Thanks to visit codestin.com
Credit goes to github.com

Skip to content

archivewebsite/chess

Repository files navigation

Cloud Chess Studio (Authenticated)

This project now uses authenticated Supabase storage so all user data is saved in one Supabase database and scoped to each logged-in user.

Stack

  • Lichess board UI: @lichess-org/chessground
  • Lichess-compatible chess logic: chessops
  • Lichess media assets from the lila repository (2D + 3D pieces, boards, sounds)
  • Supabase Auth + Postgres + Realtime

Files

  • login.html and signup.html: creative auth pages
  • auth.css, auth.js: auth UX and flows
  • supabase-client.js: shared Supabase config/session client
  • index.html, styles.css, app.js: main chess app (auth-gated)
  • supabase.sql: schema, triggers, RLS, and realtime setup

First-time setup

  1. Open your Supabase SQL editor.
  2. Run supabase.sql.
  3. Serve this folder over HTTP (not file://):
python -m http.server 8080
  1. Open http://localhost:8080/login.html.
  2. Enter Supabase URL + anon key in the auth page settings.
  3. Sign up or login.

Data model

  • profiles: username + display name per user
  • user_settings: board/piece/sound/sync preferences per user
  • chess_games: user-owned games (moves, captures, status, realtime updates)

All reads/writes are restricted by RLS to auth.uid() ownership.

Notes

  • Promotion is auto-queen by default.
  • If your Supabase project requires email confirmation, signup may require confirming email before login.
  • Chess user data (profile, settings, games) is persisted in Supabase tables; only Supabase project URL/key are cached locally to simplify reconnecting.
  • Chessground/chessops are GPL-licensed. If you deploy this app publicly, comply with GPL requirements.

About

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors