cmux/Resources
Lawrence Chen 6748c202f2
Fix sidebar drag-and-drop broken by FileDropOverlayView (#76)
* Fix sidebar drag-and-drop broken by FileDropOverlayView

The FileDropOverlayView (added in 9fd3cc2) sits on the window's theme
frame above the content view. Its hitTest returned self for all events,
causing AppKit to route drag sessions to the overlay instead of the
content view where SwiftUI lives. AppKit walks UP the superview chain
from the hit-tested view, never checking siblings — so SwiftUI's
.onDrop handlers for sidebar tab reordering were never reached.

Three changes fix this:

1. Smart hitTest: check NSPasteboard(name: .drag) for .fileURL and only
   return self during Finder file drags. Return nil otherwise so mouse
   events and internal drags pass through to the content view.

2. Custom UTType for sidebar drags: replace the fragile UTType.plainText
   hack with a proper com.cmux.sidebar-tab-reorder type registered in
   Info.plist. Uses visibility: .ownProcess since it's internal-only.

3. Narrow overlay registration: only register for .fileURL instead of
   .fileURL + .URL + .string. The broad .string type collided with
   text-based drag payloads.

* Add custom UTType Info.plist pitfall to CLAUDE.md
2026-02-18 17:20:22 -08:00
..
bin Replace CLAUDE_CONFIG_DIR with claude wrapper + richer notifications 2026-02-15 18:33:36 -08:00
ghostty/terminfo/78 Add cmuxterm CLI and socket control modes 2026-01-28 21:19:48 -08:00
shell-integration Replace CLAUDE_CONFIG_DIR with claude wrapper + richer notifications 2026-02-15 18:33:36 -08:00
terminfo-overlay Release v1.23.0 (#31) 2026-02-09 15:30:43 -08:00
Info.plist Fix sidebar drag-and-drop broken by FileDropOverlayView (#76) 2026-02-18 17:20:22 -08:00