- Implementation
- Checkbox Props
Common Examples
To use theCheckbox, import it from @servicetitan/anvil2-ai-kit and pass a visible label, or omit label and supply exactly one of aria-label or aria-labelledby.Selection
UseisSelected with onChange for controlled selection, or defaultSelected for uncontrolled.Indeterminate
isIndeterminate is a display-only mixed state for select-all rows. Derive it from child selection in your own logic.Label and indicator-only
A visiblelabel is the accessible name. For dense rows, omit label and name the control with aria-label or aria-labelledby. Never pass both naming attributes.Disabled
isDisabled dims the control and blocks interaction in either selection state.React Accessibility
- Supply a visible
label, or exactly one ofaria-labeloraria-labelledby. - Keyboard focus draws a ring on the square indicator, not the full label width.
- Users toggle a focused checkbox with Space.