{"version":3,"sources":["webpack:///../../../src/mixins/overlayable/index.ts","webpack:///../../../src/components/VDialog/VDialog.ts","webpack:///../../../src/components/VOverlay/index.ts","webpack:///./node_modules/vue2-google-maps/dist/components/cluster.js","webpack:///./node_modules/marker-clusterer-plus/src/markerclusterer.js"],"names":["Vue","extend","name","props","hideOverlay","Boolean","overlayColor","String","overlayOpacity","Number","data","animationFrame","overlay","watch","value","this","isActive","removeOverlay","genOverlay","beforeDestroy","methods","createOverlay","VOverlay","propsData","absolute","color","opacity","$mount","parent","$el","parentNode","document","querySelector","insertBefore","firstChild","hideScroll","requestAnimationFrame","undefined","activeZIndex","zIndex","getZIndex","showScroll","addOnceEventListener","removeChild","$destroy","cancelAnimationFrame","scrollListener","e","includes","target","tagName","isContentEditable","up","keyCodes","pageup","down","pagedown","keyCode","deltaY","type","body","checkPath","preventDefault","hasScrollbar","el","nodeType","Node","ELEMENT_NODE","style","window","getComputedStyle","overflowY","scrollHeight","clientHeight","overflowX","scrollWidth","clientWidth","shouldScroll","hasAttribute","dir","shiftKey","deltaX","delta","alreadyAtStart","alreadyAtEnd","scrollTop","scrollLeft","scrollingUp","scrollingDown","isInside","path","composedPath","dialog","$refs","selected","getSelection","anchorNode","index","length","documentElement","content","$vuetify","breakpoint","smAndDown","classList","add","addPassiveEventListener","passive","addEventListener","remove","removeEventListener","baseMixins","mixins","Dependent","Detachable","Overlayable","Returnable","Stackable","Activatable","directives","ClickOutside","dark","disabled","fullscreen","light","maxWidth","noClickAnimation","origin","default","persistent","retainFocus","scrollable","transition","width","activatedBy","animate","animateTimeout","stackMinZIndex","previousActiveElement","computed","classes","contentClass","trim","contentClasses","hasActivator","$slots","activator","$scopedSlots","val","show","unbind","_a","focus","created","$attrs","hasOwnProperty","removed","beforeMount","$nextTick","isBooted","animateClick","clearTimeout","setTimeout","closeConditional","_isDestroyed","contains","getMaxZIndex","options","call","activeElement","_b","bind","onFocusin","onClickOutside","$emit","onKeydown","esc","getOpenDependents","getActivator","getOpenDependentElements","some","focusable","querySelectorAll","find","genContent","showLazyContent","$createElement","VThemeProvider","root","class","attrs","role","getScopeIdAttrs","on","keydown","ref","genTransition","genInnerContent","appear","tabindex","handler","include","transformOrigin","convertToUnit","getContentSlot","render","h","staticClass","attach","genActivator","Object","defineProperty","exports","_markerClustererPlus","_markerClustererPlus2","_interopRequireDefault","_mapElementFactory","_mapElementFactory2","obj","__esModule","_objectWithoutProperties","keys","i","indexOf","prototype","maxZoom","twoWay","batchSizeIE","calculator","Function","enableRetinaIcons","gridSize","ignoreHidden","imageExtension","imagePath","imageSizes","Array","minimumClusterSize","styles","zoomOnClick","events","mappedProps","ctr","console","error","Error","ctrArgs","_ref","map","otherOptions","afterCreate","inst","reinsertMarkers","oldMarkers","getMarkers","clearMarkers","addMarkers","prop","$on","toLowerCase","updated","$clusterObject","repaint","_this","$children","forEach","marker","ClusterIcon","cluster","getMarkerClusterer","google","maps","OverlayView","cluster_","className_","getClusterClass","styles_","center_","div_","sums_","visible_","setMap","getMap","Cluster","mc","markerClusterer_","map_","gridSize_","getGridSize","minClusterSize_","getMinimumClusterSize","averageCenter_","getAverageCenter","markers_","bounds_","clusterIcon_","getStyles","MarkerClusterer","opt_markers","opt_options","clusters_","listeners_","activeMap_","ready_","maxZoom_","title_","title","zoomOnClick_","averageCenter","ignoreHidden_","enableRetinaIcons_","imagePath_","IMAGE_PATH","imageExtension_","IMAGE_EXTENSION","imageSizes_","IMAGE_SIZES","calculator_","CALCULATOR","batchSize_","batchSize","BATCH_SIZE","batchSizeIE_","BATCH_SIZE_IE","clusterClass_","clusterClass","navigator","userAgent","setupStyles_","onAdd","cMouseDownInCluster","cDraggingMapByCluster","cClusterIcon","createElement","className","getPanes","overlayMouseTarget","appendChild","boundsChangedListener_","event","addListener","addDomListener","theBounds","mz","trigger","getZoomOnClick","getMaxZoom","getBounds","fitBounds","getZoom","setZoom","cancelBubble","stopPropagation","onRemove","hide","removeListener","clearInstanceListeners","draw","pos","getPosFromLatLng_","top","y","left","x","display","img","bp","backgroundPosition_","split","spriteH","parseInt","replace","spriteV","cssText","createCss","url_","width_","height_","innerHTML","anchorText_","textColor_","textSize_","fontFamily_","fontWeight_","fontStyle_","textDecoration_","text","getTitle","useStyle","sums","Math","max","min","url","height","anchorText","anchorIcon_","anchorIcon","textColor","textSize","textDecoration","fontWeight","fontStyle","fontFamily","backgroundPosition","setCenter","center","push","join","latlng","getProjection","fromLatLngToDivPixel","getSize","getCenter","bounds","LatLngBounds","markers","getPosition","addMarker","mCount","isMarkerAlreadyAdded_","l","lat","lng","LatLng","calculateBounds_","isAdded","updateIcon_","isMarkerInClusterBounds","getExtendedBounds","numStyles","getCalculator","cMarkerClusterer","resetViewport_","get","redraw_","size","fitMapToMarkers","setGridSize","setMinimumClusterSize","setMaxZoom","setStyles","setTitle","setZoomOnClick","setAverageCenter","getIgnoreHidden","setIgnoreHidden","getEnableRetinaIcons","setEnableRetinaIcons","getImageExtension","setImageExtension","getImagePath","setImagePath","getImageSizes","setImageSizes","setCalculator","getBatchSizeIE","setBatchSizeIE","setClusterClass","getTotalMarkers","getClusters","getTotalClusters","opt_nodraw","pushMarkerTo_","key","getDraggable","removeMarker","removeMarker_","removeMarkers","r","splice","oldClusters","slice","projection","tr","getNorthEast","bl","getSouthWest","trPix","blPix","ne","fromDivPixelToLatLng","sw","createClusters_","opt_hide","distanceBetweenPoints_","p1","p2","R","dLat","PI","dLon","a","sin","cos","c","atan2","sqrt","d","isMarkerInBounds_","addToClosestCluster_","distance","clusterToAddTo","iFirst","mapBounds","timerRefStatic","iLast","getVisible","obj1","obj2","object","property","apply","count","toString","dv","module"],"mappings":"qTAgCeA,eAAIC,SAAiDA,OAAO,CACzEC,KAAM,cAENC,MAAO,CACLC,YAAaC,QACbC,aAAcC,OACdC,eAAgB,CAACC,OAAQF,SAG3BG,OACE,MAAO,CACLC,eAAgB,EAChBC,QAAS,OAIbC,MAAO,CACLT,YAAaU,GACNC,KAAKC,WAENF,EAAOC,KAAKE,gBACXF,KA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8Q,EAAiBmD,gBAAgBuB,KAChC,WAEI3e,KAAK0e,eASZ3O,OAAOC,KAAKoE,MAAMK,QAAQzU,KAAM,gBAAiBA,SAarD0R,EAAgBzE,UAAU/N,OAAS,SAAU2f,EAAMC,GACjD,OAAO,SAAWC,GAChB,IAAIC,EACJ,IAAKA,KAAYD,EAAO9R,UACtBjN,KAAKiN,UAAU+R,GAAYD,EAAO9R,UAAU+R,GAE9C,OAAOhf,MACNif,MAAMJ,EAAM,CAACC,KAclBpN,EAAgBqB,WAAa,SAAUkG,EAASc,GAC9C,IAAI7U,EAAQ,EACRiN,EAAQ,GACR+M,EAAQjG,EAAQ9T,OAAOga,WAEvBC,EAAKF,EACT,MAAc,IAAPE,EACLA,EAAKjJ,SAASiJ,EAAK,GAAI,IACvBla,IAIF,OADAA,EAAQqS,KAAKE,IAAIvS,EAAO6U,GACjB,CACL5C,KAAM+H,EACNha,MAAOA,EACPiN,MAAOA,IAWXT,EAAgBwB,WAAa,IAS7BxB,EAAgB0B,cAAgB,IAShC1B,EAAgBe,WAAa,sGAS7Bf,EAAgBiB,gBAAkB,MASlCjB,EAAgBmB,YAAc,CAAC,GAAI,GAAI,GAAI,GAAI,IAE/CwM,EAAOhT,QAAUqF","file":"js/NOMBRAMIENTOS~PROSPECTOS~REUIONCONSEJERAS~actividades~initlab~reporteria~visitadetalle~visitasdetalle.64c8bcc7.js","sourcesContent":["// Components\nimport VOverlay from '../../components/VOverlay'\n\n// Utilities\nimport {\n keyCodes,\n addOnceEventListener,\n addPassiveEventListener,\n getZIndex,\n composedPath,\n} from '../../util/helpers'\n\n// Types\nimport Vue from 'vue'\n\ninterface Toggleable extends Vue {\n isActive?: boolean\n}\n\ninterface Stackable extends Vue {\n activeZIndex: number\n}\n\ninterface options {\n absolute?: boolean\n $refs: {\n dialog?: HTMLElement\n content?: HTMLElement\n }\n}\n\n/* @vue/component */\nexport default Vue.extend().extend({\n name: 'overlayable',\n\n props: {\n hideOverlay: Boolean,\n overlayColor: String,\n overlayOpacity: [Number, String],\n },\n\n data () {\n return {\n animationFrame: 0,\n overlay: null as InstanceType | null,\n }\n },\n\n watch: {\n hideOverlay (value) {\n if (!this.isActive) return\n\n if (value) this.removeOverlay()\n else this.genOverlay()\n },\n },\n\n beforeDestroy () {\n this.removeOverlay()\n },\n\n methods: {\n createOverlay () {\n const overlay = new VOverlay({\n propsData: {\n absolute: this.absolute,\n value: false,\n color: this.overlayColor,\n opacity: this.overlayOpacity,\n },\n })\n\n overlay.$mount()\n\n const parent = this.absolute\n ? this.$el.parentNode\n : document.querySelector('[data-app]')\n\n parent && parent.insertBefore(overlay.$el, parent.firstChild)\n\n this.overlay = overlay\n },\n genOverlay () {\n this.hideScroll()\n\n if (this.hideOverlay) return\n\n if (!this.overlay) this.createOverlay()\n\n this.animationFrame = requestAnimationFrame(() => {\n if (!this.overlay) return\n\n if (this.activeZIndex !== undefined) {\n this.overlay.zIndex = String(this.activeZIndex - 1)\n } else if (this.$el) {\n this.overlay.zIndex = getZIndex(this.$el)\n }\n\n this.overlay.value = true\n })\n\n return true\n },\n /** removeOverlay(false) will not restore the scollbar afterwards */\n removeOverlay (showScroll = true) {\n if (this.overlay) {\n addOnceEventListener(this.overlay.$el, 'transitionend', () => {\n if (\n !this.overlay ||\n !this.overlay.$el ||\n !this.overlay.$el.parentNode ||\n this.overlay.value ||\n this.isActive\n ) return\n\n this.overlay.$el.parentNode.removeChild(this.overlay.$el)\n this.overlay.$destroy()\n this.overlay = null\n })\n\n // Cancel animation frame in case\n // overlay is removed before it\n // has finished its animation\n cancelAnimationFrame(this.animationFrame)\n\n this.overlay.value = false\n }\n\n showScroll && this.showScroll()\n },\n scrollListener (e: WheelEvent | KeyboardEvent) {\n if ('key' in e) {\n if (\n ['INPUT', 'TEXTAREA', 'SELECT'].includes((e.target as Element).tagName) ||\n // https://github.com/vuetifyjs/vuetify/issues/4715\n (e.target as HTMLElement).isContentEditable\n ) return\n\n const up = [keyCodes.up, keyCodes.pageup]\n const down = [keyCodes.down, keyCodes.pagedown]\n\n if (up.includes(e.keyCode)) {\n (e as any).deltaY = -1\n } else if (down.includes(e.keyCode)) {\n (e as any).deltaY = 1\n } else {\n return\n }\n }\n\n if (e.target === this.overlay ||\n (e.type !== 'keydown' && e.target === document.body) ||\n this.checkPath(e as WheelEvent)) e.preventDefault()\n },\n hasScrollbar (el?: Element) {\n if (!el || el.nodeType !== Node.ELEMENT_NODE) return false\n\n const style = window.getComputedStyle(el)\n return ((['auto', 'scroll'].includes(style.overflowY!) || el.tagName === 'SELECT') && el.scrollHeight > el.clientHeight) ||\n ((['auto', 'scroll'].includes(style.overflowX!)) && el.scrollWidth > el.clientWidth)\n },\n shouldScroll (el: Element, e: WheelEvent): boolean {\n if (el.hasAttribute('data-app')) return false\n\n const dir = e.shiftKey || e.deltaX ? 'x' : 'y'\n const delta = dir === 'y' ? e.deltaY : e.deltaX || e.deltaY\n\n let alreadyAtStart: boolean\n let alreadyAtEnd: boolean\n if (dir === 'y') {\n alreadyAtStart = el.scrollTop === 0\n alreadyAtEnd = el.scrollTop + el.clientHeight === el.scrollHeight\n } else {\n alreadyAtStart = el.scrollLeft === 0\n alreadyAtEnd = el.scrollLeft + el.clientWidth === el.scrollWidth\n }\n\n const scrollingUp = delta < 0\n const scrollingDown = delta > 0\n\n if (!alreadyAtStart && scrollingUp) return true\n if (!alreadyAtEnd && scrollingDown) return true\n if ((alreadyAtStart || alreadyAtEnd)) {\n return this.shouldScroll(el.parentNode as Element, e)\n }\n\n return false\n },\n isInside (el: Element, parent: Element): boolean {\n if (el === parent) {\n return true\n } else if (el === null || el === document.body) {\n return false\n } else {\n return this.isInside(el.parentNode as Element, parent)\n }\n },\n checkPath (e: WheelEvent) {\n const path = composedPath(e)\n\n if (e.type === 'keydown' && path[0] === document.body) {\n const dialog = this.$refs.dialog\n // getSelection returns null in firefox in some edge cases, can be ignored\n const selected = window.getSelection()!.anchorNode as Element\n if (dialog && this.hasScrollbar(dialog) && this.isInside(selected, dialog)) {\n return !this.shouldScroll(dialog, e)\n }\n return true\n }\n\n for (let index = 0; index < path.length; index++) {\n const el = path[index]\n\n if (el === document) return true\n if (el === document.documentElement) return true\n if (el === this.$refs.content) return true\n\n if (this.hasScrollbar(el as Element)) return !this.shouldScroll(el as Element, e)\n }\n\n return true\n },\n hideScroll () {\n if (this.$vuetify.breakpoint.smAndDown) {\n document.documentElement!.classList.add('overflow-y-hidden')\n } else {\n addPassiveEventListener(window, 'wheel', this.scrollListener, { passive: false })\n window.addEventListener('keydown', this.scrollListener)\n }\n },\n showScroll () {\n document.documentElement!.classList.remove('overflow-y-hidden')\n window.removeEventListener('wheel', this.scrollListener)\n window.removeEventListener('keydown', this.scrollListener)\n },\n },\n})\n","// Styles\nimport './VDialog.sass'\n\n// Components\nimport { VThemeProvider } from '../VThemeProvider'\n\n// Mixins\nimport Activatable from '../../mixins/activatable'\nimport Dependent from '../../mixins/dependent'\nimport Detachable from '../../mixins/detachable'\nimport Overlayable from '../../mixins/overlayable'\nimport Returnable from '../../mixins/returnable'\nimport Stackable from '../../mixins/stackable'\n\n// Directives\nimport ClickOutside from '../../directives/click-outside'\n\n// Helpers\nimport mixins from '../../util/mixins'\nimport { removed } from '../../util/console'\nimport {\n convertToUnit,\n keyCodes,\n} from '../../util/helpers'\n\n// Types\nimport { VNode, VNodeData } from 'vue'\n\nconst baseMixins = mixins(\n Dependent,\n Detachable,\n Overlayable,\n Returnable,\n Stackable,\n Activatable,\n)\n\n/* @vue/component */\nexport default baseMixins.extend({\n name: 'v-dialog',\n\n directives: { ClickOutside },\n\n props: {\n dark: Boolean,\n disabled: Boolean,\n fullscreen: Boolean,\n light: Boolean,\n maxWidth: [String, Number],\n noClickAnimation: Boolean,\n origin: {\n type: String,\n default: 'center center',\n },\n persistent: Boolean,\n retainFocus: {\n type: Boolean,\n default: true,\n },\n scrollable: Boolean,\n transition: {\n type: [String, Boolean],\n default: 'dialog-transition',\n },\n width: [String, Number],\n },\n\n data () {\n return {\n activatedBy: null as EventTarget | null,\n animate: false,\n animateTimeout: -1,\n stackMinZIndex: 200,\n previousActiveElement: null as HTMLElement | null,\n }\n },\n\n computed: {\n classes (): object {\n return {\n [(`v-dialog ${this.contentClass}`).trim()]: true,\n 'v-dialog--active': this.isActive,\n 'v-dialog--persistent': this.persistent,\n 'v-dialog--fullscreen': this.fullscreen,\n 'v-dialog--scrollable': this.scrollable,\n 'v-dialog--animated': this.animate,\n }\n },\n contentClasses (): object {\n return {\n 'v-dialog__content': true,\n 'v-dialog__content--active': this.isActive,\n }\n },\n hasActivator (): boolean {\n return Boolean(\n !!this.$slots.activator ||\n !!this.$scopedSlots.activator\n )\n },\n },\n\n watch: {\n isActive (val) {\n if (val) {\n this.show()\n this.hideScroll()\n } else {\n this.removeOverlay()\n this.unbind()\n this.previousActiveElement?.focus()\n }\n },\n fullscreen (val) {\n if (!this.isActive) return\n\n if (val) {\n this.hideScroll()\n this.removeOverlay(false)\n } else {\n this.showScroll()\n this.genOverlay()\n }\n },\n },\n\n created () {\n /* istanbul ignore next */\n if (this.$attrs.hasOwnProperty('full-width')) {\n removed('full-width', this)\n }\n },\n\n beforeMount () {\n this.$nextTick(() => {\n this.isBooted = this.isActive\n this.isActive && this.show()\n })\n },\n\n beforeDestroy () {\n if (typeof window !== 'undefined') this.unbind()\n },\n\n methods: {\n animateClick () {\n this.animate = false\n // Needed for when clicking very fast\n // outside of the dialog\n this.$nextTick(() => {\n this.animate = true\n window.clearTimeout(this.animateTimeout)\n this.animateTimeout = window.setTimeout(() => (this.animate = false), 150)\n })\n },\n closeConditional (e: Event) {\n const target = e.target as HTMLElement\n // Ignore the click if the dialog is closed or destroyed,\n // if it was on an element inside the content,\n // if it was dragged onto the overlay (#6969),\n // or if this isn't the topmost dialog (#9907)\n return !(\n this._isDestroyed ||\n !this.isActive ||\n this.$refs.content.contains(target) ||\n (this.overlay && target && !this.overlay.$el.contains(target))\n ) && this.activeZIndex >= this.getMaxZIndex()\n },\n hideScroll () {\n if (this.fullscreen) {\n document.documentElement.classList.add('overflow-y-hidden')\n } else {\n Overlayable.options.methods.hideScroll.call(this)\n }\n },\n show () {\n !this.fullscreen && !this.hideOverlay && this.genOverlay()\n // Double nextTick to wait for lazy content to be generated\n this.$nextTick(() => {\n this.$nextTick(() => {\n if (!this.$refs.dialog?.contains(document.activeElement)) {\n this.previousActiveElement = document.activeElement as HTMLElement\n this.$refs.dialog?.focus()\n }\n this.bind()\n })\n })\n },\n bind () {\n window.addEventListener('focusin', this.onFocusin)\n },\n unbind () {\n window.removeEventListener('focusin', this.onFocusin)\n },\n onClickOutside (e: Event) {\n this.$emit('click:outside', e)\n\n if (this.persistent) {\n this.noClickAnimation || this.animateClick()\n } else {\n this.isActive = false\n }\n },\n onKeydown (e: KeyboardEvent) {\n if (e.keyCode === keyCodes.esc && !this.getOpenDependents().length) {\n if (!this.persistent) {\n this.isActive = false\n const activator = this.getActivator()\n this.$nextTick(() => activator && (activator as HTMLElement).focus())\n } else if (!this.noClickAnimation) {\n this.animateClick()\n }\n }\n this.$emit('keydown', e)\n },\n // On focus change, wrap focus to stay inside the dialog\n // https://github.com/vuetifyjs/vuetify/issues/6892\n onFocusin (e: Event) {\n if (!e || !this.retainFocus) return\n\n const target = e.target as HTMLElement\n\n if (\n !!target &&\n this.$refs.dialog &&\n // It isn't the document or the dialog body\n ![document, this.$refs.dialog].includes(target) &&\n // It isn't inside the dialog body\n !this.$refs.dialog.contains(target) &&\n // We're the topmost dialog\n this.activeZIndex >= this.getMaxZIndex() &&\n // It isn't inside a dependent element (like a menu)\n !this.getOpenDependentElements().some(el => el.contains(target))\n // So we must have focused something outside the dialog and its children\n ) {\n // Find and focus the first available element inside the dialog\n const focusable = this.$refs.dialog.querySelectorAll('button, [href], input, select, textarea, [tabindex]:not([tabindex=\"-1\"])')\n const el = [...focusable].find(el => !el.hasAttribute('disabled')) as HTMLElement | undefined\n el && el.focus()\n }\n },\n genContent () {\n return this.showLazyContent(() => [\n this.$createElement(VThemeProvider, {\n props: {\n root: true,\n light: this.light,\n dark: this.dark,\n },\n }, [\n this.$createElement('div', {\n class: this.contentClasses,\n attrs: {\n role: 'dialog',\n 'aria-modal': this.hideOverlay ? undefined : 'true',\n ...this.getScopeIdAttrs(),\n },\n on: { keydown: this.onKeydown },\n style: { zIndex: this.activeZIndex },\n ref: 'content',\n }, [this.genTransition()]),\n ]),\n ])\n },\n genTransition () {\n const content = this.genInnerContent()\n\n if (!this.transition) return content\n\n return this.$createElement('transition', {\n props: {\n name: this.transition,\n origin: this.origin,\n appear: true,\n },\n }, [content])\n },\n genInnerContent () {\n const data: VNodeData = {\n class: this.classes,\n attrs: {\n tabindex: this.isActive ? 0 : undefined,\n },\n ref: 'dialog',\n directives: [\n {\n name: 'click-outside',\n value: {\n handler: this.onClickOutside,\n closeConditional: this.closeConditional,\n include: this.getOpenDependentElements,\n },\n },\n { name: 'show', value: this.isActive },\n ],\n style: {\n transformOrigin: this.origin,\n },\n }\n\n if (!this.fullscreen) {\n data.style = {\n ...data.style as object,\n maxWidth: convertToUnit(this.maxWidth),\n width: convertToUnit(this.width),\n }\n }\n\n return this.$createElement('div', data, this.getContentSlot())\n },\n },\n\n render (h): VNode {\n return h('div', {\n staticClass: 'v-dialog__container',\n class: {\n 'v-dialog__container--attached':\n this.attach === '' ||\n this.attach === true ||\n this.attach === 'attach',\n },\n }, [\n this.genActivator(),\n this.genContent(),\n ])\n },\n})\n","import VOverlay from './VOverlay'\n\nexport { VOverlay }\n\nexport default VOverlay\n","'use strict';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\n\nvar _markerClustererPlus = require('marker-clusterer-plus');\n\nvar _markerClustererPlus2 = _interopRequireDefault(_markerClustererPlus);\n\nvar _mapElementFactory = require('./mapElementFactory.js');\n\nvar _mapElementFactory2 = _interopRequireDefault(_mapElementFactory);\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nfunction _objectWithoutProperties(obj, keys) { var target = {}; for (var i in obj) { if (keys.indexOf(i) >= 0) continue; if (!Object.prototype.hasOwnProperty.call(obj, i)) continue; target[i] = obj[i]; } return target; } /**\n * @class Cluster\n * @prop $clusterObject -- Exposes the marker clusterer to\n descendent Marker classes. Override this if you area\n extending the class\n \n List of properties from\n https://github.com/googlemaps/v3-utility-library/blob/master/markerclustererplus/src/markerclusterer.js\n **/\n\n\nvar props = {\n maxZoom: {\n type: Number,\n twoWay: false\n },\n batchSizeIE: {\n type: Number,\n twoWay: false\n },\n calculator: {\n type: Function,\n twoWay: false\n },\n enableRetinaIcons: {\n type: Boolean,\n twoWay: false\n },\n gridSize: {\n type: Number,\n twoWay: false\n },\n ignoreHidden: {\n type: Boolean,\n twoWay: false\n },\n imageExtension: {\n type: String,\n twoWay: false\n },\n imagePath: {\n type: String,\n twoWay: false\n },\n imageSizes: {\n type: Array,\n twoWay: false\n },\n minimumClusterSize: {\n type: Number,\n twoWay: false\n },\n styles: {\n type: Array,\n twoWay: false\n },\n zoomOnClick: {\n type: Boolean,\n twoWay: false\n }\n};\n\nvar events = ['click', 'rightclick', 'dblclick', 'drag', 'dragstart', 'dragend', 'mouseup', 'mousedown', 'mouseover', 'mouseout'];\n\nexports.default = (0, _mapElementFactory2.default)({\n mappedProps: props,\n events: events,\n name: 'cluster',\n ctr: function ctr() {\n if (typeof _markerClustererPlus2.default === 'undefined') {\n /* eslint-disable no-console */\n console.error('MarkerClusterer is not installed! require() it or include it from https://cdnjs.cloudflare.com/ajax/libs/js-marker-clusterer/1.0.0/markerclusterer.js');\n throw new Error('MarkerClusterer is not installed! require() it or include it from https://cdnjs.cloudflare.com/ajax/libs/js-marker-clusterer/1.0.0/markerclusterer.js');\n }\n return _markerClustererPlus2.default;\n },\n ctrArgs: function ctrArgs(_ref) {\n var map = _ref.map,\n otherOptions = _objectWithoutProperties(_ref, ['map']);\n\n return [map, [], otherOptions];\n },\n\n render: function render(h) {\n //
\n return h('div', this.$slots.default);\n },\n afterCreate: function afterCreate(inst) {\n var reinsertMarkers = function () {\n var oldMarkers = inst.getMarkers();\n inst.clearMarkers();\n inst.addMarkers(oldMarkers);\n };\n\n for (var prop in props) {\n if (props[prop].twoWay) {\n this.$on(prop.toLowerCase() + '_changed', reinsertMarkers);\n }\n }\n },\n updated: function updated() {\n if (this.$clusterObject) {\n this.$clusterObject.repaint();\n }\n },\n beforeDestroy: function beforeDestroy() {\n var _this = this;\n\n /* Performance optimization when destroying a large number of markers */\n this.$children.forEach(function (marker) {\n if (marker.$clusterObject === _this.$clusterObject) {\n marker.$clusterObject = null;\n }\n });\n\n if (this.$clusterObject) {\n this.$clusterObject.clearMarkers();\n }\n }\n});","/**\n * @name MarkerClustererPlus for Google Maps V3\n * @version 2.1.2 [May 28, 2014]\n * @author Gary Little\n * @fileoverview\n * The library creates and manages per-zoom-level clusters for large amounts of markers.\n *

\n * This is an enhanced V3 implementation of the\n * V2 MarkerClusterer by Xiaoxi Wu. It is based on the\n * V3 MarkerClusterer port by Luke Mahe. MarkerClustererPlus was created by Gary Little.\n *

\n * v2.0 release: MarkerClustererPlus v2.0 is backward compatible with MarkerClusterer v1.0. It\n * adds support for the ignoreHidden, title, batchSizeIE,\n * and calculator properties as well as support for four more events. It also allows\n * greater control over the styling of the text that appears on the cluster marker. The\n * documentation has been significantly improved and the overall code has been simplified and\n * polished. Very large numbers of markers can now be managed without causing Javascript timeout\n * errors on Internet Explorer. Note that the name of the clusterclick event has been\n * deprecated. The new name is click, so please change your application code now.\n */\n\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\n/**\n * @name ClusterIconStyle\n * @class This class represents the object for values in the styles array passed\n * to the {@link MarkerClusterer} constructor. The element in this array that is used to\n * style the cluster icon is determined by calling the calculator function.\n *\n * @property {string} url The URL of the cluster icon image file. Required.\n * @property {number} height The display height (in pixels) of the cluster icon. Required.\n * @property {number} width The display width (in pixels) of the cluster icon. Required.\n * @property {Array} [anchorText] The position (in pixels) from the center of the cluster icon to\n * where the text label is to be centered and drawn. The format is [yoffset, xoffset]\n * where yoffset increases as you go down from center and xoffset\n * increases to the right of center. The default is [0, 0].\n * @property {Array} [anchorIcon] The anchor position (in pixels) of the cluster icon. This is the\n * spot on the cluster icon that is to be aligned with the cluster position. The format is\n * [yoffset, xoffset] where yoffset increases as you go down and\n * xoffset increases to the right of the top-left corner of the icon. The default\n * anchor position is the center of the cluster icon.\n * @property {string} [textColor=\"black\"] The color of the label text shown on the\n * cluster icon.\n * @property {number} [textSize=11] The size (in pixels) of the label text shown on the\n * cluster icon.\n * @property {string} [textDecoration=\"none\"] The value of the CSS text-decoration\n * property for the label text shown on the cluster icon.\n * @property {string} [fontWeight=\"bold\"] The value of the CSS font-weight\n * property for the label text shown on the cluster icon.\n * @property {string} [fontStyle=\"normal\"] The value of the CSS font-style\n * property for the label text shown on the cluster icon.\n * @property {string} [fontFamily=\"Arial,sans-serif\"] The value of the CSS font-family\n * property for the label text shown on the cluster icon.\n * @property {string} [backgroundPosition=\"0 0\"] The position of the cluster icon image\n * within the image defined by url. The format is \"xpos ypos\"\n * (the same format as for the CSS background-position property). You must set\n * this property appropriately when the image defined by url represents a sprite\n * containing multiple images. Note that the position must be specified in px units.\n */\n/**\n * @name ClusterIconInfo\n * @class This class is an object containing general information about a cluster icon. This is\n * the object that a calculator function returns.\n *\n * @property {string} text The text of the label to be shown on the cluster icon.\n * @property {number} index The index plus 1 of the element in the styles\n * array to be used to style the cluster icon.\n * @property {string} title The tooltip to display when the mouse moves over the cluster icon.\n * If this value is undefined or \"\", title is set to the\n * value of the title property passed to the MarkerClusterer.\n */\n/**\n * A cluster icon.\n *\n * @constructor\n * @extends google.maps.OverlayView\n * @param {Cluster} cluster The cluster with which the icon is to be associated.\n * @param {Array} [styles] An array of {@link ClusterIconStyle} defining the cluster icons\n * to use for various cluster sizes.\n * @private\n */\nfunction ClusterIcon(cluster, styles) {\n cluster.getMarkerClusterer().extend(ClusterIcon, google.maps.OverlayView);\n\n this.cluster_ = cluster;\n this.className_ = cluster.getMarkerClusterer().getClusterClass();\n this.styles_ = styles;\n this.center_ = null;\n this.div_ = null;\n this.sums_ = null;\n this.visible_ = false;\n\n this.setMap(cluster.getMap()); // Note: this causes onAdd to be called\n}\n\n\n/**\n * Adds the icon to the DOM.\n */\nClusterIcon.prototype.onAdd = function () {\n var cClusterIcon = this;\n var cMouseDownInCluster;\n var cDraggingMapByCluster;\n\n this.div_ = document.createElement(\"div\");\n this.div_.className = this.className_;\n if (this.visible_) {\n this.show();\n }\n\n this.getPanes().overlayMouseTarget.appendChild(this.div_);\n\n // Fix for Issue 157\n this.boundsChangedListener_ = google.maps.event.addListener(this.getMap(), \"bounds_changed\", function () {\n cDraggingMapByCluster = cMouseDownInCluster;\n });\n\n google.maps.event.addDomListener(this.div_, \"mousedown\", function () {\n cMouseDownInCluster = true;\n cDraggingMapByCluster = false;\n });\n\n google.maps.event.addDomListener(this.div_, \"click\", function (e) {\n cMouseDownInCluster = false;\n if (!cDraggingMapByCluster) {\n var theBounds;\n var mz;\n var mc = cClusterIcon.cluster_.getMarkerClusterer();\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(mc, \"click\", cClusterIcon.cluster_);\n google.maps.event.trigger(mc, \"clusterclick\", cClusterIcon.cluster_); // deprecated name\n\n // The default click handler follows. Disable it by setting\n // the zoomOnClick property to false.\n if (mc.getZoomOnClick()) {\n // Zoom into the cluster.\n mz = mc.getMaxZoom();\n theBounds = cClusterIcon.cluster_.getBounds();\n mc.getMap().fitBounds(theBounds);\n // There is a fix for Issue 170 here:\n setTimeout(function () {\n mc.getMap().fitBounds(theBounds);\n // Don't zoom beyond the max zoom level\n if (mz !== null && (mc.getMap().getZoom() > mz)) {\n mc.getMap().setZoom(mz + 1);\n }\n }, 100);\n }\n\n // Prevent event propagation to the map:\n e.cancelBubble = true;\n if (e.stopPropagation) {\n e.stopPropagation();\n }\n }\n });\n\n google.maps.event.addDomListener(this.div_, \"mouseover\", function () {\n var mc = cClusterIcon.cluster_.getMarkerClusterer();\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(mc, \"mouseover\", cClusterIcon.cluster_);\n });\n\n google.maps.event.addDomListener(this.div_, \"mouseout\", function () {\n var mc = cClusterIcon.cluster_.getMarkerClusterer();\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(mc, \"mouseout\", cClusterIcon.cluster_);\n });\n};\n\n\n/**\n * Removes the icon from the DOM.\n */\nClusterIcon.prototype.onRemove = function () {\n if (this.div_ && this.div_.parentNode) {\n this.hide();\n google.maps.event.removeListener(this.boundsChangedListener_);\n google.maps.event.clearInstanceListeners(this.div_);\n this.div_.parentNode.removeChild(this.div_);\n this.div_ = null;\n }\n};\n\n\n/**\n * Draws the icon.\n */\nClusterIcon.prototype.draw = function () {\n if (this.visible_) {\n var pos = this.getPosFromLatLng_(this.center_);\n this.div_.style.top = pos.y + \"px\";\n this.div_.style.left = pos.x + \"px\";\n }\n};\n\n\n/**\n * Hides the icon.\n */\nClusterIcon.prototype.hide = function () {\n if (this.div_) {\n this.div_.style.display = \"none\";\n }\n this.visible_ = false;\n};\n\n\n/**\n * Positions and shows the icon.\n */\nClusterIcon.prototype.show = function () {\n if (this.div_) {\n var img = \"\";\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_.style.cssText = this.createCss(pos);\n img = \"\";\n this.div_.innerHTML = img + \"

\" + this.sums_.text + \"
\";\n if (typeof this.sums_.title === \"undefined\" || this.sums_.title === \"\") {\n this.div_.title = this.cluster_.getMarkerClusterer().getTitle();\n } else {\n this.div_.title = this.sums_.title;\n }\n this.div_.style.display = \"\";\n }\n this.visible_ = true;\n};\n\n\n/**\n * Sets the icon styles to the appropriate element in the styles array.\n *\n * @param {ClusterIconInfo} sums The icon label text and styles index.\n */\nClusterIcon.prototype.useStyle = function (sums) {\n this.sums_ = sums;\n var index = Math.max(0, sums.index - 1);\n index = Math.min(this.styles_.length - 1, index);\n var style = this.styles_[index];\n this.url_ = style.url;\n this.height_ = style.height;\n this.width_ = style.width;\n this.anchorText_ = style.anchorText || [0, 0];\n this.anchorIcon_ = style.anchorIcon || [parseInt(this.height_ / 2, 10), parseInt(this.width_ / 2, 10)];\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\n\n/**\n * Sets the position at which to center the icon.\n *\n * @param {google.maps.LatLng} center The latlng to set as the center.\n */\nClusterIcon.prototype.setCenter = function (center) {\n this.center_ = center;\n};\n\n\n/**\n * Creates the cssText style parameter based on the position of the icon.\n *\n * @param {google.maps.Point} pos The position of the icon.\n * @return {string} The CSS style text.\n */\nClusterIcon.prototype.createCss = function (pos) {\n var style = [];\n style.push(\"cursor: pointer;\");\n style.push(\"position: absolute; top: \" + pos.y + \"px; left: \" + pos.x + \"px;\");\n style.push(\"width: \" + this.width_ + \"px; height: \" + this.height_ + \"px;\");\n return style.join(\"\");\n};\n\n\n/**\n * Returns the position at which to place the DIV depending on the latlng.\n *\n * @param {google.maps.LatLng} latlng The position in latlng.\n * @return {google.maps.Point} The position in pixels.\n */\nClusterIcon.prototype.getPosFromLatLng_ = function (latlng) {\n var pos = this.getProjection().fromLatLngToDivPixel(latlng);\n pos.x -= this.anchorIcon_[1];\n pos.y -= this.anchorIcon_[0];\n pos.x = parseInt(pos.x, 10);\n pos.y = parseInt(pos.y, 10);\n return pos;\n};\n\n\n/**\n * Creates a single cluster that manages a group of proximate markers.\n * Used internally, do not call this constructor directly.\n * @constructor\n * @param {MarkerClusterer} mc The MarkerClusterer object with which this\n * cluster is associated.\n */\nfunction Cluster(mc) {\n this.markerClusterer_ = mc;\n this.map_ = mc.getMap();\n this.gridSize_ = mc.getGridSize();\n this.minClusterSize_ = mc.getMinimumClusterSize();\n this.averageCenter_ = mc.getAverageCenter();\n this.markers_ = [];\n this.center_ = null;\n this.bounds_ = null;\n this.clusterIcon_ = new ClusterIcon(this, mc.getStyles());\n}\n\n\n/**\n * Returns the number of markers managed by the cluster. You can call this from\n * a click, mouseover, or mouseout event handler\n * for the MarkerClusterer object.\n *\n * @return {number} The number of markers in the cluster.\n */\nCluster.prototype.getSize = function () {\n return this.markers_.length;\n};\n\n\n/**\n * Returns the array of markers managed by the cluster. You can call this from\n * a click, mouseover, or mouseout event handler\n * for the MarkerClusterer object.\n *\n * @return {Array} The array of markers in the cluster.\n */\nCluster.prototype.getMarkers = function () {\n return this.markers_;\n};\n\n\n/**\n * Returns the center of the cluster. You can call this from\n * a click, mouseover, or mouseout event handler\n * for the MarkerClusterer object.\n *\n * @return {google.maps.LatLng} The center of the cluster.\n */\nCluster.prototype.getCenter = function () {\n return this.center_;\n};\n\n\n/**\n * Returns the map with which the cluster is associated.\n *\n * @return {google.maps.Map} The map.\n * @ignore\n */\nCluster.prototype.getMap = function () {\n return this.map_;\n};\n\n\n/**\n * Returns the MarkerClusterer object with which the cluster is associated.\n *\n * @return {MarkerClusterer} The associated marker clusterer.\n * @ignore\n */\nCluster.prototype.getMarkerClusterer = function () {\n return this.markerClusterer_;\n};\n\n\n/**\n * Returns the bounds of the cluster.\n *\n * @return {google.maps.LatLngBounds} the cluster bounds.\n * @ignore\n */\nCluster.prototype.getBounds = function () {\n var i;\n var bounds = new google.maps.LatLngBounds(this.center_, this.center_);\n var markers = this.getMarkers();\n for (i = 0; i < markers.length; i++) {\n bounds.extend(markers[i].getPosition());\n }\n return bounds;\n};\n\n\n/**\n * Removes the cluster from the map.\n *\n * @ignore\n */\nCluster.prototype.remove = function () {\n this.clusterIcon_.setMap(null);\n this.markers_ = [];\n delete this.markers_;\n};\n\n\n/**\n * Adds a marker to the cluster.\n *\n * @param {google.maps.Marker} marker The marker to be added.\n * @return {boolean} True if the marker was added.\n * @ignore\n */\nCluster.prototype.addMarker = function (marker) {\n var i;\n var mCount;\n var mz;\n\n if (this.isMarkerAlreadyAdded_(marker)) {\n return false;\n }\n\n if (!this.center_) {\n this.center_ = marker.getPosition();\n this.calculateBounds_();\n } else {\n if (this.averageCenter_) {\n var l = this.markers_.length + 1;\n var lat = (this.center_.lat() * (l - 1) + marker.getPosition().lat()) / l;\n var lng = (this.center_.lng() * (l - 1) + marker.getPosition().lng()) / l;\n this.center_ = new google.maps.LatLng(lat, lng);\n this.calculateBounds_();\n }\n }\n\n marker.isAdded = true;\n this.markers_.push(marker);\n\n mCount = this.markers_.length;\n mz = this.markerClusterer_.getMaxZoom();\n if (mz !== null && this.map_.getZoom() > mz) {\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 (i = 0; i < mCount; i++) {\n this.markers_[i].setMap(null);\n }\n } else {\n marker.setMap(null);\n }\n\n this.updateIcon_();\n return true;\n};\n\n\n/**\n * Determines if a marker lies within the cluster's bounds.\n *\n * @param {google.maps.Marker} marker The marker to check.\n * @return {boolean} True if the marker lies in the bounds.\n * @ignore\n */\nCluster.prototype.isMarkerInClusterBounds = function (marker) {\n return this.bounds_.contains(marker.getPosition());\n};\n\n\n/**\n * Calculates the extended bounds of the cluster with the grid.\n */\nCluster.prototype.calculateBounds_ = function () {\n var bounds = new google.maps.LatLngBounds(this.center_, this.center_);\n this.bounds_ = this.markerClusterer_.getExtendedBounds(bounds);\n};\n\n\n/**\n * Updates the cluster icon.\n */\nCluster.prototype.updateIcon_ = function () {\n var mCount = this.markers_.length;\n var mz = this.markerClusterer_.getMaxZoom();\n\n if (mz !== null && this.map_.getZoom() > mz) {\n this.clusterIcon_.hide();\n return;\n }\n\n if (mCount < this.minClusterSize_) {\n // Min cluster size not yet reached.\n this.clusterIcon_.hide();\n return;\n }\n\n var numStyles = this.markerClusterer_.getStyles().length;\n var sums = this.markerClusterer_.getCalculator()(this.markers_, numStyles);\n this.clusterIcon_.setCenter(this.center_);\n this.clusterIcon_.useStyle(sums);\n this.clusterIcon_.show();\n};\n\n\n/**\n * Determines if a marker has already been added to the cluster.\n *\n * @param {google.maps.Marker} marker The marker to check.\n * @return {boolean} True if the marker has already been added.\n */\nCluster.prototype.isMarkerAlreadyAdded_ = function (marker) {\n var i;\n if (this.markers_.indexOf) {\n return this.markers_.indexOf(marker) !== -1;\n } else {\n for (i = 0; i < this.markers_.length; i++) {\n if (marker === this.markers_[i]) {\n return true;\n }\n }\n }\n return false;\n};\n\n\n/**\n * @name MarkerClustererOptions\n * @class This class represents the optional parameter passed to\n * the {@link MarkerClusterer} constructor.\n * @property {number} [gridSize=60] The grid size of a cluster in pixels. The grid is a square.\n * @property {number} [maxZoom=null] The maximum zoom level at which clustering is enabled or\n * null if clustering is to be enabled at all zoom levels.\n * @property {boolean} [zoomOnClick=true] Whether to zoom the map when a cluster marker is\n * clicked. You may want to set this to false if you have installed a handler\n * for the click event and it deals with zooming on its own.\n * @property {boolean} [averageCenter=false] Whether the position of a cluster marker should be\n * the average position of all markers in the cluster. If set to false, the\n * cluster marker is positioned at the location of the first marker added to the cluster.\n * @property {number} [minimumClusterSize=2] The minimum number of markers needed in a cluster\n * before the markers are hidden and a cluster marker appears.\n * @property {boolean} [ignoreHidden=false] Whether to ignore hidden markers in clusters. You\n * may want to set this to true to ensure that hidden markers are not included\n * in the marker count that appears on a cluster marker (this count is the value of the\n * text property of the result returned by the default calculator).\n * If set to true and you change the visibility of a marker being clustered, be\n * sure to also call MarkerClusterer.repaint().\n * @property {string} [title=\"\"] The tooltip to display when the mouse moves over a cluster\n * marker. (Alternatively, you can use a custom calculator function to specify a\n * different tooltip for each cluster marker.)\n * @property {function} [calculator=MarkerClusterer.CALCULATOR] The function used to determine\n * the text to be displayed on a cluster marker and the index indicating which style to use\n * for the cluster marker. The input parameters for the function are (1) the array of markers\n * represented by a cluster marker and (2) the number of cluster icon styles. It returns a\n * {@link ClusterIconInfo} object. The default calculator returns a\n * text property which is the number of markers in the cluster and an\n * index property which is one higher than the lowest integer such that\n * 10^i exceeds the number of markers in the cluster, or the size of the styles\n * array, whichever is less. The styles array element used has an index of\n * index minus 1. For example, the default calculator returns a\n * text value of \"125\" and an index of 3\n * for a cluster icon representing 125 markers so the element used in the styles\n * array is 2. A calculator may also return a title\n * property that contains the text of the tooltip to be used for the cluster marker. If\n * title is not defined, the tooltip is set to the value of the title\n * property for the MarkerClusterer.\n * @property {string} [clusterClass=\"cluster\"] The name of the CSS class defining general styles\n * for the cluster markers. Use this class to define CSS styles that are not set up by the code\n * that processes the styles array.\n * @property {Array} [styles] An array of {@link ClusterIconStyle} elements defining the styles\n * of the cluster markers to be used. The element to be used to style a given cluster marker\n * is determined by the function defined by the calculator property.\n * The default is an array of {@link ClusterIconStyle} elements whose properties are derived\n * from the values for imagePath, imageExtension, and\n * imageSizes.\n * @property {boolean} [enableRetinaIcons=false] Whether to allow the use of cluster icons that\n * have sizes that are some multiple (typically double) of their actual display size. Icons such\n * as these look better when viewed on high-resolution monitors such as Apple's Retina displays.\n * Note: if this property is true, sprites cannot be used as cluster icons.\n * @property {number} [batchSize=MarkerClusterer.BATCH_SIZE] Set this property to the\n * number of markers to be processed in a single batch when using a browser other than\n * Internet Explorer (for Internet Explorer, use the batchSizeIE property instead).\n * @property {number} [batchSizeIE=MarkerClusterer.BATCH_SIZE_IE] When Internet Explorer is\n * being used, markers are processed in several batches with a small delay inserted between\n * each batch in an attempt to avoid Javascript timeout errors. Set this property to the\n * number of markers to be processed in a single batch; select as high a number as you can\n * without causing a timeout error in the browser. This number might need to be as low as 100\n * if 15,000 markers are being managed, for example.\n * @property {string} [imagePath=MarkerClusterer.IMAGE_PATH]\n * The full URL of the root name of the group of image files to use for cluster icons.\n * The complete file name is of the form imagePathn.imageExtension\n * where n is the image file number (1, 2, etc.).\n * @property {string} [imageExtension=MarkerClusterer.IMAGE_EXTENSION]\n * The extension name for the cluster icon image files (e.g., \"png\" or\n * \"jpg\").\n * @property {Array} [imageSizes=MarkerClusterer.IMAGE_SIZES]\n * An array of numbers containing the widths of the group of\n * imagePathn.imageExtension image files.\n * (The images are assumed to be square.)\n */\n/**\n * Creates a MarkerClusterer object with the options specified in {@link MarkerClustererOptions}.\n * @constructor\n * @extends google.maps.OverlayView\n * @param {google.maps.Map} map The Google map to attach to.\n * @param {Array.} [opt_markers] The markers to be added to the cluster.\n * @param {MarkerClustererOptions} [opt_options] The optional parameters.\n */\nfunction MarkerClusterer(map, opt_markers, opt_options) {\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 this.extend(MarkerClusterer, google.maps.OverlayView);\n\n opt_markers = opt_markers || [];\n opt_options = opt_options || {};\n\n this.markers_ = [];\n this.clusters_ = [];\n this.listeners_ = [];\n this.activeMap_ = null;\n this.ready_ = false;\n\n this.gridSize_ = opt_options.gridSize || 60;\n this.minClusterSize_ = opt_options.minimumClusterSize || 2;\n this.maxZoom_ = opt_options.maxZoom || null;\n this.styles_ = opt_options.styles || [];\n this.title_ = opt_options.title || \"\";\n this.zoomOnClick_ = true;\n if (opt_options.zoomOnClick !== undefined) {\n this.zoomOnClick_ = opt_options.zoomOnClick;\n }\n this.averageCenter_ = false;\n if (opt_options.averageCenter !== undefined) {\n this.averageCenter_ = opt_options.averageCenter;\n }\n this.ignoreHidden_ = false;\n if (opt_options.ignoreHidden !== undefined) {\n this.ignoreHidden_ = opt_options.ignoreHidden;\n }\n this.enableRetinaIcons_ = false;\n if (opt_options.enableRetinaIcons !== undefined) {\n this.enableRetinaIcons_ = opt_options.enableRetinaIcons;\n }\n this.imagePath_ = opt_options.imagePath || MarkerClusterer.IMAGE_PATH;\n this.imageExtension_ = opt_options.imageExtension || MarkerClusterer.IMAGE_EXTENSION;\n this.imageSizes_ = opt_options.imageSizes || MarkerClusterer.IMAGE_SIZES;\n this.calculator_ = opt_options.calculator || MarkerClusterer.CALCULATOR;\n this.batchSize_ = opt_options.batchSize || MarkerClusterer.BATCH_SIZE;\n this.batchSizeIE_ = opt_options.batchSizeIE || MarkerClusterer.BATCH_SIZE_IE;\n this.clusterClass_ = opt_options.clusterClass || \"cluster\";\n\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\n this.setupStyles_();\n\n this.addMarkers(opt_markers, true);\n this.setMap(map); // Note: this causes onAdd to be called\n}\n\n\n/**\n * Implementation of the onAdd interface method.\n * @ignore\n */\nMarkerClusterer.prototype.onAdd = function () {\n var cMarkerClusterer = this;\n\n this.activeMap_ = this.getMap();\n this.ready_ = true;\n\n this.repaint();\n\n // Add the map event listeners\n this.listeners_ = [\n google.maps.event.addListener(this.getMap(), \"zoom_changed\", function () {\n cMarkerClusterer.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 (this.getZoom() === (this.get(\"minZoom\") || 0) || this.getZoom() === this.get(\"maxZoom\")) {\n google.maps.event.trigger(this, \"idle\");\n }\n }),\n google.maps.event.addListener(this.getMap(), \"idle\", function () {\n cMarkerClusterer.redraw_();\n })\n ];\n};\n\n\n/**\n * Implementation of the onRemove interface method.\n * Removes map event listeners and all cluster icons from the DOM.\n * All managed markers are also put back on the map.\n * @ignore\n */\nMarkerClusterer.prototype.onRemove = function () {\n var i;\n\n // Put all the managed markers back on the map:\n for (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\n // Remove all clusters:\n for (i = 0; i < this.clusters_.length; i++) {\n this.clusters_[i].remove();\n }\n this.clusters_ = [];\n\n // Remove map event listeners:\n for (i = 0; i < this.listeners_.length; i++) {\n google.maps.event.removeListener(this.listeners_[i]);\n }\n this.listeners_ = [];\n\n this.activeMap_ = null;\n this.ready_ = false;\n};\n\n\n/**\n * Implementation of the draw interface method.\n * @ignore\n */\nMarkerClusterer.prototype.draw = function () {};\n\n\n/**\n * Sets up the styles object.\n */\nMarkerClusterer.prototype.setupStyles_ = function () {\n var i, size;\n if (this.styles_.length > 0) {\n return;\n }\n\n for (i = 0; i < this.imageSizes_.length; i++) {\n size = this.imageSizes_[i];\n this.styles_.push({\n url: this.imagePath_ + (i + 1) + \".\" + this.imageExtension_,\n height: size,\n width: size\n });\n }\n};\n\n\n/**\n * Fits the map to the bounds of the markers managed by the clusterer.\n */\nMarkerClusterer.prototype.fitMapToMarkers = function () {\n var i;\n var markers = this.getMarkers();\n var bounds = new google.maps.LatLngBounds();\n for (i = 0; i < markers.length; i++) {\n bounds.extend(markers[i].getPosition());\n }\n\n this.getMap().fitBounds(bounds);\n};\n\n\n/**\n * Returns the value of the gridSize property.\n *\n * @return {number} The grid size.\n */\nMarkerClusterer.prototype.getGridSize = function () {\n return this.gridSize_;\n};\n\n\n/**\n * Sets the value of the gridSize property.\n *\n * @param {number} gridSize The grid size.\n */\nMarkerClusterer.prototype.setGridSize = function (gridSize) {\n this.gridSize_ = gridSize;\n};\n\n\n/**\n * Returns the value of the minimumClusterSize property.\n *\n * @return {number} The minimum cluster size.\n */\nMarkerClusterer.prototype.getMinimumClusterSize = function () {\n return this.minClusterSize_;\n};\n\n/**\n * Sets the value of the minimumClusterSize property.\n *\n * @param {number} minimumClusterSize The minimum cluster size.\n */\nMarkerClusterer.prototype.setMinimumClusterSize = function (minimumClusterSize) {\n this.minClusterSize_ = minimumClusterSize;\n};\n\n\n/**\n * Returns the value of the maxZoom property.\n *\n * @return {number} The maximum zoom level.\n */\nMarkerClusterer.prototype.getMaxZoom = function () {\n return this.maxZoom_;\n};\n\n\n/**\n * Sets the value of the maxZoom property.\n *\n * @param {number} maxZoom The maximum zoom level.\n */\nMarkerClusterer.prototype.setMaxZoom = function (maxZoom) {\n this.maxZoom_ = maxZoom;\n};\n\n\n/**\n * Returns the value of the styles property.\n *\n * @return {Array} The array of styles defining the cluster markers to be used.\n */\nMarkerClusterer.prototype.getStyles = function () {\n return this.styles_;\n};\n\n\n/**\n * Sets the value of the styles property.\n *\n * @param {Array.} styles The array of styles to use.\n */\nMarkerClusterer.prototype.setStyles = function (styles) {\n this.styles_ = styles;\n};\n\n\n/**\n * Returns the value of the title property.\n *\n * @return {string} The content of the title text.\n */\nMarkerClusterer.prototype.getTitle = function () {\n return this.title_;\n};\n\n\n/**\n * Sets the value of the title property.\n *\n * @param {string} title The value of the title property.\n */\nMarkerClusterer.prototype.setTitle = function (title) {\n this.title_ = title;\n};\n\n\n/**\n * Returns the value of the zoomOnClick property.\n *\n * @return {boolean} True if zoomOnClick property is set.\n */\nMarkerClusterer.prototype.getZoomOnClick = function () {\n return this.zoomOnClick_;\n};\n\n\n/**\n * Sets the value of the zoomOnClick property.\n *\n * @param {boolean} zoomOnClick The value of the zoomOnClick property.\n */\nMarkerClusterer.prototype.setZoomOnClick = function (zoomOnClick) {\n this.zoomOnClick_ = zoomOnClick;\n};\n\n\n/**\n * Returns the value of the averageCenter property.\n *\n * @return {boolean} True if averageCenter property is set.\n */\nMarkerClusterer.prototype.getAverageCenter = function () {\n return this.averageCenter_;\n};\n\n\n/**\n * Sets the value of the averageCenter property.\n *\n * @param {boolean} averageCenter The value of the averageCenter property.\n */\nMarkerClusterer.prototype.setAverageCenter = function (averageCenter) {\n this.averageCenter_ = averageCenter;\n};\n\n\n/**\n * Returns the value of the ignoreHidden property.\n *\n * @return {boolean} True if ignoreHidden property is set.\n */\nMarkerClusterer.prototype.getIgnoreHidden = function () {\n return this.ignoreHidden_;\n};\n\n\n/**\n * Sets the value of the ignoreHidden property.\n *\n * @param {boolean} ignoreHidden The value of the ignoreHidden property.\n */\nMarkerClusterer.prototype.setIgnoreHidden = function (ignoreHidden) {\n this.ignoreHidden_ = ignoreHidden;\n};\n\n\n/**\n * Returns the value of the enableRetinaIcons property.\n *\n * @return {boolean} True if enableRetinaIcons property is set.\n */\nMarkerClusterer.prototype.getEnableRetinaIcons = function () {\n return this.enableRetinaIcons_;\n};\n\n\n/**\n * Sets the value of the enableRetinaIcons property.\n *\n * @param {boolean} enableRetinaIcons The value of the enableRetinaIcons property.\n */\nMarkerClusterer.prototype.setEnableRetinaIcons = function (enableRetinaIcons) {\n this.enableRetinaIcons_ = enableRetinaIcons;\n};\n\n\n/**\n * Returns the value of the imageExtension property.\n *\n * @return {string} The value of the imageExtension property.\n */\nMarkerClusterer.prototype.getImageExtension = function () {\n return this.imageExtension_;\n};\n\n\n/**\n * Sets the value of the imageExtension property.\n *\n * @param {string} imageExtension The value of the imageExtension property.\n */\nMarkerClusterer.prototype.setImageExtension = function (imageExtension) {\n this.imageExtension_ = imageExtension;\n};\n\n\n/**\n * Returns the value of the imagePath property.\n *\n * @return {string} The value of the imagePath property.\n */\nMarkerClusterer.prototype.getImagePath = function () {\n return this.imagePath_;\n};\n\n\n/**\n * Sets the value of the imagePath property.\n *\n * @param {string} imagePath The value of the imagePath property.\n */\nMarkerClusterer.prototype.setImagePath = function (imagePath) {\n this.imagePath_ = imagePath;\n};\n\n\n/**\n * Returns the value of the imageSizes property.\n *\n * @return {Array} The value of the imageSizes property.\n */\nMarkerClusterer.prototype.getImageSizes = function () {\n return this.imageSizes_;\n};\n\n\n/**\n * Sets the value of the imageSizes property.\n *\n * @param {Array} imageSizes The value of the imageSizes property.\n */\nMarkerClusterer.prototype.setImageSizes = function (imageSizes) {\n this.imageSizes_ = imageSizes;\n};\n\n\n/**\n * Returns the value of the calculator property.\n *\n * @return {function} the value of the calculator property.\n */\nMarkerClusterer.prototype.getCalculator = function () {\n return this.calculator_;\n};\n\n\n/**\n * Sets the value of the calculator property.\n *\n * @param {function(Array., number)} calculator The value\n * of the calculator property.\n */\nMarkerClusterer.prototype.setCalculator = function (calculator) {\n this.calculator_ = calculator;\n};\n\n\n/**\n * Returns the value of the batchSizeIE property.\n *\n * @return {number} the value of the batchSizeIE property.\n */\nMarkerClusterer.prototype.getBatchSizeIE = function () {\n return this.batchSizeIE_;\n};\n\n\n/**\n * Sets the value of the batchSizeIE property.\n *\n * @param {number} batchSizeIE The value of the batchSizeIE property.\n */\nMarkerClusterer.prototype.setBatchSizeIE = function (batchSizeIE) {\n this.batchSizeIE_ = batchSizeIE;\n};\n\n\n/**\n * Returns the value of the clusterClass property.\n *\n * @return {string} the value of the clusterClass property.\n */\nMarkerClusterer.prototype.getClusterClass = function () {\n return this.clusterClass_;\n};\n\n\n/**\n * Sets the value of the clusterClass property.\n *\n * @param {string} clusterClass The value of the clusterClass property.\n */\nMarkerClusterer.prototype.setClusterClass = function (clusterClass) {\n this.clusterClass_ = clusterClass;\n};\n\n\n/**\n * Returns the array of markers managed by the clusterer.\n *\n * @return {Array} The array of markers managed by the clusterer.\n */\nMarkerClusterer.prototype.getMarkers = function () {\n return this.markers_;\n};\n\n\n/**\n * Returns the number of markers managed by the clusterer.\n *\n * @return {number} The number of markers.\n */\nMarkerClusterer.prototype.getTotalMarkers = function () {\n return this.markers_.length;\n};\n\n\n/**\n * Returns the current array of clusters formed by the clusterer.\n *\n * @return {Array} The array of clusters formed by the clusterer.\n */\nMarkerClusterer.prototype.getClusters = function () {\n return this.clusters_;\n};\n\n\n/**\n * Returns the number of clusters formed by the clusterer.\n *\n * @return {number} The number of clusters formed by the clusterer.\n */\nMarkerClusterer.prototype.getTotalClusters = function () {\n return this.clusters_.length;\n};\n\n\n/**\n * Adds a marker to the clusterer. The clusters are redrawn unless\n * opt_nodraw is set to true.\n *\n * @param {google.maps.Marker} marker The marker to add.\n * @param {boolean} [opt_nodraw] Set to true to prevent redrawing.\n */\nMarkerClusterer.prototype.addMarker = function (marker, opt_nodraw) {\n this.pushMarkerTo_(marker);\n if (!opt_nodraw) {\n this.redraw_();\n }\n};\n\n\n/**\n * Adds an array of markers to the clusterer. The clusters are redrawn unless\n * opt_nodraw is set to true.\n *\n * @param {Array.} markers The markers to add.\n * @param {boolean} [opt_nodraw] Set to true to prevent redrawing.\n */\nMarkerClusterer.prototype.addMarkers = function (markers, opt_nodraw) {\n var key;\n for (key in markers) {\n if (markers.hasOwnProperty(key)) {\n this.pushMarkerTo_(markers[key]);\n }\n } \n if (!opt_nodraw) {\n this.redraw_();\n }\n};\n\n\n/**\n * Pushes a marker to the clusterer.\n *\n * @param {google.maps.Marker} marker The marker to add.\n */\nMarkerClusterer.prototype.pushMarkerTo_ = function (marker) {\n // If the marker is draggable add a listener so we can update the clusters on the dragend:\n if (marker.getDraggable()) {\n var cMarkerClusterer = this;\n google.maps.event.addListener(marker, \"dragend\", function () {\n if (cMarkerClusterer.ready_) {\n this.isAdded = false;\n cMarkerClusterer.repaint();\n }\n });\n }\n marker.isAdded = false;\n this.markers_.push(marker);\n};\n\n\n/**\n * Removes a marker from the cluster. The clusters are redrawn unless\n * opt_nodraw is set to true. Returns true if the\n * marker was removed from the clusterer.\n *\n * @param {google.maps.Marker} marker The marker to remove.\n * @param {boolean} [opt_nodraw] Set to true to prevent redrawing.\n * @return {boolean} True if the marker was removed from the clusterer.\n */\nMarkerClusterer.prototype.removeMarker = function (marker, opt_nodraw) {\n var removed = this.removeMarker_(marker);\n\n if (!opt_nodraw && removed) {\n this.repaint();\n }\n\n return removed;\n};\n\n\n/**\n * Removes an array of markers from the cluster. The clusters are redrawn unless\n * opt_nodraw is set to true. Returns true if markers\n * were removed from the clusterer.\n *\n * @param {Array.} markers The markers to remove.\n * @param {boolean} [opt_nodraw] Set to true to prevent redrawing.\n * @return {boolean} True if markers were removed from the clusterer.\n */\nMarkerClusterer.prototype.removeMarkers = function (markers, opt_nodraw) {\n var i, r;\n var removed = false;\n\n for (i = 0; i < markers.length; i++) {\n r = this.removeMarker_(markers[i]);\n removed = removed || r;\n }\n\n if (!opt_nodraw && removed) {\n this.repaint();\n }\n\n return removed;\n};\n\n\n/**\n * Removes a marker and returns true if removed, false if not.\n *\n * @param {google.maps.Marker} marker The marker to remove\n * @return {boolean} Whether the marker was removed or not\n */\nMarkerClusterer.prototype.removeMarker_ = function (marker) {\n var i;\n var index = -1;\n if (this.markers_.indexOf) {\n index = this.markers_.indexOf(marker);\n } else {\n for (i = 0; i < this.markers_.length; i++) {\n if (marker === this.markers_[i]) {\n index = i;\n break;\n }\n }\n }\n\n if (index === -1) {\n // Marker is not in our list of markers, so do nothing:\n return false;\n }\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\n\n/**\n * Removes all clusters and markers from the map and also removes all markers\n * managed by the clusterer.\n */\nMarkerClusterer.prototype.clearMarkers = function () {\n this.resetViewport_(true);\n this.markers_ = [];\n};\n\n\n/**\n * Recalculates and redraws all the marker clusters from scratch.\n * Call this after changing any properties.\n */\nMarkerClusterer.prototype.repaint = function () {\n var oldClusters = this.clusters_.slice();\n this.clusters_ = [];\n this.resetViewport_(false);\n this.redraw_();\n\n // Remove the old clusters.\n // Do it in a timeout to prevent blinking effect.\n setTimeout(function () {\n var i;\n for (i = 0; i < oldClusters.length; i++) {\n oldClusters[i].remove();\n }\n }, 0);\n};\n\n\n/**\n * Returns the current bounds extended by the grid size.\n *\n * @param {google.maps.LatLngBounds} bounds The bounds to extend.\n * @return {google.maps.LatLngBounds} The extended bounds.\n * @ignore\n */\nMarkerClusterer.prototype.getExtendedBounds = function (bounds) {\n var projection = this.getProjection();\n\n // Turn the bounds into latlng.\n var tr = new google.maps.LatLng(bounds.getNorthEast().lat(),\n bounds.getNorthEast().lng());\n var bl = new google.maps.LatLng(bounds.getSouthWest().lat(),\n bounds.getSouthWest().lng());\n\n // Convert the points to pixels and the extend out by the grid size.\n var trPix = projection.fromLatLngToDivPixel(tr);\n trPix.x += this.gridSize_;\n trPix.y -= this.gridSize_;\n\n var blPix = projection.fromLatLngToDivPixel(bl);\n blPix.x -= this.gridSize_;\n blPix.y += this.gridSize_;\n\n // Convert the pixel points back to LatLng\n var ne = projection.fromDivPixelToLatLng(trPix);\n var sw = projection.fromDivPixelToLatLng(blPix);\n\n // Extend the bounds to contain the new bounds.\n bounds.extend(ne);\n bounds.extend(sw);\n\n return bounds;\n};\n\n\n/**\n * Redraws all the clusters.\n */\nMarkerClusterer.prototype.redraw_ = function () {\n this.createClusters_(0);\n};\n\n\n/**\n * Removes all clusters from the map. The markers are also removed from the map\n * if opt_hide is set to true.\n *\n * @param {boolean} [opt_hide] Set to true to also remove the markers\n * from the map.\n */\nMarkerClusterer.prototype.resetViewport_ = function (opt_hide) {\n var i, marker;\n // Remove all the clusters\n for (i = 0; i < this.clusters_.length; i++) {\n this.clusters_[i].remove();\n }\n this.clusters_ = [];\n\n // Reset the markers to not be added and to be removed from the map.\n for (i = 0; i < this.markers_.length; i++) {\n marker = this.markers_[i];\n marker.isAdded = false;\n if (opt_hide) {\n marker.setMap(null);\n }\n }\n};\n\n\n/**\n * Calculates the distance between two latlng locations in km.\n *\n * @param {google.maps.LatLng} p1 The first lat lng point.\n * @param {google.maps.LatLng} p2 The second lat lng point.\n * @return {number} The distance between the two points in km.\n * @see http://www.movable-type.co.uk/scripts/latlong.html\n*/\nMarkerClusterer.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) +\n Math.cos(p1.lat() * Math.PI / 180) * Math.cos(p2.lat() * Math.PI / 180) *\n Math.sin(dLon / 2) * Math.sin(dLon / 2);\n var c = 2 * Math.atan2(Math.sqrt(a), Math.sqrt(1 - a));\n var d = R * c;\n return d;\n};\n\n\n/**\n * Determines if a marker is contained in a bounds.\n *\n * @param {google.maps.Marker} marker The marker to check.\n * @param {google.maps.LatLngBounds} bounds The bounds to check against.\n * @return {boolean} True if the marker is in the bounds.\n */\nMarkerClusterer.prototype.isMarkerInBounds_ = function (marker, bounds) {\n return bounds.contains(marker.getPosition());\n};\n\n\n/**\n * Adds a marker to a cluster, or creates a new cluster.\n *\n * @param {google.maps.Marker} marker The marker to add.\n */\nMarkerClusterer.prototype.addToClosestCluster_ = function (marker) {\n var i, d, cluster, center;\n var distance = 40000; // Some large number\n var clusterToAddTo = null;\n for (i = 0; i < this.clusters_.length; i++) {\n cluster = this.clusters_[i];\n center = cluster.getCenter();\n if (center) {\n d = this.distanceBetweenPoints_(center, marker.getPosition());\n if (d < distance) {\n distance = d;\n clusterToAddTo = cluster;\n }\n }\n }\n\n if (clusterToAddTo && clusterToAddTo.isMarkerInClusterBounds(marker)) {\n clusterToAddTo.addMarker(marker);\n } else {\n cluster = new Cluster(this);\n cluster.addMarker(marker);\n this.clusters_.push(cluster);\n }\n};\n\n\n/**\n * Creates the clusters. This is done in batches to avoid timeout errors\n * in some browsers when there is a huge number of markers.\n *\n * @param {number} iFirst The index of the first marker in the batch of\n * markers to be added to clusters.\n */\nMarkerClusterer.prototype.createClusters_ = function (iFirst) {\n var i, marker;\n var mapBounds;\n var cMarkerClusterer = this;\n if (!this.ready_) {\n return;\n }\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 MarkerClusterer begins\n * clustering markers.\n * @name MarkerClusterer#clusteringbegin\n * @param {MarkerClusterer} mc The MarkerClusterer whose markers are being clustered.\n * @event\n */\n google.maps.event.trigger(this, \"clusteringbegin\", this);\n\n if (typeof this.timerRefStatic !== \"undefined\") {\n clearTimeout(this.timerRefStatic);\n delete this.timerRefStatic;\n }\n }\n\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 if (this.getMap().getZoom() > 3) {\n mapBounds = new google.maps.LatLngBounds(this.getMap().getBounds().getSouthWest(),\n this.getMap().getBounds().getNorthEast());\n } else {\n mapBounds = new google.maps.LatLngBounds(new google.maps.LatLng(85.02070771743472, -178.48388434375), new google.maps.LatLng(-85.08136444384544, 178.00048865625));\n }\n var bounds = this.getExtendedBounds(mapBounds);\n\n var iLast = Math.min(iFirst + this.batchSize_, this.markers_.length);\n\n for (i = iFirst; i < iLast; i++) {\n marker = this.markers_[i];\n if (!marker.isAdded && this.isMarkerInBounds_(marker, bounds)) {\n if (!this.ignoreHidden_ || (this.ignoreHidden_ && marker.getVisible())) {\n this.addToClosestCluster_(marker);\n }\n }\n }\n\n if (iLast < this.markers_.length) {\n this.timerRefStatic = setTimeout(function () {\n cMarkerClusterer.createClusters_(iLast);\n }, 0);\n } else {\n delete this.timerRefStatic;\n\n /**\n * This event is fired when the MarkerClusterer stops\n * clustering markers.\n * @name MarkerClusterer#clusteringend\n * @param {MarkerClusterer} mc The MarkerClusterer whose markers are being clustered.\n * @event\n */\n google.maps.event.trigger(this, \"clusteringend\", this);\n }\n};\n\n\n/**\n * Extends an object's prototype by another's.\n *\n * @param {Object} obj1 The object to be extended.\n * @param {Object} obj2 The object to extend with.\n * @return {Object} The new extended object.\n * @ignore\n */\nMarkerClusterer.prototype.extend = function (obj1, obj2) {\n return (function (object) {\n var property;\n for (property in object.prototype) {\n this.prototype[property] = object.prototype[property];\n }\n return this;\n }).apply(obj1, [obj2]);\n};\n\n\n/**\n * The default function for determining the label text and style\n * for a cluster icon.\n *\n * @param {Array.} markers The array of markers represented by the cluster.\n * @param {number} numStyles The number of marker styles available.\n * @return {ClusterIconInfo} The information resource for the cluster.\n * @constant\n * @ignore\n */\nMarkerClusterer.CALCULATOR = function (markers, numStyles) {\n var index = 0;\n var title = \"\";\n var count = markers.length.toString();\n\n var dv = count;\n while (dv !== 0) {\n dv = parseInt(dv / 10, 10);\n index++;\n }\n\n index = Math.min(index, numStyles);\n return {\n text: count,\n index: index,\n title: title\n };\n};\n\n\n/**\n * The number of markers to process in one batch.\n *\n * @type {number}\n * @constant\n */\nMarkerClusterer.BATCH_SIZE = 2000;\n\n\n/**\n * The number of markers to process in one batch (IE only).\n *\n * @type {number}\n * @constant\n */\nMarkerClusterer.BATCH_SIZE_IE = 500;\n\n\n/**\n * The default root name for the marker cluster images.\n *\n * @type {string}\n * @constant\n */\nMarkerClusterer.IMAGE_PATH = \"https://raw.githubusercontent.com/googlemaps/v3-utility-library/master/markerclustererplus/images/m\";\n\n\n/**\n * The default extension name for the marker cluster images.\n *\n * @type {string}\n * @constant\n */\nMarkerClusterer.IMAGE_EXTENSION = \"png\";\n\n\n/**\n * The default array of sizes for the marker cluster images.\n *\n * @type {Array.}\n * @constant\n */\nMarkerClusterer.IMAGE_SIZES = [53, 56, 66, 78, 90];\n\nmodule.exports = MarkerClusterer\n"],"sourceRoot":""}