Skip to content

Conversation

@MaximAlien
Copy link
Contributor

@MaximAlien MaximAlien commented Apr 11, 2022

Description

This PR makes modifications that are required to make NavigationView publicly usable as a standalone view.

New NavigationViewExample was also added for testing purposes.

Example that showcases such usage can be found in: mapbox/mapbox-navigation-ios-examples#172.

@MaximAlien MaximAlien added UI Work related to visual components, Android Auto, Camera, 3D, voice, etc. drop-in labels Apr 11, 2022
@MaximAlien MaximAlien requested a review from a team April 11, 2022 21:48
@MaximAlien MaximAlien self-assigned this Apr 11, 2022
@MaximAlien MaximAlien marked this pull request as draft April 11, 2022 21:48
s.dependency "Solar-dev", "~> 3.0"
s.dependency "MapboxSpeech", "~> 2.0"
s.dependency "MapboxMobileEvents", "~> 1.0"
s.dependency "MapboxGeocoder.swift", "~> 0.14"
Copy link
Contributor

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?

Copy link
Contributor Author

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()
Copy link
Contributor

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?

Copy link
Contributor Author

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()
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is it required?

Copy link
Contributor Author

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.

@MaximAlien
Copy link
Contributor Author

@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.

@MaximAlien MaximAlien force-pushed the maxim/1622-make-navigation-view-publicly-usable branch from 2555c09 to 9f74549 Compare May 4, 2022 23:48
@mapbox-github-ci-issues-public-1

Breaking Changes in MapboxNavigation

Breaking API Changes

FloatingButton

  • removed source.lang.swift.decl.function.method.class: rounded(image:selectedImage:size:) in FloatingButton

1 similar comment
@mapbox-github-ci-issues-public-1

Breaking Changes in MapboxNavigation

Breaking API Changes

FloatingButton

  • removed source.lang.swift.decl.function.method.class: rounded(image:selectedImage:size:) in FloatingButton

@MaximAlien MaximAlien force-pushed the maxim/1622-make-navigation-view-publicly-usable branch from 8c2ce8f to d559716 Compare May 12, 2022 17:35
@mapbox-github-ci-issues-public-1

Breaking Changes in MapboxNavigation

Breaking API Changes

FloatingButton

  • removed source.lang.swift.decl.function.method.class: rounded(image:selectedImage:size:) in FloatingButton

@MaximAlien MaximAlien force-pushed the maxim/1622-make-navigation-view-publicly-usable branch from d559716 to 38ef289 Compare June 5, 2022 22:26
@mapbox-github-ci-issues-public-1

Breaking Changes in MapboxNavigation

Breaking API Changes

FloatingButton

  • removed source.lang.swift.decl.function.method.class: rounded(image:selectedImage:size:) in FloatingButton

@MaximAlien MaximAlien marked this pull request as ready for review June 7, 2022 20:56
@MaximAlien MaximAlien force-pushed the maxim/1622-make-navigation-view-publicly-usable branch from 38ef289 to a59d5bb Compare June 7, 2022 22:27
@mapbox-github-ci-issues-public-1

Breaking Changes in MapboxNavigation

Breaking API Changes

FloatingButton

  • removed source.lang.swift.decl.function.method.class: rounded(image:selectedImage:size:) in FloatingButton

@MaximAlien
Copy link
Contributor Author

Merging this PR into maxim/1378-add-preview-view-controller to continue work there.

@MaximAlien MaximAlien merged commit 62220e3 into maxim/1378-add-preview-view-controller Jun 8, 2022
@MaximAlien MaximAlien deleted the maxim/1622-make-navigation-view-publicly-usable branch June 8, 2022 00:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

drop-in UI Work related to visual components, Android Auto, Camera, 3D, voice, etc.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants