Skip to content
  • Unlock Pro
  • Log in with GitHub
Solution
Submitted almost 2 years ago

Product Preview Card using Pure CSS & HTML

accessibility
Johan Jubin•90
@Johan-Jubin
A solution to the Product preview card component challenge
View live sitePreview (opens in new tab)View codeCode (opens in new tab)

Solution retrospective


Hi 🙌! This is my 4th project, I have few small doubts, pls be kind to help: 1.how do u like a child div to its parent element? for eg: I had set a border-radius:3%; on the card, but when I added 2 divs in it (one for the image, and the other for the description) , it doesn't inherit the border-radius I set on the parent element ie. the card. And I had to separately add border-radius to each one of them.

2.If u have seen my media query, it's quite long. Can u suggest few responsive methods to make the query short as possible?

3.why do percentage values NOT work good with buttons using border-radius? (Pls explain in simple terms, stackoverflow had a complicated answer).

4.Any other feedback is always welcome

Thank you !

Code
Loading...

Please log in to post a comment

Log in with GitHub

Community feedback

No feedback yet. Be the first to give feedback on Johan Jubin's solution.

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

Stay up to datewith new challenges, featured solutions, selected articles, and our latest news

Frontend Mentor

  • Unlock Pro
  • Contact us
  • FAQs
  • Become a partner
  • Use cases

Explore

  • Learning paths
  • Challenges
  • Solutions
  • Articles

Community

  • Discord
  • Guidelines

For companies

  • Hire developers
  • Train developers
© Frontend Mentor 2019 - 2025
  • Terms
  • Cookie Policy
  • Privacy Policy
  • License