-
Notifications
You must be signed in to change notification settings - Fork 24
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
Improve vaadin-number-field #292
Improve vaadin-number-field #292
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If you use the stepper controls for increasing/decreasing the value, we probably don't want the field to unnecessarily get focused. Focusing the input opens the virtual keyboard on mobile which might be undesired. @jouni wdyt?
Yes, I agree with Tomi. |
d638e9b
to
c7d6c17
Compare
Removed input focus when using the stepper controls. |
As I've been implementing this I have noticed that trying to validate the
And thus I don't know what actually is typed in the number field when I'm relying on the browser's validated value of the number field. So instead of using
I'd be in favor of option 2. BTW I haven't implemented either of these yet. @tomivirkki LMKWYT. I can discuss more about this. |
|
@samiheikki UX of the last number field on the demo page (with steps) is pretty unexpected when using keyboard (both desktop and mobile). Can something be done about it? |
@tomivirkki That could be achieved by adding But then it won't validate the step when input value changes. So not sure which is more correct behaviour. |
* Improve vaadin-number-field * Fix value control buttons focusing behavior for touch * Add browser native validation behaviour
* Implement number-field * Include number-field demos in demos suite * Align the name of the file with number field demo with other demos * The reference to native input has changed. Fixed tests * move number field to src, and create its lumo file * Update screenshots * Validate against min, max. Synchronize input value * Disable buttons on readonly * Fix min/max limits when set to zero * Simply code by reducing conditional blocks * Disable buttons when limits have been reached * Align with master * Adding step feature and focus input on click. * Improve vaadin-number-field (#292) * Improve vaadin-number-field * Fix value control buttons focusing behavior for touch * Add browser native validation behaviour
Connects to #296
This change is![Reviewable](https://camo.githubusercontent.com/23b05f5fb48215c989e92cc44cf6512512d083132bd3daf689867c8d9d386888/68747470733a2f2f72657669657761626c652e696f2f7265766965775f627574746f6e2e737667)