|
4 | 4 | @import '../core/typography/typography-utils';
|
5 | 5 |
|
6 | 6 | @mixin _mat-slide-toggle-checked($palette, $thumb-checked-hue) {
|
7 |
| - // Do not apply the checked colors if the toggle is disabled, because the |
8 |
| - // specificity would be to high for the disabled styles. |
9 |
| - &.mat-checked:not(.mat-disabled) { |
| 7 | + &.mat-checked { |
10 | 8 | .mat-slide-toggle-thumb {
|
11 | 9 | background-color: mat-color($palette, $thumb-checked-hue);
|
12 | 10 | }
|
|
39 | 37 | // specifications. See: https://material.io/design/components/selection-controls.html#specs
|
40 | 38 | $thumb-unchecked-hue: if($is-dark, 400, 50);
|
41 | 39 | $thumb-checked-hue: if($is-dark, 200, default);
|
42 |
| - $thumb-disabled-hue: if($is-dark, 800, 400); |
43 | 40 |
|
44 | 41 | $bar-unchecked-color: mat-color($foreground, disabled);
|
45 |
| - $bar-disabled-color: if($is-dark, rgba(white, 0.12), rgba(black, 0.1)); |
46 |
| - |
47 | 42 | $ripple-unchecked-color: mat-color($foreground, base);
|
48 | 43 |
|
49 | 44 | .mat-slide-toggle {
|
|
64 | 59 | }
|
65 | 60 | }
|
66 | 61 |
|
67 |
| - .mat-disabled { |
68 |
| - .mat-slide-toggle-thumb { |
69 |
| - // The thumb of the slide-toggle always uses the hue 400 of the grey palette in dark |
70 |
| - // or light themes. Since this is very specific to the slide-toggle component, we're not |
71 |
| - // providing it in the background palette. |
72 |
| - background-color: mat-color($mat-grey, $thumb-disabled-hue); |
73 |
| - } |
74 |
| - .mat-slide-toggle-bar { |
75 |
| - background-color: $bar-disabled-color; |
76 |
| - } |
77 |
| - } |
78 |
| - |
79 | 62 | .mat-slide-toggle-thumb {
|
80 | 63 | @include _mat-theme-elevation(1, $theme);
|
81 | 64 | background-color: mat-color($mat-grey, $thumb-unchecked-hue);
|
|
0 commit comments