Badge
Compact label for status, category, or metadata. Supports solid and dot variants with Tailwind colors.
Installation
npx shadcn@latest add https://www.fluidfunctionalism.com/r/badge.jsonSolid
FictionSciencePhilosophyHistoryPoetry
Dot
FictionSciencePhilosophyHistoryPoetry
Sizes
SmallMediumLarge
Colors
GrayRedOrangeAmberYellowLimeGreenEmeraldTealCyanBlueIndigoVioletPurpleFuchsiaPinkRose
GrayRedOrangeAmberYellowLimeGreenEmeraldTealCyanBlueIndigoVioletPurpleFuchsiaPinkRose
API Reference
| Prop | Type | Default | Description |
|---|---|---|---|
| variant | "solid" | "dot" | "solid" | Visual style. Solid uses a tinted background; dot shows a colored indicator. |
| size | "sm" | "md" | "lg" | "md" | Size of the badge. |
| color | BadgeColor | "gray" | Color from the Tailwind palette: gray, red, orange, amber, yellow, lime, green, emerald, teal, cyan, blue, indigo, violet, purple, fuchsia, pink, rose. |