From 2677e4cbc97bb9dba4fd1b1f05bb186d6309aa86 Mon Sep 17 00:00:00 2001 From: Claude Date: Wed, 9 Sep 2026 14:24:47 +0000 Subject: [PATCH] docs(vscode-extension): stop the keybinding example from stealing the Command Palette (objectui#8424) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The worked `keybindings.json` example bound `ctrl+shift+p` — VS Code's default for `workbench.action.showCommands` — to `objectui.preview` under `when: editorLangId == json`. A user entry overrides the default for that chord, and the `when` clause only narrows where the entry applies, so a reader who copied the example lost the Command Palette in exactly the file type where an ObjectUI schema is open — and where this same page tells them, twice, to press `Ctrl+Shift+P` to reach it. Swap the chord for an obviously-illustrative unbound one, and say in prose that it is a stand-in rather than a proposal, that the reader should pick their own, and that whatever they pick overrides VS Code's default for that chord. The `when` clause is kept deliberately: it is what currently limits the example's blast radius to JSON editors. Removing it would widen the override to every context. Co-Authored-By: Claude Opus 5 Claude-Session: https://claude.ai/code/session_01611D6ZaRaMmwTNQmSbk8MH --- content/docs/utilities/vscode-extension.mdx | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/content/docs/utilities/vscode-extension.mdx b/content/docs/utilities/vscode-extension.mdx index 9f4c34f41b..926001e66e 100644 --- a/content/docs/utilities/vscode-extension.mdx +++ b/content/docs/utilities/vscode-extension.mdx @@ -374,12 +374,21 @@ command by its name, and assign a chord. To write the binding by hand instead, o ```json { - "key": "ctrl+shift+p", + "key": "ctrl+alt+shift+f19", "command": "objectui.preview", "when": "editorLangId == json" } ``` +The `key` above is a stand-in, not a proposal — a deliberately far-fetched chord +that nothing binds, there to show the shape of an entry. Pick your own, and pick one +you are not already using: an entry in your `keybindings.json` overrides VS Code's +default for that chord, and the `when` clause only narrows *where* your entry +applies (here, JSON editors) — it does not decide whether your entry wins. Binding +`ctrl+shift+p`, for instance, would take the Command Palette away from you in JSON +files, which is where your schemas are open and where this page keeps sending you +for these commands. + Every command the extension contributes, with the id to bind: | Command | Command id |