Components
- Accordion
- Alert
- Alert Dialog
- Aspect Ratio
- Avatar
- Badge
- Breadcrumb
- Button
- Button Group
- Calendar
- Card
- Carousel
- Chart
- Checkbox
- Code Block
- Collapsible
- Combobox
- Command
- Context Menu
- Copy Button
- Data Table
- Date Picker
- Dialog
- Drawer
- Dropdown Menu
- Empty
- Field
- Form
- Hover Card
- Input
- Input Group
- Input OTP
- Item
- Kbd
- Label
- Menubar
- Native Select
- Navigation Menu
- Page Header
- Pagination
- Panel
- Popover
- Progress
- Radio Group
- Resizable
- Scroll Area
- Section Header
- Select
- Separator
- Sheet
- Sidebar
- Skeleton
- Slider
- Sonner
- Spinner
- Stat
- Stat Card
- Switch
- Table
- Tabs
- Textarea
- Theme Toggle
- Toggle
- Toggle Group
- Tooltip
- Typography
Stat
Composable metric primitive with value, label, and delta.
$45,231
Revenue
01
Installation
Add the stat component with the shadcn CLI.
bash
npx shadcn@latest add https://swiss.ui.unsanity.ai/r/stat.json02
Usage
tsx
import { Stat } from "@/components/ui/stat"03
Examples
With delta
StatDelta in the signal accentActive users
2,350
+12.4%
import { Stat, StatDelta, StatLabel, StatValue } from "@/components/ui/stat"
<Stat>
<StatLabel>Active users</StatLabel>
<StatValue>2,350</StatValue>
<StatDelta>+12.4%</StatDelta>
</Stat>Row
Compose into a grid71
Components
1
Signal
0
Radius
import { Stat, StatLabel, StatValue } from "@/components/ui/stat"
<div className="grid grid-cols-3 gap-px bg-border">
<Stat className="bg-background p-4">
<StatValue>71</StatValue>
<StatLabel>Components</StatLabel>
</Stat>
{/* ... */}
</div>