Enabling "Edit" to show all contextual links breaks tabbing in edit forms in the backend

Created on 9 August 2018, over 6 years ago
Updated 9 July 2023, over 1 year ago

This was quite the search before I figured out why I seemingly randomly couldn't tab through any forms.

But, when you enable "edit mode" on a frontend page so all contextual links are visible, and then you go to the backend (where that "edit mode" button isn't even visible and as far as I can remember contextual links aren't even used) a tabbingManager constraints is still being applied. Resulting in essentially no fields being tabbable.

This happens on every form. From node/add to /admin/config/system/site-information. If "edit mode" is enabled, and you check console log with devel_a11y you will see the following constraint active:

TabbingManager: tabbing contraint activated, level 0, 0 tabbable elements, 48 disabled elements.

Which is a constraint that restricts tabbing to only contextual links, of which there are none.

I don't know how to fix it though, Drupal's javascript isn't my forte. I know the constraint is set by AuralView.js (core/modules/contextual/js/toolbar/views/AuralView.es6.js) because the edit mode is still technically enabled, so I'd suggest automatically disabling edit mode when viewing the admin pages or skipping this part when viewing admin pages.

// Create a new tabbing context when edit mode is enabled.
      if (!this.model.get('isViewing')) {
        tabbingContext = Drupal.tabbingManager.constrain($('.contextual-toolbar-tab, .contextual'));
        this.model.set('tabbingContext', tabbingContext);
        this.announceTabbingConstraint();
        this.announcedOnce = true;
      }

This may need escalation to Major, as this essentially breaks the entire backend for the people it was meant to help in the first place.

🐛 Bug report
Status

Fixed

Version

10.0

Component
Contextual 

Last updated about 2 months ago

Created by

🇧🇪Belgium Grayle

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.

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.

Production build 0.71.5 2024