web: add lambda favicon (svg + ico + apple-touch-icon)
Introduces the project mark — a Greek capital lambda Λ (initial of
Λήθη / Lethe) standing above a stylized rust ripple on a deep ink
plate. Reads as a glyph at 16 px; the ripple and inner rim emerge
at 32 px and above.
Three formats are shipped via web/public/ so Vite copies them
verbatim into the embedded dist bundle:
- favicon.svg canonical 64x64 vector source
- favicon.ico 16/32/48 multi-resolution legacy fallback
- apple-touch-icon.png 180x180 iOS home-screen bookmark
The ICO and PNG were rasterized from the SVG with rsvg-convert
(ImageMagick's built-in MSVG renderer drops strokes); magick is
only used to assemble the multi-image ICO container.
The dist/ placeholder index.html is regenerated alongside so a
fresh clone that hasn't run web-build yet still serves the icon
links from the committed fallback HTML.
web: review fixes for projects/stats SPA routes
- ProjectsTable: drop the inner navigate call from handleOpen;
the parent route already navigates via the onOpen callback,
so the second push was creating a duplicate history entry
on every row click. Matches the SessionsTable pattern.
- HorizontalBars: replace href:string with onActivate(row)
callback. The earlier shape passed a pre-encoded path
string straight into TanStack <Link to={...}>; routing the
navigation through the typed (to, params) form via the
caller avoids any double-encoding ambiguity around splat
params and decouples the primitive from a specific route.
- stats.css: drop duplicated .card / .card-head / .card-body
blocks. The same rules already live in shell.css (loaded
globally), so any future divergence between the two copies
would silently desync.
web: stats route with backend-driven chart primitives
web: project detail route scoped via ?cwd= sessions filter
web: projects index route with real /projects data
keyboard: guard g-leader and j/k against palette and editable targets
Add an early return after the ⌘K and Esc handlers so the g-prefix
dispatch, g-start, j/k cursor, and Enter activation skip when the
palette is open or the focused element is an input/textarea/contenteditable.
Without it, typing "gh" into the palette search input fires go("home")
mid-query, navigating away while the palette stays open.
Two regression tests added: g+h with palette open → no navigation; g
on a focused input → no pending state, follow-up h does nothing.
web: session view with turn list and transcript
Phase 6: replace the placeholder session route with the real implementation.
Adds useSession hook (TanStack Query), TurnList aside, Transcript with
react-markdown rendering, session.css, and the updated session route with
SubBar breadcrumb, error/loading states, and turn selection/scroll.
web: home route with real session list, filters, keyboard cursor
- api/client.ts: apiFetch with AuthError/APIError, 401 and problem+json handling
- api/adapters.ts: SessionDTO→Session adapter with composite id and epoch conversion
- api/adapters.test.ts: 6 TDD tests covering all specified edge cases
- features/home/useSessions.ts: TanStack Query hook with since/tool/host params
- features/home/FilterChips.tsx: chip-bar with popovers, Esc/outside-click dismiss
- features/home/SessionsTable.tsx: grid table with cursor row highlight, formatStarted/formatTok
- features/home/useHomeCursor.ts: cursor hook with move/activate/jumpTo
- routes/index.tsx: Home route wired to real data, URL-driven filters, keyboard cursor
- routes/__root.tsx: cursorRef + KeyboardCursorContext for route-local cursor registration
- routes/session.$tool.$host.$id.tsx: stub for Phase 6
- styles/home.css: .home-table/.home-thead/.home-row/.home-row.cursor grid rules
- primitives/ToolDot.tsx: widened tool prop to string (Tool type is open-ended)
web: shell, theme, keyboard, stub routes, palette skeleton
- lib/theme.ts: bootstrapTheme() + setTheme() with OS/localStorage sync
- lib/keyboard.ts: g-prefix nav, j/k cursor, ⌘K palette, Esc, Enter
- lib/theme.test.ts + lib/keyboard.test.ts: 26 vitest tests (TDD)
- shell/TopBar.tsx: brand crumb, search trigger, tab nav using router pathname
- shell/SubBar.tsx: slot component with optional right section
- shell/Palette.tsx: modal overlay, JUMP items, synthetic SEARCH row
- styles/shell.css + styles/palette.css: ported verbatim from prototype.css
- routes/__root.tsx: wires TopBar, Outlet, Palette, keyboard controller, bootstrapTheme
- routes/index.tsx + projects/stats/health/settings/search.tsx: EmptyState stubs
- main.tsx: replace scaffold div with RouterProvider
- vitest.config.ts: add jsdom url for localStorage support (Node 25 compat)
server: embed web SPA at /, wire build pipeline
- Add internal/server/web/embed.go with //go:embed all:dist and a
SPA fallback shim: file-not-found → serve index.html at 200.
- Commit dist/.gitkeep and dist/index.html (placeholder) so go build
works on a fresh clone; real build output stays gitignored.
- Mount web.Handler() as GET /* catch-all in server.go after /api/v1
so API routes and probe endpoints shadow the wildcard.
- Add three server tests: ServesSPAAtRoot, SPAFallbackForNonAPIPath,
APIPathsBypassSPA; update NotFoundReturnsProblemJSON for SPA era.
- Extend Justfile with web-{install,dev,build,test,lint,clean} targets;
build now depends on web-build.
- Add node:20-alpine web-builder stage to Dockerfile; COPY dist into
the Go builder stage before compiling.
web: scaffold vite/react/ts project, port design tokens and primitives
- package.json with runtime (react, tanstack-query, tanstack-router) and
dev deps (vite, typescript, vitest, eslint, prettier, testing-library)
- vite.config.ts: @vitejs/plugin-react + TanStack Router file-based plugin;
dev proxy for /api/v1, /healthz, /readyz, /metrics with Remote-User header;
build.outDir set to ../internal/server/web/dist (Go embed target)
- tsconfig.json (strict, ES2022, react-jsx, bundler resolution) + tsconfig.node.json
- .eslintrc.cjs (eslint 8 + @typescript-eslint + react-hooks), .prettierrc (single quotes, no semis)
- index.html: Inter + JetBrains Mono fonts, body.density-compact, #root mount
- src/main.tsx: React root with QueryClientProvider, temporary scaffold div
- src/styles/tokens.css: verbatim :root and [data-theme="dark"] blocks from prototype.css
- src/styles/primitives.css: .tag, .tooldot, .spark, .statusdot, .empty, .sub rules
- src/primitives/{Tag,ToolDot,Spark,StatusDot,EmptyState,Sub}.tsx with typed signatures
- src/primitives/index.ts re-exports all primitives
- web/.gitignore: node_modules/, coverage/
- root .gitignore: web/node_modules/, internal/server/web/dist/* with .gitkeep exception
- vitest.config.ts separate from vite to avoid router plugin scan error on empty routes dir
- src/routes/__root.tsx minimal root route to satisfy TanStack Router plugin at build time