File tree Expand file tree Collapse file tree 2 files changed +8
-3
lines changed Expand file tree Collapse file tree 2 files changed +8
-3
lines changed Original file line number Diff line number Diff line change 4242 [style.paddingTop] ="_cellPadding "
4343 [style.paddingBottom] ="_cellPadding ">
4444 < button class ="mat-calendar-body-cell-content "
45- mat-button
45+ mat-button type ="button "
46+ [attr.aria-label] ="item.displayValue "
4647 [class.mat-calendar-body-selected] ="selectedValue === item.value "
4748 [class.mat-calendar-body-today] ="todayValue === item.value ">
4849 {{item.displayValue}}
Original file line number Diff line number Diff line change @@ -70,15 +70,19 @@ describe('MatCalendar', () => {
7070
7171 let todayCell = calendarElement . querySelector ( '.mat-calendar-body-today' ) ! ;
7272 expect ( todayCell ) . not . toBeNull ( ) ;
73- expect ( todayCell . innerHTML . trim ( ) ) . toBe ( '1' ) ;
73+ let todayCellSpan = todayCell . querySelector ( 'span' ) ! ;
74+ expect ( todayCellSpan ) . not . toBeNull ( ) ;
75+ expect ( todayCellSpan . innerHTML . trim ( ) ) . toBe ( '1' ) ;
7476
7577 fakeToday = new Date ( 2018 , 0 , 10 ) ;
7678 calendarInstance . updateTodaysDate ( ) ;
7779 fixture . detectChanges ( ) ;
7880
7981 todayCell = calendarElement . querySelector ( '.mat-calendar-body-today' ) ! ;
8082 expect ( todayCell ) . not . toBeNull ( ) ;
81- expect ( todayCell . innerHTML . trim ( ) ) . toBe ( '10' ) ;
83+ todayCellSpan = todayCell . querySelector ( 'span' ) ! ;
84+ expect ( todayCellSpan ) . not . toBeNull ( ) ;
85+ expect ( todayCellSpan . innerHTML . trim ( ) ) . toBe ( '10' ) ;
8286 } ) ) ;
8387
8488 it ( 'should be in month view with specified month active' , ( ) => {
You can’t perform that action at this time.
0 commit comments