mirror of
https://github.com/Novaloop-AG/element-x-ios.git
synced 2026-10-31 16:24:11 +00:00
Space tweaks. (#5068)
This commit is contained in:
+4
-1
@@ -49,7 +49,10 @@ class SpaceAddRoomsScreenViewModel: SpaceAddRoomsScreenViewModelType, SpaceAddRo
|
||||
let existingRooms = spaceRoomListProxy.spaceRoomsPublisher.value
|
||||
suggestedRooms = await userSession.clientProxy
|
||||
.recentlyVisitedRooms { roomProxy in
|
||||
!roomProxy.infoPublisher.value.isDirect && !existingRooms.contains { $0.id == roomProxy.id }
|
||||
!roomProxy.infoPublisher.value.isDirect
|
||||
&& !roomProxy.infoPublisher.value.isSpace
|
||||
&& roomProxy.infoPublisher.value.membership == .joined
|
||||
&& !existingRooms.contains { $0.id == roomProxy.id }
|
||||
}
|
||||
.map { .init(roomProxy: $0) }
|
||||
|
||||
|
||||
@@ -138,8 +138,10 @@ struct SpaceScreen: View {
|
||||
}
|
||||
.accessibilityIdentifier(A11yIdentifiers.spaceScreen.addExistingRooms)
|
||||
|
||||
Button { context.send(viewAction: .manageChildren) } label: {
|
||||
Label(L10n.actionManageRooms, icon: \.edit)
|
||||
if context.viewState.rooms.count > 0 {
|
||||
Button { context.send(viewAction: .manageChildren) } label: {
|
||||
Label(L10n.actionManageRooms, icon: \.edit)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user