Angular 如何在mat select中不显示选定值

Angular 如何在mat select中不显示选定值,angular,angular-material,Angular,Angular Material,这里是一个简单的选择从角材料库 <mat-form-field class="ui20-filter-select"> <mat-label>Priority</mat-label> <mat-select name="byPriority" [(ngModel)]="filter.priority (selectionChange)="filterChanged.next($eve

这里是一个简单的选择从角材料库

<mat-form-field class="ui20-filter-select">
   <mat-label>Priority</mat-label>
   <mat-select name="byPriority" [(ngModel)]="filter.priority (selectionChange)="filterChanged.next($event)">
      <mat-option [value]="priority" *ngFor="let priority of availablePriorities">{{priority}}</mat-option>
   </mat-select>
 </mat-form-field>

优先

您可以使用select trigger(选择触发器)执行此操作:

<mat-form-field class="ui20-filter-select">
   <mat-label>Priority</mat-label>
   <mat-select name="byPriority" [(ngModel)]="filter.priority (selectionChange)="filterChanged.next($event)">
      <mat-select-trigger>
        Priority ->
      </mat-select-trigger>
      <mat-option [value]="priority" *ngFor="let priority of availablePriorities">{{priority}}</mat-option>
   </mat-select>
 </mat-form-field>

优先