Files
xarmian e09b11cc2e feat(attachments): in-app previews for text, Markdown and CSV/TSV (TASK-4074) (#2310)
* feat(attachments): add bounded CSV and TSV parser (TASK-4074)

* feat(attachments): add capped table preview component (TASK-4074)

* feat(attachments): enforce exact preview types and renderer byte caps (TASK-4074)

* feat(attachments): mount table previews in bounded cell steps (TASK-4074)

* feat(attachments): add raw markdown and text wrap controls (TASK-4074)

* test(attachments): accommodate full-suite table coverage (TASK-4074)

* fix(attachments): allow native table touch scrolling (TASK-4074 r1)

* fix(attachments): focus and label the table scroll region (TASK-4074 r1)

* fix(attachments): preserve preview choices on metadata fills (TASK-4074 r1)

* fix(attachments): prove both navigation toggle resets (TASK-4074 r1)

* fix(attachments): skip blank delimited-file lines (TASK-4074 r1)

* fix(attachments): preserve literal quotes in delimited fields (TASK-4074 r1)

* fix(attachments): preserve wide table arrow scrolling (TASK-4074 r2)

* fix(attachments): preserve Wrap within its default class (TASK-4074 r2)

* fix(attachments): truncate CSV cells by code point (TASK-4074 r2)

* fix(attachments): cover table row resets on input changes (TASK-4074 r2)

* test(e2e): the text card pans on both axes (TASK-4074)

The card's touch-action is now pan-x pan-y, so a wide table or an
unwrapped line can pan sideways; the IDEA-2712 spec still pinned pan-y.
No viewer gesture collides: pan/pinch arm only over a decoded bitmap
and nothing swipes between attachments. The stage-is-not-none leg
stays.

Claude-Session: https://claude.ai/code/session_017ofcsFmgnoVDPxeHwuxCjg

* docs(attachments): the text card's touch-action comments say pan-x pan-y (TASK-4074)

Comment-only: two CSS comments still named the pre-TASK-4074 pan-y.

Claude-Session: https://claude.ai/code/session_017ofcsFmgnoVDPxeHwuxCjg
2026-10-25 04:29:31 -04: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
    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