Your IP : 216.73.217.77


Current Path : /home/users/unlimited/www/ondemand.codeskitter.site/build/static/js/
Upload File :
Current File : /home/users/unlimited/www/ondemand.codeskitter.site/build/static/js/373.bd1a8d6b.chunk.js

"use strict";(self.webpackChunkproject=self.webpackChunkproject||[]).push([[373],{17373:(e,t,r)=>{r.r(t),r.d(t,{default:()=>Me});var n=r(85865),i=r(96446),a=r(19252),o=r(22698),l=r(78185),s=r(68903),d=r(39336),c=r(42518),x=r(36171),m=r(65043),p=r(73216),h=r(44978),g=r(84289),u=r(26240),v=r(12110),j=r(26494),A=r(81637),f=r(17392),y=r(71245),b=r(36591),_=r(13766),k=r(86605),C=r(40710),w=r(81045),S=r(16682),I=r(66032),F=r(88206),N=r(97412),R=r(23768),z=r(30349),E=r(79456),B=r(95539),P=r(46941),W=r(69369),M=r(74763),D=r(74802),T=r(24817),L=r(72949),$=r(70506),O=r(62811),J=r(27628),H=r(22963),q=r.n(H),G=r(77548),Y=r(19540),U=r(70579);q().setAppElement("#root");const Q=e=>{var t;let{urls:r,setLightBoxState:n}=e;const[i,a]=(0,m.useState)(!1),[o,l]=(0,m.useState)(0),[s,d]=(0,m.useState)(!1),[c,x]=(0,m.useState)(""),p=null===r||void 0===r||null===(t=r.filter((e=>(0,P.Ir)(e)===P.id.IMAGE)))||void 0===t?void 0:t.map((e=>({src:e})));return(0,U.jsxs)("div",{className:"main-lightbox",children:[(0,U.jsx)("div",{className:"all-images",children:(()=>{try{return r.map(((e,t)=>{const r=(0,P.Ir)(e);return(0,U.jsx)("div",{onClick:()=>((e,t,r)=>{try{t===P.id.IMAGE?(l(r),a(!0),n(!0)):t===P.id.VIDEO&&(x(e),d(!0),n(!0))}catch(i){n(!1),console.error("Error handling click:",i)}})(e,r,t),className:"parent_div",children:r===P.id.IMAGE?(0,U.jsx)("img",{src:e,alt:"work evidence",onError:P.jM}):(0,U.jsx)("video",{className:"video_data",src:e})},t)}))}catch(e){return console.error("Error rendering URLs:",e),null}})()}),i&&(0,U.jsx)(U.Fragment,{children:(0,U.jsx)(Y.A,{lightboxOpen:i,currentImages:p,currentImageIndex:o,handleCloseLightbox:()=>{n(!1),a(!1)},gotoNext:()=>l((e=>(e+1)%(null===p||void 0===p?void 0:p.length))),gotoPrevious:()=>{const e=(o+(null===p||void 0===p?void 0:p.length)-1)%(null===p||void 0===p?void 0:p.length);l(e)}})}),s&&(0,U.jsx)(G.A,{isOpen:s,videoUrl:c,onClose:()=>d(!1)})]})};var V=r(29082);const Z=e=>{var t,r,a,o,g,u,H,q,G,Y,Z,K,X,ee,te,re,ne,ie,ae,oe,le,se,de,ce,xe,me,pe;let{service:he,index:ge,provider:ue,partner_id:ve}=e;const[je,Ae]=(0,m.useState)(null),[fe,ye]=(0,m.useState)(!1),[be,_e]=(0,m.useState)(!0),[ke,Ce]=(0,m.useState)(0),[we,Se]=(0,m.useState)([]),[Ie]=(0,m.useState)(5),[Fe,Ne]=(0,m.useState)(!0);(0,m.useEffect)((()=>{const e=ue.find((e=>e.partner_id===ve));e&&Ae(e.is_Available_at_location)}),[ve,ue]);const Re=null===(t=(0,E.d4)((e=>e.authentication)))||void 0===t?void 0:t.isLoggedIn,ze=(0,W.u)(),Ee=(0,E.d4)((e=>e.cart)),Be=(0,E.wA)(),Pe=JSON.stringify(null===(r=Ee.base_cart)||void 0===r?void 0:r.data),[We,Me]=(0,m.useState)(!1),De=(0,p.g)(),{company_name:Te}=De;(0,m.useEffect)((()=>{document.title=`${Te}-Services`}),[Te]);const Le=()=>{Be((0,M.R9)([]))},$e=async(e,t)=>{try{Be((0,V.r8)(!1)),Be((0,V.C9)({})),Le(),Me(!0);const r=await x.A.ManageCart({id:e,qty:t.toString()});if(r&&r.data){Be((0,B.Pi)(r));let e=(0,P.eM)(r.message);R.Ay.success(e)}}catch(r){console.log("error",r)}finally{Me(!1)}},Oe=e=>{Re?$e(e,1):R.Ay.error("You need to login before adding Items to your account")},Je=()=>{R.Ay.error("The partner is not available at your location")},He=e=>{var t;Le();const r=(Pe?JSON.parse(Pe):null).find((t=>t.service_id===e.id));null===(t=Ee.base_cart)||void 0===t||t.data.forEach((t=>{if(t.service_id===e.id&&t.qty>0){const n=parseInt(t.qty);if(!r)return void $e(e.id,n+1);if(r.servic_details.max_quantity_allowed>n)return void $e(e.id,n+1);R.Ay.error(`Maximum Quantity is ${r.servic_details.max_quantity_allowed}`)}}))},qe=e=>{var t;null===(t=Ee.base_cart)||void 0===t||t.data.forEach((t=>{Le(),t.service_id==e.id&&$e(e.id,parseInt(t.qty)-1)}))},Ge=null===(a=(0,E.d4)((e=>e.Settings)))||void 0===a?void 0:a.settings,Ye=null===Ge||void 0===Ge||null===(o=Ge.app_settings)||void 0===o?void 0:o.currency,Ue=async e=>{Me(!0),await x.A.removeCart({itemId:e}).then((async e=>{Le(),Be((0,B.Pi)(e));let t=(0,P.eM)(e.message);R.Ay.success(t),Me(!1)})).catch((e=>console.log("error",e)))},[Qe,Ve]=(0,m.useState)(!1),Ze=async(e,t)=>{e.preventDefault(),Ve(!0),ye(!1),_e(!0),Ce(0),Se([]),await Ke(t,0)};(0,m.useEffect)((()=>{}),[fe]);const Ke=async(e,t)=>{try{var r;const n=await x.A.getRating({partner_id:e.user_id,service_id:e.id,offset:t.toString(),limit:Ie.toString()});_e(!1),Se((e=>[...e,...n.data])),Ne((null===n||void 0===n||null===(r=n.data)||void 0===r?void 0:r.length)===Ie)}catch(n){_e(!1),console.log("modalRating ==>",n)}},Xe=()=>{Ve(!1),tt(!1)},[et,tt]=(0,m.useState)(!1),[rt,nt]=(0,m.useState)(!1),it=[5,4,3,2,1],at=[parseInt(he.rating_5),parseInt(he.rating_4),parseInt(he.rating_3),parseInt(he.rating_2),parseInt(he.rating_1)],ot=at.reduce(((e,t)=>e+t),0);return(0,U.jsxs)(i.A,{mt:2,children:[(0,U.jsx)(v.A,{className:"provider-service-card",sx:{background:ze.palette.background.box,boxShadow:"none !important"},children:(0,U.jsx)(i.A,{className:"w-100",children:(0,U.jsxs)(i.A,{className:"row align-items-center",children:[(0,U.jsx)(i.A,{item:!0,className:"col-xxl-2 col-xl-2 col-lg-2 col-md-3 col-12",children:(0,U.jsx)(L.A,{onClick:e=>Ze(e,he),className:"provider-services",children:(0,U.jsx)("img",{src:he.image_of_the_service,alt:"hi",onError:P.jM,className:"provider-service-card1"})})}),(0,U.jsx)(i.A,{item:!0,className:"col-xxl-10 col-xl-10 col-lg-10 col-md-9 col-12",children:(0,U.jsx)(j.A,{sx:{padding:"0"},children:(0,U.jsxs)(i.A,{display:"block",textAlign:"start",children:[(0,U.jsxs)(i.A,{display:"flex",justifyContent:"space-between",children:[(0,U.jsx)(n.A,{color:null===ze||void 0===ze||null===(g=ze.palette)||void 0===g||null===(u=g.primary)||void 0===u?void 0:u.main,sx:{fontSize:"22px",cursor:"pointer"},fontWeight:"bold",mr:"auto",onClick:e=>Ze(),children:he.title}),(0,U.jsx)(N.A,{color:"gold",className:"color-gold"}),parseFloat(he.average_rating).toFixed(1)," ","","("," ",parseFloat(he.total_ratings)," )"]}),(0,U.jsx)(i.A,{children:(0,U.jsx)(n.A,{className:"provider-typo",fontSize:14,pt:2,sx:{wordBreak:"break-word",overflow:"hidden",textOverflow:"ellipsis",display:"-webkit-box",WebkitLineClamp:"2",WebkitBoxOrient:"vertical"},children:he.description})}),(0,U.jsxs)(n.A,{color:"gray",fontSize:14,children:[he.number_of_members_required," ",(0,h.t)("person"),he.duration," ",(0,h.t)("min")]}),(0,U.jsxs)(i.A,{display:"flex",justifyContent:"center",alignItems:"center",mt:1,children:[(0,U.jsx)(n.A,{mr:"auto",fontWeight:"bold",color:null===ze||void 0===ze||null===(H=ze.palette)||void 0===H||null===(q=H.primary)||void 0===q?void 0:q.main,children:(0,U.jsxs)(i.A,{display:"flex",justifyContent:"center",alignItems:"end",gap:"5px",children:[(0,U.jsxs)(n.A,{mr:"auto",fontWeight:"bold",color:null===ze||void 0===ze||null===(G=ze.palette)||void 0===G||null===(Y=G.primary)||void 0===Y?void 0:Y.main,children:[Ye,he.price_with_tax]}),(0,U.jsxs)("del",{children:[Ye,he.original_price_with_tax]})]})}),(0,U.jsx)("div",{className:"",children:We?(0,U.jsx)(A.A,{size:24}):null!==Ee.base_cart&&null!==(Z=Ee.base_cart)&&void 0!==Z&&null!==(K=Z.data)&&void 0!==K&&K.some((e=>e.service_id===he.id))?(0,U.jsxs)(i.A,{size:"large",width:109.88,height:42.5,borderRadius:"5px",bgcolor:null===ze||void 0===ze||null===(X=ze.palette)||void 0===X||null===(ee=X.primary)||void 0===ee?void 0:ee.main,color:"white",display:"flex",justifyContent:"space-around",alignItems:"center",variant:"outlined",children:[null!==(te=Ee.base_cart)&&void 0!==te&&te.data.some((e=>e.service_id===he.id&&1===parseInt(e.qty)))?(0,U.jsx)(f.A,{size:"small",onClick:()=>Ue(he.id),children:(0,U.jsx)(z.A,{className:"delete-icon"})}):(0,U.jsx)(f.A,{size:"small",onClick:()=>{qe(he)},sx:{color:"white"},children:"-"}),null===(re=Ee.base_cart)||void 0===re?void 0:re.data.map((e=>e.service_id===he.id&&e.qty>0?(0,U.jsx)(n.A,{color:"white",children:e.qty}):(0,U.jsx)(U.Fragment,{}))),(0,U.jsx)(f.A,{size:"small",onClick:()=>He(he),sx:{color:"white"},children:"+"})]}):(0,U.jsx)(U.Fragment,{children:1==je?(0,U.jsx)(c.A,{variant:"outlined",onClick:()=>Oe(he.id),float:"right",size:"medium",sx:{px:5,py:1,borderColor:"gray",textTransform:"none","&:hover":{borderColor:"gray"}},children:(0,h.t)("add")}):(0,U.jsx)(c.A,{variant:"outlined",onClick:Je,float:"right",size:"medium",sx:{px:5,py:1,borderColor:"gray",textTransform:"none","&:hover":{borderColor:"gray"}},children:(0,h.t)("add")})})})]})]},ge)})})]})})}),(0,U.jsx)(d.A,{sx:{marginTop:2}}),(0,U.jsx)(y.A,{open:Qe,onClose:Xe,"aria-labelledby":"service-modal","aria-describedby":"service-description",sx:{display:"flex",alignItems:"center",justifyContent:"center"},children:(0,U.jsxs)(i.A,{sx:{...fe?{position:"relative",borderRadius:"15px",p:2,overflow:"hidden"}:{position:"fixed",top:"50%",left:"50%",transform:"translate(-50%, -50%)",width:{xs:"100%",md:500},height:800,maxHeight:"90vh",overflowY:"auto",bgcolor:ze.palette.background.box,boxShadow:24,borderRadius:"10px",m:0,p:0}},children:[(0,U.jsx)(f.A,{onClick:Xe,sx:{position:"absolute",top:0,right:0,m:1,zIndex:1,color:"#FFFFFF",backgroundColor:"#343F53 !important","&:hover":{backgroundColor:"#343F53 !important"}},children:(0,U.jsx)(D.A,{})}),(0,U.jsx)(s.Ay,{container:!0,md:12,xs:12,mb:2,children:(0,U.jsx)(s.Ay,{item:!0,md:12,xs:12,children:(0,U.jsx)("img",{width:"100%",src:he.image_of_the_service,alt:he.title,onError:P.jM})})}),(0,U.jsxs)(s.Ay,{container:!0,display:"flex",justifyContent:"center",children:[(0,U.jsxs)(s.Ay,{item:!0,md:9,xs:6,px:2,mb:2,mt:1,children:[(0,U.jsx)(n.A,{variant:"h5",component:"h2",sx:{fontFamily:"Plus Jakarta Sans",fontWeight:"bold",fontSize:"24px",lineHeight:"32px",letterSpacing:"1.2px",color:ze.palette.color.textColor,textAlign:"left",wordBreak:"break-word"},children:he.title}),(0,U.jsx)(n.A,{fontWeight:"bold",color:ze.palette.color.textColor,children:(0,U.jsxs)(i.A,{display:"flex",justifyContent:"start",alignItems:"center",gap:"14px",my:1,children:[(0,U.jsxs)(n.A,{variant:"h5",sx:{fontFamily:"Plus Jakarta Sans",fontWeight:"bold",fontSize:"16px",lineHeight:"26px",letterSpacing:"0.8px",color:ze.palette.color.textColor,textAlign:"left",marginTop:1,wordBreak:"break-word"},children:[Ye,he.price_with_tax]}),(0,U.jsx)("del",{children:(0,U.jsxs)(n.A,{variant:"h5",sx:{fontFamily:"Plus Jakarta Sans",fontWeight:"normal",fontSize:"16px",lineHeight:"26px",letterSpacing:"0.8px",color:ze.palette.color.textColor,opacity:.4,textAlign:"left",marginTop:1,wordBreak:"break-word"},children:[Ye,he.original_price_with_tax]})})]})}),(0,U.jsxs)(n.A,{color:"gray",fontSize:14,mt:0,children:[he.number_of_members_required," ",(0,h.t)("person"),he.duration," ",(0,h.t)("min")]})]}),(0,U.jsxs)(s.Ay,{item:!0,md:3,xs:6,mt:2,mb:2,children:[(0,U.jsxs)(i.A,{display:"flex",justifyContent:"end",mr:3,children:[(0,U.jsx)(N.A,{color:"gold",className:"color-gold"}),(0,U.jsxs)(i.A,{sx:{fontFamily:"Plus Jakarta Sans",color:ze.palette.color.textColor},children:[parseFloat(he.average_rating).toFixed(1)," ","","("," ",parseFloat(he.total_ratings)," )"]})]}),(0,U.jsx)(i.A,{display:"flex",mt:1,children:(0,U.jsx)("div",{className:"",children:We?(0,U.jsx)(A.A,{size:24}):null!==Ee.base_cart&&null!==(ne=Ee.base_cart)&&void 0!==ne&&null!==(ie=ne.data)&&void 0!==ie&&ie.some((e=>e.service_id===he.id))?(0,U.jsxs)(i.A,{size:"large",width:80,height:40,borderRadius:"5px",bgcolor:null===ze||void 0===ze||null===(ae=ze.palette)||void 0===ae||null===(oe=ae.primary)||void 0===oe?void 0:oe.main,color:"white",display:"flex",justifyContent:"space-around",alignItems:"center",variant:"outlined",children:[null!==(le=Ee.base_cart)&&void 0!==le&&le.data.some((e=>e.service_id===he.id&&1===parseInt(e.qty)))?(0,U.jsx)(f.A,{size:"small",onClick:()=>Ue(he.id),children:(0,U.jsx)(z.A,{className:"delete-icon"})}):(0,U.jsx)(f.A,{size:"small",onClick:()=>{qe(he)},sx:{color:"white"},children:"-"}),null===(se=Ee.base_cart)||void 0===se?void 0:se.data.map((e=>e.service_id===he.id&&e.qty>0?(0,U.jsx)(n.A,{color:"white",children:e.qty}):(0,U.jsx)(U.Fragment,{}))),(0,U.jsx)(f.A,{size:"small",onClick:()=>He(he),sx:{color:"white"},children:"+"})]}):(0,U.jsx)(U.Fragment,{children:1==je?(0,U.jsx)(c.A,{variant:"outlined",onClick:()=>{Oe(he.id)},float:"right",size:"medium",sx:{px:5,py:1,borderColor:"gray",textTransform:"none","&:hover":{borderColor:"gray"}},children:(0,h.t)("add")}):(0,U.jsx)(c.A,{variant:"outlined",onClick:Je,float:"right",size:"medium",sx:{px:5,py:1,borderColor:"gray",textTransform:"none","&:hover":{borderColor:"gray"}},children:(0,h.t)("add")})})})})]})]}),(0,U.jsxs)(s.Ay,{container:!0,p:2,sx:{borderTop:"1px solid #A5A9B0"},children:[(0,U.jsx)(s.Ay,{item:!0,md:12,xs:12,children:(0,U.jsx)(n.A,{variant:"h5",sx:{fontFamily:"Plus Jakarta Sans",fontWeight:"bold",fontSize:"24px",lineHeight:"32px",letterSpacing:"0px",color:ze.palette.color.textColor,opacity:1,textAlign:"left",wordBreak:"break-word"},children:(0,h.t)("about_service")})}),(0,U.jsx)(s.Ay,{item:!0,md:12,xs:12,mt:1,children:(0,U.jsx)(i.A,{children:(0,U.jsx)(n.A,{fontSize:"16px",lineHeight:"24px",fontFamily:"Plus Jakarta Sans",color:ze.palette.color.textColor,textAlign:"left",sx:{fontWeight:"normal",letterSpacing:"0px",wordBreak:"break-word"},children:he.description},ge)})})]}),(null===he||void 0===he||null===(de=he.long_description)||void 0===de?void 0:de.length)>0&&(0,U.jsxs)(s.Ay,{container:!0,p:2,sx:{borderTop:"1px solid #A5A9B0"},children:[(0,U.jsx)(s.Ay,{item:!0,md:12,xs:12,children:(0,U.jsx)(n.A,{variant:"h5",sx:{fontFamily:"Plus Jakarta Sans",fontWeight:"bold",fontSize:"24px",lineHeight:"32px",letterSpacing:"0px",color:ze.palette.color.textColor,opacity:1,textAlign:"left",wordBreak:"break-word"},children:(0,h.t)("service_description")})}),(0,U.jsx)(s.Ay,{item:!0,md:12,xs:12,mt:1,children:(0,U.jsx)(i.A,{children:(0,U.jsx)(n.A,{fontSize:"16px",lineHeight:"24px",fontFamily:"Plus Jakarta Sans",color:ze.palette.color.textColor,textAlign:"left",sx:{fontWeight:"normal",letterSpacing:"0px",wordBreak:"break-word"},children:(lt=he.long_description,(new DOMParser).parseFromString(lt,"text/html").body.textContent||"")},ge)})})]}),(null===he||void 0===he||null===(ce=he.other_images)||void 0===ce?void 0:ce.length)>0&&(0,U.jsxs)(s.Ay,{container:!0,p:2,sx:{borderTop:"1px solid #A5A9B0"},children:[(0,U.jsx)(s.Ay,{item:!0,md:12,xs:12,children:(0,U.jsx)(n.A,{variant:"h5",sx:{fontFamily:"Plus Jakarta Sans",fontWeight:"bold",fontSize:"24px",lineHeight:"32px",letterSpacing:"0px",color:ze.palette.color.textColor,opacity:1,textAlign:"left",wordBreak:"break-word"},children:(0,h.t)("photos")})}),(0,U.jsx)(s.Ay,{item:!0,md:12,xs:12,display:"flex",flexWrap:"wrap",alignItems:"center",justifyContent:"center",my:2,children:(null===he||void 0===he?void 0:he.other_images)&&(null===he||void 0===he||null===(xe=he.other_images)||void 0===xe?void 0:xe.length)>0&&(0,U.jsx)(U.Fragment,{children:[0,1].map((e=>(0,U.jsx)(i.A,{sx:{display:"flex",marginBottom:"16px",position:"relative"},children:he.other_images.slice(2*e,2*e+2).map(((t,r)=>(0,U.jsx)(i.A,{sx:{marginRight:0===r?"16px":"0px",position:"relative"},children:(0,U.jsxs)(v.A,{sx:{width:"200px",borderRadius:"10px",position:"relative"},children:[(0,U.jsx)(b.A,{component:"img",image:t,alt:`Image ${2*e+r+1}`,sx:{width:"200px",height:"200px"}}),1===e&&1===r&&(0,U.jsxs)(U.Fragment,{children:[(0,U.jsx)(i.A,{sx:{position:"absolute",top:0,left:0,width:"100%",height:"100%",backgroundColor:"rgba(0, 0, 0, 0.5)",borderRadius:"10px"}}),(0,U.jsx)(i.A,{sx:{position:"absolute",top:"50%",left:"50%",transform:"translate(-50%, -50%)",zIndex:1},children:(0,U.jsxs)(c.A,{variant:"contained",sx:{width:"150px",textTransform:"none"},onClick:()=>{tt(!0)},children:[(0,U.jsx)(T.A,{sx:{width:"20%"}}),(0,h.t)("see_all")]})})]})]})},r)))},e)))})})]}),(null===he||void 0===he||null===(me=he.files)||void 0===me?void 0:me.length)>0?(0,U.jsxs)(s.Ay,{container:!0,spacing:2,mb:4,p:2,bgcolor:ze.palette.background.box,borderRadius:"10px",children:[(0,U.jsx)(s.Ay,{item:!0,md:12,children:(0,U.jsxs)(n.A,{variant:"body1",sx:{font:"normal normal bold 24px/32px 'Plus Jakarta Sans'",color:ze.palette.color.textColor,textAlign:{xs:"center",md:"left"},letterSpacing:"0px",opacity:1,marginBottom:"30px",wordBreak:"break-word"},children:[(0,h.t)("brochure"),"/",(0,h.t)("files")]})}),(0,U.jsx)(s.Ay,{item:!0,md:12,mt:-2,children:(0,U.jsx)("div",{className:"files_data",children:null===he||void 0===he?void 0:he.files.map(((e,t)=>{const r=e.split("/").pop(),n=r.replace(/\.[^/.]+$/,"");return(0,U.jsxs)(i.A,{mb:"16px",children:[(0,U.jsx)($.A,{}),(0,U.jsx)("a",{href:e,download:r,style:{textDecoration:"none",color:ze.palette.color.textColor},children:n})]},t)}))})})]}):null,(null===he||void 0===he||null===(pe=he.faqs)||void 0===pe?void 0:pe.length)>0?(0,U.jsxs)(s.Ay,{container:!0,spacing:2,mb:4,p:2,bgcolor:ze.palette.background.box,borderRadius:"10px",children:[(0,U.jsx)(s.Ay,{item:!0,md:12,children:(0,U.jsx)(n.A,{variant:"body1",sx:{font:"normal normal bold 24px/32px 'Plus Jakarta Sans'",color:ze.palette.color.textColor,textAlign:{xs:"center",md:"left"},letterSpacing:"0px",opacity:1,marginBottom:"30px",wordBreak:"break-word"},children:(0,h.t)("faq")})}),(0,U.jsx)(s.Ay,{item:!0,md:12,mt:-2,children:(0,U.jsx)("div",{children:null===he||void 0===he?void 0:he.faqs.map(((e,t)=>{return(0,U.jsx)(i.A,{mb:"16px",children:(0,U.jsxs)(_.A,{expanded:rt===`panel${t}`,onChange:(r=`panel${t}`,(e,t)=>{nt(!!t&&r)}),style:{backgroundColor:ze.palette.background.box,boxShadow:"none",border:"1px solid #CCCCCC",color:"#000000"},children:[(0,U.jsx)(k.A,{expandIcon:rt===`panel${t}`?(0,U.jsx)(F.A,{sx:{color:"black"}}):(0,U.jsx)(I.A,{sx:{color:"black"}}),"aria-controls":`panel${t}-content`,id:`panel${t}-header`,style:{backgroundColor:"#FFFFFF",color:"#000000",boxShadow:"none",borderBottom:rt===`panel${t}`?"none":"1px solid #CCCCCC"},children:(0,U.jsxs)(n.A,{children:[String(t+1).padStart(2,"0"),". ",e.question]})}),(0,U.jsx)(C.A,{style:{backgroundColor:"#FFFFFF",color:"#000000",marginTop:"-8px"},children:(0,U.jsx)(n.A,{sx:{font:"var(--unnamed-font-style-normal) normal var(--unnamed-font-weight-normal) 20px/var(--unnamed-line-spacing-32) var(--unnamed-font-family-plus-jakarta-sans)",color:"var(--secondary-color-343f53)",textAlign:"left",letterSpacing:"0px",opacity:.6,wordBreak:"break-word"},children:e.answer})})]})},t);var r}))})})]}):null,(0,U.jsxs)(i.A,{sx:{p:2,mx:"auto",borderRadius:2,textAlign:"center"},children:[(0,U.jsx)(n.A,{variant:"h6",sx:{mb:2},children:(0,h.t)("overall_rating")}),(0,U.jsxs)(i.A,{sx:{display:"flex",alignItems:"center",justifyContent:"center",mb:2},children:[(0,U.jsx)(n.A,{variant:"h4",sx:{fontWeight:"bold",mr:1},children:parseFloat(null===he||void 0===he?void 0:he.average_rating).toFixed(1)}),(0,U.jsx)(i.A,{sx:{display:"flex"},children:[...Array(5)].map(((e,t)=>(0,U.jsx)(N.A,{sx:{color:t<Math.round(null===he||void 0===he?void 0:he.average_rating)?"#FFD700":"#C0C0C0"}},t)))})]}),(0,U.jsxs)(n.A,{variant:"body2",sx:{mb:2},children:[null===he||void 0===he?void 0:he.total_ratings," ",(0,h.t)("reviews")]}),(0,U.jsx)(s.Ay,{container:!0,spacing:1,children:it&&it.map(((e,t)=>(0,U.jsxs)(s.Ay,{item:!0,xs:12,sx:{display:"flex",alignItems:"center",gap:"20px"},children:[(0,U.jsx)(n.A,{variant:"body2",children:e}),(0,U.jsx)(i.A,{sx:{flexGrow:1,bgcolor:"#C0C0C0",position:"relative",height:10},children:(0,U.jsx)(i.A,{sx:{height:"100%",width:at[t]/ot*100+"%",bgcolor:"#FFD700",position:"absolute",top:0,left:0}})})]},e)))}),(0,U.jsx)(i.A,{mx:1,children:!1===be?we&&0===(null===we||void 0===we?void 0:we.length)?(0,U.jsxs)("div",{className:"textaling-center",children:[(0,U.jsx)(i.A,{mt:5,children:(0,U.jsx)("img",{src:J,height:300,width:300,alt:"not found",onError:P.jM})}),(0,U.jsx)("p",{children:(0,h.t)("no_review_found")})]}):we&&we.map((e=>{var t,r;return(0,U.jsxs)(i.A,{sx:{background:ze.palette.background.box,padding:2,marginBottom:1,borderRadius:"10px"},gap:2,children:[(0,U.jsxs)(i.A,{display:"flex",textAlign:"start",alignItems:"center",children:[(0,U.jsx)(w.A,{alt:null===e||void 0===e?void 0:e.user_name,className:"avatar",src:null===e||void 0===e?void 0:e.profile_image}),(0,U.jsxs)(i.A,{marginLeft:3,width:"100%",children:[(0,U.jsxs)(i.A,{sx:{float:"right",justifyContent:"end",textAlign:"end"},children:[(0,U.jsxs)(i.A,{sx:{display:"flex",alignItems:"center"},children:[(0,U.jsx)(N.A,{color:"gold",className:"color-gold"}),(0,U.jsx)(n.A,{variant:"body1",fontSize:"small",children:parseFloat(null===e||void 0===e?void 0:e.rating).toFixed(1)})]}),(0,U.jsx)(n.A,{paddingTop:-2,color:"gray",children:(0,O.A)(new Date(null===e||void 0===e?void 0:e.rated_on),{addSuffix:!0})})]}),(0,U.jsx)(n.A,{variant:"h6",color:null===ze||void 0===ze||null===(t=ze.palette)||void 0===t||null===(r=t.primary)||void 0===r?void 0:r.main,fontSize:"medium",children:(0,U.jsx)("strong",{children:null===e||void 0===e?void 0:e.user_name})}),(0,U.jsx)(S.A,{name:"read-only",className:"font-medium",value:null===e||void 0===e?void 0:e.rating,readOnly:!0})]})]}),e.comment?(0,U.jsx)(n.A,{marginTop:1,children:e.comment}):"",null!==e&&void 0!==e&&e.images?(0,U.jsx)(i.A,{marginTop:3,marginBottom:3,children:(0,U.jsx)(Q,{urls:null===e||void 0===e?void 0:e.images,setLightBoxState:ye})}):(0,U.jsx)(U.Fragment,{}),(0,U.jsx)(d.A,{sx:{mt:2}})]},e.id)})):(0,U.jsxs)(i.A,{children:[(0,U.jsx)(l.A,{variant:"rectangular",height:"100px"}),(0,U.jsx)(l.A,{variant:"rectangular",sx:{mt:2},height:"100px"}),(0,U.jsx)(l.A,{variant:"rectangular",sx:{mt:2},height:"100px"}),(0,U.jsx)(l.A,{variant:"rectangular",sx:{mt:2},height:"100px"}),(0,U.jsx)(l.A,{variant:"rectangular",sx:{mt:2},height:"100px"}),(0,U.jsx)(l.A,{variant:"rectangular",sx:{mt:2},height:"100px"}),(0,U.jsx)(l.A,{variant:"rectangular",sx:{mt:2},height:"100px"}),(0,U.jsx)(l.A,{variant:"rectangular",sx:{mt:2},height:"100px"})]})}),(0,U.jsx)(i.A,{sx:{display:"flex",justifyContent:"center"},children:Fe&&!be&&(0,U.jsx)(c.A,{variant:"contained",disableElevation:!0,size:"small",onClick:async()=>{const e=ke+Ie;Ce(e),await Ke(he.id,e)},children:(0,h.t)("load_more")})})]})]})}),(0,U.jsx)(y.A,{open:et,onClose:()=>tt(!1),children:(0,U.jsxs)(i.A,{sx:{position:"relative",width:"80%",height:"80%",top:"50%",left:"50%",transform:"translate(-50%, -50%)",bgcolor:"background.paper",border:"2px solid #000",borderRadius:"10px",boxShadow:24,p:{xs:0,md:4},overflowY:"auto"},children:[(0,U.jsx)(i.A,{display:"flex",width:"100%",alignItems:"center",justifyContent:"flex-end",children:(0,U.jsx)(f.A,{onClick:Xe,sx:{position:"sticky",top:"5px",display:"flex",justifyContent:"end",color:ze.palette.color.textColor,zIndex:1},children:(0,U.jsx)(D.A,{})})}),(0,U.jsx)(s.Ay,{container:!0,spacing:0,alignItems:"stretch",children:he.other_images.map(((e,t)=>(0,U.jsx)(s.Ay,{item:!0,xs:6,sm:4,md:3,children:(0,U.jsx)(v.A,{sx:{margin:"8px"},children:(0,U.jsx)(b.A,{component:"img",image:e,alt:`Image ${t+1}`})})},t)))})]})})]});var lt};var K=r(17428),X=r(24056),ee=r(22016),te=r(15710),re=r(86506),ne=r(10611),ie=r(58729),ae=r(48729);const oe=e=>{let{overallRating:t,star1:r,star2:a,star3:o,star4:s,star5:g,noOfRating:A,partnerID:f,partner:y}=e;const[b,_]=(0,m.useState)(5),[k,C]=(0,m.useState)(0),[I,F]=(0,m.useState)(5),[N,R]=(0,m.useState)([]),[z,E]=(0,m.useState)(!0),[B,W]=(0,m.useState)(!0),M=(0,u.A)(),D=(0,p.g)(),{company_name:T}=D;(0,m.useEffect)((()=>{document.title=`${T}-Reviews | HausMate`}),[]),(0,m.useEffect)((()=>{(async()=>{try{var e,t;const r=await x.A.getRating({partner_id:y.partner_id,offset:k.toString(),limit:I.toString()});R((e=>[...e,...r.data])),E(!1),_(null===r||void 0===r||null===(e=r.data)||void 0===e?void 0:e.length),W((null===r||void 0===r||null===(t=r.data)||void 0===t?void 0:t.length)===I)}catch(r){console.error("Error loading reviews:",r)}})()}),[k,I,y.partner_id]);return(0,U.jsx)(U.Fragment,{children:(0,U.jsx)(v.A,{sx:{borderRadius:"10px"},children:(0,U.jsxs)(j.A,{sx:{backgroundColor:M.palette.background.box,maxWidth:"100%",pb:"5px !important"},children:[(0,U.jsx)(n.A,{variant:"h5",fontWeight:"bold",mb:2,pl:2,children:(0,h.t)("overall_rating")}),(0,U.jsx)(d.A,{orientation:"horizontal",sx:{mx:-2}}),(0,U.jsx)(le,{overall:Number(t),star1:r,star2:a,star3:o,star4:s,star5:g,noOfRating:A}),(0,U.jsx)(i.A,{mx:1,children:!1===z?N&&0===(null===N||void 0===N?void 0:N.length)?(0,U.jsxs)("div",{className:"textaling-center",children:[(0,U.jsx)(i.A,{mt:5,children:(0,U.jsx)("img",{src:J,height:300,width:300,alt:"not found",onError:P.jM})}),(0,U.jsx)("p",{children:(0,h.t)("no_review_found")})]}):N&&N.map((e=>{var t,r;return(0,U.jsxs)(i.A,{sx:{background:M.palette.background.box,padding:2,marginBottom:1,borderRadius:"10px"},gap:2,children:[(0,U.jsxs)(i.A,{display:"flex",textAlign:"start",alignItems:"center",children:[(0,U.jsx)(w.A,{alt:e.user_name,className:"avatar",src:e.profile_image}),(0,U.jsxs)(i.A,{marginLeft:3,width:"100%",className:"custom-review-card",children:[(0,U.jsxs)(i.A,{sx:{float:"right",justifyContent:"end",textAlign:"end"},children:[(0,U.jsx)(n.A,{variant:"body1",fontSize:"small",children:parseFloat(e.rating).toFixed(1)}),(0,U.jsx)(n.A,{paddingTop:-2,color:"gray",children:(0,O.A)(new Date(e.rated_on),{addSuffix:!0})})]}),(0,U.jsxs)(i.A,{children:[(0,U.jsx)(n.A,{variant:"h6",color:null===M||void 0===M||null===(t=M.palette)||void 0===t||null===(r=t.primary)||void 0===r?void 0:r.main,fontSize:"medium",children:(0,U.jsx)("strong",{children:e.user_name})}),(0,U.jsx)(S.A,{name:"read-only",className:"font-medium",value:e.rating,readOnly:!0})]})]})]}),e.comment?(0,U.jsx)(n.A,{marginTop:1,children:e.comment}):"",null!==e&&void 0!==e&&e.images?(0,U.jsx)(i.A,{marginTop:3,marginBottom:3,children:(0,U.jsx)(ae.A,{urls:e.images})}):(0,U.jsx)(U.Fragment,{}),(0,U.jsx)(d.A,{sx:{mt:2}})]},e.id)})):(0,U.jsxs)(i.A,{children:[(0,U.jsx)(l.A,{variant:"rectangular",height:"100px"}),(0,U.jsx)(l.A,{variant:"rectangular",sx:{mt:2},height:"100px"}),(0,U.jsx)(l.A,{variant:"rectangular",sx:{mt:2},height:"100px"}),(0,U.jsx)(l.A,{variant:"rectangular",sx:{mt:2},height:"100px"}),(0,U.jsx)(l.A,{variant:"rectangular",sx:{mt:2},height:"100px"}),(0,U.jsx)(l.A,{variant:"rectangular",sx:{mt:2},height:"100px"}),(0,U.jsx)(l.A,{variant:"rectangular",sx:{mt:2},height:"100px"}),(0,U.jsx)(l.A,{variant:"rectangular",sx:{mt:2},height:"100px"})]})}),(0,U.jsx)(i.A,{sx:{display:"flex",justifyContent:"center"},children:B&&(0,U.jsx)(c.A,{variant:"contained",disableElevation:!0,size:"small",onClick:()=>{C((e=>e+I))},children:(0,h.t)("load_more")})})]})})})},le=e=>{let{overall:t,star1:r,star2:a,star3:o,star4:l,star5:c,noOfRating:x}=e;const m=[r,a,o,l,c],p=Math.max(...m.map((e=>parseInt(e)))),g=m.map(((e,t)=>({value:parseInt(e),index:t})));return g.sort(((e,t)=>t.index-e.index)),(0,U.jsx)(i.A,{justifyContent:"center",alignItems:"center",bgcolor:"#343F53",color:"white",borderRadius:"10px",p:{xs:2,md:0},m:2,children:(0,U.jsxs)(s.Ay,{container:!0,spacing:{xs:0,md:0},children:[(0,U.jsx)(s.Ay,{item:!0,md:4,sm:12,alignItems:"center",width:"100%",children:(0,U.jsxs)(i.A,{m:{xs:0,md:3},display:"flex",bgcolor:"white",borderRadius:"10px",color:"black",flexDirection:"column",alignItems:"center",justifyContent:"center",height:"283px",alignContent:"center",sx:{alignItems:"center"},children:[(0,U.jsx)(n.A,{className:"back-343f",variant:"h5",mb:2,borderRadius:"60px",textAlign:"center",sx:{height:"100px",width:"100px",display:"flex",justifyContent:"center",alignItems:"center",color:"#FFFFFF",textAlign:"left",font:"normal normal bold 38px/13px Plus Jakarta Sans",letterSpacing:"1.9px",opacity:1},children:parseFloat(t).toFixed(1)}),(0,U.jsx)(S.A,{name:"average-rating",className:"gap-1",value:parseFloat(t),precision:.2,component:"legend",readOnly:!0,mb:1}),(0,U.jsxs)(n.A,{variant:"h6",mt:1,gutterBottom:!0,sx:{textAlign:"left",font:"normal normal medium 25px/13px Plus Jakarta Sans",letterSpacing:"1.25px",color:"#343F53",opacity:1},children:[x," ",(0,h.t)("reviews")]})]})}),(0,U.jsx)(s.Ay,{item:!0,md:.1,sm:12,children:(0,U.jsx)(d.A,{orientation:{xs:"horizontal",md:"vertical"},sx:{backgroundColor:"gray",height:{xs:"1px",md:"100%"},width:{xs:"225px",sm:"100%",md:"1px"},ml:{xs:0,md:.2},mt:{xs:2,md:0}}})}),(0,U.jsx)(s.Ay,{item:!0,md:7.9,sm:12,display:"flex",flexDirection:"column",justifyContent:"space-between",width:"100%",p:2,my:4,children:g.map(((e,t)=>(0,U.jsxs)(i.A,{mt:0,mb:0,display:"flex",alignItems:"center",flexDirection:"row",width:"100%",justifyContent:"space-between",rowGap:1,gap:1,children:[(0,U.jsxs)(i.A,{display:"flex",alignItems:"center",children:[(0,U.jsx)(ie.A,{fontSize:"small",sx:{marginRight:"16px"}}),(0,U.jsx)(n.A,{fontSize:"medium",variant:"caption",mr:1,children:e.index+1})]}),(0,U.jsx)(ne.A,{variant:"determinate",value:e.value/p*100,sx:{width:"100%",borderRadius:"5px",backgroundColor:"gray",height:9,"& .MuiLinearProgress-bar":{backgroundColor:"#F6B313"}}}),(0,U.jsx)(n.A,{fontSize:"medium",variant:"caption",ml:4,mr:2,children:e.value||0})]},t)))})]})})},se=e=>{let{isProvierLoading:t,provider:r,partner_id:n}=e;return(0,U.jsx)(i.A,{sx:{ml:-3,mt:-3,mr:-3,borderRadius:"10px"},children:t?(0,U.jsx)(U.Fragment,{children:r.map((e=>{const t=e.ratings,r=e["1_star"],n=e["2_star"],i=e["3_star"],a=e["4_star"],o=e["5_star"],l=e.number_of_ratings,s=e.partner_id;return(0,U.jsx)(oe,{overallRating:t,star1:r,star2:n,star3:i,star4:a,star5:o,noOfRating:l,partnerID:s,partner:e},s)}))}):(0,U.jsxs)(i.A,{display:"flex",flexDirection:"column",gap:3,children:[(0,U.jsx)(l.A,{variant:"rectangular",height:"800px"}),(0,U.jsx)(l.A,{variant:"rectangular",height:"500px"})]})})};var de=r(51962),ce=r(19778),xe=r(92530),me=r(93012),pe=r(77905),he=r(62995),ge=r(86598),ue=r(6407),ve=r(83462),je=r(26600);const Ae=e=>{let{open:t,setOpen:r}=e;const[n,a]=(0,m.useState)(t);return(0,U.jsx)(ve.A,{onClose:()=>{a(!1),r(!1)},open:n,children:(0,U.jsxs)(i.A,{children:[(0,U.jsx)(je.A,{children:(0,h.t)("share_provider_services")}),(0,U.jsx)(ue.A,{xlinkTitle:"Share",size:32,round:!0})]})})};var fe=r(46983),ye=r(34960);const be=e=>{let{rating:t}=e;const r=Math.floor(t),n=t%1!==0,i=5-r-(n?1:0);return(0,U.jsxs)("div",{className:"rating",children:[Array(r).fill().map(((e,t)=>(0,U.jsx)(ye.Q2Z,{className:"full-star",size:26},`full-${t}`))),n&&(0,U.jsx)(ye.h92,{className:"half-star",size:26}),Array(i).fill().map(((e,t)=>(0,U.jsx)(ye.g59,{className:"empty-star",size:26},`empty-${t}`))),(0,U.jsx)("style",{jsx:!0,children:"\n        .rating {\n          display: flex;\n          justify-content: center;\n          align-items: center;\n        }\n\n        .full-star,\n        .half-star,\n        .empty-star {\n          margin: 0 2px;\n          color: #ffd700;\n        }\n\n        .half-star {\n          color: #ffd700; /* Ensure half stars have the correct color */\n        }\n\n        .empty-star {\n          color: #ffd700; /* Empty stars still need to match color */\n        }\n      "})]})},_e=e=>{var t,r,o,d,c,g,j,A,y,_,k,C,S,I,F,z,B;let{partnerID:W,partner:M,isProvierLoading:D}=e;const[T,L]=(0,m.useState)(1),[$,O]=(0,m.useState)(!1),J=(0,u.A)(),H=(0,P.Wz)(),q=(0,E.wA)(),G=(0,p.Zp)(),Y=null===(t=(0,E.d4)((e=>e.Settings)))||void 0===t?void 0:t.settings,Q=null===(r=(0,E.d4)((e=>e.Bookmark)))||void 0===r?void 0:r.bookmark,V=null===(o=(0,E.d4)((e=>e.authentication)))||void 0===o?void 0:o.isLoggedIn,Z=(0,E.d4)((e=>e.Location)),K=Z.lat,X=Z.lng,ee="1"===(null===Y||void 0===Y?void 0:Y.general_settings.allow_pre_booking_chat);let te=Q&&(null===Q||void 0===Q?void 0:Q.filter((e=>e.partner_id===W)));const[re,ne]=(0,m.useState)((null===te||void 0===te?void 0:te.length)>0);(0,m.useEffect)((()=>{(async()=>{if(null==T)try{const e=await x.A.getRating({partner_id:M.partner_id,offset:0,limit:5});L(e.total)}catch(e){console.error("Error fetching rating total:",e)}})()}),[M.partner_id,T]);const ie=M.ratings;return(0,U.jsx)(U.Fragment,{children:(0,U.jsx)(a.A,{sx:{background:J.palette.background.box,borderRadius:"10px",maxWidth:"100%"},className:"mainContainer",children:(0,U.jsxs)(s.Ay,{container:!0,spacing:2,children:[(0,U.jsx)(s.Ay,{item:!0,md:5,sm:6,mb:3,mt:1,alignItems:"center",width:"100%",children:(0,U.jsxs)(v.A,{sx:{position:"relative"},children:[(0,U.jsxs)(i.A,{sx:{borderRadius:"8px",float:"right",mt:1.5,mr:1.5},display:"flex",gap:2,children:[ee&&"1"===(null===M||void 0===M?void 0:M.pre_booking_chat)?(0,U.jsx)(f.A,{"aria-label":"chat",onClick:e=>(e=>{if(e.preventDefault(),!V)return R.Ay.error("you need to login first!"),!1;try{(0,fe.zB)({booking_id:null,partner_id:null===M||void 0===M?void 0:M.partner_id,partner_name:null===M||void 0===M?void 0:M.company_name,image:null===M||void 0===M?void 0:M.image,order_status:""}),G("/chat")}catch(t){console.log(t)}})(e),sx:{color:null===J||void 0===J||null===(d=J.palette)||void 0===d||null===(c=d.primary)||void 0===c?void 0:c.main,backgroundColor:J.palette.background.input,borderRadius:"8px","&:hover":{backgroundColor:J.palette.background.input}},children:(0,U.jsx)(ge.A,{fontSize:"small",color:"action",sx:{color:null===J||void 0===J||null===(g=J.palette)||void 0===g||null===(j=g.primary)||void 0===j?void 0:j.main}})}):null,(0,U.jsx)(f.A,{"aria-label":"share",onClick:e=>{navigator.clipboard.writeText(window.location.href).then((()=>{R.Ay.success((0,h.t)("copied"))})).catch((e=>{console.error("Failed to copy: ",e)}))},sx:{color:null===J||void 0===J||null===(A=J.palette)||void 0===A||null===(y=A.primary)||void 0===y?void 0:y.main,backgroundColor:J.palette.background.input,borderRadius:"8px","&:hover":{backgroundColor:J.palette.background.input}},children:(0,U.jsx)(he.A,{fontSize:"small",color:"action",sx:{color:null===J||void 0===J||null===(_=J.palette)||void 0===_||null===(k=_.primary)||void 0===k?void 0:k.main}})}),!0===$?(0,U.jsx)(Ae,{open:$,setOpen:O}):"",!0===V?(0,U.jsx)(i.A,{sx:{backgroundColor:J.palette.background.input,borderRadius:"8px"},children:(0,U.jsx)(de.A,{size:"small",checked:re,sx:{color:"white"},icon:(0,U.jsx)(xe.A,{sx:{color:null===J||void 0===J||null===(C=J.palette)||void 0===C||null===(S=C.primary)||void 0===S?void 0:S.main}}),checkedIcon:(0,U.jsx)(me.A,{sx:{color:null===J||void 0===J||null===(I=J.palette)||void 0===I||null===(F=I.primary)||void 0===F?void 0:F.main}}),onClick:e=>{e.stopPropagation(),(async e=>{try{ne(!re);let t=new FormData;if(t.append("latitude",K),t.append("longitude",X),!0===re)q((0,pe.ve)(Q.filter((t=>t.partner_id!==e.partner_id)))),await x.A.bookmark({type:"remove",lat:K,lng:X,partner_id:void 0!==e.partner_id?e.partner_id:e.id}).then((t=>{t&&t.data?R.Ay.success(t.message):q((0,pe.ve)(Q.filter((t=>t.partner_id!==e.partner_id))))})).catch((e=>{R.Ay.error("Failed to remove bookmark")}));else{const r={partner_id:e.partner_id};let n=Q;n=[...n,r],q((0,pe.ve)(n)),t.append("type","add"),t.append("partner_id",void 0!==e.partner_id?e.partner_id:e.id),await x.A.bookmark({type:"add",lat:K,lng:X,partner_id:void 0!==e.partner_id?e.partner_id:e.id}).then((t=>{t&&t.data?R.Ay.success(t.message):q((0,pe.ve)(Q.filter((t=>t.partner_id!==e.partner_id))))})).catch((e=>{R.Ay.error("Failed to add bookmark")}))}}catch(t){R.Ay.error("An unexpected error occurred")}})(M)}},M.id)}):""]}),(0,U.jsxs)(i.A,{width:"100%",children:[(0,U.jsx)(b.A,{sx:{objectFit:"cover",height:228,width:"100%"},image:M.banner_image}),(0,U.jsx)(b.A,{sx:{position:"absolute",zIndex:10,top:108,left:20},className:"provider_service_logo",image:M.image})]})]})}),(0,U.jsx)(s.Ay,{item:!0,md:3,sm:6,xs:12,mb:3,maxWidth:"100%",children:D?(0,U.jsx)(U.Fragment,{children:(0,U.jsxs)(i.A,{mt:3,display:"flex",flexDirection:{xs:"column"},alignItems:{xs:"center",md:"baseline"},justifyContent:"center",children:[(0,U.jsx)(n.A,{variant:"h6",mt:{xs:1,md:2},sx:{letterSpacing:"1.2px",color:J.palette.color.textColor,textAlign:{xs:"center",md:"left"}},gutterBottom:!0,children:(0,U.jsx)("strong",{children:M.company_name})},M.partner_id),(0,U.jsx)(n.A,{variant:"subtitle1",sx:{color:J.palette.color.textColor,mt:{xs:0,md:2},textAlign:{xs:"center",md:"left"}},children:(0,h.t)("provider_rating")}),(0,U.jsxs)(i.A,{display:"flex",alignItems:"center",justifyContent:"center",flexDirection:H?"row-reverse":"row",children:[(0,U.jsx)(be,{rating:ie}),(0,U.jsxs)(n.A,{variant:"h6",sx:{marginRight:H?"8px":"0",marginLeft:H?"0":"8px"},children:["(",parseFloat(M.ratings).toFixed(1),")"]})]})]})}):(0,U.jsx)(l.A,{width:200,height:50})}),(0,U.jsx)(s.Ay,{item:!0,md:2,sm:6,xs:6,mb:3,mt:1,children:(0,U.jsxs)(i.A,{display:"flex",width:"228px",height:{xs:"190px",md:"228px"},maxWidth:"100%",borderRadius:"8px",sx:{backgroundColor:null===J||void 0===J||null===(z=J.palette)||void 0===z||null===(B=z.primary)||void 0===B?void 0:B.main,alignItems:"center",justifyContent:"center",flexDirection:"column",margin:"auto"},children:[(0,U.jsx)(w.A,{sx:{bgcolor:"white",marginTop:0,height:"60px",width:"60px"},children:(0,U.jsx)(ce.A,{sx:{p:1,height:"50px",width:"50px"},className:"color-blue border-radius-50"})}),(0,U.jsxs)(i.A,{textAlign:"center",mt:{xs:2,md:5},color:J.palette.color.text,children:[(0,U.jsx)(n.A,{variant:"h5",fontWeight:"bold",children:M.number_of_orders}),(0,U.jsx)(n.A,{variant:"subtitle1",fontWeight:"medium",children:(0,h.t)("bookings_complete")})]})]})}),(0,U.jsx)(s.Ay,{item:!0,md:2,sm:6,xs:6,mb:3,mt:1,children:(0,U.jsxs)(i.A,{display:"flex",width:"228px",height:{xs:"190px",md:"228px"},mb:3,maxWidth:"100%",borderRadius:"8px",sx:{backgroundColor:J.palette.secondary.main,alignItems:"center",justifyContent:"center",flexDirection:"column",margin:"auto"},children:[(0,U.jsx)(w.A,{sx:{bgcolor:"white",marginTop:0,height:"60px",width:"60px"},children:(0,U.jsx)(N.A,{sx:{color:"#343f53",height:"50px",width:"50px"},className:"border-radius-50"})}),(0,U.jsxs)(i.A,{textAlign:"center",mt:{xs:2,md:5},color:J.palette.color.text,children:[(0,U.jsx)(n.A,{variant:"h5",fontWeight:"bold",children:parseFloat(M.ratings).toFixed(1)}),(0,U.jsx)(n.A,{variant:"subtitle1",fontWeight:"medium",children:(0,h.t)("provider_reviewers")})]})]})})]})})})};var ke=r(60446),Ce=r.n(ke);const we=e=>{let{partner_id:t}=e;const r=(0,W.u)(),[a,o]=(0,m.useState)([]),[l,c]=(0,m.useState)(!0),g=(0,p.g)(),{company_name:u}=g;return(0,m.useEffect)((()=>{document.title=`${u}-Promocodes|HausMate`}),[]),(0,m.useEffect)((()=>{(async()=>{try{if(0===(null===a||void 0===a?void 0:a.length)){const e=await x.A.Promocode({partner_id:t});o(e.data),c(!1)}}catch(e){console.error("Error fetching promo code:",e)}})()}),[null===a||void 0===a?void 0:a.length,t]),(0,U.jsx)(i.A,{mr:{xs:0,md:3.5},mt:1,sx:{backgroundColor:r.palette.background.box},children:!1===l?a&&(null===a||void 0===a?void 0:a.length)>0?a.map(((e,t)=>(0,U.jsxs)(s.Ay,{container:!0,mb:2,spacing:2,position:"relative",sx:{background:r.palette.background.box,padding:{xs:0,md:"15px"},borderRadius:"10px",marginTop:t>0?"30px":0},children:[(0,U.jsx)(s.Ay,{item:!0,md:1,xs:12,display:"flex",alignItems:{xs:"center",md:"baseline"},justifyContent:"center",children:(0,U.jsx)(b.A,{component:"img",sx:{width:133,height:133,borderRadius:"50%",marginLeft:2},image:e.image,alt:"Live from space album cover"})}),(0,U.jsxs)(s.Ay,{item:!0,md:7,xs:12,mt:2,ml:{xs:0,md:6},display:"flex",flexDirection:"column",children:[(0,U.jsxs)(s.Ay,{item:!0,children:[(0,U.jsx)(n.A,{sx:{letterSpacing:"1.1px",color:r.palette.color.textColor,opacity:.9,marginLeft:"0px"},variant:"h6",fontWeight:"bold",textAlign:{xs:"center",md:"left"},children:e.promo_code}),(0,U.jsx)(n.A,{sx:{marginTop:"7px",font:"normal normal normal 18px/35px Plus Jakarta Sans",letterSpacing:"0.9px",color:r.palette.color.textColor,opacity:.59,marginLeft:"0px",mr:{xs:0,md:4}},textAlign:{xs:"center",md:"left"},children:e.message})]}),(0,U.jsx)(s.Ay,{item:!0,mb:2,children:(0,U.jsxs)(i.A,{my:2,sx:{textTransform:"capitalize",lineHeight:2,marginLeft:"0px"},children:[(0,U.jsx)(n.A,{variant:"body1",sx:{mb:1,mt:1,color:r.palette.color.textColor,opacity:"0.61"},fontWeight:"bold",children:(0,U.jsxs)(i.A,{display:"flex",flexDirection:{xs:"column",md:"row"},alignItems:"center",gap:1,textAlign:{xs:"center",md:"left"},children:[(0,U.jsx)(i.A,{children:(0,h.t)("min_order_value")}),(0,U.jsxs)(i.A,{children:["$",e.minimum_order_amount]})]})}),(0,U.jsx)(n.A,{variant:"body1",sx:{mb:1,mt:1,letterSpacing:"0.9px",color:r.palette.color.textColor,opacity:" 0.61"},fontWeight:"bold",children:(0,U.jsxs)(i.A,{display:"flex",flexDirection:{xs:"column",md:"row"},alignItems:"center",gap:1,textAlign:{xs:"center",md:"left"},children:[(0,U.jsx)(i.A,{children:(0,h.t)("instant_discount_of")}),(0,U.jsxs)(i.A,{children:["$",e.max_discount_amount]})]})}),(0,U.jsx)(n.A,{variant:"body1",fontWeight:"bold",sx:{mb:1,mt:1,letterSpacing:"0.9px",color:r.palette.color.textColor,opacity:" 0.61"},children:(0,U.jsxs)(i.A,{display:"flex",flexDirection:{xs:"column",md:"row"},alignItems:"center",gap:1,textAlign:{xs:"center",md:"left"},children:[(0,U.jsx)(i.A,{children:(0,h.t)("offer_valid_from")}),(0,U.jsxs)(i.A,{children:[Ce()(e.start_date).format("DD-MM-YYYY")," ",(0,h.t)("to")]}),(0,U.jsx)(i.A,{children:Ce()(e.end_date).format("DD-MM-YYYY")})]})}),e&&e.repeat_usage>=1?(0,U.jsx)(n.A,{variant:"body1",fontWeight:"bold",sx:{mb:1,mt:1,letterSpacing:"0.9px",color:r.palette.color.textColor,opacity:" 0.61"},children:(0,U.jsxs)(i.A,{display:"flex",flexDirection:{xs:"column",md:"row"},alignItems:"center",gap:1,textAlign:{xs:"center",md:"left"},children:[(0,U.jsx)(i.A,{children:(0,h.t)("promo_maximum_times")}),null===e||void 0===e?void 0:e.no_of_repeat_usage,(0,U.jsx)(i.A,{children:(0,h.t)("promo_times")})]})}):null]})})]}),(0,U.jsxs)(i.A,{sx:{position:"relative",display:{xs:"none",sm:"none",md:"block"}},children:[(0,U.jsx)(A.A,{variant:"determinate",value:-50,size:45,thickness:2,sx:{backgroundColor:r.palette.background.promoCode,color:"transparent",borderRadius:"50%"},style:{position:"absolute",top:"-15%",left:"50%",transform:"translate(-45%, 35%)",zIndex:"1",border:"none"}}),(0,U.jsx)(d.A,{orientation:"vertical",flexItem:!0,sx:{mr:"-2px",borderRight:"2px dotted #343F53",top:-12,position:"absolute",height:"100%"}}),(0,U.jsx)(A.A,{variant:"determinate",value:-50,size:45,thickness:2,sx:{backgroundColor:r.palette.background.promoCode,color:"transparent",borderRadius:"50%"},style:{position:"absolute",bottom:"-20%",left:"50%",zIndex:"1",transform:"translate(-45%, -65%)"}})]}),(0,U.jsx)(s.Ay,{item:!0,ml:{xs:0,md:5},md:3,xs:12,display:"flex",justifyContent:"center",alignItems:"center",children:(0,U.jsxs)(i.A,{display:"flex",flexDirection:"column",justifyContent:"center",alignItems:"center",textAlign:"center",mt:4,children:[(0,U.jsxs)(n.A,{component:"div",variant:"h3",sx:{width:"116px",height:"58px",color:r.palette.color.textColor,opacity:"0.9",font:'normal normal bold 16px/8px "Plus Jakarta Sans"',letterSpacing:"2.3px"},children:[e.discount,"percentage"===e.discount_type?"%":"$"," "]}),(0,U.jsx)(n.A,{component:"div",variant:"h3",mb:1,sx:{width:"114px",height:"58px",opacity:"0.9",color:r.palette.color.textColor,font:'normal normal bold 16px/8px "Plus Jakarta Sans"',letterSpacing:"2.3px"},children:"OFF"})]})})]},t))):(0,U.jsx)(U.Fragment,{children:(0,U.jsx)(i.A,{display:"flex",justifyContent:"center",alignItems:"center",textAlign:"center",sx:{flexDirection:{xs:"column",md:"row"},margin:"50px auto"},maxWidth:"100%",children:(0,U.jsxs)(i.A,{children:[(0,U.jsx)(i.A,{children:(0,U.jsx)(i.A,{component:"img",src:J,alt:"no promo code",maxHeight:"100%",maxWidth:"100%"})}),(0,U.jsx)(n.A,{sx:{color:r.palette.color.textColor,margin:"10px auto"},children:(0,h.t)("no_promo")})]})})}):(0,U.jsx)(K.Nn,{})})};var Se=r(95263);const Ie=r.p+"static/media/No_Image Found_99.da209b8fc17a3f973d7b93218b01f952.svg";var Fe=r(95367),Ne=r(25581),Re=r(85369);q().setAppElement("#root");const ze=e=>{var t;let{urls:r}=e;const[n,i]=(0,m.useState)(!1),[a,o]=(0,m.useState)(0),[l,s]=(0,m.useState)(!1),[d,x]=(0,m.useState)(""),[p,h]=(0,m.useState)(!1),g=(e,t,r)=>{try{t===P.id.IMAGE?(o(r),i(!0)):t===P.id.VIDEO&&(x(e),s(!0))}catch(n){console.error("Error handling click:",n)}},u=null===r||void 0===r||null===(t=r.filter((e=>(0,P.Ir)(e)===P.id.IMAGE)))||void 0===t?void 0:t.map((e=>({src:e})));return(0,U.jsxs)("div",{className:"main-lightbox",children:[(0,U.jsxs)("div",{className:"all-images",children:[(()=>{try{return r.slice(0,6).map(((e,t)=>{const r=(0,P.Ir)(e);return(0,U.jsx)("div",{onClick:()=>g(e,r,t),className:"parent_div",children:r===P.id.IMAGE?(0,U.jsx)("img",{src:e,alt:"work evidence"}):(0,U.jsx)("video",{className:"video_data",src:e})},t)}))}catch(e){return console.error("Error rendering URLs:",e),null}})(),r.length>6&&(0,U.jsx)(c.A,{onClick:()=>h(!0),children:"See All"})]}),n&&(0,U.jsx)(U.Fragment,{children:(0,U.jsx)(Y.A,{lightboxOpen:n,currentImages:u,currentImageIndex:a,handleCloseLightbox:()=>i(!1),gotoNext:()=>o((e=>(e+1)%(null===u||void 0===u?void 0:u.length))),gotoPrevious:()=>{const e=(a+(null===u||void 0===u?void 0:u.length)-1)%(null===u||void 0===u?void 0:u.length);o(e)}})}),l&&(0,U.jsx)(G.A,{isOpen:l,videoUrl:d,onClose:()=>s(!1)}),(0,U.jsxs)(q(),{isOpen:p,onRequestClose:()=>h(!1),contentLabel:"All Images Modal",children:[(0,U.jsx)("button",{onClick:()=>h(!1),className:"about_lightbox_closeButton","aria-label":"Close",children:(0,U.jsx)(Re.QCr,{})}),(0,U.jsx)("div",{className:"about_lightbox_all-images-modal",children:r.map(((e,t)=>{const r=(0,P.Ir)(e);return(0,U.jsx)("div",{onClick:()=>g(e,r,t),className:"parent_div",children:r===P.id.IMAGE?(0,U.jsx)("img",{src:e,alt:"work evidence"}):(0,U.jsx)("video",{className:"video_data",src:e})},t)}))})]})]})},Ee=e=>{var t,r;let{data:a}=e;const o=a&&a.latitude,l=a&&a.longitude,d=(0,p.g)(),{company_name:c}=d;(0,m.useEffect)((()=>{document.title=`${c}-About Us|HausMate`}),[]);const[x,g]=(0,m.useState)(!1),u=e=>{const[t,r]=e.split(":").map(Number);return`${t%12||12}:${r<10?"0":""}${r} ${t>=12?"PM":"AM"}`},j=e=>(new DOMParser).parseFromString(e,"text/html").body.textContent||"",A=(0,W.u)(),f=e=>a&&"1"===a[`${e.toLowerCase()}_is_open`];return(0,U.jsxs)(i.A,{children:[(0,U.jsxs)(s.Ay,{container:!0,spacing:2,children:[(0,U.jsx)(s.Ay,{item:!0,md:12,mb:2,p:2,bgcolor:A.palette.background.box,borderRadius:"10px",children:(0,U.jsxs)("div",{children:[(0,U.jsx)(n.A,{variant:"body1",sx:{font:"normal normal bold 24px/32px 'Plus Jakarta Sans'",color:A.palette.color.textColor,textAlign:"left",letterSpacing:"0px",opacity:1,marginBottom:"19px"},children:(0,h.t)("about_this_provider")}),(0,U.jsx)(i.A,{children:(0,U.jsx)(n.A,{sx:{font:"var(--unnamed-font-style-normal) normal var(--unnamed-font-weight-normal) 20px/var(--unnamed-line-spacing-32) var(--unnamed-font-family-plus-jakarta-sans)",textAlign:{xs:"center",md:"left"},marginBottom:"30px"},color:A.palette.color.textColor,children:null===a||void 0===a?void 0:a.about})})]})}),(0,U.jsxs)(s.Ay,{container:!0,gap:2,mb:2,mt:-2,py:2,children:[(0,U.jsxs)(s.Ay,{item:!0,md:5.9,bgcolor:A.palette.background.box,borderRadius:"10px",children:[(0,U.jsx)(n.A,{variant:"body1",sx:{font:"normal normal bold 24px/32px 'Plus Jakarta Sans'",color:A.palette.color.textColor,textAlign:{xs:"center",md:"left"},letterSpacing:"0px",opacity:1,marginBottom:"4px",borderRadius:"10px",padding:2},children:(0,h.t)("bussiness_hours")}),(0,U.jsx)(s.Ay,{container:!0,gap:1,ml:{xs:0,md:2},mb:2,children:["Monday","Tuesday","Wednesday","Thursday","Friday","Saturday","Sunday"].map(((e,t)=>(0,U.jsxs)(s.Ay,{container:!0,children:[(0,U.jsx)(s.Ay,{item:!0,xs:12,md:6,children:(0,U.jsx)(n.A,{variant:"body1",sx:{font:"normal normal medium 22px/32px Plus Jakarta Sans",color:A.palette.color.textColor,textAlign:{xs:"center",md:"left"},letterSpacing:"1.1px",opacity:1,marginBottom:"3px"},children:e})}),(0,U.jsx)(s.Ay,{item:!0,xs:12,md:6,children:(0,U.jsx)(n.A,{variant:"body1",color:A.palette.color.textColor,textAlign:{xs:"center",md:"left"},children:f(e)?`${u(a[`${e.toLowerCase()}_opening_time`])} - ${u(a[`${e.toLowerCase()}_closing_time`])}`:"Closed"})})]},t)))})]}),(0,U.jsxs)(s.Ay,{item:!0,md:5.9,width:"100%",bgcolor:A.palette.background.box,borderRadius:"10px",p:2,children:[(0,U.jsx)(s.Ay,{item:!0,md:12,children:(0,U.jsx)(n.A,{variant:"body1",sx:{font:"normal normal bold 24px/32px 'Plus Jakarta Sans'",color:A.palette.color.textColor,textAlign:"left",letterSpacing:"0px",opacity:1},children:(0,h.t)("photos")})}),(0,U.jsx)(i.A,{mx:1,my:2,px:2,maxWidth:"100%",display:"flex",flexDirection:"column",gap:2,children:(null===a||void 0===a||null===(t=a.other_images)||void 0===t?void 0:t.length)>0?(0,U.jsx)(i.A,{children:(0,U.jsx)(ze,{urls:a.other_images})}):(0,U.jsxs)(i.A,{mt:3,sx:{display:"flex",justifyContent:"center",flexDirection:"column",alignItems:"center"},children:[(0,U.jsx)(v.A,{sx:{width:"60%",marginTop:"0px",height:"80%",marginBottom:"8px",position:"relative",borderRadius:"10px",boxShadow:"none",display:"flex",justifyContent:"center",alignItems:"center"},children:(0,U.jsx)(b.A,{component:"img",image:Ie,alt:"No Image",sx:{width:"100%",height:"100%"}})}),(0,U.jsx)(n.A,{variant:"h6",textAlign:"center",color:"#4a4a4a",children:"No Photos Available"})]})})]})]})]}),(null===(r=j(a.long_description))||void 0===r?void 0:r.length)>0&&(0,U.jsx)(s.Ay,{container:!0,spacing:2,mt:-2,children:(0,U.jsxs)(s.Ay,{item:!0,md:12,bgcolor:A.palette.background.box,borderRadius:"10px",children:[(0,U.jsx)(n.A,{variant:"body1",sx:{font:"normal normal bold 24px/32px 'Plus Jakarta Sans'",color:A.palette.color.textColor,textAlign:"left",letterSpacing:"0px",opacity:1,marginBottom:"30px",wordBreak:"break-word"},children:(0,h.t)("company_information")}),(0,U.jsx)(s.Ay,{container:!0,children:(0,U.jsx)(s.Ay,{item:!0,md:12,children:(0,U.jsx)(n.A,{sx:{font:"var(--unnamed-font-style-normal) normal var(--unnamed-font-weight-normal) 20px/var(--unnamed-line-spacing-32) var(--unnamed-font-family-plus-jakarta-sans)",textAlign:{xs:"center",md:"left"},letterSpacing:"0px",marginBottom:"30px",pr:2,wordBreak:"break-word"},color:A.palette.color.textColor,children:j(a.long_description)})})})]})}),(0,U.jsx)(s.Ay,{container:!0,spacing:2,mt:2,children:(0,U.jsxs)(s.Ay,{item:!0,md:12,sm:12,xs:12,bgcolor:A.palette.background.box,borderRadius:"10px",width:"100%",children:[(0,U.jsx)(n.A,{variant:"body1",sx:{font:"normal normal bold 24px/32px 'Plus Jakarta Sans'",color:A.palette.color.textColor,textAlign:"left",letterSpacing:"0px",opacity:1,marginBottom:"30px",wordBreak:"break-word"},children:(0,h.t)("contact")}),(0,U.jsx)(s.Ay,{item:!0,md:12,sm:12,xm:12,mb:3,children:(0,U.jsx)("div",{style:{margin:"1em",marginLeft:"0em"},children:(0,U.jsx)(Fe.A,{onSelectLocation:e=>e,apiKey:Ne.cu,isLocationPass:!0,locationlat:parseFloat(o),locationlng:parseFloat(l)})})}),(0,U.jsxs)(s.Ay,{item:!0,md:12,mb:2,children:[(0,U.jsx)(n.A,{style:{font:"var(--unnamed-font-style-normal) normal var(--unnamed-font-weight-normal) 20px/var(--unnamed-line-spacing-32) var(--unnamed-font-family-plus-jakarta-sans)",color:"var(--secondary-color-343f53)",textAlign:"left",letterSpacing:"0px",opacity:1,fontSize:"24px",marginBottom:2,wordBreak:"break-word"},children:a.company_name}),(0,U.jsxs)(n.A,{style:{font:"var(--unnamed-font-style-normal) normal var(--unnamed-font-weight-normal) 20px/var(--unnamed-line-spacing-32) var(--unnamed-font-family-plus-jakarta-sans)",color:"var(--secondary-color-343f53)",textAlign:"left",letterSpacing:"0px",opacity:1,marginTop:10,fontSize:"20px",wordBreak:"break-word"},children:[(0,U.jsx)(Se.sIY,{color:"#2560FC "})," ","   ","  "," ",a.address]})]})]})})]})};var Be=r(35475),Pe=r(58644);const We=e=>{let{children:t}=e;return(0,U.jsx)(n.A,{variant:"body1",sx:{textTransform:"capitalize",fontWeight:"600"},children:t})},Me=()=>{const e=(0,u.A)(),[t,r]=(0,m.useState)([]),[v,j]=(0,m.useState)([]),[A,f]=(0,m.useState)(!1),[y,b]=(0,m.useState)(0),[_]=(0,m.useState)(10),[k,C]=(0,m.useState)(!0),[w,S]=(0,m.useState)(!1),I=(0,E.d4)((e=>e.Location)),F=(0,p.g)(),{partner_id:N}=F,{company_name:R}=F,[z,B]=m.useState("1"),W=async e=>{try{var t;const n=await x.A.allServices({partner_id:N,company_name:R,latitude:I.lat,longitude:I.lng,offset:e.toString(),limit:_.toString()});r((e=>[...e,...n.data])),C((null===n||void 0===n||null===(t=n.data)||void 0===t?void 0:t.length)===_),f(!0)}catch(n){f(!0),console.error("Error fetching data:",n)}};(0,m.useEffect)((()=>{W(0);(async()=>{try{const e=await x.A.get_providers({latitude:I.lat,longitude:I.lng,id:N});j(e.data),S(!0)}catch(e){console.error("Error fetching providers:",e),S(!0)}})()}),[N,R,I.lat,I.lng]),(0,m.useEffect)((()=>{document.title=`${R} Services | HausMate`}),[R]);return(0,U.jsx)(g.A,{children:(0,U.jsxs)(U.Fragment,{children:[(0,U.jsx)(i.A,{sx:{},paddingTop:"0px",paddingBottom:"44px",my:1,children:(0,U.jsxs)(a.A,{maxWidth:"lg",className:"mainContainer",children:[(0,U.jsxs)(o.A,{sx:{paddingTop:"30px"},separator:"|","aria-label":"breadcrumb",className:"mt-2 mb-1",children:[(0,U.jsx)(n.A,{component:Be.N_,to:"/",className:"breadcrumb",sx:{color:e.palette.color.breadcrum},children:(0,U.jsx)("strong",{children:(0,h.t)("home")})}),(0,U.jsx)(n.A,{component:Be.N_,to:"/providers",className:"breadcrumb",sx:{color:e.palette.color.breadcrum},children:(0,U.jsx)("strong",{children:(0,h.t)("Provider")})}),(0,U.jsx)(n.A,{component:Be.N_,to:"/providers",className:"breadcrumb",sx:{color:e.palette.color.breadcrum},children:(0,U.jsxs)("strong",{children:[" ",(0,h.t)("provider_services")]})})]}),w?(0,U.jsx)(U.Fragment,{children:v.map((e=>(0,U.jsx)(n.A,{variant:"h4",gutterBottom:!0,children:(0,U.jsx)("strong",{children:e.company_name})},e.partner_id)))}):(0,U.jsx)(l.A,{width:200,height:50})]})}),(0,U.jsx)(a.A,{maxWidth:"lg",className:"mainContainer",children:(0,U.jsx)(s.Ay,{container:!0,spacing:2,className:"mainContainer",children:(0,U.jsx)(s.Ay,{item:!0,xs:12,children:(0,U.jsx)(i.A,{children:w?(0,U.jsx)(U.Fragment,{children:v.map((e=>{const t=e.partner_id;return(0,U.jsx)(_e,{partnerID:t,partner:e,provider:v,isProvierLoading:w},t)}))}):(0,U.jsxs)(i.A,{display:"flex",flexDirection:"column",gap:3,children:[(0,U.jsx)(l.A,{variant:"rectangular",height:"288px"}),(0,U.jsx)(l.A,{variant:"rectangular",height:"50px"}),(0,U.jsx)(l.A,{variant:"rectangular",height:"800px"}),(0,U.jsx)(l.A,{variant:"rectangular",height:"500px"})]})})})})}),(0,U.jsx)(a.A,{maxWidth:"lg",className:"mainContainer",children:(0,U.jsx)(s.Ay,{container:!0,spacing:2,sx:{borderRadius:"10px"},children:(0,U.jsx)(s.Ay,{item:!0,xs:12,children:(0,U.jsx)(i.A,{sx:{mt:2},children:(0,U.jsxs)(ee.Ay,{value:z,children:[(0,U.jsx)(i.A,{sx:{borderBottom:1,borderColor:"divider"},children:(0,U.jsxs)(te.A,{onChange:(e,t)=>{B(t)},"aria-label":"lab API tabs example",className:"provider-tab",children:[(0,U.jsx)(X.A,{value:"1",label:(0,U.jsx)(We,{sx:{fontWeight:"bold"},children:(0,h.t)("services")})}),(0,U.jsx)(X.A,{value:"2",label:(0,U.jsx)(We,{children:(0,h.t)("reviews")})}),(0,U.jsx)(X.A,{value:"3",label:(0,U.jsx)(We,{children:(0,h.t)("promocodes")})}),(0,U.jsx)(X.A,{value:"4",label:(0,U.jsx)(We,{children:(0,h.t)("about_us")})})]})}),(0,U.jsxs)(re.A,{value:"1",sx:{px:0,py:0,background:e.palette.background.box,marginTop:2,mb:2,borderRadius:"10px"},children:[(0,U.jsx)(n.A,{variant:"h5",fontWeight:"bold",py:2,px:4,children:(0,h.t)("our_services")}),(0,U.jsx)(d.A,{}),(0,U.jsx)(i.A,{mt:1,px:3,children:A?t&&0===(null===t||void 0===t?void 0:t.length)?(0,U.jsxs)(U.Fragment,{children:[(0,U.jsx)(i.A,{maxWidth:"100%",maxHeight:"100%",alignItems:"center",textAlign:"center",children:(0,U.jsx)("img",{src:Pe,style:{maxWidth:"100%"},width:"400",alt:"no service",onError:P.jM})}),(0,U.jsx)(i.A,{alignItems:"center",textAlign:"center",children:(0,U.jsx)(n.A,{children:(0,h.t)("no_service")})})]}):(0,U.jsxs)(i.A,{children:[t&&t.map((e=>(0,U.jsx)(Z,{service:e,provider:v,partner_id:N},e.id))),(0,U.jsx)(i.A,{sx:{display:"flex",justifyContent:"center"},children:k&&A&&(0,U.jsx)(c.A,{variant:"contained",disableElevation:!0,size:"small",onClick:async()=>{const e=y+_;b(e),await W(e)},sx:{margin:"20px auto"},children:(0,h.t)("load_more")})})]}):(0,U.jsxs)(i.A,{children:[(0,U.jsx)(K.Hy,{}),(0,U.jsx)(K.Hy,{}),(0,U.jsx)(K.Hy,{}),(0,U.jsx)(K.Hy,{}),(0,U.jsx)(K.Hy,{}),(0,U.jsx)(K.Hy,{})]})})]}),(0,U.jsx)(re.A,{value:"2",sx:{borderRadius:"10px",mt:2},children:(0,U.jsx)(se,{isProvierLoading:w,provider:v,partner_id:N})}),(0,U.jsx)(re.A,{value:"3",sx:{marginTop:"0em",width:"100%",p:{xs:0,md:3},borderRadius:"10px"},children:(0,U.jsx)(we,{partner_id:N})}),(0,U.jsx)(re.A,{value:"4",sx:{p:2,pr:1,borderRadius:"10px",mt:2},children:(0,U.jsx)(i.A,{children:w&&v.map(((e,t)=>{const r=e;return(0,U.jsx)(Ee,{data:r},t)}))})})]})})})})})]})})}},48729:(e,t,r)=>{r.d(t,{A:()=>c});var n=r(65043),i=r(22963),a=r.n(i),o=r(77548),l=r(46941),s=r(19540),d=r(70579);a().setAppElement("#root");const c=e=>{var t;let{urls:r}=e;const[i,a]=(0,n.useState)(!1),[c,x]=(0,n.useState)(0),[m,p]=(0,n.useState)(!1),[h,g]=(0,n.useState)(""),u=null===r||void 0===r||null===(t=r.filter((e=>(0,l.Ir)(e)===l.id.IMAGE)))||void 0===t?void 0:t.map((e=>({src:e})));return(0,d.jsxs)("div",{className:"main-lightbox",children:[(0,d.jsx)("div",{className:"all-images",children:(()=>{try{return r.map(((e,t)=>{const r=(0,l.Ir)(e);return(0,d.jsx)("div",{onClick:()=>((e,t,r)=>{try{t===l.id.IMAGE?(x(r),a(!0)):t===l.id.VIDEO&&(g(e),p(!0))}catch(n){console.error("Error handling click:",n)}})(e,r,t),className:"parent_div",children:r===l.id.IMAGE?(0,d.jsx)("img",{src:e,alt:"work evidence",onError:l.jM}):(0,d.jsx)("video",{className:"video_data",src:e})},t)}))}catch(e){return console.error("Error rendering URLs:",e),null}})()}),i&&(0,d.jsx)(d.Fragment,{children:(0,d.jsx)(s.A,{lightboxOpen:i,currentImages:u,currentImageIndex:c,handleCloseLightbox:()=>a(!1),gotoNext:()=>x((e=>(e+1)%(null===u||void 0===u?void 0:u.length))),gotoPrevious:()=>{const e=(c+(null===u||void 0===u?void 0:u.length)-1)%(null===u||void 0===u?void 0:u.length);x(e)}})}),m&&(0,d.jsx)(o.A,{isOpen:m,videoUrl:h,onClose:()=>p(!1)})]})}},77548:(e,t,r)=>{r.d(t,{A:()=>c});var n=r(49788),i=r(44978),a=r(65043),o=r(85369),l=r(22963),s=r.n(l),d=r(70579);const c=e=>{let{isOpen:t,videoUrl:r,onClose:l}=e;const c=(0,a.useRef)(null);return(0,a.useEffect)((()=>{if(t&&c.current){const e=c.current;if(n.Ay.isSupported()){const t=new n.Ay;t.loadSource(r),t.attachMedia(e),t.on(n.Ay.Events.MANIFEST_PARSED,(()=>{e.play()}))}else e.canPlayType("application/vnd.apple.mpegurl")&&(e.src=r,e.addEventListener("loadedmetadata",(()=>{e.play()})))}}),[t,r]),(0,d.jsx)(s(),{isOpen:t,onRequestClose:l,contentLabel:"Video Modal",children:(0,d.jsxs)("div",{className:"video_parent",children:[(0,d.jsxs)("video",{ref:c,controls:!0,className:"video_controls",children:[(0,d.jsx)("source",{src:r,type:"video/mp4"}),(0,d.jsx)("source",{src:r,type:"video/webm"}),(0,d.jsx)("source",{src:r,type:"video/ogg"}),(0,d.jsx)("source",{src:r,type:"video/3gpp"}),(0,d.jsx)("source",{src:r,type:"video/x-msvideo"}),(0,d.jsx)("source",{src:r,type:"video/x-matroska"}),(0,d.jsx)("source",{src:r,type:"video/quicktime"}),(0,d.jsx)("source",{src:r,type:"video/x-flv"}),(0,i.t)("browser_not_support_tag")]}),(0,d.jsxs)("button",{onClick:l,className:"close_button",children:[" ",(0,d.jsx)(o.QCr,{})]})]})})}}}]);
//# sourceMappingURL=373.bd1a8d6b.chunk.js.map