Skip to content

Holo Checkbox

The <holo-checkbox> component is a form-associated checkbox that supports checked, indeterminate, and disabled states.

<holo-checkbox label="Accept terms"></holo-checkbox> <holo-checkbox label="Accept terms" checked></holo-checkbox>
<holo-checkbox label="Select all" indeterminate></holo-checkbox>
<holo-checkbox label="Accept terms" disabled></holo-checkbox>

| Property | Attribute | Description | Type | Default | | --------------- | --------------- | ---------------------------------------------------------------------- | --------- | ----------- | | label | label | The visible label text for the checkbox. | string | undefined | | name | name | The form field name submitted with the owning form. | string | undefined | | value | value | The form value submitted when the checkbox is checked. | string | "on" | | checked | checked | Whether the checkbox is checked. | boolean | false | | indeterminate | indeterminate | Puts the checkbox in an indeterminate visual state. | boolean | false | | disabled | disabled | If true, the checkbox is disabled and non-interactive. | boolean | false | | required | required | If true, the owning form cannot submit unless the checkbox is checked. | boolean | false |

| Event | Description | Type | | ------------ | --------------------------------------- | ---------------------- | | holoChange | Emitted when the checked state changes. | CustomEvent<boolean> |