Add new settings notification feature flag and update ui entry point

This commit is contained in:
langleyd
2021-06-22 13:39:50 +01:00
parent 795cefaee7
commit 997cf15dd3
7 changed files with 33 additions and 17 deletions

View File

@@ -150,6 +150,9 @@ final class RoomInfoListViewController: UIViewController {
let rowSettings = Row(type: .default, icon: Asset.Images.settingsIcon.image, text: VectorL10n.roomDetailsSettings, accessoryType: .disclosureIndicator) {
self.viewModel.process(viewAction: .navigate(target: .settings()))
}
let roomNotifications = Row(type: .default, icon: Asset.Images.roomActionNotification.image, text: VectorL10n.roomDetailsNotifs, accessoryType: .disclosureIndicator) {
self.viewModel.process(viewAction: .navigate(target: .notifications))
}
let text = viewData.numberOfMembers == 1 ? VectorL10n.roomInfoListOneMember : VectorL10n.roomInfoListSeveralMembers(String(viewData.numberOfMembers))
let rowMembers = Row(type: .default, icon: Asset.Images.userIcon.image, text: text, accessoryType: .disclosureIndicator) {
self.viewModel.process(viewAction: .navigate(target: .members))
@@ -165,8 +168,11 @@ final class RoomInfoListViewController: UIViewController {
}
var rows = [rowSettings]
if (RiotSettings.shared.roomInfoScreenShowIntegrations)
{
if BuildSettings.roomSettingsScreenShowNotificationsV2 {
rows.append(roomNotifications)
}
if RiotSettings.shared.roomInfoScreenShowIntegrations {
rows.append(rowIntegrations)
}
rows.append(rowMembers)