Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Autoplay just plays one time - v10.3.0 #7060

Closed
5 of 6 tasks
zzseba78 opened this issue Sep 22, 2023 · 4 comments
Closed
5 of 6 tasks

Autoplay just plays one time - v10.3.0 #7060

zzseba78 opened this issue Sep 22, 2023 · 4 comments

Comments

@zzseba78
Copy link

zzseba78 commented Sep 22, 2023

Check that this is really a bug

  • I confirm

Reproduction link

https://codepen.io/zzseba78-the-reactor/pen/BavYLpQ

Bug description

Autplay plays one time and then stops if disableOnInteraction: true ( or not set, defaults to true ) and no interaction on the slider at all. Works as expected if disableOnInteraction: false

Expected Behavior

Autoplay plays as always.

Actual Behavior

Play once and then stops. Seems that same case as this one: #7059

Swiper version

10.3.0

Platform/Target and Browser Versions

macOs, Chrome, Firefox, Safari ( all latest )

Validations

  • Follow our Code of Conduct
  • Read the docs.
  • Check that there isn't already an issue that request the same feature to avoid creating a duplicate.
  • Make sure this is a Swiper issue and not a framework-specific issue

Would you like to open a PR for this bug?

  • I'm willing to open a PR
@james0r
Copy link

james0r commented Sep 23, 2023

Just experienced the same. This also occurs with pauseMouseOnEnter for me.

https://codesandbox.io/s/swiper-autoplay-forked-phffl2?file=/index.html:2098-2132

Version 10.2 seems to work fine for me.

@kruboy14
Copy link

kruboy14 commented Sep 25, 2023

It happens due to the following changes in the core:

core: fix loopFix in loop and cssMode (8180a52), closes #6919

The previous implementation was:
return swiper.slideTo(swiper.activeIndex + increment, speed, runCallbacks, internal);

It has been modified to:
return swiper.slideTo(swiper.activeIndex + increment);

Consequently, the function no longer passes internal as true, causing it to stop autoplay at that point. here

Additionally, setting cssMode to true helped me to fix it

@349989153
Copy link

same problem with same 10.3.0

@Luckyfella73
Copy link

I can confirm the autoplay issue using swiper 10.3.0 (importing swiper as module). Slider swipes one time and then freezes. In my case it is not working even when setting disableOnInteraction: false

Until this is fixed in the package we can set cssMode: true like @kruboy14 suggested - thanks kruboy!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants