Progress
How far a task has got. The fill draws along a thin track, a sheen runs over it while it works, a piece slides across while the length is unknown, and the value turns into a tick when it is done.
Examples
Default
Put a ProgressLabel and a ProgressValue inside, and they sit in a row above the track. While it runs, a sheen sweeps the fill; once done, the value turns into a tick.
Indeterminate
Give null while nobody knows how long it takes, and a piece slides across. Give a number once you know, and the fill draws in. completeLabel names what it says when done.
No visible label
Leave out the children and name it with aria-label, for a row that already shows its name. variant="destructive" marks a task that failed; say so in words beside it.
Installation
npx shadcn@latest add https://kinoui.com/r/progress.json- Files
lib/reduce-motion.tslib/track.tscomponents/kino/progress.tsx- Packages
@base-ui/react- Global CSS
- the feels, the density tokens, the shape tokens and the success and warning colours
New to Kino? Installation covers what your project needs first and the @kino namespace.
API reference
Progress
ProgressValue
Data attributes
CSS variables
Accessibility
- It is a
progressbar, named byProgressLabelor byaria-label. Screen readers read the value as a percentage, or asgetAriaValueTextwrites it. - The value and the tick in the row are for sighted users and are hidden from screen readers, which read the progress bar itself.
- A failed task shows red: say it failed in text too, and in
getAriaValueText, so the colour is never the only sign. - In forced colours the fill takes the system highlight and the track gets an outline.
- When the system asks for less motion, the fill jumps to the value, the sheen is off, and while the length is unknown the whole track pulses instead of a piece sliding.