fix(desktop): Ctrl+Plus zooms in on Spanish and German keyboard layouts #17069
main fromrefs/pull/17069/head·opened View on GitHubProblem#
On keyboard layouts that type + on the key US layouts label ] (Spanish, German, and others), Ctrl++ (Cmd++ on macOS) no longer zooms the desktop app in. Ctrl+- and Ctrl+0 still work.
The shortcut matcher in packages/shared/src/keybindings.ts falls back to the physical key position for punctuation, so Ctrl++ on these layouts resolves to mod+]. Since mod+] became navigation.forward, the renderer handles that keydown and the View → Zoom In menu accelerator never fires.
Reproduction: Linux (CachyOS, Wayland), Spanish keyboard layout, desktop app, press Ctrl++. Nothing happens. The desktop trace log confirms it: over a session, desktop.window.zoomMain recorded 17 out and 15 reset calls and no in calls.
Change#
In shortcutKeyFromEvent, unshifted keys whose typed character is +, = or - are matched by that character instead of by physical position. Mod plus those characters is zoom, so a layout that types them on another punctuation key no longer fires the shortcut bound to that key's US character, and the keystroke reaches the menu's zoom accelerator.
Physical matching is unchanged for every other key and for shifted presses: Shift++ on the Spanish layout (*) still matches mod+shift+] (thread.next), and US Ctrl+Shift+= still matches mod+shift+=.
Scope and approval#
This is a very small, focused fix for an obvious regression in a core shortcut. It closes #14833 (German layout, macOS).
This takes the same approach as #14739 by @evolveperformance. That PR has been stalled with merge conflicts since 2026-10-02, because the matcher has since moved from apps/web/src/keybindings.ts to packages/shared/src/keybindings.ts. This PR applies the fix at the new location on current main and adds the Linux verification #14739 lists as not checked. If you'd rather land #14739 once it's rebased, close this one.
Background: #2706 and #799 reported earlier versions of zoom-in being unreachable on non-US layouts and Linux.
Verification#
vp test run src/keybindings.test.ts src/components/settings/KeybindingsSettings.logic.test.tsinapps/web: 169 passed. The new test fails without the fix (Ctrl++withcode: "BracketRight"resolves tonavigation.forward) and passes with it.- New tests cover:
- Spanish/German Ctrl+
+no longer resolves tonavigation.forwardand still resolves topreview.zoomInwhen the preview has focus. - Shift on that key still resolves to
thread.next. - US Ctrl+Shift+
=keeps its physical match.
- Spanish/German Ctrl+
- Manual check on Linux (CachyOS, Wayland, Spanish layout) with a locally built AppImage from this branch:
- Ctrl+
+zooms in, one step per press. - Ctrl+
-and Ctrl+0still zoom out and reset. - Ctrl+
[and Ctrl+]still go back and forward.
- Ctrl+
- Not checked: macOS and Windows. The change is in the shared matcher, so it isn't platform-specific, and #14739 verified the same approach on Windows with a German layout.
- No screenshots or recording are attached.
Work done with Claude Opus 5.5 in Claude Code (running in T3 Code).
🤖 Generated with Claude Code
- 1
github-actions[bot](GitHub profile, opens in a new tab) added labelsvouch:unvouched
github-actions[bot](GitHub profile, opens in a new tab) added labelssize:S
Approvability#
Verdict: Approved at
307cd9bMacroscope's review found this PR approvable — This is a narrowly scoped keyboard-layout bug fix that restores existing zoom behavior for Spanish and German layouts while preserving physical matching for shifted shortcuts. The production change is isolated to shared shortcut normalization and is covered by targeted regression tests.
Notes:
- Diff unchanged. Approvability was decided on eligibility alone.
Prgm-code(GitHub profile, opens in a new tab) changed the title
No actionable comments were generated in the recent review. 🎉
ℹ️ Recent review info
⚙️ Run configuration
- Configuration used: Path: .coderabbit.config.ts
- Review profile: CHILL
- Plan: Advanced
- Run ID:
7c2656cc-4219-4c03-b6c5-6fb4a770245e
📥 Commits
Reviewing files that changed from the base of the PR and between 04ad17425a80484bf323a7d5076bd477a9499119 and 307cd9bb6211e36f54e3946452881305fd6d25d4.
📒 Files selected for processing (2)
apps/web/src/keybindings.test.tspackages/shared/src/keybindings.ts
Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 9 remain after this review.
📝 Walkthrough
Walkthrough#
shortcutKeyFromEventnow receivesshiftKeyand uses normalized layout keys for unshifted+,=, and-. Tests cover preview zoom handling and shifted shortcuts that use physical-key matching.Changes#
Layout-aware zoom keybindings
Layer / File(s) Summary Normalize zoom shortcut keys
packages/shared/src/keybindings.ts,apps/web/src/keybindings.test.tsThe resolver handles unshifted +,=, and-by layout key. Tests cover Ctrl++ behavior in and outside preview, shifted-key fallback, and a custom Shift+= binding on Windows.Priority: ⬇️ Low
Estimated code review effort: 2 (Simple) | ~10 minutes
Change: Bug fix · Severity of issue fixed: Low
Suggested reviewers:
juliusmarmingeMerge Risk: ⚪ Minimal · up to
307cdNo concrete merge-blocking regression is established; the unmatched shortcut remains available for the desktop menu to handle.
Security Architecture Review#
Security architecture risk: ⚪ Minimal · up to
307cdThe change removes competing shortcut matches rather than enabling additional application commands. Existing modifier checks and focus restrictions remain intact. No introduced or worsened security risk was identified.
Retained concerns No architecture-level concerns identified.
Security review details
Security Blast Radius
- inferred — For the inspected matching path, event-controlled input cannot gain additional application-command matches through this change: the typed key was already present, and only an alternate physical alias is removed. The affected scope is shortcut selection and potential handoff to existing host handling.
Trust Boundaries and Controls
- observed — Exact modifier matching, the non-macOS AltGraph punctuation exclusion, and binding-context checks remain unchanged. Chat shortcut resolution also retains its separation between primary-environment application commands and active-project script commands.
🚥 Pre-merge checks | ✅ 4
✅ Passed checks (4 passed)
Check name Status Explanation Linked Issues check ✅ Passed The change addresses #14833.shortcutKeyFromEventnow returns unshifted+,=, and-by typed character. A German or SpanishCmd/Ctrl++event therefore no longer resolves tomod+]and `navi…Out of Scope Changes check ✅ Passed The reviewed changes are limited to the shared shortcut matcher and focused keybinding tests. These changes directly support #14833by preventing a layout-dependent collision withnavigation.forward…Title check ✅ Passed The title is concise, specific, and accurately describes the primary fix for Ctrl+Plus zoom behavior on Spanish and German keyboard layouts. Description check ✅ Passed The description includes complete Problem, Change, Scope and approval, and Verification sections. It explains the regression, implementation, linked issues, focused tests, manual Linux verification, p… ✨ Finishing Touches
🧪 Generate unit tests (beta)
- Create a new PR
- Autopilot · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
Comment `@coderabbitai help` to get the list of available commands.coderabbitai[bot](GitHub profile, opens in a new tab) approved these changes
juliusmarminge added labelsmacroscope-review
macroscopeapp[bot](GitHub profile, opens in a new tab) approved these changes
Hi! Just a friendly reminder about this PR.
I'm over 40 and rely on zooming the UI to read comfortably. I follow the nightly builds, which is where I run into this, so this one would make a real difference for me.
No rush, and thanks for all the work on T3 Code!
juliusmarminge assignedjuliusmarminge
Taking over this one. I’ll reduce the tests to the useful coverage, update the implementation against current main, and verify it before publishing the changes.
Also happens on macOS: Cmd +
+does not zoom in with the Spanish - ISO layout, where+sits on the key US layouts label].- T3 Code (Beta) 0.1.0 desktop, Electron 44.4.5
- macOS 26.4, Apple Silicon
This adds a macOS data point to the "Not checked: macOS" line in the description. I haven't tested this branch.
juliusmarminge closed this
Sign in to join this conversation.
macroscopeapp[bot](GitHub profile, opens in a new tab) reviewed