tg-map-vue3 3.9.9 → 4.0.1

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 (92) hide show
  1. package/CHANGELOG.md +5 -0
  2. package/README.md +4 -1
  3. package/dist/src/components/TgMap.vue.d.ts +1877 -83
  4. package/dist/src/components/TgMapWidget.vue.d.ts +3 -3
  5. package/dist/src/components/controls/TgCustomControl.vue.d.ts +1 -2
  6. package/dist/src/components/controls/TgMapTypeControl.vue.d.ts +8 -9
  7. package/dist/src/components/controls/TgScaleControl.vue.d.ts +4 -5
  8. package/dist/src/components/controls/TgStreetViewControl.vue.d.ts +4 -4
  9. package/dist/src/components/controls/TgZoomControl.vue.d.ts +4 -4
  10. package/dist/src/components/extra/TgHeatmap.vue.d.ts +2 -2
  11. package/dist/src/components/extra/TgMarkerClusterer.vue.d.ts +3 -4
  12. package/dist/src/components/index.d.ts +4 -41
  13. package/dist/src/components/layers/TgTrafficLayer.vue.d.ts +1 -1
  14. package/dist/src/components/map-hooks.d.ts +4 -4
  15. package/dist/src/components/map-mixin.d.ts +2 -2
  16. package/dist/src/components/overlays/TgCircle.vue.d.ts +19 -14
  17. package/dist/src/components/overlays/TgElementOverlay.vue.d.ts +5 -7
  18. package/dist/src/components/overlays/TgInfoBox.vue.d.ts +5 -7
  19. package/dist/src/components/overlays/TgInfoWindow.vue.d.ts +16 -17
  20. package/dist/src/components/overlays/TgLabel.vue.d.ts +4 -7
  21. package/dist/src/components/overlays/TgMarker.vue.d.ts +89 -45
  22. package/dist/src/components/overlays/TgPolygon.vue.d.ts +64 -27
  23. package/dist/src/components/overlays/TgPolyline.vue.d.ts +16 -12
  24. package/dist/src/components/overlays/TgRectangle.vue.d.ts +28 -27
  25. package/dist/src/utils/hooks.d.ts +4 -0
  26. package/dist/src/utils/vue-utils.d.ts +13 -2
  27. package/dist/tg-map.cjs +2 -17
  28. package/dist/tg-map.cjs.map +1 -1
  29. package/dist/tg-map.js +679 -6481
  30. package/dist/tg-map.js.map +1 -1
  31. package/package.json +14 -13
  32. package/dist/src/map/event-target.d.ts +0 -71
  33. package/dist/src/map/event.d.ts +0 -46
  34. package/dist/src/map/lat-lng.d.ts +0 -157
  35. package/dist/src/map/map/baidu-map.d.ts +0 -82
  36. package/dist/src/map/map/controls/control.d.ts +0 -112
  37. package/dist/src/map/map/controls/map-type.control.d.ts +0 -29
  38. package/dist/src/map/map/controls/scale.control.d.ts +0 -15
  39. package/dist/src/map/map/controls/street-view.control.d.ts +0 -20
  40. package/dist/src/map/map/controls/zoom.control.d.ts +0 -15
  41. package/dist/src/map/map/extra/autocomplete.d.ts +0 -41
  42. package/dist/src/map/map/extra/heatmap.d.ts +0 -71
  43. package/dist/src/map/map/extra/map-urls.d.ts +0 -59
  44. package/dist/src/map/map/extra/marker-clusterer.d.ts +0 -73
  45. package/dist/src/map/map/extra/places-service.d.ts +0 -46
  46. package/dist/src/map/map/extra/search-box.d.ts +0 -38
  47. package/dist/src/map/map/google-map.d.ts +0 -81
  48. package/dist/src/map/map/here-map.d.ts +0 -78
  49. package/dist/src/map/map/map-options.d.ts +0 -60
  50. package/dist/src/map/map/map-type.d.ts +0 -110
  51. package/dist/src/map/map/map.d.ts +0 -168
  52. package/dist/src/map/map/overlay/baidu-info-box.d.ts +0 -82
  53. package/dist/src/map/map/overlay/circle.d.ts +0 -51
  54. package/dist/src/map/map/overlay/element-overlay.d.ts +0 -37
  55. package/dist/src/map/map/overlay/google-label.d.ts +0 -68
  56. package/dist/src/map/map/overlay/icon.d.ts +0 -122
  57. package/dist/src/map/map/overlay/info-box.d.ts +0 -60
  58. package/dist/src/map/map/overlay/info-window.d.ts +0 -111
  59. package/dist/src/map/map/overlay/label.d.ts +0 -102
  60. package/dist/src/map/map/overlay/marker-label.d.ts +0 -19
  61. package/dist/src/map/map/overlay/marker.d.ts +0 -143
  62. package/dist/src/map/map/overlay/overlay.d.ts +0 -46
  63. package/dist/src/map/map/overlay/polygon.d.ts +0 -42
  64. package/dist/src/map/map/overlay/polyline.d.ts +0 -71
  65. package/dist/src/map/map/overlay/rectangle.d.ts +0 -50
  66. package/dist/src/map/map/overlay/shape.d.ts +0 -65
  67. package/dist/src/map/map-config.d.ts +0 -25
  68. package/dist/src/map/map-factory.d.ts +0 -10
  69. package/dist/src/map/map-loader.d.ts +0 -19
  70. package/dist/src/map/types.d.ts +0 -17
  71. package/dist/src/map/unions.d.ts +0 -19
  72. package/dist/src/utils/arrays.d.ts +0 -19
  73. package/dist/src/utils/baidu-utils.d.ts +0 -23
  74. package/dist/src/utils/elements.d.ts +0 -4
  75. package/dist/src/utils/formatter.d.ts +0 -1
  76. package/dist/src/utils/google-utils.d.ts +0 -34
  77. package/dist/src/utils/here-utils.d.ts +0 -10
  78. package/dist/src/utils/mapped-types.d.ts +0 -90
  79. package/dist/src/utils/maps-utils/index.d.ts +0 -2
  80. package/dist/src/utils/maps-utils/math-util.d.ts +0 -59
  81. package/dist/src/utils/maps-utils/poly-util.d.ts +0 -103
  82. package/dist/src/utils/maps-utils/spherical-util.d.ts +0 -67
  83. package/dist/src/utils/objects.d.ts +0 -27
  84. package/dist/src/utils/spherical-utils.d.ts +0 -27
  85. package/dist/src/utils/strings.d.ts +0 -21
  86. package/dist/src/utils/utils.d.ts +0 -13
  87. package/dist/src/utils/values.d.ts +0 -34
  88. package/src/map/dts/baidu.d.ts +0 -53
  89. package/src/map/dts/google.d.ts +0 -10
  90. package/src/map/dts/here-v31.d.ts +0 -16
  91. package/src/map/dts/index.d.ts +0 -4
  92. package/src/map/dts/js-modules.d.ts +0 -15
@@ -1,53 +0,0 @@
1
- declare namespace BMap {
2
- class OverlayV3 {
3
- initialize(map: Map): HTMLElement
4
- isVisible(): boolean
5
- draw(): void
6
- show(): void
7
- hide(): void
8
- // 这些方法文档中都没写, 但确实可以调用...
9
- addEventListener(event: string, handler: Callback): void
10
- removeEventListener(event: string, handler: Callback): void
11
- /** @param event type名要以'on'开头 */
12
- dispatchEvent(event: { type: string }): void
13
- }
14
- interface Map {
15
- addEventListener(event: string, handler: Callback): void
16
- removeEventListener(event: string, handler: Callback): void
17
- }
18
- interface Autocomplete {
19
- addEventListener(event: string, handler: Callback): void
20
- removeEventListener(event: string, handler: Callback): void
21
- }
22
- interface AutocompleteResultPoi {
23
- city: string
24
- }
25
- interface LocalSearchOptions {
26
- onSearchComplete?: ((results: LocalResult[] | LocalResult) => void) | undefined;
27
- }
28
- interface LocalResultPoi {
29
- uid: string
30
- }
31
-
32
- interface MarkerOptions {
33
- icon?: BMap.Symbol | Icon
34
- }
35
-
36
- interface Marker {
37
- setIcon(icon: Icon | BMap.Symbol): void;
38
- getIcon(): Icon | BMap.Symbol;
39
- }
40
-
41
- interface Symbol {
42
- /** 实际的锚点, 第一次添加到地图上时会为undefined */
43
- anchor?: Size
44
- style: {
45
- /** 设置的锚点 */
46
- anchor: Size
47
- }
48
- }
49
-
50
- interface IconOptions {
51
- imageSize?: Size
52
- }
53
- }
@@ -1,10 +0,0 @@
1
- declare namespace google.maps {
2
- /** url可以直接作为Icon */
3
- type UrlIcon = string
4
- interface InfoWindow {
5
- /** 获取Map, 文档中没写这个方法 */
6
- getMap(): Map | undefined
7
- /** 获取锚点, 文档中没写这个方法 */
8
- getAnchor(): Marker | undefined
9
- }
10
- }
@@ -1,16 +0,0 @@
1
- // v3.1
2
- declare namespace H {
3
- namespace service {
4
- interface PlatformV31Constructor {
5
- new(options: { apikey: string }): Platform
6
- }
7
- interface PlatformV31 extends Platform {
8
-
9
- }
10
- let PlatformV31: PlatformV31Constructor
11
- interface DefaultLayers {
12
- raster: { normal: H.service.MapType, satellite: H.service.MapType, terrain: H.service.MapType }
13
- vector: { normal: { map: H.map.layer.TileLayer, traffic: H.map.layer.TileLayer, trafficincidents: H.map.layer.MarkerTileLayer } }
14
- }
15
- }
16
- }
@@ -1,4 +0,0 @@
1
- /* eslint-disable @typescript-eslint/triple-slash-reference */
2
- /// <reference path="./baidu.d.ts" preserve="true" />
3
- /// <reference path="./google.d.ts" preserve="true" />
4
- /// <reference path="./here-v31.d.ts" preserve="true" />
@@ -1,15 +0,0 @@
1
- /**
2
- * 当前版本, tsconfig中`allowJs:true`和`declaration:true`不兼容, 导致引用第三方js库时, 无法利用JSDoc的类型注解
3
- * 未来貌似会增加允许两者同时为true的功能, 详见{@link https://github.com/microsoft/TypeScript/pull/32372}
4
- *
5
- * 当前使用两个tsconfig, 达到类似效果:
6
- * 1. tsconfig.json: `allowJs:true`+`declaration:false`, 用来在VSCode中利用第三方JS库的JSDoc注解
7
- * 2. tsconfig.types.json: `allowJs:false`+`declaration:true`, 用来在编译时正常输出.d.ts文件
8
- *
9
- * 而该文件(`js-modules.d.ts`)的作用就是声明用到的第三方js库, 让tsconfig.types.json能够正常编译
10
- *
11
- * typescript 3.7 之后已支持两者同时为true, 该文件暂时没有用, 可以移除
12
- */
13
- // cSpell:ignore bmaplib, markerclusterer
14
- // declare module 'bmaplib.markerclusterer'
15
- // declare module '@google/markerclusterer'