tab to accept autocomplete

This commit is contained in:
Dax Raad
2025-10-31 20:10:01 -04:00
parent 0300bd404e
commit 5bd4895b15
2 changed files with 7 additions and 0 deletions
@@ -28,7 +28,9 @@ function init() {
return registrations().flatMap((x) => x())
})
let keybinds = true
useKeyboard((evt) => {
if (!keybinds) return
for (const option of options()) {
if (option.keybind && keybind.match(option.keybind, evt)) {
evt.preventDefault()
@@ -47,6 +49,9 @@ function init() {
}
}
},
keybinds(enabled: boolean) {
keybinds = enabled
},
show() {
dialog.replace(() => <DialogCommand options={options()} />)
},