IcingaCheckbox: Add `hidden attribute to input element

refs #4310

(cherry picked from commit 24c1bb1f8cc63e811fc60d0157a895de9ab3569f)
This commit is contained in:
Florian Strohmaier 2021-05-10 10:00:00 +02:00 committed by Johannes Meyer
parent 00ff11ea9f
commit 9da047ffaf

View File

@ -11,7 +11,8 @@ class IcingaCheckbox extends \Zend_View_Helper_FormCheckbox
$attribs['id'] = $this->view->protectId('icingaCheckbox_' . $name);
}
$attribs['class'] = (isset($attribs['class']) ? $attribs['class'] . ' ' : '') . 'sr-only';
$attribs['class'] = (isset($attribs['class']) ? $attribs['class'] : '');
$attribs['hidden'] = true;
$html = parent::formCheckbox($name, $value, $attribs, $checkedOptions);
$class = 'toggle-switch';