Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix / aria-expanded attribute on icon buttons #170

Merged
merged 5 commits into from
Apr 4, 2024

Conversation

MelissaDTH
Copy link

@MelissaDTH MelissaDTH commented Apr 3, 2024

This PR

  • Fixes an issue that aria-expanded was not correctly identified by VoiceOver (iOS) on the language menu button
    • It took a while before I found the issue, because aria-expanded was correctly setup on the Language Menu: I had to update the IconButton component by refactoring the <div> element with a <button> element since this is semantically correct HTML. I think because button elements are inherently interactive, now VoiceOver on iOS recognises it as actionable controls (even whilst the IconButton already had role="button").
    • Tested on iOS and Android Talk Back
  • Solves: OTT-1079
  • The e2e tests fail because of selectors that need updating, will be fixed!

Copy link

@royschut royschut left a comment

Choose a reason for hiding this comment

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

Nice find!

With your change to an html <button />, I think we should make the IconButton really a button.

packages/ui-react/src/components/IconButton/IconButton.tsx Outdated Show resolved Hide resolved
platforms/web/public/locales/en/menu.json Outdated Show resolved Hide resolved
@MelissaDTH MelissaDTH temporarily deployed to Deployment Previews April 4, 2024 10:52 — with GitHub Actions Inactive
Copy link

@langemike langemike left a comment

Choose a reason for hiding this comment

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

Nice work, Melissa!

@MelissaDTH MelissaDTH temporarily deployed to Deployment Previews April 4, 2024 13:10 — with GitHub Actions Inactive
@MelissaDTH MelissaDTH temporarily deployed to Deployment Previews April 4, 2024 13:24 — with GitHub Actions Inactive
@MelissaDTH MelissaDTH temporarily deployed to Deployment Previews April 4, 2024 13:29 — with GitHub Actions Inactive
@MelissaDTH MelissaDTH merged commit a1c827f into feat/accessibility-sprint-4 Apr 4, 2024
7 checks passed
@MelissaDTH MelissaDTH deleted the fix/expand-language-menu branch April 4, 2024 13:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants