Design comparison
SolutionDesign
Solution retrospective
.visually-hidden was the most difficult part of this project. I am not quite sure how part of the code below works. Any help will be greatly appreciated.
.visually-hidden:not(:focus):not(:active) {
clip: rect(0 0 0 0);
clip-path: inset(50%);
/* Shrink an element into a 1px square */
width: 1px;
height: 1px;
/* Hiding any overflow */
overflow: hidden;
/* absolutely positioning the element to remove any trace of it from the normal document flow. */
position: absolute;
white-space: nowrap;
}
Community feedback
Please log in to post a comment
Log in with GitHubJoin our Discord community
Join thousands of Frontend Mentor community members taking the challenges, sharing resources, helping each other, and chatting about all things front-end!
Join our Discord