AppProgress
How far a task has got: role progressbar with aria-valuenow, aria-valuemin and aria-valuemax, or indeterminate when the amount is unknown. The bar fills on a transform (scaleX from the start edge, so RTL fills from the right), as AppPageLoader does; the circular variant draws its arc with stroke-dashoffset. A label names it, the value can show as text, and format turns the number into words for both the screen and aria-valuetext. Tones are colour only, so the label says what the colour means.
Install: pnpm add-component AppProgress
Basic usage
format names the value: a screen reader hears "3 of 8 files", not "38%".
Tones
The colour backs up the label; it never stands in for it.
Sizes
Indeterminate
Leave value out while the amount is unknown: aria-valuenow is dropped. Under reduced motion the sweep and the spin become a slow fade.
Circular
The value sits inside the ring at md and lg, and beside it at sm.
API
value(number | null): The current value, clamped to min and max. null or left out: indeterminate.min(number): Start of the range.max(number): End of the range.label(string): Visible name above the bar or beside the ring. Without one, pass aria-label.showValue(boolean): Show the value as text: a percentage, or what format returns.format((value: number, ratio: number) => string): Words for the value ("3 of 8 files"), on screen and as aria-valuetext.tone('accent' | 'success' | 'warning' | 'danger' | 'info'): Fill colour. Say what it means in the label.size('sm' | 'md' | 'lg'): Bar thickness (4, 8, 12px), or ring diameter (1.5, 2.5, 4rem). A small ring puts its value beside it.variant('bar' | 'circular'): A track that fills, or a ring.