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

Improve aria support - Columns and Navigation Drawer Icons #2299

Merged

Conversation

stephenburgess8
Copy link
Contributor

Add aria-labels to unlabelled tab nav items

The drawer tabs which control primary navigation are only labelled by a title which is not available to many screenreaders. Add an aria-label attribute to each link to improve readability with screenreaders. Organize link attributes so link target is first followed by classname.

Abstract aria roles such as 'section' should not be used in content. Use non-abstract 'region' aria role instead of 'section' for columns. That role expects an aria-labelledby attribute with an id. Pass an ID to the column header. Remove the aria-label attribute on the ColumnHeader because the same value is output in plaintext as its child. Add additional role of 'heading' to ColumnHeader as required as the heading labelling a 'region'.

Do not add aria-controls to the icon links at this time. When a button is triggered, an individual column is added to the DOM. Since there's no wrapper around those columns, these icons do not control the content of a pane, but instead is replacing one pane with another. aria-controls is therefore not applicable.

#1349

The drawer tabs which control primary navigation are only labelled by a title which is not available to many screenreaders. Add an aria-label attribute to each link to improve readability with screenreaders. Organize link attributes so link target is first followed by classname.
Issue mastodon#1349
Abstract aria roles such as section should not be used in content. Use non-abstract 'region' aria role instead. That role expects an aria-labelledby attribute with an id. Pass an ID to the column header. Remove the aria-label attribute on the ColumnHeader because the same value is output in plaintext as its child.
Issue mastodon#1349
Columns do not have wrappers, so these icons can't point to a column wrapper which it controls. Instead these icons function as triggers to show or hide individual columns.
mastodon#1349
@Gargron Gargron merged commit 4cfc155 into mastodon:master Apr 22, 2017
@stephenburgess8 stephenburgess8 deleted the feature/accessible-toolbar-icons branch April 22, 2017 15:35
seefood pushed a commit to Toootim/mastodon that referenced this pull request Apr 28, 2017
…2299)

* feat(aria): Add aria-labels to underlabelled tab nav items

The drawer tabs which control primary navigation are only labelled by a title which is not available to many screenreaders. Add an aria-label attribute to each link to improve readability with screenreaders. Organize link attributes so link target is first followed by classname.
Issue mastodon#1349

* feat(aria): Replace abstract aria role of section with region

Abstract aria roles such as section should not be used in content. Use non-abstract 'region' aria role instead. That role expects an aria-labelledby attribute with an id. Pass an ID to the column header. Remove the aria-label attribute on the ColumnHeader because the same value is output in plaintext as its child.
Issue mastodon#1349

* fix(aria): Remove aria-controls attribute until solution is found

Columns do not have wrappers, so these icons can't point to a column wrapper which it controls. Instead these icons function as triggers to show or hide individual columns.
mastodon#1349

* fix(typo): Remove type of aria-labelledby instead of aria-label
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.

None yet

2 participants