import Foundation

enum AppFlow: Codable {
    case start
    case welcome
    case accounts
    case registration
    case contacts
    case chats
    case settings
}

struct AppState: Stateable {
    var appVersion: String
    var currentFlow: AppFlow

    var accountsState: AccountsState
    var registrationState: RegistrationState
}

// MARK: Init
extension AppState {
    init() {
        appVersion = Const.appVersion
        currentFlow = .start

        accountsState = .init()
        registrationState = .init()
    }
}
