Design System

Component usage guide template

Browse Components

ui

Checkbox

A control that allows the user to toggle between checked and not checked.

1. Import
Import the checkbox component from the design system.
import { Checkbox } from "@/design-system/components/ui/checkbox"
2. Props
Checkbox component props.
PropTypeDefault
checkedboolean | 'indeterminate'false
defaultCheckedbooleanfalse
onCheckedChange(checked: boolean | 'indeterminate') => void--
disabledbooleanfalse
labelstring | React.ReactNode--
requiredbooleanfalse
errorstring--
size'xxs' | 'xs' | 'sm' | 'md' | 'lg' | 'xl' | 'xxl'sm
labelClassNamestring--
errorClassNamestring--
classNamestring--
3. Sizes
Available sizes for the Checkbox component.
4. Usages
Common checkbox patterns and configurations.
import { Checkbox } from "@/design-system/components/ui/checkbox";

export function Example() {
  return (
    <Checkbox id="terms" label="Accept terms and conditions" />
  );
}