<?php

/**
 * Displays the main navigation menu
 *
 * @package WordPress
 * @subpackage IZI_THEME
 * @since 1.0.0
 */

?>

<!-- NAVBAR BEGIN -->
<header class="fixed-top">
	<nav class="navbar navstyle navbar-expand-lg py-4">
		<div class="container">
			<a class="navbar-brand" href="<?php bloginfo('url'); ?>">
				<svg xmlns="http://www.w3.org/2000/svg" x="0px" y="0px" width="64" height="64" viewBox="0 0 64 64" style="fill:#d7d7d7;">
					<path d="M37.289 28.973l7.139-7.313L15.401 6.325C14.7 5.955 13.95 5.898 13.27 6.072L37.289 28.973zM11.084 8.284C11.033 8.505 11 8.736 11 8.978v46.044c0 .272.036.531.101.777l22.911-23.469L11.084 8.284zM37.248 35.723L13.355 57.949c.657.147 1.374.081 2.046-.274l28.447-15.029L37.248 35.723zM58.979 29.347l-9.489-5.013-8.638 8.036 8.003 7.631 10.124-5.349C61.111 33.526 61.111 30.474 58.979 29.347z">
					</path>
				</svg>
				<h1 class="naming ms-2">IZI Séries</h1>
			</a>
			<button class="navbar-toggler collapsed" type="button" data-bs-toggle="collapse" data-bs-target="#navbarCollapse" aria-controls="navbarCollapse" aria-expanded="false" aria-label="Toggle navigation">
				<span class="navbar-toggler-icon"></span>
				<span></span>
				<span></span>
			</button>
			<?php
			if (has_nav_menu('menu-1')) {
				wp_nav_menu(array(
					'menu'              => 'menu-1',
					'theme_location'    => 'menu-1',
					'container'       	=> 'div',
					'container_class' 	=> 'collapse navbar-collapse',
					'container_id'    	=> 'navbarCollapse',
					'menu_class'      	=> 'navbar-nav ms-auto mb-2 mb-lg-0 fs-5',
					'menu_id'         	=> '',
					'echo'            	=> true,
					'fallback_cb'     	=> 'wp_page_menu',
					'before'          	=> '',
					'after'           	=> '',
					'link_before'     	=> '',
					'link_after'      	=> '',
					'depth'           	=> 2,
					'walker'         	=> new bootstrap_5_wp_nav_menu_walker()
				));
			} else
				echo "Veuillez assigner un menu dans l'administration Wordpress -> Apparence -> Menus -> Gérer les emplacements";
			?>
		</div>
	</nav>
</header>
<!-- NAVBAR END -->