I have an icon with a default class , the class name is card-icon , now how do I change the class based on condition or disable the class ?
Because the default color of the icon is gray now when condition is met or condition true I want to change it to black color.
The condition is below , when condition is true disable class="card-icon" or if it is not possible to disable then replace when a new class for example [class.newclass] .
Any idea how to implement this guys ? Thank you.
#Icon with default class
<mat-icon class="card-icon">group</mat-icon>
#Condition
<mat-icon class="active-icon" [class.newclass]="currentTabElement === 'group'">group</mat-icon>