public function __invoke(ElementInterface $element = null, $buttonContent = null) { if ($element && !$element->hasAttribute('class')) { $this->addClasses($element, ['btn', 'btn-default']); } return parent::__invoke($element); }
/** * Button element * * @param ElementInterface|null $element * @param null $buttonContent * @return string|Helper\FormButton */ public function button(ElementInterface $element = null, $buttonContent = null) { $helper = new Helper\FormButton(); return $helper->__invoke($element, $buttonContent); }