Yep, as you’ve noticed, by default the addon mimics Bootstrap’s default behavior so the sub menus are not animated in collapsible mode. So, you would need the following options:
collapsibleShowFunction: function($ul, complete) {
$ul.slideDown(200, complete);
},
collapsibleHideFunction: function($ul, complete) {
$ul.slideUp(200, function() {
$ul.parent().removeClass('open');
complete();
});
}
And also another small change in “jquery.smartmenus.bootstrap.js” – comment out/remove the following code:
,
'hide.smapi': function(e, menu) {
$(menu).parent().removeClass('open');
}
Alternatively, if you would like to avoid editing “jquery.smartmenus.bootstrap.js”, you could add the options directly in the HTML source in a data-sm-options
attribute:
https://www.smartmenus.org/docs/#data-sm-options
and add the following JS code on your page after the link to “jquery.smartmenus.bootstrap.js”:
$(function() {
$('ul.navbar-nav:not([data-sm-skip])').unbind('hide.smapi');
});
Cheers!