Skip to content
GitLab
    • Explore Projects Groups Snippets
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
  • A a11yproject.com
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 40
    • Issues 40
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 10
    • Merge requests 10
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Packages and registries
    • Packages and registries
    • Package Registry
    • Infrastructure Registry
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • The A11Y Project
  • a11yproject.com
  • Merge requests
  • !532
An error occurred while fetching the assigned milestone of the selected merge_request.

Remove role="navigation" from example

  • Review changes

  • Download
  • Email patches
  • Plain diff
Merged Administrator requested to merge github/fork/albertoconnor/patch-1 into gh-pages 7 years ago
  • Overview 13
  • Commits 3
  • Pipelines 0
  • Changes 1

Created by: albertoconnor

There is some contention about whether or not <nav> is semantically the same as <nav role="navigation">, but the October 2014 version of the HTML spec seems to indicate it shouldn't be set:

https://www.w3.org/TR/html5/sections.html#the-nav-element

Even if <nav> implicitly having the "navigation" landmark isn't fully implemented by all screen readers, I would think this documentation should be aspirational, showing how things will be.

Having <nav role="navigation"> contradicts the important, and I think generally hard to grasp the idea, that redundant roles should not be used. Part of the reason it is hard to grasp due to a proliferation of incorrect examples.

That being said having role="navigation" still may be practical and a good idea currently, but if so my feeling is that should be explained.

Compare
  • gh-pages (base)

and
  • latest version
    9c28a5f2
    3 commits, 2 years ago

1 file
+ 2
- 2

    Preferences

    File browser
    Compare changes
_posts/2014-05-15-getting-started-aria.md
+ 2
- 2
  • View file @ 9c28a5f2

  • Edit in single-file editor

  • Open in Web IDE


@@ -64,10 +64,10 @@ To create accessible applications, basic principles of semantic HTML, keyboard s
## ARIA Examples
* Landmark role
The `<nav>` element has been given a landmark role allowing screen reader users navigate directly to this element.
 The `<nav>` element implicitly has a landmark role of `navigation` allowing screen reader users to navigate directly to this element. Review the article [Quick Tip: Aria Landmark Roles and HTML5 Implicit Mapping](http://a11yproject.com/posts/aria-landmark-roles/) for more information.
~~~~~~~~
<nav role="navigation">
<nav>
<ul>
<li>
<a href="/">Home</a>
0 Assignees
None
Assign to
0 Reviewers
None
Request review from
Labels
0
None
0
None
    Assign labels
  • Manage project labels

Milestone
No milestone
None
None
Time tracking
No estimate or time spent
Lock merge request
Unlocked
0
0 participants
Reference:
Source branch: github/fork/albertoconnor/patch-1

Menu

Explore Projects Groups Snippets