From 669082dbe065ae762e2be0effea7a23a1c53ad21 Mon Sep 17 00:00:00 2001 From: Bennet Bo Fenner Date: Mon, 3 Mar 2025 17:02:25 +0100 Subject: [PATCH] assistant2: Fix keyboard navigation issues when a picker is open (#25928) This fixes: - Bug: Using "up" in model selector triggers assistant2::FocusUp not menu::SelectPrev - Bug: Pressing arrow up/down in the model selector opened in the inline assistant doesn't work - Bug: Dismissing the model selector with Esc is not working - Bug: Dismissing context pickers with Esc no longer working Release Notes: - N/A --- assets/keymaps/default-linux.json | 3 +++ assets/keymaps/default-macos.json | 3 +++ 2 files changed, 6 insertions(+) diff --git a/assets/keymaps/default-linux.json b/assets/keymaps/default-linux.json index e8528fe86a..91b236f536 100644 --- a/assets/keymaps/default-linux.json +++ b/assets/keymaps/default-linux.json @@ -779,6 +779,9 @@ { "context": "Picker > Editor", "bindings": { + "escape": "menu::Cancel", + "up": "menu::SelectPrevious", + "down": "menu::SelectNext", "tab": "picker::ConfirmCompletion", "alt-enter": ["picker::ConfirmInput", { "secondary": false }] } diff --git a/assets/keymaps/default-macos.json b/assets/keymaps/default-macos.json index 7edaddf8cb..7313100500 100644 --- a/assets/keymaps/default-macos.json +++ b/assets/keymaps/default-macos.json @@ -798,6 +798,9 @@ "context": "Picker > Editor", "use_key_equivalents": true, "bindings": { + "escape": "menu::Cancel", + "up": "menu::SelectPrevious", + "down": "menu::SelectNext", "tab": "picker::ConfirmCompletion", "alt-enter": ["picker::ConfirmInput", { "secondary": false }], "cmd-alt-enter": ["picker::ConfirmInput", { "secondary": true }]