checkbox
neobrutalism/checkboxFreeComponent
neobrutalism publishes no description for this item.
Live preview
live · rendered by the registry
Rendered by neobrutalism on their own page — this is the component running, not a screenshot of it.Install it
npx shadcn@latest add https://neobrutalism.com/r/checkbox.jsonSource
1"use client"23import { Checkbox as CheckboxPrimitive } from "@base-ui/react/checkbox"4import { CheckIcon } from "lucide-react"56import { cn } from "@/lib/utils"78function Checkbox({ className, ...props }: CheckboxPrimitive.Root.Props) {9 return (10 <CheckboxPrimitive.Root11 data-slot="checkbox"12 className={cn(13 "peer relative flex size-5 shrink-0 items-center justify-center rounded border-2 bg-input shadow-sm transition-colors outline-none group-has-disabled/field:opacity-50 after:absolute after:-inset-x-3 after:-inset-y-2 focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-primary disabled:cursor-not-allowed disabled:opacity-50 aria-invalid:border-destructive data-checked:border-border data-checked:bg-primary data-checked:text-primary-foreground",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 <CheckIcon />23 </CheckboxPrimitive.Indicator>24 </CheckboxPrimitive.Root>25 )26}2728export { Checkbox }
What it pulls in
npm packages
Files it writes
More from neobrutalism
All 54 items| Component | Registry | Kind | Access | Installs | Command |
|---|---|---|---|---|---|
| accordionaccordion | neobrutalism | Components | Free | 2 deps | |
| alertalert | neobrutalism | Components | Free | 2 deps | |
| alert-dialogalert-dialog | neobrutalism | Components | Free | 1 dep | |
| aspect-ratioaspect-ratio | neobrutalism | Components | Free | 1 dep | |
| avataravatar | neobrutalism | Components | Free | 1 dep | |
| badgebadge | neobrutalism | Components | Free | 2 deps | |
| breadcrumbbreadcrumb | neobrutalism | Components | Free | 2 deps | |
| buttonbutton | neobrutalism | Components | Free | 2 deps |
