32 lines
1.1 KiB
HTML
32 lines
1.1 KiB
HTML
<!DOCTYPE html>
|
||
<html lang="en" xmlns:th="http://www.thymeleaf.org">
|
||
|
||
<!-- loading 页面,todo 这块都可以不要,后面删除,先精简代码,后续考虑组件添加 -->
|
||
<div id="loading-box" onclick="heo.hideLoading()"
|
||
th:fragment="loading-box"
|
||
th:if="${theme.config.other.loadingBox} and not ${#strings.isEmpty(theme.config.other.loadingBoxImg)}">
|
||
<div class="loading-bg">
|
||
<img class="loading-img" th:src="${theme.config.other.loadingBoxImg}">
|
||
</div>
|
||
|
||
<script>
|
||
<!-- 加载动画 -->
|
||
var preloader = {
|
||
endLoading: () => {
|
||
//- document.body.style.overflow = 'auto';
|
||
document.getElementById('loading-box').classList.add("loaded")
|
||
},
|
||
initLoading: () => {
|
||
//- document.body.style.overflow = '';
|
||
document.getElementById('loading-box').classList.remove("loaded")
|
||
}
|
||
}
|
||
window.addEventListener('load', preloader.endLoading())
|
||
setTimeout(function () {
|
||
preloader.endLoading();
|
||
}, 3000)
|
||
</script>
|
||
|
||
</div>
|
||
|
||
</html> |