pretext
pretext copied to clipboard
Move existing dark-mode css to work with css media query
This creates duplicates of css rules targeting .pretext[data-atmosphere="dark"]
and moves them to @media (prefers-color-scheme: dark)
Very hacky preview of what existing dark mode rules do.
Wild. Beta up at https://pretextbook.org/beta/html-dark-2024-01-26
Is this ready to merge? Would it be ready with more work? Should the copy be a move so we don't need to keep two versions in sync? How does this relate to #2113? So many questions.
This is ready to close without merging. This was a way to share what the existing dark mode code did and not a serious attempt to implement a long-term improvement.
But keep issue https://github.com/PreTeXtBook/pretext/issues/2113 open.
A real solution should wait until CSS bundling is in place. Oscar and I had a recent discussion about simplifying color support in general as part of that move. Fixing dark mode would dovetail nicely with that. Will start a discussion about colors in general once we reach that point.