-
-
Notifications
You must be signed in to change notification settings - Fork 344
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
Tailwind checkboxes are solid white in dark mode #1199
Comments
Good idea with refactoring into a blade, however bulk actions changes slightly in the next version, as it moves to AlpineJS approach. I'm currently reviewing more of the blades to get more refactored, and removing some of the existing theme behaviour where the code is repeated, and using conditional classes. Expect the custom blade for a checkbox to be in the version after this imminent release. |
If you can test using the develop branch and let me know if its still an issue or not, then that'd be handy! |
Aha, it's still happening for me on the
Which picks up on the However if you use
There is an open tailwind forms issue for it here.
End result in dark system and class mode (I'm focussed on the first checkbox here): |
Also nice work with the Alpine checkboxes on the |
No problem, more to come imminently in AlpineJS migrations as it really smooths the experience. |
Tweaked the labels so that I've captured the enhancement request with the blade for checkboxes. |
Just to update, and be realistic! In terms of refactoring checkboxes into a blade. This is on the roadmap, but not in an immediate release. It may not even be present until 3.x, as I've recently been reviewing the blades as a whole, and migrating to a smoother experience is such a large piece of work, that it's likely to make it into 3.x instead. I will however look closely at the form inputs, and see if I can refactor them as an interim measure |
Hey friends, bumped into this issue as well and saw that it was logged here. I updated to 2.14 but still have the white on white checkboxes. Is that something that will be released later? I tried to find it in the CHANGELOG but that mentioned "Bulk Actions (alpine.js)". Just checking. Thanks to both for picking this up! |
@iamgoodbytes it might be a while before it's fixed but a quick fix in the meantime is to set dark mode manually by adding module.exports = {
darkMode: 'class',
// ...
} And adding a <html lang="en" class="dark"> More info here: https://tailwindcss.com/docs/dark-mode#toggling-dark-mode-manually |
Thanks @bengs - that does the trick! |
I'll make a note to update the docs to reference dark mode, thought it was in there already to be honest. |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
Checkbox classes in the Tailwind views contain both
text-indigo-500
anddark:text-white
.This causes checkboxes to display like this when checked in dark mode:
.
Solution: remove all
dark:text-white
classes from checkboxes:.
Also the checkboxes are repeated a little in the code, refactoring them to a blade component might be a good thing to do, so they're utilised similarly to this:
Then if people want to change look of the checkboxes eg the primary
*-indigo-*
colour classes they only need to publish & modify classes insideinputs/checkbox.blade.php
rather than components inside multiple folders liketable/td
,table/th
tools
etc.The text was updated successfully, but these errors were encountered: