Skip to content
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

Jazzy doc actualization #2347

Merged
merged 4 commits into from
Mar 11, 2020
Merged
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions MapboxCoreNavigation/MBNavigator.swift
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ extension MBFixLocation {
}
}

/// :nodoc:
extension MBRouteState: CustomStringConvertible {
public var description: String {
switch self {
Expand Down
2 changes: 1 addition & 1 deletion MapboxNavigation-Documentation.podspec
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ Pod::Spec.new do |s|

# ――― Source Code ―――――――――――――――――――――――――――――――――――――――――――――――――――――――――――――― #

s.source_files = ["MapboxNavigation/*", "MapboxCoreNavigation/*"]
s.source_files = ["MapboxNavigation/**/*.swift","MapboxCoreNavigation"]

# ――― Resources ―――――――――――――――――――――――――――――――――――――――――――――――――――――――――――――――― #

Expand Down
2 changes: 1 addition & 1 deletion MapboxNavigation.podspec
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ Pod::Spec.new do |s|

# ――― Source Code ―――――――――――――――――――――――――――――――――――――――――――――――――――――――――――――― #

s.source_files = "MapboxNavigation/**/*.{h,m,swift}"
s.source_files = "MapboxNavigation/**/*.swift"

# ――― Resources ―――――――――――――――――――――――――――――――――――――――――――――――――――――――――――――――― #

Expand Down
2 changes: 1 addition & 1 deletion MapboxNavigation/LanesStyleKit.swift
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@

import UIKit


/// :nodoc:
public class LanesStyleKit : NSObject {

//// Drawing Methods
Expand Down
2 changes: 1 addition & 1 deletion MapboxNavigation/ManeuverView.swift
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import MapboxDirections
import MapboxCoreNavigation
import Turf

/// :nodoc:
/// A view that contains a simple image indicating a type of maneuver.
@IBDesignable
open class ManeuverView: UIView {

Expand Down
2 changes: 1 addition & 1 deletion MapboxNavigation/ManeuversStyleKit.swift
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import UIKit


/// :nodoc:
public class ManeuversStyleKit: NSObject {

//// Drawing Methods
Expand Down
4 changes: 2 additions & 2 deletions MapboxNavigation/Style.swift
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ open class Style: NSObject {
/**
URL of the style to display on the map when previewing a route, for example on CarPlay or your own route preview map.
*/
@objc open var previewMapStyleURL = MGLStyle.navigationPreviewDayStyleURL
@objc open var previewMapStyleURL: URL = MGLStyle.navigationPreviewDayStyleURL
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 type explicitly to silence Jazzy warning and correct type displaying in a doc.


/**
Applies the style for all changed properties.
Expand Down Expand Up @@ -228,7 +228,7 @@ open class StylableLabel: UILabel {
}
}

/// :nodoc
/// :nodoc:
@objc(MBStylableView)
open class StylableView: UIView {
@objc dynamic var borderWidth: CGFloat = 0.0 {
Expand Down
83 changes: 54 additions & 29 deletions docs/jazzy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,16 +22,31 @@ custom_categories:
- NavigationViewController
- NavigationViewControllerDelegate
- RouteVoiceController
- VoiceControllerDelegate
- MapboxVoiceController
- NavigationOptions
- NavigationView
Comment on lines +25 to +28
Copy link
Contributor Author

Choose a reason for hiding this comment

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

I tried to group items to where they belong, but I might be mistaken :)

Copy link
Contributor

Choose a reason for hiding this comment

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

This is a good place to put these types. 👍

- name: Core Navigation Logic
children:
- NavigationService
- NavigationServiceDelegate
- MapboxNavigationService
- Router
- RouterDataSource
- RouteController
- RouteControllerDelegate
- RouterDelegate
- RouteProgress
- RouteLegProgress
- RouteStepProgress
- RouteControllerNotificationUserInfoKey
- NavigationEventsManager
- EventsManagerDataSource
- NavigationLocationManager
- ReplayLocationManager
- SimulatedLocationManager
- NavigationRouteOptions
- NavigationMatchOptions
- NavigationDirections
- SimulationMode
- name: Maps
children:
- NavigationMapView
Expand All @@ -40,50 +55,60 @@ custom_categories:
- name: Styling
children:
- Style
- StyleKitArrows
- StylableButton
- StylableLabel
- StyleManager
- StyleManagerNotificationUserInfoKey
- StyleManagerDelegate
- DayStyle
- NightStyle
- name: Formatters
children:
- DistanceFormatter
- RouteStepFormatter
- name: UI Components
children:
- RouteTableViewController
- NavigationPulleyViewController
- Button
- CellSubtitleLabel
- CellTitleLabel
- DashedLineView
- HighlightedButton
- LineView
- ProgressBar
- SeparatorView
- SubtitleLabel
- TitleLabel
- TurnArrowView
- WayNameLabel
- ManeuverView
Copy link
Contributor

Choose a reason for hiding this comment

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

Oh wow, this class got renamed a long time ago in #745. 😅 ManeuverView is marked :nodoc:, but we should actually document it, because developers may need to adjust its appearance() when creating a new Style. Let’s go with this description for now:

A view that contains a simple image indicating a type of maneuver.

- BottomBannerViewController
- BottomBannerViewControllerDelegate
- SpeedLimitView
- UserPuckCourseView
- CourseUpdatable
- GenericRouteShield
- NavigationComponent
- name: CarPlay
children:
- CarPlayManager
- CarPlayManagerDelegate
- CarPlayNavigationViewController
- CarPlayNavigationDelegate
- CarPlayActivity
- CarPlayCompassView
- CarPlayMapViewController
- CarPlaySearchController
- CarPlayConnectionObserver
- name: Configuration
children:
- MaxSecondsSpentTravelingAwayFromStartOfRoute
- RouteControllerDeadReckoningTimeInterval
- RouteControllerMediumAlertInterval
- RouteControllerHighAlertInterval
- RouteControllerManeuverZoneRadius
- RouteControllerMaxManipulatedCourseAngle
- RouteSnappingMaxManipulatedCourseAngle
- RouteControllerMaximumAllowedDegreeOffsetForTurnCompletion
- RouteControllerMaximumDistanceBeforeRecalculating
- RouteControllerMediumAlertInterval
- RouteControllerMinimumDistanceForHighAlertCycling
- RouteControllerMinimumDistanceForHighAlertDriving
- RouteControllerMinimumDistanceForHighAlertWalking
- RouteControllerMinimumDistanceForMediumAlertCycling
- RouteControllerMinimumDistanceForMediumAlertDriving
- RouteControllerMinimumDistanceForMediumAlertWalking
- RouteControllerUserLocationSnappingDistance
- MBCongestionAttribute
- MBCurrentLegAttribute
- MBRouteLineWidthByZoomLevel
Comment on lines +97 to +99
Copy link
Contributor

Choose a reason for hiding this comment

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

Somehow we missed these constants when removing the class prefix from global symbols. As a separate task, we should rename these symbols to remove the class prefix. To avoid conflicts with other modules, we should nest them inside the class that uses them, NavigationMapView.

/cc @JThramer

- NavigationMapViewMinimumDistanceForOverheadZooming
- NavigationViewMinimumVolumeForWarning
- RouteControllerIncorrectCourseMultiplier
- RouteControllerLinkedInstructionBufferMultiplier
- RouteControllerMaximumSpeedForUsingCurrentStep
- RouteControllerMinNumberOfInCorrectCourses
- RouteControllerMinimumBacktrackingDistanceForRerouting
- RouteControllerMinimumDistanceForContinueInstruction
- RouteControllerMinimumDurationRemainingForProactiveRerouting
- RouteControllerMinimumNumberLocationUpdatesBackwards
- RouteControllerNumberOfSecondsForRerouteFeedback
- RouteControllerProactiveReroutingInterval
- RouteSnappingMinimumHorizontalAccuracy
- RouteSnappingMinimumSpeed
- NavigationSettings