<dt></dt>
<dd>
<label>
- <input type="checkbox" id="{@$field->getPrefixedId()}" name="{@$field->getPrefixedId()}" value="1"{if $field->isRequired()} required{/if}{if $field->isImmutable()} disabled{/if}{if $field->getValue()} checked{/if}>
+ <input type="checkbox" {*
+ *}id="{@$field->getPrefixedId()}" {*
+ *}name="{@$field->getPrefixedId()}" {*
+ *}value="1"{*
+ *}{if !$field->getFieldClasses()|empty} class="{implode from=$field->getFieldClasses() item='class' glue=' '}{$class}{/implode}"{/if}{*
+ *}{if $field->isRequired()} required{/if}{*
+ *}{if $field->isImmutable()} disabled{/if}{*
+ *}{if $field->getValue()} checked{/if}{*
+ *}>
{@$field->getLabel()}{if $field->isRequired()} <span class="formFieldRequired">*</span>{/if}
</label>
<dt></dt>
<dd>
<label>
- <input type="checkbox" id="{@$field->getPrefixedId()}" name="{@$field->getPrefixedId()}" value="1"{if $field->isRequired()} required{/if}{if $field->isImmutable()} disabled{/if}{if $field->getValue()} checked{/if}>
+ <input type="checkbox" {*
+ *}id="{@$field->getPrefixedId()}" {*
+ *}name="{@$field->getPrefixedId()}" {*
+ *}value="1"{*
+ *}{if !$field->getFieldClasses()|empty} class="{implode from=$field->getFieldClasses() item='class' glue=' '}{$class}{/implode}"{/if}{*
+ *}{if $field->isRequired()} required{/if}{*
+ *}{if $field->isImmutable()} disabled{/if}{*
+ *}{if $field->getValue()} checked{/if}{*
+ *}>
{@$field->getLabel()}{if $field->isRequired()} <span class="formFieldRequired">*</span>{/if}
</label>
* @package WoltLabSuite\Core\System\Form\Builder\Field
* @since 5.3
*/
-class CheckboxFormField extends BooleanFormField {
+class CheckboxFormField extends BooleanFormField implements ICssClassFormField {
+ use TCssClassFormField;
+
/**
* @inheritDoc
*/