CircularProgress
Migration guide for CircularProgress from HeroUI v2 to v3 (now ProgressCircle)
Refer to the v3 ProgressCircle documentation for complete API reference, styling guide, and advanced examples. This guide only focuses on migrating from HeroUI v2.
Looking for the Progress (linear) migration? See the Progress migration guide.
Component Rename
CircularProgress has been renamed to ProgressCircle in v3.
Structure Changes
In v2, CircularProgress was a single component configured with props:
import { CircularProgress } from "@lenso/ui";
export default function App() { return ( <CircularProgress label="Loading..." value={60} /> );}In v3, ProgressCircle uses a compound component pattern:
import { ProgressCircle } from "@lenso/ui";
export default function App() { return ( <ProgressCircle aria-label="Loading" value={60}> <ProgressCircle.Track> <ProgressCircle.TrackCircle /> <ProgressCircle.FillCircle /> </ProgressCircle.Track> </ProgressCircle> );}Key Changes
1. Component Structure
v2: Single CircularProgress component with internal SVG rendering
v3: Compound components: ProgressCircle, ProgressCircle.Track (SVG element), ProgressCircle.TrackCircle (background circle), ProgressCircle.FillCircle (progress arc)
2. Colors
v2: default, primary, secondary, success, warning, danger
v3: default, accent, success, warning, danger
3. Prop Changes
| v2 Prop | v3 Equivalent | Notes |
|---|---|---|
value | value | Same |
minValue | minValue | Same |
maxValue | maxValue | Same |
isIndeterminate | isIndeterminate | Default changed: true in v2 → false in v3 |
formatOptions | formatOptions | Same |
size | size | Same (sm, md, lg) |
color | color | primary → accent, secondary removed |
label | - | Use Label component |
valueLabel | - | Use render prop pattern |
showValueLabel | - | Place value content inside ProgressCircle |
strokeWidth | - | Set strokeWidth directly on ProgressCircle.TrackCircle and ProgressCircle.FillCircle |
isDisabled | - | Removed |
disableAnimation | - | Removed |
classNames | - | Use className on individual compound components |
Migration Examples
Basic CircularProgress
import { CircularProgress } from "@lenso/ui";
<CircularProgress aria-label="Loading..." value={60} />Indeterminate
<CircularProgress aria-label="Loading..." />{/* isIndeterminate defaults to true in v2 */}With Label
<CircularProgress label="Loading..." value={70} showValueLabel size="lg"/>Custom SVG Props
<CircularProgress value={60} strokeWidth={6} aria-label="Loading"/>Styling Changes
v2: classNames Prop
<CircularProgress classNames={{ base: "custom-base", svg: "custom-svg", track: "custom-track", indicator: "custom-fill", label: "custom-label", value: "custom-value", }}/>v3: Direct className Props
<ProgressCircle className="custom-base" value={60}> <ProgressCircle.Track className="custom-svg"> <ProgressCircle.TrackCircle className="custom-track" /> <ProgressCircle.FillCircle className="custom-fill" /> </ProgressCircle.Track></ProgressCircle>Component Anatomy
ProgressCircle (Root) └── ProgressCircle.Track (SVG element) ├── ProgressCircle.TrackCircle (background circle) └── ProgressCircle.FillCircle (progress arc)Summary
- Renamed:
CircularProgress→ProgressCircle - Component Structure: Single component → compound components (
ProgressCircle.Track,ProgressCircle.TrackCircle,ProgressCircle.FillCircle) - Indeterminate Default Changed:
isIndeterminatedefaults tofalsein v3 (wastruein v2) - Label:
labelprop →Labelcomponent - SVG Props:
strokeWidthon root → set directly onTrackCircleandFillCircle - Color Changes:
primary→accent,secondaryremoved - Removed Props:
isDisabled,disableAnimation→ use Tailwind CSS - ClassNames Removed: Use
classNameon individual compound components