Stats Preview Card Component solution with Grid & Flexbox
Design comparison
Solution retrospective
This is my first solution submission for this particular challenge. Please feel free to point out the things I've inevitably missed/looked over. I tried real hard to nail the color overlay for the image but couldn't quite get there in the end. Oh well, this is my best shot overall!
Community feedback
- @dewslysePosted about 3 years ago
Hello @ZenCode95. Congrats on your submission. However your preview card isn't quite responsive. You need to set up a media query targeting mobile devices and style the card as shown in the design.
The overlay can be achieved using one of the <blend-mode> properties in css (
background-blend-mode
ormix-blend-mode
). A value ofmultiply
on these properties should do the trick..main-card--img { background-color: hsl(277, 64%, 61%); background-blend-mode: multiply; }
In this case you won't need
img-overlay
Happy coding
0@ZenCode95Posted about 3 years ago@dewslyse Hey there, thanks for the input. On the matter of responsiveness... Is it an actual requirement to include mobile as well as desktop layouts for these challenges? I had assumed that because each challenge provides examples of both it was ultimately a choice.
Yes, I had actually spent some time tinkering with background-blend-mode but couldn't quite get the result I wanted. Guess I'll have to revise that then and see if I can make it work I suppose.
0@dewslysePosted about 3 years ago@ZenCode95 This is from the project brief ⤵️
"Your users should be able to:
- View the optimal layout depending on their device's screen size"
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