1
mirror of https://github.com/jakejarvis/jarv.is.git synced 2025-09-16 16:15:33 -04:00

animated dark mode toggle 🌓

This commit is contained in:
2022-03-07 19:32:43 -05:00
parent 19394c1fb7
commit f5c8a7a21a
8 changed files with 229 additions and 31 deletions

View File

@@ -157,20 +157,6 @@ export const globalStyles = globalCss(
},
},
},
// reduced motion preference:
// https://web.dev/prefers-reduced-motion/#(bonus)-forcing-reduced-motion-on-all-websites
"@media (prefers-reduced-motion: reduce)": {
"*, ::before, ::after": {
animationDelay: "-1ms !important",
animationDuration: "1ms !important",
animationIterationCount: "1 !important",
backgroundAttachment: "initial !important",
scrollBehavior: "auto !important",
transitionDuration: "0s !important",
transitionDelay: "0s !important",
},
},
}
);