JQUERY UI对话模式 - 有没有办法让OVERLAY Div Persist?或设置使用哪个Div?

时间:2021-10-05 20:28:23

The reason I want this is so that when the overlay shows a WHITE Background, I can add "webkit-transition-duration" property to allow the white background to nicely fade-in and out using the GPU.

我想要这个的原因是当叠加显示白色背景时,我可以添加“webkit-transition-duration”属性以允许白色背景使用GPU很好地淡入和淡出。

But problem here is that JQUERY seems to remove/add the overlay div every time the dialog is run.

但问题是,每次运行对话框时,JQUERY似乎都会删除/添加overlay div。

Any ideas?

有任何想法吗?

1 个解决方案

#1


1  

Sure do not make the dialog modal and create the overlay yourself

当然不要让对话模态并自己创建叠加

set the option modal: false;

设置选项modal:false;

$(selector).dialog({
  modal: false
  open: function () {
     //create your own overlay div here.
  },
  close: function () {
     // remove your overlay div here.
  }
  //other options as needed
  });

now create the overlay div yourself.

现在自己创建叠加div。

#1


1  

Sure do not make the dialog modal and create the overlay yourself

当然不要让对话模态并自己创建叠加

set the option modal: false;

设置选项modal:false;

$(selector).dialog({
  modal: false
  open: function () {
     //create your own overlay div here.
  },
  close: function () {
     // remove your overlay div here.
  }
  //other options as needed
  });

now create the overlay div yourself.

现在自己创建叠加div。