galaxyproject / galaxy Public
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
Update anchor tags and enhance navigation cues for screen readers #8334
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
…erpret the links as already visited
martenson
reviewed
Jul 15, 2019
|
I have another WIP branch which depends on some of the changes in this PR. When this PR passes review and gets merged I will make the PR for the WIP branch into galaxy dev (when it's not WIP anymore of course). For now I have set up a temporary PR in my own repo to keep track of the changes: WilliamHolden#1. |
martenson
approved these changes
Aug 19, 2019
|
Thanks @WilliamHolden ! |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
This pull request does two things. The first is that it changes any non link anchor tags to use href="javascript:void(0)" instead of href="#".
Both of these href attributes are trying to achieve the same thing so we should only use one for consistency reasons. There are a few reasons to prefer href="javascript:void(0)" over href="#".
#7893
There are other reasons as well. See the top answer on https://stackoverflow.com/questions/134845/which-href-value-should-i-use-for-javascript-links-or-javascriptvoid0
Ideally, a lint rule will be added to enforce this change in the future but I could not find a good eslint plugin. The closest one I found was "jsx-a11y/href-no-hash" but I think this rule was created for jsx specifically
The next thing this pull request does is make some enhancements to the navigational cues for screen readers through the use of aria-labels, tabindex, and role attributes. There is still some work to be done here and I will make another pull request with more navigational cue updates.
The text was updated successfully, but these errors were encountered: