Skip to content

Commit c791d6a

Browse files
authored
fix(material-experimental/mdc-radio): include form field core theme styles (#22071)
* fix(material-experimental/mdc-radio): include form field core theme styles * fix(material-experimental/mdc-slide-toggle): nest style under classname
1 parent d8935d1 commit c791d6a

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

src/material-experimental/mdc-radio/_radio-theme.scss

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,8 @@
2020
$mdc-radio-disabled-circle-color: rgba(mdc-theme-prop-value(on-surface), 0.38) !global;
2121

2222
.mat-mdc-radio-button {
23+
@include mdc-form-field-core-styles($query: mdc-helpers.$mat-theme-styles-query);
24+
2325
&.mat-primary {
2426
@include mdc-radio-without-ripple($query: mdc-helpers.$mat-theme-styles-query);
2527
}

src/material-experimental/mdc-slide-toggle/_slide-toggle-theme.scss

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,11 +28,11 @@
2828
$mdc-switch-disabled-thumb-color: mdc-theme-prop-value(surface) !global;
2929
$mdc-switch-disabled-track-color: mdc-theme-prop-value(on-surface) !global;
3030

31-
@include mdc-form-field-core-styles($query: mdc-helpers.$mat-theme-styles-query);
32-
3331
// MDC's switch doesn't support a `color` property. We add support
3432
// for it by adding a CSS class for accent and warn style.
3533
.mat-mdc-slide-toggle {
34+
@include mdc-form-field-core-styles($query: mdc-helpers.$mat-theme-styles-query);
35+
3636
.mdc-switch__thumb-underlay::after, .mat-ripple-element {
3737
background: $mdc-switch-toggled-off-ripple-color;
3838
}

0 commit comments

Comments
 (0)