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

Make keyboard friendly enough #708

Merged
merged 3 commits into from
Nov 22, 2022
Merged

Make keyboard friendly enough #708

merged 3 commits into from
Nov 22, 2022

Conversation

nikku
Copy link
Member

@nikku nikku commented Nov 22, 2022

Ensure we play nice with other UI components up in the component tree; rather than handling keys on capture, handle events on bubble. Ignore events that got their propagation stopped or their default prevented.

A result of this PR is that components downwards in the component tree can use standard DOM facilities to prevent the event from being handled by keyboard:

friendly-keyboard excalidraw


Closes #707

@bpmn-io-tasks bpmn-io-tasks bot added the in progress Currently worked on label Nov 22, 2022
@nikku nikku changed the title 707 friendly enough keyboard Make keyboard friendly enough Nov 22, 2022
@nikku nikku requested review from barmac and smbea November 22, 2022 17:12
@nikku nikku marked this pull request as ready for review November 22, 2022 17:31
@bpmn-io-tasks bpmn-io-tasks bot added needs review Review pending and removed in progress Currently worked on labels Nov 22, 2022
@nikku
Copy link
Member Author

nikku commented Nov 22, 2022

I did integration test this against bpmn-js and found #709 (unrelated to this change).

Ensure we play nice with other UI components up in the component
tree; rather than handling keys on capture, handle events on bubble.

Ignore events that got their propagation stopped or their default
prevented.

Closes #707
Copy link
Contributor

@smbea smbea left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is what we talked about 👍. Also great to have the added test cases

@nikku nikku merged commit ce1f81f into develop Nov 22, 2022
@nikku nikku deleted the 707-friendly-enough-keyboard branch November 22, 2022 21:02
@bpmn-io-tasks bpmn-io-tasks bot removed the needs review Review pending label Nov 22, 2022
@barmac
Copy link
Member

barmac commented Nov 23, 2022

Great improvement 👏

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

Successfully merging this pull request may close these issues.

Make keyboard more friendly
3 participants