Re: [whatwg/encoding] aria-label usage in BMP coverage table (#261)

> `<td class=unmapped aria-label=Unmapped><dl><dt>U+0000<dd>�<dd> </dl>`

My reading of the relevant best-practice guidance and relevant spec requirements lead me to believe a warning is appropriate, and so the `aria-label` attributes should be dropped from those `td` elements.

As far as the spec requirements go, https://w3c.github.io/html-aam/#other-tabular-data-elements says that for tr, td, th Elements Accessible Name Computation, the step that implementations must start with is:

> If the table element has an aria-label or an aria-labelledby attribute the accessible name is to be calculated using the algorithm defined in Accessible Name and Description: Computation and API Mappings 1.1.

Notice it says “the table element”. So I take that to mean that implementations must essentially ignore whatever `aria-label` attribute a `td`, `th`, or `tr` element might have, and instead look back up the tree and use whatever `aria-label` attribute the ancestor `table` element has.

Does my reading of that seem correct?

If my reading of that is in fact correct, then as far as the checker behavior goes, doesn’t that mean it’s appropriate for the checker to warn about not using `aria-label` with `td`, `th`, or `tr` elements?

As far as the related best-practice guidance, the source I have been following for that is  https://html5accessibility.com/stuff/2020/11/07/not-so-short-note-on-aria-label-usage-big-table-edition/, which explicitly recommends not using `aria-label` with `td`, `th`, or `tr` elements. For those, it notes *“aria-label use not well supported”* (meaning, not well supported in UAs/AT).


-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/whatwg/encoding/issues/261#issuecomment-851309662

Received on Monday, 31 May 2021 08:24:11 UTC