Find Answers and Get Support › Forums › Stego – Food Truck & Restaurant Theme › Feature Requests › Close Automatically the Mobile Menu After Clicking on an Anchor Link
- This topic has 7 replies, 2 voices, and was last updated 2 years, 6 months ago by Manathan.
-
AuthorPosts
-
NeoParticipant@neocortex
- 5 Topics
- 10 Posts
Dear team,
is there a way to make the menu automatically close after pressing a menu link on the mobile version and not staying open, hindering the view? For the UX it is quite bothersome. Someone who presses a link wants to see the content and not have to press the “X” manually everytime.
Much appreciated.
Best regards
January 11, 2022 at 09:27 #38029@themodactyl- 0 Topics
- 6587 Posts
Hi Neo,
the navigation should be closed when going to another page. 🤔
My best guess is that your issue might probably caused by some conflicting third party plugin or some extra code snippet as we don’t encounter this issue with our demos.
Could you deactivate all plugins that have not been installed with your theme during its setup and all existing custom PHP code snippets please? And then, could you confirm me that the issue is still persisting please?
Please also make sure that you have the latest theme version and that all recommended plugins are up-to-date. Finally, you could also consider clearing all activated caching system as well as your browser cache before investigating any further. If you want to read more on what browser cache is and how to clear it, here is an article that might help you: How to Clear Internet Cache in Every Major Browser.
We’re waiting for your feedback.
Best,
January 11, 2022 at 12:58 #38045NeoParticipant@neocortex- 5 Topics
- 10 Posts
Hi Manathan,
thank you for your answer. I forgot to mention, that it is a scrolling page with anchors, and it only happens on the scrolling page. The menu closes when pressing a link, where it goes to another page.
Thank you!
Best regards,
NeoJanuary 12, 2022 at 19:57 #38063@themodactyl- 0 Topics
- 6587 Posts
Hi Neo,
Thank you for your patience. 🙏🏼
It would be indeed very nice to close automatically the menu when clicking on an anchor. Please be aware that it is not standard behaviour with our theme and WordPress.
However, note that I took the liberty to move this topic to our Feature Requests forum. As your idea could be a nice addition to our theme, we will implement this feature if other community members upvote your request.
We’ll keep you informed. Thank you very much for contributing to this theme!
Best regards,
January 17, 2022 at 13:36 #38162NeoParticipant@neocortex- 5 Topics
- 10 Posts
Hello Manathan,
that’s unfortunate. Thank you for bringing it to the Feature Request forum. Is there a link where I can observe the progress on the same?
Also is there a quick workaround for this through custom css? Or I guess this would be javascript?
Thank you!
Best regards.
February 5, 2022 at 16:59 #38568NeoParticipant@neocortex- 5 Topics
- 10 Posts
Hi,
to my investigation it seems to be a few lines of code which should be possible to implement without much effort (hopefully).
The code should look sth like this:
$( '.menu a' ).on("click", function(){ $('.menu').removeClass('open'); });
In the case of this theme, it would mean switching back from navbar-collapse-show to navbar-collapse-hide, when a user presses a list menu item.
I cannot think of a situation where this would not be wanted, so I think it is quite necessary. Also scroll pages on mobile view are not uncommon.
I hope it helps and can be implemented quickly without much effort.
February 5, 2022 at 17:12 #38569@themodactyl- 0 Topics
- 6587 Posts
Hi Neo,
Thank you for sharing this with us.
It might seems quite simple, but it is not. This feature is specific on your site, but it might create some issues with other menus (mega menu, accordion menu, BuddyPress menu, …).
In order ta add this feature, it will require some investigation to make sure it will be compatible on every website using our theme. There is a reason that WordPress did not integrate this in they core.
Be sure that we will implement this feature if other community members upvote your request. 🙂
Thank you for your contribution. 🙏🏼
Best,
February 7, 2022 at 11:03 #38591 -
AuthorPosts
You must be logged in to reply to this topic.