@complexify/expo-mapbox-navigation 1.1.9 → 1.2.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.
@@ -200,10 +200,10 @@ class CustomDayStyle: StandardDayStyle {
200
200
 
201
201
  // Way Name View
202
202
  if let bgColor = customWayNameBackgroundColor {
203
- WayNameView.appearance(for: traitCollection).backgroundColor = bgColor.withAlphaComponent(0.8)
203
+ WayNameLabel.appearance(for: traitCollection).backgroundColor = bgColor.withAlphaComponent(0.8)
204
204
  }
205
205
  if let textColor = customWayNameTextColor {
206
- WayNameView.appearance(for: traitCollection).textColor = textColor
206
+ WayNameLabel.appearance(for: traitCollection).textColor = textColor
207
207
  }
208
208
 
209
209
  // Top Banner
@@ -265,46 +265,46 @@ class CustomDayStyle: StandardDayStyle {
265
265
 
266
266
  // Steps List
267
267
  if let bgColor = customStepsBackgroundColor {
268
- StepsTableView.appearance(for: traitCollection).backgroundColor = bgColor
268
+ StepsViewController.appearance(for: traitCollection).tableView.backgroundColor = bgColor
269
269
  }
270
270
  if let primaryTextColor = customStepsPrimaryTextColor {
271
- StepTableViewCell.appearance(for: traitCollection).primaryLabel.textColor = primaryTextColor
271
+ StepInstructionsView.appearance(for: traitCollection).primaryLabel.textColor = primaryTextColor
272
272
  }
273
273
  if let secondaryTextColor = customStepsSecondaryTextColor {
274
- StepTableViewCell.appearance(for: traitCollection).secondaryLabel.textColor = secondaryTextColor
274
+ StepInstructionsView.appearance(for: traitCollection).secondaryLabel.textColor = secondaryTextColor
275
275
  }
276
276
 
277
277
  // Lane View
278
278
  if let bgColor = customLaneViewBackgroundColor {
279
- LanesView.appearance(for: traitCollection).backgroundColor = bgColor
279
+ LaneView.appearance(for: traitCollection).backgroundColor = bgColor
280
280
  }
281
281
  if let fgColor = customLaneViewForegroundColor {
282
- LaneView.appearance(for: traitCollection).foregroundColor = fgColor
282
+ LaneView.appearance(for: traitCollection).primaryColor = fgColor
283
283
  }
284
284
  if let separatorColor = customLaneViewSeparatorColor {
285
- LanesView.appearance(for: traitCollection).separatorColor = separatorColor
285
+ LaneView.appearance(for: traitCollection).separatorColor = separatorColor
286
286
  }
287
287
 
288
288
  // Next Banner View
289
289
  if let bgColor = customNextBannerBackgroundColor {
290
- NextBannerView.appearance(for: traitCollection).backgroundColor = bgColor
290
+ NextInstructionView.appearance(for: traitCollection).backgroundColor = bgColor
291
291
  }
292
292
  if let primaryTextColor = customNextBannerPrimaryTextColor {
293
- NextBannerView.appearance(for: traitCollection).primaryLabel.textColor = primaryTextColor
293
+ NextInstructionView.appearance(for: traitCollection).primaryLabel.textColor = primaryTextColor
294
294
  }
295
295
  if let secondaryTextColor = customNextBannerSecondaryTextColor {
296
- NextBannerView.appearance(for: traitCollection).secondaryLabel.textColor = secondaryTextColor
296
+ NextInstructionView.appearance(for: traitCollection).secondaryLabel.textColor = secondaryTextColor
297
297
  }
298
298
  if let distanceTextColor = customNextBannerDistanceTextColor {
299
- NextBannerView.appearance(for: traitCollection).distanceLabel.textColor = distanceTextColor
299
+ NextInstructionView.appearance(for: traitCollection).distanceLabel.textColor = distanceTextColor
300
300
  }
301
301
 
302
302
  // Progress Bar
303
303
  if let progressColor = customProgressBarProgressColor {
304
- ProgressBar.appearance(for: traitCollection).progressColor = progressColor
304
+ RouteProgressView.appearance(for: traitCollection).progressColor = progressColor
305
305
  }
306
306
  if let backgroundColor = customProgressBarBackgroundColor {
307
- ProgressBar.appearance(for: traitCollection).backgroundColor = backgroundColor
307
+ RouteProgressView.appearance(for: traitCollection).backgroundColor = backgroundColor
308
308
  }
309
309
 
310
310
  // Exit View
@@ -35,12 +35,6 @@ class ExpoMapboxNavigationView: ExpoView {
35
35
  controller.view.frame = bounds
36
36
  }
37
37
 
38
- // Way Name View
39
- func setWayNameViewTextColor(hexColor: String) {
40
- controller.customDayStyle.customWayNameTextColor = UIColor(hex: hexColor)
41
- controller.update()
42
- }
43
-
44
38
  // Steps List
45
39
  func setStepsBackgroundColor(hexColor: String) {
46
40
  controller.customDayStyle.customStepsBackgroundColor = UIColor(hex: hexColor)
@@ -178,7 +172,7 @@ class ExpoMapboxNavigationView: ExpoView {
178
172
  controller.customDayStyle.customDistanceUnitColor = UIColor(hex: hexColor)
179
173
  controller.update()
180
174
  }
181
-
175
+
182
176
  func setDistanceValueColor(hexColor: String) {
183
177
  controller.customDayStyle.customDistanceValueColor = UIColor(hex: hexColor)
184
178
  controller.update()
@@ -674,26 +668,6 @@ class ExpoMapboxNavigationViewController: UIViewController {
674
668
  update()
675
669
  }
676
670
 
677
- func setManeuverViewPrimaryColor(hexColor: String) {
678
- customDayStyle.customManeuverViewPrimaryColor = UIColor(hex: hexColor)
679
- update()
680
- }
681
-
682
- func setManeuverViewSecondaryColor(hexColor: String) {
683
- customDayStyle.customManeuverViewSecondaryColor = UIColor(hex: hexColor)
684
- update()
685
- }
686
-
687
- func setManeuverViewTextColor(hexColor: String) {
688
- customDayStyle.customManeuverViewTextColor = UIColor(hex: hexColor)
689
- update()
690
- }
691
-
692
- func setManeuverViewBackgroundColor(hexColor: String) {
693
- customDayStyle.customManeuverViewBackgroundColor = UIColor(hex: hexColor)
694
- update()
695
- }
696
-
697
671
  func setManeuverViewPrimaryColorHighlighted(hexColor: String) {
698
672
  customDayStyle.customManeuverViewPrimaryColorHighlighted = UIColor(hex: hexColor)
699
673
  update()
@@ -736,7 +710,7 @@ class ExpoMapboxNavigationViewController: UIViewController {
736
710
  calculateRoutesTask = Task {
737
711
  switch await self.routingProvider!.calculateRoutes(options: routeOptions).result {
738
712
  case .failure(let error):
739
- print(error.localizedDescription)
713
+ print("Route calculation failed: \(error.localizedDescription)")
740
714
  case .success(let navigationRoutes):
741
715
  onRoutesCalculated(navigationRoutes: navigationRoutes)
742
716
  }
@@ -756,7 +730,7 @@ class ExpoMapboxNavigationViewController: UIViewController {
756
730
  calculateRoutesTask = Task {
757
731
  switch await self.routingProvider!.calculateRoutes(options: matchOptions).result {
758
732
  case .failure(let error):
759
- print(error.localizedDescription)
733
+ print("Map matching failed: \(error.localizedDescription)")
760
734
  case .success(let navigationRoutes):
761
735
  onRoutesCalculated(navigationRoutes: navigationRoutes)
762
736
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@complexify/expo-mapbox-navigation",
3
- "version": "1.1.9",
3
+ "version": "1.2.0",
4
4
  "description": "Expo module for Mapbox's Navigation SDK",
5
5
  "main": "build/index.js",
6
6
  "types": "build/index.d.ts",