From 3cc03f5e58908cf3fb6b3f6f418213a588983c36 Mon Sep 17 00:00:00 2001 From: morethanwords Date: Wed, 24 Nov 2021 17:04:45 +0400 Subject: [PATCH] Autocomplete suggestion by Tab --- src/helpers/dom/attachListNavigation.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/helpers/dom/attachListNavigation.ts b/src/helpers/dom/attachListNavigation.ts index 7509a1e8..0c7a21ae 100644 --- a/src/helpers/dom/attachListNavigation.ts +++ b/src/helpers/dom/attachListNavigation.ts @@ -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()); }