Button disabled gets twice class Mui-disabled
See original GitHub issueWhen a Button is disabled, it gets twice the class Mui-disabled
.
- The issue is present in the latest release.
- I have searched the issues of this repository and believe that this is not a duplicate.
Current Behavior 😯
There are two Mui-disabled
class on a disabled Button.
Expected Behavior 🤔
Only one Mui-disabled
class on a disabled Button.
Steps to Reproduce 🕹
https://material-ui.com/components/buttons/ Or: https://codesandbox.io/s/material-demo-mtk0k
Steps:
- Inspect the disabled Button
Context 🔦
Doesn’t affect behavior.
Your Environment 🌎
Tech | Version |
---|---|
Material-UI | v4.9.2 |
React | v16.12.0 |
Browser | Version 78.0.3904.87 (Official Build) (64-bit) |
TypeScript | 3.9.0 |
Issue Analytics
- State:
- Created 4 years ago
- Reactions:1
- Comments:12 (9 by maintainers)
Top Results From Across the Web
Button disabled gets twice class Mui-disabled #19683 - GitHub
When a Button is disabled, it gets twice the class Mui-disabled . unknown-20. The issue is present in the latest release.
Read more >Override .Mui-disabled (or other pseudo-classes/states) from ...
Mui-disabled class rules once. Basically I don't want all disabled items to have the default grey colored background.
Read more >Making Disabled Buttons More Inclusive - CSS-Tricks
Let's talk about disabled buttons. Specifically, let's get into why we use them and how we can do better than the traditional disabled...
Read more >disable twice pressing of submit button - MSDN
How do i make out the submit button has been pressed twice or how do i stop that ... Try the below Sample...
Read more >Xpath doubt - General Web Dev - SitePoint Forums
I am new to XPATH Supratik's Kitchen Switch to mobile view . where i ... <button class="MuiButtonBase-root MuiButton-root ... Mui-disabled ].
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Is there a reason this closed? This clearly isn’t the intended behavior. There shouldn’t be two
.Mui-disabled
classes appended to a DOM node if there is only onedisabled
prop on the component. It seems to be a real bug and not-intended behavior. @eps1lon Can we re-open?I don’t have an opinion about whether the Mui-disabled class is or isn’t a good ideal to direct the styling but many html checkers frown on seeing the same classname multiple times in the same class attribute