Skip to content

[Bug]: macOS option-modified explicit keybindings with letter keys fail at runtime #2261

@tciesek

Description

@tciesek

Before submitting

  • I searched existing issues and did not find a duplicate.
  • I included enough detail to reproduce or investigate the problem.

Area

apps/web

Steps to reproduce

  1. On macOS, set the following keybinding in the keybindings config:
[
  {
    "key": "ctrl+shift+option+cmd+s",
    "command": "terminal.toggle"
  }
]
  1. Open the desktop app to a normal chat view.
  2. Ensure the command palette is closed and the terminal is not focused.
  3. Press Ctrl+Shift+Option+Cmd+S.

Expected behavior

terminal.toggle should fire and the terminal drawer should open or close.

Actual behavior

The keybinding is accepted by config parsing/loading, but pressing the shortcut does not trigger terminal.toggle.

Impact

Major degradation or frequent failure

Version or commit

Desktop app 0.0.20; locally verified against main @ 40b3a800

Environment

macOS, desktop app 0.0.20

Logs or stack traces

No keybinding parse error after updating to this shortcut.

Locally, the issue traced to `apps/web/src/keybindings.ts` runtime matching relying mostly on `KeyboardEvent.key`, with only limited `event.code` aliases.

On macOS, `Option`-modified letter shortcuts can surface a symbol or dead-key value in `event.key` instead of the physical letter key, so a configured `...+s` shortcut can fail to match at runtime.

Workaround

Use a shortcut that avoids option/alt with letter keys, or use a patched build that falls back to the physical key code for option-modified letter shortcuts.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions