import{_ as l,at as m,o as f}from"./index-bc1cd1f7.js";import{p as _,c as h,d as C}from"./Main-5e1e6212.js";import{P as S}from"./ProductCard-a724df0f.js";import{b5 as b,bm as i,e as n,bn as u,bf as r,g,bh as k,N as d,l as O}from"./vendor-d15da3cb.js";import"./tendor-09c4e69c.js";const P={components:{TCSlider:m,ProductCard:S},data(){return{loading:!0}},computed:{...f(_),sliderPerView(){const{xs:t,sm:e,md:o}=b();return t.value?2:e.value||o.value?6:8}},methods:{onReachEnd(t){let e={pageIndex:t,pageSize:20};this.getList(e)},getList(t){this.productsStore.basketOppurtunitiesNext&&(this.loading=!0,this.productsStore.actions.getBasketOppurtunities(t).finally(()=>this.loading=!1))}},mounted(){this.getList()},unmounted(){this.productsStore.basketOppurtunitiesNext=!0,this.productsStore.basketOppurtunityProducts=[]}},y={class:"section-title"};function v(t,e,o,w,N,a){const p=i("ProductCard"),c=i("TCSlider");return n(),u(C,{class:"mb-6"},{default:r(()=>[t.productsStore.basketOppurtunityProducts.length>0?(n(),u(h,{key:0,cols:"12"},{default:r(()=>[g("div",y,k(t.$t("CHECKOUT_COUNTER_OFFERS")),1),d(c,{"space-between":16,"per-view":a.sliderPerView,items:t.productsStore.basketOppurtunityProducts,onReachEnd:e[0]||(e[0]=s=>a.onReachEnd(s))},{default:r(({item:s})=>[d(p,{item:s},null,8,["item"])]),_:1},8,["per-view","items"])]),_:1})):O("",!0)]),_:1})}const T=l(P,[["render",v]]);export{T as default};