diff --git a/.DS_Store b/.DS_Store index 63ee67a..7aaf77d 100644 Binary files a/.DS_Store and b/.DS_Store differ diff --git a/assets/.DS_Store b/assets/.DS_Store index 0a87740..82aed9f 100644 Binary files a/assets/.DS_Store and b/assets/.DS_Store differ diff --git a/assets/js/main.js b/assets/js/main.js index 37e111b..5aef9e4 100644 --- a/assets/js/main.js +++ b/assets/js/main.js @@ -10,18 +10,25 @@ document.addEventListener('DOMContentLoaded', () => { /** * Preloader */ + // const preloader = document.querySelector('#preloader'); + // if (preloader) { + // window.addEventListener('load', () => { + // setTimeout(() => { + // preloader.classList.add('loaded'); + // }, 1000); + // setTimeout(() => { + // preloader.remove(); + // }, 2000); + // }); + // } const preloader = document.querySelector('#preloader'); if (preloader) { - window.addEventListener('load', () => { - setTimeout(() => { - preloader.classList.add('loaded'); - }, 1000); - setTimeout(() => { - preloader.remove(); - }, 2000); + window.addEventListener('DOMContentLoaded', () => { + // Immediately remove the preloader + preloader.classList.add('loaded'); + preloader.remove(); }); } - /** * Mobile nav toggle */ diff --git a/index.html b/index.html index 01c11d8..7a20a5a 100644 --- a/index.html +++ b/index.html @@ -367,9 +367,9 @@