So I am creating a website and have several logos to place in a section, how can I keep their default colour gray and when a user hovers on a logo, it reveals the actual colours of the logo, the logo has several colours so I can’t do a simple colour change to a single colour. For eg. the python logo should have both blue and yellow on hover and complete gray without hover.
I know how to change to a single colour only
2
Answers
You need two vwersions of your logo: gray and color, an then swap them on hover like
Use the
filter: grayscale()
in CSS.grayscale(1)
will grayout an image will on:hover
can usegrayscale(0)
to reset the grayout and show the image in color: