mirror of
https://github.com/tiennm99/loto.git
synced 2026-10-14 22:17:44 +00:00
feat: three-mode display (player/master/both) with master auto-tick
- Add `mode` setting to replace legacy `masterMode` with migration path - Implement 3-button display mode picker (player-only, master-only, both) - Auto-increment master when card drawn via call-bus event system - Add voice hint on settings button, gate auto-call on mode changes - Broadcast draw events from MasterPanel, reset call-bus on new game - Broadened announce condition to cover both modes - New call-bus.svelte.js module for event coordination - Update settings-store tests to cover mode migration - Update codebase docs for mode setting and call-bus architecture
This commit is contained in:
1 parent
7d1bb5e68a
commit
d08f25bd96
17 files changed
+937
-101
No files matched your search
@@ -62,6 +62,16 @@ All colors have corresponding `dark:` variants. Tailwind's `prefers-color-scheme
|
||||
- **Max width**: `max-w-lg` (player), `max-w-2xl` (host) — centered with `mx-auto`.
|
||||
- **Flex wrap**: Use `flex flex-wrap gap-1.5` for number history chips.
|
||||
|
||||
## Settings & UI Toggles
|
||||
|
||||
### Mode Picker (SettingsButton)
|
||||
Three-way toggle in settings modal:
|
||||
- **Player mode** (`mode: "player"`) — PlayerBoard only, default UX for players
|
||||
- **Master mode** (`mode: "master"`) — MasterPanel only, host-only view (e.g., projector)
|
||||
- **Both mode** (`mode: "both"`) — PlayerBoard + MasterPanel stacked inline, master auto-ticks player board on draw
|
||||
|
||||
Mode selection is persisted to localStorage and applied immediately.
|
||||
|
||||
## Component Patterns
|
||||
|
||||
### Button Styles
|
||||
|
||||
Reference in new issue
Block a user