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C,UAAU8J,SAASzH,KAAKqH,GAAGhC,MAAM,GAAI,GAAc,WAANmC,GAAkBH,EAAEjD,cAAaoD,EAAIH,EAAEjD,YAAYC,MAAM,GAAU,QAANmD,GAAqB,QAANA,EAAa,OAAOjB,MAAMmB,KAAKL,GAAI,GAAU,cAANG,GAAqB,2CAA2CG,KAAKH,GAAI,OAAOD,EAAkBF,EAAGC,EAAS,CAF7TH,CAA4Bb,EAAKvC,IACnI,WAA8B,MAAM,IAAIrB,UAAU,4IAA8I,CADvD0E,EAAoB,CAG7J,SAASG,EAAkBjB,EAAKsB,IAAkB,MAAPA,GAAeA,EAAMtB,EAAIxC,UAAQ8D,EAAMtB,EAAIxC,QAAQ,IAAK,IAAIC,EAAI,EAAG8D,EAAO,IAAItB,MAAMqB,GAAM7D,EAAI6D,EAAK7D,IAAK8D,EAAK9D,GAAKuC,EAAIvC,GAAI,OAAO8D,CAAM,CAMlL,SAAS9D,EAAEyE,EAAGnB,GACZ,IACE83B,EAAM94B,GADC,cAAEmC,GACgB,GACzB42B,EAAID,EAAI,GACRp0B,EAAIo0B,EAAI,GACR/N,GAAI,OAAE5oB,GACR,OAAO,QAAE,IAAMuC,EAAEqmB,EAAE5f,UAAU,CAAC4f,EAAGrmB,KAAM1D,IAAK+3B,CAC9C","sources":["webpack://uk-b2c/./node_modules/@react-google-maps/api/dist/esm.js","webpack://uk-b2c/./node_modules/react/cjs/react-jsx-runtime.production.min.js","webpack://uk-b2c/./node_modules/react/jsx-runtime.js","webpack://uk-b2c/./node_modules/@headlessui/react/dist/hooks/use-computed.js"],"sourcesContent":["function _createForOfIteratorHelper(o, allowArrayLike) { var it = typeof Symbol !== \"undefined\" && o[Symbol.iterator] || o[\"@@iterator\"]; if (!it) { if (Array.isArray(o) || (it = _unsupportedIterableToArray(o)) || allowArrayLike && o && typeof o.length === \"number\") { if (it) o = it; var i = 0; var F = function () {}; return { s: F, n: function () { if (i >= o.length) return { done: true }; return { done: false, value: o[i++] }; }, e: function (e) { throw e; }, f: F }; } throw new TypeError(\"Invalid attempt to iterate non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\"); } var normalCompletion = true, didErr = false, err; return { s: function () { it = it.call(o); }, n: function () { var step = it.next(); normalCompletion = step.done; return step; }, e: function (e) { didErr = true; err = e; }, f: function () { try { if (!normalCompletion && it.return != null) it.return(); } finally { if (didErr) throw err; } } }; }\nfunction _regeneratorRuntime() { \"use strict\"; /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */ _regeneratorRuntime = function () { return exports; }; var exports = {}, Op = Object.prototype, hasOwn = Op.hasOwnProperty, defineProperty = Object.defineProperty || function (obj, key, desc) { obj[key] = desc.value; }, $Symbol = \"function\" == typeof Symbol ? Symbol : {}, iteratorSymbol = $Symbol.iterator || \"@@iterator\", asyncIteratorSymbol = $Symbol.asyncIterator || \"@@asyncIterator\", toStringTagSymbol = $Symbol.toStringTag || \"@@toStringTag\"; function define(obj, key, value) { return Object.defineProperty(obj, key, { value: value, enumerable: !0, configurable: !0, writable: !0 }), obj[key]; } try { define({}, \"\"); } catch (err) { define = function (obj, key, value) { return obj[key] = value; }; } function wrap(innerFn, outerFn, self, tryLocsList) { var protoGenerator = outerFn && outerFn.prototype instanceof Generator ? outerFn : Generator, generator = Object.create(protoGenerator.prototype), context = new Context(tryLocsList || []); return defineProperty(generator, \"_invoke\", { value: makeInvokeMethod(innerFn, self, context) }), generator; } function tryCatch(fn, obj, arg) { try { return { type: \"normal\", arg: fn.call(obj, arg) }; } catch (err) { return { type: \"throw\", arg: err }; } } exports.wrap = wrap; var ContinueSentinel = {}; function Generator() {} function GeneratorFunction() {} function GeneratorFunctionPrototype() {} var IteratorPrototype = {}; define(IteratorPrototype, iteratorSymbol, function () { return this; }); var getProto = Object.getPrototypeOf, NativeIteratorPrototype = getProto && getProto(getProto(values([]))); NativeIteratorPrototype && NativeIteratorPrototype !== Op && hasOwn.call(NativeIteratorPrototype, iteratorSymbol) && (IteratorPrototype = NativeIteratorPrototype); var Gp = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(IteratorPrototype); function defineIteratorMethods(prototype) { [\"next\", \"throw\", \"return\"].forEach(function (method) { define(prototype, method, function (arg) { return this._invoke(method, arg); }); }); } function AsyncIterator(generator, PromiseImpl) { function invoke(method, arg, resolve, reject) { var record = tryCatch(generator[method], generator, arg); if (\"throw\" !== record.type) { var result = record.arg, value = result.value; return value && \"object\" == typeof value && hasOwn.call(value, \"__await\") ? PromiseImpl.resolve(value.__await).then(function (value) { invoke(\"next\", value, resolve, reject); }, function (err) { invoke(\"throw\", err, resolve, reject); }) : PromiseImpl.resolve(value).then(function (unwrapped) { result.value = unwrapped, resolve(result); }, function (error) { return invoke(\"throw\", error, resolve, reject); }); } reject(record.arg); } var previousPromise; defineProperty(this, \"_invoke\", { value: function (method, arg) { function callInvokeWithMethodAndArg() { return new PromiseImpl(function (resolve, reject) { invoke(method, arg, resolve, reject); }); } return previousPromise = previousPromise ? previousPromise.then(callInvokeWithMethodAndArg, callInvokeWithMethodAndArg) : callInvokeWithMethodAndArg(); } }); } function makeInvokeMethod(innerFn, self, context) { var state = \"suspendedStart\"; return function (method, arg) { if (\"executing\" === state) throw new Error(\"Generator is already running\"); if (\"completed\" === state) { if (\"throw\" === method) throw arg; return doneResult(); } for (context.method = method, context.arg = arg;;) { var delegate = context.delegate; if (delegate) { var delegateResult = maybeInvokeDelegate(delegate, context); if (delegateResult) { if (delegateResult === ContinueSentinel) continue; return delegateResult; } } if (\"next\" === context.method) context.sent = context._sent = context.arg;else if (\"throw\" === context.method) { if (\"suspendedStart\" === state) throw state = \"completed\", context.arg; context.dispatchException(context.arg); } else \"return\" === context.method && context.abrupt(\"return\", context.arg); state = \"executing\"; var record = tryCatch(innerFn, self, context); if (\"normal\" === record.type) { if (state = context.done ? \"completed\" : \"suspendedYield\", record.arg === ContinueSentinel) continue; return { value: record.arg, done: context.done }; } \"throw\" === record.type && (state = \"completed\", context.method = \"throw\", context.arg = record.arg); } }; } function maybeInvokeDelegate(delegate, context) { var methodName = context.method, method = delegate.iterator[methodName]; if (undefined === method) return context.delegate = null, \"throw\" === methodName && delegate.iterator.return && (context.method = \"return\", context.arg = undefined, maybeInvokeDelegate(delegate, context), \"throw\" === context.method) || \"return\" !== methodName && (context.method = \"throw\", context.arg = new TypeError(\"The iterator does not provide a '\" + methodName + \"' method\")), ContinueSentinel; var record = tryCatch(method, delegate.iterator, context.arg); if (\"throw\" === record.type) return context.method = \"throw\", context.arg = record.arg, context.delegate = null, ContinueSentinel; var info = record.arg; return info ? info.done ? (context[delegate.resultName] = info.value, context.next = delegate.nextLoc, \"return\" !== context.method && (context.method = \"next\", context.arg = undefined), context.delegate = null, ContinueSentinel) : info : (context.method = \"throw\", context.arg = new TypeError(\"iterator result is not an object\"), context.delegate = null, ContinueSentinel); } function pushTryEntry(locs) { var entry = { tryLoc: locs[0] }; 1 in locs && (entry.catchLoc = locs[1]), 2 in locs && (entry.finallyLoc = locs[2], entry.afterLoc = locs[3]), this.tryEntries.push(entry); } function resetTryEntry(entry) { var record = entry.completion || {}; record.type = \"normal\", delete record.arg, entry.completion = record; } function Context(tryLocsList) { this.tryEntries = [{ tryLoc: \"root\" }], tryLocsList.forEach(pushTryEntry, this), this.reset(!0); } function values(iterable) { if (iterable) { var iteratorMethod = iterable[iteratorSymbol]; if (iteratorMethod) return iteratorMethod.call(iterable); if (\"function\" == typeof iterable.next) return iterable; if (!isNaN(iterable.length)) { var i = -1, next = function next() { for (; ++i < iterable.length;) if (hasOwn.call(iterable, i)) return next.value = iterable[i], next.done = !1, next; return next.value = undefined, next.done = !0, next; }; return next.next = next; } } return { next: doneResult }; } function doneResult() { return { value: undefined, done: !0 }; } return GeneratorFunction.prototype = GeneratorFunctionPrototype, defineProperty(Gp, \"constructor\", { value: GeneratorFunctionPrototype, configurable: !0 }), defineProperty(GeneratorFunctionPrototype, \"constructor\", { value: GeneratorFunction, configurable: !0 }), GeneratorFunction.displayName = define(GeneratorFunctionPrototype, toStringTagSymbol, \"GeneratorFunction\"), exports.isGeneratorFunction = function (genFun) { var ctor = \"function\" == typeof genFun && genFun.constructor; return !!ctor && (ctor === GeneratorFunction || \"GeneratorFunction\" === (ctor.displayName || ctor.name)); }, exports.mark = function (genFun) { return Object.setPrototypeOf ? Object.setPrototypeOf(genFun, GeneratorFunctionPrototype) : (genFun.__proto__ = GeneratorFunctionPrototype, define(genFun, toStringTagSymbol, \"GeneratorFunction\")), genFun.prototype = Object.create(Gp), genFun; }, exports.awrap = function (arg) { return { __await: arg }; }, defineIteratorMethods(AsyncIterator.prototype), define(AsyncIterator.prototype, asyncIteratorSymbol, function () { return this; }), exports.AsyncIterator = AsyncIterator, exports.async = function (innerFn, outerFn, self, tryLocsList, PromiseImpl) { void 0 === PromiseImpl && (PromiseImpl = Promise); var iter = new AsyncIterator(wrap(innerFn, outerFn, self, tryLocsList), PromiseImpl); return exports.isGeneratorFunction(outerFn) ? iter : iter.next().then(function (result) { return result.done ? result.value : iter.next(); }); }, defineIteratorMethods(Gp), define(Gp, toStringTagSymbol, \"Generator\"), define(Gp, iteratorSymbol, function () { return this; }), define(Gp, \"toString\", function () { return \"[object Generator]\"; }), exports.keys = function (val) { var object = Object(val), keys = []; for (var key in object) keys.push(key); return keys.reverse(), function next() { for (; keys.length;) { var key = keys.pop(); if (key in object) return next.value = key, next.done = !1, next; } return next.done = !0, next; }; }, exports.values = values, Context.prototype = { constructor: Context, reset: function (skipTempReset) { if (this.prev = 0, this.next = 0, this.sent = this._sent = undefined, this.done = !1, this.delegate = null, this.method = \"next\", this.arg = undefined, this.tryEntries.forEach(resetTryEntry), !skipTempReset) for (var name in this) \"t\" === name.charAt(0) && hasOwn.call(this, name) && !isNaN(+name.slice(1)) && (this[name] = undefined); }, stop: function () { this.done = !0; var rootRecord = this.tryEntries[0].completion; if (\"throw\" === rootRecord.type) throw rootRecord.arg; return this.rval; }, dispatchException: function (exception) { if (this.done) throw exception; var context = this; function handle(loc, caught) { return record.type = \"throw\", record.arg = exception, context.next = loc, caught && (context.method = \"next\", context.arg = undefined), !!caught; } for (var i = this.tryEntries.length - 1; i >= 0; --i) { var entry = this.tryEntries[i], record = entry.completion; if (\"root\" === entry.tryLoc) return handle(\"end\"); if (entry.tryLoc <= this.prev) { var hasCatch = hasOwn.call(entry, \"catchLoc\"), hasFinally = hasOwn.call(entry, \"finallyLoc\"); if (hasCatch && hasFinally) { if (this.prev < entry.catchLoc) return handle(entry.catchLoc, !0); if (this.prev < entry.finallyLoc) return handle(entry.finallyLoc); } else if (hasCatch) { if (this.prev < entry.catchLoc) return handle(entry.catchLoc, !0); } else { if (!hasFinally) throw new Error(\"try statement without catch or finally\"); if (this.prev < entry.finallyLoc) return handle(entry.finallyLoc); } } } }, abrupt: function (type, arg) { for (var i = this.tryEntries.length - 1; i >= 0; --i) { var entry = this.tryEntries[i]; if (entry.tryLoc <= this.prev && hasOwn.call(entry, \"finallyLoc\") && this.prev < entry.finallyLoc) { var finallyEntry = entry; break; } } finallyEntry && (\"break\" === type || \"continue\" === type) && finallyEntry.tryLoc <= arg && arg <= finallyEntry.finallyLoc && (finallyEntry = null); var record = finallyEntry ? finallyEntry.completion : {}; return record.type = type, record.arg = arg, finallyEntry ? (this.method = \"next\", this.next = finallyEntry.finallyLoc, ContinueSentinel) : this.complete(record); }, complete: function (record, afterLoc) { if (\"throw\" === record.type) throw record.arg; return \"break\" === record.type || \"continue\" === record.type ? this.next = record.arg : \"return\" === record.type ? (this.rval = this.arg = record.arg, this.method = \"return\", this.next = \"end\") : \"normal\" === record.type && afterLoc && (this.next = afterLoc), ContinueSentinel; }, finish: function (finallyLoc) { for (var i = this.tryEntries.length - 1; i >= 0; --i) { var entry = this.tryEntries[i]; if (entry.finallyLoc === finallyLoc) return this.complete(entry.completion, entry.afterLoc), resetTryEntry(entry), ContinueSentinel; } }, catch: function (tryLoc) { for (var i = this.tryEntries.length - 1; i >= 0; --i) { var entry = this.tryEntries[i]; if (entry.tryLoc === tryLoc) { var record = entry.completion; if (\"throw\" === record.type) { var thrown = record.arg; resetTryEntry(entry); } return thrown; } } throw new Error(\"illegal catch attempt\"); }, delegateYield: function (iterable, resultName, nextLoc) { return this.delegate = { iterator: values(iterable), resultName: resultName, nextLoc: nextLoc }, \"next\" === this.method && (this.arg = undefined), ContinueSentinel; } }, exports; }\nfunction _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }\nfunction _nonIterableRest() { throw new TypeError(\"Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\"); }\nfunction _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === \"string\") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === \"Object\" && o.constructor) n = o.constructor.name; if (n === \"Map\" || n === \"Set\") return Array.from(o); if (n === \"Arguments\" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }\nfunction _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i]; return arr2; }\nfunction _iterableToArrayLimit(arr, i) { var _i = null == arr ? null : \"undefined\" != typeof Symbol && arr[Symbol.iterator] || arr[\"@@iterator\"]; if (null != _i) { var _s, _e, _x, _r, _arr = [], _n = !0, _d = !1; try { if (_x = (_i = _i.call(arr)).next, 0 === i) { if (Object(_i) !== _i) return; _n = !1; } else for (; !(_n = (_s = _x.call(_i)).done) && (_arr.push(_s.value), _arr.length !== i); _n = !0); } catch (err) { _d = !0, _e = err; } finally { try { if (!_n && null != _i.return && (_r = _i.return(), Object(_r) !== _r)) return; } finally { if (_d) throw _e; } } return _arr; } }\nfunction _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }\nimport { jsx, Fragment, jsxs } from 'react/jsx-runtime';\nimport * as React from 'react';\nimport { createContext, useContext, memo, useState, useRef, useEffect, PureComponent, createRef, useMemo, Children, isValidElement, cloneElement } from 'react';\nimport * as ReactDOM from 'react-dom';\nimport { createPortal } from 'react-dom';\nvar commonjsGlobal = typeof globalThis !== 'undefined' ? globalThis : typeof window !== 'undefined' ? window : typeof global !== 'undefined' ? global : typeof self !== 'undefined' ? self : {};\n\n/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n/**\n * Use invariant() to assert state which your program assumes to be true.\n *\n * Provide sprintf-style format (only %s is supported) and arguments\n * to provide information about what broke and what you were\n * expecting.\n *\n * The invariant message will be stripped in production, but the invariant\n * will remain to ensure logic does not differ in production.\n */\n\nvar NODE_ENV = process.env.NODE_ENV;\nvar invariant = function (condition, format, a, b, c, d, e, f) {\n if (NODE_ENV !== 'production') {\n if (format === undefined) {\n throw new Error('invariant requires an error message argument');\n }\n }\n if (!condition) {\n var error;\n if (format === undefined) {\n error = new Error('Minified exception occurred; use the non-minified dev environment ' + 'for the full error message and additional helpful warnings.');\n } else {\n var args = [a, b, c, d, e, f];\n var argIndex = 0;\n error = new Error(format.replace(/%s/g, function () {\n return args[argIndex++];\n }));\n error.name = 'Invariant Violation';\n }\n error.framesToPop = 1; // we don't care about invariant's own frame\n throw error;\n }\n};\nvar invariant_1 = invariant;\nconst MapContext = /*#__PURE__*/createContext(null);\nfunction useGoogleMap() {\n invariant_1(!!useContext, 'useGoogleMap is React hook and requires React version 16.8+');\n const map = useContext(MapContext);\n invariant_1(!!map, 'useGoogleMap needs a GoogleMap available up in the tree');\n return map;\n}\n\n// eslint-disable-next-line @typescript-eslint/no-explicit-any\nfunction reduce(obj, fn, acc) {\n return Object.keys(obj).reduce(function reducer(newAcc, key) {\n return fn(newAcc, obj[key], key);\n }, acc);\n}\n\n// eslint-disable-next-line @typescript-eslint/no-explicit-any\nfunction forEach(obj, fn) {\n Object.keys(obj).forEach(key => {\n return fn(obj[key], key);\n });\n}\n\n/* global google */\nfunction applyUpdaterToNextProps(\n// eslint-disable-next-line @typescript-eslint/no-explicit-any\nupdaterMap,\n// eslint-disable-next-line @typescript-eslint/no-explicit-any\nprevProps,\n// eslint-disable-next-line @typescript-eslint/no-explicit-any\nnextProps,\n// eslint-disable-next-line @typescript-eslint/no-explicit-any\ninstance\n// eslint-disable-next-line @typescript-eslint/no-explicit-any\n) {\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n const map = {};\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n const iter = (fn, key) => {\n const nextValue = nextProps[key];\n if (nextValue !== prevProps[key]) {\n map[key] = nextValue;\n fn(instance, nextValue);\n }\n };\n forEach(updaterMap, iter);\n return map;\n}\nfunction registerEvents(\n// eslint-disable-next-line @typescript-eslint/no-explicit-any\nprops,\n// eslint-disable-next-line @typescript-eslint/no-explicit-any\ninstance, eventMap) {\n const registeredList = reduce(eventMap, function reducer(acc, googleEventName,\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n onEventName) {\n if (typeof props[onEventName] === 'function') {\n acc.push(google.maps.event.addListener(instance, googleEventName, props[onEventName]));\n }\n return acc;\n }, []);\n return registeredList;\n}\nfunction unregisterEvent(registered) {\n google.maps.event.removeListener(registered);\n}\nfunction unregisterEvents() {\n let events = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : [];\n events.forEach(unregisterEvent);\n}\nfunction applyUpdatersToPropsAndRegisterEvents(_ref) {\n let updaterMap = _ref.updaterMap,\n eventMap = _ref.eventMap,\n prevProps = _ref.prevProps,\n nextProps = _ref.nextProps,\n instance = _ref.instance;\n const registeredEvents = registerEvents(nextProps, instance, eventMap);\n applyUpdaterToNextProps(updaterMap, prevProps, nextProps, instance);\n return registeredEvents;\n}\nconst eventMap$i = {\n onDblClick: 'dblclick',\n onDragEnd: 'dragend',\n onDragStart: 'dragstart',\n onMapTypeIdChanged: 'maptypeid_changed',\n onMouseMove: 'mousemove',\n onMouseOut: 'mouseout',\n onMouseOver: 'mouseover',\n onMouseDown: 'mousedown',\n onMouseUp: 'mouseup',\n onRightClick: 'rightclick',\n onTilesLoaded: 'tilesloaded',\n onBoundsChanged: 'bounds_changed',\n onCenterChanged: 'center_changed',\n onClick: 'click',\n onDrag: 'drag',\n onHeadingChanged: 'heading_changed',\n onIdle: 'idle',\n onProjectionChanged: 'projection_changed',\n onResize: 'resize',\n onTiltChanged: 'tilt_changed',\n onZoomChanged: 'zoom_changed'\n};\nconst updaterMap$i = {\n extraMapTypes(map, extra) {\n extra.forEach(function forEachExtra(it, i) {\n map.mapTypes.set(String(i), it);\n });\n },\n center(map, center) {\n map.setCenter(center);\n },\n clickableIcons(map, clickable) {\n map.setClickableIcons(clickable);\n },\n heading(map, heading) {\n map.setHeading(heading);\n },\n mapTypeId(map, mapTypeId) {\n map.setMapTypeId(mapTypeId);\n },\n options(map, options) {\n map.setOptions(options);\n },\n streetView(map, streetView) {\n map.setStreetView(streetView);\n },\n tilt(map, tilt) {\n map.setTilt(tilt);\n },\n zoom(map, zoom) {\n map.setZoom(zoom);\n }\n};\n// TODO: unfinished!\nfunction GoogleMapFunctional(_ref2) {\n let children = _ref2.children,\n options = _ref2.options,\n id = _ref2.id,\n mapContainerStyle = _ref2.mapContainerStyle,\n mapContainerClassName = _ref2.mapContainerClassName,\n center = _ref2.center,\n onClick = _ref2.onClick,\n onDblClick = _ref2.onDblClick,\n onDrag = _ref2.onDrag,\n onDragEnd = _ref2.onDragEnd,\n onDragStart = _ref2.onDragStart,\n onMouseMove = _ref2.onMouseMove,\n onMouseOut = _ref2.onMouseOut,\n onMouseOver = _ref2.onMouseOver,\n onMouseDown = _ref2.onMouseDown,\n onMouseUp = _ref2.onMouseUp,\n onRightClick = _ref2.onRightClick,\n onCenterChanged = _ref2.onCenterChanged,\n onLoad = _ref2.onLoad,\n onUnmount = _ref2.onUnmount;\n const _useState = useState(null),\n _useState2 = _slicedToArray(_useState, 2),\n map = _useState2[0],\n setMap = _useState2[1];\n const ref = useRef(null);\n // const [extraMapTypesListener, setExtraMapTypesListener] = useState(null)\n const _useState3 = useState(null),\n _useState4 = _slicedToArray(_useState3, 2),\n centerChangedListener = _useState4[0],\n setCenterChangedListener = _useState4[1];\n const _useState5 = useState(null),\n _useState6 = _slicedToArray(_useState5, 2),\n dblclickListener = _useState6[0],\n setDblclickListener = _useState6[1];\n const _useState7 = useState(null),\n _useState8 = _slicedToArray(_useState7, 2),\n dragendListener = _useState8[0],\n setDragendListener = _useState8[1];\n const _useState9 = useState(null),\n _useState10 = _slicedToArray(_useState9, 2),\n dragstartListener = _useState10[0],\n setDragstartListener = _useState10[1];\n const _useState11 = useState(null),\n _useState12 = _slicedToArray(_useState11, 2),\n mousedownListener = _useState12[0],\n setMousedownListener = _useState12[1];\n const _useState13 = useState(null),\n _useState14 = _slicedToArray(_useState13, 2),\n mousemoveListener = _useState14[0],\n setMousemoveListener = _useState14[1];\n const _useState15 = useState(null),\n _useState16 = _slicedToArray(_useState15, 2),\n mouseoutListener = _useState16[0],\n setMouseoutListener = _useState16[1];\n const _useState17 = useState(null),\n _useState18 = _slicedToArray(_useState17, 2),\n mouseoverListener = _useState18[0],\n setMouseoverListener = _useState18[1];\n const _useState19 = useState(null),\n _useState20 = _slicedToArray(_useState19, 2),\n mouseupListener = _useState20[0],\n setMouseupListener = _useState20[1];\n const _useState21 = useState(null),\n _useState22 = _slicedToArray(_useState21, 2),\n rightclickListener = _useState22[0],\n setRightclickListener = _useState22[1];\n const _useState23 = useState(null),\n _useState24 = _slicedToArray(_useState23, 2),\n clickListener = _useState24[0],\n setClickListener = _useState24[1];\n const _useState25 = useState(null),\n _useState26 = _slicedToArray(_useState25, 2),\n dragListener = _useState26[0],\n setDragListener = _useState26[1];\n // Order does matter\n useEffect(() => {\n if (options && map !== null) {\n map.setOptions(options);\n }\n }, [map, options]);\n useEffect(() => {\n if (map !== null && typeof center !== 'undefined') {\n map.setCenter(center);\n }\n }, [map, center]);\n useEffect(() => {\n if (map && onDblClick) {\n if (dblclickListener !== null) {\n google.maps.event.removeListener(dblclickListener);\n }\n setDblclickListener(google.maps.event.addListener(map, 'dblclick', onDblClick));\n }\n }, [onDblClick]);\n useEffect(() => {\n if (map && onDragEnd) {\n if (dragendListener !== null) {\n google.maps.event.removeListener(dragendListener);\n }\n setDragendListener(google.maps.event.addListener(map, 'dragend', onDragEnd));\n }\n }, [onDragEnd]);\n useEffect(() => {\n if (map && onDragStart) {\n if (dragstartListener !== null) {\n google.maps.event.removeListener(dragstartListener);\n }\n setDragstartListener(google.maps.event.addListener(map, 'dragstart', onDragStart));\n }\n }, [onDragStart]);\n useEffect(() => {\n if (map && onMouseDown) {\n if (mousedownListener !== null) {\n google.maps.event.removeListener(mousedownListener);\n }\n setMousedownListener(google.maps.event.addListener(map, 'mousedown', onMouseDown));\n }\n }, [onMouseDown]);\n useEffect(() => {\n if (map && onMouseMove) {\n if (mousemoveListener !== null) {\n google.maps.event.removeListener(mousemoveListener);\n }\n setMousemoveListener(google.maps.event.addListener(map, 'mousemove', onMouseMove));\n }\n }, [onMouseMove]);\n useEffect(() => {\n if (map && onMouseOut) {\n if (mouseoutListener !== null) {\n google.maps.event.removeListener(mouseoutListener);\n }\n setMouseoutListener(google.maps.event.addListener(map, 'mouseout', onMouseOut));\n }\n }, [onMouseOut]);\n useEffect(() => {\n if (map && onMouseOver) {\n if (mouseoverListener !== null) {\n google.maps.event.removeListener(mouseoverListener);\n }\n setMouseoverListener(google.maps.event.addListener(map, 'mouseover', onMouseOver));\n }\n }, [onMouseOver]);\n useEffect(() => {\n if (map && onMouseUp) {\n if (mouseupListener !== null) {\n google.maps.event.removeListener(mouseupListener);\n }\n setMouseupListener(google.maps.event.addListener(map, 'mouseup', onMouseUp));\n }\n }, [onMouseUp]);\n useEffect(() => {\n if (map && onRightClick) {\n if (rightclickListener !== null) {\n google.maps.event.removeListener(rightclickListener);\n }\n setRightclickListener(google.maps.event.addListener(map, 'rightclick', onRightClick));\n }\n }, [onRightClick]);\n useEffect(() => {\n if (map && onClick) {\n if (clickListener !== null) {\n google.maps.event.removeListener(clickListener);\n }\n setClickListener(google.maps.event.addListener(map, 'click', onClick));\n }\n }, [onClick]);\n useEffect(() => {\n if (map && onDrag) {\n if (dragListener !== null) {\n google.maps.event.removeListener(dragListener);\n }\n setDragListener(google.maps.event.addListener(map, 'drag', onDrag));\n }\n }, [onDrag]);\n useEffect(() => {\n if (map && onCenterChanged) {\n if (centerChangedListener !== null) {\n google.maps.event.removeListener(centerChangedListener);\n }\n setCenterChangedListener(google.maps.event.addListener(map, 'center_changed', onCenterChanged));\n }\n }, [onClick]);\n useEffect(() => {\n const map = ref.current === null ? null : new google.maps.Map(ref.current, options);\n setMap(map);\n if (map !== null && onLoad) {\n onLoad(map);\n }\n return () => {\n if (map !== null) {\n if (onUnmount) {\n onUnmount(map);\n }\n }\n };\n }, []);\n return jsx(\"div\", Object.assign({\n id: id,\n ref: ref,\n style: mapContainerStyle,\n className: mapContainerClassName\n }, {\n children: jsx(MapContext.Provider, Object.assign({\n value: map\n }, {\n children: map !== null ? children : jsx(Fragment, {})\n }))\n }));\n}\n/*#__PURE__*/memo(GoogleMapFunctional);\nclass GoogleMap extends PureComponent {\n constructor() {\n super(...arguments);\n this.state = {\n map: null\n };\n this.registeredEvents = [];\n this.mapRef = null;\n this.getInstance = () => {\n if (this.mapRef === null) {\n return null;\n }\n return new google.maps.Map(this.mapRef, this.props.options);\n };\n this.panTo = latLng => {\n const map = this.getInstance();\n if (map) {\n map.panTo(latLng);\n }\n };\n this.setMapCallback = () => {\n if (this.state.map !== null) {\n if (this.props.onLoad) {\n this.props.onLoad(this.state.map);\n }\n }\n };\n this.getRef = ref => {\n this.mapRef = ref;\n };\n }\n componentDidMount() {\n const map = this.getInstance();\n this.registeredEvents = applyUpdatersToPropsAndRegisterEvents({\n updaterMap: updaterMap$i,\n eventMap: eventMap$i,\n prevProps: {},\n nextProps: this.props,\n instance: map\n });\n this.setState(function setMap() {\n return {\n map\n };\n }, this.setMapCallback);\n }\n componentDidUpdate(prevProps) {\n if (this.state.map !== null) {\n unregisterEvents(this.registeredEvents);\n this.registeredEvents = applyUpdatersToPropsAndRegisterEvents({\n updaterMap: updaterMap$i,\n eventMap: eventMap$i,\n prevProps,\n nextProps: this.props,\n instance: this.state.map\n });\n }\n }\n componentWillUnmount() {\n if (this.state.map !== null) {\n if (this.props.onUnmount) {\n this.props.onUnmount(this.state.map);\n }\n unregisterEvents(this.registeredEvents);\n }\n }\n render() {\n return jsx(\"div\", Object.assign({\n id: this.props.id,\n ref: this.getRef,\n style: this.props.mapContainerStyle,\n className: this.props.mapContainerClassName\n }, {\n children: jsx(MapContext.Provider, Object.assign({\n value: this.state.map\n }, {\n children: this.state.map !== null ? this.props.children : jsx(Fragment, {})\n }))\n }));\n }\n}\n\n/*! *****************************************************************************\r\nCopyright (c) Microsoft Corporation.\r\n\r\nPermission to use, copy, modify, and/or distribute this software for any\r\npurpose with or without fee is hereby granted.\r\n\r\nTHE SOFTWARE IS PROVIDED \"AS IS\" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH\r\nREGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY\r\nAND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,\r\nINDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM\r\nLOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR\r\nOTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR\r\nPERFORMANCE OF THIS SOFTWARE.\r\n***************************************************************************** */\n\nfunction __rest$1(s, e) {\n var t = {};\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) t[p] = s[p];\n if (s != null && typeof Object.getOwnPropertySymbols === \"function\") for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {\n if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i])) t[p[i]] = s[p[i]];\n }\n return t;\n}\nfunction __awaiter(thisArg, _arguments, P, generator) {\n function adopt(value) {\n return value instanceof P ? value : new P(function (resolve) {\n resolve(value);\n });\n }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) {\n try {\n step(generator.next(value));\n } catch (e) {\n reject(e);\n }\n }\n function rejected(value) {\n try {\n step(generator[\"throw\"](value));\n } catch (e) {\n reject(e);\n }\n }\n function step(result) {\n result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected);\n }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n}\nconst isBrowser = typeof document !== 'undefined';\nfunction injectScript(_ref3) {\n let url = _ref3.url,\n id = _ref3.id,\n nonce = _ref3.nonce;\n if (!isBrowser) {\n return Promise.reject(new Error('document is undefined'));\n }\n return new Promise(function injectScriptCallback(resolve, reject) {\n const existingScript = document.getElementById(id);\n const windowWithGoogleMap = window;\n if (existingScript) {\n // Same script id/url: keep same script\n const dataStateAttribute = existingScript.getAttribute('data-state');\n if (existingScript.src === url && dataStateAttribute !== 'error') {\n if (dataStateAttribute === 'ready') {\n return resolve(id);\n } else {\n const originalInitMap = windowWithGoogleMap.initMap;\n const originalErrorCallback = existingScript.onerror;\n windowWithGoogleMap.initMap = function initMap() {\n if (originalInitMap) {\n originalInitMap();\n }\n resolve(id);\n };\n existingScript.onerror = function (err) {\n if (originalErrorCallback) {\n originalErrorCallback(err);\n }\n reject(err);\n };\n return;\n }\n }\n // Same script id, but either\n // 1. requested URL is different\n // 2. script failed to load\n else {\n existingScript.remove();\n }\n }\n const script = document.createElement('script');\n script.type = 'text/javascript';\n script.src = url;\n script.id = id;\n script.async = true;\n script.nonce = nonce;\n script.onerror = function onerror(err) {\n script.setAttribute('data-state', 'error');\n reject(err);\n };\n windowWithGoogleMap.initMap = function onload() {\n script.setAttribute('data-state', 'ready');\n resolve(id);\n };\n document.head.appendChild(script);\n }).catch(err => {\n console.error('injectScript error: ', err);\n throw err;\n });\n}\nfunction isGoogleFontStyle(element) {\n // 'Roboto' or 'Google Sans Text' font download\n const href = element.href;\n if (href && (href.indexOf('https://fonts.googleapis.com/css?family=Roboto') === 0 || href.indexOf('https://fonts.googleapis.com/css?family=Google+Sans+Text') === 0)) {\n return true;\n }\n // font style elements\n if (element.tagName.toLowerCase() === 'style' &&\n // @ts-ignore\n element.styleSheet &&\n // @ts-ignore\n element.styleSheet.cssText &&\n // @ts-ignore\n element.styleSheet.cssText.replace('\\r\\n', '').indexOf('.gm-style') === 0) {\n // @ts-ignore\n element.styleSheet.cssText = '';\n return true;\n }\n // font style elements for other browsers\n if (element.tagName.toLowerCase() === 'style' && element.innerHTML && element.innerHTML.replace('\\r\\n', '').indexOf('.gm-style') === 0) {\n element.innerHTML = '';\n return true;\n }\n // when google tries to add empty style\n if (element.tagName.toLowerCase() === 'style' &&\n // @ts-ignore\n !element.styleSheet && !element.innerHTML) {\n return true;\n }\n return false;\n}\n// Preventing the Google Maps library from downloading an extra font\nfunction preventGoogleFonts() {\n // we override these methods only for one particular head element\n // default methods for other elements are not affected\n const head = document.getElementsByTagName('head')[0];\n const trueInsertBefore = head.insertBefore.bind(head);\n // TODO: adding return before reflect solves the TS issue\n // @ts-ignore\n head.insertBefore = function insertBefore(newElement, referenceElement) {\n if (!isGoogleFontStyle(newElement)) {\n Reflect.apply(trueInsertBefore, head, [newElement, referenceElement]);\n }\n };\n const trueAppend = head.appendChild.bind(head);\n // TODO: adding return before reflect solves the TS issue\n // @ts-ignore\n head.appendChild = function appendChild(textNode) {\n if (!isGoogleFontStyle(textNode)) {\n Reflect.apply(trueAppend, head, [textNode]);\n }\n };\n}\nfunction makeLoadScriptUrl(_ref4) {\n let googleMapsApiKey = _ref4.googleMapsApiKey,\n googleMapsClientId = _ref4.googleMapsClientId,\n _ref4$version = _ref4.version,\n version = _ref4$version === void 0 ? 'weekly' : _ref4$version,\n language = _ref4.language,\n region = _ref4.region,\n libraries = _ref4.libraries,\n channel = _ref4.channel,\n mapIds = _ref4.mapIds,\n authReferrerPolicy = _ref4.authReferrerPolicy;\n const params = [];\n invariant_1(googleMapsApiKey && googleMapsClientId || !(googleMapsApiKey && googleMapsClientId), '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.');\n if (googleMapsApiKey) {\n params.push(`key=${googleMapsApiKey}`);\n } else if (googleMapsClientId) {\n params.push(`client=${googleMapsClientId}`);\n }\n if (version) {\n params.push(`v=${version}`);\n }\n if (language) {\n params.push(`language=${language}`);\n }\n if (region) {\n params.push(`region=${region}`);\n }\n if (libraries && libraries.length) {\n params.push(`libraries=${libraries.sort().join(',')}`);\n }\n if (channel) {\n params.push(`channel=${channel}`);\n }\n if (mapIds && mapIds.length) {\n params.push(`map_ids=${mapIds.join(',')}`);\n }\n if (authReferrerPolicy) {\n params.push(`auth_referrer_policy=${authReferrerPolicy}`);\n }\n params.push('callback=initMap');\n return `https://maps.googleapis.com/maps/api/js?${params.join('&')}`;\n}\nlet cleaningUp = false;\nfunction DefaultLoadingElement() {\n return jsx(\"div\", {\n children: `Loading...`\n });\n}\nconst defaultLoadScriptProps = {\n id: 'script-loader',\n version: 'weekly'\n};\nclass LoadScript extends PureComponent {\n constructor() {\n super(...arguments);\n this.check = /*#__PURE__*/createRef();\n this.state = {\n loaded: false\n };\n this.cleanupCallback = () => {\n // @ts-ignore\n delete window.google.maps;\n this.injectScript();\n };\n this.isCleaningUp = () => __awaiter(this, void 0, void 0, /*#__PURE__*/_regeneratorRuntime().mark(function _callee() {\n var promiseCallback;\n return _regeneratorRuntime().wrap(function _callee$(_context) {\n while (1) switch (_context.prev = _context.next) {\n case 0:\n promiseCallback = function _promiseCallback(resolve) {\n if (!cleaningUp) {\n resolve();\n } else {\n if (isBrowser) {\n const timer = window.setInterval(function interval() {\n if (!cleaningUp) {\n window.clearInterval(timer);\n resolve();\n }\n }, 1);\n }\n }\n return;\n };\n return _context.abrupt(\"return\", new Promise(promiseCallback));\n case 2:\n case \"end\":\n return _context.stop();\n }\n }, _callee);\n }));\n this.cleanup = () => {\n cleaningUp = true;\n const script = document.getElementById(this.props.id);\n if (script && script.parentNode) {\n script.parentNode.removeChild(script);\n }\n Array.prototype.slice.call(document.getElementsByTagName('script')).filter(function filter(script) {\n return typeof script.src === 'string' && script.src.includes('maps.googleapis');\n }).forEach(function forEach(script) {\n if (script.parentNode) {\n script.parentNode.removeChild(script);\n }\n });\n Array.prototype.slice.call(document.getElementsByTagName('link')).filter(function filter(link) {\n return link.href === 'https://fonts.googleapis.com/css?family=Roboto:300,400,500,700|Google+Sans';\n }).forEach(function forEach(link) {\n if (link.parentNode) {\n link.parentNode.removeChild(link);\n }\n });\n Array.prototype.slice.call(document.getElementsByTagName('style')).filter(function filter(style) {\n return style.innerText !== undefined && style.innerText.length > 0 && style.innerText.includes('.gm-');\n }).forEach(function forEach(style) {\n if (style.parentNode) {\n style.parentNode.removeChild(style);\n }\n });\n };\n this.injectScript = () => {\n if (this.props.preventGoogleFontsLoading) {\n preventGoogleFonts();\n }\n invariant_1(!!this.props.id, 'LoadScript requires \"id\" prop to be a string: %s', this.props.id);\n const injectScriptOptions = {\n id: this.props.id,\n nonce: this.props.nonce,\n url: makeLoadScriptUrl(this.props)\n };\n injectScript(injectScriptOptions).then(() => {\n if (this.props.onLoad) {\n this.props.onLoad();\n }\n this.setState(function setLoaded() {\n return {\n loaded: true\n };\n });\n return;\n }).catch(err => {\n if (this.props.onError) {\n this.props.onError(err);\n }\n console.error(`\n There has been an Error with loading Google Maps API script, please check that you provided correct google API key (${this.props.googleMapsApiKey || '-'}) or Client ID (${this.props.googleMapsClientId || '-'}) to \n Otherwise it is a Network issue.\n `);\n });\n };\n }\n componentDidMount() {\n if (isBrowser) {\n if (window.google && window.google.maps && !cleaningUp) {\n console.error('google api is already presented');\n return;\n }\n this.isCleaningUp().then(this.injectScript).catch(function error(err) {\n console.error('Error at injecting script after cleaning up: ', err);\n });\n }\n }\n componentDidUpdate(prevProps) {\n if (this.props.libraries !== prevProps.libraries) {\n 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');\n }\n if (isBrowser && prevProps.language !== this.props.language) {\n this.cleanup();\n // TODO: refactor to use gDSFP maybe... wait for hooks refactoring.\n // eslint-disable-next-line react/no-did-update-set-state\n this.setState(function setLoaded() {\n return {\n loaded: false\n };\n }, this.cleanupCallback);\n }\n }\n componentWillUnmount() {\n if (isBrowser) {\n this.cleanup();\n const timeoutCallback = () => {\n if (!this.check.current) {\n // @ts-ignore\n delete window.google;\n cleaningUp = false;\n }\n };\n window.setTimeout(timeoutCallback, 1);\n if (this.props.onUnmount) {\n this.props.onUnmount();\n }\n }\n }\n render() {\n return jsxs(Fragment, {\n children: [jsx(\"div\", {\n ref: this.check\n }), this.state.loaded ? this.props.children : this.props.loadingElement || jsx(DefaultLoadingElement, {})]\n });\n }\n}\nLoadScript.defaultProps = defaultLoadScriptProps;\n\n/* eslint-disable filenames/match-regex */\nlet previouslyLoadedUrl;\nfunction useLoadScript(_ref5) {\n let _ref5$id = _ref5.id,\n id = _ref5$id === void 0 ? defaultLoadScriptProps.id : _ref5$id,\n _ref5$version = _ref5.version,\n version = _ref5$version === void 0 ? defaultLoadScriptProps.version : _ref5$version,\n nonce = _ref5.nonce,\n googleMapsApiKey = _ref5.googleMapsApiKey,\n googleMapsClientId = _ref5.googleMapsClientId,\n language = _ref5.language,\n region = _ref5.region,\n libraries = _ref5.libraries,\n preventGoogleFontsLoading = _ref5.preventGoogleFontsLoading,\n channel = _ref5.channel,\n mapIds = _ref5.mapIds,\n authReferrerPolicy = _ref5.authReferrerPolicy;\n const isMounted = useRef(false);\n const _useState27 = useState(false),\n _useState28 = _slicedToArray(_useState27, 2),\n isLoaded = _useState28[0],\n setLoaded = _useState28[1];\n const _useState29 = useState(undefined),\n _useState30 = _slicedToArray(_useState29, 2),\n loadError = _useState30[0],\n setLoadError = _useState30[1];\n useEffect(function trackMountedState() {\n isMounted.current = true;\n return () => {\n isMounted.current = false;\n };\n }, []);\n useEffect(function applyPreventGoogleFonts() {\n if (isBrowser && preventGoogleFontsLoading) {\n preventGoogleFonts();\n }\n }, [preventGoogleFontsLoading]);\n useEffect(function validateLoadedState() {\n if (isLoaded) {\n invariant_1(!!window.google, 'useLoadScript was marked as loaded, but window.google is not present. Something went wrong.');\n }\n }, [isLoaded]);\n const url = makeLoadScriptUrl({\n version,\n googleMapsApiKey,\n googleMapsClientId,\n language,\n region,\n libraries,\n channel,\n mapIds,\n authReferrerPolicy\n });\n useEffect(function loadScriptAndModifyLoadedState() {\n if (!isBrowser) {\n return;\n }\n function setLoadedIfMounted() {\n if (isMounted.current) {\n setLoaded(true);\n previouslyLoadedUrl = url;\n }\n }\n if (window.google && window.google.maps && previouslyLoadedUrl === url) {\n setLoadedIfMounted();\n return;\n }\n injectScript({\n id,\n url,\n nonce\n }).then(setLoadedIfMounted).catch(function handleInjectError(err) {\n if (isMounted.current) {\n setLoadError(err);\n }\n console.warn(`\n There has been an Error with loading Google Maps API script, please check that you provided correct google API key (${googleMapsApiKey || '-'}) or Client ID (${googleMapsClientId || '-'})\n Otherwise it is a Network issue.\n `);\n console.error(err);\n });\n }, [id, url, nonce]);\n const prevLibraries = useRef();\n useEffect(function checkPerformance() {\n if (prevLibraries.current && libraries !== prevLibraries.current) {\n 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');\n }\n prevLibraries.current = libraries;\n }, [libraries]);\n return {\n isLoaded,\n loadError,\n url\n };\n}\nconst defaultLoadingElement = jsx(DefaultLoadingElement, {});\nfunction LoadScriptNext(_a) {\n var loadingElement = _a.loadingElement,\n onLoad = _a.onLoad,\n onError = _a.onError,\n onUnmount = _a.onUnmount,\n children = _a.children,\n hookOptions = __rest$1(_a, [\"loadingElement\", \"onLoad\", \"onError\", \"onUnmount\", \"children\"]);\n const _useLoadScript = useLoadScript(hookOptions),\n isLoaded = _useLoadScript.isLoaded,\n loadError = _useLoadScript.loadError;\n useEffect(function handleOnLoad() {\n if (isLoaded && typeof onLoad === 'function') {\n onLoad();\n }\n }, [isLoaded, onLoad]);\n useEffect(function handleOnError() {\n if (loadError && typeof onError === 'function') {\n onError(loadError);\n }\n }, [loadError, onError]);\n useEffect(function handleOnUnmount() {\n return () => {\n if (onUnmount) {\n onUnmount();\n }\n };\n }, [onUnmount]);\n return isLoaded ? children : loadingElement || defaultLoadingElement;\n}\nvar LoadScriptNext$1 = /*#__PURE__*/memo(LoadScriptNext);\n\n// do not edit .js files directly - edit src/index.jst\n\nvar fastDeepEqual$1 = function equal(a, b) {\n if (a === b) return true;\n if (a && b && typeof a == 'object' && typeof b == 'object') {\n if (a.constructor !== b.constructor) return false;\n var length, i, keys;\n if (Array.isArray(a)) {\n length = a.length;\n if (length != b.length) return false;\n for (i = length; i-- !== 0;) if (!equal(a[i], b[i])) return false;\n return true;\n }\n if (a.constructor === RegExp) return a.source === b.source && a.flags === b.flags;\n if (a.valueOf !== Object.prototype.valueOf) return a.valueOf() === b.valueOf();\n if (a.toString !== Object.prototype.toString) return a.toString() === b.toString();\n keys = Object.keys(a);\n length = keys.length;\n if (length !== Object.keys(b).length) return false;\n for (i = length; i-- !== 0;) if (!Object.prototype.hasOwnProperty.call(b, keys[i])) return false;\n for (i = length; i-- !== 0;) {\n var key = keys[i];\n if (!equal(a[key], b[key])) return false;\n }\n return true;\n }\n\n // true if both NaN, false otherwise\n return a !== a && b !== b;\n};\n\n/**\n * Copyright 2019 Google LLC. All Rights Reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at.\n *\n * Http://www.apache.org/licenses/LICENSE-2.0.\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nconst DEFAULT_ID = \"__googleMapsScriptId\";\n/**\n * The status of the [[Loader]].\n */\nvar LoaderStatus;\n(function (LoaderStatus) {\n LoaderStatus[LoaderStatus[\"INITIALIZED\"] = 0] = \"INITIALIZED\";\n LoaderStatus[LoaderStatus[\"LOADING\"] = 1] = \"LOADING\";\n LoaderStatus[LoaderStatus[\"SUCCESS\"] = 2] = \"SUCCESS\";\n LoaderStatus[LoaderStatus[\"FAILURE\"] = 3] = \"FAILURE\";\n})(LoaderStatus || (LoaderStatus = {}));\n/**\n * [[Loader]] makes it easier to add Google Maps JavaScript API to your application\n * dynamically using\n * [Promises](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise).\n * It works by dynamically creating and appending a script node to the the\n * document head and wrapping the callback function so as to return a promise.\n *\n * ```\n * const loader = new Loader({\n * apiKey: \"\",\n * version: \"weekly\",\n * libraries: [\"places\"]\n * });\n *\n * loader.load().then((google) => {\n * const map = new google.maps.Map(...)\n * })\n * ```\n */\nclass Loader {\n /**\n * Creates an instance of Loader using [[LoaderOptions]]. No defaults are set\n * using this library, instead the defaults are set by the Google Maps\n * JavaScript API server.\n *\n * ```\n * const loader = Loader({apiKey, version: 'weekly', libraries: ['places']});\n * ```\n */\n constructor(_ref6) {\n let apiKey = _ref6.apiKey,\n authReferrerPolicy = _ref6.authReferrerPolicy,\n channel = _ref6.channel,\n client = _ref6.client,\n _ref6$id = _ref6.id,\n id = _ref6$id === void 0 ? DEFAULT_ID : _ref6$id,\n language = _ref6.language,\n _ref6$libraries = _ref6.libraries,\n libraries = _ref6$libraries === void 0 ? [] : _ref6$libraries,\n mapIds = _ref6.mapIds,\n nonce = _ref6.nonce,\n region = _ref6.region,\n _ref6$retries = _ref6.retries,\n retries = _ref6$retries === void 0 ? 3 : _ref6$retries,\n _ref6$url = _ref6.url,\n url = _ref6$url === void 0 ? \"https://maps.googleapis.com/maps/api/js\" : _ref6$url,\n version = _ref6.version;\n this.CALLBACK = \"__googleMapsCallback\";\n this.callbacks = [];\n this.done = false;\n this.loading = false;\n this.errors = [];\n this.apiKey = apiKey;\n this.authReferrerPolicy = authReferrerPolicy;\n this.channel = channel;\n this.client = client;\n this.id = id || DEFAULT_ID; // Do not allow empty string\n this.language = language;\n this.libraries = libraries;\n this.mapIds = mapIds;\n this.nonce = nonce;\n this.region = region;\n this.retries = retries;\n this.url = url;\n this.version = version;\n if (Loader.instance) {\n if (!fastDeepEqual$1(this.options, Loader.instance.options)) {\n throw new Error(`Loader must not be called again with different options. ${JSON.stringify(this.options)} !== ${JSON.stringify(Loader.instance.options)}`);\n }\n return Loader.instance;\n }\n Loader.instance = this;\n }\n get options() {\n return {\n version: this.version,\n apiKey: this.apiKey,\n channel: this.channel,\n client: this.client,\n id: this.id,\n libraries: this.libraries,\n language: this.language,\n region: this.region,\n mapIds: this.mapIds,\n nonce: this.nonce,\n url: this.url,\n authReferrerPolicy: this.authReferrerPolicy\n };\n }\n get status() {\n if (this.errors.length) {\n return LoaderStatus.FAILURE;\n }\n if (this.done) {\n return LoaderStatus.SUCCESS;\n }\n if (this.loading) {\n return LoaderStatus.LOADING;\n }\n return LoaderStatus.INITIALIZED;\n }\n get failed() {\n return this.done && !this.loading && this.errors.length >= this.retries + 1;\n }\n /**\n * CreateUrl returns the Google Maps JavaScript API script url given the [[LoaderOptions]].\n *\n * @ignore\n */\n createUrl() {\n let url = this.url;\n url += `?callback=${this.CALLBACK}`;\n if (this.apiKey) {\n url += `&key=${this.apiKey}`;\n }\n if (this.channel) {\n url += `&channel=${this.channel}`;\n }\n if (this.client) {\n url += `&client=${this.client}`;\n }\n if (this.libraries.length > 0) {\n url += `&libraries=${this.libraries.join(\",\")}`;\n }\n if (this.language) {\n url += `&language=${this.language}`;\n }\n if (this.region) {\n url += `®ion=${this.region}`;\n }\n if (this.version) {\n url += `&v=${this.version}`;\n }\n if (this.mapIds) {\n url += `&map_ids=${this.mapIds.join(\",\")}`;\n }\n if (this.authReferrerPolicy) {\n url += `&auth_referrer_policy=${this.authReferrerPolicy}`;\n }\n return url;\n }\n deleteScript() {\n const script = document.getElementById(this.id);\n if (script) {\n script.remove();\n }\n }\n /**\n * Load the Google Maps JavaScript API script and return a Promise.\n */\n load() {\n return this.loadPromise();\n }\n /**\n * Load the Google Maps JavaScript API script and return a Promise.\n *\n * @ignore\n */\n loadPromise() {\n return new Promise((resolve, reject) => {\n this.loadCallback(err => {\n if (!err) {\n resolve(window.google);\n } else {\n reject(err.error);\n }\n });\n });\n }\n /**\n * Load the Google Maps JavaScript API script with a callback.\n */\n loadCallback(fn) {\n this.callbacks.push(fn);\n this.execute();\n }\n /**\n * Set the script on document.\n */\n setScript() {\n if (document.getElementById(this.id)) {\n // TODO wrap onerror callback for cases where the script was loaded elsewhere\n this.callback();\n return;\n }\n const url = this.createUrl();\n const script = document.createElement(\"script\");\n script.id = this.id;\n script.type = \"text/javascript\";\n script.src = url;\n script.onerror = this.loadErrorCallback.bind(this);\n script.defer = true;\n script.async = true;\n if (this.nonce) {\n script.nonce = this.nonce;\n }\n document.head.appendChild(script);\n }\n /**\n * Reset the loader state.\n */\n reset() {\n this.deleteScript();\n this.done = false;\n this.loading = false;\n this.errors = [];\n this.onerrorEvent = null;\n }\n resetIfRetryingFailed() {\n if (this.failed) {\n this.reset();\n }\n }\n loadErrorCallback(e) {\n this.errors.push(e);\n if (this.errors.length <= this.retries) {\n const delay = this.errors.length * Math.pow(2, this.errors.length);\n console.log(`Failed to load Google Maps script, retrying in ${delay} ms.`);\n setTimeout(() => {\n this.deleteScript();\n this.setScript();\n }, delay);\n } else {\n this.onerrorEvent = e;\n this.callback();\n }\n }\n setCallback() {\n window.__googleMapsCallback = this.callback.bind(this);\n }\n callback() {\n this.done = true;\n this.loading = false;\n this.callbacks.forEach(cb => {\n cb(this.onerrorEvent);\n });\n this.callbacks = [];\n }\n execute() {\n this.resetIfRetryingFailed();\n if (this.done) {\n this.callback();\n } else {\n // short circuit and warn if google.maps is already loaded\n if (window.google && window.google.maps && window.google.maps.version) {\n 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.\");\n this.callback();\n return;\n }\n if (this.loading) ;else {\n this.loading = true;\n this.setCallback();\n this.setScript();\n }\n }\n }\n}\nfunction useJsApiLoader(_ref7) {\n let _ref7$id = _ref7.id,\n id = _ref7$id === void 0 ? defaultLoadScriptProps.id : _ref7$id,\n _ref7$version = _ref7.version,\n version = _ref7$version === void 0 ? defaultLoadScriptProps.version : _ref7$version,\n nonce = _ref7.nonce,\n googleMapsApiKey = _ref7.googleMapsApiKey,\n language = _ref7.language,\n region = _ref7.region,\n libraries = _ref7.libraries,\n preventGoogleFontsLoading = _ref7.preventGoogleFontsLoading,\n mapIds = _ref7.mapIds,\n authReferrerPolicy = _ref7.authReferrerPolicy;\n const isMounted = useRef(false);\n const _useState31 = useState(false),\n _useState32 = _slicedToArray(_useState31, 2),\n isLoaded = _useState32[0],\n setLoaded = _useState32[1];\n const _useState33 = useState(undefined),\n _useState34 = _slicedToArray(_useState33, 2),\n loadError = _useState34[0],\n setLoadError = _useState34[1];\n useEffect(function trackMountedState() {\n isMounted.current = true;\n return () => {\n isMounted.current = false;\n };\n }, []);\n const loader = useMemo(function memo() {\n return new Loader({\n id,\n apiKey: googleMapsApiKey,\n version,\n libraries,\n language,\n region,\n mapIds,\n nonce,\n authReferrerPolicy\n });\n }, [id, googleMapsApiKey, version, libraries, language, region, mapIds, nonce, authReferrerPolicy]);\n useEffect(function effect() {\n if (isLoaded) {\n return;\n } else {\n loader.load().then(function then() {\n if (isMounted.current) setLoaded(true);\n }).catch(function onrejected(error) {\n setLoadError(error);\n });\n }\n }, []);\n useEffect(function applyPreventGoogleFonts() {\n if (isBrowser && preventGoogleFontsLoading) {\n preventGoogleFonts();\n }\n }, [preventGoogleFontsLoading]);\n const prevLibraries = useRef();\n useEffect(function effect() {\n if (prevLibraries.current && libraries !== prevLibraries.current) {\n 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');\n }\n prevLibraries.current = libraries;\n }, [libraries]);\n return {\n isLoaded,\n loadError\n };\n}\nconst eventMap$h = {};\nconst updaterMap$h = {\n options(instance, options) {\n instance.setOptions(options);\n }\n};\nfunction TrafficLayerFunctional(_ref8) {\n let options = _ref8.options,\n onLoad = _ref8.onLoad,\n onUnmount = _ref8.onUnmount;\n const map = useContext(MapContext);\n const _useState35 = useState(null),\n _useState36 = _slicedToArray(_useState35, 2),\n instance = _useState36[0],\n setInstance = _useState36[1];\n // Order does matter\n useEffect(() => {\n if (instance !== null) {\n instance.setMap(map);\n }\n }, [map]);\n useEffect(() => {\n if (options && instance !== null) {\n instance.setOptions(options);\n }\n }, [instance, options]);\n useEffect(() => {\n const trafficLayer = new google.maps.TrafficLayer(Object.assign(Object.assign({}, options || {}), {\n map\n }));\n setInstance(trafficLayer);\n if (onLoad) {\n onLoad(trafficLayer);\n }\n return () => {\n if (instance !== null) {\n if (onUnmount) {\n onUnmount(instance);\n }\n instance.setMap(null);\n }\n };\n }, []);\n return null;\n}\nconst TrafficLayerF = /*#__PURE__*/memo(TrafficLayerFunctional);\nclass TrafficLayer extends PureComponent {\n constructor() {\n super(...arguments);\n this.state = {\n trafficLayer: null\n };\n this.setTrafficLayerCallback = () => {\n if (this.state.trafficLayer !== null && this.props.onLoad) {\n this.props.onLoad(this.state.trafficLayer);\n }\n };\n this.registeredEvents = [];\n }\n componentDidMount() {\n const trafficLayer = new google.maps.TrafficLayer(Object.assign(Object.assign({}, this.props.options || {}), {\n map: this.context\n }));\n this.registeredEvents = applyUpdatersToPropsAndRegisterEvents({\n updaterMap: updaterMap$h,\n eventMap: eventMap$h,\n prevProps: {},\n nextProps: this.props,\n instance: trafficLayer\n });\n this.setState(function setTrafficLayer() {\n return {\n trafficLayer\n };\n }, this.setTrafficLayerCallback);\n }\n componentDidUpdate(prevProps) {\n if (this.state.trafficLayer !== null) {\n unregisterEvents(this.registeredEvents);\n this.registeredEvents = applyUpdatersToPropsAndRegisterEvents({\n updaterMap: updaterMap$h,\n eventMap: eventMap$h,\n prevProps,\n nextProps: this.props,\n instance: this.state.trafficLayer\n });\n }\n }\n componentWillUnmount() {\n if (this.state.trafficLayer !== null) {\n if (this.props.onUnmount) {\n this.props.onUnmount(this.state.trafficLayer);\n }\n unregisterEvents(this.registeredEvents);\n // @ts-ignore\n this.state.trafficLayer.setMap(null);\n }\n }\n render() {\n return null;\n }\n}\nTrafficLayer.contextType = MapContext;\nfunction BicyclingLayerFunctional(_ref9) {\n let onLoad = _ref9.onLoad,\n onUnmount = _ref9.onUnmount;\n const map = useContext(MapContext);\n const _useState37 = useState(null),\n _useState38 = _slicedToArray(_useState37, 2),\n instance = _useState38[0],\n setInstance = _useState38[1];\n // Order does matter\n useEffect(() => {\n if (instance !== null) {\n instance.setMap(map);\n }\n }, [map]);\n useEffect(() => {\n const bicyclingLayer = new google.maps.BicyclingLayer();\n setInstance(bicyclingLayer);\n bicyclingLayer.setMap(map);\n if (onLoad) {\n onLoad(bicyclingLayer);\n }\n return () => {\n if (bicyclingLayer !== null) {\n if (onUnmount) {\n onUnmount(bicyclingLayer);\n }\n bicyclingLayer.setMap(null);\n }\n };\n }, []);\n return null;\n}\nconst BicyclingLayerF = /*#__PURE__*/memo(BicyclingLayerFunctional);\nclass BicyclingLayer extends PureComponent {\n constructor() {\n super(...arguments);\n this.state = {\n bicyclingLayer: null\n };\n this.setBicyclingLayerCallback = () => {\n if (this.state.bicyclingLayer !== null) {\n this.state.bicyclingLayer.setMap(this.context);\n if (this.props.onLoad) {\n this.props.onLoad(this.state.bicyclingLayer);\n }\n }\n };\n }\n componentDidMount() {\n const bicyclingLayer = new google.maps.BicyclingLayer();\n this.setState(() => {\n return {\n bicyclingLayer\n };\n }, this.setBicyclingLayerCallback);\n }\n componentWillUnmount() {\n if (this.state.bicyclingLayer !== null) {\n if (this.props.onUnmount) {\n this.props.onUnmount(this.state.bicyclingLayer);\n }\n this.state.bicyclingLayer.setMap(null);\n }\n }\n render() {\n return null;\n }\n}\nBicyclingLayer.contextType = MapContext;\nfunction TransitLayerFunctional(_ref10) {\n let onLoad = _ref10.onLoad,\n onUnmount = _ref10.onUnmount;\n const map = useContext(MapContext);\n const _useState39 = useState(null),\n _useState40 = _slicedToArray(_useState39, 2),\n instance = _useState40[0],\n setInstance = _useState40[1];\n // Order does matter\n useEffect(() => {\n if (instance !== null) {\n instance.setMap(map);\n }\n }, [map]);\n useEffect(() => {\n const transitLayer = new google.maps.TransitLayer();\n setInstance(transitLayer);\n transitLayer.setMap(map);\n if (onLoad) {\n onLoad(transitLayer);\n }\n return () => {\n if (instance !== null) {\n if (onUnmount) {\n onUnmount(instance);\n }\n // @ts-ignore\n this.state.transitLayer.setMap(null);\n }\n };\n }, []);\n return null;\n}\nconst TransitLayerF = /*#__PURE__*/memo(TransitLayerFunctional);\nclass TransitLayer extends PureComponent {\n constructor() {\n super(...arguments);\n this.state = {\n transitLayer: null\n };\n this.setTransitLayerCallback = () => {\n if (this.state.transitLayer !== null) {\n // @ts-ignore\n this.state.transitLayer.setMap(this.context);\n if (this.props.onLoad) {\n // @ts-ignore\n this.props.onLoad(this.state.transitLayer);\n }\n }\n };\n }\n componentDidMount() {\n const transitLayer = new google.maps.TransitLayer();\n this.setState(function setTransitLayer() {\n return {\n transitLayer\n };\n }, this.setTransitLayerCallback);\n }\n componentWillUnmount() {\n if (this.state.transitLayer !== null) {\n if (this.props.onUnmount) {\n // @ts-ignore\n this.props.onUnmount(this.state.transitLayer);\n }\n // @ts-ignore\n this.state.transitLayer.setMap(null);\n }\n }\n render() {\n return null;\n }\n}\nTransitLayer.contextType = MapContext;\n\n/* globals google */\nconst eventMap$g = {\n onCircleComplete: 'circlecomplete',\n onMarkerComplete: 'markercomplete',\n onOverlayComplete: 'overlaycomplete',\n onPolygonComplete: 'polygoncomplete',\n onPolylineComplete: 'polylinecomplete',\n onRectangleComplete: 'rectanglecomplete'\n};\nconst updaterMap$g = {\n drawingMode(instance, drawingMode) {\n instance.setDrawingMode(drawingMode);\n },\n options(instance, options) {\n instance.setOptions(options);\n }\n};\nfunction DrawingManagerFunctional(_ref11) {\n let options = _ref11.options,\n drawingMode = _ref11.drawingMode,\n onCircleComplete = _ref11.onCircleComplete,\n onMarkerComplete = _ref11.onMarkerComplete,\n onOverlayComplete = _ref11.onOverlayComplete,\n onPolygonComplete = _ref11.onPolygonComplete,\n onPolylineComplete = _ref11.onPolylineComplete,\n onRectangleComplete = _ref11.onRectangleComplete,\n onLoad = _ref11.onLoad,\n onUnmount = _ref11.onUnmount;\n const map = useContext(MapContext);\n const _useState41 = useState(null),\n _useState42 = _slicedToArray(_useState41, 2),\n instance = _useState42[0],\n setInstance = _useState42[1];\n const _useState43 = useState(null),\n _useState44 = _slicedToArray(_useState43, 2),\n circlecompleteListener = _useState44[0],\n setCircleCompleteListener = _useState44[1];\n const _useState45 = useState(null),\n _useState46 = _slicedToArray(_useState45, 2),\n markercompleteListener = _useState46[0],\n setMarkerCompleteListener = _useState46[1];\n const _useState47 = useState(null),\n _useState48 = _slicedToArray(_useState47, 2),\n overlaycompleteListener = _useState48[0],\n setOverlayCompleteListener = _useState48[1];\n const _useState49 = useState(null),\n _useState50 = _slicedToArray(_useState49, 2),\n polygoncompleteListener = _useState50[0],\n setPolygonCompleteListener = _useState50[1];\n const _useState51 = useState(null),\n _useState52 = _slicedToArray(_useState51, 2),\n polylinecompleteListener = _useState52[0],\n setPolylineCompleteListener = _useState52[1];\n const _useState53 = useState(null),\n _useState54 = _slicedToArray(_useState53, 2),\n rectanglecompleteListener = _useState54[0],\n setRectangleCompleteListener = _useState54[1];\n // Order does matter\n useEffect(() => {\n if (instance !== null) {\n instance.setMap(map);\n }\n }, [map]);\n useEffect(() => {\n if (options && instance !== null) {\n instance.setOptions(options);\n }\n }, [instance, options]);\n useEffect(() => {\n if (drawingMode && instance !== null) {\n instance.setDrawingMode(drawingMode);\n }\n }, [instance, drawingMode]);\n useEffect(() => {\n if (instance && onCircleComplete) {\n if (circlecompleteListener !== null) {\n google.maps.event.removeListener(circlecompleteListener);\n }\n setCircleCompleteListener(google.maps.event.addListener(instance, 'circlecomplete', onCircleComplete));\n }\n }, [instance, onCircleComplete]);\n useEffect(() => {\n if (instance && onMarkerComplete) {\n if (markercompleteListener !== null) {\n google.maps.event.removeListener(markercompleteListener);\n }\n setMarkerCompleteListener(google.maps.event.addListener(instance, 'markercomplete', onMarkerComplete));\n }\n }, [instance, onMarkerComplete]);\n useEffect(() => {\n if (instance && onOverlayComplete) {\n if (overlaycompleteListener !== null) {\n google.maps.event.removeListener(overlaycompleteListener);\n }\n setOverlayCompleteListener(google.maps.event.addListener(instance, 'overlaycomplete', onOverlayComplete));\n }\n }, [instance, onOverlayComplete]);\n useEffect(() => {\n if (instance && onPolygonComplete) {\n if (polygoncompleteListener !== null) {\n google.maps.event.removeListener(polygoncompleteListener);\n }\n setPolygonCompleteListener(google.maps.event.addListener(instance, 'polygoncomplete', onPolygonComplete));\n }\n }, [instance, onPolygonComplete]);\n useEffect(() => {\n if (instance && onPolylineComplete) {\n if (polylinecompleteListener !== null) {\n google.maps.event.removeListener(polylinecompleteListener);\n }\n setPolylineCompleteListener(google.maps.event.addListener(instance, 'polylinecomplete', onPolylineComplete));\n }\n }, [instance, onPolylineComplete]);\n useEffect(() => {\n if (instance && onRectangleComplete) {\n if (rectanglecompleteListener !== null) {\n google.maps.event.removeListener(rectanglecompleteListener);\n }\n setRectangleCompleteListener(google.maps.event.addListener(instance, 'rectanglecomplete', onRectangleComplete));\n }\n }, [instance, onRectangleComplete]);\n useEffect(() => {\n invariant_1(!!google.maps.drawing, `Did you include prop libraries={['drawing']} in the URL? %s`, google.maps.drawing);\n const drawingManager = new google.maps.drawing.DrawingManager(Object.assign(Object.assign({}, options || {}), {\n map\n }));\n if (drawingMode) {\n drawingManager.setDrawingMode(drawingMode);\n }\n if (onCircleComplete) {\n setCircleCompleteListener(google.maps.event.addListener(drawingManager, 'circlecomplete', onCircleComplete));\n }\n if (onMarkerComplete) {\n setMarkerCompleteListener(google.maps.event.addListener(drawingManager, 'markercomplete', onMarkerComplete));\n }\n if (onOverlayComplete) {\n setOverlayCompleteListener(google.maps.event.addListener(drawingManager, 'overlaycomplete', onOverlayComplete));\n }\n if (onPolygonComplete) {\n setPolygonCompleteListener(google.maps.event.addListener(drawingManager, 'polygoncomplete', onPolygonComplete));\n }\n if (onPolylineComplete) {\n setPolylineCompleteListener(google.maps.event.addListener(drawingManager, 'polylinecomplete', onPolylineComplete));\n }\n if (onRectangleComplete) {\n setRectangleCompleteListener(google.maps.event.addListener(drawingManager, 'rectanglecomplete', onRectangleComplete));\n }\n setInstance(drawingManager);\n if (onLoad) {\n onLoad(drawingManager);\n }\n return () => {\n if (instance !== null) {\n if (circlecompleteListener) {\n google.maps.event.removeListener(circlecompleteListener);\n }\n if (markercompleteListener) {\n google.maps.event.removeListener(markercompleteListener);\n }\n if (overlaycompleteListener) {\n google.maps.event.removeListener(overlaycompleteListener);\n }\n if (polygoncompleteListener) {\n google.maps.event.removeListener(polygoncompleteListener);\n }\n if (polylinecompleteListener) {\n google.maps.event.removeListener(polylinecompleteListener);\n }\n if (rectanglecompleteListener) {\n google.maps.event.removeListener(rectanglecompleteListener);\n }\n if (onUnmount) {\n onUnmount(instance);\n }\n instance.setMap(null);\n }\n };\n }, []);\n return null;\n}\nconst DrawingManagerF = /*#__PURE__*/memo(DrawingManagerFunctional);\nclass DrawingManager extends PureComponent {\n constructor(props) {\n super(props);\n this.registeredEvents = [];\n this.state = {\n drawingManager: null\n };\n this.setDrawingManagerCallback = () => {\n if (this.state.drawingManager !== null && this.props.onLoad) {\n this.props.onLoad(this.state.drawingManager);\n }\n };\n invariant_1(!!google.maps.drawing, `Did you include prop libraries={['drawing']} in the URL? %s`, google.maps.drawing);\n }\n componentDidMount() {\n const drawingManager = new google.maps.drawing.DrawingManager(Object.assign(Object.assign({}, this.props.options || {}), {\n map: this.context\n }));\n this.registeredEvents = applyUpdatersToPropsAndRegisterEvents({\n updaterMap: updaterMap$g,\n eventMap: eventMap$g,\n prevProps: {},\n nextProps: this.props,\n instance: drawingManager\n });\n this.setState(function setDrawingManager() {\n return {\n drawingManager\n };\n }, this.setDrawingManagerCallback);\n }\n componentDidUpdate(prevProps) {\n if (this.state.drawingManager !== null) {\n unregisterEvents(this.registeredEvents);\n this.registeredEvents = applyUpdatersToPropsAndRegisterEvents({\n updaterMap: updaterMap$g,\n eventMap: eventMap$g,\n prevProps,\n nextProps: this.props,\n instance: this.state.drawingManager\n });\n }\n }\n componentWillUnmount() {\n if (this.state.drawingManager !== null) {\n if (this.props.onUnmount) {\n this.props.onUnmount(this.state.drawingManager);\n }\n unregisterEvents(this.registeredEvents);\n this.state.drawingManager.setMap(null);\n }\n }\n render() {\n return null;\n }\n}\nDrawingManager.contextType = MapContext;\nconst eventMap$f = {\n onAnimationChanged: 'animation_changed',\n onClick: 'click',\n onClickableChanged: 'clickable_changed',\n onCursorChanged: 'cursor_changed',\n onDblClick: 'dblclick',\n onDrag: 'drag',\n onDragEnd: 'dragend',\n onDraggableChanged: 'draggable_changed',\n onDragStart: 'dragstart',\n onFlatChanged: 'flat_changed',\n onIconChanged: 'icon_changed',\n onMouseDown: 'mousedown',\n onMouseOut: 'mouseout',\n onMouseOver: 'mouseover',\n onMouseUp: 'mouseup',\n onPositionChanged: 'position_changed',\n onRightClick: 'rightclick',\n onShapeChanged: 'shape_changed',\n onTitleChanged: 'title_changed',\n onVisibleChanged: 'visible_changed',\n onZindexChanged: 'zindex_changed'\n};\nconst updaterMap$f = {\n animation(instance, animation) {\n instance.setAnimation(animation);\n },\n clickable(instance, clickable) {\n instance.setClickable(clickable);\n },\n cursor(instance, cursor) {\n instance.setCursor(cursor);\n },\n draggable(instance, draggable) {\n instance.setDraggable(draggable);\n },\n icon(instance, icon) {\n instance.setIcon(icon);\n },\n label(instance, label) {\n instance.setLabel(label);\n },\n map(instance, map) {\n instance.setMap(map);\n },\n opacity(instance, opacity) {\n instance.setOpacity(opacity);\n },\n options(instance, options) {\n instance.setOptions(options);\n },\n position(instance, position) {\n instance.setPosition(position);\n },\n shape(instance, shape) {\n instance.setShape(shape);\n },\n title(instance, title) {\n instance.setTitle(title);\n },\n visible(instance, visible) {\n instance.setVisible(visible);\n },\n zIndex(instance, zIndex) {\n instance.setZIndex(zIndex);\n }\n};\nconst defaultOptions$5 = {};\nfunction MarkerFunctional(_ref12) {\n let position = _ref12.position,\n options = _ref12.options,\n clusterer = _ref12.clusterer,\n noClustererRedraw = _ref12.noClustererRedraw,\n children = _ref12.children,\n draggable = _ref12.draggable,\n visible = _ref12.visible,\n animation = _ref12.animation,\n clickable = _ref12.clickable,\n cursor = _ref12.cursor,\n icon = _ref12.icon,\n label = _ref12.label,\n opacity = _ref12.opacity,\n shape = _ref12.shape,\n title = _ref12.title,\n zIndex = _ref12.zIndex,\n onClick = _ref12.onClick,\n onDblClick = _ref12.onDblClick,\n onDrag = _ref12.onDrag,\n onDragEnd = _ref12.onDragEnd,\n onDragStart = _ref12.onDragStart,\n onMouseOut = _ref12.onMouseOut,\n onMouseOver = _ref12.onMouseOver,\n onMouseUp = _ref12.onMouseUp,\n onMouseDown = _ref12.onMouseDown,\n onRightClick = _ref12.onRightClick,\n onClickableChanged = _ref12.onClickableChanged,\n onCursorChanged = _ref12.onCursorChanged,\n onAnimationChanged = _ref12.onAnimationChanged,\n onDraggableChanged = _ref12.onDraggableChanged,\n onFlatChanged = _ref12.onFlatChanged,\n onIconChanged = _ref12.onIconChanged,\n onPositionChanged = _ref12.onPositionChanged,\n onShapeChanged = _ref12.onShapeChanged,\n onTitleChanged = _ref12.onTitleChanged,\n onVisibleChanged = _ref12.onVisibleChanged,\n onZindexChanged = _ref12.onZindexChanged,\n onLoad = _ref12.onLoad,\n onUnmount = _ref12.onUnmount;\n const map = useContext(MapContext);\n const _useState55 = useState(null),\n _useState56 = _slicedToArray(_useState55, 2),\n instance = _useState56[0],\n setInstance = _useState56[1];\n const _useState57 = useState(null),\n _useState58 = _slicedToArray(_useState57, 2),\n dblclickListener = _useState58[0],\n setDblclickListener = _useState58[1];\n const _useState59 = useState(null),\n _useState60 = _slicedToArray(_useState59, 2),\n dragendListener = _useState60[0],\n setDragendListener = _useState60[1];\n const _useState61 = useState(null),\n _useState62 = _slicedToArray(_useState61, 2),\n dragstartListener = _useState62[0],\n setDragstartListener = _useState62[1];\n const _useState63 = useState(null),\n _useState64 = _slicedToArray(_useState63, 2),\n mousedownListener = _useState64[0],\n setMousedownListener = _useState64[1];\n const _useState65 = useState(null),\n _useState66 = _slicedToArray(_useState65, 2),\n mouseoutListener = _useState66[0],\n setMouseoutListener = _useState66[1];\n const _useState67 = useState(null),\n _useState68 = _slicedToArray(_useState67, 2),\n mouseoverListener = _useState68[0],\n setMouseoverListener = _useState68[1];\n const _useState69 = useState(null),\n _useState70 = _slicedToArray(_useState69, 2),\n mouseupListener = _useState70[0],\n setMouseupListener = _useState70[1];\n const _useState71 = useState(null),\n _useState72 = _slicedToArray(_useState71, 2),\n rightclickListener = _useState72[0],\n setRightclickListener = _useState72[1];\n const _useState73 = useState(null),\n _useState74 = _slicedToArray(_useState73, 2),\n clickListener = _useState74[0],\n setClickListener = _useState74[1];\n const _useState75 = useState(null),\n _useState76 = _slicedToArray(_useState75, 2),\n dragListener = _useState76[0],\n setDragListener = _useState76[1];\n const _useState77 = useState(null),\n _useState78 = _slicedToArray(_useState77, 2),\n clickableChangedListener = _useState78[0],\n setClickableChangedListener = _useState78[1];\n const _useState79 = useState(null),\n _useState80 = _slicedToArray(_useState79, 2),\n cursorChangedListener = _useState80[0],\n setCursorChangedListener = _useState80[1];\n const _useState81 = useState(null),\n _useState82 = _slicedToArray(_useState81, 2),\n animationChangedListener = _useState82[0],\n setAnimationChangedListener = _useState82[1];\n const _useState83 = useState(null),\n _useState84 = _slicedToArray(_useState83, 2),\n draggableChangedListener = _useState84[0],\n setDraggableChangedListener = _useState84[1];\n const _useState85 = useState(null),\n _useState86 = _slicedToArray(_useState85, 2),\n flatChangedListener = _useState86[0],\n setFlatChangedListener = _useState86[1];\n const _useState87 = useState(null),\n _useState88 = _slicedToArray(_useState87, 2),\n iconChangedListener = _useState88[0],\n setIconChangedListener = _useState88[1];\n const _useState89 = useState(null),\n _useState90 = _slicedToArray(_useState89, 2),\n positionChangedListener = _useState90[0],\n setPositionChangedListener = _useState90[1];\n const _useState91 = useState(null),\n _useState92 = _slicedToArray(_useState91, 2),\n shapeChangedListener = _useState92[0],\n setShapeChangedListener = _useState92[1];\n const _useState93 = useState(null),\n _useState94 = _slicedToArray(_useState93, 2),\n titleChangedListener = _useState94[0],\n setTitleChangedListener = _useState94[1];\n const _useState95 = useState(null),\n _useState96 = _slicedToArray(_useState95, 2),\n visibleChangedListener = _useState96[0],\n setVisibleChangedListener = _useState96[1];\n const _useState97 = useState(null),\n _useState98 = _slicedToArray(_useState97, 2),\n zIndexChangedListener = _useState98[0],\n setZindexChangedListener = _useState98[1];\n // Order does matter\n useEffect(() => {\n if (instance !== null) {\n instance.setMap(map);\n }\n }, [map]);\n useEffect(() => {\n if (typeof options !== 'undefined' && instance !== null) {\n instance.setOptions(options);\n }\n }, [instance, options]);\n useEffect(() => {\n if (typeof draggable !== 'undefined' && instance !== null) {\n instance.setDraggable(draggable);\n }\n }, [instance, draggable]);\n useEffect(() => {\n if (position && instance !== null) {\n instance.setPosition(position);\n }\n }, [instance, position]);\n useEffect(() => {\n if (typeof visible !== 'undefined' && instance !== null) {\n instance.setVisible(visible);\n }\n }, [instance, visible]);\n useEffect(() => {\n if (animation && instance !== null) {\n instance.setAnimation(animation);\n }\n }, [instance, animation]);\n useEffect(() => {\n if (instance && onDblClick) {\n if (dblclickListener !== null) {\n google.maps.event.removeListener(dblclickListener);\n }\n setDblclickListener(google.maps.event.addListener(instance, 'dblclick', onDblClick));\n }\n }, [onDblClick]);\n useEffect(() => {\n if (instance && onDragEnd) {\n if (dragendListener !== null) {\n google.maps.event.removeListener(dragendListener);\n }\n setDragendListener(google.maps.event.addListener(instance, 'dragend', onDragEnd));\n }\n }, [onDragEnd]);\n useEffect(() => {\n if (instance && onDragStart) {\n if (dragstartListener !== null) {\n google.maps.event.removeListener(dragstartListener);\n }\n setDragstartListener(google.maps.event.addListener(instance, 'dragstart', onDragStart));\n }\n }, [onDragStart]);\n useEffect(() => {\n if (instance && onMouseDown) {\n if (mousedownListener !== null) {\n google.maps.event.removeListener(mousedownListener);\n }\n setMousedownListener(google.maps.event.addListener(instance, 'mousedown', onMouseDown));\n }\n }, [onMouseDown]);\n useEffect(() => {\n if (instance && onMouseOut) {\n if (mouseoutListener !== null) {\n google.maps.event.removeListener(mouseoutListener);\n }\n setMouseoutListener(google.maps.event.addListener(instance, 'mouseout', onMouseOut));\n }\n }, [onMouseOut]);\n useEffect(() => {\n if (instance && onMouseOver) {\n if (mouseoverListener !== null) {\n google.maps.event.removeListener(mouseoverListener);\n }\n setMouseoverListener(google.maps.event.addListener(instance, 'mouseover', onMouseOver));\n }\n }, [onMouseOver]);\n useEffect(() => {\n if (instance && onMouseUp) {\n if (mouseupListener !== null) {\n google.maps.event.removeListener(mouseupListener);\n }\n setMouseupListener(google.maps.event.addListener(instance, 'mouseup', onMouseUp));\n }\n }, [onMouseUp]);\n useEffect(() => {\n if (instance && onRightClick) {\n if (rightclickListener !== null) {\n google.maps.event.removeListener(rightclickListener);\n }\n setRightclickListener(google.maps.event.addListener(instance, 'rightclick', onRightClick));\n }\n }, [onRightClick]);\n useEffect(() => {\n if (instance && onClick) {\n if (clickListener !== null) {\n google.maps.event.removeListener(clickListener);\n }\n setClickListener(google.maps.event.addListener(instance, 'click', onClick));\n }\n }, [onClick]);\n useEffect(() => {\n if (instance && onDrag) {\n if (dragListener !== null) {\n google.maps.event.removeListener(dragListener);\n }\n setDragListener(google.maps.event.addListener(instance, 'drag', onDrag));\n }\n }, [onDrag]);\n useEffect(() => {\n if (instance && onClickableChanged) {\n if (clickableChangedListener !== null) {\n google.maps.event.removeListener(clickableChangedListener);\n }\n setClickableChangedListener(google.maps.event.addListener(instance, 'clickable_changed', onClickableChanged));\n }\n }, [onClickableChanged]);\n useEffect(() => {\n if (instance && onCursorChanged) {\n if (cursorChangedListener !== null) {\n google.maps.event.removeListener(cursorChangedListener);\n }\n setCursorChangedListener(google.maps.event.addListener(instance, 'cursor_changed', onCursorChanged));\n }\n }, [onCursorChanged]);\n useEffect(() => {\n if (instance && onAnimationChanged) {\n if (animationChangedListener !== null) {\n google.maps.event.removeListener(animationChangedListener);\n }\n setAnimationChangedListener(google.maps.event.addListener(instance, 'animation_changed', onAnimationChanged));\n }\n }, [onAnimationChanged]);\n useEffect(() => {\n if (instance && onDraggableChanged) {\n if (draggableChangedListener !== null) {\n google.maps.event.removeListener(draggableChangedListener);\n }\n setDraggableChangedListener(google.maps.event.addListener(instance, 'draggable_changed', onDraggableChanged));\n }\n }, [onDraggableChanged]);\n useEffect(() => {\n if (instance && onFlatChanged) {\n if (flatChangedListener !== null) {\n google.maps.event.removeListener(flatChangedListener);\n }\n setFlatChangedListener(google.maps.event.addListener(instance, 'flat_changed', onFlatChanged));\n }\n }, [onFlatChanged]);\n useEffect(() => {\n if (instance && onIconChanged) {\n if (iconChangedListener !== null) {\n google.maps.event.removeListener(iconChangedListener);\n }\n setIconChangedListener(google.maps.event.addListener(instance, 'icon_changed', onIconChanged));\n }\n }, [onIconChanged]);\n useEffect(() => {\n if (instance && onPositionChanged) {\n if (positionChangedListener !== null) {\n google.maps.event.removeListener(positionChangedListener);\n }\n setPositionChangedListener(google.maps.event.addListener(instance, 'position_changed', onPositionChanged));\n }\n }, [onPositionChanged]);\n useEffect(() => {\n if (instance && onShapeChanged) {\n if (shapeChangedListener !== null) {\n google.maps.event.removeListener(shapeChangedListener);\n }\n setShapeChangedListener(google.maps.event.addListener(instance, 'shape_changed', onShapeChanged));\n }\n }, [onShapeChanged]);\n useEffect(() => {\n if (instance && onTitleChanged) {\n if (titleChangedListener !== null) {\n google.maps.event.removeListener(titleChangedListener);\n }\n setTitleChangedListener(google.maps.event.addListener(instance, 'title_changed', onTitleChanged));\n }\n }, [onTitleChanged]);\n useEffect(() => {\n if (instance && onVisibleChanged) {\n if (visibleChangedListener !== null) {\n google.maps.event.removeListener(visibleChangedListener);\n }\n setVisibleChangedListener(google.maps.event.addListener(instance, 'visible_changed', onVisibleChanged));\n }\n }, [onVisibleChanged]);\n useEffect(() => {\n if (instance && onZindexChanged) {\n if (zIndexChangedListener !== null) {\n google.maps.event.removeListener(zIndexChangedListener);\n }\n setZindexChangedListener(google.maps.event.addListener(instance, 'zindex_changed', onZindexChanged));\n }\n }, [onZindexChanged]);\n useEffect(() => {\n const markerOptions = Object.assign(Object.assign(Object.assign({}, options || defaultOptions$5), clusterer ? defaultOptions$5 : {\n map\n }), {\n position: position\n });\n const marker = new google.maps.Marker(markerOptions);\n if (clusterer) {\n clusterer.addMarker(marker, !!noClustererRedraw);\n } else {\n marker.setMap(map);\n }\n if (position) {\n marker.setPosition(position);\n }\n if (typeof visible !== 'undefined') {\n marker.setVisible(visible);\n }\n if (typeof draggable !== 'undefined') {\n marker.setDraggable(draggable);\n }\n if (typeof clickable !== 'undefined') {\n marker.setClickable(clickable);\n }\n if (typeof cursor === 'string') {\n marker.setCursor(cursor);\n }\n if (icon) {\n marker.setIcon(icon);\n }\n if (typeof label !== 'undefined') {\n marker.setLabel(label);\n }\n if (typeof opacity !== 'undefined') {\n marker.setOpacity(opacity);\n }\n if (shape) {\n marker.setShape(shape);\n }\n if (typeof title === 'string') {\n marker.setTitle(title);\n }\n if (typeof zIndex === 'number') {\n marker.setZIndex(zIndex);\n }\n if (onDblClick) {\n setDblclickListener(google.maps.event.addListener(marker, 'dblclick', onDblClick));\n }\n if (onDragEnd) {\n setDragendListener(google.maps.event.addListener(marker, 'dragend', onDragEnd));\n }\n if (onDragStart) {\n setDragstartListener(google.maps.event.addListener(marker, 'dragstart', onDragStart));\n }\n if (onMouseDown) {\n setMousedownListener(google.maps.event.addListener(marker, 'mousedown', onMouseDown));\n }\n if (onMouseOut) {\n setMouseoutListener(google.maps.event.addListener(marker, 'mouseout', onMouseOut));\n }\n if (onMouseOver) {\n setMouseoverListener(google.maps.event.addListener(marker, 'mouseover', onMouseOver));\n }\n if (onMouseUp) {\n setMouseupListener(google.maps.event.addListener(marker, 'mouseup', onMouseUp));\n }\n if (onRightClick) {\n setRightclickListener(google.maps.event.addListener(marker, 'rightclick', onRightClick));\n }\n if (onClick) {\n setClickListener(google.maps.event.addListener(marker, 'click', onClick));\n }\n if (onDrag) {\n setDragListener(google.maps.event.addListener(marker, 'drag', onDrag));\n }\n if (onClickableChanged) {\n setClickableChangedListener(google.maps.event.addListener(marker, 'clickable_changed', onClickableChanged));\n }\n if (onCursorChanged) {\n setCursorChangedListener(google.maps.event.addListener(marker, 'cursor_changed', onCursorChanged));\n }\n if (onAnimationChanged) {\n setAnimationChangedListener(google.maps.event.addListener(marker, 'animation_changed', onAnimationChanged));\n }\n if (onDraggableChanged) {\n setDraggableChangedListener(google.maps.event.addListener(marker, 'draggable_changed', onDraggableChanged));\n }\n if (onFlatChanged) {\n setFlatChangedListener(google.maps.event.addListener(marker, 'flat_changed', onFlatChanged));\n }\n if (onIconChanged) {\n setIconChangedListener(google.maps.event.addListener(marker, 'icon_changed', onIconChanged));\n }\n if (onPositionChanged) {\n setPositionChangedListener(google.maps.event.addListener(marker, 'position_changed', onPositionChanged));\n }\n if (onShapeChanged) {\n setShapeChangedListener(google.maps.event.addListener(marker, 'shape_changed', onShapeChanged));\n }\n if (onTitleChanged) {\n setTitleChangedListener(google.maps.event.addListener(marker, 'title_changed', onTitleChanged));\n }\n if (onVisibleChanged) {\n setVisibleChangedListener(google.maps.event.addListener(marker, 'visible_changed', onVisibleChanged));\n }\n if (onZindexChanged) {\n setZindexChangedListener(google.maps.event.addListener(marker, 'zindex_changed', onZindexChanged));\n }\n setInstance(marker);\n if (onLoad) {\n onLoad(marker);\n }\n return () => {\n if (dblclickListener !== null) {\n google.maps.event.removeListener(dblclickListener);\n }\n if (dragendListener !== null) {\n google.maps.event.removeListener(dragendListener);\n }\n if (dragstartListener !== null) {\n google.maps.event.removeListener(dragstartListener);\n }\n if (mousedownListener !== null) {\n google.maps.event.removeListener(mousedownListener);\n }\n if (mouseoutListener !== null) {\n google.maps.event.removeListener(mouseoutListener);\n }\n if (mouseoverListener !== null) {\n google.maps.event.removeListener(mouseoverListener);\n }\n if (mouseupListener !== null) {\n google.maps.event.removeListener(mouseupListener);\n }\n if (rightclickListener !== null) {\n google.maps.event.removeListener(rightclickListener);\n }\n if (clickListener !== null) {\n google.maps.event.removeListener(clickListener);\n }\n if (clickableChangedListener !== null) {\n google.maps.event.removeListener(clickableChangedListener);\n }\n if (cursorChangedListener !== null) {\n google.maps.event.removeListener(cursorChangedListener);\n }\n if (animationChangedListener !== null) {\n google.maps.event.removeListener(animationChangedListener);\n }\n if (draggableChangedListener !== null) {\n google.maps.event.removeListener(draggableChangedListener);\n }\n if (flatChangedListener !== null) {\n google.maps.event.removeListener(flatChangedListener);\n }\n if (iconChangedListener !== null) {\n google.maps.event.removeListener(iconChangedListener);\n }\n if (positionChangedListener !== null) {\n google.maps.event.removeListener(positionChangedListener);\n }\n if (titleChangedListener !== null) {\n google.maps.event.removeListener(titleChangedListener);\n }\n if (visibleChangedListener !== null) {\n google.maps.event.removeListener(visibleChangedListener);\n }\n if (zIndexChangedListener !== null) {\n google.maps.event.removeListener(zIndexChangedListener);\n }\n if (onUnmount) {\n onUnmount(marker);\n }\n if (clusterer) {\n clusterer.removeMarker(marker, !!noClustererRedraw);\n } else if (marker) {\n marker.setMap(null);\n }\n };\n }, []);\n const chx = useMemo(() => {\n return children ? Children.map(children, child => {\n if (! /*#__PURE__*/isValidElement(child)) {\n return child;\n }\n const elementChild = child;\n return /*#__PURE__*/cloneElement(elementChild, {\n anchor: instance\n });\n }) : null;\n }, [children, instance]);\n return jsx(Fragment, {\n children: chx\n }) || null;\n}\nconst MarkerF = /*#__PURE__*/memo(MarkerFunctional);\nclass Marker extends PureComponent {\n constructor() {\n super(...arguments);\n this.registeredEvents = [];\n }\n componentDidMount() {\n const markerOptions = Object.assign(Object.assign(Object.assign({}, this.props.options || defaultOptions$5), this.props.clusterer ? defaultOptions$5 : {\n map: this.context\n }), {\n position: this.props.position\n });\n // Unfortunately we can't just do this in the contstructor, because the\n // `MapContext` might not be filled in yet.\n this.marker = new google.maps.Marker(markerOptions);\n if (this.props.clusterer) {\n this.props.clusterer.addMarker(this.marker, !!this.props.noClustererRedraw);\n } else {\n this.marker.setMap(this.context);\n }\n this.registeredEvents = applyUpdatersToPropsAndRegisterEvents({\n updaterMap: updaterMap$f,\n eventMap: eventMap$f,\n prevProps: {},\n nextProps: this.props,\n instance: this.marker\n });\n if (this.props.onLoad) {\n this.props.onLoad(this.marker);\n }\n }\n componentDidUpdate(prevProps) {\n if (this.marker) {\n unregisterEvents(this.registeredEvents);\n this.registeredEvents = applyUpdatersToPropsAndRegisterEvents({\n updaterMap: updaterMap$f,\n eventMap: eventMap$f,\n prevProps,\n nextProps: this.props,\n instance: this.marker\n });\n }\n }\n componentWillUnmount() {\n if (this.marker) {\n if (this.props.onUnmount) {\n this.props.onUnmount(this.marker);\n }\n unregisterEvents(this.registeredEvents);\n if (this.props.clusterer) {\n this.props.clusterer.removeMarker(this.marker, !!this.props.noClustererRedraw);\n } else {\n this.marker && this.marker.setMap(null);\n }\n }\n }\n render() {\n let children = null;\n if (this.props.children) {\n children = Children.map(this.props.children, child => {\n if (! /*#__PURE__*/isValidElement(child)) {\n return child;\n }\n const elementChild = child;\n return /*#__PURE__*/cloneElement(elementChild, {\n anchor: this.marker\n });\n });\n }\n return children || null;\n }\n}\nMarker.contextType = MapContext;\nvar ClusterIcon = /** @class */function () {\n function ClusterIcon(cluster, styles) {\n cluster.getClusterer().extend(ClusterIcon, google.maps.OverlayView);\n this.cluster = cluster;\n this.clusterClassName = this.cluster.getClusterer().getClusterClass();\n this.className = this.clusterClassName;\n this.styles = styles;\n this.center = undefined;\n this.div = null;\n this.sums = null;\n this.visible = false;\n this.boundsChangedListener = null;\n this.url = '';\n this.height = 0;\n this.width = 0;\n this.anchorText = [0, 0];\n this.anchorIcon = [0, 0];\n this.textColor = 'black';\n this.textSize = 11;\n this.textDecoration = 'none';\n this.fontWeight = 'bold';\n this.fontStyle = 'normal';\n this.fontFamily = 'Arial,sans-serif';\n this.backgroundPosition = '0 0';\n this.cMouseDownInCluster = null;\n this.cDraggingMapByCluster = null;\n this.timeOut = null;\n this.setMap(cluster.getMap()); // Note: this causes onAdd to be called\n this.onBoundsChanged = this.onBoundsChanged.bind(this);\n this.onMouseDown = this.onMouseDown.bind(this);\n this.onClick = this.onClick.bind(this);\n this.onMouseOver = this.onMouseOver.bind(this);\n this.onMouseOut = this.onMouseOut.bind(this);\n this.onAdd = this.onAdd.bind(this);\n this.onRemove = this.onRemove.bind(this);\n this.draw = this.draw.bind(this);\n this.hide = this.hide.bind(this);\n this.show = this.show.bind(this);\n this.useStyle = this.useStyle.bind(this);\n this.setCenter = this.setCenter.bind(this);\n this.getPosFromLatLng = this.getPosFromLatLng.bind(this);\n }\n ClusterIcon.prototype.onBoundsChanged = function () {\n this.cDraggingMapByCluster = this.cMouseDownInCluster;\n };\n ClusterIcon.prototype.onMouseDown = function () {\n this.cMouseDownInCluster = true;\n this.cDraggingMapByCluster = false;\n };\n ClusterIcon.prototype.onClick = function (event) {\n this.cMouseDownInCluster = false;\n if (!this.cDraggingMapByCluster) {\n var markerClusterer_1 = this.cluster.getClusterer();\n /**\n * This event is fired when a cluster marker is clicked.\n * @name MarkerClusterer#click\n * @param {Cluster} c The cluster that was clicked.\n * @event\n */\n google.maps.event.trigger(markerClusterer_1, 'click', this.cluster);\n google.maps.event.trigger(markerClusterer_1, 'clusterclick', this.cluster); // deprecated name\n // The default click handler follows. Disable it by setting\n // the zoomOnClick property to false.\n if (markerClusterer_1.getZoomOnClick()) {\n // Zoom into the cluster.\n var maxZoom_1 = markerClusterer_1.getMaxZoom();\n var bounds_1 = this.cluster.getBounds();\n var map = markerClusterer_1.getMap();\n if (map !== null && 'fitBounds' in map) {\n map.fitBounds(bounds_1);\n }\n // There is a fix for Issue 170 here:\n this.timeOut = window.setTimeout(function () {\n var map = markerClusterer_1.getMap();\n if (map !== null) {\n if ('fitBounds' in map) {\n map.fitBounds(bounds_1);\n }\n var zoom = map.getZoom() || 0;\n // Don't zoom beyond the max zoom level\n if (maxZoom_1 !== null && zoom > maxZoom_1) {\n map.setZoom(maxZoom_1 + 1);\n }\n }\n }, 100);\n }\n // Prevent event propagation to the map:\n event.cancelBubble = true;\n if (event.stopPropagation) {\n event.stopPropagation();\n }\n }\n };\n ClusterIcon.prototype.onMouseOver = function () {\n /**\n * This event is fired when the mouse moves over a cluster marker.\n * @name MarkerClusterer#mouseover\n * @param {Cluster} c The cluster that the mouse moved over.\n * @event\n */\n google.maps.event.trigger(this.cluster.getClusterer(), 'mouseover', this.cluster);\n };\n ClusterIcon.prototype.onMouseOut = function () {\n /**\n * This event is fired when the mouse moves out of a cluster marker.\n * @name MarkerClusterer#mouseout\n * @param {Cluster} c The cluster that the mouse moved out of.\n * @event\n */\n google.maps.event.trigger(this.cluster.getClusterer(), 'mouseout', this.cluster);\n };\n ClusterIcon.prototype.onAdd = function () {\n var _a;\n this.div = document.createElement('div');\n this.div.className = this.className;\n if (this.visible) {\n this.show();\n }\n (_a = this.getPanes()) === null || _a === void 0 ? void 0 : _a.overlayMouseTarget.appendChild(this.div);\n var map = this.getMap();\n if (map !== null) {\n // Fix for Issue 157\n this.boundsChangedListener = google.maps.event.addListener(map, 'bounds_changed', this.onBoundsChanged);\n this.div.addEventListener('mousedown', this.onMouseDown);\n this.div.addEventListener('click', this.onClick);\n this.div.addEventListener('mouseover', this.onMouseOver);\n this.div.addEventListener('mouseout', this.onMouseOut);\n }\n };\n ClusterIcon.prototype.onRemove = function () {\n if (this.div && this.div.parentNode) {\n this.hide();\n if (this.boundsChangedListener !== null) {\n google.maps.event.removeListener(this.boundsChangedListener);\n }\n this.div.removeEventListener('mousedown', this.onMouseDown);\n this.div.removeEventListener('click', this.onClick);\n this.div.removeEventListener('mouseover', this.onMouseOver);\n this.div.removeEventListener('mouseout', this.onMouseOut);\n this.div.parentNode.removeChild(this.div);\n if (this.timeOut !== null) {\n window.clearTimeout(this.timeOut);\n this.timeOut = null;\n }\n this.div = null;\n }\n };\n ClusterIcon.prototype.draw = function () {\n if (this.visible && this.div !== null && this.center) {\n var pos = this.getPosFromLatLng(this.center);\n this.div.style.top = pos !== null ? \"\".concat(pos.y, \"px\") : '0';\n this.div.style.left = pos !== null ? \"\".concat(pos.x, \"px\") : '0';\n }\n };\n ClusterIcon.prototype.hide = function () {\n if (this.div) {\n this.div.style.display = 'none';\n }\n this.visible = false;\n };\n ClusterIcon.prototype.show = function () {\n var _a, _b, _c, _d;\n if (this.div && this.center) {\n var divTitle = this.sums === null || typeof this.sums.title === 'undefined' || this.sums.title === '' ? this.cluster.getClusterer().getTitle() : this.sums.title;\n // NOTE: values must be specified in px units\n var bp = this.backgroundPosition.split(' ');\n var spriteH = parseInt(bp[0].replace(/^\\s+|\\s+$/g, ''), 10);\n var spriteV = parseInt(bp[1].replace(/^\\s+|\\s+$/g, ''), 10);\n var pos = this.getPosFromLatLng(this.center);\n this.div.className = this.className;\n this.div.setAttribute('style', \"cursor: pointer; position: absolute; top: \".concat(pos !== null ? \"\".concat(pos.y, \"px\") : '0', \"; left: \").concat(pos !== null ? \"\".concat(pos.x, \"px\") : '0', \"; width: \").concat(this.width, \"px; height: \").concat(this.height, \"px; \"));\n var img = document.createElement('img');\n img.alt = divTitle;\n img.src = this.url;\n img.width = this.width;\n img.height = this.height;\n img.setAttribute('style', \"position: absolute; top: \".concat(spriteV, \"px; left: \").concat(spriteH, \"px\"));\n if (!this.cluster.getClusterer().enableRetinaIcons) {\n img.style.clip = \"rect(-\".concat(spriteV, \"px, -\").concat(spriteH + this.width, \"px, -\").concat(spriteV + this.height, \", -\").concat(spriteH, \")\");\n }\n var textElm = document.createElement('div');\n textElm.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\"));\n if ((_a = this.sums) === null || _a === void 0 ? void 0 : _a.text) textElm.innerText = \"\".concat((_b = this.sums) === null || _b === void 0 ? void 0 : _b.text);\n if ((_c = this.sums) === null || _c === void 0 ? void 0 : _c.html) textElm.innerHTML = \"\".concat((_d = this.sums) === null || _d === void 0 ? void 0 : _d.html);\n this.div.innerHTML = '';\n this.div.appendChild(img);\n this.div.appendChild(textElm);\n this.div.title = divTitle;\n this.div.style.display = '';\n }\n this.visible = true;\n };\n ClusterIcon.prototype.useStyle = function (sums) {\n this.sums = sums;\n var styles = this.cluster.getClusterer().getStyles();\n var style = styles[Math.min(styles.length - 1, Math.max(0, sums.index - 1))];\n this.url = style.url;\n this.height = style.height;\n this.width = style.width;\n if (style.className) this.className = \"\".concat(this.clusterClassName, \" \").concat(style.className);\n this.anchorText = style.anchorText || [0, 0];\n this.anchorIcon = style.anchorIcon || [this.height / 2, this.width / 2];\n this.textColor = style.textColor || 'black';\n this.textSize = style.textSize || 11;\n this.textDecoration = style.textDecoration || 'none';\n this.fontWeight = style.fontWeight || 'bold';\n this.fontStyle = style.fontStyle || 'normal';\n this.fontFamily = style.fontFamily || 'Arial,sans-serif';\n this.backgroundPosition = style.backgroundPosition || '0 0';\n };\n ClusterIcon.prototype.setCenter = function (center) {\n this.center = center;\n };\n ClusterIcon.prototype.getPosFromLatLng = function (latlng) {\n var pos = this.getProjection().fromLatLngToDivPixel(latlng);\n if (pos !== null) {\n pos.x -= this.anchorIcon[1];\n pos.y -= this.anchorIcon[0];\n }\n return pos;\n };\n return ClusterIcon;\n}();\nvar Cluster$1 = /** @class */function () {\n function Cluster(markerClusterer) {\n this.markerClusterer = markerClusterer;\n this.map = this.markerClusterer.getMap();\n this.gridSize = this.markerClusterer.getGridSize();\n this.minClusterSize = this.markerClusterer.getMinimumClusterSize();\n this.averageCenter = this.markerClusterer.getAverageCenter();\n this.markers = [];\n this.center = undefined;\n this.bounds = null;\n this.clusterIcon = new ClusterIcon(this, this.markerClusterer.getStyles());\n this.getSize = this.getSize.bind(this);\n this.getMarkers = this.getMarkers.bind(this);\n this.getCenter = this.getCenter.bind(this);\n this.getMap = this.getMap.bind(this);\n this.getClusterer = this.getClusterer.bind(this);\n this.getBounds = this.getBounds.bind(this);\n this.remove = this.remove.bind(this);\n this.addMarker = this.addMarker.bind(this);\n this.isMarkerInClusterBounds = this.isMarkerInClusterBounds.bind(this);\n this.calculateBounds = this.calculateBounds.bind(this);\n this.updateIcon = this.updateIcon.bind(this);\n this.isMarkerAlreadyAdded = this.isMarkerAlreadyAdded.bind(this);\n }\n Cluster.prototype.getSize = function () {\n return this.markers.length;\n };\n Cluster.prototype.getMarkers = function () {\n return this.markers;\n };\n Cluster.prototype.getCenter = function () {\n return this.center;\n };\n Cluster.prototype.getMap = function () {\n return this.map;\n };\n Cluster.prototype.getClusterer = function () {\n return this.markerClusterer;\n };\n Cluster.prototype.getBounds = function () {\n var bounds = new google.maps.LatLngBounds(this.center, this.center);\n var markers = this.getMarkers();\n for (var i = 0; i < markers.length; i++) {\n var position = markers[i].getPosition();\n if (position) {\n bounds.extend(position);\n }\n }\n return bounds;\n };\n Cluster.prototype.remove = function () {\n this.clusterIcon.setMap(null);\n this.markers = [];\n // eslint-disable-next-line @typescript-eslint/ban-ts-comment\n // @ts-ignore\n delete this.markers;\n };\n Cluster.prototype.addMarker = function (marker) {\n var _a;\n if (this.isMarkerAlreadyAdded(marker)) {\n return false;\n }\n if (!this.center) {\n var position = marker.getPosition();\n if (position) {\n this.center = position;\n this.calculateBounds();\n }\n } else {\n if (this.averageCenter) {\n var position = marker.getPosition();\n if (position) {\n var length_1 = this.markers.length + 1;\n this.center = new google.maps.LatLng((this.center.lat() * (length_1 - 1) + position.lat()) / length_1, (this.center.lng() * (length_1 - 1) + position.lng()) / length_1);\n this.calculateBounds();\n }\n }\n }\n marker.isAdded = true;\n this.markers.push(marker);\n var mCount = this.markers.length;\n var maxZoom = this.markerClusterer.getMaxZoom();\n var zoom = (_a = this.map) === null || _a === void 0 ? void 0 : _a.getZoom();\n if (maxZoom !== null && typeof zoom !== 'undefined' && zoom > maxZoom) {\n // Zoomed in past max zoom, so show the marker.\n if (marker.getMap() !== this.map) {\n marker.setMap(this.map);\n }\n } else if (mCount < this.minClusterSize) {\n // Min cluster size not reached so show the marker.\n if (marker.getMap() !== this.map) {\n marker.setMap(this.map);\n }\n } else if (mCount === this.minClusterSize) {\n // Hide the markers that were showing.\n for (var i = 0; i < mCount; i++) {\n this.markers[i].setMap(null);\n }\n } else {\n marker.setMap(null);\n }\n return true;\n };\n Cluster.prototype.isMarkerInClusterBounds = function (marker) {\n if (this.bounds !== null) {\n var position = marker.getPosition();\n if (position) {\n return this.bounds.contains(position);\n }\n }\n return false;\n };\n Cluster.prototype.calculateBounds = function () {\n this.bounds = this.markerClusterer.getExtendedBounds(new google.maps.LatLngBounds(this.center, this.center));\n };\n Cluster.prototype.updateIcon = function () {\n var _a;\n var mCount = this.markers.length;\n var maxZoom = this.markerClusterer.getMaxZoom();\n var zoom = (_a = this.map) === null || _a === void 0 ? void 0 : _a.getZoom();\n if (maxZoom !== null && typeof zoom !== 'undefined' && zoom > maxZoom) {\n this.clusterIcon.hide();\n return;\n }\n if (mCount < this.minClusterSize) {\n // Min cluster size not yet reached.\n this.clusterIcon.hide();\n return;\n }\n if (this.center) {\n this.clusterIcon.setCenter(this.center);\n }\n this.clusterIcon.useStyle(this.markerClusterer.getCalculator()(this.markers, this.markerClusterer.getStyles().length));\n this.clusterIcon.show();\n };\n Cluster.prototype.isMarkerAlreadyAdded = function (marker) {\n if (this.markers.includes) {\n return this.markers.includes(marker);\n }\n for (var i = 0; i < this.markers.length; i++) {\n if (marker === this.markers[i]) {\n return true;\n }\n }\n return false;\n };\n return Cluster;\n}();\n\n/* global google */\n/**\n * Supports up to 9007199254740991 (Number.MAX_SAFE_INTEGER) markers\n * which is not a problem as max array length is 4294967296 (2**32)\n */\nfunction CALCULATOR(markers, numStyles) {\n var count = markers.length;\n var numberOfDigits = count.toString().length;\n var index = Math.min(numberOfDigits, numStyles);\n return {\n text: count.toString(),\n index: index,\n title: ''\n };\n}\nvar BATCH_SIZE = 2000;\nvar BATCH_SIZE_IE = 500;\nvar IMAGE_PATH = 'https://developers.google.com/maps/documentation/javascript/examples/markerclusterer/m';\nvar IMAGE_EXTENSION = 'png';\nvar IMAGE_SIZES = [53, 56, 66, 78, 90];\nvar CLUSTERER_CLASS = 'cluster';\nvar Clusterer = /** @class */function () {\n function Clusterer(map, optMarkers, optOptions) {\n if (optMarkers === void 0) {\n optMarkers = [];\n }\n if (optOptions === void 0) {\n optOptions = {};\n }\n this.getMinimumClusterSize = this.getMinimumClusterSize.bind(this);\n this.setMinimumClusterSize = this.setMinimumClusterSize.bind(this);\n this.getEnableRetinaIcons = this.getEnableRetinaIcons.bind(this);\n this.setEnableRetinaIcons = this.setEnableRetinaIcons.bind(this);\n this.addToClosestCluster = this.addToClosestCluster.bind(this);\n this.getImageExtension = this.getImageExtension.bind(this);\n this.setImageExtension = this.setImageExtension.bind(this);\n this.getExtendedBounds = this.getExtendedBounds.bind(this);\n this.getAverageCenter = this.getAverageCenter.bind(this);\n this.setAverageCenter = this.setAverageCenter.bind(this);\n this.getTotalClusters = this.getTotalClusters.bind(this);\n this.fitMapToMarkers = this.fitMapToMarkers.bind(this);\n this.getIgnoreHidden = this.getIgnoreHidden.bind(this);\n this.setIgnoreHidden = this.setIgnoreHidden.bind(this);\n this.getClusterClass = this.getClusterClass.bind(this);\n this.setClusterClass = this.setClusterClass.bind(this);\n this.getTotalMarkers = this.getTotalMarkers.bind(this);\n this.getZoomOnClick = this.getZoomOnClick.bind(this);\n this.setZoomOnClick = this.setZoomOnClick.bind(this);\n this.getBatchSizeIE = this.getBatchSizeIE.bind(this);\n this.setBatchSizeIE = this.setBatchSizeIE.bind(this);\n this.createClusters = this.createClusters.bind(this);\n this.onZoomChanged = this.onZoomChanged.bind(this);\n this.getImageSizes = this.getImageSizes.bind(this);\n this.setImageSizes = this.setImageSizes.bind(this);\n this.getCalculator = this.getCalculator.bind(this);\n this.setCalculator = this.setCalculator.bind(this);\n this.removeMarkers = this.removeMarkers.bind(this);\n this.resetViewport = this.resetViewport.bind(this);\n this.getImagePath = this.getImagePath.bind(this);\n this.setImagePath = this.setImagePath.bind(this);\n this.pushMarkerTo = this.pushMarkerTo.bind(this);\n this.removeMarker = this.removeMarker.bind(this);\n this.clearMarkers = this.clearMarkers.bind(this);\n this.setupStyles = this.setupStyles.bind(this);\n this.getGridSize = this.getGridSize.bind(this);\n this.setGridSize = this.setGridSize.bind(this);\n this.getClusters = this.getClusters.bind(this);\n this.getMaxZoom = this.getMaxZoom.bind(this);\n this.setMaxZoom = this.setMaxZoom.bind(this);\n this.getMarkers = this.getMarkers.bind(this);\n this.addMarkers = this.addMarkers.bind(this);\n this.getStyles = this.getStyles.bind(this);\n this.setStyles = this.setStyles.bind(this);\n this.addMarker = this.addMarker.bind(this);\n this.onRemove = this.onRemove.bind(this);\n this.getTitle = this.getTitle.bind(this);\n this.setTitle = this.setTitle.bind(this);\n this.repaint = this.repaint.bind(this);\n this.onIdle = this.onIdle.bind(this);\n this.redraw = this.redraw.bind(this);\n this.extend = this.extend.bind(this);\n this.onAdd = this.onAdd.bind(this);\n this.draw = this.draw.bind(this);\n this.extend(Clusterer, google.maps.OverlayView);\n this.markers = [];\n this.clusters = [];\n this.listeners = [];\n this.activeMap = null;\n this.ready = false;\n this.gridSize = optOptions.gridSize || 60;\n this.minClusterSize = optOptions.minimumClusterSize || 2;\n this.maxZoom = optOptions.maxZoom || null;\n this.styles = optOptions.styles || [];\n this.title = optOptions.title || '';\n this.zoomOnClick = true;\n if (optOptions.zoomOnClick !== undefined) {\n this.zoomOnClick = optOptions.zoomOnClick;\n }\n this.averageCenter = false;\n if (optOptions.averageCenter !== undefined) {\n this.averageCenter = optOptions.averageCenter;\n }\n this.ignoreHidden = false;\n if (optOptions.ignoreHidden !== undefined) {\n this.ignoreHidden = optOptions.ignoreHidden;\n }\n this.enableRetinaIcons = false;\n if (optOptions.enableRetinaIcons !== undefined) {\n this.enableRetinaIcons = optOptions.enableRetinaIcons;\n }\n this.imagePath = optOptions.imagePath || IMAGE_PATH;\n this.imageExtension = optOptions.imageExtension || IMAGE_EXTENSION;\n this.imageSizes = optOptions.imageSizes || IMAGE_SIZES;\n this.calculator = optOptions.calculator || CALCULATOR;\n this.batchSize = optOptions.batchSize || BATCH_SIZE;\n this.batchSizeIE = optOptions.batchSizeIE || BATCH_SIZE_IE;\n this.clusterClass = optOptions.clusterClass || CLUSTERER_CLASS;\n if (navigator.userAgent.toLowerCase().indexOf('msie') !== -1) {\n // Try to avoid IE timeout when processing a huge number of markers:\n this.batchSize = this.batchSizeIE;\n }\n this.timerRefStatic = null;\n this.setupStyles();\n this.addMarkers(optMarkers, true);\n this.setMap(map); // Note: this causes onAdd to be called\n }\n\n Clusterer.prototype.onZoomChanged = function () {\n var _a, _b;\n this.resetViewport(false);\n // Workaround for this Google bug: when map is at level 0 and \"-\" of\n // zoom slider is clicked, a \"zoom_changed\" event is fired even though\n // the map doesn't zoom out any further. In this situation, no \"idle\"\n // event is triggered so the cluster markers that have been removed\n // do not get redrawn. Same goes for a zoom in at maxZoom.\n if (((_a = this.getMap()) === null || _a === void 0 ? void 0 : _a.getZoom()) === (this.get('minZoom') || 0) || ((_b = this.getMap()) === null || _b === void 0 ? void 0 : _b.getZoom()) === this.get('maxZoom')) {\n google.maps.event.trigger(this, 'idle');\n }\n };\n Clusterer.prototype.onIdle = function () {\n this.redraw();\n };\n Clusterer.prototype.onAdd = function () {\n var map = this.getMap();\n this.activeMap = map;\n this.ready = true;\n this.repaint();\n if (map !== null) {\n // Add the map event listeners\n this.listeners = [google.maps.event.addListener(map, 'zoom_changed', this.onZoomChanged), google.maps.event.addListener(map, 'idle', this.onIdle)];\n }\n };\n Clusterer.prototype.onRemove = function () {\n // Put all the managed markers back on the map:\n for (var i = 0; i < this.markers.length; i++) {\n if (this.markers[i].getMap() !== this.activeMap) {\n this.markers[i].setMap(this.activeMap);\n }\n }\n // Remove all clusters:\n for (var i = 0; i < this.clusters.length; i++) {\n this.clusters[i].remove();\n }\n this.clusters = [];\n // Remove map event listeners:\n for (var i = 0; i < this.listeners.length; i++) {\n google.maps.event.removeListener(this.listeners[i]);\n }\n this.listeners = [];\n this.activeMap = null;\n this.ready = false;\n };\n Clusterer.prototype.draw = function () {\n return;\n };\n Clusterer.prototype.setupStyles = function () {\n if (this.styles.length > 0) {\n return;\n }\n for (var i = 0; i < this.imageSizes.length; i++) {\n this.styles.push({\n url: \"\".concat(this.imagePath + (i + 1), \".\").concat(this.imageExtension),\n height: this.imageSizes[i],\n width: this.imageSizes[i]\n });\n }\n };\n Clusterer.prototype.fitMapToMarkers = function () {\n var markers = this.getMarkers();\n var bounds = new google.maps.LatLngBounds();\n for (var i = 0; i < markers.length; i++) {\n var position = markers[i].getPosition();\n if (position) {\n bounds.extend(position);\n }\n }\n var map = this.getMap();\n if (map !== null && 'fitBounds' in map) {\n map.fitBounds(bounds);\n }\n };\n Clusterer.prototype.getGridSize = function () {\n return this.gridSize;\n };\n Clusterer.prototype.setGridSize = function (gridSize) {\n this.gridSize = gridSize;\n };\n Clusterer.prototype.getMinimumClusterSize = function () {\n return this.minClusterSize;\n };\n Clusterer.prototype.setMinimumClusterSize = function (minimumClusterSize) {\n this.minClusterSize = minimumClusterSize;\n };\n Clusterer.prototype.getMaxZoom = function () {\n return this.maxZoom;\n };\n Clusterer.prototype.setMaxZoom = function (maxZoom) {\n this.maxZoom = maxZoom;\n };\n Clusterer.prototype.getStyles = function () {\n return this.styles;\n };\n Clusterer.prototype.setStyles = function (styles) {\n this.styles = styles;\n };\n Clusterer.prototype.getTitle = function () {\n return this.title;\n };\n Clusterer.prototype.setTitle = function (title) {\n this.title = title;\n };\n Clusterer.prototype.getZoomOnClick = function () {\n return this.zoomOnClick;\n };\n Clusterer.prototype.setZoomOnClick = function (zoomOnClick) {\n this.zoomOnClick = zoomOnClick;\n };\n Clusterer.prototype.getAverageCenter = function () {\n return this.averageCenter;\n };\n Clusterer.prototype.setAverageCenter = function (averageCenter) {\n this.averageCenter = averageCenter;\n };\n Clusterer.prototype.getIgnoreHidden = function () {\n return this.ignoreHidden;\n };\n Clusterer.prototype.setIgnoreHidden = function (ignoreHidden) {\n this.ignoreHidden = ignoreHidden;\n };\n Clusterer.prototype.getEnableRetinaIcons = function () {\n return this.enableRetinaIcons;\n };\n Clusterer.prototype.setEnableRetinaIcons = function (enableRetinaIcons) {\n this.enableRetinaIcons = enableRetinaIcons;\n };\n Clusterer.prototype.getImageExtension = function () {\n return this.imageExtension;\n };\n Clusterer.prototype.setImageExtension = function (imageExtension) {\n this.imageExtension = imageExtension;\n };\n Clusterer.prototype.getImagePath = function () {\n return this.imagePath;\n };\n Clusterer.prototype.setImagePath = function (imagePath) {\n this.imagePath = imagePath;\n };\n Clusterer.prototype.getImageSizes = function () {\n return this.imageSizes;\n };\n Clusterer.prototype.setImageSizes = function (imageSizes) {\n this.imageSizes = imageSizes;\n };\n Clusterer.prototype.getCalculator = function () {\n return this.calculator;\n };\n Clusterer.prototype.setCalculator = function (calculator) {\n this.calculator = calculator;\n };\n Clusterer.prototype.getBatchSizeIE = function () {\n return this.batchSizeIE;\n };\n Clusterer.prototype.setBatchSizeIE = function (batchSizeIE) {\n this.batchSizeIE = batchSizeIE;\n };\n Clusterer.prototype.getClusterClass = function () {\n return this.clusterClass;\n };\n Clusterer.prototype.setClusterClass = function (clusterClass) {\n this.clusterClass = clusterClass;\n };\n Clusterer.prototype.getMarkers = function () {\n return this.markers;\n };\n Clusterer.prototype.getTotalMarkers = function () {\n return this.markers.length;\n };\n Clusterer.prototype.getClusters = function () {\n return this.clusters;\n };\n Clusterer.prototype.getTotalClusters = function () {\n return this.clusters.length;\n };\n Clusterer.prototype.addMarker = function (marker, optNoDraw) {\n this.pushMarkerTo(marker);\n if (!optNoDraw) {\n this.redraw();\n }\n };\n Clusterer.prototype.addMarkers = function (markers, optNoDraw) {\n for (var key in markers) {\n if (Object.prototype.hasOwnProperty.call(markers, key)) {\n this.pushMarkerTo(markers[key]);\n }\n }\n if (!optNoDraw) {\n this.redraw();\n }\n };\n Clusterer.prototype.pushMarkerTo = function (marker) {\n var _this = this;\n // If the marker is draggable add a listener so we can update the clusters on the dragend:\n if (marker.getDraggable()) {\n google.maps.event.addListener(marker, 'dragend', function () {\n if (_this.ready) {\n marker.isAdded = false;\n _this.repaint();\n }\n });\n }\n marker.isAdded = false;\n this.markers.push(marker);\n };\n Clusterer.prototype.removeMarker_ = function (marker) {\n var index = -1;\n if (this.markers.indexOf) {\n index = this.markers.indexOf(marker);\n } else {\n for (var i = 0; i < this.markers.length; i++) {\n if (marker === this.markers[i]) {\n index = i;\n break;\n }\n }\n }\n if (index === -1) {\n // Marker is not in our list of markers, so do nothing:\n return false;\n }\n marker.setMap(null);\n this.markers.splice(index, 1); // Remove the marker from the list of managed markers\n return true;\n };\n Clusterer.prototype.removeMarker = function (marker, optNoDraw) {\n var removed = this.removeMarker_(marker);\n if (!optNoDraw && removed) {\n this.repaint();\n }\n return removed;\n };\n Clusterer.prototype.removeMarkers = function (markers, optNoDraw) {\n var removed = false;\n for (var i = 0; i < markers.length; i++) {\n removed = removed || this.removeMarker_(markers[i]);\n }\n if (!optNoDraw && removed) {\n this.repaint();\n }\n return removed;\n };\n Clusterer.prototype.clearMarkers = function () {\n this.resetViewport(true);\n this.markers = [];\n };\n Clusterer.prototype.repaint = function () {\n var oldClusters = this.clusters.slice();\n this.clusters = [];\n this.resetViewport(false);\n this.redraw();\n // Remove the old clusters.\n // Do it in a timeout to prevent blinking effect.\n setTimeout(function timeout() {\n for (var i = 0; i < oldClusters.length; i++) {\n oldClusters[i].remove();\n }\n }, 0);\n };\n Clusterer.prototype.getExtendedBounds = function (bounds) {\n var projection = this.getProjection();\n // Convert the points to pixels and the extend out by the grid size.\n var trPix = projection.fromLatLngToDivPixel(\n // Turn the bounds into latlng.\n new google.maps.LatLng(bounds.getNorthEast().lat(), bounds.getNorthEast().lng()));\n if (trPix !== null) {\n trPix.x += this.gridSize;\n trPix.y -= this.gridSize;\n }\n var blPix = projection.fromLatLngToDivPixel(\n // Turn the bounds into latlng.\n new google.maps.LatLng(bounds.getSouthWest().lat(), bounds.getSouthWest().lng()));\n if (blPix !== null) {\n blPix.x -= this.gridSize;\n blPix.y += this.gridSize;\n }\n // Extend the bounds to contain the new bounds.\n if (trPix !== null) {\n // Convert the pixel points back to LatLng nw\n var point1 = projection.fromDivPixelToLatLng(trPix);\n if (point1 !== null) {\n bounds.extend(point1);\n }\n }\n if (blPix !== null) {\n // Convert the pixel points back to LatLng sw\n var point2 = projection.fromDivPixelToLatLng(blPix);\n if (point2 !== null) {\n bounds.extend(point2);\n }\n }\n return bounds;\n };\n Clusterer.prototype.redraw = function () {\n // Redraws all the clusters.\n this.createClusters(0);\n };\n Clusterer.prototype.resetViewport = function (optHide) {\n // Remove all the clusters\n for (var i = 0; i < this.clusters.length; i++) {\n this.clusters[i].remove();\n }\n this.clusters = [];\n // Reset the markers to not be added and to be removed from the map.\n for (var i = 0; i < this.markers.length; i++) {\n var marker = this.markers[i];\n marker.isAdded = false;\n if (optHide) {\n marker.setMap(null);\n }\n }\n };\n Clusterer.prototype.distanceBetweenPoints = function (p1, p2) {\n var R = 6371; // Radius of the Earth in km\n var dLat = (p2.lat() - p1.lat()) * Math.PI / 180;\n var dLon = (p2.lng() - p1.lng()) * Math.PI / 180;\n var a = Math.sin(dLat / 2) * Math.sin(dLat / 2) + Math.cos(p1.lat() * Math.PI / 180) * Math.cos(p2.lat() * Math.PI / 180) * Math.sin(dLon / 2) * Math.sin(dLon / 2);\n return R * (2 * Math.atan2(Math.sqrt(a), Math.sqrt(1 - a)));\n };\n Clusterer.prototype.isMarkerInBounds = function (marker, bounds) {\n var position = marker.getPosition();\n if (position) {\n return bounds.contains(position);\n }\n return false;\n };\n Clusterer.prototype.addToClosestCluster = function (marker) {\n var cluster;\n var distance = 40000; // Some large number\n var clusterToAddTo = null;\n for (var i = 0; i < this.clusters.length; i++) {\n cluster = this.clusters[i];\n var center = cluster.getCenter();\n var position = marker.getPosition();\n if (center && position) {\n var d = this.distanceBetweenPoints(center, position);\n if (d < distance) {\n distance = d;\n clusterToAddTo = cluster;\n }\n }\n }\n if (clusterToAddTo && clusterToAddTo.isMarkerInClusterBounds(marker)) {\n clusterToAddTo.addMarker(marker);\n } else {\n cluster = new Cluster$1(this);\n cluster.addMarker(marker);\n this.clusters.push(cluster);\n }\n };\n Clusterer.prototype.createClusters = function (iFirst) {\n var _this = this;\n if (!this.ready) {\n return;\n }\n // Cancel previous batch processing if we're working on the first batch:\n if (iFirst === 0) {\n /**\n * This event is fired when the Clusterer begins\n * clustering markers.\n * @name Clusterer#clusteringbegin\n * @param {Clusterer} mc The Clusterer whose markers are being clustered.\n * @event\n */\n google.maps.event.trigger(this, 'clusteringbegin', this);\n if (this.timerRefStatic !== null) {\n window.clearTimeout(this.timerRefStatic);\n // eslint-disable-next-line @typescript-eslint/ban-ts-comment\n // @ts-ignore\n delete this.timerRefStatic;\n }\n }\n var map = this.getMap();\n var bounds = map !== null && 'getBounds' in map ? map.getBounds() : null;\n var zoom = (map === null || map === void 0 ? void 0 : map.getZoom()) || 0;\n // Get our current map view bounds.\n // Create a new bounds object so we don't affect the map.\n //\n // See Comments 9 & 11 on Issue 3651 relating to this workaround for a Google Maps bug:\n var mapBounds = zoom > 3 ? new google.maps.LatLngBounds(bounds === null || bounds === void 0 ? void 0 : bounds.getSouthWest(), bounds === null || bounds === void 0 ? void 0 : bounds.getNorthEast()) : new google.maps.LatLngBounds(new google.maps.LatLng(85.02070771743472, -178.48388434375), new google.maps.LatLng(-85.08136444384544, 178.00048865625));\n var extendedMapBounds = this.getExtendedBounds(mapBounds);\n var iLast = Math.min(iFirst + this.batchSize, this.markers.length);\n for (var i = iFirst; i < iLast; i++) {\n var marker = this.markers[i];\n if (!marker.isAdded && this.isMarkerInBounds(marker, extendedMapBounds) && (!this.ignoreHidden || this.ignoreHidden && marker.getVisible())) {\n this.addToClosestCluster(marker);\n }\n }\n if (iLast < this.markers.length) {\n this.timerRefStatic = window.setTimeout(function () {\n _this.createClusters(iLast);\n }, 0);\n } else {\n this.timerRefStatic = null;\n /**\n * This event is fired when the Clusterer stops\n * clustering markers.\n * @name Clusterer#clusteringend\n * @param {Clusterer} mc The Clusterer whose markers are being clustered.\n * @event\n */\n google.maps.event.trigger(this, 'clusteringend', this);\n for (var i = 0; i < this.clusters.length; i++) {\n this.clusters[i].updateIcon();\n }\n }\n };\n Clusterer.prototype.extend = function (obj1, obj2) {\n return function applyExtend(object) {\n for (var property in object.prototype) {\n // @ts-ignore\n this.prototype[property] = object.prototype[property];\n }\n return this;\n }.apply(obj1, [obj2]);\n };\n return Clusterer;\n}();\nconst eventMap$e = {\n onClick: 'click',\n onClusteringBegin: 'clusteringbegin',\n onClusteringEnd: 'clusteringend',\n onMouseOut: 'mouseout',\n onMouseOver: 'mouseover'\n};\nconst updaterMap$e = {\n averageCenter(instance, averageCenter) {\n instance.setAverageCenter(averageCenter);\n },\n batchSizeIE(instance, batchSizeIE) {\n instance.setBatchSizeIE(batchSizeIE);\n },\n calculator(instance, calculator) {\n instance.setCalculator(calculator);\n },\n clusterClass(instance, clusterClass) {\n instance.setClusterClass(clusterClass);\n },\n enableRetinaIcons(instance, enableRetinaIcons) {\n instance.setEnableRetinaIcons(enableRetinaIcons);\n },\n gridSize(instance, gridSize) {\n instance.setGridSize(gridSize);\n },\n ignoreHidden(instance, ignoreHidden) {\n instance.setIgnoreHidden(ignoreHidden);\n },\n imageExtension(instance, imageExtension) {\n instance.setImageExtension(imageExtension);\n },\n imagePath(instance, imagePath) {\n instance.setImagePath(imagePath);\n },\n imageSizes(instance, imageSizes) {\n instance.setImageSizes(imageSizes);\n },\n maxZoom(instance, maxZoom) {\n instance.setMaxZoom(maxZoom);\n },\n minimumClusterSize(instance, minimumClusterSize) {\n instance.setMinimumClusterSize(minimumClusterSize);\n },\n styles(instance, styles) {\n instance.setStyles(styles);\n },\n title(instance, title) {\n instance.setTitle(title);\n },\n zoomOnClick(instance, zoomOnClick) {\n instance.setZoomOnClick(zoomOnClick);\n }\n};\nconst defaultOptions$4 = {};\nfunction MarkerClustererFunctional(props) {\n const children = props.children,\n options = props.options,\n averageCenter = props.averageCenter,\n batchSizeIE = props.batchSizeIE,\n calculator = props.calculator,\n clusterClass = props.clusterClass,\n enableRetinaIcons = props.enableRetinaIcons,\n gridSize = props.gridSize,\n ignoreHidden = props.ignoreHidden,\n imageExtension = props.imageExtension,\n imagePath = props.imagePath,\n imageSizes = props.imageSizes,\n maxZoom = props.maxZoom,\n minimumClusterSize = props.minimumClusterSize,\n styles = props.styles,\n title = props.title,\n zoomOnClick = props.zoomOnClick,\n onClick = props.onClick,\n onClusteringBegin = props.onClusteringBegin,\n onClusteringEnd = props.onClusteringEnd,\n onMouseOver = props.onMouseOver,\n onMouseOut = props.onMouseOut,\n onLoad = props.onLoad,\n onUnmount = props.onUnmount;\n const _useState99 = useState(null),\n _useState100 = _slicedToArray(_useState99, 2),\n instance = _useState100[0],\n setInstance = _useState100[1];\n const map = useContext(MapContext);\n const _useState101 = useState(null),\n _useState102 = _slicedToArray(_useState101, 2),\n clickListener = _useState102[0],\n setClickListener = _useState102[1];\n const _useState103 = useState(null),\n _useState104 = _slicedToArray(_useState103, 2),\n clusteringBeginListener = _useState104[0],\n setClusteringBeginListener = _useState104[1];\n const _useState105 = useState(null),\n _useState106 = _slicedToArray(_useState105, 2),\n clusteringEndListener = _useState106[0],\n setClusteringEndListener = _useState106[1];\n const _useState107 = useState(null),\n _useState108 = _slicedToArray(_useState107, 2),\n mouseoutListener = _useState108[0],\n setMouseoutListener = _useState108[1];\n const _useState109 = useState(null),\n _useState110 = _slicedToArray(_useState109, 2),\n mouseoverListener = _useState110[0],\n setMouseoverListener = _useState110[1];\n useEffect(() => {\n if (instance && onMouseOut) {\n if (mouseoutListener !== null) {\n google.maps.event.removeListener(mouseoutListener);\n }\n setMouseoutListener(google.maps.event.addListener(instance, eventMap$e.onMouseOut, onMouseOut));\n }\n }, [onMouseOut]);\n useEffect(() => {\n if (instance && onMouseOver) {\n if (mouseoverListener !== null) {\n google.maps.event.removeListener(mouseoverListener);\n }\n setMouseoverListener(google.maps.event.addListener(instance, eventMap$e.onMouseOver, onMouseOver));\n }\n }, [onMouseOver]);\n useEffect(() => {\n if (instance && onClick) {\n if (clickListener !== null) {\n google.maps.event.removeListener(clickListener);\n }\n setClickListener(google.maps.event.addListener(instance, eventMap$e.onClick, onClick));\n }\n }, [onClick]);\n useEffect(() => {\n if (instance && onClusteringBegin) {\n if (clusteringBeginListener !== null) {\n google.maps.event.removeListener(clusteringBeginListener);\n }\n setClusteringBeginListener(google.maps.event.addListener(instance, eventMap$e.onClusteringBegin, onClusteringBegin));\n }\n }, [onClusteringBegin]);\n useEffect(() => {\n if (instance && onClusteringEnd) {\n if (clusteringEndListener !== null) {\n google.maps.event.removeListener(clusteringEndListener);\n }\n setClusteringBeginListener(google.maps.event.addListener(instance, eventMap$e.onClusteringEnd, onClusteringEnd));\n }\n }, [onClusteringEnd]);\n useEffect(() => {\n if (typeof averageCenter !== 'undefined' && instance !== null) {\n updaterMap$e.averageCenter(instance, averageCenter);\n }\n }, [instance, averageCenter]);\n useEffect(() => {\n if (typeof batchSizeIE !== 'undefined' && instance !== null) {\n updaterMap$e.batchSizeIE(instance, batchSizeIE);\n }\n }, [instance, batchSizeIE]);\n useEffect(() => {\n if (typeof calculator !== 'undefined' && instance !== null) {\n updaterMap$e.calculator(instance, calculator);\n }\n }, [instance, calculator]);\n useEffect(() => {\n if (typeof clusterClass !== 'undefined' && instance !== null) {\n updaterMap$e.clusterClass(instance, clusterClass);\n }\n }, [instance, clusterClass]);\n useEffect(() => {\n if (typeof enableRetinaIcons !== 'undefined' && instance !== null) {\n updaterMap$e.enableRetinaIcons(instance, enableRetinaIcons);\n }\n }, [instance, enableRetinaIcons]);\n useEffect(() => {\n if (typeof gridSize !== 'undefined' && instance !== null) {\n updaterMap$e.gridSize(instance, gridSize);\n }\n }, [instance, gridSize]);\n useEffect(() => {\n if (typeof ignoreHidden !== 'undefined' && instance !== null) {\n updaterMap$e.ignoreHidden(instance, ignoreHidden);\n }\n }, [instance, ignoreHidden]);\n useEffect(() => {\n if (typeof imageExtension !== 'undefined' && instance !== null) {\n updaterMap$e.imageExtension(instance, imageExtension);\n }\n }, [instance, imageExtension]);\n useEffect(() => {\n if (typeof imagePath !== 'undefined' && instance !== null) {\n updaterMap$e.imagePath(instance, imagePath);\n }\n }, [instance, imagePath]);\n useEffect(() => {\n if (typeof imageSizes !== 'undefined' && instance !== null) {\n updaterMap$e.imageSizes(instance, imageSizes);\n }\n }, [instance, imageSizes]);\n useEffect(() => {\n if (typeof maxZoom !== 'undefined' && instance !== null) {\n updaterMap$e.maxZoom(instance, maxZoom);\n }\n }, [instance, maxZoom]);\n useEffect(() => {\n if (typeof minimumClusterSize !== 'undefined' && instance !== null) {\n updaterMap$e.minimumClusterSize(instance, minimumClusterSize);\n }\n }, [instance, minimumClusterSize]);\n useEffect(() => {\n if (typeof styles !== 'undefined' && instance !== null) {\n updaterMap$e.styles(instance, styles);\n }\n }, [instance, styles]);\n useEffect(() => {\n if (typeof title !== 'undefined' && instance !== null) {\n updaterMap$e.title(instance, title);\n }\n }, [instance, title]);\n useEffect(() => {\n if (typeof zoomOnClick !== 'undefined' && instance !== null) {\n updaterMap$e.zoomOnClick(instance, zoomOnClick);\n }\n }, [instance, zoomOnClick]);\n useEffect(() => {\n if (!map) return;\n const clustererOptions = Object.assign({}, options || defaultOptions$4);\n const clusterer = new Clusterer(map, [], clustererOptions);\n if (averageCenter) {\n updaterMap$e.averageCenter(clusterer, averageCenter);\n }\n if (batchSizeIE) {\n updaterMap$e.batchSizeIE(clusterer, batchSizeIE);\n }\n if (calculator) {\n updaterMap$e.calculator(clusterer, calculator);\n }\n if (clusterClass) {\n updaterMap$e.clusterClass(clusterer, clusterClass);\n }\n if (enableRetinaIcons) {\n updaterMap$e.enableRetinaIcons(clusterer, enableRetinaIcons);\n }\n if (gridSize) {\n updaterMap$e.gridSize(clusterer, gridSize);\n }\n if (ignoreHidden) {\n updaterMap$e.ignoreHidden(clusterer, ignoreHidden);\n }\n if (imageExtension) {\n updaterMap$e.imageExtension(clusterer, imageExtension);\n }\n if (imagePath) {\n updaterMap$e.imagePath(clusterer, imagePath);\n }\n if (imageSizes) {\n updaterMap$e.imageSizes(clusterer, imageSizes);\n }\n if (maxZoom) {\n updaterMap$e.maxZoom(clusterer, maxZoom);\n }\n if (minimumClusterSize) {\n updaterMap$e.minimumClusterSize(clusterer, minimumClusterSize);\n }\n if (styles) {\n updaterMap$e.styles(clusterer, styles);\n }\n if (title) {\n updaterMap$e.title(clusterer, title);\n }\n if (zoomOnClick) {\n updaterMap$e.zoomOnClick(clusterer, zoomOnClick);\n }\n if (onMouseOut) {\n setMouseoutListener(google.maps.event.addListener(clusterer, eventMap$e.onMouseOut, onMouseOut));\n }\n if (onMouseOver) {\n setMouseoverListener(google.maps.event.addListener(clusterer, eventMap$e.onMouseOver, onMouseOver));\n }\n if (onClick) {\n setClickListener(google.maps.event.addListener(clusterer, eventMap$e.onClick, onClick));\n }\n if (onClusteringBegin) {\n setClusteringBeginListener(google.maps.event.addListener(clusterer, eventMap$e.onClusteringBegin, onClusteringBegin));\n }\n if (onClusteringEnd) {\n setClusteringEndListener(google.maps.event.addListener(clusterer, eventMap$e.onClusteringEnd, onClusteringEnd));\n }\n setInstance(clusterer);\n if (onLoad) {\n onLoad(clusterer);\n }\n return () => {\n if (mouseoutListener !== null) {\n google.maps.event.removeListener(mouseoutListener);\n }\n if (mouseoverListener !== null) {\n google.maps.event.removeListener(mouseoverListener);\n }\n if (clickListener !== null) {\n google.maps.event.removeListener(clickListener);\n }\n if (clusteringBeginListener !== null) {\n google.maps.event.removeListener(clusteringBeginListener);\n }\n if (clusteringEndListener !== null) {\n google.maps.event.removeListener(clusteringEndListener);\n }\n if (onUnmount) {\n onUnmount(clusterer);\n }\n };\n }, []);\n return instance !== null ? children(instance) || null : null;\n}\nconst MarkerClustererF = /*#__PURE__*/memo(MarkerClustererFunctional);\nclass ClustererComponent extends PureComponent {\n constructor() {\n super(...arguments);\n this.registeredEvents = [];\n this.state = {\n markerClusterer: null\n };\n this.setClustererCallback = () => {\n if (this.state.markerClusterer !== null && this.props.onLoad) {\n this.props.onLoad(this.state.markerClusterer);\n }\n };\n }\n componentDidMount() {\n if (this.context) {\n const markerClusterer = new Clusterer(this.context, [], this.props.options);\n this.registeredEvents = applyUpdatersToPropsAndRegisterEvents({\n updaterMap: updaterMap$e,\n eventMap: eventMap$e,\n prevProps: {},\n nextProps: this.props,\n instance: markerClusterer\n });\n this.setState(() => {\n return {\n markerClusterer\n };\n }, this.setClustererCallback);\n }\n }\n componentDidUpdate(prevProps) {\n if (this.state.markerClusterer) {\n unregisterEvents(this.registeredEvents);\n this.registeredEvents = applyUpdatersToPropsAndRegisterEvents({\n updaterMap: updaterMap$e,\n eventMap: eventMap$e,\n prevProps,\n nextProps: this.props,\n instance: this.state.markerClusterer\n });\n }\n }\n componentWillUnmount() {\n if (this.state.markerClusterer !== null) {\n if (this.props.onUnmount) {\n this.props.onUnmount(this.state.markerClusterer);\n }\n unregisterEvents(this.registeredEvents);\n // eslint-disable-next-line @typescript-eslint/ban-ts-comment\n // @ts-ignore\n this.state.markerClusterer.setMap(null);\n }\n }\n render() {\n return this.state.markerClusterer !== null ? this.props.children(this.state.markerClusterer) : null;\n }\n}\nClustererComponent.contextType = MapContext;\n\n// This handler prevents an event in the InfoBox from being passed on to the map.\nfunction cancelHandler(event) {\n event.cancelBubble = true;\n if (event.stopPropagation) {\n event.stopPropagation();\n }\n}\nvar InfoBox = /** @class */function () {\n function InfoBox(options) {\n if (options === void 0) {\n options = {};\n }\n this.getCloseClickHandler = this.getCloseClickHandler.bind(this);\n this.closeClickHandler = this.closeClickHandler.bind(this);\n this.createInfoBoxDiv = this.createInfoBoxDiv.bind(this);\n this.addClickHandler = this.addClickHandler.bind(this);\n this.getCloseBoxImg = this.getCloseBoxImg.bind(this);\n this.getBoxWidths = this.getBoxWidths.bind(this);\n this.setBoxStyle = this.setBoxStyle.bind(this);\n this.setPosition = this.setPosition.bind(this);\n this.getPosition = this.getPosition.bind(this);\n this.setOptions = this.setOptions.bind(this);\n this.setContent = this.setContent.bind(this);\n this.setVisible = this.setVisible.bind(this);\n this.getContent = this.getContent.bind(this);\n this.getVisible = this.getVisible.bind(this);\n this.setZIndex = this.setZIndex.bind(this);\n this.getZIndex = this.getZIndex.bind(this);\n this.onRemove = this.onRemove.bind(this);\n this.panBox = this.panBox.bind(this);\n this.extend = this.extend.bind(this);\n this.close = this.close.bind(this);\n this.draw = this.draw.bind(this);\n this.show = this.show.bind(this);\n this.hide = this.hide.bind(this);\n this.open = this.open.bind(this);\n this.extend(InfoBox, google.maps.OverlayView);\n // Standard options (in common with google.maps.InfoWindow):\n this.content = options.content || '';\n this.disableAutoPan = options.disableAutoPan || false;\n this.maxWidth = options.maxWidth || 0;\n this.pixelOffset = options.pixelOffset || new google.maps.Size(0, 0);\n this.position = options.position || new google.maps.LatLng(0, 0);\n this.zIndex = options.zIndex || null;\n // Additional options (unique to InfoBox):\n this.boxClass = options.boxClass || 'infoBox';\n this.boxStyle = options.boxStyle || {};\n this.closeBoxMargin = options.closeBoxMargin || '2px';\n this.closeBoxURL = options.closeBoxURL || 'http://www.google.com/intl/en_us/mapfiles/close.gif';\n if (options.closeBoxURL === '') {\n this.closeBoxURL = '';\n }\n this.infoBoxClearance = options.infoBoxClearance || new google.maps.Size(1, 1);\n if (typeof options.visible === 'undefined') {\n if (typeof options.isHidden === 'undefined') {\n options.visible = true;\n } else {\n options.visible = !options.isHidden;\n }\n }\n this.isHidden = !options.visible;\n this.alignBottom = options.alignBottom || false;\n this.pane = options.pane || 'floatPane';\n this.enableEventPropagation = options.enableEventPropagation || false;\n this.div = null;\n this.closeListener = null;\n this.moveListener = null;\n this.mapListener = null;\n this.contextListener = null;\n this.eventListeners = null;\n this.fixedWidthSet = null;\n }\n InfoBox.prototype.createInfoBoxDiv = function () {\n var _this = this;\n // This handler ignores the current event in the InfoBox and conditionally prevents\n // the event from being passed on to the map. It is used for the contextmenu event.\n var ignoreHandler = function (event) {\n event.returnValue = false;\n if (event.preventDefault) {\n event.preventDefault();\n }\n if (!_this.enableEventPropagation) {\n cancelHandler(event);\n }\n };\n if (!this.div) {\n this.div = document.createElement('div');\n this.setBoxStyle();\n if (typeof this.content === 'string') {\n this.div.innerHTML = this.getCloseBoxImg() + this.content;\n } else {\n this.div.innerHTML = this.getCloseBoxImg();\n this.div.appendChild(this.content);\n }\n var panes = this.getPanes();\n if (panes !== null) {\n panes[this.pane].appendChild(this.div); // Add the InfoBox div to the DOM\n }\n\n this.addClickHandler();\n if (this.div.style.width) {\n this.fixedWidthSet = true;\n } else {\n if (this.maxWidth !== 0 && this.div.offsetWidth > this.maxWidth) {\n this.div.style.width = this.maxWidth + 'px';\n this.fixedWidthSet = true;\n } else {\n // The following code is needed to overcome problems with MSIE\n var bw = this.getBoxWidths();\n this.div.style.width = this.div.offsetWidth - bw.left - bw.right + 'px';\n this.fixedWidthSet = false;\n }\n }\n this.panBox(this.disableAutoPan);\n if (!this.enableEventPropagation) {\n this.eventListeners = [];\n // Cancel event propagation.\n // Note: mousemove not included (to resolve Issue 152)\n var events = ['mousedown', 'mouseover', 'mouseout', 'mouseup', 'click', 'dblclick', 'touchstart', 'touchend', 'touchmove'];\n for (var i = 0; i < events.length; i++) {\n this.eventListeners.push(google.maps.event.addListener(this.div, events[i], cancelHandler));\n }\n // Workaround for Google bug that causes the cursor to change to a pointer\n // when the mouse moves over a marker underneath InfoBox.\n this.eventListeners.push(google.maps.event.addListener(this.div, 'mouseover', function () {\n if (_this.div) {\n _this.div.style.cursor = 'default';\n }\n }));\n }\n this.contextListener = google.maps.event.addListener(this.div, 'contextmenu', ignoreHandler);\n /**\n * This event is fired when the DIV containing the InfoBox's content is attached to the DOM.\n * @name InfoBox#domready\n * @event\n */\n google.maps.event.trigger(this, 'domready');\n }\n };\n InfoBox.prototype.getCloseBoxImg = function () {\n var img = '';\n if (this.closeBoxURL !== '') {\n img = '\"\"';\n\";\n }\n return img;\n };\n InfoBox.prototype.addClickHandler = function () {\n this.closeListener = this.div && this.div.firstChild && this.closeBoxURL !== '' ? google.maps.event.addListener(this.div.firstChild, 'click', this.getCloseClickHandler()) : null;\n };\n InfoBox.prototype.closeClickHandler = function (event) {\n // 1.0.3 fix: Always prevent propagation of a close box click to the map:\n event.cancelBubble = true;\n if (event.stopPropagation) {\n event.stopPropagation();\n }\n /**\n * This event is fired when the InfoBox's close box is clicked.\n * @name InfoBox#closeclick\n * @event\n */\n google.maps.event.trigger(this, 'closeclick');\n this.close();\n };\n InfoBox.prototype.getCloseClickHandler = function () {\n return this.closeClickHandler;\n };\n InfoBox.prototype.panBox = function (disablePan) {\n if (this.div && !disablePan) {\n // eslint-disable-next-line @typescript-eslint/ban-ts-comment\n // @ts-ignore\n var map = this.getMap();\n // Only pan if attached to map, not panorama\n if (map instanceof google.maps.Map) {\n var xOffset = 0;\n var yOffset = 0;\n var bounds = map.getBounds();\n if (bounds && !bounds.contains(this.position)) {\n // Marker not in visible area of map, so set center\n // of map to the marker position first.\n map.setCenter(this.position);\n }\n var mapDiv = map.getDiv();\n // eslint-disable-next-line @typescript-eslint/ban-ts-comment\n // @ts-ignore\n var mapWidth = mapDiv.offsetWidth;\n // eslint-disable-next-line @typescript-eslint/ban-ts-comment\n // @ts-ignore\n var mapHeight = mapDiv.offsetHeight;\n var iwOffsetX = this.pixelOffset.width;\n var iwOffsetY = this.pixelOffset.height;\n var iwWidth = this.div.offsetWidth;\n var iwHeight = this.div.offsetHeight;\n var padX = this.infoBoxClearance.width;\n var padY = this.infoBoxClearance.height;\n // eslint-disable-next-line @typescript-eslint/ban-ts-comment\n // @ts-ignore\n var projection = this.getProjection();\n var pixPosition = projection.fromLatLngToContainerPixel(this.position);\n if (pixPosition !== null) {\n if (pixPosition.x < -iwOffsetX + padX) {\n xOffset = pixPosition.x + iwOffsetX - padX;\n } else if (pixPosition.x + iwWidth + iwOffsetX + padX > mapWidth) {\n xOffset = pixPosition.x + iwWidth + iwOffsetX + padX - mapWidth;\n }\n if (this.alignBottom) {\n if (pixPosition.y < -iwOffsetY + padY + iwHeight) {\n yOffset = pixPosition.y + iwOffsetY - padY - iwHeight;\n } else if (pixPosition.y + iwOffsetY + padY > mapHeight) {\n yOffset = pixPosition.y + iwOffsetY + padY - mapHeight;\n }\n } else {\n if (pixPosition.y < -iwOffsetY + padY) {\n yOffset = pixPosition.y + iwOffsetY - padY;\n } else if (pixPosition.y + iwHeight + iwOffsetY + padY > mapHeight) {\n yOffset = pixPosition.y + iwHeight + iwOffsetY + padY - mapHeight;\n }\n }\n }\n if (!(xOffset === 0 && yOffset === 0)) {\n // Move the map to the shifted center.\n map.panBy(xOffset, yOffset);\n }\n }\n }\n };\n InfoBox.prototype.setBoxStyle = function () {\n if (this.div) {\n // Apply style values from the style sheet defined in the boxClass parameter:\n this.div.className = this.boxClass;\n // Clear existing inline style values:\n this.div.style.cssText = '';\n // Apply style values defined in the boxStyle parameter:\n var boxStyle = this.boxStyle;\n for (var i in boxStyle) {\n if (Object.prototype.hasOwnProperty.call(boxStyle, i)) {\n // eslint-disable-next-line @typescript-eslint/ban-ts-comment\n // @ts-ignore\n this.div.style[i] = boxStyle[i];\n }\n }\n // Fix for iOS disappearing InfoBox problem\n // See http://stackoverflow.com/questions/9229535/google-maps-markers-disappear-at-certain-zoom-level-only-on-iphone-ipad\n this.div.style.webkitTransform = 'translateZ(0)';\n // Fix up opacity style for benefit of MSIE\n if (typeof this.div.style.opacity !== 'undefined' && this.div.style.opacity !== '') {\n // See http://www.quirksmode.org/css/opacity.html\n var opacity = parseFloat(this.div.style.opacity || '');\n // eslint-disable-next-line @typescript-eslint/ban-ts-comment\n // @ts-ignore\n this.div.style.msFilter = '\"progid:DXImageTransform.Microsoft.Alpha(Opacity=' + opacity * 100 + ')\"';\n this.div.style.filter = 'alpha(opacity=' + opacity * 100 + ')';\n }\n // Apply required styles\n this.div.style.position = 'absolute';\n this.div.style.visibility = 'hidden';\n if (this.zIndex !== null) {\n this.div.style.zIndex = this.zIndex + '';\n }\n if (!this.div.style.overflow) {\n this.div.style.overflow = 'auto';\n }\n }\n };\n InfoBox.prototype.getBoxWidths = function () {\n var bw = {\n top: 0,\n bottom: 0,\n left: 0,\n right: 0\n };\n if (!this.div) {\n return bw;\n }\n if (document.defaultView) {\n var ownerDocument = this.div.ownerDocument;\n var computedStyle = ownerDocument && ownerDocument.defaultView ? ownerDocument.defaultView.getComputedStyle(this.div, '') : null;\n if (computedStyle) {\n // The computed styles are always in pixel units (good!)\n bw.top = parseInt(computedStyle.borderTopWidth || '', 10) || 0;\n bw.bottom = parseInt(computedStyle.borderBottomWidth || '', 10) || 0;\n bw.left = parseInt(computedStyle.borderLeftWidth || '', 10) || 0;\n bw.right = parseInt(computedStyle.borderRightWidth || '', 10) || 0;\n }\n } else if (\n // eslint-disable-next-line @typescript-eslint/ban-ts-comment\n // @ts-ignore\n document.documentElement.currentStyle // MSIE\n ) {\n // eslint-disable-next-line @typescript-eslint/ban-ts-comment\n // @ts-ignore\n var currentStyle = this.div.currentStyle;\n if (currentStyle) {\n // The current styles may not be in pixel units, but assume they are (bad!)\n bw.top = parseInt(currentStyle.borderTopWidth || '', 10) || 0;\n bw.bottom = parseInt(currentStyle.borderBottomWidth || '', 10) || 0;\n bw.left = parseInt(currentStyle.borderLeftWidth || '', 10) || 0;\n bw.right = parseInt(currentStyle.borderRightWidth || '', 10) || 0;\n }\n }\n return bw;\n };\n InfoBox.prototype.onRemove = function () {\n if (this.div && this.div.parentNode) {\n this.div.parentNode.removeChild(this.div);\n this.div = null;\n }\n };\n InfoBox.prototype.draw = function () {\n this.createInfoBoxDiv();\n if (this.div) {\n // eslint-disable-next-line @typescript-eslint/ban-ts-comment\n // @ts-ignore\n var projection = this.getProjection();\n var pixPosition = projection.fromLatLngToDivPixel(this.position);\n if (pixPosition !== null) {\n this.div.style.left = pixPosition.x + this.pixelOffset.width + 'px';\n if (this.alignBottom) {\n this.div.style.bottom = -(pixPosition.y + this.pixelOffset.height) + 'px';\n } else {\n this.div.style.top = pixPosition.y + this.pixelOffset.height + 'px';\n }\n }\n if (this.isHidden) {\n this.div.style.visibility = 'hidden';\n } else {\n this.div.style.visibility = 'visible';\n }\n }\n };\n InfoBox.prototype.setOptions = function (options) {\n if (options === void 0) {\n options = {};\n }\n if (typeof options.boxClass !== 'undefined') {\n // Must be first\n this.boxClass = options.boxClass;\n this.setBoxStyle();\n }\n if (typeof options.boxStyle !== 'undefined') {\n // Must be second\n this.boxStyle = options.boxStyle;\n this.setBoxStyle();\n }\n if (typeof options.content !== 'undefined') {\n this.setContent(options.content);\n }\n if (typeof options.disableAutoPan !== 'undefined') {\n this.disableAutoPan = options.disableAutoPan;\n }\n if (typeof options.maxWidth !== 'undefined') {\n this.maxWidth = options.maxWidth;\n }\n if (typeof options.pixelOffset !== 'undefined') {\n this.pixelOffset = options.pixelOffset;\n }\n if (typeof options.alignBottom !== 'undefined') {\n this.alignBottom = options.alignBottom;\n }\n if (typeof options.position !== 'undefined') {\n this.setPosition(options.position);\n }\n if (typeof options.zIndex !== 'undefined') {\n this.setZIndex(options.zIndex);\n }\n if (typeof options.closeBoxMargin !== 'undefined') {\n this.closeBoxMargin = options.closeBoxMargin;\n }\n if (typeof options.closeBoxURL !== 'undefined') {\n this.closeBoxURL = options.closeBoxURL;\n }\n if (typeof options.infoBoxClearance !== 'undefined') {\n this.infoBoxClearance = options.infoBoxClearance;\n }\n if (typeof options.isHidden !== 'undefined') {\n this.isHidden = options.isHidden;\n }\n if (typeof options.visible !== 'undefined') {\n this.isHidden = !options.visible;\n }\n if (typeof options.enableEventPropagation !== 'undefined') {\n this.enableEventPropagation = options.enableEventPropagation;\n }\n if (this.div) {\n this.draw();\n }\n };\n InfoBox.prototype.setContent = function (content) {\n this.content = content;\n if (this.div) {\n if (this.closeListener) {\n google.maps.event.removeListener(this.closeListener);\n this.closeListener = null;\n }\n // Odd code required to make things work with MSIE.\n if (!this.fixedWidthSet) {\n this.div.style.width = '';\n }\n if (typeof content === 'string') {\n this.div.innerHTML = this.getCloseBoxImg() + content;\n } else {\n this.div.innerHTML = this.getCloseBoxImg();\n this.div.appendChild(content);\n }\n // Perverse code required to make things work with MSIE.\n // (Ensures the close box does, in fact, float to the right.)\n if (!this.fixedWidthSet) {\n this.div.style.width = this.div.offsetWidth + 'px';\n if (typeof content === 'string') {\n this.div.innerHTML = this.getCloseBoxImg() + content;\n } else {\n this.div.innerHTML = this.getCloseBoxImg();\n this.div.appendChild(content);\n }\n }\n this.addClickHandler();\n }\n /**\n * This event is fired when the content of the InfoBox changes.\n * @name InfoBox#content_changed\n * @event\n */\n google.maps.event.trigger(this, 'content_changed');\n };\n InfoBox.prototype.setPosition = function (latLng) {\n this.position = latLng;\n if (this.div) {\n this.draw();\n }\n /**\n * This event is fired when the position of the InfoBox changes.\n * @name InfoBox#position_changed\n * @event\n */\n google.maps.event.trigger(this, 'position_changed');\n };\n InfoBox.prototype.setVisible = function (isVisible) {\n this.isHidden = !isVisible;\n if (this.div) {\n this.div.style.visibility = this.isHidden ? 'hidden' : 'visible';\n }\n };\n InfoBox.prototype.setZIndex = function (index) {\n this.zIndex = index;\n if (this.div) {\n this.div.style.zIndex = index + '';\n }\n /**\n * This event is fired when the zIndex of the InfoBox changes.\n * @name InfoBox#zindex_changed\n * @event\n */\n google.maps.event.trigger(this, 'zindex_changed');\n };\n InfoBox.prototype.getContent = function () {\n return this.content;\n };\n InfoBox.prototype.getPosition = function () {\n return this.position;\n };\n InfoBox.prototype.getZIndex = function () {\n return this.zIndex;\n };\n InfoBox.prototype.getVisible = function () {\n var map = this.getMap();\n return typeof map === 'undefined' || map === null ? false : !this.isHidden;\n };\n InfoBox.prototype.show = function () {\n this.isHidden = false;\n if (this.div) {\n this.div.style.visibility = 'visible';\n }\n };\n InfoBox.prototype.hide = function () {\n this.isHidden = true;\n if (this.div) {\n this.div.style.visibility = 'hidden';\n }\n };\n InfoBox.prototype.open = function (map, anchor) {\n var _this = this;\n if (anchor) {\n // eslint-disable-next-line @typescript-eslint/ban-ts-comment\n // @ts-ignore\n this.position = anchor.getPosition();\n this.moveListener = google.maps.event.addListener(anchor, 'position_changed', function () {\n // eslint-disable-next-line @typescript-eslint/ban-ts-comment\n // @ts-ignore\n var position = anchor.getPosition();\n _this.setPosition(position);\n });\n this.mapListener = google.maps.event.addListener(anchor, 'map_changed', function () {\n // eslint-disable-next-line @typescript-eslint/ban-ts-comment\n // @ts-ignore\n _this.setMap(anchor.map);\n });\n }\n this.setMap(map);\n if (this.div) {\n this.panBox();\n }\n };\n InfoBox.prototype.close = function () {\n if (this.closeListener) {\n google.maps.event.removeListener(this.closeListener);\n this.closeListener = null;\n }\n if (this.eventListeners) {\n for (var i = 0; i < this.eventListeners.length; i++) {\n google.maps.event.removeListener(this.eventListeners[i]);\n }\n this.eventListeners = null;\n }\n if (this.moveListener) {\n google.maps.event.removeListener(this.moveListener);\n this.moveListener = null;\n }\n if (this.mapListener) {\n google.maps.event.removeListener(this.mapListener);\n this.mapListener = null;\n }\n if (this.contextListener) {\n google.maps.event.removeListener(this.contextListener);\n this.contextListener = null;\n }\n // eslint-disable-next-line @typescript-eslint/ban-ts-comment\n // @ts-ignore\n this.setMap(null);\n };\n InfoBox.prototype.extend = function (obj1, obj2) {\n return function applyExtend(object) {\n for (var property in object.prototype) {\n if (!Object.prototype.hasOwnProperty.call(this, property)) {\n // @ts-ignore\n this.prototype[property] = object.prototype[property];\n }\n }\n return this;\n }.apply(obj1, [obj2]);\n };\n return InfoBox;\n}();\nconst eventMap$d = {\n onCloseClick: 'closeclick',\n onContentChanged: 'content_changed',\n onDomReady: 'domready',\n onPositionChanged: 'position_changed',\n onZindexChanged: 'zindex_changed'\n};\nconst updaterMap$d = {\n options(instance, options) {\n instance.setOptions(options);\n },\n position(instance, position) {\n if (position instanceof google.maps.LatLng) {\n instance.setPosition(position);\n } else {\n instance.setPosition(new google.maps.LatLng(position.lat, position.lng));\n }\n },\n visible(instance, visible) {\n instance.setVisible(visible);\n },\n zIndex(instance, zIndex) {\n instance.setZIndex(zIndex);\n }\n};\nconst defaultOptions$3 = {};\nfunction InfoBoxFunctional(_ref13) {\n let children = _ref13.children,\n anchor = _ref13.anchor,\n options = _ref13.options,\n position = _ref13.position,\n zIndex = _ref13.zIndex,\n onCloseClick = _ref13.onCloseClick,\n onDomReady = _ref13.onDomReady,\n onContentChanged = _ref13.onContentChanged,\n onPositionChanged = _ref13.onPositionChanged,\n onZindexChanged = _ref13.onZindexChanged,\n onLoad = _ref13.onLoad,\n onUnmount = _ref13.onUnmount;\n const map = useContext(MapContext);\n const _useState111 = useState(null),\n _useState112 = _slicedToArray(_useState111, 2),\n instance = _useState112[0],\n setInstance = _useState112[1];\n const _useState113 = useState(null),\n _useState114 = _slicedToArray(_useState113, 2),\n closeclickListener = _useState114[0],\n setCloseClickListener = _useState114[1];\n const _useState115 = useState(null),\n _useState116 = _slicedToArray(_useState115, 2),\n domreadyclickListener = _useState116[0],\n setDomReadyClickListener = _useState116[1];\n const _useState117 = useState(null),\n _useState118 = _slicedToArray(_useState117, 2),\n contentchangedclickListener = _useState118[0],\n setContentChangedClickListener = _useState118[1];\n const _useState119 = useState(null),\n _useState120 = _slicedToArray(_useState119, 2),\n positionchangedclickListener = _useState120[0],\n setPositionChangedClickListener = _useState120[1];\n const _useState121 = useState(null),\n _useState122 = _slicedToArray(_useState121, 2),\n zindexchangedclickListener = _useState122[0],\n setZindexChangedClickListener = _useState122[1];\n const containerElementRef = useRef(null);\n // Order does matter\n useEffect(() => {\n if (map && instance !== null) {\n instance.close();\n if (anchor) {\n instance.open(map, anchor);\n } else if (instance.getPosition()) {\n instance.open(map);\n }\n }\n }, [map, instance, anchor]);\n useEffect(() => {\n if (options && instance !== null) {\n instance.setOptions(options);\n }\n }, [instance, options]);\n useEffect(() => {\n if (position && instance !== null) {\n const positionLatLng = position instanceof google.maps.LatLng ? position\n // @ts-ignore\n : new google.maps.LatLng(position.lat, position.lng);\n instance.setPosition(positionLatLng);\n }\n }, [position]);\n useEffect(() => {\n if (typeof zIndex === 'number' && instance !== null) {\n instance.setZIndex(zIndex);\n }\n }, [zIndex]);\n useEffect(() => {\n if (instance && onCloseClick) {\n if (closeclickListener !== null) {\n google.maps.event.removeListener(closeclickListener);\n }\n setCloseClickListener(google.maps.event.addListener(instance, 'closeclick', onCloseClick));\n }\n }, [onCloseClick]);\n useEffect(() => {\n if (instance && onDomReady) {\n if (domreadyclickListener !== null) {\n google.maps.event.removeListener(domreadyclickListener);\n }\n setDomReadyClickListener(google.maps.event.addListener(instance, 'domready', onDomReady));\n }\n }, [onDomReady]);\n useEffect(() => {\n if (instance && onContentChanged) {\n if (contentchangedclickListener !== null) {\n google.maps.event.removeListener(contentchangedclickListener);\n }\n setContentChangedClickListener(google.maps.event.addListener(instance, 'content_changed', onContentChanged));\n }\n }, [onContentChanged]);\n useEffect(() => {\n if (instance && onPositionChanged) {\n if (positionchangedclickListener !== null) {\n google.maps.event.removeListener(positionchangedclickListener);\n }\n setPositionChangedClickListener(google.maps.event.addListener(instance, 'position_changed', onPositionChanged));\n }\n }, [onPositionChanged]);\n useEffect(() => {\n if (instance && onZindexChanged) {\n if (zindexchangedclickListener !== null) {\n google.maps.event.removeListener(zindexchangedclickListener);\n }\n setZindexChangedClickListener(google.maps.event.addListener(instance, 'zindex_changed', onZindexChanged));\n }\n }, [onZindexChanged]);\n useEffect(() => {\n if (map) {\n const _a = options || defaultOptions$3,\n position = _a.position,\n infoBoxOptions = __rest$1(_a, [\"position\"]);\n let positionLatLng;\n if (position && !(position instanceof google.maps.LatLng)) {\n // @ts-ignore\n positionLatLng = new google.maps.LatLng(position.lat, position.lng);\n }\n const infoBox = new InfoBox(Object.assign(Object.assign({}, infoBoxOptions), positionLatLng ? {\n position: positionLatLng\n } : {}));\n containerElementRef.current = document.createElement('div');\n setInstance(infoBox);\n if (onCloseClick) {\n setCloseClickListener(google.maps.event.addListener(infoBox, 'closeclick', onCloseClick));\n }\n if (onDomReady) {\n setDomReadyClickListener(google.maps.event.addListener(infoBox, 'domready', onDomReady));\n }\n if (onContentChanged) {\n setContentChangedClickListener(google.maps.event.addListener(infoBox, 'content_changed', onContentChanged));\n }\n if (onPositionChanged) {\n setPositionChangedClickListener(google.maps.event.addListener(infoBox, 'position_changed', onPositionChanged));\n }\n if (onZindexChanged) {\n setZindexChangedClickListener(google.maps.event.addListener(infoBox, 'zindex_changed', onZindexChanged));\n }\n infoBox.setContent(containerElementRef.current);\n if (anchor) {\n infoBox.open(map, anchor);\n } else if (infoBox.getPosition()) {\n infoBox.open(map);\n } else {\n invariant_1(false, 'You must provide either an anchor or a position prop for .');\n }\n if (onLoad) {\n onLoad(infoBox);\n }\n }\n return () => {\n if (instance !== null) {\n if (closeclickListener) {\n google.maps.event.removeListener(closeclickListener);\n }\n if (contentchangedclickListener) {\n google.maps.event.removeListener(contentchangedclickListener);\n }\n if (domreadyclickListener) {\n google.maps.event.removeListener(domreadyclickListener);\n }\n if (positionchangedclickListener) {\n google.maps.event.removeListener(positionchangedclickListener);\n }\n if (zindexchangedclickListener) {\n google.maps.event.removeListener(zindexchangedclickListener);\n }\n if (onUnmount) {\n onUnmount(instance);\n }\n instance.close();\n }\n };\n }, []);\n return containerElementRef.current ? /*#__PURE__*/createPortal(Children.only(children), containerElementRef.current) : null;\n}\nconst InfoBoxF = /*#__PURE__*/memo(InfoBoxFunctional);\nclass InfoBoxComponent extends PureComponent {\n constructor() {\n super(...arguments);\n this.registeredEvents = [];\n this.containerElement = null;\n this.state = {\n infoBox: null\n };\n this.open = (infoBox, anchor) => {\n if (anchor) {\n // @ts-ignore\n infoBox.open(this.context, anchor);\n } else if (infoBox.getPosition()) {\n // @ts-ignore\n infoBox.open(this.context);\n } else {\n invariant_1(false, 'You must provide either an anchor or a position prop for .');\n }\n };\n this.setInfoBoxCallback = () => {\n if (this.state.infoBox !== null && this.containerElement !== null) {\n this.state.infoBox.setContent(this.containerElement);\n this.open(this.state.infoBox, this.props.anchor);\n if (this.props.onLoad) {\n this.props.onLoad(this.state.infoBox);\n }\n }\n };\n }\n componentDidMount() {\n const _a = this.props.options || {},\n position = _a.position,\n infoBoxOptions = __rest$1(_a, [\"position\"]);\n let positionLatLng;\n if (position && !(position instanceof google.maps.LatLng)) {\n // @ts-ignore\n positionLatLng = new google.maps.LatLng(position.lat, position.lng);\n }\n const infoBox = new InfoBox(Object.assign(Object.assign({}, infoBoxOptions), positionLatLng ? {\n position: positionLatLng\n } : {}));\n this.containerElement = document.createElement('div');\n this.registeredEvents = applyUpdatersToPropsAndRegisterEvents({\n updaterMap: updaterMap$d,\n eventMap: eventMap$d,\n prevProps: {},\n nextProps: this.props,\n instance: infoBox\n });\n this.setState({\n infoBox\n }, this.setInfoBoxCallback);\n }\n componentDidUpdate(prevProps) {\n const infoBox = this.state.infoBox;\n if (infoBox !== null) {\n unregisterEvents(this.registeredEvents);\n this.registeredEvents = applyUpdatersToPropsAndRegisterEvents({\n updaterMap: updaterMap$d,\n eventMap: eventMap$d,\n prevProps,\n nextProps: this.props,\n instance: infoBox\n });\n }\n }\n componentWillUnmount() {\n const onUnmount = this.props.onUnmount;\n const infoBox = this.state.infoBox;\n if (infoBox !== null) {\n if (onUnmount) {\n onUnmount(infoBox);\n }\n unregisterEvents(this.registeredEvents);\n infoBox.close();\n }\n }\n render() {\n return this.containerElement ? /*#__PURE__*/createPortal(Children.only(this.props.children), this.containerElement) : null;\n }\n}\nInfoBoxComponent.contextType = MapContext;\n\n// do not edit .js files directly - edit src/index.jst\n\nvar fastDeepEqual = function equal(a, b) {\n if (a === b) return true;\n if (a && b && typeof a == 'object' && typeof b == 'object') {\n if (a.constructor !== b.constructor) return false;\n var length, i, keys;\n if (Array.isArray(a)) {\n length = a.length;\n if (length != b.length) return false;\n for (i = length; i-- !== 0;) if (!equal(a[i], b[i])) return false;\n return true;\n }\n if (a.constructor === RegExp) return a.source === b.source && a.flags === b.flags;\n if (a.valueOf !== Object.prototype.valueOf) return a.valueOf() === b.valueOf();\n if (a.toString !== Object.prototype.toString) return a.toString() === b.toString();\n keys = Object.keys(a);\n length = keys.length;\n if (length !== Object.keys(b).length) return false;\n for (i = length; i-- !== 0;) if (!Object.prototype.hasOwnProperty.call(b, keys[i])) return false;\n for (i = length; i-- !== 0;) {\n var key = keys[i];\n if (!equal(a[key], b[key])) return false;\n }\n return true;\n }\n\n // true if both NaN, false otherwise\n return a !== a && b !== b;\n};\nvar kdbush = {\n exports: {}\n};\n(function (module, exports) {\n (function (global, factory) {\n module.exports = factory();\n })(commonjsGlobal, function () {\n function sortKD(ids, coords, nodeSize, left, right, depth) {\n if (right - left <= nodeSize) {\n return;\n }\n var m = left + right >> 1;\n select(ids, coords, m, left, right, depth % 2);\n sortKD(ids, coords, nodeSize, left, m - 1, depth + 1);\n sortKD(ids, coords, nodeSize, m + 1, right, depth + 1);\n }\n function select(ids, coords, k, left, right, inc) {\n while (right > left) {\n if (right - left > 600) {\n var n = right - left + 1;\n var m = k - left + 1;\n var z = Math.log(n);\n var s = 0.5 * Math.exp(2 * z / 3);\n var sd = 0.5 * Math.sqrt(z * s * (n - s) / n) * (m - n / 2 < 0 ? -1 : 1);\n var newLeft = Math.max(left, Math.floor(k - m * s / n + sd));\n var newRight = Math.min(right, Math.floor(k + (n - m) * s / n + sd));\n select(ids, coords, k, newLeft, newRight, inc);\n }\n var t = coords[2 * k + inc];\n var i = left;\n var j = right;\n swapItem(ids, coords, left, k);\n if (coords[2 * right + inc] > t) {\n swapItem(ids, coords, left, right);\n }\n while (i < j) {\n swapItem(ids, coords, i, j);\n i++;\n j--;\n while (coords[2 * i + inc] < t) {\n i++;\n }\n while (coords[2 * j + inc] > t) {\n j--;\n }\n }\n if (coords[2 * left + inc] === t) {\n swapItem(ids, coords, left, j);\n } else {\n j++;\n swapItem(ids, coords, j, right);\n }\n if (j <= k) {\n left = j + 1;\n }\n if (k <= j) {\n right = j - 1;\n }\n }\n }\n function swapItem(ids, coords, i, j) {\n swap(ids, i, j);\n swap(coords, 2 * i, 2 * j);\n swap(coords, 2 * i + 1, 2 * j + 1);\n }\n function swap(arr, i, j) {\n var tmp = arr[i];\n arr[i] = arr[j];\n arr[j] = tmp;\n }\n function range(ids, coords, minX, minY, maxX, maxY, nodeSize) {\n var stack = [0, ids.length - 1, 0];\n var result = [];\n var x, y;\n while (stack.length) {\n var axis = stack.pop();\n var right = stack.pop();\n var left = stack.pop();\n if (right - left <= nodeSize) {\n for (var i = left; i <= right; i++) {\n x = coords[2 * i];\n y = coords[2 * i + 1];\n if (x >= minX && x <= maxX && y >= minY && y <= maxY) {\n result.push(ids[i]);\n }\n }\n continue;\n }\n var m = Math.floor((left + right) / 2);\n x = coords[2 * m];\n y = coords[2 * m + 1];\n if (x >= minX && x <= maxX && y >= minY && y <= maxY) {\n result.push(ids[m]);\n }\n var nextAxis = (axis + 1) % 2;\n if (axis === 0 ? minX <= x : minY <= y) {\n stack.push(left);\n stack.push(m - 1);\n stack.push(nextAxis);\n }\n if (axis === 0 ? maxX >= x : maxY >= y) {\n stack.push(m + 1);\n stack.push(right);\n stack.push(nextAxis);\n }\n }\n return result;\n }\n function within(ids, coords, qx, qy, r, nodeSize) {\n var stack = [0, ids.length - 1, 0];\n var result = [];\n var r2 = r * r;\n while (stack.length) {\n var axis = stack.pop();\n var right = stack.pop();\n var left = stack.pop();\n if (right - left <= nodeSize) {\n for (var i = left; i <= right; i++) {\n if (sqDist(coords[2 * i], coords[2 * i + 1], qx, qy) <= r2) {\n result.push(ids[i]);\n }\n }\n continue;\n }\n var m = Math.floor((left + right) / 2);\n var x = coords[2 * m];\n var y = coords[2 * m + 1];\n if (sqDist(x, y, qx, qy) <= r2) {\n result.push(ids[m]);\n }\n var nextAxis = (axis + 1) % 2;\n if (axis === 0 ? qx - r <= x : qy - r <= y) {\n stack.push(left);\n stack.push(m - 1);\n stack.push(nextAxis);\n }\n if (axis === 0 ? qx + r >= x : qy + r >= y) {\n stack.push(m + 1);\n stack.push(right);\n stack.push(nextAxis);\n }\n }\n return result;\n }\n function sqDist(ax, ay, bx, by) {\n var dx = ax - bx;\n var dy = ay - by;\n return dx * dx + dy * dy;\n }\n var defaultGetX = function (p) {\n return p[0];\n };\n var defaultGetY = function (p) {\n return p[1];\n };\n var KDBush = function KDBush(points, getX, getY, nodeSize, ArrayType) {\n if (getX === void 0) getX = defaultGetX;\n if (getY === void 0) getY = defaultGetY;\n if (nodeSize === void 0) nodeSize = 64;\n if (ArrayType === void 0) ArrayType = Float64Array;\n this.nodeSize = nodeSize;\n this.points = points;\n var IndexArrayType = points.length < 65536 ? Uint16Array : Uint32Array;\n var ids = this.ids = new IndexArrayType(points.length);\n var coords = this.coords = new ArrayType(points.length * 2);\n for (var i = 0; i < points.length; i++) {\n ids[i] = i;\n coords[2 * i] = getX(points[i]);\n coords[2 * i + 1] = getY(points[i]);\n }\n sortKD(ids, coords, nodeSize, 0, ids.length - 1, 0);\n };\n KDBush.prototype.range = function range$1(minX, minY, maxX, maxY) {\n return range(this.ids, this.coords, minX, minY, maxX, maxY, this.nodeSize);\n };\n KDBush.prototype.within = function within$1(x, y, r) {\n return within(this.ids, this.coords, x, y, r, this.nodeSize);\n };\n return KDBush;\n });\n})(kdbush);\nvar KDBush = kdbush.exports;\nconst defaultOptions$2 = {\n minZoom: 0,\n // min zoom to generate clusters on\n maxZoom: 16,\n // max zoom level to cluster the points on\n minPoints: 2,\n // minimum points to form a cluster\n radius: 40,\n // cluster radius in pixels\n extent: 512,\n // tile extent (radius is calculated relative to it)\n nodeSize: 64,\n // size of the KD-tree leaf node, affects performance\n log: false,\n // whether to log timing info\n\n // whether to generate numeric ids for input features (in vector tiles)\n generateId: false,\n // a reduce function for calculating custom cluster properties\n reduce: null,\n // (accumulated, props) => { accumulated.sum += props.sum; }\n\n // properties to use for individual points when running the reducer\n map: props => props // props => ({sum: props.my_value})\n};\n\nconst fround = Math.fround || (tmp => x => {\n tmp[0] = +x;\n return tmp[0];\n})(new Float32Array(1));\nclass Supercluster {\n constructor(options) {\n this.options = extend$1(Object.create(defaultOptions$2), options);\n this.trees = new Array(this.options.maxZoom + 1);\n }\n load(points) {\n const _this$options = this.options,\n log = _this$options.log,\n minZoom = _this$options.minZoom,\n maxZoom = _this$options.maxZoom,\n nodeSize = _this$options.nodeSize;\n if (log) console.time('total time');\n const timerId = `prepare ${points.length} points`;\n if (log) console.time(timerId);\n this.points = points;\n\n // generate a cluster object for each point and index input points into a KD-tree\n let clusters = [];\n for (let i = 0; i < points.length; i++) {\n if (!points[i].geometry) continue;\n clusters.push(createPointCluster(points[i], i));\n }\n this.trees[maxZoom + 1] = new KDBush(clusters, getX, getY, nodeSize, Float32Array);\n if (log) console.timeEnd(timerId);\n\n // cluster points on max zoom, then cluster the results on previous zoom, etc.;\n // results in a cluster hierarchy across zoom levels\n for (let z = maxZoom; z >= minZoom; z--) {\n const now = +Date.now();\n\n // create a new set of clusters for the zoom and index them with a KD-tree\n clusters = this._cluster(clusters, z);\n this.trees[z] = new KDBush(clusters, getX, getY, nodeSize, Float32Array);\n if (log) console.log('z%d: %d clusters in %dms', z, clusters.length, +Date.now() - now);\n }\n if (log) console.timeEnd('total time');\n return this;\n }\n getClusters(bbox, zoom) {\n let minLng = ((bbox[0] + 180) % 360 + 360) % 360 - 180;\n const minLat = Math.max(-90, Math.min(90, bbox[1]));\n let maxLng = bbox[2] === 180 ? 180 : ((bbox[2] + 180) % 360 + 360) % 360 - 180;\n const maxLat = Math.max(-90, Math.min(90, bbox[3]));\n if (bbox[2] - bbox[0] >= 360) {\n minLng = -180;\n maxLng = 180;\n } else if (minLng > maxLng) {\n const easternHem = this.getClusters([minLng, minLat, 180, maxLat], zoom);\n const westernHem = this.getClusters([-180, minLat, maxLng, maxLat], zoom);\n return easternHem.concat(westernHem);\n }\n const tree = this.trees[this._limitZoom(zoom)];\n const ids = tree.range(lngX(minLng), latY(maxLat), lngX(maxLng), latY(minLat));\n const clusters = [];\n var _iterator = _createForOfIteratorHelper(ids),\n _step;\n try {\n for (_iterator.s(); !(_step = _iterator.n()).done;) {\n const id = _step.value;\n const c = tree.points[id];\n clusters.push(c.numPoints ? getClusterJSON(c) : this.points[c.index]);\n }\n } catch (err) {\n _iterator.e(err);\n } finally {\n _iterator.f();\n }\n return clusters;\n }\n getChildren(clusterId) {\n const originId = this._getOriginId(clusterId);\n const originZoom = this._getOriginZoom(clusterId);\n const errorMsg = 'No cluster with the specified id.';\n const index = this.trees[originZoom];\n if (!index) throw new Error(errorMsg);\n const origin = index.points[originId];\n if (!origin) throw new Error(errorMsg);\n const r = this.options.radius / (this.options.extent * Math.pow(2, originZoom - 1));\n const ids = index.within(origin.x, origin.y, r);\n const children = [];\n var _iterator2 = _createForOfIteratorHelper(ids),\n _step2;\n try {\n for (_iterator2.s(); !(_step2 = _iterator2.n()).done;) {\n const id = _step2.value;\n const c = index.points[id];\n if (c.parentId === clusterId) {\n children.push(c.numPoints ? getClusterJSON(c) : this.points[c.index]);\n }\n }\n } catch (err) {\n _iterator2.e(err);\n } finally {\n _iterator2.f();\n }\n if (children.length === 0) throw new Error(errorMsg);\n return children;\n }\n getLeaves(clusterId, limit, offset) {\n limit = limit || 10;\n offset = offset || 0;\n const leaves = [];\n this._appendLeaves(leaves, clusterId, limit, offset, 0);\n return leaves;\n }\n getTile(z, x, y) {\n const tree = this.trees[this._limitZoom(z)];\n const z2 = Math.pow(2, z);\n const _this$options2 = this.options,\n extent = _this$options2.extent,\n radius = _this$options2.radius;\n const p = radius / extent;\n const top = (y - p) / z2;\n const bottom = (y + 1 + p) / z2;\n const tile = {\n features: []\n };\n this._addTileFeatures(tree.range((x - p) / z2, top, (x + 1 + p) / z2, bottom), tree.points, x, y, z2, tile);\n if (x === 0) {\n this._addTileFeatures(tree.range(1 - p / z2, top, 1, bottom), tree.points, z2, y, z2, tile);\n }\n if (x === z2 - 1) {\n this._addTileFeatures(tree.range(0, top, p / z2, bottom), tree.points, -1, y, z2, tile);\n }\n return tile.features.length ? tile : null;\n }\n getClusterExpansionZoom(clusterId) {\n let expansionZoom = this._getOriginZoom(clusterId) - 1;\n while (expansionZoom <= this.options.maxZoom) {\n const children = this.getChildren(clusterId);\n expansionZoom++;\n if (children.length !== 1) break;\n clusterId = children[0].properties.cluster_id;\n }\n return expansionZoom;\n }\n _appendLeaves(result, clusterId, limit, offset, skipped) {\n const children = this.getChildren(clusterId);\n var _iterator3 = _createForOfIteratorHelper(children),\n _step3;\n try {\n for (_iterator3.s(); !(_step3 = _iterator3.n()).done;) {\n const child = _step3.value;\n const props = child.properties;\n if (props && props.cluster) {\n if (skipped + props.point_count <= offset) {\n // skip the whole cluster\n skipped += props.point_count;\n } else {\n // enter the cluster\n skipped = this._appendLeaves(result, props.cluster_id, limit, offset, skipped);\n // exit the cluster\n }\n } else if (skipped < offset) {\n // skip a single point\n skipped++;\n } else {\n // add a single point\n result.push(child);\n }\n if (result.length === limit) break;\n }\n } catch (err) {\n _iterator3.e(err);\n } finally {\n _iterator3.f();\n }\n return skipped;\n }\n _addTileFeatures(ids, points, x, y, z2, tile) {\n var _iterator4 = _createForOfIteratorHelper(ids),\n _step4;\n try {\n for (_iterator4.s(); !(_step4 = _iterator4.n()).done;) {\n const i = _step4.value;\n const c = points[i];\n const isCluster = c.numPoints;\n let tags, px, py;\n if (isCluster) {\n tags = getClusterProperties(c);\n px = c.x;\n py = c.y;\n } else {\n const p = this.points[c.index];\n tags = p.properties;\n px = lngX(p.geometry.coordinates[0]);\n py = latY(p.geometry.coordinates[1]);\n }\n const f = {\n type: 1,\n geometry: [[Math.round(this.options.extent * (px * z2 - x)), Math.round(this.options.extent * (py * z2 - y))]],\n tags\n };\n\n // assign id\n let id;\n if (isCluster) {\n id = c.id;\n } else if (this.options.generateId) {\n // optionally generate id\n id = c.index;\n } else if (this.points[c.index].id) {\n // keep id if already assigned\n id = this.points[c.index].id;\n }\n if (id !== undefined) f.id = id;\n tile.features.push(f);\n }\n } catch (err) {\n _iterator4.e(err);\n } finally {\n _iterator4.f();\n }\n }\n _limitZoom(z) {\n return Math.max(this.options.minZoom, Math.min(+z, this.options.maxZoom + 1));\n }\n _cluster(points, zoom) {\n const clusters = [];\n const _this$options3 = this.options,\n radius = _this$options3.radius,\n extent = _this$options3.extent,\n reduce = _this$options3.reduce,\n minPoints = _this$options3.minPoints;\n const r = radius / (extent * Math.pow(2, zoom));\n\n // loop through each point\n for (let i = 0; i < points.length; i++) {\n const p = points[i];\n // if we've already visited the point at this zoom level, skip it\n if (p.zoom <= zoom) continue;\n p.zoom = zoom;\n\n // find all nearby points\n const tree = this.trees[zoom + 1];\n const neighborIds = tree.within(p.x, p.y, r);\n const numPointsOrigin = p.numPoints || 1;\n let numPoints = numPointsOrigin;\n\n // count the number of points in a potential cluster\n var _iterator5 = _createForOfIteratorHelper(neighborIds),\n _step5;\n try {\n for (_iterator5.s(); !(_step5 = _iterator5.n()).done;) {\n const neighborId = _step5.value;\n const b = tree.points[neighborId];\n // filter out neighbors that are already processed\n if (b.zoom > zoom) numPoints += b.numPoints || 1;\n }\n\n // if there were neighbors to merge, and there are enough points to form a cluster\n } catch (err) {\n _iterator5.e(err);\n } finally {\n _iterator5.f();\n }\n if (numPoints > numPointsOrigin && numPoints >= minPoints) {\n let wx = p.x * numPointsOrigin;\n let wy = p.y * numPointsOrigin;\n let clusterProperties = reduce && numPointsOrigin > 1 ? this._map(p, true) : null;\n\n // encode both zoom and point index on which the cluster originated -- offset by total length of features\n const id = (i << 5) + (zoom + 1) + this.points.length;\n var _iterator6 = _createForOfIteratorHelper(neighborIds),\n _step6;\n try {\n for (_iterator6.s(); !(_step6 = _iterator6.n()).done;) {\n const neighborId = _step6.value;\n const b = tree.points[neighborId];\n if (b.zoom <= zoom) continue;\n b.zoom = zoom; // save the zoom (so it doesn't get processed twice)\n\n const numPoints2 = b.numPoints || 1;\n wx += b.x * numPoints2; // accumulate coordinates for calculating weighted center\n wy += b.y * numPoints2;\n b.parentId = id;\n if (reduce) {\n if (!clusterProperties) clusterProperties = this._map(p, true);\n reduce(clusterProperties, this._map(b));\n }\n }\n } catch (err) {\n _iterator6.e(err);\n } finally {\n _iterator6.f();\n }\n p.parentId = id;\n clusters.push(createCluster(wx / numPoints, wy / numPoints, id, numPoints, clusterProperties));\n } else {\n // left points as unclustered\n clusters.push(p);\n if (numPoints > 1) {\n var _iterator7 = _createForOfIteratorHelper(neighborIds),\n _step7;\n try {\n for (_iterator7.s(); !(_step7 = _iterator7.n()).done;) {\n const neighborId = _step7.value;\n const b = tree.points[neighborId];\n if (b.zoom <= zoom) continue;\n b.zoom = zoom;\n clusters.push(b);\n }\n } catch (err) {\n _iterator7.e(err);\n } finally {\n _iterator7.f();\n }\n }\n }\n }\n return clusters;\n }\n\n // get index of the point from which the cluster originated\n _getOriginId(clusterId) {\n return clusterId - this.points.length >> 5;\n }\n\n // get zoom of the point from which the cluster originated\n _getOriginZoom(clusterId) {\n return (clusterId - this.points.length) % 32;\n }\n _map(point, clone) {\n if (point.numPoints) {\n return clone ? extend$1({}, point.properties) : point.properties;\n }\n const original = this.points[point.index].properties;\n const result = this.options.map(original);\n return clone && result === original ? extend$1({}, result) : result;\n }\n}\nfunction createCluster(x, y, id, numPoints, properties) {\n return {\n x: fround(x),\n // weighted cluster center; round for consistency with Float32Array index\n y: fround(y),\n zoom: Infinity,\n // the last zoom the cluster was processed at\n id,\n // encodes index of the first child of the cluster and its zoom level\n parentId: -1,\n // parent cluster id\n numPoints,\n properties\n };\n}\nfunction createPointCluster(p, id) {\n const _p$geometry$coordinat = _slicedToArray(p.geometry.coordinates, 2),\n x = _p$geometry$coordinat[0],\n y = _p$geometry$coordinat[1];\n return {\n x: fround(lngX(x)),\n // projected point coordinates\n y: fround(latY(y)),\n zoom: Infinity,\n // the last zoom the point was processed at\n index: id,\n // index of the source feature in the original input array,\n parentId: -1 // parent cluster id\n };\n}\n\nfunction getClusterJSON(cluster) {\n return {\n type: 'Feature',\n id: cluster.id,\n properties: getClusterProperties(cluster),\n geometry: {\n type: 'Point',\n coordinates: [xLng(cluster.x), yLat(cluster.y)]\n }\n };\n}\nfunction getClusterProperties(cluster) {\n const count = cluster.numPoints;\n const abbrev = count >= 10000 ? `${Math.round(count / 1000)}k` : count >= 1000 ? `${Math.round(count / 100) / 10}k` : count;\n return extend$1(extend$1({}, cluster.properties), {\n cluster: true,\n cluster_id: cluster.id,\n point_count: count,\n point_count_abbreviated: abbrev\n });\n}\n\n// longitude/latitude to spherical mercator in [0..1] range\nfunction lngX(lng) {\n return lng / 360 + 0.5;\n}\nfunction latY(lat) {\n const sin = Math.sin(lat * Math.PI / 180);\n const y = 0.5 - 0.25 * Math.log((1 + sin) / (1 - sin)) / Math.PI;\n return y < 0 ? 0 : y > 1 ? 1 : y;\n}\n\n// spherical mercator to longitude/latitude\nfunction xLng(x) {\n return (x - 0.5) * 360;\n}\nfunction yLat(y) {\n const y2 = (180 - y * 360) * Math.PI / 180;\n return 360 * Math.atan(Math.exp(y2)) / Math.PI - 90;\n}\nfunction extend$1(dest, src) {\n for (const id in src) dest[id] = src[id];\n return dest;\n}\nfunction getX(p) {\n return p.x;\n}\nfunction getY(p) {\n return p.y;\n}\n\n/*! *****************************************************************************\r\nCopyright (c) Microsoft Corporation.\r\n\r\nPermission to use, copy, modify, and/or distribute this software for any\r\npurpose with or without fee is hereby granted.\r\n\r\nTHE SOFTWARE IS PROVIDED \"AS IS\" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH\r\nREGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY\r\nAND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,\r\nINDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM\r\nLOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR\r\nOTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR\r\nPERFORMANCE OF THIS SOFTWARE.\r\n***************************************************************************** */\n\nfunction __rest(s, e) {\n var t = {};\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) t[p] = s[p];\n if (s != null && typeof Object.getOwnPropertySymbols === \"function\") for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {\n if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i])) t[p[i]] = s[p[i]];\n }\n return t;\n}\n\n/**\n * Copyright 2021 Google LLC\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nclass Cluster {\n constructor(_ref14) {\n let markers = _ref14.markers,\n position = _ref14.position;\n this.markers = markers;\n if (position) {\n if (position instanceof google.maps.LatLng) {\n this._position = position;\n } else {\n this._position = new google.maps.LatLng(position);\n }\n }\n }\n get bounds() {\n if (this.markers.length === 0 && !this._position) {\n return undefined;\n }\n return this.markers.reduce((bounds, marker) => {\n return bounds.extend(marker.getPosition());\n }, new google.maps.LatLngBounds(this._position, this._position));\n }\n get position() {\n return this._position || this.bounds.getCenter();\n }\n /**\n * Get the count of **visible** markers.\n */\n get count() {\n return this.markers.filter(m => m.getVisible()).length;\n }\n /**\n * Add a marker to the cluster.\n */\n push(marker) {\n this.markers.push(marker);\n }\n /**\n * Cleanup references and remove marker from map.\n */\n delete() {\n if (this.marker) {\n this.marker.setMap(null);\n delete this.marker;\n }\n this.markers.length = 0;\n }\n}\n\n/**\n * Copyright 2021 Google LLC\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nconst filterMarkersToPaddedViewport = (map, mapCanvasProjection, markers, viewportPadding) => {\n const extendedMapBounds = extendBoundsToPaddedViewport(map.getBounds(), mapCanvasProjection, viewportPadding);\n return markers.filter(marker => extendedMapBounds.contains(marker.getPosition()));\n};\n/**\n * Extends a bounds by a number of pixels in each direction.\n */\nconst extendBoundsToPaddedViewport = (bounds, projection, pixels) => {\n const _latLngBoundsToPixelB = latLngBoundsToPixelBounds(bounds, projection),\n northEast = _latLngBoundsToPixelB.northEast,\n southWest = _latLngBoundsToPixelB.southWest;\n const extendedPixelBounds = extendPixelBounds({\n northEast,\n southWest\n }, pixels);\n return pixelBoundsToLatLngBounds(extendedPixelBounds, projection);\n};\n/**\n * @hidden\n */\nconst distanceBetweenPoints = (p1, p2) => {\n const R = 6371; // Radius of the Earth in km\n const dLat = (p2.lat - p1.lat) * Math.PI / 180;\n const dLon = (p2.lng - p1.lng) * Math.PI / 180;\n const a = Math.sin(dLat / 2) * Math.sin(dLat / 2) + Math.cos(p1.lat * Math.PI / 180) * Math.cos(p2.lat * Math.PI / 180) * Math.sin(dLon / 2) * Math.sin(dLon / 2);\n const c = 2 * Math.atan2(Math.sqrt(a), Math.sqrt(1 - a));\n return R * c;\n};\n/**\n * @hidden\n */\nconst latLngBoundsToPixelBounds = (bounds, projection) => {\n return {\n northEast: projection.fromLatLngToDivPixel(bounds.getNorthEast()),\n southWest: projection.fromLatLngToDivPixel(bounds.getSouthWest())\n };\n};\n/**\n * @hidden\n */\nconst extendPixelBounds = (_ref15, pixels) => {\n let northEast = _ref15.northEast,\n southWest = _ref15.southWest;\n northEast.x += pixels;\n northEast.y -= pixels;\n southWest.x -= pixels;\n southWest.y += pixels;\n return {\n northEast,\n southWest\n };\n};\n/**\n * @hidden\n */\nconst pixelBoundsToLatLngBounds = (_ref16, projection) => {\n let northEast = _ref16.northEast,\n southWest = _ref16.southWest;\n const bounds = new google.maps.LatLngBounds();\n bounds.extend(projection.fromDivPixelToLatLng(northEast));\n bounds.extend(projection.fromDivPixelToLatLng(southWest));\n return bounds;\n};\n\n/**\n * Copyright 2021 Google LLC\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n/**\n * @hidden\n */\nclass AbstractAlgorithm {\n constructor(_ref17) {\n let _ref17$maxZoom = _ref17.maxZoom,\n maxZoom = _ref17$maxZoom === void 0 ? 16 : _ref17$maxZoom;\n this.maxZoom = maxZoom;\n }\n /**\n * Helper function to bypass clustering based upon some map state such as\n * zoom, number of markers, etc.\n *\n * ```typescript\n * cluster({markers, map}: AlgorithmInput): Cluster[] {\n * if (shouldBypassClustering(map)) {\n * return this.noop({markers, map})\n * }\n * }\n * ```\n */\n noop(_ref18) {\n let markers = _ref18.markers;\n return noop$1(markers);\n }\n}\n/**\n * Abstract viewport algorithm proves a class to filter markers by a padded\n * viewport. This is a common optimization.\n *\n * @hidden\n */\nclass AbstractViewportAlgorithm extends AbstractAlgorithm {\n constructor(_a) {\n var _a$viewportPadding = _a.viewportPadding,\n viewportPadding = _a$viewportPadding === void 0 ? 60 : _a$viewportPadding,\n options = __rest(_a, [\"viewportPadding\"]);\n super(options);\n this.viewportPadding = 60;\n this.viewportPadding = viewportPadding;\n }\n calculate(_ref19) {\n let markers = _ref19.markers,\n map = _ref19.map,\n mapCanvasProjection = _ref19.mapCanvasProjection;\n if (map.getZoom() >= this.maxZoom) {\n return {\n clusters: this.noop({\n markers,\n map,\n mapCanvasProjection\n }),\n changed: false\n };\n }\n return {\n clusters: this.cluster({\n markers: filterMarkersToPaddedViewport(map, mapCanvasProjection, markers, this.viewportPadding),\n map,\n mapCanvasProjection\n })\n };\n }\n}\n/**\n * @hidden\n */\nconst noop$1 = markers => {\n const clusters = markers.map(marker => new Cluster({\n position: marker.getPosition(),\n markers: [marker]\n }));\n return clusters;\n};\n\n/**\n * Copyright 2021 Google LLC\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n/**\n * The default Grid algorithm historically used in Google Maps marker\n * clustering.\n *\n * The Grid algorithm does not implement caching and markers may flash as the\n * viewport changes. Instead use {@link SuperClusterAlgorithm}.\n */\nclass GridAlgorithm extends AbstractViewportAlgorithm {\n constructor(_a) {\n var _a$maxDistance = _a.maxDistance,\n maxDistance = _a$maxDistance === void 0 ? 40000 : _a$maxDistance,\n _a$gridSize = _a.gridSize,\n gridSize = _a$gridSize === void 0 ? 40 : _a$gridSize,\n options = __rest(_a, [\"maxDistance\", \"gridSize\"]);\n super(options);\n this.clusters = [];\n this.maxDistance = maxDistance;\n this.gridSize = gridSize;\n this.state = {\n zoom: null\n };\n }\n calculate(_ref20) {\n let markers = _ref20.markers,\n map = _ref20.map,\n mapCanvasProjection = _ref20.mapCanvasProjection;\n const state = {\n zoom: map.getZoom()\n };\n let changed = false;\n if (this.state.zoom > this.maxZoom && state.zoom > this.maxZoom) ;else {\n changed = !fastDeepEqual(this.state, state);\n }\n this.state = state;\n if (map.getZoom() >= this.maxZoom) {\n return {\n clusters: this.noop({\n markers,\n map,\n mapCanvasProjection\n }),\n changed: changed\n };\n }\n return {\n clusters: this.cluster({\n markers: filterMarkersToPaddedViewport(map, mapCanvasProjection, markers, this.viewportPadding),\n map,\n mapCanvasProjection\n })\n };\n }\n cluster(_ref21) {\n let markers = _ref21.markers,\n map = _ref21.map,\n mapCanvasProjection = _ref21.mapCanvasProjection;\n this.clusters = [];\n markers.forEach(marker => {\n this.addToClosestCluster(marker, map, mapCanvasProjection);\n });\n return this.clusters;\n }\n addToClosestCluster(marker, map, projection) {\n let maxDistance = this.maxDistance; // Some large number\n let cluster = null;\n for (let i = 0; i < this.clusters.length; i++) {\n const candidate = this.clusters[i];\n const distance = distanceBetweenPoints(candidate.bounds.getCenter().toJSON(), marker.getPosition().toJSON());\n if (distance < maxDistance) {\n maxDistance = distance;\n cluster = candidate;\n }\n }\n if (cluster && extendBoundsToPaddedViewport(cluster.bounds, projection, this.gridSize).contains(marker.getPosition())) {\n cluster.push(marker);\n } else {\n const cluster = new Cluster({\n markers: [marker]\n });\n this.clusters.push(cluster);\n }\n }\n}\n\n/**\n * Copyright 2021 Google LLC\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n/**\n * Noop algorithm does not generate any clusters or filter markers by the an extended viewport.\n */\nclass NoopAlgorithm extends AbstractAlgorithm {\n constructor(_a) {\n var options = __rest(_a, []);\n super(options);\n }\n calculate(_ref22) {\n let markers = _ref22.markers,\n map = _ref22.map,\n mapCanvasProjection = _ref22.mapCanvasProjection;\n return {\n clusters: this.cluster({\n markers,\n map,\n mapCanvasProjection\n }),\n changed: false\n };\n }\n cluster(input) {\n return this.noop(input);\n }\n}\n\n/**\n * Copyright 2021 Google LLC\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n/**\n * A very fast JavaScript algorithm for geospatial point clustering using KD trees.\n *\n * @see https://www.npmjs.com/package/supercluster for more information on options.\n */\nclass SuperClusterAlgorithm extends AbstractAlgorithm {\n constructor(_a) {\n var maxZoom = _a.maxZoom,\n _a$radius = _a.radius,\n radius = _a$radius === void 0 ? 60 : _a$radius,\n options = __rest(_a, [\"maxZoom\", \"radius\"]);\n super({\n maxZoom\n });\n this.superCluster = new Supercluster(Object.assign({\n maxZoom: this.maxZoom,\n radius\n }, options));\n this.state = {\n zoom: null\n };\n }\n calculate(input) {\n let changed = false;\n if (!fastDeepEqual(input.markers, this.markers)) {\n changed = true;\n // TODO use proxy to avoid copy?\n this.markers = [...input.markers];\n const points = this.markers.map(marker => {\n return {\n type: \"Feature\",\n geometry: {\n type: \"Point\",\n coordinates: [marker.getPosition().lng(), marker.getPosition().lat()]\n },\n properties: {\n marker\n }\n };\n });\n this.superCluster.load(points);\n }\n const state = {\n zoom: input.map.getZoom()\n };\n if (!changed) {\n if (this.state.zoom > this.maxZoom && state.zoom > this.maxZoom) ;else {\n changed = changed || !fastDeepEqual(this.state, state);\n }\n }\n this.state = state;\n if (changed) {\n this.clusters = this.cluster(input);\n }\n return {\n clusters: this.clusters,\n changed\n };\n }\n cluster(_ref23) {\n let map = _ref23.map;\n return this.superCluster.getClusters([-180, -90, 180, 90], Math.round(map.getZoom())).map(this.transformCluster.bind(this));\n }\n transformCluster(_ref24) {\n let _ref24$geometry$coord = _slicedToArray(_ref24.geometry.coordinates, 2),\n lng = _ref24$geometry$coord[0],\n lat = _ref24$geometry$coord[1],\n properties = _ref24.properties;\n if (properties.cluster) {\n return new Cluster({\n markers: this.superCluster.getLeaves(properties.cluster_id, Infinity).map(leaf => leaf.properties.marker),\n position: new google.maps.LatLng({\n lat,\n lng\n })\n });\n } else {\n const marker = properties.marker;\n return new Cluster({\n markers: [marker],\n position: marker.getPosition()\n });\n }\n }\n}\n\n/**\n * Copyright 2021 Google LLC\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n/**\n * Provides statistics on all clusters in the current render cycle for use in {@link Renderer.render}.\n */\nclass ClusterStats {\n constructor(markers, clusters) {\n this.markers = {\n sum: markers.length\n };\n const clusterMarkerCounts = clusters.map(a => a.count);\n const clusterMarkerSum = clusterMarkerCounts.reduce((a, b) => a + b, 0);\n this.clusters = {\n count: clusters.length,\n markers: {\n mean: clusterMarkerSum / clusters.length,\n sum: clusterMarkerSum,\n min: Math.min(...clusterMarkerCounts),\n max: Math.max(...clusterMarkerCounts)\n }\n };\n }\n}\nclass DefaultRenderer {\n /**\n * The default render function for the library used by {@link MarkerClusterer}.\n *\n * Currently set to use the following:\n *\n * ```typescript\n * // change color if this cluster has more markers than the mean cluster\n * const color =\n * count > Math.max(10, stats.clusters.markers.mean)\n * ? \"#ff0000\"\n * : \"#0000ff\";\n *\n * // create svg url with fill color\n * const svg = window.btoa(`\n * \n * \n * \n * \n * \n * `);\n *\n * // create marker using svg icon\n * return new google.maps.Marker({\n * position,\n * icon: {\n * url: `data:image/svg+xml;base64,${svg}`,\n * scaledSize: new google.maps.Size(45, 45),\n * },\n * label: {\n * text: String(count),\n * color: \"rgba(255,255,255,0.9)\",\n * fontSize: \"12px\",\n * },\n * // adjust zIndex to be above other markers\n * zIndex: 1000 + count,\n * });\n * ```\n */\n render(_ref25, stats) {\n let count = _ref25.count,\n position = _ref25.position;\n // change color if this cluster has more markers than the mean cluster\n const color = count > Math.max(10, stats.clusters.markers.mean) ? \"#ff0000\" : \"#0000ff\";\n // create svg url with fill color\n const svg = window.btoa(`\n \n \n \n \n `);\n // create marker using svg icon\n return new google.maps.Marker({\n position,\n icon: {\n url: `data:image/svg+xml;base64,${svg}`,\n scaledSize: new google.maps.Size(45, 45)\n },\n label: {\n text: String(count),\n color: \"rgba(255,255,255,0.9)\",\n fontSize: \"12px\"\n },\n title: `Cluster of ${count} markers`,\n // adjust zIndex to be above other markers\n zIndex: Number(google.maps.Marker.MAX_ZINDEX) + count\n });\n }\n}\n\n/**\n * Copyright 2019 Google LLC. All Rights Reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n/**\n * Extends an object's prototype by another's.\n *\n * @param type1 The Type to be extended.\n * @param type2 The Type to extend with.\n * @ignore\n */\n// eslint-disable-next-line @typescript-eslint/no-explicit-any\nfunction extend(type1, type2) {\n /* istanbul ignore next */\n // eslint-disable-next-line prefer-const\n for (let property in type2.prototype) {\n type1.prototype[property] = type2.prototype[property];\n }\n}\n/**\n * @ignore\n */\nclass OverlayViewSafe {\n constructor() {\n // MarkerClusterer implements google.maps.OverlayView interface. We use the\n // extend function to extend MarkerClusterer with google.maps.OverlayView\n // because it might not always be available when the code is defined so we\n // look for it at the last possible moment. If it doesn't exist now then\n // there is no point going ahead :)\n extend(OverlayViewSafe, google.maps.OverlayView);\n }\n}\n\n/**\n * Copyright 2021 Google LLC\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nvar MarkerClustererEvents;\n(function (MarkerClustererEvents) {\n MarkerClustererEvents[\"CLUSTERING_BEGIN\"] = \"clusteringbegin\";\n MarkerClustererEvents[\"CLUSTERING_END\"] = \"clusteringend\";\n MarkerClustererEvents[\"CLUSTER_CLICK\"] = \"click\";\n})(MarkerClustererEvents || (MarkerClustererEvents = {}));\nconst defaultOnClusterClickHandler = (_, cluster, map) => {\n map.fitBounds(cluster.bounds);\n};\n/**\n * MarkerClusterer creates and manages per-zoom-level clusters for large amounts\n * of markers. See {@link MarkerClustererOptions} for more details.\n *\n */\nclass MarkerClusterer extends OverlayViewSafe {\n constructor(_ref26) {\n let map = _ref26.map,\n _ref26$markers = _ref26.markers,\n markers = _ref26$markers === void 0 ? [] : _ref26$markers,\n _ref26$algorithm = _ref26.algorithm,\n algorithm = _ref26$algorithm === void 0 ? new SuperClusterAlgorithm({}) : _ref26$algorithm,\n _ref26$renderer = _ref26.renderer,\n renderer = _ref26$renderer === void 0 ? new DefaultRenderer() : _ref26$renderer,\n _ref26$onClusterClick = _ref26.onClusterClick,\n onClusterClick = _ref26$onClusterClick === void 0 ? defaultOnClusterClickHandler : _ref26$onClusterClick;\n super();\n this.markers = [...markers];\n this.clusters = [];\n this.algorithm = algorithm;\n this.renderer = renderer;\n this.onClusterClick = onClusterClick;\n if (map) {\n this.setMap(map);\n }\n }\n addMarker(marker, noDraw) {\n if (this.markers.includes(marker)) {\n return;\n }\n this.markers.push(marker);\n if (!noDraw) {\n this.render();\n }\n }\n addMarkers(markers, noDraw) {\n markers.forEach(marker => {\n this.addMarker(marker, true);\n });\n if (!noDraw) {\n this.render();\n }\n }\n removeMarker(marker, noDraw) {\n const index = this.markers.indexOf(marker);\n if (index === -1) {\n // Marker is not in our list of markers, so do nothing:\n return false;\n }\n marker.setMap(null);\n this.markers.splice(index, 1); // Remove the marker from the list of managed markers\n if (!noDraw) {\n this.render();\n }\n return true;\n }\n removeMarkers(markers, noDraw) {\n let removed = false;\n markers.forEach(marker => {\n removed = this.removeMarker(marker, true) || removed;\n });\n if (removed && !noDraw) {\n this.render();\n }\n return removed;\n }\n clearMarkers(noDraw) {\n this.markers.length = 0;\n if (!noDraw) {\n this.render();\n }\n }\n /**\n * Recalculates and draws all the marker clusters.\n */\n render() {\n const map = this.getMap();\n if (map instanceof google.maps.Map && this.getProjection()) {\n google.maps.event.trigger(this, MarkerClustererEvents.CLUSTERING_BEGIN, this);\n const _this$algorithm$calcu = this.algorithm.calculate({\n markers: this.markers,\n map,\n mapCanvasProjection: this.getProjection()\n }),\n clusters = _this$algorithm$calcu.clusters,\n changed = _this$algorithm$calcu.changed;\n // allow algorithms to return flag on whether the clusters/markers have changed\n if (changed || changed == undefined) {\n // reset visibility of markers and clusters\n this.reset();\n // store new clusters\n this.clusters = clusters;\n this.renderClusters();\n }\n google.maps.event.trigger(this, MarkerClustererEvents.CLUSTERING_END, this);\n }\n }\n onAdd() {\n this.idleListener = this.getMap().addListener(\"idle\", this.render.bind(this));\n this.render();\n }\n onRemove() {\n google.maps.event.removeListener(this.idleListener);\n this.reset();\n }\n reset() {\n this.markers.forEach(marker => marker.setMap(null));\n this.clusters.forEach(cluster => cluster.delete());\n this.clusters = [];\n }\n renderClusters() {\n // generate stats to pass to renderers\n const stats = new ClusterStats(this.markers, this.clusters);\n const map = this.getMap();\n this.clusters.forEach(cluster => {\n if (cluster.markers.length === 1) {\n cluster.marker = cluster.markers[0];\n } else {\n cluster.marker = this.renderer.render(cluster, stats);\n if (this.onClusterClick) {\n cluster.marker.addListener(\"click\", /* istanbul ignore next */\n event => {\n google.maps.event.trigger(this, MarkerClustererEvents.CLUSTER_CLICK, cluster);\n this.onClusterClick(event, cluster, map);\n });\n }\n }\n cluster.marker.setMap(map);\n });\n }\n}\nvar index_esm = /*#__PURE__*/Object.freeze({\n __proto__: null,\n AbstractAlgorithm: AbstractAlgorithm,\n AbstractViewportAlgorithm: AbstractViewportAlgorithm,\n Cluster: Cluster,\n ClusterStats: ClusterStats,\n DefaultRenderer: DefaultRenderer,\n GridAlgorithm: GridAlgorithm,\n MarkerClusterer: MarkerClusterer,\n get MarkerClustererEvents() {\n return MarkerClustererEvents;\n },\n NoopAlgorithm: NoopAlgorithm,\n SuperClusterAlgorithm: SuperClusterAlgorithm,\n defaultOnClusterClickHandler: defaultOnClusterClickHandler,\n distanceBetweenPoints: distanceBetweenPoints,\n extendBoundsToPaddedViewport: extendBoundsToPaddedViewport,\n extendPixelBounds: extendPixelBounds,\n filterMarkersToPaddedViewport: filterMarkersToPaddedViewport,\n noop: noop$1,\n pixelBoundsToLatLngBounds: pixelBoundsToLatLngBounds\n});\nfunction useGoogleMarkerClusterer(options) {\n const map = useGoogleMap();\n const _useState123 = useState(null),\n _useState124 = _slicedToArray(_useState123, 2),\n markerClusterer = _useState124[0],\n setMarkerClusterer = _useState124[1];\n useEffect(() => {\n if (map && markerClusterer === null) {\n const markerCluster = new MarkerClusterer(Object.assign(Object.assign({}, options), {\n map\n }));\n setMarkerClusterer(markerCluster);\n }\n }, [map]);\n return markerClusterer;\n}\n/** Wrapper around [@googlemaps/markerclusterer](https://github.com/googlemaps/js-markerclusterer)\n *\n * Accepts {@link MarkerClustererOptionsSubset} which is a subset of {@link MarkerClustererOptions}\n */\nfunction GoogleMarkerClusterer(_ref27) {\n let children = _ref27.children,\n options = _ref27.options;\n const markerClusterer = useGoogleMarkerClusterer(options);\n return markerClusterer !== null ? children(markerClusterer) : null;\n}\nvar GoogleMarkerClusterer$1 = /*#__PURE__*/memo(GoogleMarkerClusterer);\n\n/* global google */\nconst eventMap$c = {\n onCloseClick: 'closeclick',\n onContentChanged: 'content_changed',\n onDomReady: 'domready',\n onPositionChanged: 'position_changed',\n onZindexChanged: 'zindex_changed'\n};\nconst updaterMap$c = {\n options(instance, options) {\n instance.setOptions(options);\n },\n position(instance, position) {\n instance.setPosition(position);\n },\n zIndex(instance, zIndex) {\n instance.setZIndex(zIndex);\n }\n};\nfunction InfoWindowFunctional(_ref28) {\n let children = _ref28.children,\n anchor = _ref28.anchor,\n options = _ref28.options,\n position = _ref28.position,\n zIndex = _ref28.zIndex,\n onCloseClick = _ref28.onCloseClick,\n onDomReady = _ref28.onDomReady,\n onContentChanged = _ref28.onContentChanged,\n onPositionChanged = _ref28.onPositionChanged,\n onZindexChanged = _ref28.onZindexChanged,\n onLoad = _ref28.onLoad,\n onUnmount = _ref28.onUnmount;\n const map = useContext(MapContext);\n const _useState125 = useState(null),\n _useState126 = _slicedToArray(_useState125, 2),\n instance = _useState126[0],\n setInstance = _useState126[1];\n const _useState127 = useState(null),\n _useState128 = _slicedToArray(_useState127, 2),\n closeclickListener = _useState128[0],\n setCloseClickListener = _useState128[1];\n const _useState129 = useState(null),\n _useState130 = _slicedToArray(_useState129, 2),\n domreadyclickListener = _useState130[0],\n setDomReadyClickListener = _useState130[1];\n const _useState131 = useState(null),\n _useState132 = _slicedToArray(_useState131, 2),\n contentchangedclickListener = _useState132[0],\n setContentChangedClickListener = _useState132[1];\n const _useState133 = useState(null),\n _useState134 = _slicedToArray(_useState133, 2),\n positionchangedclickListener = _useState134[0],\n setPositionChangedClickListener = _useState134[1];\n const _useState135 = useState(null),\n _useState136 = _slicedToArray(_useState135, 2),\n zindexchangedclickListener = _useState136[0],\n setZindexChangedClickListener = _useState136[1];\n const containerElementRef = useRef(null);\n // Order does matter\n useEffect(() => {\n if (instance !== null) {\n instance.close();\n if (anchor) {\n instance.open(map, anchor);\n } else if (instance.getPosition()) {\n instance.open(map);\n }\n }\n }, [map, instance, anchor]);\n useEffect(() => {\n if (options && instance !== null) {\n instance.setOptions(options);\n }\n }, [instance, options]);\n useEffect(() => {\n if (position && instance !== null) {\n instance.setPosition(position);\n }\n }, [position]);\n useEffect(() => {\n if (typeof zIndex === 'number' && instance !== null) {\n instance.setZIndex(zIndex);\n }\n }, [zIndex]);\n useEffect(() => {\n if (instance && onCloseClick) {\n if (closeclickListener !== null) {\n google.maps.event.removeListener(closeclickListener);\n }\n setCloseClickListener(google.maps.event.addListener(instance, 'closeclick', onCloseClick));\n }\n }, [onCloseClick]);\n useEffect(() => {\n if (instance && onDomReady) {\n if (domreadyclickListener !== null) {\n google.maps.event.removeListener(domreadyclickListener);\n }\n setDomReadyClickListener(google.maps.event.addListener(instance, 'domready', onDomReady));\n }\n }, [onDomReady]);\n useEffect(() => {\n if (instance && onContentChanged) {\n if (contentchangedclickListener !== null) {\n google.maps.event.removeListener(contentchangedclickListener);\n }\n setContentChangedClickListener(google.maps.event.addListener(instance, 'content_changed', onContentChanged));\n }\n }, [onContentChanged]);\n useEffect(() => {\n if (instance && onPositionChanged) {\n if (positionchangedclickListener !== null) {\n google.maps.event.removeListener(positionchangedclickListener);\n }\n setPositionChangedClickListener(google.maps.event.addListener(instance, 'position_changed', onPositionChanged));\n }\n }, [onPositionChanged]);\n useEffect(() => {\n if (instance && onZindexChanged) {\n if (zindexchangedclickListener !== null) {\n google.maps.event.removeListener(zindexchangedclickListener);\n }\n setZindexChangedClickListener(google.maps.event.addListener(instance, 'zindex_changed', onZindexChanged));\n }\n }, [onZindexChanged]);\n useEffect(() => {\n const infoWindow = new google.maps.InfoWindow(Object.assign({}, options || {}));\n setInstance(infoWindow);\n containerElementRef.current = document.createElement('div');\n if (onCloseClick) {\n setCloseClickListener(google.maps.event.addListener(infoWindow, 'closeclick', onCloseClick));\n }\n if (onDomReady) {\n setDomReadyClickListener(google.maps.event.addListener(infoWindow, 'domready', onDomReady));\n }\n if (onContentChanged) {\n setContentChangedClickListener(google.maps.event.addListener(infoWindow, 'content_changed', onContentChanged));\n }\n if (onPositionChanged) {\n setPositionChangedClickListener(google.maps.event.addListener(infoWindow, 'position_changed', onPositionChanged));\n }\n if (onZindexChanged) {\n setZindexChangedClickListener(google.maps.event.addListener(infoWindow, 'zindex_changed', onZindexChanged));\n }\n infoWindow.setContent(containerElementRef.current);\n if (position) {\n infoWindow.setPosition(position);\n }\n if (zIndex) {\n infoWindow.setZIndex(zIndex);\n }\n if (anchor) {\n infoWindow.open(map, anchor);\n } else if (infoWindow.getPosition()) {\n infoWindow.open(map);\n } else {\n invariant_1(false, `You must provide either an anchor (typically render it inside a ) or a position props for .`);\n }\n if (onLoad) {\n onLoad(infoWindow);\n }\n return () => {\n if (closeclickListener) {\n google.maps.event.removeListener(closeclickListener);\n }\n if (contentchangedclickListener) {\n google.maps.event.removeListener(contentchangedclickListener);\n }\n if (domreadyclickListener) {\n google.maps.event.removeListener(domreadyclickListener);\n }\n if (positionchangedclickListener) {\n google.maps.event.removeListener(positionchangedclickListener);\n }\n if (zindexchangedclickListener) {\n google.maps.event.removeListener(zindexchangedclickListener);\n }\n if (onUnmount) {\n onUnmount(infoWindow);\n }\n infoWindow.close();\n };\n }, []);\n return containerElementRef.current ? /*#__PURE__*/createPortal(Children.only(children), containerElementRef.current) : null;\n}\nconst InfoWindowF = /*#__PURE__*/memo(InfoWindowFunctional);\nclass InfoWindow extends PureComponent {\n constructor() {\n super(...arguments);\n this.registeredEvents = [];\n this.containerElement = null;\n this.state = {\n infoWindow: null\n };\n this.open = (infoWindow, anchor) => {\n if (anchor) {\n infoWindow.open(this.context, anchor);\n } else if (infoWindow.getPosition()) {\n // @ts-ignore\n infoWindow.open(this.context);\n } else {\n invariant_1(false, `You must provide either an anchor (typically render it inside a ) or a position props for .`);\n }\n };\n this.setInfoWindowCallback = () => {\n if (this.state.infoWindow !== null && this.containerElement !== null) {\n this.state.infoWindow.setContent(this.containerElement);\n this.open(this.state.infoWindow, this.props.anchor);\n if (this.props.onLoad) {\n this.props.onLoad(this.state.infoWindow);\n }\n }\n };\n }\n componentDidMount() {\n const infoWindow = new google.maps.InfoWindow(Object.assign({}, this.props.options || {}));\n this.containerElement = document.createElement('div');\n this.registeredEvents = applyUpdatersToPropsAndRegisterEvents({\n updaterMap: updaterMap$c,\n eventMap: eventMap$c,\n prevProps: {},\n nextProps: this.props,\n instance: infoWindow\n });\n this.setState(() => {\n return {\n infoWindow\n };\n }, this.setInfoWindowCallback);\n }\n componentDidUpdate(prevProps) {\n if (this.state.infoWindow !== null) {\n unregisterEvents(this.registeredEvents);\n this.registeredEvents = applyUpdatersToPropsAndRegisterEvents({\n updaterMap: updaterMap$c,\n eventMap: eventMap$c,\n prevProps,\n nextProps: this.props,\n instance: this.state.infoWindow\n });\n }\n }\n componentWillUnmount() {\n if (this.state.infoWindow !== null) {\n unregisterEvents(this.registeredEvents);\n if (this.props.onUnmount) {\n this.props.onUnmount(this.state.infoWindow);\n }\n this.state.infoWindow.close();\n }\n }\n render() {\n return this.containerElement ? /*#__PURE__*/createPortal(Children.only(this.props.children), this.containerElement) : null;\n }\n}\nInfoWindow.contextType = MapContext;\nconst eventMap$b = {\n onClick: 'click',\n onDblClick: 'dblclick',\n onDrag: 'drag',\n onDragEnd: 'dragend',\n onDragStart: 'dragstart',\n onMouseDown: 'mousedown',\n onMouseMove: 'mousemove',\n onMouseOut: 'mouseout',\n onMouseOver: 'mouseover',\n onMouseUp: 'mouseup',\n onRightClick: 'rightclick'\n};\nconst updaterMap$b = {\n draggable(instance, draggable) {\n instance.setDraggable(draggable);\n },\n editable(instance, editable) {\n instance.setEditable(editable);\n },\n map(instance, map) {\n instance.setMap(map);\n },\n options(instance, options) {\n instance.setOptions(options);\n },\n path(instance, path) {\n instance.setPath(path);\n },\n visible(instance, visible) {\n instance.setVisible(visible);\n }\n};\nconst defaultOptions$1 = {};\nfunction PolylineFunctional(_ref29) {\n let options = _ref29.options,\n draggable = _ref29.draggable,\n editable = _ref29.editable,\n visible = _ref29.visible,\n path = _ref29.path,\n onDblClick = _ref29.onDblClick,\n onDragEnd = _ref29.onDragEnd,\n onDragStart = _ref29.onDragStart,\n onMouseDown = _ref29.onMouseDown,\n onMouseMove = _ref29.onMouseMove,\n onMouseOut = _ref29.onMouseOut,\n onMouseOver = _ref29.onMouseOver,\n onMouseUp = _ref29.onMouseUp,\n onRightClick = _ref29.onRightClick,\n onClick = _ref29.onClick,\n onDrag = _ref29.onDrag,\n onLoad = _ref29.onLoad,\n onUnmount = _ref29.onUnmount;\n const map = useContext(MapContext);\n const _useState137 = useState(null),\n _useState138 = _slicedToArray(_useState137, 2),\n instance = _useState138[0],\n setInstance = _useState138[1];\n const _useState139 = useState(null),\n _useState140 = _slicedToArray(_useState139, 2),\n dblclickListener = _useState140[0],\n setDblclickListener = _useState140[1];\n const _useState141 = useState(null),\n _useState142 = _slicedToArray(_useState141, 2),\n dragendListener = _useState142[0],\n setDragendListener = _useState142[1];\n const _useState143 = useState(null),\n _useState144 = _slicedToArray(_useState143, 2),\n dragstartListener = _useState144[0],\n setDragstartListener = _useState144[1];\n const _useState145 = useState(null),\n _useState146 = _slicedToArray(_useState145, 2),\n mousedownListener = _useState146[0],\n setMousedownListener = _useState146[1];\n const _useState147 = useState(null),\n _useState148 = _slicedToArray(_useState147, 2),\n mousemoveListener = _useState148[0],\n setMousemoveListener = _useState148[1];\n const _useState149 = useState(null),\n _useState150 = _slicedToArray(_useState149, 2),\n mouseoutListener = _useState150[0],\n setMouseoutListener = _useState150[1];\n const _useState151 = useState(null),\n _useState152 = _slicedToArray(_useState151, 2),\n mouseoverListener = _useState152[0],\n setMouseoverListener = _useState152[1];\n const _useState153 = useState(null),\n _useState154 = _slicedToArray(_useState153, 2),\n mouseupListener = _useState154[0],\n setMouseupListener = _useState154[1];\n const _useState155 = useState(null),\n _useState156 = _slicedToArray(_useState155, 2),\n rightclickListener = _useState156[0],\n setRightclickListener = _useState156[1];\n const _useState157 = useState(null),\n _useState158 = _slicedToArray(_useState157, 2),\n clickListener = _useState158[0],\n setClickListener = _useState158[1];\n const _useState159 = useState(null),\n _useState160 = _slicedToArray(_useState159, 2),\n dragListener = _useState160[0],\n setDragListener = _useState160[1];\n // Order does matter\n useEffect(() => {\n if (instance !== null) {\n instance.setMap(map);\n }\n }, [map]);\n useEffect(() => {\n if (typeof options !== 'undefined' && instance !== null) {\n instance.setOptions(options);\n }\n }, [instance, options]);\n useEffect(() => {\n if (typeof draggable !== 'undefined' && instance !== null) {\n instance.setDraggable(draggable);\n }\n }, [instance, draggable]);\n useEffect(() => {\n if (typeof editable !== 'undefined' && instance !== null) {\n instance.setEditable(editable);\n }\n }, [instance, editable]);\n useEffect(() => {\n if (typeof visible !== 'undefined' && instance !== null) {\n instance.setVisible(visible);\n }\n }, [instance, visible]);\n useEffect(() => {\n if (typeof path !== 'undefined' && instance !== null) {\n instance.setPath(path);\n }\n }, [instance, path]);\n useEffect(() => {\n if (instance && onDblClick) {\n if (dblclickListener !== null) {\n google.maps.event.removeListener(dblclickListener);\n }\n setDblclickListener(google.maps.event.addListener(instance, 'dblclick', onDblClick));\n }\n }, [onDblClick]);\n useEffect(() => {\n if (instance && onDragEnd) {\n if (dragendListener !== null) {\n google.maps.event.removeListener(dragendListener);\n }\n setDragendListener(google.maps.event.addListener(instance, 'dragend', onDragEnd));\n }\n }, [onDragEnd]);\n useEffect(() => {\n if (instance && onDragStart) {\n if (dragstartListener !== null) {\n google.maps.event.removeListener(dragstartListener);\n }\n setDragstartListener(google.maps.event.addListener(instance, 'dragstart', onDragStart));\n }\n }, [onDragStart]);\n useEffect(() => {\n if (instance && onMouseDown) {\n if (mousedownListener !== null) {\n google.maps.event.removeListener(mousedownListener);\n }\n setMousedownListener(google.maps.event.addListener(instance, 'mousedown', onMouseDown));\n }\n }, [onMouseDown]);\n useEffect(() => {\n if (instance && onMouseMove) {\n if (mousemoveListener !== null) {\n google.maps.event.removeListener(mousemoveListener);\n }\n setMousemoveListener(google.maps.event.addListener(instance, 'mousemove', onMouseMove));\n }\n }, [onMouseMove]);\n useEffect(() => {\n if (instance && onMouseOut) {\n if (mouseoutListener !== null) {\n google.maps.event.removeListener(mouseoutListener);\n }\n setMouseoutListener(google.maps.event.addListener(instance, 'mouseout', onMouseOut));\n }\n }, [onMouseOut]);\n useEffect(() => {\n if (instance && onMouseOver) {\n if (mouseoverListener !== null) {\n google.maps.event.removeListener(mouseoverListener);\n }\n setMouseoverListener(google.maps.event.addListener(instance, 'mouseover', onMouseOver));\n }\n }, [onMouseOver]);\n useEffect(() => {\n if (instance && onMouseUp) {\n if (mouseupListener !== null) {\n google.maps.event.removeListener(mouseupListener);\n }\n setMouseupListener(google.maps.event.addListener(instance, 'mouseup', onMouseUp));\n }\n }, [onMouseUp]);\n useEffect(() => {\n if (instance && onRightClick) {\n if (rightclickListener !== null) {\n google.maps.event.removeListener(rightclickListener);\n }\n setRightclickListener(google.maps.event.addListener(instance, 'rightclick', onRightClick));\n }\n }, [onRightClick]);\n useEffect(() => {\n if (instance && onClick) {\n if (clickListener !== null) {\n google.maps.event.removeListener(clickListener);\n }\n setClickListener(google.maps.event.addListener(instance, 'click', onClick));\n }\n }, [onClick]);\n useEffect(() => {\n if (instance && onDrag) {\n if (dragListener !== null) {\n google.maps.event.removeListener(dragListener);\n }\n setDragListener(google.maps.event.addListener(instance, 'drag', onDrag));\n }\n }, [onDrag]);\n useEffect(() => {\n const polyline = new google.maps.Polyline(Object.assign(Object.assign({}, options || defaultOptions$1), {\n map\n }));\n if (path) {\n polyline.setPath(path);\n }\n if (typeof visible !== 'undefined') {\n polyline.setVisible(visible);\n }\n if (typeof editable !== 'undefined') {\n polyline.setEditable(editable);\n }\n if (typeof draggable !== 'undefined') {\n polyline.setDraggable(draggable);\n }\n if (onDblClick) {\n setDblclickListener(google.maps.event.addListener(polyline, 'dblclick', onDblClick));\n }\n if (onDragEnd) {\n setDragendListener(google.maps.event.addListener(polyline, 'dragend', onDragEnd));\n }\n if (onDragStart) {\n setDragstartListener(google.maps.event.addListener(polyline, 'dragstart', onDragStart));\n }\n if (onMouseDown) {\n setMousedownListener(google.maps.event.addListener(polyline, 'mousedown', onMouseDown));\n }\n if (onMouseMove) {\n setMousemoveListener(google.maps.event.addListener(polyline, 'mousemove', onMouseMove));\n }\n if (onMouseOut) {\n setMouseoutListener(google.maps.event.addListener(polyline, 'mouseout', onMouseOut));\n }\n if (onMouseOver) {\n setMouseoverListener(google.maps.event.addListener(polyline, 'mouseover', onMouseOver));\n }\n if (onMouseUp) {\n setMouseupListener(google.maps.event.addListener(polyline, 'mouseup', onMouseUp));\n }\n if (onRightClick) {\n setRightclickListener(google.maps.event.addListener(polyline, 'rightclick', onRightClick));\n }\n if (onClick) {\n setClickListener(google.maps.event.addListener(polyline, 'click', onClick));\n }\n if (onDrag) {\n setDragListener(google.maps.event.addListener(polyline, 'drag', onDrag));\n }\n setInstance(polyline);\n if (onLoad) {\n onLoad(polyline);\n }\n return () => {\n if (dblclickListener !== null) {\n google.maps.event.removeListener(dblclickListener);\n }\n if (dragendListener !== null) {\n google.maps.event.removeListener(dragendListener);\n }\n if (dragstartListener !== null) {\n google.maps.event.removeListener(dragstartListener);\n }\n if (mousedownListener !== null) {\n google.maps.event.removeListener(mousedownListener);\n }\n if (mousemoveListener !== null) {\n google.maps.event.removeListener(mousemoveListener);\n }\n if (mouseoutListener !== null) {\n google.maps.event.removeListener(mouseoutListener);\n }\n if (mouseoverListener !== null) {\n google.maps.event.removeListener(mouseoverListener);\n }\n if (mouseupListener !== null) {\n google.maps.event.removeListener(mouseupListener);\n }\n if (rightclickListener !== null) {\n google.maps.event.removeListener(rightclickListener);\n }\n if (clickListener !== null) {\n google.maps.event.removeListener(clickListener);\n }\n if (onUnmount) {\n onUnmount(polyline);\n }\n polyline.setMap(null);\n };\n }, []);\n return null;\n}\nconst PolylineF = /*#__PURE__*/memo(PolylineFunctional);\nclass Polyline extends PureComponent {\n constructor() {\n super(...arguments);\n this.registeredEvents = [];\n this.state = {\n polyline: null\n };\n this.setPolylineCallback = () => {\n if (this.state.polyline !== null && this.props.onLoad) {\n this.props.onLoad(this.state.polyline);\n }\n };\n }\n componentDidMount() {\n const polyline = new google.maps.Polyline(Object.assign(Object.assign({}, this.props.options || {}), {\n map: this.context\n }));\n this.registeredEvents = applyUpdatersToPropsAndRegisterEvents({\n updaterMap: updaterMap$b,\n eventMap: eventMap$b,\n prevProps: {},\n nextProps: this.props,\n instance: polyline\n });\n this.setState(function setPolyline() {\n return {\n polyline\n };\n }, this.setPolylineCallback);\n }\n componentDidUpdate(prevProps) {\n if (this.state.polyline !== null) {\n unregisterEvents(this.registeredEvents);\n this.registeredEvents = applyUpdatersToPropsAndRegisterEvents({\n updaterMap: updaterMap$b,\n eventMap: eventMap$b,\n prevProps,\n nextProps: this.props,\n instance: this.state.polyline\n });\n }\n }\n componentWillUnmount() {\n if (this.state.polyline !== null) {\n if (this.props.onUnmount) {\n this.props.onUnmount(this.state.polyline);\n }\n unregisterEvents(this.registeredEvents);\n this.state.polyline.setMap(null);\n }\n }\n render() {\n return null;\n }\n}\nPolyline.contextType = MapContext;\n\n/* global google */\nconst eventMap$a = {\n onClick: 'click',\n onDblClick: 'dblclick',\n onDrag: 'drag',\n onDragEnd: 'dragend',\n onDragStart: 'dragstart',\n onMouseDown: 'mousedown',\n onMouseMove: 'mousemove',\n onMouseOut: 'mouseout',\n onMouseOver: 'mouseover',\n onMouseUp: 'mouseup',\n onRightClick: 'rightclick'\n};\nconst updaterMap$a = {\n draggable(instance, draggable) {\n instance.setDraggable(draggable);\n },\n editable(instance, editable) {\n instance.setEditable(editable);\n },\n map(instance, map) {\n instance.setMap(map);\n },\n options(instance, options) {\n instance.setOptions(options);\n },\n path(instance, path) {\n instance.setPath(path);\n },\n paths(instance, paths) {\n instance.setPaths(paths);\n },\n visible(instance, visible) {\n instance.setVisible(visible);\n }\n};\nfunction PolygonFunctional(_ref30) {\n let options = _ref30.options,\n draggable = _ref30.draggable,\n editable = _ref30.editable,\n visible = _ref30.visible,\n path = _ref30.path,\n paths = _ref30.paths,\n onDblClick = _ref30.onDblClick,\n onDragEnd = _ref30.onDragEnd,\n onDragStart = _ref30.onDragStart,\n onMouseDown = _ref30.onMouseDown,\n onMouseMove = _ref30.onMouseMove,\n onMouseOut = _ref30.onMouseOut,\n onMouseOver = _ref30.onMouseOver,\n onMouseUp = _ref30.onMouseUp,\n onRightClick = _ref30.onRightClick,\n onClick = _ref30.onClick,\n onDrag = _ref30.onDrag,\n onLoad = _ref30.onLoad,\n onUnmount = _ref30.onUnmount;\n const map = useContext(MapContext);\n const _useState161 = useState(null),\n _useState162 = _slicedToArray(_useState161, 2),\n instance = _useState162[0],\n setInstance = _useState162[1];\n const _useState163 = useState(null),\n _useState164 = _slicedToArray(_useState163, 2),\n dblclickListener = _useState164[0],\n setDblclickListener = _useState164[1];\n const _useState165 = useState(null),\n _useState166 = _slicedToArray(_useState165, 2),\n dragendListener = _useState166[0],\n setDragendListener = _useState166[1];\n const _useState167 = useState(null),\n _useState168 = _slicedToArray(_useState167, 2),\n dragstartListener = _useState168[0],\n setDragstartListener = _useState168[1];\n const _useState169 = useState(null),\n _useState170 = _slicedToArray(_useState169, 2),\n mousedownListener = _useState170[0],\n setMousedownListener = _useState170[1];\n const _useState171 = useState(null),\n _useState172 = _slicedToArray(_useState171, 2),\n mousemoveListener = _useState172[0],\n setMousemoveListener = _useState172[1];\n const _useState173 = useState(null),\n _useState174 = _slicedToArray(_useState173, 2),\n mouseoutListener = _useState174[0],\n setMouseoutListener = _useState174[1];\n const _useState175 = useState(null),\n _useState176 = _slicedToArray(_useState175, 2),\n mouseoverListener = _useState176[0],\n setMouseoverListener = _useState176[1];\n const _useState177 = useState(null),\n _useState178 = _slicedToArray(_useState177, 2),\n mouseupListener = _useState178[0],\n setMouseupListener = _useState178[1];\n const _useState179 = useState(null),\n _useState180 = _slicedToArray(_useState179, 2),\n rightclickListener = _useState180[0],\n setRightclickListener = _useState180[1];\n const _useState181 = useState(null),\n _useState182 = _slicedToArray(_useState181, 2),\n clickListener = _useState182[0],\n setClickListener = _useState182[1];\n const _useState183 = useState(null),\n _useState184 = _slicedToArray(_useState183, 2),\n dragListener = _useState184[0],\n setDragListener = _useState184[1];\n // Order does matter\n useEffect(() => {\n if (instance !== null) {\n instance.setMap(map);\n }\n }, [map]);\n useEffect(() => {\n if (typeof options !== 'undefined' && instance !== null) {\n instance.setOptions(options);\n }\n }, [instance, options]);\n useEffect(() => {\n if (typeof draggable !== 'undefined' && instance !== null) {\n instance.setDraggable(draggable);\n }\n }, [instance, draggable]);\n useEffect(() => {\n if (typeof editable !== 'undefined' && instance !== null) {\n instance.setEditable(editable);\n }\n }, [instance, editable]);\n useEffect(() => {\n if (typeof visible !== 'undefined' && instance !== null) {\n instance.setVisible(visible);\n }\n }, [instance, visible]);\n useEffect(() => {\n if (typeof path !== 'undefined' && instance !== null) {\n instance.setPath(path);\n }\n }, [instance, path]);\n useEffect(() => {\n if (typeof paths !== 'undefined' && instance !== null) {\n instance.setPaths(paths);\n }\n }, [instance, paths]);\n useEffect(() => {\n if (instance && onDblClick) {\n if (dblclickListener !== null) {\n google.maps.event.removeListener(dblclickListener);\n }\n setDblclickListener(google.maps.event.addListener(instance, 'dblclick', onDblClick));\n }\n }, [onDblClick]);\n useEffect(() => {\n if (instance && onDragEnd) {\n if (dragendListener !== null) {\n google.maps.event.removeListener(dragendListener);\n }\n setDragendListener(google.maps.event.addListener(instance, 'dragend', onDragEnd));\n }\n }, [onDragEnd]);\n useEffect(() => {\n if (instance && onDragStart) {\n if (dragstartListener !== null) {\n google.maps.event.removeListener(dragstartListener);\n }\n setDragstartListener(google.maps.event.addListener(instance, 'dragstart', onDragStart));\n }\n }, [onDragStart]);\n useEffect(() => {\n if (instance && onMouseDown) {\n if (mousedownListener !== null) {\n google.maps.event.removeListener(mousedownListener);\n }\n setMousedownListener(google.maps.event.addListener(instance, 'mousedown', onMouseDown));\n }\n }, [onMouseDown]);\n useEffect(() => {\n if (instance && onMouseMove) {\n if (mousemoveListener !== null) {\n google.maps.event.removeListener(mousemoveListener);\n }\n setMousemoveListener(google.maps.event.addListener(instance, 'mousemove', onMouseMove));\n }\n }, [onMouseMove]);\n useEffect(() => {\n if (instance && onMouseOut) {\n if (mouseoutListener !== null) {\n google.maps.event.removeListener(mouseoutListener);\n }\n setMouseoutListener(google.maps.event.addListener(instance, 'mouseout', onMouseOut));\n }\n }, [onMouseOut]);\n useEffect(() => {\n if (instance && onMouseOver) {\n if (mouseoverListener !== null) {\n google.maps.event.removeListener(mouseoverListener);\n }\n setMouseoverListener(google.maps.event.addListener(instance, 'mouseover', onMouseOver));\n }\n }, [onMouseOver]);\n useEffect(() => {\n if (instance && onMouseUp) {\n if (mouseupListener !== null) {\n google.maps.event.removeListener(mouseupListener);\n }\n setMouseupListener(google.maps.event.addListener(instance, 'mouseup', onMouseUp));\n }\n }, [onMouseUp]);\n useEffect(() => {\n if (instance && onRightClick) {\n if (rightclickListener !== null) {\n google.maps.event.removeListener(rightclickListener);\n }\n setRightclickListener(google.maps.event.addListener(instance, 'rightclick', onRightClick));\n }\n }, [onRightClick]);\n useEffect(() => {\n if (instance && onClick) {\n if (clickListener !== null) {\n google.maps.event.removeListener(clickListener);\n }\n setClickListener(google.maps.event.addListener(instance, 'click', onClick));\n }\n }, [onClick]);\n useEffect(() => {\n if (instance && onDrag) {\n if (dragListener !== null) {\n google.maps.event.removeListener(dragListener);\n }\n setDragListener(google.maps.event.addListener(instance, 'drag', onDrag));\n }\n }, [onDrag]);\n useEffect(() => {\n const polygon = new google.maps.Polygon(Object.assign(Object.assign({}, options || {}), {\n map\n }));\n if (path) {\n polygon.setPath(path);\n }\n if (paths) {\n polygon.setPaths(paths);\n }\n if (typeof visible !== 'undefined') {\n polygon.setVisible(visible);\n }\n if (typeof editable !== 'undefined') {\n polygon.setEditable(editable);\n }\n if (typeof draggable !== 'undefined') {\n polygon.setDraggable(draggable);\n }\n if (onDblClick) {\n setDblclickListener(google.maps.event.addListener(polygon, 'dblclick', onDblClick));\n }\n if (onDragEnd) {\n setDragendListener(google.maps.event.addListener(polygon, 'dragend', onDragEnd));\n }\n if (onDragStart) {\n setDragstartListener(google.maps.event.addListener(polygon, 'dragstart', onDragStart));\n }\n if (onMouseDown) {\n setMousedownListener(google.maps.event.addListener(polygon, 'mousedown', onMouseDown));\n }\n if (onMouseMove) {\n setMousemoveListener(google.maps.event.addListener(polygon, 'mousemove', onMouseMove));\n }\n if (onMouseOut) {\n setMouseoutListener(google.maps.event.addListener(polygon, 'mouseout', onMouseOut));\n }\n if (onMouseOver) {\n setMouseoverListener(google.maps.event.addListener(polygon, 'mouseover', onMouseOver));\n }\n if (onMouseUp) {\n setMouseupListener(google.maps.event.addListener(polygon, 'mouseup', onMouseUp));\n }\n if (onRightClick) {\n setRightclickListener(google.maps.event.addListener(polygon, 'rightclick', onRightClick));\n }\n if (onClick) {\n setClickListener(google.maps.event.addListener(polygon, 'click', onClick));\n }\n if (onDrag) {\n setDragListener(google.maps.event.addListener(polygon, 'drag', onDrag));\n }\n setInstance(polygon);\n if (onLoad) {\n onLoad(polygon);\n }\n return () => {\n if (dblclickListener !== null) {\n google.maps.event.removeListener(dblclickListener);\n }\n if (dragendListener !== null) {\n google.maps.event.removeListener(dragendListener);\n }\n if (dragstartListener !== null) {\n google.maps.event.removeListener(dragstartListener);\n }\n if (mousedownListener !== null) {\n google.maps.event.removeListener(mousedownListener);\n }\n if (mousemoveListener !== null) {\n google.maps.event.removeListener(mousemoveListener);\n }\n if (mouseoutListener !== null) {\n google.maps.event.removeListener(mouseoutListener);\n }\n if (mouseoverListener !== null) {\n google.maps.event.removeListener(mouseoverListener);\n }\n if (mouseupListener !== null) {\n google.maps.event.removeListener(mouseupListener);\n }\n if (rightclickListener !== null) {\n google.maps.event.removeListener(rightclickListener);\n }\n if (clickListener !== null) {\n google.maps.event.removeListener(clickListener);\n }\n if (onUnmount) {\n onUnmount(polygon);\n }\n polygon.setMap(null);\n };\n }, []);\n return null;\n}\nconst PolygonF = /*#__PURE__*/memo(PolygonFunctional);\nclass Polygon extends PureComponent {\n constructor() {\n super(...arguments);\n this.registeredEvents = [];\n this.state = {\n polygon: null\n };\n this.setPolygonCallback = () => {\n if (this.state.polygon !== null && this.props.onLoad) {\n this.props.onLoad(this.state.polygon);\n }\n };\n }\n componentDidMount() {\n const polygon = new google.maps.Polygon(Object.assign(Object.assign({}, this.props.options || {}), {\n // @ts-ignore\n map: this.context\n }));\n this.registeredEvents = applyUpdatersToPropsAndRegisterEvents({\n updaterMap: updaterMap$a,\n eventMap: eventMap$a,\n prevProps: {},\n nextProps: this.props,\n instance: polygon\n });\n this.setState(function setPolygon() {\n return {\n polygon\n };\n }, this.setPolygonCallback);\n }\n componentDidUpdate(prevProps) {\n if (this.state.polygon !== null) {\n unregisterEvents(this.registeredEvents);\n this.registeredEvents = applyUpdatersToPropsAndRegisterEvents({\n updaterMap: updaterMap$a,\n eventMap: eventMap$a,\n prevProps,\n nextProps: this.props,\n instance: this.state.polygon\n });\n }\n }\n componentWillUnmount() {\n if (this.state.polygon !== null) {\n if (this.props.onUnmount) {\n this.props.onUnmount(this.state.polygon);\n }\n unregisterEvents(this.registeredEvents);\n this.state.polygon && this.state.polygon.setMap(null);\n }\n }\n render() {\n return null;\n }\n}\nPolygon.contextType = MapContext;\nconst eventMap$9 = {\n onBoundsChanged: 'bounds_changed',\n onClick: 'click',\n onDblClick: 'dblclick',\n onDrag: 'drag',\n onDragEnd: 'dragend',\n onDragStart: 'dragstart',\n onMouseDown: 'mousedown',\n onMouseMove: 'mousemove',\n onMouseOut: 'mouseout',\n onMouseOver: 'mouseover',\n onMouseUp: 'mouseup',\n onRightClick: 'rightclick'\n};\nconst updaterMap$9 = {\n bounds(instance, bounds) {\n instance.setBounds(bounds);\n },\n draggable(instance, draggable) {\n instance.setDraggable(draggable);\n },\n editable(instance, editable) {\n instance.setEditable(editable);\n },\n map(instance, map) {\n instance.setMap(map);\n },\n options(instance, options) {\n instance.setOptions(options);\n },\n visible(instance, visible) {\n instance.setVisible(visible);\n }\n};\nfunction RectangleFunctional(_ref31) {\n let options = _ref31.options,\n bounds = _ref31.bounds,\n draggable = _ref31.draggable,\n editable = _ref31.editable,\n visible = _ref31.visible,\n onDblClick = _ref31.onDblClick,\n onDragEnd = _ref31.onDragEnd,\n onDragStart = _ref31.onDragStart,\n onMouseDown = _ref31.onMouseDown,\n onMouseMove = _ref31.onMouseMove,\n onMouseOut = _ref31.onMouseOut,\n onMouseOver = _ref31.onMouseOver,\n onMouseUp = _ref31.onMouseUp,\n onRightClick = _ref31.onRightClick,\n onClick = _ref31.onClick,\n onDrag = _ref31.onDrag,\n onBoundsChanged = _ref31.onBoundsChanged,\n onLoad = _ref31.onLoad,\n onUnmount = _ref31.onUnmount;\n const map = useContext(MapContext);\n const _useState185 = useState(null),\n _useState186 = _slicedToArray(_useState185, 2),\n instance = _useState186[0],\n setInstance = _useState186[1];\n const _useState187 = useState(null),\n _useState188 = _slicedToArray(_useState187, 2),\n dblclickListener = _useState188[0],\n setDblclickListener = _useState188[1];\n const _useState189 = useState(null),\n _useState190 = _slicedToArray(_useState189, 2),\n dragendListener = _useState190[0],\n setDragendListener = _useState190[1];\n const _useState191 = useState(null),\n _useState192 = _slicedToArray(_useState191, 2),\n dragstartListener = _useState192[0],\n setDragstartListener = _useState192[1];\n const _useState193 = useState(null),\n _useState194 = _slicedToArray(_useState193, 2),\n mousedownListener = _useState194[0],\n setMousedownListener = _useState194[1];\n const _useState195 = useState(null),\n _useState196 = _slicedToArray(_useState195, 2),\n mousemoveListener = _useState196[0],\n setMousemoveListener = _useState196[1];\n const _useState197 = useState(null),\n _useState198 = _slicedToArray(_useState197, 2),\n mouseoutListener = _useState198[0],\n setMouseoutListener = _useState198[1];\n const _useState199 = useState(null),\n _useState200 = _slicedToArray(_useState199, 2),\n mouseoverListener = _useState200[0],\n setMouseoverListener = _useState200[1];\n const _useState201 = useState(null),\n _useState202 = _slicedToArray(_useState201, 2),\n mouseupListener = _useState202[0],\n setMouseupListener = _useState202[1];\n const _useState203 = useState(null),\n _useState204 = _slicedToArray(_useState203, 2),\n rightclickListener = _useState204[0],\n setRightclickListener = _useState204[1];\n const _useState205 = useState(null),\n _useState206 = _slicedToArray(_useState205, 2),\n clickListener = _useState206[0],\n setClickListener = _useState206[1];\n const _useState207 = useState(null),\n _useState208 = _slicedToArray(_useState207, 2),\n dragListener = _useState208[0],\n setDragListener = _useState208[1];\n const _useState209 = useState(null),\n _useState210 = _slicedToArray(_useState209, 2),\n boundsChangedListener = _useState210[0],\n setBoundsChangedListener = _useState210[1];\n // Order does matter\n useEffect(() => {\n if (instance !== null) {\n instance.setMap(map);\n }\n }, [map]);\n useEffect(() => {\n if (typeof options !== 'undefined' && instance !== null) {\n instance.setOptions(options);\n }\n }, [instance, options]);\n useEffect(() => {\n if (typeof draggable !== 'undefined' && instance !== null) {\n instance.setDraggable(draggable);\n }\n }, [instance, draggable]);\n useEffect(() => {\n if (typeof editable !== 'undefined' && instance !== null) {\n instance.setEditable(editable);\n }\n }, [instance, editable]);\n useEffect(() => {\n if (typeof visible !== 'undefined' && instance !== null) {\n instance.setVisible(visible);\n }\n }, [instance, visible]);\n useEffect(() => {\n if (typeof bounds !== 'undefined' && instance !== null) {\n instance.setBounds(bounds);\n }\n }, [instance, bounds]);\n useEffect(() => {\n if (instance && onDblClick) {\n if (dblclickListener !== null) {\n google.maps.event.removeListener(dblclickListener);\n }\n setDblclickListener(google.maps.event.addListener(instance, 'dblclick', onDblClick));\n }\n }, [onDblClick]);\n useEffect(() => {\n if (instance && onDragEnd) {\n if (dragendListener !== null) {\n google.maps.event.removeListener(dragendListener);\n }\n setDragendListener(google.maps.event.addListener(instance, 'dragend', onDragEnd));\n }\n }, [onDragEnd]);\n useEffect(() => {\n if (instance && onDragStart) {\n if (dragstartListener !== null) {\n google.maps.event.removeListener(dragstartListener);\n }\n setDragstartListener(google.maps.event.addListener(instance, 'dragstart', onDragStart));\n }\n }, [onDragStart]);\n useEffect(() => {\n if (instance && onMouseDown) {\n if (mousedownListener !== null) {\n google.maps.event.removeListener(mousedownListener);\n }\n setMousedownListener(google.maps.event.addListener(instance, 'mousedown', onMouseDown));\n }\n }, [onMouseDown]);\n useEffect(() => {\n if (instance && onMouseMove) {\n if (mousemoveListener !== null) {\n google.maps.event.removeListener(mousemoveListener);\n }\n setMousemoveListener(google.maps.event.addListener(instance, 'mousemove', onMouseMove));\n }\n }, [onMouseMove]);\n useEffect(() => {\n if (instance && onMouseOut) {\n if (mouseoutListener !== null) {\n google.maps.event.removeListener(mouseoutListener);\n }\n setMouseoutListener(google.maps.event.addListener(instance, 'mouseout', onMouseOut));\n }\n }, [onMouseOut]);\n useEffect(() => {\n if (instance && onMouseOver) {\n if (mouseoverListener !== null) {\n google.maps.event.removeListener(mouseoverListener);\n }\n setMouseoverListener(google.maps.event.addListener(instance, 'mouseover', onMouseOver));\n }\n }, [onMouseOver]);\n useEffect(() => {\n if (instance && onMouseUp) {\n if (mouseupListener !== null) {\n google.maps.event.removeListener(mouseupListener);\n }\n setMouseupListener(google.maps.event.addListener(instance, 'mouseup', onMouseUp));\n }\n }, [onMouseUp]);\n useEffect(() => {\n if (instance && onRightClick) {\n if (rightclickListener !== null) {\n google.maps.event.removeListener(rightclickListener);\n }\n setRightclickListener(google.maps.event.addListener(instance, 'rightclick', onRightClick));\n }\n }, [onRightClick]);\n useEffect(() => {\n if (instance && onClick) {\n if (clickListener !== null) {\n google.maps.event.removeListener(clickListener);\n }\n setClickListener(google.maps.event.addListener(instance, 'click', onClick));\n }\n }, [onClick]);\n useEffect(() => {\n if (instance && onDrag) {\n if (dragListener !== null) {\n google.maps.event.removeListener(dragListener);\n }\n setDragListener(google.maps.event.addListener(instance, 'drag', onDrag));\n }\n }, [onDrag]);\n useEffect(() => {\n if (instance && onBoundsChanged) {\n if (boundsChangedListener !== null) {\n google.maps.event.removeListener(boundsChangedListener);\n }\n setBoundsChangedListener(google.maps.event.addListener(instance, 'bounds_changed', onBoundsChanged));\n }\n }, [onBoundsChanged]);\n useEffect(() => {\n const rectangle = new google.maps.Rectangle(Object.assign(Object.assign({}, options || {}), {\n map\n }));\n if (typeof visible !== 'undefined') {\n rectangle.setVisible(visible);\n }\n if (typeof editable !== 'undefined') {\n rectangle.setEditable(editable);\n }\n if (typeof draggable !== 'undefined') {\n rectangle.setDraggable(draggable);\n }\n if (typeof bounds !== 'undefined') {\n rectangle.setBounds(bounds);\n }\n if (onDblClick) {\n setDblclickListener(google.maps.event.addListener(rectangle, 'dblclick', onDblClick));\n }\n if (onDragEnd) {\n setDragendListener(google.maps.event.addListener(rectangle, 'dragend', onDragEnd));\n }\n if (onDragStart) {\n setDragstartListener(google.maps.event.addListener(rectangle, 'dragstart', onDragStart));\n }\n if (onMouseDown) {\n setMousedownListener(google.maps.event.addListener(rectangle, 'mousedown', onMouseDown));\n }\n if (onMouseMove) {\n setMousemoveListener(google.maps.event.addListener(rectangle, 'mousemove', onMouseMove));\n }\n if (onMouseOut) {\n setMouseoutListener(google.maps.event.addListener(rectangle, 'mouseout', onMouseOut));\n }\n if (onMouseOver) {\n setMouseoverListener(google.maps.event.addListener(rectangle, 'mouseover', onMouseOver));\n }\n if (onMouseUp) {\n setMouseupListener(google.maps.event.addListener(rectangle, 'mouseup', onMouseUp));\n }\n if (onRightClick) {\n setRightclickListener(google.maps.event.addListener(rectangle, 'rightclick', onRightClick));\n }\n if (onClick) {\n setClickListener(google.maps.event.addListener(rectangle, 'click', onClick));\n }\n if (onDrag) {\n setDragListener(google.maps.event.addListener(rectangle, 'drag', onDrag));\n }\n if (onBoundsChanged) {\n setBoundsChangedListener(google.maps.event.addListener(rectangle, 'bounds_changed', onBoundsChanged));\n }\n setInstance(rectangle);\n if (onLoad) {\n onLoad(rectangle);\n }\n return () => {\n if (dblclickListener !== null) {\n google.maps.event.removeListener(dblclickListener);\n }\n if (dragendListener !== null) {\n google.maps.event.removeListener(dragendListener);\n }\n if (dragstartListener !== null) {\n google.maps.event.removeListener(dragstartListener);\n }\n if (mousedownListener !== null) {\n google.maps.event.removeListener(mousedownListener);\n }\n if (mousemoveListener !== null) {\n google.maps.event.removeListener(mousemoveListener);\n }\n if (mouseoutListener !== null) {\n google.maps.event.removeListener(mouseoutListener);\n }\n if (mouseoverListener !== null) {\n google.maps.event.removeListener(mouseoverListener);\n }\n if (mouseupListener !== null) {\n google.maps.event.removeListener(mouseupListener);\n }\n if (rightclickListener !== null) {\n google.maps.event.removeListener(rightclickListener);\n }\n if (clickListener !== null) {\n google.maps.event.removeListener(clickListener);\n }\n if (dragListener !== null) {\n google.maps.event.removeListener(dragListener);\n }\n if (boundsChangedListener !== null) {\n google.maps.event.removeListener(boundsChangedListener);\n }\n if (onUnmount) {\n onUnmount(rectangle);\n }\n rectangle.setMap(null);\n };\n }, []);\n return null;\n}\nconst RectangleF = /*#__PURE__*/memo(RectangleFunctional);\nclass Rectangle extends PureComponent {\n constructor() {\n super(...arguments);\n this.registeredEvents = [];\n this.state = {\n rectangle: null\n };\n this.setRectangleCallback = () => {\n if (this.state.rectangle !== null && this.props.onLoad) {\n this.props.onLoad(this.state.rectangle);\n }\n };\n }\n componentDidMount() {\n const rectangle = new google.maps.Rectangle(Object.assign(Object.assign({}, this.props.options || {}), {\n // @ts-ignore\n map: this.context\n }));\n this.registeredEvents = applyUpdatersToPropsAndRegisterEvents({\n updaterMap: updaterMap$9,\n eventMap: eventMap$9,\n prevProps: {},\n nextProps: this.props,\n instance: rectangle\n });\n this.setState(function setRectangle() {\n return {\n rectangle\n };\n }, this.setRectangleCallback);\n }\n componentDidUpdate(prevProps) {\n if (this.state.rectangle !== null) {\n unregisterEvents(this.registeredEvents);\n this.registeredEvents = applyUpdatersToPropsAndRegisterEvents({\n updaterMap: updaterMap$9,\n eventMap: eventMap$9,\n prevProps,\n nextProps: this.props,\n instance: this.state.rectangle\n });\n }\n }\n componentWillUnmount() {\n if (this.state.rectangle !== null) {\n if (this.props.onUnmount) {\n this.props.onUnmount(this.state.rectangle);\n }\n unregisterEvents(this.registeredEvents);\n this.state.rectangle.setMap(null);\n }\n }\n render() {\n return null;\n }\n}\nRectangle.contextType = MapContext;\nconst eventMap$8 = {\n onCenterChanged: 'center_changed',\n onRadiusChanged: 'radius_changed',\n onClick: 'click',\n onDblClick: 'dblclick',\n onDrag: 'drag',\n onDragEnd: 'dragend',\n onDragStart: 'dragstart',\n onMouseDown: 'mousedown',\n onMouseMove: 'mousemove',\n onMouseOut: 'mouseout',\n onMouseOver: 'mouseover',\n onMouseUp: 'mouseup',\n onRightClick: 'rightclick'\n};\nconst updaterMap$8 = {\n center(instance, center) {\n instance.setCenter(center);\n },\n draggable(instance, draggable) {\n instance.setDraggable(draggable);\n },\n editable(instance, editable) {\n instance.setEditable(editable);\n },\n map(instance, map) {\n instance.setMap(map);\n },\n options(instance, options) {\n instance.setOptions(options);\n },\n radius(instance, radius) {\n instance.setRadius(radius);\n },\n visible(instance, visible) {\n instance.setVisible(visible);\n }\n};\nconst defaultOptions = {};\nfunction CircleFunctional(_ref32) {\n let options = _ref32.options,\n center = _ref32.center,\n radius = _ref32.radius,\n draggable = _ref32.draggable,\n editable = _ref32.editable,\n visible = _ref32.visible,\n onDblClick = _ref32.onDblClick,\n onDragEnd = _ref32.onDragEnd,\n onDragStart = _ref32.onDragStart,\n onMouseDown = _ref32.onMouseDown,\n onMouseMove = _ref32.onMouseMove,\n onMouseOut = _ref32.onMouseOut,\n onMouseOver = _ref32.onMouseOver,\n onMouseUp = _ref32.onMouseUp,\n onRightClick = _ref32.onRightClick,\n onClick = _ref32.onClick,\n onDrag = _ref32.onDrag,\n onCenterChanged = _ref32.onCenterChanged,\n onRadiusChanged = _ref32.onRadiusChanged,\n onLoad = _ref32.onLoad,\n onUnmount = _ref32.onUnmount;\n const map = useContext(MapContext);\n const _useState211 = useState(null),\n _useState212 = _slicedToArray(_useState211, 2),\n instance = _useState212[0],\n setInstance = _useState212[1];\n const _useState213 = useState(null),\n _useState214 = _slicedToArray(_useState213, 2),\n dblclickListener = _useState214[0],\n setDblclickListener = _useState214[1];\n const _useState215 = useState(null),\n _useState216 = _slicedToArray(_useState215, 2),\n dragendListener = _useState216[0],\n setDragendListener = _useState216[1];\n const _useState217 = useState(null),\n _useState218 = _slicedToArray(_useState217, 2),\n dragstartListener = _useState218[0],\n setDragstartListener = _useState218[1];\n const _useState219 = useState(null),\n _useState220 = _slicedToArray(_useState219, 2),\n mousedownListener = _useState220[0],\n setMousedownListener = _useState220[1];\n const _useState221 = useState(null),\n _useState222 = _slicedToArray(_useState221, 2),\n mousemoveListener = _useState222[0],\n setMousemoveListener = _useState222[1];\n const _useState223 = useState(null),\n _useState224 = _slicedToArray(_useState223, 2),\n mouseoutListener = _useState224[0],\n setMouseoutListener = _useState224[1];\n const _useState225 = useState(null),\n _useState226 = _slicedToArray(_useState225, 2),\n mouseoverListener = _useState226[0],\n setMouseoverListener = _useState226[1];\n const _useState227 = useState(null),\n _useState228 = _slicedToArray(_useState227, 2),\n mouseupListener = _useState228[0],\n setMouseupListener = _useState228[1];\n const _useState229 = useState(null),\n _useState230 = _slicedToArray(_useState229, 2),\n rightclickListener = _useState230[0],\n setRightclickListener = _useState230[1];\n const _useState231 = useState(null),\n _useState232 = _slicedToArray(_useState231, 2),\n clickListener = _useState232[0],\n setClickListener = _useState232[1];\n const _useState233 = useState(null),\n _useState234 = _slicedToArray(_useState233, 2),\n dragListener = _useState234[0],\n setDragListener = _useState234[1];\n const _useState235 = useState(null),\n _useState236 = _slicedToArray(_useState235, 2),\n centerChangedListener = _useState236[0],\n setCenterChangedListener = _useState236[1];\n const _useState237 = useState(null),\n _useState238 = _slicedToArray(_useState237, 2),\n radiusChangedListener = _useState238[0],\n setRadiusChangedListener = _useState238[1];\n // Order does matter\n useEffect(() => {\n if (instance !== null) {\n instance.setMap(map);\n }\n }, [map]);\n useEffect(() => {\n if (typeof options !== 'undefined' && instance !== null) {\n instance.setOptions(options);\n }\n }, [instance, options]);\n useEffect(() => {\n if (typeof draggable !== 'undefined' && instance !== null) {\n instance.setDraggable(draggable);\n }\n }, [instance, draggable]);\n useEffect(() => {\n if (typeof editable !== 'undefined' && instance !== null) {\n instance.setEditable(editable);\n }\n }, [instance, editable]);\n useEffect(() => {\n if (typeof visible !== 'undefined' && instance !== null) {\n instance.setVisible(visible);\n }\n }, [instance, visible]);\n useEffect(() => {\n if (typeof radius === 'number' && instance !== null) {\n instance.setRadius(radius);\n }\n }, [instance, radius]);\n useEffect(() => {\n if (typeof center !== 'undefined' && instance !== null) {\n instance.setCenter(center);\n }\n }, [instance, center]);\n useEffect(() => {\n if (instance && onDblClick) {\n if (dblclickListener !== null) {\n google.maps.event.removeListener(dblclickListener);\n }\n setDblclickListener(google.maps.event.addListener(instance, 'dblclick', onDblClick));\n }\n }, [onDblClick]);\n useEffect(() => {\n if (instance && onDragEnd) {\n if (dragendListener !== null) {\n google.maps.event.removeListener(dragendListener);\n }\n setDragendListener(google.maps.event.addListener(instance, 'dragend', onDragEnd));\n }\n }, [onDragEnd]);\n useEffect(() => {\n if (instance && onDragStart) {\n if (dragstartListener !== null) {\n google.maps.event.removeListener(dragstartListener);\n }\n setDragstartListener(google.maps.event.addListener(instance, 'dragstart', onDragStart));\n }\n }, [onDragStart]);\n useEffect(() => {\n if (instance && onMouseDown) {\n if (mousedownListener !== null) {\n google.maps.event.removeListener(mousedownListener);\n }\n setMousedownListener(google.maps.event.addListener(instance, 'mousedown', onMouseDown));\n }\n }, [onMouseDown]);\n useEffect(() => {\n if (instance && onMouseMove) {\n if (mousemoveListener !== null) {\n google.maps.event.removeListener(mousemoveListener);\n }\n setMousemoveListener(google.maps.event.addListener(instance, 'mousemove', onMouseMove));\n }\n }, [onMouseMove]);\n useEffect(() => {\n if (instance && onMouseOut) {\n if (mouseoutListener !== null) {\n google.maps.event.removeListener(mouseoutListener);\n }\n setMouseoutListener(google.maps.event.addListener(instance, 'mouseout', onMouseOut));\n }\n }, [onMouseOut]);\n useEffect(() => {\n if (instance && onMouseOver) {\n if (mouseoverListener !== null) {\n google.maps.event.removeListener(mouseoverListener);\n }\n setMouseoverListener(google.maps.event.addListener(instance, 'mouseover', onMouseOver));\n }\n }, [onMouseOver]);\n useEffect(() => {\n if (instance && onMouseUp) {\n if (mouseupListener !== null) {\n google.maps.event.removeListener(mouseupListener);\n }\n setMouseupListener(google.maps.event.addListener(instance, 'mouseup', onMouseUp));\n }\n }, [onMouseUp]);\n useEffect(() => {\n if (instance && onRightClick) {\n if (rightclickListener !== null) {\n google.maps.event.removeListener(rightclickListener);\n }\n setRightclickListener(google.maps.event.addListener(instance, 'rightclick', onRightClick));\n }\n }, [onRightClick]);\n useEffect(() => {\n if (instance && onClick) {\n if (clickListener !== null) {\n google.maps.event.removeListener(clickListener);\n }\n setClickListener(google.maps.event.addListener(instance, 'click', onClick));\n }\n }, [onClick]);\n useEffect(() => {\n if (instance && onDrag) {\n if (dragListener !== null) {\n google.maps.event.removeListener(dragListener);\n }\n setDragListener(google.maps.event.addListener(instance, 'drag', onDrag));\n }\n }, [onDrag]);\n useEffect(() => {\n if (instance && onCenterChanged) {\n if (centerChangedListener !== null) {\n google.maps.event.removeListener(centerChangedListener);\n }\n setCenterChangedListener(google.maps.event.addListener(instance, 'center_changed', onCenterChanged));\n }\n }, [onClick]);\n useEffect(() => {\n if (instance && onRadiusChanged) {\n if (radiusChangedListener !== null) {\n google.maps.event.removeListener(radiusChangedListener);\n }\n setRadiusChangedListener(google.maps.event.addListener(instance, 'radius_changed', onRadiusChanged));\n }\n }, [onRadiusChanged]);\n useEffect(() => {\n const circle = new google.maps.Circle(Object.assign(Object.assign({}, options || defaultOptions), {\n map\n }));\n if (typeof radius === 'number') {\n circle.setRadius(radius);\n }\n if (typeof center !== 'undefined') {\n circle.setCenter(center);\n }\n if (typeof radius === 'number') {\n circle.setRadius(radius);\n }\n if (typeof visible !== 'undefined') {\n circle.setVisible(visible);\n }\n if (typeof editable !== 'undefined') {\n circle.setEditable(editable);\n }\n if (typeof draggable !== 'undefined') {\n circle.setDraggable(draggable);\n }\n if (onDblClick) {\n setDblclickListener(google.maps.event.addListener(circle, 'dblclick', onDblClick));\n }\n if (onDragEnd) {\n setDragendListener(google.maps.event.addListener(circle, 'dragend', onDragEnd));\n }\n if (onDragStart) {\n setDragstartListener(google.maps.event.addListener(circle, 'dragstart', onDragStart));\n }\n if (onMouseDown) {\n setMousedownListener(google.maps.event.addListener(circle, 'mousedown', onMouseDown));\n }\n if (onMouseMove) {\n setMousemoveListener(google.maps.event.addListener(circle, 'mousemove', onMouseMove));\n }\n if (onMouseOut) {\n setMouseoutListener(google.maps.event.addListener(circle, 'mouseout', onMouseOut));\n }\n if (onMouseOver) {\n setMouseoverListener(google.maps.event.addListener(circle, 'mouseover', onMouseOver));\n }\n if (onMouseUp) {\n setMouseupListener(google.maps.event.addListener(circle, 'mouseup', onMouseUp));\n }\n if (onRightClick) {\n setRightclickListener(google.maps.event.addListener(circle, 'rightclick', onRightClick));\n }\n if (onClick) {\n setClickListener(google.maps.event.addListener(circle, 'click', onClick));\n }\n if (onDrag) {\n setDragListener(google.maps.event.addListener(circle, 'drag', onDrag));\n }\n if (onCenterChanged) {\n setCenterChangedListener(google.maps.event.addListener(circle, 'center_changed', onCenterChanged));\n }\n if (onRadiusChanged) {\n setRadiusChangedListener(google.maps.event.addListener(circle, 'radius_changed', onRadiusChanged));\n }\n setInstance(circle);\n if (onLoad) {\n onLoad(circle);\n }\n return () => {\n if (dblclickListener !== null) {\n google.maps.event.removeListener(dblclickListener);\n }\n if (dragendListener !== null) {\n google.maps.event.removeListener(dragendListener);\n }\n if (dragstartListener !== null) {\n google.maps.event.removeListener(dragstartListener);\n }\n if (mousedownListener !== null) {\n google.maps.event.removeListener(mousedownListener);\n }\n if (mousemoveListener !== null) {\n google.maps.event.removeListener(mousemoveListener);\n }\n if (mouseoutListener !== null) {\n google.maps.event.removeListener(mouseoutListener);\n }\n if (mouseoverListener !== null) {\n google.maps.event.removeListener(mouseoverListener);\n }\n if (mouseupListener !== null) {\n google.maps.event.removeListener(mouseupListener);\n }\n if (rightclickListener !== null) {\n google.maps.event.removeListener(rightclickListener);\n }\n if (clickListener !== null) {\n google.maps.event.removeListener(clickListener);\n }\n if (centerChangedListener !== null) {\n google.maps.event.removeListener(centerChangedListener);\n }\n if (radiusChangedListener !== null) {\n google.maps.event.removeListener(radiusChangedListener);\n }\n if (onUnmount) {\n onUnmount(circle);\n }\n circle.setMap(null);\n };\n }, []);\n return null;\n}\nconst CircleF = /*#__PURE__*/memo(CircleFunctional);\nclass Circle extends PureComponent {\n constructor() {\n super(...arguments);\n this.registeredEvents = [];\n this.state = {\n circle: null\n };\n this.setCircleCallback = () => {\n if (this.state.circle !== null && this.props.onLoad) {\n this.props.onLoad(this.state.circle);\n }\n };\n }\n componentDidMount() {\n const circle = new google.maps.Circle(Object.assign(Object.assign({}, this.props.options || {}), {\n // @ts-ignore\n map: this.context\n }));\n this.registeredEvents = applyUpdatersToPropsAndRegisterEvents({\n updaterMap: updaterMap$8,\n eventMap: eventMap$8,\n prevProps: {},\n nextProps: this.props,\n instance: circle\n });\n this.setState(function setCircle() {\n return {\n circle\n };\n }, this.setCircleCallback);\n }\n componentDidUpdate(prevProps) {\n if (this.state.circle !== null) {\n unregisterEvents(this.registeredEvents);\n this.registeredEvents = applyUpdatersToPropsAndRegisterEvents({\n updaterMap: updaterMap$8,\n eventMap: eventMap$8,\n prevProps,\n nextProps: this.props,\n instance: this.state.circle\n });\n }\n }\n componentWillUnmount() {\n if (this.state.circle !== null) {\n if (this.props.onUnmount) {\n this.props.onUnmount(this.state.circle);\n }\n unregisterEvents(this.registeredEvents);\n this.state.circle && this.state.circle.setMap(null);\n }\n }\n render() {\n return null;\n }\n}\nCircle.contextType = MapContext;\nconst eventMap$7 = {\n onClick: 'click',\n onDblClick: 'dblclick',\n onMouseDown: 'mousedown',\n onMouseOut: 'mouseout',\n onMouseOver: 'mouseover',\n onMouseUp: 'mouseup',\n onRightClick: 'rightclick',\n onAddFeature: 'addfeature',\n onRemoveFeature: 'removefeature',\n onRemoveProperty: 'removeproperty',\n onSetGeometry: 'setgeometry',\n onSetProperty: 'setproperty'\n};\nconst updaterMap$7 = {\n add(instance, feature) {\n instance.add(feature);\n },\n addgeojson(instance, geojson, options) {\n instance.addGeoJson(geojson, options);\n },\n contains(instance, feature) {\n instance.contains(feature);\n },\n foreach(instance, callback) {\n instance.forEach(callback);\n },\n loadgeojson(instance, url, options, callback) {\n instance.loadGeoJson(url, options, callback);\n },\n overridestyle(instance, feature, style) {\n instance.overrideStyle(feature, style);\n },\n remove(instance, feature) {\n instance.remove(feature);\n },\n revertstyle(instance, feature) {\n instance.revertStyle(feature);\n },\n controlposition(instance, controlPosition) {\n instance.setControlPosition(controlPosition);\n },\n controls(instance, controls) {\n instance.setControls(controls);\n },\n drawingmode(instance, mode) {\n instance.setDrawingMode(mode);\n },\n map(instance, map) {\n instance.setMap(map);\n },\n style(instance, style) {\n instance.setStyle(style);\n },\n togeojson(instance, callback) {\n instance.toGeoJson(callback);\n }\n};\nfunction DataFunctional(_ref33) {\n let options = _ref33.options,\n onClick = _ref33.onClick,\n onDblClick = _ref33.onDblClick,\n onMouseDown = _ref33.onMouseDown,\n onMouseMove = _ref33.onMouseMove,\n onMouseOut = _ref33.onMouseOut,\n onMouseOver = _ref33.onMouseOver,\n onMouseUp = _ref33.onMouseUp,\n onRightClick = _ref33.onRightClick,\n onAddFeature = _ref33.onAddFeature,\n onRemoveFeature = _ref33.onRemoveFeature,\n onRemoveProperty = _ref33.onRemoveProperty,\n onSetGeometry = _ref33.onSetGeometry,\n onSetProperty = _ref33.onSetProperty,\n onLoad = _ref33.onLoad,\n onUnmount = _ref33.onUnmount;\n const map = useContext(MapContext);\n const _useState239 = useState(null),\n _useState240 = _slicedToArray(_useState239, 2),\n instance = _useState240[0],\n setInstance = _useState240[1];\n const _useState241 = useState(null),\n _useState242 = _slicedToArray(_useState241, 2),\n dblclickListener = _useState242[0],\n setDblclickListener = _useState242[1];\n const _useState243 = useState(null),\n _useState244 = _slicedToArray(_useState243, 2),\n mousedownListener = _useState244[0],\n setMousedownListener = _useState244[1];\n const _useState245 = useState(null),\n _useState246 = _slicedToArray(_useState245, 2),\n mousemoveListener = _useState246[0],\n setMousemoveListener = _useState246[1];\n const _useState247 = useState(null),\n _useState248 = _slicedToArray(_useState247, 2),\n mouseoutListener = _useState248[0],\n setMouseoutListener = _useState248[1];\n const _useState249 = useState(null),\n _useState250 = _slicedToArray(_useState249, 2),\n mouseoverListener = _useState250[0],\n setMouseoverListener = _useState250[1];\n const _useState251 = useState(null),\n _useState252 = _slicedToArray(_useState251, 2),\n mouseupListener = _useState252[0],\n setMouseupListener = _useState252[1];\n const _useState253 = useState(null),\n _useState254 = _slicedToArray(_useState253, 2),\n rightclickListener = _useState254[0],\n setRightclickListener = _useState254[1];\n const _useState255 = useState(null),\n _useState256 = _slicedToArray(_useState255, 2),\n clickListener = _useState256[0],\n setClickListener = _useState256[1];\n const _useState257 = useState(null),\n _useState258 = _slicedToArray(_useState257, 2),\n addFeatureListener = _useState258[0],\n setAddFeatureListener = _useState258[1];\n const _useState259 = useState(null),\n _useState260 = _slicedToArray(_useState259, 2),\n removeFeatureListener = _useState260[0],\n setRemoveFeatureListener = _useState260[1];\n const _useState261 = useState(null),\n _useState262 = _slicedToArray(_useState261, 2),\n removePropertyListener = _useState262[0],\n setRemovePropertyListener = _useState262[1];\n const _useState263 = useState(null),\n _useState264 = _slicedToArray(_useState263, 2),\n setGeometryListener = _useState264[0],\n setSetGeometryListener = _useState264[1];\n const _useState265 = useState(null),\n _useState266 = _slicedToArray(_useState265, 2),\n setPropertyListener = _useState266[0],\n setSetPropertyListener = _useState266[1];\n // Order does matter\n useEffect(() => {\n if (instance !== null) {\n instance.setMap(map);\n }\n }, [map]);\n useEffect(() => {\n if (instance && onDblClick) {\n if (dblclickListener !== null) {\n google.maps.event.removeListener(dblclickListener);\n }\n setDblclickListener(google.maps.event.addListener(instance, 'dblclick', onDblClick));\n }\n }, [onDblClick]);\n useEffect(() => {\n if (instance && onMouseDown) {\n if (mousedownListener !== null) {\n google.maps.event.removeListener(mousedownListener);\n }\n setMousedownListener(google.maps.event.addListener(instance, 'mousedown', onMouseDown));\n }\n }, [onMouseDown]);\n useEffect(() => {\n if (instance && onMouseMove) {\n if (mousemoveListener !== null) {\n google.maps.event.removeListener(mousemoveListener);\n }\n setMousemoveListener(google.maps.event.addListener(instance, 'mousemove', onMouseMove));\n }\n }, [onMouseMove]);\n useEffect(() => {\n if (instance && onMouseOut) {\n if (mouseoutListener !== null) {\n google.maps.event.removeListener(mouseoutListener);\n }\n setMouseoutListener(google.maps.event.addListener(instance, 'mouseout', onMouseOut));\n }\n }, [onMouseOut]);\n useEffect(() => {\n if (instance && onMouseOver) {\n if (mouseoverListener !== null) {\n google.maps.event.removeListener(mouseoverListener);\n }\n setMouseoverListener(google.maps.event.addListener(instance, 'mouseover', onMouseOver));\n }\n }, [onMouseOver]);\n useEffect(() => {\n if (instance && onMouseUp) {\n if (mouseupListener !== null) {\n google.maps.event.removeListener(mouseupListener);\n }\n setMouseupListener(google.maps.event.addListener(instance, 'mouseup', onMouseUp));\n }\n }, [onMouseUp]);\n useEffect(() => {\n if (instance && onRightClick) {\n if (rightclickListener !== null) {\n google.maps.event.removeListener(rightclickListener);\n }\n setRightclickListener(google.maps.event.addListener(instance, 'rightclick', onRightClick));\n }\n }, [onRightClick]);\n useEffect(() => {\n if (instance && onClick) {\n if (clickListener !== null) {\n google.maps.event.removeListener(clickListener);\n }\n setClickListener(google.maps.event.addListener(instance, 'click', onClick));\n }\n }, [onClick]);\n useEffect(() => {\n if (instance && onAddFeature) {\n if (addFeatureListener !== null) {\n google.maps.event.removeListener(addFeatureListener);\n }\n setAddFeatureListener(google.maps.event.addListener(instance, 'addfeature', onAddFeature));\n }\n }, [onAddFeature]);\n useEffect(() => {\n if (instance && onRemoveFeature) {\n if (removeFeatureListener !== null) {\n google.maps.event.removeListener(removeFeatureListener);\n }\n setRemoveFeatureListener(google.maps.event.addListener(instance, 'removefeature', onRemoveFeature));\n }\n }, [onRemoveFeature]);\n useEffect(() => {\n if (instance && onRemoveProperty) {\n if (removePropertyListener !== null) {\n google.maps.event.removeListener(removePropertyListener);\n }\n setRemovePropertyListener(google.maps.event.addListener(instance, 'removeproperty', onRemoveProperty));\n }\n }, [onRemoveProperty]);\n useEffect(() => {\n if (instance && onSetGeometry) {\n if (setGeometryListener !== null) {\n google.maps.event.removeListener(setGeometryListener);\n }\n setSetGeometryListener(google.maps.event.addListener(instance, 'setgeometry', onSetGeometry));\n }\n }, [onSetGeometry]);\n useEffect(() => {\n if (instance && onSetProperty) {\n if (setPropertyListener !== null) {\n google.maps.event.removeListener(setPropertyListener);\n }\n setSetPropertyListener(google.maps.event.addListener(instance, 'setproperty', onSetProperty));\n }\n }, [onSetProperty]);\n useEffect(() => {\n if (map !== null) {\n const data = new google.maps.Data(Object.assign(Object.assign({}, options || {}), {\n map\n }));\n if (onDblClick) {\n setDblclickListener(google.maps.event.addListener(data, 'dblclick', onDblClick));\n }\n if (onMouseDown) {\n setMousedownListener(google.maps.event.addListener(data, 'mousedown', onMouseDown));\n }\n if (onMouseMove) {\n setMousemoveListener(google.maps.event.addListener(data, 'mousemove', onMouseMove));\n }\n if (onMouseOut) {\n setMouseoutListener(google.maps.event.addListener(data, 'mouseout', onMouseOut));\n }\n if (onMouseOver) {\n setMouseoverListener(google.maps.event.addListener(data, 'mouseover', onMouseOver));\n }\n if (onMouseUp) {\n setMouseupListener(google.maps.event.addListener(data, 'mouseup', onMouseUp));\n }\n if (onRightClick) {\n setRightclickListener(google.maps.event.addListener(data, 'rightclick', onRightClick));\n }\n if (onClick) {\n setClickListener(google.maps.event.addListener(data, 'click', onClick));\n }\n if (onAddFeature) {\n setAddFeatureListener(google.maps.event.addListener(data, 'addfeature', onAddFeature));\n }\n if (onRemoveFeature) {\n setRemoveFeatureListener(google.maps.event.addListener(data, 'removefeature', onRemoveFeature));\n }\n if (onRemoveProperty) {\n setRemovePropertyListener(google.maps.event.addListener(data, 'removeproperty', onRemoveProperty));\n }\n if (onSetGeometry) {\n setSetGeometryListener(google.maps.event.addListener(data, 'setgeometry', onSetGeometry));\n }\n if (onSetProperty) {\n setSetPropertyListener(google.maps.event.addListener(data, 'setproperty', onSetProperty));\n }\n setInstance(data);\n if (onLoad) {\n onLoad(data);\n }\n }\n return () => {\n if (instance) {\n if (dblclickListener !== null) {\n google.maps.event.removeListener(dblclickListener);\n }\n if (mousedownListener !== null) {\n google.maps.event.removeListener(mousedownListener);\n }\n if (mousemoveListener !== null) {\n google.maps.event.removeListener(mousemoveListener);\n }\n if (mouseoutListener !== null) {\n google.maps.event.removeListener(mouseoutListener);\n }\n if (mouseoverListener !== null) {\n google.maps.event.removeListener(mouseoverListener);\n }\n if (mouseupListener !== null) {\n google.maps.event.removeListener(mouseupListener);\n }\n if (rightclickListener !== null) {\n google.maps.event.removeListener(rightclickListener);\n }\n if (clickListener !== null) {\n google.maps.event.removeListener(clickListener);\n }\n if (addFeatureListener !== null) {\n google.maps.event.removeListener(addFeatureListener);\n }\n if (removeFeatureListener !== null) {\n google.maps.event.removeListener(removeFeatureListener);\n }\n if (removePropertyListener !== null) {\n google.maps.event.removeListener(removePropertyListener);\n }\n if (setGeometryListener !== null) {\n google.maps.event.removeListener(setGeometryListener);\n }\n if (setPropertyListener !== null) {\n google.maps.event.removeListener(setPropertyListener);\n }\n if (onUnmount) {\n onUnmount(instance);\n }\n instance.setMap(null);\n }\n };\n }, []);\n return null;\n}\nconst DataF = /*#__PURE__*/memo(DataFunctional);\nclass Data extends PureComponent {\n constructor() {\n super(...arguments);\n this.registeredEvents = [];\n this.state = {\n data: null\n };\n this.setDataCallback = () => {\n if (this.state.data !== null && this.props.onLoad) {\n this.props.onLoad(this.state.data);\n }\n };\n }\n componentDidMount() {\n if (this.context !== null) {\n const data = new google.maps.Data(Object.assign(Object.assign({}, this.props.options || {}), {\n map: this.context\n }));\n this.registeredEvents = applyUpdatersToPropsAndRegisterEvents({\n updaterMap: updaterMap$7,\n eventMap: eventMap$7,\n prevProps: {},\n nextProps: this.props,\n instance: data\n });\n this.setState(() => {\n return {\n data\n };\n }, this.setDataCallback);\n }\n }\n componentDidUpdate(prevProps) {\n if (this.state.data !== null) {\n unregisterEvents(this.registeredEvents);\n this.registeredEvents = applyUpdatersToPropsAndRegisterEvents({\n updaterMap: updaterMap$7,\n eventMap: eventMap$7,\n prevProps,\n nextProps: this.props,\n instance: this.state.data\n });\n }\n }\n componentWillUnmount() {\n if (this.state.data !== null) {\n if (this.props.onUnmount) {\n this.props.onUnmount(this.state.data);\n }\n unregisterEvents(this.registeredEvents);\n if (this.state.data) {\n this.state.data.setMap(null);\n }\n }\n }\n render() {\n return null;\n }\n}\nData.contextType = MapContext;\nconst eventMap$6 = {\n onClick: 'click',\n onDefaultViewportChanged: 'defaultviewport_changed',\n onStatusChanged: 'status_changed'\n};\nconst updaterMap$6 = {\n options(instance, options) {\n instance.setOptions(options);\n },\n url(instance, url) {\n instance.setUrl(url);\n },\n zIndex(instance, zIndex) {\n instance.setZIndex(zIndex);\n }\n};\nclass KmlLayer extends PureComponent {\n constructor() {\n super(...arguments);\n this.registeredEvents = [];\n this.state = {\n kmlLayer: null\n };\n this.setKmlLayerCallback = () => {\n if (this.state.kmlLayer !== null && this.props.onLoad) {\n this.props.onLoad(this.state.kmlLayer);\n }\n };\n }\n componentDidMount() {\n const kmlLayer = new google.maps.KmlLayer(Object.assign(Object.assign({}, this.props.options), {\n map: this.context\n }));\n this.registeredEvents = applyUpdatersToPropsAndRegisterEvents({\n updaterMap: updaterMap$6,\n eventMap: eventMap$6,\n prevProps: {},\n nextProps: this.props,\n instance: kmlLayer\n });\n this.setState(function setLmlLayer() {\n return {\n kmlLayer\n };\n }, this.setKmlLayerCallback);\n }\n componentDidUpdate(prevProps) {\n if (this.state.kmlLayer !== null) {\n unregisterEvents(this.registeredEvents);\n this.registeredEvents = applyUpdatersToPropsAndRegisterEvents({\n updaterMap: updaterMap$6,\n eventMap: eventMap$6,\n prevProps,\n nextProps: this.props,\n instance: this.state.kmlLayer\n });\n }\n }\n componentWillUnmount() {\n if (this.state.kmlLayer !== null) {\n if (this.props.onUnmount) {\n this.props.onUnmount(this.state.kmlLayer);\n }\n unregisterEvents(this.registeredEvents);\n this.state.kmlLayer.setMap(null);\n }\n }\n render() {\n return null;\n }\n}\nKmlLayer.contextType = MapContext;\nfunction getOffsetOverride(containerElement, getPixelPositionOffset) {\n return typeof getPixelPositionOffset === 'function' ? getPixelPositionOffset(containerElement.offsetWidth, containerElement.offsetHeight) : {\n x: 0,\n y: 0\n };\n}\n// eslint-disable-next-line @typescript-eslint/no-explicit-any\nfunction createLatLng(inst, Type) {\n return new Type(inst.lat, inst.lng);\n}\n// eslint-disable-next-line @typescript-eslint/no-explicit-any\nfunction createLatLngBounds(inst, Type) {\n return new Type(new google.maps.LatLng(inst.ne.lat, inst.ne.lng), new google.maps.LatLng(inst.sw.lat, inst.sw.lng));\n}\n// eslint-disable-next-line @typescript-eslint/no-explicit-any\nfunction ensureOfType(inst, type, factory) {\n return inst instanceof type ? inst : factory(inst, type);\n}\nfunction ensureOfTypeBounds(inst, type, factory) {\n return inst instanceof type ? inst : factory(inst, type);\n}\nfunction getLayoutStylesByBounds(mapCanvasProjection, offset, bounds) {\n const ne = mapCanvasProjection && mapCanvasProjection.fromLatLngToDivPixel(bounds.getNorthEast());\n const sw = mapCanvasProjection && mapCanvasProjection.fromLatLngToDivPixel(bounds.getSouthWest());\n if (ne && sw) {\n return {\n left: `${sw.x + offset.x}px`,\n top: `${ne.y + offset.y}px`,\n width: `${ne.x - sw.x - offset.x}px`,\n height: `${sw.y - ne.y - offset.y}px`\n };\n }\n return {\n left: '-9999px',\n top: '-9999px'\n };\n}\nfunction getLayoutStylesByPosition(mapCanvasProjection, offset, position) {\n const point = mapCanvasProjection && mapCanvasProjection.fromLatLngToDivPixel(position);\n if (point) {\n const x = point.x,\n y = point.y;\n return {\n left: `${x + offset.x}px`,\n top: `${y + offset.y}px`\n };\n }\n return {\n left: '-9999px',\n top: '-9999px'\n };\n}\nfunction getLayoutStyles(mapCanvasProjection, offset, bounds, position) {\n return bounds !== undefined ? getLayoutStylesByBounds(mapCanvasProjection, offset, ensureOfTypeBounds(bounds, google.maps.LatLngBounds, createLatLngBounds)) : getLayoutStylesByPosition(mapCanvasProjection, offset, ensureOfType(position, google.maps.LatLng, createLatLng));\n}\nfunction arePositionsEqual(currentPosition, previousPosition) {\n return currentPosition.left === previousPosition.left && currentPosition.top === previousPosition.top && currentPosition.width === previousPosition.height && currentPosition.height === previousPosition.height;\n}\nfunction createOverlay(container, pane, position, bounds, getPixelPositionOffset) {\n class Overlay extends google.maps.OverlayView {\n constructor(container, pane, position, bounds) {\n super();\n this.container = container;\n this.pane = pane;\n this.position = position;\n this.bounds = bounds;\n }\n onAdd() {\n var _a;\n const pane = (_a = this.getPanes()) === null || _a === void 0 ? void 0 : _a[this.pane];\n pane === null || pane === void 0 ? void 0 : pane.appendChild(this.container);\n }\n draw() {\n const projection = this.getProjection();\n const offset = Object.assign({}, this.container ? getOffsetOverride(this.container, getPixelPositionOffset) : {\n x: 0,\n y: 0\n });\n const layoutStyles = getLayoutStyles(projection, offset, this.bounds, this.position);\n for (var _i2 = 0, _Object$entries = Object.entries(layoutStyles); _i2 < _Object$entries.length; _i2++) {\n const _Object$entries$_i = _slicedToArray(_Object$entries[_i2], 2),\n key = _Object$entries$_i[0],\n value = _Object$entries$_i[1];\n // eslint-disable-next-line @typescript-eslint/ban-ts-comment\n // @ts-ignore\n this.container.style[key] = value;\n }\n }\n onRemove() {\n if (this.container.parentNode !== null) {\n this.container.parentNode.removeChild(this.container);\n }\n }\n }\n return new Overlay(container, pane, position, bounds);\n}\nfunction convertToLatLngString(latLngLike) {\n if (!latLngLike) {\n return '';\n }\n const latLng = latLngLike instanceof google.maps.LatLng ? latLngLike : new google.maps.LatLng(latLngLike.lat, latLngLike.lng);\n return latLng + '';\n}\nfunction convertToLatLngBoundsString(latLngBoundsLike) {\n if (!latLngBoundsLike) {\n return '';\n }\n const latLngBounds = latLngBoundsLike instanceof google.maps.LatLngBounds ? latLngBoundsLike : new google.maps.LatLngBounds(new google.maps.LatLng(latLngBoundsLike.south, latLngBoundsLike.east), new google.maps.LatLng(latLngBoundsLike.north, latLngBoundsLike.west));\n return latLngBounds + '';\n}\nconst FLOAT_PANE = `floatPane`;\nconst MAP_PANE = `mapPane`;\nconst MARKER_LAYER = `markerLayer`;\nconst OVERLAY_LAYER = `overlayLayer`;\nconst OVERLAY_MOUSE_TARGET = `overlayMouseTarget`;\nfunction OverlayViewFunctional(_ref34) {\n let position = _ref34.position,\n bounds = _ref34.bounds,\n mapPaneName = _ref34.mapPaneName,\n zIndex = _ref34.zIndex,\n onLoad = _ref34.onLoad,\n onUnmount = _ref34.onUnmount,\n getPixelPositionOffset = _ref34.getPixelPositionOffset,\n children = _ref34.children;\n const map = useContext(MapContext);\n const container = useMemo(() => {\n const div = document.createElement('div');\n div.style.position = 'absolute';\n return div;\n }, []);\n const overlay = useMemo(() => {\n return createOverlay(container, mapPaneName, position, bounds, getPixelPositionOffset);\n }, [container, mapPaneName, position, bounds]);\n useEffect(() => {\n onLoad === null || onLoad === void 0 ? void 0 : onLoad(overlay);\n overlay === null || overlay === void 0 ? void 0 : overlay.setMap(map);\n return () => {\n onUnmount === null || onUnmount === void 0 ? void 0 : onUnmount(overlay);\n overlay === null || overlay === void 0 ? void 0 : overlay.setMap(null);\n };\n }, [map, overlay]);\n // to move the container to the foreground and background\n useEffect(() => {\n container.style.zIndex = `${zIndex}`;\n }, [zIndex, container]);\n return /*#__PURE__*/ReactDOM.createPortal(children, container);\n}\nconst OverlayViewF = /*#__PURE__*/memo(OverlayViewFunctional);\nclass OverlayView extends PureComponent {\n constructor(props) {\n super(props);\n this.state = {\n paneEl: null,\n containerStyle: {\n // set initial position\n position: 'absolute'\n }\n };\n this.updatePane = () => {\n const mapPaneName = this.props.mapPaneName;\n // https://developers.google.com/maps/documentation/javascript/3.exp/reference#MapPanes\n const mapPanes = this.overlayView.getPanes();\n invariant_1(!!mapPaneName, `OverlayView requires props.mapPaneName but got %s`, mapPaneName);\n if (mapPanes) {\n this.setState({\n paneEl: mapPanes[mapPaneName]\n });\n } else {\n this.setState({\n paneEl: null\n });\n }\n };\n this.onAdd = () => {\n var _a, _b;\n this.updatePane();\n (_b = (_a = this.props).onLoad) === null || _b === void 0 ? void 0 : _b.call(_a, this.overlayView);\n };\n this.onPositionElement = () => {\n const mapCanvasProjection = this.overlayView.getProjection();\n const offset = Object.assign({\n x: 0,\n y: 0\n }, this.containerRef.current ? getOffsetOverride(this.containerRef.current, this.props.getPixelPositionOffset) : {});\n const layoutStyles = getLayoutStyles(mapCanvasProjection, offset, this.props.bounds, this.props.position);\n const _this$state$container = this.state.containerStyle,\n left = _this$state$container.left,\n top = _this$state$container.top,\n width = _this$state$container.width,\n height = _this$state$container.height;\n if (!arePositionsEqual(layoutStyles, {\n left,\n top,\n width,\n height\n })) {\n this.setState({\n containerStyle: Object.assign(Object.assign({}, layoutStyles), {\n position: 'absolute'\n })\n });\n }\n };\n this.draw = () => {\n this.onPositionElement();\n };\n this.onRemove = () => {\n var _a, _b;\n this.setState(() => ({\n paneEl: null\n }));\n // this.mapPaneEl = null\n (_b = (_a = this.props).onUnmount) === null || _b === void 0 ? void 0 : _b.call(_a, this.overlayView);\n };\n this.containerRef = /*#__PURE__*/createRef();\n // You must implement three methods: onAdd(), draw(), and onRemove().\n const overlayView = new google.maps.OverlayView();\n overlayView.onAdd = this.onAdd;\n overlayView.draw = this.draw;\n overlayView.onRemove = this.onRemove;\n this.overlayView = overlayView;\n }\n componentDidMount() {\n // You must call setMap() with a valid Map object to trigger the call to\n // the onAdd() method and setMap(null) in order to trigger the onRemove() method.\n // eslint-disable-next-line @typescript-eslint/ban-ts-comment\n // @ts-ignore\n this.overlayView.setMap(this.context);\n }\n componentDidUpdate(prevProps) {\n const prevPositionString = convertToLatLngString(prevProps.position);\n const positionString = convertToLatLngString(this.props.position);\n const prevBoundsString = convertToLatLngBoundsString(prevProps.bounds);\n const boundsString = convertToLatLngBoundsString(this.props.bounds);\n if (prevPositionString !== positionString || prevBoundsString !== boundsString) {\n this.overlayView.draw();\n }\n if (prevProps.mapPaneName !== this.props.mapPaneName) {\n this.updatePane();\n }\n }\n componentWillUnmount() {\n this.overlayView.setMap(null);\n }\n render() {\n const paneEl = this.state.paneEl;\n if (paneEl) {\n return /*#__PURE__*/ReactDOM.createPortal(jsx(\"div\", Object.assign({\n ref: this.containerRef,\n style: this.state.containerStyle\n }, {\n children: Children.only(this.props.children)\n })), paneEl);\n } else {\n return null;\n }\n }\n}\nOverlayView.FLOAT_PANE = `floatPane`;\nOverlayView.MAP_PANE = `mapPane`;\nOverlayView.MARKER_LAYER = `markerLayer`;\nOverlayView.OVERLAY_LAYER = `overlayLayer`;\nOverlayView.OVERLAY_MOUSE_TARGET = `overlayMouseTarget`;\nOverlayView.contextType = MapContext;\nfunction noop() {\n return;\n}\nconst eventMap$5 = {\n onDblClick: 'dblclick',\n onClick: 'click'\n};\nconst updaterMap$5 = {\n opacity(instance, opacity) {\n instance.setOpacity(opacity);\n }\n};\nfunction GroundOverlayFunctional(_ref35) {\n let url = _ref35.url,\n bounds = _ref35.bounds,\n options = _ref35.options,\n visible = _ref35.visible;\n const map = useContext(MapContext);\n const imageBounds = new google.maps.LatLngBounds(new google.maps.LatLng(bounds.south, bounds.west), new google.maps.LatLng(bounds.north, bounds.east));\n const groundOverlay = useMemo(() => {\n const overlay = new google.maps.GroundOverlay(url, imageBounds, Object.assign({}, options));\n return overlay;\n }, []);\n useEffect(() => {\n if (groundOverlay !== null) {\n groundOverlay.setMap(map);\n }\n }, [map]);\n useEffect(() => {\n if (typeof url !== 'undefined' && groundOverlay !== null) {\n groundOverlay.set(\"url\", url);\n groundOverlay.setMap(map);\n }\n }, [groundOverlay, url]);\n useEffect(() => {\n if (typeof visible !== 'undefined' && groundOverlay !== null) {\n groundOverlay.setOpacity(visible ? 1 : 0);\n }\n }, [groundOverlay, visible]);\n useEffect(() => {\n const newBounds = new google.maps.LatLngBounds(new google.maps.LatLng(bounds.south, bounds.west), new google.maps.LatLng(bounds.north, bounds.east));\n if (typeof bounds !== 'undefined' && groundOverlay !== null) {\n groundOverlay.set(\"bounds\", newBounds);\n groundOverlay.setMap(map);\n }\n }, [groundOverlay, bounds]);\n return null;\n}\nconst GroundOverlayF = /*#__PURE__*/memo(GroundOverlayFunctional);\nclass GroundOverlay extends PureComponent {\n constructor() {\n super(...arguments);\n this.registeredEvents = [];\n this.state = {\n groundOverlay: null\n };\n this.setGroundOverlayCallback = () => {\n if (this.state.groundOverlay !== null && this.props.onLoad) {\n this.props.onLoad(this.state.groundOverlay);\n }\n };\n }\n componentDidMount() {\n invariant_1(!!this.props.url || !!this.props.bounds, `For GroundOverlay, url and bounds are passed in to constructor and are immutable after instantiated. This is the behavior of Google Maps JavaScript API v3 ( See https://developers.google.com/maps/documentation/javascript/reference#GroundOverlay) Hence, use the corresponding two props provided by \\`react-google-maps-api\\`, url and bounds. In some cases, you'll need the GroundOverlay component to reflect the changes of url and bounds. You can leverage the React's key property to remount the component. Typically, just \\`key={url}\\` would serve your need. See https://github.com/tomchentw/react-google-maps/issues/655`);\n const groundOverlay = new google.maps.GroundOverlay(this.props.url, this.props.bounds, Object.assign(Object.assign({}, this.props.options), {\n map: this.context\n }));\n this.registeredEvents = applyUpdatersToPropsAndRegisterEvents({\n updaterMap: updaterMap$5,\n eventMap: eventMap$5,\n prevProps: {},\n nextProps: this.props,\n instance: groundOverlay\n });\n this.setState(function setGroundOverlay() {\n return {\n groundOverlay\n };\n }, this.setGroundOverlayCallback);\n }\n componentDidUpdate(prevProps) {\n if (this.state.groundOverlay !== null) {\n unregisterEvents(this.registeredEvents);\n this.registeredEvents = applyUpdatersToPropsAndRegisterEvents({\n updaterMap: updaterMap$5,\n eventMap: eventMap$5,\n prevProps,\n nextProps: this.props,\n instance: this.state.groundOverlay\n });\n }\n }\n componentWillUnmount() {\n if (this.state.groundOverlay) {\n if (this.props.onUnmount) {\n this.props.onUnmount(this.state.groundOverlay);\n }\n this.state.groundOverlay.setMap(null);\n }\n }\n render() {\n return null;\n }\n}\nGroundOverlay.defaultProps = {\n onLoad: noop\n};\nGroundOverlay.contextType = MapContext;\nconst eventMap$4 = {};\nconst updaterMap$4 = {\n data(instance, data) {\n instance.setData(data);\n },\n map(instance, map) {\n instance.setMap(map);\n },\n options(instance, options) {\n instance.setOptions(options);\n }\n};\nfunction HeatmapLayerFunctional(_ref36) {\n let data = _ref36.data,\n onLoad = _ref36.onLoad,\n onUnmount = _ref36.onUnmount,\n options = _ref36.options;\n const map = useContext(MapContext);\n const _useState267 = useState(null),\n _useState268 = _slicedToArray(_useState267, 2),\n instance = _useState268[0],\n setInstance = _useState268[1];\n useEffect(() => {\n if (!google.maps.visualization) {\n invariant_1(!!google.maps.visualization, 'Did you include prop libraries={[\"visualization\"]} in useJsApiScript? %s', google.maps.visualization);\n }\n }, []);\n useEffect(() => {\n invariant_1(!!data, 'data property is required in HeatmapLayer %s', data);\n }, [data]);\n // Order does matter\n useEffect(() => {\n if (instance !== null) {\n instance.setMap(map);\n }\n }, [map]);\n useEffect(() => {\n if (options && instance !== null) {\n instance.setOptions(options);\n }\n }, [instance, options]);\n useEffect(() => {\n const heatmapLayer = new google.maps.visualization.HeatmapLayer(Object.assign(Object.assign({}, options || {}), {\n data,\n map\n }));\n setInstance(heatmapLayer);\n if (onLoad) {\n onLoad(heatmapLayer);\n }\n return () => {\n if (instance !== null) {\n if (onUnmount) {\n onUnmount(instance);\n }\n instance.setMap(null);\n }\n };\n }, []);\n return null;\n}\nconst HeatmapLayerF = /*#__PURE__*/memo(HeatmapLayerFunctional);\nclass HeatmapLayer extends PureComponent {\n constructor() {\n super(...arguments);\n this.registeredEvents = [];\n this.state = {\n heatmapLayer: null\n };\n this.setHeatmapLayerCallback = () => {\n if (this.state.heatmapLayer !== null && this.props.onLoad) {\n this.props.onLoad(this.state.heatmapLayer);\n }\n };\n }\n componentDidMount() {\n invariant_1(!!google.maps.visualization, 'Did you include prop libraries={[\"visualization\"]} to ? %s', google.maps.visualization);\n invariant_1(!!this.props.data, 'data property is required in HeatmapLayer %s', this.props.data);\n const heatmapLayer = new google.maps.visualization.HeatmapLayer(Object.assign(Object.assign({}, this.props.options || {}), {\n data: this.props.data,\n map: this.context\n }));\n this.registeredEvents = applyUpdatersToPropsAndRegisterEvents({\n updaterMap: updaterMap$4,\n eventMap: eventMap$4,\n prevProps: {},\n nextProps: this.props,\n instance: heatmapLayer\n });\n this.setState(function setHeatmapLayer() {\n return {\n heatmapLayer\n };\n }, this.setHeatmapLayerCallback);\n }\n componentDidUpdate(prevProps) {\n unregisterEvents(this.registeredEvents);\n this.registeredEvents = applyUpdatersToPropsAndRegisterEvents({\n updaterMap: updaterMap$4,\n eventMap: eventMap$4,\n prevProps,\n nextProps: this.props,\n instance: this.state.heatmapLayer\n });\n }\n componentWillUnmount() {\n if (this.state.heatmapLayer !== null) {\n if (this.props.onUnmount) {\n this.props.onUnmount(this.state.heatmapLayer);\n }\n unregisterEvents(this.registeredEvents);\n this.state.heatmapLayer.setMap(null);\n }\n }\n render() {\n return null;\n }\n}\nHeatmapLayer.contextType = MapContext;\nconst eventMap$3 = {\n onCloseClick: 'closeclick',\n onPanoChanged: 'pano_changed',\n onPositionChanged: 'position_changed',\n onPovChanged: 'pov_changed',\n onResize: 'resize',\n onStatusChanged: 'status_changed',\n onVisibleChanged: 'visible_changed',\n onZoomChanged: 'zoom_changed'\n};\nconst updaterMap$3 = {\n register(instance, provider, options) {\n instance.registerPanoProvider(provider, options);\n },\n links(instance, links) {\n instance.setLinks(links);\n },\n motionTracking(instance, motionTracking) {\n instance.setMotionTracking(motionTracking);\n },\n options(instance, options) {\n instance.setOptions(options);\n },\n pano(instance, pano) {\n instance.setPano(pano);\n },\n position(instance, position) {\n instance.setPosition(position);\n },\n pov(instance, pov) {\n instance.setPov(pov);\n },\n visible(instance, visible) {\n instance.setVisible(visible);\n },\n zoom(instance, zoom) {\n instance.setZoom(zoom);\n }\n};\nclass StreetViewPanorama extends PureComponent {\n constructor() {\n super(...arguments);\n this.registeredEvents = [];\n this.state = {\n streetViewPanorama: null\n };\n this.setStreetViewPanoramaCallback = () => {\n if (this.state.streetViewPanorama !== null && this.props.onLoad) {\n this.props.onLoad(this.state.streetViewPanorama);\n }\n };\n }\n componentDidMount() {\n // @ts-ignore\n const streetViewPanorama = this.context.getStreetView();\n this.registeredEvents = applyUpdatersToPropsAndRegisterEvents({\n updaterMap: updaterMap$3,\n eventMap: eventMap$3,\n prevProps: {},\n nextProps: this.props,\n instance: streetViewPanorama\n });\n this.setState(() => {\n return {\n streetViewPanorama\n };\n }, this.setStreetViewPanoramaCallback);\n }\n componentDidUpdate(prevProps) {\n if (this.state.streetViewPanorama !== null) {\n unregisterEvents(this.registeredEvents);\n this.registeredEvents = applyUpdatersToPropsAndRegisterEvents({\n updaterMap: updaterMap$3,\n eventMap: eventMap$3,\n prevProps,\n nextProps: this.props,\n instance: this.state.streetViewPanorama\n });\n }\n }\n componentWillUnmount() {\n if (this.state.streetViewPanorama !== null) {\n if (this.props.onUnmount) {\n this.props.onUnmount(this.state.streetViewPanorama);\n }\n unregisterEvents(this.registeredEvents);\n this.state.streetViewPanorama.setVisible(false);\n }\n }\n render() {\n return null;\n }\n}\nStreetViewPanorama.contextType = MapContext;\nclass StreetViewService extends PureComponent {\n constructor() {\n super(...arguments);\n this.state = {\n streetViewService: null\n };\n this.setStreetViewServiceCallback = () => {\n if (this.state.streetViewService !== null && this.props.onLoad) {\n this.props.onLoad(this.state.streetViewService);\n }\n };\n }\n componentDidMount() {\n const streetViewService = new google.maps.StreetViewService();\n this.setState(function setStreetViewService() {\n return {\n streetViewService\n };\n }, this.setStreetViewServiceCallback);\n }\n componentWillUnmount() {\n if (this.state.streetViewService !== null && this.props.onUnmount) {\n this.props.onUnmount(this.state.streetViewService);\n }\n }\n render() {\n return null;\n }\n}\nStreetViewService.contextType = MapContext;\nclass DirectionsService extends React.PureComponent {\n constructor() {\n super(...arguments);\n this.state = {\n directionsService: null\n };\n this.setDirectionsServiceCallback = () => {\n if (this.state.directionsService !== null && this.props.onLoad) {\n this.props.onLoad(this.state.directionsService);\n }\n };\n }\n componentDidMount() {\n invariant_1(!!this.props.options, 'DirectionsService expected options object as parameter, but got %s', this.props.options);\n const directionsService = new google.maps.DirectionsService();\n this.setState(function setDirectionsService() {\n return {\n directionsService\n };\n }, this.setDirectionsServiceCallback);\n }\n componentDidUpdate() {\n if (this.state.directionsService !== null) {\n this.state.directionsService.route(this.props.options, this.props.callback);\n }\n }\n componentWillUnmount() {\n if (this.state.directionsService !== null) {\n if (this.props.onUnmount) {\n this.props.onUnmount(this.state.directionsService);\n }\n }\n }\n render() {\n return null;\n }\n}\nconst eventMap$2 = {\n onDirectionsChanged: 'directions_changed'\n};\nconst updaterMap$2 = {\n directions(instance, directions) {\n instance.setDirections(directions);\n },\n map(instance, map) {\n instance.setMap(map);\n },\n options(instance, options) {\n instance.setOptions(options);\n },\n panel(instance, panel) {\n instance.setPanel(panel);\n },\n routeIndex(instance, routeIndex) {\n instance.setRouteIndex(routeIndex);\n }\n};\nclass DirectionsRenderer extends PureComponent {\n constructor() {\n super(...arguments);\n this.registeredEvents = [];\n this.state = {\n directionsRenderer: null\n };\n this.setDirectionsRendererCallback = () => {\n if (this.state.directionsRenderer !== null) {\n // @ts-ignore\n this.state.directionsRenderer.setMap(this.context);\n if (this.props.onLoad) {\n this.props.onLoad(this.state.directionsRenderer);\n }\n }\n };\n }\n componentDidMount() {\n const directionsRenderer = new google.maps.DirectionsRenderer(this.props.options);\n this.registeredEvents = applyUpdatersToPropsAndRegisterEvents({\n updaterMap: updaterMap$2,\n eventMap: eventMap$2,\n prevProps: {},\n nextProps: this.props,\n instance: directionsRenderer\n });\n this.setState(function setDirectionsRenderer() {\n return {\n directionsRenderer\n };\n }, this.setDirectionsRendererCallback);\n }\n componentDidUpdate(prevProps) {\n if (this.state.directionsRenderer !== null) {\n unregisterEvents(this.registeredEvents);\n this.registeredEvents = applyUpdatersToPropsAndRegisterEvents({\n updaterMap: updaterMap$2,\n eventMap: eventMap$2,\n prevProps,\n nextProps: this.props,\n instance: this.state.directionsRenderer\n });\n }\n }\n componentWillUnmount() {\n if (this.state.directionsRenderer !== null) {\n if (this.props.onUnmount) {\n this.props.onUnmount(this.state.directionsRenderer);\n }\n unregisterEvents(this.registeredEvents);\n if (this.state.directionsRenderer) {\n this.state.directionsRenderer.setMap(null);\n }\n }\n }\n render() {\n return jsx(Fragment, {});\n }\n}\nDirectionsRenderer.contextType = MapContext;\nclass DistanceMatrixService extends React.PureComponent {\n constructor() {\n super(...arguments);\n this.state = {\n distanceMatrixService: null\n };\n this.setDistanceMatrixServiceCallback = () => {\n if (this.state.distanceMatrixService !== null && this.props.onLoad) {\n this.props.onLoad(this.state.distanceMatrixService);\n }\n };\n }\n componentDidMount() {\n invariant_1(!!this.props.options, 'DistanceMatrixService expected options object as parameter, but go %s', this.props.options);\n const distanceMatrixService = new google.maps.DistanceMatrixService();\n this.setState(function setDistanceMatrixService() {\n return {\n distanceMatrixService\n };\n }, this.setDistanceMatrixServiceCallback);\n }\n componentDidUpdate() {\n if (this.state.distanceMatrixService !== null) {\n this.state.distanceMatrixService.getDistanceMatrix(this.props.options, this.props.callback);\n }\n }\n componentWillUnmount() {\n if (this.state.distanceMatrixService !== null && this.props.onUnmount) {\n this.props.onUnmount(this.state.distanceMatrixService);\n }\n }\n render() {\n return null;\n }\n}\nconst eventMap$1 = {\n onPlacesChanged: 'places_changed'\n};\nconst updaterMap$1 = {\n bounds(instance, bounds) {\n instance.setBounds(bounds);\n }\n};\nclass StandaloneSearchBox extends PureComponent {\n constructor() {\n super(...arguments);\n this.registeredEvents = [];\n this.containerElement = /*#__PURE__*/createRef();\n this.state = {\n searchBox: null\n };\n this.setSearchBoxCallback = () => {\n if (this.state.searchBox !== null && this.props.onLoad) {\n this.props.onLoad(this.state.searchBox);\n }\n };\n }\n componentDidMount() {\n invariant_1(!!google.maps.places, 'You need to provide libraries={[\"places\"]} prop to component %s', google.maps.places);\n if (this.containerElement !== null && this.containerElement.current !== null) {\n const input = this.containerElement.current.querySelector('input');\n if (input !== null) {\n const searchBox = new google.maps.places.SearchBox(input, this.props.options);\n this.registeredEvents = applyUpdatersToPropsAndRegisterEvents({\n updaterMap: updaterMap$1,\n eventMap: eventMap$1,\n prevProps: {},\n nextProps: this.props,\n instance: searchBox\n });\n this.setState(function setSearchBox() {\n return {\n searchBox\n };\n }, this.setSearchBoxCallback);\n }\n }\n }\n componentDidUpdate(prevProps) {\n if (this.state.searchBox !== null) {\n unregisterEvents(this.registeredEvents);\n this.registeredEvents = applyUpdatersToPropsAndRegisterEvents({\n updaterMap: updaterMap$1,\n eventMap: eventMap$1,\n prevProps,\n nextProps: this.props,\n instance: this.state.searchBox\n });\n }\n }\n componentWillUnmount() {\n if (this.state.searchBox !== null) {\n if (this.props.onUnmount) {\n this.props.onUnmount(this.state.searchBox);\n }\n unregisterEvents(this.registeredEvents);\n }\n }\n render() {\n return jsx(\"div\", Object.assign({\n ref: this.containerElement\n }, {\n children: Children.only(this.props.children)\n }));\n }\n}\nStandaloneSearchBox.contextType = MapContext;\nconst eventMap = {\n onPlaceChanged: 'place_changed'\n};\nconst updaterMap = {\n bounds(instance, bounds) {\n instance.setBounds(bounds);\n },\n restrictions(instance, restrictions) {\n instance.setComponentRestrictions(restrictions);\n },\n fields(instance, fields) {\n instance.setFields(fields);\n },\n options(instance, options) {\n instance.setOptions(options);\n },\n types(instance, types) {\n instance.setTypes(types);\n }\n};\nclass Autocomplete extends PureComponent {\n constructor() {\n super(...arguments);\n this.registeredEvents = [];\n this.containerElement = /*#__PURE__*/createRef();\n this.state = {\n autocomplete: null\n };\n this.setAutocompleteCallback = () => {\n if (this.state.autocomplete !== null && this.props.onLoad) {\n this.props.onLoad(this.state.autocomplete);\n }\n };\n }\n componentDidMount() {\n invariant_1(!!google.maps.places, 'You need to provide libraries={[\"places\"]} prop to component %s', google.maps.places);\n // TODO: why current could be equal null?\n // @ts-ignore\n const input = this.containerElement.current.querySelector('input');\n if (input) {\n const autocomplete = new google.maps.places.Autocomplete(input, this.props.options);\n this.registeredEvents = applyUpdatersToPropsAndRegisterEvents({\n updaterMap,\n eventMap,\n prevProps: {},\n nextProps: this.props,\n instance: autocomplete\n });\n this.setState(() => {\n return {\n autocomplete\n };\n }, this.setAutocompleteCallback);\n }\n }\n componentDidUpdate(prevProps) {\n unregisterEvents(this.registeredEvents);\n this.registeredEvents = applyUpdatersToPropsAndRegisterEvents({\n updaterMap,\n eventMap,\n prevProps,\n nextProps: this.props,\n instance: this.state.autocomplete\n });\n }\n componentWillUnmount() {\n if (this.state.autocomplete !== null) {\n unregisterEvents(this.registeredEvents);\n }\n }\n render() {\n return jsx(\"div\", Object.assign({\n ref: this.containerElement,\n className: this.props.className\n }, {\n children: Children.only(this.props.children)\n }));\n }\n}\nAutocomplete.defaultProps = {\n className: ''\n};\nAutocomplete.contextType = MapContext;\nexport { Autocomplete, BicyclingLayer, BicyclingLayerF, Circle, CircleF, Data, DataF, DirectionsRenderer, DirectionsService, DistanceMatrixService, DrawingManager, DrawingManagerF, FLOAT_PANE, GoogleMap, index_esm as GoogleMapsMarkerClusterer, GoogleMarkerClusterer$1 as GoogleMarkerClusterer, GroundOverlay, GroundOverlayF, HeatmapLayer, HeatmapLayerF, InfoBoxComponent as InfoBox, InfoBoxF, InfoWindow, InfoWindowF, KmlLayer, LoadScript, LoadScriptNext$1 as LoadScriptNext, MAP_PANE, MARKER_LAYER, MapContext, Marker, ClustererComponent as MarkerClusterer, MarkerClustererF, MarkerF, OVERLAY_LAYER, OVERLAY_MOUSE_TARGET, OverlayView, OverlayViewF, Polygon, PolygonF, Polyline, PolylineF, Rectangle, RectangleF, StandaloneSearchBox, StreetViewPanorama, StreetViewService, TrafficLayer, TrafficLayerF, TransitLayer, TransitLayerF, useGoogleMap, useJsApiLoader, useLoadScript };","/**\n * @license React\n * react-jsx-runtime.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n'use strict';\n\nvar f = require(\"react\"),\n k = Symbol.for(\"react.element\"),\n l = Symbol.for(\"react.fragment\"),\n m = Object.prototype.hasOwnProperty,\n n = f.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,\n p = {\n key: !0,\n ref: !0,\n __self: !0,\n __source: !0\n };\nfunction q(c, a, g) {\n var b,\n d = {},\n e = null,\n h = null;\n void 0 !== g && (e = \"\" + g);\n void 0 !== a.key && (e = \"\" + a.key);\n void 0 !== a.ref && (h = a.ref);\n for (b in a) m.call(a, b) && !p.hasOwnProperty(b) && (d[b] = a[b]);\n if (c && c.defaultProps) for (b in a = c.defaultProps, a) void 0 === d[b] && (d[b] = a[b]);\n return {\n $$typeof: k,\n type: c,\n key: e,\n ref: h,\n props: d,\n _owner: n.current\n };\n}\nexports.Fragment = l;\nexports.jsx = q;\nexports.jsxs = q;","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-jsx-runtime.production.min.js');\n} else {\n module.exports = require('./cjs/react-jsx-runtime.development.js');\n}","function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }\nfunction _nonIterableRest() { throw new TypeError(\"Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\"); }\nfunction _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === \"string\") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === \"Object\" && o.constructor) n = o.constructor.name; if (n === \"Map\" || n === \"Set\") return Array.from(o); if (n === \"Arguments\" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }\nfunction _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i]; return arr2; }\nfunction _iterableToArrayLimit(arr, i) { var _i = null == arr ? null : \"undefined\" != typeof Symbol && arr[Symbol.iterator] || arr[\"@@iterator\"]; if (null != _i) { var _s, _e, _x, _r, _arr = [], _n = !0, _d = !1; try { if (_x = (_i = _i.call(arr)).next, 0 === i) { if (Object(_i) !== _i) return; _n = !1; } else for (; !(_n = (_s = _x.call(_i)).done) && (_arr.push(_s.value), _arr.length !== i); _n = !0); } catch (err) { _d = !0, _e = err; } finally { try { if (!_n && null != _i.return && (_r = _i.return(), Object(_r) !== _r)) return; } finally { if (_d) throw _e; } } return _arr; } }\nfunction _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }\nimport { useState as s } from \"react\";\nimport { useIsoMorphicEffect as f } from './use-iso-morphic-effect.js';\nimport { useLatestValue as m } from './use-latest-value.js';\nfunction i(e, o) {\n let _s = s(e),\n _s2 = _slicedToArray(_s, 2),\n u = _s2[0],\n t = _s2[1],\n r = m(e);\n return f(() => t(r.current), [r, t, ...o]), u;\n}\nexport { i as useComputed };"],"names":["_regeneratorRuntime","exports","Op","Object","prototype","hasOwn","hasOwnProperty","defineProperty","obj","key","desc","value","$Symbol","Symbol","iteratorSymbol","iterator","asyncIteratorSymbol","asyncIterator","toStringTagSymbol","toStringTag","define","enumerable","configurable","writable","err","wrap","innerFn","outerFn","self","tryLocsList","protoGenerator","Generator","generator","create","context","Context","makeInvokeMethod","tryCatch","fn","arg","type","call","ContinueSentinel","GeneratorFunction","GeneratorFunctionPrototype","IteratorPrototype","this","getProto","getPrototypeOf","NativeIteratorPrototype","values","Gp","defineIteratorMethods","forEach","method","_invoke","AsyncIterator","PromiseImpl","invoke","resolve","reject","record","result","__await","then","unwrapped","error","previousPromise","callInvokeWithMethodAndArg","state","Error","doneResult","delegate","delegateResult","maybeInvokeDelegate","sent","_sent","dispatchException","abrupt","done","methodName","undefined","return","TypeError","info","resultName","next","nextLoc","pushTryEntry","locs","entry","tryLoc","catchLoc","finallyLoc","afterLoc","tryEntries","push","resetTryEntry","completion","reset","iterable","iteratorMethod","isNaN","length","i","displayName","isGeneratorFunction","genFun","ctor","constructor","name","mark","setPrototypeOf","__proto__","awrap","async","Promise","iter","keys","val","object","reverse","pop","skipTempReset","prev","charAt","slice","stop","rootRecord","rval","exception","handle","loc","caught","hasCatch","hasFinally","finallyEntry","complete","finish","catch","thrown","delegateYield","_slicedToArray","arr","Array","isArray","_arrayWithHoles","_i","_s","_e","_x","_r","_arr","_n","_d","_iterableToArrayLimit","_unsupportedIterableToArray","_nonIterableRest","o","minLen","_arrayLikeToArray","n","toString","from","test","len","arr2","globalThis","window","g","invariant_1","condition","format","a","b","c","d","e","f","args","argIndex","replace","framesToPop","MapContext","createContext","applyUpdaterToNextProps","updaterMap","prevProps","nextProps","instance","map","nextValue","registerEvents","props","eventMap","registeredList","acc","googleEventName","onEventName","google","maps","event","addListener","reduce","newAcc","unregisterEvent","registered","removeListener","unregisterEvents","arguments","applyUpdatersToPropsAndRegisterEvents","_ref","registeredEvents","PureComponent","__rest$1","s","t","p","indexOf","getOwnPropertySymbols","propertyIsEnumerable","__awaiter","thisArg","_arguments","P","fulfilled","step","rejected","apply","isBrowser","document","injectScript","_ref3","url","id","nonce","existingScript","getElementById","windowWithGoogleMap","dataStateAttribute","getAttribute","src","originalInitMap","initMap","originalErrorCallback","onerror","remove","script","createElement","setAttribute","head","appendChild","console","isGoogleFontStyle","element","href","tagName","toLowerCase","styleSheet","cssText","innerHTML","preventGoogleFonts","getElementsByTagName","trueInsertBefore","insertBefore","bind","newElement","referenceElement","Reflect","trueAppend","textNode","makeLoadScriptUrl","_ref4","googleMapsApiKey","googleMapsClientId","_ref4$version","version","language","region","libraries","channel","mapIds","authReferrerPolicy","params","sort","join","cleaningUp","DefaultLoadingElement","jsx","children","defaultLoadScriptProps","LoadScript","super","check","createRef","loaded","cleanupCallback","isCleaningUp","_callee","promiseCallback","_context","timer","setInterval","clearInterval","cleanup","parentNode","removeChild","filter","includes","link","style","innerText","preventGoogleFontsLoading","onLoad","setState","onError","componentDidMount","componentDidUpdate","warn","componentWillUnmount","timeoutCallback","current","setTimeout","onUnmount","render","jsxs","Fragment","ref","loadingElement","defaultProps","fastDeepEqual$1","equal","RegExp","source","flags","valueOf","DEFAULT_ID","LoaderStatus","Loader","_ref6","apiKey","client","_ref6$id","_ref6$libraries","_ref6$retries","retries","_ref6$url","CALLBACK","callbacks","loading","errors","options","JSON","stringify","status","FAILURE","SUCCESS","LOADING","INITIALIZED","failed","createUrl","deleteScript","load","loadPromise","loadCallback","execute","setScript","callback","loadErrorCallback","defer","onerrorEvent","resetIfRetryingFailed","delay","Math","pow","log","setCallback","__googleMapsCallback","cb","useJsApiLoader","_ref7","_ref7$id","_ref7$version","isMounted","useRef","_useState32","useState","isLoaded","setLoaded","_useState34","loadError","setLoadError","useEffect","loader","useMemo","prevLibraries","eventMap$h","updaterMap$h","setOptions","TrafficLayer","trafficLayer","setTrafficLayerCallback","assign","setMap","contextType","BicyclingLayer","bicyclingLayer","setBicyclingLayerCallback","TransitLayer","transitLayer","setTransitLayerCallback","eventMap$g","onCircleComplete","onMarkerComplete","onOverlayComplete","onPolygonComplete","onPolylineComplete","onRectangleComplete","updaterMap$g","drawingMode","setDrawingMode","DrawingManager","drawingManager","setDrawingManagerCallback","drawing","eventMap$f","onAnimationChanged","onClick","onClickableChanged","onCursorChanged","onDblClick","onDrag","onDragEnd","onDraggableChanged","onDragStart","onFlatChanged","onIconChanged","onMouseDown","onMouseOut","onMouseOver","onMouseUp","onPositionChanged","onRightClick","onShapeChanged","onTitleChanged","onVisibleChanged","onZindexChanged","updaterMap$f","animation","setAnimation","clickable","setClickable","cursor","setCursor","draggable","setDraggable","icon","setIcon","label","setLabel","opacity","setOpacity","position","setPosition","shape","setShape","title","setTitle","visible","setVisible","zIndex","setZIndex","defaultOptions$5","Marker","markerOptions","clusterer","marker","addMarker","noClustererRedraw","removeMarker","Children","child","isValidElement","elementChild","cloneElement","anchor","ClusterIcon","cluster","styles","getClusterer","extend","OverlayView","clusterClassName","getClusterClass","className","center","div","sums","boundsChangedListener","height","width","anchorText","anchorIcon","textColor","textSize","textDecoration","fontWeight","fontStyle","fontFamily","backgroundPosition","cMouseDownInCluster","cDraggingMapByCluster","timeOut","getMap","onBoundsChanged","onAdd","onRemove","draw","hide","show","useStyle","setCenter","getPosFromLatLng","markerClusterer_1","trigger","getZoomOnClick","maxZoom_1","getMaxZoom","bounds_1","getBounds","fitBounds","zoom","getZoom","setZoom","cancelBubble","stopPropagation","_a","getPanes","overlayMouseTarget","addEventListener","removeEventListener","clearTimeout","pos","top","concat","y","left","x","display","_b","_c","divTitle","getTitle","bp","split","spriteH","parseInt","spriteV","img","alt","enableRetinaIcons","clip","textElm","text","html","getStyles","min","max","index","latlng","getProjection","fromLatLngToDivPixel","Cluster$1","Cluster","markerClusterer","gridSize","getGridSize","minClusterSize","getMinimumClusterSize","averageCenter","getAverageCenter","markers","bounds","clusterIcon","getSize","getMarkers","getCenter","isMarkerInClusterBounds","calculateBounds","updateIcon","isMarkerAlreadyAdded","LatLngBounds","getPosition","length_1","LatLng","lat","lng","isAdded","mCount","maxZoom","contains","getExtendedBounds","getCalculator","CALCULATOR","numStyles","count","numberOfDigits","IMAGE_SIZES","Clusterer","optMarkers","optOptions","setMinimumClusterSize","getEnableRetinaIcons","setEnableRetinaIcons","addToClosestCluster","getImageExtension","setImageExtension","setAverageCenter","getTotalClusters","fitMapToMarkers","getIgnoreHidden","setIgnoreHidden","setClusterClass","getTotalMarkers","setZoomOnClick","getBatchSizeIE","setBatchSizeIE","createClusters","onZoomChanged","getImageSizes","setImageSizes","setCalculator","removeMarkers","resetViewport","getImagePath","setImagePath","pushMarkerTo","clearMarkers","setupStyles","setGridSize","getClusters","setMaxZoom","addMarkers","setStyles","repaint","onIdle","redraw","clusters","listeners","activeMap","ready","minimumClusterSize","zoomOnClick","ignoreHidden","imagePath","imageExtension","imageSizes","calculator","batchSize","batchSizeIE","clusterClass","navigator","userAgent","timerRefStatic","get","optNoDraw","_this","getDraggable","removeMarker_","splice","removed","oldClusters","projection","trPix","getNorthEast","blPix","getSouthWest","point1","fromDivPixelToLatLng","point2","optHide","distanceBetweenPoints","p1","p2","dLat","PI","dLon","sin","cos","atan2","sqrt","isMarkerInBounds","distance","clusterToAddTo","iFirst","mapBounds","extendedMapBounds","iLast","getVisible","obj1","obj2","property","eventMap$e","onClusteringBegin","onClusteringEnd","updaterMap$e","ClustererComponent","setClustererCallback","cancelHandler","InfoBox","getCloseClickHandler","closeClickHandler","createInfoBoxDiv","addClickHandler","getCloseBoxImg","getBoxWidths","setBoxStyle","setContent","getContent","getZIndex","panBox","close","open","content","disableAutoPan","maxWidth","pixelOffset","Size","boxClass","boxStyle","closeBoxMargin","closeBoxURL","infoBoxClearance","isHidden","alignBottom","pane","enableEventPropagation","closeListener","moveListener","mapListener","contextListener","eventListeners","fixedWidthSet","panes","offsetWidth","bw","right","events","returnValue","preventDefault","firstChild","disablePan","Map","xOffset","yOffset","mapDiv","getDiv","mapWidth","mapHeight","offsetHeight","iwOffsetX","iwOffsetY","iwWidth","iwHeight","padX","padY","pixPosition","fromLatLngToContainerPixel","panBy","webkitTransform","parseFloat","msFilter","visibility","overflow","bottom","defaultView","ownerDocument","computedStyle","getComputedStyle","borderTopWidth","borderBottomWidth","borderLeftWidth","borderRightWidth","documentElement","currentStyle","latLng","isVisible","eventMap$d","onCloseClick","onContentChanged","onDomReady","updaterMap$d","InfoBoxComponent","containerElement","infoBox","setInfoBoxCallback","infoBoxOptions","positionLatLng","createPortal","only","kdbush","sortKD","ids","coords","nodeSize","depth","m","select","k","inc","z","exp","sd","floor","j","swapItem","swap","tmp","range","minX","minY","maxX","maxY","stack","axis","nextAxis","within","qx","qy","r","r2","sqDist","ax","ay","bx","by","dx","dy","defaultGetX","defaultGetY","KDBush","points","getX","getY","ArrayType","Float64Array","IndexArrayType","Uint16Array","Uint32Array","factory","fround","Float32Array","MarkerClustererEvents","eventMap$c","updaterMap$c","InfoWindow","infoWindow","setInfoWindowCallback","eventMap$b","onMouseMove","updaterMap$b","editable","setEditable","path","setPath","Polyline","polyline","setPolylineCallback","eventMap$a","updaterMap$a","paths","setPaths","Polygon","polygon","setPolygonCallback","eventMap$9","updaterMap$9","setBounds","Rectangle","rectangle","setRectangleCallback","eventMap$8","onCenterChanged","onRadiusChanged","updaterMap$8","radius","setRadius","Circle","circle","setCircleCallback","eventMap$7","onAddFeature","onRemoveFeature","onRemoveProperty","onSetGeometry","onSetProperty","updaterMap$7","add","feature","addgeojson","geojson","addGeoJson","foreach","loadgeojson","loadGeoJson","overridestyle","overrideStyle","revertstyle","revertStyle","controlposition","controlPosition","setControlPosition","controls","setControls","drawingmode","mode","setStyle","togeojson","toGeoJson","Data","data","setDataCallback","eventMap$6","onDefaultViewportChanged","onStatusChanged","updaterMap$6","setUrl","KmlLayer","kmlLayer","setKmlLayerCallback","getOffsetOverride","getPixelPositionOffset","createLatLng","inst","Type","createLatLngBounds","ne","sw","getLayoutStyles","mapCanvasProjection","offset","getLayoutStylesByBounds","point","getLayoutStylesByPosition","ensureOfType","convertToLatLngString","latLngLike","convertToLatLngBoundsString","latLngBoundsLike","south","east","north","west","paneEl","containerStyle","updatePane","mapPaneName","mapPanes","overlayView","onPositionElement","layoutStyles","containerRef","_this$state$container","currentPosition","previousPosition","prevPositionString","positionString","prevBoundsString","boundsString","FLOAT_PANE","MAP_PANE","MARKER_LAYER","OVERLAY_LAYER","OVERLAY_MOUSE_TARGET","eventMap$5","updaterMap$5","GroundOverlay","groundOverlay","setGroundOverlayCallback","eventMap$4","updaterMap$4","setData","HeatmapLayer","heatmapLayer","setHeatmapLayerCallback","visualization","eventMap$3","onPanoChanged","onPovChanged","onResize","updaterMap$3","register","provider","registerPanoProvider","links","setLinks","motionTracking","setMotionTracking","pano","setPano","pov","setPov","StreetViewPanorama","streetViewPanorama","setStreetViewPanoramaCallback","getStreetView","StreetViewService","streetViewService","setStreetViewServiceCallback","eventMap$2","onDirectionsChanged","updaterMap$2","directions","setDirections","panel","setPanel","routeIndex","setRouteIndex","DirectionsRenderer","directionsRenderer","setDirectionsRendererCallback","eventMap$1","onPlacesChanged","updaterMap$1","StandaloneSearchBox","searchBox","setSearchBoxCallback","places","input","querySelector","SearchBox","onPlaceChanged","restrictions","setComponentRestrictions","fields","setFields","types","setTypes","Autocomplete","autocomplete","setAutocompleteCallback","for","l","__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED","ReactCurrentOwner","__self","__source","q","h","$$typeof","_owner","module","_s2","u"],"sourceRoot":""}