diff --git a/Router/Destination.swift b/Router/Destination.swift
index ab5b576..7295026 100644
--- a/Router/Destination.swift
+++ b/Router/Destination.swift
@@ -31,12 +31,11 @@ extension PresentationHint: CustomStringConvertible {
switch self {
case .navigate:
return "navigate"
- case .modal(let metrics):
- let style = metrics.style != nil ? String(describing: metrics.style!) : "none"
- return "modal - animated: \(metrics.animated), style: \(style)"
- case .tab(let index):
+ case let .modal(metrics):
+ return "modal - animated: \(metrics.animated), style: \(metrics.style.styleDescription)"
+ case let .tab(index):
return "tab - index: \(index)"
- case .replaceTab(let index, let shouldSwitch):
+ case let .replaceTab(index, shouldSwitch):
return "replaceTab - index: \(index), shouldSwitch: \(shouldSwitch)"
}
}
@@ -79,3 +78,29 @@ extension PresentationHint: Equatable {
}
}
}
+
+extension Optional where Wrapped == UIModalPresentationStyle {
+ var styleDescription: String {
+ guard case let .some(style) = self else { return "none" }
+ switch style {
+ case .fullScreen:
+ return "fullScreen"
+ case .pageSheet:
+ return "pageSheet"
+ case .formSheet:
+ return "formSheet"
+ case .currentContext:
+ return "currentContext"
+ case .custom:
+ return "custom"
+ case .overFullScreen:
+ return "overFullScreen"
+ case .overCurrentContext:
+ return "overCurrentContext"
+ case .popover:
+ return "popover"
+ case .none:
+ return "none"
+ }
+ }
+}
diff --git a/Router/Info.plist b/Router/Info.plist
index 1007fd9..6db6fe4 100644
--- a/Router/Info.plist
+++ b/Router/Info.plist
@@ -15,7 +15,7 @@
CFBundlePackageType
FMWK
CFBundleShortVersionString
- 1.0
+ 1.1.1
CFBundleVersion
$(CURRENT_PROJECT_VERSION)
NSPrincipalClass