We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent dd9f267 commit 264f306Copy full SHA for 264f306
src/lib/slide-toggle/slide-toggle.scss
@@ -243,6 +243,14 @@ $mat-slide-toggle-bar-track-width: $mat-slide-toggle-bar-width - $mat-slide-togg
243
244
.mat-slide-toggle-bar {
245
background: #fff;
246
+
247
+ // As a focus indication in high contrast mode, we add a dotted outline to the slide-toggle
248
+ // bar. Since the bar element does not have any padding, we need to specify an outline offset
249
+ // because otherwise the opaque thumb element will hide the outline.
250
+ .mat-slide-toggle.cdk-keyboard-focused & {
251
+ outline: 1px dotted;
252
+ outline-offset: ($mat-slide-toggle-height - $mat-slide-toggle-bar-height) / 2;
253
+ }
254
}
255
256
0 commit comments