mirror of
https://gitee.com/vant-contrib/vant.git
synced 2025-05-02 14:16:35 +08:00
docs(Stepper): fix async change demo (#7703)
This commit is contained in:
parent
2e6b032464
commit
af81912210
@ -88,7 +88,8 @@ export default {
|
|||||||
onChange(value) {
|
onChange(value) {
|
||||||
Toast.loading({ forbidClick: true });
|
Toast.loading({ forbidClick: true });
|
||||||
|
|
||||||
setTimeout(() => {
|
clearTimeout(this.timer);
|
||||||
|
this.timer = setTimeout(() => {
|
||||||
Toast.clear();
|
Toast.clear();
|
||||||
this.value = value;
|
this.value = value;
|
||||||
}, 500);
|
}, 500);
|
||||||
|
@ -110,9 +110,9 @@ export default {
|
|||||||
onChange(value) {
|
onChange(value) {
|
||||||
Toast.loading({ forbidClick: true });
|
Toast.loading({ forbidClick: true });
|
||||||
|
|
||||||
setTimeout(() => {
|
clearTimeout(this.timer);
|
||||||
|
this.timer = setTimeout(() => {
|
||||||
Toast.clear();
|
Toast.clear();
|
||||||
|
|
||||||
// 注意此时修改 value 后会再次触发 change 事件
|
// 注意此时修改 value 后会再次触发 change 事件
|
||||||
this.value = value;
|
this.value = value;
|
||||||
}, 500);
|
}, 500);
|
||||||
|
@ -91,7 +91,8 @@ export default {
|
|||||||
onChange(value) {
|
onChange(value) {
|
||||||
this.$toast.loading({ forbidClick: true });
|
this.$toast.loading({ forbidClick: true });
|
||||||
|
|
||||||
setTimeout(() => {
|
clearTimeout(this.timer);
|
||||||
|
this.timer = setTimeout(() => {
|
||||||
this.stepper6 = value;
|
this.stepper6 = value;
|
||||||
this.$toast.clear();
|
this.$toast.clear();
|
||||||
}, 500);
|
}, 500);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user