Skip to content
Advertisement

How to close the first menu collapse when the second one is open?

I have a site built with “Drupal 8” and “Bootstrap 3”. I created in the header, a menu collapse on the left and a menu collapse on the right.

How to close the first menu collapse when the second is open ?

And vice versa ?

Here are the two menus :

JavaScript

What should I add to my JS file.

Here is the contents of the file collapse.js :

JavaScript

Advertisement

Answer

Following the bootstrap doc, I think you could test something like this :

JavaScript
User contributions licensed under: CC BY-SA
8 People found this is helpful
Advertisement