Commit graph

130 commits

Author SHA1 Message Date
Lawrence Chen
7cbac356fc
Add optional single-click focus for inactive panes (#1796)
* Add failing first-click pane focus tests

* Enable optional first-click focus for inactive panes

* Address PR review follow-ups

---------

Co-authored-by: Lawrence Chen <lawrencecchen@users.noreply.github.com>
2026-03-19 01:01:10 -07:00
Lawrence Chen
637a0eed13
Add command palette minimal mode actions 2026-03-18 04:18:11 -07:00
Lawrence Chen
1e908b2b75
Merge origin/main into feat-hidden-titlebar-minimalism-reset 2026-03-18 04:05:43 -07:00
Lawrence Chen
798c1fbc42
Fix laggy terminal sync during sidebar drags (#1598)
* Fix sidebar drag terminal resize lag

* Add display resolution churn regression

* Prelaunch display churn helper in e2e workflow

* Use manifest handoff for display churn UI test

* Fix e2e display churn harness startup

* Resolve display churn UI test socket path

* Use marker-based socket discovery in display UI test

* Add failing sidebar drag portal regression tests

* Fix sidebar drag terminal portal resize lag

* Add failing scoped resize regression tests

* Fix terminal portal resize scheduling lag

* Add failing zsh resize prompt regression test

* Fix zsh resize prompt duplication

* Fix Sequoia sidebar resize regression

* Guard display-resolution CI runner

* Run display-resolution CI on WarpBuild

* Allow backgrounded display regression app launch

* Launch display regression app directly

* Launch display regression app via NSWorkspace

* Load display regression launch env from manifest

* Write display regression manifest in runner temp dir

* Write display regression manifest in shared tmp

* Write display regression manifest in repo scratch dir

* Launch display regression app with explicit env

* Avoid xcodebuild broken pipe in compat CI

* Launch display regression via XCUIApplication

* Harden display regression socket readiness

* Trust display socket diagnostics path

* Replace display socket probe with render diagnostics

* Write display churn start marker atomically

* Move display churn harness out of /tmp

---------

Co-authored-by: Lawrence Chen <lawrencecchen@users.noreply.github.com>
2026-03-18 01:28:11 -07:00
Austin Wang
55cb5c6763
Fix sidebar workspace PR status display and false positives (#1636)
* test(sidebar): add failing PR checks regressions

* fix(sidebar): show workspace PR status

* refactor(sidebar): restore PR icon style

* refactor(sidebar): simplify PR check labels

* test(sidebar): cover focused workspace PR selection

* fix(sidebar): scope workspace PRs to current branch

* test(sidebar): cover stale PR after branch change

* fix(sidebar): clear stale PRs on branch changes

* test(sidebar): cover workspace PR false positives

* fix(sidebar): stop false-positive workspace PR badges

* test(cmuxTests): remove duplicate sidebar PR regressions
2026-03-17 22:57:12 -07:00
Austin Wang
bdd95902f2
Restore last-surface close preference toggle (#1679)
* test: cover last-surface close preference regression

* fix: restore last-surface close preference
2026-03-17 22:36:32 -07:00
Lawrence Chen
58de044f4f
Rename "Import From Browser" to "Import Browser Data" (#1672)
Co-authored-by: Lawrence Chen <lawrencecchen@users.noreply.github.com>
2026-03-17 22:07:19 -07:00
Lawrence Chen
e505782a31
Merge remote-tracking branch 'origin/main' into feat-hidden-titlebar-minimalism-reset 2026-03-17 20:06:43 -07:00
fvallenilla
aefb7767f6
fix: suppress socat stdout in _cmux_send to prevent "OK" leak (#1619)
The socat path in _cmux_send did not redirect stdout/stderr, causing
the cmux socket's "OK" response to print to the user's terminal on
every shell integration event (new tab, cd, precmd, preexec).

The ncat path avoids this via --send-only, and the nc path already
redirects to /dev/null. This aligns the socat path with both.

Fixes #1618

Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-17 17:50:11 -07:00
FredrikSeidl
dfbd238e47
Add 'rc' and 'remote-control' to command passthrough (#1539) 2026-03-17 17:50:08 -07:00
Lawrence Chen
90e573b68f
Merge origin/main into feat-hidden-titlebar-minimalism-reset 2026-03-17 17:37:28 -07:00
Lawrence Chen
f5d610e3ea
Merge remote-tracking branch 'origin/main' into task-browser-import-followups
# Conflicts:
#	Sources/Workspace.swift
2026-03-17 16:49:16 -07:00
Lawrence Chen
c4742a4ba1
Refine browser import minimal UI 2026-03-17 16:46:10 -07:00
Austin Wang
e15825826f
fix: restore Sparkle automatic update checks (#1597) 2026-03-17 03:07:38 -07:00
Lawrence Chen
b9de0f0446
Add browser import hint debug variants 2026-03-17 03:01:50 -07:00
Lawrence Chen
ffcd3fdfaa
Tighten browser import sheet UI 2026-03-17 01:51:57 -07:00
Lawrence Chen
fdde470dcf
fix: address browser profile review follow-ups 2026-03-16 23:50:43 -07:00
Lawrence Chen
03dc055138
Merge remote-tracking branch 'origin/main' into pr-ssh-stack-main
# Conflicts:
#	CLI/cmux.swift
#	Sources/Panels/BrowserPanel.swift
#	Sources/TabManager.swift
#	Sources/Workspace.swift
#	cmuxTests/GhosttyConfigTests.swift
2026-03-16 23:16:12 -07:00
Lawrence Chen
21824f86fd
Replace titlebar and fade toggles with minimal mode 2026-03-16 23:06:05 -07:00
Lawrence Chen
746fb8e5ec
Merge pull request #318 from manaflow-ai/issue-122-import-browser-cookies-history-settings
Browser: import data from detected installed browsers
2026-03-16 22:42:40 -07:00
Lawrence Chen
dc6bcb259a
fix: address browser import review feedback 2026-03-16 22:30:09 -07:00
Lawrence Chen
92cb42262c
feat: add browser profile mapping import flow 2026-03-16 21:22:39 -07:00
Austin Wang
7f220dc8e4
Fix sidebar PR badges for restored workspaces (#1570)
* test: cover sidebar PR explicit branch fallback

* fix: restore sidebar PR badges for workspace branches

* test: preserve sidebar PR badge on first prompt

* fix: keep sidebar PR badges through first prompt
2026-03-16 21:09:02 -07:00
Austin Wang
1480171e5e
Support folder drops on dock icon (#1571) 2026-03-16 21:00:30 -07:00
Lawrence Chen
70ec1a0915
Split fade buttons from titlebar visibility 2026-03-15 21:31:41 -07:00
Manfred Neustifter
6b138f7d9d
feat: support window.open() popup windows (#1150)
* feat: support window.open() popup windows (#742)

Return a live WKWebView from createWebViewWith using WebKit's supplied
configuration, preserving popup browsing-context semantics (window.opener,
postMessage). This fixes OAuth/OIDC flows and any site relying on standard
popup patterns.

- Add BrowserPopupWindowController: NSPanel-based popup with self-retention,
  KVO title/URL, read-only URL label, nested popup depth limit (3),
  insecure-HTTP prompt parity, auth challenge parity, download delegate
- Classifier: scripted requests (window.open) create popups; user-initiated
  actions (Cmd+click, middle-click, context menu) open tabs
- Retarget context menu "Open Link in New Tab" to bypass createWebViewWith,
  wired in both main browser and popup web views
- Cmd+W fast path in AppDelegate for popup windows
- Opener panel owns popup lifecycle; close() tears down all child popups

* fix: Cmd+W closes only the popup, not the parent tab

Add BrowserPopupPanel (NSPanel subclass) that intercepts Cmd+W in
performKeyEquivalent before the swizzled cmux_performKeyEquivalent
can dispatch it to the main menu's "Close Tab" action.

Also refine the popup classifier to reuse browserNavigationShouldOpenInNewTab
for Cmd+click/middle-click detection, add download delegate wiring, and
wire onContextMenuOpenLinkInNewTab for popup web views.

* fix: tighten popup routing and window behavior

* test: cover oversized popup frame clamping

* test: cover plain link-activated popup routing

---------

Co-authored-by: Lawrence Chen <lawrencecchen@users.noreply.github.com>
2026-03-15 17:48:05 -07:00
Jonathan Wukitsch
9b377a930f
Fix About Panel Newline Escaping (#1298)
* fix: about panel newline escaping

* fix: other languages
2026-03-15 16:49:40 -07:00
Lawrence Chen
e4ef98aca1
Implement hidden-titlebar minimalism mode 2026-03-15 16:43:26 -07:00
BillionClaw
5776cd5d81
fix: remove blocking sleep from preexec hook causing command lag (#1444)
When socket connection mode is not 'off', the shell integration runs
_cmux_stop_pr_poll_loop in the preexec hook before every command.
This function had a blocking 'sleep 0.1' call that caused noticeable
lag on every command execution.

The fix replaces the TERM+sleep+KILL pattern with direct SIGKILL.
The PR poll loop is a lightweight background process that only runs
'gh pr view' periodically - it's safe to kill abruptly without
waiting for graceful termination.

Fixes #1436

Co-authored-by: BillionClaw <267901332+BillionClaw@users.noreply.github.com>
2026-03-15 16:11:07 -07:00
Ragnar Rova
a7cb968a55
Add configurable sidebar tint color with light/dark mode support (#1465)
- Config: sidebar-background supports plain hex (#336699) or
  light/dark syntax (light:#fbf3db,dark:#103c48)
- Config: sidebar-tint-opacity overrides tint opacity
- Settings UI: per-scheme color pickers, opacity slider (0-70%), reset
- SidebarBackdrop resolves light/dark hex based on @Environment colorScheme
- applySidebarAppearanceToUserDefaults guards on rawSidebarBackground presence
  so UI picks survive appearance toggles when no config is set
- Stale light/dark UserDefaults keys cleared when config switches from
  dual-mode to single or sidebar-background is removed
- applyPreset() and Reset Tint clear per-scheme overrides
- Debug snapshot (combinedPayload + copySidebarConfig) includes new keys
- ColorPicker labels use String(localized:) per localization policy
- Opacity slider capped at 0.7 to match debug view vibrancy constraint

Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-15 15:48:57 -07:00
Lawrence Chen
623262493b
Fix stale Claude sidebar status: add missing hooks, OSC suppression, PID sweep (#1306)
* Fix stale Claude status in sidebar by adding missing hooks and OSC suppression

The Claude Code integration only used 3 hooks (SessionStart, Stop, Notification),
leaving gaps that caused stale sidebar status. Now uses 6 hooks:

- SessionEnd: clears status when Claude exits (covers Ctrl+C where Stop doesn't fire)
- UserPromptSubmit: clears "Needs input" and sets "Running" on new prompt
- PreToolUse (async): clears "Needs input" when Claude resumes after permission grant

Also:
- Suppress OSC 9/99 desktop notifications for workspaces with active Claude hook
  sessions to prevent duplicates from the raw OSC path
- Store Claude process PID in status entries for stale-session detection
- Add 30-second sweep timer that checks agent PIDs and clears stale entries
  (safety net for SIGKILL/crash where no hook fires)
- Update wrapper test expectations for the new hook set

Fixes https://github.com/manaflow-ai/cmux/issues/1301

* Don't show "Running" status on Claude launch, only when actually working

SessionStart now registers the PID for tracking and OSC suppression via
set_agent_pid without setting a visible status entry. "Running" only
appears when the user submits a prompt (UserPromptSubmit) or Claude
starts using tools (PreToolUse).

Added set_agent_pid / clear_agent_pid socket commands to decouple PID
tracking from visible status entries. OSC suppression checks agentPIDs
instead of statusEntries so it works during the initial idle period.

* Don't restore status entries across app restarts

Status entries are ephemeral runtime state tied to running processes
(e.g. claude_code "Running"). Restoring them after restart shows stale
status for processes that no longer exist.

* Address PR review comments and remove debug logging

- session-end: only clear status/PID/notifications when Stop didn't fire first
- PID sweep: check errno == ESRCH instead of treating all kill(pid,0) failures as dead
- Validate CMUX_CLAUDE_PID > 0
- Propagate tracked PID in pre-tool-use setClaudeStatus
- OSC suppression: use tabManagerFor(tabId:) for multi-window support
- clearAgentPID: resolve tab UUID before async dispatch
- restoreSessionSnapshot: also clear agentPIDs alongside statusEntries
- Fix AskUserQuestion surfaceId overwrite (wrong workspace notification)
- Fix notification text matching for "Claude Code needs your attention"
- AskUserQuestion: render option labels as bracketed inline text
- Remove artificial text truncation limits
- Remove temporary JSONL debug logging from all handlers

* Use resolveTabIdForSidebarMutation in clearAgentPID
2026-03-13 20:47:42 -07:00
Lawrence Chen
2eae782739 Merge remote-tracking branch 'origin/main' into pr-ssh-stack-main
# Conflicts:
#	.github/workflows/ci.yml
#	CLI/cmux.swift
#	Sources/GhosttyTerminalView.swift
#	Sources/SocketControlSettings.swift
#	Sources/TabManager.swift
#	Sources/TerminalController.swift
#	Sources/Workspace.swift
#	ghostty
#	scripts/reload.sh
2026-03-13 17:56:38 -07:00
Lawrence Chen
f90bcbc862
Merge pull request #1382 from manaflow-ai/task-cmd-p-search-all-surfaces
Add Cmd+P all-surface search option
2026-03-13 17:55:10 -07:00
Lawrence Chen
a99ee15672
fix: honor shell state for close confirmation 2026-03-13 15:43:04 -07:00
Austin Wang
03e9b81cf2
Merge pull request #1389 from manaflow-ai/issue-1321-vsc-opens-browser
Fix VS Code command palette to open desktop app
2026-03-13 10:45:08 -07:00
austinpower1258
fcd256a193 Fix VS Code command palette open target 2026-03-13 10:37:36 -07:00
Lawrence Chen
3135b4b13e
Add Cmd+P all-surfaces search option 2026-03-13 07:43:57 -07:00
Lawrence Chen
f3a0bd9d15
Merge pull request #1379 from manaflow-ai/task-drag-related-regression
Fix internal drag regressions from bundle type declarations
2026-03-13 07:36:19 -07:00
Lawrence Chen
85e6a5aae4 Fix ssh stack review regressions 2026-03-13 07:29:22 -07:00
Lawrence Chen
ee3b027703
Change help menu "Welcome" to "Welcome to cmux!" (#1377)
Co-authored-by: Lawrence Chen <lawrencecchen@users.noreply.github.com>
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-13 07:24:51 -07:00
Lawrence Chen
1f9a1997b9
fix: restore internal drag type exports 2026-03-13 07:24:07 -07:00
Lawrence Chen
4eb7a37972
Add Discord link to help menu (#1366)
Co-authored-by: Lawrence Chen <lawrencecchen@users.noreply.github.com>
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-13 06:49:11 -07:00
Lawrence Chen
c7b54b78d6
Add subtitle to App Icon setting to clarify it's not a theme toggle (#1367)
* Add subtitle to App Icon setting to reduce confusion with theme

Users were confusing the App Icon picker (Automatic/Light/Dark) with
the Theme toggle. Add "Dock and app switcher" subtitle to clarify
this setting only affects the icon appearance, not the app theme.

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

* Replace Theme dropdown with visual appearance picker

Draw window thumbnails showing light/dark previews with traffic light
dots and content bars, matching the macOS System Settings appearance
picker pattern. System mode shows overlapping light+dark thumbnails.

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

* Swap theme picker to Gemini's wallpaper + layered window design

Replace flat single-window thumbnails with richer previews: wallpaper
gradient backgrounds, menu bar with Apple logo, two layered windows
with shadows, and a split-mask for the System option (light on left,
dark on right with center divider), matching the macOS System Settings
appearance picker more closely.

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

* Move Theme and App Icon pickers to right-aligned row layout

Both pickers now use an HStack with the label on the left and
thumbnails on the right, matching the SettingsCardRow pattern.
Thumbnails get layoutPriority(1) so the label text compresses
first on narrow windows. Slightly smaller thumbnails (76x50 for
theme, 48px icons) to fit comfortably at minimum settings width.

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

* Top-align labels in Theme and App Icon picker rows

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

* Increase hitbox on picker buttons and remove focus ring

Add contentShape(Rectangle()) for full-area tap targets, increase
padding (8v/10h), and add focusable(false) to prevent the macOS
keyboard focus outline from showing on the buttons.

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

* Use rounder squircle corners on theme thumbnails

Bump cornerRadius from 10 to 14 on the thumbnail clip shape and
border for a more pronounced squircle look.

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

* Use true superellipse squircle shape for theme thumbnails

Add a Squircle shape that draws a superellipse (n=4) path blended
with an ellipse based on corner radius. Apply it to the theme
thumbnail clip and border instead of RoundedRectangle.

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

* Remove custom Squircle struct, use built-in continuous rounded rect

RoundedRectangle(style: .continuous) is Apple's squircle. The custom
superellipse shape was unnecessary.

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

---------

Co-authored-by: Lawrence Chen <lawrencecchen@users.noreply.github.com>
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-13 06:42:08 -07:00
Lawrence Chen
2c9464c0bc Proxy remote browser favicon fetches 2026-03-13 06:17:35 -07:00
Lawrence Chen
21246c7657 Merge origin/main into pr-ssh-stack-main 2026-03-13 04:30:06 -07:00
Lawrence Chen
4fffe3be3d Address ssh stack review follow-ups 2026-03-13 04:28:24 -07:00
Lawrence Chen
601e5a92e4 Merge origin/main into pr-ssh-stack-main 2026-03-13 04:18:07 -07:00
Lawrence Chen
9eefc80e32 Share last-surface close handling across close actions 2026-03-13 04:16:59 -07:00
Lawrence Chen
2e6856ff2f Fix ssh stack review regressions 2026-03-13 04:14:52 -07:00
Lawrence Chen
fe7ef33fea
Keep workspaces open when closing the last surface (#1315)
* Add last-surface close regression tests

* Keep workspaces open when closing last surface

* Add Cmd+W last-surface close setting

* Share Cmd+W surface-close path
2026-03-13 03:58:07 -07:00