@syncfusion/ej2-maps 19.3.53 → 19.4.48
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/.github/PULL_REQUEST_TEMPLATE/Bug.md +72 -0
- package/.github/PULL_REQUEST_TEMPLATE/Feature.md +49 -0
- package/CHANGELOG.md +42 -1
- package/README.md +1 -1
- 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 +663 -293
- package/dist/es6/ej2-maps.es2015.js.map +1 -1
- package/dist/es6/ej2-maps.es5.js +659 -289
- 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 +12 -12
- package/src/maps/layers/bubble.d.ts +6 -0
- package/src/maps/layers/bubble.js +7 -1
- package/src/maps/layers/data-label.js +1 -0
- package/src/maps/layers/layer-panel.d.ts +2 -1
- package/src/maps/layers/layer-panel.js +89 -52
- package/src/maps/layers/legend.d.ts +41 -2
- package/src/maps/layers/legend.js +90 -29
- package/src/maps/layers/marker.js +2 -8
- package/src/maps/maps-model.d.ts +1 -1
- package/src/maps/maps.d.ts +8 -0
- package/src/maps/maps.js +142 -19
- package/src/maps/model/base-model.d.ts +7 -0
- package/src/maps/model/base.d.ts +6 -0
- package/src/maps/model/base.js +5 -2
- package/src/maps/model/interface.d.ts +1 -3
- package/src/maps/model/theme.js +62 -5
- package/src/maps/user-interaction/highlight.d.ts +9 -1
- package/src/maps/user-interaction/highlight.js +22 -15
- package/src/maps/user-interaction/selection.d.ts +9 -1
- package/src/maps/user-interaction/selection.js +27 -19
- package/src/maps/user-interaction/tooltip.js +9 -3
- package/src/maps/user-interaction/zoom.d.ts +5 -1
- package/src/maps/user-interaction/zoom.js +82 -45
- package/src/maps/utils/enum.d.ts +3 -1
- package/src/maps/utils/helper.d.ts +4 -2
- package/src/maps/utils/helper.js +130 -98
package/src/maps/model/base.d.ts
CHANGED
|
@@ -845,6 +845,12 @@ export declare class ToggleLegendSettings extends ChildProperty<ToggleLegendSett
|
|
|
845
845
|
* Sets and gets the options to customize the legend of the maps.
|
|
846
846
|
*/
|
|
847
847
|
export declare class LegendSettings extends ChildProperty<LegendSettings> {
|
|
848
|
+
/**
|
|
849
|
+
* Enables or disables to render the legend item based on the shapes from the data source of markers.
|
|
850
|
+
*
|
|
851
|
+
* @default false
|
|
852
|
+
*/
|
|
853
|
+
useMarkerShape: boolean;
|
|
848
854
|
/**
|
|
849
855
|
* Enables or disables the toggle visibility for legend in maps.
|
|
850
856
|
*
|
package/src/maps/model/base.js
CHANGED
|
@@ -655,6 +655,9 @@ var LegendSettings = /** @class */ (function (_super) {
|
|
|
655
655
|
function LegendSettings() {
|
|
656
656
|
return _super !== null && _super.apply(this, arguments) || this;
|
|
657
657
|
}
|
|
658
|
+
__decorate([
|
|
659
|
+
Property(false)
|
|
660
|
+
], LegendSettings.prototype, "useMarkerShape", void 0);
|
|
658
661
|
__decorate([
|
|
659
662
|
Property(false)
|
|
660
663
|
], LegendSettings.prototype, "toggleVisibility", void 0);
|
|
@@ -707,7 +710,7 @@ var LegendSettings = /** @class */ (function (_super) {
|
|
|
707
710
|
Complex({}, CommonTitleSettings)
|
|
708
711
|
], LegendSettings.prototype, "title", void 0);
|
|
709
712
|
__decorate([
|
|
710
|
-
Complex(
|
|
713
|
+
Complex(Theme.legendTitleFont, Font)
|
|
711
714
|
], LegendSettings.prototype, "titleStyle", void 0);
|
|
712
715
|
__decorate([
|
|
713
716
|
Property('Bottom')
|
|
@@ -807,7 +810,7 @@ var ShapeSettings = /** @class */ (function (_super) {
|
|
|
807
810
|
Property(5)
|
|
808
811
|
], ShapeSettings.prototype, "circleRadius", void 0);
|
|
809
812
|
__decorate([
|
|
810
|
-
Complex({ width:
|
|
813
|
+
Complex({ width: null, color: '#000000' }, Border)
|
|
811
814
|
], ShapeSettings.prototype, "border", void 0);
|
|
812
815
|
__decorate([
|
|
813
816
|
Property('')
|
|
@@ -109,9 +109,7 @@ export interface ITooltipRenderCompleteEventArgs extends IMapsEventArgs {
|
|
|
109
109
|
/**
|
|
110
110
|
* Specifies the event arguments for the resize event in maps.
|
|
111
111
|
*/
|
|
112
|
-
export interface IResizeEventArgs {
|
|
113
|
-
/** Defines the name of the event. */
|
|
114
|
-
name: string;
|
|
112
|
+
export interface IResizeEventArgs extends IMapsEventArgs {
|
|
115
113
|
/** Defines the previous size of the maps before the resize event. */
|
|
116
114
|
previousSize: Size;
|
|
117
115
|
/** Defines the current size of the maps after the resize event. */
|
package/src/maps/model/theme.js
CHANGED
|
@@ -26,15 +26,15 @@ export var Theme;
|
|
|
26
26
|
fontWeight: 'Regular',
|
|
27
27
|
color: null,
|
|
28
28
|
fontStyle: 'Regular',
|
|
29
|
-
fontFamily:
|
|
29
|
+
fontFamily: null
|
|
30
30
|
};
|
|
31
31
|
/** @private */
|
|
32
32
|
Theme.legendTitleFont = {
|
|
33
|
-
size: '
|
|
34
|
-
fontWeight: '
|
|
33
|
+
size: '12px',
|
|
34
|
+
fontWeight: 'Medium',
|
|
35
35
|
color: null,
|
|
36
|
-
fontStyle: '
|
|
37
|
-
fontFamily:
|
|
36
|
+
fontStyle: 'Medium',
|
|
37
|
+
fontFamily: null
|
|
38
38
|
};
|
|
39
39
|
/** @private */
|
|
40
40
|
Theme.legendLabelFont = {
|
|
@@ -183,6 +183,14 @@ export function getShapeColor(theme) {
|
|
|
183
183
|
themePalette = ['#5ECB9B', '#A860F1', '#EBA844', '#557EF7', '#E9599B',
|
|
184
184
|
'#BFC529', '#3BC6CF', '#7A68EC', '#74B706', '#EA6266'];
|
|
185
185
|
break;
|
|
186
|
+
case 'fluentui':
|
|
187
|
+
themePalette = ['#614570', '#4C6FB1', '#CC6952', '#3F579A', '#4EA09B',
|
|
188
|
+
'#6E7A89', '#D4515C', '#E6AF5D', '#639751', '#9D4D69'];
|
|
189
|
+
break;
|
|
190
|
+
case 'fluentuidark':
|
|
191
|
+
themePalette = ['#8AB113', '#2A72D5', '#43B786', '#584EC6', '#E85F9C',
|
|
192
|
+
'#6E7A89', '#EA6266', '#EBA844', '#26BC7A', '#BC4870'];
|
|
193
|
+
break;
|
|
186
194
|
default:
|
|
187
195
|
themePalette = ['#B5E485', '#7BC1E8', '#DF819C', '#EC9B79', '#78D0D3',
|
|
188
196
|
'#D6D572', '#9178E3', '#A1E5B4', '#87A4B4', '#E4C16C'];
|
|
@@ -328,6 +336,7 @@ export function getThemeStyle(theme) {
|
|
|
328
336
|
tooltipFillColor: '#363F4C',
|
|
329
337
|
zoomFillColor: '#FFFFFF',
|
|
330
338
|
labelFontFamily: 'Roboto, Noto, Sans-serif',
|
|
339
|
+
fontFamily: 'Roboto, Noto, Sans-serif',
|
|
331
340
|
titleFontWeight: 'Medium',
|
|
332
341
|
zoomSelectionColor: '#e61576',
|
|
333
342
|
shapeFill: '#A6A6A6'
|
|
@@ -345,6 +354,7 @@ export function getThemeStyle(theme) {
|
|
|
345
354
|
tooltipFontColor: '#000000',
|
|
346
355
|
tooltipFillColor: '#ffffff',
|
|
347
356
|
zoomFillColor: '#FFFFFF',
|
|
357
|
+
fontFamily: 'Roboto, Noto, Sans-serif',
|
|
348
358
|
labelFontFamily: 'Roboto, Noto, Sans-serif',
|
|
349
359
|
titleFontWeight: 'Medium',
|
|
350
360
|
zoomSelectionColor: '#e61576',
|
|
@@ -466,6 +476,52 @@ export function getThemeStyle(theme) {
|
|
|
466
476
|
shapeFill: '#495057'
|
|
467
477
|
};
|
|
468
478
|
break;
|
|
479
|
+
case 'fluentui':
|
|
480
|
+
style = {
|
|
481
|
+
backgroundColor: 'rgba(255,255,255, 0.0)',
|
|
482
|
+
areaBackgroundColor: 'rgba(255,255,255, 0.0)',
|
|
483
|
+
titleFontColor: '#201F1E',
|
|
484
|
+
subTitleFontColor: '#201F1E',
|
|
485
|
+
legendTitleFontColor: '#201F1E',
|
|
486
|
+
legendTextColor: '#201F1E',
|
|
487
|
+
dataLabelFontColor: '#201F1E',
|
|
488
|
+
tooltipFontColor: '#323130',
|
|
489
|
+
tooltipFillColor: '#FFFFFF',
|
|
490
|
+
zoomFillColor: '#A19F9D',
|
|
491
|
+
fontFamily: 'Segoe UI',
|
|
492
|
+
titleFontSize: '14px',
|
|
493
|
+
legendFontSize: '12px',
|
|
494
|
+
tooltipFillOpacity: 1,
|
|
495
|
+
tooltipTextOpacity: 1,
|
|
496
|
+
labelFontFamily: 'Segoe UI',
|
|
497
|
+
titleFontWeight: '600',
|
|
498
|
+
zoomSelectionColor: '#323130',
|
|
499
|
+
shapeFill: '#F3F2F1'
|
|
500
|
+
};
|
|
501
|
+
break;
|
|
502
|
+
case 'fluentuidark':
|
|
503
|
+
style = {
|
|
504
|
+
backgroundColor: 'rgba(255,255,255, 0.0)',
|
|
505
|
+
areaBackgroundColor: 'rgba(255,255,255, 0.0)',
|
|
506
|
+
titleFontColor: '#F3F2F1',
|
|
507
|
+
subTitleFontColor: '#F3F2F1',
|
|
508
|
+
legendTitleFontColor: '#F3F2F1',
|
|
509
|
+
legendTextColor: '#F3F2F1',
|
|
510
|
+
dataLabelFontColor: '#F3F2F1',
|
|
511
|
+
tooltipFontColor: '#F3F2F1',
|
|
512
|
+
tooltipFillColor: '#252423',
|
|
513
|
+
zoomFillColor: '#484644',
|
|
514
|
+
fontFamily: 'Segoe UI',
|
|
515
|
+
titleFontSize: '14px',
|
|
516
|
+
legendFontSize: '12px',
|
|
517
|
+
tooltipFillOpacity: 1,
|
|
518
|
+
tooltipTextOpacity: 1,
|
|
519
|
+
labelFontFamily: 'Segoe UI',
|
|
520
|
+
titleFontWeight: '600',
|
|
521
|
+
zoomSelectionColor: '#F3F2F1',
|
|
522
|
+
shapeFill: '#252423'
|
|
523
|
+
};
|
|
524
|
+
break;
|
|
469
525
|
default:
|
|
470
526
|
style = {
|
|
471
527
|
backgroundColor: '#FFFFFF',
|
|
@@ -479,6 +535,7 @@ export function getThemeStyle(theme) {
|
|
|
479
535
|
tooltipFillColor: '#000000',
|
|
480
536
|
zoomFillColor: '#737373',
|
|
481
537
|
labelFontFamily: 'Roboto, Noto, Sans-serif',
|
|
538
|
+
fontFamily: 'Roboto, Noto, Sans-serif',
|
|
482
539
|
titleFontWeight: 'Medium',
|
|
483
540
|
zoomSelectionColor: '#e61576',
|
|
484
541
|
shapeFill: '#A6A6A6'
|
|
@@ -1,10 +1,14 @@
|
|
|
1
1
|
import { Maps } from '../../index';
|
|
2
|
+
import { HighlightSettingsModel } from '../index';
|
|
2
3
|
/**
|
|
3
4
|
* Highlight module class
|
|
4
5
|
*/
|
|
5
6
|
export declare class Highlight {
|
|
6
7
|
private maps;
|
|
7
|
-
|
|
8
|
+
/**
|
|
9
|
+
* @private
|
|
10
|
+
*/
|
|
11
|
+
highlightSettings: HighlightSettingsModel;
|
|
8
12
|
constructor(maps: Maps);
|
|
9
13
|
/**
|
|
10
14
|
* To bind events for highlight module
|
|
@@ -23,6 +27,10 @@ export declare class Highlight {
|
|
|
23
27
|
*/
|
|
24
28
|
addHighlight(layerIndex: number, name: string, enable: boolean): void;
|
|
25
29
|
private mouseMove;
|
|
30
|
+
/**
|
|
31
|
+
* @private
|
|
32
|
+
*/
|
|
33
|
+
handleHighlight(targetElement: Element, layerIndex: number, data: any, shapeData: any): void;
|
|
26
34
|
private mapHighlight;
|
|
27
35
|
private highlightMap;
|
|
28
36
|
/**
|
|
@@ -93,14 +93,7 @@ var Highlight = /** @class */ (function () {
|
|
|
93
93
|
this.highlightSettings = this.maps.layers[layerIndex].navigationLineSettings[index].highlightSettings;
|
|
94
94
|
}
|
|
95
95
|
if (this.highlightSettings.enable) {
|
|
96
|
-
|
|
97
|
-
this.maps.legendModule.shapeHighLightAndSelection(targetEle, data, this.highlightSettings, 'highlight', layerIndex);
|
|
98
|
-
}
|
|
99
|
-
var selectHighLight = targetEle.id.indexOf('shapeIndex') > -1 && this.maps.legendSettings.visible ?
|
|
100
|
-
this.maps.legendModule.shapeToggled : true;
|
|
101
|
-
if (selectHighLight) {
|
|
102
|
-
this.mapHighlight(targetEle, shapeData, data);
|
|
103
|
-
}
|
|
96
|
+
this.handleHighlight(targetEle, layerIndex, data, shapeData);
|
|
104
97
|
}
|
|
105
98
|
else {
|
|
106
99
|
var element = document.getElementsByClassName('highlightMapStyle')[0];
|
|
@@ -124,21 +117,35 @@ var Highlight = /** @class */ (function () {
|
|
|
124
117
|
targetEle.setAttribute('stroke', this.maps.layers[layerIndex].navigationLineSettings[index].color);
|
|
125
118
|
}
|
|
126
119
|
removeClass(targetEle);
|
|
127
|
-
if (this.maps.legendSettings.visible) {
|
|
120
|
+
if (this.maps.legendSettings.visible && this.maps.legendModule) {
|
|
128
121
|
this.maps.legendModule.removeShapeHighlightCollection();
|
|
129
122
|
}
|
|
130
123
|
}
|
|
131
124
|
else if ((targetEle.id.indexOf(this.maps.element.id + '_Legend_Shape_Index') !== -1 ||
|
|
132
|
-
targetEle.id.indexOf(this.maps.element.id + '_Legend_Index') !== -1) &&
|
|
125
|
+
targetEle.id.indexOf(this.maps.element.id + '_Legend_Index') !== -1) && this.maps.legendModule &&
|
|
133
126
|
this.maps.legendSettings.visible && targetEle.id.indexOf('_Text') === -1) {
|
|
134
127
|
this.maps.legendModule.legendHighLightAndSelection(targetEle, 'highlight');
|
|
135
128
|
}
|
|
136
129
|
else {
|
|
137
|
-
if (this.maps.legendSettings.visible) {
|
|
130
|
+
if (this.maps.legendSettings.visible && this.maps.legendModule) {
|
|
138
131
|
this.maps.legendModule.removeLegendHighlightCollection();
|
|
139
132
|
}
|
|
140
133
|
}
|
|
141
134
|
};
|
|
135
|
+
/**
|
|
136
|
+
* @private
|
|
137
|
+
*/
|
|
138
|
+
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
139
|
+
Highlight.prototype.handleHighlight = function (targetElement, layerIndex, data, shapeData) {
|
|
140
|
+
if (this.maps.legendSettings.visible && targetElement.id.indexOf('_MarkerIndex_') === -1 && this.maps.legendModule) {
|
|
141
|
+
this.maps.legendModule.shapeHighLightAndSelection(targetElement, data, this.highlightSettings, 'highlight', layerIndex);
|
|
142
|
+
}
|
|
143
|
+
var selectHighLight = targetElement.id.indexOf('shapeIndex') > -1 && (this.maps.legendSettings.visible && this.maps.legendModule) ?
|
|
144
|
+
this.maps.legendModule.shapeToggled : true;
|
|
145
|
+
if (selectHighLight) {
|
|
146
|
+
this.mapHighlight(targetElement, shapeData, data);
|
|
147
|
+
}
|
|
148
|
+
};
|
|
142
149
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
143
150
|
Highlight.prototype.mapHighlight = function (targetEle, shapeData, data) {
|
|
144
151
|
var _this = this;
|
|
@@ -149,14 +156,14 @@ var Highlight = /** @class */ (function () {
|
|
|
149
156
|
isMarkerSelect = this.maps.layers[layerIndex].markerSettings[marker].highlightSettings.enable;
|
|
150
157
|
}
|
|
151
158
|
var border = {
|
|
152
|
-
color: this.highlightSettings.border.color,
|
|
153
|
-
width: this.highlightSettings.border.width / (isMarkerSelect ? 1 : this.maps.scale),
|
|
159
|
+
color: (targetEle.parentElement.id.indexOf('LineString') === -1) ? this.highlightSettings.border.color : (this.highlightSettings.border.color || this.highlightSettings.fill),
|
|
160
|
+
width: (targetEle.parentElement.id.indexOf('LineString') === -1) ? (this.highlightSettings.border.width / (isMarkerSelect ? 1 : this.maps.scale)) : (this.highlightSettings.border.width / this.maps.scale),
|
|
154
161
|
opacity: this.highlightSettings.border.opacity
|
|
155
162
|
};
|
|
156
163
|
var eventArgs = {
|
|
157
164
|
opacity: this.highlightSettings.opacity,
|
|
158
|
-
fill: targetEle.id.indexOf('NavigationIndex') === -1 ? !isNullOrUndefined(this.highlightSettings.fill)
|
|
159
|
-
? this.highlightSettings.fill : targetEle.getAttribute('fill') : 'none',
|
|
165
|
+
fill: (targetEle.parentElement.id.indexOf('LineString') === -1) ? (targetEle.id.indexOf('NavigationIndex') === -1 ? !isNullOrUndefined(this.highlightSettings.fill)
|
|
166
|
+
? this.highlightSettings.fill : targetEle.getAttribute('fill') : 'none') : 'transparent',
|
|
160
167
|
border: border,
|
|
161
168
|
name: itemHighlight,
|
|
162
169
|
target: targetEle.id,
|
|
@@ -1,10 +1,14 @@
|
|
|
1
1
|
import { Maps } from '../../index';
|
|
2
|
+
import { SelectionSettingsModel } from '../index';
|
|
2
3
|
/**
|
|
3
4
|
* Selection module class
|
|
4
5
|
*/
|
|
5
6
|
export declare class Selection {
|
|
6
7
|
private maps;
|
|
7
|
-
|
|
8
|
+
/**
|
|
9
|
+
* @private
|
|
10
|
+
*/
|
|
11
|
+
selectionsettings: SelectionSettingsModel;
|
|
8
12
|
/**
|
|
9
13
|
* @private
|
|
10
14
|
*/
|
|
@@ -23,6 +27,10 @@ export declare class Selection {
|
|
|
23
27
|
*/
|
|
24
28
|
private removeEventListener;
|
|
25
29
|
private mouseClick;
|
|
30
|
+
/**
|
|
31
|
+
* @private
|
|
32
|
+
*/
|
|
33
|
+
selectElement(targetElement: Element, layerIndex: number, data: any, shapeData: any): void;
|
|
26
34
|
/**
|
|
27
35
|
* Public method for selection
|
|
28
36
|
*/
|
|
@@ -80,24 +80,31 @@ var Selection = /** @class */ (function () {
|
|
|
80
80
|
this.selectionType = 'navigationline';
|
|
81
81
|
}
|
|
82
82
|
if (this.selectionsettings.enable) {
|
|
83
|
-
this.
|
|
84
|
-
if (this.maps.legendSettings.visible && targetElement.id.indexOf('_MarkerIndex_') === -1) {
|
|
85
|
-
this.maps.legendModule.shapeHighLightAndSelection(targetElement, data, this.selectionsettings, 'selection', layerIndex);
|
|
86
|
-
}
|
|
87
|
-
var shapeToggled = (targetElement.id.indexOf('shapeIndex') > -1 && this.maps.legendSettings.visible) ?
|
|
88
|
-
this.maps.legendModule.shapeToggled : true;
|
|
89
|
-
if (shapeToggled) {
|
|
90
|
-
this.selectMap(targetElement, shapeData, data);
|
|
91
|
-
}
|
|
83
|
+
this.selectElement(targetElement, layerIndex, data, shapeData);
|
|
92
84
|
}
|
|
93
85
|
}
|
|
94
|
-
else if (this.maps.legendSettings.visible && !this.maps.legendSettings.toggleLegendSettings.enable &&
|
|
86
|
+
else if ((this.maps.legendSettings.visible && !this.maps.legendSettings.toggleLegendSettings.enable && this.maps.legendModule) &&
|
|
95
87
|
!isNullOrUndefined(targetElement.id) && targetElement.id.indexOf('_Text') === -1 &&
|
|
96
88
|
(targetElement.id.indexOf(this.maps.element.id + '_Legend_Shape_Index') > -1 ||
|
|
97
89
|
targetElement.id.indexOf(this.maps.element.id + '_Legend_Index') !== -1)) {
|
|
98
90
|
this.maps.legendModule.legendHighLightAndSelection(targetElement, 'selection');
|
|
99
91
|
}
|
|
100
92
|
};
|
|
93
|
+
/**
|
|
94
|
+
* @private
|
|
95
|
+
*/
|
|
96
|
+
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
97
|
+
Selection.prototype.selectElement = function (targetElement, layerIndex, data, shapeData) {
|
|
98
|
+
this.maps.mapSelect = targetElement ? true : false;
|
|
99
|
+
if (this.maps.legendModule && this.maps.legendSettings.visible && targetElement.id.indexOf('_MarkerIndex_') === -1) {
|
|
100
|
+
this.maps.legendModule.shapeHighLightAndSelection(targetElement, data, this.selectionsettings, 'selection', layerIndex);
|
|
101
|
+
}
|
|
102
|
+
var shapeToggled = (targetElement.id.indexOf('shapeIndex') > -1 && this.maps.legendSettings.visible && this.maps.legendModule) ?
|
|
103
|
+
this.maps.legendModule.shapeToggled : true;
|
|
104
|
+
if (shapeToggled) {
|
|
105
|
+
this.selectMap(targetElement, shapeData, data);
|
|
106
|
+
}
|
|
107
|
+
};
|
|
101
108
|
// eslint-disable-next-line valid-jsdoc
|
|
102
109
|
/**
|
|
103
110
|
* Public method for selection
|
|
@@ -122,18 +129,19 @@ var Selection = /** @class */ (function () {
|
|
|
122
129
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
123
130
|
Selection.prototype.selectMap = function (targetElement, shapeData, data) {
|
|
124
131
|
var _this = this;
|
|
132
|
+
var layerIndex = parseInt(targetElement.id.split('_LayerIndex_')[1].split('_')[0], 10);
|
|
125
133
|
var parentElement;
|
|
126
134
|
var children;
|
|
127
135
|
var selectionClass;
|
|
128
136
|
var selectionsettings = this.selectionsettings;
|
|
129
137
|
var border = {
|
|
130
|
-
color: this.selectionsettings.border.color,
|
|
131
|
-
width: this.selectionsettings.border.width / (this.selectionType === 'Marker' ? 1 : this.maps.scale),
|
|
138
|
+
color: (targetElement.parentElement.id.indexOf('LineString') === -1) ? this.selectionsettings.border.color : (this.selectionsettings.border.color || this.selectionsettings.fill),
|
|
139
|
+
width: (targetElement.parentElement.id.indexOf('LineString') === -1) ? (this.selectionsettings.border.width / (this.selectionType === 'Marker' ? 1 : this.maps.scale)) : (this.selectionsettings.border.width / this.maps.scale),
|
|
132
140
|
opacity: this.selectionsettings.border.opacity
|
|
133
141
|
};
|
|
134
142
|
var eventArgs = {
|
|
135
143
|
opacity: this.selectionsettings.opacity,
|
|
136
|
-
fill: this.selectionType !== 'navigationline' ? this.selectionsettings.fill : 'none',
|
|
144
|
+
fill: (targetElement.parentElement.id.indexOf('LineString') === -1) ? (this.selectionType !== 'navigationline' ? this.selectionsettings.fill : 'none') : 'transparent',
|
|
137
145
|
border: border,
|
|
138
146
|
name: itemSelection,
|
|
139
147
|
target: targetElement.id,
|
|
@@ -156,9 +164,9 @@ var Selection = /** @class */ (function () {
|
|
|
156
164
|
}
|
|
157
165
|
if (targetElement.id.indexOf('NavigationIndex') > -1) {
|
|
158
166
|
var index = parseInt(targetElement.id.split('_NavigationIndex_')[1].split('_')[0], 10);
|
|
159
|
-
var
|
|
160
|
-
targetElement.setAttribute('stroke-width', _this.maps.layers[
|
|
161
|
-
targetElement.setAttribute('stroke', _this.maps.layers[
|
|
167
|
+
var layerIndex_1 = parseInt(targetElement.parentElement.id.split('_LayerIndex_')[1].split('_')[0], 10);
|
|
168
|
+
targetElement.setAttribute('stroke-width', _this.maps.layers[layerIndex_1].navigationLineSettings[index].width.toString());
|
|
169
|
+
targetElement.setAttribute('stroke', _this.maps.layers[layerIndex_1].navigationLineSettings[index].color);
|
|
162
170
|
}
|
|
163
171
|
}
|
|
164
172
|
else {
|
|
@@ -184,9 +192,9 @@ var Selection = /** @class */ (function () {
|
|
|
184
192
|
}
|
|
185
193
|
if (ele.id.indexOf('NavigationIndex') > -1) {
|
|
186
194
|
var index = parseInt(targetElement.id.split('_NavigationIndex_')[1].split('_')[0], 10);
|
|
187
|
-
var
|
|
188
|
-
ele.setAttribute('stroke-width', _this.maps.layers[
|
|
189
|
-
ele.setAttribute('stroke', _this.maps.layers[
|
|
195
|
+
var layerIndex_2 = parseInt(targetElement.parentElement.id.split('_LayerIndex_')[1].split('_')[0], 10);
|
|
196
|
+
ele.setAttribute('stroke-width', _this.maps.layers[layerIndex_2].navigationLineSettings[index].width.toString());
|
|
197
|
+
ele.setAttribute('stroke', _this.maps.layers[layerIndex_2].navigationLineSettings[index].color);
|
|
190
198
|
}
|
|
191
199
|
}
|
|
192
200
|
if (!getElement(_this.selectionType + 'selectionMap')) {
|
|
@@ -54,8 +54,6 @@ var MapsTooltip = /** @class */ (function () {
|
|
|
54
54
|
if (istooltipRender) {
|
|
55
55
|
if (targetId.indexOf('_shapeIndex_') > -1) {
|
|
56
56
|
option = layer.tooltipSettings;
|
|
57
|
-
option.textStyle.fontFamily = this.maps.themeStyle.fontFamily || option.textStyle.fontFamily;
|
|
58
|
-
option.textStyle.opacity = this.maps.themeStyle.tooltipTextOpacity || option.textStyle.opacity;
|
|
59
57
|
var shape = parseInt(targetId.split('_shapeIndex_')[1].split('_')[0], 10);
|
|
60
58
|
if (isNullOrUndefined(layer.layerData) || isNullOrUndefined(layer.layerData[shape])) {
|
|
61
59
|
return;
|
|
@@ -172,9 +170,13 @@ var MapsTooltip = /** @class */ (function () {
|
|
|
172
170
|
option.template = option.template[Object.keys(option.template)[0]];
|
|
173
171
|
}
|
|
174
172
|
templateData = this.setTooltipContent(option, templateData);
|
|
173
|
+
var tooltipTextStyle = {
|
|
174
|
+
color: option.textStyle.color, fontFamily: option.textStyle.fontFamily, fontStyle: option.textStyle.fontStyle,
|
|
175
|
+
fontWeight: option.textStyle.fontWeight, opacity: option.textStyle.opacity, size: option.textStyle.size
|
|
176
|
+
};
|
|
175
177
|
var tooltipOption = {
|
|
176
178
|
location: location, text: tooltipContent, data: templateData,
|
|
177
|
-
textStyle:
|
|
179
|
+
textStyle: tooltipTextStyle,
|
|
178
180
|
template: option.template
|
|
179
181
|
};
|
|
180
182
|
tooltipArgs = {
|
|
@@ -190,6 +192,10 @@ var MapsTooltip = /** @class */ (function () {
|
|
|
190
192
|
_this.maps['isProtectedOnChange'] = true;
|
|
191
193
|
tooltipArgs.options['textStyle']['color'] = tooltipArgs.options['textStyle']['color']
|
|
192
194
|
|| _this.maps.themeStyle.tooltipFontColor;
|
|
195
|
+
tooltipArgs.options['textStyle']['fontFamily'] = tooltipArgs.options['textStyle']['fontFamily']
|
|
196
|
+
|| _this.maps.themeStyle.fontFamily;
|
|
197
|
+
tooltipArgs.options['textStyle']['opacity'] = tooltipArgs.options['textStyle']['opacity']
|
|
198
|
+
|| _this.maps.themeStyle.tooltipTextOpacity;
|
|
193
199
|
if (tooltipArgs.cancel) {
|
|
194
200
|
_this.svgTooltip = new Tooltip({
|
|
195
201
|
enable: true,
|
|
@@ -102,7 +102,11 @@ export declare class Zoom {
|
|
|
102
102
|
processTemplate(x: number, y: number, scale: number, maps: Maps): void;
|
|
103
103
|
private dataLabelTranslate;
|
|
104
104
|
private markerTranslate;
|
|
105
|
-
|
|
105
|
+
private markerLineAnimation;
|
|
106
|
+
/**
|
|
107
|
+
* @private
|
|
108
|
+
*/
|
|
109
|
+
panning(direction: PanDirection, xDifference: number, yDifference: number, mouseLocation?: PointerEvent | TouchEvent | KeyboardEvent): void;
|
|
106
110
|
private toAlignSublayer;
|
|
107
111
|
toolBarZooming(zoomFactor: number, type: string): void;
|
|
108
112
|
createZoomingToolbars(): void;
|