Commit Graph

44 Commits

Author SHA1 Message Date
xarmian d2898edc61 feat: show field change details in dashboard activity section (#4)
Dashboard activity rows now display change metadata inline (e.g.
"status: open → done") when available. Adds parseActivityChanges
helper and subtle muted styling for the change text.
2026-03-28 11:05:57 -04:00
xarmian a51e145b96 fix: resolve svelte-check type error in TableView component (#2)
page.params.workspace is string | undefined, but EmptyState expects
string. Add fallback to empty string so the type narrows correctly.
Fixes CI failure from svelte-check.
2026-03-28 10:54:03 -04:00
xarmian 52c8348361 fix: enrich activity log entries with item titles and collection info (#1)
The activity list endpoint returned raw entries without item context,
causing the activity page to show bare "Created"/"Updated" verbs.
The dashboard already enriched entries via GetItem() lookups — now the
activity handler does the same, and the frontend reads top-level fields
with metadata fallback.
2026-03-28 10:51:36 -04:00
xarmian 559815f7a3 Add burndown chart to phase detail pages
Create PhaseChart SVG component showing task completion over time with
an ideal burndown line, actual step chart, and today marker. Wire it
into PhaseTasks (shown when phase has start_date) and pass phaseFields
from the item detail page.
2026-03-28 14:14:32 +00:00
xarmian dc83d7490c feat: Add content templates for collections
Collections can now define a content_template in their settings — a
markdown template that pre-fills new items. When creating a bug report,
for example, the template can include "Steps to Reproduce", "Expected
Behavior", "Actual Behavior" sections automatically.

- Add content_template to CollectionSettings (Go model + TypeScript type)
- Sidebar "New" button uses template when creating items
- Dashboard quick-create buttons use template
- Template is stored in collection settings JSON, configurable via
  the collection edit UI
2026-03-28 14:07:07 +00:00
xarmian dc6ea138b7 feat: Make toast notifications and notification history clickable
Toast notifications from SSE events (agent/CLI item creation) now
include a link to the created item. Clicking the toast navigates
to the item detail page. The notification panel history entries
are also clickable when they have links.

- Toast and HistoryEntry types gain optional `link` field
- ToastContainer renders clickable toasts with hover state and → hint
- NotificationPanel renders linked entries as buttons with hover
- Workspace layout passes item URL to SSE-triggered toasts
2026-03-28 14:04:04 +00:00
xarmian e6a4bdc986 feat: Redesign web UI with dashboard, activity feed, notifications, and mobile improvements
Dashboard: Complete rewrite as command center with active work cards,
collection grid with status dots and progress bars, phase progress,
side-by-side attention/up-next, skeleton loading, instant creation buttons.

New pages: Activity feed with date grouping, action/source/collection
filters, and pagination. Sidebar navigation link + "View all" from dashboard.

New components: Keyboard shortcuts overlay (press ?), notification center
(bell icon + slide-out panel with toast history), contextual empty states
per collection with agent prompt hints.

Improvements: Command palette with search icon, item refs, colored status
badges. Mobile board horizontal scroll with snap-to-column. Collection
page header with collapsible filter toggle. Saved view tabs. Item detail
relationships section (blocks/blocked-by/wiki-links). Sidebar shows
active item counts only. Mobile header taps to dashboard. PWA manifest.

Bug fix: Mobile sidebar swipe zone reduced to left edge (0-24px) to
avoid conflicts with board horizontal scrolling.
2026-03-28 13:55:23 +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 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 a144de9af2 Fix title autofocus when creating new items
- Use tick() in startEditTitle() for reliable DOM focus instead of reactive $effect
- Add ?new=1 param to /new page redirect so title editing triggers on the detail page
2026-03-28 03:58:45 +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 a03b6d7bf8 Fix svelte-check type error in MermaidCodeBlock NodeView
Cast the NodeView factory return to `any` to satisfy the
CodeBlockOptions type constraint in strict mode.
2026-03-28 00:48:53 +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 e20b84fe90 Fix board column reordering with native HTML5 drag-and-drop
Replace nested svelte-dnd-action zones (which treated the whole board as one
drop target) with native HTML5 drag events on column headers. Source column
fades during drag, blue left-border indicates drop position. Card drag-and-drop
within/between columns still uses svelte-dnd-action.
2026-03-27 01:24:41 +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 3cf2522411 Add drag-and-drop column and group reordering for board and list views
Board columns and list groups can now be reordered by dragging their headers.
New order persists by updating the collection schema's field options array.
Column names remain left-aligned with drag handle on hover.
2026-03-27 01:12:58 +00:00
xarmian 880521c719 Add extract-to-item bubble menu for creating linked items from text selections
Select text in the editor to see a floating "Extract" button. Clicking it
opens an inline form to pick a collection and edit the title, then creates
the item and replaces the selection with a [[wiki-link]]. Full selected text
is included as item content when the title is edited shorter.
2026-03-27 00:55:50 +00:00
xarmian 0506051495 Show full timestamps on hover for all relative time displays
Added title attributes with localized timestamps to every relativeTime()
display: item detail meta, item cards, dashboard activity, activity feed,
comments, and version history.
2026-03-27 00:06:00 +00:00
xarmian c9e3d757e7 Use item refs instead of slugs in remaining navigation URLs
Fixed collection page new-item creation, new item form, and playbooks edit
button to use itemUrlId() for consistent PREFIX-NUMBER URLs.
2026-03-26 23:57:58 +00:00
xarmian 7c0514eacc Redesign sidebar with section headers and fix slug collision with deleted items
Sidebar now has "Collections" and "Agent" section headers with visual
distinction. Drag handles appear on hover for reorderable collections.
Also fixed uniqueSlug to check all rows including soft-deleted when
generating slugs, preventing UNIQUE constraint violations when creating
items with names matching archived items.
2026-03-26 23:55:47 +00:00
xarmian c6d154a117 Add archive functionality with bulk archive and show-archived toggle
Board columns and list groups now show an archive icon on hover with inline
confirmation to bulk-archive all items in a group. Collection page has a
"Show archived" checkbox that loads archived items via include_archived param.
Restore handler wired up for restoring individual archived items.
2026-03-26 23:49:34 +00:00
xarmian 49a35ef1c0 Overhaul EditCollectionModal with tabbed layout and wider design
Reorganized the modal into three tabs (General, Fields, Display) at 680px
width. General tab has name/icon/description/prefix. Fields tab has improved
field cards with key identifiers and a cleaner add-field section. Display tab
uses a two-column grid for settings. Fixed scroll containment so footer stays
pinned while tab content scrolls.
2026-03-26 23:38:23 +00:00
xarmian 158488f31a Add collection display settings UI for default view, layout, and grouping
EditCollectionModal now includes a Display section with controls for: default
view (list/board), item layout (balanced/fields-primary/content-primary), board
and list group-by fields (populated from select fields), and list sort-by field.
Settings are saved alongside schema changes in the same PATCH request.
2026-03-26 23:24:43 +00:00
xarmian 9918dfe322 Change item URLs to use PREFIX-NUMBER refs instead of slugs
URLs now use collection prefix + item number (e.g. /ideas/IDEA-15) instead of
long slugs. Backend ResolveItem() accepts either format for backwards compat —
old slug-based URLs and bookmarks still work. Updated all frontend link
generation (item cards, sidebar, search, wiki-links) to use refs.
2026-03-26 23:19:44 +00:00
xarmian b8aab7a37d Add collection template library with pre-built schemas for common use cases
CreateCollectionModal now shows a template picker as the first step with 8
templates: Bug Tracker, Feature Requests, Meeting Notes, Decisions, Tech Debt,
OKRs, Sprint Backlog, and Knowledge Base. Selecting a template pre-fills name,
icon, description, fields, and settings. A "Blank" option starts from scratch.
2026-03-26 23:10:05 +00:00
xarmian 203080fde1 Implement mutable collection schemas with field editing and option rename migration
Redesigned the EditCollectionModal to support full schema evolution: editable
field labels, delete fields, reorder with up/down buttons, and per-option
chip editing for select/multi_select fields. When select options are renamed,
a bulk migration updates all existing items via SQLite json_set/json_extract.
2026-03-26 23:00:23 +00:00
xarmian 82e159ffc6 Add delete item button with inline confirmation to item detail page
Two-stage delete: click Delete, then confirm Yes/No. Soft-deletes the item
and redirects back to the collection list.
2026-03-26 22:27:05 +00:00
xarmian b17c7ad3aa Remove redundant Library sidebar link and fix board column drag-and-drop height
Library link was accessible from Conventions/Playbooks pages already. Board
columns now stretch to match the tallest column so items can be dragged to
any column when scrolled down.
2026-03-26 21:31:52 +00:00
xarmian f3d66925bc Add Pad icon as favicon, PWA icons, and social metadata
Generate favicon sizes (16, 32, ico), Apple touch icon (180),
PWA icons (192, 512), and web manifest from padicon.png. Add
Open Graph meta tags for social sharing previews.
2026-03-26 18:30:31 +00:00
xarmian 2ad8e1a6b2 Fix uncategorized items missing from list view, replace toast spam with save indicator
ListView: items with empty group field values now appear in an
"Uncategorized" group at the bottom instead of being silently dropped.

Detail page: field and title updates now show the subtle "Saving..."
→ "✓ Saved" status indicator instead of firing toast notifications
on every change. Toasts are reserved for errors only.
2026-03-26 02:12:55 +00:00
xarmian c8699b555a Notion-style item creation: instant create and edit in place
Clicking "+ New Item" now immediately creates a blank item with
default fields and navigates to its detail page with the title
input focused and selected, ready to type. No more separate
creation form — creating and editing an item are the same
experience. Both the collection page button and sidebar button
use this flow.
2026-03-26 02:08:09 +00:00
xarmian 6d23cb986f Fix effect_update_depth_exceeded when editing field types
The infinite loop was caused by bind:value on a dynamic key of a
$state proxy Record (existingOptionsText[field.key]). Replaced with
_optionsText stored directly on each field object, avoiding the
proxy key-access reactivity cycle.
2026-03-26 02:02:10 +00:00
xarmian cc5f7ec20f Fix inconsistent input heights in FieldEditor
Add min-height: 30px to .field-input and .select-trigger so inputs
without placeholders match the height of selects and populated inputs.
2026-03-26 02:00:25 +00:00
xarmian 757f500ed8 Fix field type editing and show all fields on item creation page
Fix infinite loop when changing a field's type in Edit Collection
modal — existingOptionsText now initializes entries for all fields.

New item creation page now shows all editable schema fields (priority,
category, assignee, phase, etc.) using FieldEditor components, not
just status. Fields reset when switching collections.
2026-03-26 01:57:31 +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