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

Component page

@Auto-Yahwin

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


I can now overlay my background image with colors and effects, thanks to the community for the response.

Community feedback

@AbbyNyakara

Posted

use the css filter property to add the opacity. This was how i did mine

img{ filter: opacity(35%) drop-shadow(0 0 hsl(277, 64%, 61%)); }

Marked as helpful

1

@Auto-Yahwin

Posted

@AbigaelN2021 thanks for the response. I haven't used drop-shadow before. I'll look it up to fully understand, then apply it to my project.

0
darryncodes 6,430

@darryncodes

Posted

Hi Solomon,

  • you could try adding a solid linear-gradient to a background image: background-image: linear-gradient(hsl(277, 64%, 61%), hsl(277, 64%, 61%) ), url(../your/image-filepath); this will help achieve the purple colour to match the design, rather than the overlay approach
  • you also need to explore background-blend-mode. (multiply usually does the trick)

Good luck!

Marked as helpful

0

@Auto-Yahwin

Posted

@darryncodes, is there any way I can reduce the opacity of the color assuming am using the first approach (I.e the linear-gradient method)?

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