Merge pull request #3322 from github/koesie10/suggest-box-command-palette

Fix not being able to open command palette in suggest box
This commit is contained in:
Koen Vlaswinkel 2024-02-07 14:36:19 +01:00 коммит произвёл GitHub
Родитель 57faebd5b9 fdb4d42bf3
Коммит f2eea4025a
Не найден ключ, соответствующий данной подписи
Идентификатор ключа GPG: B5690EEEBB952194
1 изменённых файлов: 6 добавлений и 0 удалений

Просмотреть файл

@ -243,6 +243,12 @@ export const SuggestBox = <
context={context}
initialFocus={-1}
visuallyHiddenDismiss
// The default for returnFocus is true, but this doesn't work when opening
// the command palette in a VS Code webview. The focus is returned to the
// input element, but this closes the command palette immediately after opening
// it. By setting returnFocus to false, the focus is not immediately given to
// the input element, so the command palette stays open.
returnFocus={false}
>
<ListContainer
{...getFloatingProps({