diff --git a/src/area-cascader.vue b/src/area-cascader.vue index eddbad0..c4fc940 100644 --- a/src/area-cascader.vue +++ b/src/area-cascader.vue @@ -119,7 +119,7 @@ methods: { beforeSetDefault () { - const chinese = /^[\u4E00-\u9FA5\uF900-\uFA2D]{3,}$/; + const chinese = /^[\u4E00-\u9FA5\uF900-\uFA2D]{2,}$/; const num = /^\d{6,}$/; const isCode = num.test(this.value[0]); let isValid; diff --git a/src/area-select.vue b/src/area-select.vue index 9da7791..a9f3f9f 100644 --- a/src/area-select.vue +++ b/src/area-select.vue @@ -237,7 +237,7 @@ }, beforeSetDefault () { - const chinese = /^[\u4E00-\u9FA5\uF900-\uFA2D]{3,}$/; + const chinese = /^[\u4E00-\u9FA5\uF900-\uFA2D]{2,}$/; const num = /^\d{6,}$/; const isCode = num.test(this.value[0]); let isValid;