-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
used gov uk design system styles for visually hidden since they have …
…already been tested
- Loading branch information
1 parent
2693175
commit 291b978
Showing
2 changed files
with
8 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,16 @@ | ||
/// Used to hide an element visually, but keeping it accessible for | ||
/// accessibility tools. | ||
|
||
/// styles referenced from GOV.UK design system | ||
/// https://github.com/h5bp/main.css/issues/12#issuecomment-451965809 | ||
@mixin visually-hidden { | ||
clip-path: inset(50%); | ||
height: 1px; | ||
width: 1px; | ||
overflow: hidden; | ||
position: absolute; | ||
white-space: nowrap; | ||
width: 1px; | ||
height: 1px; | ||
margin: 0; | ||
padding: 0; | ||
overflow: hidden; | ||
clip-path: inset(50%); | ||
border: 0; | ||
white-space: nowrap; | ||
} |