From cdbfd82c6425843d0b12f380886bd92c0049738b Mon Sep 17 00:00:00 2001 From: Sergii Demianchuk Date: Tue, 21 Jul 2026 23:13:52 -0400 Subject: [PATCH] fix(ai): bind Shift+Cmd+I to Focus Chat (was only Ctrl+Cmd+I) The chat-focus command worked from the Command Palette but Shift+Cmd+I did nothing: the only contributed binding was ctrl+cmd+i, and Shift+Cmd+I is claimed in the Code-OSS base by the built-in VS Code chat's "Open Chat (Agent)" action (chatActions.ts:593, gated on config.chat.agent.enabled). LevelCode ships its own chat and doesn't enable that, so the key fired a dead/stripped built-in action instead of LevelCode's chat. Added an explicit shift+cmd+i -> levelcode.ai.focus binding. Bundled-extension keybindings register at weight >= BuiltinExtension (300), above the base action's WorkbenchContrib (200), so the explicit binding wins (confirmed in keybindingService.ts:633-635). Mirrors VS Code's own chat convention across platforms (mac shift+cmd+i, win ctrl+shift+i, linux ctrl+alt+shift+i to dodge Dev Tools), and keeps the existing ctrl+cmd+i so no one loses their current shortcut. Also closes a latent gap: the old `"key": "ctrl+cmd+i"` used `cmd`, invalid on Windows/Linux, so those platforms had no chat shortcut at all. Verified: package.json is valid and the bindings resolve to shift+cmd+i on mac. The keypress itself needs a build to smoke-test (no editor host here), but the weight-override mechanism is confirmed in the Code-OSS source. Co-Authored-By: Claude Opus 4.8 --- extensions/levelcode-ai/package.json | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/extensions/levelcode-ai/package.json b/extensions/levelcode-ai/package.json index c5f6c8e..866365b 100644 --- a/extensions/levelcode-ai/package.json +++ b/extensions/levelcode-ai/package.json @@ -253,6 +253,12 @@ ] }, "keybindings": [ + { + "command": "levelcode.ai.focus", + "key": "ctrl+shift+i", + "mac": "shift+cmd+i", + "linux": "ctrl+alt+shift+i" + }, { "command": "levelcode.ai.focus", "key": "ctrl+cmd+i"