change: hiding timeline media has three options

This commit is contained in:
Mauro Romito
2025-04-09 17:03:47 +02:00
committed by Mauro
parent fe9cb2e2f0
commit bf875a23ce
5 changed files with 56 additions and 10 deletions
+3 -1
View File
@@ -106,7 +106,9 @@ struct NotificationContentBuilder {
let displayName = notificationItem.senderDisplayName ?? notificationItem.roomDisplayName
notification.body = String(messageEventStringBuilder.buildAttributedString(for: messageType, senderDisplayName: displayName).characters)
guard !settings.hideTimelineMedia else { return notification }
// For now we are fine hiding all images if the visibility is not `always` while we wait for an `isPublic` flag
// to be implemented in the SDK.
guard settings.timelineMediaVisibility == .always else { return notification }
switch messageType {
case .image(content: let content):