You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If you add multiple autocomplete components on a page, their "onOptionClick" handlers are somehow interdependent
Here is an example (I just select options from 3 autocomplete in a row):
Codewise: in autocomplete.js there is the following code:
let dropdownOptions = $.extend(
Autocomplete.defaults.dropdownOptions,
this.options.dropdownOptions
);
So on every init we extend default options with new dropdown options. I.e. we modify defaults every time we create a new autocomplete.
Bug description
If you add multiple autocomplete components on a page, their "onOptionClick" handlers are somehow interdependent
Here is an example (I just select options from 3 autocomplete in a row):
Codewise: in
autocomplete.js
there is the following code:So on every init we extend default options with new dropdown options. I.e. we modify defaults every time we create a new autocomplete.
This was introduced in #60
Steps to Reproduce
Create 3 autocomplete, like this:
And then initialize them:
Then just select options in each autocomplete one by one
As a result, you will see the behavior from the GIF above
The text was updated successfully, but these errors were encountered: