有没有办法提高jQuery中SimpleModal对话框的显示速度?

发布于 2024-07-17 06:39:15 字数 121 浏览 2 评论 0原文

我正在使用 jQuery 中的 SimpleModal 插件。

当我使用动作事件时,模式对话框会缓慢出现。

有什么方法可以提高模式对话框的速度,使其显示得更快吗?

I am using the SimpleModal plug-in in jQuery.

When I use the action event, the modal dialog appears slowly.

Is there any way to increase the speed of the modal dialog, so it appears quicker?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

慢慢从新开始 2024-07-24 06:39:15

尝试模态主页中描述的 onOpen 回调:

data.modal({onOpen: function (dialog) {
  dialog.overlay.fadeIn('slow', function () {
    dialog.container.slideDown('slow', function () {
      dialog.data.fadeIn('slow');
    });
  });
}});

如果这会改变某些内容,请尝试为 fadeIn 函数使用不同的值,而不是缓慢。

Try the onOpen callback described at the modal homepage:

data.modal({onOpen: function (dialog) {
  dialog.overlay.fadeIn('slow', function () {
    dialog.container.slideDown('slow', function () {
      dialog.data.fadeIn('slow');
    });
  });
}});

Try using different values for the fadeIn function instead of slow if this changes something.

电影里的梦 2024-07-24 06:39:15

我有用户抱怨速度。 对于模态来说,即使快速淡入也可能有点慢(取决于谁在使用它)。 我发现似乎有帮助的一件事就是用较小的数字调用 show 函数......

$(content).modal({onOpen: function (dialog) {
    dialog.overlay.show(10, function () {
        dialog.container.show(10, function () {
            dialog.data.show(10);
        });
    });
});

I had users complaining about speed. Even fadeIn fast can be a little slow as well for the modal (depending on who's using it). One thing I found that seems to help is just to call the show function with a low number instead...

$(content).modal({onOpen: function (dialog) {
    dialog.overlay.show(10, function () {
        dialog.container.show(10, function () {
            dialog.data.show(10);
        });
    });
});
~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文