sydcanem / bootstrap-contextmenu

Context menu plugin for Twitter's Bootstrap framework
http://sydcanem.com/bootstrap-contextmenu/
645 stars 193 forks source link

Contextmenu's not dissapearing when another one is toggled #20

Closed Nickvda closed 11 years ago

Nickvda commented 11 years ago

Hey there,

The plugin does not seem to 'hide' (open) contextmenu's when a new one is opened. I saw something about it in the documentation, but it does not seem to work. Not when I use Javascript to toggle them, nor data-toggle.

sydcanem commented 11 years ago

Uhm, are you using multiple context-menu's?

James Santos Software/Web Applications Developer http://sydcanem.com

On Fri, May 3, 2013 at 8:31 PM, Nick van den Adel notifications@github.comwrote:

Hey there,

The plugin does not seem to 'hide' (open) contextmenu's when a new one is opened. I saw something about it in the documentation, but it does not seem to work. Not when I use Javascript to toggle them, nor data-toggle.

— Reply to this email directly or view it on GitHubhttps://github.com/sydcanem/bootstrap-contextmenu/issues/20 .

Nickvda commented 11 years ago

Yeah; a couple. 4 to be exact.

The issue lies with 2 specific menu's. One is toggled through Javascript and another one is called by the data-toggle. The problem lies that they overlap which is a tad annoying (for the user). So I wanted to hide all the other ones first; but I thought I read something about that being a standard feature. So it could be that I'm doing something wrong.

Right now I have (halfheartedly) solved it by simply removing the 'open' class. Was hoping to find something more elegant; though :)

sydcanem commented 11 years ago

I suspect something is wrong with the setup. I tested the 4 diff. context menus yet no overlapping of the menus.

Nickvda commented 11 years ago

I toggle them through data-target, is there something else that needs to be done? I followed the documentation.

sydcanem commented 11 years ago

Yes you're right. I was testing it with the same menu element #context-menu so there was no overlapping of context menus.

Nickvda commented 11 years ago

Do I understand correctly that you used multiple context-menu's with the same ID?

sydcanem commented 11 years ago

Yep.

Nickvda commented 11 years ago

Alright; thanks. I'll keep looking for a plugin then :)