feat(desktop): add Mac-native zoom shortcuts (Cmd+=/-/0)#6
Merged
Conversation
Agent-Logs-Url: https://github.com/Genuifx/claude-code-env-manager/sessions/795cefa6-ad89-42e5-b67c-33278b63e920 Co-authored-by: Genuifx <10156994+Genuifx@users.noreply.github.com>
Agent-Logs-Url: https://github.com/Genuifx/claude-code-env-manager/sessions/795cefa6-ad89-42e5-b67c-33278b63e920 Co-authored-by: Genuifx <10156994+Genuifx@users.noreply.github.com>
Agent-Logs-Url: https://github.com/Genuifx/claude-code-env-manager/sessions/2b1c64d5-8e6b-4c13-ba99-cd17509123a9 Co-authored-by: Genuifx <10156994+Genuifx@users.noreply.github.com>
Copilot created this pull request from a session on behalf of
Genuifx
May 18, 2026 16:36
View session
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.
The desktop app had no way to scale the UI; users expect the standard macOS zoom keys to work like in native apps and browsers.
Changes
useZoomhook (apps/desktop/src/hooks/useZoom.ts)Cmd/Ctrl + =/+(zoom in),Cmd/Ctrl + -(zoom out),Cmd/Ctrl + 0(reset).getCurrentWebview().setZoom()so the whole webview scales like browser Cmd+/-, rather than via CSS hacks.0.5–2.0in0.1steps (rounded to avoid float drift), persists tolocalStorageunderccem-zoom-level, restores on mount.keydownlistener registered in capture phase so the shortcuts win against inputs, textareas, terminals, and contenteditable surfaces. Combos includingAltare ignored to avoid clashing with other namespaces.Capability: added
core:webview:allow-set-webview-zoomtoapps/desktop/src-tauri/capabilities/default.json— required for the JSsetZoomIPC call.Wiring:
App.tsxcallsuseZoom()alongside the existinguseKeyboardShortcuts. No change to the existing global shortcut map.Notes
localStorage), not part of~/.ccem/config.json— this is a UI preference, not cross-CLI config.zoomondocumentElement; switched to the native Tauri API after confirming it's the supported path.