我在Angular有一个系统,我称之为“oke魔 t镜”,我只关心“卡片、im子”特性,负责展示图像链接。 但是,我无法正常展示这些卡片。 目前有四舍五入。
<div class="scroll">
<span class="font-extrabold text-3xl" style="color: #ffcb08;" *ngIf="spinner">Carregando cartas</span>
<table *ngIf="!spinner" mat-table [dataSource]="dataSource" class="mat-elevation-z8 mat-table">
<ng-container matColumnDef="position">
<th mat-header-cell *matHeaderCellDef></th>
<td (click)="addCard(element)" mat-cell *matCellDef="let element"> <img class="card" [src]="element.images?.small" alt=""> </td>
</ng-container>
<ng-container matColumnDef="position2">
<th mat-header-cell *matHeaderCellDef></th>
<td (click)="addCard(element)" mat-cell *matCellDef="let element"> <img class="card" [src]="element.images?.small" alt=""> </td>
</ng-container>
<ng-container matColumnDef="position3">
<th mat-header-cell *matHeaderCellDef></th>
<td (click)="addCard(element)" mat-cell *matCellDef="let element"> <img class="card" [src]="element.images?.small" alt=""> </td>
</ng-container>
<ng-container matColumnDef="position4">
<th mat-header-cell *matHeaderCellDef></th>
<td (click)="addCard(element)" mat-cell *matCellDef="let element"> <img class="card" [src]="element.images?.small" alt=""> </td>
</ng-container>
<tr mat-header-row *matHeaderRowDef="displayedColumns"></tr>
<tr mat-row *matRowDef="let row; columns: displayedColumns;"></tr>
</table>
</div>