Skip to content
Feedback

Progress

How far along something is. Leave value out when you can't tell.

import { Progress } from "@flinbu/seed";

Determinate, custom text and indeterminate

Uploading tokens40%
Storage9.2 of 10 GB
Syncing with Figma
import { Button, Progress } from "@flinbu/seed";

const [v, setV] = React.useState(40);

<div className="flex w-full max-w-sm flex-col gap-base">
  <Progress value={v} label="Uploading tokens" showValue />
  <Progress value={9.2} max={10} label="Storage" showValue valueText="9.2 of 10 GB" variant="warning" />
  <Progress label="Syncing with Figma" size="sm" />
  <Button size="sm" variant="secondary" onClick={() => setV((x) => (x >= 100 ? 0 : x + 20))}>Add 20%</Button>
</div>

Use it for

  • Uploads, imports, usage against a limit.

Props

PropTypeDefaultDescription
valuenumber | nullnoneOmit for an indeterminate bar.
maxnumber100Top of the scale.
labelReactNodenoneNames the bar.
showValuebooleannoneShows the percentage or valueText.
valueTextstringnoneReplaces the percentage, e.g. 9.2 of 10 GB.
variant'accent' | 'success' | 'warning' | 'error''accent'Bar color.
size'sm' | 'md''md'4 or 8 px tall.

Accessibility

  • Built on Radix Progress: role progressbar with aria-valuenow and a readable valuetext.
  • The label names the bar.