-
Notifications
You must be signed in to change notification settings - Fork 19
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
Return/Esc doesn't close editor after editing field #176
Comments
Handles cases where focus is lost (e.g. after making a selection in select box)
I've fixed a case where after following steps you've described, pressing Esc wouldn't close the editor.
Personally I don't think that's the case. In select boxes pressing Enter confirms selection (Tab also does, but most people will still press enter), thus I believe it should do the same (i.e. confirm change) in other fields, it actually works in text areas with Shift+Enter as well. |
I do think there's a difference between an autocomplete selection and pressing Return in the field. E.g., in Zotero, Return will select from the autocomplete, and the field stays open, and then Return again saves the entry and returns focus to the middle pane. But you may be right that people will press Return a lot once they've typed in a field and having it close the window would be annoying, so we can try it this way. |
After trying this out more I'm still not convinced that not closing the dialog on Return is right. I think it's important to remember that we're showing these as open text boxes, which makes them fairly equivalent to a web form where Return often submits the form. I think a drop-down is a different case — just how, in a web form, if there's an open drop-down, Return will make the selection but not submit the form. We should at the very least close on an unfocused Return — making that equivalent to Esc, which feels scarier to use, since it also cancels some of the time — but I still don't really see a reason why you shouldn't be able to just move through the dialog with Tab and then press Return when you're done. |
(Every time I use the editor to edit a field I find it frustrating that pressing Return after typing doesn't close it.) |
The field is saved, but neither Return nor Esc close the editor until something else if focused. Tested in Firefox.
But while we're fixing this, I think Return in a field should just close the editor. There's not really any other reason to press Return.
The text was updated successfully, but these errors were encountered: