docs: add UI-first design principle
Every player-triggered action (new game, undo, draw, pause, open any overlay, switch mode, etc.) must be reachable from a visible UI control. Keyboard shortcuts are optional accelerators only — never the sole entry point. New gameplay features ship with the UI control alongside the system that backs it. - ARCHITECTURE.md §1 (Design Principles): add UI-first bullet. - ARCHITECTURE.md §5 plugin table: rename "Key" column to "Shortcut" and add a note that the column lists optional accelerators, not primary entry points. - CLAUDE.md (Bevy Conventions): add a matching hard rule. Surfaced during smoke testing: the N+N "press again to confirm" toast collides with the ConfirmNewGameScreen modal because the keyboard flow is the only entry point. Adding a visible New Game button (next commit) makes the modal the single source of truth for the confirm flow. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -77,6 +77,7 @@ cargo clippy -p solitaire_core -- -D warnings
|
||||
- Resources own shared state. Events communicate between systems. Components own per-entity data.
|
||||
- All UI screens are built with Bevy UI (`bevy::ui`). Never mix UI layout and game logic in the same system.
|
||||
- Layout is recomputed on `WindowResized` — never assume a fixed window size.
|
||||
- **UI-first.** Every player-triggered action (new game, undo, draw, pause, open stats / settings / help / profile / leaderboard, switch mode, etc.) must be reachable from a visible UI control. Keyboard shortcuts are optional accelerators — never the sole entry point. New gameplay features ship with the UI control alongside the system that backs it; do not merge a feature that is keyboard-only.
|
||||
|
||||
---
|
||||
|
||||
|
||||
Reference in New Issue
Block a user