w3c / dpub-aria

Digital Publishing WAI-ARIA Module
https://w3c.github.io/dpub-aria/
11 stars 10 forks source link

Can we have doc-glossary on <aside>? #53

Open chiaradm95 opened 1 year ago

chiaradm95 commented 1 year ago

Hi everyone,

as the title suggests, I'm here because I'd need to use role="doc-glossary"on the <aside> tag. However, both EPUBCheck and ACE report errors. ACE reports that "ARIA role doc-glossary is not allowed for given element". As far as I understand, <aside> has the implicit role "complementary", which is a subclass role of "landmark", which in turn is the superclass indicated for doc-glossary.

Also, looking at the Accessible Publishing Knowledge Base by DAISY, <aside> is listed among the possible elements doc-glossary is allowed on (http://kb.daisy.org/publishing/docs/html/dpub-aria/doc-glossary.html).

As for the content of the <aside>, the error occurs both if we have a definition list (<dl> with <dt> and <dd>, possibly with role="term" on <dt>), or if we have a <p> with <dfn> to identify the term.

In the specific use case, I have an EPUB with boxes (<aside>) that contain definitions of words and therefore represent small glossaries, so using doc-glossary would give more semantics.

Can anyone help me understand the problem?

pkra commented 1 year ago

The relevant spec is html-aria which defines which roles are allowed on HTML elements. For the specifics for the aside element see https://w3c.github.io/html-aria/#el-aside.

There's currently an open issue to review the aside element, see https://github.com/w3c/html-aria/issues/411

chiaradm95 commented 1 year ago

Thank you very much, I wasn't aware of this spec. I will look at it in detail.


Chiara De Martin

[Logo di Fondazione LIA]

Corso di Porta Romana 108, 20122 Milano

www.fondazionelia.orghttp://www.fondazionelia.org/ - www.libriitalianiaccessibili.orghttp://www.libriitalianiaccessibili.org/

[Loghi dei social Facebook, Twitter, Instagram e Twitter] Segui @fondazionelia


Da: Peter Krautzberger @.> Inviato: martedì 28 marzo 2023 17:16 A: w3c/dpub-aria @.> Cc: Chiara De Martin @.>; Author @.> Oggetto: Re: [w3c/dpub-aria] Can we have doc-glossary on

mattgarrish commented 1 year ago

This shows one of the problems of publishing structures being both primary and subordinate. The role was modelled on a glossary being a primary section in the back matter. If you put it on an aside for a glossary embedded within a section then it's no longer going to be complementary. That's probably not critical since embedded glossaries usually precede the section content, but there's no real advantage to using aside over section in terms of how it will be exposed to AT.

That said, if an aside not scoped to the body or main is going to be generic, anyway, then it doesn't seem harmful to allow doc-glossary on it.

The KB page is not authoritative, as @pkra has already mentioned. There's a link to ARIA in HTML at the bottom, but I'll go back to those element lists and make it clearer to refer to that doc for the most up-to-date list of elements or in case of conflicts.

pkra commented 1 year ago

FWIW, the PR https://github.com/w3c/html-aria/pull/455 is proposing to allow the role on aside elements.