From ac5da5d9b4809121339ff08bf8726785dbceb666 Mon Sep 17 00:00:00 2001 From: HRK <119110706+18148764734@users.noreply.github.com> Date: Fri, 26 Apr 2024 15:02:24 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20numbox=20=E5=9C=A8vue2=E6=89=8B=E5=8A=A8?= =?UTF-8?q?=E8=BE=93=E5=85=A5=E5=90=8E=E5=A4=B1=E7=84=A6=E5=AF=BC=E8=87=B4?= =?UTF-8?q?=E6=B8=85=E7=A9=BA=E6=95=B0=E5=80=BC=E7=9A=84=E4=B8=A5=E9=87=8D?= =?UTF-8?q?bug?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- uni_modules/uni-number-box/changelog.md | 2 ++ .../components/uni-number-box/uni-number-box.vue | 4 ++-- uni_modules/uni-number-box/package.json | 5 +++-- 3 files changed, 7 insertions(+), 4 deletions(-) diff --git a/uni_modules/uni-number-box/changelog.md b/uni_modules/uni-number-box/changelog.md index 010c67de..5190ae20 100644 --- a/uni_modules/uni-number-box/changelog.md +++ b/uni_modules/uni-number-box/changelog.md @@ -1,3 +1,5 @@ +## 1.2.7(2024-04-26) +- 修复 在vue2手动输入后失焦导致清空数值的严重bug ## 1.2.6(2024-02-22) - 新增 设置宽度属性width(单位:px) ## 1.2.5(2024-02-21) diff --git a/uni_modules/uni-number-box/components/uni-number-box/uni-number-box.vue b/uni_modules/uni-number-box/components/uni-number-box/uni-number-box.vue index 987364f1..407a42eb 100644 --- a/uni_modules/uni-number-box/components/uni-number-box/uni-number-box.vue +++ b/uni_modules/uni-number-box/components/uni-number-box/uni-number-box.vue @@ -145,7 +145,7 @@ this.$emit('blur', event) let value = event.detail.value; if (isNaN(value)) { - this.inputValue = this.min; + this.inputValue = this.value; return; } value = +value; @@ -230,4 +230,4 @@ cursor: not-allowed; /* #endif */ } - + diff --git a/uni_modules/uni-number-box/package.json b/uni_modules/uni-number-box/package.json index 12f3e05d..f16ca3a8 100644 --- a/uni_modules/uni-number-box/package.json +++ b/uni_modules/uni-number-box/package.json @@ -1,7 +1,7 @@ { "id": "uni-number-box", "displayName": "uni-number-box 数字输入框", - "version": "1.2.6", + "version": "1.2.7", "description": "NumberBox 带加减按钮的数字输入框组件,用户可以控制每次点击增加的数值,支持小数。", "keywords": [ "uni-ui", @@ -41,7 +41,8 @@ "platforms": { "cloud": { "tcb": "y", - "aliyun": "y" + "aliyun": "y", + "alipay": "n" }, "client": { "App": {