📜  多模式的背景问题 - Javascript 代码示例

📅  最后修改于: 2022-03-11 15:02:35.503000             🧑  作者: Mango

代码示例1
$(document).on('show.bs.modal', '.modal', function (event) {
  var zIndex = 1040 + (10 * $('.modal:visible').length);
  $(this).css('z-index', zIndex);
  setTimeout(function() {
    $('.modal-backdrop').not('.modal-stack').css('z-index', zIndex - 1).addClass('modal-stack');
  }, 0);
});