index.tsx
600 Bytes
import React from 'react';
import {getOr} from 'lodash/fp';
import FileAttachments from '../FileAttachments';
import ThreadContent from '../../../../../models/ThreadContent';
import {fileAttachments} from '../../../../../helpers/threadContent';
interface Props {
threadContent: ThreadContent;
}
const Text = ({threadContent}: Props) => {
return (
<div className='talktext'>
<p dangerouslySetInnerHTML={{__html: getOr('', 'contentInstance.contentText', threadContent)}}/>
<FileAttachments attachments={fileAttachments(threadContent)} />
</div>
);
};
export default Text;