-
-
Notifications
You must be signed in to change notification settings - Fork 14
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
Add support for additional theme values #66
Comments
Hey @wesharper, this is something we will consider before publishing a v1 of the package. The only thing I foresee is that we will still need to have light/dark/system as the primaries since those are relevant to native scrollbars and UI elements using the |
Could be interesting to enforce setting a color-scheme for custom theme values with some good jsdoc comments and docs about why it's necessary |
But let's say I have a |
are you suggesting that:
if 2), then we would have to figure out:
I wonder if it would make sense to separate mode (as in dark mode, light mode, system mode) vs. theme (as in default, dracula...) and allow mode + theme to be managed by mode-watcher. [1] this might even be needed if we want to support tracking system preferences with a non-default theme active. right? I also wonder how much should be configured by |
@ollema, the scope would be limited to simply applying a data attribute at the same time we apply the See how DaisyUI handles themes: https://daisyui.com/docs/themes/ The themes have a dark and a light variant, which is based on the system in our case based on mode-watcher, it's just a matter of applying such theme early enough to prevent FOUC and storing it in local storage. This won't replace the three modes - I was hesitant at first until i realized you basically have to reinvent mode-watcher to add this functionality to your app if the user is able to select from a list of different themes (like DaisyUI allows). As for implementation, we'd likely just expose a |
ah, thanks for the clarification. I think I got confused by:
in the original post. your |
https://x.com/adamwathan/status/1770979061721919598?s=20 Here's more reasoning to do so :) |
Reading thru the comments here. The ask is indeed to support additional themes, with the caveat that those themes can and should also specify what their mode should be for browser-rendered UI elements that need to coexist. |
This indeed would be very much appreciated if it could land in the lib.
@huntabyte, @ollema is it safe to assume that this might land some time after Tailwind CSS V.4 lands? No pressure from me, just want to grab some context. 🙂 |
Any way we can prioritize this one? In addition to |
Describe the feature in detail (code, mocks, or screenshots encouraged)
'light', 'dark', and 'system' are great, but I'm building a fun hobby project where I want to enable other themes like 'unicorn-puke'. It would be great if I could update the expected type and use
setMode
to set it to any of the types in that union.What type of pull request would this be?
New Feature
Provide relevant links or additional information.
No response
The text was updated successfully, but these errors were encountered: