Phase 13: questions, sounds and videos on the scoreboard
A game can now carry a list of items the host puts on the scoreboard one at a time: a question (shown above the standings, with an optional picture and an answer to reveal), a sound (played through the scoreboard's speakers) or a video such as a karaoke track (takes over the screen). - Media is a YouTube link, an https link to a file, or an upload to the private game-media bucket. The scoreboard API signs a URL only for the item that is on screen. - What is on screen is state on the event, like the timer, so the ping still carries no data. An unrevealed answer and a sound's or video's name never reach the scoreboard payload. - Control room: click an item to show it, or "Random" to have one picked (prefers items not played yet). Show/hide answer, pause, take off screen; shortcuts Q / A / X. - Duplicating a game or event copies its items and files; deleting removes the files. Needs supabase/migrations/0006_screen_items.sql applied before deploying. database.types.ts was edited by hand to match; re-run gen:types after. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -89,5 +89,16 @@ in the scoring grid and on the scoreboard; "Undo" takes it back; "Next question"
|
||||
run the control room alongside A, but has no Delete button and can't change the co-hosts; removing B
|
||||
makes the event disappear from B's list.
|
||||
|
||||
## Phase 13 — Questions, sounds and videos on the scoreboard
|
||||
- Apply `supabase/migrations/0006_screen_items.sql` (table, event columns, the `game-media`
|
||||
bucket and its policies), then `npm run gen:types` and `npm run check:rls`.
|
||||
- Rules in `src/lib/screen.ts` (tested); setup editor per game with links and uploads;
|
||||
control-room panel (show, random, answer, pause, take off screen; `Q` / `A` / `X`).
|
||||
- Scoreboard: question above the standings, sound banner, video takeover.
|
||||
**Done when:** a quiz game shows its questions one by one with `Q` and reveals an answer with `A`
|
||||
(the answer is not in the scoreboard's network tab before that); an uploaded mp3 plays on the
|
||||
scoreboard; a karaoke game with several YouTube links plays the one I click full screen, "Random
|
||||
video" picks one that hasn't been played, and "Take off screen" brings the standings back.
|
||||
|
||||
## Stretch (only if asked)
|
||||
Participants within teams · CSV export of results.
|
||||
|
||||
Reference in New Issue
Block a user