Repository navigation
Keep the player card off the open leaderboard from 1024px - #6157
Conversation
From lg, where the leaderboard opens by default, the leaderboard, the hovered-player card and the timer sidebar share one top row: the card stays centered when it fits and otherwise shifts right (narrowing if it has to) to clear the leaderboard. Fixes the overlap on Poki's 1031px frame. Below lg nothing changes. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
No actionable comments were generated in the recent review.
|
| Layer / File(s) | Summary |
|---|---|
Responsive top HUD layout index.html, src/client/hud/layers/GameLeftSidebar.ts, src/client/hud/layers/PlayerInfoOverlay.ts |
At lg and above, the left sidebar, player-info overlay, and right-side controls occupy three columns. Below lg, the right-side controls remain fixed at the top right. The sidebar and overlay use breakpoint-specific positioning and pointer-event classes. |
Priority:
Estimated code review effort: 2 (Simple) | ~10 minutes
Change: Bug fix
Possibly related PRs
- openfrontio/OpenFrontIO#6147: Reduces the default leaderboard width to avoid overlap with the player card.
Suggested reviewers: celant, jb940
Merge Risk: 
Minimal · up to 9306b
-
The responsive HUD change is ready to merge after normal checks.
Pre-merge checks: 
5
-
Full details: Docstring Coverage
-
Explanation
No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff. Analyzed 0 functions across 2 files. (1 skipped: 1 unsupported.)
-
Finishing Touches: 💡 1
-
🛠️ Fix failing CI checks: 💡
-
- Commit to this branch
- Create a new PR
-
- Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.
Three columns line up at the top.
The side controls keep their place.
Below lg, the layout shifts.
The player card finds its space.
A tidy HUD settles in.
Comment @coderabbitai help to get the list of available commands.
🤖 Claude Code ReviewVerdict: No issues found. Findings: 0 critical, 0 major, 0 minor. Checked for bugs and CLAUDE.md compliance. Below |
|
🍒 Cherry-pick onto |
Cherry-pick of #6157 onto `v35`. It conflicted, and Claude resolved it. Conflicted files: - `src/client/hud/layers/PlayerInfoOverlay.ts` Typecheck, format and lint pass on the result. Check the fix before merging. Co-authored-by: Evan <evanpelle@gmail.com>
Summary
lg(1024px), where the leaderboard opens by default, the leaderboard, the card and the timer sidebar (with the replay panel) now share one top row inindex.html. It's a 3-column grid,[minmax(max-content,1fr) | minmax(0,max-content) | minmax(max-content,1fr)]. When there's room the card stays centered as before. Otherwise it shifts right to clear the leaderboard, and narrows (lg:max-w-full) only if it would reach the sidebar. The card's building-count boxes shrink a few pixels rather than wrap.lg, nothing changes: each piece keeps its own fixed position (max-lg:), as on main. There's no shrinking and no vertical sidebar.pointer-events-none. The leaderboard, the sidebar and the visible card opt back in, so map clicks pass through the empty parts of the row.Test plan
Headed Chromium against a local dev server, solo game, leaderboard open:
game-input-overlay, and the leaderboard and sidebar take clicks.npx vitest run: 9534 passed, 1 skipped.npm run typecheck, oxlint and oxfmt are clean.🤖 Generated with Claude Code