react-native-maps 1.24.0 → 1.24.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.
@@ -206,9 +206,9 @@ bool areHolesEqual(const std::vector<std::vector<RNMapsGooglePolygonHolesStruct>
206
206
  if (newViewProps.strokeColor){
207
207
  _view.strokeColor = RCTUIColorFromSharedColor(newViewProps.strokeColor);
208
208
  }
209
-
210
-
211
-
209
+ if (newViewProps.strokeWidth != oldViewProps.strokeWidth){
210
+ _view.strokeWidth = newViewProps.strokeWidth;
211
+ }
212
212
 
213
213
  [super updateProps:props oldProps:oldProps];
214
214
  }
@@ -32,7 +32,7 @@ RNMapsCircleProps::RNMapsCircleProps(
32
32
  fillColor(convertRawProp(context, rawProps, "fillColor", sourceProps.fillColor, {})),
33
33
  radius(convertRawProp(context, rawProps, "radius", sourceProps.radius, {0.0})),
34
34
  strokeColor(convertRawProp(context, rawProps, "strokeColor", sourceProps.strokeColor, {})),
35
- strokeWidth(convertRawProp(context, rawProps, "strokeWidth", sourceProps.strokeWidth, {0.0})),
35
+ strokeWidth(convertRawProp(context, rawProps, "strokeWidth", sourceProps.strokeWidth, {1.0})),
36
36
  tappable(convertRawProp(context, rawProps, "tappable", sourceProps.tappable, {false}))
37
37
  {}
38
38
  RNMapsGoogleMapViewProps::RNMapsGoogleMapViewProps(
@@ -83,6 +83,7 @@ RNMapsGooglePolygonProps::RNMapsGooglePolygonProps(
83
83
  coordinates(convertRawProp(context, rawProps, "coordinates", sourceProps.coordinates, {})),
84
84
  fillColor(convertRawProp(context, rawProps, "fillColor", sourceProps.fillColor, {})),
85
85
  strokeColor(convertRawProp(context, rawProps, "strokeColor", sourceProps.strokeColor, {})),
86
+ strokeWidth(convertRawProp(context, rawProps, "strokeWidth", sourceProps.strokeWidth, {1.0})),
86
87
  geodesic(convertRawProp(context, rawProps, "geodesic", sourceProps.geodesic, {false})),
87
88
  holes(convertRawProp(context, rawProps, "holes", sourceProps.holes, {})),
88
89
  tappable(convertRawProp(context, rawProps, "tappable", sourceProps.tappable, {false}))
@@ -189,7 +190,7 @@ RNMapsPolylineProps::RNMapsPolylineProps(
189
190
  lineJoin(convertRawProp(context, rawProps, "lineJoin", sourceProps.lineJoin, {RNMapsPolylineLineJoin::Miter})),
190
191
  strokeColor(convertRawProp(context, rawProps, "strokeColor", sourceProps.strokeColor, {})),
191
192
  strokeColors(convertRawProp(context, rawProps, "strokeColors", sourceProps.strokeColors, {})),
192
- strokeWidth(convertRawProp(context, rawProps, "strokeWidth", sourceProps.strokeWidth, {0.0})),
193
+ strokeWidth(convertRawProp(context, rawProps, "strokeWidth", sourceProps.strokeWidth, {1.0})),
193
194
  tappable(convertRawProp(context, rawProps, "tappable", sourceProps.tappable, {false}))
194
195
  {}
195
196
  RNMapsUrlTileProps::RNMapsUrlTileProps(
@@ -61,7 +61,7 @@ class RNMapsCircleProps final : public ViewProps {
61
61
  SharedColor fillColor{};
62
62
  double radius{0.0};
63
63
  SharedColor strokeColor{};
64
- Float strokeWidth{0.0};
64
+ Float strokeWidth{1.0};
65
65
  bool tappable{false};
66
66
  };
67
67
 
@@ -478,6 +478,7 @@ class RNMapsGooglePolygonProps final : public ViewProps {
478
478
  std::vector<RNMapsGooglePolygonCoordinatesStruct> coordinates{};
479
479
  SharedColor fillColor{};
480
480
  SharedColor strokeColor{};
481
+ Float strokeWidth{1.0};
481
482
  bool geodesic{false};
482
483
  std::vector<std::vector<RNMapsGooglePolygonHolesStruct>> holes{};
483
484
  bool tappable{false};
@@ -1275,7 +1276,7 @@ class RNMapsPolylineProps final : public ViewProps {
1275
1276
  RNMapsPolylineLineJoin lineJoin{RNMapsPolylineLineJoin::Miter};
1276
1277
  SharedColor strokeColor{};
1277
1278
  std::vector<SharedColor> strokeColors{};
1278
- Float strokeWidth{0.0};
1279
+ Float strokeWidth{1.0};
1279
1280
  bool tappable{false};
1280
1281
  };
1281
1282
 
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.0",
8
+ "version": "1.24.1",
9
9
  "license": "MIT",
10
10
  "scripts": {
11
11
  "lint": "eslint . --max-warnings 0",
@@ -5,6 +5,7 @@ import type {
5
5
  Double,
6
6
  Float,
7
7
  BubblingEventHandler,
8
+ WithDefault,
8
9
  } from 'react-native/Libraries/Types/CodegenTypes';
9
10
 
10
11
  export type LatLng = Readonly<{
@@ -77,7 +78,7 @@ export interface CircleFabricNativeProps extends ViewProps {
77
78
  * @platform iOS: Supported
78
79
  * @platform Android: Supported
79
80
  */
80
- strokeWidth?: Float;
81
+ strokeWidth?: WithDefault<Float, 1.0>;
81
82
 
82
83
  /**
83
84
  * Boolean to allow a polygon to be tappable and use the onPress function.
@@ -4,6 +4,8 @@ import codegenNativeComponent from 'react-native/Libraries/Utilities/codegenNati
4
4
  import type {
5
5
  Double,
6
6
  BubblingEventHandler,
7
+ Float,
8
+ WithDefault,
7
9
  } from 'react-native/Libraries/Types/CodegenTypes';
8
10
 
9
11
  export type LatLng = Readonly<{
@@ -53,6 +55,15 @@ export interface PolygonFabricNativeProps extends ViewProps {
53
55
  */
54
56
  strokeColor?: ColorValue;
55
57
 
58
+ /**
59
+ * The stroke width to use for the path.
60
+ *
61
+ * @default 1
62
+ * @platform iOS: Supported
63
+ * @platform Android: Supported
64
+ */
65
+ strokeWidth?: WithDefault<Float, 1.0>;
66
+
56
67
  /**
57
68
  * Boolean to indicate whether to draw each segment of the line as a geodesic as opposed to straight lines on the Mercator projection.
58
69
  * A geodesic is the shortest path between two points on the Earth's surface.
@@ -107,7 +107,7 @@ export interface PolylineFabricNativeProps extends ViewProps {
107
107
  * @platform iOS: Supported
108
108
  * @platform Android: Supported
109
109
  */
110
- strokeWidth?: Float;
110
+ strokeWidth?: WithDefault<Float, 1.0>;
111
111
 
112
112
  /**
113
113
  * Boolean to allow a polygon to be tappable and use the onPress function.