mirror of
https://github.com/Choices-js/Choices.git
synced 2024-06-04 23:12:17 +02:00
Resolve issue with Firefox not selecting choices via enter key
This commit is contained in:
parent
bd44abb629
commit
7e4347b183
|
@ -1229,7 +1229,6 @@ class Choices {
|
||||||
}
|
}
|
||||||
|
|
||||||
if (hasActiveDropdown) {
|
if (hasActiveDropdown) {
|
||||||
event.preventDefault();
|
|
||||||
const highlighted = this.dropdown.getChild(
|
const highlighted = this.dropdown.getChild(
|
||||||
`.${this.config.classNames.highlightedState}`,
|
`.${this.config.classNames.highlightedState}`,
|
||||||
);
|
);
|
||||||
|
@ -1242,6 +1241,8 @@ class Choices {
|
||||||
}
|
}
|
||||||
this._handleChoiceAction(activeItems, highlighted);
|
this._handleChoiceAction(activeItems, highlighted);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
event.preventDefault();
|
||||||
} else if (this._isSelectOneElement) {
|
} else if (this._isSelectOneElement) {
|
||||||
// Open single select dropdown if it's not active
|
// Open single select dropdown if it's not active
|
||||||
this.showDropdown();
|
this.showDropdown();
|
||||||
|
|
Loading…
Reference in a new issue