{ "name": "item-card", "type": "registry:ui", "title": "Item Card", "description": "A generic row card: icon, title, description, meta, action.", "dependencies": [ "@base-ui/react@^1.8.0", "@wunderui/react", "class-variance-authority@^0.7.1", "cn@^0.3.0", "lucide-react@^1.46.0" ], "registryDependencies": [ "https://raw.githubusercontent.com/wunder-ui/wunderui/main/r/styles.json" ], "files": [ { "path": "components/wunderui/item-card.tsx", "type": "registry:component", "target": "components/wunderui/item-card.tsx", "content": "\"use client\"\n\nimport type { ReactNode } from \"react\"\nimport { Icon } from \"@/components/ui/icon-provider\"\nimport { cn } from \"@/lib/utils\"\nimport { Checkbox } from \"@/components/ui/checkbox\"\nimport { IconButton } from \"@/components/ui/icon-button\"\n\ntype ItemCardTint = \"indigo\" | \"blue\" | \"purple\" | \"pink\" | \"red\" | \"orange\" | \"yellow\" | \"green\" | \"alternative\"\n\nconst ITEM_CARD_TINT: Record = {\n indigo: \"bg-tint-indigo text-tint-text-indigo\",\n blue: \"bg-tint-blue text-tint-text-blue\",\n purple: \"bg-tint-purple text-tint-text-purple\",\n pink: \"bg-tint-pink text-tint-text-pink\",\n red: \"bg-tint-red text-tint-text-red\",\n orange: \"bg-tint-orange text-tint-text-orange\",\n yellow: \"bg-tint-yellow text-tint-text-yellow\",\n green: \"bg-tint-green text-tint-text-green\",\n alternative: \"bg-tint-alternative text-tint-text-alternative\",\n}\n\nfunction ItemCard({\n icon,\n title,\n description,\n meta,\n action,\n className,\n}: {\n icon?: ReactNode\n title: ReactNode\n description?: ReactNode\n meta?: ReactNode\n action?: ReactNode\n className?: string\n}) {\n return (\n \n {icon && (\n
\n {icon}\n
\n )}\n
\n

{title}

\n {description && (\n

{description}

\n )}\n
\n {meta &&
{meta}
}\n {action &&
{action}
}\n \n )\n}\n\nfunction ItemCardGroup({\n children,\n className,\n}: {\n children: ReactNode\n className?: string\n}) {\n return (\n
\n {children}\n
\n )\n}\n\n\n/* ------------------------------------------------------------------ */\n/* ItemCardCover — a clickable tile with a tinted cover, name and meta */\n/* Figma: Project Card (693:146) */\n/* ------------------------------------------------------------------ */\n\ntype ItemCardCoverProps = {\n name: ReactNode\n /** One short line under the name. */\n meta?: ReactNode\n /** Tint of the cover band. */\n color?: ItemCardTint\n /** Icon, logo or image in the middle of the cover. */\n cover?: ReactNode\n onClick?: () => void\n className?: string\n}\n\nfunction ItemCardCover({ name, meta, color = \"indigo\", cover, onClick, className }: ItemCardCoverProps) {\n return (\n \n {cover}\n \n {name}\n {meta && {meta}}\n \n \n )\n}\n\n/* ------------------------------------------------------------------ */\n/* ItemCardFile — a file tile: preview, name, details, selection, menu */\n/* Figma: File Card (702:57) */\n/* ------------------------------------------------------------------ */\n\ntype ItemCardFileProps = {\n name: ReactNode\n meta?: ReactNode\n icon?: ReactNode\n color?: ItemCardTint\n /** Image preview instead of the icon tile. */\n thumbnail?: string\n selected?: boolean\n onSelectedChange?: (selected: boolean) => void\n /** Type=trash — deletion line shown in red, no menu/checkbox. */\n deletedAt?: ReactNode\n onMenu?: () => void\n onOpen?: () => void\n className?: string\n}\n\nfunction ItemCardFile({ name, meta, icon, color = \"red\", thumbnail, selected, onSelectedChange, deletedAt, onMenu, onOpen, className }: ItemCardFileProps) {\n return (\n \n {/* onOpen: a real button covers the preview; the checkbox sits above it\n as a sibling, so no interactive element is nested in another. */}\n svg]:size-9\",\n ITEM_CARD_TINT[color],\n onOpen && \"has-[[data-open]:focus-visible]:focus-ring-on\"\n )}\n >\n {thumbnail ? (\n // eslint-disable-next-line @next/next/no-img-element\n \"\"\n ) : (\n (icon ?? )\n )}\n {onOpen && (\n \n )}\n {onSelectedChange && (\n onSelectedChange(!!v)}\n className={cn(\"absolute top-2 start-2 size-6 bg-card transition-opacity duration-fast ease-entrance\", !selected && \"opacity-0 group-hover/file:opacity-100 focus-visible:opacity-100\")}\n />\n )}\n \n
\n
\n

{name}

\n {meta &&

{meta}

}\n {deletedAt &&

{deletedAt}

}\n
\n {onMenu && !deletedAt && (\n \n \n \n )}\n
\n \n )\n}\n\nexport { ItemCard, ItemCardGroup, ItemCardCover, ItemCardFile, ITEM_CARD_TINT }\nexport type { ItemCardTint, ItemCardCoverProps, ItemCardFileProps }\n" }, { "path": "components/ui/icon-button.tsx", "type": "registry:ui", "target": "components/ui/icon-button.tsx", "content": "import * as React from \"react\"\nimport { Button as ButtonPrimitive } from \"@base-ui/react/button\"\nimport { cva, type VariantProps } from \"class-variance-authority\"\nimport { Icon } from \"@/components/ui/icon-provider\"\nimport { cn } from \"@/lib/utils\"\n\n// Same states as Button (see button.tsx and the Figma Button / Icon set): the filled variants use fixed\n// hover and pressed fills (brand-700/800, red-800/900, dark-400/500, bg-page/bg-subtle on neutral surfaces)\n// instead of brightness-95, and focus is the shared 2 px focus-ring (owner rule 31 Oct 2026). The gradient top\n// stop is 85 % primary + 15 % brand-500 (4.73:1 with a white icon); hover and pressed step the gradient to\n// brand-600/700 and brand-700/800. The light variant's icon is light-1000 (5.93:1 on light-600); it has no\n// Figma counterpart, hover and pressed step to the lighter light-500 and light-400 so the icon keeps >= 3:1.\nconst iconButtonVariants = cva(\n \"group/icon-button inline-flex shrink-0 items-center justify-center border border-transparent transition duration-fast ease-entrance outline-none select-none shadow-[0px_1px_1px_0px_rgba(16,24,40,0.05)] active:scale-[0.97] motion-reduce:active:scale-100 disabled:pointer-events-none disabled:opacity-40 [&_svg]:pointer-events-none [&_svg]:shrink-0\",\n {\n variants: {\n variant: {\n plain: \"bg-card border-border-control text-foreground hover:bg-bg-page data-expanded:bg-bg-subtle data-expanded:hover:bg-bg-subtle active:bg-bg-subtle focus-ring\",\n primary:\n \"border-primary bg-primary text-primary-foreground hover:border-(color:--brand-700) hover:bg-(--brand-700) active:border-(color:--brand-800) active:bg-(--brand-800) focus-ring\",\n brand:\n \"border-brand-primary bg-brand-primary text-brand-primary-foreground hover:border-(color:--brand-700) hover:bg-(--brand-700) active:border-(color:--brand-800) active:bg-(--brand-800) focus-ring\",\n gradient:\n \"border-primary bg-gradient-to-b from-[color-mix(in_srgb,var(--primary)_85%,var(--brand-500))] to-primary text-primary-foreground shadow-[0px_1px_1px_0px_rgba(16,24,40,0.05),inset_0px_1px_2px_0px_rgba(255,255,255,0.35)] hover:from-(--brand-600) hover:to-(--brand-700) active:from-(--brand-700) active:to-(--brand-800) focus-ring\",\n dark: \"bg-inverse text-text-inverse hover:bg-(--dark-400) hover:text-neutral-white active:bg-(--dark-500) active:text-neutral-white focus-visible:outline-2 focus-visible:outline-solid focus-visible:outline-offset-0 focus-visible:outline-(color:--dark-300)\",\n light: \"bg-(--light-600) text-(--light-1000) hover:bg-(--light-500) data-expanded:bg-bg-subtle data-expanded:hover:bg-bg-subtle active:bg-(--light-400) focus-ring\",\n outline: \"bg-card border-primary text-foreground hover:border-tint-text-indigo hover:bg-tint-indigo hover:text-tint-text-indigo data-expanded:bg-bg-subtle data-expanded:hover:bg-bg-subtle active:bg-bg-subtle focus-ring\",\n // Figma Type=ghost / destructive (added Sep 2026)\n ghost: \"bg-transparent text-foreground shadow-none hover:bg-bg-page data-expanded:bg-bg-subtle data-expanded:hover:bg-bg-subtle active:bg-bg-subtle focus-ring\",\n destructive:\n \"border-destructive bg-destructive text-destructive-foreground hover:border-(color:--red-800) hover:bg-(color:--red-800) active:border-(color:--red-900) active:bg-(color:--red-900) focus-ring-error\",\n },\n shape: {\n rounded: \"rounded-md\",\n circle: \"rounded-full\",\n },\n size: {\n sm: \"size-8 [&_svg]:size-4\",\n md: \"size-9 [&_svg]:size-[18px]\",\n lg: \"size-10 [&_svg]:size-5\",\n xl: \"size-11 [&_svg]:size-[22px]\",\n \"2xl\": \"size-12 [&_svg]:size-6\",\n },\n },\n defaultVariants: {\n variant: \"primary\",\n shape: \"rounded\",\n size: \"md\",\n },\n }\n)\n\ntype IconButtonPhase = \"idle\" | \"pending\" | \"success\" | \"error\"\n\nfunction IconButton({\n className,\n variant,\n shape,\n size,\n children,\n onClick,\n pending,\n phase,\n expanded,\n ...props\n}: ButtonPrimitive.Props &\n VariantProps & {\n /**\n * Shows a spinner in place of the icon, in the same square, and ignores presses.\n * The button stays focusable and keeps its colour (it is not disabled).\n */\n pending?: boolean\n /**\n * Async feedback in the same square: pending shows a spinner, success a check, error a retry icon.\n * The size never changes. The accessible name is yours: change the aria-label with the phase\n * (for example Copy link, Copying, Copied, Retry copying).\n */\n phase?: IconButtonPhase\n /**\n * Marks a trigger whose menu or panel is open: sets aria-expanded and the pressed surface\n * (bg-bg-subtle) on the quiet variants. Leave it undefined when the button does not control a popup.\n */\n expanded?: boolean\n }) {\n const status: IconButtonPhase = phase ?? (pending ? \"pending\" : \"idle\")\n const isIdle = status === \"idle\"\n\n const resolvedVariant = variant ?? \"primary\"\n const effectiveVariant =\n status === \"error\" && [\"primary\", \"brand\", \"gradient\"].includes(resolvedVariant)\n ? \"destructive\"\n : variant\n\n const quiet = [\"plain\", \"ghost\", \"outline\"].includes(resolvedVariant)\n\n let statusIcon: React.ReactNode = null\n if (status === \"pending\") {\n statusIcon = (\n \n )\n } else if (status === \"success\") {\n statusIcon = (\n \n )\n } else if (status === \"error\") {\n statusIcon = (\n \n )\n }\n\n const handleClick: NonNullable = (event) => {\n if (status === \"pending\") {\n event.preventDefault()\n return\n }\n onClick?.(event)\n }\n\n return (\n \n {isIdle ? children : statusIcon}\n \n )\n}\n\nexport { IconButton, iconButtonVariants }\nexport type { IconButtonPhase }\n" }, { "path": "lib/utils.ts", "type": "registry:lib", "target": "lib/utils.ts", "content": "import type { CnFunction } from \"cn\"\nimport { createCn } from \"cn/config\"\n\n/**\n * clsx + tailwind-merge, taught WunderUI's own theme utilities so they merge\n * in the right group: `text-label-sm` is a font size (not a text colour, which\n * dropped it next to `text-text-tertiary`), `bg-gradient-*` a background image\n * (not a colour that `bg-card` would remove), and the motion utilities\n * `ease-entrance …` and `duration-fast …` replace each other.\n */\nexport const cn: CnFunction = createCn({\n extend: {\n classGroups: {\n \"font-size\": [{ text: [\"label-sm\", \"micro\"] }],\n \"bg-image\": [\n {\n bg: [\n \"gradient-primary\",\n \"gradient-indigo\",\n \"gradient-blue\",\n \"gradient-purple\",\n \"gradient-pink\",\n \"gradient-red\",\n \"gradient-orange\",\n \"gradient-yellow\",\n \"gradient-green\",\n \"gradient-alternative\",\n \"gradient-slate\",\n \"gradient-dark\",\n ],\n },\n ],\n ease: [{ ease: [\"entrance\", \"exit\", \"move\", \"overshoot\", \"spring\"] }],\n duration: [{ duration: [\"instant\", \"fast\", \"base\", \"slow\", \"deliberate\", \"ambient\"] }],\n },\n },\n})\n" }, { "path": "components/ui/icon-provider.tsx", "type": "registry:ui", "target": "components/ui/icon-provider.tsx", "content": "\"use client\"\n\nimport * as React from \"react\"\nimport {\n ArrowDown,\n ArrowDownRight,\n ArrowLeft,\n ArrowLeftToLine,\n ArrowRightToLine,\n ArrowUp,\n ArrowRight,\n ArrowUpRight,\n AtSign,\n Ban,\n Bell,\n Bold,\n Bot,\n Building2,\n Calendar,\n CalendarDays,\n ChartColumn,\n Check,\n ChevronDown,\n ChevronLeft,\n ChevronRight,\n ChevronsLeft,\n ChevronsRight,\n ChevronsUpDown,\n ChevronUp,\n Circle,\n CircleAlert,\n CircleCheck,\n CircleDashed,\n CircleDot,\n CircleHelp,\n CircleMinus,\n CircleSlash,\n Clock,\n CloudUpload,\n Copy,\n Download,\n Ellipsis,\n EllipsisVertical,\n ExternalLink,\n Eye,\n EyeOff,\n FileIcon,\n FileCode,\n FileDiff,\n FilePenLine,\n FileText,\n Film,\n Flag,\n Folder,\n FolderOpen,\n Globe,\n GripVertical,\n Hand,\n Handshake,\n Hash,\n Heading1,\n Heading2,\n Heart,\n ImageIcon,\n ImageOff,\n Inbox,\n Info,\n Italic,\n LinkIcon,\n Link2,\n List,\n ListFilter,\n ListOrdered,\n ListTodo,\n LoaderCircle,\n Lock,\n Maximize2,\n Menu,\n MessageCircle,\n MessageSquare,\n Mic,\n Minimize2,\n Minus,\n Moon,\n MousePointer2,\n Package,\n Pause,\n Play,\n PanelRight,\n PictureInPicture2,\n Paperclip,\n Pencil,\n Pin,\n PinOff,\n Pipette,\n Plus,\n ReceiptText,\n RefreshCw,\n Reply,\n RotateCcw,\n RotateCw,\n Scan,\n SeparatorHorizontal,\n Search,\n SearchX,\n ShieldAlert,\n ShieldCheck,\n Slash,\n SlidersHorizontal,\n Smartphone,\n Split,\n Sparkles,\n Square,\n SquareCode,\n SquareCheck,\n SquareCheckBig,\n Star,\n StickyNote,\n Sun,\n Table2,\n ThumbsDown,\n ThumbsUp,\n Timer,\n Trash2,\n TextQuote,\n TrendingDown,\n TrendingUp,\n TriangleAlert,\n Underline,\n Undo2,\n UserRound,\n Workflow,\n Wrench,\n X,\n Zap,\n ZoomIn,\n ZoomOut,\n} from \"lucide-react\"\n\n/**\n * Props every icon of an `IconSet` receives: the SVG attributes the components set (`className`,\n * `aria-hidden`, `strokeWidth`, `data-*`, `style` …) and `size`. Sizes come from the `size-*` classes\n * the components put on the icon, so a replacement only has to pass `className` on to its ``.\n */\ntype IconProps = Omit, \"ref\" | \"children\" | \"dangerouslySetInnerHTML\"> & {\n /** Width and height; the components size icons through `className` instead. */\n size?: number | string\n}\n\ntype IconComponent = React.ComponentType\n\n// The checkbox draws its mark heavier so it reads at 14 px: 3 on lucide's 24 grid for the check, 4\n// for the minus. The weight belongs to the Lucide drawing, so a replacement set brings its own.\nfunction CheckboxCheck(props: IconProps) {\n return \n}\nfunction CheckboxIndeterminate(props: IconProps) {\n return \n}\n\n/**\n * The Lucide glyphs the components draw themselves (chevrons, checks, close buttons, status marks,\n * table tools …), one name per role. `IconProvider` swaps them for another set; without a provider\n * the components render exactly these Lucide icons. Icons you pass to a component as a prop are\n * yours and never resolved through here.\n */\nconst DEFAULT_ICONS = {\n // chevrons and arrows\n chevronDown: ChevronDown,\n chevronUp: ChevronUp,\n chevronLeft: ChevronLeft,\n chevronRight: ChevronRight,\n chevronsLeft: ChevronsLeft,\n chevronsRight: ChevronsRight,\n arrowUp: ArrowUp,\n arrowDown: ArrowDown,\n arrowLeft: ArrowLeft,\n arrowRight: ArrowRight,\n arrowUpRight: ArrowUpRight,\n arrowDownRight: ArrowDownRight,\n trendUp: TrendingUp,\n trendDown: TrendingDown,\n moveUp: ArrowUp,\n moveDown: ArrowDown,\n send: ArrowUp,\n external: ExternalLink,\n // actions\n check: Check,\n close: X,\n plus: Plus,\n minus: Minus,\n search: Search,\n searchEmpty: SearchX,\n copy: Copy,\n download: Download,\n upload: CloudUpload,\n edit: Pencil,\n trash: Trash2,\n undo: Undo2,\n reset: RotateCcw,\n regenerate: RotateCcw,\n retry: RotateCw,\n refresh: RefreshCw,\n more: Ellipsis,\n moreVertical: EllipsisVertical,\n grip: GripVertical,\n menu: Menu,\n panelRight: PanelRight,\n expand: Maximize2,\n collapse: Minimize2,\n // floating panel windows\n minimize: Minus,\n dock: PanelRight,\n undock: PictureInPicture2,\n show: Eye,\n hide: EyeOff,\n pin: Pin,\n unpin: PinOff,\n eyedropper: Pipette,\n attach: Paperclip,\n stop: Square,\n microphone: Mic,\n reply: Reply,\n thumbsUp: ThumbsUp,\n thumbsDown: ThumbsDown,\n // data table\n filter: ListFilter,\n view: SlidersHorizontal,\n sortAsc: ArrowUp,\n sortDesc: ArrowDown,\n sortNone: ChevronsUpDown,\n pinStart: ArrowLeftToLine,\n pinEnd: ArrowRightToLine,\n chart: ChartColumn,\n table: Table2,\n // form marks\n checkboxCheck: CheckboxCheck,\n checkboxIndeterminate: CheckboxIndeterminate,\n checkboxOff: Square,\n checkboxOn: SquareCheck,\n radioOff: Circle,\n radioOn: CircleDot,\n // status\n spinner: LoaderCircle,\n warning: TriangleAlert,\n error: CircleAlert,\n success: CircleCheck,\n info: Info,\n help: CircleHelp,\n verified: ShieldCheck,\n securityAlert: ShieldAlert,\n cancelled: Ban,\n pause: Pause,\n play: Play,\n pending: Circle,\n circleDashed: CircleDashed,\n circleMinus: CircleMinus,\n circleSlash: CircleSlash,\n lock: Lock,\n inbox: Inbox,\n imageMissing: ImageOff,\n clock: Clock,\n timer: Timer,\n calendar: CalendarDays,\n dueDate: Calendar,\n notification: Bell,\n sun: Sun,\n moon: Moon,\n star: Star,\n heart: Heart,\n package: Package,\n smartphone: Smartphone,\n // chart event markers (ChartAnnotations events)\n flag: Flag,\n // AI and chat\n agent: Bot,\n user: UserRound,\n tool: Wrench,\n sparkles: Sparkles,\n zap: Zap,\n globe: Globe,\n comment: MessageCircle,\n message: MessageSquare,\n mention: AtSign,\n hash: Hash,\n link: Link2,\n // files\n file: FileIcon,\n document: FileText,\n fileCode: FileCode,\n fileDiff: FileDiff,\n image: ImageIcon,\n video: Film,\n folder: Folder,\n folderOpen: FolderOpen,\n // records (Record Chip)\n customer: Building2,\n deal: Handshake,\n invoice: ReceiptText,\n contract: FilePenLine,\n task: SquareCheckBig,\n note: StickyNote,\n // breadcrumb\n slash: Slash,\n // rich text editor\n formatBold: Bold,\n formatItalic: Italic,\n formatUnderline: Underline,\n formatBulletList: List,\n formatNumberedList: ListOrdered,\n formatLink: LinkIcon,\n formatHeading1: Heading1,\n formatHeading2: Heading2,\n formatTaskList: ListTodo,\n formatQuote: TextQuote,\n formatDivider: SeparatorHorizontal,\n formatCode: SquareCode,\n // flow canvas\n zoomIn: ZoomIn,\n zoomOut: ZoomOut,\n fitView: Scan,\n toolSelect: MousePointer2,\n toolHand: Hand,\n tidyUp: Workflow,\n branch: Split,\n} satisfies Record\n\n/** Every built-in icon role of the components (see `DEFAULT_ICONS`). */\ntype IconName = keyof typeof DEFAULT_ICONS\n\n/** A replacement for some or all built-in icons; names left out keep the icon of the parent provider (or Lucide). */\ntype IconSet = Partial>\n\nconst IconContext = React.createContext(null)\n\ntype IconProviderProps = {\n /** The icons to use instead of Lucide, by name. Names left out keep the icon of the parent provider. */\n icons: IconSet\n children?: React.ReactNode\n}\n\n/**\n * Swaps the icons the components draw themselves (the Select chevron, the Checkbox check, the Dialog\n * close button, the Data Table tools …) for another set. Providers nest: an inner provider replaces\n * only the names it lists. It renders no UI, and portals (Dialog, Sheet, menus) inherit it, since they\n * stay in the React tree. Without a provider every component draws Lucide.\n *\n * @example\n * import { solarSet } from \"@wunderui/react/icons/solar/set\"\n *\n * \n * \n * \n */\nfunction IconProvider({ icons, children }: IconProviderProps) {\n const parent = React.useContext(IconContext)\n const value = React.useMemo(() => (parent ? { ...parent, ...icons } : icons), [parent, icons])\n return {children}\n}\n\n/**\n * The component for a built-in icon name: the one of the nearest `IconProvider`, otherwise the Lucide\n * default.\n *\n * @example\n * const ChevronIcon = useIcon(\"chevronDown\")\n * return \n */\nfunction useIcon(name: IconName): IconComponent {\n const icons = React.useContext(IconContext)\n return icons?.[name] ?? DEFAULT_ICONS[name]\n}\n\ntype IconByNameProps = IconProps & {\n /** The built-in icon role, resolved through the nearest `IconProvider`. */\n name: IconName\n}\n\n/**\n * Draws a built-in icon by name, through the nearest `IconProvider`.\n *\n * @example\n * \n */\nfunction Icon({ name, ...props }: IconByNameProps) {\n const Component = useIcon(name)\n return \n}\n\nexport { DEFAULT_ICONS, Icon, IconProvider, useIcon }\nexport type { IconByNameProps, IconComponent, IconName, IconProps, IconProviderProps, IconSet }\n" }, { "path": "components/ui/checkbox.tsx", "type": "registry:ui", "target": "components/ui/checkbox.tsx", "content": "\"use client\"\n\nimport { Checkbox as CheckboxPrimitive } from \"@base-ui/react/checkbox\"\nimport { cn } from \"@/lib/utils\"\nimport { Icon } from \"@/components/ui/icon-provider\"\nimport * as React from \"react\"\n\n/**\n * Base UI renders a hidden native \n {label && (\n {label}\n )}\n {description && {description}}\n \n \n )\n if (!withMessage) return row\n return (\n
\n {row}\n {error && (\n

\n {error}\n

\n )}\n
\n )\n}\n\nfunction CheckboxControl({\n className,\n inputRef,\n appearance = \"brand\",\n ...props\n}: CheckboxControlProps) {\n const namedInputRef = useNamedHiddenInput(inputRef, props[\"aria-label\"], props[\"aria-labelledby\"])\n return (\n \n svg]:size-3.5 [&>svg:last-child]:hidden data-indeterminate:[&>svg:first-child]:hidden data-indeterminate:[&>svg:last-child]:block\",\n // The box fills instantly (see Root's data-checked:bg-primary above);\n // the check stroke draws in after via stroke-dashoffset. 23 is\n // lucide's CheckIcon path length (getTotalLength()), rounded up by 1\n // so the draw never over/under-shoots. Uncheck reverses fast with no\n // draw — transitioning offset (not toggling display) is what lets a\n // mid-draw uncheck reverse cleanly instead of jumping. The offset is\n // negative because lucide's path starts at the top-right end: the\n // tick draws from its short stroke up to the long one, like by hand.\n \"[&_svg_path]:[stroke-dasharray:23] [&_svg_path]:[stroke-dashoffset:-23] [&_svg_path]:transition-[stroke-dashoffset] [&_svg_path]:duration-fast [&_svg_path]:ease-entrance data-checked:[&_svg_path]:[stroke-dashoffset:0] data-indeterminate:[&_svg_path]:[stroke-dashoffset:0] data-checked:[&_svg_path]:duration-slow\"\n )}\n >\n {/* the roles checkboxCheck / checkboxIndeterminate (ui/icon-provider.tsx) draw Lucide heavier so the mark reads at 16 px: 3 on lucide's 24 grid for the check (about 1.75 px at 14 px), 4 for the minus, a short bar that looks thinner than the check at the same weight */}\n \n \n \n \n )\n}\n\nexport { Checkbox }\nexport type { CheckboxProps }\n" } ], "docs": "https://wunderui.com/components/item-card", "meta": { "group": "Core Elements", "exports": [ "ItemCard", "FileCard", "ItemCardCover", "ItemCardCoverProps", "ItemCardFile", "ItemCardFileProps", "ItemCardGroup", "ItemCardTint", "ProjectCard" ] } }