Skip to content

refactor: invert progress calculation for inside variant#4483

Merged
ComputelessComputer merged 1 commit intomainfrom
fix-now-indicator
Mar 10, 2026
Merged

refactor: invert progress calculation for inside variant#4483
ComputelessComputer merged 1 commit intomainfrom
fix-now-indicator

Conversation

@ComputelessComputer
Copy link
Copy Markdown
Collaborator

Extract progress calculation to insideOffset variable and invert the formula from progress * 100% to (1 - progress) * 100% so that progress 0 positions the indicator at bottom (100%) and progress 1 at top (0%).

Add test coverage to verify the inside variant renders progress from bottom to top as expected.

Extract progress calculation to insideOffset variable and invert
the formula from progress * 100% to (1 - progress) * 100% so that
progress 0 positions the indicator at bottom (100%) and progress 1
at top (0%).

Add test coverage to verify the inside variant renders progress
from bottom to top as expected.
@netlify
Copy link
Copy Markdown

netlify bot commented Mar 10, 2026

Deploy Preview for hyprnote-storybook canceled.

Name Link
🔨 Latest commit d86e8e9
🔍 Latest deploy log https://app.netlify.com/projects/hyprnote-storybook/deploys/69afcffd8a30d100089fb785

@netlify
Copy link
Copy Markdown

netlify bot commented Mar 10, 2026

Deploy Preview for hyprnote canceled.

Name Link
🔨 Latest commit d86e8e9
🔍 Latest deploy log https://app.netlify.com/projects/hyprnote/deploys/69afcffdf354c20007b0f142

@ComputelessComputer ComputelessComputer merged commit 080b8d8 into main Mar 10, 2026
14 checks passed
@ComputelessComputer ComputelessComputer deleted the fix-now-indicator branch March 10, 2026 08:18
jack-jackhui pushed a commit to jack-jackhui/char that referenced this pull request Mar 15, 2026
Extract progress calculation to insideOffset variable and invert
the formula from progress * 100% to (1 - progress) * 100% so that
progress 0 positions the indicator at bottom (100%) and progress 1
at top (0%).

Add test coverage to verify the inside variant renders progress
from bottom to top as expected.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant