homeeondemand / react-native-mapbox-navigation

A navigation UI ready to drop into your React Native application
MIT License
162 stars 123 forks source link

Add showsEndOfRouteFeedback property #19

Closed epavlov closed 3 years ago

epavlov commented 3 years ago

Hi!

This is iOS only change.

I've added showsEndOfRouteFeedback property to allow showing/hiding end of route feedback UI on the iPhone.

Let me know if I missed anything. I specifically did not change anything for Android, because I was not able to find corresponding property in Android Navigation SDK. I found

 override fun onFinalDestinationArrival(enableDetailedFeedbackFlowAfterTbt: Boolean, enableArrivalExperienceFeedback: Boolean)

in the kotlin code (MapboxNavigationView.kt line 176) which seems like the Android equivalent, but I don't know enough Kotlin or Android development to expose it in the bridge.

rossmartin commented 3 years ago

Hey thank you this is great. I'm going to merge this into a feature branch and see if I can get this to work for android also. Either way I'll get this merged into master and publish a new version within the next day.

rossmartin commented 3 years ago

I got this implemented on android in this feature branch and merged it into master. I also defaulted showsEndOfRouteFeedback to false for both platforms. I think most people will not want that UI showing up at the end of navigation.

It is published in 1.0.4.

epavlov commented 3 years ago

@rossmartin Awesome! Thank you!