| @@ -180,23 +180,46 @@ · 179 unmodified lines |
| 180 | desktop window it renders page content straight to the top edge with nothing | 180 | desktop window it renders page content straight to the top edge with nothing |
| 181 | marked as a drag region, so the window could not be moved or | 181 | marked as a drag region, so the window could not be moved or |
| 182 | double-clicked-to-zoom from there (only the sidebar header worked, see | 182 | double-clicked-to-zoom from there (only the sidebar header worked, see |
| 183 | .desktop-macos-titlebar above). Reserve a title-bar-height strip along the | 183 | .desktop-macos-titlebar above). Lay a title-bar-height drag strip along the |
| 184 | top of the main area and make it draggable so the whole top row behaves like | 184 | top of the main area so the whole top row behaves like the native title bar. |
| 185 | the native title bar. Hidden off-desktop. It reserves space rather than | 185 | Hidden off-desktop. It OVERLAYS the top of the main area (absolute, behind |
| 186 | overlaying, so no page content sits under the drag region (a drag region | 186 | page content via z-index) rather than reserving its own row: reserving space |
| 187 | would otherwise swallow clicks on anything beneath it). The traffic lights | 187 | pushed every page header down a full title-bar height, so its bottom border |
| 188 | sit over the sidebar, never the main area, so no left offset is needed here. */ | 188 | no longer lined up with the sidebar header's. Sitting behind, it keeps page |
| | 189 | headers flush with the top (borders aligned again) while the empty/text parts |
| | 190 | of the header stay draggable. Interactive controls carve themselves out of |
| | 191 | the drag region via the global no-drag rule below, so the strip never |
| | 192 | swallows their clicks. The traffic lights sit over the sidebar, never the |
| | 193 | main area, so no left offset is needed here. */ |
| 189 | .desktop-macos-main-titlebar { | 194 | .desktop-macos-main-titlebar { |
| 190 | display: none; | 195 | display: none; |
| 191 | } | 196 | } |
| 192 | | 197 | |
| 193 | .executor-desktop-macos .desktop-macos-main-titlebar { | 198 | .executor-desktop-macos .desktop-macos-main-titlebar { |
| 194 | display: block; | 199 | display: block; |
| | 200 | position: absolute; |
| | 201 | top: 0; |
| | 202 | left: 0; |
| | 203 | right: 0; |
| 195 | height: 3rem; /* matches the sidebar header (h-12) */ | 204 | height: 3rem; /* matches the sidebar header (h-12) */ |
| 196 | flex-shrink: 0; | 205 | z-index: -1; /* behind page content so header controls stay clickable */ |
| 197 | -webkit-app-region: drag; | 206 | -webkit-app-region: drag; |
| 198 | } | 207 | } |
| 199 | | 208 | |
| | 209 | /* Safety net for the overlaid main drag strip: any interactive control that |
| | 210 | ends up within the top title-bar strip must carve itself out of the drag |
| | 211 | region, or the native window-drag would steal its clicks. Mirrors the |
| | 212 | explicit .desktop-macos-no-drag the sidebar header uses on its controls. */ |
| | 213 | .executor-desktop-macos button, |
| | 214 | .executor-desktop-macos a, |
| | 215 | .executor-desktop-macos input, |
| | 216 | .executor-desktop-macos select, |
| | 217 | .executor-desktop-macos textarea, |
| | 218 | .executor-desktop-macos [role="button"], |
| | 219 | .executor-desktop-macos [role="tab"] { |
| | 220 | -webkit-app-region: no-drag; |
| | 221 | } |
| | 222 | |
| 200 | /* The 88px title-bar offset eats into the sidebar's width; without extra room | 223 | /* The 88px title-bar offset eats into the sidebar's width; without extra room |
| 201 | the brand wordmark and the server-connection menu collide. Widen the macOS | 224 | the brand wordmark and the server-connection menu collide. Widen the macOS |
| 202 | sidebar so both clear the traffic lights with comfortable spacing. */ | 225 | sidebar so both clear the traffic lights with comfortable spacing. */ |