mirror of
https://github.com/Novaloop-AG/element-x-ios.git
synced 2026-11-04 10:33:45 +00:00
Knock Requests List Screen (#3533)
* created the basic navigation and files * updated the logic so that the buttons that do not have permissions won't show * added the empty state * progress in making the list UI * update tests * UI improvements * fixed an issue with media provider * update button style * fixed a navigation bug * pr suggestions * pr suggestions
This commit is contained in:
@@ -22,6 +22,7 @@ enum RoomDetailsScreenViewModelAction {
|
||||
case requestRolesAndPermissionsPresentation
|
||||
case startCall
|
||||
case displayPinnedEventsTimeline
|
||||
case displayKnockingRequests
|
||||
}
|
||||
|
||||
// MARK: View
|
||||
@@ -42,9 +43,16 @@ struct RoomDetailsScreenViewState: BindableState {
|
||||
var canEditRoomTopic = false
|
||||
var canEditRoomAvatar = false
|
||||
var canEditRolesOrPermissions = false
|
||||
var canKickUsers = false
|
||||
var canBanUsers = false
|
||||
var notificationSettingsState: RoomDetailsNotificationSettingsState = .loading
|
||||
var canJoinCall = false
|
||||
var pinnedEventsActionState = RoomDetailsScreenPinnedEventsActionState.loading
|
||||
var knockingEnabled = false
|
||||
|
||||
var canSeeKnockingRequests: Bool {
|
||||
knockingEnabled && dmRecipient == nil && (canInviteUsers || canKickUsers || canBanUsers)
|
||||
}
|
||||
|
||||
var canEdit: Bool {
|
||||
!isDirect && (canEditRoomName || canEditRoomTopic || canEditRoomAvatar)
|
||||
@@ -188,6 +196,7 @@ enum RoomDetailsScreenViewAction {
|
||||
case processTapRolesAndPermissions
|
||||
case processTapCall
|
||||
case processTapPinnedEvents
|
||||
case processTapRequestsToJoin
|
||||
}
|
||||
|
||||
enum RoomDetailsScreenViewShortcut {
|
||||
|
||||
Reference in New Issue
Block a user