- Fix config access: use response.data.share instead of response.share
- Make config read lazy to avoid blocking plugin init
- Add --disable-sharing and --keep flags to sandbox script
- Add sharingEnabled to test-server.ts
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Add deployment-level configuration to disable URL sharing for
security/privacy concerns.
Configuration methods:
- Claude Code: PLANNOTATOR_SHARE=disabled env var
- OpenCode: "share": "disabled" in opencode.json (primary), env var fallback
When disabled:
- Quick Share button hidden in annotation panel
- Share tab hidden in export modal (shows only Raw Diff)
Closes#69
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
* feat: add permission mode utility and setup dialog
Add cookie-based storage for permission mode preference with first-time
setup dialog for Claude Code users. Supports three modes:
- Auto-accept Edits (default)
- Bypass Permissions (equivalent to --dangerously-skip-permissions)
- Manual Approval
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
* feat: integrate permission mode in editor and settings
- Show first-time setup dialog for Claude Code users
- Add permission mode dropdown to Settings (Claude Code only)
- Pass selected mode in approve request
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
* feat: output updatedPermissions in hook response
Use Claude Code 2.1.7+ hook protocol to preserve permission mode after
plan approval. Extracts permission_mode from hook input, allows client
to override via request, and outputs setMode in updatedPermissions.
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
---------
Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
The postinstall script previously hardcoded ~/.config/opencode/command
as the destination for slash command files. This causes issues for users
running OpenCode in portable/XDG-compliant environments where
XDG_CONFIG_HOME is set to a custom location.
This change uses ${XDG_CONFIG_HOME:-$HOME/.config} which:
- Uses XDG_CONFIG_HOME when set (for portable installations)
- Falls back to ~/.config for standard installations (no behavior change)
This follows the XDG Base Directory Specification and ensures the plugin
works correctly in containerized, portable, or multi-user environments.
Co-authored-by: Aleksey Bragin <ab@alfabox.net>
- Add Windows PowerShell install script (install.ps1)
- Install slash commands for both Claude Code and OpenCode
- Update OpenCode README with install script instructions
- Simplify UpdateBanner to use same install command for both platforms
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Remove early exit when no uncommitted changes - user can switch to
"Last commit" or other diff types via dropdown.
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
- Show correct origin badge (Claude Code orange, OpenCode gray)
- Always show file tree sidebar when diff options available
- Update README with v0.5.0 label
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
- Add "after you restart Claude Code" to /plannotator-review message
- Symlink install scripts to marketing/public for automatic deploys
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
- Update version in root, opencode-plugin, and server packages
- Add code review feature to README
- Build artifacts for release
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
## Summary
Complete code review system for reviewing git diffs with annotations.
### Features
- Interactive diff viewer with split/unified views
- Line-level annotation system
- Diff type selector (uncommitted, last commit, vs main branch)
- Dynamic default branch detection
- Empty state handling
- Simplified UX with streamlined feedback flow
Closes#51Closes#56
Allow users to specify which browser opens plan files via environment variable.
Default behavior unchanged - only activates when env var is set.
- macOS: Set to app name ("Google Chrome") or path
- Linux/Windows: Set to executable path
Closes#42
Fix stale build artifacts in npm package - version was showing 0.4.9 due to
pre-built HTML being copied before version bump.
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
- Update CLAUDE.md with new APIs and file structure
- Remove unused helper functions (isAgentSwitchEnabled, isPlanSaveEnabled)
- Sync all package versions to 0.4.10
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
* Add configurable agent switching for OpenCode
Add a Settings UI option to configure agent switching behavior after plan
approval. Users can now choose to switch to the "build" agent (default) or
disable agent switching entirely. This is particularly useful for oh-my-opencode
users who have their own agent switching logic.
Changes:
- Add agentSwitch.ts utility for storing agent switch preference
- Add "Agent Switching" dropdown in Settings UI
- Pass agentSwitch setting through /api/approve to OpenCode plugin
- Conditionally perform agent switch based on user preference
Closes#37🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: TheOutdoorProgrammer <13936290+TheOutdoorProgrammer@users.noreply.github.com>
* Hide Agent Switching setting when not in OpenCode mode
* Add configurable plan saving settings
Users can now:
- Disable plan saving entirely via Settings toggle
- Set a custom save path (supports ~ for home directory)
Closes#36
* Widen Settings dialog to accommodate new options
* Move Save Plans setting below Identity section
* Make Obsidian Vault and Folder inputs side by side
* Move Agent Switching below Save Plans in Settings
---------
Co-authored-by: TheOutdoorProgrammer <13936290+TheOutdoorProgrammer@users.noreply.github.com>
- New storage.ts module with cross-platform support (Windows/macOS/Linux)
- Save plan.md on server start
- Save plan.diff.md and plan-{approved,denied}.md on decision
- OpenCode plugin shows saved path in tool result
Features:
- OpenCode: annotations are sent on approval as implementation notes
- Claude Code: confirmation dialog warns annotations won't be sent
- Dialog includes links to upvote Claude Code issues #16001#15755
Refactor:
- New reusable ConfirmDialog component
Closes#30🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Agent switching:
- Use noReply: true with await to ensure user message is created
before returning from tool
- Fixes race condition where message was created after loop exited
UI:
- Adjust plan viewer width to 832px (between 3xl and 4xl)
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Increases default width from 768px to 896px for better readability
while still fitting comfortably on laptop screens.
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Users need to clear both ~/.cache/opencode and ~/.bun/install/cache
for a complete reset when stuck on old versions.
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Removes xl breakpoint to keep narrow layout on all laptops.
Only widens on truly large external monitors.
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Restore max-w-3xl as default width, only widen on larger screens:
- Default: max-w-3xl (768px) for laptops
- xl (1280px+): max-w-5xl for external monitors
- 2xl (1536px+): max-w-6xl for large desktops
Bumps version to 0.4.3.
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
The hook's server/index.ts imports from @plannotator/server, but the
package wasn't declared in dependencies. Bun only creates workspace
symlinks for declared dependencies, causing the build to fail in CI.
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
* Refactor: shared server package with PLANNOTATOR_REMOTE env var
- Create packages/server/ with shared server implementation
- Add PLANNOTATOR_REMOTE=1 env var for devcontainer/SSH mode
- Deprecate SSH_CONNECTION detection (still works with warning)
- Both Claude Code and OpenCode now use identical server logic
- OpenCode gains Obsidian/Bear integrations and remote detection
- Update documentation with environment variables section
Fixes#27🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
* Remove PLANNOTATOR_ORIGIN env var, fix onReady callback timing
- Remove PLANNOTATOR_ORIGIN hack from Claude Code hook (hardcode "claude-code")
- Fix onReady callback to pass port directly (was referencing undefined server)
- Create tests/manual/test-server.ts for testing either origin
- Update test-hook-2.sh to use new test server with opencode origin
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
* Add devcontainer test setup, reduce logging verbosity
- Add tests/devcontainer/ with devcontainer.json for testing remote mode
- Add tests/opencode-local/ for local OpenCode testing
- Update package.json build script for proper bundling
- Remove verbose multi-line error messages, keep useful errors
- Clean up unused deprecationWarned variable
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
* Add devcontainer support and documentation
- Add PLANNOTATOR_REMOTE env var for container/remote detection
- Remove console logging (silent operation)
- Add devcontainer.md with full setup instructions
- Add devcontainer section to OpenCode plugin README
- Add port-only test setup to reproduce common misconfiguration
- Update test devcontainers to forward port 4096 for opencode web
- Bump version to 0.4.1
Fixes#27🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
* Update CLAUDE.md: legacy SSH detection, not deprecated
Removed incorrect mention of deprecation warning - SSH_TTY/SSH_CONNECTION
detection is silent by design.
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
* Fix OpenCode agent switching after plan approval
After approving a plan, the conversation context stayed in "plan" mode
even though the TUI showed "build". This caused edits to fail because
the plan agent has edit permissions denied.
The fix uses session.prompt() to inject a message with agent: "build",
which triggers a new agentic loop with proper build agent permissions.
Fixes#29🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
---------
Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
- Add global (plan-level) and per-annotation image attachments
- Image upload via drag-drop, file picker, or clipboard paste (Cmd+V)
- ImageAnnotator component for drawing on images before saving
- Freehand pen, arrow, and circle tools
- Adjustable stroke size and color presets
- Edge-to-edge circle drawing
- Server endpoints for image upload (/api/upload) and serving (/api/image)
- Images stored as paths in /tmp/plannotator/, included in export for Claude
- Preserve image paths in URL sharing for round-trip scenarios
- Uses perfect-freehand (~2KB) for smooth pen strokes
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
- Server returns origin field in /api/plan response
- UI displays badge next to version in header
- Claude Code: orange badge
- OpenCode: neutral zinc/gray badge
- Supports PLANNOTATOR_ORIGIN env var for testing
Closes#22🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
- Add project.ts utility for detecting git repo name
- Fallback to directory name if not in a git repo
- Include project name as second tag after "plannotator"
- Add 21 unit tests for project detection
- Increase tag limit from 6 to 7
Closes#24🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
- Add bear.ts utility for settings storage
- Add Bear toggle to Settings UI (simple on/off)
- Add saveToBear() using x-callback-url protocol
- Reuse extractTags() for inline #hashtags
- Change base tag from "plan" to "plannotator"
- Add test-hook-2.sh with alternate plan for testing
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
Users may be stuck on old plugin versions due to OpenCode's caching.
Added note to both READMEs with the rm command to clear the cache.
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
* Add Obsidian integration for auto-saving approved plans
- Auto-detect Obsidian vaults from system config
- Settings UI with vault dropdown and folder config
- Save plans with YAML frontmatter (created, source, tags)
- Extract tags heuristically from H1 title and code fence languages
- Human-readable filenames: "Title - Jan 2, 2026 2-30pm.md"
- Cross-platform support (macOS, Windows, Linux)
- Add local test script for hook simulation
* Add backlinks and improve filename generation
- Add [[Plannotator Plans]] backlink to saved notes for graph connectivity
- Extract title from H1 for human-readable filenames
- Format: "Title - Jan 2, 2026 2-30pm.md"
- Add bulk test script for ~/.claude/plans
- Add fix script to add backlinks to existing vault files
* Add Obsidian integration docs to README, landing page, and plugins
- Root README: Quick note about Obsidian support after video table
- apps/hook README: Detailed setup and example file format
- apps/opencode-plugin README: Feature list and setup instructions
- Landing page: New "Save to Obsidian" feature card
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
* Add Obsidian Integration section to README
* Screenshot Obsidian settings
Added an implementation plan section for user authentication.
* Update README with Obsidian auto-save feature
Added information about auto-saving approved plans to Obsidian.
* Update README with Obsidian integration link
Added link to details about Obsidian integration.
* Update README to include Obsidian auto-saving feature
Clarified the new feature for saving to Obsidian with a link.
---------
- Sync all package versions (root, Claude plugin, OpenCode npm package)
- Includes global comments feature and forward-compatibility fix
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
- Update version to 0.2.1 in package.json and plugin.json
- Fix hardcoded v0.1 in App.tsx to use dynamic __APP_VERSION__
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
* Add SSH remote session support with fixed port
- Auto-detect SSH sessions via SSH_TTY/SSH_CONNECTION env vars
- Use fixed port 19432 over SSH for predictable port forwarding
- Add PLANNOTATOR_PORT env var for custom port configuration
- Add retry loop (5 attempts) for port conflicts
- Print SSH config hint when running remotely
- Skip browser auto-open in SSH sessions
* integration test for ssh
---------
Co-authored-by: Michael Ramos <mdramos8@gmail.com>