Updates to File Info Bottom Sheet (#5667)

* Updates to File Info Bottom Sheet

Removing buttons, changing labels, adding a title

* Update the underlying actions rather than fixing it at the screen-level.

* Fix the media details sheet height now there's a navigation title.

* Record preview snapshots

---------

Co-authored-by: Doug <douglase@element.io>
Co-authored-by: Element CI <ci@element.io>
This commit is contained in:
Aaron Thornburgh
2026-06-01 15:00:55 +02:00
committed by GitHub
parent a3f78c9005
commit dc7454d161
23 changed files with 66 additions and 75 deletions
@@ -65,7 +65,7 @@ enum TimelineItemMenuAction: Identifiable, Hashable {
case removeCaption
case editPoll
case copyPermalink
case redact
case redact(isMedia: Bool)
case reply(isThread: Bool)
case replyInThread
case forward(itemID: TimelineItemIdentifier)
@@ -77,8 +77,7 @@ enum TimelineItemMenuAction: Identifiable, Hashable {
case pin
case unpin
case viewInRoomTimeline
case share
case save
case downloadMedia
var id: Self {
self
@@ -135,7 +134,7 @@ enum TimelineItemMenuAction: Identifiable, Hashable {
var canAppearInMediaDetails: Bool {
switch self {
case .viewInRoomTimeline, .share, .save, .redact, .forward:
case .viewInRoomTimeline, .downloadMedia, .redact, .forward:
true
default:
false
@@ -171,8 +170,8 @@ enum TimelineItemMenuAction: Identifiable, Hashable {
Label(L10n.actionReplyInThread, icon: \.threads)
case .forward:
Label(L10n.actionForward, icon: \.forward)
case .redact:
Label(L10n.actionRemoveMessage, icon: \.delete)
case .redact(let isMedia):
Label(isMedia ? L10n.actionDeleteFile : L10n.actionRemoveMessage, icon: \.delete)
case .viewSource:
Label(L10n.actionViewSource, icon: \.code)
case .report:
@@ -190,10 +189,8 @@ enum TimelineItemMenuAction: Identifiable, Hashable {
Label(L10n.actionUnpin, icon: \.unpin)
case .viewInRoomTimeline:
Label(L10n.actionViewInTimeline, icon: \.visibilityOn)
case .share:
Label(L10n.actionShare, icon: \.shareIos)
case .save:
Label(L10n.actionSave, icon: \.downloadIos)
case .downloadMedia:
Label(L10n.actionDownload, icon: \.downloadIos)
}
}
}