Hi! For some reason, the mobile menu on our site won’t close when a menu item is tapped. Is there a way to remedy this?
Thank you so much!
Hi! For some reason, the mobile menu on our site won’t close when a menu item is tapped. Is there a way to remedy this?
Thank you so much!
Hello Jeanne,
The mobile menu remains open after a menu item is tapped. It would require a bit of customization to make the mobile menu close when you click/tap a menu item but this is something that goes beyond the scope of our support.
However, to get you started, try adding this code in X > Theme Options > CSS:
jQuery(function($) {
$('.mobile .x-nav a').on('touchend click', function(){
$('.x-btn-navbar').click();
});
});
Kindly note that since this is a custom code that changes the default behavior/display of the theme, you will be responsible to maintain or update the code in case you require further changes or if the code stops working in future updates. If you are uncertain how to proceed, it would be best to get in touch with a developer.
Hope this helps.
Oh my goodness!! Thank you so much, Jade! That appears to work perfectly (in JS) with no adverse behavioral issues.
I SO appreciate the incredible support from ThemeCo. When my company switched over to WordPress years ago, we worked with several theme developers and no one came close to level of support you guys offer. Now ALL of our sites are done in X. 
THANK YOU AGAIN for all you do!
We’re glad that we could help
and you’re most welcome!
This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.