Design comparison
SolutionDesign
Solution retrospective
- The font style for both "Gabrielle Essence Eau De Parfum" and "$149.99" is the same, and the only difference is the color. Is there a more efficient way to write the CSS code?
- How do I make the card's size responsive to the user's screen size? (eg. @media rule?)
- The challenge description says user should be able to "see hover and focus states for interactive elements". What does this mean?
Thank you for your answers in advance!
Community feedback
- @VCaramesPosted almost 2 years ago
Hey there! 👋 Here is some feedback to further improve your code:
Regarding your questions,
- The way you applied it is fine but your class names need improvement. A naming methodology a lot of beginner users find easy to implement is the BEM methodology.
- You will use responsive properties and a
media query
to make the layout responsive. - When a users mouse hovers/ keyboard interacts with said interactive element it should change colors and/or have a border displaying.
- The image’s
alt tag
description needs to be improved upon ⚠️. Assume that you are describing the image to a someone over the phone.
More Info:📚
https://www.w3.org/WAI/tutorials/images/
- This component requires the use of two images 🎑 at different breakpoints ⚠️. The
picture
element will facilitate this.
Here is how it looks like implemented: EXAMPLE
Syntax:
<picture> <source media="(min-width: )" srcset=""> <img src="" alt=""> </picture>
More Info:📚
https://www.w3schools.com/html/html_images_picture.asp
- The only heading ⚠️ in this component, is the name of the perfume; “Gabrielle Essence Eau De Parfum” . The rest of the text should be wrapped in a
paragraph
element.
- Do not uppercase ❌ "perfume" in HTML as it is not accessible friendly. Instead you will want to style it in CSS.
- It is best practice ✅ to use,
classes
for styling purposes, while usingids
solely for JavaScript.
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 helpful1@mochimoooPosted almost 2 years ago@vcarames Thank you so much for your feedback! I will def take these into account and read the info's you linked. Hope to keep in touch!
0
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