import{S as r,N as a,P as o}from"./swiper-C8ZQRgZ4-v4.7.2.js";import"./ProductCard-D7i7ejMC-v4.7.2.js";Alpine.data("LandscapeProducts",({url:i,watchState:s})=>({products:[],init(){this.fetchProducts(),s&&this.$watch(s,e=>{e&&(this.products=[],this.$refs.landscapeProductsWrap.remove())})},hideLandscapeProductsSkeleton(){document.querySelectorAll(".landscape-products .swiper-slide-skeleton").forEach(t=>t.remove())},async fetchProducts(){try{const e=await axios.get(i);this.products=e.data,this.$nextTick(()=>{new r(".landscape-products",{modules:[a,o],slidesPerView:2,navigation:{nextEl:".swiper-button-next",prevEl:".swiper-button-prev"},pagination:{el:".swiper-pagination",dynamicBullets:!0,clickable:!0},breakpoints:{576:{slidesPerView:3},830:{slidesPerView:4},991:{slidesPerView:5},1200:{slidesPerView:6},1400:{slidesPerView:7},1760:{slidesPerView:8}}})})}catch(e){notify(e.response.data.message)}finally{this.hideLandscapeProductsSkeleton()}}}));
