gs-shop / vue-slick-carousel

🚥Vue Slick Carousel with True SSR Written for ⚡Faster Luxstay
https://gs-shop.github.io/vue-slick-carousel/
Other
801 stars 186 forks source link

css grid with gap for spacing between slides #248

Open netzpixel opened 2 years ago

netzpixel commented 2 years ago

Please add the option to add a gap value for the spacing between the slides. If I add it myself the width calculation breaks... I need display grid to have all slides the same height - which works just fine - but adding a padding around each element is not a good solution since the slider is supposed to start at the parent element left/right border and not x px away from it.

jamik-dev commented 3 months ago

still it's not added, but here is the solution:

<VueSlickCarousel :slidesPerRow="4" :infinite="true" :arrows="true">
   <div v-for="item in 8" :key="item">
     <div class="padding-3">
       <customCartClientReview />
     </div>
   </div>
</VueSlickCarousel>

just wrap parent div and give some padding :)