Skip to content

Checkbox

A checkbox built on the Radix checkbox primitive. It supports a two- or three-state (indeterminate) value and works controlled or uncontrolled.

Prop Type Default Description
label string Text label beside the box.
checked boolean | 'indeterminate' Controlled checked state.
defaultChecked boolean | 'indeterminate' Initial state when uncontrolled.
onCheckedChange (checked: boolean | 'indeterminate') => void Called when the state changes.
size 'sm' | 'md' | 'lg' 'md' Control size.
error string Error message; toggles invalid styling.
disabled boolean false Disable the control.