Commit graph

144 commits

Author SHA1 Message Date
Austin Wang
3c1f1792c0
Fix browser workspace focus handoff lag (#381) 2026-02-23 10:27:04 -08:00
Lawrence Chen
bf69fcbdcf Hide apply-update command until update is available 2026-02-23 04:56:48 -08:00
Lawrence Chen
82d2d0e474 Add command palette apply and attempt update actions 2026-02-23 04:53:25 -08:00
Lawrence Chen
47d0b60cd6
Merge pull request #362 from manaflow-ai/task-cmd-p-show-all-windows
Cmd+P switcher includes workspaces from every window
2026-02-23 04:33:36 -08:00
Lawrence Chen
1e8859f922 Show Cmd+P switcher results across all windows 2026-02-23 04:13:15 -08:00
Lawrence Chen
8d03657c94
Command palette caret uses white tint (#361)
* Set command palette caret tint to white

* Add command palette window actions and shortcut sync
2026-02-23 04:08:01 -08:00
Lawrence Chen
5d63c5f035
Add command palette (Cmd+Shift+P) (#358)
Implements a VS Code-style command palette with fuzzy search,
workspace/surface switching, rename mode, and keyboard navigation.

Closes https://github.com/manaflow-ai/cmux/issues/133
2026-02-23 03:26:36 -08:00
Lawrence Chen
eb1f0bdd43 Unify theme refresh path across workspace and titlebar 2026-02-23 02:44:28 -08:00
Lawrence Chen
1b954f1d68 Sync theme updates in same frame on theme switch 2026-02-23 01:11:27 -08:00
Vadim Kostin
2d454df50f feat(sidebar): show linked pull request metadata 2026-02-23 10:45:36 +08:00
Lawrence Chen
0105b6256a
Add workspace tab color schemes and debug scheme toggle (#324)
* Add tab color feature to sidebar workspaces

Lets users assign a custom background color to any sidebar workspace tab
via a right-click "Tab Color" submenu. The primary motivation is working
across multiple projects simultaneously — coloring tabs by project makes
it instant to visually locate the right workspace without reading the title.

- Workspace: adds `customColor: String?` (@Published hex string) and
  `setCustomColor()` setter
- TabManager: adds `setTabColor(tabId:color:)` convenience method
- ContentView: 16-color dark palette (all luminance < 0.30, white text
  always readable), `Color(hex:)` extension, `coloredCircleImage(hex:)`
  helper to render bitmapped NSImage circles (needed because macOS menus
  strip SwiftUI foregroundColor from SF Symbols), updated `backgroundColor`
  to use custom color at full/70%/35% opacity for active/inactive/
  multi-selected states, "Tab Color" submenu in context menu with
  "Clear Color" option, and a 1.5pt `Color.primary` border overlay on
  the active tab for clear selection indication when custom colors are set

* Add workspace tab color schemes with settings and debug toggles

* Remove Kelly scheme and keep only original tab color palette

* Preserve neutral grayscale when brightening tab colors

* Harden UpdatePill UI test polling timeouts

---------

Co-authored-by: Andreas Fruth <andreas.fruth@gmail.com>
2026-02-22 17:30:30 -08:00
Lawrence Chen
07796232d7 Sync customizable shortcuts across menus and tooltips 2026-02-22 16:24:43 -08:00
Lawrence Chen
927b0eb2d1 Implement session persistence pass 1 with multi-window restore 2026-02-22 15:39:59 -08:00
Austin Wang
78fe5a9b04
Fix cmux border resize icon disappearing (#284)
* Keep split dividers visible in tiny panes

* Fix collapsed split border resize hit-testing

* Stabilize sidebar and split divider resize routing

* Fix split divider resize cursor routing regressions
2026-02-21 17:57:00 -08:00
Lawrence Chen
685996ef0d
Remove border below titlebar (#242)
* Remove border below titlebar

Remove the 1px separator line overlay at the bottom of the custom
titlebar and its associated fakeTitlebarSeparatorColor computed property.

* Remove tab hover background in bonsplit

Update bonsplit submodule to remove the background fill on hovered
non-selected tabs.

* Restore titlebar border with system separator color, hover bg on all tabs, browser theme bg

- Add back 1px bottom border on titlebar using NSColor.separatorColor
  (matches bonsplit tab separator color)
- Tab hover background now applies to all tabs including the selected one
- Browser address bar and under-page background now use Ghostty theme
  background color instead of window background
2026-02-21 04:31:55 -08:00
Lawrence Chen
a2c39802d1 Merge origin/main into feat-sidebar-branch-refresh-on-close 2026-02-20 23:36:11 -08:00
Lawrence Chen
868c2c9d11 Tighten spacing around branch separator dot 2026-02-20 23:26:47 -08:00
Lawrence Chen
7cb1abca37 Use smaller separator dot for branch directory rows 2026-02-20 23:20:58 -08:00
Austin Wang
021cc05cf3
Stabilize sidebar resizer hitbox and cursor across portals (#255) 2026-02-20 23:14:48 -08:00
Lawrence Chen
5ffae27d64 Use dot icon separator between branch and directory 2026-02-20 22:39:26 -08:00
Lawrence Chen
277e95d07e Use non-path separator for branch directory rows 2026-02-20 22:35:14 -08:00
Lawrence Chen
b3c28a8723 Render vertical sidebar rows as branch and directory 2026-02-20 22:31:17 -08:00
Lawrence Chen
5ca1616bd2 Add vertical sidebar branch layout setting 2026-02-20 22:26:10 -08:00
Lawrence Chen
c533ebe5e5 Render sidebar branches in split/tab display order 2026-02-20 21:59:35 -08:00
Lawrence Chen
5c0c2d9bf9 Merge origin/main and keep TabManager title updates synchronous 2026-02-20 20:29:47 -08:00
Lawrence Chen
d1524c347c Merge origin/main into issue-230-main-thread-notification-cascade 2026-02-20 20:18:02 -08:00
Lawrence Chen
641124c084 Coalesce title notification updates to reduce main-thread hangs 2026-02-20 20:14:19 -08:00
Lawrence Chen
10e44396df Add tab/workspace action APIs and consistent naming 2026-02-20 20:13:36 -08:00
Lawrence Chen
fe6c9ec1dc Restrict portal pass-through to active drag-motion events 2026-02-20 20:07:54 -08:00
Lawrence Chen
a5c7600458 Harden drag overlay routing and add terminal overlay regression probes 2026-02-20 19:58:58 -08:00
Lawrence Chen
9388358914 Merge remote-tracking branch 'origin/main' into fix-dragdrop-overlay 2026-02-20 19:53:45 -08:00
Lawrence Chen
699e708601 Scope command shortcut hints to active window 2026-02-20 18:48:29 -08:00
Lawrence Chen
cf767cf9af Fix bonsplit drag routing and pin submodule commit 2026-02-20 18:47:34 -08:00
Lawrence Chen
23979d8c02 Merge origin/main into fix-dragdrop-overlay 2026-02-20 18:29:36 -08:00
Austin Wang
04431751ce
Fix file drag-and-drop and file input in browser panel (#214)
* Fix file drag-and-drop and file input in browser panel (#194)

Two fixes for the browser panel:

1. File drag-and-drop from Finder: CmuxWebView previously suppressed ALL
   drag type registration as a no-op to prevent bonsplit tab drags from
   being intercepted. Now it selectively filters out only the text-based
   types that conflict with bonsplit (public.text, public.utf8-plain-text,
   public.plain-text) and the custom tab transfer types, while allowing
   file URL types through so Finder drops work.

2. File <input> elements: Added the WKUIDelegate runOpenPanelWith method
   to BrowserUIDelegate so clicking a file input opens the native macOS
   file picker (NSOpenPanel), with support for multiple selection and
   directory picking as specified by the HTML element.

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

* chore(claude-opus-4-6): take a look at https://github.com/manaflow-ai/cmux/issues...

* ok

* wok

---------

Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-20 18:26:23 -08:00
Lawrence Chen
146ac253af Harden file-drop routing for local tab drags 2026-02-20 16:27:12 -08:00
Lawrence Chen
a5d724cf28 Unify drag overlay routing and add regression coverage 2026-02-20 16:09:42 -08:00
Lawrence Chen
573cec4a75
Fix inconsistent Tab/Workspace terminology in settings and menus (#187)
Unify user-facing labels to consistently use "Workspace" instead of
mixing "Tab" and "Workspace":

- Settings: "New Tab" → "New Workspace" (keyboard shortcuts section)
- Menu: "Tab 1"–"Tab 9" → "Workspace 1"–"Workspace 9" (Cmd+1–9)
- Sidebar context menu: "Close Tabs" → "Close Workspaces",
  "Close Tabs Below/Above" → "Close Workspaces Below/Above"

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

Co-authored-by: austinpower1258 <austinwang115@gmail.com>
2026-02-20 14:58:58 -08:00
Lawrence Chen
1650ba372f
Fix sidebar workspace staying dim after external drop (#207)
* Fix stuck sidebar dim state after external drop

* Debug sidebar drag outside-drop flow with content overlay

* Handle sidebar drag endings outside window

* Fix stale update feed resolver tests
2026-02-20 14:53:57 -08:00
Austin Wang
f455af4541
Fix issue #185 overlay recursion hardening and scroll regression (#193) 2026-02-20 14:51:44 -08:00
Lawrence Chen
cae40d1a4c
Sidebar ports on own line, wider sidebar, CMUX_PORT env vars (#160)
* Sidebar ports on own line, wider sidebar, CMUX_PORT env vars

- Move listening ports to dedicated sidebar row (removed from branch/directory line)
- Allow sidebar to resize up to 2/3 of screen width (was capped at 360px)
- Add CMUX_PORT, CMUX_PORT_END, CMUX_PORT_RANGE env vars per workspace
- Each workspace gets a dedicated port range (default: base 9100, range 10)
- Add settings UI for port base and range size
- Add portOrdinal to Workspace, monotonic counter in TabManager

Closes #129

* Make port ordinal counter static to avoid overlap across windows

Each window creates its own TabManager, so a per-instance counter
would reset and reuse port ranges. Making it static ensures unique
ranges across all windows.

* Fix portOrdinal race: pass through Workspace init instead of setting after

The first TerminalPanel is created inside Workspace.init, so setting
portOrdinal after init returns meant the initial terminal always got
ordinal 0. Pass portOrdinal as an init parameter and set it before
the TerminalPanel is created.

* Fix P2/P3: snapshot port settings at surface creation, use window screen for sidebar cap

P2: Port base/range are now snapshotted on TerminalSurface when the
panel is created, so changing settings mid-session won't cause
inconsistent CMUX_PORT values across terminals in the same workspace.

P3: Sidebar max width now uses NSApp.keyWindow?.screen instead of
NSScreen.main, so multi-monitor setups get the correct 2/3 cap for
the display the window is actually on.

* Fix P1: snapshot port base/range once per app session, not per panel

Port base and range size are now static properties on TerminalSurface,
initialized once from UserDefaults at first access. This prevents
overlapping port ranges across workspaces when settings are changed
mid-session (e.g., workspace 1 with range=10 at 9110-9119, then
range changed to 5, workspace 2 would overlap at 9110).
2026-02-20 14:12:14 -08:00
Lawrence Chen
7b2675cd1e
Fix theme initialization to respect configured/system appearance (#161)
* Respect configured appearance before Ghostty initialization

* Apply Ghostty theme colors to cmux titlebar and tab chrome

* Fix builtin theme resolution and tab strip icon contrast

* Alias builtin Solarized names to current Ghostty themes

* Sync tab chrome with active Ghostty theme

* Fix system appearance theme switching for surfaces

* Refresh titlebar on background theme updates

* Refresh split overlay config on appearance change

* Update bonsplit for chrome color review fixes
2026-02-20 04:51:01 -08:00
austinpower1258
b739e918c9 works 2026-02-19 23:52:09 -08:00
Lawrence Chen
631f689aba Fix stale drag overlay click routing and add real-click regression test 2026-02-19 05:21:15 -08:00
Lawrence Chen
d08f28d770
Merge pull request #83 from manaflow-ai/perf/portal-hosting-selected-mount
Reduce terminal input latency via portal hosting + selected-only workspace mounting
2026-02-18 22:31:45 -08:00
Lawrence Chen
ee4848c008 Speed up workspace switching: reduce portal churn and enforce selected z-order 2026-02-18 22:13:40 -08:00
Lawrence Chen
7aa80b9cdc Stabilize rapid workspace switching handoff 2026-02-18 21:17:53 -08:00
Austin Wang
2d64ecfc44
fixes crashes and filedrop fatal issue 2026-02-18 20:46:31 -08:00
Lawrence Chen
ed7f6301d0 Improve terminal hosting depth and workspace mount policy 2026-02-18 19:55:41 -08:00
Lawrence Chen
03a1cc13e0
Fix stack overflow in FileDropOverlayView mouse forwarding (#82)
The hide-send-unhide pattern in forwardEvent() can recurse infinitely
when gesture recognizer routing re-delivers the event despite isHidden.
Add a re-entrancy guard to break the cycle.

Fixes EXC_BAD_ACCESS (stack overflow) crash in production.
2026-02-18 19:51:25 -08:00