@heycar/heycars-map 0.9.11 → 0.9.13

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 (34) hide show
  1. package/dist/index.cjs +506 -93
  2. package/dist/index.js +507 -94
  3. package/dist/src/Demo/DemoBusinessTaxiService.d.ts +805 -560
  4. package/dist/src/business-components/BusinessRecomendPlaceMap/BusinessRecomendPlaceMap.d.ts +0 -1
  5. package/dist/src/business-components/BusinessReselectPlaceMap/BusinessReselectPlaceMap.d.ts +2 -2
  6. package/dist/src/business-components/FitView/FitView.d.ts +9 -2
  7. package/dist/src/business-components/PassengerCircle/PassengerCircle.d.ts +825 -825
  8. package/dist/src/business-components/StartEndPoint/StartEndPoint.d.ts +825 -825
  9. package/dist/src/business-components/TaxiCar/TaxiCar.d.ts +825 -825
  10. package/dist/src/components/Amap/Amap.d.ts +8 -7
  11. package/dist/src/components/Amap/SafeAmap.d.ts +103 -0
  12. package/dist/src/components/MapProvider/MapProvider.d.ts +2 -1
  13. package/dist/src/hooks/useHeycarMap.d.ts +5 -1585
  14. package/dist/src/hooks/useMap.d.ts +4 -794
  15. package/dist/src/hooks/useMapAngle.d.ts +3 -3
  16. package/dist/src/hooks/useMapDrag.d.ts +3 -3
  17. package/dist/src/hooks/useMapFitView.d.ts +108 -108
  18. package/dist/src/hooks/useMapLngLatToVw.d.ts +3 -3
  19. package/dist/src/hooks/useMapRecomendPlace.d.ts +1 -0
  20. package/dist/src/hooks/useMapWheelZoomCenter.d.ts +3 -2
  21. package/dist/src/hooks/useMapZoom.d.ts +3 -2
  22. package/dist/src/hooks-business/useBusinessQuotingMap.d.ts +806 -561
  23. package/dist/src/hooks-business/useBusinessRecomendPlaceMap.d.ts +4 -3
  24. package/dist/src/hooks-business/useBusinessReselectPlaceMap.d.ts +1 -1
  25. package/dist/src/hooks-business/useBusinessTaxiServiceMap.d.ts +806 -561
  26. package/dist/src/index.d.ts +1 -0
  27. package/dist/src/types/interface.d.ts +4 -2
  28. package/dist/src/types/my.d.ts +21 -0
  29. package/dist/src/types/wx.d.ts +1 -0
  30. package/dist/src/utils/alipayPolyfill.d.ts +1 -0
  31. package/dist/src/utils/helper.d.ts +0 -1
  32. package/dist/src/utils/referenceCount.d.ts +8 -0
  33. package/package.json +1 -1
  34. package/todo.md +15 -0
@@ -1,16 +1,16 @@
1
1
  /// <reference types="google.maps" />
2
- import type { MapShallowRef, RegisterOverlay } from "../types/interface";
2
+ import type { AmapMap, MapShallowRef, RegisterOverlay } from "../types/interface";
3
3
  import type { AmapOverlay, GmapOverlay } from "./useOverlay";
4
4
  export interface UseMapFitViewOutput<L> {
5
- setFitView: () => void;
5
+ setFitView: (immediate: boolean) => void;
6
6
  registerFitVeiw: RegisterOverlay<L>;
7
7
  }
8
- export interface UseMapFitViewProps<M = AMap.Map | google.maps.Map> {
8
+ export interface UseMapFitViewProps<M = AmapMap | google.maps.Map> {
9
9
  mapRef: MapShallowRef<M>;
10
10
  padding?: [number, number, number, number];
11
11
  autoFitTimeout?: number;
12
12
  }
13
- export declare const useAmapFitView: (props: UseMapFitViewProps<AMap.Map>) => {
13
+ export declare const useAmapFitView: (props: UseMapFitViewProps<AmapMap>) => {
14
14
  registerFitVeiw: RegisterOverlay<{
15
15
  _needUpdate: boolean;
16
16
  readonly CLASS_NAME: "Overlay" | "Overlay.Polygon" | "Overlay.CorePolygon" | "Overlay.CorePolyline" | "Overlay.Rectangle" | "Overlay.Ellipse" | "Overlay.Circle" | "Overlay.CircleMarker" | "Overlay.Polyline" | "Overlay.BezierCurve" | "Overlay.OverlayGroup" | "Overlay.GeoJSON";
@@ -39,18 +39,11 @@ export declare const useAmapFitView: (props: UseMapFitViewProps<AMap.Map>) => {
39
39
  setPitch(pitch: number, immediately?: boolean | undefined, duration?: number | undefined): void;
40
40
  getRotation(): number;
41
41
  setRotation(rotation?: number | undefined, immediately?: boolean | undefined, duration?: number | undefined): void;
42
- setBounds(bounds: number[] | AMap.Bounds, immediately?: boolean | undefined, avoid?: number[] | undefined): void;
42
+ setBounds(bounds: AMap.Bounds | number[], immediately?: boolean | undefined, avoid?: number[] | undefined): void;
43
43
  panTo(lnglat: [number, number] | AMap.LngLat, duration?: number | undefined): void;
44
44
  panBy(x: number, y: number, duration?: number | undefined): void;
45
45
  getContainer(): HTMLDivElement;
46
46
  add(features: {
47
- on(type: AMap.EventType | AMap.EventType[], fn: (e: any) => void, context?: any, once?: boolean | undefined): any;
48
- off(type: AMap.EventType, fn: (e: any) => void, context?: any): any;
49
- hasEvents(type: AMap.EventType, fn: (e: any) => void, context?: any): boolean;
50
- clearEvents(type: AMap.EventType): any;
51
- emit(type: AMap.EventType, data?: any): any;
52
- getEvents(): Record<string, any[]>;
53
- } | {
54
47
  CLASS_NAME: string;
55
48
  _zIndex: number;
56
49
  _opts: any;
@@ -72,14 +65,14 @@ export declare const useAmapFitView: (props: UseMapFitViewProps<AMap.Map>) => {
72
65
  clearEvents(type: AMap.EventType): any;
73
66
  emit(type: AMap.EventType, data?: any): any;
74
67
  getEvents(): Record<string, any[]>;
75
- } | ({
68
+ } | {
76
69
  on(type: AMap.EventType | AMap.EventType[], fn: (e: any) => void, context?: any, once?: boolean | undefined): any;
77
70
  off(type: AMap.EventType, fn: (e: any) => void, context?: any): any;
78
71
  hasEvents(type: AMap.EventType, fn: (e: any) => void, context?: any): boolean;
79
72
  clearEvents(type: AMap.EventType): any;
80
73
  emit(type: AMap.EventType, data?: any): any;
81
74
  getEvents(): Record<string, any[]>;
82
- } | {
75
+ } | ({
83
76
  CLASS_NAME: string;
84
77
  _zIndex: number;
85
78
  _opts: any;
@@ -101,15 +94,15 @@ export declare const useAmapFitView: (props: UseMapFitViewProps<AMap.Map>) => {
101
94
  clearEvents(type: AMap.EventType): any;
102
95
  emit(type: AMap.EventType, data?: any): any;
103
96
  getEvents(): Record<string, any[]>;
104
- })[]): void;
105
- remove(features: {
97
+ } | {
106
98
  on(type: AMap.EventType | AMap.EventType[], fn: (e: any) => void, context?: any, once?: boolean | undefined): any;
107
99
  off(type: AMap.EventType, fn: (e: any) => void, context?: any): any;
108
100
  hasEvents(type: AMap.EventType, fn: (e: any) => void, context?: any): boolean;
109
101
  clearEvents(type: AMap.EventType): any;
110
102
  emit(type: AMap.EventType, data?: any): any;
111
103
  getEvents(): Record<string, any[]>;
112
- } | {
104
+ })[]): void;
105
+ remove(features: {
113
106
  CLASS_NAME: string;
114
107
  _zIndex: number;
115
108
  _opts: any;
@@ -131,14 +124,14 @@ export declare const useAmapFitView: (props: UseMapFitViewProps<AMap.Map>) => {
131
124
  clearEvents(type: AMap.EventType): any;
132
125
  emit(type: AMap.EventType, data?: any): any;
133
126
  getEvents(): Record<string, any[]>;
134
- } | ({
127
+ } | {
135
128
  on(type: AMap.EventType | AMap.EventType[], fn: (e: any) => void, context?: any, once?: boolean | undefined): any;
136
129
  off(type: AMap.EventType, fn: (e: any) => void, context?: any): any;
137
130
  hasEvents(type: AMap.EventType, fn: (e: any) => void, context?: any): boolean;
138
131
  clearEvents(type: AMap.EventType): any;
139
132
  emit(type: AMap.EventType, data?: any): any;
140
133
  getEvents(): Record<string, any[]>;
141
- } | {
134
+ } | ({
142
135
  CLASS_NAME: string;
143
136
  _zIndex: number;
144
137
  _opts: any;
@@ -160,6 +153,13 @@ export declare const useAmapFitView: (props: UseMapFitViewProps<AMap.Map>) => {
160
153
  clearEvents(type: AMap.EventType): any;
161
154
  emit(type: AMap.EventType, data?: any): any;
162
155
  getEvents(): Record<string, any[]>;
156
+ } | {
157
+ on(type: AMap.EventType | AMap.EventType[], fn: (e: any) => void, context?: any, once?: boolean | undefined): any;
158
+ off(type: AMap.EventType, fn: (e: any) => void, context?: any): any;
159
+ hasEvents(type: AMap.EventType, fn: (e: any) => void, context?: any): boolean;
160
+ clearEvents(type: AMap.EventType): any;
161
+ emit(type: AMap.EventType, data?: any): any;
162
+ getEvents(): Record<string, any[]>;
163
163
  })[]): void;
164
164
  lngLatToCoords(lnglat: [number, number] | AMap.LngLat): [number, number];
165
165
  coordsToLngLat(coords: [number, number]): AMap.LngLat;
@@ -188,7 +188,7 @@ export declare const useAmapFitView: (props: UseMapFitViewProps<AMap.Map>) => {
188
188
  getEvents(): Record<string, any[]>;
189
189
  }[] | undefined, immediately?: boolean | undefined, avoid?: number[] | undefined, maxZoom?: number | undefined): AMap.Bounds | undefined;
190
190
  getFitZoomAndCenterByOverlays(overlayList: any[], avoid?: number[] | undefined, maxZoom?: number | undefined): any[] | undefined;
191
- getFitZoomAndCenterByBounds(bounds: number[] | AMap.Bounds, avoid?: number[] | undefined, maxZoom?: number | undefined): any[];
191
+ getFitZoomAndCenterByBounds(bounds: AMap.Bounds | number[], avoid?: number[] | undefined, maxZoom?: number | undefined): any[];
192
192
  addControl(control: AMap.Control): void;
193
193
  removeControl(control: AMap.Control): void;
194
194
  setMapStyle(value: string): void;
@@ -367,7 +367,7 @@ export declare const useAmapFitView: (props: UseMapFitViewProps<AMap.Map>) => {
367
367
  getDefaultCursor(): string;
368
368
  setDefaultCursor(cursor: string): void;
369
369
  getLimitBounds(): AMap.Bounds | undefined;
370
- setLimitBounds(bounds: number[] | AMap.Bounds): void;
370
+ setLimitBounds(bounds: AMap.Bounds | number[]): void;
371
371
  clearLimitBounds(): void;
372
372
  getZooms(): [number, number];
373
373
  setZooms(zooms: [number, number]): void;
@@ -410,18 +410,11 @@ export declare const useAmapFitView: (props: UseMapFitViewProps<AMap.Map>) => {
410
410
  setPitch(pitch: number, immediately?: boolean | undefined, duration?: number | undefined): void;
411
411
  getRotation(): number;
412
412
  setRotation(rotation?: number | undefined, immediately?: boolean | undefined, duration?: number | undefined): void;
413
- setBounds(bounds: number[] | AMap.Bounds, immediately?: boolean | undefined, avoid?: number[] | undefined): void;
413
+ setBounds(bounds: AMap.Bounds | number[], immediately?: boolean | undefined, avoid?: number[] | undefined): void;
414
414
  panTo(lnglat: [number, number] | AMap.LngLat, duration?: number | undefined): void;
415
415
  panBy(x: number, y: number, duration?: number | undefined): void;
416
416
  getContainer(): HTMLDivElement;
417
417
  add(features: {
418
- on(type: AMap.EventType | AMap.EventType[], fn: (e: any) => void, context?: any, once?: boolean | undefined): any;
419
- off(type: AMap.EventType, fn: (e: any) => void, context?: any): any;
420
- hasEvents(type: AMap.EventType, fn: (e: any) => void, context?: any): boolean;
421
- clearEvents(type: AMap.EventType): any;
422
- emit(type: AMap.EventType, data?: any): any;
423
- getEvents(): Record<string, any[]>;
424
- } | {
425
418
  CLASS_NAME: string;
426
419
  _zIndex: number;
427
420
  _opts: any;
@@ -443,14 +436,14 @@ export declare const useAmapFitView: (props: UseMapFitViewProps<AMap.Map>) => {
443
436
  clearEvents(type: AMap.EventType): any;
444
437
  emit(type: AMap.EventType, data?: any): any;
445
438
  getEvents(): Record<string, any[]>;
446
- } | ({
439
+ } | {
447
440
  on(type: AMap.EventType | AMap.EventType[], fn: (e: any) => void, context?: any, once?: boolean | undefined): any;
448
441
  off(type: AMap.EventType, fn: (e: any) => void, context?: any): any;
449
442
  hasEvents(type: AMap.EventType, fn: (e: any) => void, context?: any): boolean;
450
443
  clearEvents(type: AMap.EventType): any;
451
444
  emit(type: AMap.EventType, data?: any): any;
452
445
  getEvents(): Record<string, any[]>;
453
- } | {
446
+ } | ({
454
447
  CLASS_NAME: string;
455
448
  _zIndex: number;
456
449
  _opts: any;
@@ -472,15 +465,15 @@ export declare const useAmapFitView: (props: UseMapFitViewProps<AMap.Map>) => {
472
465
  clearEvents(type: AMap.EventType): any;
473
466
  emit(type: AMap.EventType, data?: any): any;
474
467
  getEvents(): Record<string, any[]>;
475
- })[]): void;
476
- remove(features: {
468
+ } | {
477
469
  on(type: AMap.EventType | AMap.EventType[], fn: (e: any) => void, context?: any, once?: boolean | undefined): any;
478
470
  off(type: AMap.EventType, fn: (e: any) => void, context?: any): any;
479
471
  hasEvents(type: AMap.EventType, fn: (e: any) => void, context?: any): boolean;
480
472
  clearEvents(type: AMap.EventType): any;
481
473
  emit(type: AMap.EventType, data?: any): any;
482
474
  getEvents(): Record<string, any[]>;
483
- } | {
475
+ })[]): void;
476
+ remove(features: {
484
477
  CLASS_NAME: string;
485
478
  _zIndex: number;
486
479
  _opts: any;
@@ -502,14 +495,14 @@ export declare const useAmapFitView: (props: UseMapFitViewProps<AMap.Map>) => {
502
495
  clearEvents(type: AMap.EventType): any;
503
496
  emit(type: AMap.EventType, data?: any): any;
504
497
  getEvents(): Record<string, any[]>;
505
- } | ({
498
+ } | {
506
499
  on(type: AMap.EventType | AMap.EventType[], fn: (e: any) => void, context?: any, once?: boolean | undefined): any;
507
500
  off(type: AMap.EventType, fn: (e: any) => void, context?: any): any;
508
501
  hasEvents(type: AMap.EventType, fn: (e: any) => void, context?: any): boolean;
509
502
  clearEvents(type: AMap.EventType): any;
510
503
  emit(type: AMap.EventType, data?: any): any;
511
504
  getEvents(): Record<string, any[]>;
512
- } | {
505
+ } | ({
513
506
  CLASS_NAME: string;
514
507
  _zIndex: number;
515
508
  _opts: any;
@@ -531,6 +524,13 @@ export declare const useAmapFitView: (props: UseMapFitViewProps<AMap.Map>) => {
531
524
  clearEvents(type: AMap.EventType): any;
532
525
  emit(type: AMap.EventType, data?: any): any;
533
526
  getEvents(): Record<string, any[]>;
527
+ } | {
528
+ on(type: AMap.EventType | AMap.EventType[], fn: (e: any) => void, context?: any, once?: boolean | undefined): any;
529
+ off(type: AMap.EventType, fn: (e: any) => void, context?: any): any;
530
+ hasEvents(type: AMap.EventType, fn: (e: any) => void, context?: any): boolean;
531
+ clearEvents(type: AMap.EventType): any;
532
+ emit(type: AMap.EventType, data?: any): any;
533
+ getEvents(): Record<string, any[]>;
534
534
  })[]): void;
535
535
  lngLatToCoords(lnglat: [number, number] | AMap.LngLat): [number, number];
536
536
  coordsToLngLat(coords: [number, number]): AMap.LngLat;
@@ -559,7 +559,7 @@ export declare const useAmapFitView: (props: UseMapFitViewProps<AMap.Map>) => {
559
559
  getEvents(): Record<string, any[]>;
560
560
  }[] | undefined, immediately?: boolean | undefined, avoid?: number[] | undefined, maxZoom?: number | undefined): AMap.Bounds | undefined;
561
561
  getFitZoomAndCenterByOverlays(overlayList: any[], avoid?: number[] | undefined, maxZoom?: number | undefined): any[] | undefined;
562
- getFitZoomAndCenterByBounds(bounds: number[] | AMap.Bounds, avoid?: number[] | undefined, maxZoom?: number | undefined): any[];
562
+ getFitZoomAndCenterByBounds(bounds: AMap.Bounds | number[], avoid?: number[] | undefined, maxZoom?: number | undefined): any[];
563
563
  addControl(control: AMap.Control): void;
564
564
  removeControl(control: AMap.Control): void;
565
565
  setMapStyle(value: string): void;
@@ -738,7 +738,7 @@ export declare const useAmapFitView: (props: UseMapFitViewProps<AMap.Map>) => {
738
738
  getDefaultCursor(): string;
739
739
  setDefaultCursor(cursor: string): void;
740
740
  getLimitBounds(): AMap.Bounds | undefined;
741
- setLimitBounds(bounds: number[] | AMap.Bounds): void;
741
+ setLimitBounds(bounds: AMap.Bounds | number[]): void;
742
742
  clearLimitBounds(): void;
743
743
  getZooms(): [number, number];
744
744
  setZooms(zooms: [number, number]): void;
@@ -804,18 +804,11 @@ export declare const useAmapFitView: (props: UseMapFitViewProps<AMap.Map>) => {
804
804
  setPitch(pitch: number, immediately?: boolean | undefined, duration?: number | undefined): void;
805
805
  getRotation(): number;
806
806
  setRotation(rotation?: number | undefined, immediately?: boolean | undefined, duration?: number | undefined): void;
807
- setBounds(bounds: number[] | AMap.Bounds, immediately?: boolean | undefined, avoid?: number[] | undefined): void;
807
+ setBounds(bounds: AMap.Bounds | number[], immediately?: boolean | undefined, avoid?: number[] | undefined): void;
808
808
  panTo(lnglat: [number, number] | AMap.LngLat, duration?: number | undefined): void;
809
809
  panBy(x: number, y: number, duration?: number | undefined): void;
810
810
  getContainer(): HTMLDivElement;
811
811
  add(features: {
812
- on(type: AMap.EventType | AMap.EventType[], fn: (e: any) => void, context?: any, once?: boolean | undefined): any;
813
- off(type: AMap.EventType, fn: (e: any) => void, context?: any): any;
814
- hasEvents(type: AMap.EventType, fn: (e: any) => void, context?: any): boolean;
815
- clearEvents(type: AMap.EventType): any;
816
- emit(type: AMap.EventType, data?: any): any;
817
- getEvents(): Record<string, any[]>;
818
- } | {
819
812
  CLASS_NAME: string;
820
813
  _zIndex: number;
821
814
  _opts: any;
@@ -837,14 +830,14 @@ export declare const useAmapFitView: (props: UseMapFitViewProps<AMap.Map>) => {
837
830
  clearEvents(type: AMap.EventType): any;
838
831
  emit(type: AMap.EventType, data?: any): any;
839
832
  getEvents(): Record<string, any[]>;
840
- } | ({
833
+ } | {
841
834
  on(type: AMap.EventType | AMap.EventType[], fn: (e: any) => void, context?: any, once?: boolean | undefined): any;
842
835
  off(type: AMap.EventType, fn: (e: any) => void, context?: any): any;
843
836
  hasEvents(type: AMap.EventType, fn: (e: any) => void, context?: any): boolean;
844
837
  clearEvents(type: AMap.EventType): any;
845
838
  emit(type: AMap.EventType, data?: any): any;
846
839
  getEvents(): Record<string, any[]>;
847
- } | {
840
+ } | ({
848
841
  CLASS_NAME: string;
849
842
  _zIndex: number;
850
843
  _opts: any;
@@ -866,15 +859,15 @@ export declare const useAmapFitView: (props: UseMapFitViewProps<AMap.Map>) => {
866
859
  clearEvents(type: AMap.EventType): any;
867
860
  emit(type: AMap.EventType, data?: any): any;
868
861
  getEvents(): Record<string, any[]>;
869
- })[]): void;
870
- remove(features: {
862
+ } | {
871
863
  on(type: AMap.EventType | AMap.EventType[], fn: (e: any) => void, context?: any, once?: boolean | undefined): any;
872
864
  off(type: AMap.EventType, fn: (e: any) => void, context?: any): any;
873
865
  hasEvents(type: AMap.EventType, fn: (e: any) => void, context?: any): boolean;
874
866
  clearEvents(type: AMap.EventType): any;
875
867
  emit(type: AMap.EventType, data?: any): any;
876
868
  getEvents(): Record<string, any[]>;
877
- } | {
869
+ })[]): void;
870
+ remove(features: {
878
871
  CLASS_NAME: string;
879
872
  _zIndex: number;
880
873
  _opts: any;
@@ -896,14 +889,14 @@ export declare const useAmapFitView: (props: UseMapFitViewProps<AMap.Map>) => {
896
889
  clearEvents(type: AMap.EventType): any;
897
890
  emit(type: AMap.EventType, data?: any): any;
898
891
  getEvents(): Record<string, any[]>;
899
- } | ({
892
+ } | {
900
893
  on(type: AMap.EventType | AMap.EventType[], fn: (e: any) => void, context?: any, once?: boolean | undefined): any;
901
894
  off(type: AMap.EventType, fn: (e: any) => void, context?: any): any;
902
895
  hasEvents(type: AMap.EventType, fn: (e: any) => void, context?: any): boolean;
903
896
  clearEvents(type: AMap.EventType): any;
904
897
  emit(type: AMap.EventType, data?: any): any;
905
898
  getEvents(): Record<string, any[]>;
906
- } | {
899
+ } | ({
907
900
  CLASS_NAME: string;
908
901
  _zIndex: number;
909
902
  _opts: any;
@@ -925,6 +918,13 @@ export declare const useAmapFitView: (props: UseMapFitViewProps<AMap.Map>) => {
925
918
  clearEvents(type: AMap.EventType): any;
926
919
  emit(type: AMap.EventType, data?: any): any;
927
920
  getEvents(): Record<string, any[]>;
921
+ } | {
922
+ on(type: AMap.EventType | AMap.EventType[], fn: (e: any) => void, context?: any, once?: boolean | undefined): any;
923
+ off(type: AMap.EventType, fn: (e: any) => void, context?: any): any;
924
+ hasEvents(type: AMap.EventType, fn: (e: any) => void, context?: any): boolean;
925
+ clearEvents(type: AMap.EventType): any;
926
+ emit(type: AMap.EventType, data?: any): any;
927
+ getEvents(): Record<string, any[]>;
928
928
  })[]): void;
929
929
  lngLatToCoords(lnglat: [number, number] | AMap.LngLat): [number, number];
930
930
  coordsToLngLat(coords: [number, number]): AMap.LngLat;
@@ -953,7 +953,7 @@ export declare const useAmapFitView: (props: UseMapFitViewProps<AMap.Map>) => {
953
953
  getEvents(): Record<string, any[]>;
954
954
  }[] | undefined, immediately?: boolean | undefined, avoid?: number[] | undefined, maxZoom?: number | undefined): AMap.Bounds | undefined;
955
955
  getFitZoomAndCenterByOverlays(overlayList: any[], avoid?: number[] | undefined, maxZoom?: number | undefined): any[] | undefined;
956
- getFitZoomAndCenterByBounds(bounds: number[] | AMap.Bounds, avoid?: number[] | undefined, maxZoom?: number | undefined): any[];
956
+ getFitZoomAndCenterByBounds(bounds: AMap.Bounds | number[], avoid?: number[] | undefined, maxZoom?: number | undefined): any[];
957
957
  addControl(control: AMap.Control): void;
958
958
  removeControl(control: AMap.Control): void;
959
959
  setMapStyle(value: string): void;
@@ -1132,7 +1132,7 @@ export declare const useAmapFitView: (props: UseMapFitViewProps<AMap.Map>) => {
1132
1132
  getDefaultCursor(): string;
1133
1133
  setDefaultCursor(cursor: string): void;
1134
1134
  getLimitBounds(): AMap.Bounds | undefined;
1135
- setLimitBounds(bounds: number[] | AMap.Bounds): void;
1135
+ setLimitBounds(bounds: AMap.Bounds | number[]): void;
1136
1136
  clearLimitBounds(): void;
1137
1137
  getZooms(): [number, number];
1138
1138
  setZooms(zooms: [number, number]): void;
@@ -1175,18 +1175,11 @@ export declare const useAmapFitView: (props: UseMapFitViewProps<AMap.Map>) => {
1175
1175
  setPitch(pitch: number, immediately?: boolean | undefined, duration?: number | undefined): void;
1176
1176
  getRotation(): number;
1177
1177
  setRotation(rotation?: number | undefined, immediately?: boolean | undefined, duration?: number | undefined): void;
1178
- setBounds(bounds: number[] | AMap.Bounds, immediately?: boolean | undefined, avoid?: number[] | undefined): void;
1178
+ setBounds(bounds: AMap.Bounds | number[], immediately?: boolean | undefined, avoid?: number[] | undefined): void;
1179
1179
  panTo(lnglat: [number, number] | AMap.LngLat, duration?: number | undefined): void;
1180
1180
  panBy(x: number, y: number, duration?: number | undefined): void;
1181
1181
  getContainer(): HTMLDivElement;
1182
1182
  add(features: {
1183
- on(type: AMap.EventType | AMap.EventType[], fn: (e: any) => void, context?: any, once?: boolean | undefined): any;
1184
- off(type: AMap.EventType, fn: (e: any) => void, context?: any): any;
1185
- hasEvents(type: AMap.EventType, fn: (e: any) => void, context?: any): boolean;
1186
- clearEvents(type: AMap.EventType): any;
1187
- emit(type: AMap.EventType, data?: any): any;
1188
- getEvents(): Record<string, any[]>;
1189
- } | {
1190
1183
  CLASS_NAME: string;
1191
1184
  _zIndex: number;
1192
1185
  _opts: any;
@@ -1208,14 +1201,14 @@ export declare const useAmapFitView: (props: UseMapFitViewProps<AMap.Map>) => {
1208
1201
  clearEvents(type: AMap.EventType): any;
1209
1202
  emit(type: AMap.EventType, data?: any): any;
1210
1203
  getEvents(): Record<string, any[]>;
1211
- } | ({
1204
+ } | {
1212
1205
  on(type: AMap.EventType | AMap.EventType[], fn: (e: any) => void, context?: any, once?: boolean | undefined): any;
1213
1206
  off(type: AMap.EventType, fn: (e: any) => void, context?: any): any;
1214
1207
  hasEvents(type: AMap.EventType, fn: (e: any) => void, context?: any): boolean;
1215
1208
  clearEvents(type: AMap.EventType): any;
1216
1209
  emit(type: AMap.EventType, data?: any): any;
1217
1210
  getEvents(): Record<string, any[]>;
1218
- } | {
1211
+ } | ({
1219
1212
  CLASS_NAME: string;
1220
1213
  _zIndex: number;
1221
1214
  _opts: any;
@@ -1237,15 +1230,15 @@ export declare const useAmapFitView: (props: UseMapFitViewProps<AMap.Map>) => {
1237
1230
  clearEvents(type: AMap.EventType): any;
1238
1231
  emit(type: AMap.EventType, data?: any): any;
1239
1232
  getEvents(): Record<string, any[]>;
1240
- })[]): void;
1241
- remove(features: {
1233
+ } | {
1242
1234
  on(type: AMap.EventType | AMap.EventType[], fn: (e: any) => void, context?: any, once?: boolean | undefined): any;
1243
1235
  off(type: AMap.EventType, fn: (e: any) => void, context?: any): any;
1244
1236
  hasEvents(type: AMap.EventType, fn: (e: any) => void, context?: any): boolean;
1245
1237
  clearEvents(type: AMap.EventType): any;
1246
1238
  emit(type: AMap.EventType, data?: any): any;
1247
1239
  getEvents(): Record<string, any[]>;
1248
- } | {
1240
+ })[]): void;
1241
+ remove(features: {
1249
1242
  CLASS_NAME: string;
1250
1243
  _zIndex: number;
1251
1244
  _opts: any;
@@ -1267,14 +1260,14 @@ export declare const useAmapFitView: (props: UseMapFitViewProps<AMap.Map>) => {
1267
1260
  clearEvents(type: AMap.EventType): any;
1268
1261
  emit(type: AMap.EventType, data?: any): any;
1269
1262
  getEvents(): Record<string, any[]>;
1270
- } | ({
1263
+ } | {
1271
1264
  on(type: AMap.EventType | AMap.EventType[], fn: (e: any) => void, context?: any, once?: boolean | undefined): any;
1272
1265
  off(type: AMap.EventType, fn: (e: any) => void, context?: any): any;
1273
1266
  hasEvents(type: AMap.EventType, fn: (e: any) => void, context?: any): boolean;
1274
1267
  clearEvents(type: AMap.EventType): any;
1275
1268
  emit(type: AMap.EventType, data?: any): any;
1276
1269
  getEvents(): Record<string, any[]>;
1277
- } | {
1270
+ } | ({
1278
1271
  CLASS_NAME: string;
1279
1272
  _zIndex: number;
1280
1273
  _opts: any;
@@ -1296,6 +1289,13 @@ export declare const useAmapFitView: (props: UseMapFitViewProps<AMap.Map>) => {
1296
1289
  clearEvents(type: AMap.EventType): any;
1297
1290
  emit(type: AMap.EventType, data?: any): any;
1298
1291
  getEvents(): Record<string, any[]>;
1292
+ } | {
1293
+ on(type: AMap.EventType | AMap.EventType[], fn: (e: any) => void, context?: any, once?: boolean | undefined): any;
1294
+ off(type: AMap.EventType, fn: (e: any) => void, context?: any): any;
1295
+ hasEvents(type: AMap.EventType, fn: (e: any) => void, context?: any): boolean;
1296
+ clearEvents(type: AMap.EventType): any;
1297
+ emit(type: AMap.EventType, data?: any): any;
1298
+ getEvents(): Record<string, any[]>;
1299
1299
  })[]): void;
1300
1300
  lngLatToCoords(lnglat: [number, number] | AMap.LngLat): [number, number];
1301
1301
  coordsToLngLat(coords: [number, number]): AMap.LngLat;
@@ -1324,7 +1324,7 @@ export declare const useAmapFitView: (props: UseMapFitViewProps<AMap.Map>) => {
1324
1324
  getEvents(): Record<string, any[]>;
1325
1325
  }[] | undefined, immediately?: boolean | undefined, avoid?: number[] | undefined, maxZoom?: number | undefined): AMap.Bounds | undefined;
1326
1326
  getFitZoomAndCenterByOverlays(overlayList: any[], avoid?: number[] | undefined, maxZoom?: number | undefined): any[] | undefined;
1327
- getFitZoomAndCenterByBounds(bounds: number[] | AMap.Bounds, avoid?: number[] | undefined, maxZoom?: number | undefined): any[];
1327
+ getFitZoomAndCenterByBounds(bounds: AMap.Bounds | number[], avoid?: number[] | undefined, maxZoom?: number | undefined): any[];
1328
1328
  addControl(control: AMap.Control): void;
1329
1329
  removeControl(control: AMap.Control): void;
1330
1330
  setMapStyle(value: string): void;
@@ -1503,7 +1503,7 @@ export declare const useAmapFitView: (props: UseMapFitViewProps<AMap.Map>) => {
1503
1503
  getDefaultCursor(): string;
1504
1504
  setDefaultCursor(cursor: string): void;
1505
1505
  getLimitBounds(): AMap.Bounds | undefined;
1506
- setLimitBounds(bounds: number[] | AMap.Bounds): void;
1506
+ setLimitBounds(bounds: AMap.Bounds | number[]): void;
1507
1507
  clearLimitBounds(): void;
1508
1508
  getZooms(): [number, number];
1509
1509
  setZooms(zooms: [number, number]): void;
@@ -1546,18 +1546,11 @@ export declare const useAmapFitView: (props: UseMapFitViewProps<AMap.Map>) => {
1546
1546
  setPitch(pitch: number, immediately?: boolean | undefined, duration?: number | undefined): void;
1547
1547
  getRotation(): number;
1548
1548
  setRotation(rotation?: number | undefined, immediately?: boolean | undefined, duration?: number | undefined): void;
1549
- setBounds(bounds: number[] | AMap.Bounds, immediately?: boolean | undefined, avoid?: number[] | undefined): void;
1549
+ setBounds(bounds: AMap.Bounds | number[], immediately?: boolean | undefined, avoid?: number[] | undefined): void;
1550
1550
  panTo(lnglat: [number, number] | AMap.LngLat, duration?: number | undefined): void;
1551
1551
  panBy(x: number, y: number, duration?: number | undefined): void;
1552
1552
  getContainer(): HTMLDivElement;
1553
1553
  add(features: {
1554
- on(type: AMap.EventType | AMap.EventType[], fn: (e: any) => void, context?: any, once?: boolean | undefined): any;
1555
- off(type: AMap.EventType, fn: (e: any) => void, context?: any): any;
1556
- hasEvents(type: AMap.EventType, fn: (e: any) => void, context?: any): boolean;
1557
- clearEvents(type: AMap.EventType): any;
1558
- emit(type: AMap.EventType, data?: any): any;
1559
- getEvents(): Record<string, any[]>;
1560
- } | {
1561
1554
  CLASS_NAME: string;
1562
1555
  _zIndex: number;
1563
1556
  _opts: any;
@@ -1579,14 +1572,14 @@ export declare const useAmapFitView: (props: UseMapFitViewProps<AMap.Map>) => {
1579
1572
  clearEvents(type: AMap.EventType): any;
1580
1573
  emit(type: AMap.EventType, data?: any): any;
1581
1574
  getEvents(): Record<string, any[]>;
1582
- } | ({
1575
+ } | {
1583
1576
  on(type: AMap.EventType | AMap.EventType[], fn: (e: any) => void, context?: any, once?: boolean | undefined): any;
1584
1577
  off(type: AMap.EventType, fn: (e: any) => void, context?: any): any;
1585
1578
  hasEvents(type: AMap.EventType, fn: (e: any) => void, context?: any): boolean;
1586
1579
  clearEvents(type: AMap.EventType): any;
1587
1580
  emit(type: AMap.EventType, data?: any): any;
1588
1581
  getEvents(): Record<string, any[]>;
1589
- } | {
1582
+ } | ({
1590
1583
  CLASS_NAME: string;
1591
1584
  _zIndex: number;
1592
1585
  _opts: any;
@@ -1608,15 +1601,15 @@ export declare const useAmapFitView: (props: UseMapFitViewProps<AMap.Map>) => {
1608
1601
  clearEvents(type: AMap.EventType): any;
1609
1602
  emit(type: AMap.EventType, data?: any): any;
1610
1603
  getEvents(): Record<string, any[]>;
1611
- })[]): void;
1612
- remove(features: {
1604
+ } | {
1613
1605
  on(type: AMap.EventType | AMap.EventType[], fn: (e: any) => void, context?: any, once?: boolean | undefined): any;
1614
1606
  off(type: AMap.EventType, fn: (e: any) => void, context?: any): any;
1615
1607
  hasEvents(type: AMap.EventType, fn: (e: any) => void, context?: any): boolean;
1616
1608
  clearEvents(type: AMap.EventType): any;
1617
1609
  emit(type: AMap.EventType, data?: any): any;
1618
1610
  getEvents(): Record<string, any[]>;
1619
- } | {
1611
+ })[]): void;
1612
+ remove(features: {
1620
1613
  CLASS_NAME: string;
1621
1614
  _zIndex: number;
1622
1615
  _opts: any;
@@ -1638,14 +1631,14 @@ export declare const useAmapFitView: (props: UseMapFitViewProps<AMap.Map>) => {
1638
1631
  clearEvents(type: AMap.EventType): any;
1639
1632
  emit(type: AMap.EventType, data?: any): any;
1640
1633
  getEvents(): Record<string, any[]>;
1641
- } | ({
1634
+ } | {
1642
1635
  on(type: AMap.EventType | AMap.EventType[], fn: (e: any) => void, context?: any, once?: boolean | undefined): any;
1643
1636
  off(type: AMap.EventType, fn: (e: any) => void, context?: any): any;
1644
1637
  hasEvents(type: AMap.EventType, fn: (e: any) => void, context?: any): boolean;
1645
1638
  clearEvents(type: AMap.EventType): any;
1646
1639
  emit(type: AMap.EventType, data?: any): any;
1647
1640
  getEvents(): Record<string, any[]>;
1648
- } | {
1641
+ } | ({
1649
1642
  CLASS_NAME: string;
1650
1643
  _zIndex: number;
1651
1644
  _opts: any;
@@ -1667,6 +1660,13 @@ export declare const useAmapFitView: (props: UseMapFitViewProps<AMap.Map>) => {
1667
1660
  clearEvents(type: AMap.EventType): any;
1668
1661
  emit(type: AMap.EventType, data?: any): any;
1669
1662
  getEvents(): Record<string, any[]>;
1663
+ } | {
1664
+ on(type: AMap.EventType | AMap.EventType[], fn: (e: any) => void, context?: any, once?: boolean | undefined): any;
1665
+ off(type: AMap.EventType, fn: (e: any) => void, context?: any): any;
1666
+ hasEvents(type: AMap.EventType, fn: (e: any) => void, context?: any): boolean;
1667
+ clearEvents(type: AMap.EventType): any;
1668
+ emit(type: AMap.EventType, data?: any): any;
1669
+ getEvents(): Record<string, any[]>;
1670
1670
  })[]): void;
1671
1671
  lngLatToCoords(lnglat: [number, number] | AMap.LngLat): [number, number];
1672
1672
  coordsToLngLat(coords: [number, number]): AMap.LngLat;
@@ -1695,7 +1695,7 @@ export declare const useAmapFitView: (props: UseMapFitViewProps<AMap.Map>) => {
1695
1695
  getEvents(): Record<string, any[]>;
1696
1696
  }[] | undefined, immediately?: boolean | undefined, avoid?: number[] | undefined, maxZoom?: number | undefined): AMap.Bounds | undefined;
1697
1697
  getFitZoomAndCenterByOverlays(overlayList: any[], avoid?: number[] | undefined, maxZoom?: number | undefined): any[] | undefined;
1698
- getFitZoomAndCenterByBounds(bounds: number[] | AMap.Bounds, avoid?: number[] | undefined, maxZoom?: number | undefined): any[];
1698
+ getFitZoomAndCenterByBounds(bounds: AMap.Bounds | number[], avoid?: number[] | undefined, maxZoom?: number | undefined): any[];
1699
1699
  addControl(control: AMap.Control): void;
1700
1700
  removeControl(control: AMap.Control): void;
1701
1701
  setMapStyle(value: string): void;
@@ -1874,7 +1874,7 @@ export declare const useAmapFitView: (props: UseMapFitViewProps<AMap.Map>) => {
1874
1874
  getDefaultCursor(): string;
1875
1875
  setDefaultCursor(cursor: string): void;
1876
1876
  getLimitBounds(): AMap.Bounds | undefined;
1877
- setLimitBounds(bounds: number[] | AMap.Bounds): void;
1877
+ setLimitBounds(bounds: AMap.Bounds | number[]): void;
1878
1878
  clearLimitBounds(): void;
1879
1879
  getZooms(): [number, number];
1880
1880
  setZooms(zooms: [number, number]): void;
@@ -1917,18 +1917,11 @@ export declare const useAmapFitView: (props: UseMapFitViewProps<AMap.Map>) => {
1917
1917
  setPitch(pitch: number, immediately?: boolean | undefined, duration?: number | undefined): void;
1918
1918
  getRotation(): number;
1919
1919
  setRotation(rotation?: number | undefined, immediately?: boolean | undefined, duration?: number | undefined): void;
1920
- setBounds(bounds: number[] | AMap.Bounds, immediately?: boolean | undefined, avoid?: number[] | undefined): void;
1920
+ setBounds(bounds: AMap.Bounds | number[], immediately?: boolean | undefined, avoid?: number[] | undefined): void;
1921
1921
  panTo(lnglat: [number, number] | AMap.LngLat, duration?: number | undefined): void;
1922
1922
  panBy(x: number, y: number, duration?: number | undefined): void;
1923
1923
  getContainer(): HTMLDivElement;
1924
1924
  add(features: {
1925
- on(type: AMap.EventType | AMap.EventType[], fn: (e: any) => void, context?: any, once?: boolean | undefined): any;
1926
- off(type: AMap.EventType, fn: (e: any) => void, context?: any): any;
1927
- hasEvents(type: AMap.EventType, fn: (e: any) => void, context?: any): boolean;
1928
- clearEvents(type: AMap.EventType): any;
1929
- emit(type: AMap.EventType, data?: any): any;
1930
- getEvents(): Record<string, any[]>;
1931
- } | {
1932
1925
  CLASS_NAME: string;
1933
1926
  _zIndex: number;
1934
1927
  _opts: any;
@@ -1950,14 +1943,14 @@ export declare const useAmapFitView: (props: UseMapFitViewProps<AMap.Map>) => {
1950
1943
  clearEvents(type: AMap.EventType): any;
1951
1944
  emit(type: AMap.EventType, data?: any): any;
1952
1945
  getEvents(): Record<string, any[]>;
1953
- } | ({
1946
+ } | {
1954
1947
  on(type: AMap.EventType | AMap.EventType[], fn: (e: any) => void, context?: any, once?: boolean | undefined): any;
1955
1948
  off(type: AMap.EventType, fn: (e: any) => void, context?: any): any;
1956
1949
  hasEvents(type: AMap.EventType, fn: (e: any) => void, context?: any): boolean;
1957
1950
  clearEvents(type: AMap.EventType): any;
1958
1951
  emit(type: AMap.EventType, data?: any): any;
1959
1952
  getEvents(): Record<string, any[]>;
1960
- } | {
1953
+ } | ({
1961
1954
  CLASS_NAME: string;
1962
1955
  _zIndex: number;
1963
1956
  _opts: any;
@@ -1979,15 +1972,15 @@ export declare const useAmapFitView: (props: UseMapFitViewProps<AMap.Map>) => {
1979
1972
  clearEvents(type: AMap.EventType): any;
1980
1973
  emit(type: AMap.EventType, data?: any): any;
1981
1974
  getEvents(): Record<string, any[]>;
1982
- })[]): void;
1983
- remove(features: {
1975
+ } | {
1984
1976
  on(type: AMap.EventType | AMap.EventType[], fn: (e: any) => void, context?: any, once?: boolean | undefined): any;
1985
1977
  off(type: AMap.EventType, fn: (e: any) => void, context?: any): any;
1986
1978
  hasEvents(type: AMap.EventType, fn: (e: any) => void, context?: any): boolean;
1987
1979
  clearEvents(type: AMap.EventType): any;
1988
1980
  emit(type: AMap.EventType, data?: any): any;
1989
1981
  getEvents(): Record<string, any[]>;
1990
- } | {
1982
+ })[]): void;
1983
+ remove(features: {
1991
1984
  CLASS_NAME: string;
1992
1985
  _zIndex: number;
1993
1986
  _opts: any;
@@ -2009,14 +2002,14 @@ export declare const useAmapFitView: (props: UseMapFitViewProps<AMap.Map>) => {
2009
2002
  clearEvents(type: AMap.EventType): any;
2010
2003
  emit(type: AMap.EventType, data?: any): any;
2011
2004
  getEvents(): Record<string, any[]>;
2012
- } | ({
2005
+ } | {
2013
2006
  on(type: AMap.EventType | AMap.EventType[], fn: (e: any) => void, context?: any, once?: boolean | undefined): any;
2014
2007
  off(type: AMap.EventType, fn: (e: any) => void, context?: any): any;
2015
2008
  hasEvents(type: AMap.EventType, fn: (e: any) => void, context?: any): boolean;
2016
2009
  clearEvents(type: AMap.EventType): any;
2017
2010
  emit(type: AMap.EventType, data?: any): any;
2018
2011
  getEvents(): Record<string, any[]>;
2019
- } | {
2012
+ } | ({
2020
2013
  CLASS_NAME: string;
2021
2014
  _zIndex: number;
2022
2015
  _opts: any;
@@ -2038,6 +2031,13 @@ export declare const useAmapFitView: (props: UseMapFitViewProps<AMap.Map>) => {
2038
2031
  clearEvents(type: AMap.EventType): any;
2039
2032
  emit(type: AMap.EventType, data?: any): any;
2040
2033
  getEvents(): Record<string, any[]>;
2034
+ } | {
2035
+ on(type: AMap.EventType | AMap.EventType[], fn: (e: any) => void, context?: any, once?: boolean | undefined): any;
2036
+ off(type: AMap.EventType, fn: (e: any) => void, context?: any): any;
2037
+ hasEvents(type: AMap.EventType, fn: (e: any) => void, context?: any): boolean;
2038
+ clearEvents(type: AMap.EventType): any;
2039
+ emit(type: AMap.EventType, data?: any): any;
2040
+ getEvents(): Record<string, any[]>;
2041
2041
  })[]): void;
2042
2042
  lngLatToCoords(lnglat: [number, number] | AMap.LngLat): [number, number];
2043
2043
  coordsToLngLat(coords: [number, number]): AMap.LngLat;
@@ -2066,7 +2066,7 @@ export declare const useAmapFitView: (props: UseMapFitViewProps<AMap.Map>) => {
2066
2066
  getEvents(): Record<string, any[]>;
2067
2067
  }[] | undefined, immediately?: boolean | undefined, avoid?: number[] | undefined, maxZoom?: number | undefined): AMap.Bounds | undefined;
2068
2068
  getFitZoomAndCenterByOverlays(overlayList: any[], avoid?: number[] | undefined, maxZoom?: number | undefined): any[] | undefined;
2069
- getFitZoomAndCenterByBounds(bounds: number[] | AMap.Bounds, avoid?: number[] | undefined, maxZoom?: number | undefined): any[];
2069
+ getFitZoomAndCenterByBounds(bounds: AMap.Bounds | number[], avoid?: number[] | undefined, maxZoom?: number | undefined): any[];
2070
2070
  addControl(control: AMap.Control): void;
2071
2071
  removeControl(control: AMap.Control): void;
2072
2072
  setMapStyle(value: string): void;
@@ -2245,7 +2245,7 @@ export declare const useAmapFitView: (props: UseMapFitViewProps<AMap.Map>) => {
2245
2245
  getDefaultCursor(): string;
2246
2246
  setDefaultCursor(cursor: string): void;
2247
2247
  getLimitBounds(): AMap.Bounds | undefined;
2248
- setLimitBounds(bounds: number[] | AMap.Bounds): void;
2248
+ setLimitBounds(bounds: AMap.Bounds | number[]): void;
2249
2249
  clearLimitBounds(): void;
2250
2250
  getZooms(): [number, number];
2251
2251
  setZooms(zooms: [number, number]): void;
@@ -2280,7 +2280,7 @@ export declare const useAmapFitView: (props: UseMapFitViewProps<AMap.Map>) => {
2280
2280
  getOrientation(): number | null | undefined;
2281
2281
  setOrientation(orientation: number | undefined): void;
2282
2282
  getSize(): AMap.Vector2;
2283
- setSize(size: AMap.Vector2 | AMap.Size): void;
2283
+ setSize(size: AMap.Size | AMap.Vector2): void;
2284
2284
  getzIndex(): number | undefined;
2285
2285
  setzIndex(zIndex: number): void;
2286
2286
  getOptions(): AMap.OverlayOptions;
@@ -2300,7 +2300,7 @@ export declare const useAmapFitView: (props: UseMapFitViewProps<AMap.Map>) => {
2300
2300
  emit(type: AMap.EventType, data?: any): any;
2301
2301
  getEvents(): Record<string, any[]>;
2302
2302
  }>;
2303
- setFitView: () => void;
2303
+ setFitView: (immediate?: boolean) => void;
2304
2304
  };
2305
2305
  export declare const useGmapFitView: (props: UseMapFitViewProps<google.maps.Map>) => {
2306
2306
  registerFitVeiw: RegisterOverlay<GmapOverlay>;