@sendbird/uikit-react
Advanced tools
Changelog
[v3.14.3] (Apr 19, 2024)
<SendbirdProvider
...
imageCompression={{
outputFormat: 'preserve' | 'png' | 'jpeg',
}}
>
</SendbirdProvider>
12px
in the mobile modeChangelog
[v3.14.2] (Apr 18, 2024)
Changelog
[v3.14.1] (Apr 12, 2024)
renderMessage
in the OpenChannel
modulerenderMessageInput
propChangelog
[v3.14.0] (Apr 5, 2024)
TemplateMessageItemBody
now supports CarouselView
type templateMessageContent
when value exists in message.extendedMessagePayload['ui']['container_type']
TemplateMessageItemBody
borderRadius
, backgroundColor
, and color
for message template itemsChangelog
[v3.13.5] (Apr 5, 2024)
Changelog
[v3.13.4] (Mar 27, 2024)
Emoji Reactions
feature in the super group channel
Tooltip
displaying who reacted will only appear in the normal group channel, not in the super group channel.MessageFeedbackFailedModal
component for consistency with other message feedback-related components.Changelog
[v3.13.3] (Mar 22, 2024)
renderMenuItem
to the MessageMenu
component
<GroupChannel
renderMessageContent={(props) => (
<MessageContent
{...props}
renderMessageMenu={(props) => (
<MessageMenu
{...props}
renderMenuItem={(props) => {
const {
className,
onClick,
dataSbId,
disable,
text,
} = props;
return <MenuItem /> // Render Custom Menu Item
}}
/>
)}
/>
)}
/>
onBeforeDownloadFileMessage
to the <GroupChannel />
and <Thread />
modules
const ONE_MB = 1024 * 1024;
/**
* Use this list to check if it's displayed as a ThumbnailMessage.
* (https://github.com/sendbird/sendbird-uikit-react/blob/main/src/utils/index.ts)
*/
const ThumbnailMessageTypes = [
'image/jpeg',
'image/jpg',
'image/png',
'image/gif',
'image/svg+xml',
'image/webp', // not supported in IE
'video/mpeg',
'video/ogg',
'video/webm',
'video/mp4',
];
<GroupChannel // or Thread
onBeforeDownloadFileMessage={async ({ message, index = null }) => {
if (message.isFileMessage()) {
const confirmed = window.confirm(`The file size is ${(message.size / ONE_MB).toFixed(2)}MB. Would you like to continue downloading?`);
return confirmed;
}
if (message.isMultipleFilesMessage()) {
const confirmed = window.confirm(`The file size is ${(message.fileInfoList[index].fileSize / ONE_MB).toFixed(2)}MB. Would you like to continue downloading?`);
return confirmed;
}
return true;
}}
/>
onDownloadClick
to the FileViewer
, FileViewerView
, MobileBottomSheet
, MobileContextMenu
, and MobileMenu
MembersModal
, MutedMembersModal
, and OperatorsModal
Operator
description on the MembersModal
width
size of the OGMessageItemBody
component (You)
with the StringSet CHANNEL_SETTING__MEMBERS__YOU
in the UserListItem