Magnific-Popup icon indicating copy to clipboard operation
Magnific-Popup copied to clipboard

tCounter not displaying the correct number of images

Open Madeirense opened this issue 9 years ago • 6 comments

Hi there, thank you for the amazing script.

I am running into an issue I can't seem to find a solution for though..

At the moment, I have 4 images in a slick slider. By clicking on the images on the slick slider I have them displaying in a bigger size with magnificPopup. All works as expected apart from the tCounter values which for some reason shows a count of 10 images instead of 4, starts the count at 3 instead of 1 and sometimes the slides don't show in the correct order. it starts at 3, shows a total of ten and sometimes it randomly messes up the order.

So the counter should show a count of 4 images as I only have 4 images, start at 1 finish at 4 and the slides should always show in the correct order..

Any help on this would be much appreciated.

Madeirense avatar Jan 20 '16 12:01 Madeirense

Mine starts at 3 and shows a count of 10 images for 4 images .

Anyone willing to help us?

Meanwhile going to keep searching for a solution. If I find one I'll post it here.

Madeirense avatar Jan 21 '16 10:01 Madeirense

Found a solution.

My issue was caused by the slick slider cloned slides.

Solution was to add this bit of code when initializing magnificPopup:

delegate: '.slides:not(.slick-cloned) a',

For flexslider the solution shouldn't be far from this.

Madeirense avatar Jan 21 '16 12:01 Madeirense

Thanks for help

delegate: '.slides:not(.slick-cloned) a',

Kokocuk avatar Sep 27 '16 14:09 Kokocuk

@Madeirense: if you change the delete to ignore the slick-cloned elements, those are no longer clickable, correct?

Running into this issue myself...

AdamWills avatar Oct 26 '16 18:10 AdamWills

@Madeirense

That won't work, as @AdamWills said. It will disable clicking the cloned items. It may look like it works because you're probably clicking on the non-cloned ones.

One "solution" is to just set infinite: false on the slick slider, but that kinda sucks...

srt4rulez avatar Aug 31 '17 16:08 srt4rulez

Facing the same issue.

sushmak02 avatar Mar 08 '24 08:03 sushmak02