Add translations, footer message and room encryption handling

This commit is contained in:
langleyd
2021-07-02 10:15:35 +01:00
parent 7453fa68bb
commit c60093a4ee
7 changed files with 105 additions and 20 deletions
@@ -20,11 +20,21 @@ import Foundation
/// RoomNotificationSettingsViewController view state
struct RoomNotificationSettingsViewStateImpl: RoomNotificationSettingsViewState {
let roomEncrypted: Bool
var saving: Bool
var notificationState: RoomNotificationState
var notificationOptions: [RoomNotificationState] {
if roomEncrypted {
return [.all, .mute]
} else {
return RoomNotificationState.allCases
}
}
}
protocol RoomNotificationSettingsViewState {
var saving: Bool { get }
var roomEncrypted: Bool { get }
var notificationOptions: [RoomNotificationState] { get }
var notificationState: RoomNotificationState { get }
}