GithubHelp home page GithubHelp logo

Menu links don't work about fixed-nav HOT 7 OPEN

adtile avatar adtile commented on August 21, 2024
Menu links don't work

from fixed-nav.

Comments (7)

banbanbana avatar banbanbana commented on August 21, 2024 1

Same issue for me. My code is live at www.edgeshelf.com. It only happens when you scroll past one of the areas linked to by the menu (in this case, if I scroll down to the footer past the last menu item, which is "Contact Us"). If I scroll back up into any area linked to by the menu, it works again.

from fixed-nav.

slsriehl avatar slsriehl commented on August 21, 2024 1

I've played around with happybana's code and it seems like the fixed nav links work if the page is positioned more than 62px up from the bottom (62px is also the height of the fixed nav with the page scrolled down). Maybe it's something with the offset, position: fixed, and the scroll event listener.

from fixed-nav.

banbanbana avatar banbanbana commented on August 21, 2024 1

For my issue, adding the offset to that line worked!

from fixed-nav.

arielsalminen avatar arielsalminen commented on August 21, 2024

@slsriehl Do you think you could share the code you are using? Iā€™m wondering if something in the CSS is causing this.

from fixed-nav.

slsriehl avatar slsriehl commented on August 21, 2024

@viljamis Sure, at:
http://www.riehlhelp.com/swg/index.html
http://www.riehlhelp.com/swg/frn/styles.css

The rest fixed-nav files are under their original names at http://www.riehlhelp.com/swg/frn/.

from fixed-nav.

timi-codes avatar timi-codes commented on August 21, 2024

Seriously Battling with the same issue.
I get this in my console when a click on the link
Unable to preventDefault inside passive event listener due to target being treated as passive.
Have you found any fix for this.

from fixed-nav.

banbanbana avatar banbanbana commented on August 21, 2024

After poking around a bit, I think the issue might be with this line. The second condition is making the scroll stop before the end of the document. Maybe because it doesn't know about the offset in fixed-responsive-nav.js?

scroll.js, line 148
if ( position == endLocation || currentLocation == endLocation || ( (window.innerHeight + currentLocation) >= document.body.scrollHeight ) ) {

from fixed-nav.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    šŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. šŸ“ŠšŸ“ˆšŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ā¤ļø Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.