Skip to content

Checkbox group โ€‹

...

Browser support โ€‹

...

Parameters โ€‹

The Web component uses a <z-checkbox-group> tag.

Hello

The parametrization of the component can be done with the following custom HTML params:

NameTypeDescription
disabledboolean?Blocks the interaction with the input component.
requiredboolean?Marks the input component as required.
namestring?Identification for the field inside the form
invalidboolean?The forced state for set the input as invalid

The events emitted from the component are:

NamePayloadDescription
onchangeboolean[]Returns the new value of the "value" attribute

Playground โ€‹

Customization โ€‹

HTML Examples โ€‹

Imports
html
<link rel="stylesheet" href="/0.3.6/@zurich/web-components/styles.css" />
<script type="module" src="/0.3.6/@zurich/web-components/checkbox-group.js"></script>
Code
html
<z-checkbox-group label="Checkbox group"
  options='[{ "text": "Option A" },{ "text": "Option B" },{ "text": "Option C" },{ "text": "Option D", "disabled": "true" }]'></z-checkbox-group>