-
-
Notifications
You must be signed in to change notification settings - Fork 6.2k
Closed
Description
Upgrading from 4.0.5 to 4.0.7 and ran into an issue where this code no longer works:
$(document).ready(function() {
$("#select1").select2().select2("focus");
$("select").on("select2:close", function (e) {
$("#checkbox1").focus();
});
});
The goal is to auto-select the select2 on page load, then after the select2 is closed, focus on the next element. With 4.0.5 it works, with 4.0.7, the select2 element remains focused.
Example w/4.0.5 which works:
https://jsfiddle.net/bvL2wejz/
Example w/4.0.7 which doesn't work:
https://jsfiddle.net/4b0zy1hd/