Commit e54c9b0a by HoMeTown

feat: 参考文档的处理

parent ae1820bb
...@@ -48,7 +48,7 @@ export const ChatAnswerAttachment: React.FC<ChatAnswerAttachmentProps> = ({ from ...@@ -48,7 +48,7 @@ export const ChatAnswerAttachment: React.FC<ChatAnswerAttachmentProps> = ({ from
<div className="bg-[#29B6FD0A] text-[14px] text-primary py-[4px] px-[16px] w-fit flex items-center"> <div className="bg-[#29B6FD0A] text-[14px] text-primary py-[4px] px-[16px] w-fit flex items-center">
<AnswerProDetailIcon /> <AnswerProDetailIcon />
{/* <span className="ml-[6px]">{attachment.name}</span> */} {/* <span className="ml-[6px]">{attachment.name}</span> */}
<div className="ml-[6px] w-[150px] sm:w-full text-nowrap text-ellipsis overflow-hidden"> <div className="ml-[6px] max-w-full sm:w-full text-nowrap text-ellipsis overflow-hidden">
{attachment.name} {attachment.name}
</div> </div>
</div> </div>
...@@ -64,11 +64,11 @@ export const ChatAnswerAttachment: React.FC<ChatAnswerAttachmentProps> = ({ from ...@@ -64,11 +64,11 @@ export const ChatAnswerAttachment: React.FC<ChatAnswerAttachmentProps> = ({ from
</p> </p>
<div className="flex flex-col gap-[9px]"> <div className="flex flex-col gap-[9px]">
{ attachment.content.docList.map((doc, docIdx) => ( { attachment.content.docList.map((doc, docIdx) => (
<Link className="cursor-pointer" onPress={() => handleClickDocLink(doc.docId)} size="sm" key={doc.docId} isExternal showAnchorIcon underline="hover"> <Link className="cursor-pointer" onPress={() => handleClickDocLink(doc.documentName)} size="sm" key={doc.documentName} isExternal showAnchorIcon underline="hover">
{docIdx + 1} {docIdx + 1}
. .
{' '} {' '}
{doc.docName} {doc.documentAlias}
</Link> </Link>
))} ))}
</div> </div>
......
...@@ -54,7 +54,7 @@ export const ChatAnswerBox: React.FC<ChatAnswerBoxProps> = ({ record, showIndex, ...@@ -54,7 +54,7 @@ export const ChatAnswerBox: React.FC<ChatAnswerBoxProps> = ({ record, showIndex,
<div className="flex"> <div className="flex">
<Avatar className="flex-shrink-0" src={AvatarBot} /> <Avatar className="flex-shrink-0" src={AvatarBot} />
<div <div
className="ml-[20px] bg-white rounded-[20px] box-border px-[16px] py-[12px] sm:px-[24px] sm:py-[20px]" className="ml-[12px] sm:ml-[20px] bg-white rounded-[20px] box-border px-[16px] py-[12px] sm:px-[24px] sm:py-[20px]"
> >
{(item.answer?.length || item.cardList?.length) {(item.answer?.length || item.cardList?.length)
? ( ? (
......
...@@ -9,11 +9,11 @@ export const ChatWelcome: React.FC = () => { ...@@ -9,11 +9,11 @@ export const ChatWelcome: React.FC = () => {
<div className="flex"> <div className="flex">
<Avatar className="flex-shrink-0" src={AvatarBot} /> <Avatar className="flex-shrink-0" src={AvatarBot} />
<motion.div <motion.div
className="ml-[20px] bg-white rounded-[20px] box-border px-[16px] py-[12px] sm:px-[24px] sm:py-[20px]" className="ml-[12px] sm:ml-[20px] bg-white rounded-[20px] box-border px-[16px] py-[12px] sm:px-[24px] sm:py-[20px]"
> >
<div className="content"> <div className="content">
<p className="text-[16px] sm:text-[18px] font-medium text-[#333]">您好,我是晓得</p> <p className="text-[16px] sm:text-[18px] font-medium text-[#333]">您好,我是晓得</p>
<p className="text-[15px] mt-[8px] sm:text-13px text-[#27353C] font-300">作为您的智能保险伙伴,您有各类专业相关的问题都可以抛给我哟~让我们互相帮助共同成长吧~</p> <p className="text-[15px] sm:mt-[8px] sm:text-13px text-[#27353C] font-300">作为您的智能保险伙伴,您有各类专业相关的问题都可以抛给我哟~让我们互相帮助共同成长吧~</p>
</div> </div>
</motion.div> </motion.div>
</div> </div>
......
...@@ -55,7 +55,7 @@ export const Home: React.FC = () => { ...@@ -55,7 +55,7 @@ export const Home: React.FC = () => {
<div className="box flex flex-col h-full w-full"> <div className="box flex flex-col h-full w-full">
<div className="flex-1 sm:flex items-center pt-[24px] overflow-y-scroll sm:pt-[32px] scrollbar-hide sm:overflow-hidden"> <div className="flex-1 sm:flex items-center pt-[24px] overflow-y-scroll sm:pt-[32px] scrollbar-hide sm:overflow-hidden">
<div className="w-full"> <div className="w-full">
<div className="px-[12px] pb-[24px] sm:px-0"> <div className="px-[22px] pb-[24px] sm:px-0">
{/* slogan */} {/* slogan */}
<Slogan /> <Slogan />
......
interface AttachmentContentDoc { interface AttachmentContentDoc {
docId: string knowledgeName: string
docName: string collectionName: string
documentName: string
documentAlias: string
documentStoreKey: string
} }
interface AttachmentContentProduct { interface AttachmentContentProduct {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment