Fix dark mode and bring the public design in line with the taste audit

- Dark mode: the countdown card, timeline section, Giving text, error
  text, the Leadership button, skeletons and the admin's dark text all
  follow the tokens; logos get a light plate in dark mode
- One BRAND accent (the button token, so the admin palette reaches
  every page) and one ACCENTS family in color.ts, replacing 20 local
  teal constants and the purple, ochre and rust section colours;
  neon green and gold become mint and brand green
- Shadows are tinted with the site's ink; glow shadows are gone
- One giving label, Give, in the nav, footer and Giving page
- Phosphor icons replace the hand-drawn SVGs and the glyph icons;
  Pathfinder paths pick a named icon (emoji still shown) and lose the
  watermark
- Home keeps two eyebrows; StatsBand's title is a real heading;
  section headings step down under the page title
- Nav links switch to the menu below lg, so they never wrap; jump
  links land clear of the header; press feedback on buttons
- Empty sections say what's coming and who to ask; loading is a
  skeleton; form placeholders and borders are readable; one
  corner-radius rule; theme-color for both modes

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
Zaldimmar 2026-09-29 02:54:03 -05:00
parent f72a9604d2
commit 048c7599ce
59 changed files with 416 additions and 350 deletions

View file

@ -18,9 +18,8 @@ import { useCallback, useEffect, useRef, useState, type ReactNode } from "react"
import { Link } from "react-router-dom";
import { ApiError, del, get, post } from "../../lib/api.ts";
import { accentText } from '../../lib/color.ts'
import { accentText, BRAND } from '../../lib/color.ts'
const TEAL = "#0f7183";
const MUTED = "var(--color-muted)";
const POLL_MS = 2000;
@ -234,7 +233,7 @@ function Editor({ source, onMade }: { source: Job; onMade: () => void }) {
<button
type="button"
className="text-sm underline"
style={{ color: accentText(TEAL) }}
style={{ color: accentText(BRAND) }}
onClick={() => {
if (videoRef.current) videoRef.current.currentTime = value;
}}
@ -245,7 +244,7 @@ function Editor({ source, onMade }: { source: Job; onMade: () => void }) {
</div>
))}
</div>
<p className="text-sm" style={{ color: end > start ? MUTED : "#b3261e" }}>
<p className="text-sm" style={{ color: end > start ? MUTED : "var(--color-danger)" }}>
{end > start ? `Clip length: ${clock(end - start)}` : "The start has to be before the end."}
</p>
@ -359,7 +358,7 @@ export default function AdminClips() {
}
if (!data) {
return <p style={{ color: loadError ? "#b3261e" : MUTED }}>{loadError ?? "Loading…"}</p>;
return <p style={{ color: loadError ? "var(--color-danger)" : MUTED }}>{loadError ?? "Loading…"}</p>;
}
const missing = [!data.tools.ytdlp && "yt-dlp", !data.tools.ffmpeg && "ffmpeg"].filter(Boolean);
@ -481,7 +480,7 @@ export default function AdminClips() {
</>
)}
{clip.saved_url && (
<Link to="/admin/media" className="text-sm underline" style={{ color: accentText(TEAL) }}>
<Link to="/admin/media" className="text-sm underline" style={{ color: accentText(BRAND) }}>
In the media library
</Link>
)}

View file

@ -16,6 +16,7 @@
record) wants to be a separate component that fails on its own.
═══════════════════════════════════════════════════════════════ */
import { ArrowRight, ArrowUpRight } from "@phosphor-icons/react";
import { Link } from "react-router-dom";
import { useAuth } from "../../lib/auth.tsx";
import { SITE_VERSION } from "../../lib/version.ts";
@ -48,7 +49,7 @@ function NavCard({ item }) {
aria-hidden="true"
className="ml-auto text-link opacity-0 transition-opacity group-hover:opacity-100"
>
→
<ArrowRight size="1em" weight="bold" className="inline align-[-0.125em]" aria-hidden="true" />
</span>
</div>
@ -139,7 +140,7 @@ export default function AdminHome() {
{/* Sticky so it stays put once the card column outgrows it. */}
<aside className="divide-y divide-brand/10 rounded-2xl border border-brand/20 bg-surface lg:sticky lg:top-6">
<PanelSection title="Signed in">
<p className="font-medium text-[#0f2f36]">{user?.name || user?.email}</p>
<p className="font-medium text-ink">{user?.name || user?.email}</p>
{user?.name && user?.email && (
<p className="mt-0.5 break-all text-xs text-muted/80">{user.email}</p>
)}
@ -173,7 +174,7 @@ export default function AdminHome() {
rel="noreferrer"
className="mt-2 inline-block underline-offset-4 transition-colors hover:text-link hover:underline"
>
View the public site ↗
View the public site <ArrowUpRight size="1em" weight="bold" className="inline align-[-0.125em]" aria-hidden="true" />
</a>
</PanelSection>
</aside>

View file

@ -36,7 +36,7 @@ const GOOGLE_ERRORS: Record<string, string> = {
};
const fieldClass =
"w-full rounded-xl border border-muted/25 bg-surface px-4 py-3 text-body " +
"w-full rounded-xl border border-muted/50 bg-surface px-4 py-3 text-body " +
"outline-none transition-colors focus:border-brand focus:ring-2 focus:ring-brand/25";
export default function AdminLogin() {

View file

@ -68,7 +68,7 @@ function Stat({ label, value }) {
<div className="text-xs font-medium uppercase tracking-wider text-muted/70">
{label}
</div>
<div className="mt-1 break-words text-sm font-medium text-[#0f2f36]">{value}</div>
<div className="mt-1 break-words text-sm font-medium text-ink">{value}</div>
</div>
);
}
@ -198,7 +198,7 @@ export default function AdminPanel() {
className="rounded-full border border-brand/20 bg-surface px-3 py-1 text-sm text-muted"
>
{row.label}{" "}
<strong className="font-semibold text-[#0f2f36]">
<strong className="font-semibold text-ink">
{row.count ?? "-"}
</strong>
</span>
@ -232,7 +232,7 @@ export default function AdminPanel() {
return (
<tr key={row.id} className={row.is_active ? "" : "bg-tint-soft"}>
<td className="px-4 py-3">
<div className="font-medium text-[#0f2f36]">
<div className="font-medium text-ink">
{row.name || row.email}
{isMe && (
<span className="ml-2 text-xs font-normal text-muted/70">
@ -255,7 +255,7 @@ export default function AdminPanel() {
value={row.role}
disabled={locked || busy}
onChange={(e) => changeRole(row, e.target.value)}
className="rounded-lg border border-brand/30 bg-surface px-2 py-1 text-sm text-[#0f2f36] disabled:cursor-not-allowed disabled:bg-tint-soft disabled:text-muted/60"
className="rounded-lg border border-brand/30 bg-surface px-2 py-1 text-sm text-ink disabled:cursor-not-allowed disabled:bg-tint-soft disabled:text-muted/60"
title={
isMe
? "You can't change your own role."
@ -314,7 +314,7 @@ export default function AdminPanel() {
<dl className="mt-4 grid gap-x-6 gap-y-1.5 text-sm sm:grid-cols-2">
{ROLES.map((role) => (
<div key={role} className="flex gap-2">
<dt className="shrink-0 font-medium text-[#0f2f36]">
<dt className="shrink-0 font-medium text-ink">
{ROLE_LABELS[role]}
</dt>
<dd className="text-muted">{ROLE_NOTES[role]}</dd>

View file

@ -46,6 +46,7 @@
why the array form exists and teams uses it.
═══════════════════════════════════════════════════════════════ */
import { ArrowLeft } from "@phosphor-icons/react";
import { useCallback, useEffect, useMemo, useRef, useState } from "react";
import { useNavigate, useParams } from "react-router-dom";
@ -358,7 +359,7 @@ export default function EntityEdit() {
onClick={() => leave(`/admin/${manifest.key}`)}
className="text-sm text-muted hover:text-link"
>
← {manifest.label}
<ArrowLeft size="1em" weight="bold" className="inline align-[-0.125em]" aria-hidden="true" /> {manifest.label}
</button>
)}
@ -470,7 +471,7 @@ export default function EntityEdit() {
</div>
{/* Sticky action bar */}
<div className="fixed inset-x-0 bottom-0 border-t border-brand/20 bg-white/95 backdrop-blur">
<div className="fixed inset-x-0 bottom-0 border-t border-brand/20 bg-surface/95 backdrop-blur">
<div className="mx-auto flex max-w-5xl flex-wrap items-center gap-4 px-6 py-3">
{canWrite ? (
<>