Question: set aria-checked on onChange event
karenpayneoregon opened this issue · 0 comments
karenpayneoregon commented
Is there a way to toggle the current option aria-checked
attribute in onChange event?
onChange: function (option, checked) {
var toppings = $('#select-tops-options option:selected');
var selected = [];
$(toppings).each(function (index, item) {
selected.push([$(this).val()]);
console.log([$(this).val()]);
});
}
I tried the following which a screen reader does not pick up on and honestly feels wrong.
$(option[0])[0].ariaChecked = checked;
Source file on GitHub