2024-06-19 15:15:27 +00:00
|
|
|
import Martin
|
|
|
|
import SwiftUI
|
|
|
|
|
|
|
|
struct BaseNavigationView: View {
|
|
|
|
@EnvironmentObject var store: AppStore
|
|
|
|
|
|
|
|
public var body: some View {
|
|
|
|
Group {
|
|
|
|
switch store.state.currentFlow {
|
|
|
|
case .start:
|
|
|
|
switch store.state.startState.navigation {
|
|
|
|
case .startScreen:
|
|
|
|
StartScreen()
|
|
|
|
|
|
|
|
case .welcomeScreen:
|
|
|
|
WelcomeScreen()
|
|
|
|
}
|
|
|
|
|
|
|
|
case .accounts:
|
|
|
|
switch store.state.accountsState.navigation {
|
|
|
|
case .addAccount:
|
|
|
|
AddAccountScreen()
|
|
|
|
}
|
|
|
|
|
|
|
|
case .chats:
|
|
|
|
ChatsListScreen()
|
|
|
|
|
|
|
|
case .contacts:
|
|
|
|
ContactsScreen()
|
|
|
|
|
|
|
|
case .settings:
|
|
|
|
SettingsScreen()
|
2024-06-21 10:42:50 +00:00
|
|
|
|
|
|
|
case .conversation:
|
|
|
|
ConversationScreen()
|
2024-08-07 08:36:33 +00:00
|
|
|
|
|
|
|
case .createConversation:
|
|
|
|
CreateConversationMainScreen()
|
2024-06-19 15:15:27 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|