Inside my matDatepickerFilter I need to access the component. Till Angular 9 it worked to set bind(this) on the filter Function.
Unfortunately this doesn't work no longer. Whenever I define a matDatepickerFilter in a template like this [matDatepickerFilter]="valiDateStart.bind(this)" I can't click on a month on the corresponding matDatePicker.
Once I remove the bind(this) the datePicker works again.
Reproduction
https://stackblitz.com/edit/components-issue-5tpaxb?file=src%2Fapp%2Fexample-component.html
Steps to reproduce:
- Click on second calender Icon
- Click a month on the opening popup
Expected Behavior
I would expect to see the month view for the clicked month
Actual Behavior
No reaction. The month selection view is still shown
Environment
- Angular: Had the problem with Angular 10 and 11
- CDK/Material: 10 & 11 as well
- Browser(s): Current Firefox, Current Chrome
- Operating System (e.g. Windows, macOS, Ubuntu): Currently using Fedora, haven't checked another OS yet
Inside my matDatepickerFilter I need to access the component. Till Angular 9 it worked to set
bind(this)on the filter Function.Unfortunately this doesn't work no longer. Whenever I define a matDatepickerFilter in a template like this
[matDatepickerFilter]="valiDateStart.bind(this)"I can't click on a month on the corresponding matDatePicker.Once I remove the
bind(this)the datePicker works again.Reproduction
https://stackblitz.com/edit/components-issue-5tpaxb?file=src%2Fapp%2Fexample-component.html
Steps to reproduce:
Expected Behavior
I would expect to see the month view for the clicked month
Actual Behavior
No reaction. The month selection view is still shown
Environment