我在jquery上创建了启动画面它在加载页面上工作正常。当我注销页面时。再次重复同样的事情。我想在注销时删除启动动画我该怎么做?
document.addEventListener('DOMContentLoaded', () => {
document.querySelector('#splash').addEventListener('transitionend', (event) => {
event.target.remove();
});
document.querySelector('.content').addEventListener('transitionend', (event) => {
event.target.remove();
});
requestAnimationFrame(() => {
document.querySelector('#splash').classList.add('slide-out-fwd-center');
$('#splash').delay(3000).fadeOut(500, function() {
$('#splash').hide();
$('.content').css({
'display': 'block',
'animation': 'popup 0.5s ease-in-out 1'
});
});
});
});
Here is logout button which i am using .content is linking to login page
<a href="login.php" class="innerrestart" id="stop">Logout</a>