Skip to content
This repository has been archived by the owner on May 10, 2018. It is now read-only.

Navigation TOC Example #3 #2

Open
clapierre opened this issue Jul 15, 2016 · 3 comments
Open

Navigation TOC Example #3 #2

clapierre opened this issue Jul 15, 2016 · 3 comments

Comments

@clapierre
Copy link
Contributor

clapierre commented Jul 15, 2016

http://www.idpf.org/accessibility/guidelines/content/nav/toc.php
Shouldn't there also be aria-hidden="true" here as well?
`

  • A linked heading
    1. Hidden subsection
  • `
    @mattgarrish
    Copy link
    Member

    No, aria-hidden is redundant in this case. It applies to content that is still visible but is not relevant for AT to present anymore. The hidden attribute hides the content from everyone.

    @clapierre
    Copy link
    Contributor Author

    Ok but in these two examples it has both the hidden and aria-hidden when is it needed?
    '

    ' and ' function toggleExample(ex, show) { if (show) { ex.removeAttribute("hidden"); ex.setAttribute("aria-hidden", "false"); } else { ex.setAttribute("hidden", "hidden"); ex.setAttribute("aria-hidden", "true"); } ]]> '

    @mattgarrish
    Copy link
    Member

    mattgarrish commented Jul 15, 2016

    Should be stripped from those examples. Harmless but redundant. See this page:
    https://www.paciellogroup.com/blog/2012/05/html5-accessibility-chops-hidden-and-aria-hidden/

    It's actually less well supported than hidden, or was at the time that was written.

    I can't think of a good case of where you'd leave content visible in a publication but hide it from AT, but I'm not as imaginative as the people the ARIA folks are trying to account for.

    The alternative case I remember for the toc was that you could hide branches using hidden but make them available only to AT using aria-hidden=false. But this is also bad design, and there's no actual support for unhiding hidden content this way.

    Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
    Labels
    None yet
    Projects
    None yet
    Development

    No branches or pull requests

    2 participants