Skip to content
Snippets Groups Projects
Commit 618eae31 authored by Dariusz Rybicki's avatar Dariusz Rybicki
Browse files

Show failure in ContactLookupView

parent f7f7def9
No related branches found
No related tags found
2 merge requests!112Restore contacts from backup,!102Release 1.0.0
......@@ -13,10 +13,12 @@ public struct ContactLookupView: View {
init(state: ContactLookupState) {
id = state.id
isLookingUp = state.isLookingUp
failure = state.failure
}
var id: Data
var isLookingUp: Bool
var failure: String?
}
public var body: some View {
......@@ -43,6 +45,14 @@ public struct ContactLookupView: View {
} header: {
Text("Contact ID")
}
if let failure = viewStore.failure {
Section {
Text(failure)
} header: {
Text("Error")
}
}
}
.navigationTitle("Lookup")
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment