mapping-component-package-jp 0.1.4 → 0.1.7
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/AzuriteConfig +1 -0
- package/__azurite_db_table__.json +1 -0
- package/dist/index.d.ts +2 -0
- package/dist/index.js +1 -1
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +1 -1
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
- package/src/js/mapEncapsulation/mapOverlayManager.d.ts +2 -0
- package/src/js/mapEncapsulation/mapOverlayManager.js +33 -2
- package/src/js/mapEncapsulation/shapes/circle.sector.js +2 -6
- package/src/js/mapEncapsulation/shapes/circle.segment.js +25 -26
package/package.json
CHANGED
|
@@ -16,6 +16,7 @@ export class MapOverlayManager {
|
|
|
16
16
|
Shape_Delete(ShapeId: string | number, EventHandlers?: any): void;
|
|
17
17
|
Shape_DeleteAll(isMobile?: boolean): void;
|
|
18
18
|
Shape_Convert(ShapeId: string | number): string;
|
|
19
|
+
SelectedShape_GetType(ShapeId: string | number, shapeTypes: any): string;
|
|
19
20
|
|
|
20
21
|
// Rendering Methods
|
|
21
22
|
RenderFields(locations: any[], properties: any, editMode?: boolean): void;
|
|
@@ -43,6 +44,7 @@ export class MapOverlayManager {
|
|
|
43
44
|
// Field Management
|
|
44
45
|
TriggerField_ChangeEvent(): any;
|
|
45
46
|
DrawField_AttachEvents(eHandlers: any): void;
|
|
47
|
+
DrawField_DetachEvents(StrokeColor: string, SelectedShapeId: string): void;
|
|
46
48
|
clearBackgroundFields(): void;
|
|
47
49
|
checkForBackgroundFieldOverlaps(): boolean;
|
|
48
50
|
|
|
@@ -620,6 +620,22 @@ export class MapOverlayManager {
|
|
|
620
620
|
|
|
621
621
|
}
|
|
622
622
|
|
|
623
|
+
_this.SelectedShape_GetType = function (ShapeId, shapeTypes) {
|
|
624
|
+
var polygon = locPolygons.find(p => p.id == ShapeId);
|
|
625
|
+
|
|
626
|
+
if (polygon.id == ShapeId) {
|
|
627
|
+
if (polygon.isPolygon) {
|
|
628
|
+
return shapeTypes.ShapeTypeId_Polygon;
|
|
629
|
+
} else if (polygon.isCircle) {
|
|
630
|
+
return shapeTypes.ShapeTypeId_Circle;
|
|
631
|
+
} else if (polygon.isCircleSector) {
|
|
632
|
+
return shapeTypes.ShapeTypeId_CircleSector;
|
|
633
|
+
} else if (polygon.isCircleSegment) {
|
|
634
|
+
return shapeTypes.ShapeTypeId_CircleSegment;
|
|
635
|
+
}
|
|
636
|
+
}
|
|
637
|
+
}
|
|
638
|
+
|
|
623
639
|
|
|
624
640
|
_this.selectShape = function(shapeId, selectedStyle, unselectedStyle) {
|
|
625
641
|
console.log('Selecting shape:', shapeId);
|
|
@@ -899,7 +915,7 @@ export class MapOverlayManager {
|
|
|
899
915
|
zIndex: 10100,
|
|
900
916
|
clickable: true,
|
|
901
917
|
editable: false,
|
|
902
|
-
draggable:
|
|
918
|
+
draggable: true,
|
|
903
919
|
isPolygon: true,
|
|
904
920
|
isCircle: false,
|
|
905
921
|
isCircleSector: false,
|
|
@@ -2010,7 +2026,7 @@ export class MapOverlayManager {
|
|
|
2010
2026
|
return { perimeter, area, path };
|
|
2011
2027
|
}
|
|
2012
2028
|
|
|
2013
|
-
_this.DrawField_AttachEvents = function (eHandlers) {
|
|
2029
|
+
_this.DrawField_AttachEvents = function (eHandlers, ShapeId, StrokeColor) {
|
|
2014
2030
|
|
|
2015
2031
|
locPolygons.forEach(function (polygon) {
|
|
2016
2032
|
|
|
@@ -2028,10 +2044,25 @@ export class MapOverlayManager {
|
|
|
2028
2044
|
eHandlers["ShapeSelect"](this.id);
|
|
2029
2045
|
});
|
|
2030
2046
|
polygonListeners.push(mclListener);
|
|
2047
|
+
|
|
2048
|
+
if (polygon.id == ShapeId && StrokeColor !== undefined) {
|
|
2049
|
+
polygon.setOptions({ strokeColor: StrokeColor, strokeWeight: 3 });
|
|
2050
|
+
}
|
|
2051
|
+
|
|
2031
2052
|
});
|
|
2032
2053
|
|
|
2033
2054
|
}
|
|
2034
2055
|
|
|
2056
|
+
_this.DrawField_DetachEvents = function (StrokeColor, SelectedShapeId) {
|
|
2057
|
+
polygonListeners_clear();
|
|
2058
|
+
|
|
2059
|
+
locPolygons.forEach(function (polygon) {
|
|
2060
|
+
if(polygon.id == SelectedShapeId) {
|
|
2061
|
+
polygon.setOptions({ strokeColor: StrokeColor });
|
|
2062
|
+
}
|
|
2063
|
+
});
|
|
2064
|
+
}
|
|
2065
|
+
|
|
2035
2066
|
_this.PolygonCustomEdit_Edit = function (ShapeId, isMobile) {
|
|
2036
2067
|
var polygonCE = locPolygons.find(p => p.id == ShapeId);
|
|
2037
2068
|
if (polygonCE) {
|
|
@@ -204,7 +204,7 @@ export class IQLCircleSector {
|
|
|
204
204
|
anchor: new google.maps.Point(4, 4),
|
|
205
205
|
strokeWeight: 1,
|
|
206
206
|
strokeOpacity: 1,
|
|
207
|
-
strokeColor:
|
|
207
|
+
strokeColor: '#303030',
|
|
208
208
|
scale: 1,
|
|
209
209
|
id: 'startPinIcon'
|
|
210
210
|
};
|
|
@@ -216,7 +216,7 @@ export class IQLCircleSector {
|
|
|
216
216
|
anchor: new google.maps.Point(4, 4),
|
|
217
217
|
strokeWeight: 1,
|
|
218
218
|
strokeOpacity: 1,
|
|
219
|
-
strokeColor:
|
|
219
|
+
strokeColor: '#303030',
|
|
220
220
|
scale: 1,
|
|
221
221
|
id: 'endPinIcon'
|
|
222
222
|
};
|
|
@@ -247,10 +247,6 @@ export class IQLCircleSector {
|
|
|
247
247
|
scale: 1,
|
|
248
248
|
id: 'handleIcon'
|
|
249
249
|
};
|
|
250
|
-
*/
|
|
251
|
-
/*
|
|
252
|
-
*/
|
|
253
|
-
/*
|
|
254
250
|
*/
|
|
255
251
|
|
|
256
252
|
function DistanceWidget(map, cs) {
|
|
@@ -206,6 +206,31 @@ export class IQLCircleSegment {
|
|
|
206
206
|
scale: 1,
|
|
207
207
|
id: 'centerIcon'
|
|
208
208
|
};
|
|
209
|
+
|
|
210
|
+
var startPinIcon = {
|
|
211
|
+
path: 'M4 4m-4,0a4,4,0 0,1 8,0a 4,4 0 0,1 -8,0z',
|
|
212
|
+
fillColor: '#ffffff',
|
|
213
|
+
fillOpacity: 1,
|
|
214
|
+
anchor: new google.maps.Point(4, 4),
|
|
215
|
+
strokeWeight: 1,
|
|
216
|
+
strokeOpacity: 1,
|
|
217
|
+
strokeColor: '#303030',
|
|
218
|
+
scale: 1,
|
|
219
|
+
id: 'startPinIcon'
|
|
220
|
+
};
|
|
221
|
+
|
|
222
|
+
var endPinIcon = {
|
|
223
|
+
path: 'M4 4m-4,0a4,4,0 0,1 8,0a 4,4 0 0,1 -8,0z',
|
|
224
|
+
fillColor: '#ffffff',
|
|
225
|
+
fillOpacity: 1,
|
|
226
|
+
anchor: new google.maps.Point(4, 4),
|
|
227
|
+
strokeWeight: 1,
|
|
228
|
+
strokeOpacity: 1,
|
|
229
|
+
strokeColor: '#303030',
|
|
230
|
+
scale: 1,
|
|
231
|
+
id: 'endPinIcon'
|
|
232
|
+
};
|
|
233
|
+
|
|
209
234
|
}
|
|
210
235
|
|
|
211
236
|
|
|
@@ -232,32 +257,6 @@ export class IQLCircleSegment {
|
|
|
232
257
|
scale: 1,
|
|
233
258
|
id: 'handleIcon'
|
|
234
259
|
};
|
|
235
|
-
*/
|
|
236
|
-
/*
|
|
237
|
-
var startPinIcon = {
|
|
238
|
-
path: 'M4 4m-4,0a4,4,0 0,1 8,0a 4,4 0 0,1 -8,0z',
|
|
239
|
-
fillColor: '#ffffff',
|
|
240
|
-
fillOpacity: 1,
|
|
241
|
-
anchor: new google.maps.Point(4, 4),
|
|
242
|
-
strokeWeight: 1,
|
|
243
|
-
strokeOpacity: 1,
|
|
244
|
-
strokeColor: cs.strokeColor,
|
|
245
|
-
scale: 1,
|
|
246
|
-
id: 'startPinIcon'
|
|
247
|
-
};
|
|
248
|
-
*/
|
|
249
|
-
/*
|
|
250
|
-
var endPinIcon = {
|
|
251
|
-
path: 'M4 4m-4,0a4,4,0 0,1 8,0a 4,4 0 0,1 -8,0z',
|
|
252
|
-
fillColor: '#ffffff',
|
|
253
|
-
fillOpacity: 1,
|
|
254
|
-
anchor: new google.maps.Point(4, 4),
|
|
255
|
-
strokeWeight: 1,
|
|
256
|
-
strokeOpacity: 1,
|
|
257
|
-
strokeColor: cs.strokeColor,
|
|
258
|
-
scale: 1,
|
|
259
|
-
id: 'endPinIcon'
|
|
260
|
-
};
|
|
261
260
|
*/
|
|
262
261
|
function DistanceWidget(map, cs) {
|
|
263
262
|
|