aboutsummaryrefslogtreecommitdiff
path: root/Hotline/Views/ChatView.swift
diff options
context:
space:
mode:
authorDustin Mierau <dustin@mierau.me>2023-12-07 00:14:31 -0800
committerDustin Mierau <dustin@mierau.me>2023-12-07 00:14:31 -0800
commitf0e278db3b6e9022355ac8a25c301936f15454cf (patch)
tree5d5e62efcb4a626edf2c4ad885d069aad5b36c13 /Hotline/Views/ChatView.swift
parent2305aa8eab18ec5e60d940351793642145de5bd5 (diff)
Few style changes in chat and files and news.
Diffstat (limited to 'Hotline/Views/ChatView.swift')
-rw-r--r--Hotline/Views/ChatView.swift11
1 files changed, 7 insertions, 4 deletions
diff --git a/Hotline/Views/ChatView.swift b/Hotline/Views/ChatView.swift
index 108aea3..2283cdd 100644
--- a/Hotline/Views/ChatView.swift
+++ b/Hotline/Views/ChatView.swift
@@ -15,7 +15,7 @@ struct ChatView: View {
@State private var contentHeight: CGFloat = 0
@Namespace var bottomID
-
+
var body: some View {
NavigationStack {
VStack(spacing: 0) {
@@ -26,6 +26,7 @@ struct ChatView: View {
if msg.type == .agreement {
VStack(alignment: .leading) {
Text(msg.text)
+ .font(.system(size: 11, weight: .regular, design: .monospaced))
.padding()
.opacity(0.75)
.background(colorScheme == .dark ? Color(white: 0.1) : Color(white: 0.96))
@@ -36,10 +37,12 @@ struct ChatView: View {
else {
HStack(alignment: .firstTextBaseline) {
if !msg.username.isEmpty {
- Text("\(msg.username):").bold()
+ Text("**\(msg.username):** \(msg.text)")
+ }
+ else {
+ Text(msg.text)
+ .textSelection(.enabled)
}
- Text(msg.text)
- .textSelection(.enabled)
Spacer()
}
.padding()