Commit 39564cb7 authored by Geeku's avatar Geeku Committed by 杨奕

carousel: be able to switch autoplay state

parent 0d5b7c03
...@@ -109,6 +109,10 @@ export default { ...@@ -109,6 +109,10 @@ export default {
activeIndex(val, oldVal) { activeIndex(val, oldVal) {
this.resetItemPosition(); this.resetItemPosition();
this.$emit('change', val, oldVal); this.$emit('change', val, oldVal);
},
autoplay(val) {
val ? this.startTimer() : this.pauseTimer();
} }
}, },
......
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