Checkbox
Allows user to toggle between checked, unchecked, and indeterminate states.
Import
js
import { MpCheckbox } from '@mekari/pixel3'
Playground
API
MpCheckbox
Props
Events
Slots
Name | Type | Default |
---|---|---|
id | string | - |
name | string | - |
value | string | - |
model-value | array | - |
is-checked | boolean | false |
is-indeterminate | boolean | false |
is-disabled | boolean | false |
is-invalid | boolean | false |
is-read-only | boolean | false |
Usage
Checkbox Group
With Description
Accessibility
WAI-ARIA: https://www.w3.org/WAI/ARIA/apg/patterns/checkbox/
- Provide aria-label and or aria-labelledby for screen reader support.
- When checked, checkbox has aria-checked set to true.
- When not checked, checkbox has aria-checked set to false.
- When partially checked, checkbox has aria-checked set to mixed.