I want to list items in an array vertically with cards, but there is no space between them. I tried to use padding but it seems it doesn't work.
How can I have these cards spaced?
<ng-container *ngIf="titles?.length; else noTitle">
<mat-card class="asd cardPardding" *ngFor="let title of titles">
<p>
{{title}}
</p>
</mat-card>
</ng-container>
<ng-template #noTitle>
<mat-card class="asd cardPardding">
<p>
No title !
</p>
</mat-card>
</ng-template>
This is css
.asd {
width: 80%;
margin: 0 auto; /* Added */
}
.inputasd {
width: 100%;
}
.cardPadding {
padding: 100px;
margin-bottom: 50px;
}
margin-bottom: 10px;
– Twopiecemat-card { margin-bottom: 10px; }
– Twopiece