1"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[4082],{73677:function(e,t){t.Z={routes:{schema:{blog_carousel:{getFields:[],getBlob:["summary","body"]}}},setMenuCategoryName:"",scrollTopGenerateParamsChange:!0,getCategorySchema:"",getSettingSchema:!1,mainCatalog:"",pageLoader:{color:"rgb(25, 191, 211)",showSpinner:!1,speed:500},invoiceReminder:{autoHide:!1,duration:6e3,animationDuration:300}}},75292:function(e,t,n){n.r(t),n.d(t,{default:function(){return s}});var l=n(57437),a=n(2265),o=n(27648),r=n(34211),i=n(99376);function s(){let e=(0,i.usePathname)();return(0,a.useEffect)(()=>{(async()=>{await (0,r.qj)({url:e,status:"404"}),await (0,r.RZ)({request_methode:"POST",address:e})})()},[e]),(0,l.jsxs)("div",{className:"flex flex-col items-center justify-center gap-4 mb-20",children:[(0,l.jsx)("img",{src:"/assets/images/custom/404.svg",className:"max-w-full w-[700px] mx-auto"}),(0,l.jsx)(o.default,{href:"/",className:"py-2 px-8 bg-custom-bg-1 rounded-md text-custom-text-3",children:" بازگشت ب٠خاÙÙ "})]})}},87510:function(e,t,n){var l=n(57437),a=n(2265),o=n(24326),r=n(45926),i=n(23302),s=n(99376),c=n(33085),u=n(87798);let d=null;t.Z=function(e){let{catalog:t,className:n,resultData:m,stickyClass:p,settings:h,placeholder:v,showOption:f=!0,params:x={},searchUrl:g}=e,[y,b]=(0,a.useState)(""),[j,_]=(0,a.useState)([]),[w,N]=(0,a.useState)(!0),C=(0,s.useRouter)();return(0,l.jsx)("div",{className:"w-full ".concat(null!=p?p:""),children:(0,l.jsx)("div",{children:(0,l.jsx)(o.hQ,{value:"",onChange:e=>{if(null==e?void 0:e.searchItem){var n;(null==y?void 0:null===(n=y.trim())||void 0===n?void 0:n.length)>0&&(g?C.push("".concat(g,"?q=").concat(y)):C.push("/".concat(null!=t?t:"products","?q=").concat(y)))}else g?C.push(null==e?void 0:e.direct_url):C.push((0,c.C)({urlFormat:null==h?void 0:h.CATEGORY_URL_FORMAT,catalogName:"products",model:t,slug:null==e?void 0:e.slug,id:null==e?void 0:e.entity_id}))},children:(0,l.jsxs)("form",{className:"relative",onSubmit:e=>{var n;e.preventDefault(),(null==y?void 0:null===(n=y.trim())||void 0===n?void 0:n.length)>0&&C.push("/".concat(null!=t?t:"products","?q=").concat(y))},children:[(0,l.jsx)("span",{className:"text-custom-text-6 absolute left-2 top-2 cursor-text z-[2]",children:(0,l.jsx)(u.IconSearch,{size:21})}),(0,l.jsx)("label",{className:"relative",children:(0,l.jsx)(o.hQ.Input,{className:"appearance-none font-light focus:appearance-none ".concat(null!=n?n:"bg-custom-bg-4 w-72 max-md:w-56 h-10 block px-3 py-2 transition rounded-xl focus:border focus:border-custom-border-1 focus:bg-custom-bg-3 max-lg:mb-0"),placeholder:null!=v?v:"جستجÙ",autoComplete:"off",displayValue:e=>e.title,onChange:async e=>{N(!0);try{clearTimeout(d),d=setTimeout(async()=>{var n,l,a,o,r,s;if((null===(n=e.target.value)||void 0===n?void 0:n.length)>=2){let n=await (0,i.W)({catalogName:null!=t?t:"entity",params:{q:e.target.value,show_img:1,...x}});_(null!==(l=null==n?void 0:n.data)&&void 0!==l?l:[]),m&&m(null!==(a=null==n?void 0:n.data)&&void 0!==a?a:[]),N(!1)}else{if((null===(o=e.target.value)||void 0===o?void 0:o.length)<=2&&(null==y?void 0:y.length)>=2){let e=await (0,i.W)({catalogName:null!=t?t:"entity",params:{show_img:1,...x}});_(null!==(r=null==e?void 0:e.data)&&void 0!==r?r:[]),m&&m(null!==(s=null==e?void 0:e.data)&&void 0!==s?s:[])}N(!1)}},300)}catch(e){N(!1)}b(e.target.value)}})}),f&&(0,l.jsx)(r.u,{as:a.Fragment,leave:"transition ease-in duration-100",leaveFrom:"opacity-100",leaveTo:"opacity-0",afterLeave:()=>b(""),children:(0,l.jsxs)(o.hQ.Options,{className:"absolute mt-0 max-h-60 w-full z-10 overflow-auto rounded-md bg-custom-bg-3 py-1 text-base shadow-lg ring-1 ring-black ring-opacity-5 focus:outline-none sm:text-sm",children:[(0,l.jsx)(o.hQ.Option,{value:{searchItem:!0}}),w&&(null==y?void 0:y.length)>=2?(0,l.jsx)("div",{className:"flex justify-center py-3",children:(0,l.jsx)(u.IconLoading,{size:30})}):(0,l.jsx)(l.Fragment,{children:(null==j?void 0:j.length)===0&&""!==y?(0,l.jsx)("div",{className:"relative cursor-default select-none py-2 px-4 text-custom-text-2",children:"Ù
ÙØ±Ø¯Û ÛØ§Ùت ÙØ´Ø¯"}):(0,l.jsx)(l.Fragment,{children:null==j?void 0:j.map(e=>(0,l.jsx)(o.hQ.Option,{className:e=>{let{active:t}=e;return"relative select-none py-2 pl-10 pr-4 cursor-pointer ".concat(t?"bg-custom-bg-7 text-custom-text-3":"text-custom-text-1")},value:e,children:t=>{let{selected:n,active:a}=t;return(0,l.jsxs)(l.Fragment,{children:[(0,l.jsx)("span",{className:"block truncate ".concat(n?"font-medium":"font-normal"),children:null==e?void 0:e.title}),n?(0,l.jsx)("span",{className:"absolute inset-y-0 left-0 flex items-center pl-3 ".concat(a?"text-custom-text-3":"text-custom-text-4")}):null]})}},null==e?void 0:e.id))})})]})})]})})})})}},11212:function(e,t,n){n.r(t),n.d(t,{JsonLdArticle:function(){return o},JsonLdBreadcrumb:function(){return u},JsonLdContact:function(){return m},JsonLdFaq:function(){return p},JsonLdProduct:function(){return d},JsonLdSchema:function(){return h}});var l=n(57437),a=n(17719);function o(e){var t,n,o;let{data:r}=e,{title:i,summary:s,attach_index_image_md:c,canonical_url:u,entity_score_count:d,entity_score_avg:m,author_name:p,tree_nodes:h,register_date:v}=null==r?void 0:r.data,f={"@context":"https://schema.org","@type":"Article",name:i,mainEntityOfPage:{"@type":"WebPage","@id":"https://bookroom.ir"},headline:i,image:{"@type":"ImageObject",url:c?"https://api.bookroom.ir"+c:""},author:p,genre:null!==(o=null==h?void 0:h.node_title)&&void 0!==o?o:"NEWS",publisher:{"@type":"Organization",name:null==r?void 0:null===(t=r.setting)||void 0===t?void 0:t.Site_Title,logo:{"@type":"ImageObject",url:(0,a.Z)(null==r?void 0:null===(n=r.settings)||void 0===n?void 0:n.logo)}},url:"https://bookroom.ir"+u,datePublished:v,dateCreated:v,dateModified:v,description:s};return(0,l.jsx)(l.Fragment,{children:(0,l.jsx)("script",{type:"application/ld+json",dangerouslySetInnerHTML:{__html:JSON.stringify(f)}})})}var r=n(2265),i=n(96341),s=n(33085);let c=(0,n(42171).Z)("custom");function u(){var e;let{categoryParents:t,currentCategory:n,settings:a,catalogName:o,inRelationResult:u,tagResult:d,categories:m}=(0,r.useContext)(i.H),p=()=>{var e,l;let r=[];if(t&&(null===(e=Object.entries(t))||void 0===e?void 0:e.length)>0)null==t||null===(l=t.reverse())||void 0===l||l.forEach((e,t)=>{r.push({"@type":"ListItem",position:t+1,name:null==e?void 0:e.node_title,item:0==t?"https://bookroom.ir":"https://bookroom.ir"+(0,s.C)({urlFormat:null==a?void 0:a.CATEGORY_URL_FORMAT,catalogName:o,model:"category",slug:null==e?void 0:e.node_slug,id:null==e?void 0:e.node_id})})}),(null==n?void 0:n.title)&&r.push({"@type":"ListItem",position:(null==t?void 0:t.length)+1,name:null==n?void 0:n.title,item:"https://bookroom.ir"+(0,s.C)({urlFormat:null==a?void 0:a.CATEGORY_URL_FORMAT,catalogName:o,model:"category",slug:null==n?void 0:n.title.replaceAll(" ","-"),id:null==n?void 0:n.node_id})});else if(u||d){let e=(null==u?void 0:u.title)?null==u?void 0:u.title:null==d?void 0:d.tag_word,t=d?"tag":null==u?void 0:u.catalog_class,n="https://bookroom.ir"+(0,s.C)({urlFormat:null==a?void 0:a.CATEGORY_URL_FORMAT,catalogName:o,model:t,slug:e.replaceAll(" ","-"),id:u?null==u?void 0:u.entity_id:null==d?void 0:d.tag_id});r.push({"@type":"ListItem",position:1,name:c.home,item:"https://bookroom.ir"},{"@type":"ListItem",position:2,name:(null==m?void 0:m.node_title)||o,item:"".concat("https://bookroom.ir","/").concat(o)},{"@type":"ListItem",position:3,name:e,item:n})}return r},h={"@context":"http://schema.org","@type":"BreadcrumbList",itemListElement:p()};return(0,l.jsx)(l.Fragment,{children:(null===(e=p())||void 0===e?void 0:e.length)>0&&(0,l.jsx)("script",{type:"application/ld+json",dangerouslySetInnerHTML:{__html:JSON.stringify(h)}})})}function d(e){var t,n;let{data:o}=e,{id:r,title:i,meta_desc:s,price:c,attach_index_image_md:u,canonical_url:d,entity_score_count:m,entity_score_avg:p,fields:h}=null==o?void 0:o.data,v="";(null==h?void 0:null===(t=h.brand)||void 0===t?void 0:t.relations)&&Object.values(null==h?void 0:null===(n=h.brand)||void 0===n?void 0:n.relations).forEac
1h((e,t)=>{v+=(t>=1?" , ":"")+(null==e?void 0:e.entity_title)});let f=new Date;f.setDate(f.getDate()+30);let x=f.toISOString().split("T")[0],g={"@context":"https://schema.org","@type":"Product",name:i,image:(0,a.Z)(u),sku:r,mpn:r,offers:{"@type":"Offer",url:"https://bookroom.ir"+d,priceCurrency:"IRR",price:c,priceValidUntil:x,shippingDetails:{"@type":"OfferShippingDetails",shippingRate:{"@type":"MonetaryAmount",value:45e4,currency:"IRR"},shippingDestination:{"@type":"DefinedRegion",addressCountry:"IR"},deliveryTime:{"@type":"ShippingDeliveryTime",handlingTime:{"@type":"QuantitativeValue",minValue:0,maxValue:1,unitCode:"DAY"},transitTime:{"@type":"QuantitativeValue",minValue:1,maxValue:5,unitCode:"DAY"}}},hasMerchantReturnPolicy:{"@type":"MerchantReturnPolicy",applicableCountry:"IR",returnPolicyCategory:"https://schema.org/MerchantReturnFiniteReturnWindow",merchantReturnDays:1,returnMethod:"https://schema.org/ReturnByMail",returnFees:"https://schema.org/FreeReturn"},availability:"https://schema.org/InStock",itemCondition:"https://schema.org/NewCondition"}};return g.description=(null==s?void 0:s.length)>0?s:i,v&&(g.brand={"@type":"Brand",name:null!=v?v:""}),g.review={"@type":"Review",reviewRating:{"@type":"Rating",ratingValue:Number(p)?p:5,bestRating:"5",worstRating:"1"},reviewCount:Number(m)?m:1,author:{"@type":"Person",name:"Ù
خاطب"}},g.aggregateRating={"@type":"AggregateRating",ratingValue:Number(p)?p:5,reviewCount:Number(m)?m:1,bestRating:"5",worstRating:"1"},(0,l.jsx)(l.Fragment,{children:(0,l.jsx)("script",{type:"application/ld+json",dangerouslySetInnerHTML:{__html:JSON.stringify(g)}})})}function m(e){let{data:t}=e,{logo:n,Site_Title:o}=t,r={"@context":"https://schema.org","@type":"Organization",name:o,alternateName:"",url:"https://bookroom.ir/contact",logo:(0,a.Z)(n)};return(0,l.jsx)(l.Fragment,{children:(0,l.jsx)("script",{type:"application/ld+json",dangerouslySetInnerHTML:{__html:JSON.stringify(r)}})})}function p(e){var t;let{data:n}=e,a=()=>{var e,t;let l=[];return(null==n?void 0:n.data)&&(null==n?void 0:null===(e=n.data)||void 0===e?void 0:e.length)>0&&(null==n||null===(t=n.data)||void 0===t||t.forEach(e=>{l.push({"@type":"Question",name:null==e?void 0:e.title,acceptedAnswer:{"@type":"Answer",text:null==e?void 0:e.body}})})),l},o={"@context":"https://schema.org","@type":"FAQPage",mainEntity:a()};return(0,l.jsx)(l.Fragment,{children:(null===(t=a())||void 0===t?void 0:t.length)>0&&(0,l.jsx)("script",{type:"application/ld+json",dangerouslySetInnerHTML:{__html:JSON.stringify(o)}})})}function h(e){let{data:t,title:n,description:o}=e,{logo:r,Site_tel_1:i,Site_Address:s,ZIPCODE:c,SOCIAL_APARAT:u,SOCIAL_BALE:d,SOCIAL_EITAA:m,SOCIAL_GAP:p,SOCIAL_SOROUSH:h,SOCIAL_FACEBOOK:v,SOCIAL_INSTAGRAM:f,SOCIAL_LINKEDIN:x,SOCIAL_TELEGRAM:g,SOCIAL_TWITTER:y,SOCIAL_WHATSAPP:b,SOCIAL_YOUTUBE:j}=t||{},_=[];u&&_.push(u),d&&_.push(d),m&&_.push(m),p&&_.push(p),h&&_.push(h),v&&_.push(v),f&&_.push(f),x&&_.push(x),g&&_.push(g),y&&_.push(y),b&&_.push(b),j&&_.push(j);let w={"@context":"https://schema.org","@type":"WebPage",name:n,url:"https://bookroom.ir",description:o,publisher:{"@type":"Organization",name:(null==t?void 0:t.Site_Title)||"",logo:{"@type":"ImageObject",url:(0,a.Z)(r)},sameAs:_},mainEntityOfPage:{"@type":"WebPage","@id":"https://bookroom.ir"},mainEntity:{"@type":"Organization",name:n,url:"https://bookroom.ir",logo:(0,a.Z)(r),contactPoint:{"@type":"ContactPoint",telephone:i,contactType:"Customer Service",areaServed:"IR",availableLanguage:["Persian"]},sameAs:_},potentialAction:{"@type":"SearchAction",target:"".concat("https://bookroom.ir","/products?q={search_term_string}"),"query-input":"required name=search_term_string"},author:{"@type":"Person",name:"Almaatech Co."}};return s&&(w.address={"@type":"PostalAddress",streetAddress:s,addressLocality:"",addressRegion:"",postalCode:c||"",addressCountry:"IR"}),(0,l.jsx)(l.Fragment,{children:(0,l.jsx)("script",{type:"application/ld+json",dangerouslySetInnerHTML:{__html:JSON.stringify(w)}})})}},7139:function(e,t,n){var l=n(57437),a=n(2265),o=n(96341),r=n(11212),i=n(33085),s=n(42171);t.Z=e=>{var t,n,c,u,d;let{classNameUl:m,classNameLl:p,classNameA:h,homeIcon:v,splitterIcon:f}=e,{categoryParents:x,currentCategory:g,categories:y,inRelationResult:b,tagResult:j,catalogName:_,settings:w}=(0,a.useContext)(o.H),N=Array.isArray(y)?y[0]:y,C=(0,s.Z)("custom"),R=(null==g?void 0:g.title)||"",k=R.match(/\([^)]*\d[^)]*\)/g);k&&(R=R.replace(k.pop(),""));let T=R.replace(/[(),Ø]/g,"").trim().replace(/\s+/g,"-");return(0,l.jsxs)(l.Fragment,{children:[(0,l.jsx)(r.JsonLdBreadcrumb,{}),(0,l.jsx)("ul",{className:null!=m?m:"flex items-center justify-start mb-3 max-w-max flex-row-reverse overflow-auto",children:x?(0,l.jsxs)(a.Fragment,{children:[(null==g?void 0:g.title)&&(0,l.jsx)(l.Fragment,{children:N?(0,l.jsxs)("li",{className:"whitespace-nowrap ".concat(null!=p?p:"[&:not(:last-child)]:pr-3 [&:not(:last-child)]:mr-3 cursor-default"," ").concat(f?"":"relative [&:not(:last-child)]:after:content-['/'] after:absolute after:inset-0 after:left-auto"," ").concat(f?"flex items-center gap-3 !pr-0":""),children:[f&&f,null==g?void 0:null===(n=g.t
1itle)||void 0===n?void 0:null===(t=n.replace(/ *\([^)]*\)*/g,""))||void 0===t?void 0:t.replace(/-+/g,"-")]}):(0,l.jsxs)("a",{href:(0,i.C)({urlFormat:null==w?void 0:w.CATEGORY_URL_FORMAT,model:"category",slug:null==T?void 0:T.replace(/-+/g,"-"),id:null==g?void 0:g.node_id}),className:"whitespace-nowrap ".concat(null!=p?p:"[&:not(:last-child)]:pr-3 [&:not(:last-child)]:mr-3"," ").concat(f?"":"relative [&:not(:last-child)]:after:content-['/'] after:absolute after:inset-0 after:left-auto"," ").concat(f?"flex items-center gap-3 !pr-0":""),children:[f&&f,null==g?void 0:null===(u=g.title)||void 0===u?void 0:null===(c=u.replace(/ *\([^)]*\)*/g,""))||void 0===c?void 0:c.replace(/-+/g,"-")]})}),(0,l.jsx)(o.H.Consumer,{children:e=>{var t;return Array.isArray(null==e?void 0:e.categoryParents)&&(null==e?void 0:null===(t=e.categoryParents)||void 0===t?void 0:t.map(t=>{var n,a,o,r;return 1===Number(t.node_id)?(0,l.jsx)("li",{className:"".concat(null!=p?p:""),children:v?(0,l.jsx)("a",{className:null!=h?h:"",href:"/",children:v}):(0,l.jsx)("a",{className:null!=h?h:"",href:"/",children:t.node_title})},t.node_id):(0,l.jsxs)("li",{className:"".concat(null!=p?p:"[&:not(:last-child)]:pr-3 [&:not(:last-child)]:mr-3"," ").concat(f?"":"relative [&:not(:last-child)]:after:content-['/'] after:absolute after:inset-0 after:left-auto"," ").concat(f?"flex items-center gap-3 !pr-0":""," "),children:[f&&f,(0,l.jsx)("a",{className:null!=h?h:"whitespace-nowrap",href:(0,i.C)({urlFormat:null===(n=e.settings)||void 0===n?void 0:n.CATEGORY_URL_FORMAT,catalogName:null==e?void 0:e.catalogName,model:"category",slug:null==t?void 0:null===(a=t.node_slug)||void 0===a?void 0:a.replace(/-+/g,"-"),id:null==t?void 0:t.node_id}),children:null==t?void 0:null===(r=t.node_title)||void 0===r?void 0:null===(o=r.replace(/ *\([^)]*\)*/g,""))||void 0===o?void 0:o.replace(/-+/g,"-")})]},t.node_id)}))}}),!!((null==b?void 0:b.title)||(null==j?void 0:j.tag_word))&&(0,l.jsxs)(l.Fragment,{children:[!!(null==b?void 0:b.title)&&(0,l.jsx)("li",{className:"".concat(null!=p?p:"[&:not(:last-child)]:pr-3 [&:not(:last-child)]:mr-3 cursor-default"," ").concat(f?"":"relative [&:not(:last-child)]:after:content-['/'] after:absolute after:inset-0 after:left-auto"," ").concat(f?"flex items-center gap-3 !pr-0":""," whitespace-nowrap"),children:null==b?void 0:b.title}),!!(null==j?void 0:j.tag_word)&&(0,l.jsx)("li",{className:"".concat(null!=p?p:"[&:not(:last-child)]:pr-3 [&:not(:last-child)]:mr-3 cursor-default"," ").concat(f?"":"relative [&:not(:last-child)]:after:content-['/'] after:absolute after:inset-0 after:left-auto"," ").concat(f?"flex items-center gap-3 !pr-0":""," whitespace-nowrap"),children:null==j?void 0:j.tag_word}),(0,l.jsx)("li",{className:"".concat(null!=p?p:"[&:not(:last-child)]:pr-3 [&:not(:last-child)]:mr-3 cursor-default"," ").concat(f?"":"relative [&:not(:last-child)]:after:content-['/'] after:absolute after:inset-0 after:left-auto"," ").concat(f?"flex items-center gap-3 !pr-0":""," whitespace-nowrap"),children:(0,l.jsx)("a",{className:null!=h?h:"",href:1===Number(null==w?void 0:w.CATEGORY_URL_FORMAT)?"/products":(0,i.C)({urlFormat:null==w?void 0:w.CATEGORY_URL_FORMAT,catalogName:_,model:"category",slug:null===(d=N.node_slug)||void 0===d?void 0:d.replace(/-+/g,"-"),id:N.node_id}),children:1===Number(null==w?void 0:w.CATEGORY_URL_FORMAT)?null==C?void 0:C.product:N.node_title})}),(0,l.jsxs)("li",{className:"".concat(null!=p?p:"[&:not(:last-child)]:pr-3 [&:not(:last-child)]:mr-3 cursor-default"," ").concat(f?"":"relative [&:not(:last-child)]:after:content-['/'] after:absolute after:inset-0 after:left-auto"," ").concat(f?"flex items-center gap-3 !pr-0":""," whitespace-nowrap"),children:[f&&f,(0,l.jsx)("a",{className:null!=h?h:"",href:"/",children:null!=v?v:null==C?void 0:C.home})]})]})]}):(0,l.jsxs)(l.Fragment,{children:[(0,l.jsx)("li",{className:"".concat(null!=p?p:"[&:not(:last-child)]:pr-3 [&:not(:last-child)]:mr-3 cursor-default"," ").concat(f?"":"relative [&:not(:last-child)]:after:content-['/'] after:absolute after:inset-0 after:left-auto"," ").concat(f?"flex items-center gap-3 !pr-0":""," whitespace-nowrap"),children:null==N?void 0:N.node_title}),(0,l.jsxs)("li",{className:"".concat(null!=p?p:"[&:not(:last-child)]:pr-3 [&:not(:last-child)]:mr-3 cursor-default"," ").concat(f?"":"relative [&:not(:last-child)]:after:content-['/'] after:absolute after:inset-0 after:left-auto"," ").concat(f?"flex items-center gap-3 !pr-0":""," whitespace-nowrap"),children:[f&&f,(0,l.jsx)("a",{className:null!=h?h:"",href:"/",children:null!=v?v:""})]})]})})]})}},95638:function(e,t,n){let l;n.d(t,{Z:function(){return p}});var a=n(57437),o=n(14232),r=n(45484),i=n(24039),s=n(2265),c=n(42171),u=n(87798),d=n(96341);let m=(0,c.Z)("custom");function p(e){var t;
1let n,{title:c=m.add_to_basket,eventTarget:p,controllerWidth:h,entity_id:v,product_id:f,array_key:x,btnClass:g,hasCountTextColor:y,hasProductBtnClass:b,notProductBtnClass:j,textColor:_,textColorActive:w,showAlways:N=!1,deleteIcon:C}=e,R=(0,o.T)(),{products:k}=(0,o.C)(e=>{let{basket:t}=e;return t})||{},{isMobile:T}=(0,s.useContext)(d.H),[O,S]=(0,s.useState)(!1),[F,P]=(0,s.useState)(!1),[A,L]=(0,s.useState)(!1);(null==k?void 0:k.length)>0&&(n=x?null==k?void 0:k.find(e=>{let{array_key:t}=e;return t===x}):null==k?void 0:k.find(e=>{let{product_id:t}=e;return t===f}));let Z=async()=>{if(!O&&!F)try{S(!0);try{let e=await (0,r.Cb)({entity_id:v,product_id:f,inc:1,_method:"POST"});R((0,i.a3)(e)),S(!1)}catch(e){S(!1)}}catch(t){var e;(null==t?void 0:null===(e=t.messages)||void 0===e?void 0:e.messageId)===13&&P(!0),S(!1)}},I=async()=>{if(!O){S(!0);try{let e=await (0,r.Cb)({entity_id:v,product_id:f,inc:0,_method:"POST"});R((0,i.a3)(e))}catch(e){}F&&P(!1),S(!1)}},E=()=>{clearTimeout(l),l=setTimeout(()=>{L(!1)},2e3)};return(0,a.jsx)(a.Fragment,{children:!(null==n?void 0:n.disabled)&&(0,a.jsx)("div",{className:"relative flex items-center rounded-md w-full h-10 cursor-pointer\n ".concat(null!=g?g:"text-custom-text-5"," ").concat(n&&(null==n?void 0:n.count)?null!=b?b:"":"".concat(null!=j?j:"bg-custom-bg-12 border")),onMouseLeave:()=>{!T&&(N||E())},onMouseEnter:()=>{T||L(!0)},children:(0,a.jsx)("div",{className:"flex items-center justify-center grow",children:(0,a.jsx)("div",{className:"flex w-full",onClick:()=>{p&&p()},children:(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("span",{className:"".concat(null!=_?_:"text-custom-text-3"," text-sm text-center px-3 py-2 w-11 ").concat((null==n?void 0:n.count)&&y?y:""),onClick:()=>{(null==n?void 0:n.count)?(L(!0),N||E()):(Z(),L(!0),T&&(N||E()))},children:O?(0,a.jsx)(u.IconLoading,{size:20}):null!==(t=null==n?void 0:n.product_unit_lable_simple)&&void 0!==t?t:c}),(N||A)&&n&&!!(null==n?void 0:n.count)&&(0,a.jsxs)("div",{className:"flex justify-between items-center left-0 absolute ".concat(null!=h?h:"w-[80px]"," shadow-shadow-1 rounded-md bg-custom-bg-3 h-12 top-0"),children:[(0,a.jsx)("span",{className:"".concat(null!=w?w:"text-custom-text-9"," text-sm px-1 py-2"),children:(0,a.jsx)("span",{onClick:()=>{Z(),T&&(N||E())},children:(0,a.jsx)(u.IconPlus,{size:20})})}),O?(0,a.jsx)("span",{className:"".concat(null!=w?w:"text-custom-text-9"," text-sm px-1 py-2"),children:(0,a.jsx)(u.IconMoreHorizontal,{size:20})}):(0,a.jsxs)("span",{className:"".concat(null!=w?w:"text-custom-text-9"," text-base px-1 py-2 text-center flex flex-col items-center justify-center"),children:[(0,a.jsx)("span",{className:"flex items-center",children:(0,a.jsx)("span",{className:"text-md",children:null==n?void 0:n.product_unit_lable_simple})}),(0,a.jsx)("span",{className:"text-xs",children:F&&m.maximum})]}),(null==n?void 0:n.count)>1?(0,a.jsx)("span",{className:"".concat(null!=w?w:"text-custom-text-9"," text-sm px-1 py-2"),onClick:()=>{I(),T&&(N||E())},children:(0,a.jsx)(u.IconMinus,{size:20})}):(0,a.jsx)("span",{className:"".concat(null!=w?w:"text-custom-text-9"," text-sm px-1 py-2"),onClick:()=>I(),children:null!=C?C:(0,a.jsx)(u.IconTrash2,{size:20})})]})]})})})})})}},37907:function(e,t,n){var l=n(57437),a=n(25103),o=n.n(a);t.Z=e=>{let{nextLabel:t,pageRangeDisplayed:n,handlePage:a,previousLabel:r,currentPage:i,className:s,breakClassName:c,nextClassName:u,previousClassName:d,activeClassName:m,pageClassName:p,pageLinkClassName:h,mainClassName:v,pageCount:f,disabledClassName:x,scrollToTop:g=!1,scrollTargetRef:y,scrollBehavior:b="smooth",scrollOffset:j=0}=e;return(0,l.jsx)(l.Fragment,{children:f>1&&(0,l.jsx)("div",{className:"flex w-full paginationBox py-2 justify-center ".concat(null!=v?v:""),children:(0,l.jsx)(o(),{breakLabel:"...",nextLabel:null!=t?t:"",onPageChange:e=>{a(parseInt(e.selected)+1),g&&requestAnimationFrame(()=>{if(null==y?void 0:y.current){let e=y.current.getBoundingClientRect().top+window.scrollY-j;window.scrollTo({top:e,behavior:b})}else window.scrollTo({top:0,behavior:b})})},forcePage:Number(i)-1,pageRangeDisplayed:null!=n?n:3,pageCount:f,previousLabel:null!=r?r:"",renderOnZeroPageCount:null,className:"flex justify-center items-center ".concat(null!=s?s:""),breakClassName:null!=c?c:"",nextClassName:null!=u?u:"",activeClassName:"z-2 bg-custom-bg-7 text-custom-text-3 relative inline-flex items-center w-9 h-9 text-sm ".concat(null!=m?m:""),pageClassName:"flex w-9 h-9 justify-center rounded-full m-1 items-center ".concat(null!=p?p:""),pageLinkClassName:"flex w-9 h-9 justify-center rounded-full m-1 items-center ".concat(null!=h?h:""),previousClassName:null!=d?d:"",disabledClassName:null!=x?x:""})})})}},12115:function(e,t,n){var l=n(57437),a=n(97539),o=n(45432),r=n(27648),i=n(2265),s=n(42171),c=n(95638),u=n(87798);let d=(0,s.Z)("custom"),m={0:{key:d.unavailable,value:d.unavailable_message},1:{key:d.unavailable,value:d.unavailable_message},2:{key:d.unavailable,value:d.unavailable_message},3:{key:d.unorderable,value:d.unorderable_message},4:{key:d.soon,value:d.soon_message}};t.Z=e=>{var t;let{attach_index_image_xs:n,title:s,original_price:d,price:p,entity_id:h,product_id:v,array_key:f,direct_url:x,inventory_status:g,inventory_available:y,discount_percent:b}=e;return(0,l.jsx)("div",{className:"bg-custom-bg-3 rounded-3xl relative before:content-[''] before:absolute before:w-[70%] before:h-[70%] before:z-[0] before:rounded-3xl before:top-0 before:right-0 before:shadow-[2.5px_-2.5px_15px_#edf1f5] after:content-[''] after:absolute after:w-[70%] after:h-[70%] after:z-[0] after:rounded-3xl after:bottom-0 after:left-0 after:shadow-[2.5px_-2.5px_15px_#edf1f5] ",children:(0,l.jsxs)("div",{className:"bg-custom-bg-3 rounded-3xl p-4 flex flex-col justify-center items-center space-y-2 relative z-[1]",children:[(0,l.jsxs)(r.default,{href:x,children:[(0,l.jsx)(a.default,{src:n||"/assets/images/custom/default.png",imgClassName:"object-contain rounded-2xl max-w-[172px] mx-auto border border-custom-border-2 mb-3 h-[250px]",alt:s,width:180,height:250,loading:"eager"}),(0,l.jsx)("h3",{className:"line-clamp-2 h-10 text-sm w-full",children:s})]}),Number(y)?(0,l.jsxs)("div",{className:"flex justify-between w-full gap-4 items-end",children:[(0,l.jsx)(c.Z,{entity_id:h,product_id:v,array_key:f,title:(0,l.jsx)(u.IconCartPlusSolid,{size:22}),notProductBtnClass:"bg-custom-bg-1 !w-10 !h-10 flex justify-center",hasProductBtnClass:"bg-custom-bg-1 !w-10 !h-10 flex justify-center",textColor:"text-custom-text-3 !px-0 !py-0 !w-auto !blok !mx-auto",controllerWi
1dth:"!right-0 !left-auto border border-custom-border-3 !h-10",textColorActive:"!text-custom-text-7"}),(0,l.jsxs)("div",{className:"flex flex-col justify-end items-end w-[calc(100%-30px)] min-h-[45px]",children:[!!b&&Number(b)>0&&(0,l.jsxs)("div",{className:"flex items-center gap-1",children:[(0,l.jsxs)("div",{className:"flex items-center gap-1",children:[(0,l.jsx)("div",{className:"text-custom-text-2 font-light line-through max-lg:text-sm",children:(0,o.Y)({number:d,isRial:!0})}),(0,l.jsx)("div",{className:"text-xs text-custom-text-2 font-light",children:" تÙÙ
اÙ"})]}),(0,l.jsxs)("div",{className:"text-custom-text-3 whitespace-nowrap bg-custom-bg-5 px-1 inline-block text-xs rounded-3xl",children:[b," Ùª"]})]}),(0,l.jsxs)("div",{className:"flex items-center gap-1",children:[(0,l.jsx)("div",{className:"text-base",children:(0,o.Y)({number:p,isRial:!0})}),(0,l.jsx)("div",{className:"text-xs text-custom-text-5",children:" تÙÙ
اÙ"})]})]})]}):(0,l.jsx)(l.Fragment,{children:"object"==typeof m&&(null===(t=Object.entries(m))||void 0===t?void 0:t.map((e,t)=>{let[n,a]=e;return(0,l.jsx)(i.Fragment,{children:g==n&&(0,l.jsx)("div",{className:"text-custom-text-9 text-center flex gap-1.5 items-center justify-center w-full !mt-5 h-9",children:(0,l.jsxs)("span",{children:[" ",null==a?void 0:a.key," "]})})},t)}))})]})})}},69459:function(e,t,n){n.d(t,{Z:function(){return o}});var l=n(57437),a=n(96341);function o(e){let t=t=>(0,l.jsx)(a.H.Provider,{value:t,children:(0,l.jsx)(e,{...t})});return t.displayName="context_props",t}},2573:function(e,t,n){n.d(t,{Z:function(){return l}});function l(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1e3,n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];if((null==e?void 0:e.length)>t){let l=e.slice(0,t);if(n){let n=l.lastIndexOf(".");e=-1!==n&&n<t?l.slice(0,n+1):l}else e=l}return e}},33085:function(e,t,n){n.d(t,{C:function(){return l}});function l(e){let{urlFormat:t,catalogName:n="",model:l,slug:a,id:o,params:r="",productType:i,basePath:s}=e,c=!n;switch(t){case 1:return"".concat(null!=s?s:"","/").concat(1===i||c?"products":n,"/").concat(l,"-").concat(a).concat(r);case 2:return"/".concat(n,"/").concat(l,"/").concat(a).concat(r);case 3:return"/".concat(n,"/").concat(l,"=").concat(o,"/").concat(a).concat(r);default:return""}}},37778:function(e,t,n){n.d(t,{Z:function(){return r}});var l=n(57437),a=n(99376),o=n(73677);function r(e){return t=>{let n=(0,a.useRouter)(),r=(0,a.usePathname)(),i=(0,a.useSearchParams)(),s=new URLSearchParams(i);function c(){s.delete("page")}let u=()=>{let e="".concat(r,"?"),t=[];s.forEach((e,n)=>{t.push("".concat(n,"=").concat(e))}),e+=t=t.join("&"),n.push(e,{scroll:null===o.Z||void 0===o.Z?void 0:o.Z.scrollTopGenerateParamsChange})};return(0,l.jsx)(e,{...t,createParams:function(e){if("object"==typeof e){var t;c(),null===(t=Object.entries(e))||void 0===t||t.forEach(e=>{let[t,n]=e;i.get(t)!==n&&s.set(t,n)}),u()}},removeParams:function(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];(null==t?void 0:t.length)>0&&(c(),null==t||t.forEach(e=>{s.delete(e)}),u())},removeParamsRelation:function(e){if("object"==typeof e){var t;c();let n="";null===(t=Object.entries(e))||void 0===t||t.forEach(e=>{let[t,l]=e;n=t;let a=s.getAll(t);s.delete(t);let o=null==a?void 0:a.findIndex(e=>e===l);Number(o)>=0&&(a.splice(o,1),null==a||a.forEach(e=>{s.append(n,e)}))}),u()}},createParamsRelation:function(e){if("object"==typeof e){var t;c();let n=[],l="";null===(t=Object.entries(e))||void 0===t||t.forEach(e=>{let[t,a]=e;l=t,n=Array.from(new Set(n=[...s.getAll(t),a]))}),s.delete(l),n.forEach(e=>s.append(l,e)),u()}},getParamsRelation:function(e){return s.getAll(e)}})}}},41835:function(e,t){t.Z=e=>{let{currentCategory:t,catalogResult:n,inRelationResult:l,tagResult:a,searchParams:o}=e,r={},i=null==t?void 0:t.node_id,s=null==l?void 0:l.entity_id;if(o.forEach((e,t)=>{r[t]=r[t]?"".concat(r[t],",").concat(e):e}),i&&(r.category=i.toString()),s&&(r["in_relation[]"]=s.toString()),(null==a?void 0:a.tag_id)&&(r.tag_ids=a.tag_id.toString()),Number(r.limit)>100&&(r.limit="100"),null==n?void 0:n.default_order_by){var c;r.order_by=null!==(c=r.order_by)&&void 0!==c?c:n.default_order_by}return Number(r.min_price)>0&&(r.min_price=(10*Number(r.min_price)).toString()),Number(r.max_price)>0&&(r.max_price=(10*Number(r.max_price)).toString()),r}},23302:function(e,t,n){n.d(t,{W:function(){return o}});var l=n(26070),a=n(64358);async function o(e){let{catalogName:t,params:n,token:o,sellerId:r,clientHostDockerImage:i,hostDockerImage:s}=e;try{let e=!!Number(null==n?void 0:n.revalidate);n._method="GET";let l=await (0,a.Z)({ignoreToken:!((null==n?void 0:n.id)||(null==n?void 0:n.slug)||(null==n?void 0:n.like)||(null==n?void 0:n.bookmark)||(null==n?void 0:n.mine)||(null==n?void 0:n.notify)),serverSideToken:o,sellerId:r,clientHost:e,clientHostDockerImage:i,hostDockerImage:s}).post(e?"/revalidate?route=".concat(t):"/".concat(t),n,{headers:{"content-type":"multipart/form-data"}});if(l.success&&l.result)return l.result;throw Error(l.message||"Failed to fetch catalog")}catch(e){return e instanceof l.Z&&console.error("Validation error:",e.messages),Promise.reject(e)}}},34211:function(e,t,n){n.d(t,{JX:function(){return m},RR:function(){return d},RZ:function(){return h},TZ:function(){return c},YT:function(){return i},eQ:function(){return u},qj:function(){return p},ug:function(){return s},y4:function(){return v}});var l=n(26070),a=n(64358),o=n(27030);function r(){return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,function(e){var t=16*Math.random()|0;return("x"==e?t:3&t|8).toString(16)})}async function i(e,t){try{let n=(0,o.$1)("x-api-key"),l=(0,o.$1)("user-agent"),i=(0,o.$1)("android_app_version","",!1);if((0,o.$1)("android_firebase_token","",!1),(n||t)&&!e)return;let s=new FormData;s.append("app_version",i?i.toString():1),s.append("http_user_agent",null==l?void 0:l.ua),s.append("imei",""),s.append("model",""),s.append("brand",""),s.append("platform",i?"2":"6"),s.append("os",""),s.append("android_id",""),s.append("guid",r()),s.append("_method","POST");let c=await (0,a.Z)().post("/get_token",s);if((0,o.lE)("x-api-key",null==c?void 0:c.token),e)try{window.location.reload()}catch(e){}}catch(e){l.Z}}async function s(e){try{var t;let{revalidate:n}=e||{revalidate:3600},l={},o=!!Number(n);o&&(l.revalidate=n);let r=await (0,a.Z)({ignoreToken:!0,clientHost:o}).post(o?"/revalidate?route=province_city":"/province_city",l,{headers:{"content-type":"multipart/form-data"}});return null==r?void 0:null===(t=r.result)||void 0===t?void 0:t.province}catch(e){l.Z}}async function c(e){let{updateUser:t,params:n}=e;try{var i,s,c;let e=(0,o.$1)("user");if(((0,o.$1)("hello")||e)&&!t)return;let l=await (0,a.Z)().post("/hello",{_method:"GET",...n});return(null==l?void 0:null===(i=l.result)||void 0===i?void 0:i.member_info)&&(0,o.lE)("user",null==l?void 0:null===(c=l.result)||void 0===c?void 0:c.member_info),(0,o.lE)("hello",r()),null==l?void 0:null===(s=l.result)||void 0===s?void 0:s.member_info}catch(e){l.Z}}async function u(e){let{params:t,token:n,hostDockerImage:l}=e;try{let e=await (0,a.Z)({serverSideToken:n,hostDockerImage:l}).post("/invoice",t);return null==e?void 0:e.result}catch(e){return Promise.reject(e)}}async function d(e){try{let t=new FormData;
1"object"==typeof e&&Object.entries(e).forEach(e=>{let[n,l]=e;t.append(n,l)});let n=await (0,a.Z)().post("/utm_add",e);return null==n?void 0:n.result}catch(e){}}async function m(e){let{params:t}=e,n=new FormData;try{"object"==typeof t&&Object.entries(t).forEach(e=>{let[t,l]=e;n.append(t,l)});let e=await (0,a.Z)().post("/fast_buy",n);if((null==e?void 0:e.success)&&(null==e?void 0:e.result))return null==e?void 0:e.result}catch(e){return l.Z,Promise.reject(e)}}async function p(e){let{url:t}=e}async function h(e){let{request_method:t,address:n}=e;try{let e=new FormData;e.append("request_method",t),e.append("address",n);let l=await (0,a.Z)().post("/not_found_page_hit",e);return null==l?void 0:l.result}catch(e){return Promise.reject(e)}}async function v(e){try{let t=new FormData;return"object"==typeof e&&Object.entries(e).forEach(e=>{let[n,l]=e;l&&t.append(n,l)}),await (0,a.Z)({ignoreToken:!0,clientHost:!0}).post("/related",t)}catch(e){return Promise.reject(e)}}}}]);
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.