Input's FormControl setValue does not work when mat-form-field has chip-list and input is linked to autocomplete
Chưa có ai nhận issue này.
- Ngôn ngữ chính
- TypeScript
- Star
- 25k
- Fork
- 6.8k
- Merge trung bình
- 1 ngày 8 giờ
- Pull request đã merge (30 ngày)
- 91
Mô tả
#### Bug, feature request, or proposal:
Bug
#### What is the expected behavior?
Input's FormControl's setValue should work for an input that is inside a mat-form-field that has both autocomplete and chip-list.
#### What is the current behavior?
FormControl setValue does not work when the following iff a mat-form-field has an input that has matAutocomplete AND the mat-form-field has a mat-chip-list.
SetValue works if one removes the matAutocomplete directive from the input or removes the mat-chip-list element.
#### What are the steps to reproduce?
Demo should have the input incrementing a number every second, which doesn't work:
https://stackblitz.com/edit/angular-ay3yts?file=app%2Fautocomplete-simple-example.html
Deleting mat-chip-list or removing the matAutocomplete directive fixes the issue.
#### What is the use-case or motivation for changing an existing behavior?
I want to be able to programmatically add a chip then clear the input when an option in the autocomplete has been selected.
#### Which versions of Angular, Material, OS, TypeScript, browsers are affected?
Angular: 5.2.4
Material: 5.2.4
#### Is there anything else we should know?
Nope :)
Hướng dẫn đóng góp
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Hướng nghiên cứu
Bắt đầu với bản tái hiện StackBlitz được liên kết, đặc biệt là app/autocomplete-simple-example.html, và chạy ví dụ khi có cả matAutocomplete và mat-chip-list. Truy vết lý do setValue của FormControl của input không được cập nhật trong tổ hợp đó. Hoàn thành khi các cập nhật bằng chương trình hoạt động mà hành vi của autocomplete và chip-list vẫn khả dụng.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Đánh giá
- Công nghệ
- angular, typescript
- Lĩnh vực
- frontend
- Loại issue
- Lỗi
- Độ khó
- 4/5
- Thời gian dự kiến
- 3-5 ngày
- Mức độ hoạt động
- Đình trệ
- Độ rõ ràng
- Khá rõ ràng
- Mức phù hợp với người mới
- 35/100