-
Notifications
You must be signed in to change notification settings - Fork 528
add dpub-aria roles for footnotes #287
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
Conversation
Looks good. I'm still a bit hesitant to call this an endnote, but it does indeed match the spec better despite the divergent names. As for giving a name/title/label to the backlink, there's already a |
Should I duplicate |
Perhaps. I think most people who take the time to set this configuration variable use something that would be appropriate for the aria label, but I can't be sure. As for endnote vs. footnote, do you know how accessibility tools treat the two, or the absence of either? I'm a bit worried about adding this blindly without knowing what effect it has in practice. It'd be nice if the test cases involving for footnotes in MDTest were updated too. |
I tried to do that in michelf/mdtest#9. Unfortunately, I do not currently have access to a working PHP setup, so it should be tested thouroughly.
To be honest I have no clue. The spec is fairly new, so I can imagine that it has not yet been implemented in a lot of tools. In my experience, new features often have a chicken-egg problem: AT vendors do not add support because few pages use the feature and authors do not use the feature because it is not supported in AT. My idea was that adding this to markdown could be a catalyst. I can completely understand if you want to wait for wider support though. |
It's nice that ARIA is doing something about this. Honestly, I think footnote markup should be directly part of the HTML spec, not solely an accessibility-oriented feature. Footnotes are so prevalent that they are worthy of discussion in the HTML spec... but the markup they suggest isn't that useful. There is surprisingly little talk out there about aria's footnote and endnote roles. This is the best I could find. It looks like the distinction between the two had to be made because you can't have the same role for an item in a list and one that is embedded from its context (basically a presentational issue). It's going to be awkward to add this "endnote" role for a feature everyone calls footnote when aria also has a "footnote" role we could use. If the end result for the user is the same, I'd rather go for the one called "footnote" because it's the right word and will cause less confusion to those who care about the HTML output. If the treatment is different, I'd at least like to avoid accessibility tools announcing those as "endnotes" for users, so again "footnote" wins. But given the aria spec tries to differentiate the two I guess it's possible "footnote" would result in less optimal navigation, I guess. So I can't really decide what to do because I can't weight the pros and cons. It seems to me like neither choice is right. I'd love to break the chicken and egg problem, but I think I'll wait a bit until I can find clearer guidance. |
First of all, a big thanks to you. It never happened to me that I wrote a pull request and the maintainer got so deep into it! I wrote a mail to [email protected] asking for help on this. Maybe something will come of it. Reading the spec again I still think that endnote is the appropriate concept here. Note for example that |
Sorry for the delayed response. The reason that we created both the Endnotes are widely understood, so it shouldn't be all that confusing given that endnotes and footnotes are the same except in positioning and collection. If you need to have a footnote semantic a workaround would be to add a div inside each list item and put the role on that instead of on the list item. It's not elegant, but it wouldn't cause issues in parsing the markup |
@TzviyaSiegman Thanks for your input. @xi Let's go with So I take this is ready to merge as soon as I have some time to test it (probably by next week). Thank you for the patch. |
Thanks to @TzviyaSiegman for the quick feedback. Happy to see this going forward! |
The current draft for dpub-aria 1.1 removes the |
The Digital Publishing WAI-ARIA Module 1.0 has recently become a W3C recommendation. It contains semantic structures that are derived from EPUB.
I added the appropriate roles to footnotes. Note that I chose to use
doc-endnote
rather thandoc-footnote
because of this section of the spec:Note that in order to be fully compliant the backlink needs an accessible name. The current name is
'↩︎'
which is not very useful. We could duplicate the title asaria-label
, but by default the title is currently empty.