refactor(frontend): replace toast system with zibll notyf
This commit is contained in:
1 parent
fb11a7ed0c
commit
86614c4905
33 files changed
+603
-802
No files matched your search
@@ -382,11 +382,7 @@
|
||||
updateNavUser(data.user);
|
||||
}
|
||||
|
||||
if (window.aksrt && aksrt.notyf) {
|
||||
aksrt.notyf(data.message || '登录成功', 'success');
|
||||
} else if (typeof window.aksrtToast === 'function') {
|
||||
window.aksrtToast(data.message || '登录成功', 'success');
|
||||
}
|
||||
notyf(data.message || '登录成功', 'success');
|
||||
|
||||
var redirect = modal.dataset.redirect || data.redirect;
|
||||
if (redirect && redirect !== window.location.href) {
|
||||
@@ -589,7 +585,7 @@
|
||||
e.preventDefault();
|
||||
e.stopImmediatePropagation();
|
||||
agree.closest('label, .aksrt-modal-auth__agreement').classList.add('ani', 'shake');
|
||||
if (window.aksrt && aksrt.notyf) aksrt.notyf('请先同意用户协议', 'warning');
|
||||
notyf('请先同意用户协议', 'warning');
|
||||
setTimeout(function () {
|
||||
agree.closest('label, .aksrt-modal-auth__agreement').classList.remove('ani', 'shake');
|
||||
}, 400);
|
||||
|
||||
Reference in new issue
Block a user