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

Font Library: Focus loss when deleting fonts and possibly other flows #58893

Closed
afercia opened this issue Feb 9, 2024 · 0 comments · Fixed by #59036
Closed

Font Library: Focus loss when deleting fonts and possibly other flows #58893

afercia opened this issue Feb 9, 2024 · 0 comments · Fixed by #59036
Labels
[Feature] Font Library [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

@afercia
Copy link
Contributor

afercia commented Feb 9, 2024

Description

I'm not sure this ha been already tracked but there are more focus losses in the FOnts modal dialog than the one already fixed in #58314

For example, when deleting a font the whole content of the modal dialog updates and the delete button that had keyboard focus disappers. As such, focus is entirely lost. Pressing tab again starts the tab sequence from scratch from the document root outside of the modal dialog which is something that should never ever happen.

See attached animated GIF to better illustrate.

Possibly, there are more flows where focused element get dynamically hidden / removed thus triggering more focus losses.

loss

Step-by-step reproduction instructions

  • Make sure you already have some custom fonts installed, e.g. a Google font.
  • Go to Site editor > Styles > Typography > Manage fonts.
  • Use the keyboard to navigate the modal dialog focusable elements.
  • In the Library tab, select an installed custom font of your choice.
  • In the sub-view with the font details, the Delete button and press Enter.
  • In the confirm dialog tab to the Delete button and press Enter.
  • Wait for the font deletion to complete successfully.
  • The confirm dialog closes.
  • Press the tab key.
  • Observe focus is lost and the tab sequence starts from scratch from the 'Open Navigation' WP logo in the editor UI outside of the modal dialog.

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

@afercia afercia added [Type] Bug An existing feature does not function as intended [Focus] Accessibility (a11y) Changes that impact accessibility and need corresponding review (e.g. markup changes). [Feature] Font Library labels Feb 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[Feature] Font Library [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
Status: Done
Development

Successfully merging a pull request may close this issue.

1 participant