mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 14:05:37 +02:00
BUG Allow extension of getAttributes for Tab and TabSet (#9954)
This commit is contained in:
parent
2c1ef4df23
commit
6e2955fe14
@ -137,12 +137,16 @@ class Tab extends CompositeField
|
|||||||
|
|
||||||
public function getAttributes()
|
public function getAttributes()
|
||||||
{
|
{
|
||||||
return array_merge(
|
$attributes = array_merge(
|
||||||
$this->attributes,
|
$this->attributes,
|
||||||
[
|
[
|
||||||
'id' => $this->ID(),
|
'id' => $this->ID(),
|
||||||
'class' => 'tab ' . $this->extraClass()
|
'class' => 'tab ' . $this->extraClass()
|
||||||
]
|
]
|
||||||
);
|
);
|
||||||
|
|
||||||
|
$this->extend('updateAttributes', $attributes);
|
||||||
|
|
||||||
|
return $attributes;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -178,13 +178,17 @@ class TabSet extends CompositeField
|
|||||||
|
|
||||||
public function getAttributes()
|
public function getAttributes()
|
||||||
{
|
{
|
||||||
return array_merge(
|
$attributes = array_merge(
|
||||||
$this->attributes,
|
$this->attributes,
|
||||||
[
|
[
|
||||||
'id' => $this->ID(),
|
'id' => $this->ID(),
|
||||||
'class' => $this->extraClass()
|
'class' => $this->extraClass()
|
||||||
]
|
]
|
||||||
);
|
);
|
||||||
|
|
||||||
|
$this->extend('updateAttributes', $attributes);
|
||||||
|
|
||||||
|
return $attributes;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
Loading…
Reference in New Issue
Block a user