【发布时间】:2021-06-23 16:31:39
【问题描述】:
我使用了 ng-flex,所以它们反应灵敏。但我想对齐它们,使它们都具有相同的高度。 how you can see they aren't alinged.
.content {
padding: 16px;
}
.content > mat-card {
width: 200px;
}
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css">
<div class="content">
<div fxLayout="row wrap" fxLayoutGap="16px grid">
<div fxFlex="25%" fxFlex.xs="100%" fxFlex.sm="33%" *ngFor="let manga of mangaList">
<mat-card class="mat-elevation-z4" >
<mat-card-header>
<mat-card-title>{{ manga.title }}</mat-card-title>
</mat-card-header>
<img mat-card-image src="{{ manga.preview }}">
<mat-card-actions>
<button mat-button>Leggi</button>
<button mat-button (click)="updateBookmark(manga)">
<i *ngIf="manga.bookmarked == 'false'; else ifBookmarked" class="fa fa-bookmark-o fa-lg"></i>
<ng-template #ifBookmarked>
<i class="fa fa-bookmark fa-lg"></i>
</ng-template>
</button>
</mat-card-actions>
</mat-card>
</div>
</div>
</div>
【问题讨论】:
标签: javascript html css angular angular-material