diff --git a/src/wp-content/themes/twentyfifteen/js/functions.js b/src/wp-content/themes/twentyfifteen/js/functions.js index eb4f8fa6d9..c530e42c28 100644 --- a/src/wp-content/themes/twentyfifteen/js/functions.js +++ b/src/wp-content/themes/twentyfifteen/js/functions.js @@ -13,6 +13,10 @@ // Add dropdown toggle that display child menu items. $( '.main-navigation .menu-item-has-children > a' ).after( '' ); + // Toggle buttons and submenu items with active children menu items. + $( '.main-navigation .current-menu-ancestor > button' ).addClass( 'toggle-on' ); + $( '.main-navigation .current-menu-ancestor > .sub-menu' ).addClass( 'toggled-on' ); + $( '.dropdown-toggle' ).click( function( e ) { var _this = $( this ); e.preventDefault();