mirror of https://github.com/ElemeFE/element
Carousel: fix interval and scale bug (#20931)
parent
0418a47148
commit
655d89fe0e
|
@ -98,6 +98,7 @@
|
|||
this.active = index === activeIndex;
|
||||
const isVertical = parentDirection === 'vertical';
|
||||
this.translate = this.calcTranslate(index, activeIndex, isVertical);
|
||||
this.scale = 1;
|
||||
}
|
||||
this.ready = true;
|
||||
},
|
||||
|
|
|
@ -159,6 +159,11 @@ export default {
|
|||
|
||||
loop() {
|
||||
this.setActiveItem(this.activeIndex);
|
||||
},
|
||||
|
||||
interval() {
|
||||
this.pauseTimer();
|
||||
this.startTimer();
|
||||
}
|
||||
},
|
||||
|
||||
|
|
Loading…
Reference in New Issue