Answer the question
In order to leave comments, you need to log in
In popup(fancybox), there are slides made in slick slider. Slides stick together when calling popup, how to fix it?
Hello. I described the essence in the title, there is a popup, and there is a slider in it. When called, it sticks together, but when scrolling, it is restored. I attached the slider call, followed by the fancybox call.
$(".gooodPopup__slider").not('.slick-initialized').slick({
slidesToShow: 1,
slidesToScroll:1,
dots: false,
swipe:true,
infinite:true,
asNavFor: '.gooodPopup__dots',
});
$('.gooodPopup__dots').not('.slick-initialized').slick({
slidesToShow: 3,
arrows: false,
variableWidth: true,
asNavFor: '.gooodPopup__slider',
focusOnSelect: true
});
$('.fancybox__goods').fancybox({
beforeShow: function() {
$('.gooodPopup__slider').slick('setPosition');
$('.gooodPopup__dots').slick('setPosition');
},
});
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question