Conversation
Dropdowns for stats. Very messy css for calendar. About page
This is a pre-emptive merge to make merging with main easier.
There was a problem hiding this comment.
this can throw in storage-restricted contexts and also toggles arbitrary class names if stored is unexpected. i think wrapping in try/catch and only apply 'dark' when stored === 'dark', then otherwise explicitly remove 'dark' for light/default
There was a problem hiding this comment.
for the
document.documentElement.classList.toggle(...) localStorage.setItem(...)
lines (20, 24, etc),
reducers should stay pure and this side-effect code can throw during dispatch (localStorage failures). imo should move DOM/storage writes to middleware/listener/effect, or at minimum guard writes with try/catch so toggle dispatch can't crash
There was a problem hiding this comment.
What was I doing....
It should be fixed here: 5710eb8
| > | ||
| ABOUT | ||
| </Link> | ||
| <div |
There was a problem hiding this comment.
interactive control is a div, so it's not keyboard accesible by default
could use semantic <button type="button"> with aria-label (e.g. "Toggle theme") and preserve current styling via CSS
Description
This PR adds support for light mode by:
variables.css.themeNoFlashScript.themeSlice.ts. This is intentionally done differently than our current way of implementing Redux to serve as an example for our possible migration to RTK in the future: Update to RTK #654Added color changes and .css variables to light mode branch
change colors later