react-native-maps 1.24.7 → 1.24.9
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/src/main/RCTThirdPartyComponentsProvider.mm +0 -2
- package/android/src/main/java/com/facebook/react/viewmanagers/RNMapsMarkerManagerDelegate.java +3 -0
- package/android/src/main/java/com/facebook/react/viewmanagers/RNMapsMarkerManagerInterface.java +1 -0
- package/android/src/main/java/com/rnmaps/fabric/MarkerManager.java +5 -0
- package/android/src/main/jni/react/renderer/components/RNMapsSpecs/Props.cpp +1 -0
- package/android/src/main/jni/react/renderer/components/RNMapsSpecs/Props.h +1 -0
- package/ios/AirGoogleMaps/RNMapsGoogleMapView.mm +2 -0
- package/ios/AirMaps/RNMapsMapView.mm +5 -6
- package/package.json +1 -1
- package/src/specs/NativeComponentMarker.ts +10 -0
|
@@ -16,8 +16,6 @@
|
|
|
16
16
|
+ (NSDictionary<NSString *, Class<RCTComponentViewProtocol>> *)thirdPartyFabricComponents
|
|
17
17
|
{
|
|
18
18
|
return @{
|
|
19
|
-
@"RNMapsGoogleMapView": NSClassFromString(@"RNMapsGoogleMapView"), // react-native-maps
|
|
20
|
-
@"RNMapsGooglePolygon": NSClassFromString(@"RNMapsGooglePolygonView"), // react-native-maps
|
|
21
19
|
@"RNMapsGoogleMapView": NSClassFromString(@"RNMapsGoogleMapView"), // react-native-maps
|
|
22
20
|
@"RNMapsGooglePolygon": NSClassFromString(@"RNMapsGooglePolygonView"), // react-native-maps
|
|
23
21
|
@"RNMapsMapView": NSClassFromString(@"RNMapsMapView"), // react-native-maps
|
package/android/src/main/java/com/facebook/react/viewmanagers/RNMapsMarkerManagerDelegate.java
CHANGED
|
@@ -52,6 +52,9 @@ public class RNMapsMarkerManagerDelegate<T extends View, U extends BaseViewManag
|
|
|
52
52
|
case "title":
|
|
53
53
|
mViewManager.setTitle(view, value == null ? null : (String) value);
|
|
54
54
|
break;
|
|
55
|
+
case "tracksViewChanges":
|
|
56
|
+
mViewManager.setTracksViewChanges(view, value == null ? true : (boolean) value);
|
|
57
|
+
break;
|
|
55
58
|
case "identifier":
|
|
56
59
|
mViewManager.setIdentifier(view, value == null ? null : (String) value);
|
|
57
60
|
break;
|
package/android/src/main/java/com/facebook/react/viewmanagers/RNMapsMarkerManagerInterface.java
CHANGED
|
@@ -23,6 +23,7 @@ public interface RNMapsMarkerManagerInterface<T extends View> {
|
|
|
23
23
|
void setDescription(T view, @Nullable String value);
|
|
24
24
|
void setDraggable(T view, boolean value);
|
|
25
25
|
void setTitle(T view, @Nullable String value);
|
|
26
|
+
void setTracksViewChanges(T view, boolean value);
|
|
26
27
|
void setIdentifier(T view, @Nullable String value);
|
|
27
28
|
void setIsPreselected(T view, boolean value);
|
|
28
29
|
void setOpacity(T view, double value);
|
|
@@ -182,6 +182,11 @@ public class MarkerManager extends ViewGroupManager<MapMarker> implements RNMaps
|
|
|
182
182
|
view.setUpdated(true);
|
|
183
183
|
}
|
|
184
184
|
|
|
185
|
+
@Override
|
|
186
|
+
public void setTracksViewChanges(MapMarker view, boolean value) {
|
|
187
|
+
view.setTracksViewChanges(value);
|
|
188
|
+
}
|
|
189
|
+
|
|
185
190
|
@Override
|
|
186
191
|
public void setIdentifier(MapMarker view, @Nullable String value) {
|
|
187
192
|
view.setIdentifier(value);
|
|
@@ -157,6 +157,7 @@ RNMapsMarkerProps::RNMapsMarkerProps(
|
|
|
157
157
|
description(convertRawProp(context, rawProps, "description", sourceProps.description, {})),
|
|
158
158
|
draggable(convertRawProp(context, rawProps, "draggable", sourceProps.draggable, {false})),
|
|
159
159
|
title(convertRawProp(context, rawProps, "title", sourceProps.title, {})),
|
|
160
|
+
tracksViewChanges(convertRawProp(context, rawProps, "tracksViewChanges", sourceProps.tracksViewChanges, {true})),
|
|
160
161
|
identifier(convertRawProp(context, rawProps, "identifier", sourceProps.identifier, {})),
|
|
161
162
|
isPreselected(convertRawProp(context, rawProps, "isPreselected", sourceProps.isPreselected, {false})),
|
|
162
163
|
opacity(convertRawProp(context, rawProps, "opacity", sourceProps.opacity, {1.0})),
|
|
@@ -1085,6 +1085,7 @@ class RNMapsMarkerProps final : public ViewProps {
|
|
|
1085
1085
|
std::string description{};
|
|
1086
1086
|
bool draggable{false};
|
|
1087
1087
|
std::string title{};
|
|
1088
|
+
bool tracksViewChanges{true};
|
|
1088
1089
|
std::string identifier{};
|
|
1089
1090
|
bool isPreselected{false};
|
|
1090
1091
|
double opacity{1.0};
|
|
@@ -593,6 +593,8 @@ using namespace facebook::react;
|
|
|
593
593
|
|
|
594
594
|
REMAP_MAPVIEW_STRING_PROP(kmlSrc)
|
|
595
595
|
REMAP_MAPVIEW_STRING_PROP(customMapStyleString)
|
|
596
|
+
REMAP_MAPVIEW_PROP(showsBuildings)
|
|
597
|
+
REMAP_MAPVIEW_PROP(rotateEnabled)
|
|
596
598
|
|
|
597
599
|
|
|
598
600
|
if (newViewProps.minZoom != oldViewProps.minZoom || newViewProps.maxZoom != oldViewProps.maxZoom){
|
|
@@ -544,26 +544,25 @@ newViewProps.name.right); \
|
|
|
544
544
|
|
|
545
545
|
#define REMAP_MAPVIEW_MAPTYPE(rnMapType) MKMapType##rnMapType
|
|
546
546
|
|
|
547
|
-
|
|
548
547
|
REMAP_MAPVIEW_PROP(cacheEnabled)
|
|
549
|
-
|
|
550
548
|
REMAP_MAPVIEW_PROP(followsUserLocation)
|
|
551
549
|
REMAP_MAPVIEW_PROP(loadingEnabled)
|
|
552
|
-
|
|
553
550
|
REMAP_MAPVIEW_PROP(scrollEnabled)
|
|
554
551
|
REMAP_MAPVIEW_PROP(handlePanDrag)
|
|
555
|
-
|
|
556
552
|
REMAP_MAPVIEW_PROP(maxDelta)
|
|
557
553
|
REMAP_MAPVIEW_PROP(maxZoom)
|
|
558
554
|
REMAP_MAPVIEW_PROP(minDelta)
|
|
559
555
|
REMAP_MAPVIEW_PROP(minZoom)
|
|
560
|
-
|
|
561
556
|
REMAP_MAPVIEW_PROP(showsCompass)
|
|
562
557
|
REMAP_MAPVIEW_PROP(showsScale)
|
|
563
558
|
REMAP_MAPVIEW_PROP(showsUserLocation)
|
|
564
559
|
REMAP_MAPVIEW_PROP(userLocationCalloutEnabled)
|
|
565
560
|
REMAP_MAPVIEW_PROP(zoomEnabled)
|
|
566
|
-
|
|
561
|
+
REMAP_MAPVIEW_PROP(loadingEnabled)
|
|
562
|
+
REMAP_MAPVIEW_PROP(showsTraffic)
|
|
563
|
+
REMAP_MAPVIEW_PROP(pitchEnabled)
|
|
564
|
+
REMAP_MAPVIEW_PROP(showsBuildings)
|
|
565
|
+
REMAP_MAPVIEW_PROP(rotateEnabled)
|
|
567
566
|
|
|
568
567
|
REMAP_MAPVIEW_POINT_PROP(compassOffset)
|
|
569
568
|
|
package/package.json
CHANGED
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
"main": "src/index.ts",
|
|
6
6
|
"author": "Leland Richardson <leland.m.richardson@gmail.com>",
|
|
7
7
|
"homepage": "https://github.com/react-native-maps/react-native-maps#readme",
|
|
8
|
-
"version": "1.24.
|
|
8
|
+
"version": "1.24.9",
|
|
9
9
|
"license": "MIT",
|
|
10
10
|
"scripts": {
|
|
11
11
|
"lint": "eslint . --max-warnings 0",
|
|
@@ -187,6 +187,16 @@ export interface MarkerFabricNativeProps extends ViewProps {
|
|
|
187
187
|
*/
|
|
188
188
|
title?: string;
|
|
189
189
|
|
|
190
|
+
/**
|
|
191
|
+
* Sets whether this marker should track view changes.
|
|
192
|
+
* It's recommended to turn it off whenever it's possible to improve custom marker performance.
|
|
193
|
+
*
|
|
194
|
+
* @default true
|
|
195
|
+
* @platform iOS: Google Maps only
|
|
196
|
+
* @platform Android: Supported
|
|
197
|
+
*/
|
|
198
|
+
tracksViewChanges?: WithDefault<boolean, true>;
|
|
199
|
+
|
|
190
200
|
/**
|
|
191
201
|
* A string that can be used to identify this marker.
|
|
192
202
|
*
|