[ToggleButton] Selected color should be take in account without '! important'
See original GitHub issueWhen you want to use a specific color on the selected toggleButton, you must add important
for the color to be taken into account
Example with codesandbox
Issue Analytics
- State:
- Created 3 years ago
- Comments:5 (4 by maintainers)
Top Results From Across the Web
[ToggleButton] Selected color should be take in account ...
When you want to use a specific color on the selected toggleButton, you must add important for the color to be taken into...
Read more >Material UI Toggle Button - can't change background color ...
I'm using the classes prop on the ToggleButton component, and using the "selected" rule within that prop.
Read more >What Makes A Great Toggle Button? (Case Study, Part 2)
If you choose to use color as the main lead, we suggest you use a combination of a saturated lively color (ideally corresponding...
Read more >The best tools to create effective toggle buttons
Explore what a toggle button is, learn when to use a toggle button, and find the tools that help you create effective toggles....
Read more >ToggleButton (On/Off) Tutorial With Example In Android
To check current state of a toggle button programmatically we use isChecked() method. This method returns a Boolean value either true or false....
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
@oliviertassinari Shouldn’t the classes override win over the default style ?
From the codesandbox:
Indeed the specificy is less important because you have one class
.makeStyles-buttonColor-1
vs.MuiToggleButton-root.Mui-selected
Alright, I missed that, thanks 👍