aufgrund vieler Anfragen stelle ich eine Theme-Switcher-Komponente vor, die aus meinem Alien Night Theme gekapselt wurde.
Derzeit wechselt das Theme beim Drücken des Buttons in ein Dark-Mode-Theme.
Später könnte ich vielleicht eine Einstellungsseite implementieren, auf der Sie Ihre eigene globale CSS-Klasse definieren können, in die Ihr Theme wechseln soll.
Oder einfach zwischen den ersten beiden Themes hin- und herschalten, die Sie den Benutzern zur Auswahl angeboten haben…
You can let admins select which themes they want to use. We have two different themes and each theme has it own dark mode.
When we click the switch to change light to dark, this component below should have change the logo’s color to light as the opposite. Now it doesn’t work with this switch.
Defining the themes in the settings is possible, but will complicate things. The hamburger menu theme selector is a good working example of how you’d change the theme based on ID.
I had some time tonight, so I worked on modifying the hamburger theme selector to toggle between two themes: Header Theme Toggle. Thanks so much for inspiring this with your theme @B-iggy!
Not necessarily, there are some benefits of switching the CSS rather than switching the entire theme. Everything’s self contained and you don’t need to fully refresh for all the changes to take effect.
Instead of changing the code on your end I think it makes sense to have it next to the search icon per default.
So I pushed this change now. Let me know if it’s fine
Also is there any workaround to add an alternative logo? My current one is not readable on dark bg, hence I want to add a inverted one for the dark mode
My theme has lots of hardcoded colors and only works properly with a light color scheme. Open to fixing this but for now it does not work right in dark mode.
Any thoughts about making the bottom smaller? When using additional component, it takes a lot of space in the header. For example I like the dark mode button in this ghost theme at top right: