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

2 way control not working (swiper element) #7628

Closed
5 of 6 tasks
philippbuerger opened this issue Jul 22, 2024 · 4 comments · Fixed by rizwan-r-r/generative-ai-docs#55 · 4 remaining pull requests
Closed
5 of 6 tasks

2 way control not working (swiper element) #7628

philippbuerger opened this issue Jul 22, 2024 · 4 comments · Fixed by rizwan-r-r/generative-ai-docs#55 · 4 remaining pull requests

Comments

@philippbuerger
Copy link

philippbuerger commented Jul 22, 2024

Check that this is really a bug

  • I confirm

Reproduction link

https://codepen.io/philipp-buerger/pen/bGPeVpG

Bug description

I have 2 swiper elements on one page. I want to do a 2 way control. Only the controlling from the second to the first is working.

Expected Behavior

The sliders control each other

Actual Behavior

Only the second slider controls the first

Swiper version

11.1.5

Platform/Target and Browser Versions

macOS, Chrome / Safari / Firefox

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
@leegyusung
Copy link

In Our business, We're using two swipes, We're matching the two swipes through a function called thumbs.

However, At the version of 11.1.6
When I clicked swipe thumbnail that was matched through thumbs functions, then I clicked the swipe Slide of subordinate element. finally click event is not working how can i solve this problem?

@philippbuerger
Copy link
Author

Hi @nolimits4web its still not working as expected for me. The 2 way control does not working initially. Only if the second slider is moved minimum 1 slide the sync seems to work.

@philippbuerger
Copy link
Author

philippbuerger commented Jul 24, 2024

It seems that the cdn is not updated yet so the reproduction link has the old behavior. I tested it in my local env

@philippbuerger
Copy link
Author

Or does it have something todo with that my second slider is not visible initially? I have a product image slider and on a click an overlay opens to see the images in full size. What I found out, that when I first open the overlay that close it the 2 way binding works perfect. But when I first swipe in the visible slider and than open the overlay, the slide index is set to 0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment