|
| 1 | +// stylelint-disable max-line-length |
| 2 | + |
1 | 3 | @use '@material/theme/theme-color' as mdc-theme-color;
|
2 | 4 | @use '@material/theme/theme' as mdc-theme;
|
3 |
| -@use '@material/list/evolution-mixins' as mdc-list-mixins; |
| 5 | +@use '@material/list' as mdc-list; |
4 | 6 | @use '@material/typography' as mdc-typography;
|
5 | 7 | @use '@material/ripple' as mdc-ripple;
|
6 | 8 | @use '../../mdc-helpers/mdc-helpers';
|
|
15 | 17 | // Since this will usually be rendered in an overlay,
|
16 | 18 | // we have explicitly set the default color.
|
17 | 19 | @include mdc-theme.prop(color, text-primary-on-background);
|
| 20 | + @include mdc-list.deprecated-item-disabled-text-color( |
| 21 | + mdc-list.$deprecated-text-disabled-color, $query: mdc-helpers.$mat-theme-styles-query); |
18 | 22 |
|
19 |
| - &:hover:not(.mdc-list-item--disabled), |
20 |
| - &:focus:not(.mdc-list-item--disabled), |
| 23 | + &:hover:not(.mdc-deprecated-list-item--disabled), |
| 24 | + &:focus:not(.mdc-deprecated-list-item--disabled), |
21 | 25 | &.mat-mdc-option-active,
|
22 | 26 |
|
23 | 27 | // In multiple mode there is a checkbox to show that the option is selected.
|
24 |
| - &.mdc-list-item--selected:not(.mat-mdc-option-multiple):not(.mdc-list-item--disabled) { |
| 28 | + &.mdc-deprecated-list-item--selected:not(.mat-mdc-option-multiple):not(.mdc-deprecated-list-item--disabled) { |
25 | 29 | $color: mdc-theme-color.$on-surface;
|
26 | 30 | background: rgba($color, mdc-ripple.states-opacity($color, hover));
|
27 | 31 | }
|
28 | 32 | }
|
29 | 33 |
|
30 | 34 | .mat-primary {
|
31 |
| - .mat-mdc-option.mdc-list-item--selected:not(.mdc-list-item--disabled) { |
32 |
| - @include mdc-list-mixins.list-primary-text-ink-color(primary, |
33 |
| - $query: mdc-helpers.$mat-theme-styles-query); |
| 35 | + .mat-mdc-option.mdc-deprecated-list-item--selected:not(.mdc-deprecated-list-item--disabled) { |
| 36 | + @include mdc-list.deprecated-item-primary-text-ink-color( |
| 37 | + primary, $query: mdc-helpers.$mat-theme-styles-query); |
34 | 38 | }
|
35 | 39 | }
|
36 | 40 |
|
37 | 41 | .mat-accent {
|
38 |
| - .mat-mdc-option.mdc-list-item--selected:not(.mdc-list-item--disabled) { |
39 |
| - @include mdc-list-mixins.list-primary-text-ink-color(secondary, |
40 |
| - $query: mdc-helpers.$mat-theme-styles-query); |
| 42 | + .mat-mdc-option.mdc-deprecated-list-item--selected:not(.mdc-deprecated-list-item--disabled) { |
| 43 | + @include mdc-list.deprecated-item-primary-text-ink-color( |
| 44 | + secondary, $query: mdc-helpers.$mat-theme-styles-query); |
41 | 45 | }
|
42 | 46 | }
|
43 | 47 |
|
44 | 48 | .mat-warn {
|
45 |
| - .mat-mdc-option.mdc-list-item--selected:not(.mdc-list-item--disabled) { |
46 |
| - @include mdc-list-mixins.list-primary-text-ink-color(error, |
47 |
| - $query: mdc-helpers.$mat-theme-styles-query); |
| 49 | + .mat-mdc-option.mdc-deprecated-list-item--selected:not(.mdc-deprecated-list-item--disabled) { |
| 50 | + @include mdc-list.deprecated-item-primary-text-ink-color( |
| 51 | + error, $query: mdc-helpers.$mat-theme-styles-query); |
48 | 52 | }
|
49 | 53 | }
|
50 | 54 | }
|
|
57 | 61 | @include mdc-helpers.mat-using-mdc-typography($config) {
|
58 | 62 | // MDC uses the `subtitle1` level for list items, but the spec shows `body1` as the correct
|
59 | 63 | // level. Class is repeated for increased specificity.
|
60 |
| - .mat-mdc-option .mdc-list-item__primary-text { |
| 64 | + .mat-mdc-option { |
61 | 65 | @include mdc-typography.typography(body1, $query: mdc-helpers.$mat-typography-styles-query);
|
62 | 66 | }
|
63 | 67 | }
|
|
0 commit comments