dropdown_list_widget: Properly bind focus to dropdown elements.

Previously, the focus event tends to skip the first
element within the dropdown list when the user presses
the down arrow.
Added a stopPropogation event for keydown handler within
dropdown_list_widget which propoerly binds the focus
event to the dropdown list items.
This commit is contained in:
aryanshridhar
2021-05-13 17:16:03 +05:30
committed by Tim Abbott
parent 454eced466
commit 352acdcc36

View File

@@ -133,6 +133,7 @@ export const DropdownListWidget = function ({
return;
}
e.preventDefault();
e.stopPropagation();
const custom_event = new $.Event("keydown.dropdown.data-api", {
keyCode: e.keyCode,
which: e.keyCode,