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

Don't allow the grid to steal focus on init #8495

Merged
merged 1 commit into from
Jul 28, 2020

Conversation

kjac
Copy link
Contributor

@kjac kjac commented Jul 28, 2020

Prerequisites

  • I have added steps to test this contribution in the description below

If there's an existing issue for this PR then this fixes #8324

Description

See also #8324 for a brilliant issue description

If a Grid configuration has only one layout and one row configuration, the property editor will automatically initialize itself with one layout + row. This makes sense. However, in combination with the excellent accessibility effort in #6804, this causes the grid to steal focus on init - most noticeably when creating new content:

grid-init-focus-before

This PR ensures that the auto-focus is not performed on init, but is retained on subsequent row additions to preserve the accessibility:

grid-init-focus-after

@nul800sebastiaan
Copy link
Member

Nice one @kjac! Thanks for this! 👍

@nul800sebastiaan nul800sebastiaan added release/8.8.0 release/no-notes This is too small to add to the release notes or fixed after a beta/RC labels Oct 1, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
release/no-notes This is too small to add to the release notes or fixed after a beta/RC release/8.8.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Focus issue when creating new page w. grid in backoffice
2 participants