Skip to content
This repository has been archived by the owner on Aug 13, 2023. It is now read-only.

Replace aria label with text for nav button #2951

Merged
merged 2 commits into from
Jan 17, 2020

Conversation

tochwill
Copy link
Contributor

@tochwill tochwill commented Jan 17, 2020

Resolves #2950

Overall change:
The BBC a11y check on CI is failing with the following error:

  • Forms: Labelling form controls: Fields must have labels or titles
    • Button has no text: //div[@id='root']/header/nav/div/div[1]/button

This is because the button contains no text, and relies instead on an aria-label. We can use the VisuallyHiddenText component instead, which will pass the a11y acceptance criteria.

Code changes:

  • A bullet point list of key code changes that have been made.
  • When describing code changes, try to communicate how and why you implemented something a specific way, not just what has changed.

  • I have assigned myself to this PR and the corresponding issues
  • Automated jest tests added (for new features) or updated (for existing features)
  • This PR requires manual testing

@tochwill tochwill self-assigned this Jan 17, 2020
@tochwill tochwill added the ws-home Tasks for the WS Home Team label Jan 17, 2020
Copy link
Contributor

@AlistairGempf AlistairGempf left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good.

@tochwill tochwill merged commit 1ee5fb0 into latest Jan 17, 2020
@tochwill tochwill deleted the nav-button-visually-hidden-text branch January 17, 2020 15:13
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
ws-home Tasks for the WS Home Team
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Use visually hidden text instead of aria-label for navigation menu button.
3 participants