сделал reviews для пк
This commit is contained in:
@@ -2,7 +2,6 @@
|
||||
|
||||
const gymSwiper = new Swiper('.gym-swiper', {
|
||||
direction: 'horizontal',
|
||||
slidesPerView: 1.20,
|
||||
breakpoints: {
|
||||
320:{
|
||||
slidesPerView: 1.20,
|
||||
@@ -14,4 +13,33 @@ const gymSwiper = new Swiper('.gym-swiper', {
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
|
||||
const reviewsSwiper = new Swiper('.reviews-swiper', {
|
||||
spaceBetween: 24,
|
||||
// If we need pagination
|
||||
pagination: {
|
||||
el: '.swiper-pagination',
|
||||
},
|
||||
|
||||
// Navigation arrows
|
||||
navigation: {
|
||||
nextEl: '.swiper-button-next',
|
||||
prevEl: '.swiper-button-prev',
|
||||
},
|
||||
|
||||
// And if we need scrollbar
|
||||
scrollbar: {
|
||||
el: '.swiper-scrollbar',
|
||||
},
|
||||
runCallbacksOnInit: true,
|
||||
// === new change
|
||||
on: {
|
||||
slideChange: function(){
|
||||
let offer = document.querySelector('#numberReviews');
|
||||
offer.innerHTML = (this.activeIndex + 1);
|
||||
}
|
||||
}
|
||||
})
|
||||
|
||||
// gymSwiper.destroy();
|
||||
|
||||
Reference in New Issue
Block a user