feat: add weekly goal setter widget to [SYS_TARGETS] card (#113)#233
Open
manjiri27 wants to merge 1 commit into
Open
feat: add weekly goal setter widget to [SYS_TARGETS] card (#113)#233manjiri27 wants to merge 1 commit into
manjiri27 wants to merge 1 commit into
Conversation
Contributor
|
Thank you for submitting a pull request. Please ensure your changes comply with the project's contribution guidelines and that all workflow checks pass successfully. Formatting and Branching
|
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.
Description
Adds a weekly goal-setting widget to the [SYS_TARGETS] card on the user profile page. Users can set a weekly problem-solving target (by difficulty: Total / Easy / Medium / Hard), track their progress via a retro terminal-style progress bar, and reset their goal at any time. Goals persist across sessions via localStorage and auto-reset every Monday.
Linked Issue
Fixes #113
Changes Made
Populated the empty [SYS_TARGETS] card in frontend/user.html with goal setter UI (metric selector, number input, [SET] button)
Added progress display view showing [=====>..........] X% bar, current count, and a celebration message on goal completion
Created frontend/js/user/goal-setter.js to handle all goal logic: save/load/reset via localStorage, weekly auto-reset every Monday, live solved count fetched from /api/user/:username
Type of Change
Testing
Checklist
npx prettier --write .before submittingfeature/*branch, not themainbranchScreenshots / Screen Recording
Goal setter (no goal set):

Progress bar (after setting goal):
