-
-
Notifications
You must be signed in to change notification settings - Fork 32.3k
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
[SvgIcon] Apply custom color if defined in the theme #27923
Conversation
SvgIcon
with custom color
<ThemeProvider theme={theme}> | ||
<FavoriteRounded fontSize="large" /> | ||
<FavoriteRounded fontSize="large" color="secondary" /> | ||
<FavoriteRounded fontSize="large" color="custom" /> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should we add some instructions for typescript? Or do we already support extending the color prop values?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah I saw, we already have it. Nevermind looks good :)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Perfect! Thanks for taking this up 💯
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍
Given
Before:
After:
Closes #27831 see https://codesandbox.io/s/material-ui-v5-icons-custom-color-bug-forked-mzyxm