docs(ui): sync docs to the app-shell; fix stale nav comments
Tests · UI / test (push) Failing after 9m28s
Tests · UI / test (push) Failing after 9m28s
Rewrite ui/docs (navigation, order-composer, auth-flow, pwa-strategy, game-state + secondary topic docs) and ui/README for the single-URL app-shell (in-memory screens/views, Back→lobby via shallow routing, sessionStorage restore + validation, return-to-lobby). ui/PLAN.md gets a Phase-10 supersede note (implemented; standalone-compatible). Fix stale code comments (session-store auth gate, report-sections spec contract). Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -1,7 +1,9 @@
|
||||
# Battle Viewer UX
|
||||
|
||||
The battle viewer is a dedicated view for battles
|
||||
(`/games/<id>/battle/<battleId>`). Bombings are a separate static
|
||||
The battle viewer is a dedicated active view for battles
|
||||
(`activeView.view === "battle"`, with `battleId` and `turn`
|
||||
sub-parameters; the app-shell has no per-view URL — see
|
||||
[`navigation.md`](navigation.md)). Bombings are a separate static
|
||||
table in the Reports view (`section-bombings.svelte`). The two
|
||||
domains are deliberately not mixed in any visual surface or click
|
||||
target.
|
||||
@@ -212,7 +214,8 @@ result is an X-shaped cross overlaid on the planet glyph.
|
||||
The stroke width is computed by `battleMarkerStrokeWidth(shots)`:
|
||||
1 shot → 1 px, 100 shots → 5 px, linearly interpolated in between
|
||||
(`width = 1 + (shots − 1) × 4 / 99`, clamped). A click on either
|
||||
line navigates to `/games/<id>/battle/<battleId>?turn=<turn>`.
|
||||
line opens the battle viewer in memory via
|
||||
`activeView.select("battle", { battleId, turn })`.
|
||||
|
||||
### Bombing marker — colored ring
|
||||
|
||||
@@ -223,10 +226,10 @@ Colour:
|
||||
- yellow (`#FFD400`) when `wiped: false`,
|
||||
- red (`#FF3030`) when `wiped: true`.
|
||||
|
||||
A click on the ring navigates to `/games/<id>/report#report-bombings`
|
||||
and scrolls the matching `report-bombing-row` (by `data-planet`)
|
||||
into view. Bombing markers never open the Battle Viewer — the two
|
||||
domains stay separate.
|
||||
A click on the ring switches to the report view
|
||||
(`activeView.select("report")`) and scrolls the matching
|
||||
`report-bombing-row` (by `data-planet`) into view. Bombing markers
|
||||
never open the Battle Viewer — the two domains stay separate.
|
||||
|
||||
## Data source
|
||||
|
||||
|
||||
Reference in New Issue
Block a user