fix loader close
This commit is contained in:
parent
78ebe5012d
commit
3ebef6cc8a
2 changed files with 7 additions and 3 deletions
|
@ -6,6 +6,4 @@ document.onreadystatechange = function () {
|
|||
element.target = "_blank";
|
||||
}
|
||||
});
|
||||
|
||||
document.querySelector(".loader").style.display = "none";
|
||||
}
|
|
@ -8,4 +8,10 @@ div.innerHTML = `<div class="loader-dots">
|
|||
<div class="dots"></div>
|
||||
</div>`;
|
||||
|
||||
document.body.appendChild(div);
|
||||
document.body.appendChild(div);
|
||||
|
||||
document.addEventListener('readystatechange', event => {
|
||||
if (event.target.readyState === "complete") {
|
||||
document.querySelector(".loader").style.display = "none";
|
||||
}
|
||||
});
|
Loading…
Reference in a new issue