Join GitHub today
Keyboard navigation when inserting a block has unexpected behaviour #9583
Describe the bug
I can reproduce this in the side inserter. The main inserter in the top bar seems not affected.
When the caret is in the search field, users could try using the arrow keys. Both left / right and up / down arrows trigger the writing flow, and focus goes to the blocks list.
This is not the expected behavior: when the caret is within a standard input field, for no reason, ever, arrows should move focus away. The native behavior should be preserved.
Wild guess: some event that needs to stop propagation (as noted in other issues, this should be the default in most of the cases in Gutenberg).
referenced this issue
Sep 3, 2018
I'd suggest to consider this issue together with #6468
Basically, this requires to make a decision about where Writing Flow should work. Currently, it works on any focusable element in the post content (post title + blocks list). However, there are native input fields, buttons, and other focusable elements rendered within the blocks list where Writing Flow should not conflict with native behavior of the arrow keys. The native interaction with native input fields should always be preserved, as that's the expected interaction in terms of both usability and accessibility.
I'd strongly recommend to make Writing Flow work only through textual content. After all, that's what it was designed for initially: to make the writing experience similar to the one users have in word editors. This shouldn't include native UI controls or other focusable elements that are not text.