CometChatBannedMembers
is a Component that displays all the users who have been restricted or prohibited from participating in specific groups or conversations. When the user is banned, they are no longer able to access or engage with the content and discussions within the banned group. Group administrators or owners have the authority to ban members from specific groups they manage. They can review user activity, monitor behavior, and take appropriate actions, including banning users when necessary.
onSelection
action is activated when you select the done icon while in selection mode. This returns a list of all the banned members that you have selected.
This action does not come with any predefined behavior. However, you have the flexibility to override this event and tailor it to suit your needs using the following code snippet.
onItemPress
event is activated when you click on the Banned Members List item. This action does not come with any predefined behavior. However, you have the flexibility to override this event and tailor it to suit your needs using the following code snippet.
onItemLongPress
event is activated when you Long Press on the Banned Members List item. This action does not come with any predefined behavior. However, you have the flexibility to override this event and tailor it to suit your needs using the following code snippet.
OnBack
is triggered when you click on the back button of the Banned Members component. You can override this action using the following code snippet.
Methods | Type | Description |
---|---|---|
setLimit | number | sets the number of banned members that can be fetched in a single request, suitable for pagination |
setSearchKeyword | String | used for fetching banned members matching the passed string |
setScopes | Array<String> | used for fetching banned members based on multiple scopes |
Component
. By using event you can extend existing functionality. Being global events, they can be applied in Multiple Locations and are capable of being Added or Removed.
Events emitted by the Add Members component is as follows.
Event | Description |
---|---|
ccGroupMemberUnBanned | Triggers when a user is unbanned from a group |
BannedMembersStyle
to the Banned Members Component to customize the styling.
Property | Description | Code |
---|---|---|
border | Used to set border | border?: BorderStyleInterface, |
borderRadius | Used to set border radius | borderRadius?: number; |
background | Used to set background colour | background?: string; |
height | Used to set height | height?: string | number ; |
width | Used to set width | width?: string | number ; |
titleFont | Used to set title text font | titleFont?: FontStyleInterface, |
titleColor | Used to set title text color | titleColor?: string; |
backIconTint | Used to set back button icon tint | backIconTint?: string; |
searchIconTint | Used to set search icon tint | searchIconTint?: string; |
searchBorder | Used to set search border | searchBorder?: BorderStyleInterface; |
searchBorderRadius | Used to set search border radius | searchBorderRadius?: number; |
searchBackground | Used to set search background color | searchBackground?: string; |
searchTextFont | Used to set search text font | searchTextFont?: FontStyleInterface; |
searchTextColor | Used to set search text color | searchTextColor?: string; |
onlineStatusColor | Used to set online status color | onlineStatusColor?: string; |
loadingIconTint | Used to set loading icon tint | loadingIconTint?: string; |
separatorColor | Used to set separator color | separatorColor?: string; |
emptyTextColor | Used to set empty state text color | emptyTextColor?: string; |
emptyStateTextFont | Used to set empty state text font | emptyStateTextFont?: FontStyleInterface; |
errorTextFont | Used to set error state text font | errorStateTextFont?: FontStyleInterface; |
errorTextColor | Used to set error state text color | errorStateTextColor?: string; |
sectionHeaderTextFont | Used to set section header text font | sectionHeaderTextFont?: FontStyleInterface; |
sectionHeaderTextColor | Used to set section header text color | sectionHeaderTextColor?: string; |
Avatar
component in the Add Members Component, you can use the following code snippet. For further insights on Avatar
Styles refer
ListItemStyle
component in the Add Members
Component, you can use the following code snippet. For further insights on ListItemStyle
Styles refer
Property | Description | Code |
---|---|---|
title | Used to set title in the app bar | title?: string; |
searchPlaceholderText | Used to set search placeholder text | searchPlaceholderText?: string; |
backButtonIcon | Used to set back button icon | backButtonIcon?: ImageURISource |
showBackButton | Used to toggle visibility for back button | showBackButton?: boolean |
searchBoxIcon | Used to set search Icon in the search field | searchBoxIcon?: ImageURISource |
hideSearch | Used to toggle visibility for search box | hideSearch?: boolean |
hideError | Used to hide error on fetching users | hideError?: boolean |
hideSeparator | Used to hide the divider separating the user items | hideSeparator?: boolean |
disableUsersPresence | Used to control visibility of user indicator shown if user is online | disableUsersPresence?: boolean |
selectionIcon | Used to override the default selection complete icon | selectionIcon?: ImageURISource |
emptyStateText | Used to set a custom text response when fetching the users has returned an empty list | emptyStateText?: string |
errorStateText | Used to set a custom text response when some error occurs on fetching the list of users | errorStateText?: string |
group | Used to pass group object of which group members will be shown | group={chatGroup} |
LoadingStateView
to match the loading view of your app.
EmptyStateView
using EmptyStateView
to match the empty view of your app.