diff --git a/packages/uikit-react-native/src/domain/openChannelMutedParticipants/types.ts b/packages/uikit-react-native/src/domain/openChannelMutedParticipants/types.ts index 82dc44b87..df1f8e808 100644 --- a/packages/uikit-react-native/src/domain/openChannelMutedParticipants/types.ts +++ b/packages/uikit-react-native/src/domain/openChannelMutedParticipants/types.ts @@ -1,5 +1,6 @@ import type React from 'react'; +import type { UseUserListOptions } from '@sendbird/uikit-chat-hooks'; import type { SendbirdOpenChannel, SendbirdRestrictedUser } from '@sendbird/uikit-utils'; import type { CommonComponent } from '../../types'; @@ -9,6 +10,7 @@ export type OpenChannelMutedParticipantsProps = { channel: SendbirdOpenChannel; onPressHeaderLeft: OpenChannelMutedParticipantsProps['Header']['onPressHeaderLeft']; renderUser?: OpenChannelMutedParticipantsProps['List']['renderUser']; + queryCreator?: UseUserListOptions['queryCreator']; }; Header: { onPressHeaderLeft: () => void; diff --git a/packages/uikit-react-native/src/fragments/createOpenChannelMutedParticipantsFragment.tsx b/packages/uikit-react-native/src/fragments/createOpenChannelMutedParticipantsFragment.tsx index 3748751b9..d96adc288 100644 --- a/packages/uikit-react-native/src/fragments/createOpenChannelMutedParticipantsFragment.tsx +++ b/packages/uikit-react-native/src/fragments/createOpenChannelMutedParticipantsFragment.tsx @@ -18,7 +18,7 @@ const createOpenChannelMutedParticipantsFragment = ( ): OpenChannelMutedParticipantsFragment => { const OpenChannelMutedParticipantsModule = createOpenChannelMutedParticipantsModule(initModule); - return ({ onPressHeaderLeft = NOOP, channel, renderUser }) => { + return ({ onPressHeaderLeft = NOOP, channel, renderUser, queryCreator }) => { const handlerId = useUniqHandlerId('OpenChannelMutedParticipants'); const { STRINGS } = useLocalization(); @@ -26,7 +26,7 @@ const createOpenChannelMutedParticipantsFragment = ( const { openMenu } = useActionMenu(); const { users, deleteUser, upsertUser, loading, refresh, error, next } = useUserList(sdk, { - queryCreator: () => channel.createMutedUserListQuery({ limit: 20 }), + queryCreator: queryCreator ?? (() => channel.createMutedUserListQuery({ limit: 20 })), }); useChannelHandler(