@mint-ui/map 0.1.7-beta → 0.1.9-beta

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.
Files changed (36) hide show
  1. package/.eslintrc.js +109 -109
  2. package/LICENSE +21 -21
  3. package/README.md +53 -53
  4. package/dist/components/mint-map/MintMap.d.ts +92 -88
  5. package/dist/components/mint-map/MintMap.js +42 -11
  6. package/dist/components/mint-map/core/MintMapController.d.ts +33 -32
  7. package/dist/components/mint-map/core/MintMapCore.d.ts +3 -3
  8. package/dist/components/mint-map/core/MintMapCore.js +10 -0
  9. package/dist/components/mint-map/core/advanced/MapBuildingProjection.d.ts +15 -15
  10. package/dist/components/mint-map/core/advanced/index.d.ts +1 -1
  11. package/dist/components/mint-map/core/hooks/MarkerMovingHook.d.ts +6 -6
  12. package/dist/components/mint-map/core/hooks/index.d.ts +1 -1
  13. package/dist/components/mint-map/core/index.d.ts +7 -7
  14. package/dist/components/mint-map/core/provider/MintMapProvider.d.ts +8 -8
  15. package/dist/components/mint-map/core/provider/index.d.ts +1 -1
  16. package/dist/components/mint-map/core/util/animation.d.ts +16 -16
  17. package/dist/components/mint-map/core/util/calculate.d.ts +34 -29
  18. package/dist/components/mint-map/core/util/calculate.js +68 -8
  19. package/dist/components/mint-map/core/util/index.d.ts +3 -3
  20. package/dist/components/mint-map/core/util/waiting.d.ts +1 -1
  21. package/dist/components/mint-map/core/wrapper/MapControlWrapper.d.ts +11 -11
  22. package/dist/components/mint-map/core/wrapper/MapMarkerWrapper.d.ts +23 -23
  23. package/dist/components/mint-map/core/wrapper/MapMarkerWrapper.js +2 -4
  24. package/dist/components/mint-map/core/wrapper/MapPolygonWrapper.d.ts +5 -5
  25. package/dist/components/mint-map/core/wrapper/MapPolylineWrapper.d.ts +5 -5
  26. package/dist/components/mint-map/core/wrapper/index.d.ts +4 -4
  27. package/dist/components/mint-map/google/GoogleMintMapController.d.ts +35 -34
  28. package/dist/components/mint-map/google/GoogleMintMapController.js +19 -8
  29. package/dist/components/mint-map/index.d.ts +4 -4
  30. package/dist/components/mint-map/naver/NaverMintMapController.d.ts +38 -36
  31. package/dist/components/mint-map/naver/NaverMintMapController.js +45 -11
  32. package/dist/index.d.ts +1 -1
  33. package/dist/index.es.js +186 -42
  34. package/dist/index.umd.js +186 -42
  35. package/package.json +76 -76
  36. package/test.ts +6 -6
@@ -1,32 +1,33 @@
1
- import { Bounds, Drawable, MapType, MapVendorType, Marker, MarkerOptions, MintMapProps, Polygon, PolygonOptions, Polyline, PolylineOptions, Position } from "../MintMap";
2
- export declare abstract class MintMapController {
3
- abstract type: MapType;
4
- abstract map: MapVendorType | null;
5
- abstract scriptUrl: string;
6
- abstract initializingMap(divElement: HTMLDivElement): Promise<MapVendorType>;
7
- abstract destroyMap(): void;
8
- abstract loadMapApi(): Promise<boolean>;
9
- abstract getCurrBounds(): Bounds;
10
- abstract panningTo(targetCenter: Position): void;
11
- abstract getZoomLevel(): number;
12
- abstract createMarker(marker: Marker): void;
13
- abstract updateMarker(marker: Marker, options: MarkerOptions): void;
14
- abstract clearDrawable(drawable: Drawable): boolean;
15
- abstract markerToTheTop(marker: Marker): void;
16
- abstract isMapDragged(): boolean;
17
- abstract setMapDragged(value: boolean): void;
18
- abstract createPolyline(polyline: Polyline): void;
19
- abstract updatePolyline(polyline: Polyline, options: PolylineOptions): void;
20
- abstract createPolygon(polygon: Polygon): void;
21
- abstract updatePolygon(polygon: Polygon, options: PolygonOptions): void;
22
- mapProps: MintMapProps;
23
- mapApiLoaded: boolean;
24
- mapInitialized: boolean;
25
- constructor(props: MintMapProps);
26
- getMap(): MapVendorType | null;
27
- getMapType(): MapType;
28
- loadScript(url: string, id?: string): Promise<void>;
29
- buildUrl(baseUrl: string, param: {
30
- [key: string]: string | string[];
31
- }): string;
32
- }
1
+ import { Bounds, Drawable, MapType, MapVendorType, Marker, MarkerOptions, MintMapProps, Polygon, PolygonOptions, Polyline, PolylineOptions, Position } from "../MintMap";
2
+ export declare abstract class MintMapController {
3
+ abstract type: MapType;
4
+ abstract map: MapVendorType | null;
5
+ abstract scriptUrl: string;
6
+ abstract initializingMap(divElement: HTMLDivElement): Promise<MapVendorType>;
7
+ abstract destroyMap(): void;
8
+ abstract loadMapApi(): Promise<boolean>;
9
+ abstract getCurrBounds(): Bounds;
10
+ abstract panningTo(targetCenter: Position): void;
11
+ abstract getZoomLevel(): number;
12
+ abstract setZoomLevel(zoom: number): void;
13
+ abstract createMarker(marker: Marker): void;
14
+ abstract updateMarker(marker: Marker, options: MarkerOptions): void;
15
+ abstract clearDrawable(drawable: Drawable): boolean;
16
+ abstract markerToTheTop(marker: Marker): void;
17
+ abstract isMapDragged(): boolean;
18
+ abstract setMapDragged(value: boolean): void;
19
+ abstract createPolyline(polyline: Polyline): void;
20
+ abstract updatePolyline(polyline: Polyline, options: PolylineOptions): void;
21
+ abstract createPolygon(polygon: Polygon): void;
22
+ abstract updatePolygon(polygon: Polygon, options: PolygonOptions): void;
23
+ mapProps: MintMapProps;
24
+ mapApiLoaded: boolean;
25
+ mapInitialized: boolean;
26
+ constructor(props: MintMapProps);
27
+ getMap(): MapVendorType | null;
28
+ getMapType(): MapType;
29
+ loadScript(url: string, id?: string): Promise<void>;
30
+ buildUrl(baseUrl: string, param: {
31
+ [key: string]: string | string[];
32
+ }): string;
33
+ }
@@ -1,3 +1,3 @@
1
- import { PropsWithChildren } from "react";
2
- import { MintMapProps } from "../MintMap";
3
- export declare function MintMapCore({ onLoad, visible, children }: PropsWithChildren<MintMapProps>): JSX.Element;
1
+ import { PropsWithChildren } from "react";
2
+ import { MintMapProps } from "../MintMap";
3
+ export declare function MintMapCore({ onLoad, visible, base, children }: PropsWithChildren<MintMapProps>): JSX.Element;
@@ -20,6 +20,7 @@ function MintMapCore(_a) {
20
20
  var onLoad = _a.onLoad,
21
21
  _b = _a.visible,
22
22
  visible = _b === void 0 ? true : _b,
23
+ base = _a.base,
23
24
  children = _a.children;
24
25
  var controller = MintMapProvider.useMintMapController();
25
26
  var elementRef = React.useRef(null);
@@ -57,6 +58,15 @@ function MintMapCore(_a) {
57
58
  controller && controller.destroyMap();
58
59
  };
59
60
  }, [controller, elementRef]);
61
+ React.useEffect(function () {
62
+ if ((base === null || base === void 0 ? void 0 : base.zoomLevel) && controller && mapInitialized) {
63
+ var prevZoomLevel = controller === null || controller === void 0 ? void 0 : controller.getZoomLevel();
64
+
65
+ if (prevZoomLevel !== base.zoomLevel) {
66
+ controller === null || controller === void 0 ? void 0 : controller.setZoomLevel(base.zoomLevel);
67
+ }
68
+ }
69
+ }, [base]);
60
70
  return React__default["default"].createElement("div", {
61
71
  className: cn('mint-map-root'),
62
72
  style: {
@@ -1,15 +1,15 @@
1
- /// <reference types="react" />
2
- import { Position } from "../../MintMap";
3
- interface MapBuildingProjectionProps {
4
- basePolygonPath: Position[];
5
- numberOfFloor: number;
6
- heightOfFloor?: number;
7
- lineColor?: string;
8
- lineOpacity?: number;
9
- fillColor?: string;
10
- fillOpacity?: number;
11
- title?: string;
12
- titleElement?: JSX.Element;
13
- }
14
- export declare function MapBuildingProjection(props: MapBuildingProjectionProps): JSX.Element;
15
- export {};
1
+ /// <reference types="react" />
2
+ import { Position } from "../../MintMap";
3
+ interface MapBuildingProjectionProps {
4
+ basePolygonPath: Position[];
5
+ numberOfFloor: number;
6
+ heightOfFloor?: number;
7
+ lineColor?: string;
8
+ lineOpacity?: number;
9
+ fillColor?: string;
10
+ fillOpacity?: number;
11
+ title?: string;
12
+ titleElement?: JSX.Element;
13
+ }
14
+ export declare function MapBuildingProjection(props: MapBuildingProjectionProps): JSX.Element;
15
+ export {};
@@ -1 +1 @@
1
- export * from './MapBuildingProjection';
1
+ export * from './MapBuildingProjection';
@@ -1,6 +1,6 @@
1
- import { Marker } from "../../MintMap";
2
- import { MapMarkerMoving } from "../wrapper/MapMarkerWrapper";
3
- export interface MapMarkerMovingHookProps extends MapMarkerMoving {
4
- marker?: Marker;
5
- }
6
- export declare function useMarkerMoving({ marker, positions, positionClosed, loop, fps, startPositionIndex, velocity, onMovingStart, onMovingEnd }: MapMarkerMovingHookProps): (() => void)[];
1
+ import { Marker } from "../../MintMap";
2
+ import { MapMarkerMoving } from "../wrapper/MapMarkerWrapper";
3
+ export interface MapMarkerMovingHookProps extends MapMarkerMoving {
4
+ marker?: Marker;
5
+ }
6
+ export declare function useMarkerMoving({ marker, positions, positionClosed, loop, fps, startPositionIndex, velocity, onMovingStart, onMovingEnd }: MapMarkerMovingHookProps): (() => void)[];
@@ -1 +1 @@
1
- export * from "./MarkerMovingHook";
1
+ export * from "./MarkerMovingHook";
@@ -1,7 +1,7 @@
1
- export * from "./MintMapCore";
2
- export * from "./MintMapController";
3
- export * from "./advanced";
4
- export * from "./hooks";
5
- export * from "./provider";
6
- export * from './util';
7
- export * from './wrapper';
1
+ export * from "./MintMapCore";
2
+ export * from "./MintMapController";
3
+ export * from "./advanced";
4
+ export * from "./hooks";
5
+ export * from "./provider";
6
+ export * from './util';
7
+ export * from './wrapper';
@@ -1,8 +1,8 @@
1
- import { PropsWithChildren } from "react";
2
- import { MintMapController } from "../MintMapController";
3
- interface MintMapProviderProps {
4
- controller: MintMapController;
5
- }
6
- export declare function MintMapProvider({ controller, children }: PropsWithChildren<MintMapProviderProps>): JSX.Element;
7
- export declare function useMintMapController(): MintMapController;
8
- export {};
1
+ import { PropsWithChildren } from "react";
2
+ import { MintMapController } from "../MintMapController";
3
+ interface MintMapProviderProps {
4
+ controller: MintMapController;
5
+ }
6
+ export declare function MintMapProvider({ controller, children }: PropsWithChildren<MintMapProviderProps>): JSX.Element;
7
+ export declare function useMintMapController(): MintMapController;
8
+ export {};
@@ -1 +1 @@
1
- export * from "./MintMapProvider";
1
+ export * from "./MintMapProvider";
@@ -1,16 +1,16 @@
1
- export declare type DrawFunction = (frameGapTime: number, elapsedTime: number) => boolean | undefined;
2
- export declare class AnimationPlayer {
3
- prevtime: number;
4
- elapsedTime: number;
5
- fps: number | null;
6
- baseDrawGapTime: number | null;
7
- private deltaTime;
8
- private playing;
9
- draw: DrawFunction;
10
- constructor(drawFunction: DrawFunction, fps?: number);
11
- init(): void;
12
- start(): void;
13
- stop(): void;
14
- resume(): void;
15
- makeFrame(timestamp: number): void;
16
- }
1
+ export declare type DrawFunction = (frameGapTime: number, elapsedTime: number) => boolean | undefined;
2
+ export declare class AnimationPlayer {
3
+ prevtime: number;
4
+ elapsedTime: number;
5
+ fps: number | null;
6
+ baseDrawGapTime: number | null;
7
+ private deltaTime;
8
+ private playing;
9
+ draw: DrawFunction;
10
+ constructor(drawFunction: DrawFunction, fps?: number);
11
+ init(): void;
12
+ start(): void;
13
+ stop(): void;
14
+ resume(): void;
15
+ makeFrame(timestamp: number): void;
16
+ }
@@ -1,29 +1,34 @@
1
- import { Position } from "../../MintMap";
2
- export declare class PolygonCalculator {
3
- static getCenter(positions: Position[]): Position;
4
- static intersects(positions1: Position[], positions2: Position[]): boolean;
5
- private static convertPositionToPoints;
6
- private static findCrossPoint;
7
- }
8
- export interface NextPositionContext {
9
- pos1: Position;
10
- pos2: Position;
11
- velocityKmh: number;
12
- elapsedTimeMs: number;
13
- totalDistance: number;
14
- currDistance: number;
15
- distanceRemain: number;
16
- prevPos2: Position;
17
- prevVelocityKmh: number;
18
- vPerMs: number;
19
- nextPos: Position;
20
- }
21
- export declare class GeoCalulator {
22
- private static readonly EARTH_RADIUS;
23
- private static readonly LATITUDE_POSITION_VALUE_PER_METER;
24
- static computeDistanceKiloMeter(pos1: Position, pos2: Position): number;
25
- private static deg2rad;
26
- static convertMeterToLatitudeValue(meter: number): number;
27
- private static readonly MS_FROM_HOUR;
28
- static computeNextPositionAndDistances(context: NextPositionContext): NextPositionContext;
29
- }
1
+ import { Position } from "../../MintMap";
2
+ export declare class PolygonCalculator {
3
+ static getCenter(positions: Position[]): Position;
4
+ static intersects(positions1: Position[], positions2: Position[]): boolean;
5
+ static getIncludedPositions(polygon: Position[], position: Position | Position[]): Position[];
6
+ private static convertPolygonToLinePoints;
7
+ private static convertPositionToPoints;
8
+ private static getCrossPoint;
9
+ private static toFixedPosition;
10
+ private static getCrossPointAll;
11
+ private static findCrossPoint;
12
+ }
13
+ export interface NextPositionContext {
14
+ pos1: Position;
15
+ pos2: Position;
16
+ velocityKmh: number;
17
+ elapsedTimeMs: number;
18
+ totalDistance: number;
19
+ currDistance: number;
20
+ distanceRemain: number;
21
+ prevPos2: Position;
22
+ prevVelocityKmh: number;
23
+ vPerMs: number;
24
+ nextPos: Position;
25
+ }
26
+ export declare class GeoCalulator {
27
+ private static readonly EARTH_RADIUS;
28
+ private static readonly LATITUDE_POSITION_VALUE_PER_METER;
29
+ static computeDistanceKiloMeter(pos1: Position, pos2: Position): number;
30
+ private static deg2rad;
31
+ static convertMeterToLatitudeValue(meter: number): number;
32
+ private static readonly MS_FROM_HOUR;
33
+ static computeNextPositionAndDistances(context: NextPositionContext): NextPositionContext;
34
+ }
@@ -66,22 +66,82 @@ var PolygonCalculator = function () {
66
66
  return false;
67
67
  };
68
68
 
69
+ PolygonCalculator.getIncludedPositions = function (polygon, position) {
70
+ var targets = Array.isArray(position) ? position : [position];
71
+ var result = [];
72
+ var maxX = Math.max.apply(Math, polygon.map(function (pos) {
73
+ return pos.lng;
74
+ })) + 1;
75
+ var lines = this.convertPolygonToLinePoints(polygon);
76
+
77
+ for (var _i = 0, targets_1 = targets; _i < targets_1.length; _i++) {
78
+ var target = targets_1[_i];
79
+ var tempLine = this.convertPositionToPoints(target, new MintMap.Position(target.lat, maxX));
80
+ var crossPoints = this.getCrossPointAll(lines, tempLine);
81
+
82
+ if (crossPoints.length > 0 && crossPoints.length % 2 != 0) {
83
+ result.push(target);
84
+ }
85
+ }
86
+
87
+ return result;
88
+ };
89
+
90
+ PolygonCalculator.convertPolygonToLinePoints = function (polygon) {
91
+ var lines = [];
92
+
93
+ for (var i = 0; i < polygon.length; i++) {
94
+ lines.push(this.convertPositionToPoints(polygon[i], polygon[i + 1 === polygon.length ? 0 : i + 1]));
95
+ }
96
+
97
+ return lines;
98
+ };
99
+
69
100
  PolygonCalculator.convertPositionToPoints = function (pos1, pos2) {
70
101
  return new LinePoints(pos1.lng, pos1.lat, pos2.lng, pos2.lat);
71
102
  };
72
103
 
73
- PolygonCalculator.findCrossPoint = function (sr, tr) {
104
+ PolygonCalculator.getCrossPoint = function (sr, tr) {
105
+ var p1 = (sr.x1 - sr.x2) * (tr.y1 - tr.y2) - (sr.y1 - sr.y2) * (tr.x1 - tr.x2);
106
+
107
+ if (p1 != 0) {
108
+ var x = ((sr.x1 * sr.y2 - sr.y1 * sr.x2) * (tr.x1 - tr.x2) - (sr.x1 - sr.x2) * (tr.x1 * tr.y2 - tr.y1 * tr.x2)) / p1;
109
+ var y = ((sr.x1 * sr.y2 - sr.y1 * sr.x2) * (tr.y1 - tr.y2) - (sr.y1 - sr.y2) * (tr.x1 * tr.y2 - tr.y1 * tr.x2)) / p1;
110
+
111
+ if (this.toFixedPosition((x - sr.x1) * (x - sr.x2)) <= 0 && this.toFixedPosition((y - sr.y1) * (y - sr.y2)) <= 0 && this.toFixedPosition((x - tr.x1) * (x - tr.x2)) <= 0 && this.toFixedPosition((y - tr.y1) * (y - tr.y2)) <= 0) {
112
+ return {
113
+ x: x,
114
+ y: y
115
+ };
116
+ }
117
+ }
118
+ };
119
+
120
+ PolygonCalculator.toFixedPosition = function (n) {
121
+ return Number(n.toFixed(15));
122
+ };
123
+
124
+ PolygonCalculator.getCrossPointAll = function (sr, tr) {
125
+ var result = [];
126
+
74
127
  for (var _i = 0, sr_1 = sr; _i < sr_1.length; _i++) {
75
128
  var tmp = sr_1[_i];
76
- var p1 = (tmp.x1 - tmp.x2) * (tr.y1 - tr.y2) - (tmp.y1 - tmp.y2) * (tr.x1 - tr.x2);
129
+ var p = this.getCrossPoint(tmp, tr);
77
130
 
78
- if (p1 != 0) {
79
- var x = ((tmp.x1 * tmp.y2 - tmp.y1 * tmp.x2) * (tr.x1 - tr.x2) - (tmp.x1 - tmp.x2) * (tr.x1 * tr.y2 - tr.y1 * tr.x2)) / p1;
80
- var y = ((tmp.x1 * tmp.y2 - tmp.y1 * tmp.x2) * (tr.y1 - tr.y2) - (tmp.y1 - tmp.y2) * (tr.x1 * tr.y2 - tr.y1 * tr.x2)) / p1;
131
+ if (p) {
132
+ result.push(p);
133
+ }
134
+ }
135
+
136
+ return result;
137
+ };
81
138
 
82
- if ((x - tmp.x1) * (x - tmp.x2) <= 0 && (y - tmp.y1) * (y - tmp.y2) <= 0 && (x - tr.x1) * (x - tr.x2) <= 0 && (y - tr.y1) * (y - tr.y2) <= 0) {
83
- return true;
84
- }
139
+ PolygonCalculator.findCrossPoint = function (sr, tr) {
140
+ for (var _i = 0, sr_2 = sr; _i < sr_2.length; _i++) {
141
+ var tmp = sr_2[_i];
142
+
143
+ if (this.getCrossPoint(tmp, tr)) {
144
+ return true;
85
145
  }
86
146
  }
87
147
 
@@ -1,3 +1,3 @@
1
- export * from './animation';
2
- export * from './calculate';
3
- export * from './waiting';
1
+ export * from './animation';
2
+ export * from './calculate';
3
+ export * from './waiting';
@@ -1 +1 @@
1
- export declare function waiting(evaluation: () => boolean, timeoutSeconds?: number): Promise<boolean>;
1
+ export declare function waiting(evaluation: () => boolean, timeoutSeconds?: number): Promise<boolean>;
@@ -1,11 +1,11 @@
1
- import { PropsWithChildren } from "react";
2
- declare type AlignHorizontal = 'left' | 'right' | 'center';
3
- declare type AlignVertical = 'top' | 'bottom' | 'center';
4
- export interface MapControlWrapperProps {
5
- width?: number | string;
6
- height?: number | string;
7
- positionHorizontal?: AlignHorizontal;
8
- positionVertical?: AlignVertical;
9
- }
10
- export declare function MapControlWrapper({ width, height, positionHorizontal, positionVertical, children }: PropsWithChildren<MapControlWrapperProps>): JSX.Element;
11
- export {};
1
+ import { PropsWithChildren } from "react";
2
+ declare type AlignHorizontal = 'left' | 'right' | 'center';
3
+ declare type AlignVertical = 'top' | 'bottom' | 'center';
4
+ export interface MapControlWrapperProps {
5
+ width?: number | string;
6
+ height?: number | string;
7
+ positionHorizontal?: AlignHorizontal;
8
+ positionVertical?: AlignVertical;
9
+ }
10
+ export declare function MapControlWrapper({ width, height, positionHorizontal, positionVertical, children }: PropsWithChildren<MapControlWrapperProps>): JSX.Element;
11
+ export {};
@@ -1,23 +1,23 @@
1
- import { PropsWithChildren } from "react";
2
- import { MarkerOptions, Position } from "../../MintMap";
3
- export declare type MovingEventFunciton = () => void;
4
- export interface MapMarkerMoving {
5
- positions?: Position[];
6
- positionClosed?: boolean;
7
- startPositionIndex?: number;
8
- velocity?: number;
9
- loop?: boolean;
10
- delay?: number;
11
- autoStart?: boolean;
12
- fps?: number;
13
- onMovingStart?: MovingEventFunciton;
14
- onMovingEnd?: MovingEventFunciton;
15
- }
16
- export interface MapMarkerWrapperProps extends MarkerOptions {
17
- topOnClick?: boolean;
18
- topOnHover?: boolean;
19
- startAnimationClassName?: string;
20
- endAnimationClassName?: string;
21
- movingAnimation?: MapMarkerMoving;
22
- }
23
- export declare function MapMarkerWrapper({ startAnimationClassName, endAnimationClassName, topOnClick, topOnHover, movingAnimation, children, ...options }: PropsWithChildren<MapMarkerWrapperProps>): JSX.Element;
1
+ import { PropsWithChildren } from "react";
2
+ import { MarkerOptions, Position } from "../../MintMap";
3
+ export declare type MovingEventFunciton = () => void;
4
+ export interface MapMarkerMoving {
5
+ positions?: Position[];
6
+ positionClosed?: boolean;
7
+ startPositionIndex?: number;
8
+ velocity?: number;
9
+ loop?: boolean;
10
+ delay?: number;
11
+ autoStart?: boolean;
12
+ fps?: number;
13
+ onMovingStart?: MovingEventFunciton;
14
+ onMovingEnd?: MovingEventFunciton;
15
+ }
16
+ export interface MapMarkerWrapperProps extends MarkerOptions {
17
+ topOnClick?: boolean;
18
+ topOnHover?: boolean;
19
+ startAnimationClassName?: string;
20
+ endAnimationClassName?: string;
21
+ movingAnimation?: MapMarkerMoving;
22
+ }
23
+ export declare function MapMarkerWrapper({ startAnimationClassName, endAnimationClassName, topOnClick, topOnHover, movingAnimation, children, ...options }: PropsWithChildren<MapMarkerWrapperProps>): JSX.Element;
@@ -100,7 +100,7 @@ function MapMarkerWrapper(_a) {
100
100
  divCloneRef.current && divCloneRef.current.removeEventListener('animationend', aniListener_1);
101
101
 
102
102
  if (markerRef.current) {
103
- console.log('drawable cleared', controller.clearDrawable(markerRef.current));
103
+ controller.clearDrawable(markerRef.current);
104
104
  }
105
105
 
106
106
  divCloneRef.current = undefined;
@@ -113,7 +113,7 @@ function MapMarkerWrapper(_a) {
113
113
  divElement.removeEventListener('mouseover', onMouseOverHandler);
114
114
 
115
115
  if (markerRef.current) {
116
- console.log('drawable cleared', controller.clearDrawable(markerRef.current));
116
+ controller.clearDrawable(markerRef.current);
117
117
  }
118
118
  }
119
119
  };
@@ -121,11 +121,9 @@ function MapMarkerWrapper(_a) {
121
121
  React.useEffect(function () {
122
122
  if (options) {
123
123
  if (markerRef.current) {
124
- console.log('update Marker');
125
124
  controller.updateMarker(markerRef.current, options);
126
125
  offsetCalibration(controller.getMapType(), divElement, options);
127
126
  } else {
128
- console.log('create Marker');
129
127
  markerRef.current = new MintMap.Marker(options);
130
128
  markerRef.current.element = divElement;
131
129
  controller.createMarker(markerRef.current);
@@ -1,5 +1,5 @@
1
- import { PropsWithChildren } from "react";
2
- import { PolygonOptions } from "../../MintMap";
3
- export interface MapPolygonWrapperProps extends PolygonOptions {
4
- }
5
- export declare function MapPolygonWrapper({ children, ...options }: PropsWithChildren<MapPolygonWrapperProps>): JSX.Element;
1
+ import { PropsWithChildren } from "react";
2
+ import { PolygonOptions } from "../../MintMap";
3
+ export interface MapPolygonWrapperProps extends PolygonOptions {
4
+ }
5
+ export declare function MapPolygonWrapper({ children, ...options }: PropsWithChildren<MapPolygonWrapperProps>): JSX.Element;
@@ -1,5 +1,5 @@
1
- import { PropsWithChildren } from "react";
2
- import { PolylineOptions } from "../../MintMap";
3
- export interface MapPolylineWrapperProps extends PolylineOptions {
4
- }
5
- export declare function MapPolylineWrapper({ children, ...options }: PropsWithChildren<MapPolylineWrapperProps>): JSX.Element;
1
+ import { PropsWithChildren } from "react";
2
+ import { PolylineOptions } from "../../MintMap";
3
+ export interface MapPolylineWrapperProps extends PolylineOptions {
4
+ }
5
+ export declare function MapPolylineWrapper({ children, ...options }: PropsWithChildren<MapPolylineWrapperProps>): JSX.Element;
@@ -1,4 +1,4 @@
1
- export * from './MapControlWrapper';
2
- export * from './MapMarkerWrapper';
3
- export * from './MapPolygonWrapper';
4
- export * from './MapPolylineWrapper';
1
+ export * from './MapControlWrapper';
2
+ export * from './MapMarkerWrapper';
3
+ export * from './MapPolygonWrapper';
4
+ export * from './MapPolylineWrapper';
@@ -1,34 +1,35 @@
1
- /// <reference types="google.maps" />
2
- import { MintMapController } from "../core/MintMapController";
3
- import { Bounds, Drawable, MapType, MapVendorType, Marker, MarkerOptions, MintMapProps, Polygon, PolygonOptions, Polyline, PolylineOptions, Position } from "../MintMap";
4
- export declare class GoogleMintMapController extends MintMapController {
5
- type: MapType;
6
- map: google.maps.Map | null;
7
- scriptUrl: string;
8
- scriptModules: string[];
9
- constructor(props: MintMapProps);
10
- polylineEvents: string[];
11
- createPolyline(polyline: Polyline): void;
12
- updatePolyline(polyline: Polyline, options: PolylineOptions): void;
13
- polygonEvents: string[];
14
- createPolygon(polygon: Polygon): void;
15
- updatePolygon(polygon: Polygon, options: PolygonOptions): void;
16
- private getValidOptions;
17
- markerEvents: string[];
18
- createMarker(marker: Marker): void;
19
- updateMarker(marker: Marker, options: MarkerOptions): void;
20
- private markerMaxZIndex;
21
- private getMaxZIndex;
22
- markerToTheTop(marker: Marker): void;
23
- clearDrawable(drawable: Drawable): boolean;
24
- private dragged;
25
- isMapDragged(): boolean;
26
- setMapDragged(value: boolean): void;
27
- loadMapApi(): Promise<boolean>;
28
- initializingMap(divElement: HTMLDivElement): Promise<MapVendorType>;
29
- destroyMap: () => void;
30
- private fromGoogleBounds;
31
- getCurrBounds(): Bounds;
32
- panningTo(targetCenter: Position): void;
33
- getZoomLevel(): number;
34
- }
1
+ /// <reference types="google.maps" />
2
+ import { MintMapController } from "../core/MintMapController";
3
+ import { Bounds, Drawable, MapType, MapVendorType, Marker, MarkerOptions, MintMapProps, Polygon, PolygonOptions, Polyline, PolylineOptions, Position } from "../MintMap";
4
+ export declare class GoogleMintMapController extends MintMapController {
5
+ type: MapType;
6
+ map: google.maps.Map | null;
7
+ scriptUrl: string;
8
+ scriptModules: string[];
9
+ constructor(props: MintMapProps);
10
+ polylineEvents: string[];
11
+ createPolyline(polyline: Polyline): void;
12
+ updatePolyline(polyline: Polyline, options: PolylineOptions): void;
13
+ polygonEvents: string[];
14
+ createPolygon(polygon: Polygon): void;
15
+ updatePolygon(polygon: Polygon, options: PolygonOptions): void;
16
+ private getValidOptions;
17
+ markerEvents: string[];
18
+ createMarker(marker: Marker): void;
19
+ updateMarker(marker: Marker, options: MarkerOptions): void;
20
+ private markerMaxZIndex;
21
+ private getMaxZIndex;
22
+ markerToTheTop(marker: Marker): void;
23
+ clearDrawable(drawable: Drawable): boolean;
24
+ private dragged;
25
+ isMapDragged(): boolean;
26
+ setMapDragged(value: boolean): void;
27
+ loadMapApi(): Promise<boolean>;
28
+ initializingMap(divElement: HTMLDivElement): Promise<MapVendorType>;
29
+ destroyMap: () => void;
30
+ private fromGoogleBounds;
31
+ getCurrBounds(): Bounds;
32
+ panningTo(targetCenter: Position): void;
33
+ getZoomLevel(): number;
34
+ setZoomLevel(zoom: number): void;
35
+ }