30 Commits

Author SHA1 Message Date
xarmian eb4e41ad0b build(embed): stop rewriting embed.go for TASK-112 (#32) 2026-04-01 15:00:18 -04:00
xarmian a6befde8bf feat: email-based password reset flow (#24)
* feat: email-based password reset flow (IDEA-81)

Add full password reset flow: forgot password request, time-limited
reset tokens (1hr, single-use, SHA-256 hashed), new password form,
and automatic session creation after reset.

* fix: use all: prefix in go:embed to include _-prefixed files

Go's embed package excludes files starting with _ or . when recursing
directories. SvelteKit/Vite occasionally generates chunk filenames with
_ prefixes (e.g. _VLZtjCJ.js), causing them to be silently dropped
from the embedded filesystem and served as HTML by the SPA fallback.

The all: prefix includes everything regardless of filename prefix.
Fixed in both embed.go and the Makefile which regenerates it.

* fix: address PR review — atomic token consumption, error handling, log reset URL

- Replace ValidatePasswordReset + MarkPasswordResetUsed with atomic
  ConsumePasswordReset using UPDATE ... WHERE ... RETURNING to prevent
  race conditions where two concurrent requests consume the same token
- Handle DeleteUserSessions errors (log instead of silently ignoring)
- Log the full reset URL when email is not configured so the admin
  CLI fallback is actually usable
2026-03-29 19:31:16 -04:00
xarmian d94a28c3e8 feat: account settings, email infrastructure, and UX polish (#23)
- Add Account tab to settings: profile editing, password change, API token management
- Add PATCH /api/v1/auth/me endpoint for profile updates with password verification
- Add email sending infrastructure via Maileroo with contextual sender names
- Add Platform settings tab (admin-only) for email configuration with test send
- Add platform_settings table for instance-wide configuration
- Add tab visibility refresh: silently sync data when browser tab regains focus
- Fix filters icon: replace broken Unicode character with proper SVG funnel
- Add cancel invitation support, TypeScript User/APIToken types
2026-03-29 18:29:52 -04:00
xarmian 992690f77d fix: split item detail meta section into two rows for mobile readability (#21)
The meta area (timestamps + action buttons) was a single flex row that
wrapped chaotically on narrow screens. Split it into a `.meta-info` row
for timestamps/save status and a separate `.meta-actions` row for buttons,
both with flex-wrap. Renamed `.history-btn` to `.action-btn` with
consistent sizing (min-width, white-space: nowrap).

Closes IDEA-71
2026-03-29 08:21:52 -04:00
xarmian a49d7606dd fix: prevent layout jump from save status transitions on mobile (#20)
Replace conditional {#if} rendering of save status with always-present
span using opacity transitions. Element stays in the DOM flow so the
flex row never reflows when state changes.
2026-03-29 07:58:35 -04:00
xarmian c7dc653c10 fix: debounce activity entries to prevent autosave flood (#19)
Rapid saves to the same item by the same user within 5 minutes now
coalesce into a single activity entry instead of creating one per save.
SSE events still fire every time for real-time UI updates.
2026-03-29 07:53:36 -04:00
xarmian a219f81633 fix: CLI and skill file now use issue IDs (TASK-5) instead of slugs (#15)
Agents were using verbose slugs because:
1. The skill file (SKILL.md) taught them to use `<slug>` in every example
2. CLI output showed slugs in parentheses rather than issue IDs
3. CLI usage strings said `<slug>` not `<ref>`
4. JSON output lacked a `ref` field, so agents parsing JSON only saw slugs

Changes:
- Add computed `ref` field to Item model (e.g. "TASK-5") in JSON output
- CLI create/update/delete/edit output now prominently shows issue IDs
- All CLI usage strings changed from `<slug>` to `<ref>`
- Issue IDs displayed in bold cyan (not dim) in list/show/grouped views
- Skill file rewritten to use issue IDs in all examples and instructions
- Dashboard API includes `item_ref`/`ref` in attention, suggestions, phases
- Search results now include item_number and collection_prefix for refs
- CLAUDE.md updated to document issue ID usage
2026-03-28 16:14:32 -04:00
xarmian c2527395aa chore: Rebuild embedded assets 2026-03-28 14:15:06 +00:00
xarmian cdd3dcdc50 fix: Remove incomplete webhook/bulk-update command registrations
The agent registered webhooksCmd() and bulkUpdateCmd() but hasn't
written the implementations yet. Remove the registrations to fix
the build. They'll be re-added when the implementations are complete.
2026-03-28 14:08:53 +00:00
xarmian 66d650155c chore: Rebuild embedded assets with updated skill and conventions 2026-03-28 13:56:44 +00:00
xarmian 40fc3eab33 feat: Add standup, changelog, watch, and dependency CLI commands
- pad standup: Auto-generate daily standup from recent activity
  (completed/in-progress/blockers, --days flag, JSON output)
- pad changelog: Generate release notes grouped by collection
  (--days, --since, --phase flags, markdown output for GitHub releases)
- pad watch: Real-time terminal activity stream via SSE
  (colored output, graceful Ctrl+C shutdown)
- pad blocks/blocked-by/deps/unblock: Task dependency management
- Colorized pad init, pad onboard, pad show, and pad status output
  with Active Work section showing in-progress items
2026-03-28 13:54:52 +00:00
xarmian 6daa8eb68b Add move item between collections with field migration
Full-stack feature: move items between collections (e.g., idea → task)
with automatic field migration.

Backend:
- Field migration engine (items/migrate.go) maps matching fields,
  handles type conversions, drops incompatible fields, applies defaults
- Store method updates collection_id and assigns new item_number
- POST /api/v1/workspaces/{ws}/items/{slug}/move endpoint
- Activity logging with "moved" action and from/to metadata
- 6 migration unit tests covering type matching, conversion, and edge cases

CLI:
- pad move <slug> <target-collection> [--field key=value ...]
- Accepts singular collection names (task, idea, bug, etc.)

Web UI:
- "Move to..." dropdown on item detail page
- Shows all collections except current with icons
- Redirects to the item's new URL after move

Field migration rules:
- Same type: transfer directly (validate select options)
- Compatible types (text↔url, number→text, select→text): auto-convert
- Incompatible types: drop silently
- Missing required target fields: apply defaults or error
2026-03-28 05:01:40 +00:00
xarmian d41842ef7a Enhance dashboard with in-progress focus section and agent activity badges
Dashboard improvements:
- New "In Progress" section at the top showing clickable chips for
  collections with in-progress items — jump straight to what you're
  working on
- Agent activity gets a purple left-border and "AGENT" badge in the
  activity feed, making AI contributions visually distinct
- CLI activity gets a blue "CLI" badge
- Removed redundant "by you via web" text — the badges are cleaner

The dashboard now clearly shows the human-agent collaboration story:
you can see at a glance what the AI has been doing alongside you.
2026-03-28 04:50:34 +00:00
xarmian 5bcdf9a1ab Add keyboard navigation for collection pages
j/k or arrow keys to move between items, Enter to open, Esc to clear
focus. Works in both list and board views. Focused item gets a blue
outline ring and auto-scrolls into view.

Skips keyboard handling when typing in inputs or when the quick-create
bar is open. Doesn't conflict with existing Cmd+K, Cmd+N, etc. global
shortcuts since those all use modifier keys.

This is the kind of keyboard-first navigation that makes developer
tools feel fast — no mouse needed to browse your task board.
2026-03-28 04:48:51 +00:00
xarmian 889c6d3a56 Enhance demo template with playbook, extra convention, and multi-agent refs
The demo workspace now showcases conventions AND playbooks (both key
differentiators), references multi-agent support in the architecture doc,
and has a better description. This is what people see when they run
pad init --template demo to try Pad for the first time.
2026-03-28 04:36:47 +00:00
xarmian a2e5a6622d Add Docker support and PAD_DATA_DIR config
- Multi-stage Dockerfile for building from source
- Dockerfile.goreleaser for GoReleaser-built release images
- GoReleaser config: publish multi-arch Docker images to ghcr.io
- Add PAD_DATA_DIR environment variable for configuring data directory
- Update README with Docker install option
- Add .dockerignore
2026-03-28 04:34:17 +00:00
xarmian 9d0d6cca5e Show toast notifications for external item changes
When the CLI or an agent creates items, the web UI now shows a subtle
toast notification like "Agent created: Fix OAuth redirect" or
"CLI created: New task". Only fires for non-web sources — changes you
make in the browser don't trigger redundant notifications.

This makes the agent collaboration feel alive — you can see items
appearing in real-time as your AI works alongside you.
2026-03-28 04:30:47 +00:00
xarmian 741ea94789 Add inline quick-create bar on collection pages
Click "+ New Task" to open a title input right in the page header.
Type a title, press Enter — item is created instantly without navigating
to a separate form. Press Esc to cancel. The item appears in the current
view immediately via local state update.

This is how Linear/Todoist handle creation — no page navigation, no forms,
just type and go. Much faster for rapid item creation during planning or
when an agent is working alongside you.
2026-03-28 04:27:12 +00:00
xarmian f7ac533ec1 Fix critical security issues found in pre-public audit
- Fix SQL injection in sort parameter: validate field names against
  alphanumeric regex before interpolating into json_extract queries
- Restrict CORS to localhost origins only (remove http://* wildcard)
- Change Makefile HOST default from 0.0.0.0 to 127.0.0.1
- Add Apache-2.0 license field to web/package.json
2026-03-28 04:20:59 +00:00
xarmian 123190c15d Add pad open command to launch the web UI in a browser
- Opens http://localhost:7777 (or configured URL) in the default browser
- Auto-starts the server if not running
- Navigates directly to the active workspace if detected
- Works on macOS (open), Linux (xdg-open), and Windows (rundll32)
- Update skills command description to reference pad install
2026-03-28 04:03:30 +00:00
xarmian b18ca1f3fc Add multi-agent pad install command
New top-level `pad install` command that auto-detects AI coding tools and
installs the /pad skill with tool-appropriate frontmatter:
- Claude Code (.claude/skills/) — full frontmatter
- Codex/Cursor/Windsurf (.agents/skills/) — name+description only
- GitHub Copilot (.github/instructions/) — applyTo frontmatter
- Amazon Q (.amazonq/rules/) — no frontmatter
- JetBrains Junie (.junie/guidelines/) — no frontmatter

Supports: pad install, pad install <tool>, pad install --all, --list, --update.
Updates pad init to detect and offer multi-tool installation.
2026-03-28 03:58:52 +00:00
xarmian eb828a8a77 Fix 3 web UI bugs: board empty state alignment, drag-and-drop positioning, and onboarding improvements
- Board view: move empty column text inside .column-cards so it aligns at top instead of bottom
- List/Board views: capture reorder data before awaiting status change to prevent reactive overwrite of drop position
- Onboarding: add dismiss button with localStorage persistence and re-show option, copyable prompts using shared clipboard utility, clearer setup instructions, and proper spacing below the checklist
2026-03-28 01:24:11 +00:00
xarmian dbecb741c6 Add workspace export/import and fix create workspace modal
Export/Import:
- `pad export -o file.json` exports workspace (collections, items,
  comments, links, versions) to portable JSON
- `pad import file.json --name X` creates new workspace with
  regenerated UUIDs and remapped relations
- GET /workspaces/{slug}/export and POST /workspaces/import endpoints
- "Download JSON" button in workspace settings
- Import tab with drag-and-drop in the create workspace modal
- Full transaction wrapping for atomic imports

Create Workspace Modal:
- Extracted from sidebar dropdown into a proper centered modal
  (sidebar's CSS transform was trapping fixed-position elements)
- Rendered at root layout level via uiStore flag
- Create and Import tabs with template picker and file drop zone
2026-03-28 00:25:04 +00:00
xarmian 222d2a1b80 Add table view for collections (IDEA-25)
Spreadsheet-style third view option alongside list and board. Sortable
columns for all schema fields, clickable status cycling, inline progress
bars, resolved relation labels, sticky header, and horizontal scroll.
Persisted per-collection in localStorage, configurable as default view.
2026-03-27 23:51:13 +00:00
xarmian a8059c5a0f Implement 8 ideas from the idea board
Quick wins:
- IDEA-31: URL autolink + link popover in editor (SafeLink with data-href
  prevents mobile navigation, popover shows open/edit/remove actions)
- IDEA-36: Focus title on new item creation, Enter moves to editor
- IDEA-38: Add `pad link` CLI command to link directory to existing workspace
- IDEA-34: Show checklist progress bar on item cards (parses markdown checkboxes)
- IDEA-28: Workspace rename (already existed in settings)

Medium effort:
- IDEA-33: Drag-and-drop task reordering in Phase documents via svelte-dnd-action
- IDEA-26: Archive collections (frontend wiring — backend already supported soft delete)
- IDEA-29: Archive workspaces with danger zone confirmation in settings
- IDEA-37: Raw markdown editor toggle + inline Mermaid diagram rendering
  (NodeView with ignoreMutation to prevent ProseMirror re-parse loops)
2026-03-27 23:41:20 +00:00
xarmian d318ecf7fc Add workspace onboarding: CLI hints, web checklist, codebase detection, and relation field fix
- Print suggested /pad prompts after `pad init` creates a new workspace
- Add `pad onboard` command that detects project tooling (language, build system,
  test runner, CI, linter) and suggests matching conventions from the library
- Replace empty workspace welcome box with OnboardingChecklist component showing
  a 4-step guided setup with progress bar and /pad prompt hints
- Add contextual tips with /pad prompts to empty collection states
- Add onboarding workflow to /pad skill for agent-driven codebase analysis
- Fix relation fields storing slugs instead of UUIDs: server now resolves
  slugs/refs to UUIDs for relation-type fields on both create and update
2026-03-27 19:33:18 +00:00
xarmian 9a590dc580 Fix SQLITE_BUSY on drag-and-drop by sequencing API calls and using item IDs
Status change and sort order updates were firing concurrently, causing
SQLITE_BUSY errors. Now handleFinalize awaits the status change before
sending reorder updates. Switched all frontend API calls from item.slug
to item.id (UUID). Added UUID support to ResolveItem in the store layer.
2026-03-27 02:09:14 +00:00
xarmian a6d08fdd7e Add Quick Actions — contextual prompt buttons that copy agent commands to clipboard
New QuickAction type in collection settings lets users define prompt templates
with variables ({ref}, {title}, {status}, etc.) that resolve at click time.
Lightning bolt menu appears on item detail and collection pages. Includes
default actions for Tasks, Ideas, Phases, and Docs collections. Fully
customizable via new Quick Actions tab in EditCollectionModal.
2026-03-27 01:56:31 +00:00
xarmian 7ba69abb88 Misc improvements: CLI field summaries, editor enhancements, CI and UI polish
Show field summary after create/update CLI commands. Make svelte-check
blocking in CI. Improve editor block handling, field editor layout,
conventions page, and minor UI consistency fixes across pages.
2026-03-27 01:13:07 +00:00
xarmian 81579847c6 Initial release
Pad — project management for developers and AI agents.
Single Go binary with embedded SvelteKit web UI, SQLite storage,
CLI, and Claude Code /pad skill integration.

https://getpad.dev
2026-03-26 01:52:36 +00:00