|
| 1 | +<?php |
| 2 | +use BEA\Theme\Framework\Helpers\Custom_Menu_Walker; |
| 3 | +?> |
1 | 4 | <!DOCTYPE html>
|
2 | 5 | <html class="no-js no-js-animation" <?php language_attributes(); ?>>
|
3 | 6 | <head>
|
@@ -27,10 +30,52 @@ function replaceHtmlClass(regexp, str) {
|
27 | 30 | </head>
|
28 | 31 | <body <?php body_class(); ?>>
|
29 | 32 | <?php wp_body_open(); ?>
|
30 |
| - <?php |
31 |
| - get_template_part( 'components/parts/common/skip-links' ); |
32 |
| - get_template_part( 'components/parts/common/header' ); |
33 |
| - ?> |
| 33 | + <nav class="skip-links skip-links--hidden" role="navigation" aria-label="<?php esc_attr_e( 'Fast access links', 'beapi-frontend-framework' ); ?>"> |
| 34 | + <ul> |
| 35 | + <li> |
| 36 | + <a href="#menu"><?php esc_html_e( 'Main navigation menu', 'beapi-frontend-framework' ); ?></a> |
| 37 | + </li> |
| 38 | + <li> |
| 39 | + <a href="#content"><?php esc_html_e( 'Main content', 'beapi-frontend-framework' ); ?></a> |
| 40 | + </li> |
| 41 | + <li> |
| 42 | + <a href="#footer"><?php esc_html_e( 'Footer', 'beapi-frontend-framework' ); ?></a> |
| 43 | + </li> |
| 44 | + </ul> |
| 45 | + </nav> |
| 46 | + <header id="header" class="header" role="banner" aria-label="<?php esc_attr_e( 'Header', 'beapi-frontend-framework' ); ?>"> |
| 47 | + <div class="header__inner"> |
| 48 | + <div class="container"> |
| 49 | + <a class="header__logo-link" href="<?php echo esc_url( home_url( '/' ) ); ?>"> |
| 50 | + <strong><?php echo esc_html( get_bloginfo( 'name' ) ); ?></strong> |
| 51 | + <span class="sr-only"><?php echo esc_html( get_bloginfo( 'name' ) ); ?></span> |
| 52 | + </a> |
| 53 | + <?php if ( has_nav_menu( 'menu-main' ) ) : ?> |
| 54 | + <button class="header__menu-toggle" aria-expanded="false" aria-controls="menu"> |
| 55 | + <span></span> |
| 56 | + <span class="sr-only aria-expanded-false-text"><?php esc_html_e( 'Open the menu', 'beapi-frontend-framework' ); ?></span> |
| 57 | + <span class="sr-only aria-expanded-true-text"><?php esc_html_e( 'Close the menu', 'beapi-frontend-framework' ); ?></span> |
| 58 | + </button> |
| 59 | + |
| 60 | + <nav id="menu" class="header__menu" aria-label="<?php esc_attr_e( 'Main navigation', 'beapi-frontend-framework' ); ?>" role="navigation"> |
| 61 | + <div> |
| 62 | + <?php |
| 63 | + wp_nav_menu( |
| 64 | + [ |
| 65 | + 'theme_location' => 'menu-main', |
| 66 | + 'container' => 'none', |
| 67 | + 'menu_class' => 'header__menu-list', |
| 68 | + 'fallback_cb' => false, |
| 69 | + 'walker' => new Custom_Menu_Walker(), |
| 70 | + ] |
| 71 | + ); |
| 72 | + ?> |
| 73 | + </div> |
| 74 | + </nav> |
| 75 | + <?php endif; ?> |
| 76 | + </div> |
| 77 | + </div> |
| 78 | + </header> |
34 | 79 | <main id="content" role="main" tabindex="-1" aria-label="<?php esc_attr_e( 'Main content', 'beapi-frontend-framework' ); ?>">
|
35 | 80 | <?php
|
36 | 81 | if ( ! is_front_page() && ! is_search() ) {
|
|
0 commit comments