chrome
<tc-progress>
Linear or circular progress indicator. Determinate or indeterminate, three sizes, optional inline label.
import
"@ra9/tan-compose-kit/progress"
Props
| Name | Type | Default | Description |
|---|---|---|---|
value | number | 0 | Current progress, between 0 and `max`. Ignored when `indeterminate` is true. |
max | number | 100 | Maximum value. |
variant | "linear" | "circular" | "linear" | Shape. |
size | "sm" | "md" | "lg" | "md" | Linear height or circular diameter. |
indeterminate | boolean | false | Cycle indefinitely. Use while waiting for a value to land. |
showLabel | boolean | false | Show the percent (or `label`) inline. |
label | string | "" | Override the auto-generated label. |
CSS variables
| Variable | Default | Description |
|---|---|---|
--tc-progress-track | var(--tc-color-rule, #ece5d3) | Track color. |
--tc-progress-fill | var(--tc-color-accent, #a16939) | Fill color. |
--tc-progress-radius | 999px | Corner radius. |
--tc-progress-fg | var(--tc-color-ink, #14171f) | Label color. |
--tc-progress-font | var(--tc-font-mono, …) | Label font. |
Examples
Linear
Indeterminate
Useful while the page is waiting for a value to arrive — uploads, deploys, dependent fetches.
Circular
Custom max
Driving from JS
Accessibility
role="progressbar"witharia-valuenow / valuemin / valuemax(determinate) oraria-valuetext(indeterminate) is wired up for you.- For longer operations, pair with a live region announcement of milestones (e.g., "Uploaded 50%") so screen-reader users get progress feedback without watching the bar.
prefers-reduced-motion: reduceslows indeterminate animation rather than disabling it.