|
|
|
@ -75,7 +75,13 @@ const MessagesList = ({ messages, handlePreview, reference, longListLoading, get
|
|
|
|
|
<div ref={reference} className='relative overflow-y-auto overflow-x-hidden block flex-1'>
|
|
|
|
|
{loadNextPage && messages.length > 0 && (
|
|
|
|
|
<div className='text-center pt-3 mb-3 h-8 leading-8 '>
|
|
|
|
|
{!longListLoading ? <Button onClick={onLoadMore} type={'dashed'}>loading more</Button> : <LoadingOutlined className='text-primary' />}
|
|
|
|
|
{!longListLoading ? (
|
|
|
|
|
<Button onClick={onLoadMore} type={'dashed'}>
|
|
|
|
|
loading more
|
|
|
|
|
</Button>
|
|
|
|
|
) : (
|
|
|
|
|
<LoadingOutlined className='text-primary' />
|
|
|
|
|
)}
|
|
|
|
|
</div>
|
|
|
|
|
)}
|
|
|
|
|
{messages.map((message, index) => (
|
|
|
|
@ -103,10 +109,14 @@ const MessagesList = ({ messages, handlePreview, reference, longListLoading, get
|
|
|
|
|
{...(message.type === 'meetingLink'
|
|
|
|
|
? {
|
|
|
|
|
actionButtons: [
|
|
|
|
|
...(message.waBtn
|
|
|
|
|
? [
|
|
|
|
|
{
|
|
|
|
|
onClickButton: () => handleContactClick(message.data),
|
|
|
|
|
Component: () => <div>发消息</div>,
|
|
|
|
|
},
|
|
|
|
|
]
|
|
|
|
|
: []),
|
|
|
|
|
{
|
|
|
|
|
onClickButton: () => {
|
|
|
|
|
navigator.clipboard.writeText(message.text);
|
|
|
|
|