Skip to content

Commit

Permalink
fix(autoplay): fix autoplay stop when disableOnInteraction is active
Browse files Browse the repository at this point in the history
fixes #7060
fixes #7059
  • Loading branch information
nolimits4web committed Sep 28, 2023
1 parent d8596ea commit ecfb3fb
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/core/slide/slideNext.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -16,13 +16,13 @@ export default function slideNext(speed = this.params.speed, runCallbacks = true
swiper._clientLeft = swiper.wrapperEl.clientLeft;
if (swiper.activeIndex === swiper.slides.length - 1 && params.cssMode) {
requestAnimationFrame(() => {
swiper.slideTo(swiper.activeIndex + increment);
swiper.slideTo(swiper.activeIndex + increment, speed, runCallbacks, internal);
});
return true;
}
}
if (params.rewind && swiper.isEnd) {
return swiper.slideTo(0, speed, runCallbacks, internal);
}
return swiper.slideTo(swiper.activeIndex + increment);
return swiper.slideTo(swiper.activeIndex + increment, speed, runCallbacks, internal);
}

0 comments on commit ecfb3fb

Please sign in to comment.