File tree 2 files changed +15
-2
lines changed
src/material-experimental/mdc-chips
2 files changed +15
-2
lines changed Original file line number Diff line number Diff line change 1
- @use ' @material/chips/chip' as mdc-chip ;
2
1
@use ' @material/chips/chip-theme' as mdc-chip-theme ;
3
2
@use ' @material/chips/chip-set' as mdc-chip-set ;
4
3
@use ' @material/theme/theme-color' as mdc-theme-color ;
5
4
@use ' @material/theme/color-palette' as mdc-color-palette ;
5
+ @use ' @material/typography' as mdc-typography ;
6
6
@use ' sass:color' ;
7
7
@use ' sass:map' ;
8
8
@use ' ../mdc-helpers/mdc-helpers' ;
80
80
theming .get-typography-config ($config-or-theme ));
81
81
@include mdc-chip-set .core-styles ($query : mdc-helpers .$mat-typography-styles-query );
82
82
@include mdc-helpers .mat-using-mdc-typography ($config ) {
83
- @include mdc-chip .without-ripple-styles ($query : mdc-helpers .$mat-typography-styles-query );
83
+ // Note that we don't go through MDC's typography mixin, because it assigns the styles to
84
+ // an inner element which makes it difficult for clients to customize. Instead we apply the
85
+ // same styles ourselves to the root.
86
+ .mat-mdc-standard-chip {
87
+ @include mdc-typography .typography (body2, $query : mdc-helpers .$mat-typography-styles-query );
88
+ }
84
89
}
85
90
}
86
91
Original file line number Diff line number Diff line change 73
73
width : 100% ;
74
74
}
75
75
76
+ // This element can be placed on a `button` node which usually has some user agent styles.
77
+ // Reset the font so that the typography from the root element can propagate down.
78
+ .mdc-evolution-chip__action--primary {
79
+ font : inherit ;
80
+ letter-spacing : inherit ;
81
+ white-space : inherit ;
82
+ }
83
+
76
84
// MDC sizes and positions this element using `width`, `height` and `padding`.
77
85
// This usually works, but it's common for apps to add `box-sizing: border-box`
78
86
// to all elements on the page which can cause the graphic to be clipped.
You can’t perform that action at this time.
0 commit comments