index.html 1.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869
  1. <!DOCTYPE html>
  2. <html lang="en">
  3. <head>
  4. <meta charset="UTF-8" />
  5. <link rel="icon" type="image/svg+xml" href="/vite.svg" />
  6. <meta name="viewport" content="width=device-width, initial-scale=1.0" />
  7. <script src="https://4dkk.4dage.com/v4-test/www/viewer/static/lib/vconsole.js"></script>
  8. <title>Getty Show</title>
  9. <style>
  10. body {
  11. background-color: #000;
  12. overflow: hidden;
  13. }
  14. .load-wrap {
  15. display: flex;
  16. flex-direction: column;
  17. height: 100vh;
  18. justify-content: center;
  19. align-items: center;
  20. }
  21. .load-wrap img {
  22. width: 80px;
  23. height: auto;
  24. }
  25. .load-wrap div:nth-child(3) {
  26. align-items: flex-start;
  27. }
  28. .page-loader {
  29. margin-top: 20px;
  30. color: #fff;
  31. line-height: 1.4;
  32. font-size: 1rem;
  33. font-weight: 600;
  34. font-family: sans-serif;
  35. }
  36. </style>
  37. </head>
  38. <body>
  39. <div id="root">
  40. <div class="load-wrap">
  41. <div>
  42. <img src="/src/assets/infinite-spinner.svg" />
  43. </div>
  44. <div>
  45. <div id="page-process" class="page-process">0%</div>
  46. </div>
  47. </div>
  48. </div>
  49. <script type="module" src="/src/main.jsx"></script>
  50. <script>
  51. let loadProgress = 0;
  52. const pageLoader = document.querySelector("#page-process"),
  53. loadAnimation = setInterval(() => {
  54. if (
  55. (loadProgress++,
  56. (pageLoader.innerText = loadProgress + "%"),
  57. 72 === loadProgress)
  58. ) {
  59. clearInterval(loadAnimation);
  60. const e = setInterval(() => {
  61. loadProgress++,
  62. (pageLoader.innerText = loadProgress + "%"),
  63. 83 === loadProgress && clearInterval(e);
  64. }, 86);
  65. }
  66. }, 32);
  67. </script>
  68. </body>
  69. </html>