Responsive menu when using anchor links

StatusIDPriorityType
Closed6648NormalZero Theme HTML
Profile Reply
graphicsgrove Client

Hi,

I’m currently building a one page website using the Zero HTML template but I’m having issues with the responsive menu when scrolling to links on the same page (I’m using anchor links). The responsive menu either stays open when clicking on an anchor link, or it gets stuck about half-way, so you are forced to scroll back up and click on the X to close the menu completely.

I’m assuming this can be fixed by modifying the responsive nav js file? Can you give me a pointer on what part I should modify?

Thanks!

Replies

User Description Posted On
Shindiri Support team Administrator

Hi,

 

You have a function for anchoring to target. At the moment where you call for 'click' event, simply add this line:
$('.responsive_nav .menu-closing').trigger('click');

 

Kind regards,

Br0

graphicsgrove Client

Thanks for your reply!

I was going through the js files but couldn't locate the function for anchoring to target. What file is it in exactly? I'm probably just overlooking something.

Shindiri Support team Administrator

Hi,

 

Theme's "js" folder, common.js file, anchorToTarget function.

 

Kind regards,
Br0

graphicsgrove Client

Ah, I hadn't looked at the common.js file yet. Thanks.

That said, I think I will make a different mobile nav as this one doesn't scroll along when users are further down on the page. And having to scroll up to get to the menu doesn't make much sense on a one pager.

But thank you for your assistance!

× This ticket is closed.