Skip to content

feat: add indeterminate ProgressCircle#501

Merged
adrienzheng-cb merged 9 commits intomasterfrom
adrien/indeterminate-progress-circle
Mar 29, 2026
Merged

feat: add indeterminate ProgressCircle#501
adrienzheng-cb merged 9 commits intomasterfrom
adrien/indeterminate-progress-circle

Conversation

@adrienzheng-cb
Copy link
Copy Markdown
Contributor

@adrienzheng-cb adrienzheng-cb commented Mar 13, 2026

What changed? Why?

feat: add indeterminate ProgressCircle, unify progress size and float-label math

  • Add indeterminate prop to ProgressCircle (web & mobile): spinning state with
    configurable weight, default stroke ratio 0.11; animate full SVG on mobile,
    CSS keyframes on web; hide default content when indeterminate.
  • Add getProgressSize(weight) in common and deprecate useProgressSize; use
    getProgressSize in ProgressBar and ProgressCircle on both platforms.
  • Simplify ProgressBarWithFloatLabel (web & mobile): remove usePreviousValues,
    useIsoEffect, and imperative animation; use shared getEndTranslateX so float
    label trailing edge follows fill end (containerWidth * progress - textWidth);
    web uses useMotionProps + MotionBox, mobile animates translateX to target.
  • ProgressBar/ProgressCircle: progress optional with default 0; add originX/
    originY in getProgressCircleParams; web ProgressCircle uses pathLength=1.
  • Deprecate Spinner (web & mobile) in favor of indeterminate ProgressCircle.
  • ProgressBar tests: update float-label position expectation (80) and accept
    transform none/translateX(0) for zero progress; iconSvgMap regenerated.

The look of indeterminate ProgressCircle is based on the loading Button figma design

Root cause (required for bugfixes)

UI changes

storybook
docs

Simulator.Screen.Recording.-.iPhone.16.Pro.-.2026-03-17.at.12.02.31.mov
Simulator.Screen.Recording.-.iPhone.16.Pro.-.2026-03-17.at.12.01.33.mov
Simulator.Screen.Recording.-.iPhone.16.Pro.-.2026-03-17.at.12.03.13.mov

Testing

How has it been tested?

  • Unit tests
  • Interaction tests
  • Pseudo State tests
  • Manual - Web
  • Manual - Android (Emulator / Device)
  • Manual - iOS (Emulator / Device)

Testing instructions

Illustrations/Icons Checklist

Required if this PR changes files under packages/illustrations/** or packages/icons/**

  • verified visreg changes with Terran (include link to visreg run/approval)
  • all illustration/icons names have been reviewed by Dom and/or Terran

Change management

type=routine
risk=low
impact=sev5

automerge=false

@adrienzheng-cb adrienzheng-cb requested a review from hcopp March 13, 2026 19:17
@cb-heimdall
Copy link
Copy Markdown
Collaborator

cb-heimdall commented Mar 13, 2026

✅ Heimdall Review Status

Requirement Status More Info
Reviews 1/1
Denominator calculation
Show calculation
1 if user is bot 0
1 if user is external 0
2 if repo is sensitive 0
From .codeflow.yml 1
Additional review requirements
Show calculation
Max 0
0
From CODEOWNERS 1
Global minimum 0
Max 1
1
1 if commit is unverified 0
Sum 1
CODEOWNERS ✅ See below

CODEOWNERS

Code Owner Status Calculation
ui-systems-eng-team 1/1
Denominator calculation
Additional CODEOWNERS Requirement
Show calculation
Sum 0
0
From CODEOWNERS 1
Sum 1

color={colorValue}
size={progressCircleHeight}
weight="thin"
/>
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

How easy do you think it would be to have this value not be hardcoded? Particularly for v9 branch. I guess wed need text to be hidden still and then somehow have this be 100% height (If possible?)

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

depends if we want to merge this pr before or after v9

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

since we are pushing back the release of v9. we should merge this change in v8. I'll then remove the fixed height in cds-v9 branch following the new pattern after sync.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Would it be bad to have a loadingSpinnerSize prop or something similar on ButtonBaseProps (and include for IconButton? Or does that feel weird? We could also expose a node prop for this , such as loadingNode or something.

Advanced hoping to adjust size here and I'm wondering if possible, although in v9 with it being padding maybe the size prop doesn't make as much sense, vs a node for overriding.

Also if we say this isn't worth it then that's fine!

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I added progressCircleSize prop to both Button and IconButton.

@hcopp
Copy link
Copy Markdown
Contributor

hcopp commented Mar 13, 2026

Great work! Excited to see this when it's fully ready.

@adrienzheng-cb adrienzheng-cb marked this pull request as ready for review March 27, 2026 16:35
…-label math

- Add indeterminate prop to ProgressCircle (web & mobile): spinning state with
  configurable weight, default stroke ratio 0.11; animate full SVG on mobile,
  CSS keyframes on web; hide default content when indeterminate.
- Add getProgressSize(weight) in common and deprecate useProgressSize; use
  getProgressSize in ProgressBar and ProgressCircle on both platforms.
- Simplify ProgressBarWithFloatLabel (web & mobile): remove usePreviousValues,
  useIsoEffect, and imperative animation; use shared getEndTranslateX so float
  label trailing edge follows fill end (containerWidth * progress - textWidth);
  web uses useMotionProps + MotionBox, mobile animates translateX to target.
- ProgressBar/ProgressCircle: progress optional with default 0; add originX/
  originY in getProgressCircleParams; web ProgressCircle uses pathLength=1.
- Deprecate Spinner (web & mobile) in favor of indeterminate ProgressCircle.
- ProgressBar tests: update float-label position expectation (80) and accept
  transform none/translateX(0) for zero progress; iconSvgMap regenerated.
@github-actions
Copy link
Copy Markdown
Contributor

@adrienzheng-cb adrienzheng-cb requested a review from hcopp March 29, 2026 18:24
Copy link
Copy Markdown
Contributor

@hcopp hcopp left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks great, thanks for being thorough!

@adrienzheng-cb adrienzheng-cb merged commit cfc7c5e into master Mar 29, 2026
33 checks passed
@adrienzheng-cb adrienzheng-cb deleted the adrien/indeterminate-progress-circle branch March 29, 2026 21:34
adrienzheng-cb added a commit that referenced this pull request Mar 30, 2026
* feat: add indeterminate ProgressCircle (#501)

* feat: add indeterminate ProgressCircle, unify progress size and float-label math

- Add indeterminate prop to ProgressCircle (web & mobile): spinning state with
  configurable weight, default stroke ratio 0.11; animate full SVG on mobile,
  CSS keyframes on web; hide default content when indeterminate.
- Add getProgressSize(weight) in common and deprecate useProgressSize; use
  getProgressSize in ProgressBar and ProgressCircle on both platforms.
- Simplify ProgressBarWithFloatLabel (web & mobile): remove usePreviousValues,
  useIsoEffect, and imperative animation; use shared getEndTranslateX so float
  label trailing edge follows fill end (containerWidth * progress - textWidth);
  web uses useMotionProps + MotionBox, mobile animates translateX to target.
- ProgressBar/ProgressCircle: progress optional with default 0; add originX/
  originY in getProgressCircleParams; web ProgressCircle uses pathLength=1.
- Deprecate Spinner (web & mobile) in favor of indeterminate ProgressCircle.
- ProgressBar tests: update float-label position expectation (80) and accept
  transform none/translateX(0) for zero progress; iconSvgMap regenerated.

* update test and deprecation message

* add more button stories

* a11y fix

* remove 0.11

* add progressCircleSize prop

* update changelogs and package versions

* add progressCircleSize prop to IconButton

* fix removal version

* chore: deprecate CardGroup (#560)

* chore: deprecate CardGroup

* Update changelog

* feat: added cds skills for distribution (#561)

* chore: deprecate old card (#562)

* chore: deprecate old card

1. derpecated Card and related components and types
2. added derepcate-cds-api-skill

* update changelogs

* tweaks

---------

Co-authored-by: Hunter Copp <huntercolecopp@gmail.com>
Co-authored-by: Harry <ruikun.hao@coinbase.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Development

Successfully merging this pull request may close these issues.

3 participants