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

bug: Disabled inputs and buttons have inconsistent styling #2865

Open
TheWilley opened this issue Feb 23, 2024 · 2 comments
Open

bug: Disabled inputs and buttons have inconsistent styling #2865

TheWilley opened this issue Feb 23, 2024 · 2 comments

Comments

@TheWilley
Copy link

TheWilley commented Feb 23, 2024

What version of daisyUI are you using?

v4.7.2

Which browsers are you seeing the problem on?

Chrome

Reproduction URL

https://play.tailwindcss.com/Q8tDkINpUK

Describe your issue

The styling applied to disabled elements seems to be inconsistent between buttons and inputs. For example, when using the dark theme, a disabled button has a light gray tone, while a disabled input has a dark gray tone. From a UXD standpoint, this is confusing as it's unclear what is disabled and what is not. This inconsistency appears to apply to all themes.

Copy link

Thank you @TheWilley for reporting issues. It helps daisyUI a lot 💚
I'll be working on issues one by one. I will help with this one as soon as a I find a solution.
In the meantime providing more details and reproduction links would be helpful.

@TheWilley
Copy link
Author

I think I may have found something after some further research. It seems like the button uses bg-neutral:

@apply bg-neutral text-base-content border-opacity-0 bg-opacity-20 text-opacity-20;

while the input uses border-base-200 and bg-base-200:

@apply border-base-200 bg-base-200 placeholder-base-content text-base-content/40 cursor-not-allowed placeholder-opacity-20;

And therefore the color differences.

TheWilley added a commit to TheWilley/FruityDancitor that referenced this issue Feb 25, 2024
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

1 participant