Initial TopDeck: self-hosted ranked favorites

A single Go binary with SQLite that serves a public page of the owner's
ranked lists (movies, TV, albums, songs, video games, theater) and a
login-gated editor.

- Lists of 1–65,535 entries (100 recommended), several per category
- Search-to-add via TMDB, TheTVDB, IGDB, Deezer/MusicBrainz, Wikipedia;
  manual entry as a fallback
- Theater entries carry a production (Broadway, tour, …), venue and cast
- Artwork cached locally; URL override and uploads
- Drag, arrow and type-a-rank reordering; paginated for long lists
- 12 theme presets plus custom CSS
- First-run setup code or env-provided admin; bcrypt, rate-limited login,
  CSRF-guarded JSON API
- Dockerfile and docker-compose.yml

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
cdnutterandClaude Opus 5.5 committed 2026-09-24 16:54:19 -07:00
commit e9a75a968a
53 files changed
+7078

No files matched your search

+35
View File
@@ -0,0 +1,35 @@
package server
// Theme is a built-in color preset. The actual colors live in
// web/static/css/themes.css under [data-theme="<key>"].
type Theme struct {
Key string `json:"key"`
Label string `json:"label"`
Dark bool `json:"dark"`
}
var Themes = []Theme{
{"midnight", "Midnight", true},
{"obsidian", "Obsidian", true},
{"nord", "Nord", true},
{"dracula", "Dracula", true},
{"mocha", "Mocha", true},
{"rose-pine", "Rosé Pine", true},
{"gruvbox", "Gruvbox", true},
{"forest", "Forest", true},
{"synthwave", "Synthwave", true},
{"daylight", "Daylight", false},
{"paper", "Paper", false},
{"latte", "Latte", false},
}
const DefaultTheme = "midnight"
func validTheme(key string) bool {
for _, t := range Themes {
if t.Key == key {
return true
}
}
return false
}