我試圖覆蓋并降低mat-form-field中的mat-select、mat-form-field中的datepicker和mat-input的高度: 我嘗試了很多方法,包括::ng-deep和ViewEncapsulation。沒有,只是運氣不好。
這是我的代碼:
<mat-form-field appearance="outline">
<mat-label>mat select</mat-label>
<mat-select formControlName="merch" (selectionChange)="merchTechnic()">
<mat-option *ngFor="let merch of merches" [value]="merch">
{{merch}}
</mat-option>
</mat-select>
</mat-form-field>
<mat-form-field appearance="outline">
<input matInput [matDatepicker]="pickerA" [(ngModel)]="to" (dateChange)="dateChange()">
<mat-datepicker-toggle matIconSuffix [for]="pickerA"></mat-datepicker-toggle>
<mat-datepicker #pickerA color="warn"></mat-datepicker>
</mat-form-field>
<mat-form-field class="form-field" appearance="outline">
<mat-label>searching</mat-label>
<input matInput type="text" formControlName="words">
</mat-form-field>
謝謝你,