How eshwarkothapalli11/bingopremium works
BINGO is a browser-based multiplayer game: players start a session, create or join a shareable room, ready up, privately enter boards, then compete in live play and view results and history. The README describes Supabase, while the sampled runtime and central modules use Firebase; the graph reflects the sampled implementation. Some feature components and persistence details are unsampled, so their internal connections are omitted unless documented or indexed.
Main entry points: GameView.tsx Live Game View · firestore.ts Firestore Operations · RoomPageClient.tsx Room Route · RoomContext.tsx Room Coordinator
Components 25
Entry and Rooms
- Session Gate
components/auth/AuthGate.tsx - Player Dashboard
app/dashboard/DashboardClient.tsx - Room Creation
components/lobby/CreateRoomPage.tsx - Join by Code
components/lobby/JoinRoomModal.tsx - Room Route
app/room/[code]/RoomPageClient.tsx
Game Experience
- Ready Lobby
components/lobby/LobbyView.tsx - Private Board Entry
components/game/MatrixEntry.tsx - Live Game View
components/game/GameView.tsx - Board Grid
components/game/BoardGrid.tsx - BINGO Progress
components/game/BingoProgress.tsx - Opponent Tracking
components/game/OpponentCard.tsx - Game Chat
components/game/GameChat.tsx - Leaderboard
components/game/Leaderboard.tsx - Live Moves Feed
components/game/LiveMovesFeed.tsx - Win Screen
components/game/WinModal.tsx
Game Runtime
- Room Coordinator
context/RoomContext.tsx - Room Operations
hooks/useRoom.ts - BINGO Rules
lib/bingo-logic.ts - Game Actions
hooks/useGame.ts
Identity and Data
- Firebase Auth
lib/firebase/auth.ts - Firestore Operations
lib/firebase/firestore.ts - Realtime Subscriptions
lib/firebase/realtime.ts - Firebase Client
lib/firebase/firebase.ts - Firestore Store
Other components
- Player
Connections 30
- Player → Session Gate: opens app
- Session Gate → Firebase Auth: gets profile
components/auth/AuthGate.tsx - Player → Player Dashboard: chooses room
- Player Dashboard → Room Creation: opens create
app/dashboard/DashboardClient.tsx - Player Dashboard → Join by Code: opens join
app/dashboard/DashboardClient.tsx - Room Creation → Room Operations: creates room
components/lobby/CreateRoomPage.tsx - Room Operations → Firestore Operations: loads and writes
hooks/useRoom.ts - Player → Room Route: opens room link
- Room Route → Room Coordinator: provides room state
app/room/[code]/RoomPageClient.tsx - Room Coordinator → Firestore Operations: loads room data
context/RoomContext.tsx - Room Coordinator → Realtime Subscriptions: subscribes to room
context/RoomContext.tsx - Room Route → Ready Lobby: renders waiting stage
app/room/[code]/RoomPageClient.tsx - Room Route → Private Board Entry: renders matrix stage
app/room/[code]/RoomPageClient.tsx - Room Route → Live Game View: renders game stage
app/room/[code]/RoomPageClient.tsx - Private Board Entry → BINGO Rules: validates board
components/game/MatrixEntry.tsx - Room Coordinator → Firestore Operations: submits boards
context/RoomContext.tsx - Live Game View → Game Actions: uses game actions
components/game/GameView.tsx - Game Actions → Firestore Operations: persists moves
hooks/useGame.ts - Live Game View → Board Grid: renders board
components/game/GameView.tsx - Board Grid → BINGO Rules: checks winning lines
components/game/BoardGrid.tsx - Live Game View → BINGO Progress: shows progression
components/game/GameView.tsx - Live Game View → Opponent Tracking: shows opponents
components/game/GameView.tsx - Live Game View → Game Chat: loads chat
components/game/GameView.tsx - Live Game View → Leaderboard: loads standings
components/game/GameView.tsx - Live Game View → Live Moves Feed: shows live moves
components/game/GameView.tsx - Live Game View → Win Screen: shows result
components/game/GameView.tsx - Firebase Auth → Firebase Client: uses client
lib/firebase/auth.ts - Firestore Operations → Firebase Client: uses client
lib/firebase/firestore.ts - Realtime Subscriptions → Firebase Client: uses client
lib/firebase/realtime.ts - Firestore Operations → Firestore Store: reads and writes
lib/firebase/firestore.ts