Default
Unchecked glass control with label.
Native checkbox with a glass visual control — pair with a label for multi-select
options. Control and label are vertically centered; add .items-start when
the label wraps to multiple lines.
Live
<label class="checkbox">
<input class="checkbox__input" type="checkbox" name="notify" value="email" checked />
<span class="checkbox__control" aria-hidden="true"></span>
<span class="checkbox__label">Email updates</span>
</label>
import { Checkbox } from 'caustica-design/core'
<Checkbox name="notify" value="email" defaultChecked>
Email updates
</Checkbox>
Unchecked glass control with label.
Filled system-blue with checkmark.
.is-invalid + aria-invalid for error styling.
Native disabled — reduced opacity.
<label> so the text activates the control.
.checkbox__control is decorative —
aria-hidden="true".
aria-invalid="true" and link help text with
aria-describedby.
:focus-visible — keep them.| Class | Description |
|---|---|
.checkbox |
Root label / wrapper. |
.checkbox__input |
Native type="checkbox" (visually hidden). |
.checkbox__control |
Glass square indicator. |
.checkbox__label |
Visible label text. |
.is-invalid |
Error border / ring on root or input. |
.selection-stack |
Vertical stack of selection controls. |
From src/core/Checkbox.tsx — extends native
InputHTMLAttributes<HTMLInputElement> (minus type).
| Prop | Type | Default | Description |
|---|---|---|---|
invalid |
boolean |
false |
Applies .is-invalid and aria-invalid. |
children |
ReactNode |
— | When set, wraps in a <label> with label text. |
disabled |
boolean |
— | Native disabled state. |
className |
string |
— | Merged onto the root wrapper. |
id / name / checked |
native | — | Passed through to the input. |