Title bar: window buttons on the left are clickable again

The centred title spans the whole bar and inherits its drag region; it came
after the left button group, so its drag covered their no-drag and a click
started a window move instead. The title now goes first.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-11-09 16:37:24 -08:00
co-authored by Claude Opus 5.5
parent 8927c5c59c
commit a2d8f7761e
+5 -1
View File
@@ -218,8 +218,12 @@ function TitleBar({ title, maximized }: { title: string; maximized: boolean }) {
) )
return ( return (
<div className="titlebar" onDoubleClick={control('maximize')}> <div className="titlebar" onDoubleClick={control('maximize')}>
{side(layout[0])} {/* The title spans the whole bar (to stay centred) and inherits its
drag region, so it goes first: drag regions stack in page order,
and the buttons' no-drag must land on top of it or clicks on them
start a window move instead. */}
<div className="tb-title">{title}</div> <div className="tb-title">{title}</div>
{side(layout[0])}
{side(layout[1])} {side(layout[1])}
</div> </div>
) )