Compare commits

...

1 Commits

Author SHA1 Message Date
Richard Schreiber
b5c1cdd14e Select2: add option to close when clearing selection 2024-02-09 09:40:56 +01:00

View File

@@ -613,6 +613,13 @@ var form_handlers = function (el) {
}, 50);
}
});
if ($s[0].hasAttribute("data-close-on-clear")) {
$s.on("select2:clear", function () {
window.setTimeout(function () {
$s.select2('close');
}, 50);
});
}
});
el.find('[data-model-select2=event]').each(function () {