@syncfusion/ej2-maps 25.1.37 → 25.1.40
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.eslintrc.json +260 -0
- package/CHANGELOG.md +9 -0
- package/dist/ej2-maps.min.js +2 -2
- package/dist/ej2-maps.umd.min.js +2 -2
- package/dist/ej2-maps.umd.min.js.map +1 -1
- package/dist/es6/ej2-maps.es2015.js +620 -396
- package/dist/es6/ej2-maps.es2015.js.map +1 -1
- package/dist/es6/ej2-maps.es5.js +601 -378
- package/dist/es6/ej2-maps.es5.js.map +1 -1
- package/dist/global/ej2-maps.min.js +2 -2
- package/dist/global/ej2-maps.min.js.map +1 -1
- package/dist/global/index.d.ts +1 -1
- package/package.json +7 -7
- package/src/maps/layers/bubble.d.ts +17 -2
- package/src/maps/layers/bubble.js +20 -5
- package/src/maps/layers/color-mapping.d.ts +1 -1
- package/src/maps/layers/color-mapping.js +4 -0
- package/src/maps/layers/data-label.d.ts +2 -2
- package/src/maps/layers/data-label.js +4 -6
- package/src/maps/layers/layer-panel.d.ts +9 -7
- package/src/maps/layers/layer-panel.js +124 -121
- package/src/maps/layers/legend.d.ts +7 -6
- package/src/maps/layers/legend.js +41 -24
- package/src/maps/layers/marker.d.ts +7 -2
- package/src/maps/layers/marker.js +14 -10
- package/src/maps/layers/navigation-selected-line.js +1 -0
- package/src/maps/layers/polygon.js +5 -1
- package/src/maps/maps-model.d.ts +9 -9
- package/src/maps/maps.d.ts +30 -12
- package/src/maps/maps.js +88 -59
- package/src/maps/model/base-model.d.ts +3 -2
- package/src/maps/model/base.d.ts +10 -9
- package/src/maps/model/base.js +1 -1
- package/src/maps/model/export-image.js +1 -1
- package/src/maps/model/export-pdf.js +3 -3
- package/src/maps/model/interface.d.ts +1 -0
- package/src/maps/model/print.js +2 -0
- package/src/maps/model/theme.js +12 -12
- package/src/maps/user-interaction/annotation.d.ts +5 -0
- package/src/maps/user-interaction/annotation.js +6 -2
- package/src/maps/user-interaction/highlight.d.ts +13 -1
- package/src/maps/user-interaction/highlight.js +12 -2
- package/src/maps/user-interaction/selection.d.ts +13 -1
- package/src/maps/user-interaction/selection.js +19 -13
- package/src/maps/user-interaction/tooltip.d.ts +14 -0
- package/src/maps/user-interaction/tooltip.js +16 -1
- package/src/maps/user-interaction/zoom.d.ts +55 -10
- package/src/maps/user-interaction/zoom.js +146 -104
- package/src/maps/utils/helper.d.ts +64 -36
- package/src/maps/utils/helper.js +82 -52
- package/tslint.json +111 -0
package/dist/global/index.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* filename: index.d.ts
|
|
3
|
-
* version : 25.1.
|
|
3
|
+
* version : 25.1.40
|
|
4
4
|
* Copyright Syncfusion Inc. 2001 - 2023. All rights reserved.
|
|
5
5
|
* Use of this code is subject to the terms of our license.
|
|
6
6
|
* A copy of the current license can be obtained at any time by e-mailing
|
package/package.json
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
{
|
|
2
2
|
"_from": "@syncfusion/ej2-maps@*",
|
|
3
|
-
"_id": "@syncfusion/ej2-maps@25.1.
|
|
3
|
+
"_id": "@syncfusion/ej2-maps@25.1.37",
|
|
4
4
|
"_inBundle": false,
|
|
5
|
-
"_integrity": "sha512-
|
|
5
|
+
"_integrity": "sha512-CWC04KDnHjmE6WI+jSrzsAM4JRyaZ++anTsS4BMOwpaFVRHg09afWT0/K9G7YXarS8LN7JW39jmD3p0NHJTUSA==",
|
|
6
6
|
"_location": "/@syncfusion/ej2-maps",
|
|
7
7
|
"_phantomChildren": {},
|
|
8
8
|
"_requested": {
|
|
@@ -23,8 +23,8 @@
|
|
|
23
23
|
"/@syncfusion/ej2-react-maps",
|
|
24
24
|
"/@syncfusion/ej2-vue-maps"
|
|
25
25
|
],
|
|
26
|
-
"_resolved": "https://nexus.syncfusioninternal.com/repository/ej2-hotfix-new/@syncfusion/ej2-maps/-/ej2-maps-25.1.
|
|
27
|
-
"_shasum": "
|
|
26
|
+
"_resolved": "https://nexus.syncfusioninternal.com/repository/ej2-hotfix-new/@syncfusion/ej2-maps/-/ej2-maps-25.1.37.tgz",
|
|
27
|
+
"_shasum": "4c429228b5fcee8b1e66f931c7d6802f702b1a28",
|
|
28
28
|
"_spec": "@syncfusion/ej2-maps@*",
|
|
29
29
|
"_where": "/jenkins/workspace/elease-automation_release_25.1.1/packages/included",
|
|
30
30
|
"author": {
|
|
@@ -36,11 +36,11 @@
|
|
|
36
36
|
"bundleDependencies": false,
|
|
37
37
|
"dependencies": {
|
|
38
38
|
"@syncfusion/ej2-base": "~25.1.35",
|
|
39
|
-
"@syncfusion/ej2-buttons": "~25.1.
|
|
39
|
+
"@syncfusion/ej2-buttons": "~25.1.39",
|
|
40
40
|
"@syncfusion/ej2-compression": "~25.1.35",
|
|
41
41
|
"@syncfusion/ej2-data": "~25.1.35",
|
|
42
42
|
"@syncfusion/ej2-file-utils": "~25.1.35",
|
|
43
|
-
"@syncfusion/ej2-pdf-export": "~25.1.
|
|
43
|
+
"@syncfusion/ej2-pdf-export": "~25.1.38",
|
|
44
44
|
"@syncfusion/ej2-svg-base": "~25.1.37"
|
|
45
45
|
},
|
|
46
46
|
"deprecated": false,
|
|
@@ -93,6 +93,6 @@
|
|
|
93
93
|
"url": "git+https://github.com/syncfusion/ej2-javascript-ui-controls.git"
|
|
94
94
|
},
|
|
95
95
|
"typings": "index.d.ts",
|
|
96
|
-
"version": "25.1.
|
|
96
|
+
"version": "25.1.40",
|
|
97
97
|
"sideEffects": false
|
|
98
98
|
}
|
|
@@ -7,9 +7,10 @@ import { LayerSettings } from '../index';
|
|
|
7
7
|
export declare class Bubble {
|
|
8
8
|
private maps;
|
|
9
9
|
/** @private */
|
|
10
|
-
bubbleCollection:
|
|
10
|
+
bubbleCollection: object[];
|
|
11
11
|
/**
|
|
12
12
|
* Bubble Id for current layer
|
|
13
|
+
*
|
|
13
14
|
* @private
|
|
14
15
|
*/
|
|
15
16
|
id: string;
|
|
@@ -17,9 +18,23 @@ export declare class Bubble {
|
|
|
17
18
|
/**
|
|
18
19
|
* To render bubble
|
|
19
20
|
*
|
|
21
|
+
* @param {BubbleSettingsModel} bubbleSettings - Specifies the bubble data to be rendered
|
|
22
|
+
* @param {object} shapeData - Specifies the data about the shape
|
|
23
|
+
* @param {string} color - Specifies the color of the bubble
|
|
24
|
+
* @param {number} range - Specifies the range of the bubble
|
|
25
|
+
* @param {number} range.min - Specifies the minimum range of the bubble
|
|
26
|
+
* @param {number} range.max - Specifies the maximum range of the bubble
|
|
27
|
+
* @param {number} bubbleIndex - Specifies the index of the bubble
|
|
28
|
+
* @param {number} dataIndex - Specifies the index of the data
|
|
29
|
+
* @param {number} layerIndex - Specifies the index of the layer
|
|
30
|
+
* @param {LayerSettings} layer - Specifies the layer data
|
|
31
|
+
* @param {Element} group - Specifies the element group
|
|
32
|
+
* @param {string} bubbleID - Specifies the ID of the bubble
|
|
33
|
+
* @returns {void}
|
|
34
|
+
*
|
|
20
35
|
* @private
|
|
21
36
|
*/
|
|
22
|
-
renderBubble(bubbleSettings: BubbleSettingsModel, shapeData:
|
|
37
|
+
renderBubble(bubbleSettings: BubbleSettingsModel, shapeData: object, color: string, range: {
|
|
23
38
|
min: number;
|
|
24
39
|
max: number;
|
|
25
40
|
}, bubbleIndex: number, dataIndex: number, layerIndex: number, layer: LayerSettings, group: Element, bubbleID?: string): void;
|
|
@@ -10,21 +10,33 @@ var Bubble = /** @class */ (function () {
|
|
|
10
10
|
function Bubble(maps) {
|
|
11
11
|
/**
|
|
12
12
|
* Bubble Id for current layer
|
|
13
|
+
*
|
|
13
14
|
* @private
|
|
14
15
|
*/
|
|
15
16
|
this.id = '';
|
|
16
17
|
this.maps = maps;
|
|
17
18
|
this.bubbleCollection = [];
|
|
18
19
|
}
|
|
19
|
-
// eslint-disable-next-line valid-jsdoc
|
|
20
20
|
/**
|
|
21
21
|
* To render bubble
|
|
22
22
|
*
|
|
23
|
+
* @param {BubbleSettingsModel} bubbleSettings - Specifies the bubble data to be rendered
|
|
24
|
+
* @param {object} shapeData - Specifies the data about the shape
|
|
25
|
+
* @param {string} color - Specifies the color of the bubble
|
|
26
|
+
* @param {number} range - Specifies the range of the bubble
|
|
27
|
+
* @param {number} range.min - Specifies the minimum range of the bubble
|
|
28
|
+
* @param {number} range.max - Specifies the maximum range of the bubble
|
|
29
|
+
* @param {number} bubbleIndex - Specifies the index of the bubble
|
|
30
|
+
* @param {number} dataIndex - Specifies the index of the data
|
|
31
|
+
* @param {number} layerIndex - Specifies the index of the layer
|
|
32
|
+
* @param {LayerSettings} layer - Specifies the layer data
|
|
33
|
+
* @param {Element} group - Specifies the element group
|
|
34
|
+
* @param {string} bubbleID - Specifies the ID of the bubble
|
|
35
|
+
* @returns {void}
|
|
36
|
+
*
|
|
23
37
|
* @private
|
|
24
38
|
*/
|
|
25
|
-
Bubble.prototype.renderBubble = function (
|
|
26
|
-
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
27
|
-
bubbleSettings, shapeData, color, range, bubbleIndex, dataIndex, layerIndex, layer, group, bubbleID) {
|
|
39
|
+
Bubble.prototype.renderBubble = function (bubbleSettings, shapeData, color, range, bubbleIndex, dataIndex, layerIndex, layer, group, bubbleID) {
|
|
28
40
|
var _this = this;
|
|
29
41
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
30
42
|
var layerData = layer.layerData;
|
|
@@ -124,6 +136,7 @@ var Bubble = /** @class */ (function () {
|
|
|
124
136
|
return;
|
|
125
137
|
}
|
|
126
138
|
}
|
|
139
|
+
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
127
140
|
this.maps.trigger('bubbleRendering', eventArgs, function (bubbleArgs) {
|
|
128
141
|
if (eventArgs.cancel) {
|
|
129
142
|
return;
|
|
@@ -162,7 +175,9 @@ var Bubble = /** @class */ (function () {
|
|
|
162
175
|
var bubbleDataSource = bubbleSettings.dataSource;
|
|
163
176
|
var scale = translate['scale'];
|
|
164
177
|
var transPoint = translate['location'];
|
|
165
|
-
var position = new MapLocation((_this.maps.isTileMap ? ((eventArgs.cx + _this.maps.translatePoint.x) * _this.maps.tileZoomLevel)
|
|
178
|
+
var position = new MapLocation((_this.maps.isTileMap ? ((eventArgs.cx + _this.maps.translatePoint.x) * _this.maps.tileZoomLevel)
|
|
179
|
+
: ((eventArgs.cx + transPoint.x) * scale)), (_this.maps.isTileMap ? ((eventArgs.cy + _this.maps.translatePoint.y) * _this.maps.tileZoomLevel)
|
|
180
|
+
: ((eventArgs.cy + transPoint.y) * scale)));
|
|
166
181
|
bubbleElement.setAttribute('transform', 'translate( ' + (position.x) + ' ' + (position.y) + ' )');
|
|
167
182
|
var bubble = (bubbleDataSource.length - 1) === dataIndex ? 'bubble' : null;
|
|
168
183
|
if (bubbleSettings.bubbleType === 'Square') {
|
|
@@ -14,7 +14,7 @@ export declare class ColorMapping {
|
|
|
14
14
|
* @returns {Object} - Returns the object.
|
|
15
15
|
* @private
|
|
16
16
|
*/
|
|
17
|
-
getShapeColorMapping(shapeSettings: ShapeSettingsModel, layerData:
|
|
17
|
+
getShapeColorMapping(shapeSettings: ShapeSettingsModel, layerData: object, color: string): any;
|
|
18
18
|
/**
|
|
19
19
|
* To color by value and color mapping
|
|
20
20
|
*
|
|
@@ -5,8 +5,12 @@ import { getValueFromObject } from '../utils/helper';
|
|
|
5
5
|
* ColorMapping class
|
|
6
6
|
*/
|
|
7
7
|
var ColorMapping = /** @class */ (function () {
|
|
8
|
+
/* eslint-disable @typescript-eslint/no-unused-vars */
|
|
9
|
+
/* eslint-disable @typescript-eslint/no-empty-function */
|
|
8
10
|
function ColorMapping(maps) {
|
|
9
11
|
}
|
|
12
|
+
/* eslint-enable @typescript-eslint/no-unused-vars */
|
|
13
|
+
/* eslint-enable @typescript-eslint/no-empty-function */
|
|
10
14
|
/**
|
|
11
15
|
* To get color based on shape settings.
|
|
12
16
|
*
|
|
@@ -19,7 +19,7 @@ export declare class DataLabel {
|
|
|
19
19
|
*
|
|
20
20
|
* @param {LayerSettings} layer - Specifies the layer settings
|
|
21
21
|
* @param {number} layerIndex - Specifies the layer index.
|
|
22
|
-
* @param {
|
|
22
|
+
* @param {object} shape - Specifies the shape.
|
|
23
23
|
* @param {any[]} layerData - Specifies the layer data.
|
|
24
24
|
* @param {Element} group Specifies the element.
|
|
25
25
|
* @param {HTMLElement} labelTemplateElement - Specifies the template element.
|
|
@@ -28,7 +28,7 @@ export declare class DataLabel {
|
|
|
28
28
|
* @returns {void}
|
|
29
29
|
* @private
|
|
30
30
|
*/
|
|
31
|
-
renderLabel(layer: LayerSettings, layerIndex: number, shape:
|
|
31
|
+
renderLabel(layer: LayerSettings, layerIndex: number, shape: object, layerData: any[], group: Element, labelTemplateElement: HTMLElement, index: number, intersect: any[]): void;
|
|
32
32
|
private datalabelAnimate;
|
|
33
33
|
private getPoint;
|
|
34
34
|
/**
|
|
@@ -36,7 +36,7 @@ var DataLabel = /** @class */ (function () {
|
|
|
36
36
|
*
|
|
37
37
|
* @param {LayerSettings} layer - Specifies the layer settings
|
|
38
38
|
* @param {number} layerIndex - Specifies the layer index.
|
|
39
|
-
* @param {
|
|
39
|
+
* @param {object} shape - Specifies the shape.
|
|
40
40
|
* @param {any[]} layerData - Specifies the layer data.
|
|
41
41
|
* @param {Element} group Specifies the element.
|
|
42
42
|
* @param {HTMLElement} labelTemplateElement - Specifies the template element.
|
|
@@ -45,9 +45,7 @@ var DataLabel = /** @class */ (function () {
|
|
|
45
45
|
* @returns {void}
|
|
46
46
|
* @private
|
|
47
47
|
*/
|
|
48
|
-
DataLabel.prototype.renderLabel = function (
|
|
49
|
-
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
50
|
-
layer, layerIndex, shape,
|
|
48
|
+
DataLabel.prototype.renderLabel = function (layer, layerIndex, shape,
|
|
51
49
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
52
50
|
layerData, group, labelTemplateElement, index, intersect) {
|
|
53
51
|
var _this = this;
|
|
@@ -250,7 +248,7 @@ var DataLabel = /** @class */ (function () {
|
|
|
250
248
|
var templateElement = templateFn ? templateFn(!isNullOrUndefined(datasrcObj) ?
|
|
251
249
|
datasrcObj : shapeData['properties'], _this.maps, eventargs_1.template, _this.maps.element.id + '_LabelTemplate', false) : document.createElement('div');
|
|
252
250
|
templateElement.innerHTML = !templateFn ? eventargs_1.template : '';
|
|
253
|
-
labelElement = convertElementFromLabel(templateElement, labelId, !isNullOrUndefined(datasrcObj) ? datasrcObj : shapeData['properties']
|
|
251
|
+
labelElement = convertElementFromLabel(templateElement, labelId, !isNullOrUndefined(datasrcObj) ? datasrcObj : shapeData['properties']);
|
|
254
252
|
if (_this.maps.isTileMap) {
|
|
255
253
|
labelElement.style.left = (((location['x'] + transPoint['x']) * scale) - (textSize['width'] / 2)) + 'px';
|
|
256
254
|
labelElement.style.top = (((location['y'] + transPoint['y']) * scale) - textSize['height']) + 'px';
|
|
@@ -404,7 +402,7 @@ var DataLabel = /** @class */ (function () {
|
|
|
404
402
|
element.setAttribute(isRect ? 'fill-opacity' : 'opacity', (opacity * height).toString());
|
|
405
403
|
}
|
|
406
404
|
},
|
|
407
|
-
end: function (
|
|
405
|
+
end: function () {
|
|
408
406
|
element.style.visibility = 'visible';
|
|
409
407
|
element.setAttribute(isRect ? 'fill-opacity' : 'opacity', opacity.toString());
|
|
410
408
|
}
|
|
@@ -49,7 +49,6 @@ export declare class LayerPanel {
|
|
|
49
49
|
* @param {Element} pathEle - Specifies the svg element.
|
|
50
50
|
* @param {string} drawingType - Specifies the data type.
|
|
51
51
|
* @param {any} currentShapeData - Specifies the layer of shapedata.
|
|
52
|
-
* @param {number} index - Specifies the tab index.
|
|
53
52
|
* @returns {void}
|
|
54
53
|
*/
|
|
55
54
|
private pathAttributeCalculate;
|
|
@@ -58,7 +57,7 @@ export declare class LayerPanel {
|
|
|
58
57
|
*
|
|
59
58
|
* @param {number} layerIndex - Specifies the layer index
|
|
60
59
|
* @param {string[]} colors - Specifies the colors
|
|
61
|
-
* @param {
|
|
60
|
+
* @param {any[]} renderData - Specifies the render data
|
|
62
61
|
* @param {HTMLElement} labelTemplateEle - Specifies the label template element
|
|
63
62
|
* @returns {void}
|
|
64
63
|
*/
|
|
@@ -90,6 +89,8 @@ export declare class LayerPanel {
|
|
|
90
89
|
* @param {object} bubbleData - Specifies the bubble data
|
|
91
90
|
* @param {string} color - Specifies the color
|
|
92
91
|
* @param {number} range - Specifies the range
|
|
92
|
+
* @param {number} range.min - Specifies the minimum range
|
|
93
|
+
* @param {number} range.max - Specifies the maximum range
|
|
93
94
|
* @param {number} bubbleIndex - Specifies the bubble index
|
|
94
95
|
* @param {number} dataIndex - Specifies the data index
|
|
95
96
|
* @param {number} group - Specifies the group
|
|
@@ -102,20 +103,21 @@ export declare class LayerPanel {
|
|
|
102
103
|
* To get the shape color from color mapping module
|
|
103
104
|
*
|
|
104
105
|
* @param {LayerSettingsModel} layer - Specifies the layer
|
|
105
|
-
* @param {
|
|
106
|
+
* @param {any} shape - Specifies the shape
|
|
106
107
|
* @param {string} color - Specifies the color
|
|
107
|
-
* @returns {
|
|
108
|
+
* @returns {any} - Returns the object
|
|
108
109
|
*/
|
|
109
110
|
private getShapeColorMapping;
|
|
110
|
-
generatePoints(type: string, coordinates: any[], data:
|
|
111
|
+
generatePoints(type: string, coordinates: any[], data: object, properties: object): void;
|
|
111
112
|
calculateBox(point: Point, extraSpace: number): void;
|
|
112
113
|
calculateFactor(layer: LayerSettings): number;
|
|
113
|
-
translateLayerElements(layerElement: Element
|
|
114
|
+
translateLayerElements(layerElement: Element): void;
|
|
114
115
|
calculateRectBounds(layerData: any[]): void;
|
|
115
|
-
calculatePolygonBox(coordinates: any[]
|
|
116
|
+
calculatePolygonBox(coordinates: any[]): any;
|
|
116
117
|
calculateRectBox(coordinates: any[], type?: string, isFirstItem?: boolean): void;
|
|
117
118
|
generateTiles(zoomLevel: number, tileTranslatePoint: Point, zoomType?: string, bing?: BingMap, position?: Point): void;
|
|
118
119
|
arrangeTiles(type: string, x: number, y: number): void;
|
|
120
|
+
private arrangeTilesLayer;
|
|
119
121
|
/**
|
|
120
122
|
* Animation for tile layers and hide the group element until the tile layer rendering
|
|
121
123
|
*
|