Ravox KitBasics

Progress

Progress bar with a label and value wired to it. Without a value, it is indeterminate while the remaining amount is unknown. The steps variant shows where the person is in a sign-up, checkout or import.

Armazenamento usado

Settings

Tipo
Espessura
Cor
Toggles

Examples

File upload

Enviando fotos do produto

Multi-step sign-up

Step 2 of 4: Loja

  1. Conta (completed)
  2. Loja (current)
  3. Pagamento
  4. Revisão

Unknown remaining time

Conectando ao banco

Goals on a dashboard

Vendas de setembro
Vagas do workshop
Backup de hoje

Installation

The command creates components/ui/progress.tsx in your project and installs the theme with it. The file is yours: edit it as you like.

npx @ravox-ui/cli add progress

Props

PropTypeDefaultDescription
valuenumber | null—From 0 to max. Without a value (or null), the bar is indeterminate.
maxnumber100Value that fills the bar (e.g. total files).
labelReactNode—Text above the bar, which becomes its name for screen readers.
showValuebooleanfalseShows the value on the right of the label.
format(value, max) => string42%Text of the value, also used in aria-valuetext ("3 of 8 files").
thickness"sm" | "md" | "lg""md"4, 8 or 12px.
color"default" | "pink" | "yellow" | "lime" | "blue""default"Fill color. The default is the text color.
ProgressSteps steps / currentstring[] / number—Names in order and the index of the current step (0 is the first; steps.length = all done).
ProgressSteps showLabelsbooleantrueName of each step below. In narrow space only "Step 2 of 4: Payment" shows.

More in Basics