Tab drop settles into its slot (classic motion pass)

Merged
TE
6d ago
+306-1

Summary

Classic cmux snaps a dropped tab: the drag image vanishes under the pointer and the tab appears in its new slot at once. A tab reordered within its strip now settles. The drop asks AppKit to slide the drag image into the slot where the pane placed the tab (animatesToDestination, pinned tabs first). The real tab draws nothing there until the drag session ends (or 0.5 s), so it never shows twice.

The drop lands at once, as before, in these cases:

  • under Reduce Motion;
  • for a tab from another pane (its emptied pane may close, and fill-width tabs narrow, so the layout changes under the slot);
  • for file drops;
  • for a slot that is not fully on screen (scrolled, or under the trailing button lane), where the strip scrolls to reveal the tab.

Only the tab row moves. No pane, terminal or browser view animates or resizes.

Testing

  • TabDropSettleTests, red then green. Red on 85a5b5f: the drops landed but animatesToDestination stayed off and the drag image frame was unchanged. Green on 4df2b47. It covers left and right reorders, an unpinned tab dropped among pinned tabs, the session end showing the tab, and Reduce Motion.
  • Full suite in CI: 275 tests, 0 failures.
  • Not yet seen on screen: whether AppKit ends the session only after the slide. If it ends sooner, the tab shows slightly early; it can never stay hidden past 0.5 s.

🤖 Generated with Claude Code