Describe the bug
When using inside a
with an initialValue set, the input cannot be cleared by the user.
If the numeric value is deleted, the component automatically restores the initial value instead of allowing null or an empty state.
This behavior only occurs when initialValue is provided to the .
If initialValue is not set, can be cleared correctly.
Pull Request Link
No response
Reason for not contributing a PR
Other Reason
No response
Reproducer
https://stackblitz.com/edit/pxbps7wy?file=src%2FApp.vue
Environment
User Agent
Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/142.0.0.0 Safari/537.36
Vue version
3.2.45
PrimeVue version
4.5.4
Node version
No response
Browser(s)
Vivaldi 7.7.3851.67 > based on Chromium 142.0.7444.267
Steps to reproduce the behavior
- Open the StackBlitz reproduction link.
- Verify the behavior of the two rendered forms
Expected behavior
should allow being emptied (set to null) even when the form is initialized with initialValue
Describe the bug
When using inside a
with an initialValue set, the input cannot be cleared by the user.If the numeric value is deleted, the component automatically restores the initial value instead of allowing null or an empty state.
This behavior only occurs when initialValue is provided to the .
If initialValue is not set, can be cleared correctly.
Pull Request Link
No response
Reason for not contributing a PR
Other Reason
No response
Reproducer
https://stackblitz.com/edit/pxbps7wy?file=src%2FApp.vue
Environment
User Agent
Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/142.0.0.0 Safari/537.36
Vue version
3.2.45
PrimeVue version
4.5.4
Node version
No response
Browser(s)
Vivaldi 7.7.3851.67 > based on Chromium 142.0.7444.267
Steps to reproduce the behavior
Expected behavior
should allow being emptied (set to null) even when the form is initialized with initialValue