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 accessibility issue in Quick starts page-Buttons must have discernible text #9339

Merged
merged 1 commit into from Jun 28, 2021

Conversation

sanketpathak
Copy link
Contributor

@sanketpathak sanketpathak commented Jun 24, 2021

Fixes:
https://issues.redhat.com/browse/ODC-6065

Analysis / Root cause:
Getting Critical Accessibility violation when scaning the Quick Starts page using axe tool

Solution Description:
Added aria-label to the prerequisite button on quick start tile

Screen shots / Gifs for design review:
UI is unchanged
Before:
Screenshot from 2021-06-24 13-28-39

After:
Screenshot from 2021-06-24 17-06-04

Unit test coverage report:
Unchanged

Test setup:
Go to Quick Starts catalog page and scan page using axe devtools in developer console

Browser conformance:

  • Chrome
  • Firefox
  • Safari
  • Edge

@openshift-ci openshift-ci bot added the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Jun 24, 2021
@openshift-ci openshift-ci bot requested review from rhamilto and spadgett June 24, 2021 10:40
@sanketpathak sanketpathak changed the title [WIP]Fix accessibility issue in Quick starts page-Buttons must have discernible text [WIP] Fix accessibility issue in Quick starts page-Buttons must have discernible text Jun 24, 2021
@sanketpathak sanketpathak changed the title [WIP] Fix accessibility issue in Quick starts page-Buttons must have discernible text Fix accessibility issue in Quick starts page-Buttons must have discernible text Jun 24, 2021
@openshift-ci openshift-ci bot removed the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Jun 24, 2021
Copy link
Member

@spadgett spadgett left a comment

Choose a reason for hiding this comment

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

If this page now passes axe, can we add it to the pages we test a11y for in cypress? If not, how hard is it to address the remaining issue?

The easiest way to add a11y test coverage is to add this page to the other routes test here:

https://github.com/spadgett/console/blob/852743d807b0c5f8a551cb4bc18345b8c3b22029/frontend/packages/integration-tests-cypress/tests/crud/other-routes.spec.ts#L125

@@ -55,6 +55,7 @@ const QuickStartTileDescription: React.FC<QuickStartTileDescriptionProps> = ({
e.preventDefault();
e.stopPropagation();
}}
aria-label={t('quickstart~Prerequisites icon')}
Copy link
Contributor

Choose a reason for hiding this comment

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

Imagine a screen reader telling you that you've navigated to a button and then it tells you "Prerequisites icon". Do you know what the button does now?

An aria-label is just as important as visible text. Button text should be actionable.

Suggested change
aria-label={t('quickstart~Prerequisites icon')}
aria-label={t('quickstart~Show prerequisites')}

Don't forget to regenerate the locale files.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Thanks for explaining, I've updated the pr

@openshift-ci openshift-ci bot added the kind/i18n Indicates issue or PR relates to internationalization or has content that needs to be translated label Jun 25, 2021
@christianvogt
Copy link
Contributor

/retest

@christianvogt
Copy link
Contributor

fyi @jschuler

@sanketpathak
Copy link
Contributor Author

@spadgett Critical issues from the Quick Starts catalog page has been removed by this pr and I can see one moderate issue remaining

@christianvogt
Copy link
Contributor

/lgtm
/approved

I think we can further improve this with other aria attributes to indicate a popup but for now this addresses the immediate concern.

@openshift-ci openshift-ci bot added the lgtm Indicates that a PR is ready to be merged. label Jun 28, 2021
@openshift-ci
Copy link
Contributor

openshift-ci bot commented Jun 28, 2021

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: christianvogt, sanketpathak

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@openshift-ci openshift-ci bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Jun 28, 2021
@openshift-merge-robot openshift-merge-robot merged commit dae8020 into openshift:master Jun 28, 2021
@spadgett spadgett added this to the v4.9 milestone Jul 14, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. component/core Related to console core functionality kind/i18n Indicates issue or PR relates to internationalization or has content that needs to be translated lgtm Indicates that a PR is ready to be merged.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants