tg-map-vue3 3.1.3 → 3.1.5
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/dist/src/components/index.d.ts +2 -0
- package/dist/src/components/overlays/TgMarker.vue.d.ts +29 -27
- package/dist/src/utils/spherical-utils.d.ts +20 -0
- package/dist/tg-map.js +1031 -995
- package/dist/tg-map.js.map +1 -1
- package/dist/tg-map.umd.cjs +4 -4
- package/dist/tg-map.umd.cjs.map +1 -1
- package/package.json +1 -1
|
@@ -27,6 +27,7 @@ export * from '../map/lat-lng';
|
|
|
27
27
|
export * from '../map/map/map';
|
|
28
28
|
export * from '../map/map-factory';
|
|
29
29
|
export * from '../map/types';
|
|
30
|
+
export { type Tg } from '../map/event';
|
|
30
31
|
export * from '../map/map/overlay/icon';
|
|
31
32
|
export * from '../map/map/overlay/marker';
|
|
32
33
|
export * from '../map/map/overlay/circle';
|
|
@@ -43,6 +44,7 @@ export * from '../map/map/controls/zoom.control';
|
|
|
43
44
|
export * from '../utils/utils';
|
|
44
45
|
export * from '../utils/vue-utils';
|
|
45
46
|
export * from '../utils/mapped-types';
|
|
47
|
+
export * from '../utils/spherical-utils';
|
|
46
48
|
export { Objects } from '../utils/objects';
|
|
47
49
|
export * from '../utils/arrays';
|
|
48
50
|
export * from '../utils/strings';
|
|
@@ -1,37 +1,39 @@
|
|
|
1
|
+
import { type PropType } from 'vue';
|
|
1
2
|
import { LatLng } from '../../map/lat-lng';
|
|
2
3
|
import { type MarkerOverlay } from '../../map/map/overlay/marker';
|
|
4
|
+
import type { Icon } from '../../map/map/overlay/icon';
|
|
3
5
|
import TgMarkerClusterer from '../extra/TgMarkerClusterer.vue';
|
|
4
6
|
import type TgLabel from './TgLabel.vue';
|
|
5
7
|
import type TgInfoWindow from './TgInfoWindow.vue';
|
|
6
8
|
import type TgInfoBox from './TgInfoBox.vue';
|
|
7
9
|
declare const TgMarker: import("vue").DefineComponent<{
|
|
8
10
|
position: {
|
|
9
|
-
type:
|
|
11
|
+
type: PropType<LatLng>;
|
|
10
12
|
required: true;
|
|
11
13
|
};
|
|
12
14
|
title: {
|
|
13
|
-
type:
|
|
15
|
+
type: PropType<string>;
|
|
14
16
|
};
|
|
15
17
|
icon: {
|
|
16
|
-
type:
|
|
18
|
+
type: PropType<Icon>;
|
|
17
19
|
};
|
|
18
20
|
clickable: {
|
|
19
|
-
type:
|
|
21
|
+
type: PropType<boolean>;
|
|
20
22
|
};
|
|
21
23
|
draggable: {
|
|
22
|
-
type:
|
|
24
|
+
type: PropType<boolean>;
|
|
23
25
|
};
|
|
24
26
|
crossOnDrag: {
|
|
25
|
-
type:
|
|
27
|
+
type: PropType<boolean>;
|
|
26
28
|
};
|
|
27
29
|
cursor: {
|
|
28
|
-
type:
|
|
30
|
+
type: PropType<string>;
|
|
29
31
|
};
|
|
30
32
|
zIndex: {
|
|
31
|
-
type:
|
|
33
|
+
type: PropType<number>;
|
|
32
34
|
};
|
|
33
35
|
visible: {
|
|
34
|
-
type:
|
|
36
|
+
type: PropType<boolean>;
|
|
35
37
|
};
|
|
36
38
|
}, {
|
|
37
39
|
attrs: import("vue").ComputedRef<{
|
|
@@ -45,13 +47,13 @@ declare const TgMarker: import("vue").DefineComponent<{
|
|
|
45
47
|
$data: {};
|
|
46
48
|
$props: Partial<{} & {}> & Omit<Readonly<import("vue").ExtractPropTypes<{}>> & Readonly<import("vue").ExtractPropTypes<{
|
|
47
49
|
position: {
|
|
48
|
-
type:
|
|
50
|
+
type: PropType<LatLng>;
|
|
49
51
|
};
|
|
50
52
|
offset: {
|
|
51
|
-
type:
|
|
53
|
+
type: PropType<any>;
|
|
52
54
|
};
|
|
53
55
|
zIndex: {
|
|
54
|
-
type:
|
|
56
|
+
type: PropType<number>;
|
|
55
57
|
};
|
|
56
58
|
}>> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, never>;
|
|
57
59
|
$attrs: {
|
|
@@ -69,13 +71,13 @@ declare const TgMarker: import("vue").DefineComponent<{
|
|
|
69
71
|
$el: any;
|
|
70
72
|
$options: import("vue").ComponentOptionsBase<Readonly<import("vue").ExtractPropTypes<{
|
|
71
73
|
position: {
|
|
72
|
-
type:
|
|
74
|
+
type: PropType<LatLng>;
|
|
73
75
|
};
|
|
74
76
|
offset: {
|
|
75
|
-
type:
|
|
77
|
+
type: PropType<any>;
|
|
76
78
|
};
|
|
77
79
|
zIndex: {
|
|
78
|
-
type:
|
|
80
|
+
type: PropType<number>;
|
|
79
81
|
};
|
|
80
82
|
}>>, {
|
|
81
83
|
attrs: import("vue").ComputedRef<{
|
|
@@ -113,13 +115,13 @@ declare const TgMarker: import("vue").DefineComponent<{
|
|
|
113
115
|
$watch<T extends string | ((...args: any) => any)>(source: T, cb: T extends (...args: any) => infer R ? (args_0: R, args_1: R) => any : (...args: any) => any, options?: import("vue").WatchOptions<boolean> | undefined): import("vue").WatchStopHandle;
|
|
114
116
|
} & Readonly<import("vue").ExtractPropTypes<{}>> & Readonly<import("vue").ExtractPropTypes<{
|
|
115
117
|
position: {
|
|
116
|
-
type:
|
|
118
|
+
type: PropType<LatLng>;
|
|
117
119
|
};
|
|
118
120
|
offset: {
|
|
119
|
-
type:
|
|
121
|
+
type: PropType<any>;
|
|
120
122
|
};
|
|
121
123
|
zIndex: {
|
|
122
|
-
type:
|
|
124
|
+
type: PropType<number>;
|
|
123
125
|
};
|
|
124
126
|
}>> & import("vue").ShallowUnwrapRef<{
|
|
125
127
|
attrs: import("vue").ComputedRef<{
|
|
@@ -148,32 +150,32 @@ declare const TgMarker: import("vue").DefineComponent<{
|
|
|
148
150
|
recreate(): void;
|
|
149
151
|
}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}>, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
150
152
|
position: {
|
|
151
|
-
type:
|
|
153
|
+
type: PropType<LatLng>;
|
|
152
154
|
required: true;
|
|
153
155
|
};
|
|
154
156
|
title: {
|
|
155
|
-
type:
|
|
157
|
+
type: PropType<string>;
|
|
156
158
|
};
|
|
157
159
|
icon: {
|
|
158
|
-
type:
|
|
160
|
+
type: PropType<Icon>;
|
|
159
161
|
};
|
|
160
162
|
clickable: {
|
|
161
|
-
type:
|
|
163
|
+
type: PropType<boolean>;
|
|
162
164
|
};
|
|
163
165
|
draggable: {
|
|
164
|
-
type:
|
|
166
|
+
type: PropType<boolean>;
|
|
165
167
|
};
|
|
166
168
|
crossOnDrag: {
|
|
167
|
-
type:
|
|
169
|
+
type: PropType<boolean>;
|
|
168
170
|
};
|
|
169
171
|
cursor: {
|
|
170
|
-
type:
|
|
172
|
+
type: PropType<string>;
|
|
171
173
|
};
|
|
172
174
|
zIndex: {
|
|
173
|
-
type:
|
|
175
|
+
type: PropType<number>;
|
|
174
176
|
};
|
|
175
177
|
visible: {
|
|
176
|
-
type:
|
|
178
|
+
type: PropType<boolean>;
|
|
177
179
|
};
|
|
178
180
|
}>>, {}>;
|
|
179
181
|
type TgMarker = InstanceType<typeof TgMarker>;
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import type { LatLngLiteral } from '../components';
|
|
2
|
+
/**
|
|
3
|
+
* 球面两点之间距离(米)
|
|
4
|
+
* @param p1
|
|
5
|
+
* @param p2
|
|
6
|
+
*/
|
|
7
|
+
declare function getDistance(p1: LatLngLiteral, p2: LatLngLiteral): number;
|
|
8
|
+
/**
|
|
9
|
+
* 已知一点经纬度,方位角,距离求另一点
|
|
10
|
+
* @param pt 点
|
|
11
|
+
* @param angle 角度
|
|
12
|
+
* @param dist 距离
|
|
13
|
+
*/
|
|
14
|
+
export declare function getDestination(pt: LatLngLiteral, angle: number, dist: number): LatLngLiteral;
|
|
15
|
+
/** 球面工具 */
|
|
16
|
+
export declare const SphericalUtils: {
|
|
17
|
+
getDistance: typeof getDistance;
|
|
18
|
+
getDestination: typeof getDestination;
|
|
19
|
+
};
|
|
20
|
+
export {};
|