1"use strict";(self.webpackChunk=self.webpackChunk||[]).push([[3535],{3535(e,n,s){s.d(n,{A:()=>i});var o=s(14405),a=s(19061),l=s(36977),t=s(93183),r=s(55431);function d({MarkerComponent:e,coordinates:n,address:s,onConfirm:o,onClose:l}){return o&&n?(0,a.jsx)(e,{coordinates:n,children:(0,a.jsxs)("div",{className:"address-map-popup",children:[(0,a.jsx)("strong",{className:"address-map-popup_address",children:s}),(0,a.jsx)("div",{className:"delivery-office-popup__chooser",children:(0,a.jsx)("button",{type:"button",className:"link-styled link-styled_underline_dashed",onClick:o,children:"ÐÑбÑаÑÑ Ð°Ð´ÑеÑ"})}),(0,a.jsx)("button",{"aria-label":"close",className:"address-map-popup_close",type:"button",onClick:l})]})}):null}function i({onChange:e,onClose:n,geo:s,address:i}){const[c,u,p]=function(e,n){const[s,a]=(0,l.useState)(null),[t,d]=(0,l.useState)(null),[i,c]=(0,l.useState)(!0);function u(){return(0,o._)(function*(){try{const n=yield r.A.getInstance().getGeoCoordinatesById(e.id);a({center:[n.lon,n.lat],zoom:13})}catch(e){a({center:[131.941412,43.090009],zoom:13})}})()}return(0,l.useEffect)(()=>{(0,o._)(function*(){n.length>0?yield(0,o._)(function*(){try{const s=yield r.A.getInstance().findLandmarks(n,e.geoCoderName),o=null==s?void 0:s.landmarks[0];null!=(null==o?void 0:o.lon)&&null!=(null==o?void 0:o.lat)?(d([o.lon,o.lat]),a({center:[o.lon,o.lat],zoom:16})):yield u()}catch(e){yield u()}})():yield u(),c(!1)})()},[]),[s,t,i]}(s,i),[m,f]=(0,l.useState)(null),[h,x]=(0,l.useState)(null),{YMap:j,YMapDefaultSchemeLayer:y,YMapDefaultFeaturesLayer:C,YMapControls:g,YMapMarker:k,YMapListener:v,YMapZoomControl:M,YMapGeolocationControl:_,reactify:N,isLoaded:Y}=(0,t.zL)();return Y&&!p&&c?(0,a.jsx)("div",{className:"address-map-wrapper",children:(0,a.jsxs)(j,{location:N.useDefault(c),zoomRange:{min:8,max:17},zoomRounding:"smooth",margin:[20,20,20,20],children:[(0,a.jsx)(y,{}),(0,a.jsx)(C,{}),(0,a.jsxs)(g,{position:"right",children:[(0,a.jsx)(M,{}),(0,a.jsx)(_,{easing:"ease-in-out",duration:500,zoom:17})]}),(0,a.jsx)(v,{onClick:(n,s)=>(0,o._)(function*(){if(!e)return;if("hotspot"!==(null==n?void 0:n.type))return;const o=s.coordinates,a=yield r.A.getInstance().reverseRequest(o);(null==a?void 0:a.address)&&(f(o),x(a.address))})()}),u&&(0,a.jsx)(k,{coordinates:u,children:(0,a.jsx)("div",{className:"map-pin"})}),(0,a.jsx)(d,{MarkerComponent:k,coordinates:m,address:h,onConfirm:e?()=>{e(h),f(null),x(null),n()}:null,onClose:()=>{f(null),x(null)}})]})}):(0,a.jsx)("div",{className:"address-map-wrapper address-map-wrapper_loading",children:(0,a.jsx)(t.aH,{})})}}}]); 2//# sourceMappingURL=/resources/source-maps/3535.d55ebf77ee3bfed22d1f.js.map
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.