Streaming live at 10am (PST)

Change logo color when it reaches certain sections


#1

Wondering how I can change my logos colour when it reaches certain sections in my site. Im using some dark and light backgrounds and need my logo to change between White and Black when it reaches these sections.

Something like this: http://webdesign.tutsplus.com/tutorials/how-to-give-your-logo-the-slip-scroll-effect--cms-22274


#2

If you consider Webflow features, there's nothing out of the box to actually change the color of the logo when you reach a given section. However, with interactions, there are many ways to achieve the result. I did it once, here is how I setuped it.

  1. create a container for your logo. Give it the class "logo-container" and give it position:relative (it makes no difference, that's normal)
  2. Put the black version in it. Give to the black version (image) ONLY ONE class name, like "black-logo". Give it position:relative and z-index of 10.
  3. Now put the white version in the container too. It should appear after the black version. Set it to position:absolute, click on the button that positions it top left, and give it z-index of 11. Your white logo should now cover the black logo. (if you want the opposite by default, you know what to do, right? :smile: )

Ok, now we're going to create two interactions. The principle here is that when one section reaches the top, we show or hide the white logo. So create one interaction that tagrets the white logo and hides it (display:none) and one that does the opposite. Set the interaction for each section and adjust the threshold to set when the interaction kicks in.

I realize, writing this, that it may be difficult to adjust. let me try a better, simpler system.. I'll come back.


#3

Thanks for the reply Vincent. Just started with webflow and I got a bit stuck on the interactions and triggers. Will wait for your reply :smile:


#4

Hello, wondering if you were able to get a look at this @vincent


#5

Hi sorry I've been traveling :smile:

Well no, for the moment no luck, I stumble upn an issue with fixed position and zindex, that I can't seem to fix.


#6

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.