The open source coding agent.
TypeScript
fix(app): drag region for native controls (#11854)
Filip96fbc309450c
diff --git a/packages/app/src/components/titlebar.tsx b/packages/app/src/components/titlebar.tsxindex affb6854116..86b4fbeb1b9 100644--- a/packages/app/src/components/titlebar.tsx+++ b/packages/app/src/components/titlebar.tsx@@ -137,7 +137,6 @@ export function Titlebar() {<headerclass="h-10 shrink-0 bg-background-base relative grid grid-cols-[auto_minmax(0,1fr)_auto] items-center"style={{ "min-height": minHeight() }}- data-tauri-drag-region><divclassList={{@@ -145,10 +144,9 @@ export function Titlebar() {"pl-2": !mac(),}}onMouseDown={drag}- data-tauri-drag-region><Show when={mac()}>- <div class="h-full shrink-0" style={{ width: `${72 / zoom()}px` }} data-tauri-drag-region />+ <div class="h-full shrink-0" style={{ width: `${72 / zoom()}px` }} /><div class="xl:hidden w-10 shrink-0 flex items-center justify-center"><IconButtonicon="menu"@@ -222,13 +220,10 @@ export function Titlebar() {</Tooltip></div></div>- <div id="opencode-titlebar-left" class="flex items-center gap-3 min-w-0 px-2" data-tauri-drag-region />+ <div id="opencode-titlebar-left" class="flex items-center gap-3 min-w-0 px-2" /></div>- <div- class="min-w-0 flex items-center justify-center pointer-events-none lg:absolute lg:inset-0 lg:flex lg:items-center lg:justify-center"- data-tauri-drag-region- >+ <div class="min-w-0 flex items-center justify-center pointer-events-none lg:absolute lg:inset-0 lg:flex lg:items-center lg:justify-center"><div id="opencode-titlebar-center" class="pointer-events-auto w-full min-w-0 flex justify-center lg:w-fit" /></div>@@ -238,9 +233,8 @@ export function Titlebar() {"pr-6": !windows(),}}onMouseDown={drag}- data-tauri-drag-region>- <div id="opencode-titlebar-right" class="flex items-center gap-3 shrink-0 justify-end" data-tauri-drag-region />+ <div id="opencode-titlebar-right" class="flex items-center gap-3 shrink-0 justify-end" /><Show when={windows()}><div class="w-6 shrink-0" /><div data-tauri-decorum-tb class="flex flex-row" />diff --git a/packages/desktop/index.html b/packages/desktop/index.htmlindex a5a8c2571f0..6a81ef4a50d 100644--- a/packages/desktop/index.html+++ b/packages/desktop/index.html@@ -17,7 +17,7 @@</head><body class="antialiased overscroll-none text-12-regular overflow-hidden"><noscript>You need to enable JavaScript to run this app.</noscript>- <div id="root" class="flex flex-col h-dvh p-px"></div>+ <div id="root" class="flex flex-col h-dvh"></div><div data-tauri-decorum-tb class="w-0 h-0 hidden" /><script src="/src/index.tsx" type="module"></script></body>