You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Setting a link color on a parent block overrides icon and button colors #33437
The "fix" for this is to add more !important rules to ensure the icon color and button text color display as intended.
However this would not be a proper fix as we then get into a seemingly never ending pathway of adding !important whenever new issues like this come up.
Have we already gone too far down this route? Is it too late to rethink the use of !important from the ground up?
The "fix" for this is to add more !important rules to ensure the icon color and button text color display as intended.
That's not the perfect solution.
If there some !important used on nested selectors for example .foo .bar > a, perhaps the fix with !important still won't work.
However this would not be a proper fix as we then get into a seemingly never ending pathway of adding !important whenever new issues like this come up.
Yes, I call this the "hell of !important".
Have we already gone too far down this route? Is it too late to rethink the use of !important from the ground up?
Removing important on initial styles in core should help. See also #34575.
I've seen a css framework wich uses tons of classes for elements to adjust styles:
Activity
richtabor commentedon Aug 17, 2021
Came here to report the same issue.
Sandstromer commentedon Sep 9, 2021
The "fix" for this is to add more
!importantrules to ensure the icon color and button text color display as intended.However this would not be a proper fix as we then get into a seemingly never ending pathway of adding
!importantwhenever new issues like this come up.Have we already gone too far down this route? Is it too late to rethink the use of
!importantfrom the ground up?oandregal commentedon Sep 9, 2021
I've got a potential fix at #34689 and would like help in testing it. Does the PR list all the use cases that we need to take care of?
mkkeck commentedon Sep 11, 2021
That's not the perfect solution.
If there some
!importantused on nested selectors for example.foo .bar > a, perhaps the fix with!importantstill won't work.Yes, I call this the "hell of
!important".Removing important on initial styles in core should help. See also #34575.
I've seen a css framework wich uses tons of classes for elements to adjust styles:
But the code above is most flexible for all things. Perhaps this may be a solution for core styles.