show avatar dialog instead of default (#4033)

show avatar dialog instead of default

- [x] New Feature (non-breaking change which adds functionality)

---------

Co-authored-by: Kevin Hu <kevinhu.sh@gmail.com>
This commit is contained in:
so95
2024-12-17 16:29:35 +07:00
committed by GitHub
parent 09436f6c60
commit 251592eeeb
14 changed files with 159 additions and 12 deletions

View File

@ -9,6 +9,7 @@ import { useSendNextMessage } from './hooks';
import PdfDrawer from '@/components/pdf-drawer';
import { useClickDrawer } from '@/components/pdf-drawer/hooks';
import { useFetchFlow } from '@/hooks/flow-hooks';
import { useFetchUserInfo } from '@/hooks/user-setting-hooks';
import styles from './index.less';
@ -29,6 +30,7 @@ const FlowChatBox = () => {
useGetFileIcon();
const { t } = useTranslate('chat');
const { data: userInfo } = useFetchUserInfo();
const { data: cavasInfo } = useFetchFlow();
return (
<>
@ -47,6 +49,7 @@ const FlowChatBox = () => {
key={message.id}
nickname={userInfo.nickname}
avatar={userInfo.avatar}
avatardialog={cavasInfo.avatar}
item={message}
reference={buildMessageItemReference(
{ message: derivedMessages, reference },