[v3.3.1] (Nov 23 2022)
Fixes:
- Rename properties of
useThreadContext
channelStatus
tochannelState
parentMessageInfoStatus
toparentMessageState
threadListStatus
tothreadListState
- Change the state types to enum
enum ChannelStateTypes { NIL = 'NIL', LOADING = 'LOADING', INVALID = 'INVALID', INITIALIZED = 'INITIALIZED', } enum ParentMessageStateTypes { NIL = 'NIL', LOADING = 'LOADING', INVALID = 'INVALID', INITIALIZED = 'INITIALIZED', } enum ThreadListStateTypes { NIL = 'NIL', LOADING = 'LOADING', INVALID = 'INVALID', INITIALIZED = 'INITIALIZED', }
[v3.3.0] (Nov 23 2022)
Features:
- Provide new module
Thread
. See the specific informations of this module on the Docs page- You can use a combined component
Thread
. Import it withimport Thread from "@sendbird/uikit-react/Thread"
- Also you can use
ThreadProvider
anduseThreadContext
for customization. Import it withimport { ThreadProvider, useThreadContext } from "@sendbird/uikit-react/Thread/context"
- And the other UI components are provided under the Thread.
ThreadUI
,ThreadHeader
,ParentMessageInfo
,ParentMessageInfoItem
,ThreadList
,ThreadListItem
, andThreadMessageInput
are it
- You can use a combined component
- Add channel props
threadReplySelectType
: Type of the value should beYou can see how to use it belowenum ThreadReplySelectType { PARENT, THREAD }
import { ThreadReplySelectType } from "@sendbird/uikit-react/Channel/context"; <Channel ... threadReplySelectType={ThreadReplySelectType.PARENT} />
animatedMessage
: Type of the value should be number(messageId)onReplyInThread
: This function is called when user click the button "Reply in thread" on the message context menutype onReplyInThread = ({ message: UserMessage | FileMessage }) => void
onQuoteMessageClick
: This function is called when user click the quote message on the message of Channeltype onQuoteMessageClick = ({ message: UserMessage | FileMessage }) => {}
onMessageAnimated
: This function is called after that message item is animatedtype onMessageAnimated = () => void
onMessageHighlighted
: This function is called after that message item is highlightedtype onMessageHighlighted = () => void
- Add
ui/ThreadReplies
componentinterface ThreadRepliesProps { className?: string; threadInfo: ThreadInfo; onClick?: (e: React.MouseEvent<HTMLElement> | React.KeyboardEvent<HTMLElement>) => void; }
Fixes:
- Do not allow operator to unregister itself on the OperatorList of GroupChannel
- Create new group channel when user open 1:1 channel on the UserProfile
- Register the channel creator as an operator in 1:1 channel