Created
December 9, 2019 04:35
-
-
Save ibndawood/30d7b65e603a2f7b542c81bd056d3f4a to your computer and use it in GitHub Desktop.
Electro v2 - Light Off-Canvas Navigation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function electro_off_canvas_nav() { | |
$classes = ''; | |
if( apply_filters( 'electro_off_canvas_nav_hide_in_desktop', false ) ) { | |
$classes = 'off-canvas-hide-in-desktop'; | |
} | |
?> | |
<div class="off-canvas-navigation-wrapper <?php echo esc_attr( $classes ); ?>"> | |
<div class="off-canvas-navbar-toggle-buttons clearfix"> | |
<button class="navbar-toggler navbar-toggle-hamburger " type="button"> | |
<i class="ec ec-menu"></i> | |
</button> | |
<button class="navbar-toggler navbar-toggle-close " type="button"> | |
<i class="ec ec-close-remove"></i> | |
</button> | |
</div> | |
<div class="off-canvas-navigation light" id="default-oc-header"> | |
<?php | |
wp_nav_menu( array( | |
'theme_location' => 'hand-held-nav', | |
'container' => false, | |
'menu_class' => 'nav nav-inline yamm', | |
'fallback_cb' => 'electro_handheld_nav_fallback', | |
'walker' => new wp_bootstrap_navwalker() | |
) ); | |
?> | |
</div> | |
</div> | |
<?php | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hi, is it possible to create this same menu but superimposed(overlay) as the canvas cart?