176 Commits

Author SHA1 Message Date
Michael Ramos 35de9756a0 chore: bump version to 0.8.1
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
v0.8.1
2026-02-17 07:51:23 -08:00
PooLyum Lim 44cfce6ad0 fix(ui): prevent annotation toolbar from stealing global comment focus (#157)
Co-authored-by: blue <blue@blueui-MacBookPro.local>
2026-02-16 12:57:09 -08:00
J-token 80209cb6f4 fix: mermaid diagrams clipped due to fixed SVG dimensions and inline max-width (#156) 2026-02-16 12:04:14 -08:00
Michael Ramos 13b427b97b feat: use BROWSER env var as fallback for opening UI (#153)
* feat: use BROWSER env var as fallback for opening UI

Closes #119

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

* fix: add missing reference docs (were gitignored by reference/ pattern)

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-16 12:03:59 -08:00
Michael Ramos 6f3bfde039 chore: bump version to 0.8.0
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
v0.8.0
2026-02-13 14:05:27 -08:00
Michael Ramos 0554bfc544 feat: migrate marketing site to Astro with docs and blog (#150)
Migrate marketing site from Vite React SPA to Astro 5 with documentation (15 pages) and blog. Preserves landing page design, OKLCH design system, and S3/CloudFront deploy pipeline.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-13 13:15:31 -08:00
김영준E b35f2d88fd feat: close annotation toolbar on ESC key press (#149) 2026-02-13 10:39:48 -08:00
Michael Ramos 3102405f91 docs: add markdown annotation documentation
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-13 10:33:01 -08:00
Michael Ramos e46815d8ea feat: named image references and annotate command (#147)
* feat: named image references and annotate command (#67, #109)

Add human-readable names to image attachments throughout the annotation
pipeline, and add a new `plannotator annotate <file.md>` command for
annotating arbitrary markdown files.

Image names: ImageAttachment type replaces plain string paths, upload
endpoints return originalName, editable name inputs under thumbnails,
[name] path format in exported feedback, backward-compatible sharing.

Annotate command: new server module reusing plan editor HTML with
mode:"annotate", CLI subcommand, slash commands for Claude Code and
OpenCode, annotate mode UI (hides Approve, shows Send Annotations).

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

* refactor: move image name input to ImageAnnotator screen

The name input now appears on the full-screen annotator modal that opens
immediately when uploading/pasting an image, pre-populated from the
filename. Removes the disruptive inline name editing from thumbnails.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

* fix: stale closure in paste handler, update CLAUDE.md for new features

Fix race condition where globalAttachments was captured as empty array
in the paste event listener (missing dependency). Also update CLAUDE.md
to document ImageAttachment type, annotate server/flow, updated sharing
format with image support, and new slash commands.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-12 20:23:49 -08:00
Michael Ramos 0b47dd54a7 feat: add configurable share URL for self-hosted portals (#146)
Add PLANNOTATOR_SHARE_URL env var so users can point share links at
their own self-hosted portal instance instead of share.plannotator.ai.
Threads the base URL through the same path as sharingEnabled: env var →
server options → API response → editor state → useSharing hook →
generateShareUrl(). Includes self-hosting guide and documentation.

Closes #12

Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-12 15:07:43 -08:00
김영준E 044a50ea2c ✨ feat: add resizable side panels (#141)
Add drag-to-resize for the annotation panel, table of contents,
and file tree sidebar. Panel widths persist in cookie storage
across sessions and random-port hook invocations.

- Add useResizablePanel hook with left/right side support
- Extract ResizeHandle component with spread-friendly handleProps API
- Apply to AnnotationPanel, ReviewPanel, TableOfContents, FileTree
- Double-click handle to reset to default width
- Add min-w-0 on content areas for proper flex shrinking
2026-02-12 11:19:14 -08:00
Michael Ramos 8c446250c0 chore: relicense from BSL-1.1 to dual MIT/Apache-2.0 (#144)
* chore: relicense from BSL-1.1 to dual MIT/Apache-2.0
* fix: correct copyright holder to backnotprop
2026-02-12 09:55:14 -08:00
sen 1d2948b6a6 Add the ability to auto close the tab on approval (#128)
feat: add opt-in auto-close tab setting after approval/denial

Partial implementation of #41
2026-02-10 22:23:43 -08:00
J-token 705e2755a7 feat: add zoom, pan, and drag controls to mermaid diagrams (#134)
feat: add zoom, pan, and drag controls to mermaid diagrams

Closes #125
2026-02-10 22:03:23 -08:00
Michael Ramos 3fdb35d80d fix: honor CLAUDE_CONFIG_DIR in install scripts (#137)
Install scripts now check for the CLAUDE_CONFIG_DIR environment
variable when determining where to place the slash command file.
Falls back to the default ~/.claude/ when unset.

Closes #136

Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-10 09:13:38 -08:00
Michael Ramos 2d7f7bf977 chore: bump version to 0.7.0
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
v0.7.0
2026-02-09 12:43:26 -08:00
Raz Ben Yaish 851a4b32af feat: import teammate review from share link (#131)
* feat: add import teammate review from share link

Adds the ability to import annotations from a teammate's plannotator
share URL into the current plan review session.

- New ImportModal component with URL input, validation, and feedback
- importFromShareUrl() in useSharing hook: decodes share link,
  deserializes annotations, deduplicates, and merges into session
- Import button in header toolbar (visible when sharing is enabled)

Workflow: teammate shares their annotated plan via share link,
user clicks Import, pastes the URL, annotations are merged in.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

* fix: cleanup auto-close timer and deduplicate global attachments on import

- Clear auto-close setTimeout when user manually closes ImportModal
  (prevents orphaned callback from firing after unmount)
- Deduplicate global attachment paths on import to prevent duplicates
  when importing the same share link twice

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

* refactor: move import button into export dropdown menu

Move "Import Review" from a standalone header button into the export
dropdown, separated by a divider. Reduces header clutter.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

---------

Co-authored-by: razb <razb@voyager-labs.com>
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
Co-authored-by: Michael Ramos <mdramos8@gmail.com>
2026-02-09 12:37:33 -08:00
Michael Ramos bfa3f2d303 feat: add UI features setup dialog for TOC and sticky actions (#133)
One-time dialog introduces Table of Contents and Sticky Actions to
new and existing users. Sequences after Permission Mode Setup dialog
if both need to show, uses cookie-based detection to avoid repeat.

Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-09 11:52:36 -08:00
Michael Ramos ef20bb62b7 feat: save to notes without approving (#127) (#132)
Decouple Obsidian/Bear saves from the approve/deny flow so users can
save plans to their notes app independently, then manually approve in
Claude Code (e.g. shift+tab for context clearing).

- Add POST /api/save-notes server endpoint
- Add "Notes" tab to Export dialog with per-integration save buttons
- Split Export button into button+dropdown with quick actions:
  Copy Share Link, Download Diff, Save to Obsidian/Bear
- Add Cmd/Ctrl+S keyboard shortcut with configurable default action
- Add "Default Save Action" setting in Settings > Saving
- New utility: defaultNotesApp.ts for cookie-based preference

Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-09 11:28:09 -08:00
Thomas Roche 313c45138c feat: TOC sidebar, sticky actions, and settings redesign (#122)
* feat: Add Table of Contents sidebar with sticky action buttons

- Add hierarchical Table of Contents component with clickable navigation
- Implement useActiveSection hook for real-time section highlighting
- Add annotationHelpers utility for block identification
- Make Images, Global comment, and Copy plan buttons sticky during scroll
- Fix navigation scrolling to work within scrollable main container

* fix: Correct typo in opencode.json (CALUDE -> CLAUDE)

* docs: Update testing documentation - separate UI tests from integration/utility tests

* fix(ui): prevent code block annotation from breaking syntax highlighting

- Replace surroundContents() with plain text wrapper approach
- Add syntax highlighting restoration in removeHighlight()
- Fixes issue reported by kkharji in PR #122

The old approach used range.surroundContents() which wrapped syntax-highlighted
<span> elements, creating nested structure that broke the layout. The new approach
replaces code block innerHTML with plain text wrapped in <mark>, then restores
syntax highlighting when the annotation is removed.

Test coverage: 15 tests pass with edge cases for empty blocks, special chars,
large blocks (10k), unicode, and multiple annotation cycles.

* test(ui): add comprehensive code block annotation regression tests

- Add 15 test cases covering code block annotation behavior
- Test plain text wrapper approach vs nested span approach
- Verify syntax highlighting restoration on annotation removal
- Cover edge cases: empty blocks, special chars, large blocks, unicode
- Add happy-dom dev dependency for DOM testing

* feat: update opencode.json to include additional documentation instructions and configure Playwright MCP

* chore: stop tracking docs directory and opencode.json

* chore: move UI-TESTING.md to tests directory

* docs: extract UI testing checklist into separate file

- Move comprehensive feature checklists to UI-TESTING-CHECKLIST.md
- Keep main UI-TESTING.md focused on development workflow and setup
- Add reference link to checklist file for easy navigation

* docs: update UI testing documentation

* fix(ui): fix TOC active section tracking

IntersectionObserver was using root: null (viewport) instead of the
actual scroll container (<main>), and the effect only ran on mount
before headings were rendered. Pass the container as root and re-run
the observer when heading count changes.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

* revert: remove Playwright MCP from marketplace.json and stale README links

Playwright MCP is dev tooling, not for end users. README referenced
docs/UI-TESTING.md and docs/CODE-STYLE.md which don't exist at those paths.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

* style(ui): compact TOC styling and fix layout shifts

- Smaller text (text-xs) and tighter padding for compact feel
- Remove border-l-2 and font-medium from active state to prevent
  layout shifts that pushed text into multiline
- Annotation count badges are now perfect circles (w-5 h-5)
- Add left padding to root-level heading

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

* feat(ui): add optional TOC and sticky actions settings

- New uiPreferences.ts utility for cookie-based persistence
- TOC toggle: conditionally renders sidebar in App.tsx
- Sticky Actions toggle: conditionally applies sticky positioning in Viewer.tsx
- Both default to enabled, persisted via cookies

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

* refactor(ui): redesign Settings dialog with sidebar navigation

Replace flat settings list with sidebar + content panel layout:
- General tab: Identity, Permission Mode, Agent Switching
- Display tab: TOC, Sticky Actions, Tater Mode
- Saving tab: Plan Saving, Obsidian, Bear Notes
- Scrollable content area (max-h-[70vh])
- Sidebar hidden in review mode (single tab)

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

* fix(ui): fix sticky action bar positioning and add scroll-aware card background

Match main's button positioning across all breakpoints with responsive
margins that account for article padding. Use IntersectionObserver sentinel
to detect when the bar is stuck, revealing the card background only on scroll.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

---------

Co-authored-by: Michael Ramos <mdramos8@gmail.com>
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-09 09:28:09 -08:00
Michael Ramos 16429342c1 Merge pull request #130 from blue-poolyum/feat/github-style-viewed
feat: add GitHub-style viewed file tracking to code review
2026-02-07 10:23:09 -08:00
Michael Ramos 881ba9b40d Merge pull request #126 from rcdailey/feat/persist-editor-mode
feat: persist editor mode selection between plan reviews
2026-02-07 10:19:31 -08:00
blue 34d76b8cf6 feat: add GitHub-style viewed file tracking to code review
- Add viewed checkbox in FileTree for manual toggling
- Add Viewed button in DiffViewer file header
- Add progress indicator (N/M format)
- Add option to hide/show viewed files
- Remove automatic viewed marking on file selection
2026-02-05 20:15:56 +09:00
Robert Dailey 2fc34db81d feat: persist editor mode selection between plan reviews 2026-02-01 20:18:39 -06:00
Michael Ramos fe293217e8 chore: bump version to 0.6.8
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
v0.6.8
2026-01-29 08:44:01 -08:00
Michael Ramos 48f53eed16 feat: display repo and branch info in plan document (#117)
* feat: display repo and branch info in plan document

Add subtle badge display in upper-left corner of plan document showing:
- Repository name (org/repo from git remote, with fallbacks)
- Current branch with git branch icon

New modular repo.ts handles detection with fallback chain:
1. Parse org/repo from git remote origin
2. Fall back to git repo root directory name
3. Fall back to current working directory

Closes #104

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

* test: add --no-git flag to sandbox script

Allows testing repo info fallback behavior when not in a git repository.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-28 10:29:52 -08:00
Michael Ramos 5474469cab feat: add mermaid.js diagram rendering support (#116)
- Detect mermaid code blocks and render as interactive diagrams
- Dark theme matching Plannotator UI
- Toggle between source code and rendered diagram view
- Use getBBox() to recalculate viewBox for proper centering
- Error state shows source code fallback
- Add mermaid diagram to demo plan

Closes #115

Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-28 09:50:20 -08:00
Michael Ramos 813d41ddb2 fix: clean up old Windows install locations from bash script
Windows users running the bash script (via Git Bash/MSYS) may have old
binaries at different locations. Now cleans up both:
- $USERPROFILE/.local/bin/plannotator* (old bash location)
- $LOCALAPPDATA/plannotator/plannotator.exe (PowerShell location)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-20 16:09:19 -08:00
Michael Ramos 2b9bb37eb7 fix: explicitly delete old binary before install
Helps Windows users running bash script who were stuck on old versions.
The mv command may not overwrite properly on Windows due to file locking
or .exe extension mismatch.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-20 16:06:53 -08:00
Michael Ramos 0802102b2c fix: clean up old Windows install locations (#101)
Users with older installations at ~/.local/bin had PATH conflicts
where the old binary took precedence over the new install location.

Now removes plannotator from old locations before installing.

Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-20 16:01:56 -08:00
cognitive b46c855a5d fix(opencode-plugin): exclude sub-agents and build agent from prompt injection (#98)
Add agent filtering to experimental.chat.system.transform hook to prevent
injecting plan submission prompts into agents that shouldn't receive them:

- Hardcoded exclusion for "build" agent
- Dynamic exclusion for agents with mode "subagent" (e.g., general, explore)
- Skip injection if agent detection fails (safer behavior)

The plan agent and other primary agents will continue to receive the prompt.

Co-authored-by: cognitive <152830360+METAeuPHORIC@users.noreply.github.com>
2026-01-20 08:39:37 -08:00
Michael Ramos f01036949b chore: bump version to 0.6.7
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
v0.6.7
2026-01-19 12:10:23 -08:00
Michael Ramos 18540a55d3 feat: add Comment mode and type-to-comment shortcut (#93) (#97)
- Add new "Comment" editor mode that shows input directly on selection
- Add type-to-comment in Selection mode: typing while toolbar is open
  auto-transitions to comment input with the typed character
- Add initialStep/initialType props to AnnotationToolbar for direct input
- Fix autofocus timing for portal-rendered toolbar

Closes #93

Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-19 12:09:11 -08:00
Michael Ramos c24e775292 fix: smart detection for agent switching in OpenCode (#96)
Closes #94
2026-01-19 11:07:22 -08:00
Michael Ramos c4f8f58c50 fix: use primary_tools config for sub-agent blocking (#95)
Addresses community feedback on v0.6.6 sub-agent fix:

1. Add `config` hook to register `submit_plan` in `primary_tools`
   - OpenCode natively hides these tools from ALL sub-agents
   - Works for custom sub-agents too, not just general/explore

2. Replace buggy `chat.message` hook with `experimental.chat.system.transform`
   - chat.message was persisting the reminder to ALL user messages
   - system.transform injects once into system prompt

3. Remove hardcoded runtime sub-agent check
   - No longer needed with primary_tools handling it

Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-19 09:18:35 -08:00
Michael Ramos 2832d70bd9 chore: bump version to 0.6.6
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
v0.6.6
2026-01-18 09:14:35 -08:00
Michael Ramos 8fc6b80476 fix: OpenCode plugin updates (CVE + sub-agent fix) (#90)
## Summary

- Bump `@opencode-ai/plugin` to >=1.1.10 for CVE-2026-22812
- Prevent sub-agents from triggering plannotator

## Changes

1. **CVE Fix**: Updated dependency to address critical RCE vulnerability in OpenCode < v1.1.10

2. **Sub-agent Fix**: 
   - Replace `experimental.chat.system.transform` with `chat.message` hook (only injects for "plan" agent)
   - Add runtime block for sub-agents ("general", "explore") in `execute()`

Fixes #89, fixes #15, fixes #86
2026-01-18 09:11:54 -08:00
Michael Ramos f1087efc7c chore: bump version to 0.6.5
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
v0.6.5
2026-01-17 14:42:02 -08:00
Michael Ramos c9b25a5e30 fix: increase hook timeout to 4 days (#88)
Increases the plannotator hook timeout from 30 minutes to 4 days
(345600 seconds) to prevent the server from being killed during
extended plan review sessions.

Fixes #84

Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-17 13:38:01 -08:00
Michael Ramos e5e59d0740 fix: preserve newlines in copy and add Cmd+C shortcut (#87)
* fix: use @plannotator/web-highlighter for proper newline handling

- Switch from web-highlighter to @plannotator/web-highlighter@0.8.1
- Use source.text from highlighter (preserves newlines in cross-block selections)
- Update dependency to ^0.8.1 which fixes exports field for bundlers

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

* feat: add Cmd+C keyboard shortcut for copying selected text

Closes #60

When text is selected and the annotation toolbar is visible, Cmd+C (Mac)
or Ctrl+C (Windows/Linux) will copy the selected text with proper newlines
preserved between block elements.

This works because @plannotator/web-highlighter@0.8.1 now captures text
using Selection.toString() which preserves newlines for cross-block
selections.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

* fix: don't intercept Cmd+C in input/textarea fields

Prevents the custom copy handler from intercepting Cmd+C when the user
is focused in an input or textarea (e.g., annotation comment input).
Previously, copying text from an input would copy the original plan
selection instead.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-17 13:13:00 -08:00
Michael Ramos 4ed4d15171 chore: bump version to 0.6.4 v0.6.4 2026-01-15 20:55:54 -08:00
Michael Ramos cc3c3fe2bf feat: add Cmd+Enter keyboard shortcut to submit (#80) (#81)
- No annotations → Approve (proceed with implementation)
- With annotations → Send Feedback (request revision)

Works in both plan review and code review UIs. Respects input focus
to avoid conflict with existing Cmd+Enter to save annotation edits.

Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-15 20:51:57 -08:00
Michael Ramos 49c6575370 fix: restore both cache paths in install.sh
Keep clearing both ~/.cache/opencode and ~/.bun/install/cache paths
to match Windows behavior (belt and suspenders).

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-15 10:13:26 -08:00
Michael Ramos b1883d38e8 fix(opencode): include HTML files in npm package
The `files` array in package.json was missing plannotator.html and
review-editor.html, causing them to be omitted from npm publishes.
This explains why users were stuck on old versions.

Also fixes incorrect cache path in docs and install script.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
v0.6.3
2026-01-15 10:04:26 -08:00
Michael Ramos dcc1ad108a chore: bump version to 0.6.2
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
v0.6.2
2026-01-15 07:54:14 -08:00
Michael Ramos 4f6af14f02 Merge pull request #78 from stranger2904/fix/skip-title-generation-prompt
fix(opencode): skip Plan Submission prompt for title generation
2026-01-15 07:52:16 -08:00
Michael Ramos 4dd67c1157 chore: bump version to 0.6.1
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
v0.6.1
2026-01-15 07:45:14 -08:00
Aleksey Bragin 7cd2484461 fix(opencode): skip Plan Submission prompt for title generation
The Plan Submission system prompt was being injected into ALL requests,
including title generation. This caused the title generator to see the
wrong system prompt and attempt to call submit_plan instead of generating
a title.

This fix detects title generation requests by checking for "title generator"
or "generate a title" in the existing system prompt and skips injecting
the Plan Submission instructions for those requests.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-15 10:44:45 -05:00
Michael Ramos 02c2b032a4 Merge pull request #76 from backnotprop/feat/obsidian-custom-path
feat: allow custom path for Obsidian integration (#68)
2026-01-14 14:29:34 -08:00
Michael Ramos 12385beef5 fix: use correct placeholder for custom vault path
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-14 14:28:29 -08:00