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

Hide the menu after a link is clicked #4

Closed
dandrews opened this issue Dec 6, 2013 · 6 comments
Closed

Hide the menu after a link is clicked #4

dandrews opened this issue Dec 6, 2013 · 6 comments

Comments

@dandrews
Copy link
Contributor

dandrews commented Dec 6, 2013

Thanks for writing this plugin. Is there a simple way or extension to hide the menu after a link in the menu is clicked?

@dandrews
Copy link
Contributor Author

dandrews commented Dec 6, 2013

I added an option closeOnClickInside: true and the following snippet:

if(o.closeOnClickInside) {
  $('.cbp-spmenu a').click(function(e){
    jPushMenu.close();
  });
}

@dandrews dandrews closed this as completed Dec 6, 2013
@takien
Copy link
Owner

takien commented Dec 6, 2013

nice.

@takien
Copy link
Owner

takien commented Dec 6, 2013

Please fork and push so I can merge it. thanks.

@pascalf22
Copy link

Hello,
Thanks for this comment.... where do i should place this code : closeOnClickInside: true

thanks a lot !

@pascalf22
Copy link

Hello,

I need that the menu doesn't close on a clicl on it... so i try this..

jQuery(document).ready(function($) {
$('.toggle-menu').jPushMenu({closeOnClickInside: false});

});

But it close when i cick...
I need it because i have a textbox in the menu to search... and when i click in the textbox.. the menu close...

thanks

@mimomedia
Copy link

Same issue here, any idea?

Thank you & Regards

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

No branches or pull requests

4 participants