-
Notifications
You must be signed in to change notification settings - Fork 36
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
[1333]close modals/overlays on escape #1335
Conversation
…ask and stage configurator modals on escape part of #1333
…ration modal on escape
…ntrib install modal on escape
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is cool. I found a bug and a couple cases where the esc
handler is missing.
Bug
In the trigger configuration modal we have a confirmation for closing the modal if there are pending changes. In that case the confirmation submodal can be opened more than once and it enters a loop where the confirmation cannot be closed with keyboard.
This can be tricky to handle, we have to make the confirmation modal "own" the esc
key or somehow make the parent modal ignore the esc
event while confirmation is open and let the confirmation handle it instead.
Steps to reproduce:
- Open trigger configurator and make changes to a trigger
- Hit
esc
key. The confirmation modal will pop up - Hit
esc
key again, another confirmation will open
Missing esc
handler
In apps page:
- Export
- App (For confirmation modal that only appears when app has 0 triggers)
- Actions
- Modal for selecting shim trigger
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Look good to me now. One thing we need to add though is that we need to add a keyboard trap in the close confirmation for trigger so tabbing cycles through close, continue, save and discard. Currently the focus is set in the fields behind the confirmation modal.
Description
Close below mentioned modals/overlays on escape key press
Part of #1333
How has this been tested?
Tested manually
Types of changes
Checklist: