Components
Pill
Pills label, categorise, or tag content. Use them to highlight short status or metadata.
Stable
GitHubPill
Anatomy
Anatomy
import {Pill} from '@staffbase/design';
<Pill />;Examples
Variants
Solid
Outline
Colors
Primary
Critical
Success
Warning
Neutral
Teal
Purple
Pink
Cyan
Yellow
Primary
Critical
Success
Warning
Neutral
Teal
Purple
Pink
Cyan
Yellow
API reference
| Name | Type | Description |
|---|---|---|
children | ReactNode | Content rendered inside the pill. |
variant | solidoutline | Visual style of the pill. Default: solid |
color | primarycriticalsuccesswarningneutraltealpurplepinkcyanyellow | Colour of the pill. Default: primary |
When to use
When not to use
How to use
Variants
Solid
Outline
Color
| Color | Meaning / use |
|---|---|
neutral |
Default, non-status labels and categories |
primary |
Highlighted, featured or in-between state, such as Scheduled or Pending |
success |
Positive or completed state, such as Published, Approved, or Sent |
warning |
Needs attention |
critical |
Negative or blocking state, such as Removed, Failed, or Unpublished |
teal purple pink cyan yellow |
Categorical color-coding only, when hue distinguishes categories |
Icon & label
Approved
Scheduled
Public
Layout & spacing
Published
Scheduled
Draft
Accessibility
Content & UX copy
Do
Draft
Published
Processing
Short, Title Case status labels.
Don't
this is a draft
it has been published to everyone
Full sentences and lowercase copy.