When I wrote An Accessible Dark Mode Toggle in React back in 2021, @grahamthedev suggested I implement a prefers-color-scheme check in my theme setter. I finally got around to it.
https://dev.to/abbeyperini/dark-mode-toggle-and-prefers-color-scheme-4f3m