import{j as t,aq as r,g as b,B as m,c as u,ar as h}from"./chunk-CPxJPrh0.js";import{s as v,g as x,a as g}from"./chunk-5FDXibT8.js";import{S as j,a as $}from"./chunk-Fb6tsTW_.js";const N=({className:e,productLinks:i,children:c})=>i.length===1?t.jsx("a",{href:i[0].link,className:e,children:c}):t.jsx("div",{className:e,children:c}),z="_cards_i3xgz_1",P="_card_i3xgz_1",O="_hover__shadow_i3xgz_22",k="_bonus_i3xgz_27",w="_img_i3xgz_40",R="_content_i3xgz_44",L="_name_i3xgz_48",T="_attributes_list_i3xgz_60",B="_attribute_i3xgz_60",C="_attribute_name_i3xgz_71",I="_attribute_value_i3xgz_77",A="_buy_buttons_i3xgz_84",W="_buy_btn_i3xgz_89",Y="_card__footer_i3xgz_109",D="_cart__button_i3xgz_115",M="_price_i3xgz_132",q="_cart__icon_i3xgz_139",s={cards:z,card:P,hover__shadow:O,bonus:k,img:w,content:R,name:L,attributes_list:T,attribute:B,attribute_name:C,attribute_value:I,buy_buttons:A,buy_btn:W,card__footer:Y,cart__button:D,price:M,cart__icon:q},F=({products:e,withShadowOnHover:i,userType:c,swiperLoop:_=!0,slidesPerView:o=4.79,width:l=1200})=>t.jsx(j,{loop:_,slidesPerView:o,spaceBetween:16,className:s.cards,width:l,children:e.map((n,S)=>{const d=v(n==null?void 0:n.attributes),y=x(n,c),p=g(n),f=`${r}/${n.transliterated_category_name}/${n.transliterated_name}---${n.id}`;return t.jsx($,{children:t.jsxs(N,{className:[s.card,i?s.hover__shadow:""].join(" "),productLinks:[{link:f,name:""}],children:[t.jsx("img",{src:p,alt:n.name,className:s.img,width:219,height:208,draggable:!1}),t.jsxs("div",{className:s.content,children:[t.jsx("div",{className:s.name,children:n.name}),t.jsxs("div",{className:s.attributes_list,children:[t.jsxs("div",{className:s.attribute,children:[t.jsx("div",{className:s.attribute_name,children:"Бренд:"}),t.jsx("div",{className:s.attribute_value,children:n.brand})]}),d&&t.jsxs("div",{className:s.attribute,children:[t.jsxs("div",{className:s.attribute_name,children:[d.name,":"]}),t.jsx("div",{className:s.attribute_value,children:d.value})]})]})]}),t.jsxs("div",{className:s.card__footer,children:[t.jsx("p",{className:s.price,children:y}),t.jsx("div",{className:s.cart__button,children:t.jsx(b,{icon:m,className:s.cart__icon})})]})]})},S)})}),J=e=>({userType:h(e)}),U=u(J),xt=U(F);var V=(e=>(e.OILS="OILS",e.WIPER_BLADES="WIPER_BLADES",e.OPTICS="OPTICS",e.TOOLS="TOOLS",e.BODY_PARTS="BODY_PARTS",e))(V||{});const gt={BODY_PARTS:[1e4,25e3,45e3],OILS:[1e4,2e4,5e4],WIPER_BLADES:[1e3,5e3],TOOLS:[500,2500,1e4],OPTICS:[3e3,6e3,2e4]},jt=[{title:"Кузовные запчасти",id:"25230d56-1841-49b3-8124-400b90bad41f",brands:["Jorden"],priceRange:[1e4,5e4],link:`${r}/kuzovnye-zapchasti`},{title:`Масла и 
 тех жидкости`,id:"440a4a28-108e-4ef1-ae5b-ca32a70074c0",brands:["Bardahl","Castrol","G-Energy","Kixx","Liqui","Moly","Mobil","Motul","Shell","Ravenol"],priceRange:[3e3,4e4],link:`${r}/masla-i-tekhnicheskie-zhidkosti`},{title:`Щетки 
 стеклоочистителя`,id:"60cbd4cd-185a-41dd-96e6-ac909cdcd742",brands:["Bosch","Denso","Valeo","Champion"],priceRange:[1e3,6e3],link:`${r}/shhetki-stekloochistitelja`},{title:"Автосвет",id:"9f0be18e-54ba-46a1-92a8-556b6efa7789",brands:["Philips","Osram","ClearLight"],priceRange:[500,5e3],link:`${r}/avtosvet`},{title:"Инструменты",id:"115a16c6-5612-4f7f-8853-01ba76ecd910",brands:["GROSS","JONNESWAY","OMBRA","SPARTA","STAYER","СИБРТЕХ"],priceRange:[300,25e3],link:`${r}/instrumenty`}],H="_card_1vhns_1",Q="_bonus_1vhns_12",Z="_img_1vhns_25",K="_content_1vhns_29",E="_name_1vhns_33",G="_attributes_list_1vhns_44",X="_attribute_1vhns_44",tt="_attribute_name_1vhns_55",et="_attribute_value_1vhns_61",st="_buy_buttons_1vhns_68",at="_buy_btn_1vhns_73",nt="_card__footer_1vhns_92",it="_cart__button_1vhns_98",ct="_price_1vhns_110",_t="_cart__icon_1vhns_117",a={card:H,bonus:Q,img:Z,content:K,name:E,attributes_list:G,attribute:X,attribute_name:tt,attribute_value:et,buy_buttons:st,buy_btn:at,card__footer:nt,cart__button:it,price:ct,cart__icon:_t},rt=({product:e,userType:i,withShadowOnHover:c})=>{const _=v(e==null?void 0:e.attributes),o=x(e,i),l=g(e),n=`${r}/${e.transliterated_category_name}/${e.transliterated_name}---${e.id}`;return t.jsxs(N,{className:[a.card,c?a.hover__shadow:""].join(" "),productLinks:[{link:n,name:""}],children:[t.jsx("img",{src:l,alt:e.name,className:a.img,width:148,height:129,draggable:!1}),t.jsxs("div",{className:a.content,children:[t.jsx("div",{className:a.name,children:e.name}),t.jsxs("div",{className:a.attributes_list,children:[t.jsxs("div",{className:a.attribute,children:[t.jsx("div",{className:a.attribute_name,children:"Бренд:"}),t.jsx("div",{className:a.attribute_value,children:e.brand})]}),_&&t.jsxs("div",{className:a.attribute,children:[t.jsxs("div",{className:a.attribute_name,children:[_.name,":"]}),t.jsx("div",{className:a.attribute_value,children:_.value})]})]})]}),t.jsxs("div",{className:a.card__footer,children:[t.jsx("p",{className:a.price,children:o}),t.jsx("div",{className:a.cart__button,children:t.jsx(b,{icon:m,className:a.cart__icon})})]})]})},ot=e=>({userType:h(e)}),lt=u(ot),dt=lt(rt),bt="_slider_1t6zn_1",mt={slider:bt},$t=({products:e,swiperLoop:i=!1,slidesPerView:c=2,spaceBetween:_=10})=>t.jsx(j,{loop:i,slidesPerView:c,spaceBetween:_,className:mt.slider,children:e.map((o,l)=>t.jsx($,{children:t.jsx(dt,{product:o})},l))});export{N as C,gt as I,$t as P,xt as a,V as b,jt as c,dt as d};
