@rnmapbox/maps 10.3.1 → 10.3.2-rc.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.
- package/android/src/main/java/com/rnmapbox/rnmbx/components/annotation/RNMBXMarkerView.kt +16 -2
- package/android/src/main/java/com/rnmapbox/rnmbx/components/annotation/RNMBXMarkerViewContent.kt +9 -0
- package/android/src/main/java/com/rnmapbox/rnmbx/components/annotation/RNMBXMarkerViewContentManager.kt +7 -1
- package/android/src/main/java/com/rnmapbox/rnmbx/components/annotation/RNMBXMarkerViewManager.kt +14 -0
- package/android/src/main/java/com/rnmapbox/rnmbx/components/camera/RNMBXCamera.kt +3 -0
- package/android/src/main/java/com/rnmapbox/rnmbx/components/camera/RNMBXCameraManager.kt +6 -0
- package/android/src/main/java/com/rnmapbox/rnmbx/components/camera/RNMBXVIewportManager.kt +6 -0
- package/android/src/main/java/com/rnmapbox/rnmbx/components/images/RNMBXImageManager.kt +6 -0
- package/android/src/main/java/com/rnmapbox/rnmbx/components/images/RNMBXImagesManager.kt +6 -0
- package/android/src/main/java/com/rnmapbox/rnmbx/components/location/RNMBXCustomLocationProviderManager.kt +6 -0
- package/android/src/main/java/com/rnmapbox/rnmbx/components/location/RNMBXNativeUserLocationManager.kt +6 -0
- package/android/src/main/java/com/rnmapbox/rnmbx/components/mapview/RNMBXMapView.kt +13 -0
- package/android/src/main/java/com/rnmapbox/rnmbx/components/mapview/RNMBXMapViewManager.kt +6 -1
- package/android/src/main/java/com/rnmapbox/rnmbx/components/styles/RNMBXStyleFactory.kt +110 -0
- package/android/src/main/java/com/rnmapbox/rnmbx/components/styles/RNMBXStyleImportManager.kt +6 -0
- package/android/src/main/java/com/rnmapbox/rnmbx/components/styles/layers/RNMBXBackgroundLayerManager.kt +6 -0
- package/android/src/main/java/com/rnmapbox/rnmbx/components/styles/layers/RNMBXCircleLayerManager.kt +6 -0
- package/android/src/main/java/com/rnmapbox/rnmbx/components/styles/layers/RNMBXFillExtrusionLayerManager.kt +6 -0
- package/android/src/main/java/com/rnmapbox/rnmbx/components/styles/layers/RNMBXFillLayerManager.kt +6 -0
- package/android/src/main/java/com/rnmapbox/rnmbx/components/styles/layers/RNMBXHeatmapLayerManager.kt +6 -0
- package/android/src/main/java/com/rnmapbox/rnmbx/components/styles/layers/RNMBXHillshadeLayerManager.kt +6 -0
- package/android/src/main/java/com/rnmapbox/rnmbx/components/styles/layers/RNMBXLineLayerManager.kt +6 -0
- package/android/src/main/java/com/rnmapbox/rnmbx/components/styles/layers/RNMBXModelLayerManager.kt +6 -0
- package/android/src/main/java/com/rnmapbox/rnmbx/components/styles/layers/RNMBXRasterLayerManager.kt +6 -0
- package/android/src/main/java/com/rnmapbox/rnmbx/components/styles/layers/RNMBXSkyLayerManager.kt +6 -0
- package/android/src/main/java/com/rnmapbox/rnmbx/components/styles/layers/RNMBXSymbolLayerManager.kt +6 -0
- package/android/src/main/java/com/rnmapbox/rnmbx/components/styles/light/RNMBXLightManager.kt +6 -0
- package/android/src/main/java/com/rnmapbox/rnmbx/components/styles/model/RNMBXModelsManager.kt +6 -0
- package/android/src/main/java/com/rnmapbox/rnmbx/components/styles/sources/RNMBXImageSourceManager.kt +6 -0
- package/android/src/main/java/com/rnmapbox/rnmbx/components/styles/sources/RNMBXRasterDemSourceManager.kt +6 -0
- package/android/src/main/java/com/rnmapbox/rnmbx/components/styles/sources/RNMBXRasterSource.kt +1 -1
- package/android/src/main/java/com/rnmapbox/rnmbx/components/styles/sources/RNMBXRasterSourceManager.kt +6 -0
- package/android/src/main/java/com/rnmapbox/rnmbx/components/styles/sources/RNMBXShapeSource.kt +8 -0
- package/android/src/main/java/com/rnmapbox/rnmbx/components/styles/sources/RNMBXShapeSourceManager.kt +11 -0
- package/android/src/main/java/com/rnmapbox/rnmbx/components/styles/sources/RNMBXVectorSourceManager.kt +6 -0
- package/android/src/main/java/com/rnmapbox/rnmbx/components/styles/terrain/RNMBXTerrainManager.kt +6 -0
- package/ios/RNMBX/RNMBXCamera.swift +5 -2
- package/ios/RNMBX/RNMBXMapView.swift +16 -0
- package/ios/RNMBX/RNMBXMapViewComponentView.mm +10 -0
- package/ios/RNMBX/RNMBXShapeSource.swift +5 -0
- package/ios/RNMBX/RNMBXShapeSourceComponentView.mm +1 -0
- package/ios/RNMBX/RNMBXStyle.swift +62 -0
- package/lib/commonjs/plugin/build/withMapbox.d.ts +1 -1
- package/lib/commonjs/plugin/src/withMapbox.ts +2 -2
- package/lib/module/Mapbox.native.js +0 -1
- package/lib/module/Mapbox.native.js.map +1 -1
- package/lib/module/components/AbstractLayer.js.map +1 -1
- package/lib/module/components/Annotation.js.map +1 -1
- package/lib/module/components/Callout.js.map +1 -1
- package/lib/module/components/Image.js.map +1 -1
- package/lib/module/components/Images.js.map +1 -1
- package/lib/module/components/MapView.js.map +1 -1
- package/lib/module/components/MarkerView.js +6 -2
- package/lib/module/components/MarkerView.js.map +1 -1
- package/lib/module/components/PointAnnotation.js +11 -4
- package/lib/module/components/PointAnnotation.js.map +1 -1
- package/lib/module/components/ShapeSource.js +1 -0
- package/lib/module/components/ShapeSource.js.map +1 -1
- package/lib/module/components/SymbolLayer.js.map +1 -1
- package/lib/module/components/UserLocation.js.map +1 -1
- package/lib/module/components/VectorSource.js.map +1 -1
- package/lib/module/specs/RNMBXCameraNativeComponent.ts +3 -3
- package/lib/module/specs/RNMBXCustomLocationProviderNativeComponent.ts +1 -1
- package/lib/module/specs/RNMBXImageSourceNativeComponent.ts +1 -1
- package/lib/module/specs/RNMBXMapViewNativeComponent.ts +5 -4
- package/lib/module/specs/RNMBXMarkerViewNativeComponent.ts +2 -2
- package/lib/module/specs/RNMBXModelLayerNativeComponent.ts +2 -2
- package/lib/module/specs/RNMBXModelsNativeComponent.ts +1 -1
- package/lib/module/specs/RNMBXNativeUserLocationNativeComponent.ts +1 -1
- package/lib/module/specs/RNMBXRasterArraySourceNativeComponent.ts +1 -1
- package/lib/module/specs/RNMBXRasterDemSourceNativeComponent.ts +1 -1
- package/lib/module/specs/RNMBXRasterSourceNativeComponent.ts +1 -1
- package/lib/module/specs/RNMBXShapeSourceNativeComponent.ts +4 -3
- package/lib/module/specs/RNMBXVectorSourceNativeComponent.ts +2 -2
- package/lib/module/utils/index.js.map +1 -1
- package/lib/module/utils/styleMap.js +6 -0
- package/lib/module/utils/styleMap.js.map +1 -1
- package/lib/module/web/components/Camera.js.map +1 -1
- package/lib/typescript/jest.config.d.ts +3 -3
- package/lib/typescript/jest.config.d.ts.map +1 -1
- package/lib/typescript/plugin/src/withMapbox.d.ts +1 -1
- package/lib/typescript/plugin/src/withMapbox.d.ts.map +1 -1
- package/lib/typescript/scripts/autogenHelpers/examplesJsonSchema.d.ts +1 -1
- package/lib/typescript/scripts/autogenHelpers/examplesJsonSchema.d.ts.map +1 -1
- package/lib/typescript/scripts/autogenHelpers/generateCodeWithEjs.d.mts.map +1 -1
- package/lib/typescript/src/Mapbox.native.d.ts +1 -1
- package/lib/typescript/src/Mapbox.native.d.ts.map +1 -1
- package/lib/typescript/src/components/AbstractLayer.d.ts +2 -2
- package/lib/typescript/src/components/AbstractLayer.d.ts.map +1 -1
- package/lib/typescript/src/components/AbstractSource.d.ts +1 -1
- package/lib/typescript/src/components/AbstractSource.d.ts.map +1 -1
- package/lib/typescript/src/components/Annotation.d.ts +4 -4
- package/lib/typescript/src/components/Annotation.d.ts.map +1 -1
- package/lib/typescript/src/components/Callout.d.ts +2 -2
- package/lib/typescript/src/components/Callout.d.ts.map +1 -1
- package/lib/typescript/src/components/Camera.d.ts +1 -1
- package/lib/typescript/src/components/Camera.d.ts.map +1 -1
- package/lib/typescript/src/components/CameraGestureObserver.d.ts +1 -1
- package/lib/typescript/src/components/CameraGestureObserver.d.ts.map +1 -1
- package/lib/typescript/src/components/CircleLayer.d.ts +1 -1
- package/lib/typescript/src/components/CircleLayer.d.ts.map +1 -1
- package/lib/typescript/src/components/CustomLocationProvider.d.ts +1 -1
- package/lib/typescript/src/components/CustomLocationProvider.d.ts.map +1 -1
- package/lib/typescript/src/components/FillExtrusionLayer.d.ts +1 -1
- package/lib/typescript/src/components/FillExtrusionLayer.d.ts.map +1 -1
- package/lib/typescript/src/components/HeadingIndicator.d.ts +1 -1
- package/lib/typescript/src/components/HeadingIndicator.d.ts.map +1 -1
- package/lib/typescript/src/components/HillshadeLayer.d.ts +1 -1
- package/lib/typescript/src/components/HillshadeLayer.d.ts.map +1 -1
- package/lib/typescript/src/components/Image.d.ts +1 -1
- package/lib/typescript/src/components/Image.d.ts.map +1 -1
- package/lib/typescript/src/components/ImageSource.d.ts +1 -1
- package/lib/typescript/src/components/ImageSource.d.ts.map +1 -1
- package/lib/typescript/src/components/Images.d.ts +2 -2
- package/lib/typescript/src/components/Images.d.ts.map +1 -1
- package/lib/typescript/src/components/LineLayer.d.ts +1 -1
- package/lib/typescript/src/components/LineLayer.d.ts.map +1 -1
- package/lib/typescript/src/components/MapView.d.ts +5 -1
- package/lib/typescript/src/components/MapView.d.ts.map +1 -1
- package/lib/typescript/src/components/MarkerView.d.ts +1 -1
- package/lib/typescript/src/components/MarkerView.d.ts.map +1 -1
- package/lib/typescript/src/components/ModelLayer.d.ts +1 -1
- package/lib/typescript/src/components/ModelLayer.d.ts.map +1 -1
- package/lib/typescript/src/components/NativeBridgeComponent.d.ts +1 -1
- package/lib/typescript/src/components/NativeBridgeComponent.d.ts.map +1 -1
- package/lib/typescript/src/components/PointAnnotation.d.ts +3 -3
- package/lib/typescript/src/components/PointAnnotation.d.ts.map +1 -1
- package/lib/typescript/src/components/RasterArraySource.d.ts +1 -1
- package/lib/typescript/src/components/RasterArraySource.d.ts.map +1 -1
- package/lib/typescript/src/components/RasterLayer.d.ts +1 -1
- package/lib/typescript/src/components/RasterLayer.d.ts.map +1 -1
- package/lib/typescript/src/components/RasterParticleLayer.d.ts +1 -1
- package/lib/typescript/src/components/RasterParticleLayer.d.ts.map +1 -1
- package/lib/typescript/src/components/RasterSource.d.ts +1 -1
- package/lib/typescript/src/components/RasterSource.d.ts.map +1 -1
- package/lib/typescript/src/components/ShapeSource.d.ts +8 -3
- package/lib/typescript/src/components/ShapeSource.d.ts.map +1 -1
- package/lib/typescript/src/components/SkyLayer.d.ts +1 -1
- package/lib/typescript/src/components/SkyLayer.d.ts.map +1 -1
- package/lib/typescript/src/components/SymbolLayer.d.ts +1 -1
- package/lib/typescript/src/components/SymbolLayer.d.ts.map +1 -1
- package/lib/typescript/src/components/UserLocation.d.ts +1 -1
- package/lib/typescript/src/components/UserLocation.d.ts.map +1 -1
- package/lib/typescript/src/components/VectorSource.d.ts +2 -2
- package/lib/typescript/src/components/VectorSource.d.ts.map +1 -1
- package/lib/typescript/src/modules/location/locationManager.d.ts +1 -1
- package/lib/typescript/src/modules/location/locationManager.d.ts.map +1 -1
- package/lib/typescript/src/modules/offline/offlineManager.d.ts +1 -1
- package/lib/typescript/src/modules/offline/offlineManager.d.ts.map +1 -1
- package/lib/typescript/src/shapeAnimators/ChangeLineOffsetsShapeAnimator.d.ts +1 -1
- package/lib/typescript/src/shapeAnimators/ChangeLineOffsetsShapeAnimator.d.ts.map +1 -1
- package/lib/typescript/src/shapeAnimators/MovePointShapeAnimator.d.ts +2 -2
- package/lib/typescript/src/shapeAnimators/MovePointShapeAnimator.d.ts.map +1 -1
- package/lib/typescript/src/specs/RNMBXCameraNativeComponent.d.ts +1 -1
- package/lib/typescript/src/specs/RNMBXCameraNativeComponent.d.ts.map +1 -1
- package/lib/typescript/src/specs/RNMBXCustomLocationProviderNativeComponent.d.ts +1 -1
- package/lib/typescript/src/specs/RNMBXCustomLocationProviderNativeComponent.d.ts.map +1 -1
- package/lib/typescript/src/specs/RNMBXImageSourceNativeComponent.d.ts +1 -1
- package/lib/typescript/src/specs/RNMBXImageSourceNativeComponent.d.ts.map +1 -1
- package/lib/typescript/src/specs/RNMBXMapViewNativeComponent.d.ts +2 -1
- package/lib/typescript/src/specs/RNMBXMapViewNativeComponent.d.ts.map +1 -1
- package/lib/typescript/src/specs/RNMBXMarkerViewNativeComponent.d.ts +2 -2
- package/lib/typescript/src/specs/RNMBXMarkerViewNativeComponent.d.ts.map +1 -1
- package/lib/typescript/src/specs/RNMBXModelLayerNativeComponent.d.ts +2 -2
- package/lib/typescript/src/specs/RNMBXModelLayerNativeComponent.d.ts.map +1 -1
- package/lib/typescript/src/specs/RNMBXModelsNativeComponent.d.ts +1 -1
- package/lib/typescript/src/specs/RNMBXModelsNativeComponent.d.ts.map +1 -1
- package/lib/typescript/src/specs/RNMBXNativeUserLocationNativeComponent.d.ts +1 -1
- package/lib/typescript/src/specs/RNMBXNativeUserLocationNativeComponent.d.ts.map +1 -1
- package/lib/typescript/src/specs/RNMBXRasterArraySourceNativeComponent.d.ts +1 -1
- package/lib/typescript/src/specs/RNMBXRasterArraySourceNativeComponent.d.ts.map +1 -1
- package/lib/typescript/src/specs/RNMBXRasterDemSourceNativeComponent.d.ts +1 -1
- package/lib/typescript/src/specs/RNMBXRasterDemSourceNativeComponent.d.ts.map +1 -1
- package/lib/typescript/src/specs/RNMBXRasterSourceNativeComponent.d.ts +1 -1
- package/lib/typescript/src/specs/RNMBXRasterSourceNativeComponent.d.ts.map +1 -1
- package/lib/typescript/src/specs/RNMBXShapeSourceNativeComponent.d.ts +2 -1
- package/lib/typescript/src/specs/RNMBXShapeSourceNativeComponent.d.ts.map +1 -1
- package/lib/typescript/src/specs/RNMBXVectorSourceNativeComponent.d.ts +1 -1
- package/lib/typescript/src/specs/RNMBXVectorSourceNativeComponent.d.ts.map +1 -1
- package/lib/typescript/src/types/index.d.ts +2 -2
- package/lib/typescript/src/types/index.d.ts.map +1 -1
- package/lib/typescript/src/utils/Logger.d.ts +1 -1
- package/lib/typescript/src/utils/Logger.d.ts.map +1 -1
- package/lib/typescript/src/utils/MapboxStyles.d.ts +31 -1
- package/lib/typescript/src/utils/MapboxStyles.d.ts.map +1 -1
- package/lib/typescript/src/utils/StyleValue.d.ts +1 -1
- package/lib/typescript/src/utils/StyleValue.d.ts.map +1 -1
- package/lib/typescript/src/utils/index.d.ts +2 -2
- package/lib/typescript/src/utils/index.d.ts.map +1 -1
- package/lib/typescript/src/utils/nativeRef.d.ts +1 -1
- package/lib/typescript/src/utils/nativeRef.d.ts.map +1 -1
- package/lib/typescript/src/utils/styleMap.d.ts.map +1 -1
- package/lib/typescript/src/web/components/Camera.d.ts +3 -3
- package/lib/typescript/src/web/components/Camera.d.ts.map +1 -1
- package/package.json +3 -3
- package/plugin/build/withMapbox.d.ts +1 -1
- package/plugin/src/withMapbox.ts +2 -2
- package/src/Mapbox.native.ts +1 -1
- package/src/components/AbstractLayer.tsx +2 -2
- package/src/components/AbstractSource.tsx +1 -1
- package/src/components/Annotation.tsx +4 -4
- package/src/components/Callout.tsx +3 -3
- package/src/components/Camera.tsx +1 -1
- package/src/components/CameraGestureObserver.tsx +1 -1
- package/src/components/CircleLayer.tsx +1 -1
- package/src/components/CustomLocationProvider.tsx +1 -1
- package/src/components/FillExtrusionLayer.tsx +1 -1
- package/src/components/HeadingIndicator.tsx +1 -1
- package/src/components/HillshadeLayer.tsx +1 -1
- package/src/components/Image.tsx +1 -1
- package/src/components/ImageSource.tsx +1 -1
- package/src/components/Images.tsx +6 -3
- package/src/components/LineLayer.tsx +1 -1
- package/src/components/MapView.tsx +10 -5
- package/src/components/MarkerView.tsx +10 -3
- package/src/components/ModelLayer.tsx +1 -1
- package/src/components/NativeBridgeComponent.tsx +1 -1
- package/src/components/PointAnnotation.tsx +18 -5
- package/src/components/RasterArraySource.tsx +1 -1
- package/src/components/RasterLayer.tsx +1 -1
- package/src/components/RasterParticleLayer.tsx +1 -1
- package/src/components/RasterSource.tsx +1 -1
- package/src/components/ShapeSource.tsx +11 -4
- package/src/components/SkyLayer.tsx +1 -1
- package/src/components/SymbolLayer.tsx +1 -1
- package/src/components/UserLocation.tsx +2 -2
- package/src/components/VectorSource.tsx +2 -2
- package/src/modules/location/locationManager.ts +3 -3
- package/src/modules/offline/offlineManager.ts +1 -1
- package/src/shapeAnimators/ChangeLineOffsetsShapeAnimator.ts +1 -1
- package/src/shapeAnimators/MovePointShapeAnimator.ts +2 -2
- package/src/specs/RNMBXCameraNativeComponent.ts +3 -3
- package/src/specs/RNMBXCustomLocationProviderNativeComponent.ts +1 -1
- package/src/specs/RNMBXImageSourceNativeComponent.ts +1 -1
- package/src/specs/RNMBXMapViewNativeComponent.ts +5 -4
- package/src/specs/RNMBXMarkerViewNativeComponent.ts +2 -2
- package/src/specs/RNMBXModelLayerNativeComponent.ts +2 -2
- package/src/specs/RNMBXModelsNativeComponent.ts +1 -1
- package/src/specs/RNMBXNativeUserLocationNativeComponent.ts +1 -1
- package/src/specs/RNMBXRasterArraySourceNativeComponent.ts +1 -1
- package/src/specs/RNMBXRasterDemSourceNativeComponent.ts +1 -1
- package/src/specs/RNMBXRasterSourceNativeComponent.ts +1 -1
- package/src/specs/RNMBXShapeSourceNativeComponent.ts +4 -3
- package/src/specs/RNMBXVectorSourceNativeComponent.ts +2 -2
- package/src/types/index.ts +2 -2
- package/src/utils/Logger.ts +1 -1
- package/src/utils/MapboxStyles.ts +31 -1
- package/src/utils/StyleValue.ts +1 -1
- package/src/utils/index.ts +3 -3
- package/src/utils/nativeRef.ts +1 -1
- package/src/utils/styleMap.ts +6 -0
- package/src/web/components/Camera.tsx +8 -4
|
@@ -72,6 +72,7 @@ const MarkerView = ({
|
|
|
72
72
|
isSelected = false,
|
|
73
73
|
coordinate,
|
|
74
74
|
style,
|
|
75
|
+
pointerEvents,
|
|
75
76
|
children,
|
|
76
77
|
}: Props) => {
|
|
77
78
|
// Android new-arch (Fabric) fix: UIManager.measure reads from the Fabric shadow
|
|
@@ -98,9 +99,14 @@ const MarkerView = ({
|
|
|
98
99
|
// we don't trigger a re-render for no-op native position re-applications.
|
|
99
100
|
const lastTranslateRef = useRef<{ x: number; y: number } | null>(null);
|
|
100
101
|
|
|
101
|
-
const handleTouchEnd = useCallback(
|
|
102
|
-
e
|
|
103
|
-
|
|
102
|
+
const handleTouchEnd = useCallback(
|
|
103
|
+
(e: { stopPropagation: () => void }) => {
|
|
104
|
+
if (pointerEvents !== 'none' && pointerEvents !== 'box-none') {
|
|
105
|
+
e.stopPropagation();
|
|
106
|
+
}
|
|
107
|
+
},
|
|
108
|
+
[pointerEvents],
|
|
109
|
+
);
|
|
104
110
|
|
|
105
111
|
const handleAnnotationPosition = useCallback(
|
|
106
112
|
(e: NativeSyntheticEvent<{ x: number; y: number }>) => {
|
|
@@ -150,6 +156,7 @@ const MarkerView = ({
|
|
|
150
156
|
allowOverlap={allowOverlap}
|
|
151
157
|
allowOverlapWithPuck={allowOverlapWithPuck}
|
|
152
158
|
isSelected={isSelected}
|
|
159
|
+
pointerEvents={pointerEvents}
|
|
153
160
|
onTouchEnd={handleTouchEnd}
|
|
154
161
|
>
|
|
155
162
|
<RNMBXMakerViewContentComponent
|
|
@@ -4,7 +4,7 @@ import type {
|
|
|
4
4
|
FilterExpression,
|
|
5
5
|
ModelLayerStyleProps,
|
|
6
6
|
} from '../utils/MapboxStyles';
|
|
7
|
-
import { StyleValue } from '../utils/StyleValue';
|
|
7
|
+
import { type StyleValue } from '../utils/StyleValue';
|
|
8
8
|
import RNMBXModelLayerNativeComponent from '../specs/RNMBXModelLayerNativeComponent';
|
|
9
9
|
|
|
10
10
|
import AbstractLayer from './AbstractLayer';
|
|
@@ -1,16 +1,22 @@
|
|
|
1
|
-
import React, { SyntheticEvent, type Component } from 'react';
|
|
2
|
-
import { StyleSheet, type ViewProps } from 'react-native';
|
|
3
|
-
import {
|
|
1
|
+
import React, { type SyntheticEvent, type Component } from 'react';
|
|
2
|
+
import { StyleSheet, View, type ViewProps } from 'react-native';
|
|
3
|
+
import {
|
|
4
|
+
type Feature,
|
|
5
|
+
type GeoJsonProperties,
|
|
6
|
+
type Geometry,
|
|
7
|
+
type Point,
|
|
8
|
+
} from 'geojson';
|
|
4
9
|
|
|
5
10
|
import { toJSONString, isFunction } from '../utils';
|
|
6
11
|
import checkRequiredProps from '../utils/checkRequiredProps';
|
|
7
12
|
import { makePoint } from '../utils/geoUtils';
|
|
8
13
|
import { type BaseProps } from '../types/BaseProps';
|
|
9
|
-
import { Position } from '../types/Position';
|
|
14
|
+
import { type Position } from '../types/Position';
|
|
10
15
|
import RNMBXPointAnnotationNativeComponent from '../specs/RNMBXPointAnnotationNativeComponent';
|
|
11
16
|
import NativeRNMBXPointAnnotationModule from '../specs/NativeRNMBXPointAnnotationModule';
|
|
12
17
|
|
|
13
18
|
import NativeBridgeComponent, { type RNMBEvent } from './NativeBridgeComponent';
|
|
19
|
+
import Callout from './Callout';
|
|
14
20
|
|
|
15
21
|
export const NATIVE_MODULE_NAME = 'RNMBXPointAnnotation';
|
|
16
22
|
|
|
@@ -230,10 +236,17 @@ class PointAnnotation extends NativeBridgeComponent(
|
|
|
230
236
|
onMapboxPointAnnotationDragEnd: this._onDragEnd,
|
|
231
237
|
coordinate: this._getCoordinate(),
|
|
232
238
|
};
|
|
239
|
+
const children = React.Children.toArray(this.props.children);
|
|
240
|
+
const callout = children.find(
|
|
241
|
+
(c) => React.isValidElement(c) && c.type === Callout,
|
|
242
|
+
);
|
|
243
|
+
const content = children.filter((c) => c !== callout);
|
|
244
|
+
|
|
233
245
|
return (
|
|
234
246
|
// @ts-expect-error just codegen stuff
|
|
235
247
|
<RNMBXPointAnnotationNativeComponent {...props}>
|
|
236
|
-
{
|
|
248
|
+
<View collapsable={false}>{content}</View>
|
|
249
|
+
{callout}
|
|
237
250
|
</RNMBXPointAnnotationNativeComponent>
|
|
238
251
|
);
|
|
239
252
|
}
|
|
@@ -2,7 +2,7 @@ import React from 'react';
|
|
|
2
2
|
import { NativeModules } from 'react-native';
|
|
3
3
|
|
|
4
4
|
import { cloneReactChildrenWithProps } from '../utils';
|
|
5
|
-
import { BaseProps } from '../types/BaseProps';
|
|
5
|
+
import { type BaseProps } from '../types/BaseProps';
|
|
6
6
|
import RNMBXRasterArraySourceNativeComponent from '../specs/RNMBXRasterArraySourceNativeComponent';
|
|
7
7
|
|
|
8
8
|
import AbstractSource from './AbstractSource';
|
|
@@ -5,7 +5,7 @@ import type {
|
|
|
5
5
|
FilterExpression,
|
|
6
6
|
RasterLayerStyleProps,
|
|
7
7
|
} from '../utils/MapboxStyles';
|
|
8
|
-
import { StyleValue } from '../utils/StyleValue';
|
|
8
|
+
import { type StyleValue } from '../utils/StyleValue';
|
|
9
9
|
import RNMBXRasterLayerNativeComponent from '../specs/RNMBXRasterLayerNativeComponent';
|
|
10
10
|
|
|
11
11
|
import AbstractLayer from './AbstractLayer';
|
|
@@ -5,7 +5,7 @@ import type {
|
|
|
5
5
|
FilterExpression,
|
|
6
6
|
RasterParticleLayerStyleProps,
|
|
7
7
|
} from '../utils/MapboxStyles';
|
|
8
|
-
import { StyleValue } from '../utils/StyleValue';
|
|
8
|
+
import { type StyleValue } from '../utils/StyleValue';
|
|
9
9
|
import RNMBXRasterParticleLayerNativeComponent from '../specs/RNMBXRasterParticleLayerNativeComponent';
|
|
10
10
|
|
|
11
11
|
import AbstractLayer from './AbstractLayer';
|
|
@@ -2,7 +2,7 @@ import React from 'react';
|
|
|
2
2
|
import { NativeModules } from 'react-native';
|
|
3
3
|
|
|
4
4
|
import { cloneReactChildrenWithProps } from '../utils';
|
|
5
|
-
import { BaseProps } from '../types/BaseProps';
|
|
5
|
+
import { type BaseProps } from '../types/BaseProps';
|
|
6
6
|
import RNMBXRasterSourceNativeComponent from '../specs/RNMBXRasterSourceNativeComponent';
|
|
7
7
|
|
|
8
8
|
import AbstractSource from './AbstractSource';
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import {
|
|
3
|
-
NativeMethods,
|
|
3
|
+
type NativeMethods,
|
|
4
4
|
NativeModules,
|
|
5
|
-
NativeSyntheticEvent,
|
|
5
|
+
type NativeSyntheticEvent,
|
|
6
6
|
} from 'react-native';
|
|
7
7
|
|
|
8
8
|
import RNMBXShapeSourceNativeComponent from '../specs/RNMBXShapeSourceNativeComponent';
|
|
@@ -14,8 +14,8 @@ import {
|
|
|
14
14
|
isAndroid,
|
|
15
15
|
} from '../utils';
|
|
16
16
|
import { copyPropertiesAsDeprecated } from '../utils/deprecation';
|
|
17
|
-
import { OnPressEvent } from '../types/OnPressEvent';
|
|
18
|
-
import { ShapeAnimatorInterface } from '../shapeAnimators';
|
|
17
|
+
import { type OnPressEvent } from '../types/OnPressEvent';
|
|
18
|
+
import { type ShapeAnimatorInterface } from '../shapeAnimators';
|
|
19
19
|
|
|
20
20
|
import AbstractSource from './AbstractSource';
|
|
21
21
|
import NativeBridgeComponent from './NativeBridgeComponent';
|
|
@@ -93,6 +93,12 @@ export type Props = {
|
|
|
93
93
|
*/
|
|
94
94
|
maxZoomLevel?: number;
|
|
95
95
|
|
|
96
|
+
/**
|
|
97
|
+
* Specifies the minimum zoom level at which to create vector tiles.
|
|
98
|
+
* The default value is 0.
|
|
99
|
+
*/
|
|
100
|
+
minZoomLevel?: number;
|
|
101
|
+
|
|
96
102
|
/**
|
|
97
103
|
* Specifies the size of the tile buffer on each side.
|
|
98
104
|
* A value of 0 produces no buffer. A value of 512 produces a buffer as wide as the tile itself.
|
|
@@ -312,6 +318,7 @@ export class ShapeSource extends NativeBridgeComponent(
|
|
|
312
318
|
clusterMaxZoomLevel: this.props.clusterMaxZoomLevel,
|
|
313
319
|
clusterProperties: this.props.clusterProperties,
|
|
314
320
|
maxZoomLevel: this.props.maxZoomLevel,
|
|
321
|
+
minZoomLevel: this.props.minZoomLevel,
|
|
315
322
|
buffer: this.props.buffer,
|
|
316
323
|
tolerance: this.props.tolerance,
|
|
317
324
|
lineMetrics: this.props.lineMetrics,
|
|
@@ -5,7 +5,7 @@ import type {
|
|
|
5
5
|
FilterExpression,
|
|
6
6
|
SkyLayerStyleProps,
|
|
7
7
|
} from '../utils/MapboxStyles';
|
|
8
|
-
import { StyleValue } from '../utils/StyleValue';
|
|
8
|
+
import { type StyleValue } from '../utils/StyleValue';
|
|
9
9
|
import RNMBXSkyLayerNativeComponent from '../specs/RNMBXSkyLayerNativeComponent';
|
|
10
10
|
|
|
11
11
|
import AbstractLayer from './AbstractLayer';
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import React, { ReactElement } from 'react';
|
|
1
|
+
import React, { type ReactElement } from 'react';
|
|
2
2
|
|
|
3
3
|
import locationManager from '../modules/location/locationManager';
|
|
4
4
|
import { type Location } from '../modules/location/locationManager';
|
|
5
|
-
import { CircleLayerStyle } from '../Mapbox';
|
|
5
|
+
import { type CircleLayerStyle } from '../Mapbox';
|
|
6
6
|
|
|
7
7
|
import Annotation from './Annotation';
|
|
8
8
|
import CircleLayer from './CircleLayer';
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { NativeModules, NativeSyntheticEvent } from 'react-native';
|
|
2
|
+
import { NativeModules, type NativeSyntheticEvent } from 'react-native';
|
|
3
3
|
|
|
4
4
|
import RNMBXVectorSourceNativeComponent from '../specs/RNMBXVectorSourceNativeComponent';
|
|
5
5
|
import { cloneReactChildrenWithProps, isFunction } from '../utils';
|
|
6
6
|
import { copyPropertiesAsDeprecated } from '../utils/deprecation';
|
|
7
|
-
import { OnPressEvent } from '../types/OnPressEvent';
|
|
7
|
+
import { type OnPressEvent } from '../types/OnPressEvent';
|
|
8
8
|
|
|
9
9
|
import AbstractSource from './AbstractSource';
|
|
10
10
|
|
|
@@ -2,11 +2,11 @@ import {
|
|
|
2
2
|
NativeModules,
|
|
3
3
|
NativeEventEmitter,
|
|
4
4
|
AppState,
|
|
5
|
-
NativeEventSubscription,
|
|
6
|
-
EmitterSubscription,
|
|
5
|
+
type NativeEventSubscription,
|
|
6
|
+
type EmitterSubscription,
|
|
7
7
|
type AppStateStatus,
|
|
8
8
|
Platform,
|
|
9
|
-
EventSubscription,
|
|
9
|
+
type EventSubscription,
|
|
10
10
|
} from 'react-native';
|
|
11
11
|
|
|
12
12
|
import NativeRNMBXLocationModule from '../../specs/NativeRNMBXLocationModule';
|
|
@@ -5,7 +5,7 @@ import NativeRNMBXChangeLineOffsetsShapeAnimatorModule from '../specs/NativeRNMB
|
|
|
5
5
|
|
|
6
6
|
import ShapeAnimatorManager from './ShapeAnimatorManager';
|
|
7
7
|
|
|
8
|
-
import { ShapeAnimatorInterface } from '.';
|
|
8
|
+
import { type ShapeAnimatorInterface } from '.';
|
|
9
9
|
|
|
10
10
|
export default class ChangeLineOffsetsShapeAnimator
|
|
11
11
|
implements ShapeAnimatorInterface
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { Position } from '../types/Position';
|
|
1
|
+
import { type Position } from '../types/Position';
|
|
2
2
|
import NativeRNMBXMovePointShapeAnimatorModule from '../specs/NativeRNMBXMovePointShapeAnimatorModule';
|
|
3
3
|
|
|
4
4
|
import ShapeAnimatorManager from './ShapeAnimatorManager';
|
|
5
5
|
|
|
6
|
-
import { ShapeAnimatorInterface } from '.';
|
|
6
|
+
import { type ShapeAnimatorInterface } from '.';
|
|
7
7
|
|
|
8
8
|
export default class MovePointShapeAnimator implements ShapeAnimatorInterface {
|
|
9
9
|
__nativeTag: number;
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import type { HostComponent, ViewProps } from 'react-native';
|
|
2
2
|
import codegenNativeComponent from 'react-native/Libraries/Utilities/codegenNativeComponent';
|
|
3
3
|
import {
|
|
4
|
-
DirectEventHandler,
|
|
5
|
-
Double,
|
|
6
|
-
Int32,
|
|
4
|
+
type DirectEventHandler,
|
|
5
|
+
type Double,
|
|
6
|
+
type Int32,
|
|
7
7
|
// @ts-ignore - CI environment type resolution issue for CodegenTypes
|
|
8
8
|
} from 'react-native/Libraries/Types/CodegenTypes';
|
|
9
9
|
|
|
@@ -5,7 +5,7 @@ import { Double } from 'react-native/Libraries/Types/CodegenTypes';
|
|
|
5
5
|
|
|
6
6
|
import type { Position } from '../types/Position';
|
|
7
7
|
|
|
8
|
-
import { UnsafeMixed } from './codegenUtils';
|
|
8
|
+
import { type UnsafeMixed } from './codegenUtils';
|
|
9
9
|
|
|
10
10
|
// see https://github.com/rnmapbox/maps/wiki/FabricOptionalProp
|
|
11
11
|
type OptionalProp<T> = UnsafeMixed<T>;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import type { HostComponent, ViewProps } from 'react-native';
|
|
2
2
|
import codegenNativeComponent from 'react-native/Libraries/Utilities/codegenNativeComponent';
|
|
3
3
|
|
|
4
|
-
import { UnsafeMixed } from './codegenUtils';
|
|
4
|
+
import { type UnsafeMixed } from './codegenUtils';
|
|
5
5
|
|
|
6
6
|
export interface NativeProps extends ViewProps {
|
|
7
7
|
id: UnsafeMixed<string>;
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import type { HostComponent, ViewProps } from 'react-native';
|
|
2
2
|
import codegenNativeComponent from 'react-native/Libraries/Utilities/codegenNativeComponent';
|
|
3
3
|
import {
|
|
4
|
-
BubblingEventHandler,
|
|
5
|
-
DirectEventHandler,
|
|
6
|
-
Int32,
|
|
7
|
-
Double,
|
|
4
|
+
type BubblingEventHandler,
|
|
5
|
+
type DirectEventHandler,
|
|
6
|
+
type Int32,
|
|
7
|
+
type Double,
|
|
8
8
|
// @ts-ignore - CI environment type resolution issue for CodegenTypes
|
|
9
9
|
} from 'react-native/Libraries/Types/CodegenTypes';
|
|
10
10
|
|
|
@@ -49,6 +49,7 @@ export interface NativeProps extends ViewProps {
|
|
|
49
49
|
|
|
50
50
|
scaleBarEnabled?: OptionalProp<boolean>;
|
|
51
51
|
scaleBarPosition?: UnsafeMixed<any>;
|
|
52
|
+
scaleBarUnits?: OptionalProp<string>;
|
|
52
53
|
|
|
53
54
|
zoomEnabled?: OptionalProp<boolean>;
|
|
54
55
|
scrollEnabled?: OptionalProp<boolean>;
|
|
@@ -3,9 +3,9 @@ import type { HostComponent, ViewProps } from 'react-native';
|
|
|
3
3
|
import { Int32 } from 'react-native/Libraries/Types/CodegenTypes';
|
|
4
4
|
import codegenNativeComponent from 'react-native/Libraries/Utilities/codegenNativeComponent';
|
|
5
5
|
|
|
6
|
-
import { Position } from '../types/Position';
|
|
6
|
+
import { type Position } from '../types/Position';
|
|
7
7
|
|
|
8
|
-
import { UnsafeMixed } from './codegenUtils';
|
|
8
|
+
import { type UnsafeMixed } from './codegenUtils';
|
|
9
9
|
|
|
10
10
|
type Point = {
|
|
11
11
|
x: Int32;
|
|
@@ -4,9 +4,9 @@ import codegenNativeComponent from 'react-native/Libraries/Utilities/codegenNati
|
|
|
4
4
|
import { Double, Int32 } from 'react-native/Libraries/Types/CodegenTypes';
|
|
5
5
|
|
|
6
6
|
import type { FilterExpression } from '../utils/MapboxStyles';
|
|
7
|
-
import { StyleValue } from '../utils/StyleValue';
|
|
7
|
+
import { type StyleValue } from '../utils/StyleValue';
|
|
8
8
|
|
|
9
|
-
import { UnsafeMixed } from './codegenUtils';
|
|
9
|
+
import { type UnsafeMixed } from './codegenUtils';
|
|
10
10
|
|
|
11
11
|
// @{codepart-replace-start(CommonLayerNativeComponentsProps.codepart-ts)}
|
|
12
12
|
// see https://github.com/rnmapbox/maps/wiki/FabricOptionalProp
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import type { HostComponent, ViewProps } from 'react-native';
|
|
2
2
|
import codegenNativeComponent from 'react-native/Libraries/Utilities/codegenNativeComponent';
|
|
3
3
|
|
|
4
|
-
import { UnsafeMixed } from './codegenUtils';
|
|
4
|
+
import { type UnsafeMixed } from './codegenUtils';
|
|
5
5
|
|
|
6
6
|
type Asset = {
|
|
7
7
|
__packager_asset?: boolean;
|
|
@@ -7,7 +7,7 @@ import codegenNativeComponent from 'react-native/Libraries/Utilities/codegenNati
|
|
|
7
7
|
|
|
8
8
|
import type { Expression } from '../utils/MapboxStyles';
|
|
9
9
|
|
|
10
|
-
import { UnsafeMixed } from './codegenUtils';
|
|
10
|
+
import { type UnsafeMixed } from './codegenUtils';
|
|
11
11
|
|
|
12
12
|
type Value<T> = T | Expression;
|
|
13
13
|
|
|
@@ -3,7 +3,7 @@ import codegenNativeComponent from 'react-native/Libraries/Utilities/codegenNati
|
|
|
3
3
|
// @ts-ignore - CI environment type resolution issue for CodegenTypes
|
|
4
4
|
import { Double } from 'react-native/Libraries/Types/CodegenTypes';
|
|
5
5
|
|
|
6
|
-
import { UnsafeMixed } from './codegenUtils';
|
|
6
|
+
import { type UnsafeMixed } from './codegenUtils';
|
|
7
7
|
|
|
8
8
|
export interface NativeProps extends ViewProps {
|
|
9
9
|
id: UnsafeMixed<string>;
|
|
@@ -3,7 +3,7 @@ import type { HostComponent, ViewProps } from 'react-native';
|
|
|
3
3
|
import { Double } from 'react-native/Libraries/Types/CodegenTypes';
|
|
4
4
|
import codegenNativeComponent from 'react-native/Libraries/Utilities/codegenNativeComponent';
|
|
5
5
|
|
|
6
|
-
import { UnsafeMixed } from './codegenUtils';
|
|
6
|
+
import { type UnsafeMixed } from './codegenUtils';
|
|
7
7
|
|
|
8
8
|
export interface NativeProps extends ViewProps {
|
|
9
9
|
id: UnsafeMixed<string>;
|
|
@@ -3,7 +3,7 @@ import codegenNativeComponent from 'react-native/Libraries/Utilities/codegenNati
|
|
|
3
3
|
// @ts-ignore - CI environment type resolution issue for CodegenTypes
|
|
4
4
|
import { Double } from 'react-native/Libraries/Types/CodegenTypes';
|
|
5
5
|
|
|
6
|
-
import { UnsafeMixed } from './codegenUtils';
|
|
6
|
+
import { type UnsafeMixed } from './codegenUtils';
|
|
7
7
|
|
|
8
8
|
export interface NativeProps extends ViewProps {
|
|
9
9
|
id: UnsafeMixed<string>;
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import type { HostComponent, ViewProps } from 'react-native';
|
|
2
2
|
import codegenNativeComponent from 'react-native/Libraries/Utilities/codegenNativeComponent';
|
|
3
3
|
import {
|
|
4
|
-
DirectEventHandler,
|
|
5
|
-
Double,
|
|
6
|
-
Int32,
|
|
4
|
+
type DirectEventHandler,
|
|
5
|
+
type Double,
|
|
6
|
+
type Int32,
|
|
7
7
|
// @ts-ignore - CI environment type resolution issue for CodegenTypes
|
|
8
8
|
} from 'react-native/Libraries/Types/CodegenTypes';
|
|
9
9
|
|
|
@@ -21,6 +21,7 @@ export interface NativeProps extends ViewProps {
|
|
|
21
21
|
clusterMaxZoomLevel: UnsafeMixed<Double>;
|
|
22
22
|
clusterProperties: UnsafeMixed<any>;
|
|
23
23
|
maxZoomLevel: UnsafeMixed<Double>;
|
|
24
|
+
minZoomLevel: UnsafeMixed<Double>;
|
|
24
25
|
buffer: UnsafeMixed<Double>;
|
|
25
26
|
tolerance: UnsafeMixed<Double>;
|
|
26
27
|
lineMetrics: UnsafeMixed<boolean>;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import type { HostComponent, ViewProps } from 'react-native';
|
|
2
2
|
import codegenNativeComponent from 'react-native/Libraries/Utilities/codegenNativeComponent';
|
|
3
3
|
import {
|
|
4
|
-
DirectEventHandler,
|
|
5
|
-
Double,
|
|
4
|
+
type DirectEventHandler,
|
|
5
|
+
type Double,
|
|
6
6
|
// @ts-ignore - CI environment type resolution issue for CodegenTypes
|
|
7
7
|
} from 'react-native/Libraries/Types/CodegenTypes';
|
|
8
8
|
|
package/src/types/index.ts
CHANGED
package/src/utils/Logger.ts
CHANGED
|
@@ -809,7 +809,10 @@ export interface LineLayerStyleProps {
|
|
|
809
809
|
*
|
|
810
810
|
* @requires lights
|
|
811
811
|
*/
|
|
812
|
-
lineEmissiveStrength?: Value<
|
|
812
|
+
lineEmissiveStrength?: Value<
|
|
813
|
+
number,
|
|
814
|
+
['zoom', 'measure-light', 'line-progress']
|
|
815
|
+
>;
|
|
813
816
|
|
|
814
817
|
/**
|
|
815
818
|
* The transition affecting any changes to this layer’s lineEmissiveStrength property.
|
|
@@ -1362,6 +1365,18 @@ export interface SymbolLayerStyleProps {
|
|
|
1362
1365
|
* Increase or reduce the saturation of the symbol icon.
|
|
1363
1366
|
*/
|
|
1364
1367
|
iconColorSaturation?: Value<number>;
|
|
1368
|
+
/**
|
|
1369
|
+
* Increase or reduce the contrast of the symbol icon.
|
|
1370
|
+
*/
|
|
1371
|
+
iconColorContrast?: Value<number>;
|
|
1372
|
+
/**
|
|
1373
|
+
* Increase or reduce the brightness of the symbols. The value is the minimum brightness.
|
|
1374
|
+
*/
|
|
1375
|
+
iconColorBrightnessMin?: Value<number>;
|
|
1376
|
+
/**
|
|
1377
|
+
* Increase or reduce the brightness of the symbols. The value is the maximum brightness.
|
|
1378
|
+
*/
|
|
1379
|
+
iconColorBrightnessMax?: Value<number>;
|
|
1365
1380
|
/**
|
|
1366
1381
|
* Specifies an uniform elevation from the ground, in meters.
|
|
1367
1382
|
*/
|
|
@@ -1826,6 +1841,10 @@ export interface FillExtrusionLayerStyleProps {
|
|
|
1826
1841
|
* The transition affecting any changes to this layer’s fillExtrusionLineWidth property.
|
|
1827
1842
|
*/
|
|
1828
1843
|
fillExtrusionLineWidthTransition?: Transition;
|
|
1844
|
+
/**
|
|
1845
|
+
* Enable/Disable shadow casting for this layer
|
|
1846
|
+
*/
|
|
1847
|
+
fillExtrusionCastShadows?: boolean;
|
|
1829
1848
|
}
|
|
1830
1849
|
export interface RasterLayerStyleProps {
|
|
1831
1850
|
/**
|
|
@@ -2047,6 +2066,17 @@ export interface HillshadeLayerStyleProps {
|
|
|
2047
2066
|
* The transition affecting any changes to this layer’s hillshadeAccentColor property.
|
|
2048
2067
|
*/
|
|
2049
2068
|
hillshadeAccentColorTransition?: Transition;
|
|
2069
|
+
/**
|
|
2070
|
+
* Controls the intensity of light emitted on the source features.
|
|
2071
|
+
*
|
|
2072
|
+
* @requires lights
|
|
2073
|
+
*/
|
|
2074
|
+
hillshadeEmissiveStrength?: Value<number, ['zoom', 'measure-light']>;
|
|
2075
|
+
|
|
2076
|
+
/**
|
|
2077
|
+
* The transition affecting any changes to this layer’s hillshadeEmissiveStrength property.
|
|
2078
|
+
*/
|
|
2079
|
+
hillshadeEmissiveStrengthTransition?: Transition;
|
|
2050
2080
|
}
|
|
2051
2081
|
export interface ModelLayerStyleProps {
|
|
2052
2082
|
/**
|
package/src/utils/StyleValue.ts
CHANGED
|
@@ -4,7 +4,7 @@ import BridgeValue, {
|
|
|
4
4
|
type RawValueType,
|
|
5
5
|
type StyleValueJSON,
|
|
6
6
|
} from './BridgeValue';
|
|
7
|
-
import { AllLayerStyleProps } from './MapboxStyles';
|
|
7
|
+
import { type AllLayerStyleProps } from './MapboxStyles';
|
|
8
8
|
import { getStyleType } from './styleMap';
|
|
9
9
|
|
|
10
10
|
export type StyleValue = {
|
package/src/utils/index.ts
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import React, { ReactNode } from 'react';
|
|
1
|
+
import React, { type ReactNode } from 'react';
|
|
2
2
|
import {
|
|
3
3
|
findNodeHandle,
|
|
4
4
|
Platform,
|
|
5
5
|
Image,
|
|
6
|
-
ImageSourcePropType,
|
|
7
|
-
TurboModule,
|
|
6
|
+
type ImageSourcePropType,
|
|
7
|
+
type TurboModule,
|
|
8
8
|
} from 'react-native';
|
|
9
9
|
|
|
10
10
|
export function isAndroid(): boolean {
|
package/src/utils/nativeRef.ts
CHANGED
package/src/utils/styleMap.ts
CHANGED
|
@@ -163,6 +163,9 @@ const styleMap = {
|
|
|
163
163
|
textOcclusionOpacity: StyleTypes.Constant,
|
|
164
164
|
textOcclusionOpacityTransition: StyleTypes.Transition,
|
|
165
165
|
iconColorSaturation: StyleTypes.Constant,
|
|
166
|
+
iconColorContrast: StyleTypes.Constant,
|
|
167
|
+
iconColorBrightnessMin: StyleTypes.Constant,
|
|
168
|
+
iconColorBrightnessMax: StyleTypes.Constant,
|
|
166
169
|
symbolZOffset: StyleTypes.Constant,
|
|
167
170
|
symbolZOffsetTransition: StyleTypes.Transition,
|
|
168
171
|
|
|
@@ -245,6 +248,7 @@ const styleMap = {
|
|
|
245
248
|
fillExtrusionEmissiveStrengthTransition: StyleTypes.Transition,
|
|
246
249
|
fillExtrusionLineWidth: StyleTypes.Constant,
|
|
247
250
|
fillExtrusionLineWidthTransition: StyleTypes.Transition,
|
|
251
|
+
fillExtrusionCastShadows: StyleTypes.Constant,
|
|
248
252
|
|
|
249
253
|
rasterOpacity: StyleTypes.Constant,
|
|
250
254
|
rasterOpacityTransition: StyleTypes.Transition,
|
|
@@ -291,6 +295,8 @@ const styleMap = {
|
|
|
291
295
|
hillshadeHighlightColorTransition: StyleTypes.Transition,
|
|
292
296
|
hillshadeAccentColor: StyleTypes.Color,
|
|
293
297
|
hillshadeAccentColorTransition: StyleTypes.Transition,
|
|
298
|
+
hillshadeEmissiveStrength: StyleTypes.Constant,
|
|
299
|
+
hillshadeEmissiveStrengthTransition: StyleTypes.Transition,
|
|
294
300
|
|
|
295
301
|
modelAllowDensityReduction: StyleTypes.Constant,
|
|
296
302
|
modelId: StyleTypes.Constant,
|
|
@@ -1,7 +1,11 @@
|
|
|
1
|
-
import { Component, ContextType } from 'react';
|
|
2
|
-
|
|
3
|
-
import {
|
|
4
|
-
|
|
1
|
+
import { Component, type ContextType } from 'react';
|
|
2
|
+
|
|
3
|
+
import {
|
|
4
|
+
type CameraProps,
|
|
5
|
+
type CameraStop,
|
|
6
|
+
type CameraRef,
|
|
7
|
+
} from '../../components/Camera';
|
|
8
|
+
import { type Position } from '../../types/Position';
|
|
5
9
|
import MapContext from '../MapContext';
|
|
6
10
|
|
|
7
11
|
function isArray<T>(value: T | ArrayLike<T>): value is ArrayLike<T> {
|