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
I have a very big table with a bunch of selects
These selects are huge with more than 150 options, so, to avoid my browser to freeze I fill these selects dynamically.
The Idea is fill these selects when the chosen:showing_dropdown event is fired
The issue is that when I go from one select to another using the tab key, I try to paste my clipboard content directly and I need to paste twice in order to paste my content inside the input.
The first paste command(CTRL+V) only open the dropdown, the input keeps empty.
If I remove my dynamically filling, this issue does not happen anymore
When chosen:updated is triggered, Chosen goes through the entire process of rebuilding itself. One of the steps that gets taken is calling show_search_field_default which empties out the search field. So your paste is working, but is getting cleared right away.
I would point out that browsers are more than capable of handling selects with 150 options in them. No need to get all fancy trying to delay their construction!
Yeah, about the browser: the problem is that my screen does not have 1 or 2 selects, I have more than 100-200-300, thats why I delay the construction filling dynamically, because if I do not do that my browser freezes and it does not matter how much system memory I have :(
Ah. You could try building when the Chosen element gets focus (maybe listen on the chosen-single class) instead of when the dropdown is showing. Beyond that, I might actually start working within the Chosen source directly instead of bolting functionality on.
I have a very big table with a bunch of selects
These selects are huge with more than 150 options, so, to avoid my browser to freeze I fill these selects dynamically.
The Idea is fill these selects when the chosen:showing_dropdown event is fired
The issue is that when I go from one select to another using the tab key, I try to paste my clipboard content directly and I need to paste twice in order to paste my content inside the input.
The first paste command(CTRL+V) only open the dropdown, the input keeps empty.
If I remove my dynamically filling, this issue does not happen anymore
Here it is a bug reproduction.
http://jsfiddle.net/fzGLA/
Is there any way to avoid this behavior or it is a bug?
Thanks
The text was updated successfully, but these errors were encountered: