Re: Accessible name definition

Hi Sarah,
I’ll take a stab at responding to this in the context of WCAG, but note that I’m not as technical as many on this thread.

It’s important to distinguish between “user interface component”, a defined term used in WCAG<https://www.w3.org/WAI/WCAG21/Understanding/non-text-contrast.html#dfn-user-interface-component> for something that is operable, and “user interface element”, the phrase you quoted from the AccName spec, which is talking about elements in the sense of HTML, where any tagged object, such as <h1>, is an element, regardless of whether it’s operable.

You then go on to quote “accessible objects” from the wai-aria 1.1 spec. So, just to make sure we’re clear we’ve now talked about similar terms from three different specs.

A heading gets an accessible name from whatever text is between its opening and closing tags. That’s what is meant by that phrase. So many things that aren’t necessarily ‘components’ can get accessible names in the same way.

A heading with no text is worse less than useless. I can’t think of a reason one would put that on a page. So there should not be any occasion to put an aria-label on an empty heading tag. Generally, the advice is to natively provide accessible names where possible, not override them with aria-label.

Conversely, adding a role of heading to some text on a page WILL give that text the role of heading, and the text will be the heading’s accessible name.

Although a list rarely has text (except inside the list items), I think it can technically support it. That’s probably why it isn’t mentioned in either 5.2.7.4 and 5.2.7.5.

Hope that helps. I’m sure someone will correct any inaccuracies I’ve made 😊

Mike


From: Ms J <ms.jflz.woop@gmail.com>
Date: Friday, April 8, 2022 at 3:25 AM
To: w3c-wai-ig@w3.org <w3c-wai-ig@w3.org>
Subject: [EXTERNAL] Accessible name definition
Hello, Please can you provide some clarity on what counts as an ‘accessible name’. The definition says The accessible name is the name of a ‘user interface element’. https://www.w3.org/TR/accname-1.1/#glossary ‍ ‍ ‍ ‍ ‍ ‍ ‍ ‍ ‍ ‍ ‍ ‍ ‍ ‍ ‍ ‍ ‍ ‍ ‍ ‍ ‍ ‍ ‍ ‍ ‍ ‍ ‍ ‍ ‍ ‍ ZjQcmQRYFpfptBannerStart
This Message Is From an External Sender
This message came from outside your organization.
ZjQcmQRYFpfptBannerEnd

Hello,

Please can you provide some clarity on what counts as an ‘accessible name’.

The definition says

The accessible name is the name of a ‘user interface element’.
https://www.w3.org/TR/accname-1.1/#glossary<https://www.w3.org/TR/accname-1.1/#glossary>

But then the name computation mentions the name of ‘accessible objects’ and tasks about headings having accessible names:
https://www.w3.org/TR/wai-aria-1.1/#namecomputation<https://www.w3.org/TR/wai-aria-1.1/#namecomputation>

I mainly just want to make sure I’m using terminology correctly. I appreciate there are other widgets and roles that are not ‘user interface components’ that do support or require an accessible name, such as regions or tabpanels. However, there are some that don’t require them such as a rule of ‘list’ - this isn’t on the list of roles supporting name from content, but wouldn’t generally require an aria-label or anything explicitly defining the accessible name.

I associate accessible names with anything I would use the aria-label attribute on. I would not usually refer to an empty heading as having no ‘accessible name’ and would not tend to use an aria-label on one.

Some clarity would be greatly appreciated!

Thank you

Sarah

Received on Friday, 8 April 2022 14:04:14 UTC