Skip to content
Style Guide
v0.1.0

Components

Badges

Small pill labels for status and counts. A badge annotates something else on the screen — it is never a control, and it never carries meaning on colour alone.

Variants

Neutral Solid Outline Online Low battery Offline Updating
Badge variants

Neutral is the default and the right choice most of the time. Reach for a status variant only when the state genuinely maps to success, warning, error or information — a badge that is green because green looks nice teaches people to ignore green.

Status dots

A dot adds a second visual signal. It is decoration, not information — the word beside it is what carries the meaning, which is what keeps the badge readable in greyscale.

Online Low battery Offline Unknown
With dots
Never a bare dot. A coloured dot with no label is meaningless to anyone who cannot distinguish the hues, and unreadable to a screen reader. If space is genuinely too tight for a word, the layout needs fixing, not the badge.

Counts

A count badge sits on a navigation item or a button. The number alone means nothing out of context, so pair it with visually hidden text that says what is being counted.

Counts

Cap large numbers at "99+" so the pill does not stretch the control it sits on, and put the true figure in the hidden text. Hide the badge entirely at zero rather than showing a "0".

Counts use tabular figures, so a badge does not change width as the number ticks between 11 and 12.

In context

Front door lock

Locked

Last changed 14:20 by Yaman

Badge in a card header

Badges also appear in table cells — see Tables — and beside navigation items. Wherever they go, they annotate the thing next to them and are never the thing itself.

Badges, chips and buttons

All three are pill-shaped in this system, which makes it easy to reach for the wrong one.

If it…Use
Describes something else on screen and is not clickableA badge
Can be pressed to do somethingA button — Buttons
Can be removed, or filters a listA button. The system has no chip component yet; use .tmt-btn--secondary.tmt-btn--sm.
Is a page-level messageAn alert — Alerts

A badge is a <span>. If you find yourself adding a click handler to one, it should have been a button.

Do and don't

Do

  • Use one or two words.
  • Keep the same label for the same state everywhere in the product.
  • Add hidden text to any badge whose meaning depends on what it sits next to.
  • Default to neutral.

Don't

  • Put a sentence in a badge.
  • Use a bare coloured dot as a status.
  • Line up five badges on one row — that is a table of attributes.
  • Make a badge clickable.