"Skip to main content" should link to main tag or similar

Created on 15 August 2016, about 8 years ago
Updated 15 February 2024, 9 months ago

Problem/Motivation

Currently most (all) D8 themes 'Skip to content' link target the markup:

<a id="main-content" tabindex="-1"></a>

When we should be targeting something like:

<main id="main-content" role="main" tabindex="-1"></main>

This extra a tag that's missing an href attribute and textual content, isn't really needed and should be removed.

Steps to reproduce

Proposed resolution

TBD

Remaining tasks

Address follow up tag
Accessibility review
Change record

User interface changes

TBD

API changes

TBD

Data model changes

TBD

Release notes snippet

TBD

📌 Task
Status

Closed: cannot reproduce

Version

11.0 🔥

Component
System 

Last updated 7 days ago

No maintainer
Created by

🇬🇧United Kingdom Jmdrawneek@googlemail.com

Live updates comments and jobs are added and updated live.
  • Accessibility

    It affects the ability of people with disabilities or special needs (such as blindness or color-blindness) to use Drupal.

  • Needs accessibility review

    Used to alert the accessibility topic maintainer(s) that an issue significantly affects (or has the potential to affect) the accessibility of Drupal, and their signoff is needed (see the governance policy draft for more information). Useful links: Drupal's accessibility standards, the Drupal Core accessibility gate.

Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

  • The Needs Review Queue Bot tested this issue. It either no longer applies to Drupal core, or fails the Drupal core commit checks. Therefore, this issue status is now "Needs work".

    Apart from a re-roll or rebase, this issue may need more work to address feedback in the issue or MR comments. To progress an issue, incorporate this feedback as part of the process of updating the issue. This helps other contributors to know what is outstanding.

    Consult the Drupal Contributor Guide to find step-by-step guides for working with issues.

  • 🇨🇦Canada mgifford Ottawa, Ontario

    Adding for Bypass Blocks SC.

  • 🇮🇳India rhithwik

    With https://www.drupal.org/project/drupal/issues/2784311#comment-13367850 📌 "Skip to main content" should link to main tag or similar Needs work in the custom theme in my project, it solves issue from continuum scan error. The alternative approach tried was to add role="none", which also solves the same issue from continuum scan.

  • First commit to issue fork.
  • last update about 1 year ago
    30,060 pass
  • @rpayanm opened merge request.
  • Status changed to Needs review about 1 year ago
  • 🇺🇾Uruguay rpayanm

    I rerolled the patch from #77.

    Please review.

  • Status changed to Needs work about 1 year ago
  • 🇺🇸United States smustgrave

    Was tagged for a followup 7 years ago is that still needed?

    Started the IS but it will need some updating too.

  • 🇺🇦Ukraine HitchShock Ukraine

    Reroled the last successful patch #77

  • last update 11 months ago
    29,722 pass
  • 🇺🇸United States goose2000

    I'm just mainly following, I need a theme that does ARIA landmark role="main" correctly; working on a university project. I was surprised to see this doesn't yet exist in D10.2 Olivero. I guess I can override this somehow until patches are in core.

    <!-- END OUTPUT from 'core/themes/olivero/templates/layout/region--secondary-menu.html.twig' -->
    
       </div>
         </div>
           </div>
             </div>
             </header>
        <div id="main-wrapper" class="layout-main-wrapper layout-container">
          <div id="main" class="layout-main">
            <div class="main-content">
              <a id="main-content" tabindex="-1"></a> 
              <div class="main-content__container container">
                
    
  • Status changed to Closed: cannot reproduce 9 months ago
  • 🇺🇸United States mherchel Gainesville, FL, US

    Discussed within Accessibility office hours February 15th (today) with several folks including A11y maintainers Mike Gifford and Ben Mullins.

    This is a very low priority, and we're struggling to figure out the problem that this is solving. A potential problem, that's not in the IS, is that maybe the named anchor link will get styled unnecessarily, but I haven't seen this.

    According to Ben Mullins, we need evidence that this is a problem, which we do not have. Closing and if anyone can post evidence that this is a real problem, please re-open.

Production build 0.71.5 2024