fix(desktop): remove titlebar inset in fullscreen#38793
Open
Hona wants to merge 3 commits into
Open
Conversation
The macOS traffic-light padding was keyed only by platform, so it remained after Electron hid the controls in fullscreen.
The __TAURI__ window bridge is always undefined since the Tauri shell was removed; drag, maximize, and setTheme were no-ops (CSS app-region and native OS handling do the real work). The inset change now follows the macOS fullscreen transition and respects reduced motion.
Electron emits macOS fullscreen events after the native transition completes, so animating the inset from those events delayed its alignment with the traffic lights.
Contributor
|
This PR cannot be merged into the beta branch due to: Merge failed Please resolve this issue to include this PR in the next beta release. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
__TAURI__titlebar bridge (drag/maximize/setTheme no-ops, unreachable decorum containers,electronWindowsalias) left behind after the Tauri shell removalRoot cause
The macOS traffic-light padding was keyed only by platform, so the 84px reservation remained after Electron hid the native controls in fullscreen. Electron emits
enter-full-screen/leave-full-screenafter the asynchronous native transition completes, so the inset updates immediately with those events rather than adding a late CSS animation.Notes
data-tauri-drag-regionis kept: it is the live CSS hook forapp-region: draginpackages/ui/src/styles/base.css, just legacy-named. Window dragging and native double-click zoom/maximize are unaffected (the removed handlers always early-returned onwindow.__TAURI__ === undefined).isFullScreen(),enter/leave-full-screen), but only the macOS inset consumes it; Windows continues to size viaenv(titlebar-area-width).Testing
bun typecheckinpackages/appandpackages/desktopbun test ./src/components/titlebar-padding.test.ts ./src/components/titlebar-history.test.ts ./src/components/titlebar-tab-gesture.test.ts ./src/components/titlebar-session-events.test.tsinpackages/appbun test ./src/main/window-registry.test.ts ./electron-builder.config.test.tsinpackages/desktop