Progress: Segments
Pass segments to split the fill into parts, such as passed, failed and skipped tests. Each part eases on its own and pushes the parts after it, and their labels are read out with the value.
Running tests
This adds the example as components/examples/progress/segments.tsx, together with the Progress component and the HextaUI theme tokens it needs.
pnpm dlx shadcn@latest add https://hextaui.com/r/progress-segments.jsonTo add only the component, follow the Progress installation.
Props in this example
The Progress props this example sets, from the API reference.
| Prop | Type | Default |
|---|---|---|
max | number | 100 |
segmentsSplits the fill into parts. Their sum becomes the value. | { value: number; variant?: ProgressVariant; label?: string }[] | – |
Every prop is in the Progress API reference.
- Sizes
- Status
- Indeterminate
- Circle
- Indeterminate circle
- Custom range and format
- Animated value
- Long labels
- Without a visible label
- Right to left
See them all, with keyboard support and accessibility notes, on the Progress page.
- AlertInline messages for status and feedback, with a neutral surface, a colored icon and a dismiss that collapses smoothly.
- EmptyA placeholder for screens with nothing to show yet, with an icon, a message and the next action.
- SkeletonPlaceholders that wait 150ms before showing, take the exact size of the content they wrap, and fade it in without moving anything.
- SpinnerA loading indicator with Apple-style ticks or a breathing ring that can wait before showing and stay long enough not to flicker.
- ToastBrief messages that stack neatly, expand on hover, swipe away, and turn a loading state into success or error in place.
- AttachmentFile and image cards for uploads, with progress, states, actions, a full-card trigger and names that keep their extension.