Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@types/markerclustererplus

Package Overview
Dependencies
Maintainers
1
Versions
16
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@types/markerclustererplus - npm Package Compare versions

Comparing version 2.1.30 to 2.1.31

753

markerclustererplus/index.d.ts

@@ -1,5 +0,7 @@

// Type definitions for MarkerClustererPlus for Google Maps V3 2.1.1
// Type definitions for MarkerClustererPlus for Google Maps V3 2.1
// Project: https://github.com/mahnunchik/markerclustererplus
// Definitions by: Mathias Rodriguez <https://github.com/enanox>
// Michael Ledin <https://github.com/mxl>
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
// TypeScript Version: 2.2

@@ -13,3 +15,3 @@ /// <reference types="google-maps" />

*/
declare interface ClusterIconStyle {
interface ClusterIconStyle {
/** The URL of the cluster icon image file. Required. */

@@ -81,104 +83,106 @@ url: string;

*/
interface ClusterIconInfo {
text: string;
index: number;
title: string;
}
declare class ClusterIconInfo extends google.maps.OverlayView {
text: string;
index: number;
title: string;
/**
* A cluster icon.
*
* @constructor
* @extends google.maps.OverlayView
* @param {Cluster} cluster The cluster with which the icon is to be associated.
* @param {Array} [styles] An array of {@link ClusterIconStyle} defining the cluster icons
* to use for various cluster sizes.
* @private
*/
constructor(cluster: Cluster, styles: ClusterIconStyle[]);
declare class ClusterIcon extends google.maps.OverlayView {
/**
* A cluster icon.
*
* @constructor
* @extends google.maps.OverlayView
* @param {Cluster} cluster The cluster with which the icon is to be associated.
* @param {Array} [styles] An array of {@link ClusterIconStyle} defining the cluster icons
* to use for various cluster sizes.
* @private
*/
constructor(cluster: Cluster, styles: ClusterIconStyle[]);
/**
* Adds the icon to the DOM.
*/
onAdd(): void;
/**
* Adds the icon to the DOM.
*/
onAdd(): void;
/**
* Removes the icon from the DOM.
*/
onRemove(): void;
/**
* Removes the icon from the DOM.
*/
onRemove(): void;
/**
* Draws the icon.
*/
draw(): void;
/**
* Draws the icon.
*/
draw(): void;
/**
* Hides the icon.
*/
hide(): void;
/**
* Hides the icon.
*/
hide(): void;
/**
* Positions and shows the icon.
*/
show(): void;
/**
* Positions and shows the icon.
*/
show(): void;
/**
* Sets the icon styles to the appropriate element in the styles array.
*
* @param {ClusterIconInfo} sums The icon label text and styles index.
*/
useStyle(sums: ClusterIconInfo[]): void;
/**
* Sets the icon styles to the appropriate element in the styles array.
*
* @param {ClusterIconInfo} style The icon label text and styles index.
*/
useStyle(style: ClusterIconInfo): void;
/**
* Sets the position at which to center the icon.
*
* @param {google.maps.LatLng} center The latlng to set as the center.
*/
setCenter(center: google.maps.LatLng): void;
/**
* Sets the position at which to center the icon.
*
* @param {google.maps.LatLng} center The latlng to set as the center.
*/
setCenter(center: google.maps.LatLng): void;
/**
* Creates the cssText style parameter based on the position of the icon.
*
* @param {google.maps.Point} pos The position of the icon.
* @return {string} The CSS style text.
*/
createCss(pos: google.maps.Point): string;
/**
* Creates the cssText style parameter based on the position of the icon.
*
* @param {google.maps.Point} pos The position of the icon.
* @return {string} The CSS style text.
*/
createCss(pos: google.maps.Point): string;
/**
* Returns the position at which to place the DIV depending on the latlng.
*
* @param {google.maps.LatLng} latlng The position in latlng.
* @return {google.maps.Point} The position in pixels.
*/
getPosFromLatLng_(latLng: google.maps.LatLng): google.maps.Point;
/**
* Returns the position at which to place the DIV depending on the latlng.
*
* @param {google.maps.LatLng} latLng The position in latlng.
* @return {google.maps.Point} The position in pixels.
*/
getPosFromLatLng_(latLng: google.maps.LatLng): google.maps.Point;
}
interface Cluster {
/**
* Creates a single cluster that manages a group of proximate markers.
* Used internally, do not call this constructor directly.
* @constructor
* @param {MarkerClusterer} mc The <code>MarkerClusterer</code> object with which this
* cluster is associated.
*/
new (mc: MarkerClusterer): Cluster;
declare class Cluster {
/**
* Creates a single cluster that manages a group of proximate markers.
* Used internally, do not call this constructor directly.
* @constructor
* @param {MarkerClusterer} mc The <code>MarkerClusterer</code> object with which this
* cluster is associated.
*/
constructor(mc: MarkerClusterer);
/**
* Returns the number of markers managed by the cluster. You can call this from
* a <code>click</code>, <code>mouseover</code>, or <code>mouseout</code> event handler
* for the <code>MarkerClusterer</code> object.
*
* @return {number} The number of markers in the cluster.
*/
getSize(): number;
/**
* Returns the number of markers managed by the cluster. You can call this from
* a <code>click</code>, <code>mouseover</code>, or <code>mouseout</code> event handler
* for the <code>MarkerClusterer</code> object.
*
* @return {number} The number of markers in the cluster.
*/
getSize(): number;
/**
* Returns the array of markers managed by the cluster. You can call this from
* a <code>click</code>, <code>mouseover</code>, or <code>mouseout</code> event handler
* for the <code>MarkerClusterer</code> object.
*
* @return {Array} The array of markers in the cluster.
*/
getMarkers(): google.maps.Marker[];
/**
* Returns the array of markers managed by the cluster. You can call this from
* a <code>click</code>, <code>mouseover</code>, or <code>mouseout</code> event handler
* for the <code>MarkerClusterer</code> object.
*
* @return {Array} The array of markers in the cluster.
*/
getMarkers(): google.maps.Marker[];
/**
/**
* Returns the center of the cluster. You can call this from

@@ -190,5 +194,5 @@ * a <code>click</code>, <code>mouseover</code>, or <code>mouseout</code> event handler

*/
getCenter(): google.maps.LatLng;
getCenter(): google.maps.LatLng;
/**
/**
* Returns the map with which the cluster is associated.

@@ -199,5 +203,5 @@ *

*/
getMap(): google.maps.Map;
getMap(): google.maps.Map;
/**
/**
* Returns the <code>MarkerClusterer</code> object with which the cluster is associated.

@@ -208,5 +212,5 @@ *

*/
getMarkerClusterer(): MarkerClusterer;
getMarkerClusterer(): MarkerClusterer;
/**
/**
* Returns the bounds of the cluster.

@@ -217,5 +221,5 @@ *

*/
getBounds(): google.maps.LatLngBounds;
getBounds(): google.maps.LatLngBounds;
/**
/**
* Removes the cluster from the map.

@@ -225,5 +229,5 @@ *

*/
remove(): void;
remove(): void;
/**
/**
* Adds a marker to the cluster.

@@ -235,5 +239,5 @@ *

*/
addMarker(marker: google.maps.Marker): boolean;
addMarker(marker: google.maps.Marker): boolean;
/**
/**
* Determines if a marker lies within the cluster's bounds.

@@ -245,15 +249,15 @@ *

*/
isMarkerInClusterBounds(marker: google.maps.Marker): boolean;
isMarkerInClusterBounds(marker: google.maps.Marker): boolean;
/**
/**
* Calculates the extended bounds of the cluster with the grid.
*/
calculateBounds_(): void;
calculateBounds_(): void;
/**
/**
* Updates the cluster icon.
*/
updateIcon_(): void;
updateIcon_(): void;
/**
/**
* Determines if a marker has already been added to the cluster.

@@ -264,3 +268,3 @@ *

*/
isMarkerAlreadyAdded_(marker: google.maps.Marker): boolean;
isMarkerAlreadyAdded_(marker: google.maps.Marker): boolean;
}

@@ -274,120 +278,120 @@

interface MarkerClustererOptions {
/** [gridSize=60] The grid size of a cluster in pixels. The grid is a square. */
gridSize?: number;
/** [maxZoom=null] The maximum zoom level at which clustering is enabled or
* <code>null</code> if clustering is to be enabled at all zoom levels.
*/
maxZoom?: number;
/**
* [zoomOnClick=true] Whether to zoom the map when a cluster marker is
* clicked. You may want to set this to <code>false</code> if you have installed a handler
* for the <code>click</code> event and it deals with zooming on its own.
*/
zoomOnClick?: boolean;
/**
* [averageCenter=false] Whether the position of a cluster marker should be
* the average position of all markers in the cluster. If set to <code>false</code>, the
* cluster marker is positioned at the location of the first marker added to the cluster.
*/
averageCenter?: boolean;
/**
* [minimumClusterSize=2] The minimum number of markers needed in a cluster
* before the markers are hidden and a cluster marker appears.
*/
minimumClusterSize?: number;
/**
* [ignoreHidden=false] Whether to ignore hidden markers in clusters. You
* may want to set this to <code>true</code> to ensure that hidden markers are not included
* in the marker count that appears on a cluster marker (this count is the value of the
* <code>text</code> property of the result returned by the default <code>calculator</code>).
* If set to <code>true</code> and you change the visibility of a marker being clustered, be
* sure to also call <code>MarkerClusterer.repaint()</code>.
*/
ignoreHidden?: boolean;
/**
* [title=""] The tooltip to display when the mouse moves over a cluster
* marker. (Alternatively, you can use a custom <code>calculator</code> function to specify a
* different tooltip for each cluster marker.)
*/
title?: string;
/**
* [calculator=MarkerClusterer.CALCULATOR] The function used to determine
* the text to be displayed on a cluster marker and the index indicating which style to use
* for the cluster marker. The input parameters for the function are (1) the array of markers
* represented by a cluster marker and (2) the number of cluster icon styles. It returns a
* {@link ClusterIconInfo} object. The default <code>calculator</code> returns a
* <code>text</code> property which is the number of markers in the cluster and an
* <code>index</code> property which is one higher than the lowest integer such that
* <code>10^i</code> exceeds the number of markers in the cluster, or the size of the styles
* array, whichever is less. The <code>styles</code> array element used has an index of
* <code>index</code> minus 1. For example, the default <code>calculator</code> returns a
* <code>text</code> value of <code>"125"</code> and an <code>index</code> of <code>3</code>
* for a cluster icon representing 125 markers so the element used in the <code>styles</code>
* array is <code>2</code>. A <code>calculator</code> may also return a <code>title</code>
* property that contains the text of the tooltip to be used for the cluster marker. If
* <code>title</code> is not defined, the tooltip is set to the value of the <code>title</code>
* property for the MarkerClusterer.
*/
calculator?: Calculator;
/**
* [clusterClass="cluster"] The name of the CSS class defining general styles
* for the cluster markers. Use this class to define CSS styles that are not set up by the code
* that processes the <code>styles</code> array.
*/
clusterClass?: string;
/**
*[styles] An array of {@link ClusterIconStyle} elements defining the styles
* of the cluster markers to be used. The element to be used to style a given cluster marker
* is determined by the function defined by the <code>calculator</code> property.
* The default is an array of {@link ClusterIconStyle} elements whose properties are derived
* from the values for <code>imagePath</code>, <code>imageExtension</code>, and
* <code>imageSizes</code>.
*/
styles?: ClusterIconStyle[];
/**
* [enableRetinaIcons=false] Whether to allow the use of cluster icons that
* have sizes that are some multiple (typically double) of their actual display size. Icons such
* as these look better when viewed on high-resolution monitors such as Apple's Retina displays.
* Note: if this property is <code>true</code>, sprites cannot be used as cluster icons.
*/
enableRetinaIcons?: boolean;
/**
* [batchSize=MarkerClusterer.BATCH_SIZE] Set this property to the
* number of markers to be processed in a single batch when using a browser other than
* Internet Explorer (for Internet Explorer, use the batchSizeIE property instead).
*/
batchSize?: number;
/**
* [batchSizeIE=MarkerClusterer.BATCH_SIZE_IE] When Internet Explorer is
* being used, markers are processed in several batches with a small delay inserted between
* each batch in an attempt to avoid Javascript timeout errors. Set this property to the
* number of markers to be processed in a single batch; select as high a number as you can
* without causing a timeout error in the browser. This number might need to be as low as 100
* if 15,000 markers are being managed, for example.
*/
batchSizeIE?: number;
/**
* [imagePath=MarkerClusterer.IMAGE_PATH]
* The full URL of the root name of the group of image files to use for cluster icons.
* The complete file name is of the form <code>imagePath</code>n.<code>imageExtension</code>
* where n is the image file number (1, 2, etc.).
*/
imagePath?: string;
/**
* [imageExtension=MarkerClusterer.IMAGE_EXTENSION]
* The extension name for the cluster icon image files (e.g., <code>"png"</code> or
* <code>"jpg"</code>).
*/
imageExtension?: string;
/**
* [imageSizes=MarkerClusterer.IMAGE_SIZES]
* An array of numbers containing the widths of the group of
* <code>imagePath</code>n.<code>imageExtension</code> image files.
* (The images are assumed to be square.)
*/
imageSizes?: number[];
/** [gridSize=60] The grid size of a cluster in pixels. The grid is a square. */
gridSize?: number;
/** [maxZoom=null] The maximum zoom level at which clustering is enabled or
* <code>null</code> if clustering is to be enabled at all zoom levels.
*/
maxZoom?: number;
/**
* [zoomOnClick=true] Whether to zoom the map when a cluster marker is
* clicked. You may want to set this to <code>false</code> if you have installed a handler
* for the <code>click</code> event and it deals with zooming on its own.
*/
zoomOnClick?: boolean;
/**
* [averageCenter=false] Whether the position of a cluster marker should be
* the average position of all markers in the cluster. If set to <code>false</code>, the
* cluster marker is positioned at the location of the first marker added to the cluster.
*/
averageCenter?: boolean;
/**
* [minimumClusterSize=2] The minimum number of markers needed in a cluster
* before the markers are hidden and a cluster marker appears.
*/
minimumClusterSize?: number;
/**
* [ignoreHidden=false] Whether to ignore hidden markers in clusters. You
* may want to set this to <code>true</code> to ensure that hidden markers are not included
* in the marker count that appears on a cluster marker (this count is the value of the
* <code>text</code> property of the result returned by the default <code>calculator</code>).
* If set to <code>true</code> and you change the visibility of a marker being clustered, be
* sure to also call <code>MarkerClusterer.repaint()</code>.
*/
ignoreHidden?: boolean;
/**
* [title=""] The tooltip to display when the mouse moves over a cluster
* marker. (Alternatively, you can use a custom <code>calculator</code> function to specify a
* different tooltip for each cluster marker.)
*/
title?: string;
/**
* [calculator=MarkerClusterer.CALCULATOR] The function used to determine
* the text to be displayed on a cluster marker and the index indicating which style to use
* for the cluster marker. The input parameters for the function are (1) the array of markers
* represented by a cluster marker and (2) the number of cluster icon styles. It returns a
* {@link ClusterIconInfo} object. The default <code>calculator</code> returns a
* <code>text</code> property which is the number of markers in the cluster and an
* <code>index</code> property which is one higher than the lowest integer such that
* <code>10^i</code> exceeds the number of markers in the cluster, or the size of the styles
* array, whichever is less. The <code>styles</code> array element used has an index of
* <code>index</code> minus 1. For example, the default <code>calculator</code> returns a
* <code>text</code> value of <code>"125"</code> and an <code>index</code> of <code>3</code>
* for a cluster icon representing 125 markers so the element used in the <code>styles</code>
* array is <code>2</code>. A <code>calculator</code> may also return a <code>title</code>
* property that contains the text of the tooltip to be used for the cluster marker. If
* <code>title</code> is not defined, the tooltip is set to the value of the <code>title</code>
* property for the MarkerClusterer.
*/
calculator?: Calculator;
/**
* [clusterClass="cluster"] The name of the CSS class defining general styles
* for the cluster markers. Use this class to define CSS styles that are not set up by the code
* that processes the <code>styles</code> array.
*/
clusterClass?: string;
/**
* [styles] An array of {@link ClusterIconStyle} elements defining the styles
* of the cluster markers to be used. The element to be used to style a given cluster marker
* is determined by the function defined by the <code>calculator</code> property.
* The default is an array of {@link ClusterIconStyle} elements whose properties are derived
* from the values for <code>imagePath</code>, <code>imageExtension</code>, and
* <code>imageSizes</code>.
*/
styles?: ClusterIconStyle[];
/**
* [enableRetinaIcons=false] Whether to allow the use of cluster icons that
* have sizes that are some multiple (typically double) of their actual display size. Icons such
* as these look better when viewed on high-resolution monitors such as Apple's Retina displays.
* Note: if this property is <code>true</code>, sprites cannot be used as cluster icons.
*/
enableRetinaIcons?: boolean;
/**
* [batchSize=MarkerClusterer.BATCH_SIZE] Set this property to the
* number of markers to be processed in a single batch when using a browser other than
* Internet Explorer (for Internet Explorer, use the batchSizeIE property instead).
*/
batchSize?: number;
/**
* [batchSizeIE=MarkerClusterer.BATCH_SIZE_IE] When Internet Explorer is
* being used, markers are processed in several batches with a small delay inserted between
* each batch in an attempt to avoid Javascript timeout errors. Set this property to the
* number of markers to be processed in a single batch; select as high a number as you can
* without causing a timeout error in the browser. This number might need to be as low as 100
* if 15,000 markers are being managed, for example.
*/
batchSizeIE?: number;
/**
* [imagePath=MarkerClusterer.IMAGE_PATH]
* The full URL of the root name of the group of image files to use for cluster icons.
* The complete file name is of the form <code>imagePath</code>n.<code>imageExtension</code>
* where n is the image file number (1, 2, etc.).
*/
imagePath?: string;
/**
* [imageExtension=MarkerClusterer.IMAGE_EXTENSION]
* The extension name for the cluster icon image files (e.g., <code>"png"</code> or
* <code>"jpg"</code>).
*/
imageExtension?: string;
/**
* [imageSizes=MarkerClusterer.IMAGE_SIZES]
* An array of numbers containing the widths of the group of
* <code>imagePath</code>n.<code>imageExtension</code> image files.
* (The images are assumed to be square.)
*/
imageSizes?: number[];
}
interface MarkerClusterer extends google.maps.OverlayView {
/**
declare class MarkerClusterer extends google.maps.OverlayView {
/**
* Creates a MarkerClusterer object with the options specified in {@link MarkerClustererOptions}.

@@ -397,14 +401,14 @@ * @constructor

* @param {google.maps.Map} map The Google map to attach to.
* @param {Array.<google.maps.Marker>} [opt_markers] The markers to be added to the cluster.
* @param {MarkerClustererOptions} [opt_options] The optional parameters.
* @param {Array.<google.maps.Marker>} [markers] The markers to be added to the cluster.
* @param {MarkerClustererOptions} [options] The optional parameters.
*/
new (map: google.maps.Map, opt_markers: google.maps.Marker[], opt_options?: MarkerClustererOptions): MarkerClusterer;
constructor(map: google.maps.Map, markers?: google.maps.Marker[], options?: MarkerClustererOptions);
/**
/**
* Implementation of the onAdd interface method.
* @ignore
*/
onAdd(): void;
onAdd(): void;
/**
/**
* Implementation of the onRemove interface method.

@@ -415,21 +419,21 @@ * Removes map event listeners and all cluster icons from the DOM.

*/
onRemove(): void;
onRemove(): void;
/**
/**
* Implementation of the draw interface method.
* @ignore
*/
draw(): void;
draw(): void;
/**
/**
* Sets up the styles object.
*/
setupStyles_(): void;
setupStyles_(): void;
/**
/**
* Fits the map to the bounds of the markers managed by the clusterer.
*/
fitMapToMarkers(): void;
fitMapToMarkers(): void;
/**
/**
* Returns the value of the <code>gridSize</code> property.

@@ -439,5 +443,5 @@ *

*/
getGridSize(): number;
getGridSize(): number;
/**
/**
* Sets the value of the <code>gridSize</code> property.

@@ -447,5 +451,5 @@ *

*/
setGridSize(gridSize: number): void;
setGridSize(gridSize: number): void;
/**
/**
* Returns the value of the <code>minimumClusterSize</code> property.

@@ -455,5 +459,5 @@ *

*/
getMinimumClusterSize(): number;
getMinimumClusterSize(): number;
/**
/**
* Sets the value of the <code>minimumClusterSize</code> property.

@@ -463,5 +467,5 @@ *

*/
setMinimumClusterSize(minimumClusterSize: number): void;
setMinimumClusterSize(minimumClusterSize: number): void;
/**
/**
* Returns the value of the <code>maxZoom</code> property.

@@ -471,5 +475,5 @@ *

*/
getMaxZoom(): number;
getMaxZoom(): number;
/**
/**
* Sets the value of the <code>maxZoom</code> property.

@@ -479,5 +483,5 @@ *

*/
setMaxZoom(maxZoom: number): void;
setMaxZoom(maxZoom: number): void;
/**
/**
* Returns the value of the <code>styles</code> property.

@@ -487,5 +491,5 @@ *

*/
getStyles(): ClusterIconStyle[];
getStyles(): ClusterIconStyle[];
/**
/**
* Sets the value of the <code>styles</code> property.

@@ -495,5 +499,5 @@ *

*/
setStyles(styles: ClusterIconStyle[]): void;
setStyles(styles: ClusterIconStyle[]): void;
/**
/**
* Returns the value of the <code>title</code> property.

@@ -503,5 +507,5 @@ *

*/
getTitle(): string;
getTitle(): string;
/**
/**
* Sets the value of the <code>title</code> property.

@@ -511,5 +515,5 @@ *

*/
setTitle(title: string): void;
setTitle(title: string): void;
/**
/**
* Returns the value of the <code>zoomOnClick</code> property.

@@ -519,5 +523,5 @@ *

*/
getZoomOnClick(): boolean;
getZoomOnClick(): boolean;
/**
/**
* Sets the value of the <code>zoomOnClick</code> property.

@@ -527,5 +531,5 @@ *

*/
setZoomOnClick(zoomOnClick: boolean): void;
setZoomOnClick(zoomOnClick: boolean): void;
/**
/**
* Returns the value of the <code>averageCenter</code> property.

@@ -535,5 +539,5 @@ *

*/
getAverageCenter(): boolean;
getAverageCenter(): boolean;
/**
/**
* Sets the value of the <code>averageCenter</code> property.

@@ -543,5 +547,5 @@ *

*/
setAverageCenter(averageCenter: boolean): void;
setAverageCenter(averageCenter: boolean): void;
/**
/**
* Returns the value of the <code>ignoreHidden</code> property.

@@ -551,5 +555,5 @@ *

*/
getIgnoreHidden(): boolean;
getIgnoreHidden(): boolean;
/**
/**
* Sets the value of the <code>ignoreHidden</code> property.

@@ -559,5 +563,5 @@ *

*/
setIgnoreHidden(ignoreHidden: boolean): void;
setIgnoreHidden(ignoreHidden: boolean): void;
/**
/**
* Returns the value of the <code>enableRetinaIcons</code> property.

@@ -567,5 +571,5 @@ *

*/
getEnableRetinaIcons(): boolean;
getEnableRetinaIcons(): boolean;
/**
/**
* Sets the value of the <code>enableRetinaIcons</code> property.

@@ -575,5 +579,5 @@ *

*/
setEnableRetinaIcons(enableRetinaIcons: boolean): void;
setEnableRetinaIcons(enableRetinaIcons: boolean): void;
/**
/**
* Returns the value of the <code>imageExtension</code> property.

@@ -583,5 +587,5 @@ *

*/
getImageExtension(): string;
getImageExtension(): string;
/**
/**
* Sets the value of the <code>imageExtension</code> property.

@@ -591,5 +595,5 @@ *

*/
setImageExtension(imageExtension: string): void;
setImageExtension(imageExtension: string): void;
/**
/**
* Returns the value of the <code>imagePath</code> property.

@@ -599,12 +603,12 @@ *

*/
getImagePath(): string;
getImagePath(): string;
/**
* Sets the value of the <code>imagePath</code> property.
*
* @param {string} imagePath The value of the imagePath property.
*/
setImagePath(imagePath: string): void;
/**
* Sets the value of the <code>imagePath</code> property.
*
* @param {string} imagePath The value of the imagePath property.
*/
setImagePath(imagePath: string): void;
/**
/**
* Returns the value of the <code>imageSizes</code> property.

@@ -614,5 +618,5 @@ *

*/
getImageSizes(): number[];
getImageSizes(): number[];
/**
/**
* Sets the value of the <code>imageSizes</code> property.

@@ -622,5 +626,5 @@ *

*/
setImageSizes(imageSizes: number[]): void;
setImageSizes(imageSizes: number[]): void;
/**
/**
* Returns the value of the <code>calculator</code> property.

@@ -630,5 +634,5 @@ *

*/
getCalculator(): Calculator;
getCalculator(): Calculator;
/**
/**
* Sets the value of the <code>calculator</code> property.

@@ -639,5 +643,5 @@ *

*/
setCalculator(calculator: Calculator): void;
setCalculator(calculator: Calculator): void;
/**
/**
* Sets the value of the <code>hideLabel</code> property.

@@ -647,5 +651,5 @@ *

*/
setHideLabel(printable: boolean): void;
setHideLabel(printable: boolean): void;
/**
/**
* Returns the value of the <code>hideLabel</code> property.

@@ -655,5 +659,5 @@ *

*/
getHideLabel(): boolean;
getHideLabel(): boolean;
/**
/**
* Returns the value of the <code>batchSizeIE</code> property.

@@ -663,5 +667,5 @@ *

*/
getBatchSizeIE(): number;
getBatchSizeIE(): number;
/**
/**
* Sets the value of the <code>batchSizeIE</code> property.

@@ -671,5 +675,5 @@ *

*/
setBatchSizeIE(batchSizeIE: number): void;
setBatchSizeIE(batchSizeIE: number): void;
/**
/**
* Returns the value of the <code>clusterClass</code> property.

@@ -679,5 +683,5 @@ *

*/
getClusterClass(): string;
getClusterClass(): string;
/**
/**
* Sets the value of the <code>clusterClass</code> property.

@@ -687,5 +691,5 @@ *

*/
setClusterClass(clusterClass: string): void;
setClusterClass(clusterClass: string): void;
/**
/**
* Returns the array of markers managed by the clusterer.

@@ -697,3 +701,3 @@ *

/**
/**
* Returns the number of markers managed by the clusterer.

@@ -703,5 +707,5 @@ *

*/
getTotalMarkers(): number;
getTotalMarkers(): number;
/**
/**
* Returns the current array of clusters formed by the clusterer.

@@ -711,5 +715,5 @@ *

*/
getClusters(): Cluster[];
getClusters(): Cluster[];
/**
/**
* Returns the number of clusters formed by the clusterer.

@@ -719,23 +723,23 @@ *

*/
getTotalClusters(): number;
getTotalClusters(): number;
/**
/**
* Adds a marker to the clusterer. The clusters are redrawn unless
* <code>opt_nodraw</code> is set to <code>true</code>.
* <code>noDraw</code> is set to <code>true</code>.
*
* @param {google.maps.Marker} marker The marker to add.
* @param {boolean} [opt_nodraw] Set to <code>true</code> to prevent redrawing.
* @param {boolean} [noDraw] Set to <code>true</code> to prevent redrawing.
*/
addMarker(marker: google.maps.Marker, opt_nodraw: boolean): void;
addMarker(marker: google.maps.Marker, noDraw?: boolean): void;
/**
/**
* Adds an array of markers to the clusterer. The clusters are redrawn unless
* <code>opt_nodraw</code> is set to <code>true</code>.
* <code>noDraw</code> is set to <code>true</code>.
*
* @param {Array.<google.maps.Marker>} markers The markers to add.
* @param {boolean} [opt_nodraw] Set to <code>true</code> to prevent redrawing.
* @param {boolean} [noDraw] Set to <code>true</code> to prevent redrawing.
*/
addMarkers(markers: google.maps.Marker[], opt_nodraw: boolean): void;
addMarkers(markers: google.maps.Marker[], noDraw?: boolean): void;
/**
/**
* Pushes a marker to the clusterer.

@@ -745,29 +749,29 @@ *

*/
pushMarkerTo_(marker: google.maps.Marker): void;
pushMarkerTo_(marker: google.maps.Marker): void;
/**
/**
* Removes a marker from the cluster and map. The clusters are redrawn unless
* <code>opt_nodraw</code> is set to <code>true</code>. Returns <code>true</code> if the
* <code>noDraw</code> is set to <code>true</code>. Returns <code>true</code> if the
* marker was removed from the clusterer.
*
* @param {google.maps.Marker} marker The marker to remove.
* @param {boolean} [opt_nodraw] Set to <code>true</code> to prevent redrawing.
* @param {boolean} [opt_noMapRemove] Set to <code>true</code> to prevent removal from map but still removing from cluster management
* @param {boolean} [noDraw] Set to <code>true</code> to prevent redrawing.
* @param {boolean} [noMapRemove] Set to <code>true</code> to prevent removal from map but still removing from cluster management
* @return {boolean} True if the marker was removed from the clusterer.
*/
removeMarker(marker: google.maps.Marker, opt_nodraw: boolean, noMapRemove: boolean): boolean;
removeMarker(marker: google.maps.Marker, noDraw?: boolean, noMapRemove?: boolean): boolean;
/**
/**
* Removes an array of markers from the cluster and map. The clusters are redrawn unless
* <code>opt_nodraw</code> is set to <code>true</code>. Returns <code>true</code> if markers
* <code>noDraw</code> is set to <code>true</code>. Returns <code>true</code> if markers
* were removed from the clusterer.
*
* @param {Array.<google.maps.Marker>} markers The markers to remove.
* @param {boolean} [opt_nodraw] Set to <code>true</code> to prevent redrawing.
* @param {boolean} [opt_noMapRemove] Set to <code>true</code> to prevent removal from map but still removing from cluster management
* @param {boolean} [noDraw] Set to <code>true</code> to prevent redrawing.
* @param {boolean} [noMapRemove] Set to <code>true</code> to prevent removal from map but still removing from cluster management
* @return {boolean} True if markers were removed from the clusterer.
*/
removeMarkers(markers: google.maps.Marker[], opt_nodraw: boolean, opt_noMapRemove: boolean): boolean;
removeMarkers(markers: google.maps.Marker[], noDraw?: boolean, noMapRemove?: boolean): boolean;
/**
/**
* Removes a marker and returns true if removed, false if not.

@@ -779,17 +783,17 @@ *

*/
removeMarker_(marker: google.maps.Marker, removeFromMap: boolean): boolean;
removeMarker_(marker: google.maps.Marker, removeFromMap?: boolean): boolean;
/**
/**
* Removes all clusters and markers from the map and also removes all markers
* managed by the clusterer.
*/
clearMarkers(): void;
clearMarkers(): void;
/**
/**
* Recalculates and redraws all the marker clusters from scratch.
* Call this after changing any properties.
*/
repaint(): void;
repaint(): void;
/**
/**
* Returns the current bounds extended by the grid size.

@@ -801,19 +805,19 @@ *

*/
getExtendedBounds(bounds: google.maps.LatLngBounds): google.maps.LatLngBounds;
getExtendedBounds(bounds: google.maps.LatLngBounds): google.maps.LatLngBounds;
/**
/**
* Redraws all the clusters.
*/
redraw_(): void;
redraw_(): void;
/**
/**
* Removes all clusters from the map. The markers are also removed from the map
* if <code>opt_hide</code> is set to <code>true</code>.
* if <code>hide</code> is set to <code>true</code>.
*
* @param {boolean} [opt_hide] Set to <code>true</code> to also remove the markers
* @param {boolean} [hide] Set to <code>true</code> to also remove the markers
* from the map.
*/
resetViewport_(opt_hide: boolean): void;
resetViewport_(hide?: boolean): void;
/**
/**
* Calculates the distance between two latlng locations in km.

@@ -825,6 +829,6 @@ *

* @see http://www.movable-type.co.uk/scripts/latlong.html
*/
distanceBetweenPoints_(p1: google.maps.LatLng, p2: google.maps.LatLng): number;
*/
distanceBetweenPoints_(p1: google.maps.LatLng, p2: google.maps.LatLng): number;
/**
/**
* Determines if a marker is contained in a bounds.

@@ -836,5 +840,5 @@ *

*/
isMarkerInBounds_(marker: google.maps.Marker, bounds: google.maps.LatLngBounds): boolean;
isMarkerInBounds_(marker: google.maps.Marker, bounds: google.maps.LatLngBounds): boolean;
/**
/**
* Adds a marker to a cluster, or creates a new cluster.

@@ -844,5 +848,5 @@ *

*/
addToClosestCluster_(marker: google.maps.Marker): void;
addToClosestCluster_(marker: google.maps.Marker): void;
/**
/**
* Creates the clusters. This is done in batches to avoid timeout errors

@@ -854,15 +858,15 @@ * in some browsers when there is a huge number of markers.

*/
createClusters_(iFirst: number): void;
createClusters_(iFirst: number): void;
/**
/**
* Extends an object's prototype by another's.
*
* @param {Object} obj1 The object to be extended.
* @param {Object} obj2 The object to extend with.
* @return {Object} The new extended object.
* @param {object} obj1 The object to be extended.
* @param {object} obj2 The object to extend with.
* @return {object} The new extended object.
* @ignore
*/
extend(obj1: Object, obj2: Object): Object;
extend(obj1: object, obj2: object): object;
/**
/**
* The default function for determining the label text and style

@@ -877,5 +881,5 @@ * for a cluster icon.

*/
CALCULATOR: Calculator;
static CALCULATOR: Calculator;
/**
/**
* The number of markers to process in one batch.

@@ -886,5 +890,5 @@ *

*/
BATCH_SIZE: number;
static BATCH_SIZE: number;
/**
/**
* The number of markers to process in one batch (IE only).

@@ -895,5 +899,5 @@ *

*/
BATCH_SIZE_IE: number;
static BATCH_SIZE_IE: number;
/**
/**
* The default root name for the marker cluster images.

@@ -904,5 +908,5 @@ *

*/
IMAGE_PATH: string;
static IMAGE_PATH: string;
/**
/**
* The default extension name for the marker cluster images.

@@ -913,5 +917,5 @@ *

*/
IMAGE_EXTENSION: string;
static IMAGE_EXTENSION: string;
/**
/**
* The default array of sizes for the marker cluster images.

@@ -922,10 +926,7 @@ *

*/
IMAGE_SIZES: number[];
static IMAGE_SIZES: number[];
}
declare var MarkerClusterer: MarkerClusterer;
interface String {
trim(): string;
trim(): string;
}
{
"name": "@types/markerclustererplus",
"version": "2.1.30",
"version": "2.1.31",
"description": "TypeScript definitions for MarkerClustererPlus for Google Maps V3",

@@ -11,2 +11,7 @@ "license": "MIT",

"githubUsername": "enanox"
},
{
"name": "Michael Ledin",
"url": "https://github.com/mxl",
"githubUsername": "mxl"
}

@@ -23,4 +28,4 @@ ],

},
"typesPublisherContentHash": "50f9f537e799d0b203d4945f47146d7a52e55dbad58a58ca670c5c9cdfdfaed4",
"typeScriptVersion": "2.0"
"typesPublisherContentHash": "84463fc55bd04b88fcd3b294b9dd6260c85985139e241d2c46d9f3e417ee5ca6",
"typeScriptVersion": "2.2"
}

@@ -11,7 +11,7 @@ # Installation

Additional Details
* Last updated: Thu, 05 Oct 2017 18:37:51 GMT
* Last updated: Wed, 11 Oct 2017 23:18:32 GMT
* Dependencies: google-maps
* Global values: ClusterIconInfo, MarkerClusterer
* Global values: Cluster, ClusterIcon, MarkerClusterer
# Credits
These definitions were written by Mathias Rodriguez <https://github.com/enanox>.
These definitions were written by Mathias Rodriguez <https://github.com/enanox>, Michael Ledin <https://github.com/mxl>.
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc