Archived topic
Elements must only use allowed ARIA attributes
12 replies · Started by Maria on March 9, 2022
Axe Dev Tools is giving me this error on my page titles. Any idea why? See screenshots: https://www.screencast.com/t/71lytO7ofV7
Hi Maria,
Can you try setting up a Block Element - Page hero containing this setup?
https://share.getcloudapp.com/5zuLpP1q
And then try checking with axe-core dev tools if it still gets flagged.
Will do. What should I set the Element Type and Hook Name to?
The type would be page hero, you don't need to select hook name whenpage hero is selected as the element type.
Thanks for the clarification. I'm not sure why I should be doing this. When creating a page, I should just be able to enter the title and not get any accessibility errors.
You should not :)
As accessibility rules are changing rapidly, we might not be able to keep up with it with our updates.
I would mention this to Tom see what he thinks.
If you could pass this on to him, that would be great. I appreciate your help.
You are welcome :)
Hi there,
Any chance you can link me to that page so I can take a closer look?
Let me know :)
I get the error on all pages except the Home page. Here's one of the pages: https://a6awareness.org/testing-centers/
The aria-label is required on the header element, but a role should not be required as header already implies the role (the header of the content).
Have you checked the page using a different accessibility tool? It's possible that the one you're using is wanting a role attribute even though it shouldn't be necessary.
We can remove the aria-label with a filter very simply, but doing so will cause more accessibility errors for you. We can also add a role attribute very easily with a filter if you'd like us to provide it.
Let me know :)
I'm going to leave it alone. I did check it with other accessibility tools and didn't get any errors so I'm good. Thanks for looking into it for me.
No problem!