fix init of seasonals
This commit is contained in:
@ -114,7 +114,7 @@ function launchFirework() {
|
||||
fireworkContainer.className = "fireworks";
|
||||
fireworkContainer.setAttribute("aria-hidden", "true");
|
||||
document.body.appendChild(fireworkContainer);
|
||||
}
|
||||
}
|
||||
|
||||
// Random horizontal position
|
||||
const x = Math.random() * window.innerWidth; // Any value across the entire width
|
||||
@ -152,8 +152,6 @@ function startFireworks() {
|
||||
}
|
||||
|
||||
// Initialize fireworks and add random fireworks after the DOM is loaded
|
||||
document.addEventListener('DOMContentLoaded', () => {
|
||||
if (!fireworks) return; // exit if fireworks are disabled
|
||||
startFireworks();
|
||||
toggleFirework();
|
||||
});
|
||||
if (!fireworks) return; // exit if fireworks are disabled
|
||||
startFireworks();
|
||||
toggleFirework();
|
||||
|
Reference in New Issue
Block a user