Checkboxes
Usage and anatomy
Checkbox combines an accessible control with a separate label. Use <Checkbox /> for the interactive state and connect <Label /> with a matching htmlFor value.
import { Checkbox } from "@acme/ui/checkbox"import { Label } from "@acme/ui/label"<div className="flex plumeui-wr plumeui-oaa"><Checkbox id="email-notifications" defaultChecked /><Label htmlFor="email-notifications">Email notifications</Label></div>
- Use a clear, unique
idfor every checkbox so its label remains clickable. - Use descriptions for supporting context and choice cards when the entire option should feel selectable.
- Use Button for submitting or confirming a group of checkbox choices.
Checkbox States
License required
In order to get the source code for this component, you need to buy a license.
Checkbox Sizes
License required
In order to get the source code for this component, you need to buy a license.
Checkbox Disabled States
License required
In order to get the source code for this component, you need to buy a license.
Checkbox with Description
License required
In order to get the source code for this component, you need to buy a license.
Checkbox Choice Cards
License required
In order to get the source code for this component, you need to buy a license.
Checkbox with Form
License required
In order to get the source code for this component, you need to buy a license.
API reference
Checkbox
| Prop | Type | Default |
|---|---|---|
| size | md | lg | md |
| checked | boolean | indeterminate | — |
| disabled | boolean | false |
Checkbox also accepts native Radix checkbox props such as defaultChecked, onCheckedChange, and aria-invalid.