Created
March 26, 2025 05:49
-
-
Save jmabbas/0d1af94c8d6661bbc7b4babbac25d8b3 to your computer and use it in GitHub Desktop.
Silicon Offcanvas
This file contains hidden or 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 silicon_header_navbar_offcanvas() { | |
$header_class = silicon_custom_sticky_header_options(); | |
$dark_css = strpos( $header_class, 'navbar-dark' ) ? ' bg-dark' : ''; | |
?> | |
<div id="navbarNav" class="offcanvas offcanvas-end<?php echo esc_attr( $dark_css ); ?>"> | |
<div class="offcanvas-header border-bottom"> | |
<h5 class="offcanvas-title"><?php echo esc_html__( 'Menu', 'silicon' ); ?></h5> | |
<button type="button" class="btn-close" data-bs-dismiss="offcanvas" aria-label="Close"></button> | |
</div> | |
<div class="offcanvas-body"> | |
<?php silicon_navbar_nav(); ?> | |
</div> | |
<div class="offcanvas-footer border-top"> | |
<?php silicon_toggle_custom_button_options(); ?> | |
</div> | |
</div> | |
<?php | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment