Card-style multi-select component. Each card acts as a checkbox, making selections visually prominent.
import CheckboxCards from "@radui/ui/CheckboxCards"- Multi-select where each option is a card you can lay out freely
- Arrow keys move between cards; Space toggles the focused one
- Each card is a native checkbox for forms, with a shared name
- Controlled with value and onValueChange, or uncontrolled with defaultValue
Import all parts of the component and piece them together.
The root CheckboxCards component.
| Prop | Type | Default |
|---|---|---|
value | string[] | [] |
defaultValue | string[] | [] |
onValueChange | function | — |
| Shortcut | Description |
|---|---|
| Tab | Moves focus into or out of the checkbox card group. |
| ArrowRight | Moves focus to the next enabled card when the group orientation allows horizontal navigation. |
| ArrowDown | Moves focus to the next enabled card when the group orientation allows vertical navigation. |
| ArrowLeft | Moves focus to the previous enabled card when the group orientation allows horizontal navigation. |
| ArrowUp | Moves focus to the previous enabled card when the group orientation allows vertical navigation. |
| Home | Moves focus to the first enabled card. |
| End | Moves focus to the last enabled card. |
| Space | Toggles the focused card between checked and unchecked states. |
| Reference | What Rad UI follows |
|---|---|
| Checkbox pattern | Each card uses checkbox semantics with aria-checked, aria-required, and aria-disabled state exposed on the focusable item. |