"demo-photographer" template: close menu on menu item click

1 reply · opened Jun 2, 2019

JjogjandrewJun 2, 2019

Hello:

I've adapted your demo-photographer.html template to a one-page scenario. I've added the class "one-page-menu" which scrolls to the correct page sections, but the menu stays open and must be closed manually. How can I make the menu close automatically when a menu item is clicked?

Thanks.

SSemicolon WebSTAFFJun 5, 2019

Hello,

Consider using the following JS Code:

jQuery(document).ready( function($){
	$('.global-menu__item').on( 'click', function(){
		$('.hamburger').trigger('click');
	});
});

This should definitely work fine. Hope this Helps!

Let us know if we can help you with anything else or if you find any further issues.

Have the same question, or something new?

Sign in to the Canvas dashboard to reply or open your own topic. Canvas owners get direct help from the SemiColonWeb team.

Reply on the dashboard