mirror of
https://github.com/devbridge/jQuery-Autocomplete.git
synced 2024-11-22 04:45:12 +00:00
Update jquery.autocomplete.js
We have to remove class from first suggestion element, not from every first children. Otherwise, in case of a grouped list, first item never lose selected state.
This commit is contained in:
parent
50a7d9b130
commit
b91bc43929
@ -859,7 +859,7 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (that.selectedIndex === 0) {
|
if (that.selectedIndex === 0) {
|
||||||
$(that.suggestionsContainer).children().first().removeClass(that.classes.selected);
|
$(that.suggestionsContainer).children('.' + that.classes.suggestion).first().removeClass(that.classes.selected);
|
||||||
that.selectedIndex = -1;
|
that.selectedIndex = -1;
|
||||||
that.ignoreValueChange = false;
|
that.ignoreValueChange = false;
|
||||||
that.el.val(that.currentValue);
|
that.el.val(that.currentValue);
|
||||||
|
Loading…
Reference in New Issue
Block a user