Checkbox
edgecom/checkboxFreeComponent
The Edgecom Checkbox component.
Live preview
live · rendered by the registry
Rendered by edgecom on their own page — this is the component running, not a screenshot of it.Install it
npx shadcn@latest add https://design.edgecom.ai/r/checkbox.jsonSource
1"use client"23import { Checkbox as CheckboxPrimitive } from "@base-ui/react/checkbox"45import { cn } from "@/lib/utils"6import { CheckIcon } from "lucide-react"78function Checkbox({ className, ...props }: CheckboxPrimitive.Root.Props) {9 return (10 <CheckboxPrimitive.Root11 data-slot="checkbox"12 className={cn(13 "peer relative flex size-4 shrink-0 items-center justify-center rounded-[4px] border border-input transition-colors outline-none group-has-disabled/field:opacity-50 after:absolute after:-inset-x-3 after:-inset-y-2 focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 disabled:cursor-not-allowed disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 aria-invalid:aria-checked:border-primary dark:bg-input/30 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40 data-checked:border-primary data-checked:bg-primary data-checked:text-primary-foreground dark:data-checked:bg-primary",14 className15 )}16 {...props}17 >18 <CheckboxPrimitive.Indicator19 data-slot="checkbox-indicator"20 className="grid place-content-center text-current transition-none [&>svg]:size-3.5"21 >22 <CheckIcon23 />24 </CheckboxPrimitive.Indicator>25 </CheckboxPrimitive.Root>26 )27}2829export { Checkbox }
What it pulls in
npm packages
Other registry items
Files it writes
More from edgecom
All 66 items| Component | Registry | Kind | Access | Installs | Command |
|---|---|---|---|---|---|
| Accordionaccordion | edgecom | Components | Free | 2 deps | |
| Alertalert | edgecom | Components | Free | 1 dep | |
| Alert Dialogalert-dialog | edgecom | Components | Free | 1 dep | |
| Avataravatar | edgecom | Components | Free | 1 dep | |
| Badgebadge | edgecom | Components | Free | 2 deps | |
| Bannerbanner | edgecom | Components | Free | 1 dep | |
| Breadcrumbbreadcrumb | edgecom | Components | Free | 2 deps | |
| Buttonbutton | edgecom | Components | Free | 2 deps |
