Badge

A compact label for a status, a count or a category.

Sizes and shape

Two sizes: sm for dense rows, md elsewhere. pill rounds the ends fully, at either size.

Content

icon takes a Phosphor icon component, drawn before the label. children also takes a string, for badges built from data at runtime.

Links

With href the badge renders as an anchor.

Custom colours

--badge-color, --badge-bg and --badge-border restyle one badge without a new variant.

Examples

Small and medium
Small Medium
Pills at both sizes
Default pill Small pill
Leading icons
Passed Failed
A label from a string
Active Verified
A link badge
Status colours from the badge variables
Success Danger