mirror of https://github.com/4xmen/xshop.git
You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
28 lines
530 B
JavaScript
28 lines
530 B
JavaScript
let isWinLoaded = false;
|
|
window.addEventListener('load',function () {
|
|
|
|
if (!isWinLoaded){
|
|
forceLoad();
|
|
isWinLoaded = true;
|
|
}
|
|
});
|
|
|
|
|
|
setTimeout(function () {
|
|
if (!isWinLoaded){
|
|
forceLoad();
|
|
isWinLoaded = true;
|
|
}
|
|
},5000);
|
|
const forceLoad = function () {
|
|
try {
|
|
const preloader = document.querySelector('#panel-preloader');
|
|
preloader.style.height = 0;
|
|
setTimeout( () => {
|
|
preloader.style.display = 'none';
|
|
},500);
|
|
} catch {
|
|
}
|
|
|
|
};
|