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

"Recipient edit" form should handle [Enter] and [Escape] keys #7133

Closed
dboehmer opened this issue Dec 31, 2019 · 4 comments
Closed

"Recipient edit" form should handle [Enter] and [Escape] keys #7133

dboehmer opened this issue Dec 31, 2019 · 4 comments

Comments

@dboehmer
Copy link

The recipient fields like To were recently changed to show boxes for each recipient which can be edited by double-clicking on a box. The dialog to edit the recipient title Recipient edit should save on [Enter] and abort on [Escape] key press.

I found issue #3843 which claims making forms handle these keys is difficult. Hopyfully it's possible for this form because it's only 1 input element and it's a text input—so the user has their hand already on the keyboard and pressing [Enter] is a common thing.

I miss this behavior at other places, too. If I can understand how this is resolved I might try to send PRs to fix other locations as well.

@alecpl
Copy link
Member

alecpl commented Dec 31, 2019

I agree. It makes sense for forms with single input in dialogs. Because we have at least three more such dialogs, we should make it a general solution. The place to implement this will be show_popup_dialog() method in app.js.

ps. ESC should already work for most dialogs, it works for me in this one.

@dboehmer
Copy link
Author

Oh, you're right: Escape already works. I mixed up different forms. Can you link to a commit that adds the Escape function to any form? I could try to add this solution to other forms.

@alecpl
Copy link
Member

alecpl commented Dec 31, 2019

The ESC is handled by jQuery-UI Dialog, there's no custom code for that.

@alecpl
Copy link
Member

alecpl commented May 30, 2021

Implemented.

@alecpl alecpl closed this as completed May 30, 2021
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