Components
- Accordion
- Alert
- Alert Dialog
- Aspect Ratio
- Attachment
- Avatar
- Badge
- Breadcrumb
- Bubble
- Button
- Button Group
- Calendar
- Card
- Carousel
- Chart
- Checkbox
- Collapsible
- Combobox
- Command
- Context Menu
- Date Picker
- Dialog
- Drawer
- Dropdown Menu
- Empty
- Field
- Hover Card
- Input
- Input OTP
- Input Group
- Item
- Kbd
- Label
- Marker
- Menubar
- Message
- Message Scroller
- Native Select
- Navigation Menu
- Pagination
- Popover
- Progress
- Radio Group
- Resizable
- Scroll Area
- Select
- Separator
- Sheet
- Sidebar
- Skeleton
- Slider
- Sonner
- Spinner
- Switch
- Table
- Tabs
- Textarea
- Toggle
- Toggle Group
- Tooltip
- New Component
Elements
Charts
Icons
Profile
nuno@example.com
Notifications
Push and email alerts
3
Billing
Manage your subscription
import { Bell, ChevronRight, CreditCard, Lock, Mail, User } from "lucide-react";
import { Badge } from "@/components/ui/badge";
import { Item, ItemAction, ItemContent, ItemDescription, ItemIcon, ItemLabel } from "@/components/ui/item";
export const ItemDemo = () => (
<div className="w-full max-w-sm divide-y">
{/* Icon + label only */}
<Item>
<ItemIcon><User /></ItemIcon>
<ItemContent><ItemLabel>Profile</ItemLabel></ItemContent>
</Item>
{/* Icon + label + description */}
<Item>
<ItemIcon><Mail /></ItemIcon>
<ItemContent>
<ItemLabel>Email</ItemLabel>
<ItemDescription>nuno@example.com</ItemDescription>
</ItemContent>
</Item>
{/* With badge action */}
<Item>
<ItemIcon><Bell /></ItemIcon>
<ItemContent>
<ItemLabel>Notifications</ItemLabel>
<ItemDescription>Push and email alerts</ItemDescription>
</ItemContent>
<ItemAction><Badge>3</Badge></ItemAction>
</Item>
{/* With chevron (interactive via asChild) */}
<Item asChild>
<button className="w-full cursor-pointer hover:bg-muted/50 rounded-md px-2 -mx-2 transition-colors">
<ItemIcon><Lock /></ItemIcon>
<ItemContent>
<ItemLabel>Security</ItemLabel>
<ItemDescription>Password and 2FA</ItemDescription>
</ItemContent>
<ItemAction><ChevronRight className="size-4 text-muted-foreground" /></ItemAction>
</button>
</Item>
{/* No icon */}
<Item>
<ItemContent>
<ItemLabel>Billing</ItemLabel>
<ItemDescription>Manage your subscription</ItemDescription>
</ItemContent>
<ItemAction><CreditCard className="size-4 text-muted-foreground" /></ItemAction>
</Item>
</div>
);Label only
The simplest form — just a label with an optional icon.
<Item>
<ItemIcon>
<User />
</ItemIcon>
<ItemContent>
<ItemLabel>Profile</ItemLabel>
</ItemContent>
</Item>With description
Add a secondary line for supporting detail. ItemDescription truncates long text automatically.
<Item>
<ItemIcon>
<Mail />
</ItemIcon>
<ItemContent>
<ItemLabel>Email</ItemLabel>
<ItemDescription>nuno@example.com</ItemDescription>
</ItemContent>
</Item>With trailing action
ItemAction anchors to the right with ml-auto. Place a badge, icon, or switch inside.
<Item>
<ItemIcon>
<Bell />
</ItemIcon>
<ItemContent>
<ItemLabel>Notifications</ItemLabel>
<ItemDescription>Push and email alerts</ItemDescription>
</ItemContent>
<ItemAction>
<Badge>3</Badge>
</ItemAction>
</Item>Interactive with asChild
Use asChild to render Item as a <button> or <a> — the item merges its classes onto the child element so semantics and interactivity are correct.
<Item asChild>
<button className="w-full cursor-pointer hover:bg-muted/50 rounded-md px-2 transition-colors">
<ItemIcon>
<Lock />
</ItemIcon>
<ItemContent>
<ItemLabel>Security</ItemLabel>
<ItemDescription>Password and 2FA</ItemDescription>
</ItemContent>
<ItemAction>
<ChevronRight className="size-4 text-muted-foreground" />
</ItemAction>
</button>
</Item>Without icon
ItemIcon is optional — omit it to push ItemContent to the leading edge.
<Item>
<ItemContent>
<ItemLabel>Billing</ItemLabel>
<ItemDescription>Manage your subscription</ItemDescription>
</ItemContent>
<ItemAction>
<CreditCard className="size-4 text-muted-foreground" />
</ItemAction>
</Item>In a list
Wrap multiple items in a <div className="divide-y"> for a standard bordered list.
<div className="divide-y rounded-lg border">
<Item className="px-4">
<ItemContent>
<ItemLabel>General</ItemLabel>
</ItemContent>
<ItemAction>
<ChevronRight className="size-4 text-muted-foreground" />
</ItemAction>
</Item>
<Item className="px-4">
<ItemContent>
<ItemLabel>Notifications</ItemLabel>
</ItemContent>
<ItemAction>
<ChevronRight className="size-4 text-muted-foreground" />
</ItemAction>
</Item>
</div>Props
Item
| Prop | Type | Default | Description |
|---|---|---|---|
asChild | boolean | false | Merges props onto the child element instead of rendering a <div> |
className | string | — | Default layout is flex items-center gap-3 py-2.5 |
ItemIcon
Asize-9 square container with bg-muted and centered SVG icon. Pass any icon as a child; it is automatically sized to size-4.
ItemContent
flex-1 min-w-0 column — place ItemLabel and optionally ItemDescription inside.
ItemLabel
text-sm font-medium leading-none paragraph.
ItemDescription
text-xs text-muted-foreground paragraph with truncate. For a second line of detail.
ItemAction
ml-auto flex row — place icons, badges, switches, or buttons as trailing content.
Usage
import {
Item,
ItemAction,
ItemContent,
ItemDescription,
ItemIcon,
ItemLabel,
} from "@/components/ui/item";
<Item>
<ItemIcon>
<User />
</ItemIcon>
<ItemContent>
<ItemLabel>Profile</ItemLabel>
<ItemDescription>Manage your account</ItemDescription>
</ItemContent>
<ItemAction>
<ChevronRight className="size-4 text-muted-foreground" />
</ItemAction>
</Item>Specs
# Mint — Item Specs
## Component
- name: item
- file: registry/mint/item.tsx
- installs to: components/ui/item.tsx
- dependencies: radix-ui
- registryDependencies: none
## What is it
A composable flex row used as a building block for lists, settings panels,
navigation drawers, and notification feeds. Provides consistent spacing,
icon sizing, and trailing-action alignment without coupling to a specific
semantic element. Use Item when you need a reusable row with an optional
icon, label, description, and trailing slot. Do not use it as a standalone
interactive element — apply interactivity via asChild.
## Visual identity
Calm, low-profile layout with a soft mint tint. The icon slot uses --muted as
a green-tinted square container, keeping emphasis on the label. No border or
shadow by default — density and containment are added by the surrounding
list wrapper.
## Design tokens
--muted: oklch(0.96 0.02 155) / oklch(0.2 0.03 155) — ItemIcon background
--muted-foreground: oklch(0.52 0.06 155) / oklch(0.6 0.06 155) — ItemIcon icon colour, ItemDescription text
## Sub-components
- Item → root flex row (flex items-center gap-3 py-2.5); supports asChild
- ItemIcon → size-9 square container, bg-muted, auto-sizes child SVG to size-4
- ItemContent → flex-1 min-w-0 column; wraps ItemLabel and ItemDescription
- ItemLabel → text-sm font-medium leading-none primary text line
- ItemDescription → text-xs text-muted-foreground mt-1 truncate secondary line
- ItemAction → ml-auto trailing slot for icons, badges, switches, or buttons
## States
- asChild / interactive: hover and focus styles must be applied on the child element directly; Item provides no built-in hover or focus styles
## Conventions
- Sub-components expose data-slot="item", data-slot="item-icon", data-slot="item-content", data-slot="item-label", data-slot="item-description", data-slot="item-action" for CSS targeting
- Use asChild with <button> or <a> to get correct semantics and interactivity
- Wrap multiple items in <div className="divide-y"> for bordered list rows
- Add px-4 to Item when inside a bordered card or panel
- Use border rounded-lg on the wrapping div for a contained list appearance
- ItemIcon is optional — omit it to push ItemContent to the leading edge
- ItemDescription truncates long text automatically; do not nest block elements inside itInstallation
$ npx shadcn add \https://gin-design.vercel.app/item