@mapsindoors/react-native-maps-indoors-mapbox 2.6.2 → 2.7.0
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/README.md +10 -1
- package/android/build.gradle +17 -70
- package/android/src/main/java/com/mapsindoorsrn/MapsIndoorsPackage.java +69 -18
- package/android/src/main/java/com/mapsindoorsrn/core/DirectionsRendererModule.java +5 -1
- package/android/src/main/java/com/mapsindoorsrn/core/DirectionsServiceModule.java +5 -2
- package/android/src/main/java/com/mapsindoorsrn/core/MPDisplayRuleModule.java +5 -1
- package/android/src/main/java/com/mapsindoorsrn/core/MapControlModule.java +5 -1
- package/android/src/main/java/com/mapsindoorsrn/core/MapsIndoorsModule.java +4 -1
- package/android/src/main/java/com/mapsindoorsrn/core/UtilsModule.java +4 -1
- package/ios/core/DirectionsRendererBridge.m +5 -0
- package/ios/core/DirectionsRendererModule.swift +92 -72
- package/ios/core/DirectionsServiceBridge.m +1 -1
- package/ios/core/DirectionsServiceModule.swift +44 -51
- package/ios/core/IconStopUrl.swift +1 -1
- package/ios/core/MPDisplayRuleModule.swift +208 -210
- package/ios/core/MapControlModule.swift +284 -216
- package/ios/core/MapsIndoorsData.swift +48 -49
- package/ios/core/MapsIndoorsModule.swift +46 -52
- package/ios/core/RCMapView.swift +1 -1
- package/ios/core/ReactPositionProvider.swift +1 -2
- package/ios/core/RouteIcon.swift +6 -6
- package/ios/core/UtilsModule.swift +37 -42
- package/ios/core/helpers.swift +16 -11
- package/package.json +10 -1
- package/react-native-maps-indoors-mapbox.podspec +3 -3
- package/specs/MapsIndoorsViewNativeComponent.ts +10 -0
- package/specs/NativeDirectionsRendererModule.ts +23 -0
- package/specs/NativeDirectionsServiceModule.ts +22 -0
- package/specs/NativeMPDisplayRuleModule.ts +155 -0
- package/specs/NativeMapControlModule.ts +62 -0
- package/specs/NativeMapsIndoorsModule.ts +43 -0
- package/specs/NativeUtilsModule.ts +21 -0
- package/src/core/MPDirectionsRenderer.ts +15 -0
- package/src/core/MPDirectionsService.ts +1 -1
|
@@ -128,6 +128,21 @@ export default class MPDirectionsRenderer {
|
|
|
128
128
|
await DirectionsRenderer.setAnimatedPolyline(animated, repeating, durationMs);
|
|
129
129
|
}
|
|
130
130
|
|
|
131
|
+
/**
|
|
132
|
+
* Set the colors of the route polyline.
|
|
133
|
+
*
|
|
134
|
+
* Colors are given as hex strings (e.g. "#3071D9").
|
|
135
|
+
*
|
|
136
|
+
* @public
|
|
137
|
+
* @async
|
|
138
|
+
* @param {string} foregroundColor the primary color (animated polyline)
|
|
139
|
+
* @param {string} backgroundColor the secondary color (static polyline)
|
|
140
|
+
* @returns {Promise<void>}
|
|
141
|
+
*/
|
|
142
|
+
public async setPolylineColors(foregroundColor: string, backgroundColor: string): Promise<void> {
|
|
143
|
+
await DirectionsRenderer.setPolyLineColors(foregroundColor, backgroundColor);
|
|
144
|
+
}
|
|
145
|
+
|
|
131
146
|
/**
|
|
132
147
|
* Enable/Disable the route end/start label buttons from showing on the route. Default is true
|
|
133
148
|
*
|
|
@@ -29,7 +29,7 @@ export default class MPDirectionsService {
|
|
|
29
29
|
* @returns {Promise<MPDirectionsService>}
|
|
30
30
|
*/
|
|
31
31
|
public static async create(): Promise<MPDirectionsService> {
|
|
32
|
-
return DirectionsService.
|
|
32
|
+
return DirectionsService.createService().then((resolve: string) => new MPDirectionsService(resolve));
|
|
33
33
|
}
|
|
34
34
|
|
|
35
35
|
/**
|