"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[9759],{99072:(t,e,s)=>{s.d(e,{KD:()=>R,T6:()=>f,pH:()=>te,u6:()=>M});var i,n,o,r,a,h,l=s(37876),p=s(14232),c=s(98477);function u(t){return(u="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}function d(t,e,s){var i;return(i=function(t,e){if("object"!=u(t)||!t)return t;var s=t[Symbol.toPrimitive];if(void 0!==s){var i=s.call(t,e||"default");if("object"!=u(i))return i;throw TypeError("@@toPrimitive must return a primitive value.")}return("string"===e?String:Number)(t)}(e,"string"),(e="symbol"==u(i)?i:i+"")in t)?Object.defineProperty(t,e,{value:s,enumerable:!0,configurable:!0,writable:!0}):t[e]=s,t}function g(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}var m=g(n?i:(n=1,i=function(t,e,s,i,n,o,r,a){0;if(!t){var h;if(void 0===e)h=Error("Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.");else{var l=[s,i,n,o,r,a],p=0;(h=Error(e.replace(/%s/g,function(){return l[p++]}))).name="Invariant Violation"}throw h.framesToPop=1,h}})),v=(0,p.createContext)(null);function f(){m(!!p.useContext,"useGoogleMap is React hook and requires React version 16.8+");var t=(0,p.useContext)(v);return m(!!t,"useGoogleMap needs a GoogleMap available up in the tree"),t}function y(t){google.maps.event.removeListener(t)}function b(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];t.forEach(y)}function x(t){var e,{updaterMap:s,eventMap:i,prevProps:n,nextProps:o,instance:r}=t,a=Object.keys(i).reduce(function(t,e){var s,n,a;return s=t,n=i[e],"function"==typeof o[a=e]&&s.push(google.maps.event.addListener(r,n,o[a])),s},[]);return e={},function(t,e){Object.keys(t).forEach(s=>e(t[s],s))}(s,(t,s)=>{var i=o[s];i!==n[s]&&(e[s]=i,t(r,i))}),a}var C={onDblClick:"dblclick",onDragEnd:"dragend",onDragStart:"dragstart",onMapTypeIdChanged:"maptypeid_changed",onMouseMove:"mousemove",onMouseOut:"mouseout",onMouseOver:"mouseover",onMouseDown:"mousedown",onMouseUp:"mouseup",onRightClick:"rightclick",onTilesLoaded:"tilesloaded",onBoundsChanged:"bounds_changed",onCenterChanged:"center_changed",onClick:"click",onDrag:"drag",onHeadingChanged:"heading_changed",onIdle:"idle",onProjectionChanged:"projection_changed",onResize:"resize",onTiltChanged:"tilt_changed",onZoomChanged:"zoom_changed"},w={extraMapTypes(t,e){e.forEach(function(e,s){t.mapTypes.set(String(s),e)})},center(t,e){t.setCenter(e)},clickableIcons(t,e){t.setClickableIcons(e)},heading(t,e){t.setHeading(e)},mapTypeId(t,e){t.setMapTypeId(e)},options(t,e){t.setOptions(e)},streetView(t,e){t.setStreetView(e)},tilt(t,e){t.setTilt(e)},zoom(t,e){t.setZoom(e)}};class M extends p.PureComponent{componentDidMount(){var t=this.getInstance();this.registeredEvents=x({updaterMap:w,eventMap:C,prevProps:{},nextProps:this.props,instance:t}),this.setState(function(){return{map:t}},this.setMapCallback)}componentDidUpdate(t){null!==this.state.map&&(b(this.registeredEvents),this.registeredEvents=x({updaterMap:w,eventMap:C,prevProps:t,nextProps:this.props,instance:this.state.map}))}componentWillUnmount(){null!==this.state.map&&(this.props.onUnmount&&this.props.onUnmount(this.state.map),b(this.registeredEvents))}render(){return(0,l.jsx)("div",{id:this.props.id,ref:this.getRef,style:this.props.mapContainerStyle,className:this.props.mapContainerClassName,children:(0,l.jsx)(v.Provider,{value:this.state.map,children:null!==this.state.map?this.props.children:null})})}constructor(){super(...arguments),d(this,"state",{map:null}),d(this,"registeredEvents",[]),d(this,"mapRef",null),d(this,"getInstance",()=>null===this.mapRef?null:new google.maps.Map(this.mapRef,this.props.options)),d(this,"panTo",t=>{var e=this.getInstance();e&&e.panTo(t)}),d(this,"setMapCallback",()=>{null!==this.state.map&&this.props.onLoad&&this.props.onLoad(this.state.map)}),d(this,"getRef",t=>{this.mapRef=t})}}function P(t,e,s,i,n,o,r){try{var a=t[o](r),h=a.value}catch(t){return void s(t)}a.done?e(h):Promise.resolve(h).then(i,n)}function k(t){return function(){var e=this,s=arguments;return new Promise(function(i,n){var o=t.apply(e,s);function r(t){P(o,i,n,r,a,"next",t)}function a(t){P(o,i,n,r,a,"throw",t)}r(void 0)})}}var O="undefined"!=typeof document;function L(t){var e=t.href;return!!e&&(0===e.indexOf("https://fonts.googleapis.com/css?family=Roboto")||0===e.indexOf("https://fonts.googleapis.com/css?family=Google+Sans+Text"))||("style"===t.tagName.toLowerCase()&&t.styleSheet&&t.styleSheet.cssText&&0===t.styleSheet.cssText.replace("\r\n","").indexOf(".gm-style")?(t.styleSheet.cssText="",!0):"style"===t.tagName.toLowerCase()&&t.innerHTML&&0===t.innerHTML.replace("\r\n","").indexOf(".gm-style")?(t.innerHTML="",!0):"style"===t.tagName.toLowerCase()&&!t.styleSheet&&!t.innerHTML)}function E(){var t=document.getElementsByTagName("head")[0];if(t){var e=t.insertBefore.bind(t);t.insertBefore=function(s,i){return L(s)||Reflect.apply(e,t,[s,i]),s};var s=t.appendChild.bind(t);t.appendChild=function(e){return L(e)||Reflect.apply(s,t,[e]),e}}}var S=!1;function I(){return(0,l.jsx)("div",{children:"Loading..."})}var j={id:"script-loader",version:"weekly"};class D extends p.PureComponent{componentDidMount(){if(O){if(window.google&&window.google.maps&&!S){console.error("google api is already presented");return}this.isCleaningUp().then(this.injectScript).catch(function(t){console.error("Error at injecting script after cleaning up: ",t)})}}componentDidUpdate(t){this.props.libraries!==t.libraries&&console.warn("Performance warning! LoadScript has been reloaded unintentionally! You should not pass `libraries` prop as new array. Please keep an array of libraries as static class property for Components and PureComponents, or just a const variable outside of component, or somewhere in config files or ENV variables"),O&&t.language!==this.props.language&&(this.cleanup(),this.setState(function(){return{loaded:!1}},this.cleanupCallback))}componentWillUnmount(){O&&(this.cleanup(),window.setTimeout(()=>{this.check||(delete window.google,S=!1)},1),this.props.onUnmount&&this.props.onUnmount())}render(){return(0,l.jsxs)(l.Fragment,{children:[(0,l.jsx)("div",{ref:this.getRef}),this.state.loaded?this.props.children:this.props.loadingElement||(0,l.jsx)(I,{})]})}constructor(){super(...arguments),d(this,"check",null),d(this,"state",{loaded:!1}),d(this,"cleanupCallback",()=>{delete window.google.maps,this.injectScript()}),d(this,"isCleaningUp",k(function*(){return new Promise(function(t){if(S){if(O)var e=window.setInterval(function(){S||(window.clearInterval(e),t())},1)}else t()})})),d(this,"cleanup",()=>{S=!0;var t=document.getElementById(this.props.id);t&&t.parentNode&&t.parentNode.removeChild(t),Array.prototype.slice.call(document.getElementsByTagName("script")).filter(function(t){return"string"==typeof t.src&&t.src.includes("maps.googleapis")}).forEach(function(t){t.parentNode&&t.parentNode.removeChild(t)}),Array.prototype.slice.call(document.getElementsByTagName("link")).filter(function(t){return"https://fonts.googleapis.com/css?family=Roboto:300,400,500,700|Google+Sans"===t.href}).forEach(function(t){t.parentNode&&t.parentNode.removeChild(t)}),Array.prototype.slice.call(document.getElementsByTagName("style")).filter(function(t){return void 0!==t.innerText&&t.innerText.length>0&&t.innerText.includes(".gm-")}).forEach(function(t){t.parentNode&&t.parentNode.removeChild(t)})}),d(this,"injectScript",()=>{this.props.preventGoogleFontsLoading&&E(),m(!!this.props.id,'LoadScript requires "id" prop to be a string: %s',this.props.id),(function(t){var{url:e,id:s,nonce:i}=t;return O?new Promise(function(t,n){var o=document.getElementById(s),r=window;if(o){var a=o.getAttribute("data-state");if(o.src===e&&"error"!==a)if("ready"===a)return t(s);else{var h=r.initMap,l=o.onerror;r.initMap=function(){h&&h(),t(s)},o.onerror=function(t){l&&l(t),n(t)};return}o.remove()}var p=document.createElement("script");p.type="text/javascript",p.src=e,p.id=s,p.async=!0,p.nonce=i||"",p.onerror=function(t){p.setAttribute("data-state","error"),n(t)},r.initMap=function(){p.setAttribute("data-state","ready"),t(s)},document.head.appendChild(p)}).catch(t=>{throw console.error("injectScript error: ",t),t}):Promise.reject(Error("document is undefined"))})({id:this.props.id,nonce:this.props.nonce,url:function(t){var{googleMapsApiKey:e,googleMapsClientId:s,version:i="weekly",language:n,region:o,libraries:r,channel:a,mapIds:h,authReferrerPolicy:l}=t,p=[];return m(e&&s||!(e&&s),"You need to specify either googleMapsApiKey or googleMapsClientId for @react-google-maps/api load script to work. You cannot use both at the same time."),e?p.push("key=".concat(e)):s&&p.push("client=".concat(s)),i&&p.push("v=".concat(i)),n&&p.push("language=".concat(n)),o&&p.push("region=".concat(o)),r&&r.length&&p.push("libraries=".concat(r.sort().join(","))),a&&p.push("channel=".concat(a)),h&&h.length&&p.push("map_ids=".concat(h.join(","))),l&&p.push("auth_referrer_policy=".concat(l)),p.push("loading=async"),p.push("callback=initMap"),"https://maps.googleapis.com/maps/api/js?".concat(p.join("&"))}(this.props)}).then(()=>{this.props.onLoad&&this.props.onLoad(),this.setState(function(){return{loaded:!0}})}).catch(t=>{this.props.onError&&this.props.onError(t),console.error("\n There has been an Error with loading Google Maps API script, please check that you provided correct google API key (".concat(this.props.googleMapsApiKey||"-",") or Client ID (").concat(this.props.googleMapsClientId||"-",") to \n Otherwise it is a Network issue.\n "))})}),d(this,"getRef",t=>{this.check=t})}}d(D,"defaultProps",j);(0,l.jsx)(I,{}),"function"==typeof SuppressedError&&SuppressedError;var B=function(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}(function t(e,s){if(e===s)return!0;if(e&&s&&"object"==typeof e&&"object"==typeof s){if(e.constructor!==s.constructor)return!1;if(Array.isArray(e)){if((i=e.length)!=s.length)return!1;for(n=i;0!=n--;)if(!t(e[n],s[n]))return!1;return!0}if(e.constructor===RegExp)return e.source===s.source&&e.flags===s.flags;if(e.valueOf!==Object.prototype.valueOf)return e.valueOf()===s.valueOf();if(e.toString!==Object.prototype.toString)return e.toString()===s.toString();if((i=(o=Object.keys(e)).length)!==Object.keys(s).length)return!1;for(n=i;0!=n--;)if(!Object.prototype.hasOwnProperty.call(s,o[n]))return!1;for(n=i;0!=n--;){var i,n,o,r=o[n];if(!t(e[r],s[r]))return!1}return!0}return e!=e&&s!=s}),T="__googleMapsScriptId";!function(t){t[t.INITIALIZED=0]="INITIALIZED",t[t.LOADING=1]="LOADING",t[t.SUCCESS=2]="SUCCESS",t[t.FAILURE=3]="FAILURE"}(o||(o={}));class U{get options(){return{version:this.version,apiKey:this.apiKey,channel:this.channel,client:this.client,id:this.id,libraries:this.libraries,language:this.language,region:this.region,mapIds:this.mapIds,nonce:this.nonce,url:this.url,authReferrerPolicy:this.authReferrerPolicy}}get status(){return this.errors.length?o.FAILURE:this.done?o.SUCCESS:this.loading?o.LOADING:o.INITIALIZED}get failed(){return this.done&&!this.loading&&this.errors.length>=this.retries+1}createUrl(){var t=this.url;return t+="?callback=__googleMapsCallback&loading=async",this.apiKey&&(t+="&key=".concat(this.apiKey)),this.channel&&(t+="&channel=".concat(this.channel)),this.client&&(t+="&client=".concat(this.client)),this.libraries.length>0&&(t+="&libraries=".concat(this.libraries.join(","))),this.language&&(t+="&language=".concat(this.language)),this.region&&(t+="®ion=".concat(this.region)),this.version&&(t+="&v=".concat(this.version)),this.mapIds&&(t+="&map_ids=".concat(this.mapIds.join(","))),this.authReferrerPolicy&&(t+="&auth_referrer_policy=".concat(this.authReferrerPolicy)),t}deleteScript(){var t=document.getElementById(this.id);t&&t.remove()}load(){return this.loadPromise()}loadPromise(){return new Promise((t,e)=>{this.loadCallback(s=>{s?e(s.error):t(window.google)})})}importLibrary(t){return this.execute(),google.maps.importLibrary(t)}loadCallback(t){this.callbacks.push(t),this.execute()}setScript(){if(document.getElementById(this.id)){this.callback();return}var t,e,s,i,n,o,r,a,h,l,p,c,u,d,g,m={key:this.apiKey,channel:this.channel,client:this.client,libraries:this.libraries.length&&this.libraries,v:this.version,mapIds:this.mapIds,language:this.language,region:this.region,authReferrerPolicy:this.authReferrerPolicy};Object.keys(m).forEach(t=>!m[t]&&delete m[t]),!(null===(g=null===(d=null==window?void 0:window.google)||void 0===d?void 0:d.maps)||void 0===g?void 0:g.importLibrary)&&(i="The Google Maps JavaScript API",n="google",o="importLibrary",r="__ib__",a=document,l=(h=(h=window)[n]||(h[n]={})).maps||(h.maps={}),p=new Set,c=new URLSearchParams,u=()=>t||(t=new Promise((o,h)=>{var u,d,g;return u=this,d=void 0,g=function*(){var u;for(s in yield e=a.createElement("script"),e.id=this.id,c.set("libraries",[...p]+""),m)c.set(s.replace(/[A-Z]/g,t=>"_"+t[0].toLowerCase()),m[s]);c.set("callback",n+".maps."+r),e.src=this.url+"?"+c,l[r]=o,e.onerror=()=>t=h(Error(i+" could not load.")),e.nonce=this.nonce||(null===(u=a.querySelector("script[nonce]"))||void 0===u?void 0:u.nonce)||"",a.head.append(e)},new(d||(d=Promise))(function(t,e){function s(t){try{n(g.next(t))}catch(t){e(t)}}function i(t){try{n(g.throw(t))}catch(t){e(t)}}function n(e){var n;e.done?t(e.value):((n=e.value)instanceof d?n:new d(function(t){t(n)})).then(s,i)}n((g=g.apply(u,[])).next())})})),l[o]?console.warn(i+" only loads once. Ignoring:",m):l[o]=function(t){for(var e=arguments.length,s=Array(e>1?e-1:0),i=1;il[o](t,...s))});var v=this.libraries.map(t=>this.importLibrary(t));v.length||v.push(this.importLibrary("core")),Promise.all(v).then(()=>this.callback(),t=>{var e=new ErrorEvent("error",{error:t});this.loadErrorCallback(e)})}reset(){this.deleteScript(),this.done=!1,this.loading=!1,this.errors=[],this.onerrorEvent=null}resetIfRetryingFailed(){this.failed&&this.reset()}loadErrorCallback(t){if(this.errors.push(t),this.errors.length<=this.retries){var e=this.errors.length*Math.pow(2,this.errors.length);console.error("Failed to load Google Maps script, retrying in ".concat(e," ms.")),setTimeout(()=>{this.deleteScript(),this.setScript()},e)}else this.onerrorEvent=t,this.callback()}callback(){this.done=!0,this.loading=!1,this.callbacks.forEach(t=>{t(this.onerrorEvent)}),this.callbacks=[]}execute(){if(this.resetIfRetryingFailed(),!this.loading)if(this.done)this.callback();else{if(window.google&&window.google.maps&&window.google.maps.version){console.warn("Google Maps already loaded outside @googlemaps/js-api-loader. This may result in undesirable behavior as options and script parameters may not match."),this.callback();return}this.loading=!0,this.setScript()}}constructor(t){var{apiKey:e,authReferrerPolicy:s,channel:i,client:n,id:o=T,language:r,libraries:a=[],mapIds:h,nonce:l,region:p,retries:c=3,url:u="https://maps.googleapis.com/maps/api/js",version:d}=t;if(this.callbacks=[],this.done=!1,this.loading=!1,this.errors=[],this.apiKey=e,this.authReferrerPolicy=s,this.channel=i,this.client=n,this.id=o||T,this.language=r,this.libraries=a,this.mapIds=h,this.nonce=l,this.region=p,this.retries=c,this.url=u,this.version=d,U.instance){if(!B(this.options,U.instance.options))throw Error("Loader must not be called again with different options. ".concat(JSON.stringify(this.options)," !== ").concat(JSON.stringify(U.instance.options)));return U.instance}U.instance=this}}var A=["maps"];function R(t){var{id:e=j.id,version:s=j.version,nonce:i,googleMapsApiKey:n,language:o,region:r,libraries:a=A,preventGoogleFontsLoading:h,mapIds:l,authReferrerPolicy:c}=t,u=(0,p.useRef)(!1),[d,g]=(0,p.useState)(!1),[m,v]=(0,p.useState)(void 0);(0,p.useEffect)(function(){return u.current=!0,()=>{u.current=!1}},[]);var f=(0,p.useMemo)(()=>new U({id:e,apiKey:n,version:s,libraries:a,language:o||"en",region:r||"US",mapIds:l||[],nonce:i||"",authReferrerPolicy:c||"origin"}),[e,n,s,a,o,r,l,i,c]);(0,p.useEffect)(function(){!d&&f.load().then(()=>{u.current&&g(!0)}).catch(t=>{v(t)})},[]),(0,p.useEffect)(()=>{O&&h&&E()},[h]);var y=(0,p.useRef)();return(0,p.useEffect)(()=>{y.current&&a!==y.current&&console.warn("Performance warning! LoadScript has been reloaded unintentionally! You should not pass `libraries` prop as new array. Please keep an array of libraries as static class property for Components and PureComponents, or just a const variable outside of component, or somewhere in config files or ENV variables"),y.current=a},[a]),{isLoaded:d,loadError:m}}function _(t,e){var s=Object.keys(t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(t);e&&(i=i.filter(function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable})),s.push.apply(s,i)}return s}function z(t){for(var e=1;e{null!==this.state.trafficLayer&&this.props.onLoad&&this.props.onLoad(this.state.trafficLayer)}),d(this,"registeredEvents",[])}}d(V,"contextType",v);class N extends p.PureComponent{componentDidMount(){var t=new google.maps.BicyclingLayer;this.setState(()=>({bicyclingLayer:t}),this.setBicyclingLayerCallback)}componentWillUnmount(){null!==this.state.bicyclingLayer&&(this.props.onUnmount&&this.props.onUnmount(this.state.bicyclingLayer),this.state.bicyclingLayer.setMap(null))}render(){return null}constructor(){super(...arguments),d(this,"state",{bicyclingLayer:null}),d(this,"setBicyclingLayerCallback",()=>{null!==this.state.bicyclingLayer&&(this.state.bicyclingLayer.setMap(this.context),this.props.onLoad&&this.props.onLoad(this.state.bicyclingLayer))})}}d(N,"contextType",v);class H extends p.PureComponent{componentDidMount(){var t=new google.maps.TransitLayer;this.setState(function(){return{transitLayer:t}},this.setTransitLayerCallback)}componentWillUnmount(){null!==this.state.transitLayer&&(this.props.onUnmount&&this.props.onUnmount(this.state.transitLayer),this.state.transitLayer.setMap(null))}render(){return null}constructor(){super(...arguments),d(this,"state",{transitLayer:null}),d(this,"setTransitLayerCallback",()=>{null!==this.state.transitLayer&&(this.state.transitLayer.setMap(this.context),this.props.onLoad&&this.props.onLoad(this.state.transitLayer))})}}function F(t,e){var s=Object.keys(t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(t);e&&(i=i.filter(function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable})),s.push.apply(s,i)}return s}function G(t){for(var e=1;e{null!==this.state.drawingManager&&this.props.onLoad&&this.props.onLoad(this.state.drawingManager)}),m(!!google.maps.drawing,"Did you include prop libraries={['drawing']} in the URL? %s",google.maps.drawing)}}function J(t,e){var s=Object.keys(t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(t);e&&(i=i.filter(function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable})),s.push.apply(s,i)}return s}function X(t){for(var e=1;e(0,p.isValidElement)(t)?(0,p.cloneElement)(t,{anchor:this.marker}):t):null)||null}constructor(){super(...arguments),d(this,"registeredEvents",[])}}d(te,"contextType",v);var ts=function(){function t(e,s){e.getClusterer().extend(t,google.maps.OverlayView),this.cluster=e,this.clusterClassName=this.cluster.getClusterer().getClusterClass(),this.className=this.clusterClassName,this.styles=s,this.center=void 0,this.div=null,this.sums=null,this.visible=!1,this.boundsChangedListener=null,this.url="",this.height=0,this.width=0,this.anchorText=[0,0],this.anchorIcon=[0,0],this.textColor="black",this.textSize=11,this.textDecoration="none",this.fontWeight="bold",this.fontStyle="normal",this.fontFamily="Arial,sans-serif",this.backgroundPosition="0 0",this.cMouseDownInCluster=null,this.cDraggingMapByCluster=null,this.timeOut=null,this.setMap(e.getMap()),this.onBoundsChanged=this.onBoundsChanged.bind(this),this.onMouseDown=this.onMouseDown.bind(this),this.onClick=this.onClick.bind(this),this.onMouseOver=this.onMouseOver.bind(this),this.onMouseOut=this.onMouseOut.bind(this),this.onAdd=this.onAdd.bind(this),this.onRemove=this.onRemove.bind(this),this.draw=this.draw.bind(this),this.hide=this.hide.bind(this),this.show=this.show.bind(this),this.useStyle=this.useStyle.bind(this),this.setCenter=this.setCenter.bind(this),this.getPosFromLatLng=this.getPosFromLatLng.bind(this)}return t.prototype.onBoundsChanged=function(){this.cDraggingMapByCluster=this.cMouseDownInCluster},t.prototype.onMouseDown=function(){this.cMouseDownInCluster=!0,this.cDraggingMapByCluster=!1},t.prototype.onClick=function(t){if(this.cMouseDownInCluster=!1,!this.cDraggingMapByCluster){var e=this.cluster.getClusterer();if(google.maps.event.trigger(e,"click",this.cluster),google.maps.event.trigger(e,"clusterclick",this.cluster),e.getZoomOnClick()){var s=e.getMaxZoom(),i=this.cluster.getBounds(),n=e.getMap();null!==n&&"fitBounds"in n&&n.fitBounds(i),this.timeOut=window.setTimeout(function(){var t=e.getMap();if(null!==t){"fitBounds"in t&&t.fitBounds(i);var n=t.getZoom()||0;null!==s&&n>s&&t.setZoom(s+1)}},100)}t.cancelBubble=!0,t.stopPropagation&&t.stopPropagation()}},t.prototype.onMouseOver=function(){google.maps.event.trigger(this.cluster.getClusterer(),"mouseover",this.cluster)},t.prototype.onMouseOut=function(){google.maps.event.trigger(this.cluster.getClusterer(),"mouseout",this.cluster)},t.prototype.onAdd=function(){this.div=document.createElement("div"),this.div.className=this.className,this.visible&&this.show(),null===(t=this.getPanes())||void 0===t||t.overlayMouseTarget.appendChild(this.div);var t,e=this.getMap();null!==e&&(this.boundsChangedListener=google.maps.event.addListener(e,"bounds_changed",this.onBoundsChanged),this.div.addEventListener("mousedown",this.onMouseDown),this.div.addEventListener("click",this.onClick),this.div.addEventListener("mouseover",this.onMouseOver),this.div.addEventListener("mouseout",this.onMouseOut))},t.prototype.onRemove=function(){this.div&&this.div.parentNode&&(this.hide(),null!==this.boundsChangedListener&&google.maps.event.removeListener(this.boundsChangedListener),this.div.removeEventListener("mousedown",this.onMouseDown),this.div.removeEventListener("click",this.onClick),this.div.removeEventListener("mouseover",this.onMouseOver),this.div.removeEventListener("mouseout",this.onMouseOut),this.div.parentNode.removeChild(this.div),null!==this.timeOut&&(window.clearTimeout(this.timeOut),this.timeOut=null),this.div=null)},t.prototype.draw=function(){if(this.visible&&null!==this.div&&this.center){var t=this.getPosFromLatLng(this.center);this.div.style.top=null!==t?"".concat(t.y,"px"):"0",this.div.style.left=null!==t?"".concat(t.x,"px"):"0"}},t.prototype.hide=function(){this.div&&(this.div.style.display="none"),this.visible=!1},t.prototype.show=function(){var t,e,s,i,n,o;if(this.div&&this.center){var r=null===this.sums||void 0===this.sums.title||""===this.sums.title?this.cluster.getClusterer().getTitle():this.sums.title,a=this.backgroundPosition.split(" "),h=parseInt((null===(t=a[0])||void 0===t?void 0:t.replace(/^\s+|\s+$/g,""))||"0",10),l=parseInt((null===(e=a[1])||void 0===e?void 0:e.replace(/^\s+|\s+$/g,""))||"0",10),p=this.getPosFromLatLng(this.center);this.div.className=this.className,this.div.setAttribute("style","cursor: pointer; position: absolute; top: ".concat(null!==p?"".concat(p.y,"px"):"0","; left: ").concat(null!==p?"".concat(p.x,"px"):"0","; width: ").concat(this.width,"px; height: ").concat(this.height,"px; "));var c=document.createElement("img");c.alt=r,c.src=this.url,c.width=this.width,c.height=this.height,c.setAttribute("style","position: absolute; top: ".concat(l,"px; left: ").concat(h,"px")),this.cluster.getClusterer().enableRetinaIcons||(c.style.clip="rect(-".concat(l,"px, -").concat(h+this.width,"px, -").concat(l+this.height,", -").concat(h,")"));var u=document.createElement("div");u.setAttribute("style","position: absolute; top: ".concat(this.anchorText[0],"px; left: ").concat(this.anchorText[1],"px; color: ").concat(this.textColor,"; font-size: ").concat(this.textSize,"px; font-family: ").concat(this.fontFamily,"; font-weight: ").concat(this.fontWeight,"; fontStyle: ").concat(this.fontStyle,"; text-decoration: ").concat(this.textDecoration,"; text-align: center; width: ").concat(this.width,"px; line-height: ").concat(this.height,"px")),(null===(s=this.sums)||void 0===s?void 0:s.text)&&(u.innerText="".concat(null===(i=this.sums)||void 0===i?void 0:i.text)),(null===(n=this.sums)||void 0===n?void 0:n.html)&&(u.innerHTML="".concat(null===(o=this.sums)||void 0===o?void 0:o.html)),this.div.innerHTML="",this.div.appendChild(c),this.div.appendChild(u),this.div.title=r,this.div.style.display=""}this.visible=!0},t.prototype.useStyle=function(t){this.sums=t;var e=this.cluster.getClusterer().getStyles(),s=e[Math.min(e.length-1,Math.max(0,t.index-1))];s&&(this.url=s.url,this.height=s.height,this.width=s.width,s.className&&(this.className="".concat(this.clusterClassName," ").concat(s.className)),this.anchorText=s.anchorText||[0,0],this.anchorIcon=s.anchorIcon||[this.height/2,this.width/2],this.textColor=s.textColor||"black",this.textSize=s.textSize||11,this.textDecoration=s.textDecoration||"none",this.fontWeight=s.fontWeight||"bold",this.fontStyle=s.fontStyle||"normal",this.fontFamily=s.fontFamily||"Arial,sans-serif",this.backgroundPosition=s.backgroundPosition||"0 0")},t.prototype.setCenter=function(t){this.center=t},t.prototype.getPosFromLatLng=function(t){var e=this.getProjection().fromLatLngToDivPixel(t);return null!==e&&(e.x-=this.anchorIcon[1],e.y-=this.anchorIcon[0]),e},t}(),ti=function(){function t(t){this.markerClusterer=t,this.map=this.markerClusterer.getMap(),this.gridSize=this.markerClusterer.getGridSize(),this.minClusterSize=this.markerClusterer.getMinimumClusterSize(),this.averageCenter=this.markerClusterer.getAverageCenter(),this.markers=[],this.center=void 0,this.bounds=null,this.clusterIcon=new ts(this,this.markerClusterer.getStyles()),this.getSize=this.getSize.bind(this),this.getMarkers=this.getMarkers.bind(this),this.getCenter=this.getCenter.bind(this),this.getMap=this.getMap.bind(this),this.getClusterer=this.getClusterer.bind(this),this.getBounds=this.getBounds.bind(this),this.remove=this.remove.bind(this),this.addMarker=this.addMarker.bind(this),this.isMarkerInClusterBounds=this.isMarkerInClusterBounds.bind(this),this.calculateBounds=this.calculateBounds.bind(this),this.updateIcon=this.updateIcon.bind(this),this.isMarkerAlreadyAdded=this.isMarkerAlreadyAdded.bind(this)}return t.prototype.getSize=function(){return this.markers.length},t.prototype.getMarkers=function(){return this.markers},t.prototype.getCenter=function(){return this.center},t.prototype.getMap=function(){return this.map},t.prototype.getClusterer=function(){return this.markerClusterer},t.prototype.getBounds=function(){for(var t=new google.maps.LatLngBounds(this.center,this.center),e=this.getMarkers(),s=0;so)t.getMap()!==this.map&&t.setMap(this.map);else if(ns||e0))for(var t=0;t3?new google.maps.LatLngBounds(null==i?void 0:i.getSouthWest(),null==i?void 0:i.getNorthEast()):new google.maps.LatLngBounds(new google.maps.LatLng(85.02070771743472,-178.48388434375),new google.maps.LatLng(-85.08136444384544,178.00048865625)),o=this.getExtendedBounds(n),r=Math.min(t+this.batchSize,this.markers.length),a=t;a({markerClusterer:t}),this.setClustererCallback)}}componentDidUpdate(t){this.state.markerClusterer&&(b(this.registeredEvents),this.registeredEvents=x({updaterMap:th,eventMap:ta,prevProps:t,nextProps:this.props,instance:this.state.markerClusterer}))}componentWillUnmount(){null!==this.state.markerClusterer&&(this.props.onUnmount&&this.props.onUnmount(this.state.markerClusterer),b(this.registeredEvents),this.state.markerClusterer.setMap(null))}render(){return null!==this.state.markerClusterer?this.props.children(this.state.markerClusterer):null}constructor(){super(...arguments),d(this,"registeredEvents",[]),d(this,"state",{markerClusterer:null}),d(this,"setClustererCallback",()=>{null!==this.state.markerClusterer&&this.props.onLoad&&this.props.onLoad(this.state.markerClusterer)})}}function tp(t){t.cancelBubble=!0,t.stopPropagation&&t.stopPropagation()}d(tl,"contextType",v);var tc=function(){function t(e){void 0===e&&(e={}),this.getCloseClickHandler=this.getCloseClickHandler.bind(this),this.closeClickHandler=this.closeClickHandler.bind(this),this.createInfoBoxDiv=this.createInfoBoxDiv.bind(this),this.addClickHandler=this.addClickHandler.bind(this),this.getCloseBoxImg=this.getCloseBoxImg.bind(this),this.getBoxWidths=this.getBoxWidths.bind(this),this.setBoxStyle=this.setBoxStyle.bind(this),this.setPosition=this.setPosition.bind(this),this.getPosition=this.getPosition.bind(this),this.setOptions=this.setOptions.bind(this),this.setContent=this.setContent.bind(this),this.setVisible=this.setVisible.bind(this),this.getContent=this.getContent.bind(this),this.getVisible=this.getVisible.bind(this),this.setZIndex=this.setZIndex.bind(this),this.getZIndex=this.getZIndex.bind(this),this.onRemove=this.onRemove.bind(this),this.panBox=this.panBox.bind(this),this.extend=this.extend.bind(this),this.close=this.close.bind(this),this.draw=this.draw.bind(this),this.show=this.show.bind(this),this.hide=this.hide.bind(this),this.open=this.open.bind(this),this.extend(t,google.maps.OverlayView),this.content=e.content||"",this.disableAutoPan=e.disableAutoPan||!1,this.maxWidth=e.maxWidth||0,this.pixelOffset=e.pixelOffset||new google.maps.Size(0,0),this.position=e.position||new google.maps.LatLng(0,0),this.zIndex=e.zIndex||null,this.boxClass=e.boxClass||"infoBox",this.boxStyle=e.boxStyle||{},this.closeBoxMargin=e.closeBoxMargin||"2px",this.closeBoxURL=e.closeBoxURL||"http://www.google.com/intl/en_us/mapfiles/close.gif",""===e.closeBoxURL&&(this.closeBoxURL=""),this.infoBoxClearance=e.infoBoxClearance||new google.maps.Size(1,1),void 0===e.visible&&(void 0===e.isHidden?e.visible=!0:e.visible=!e.isHidden),this.isHidden=!e.visible,this.alignBottom=e.alignBottom||!1,this.pane=e.pane||"floatPane",this.enableEventPropagation=e.enableEventPropagation||!1,this.div=null,this.closeListener=null,this.moveListener=null,this.mapListener=null,this.contextListener=null,this.eventListeners=null,this.fixedWidthSet=null}return t.prototype.createInfoBoxDiv=function(){var t=this;if(!this.div){this.div=document.createElement("div"),this.setBoxStyle(),"string"==typeof this.content?this.div.innerHTML=this.getCloseBoxImg()+this.content:(this.div.innerHTML=this.getCloseBoxImg(),this.div.appendChild(this.content));var e=this.getPanes();if(null!==e&&e[this.pane].appendChild(this.div),this.addClickHandler(),this.div.style.width)this.fixedWidthSet=!0;else if(0!==this.maxWidth&&this.div.offsetWidth>this.maxWidth)this.div.style.width=this.maxWidth+"px",this.fixedWidthSet=!0;else{var s=this.getBoxWidths();this.div.style.width=this.div.offsetWidth-s.left-s.right+"px",this.fixedWidthSet=!1}if(this.panBox(this.disableAutoPan),!this.enableEventPropagation){this.eventListeners=[];for(var i=0,n=["mousedown","mouseover","mouseout","mouseup","click","dblclick","touchstart","touchend","touchmove"];i"),t},t.prototype.addClickHandler=function(){this.closeListener=this.div&&this.div.firstChild&&""!==this.closeBoxURL?google.maps.event.addListener(this.div.firstChild,"click",this.getCloseClickHandler()):null},t.prototype.closeClickHandler=function(t){t.cancelBubble=!0,t.stopPropagation&&t.stopPropagation(),google.maps.event.trigger(this,"closeclick"),this.close()},t.prototype.getCloseClickHandler=function(){return this.closeClickHandler},t.prototype.panBox=function(t){if(this.div&&!t){var e=this.getMap();if(e instanceof google.maps.Map){var s=0,i=0,n=e.getBounds();n&&!n.contains(this.position)&&e.setCenter(this.position);var o=e.getDiv(),r=o.offsetWidth,a=o.offsetHeight,h=this.pixelOffset.width,l=this.pixelOffset.height,p=this.div.offsetWidth,c=this.div.offsetHeight,u=this.infoBoxClearance.width,d=this.infoBoxClearance.height,g=this.getProjection().fromLatLngToContainerPixel(this.position);null!==g&&(g.x<-h+u?s=g.x+h-u:g.x+p+h+u>r&&(s=g.x+p+h+u-r),this.alignBottom?g.y<-l+d+c?i=g.y+l-d-c:g.y+l+d>a&&(i=g.y+l+d-a):g.y<-l+d?i=g.y+l-d:g.y+c+l+d>a&&(i=g.y+c+l+d-a)),(0!==s||0!==i)&&e.panBy(s,i)}}},t.prototype.setBoxStyle=function(){if(this.div){this.div.className=this.boxClass,this.div.style.cssText="";var t=this.boxStyle;for(var e in t)Object.prototype.hasOwnProperty.call(t,e)&&(this.div.style[e]=t[e]);if(this.div.style.webkitTransform="translateZ(0)",void 0!==this.div.style.opacity&&""!==this.div.style.opacity){var s=parseFloat(this.div.style.opacity||"");this.div.style.msFilter='"progid:DXImageTransform.Microsoft.Alpha(Opacity='+100*s+')"',this.div.style.filter="alpha(opacity="+100*s+")"}this.div.style.position="absolute",this.div.style.visibility="hidden",null!==this.zIndex&&(this.div.style.zIndex=this.zIndex+""),this.div.style.overflow||(this.div.style.overflow="auto")}},t.prototype.getBoxWidths=function(){var t={top:0,bottom:0,left:0,right:0};if(!this.div)return t;if(document.defaultView){var e=this.div.ownerDocument,s=e&&e.defaultView?e.defaultView.getComputedStyle(this.div,""):null;s&&(t.top=parseInt(s.borderTopWidth||"",10)||0,t.bottom=parseInt(s.borderBottomWidth||"",10)||0,t.left=parseInt(s.borderLeftWidth||"",10)||0,t.right=parseInt(s.borderRightWidth||"",10)||0)}else if(document.documentElement.currentStyle){var i=this.div.currentStyle;i&&(t.top=parseInt(i.borderTopWidth||"",10)||0,t.bottom=parseInt(i.borderBottomWidth||"",10)||0,t.left=parseInt(i.borderLeftWidth||"",10)||0,t.right=parseInt(i.borderRightWidth||"",10)||0)}return t},t.prototype.onRemove=function(){this.div&&this.div.parentNode&&(this.div.parentNode.removeChild(this.div),this.div=null)},t.prototype.draw=function(){if(this.createInfoBoxDiv(),this.div){var t=this.getProjection().fromLatLngToDivPixel(this.position);null!==t&&(this.div.style.left=t.x+this.pixelOffset.width+"px",this.alignBottom?this.div.style.bottom=-(t.y+this.pixelOffset.height)+"px":this.div.style.top=t.y+this.pixelOffset.height+"px"),this.isHidden?this.div.style.visibility="hidden":this.div.style.visibility="visible"}},t.prototype.setOptions=function(t){void 0===t&&(t={}),void 0!==t.boxClass&&(this.boxClass=t.boxClass,this.setBoxStyle()),void 0!==t.boxStyle&&(this.boxStyle=t.boxStyle,this.setBoxStyle()),void 0!==t.content&&this.setContent(t.content),void 0!==t.disableAutoPan&&(this.disableAutoPan=t.disableAutoPan),void 0!==t.maxWidth&&(this.maxWidth=t.maxWidth),void 0!==t.pixelOffset&&(this.pixelOffset=t.pixelOffset),void 0!==t.alignBottom&&(this.alignBottom=t.alignBottom),void 0!==t.position&&this.setPosition(t.position),void 0!==t.zIndex&&this.setZIndex(t.zIndex),void 0!==t.closeBoxMargin&&(this.closeBoxMargin=t.closeBoxMargin),void 0!==t.closeBoxURL&&(this.closeBoxURL=t.closeBoxURL),void 0!==t.infoBoxClearance&&(this.infoBoxClearance=t.infoBoxClearance),void 0!==t.isHidden&&(this.isHidden=t.isHidden),void 0!==t.visible&&(this.isHidden=!t.visible),void 0!==t.enableEventPropagation&&(this.enableEventPropagation=t.enableEventPropagation),this.div&&this.draw()},t.prototype.setContent=function(t){this.content=t,this.div&&(this.closeListener&&(google.maps.event.removeListener(this.closeListener),this.closeListener=null),this.fixedWidthSet||(this.div.style.width=""),"string"==typeof t?this.div.innerHTML=this.getCloseBoxImg()+t:(this.div.innerHTML=this.getCloseBoxImg(),this.div.appendChild(t)),this.fixedWidthSet||(this.div.style.width=this.div.offsetWidth+"px","string"==typeof t?this.div.innerHTML=this.getCloseBoxImg()+t:(this.div.innerHTML=this.getCloseBoxImg(),this.div.appendChild(t))),this.addClickHandler()),google.maps.event.trigger(this,"content_changed")},t.prototype.setPosition=function(t){this.position=t,this.div&&this.draw(),google.maps.event.trigger(this,"position_changed")},t.prototype.setVisible=function(t){this.isHidden=!t,this.div&&(this.div.style.visibility=this.isHidden?"hidden":"visible")},t.prototype.setZIndex=function(t){this.zIndex=t,this.div&&(this.div.style.zIndex=t+""),google.maps.event.trigger(this,"zindex_changed")},t.prototype.getContent=function(){return this.content},t.prototype.getPosition=function(){return this.position},t.prototype.getZIndex=function(){return this.zIndex},t.prototype.getVisible=function(){return null!=this.getMap()&&!this.isHidden},t.prototype.show=function(){this.isHidden=!1,this.div&&(this.div.style.visibility="visible")},t.prototype.hide=function(){this.isHidden=!0,this.div&&(this.div.style.visibility="hidden")},t.prototype.open=function(t,e){var s=this;e&&(this.position=e.getPosition(),this.moveListener=google.maps.event.addListener(e,"position_changed",function(){var t=e.getPosition();s.setPosition(t)}),this.mapListener=google.maps.event.addListener(e,"map_changed",function(){s.setMap(e.map)})),this.setMap(t),this.div&&this.panBox()},t.prototype.close=function(){if(this.closeListener&&(google.maps.event.removeListener(this.closeListener),this.closeListener=null),this.eventListeners){for(var t=0,e=this.eventListeners;t{e?null!==this.context&&t.open(this.context,e):t.getPosition()?null!==this.context&&t.open(this.context):m(!1,"You must provide either an anchor or a position prop for .")}),d(this,"setInfoBoxCallback",()=>{null!==this.state.infoBox&&null!==this.containerElement&&(this.state.infoBox.setContent(this.containerElement),this.open(this.state.infoBox,this.props.anchor),this.props.onLoad&&this.props.onLoad(this.state.infoBox))})}}d(tf,"contextType",v);var ty=g(a?r:(a=1,r=function t(e,s){if(e===s)return!0;if(e&&s&&"object"==typeof e&&"object"==typeof s){if(e.constructor!==s.constructor)return!1;if(Array.isArray(e)){if((i=e.length)!=s.length)return!1;for(n=i;0!=n--;)if(!t(e[n],s[n]))return!1;return!0}if(e.constructor===RegExp)return e.source===s.source&&e.flags===s.flags;if(e.valueOf!==Object.prototype.valueOf)return e.valueOf()===s.valueOf();if(e.toString!==Object.prototype.toString)return e.toString()===s.toString();if((i=(o=Object.keys(e)).length)!==Object.keys(s).length)return!1;for(n=i;0!=n--;)if(!Object.prototype.hasOwnProperty.call(s,o[n]))return!1;for(n=i;0!=n--;){var i,n,o,r=o[n];if(!t(e[r],s[r]))return!1}return!0}return e!=e&&s!=s})),tb=[Int8Array,Uint8Array,Uint8ClampedArray,Int16Array,Uint16Array,Int32Array,Uint32Array,Float32Array,Float64Array];class tx{static from(t){if(!(t instanceof ArrayBuffer))throw Error("Data must be an instance of ArrayBuffer.");var[e,s]=new Uint8Array(t,0,2);if(219!==e)throw Error("Data does not appear to be in a KDBush format.");var i=s>>4;if(1!==i)throw Error("Got v".concat(i," data when expected v").concat(1,"."));var n=tb[15&s];if(!n)throw Error("Unrecognized array type.");var[o]=new Uint16Array(t,2,1),[r]=new Uint32Array(t,4,1);return new tx(r,o,n,t)}add(t,e){var s=this._pos>>1;return this.ids[s]=s,this.coords[this._pos++]=t,this.coords[this._pos++]=e,s}finish(){var t=this._pos>>1;if(t!==this.numItems)throw Error("Added ".concat(t," items when expected ").concat(this.numItems,"."));return function t(e,s,i,n,o,r){if(!(o-n<=i)){var a=n+o>>1;(function t(e,s,i,n,o,r){for(;o>n;){if(o-n>600){var a=o-n+1,h=i-n+1,l=Math.log(a),p=.5*Math.exp(2*l/3),c=.5*Math.sqrt(l*p*(a-p)/a)*(h-a/2<0?-1:1),u=Math.max(n,Math.floor(i-h*p/a+c)),d=Math.min(o,Math.floor(i+(a-h)*p/a+c));t(e,s,i,u,d,r)}var g=s[2*i+r],m=n,v=o;for(tC(e,s,n,i),s[2*o+r]>g&&tC(e,s,n,o);mg;)v--}s[2*n+r]===g?tC(e,s,n,v):tC(e,s,++v,o),v<=i&&(n=v+1),i<=v&&(o=v-1)}})(e,s,a,n,o,r),t(e,s,i,n,a-1,1-r),t(e,s,i,a+1,o,1-r)}}(this.ids,this.coords,this.nodeSize,0,this.numItems-1,0),this._finished=!0,this}range(t,e,s,i){if(!this._finished)throw Error("Data not yet indexed - call index.finish().");for(var{ids:n,coords:o,nodeSize:r}=this,a=[0,n.length-1,0],h=[];a.length;){var l=a.pop()||0,p=a.pop()||0,c=a.pop()||0;if(p-c<=r){for(var u=c;u<=p;u++){var d=o[2*u],g=o[2*u+1];d>=t&&d<=s&&g>=e&&g<=i&&h.push(n[u])}continue}var m=c+p>>1,v=o[2*m],f=o[2*m+1];v>=t&&v<=s&&f>=e&&f<=i&&h.push(n[m]),(0===l?t<=v:e<=f)&&(a.push(c),a.push(m-1),a.push(1-l)),(0===l?s>=v:i>=f)&&(a.push(m+1),a.push(p),a.push(1-l))}return h}within(t,e,s){if(!this._finished)throw Error("Data not yet indexed - call index.finish().");for(var{ids:i,coords:n,nodeSize:o}=this,r=[0,i.length-1,0],a=[],h=s*s;r.length;){var l=r.pop()||0,p=r.pop()||0,c=r.pop()||0;if(p-c<=o){for(var u=c;u<=p;u++)tM(n[2*u],n[2*u+1],t,e)<=h&&a.push(i[u]);continue}var d=c+p>>1,g=n[2*d],m=n[2*d+1];tM(g,m,t,e)<=h&&a.push(i[d]),(0===l?t-s<=g:e-s<=m)&&(r.push(c),r.push(d-1),r.push(1-l)),(0===l?t+s>=g:e+s>=m)&&(r.push(d+1),r.push(p),r.push(1-l))}return a}constructor(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:64,s=arguments.length>2&&void 0!==arguments[2]?arguments[2]:Float64Array,i=arguments.length>3?arguments[3]:void 0;if(isNaN(t)||t<0)throw Error("Unpexpected numItems value: ".concat(t,"."));this.numItems=+t,this.nodeSize=Math.min(Math.max(+e,2),65535),this.ArrayType=s,this.IndexArrayType=t<65536?Uint16Array:Uint32Array;var n=tb.indexOf(this.ArrayType),o=2*t*this.ArrayType.BYTES_PER_ELEMENT,r=t*this.IndexArrayType.BYTES_PER_ELEMENT,a=(8-r%8)%8;if(n<0)throw Error("Unexpected typed array class: ".concat(s,"."));i&&i instanceof ArrayBuffer?(this.data=i,this.ids=new this.IndexArrayType(this.data,8,t),this.coords=new this.ArrayType(this.data,8+r+a,2*t),this._pos=2*t,this._finished=!0):(this.data=new ArrayBuffer(8+o+r+a),this.ids=new this.IndexArrayType(this.data,8,t),this.coords=new this.ArrayType(this.data,8+r+a,2*t),this._pos=0,this._finished=!1,new Uint8Array(this.data,0,2).set([219,16+n]),new Uint16Array(this.data,2,1)[0]=e,new Uint32Array(this.data,4,1)[0]=t)}}function tC(t,e,s,i){tw(t,s,i),tw(e,2*s,2*i),tw(e,2*s+1,2*i+1)}function tw(t,e,s){var i=t[e];t[e]=t[s],t[s]=i}function tM(t,e,s,i){var n=t-s,o=e-i;return n*n+o*o}var tP={minZoom:0,maxZoom:16,minPoints:2,radius:40,extent:512,nodeSize:64,log:!1,generateId:!1,reduce:null,map:t=>t},tk=Math.fround||(t=>e=>(t[0]=+e,t[0]))(new Float32Array(1));class tO{load(t){var{log:e,minZoom:s,maxZoom:i}=this.options;e&&console.time("total time");var n="prepare ".concat(t.length," points");e&&console.time(n),this.points=t;for(var o=[],r=0;r=s;d--){var g=+Date.now();u=this.trees[d]=this._createTree(this._cluster(u,d)),e&&console.log("z%d: %d clusters in %dms",d,u.numItems,+Date.now()-g)}return e&&console.timeEnd("total time"),this}getClusters(t,e){var s=((t[0]+180)%360+360)%360-180,i=Math.max(-90,Math.min(90,t[1])),n=180===t[2]?180:((t[2]+180)%360+360)%360-180,o=Math.max(-90,Math.min(90,t[3]));if(t[2]-t[0]>=360)s=-180,n=180;else if(s>n){var r=this.getClusters([s,i,180,o],e),a=this.getClusters([-180,i,n,o],e);return r.concat(a)}var h=this.trees[this._limitZoom(e)],l=h.range(tS(s),tI(o),tS(n),tI(i)),p=h.data,c=[];for(var u of l){var d=this.stride*u;c.push(p[d+5]>1?tL(p,d,this.clusterProps):this.points[p[d+3]])}return c}getChildren(t){var e=this._getOriginId(t),s=this._getOriginZoom(t),i="No cluster with the specified id.",n=this.trees[s];if(!n)throw Error(i);var o=n.data;if(e*this.stride>=o.length)throw Error(i);var r=this.options.radius/(this.options.extent*Math.pow(2,s-1)),a=o[e*this.stride],h=o[e*this.stride+1],l=n.within(a,h,r),p=[];for(var c of l){var u=c*this.stride;o[u+4]===t&&p.push(o[u+5]>1?tL(o,u,this.clusterProps):this.points[o[u+3]])}if(0===p.length)throw Error(i);return p}getLeaves(t,e,s){e=e||10,s=s||0;var i=[];return this._appendLeaves(i,t,e,s,0),i}getTile(t,e,s){var i=this.trees[this._limitZoom(t)],n=Math.pow(2,t),{extent:o,radius:r}=this.options,a=r/o,h=(s-a)/n,l=(s+1+a)/n,p={features:[]};return this._addTileFeatures(i.range((e-a)/n,h,(e+1+a)/n,l),i.data,e,s,n,p),0===e&&this._addTileFeatures(i.range(1-a/n,h,1,l),i.data,n,s,n,p),e===n-1&&this._addTileFeatures(i.range(0,h,a/n,l),i.data,-1,s,n,p),p.features.length?p:null}getClusterExpansionZoom(t){for(var e=this._getOriginZoom(t)-1;e<=this.options.maxZoom;){var s=this.getChildren(t);if(e++,1!==s.length)break;t=s[0].properties.cluster_id}return e}_appendLeaves(t,e,s,i,n){for(var o of this.getChildren(e)){var r=o.properties;if(r&&r.cluster?n+r.point_count<=i?n+=r.point_count:n=this._appendLeaves(t,r.cluster_id,s,i,n):n1,l=void 0,p=void 0,c=void 0;if(h)l=tE(e,a,this.clusterProps),p=e[a],c=e[a+1];else{var u=this.points[e[a+3]];l=u.properties;var[d,g]=u.geometry.coordinates;p=tS(d),c=tI(g)}var m={type:1,geometry:[[Math.round(this.options.extent*(p*n-s)),Math.round(this.options.extent*(c*n-i))]],tags:l},v=void 0;void 0!==(v=h||this.options.generateId?e[a+3]:this.points[e[a+3]].id)&&(m.id=v),o.features.push(m)}}_limitZoom(t){return Math.max(this.options.minZoom,Math.min(Math.floor(+t),this.options.maxZoom+1))}_cluster(t,e){for(var{radius:s,extent:i,reduce:n,minPoints:o}=this.options,r=s/(i*Math.pow(2,e)),a=t.data,h=[],l=this.stride,p=0;pe&&(m+=a[f+5])}if(m>g&&m>=o){var y=c*g,b=u*g,x=void 0,C=-1,w=((p/l|0)<<5)+(e+1)+this.points.length;for(var M of d){var P=M*l;if(!(a[P+2]<=e)){a[P+2]=e;var k=a[P+5];y+=a[P]*k,b+=a[P+1]*k,a[P+4]=w,n&&(x||(x=this._map(a,p,!0),C=this.clusterProps.length,this.clusterProps.push(x)),n(x,this._map(a,P)))}}a[p+4]=w,h.push(y/m,b/m,1/0,w,-1,m),n&&h.push(C)}else{for(var O=0;O1)for(var L of d){var E=L*l;if(!(a[E+2]<=e)){a[E+2]=e;for(var S=0;S>5}_getOriginZoom(t){return(t-this.points.length)%32}_map(t,e,s){if(t[e+5]>1){var i=this.clusterProps[t[e+6]];return s?Object.assign({},i):i}var n=this.points[t[e+3]].properties,o=this.options.map(n);return s&&o===n?Object.assign({},o):o}constructor(t){this.options=Object.assign(Object.create(tP),t),this.trees=Array(this.options.maxZoom+1),this.stride=this.options.reduce?7:6,this.clusterProps=[]}}function tL(t,e,s){return{type:"Feature",id:t[e+3],properties:tE(t,e,s),geometry:{type:"Point",coordinates:[(t[e]-.5)*360,360*Math.atan(Math.exp((180-360*t[e+1])*Math.PI/180))/Math.PI-90]}}}function tE(t,e,s){var i=t[e+5],n=i>=1e4?"".concat(Math.round(i/1e3),"k"):i>=1e3?"".concat(Math.round(i/100)/10,"k"):i,o=t[e+6];return Object.assign(-1===o?{}:Object.assign({},s[o]),{cluster:!0,cluster_id:t[e+3],point_count:i,point_count_abbreviated:n})}function tS(t){return t/360+.5}function tI(t){var e=Math.sin(t*Math.PI/180),s=.5-.25*Math.log((1+e)/(1-e))/Math.PI;return s<0?0:s>1?1:s}function tj(t,e){var s={};for(var i in t)Object.prototype.hasOwnProperty.call(t,i)&&0>e.indexOf(i)&&(s[i]=t[i]);if(null!=t&&"function"==typeof Object.getOwnPropertySymbols)for(var n=0,i=Object.getOwnPropertySymbols(t);ne.indexOf(i[n])&&Object.prototype.propertyIsEnumerable.call(t,i[n])&&(s[i[n]]=t[i[n]]);return s}class tD{static isAdvancedMarkerAvailable(t){return google.maps.marker&&!0===t.getMapCapabilities().isAdvancedMarkersAvailable}static isAdvancedMarker(t){return google.maps.marker&&t instanceof google.maps.marker.AdvancedMarkerElement}static setMap(t,e){this.isAdvancedMarker(t)?t.map=e:t.setMap(e)}static getPosition(t){if(this.isAdvancedMarker(t)){if(t.position){if(t.position instanceof google.maps.LatLng)return t.position;if(t.position.lat&&t.position.lng)return new google.maps.LatLng(t.position.lat,t.position.lng)}return new google.maps.LatLng(null)}return t.getPosition()}static getVisible(t){return!!this.isAdvancedMarker(t)||t.getVisible()}}class tB{get bounds(){if(0!==this.markers.length||this._position){var t=new google.maps.LatLngBounds(this._position,this._position);for(var e of this.markers)t.extend(tD.getPosition(e));return t}}get position(){return this._position||this.bounds.getCenter()}get count(){return this.markers.filter(t=>tD.getVisible(t)).length}push(t){this.markers.push(t)}delete(){this.marker&&(tD.setMap(this.marker,null),this.marker=void 0),this.markers.length=0}constructor(t){var{markers:e,position:s}=t;this.markers=e,s&&(s instanceof google.maps.LatLng?this._position=s:this._position=new google.maps.LatLng(s))}}var tT=(t,e,s,i)=>{var n=tU(t.getBounds(),e,i);return s.filter(t=>n.contains(tD.getPosition(t)))},tU=(t,e,s)=>{var{northEast:i,southWest:n}=t_(t,e);return tW(tz({northEast:i,southWest:n},s),e)},tA=(t,e,s)=>{var i=tU(t,e,s),n=i.getNorthEast(),o=i.getSouthWest();return[o.lng(),o.lat(),n.lng(),n.lat()]},tR=(t,e)=>{var s=(e.lat-t.lat)*Math.PI/180,i=(e.lng-t.lng)*Math.PI/180,n=Math.sin(s/2),o=Math.sin(i/2),r=n*n+Math.cos(t.lat*Math.PI/180)*Math.cos(e.lat*Math.PI/180)*o*o;return 2*Math.atan2(Math.sqrt(r),Math.sqrt(1-r))*6371},t_=(t,e)=>({northEast:e.fromLatLngToDivPixel(t.getNorthEast()),southWest:e.fromLatLngToDivPixel(t.getSouthWest())}),tz=(t,e)=>{var{northEast:s,southWest:i}=t;return s.x+=e,s.y-=e,i.x-=e,i.y+=e,{northEast:s,southWest:i}},tW=(t,e)=>{var{northEast:s,southWest:i}=t,n=e.fromDivPixelToLatLng(i),o=e.fromDivPixelToLatLng(s);return new google.maps.LatLngBounds(n,o)};class tZ{noop(t){var{markers:e}=t;return tN(e)}constructor(t){var{maxZoom:e=16}=t;this.maxZoom=e}}class tV extends tZ{calculate(t){var{markers:e,map:s,mapCanvasProjection:i}=t;return s.getZoom()>=this.maxZoom?{clusters:this.noop({markers:e}),changed:!1}:{clusters:this.cluster({markers:tT(s,i,e,this.viewportPadding),map:s,mapCanvasProjection:i})}}constructor(t){var{viewportPadding:e=60}=t;super(tj(t,["viewportPadding"])),this.viewportPadding=60,this.viewportPadding=e}}var tN=t=>t.map(t=>new tB({position:tD.getPosition(t),markers:[t]}));class tH extends tZ{calculate(t){var e=!1,s={zoom:t.map.getZoom()};if(!ty(t.markers,this.markers)){e=!0,this.markers=[...t.markers];var i=this.markers.map(t=>{var e=tD.getPosition(t);return{type:"Feature",geometry:{type:"Point",coordinates:[e.lng(),e.lat()]},properties:{marker:t}}});this.superCluster.load(i)}return!e&&(this.state.zoom<=this.maxZoom||s.zoom<=this.maxZoom)&&(e=!ty(this.state,s)),this.state=s,e&&(this.clusters=this.cluster(t)),{clusters:this.clusters,changed:e}}cluster(t){var{map:e}=t;return this.superCluster.getClusters([-180,-90,180,90],Math.round(e.getZoom())).map(t=>this.transformCluster(t))}transformCluster(t){var{geometry:{coordinates:[e,s]},properties:i}=t;if(i.cluster)return new tB({markers:this.superCluster.getLeaves(i.cluster_id,1/0).map(t=>t.properties.marker),position:{lat:s,lng:e}});var n=i.marker;return new tB({markers:[n],position:tD.getPosition(n)})}constructor(t){var{maxZoom:e,radius:s=60}=t,i=tj(t,["maxZoom","radius"]);super({maxZoom:e}),this.state={zoom:-1},this.superCluster=new tO(Object.assign({maxZoom:this.maxZoom,radius:s},i))}}class tF{constructor(t,e){this.markers={sum:t.length};var s=e.map(t=>t.count),i=s.reduce((t,e)=>t+e,0);this.clusters={count:e.length,markers:{mean:i/e.length,sum:i,min:Math.min(...s),max:Math.max(...s)}}}}class tG{render(t,e,s){var{count:i,position:n}=t,o=i>Math.max(10,e.clusters.markers.mean)?"#ff0000":"#0000ff",r='"),a="Cluster of ".concat(i," markers"),h=Number(google.maps.Marker.MAX_ZINDEX)+i;if(tD.isAdvancedMarkerAvailable(s)){var l=new DOMParser().parseFromString(r,"image/svg+xml").documentElement;return l.setAttribute("transform","translate(0 25)"),new google.maps.marker.AdvancedMarkerElement({map:s,position:n,zIndex:h,title:a,content:l})}var p={position:n,zIndex:h,title:a,icon:{url:"data:image/svg+xml;base64,".concat(btoa(r)),anchor:new google.maps.Point(25,25)}};return new google.maps.Marker(p)}}class tK{constructor(){!function(t,e){for(var s in e.prototype)t.prototype[s]=e.prototype[s]}(tK,google.maps.OverlayView)}}!function(t){t.CLUSTERING_BEGIN="clusteringbegin",t.CLUSTERING_END="clusteringend",t.CLUSTER_CLICK="click"}(h||(h={}));var tY=(t,e,s)=>{s.fitBounds(e.bounds)};function tq(t,e){var s=Object.keys(t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(t);e&&(i=i.filter(function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable})),s.push.apply(s,i)}return s}var tJ={onCloseClick:"closeclick",onContentChanged:"content_changed",onDomReady:"domready",onPositionChanged:"position_changed",onZindexChanged:"zindex_changed"},tX={options(t,e){t.setOptions(e)},position(t,e){t.setPosition(e)},zIndex(t,e){t.setZIndex(e)}};class t$ extends p.PureComponent{componentDidMount(){var t=new google.maps.InfoWindow(this.props.options);this.containerElement=document.createElement("div"),this.registeredEvents=x({updaterMap:tX,eventMap:tJ,prevProps:{},nextProps:this.props,instance:t}),this.setState(()=>({infoWindow:t}),this.setInfoWindowCallback)}componentDidUpdate(t){null!==this.state.infoWindow&&(b(this.registeredEvents),this.registeredEvents=x({updaterMap:tX,eventMap:tJ,prevProps:t,nextProps:this.props,instance:this.state.infoWindow}))}componentWillUnmount(){null!==this.state.infoWindow&&(b(this.registeredEvents),this.props.onUnmount&&this.props.onUnmount(this.state.infoWindow),this.state.infoWindow.close())}render(){return this.containerElement?(0,c.createPortal)(p.Children.only(this.props.children),this.containerElement):null}constructor(){super(...arguments),d(this,"registeredEvents",[]),d(this,"containerElement",null),d(this,"state",{infoWindow:null}),d(this,"open",(t,e)=>{e?t.open(this.context,e):t.getPosition()?t.open(this.context):m(!1,"You must provide either an anchor (typically render it inside a ) or a position props for .")}),d(this,"setInfoWindowCallback",()=>{null!==this.state.infoWindow&&null!==this.containerElement&&(this.state.infoWindow.setContent(this.containerElement),this.open(this.state.infoWindow,this.props.anchor),this.props.onLoad&&this.props.onLoad(this.state.infoWindow))})}}function tQ(t,e){var s=Object.keys(t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(t);e&&(i=i.filter(function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable})),s.push.apply(s,i)}return s}function t0(t){for(var e=1;e{null!==this.state.polyline&&this.props.onLoad&&this.props.onLoad(this.state.polyline)})}}function t8(t,e){var s=Object.keys(t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(t);e&&(i=i.filter(function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable})),s.push.apply(s,i)}return s}d(t3,"contextType",v);var t6={onClick:"click",onDblClick:"dblclick",onDrag:"drag",onDragEnd:"dragend",onDragStart:"dragstart",onMouseDown:"mousedown",onMouseMove:"mousemove",onMouseOut:"mouseout",onMouseOver:"mouseover",onMouseUp:"mouseup",onRightClick:"rightclick"},t5={draggable(t,e){t.setDraggable(e)},editable(t,e){t.setEditable(e)},map(t,e){t.setMap(e)},options(t,e){t.setOptions(e)},path(t,e){t.setPath(e)},paths(t,e){t.setPaths(e)},visible(t,e){t.setVisible(e)}};class t4 extends p.PureComponent{componentDidMount(){var t=this.props.options||{};this.polygon=new google.maps.Polygon(t),this.polygon.setMap(this.context),this.registeredEvents=x({updaterMap:t5,eventMap:t6,prevProps:{},nextProps:this.props,instance:this.polygon}),this.props.onLoad&&this.props.onLoad(this.polygon)}componentDidUpdate(t){this.polygon&&(b(this.registeredEvents),this.registeredEvents=x({updaterMap:t5,eventMap:t6,prevProps:t,nextProps:this.props,instance:this.polygon}))}componentWillUnmount(){this.polygon&&(this.props.onUnmount&&this.props.onUnmount(this.polygon),b(this.registeredEvents),this.polygon&&this.polygon.setMap(null))}render(){return null}constructor(){super(...arguments),d(this,"registeredEvents",[])}}function t9(t,e){var s=Object.keys(t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(t);e&&(i=i.filter(function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable})),s.push.apply(s,i)}return s}function t7(t){for(var e=1;e{null!==this.state.rectangle&&this.props.onLoad&&this.props.onLoad(this.state.rectangle)})}}function ei(t,e){var s=Object.keys(t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(t);e&&(i=i.filter(function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable})),s.push.apply(s,i)}return s}function en(t){for(var e=1;e{null!==this.state.circle&&this.props.onLoad&&this.props.onLoad(this.state.circle)})}}function eh(t,e){var s=Object.keys(t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(t);e&&(i=i.filter(function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable})),s.push.apply(s,i)}return s}function el(t){for(var e=1;e({data:t}),this.setDataCallback)}}componentDidUpdate(t){null!==this.state.data&&(b(this.registeredEvents),this.registeredEvents=x({updaterMap:ec,eventMap:ep,prevProps:t,nextProps:this.props,instance:this.state.data}))}componentWillUnmount(){null!==this.state.data&&(this.props.onUnmount&&this.props.onUnmount(this.state.data),b(this.registeredEvents),this.state.data&&this.state.data.setMap(null))}render(){return null}constructor(){super(...arguments),d(this,"registeredEvents",[]),d(this,"state",{data:null}),d(this,"setDataCallback",()=>{null!==this.state.data&&this.props.onLoad&&this.props.onLoad(this.state.data)})}}function ed(t,e){var s=Object.keys(t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(t);e&&(i=i.filter(function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable})),s.push.apply(s,i)}return s}function eg(t){for(var e=1;e{null!==this.state.kmlLayer&&this.props.onLoad&&this.props.onLoad(this.state.kmlLayer)})}}function ey(t,e){return new e(t.lat,t.lng)}function eb(t,e){return new e(new google.maps.LatLng(t.ne.lat,t.ne.lng),new google.maps.LatLng(t.sw.lat,t.sw.lng))}d(ef,"contextType",v);function ex(t,e){var s=Object.keys(t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(t);e&&(i=i.filter(function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable})),s.push.apply(s,i)}return s}function eC(t){return t?(t instanceof google.maps.LatLng?t:new google.maps.LatLng(t.lat,t.lng))+"":""}function ew(t){return t?(t instanceof google.maps.LatLngBounds?t:new google.maps.LatLngBounds(new google.maps.LatLng(t.south,t.east),new google.maps.LatLng(t.north,t.west)))+"":""}class eM extends p.PureComponent{componentDidMount(){this.overlayView.setMap(this.context)}componentDidUpdate(t){var e=eC(t.position),s=eC(this.props.position),i=ew(t.bounds),n=ew(this.props.bounds);(e!==s||i!==n)&&this.overlayView.draw(),t.mapPaneName!==this.props.mapPaneName&&this.updatePane()}componentWillUnmount(){this.overlayView.setMap(null)}render(){var t=this.state.paneEl;return t?c.createPortal((0,l.jsx)("div",{ref:this.containerRef,style:this.state.containerStyle,children:p.Children.only(this.props.children)}),t):null}constructor(t){super(t),d(this,"state",{paneEl:null,containerStyle:{position:"absolute"}}),d(this,"updatePane",()=>{var t=this.props.mapPaneName,e=this.overlayView.getPanes();m(!!t,"OverlayView requires props.mapPaneName but got %s",t),e?this.setState({paneEl:e[t]}):this.setState({paneEl:null})}),d(this,"onAdd",()=>{var t,e;this.updatePane(),null===(t=(e=this.props).onLoad)||void 0===t||t.call(e,this.overlayView)}),d(this,"onPositionElement",()=>{var t,e,s,i,n=function(t,e,s,i){var n,o,r,a,h;return void 0!==s?(o=s instanceof(n=google.maps.LatLngBounds)?s:eb(s,n),r=t&&t.fromLatLngToDivPixel(o.getNorthEast()),a=t&&t.fromLatLngToDivPixel(o.getSouthWest()),r&&a?{left:"".concat(a.x+e.x,"px"),top:"".concat(r.y+e.y,"px"),width:"".concat(r.x-a.x-e.x,"px"),height:"".concat(a.y-r.y-e.y,"px")}:{left:"-9999px",top:"-9999px"}):function(t,e,s){var i=t&&t.fromLatLngToDivPixel(s);if(i){var{x:n,y:o}=i;return{left:"".concat(n+e.x,"px"),top:"".concat(o+e.y,"px")}}return{left:"-9999px",top:"-9999px"}}(t,e,i instanceof(h=google.maps.LatLng)?i:ey(i,h))}(this.overlayView.getProjection(),function(t){for(var e=1;e{this.onPositionElement()}),d(this,"onRemove",()=>{var t,e;this.setState(()=>({paneEl:null})),null===(t=(e=this.props).onUnmount)||void 0===t||t.call(e,this.overlayView)}),this.containerRef=(0,p.createRef)();var e=new google.maps.OverlayView;e.onAdd=this.onAdd,e.draw=this.draw,e.onRemove=this.onRemove,this.overlayView=e}}function eP(t,e){var s=Object.keys(t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(t);e&&(i=i.filter(function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable})),s.push.apply(s,i)}return s}function ek(t){for(var e=1;e{null!==this.state.groundOverlay&&this.props.onLoad&&this.props.onLoad(this.state.groundOverlay)})}}function eS(t,e){var s=Object.keys(t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(t);e&&(i=i.filter(function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable})),s.push.apply(s,i)}return s}function eI(t){for(var e=1;e? %s',google.maps.visualization),m(!!this.props.data,"data property is required in HeatmapLayer %s",this.props.data);var t=new google.maps.visualization.HeatmapLayer(eI(eI({},this.props.options),{},{data:this.props.data,map:this.context}));this.registeredEvents=x({updaterMap:eD,eventMap:ej,prevProps:{},nextProps:this.props,instance:t}),this.setState(function(){return{heatmapLayer:t}},this.setHeatmapLayerCallback)}componentDidUpdate(t){b(this.registeredEvents),this.registeredEvents=x({updaterMap:eD,eventMap:ej,prevProps:t,nextProps:this.props,instance:this.state.heatmapLayer})}componentWillUnmount(){null!==this.state.heatmapLayer&&(this.props.onUnmount&&this.props.onUnmount(this.state.heatmapLayer),b(this.registeredEvents),this.state.heatmapLayer.setMap(null))}render(){return null}constructor(){super(...arguments),d(this,"registeredEvents",[]),d(this,"state",{heatmapLayer:null}),d(this,"setHeatmapLayerCallback",()=>{null!==this.state.heatmapLayer&&this.props.onLoad&&this.props.onLoad(this.state.heatmapLayer)})}}d(eB,"contextType",v);var eT={onCloseClick:"closeclick",onPanoChanged:"pano_changed",onPositionChanged:"position_changed",onPovChanged:"pov_changed",onResize:"resize",onStatusChanged:"status_changed",onVisibleChanged:"visible_changed",onZoomChanged:"zoom_changed"},eU={register(t,e,s){t.registerPanoProvider(e,s)},links(t,e){t.setLinks(e)},motionTracking(t,e){t.setMotionTracking(e)},options(t,e){t.setOptions(e)},pano(t,e){t.setPano(e)},position(t,e){t.setPosition(e)},pov(t,e){t.setPov(e)},visible(t,e){t.setVisible(e)},zoom(t,e){t.setZoom(e)}};class eA extends p.PureComponent{componentDidMount(){var t,e,s=null!==(t=null===(e=this.context)||void 0===e?void 0:e.getStreetView())&&void 0!==t?t:null;this.registeredEvents=x({updaterMap:eU,eventMap:eT,prevProps:{},nextProps:this.props,instance:s}),this.setState(()=>({streetViewPanorama:s}),this.setStreetViewPanoramaCallback)}componentDidUpdate(t){null!==this.state.streetViewPanorama&&(b(this.registeredEvents),this.registeredEvents=x({updaterMap:eU,eventMap:eT,prevProps:t,nextProps:this.props,instance:this.state.streetViewPanorama}))}componentWillUnmount(){null!==this.state.streetViewPanorama&&(this.props.onUnmount&&this.props.onUnmount(this.state.streetViewPanorama),b(this.registeredEvents),this.state.streetViewPanorama.setVisible(!1))}render(){return null}constructor(){super(...arguments),d(this,"registeredEvents",[]),d(this,"state",{streetViewPanorama:null}),d(this,"setStreetViewPanoramaCallback",()=>{null!==this.state.streetViewPanorama&&this.props.onLoad&&this.props.onLoad(this.state.streetViewPanorama)})}}d(eA,"contextType",v);class eR extends p.PureComponent{componentDidMount(){var t=new google.maps.StreetViewService;this.setState(function(){return{streetViewService:t}},this.setStreetViewServiceCallback)}componentWillUnmount(){null!==this.state.streetViewService&&this.props.onUnmount&&this.props.onUnmount(this.state.streetViewService)}render(){return null}constructor(){super(...arguments),d(this,"state",{streetViewService:null}),d(this,"setStreetViewServiceCallback",()=>{null!==this.state.streetViewService&&this.props.onLoad&&this.props.onLoad(this.state.streetViewService)})}}d(eR,"contextType",v),p.PureComponent;var e_={onDirectionsChanged:"directions_changed"},ez={directions(t,e){t.setDirections(e)},map(t,e){t.setMap(e)},options(t,e){t.setOptions(e)},panel(t,e){t.setPanel(e)},routeIndex(t,e){t.setRouteIndex(e)}};class eW extends p.PureComponent{componentDidMount(){var t=new google.maps.DirectionsRenderer(this.props.options);this.registeredEvents=x({updaterMap:ez,eventMap:e_,prevProps:{},nextProps:this.props,instance:t}),this.setState(function(){return{directionsRenderer:t}},this.setDirectionsRendererCallback)}componentDidUpdate(t){null!==this.state.directionsRenderer&&(b(this.registeredEvents),this.registeredEvents=x({updaterMap:ez,eventMap:e_,prevProps:t,nextProps:this.props,instance:this.state.directionsRenderer}))}componentWillUnmount(){null!==this.state.directionsRenderer&&(this.props.onUnmount&&this.props.onUnmount(this.state.directionsRenderer),b(this.registeredEvents),this.state.directionsRenderer&&this.state.directionsRenderer.setMap(null))}render(){return null}constructor(){super(...arguments),d(this,"registeredEvents",[]),d(this,"state",{directionsRenderer:null}),d(this,"setDirectionsRendererCallback",()=>{null!==this.state.directionsRenderer&&(this.state.directionsRenderer.setMap(this.context),this.props.onLoad&&this.props.onLoad(this.state.directionsRenderer))})}}d(eW,"contextType",v),p.PureComponent;var eZ={onPlacesChanged:"places_changed"},eV={bounds(t,e){t.setBounds(e)}};class eN extends p.PureComponent{componentDidMount(){if(m(!!google.maps.places,'You need to provide libraries={["places"]} prop to component %s',google.maps.places),null!==this.containerElement&&null!==this.containerElement.current){var t=this.containerElement.current.querySelector("input");if(null!==t){var e=new google.maps.places.SearchBox(t,this.props.options);this.registeredEvents=x({updaterMap:eV,eventMap:eZ,prevProps:{},nextProps:this.props,instance:e}),this.setState(function(){return{searchBox:e}},this.setSearchBoxCallback)}}}componentDidUpdate(t){null!==this.state.searchBox&&(b(this.registeredEvents),this.registeredEvents=x({updaterMap:eV,eventMap:eZ,prevProps:t,nextProps:this.props,instance:this.state.searchBox}))}componentWillUnmount(){null!==this.state.searchBox&&(this.props.onUnmount&&this.props.onUnmount(this.state.searchBox),b(this.registeredEvents))}render(){return(0,l.jsx)("div",{ref:this.containerElement,children:p.Children.only(this.props.children)})}constructor(){super(...arguments),d(this,"registeredEvents",[]),d(this,"containerElement",(0,p.createRef)()),d(this,"state",{searchBox:null}),d(this,"setSearchBoxCallback",()=>{null!==this.state.searchBox&&this.props.onLoad&&this.props.onLoad(this.state.searchBox)})}}d(eN,"contextType",v);var eH={onPlaceChanged:"place_changed"},eF={bounds(t,e){t.setBounds(e)},restrictions(t,e){t.setComponentRestrictions(e)},fields(t,e){t.setFields(e)},options(t,e){t.setOptions(e)},types(t,e){t.setTypes(e)}};class eG extends p.PureComponent{componentDidMount(){m(!!google.maps.places,'You need to provide libraries={["places"]} prop to component %s',google.maps.places);var t,e=null===(t=this.containerElement.current)||void 0===t?void 0:t.querySelector("input");if(e){var s=new google.maps.places.Autocomplete(e,this.props.options);this.registeredEvents=x({updaterMap:eF,eventMap:eH,prevProps:{},nextProps:this.props,instance:s}),this.setState(()=>({autocomplete:s}),this.setAutocompleteCallback)}}componentDidUpdate(t){b(this.registeredEvents),this.registeredEvents=x({updaterMap:eF,eventMap:eH,prevProps:t,nextProps:this.props,instance:this.state.autocomplete})}componentWillUnmount(){null!==this.state.autocomplete&&b(this.registeredEvents)}render(){return(0,l.jsx)("div",{ref:this.containerElement,className:this.props.className,children:p.Children.only(this.props.children)})}constructor(){super(...arguments),d(this,"registeredEvents",[]),d(this,"containerElement",(0,p.createRef)()),d(this,"state",{autocomplete:null}),d(this,"setAutocompleteCallback",()=>{null!==this.state.autocomplete&&this.props.onLoad&&this.props.onLoad(this.state.autocomplete)})}}d(eG,"defaultProps",{className:""}),d(eG,"contextType",v)}}]);