Remove avatar from chat messages
This commit is contained in:
parent
8d9182eb44
commit
f2e7cf4e5c
1 changed files with 8 additions and 11 deletions
|
@ -311,8 +311,8 @@ const ChatMessageList: React.FC<IChatMessageList> = ({ chat }) => {
|
||||||
className={
|
className={
|
||||||
classNames({
|
classNames({
|
||||||
'text-ellipsis break-all relative rounded-md p-2 max-w-full': true,
|
'text-ellipsis break-all relative rounded-md p-2 max-w-full': true,
|
||||||
'bg-primary-500 text-white mr-2': isMyMessage,
|
'bg-primary-500 text-white': isMyMessage,
|
||||||
'bg-gray-200 dark:bg-gray-800 text-gray-900 dark:text-gray-100 order-2 ml-2': !isMyMessage,
|
'bg-gray-200 dark:bg-gray-800 text-gray-900 dark:text-gray-100': !isMyMessage,
|
||||||
'!bg-transparent !p-0 emoji-lg': isOnlyEmoji,
|
'!bg-transparent !p-0 emoji-lg': isOnlyEmoji,
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
@ -320,11 +320,12 @@ const ChatMessageList: React.FC<IChatMessageList> = ({ chat }) => {
|
||||||
tabIndex={0}
|
tabIndex={0}
|
||||||
>
|
>
|
||||||
{maybeRenderMedia(chatMessage)}
|
{maybeRenderMedia(chatMessage)}
|
||||||
<Text size='sm' theme='inherit' className='break-word-nested' dangerouslySetInnerHTML={{ __html: content }} />
|
<Text
|
||||||
</div>
|
size='sm'
|
||||||
|
theme='inherit'
|
||||||
<div className={classNames({ 'order-1': !isMyMessage })}>
|
className='break-word-nested'
|
||||||
<Avatar src={isMyMessage ? account?.avatar as string : chat.account.avatar as string} size={34} />
|
dangerouslySetInnerHTML={{ __html: content }}
|
||||||
|
/>
|
||||||
</div>
|
</div>
|
||||||
</HStack>
|
</HStack>
|
||||||
</HStack>
|
</HStack>
|
||||||
|
@ -365,10 +366,6 @@ const ChatMessageList: React.FC<IChatMessageList> = ({ chat }) => {
|
||||||
) : null}
|
) : null}
|
||||||
</span>
|
</span>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div className={classNames({ 'order-1': !isMyMessage })}>
|
|
||||||
<div className='w-[34px]' />
|
|
||||||
</div>
|
|
||||||
</HStack>
|
</HStack>
|
||||||
</Stack>
|
</Stack>
|
||||||
</div>
|
</div>
|
||||||
|
|
Loading…
Reference in a new issue