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

Specify input validation errors #474

Open
noel-jasper opened this issue Mar 12, 2021 · 3 comments
Open

Specify input validation errors #474

noel-jasper opened this issue Mar 12, 2021 · 3 comments
Labels
Priority: Low Status: In Progress Type: Enhancement Refers to an enhancement or additional functionality

Comments

@noel-jasper
Copy link

qrl-wallet v1.7
win10
ledger nano s

Hey,
I'd appreciate some specific error messages for unexpected user input in the "Recipient" and "Amount" field on the "Send & Receive" page.
Right now there is this general message on a new view: "Transaction Generation Failed Error: Custom validation failed".

I tried to send 10.1 Quanta but typed "10,1" and it would have been helpful to see: "Invalid amount" or "amount input is not a valid number".

Of course, input validation onClick of the "Confirm" button would be even more helpful :) right now the validation seems to happen after the click and the next page with the general error message has no navigation buttons.
Therefore, I am forced to click on the left navbar and then have to confirm that I want to cancel the transaction. But that will reset the input fields so I have to start all over.

Error messages under the red-bordered input fields would be the most helpful way to figure out where the wrong input happened. Like this:
grafik

Keep up the good work 👍

@jplomas
Copy link
Contributor

jplomas commented Mar 12, 2021

Thanks for opening this issue.

We could make the input number (it is text at the moment) which would stop the user entering a comma, but the risk here is that pasting 1,21 actually gets interpreted as 121 (at least in Chrome where this behaviour has been noted) -- which is a definite no-go.

As it happens, we had most of the validation code in the wallet, and I've just looked at how straight-forward it would be to finish the implementation...

QRL_Wallet

The actual nuts-and-bolts of inline validation is complete on my local branch, will fix the UI (location of the amounts error message) then update the web wallet either at the weekend or next week, and this will be included in the next desktop wallet release (date TBC).

Again, thanks for the issue!

@jplomas
Copy link
Contributor

jplomas commented Mar 12, 2021

(the QRL address in screenshot above is invalid as the checksum is invalid!)

@jplomas jplomas added Priority: Low Status: In Progress Type: Enhancement Refers to an enhancement or additional functionality labels Mar 12, 2021
@noel-jasper
Copy link
Author

that was fast, thanks a lot!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Priority: Low Status: In Progress Type: Enhancement Refers to an enhancement or additional functionality
Projects
None yet
Development

No branches or pull requests

2 participants