CategoryPill
ImplementedTicket-category pill (Diamond, Platinum, Silver, Gold, CAT 1/2/3). Distinct from StatusBadge (state) — encodes categorization only. Tints derived via color-mix() from existing CSS variables so dark-mode adapts automatically.
patterns/molecules/categorypill.htmlStatic ticket-category badge (dot + label) for Diamond, Platinum, Silver, Gold and CAT 1–3. Categorization only — not a state badge and not an interactive filter chip.
CategoryPill
Display molecule (Tier 1)
Renders a rounded-full pill: a decorative color dot (aria-hidden) plus the category label. Colors come from existing brand tokens tinted via color-mix() (ADR-027) — no raw values, and dark mode adapts automatically.
This component supports light and dark mode.
Usage
category is required — the pill always names a concrete category. CategoryPill is a plain <span>: it renders text, it is not focusable, and it carries no aria-pressed or role="radio" semantics. It is not a filter control.
import { CategoryPill } from '@epasslive/design-system'
<CategoryPill category="gold" />
<CategoryPill category="diamond" label="VIP Diamond" />
<CategoryPill category="cat1" label="CAT 1 — Floor" />Which pill? (4-way disambiguation)
Four DS components look like "a colored pill with a label". Pick by semantics, not by shape:
Metallic-name trap: platinum/silver/gold exist on both SeasonPassBadge (loyalty tier) and CategoryPill (ticket category). If the value describes who the holder is, use SeasonPassBadge; if it describes which ticket tier this is, use CategoryPill.
Localization
Default labels are English proper nouns rendered from the component (Diamond, Platinum, Silver, Gold, CAT 1–CAT 3). The label prop is the localization hook — pass the translated term from your catalog. The component itself has no i18n strings (no interactive/aria copy), so no DS translation keys are needed.
// FR <CategoryPill category="gold" label="Or VIP" /> <CategoryPill category="diamond" label="Diamant" />
Dark mode
Backgrounds and borders are 8%/20% tints computed at runtime via color-mix(in oklab, var(--ep-*) N%, transparent) — when the referenced tokens swap in dark mode, the tints adapt automatically (ADR-027). Every referenced token (--ep-amber, --ep-blue, --ep-pink, --ep-neutral-500, --ep-border-strong) has a dark override in globals.css.
Accessibility
Static display element — the accessible name comes from the visible label text content (the decorative dot is aria-hidden). There is deliberately no aria-label on the generic span (axe aria-prohibited-attr) and no interactive role: this is not a filter control. Keep it inside the reading order next to the item it categorizes.
Props
category*'diamond' | 'platinum' | 'silver' | 'gold' | 'cat1' | 'cat2' | 'cat3'Category key — drives the dot color and the token tint of the pill background/border.
labelstringOverride the visible label. Localization hook — defaults are English proper nouns (Diamond, Platinum, Silver, Gold, CAT 1, CAT 2, CAT 3). Pass the translated term, e.g. "Or VIP".
classNamestringAdditional CSS classes appended to the pill container.
Props
CategoryPill
category'diamond' | 'platinum' | 'silver' | 'gold' | 'cat1' | 'cat2' | 'cat3'—Category key — drives the dot color and the tint background (dark-mode adapts via color-mix()).
labelstringsentence-case category nameOverride the default label — the localization hook (defaults are EN proper nouns; pass e.g. "Or VIP").
classNamestring—Additional CSS classes.
<CategoryPill />Accessibility
ARIA
1 ruleType
1 ruleUsage
Import
import { CategoryPill } from "@epasslive/design-system"Example 1
<CategoryPill category="gold" />Example 2
<CategoryPill category="diamond" label="VIP Diamond" />Anti-patterns
— Do not use for state (paid/refunded) — that is StatusBadge's domain
— Do not wire click handlers onto it — it renders spans, not a control