@syncfusion/ej2-maps 19.3.43 → 19.4.38

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.
@@ -1,6 +1,6 @@
1
1
  /*!
2
2
  * filename: index.d.ts
3
- * version : 19.3.43
3
+ * version : 19.4.38
4
4
  * Copyright Syncfusion Inc. 2001 - 2020. 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@16.34.2",
3
+ "_id": "@syncfusion/ej2-maps@16.34.3",
4
4
  "_inBundle": false,
5
- "_integrity": "sha512-8ZHD36Xsb0ZFKFtYhXal6pwX7ylJH0bVUUl4SlUWIIp6EpS+7CDemE8D3QlrqIpYlKusaTZyyv5mzYQeqyPc3g==",
5
+ "_integrity": "sha512-9o+tvn3s5jwKMJdz4hJ07bREhH0HvZvIYHC7pT0z6MT0+fkDn7JW3H/KZdKinOVabqE1K02qzUb4Vrf9q0c3IQ==",
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": "http://nexus.syncfusion.com/repository/ej2-release/@syncfusion/ej2-maps/-/ej2-maps-16.34.2.tgz",
27
- "_shasum": "959cfbb52e5515d0bdcfac7fcddc7955572615c8",
26
+ "_resolved": "http://nexus.syncfusion.com/repository/ej2-release/@syncfusion/ej2-maps/-/ej2-maps-16.34.3.tgz",
27
+ "_shasum": "40e2dd046d32774580816d584a69fe8720b62895",
28
28
  "_spec": "@syncfusion/ej2-maps@*",
29
29
  "_where": "/jenkins/workspace/automation_release_19.1.0.1-ZPMUBNQ6AUYH6YGEFBPVYMEQLRRW2SLD4XCZ6GATNZJFYJ3RIAOA/packages/included",
30
30
  "author": {
@@ -35,13 +35,13 @@
35
35
  },
36
36
  "bundleDependencies": false,
37
37
  "dependencies": {
38
- "@syncfusion/ej2-base": "~19.3.43",
39
- "@syncfusion/ej2-buttons": "~19.3.43",
40
- "@syncfusion/ej2-compression": "~19.3.43",
41
- "@syncfusion/ej2-data": "~19.3.43",
42
- "@syncfusion/ej2-file-utils": "~19.3.43",
43
- "@syncfusion/ej2-pdf-export": "~19.3.43",
44
- "@syncfusion/ej2-svg-base": "~19.3.43"
38
+ "@syncfusion/ej2-base": "~19.4.38",
39
+ "@syncfusion/ej2-buttons": "~19.4.38",
40
+ "@syncfusion/ej2-compression": "~19.4.38",
41
+ "@syncfusion/ej2-data": "~19.4.38",
42
+ "@syncfusion/ej2-file-utils": "~19.4.38",
43
+ "@syncfusion/ej2-pdf-export": "~19.4.38",
44
+ "@syncfusion/ej2-svg-base": "~19.4.38"
45
45
  },
46
46
  "deprecated": false,
47
47
  "description": "The Maps component is used to visualize the geographical data and represent the statistical data of a particular geographical area on earth with user interactivity, and provides various customizing options",
@@ -80,6 +80,6 @@
80
80
  "url": "git+https://github.com/syncfusion/ej2-javascript-ui-controls.git"
81
81
  },
82
82
  "typings": "index.d.ts",
83
- "version": "19.3.43",
83
+ "version": "19.4.38",
84
84
  "sideEffects": false
85
85
  }
@@ -14,6 +14,8 @@ export declare class Bubble {
14
14
  constructor(maps: Maps);
15
15
  /**
16
16
  * To render bubble
17
+ *
18
+ * @private
17
19
  */
18
20
  renderBubble(bubbleSettings: BubbleSettingsModel, shapeData: any, color: string, range: {
19
21
  min: number;
@@ -22,6 +24,8 @@ export declare class Bubble {
22
24
  private getPoints;
23
25
  /**
24
26
  * To check and trigger bubble click event
27
+ *
28
+ * @private
25
29
  */
26
30
  bubbleClick(e: PointerEvent): void;
27
31
  /**
@@ -33,6 +37,8 @@ export declare class Bubble {
33
37
  private getbubble;
34
38
  /**
35
39
  * To check and trigger bubble move event
40
+ *
41
+ * @private
36
42
  */
37
43
  bubbleMove(e: PointerEvent): void;
38
44
  /**
@@ -18,6 +18,8 @@ var Bubble = /** @class */ (function () {
18
18
  // eslint-disable-next-line valid-jsdoc
19
19
  /**
20
20
  * To render bubble
21
+ *
22
+ * @private
21
23
  */
22
24
  Bubble.prototype.renderBubble = function (
23
25
  // eslint-disable-next-line @typescript-eslint/no-explicit-any
@@ -63,7 +65,7 @@ var Bubble = /** @class */ (function () {
63
65
  isNaN(shapeData[layer.shapeDataPath]) ? shapeData[layer.shapeDataPath].toLowerCase() : shapeData[layer.shapeDataPath];
64
66
  var shapePathValue = !isNullOrUndefined(shape[shapePath]) && isNaN(shape[shapePath])
65
67
  ? shape[shapePath].toLowerCase() : shape[shapePath];
66
- if (shapeDataLayerPathValue === shapePathValue) {
68
+ if (shapeDataLayerPathValue === shapePathValue && layerData[i].type !== 'LineString') {
67
69
  if (layerData[i]['type'] === 'Point') {
68
70
  // eslint-disable-next-line @typescript-eslint/no-explicit-any
69
71
  shapePoints.push(this.getPoints(layerData[i], []));
@@ -194,6 +196,8 @@ var Bubble = /** @class */ (function () {
194
196
  // eslint-disable-next-line valid-jsdoc
195
197
  /**
196
198
  * To check and trigger bubble click event
199
+ *
200
+ * @private
197
201
  */
198
202
  Bubble.prototype.bubbleClick = function (e) {
199
203
  var target = e.target.id;
@@ -237,6 +241,8 @@ var Bubble = /** @class */ (function () {
237
241
  // eslint-disable-next-line valid-jsdoc
238
242
  /**
239
243
  * To check and trigger bubble move event
244
+ *
245
+ * @private
240
246
  */
241
247
  Bubble.prototype.bubbleMove = function (e) {
242
248
  var target = e.target.id;
@@ -267,6 +267,7 @@ var DataLabel = /** @class */ (function () {
267
267
  }
268
268
  else {
269
269
  if (dataLabelSettings.smartLabelMode === 'Trim') {
270
+ // eslint-disable-next-line @typescript-eslint/no-explicit-any
270
271
  var textType = typeof text === 'number' ? text.toString() : text;
271
272
  trimmedLable = textTrim(width, textType, style);
272
273
  elementSize = measureText(trimmedLable, style);
@@ -96,11 +96,12 @@ export declare class LayerPanel {
96
96
  */
97
97
  private getShapeColorMapping;
98
98
  generatePoints(type: string, coordinates: any[], data: any, properties: any): void;
99
+ calculateBox(point: Point, extraSpace: number): void;
99
100
  calculateFactor(layer: LayerSettings): number;
100
101
  translateLayerElements(layerElement: Element, index: number): void;
101
102
  calculateRectBounds(layerData: any[]): void;
102
103
  calculatePolygonBox(coordinates: any[], data: any, properties: any): any;
103
- calculateRectBox(coordinates: any[]): void;
104
+ calculateRectBox(coordinates: any[], type?: string, isFirstItem?: boolean): void;
104
105
  generateTiles(zoomLevel: number, tileTranslatePoint: Point, zoomType?: string, bing?: BingMap, position?: Point): void;
105
106
  arrangeTiles(type: string, x: number, y: number): void;
106
107
  /**
@@ -4,7 +4,7 @@
4
4
  /* eslint-disable @typescript-eslint/no-unused-vars */
5
5
  import { isNullOrUndefined, extend, createElement, Ajax } from '@syncfusion/ej2-base';
6
6
  import { getShapeColor } from '../model/theme';
7
- import { GeoLocation, isCustomPath, convertGeoToPoint, Point, PathOption, Size, PolylineOption, removeElement } from '../utils/helper';
7
+ import { GeoLocation, isCustomPath, convertGeoToPoint, Point, PathOption, Size, removeElement } from '../utils/helper';
8
8
  import { getElementByID, maintainSelection, getValueFromObject } from '../utils/helper';
9
9
  import { RectOption, getTranslate, convertTileLatLongToPoint, checkShapeDataFields, CircleOption } from '../utils/helper';
10
10
  import { getZoomTranslate, fixInitialScaleForTile } from '../utils/helper';
@@ -178,7 +178,7 @@ var LayerPanel = /** @class */ (function () {
178
178
  if (this.mapObject.zoomSettings.resetToInitial && this.mapObject.initialCheck && !isNullOrUndefined(panel.mapObject.height)
179
179
  && this.mapObject.availableSize.height > 512) {
180
180
  this.mapObject.applyZoomReset = true;
181
- this.mapObject.initialZoomLevel = Math.floor(this.mapObject.availableSize.height / 512) + 1;
181
+ this.mapObject.initialZoomLevel = Math.floor(this.mapObject.availableSize.height / 512);
182
182
  var padding = this.mapObject.layers[this.mapObject.baseLayerIndex].layerType !== 'GoogleStaticMap' ?
183
183
  20 : 0;
184
184
  var totalSize = Math.pow(2, this.mapObject.initialZoomLevel) * 256;
@@ -260,6 +260,9 @@ var LayerPanel = /** @class */ (function () {
260
260
  proxy_1.mapObject['bingMap'] = bing_1;
261
261
  proxy_1.renderTileLayer(proxy_1, layer, layerIndex, bing_1);
262
262
  _this.mapObject.arrangeTemplate();
263
+ if (_this.mapObject.zoomModule && (_this.mapObject.previousScale !== _this.mapObject.scale)) {
264
+ _this.mapObject.zoomModule.applyTransform(true);
265
+ }
263
266
  };
264
267
  ajax.send();
265
268
  }
@@ -338,9 +341,7 @@ var LayerPanel = /** @class */ (function () {
338
341
  var data = geometryData['geometry'];
339
342
  // eslint-disable-next-line @typescript-eslint/no-explicit-any
340
343
  var properties = geometryData['properties'];
341
- if (type !== 'LineString') {
342
- _this.generatePoints(type, coords, data, properties);
343
- }
344
+ _this.generatePoints(type, coords, data, properties);
344
345
  }
345
346
  });
346
347
  this.currentLayer.rectBounds = this.rectBounds;
@@ -368,7 +369,7 @@ var LayerPanel = /** @class */ (function () {
368
369
  // eslint-disable-next-line @typescript-eslint/no-explicit-any
369
370
  var currentShapeData = this_1.currentLayer.layerData[i];
370
371
  var pathOptions;
371
- var polyLineOptions;
372
+ var polyLineOptions = void 0;
372
373
  var circleOptions;
373
374
  var groupElement;
374
375
  var drawObject = void 0;
@@ -437,7 +438,7 @@ var LayerPanel = /** @class */ (function () {
437
438
  if (isNullOrUndefined(shapeSettings.borderColorValuePath)) {
438
439
  _this.mapObject.layers[layerIndex].shapeSettings.border.color = eventArgs.border.color;
439
440
  }
440
- else if (isNullOrUndefined(shapeSettings.borderWidthValuePath)) {
441
+ if (isNullOrUndefined(shapeSettings.borderWidthValuePath)) {
441
442
  _this.mapObject.layers[layerIndex].shapeSettings.border.width = eventArgs.border.width;
442
443
  }
443
444
  }
@@ -491,17 +492,21 @@ var LayerPanel = /** @class */ (function () {
491
492
  }
492
493
  break;
493
494
  case 'LineString':
495
+ path += 'M ' + (currentShapeData[0]['point']['x']) + ' ' + (currentShapeData[0]['point']['y']);
494
496
  // eslint-disable-next-line @typescript-eslint/no-explicit-any
495
497
  currentShapeData.map(function (lineData) {
496
- points += lineData['point']['x'] + ' , ' + lineData['point']['y'] + ' ';
498
+ path += 'L' + (lineData['point']['x']) + ' , ' + (lineData['point']['y']) + ' ';
497
499
  });
498
- polyLineOptions = new PolylineOption(shapeID, points, eventArgs.fill, eventArgs.border.width, eventArgs.border.color, opacity, eventArgs.border.opacity, shapeSettings.dashArray);
499
- pathEle = _this.mapObject.renderer.drawPolyline(polyLineOptions);
500
+ if (path.length > 3) {
501
+ pathOptions = new PathOption(shapeID, 'transparent', !isNullOrUndefined(eventArgs.border.width) ? eventArgs.border.width : 1, eventArgs.border.color, opacity, eventArgs.border.opacity, shapeSettings.dashArray, path);
502
+ pathEle = _this.mapObject.renderer.drawPath(pathOptions);
503
+ }
500
504
  break;
501
505
  case 'Point':
502
506
  // eslint-disable-next-line @typescript-eslint/no-explicit-any
503
507
  var pointData = currentShapeData['point'];
504
- circleOptions = new CircleOption(shapeID, eventArgs.fill, eventArgs.border, opacity, pointData['x'], pointData['y'], shapeSettings.circleRadius, null);
508
+ var circleRadius = (_this.mapObject.layers[layerIndex].type !== 'SubLayer') ? shapeSettings.circleRadius : shapeSettings.circleRadius / _this.currentFactor;
509
+ circleOptions = new CircleOption(shapeID, eventArgs.fill, eventArgs.border, opacity, pointData['x'], pointData['y'], circleRadius, null);
505
510
  pathEle = _this.mapObject.renderer.drawCircle(circleOptions);
506
511
  break;
507
512
  case 'Path':
@@ -523,6 +528,9 @@ var LayerPanel = /** @class */ (function () {
523
528
  pathEle.setAttribute('aria-label', ((!isNullOrUndefined(currentShapeData['property'])) ?
524
529
  (currentShapeData['property'][properties]) : ''));
525
530
  pathEle.setAttribute('tabindex', (_this.mapObject.tabIndex + i + 2).toString());
531
+ if (drawingType === 'LineString') {
532
+ pathEle.setAttribute('style', 'outline:none');
533
+ }
526
534
  maintainSelection(_this.mapObject.selectedElementId, _this.mapObject.shapeSelectionClass, pathEle, 'ShapeselectionMapStyle');
527
535
  if (_this.mapObject.toggledShapeElementId) {
528
536
  for (var j = 0; j < _this.mapObject.toggledShapeElementId.length; j++) {
@@ -741,11 +749,14 @@ var LayerPanel = /** @class */ (function () {
741
749
  this.currentLayer.layerData.push(multiPolygonDatas);
742
750
  break;
743
751
  case 'linestring':
752
+ var extraSpace_1 = !isNullOrUndefined(this.currentLayer.shapeSettings.border.width) ?
753
+ this.currentLayer.shapeSettings.border.width : 1;
744
754
  // eslint-disable-next-line @typescript-eslint/no-explicit-any
745
755
  coordinates.map(function (points, index) {
746
756
  latitude = points[1];
747
757
  longitude = points[0];
748
758
  var point = convertGeoToPoint(latitude, longitude, _this.currentFactor, _this.currentLayer, _this.mapObject);
759
+ _this.calculateBox(point, extraSpace_1);
749
760
  newData.push({
750
761
  point: point, lat: latitude, lng: longitude
751
762
  });
@@ -756,6 +767,8 @@ var LayerPanel = /** @class */ (function () {
756
767
  break;
757
768
  case 'point': {
758
769
  var arrayCollections_1 = false;
770
+ var extraSpace_2 = (!isNullOrUndefined(this.currentLayer.shapeSettings.border.width) ?
771
+ this.currentLayer.shapeSettings.border.width : 1) + (this.currentLayer.shapeSettings.circleRadius * 2);
759
772
  // eslint-disable-next-line @typescript-eslint/no-explicit-any
760
773
  coordinates.map(function (points, index) {
761
774
  if (Object.prototype.toString.call(points) === '[object Array]') {
@@ -772,6 +785,7 @@ var LayerPanel = /** @class */ (function () {
772
785
  latitude = coordinates[1];
773
786
  longitude = coordinates[0];
774
787
  var point = convertGeoToPoint(latitude, longitude, this.currentFactor, this.currentLayer, this.mapObject);
788
+ this.calculateBox(point, extraSpace_2);
775
789
  this.currentLayer.layerData.push({
776
790
  point: point, type: type, lat: latitude, lng: longitude, property: properties
777
791
  });
@@ -785,6 +799,17 @@ var LayerPanel = /** @class */ (function () {
785
799
  break;
786
800
  }
787
801
  };
802
+ LayerPanel.prototype.calculateBox = function (point, extraSpace) {
803
+ if (isNullOrUndefined(this.rectBounds)) {
804
+ this.rectBounds = { min: { x: point.x, y: point.y - extraSpace }, max: { x: point.x, y: point.y + extraSpace } };
805
+ }
806
+ else {
807
+ this.rectBounds['min']['x'] = Math.min(this.rectBounds['min']['x'], point.x);
808
+ this.rectBounds['min']['y'] = Math.min(this.rectBounds['min']['y'], point.y - extraSpace);
809
+ this.rectBounds['max']['x'] = Math.max(this.rectBounds['max']['x'], point.x);
810
+ this.rectBounds['max']['y'] = Math.max(this.rectBounds['max']['y'], point.y + extraSpace);
811
+ }
812
+ };
788
813
  LayerPanel.prototype.calculateFactor = function (layer) {
789
814
  var horFactor;
790
815
  var verFactor = 1;
@@ -893,6 +918,15 @@ var LayerPanel = /** @class */ (function () {
893
918
  _this.calculateRectBox(point[0]);
894
919
  });
895
920
  break;
921
+ case 'linestring':
922
+ // eslint-disable-next-line @typescript-eslint/no-explicit-any
923
+ coordinates.map(function (point, index) {
924
+ _this.calculateRectBox(point, 'LineString', index === 0 ? true : false);
925
+ });
926
+ break;
927
+ case 'point':
928
+ _this.calculateRectBox(coordinates, 'point');
929
+ break;
896
930
  }
897
931
  }
898
932
  });
@@ -929,20 +963,33 @@ var LayerPanel = /** @class */ (function () {
929
963
  return newData;
930
964
  };
931
965
  // eslint-disable-next-line @typescript-eslint/no-explicit-any
932
- LayerPanel.prototype.calculateRectBox = function (coordinates) {
966
+ LayerPanel.prototype.calculateRectBox = function (coordinates, type, isFirstItem) {
933
967
  var _this = this;
934
- // eslint-disable-next-line @typescript-eslint/no-explicit-any
935
- Array.prototype.forEach.call(coordinates, function (currentCoords) {
936
- if (isNullOrUndefined(_this.mapObject.baseMapBounds)) {
937
- _this.mapObject.baseMapBounds = new GeoLocation({ min: currentCoords[1], max: currentCoords[1] }, { min: currentCoords[0], max: currentCoords[0] });
968
+ if (type !== 'LineString' && type !== 'point') {
969
+ // eslint-disable-next-line @typescript-eslint/no-explicit-any
970
+ Array.prototype.forEach.call(coordinates, function (currentCoords) {
971
+ if (isNullOrUndefined(_this.mapObject.baseMapBounds)) {
972
+ _this.mapObject.baseMapBounds = new GeoLocation({ min: currentCoords[1], max: currentCoords[1] }, { min: currentCoords[0], max: currentCoords[0] });
973
+ }
974
+ else {
975
+ _this.mapObject.baseMapBounds.latitude.min = Math.min(_this.mapObject.baseMapBounds.latitude.min, currentCoords[1]);
976
+ _this.mapObject.baseMapBounds.latitude.max = Math.max(_this.mapObject.baseMapBounds.latitude.max, currentCoords[1]);
977
+ _this.mapObject.baseMapBounds.longitude.min = Math.min(_this.mapObject.baseMapBounds.longitude.min, currentCoords[0]);
978
+ _this.mapObject.baseMapBounds.longitude.max = Math.max(_this.mapObject.baseMapBounds.longitude.max, currentCoords[0]);
979
+ }
980
+ });
981
+ }
982
+ else {
983
+ if ((isFirstItem || type === 'point') && isNullOrUndefined(this.mapObject.baseMapBounds)) {
984
+ this.mapObject.baseMapBounds = new GeoLocation({ min: coordinates[1], max: coordinates[1] }, { min: coordinates[0], max: coordinates[0] });
938
985
  }
939
986
  else {
940
- _this.mapObject.baseMapBounds.latitude.min = Math.min(_this.mapObject.baseMapBounds.latitude.min, currentCoords[1]);
941
- _this.mapObject.baseMapBounds.latitude.max = Math.max(_this.mapObject.baseMapBounds.latitude.max, currentCoords[1]);
942
- _this.mapObject.baseMapBounds.longitude.min = Math.min(_this.mapObject.baseMapBounds.longitude.min, currentCoords[0]);
943
- _this.mapObject.baseMapBounds.longitude.max = Math.max(_this.mapObject.baseMapBounds.longitude.max, currentCoords[0]);
987
+ this.mapObject.baseMapBounds.latitude.min = Math.min(this.mapObject.baseMapBounds.latitude.min, coordinates[1]);
988
+ this.mapObject.baseMapBounds.latitude.max = Math.max(this.mapObject.baseMapBounds.latitude.max, coordinates[1]);
989
+ this.mapObject.baseMapBounds.longitude.min = Math.min(this.mapObject.baseMapBounds.longitude.min, coordinates[0]);
990
+ this.mapObject.baseMapBounds.longitude.max = Math.max(this.mapObject.baseMapBounds.longitude.max, coordinates[0]);
944
991
  }
945
- });
992
+ }
946
993
  };
947
994
  LayerPanel.prototype.generateTiles = function (zoomLevel, tileTranslatePoint, zoomType, bing, position) {
948
995
  var userLang = this.mapObject.locale;
@@ -1031,16 +1078,18 @@ var LayerPanel = /** @class */ (function () {
1031
1078
  }
1032
1079
  }
1033
1080
  }
1034
- this.arrangeTiles(zoomType, this.animateToZoomX, this.animateToZoomY);
1081
+ if (this.mapObject.previousScale !== this.mapObject.scale || this.mapObject.isReset) {
1082
+ this.arrangeTiles(zoomType, this.animateToZoomX, this.animateToZoomY);
1083
+ }
1035
1084
  };
1036
1085
  LayerPanel.prototype.arrangeTiles = function (type, x, y) {
1037
1086
  var _this = this;
1038
1087
  var element = document.getElementById(this.mapObject.element.id + '_tile_parent');
1039
1088
  var element1 = document.getElementById(this.mapObject.element.id + '_tiles');
1040
1089
  var timeOut;
1041
- if (!isNullOrUndefined(type) && type !== 'Pan' && type !== 'Reset' && type.indexOf('ZoomOut') === -1) {
1090
+ if (!isNullOrUndefined(type) && type !== 'Pan') {
1042
1091
  this.tileAnimation(type, x, y);
1043
- timeOut = 250;
1092
+ timeOut = this.mapObject.layersCollection[0].animationDuration;
1044
1093
  }
1045
1094
  else {
1046
1095
  timeOut = 0;
@@ -1055,7 +1104,6 @@ var LayerPanel = /** @class */ (function () {
1055
1104
  }
1056
1105
  if (element1) {
1057
1106
  element1.style.zIndex = '0';
1058
- element1.style.visibility = 'hidden';
1059
1107
  }
1060
1108
  var animateElement;
1061
1109
  if (!document.getElementById(_this.mapObject.element.id + '_animated_tiles') && element) {
@@ -1117,35 +1165,23 @@ var LayerPanel = /** @class */ (function () {
1117
1165
  * @returns {void}
1118
1166
  */
1119
1167
  LayerPanel.prototype.tileAnimation = function (zoomType, translateX, translateY) {
1120
- var element = document.getElementById(this.mapObject.element.id + '_tile_parent');
1121
- var element1 = document.getElementById('animated_tiles');
1122
- var ele = document.getElementById(this.mapObject.element.id + '_tiles');
1168
+ var tileParent = document.getElementById(this.mapObject.element.id + '_tile_parent');
1169
+ var animatedTiles = document.getElementById(this.mapObject.element.id + '_animated_tiles');
1170
+ var tileElement = document.getElementById(this.mapObject.element.id + '_tiles');
1123
1171
  var scaleValue = '2';
1124
- if (zoomType.indexOf('ZoomOut') === 0) {
1125
- ele.style.zIndex = '1';
1126
- element.style.zIndex = '0';
1127
- // element1 = ele.children[ele.childElementCount - 1] as HTMLElement;
1128
- while (ele.childElementCount >= 1) {
1129
- ele.removeChild(ele.children[0]);
1130
- }
1131
- translateX = 0;
1132
- translateY = 128 - 23;
1133
- scaleValue = '0.5';
1134
- }
1135
- else if (zoomType === 'Reset') {
1136
- ele.style.zIndex = '1';
1137
- element.style.zIndex = '0';
1138
- while (!(ele.childElementCount === 1) && !(ele.childElementCount === 0)) {
1139
- ele.removeChild(ele.children[1]);
1172
+ if (zoomType.indexOf('ZoomOut') === 0 || zoomType === 'Reset') {
1173
+ tileElement.style.zIndex = '1';
1174
+ tileParent.style.zIndex = '0';
1175
+ while (tileElement.childElementCount >= 1) {
1176
+ tileElement.removeChild(tileElement.children[0]);
1140
1177
  }
1141
- element1 = ele.children[0];
1142
1178
  translateX = 0;
1143
- translateY = 0;
1144
- scaleValue = '1';
1179
+ translateY = document.getElementById(this.mapObject.element.id + '_tile_parent').getClientRects()[0].height / 4;
1180
+ scaleValue = zoomType.indexOf('ZoomOut') === 0 ? '0.5' : '0.2';
1145
1181
  }
1146
- if (!isNullOrUndefined(element1)) {
1147
- element1.style.transition = '250ms';
1148
- element1.style.transform = 'translate(' + translateX + 'px, ' + translateY + 'px) scale(' + scaleValue + ')';
1182
+ if (!isNullOrUndefined(animatedTiles)) {
1183
+ animatedTiles.style.transition = this.mapObject.layersCollection[0].animationDuration + 'ms';
1184
+ animatedTiles.style.transform = 'translate(' + translateX + 'px, ' + translateY + 'px) scale(' + scaleValue + ')';
1149
1185
  }
1150
1186
  };
1151
1187
  /**
@@ -446,21 +446,25 @@ var Legend = /** @class */ (function () {
446
446
  var textLocation = collection['Text'];
447
447
  var imageUrl = ((isNullOrUndefined(collection['ImageSrc'])) ? legend.shape : collection['ImageSrc']);
448
448
  var renderOptions_1 = new PathOption(shapeId, collection['Fill'], strokeWidth, strokeColor, legend.opacity, isNullOrUndefined(shapeBorder.opacity) ? legend.opacity : shapeBorder.opacity, '');
449
- legend.textStyle.color = (legend.textStyle.color !== null) ? legend.textStyle.color :
449
+ var legendTextStyle = {
450
+ fontFamily: legend.textStyle.fontFamily, fontStyle: legend.textStyle.fontStyle,
451
+ fontWeight: legend.textStyle.fontWeight, size: legend.textStyle.size, color: legend.textStyle.color, opacity: legend.textStyle.opacity
452
+ };
453
+ legendTextStyle.color = (legendTextStyle.color !== null) ? legendTextStyle.color :
450
454
  this.maps.themeStyle.legendTextColor;
451
- legend.textStyle.fontFamily = map.themeStyle.fontFamily || legend.textStyle.fontFamily;
452
- legend.textStyle.size = map.themeStyle.legendFontSize || legend.textStyle.size;
455
+ legendTextStyle.fontFamily = map.themeStyle.fontFamily || legendTextStyle.fontFamily;
456
+ legendTextStyle.size = map.themeStyle.legendFontSize || legendTextStyle.size;
453
457
  if (i === 0) {
454
458
  this.renderLegendBorder();
455
459
  }
456
460
  legendElement.appendChild(drawSymbol(shapeLocation, shape, shapeSize, collection['ImageSrc'], renderOptions_1));
457
461
  var legendRectSize = collection['Rect']['x'] + collection['Rect']['width'];
458
462
  if (legendRectSize > this.legendBorderRect.width) {
459
- var trimmedText = this.legendTextTrim(this.legendBorderRect.width, legendText, legend.textStyle, legendRectSize);
463
+ var trimmedText = this.legendTextTrim(this.legendBorderRect.width, legendText, legendTextStyle, legendRectSize);
460
464
  legendText = trimmedText;
461
465
  }
462
466
  textOptions = new TextOption(textId, textLocation.x, textLocation.y, 'start', legendText, '', '');
463
- renderTextElement(textOptions, legend.textStyle, legend.textStyle.color, legendElement);
467
+ renderTextElement(textOptions, legendTextStyle, legendTextStyle.color, legendElement);
464
468
  this.legendGroup.appendChild(legendElement);
465
469
  // eslint-disable-next-line @typescript-eslint/no-explicit-any
466
470
  if (i === (this.totalPages[page]['Collection'].length - 1)) {
@@ -528,7 +532,7 @@ var Legend = /** @class */ (function () {
528
532
  // eslint-disable-next-line @typescript-eslint/no-explicit-any
529
533
  var collection = this.maps.legendModule.legendCollection;
530
534
  var length;
531
- var multiSelectEnable = this.maps.layers[collection[0]['data'][0]['layerIndex']].selectionSettings.enableMultiSelect;
535
+ var multiSelectEnable = !isNullOrUndefined(collection[0]['data'][0]['layerIndex']) ? this.maps.layers[collection[0]['data'][0]['layerIndex']].selectionSettings.enableMultiSelect : false;
532
536
  var selectLength = 0;
533
537
  var interactProcess = true;
534
538
  var idIndex = parseFloat(targetElement.id.charAt(targetElement.id.length - 1));
@@ -1141,7 +1145,10 @@ var Legend = /** @class */ (function () {
1141
1145
  var map = this.maps;
1142
1146
  var legend = map.legendSettings;
1143
1147
  var legendTitle = legend.title.text;
1144
- var textStyle = legend.titleStyle;
1148
+ var textStyle = {
1149
+ fontFamily: legend.titleStyle.fontFamily, fontStyle: legend.titleStyle.fontStyle,
1150
+ fontWeight: legend.titleStyle.fontWeight, size: legend.titleStyle.size, color: legend.titleStyle.color, opacity: legend.titleStyle.opacity
1151
+ };
1145
1152
  var textOptions;
1146
1153
  var spacing = 10;
1147
1154
  var trimTitle = textTrim((this.legendItemRect.width + (spacing * 2)), legendTitle, textStyle);
@@ -1160,6 +1167,7 @@ var Legend = /** @class */ (function () {
1160
1167
  map.svgObject.appendChild(this.legendGroup);
1161
1168
  if (legendTitle) {
1162
1169
  textStyle.color = (textStyle.color !== null) ? textStyle.color : this.maps.themeStyle.legendTitleFontColor;
1170
+ textStyle.fontFamily = !isNullOrUndefined(textStyle.fontFamily) ? textStyle.fontFamily : this.maps.themeStyle.fontFamily;
1163
1171
  textOptions = new TextOption(map.element.id + '_LegendTitle', (this.legendItemRect.x) + (this.legendItemRect.width / 2), this.legendItemRect.y - (textSize.height / 2) - spacing / 2, 'middle', trimTitle, '');
1164
1172
  renderTextElement(textOptions, textStyle, textStyle.color, this.legendGroup);
1165
1173
  }
@@ -1275,14 +1283,18 @@ var Legend = /** @class */ (function () {
1275
1283
  });
1276
1284
  });
1277
1285
  };
1286
+ // eslint-disable-next-line @typescript-eslint/no-explicit-any
1278
1287
  Legend.prototype.getMarkerLegendData = function (layerIndex, text, legendFill) {
1279
1288
  var _this = this;
1289
+ // eslint-disable-next-line @typescript-eslint/no-explicit-any
1280
1290
  var legendData = [];
1281
1291
  this.maps.layers[layerIndex].markerSettings.map(function (markerSettings, markerIndex) {
1292
+ // eslint-disable-next-line @typescript-eslint/no-explicit-any
1282
1293
  var markerData = markerSettings.dataSource;
1294
+ // eslint-disable-next-line @typescript-eslint/no-explicit-any
1283
1295
  Array.prototype.forEach.call(markerData, function (data, dataIndex) {
1284
1296
  var marker = _this.maps.layers[layerIndex].markerSettings[markerIndex];
1285
- if ((text === data[marker.legendText] || text === '') && legendFill == data[marker.colorValuePath]) {
1297
+ if ((text === data[marker.legendText] || text === '') && legendFill === data[marker.colorValuePath]) {
1286
1298
  legendData.push({ layerIndex: layerIndex, markerIndex: markerIndex, dataIndex: dataIndex, value: legendFill, name: text,
1287
1299
  shape: !isNullOrUndefined(marker.shapeValuePath) ? data[marker.shapeValuePath] : marker.shape });
1288
1300
  }
@@ -1659,7 +1671,7 @@ var Legend = /** @class */ (function () {
1659
1671
  mapElement.setAttribute('fill', this.maps.layers[k].shapeSettings.fill);
1660
1672
  mapElement.setAttribute('stroke', this.maps.layers[k].shapeSettings.border.color);
1661
1673
  mapElement.setAttribute('fill-opacity', (this.maps.layers[k].shapeSettings.opacity).toString());
1662
- mapElement.setAttribute('stroke-width', (this.maps.layers[k].shapeSettings.border.width).toString());
1674
+ mapElement.setAttribute('stroke-width', (isNullOrUndefined(this.maps.layers[k].shapeSettings.border.width) ? 0 : this.maps.layers[k].shapeSettings.border.width).toString());
1663
1675
  mapElement.setAttribute('stroke-opacity', (isNullOrUndefined(this.maps.layers[k].shapeSettings.border.opacity) ?
1664
1676
  this.maps.layers[k].shapeSettings.opacity :
1665
1677
  this.maps.layers[k].shapeSettings.border.opacity).toString());
@@ -1722,7 +1734,7 @@ var Legend = /** @class */ (function () {
1722
1734
  layerElement.setAttribute('fill', this.maps.layers[j].shapeSettings.fill);
1723
1735
  layerElement.setAttribute('fill-opacity', (this.maps.layers[j].shapeSettings.opacity).toString());
1724
1736
  layerElement.setAttribute('stroke', this.maps.layers[j].shapeSettings.border.color);
1725
- layerElement.setAttribute('stroke-width', (this.maps.layers[j].shapeSettings.border.width).toString());
1737
+ layerElement.setAttribute('stroke-width', (isNullOrUndefined(this.maps.layers[j].shapeSettings.border.width) ? 0 : this.maps.layers[j].shapeSettings.border.width).toString());
1726
1738
  layerElement.setAttribute('stroke-opacity', (isNullOrUndefined(this.maps.layers[j].shapeSettings.border.opacity) ?
1727
1739
  this.maps.layers[j].shapeSettings.opacity :
1728
1740
  this.maps.layers[j].shapeSettings.border.opacity).toString());
@@ -1752,7 +1764,7 @@ var Legend = /** @class */ (function () {
1752
1764
  layerElement.setAttribute('stroke-opacity', (isNullOrUndefined(this.maps.layers[j].shapeSettings.border.opacity) ?
1753
1765
  this.maps.layers[j].shapeSettings.opacity :
1754
1766
  this.maps.layers[j].shapeSettings.border.opacity).toString());
1755
- layerElement.setAttribute('stroke-width', (this.maps.layers[j].shapeSettings.border.width).toString());
1767
+ layerElement.setAttribute('stroke-width', (isNullOrUndefined(this.maps.layers[j].shapeSettings.border.width) ? 0 : this.maps.layers[j].shapeSettings.border.width).toString());
1756
1768
  layerElement.setAttribute('fill-opacity', (this.maps.layers[j].shapeSettings.opacity).toString());
1757
1769
  layerElement.setAttribute('stroke', this.maps.layers[j].shapeSettings.border.color);
1758
1770
  if (targetEle !== null) {
@@ -1793,7 +1805,7 @@ var Legend = /** @class */ (function () {
1793
1805
  if (this.maps.legendSettings.toggleLegendSettings.applyShapeSettings) {
1794
1806
  LegendInteractive.setAttribute('fill', this.maps.layers[k].shapeSettings.fill);
1795
1807
  LegendInteractive.setAttribute('stroke', this.maps.layers[k].shapeSettings.border.color);
1796
- LegendInteractive.setAttribute('stroke-width', (this.maps.layers[k].shapeSettings.border.width).toString());
1808
+ LegendInteractive.setAttribute('stroke-width', (isNullOrUndefined(this.maps.layers[k].shapeSettings.border.width) ? 0 : this.maps.layers[k].shapeSettings.border.width).toString());
1797
1809
  LegendInteractive.setAttribute('stroke-opacity', (isNullOrUndefined(this.maps.layers[k].shapeSettings.border.opacity) ?
1798
1810
  this.maps.layers[k].shapeSettings.opacity :
1799
1811
  this.maps.layers[k].shapeSettings.border.opacity).toString());
@@ -1857,7 +1869,7 @@ var Legend = /** @class */ (function () {
1857
1869
  mapLegendElement.setAttribute('fill', this.maps.layers[0].shapeSettings.fill);
1858
1870
  mapLegendElement.setAttribute('stroke', this.maps.layers[0].shapeSettings.border.color);
1859
1871
  mapLegendElement.setAttribute('fill-opacity', (this.maps.layers[k].shapeSettings.opacity).toString());
1860
- mapLegendElement.setAttribute('stroke-width', (this.maps.layers[k].shapeSettings.border.width).toString());
1872
+ mapLegendElement.setAttribute('stroke-width', (isNullOrUndefined(this.maps.layers[k].shapeSettings.border.width) ? 0 : this.maps.layers[k].shapeSettings.border.width).toString());
1861
1873
  mapLegendElement.setAttribute('stroke-opacity', (isNullOrUndefined(this.maps.layers[k].shapeSettings.border.opacity) ?
1862
1874
  this.maps.layers[k].shapeSettings.opacity :
1863
1875
  this.maps.layers[k].shapeSettings.border.opacity).toString());
@@ -1884,7 +1896,7 @@ var Legend = /** @class */ (function () {
1884
1896
  this.maps.toggledShapeElementId.splice(toggledShapeIdIndex, 1);
1885
1897
  }
1886
1898
  mapLegendElement.setAttribute('fill-opacity', (this.maps.layers[k].shapeSettings.opacity).toString());
1887
- mapLegendElement.setAttribute('stroke-width', (this.maps.layers[k].shapeSettings.border.width).toString());
1899
+ mapLegendElement.setAttribute('stroke-width', (isNullOrUndefined(this.maps.layers[k].shapeSettings.border.width) ? 0 : this.maps.layers[k].shapeSettings.border.width).toString());
1888
1900
  mapLegendElement.setAttribute('stroke', this.maps.layers[0].shapeSettings.border.color);
1889
1901
  mapLegendElement.setAttribute('stroke-opacity', (isNullOrUndefined(this.maps.layers[k].shapeSettings.border.opacity) ?
1890
1902
  this.maps.layers[k].shapeSettings.opacity : this.maps.layers[k].shapeSettings.border.opacity).toString());
@@ -48,15 +48,9 @@ var Marker = /** @class */ (function () {
48
48
  border: markerSettings.border, colorValuePath: markerSettings.colorValuePath,
49
49
  shapeValuePath: markerSettings.shapeValuePath, imageUrlValuePath: markerSettings.imageUrlValuePath
50
50
  };
51
- eventArgs = markerColorChoose(eventArgs, data);
52
- eventArgs = markerShapeChoose(eventArgs, data);
53
51
  _this.maps.trigger('markerRendering', eventArgs, function (MarkerArgs) {
54
- if (markerSettings.colorValuePath !== eventArgs.colorValuePath) {
55
- eventArgs = markerColorChoose(eventArgs, data);
56
- }
57
- if (markerSettings.shapeValuePath !== eventArgs.shapeValuePath) {
58
- eventArgs = markerShapeChoose(eventArgs, data);
59
- }
52
+ eventArgs = markerColorChoose(eventArgs, data);
53
+ eventArgs = markerShapeChoose(eventArgs, data);
60
54
  var lng = (!isNullOrUndefined(markerSettings.longitudeValuePath)) ?
61
55
  Number(getValueFromObject(data, markerSettings.longitudeValuePath)) : !isNullOrUndefined(data['longitude']) ?
62
56
  parseFloat(data['longitude']) : !isNullOrUndefined(data['Longitude']) ? parseFloat(data['Longitude']) : 0;
package/src/maps/maps.js CHANGED
@@ -1233,7 +1233,7 @@ var Maps = /** @class */ (function (_super) {
1233
1233
  */
1234
1234
  Maps.prototype.mapsOnResize = function (e) {
1235
1235
  var _this = this;
1236
- this.isResize = true;
1236
+ this.isResize = this.isReset = true;
1237
1237
  var args = {
1238
1238
  name: resize,
1239
1239
  previousSize: this.availableSize,
@@ -707,7 +707,7 @@ var LegendSettings = /** @class */ (function (_super) {
707
707
  Complex({}, CommonTitleSettings)
708
708
  ], LegendSettings.prototype, "title", void 0);
709
709
  __decorate([
710
- Complex({}, Font)
710
+ Complex(Theme.legendTitleFont, Font)
711
711
  ], LegendSettings.prototype, "titleStyle", void 0);
712
712
  __decorate([
713
713
  Property('Bottom')
@@ -807,7 +807,7 @@ var ShapeSettings = /** @class */ (function (_super) {
807
807
  Property(5)
808
808
  ], ShapeSettings.prototype, "circleRadius", void 0);
809
809
  __decorate([
810
- Complex({ width: 0, color: '#000000' }, Border)
810
+ Complex({ width: null, color: '#000000' }, Border)
811
811
  ], ShapeSettings.prototype, "border", void 0);
812
812
  __decorate([
813
813
  Property('')