wip
This commit is contained in:
parent
f9de9e3800
commit
f06208ec66
|
@ -1,3 +1,4 @@
|
|||
import SwiftfulRouting
|
||||
import SwiftUI
|
||||
|
||||
@main
|
||||
|
@ -6,8 +7,10 @@ struct AnotherIMApp: App {
|
|||
|
||||
var body: some Scene {
|
||||
WindowGroup {
|
||||
RootView()
|
||||
.environmentObject(wrapper)
|
||||
RouterView { _ in
|
||||
RootView()
|
||||
}
|
||||
.environmentObject(wrapper)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -2,17 +2,27 @@ import SwiftUI
|
|||
|
||||
struct RootView: View {
|
||||
@EnvironmentObject var wrapper: MonalXmppWrapper
|
||||
@Environment(\.router) var router
|
||||
|
||||
var body: some View {
|
||||
VStack {
|
||||
Image(systemName: "globe")
|
||||
.imageScale(.large)
|
||||
.foregroundStyle(.tint)
|
||||
Text("Hello, world!")
|
||||
ZStack {
|
||||
Color.Material.Background.dark
|
||||
Image(.aimLogo)
|
||||
.resizable()
|
||||
.frame(width: 200, height: 200)
|
||||
}
|
||||
.padding()
|
||||
.ignoresSafeArea()
|
||||
.onAppear {
|
||||
print("test")
|
||||
switch wrapper.accountsAvailability {
|
||||
case .noAccounts:
|
||||
break
|
||||
|
||||
case .someEnabled:
|
||||
break
|
||||
|
||||
case .allDisabled:
|
||||
break
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue