Skip to content

πŸ”₯ πŸ”₯ πŸ”₯ A Free & Self-hostable Airtable Alternative

fix: check vModel value as well without formatting

Ramesh Mane2ee95469753e
diff --git a/packages/nc-gui/components/cell/Decimal/DecimalInput.vue b/packages/nc-gui/components/cell/Decimal/DecimalInput.vue
index 85737bb9fa..e3827689fa 100644
--- a/packages/nc-gui/components/cell/Decimal/DecimalInput.vue
+++ b/packages/nc-gui/components/cell/Decimal/DecimalInput.vue
@@ -210,7 +210,14 @@ onMounted(() => {
})
watch(vModel, (newValue) => {
- if (!inputRef.value || newValue || inputRef.value.value === getFormattedModelValue()) return
+ if (
+ !inputRef.value ||
+ newValue ||
+ inputRef.value.value === getFormattedModelValue() ||
+ inputRef.value.value === (newValue?.toString() || '')
+ ) {
+ return
+ }
// Clear input value if vModel is null and input value is not empty and not a dot or minus
if (!newValue && inputRef.value.value && !['.', '-'].includes(inputRef.value.value)) {