Browse Source

Autocomplete suggestion by Tab

master
morethanwords 3 years ago
parent
commit
3cc03f5e58
  1. 2
      src/helpers/dom/attachListNavigation.ts

2
src/helpers/dom/attachListNavigation.ts

@ -89,7 +89,7 @@ export default function attachListNavigation({list, type, onSelect, once, waitFo @@ -89,7 +89,7 @@ export default function attachListNavigation({list, type, onSelect, once, waitFo
let onKeyDown = (e: KeyboardEvent) => {
if(!keyNames.has(e.key as any)) {
if(e.key === 'Enter') {
if(e.key === 'Enter' || (type !== 'xy' && e.key === 'Tab')) {
cancelEvent(e);
fireSelect(getCurrentTarget());
}

Loading…
Cancel
Save