I have the following:
<div class="wrapper">
<mat-card style="margin:1em; width: 250px; border: 1px ridge white">
<mat-card-header>
<div mat-card-avatar class="verify-header-image"></div>
<mat-card-title>{{name}}</mat-card-title>
<mat-card-subtitle [hidden]="shouldHideSub">Linked</mat-card-subtitle>
<mat-card-subtitle [hidden]="!shouldHideSub">Unlinked</mat-card-subtitle>
</mat-card-header>
<img mat-card-image src={{picture}} alt="Portrait of the character">
<mat-card-content>
</mat-card-content>
<mat-card-actions>
<div class="button-row">
<button mat-raised-button color="primary">Details</button>
</div>
</mat-card-actions>
</mat-card>
</div>
I want to show the subtitle conditionally but for some reason I cannot use hidden like I have above, ng-if does not seem to work either, I also cannot use ngClass
to specify the class for mat-card-avatar picture.
Is this just not possible or am I missing something?