Skip to content

components/bits/StatusDot#

resolveTone()#

function resolveTone(status): StatusTone;

A tone passes through; anything else is a backend word.

Parameters#

Parameter Type
status string

Returns#

StatusTone


StatusDot()#

function StatusDot(props): Element;

A status dot — the smallest way to say "this thing is in state X".

Replaces the bespoke borderRadius: '50%' Boxes scattered through the app, each with its own diameter and its own idea of what green means.

Parameters#

Parameter Type
props StatusDotProps

Returns#

Element


StatusDotProps#

Properties#

label?#

optional label?: string;

Tooltip and accessible name. Without it the dot is decorative.

pulse?#

optional pulse?: boolean;

Slow pulse, for a genuinely in-flight state.

ring?#

optional ring?: boolean;

A ring of the app ground around the dot, so it stays legible when it overlaps an icon or an avatar.

size?#

optional size?: "sm" | "md" | "lg";

6 / 8 / 10px. The scale exists so dots line up across surfaces.

status#

status: string;

Either a tone directly, or a raw backend status word to be normalised by statusToToken ('RUNNING', 'ERROR', 'completed', …).

sx?#

optional sx?: any;