Progress
A progress indicator for displaying task completion. Consists of a track (background bar), an indicator (filled portion), and an optional label area.
// Minimum invocation — just a value.<Progress value={60} />
// Pair the value with a descriptive label and a right-aligned hint.<Progress value={42} label="Uploading files…" hint="3 of 7" />
// tone="info" re-tints every internal color via the --*-info token cascade.<Progress value={75} tone="info" label="Processing" />
// The host pre-declares border colour + style with width 0 — give it any// width to opt in; the colour auto-tracks the tone.<Progress value={60} label="Uploading" hint="3 of 5" style={{ borderBottomWidth: '1px' }} />
// Animate by driving `value` over time.function AnimatedProgress({ speed = 1 }) { const [v, setV] = useState(0) useEffect(() => { const id = setInterval(() => setV((x) => (x + speed) % 101), 50) return () => clearInterval(id) }, [speed]) return <Progress value={v} label="Animated" />} Playground
Preview
value
max
tone
label
hint
className
style
children
Component props
| Prop | Type | Default | Description |
|---|---|---|---|
| value | number | — | Current progress value. Negative values are clamped to 0. |
| hint? | string | — | Right-aligned hint text (e.g. "3 of 7"). |
| label? | string | — | Text label displayed after the percentage. |
| max? | number | 100 | Upper bound of the range. |
| tone? | neutralinfo | neutral | Color variant. 'info' applies a blue tint. |
Inherited props (children, className, id, style, tabIndex, title)
| Prop | Type | Default | Description |
|---|---|---|---|
| children? | ReactNode | — | Child elements. When provided, replaces the component's default label/content. |
| className? | string | — | CSS class name. Merged with any internal classes by the component. |
| id? | string | — | HTML id attribute. |
| style? | CSSProperties | — | Inline styles applied to the root element. |
| tabIndex? | number | — | Tab order. Set to -1 to skip the element when tabbing. |
| title? | string | — | HTML title attribute — native browser tooltip on hover. |
Component tokens
Progress exposes these CSS custom properties as its theming surface. Override any of them in consumer CSS to retint a single instance, or set them on a [tone="…"] selector to add a new tone variant. Tokens marked (shadow-only API) style elements inside the shadow DOM and can only be customized via these properties — consumer CSS can’t reach those elements directly.
| Token | Description |
|---|---|
--progress-bg | Host background (the track behind the indicator). |
--progress-border-color | Host border colour. Also one endpoint of the indicator-edge gradient. |
--progress-indicator-bg (shadow-only API) | Indicator fill colour. Also the start endpoint of the indicator-edge gradient. |
--progress-indicator-edge (shadow-only API) | Gradient painted at the indicator’s right edge. Defaults to linear-gradient(90deg in oklch, var(--progress-indicator-bg), var(--progress-border-color)). |
--progress-text-color | Colour of the percentage number and the label text. |
--progress-hint-color | Colour of the right-aligned hint text. |