Repository navigation
Conversation
Move the traffic lights to the native 52pt unified-toolbar position (circle at 20, 20), request the sidebar material for the main window, and grant start-dragging so toolbar drag regions can move the window. The sidebar material stays hidden until the tauri crate enables the macos-private-api feature and the window sets transparent: true. Only tauri.conf.json may change in this PR, so those steps are left out.
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.
Why
The design spec (7.1, 7.4) puts Lore's window chrome on Apple Mail's model. The window gets a 52px unified toolbar with native traffic lights, a sidebar material, and a toolbar you can drag. This PR sets those window values in
tauri.conf.json, so the UI PRs can build on them.What changed
trafficLightPositionchanges from 16, 11 to 19, 24. Tauri sets the close button's frame x tox. It resizes the titlebar container to the button height plusy, and the button keeps a 6pt bottom margin. So the circle lands atx + 1,y - 4, which is 20, 20. That is the measured native position for a.unifiedtoolbar (appkit-metrics.md, section 5).windowEffectsrequests thesidebarmaterial and follows the window's active state.app.security.capabilitiesnow lists"default"plus an inlinewindow-dragcapability. That capability grants onlycore:window:allow-start-draggingon windowmain.Scope
src-tauri/Cargo.tomlneedsfeatures = ["macos-private-api"]. The config then needsapp.macOSPrivateApi: trueandtransparent: trueon the window. Without the Cargo feature, Tauri dropstransparenton macOS and the webview paints an opaque background over the effect view.tauri-buildalso fails the build ifmacOSPrivateApiis set without the feature. The private API also blocks Mac App Store distribution. That decision belongs to the owner, so this PR leaves it out.data-tauri-drag-regionmarkup comes in the UI PR. This PR only grants the permission it needs.Tradeoffs
transparent: trueout for now. Without the Cargo feature it has no effect, and debug builds print a warning on every launch. It belongs in the same change that turns on the private API.app.security.capabilities. Once that list is non-empty, Tauri stops loadingcapabilities/on its own. So the list names"default"explicitly. A missing reference fails the build, so a renamed file cannot be dropped without notice.Blast Radius
The change touches only the macOS main window. On screen, the traffic lights move down and right. The IPC surface gains one command,
start_dragging, on windowmain. Alldefaultpermissions stay in place. Double-click to zoom already worked, becausecore:defaultincludesinternal-toggle-maximize.Verification
cargo build -p lore-apppasses.plugin:window|start_dragging. With this config, the table has it, next toplugin:dialog|open,plugin:dialog|saveand thecore:defaultcommands.src-tauri/gen/schemas/capabilities.jsonlists only the file scan (default), because Tauri merges the inline capability later, at codegen..unified.