From 9503a4d4ab7ec75cb9c7d805656ce1f5c720346b Mon Sep 17 00:00:00 2001 From: Lumaa Date: Thu, 8 Feb 2024 08:33:20 +0100 Subject: [PATCH] display attachment count --- Threaded/Components/NotificationRow.swift | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/Threaded/Components/NotificationRow.swift b/Threaded/Components/NotificationRow.swift index 4edb6e2..fe0c0fc 100644 --- a/Threaded/Components/NotificationRow.swift +++ b/Threaded/Components/NotificationRow.swift @@ -33,6 +33,14 @@ struct NotificationRow: View { .font(.caption) .foregroundStyle(Color.gray) .lineLimit(3, reservesSpace: true) + + if notif.status!.mediaAttachments.count > 0 { + Label("activity.status.attachments-\(notif.status!.mediaAttachments.count)", systemImage: "photo.on.rectangle.angled") + .multilineTextAlignment(.leading) + .font(.caption) + .foregroundStyle(Color.gray) + .lineLimit(1, reservesSpace: false) + } } else { TextEmoji(notif.account.note, emojis: notif.account.emojis) .multilineTextAlignment(.leading) @@ -77,7 +85,7 @@ struct NotificationRow: View { case .mention: return Color.blue case .reblog: - return Color.pink + return Color.orange case .status: return Color.yellow default: