mirror of
https://github.com/lumaa-dev/BubbleApp.git
synced 2025-02-02 19:47:19 +01:00
Safari sheet
This commit is contained in:
parent
d2bb747bf9
commit
14f08c6c46
@ -39,6 +39,7 @@ public enum SheetDestination: Identifiable {
|
||||
case welcome
|
||||
case mastodonLogin(logged: Binding<Bool>)
|
||||
case post(content: String = "", replyId: String? = nil)
|
||||
case safari(url: URL)
|
||||
|
||||
public var id: String {
|
||||
switch self {
|
||||
@ -48,6 +49,8 @@ public enum SheetDestination: Identifiable {
|
||||
return "login"
|
||||
case .post:
|
||||
return "post"
|
||||
case .safari:
|
||||
return "safari"
|
||||
}
|
||||
}
|
||||
|
||||
@ -61,6 +64,9 @@ public enum SheetDestination: Identifiable {
|
||||
|
||||
case .post:
|
||||
return false
|
||||
|
||||
case .safari:
|
||||
return false
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -85,7 +91,7 @@ extension View {
|
||||
case .appearence:
|
||||
AppearenceView()
|
||||
case .account(let acc):
|
||||
AccountView(account: acc, navigator: navigator)
|
||||
AccountView(account: acc)
|
||||
case .post(let status):
|
||||
PostDetailsView(status: status)
|
||||
case .about:
|
||||
@ -125,6 +131,8 @@ extension View {
|
||||
case let .mastodonLogin(logged):
|
||||
AddInstanceView(logged: logged)
|
||||
.tint(Color.accentColor)
|
||||
case let .safari(url):
|
||||
SfSafariView(url: url)
|
||||
default:
|
||||
EmptyView()
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user