Files
pad/web
xarmian 841a2cb4ea feat(web): violet retheme — accent-primary alias, neutral scale, card tokens, radius, AA text (TASK-2291) (#1018)
* feat(web): violet retheme — accent-primary, neutral scale, card tokens, radius, AA text (TASK-2291)

PLAN-2290 Phase 1, PR B. Values-only retheme in app.css + theme-color meta:

- --accent-primary #9268f8 dark / #7c3aed light; --accent-blue aliased to it
  (~95% of its 462 sites are brand usage; categorical sites moved to
  --status-blue in PR A and stay blue). Dark value chosen by contrast math:
  AA as link text (4.85:1) while improving white-on-fill from 2.75 to 3.78
  (>=3:1 UI threshold; full text-on-fill AA lands with the Phase 2 Button
  primitive via --text-on-accent).
- Violet-biased neutral scale both themes; light mode inverts to off-white
  canvas (#f5f5f9) with white surfaces per the mock.
- Muted/secondary text re-picked: >=5:1 on every bg token in both themes
  (closes TASK-2262 C9 app-wide).
- --border-strong/--card-bg/--card-border/--shadow-card defined both themes
  (consumed from Phase 3).
- Radius scale 6/4/8 -> 8/5/12; light-mode danger tuned to #dc2626 (4.83:1).
- theme-color meta #4a9eff -> #8b5cf6.

Verified: make check green; screenshots on 4 surfaces x 2 themes reviewed;
contrast ratios computed for all text-token pairs.

* fix(web): violet PWA branding (manifest/icon) + pin light accents in print block

Codex review findings on #1018: manifest theme_color/background and icon.svg
still carried the blue brand; print block now pins light-theme accents so
dark-theme printing doesn't put the bright violet on white paper. Dark
button text-on-fill AA is explicitly deferred to the Phase 2 Button
primitive (tracked in TASK-2292).

* fix(web): regenerate apple-touch-icon.png from the violet icon.svg (180x180)

* fix(web): regenerate remaining brand rasters from violet icon.svg

favicon-16/32, favicon.ico (single PNG-encoded 48px entry), icon-192 (was
0 bytes), icon-512, padicon.png (OG image, 701x701) all regenerated from
the canonical icon.svg 'P' mark — the old rasters were a blue calendar
design inconsistent with the linked SVG. site.webmanifest colors updated
to the violet scheme.
2026-07-24 14:03:53 -04:00
..
2026-03-26 01:52:36 +00:00
2026-03-26 01:52:36 +00:00
2026-03-26 01:52:36 +00:00
2026-03-26 01:52:36 +00:00
2026-03-26 01:52:36 +00:00

Pad Web UI

SvelteKit 2 + Svelte 5 frontend for Pad, compiled to static files and embedded into the Go binary.

Development

npm install
npm run dev          # Dev server at localhost:5173 (proxies API to localhost:7777)
npm run build        # Production build to build/
npm run check        # Type checking with svelte-check

When developing, run the Go backend separately with make dev from the project root.

Building for Production

Do not build in isolation. Always use make build from the project root — this builds the web frontend, then compiles the Go binary with the build output embedded via //go:embed.

Stack

  • Svelte 5 with runes ($state, $derived, $effect)
  • SvelteKit 2 with adapter-static (SPA mode)
  • Tiptap block editor with markdown round-trip
  • svelte-dnd-action for drag-and-drop in board/list views
  • SSE for real-time updates
  • TypeScript throughout

Structure

src/
  routes/                    SvelteKit pages
    +layout.svelte           App shell (sidebar + main)
    +page.svelte             Landing/redirect
    [workspace]/
      +page.svelte           Dashboard (collections, phases, activity)
      +layout.svelte         SSE connection per workspace
      [collection]/
        +page.svelte         Collection view (board/list)
      [collection]/[item]/
        +page.svelte         Item detail + editor
      conventions/            Purpose-built conventions page
      playbooks/              Purpose-built playbooks page
      settings/               Workspace settings
  lib/
    api/client.ts            HTTP API client
    components/
      layout/                Sidebar, navigation
      editor/                Tiptap editor, raw markdown editor
      fields/                FieldEditor, relation picker
      items/                 ItemCard, ItemDetail
      collections/           BoardView, ListView
      common/                StatusBadge, badges, modals
      search/                CommandPalette
      activity/              ActivityFeed
    stores/                  Svelte 5 reactive stores
      workspace.svelte.ts    Workspace state
      collections.svelte.ts  Collection + item state
      ui.svelte.ts           Sidebar, mobile state
    types/index.ts           TypeScript types and constants
  app.css                    Global styles and design tokens