mirror of
https://github.com/Novaloop-AG/element-x-ios.git
synced 2026-11-03 06:55:59 +00:00
Add voice message analytics
This commit is contained in:
committed by
Alfonso Grillo
parent
530985e674
commit
4985d410b3
@@ -1001,6 +1001,12 @@ class RoomScreenViewModel: RoomScreenViewModelType, RoomScreenViewModelProtocol
|
||||
displayError(.alert(L10n.errorFailedUploadingVoiceMessage))
|
||||
return
|
||||
}
|
||||
|
||||
analytics.trackComposer(inThread: false,
|
||||
isEditing: false,
|
||||
isReply: false,
|
||||
messageType: .voiceMessage,
|
||||
startsThread: nil)
|
||||
|
||||
actionsSubject.send(.composer(action: .setMode(mode: .previewVoiceMessage(state: audioPlayerState, waveform: .url(recordingURL), isUploading: true))))
|
||||
await voiceMessageRecorder.stopPlayback()
|
||||
|
||||
@@ -20,6 +20,7 @@ enum AnalyticsMessageType {
|
||||
case location(LocationType)
|
||||
case poll
|
||||
case text
|
||||
case voiceMessage
|
||||
|
||||
enum LocationType {
|
||||
case pin
|
||||
@@ -36,6 +37,8 @@ extension AnalyticsEvent.Composer.MessageType {
|
||||
self = .Poll
|
||||
case .text:
|
||||
self = .Text
|
||||
case .voiceMessage:
|
||||
self = .VoiceMessage
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user