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 e8528fe86ab477f3ab81e7b4a33a466812adee3c..91b236f5367b362d6aa1ed7c5c52a7e1f5101f64 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 7edaddf8cbaca565eb70e1e79cf49176e874416f..7313100500695029a2b42dc8616a9c4dd3836e04 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 }]