-
Notifications
You must be signed in to change notification settings - Fork 6.8k
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
fix(button): theme font color being overwritten #9771
fix(button): theme font color being overwritten #9771
Conversation
5f96312
to
1725324
Compare
@jelbourn I differentiated between |
03e0f7b
to
f35a666
Compare
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.
LGTM, @mmalerba should look at the form-field bits
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.
LGTM
caretaker note: there's a number of broken screendiffs where the button color is wrong (black on dark themes, etc) |
f35a666
to
f3b930b
Compare
* Currently buttons with a background color (e.g. flat buttons, raised buttons, fabs) receive a font color by the theme. This font color is accidentally being overwritten by the normal button CSS that sets the `color` for every button to `inherit`. This can cause the text to be invisible in a dark theme. From now on, those buttons will no longer inherit the font color accidentally. * Normal buttons, stroked buttons and icon buttons will still inherit the font color, because it's wrong to assume that those buttons are always placed inside of containers with the default background color. Otherwise those buttons would be invisible in some containers with a different background color (e.g. in a themed toolbar). * Removes the SSR check for `hasHostAttributes`. This method is essential for the color of the buttons, and needs to run inside of SSR. (now possible with Domino anyway) * Cleans up the button theme while being at it. Fixes angular#4614. Fixes angular#9231. Fixes angular#9634
f3b930b
to
32b234e
Compare
Just a ping for review. As mentioned in the standup. This is pretty high priority IMO. |
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.
LGTM
changes were approved a month ago, looks like CI failed because of rate limit exceeded or missing tokens, any idea when this will be merged? |
Has this been solved in 5.2.5? I'm still having this issue in 5.2.5.. |
This is tagged as a |
If your font color is black in a dark theme, that's your problem, not the button's. |
This issue has been automatically locked due to inactivity. Read more about our automatic conversation locking policy. This action has been performed automatically by a bot. |
Updated version of #9536
Currently buttons with a background color (e.g. flat buttons, raised buttons, fabs) receive a font color by the theme. This font color is accidentally being overwritten by the normal button CSS that sets the
color
for every button toinherit
. This can cause the text to be invisible in a dark theme. From now on, those buttons will no longer inherit the font color accidentally.Normal buttons, stroked buttons and icon buttons will still inherit the font color, because it's wrong to assume that those buttons are always placed inside of containers with the default background color. Otherwise those buttons would be invisible in some containers with a different background color (e.g. in a themed toolbar).
Removes the SSR check for
hasHostAttributes
. This method is essential for the color of the buttons, and needs to run inside of SSR. (now possible with Domino anyway)Cleans up the button theme while being at it.
Fixes #4614. Fixes #9231. Fixes #9634