feat: make colors more stable
All checks were successful
Deploy to GitHub Pages / build_site (push) Successful in 1m47s

This commit is contained in:
max_richter 2024-04-25 04:12:18 +02:00
parent 82f83629c7
commit 41ca2123ba

View File

@ -29,13 +29,16 @@ function updateColors() {
lastStyle = hash; lastStyle = hash;
} }
updateColors();
export const colors = readable(store, set => { export const colors = readable(store, set => {
updateColors(); updateColors();
set(store); set(store);
setTimeout(() => {
updateColors();
set(store);
}, 1000);
window.onload = function () { updateColors(); set(store) }; window.onload = function () { updateColors(); set(store) };
document.body.addEventListener("transitionstart", () => { document.body.addEventListener("transitionstart", () => {