Open andi-b opened 3 years ago
The following piece of code works for me.
styler: function (row) {
if(row.selected) {
$([data-key=${row._key.trim()}]
).prop("checked", true); // Mark checked for selected checkbox value
$([data-key=${row._key.trim()}]
).closest("li").addClass("selected"); // NOT mandatory. Added class to make consistency while rendering dropdownlist
} else {
$([data-key=${row._key.trim()}]
).prop("checked", false); // Unmark checked for selected checkbox value
$([data-key=${row._key.trim()}]
).closest("li").removeClass("selected");
}
},
It would be good that if there's already an option selected that when you open the dropdown, the selected value is visible without scrolling. I've been able to do this when there are less than 200 options, but not if the selected option is in the hidden group over 200 options.