blob: bd9e7a13f2eea93fdb56ff8cd0002a8a700e4e73 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
|
<div *ngIf="data">
<div class="table-responsive" style="max-height: 50vh; max-width: 100%; overflow: scroll;">
<table *ngIf="hasHeader" class="table table-bordered table-light">
<thead>
<tr>
<th *ngFor="let item of data[0]; let i = index">{{item}}</th>
</tr>
</thead>
<tbody>
<tr *ngFor="let row of data | slice:1">
<td *ngFor="let col of row">{{col}}</td>
</tr>
</tbody>
</table>
<table *ngIf="data.length > 0 && !hasHeader" class="table table-bordered table-light">
<tbody>
<tr *ngFor="let row of data">
<td *ngFor="let col of row">{{col}}</td>
</tr>
</tbody>
</table>
</div>
<div id="info">
<br>
<span *ngIf="hasHeader">{{data.length - 1}} x {{data[0].length}}</span>
<span *ngIf="!hasHeader">{{data.length}} x {{data[0].length}}</span>
</div>
</div>
|