Skip to content

Commit

Permalink
fix(Checkbox): update focus styles (#7620)
Browse files Browse the repository at this point in the history
* fix(Checkbox): update focus styles

* fix(Checkbox): reduce outline offset

Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com>
  • Loading branch information
tw15egan and kodiakhq[bot] authored Jan 25, 2021
1 parent b62628f commit 0dead00
Showing 1 changed file with 2 additions and 10 deletions.
12 changes: 2 additions & 10 deletions packages/components/src/components/checkbox/_checkbox.scss
Original file line number Diff line number Diff line change
Expand Up @@ -153,16 +153,8 @@
// Indeterminate
.#{$prefix}--checkbox:indeterminate:focus + .#{$prefix}--checkbox-label::before,
.#{$prefix}--checkbox-label[data-contained-checkbox-state='mixed'].#{$prefix}--checkbox-label__focus::before {
// Must use box-shadow for appearance of multiple borders with rounded corners.
box-shadow: 0 0 0 2px $inverse-01, 0 0 0 4px $focus;

// Windows, Firefox HCM Fix
@media screen and (-ms-high-contrast: active),
screen and (prefers-contrast) {
// `highlightText` is a CSS2 system color to help improve colors in HCM
outline: 1px solid highlightText;
outline-offset: 2px;
}
outline: 2px solid $focus;
outline-offset: 1px;
}

//----------------------------------------------
Expand Down

0 comments on commit 0dead00

Please sign in to comment.