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: The preview frame can have edits triggered by keyboard #69154

Open
3 of 6 tasks
stokesman opened this issue Feb 11, 2025 · 0 comments · May be fixed by #69132
Open
3 of 6 tasks

Site editor: The preview frame can have edits triggered by keyboard #69154

stokesman opened this issue Feb 11, 2025 · 0 comments · May be fixed by #69132
Labels
[Package] Block editor /packages/block-editor [Type] Bug An existing feature does not function as intended

Comments

@stokesman
Copy link
Contributor

Description

In the Site editor tabbing through the interface can focus the site preview and while focused the keyboard can be used to “Select All” and the the block toolbar is accessible and edits can be made. There may be other ways keyboard use can trigger edits too.

The cause of this is the writing flow hook is active so the when the body of the iframe has focus there is the potential to trigger its behaviors.

Step-by-step reproduction instructions

  1. Open the Site editor
  2. Tab to the preview frame
  3. Use the “Select all” shortcut
  4. Press Shift tab to focus the block toolbar
  5. Use arrow keys to navigate the block toolbar
  6. Trigger an edit of some kind

Screenshots, screen recording, code snippet

site-editor-preview-unintended-keyboard-editable.mp4

Environment info

  • WP 6.7.1 with Gutenberg plugin at trunk
  • Chrome
  • macOS

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

Please confirm which theme type you used for testing.

  • Block
  • Classic
  • Hybrid (e.g. classic with theme.json)
  • Not sure
@stokesman stokesman added [Type] Bug An existing feature does not function as intended [Package] Block editor /packages/block-editor labels Feb 11, 2025
@stokesman stokesman linked a pull request Feb 11, 2025 that will close this issue
@stokesman stokesman linked a pull request Feb 11, 2025 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[Package] Block editor /packages/block-editor [Type] Bug An existing feature does not function as intended
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant