Commit f0860be6 authored by yiruiwen's avatar yiruiwen

1. 优化tabs组件滑块第一次滑动的状态

2. 优化test.mobile()对手机号规则的判断
parent 8968a8ef
......@@ -202,6 +202,7 @@
'transition-duration': `${this.barFirstTimeMove ? 0 : this.duration }s`,
'background-color': this.activeColor,
height: this.barHeight + 'rpx',
opacity: this.barFirstTimeMove ? 0 : 1,
// 设置一个很大的值,它会自动取能用的最大值,不用高度的一半,是因为高度可能是单数,会有小数出现
'border-radius': `${this.barHeight / 2}px`
};
......
......@@ -9,7 +9,7 @@ function email(value) {
* 验证手机格式
*/
function mobile(value) {
return /^1[23456789]\d{9}$/.test(value)
return /^1[3-9]\d{9}$/.test(value)
}
/**
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment