-
Notifications
You must be signed in to change notification settings - Fork 25
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
Prevent the enter key to submit the form in some fields that may be filled though a scanning device #1421
Comments
I disagree. This is a default behaviour and a best practice to submit a web form using the enter key. This is the case for example on every google form (login, etc.). Moreover since the submitting the form display the validation error it still useful. We needs to fix this wrong behaviour for scan device if it is needed. |
@iGormilhit What is your opinion? Should we close this issue, considering that this is a setting to do in the scan device? |
@pronguen I'm pretty sure that at least once I've encountered the issue of hitting the enter key to do something and was surprised to see the form being submitted. @jma is right, but I think we need to identify in which situation hitting the enter key does not what the user is expecting. I'm going to make some tests and verify about a barcode scanner. |
@jma @iGormilhit I know that it could be a default behaviour in a standard environment. But in libraries, there are barcodes and scanning devices everywhere. |
@pronguen I agree. I think that at least in the forms like documents, we could at least try to prevent the enter key to submit the form in specific fields such as Identifiers. Thus we will keep:
I propose to transform this issue in "Prevent the enter key to submit the form in some fields". And then to provide a list in the description of the issue. |
* Prevents the enter key to submit the form in some fields that may be filled though a scanning device. * Closes rero#1421. Co-Authored-by: Johnny Mariéthoz <johnny.mariethoz@rero.ch>
* Prevents the enter key to submit the form in some fields that may be filled though a scanning device. * Closes rero#1421. Co-Authored-by: Johnny Mariéthoz <johnny.mariethoz@rero.ch>
* Prevents the enter key to submit the form in some fields that may be filled though a scanning device. * Closes rero#1421. Co-Authored-by: Johnny Mariéthoz <johnny.mariethoz@rero.ch>
* Prevents the enter key to submit the form in some fields that may be filled though a scanning device. * Closes rero#1421. Co-Authored-by: Johnny Mariéthoz <johnny.mariethoz@rero.ch>
* Prevents the enter key to submit the form in some fields that may be filled though a scanning device. * Closes rero#1421. Co-Authored-by: Johnny Mariéthoz <johnny.mariethoz@rero.ch>
* Prevents the enter key to submit the form in some fields that may be filled though a scanning device. * Closes rero#1421. Co-Authored-by: Johnny Mariéthoz <johnny.mariethoz@rero.ch>
* Prevents the enter key to submit the form in some fields that may be filled though a scanning device. * Closes #1421. Co-Authored-by: Johnny Mariéthoz <johnny.mariethoz@rero.ch>
How it works
When editing a resource in a form, using the "enter" key saves the form. This is not the case for text area input fields.
The user does not expect this behaviour.
When entering an ISBN with a scan device configured for checkout; the device automatically sends an "enter" to the system. When this happen in a document editor form, the form is submitted but should not.
Improvement suggestion
Disable the default enter key behavior in specific fields such as identifiers, or barcodes:
identifiedBy.value
barcode
barcode
Disable the enter key for the whole ILL request form in the public interface (the ideal enhancement, for later, is described here: #1771)
The text was updated successfully, but these errors were encountered: