|
|
|
@ -3,7 +3,7 @@ import { useState } from 'react';
|
|
|
|
|
import { FileAddOutlined } from '@ant-design/icons';
|
|
|
|
|
import { v4 as uuid } from 'uuid';
|
|
|
|
|
import { API_HOST, OSS_URL as aliOSSHost } from '@/config';
|
|
|
|
|
import { whatsappSupportFileTypes } from '@/channel/whatsappUtils';
|
|
|
|
|
import { whatsappSupportFileTypes, uploadProgressSimulate } from '@/channel/whatsappUtils';
|
|
|
|
|
import { isEmpty, sanitizeFilename } from '@/utils/commons';
|
|
|
|
|
// import useConversationStore from '@/stores/ConversationStore';
|
|
|
|
|
|
|
|
|
@ -40,7 +40,7 @@ const ImageUpload = ({ disabled, invokeUploadFileMessage, invokeSendUploadMessag
|
|
|
|
|
type: fileTypeSupport,
|
|
|
|
|
name: file.name,
|
|
|
|
|
// status: 'loading',
|
|
|
|
|
data: { uri: previewSrc, dataUri: '', link: '', width: '100%', height: 150, loading: 0.01 },
|
|
|
|
|
data: { uri: previewSrc, dataUri: '', link: '', width: '100%', height: 150, loading: uploadProgressSimulate() },
|
|
|
|
|
id: uuid(),
|
|
|
|
|
};
|
|
|
|
|
file.msgData = msgObj;
|
|
|
|
|