- dark tokens move from prefers-color-scheme to :root[data-theme="dark"];
light is the default for everyone regardless of OS preference
- choice persisted in localStorage (artiot-theme), applied to <html> at
module load so the login screen themes before first paint
- Account page gains an Appearance section with a squared slide switch;
meta theme-color follows the active theme
- non-admins now see ONLY their own sessions in /api/sessions (own app
starts + own linked cards); gun scopes grant control, not visibility;
admins see everything
- Account page shows the logged-in user's permissions in plain words
(Administrator badge, or the guns/relays they control), built solely
from data already visible to them
- Start button arms only when the gun reports Preparing (cable in the
car); idle unplugged gun shows an explanatory hint instead
- keep owner's app rename to 'Art IoT'
- smoke test: 59 checks (gun-scoped user sees no foreign sessions)
Frontend rewrite (frontend/, replacing backend/static/):
- Vite + TypeScript + React 19, React Router 7, zustand, TanStack Query 5
- dev: vite proxy /api -> :9000; prod: npm run build -> dist/, served by
the backend with SPA fallback
- pages: Control (gun bays w/ scope+readiness-gated start/stop, relays),
History (who/via/gun/when/duration/kWh audit), Cards (pending review,
enrolled, rejected), Users (permission checkbox matrix)
- self-contained: fonts bundled, no CDN; light/dark; reduced-motion safe
Backend:
- learn mode removed: unknown cards are always refused and queued in
pending_cards; admin approves (name + owner + gun restrictions in one
step) or rejects (denied_cards, silent, un-rejectable); pending count
rides /api/status as the notification signal
- sessions record the auth method (card tap vs in-app button) for audit
- GET /api/permissions: grantable-permission catalog driving the UI matrix
- SPA static serving with path-traversal guard; 503 hint when not built
Smoke test: 54 checks incl. approve/reject round-trips over a fake charge
point and method audit assertions.