Repository navigation
Commit 7913898
Add Leaderboard modal UI, visual-state leaderboard projection, and wiring (#35)
* Review leaderboard modal behavior
* Fix leaderboard UI layering, scaling, and HUD placement
The leaderboard modal was rendering behind the HUD/map because its
UIDocument shared sortingOrder 0 with every other document and relied
on scene-authoring order to win ties. Give it an explicit sortingOrder
in code instead, per this project's own guidance not to rely on scene
ordering for stacking.
The table header wasn't scaling with the panel because .gs-panel uses
align-items: center, so header children shrank to content size instead
of stretching to the panel width — only the table header needed the
fix, the title bar stays centered by design.
Also moves the leaderboard button next to the player org panel,
fixes org/country flag aspect ratio, disables map zoom while the
window is open (full scroll-forwarding into the list is deferred),
and formats scores with thousands separators.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
* Pin leaderboard close button to the panel's top-right corner
The close button lived inside the centered title row, so it sat next
to the title instead of at a fixed corner. Move it out to its own
absolutely-positioned element inset by the panel's own padding,
independent of the title, which stays centered.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
* Replace InternalsVisibleTo with public API for test-only access
Game.Main and Game.Configs.Loader each carried an AssemblyInfo.cs
whose only purpose was granting Game.Tests blanket access to internal
members. That's an invisible, all-or-nothing escape hatch rather than
a deliberate API decision, and it hides which members tests actually
depend on.
Flip just the members Game.Tests calls (VisualStateConverter's
constructor and Update/UpdateCountryScore/UpdateLeaderboards; Program
.ApplyPreservedFields; ProvinceProcessor.Process, plus their
containing types) to public instead, and drop both AssemblyInfo.cs
files now that nothing needs InternalsVisibleTo. Document the
preference in code_style.md so future test-only access follows the
same pattern.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
---------
Co-authored-by: Claude Sonnet 5 <noreply@anthropic.com>1 parent d4918be commit 7913898
39 files changed
Lines changed: 1208 additions & 43 deletions
File tree
- .claude/rules/csharp
- Assets
- Localization
- Plugins/Core
- Scenes
- Scripts/Unity
- DI
- Map
- UI
- UI
- HUD
- Modal
- LeaderboardWindow
- Docs/Specs/26_07_18_19_leaderboards-ui
- ProjectSettings
- src
- Game.Configs.Loader
- Game.Main
- Game.Tests
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
20 | 20 | | |
21 | 21 | | |
22 | 22 | | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
14 | 14 | | |
15 | 15 | | |
16 | 16 | | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
17 | 27 | | |
18 | 28 | | |
19 | 29 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
14 | 14 | | |
15 | 15 | | |
16 | 16 | | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
17 | 27 | | |
18 | 28 | | |
19 | 29 | | |
| |||
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
0 commit comments