File tree Expand file tree Collapse file tree 2 files changed +15
-2
lines changed
src/material-experimental/mdc-chips Expand file tree Collapse file tree 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 ;
21@use ' @material/chips/chip-theme' as mdc-chip-theme ;
32@use ' @material/chips/chip-set' as mdc-chip-set ;
43@use ' @material/theme/theme-color' as mdc-theme-color ;
54@use ' @material/theme/color-palette' as mdc-color-palette ;
5+ @use ' @material/typography' as mdc-typography ;
66@use ' sass:color' ;
77@use ' sass:map' ;
88@use ' ../mdc-helpers/mdc-helpers' ;
8080 theming .get-typography-config ($config-or-theme ));
8181 @include mdc-chip-set .core-styles ($query : mdc-helpers .$mat-typography-styles-query );
8282 @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+ }
8489 }
8590}
8691
Original file line number Diff line number Diff line change 7373 width : 100% ;
7474 }
7575
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+
7684 // MDC sizes and positions this element using `width`, `height` and `padding`.
7785 // This usually works, but it's common for apps to add `box-sizing: border-box`
7886 // 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