Forums

The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums Design Make centered logo scroll into fixed header

  • This topic is empty.
Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #259311
    flightbulb
    Participant

    My splash page has a centered logo. As you scroll down, the logo needs to scale down in size and fit into a fixed header on the top nav bar. I would like tips on how to do this.
    Thanks!

    #259312
    Beverleyh
    Participant

    You’d need JavaScript; probably using an eventListener to “watch” for when the logo scrolls to a desirable position, at which point new CSS comes in to play to alter its size and final placement in the layout.

    Googling terms like ” scroll to position JavaScript” or “scroll in to view JavaScript” will give you places to start your research. And here’s a blog post of mine from a few months ago that may help too http://blog.fofwebdesign.co.uk/41-add-classes-to-an-element-when-scrolled-into-viewport Demos are included.

Viewing 2 posts - 1 through 2 (of 2 total)
  • The forum ‘Design’ is closed to new topics and replies.