Skip to content

Commit

Permalink
Merge pull request #2304 from claytoncollie/2286-labels-for-icon-links
Browse files Browse the repository at this point in the history
Add aria-labels and title attributes to icon hyperlinks in the header toolbar
  • Loading branch information
felipeelia authored Aug 16, 2021
2 parents bc8e165 + 24901e3 commit ba89c99
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions includes/partials/header.php
Original file line number Diff line number Diff line change
Expand Up @@ -22,14 +22,14 @@
<div class="icons">
<span class="sync-status"></span>
<?php if ( in_array( Screen::factory()->get_current_screen(), [ 'dashboard', 'settings', 'health' ], true ) ) : ?>
<a class="dashicons pause-sync dashicons-controls-pause"></a>
<a class="dashicons resume-sync dashicons-controls-play"></a>
<a class="dashicons cancel-sync dashicons-no"></a>
<a class="dashicons pause-sync dashicons-controls-pause" title="<?php esc_attr_e( 'Pause Sync', 'elasticpress' ); ?>" aria-label="<?php esc_attr_e( 'Pause Sync', 'elasticpress' ); ?>"></a>
<a class="dashicons resume-sync dashicons-controls-play" title ="<?php esc_attr_e( 'Resume Sync', 'elasticpress' ); ?>" aria-label="<?php esc_attr_e( 'Resume Sync', 'elasticpress' ); ?>"></a>
<a class="dashicons cancel-sync dashicons-no" title="<?php esc_attr_e( 'Cancel Sync', 'elasticpress' ); ?>" aria-label="<?php esc_attr_e( 'Cancel Sync', 'elasticpress' ); ?>"></a>
<?php if ( Elasticsearch::factory()->get_elasticsearch_version() && defined( 'EP_DASHBOARD_SYNC' ) && EP_DASHBOARD_SYNC ) : ?>
<a class="dashicons start-sync dashicons-update"></a>
<a class="dashicons start-sync dashicons-update" title="<?php esc_attr_e( 'Start Sync', 'elasticpress' ); ?>" aria-label="<?php esc_attr_e( 'Start Sync', 'elasticpress' ); ?>"></a>
<?php endif; ?>
<?php endif; ?>
<a href="<?php echo esc_url( $base_url . 'elasticpress-settings' ); ?>" class="dashicons dashicons-admin-generic"></a>
<a href="<?php echo esc_url( $base_url . 'elasticpress-settings' ); ?>" class="dashicons dashicons-admin-generic" title="<?php esc_attr_e( 'Settings', 'elasticpress' ); ?>" aria-label="<?php esc_attr_e( 'Settings', 'elasticpress' ); ?>"></a>
</div>

<div class="progress-bar"></div>
Expand Down

0 comments on commit ba89c99

Please sign in to comment.