fix(goals): clamp progress bar width to 100% max and add Goal Surpass… - #3259
Open
Nareshkumawat-star wants to merge 1 commit into
Open
Conversation
GSSoC Label Checklist 🏷️@Priyanshu-byte-coder — please apply the appropriate labels before merging: Difficulty (pick one):
Quality (optional):
Validation (required to score):
|
Author
|
Hi @Priyanshu-byte-coder kindly review and merge it |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Fixes progress bar visual overflow in
GoalTracker.tsxby clamping progress width to a maximum of 100% (Math.min((current / target) * 100, 100)). Introduces a dedicated "Goal surpassed! 🎯" label and emerald glow ring indicator when a user exceeds their target.Closes #3246
Type of Change
What Changed
src/components/GoalTracker.tsx:progressWidthto100%max in the style property (Math.min(progressWidth, 100)%).Goal surpassed! 🎯completion label whengoal.current > goal.target.test/GoalTracker.test.ts:How to Test
currentto be higher thantarget).Checklist
console.logor debug code