* refactor UI and API, send command on Enter, fix Date parsing * UI sheets to create connection and groups * show received messages * readme
28 lines
667 B
Swift
28 lines
667 B
Swift
//
|
|
// ChatPreviewView.swift
|
|
// SimpleX
|
|
//
|
|
// Created by Evgeny Poberezkin on 28/01/2022.
|
|
// Copyright © 2022 SimpleX Chat. All rights reserved.
|
|
//
|
|
|
|
import SwiftUI
|
|
|
|
struct ChatPreviewView: View {
|
|
var chatPreview: ChatPreview
|
|
|
|
var body: some View {
|
|
Text(chatPreview.chatInfo.displayName)
|
|
}
|
|
}
|
|
|
|
struct ChatPreviewView_Previews: PreviewProvider {
|
|
static var previews: some View {
|
|
Group{
|
|
ChatPreviewView(chatPreview: ChatPreview(chatInfo: sampleDirectChatInfo))
|
|
ChatPreviewView(chatPreview: ChatPreview(chatInfo: sampleGroupChatInfo))
|
|
}
|
|
.previewLayout(.fixed(width: 300, height: 70))
|
|
}
|
|
}
|