Repository navigation
Conversation
- DAB: add redo feature - player can request undo, immediate opponent accepts/rejects - All games: add player name badges, (You) indicator, prominent turn display - PaperParty landing: paper sketch style with custom SVG game icons, notebook aesthetic - DAB: allow game to continue with 1 player if started with 4+ players - Fix DAB grid layout and lucide icon import (RotateCCW -> Undo2)
The cursor/disabled logic incorrectly marked won grids as dead instead of won. Using macroWinner !== null (instead of === 'DEAD') properly blocks interaction on won grids while keeping them visually distinct from DEAD grids.
Bingo: - currentTurn now stores socket.id (not index) - markNumber validates socket.id match, not index-based lookup - checkForWin uses typeof === 'string' for marked cells - handleCellClick uses typeof to detect marked numbers UTTT: - Backend: activeGrid = null only when next grid is DEAD (not won) - Frontend: isActive is true also when grid is DEAD (free move only on dead) All games: - leaveRoom frontend cleanup on both confirmations
…ks with tests - Add AvatarSelector, CountdownOverlay, GameLayout, MatchReport, TurnIndicator components - Add useGameHandlers, usePlayerAvatars, useTurnTimer hooks - Refactor game managers (bingo, dab, ttt, uttt) with sanitizeRoomId and unified alert pattern - Update existing components (Bingo, DabGame, TicTacToe, UTTTGame, RoomLobby) - Add tests for all new components and hooks, plus server-side tictactoe tests
…env check - Remove duplicate requestRedo, respondRedo, handleDisconnect from dab.js (these exist elsewhere or are inherited from BaseManager) - Escape apostrophes in ErrorBoundary.jsx and UTTTGame.jsx for JSX safety - Replace process.env.NODE_ENV with import.meta.env.DEV for Vite compatibility
- ESLint config with per-package overrides (Node for api, browser+JSX for pro) - Prettier config for consistent formatting - Husky + lint-staged pre-commit hook for lint and format on staged files - GitHub Actions CI workflow running mocha (api) and vitest (pro) - EditorConfig for 2-space indent, LF endings across the monorepo - Kilo code review plan for tracking improvement priorities
Root ESLint (^8.57.0) was never installed in CI — only subdirectory npm ci ran. npx eslint then fetched v10+, which requires flat config. Fix by running npm ci at root before linting. Also add root-level .gitignore with node_modules/.
Job-level defaults.run.working-directory applied to ALL steps, so the first npm ci was running in api/ (or pro/) instead of root. Root node_modules was never installed, causing npx to fetch eslint v10.
…ng-directory - Add missing handleDisconnect method to DabManager (was crashing all tests on socket disconnect) - Fix .github/workflows/ci.yml working-directory paths (removed ambiguous defaults) - Fix 60+ no-unused-vars lint warnings across api/test/ and pro/src/
…disconnect timing - Remove io.close() from shutdown() (server.close() alone is sufficient) - Fix Graceful Shutdown test to disconnect socket before calling shutdown - Add setTimeout(done, 100) to afterEach hooks across all test files - Fix unused variable warning in index.js
Bug 1 (N/A): Only one Leave Room button exists in current source; no changes needed. Bug 2: Remove gameState === 'playing' guard in leaveRoom for all 4 managers (bingo.js, tictactoe.js, uttt.js, dab.js). Non-playing states now properly splice the player, reassign creator if needed, and clean up empty rooms. Bug 3: Move clearTimer before socket emits in bingo.js markNumber to prevent stale timer callback from advancing turn twice after a number is marked. Bug 4: Change room.scores = Array(room.players.length).fill(0) to room.scores = Array(room.maxPlayers).fill(0) in dab.js restartGame, fixing incorrectly sized scores array when a player had left. Bug 5 (re-fix): Re-add DAB auto-start block in dab.js joinRoom after it was accidentally removed. When players.length >= maxPlayers, emit dab_gameStarted and set gameState='playing'. sendRoomInfo must come AFTER auto-start so the roomInfo reflects 'playing' state. Bug 6: Add socketRooms Map to BaseManager with _trackSocket/_untrackSocket helpers. Update all 4 managers' createRoom, joinRoom, reconnect to track; leaveRoom to untrack; handleDisconnect to use socketRooms instead of O(n) iteration over all rooms. Prevents disconnect-ordering bugs across socket.io versions. Bug 7: Change gameState === 'ready' || gameState === 'playing' to gameState === 'waiting' || gameState === 'playing' in TicTacToe.jsx for the Leave Room button visibility, since TTT uses 'waiting' not 'ready'. Bug 8: Add strikedNumbersRef in Bingo.jsx. The roomInfo handler stores strikedNumbers in ref; playerBoard handler applies them when board arrives, fixing loss of striked numbers on reconnection. Bug 9: Add .trim() check in PaperPartyLanding.jsx Swal inputValidator and call setPlayerName(result.value.trim()) to prevent whitespace-only names. Bug 10: Add roomIdRef in GameContext.jsx, updated via useEffect, used in clearRoomId to avoid stale closure over the roomId state. Features: - Add _trackSocket/_untrackSocket helpers to BaseManager with socketRooms Map - Add base-manager.test.js tests for socket tracking and cleanup
…pdated DAB redo logic
- Fix e2e test selectors and async handling across all games - Update DabGame component with improved redo logic and UI fixes - Update TicTacToe component and tests - Update MatchReport component styling - Update API dab test file
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.
No description provided.