Skip to content

Commit

Permalink
fix(material-experimental/mdc-chips): add feature targeting to… (#18830)
Browse files Browse the repository at this point in the history
The MDC chips theme was including some styles without a feature target, resulting in some unnecessary styles being added.
  • Loading branch information
crisbeto committed Mar 21, 2020
1 parent 76e8a38 commit 54bbb90
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions src/material-experimental/mdc-chips/_chips-theme.scss
Expand Up @@ -10,27 +10,27 @@
$accent: mat-color(map-get($theme, accent));
$warn: mat-color(map-get($theme, warn));
$background: map-get($theme, background);

$unselected-background: mat-color($background, unselected-chip);

.mat-mdc-chip {
@include mdc-chip-fill-color-accessible($unselected-background);
@include mdc-chip-fill-color-accessible($unselected-background,
$query: $mat-theme-styles-query);

&.mat-primary {
&.mdc-chip--selected, &.mat-mdc-chip-highlighted {
@include mdc-chip-fill-color-accessible($primary);
@include mdc-chip-fill-color-accessible($primary, $query: $mat-theme-styles-query);
}
}

&.mat-accent {
&.mdc-chip--selected, &.mat-mdc-chip-highlighted {
@include mdc-chip-fill-color-accessible($accent);
@include mdc-chip-fill-color-accessible($accent, $query: $mat-theme-styles-query);
}
}

&.mat-warn {
&.mdc-chip--selected, &.mat-mdc-chip-highlighted {
@include mdc-chip-fill-color-accessible($warn);
@include mdc-chip-fill-color-accessible($warn, $query: $mat-theme-styles-query);
}
}
}
Expand Down

0 comments on commit 54bbb90

Please sign in to comment.