Skip to content

Commit b3c5188

Browse files
committed
fixup! feat(cdk/private): create cdk-visually-hidden style loader
1 parent ba6d80b commit b3c5188

File tree

1 file changed

+2
-33
lines changed

1 file changed

+2
-33
lines changed
Lines changed: 2 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -1,34 +1,3 @@
1-
/// This class can be applied to an element to make that element
2-
/// visually hidden while remaining available to assistive technology.
3-
.cdk-visually-hidden {
4-
border: 0;
5-
clip: rect(0 0 0 0);
6-
height: 1px;
7-
margin: -1px;
8-
overflow: hidden;
9-
padding: 0;
10-
position: absolute;
11-
width: 1px;
1+
@use '@angular/cdk';
122

13-
// This works around a Chrome bug that can cause the tab to crash when large amounts of
14-
// non-English text get wrapped: https://bugs.chromium.org/p/chromium/issues/detail?id=1201444
15-
white-space: nowrap;
16-
17-
// Avoid browsers rendering the focus ring in some cases.
18-
outline: 0;
19-
20-
// Avoid some cases where the browser will still render the native controls (see #9049).
21-
-webkit-appearance: none;
22-
-moz-appearance: none;
23-
24-
// We need at least one of top/bottom/left/right in order to prevent cases where the
25-
// absolute-positioned element is pushed down and can affect scrolling (see #24597).
26-
// `left` was chosen here, because it's the least likely to break overrides where the
27-
// element might have been positioned (e.g. `mat-checkbox`).
28-
left: 0;
29-
30-
[dir='rtl'] & {
31-
left: auto;
32-
right: 0;
33-
}
34-
}
3+
@include cdk.a11y-visually-hidden();

0 commit comments

Comments
 (0)