Describe the bug
When using the InputNumber component with both min and max props set, it becomes difficult to input certain valid values due to aggressive auto-correction. This affects user experience and makes it unintuitive to edit the field.
Render the component with a default, min and max values as reported in the stackblitz link example.
Reproducer
https://stackblitz.com/edit/vitejs-vite-c14kqmbg?file=src%2FApp.tsx
System Information
PrimeReact version
10.9.6
React version
18.2
Language
ES6
Build / Runtime
Vite
Browser(s)
No response
Steps to reproduce the behavior
Attempt to type 0.5:
- Type 0 → the field auto-corrects to 0.2.
- Try to remove the 2 using the backspace key → the field reverts or resists change.
Expected behavior
The component should allow the user to enter any number that respects the defined constraints, without interfering with the input process before the number is complete. In this specific scenario the users should be able to freely input 0.5 without the component prematurely setting the value to the minimum 0.2.
Backspacing or editing the value manually should be possible without the field auto-correcting in a way that blocks input.
Describe the bug
When using the InputNumber component with both min and max props set, it becomes difficult to input certain valid values due to aggressive auto-correction. This affects user experience and makes it unintuitive to edit the field.
Render the component with a default, min and max values as reported in the stackblitz link example.
Reproducer
https://stackblitz.com/edit/vitejs-vite-c14kqmbg?file=src%2FApp.tsx
System Information
Steps to reproduce the behavior
Attempt to type 0.5:
Expected behavior
The component should allow the user to enter any number that respects the defined constraints, without interfering with the input process before the number is complete. In this specific scenario the users should be able to freely input 0.5 without the component prematurely setting the value to the minimum 0.2.
Backspacing or editing the value manually should be possible without the field auto-correcting in a way that blocks input.