@complexify/expo-mapbox-navigation 1.2.2 → 1.3.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.
@@ -210,50 +210,6 @@ public class ExpoMapboxNavigationModule: Module {
210
210
  }
211
211
  }
212
212
 
213
- Prop("maneuverViewPrimaryColor") { (view: ExpoMapboxNavigationView, color: String?) in
214
- if let hexColor = color {
215
- view.controller.setManeuverViewPrimaryColor(hexColor: hexColor)
216
- }
217
- }
218
-
219
- Prop("maneuverViewSecondaryColor") { (view: ExpoMapboxNavigationView, color: String?) in
220
- if let hexColor = color {
221
- view.controller.setManeuverViewSecondaryColor(hexColor: hexColor)
222
- }
223
- }
224
-
225
- Prop("maneuverViewTextColor") { (view: ExpoMapboxNavigationView, color: String?) in
226
- if let hexColor = color {
227
- view.controller.setManeuverViewTextColor(hexColor: hexColor)
228
- }
229
- }
230
-
231
- Prop("maneuverViewBackgroundColor") { (view: ExpoMapboxNavigationView, color: String?) in
232
- if let hexColor = color {
233
- view.controller.setManeuverViewBackgroundColor(hexColor: hexColor)
234
- }
235
- }
236
-
237
- Prop("maneuverViewPrimaryColorHighlighted") { (view: ExpoMapboxNavigationView, color: String?) in
238
- if let hexColor = color {
239
- view.controller.setManeuverViewPrimaryColorHighlighted(hexColor: hexColor)
240
- }
241
- }
242
-
243
- Prop("maneuverViewSecondaryColorHighlighted") { (view: ExpoMapboxNavigationView, color: String?) in
244
- if let hexColor = color {
245
- view.controller.setManeuverViewSecondaryColorHighlighted(hexColor: hexColor)
246
- }
247
- }
248
-
249
- // Way Name View
250
- Prop("wayNameViewTextColor") { (view: ExpoMapboxNavigationView, color: String?) in
251
- if let hexColor = color {
252
- view.controller.setWayNameViewTextColor(hexColor: hexColor)
253
- }
254
- }
255
-
256
- // Steps List
257
213
  Prop("stepsBackgroundColor") { (view: ExpoMapboxNavigationView, color: String?) in
258
214
  if let hexColor = color {
259
215
  view.controller.setStepsBackgroundColor(hexColor: hexColor)
@@ -278,34 +234,30 @@ public class ExpoMapboxNavigationModule: Module {
278
234
  }
279
235
  }
280
236
 
281
- Prop("stepsManeuverViewSecondaryColor") { (view: ExpoMapboxNavigationView, color: String?) in
237
+ Prop("laneViewBackgroundColor") { (view: ExpoMapboxNavigationView, color: String?) in
282
238
  if let hexColor = color {
283
- view.controller.setStepsManeuverViewSecondaryColor(hexColor: hexColor)
239
+ view.controller.setLaneViewBackgroundColor(hexColor: hexColor)
284
240
  }
285
241
  }
286
242
 
287
- Prop("stepsSeparatorColor") { (view: ExpoMapboxNavigationView, color: String?) in
243
+ Prop("stepsManeuverViewSecondaryColor") { (view: ExpoMapboxNavigationView, color: String?) in
288
244
  if let hexColor = color {
289
- view.controller.setStepsSeparatorColor(hexColor: hexColor)
245
+ view.controller.customDayStyle.customStepsManeuverViewSecondaryColor = UIColor(hex: hexColor)
246
+ view.controller.update()
290
247
  }
291
248
  }
292
249
 
293
- // Lane View
294
- Prop("laneViewBackgroundColor") { (view: ExpoMapboxNavigationView, color: String?) in
250
+ Prop("stepsSeparatorColor") { (view: ExpoMapboxNavigationView, color: String?) in
295
251
  if let hexColor = color {
296
- view.controller.setLaneViewBackgroundColor(hexColor: hexColor)
252
+ view.controller.customDayStyle.customStepsSeparatorColor = UIColor(hex: hexColor)
253
+ view.controller.update()
297
254
  }
298
255
  }
299
256
 
300
257
  Prop("laneViewForegroundColor") { (view: ExpoMapboxNavigationView, color: String?) in
301
258
  if let hexColor = color {
302
- view.controller.setLaneViewForegroundColor(hexColor: hexColor)
303
- }
304
- }
305
-
306
- Prop("laneViewSeparatorColor") { (view: ExpoMapboxNavigationView, color: String?) in
307
- if let hexColor = color {
308
- view.controller.setLaneViewSeparatorColor(hexColor: hexColor)
259
+ view.controller.customDayStyle.customLaneViewForegroundColor = UIColor(hex: hexColor)
260
+ view.controller.update()
309
261
  }
310
262
  }
311
263
 
@@ -347,243 +299,117 @@ public class ExpoMapboxNavigationModule: Module {
347
299
  }
348
300
  }
349
301
 
350
- // Instructions Card
351
- Prop("instructionsCardBackgroundColor") { (view: ExpoMapboxNavigationView, color: String?) in
352
- if let hexColor = color {
353
- view.setInstructionsCardBackgroundColor(hexColor: hexColor)
354
- }
355
- }
356
-
357
- Prop("instructionsCardSeparatorColor") { (view: ExpoMapboxNavigationView, color: String?) in
358
- if let hexColor = color {
359
- view.setInstructionsCardSeparatorColor(hexColor: hexColor)
360
- }
361
- }
362
-
363
- Prop("instructionsCardHighlightedSeparatorColor") { (view: ExpoMapboxNavigationView, color: String?) in
364
- if let hexColor = color {
365
- view.setInstructionsCardHighlightedSeparatorColor(hexColor: hexColor)
366
- }
367
- }
368
-
369
- // Exit View
370
- Prop("exitViewForegroundColor") { (view: ExpoMapboxNavigationView, color: String?) in
371
- if let hexColor = color {
372
- view.setExitViewForegroundColor(hexColor: hexColor)
373
- }
374
- }
375
-
376
- Prop("exitViewBorderColor") { (view: ExpoMapboxNavigationView, color: String?) in
377
- if let hexColor = color {
378
- view.setExitViewBorderColor(hexColor: hexColor)
379
- }
380
- }
381
-
382
- Prop("exitViewHighlightColor") { (view: ExpoMapboxNavigationView, color: String?) in
383
- if let hexColor = color {
384
- view.setExitViewHighlightColor(hexColor: hexColor)
385
- }
386
- }
387
-
388
- // Route Shield Colors
389
- Prop("roadShieldBlackColor") { (view: ExpoMapboxNavigationView, color: String?) in
390
- if let hexColor = color {
391
- view.setRoadShieldBlackColor(hexColor: hexColor)
392
- }
393
- }
394
-
395
- Prop("roadShieldBlueColor") { (view: ExpoMapboxNavigationView, color: String?) in
396
- if let hexColor = color {
397
- view.setRoadShieldBlueColor(hexColor: hexColor)
398
- }
399
- }
400
-
401
- Prop("roadShieldGreenColor") { (view: ExpoMapboxNavigationView, color: String?) in
402
- if let hexColor = color {
403
- view.setRoadShieldGreenColor(hexColor: hexColor)
404
- }
405
- }
406
-
407
- Prop("roadShieldRedColor") { (view: ExpoMapboxNavigationView, color: String?) in
408
- if let hexColor = color {
409
- view.setRoadShieldRedColor(hexColor: hexColor)
410
- }
411
- }
412
-
413
- Prop("roadShieldWhiteColor") { (view: ExpoMapboxNavigationView, color: String?) in
302
+ // Maneuver View
303
+ Prop("maneuverViewPrimaryColor") { (view: ExpoMapboxNavigationView, color: String?) in
414
304
  if let hexColor = color {
415
- view.setRoadShieldWhiteColor(hexColor: hexColor)
305
+ view.controller.setManeuverViewPrimaryColor(hexColor: hexColor)
416
306
  }
417
307
  }
418
308
 
419
- Prop("roadShieldYellowColor") { (view: ExpoMapboxNavigationView, color: String?) in
309
+ Prop("maneuverViewSecondaryColor") { (view: ExpoMapboxNavigationView, color: String?) in
420
310
  if let hexColor = color {
421
- view.setRoadShieldYellowColor(hexColor: hexColor)
311
+ view.controller.setManeuverViewSecondaryColor(hexColor: hexColor)
422
312
  }
423
313
  }
424
314
 
425
- Prop("roadShieldDefaultColor") { (view: ExpoMapboxNavigationView, color: String?) in
315
+ Prop("maneuverViewPrimaryColorHighlighted") { (view: ExpoMapboxNavigationView, color: String?) in
426
316
  if let hexColor = color {
427
- view.setRoadShieldDefaultColor(hexColor: hexColor)
317
+ view.controller.setManeuverViewPrimaryColorHighlighted(hexColor: hexColor)
428
318
  }
429
319
  }
430
320
 
431
- // Button Properties
432
- Prop("buttonTextColor") { (view: ExpoMapboxNavigationView, color: String?) in
321
+ Prop("maneuverViewSecondaryColorHighlighted") { (view: ExpoMapboxNavigationView, color: String?) in
433
322
  if let hexColor = color {
434
- view.setButtonTextColor(hexColor: hexColor)
323
+ view.controller.setManeuverViewSecondaryColorHighlighted(hexColor: hexColor)
435
324
  }
436
325
  }
437
326
 
438
- Prop("cancelButtonTintColor") { (view: ExpoMapboxNavigationView, color: String?) in
327
+ // Instructions Card
328
+ Prop("instructionsCardBackgroundColor") { (view: ExpoMapboxNavigationView, color: String?) in
439
329
  if let hexColor = color {
440
- view.setCancelButtonTintColor(hexColor: hexColor)
330
+ view.controller.setInstructionsCardBackgroundColor(hexColor: hexColor)
441
331
  }
442
332
  }
443
333
 
444
- Prop("previewButtonTintColor") { (view: ExpoMapboxNavigationView, color: String?) in
334
+ Prop("instructionsCardSeparatorColor") { (view: ExpoMapboxNavigationView, color: String?) in
445
335
  if let hexColor = color {
446
- view.setPreviewButtonTintColor(hexColor: hexColor)
336
+ view.controller.setInstructionsCardSeparatorColor(hexColor: hexColor)
447
337
  }
448
338
  }
449
339
 
450
- Prop("startButtonTintColor") { (view: ExpoMapboxNavigationView, color: String?) in
340
+ Prop("instructionsCardHighlightedSeparatorColor") { (view: ExpoMapboxNavigationView, color: String?) in
451
341
  if let hexColor = color {
452
- view.setStartButtonTintColor(hexColor: hexColor)
342
+ view.controller.setInstructionsCardHighlightedSeparatorColor(hexColor: hexColor)
453
343
  }
454
344
  }
455
345
 
456
- Prop("dismissButtonBackgroundColor") { (view: ExpoMapboxNavigationView, color: String?) in
346
+ // Exit View
347
+ Prop("exitViewForegroundColor") { (view: ExpoMapboxNavigationView, color: String?) in
457
348
  if let hexColor = color {
458
- view.setDismissButtonBackgroundColor(hexColor: hexColor)
349
+ view.controller.setExitViewForegroundColor(hexColor: hexColor)
459
350
  }
460
351
  }
461
352
 
462
- Prop("dismissButtonTextColor") { (view: ExpoMapboxNavigationView, color: String?) in
353
+ Prop("exitViewBorderColor") { (view: ExpoMapboxNavigationView, color: String?) in
463
354
  if let hexColor = color {
464
- view.setDismissButtonTextColor(hexColor: hexColor)
355
+ view.controller.setExitViewBorderColor(hexColor: hexColor)
465
356
  }
466
357
  }
467
358
 
468
- Prop("backButtonBackgroundColor") { (view: ExpoMapboxNavigationView, color: String?) in
359
+ Prop("exitViewHighlightColor") { (view: ExpoMapboxNavigationView, color: String?) in
469
360
  if let hexColor = color {
470
- view.setBackButtonBackgroundColor(hexColor: hexColor)
361
+ view.controller.setExitViewHighlightColor(hexColor: hexColor)
471
362
  }
472
363
  }
473
364
 
474
- Prop("backButtonTintColor") { (view: ExpoMapboxNavigationView, color: String?) in
365
+ // Route Shield
366
+ Prop("routeShieldForegroundColor") { (view: ExpoMapboxNavigationView, color: String?) in
475
367
  if let hexColor = color {
476
- view.setBackButtonTintColor(hexColor: hexColor)
368
+ view.controller.setRouteShieldForegroundColor(hexColor: hexColor)
477
369
  }
478
370
  }
479
371
 
480
- Prop("backButtonTextColor") { (view: ExpoMapboxNavigationView, color: String?) in
372
+ Prop("routeShieldBorderColor") { (view: ExpoMapboxNavigationView, color: String?) in
481
373
  if let hexColor = color {
482
- view.setBackButtonTextColor(hexColor: hexColor)
374
+ view.controller.setRouteShieldBorderColor(hexColor: hexColor)
483
375
  }
484
376
  }
485
377
 
486
- Prop("backButtonBorderColor") { (view: ExpoMapboxNavigationView, color: String?) in
378
+ Prop("routeShieldHighlightColor") { (view: ExpoMapboxNavigationView, color: String?) in
487
379
  if let hexColor = color {
488
- view.setBackButtonBorderColor(hexColor: hexColor)
380
+ view.controller.setRouteShieldHighlightColor(hexColor: hexColor)
489
381
  }
490
382
  }
491
383
 
492
- // Navigation View
493
- Prop("navigationViewBackgroundColor") { (view: ExpoMapboxNavigationView, color: String?) in
384
+ // Distance Labels
385
+ Prop("distanceRemainingColor") { (view: ExpoMapboxNavigationView, color: String?) in
494
386
  if let hexColor = color {
495
- view.setNavigationViewBackgroundColor(hexColor: hexColor)
387
+ view.controller.setDistanceRemainingColor(hexColor: hexColor)
496
388
  }
497
389
  }
498
390
 
499
- // Distance Label Properties
500
- Prop("distanceLabelUnitTextColor") { (view: ExpoMapboxNavigationView, color: String?) in
391
+ Prop("distanceUnitColor") { (view: ExpoMapboxNavigationView, color: String?) in
501
392
  if let hexColor = color {
502
- view.setDistanceLabelUnitTextColor(hexColor: hexColor)
393
+ view.controller.setDistanceUnitColor(hexColor: hexColor)
503
394
  }
504
395
  }
505
396
 
506
- Prop("distanceLabelValueTextColor") { (view: ExpoMapboxNavigationView, color: String?) in
397
+ Prop("distanceValueColor") { (view: ExpoMapboxNavigationView, color: String?) in
507
398
  if let hexColor = color {
508
- view.setDistanceLabelValueTextColor(hexColor: hexColor)
399
+ view.controller.setDistanceValueColor(hexColor: hexColor)
509
400
  }
510
401
  }
511
402
 
512
403
  // Rating Control
513
404
  Prop("ratingControlNormalColor") { (view: ExpoMapboxNavigationView, color: String?) in
514
405
  if let hexColor = color {
515
- view.setRatingControlNormalColor(hexColor: hexColor)
406
+ view.controller.setRatingControlNormalColor(hexColor: hexColor)
516
407
  }
517
408
  }
518
409
 
519
410
  Prop("ratingControlSelectedColor") { (view: ExpoMapboxNavigationView, color: String?) in
520
411
  if let hexColor = color {
521
- view.setRatingControlSelectedColor(hexColor: hexColor)
522
- }
523
- }
524
-
525
- // Steps Properties
526
- Prop("stepsBackgroundViewColor") { (view: ExpoMapboxNavigationView, color: String?) in
527
- if let hexColor = color {
528
- view.setStepsBackgroundViewColor(hexColor: hexColor)
529
- }
530
- }
531
-
532
- Prop("stepsTableHeaderTintColor") { (view: ExpoMapboxNavigationView, color: String?) in
533
- if let hexColor = color {
534
- view.setStepsTableHeaderTintColor(hexColor: hexColor)
535
- }
536
- }
537
-
538
- Prop("stepsTableHeaderTextColor") { (view: ExpoMapboxNavigationView, color: String?) in
539
- if let hexColor = color {
540
- view.setStepsTableHeaderTextColor(hexColor: hexColor)
541
- }
542
- }
543
-
544
- Prop("stepInstructionsBackgroundColor") { (view: ExpoMapboxNavigationView, color: String?) in
545
- if let hexColor = color {
546
- view.setStepInstructionsBackgroundColor(hexColor: hexColor)
547
- }
548
- }
549
-
550
- Prop("stepTableViewCellBackgroundColor") { (view: ExpoMapboxNavigationView, color: String?) in
551
- if let hexColor = color {
552
- view.setStepTableViewCellBackgroundColor(hexColor: hexColor)
553
- }
554
- }
555
-
556
- // Next Instruction
557
- Prop("nextInstructionNormalTextColor") { (view: ExpoMapboxNavigationView, color: String?) in
558
- if let hexColor = color {
559
- view.setNextInstructionNormalTextColor(hexColor: hexColor)
560
- }
561
- }
562
-
563
- Prop("nextInstructionContainedTextColor") { (view: ExpoMapboxNavigationView, color: String?) in
564
- if let hexColor = color {
565
- view.setNextInstructionContainedTextColor(hexColor: hexColor)
566
- }
567
- }
568
-
569
- // Secondary Label Properties
570
- Prop("secondaryLabelNormalTextColor") { (view: ExpoMapboxNavigationView, color: String?) in
571
- if let hexColor = color {
572
- view.setSecondaryLabelNormalTextColor(hexColor: hexColor)
573
- }
574
- }
575
-
576
- // Stylable Label
577
- Prop("stylableLabelNormalTextColor") { (view: ExpoMapboxNavigationView, color: String?) in
578
- if let hexColor = color {
579
- view.setStylableLabelNormalTextColor(hexColor: hexColor)
580
- }
581
- }
582
-
583
- // CarPlay Properties
584
- Prop("carPlayCompassBackgroundColor") { (view: ExpoMapboxNavigationView, color: String?) in
585
- if let hexColor = color {
586
- view.setCarPlayCompassBackgroundColor(hexColor: hexColor)
412
+ view.controller.setRatingControlSelectedColor(hexColor: hexColor)
587
413
  }
588
414
  }
589
415
  }