Skip to content
This repository was archived by the owner on Sep 5, 2024. It is now read-only.

Commit f20a635

Browse files
jelbournThomasBurleson
authored andcommitted
fix(datepicker): fix theme not being applied.
fixes #5141.
1 parent 9f561a5 commit f20a635

File tree

4 files changed

+14
-15
lines changed

4 files changed

+14
-15
lines changed

src/components/autocomplete/autocomplete-theme.scss

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ md-autocomplete.md-THEME_NAME-theme {
1414
}
1515
}
1616
}
17-
.md-autocomplete-suggestions-container.md-THEME_NAME-theme, {
17+
.md-autocomplete-suggestions-container.md-THEME_NAME-theme {
1818
background: '{{background-50}}';
1919
li {
2020
color: '{{background-900}}';

src/components/datepicker/calendar-theme.scss

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
11
/** Theme styles for mdCalendar. */
22

3-
.md-calendar.md-THEME_NAME-theme {
4-
color: '{{foreground-1}}';
3+
md-calendar.md-THEME_NAME-theme {
4+
.md-calendar {
5+
color: '{{foreground-1}}';
56

6-
tr:last-child td {
7-
border-bottom-color: '{{background-200}}';
7+
tr:last-child td {
8+
border-bottom-color: '{{background-200}}';
9+
}
810
}
9-
}
10-
.md-THEME_NAME-theme {
1111

1212
.md-calendar-day-header {
1313
background: '{{background-hue-1}}';

src/components/datepicker/datePicker-theme.scss

Lines changed: 6 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,6 @@
22

33
md-datepicker.md-THEME_NAME-theme {
44
background: '{{background-color}}';
5-
}
6-
7-
.md-THEME_NAME-theme {
85

96
.md-datepicker-input {
107
@include input-placeholder-color('{{foreground-3}}');
@@ -24,10 +21,6 @@ md-datepicker.md-THEME_NAME-theme {
2421
}
2522
}
2623

27-
.md-datepicker-calendar-pane {
28-
border-color: '{{background-300}}';
29-
}
30-
3124
.md-datepicker-triangle-button {
3225
.md-datepicker-expand-triangle {
3326
border-top-color: '{{foreground-3}}';
@@ -39,14 +32,19 @@ md-datepicker.md-THEME_NAME-theme {
3932
}
4033

4134
// Open state for all of the elements of the picker.
42-
.md-datepicker-open {
35+
&.md-datepicker-open {
4336
.md-datepicker-calendar-icon {
4437
fill: '{{primary-500}}';
4538
}
4639
}
40+
}
41+
42+
.md-datepicker-calendar-pane.md-THEME_NAME-theme {
43+
border-color: '{{background-300}}';
4744

4845
.md-datepicker-calendar,
4946
.md-datepicker-input-mask-opaque {
5047
background: '{{background-color}}';
5148
}
5249
}
50+

src/components/datepicker/datePicker.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -213,6 +213,7 @@
213213
this.calendarPane.id = 'md-date-pane' + $mdUtil.nextUid();
214214

215215
$mdTheming($element);
216+
$mdTheming(angular.element(this.calendarPane));
216217

217218
/** Pre-bound click handler is saved so that the event listener can be removed. */
218219
this.bodyClickHandler = angular.bind(this, this.handleBodyClick);

0 commit comments

Comments
 (0)