Skip to content

Signal

Components

Chip

Small labels: route type, change type, metadata. Variants: --muted, --accent, --solid, --inverse, --outline, --good, --warn, --alert, --critical, --highlight; --sm is the changelog size.

Live example

Rendered with the real classes from /site/chitransit.css, light (left) and dark (right).

Train.ct-chip
Bus.ct-chip--muted
feat.ct-chip--accent
release.ct-chip--solid
api.ct-chip--inverse
app.ct-chip--outline
perffixbreaking.ct-chip--good · --warn · --alert
breaking.ct-chip--critical
Coming soonNew.ct-chip--highlight
apifeatfixv1.4.0.ct-chip--sm
a1b2c3.ct-chip--mono

Code

<span class="ct-chip">Train</span>
<span class="ct-chip ct-chip--muted">Bus</span>
<span class="ct-chip ct-chip--accent">feat</span>
<span class="ct-chip ct-chip--solid">release</span>
<span class="ct-chip ct-chip--inverse">api</span>
<span class="ct-chip ct-chip--outline">app</span>
<span class="ct-chip ct-chip--good">perf</span><span class="ct-chip ct-chip--warn">fix</span><span class="ct-chip ct-chip--alert">breaking</span>
<span class="ct-chip ct-chip--critical">breaking</span>
<span class="ct-chip ct-chip--highlight">Coming soon</span><span class="ct-chip ct-chip--sm ct-chip--highlight">New</span>
<span class="ct-chip ct-chip--sm ct-chip--inverse">api</span><span class="ct-chip ct-chip--sm ct-chip--accent">feat</span><span class="ct-chip ct-chip--sm ct-chip--warn">fix</span><span class="ct-chip ct-chip--sm ct-chip--solid">v1.4.0</span>
<span class="ct-chip ct-chip--sm ct-chip--muted ct-chip--mono">a1b2c3</span>

Tokens

From tokens/components.tokens.json. Override one instance by setting the property without the ct- prefix.

Custom propertyValueAliasResolves to
--ct-chip-backgroundvar(--card-2){colors.card2}#E9EBF1 #1F2733
--ct-chip-colorvar(--ink){colors.ink}#101A2E #EEF1F6
--ct-chip-font-sizevar(--size-chip-text){size.chipText}12 pt
--ct-chip-font-size-smvar(--fs-cap){type.cap}12
--ct-chip-font-weightvar(--weight-semibold){weight.semibold}600
--ct-chip-font-weight-smvar(--weight-semibold){weight.semibold}600
--ct-chip-heightvar(--size-chip-height){size.chipHeight}22 pt
--ct-chip-height-smvar(--size-chip-height-small){size.chipHeightSmall}20 pt
--ct-chip-outline-widthvar(--size-focus-ring-width){size.focusRingWidth}2.5 pt
--ct-chip-outline-width-sm1.5px
--ct-chip-padding-xvar(--space-8){space.s8}8 pt
--ct-chip-padding-x-sm7px
--ct-chip-radiusvar(--radius-chip){radius.chip}6 pt
--ct-chip-tracking-sm.02em

Variants

Color: --muted, --accent, --solid, --inverse, --outline, --good, --warn, --alert, --critical, --highlight; with none, the chip is the Card 2 default. Size --sm (the changelog badge); --mono for codes. Nothing else exists.

  • A status word: --good, --warn or --alert; --critical only for an outage.
  • New or coming soon: --highlight.
  • A neutral label (route type, metadata): the default or --muted.
  • Emphasis on a busy surface: --solid or --inverse.
<!-- Do -->
<span class="ct-chip ct-chip--good">On time</span>
<!-- Don't: a raw color, or a variant that doesn't exist -->
<span class="ct-chip" style="background:#2ec4b6">New</span>
<span class="ct-chip ct-chip--success">On time</span>

Usage

Do

  • Use chips for small metadata labels: route type, change type.
  • Pick a variant for emphasis: --muted, --accent, --solid, --inverse, --outline.
  • Use --sm for dense lists such as the changelog (repository, change type, release, breaking); --critical marks a breaking change.
  • Use --highlight to call out information such as a new or coming-soon feature.
  • Use --muted for a type pill (Station, Route, Stop) beside a search result.

Don't

  • Don't use a status variant (--good, --warn, --alert) without a status word.
  • Don't use --highlight for a status or a line; it only calls out information.
  • Don't use line colors on chips; line color means a line.

Accessibility

  • Chips are static text. Interactive filters use the route toggle or segmented control.