feat: fetch and dynamically render local leaderboard ranks in profile page#319
feat: fetch and dynamically render local leaderboard ranks in profile page#319Yashaswini-K-P wants to merge 1 commit into
Conversation
|
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
|
|
Are you planning to open a follow-up PR to display the rank change indicators alongside the ranks as well? We already expose those through the |
|
"Hi @jagdish-15! I'd prefer to keep this PR focused purely on rendering the base ranks as it's already tested and standalone. I will gladly open a follow-up PR right after this one gets merged to implement the rank change indicators" |
Description
This PR connects the frontend user profile banner to the newly exposed leaderboard rankings API data. It reads the local rankings (Overall, Monthly, Weekly, and Daily) and updates the dashboard UI dynamically on page load using a standalone, self-contained architecture consistent with other widgets like badges and contests.
Related to #195
Changes Made
overall-item,overall-rank, etc.) to the rankings layout structure insideuser.html./js/user/ranks.jsto extract the username from the URL path, query the user profile API endpoint, and populate the banner.--if the rank is0or missing).Type of Change
Testing
Checklist
npx prettier --write .before submittingfeature/*branch, not themainbranchScreenshots / Screen Recording