Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found

Submitted

Interactive Rating Component using Sass, and BEM

#accessibility#bem#sass/scss

@garcialexco

Desktop design screenshot for the Interactive rating component coding challenge

This is a solution for...

  • HTML
  • CSS
  • JS
1newbie
View challenge

Design comparison


SolutionDesign

Solution retrospective


Hello! This is my solution for this challenge. πŸŽ‰

This is my first Javascript project ever and I had a ton of fun building it! Please be very honest about any improvements I can make, I'm learning!

Any ideas on how to improve in any way are greatly appreciated! Much thanks. πŸ™πŸ½πŸ‘»

Community feedback

@VCarames

Posted

Hey there! πŸ‘‹ Here is some feedback to further improve your code:

  • The figure and article elements are being used incorrectly ⚠️ and not needed for this challenge.
  • The β€œicons/illustrations” in this component are purely decorative. ⚠️ Their alt tag should be left blank to hide them from assistive technology.

More Info:πŸ“š

https://www.w3.org/WAI/tutorials/images/

  • The HTML for the ratings needs to be rewritten as it was done incorrectly ❌:

To ensure that the "rating buttons" are fully accessible πŸ’―, they need to be built using a form ⚠️.

  1. Everything will be wrapped inside a fieldset which will have a legend that is visually hidden using CSS.
  2. Inside, there should be five input radios and each input should have a label attached to it to make the β€œratings” accessible.
  3. The last thing you will want to include will be a button so users can submit their choice.

More Info: πŸ“š

MDN: Form Element

MDN: <input type="radio">

MDN: Field Set Element

  • Once the top is implemented , for your JS, the eventListener should be on the form ⚠️ as a submit.

More Info:πŸ“š

Click vs. Submit EventListeners

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.

Happy Coding! πŸ€–

Marked as helpful

0

@garcialexco

Posted

@vcarames Thank you very much! I appreciate the thorough response, it helps out immensely. I will tweak this challenge and resubmit. Again, your comment is very helpful and if I could give you another few "Mark as helpful" points, I totally would. πŸ‘

2

Please log in to post a comment

Log in with GitHub
Discord logo

Join 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