Move the media caption composer (and Add Caption action) behind a feature flag for now. (#3560)

This commit is contained in:
Doug
2024-11-27 06:30:10 +00:00
committed by GitHub
parent ed4063a222
commit a292c41ca5
15 changed files with 39 additions and 11 deletions
@@ -16,6 +16,7 @@ struct TimelineItemMenuActionProvider {
let pinnedEventIDs: Set<String>
let isDM: Bool
let isViewSourceEnabled: Bool
let isCreateMediaCaptionsEnabled: Bool
let isPinnedEventsTimeline: Bool
let emojiProvider: EmojiProviderProtocol
@@ -68,7 +69,7 @@ struct TimelineItemMenuActionProvider {
if let messageItem = item as? EventBasedMessageTimelineItemProtocol, messageItem.supportsMediaCaption {
if messageItem.hasMediaCaption {
actions.append(contentsOf: [.editCaption, .removeCaption])
} else {
} else if isCreateMediaCaptionsEnabled {
actions.append(.addCaption)
}
} else if !(item is VoiceMessageRoomTimelineItem) {