27 lines
640 B
Swift
27 lines
640 B
Swift
import SwiftUI
|
|
|
|
struct RootView: View {
|
|
@EnvironmentObject var wrapper: MonalXmppWrapper
|
|
@Environment(\.router) var router
|
|
|
|
var body: some View {
|
|
ZStack {
|
|
Color.Material.Background.dark
|
|
Image(.aimLogo)
|
|
.resizable()
|
|
.frame(width: 200, height: 200)
|
|
}
|
|
.ignoresSafeArea()
|
|
.onAppear {
|
|
switch wrapper.accountsAvailability {
|
|
case .noAccounts, .allDisabled:
|
|
WelcomeScreen()
|
|
|
|
case .someEnabled:
|
|
// here will be main flow
|
|
EmptyView()
|
|
}
|
|
}
|
|
}
|
|
}
|