Scribble assigment#129
Open
bhaskar-everest wants to merge 21 commits into
Open
Conversation
- Define loading spinner UX for create/join/refresh - Scope game start transition (lobby->playing) into this feature - Add room code collision retry handling - Add drawer assignment and word selection requirements
- Add plan.md with technical context, constitution check, and project structure - Add research.md with existing code analysis and key decisions - Add data-model.md with entity definitions and state transitions - Add contracts/api-v1.md with REST endpoint contracts - Add quickstart.md with validation scenarios and curl commands - Point AGENTS.md SPECKIT markers to plan.md
- 28 tasks across 7 phases (Setup, Foundational, US1-4, Polish) - MVP scope: Phase 1+2+US1 (create room with host indicator) - US3 and US4 designed for parallel execution
… game start - Extend RoomStatus to include playing/finished - Add hostId, secretWord to Room model, role to Participant - Add playerName validation (non-empty, non-whitespace) via Zod - Mark first participant as host on room creation - Add client-side validation and loading spinners on Create/Join pages - Add case-insensitive room code lookup and join rejection for non-lobby rooms - Implement lobby auto-polling (2s interval) replacing manual refresh - Show host indicator badge in participant list - Add startGame endpoint with host check, min 2 players, role/word assignment - Add leaveRoom endpoint with host transfer and room cleanup - Fix API_BASE_URL (/bug suffix removed) - Add drawer-only secretWord visibility in snapshots - Add max 8 participants check on join, max 4 char room code validation
- Defines 4 user stories covering game start transition, drawer word visibility, deterministic drawer assignment, and deterministic word selection - 9 functional requirements and 7 success criteria - Covers edge cases for refresh, non-drawer draw rejection, and name trimming
…rt-drawer - plan.md: technical context, constitution check, project structure, phases - research.md: 6 design decisions (drawer=host, word index-based, polling, canvas) - data-model.md: entity definitions, state transitions, validation rules - contracts/api-v1.md: behavioral changes to start endpoint - quickstart.md: 6 validation scenarios for two-tab testing - AGENTS.md: updated SPECKIT marker
22 tasks across 6 phases: foundational backend fixes (T001-T004), US1 game page + canvas (T005-T010), US2 word visibility (T011-T013), US3 drawer assignment tests (T014-T015), US4 word selection tests (T016-T017), and polish/validation (T018-T022)
…ased game screen - Fix drawer assignment to host (not first non-host) per FR-001 - Add deterministic word selection via charCodeSum(code) % 5 per FR-002 - Add Canvas component with freehand brush and 8-color palette - Add WordDisplay and RoleBadge components - Update GamePage with role-based rendering and polling - Add lobby-to-game auto-navigation for non-host participants - Add backend tests for drawer assignment, word selection, host transfer - Trim display names via Zod transform - Add canvas, word-display, and role-badge CSS styles
- Resolve canvas delivery model (separate endpoint) - Resolve post-round flow deferral - Resolve network error handling on guess submission - Add Clarifications session section with 3 Q&A items
…-interaction - Research document with 10 design decisions (stroke format, endpoints, storage, round end detection) - Data model with 5 new entities (Stroke, CanvasState, Guess, Score, extended Room) - API contracts for 5 endpoints (draw, clear, guess, end-round, extended room poll) - Quickstart validation guide with 6 testable scenarios - Updated AGENTS.md to reference current plan
- 49 tasks across 7 phases organized by user story priority - Foundational phase: data model types, schemas, API methods - US1 (P1): drawing sync with canvas endpoints and polling - US2 (P1): guess submission with feedback and guess log - US3 (P1): scoring, round end detection, results screen - US4 (P2): host-controlled early round end - US5 (P3): canvas reset on round completion
…, round end) - Drawing sync: canvas polling, stroke submission, real-time rendering - Guess submission with correct/incorrect/already-guessed feedback - Scoring: 100 pts per correct guess, drawer gets pts for unguessed - Round end: auto-end when all guess correct, host can end early - Results screen with secret word revealed, scores, guess log - Backend: canvas store, guess validation, Zod schemas, all endpoints - Frontend: Canvas rewrite, GuessForm, ResultPanel, Scoreboard, GamePage - 16 new backend tests (36 total), all quickstart scenarios validated - Edge cases: duplicate incorrect guess detection, canvas clear no-op
- Feature spec for multi-round gameplay: results viewing, lobby return, new round start, final standings, and participant leave flows - Room state machine: lobby -> playing -> round_end -> lobby (or game_over) - Max rounds = participant count, pre-game joining only - 4 clarifications resolved in clarify session
…estart-validation - Phase 0 research: 10 design decisions (state machine, drawer rotation, word cycling, endpoint design, host transfer, polling integration) - Phase 1 data model: Room status enum extended, RoundResult/FinalStandings types, state machine diagram, validation rules - Phase 1 contracts: return-to-lobby, start-round, leave endpoints; breaking change note for room status enum - Phase 1 quickstart: 7 validation scenarios with curl commands - Updated AGENTS.md to point to new plan
- 43 tasks across 7 phases: Foundational, US1 (View Round Results), US2 (Return to Lobby), US3 (Start New Round), US5 (End-of-Game Standings), US4 (Leave Room), Polish - MVP scope: US1 only (T001-T009) - Parallel opportunities: Foundational tasks, US4 independent
…rounds, final standings, and leave - Extend Room status to lobby/playing/round_end/game_over replacing 'finished' - Add RoundResult, FinalStanding types and roundCounter/maxRounds/currentDrawerIndex/wordIndex to Room model - Rewrite endRound to compute RoundResult and detect game_over on final round - Add return-to-lobby and start-round endpoints with Zod validation - Implement drawer rotation (round-robin) and word cycling with skip-back guard - Add LeaveButton component and update leave route with drawer restriction and host transfer - Update GamePage to handle round_end, game_over, and lobby transitions - Update LobbyPage for post-round lobby with Start New Round and Game Complete states - Mask correct guesses in activity feed during play to prevent answer disclosure - Add 17 new backend unit tests (53 total passing) - Add CSS for standings-list, waiting-message, round-result-summary
Covers what the starter had, what was added, AI usage, tradeoffs/decisions, and improvement ideas.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Multi-Round Gameplay with Results, Restart, and Final Standings
Backend:
Frontend:
Specs & Docs:
Contributor