🐛(input-number): 修复手动输入拼接字符串的问题
This commit is contained in:
parent
11c793c7b1
commit
6a3fa5116e
@ -113,7 +113,7 @@ const inputChange = function () {
|
|||||||
};
|
};
|
||||||
|
|
||||||
const isNumber = function (num: any) {
|
const isNumber = function (num: any) {
|
||||||
return /^\d+(\.\d+)?$/.test(num);
|
return !isNaN(num)
|
||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
@ -13,6 +13,7 @@
|
|||||||
::: demo 使用 `lay-input-number` 标签, 创建数字输入框
|
::: demo 使用 `lay-input-number` 标签, 创建数字输入框
|
||||||
|
|
||||||
<template>
|
<template>
|
||||||
|
{{data1}}
|
||||||
<lay-input-number v-model="data1"></lay-input-number>
|
<lay-input-number v-model="data1"></lay-input-number>
|
||||||
<lay-input-number v-model="data2" position="right"></lay-input-number>
|
<lay-input-number v-model="data2" position="right"></lay-input-number>
|
||||||
</template>
|
</template>
|
||||||
|
Loading…
Reference in New Issue
Block a user