scss: utils: add sr-only utility mixin & class (36909)
This commit is contained in:
parent
37af4b4ac8
commit
9b37bd3edb
|
@ -38,3 +38,20 @@ $black: #000000 !default;
|
|||
@function is-positive-number($value) {
|
||||
@return type-of($value) == 'number' and $value > 0;
|
||||
}
|
||||
|
||||
// Only display content to screen readers
|
||||
@mixin sr-only {
|
||||
position: absolute !important;
|
||||
width: 1px !important;
|
||||
height: 1px !important;
|
||||
padding: 0 !important;
|
||||
margin: -1px !important;
|
||||
overflow: hidden !important;
|
||||
clip: rect(0, 0, 0, 0) !important;
|
||||
white-space: nowrap !important;
|
||||
border: 0 !important;
|
||||
}
|
||||
|
||||
.sr-only {
|
||||
@include sr-only();
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue