Stats Preview Card - HTML/CSS/Flexbox

Solution retrospective
How do you overlay a color on top of an image?
Please log in to post a comment
Log in with GitHubCommunity feedback
- @nakoyawilson
You can try using the mix-blend-mode css property to get the overlay using the following steps:
-
Add a background color to the div the image is contained in.
.wrapper-right { background-color: hsl(277, 64%, 61%); }
-
Use mix-blend-mode and opacity for the image itself:
img { mix-blend-mode: multiply; opacity: 0.75; }
Marked as helpful -
- @zacharyboelter
Amazing!
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