Surface per-user effective max on tournament and league leaderboards - #7
Merged
borland667 merged 1 commit intoJun 15, 2026
Conversation
Builds on the forfeitedKnockoutPoints field shipped with the
closed-group bracket-seeding change. Each row's Total column now reads
as `score / per-user maximum` where the maximum is
`tournament.rules.totalMaximumPoints − forfeitedKnockoutPoints`.
When no group has closed with corrected seeding yet, every player's
max equals the tournament-wide max and the column reads the same for
all rows. Once a player has at least one knockout match whose actual
participants did not include their stored pick, that player's max
drops by the round's `pointsPerCorrect` and a single explanatory
footnote is rendered below the table.
The global leaderboard and profile still show earned totals only —
they aggregate across multiple tournaments and a cross-tournament
maximum is not yet exposed by the API. Left as a follow-up.
- `src/pages/Leaderboard.jsx`, `src/pages/League.jsx`: render
`score / effective_max` per row; conditional footnote
- `src/index.css`: `.leaderboard-table-footnote` style
- `src/i18n/messages/{en,es,pt,it,nl}.js`: `leaderboard.effectiveMaxTooltip`
and `leaderboard.effectiveMaxNote`
- `docs/QA_CHECKLIST.md`: cover the new display in §14 and §15
- `docs/IMPLEMENTATION_STATUS.md`: note current coverage and the
global/profile follow-up
Co-authored-by: Cursor <cursoragent@cursor.com>
4 tasks
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
Frontend follow-up to PR #6. The Total column on the tournament and league leaderboards now reads as
score / per-user maximum, where the maximum istournament.rules.totalMaximumPoints − forfeitedKnockoutPoints.pointsPerCorrectand a single explanatory footnote is rendered below the table.Out of scope (future PRs)
/leaderboard/global) still shows earned totals only. Its rows aggregate across multiple tournaments and the API doesn't yet expose the user's cross-tournament max-possible.Both would need an API extension (per-user lifetime max across tournaments) which is a larger change.
Files
src/pages/Leaderboard.jsx,src/pages/League.jsx: renderscore / effective_maxper row + conditional footnotesrc/index.css:.leaderboard-table-footnotesrc/i18n/messages/{en,es,pt,it,nl}.js:leaderboard.effectiveMaxTooltip+leaderboard.effectiveMaxNotedocs/QA_CHECKLIST.md§14 / §15 cover the new displaydocs/IMPLEMENTATION_STATUS.mdnotes the current coverage + follow-upTest plan
Stacking
Based on `ux/closed-group-bracket-seeding` (PR #6) — that PR introduces `Score.forfeitedKnockoutPoints` and exposes it on the API. Once #6 merges to `main`, this PR's base will retarget to `main` automatically on GitHub.
Made with Cursor