1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[73360],{31915:function(e,t,a){"use strict";var l=a(57437);a(2265);var n=a(30938);t.Z=e=>{let{viewBox:t="0 0 16 16",stroke:a}=e;return a=a||"var(--secondary-main)",(0,l.jsx)(n.Z,{viewBox:t,style:{width:"16px",height:"16px"},children:(0,l.jsxs)("svg",{width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[(0,l.jsx)("path",{d:"M3.5 11.5C3.5 12.5609 3.92143 13.5783 4.67157 14.3284C5.42172 15.0786 6.43913 15.5 7.5 15.5",stroke:a,strokeLinecap:"round",strokeLinejoin:"round"}),(0,l.jsx)("path",{d:"M3.5 8.5C5.5 6.27067 6.5 4.604 6.5 3.5C6.5 2.70435 6.18393 1.94129 5.62132 1.37868C5.05871 0.81607 4.29565 0.5 3.5 0.5C2.70435 0.5 1.94129 0.81607 1.37868 1.37868C0.81607 1.94129 0.5 2.70435 0.5 3.5C0.5 4.60533 1.5 6.272 3.5 8.5Z",stroke:a,strokeLinecap:"round",strokeLinejoin:"round"}),(0,l.jsx)("path",{d:"M11.5 10C12.3284 10 13 9.32843 13 8.5C13 7.67157 12.3284 7 11.5 7C10.6716 7 10 7.67157 10 8.5C10 9.32843 10.6716 10 11.5 10Z",fill:a}),(0,l.jsx)("path",{d:"M3.5 4.5C4.05228 4.5 4.5 4.05228 4.5 3.5C4.5 2.94772 4.05228 2.5 3.5 2.5C2.94772 2.5 2.5 2.94772 2.5 3.5C2.5 4.05228 2.94772 4.5 3.5 4.5Z",fill:a}),(0,l.jsx)("path",{d:"M11.5 15C14.1667 12.14 15.5 9.97333 15.5 8.5C15.5 7.43913 15.0786 6.42172 14.3284 5.67157C13.5783 4.92143 12.5609 4.5 11.5 4.5C10.4391 4.5 9.42172 4.92143 8.67157 5.67157C7.92143 6.42172 7.5 7.43913 7.5 8.5C7.5 9.97333 8.83333 12.14 11.5 15Z",stroke:a,strokeLinecap:"round",strokeLinejoin:"round"})]})})}},73360:function(e,t,a){"use strict";a.d(t,{default:function(){return z}});var l=a(57437);a(60850),a(66548),a(78362);var n=a(35389),i=a(46387),o=a(94013),s=a(62069),r=a(12713),d=a(38266),c=a(99376),u=a(2265),m=a(60032),g=a(73247),p=a(32489),v=a(83774),h=a(75526),y=a(31915),f=a(91964),b=a(74416);let x={width:"100%",height:"100%"},j=["places"];var C=u.memo(e=>{let[t,a]=(0,u.useState)(!1),{isLoaded:n}=(0,f.Ji)({googleMapsApiKey:e.googleApiKey||"",libraries:j}),[i,o]=u.useState(null),s=(0,u.useRef)(!1),[r,d]=(0,u.useState)(15),c=u.useCallback(function(t){let a=new window.google.maps.LatLngBounds(e.mapPosition);t.fitBounds(a),o(t),setTimeout(()=>{d(16)},300)},[e.mapPosition.lat,e.mapPosition.lng]),m=u.useCallback(function(){o(null)},[]);return(0,l.jsx)(l.Fragment,{children:n?(0,l.jsxs)(f.b6,{mapContainerStyle:x,center:e.mapPosition,zoom:r,onLoad:c,onUnmount:m,options:{zoomControl:!b.Sr,streetViewControl:!1,gestureHandling:"cooperative"},onDragStart:()=>a(!0),onDragEnd:()=>{var t,l;e.setMapPosition({lat:(null==i?void 0:null===(t=i.center)||void 0===t?void 0:t.lat())||e.defaultPosition.lat,lng:(null==i?void 0:null===(l=i.center)||void 0===l?void 0:l.lng())||e.defaultPosition.lng}),a(!1)},onZoomChanged:()=>{if(s.current){var t,a;e.setMapPosition({lat:(null==i?void 0:null===(t=i.center)||void 0===t?void 0:t.lat())||e.defaultPosition.lat,lng:(null==i?void 0:null===(a=i.center)||void 0===a?void 0:a.lng())||e.defaultPosition.lng})}else s.current=!0},children:[(0,l.jsx)(f.Jx,{position:e.mapPosition,draggable:!0,onDragEnd:t=>{e.setMapPosition({lat:t.latLng.lat()||e.defaultPosition.lat,lng:t.latLng.lng()||e.defaultPosition.lng})},icon:{url:"https://img.clevup.in/static/web-store/default-marker.png",scaledSize:new window.google.maps.Size(26,37)},visible:!t}),(0,l.jsx)("img",{className:"map-widget-marker",style:t?{opacity:"1",visibility:"visible"}:{opacity:"0",visibility:"hidden"},src:"https://img.clevup.in/static/web-store/default-marker.png",width:"26px",height:"37px",alt:"marker"}),(0,l.jsx)("button",{type:"button",className:"map-widget-current-location",onClick:e.getCurrentLocation,children:(0,l.jsx)("svg",{width:"20",height:"20",viewBox:"0 0 20 20",xmlns:"http://www.w3.org/2000/svg",children:(0,l.jsx)("path",{d:"M10 6.36364C7.99091 6.36364 6.36364 7.99091 6.36364 10C6.36364 12.0091 7.99091 13.6364 10 13.6364C12.0091 13.6364 13.6364 12.0091 13.6364 10C13.6364 7.99091 12.0091 6.36364 10 6.36364ZM18.1273 9.09091C17.7091 5.3 14.7 2.29091 10.9091 1.87273V0H9.09091V1.87273C5.3 2.29091 2.29091 5.3 1.87273 9.09091H0V10.9091H1.87273C2.29091 14.7 5.3 17.7091 9.09091 18.1273V20H10.9091V18.1273C14.7 17.7091 17.7091 14.7 18.1273 10.9091H20V9.09091H18.1273ZM10 16.3636C6.48182 16.3636 3.63636 13.5182 3.63636 10C3.63636 6.48182 6.48182 3.63636 10 3.63636C13.5182 3.63636 16.3636 6.48182 16.3636 10C16.3636 13.5182 13.5182 16.3636 10 16.3636Z",fill:"currentColor"})})})]}):(0,l.jsx)("div",{style:{height:"100%"}})})}),w=a(4571),N=a(37231),P=a(39919),_=a(9397),k=a(77382),S=a(90381),Z=a(69111),L=a(49245),I=a(96650),F=a(75449),E=a(25472),M=a(57886),A=a(98236),B=a(69016),z=e=>{var t,a,f;let{noLayout:x,closeModal:j,onlyAddressData:z,isEditMapAddress:D,orgStore:O,changeTab:H}=e,T=(0,c.useSearchParams)().get("redirectUrl"),J=(0,b.W7)(O),K=(0,I.r2)(),R=(0,u.useMemo)(()=>(0,B.pO)(O.country_code),[O.country_code]),V=R.postalCodeLength>0,W=(0,m.v9)(e=>e.address),q=(0,m.v9)(e=>e.customer.customer),U=(0,m.v9)(e=>e.cart.cart),X=O.settings,Y=null!==(f=null==X?void 0:X.address_mode)&&void 0!==f?f:"FORM_MAP",$=W.loader,G=null==O?void 0:null===(a=O.attributes)||void 0===a?void 0:null===(t=a.site_settings)||void 0===t?void 0:t.map_api_key,Q=!!G,ee={lat:O.lat||12.97,lng:O.lng||77.5946},[et,ea]=(0,u.useState)(null),[el,en]=(0,u.useState)(!1),[ei,eo]=(0,u.useState)(null),[es,er]=(0,u.useState)(!1),[ed,ec]=(0,u.useState)(""),[eu,em]=(0,u.useState)(null),[eg,ep]=(0,u.useState)(""),[ev,eh]=(0,u.useState)([]),[ey,ef]=(0,u.useState)(!1),[eb,ex]=(0,u.useState)("idle"),ej=(0,u.useRef)(null),eC=(0,m.I0)(),ew=(0,c.useRouter)(),eN=(0,u.useMemo)(()=>(0,E.ZR)(O),[O]),[eP,e_]=(0,u.useState)({name:{value:"",error:!1,errmsg:"Please enter name"},mobile:{value:"",error:!1,errmsg:"Invalid mobile number"},flat_number:"",landmark:"",formatedaddress:"",locality:"",street1:"",street2:"",city:"",state:"",pincode:"",country:"",lat:null,lng:null,countryInfo:""});(0,u.useEffect)(()=>
1{if(D&&(0,L.YX)("".concat(O.id,"_map_address"))){var e;let t=JSON.parse((0,L.YX)("".concat(O.id,"_map_address"))),a="object"==typeof t.mobile?(null===(e=t.mobile)||void 0===e?void 0:e.value)||"":t.mobile||"";a&&!(0,F.DD)(a,eN)&&(t.countryInfo="",t.mobile="object"==typeof t.mobile?{...t.mobile,value:""}:""),e_(t);let l=null!=t.lat?Number(t.lat):NaN,n=null!=t.lng?Number(t.lng):NaN;if(Number.isFinite(l)&&Number.isFinite(n)){ea({lat:l,lng:n});return}en(!0),eo(null),navigator.geolocation.getCurrentPosition(e=>{ea({lat:e.coords.latitude,lng:e.coords.longitude}),en(!1),eo(null)},e=>{en(!1),eo(1===e.code?"Location blocked. Enable it in browser settings and try again.":2===e.code?"Location unavailable.":3===e.code?"Location request timed out.":"Unable to get location.")},{enableHighAccuracy:!0});return}let t=(null==O?void 0:O.id)&&((0,L.YX)("".concat(O.id,"_address"))||(0,L.Jt)("".concat(O.id,"_address")));if(t)try{let e=JSON.parse(t),a=null!=e.lat?Number(e.lat):NaN,l=null!=e.lng?Number(e.lng):NaN;if(Number.isFinite(a)&&Number.isFinite(l)){ea({lat:a,lng:l});return}}catch(e){}en(!0),eo(null),navigator.geolocation.getCurrentPosition(e=>{ea({lat:e.coords.latitude,lng:e.coords.longitude}),en(!1),eo(null)},e=>{en(!1),eo(1===e.code?"Location blocked. Enable it in browser settings and try again.":2===e.code?"Location unavailable.":3===e.code?"Location request timed out.":"Unable to get location.")},{enableHighAccuracy:!0})},[]),(0,u.useEffect)(()=>{var e,t,a,l,n,i;let o=null!==(t=null!==(e=null==q?void 0:q.name)&&void 0!==e?e:null==U?void 0:U.customer_name)&&void 0!==t?t:"",s=null!==(l=null!==(a=null==q?void 0:q.mobile)&&void 0!==a?a:null==U?void 0:U.customer_mobile)&&void 0!==l?l:"",r="",d="";if(null==O?void 0:O.id){let e=(0,L.YX)("".concat(O.id,"_address"))||(0,L.Jt)("".concat(O.id,"_address"));if(e)try{let t=JSON.parse(e);r=null!==(n=t.customer_name)&&void 0!==n?n:"",d=null!==(i=t.mobile)&&void 0!==i?i:""}catch(e){}}let c=r||o,u=d||s;(c||u)&&e_(e=>({...e,name:{...e.name,value:e.name.value||c,error:!1},mobile:{...e.mobile,value:e.mobile.value||u,error:!1}}))},[]),(0,u.useEffect)(()=>{if(!O)return;let e=(0,h.RA)(O.id,k.JO),t=G||e;em(t),d.Z.setApiKey(t),d.Z.enableDebug(),d.Z.setLanguage(R.languageCode),d.Z.setRegion(R.regionCode)},[O,G]),(0,u.useEffect)(()=>{var e,t,a,l;if(!Q||!G)return;let n=()=>{var e,t;(null===(t=window.google)||void 0===t?void 0:null===(e=t.maps)||void 0===e?void 0:e.places)&&!ej.current&&(ej.current=new window.google.maps.places.AutocompleteService)};if(null===(t=window.google)||void 0===t?void 0:null===(e=t.maps)||void 0===e?void 0:e.places)n();else{let e=document.querySelector('script[src*="maps.googleapis.com"]');if(e)(null===(l=window.google)||void 0===l?void 0:null===(a=l.maps)||void 0===a?void 0:a.places)?n():e.addEventListener("load",n);else{let e=document.createElement("script");e.src="https://maps.googleapis.com/maps/api/js?key=".concat(G,"&libraries=places"),e.async=!0,e.defer=!0,e.onload=n,document.head.appendChild(e)}}return()=>{ej.current=null}},[Q,G]),(0,u.useEffect)(()=>{let e=eg.trim();if(!e||e.length<5){eh([]),ef(!1);return}if(!ej.current)return;ef(!0);let t=setTimeout(()=>{ej.current?ej.current.getPlacePredictions({input:e,componentRestrictions:{country:R.regionCode},types:["geocode"]},(e,t)=>{ef(!1),t===window.google.maps.places.PlacesServiceStatus.OK&&e?eh(e):eh([])}):ef(!1)},500);return()=>clearTimeout(t)},[eg]);let ek=e=>{var t,a;e.place_id&&(null===(a=window.google)||void 0===a?void 0:null===(t=a.maps)||void 0===t?void 0:t.places)&&new window.google.maps.places.PlacesService(document.createElement("div")).getDetails({placeId:e.place_id,fields:["geometry"]},(e,t)=>{var a;if(t===window.google.maps.places.PlacesServiceStatus.OK&&(null==e?void 0:null===(a=e.geometry)||void 0===a?void 0:a.location)){let t=e.geometry.location;ea({lat:"function"==typeof t.lat?t.lat():t.lat,lng:"function"==typeof t.lng?t.lng():t.lng}),eo(null),ep(""),eh([])}})},eS=e=>{ex("idle"),er(!0),ec(e||"We couldn't find a proper address here. Please drag the pin to a nearby location and try again."),e_(e=>({...e,flat_number:"",landmark:"",formatedaddress:"",locality:"",street1:"",street2:"",city:"",state:"",pincode:"",country:"",countryInfo:""}))},eZ=(e,t)=>{d.Z.fromLatLng(e,t).then(a=>{er(!1),ec(""),eI(a,e,t)}).catch(()=>{eS()})};(0,u.useEffect)(()=>{et&&eZ(et.lat,et.lng)},[null==et?void 0:et.lat,null==et?void 0:et.lng]),(0,u.useEffect)(()=>
1{if(!(O&&(!V||eP.pincode)&&null!=eP.lat&&null!=eP.lng&&Number.isFinite(Number(eP.lat))&&Number.isFinite(Number(eP.lng)))){ex("idle");return}let e=!1;return ex("checking"),(0,I.KB)(O,{lat:eP.lat,lng:eP.lng,...eP.pincode&&{pincode:eP.pincode},...eP.city&&{city:eP.city},...eP.street1&&{street1:eP.street1},...eP.state&&{state:eP.state}}).then(t=>{var a;e||ex(t&&(null==t?void 0:null===(a=t.info)||void 0===a?void 0:a.unavailable)!==!0&&((null==t?void 0:t.status)==null||"ACTIVE"===t.status)?"available":"unavailable")}).catch(()=>{e||ex("unavailable")}),()=>{e=!0}},[eP.pincode,eP.lat,eP.lng,O]);let eL=()=>{en(!0),eo(null),navigator.geolocation.getCurrentPosition(e=>{ea({lat:e.coords.latitude,lng:e.coords.longitude}),en(!1),eo(null)},e=>{en(!1),eo(1===e.code?"Location blocked. Enable it in browser settings and try again.":2===e.code?"Location unavailable.":3===e.code?"Location request timed out.":"Unable to get location.")},{enableHighAccuracy:!0})},eI=(e,t,a)=>{let{found:l,address_fields:n,street:i,premise:o,formated_address:s,locality:r}=(0,h.tw)(e),d=n.city&&"unnamed"!==n.city.toLowerCase(),c=!!n.pincode;(V?l&&d&&c:l)?e_(e=>({...e,locality:r,formatedaddress:o?(0,h.uF)(s,o):s,city:d?n.city:"",state:n.state,country:n.country,pincode:c?n.pincode:"",street1:i,lat:t,lng:a})):eS("This location doesn't have a valid city or pincode. Please drag the pin to a nearby location and try again.")},eF=(e,t)=>{"name"===e.target.name?!(0,b.av)(e.target.value)||e_({...eP,name:{value:e.target.value}}):"mobile"===e.target.name?e_({...eP,mobile:{value:e.target.value},countryInfo:t}):e_({...eP,[e.target.name]:e.target.value})},eE=e=>{let{name:t,value:a}=e.target;if("mobile"===t){let{isValid:e,errorMessage:t}=(0,A.$L)(a,eP.countryInfo);e_({...eP,mobile:{value:a,error:!e,errmsg:e?"":t}})}else e_({...eP,[t]:{...eP[t],error:""===a.trim()}})},eM=e=>{e_({...eP,[e.target.name]:{...eP[e.target.name],error:!1}})},eA=e=>(e||"").replace(/^[,-.]+|[,-.]+$/g,"").trim(),eB=async e=>{e&&e.preventDefault();let t=null!=eP.lat&&null!=eP.lng&&Number.isFinite(Number(eP.lat))&&Number.isFinite(Number(eP.lng)),a=!!eP.pincode,l=!!eP.city&&"unnamed"!==eP.city.toLowerCase();if(!t||!(!V||a&&l)){er(!0),ec("We couldn't find this location precisely. Please drag the pin to a nearby spot and try again.");return}if(""===eP.name.value.trim()){e_({...eP,name:{value:"",error:!0,errmsg:"Please enter name"}});return}if(""!==eP.mobile.value){let{isValid:e,errorMessage:t}=(0,A.$L)(eP.mobile.value,eP.countryInfo);if(e_({...eP,mobile:{value:eP.mobile.value,error:!e,errmsg:e?"":t}}),!e)return}let n={customer_name:eP.name.value,mobile:(0,A.Sj)(eP.mobile.value),contact_name:eP.name.value,contact_mobile:(0,A.Sj)(eP.mobile.value),apartment:eP.flat_number,street1:eA(eP.street1),street2:eA(eP.street2),landmark:eP.landmark,pincode:eP.pincode,city:eP.city,state:eP.state,lat:eP.lat,lng:eP.lng,country_info:eP.countryInfo};try{var i;let e=await (0,I.KB)(O,{lat:n.lat,lng:n.lng,...n.pincode&&{pincode:n.pincode},...n.city&&{city:n.city},...n.street1&&{street1:n.street1},...n.state&&{state:n.state}});if(!e||(null==e?void 0:null===(i=e.info)||void 0===i?void 0:i.unavailable)===!0||(null==e?void 0:e.status)!=null&&"ACTIVE"!==e.status){er(!0),ec("Delivery is not available for this location. Please choose a different address.");return}}catch(e){er(!0),ec("We couldn't verify delivery for this location. Please try again or choose a different spot.");return}if(z&&j){"MAP"===Y&&(0,L.nz)("".concat(O.id,"_map_address"),JSON.stringify(eP)),j(n);return}let o=O.slug;"true"===(0,L.Jt)("".concat(O.id,"_guest_checkout"))?(0,w.Kg)({orgStore:O,address:n,customer:q}).then(e=>{eC((0,N.Eh)(e)),ew.replace("/cart-review")}):eC((0,_.y$)({addressData:n,slug:o})).then(e=>{if(!$){if(e.payload.payload){let t=e.payload.payload;if(T){ew.replace("/".concat(T,"?addId=").concat(t.id));return}let a=()=>{j?j(t.id):K?ew.replace("/cart-detail".concat(K?"?type=open":"")):ew.replace("/cart-review")};(0,w.Kg)({orgStore:O,address:{...t,contact_name:t.customer_name,contact_mobile:t.mobile,store_id:O.id},customer:q}).then(e=>{eC((0,N.Eh)(e)),a()}).catch(e=>{eC((0,P.OV)({message:(null==e?void 0:e.message)||"Something went wrong. Please try again."})),a()})}e.payload.error&&console.log(e.payload.error)}e.payload.error&&console.log(e.payload.error)})},ez={...J?{}:{height:"400px"},position:"relative",display:"flex",flexDirection:"column"},eD=(0,l.jsxs)(l.Fragment,{children:[(0,l.jsxs)("div",{className:J?"address-map-sm":"address-map-lg",style:ez,children:[Q&&eu&&(0,l.jsxs)("div",{className:"map-widget-search-row",style:{flexShrink:0,position:"relative"},children:[(0,l.jsx)("div",{className:"location-search-row",style:{marginBottom:0},children:(0,l.jsxs)("div",{className:"location-search-wrapper",children:[(0,l.jsx)(g.Z,{size:20,className:"location-search-icon"}),(0,l.jsx)("input",{className:"location-search-input",type:"text",value:eg,onChange:e=>ep(e.target.value),placeholder:"Search for a place",autoComplete:"off"}),eg&&(0,l.jsx)("button",{type:"button",onClick:()=>ep(""),className:"location-search-clear-btn","aria-label":"Clear search",children:(0,l.jsx)(p.Z,{size:14})})]})}),eg.trim().length>0&&(0,l.jsx)("div",{className:"map-widget-suggestions-overlay",children:ey?(0,l.jsx)("div",{className:"location-loading-message",children:"Searching for matching locationsâ¦"}):ev.length>0?(0,l.jsx)("div",{className:"location-suggestions-list map-widget-suggestions-list",children:ev.map((e,t)=>{var a,n;return(0,l.jsxs)("div",{children:[(0,l.jsxs)("div",{role:"button",tabIndex:0,onClick:()=>ek(e),onKeyDown:t=>{("Enter"===t.key||" "===t.key)&&(t.preventDefault(),ek(e))},className:"location-suggestion-item",children:[(0,l.jsx)(v.Z,{size:20}),(0,l.jsxs)("div",{className:"location-suggestion-item-content",children:[(0,l.jsx)("div",{className:"location-suggestion-item-main",children:null!==(n=null===(a=e.structured_formatting)||void 0===a?void 0:a.main_text)&&void 0!==n?n:e.description}),(0,l.jsx)("div",{className:"location-suggestion-item-desc",children:e.description})]})]}),t<ev.length-1&&(0,l.jsx)("div",{className:"location-suggestion-divider"})]},e.place_id||t)})}):eg.trim().length<5?(0,l.jsx)("div",{className:"location-loading-message",children:"Type at least 5 characters to search for a place."}):(0,l.jsx)("div",{className:"location-no-results",children:"No locations foun
1d. Try a different place name."})})]}),(0,l.jsxs)("div",{style:{flex:1,minHeight:0,display:"flex",alignItems:"center",justifyContent:"center",...J&&{margin:"0 -16px"},marginBottom:"8px"},children:[!et&&el&&(0,l.jsxs)("div",{style:{display:"flex",flexDirection:"column",alignItems:"center",gap:12},children:[(0,l.jsx)(n.Z,{size:28,style:{color:"var(--secondary-main)"}}),(0,l.jsx)(i.Z,{color:"textSecondary",children:"Fetching your current addressâ¦"})]}),!et&&ei&&!el&&(0,l.jsxs)("div",{style:{textAlign:"center",padding:16},children:[(0,l.jsx)(i.Z,{color:"error",style:{marginBottom:8},children:ei}),(0,l.jsx)(S.default,{onClick:eL,bold:!0,children:"Try again"})]}),et&&eu&&(0,l.jsx)(C,{mapPosition:et,googleApiKey:eu,setMapPosition:ea,getCurrentLocation:()=>{eL()},defaultPosition:ee})]})]}),(0,l.jsxs)("div",{className:"".concat(J?"address-map-address-sm":"address-map-address-lg"),children:[es&&(0,l.jsxs)("div",{style:{display:"flex",marginBottom:12,alignItems:"center",justifyContent:"space-between",gap:12},children:[(0,l.jsxs)("div",{style:{display:"flex",alignItems:"center",gap:8},children:[(0,l.jsx)("img",{src:"https://img.clevup.in/static/shoopy-app/undraw_into_the_night_vumi.png",style:{width:56,height:56,objectFit:"contain"},alt:""}),(0,l.jsx)(i.Z,{className:"address-map-locality",children:ed||"Oops! No Address Found."})]}),Object.keys(q).length>0&&(0,l.jsx)(o.Z,{color:"secondary",style:{fontWeight:700,fontSize:14,border:"1px solid ".concat(X&&X.theme_color?X.theme_color:b.bL),borderRadius:6,padding:"7px 15px"},onClick:()=>{H?H():((0,L.nz)("address",JSON.stringify(eP)),ew.push("/account/address-form"))},children:"Fill Manually"})]}),(0,l.jsxs)(u.Fragment,{children:[(0,l.jsx)("div",{style:{display:"flex",marginBottom:8,alignItems:"center",justifyContent:"space-between"},children:(0,l.jsxs)("div",{style:{display:"flex"},children:[(0,l.jsx)(y.Z,{}),(0,l.jsx)(i.Z,{className:"address-map-locality",children:eP.locality})]})}),(0,l.jsx)(i.Z,{className:"address-map-formated-address",children:eP.formatedaddress}),"idle"!==eb&&(0,l.jsxs)("div",{style:{display:"flex",alignItems:"center",gap:8,marginTop:12,marginBottom:4},children:["checking"===eb&&(0,l.jsxs)(l.Fragment,{children:[(0,l.jsx)(n.Z,{size:18,sx:{color:"var(--secondary-main)"}}),(0,l.jsx)(i.Z,{variant:"body2",color:"textSecondary",children:"Checking delivery availability"})]}),"available"===eb&&(0,l.jsx)(i.Z,{variant:"body2",sx:{color:"#2e7d32",fontWeight:500},children:"Delivery available"}),"unavailable"===eb&&(0,l.jsx)(i.Z,{variant:"body2",color:"error",children:"Delivery not available for this location."})]}),(0,l.jsx)("div",{style:{width:"100%",margin:"20px 0px"},children:(0,l.jsxs)(s.ZP,{container:!0,spacing:3,children:[(0,l.jsx)(s.ZP,{item:!0,xs:12,sm:6,children:(0,l.jsx)(r.Z,{variant:"outlined",size:"small",required:!0,fullWidth:!0,label:"Name",color:"secondary",name:"name",error:eP.name.error,helperText:eP.name.error?eP.name.errmsg:"",onChange:eF,onBlur:eE,onFocus:eM,value:eP.name.value,InputLabelProps:{className:"address-map-input-label"},inputProps:{maxLength:64,className:"address-map-input"},InputProps:{className:"address-map-inputfield universal-input"}})}),(0,l.jsx)(s.ZP,{item:!0,xs:12,sm:6,children:(0,l.jsx)(M.Z,{label:"Mobile Number",country:(0,E.Bw)(O),onlyCountries:eN,value:eP.mobile.value,onChange:(e,t)=>
1{eF(e,t)},onFocus:e=>eM(e),onBlur:e=>eE(e),error:eP.mobile.error,helperText:eP.mobile.error?"Invalid Phone Number":"",inputProps:{name:"mobile",autoFocus:!1}})}),(0,l.jsx)(s.ZP,{item:!0,xs:12,sm:6,children:(0,l.jsx)(r.Z,{variant:"outlined",size:"small",fullWidth:!0,label:"House/Flat No.",color:"secondary",name:"flat_number",onChange:eF,value:eP.flat_number,InputLabelProps:{className:"address-map-input-label"},inputProps:{className:"address-map-input"},InputProps:{className:"address-map-inputfield universal-input"}})}),(0,l.jsx)(s.ZP,{item:!0,xs:12,sm:6,children:(0,l.jsx)(r.Z,{variant:"outlined",size:"small",fullWidth:!0,label:"Landmark",color:"secondary",name:"landmark",onChange:eF,value:eP.landmark,InputLabelProps:{className:"address-map-input-label"},inputProps:{className:"address-map-input"},InputProps:{className:"address-map-inputfield universal-input"}})})]})}),x&&(0,l.jsxs)("div",{className:"address-map-btn-container",children:[(0,l.jsx)(S.default,{style:{width:"28%",marginRight:12},onClick:()=>j(),bold:!0,children:"Cancel"}),(0,l.jsx)(Z.default,{style:{width:"28%",marginLeft:12},onClick:eB,bold:!0,children:"Save"})]}),!x&&(0,l.jsx)("div",{style:{display:"flex",alignItems:"center",justifyContent:"center",...J&&{position:"sticky",bottom:0,padding:"16px",margin:"-16px",background:"#ffffff"}},children:(0,l.jsx)(Z.default,{bold:!0,fullWidth:!0,onClick:eB,loading:$,children:"Save Address"})})]})]})]});return(0,l.jsx)(u.Fragment,{children:eD})}},66548:function(){},78362:function(){},60850:function(){}}]);
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.