@flavio_b wrote:
Hello,
I was wondering if something similar to this, was possible in case of a list. I wanted to hide just the ion-card-content, upon click on ion-card-header if I have a list of cards.
Basically, I have something like this in my html:
<ion-list> <ion-card *ngFor="let entry of entries | async; let i = index"> <ion-card-header (click)="toggleSection(i)" class="header"> {{ entry.name }} </ion-card-header> <ion-card-content [hidden]="entry.hidden"> "some content" </ion-card-content> </ion-card> </ion-list>
The problem is that entry.hidden doesn’t exist in the “entries” (namely, hidden is not a field of entry), so I don’t know how to store this property efficiently for each element of entries to be used to show/hide the ion-card-content.
Any suggestion?
Posts: 1
Participants: 1