A compact status label with solid, muted, and dot variants for tagging content inline.
Dependencies
Interaction Type
Static label by default; supports a shimmer wave on solid badges, a pulsing status dot, dismissible chips, and click interactivity.
Props
Options you can pass to customize this component.
variantVisual style. Defaults to "solid".
sizeBadge size. Defaults to "md".
iconLeading decorative icon (solid/muted variants).
shimmerSolid variant only: a soft light wave sweeps across the badge (default: true). Disabled under reduced motion.
pulseDot variant only: softly pulses the status dot (default: false). Disabled under reduced motion.
onDismissRenders a trailing remove button and calls back on activation.
dismissLabelAccessible label for the remove button (default: "Remove").
asChildMerge badge styling onto the child element (Slot pattern).
classNameAdditional CSS classes.
Installation
How to use
import { Badge } from "@/components/ui/badge"
export function Demo() {
return (
<div className="flex items-center gap-2">
<Badge>New</Badge>
<Badge variant="muted">Beta</Badge>
<Badge variant="dot" pulse>Live</Badge>
<Badge variant="muted" onDismiss={() => console.log("removed")}>
Filter
</Badge>
</div>
)
}Source Code
Click the code icon in the top-right corner to view the source code.
License & Usage
// No code loaded.This update isEarly Accessand ready to ship.