Add "Translate" to TimelineItemMenuActions (#4846)

* Add "Translate" to TimelineItemMenuActions

* Update TimelineView.swift

Co-authored-by: Doug <6060466+pixlwave@users.noreply.github.com>

* Update strings using `download-strings`

* Update ElementX/Sources/Screens/Timeline/View/ItemMenu/TimelineItemMenuAction.swift

Co-authored-by: Doug <6060466+pixlwave@users.noreply.github.com>

* Clear `textToBeTranslated` after translation was dismissed

* `swift run tools download-strings --all-languages`

---------

Co-authored-by: Doug <6060466+pixlwave@users.noreply.github.com>
# Conflicts:
#	ElementX/Resources/Localizations/et.lproj/Localizable.strings
#	ElementX/Resources/Localizations/fr.lproj/Localizable.strings
#	ElementX/Resources/Localizations/hr.lproj/Localizable.strings
This commit is contained in:
Lukas
2026-01-05 14:03:53 +01:00
committed by Doug
parent 784bc04237
commit ec97996a7c
6 changed files with 27 additions and 0 deletions
@@ -498,6 +498,9 @@ class TimelineViewModel: TimelineViewModelType, TimelineViewModelProtocol {
Task { await self.viewInRoomTimeline(eventID: eventID) }
case .displayThread(let itemID):
actionsSubject.send(.displayThread(itemID: itemID))
case .showTranslation(let text):
self.state.bindings.textToBeTranslated = text
self.state.bindings.showTranslation = true
}
}
.store(in: &cancellables)