Commit graph

5 commits

Author SHA1 Message Date
72d996cb4b Show players during setup: empty slots and registration progress
Parser changes:
- Track num_players_expected from user input after 'How many players?'
- Create placeholder players ('Player N') on 'say me please' prompts
- Replace placeholder names when real names appear in roll lines
- Emit state during setup phase (was returning None)
- Include phase and numPlayersExpected in state JSON

UI changes:
- Empty slots shown as dashed/dimmed panels with '?' token
- Placeholder players shown as 'Registering...'
- Registered players shown with checkmark and ,500
- Status bar shows 'Setting up · 2/3 players registered'
2026-02-21 11:24:49 +00:00
435b24bfb8 Replace disconnected overlay with slim banner matching stale style
Same top-banner pattern as the stale indicator but with red accent
and 'Connection lost — retrying every 2s...' message. Page gets
subtle greyscale/dim instead of a blocking overlay.
2026-02-21 11:15:18 +00:00
dd4787615d Add stale data banner when game state hasn't updated in 20s
Subtle top banner with dimmed page (not a blocking overlay like the
full disconnect state). Shows elapsed time since last update.
Separate from the hard disconnect which triggers after 3 fetch failures.

Debug panel: added 'Stale' button to test.
2026-02-21 11:13:19 +00:00
34a4f47402 Add zero state, disconnected overlay, game over confetti, and debug panel
- Zero state: bouncing dice + message when no game exists
- Disconnected: greyed overlay after 3 consecutive fetch failures,
  with retry countdown
- Game over: gold banner with winner name + confetti animation,
  detected from log ('WINS!') or single remaining player
- Debug panel: Ctrl+Shift+D toggles hidden panel with buttons to
  test all four states (zero, playing, gameover, disconnected, reset)
- Also fixed player panel to use p.number for current-turn matching
  and property ownership display
2026-02-21 11:08:06 +00:00
7dadd1f37f Organize directory structure
- cardinal-plugin/ → plugins/ (matches Cardinal's plugin dir convention)
- index.html + game-state.json → site/
- OUTPUT_CATALOG.md → docs/
- Core Python files and tests stay flat (no import changes needed)
2026-02-21 10:16:49 +00:00
Renamed from index.html (Browse further)