mirror of
https://github.com/Novaloop-AG/element-x-ios.git
synced 2026-11-02 21:33:26 +00:00
Use Compound List in more screens. (#2099)
* Use Compound List in room member details, secure backup, notification settings. * Use ListRow in CreateRoomScreen. * Fix ListRow layout when isWaiting && !isSelected.
This commit is contained in:
-1
@@ -63,7 +63,6 @@ struct NotificationSettingsEditScreen: View {
|
||||
Text(L10n.screenNotificationSettingsEditCustomSettingsSectionTitle)
|
||||
.compoundListSectionHeader()
|
||||
}
|
||||
.compoundFormSection()
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
+1
-1
@@ -50,7 +50,7 @@ struct NotificationSettingsEditScreenRoomCell: View {
|
||||
}
|
||||
|
||||
@MainActor
|
||||
var roomDetailsLabel: ListDetailsLabel<EmptyView>? {
|
||||
var roomDetailsLabel: ListRowDetails<EmptyView>? {
|
||||
guard let mode = room.notificationMode else { return nil }
|
||||
return .label(title: context.viewState.strings.string(for: mode),
|
||||
icon: EmptyView())
|
||||
|
||||
+2
-2
@@ -98,7 +98,7 @@ struct NotificationSettingsScreen: View {
|
||||
// Group chats
|
||||
ListRow(label: .plain(title: L10n.screenNotificationSettingsGroupChats),
|
||||
details: context.viewState.settings.map {
|
||||
ListDetailsLabel.title(context.viewState.strings.string(for: $0.groupChatsMode))
|
||||
.title(context.viewState.strings.string(for: $0.groupChatsMode))
|
||||
} ?? .isWaiting(true),
|
||||
kind: .navigationLink {
|
||||
context.send(viewAction: .groupChatsTapped)
|
||||
@@ -109,7 +109,7 @@ struct NotificationSettingsScreen: View {
|
||||
// Direct chats
|
||||
ListRow(label: .plain(title: L10n.screenNotificationSettingsDirectChats),
|
||||
details: context.viewState.settings.map {
|
||||
ListDetailsLabel.title(context.viewState.strings.string(for: $0.directChatsMode))
|
||||
.title(context.viewState.strings.string(for: $0.directChatsMode))
|
||||
} ?? .isWaiting(true),
|
||||
kind: .navigationLink {
|
||||
context.send(viewAction: .directChatsTapped)
|
||||
|
||||
@@ -71,9 +71,7 @@ struct SettingsScreen: View {
|
||||
|
||||
Spacer()
|
||||
|
||||
CompoundIcon(\.chevronRight)
|
||||
.foregroundColor(.compound.iconTertiaryAlpha)
|
||||
.flipsForRightToLeftLayoutDirection(true)
|
||||
ListRowAccessory.navigationLink
|
||||
}
|
||||
.padding(.horizontal, ListRowPadding.horizontal)
|
||||
.padding(.vertical, 8)
|
||||
|
||||
Reference in New Issue
Block a user