Skip to content

Commit 22377de

Browse files
hamzajazyricrisbeto
authored andcommitted
docs(material/datepicker): avoid CalendarView switching (#26652)
add missing encapsulation to disable pointer-events for periodButtonLabel. fixes #24915 (cherry picked from commit ab6b4bf)
1 parent 5df5368 commit 22377de

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/components-examples/material/datepicker/datepicker-views-selection/datepicker-views-selection-example.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import {Component} from '@angular/core';
1+
import {Component, ViewEncapsulation} from '@angular/core';
22
import {FormControl} from '@angular/forms';
33
import {MomentDateAdapter, MAT_MOMENT_DATE_ADAPTER_OPTIONS} from '@angular/material-moment-adapter';
44
import {DateAdapter, MAT_DATE_FORMATS, MAT_DATE_LOCALE} from '@angular/material/core';
@@ -45,6 +45,7 @@ export const MY_FORMATS = {
4545

4646
{provide: MAT_DATE_FORMATS, useValue: MY_FORMATS},
4747
],
48+
encapsulation: ViewEncapsulation.None,
4849
})
4950
export class DatepickerViewsSelectionExample {
5051
date = new FormControl(moment());

0 commit comments

Comments
 (0)