import Foundation

final class LocalizedNavigationSettings: ObservableObject {

    @Published
    var rootUrl: String

    init(rootUrl: String) {
        self.rootUrl = rootUrl
    }

    init(file: LocalizedNavigationSettingsFile) {
        self.rootUrl = file.rootUrl
    }

    var file: LocalizedNavigationSettingsFile {
        .init(rootUrl: rootUrl)
    }
}

extension LocalizedNavigationSettings {

    static var `default`: LocalizedNavigationSettings {
        .init(rootUrl: "/")
    }
}
