-
Notifications
You must be signed in to change notification settings - Fork 6.8k
Closed
Labels
P2The issue is important to a large percentage of users, with a workaroundThe issue is important to a large percentage of users, with a workaround
Description
Bug, feature request, or proposal:
Bug
What is the expected behavior?
When the ngModel of a mat-select is populated on page load the mat-select should have that option selected.
What is the current behavior?
mat-select does not show the current selected option on page load if a mat-option has some async behaviour, in my case the translate pipe:
<mat-option *ngFor="let option of options" [value]="option.value">
{{ option.label | translate }}
</mat-option>
The current selected option is shown the moment the mat-select gets focus.
What are the steps to reproduce?
Please have a look at the following StackBlitz example:
https://stackblitz.com/edit/angular-material2-issue-async-mat-option-label?file=app%2Fpet-select-async%2Fpet-select-async.component.ts
Which versions of Angular, Material, OS, TypeScript, browsers are affected?
material beta 12
angular 4.4.3
lordgreg, diogen737, Nheverest, DimaLegeza, alexey-shakura and 10 more
Metadata
Metadata
Assignees
Labels
P2The issue is important to a large percentage of users, with a workaroundThe issue is important to a large percentage of users, with a workaround