Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Landmarks and role directory #1010

Closed
JayPanoz opened this issue Mar 15, 2019 · 8 comments
Closed

Landmarks and role directory #1010

JayPanoz opened this issue Mar 15, 2019 · 8 comments
Labels
type: not an issue The issue is rejected (not an actual issue or not relevant)

Comments

@JayPanoz
Copy link

JayPanoz commented Mar 15, 2019

Any idea why I now get this error in 4.2.0-beta:

/Users/Pan/BlitzFramework/Blitz_template/Blitz_epub3.epub/OEBPS/Text/nav.xhtml(24,80): Erreur lors de l'analyse du fichier: la valeur de l'attribut "role" n'est pas valide ; doit être égal à "doc-index", "doc-pagelist", "doc-toc" ou "navigation"

While the markup pretty much follows Role Mapping Table to the letter?

@mattgarrish
Copy link
Member

The role attribute is more restricted in what values can be used with it depending on the element it's used on. The rules are defined in the ARIA in HTML document.

You may have the correct mapping for whatever term you've put on the nav, but it may not be a navigation role, in other words. What term is causing the error?

@rdeltour
Copy link
Member

rdeltour commented Mar 15, 2019

Yeah the role mapping table is to be taken with a grain of salt; it's more an indication of which role may be used to actually add AT-supported semantics for a given epub:type, but it doesn't necessarily mean that the role is conforming on the element which carried the epub:type.

For conformance rules on where DPUB ARIA roles (and other ARIA roles) are allowed in HTML, you need to refer to ARIA in HTML.

In your case, the directory role is a subclass of the list role, so yeah it's not allowed on elements that already have a different semantics (native semantics should not be overridden).

@rdeltour
Copy link
Member

(damn @mattgarrish is fast!)

@rdeltour
Copy link
Member

Closing this issue as invalid, but feel free to keep on discussing here!

@rdeltour rdeltour added the type: not an issue The issue is rejected (not an actual issue or not relevant) label Mar 15, 2019
@mattgarrish
Copy link
Member

Ya, but apparently I can't read issue titles... d'oh!

I'm thinking maybe we should add a column to the mapping table to list where the roles are allowed.

@JayPanoz
Copy link
Author

Guilty as charged.

I moved it from nav to the nested list and it’s now OK.

However, I’ve seen other mappings in the wild putting it on nav – and cover-image on figure instead of img for instance, especially authoring tool plugins, automated tools, etc. so yeah, it would be useful to have such a column to the mapping table.

Now I’ll have to deal with doc-glossary because dl is a group and not a list, and is in a huge turmoil it seems.

@mattgarrish
Copy link
Member

Now I’ll have to deal with doc-glossary because dl is a group and not a list, and is in a huge turmoil it seems.

Ya, doc-glossary is technically a landmark role, so there are problems both in that ARIA document and in our current release (it's not supposed to be on dl but on a section containing a glossary, and the schemas right now don't allow it anywhere). The example in the DPUB-ARIA module was incorrect, and seems to have caused various confusion.

I've filed an issue to fix the ARIA doc here: w3c/html-aria#128

And to fix the schemas here: validator/validator#771

We've fixed epubcheck for the next release, though, so it will validate on section.

@JayPanoz
Copy link
Author

Thanks for the heads up!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: not an issue The issue is rejected (not an actual issue or not relevant)
Projects
None yet
Development

No branches or pull requests

3 participants