我想让Sweet Alert弹出窗口的动画速度慢一点。我试图在任何地方搜索,文档,网络,论坛,但没有那么多成功。如何降低动画速度?
原始的甜蜜警报插件不受支持,我建议你使用SweetAlert2插件。
迁移很简单,这是迁移指南:Migration from SweetAlert to SweetAlert2
在SweetAlert2中,您可以通过覆盖.swal2-show
类来更改动画速度:
Swal.fire({
title: 'Custom animation speed',
customClass: 'slow-animation'
})
.slow-animation {
animation: swal2-show 3s !important;
}
<script src="https://cdn.jsdelivr.net/npm/sweetalert2@8"></script>
您是否尝试在quelltext中搜索以下代码:
animation: animateSuccessTip 0.75s;
我认为您应该尝试更改具有此“s”(我猜的是秒)后缀的值。只需将其更改为高值并检查其是否正确。