PSWriteHTML
PSWriteHTML copied to clipboard
Dark mode support
Some possible solutions:
- https://dev.to/blacksonic/add-dark-mode-to-your-site-with-this-short-css-trick-1g7b
- I would like to have automatic dark mode switch available
- I would like to have manual switch available
This looks easy, but there's a lot of things to make sure things run as required. Tables/Diagrams/etc.
Not easy, unless I miss something obvious.
I'd be interested in seeing this. what about creating a new type of child element for navigation that would be for create a new nav menu root and items (that would typically be aligned to the right?). That new type of nav would have these special nodes that are parameterized to pass a css class to be applied to the body tag, a "name", and maybe even an icon. These could be under functions titled something like "nav theme nodes". The main nav link for this theme system would require providing the path to a css file that has all the styles associated with these themes (or maybe each node has its own?) Each nav link when clicked would apply the css styles from the provided files to the end of the body to embed those styles (and being at the end, they would override most styles). The nodes are essentially just using jQuery to swap which theme class is applied to the body which essentially give you a theming system. Would love to provide a pull request for this myself but currently buried in a report development and tight schedules. Would love to see this though!
So in most cases it will be <body data-bs-theme="light">
which is supported by many libraries, few of them it's just matter of fixing background, but it requires testing and slowly adding things. For others it will require some more work. I am currently busy with my other projects so this isn't a priority for me. Unless someone makes a PR starter I don't think I will pick it up.