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 with CSS Grid and Flex

@manuvh152

Desktop design screenshot for the Stats preview card component coding challenge

This is a solution for...

  • HTML
  • CSS
1newbie
View challenge

Design comparison


SolutionDesign

Community feedback

Hassia Issah 50,670

@Hassiai

Posted

For the color of the image, give .image-header a background-color of soft violet, and the img a width of 100% instead of fixed max-width value, object-fit: cover, mix-blend-mode: multiply and opacity: 0.8.

.image-header{
background-color: hsl();
}
img{
width: 100%;
height: 100%;
object-fit: cover;
mix-blend-mode: multiply;
opacity: 0.8;
}

the no need to style . contain and redeclare display: grid and its properties to center .card.

In the desktop design , give .image-header a width of 50% and .info a width of 50%. In the media query, increase the width of card, for a responsive content replace the width in .card with max-width ..card{max-width: 25rem;} 25rem is 400px.

Hope am helpful.

Well done for completing this challenge. HAPPY CODING

Marked as helpful

0

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