Add dark/light mode toggle and coolors.co palettes

Admin UI:
- system / light / dark switch in the sidebar (cycle button on
  mobile), stored in localStorage and applied before first paint
- dark mode now driven by data-theme instead of only the media query

Link page themes:
- keep the Midnight and Paper presets, replace the others with the
  4 trending palettes from coolors.co
- paste a coolors.co link (or a bare hex list) to use any palette;
  the colors are read from the URL, nothing is fetched
- palettes are mapped to background, text and button colors by
  contrast, with a dark/light background choice

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-10-14 16:27:21 +02:00
co-authored by Claude Opus 5.5
parent 74ce76ab8b
commit 624517e010
13 changed files with 477 additions and 82 deletions
+1 -1
View File
@@ -51,7 +51,7 @@ export function OverviewScreen({ me }: { me: Me }) {
const links = all.filter((p) => p.kind === "redirect");
const linkPages = all.filter((p) => p.kind === "linkpage");
const clicks = all.reduce((sum, p) => sum + p.totalClicks, 0);
const scope = me.isAdmin ? "across all namespaces" : `in /${me.username}/`;
const scope = me.isAdmin ? "all users" : `in /${me.username}/`;
return (
<>