react-native-maps 1.21.0-alpha.11 → 1.21.0-alpha.111
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/android/build.gradle +77 -57
- package/android/gradlew +1 -2
- package/android/src/main/java/com/rnmaps/fabric/CalloutManager.java +77 -0
- package/android/src/main/java/com/rnmaps/fabric/CircleManager.java +94 -0
- package/android/src/main/java/com/rnmaps/fabric/JSONUtil.java +86 -0
- package/android/src/main/java/com/rnmaps/fabric/MapViewManager.java +619 -0
- package/android/src/main/java/com/rnmaps/fabric/MarkerManager.java +258 -0
- package/android/src/main/java/com/rnmaps/fabric/NativeAirMapsModule.java +235 -2
- package/android/src/main/java/com/rnmaps/fabric/OverlayManager.java +95 -0
- package/android/src/main/java/com/rnmaps/fabric/PolygonManager.java +89 -0
- package/android/src/main/java/com/rnmaps/fabric/PolylineManager.java +121 -0
- package/android/src/main/java/com/rnmaps/fabric/event/OnCalloutPressEvent.java +25 -0
- package/android/src/main/java/com/rnmaps/fabric/event/OnDeselectEvent.java +28 -0
- package/android/src/main/java/com/rnmaps/fabric/event/OnDoublePressEvent.java +27 -0
- package/android/src/main/java/com/rnmaps/fabric/event/OnDragEndEvent.java +28 -0
- package/android/src/main/java/com/rnmaps/fabric/event/OnDragEvent.java +28 -0
- package/android/src/main/java/com/rnmaps/fabric/event/OnDragStartEvent.java +28 -0
- package/android/src/main/java/com/rnmaps/fabric/event/OnIndoorBuildingFocusedEvent.java +28 -0
- package/android/src/main/java/com/rnmaps/fabric/event/OnIndoorLevelActivatedEvent.java +28 -0
- package/android/src/main/java/com/rnmaps/fabric/event/OnKmlReadyEvent.java +28 -0
- package/android/src/main/java/com/rnmaps/fabric/event/OnLongPressEvent.java +28 -0
- package/android/src/main/java/com/rnmaps/fabric/event/OnMapLoadedEvent.java +29 -0
- package/android/src/main/java/com/rnmaps/fabric/event/OnMapReadyEvent.java +29 -0
- package/android/src/main/java/com/rnmaps/fabric/event/OnMarkerDeselectEvent.java +28 -0
- package/android/src/main/java/com/rnmaps/fabric/event/OnMarkerDragEndEvent.java +28 -0
- package/android/src/main/java/com/rnmaps/fabric/event/OnMarkerDragEvent.java +28 -0
- package/android/src/main/java/com/rnmaps/fabric/event/OnMarkerDragStartEvent.java +28 -0
- package/android/src/main/java/com/rnmaps/fabric/event/OnMarkerPressEvent.java +28 -0
- package/android/src/main/java/com/rnmaps/fabric/event/OnMarkerSelectEvent.java +28 -0
- package/android/src/main/java/com/rnmaps/fabric/event/OnPanDragEvent.java +28 -0
- package/android/src/main/java/com/rnmaps/fabric/event/OnPoiClickEvent.java +27 -0
- package/android/src/main/java/com/rnmaps/fabric/event/OnPressEvent.java +27 -0
- package/android/src/main/java/com/rnmaps/fabric/event/OnRegionChangeCompleteEvent.java +30 -0
- package/android/src/main/java/com/rnmaps/fabric/event/OnRegionChangeEvent.java +48 -0
- package/android/src/main/java/com/rnmaps/fabric/event/OnRegionChangeStartEvent.java +33 -0
- package/android/src/main/java/com/rnmaps/fabric/event/OnSelectEvent.java +28 -0
- package/android/src/main/java/com/rnmaps/fabric/event/OnUserLocationChangeEvent.java +28 -0
- package/android/src/main/java/com/rnmaps/maps/MapAirModulePackage.java +39 -3
- package/android/src/main/java/com/rnmaps/maps/MapCallout.java +18 -0
- package/android/src/main/java/com/rnmaps/maps/MapCircle.java +24 -0
- package/android/src/main/java/com/rnmaps/maps/MapManager.java +14 -14
- package/android/src/main/java/com/rnmaps/maps/MapMarker.java +637 -556
- package/android/src/main/java/com/rnmaps/maps/MapMarkerManager.java +3 -3
- package/android/src/main/java/com/rnmaps/maps/MapModule.java +206 -206
- package/android/src/main/java/com/rnmaps/maps/MapOverlay.java +267 -151
- package/android/src/main/java/com/rnmaps/maps/MapPolygon.java +31 -1
- package/android/src/main/java/com/rnmaps/maps/MapPolyline.java +207 -141
- package/android/src/main/java/com/rnmaps/maps/MapPolylineManager.java +1 -16
- package/android/src/main/java/com/rnmaps/maps/MapView.java +1650 -1337
- package/ios/AirGoogleMaps/AIRGMSMarker.h +1 -1
- package/ios/AirGoogleMaps/AIRGoogleMap.h +9 -10
- package/ios/AirGoogleMaps/AIRGoogleMap.m +112 -74
- package/ios/AirGoogleMaps/AIRGoogleMapCircle.m +23 -11
- package/ios/AirGoogleMaps/AIRGoogleMapManager.m +10 -9
- package/ios/AirGoogleMaps/AIRGoogleMapMarker.h +2 -0
- package/ios/AirGoogleMaps/AIRGoogleMapMarker.m +347 -243
- package/ios/AirGoogleMaps/AIRGoogleMapMarkerManager.m +1 -1
- package/ios/AirGoogleMaps/AIRGoogleMapPolygon.h +2 -1
- package/ios/AirGoogleMaps/AIRGoogleMapPolygon.m +30 -0
- package/ios/AirGoogleMaps/AIRGoogleMapPolyline.h +0 -1
- package/ios/AirGoogleMaps/AIRGoogleMapPolyline.m +0 -7
- package/ios/AirGoogleMaps/AIRGoogleMapUrlTile.m +2 -2
- package/ios/AirGoogleMaps/AIRGoogleMapWMSTile.h +1 -1
- package/ios/AirGoogleMaps/AIRGoogleMapWMSTile.m +4 -4
- package/ios/AirGoogleMaps/RCTConvert+GMSMapViewType.m +2 -0
- package/ios/AirGoogleMaps/RNMapsGoogleMapView.mm +137 -57
- package/ios/AirGoogleMaps/RNMapsGoogleMapViewManager.mm +16 -1
- package/ios/AirGoogleMaps/RNMapsGooglePolygonView.h +26 -0
- package/ios/AirGoogleMaps/RNMapsGooglePolygonView.mm +217 -0
- package/ios/AirGoogleMaps/RNMapsGooglePolygonViewManager.mm +26 -0
- package/ios/AirMaps/AIRMap.h +7 -7
- package/ios/AirMaps/AIRMap.m +227 -236
- package/ios/AirMaps/AIRMapManager.m +13 -7
- package/ios/AirMaps/AIRMapMarker.h +1 -0
- package/ios/AirMaps/AIRMapMarker.m +165 -103
- package/ios/AirMaps/Callout/SMCalloutView.m +1 -1
- package/ios/AirMaps/NSObject+DynamicLoad.h +16 -0
- package/ios/AirMaps/NSObject+DynamicLoad.m +28 -0
- package/ios/AirMaps/RNMapsAirModule.h +1 -1
- package/ios/AirMaps/RNMapsAirModule.mm +4 -3
- package/ios/AirMaps/RNMapsAirModuleDelegate.h +2 -2
- package/ios/AirMaps/RNMapsMapView.mm +332 -295
- package/ios/AirMaps/RNMapsMapViewManager.mm +19 -1
- package/ios/AirMaps/RNMapsMarkerView.h +24 -0
- package/ios/AirMaps/RNMapsMarkerView.mm +430 -0
- package/ios/AirMaps/RNMapsMarkerViewManager.mm +28 -0
- package/ios/AirMaps.xcodeproj/project.pbxproj +20 -0
- package/lib/MapCircle.d.ts +1 -1
- package/lib/MapHeatmap.d.ts +2 -2
- package/lib/MapHeatmap.js +1 -1
- package/lib/MapMarker.d.ts +16 -3
- package/lib/MapMarker.js +55 -13
- package/lib/MapMarkerNativeComponent.js +0 -2
- package/lib/MapOverlay.d.ts +1 -0
- package/lib/MapOverlay.js +11 -9
- package/lib/MapPolygon.d.ts +1 -1
- package/lib/MapPolyline.d.ts +7 -7
- package/lib/MapView.d.ts +17 -29
- package/lib/MapView.js +114 -128
- package/lib/MapView.types.d.ts +1 -1
- package/lib/createFabricMap.d.ts +1 -0
- package/lib/createFabricMap.js +17 -4
- package/lib/decorateMapComponent.js +40 -0
- package/lib/fixImageProp.d.ts +4 -0
- package/lib/fixImageProp.js +16 -0
- package/lib/specs/NativeAirMapsModule.d.ts +2 -2
- package/lib/specs/NativeComponentCallout.d.ts +46 -0
- package/lib/specs/NativeComponentCallout.js +9 -0
- package/lib/specs/NativeComponentCircle.d.ts +74 -0
- package/lib/specs/NativeComponentCircle.js +7 -0
- package/lib/specs/NativeComponentGoogleMapView.d.ts +19 -22
- package/lib/specs/NativeComponentGoogleMapView.js +1 -0
- package/lib/specs/NativeComponentGooglePolygon.d.ts +75 -0
- package/lib/specs/NativeComponentGooglePolygon.js +7 -0
- package/lib/specs/NativeComponentMapView.d.ts +43 -56
- package/lib/specs/NativeComponentMapView.js +2 -3
- package/lib/specs/NativeComponentMarker.d.ts +258 -0
- package/lib/specs/NativeComponentMarker.js +19 -0
- package/lib/specs/NativeComponentOverlay.d.ts +67 -0
- package/lib/specs/NativeComponentOverlay.js +7 -0
- package/lib/specs/NativeComponentPolyline.d.ts +101 -0
- package/lib/specs/NativeComponentPolyline.js +7 -0
- package/package.json +21 -19
- package/react-native-maps.podspec +15 -15
- package/specs/NativeAirMapsModule.ts +36 -0
- package/specs/NativeComponentCallout.ts +63 -0
- package/specs/NativeComponentCircle.ts +94 -0
- package/specs/NativeComponentGoogleMapView.ts +913 -0
- package/specs/NativeComponentGooglePolygon.ts +94 -0
- package/specs/NativeComponentMapView.ts +1059 -0
- package/specs/NativeComponentMarker.ts +326 -0
- package/specs/NativeComponentOverlay.ts +89 -0
- package/specs/NativeComponentPolyline.ts +124 -0
|
@@ -133,11 +133,9 @@ export type IndoorLevel = Readonly<{
|
|
|
133
133
|
shortName: string;
|
|
134
134
|
}>;
|
|
135
135
|
export type IndoorLevelActivatedEventHandler = DirectEventHandler<Readonly<{
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
shortName: string;
|
|
140
|
-
};
|
|
136
|
+
activeLevelIndex: Int32;
|
|
137
|
+
name: string;
|
|
138
|
+
shortName: string;
|
|
141
139
|
}>>;
|
|
142
140
|
export type IndoorBuilding = Readonly<{
|
|
143
141
|
underground: boolean;
|
|
@@ -145,10 +143,9 @@ export type IndoorBuilding = Readonly<{
|
|
|
145
143
|
levels: ReadonlyArray<IndoorLevel>;
|
|
146
144
|
}>;
|
|
147
145
|
export type IndoorBuildingEventHandler = DirectEventHandler<Readonly<{
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
};
|
|
146
|
+
underground: boolean;
|
|
147
|
+
activeLevelIndex: Int32;
|
|
148
|
+
levels: string;
|
|
152
149
|
}>>;
|
|
153
150
|
export type KmlMapEventHandler = DirectEventHandler<Readonly<{}>>;
|
|
154
151
|
export type MapLoadedEventHandler = DirectEventHandler<Readonly<{}>>;
|
|
@@ -517,7 +514,7 @@ export interface MapFabricNativeProps extends ViewProps {
|
|
|
517
514
|
* @platform iOS: Google Maps only
|
|
518
515
|
* @platform Android: Supported
|
|
519
516
|
*/
|
|
520
|
-
pitchEnabled?: boolean
|
|
517
|
+
pitchEnabled?: WithDefault<boolean, true>;
|
|
521
518
|
/**
|
|
522
519
|
* The region to be displayed by the map.
|
|
523
520
|
* The region is defined by the center coordinates and the span of coordinates to display.
|
|
@@ -533,7 +530,7 @@ export interface MapFabricNativeProps extends ViewProps {
|
|
|
533
530
|
* @platform iOS: Google Maps only
|
|
534
531
|
* @platform Android: Supported
|
|
535
532
|
*/
|
|
536
|
-
rotateEnabled?: boolean
|
|
533
|
+
rotateEnabled?: WithDefault<boolean, true>;
|
|
537
534
|
/**
|
|
538
535
|
* If `false` the map will stay centered while rotating or zooming.
|
|
539
536
|
*
|
|
@@ -541,7 +538,7 @@ export interface MapFabricNativeProps extends ViewProps {
|
|
|
541
538
|
* @platform iOS: Google Maps only
|
|
542
539
|
* @platform Android: Supported
|
|
543
540
|
*/
|
|
544
|
-
scrollDuringRotateOrZoomEnabled?: boolean
|
|
541
|
+
scrollDuringRotateOrZoomEnabled?: WithDefault<boolean, true>;
|
|
545
542
|
/**
|
|
546
543
|
* If `false` the user won't be able to change the map region being displayed.
|
|
547
544
|
*
|
|
@@ -549,7 +546,7 @@ export interface MapFabricNativeProps extends ViewProps {
|
|
|
549
546
|
* @platform iOS: Supported
|
|
550
547
|
* @platform Android: Supported
|
|
551
548
|
*/
|
|
552
|
-
scrollEnabled?: boolean
|
|
549
|
+
scrollEnabled?: WithDefault<boolean, true>;
|
|
553
550
|
/**
|
|
554
551
|
* A Boolean indicating whether the map displays extruded building information.
|
|
555
552
|
*
|
|
@@ -557,7 +554,7 @@ export interface MapFabricNativeProps extends ViewProps {
|
|
|
557
554
|
* @platform iOS: Not supported
|
|
558
555
|
* @platform Android: Supported
|
|
559
556
|
*/
|
|
560
|
-
showsBuildings?: boolean
|
|
557
|
+
showsBuildings?: WithDefault<boolean, true>;
|
|
561
558
|
/**
|
|
562
559
|
* If `false` compass won't be displayed on the map.
|
|
563
560
|
*
|
|
@@ -565,7 +562,7 @@ export interface MapFabricNativeProps extends ViewProps {
|
|
|
565
562
|
* @platform iOS: Supported
|
|
566
563
|
* @platform Android: Supported
|
|
567
564
|
*/
|
|
568
|
-
showsCompass?: boolean
|
|
565
|
+
showsCompass?: WithDefault<boolean, true>;
|
|
569
566
|
/**
|
|
570
567
|
* A Boolean indicating whether indoor level picker should be enabled.
|
|
571
568
|
*
|
|
@@ -581,7 +578,7 @@ export interface MapFabricNativeProps extends ViewProps {
|
|
|
581
578
|
* @platform iOS: Google Maps only
|
|
582
579
|
* @platform Android: Supported
|
|
583
580
|
*/
|
|
584
|
-
showsIndoors?: boolean
|
|
581
|
+
showsIndoors?: WithDefault<boolean, true>;
|
|
585
582
|
/**
|
|
586
583
|
* If `false` hide the button to move map to the current user's location.
|
|
587
584
|
*
|
|
@@ -589,7 +586,7 @@ export interface MapFabricNativeProps extends ViewProps {
|
|
|
589
586
|
* @platform iOS: Google Maps only
|
|
590
587
|
* @platform Android: Supported
|
|
591
588
|
*/
|
|
592
|
-
showsMyLocationButton?: boolean
|
|
589
|
+
showsMyLocationButton?: WithDefault<boolean, true>;
|
|
593
590
|
/**
|
|
594
591
|
* If `false` points of interest won't be displayed on the map.
|
|
595
592
|
* TODO: DEPRECATED? Doesn't seem to do anything
|
|
@@ -609,7 +606,6 @@ export interface MapFabricNativeProps extends ViewProps {
|
|
|
609
606
|
showsScale?: boolean;
|
|
610
607
|
/**
|
|
611
608
|
* A Boolean value indicating whether the map displays traffic information.
|
|
612
|
-
* TODO: Look into android support
|
|
613
609
|
*
|
|
614
610
|
* @default false
|
|
615
611
|
* @platform iOS: Supported
|
|
@@ -630,8 +626,8 @@ export interface MapFabricNativeProps extends ViewProps {
|
|
|
630
626
|
* Sets the map to the style selected.
|
|
631
627
|
*
|
|
632
628
|
* @default System setting
|
|
633
|
-
* @platform iOS:
|
|
634
|
-
* @platform Android:
|
|
629
|
+
* @platform iOS: Supported
|
|
630
|
+
* @platform Android: Supported
|
|
635
631
|
*/
|
|
636
632
|
userInterfaceStyle?: WithDefault<'system' | 'light' | 'dark', 'system'>;
|
|
637
633
|
/**
|
|
@@ -689,7 +685,7 @@ export interface MapFabricNativeProps extends ViewProps {
|
|
|
689
685
|
* @platform iOS: Supported
|
|
690
686
|
* @platform Android: Supported
|
|
691
687
|
*/
|
|
692
|
-
zoomEnabled?: boolean
|
|
688
|
+
zoomEnabled?: WithDefault<boolean, true>;
|
|
693
689
|
/**
|
|
694
690
|
* If `false` the user won't be able to double tap to zoom the map.
|
|
695
691
|
* **Note:** But it will greatly decrease delay of tap gesture recognition.
|
|
@@ -698,7 +694,7 @@ export interface MapFabricNativeProps extends ViewProps {
|
|
|
698
694
|
* @platform iOS: Google Maps only
|
|
699
695
|
* @platform Android: Not supported
|
|
700
696
|
*/
|
|
701
|
-
zoomTapEnabled?: boolean
|
|
697
|
+
zoomTapEnabled?: WithDefault<boolean, true>;
|
|
702
698
|
}
|
|
703
699
|
export interface NativeCommands {
|
|
704
700
|
animateToRegion: (viewRef: React.ElementRef<React.ComponentType>, regionJSON: string, duration: Int32) => void;
|
|
@@ -707,6 +703,7 @@ export interface NativeCommands {
|
|
|
707
703
|
fitToElements: (viewRef: React.ElementRef<React.ComponentType>, edgePaddingJSON: string, animated: boolean) => void;
|
|
708
704
|
fitToSuppliedMarkers: (viewRef: React.ElementRef<React.ComponentType>, markersJSON: string, edgePaddingJSON: string, animated: boolean) => void;
|
|
709
705
|
fitToCoordinates: (viewRef: React.ElementRef<React.ComponentType>, coordinatesJSON: string, edgePaddingJSON: string, animated: boolean) => void;
|
|
706
|
+
setIndoorActiveLevelIndex: (viewRef: React.ElementRef<React.ComponentType>, activeLevelIndex: Int32) => void;
|
|
710
707
|
}
|
|
711
708
|
export declare const Commands: NativeCommands;
|
|
712
709
|
declare const _default: HostComponent<MapFabricNativeProps>;
|
|
@@ -0,0 +1,75 @@
|
|
|
1
|
+
import type { HostComponent, ViewProps, ColorValue } from 'react-native';
|
|
2
|
+
import { Double, BubblingEventHandler } from 'react-native/Libraries/Types/CodegenTypes';
|
|
3
|
+
export type LatLng = Readonly<{
|
|
4
|
+
latitude: Double;
|
|
5
|
+
longitude: Double;
|
|
6
|
+
}>;
|
|
7
|
+
export type PolygonPressEventHandler = BubblingEventHandler<Readonly<{
|
|
8
|
+
action?: string;
|
|
9
|
+
id: string;
|
|
10
|
+
coordinate: {
|
|
11
|
+
latitude: Double;
|
|
12
|
+
longitude: Double;
|
|
13
|
+
};
|
|
14
|
+
position?: {
|
|
15
|
+
x: Double;
|
|
16
|
+
y: Double;
|
|
17
|
+
};
|
|
18
|
+
}>>;
|
|
19
|
+
export interface PolygonFabricNativeProps extends ViewProps {
|
|
20
|
+
/**
|
|
21
|
+
* An array of coordinates to describe the polygon
|
|
22
|
+
*
|
|
23
|
+
* @platform iOS: Supported
|
|
24
|
+
* @platform Android: Supported
|
|
25
|
+
*/
|
|
26
|
+
coordinates: ReadonlyArray<LatLng>;
|
|
27
|
+
/**
|
|
28
|
+
* The fill color to use for the path.
|
|
29
|
+
*
|
|
30
|
+
* @default `#000`, `rgba(r,g,b,0.5)`
|
|
31
|
+
* @platform iOS: Supported
|
|
32
|
+
* @platform Android: Supported
|
|
33
|
+
*/
|
|
34
|
+
fillColor?: ColorValue;
|
|
35
|
+
/**
|
|
36
|
+
* The stroke color to use for the path.
|
|
37
|
+
*
|
|
38
|
+
* @default `#000`, `rgba(r,g,b,0.5)`
|
|
39
|
+
* @platform iOS: Supported
|
|
40
|
+
* @platform Android: Supported
|
|
41
|
+
*/
|
|
42
|
+
strokeColor?: ColorValue;
|
|
43
|
+
/**
|
|
44
|
+
* Boolean to indicate whether to draw each segment of the line as a geodesic as opposed to straight lines on the Mercator projection.
|
|
45
|
+
* A geodesic is the shortest path between two points on the Earth's surface.
|
|
46
|
+
* The geodesic curve is constructed assuming the Earth is a sphere.
|
|
47
|
+
*
|
|
48
|
+
* @platform iOS: Google Maps only
|
|
49
|
+
* @platform Android: Supported
|
|
50
|
+
*/
|
|
51
|
+
geodesic?: boolean;
|
|
52
|
+
/**
|
|
53
|
+
* A 2d array of coordinates to describe holes of the polygon where each hole has at least 3 points.
|
|
54
|
+
*
|
|
55
|
+
* @platform iOS: Supported
|
|
56
|
+
* @platform Android: Supported
|
|
57
|
+
*/
|
|
58
|
+
holes?: ReadonlyArray<ReadonlyArray<LatLng>>;
|
|
59
|
+
/**
|
|
60
|
+
* Boolean to allow a polygon to be tappable and use the onPress function.
|
|
61
|
+
*
|
|
62
|
+
* @platform iOS: Google Maps only
|
|
63
|
+
* @platform Android: Supported
|
|
64
|
+
*/
|
|
65
|
+
tappable?: boolean;
|
|
66
|
+
/**
|
|
67
|
+
* Callback that is called when user taps on the map.
|
|
68
|
+
*
|
|
69
|
+
* @platform iOS: Supported
|
|
70
|
+
* @platform Android: Supported
|
|
71
|
+
*/
|
|
72
|
+
onPress?: PolygonPressEventHandler;
|
|
73
|
+
}
|
|
74
|
+
declare const _default: HostComponent<PolygonFabricNativeProps>;
|
|
75
|
+
export default _default;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
const codegenNativeComponent_1 = __importDefault(require("react-native/Libraries/Utilities/codegenNativeComponent"));
|
|
7
|
+
exports.default = (0, codegenNativeComponent_1.default)('RNMapsGooglePolygon', {});
|
|
@@ -14,7 +14,7 @@ export type Frame = Readonly<{
|
|
|
14
14
|
width: Double;
|
|
15
15
|
height: Double;
|
|
16
16
|
}>;
|
|
17
|
-
export type ClickEvent =
|
|
17
|
+
export type ClickEvent = DirectEventHandler<Readonly<{
|
|
18
18
|
coordinate: {
|
|
19
19
|
latitude: Double;
|
|
20
20
|
longitude: Double;
|
|
@@ -48,7 +48,7 @@ export type LongPressEventHandler = BubblingEventHandler<Readonly<{
|
|
|
48
48
|
};
|
|
49
49
|
action?: string;
|
|
50
50
|
}>>;
|
|
51
|
-
export type MarkerDeselectEventHandler =
|
|
51
|
+
export type MarkerDeselectEventHandler = DirectEventHandler<Readonly<{
|
|
52
52
|
action?: string;
|
|
53
53
|
id: string;
|
|
54
54
|
coordinate: {
|
|
@@ -56,7 +56,7 @@ export type MarkerDeselectEventHandler = BubblingEventHandler<Readonly<{
|
|
|
56
56
|
longitude: Double;
|
|
57
57
|
};
|
|
58
58
|
}>>;
|
|
59
|
-
export type MarkerSelectEventHandler =
|
|
59
|
+
export type MarkerSelectEventHandler = DirectEventHandler<Readonly<{
|
|
60
60
|
action?: string;
|
|
61
61
|
id: string;
|
|
62
62
|
coordinate: {
|
|
@@ -64,7 +64,7 @@ export type MarkerSelectEventHandler = BubblingEventHandler<Readonly<{
|
|
|
64
64
|
longitude: Double;
|
|
65
65
|
};
|
|
66
66
|
}>>;
|
|
67
|
-
export type CalloutPressEvent =
|
|
67
|
+
export type CalloutPressEvent = DirectEventHandler<{
|
|
68
68
|
action?: string;
|
|
69
69
|
/**
|
|
70
70
|
* @platform iOS
|
|
@@ -150,13 +150,10 @@ export type IndoorBuildingEventHandler = DirectEventHandler<Readonly<{
|
|
|
150
150
|
activeLevelIndex: Int32;
|
|
151
151
|
};
|
|
152
152
|
}>>;
|
|
153
|
-
export type KmlMapEventHandler = DirectEventHandler<Readonly<{}>>;
|
|
154
|
-
export type MapLoadedEventHandler = DirectEventHandler<Readonly<{}>>;
|
|
155
|
-
export type MapReadyEventHandler = DirectEventHandler<Readonly<{}>>;
|
|
156
153
|
export type Details = Readonly<{
|
|
157
154
|
isGesture?: boolean;
|
|
158
155
|
}>;
|
|
159
|
-
export type MarkerDragEventHandler =
|
|
156
|
+
export type MarkerDragEventHandler = DirectEventHandler<Readonly<{
|
|
160
157
|
coordinate: {
|
|
161
158
|
latitude: Double;
|
|
162
159
|
longitude: Double;
|
|
@@ -167,7 +164,7 @@ export type MarkerDragEventHandler = BubblingEventHandler<Readonly<{
|
|
|
167
164
|
};
|
|
168
165
|
id?: string;
|
|
169
166
|
}>>;
|
|
170
|
-
export type MarkerDragStartEndEventHandler =
|
|
167
|
+
export type MarkerDragStartEndEventHandler = DirectEventHandler<Readonly<{
|
|
171
168
|
coordinate: {
|
|
172
169
|
latitude: Double;
|
|
173
170
|
longitude: Double;
|
|
@@ -178,7 +175,7 @@ export type MarkerDragStartEndEventHandler = BubblingEventHandler<Readonly<{
|
|
|
178
175
|
y: Double;
|
|
179
176
|
};
|
|
180
177
|
}>>;
|
|
181
|
-
export type MarkerPressEventHandler =
|
|
178
|
+
export type MarkerPressEventHandler = DirectEventHandler<Readonly<{
|
|
182
179
|
action?: string;
|
|
183
180
|
id: string;
|
|
184
181
|
coordinate: {
|
|
@@ -190,7 +187,7 @@ export type MarkerPressEventHandler = BubblingEventHandler<Readonly<{
|
|
|
190
187
|
y: Double;
|
|
191
188
|
};
|
|
192
189
|
}>>;
|
|
193
|
-
export type PanDragEventHandler =
|
|
190
|
+
export type PanDragEventHandler = DirectEventHandler<Readonly<{
|
|
194
191
|
coordinate: {
|
|
195
192
|
latitude: Double;
|
|
196
193
|
longitude: Double;
|
|
@@ -200,7 +197,7 @@ export type PanDragEventHandler = BubblingEventHandler<Readonly<{
|
|
|
200
197
|
y: Double;
|
|
201
198
|
};
|
|
202
199
|
}>>;
|
|
203
|
-
export type PoiClickEventHandler =
|
|
200
|
+
export type PoiClickEventHandler = DirectEventHandler<Readonly<{
|
|
204
201
|
placeId: string;
|
|
205
202
|
name: string;
|
|
206
203
|
coordinate: {
|
|
@@ -223,7 +220,6 @@ export type MapPressEventHandler = BubblingEventHandler<Readonly<{
|
|
|
223
220
|
};
|
|
224
221
|
action?: string;
|
|
225
222
|
}>>;
|
|
226
|
-
export type RegionChangeStartEventHandler = DirectEventHandler<Details>;
|
|
227
223
|
export type RegionChangeEvent = Readonly<{
|
|
228
224
|
region: {
|
|
229
225
|
latitude: Double;
|
|
@@ -233,7 +229,6 @@ export type RegionChangeEvent = Readonly<{
|
|
|
233
229
|
};
|
|
234
230
|
continuous?: boolean;
|
|
235
231
|
}>;
|
|
236
|
-
export type RegionChangeEventHandler = BubblingEventHandler<RegionChangeEvent>;
|
|
237
232
|
export type UserLocationChangeEvent = Readonly<{
|
|
238
233
|
coordinate?: {
|
|
239
234
|
latitude: Double;
|
|
@@ -447,7 +442,7 @@ export interface MapFabricNativeProps extends ViewProps {
|
|
|
447
442
|
* @platform iOS: Not supported
|
|
448
443
|
* @platform Android: Supported
|
|
449
444
|
*/
|
|
450
|
-
moveOnMarkerPress?: boolean
|
|
445
|
+
moveOnMarkerPress?: WithDefault<boolean, true>;
|
|
451
446
|
/**
|
|
452
447
|
* Callback that is called when a callout is tapped by the user.
|
|
453
448
|
*
|
|
@@ -482,7 +477,7 @@ export interface MapFabricNativeProps extends ViewProps {
|
|
|
482
477
|
* @platform iOS: Google Maps only
|
|
483
478
|
* @platform Android: Supported
|
|
484
479
|
*/
|
|
485
|
-
onKmlReady?:
|
|
480
|
+
onKmlReady?: DirectEventHandler<null>;
|
|
486
481
|
/**
|
|
487
482
|
* Callback that is called when user makes a "long press" somewhere on the map.
|
|
488
483
|
*
|
|
@@ -496,7 +491,7 @@ export interface MapFabricNativeProps extends ViewProps {
|
|
|
496
491
|
* @platform iOS: Google Maps only
|
|
497
492
|
* @platform Android: Supported
|
|
498
493
|
*/
|
|
499
|
-
onMapLoaded?:
|
|
494
|
+
onMapLoaded?: DirectEventHandler<null>;
|
|
500
495
|
/**
|
|
501
496
|
* Callback that is called once the map is ready.
|
|
502
497
|
*
|
|
@@ -506,7 +501,7 @@ export interface MapFabricNativeProps extends ViewProps {
|
|
|
506
501
|
* @platform iOS: Supported
|
|
507
502
|
* @platform Android: Supported
|
|
508
503
|
*/
|
|
509
|
-
onMapReady?:
|
|
504
|
+
onMapReady?: DirectEventHandler<null>;
|
|
510
505
|
/**
|
|
511
506
|
* Callback that is called when a marker on the map becomes deselected.
|
|
512
507
|
* This will be called when the callout for that marker is about to be hidden.
|
|
@@ -560,6 +555,7 @@ export interface MapFabricNativeProps extends ViewProps {
|
|
|
560
555
|
* @platform Android: Supported
|
|
561
556
|
*/
|
|
562
557
|
onPanDrag?: PanDragEventHandler;
|
|
558
|
+
handlePanDrag?: boolean;
|
|
563
559
|
/**
|
|
564
560
|
* Callback that is called when user click on a POI.
|
|
565
561
|
*
|
|
@@ -582,7 +578,7 @@ export interface MapFabricNativeProps extends ViewProps {
|
|
|
582
578
|
* @platform iOS: Supported
|
|
583
579
|
* @platform Android: Supported
|
|
584
580
|
*/
|
|
585
|
-
onRegionChangeStart?:
|
|
581
|
+
onRegionChangeStart?: DirectEventHandler<RegionChangeEvent>;
|
|
586
582
|
/**
|
|
587
583
|
* Callback that is called continuously when the region changes, such as when a user is dragging the map.
|
|
588
584
|
* `isGesture` property indicates if the move was from the user (true) or an animation (false).
|
|
@@ -591,7 +587,7 @@ export interface MapFabricNativeProps extends ViewProps {
|
|
|
591
587
|
* @platform iOS: Supported
|
|
592
588
|
* @platform Android: Supported
|
|
593
589
|
*/
|
|
594
|
-
onRegionChange?:
|
|
590
|
+
onRegionChange?: DirectEventHandler<RegionChangeEvent>;
|
|
595
591
|
/**
|
|
596
592
|
* Callback that is called once when the region changes, such as when the user is done moving the map.
|
|
597
593
|
* `isGesture` property indicates if the move was from the user (true) or an animation (false).
|
|
@@ -600,7 +596,7 @@ export interface MapFabricNativeProps extends ViewProps {
|
|
|
600
596
|
* @platform iOS: Supported
|
|
601
597
|
* @platform Android: Supported
|
|
602
598
|
*/
|
|
603
|
-
onRegionChangeComplete?:
|
|
599
|
+
onRegionChangeComplete?: DirectEventHandler<RegionChangeEvent>;
|
|
604
600
|
/**
|
|
605
601
|
* Callback that is called when the underlying map figures our users current location
|
|
606
602
|
* (coordinate also includes isFromMockProvider value for Android API 18 and above).
|
|
@@ -624,7 +620,7 @@ export interface MapFabricNativeProps extends ViewProps {
|
|
|
624
620
|
* @platform iOS: Google Maps only
|
|
625
621
|
* @platform Android: Supported
|
|
626
622
|
*/
|
|
627
|
-
pitchEnabled?: boolean
|
|
623
|
+
pitchEnabled?: WithDefault<boolean, true>;
|
|
628
624
|
/**
|
|
629
625
|
* The region to be displayed by the map.
|
|
630
626
|
* The region is defined by the center coordinates and the span of coordinates to display.
|
|
@@ -640,7 +636,7 @@ export interface MapFabricNativeProps extends ViewProps {
|
|
|
640
636
|
* @platform iOS: Google Maps only
|
|
641
637
|
* @platform Android: Supported
|
|
642
638
|
*/
|
|
643
|
-
rotateEnabled?: boolean
|
|
639
|
+
rotateEnabled?: WithDefault<boolean, true>;
|
|
644
640
|
/**
|
|
645
641
|
* If `false` the map will stay centered while rotating or zooming.
|
|
646
642
|
*
|
|
@@ -648,7 +644,7 @@ export interface MapFabricNativeProps extends ViewProps {
|
|
|
648
644
|
* @platform iOS: Google Maps only
|
|
649
645
|
* @platform Android: Supported
|
|
650
646
|
*/
|
|
651
|
-
scrollDuringRotateOrZoomEnabled?: boolean
|
|
647
|
+
scrollDuringRotateOrZoomEnabled?: WithDefault<boolean, true>;
|
|
652
648
|
/**
|
|
653
649
|
* If `false` the user won't be able to change the map region being displayed.
|
|
654
650
|
*
|
|
@@ -656,7 +652,7 @@ export interface MapFabricNativeProps extends ViewProps {
|
|
|
656
652
|
* @platform iOS: Supported
|
|
657
653
|
* @platform Android: Supported
|
|
658
654
|
*/
|
|
659
|
-
scrollEnabled?: boolean
|
|
655
|
+
scrollEnabled?: WithDefault<boolean, true>;
|
|
660
656
|
/**
|
|
661
657
|
* A Boolean indicating whether the map displays extruded building information.
|
|
662
658
|
*
|
|
@@ -664,7 +660,7 @@ export interface MapFabricNativeProps extends ViewProps {
|
|
|
664
660
|
* @platform iOS: Not supported
|
|
665
661
|
* @platform Android: Supported
|
|
666
662
|
*/
|
|
667
|
-
showsBuildings?: boolean
|
|
663
|
+
showsBuildings?: WithDefault<boolean, true>;
|
|
668
664
|
/**
|
|
669
665
|
* If `false` compass won't be displayed on the map.
|
|
670
666
|
*
|
|
@@ -672,7 +668,7 @@ export interface MapFabricNativeProps extends ViewProps {
|
|
|
672
668
|
* @platform iOS: Supported
|
|
673
669
|
* @platform Android: Supported
|
|
674
670
|
*/
|
|
675
|
-
showsCompass?: boolean
|
|
671
|
+
showsCompass?: WithDefault<boolean, true>;
|
|
676
672
|
/**
|
|
677
673
|
* A Boolean indicating whether indoor level picker should be enabled.
|
|
678
674
|
*
|
|
@@ -688,7 +684,7 @@ export interface MapFabricNativeProps extends ViewProps {
|
|
|
688
684
|
* @platform iOS: Google Maps only
|
|
689
685
|
* @platform Android: Supported
|
|
690
686
|
*/
|
|
691
|
-
showsIndoors?: boolean
|
|
687
|
+
showsIndoors?: WithDefault<boolean, true>;
|
|
692
688
|
/**
|
|
693
689
|
* If `false` hide the button to move map to the current user's location.
|
|
694
690
|
*
|
|
@@ -696,33 +692,15 @@ export interface MapFabricNativeProps extends ViewProps {
|
|
|
696
692
|
* @platform iOS: Google Maps only
|
|
697
693
|
* @platform Android: Supported
|
|
698
694
|
*/
|
|
699
|
-
showsMyLocationButton?: boolean
|
|
700
|
-
/**
|
|
701
|
-
* If `false` points of interest won't be displayed on the map.
|
|
702
|
-
* TODO: DEPRECATED? Doesn't seem to do anything
|
|
703
|
-
*
|
|
704
|
-
* @default true
|
|
705
|
-
* @platform iOS: Maybe Apple Maps?
|
|
706
|
-
* @platform Android: Not supported
|
|
707
|
-
*/
|
|
708
|
-
showsPointsOfInterest?: boolean;
|
|
695
|
+
showsMyLocationButton?: WithDefault<boolean, true>;
|
|
709
696
|
/**
|
|
710
697
|
* A Boolean indicating whether the map shows scale information.
|
|
711
698
|
*
|
|
712
|
-
* @default
|
|
699
|
+
* @default false
|
|
713
700
|
* @platform iOS: Apple Maps only
|
|
714
701
|
* @platform Android: Not supported
|
|
715
702
|
*/
|
|
716
703
|
showsScale?: boolean;
|
|
717
|
-
/**
|
|
718
|
-
* A Boolean value indicating whether the map displays traffic information.
|
|
719
|
-
* TODO: Look into android support
|
|
720
|
-
*
|
|
721
|
-
* @default false
|
|
722
|
-
* @platform iOS: Supported
|
|
723
|
-
* @platform Android: Not supported?
|
|
724
|
-
*/
|
|
725
|
-
showsTraffic?: boolean;
|
|
726
704
|
/**
|
|
727
705
|
* If `true` the users location will be displayed on the map.
|
|
728
706
|
*
|
|
@@ -748,13 +726,13 @@ export interface MapFabricNativeProps extends ViewProps {
|
|
|
748
726
|
* @platform iOS: Not supported
|
|
749
727
|
* @platform Android: Supported
|
|
750
728
|
*/
|
|
751
|
-
toolbarEnabled?: boolean
|
|
729
|
+
toolbarEnabled?: WithDefault<boolean, true>;
|
|
752
730
|
/**
|
|
753
731
|
* Sets the map to the style selected.
|
|
754
732
|
*
|
|
755
733
|
* @default System setting
|
|
756
|
-
* @platform iOS:
|
|
757
|
-
* @platform Android:
|
|
734
|
+
* @platform iOS: Supported
|
|
735
|
+
* @platform Android: Supported
|
|
758
736
|
*/
|
|
759
737
|
userInterfaceStyle?: WithDefault<'system' | 'light' | 'dark', 'system'>;
|
|
760
738
|
/**
|
|
@@ -784,7 +762,7 @@ export interface MapFabricNativeProps extends ViewProps {
|
|
|
784
762
|
* @platform iOS: Not supported
|
|
785
763
|
* @platform Android: Supported
|
|
786
764
|
*/
|
|
787
|
-
userLocationFastestInterval?: Int32
|
|
765
|
+
userLocationFastestInterval?: WithDefault<Int32, 5000>;
|
|
788
766
|
/**
|
|
789
767
|
* Set power priority of user location tracking.
|
|
790
768
|
*
|
|
@@ -804,7 +782,7 @@ export interface MapFabricNativeProps extends ViewProps {
|
|
|
804
782
|
* @platform iOS: Not supported
|
|
805
783
|
* @platform Android: Supported
|
|
806
784
|
*/
|
|
807
|
-
userLocationUpdateInterval?: Int32
|
|
785
|
+
userLocationUpdateInterval?: WithDefault<Int32, 5000>;
|
|
808
786
|
/**
|
|
809
787
|
* If `false` the zoom control at the bottom right of the map won't be visible.
|
|
810
788
|
*
|
|
@@ -812,7 +790,7 @@ export interface MapFabricNativeProps extends ViewProps {
|
|
|
812
790
|
* @platform iOS: Not supported
|
|
813
791
|
* @platform Android: Supported
|
|
814
792
|
*/
|
|
815
|
-
zoomControlEnabled?: boolean
|
|
793
|
+
zoomControlEnabled?: WithDefault<boolean, true>;
|
|
816
794
|
/**
|
|
817
795
|
* If `false` the user won't be able to pinch/zoom the map.
|
|
818
796
|
*
|
|
@@ -822,7 +800,15 @@ export interface MapFabricNativeProps extends ViewProps {
|
|
|
822
800
|
* @platform iOS: Supported
|
|
823
801
|
* @platform Android: Supported
|
|
824
802
|
*/
|
|
825
|
-
zoomEnabled?: boolean
|
|
803
|
+
zoomEnabled?: WithDefault<boolean, true>;
|
|
804
|
+
/**
|
|
805
|
+
* A Boolean value indicating whether the map displays traffic information.
|
|
806
|
+
*
|
|
807
|
+
* @default false
|
|
808
|
+
* @platform iOS: Google Maps only
|
|
809
|
+
* @platform Android: Supported
|
|
810
|
+
*/
|
|
811
|
+
showsTraffic?: boolean;
|
|
826
812
|
/**
|
|
827
813
|
* If `false` the user won't be able to double tap to zoom the map.
|
|
828
814
|
* **Note:** But it will greatly decrease delay of tap gesture recognition.
|
|
@@ -831,7 +817,7 @@ export interface MapFabricNativeProps extends ViewProps {
|
|
|
831
817
|
* @platform iOS: Google Maps only
|
|
832
818
|
* @platform Android: Not supported
|
|
833
819
|
*/
|
|
834
|
-
zoomTapEnabled?: boolean
|
|
820
|
+
zoomTapEnabled?: WithDefault<boolean, true>;
|
|
835
821
|
/**
|
|
836
822
|
* Map camera distance limits. `minCenterCoordinateDistance` for minimum distance, `maxCenterCoordinateDistance` for maximum.
|
|
837
823
|
* `animated` for animated zoom changes.
|
|
@@ -849,6 +835,7 @@ export interface NativeCommands {
|
|
|
849
835
|
fitToElements: (viewRef: React.ElementRef<React.ComponentType>, edgePaddingJSON: string, animated: boolean) => void;
|
|
850
836
|
fitToSuppliedMarkers: (viewRef: React.ElementRef<React.ComponentType>, markersJSON: string, edgePaddingJSON: string, animated: boolean) => void;
|
|
851
837
|
fitToCoordinates: (viewRef: React.ElementRef<React.ComponentType>, coordinatesJSON: string, edgePaddingJSON: string, animated: boolean) => void;
|
|
838
|
+
setIndoorActiveLevelIndex: (viewRef: React.ElementRef<React.ComponentType>, activeLevelIndex: Int32) => void;
|
|
852
839
|
}
|
|
853
840
|
export declare const Commands: NativeCommands;
|
|
854
841
|
declare const _default: HostComponent<MapFabricNativeProps>;
|
|
@@ -14,8 +14,7 @@ exports.Commands = (0, codegenNativeCommands_1.default)({
|
|
|
14
14
|
'fitToElements',
|
|
15
15
|
'fitToSuppliedMarkers',
|
|
16
16
|
'fitToCoordinates',
|
|
17
|
+
'setIndoorActiveLevelIndex',
|
|
17
18
|
],
|
|
18
19
|
});
|
|
19
|
-
exports.default = (0, codegenNativeComponent_1.default)('RNMapsMapView', {
|
|
20
|
-
excludedPlatforms: ['android'],
|
|
21
|
-
});
|
|
20
|
+
exports.default = (0, codegenNativeComponent_1.default)('RNMapsMapView', {});
|