InputNumber: setting "min" to anything greater than 0 implies "required"
I'm submitting a ... (check one with "x")
[x] bug report => Search github for a similar issue or PR before submitting
[ ] feature request => Please check if request is not on the roadmap already https://github.com/primefaces/primeng/wiki/Roadmap
[ ] support request => Please do not submit support request here, instead see http://forum.primefaces.org/viewforum.php?f=35
Plunkr Case (Bug Reports)
See https://github-tlqtev.stackblitz.io
Current behavior
A min value greater than 0 on a p-inputNumber implies required, while a min value of 0 or less does not.
Expected behavior
Clicking in and out of a p-inputNumber with min > 0 leaves it empty. Deleting a value, which has min > 0 is allowed. In other words: min does not imply required.
Minimal reproduction of the problem with instructions
Open the StackBlitz above, and one-by-one click into each of the p-inputNumber, and finally on the blank page again. Just click, don't enter anything. Afterwards, I would expect having:
- empty
- empty
- empty
- empty
but I get:
- empty
- empty
- 1
- 2
What is the motivation / use case for changing the behavior?
It is at the very least inconsistent.
Please tell us about your environment:
Not really relevant I guess. Reproducible on whatever StackBlitz is running at the time of writing.
-
Browser I tried with (all on Linux Mint 20) - all affected:
- Firefox 87.0
- Chromium 84.0.4147.135
- Opera 75.0.3969.93
- Microsoft Edge 91.0.831.1
I can confirm that i have the same problem with PrimeNG v9. It's really restrictive ! Could someone fix this asap ? Thanks
@J2BB do you happen to know what the policy on PRs is in PrimeNG, i.e. if it even makes sense to open one to speed-up things? I am under the impression the team is currently just overloaded with work and reviewing stuff, so I'm not sure if opening a PR would actually do more harm than good.