Skip to content
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

Site editor: shift tab from the first block, or tab from the last block not working as expected #41811

Closed
talldan opened this issue Jun 20, 2022 · 0 comments · Fixed by #42036
Assignees
Labels
[Feature] Writing Flow Block selection, navigation, splitting, merging, deletion... [Focus] Accessibility (a11y) Changes that impact accessibility and need corresponding review (e.g. markup changes). [Type] Bug An existing feature does not function as intended

Comments

@talldan
Copy link
Contributor

talldan commented Jun 20, 2022

Description

I noticed that shift-tab (used to access the block toolbar) and tab (used to access the block inspector) aren't working as expected in the site editor. A JS error is being thrown:

Uncaught TypeError: Cannot destructure property 'tagName' of 'element' as it is undefined.
    at isFormElement (is-form-element.js:15:10)
    at HTMLBodyElement.onKeyDown (use-tab-nav.js:121:18)

Things seem to work ok in the post editor.

Step-by-step reproduction instructions

Shift-tabbing

  1. Select the first block (usually a header template part, selecting via list view makes this easier)
  2. Press shift tab

Expected - the toolbar is focused
Actual - nothing happens visually, a JS error is thrown

Tabbing

  1. Add an image block as the last block and select it
  2. Tab through the buttons in the placeholder and keep pressing tab

Expected - the block inspector is focused
Actual - nothing happens visually, a JS error is thrown

Screenshots, screen recording, code snippet

No response

Environment info

No response

Please confirm that you have searched existing issues in the repo.

Yes

Please confirm that you have tested with all plugins deactivated except Gutenberg.

Yes

@talldan talldan added [Type] Bug An existing feature does not function as intended [Feature] Writing Flow Block selection, navigation, splitting, merging, deletion... [a11y] Keyboard & Focus labels Jun 20, 2022
@talldan talldan self-assigned this Jun 28, 2022
@github-actions github-actions bot added the [Status] In Progress Tracking issues with work in progress label Jun 29, 2022
@priethor priethor removed the [Status] In Progress Tracking issues with work in progress label May 22, 2023
@priethor priethor added the [Focus] Accessibility (a11y) Changes that impact accessibility and need corresponding review (e.g. markup changes). label Jul 24, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[Feature] Writing Flow Block selection, navigation, splitting, merging, deletion... [Focus] Accessibility (a11y) Changes that impact accessibility and need corresponding review (e.g. markup changes). [Type] Bug An existing feature does not function as intended
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants