Forms
ChoiceCard
A choice that needs more than a word: a plan, a way to import, where to start. Each card is the label of a native radio or checkbox, so the arrow keys, one Tab stop and forms come from the browser. The chosen card takes the strong brand border and a check that draws itself in. An option that is off says why. Server safe without onValueChange.
Preview
Installation
// Resolves dependencies, copies the source, and installs npm packages automatically.
Usage
Props
| Prop | Type | Default | Description |
|---|---|---|---|
| options | { value, title, description?, icon?, badge?, disabled? }[] | - | disabled as text says why |
| legend | ReactNode | - | The question; hideLegend keeps it for screen readers |
| type | "radio" | "checkbox" | "radio" | One, or several |
| value, defaultValue, onValueChange | string | string[] | - | A string for radio, an array for checkbox |
| columns | 1 | 2 | 3 | 2 | From 640px; one below |