Phase 8: share panel, polish, accessibility and deploy config
- Share links section: scoreboard link, every judged game's judge links and open link with QR codes, and 'Copy all judge links' as plain text for WhatsApp. Warns when links point at localhost. - Error and not-found pages with plain-language copy; a real start page. - Accessibility: darker 'alert strong' red for text and white-on-red (Alert was 4.0:1 on white), no text below 70% ink, 44px block buttons and link targets, scoreboard status stays readable when idle. - vercel.json pins functions to Dublin next to the West EU database; README documents deployment and pre-game-night checks. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -34,7 +34,36 @@ an admin control room, a projector scoreboard, and per-game judge links.
|
||||
- Open `docs/KICKOFF_PROMPT.md`, paste its contents into Claude Code.
|
||||
- Let it go phase by phase. After each phase: run it, click around, commit, then say "next phase".
|
||||
|
||||
## Tips
|
||||
## Commands
|
||||
|
||||
- Keep `docs/` as the source of truth. If you change your mind on a feature, edit the doc first, then tell Claude Code "I updated PRD.md section X, implement it".
|
||||
- Test the scoreboard on the actual projector PC + one judge on a phone before game night. Wi-Fi at church is the #1 thing that'll bite you.
|
||||
| Command | What it does |
|
||||
|---|---|
|
||||
| `npm run dev` | Run locally at http://localhost:3000 |
|
||||
| `npm run test` / `npm run test:coverage` | Unit tests (scoring engine must stay at 100%) |
|
||||
| `npm run lint` / `npm run build` | Lint / production build |
|
||||
| `npm run check:rls` | Proves the anon key cannot read or write any table |
|
||||
| `npm run gen:types` | Regenerate `src/lib/database.types.ts` after a migration |
|
||||
|
||||
## Deploying to Vercel
|
||||
|
||||
1. Push this repo to GitHub, then in Vercel choose **Add New → Project** and import it.
|
||||
2. Add these environment variables in Vercel (Production): `NEXT_PUBLIC_SUPABASE_URL`,
|
||||
`NEXT_PUBLIC_SUPABASE_ANON_KEY`, `SUPABASE_SERVICE_ROLE_KEY`, `ADMIN_EMAILS`,
|
||||
`NEXT_PUBLIC_APP_NAME`, and `NEXT_PUBLIC_SITE_URL` set to the site's address
|
||||
(e.g. `https://your-project.vercel.app`, no trailing slash). The build fails with a clear
|
||||
message if any is missing.
|
||||
3. Deploy. `vercel.json` runs the server functions in Dublin (`dub1`), next to a West EU
|
||||
Supabase project; change it if your database is elsewhere.
|
||||
4. In Supabase → Authentication → URL Configuration, set **Site URL** to the Vercel address and
|
||||
add `https://your-project.vercel.app/auth/confirm` to **Redirect URLs** (keep the localhost
|
||||
one for development).
|
||||
5. If you change `NEXT_PUBLIC_SITE_URL` later, redeploy: share links and QR codes are built from it.
|
||||
|
||||
## Before game night
|
||||
|
||||
- Free Supabase projects pause after about a week without use. Open the Supabase dashboard a
|
||||
day before and click **Restore** if it is paused.
|
||||
- Sign in as host the day before; the magic-link email is limited to a few per hour.
|
||||
- Test the scoreboard on the actual projector PC and one judge link on a phone, on the venue's
|
||||
Wi-Fi. The scoreboard also polls every 10 seconds if live updates are blocked.
|
||||
- Keep `docs/` as the source of truth: change the doc first, then the code.
|
||||
|
||||
Reference in New Issue
Block a user