mapbox / mapbox/mapbox-navigation-android

Add interface to suppress "Rerouting..." expression in NavigationView

Open
#3,726 3 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

feature
Dominant language
Kotlin
Stars
651
Forks
321
PR merge metrics
No merged PRs in 30d

Description

**Android API: No dependency**
**Mapbox Navigation SDK version: v1.1.2**

### Steps to trigger behavior
1. Call `MapboxNavigation.setRerouteController` with `null` to disable rerouting
2. Go out side of route

### Expected behavior
"Rerouting..." in `InstructionView` and `ProgressBar` in `SummaryBottomSheet` are not shown.

### Actual behavior
"Rerouting..." in `InstructionView` and `ProgressBar` in `SummaryBottomSheet` are shown.
![feature_request](https://user-images.githubusercontent.com/13183117/97872130-da327700-1d58-11eb-9059-f55ceeb41b1c.gif)

### Detailed information
For current implementation, this is an expected behaviour ([InstructionView](https://github.com/mapbox/mapbox-navigation-android/blob/v1.1.2/libnavigation-ui/src/main/java/com/mapbox/navigation/ui/instruction/InstructionView.java#L235)/[SummaryBottomSheet](https://github.com/mapbox/mapbox-navigation-android/blob/v1.1.2/libnavigation-ui/src/main/java/com/mapbox/navigation/ui/summary/SummaryBottomSheet.java#L121)).

At the same time, showing those information is a bit confusing because it's not rerouting actually. Instead, if SDK have an interface to suppress those behaviour or to customize the expression (e.g. show "Off route"), it would be more user-friendly.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Review the rerouting behavior in libnavigation-ui/src/main/java/com/mapbox/navigation/ui/instruction/InstructionView.java and SummaryBottomSheet.java, at the linked implementation points. Trace how MapboxNavigation.setRerouteController(null) affects these views, then determine the interface needed to suppress or customize the messages; done means both views no longer show misleading rerouting state when rerouting is disabled.

Written by the indexing model from the issue text.

Assessment

Tech stack
android, java
Domain
mobile
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.