Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CSS auto dark mode? #305

Open
trentbuck opened this issue Jan 9, 2023 · 7 comments
Open

CSS auto dark mode? #305

trentbuck opened this issue Jan 9, 2023 · 7 comments

Comments

@trentbuck
Copy link

Static CSS can automatically switch to "dark theme".
It would be nice if klaus had this (github does since about 2021).
Looking at https://github.com/jonashaag/klaus/blob/master/klaus/static/klaus.css I'm not sure if you can just leave the colors where they are and shove an "if dark then color1 else color2" around each one...

https://caniuse.com/prefers-color-scheme
https://css-tricks.com/dark-modes-with-css/
https://developer.mozilla.org/en-US/docs/Web/CSS/@media/prefers-color-scheme

@jonashaag
Copy link
Owner

jonashaag commented Jan 9, 2023

Great idea. Do you want to come up with an initial version?

The CSS desperately needs a remake so if you feel like it, feel free to create an entirely new one. Feel free to use a CSS framework like Tailwind.

@trentbuck
Copy link
Author

trentbuck commented Jan 9, 2023 via email

@jonashaag
Copy link
Owner

not encouraging users to keep using

Anything in particular that can be improved in klaus?

@trentbuck
Copy link
Author

trentbuck commented Jan 9, 2023 via email

@jonashaag
Copy link
Owner

Thanks for the feedback! Yeah CSS remake is long overdue.

@trentbuck
Copy link
Author

trentbuck commented Jan 10, 2023 via email

@trentbuck
Copy link
Author

Let me try those attachments again, but inside a browser.
Screenshot from 2023-01-10 20-23-05
Screenshot from 2023-01-10 20-21-12

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants