kanno927's picture
feature(#134): finish UI Implementation for general chat, search images and contacts in Apple Watch
17afd55
raw
history blame contribute delete
906 Bytes
import SwiftUI
struct ContactView: View {
@State var contact: Contact
var body: some View {
VStack {
Text(contact.displayName).padding()
.bold()
.foregroundColor(.white)
.font(.system(size: 18))
.padding()
List {
ForEach(contact.phoneNumbers, id: \.self) { phone in
Text(phone)
.foregroundColor(.white)
.font(.system(size: 15))
.padding()
}
}.listStyle(PlainListStyle()).padding(.bottom, 10)
}
}
}
struct ContactView_Previews: PreviewProvider {
static var previews: some View {
ContactView(contact: Contact(
contactId: "5",
displayName: "Peter Luo",
phoneNumbers: ["123-234-345"])
)
}
}