Browse the docs

Count & StatusDot

Round count stickers and little status dots.

Server ComponentWCAG AASince v0.1

Live example

312OnlineOn a callOffline

Change every prop live in the playground.

Props

Count

PropTypeDefaultWhat it does
childrenrequiredstring | numbernoneThe number shown. Screen readers hear label instead.
labelrequiredstringnoneWhat the number means, read by screen readers: "3 unread". Required, because a bare number says nothing.
classNamestringnoneExtra class on the sticker.
size"sm" | "md"mdsm fits inside tabs and buttons.
tone"ink" | "tomato"tomatoFill: tomato for attention, ink for plain counts.

StatusDot

PropTypeDefaultWhat it does
childrenrequiredReactNodenoneThe words are the status; the dot only repeats it.
classNamestringnoneExtra class on the wrapper around the dot and words.
tone"online" | "busy" | "offline"onlineSets the dot color: online, busy or offline.

Use it well

DoSay what the number counts in the label: "3 unread".
Don'tShow a dot without its words.

Accessibility

  • A Count needs a label; a bare number says nothing.
  • A StatusDot always has its words next to it.
Five stamps!

All aboard.

You took the whole tour. Here's Holo Pip, a foil sticker for riders who finish. It's in your playground tray now, for good.