DualListBox icon indicating copy to clipboard operation
DualListBox copied to clipboard

Plugin does not work with the latest browser versions

Open maxfrz21 opened this issue 5 years ago • 2 comments

Hi All, please help me, with the last versions of Chrome and Firefox, this plugin doesn't work fine . You can test it from the official DEMO page http://geodan.github.io/duallistbox/sample-100.html The problem is that doesn't load fine the two list when shift element.

Thanks! Max

maxfrz21 avatar Apr 28 '20 08:04 maxfrz21

Confirm. We have the same issue on the latest chrome version.

patriotyk avatar May 04 '20 14:05 patriotyk

I've solved by rewriting SortOptions function, here is my code: $.fn.sortOptions = function() { return this.each(function() { var opts_list = $(this).find('option'); opts_list.sort(function(a, b) { return $(a).text() > $(b).text() ? 1 : -1; }); var html = []; opts_list.each( function(){ html.push('<option title="'+$(this).text()+'" value="' + $(this).val() + '">' +$(this).text()+ '</option>'); }); $(this).html(''); $(this).append(html.join('')); }); };

maxfrz21 avatar May 08 '20 20:05 maxfrz21