feat: dynamic app name and custom navigation app selector#91
Open
PremSharma-Intelegencia wants to merge 2 commits intofleetbase:mainfrom
Open
Conversation
Previously, the app used the native React Native Alert to display available navigation apps, which only supports up to three options. This caused issues when users had more than three navigation apps installed, as some apps (like Google Maps) would not appear in the list, leading to confusion. This update introduces a custom bottom sheet component (`NavigationAppSelector`) to display all available navigation apps, ensuring users can always select their preferred app regardless of how many are installed. Additionally: - Removed unused imports and reordered imports automatically via lint and Prettier. - Minor code cleanup from automatic formatting during file save.
- Updated android/app/build.gradle to set app_name from APP_NAME env variable.
- Modified android/app/src/main/res/values/strings.xml to remove hardcoded
app_name.
- Updated DriverNavigator.tsx to use config('APP_NAME', 'Navigator') for
displaying the app name in headers and tab labels.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
🧭 Summary
This PR enhances Fleetbase Navigator by improving configurability and user experience with two key updates:
Dynamic App Name via Environment Variable (
APP_NAME)The app name is now configurable via an environment variable for Android and the app header, enabling dynamic branding and easier deployment across environments.
Custom Modal for Navigation App Selection
Replaces the React Native
Alert, which was limited to three options, with a fully custom bottom sheet modal. Users can now view and select from all installed navigation apps.🔧 Description of Changes
🧱 Dynamic App Name
android/app/build.gradleto set the app name dynamically using theAPP_NAMEenvironment variable.android/app/src/main/res/values/strings.xml.DriverNavigator.tsxto useconfig('APP_NAME', 'Navigator')for headers and tab labels.Impact:
The app name now automatically adapts to environment configuration, eliminating the need for manual edits per deployment.
🪟 Custom Navigation App Selector
NavigationAppSelector.Impact:
Users enjoy a smoother, more intuitive experience when choosing a navigation app.
🎨 UI / UX Improvements
Alertlimited to 3 options✅ Key Benefits: