Commit Graph

7 Commits

Author SHA1 Message Date
randrews 5f872d1608 pass rules 2026-05-28 23:29:33 -05:00
randrews 23621da468 typo 2026-05-28 23:23:35 -05:00
randrews 79832ed818 Add help modal and back button to score entry pages
HelpModal component shows game setup and scoring rules in a scrollable
overlay, triggered by a ? button top-right on Player Setup and Enter
Scores. Enter Scores also gets a ← back button top-left that returns
to the scoresheet without saving. PageFrame gains a headerActionLeft
slot to support the left-side button.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-28 23:06:48 -05:00
randrews 813d18e133 Implement scoresheet page with scoring logic and confirmation dialog
- Add src/game/scoring.ts with computeRunningTotals and isGameOver
- Build ScoreSheet grid: player columns, per-round scores, running totals after round 2+
- Small red "New Game" button in header top-right with full-screen confirmation overlay
- Extend PageFrame with headerAction and overlay props
- Move press animation/shadow from .pressable class to global button selector

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-28 00:34:23 -05:00
randrews e0a6aed4cf Centralize duplicated card shell, press animation, and color tokens
Extract the rounded-card shell and button press animation into a shared
CSS module composed by PageFrame, TitleScreen, and all buttons, add color
tokens for repeated values, and load the saved game once on mount.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-05-27 00:23:36 -05:00
randrews 4f852d7902 Add player setup form with validation and field error highlighting
- Dynamic name fields (3–6 players) with add/remove controls
- Start button disabled until all names are non-blank and unique;
  uniqueness check normalizes internal whitespace so "Bob  Smith"
  and "Bob Smith" are treated as the same name
- Names passed to game state are edge-trimmed only, preserving
  internal spacing as the user typed it
- Failing fields highlighted with red border and light red background
- PrimaryButton gains disabled prop with faded/flat appearance;
  active press state suppressed when disabled
- All round buttons now use consistent shadow and translateY values

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-26 23:59:45 -05:00
randrews b3e7df9ba8 Add PageFrame, PrimaryButton, and shared layout for non-title pages
- PageFrame: parchment-background frame with title, diamond-rule divider,
  scrollable content area, and optional bottom-pinned footer slot
- PrimaryButton: shared full-width button (light blue, drop shadow, pressed
  state via translateY + shadow reduction) — used by TitleScreen and PlayerSetup
- Global button base in index.css ensures touch-friendly sizing everywhere
- TitleScreen consolidated to use PrimaryButton instead of its own button style

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-26 20:28:49 -05:00