remove focus from disabled elements inside the modal

This commit is contained in:
daria 2024-09-05 13:38:29 +03:00
parent 09067da341
commit 7eecb1032f

View File

@ -2513,7 +2513,10 @@ define([
var next = function () {
selected = ++selected % types.length;
$container.find('.cp-icons-element-selected').removeClass('cp-icons-element-selected');
$container.find('#cp-newpad-icons-'+selected).addClass('cp-icons-element-selected');
let element = $container.find('#cp-newpad-icons-'+selected).addClass('cp-icons-element-selected');
if (element.hasClass('cp-app-disabled')) {
next();
}
};
$modal.off('keydown');