Open
Conversation
Allow upload to Authoring Tool
danielstorey
requested changes
Feb 15, 2019
Owner
danielstorey
left a comment
There was a problem hiding this comment.
Thanks for your contribution, it's definitely an issue that needs attending to. I think we may also need to add the ariaRegion into the top of the template as well.
I've made a few points below. Let me know if you're unsure of anything or if you're not able to make the changes and I'll pick this up myself.
Thanks again - I do really appreciate everyone that's willing to contribute!
templates/expose.hbs
Outdated
| <div class="expose-item nth-child-{{@index}}"> | ||
| <div class="expose-item-inner"> | ||
| <button class="expose-item-button"></button> | ||
| <button class="expose-item-button" title="{{#if front}} {{{a11y_text front}}} {{else}} reveal {{/if}}"></button> |
Owner
There was a problem hiding this comment.
- As well as making text accessible we also need to be mindful about not hard coding language strings.
- Reveal is quite vague - I would default to something like 'Expose button'
- Would an aria label be more appropriate than a title? That way the label would still be present regardless of there being a title or not.
- Language string should be placed in _globals._components._expose.buttonLabel and schema needs updating
- Code wise there shouldn't really be any spaces in between Handlebars helpers otherwise Handlebars will render these. E.g.
{{#if front}}{{{a11y_text front}}}{{else}}reveal{{/if}}. I know reading is more difficult but the output is tidier.
Author
There was a problem hiding this comment.
I can try next time I have a window of opportunity.
This file contains hidden or 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
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.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adding a title to the button gives it meaning in a screenreader