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

Keyboard trap upon tabbing into editor #81

Closed
marcysutton opened this issue Aug 1, 2018 · 1 comment
Closed

Keyboard trap upon tabbing into editor #81

marcysutton opened this issue Aug 1, 2018 · 1 comment

Comments

@marcysutton
Copy link
Contributor

marcysutton commented Aug 1, 2018

Keyboard-only users get stuck in a keyboard trap when tabbing into the editor. It makes it impossible to exit, a huge blocker for people who can't use a mouse or trackpad. One quick and dirty solution would be to wire up the escape key once you tab into the text editor...maybe it could send focus to the next tab stop, allowing you to keep going through the page?

In an ideal world, editing with the keyboard would only start once you'd pressed an "enable editor" button, where combined with the escape key to exit, the user would thus be making a more conscious choice to toggle edit mode. But that would be a way bigger change, where an escape key + focus management might do the trick in the meantime. I'll try to put a PR together since I have to fix this for our site.

Edit: this must have started occurring in the latest version, because I'm not experiencing a keyboard trap with an older one.

marcysutton pushed a commit to marcysutton/CodeFlask that referenced this issue Aug 3, 2018
WIP tests. Need to find a way to assert this behavior

Closes kazzkiq#81
@marcysutton
Copy link
Contributor Author

I decided to add an option to override the tab key behavior instead, which was a pretty easy solution leveraging the existing code. See PR #82.

marcysutton pushed a commit to marcysutton/CodeFlask that referenced this issue Nov 1, 2018
The default behavior of disableTabs: false will capture the TAB key inside of the editor, however this creates an inaccessible keyboard trap. By adding `disableTabs: true`, Codeflask will not capture the TAB key and allow users to tab on by.

Tests are still a WIP

Closes kazzkiq#81
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants