Skip to content

Fix terminal drag hover overlay flicker - #1046

Merged
austinywang merged 1 commit into
mainfrom
issue-1045-drag-hover-terminal-flicker
Mar 7, 2026
Merged

austinywang merged 1 commit into
mainfrom
issue-1045-drag-hover-terminal-flicker

Conversation

@austinywang

@austinywang austinywang commented Mar 7, 2026 •

Copy link
Copy Markdown
Contributor

Summary

  • update vendor/bonsplit to render pane drop hover indicators as non-layout overlays
  • keep portal-hosted terminal geometry stable while drag hover targets change
  • add bonsplit regression coverage for hover overlays not resizing hosted content

Related

Verification

  • cd vendor/bonsplit && swift build --build-tests
  • ./scripts/reload.sh --tag fix-drop-hover-overlay currently fails on an unrelated existing compile error in Sources/Update/UpdateTitlebarAccessory.swift:324

Summary by cubic

Fixes terminal drag-hover flicker by updating bonsplit to render drop targets as non-layout overlays, keeping terminal geometry stable. Closes #1045.

  • Dependencies
    • Update vendor/bonsplit to include the overlay fix and regression tests preventing hover overlays from resizing hosted content.

Written for commit e019293. Summary will update on new commits.

Summary by CodeRabbit

  • Chores
    • Updated dependency to latest version. No functional changes.

@vercel

vercel Bot commented Mar 7, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
cmux Ready Ready Preview, Comment Mar 7, 2026 6:32pm

@austinywang
austinywang merged commit 901cacc into main Mar 7, 2026
6 of 12 checks passed
@coderabbitai

coderabbitai Bot commented Mar 7, 2026 •

Copy link
Copy Markdown

Caution

Review failed

The pull request is closed.

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 416e6157-c2ae-4681-aa7a-c98856d245f1

📥 Commits

Reviewing files that changed from the base of the PR and between 0c11bc1 and e019293.

📒 Files selected for processing (1)
  • vendor/bonsplit

📝 Walkthrough

Walkthrough

The vendor/bonsplit submodule reference is updated to a newer commit. No functional code changes, control flow modifications, or exported entity declarations are altered. This is a straightforward dependency version bump with minimal impact.

Changes

Cohort / File(s) Summary
Submodule Update
vendor/bonsplit
Submodule reference updated from commit c5b3dd4cd314f7452bd27ffacd00ebeb19d96d17 to 6739829 with no functional code changes.

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~3 minutes

Poem

🐰 A version bump so clean and small,
Just one line changed, no fuss at all,
The bonsplit grows to newer heights,
No flickering terminals in sight! ✨
Hop along, the code still right!

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch issue-1045-drag-hover-terminal-flicker

Comment @coderabbitai help to get the list of available commands and usage tips.

@cubic-dev-ai cubic-dev-ai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No issues found across 1 file

@greptile-apps

greptile-apps Bot commented Mar 7, 2026

Copy link
Copy Markdown
Contributor

Greptile Summary

This PR advances the vendor/bonsplit submodule pointer from c5b3dd4 to 6739829 to pull in a fix (bonsplit PR #18) that renders pane drop hover indicators as non-layout overlays, preventing the SwiftUI layout engine from resizing portal-hosted terminal views whenever a drag target changes. No Swift source files in the main cmux repo were modified.

Key changes

  • vendor/bonsplit bumped to 6739829bb54a2293dfcea6e6717fbe0d2e4b966b; actual implementation changes (overlay rendering, portal geometry stability, regression tests) live in the bonsplit repo.

Points to verify before merging

  • The new bonsplit commit must be reachable from origin/main in the manaflow-ai/bonsplit repo (per the submodule safety policy in CLAUDE.md/AGENTS.md). The PR links to bonsplit PR Fix zsh ZDOTDIR wrapper + log parsing for -- tokens #18 but does not explicitly confirm it has been merged to main.
  • The full cmux build remains unverified because of the pre-existing compile error in Sources/Update/UpdateTitlebarAccessory.swift:324. While unrelated to this change, it means CI cannot currently give a clean green signal on this bump.

Confidence Score: 4/5

  • Safe to merge once the bonsplit commit is confirmed on origin/main; the change is self-contained and low-risk.
  • The diff is a single submodule pointer update with no changes to cmux source files, making regression risk minimal. The score is held at 4 rather than 5 because the submodule safety policy (commit must be on main before the parent pointer is updated) has not been explicitly confirmed, and the full end-to-end build is currently blocked by a pre-existing unrelated compile error.
  • vendor/bonsplit — verify the new commit SHA is on the remote main branch of manaflow-ai/bonsplit before merging.

Important Files Changed

Filename Overview
vendor/bonsplit Submodule pointer bumped from c5b3dd4 to 6739829; intended to change hover drop indicators to non-layout overlays and stabilise portal-hosted terminal geometry during drags. Actual bonsplit source changes are in the linked bonsplit PR #18 and cannot be reviewed here. Whether 6739829 is on bonsplit's remote main branch — required by the submodule safety policy — is unverified in this diff.

Sequence Diagram

sequenceDiagram
    participant User as User (drag gesture)
    participant BSV as BonsplitView
    participant PD as PaneDragContainerView
    participant OL as HoverOverlay (non-layout)
    participant TW as TerminalWindowPortal

    User->>BSV: begin drag over split pane
    BSV->>PD: hover target changes
    PD->>OL: show/hide drop indicator (overlay only)
    Note over OL,TW: Old behaviour: layout recalculated → portal resized → flicker
    Note over OL,TW: New behaviour: overlay is out-of-layout → portal geometry unchanged
    OL-->>TW: geometry stable (no resize event)
    User->>BSV: drop or cancel drag
    BSV->>PD: clear hover target
    PD->>OL: hide drop indicator
Loading

Last reviewed commit: e019293

Comment thread vendor/bonsplit
@@ -1 +1 @@
Subproject commit c5b3dd4cd314f7452bd27ffacd00ebeb19d96d17
Subproject commit 6739829bb54a2293dfcea6e6717fbe0d2e4b966b

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Verify bonsplit commit is on remote main

CLAUDE.md and AGENTS.md both document a hard submodule safety rule:

Always push the submodule commit to its remote main branch before committing the updated pointer in the parent repo. Never commit on a detached HEAD or temporary branch — the commit will be orphaned and lost.
Verify with: cd vendor/bonsplit && git merge-base --is-ancestor HEAD origin/main

This PR points vendor/bonsplit at 6739829 and links to bonsplit PR #18, but the description does not confirm that PR has been merged to main in the manaflow-ai/bonsplit repo. If 6739829 lives only on a feature branch or a detached HEAD, it could be garbage-collected and the parent-repo pointer would become dangling.

Please confirm the bonsplit commit is reachable from origin/main before merging.

Comment thread vendor/bonsplit
@@ -1 +1 @@
Subproject commit c5b3dd4cd314f7452bd27ffacd00ebeb19d96d17
Subproject commit 6739829bb54a2293dfcea6e6717fbe0d2e4b966b

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

End-to-end build is unverified

The PR's verification section notes:

./scripts/reload.sh --tag fix-drop-hover-overlay currently fails on an unrelated existing compile error in Sources/Update/UpdateTitlebarAccessory.swift:324

While the failure is attributed to a pre-existing issue, it means the full cmux build with this new bonsplit version has not been confirmed clean. If the pre-existing error is blocking CI it may mask any new failures introduced by this bonsplit bump. Consider tracking the UpdateTitlebarAccessory.swift:324 compile error so it does not continue to obscure build health on future PRs.

austinywang added a commit that referenced this pull request Mar 7, 2026
austinywang added a commit that referenced this pull request Mar 7, 2026
bn-l pushed a commit to bn-l/cmux that referenced this pull request Apr 3, 2026
…hover-terminal-flicker

Fix terminal drag hover overlay flicker
bn-l pushed a commit to bn-l/cmux that referenced this pull request Apr 3, 2026
bn-l pushed a commit to bn-l/cmux that referenced this pull request Apr 3, 2026

This branch was successfully deployed

1 active deployment
Preview — e0192932 Deployed Mar 7, 2026 by vercel[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Terminal flickers and re-renders when drag target hovers over it

1 participant