User tests: Successful: Unsuccessful:
Added role="button" attribute to the Back-to-Top link in the Cassiopeia template to improve accessibility and resolve Axe DevTools warning.
Fixes #45679
Pull Request resolves #45679.
Added role="button" attribute to the Back-to-Top link in the Cassiopeia template (templates/cassiopeia/index.php) to improve accessibility and address Axe DevTools warnings.
The Back-to-Top link does not contain the role="button" attribute, which triggers an accessibility warning in Axe DevTools.
The Back-to-Top link includes role="button", improving accessibility and resolving the Axe DevTools warning.
Please select:
Documentation link for guide.joomla.org:
No documentation changes for guide.joomla.org needed
Pull Request link for manual.joomla.org:
No documentation changes for manual.joomla.org needed
| Status | New | ⇒ | Pending |
| Category | ⇒ | Front End Templates (site) |
Thank you for the feedback.
I understand that adding role="button" to an anchor element may not be the correct semantic approach. I will review accessibility best practices for back-to-top links and update the implementation accordingly instead of relying only on the Axe DevTools warning.
I will update the PR shortly.
| Labels |
Added:
PR-5.4-dev
|
||
why add a role to change the semantic meaning of an
a? if you want it to be a button then change it tobuttonBUT please note that either with or without that change does not mean it is correct. Passing an automated test does not mean it is correct it just means you passed a test.
Have you researched accessibility best practices for back-to-top links and followed their advice or did you just rely on passing a test