mirror of
https://github.com/WordPress/WordPress.git
synced 2024-08-20 12:54:00 +02:00
* Relies on header skip link instead of l10n variables in JavaScript. * Fixes issue where scroll down arrow appeared next to the navigation on the front page with no header image or video. It now only appears with a big header. Props enodekciw, laurelfulford. Fixes #38502. Built from https://develop.svn.wordpress.org/trunk@39073 git-svn-id: http://core.svn.wordpress.org/trunk@39015 1a063a9b-81f0-0310-95a4-ce76da25c4cd
23 lines
981 B
PHP
23 lines
981 B
PHP
<?php
|
|
/**
|
|
* Displays top navigation
|
|
*
|
|
* @package WordPress
|
|
* @subpackage Twenty_Seventeen
|
|
* @since 1.0
|
|
* @version 1.0
|
|
*/
|
|
|
|
?>
|
|
<nav id="site-navigation" class="main-navigation" role="navigation" aria-label="<?php _e( 'Top Menu', 'twentyseventeen' ); ?>">
|
|
<button class="menu-toggle" aria-controls="top-menu" aria-expanded="false"><?php echo twentyseventeen_get_svg( array( 'icon' => 'bars' ) ); echo twentyseventeen_get_svg( array( 'icon' => 'close' ) ); _e( 'Menu', 'twentyseventeen' ); ?></button>
|
|
<?php wp_nav_menu( array(
|
|
'theme_location' => 'top',
|
|
'menu_id' => 'top-menu',
|
|
) ); ?>
|
|
|
|
<?php if ( ( twentyseventeen_is_frontpage() || ( is_home() && is_front_page() ) ) && has_custom_header() ) : ?>
|
|
<a href="#content" class="menu-scroll-down"><?php echo twentyseventeen_get_svg( array( 'icon' => 'arrow-right' ) ); ?><span class="screen-reader-text"><?php _e( 'Scroll Down', 'twentyseventeen' ); ?></span></a>
|
|
<?php endif; ?>
|
|
</nav><!-- #site-navigation -->
|