aboutsummaryrefslogtreecommitdiff
path: root/Hotline/Views/MessageBoardView.swift
diff options
context:
space:
mode:
Diffstat (limited to 'Hotline/Views/MessageBoardView.swift')
-rw-r--r--Hotline/Views/MessageBoardView.swift24
1 files changed, 15 insertions, 9 deletions
diff --git a/Hotline/Views/MessageBoardView.swift b/Hotline/Views/MessageBoardView.swift
index e5f1521..8b1a30c 100644
--- a/Hotline/Views/MessageBoardView.swift
+++ b/Hotline/Views/MessageBoardView.swift
@@ -9,19 +9,25 @@ struct MessageBoardView: View {
var body: some View {
// @Bindable var config = appState
- VStack(alignment: .leading) {
- ScrollView {
- VStack(alignment: .leading) {
- Text(hotline.messageBoard)
- .fontDesign(.monospaced)
+ ScrollView {
+ LazyVStack(alignment: .leading) {
+ ForEach(hotline.messageBoardMessages, id: \.self) {
+ Text($0)
+ .lineLimit(100)
.padding()
- .dynamicTypeSize(.small)
- .textSelection(.enabled)
+ Divider()
}
}
}
- .presentationDetents([.fraction(0.6)])
- .presentationDragIndicator(.visible)
+// List(hotline.messageBoardMessages, id: \.self) {
+// Text($0)
+// .lineLimit(100)
+// .padding()
+// Divider()
+// .listRowSeparator(.hidden)
+// .listRowInsets(EdgeInsets(top: 0, leading: 0, bottom: 0, trailing: 0))
+// }
+// .listStyle(.plain)
.task {
if !fetched {
hotline.sendGetNews() {