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

Product preview card component solution

@RREYES0424

Desktop design screenshot for the Product preview card component coding challenge

This is a solution for...

  • HTML
  • CSS
1newbie
View challenge

Design comparison


SolutionDesign

Solution retrospective


I have problems with the responsive design, I don't know how to remove the scroll in the mobile version.

Community feedback

@mbonamensa

Posted

Hi Ricardo, well done for completing this challenge!

Few tips and feedback

  • The live site URL was flagged in my browser as a deceptive site. I think this because of how it is named. Instead of using the names generated by Netlify, you could try renaming the subdomain. For example: instead of regal-tiramisu-0e2998.netlify.app, try product-card-component.netlify.app
  • Use <picture> in rendering the images for the different screen sizes instead of using display: none in your CSS to render them on the screen. Like the code below:
 <picture>
    <source media="(max-width: 650px)" srcset="./img/image-product-mobile.jpg">
    <img src="./img/image-product-desktop.jpg" alt="Perfume with green leaf props">
  </picture> 
  • I found that using min-height: 100vh instead of height:100vh and removing the width: 100vw solved the issue with the scroll.

Happy coding!

1

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