Commit 11ae8ec845a8659e65cb63748c2a4e9d63bb6af3
1 parent
d14f6a4d
UI: Improvement table columns assigment
Showing
2 changed files
with
10 additions
and
3 deletions
... | ... | @@ -23,13 +23,13 @@ |
23 | 23 | </mat-cell> |
24 | 24 | </ng-container> |
25 | 25 | <ng-container matColumnDef="sampleData"> |
26 | - <mat-header-cell *matHeaderCellDef style="flex: 0 0 30%;" class="mat-column-sampleData"> {{ 'import.column-example' | translate }} </mat-header-cell> | |
26 | + <mat-header-cell *matHeaderCellDef class="mat-column-sampleData"> {{ 'import.column-example' | translate }} </mat-header-cell> | |
27 | 27 | <mat-cell *matCellDef="let column"> |
28 | 28 | {{column.sampleData}} |
29 | 29 | </mat-cell> |
30 | 30 | </ng-container> |
31 | 31 | <ng-container matColumnDef="type"> |
32 | - <mat-header-cell *matHeaderCellDef style="flex: 0 0 40%" class="mat-column-type"> {{ 'import.column-type.column-type' | translate }} </mat-header-cell> | |
32 | + <mat-header-cell *matHeaderCellDef class="mat-column-type"> {{ 'import.column-type.column-type' | translate }} </mat-header-cell> | |
33 | 33 | <mat-cell *matCellDef="let column"> |
34 | 34 | <mat-select [(ngModel)]="column.type" (ngModelChange)="columnsUpdated()"> |
35 | 35 | <mat-option *ngFor="let type of columnTypes" [value]="type.value" [disabled]="type.disabled"> |
... | ... | @@ -44,7 +44,7 @@ |
44 | 44 | </mat-cell> |
45 | 45 | </ng-container> |
46 | 46 | <ng-container matColumnDef="key"> |
47 | - <mat-header-cell *matHeaderCellDef style="flex: 0 0 30%"> {{ 'import.column-key' | translate }} </mat-header-cell> | |
47 | + <mat-header-cell *matHeaderCellDef class="mat-column-key"> {{ 'import.column-key' | translate }} </mat-header-cell> | |
48 | 48 | <mat-cell *matCellDef="let column"> |
49 | 49 | <mat-form-field floatLabel="always" hideRequiredMarker |
50 | 50 | *ngIf="isColumnTypeDiffers(column.type)"> | ... | ... |
... | ... | @@ -14,14 +14,21 @@ |
14 | 14 | * limitations under the License. |
15 | 15 | */ |
16 | 16 | :host { |
17 | + overflow-x: auto; | |
18 | + | |
17 | 19 | .mat-column-order { |
18 | 20 | flex: 0 0 40px; |
19 | 21 | } |
20 | 22 | .mat-column-sampleData { |
21 | 23 | flex: 0 0 120px; |
22 | 24 | min-width: 120px; |
25 | + max-width: 230px; | |
23 | 26 | } |
24 | 27 | .mat-column-type { |
28 | + flex: 0 0 180px; | |
29 | + min-width: 180px; | |
30 | + } | |
31 | + .mat-column-key { | |
25 | 32 | flex: 0 0 120px; |
26 | 33 | min-width: 120px; |
27 | 34 | } | ... | ... |