Installation

Terminal
pnpm add @choice-ui/progress-bar

Import

Component.tsx
import { Component } from "@choice-ui/progress-bar"

Basic

Basic: Shows the default ProgressBar with label and value.
- Demonstrates composite API usage with `ProgressBar.Label`, `ProgressBar.Track`, and `ProgressBar.Connects`. - Displays current progress value via `showValue`. - Use for simple linear progress indications.

Sizes

Sizes: Demonstrates the two size options available.
- `size="small"` for compact contexts. - `size="default"` (default) for compact contexts. - `size="large"` for more prominent progress indicators.
Small
Default
Large

Variants

Variants: Demonstrates theme-driven color variants.
- Uses theme tokens for `accent`, `success`, `warning`, `danger`, and `inverse`. - Choose the variant that matches the semantic meaning of the progress.
accent
default

Striped And Indeterminate

Striped & Indeterminate: Shows a striped progress and an indeterminate state.
- `striped` adds a subtle moving texture for ongoing processes. - `indeterminate` renders without a known value; useful for unknown durations.
Striped
Indeterminate

Based On Value

Based-on-value: Demonstrates continuous color blending driven by `value`.
- Set `variant="based-on-value"` and provide `dynamicColors`. - Accepts either an array of colors (evenly spaced) or stops with `{ at, color }`. - Colors are smoothly mixed between stops using the current progress value.
Evenly spaced colors
Custom stops (at)
Value: 35