fix: close pane gaps by centering resize handle on the seam

This commit is contained in:
Linus Rath
2026-06-02 01:17:09 +02:00
parent 75c02f443f
commit 8f7066d194
+4 -2
View File
@@ -77,9 +77,11 @@ export function ResizeHandle({ onResizeStart, onResize, onResizeEnd, onDoubleCli
onKeyDown={handleKeyDown}
onDoubleClick={onDoubleClick}
className={cn(
"flex-shrink-0 hover:bg-primary/30 active:bg-primary/50 transition-colors relative group",
// Centered over the seam with negative margins so the handle adds no
// net layout space (panes sit flush) while staying draggable.
"flex-shrink-0 hover:bg-primary/30 active:bg-primary/50 transition-colors relative group z-10",
"focus-visible:outline-none focus-visible:bg-primary/40 focus-visible:ring-2 focus-visible:ring-primary/50",
isHorizontal ? "h-1 cursor-row-resize bg-border" : "w-1 cursor-col-resize",
isHorizontal ? "h-1 -my-0.5 cursor-row-resize bg-border" : "w-1 -mx-0.5 cursor-col-resize",
className
)}
>