File tree Expand file tree Collapse file tree 4 files changed +32
-12
lines changed Expand file tree Collapse file tree 4 files changed +32
-12
lines changed Original file line number Diff line number Diff line change 55@import ' ../../card/card-theme' ;
66@import ' ../../checkbox/checkbox-theme' ;
77@import ' ../../chips/chips-theme' ;
8+ @import ' ../../datepicker/datepicker-theme' ;
89@import ' ../../dialog/dialog-theme' ;
910@import ' ../../grid-list/grid-list-theme' ;
1011@import ' ../../icon/icon-theme' ;
3435 @include mat-card-typography ($config );
3536 @include mat-checkbox-typography ($config );
3637 @include mat-chips-typography ($config );
38+ @include mat-datepicker-typography ($config );
3739 @include mat-dialog-typography ($config );
3840 @include mat-grid-list-typography ($config );
3941 @include mat-icon-typography ($config );
Original file line number Diff line number Diff line change 11@import ' ../core/theming/palette' ;
22@import ' ../core/theming/theming' ;
3+ @import ' ../core/typography/typography-utils' ;
4+
5+
6+ $mat-calendar-body-font-size : 13px !default ;
7+ $mat-calendar-weekday-table-font-size : 11px !default ;
38
49
510@mixin mat-datepicker-theme ($theme ) {
7883 border-color : fade-out (mat-color ($foreground , hint-text ), $mat-datepicker-today-fade-amount );
7984 }
8085}
86+
87+ @mixin mat-datepicker-typography ($config ) {
88+ .mat-calendar {
89+ font-family : mat-font-family ($config );
90+ }
91+
92+ .mat-calendar-body {
93+ font-size : $mat-calendar-body-font-size ;
94+ }
95+
96+ .mat-calendar-body-label ,
97+ .mat-calendar-period-button {
98+ font : {
99+ size : mat-font-size ($config , button );
100+ weight : mat-font-weight ($config , button );
101+ }
102+ }
103+
104+ .mat-calendar-table-header th {
105+ font : {
106+ size : $mat-calendar-weekday-table-font-size ;
107+ weight : mat-font-weight ($config , body-1 );
108+ }
109+ }
110+ }
Original file line number Diff line number Diff line change 1- $mat-calendar-body-font-size : 13px !default ;
2- $mat-calendar-body-header-font-size : 14px !default ;
31$mat-calendar-body-label-padding-start : 5% !default ;
42$mat-calendar-body-label-translation : -6px !default ;
53$mat-calendar-body-cell-min-size : 32px !default ;
@@ -13,7 +11,6 @@ $mat-calendar-body-cell-content-size: 100% - $mat-calendar-body-cell-content-mar
1311
1412
1513.mat-calendar-body {
16- font-size : $mat-calendar-body-font-size ;
1714 min-width : $mat-calendar-body-min-size ;
1815}
1916
@@ -24,8 +21,6 @@ $mat-calendar-body-cell-content-size: 100% - $mat-calendar-body-cell-content-mar
2421 line-height : 0 ;
2522 transform : translateX ($mat-calendar-body-label-translation );
2623 text-align : left ;
27- font-size : $mat-calendar-body-header-font-size ;
28- font-weight : bold ;
2924}
3025
3126.mat-calendar-body-cell {
Original file line number Diff line number Diff line change @@ -6,10 +6,8 @@ $mat-calendar-controls-vertical-padding: 5%;
66$mat-calendar-controls-start-padding : calc (100% / 14 - 22px );
77// Same as above, but on other side for arrows.
88$mat-calendar-controls-end-padding : calc (100% / 14 - 22px );
9- $mat-calendar-period-font-size : 14px ;
109$mat-calendar-arrow-size : 5px !default ;
1110$mat-calendar-arrow-disabled-opacity : 0.5 !default ;
12- $mat-calendar-weekday-table-font-size : 11px !default ;
1311
1412// Values chosen to approximate https://material.io/icons/#ic_navigate_before and
1513// https://material.io/icons/#ic_navigate_next as closely as possible.
@@ -43,9 +41,6 @@ $mat-calendar-next-icon-transform: translateX(-2px) rotate(45deg);
4341}
4442
4543.mat-calendar-period-button {
46- font : inherit ;
47- font-size : $mat-calendar-period-font-size ;
48- font-weight : bold ;
4944 min-width : 0 ;
5045}
5146
@@ -108,8 +103,6 @@ $mat-calendar-next-icon-transform: translateX(-2px) rotate(45deg);
108103
109104.mat-calendar-table-header th {
110105 text-align : center ;
111- font-size : $mat-calendar-weekday-table-font-size ;
112- font-weight : normal ;
113106 padding : 0 0 $mat-calendar-padding 0 ;
114107}
115108
You can’t perform that action at this time.
0 commit comments