w3c / html-aria

ARIA in HTML
https://w3c.github.io/html-aria/
Other
181 stars 49 forks source link

Addition: update figure role allowances #415

Closed scottaohara closed 1 year ago

scottaohara commented 2 years ago

closes #412

As discussed in https://github.com/w3c/dpub-aria/issues/42#issuecomment-1092558918, doc-example is a dpub variant of the figure role. This role being the same as figure but with the opportunity of being exposed as an "example" for its role description, needs to be an allowed role for the figure element.

create test case

Expected results: doc-example is an allowed role for <figure role=doc-example>...<figcaption>...</figcaption> figure results in a warning as unnecessary for <figure role=figure>...<figcaption>...</figcaption> no other roles are allowed if a figcaption is a child of a figure element.


Preview | Diff

scottaohara commented 1 year ago

merging as arc toolkit and axe do not report errors when using this role on figure element