Submitted 10 months ago
Responsive landing page with Astro and Tailwind v4 alpha
#astro#tailwind-css
@Brian-Pob
Design comparison
SolutionDesign
Solution retrospective
What are you most proud of, and what would you do differently next time?
Since icons were not provided for some reason (or I forgot to copy them over haha), I used Phosphor Icons for my social media links.
Community feedback
- @0xabdulkhaliqPosted 10 months ago
Hello there 👋. Congratulations on successfully completing the challenge! 🎉
- I have a suggestion regarding your code that I believe will be of great interest to you.
ANCHOR ELEMENT 🔴:
- The social anchors on footer is not properly accessible due to wrong implementation of
sr-only
classes, because currently contents of thosesr-only
span
s are having "Social Media 1, 2, 3" respectively. We want to make sure to utilizesr-only
classes wisely, current implementation may confuse users while announcing to users.
- So instead of relying on
sr-only
classes you can directly usearia-label
attribute for<a>
element it will help provide more context to users with visual impairments who use assistive technologies such as screen readers to access your website.
- When a screen reader encounters an anchor tag with a social link, it may announce the link's text content, such as "Facebook" or "Twitter," by including an
aria-label
attribute that points to a nearby element containing a description of the link's purpose, you can provide more context and clarity to the user.
- By providing this additional information, you can help users with visual impairments to better understand the purpose and value of social links, and encourage them to engage with your content. This can ultimately improve the user experience on your website, and make it more accessible and inclusive for all users.
- Example:
<a href="#" aria-label="Facebook profile of Huddle"> <svg>...</svg> </a>
- After implementing
aria-label
fora
elementssr-only
span elements are not needed, we make our solution more accessible by just using native accessibility features of HTML.
- If you have any questions or need further clarification, you can always check out
my submission
and/or feel free to reach out to me.
.
I hope you find this helpful 😄 Above all, the solution you submitted is great !
Happy coding!
Marked as helpful1
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