kenwheeler / slick

the last carousel you'll ever need
kenwheeler.github.io/slick
MIT License
28.54k stars 5.89k forks source link

Slider Syncing + slickFilter #3833

Open morinos opened 5 years ago

morinos commented 5 years ago

Description:

Synchronized sliders are getting desync when using the slickFilter method

https://jsfiddle.net/w0o4mr7k/8/

====================================================================

Steps to reproduce the problem

  1. Click on the "Filter green slides" button
  2. Navigate through the slides by clicking on the small thumbnails
  3. it should skip the slide number 5

====================================================================

What is the expected behaviour?

After filtering slides, you should be able to navigate smoothly using the thumbnail slider

====================================================================

What is observed behaviour?

Slides are not being re-indexed, I'm using a similar setup on a website and I only have this problem when the slidesToShow is higher or equal to the number of filtered slides.

====================================================================

More Details

Note: it's my first ever post on Github so I apologize if I did it wrong.

andrewcbi commented 5 years ago

yes have found this to happen also, my way around it was to make the swatches of the main slider directly call the other slider underneath when clicked on using the gotoslide function. It is a bit to keep track of but if not changing too often it works.

artemas commented 5 years ago

I've got a similar problem with 1.6.0, upgrade to 1.8.1 doesn't help.

jinch commented 4 years ago

Me too : / ~ has there been any resolution for this?

diff-michael-m commented 4 years ago

Me too : / ~ has there been any resolution for this?

Sadly not

jinch commented 4 years ago

Found a work around in this post if anyone else needs.

2836

You basically just need to apply ".slick('refresh');" after initializing the filter. Like So: $('.slick-slider').slick('slickFilter', selection).slick('refresh');