Commit Graph
85 Commits
Author SHA1 Message Date
Bohdan Triapitsyn fd08cc4e5d fix(desktop): terminate sidecar on main window close
- Terminate the sidecar when the macOS main window is closed
- Update opencode-ai/sdk to v1.1.53 across all packages
2026-02-06 02:50:08 +02:00
Bohdan Triapitsyn 234a91b444 feat: add OpenCode CLI path override and settings UI
- Add opencodeBinary field to settings and persistence flow
- Introduce OpenCode CLI settings panel with Browse and Save actions
2026-02-06 01:32:32 +02:00
Bohdan Triapitsyn 904b6c11fe release v1.6.4 2026-02-05 03:16:24 +02:00
Bohdan Triapitsyn 83ffb1af34 refactor(desktop): make Tauri thin shell running web sidecar (#273)
## What / Why
This PR finishes the desktop refactor: the Tauri app is now a thin shell that launches the web server as a sidecar and loads the UI from `http://127.0.0.1:<port>`. All real backend logic lives in `packages/web/server/index.js`; desktop Rust keeps only native integrations (menu/dialog/notifications/updater/deep-link + window chrome).
This unblocks:
- consistent behavior across web/desktop/vscode (single backend)
- simpler desktop maintenance (no duplicated Rust backend)
- host switching between Local + remote instances in desktop
- reliable cold-start behavior on slow machines (VSCode + desktop)
## Key changes
- Desktop sidecar runtime
  - build pipeline to bundle web dist + `openchamber-server` sidecar (`packages/desktop/scripts/build-sidecar.mjs`)
  - robust local port selection (prefer saved/default, fallback to random; persisted in `~/.config/openchamber/settings.json`)
  - improved PATH handling so the sidecar can locate `opencode` CLI (incl `~/.opencode/bin`, overrides, common bins)
  - disable native right-click context menu in production builds (dev keeps it)
- Desktop instance switcher (Tauri-only)
  - header button + modal to add/edit/delete remote hosts, set default, probe status/ping, switch back to Local escape hatch
  - auth gate includes host switcher so you can recover when a remote host is broken/auth-required
  - host list stored desktop-locally (not tied to the currently selected remote server)
- Notifications
  - decision logic moved server-side; desktop notifications emitted via sidecar stdout and shown natively by Tauri
  - prevent double-notifications on desktop Local origin (UI ignores SSE notification when native path is active)
  - restore macOS notification sound
- Updates
  - Tauri updater used only when viewing Local instance in desktop shell (avoid “remote web update” triggering desktop restart)
- Settings persistence & UX polish
  - persist model favorites/recents via `/api/config/settings` (works for web + desktop; not origin-dependent)
  - persist per-project sidebar collapse state in `projects[].sidebarCollapsed` via `/api/config/settings` (with debounce on toggles)
  - macOS header sizing/traffic-lights offsets fixed (marketing macOS major injected from desktop; MultiRun header aligned)
  - VSCode cold-start: keep retrying provider/agent loads after connection to avoid empty UI on slow machines
  - misc lint/type fixes + bun.lock sync
- Desktop bootstrap / resiliency
  - show onboarding screen when OpenCode CLI is missing (desktop Local origin), with retry hook to restart OpenCode after install
## Testing notes
- Desktop (macOS): switch Local <-> remote, set default host, verify auth gate recovery, native notifications (with sound), updater gated to Local
- Web: favorites/recents + per-project collapsed state persist across reload/restart
- VSCode: slow startup no longer results in missing providers/agents/models
2026-02-05 01:59:49 +02:00
shekohex 8b3765e362 feat(syntax): support phoenix file extensions (#278)
* feat(syntax): support phoenix file extensions

* feat(syntax): add elixir codemirror language
2026-02-03 21:20:57 +02:00
Bohdan Triapitsyn 388911b253 release v1.6.3 2026-02-02 19:04:59 +02:00
Bohdan Triapitsyn cd37b778c3 release v1.6.2 2026-02-01 22:47:21 +02:00
Bohdan Triapitsyn fd0b78191e release v1.6.1 2026-01-30 15:40:25 +02:00
Nelson Pires 2ed1a73d3c Add new mobile chat controls (#247)
* chore: upgrade @opencode-ai/sdk to 1.1.40

* chore(ui): bump @opencode-ai/sdk to 1.1.40

* feat(chat): add mobile controls drawer and panel switching

Add mobile-only controls drawer with open/close and panel switching
Introduce state and handlers for mobile controls and panels
Reset mobile UI state when switching to non-mobile or returning to unified controls

* feat: add mobile chat controls utilities

Add utilities to compute and display the selected agent and model names in mobile chat controls.
Add effort variant formatting, serialization, parsing, and ranking helpers for quick options.
Expose helpers to build quick effort option lists for the UI

* feat(ModelControls): allow external mobile panel control

Initialize mobile panel state from external props when provided
Fall back to internal mobile panel state when external control is absent
Notify parent on panel changes via onMobilePanelChange callback

* feat(chat): add StatusChip component

Add StatusChip button that displays agent, model, and effort
Show marquee animation when the label is truncated
Bind to config and session stores to reflect current context

* feat: add UnifiedControlsDrawer chat controls

Add a side panel to switch agent, model, and effort quickly
Show recent agents and models for faster reselect
Persist agent/model/variant selections in session

* fix(openchamber): correct base64 to Uint8Array typing

* feat: add reduced-motion support for marquee animations

Add marquee-text--auto to enable continuous scrolling
Introduce prefers-reduced-motion media query to disable animations
Apply reduced-motion rules to active marquee and hover states

* feat[worktrees]: enhance sdk worktree removal with fallbacks

Add dynamic resolution of remove/delete/archive methods for worktrees
Fallback to delete or archive when remove is not available
Throw clear error when SDK version does not support worktree removal

* feat(ui): track recent agents and efforts in UI store

Add recentAgents array to UI state for quick access
Track up to 5 variants per provider/model in recentEfforts
Expose addRecentAgent and addRecentEffort actions to update history

* fix(deps): upgrade @opencode-ai/sdk to 1.1.42

Upgrade the OpenCode AI SDK to 1.1.42 across packages
Refresh lockfile entries to reflect the new SDK version and integrity hash
Ensure downstream packages consume the latest SDK and remain compatible

* refactor: simplify agent overflow logic in UnifiedControlsDrawer
2026-01-30 11:13:37 +02:00
Bohdan Triapitsyn 64e6c53719 release v1.6.0 2026-01-29 01:22:21 +02:00
Bohdan Triapitsyn 8c6eb3c44d release v1.5.9 2026-01-28 02:23:27 +02:00
Bohdan Triapitsyn 415b043326 feat: migrate to OpenCode SDK worktrees with per-project config
Add SDK-based worktree management that lists and starts SDK worktrees
Migrate per-project setup to ~/.config/openchamber/<projectId>.json
Deprecate .openchamber legacy paths and adapt UI to new config
2026-01-27 20:00:07 +02:00
Bohdan Triapitsyn 6656816101 release v1.5.8 2026-01-26 20:05:57 +02:00
Bohdan Triapitsyn 1720a8d6fd feat: add iOS safe area support for PWA header
Introduce CSS variables for safe-area in iOS PWA environments
Apply header padding based on safe-area top to header-safe-area element
2026-01-24 18:37:03 +02:00
Bohdan Triapitsyn 3e809e79b1 release v1.5.7 2026-01-24 18:19:58 +02:00
Bohdan Triapitsyn 4ff085d314 release v1.5.6 2026-01-24 02:34:52 +02:00
Bohdan Triapitsyn 463e9ec4e3 Add GitHub integration for PRs, issues and AI PR description (#205)
* feat: integrate GitHub OAuth device flow across runtimes

Add GitHub OAuth device flow endpoints across runtimes
Introduce GitHubSettings UI panel and sidebar entry
Persist GitHub auth state in per-runtime storage

* feat: add GitHub PR status and PR description generation

Show PR status for the current branch in the Git view
Generate a pull request description from the diff between base and head
Expose prStatus, prCreate, and prMerge APIs in web and desktop clients

* feat: add GitHub PR ready for review

Add API to mark pull requests as ready for review
Show a Ready button for draft PRs and reflect status in UI
Handle token expiration and GraphQL errors when marking ready
2026-01-23 16:08:58 +02:00
Bohdan Triapitsyn 0e715be7d6 release v1.5.5 2026-01-23 01:56:46 +02:00
Bohdan Triapitsyn 2618efe8e5 release v1.5.4 2026-01-22 19:49:52 +02:00
Bohdan Triapitsyn d01b58593a release v1.5.3 2026-01-20 15:32:52 +02:00
Bohdan Triapitsyn 24969ba856 feat: implement file editing capabilities with CodeMirror integration
- Added CodeMirror editor for file content editing in FilesView.
- Introduced draft saving functionality with unsaved changes confirmation dialog.
- Implemented file writing API to persist changes to the filesystem.
- Enhanced language support for syntax highlighting based on file extensions.
- Updated UI components to support new editing features, including save and discard options.
- Refactored line selection logic for improved user experience on both desktop and mobile.
- Added new utility functions for language detection by file extension.
- Introduced a new theme for CodeMirror to align with the application's design.
2026-01-18 17:29:31 +02:00
Bohdan Triapitsyn 8879573def release v1.5.2 2026-01-17 22:44:09 +02:00
Bohdan Triapitsyn f0fe9632ef release v1.5.1 2026-01-16 02:29:48 +02:00
Bohdan Triapitsyn ba49a291bd release v1.5.0 2026-01-16 01:24:38 +02:00
Bohdan Triapitsyn 475bd3288a release v1.4.9 2026-01-14 18:05:52 +02:00
Bohdan Triapitsyn c52a5f27a2 feat(vscode): enhance server readiness with multiple URL candidates (#145)
Add support for multiple candidate base URLs in readiness check.
Automatically set API URL override upon successful server connection.
2026-01-14 15:40:41 +02:00
Bohdan Triapitsyn 5ffec2acba release v1.4.8 2026-01-14 02:55:52 +02:00
Bohdan Triapitsyn 1e1ca9f15e release v1.4.7 2026-01-10 11:02:25 +02:00
Bohdan Triapitsyn 591cbb723a release v1.4.6 2026-01-09 22:52:11 +02:00
Bohdan Triapitsyn 4a87126b74 feat: added questions and permissions 2026-01-09 21:38:22 +02:00
Bohdan Triapitsyn 2382c6e82a release v1.4.5 2026-01-09 00:01:22 +02:00
Bohdan Triapitsyn 6eace604de feat: add McpDropdown component with related UI enhancements 2026-01-08 23:14:29 +02:00
Bohdan Triapitsyn 2cbec5c3ce release v1.4.4 2026-01-08 02:05:17 +02:00
Bohdan Triapitsyn b6646b6b3e feat: enhance worktree session creation with loading screen 2026-01-07 23:00:26 +02:00
Martin DONADIEU b8463b787b feat: add unified dev script for concurrent development (#113)
Add a "dev" script that runs the server, web build, and UI dev mode
concurrently with colored output for easier development workflow.
2026-01-07 21:52:11 +02:00
Martin DONADIEU 11fb61a883 feat: add QR code and password URL for Cloudflare tunnel (#112)
* feat: add QR code and password URL parameter for Cloudflare tunnel

Add --tunnel-qr flag to generate scannable QR code for tunnel URL in terminal.
Add --tunnel-password-url flag to include password as URL parameter for auto-login.
Frontend now automatically detects and submits password token from URL.

* docs: update README with tunnel QR and password URL features

Add dev script for concurrent server, web, and UI watch mode.
2026-01-07 21:51:45 +02:00
Bohdan Triapitsyn 18c5b4c7b5 feat: add multi-project support (#110)
* feat: Implement project management store with project path validation and synchronization

- Added `useProjectsStore` for managing projects, including adding, removing, renaming, and validating project paths.
- Implemented persistence for projects and active project ID using safe storage.
- Introduced synchronization from desktop settings to keep project data consistent.
- Enhanced session store to manage sessions by directory and added new methods for session management.
- Updated todo store to fetch session todos based on the directory context.
- Refactored server code to validate and resolve project directories for various API endpoints.
- Added project entry validation and sanitization to ensure data integrity.

* feat(settings): migrate legacy project settings and update settings loading logic

* feat: enhance project management with directory-aware settings and improved agent/command source handling

* feat: enhance session and project management with directory-aware settings and improved configuration refresh logic

* feat: enhance project management with worktree manager integration and project directory resolution

* feat: enhance agent groups store with project directory resolution and loading logic

* feat: add heartbeat management and global wrapping for SSE blocks in agent and chat providers

* feat: refactor command and project handling in useCommandsStore

- Replaced useDirectoryStore with useProjectsStore to manage project paths.
- Introduced getRequestDirectory function to determine the active project directory.
- Updated command fetching to respect project-level scoping.
- Enhanced error handling and logging for command configuration fetching.
- Improved command configuration saving and updating to utilize project directory context.

feat: enhance project path normalization in useProjectsStore

- Added resolveTildePath function to expand paths starting with ~.
- Updated normalizeProjectPath to utilize home directory for path expansion.

fix: update permission handling in useSessionStore

- Changed Permission type to PermissionRequest for clarity.
- Updated respondToPermission method to use requestId instead of permissionId.

refactor: improve permission utilities

- Introduced types for PermissionAction and PermissionRule.
- Enhanced getAgentDefinition and resolveConfigStore functions for better type safety.
- Added resolvePermissionAction to streamline permission resolution logic.

feat: add agent configuration retrieval endpoint

- Implemented new API endpoint to fetch agent configuration based on project directory.
- Enhanced getAgentPermissionSource to prioritize project-level permissions.

chore: update SDK version in package.json files

- Bumped @opencode-ai/sdk version to ^1.1.1 across all relevant package.json files.

refactor: streamline bridge message handling

- Updated handleBridgeMessage to accept directory parameter for agent and command requests.
- Improved local API request handling to extract directory from query parameters and headers.

feat: enhance project configuration management

- Added functions to retrieve and merge project configuration paths.
- Improved handling of existing project configuration files for agents and commands.

* feat: enhance VSCode integration and session management

- Added support for a sticky sidebar header background in light and dark themes.
- Introduced functions to read VSCode workspace directory and check if running in VSCode.
- Implemented detailed logging for session loading and creation processes.
- Enhanced session filtering based on directory structure and canonical paths.
- Added a new method to reorder projects and prevent modifications in VSCode workspace.
- Improved error handling and logging for app initialization and markdown file parsing.
- Updated API checks and health checks to ensure readiness before proceeding.
- Refactored code for better readability and maintainability across various modules.

* feat: improve agent and branch selection logic, enhance session management, and update multi-run creation response

* feat: add worktree management actions in agent group detail and sidebar, including delete and keep only options

* fix(ui): share IME guard and cover multi-run

* fix(session): reduce maximum visible sessions in group from 7 to 5
2026-01-06 21:31:04 +02:00
Bohdan Triapitsyn d86105fcb2 release v1.4.3 2026-01-04 00:36:59 +02:00
Bohdan Triapitsyn b97399a5af release v1.4.2 2026-01-03 14:53:19 +02:00
aptdnfapt 025a9a6b80 feat: implement Undo/Redo/Timeline and Fork Features and fixed opencode.json reading issue on broken json (#99)
* feat: add /undo, /redo, /timeline slash commands and fork button

- Add /undo command to revert to previous user message
- Add /redo command to redo previously undone messages
- Add /timeline command to show conversation history
- Add fork button on user messages (hover) to create new session
- Add TimelineDialog component for navigating conversation history
- Show undo/redo/timeline in autocomplete when session exists
- Fix fork to use SDK session.fork API
- Silent no-op behavior for undo/redo when no messages (matches OpenCode CLI)

* fix: correct fork session endpoint and session switching

- Add hybrid SDK approach using v1 for existing methods and v2 for fork only
- v2 SDK has correct endpoint /session/{sessionID}/fork instead of broken /session/{id}/fork
- Fix forkFromMessage to use setCurrentSession instead of direct set
- Ensures both useSessionStore and useSessionManagementStore are consistent
- Fixes issue where forked sessions appeared empty until sending a new message

* fix: use direct fetch for fork to avoid v2 SDK build errors

- Remove v2 SDK imports and hybrid SDK approach
- Use direct fetch() call to /api/session/{sessionID}/fork endpoint
- Avoids type conflicts between v1 and v2 SDK
- Bypasses broken v1 SDK fork endpoint (wrong path parameter)
- All codebase now uses v1 SDK consistently

* fix: use jsonc-parser for config file parsing

- Replace strip-json-comments + JSON.parse with jsonc-parser
- Handles comments, trailing commas, and unquoted keys
- Matches OpenCode CLI config parsing behavior
- Fixes SyntaxError when reading global opencode.json config

* feat: improve timeline dialog with loading state and search

- Add loading spinner on fork button during operation (~30s on big sessions)
- Refresh session list after fork so new session appears in sidebar immediately
- Add search bar to filter messages by prompt text content
- Show 'No messages found' when search has no results
- Disable fork button while forking to prevent duplicate operations
2026-01-03 01:33:35 +02:00
Bohdan Triapitsyn 17df8a43a9 release v1.4.1 2026-01-02 22:06:29 +02:00
Bohdan Triapitsyn 110b0e5d8f feat(terminal) refactoring and stability improvements (#98)
* feat(terminal): replace xterm with ghostty-web

Replace xterm.js terminal with ghostty-web implementation
Add terminal serialization support for state restoration
Apply custom patches to ghostty-web for enhancements

* feat(terminal): add bun-pty backend support

Switch terminal to ghostty-web with bun-pty backend for better performance
Auto-detect and prefer Bun runtime when available for terminal sessions
Update terminal viewport write queue handling for improved reliability

* fix(terminal): prevent unnecessary resize events

Only report terminal resize when dimensions actually change
Simplify chunk processing state tracking
Disable terminal transparency for consistent rendering

* feat(terminal): increase scrollback and buffer limits

Increase terminal scrollback buffer from 10k to 50k lines
Increase terminal buffer limit from 256k to 1M bytes
Add rate limiting and improve output handling for terminal streams
2026-01-02 21:57:53 +02:00
Bohdan Triapitsyn 8505455c2e release v1.4.0 2026-01-01 16:18:05 +02:00
Bohdan Triapitsyn a9f3180439 release v1.3.9 2025-12-30 21:32:27 +02:00
Bohdan Triapitsyn 2c833cef40 feat: Implement skill management functionality
- Added skill scope helpers and CRUD operations for skills in opencodeConfig.ts.
- Introduced API endpoints for skill management in main.tsx and index.js.
- Enhanced server-side logic to support skill discovery, creation, updating, and deletion.
- Implemented supporting file operations for skills, including reading, writing, and deleting files.
- Updated package.json to use the latest version of @opencode-ai/sdk.
2025-12-30 17:36:52 +02:00
Bohdan Triapitsyn 1492a2e512 release v1.3.8 2025-12-30 00:04:48 +02:00
Nick Roth aefbb1eac2 feat: add intel mac support (#80) 2025-12-28 22:57:26 +02:00
Bohdan Triapitsyn d69ccd154d release v1.3.7 2025-12-28 03:31:24 +02:00
Bohdan Triapitsyn 88e0cedcd3 release v1.3.6 2025-12-27 02:39:50 +02:00
Bohdan Triapitsyn ff874cc33d feat: switch project from pnpm to bun 2025-12-26 16:45:30 +02:00