This is a solution to the Interactive rating component challenge on Frontend Mentor. Frontend Mentor challenges help you improve your coding skills by building realistic projects.
Users should be able to:
- View the optimal layout for the app depending on their device's screen size
- See hover states for all interactive elements on the page
- Select and submit a number rating
- See the "Thank you" card state after submitting a rating
- Solution URL: FrontEnd Mentor
- Live Site URL: GitHub Pages
- Semantic HTML5 markup
- Flexbox
- Mobile-first workflow
- How to use labels as radio buttons
- :has() parent selector
- style.display="none"/"block" performs faster than classList.add()/remove()
- How to use linear gradients
- CSS-Tricks - I used the CSS :has() selector to select the parent label when a radio button was checked.
- MeasureThat.net - This performance benchmark shows that style.display="none"/"block" performs faster than classList.add()/remove()
- Frontend Mentor - @corjon