How sahilbhatti292005-cloud/techkbc works
TechKBC is a browser-based, multi-role trivia game. A host selects a role; the app routes users to game controls, team submission, or a projected display, while shared game state is synchronized through Firebase Realtime Database. The sampled code shows Fastest Finger First, timed Hot Seat questions, audience voting, lifelines, scoring, and game controls. AdminMobile handles score and team maintenance, while AdminLaptop controls rounds and timers. The README is a generic AI Studio setup description; feature details come from sampled source. Unsampled component behavior is represented only where supported by the source index.
Main entry points: App.tsx Role Router · AdminLaptop.tsx Host Controls · Volunteer.tsx Team Submission · AdminMobile.tsx Score Controls
Components 10
App and Routing
- Role Router
src/App.tsx
Game Operations
- Host Controls
src/components/AdminLaptop.tsx - Score Controls
src/components/AdminMobile.tsx - Question Bank
src/constants.ts
Player and Display
- Team Submission
src/components/Volunteer.tsx - Game Display
src/components/Display.tsx
Shared State
- Game State Types
src/types.ts - Firebase Client
src/lib/firebase.ts - Realtime Database
Other components
- Game Users
Connections 14
- Game Users → Role Router: choose role
src/App.tsx - Role Router → Host Controls: routes to
src/App.tsx - Role Router → Score Controls: routes to
src/App.tsx - Role Router → Team Submission: routes to
src/App.tsx - Role Router → Game Display: routes to
src/App.tsx - Role Router → Realtime Database: syncs game state
src/App.tsx - Host Controls → Question Bank: uses questions
src/components/AdminLaptop.tsx - Host Controls → Realtime Database: updates rounds
src/components/AdminLaptop.tsx - Score Controls → Realtime Database: updates scores
src/components/AdminMobile.tsx - Team Submission → Realtime Database: submits answers
src/components/Volunteer.tsx - Team Submission → Realtime Database: casts votes
src/components/Volunteer.tsx - Game Display → Firebase Client: reads server time
src/components/Display.tsx - Firebase Client → Realtime Database: connects to
src/lib/firebase.ts - Role Router → Game State Types: uses state types
src/App.tsx