-
Notifications
You must be signed in to change notification settings - Fork 85
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
fix: check for bad input when updating _hasInputValue #5092
fix: check for bad input when updating _hasInputValue #5092
Conversation
Kudos, SonarCloud Quality Gate passed!
|
Hi @vursen , this commit cannot be picked to 23.3 by this bot, can you take a look and pick it manually? |
I'm not sure if we should cherry-pick this now, but it's probably worth doing. In the future we might want to backport the whole set of validation improvements to a future minor e.g. |
Sounds reasonable, let's cherry-pick it while it is fresh in our minds. |
This ticket/PR has been released with Vaadin 24.0.0.alpha6 and is also targeting the upcoming stable 24.0.0 version. |
Description
Native [type=number] inputs don't update their value when you are entering input that the browser is unable to parse e.g.
--5
which results in_hasInputValue
not being updated either. To work this out, the PR modifies the computation of_hasInputValue
fornumber-field
so that it would additionally check for bad input based on the nativevalidity.badInput
property and then update_hasInputValue
accordingly.Related to vaadin/flow-components#4272
Part of vaadin/platform#3066.
Type of change
Checklist