another.im-ios/ConversationsClassic/View/AppRootView.swift

48 lines
1.2 KiB
Swift
Raw Normal View History

2024-08-11 00:28:01 +00:00
import SwiftUI
struct AppRootView: View {
@EnvironmentObject var navigation: NavigationStore
var body: some View {
Group {
switch navigation.flow {
case .start:
StartScreen()
2024-08-11 14:02:18 +00:00
case .entering(let kind):
switch kind {
2024-08-11 00:28:01 +00:00
case .welcome:
WelcomeScreen()
case .login:
LoginScreen()
case .registration:
RegistrationScreen()
}
case .main(let main):
switch main {
2024-08-11 14:02:18 +00:00
case .contacts(let kind):
switch kind {
case .list:
ContactsScreen()
case .add:
ContactsScreen()
.fullScreenCover(isPresented: .constant(true)) {
AddContactOrChannelScreen()
}
}
2024-08-11 00:28:01 +00:00
case .conversations:
EmptyView()
case .settings:
EmptyView()
}
}
}
}
}