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

Set default aria-labels for trickle button #192

Open
kirsty-hames opened this issue May 24, 2023 · 1 comment
Open

Set default aria-labels for trickle button #192

kirsty-hames opened this issue May 24, 2023 · 1 comment

Comments

@kirsty-hames
Copy link
Contributor

Subject of the issue

By default, there is no aria-label for Trickle buttons. For Buttons containing text this is fine as .trickle__btn-text is read instead.
For icon only trickle buttons (_hasIcon enabled and empty text), you need to set the appropriate ariaLabel, startAriaLabel and finalAriaLabel. From experience these are often missed and for most Adapt buttons we include aria-label defaults as standard e.g. question buttons.

trickle_no_aria

Expected behaviour

Set aria-label defaults. Either pulling in the text startText and finalText so these are automatically populated when you amend the text properties (to save on amending multiple instances and to keep these consistent). Or to set defaults just copying the text startText and finalText text.

@kirsty-hames
Copy link
Contributor Author

Either pulling in the text startText and finalText so these are automatically populated when you amend the text properties (to save on amending multiple instances and to keep these consistent).

On reflection, I think this approach could be utilised across Adapt. With AAT users in mind, having aria-label defaults that automatically inherit from the visually displayed text would be useful and we already have this approach with title and displayTitle in Adapt. They are linked by default but giving the flexibility to edit separately if required.

I'd be interested to hear thoughts from others.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: Awaiting Response
Development

No branches or pull requests

1 participant