Within my Angular 4 project, I am utilizing ngClass on an object that contains a CSS class applied with unset: all within it. Despite knowing that ngClass adds its properties, the expected result was for all values to be unset and the style elements from ngClass to be added. However, this did not occur as anticipated, causing significant frustration in my specific scenario:
<i [ngClass]="{'material-icons':true}" class="ignore-css" >chevron_right</i>
.ignore-css {
all: unset;
}
The reason for unsetting previous CSS is to avoid inheriting size, colors, and other styles from the icons elsewhere on the page. Unfortunately, using all: unset; results in the arrow icon not being displayed, only showing "chevron_right."
Is there a way to unset previous CSS while still displaying the icon?