Skip to content

web-ui: only offer session-drop targets that will really happen - #388

Merged
ReganBell merged 1 commit into
mainfrom
upstream-1901
Aug 13, 2026
Merged

web-ui: only offer session-drop targets that will really happen#388
ReganBell merged 1 commit into
mainfrom
upstream-1901

Conversation

@ReganBell

@ReganBell ReganBell commented Aug 13, 2026

Copy link
Copy Markdown
Collaborator

Dragging a session onto the multiview canvas rendered all five drop zones (open-here plus four splits) unconditionally, with legitimacy decided only inside the drop handlers after the drop. So the UI advertised actions that wouldn't happen: at the pane cap a "Split" drop silently became a tab, and dragging a session already on the canvas showed full zones but any drop just focused its existing pane. The overlay now computes which targets are legitimate before rendering and only offers those, so what the user sees is what the drop will do. Tests cover the cap, the already-open session, and single-view cases.

Deployment notes

Builds on the multiview pane work in #1885 (e06ba40af) — land that first or together
Web-ui drag/drop UI logic only


View with [code]smith Autofix with [code]smith
Need help on this PR? Tag @codesmith-bot with what you need. Autofix is disabled.

Dragging a session onto the multiview canvas rendered all five drop zones (open-here plus four splits) unconditionally, with legitimacy decided only inside the drop handlers after the drop. So the UI advertised actions that wouldn't happen: at the pane cap a "Split" drop silently became a tab, and dragging a session already on the canvas showed full zones but any drop just focused its existing pane. The overlay now computes which targets are legitimate before rendering and only offers those, so what the user sees is what the drop will do. Tests cover the cap, the already-open session, and single-view cases.
@ReganBell
ReganBell merged commit 1aefd55 into main Aug 13, 2026
20 checks passed
@ReganBell
ReganBell deleted the upstream-1901 branch August 13, 2026 19:22
ReganBell added a commit that referenced this pull request Aug 13, 2026
Dragging a session onto the multiview canvas rendered all five drop zones (open-here plus four splits) unconditionally, with legitimacy decided only inside the drop handlers after the drop. So the UI advertised actions that wouldn't happen: at the pane cap a "Split" drop silently became a tab, and dragging a session already on the canvas showed full zones but any drop just focused its existing pane. The overlay now computes which targets are legitimate before rendering and only offers those, so what the user sees is what the drop will do. Tests cover the cap, the already-open session, and single-view cases.

**Deployment notes**

Builds on the multiview pane work in #1885 (e06ba40af) — land that first or together
Web-ui drag/drop UI logic only

<!-- codesmith:footer -->
---
<a href="https://app.blacksmith.sh/yc-software/codesmith/qm/pr/388"><picture><source media="(prefers-color-scheme: dark)" srcset="https://pr-comments-assets.blacksmith.sh/codesmith/view-with-codesmith-dark-v2.svg"><source media="(prefers-color-scheme: light)" srcset="https://pr-comments-assets.blacksmith.sh/codesmith/view-with-codesmith-light-v2.svg"><img alt="View with [code]smith" src="https://pr-comments-assets.blacksmith.sh/codesmith/view-with-codesmith-dark-v2.svg"></picture></a> <a href="https://backend.blacksmith.sh/track/enable-autofix?expires=1789237832&installation_model_id=19911&pr_number=388&repository=yc-software%2Fqm&return_to=https%3A%2F%2Fgithub.com%2Fyc-software%2Fqm%2Fpull%2F388&signature=255307e27382f83752dda99ea9a7cf5b6fc53bd872c7b581cb28061fe9f1e106"><picture><source media="(prefers-color-scheme: dark)" srcset="https://pr-comments-assets.blacksmith.sh/codesmith/autofix-with-codesmith-dark.svg"><source media="(prefers-color-scheme: light)" srcset="https://pr-comments-assets.blacksmith.sh/codesmith/autofix-with-codesmith-light.svg"><img alt="Autofix with [code]smith" src="https://pr-comments-assets.blacksmith.sh/codesmith/autofix-with-codesmith-dark.svg"></picture></a>
<sup>Need help on this PR? Tag <code>@codesmith-bot</code> with what you need. Autofix is disabled.</sup>

<!-- codesmith:autofix:disabled -->
<!-- /codesmith:footer -->
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.

1 participant