Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Anchor links #4

Open
dalmatiandots opened this issue May 1, 2016 · 3 comments
Open

Anchor links #4

dalmatiandots opened this issue May 1, 2016 · 3 comments
Assignees
Labels

Comments

@dalmatiandots
Copy link

dalmatiandots commented May 1, 2016

First I want to tell you that Menu is awesome.
I have one issue, found it today. I add some anchor links elements in menu. Everything is fine while menu is inline. But clicking an anchor link in "toggle" menu, will result with the page scrolls to the correct part of the page BUT the menu stays open. With "regular" links everything works fine.
For now I make a trick, instead of anchor #anchor-link I put absolute url http://domain/path/page-name.asp/#anchor-link and it works at all devices. For sure there is more elegant way to close the toggle ;)
Thanks in advance
Best
Ivana

@dalmatiandots
Copy link
Author

dalmatiandots commented May 1, 2016

Well, I decided that I don't need anchor links in toggle menu layout (mobile viewport). It's ok in inline menu layout but in toggle there is no point to have anchor links ;) (it's eaisier to scroll than cliks on menu links few times...)

@ivanvermeyen
Copy link
Contributor

Hi, I could add a click event for all navigation links except the ones that have the submenu class, and have it collapse the menu. I'll try to look into it this week. :)

@ivanvermeyen ivanvermeyen self-assigned this May 1, 2016
@dalmatiandots
Copy link
Author

You helped me twice ;-) Navigation works fantastic plus I realized that it makes no sense to have anchor links within the sub-menu (when navigation prepend to a menu icon). So I hide that sub-menu when the browser viewport is smaller than a specific width. But adding click event sound great, for some future projects because I want use your responsive-nav forever. It works so good! Thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants