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

Stats Preview Card Component

@narahkaruna

Desktop design screenshot for the Stats preview card component coding challenge

This is a solution for...

  • HTML
  • CSS
1newbie
View challenge

Design comparison


SolutionDesign

Solution retrospective


Hello everyone! This is my solution for the Stats Preview Card Component

In the challenge, I used the ::before pseudo element to create an overlay for the header image. I tried to do that directly on the image, but I couldn't achieve my desired result. I read somewhere that you can't use pseudo elements on images that change. So I put the picture element in a div and use the div::before to create an overlay.

I had a hard time making the image big. How do you make the image bigger on desktop?

How did you achieve the overlay in this project?

Happy to hear feedback and advice

Community feedback

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