no override of arrow up/down actions in toolbar search fields

This commit is contained in:
Bogdan Abaev 2023-11-15 16:20:18 -05:00 committed by Dan Stillman
parent f8a6b82c63
commit a7fe2130ce

View file

@ -174,10 +174,11 @@ var ZoteroPane = new function()
if (isMenu && ['ArrowUp', 'ArrowDown'].includes(key)) {
return;
}
if (verticalArrowIsTab && key == 'ArrowUp') {
let onInput = event.originalTarget.tagName.toLowerCase() == "input";
if (verticalArrowIsTab && key == 'ArrowUp' && !onInput) {
key = 'ShiftTab';
}
else if (verticalArrowIsTab && key == 'ArrowDown') {
else if (verticalArrowIsTab && key == 'ArrowDown' && !onInput) {
key = 'Tab';
}
let focusFunction = actionsMap[event.target.id]?.[key];