Image Select is an extension of Chosen, a jQuery plugin that makes long, unwieldy select boxes much more user-friendly. It provides image support for Single and Multi select HTML tags.
Thanks for a great plugin. I noticed that if you have an option preselected as the page is loaded, the image isn't shown, until you open and close the dropdown.
My solution was to add:
$this.trigger('chosen:hiding_dropdown');
To line 167 of ImageSelect.jquery.js - after the chosen:showing_dropdown event is added.
It didn't work if I had it in the chosen:ready event (unless I delayed it by 1 second (so the other events could load)), but you might be able to find a better home for it.
I probably haven't covered all the bases for testing, but it seems happy enough on both single and multiple selects - hope it helps.
Last thing, in case it matters, your README says v1.1, but the ImageSelect.jquery.js says v1.0.2.
Hi guys,
Thanks for a great plugin. I noticed that if you have an option preselected as the page is loaded, the image isn't shown, until you open and close the dropdown.
My solution was to add:
To line 167 of ImageSelect.jquery.js - after the
chosen:showing_dropdown
event is added.It didn't work if I had it in the
chosen:ready
event (unless I delayed it by 1 second (so the other events could load)), but you might be able to find a better home for it.I probably haven't covered all the bases for testing, but it seems happy enough on both single and multiple selects - hope it helps.
Last thing, in case it matters, your README says v1.1, but the ImageSelect.jquery.js says v1.0.2.
Thanks again.