-
Notifications
You must be signed in to change notification settings - Fork 326
Make NavigationView publicly usable.
#3823
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Make NavigationView publicly usable.
#3823
Conversation
MapboxNavigation.podspec
Outdated
| s.dependency "Solar-dev", "~> 3.0" | ||
| s.dependency "MapboxSpeech", "~> 2.0" | ||
| s.dependency "MapboxMobileEvents", "~> 1.0" | ||
| s.dependency "MapboxGeocoder.swift", "~> 0.14" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why this was added here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Added to fix compilation issues in mapbox/mapbox-navigation-ios-examples#172. Not sure yet, but this dependency might be needed in future to load final destination description.
| lazy var speedLimitView: SpeedLimitView = .forAutoLayout(hidden: true) | ||
|
|
||
| lazy var topBannerContainerView: BannerContainerView = .forAutoLayout() | ||
| public lazy var topBannerContainerView: BannerContainerView = .forAutoLayout() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is it safe to provide readwrite access to these properties?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Idea is to allow users use NavigationView independently. This change will allow them to modify top and bottom banners.
| } | ||
|
|
||
| func commonInit() { | ||
| DayStyle().apply() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is it required?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is the easiest way to apply styling for the views in NavigationView, as some of them are blank. Users are able to change colors to anything else as well.
|
@Udumft, @bamx23, thanks for initial look. This PR is still in draft and more modifications will be required (I've created it for mapbox/mapbox-navigation-ios-examples#172), I'll let you know when it's ready for review. |
2555c09 to
9f74549
Compare
Breaking Changes in MapboxNavigationBreaking API Changes
|
1 similar comment
Breaking Changes in MapboxNavigationBreaking API Changes
|
8c2ce8f to
d559716
Compare
Breaking Changes in MapboxNavigationBreaking API Changes
|
d559716 to
38ef289
Compare
Breaking Changes in MapboxNavigationBreaking API Changes
|
38ef289 to
a59d5bb
Compare
Breaking Changes in MapboxNavigationBreaking API Changes
|
|
Merging this PR into |
Description
This PR makes modifications that are required to make
NavigationViewpublicly usable as a standalone view.New
NavigationViewExamplewas also added for testing purposes.Example that showcases such usage can be found in: mapbox/mapbox-navigation-ios-examples#172.