Checkbox
Base UIA square checkbox on the same hard rule as everything else.
Install
$ npx shadcn@latest add https://spotcheckui.com/r/checkbox.jsonAlso installs @base-ui/react.
Usage
import { Checkbox } from "@/components/spotcheck/checkbox"
<Checkbox checked={weekends} onCheckedChange={setWeekends}>Include weekends</Checkbox>Props
- children
ReactNodeDefault —The visible label. - className
stringDefault —
Keyboard
| Space | Check or uncheck |
|---|
Reduced motion
Nothing here animates.