33 $this->registerUniversalTagAttributes();
34 $this->registerArgument(
'additionalAttributes',
'array',
'Additional tag attributes. They will be added directly to the resulting HTML tag.');
35 $this->registerArgument(
'data',
'array',
'Additional data-* attributes. They will each be added with a "data-" prefix.');
36 $this->registerTagAttribute(
'label',
'string',
'Human-readable label property for the generated optgroup tag');
37 $this->registerTagAttribute(
'disabled',
'boolean',
'If true, option group is rendered as disabled',
false,
false);
45 if ($this->arguments[
'disabled']) {
46 $this->tag->addAttribute(
'disabled',
'disabled');
48 $this->tag->removeAttribute(
'disabled');
51 $this->tag->setContent($this->renderChildren());
52 return $this->tag->render();