Environment
Vuetify Version: 4.1.8
Vue Version: 3.5.30
OS: Windows 10 (current)
Steps to reproduce
- Create a VNumberInput with a v-model or :model-value &
@update:model-value combination.
- Add some custom rules to be applied to the modelValue when it is updated - e.g. manually enforce a minimum limit of 0.
- Use the spin buttons to reach a value outside the manually enforced limits.
Expected Behavior
When intercepting a model-value change and changing the value, the displayed value in the number input should update accordingly
Actual Behavior
When the spin buttons are used to increment or decrement the value past manually enforced limits, the displayed value retains an incorrect further step even though the value modelValue has been corrected.
Reproduction Link
https://play.vuetifyjs.com/#...
Other comments
I believe this is occurring because the display value is updated before the changed modelValue is emitted. When the modelValue is emitted, it is manually changed. If that changed value is the same as the previous ticks value (which is usually the case), no change in value is detected and thus the display value is not refreshed, thus breaking the synchronization between it and the modelValue. The modelValue does change correctly, which can be confirmed by stepping the other direction with the spin buttons and seeing the resulting step "skip".
Environment
Vuetify Version: 4.1.8
Vue Version: 3.5.30
OS: Windows 10 (current)
Steps to reproduce
@update:model-valuecombination.Expected Behavior
When intercepting a model-value change and changing the value, the displayed value in the number input should update accordingly
Actual Behavior
When the spin buttons are used to increment or decrement the value past manually enforced limits, the displayed value retains an incorrect further step even though the value modelValue has been corrected.
Reproduction Link
https://play.vuetifyjs.com/#...
Other comments
I believe this is occurring because the display value is updated before the changed modelValue is emitted. When the modelValue is emitted, it is manually changed. If that changed value is the same as the previous ticks value (which is usually the case), no change in value is detected and thus the display value is not refreshed, thus breaking the synchronization between it and the modelValue. The modelValue does change correctly, which can be confirmed by stepping the other direction with the spin buttons and seeing the resulting step "skip".