Skip to content

Improving EuiIcon a11y#2786

Merged
elizabetdev merged 4 commits intoelastic:masterfrom
elizabetdev:icons-title-a11y
Jan 27, 2020
Merged

Improving EuiIcon a11y#2786
elizabetdev merged 4 commits intoelastic:masterfrom
elizabetdev:icons-title-a11y

Conversation

@elizabetdev
Copy link
Copy Markdown
Contributor

Summary

Closes #579

When PR #2554 was merged we couldn't use aria-labelledby because the SVGR at that time didn't allow to specify an id for the title tag.

After requesting a new SVGR feature to allow a title id, it was finally merged.

This PR updates the package @svgr/core to the latest version so we can specify a title id to use with the aria-labelledby. Some logic was changed and icons were generated again to include the new SVGR feature.

The other task remaining on #579, translating the icon names, doesn't make sense anymore because we are not using the icon name as a default title.

Checklist

  • Check against all themes for compatibility in both light and dark modes
  • Checked in mobile
  • Checked in IE11 and Firefox
  • Props have proper autodocs
  • Added documentation examples
  • Added or updated jest tests
  • Checked for breaking changes and labeled appropriately
  • Checked for accessibility including keyboard-only and screenreader modes
  • A changelog entry exists and is marked appropriately

Copy link
Copy Markdown
Contributor

@chandlerprall chandlerprall left a comment

Choose a reason for hiding this comment

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

Nice! Changes LGTM; logic looks correct, additional test is great, and spot checked a couple of the generated icon files.

Copy link
Copy Markdown
Contributor

@snide snide left a comment

Choose a reason for hiding this comment

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

Ran locally and checked the code and the output of the SVGs.

@elizabetdev elizabetdev merged commit 096fbfd into elastic:master Jan 27, 2020
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.

Enforce label or aria-hidden in EuiIcon

3 participants