Fix UI selection when dragging pane borders

This commit is contained in:
Skyler Lehmkuhl 2025-10-23 23:25:22 -04:00
parent 976b41cb83
commit 4b1d9dc851
2 changed files with 3 additions and 2 deletions

View File

@ -4522,6 +4522,7 @@ function splitPane(div, percent, horiz, newPane = undefined) {
if (event.target === event.currentTarget) {
if (event.button === 0) {
// Left click
event.preventDefault(); // Prevent text selection during drag
event.currentTarget.setAttribute("dragging", true);
event.currentTarget.style.userSelect = "none";
rootPane.style.userSelect = "none";
@ -4655,7 +4656,7 @@ function splitPane(div, percent, horiz, newPane = undefined) {
{ id: "ctx_option4", text: horiz ? "Join Right" : "Join Down" },
],
});
menu.popup({ x: event.clientX, y: event.clientY });
await menu.popup();
}
console.log("Right-click on the element");

View File

@ -150,7 +150,7 @@ button {
}
.horizontal-grid:not(.panecontainer > .horizontal-grid),
.vertical-grid:not(.panecontainer > .vertical-grid) {
gap: 3px;
gap: 8px;
}
.horizontal-grid {
flex-direction: row;