diff options
| author | Dhravya <[email protected]> | 2024-05-21 22:47:33 -0500 |
|---|---|---|
| committer | Dhravya <[email protected]> | 2024-05-21 22:47:33 -0500 |
| commit | a4f566aaa085ce2a871f12070f932fa7da557316 (patch) | |
| tree | e8ff7e3eb0a27ef47300f261975afdefae093b32 /apps/web/src/components/ChatMessage.tsx | |
| parent | footer fix: Arrow color should be consistent, no need for stroke (diff) | |
| download | supermemory-a4f566aaa085ce2a871f12070f932fa7da557316.tar.xz supermemory-a4f566aaa085ce2a871f12070f932fa7da557316.zip | |
format documents
Diffstat (limited to 'apps/web/src/components/ChatMessage.tsx')
| -rw-r--r-- | apps/web/src/components/ChatMessage.tsx | 40 |
1 files changed, 20 insertions, 20 deletions
diff --git a/apps/web/src/components/ChatMessage.tsx b/apps/web/src/components/ChatMessage.tsx index 0ab22271..58ef9870 100644 --- a/apps/web/src/components/ChatMessage.tsx +++ b/apps/web/src/components/ChatMessage.tsx @@ -12,7 +12,7 @@ export function ChatAnswer({ loading = false, }: { children: string; - sources?: ChatHistory['answer']['sources']; + sources?: ChatHistory["answer"]["sources"]; loading?: boolean; }) { return ( @@ -30,25 +30,25 @@ export function ChatAnswer({ <SpaceIcon className="h-6 w-6 -translate-y-[2px]" /> Related Memories </h1> - <div className="animate-fade-in gap-1 -mt-3 flex items-center justify-start opacity-0 [animation-duration:1s]"> - {sources?.map((source) => source.isNote ? ( - <button - className="bg-rgray-3 flex items-center justify-center gap-2 rounded-full py-1 pl-2 pr-3 text-sm" - > - <Text className="w-4 h-4" /> - {source.source} - </button> - ) : ( - <a - className="bg-rgray-3 flex items-center justify-center gap-2 rounded-full py-1 pl-2 pr-3 text-sm" - key={source.source} - href={source.source} - target="_blank" - > - <Globe className="h-4 w-4" /> - {cleanUrl(source.source)} - </a> - ))} + <div className="animate-fade-in -mt-3 flex items-center justify-start gap-1 opacity-0 [animation-duration:1s]"> + {sources?.map((source) => + source.isNote ? ( + <button className="bg-rgray-3 flex items-center justify-center gap-2 rounded-full py-1 pl-2 pr-3 text-sm"> + <Text className="h-4 w-4" /> + {source.source} + </button> + ) : ( + <a + className="bg-rgray-3 flex items-center justify-center gap-2 rounded-full py-1 pl-2 pr-3 text-sm" + key={source.source} + href={source.source} + target="_blank" + > + <Globe className="h-4 w-4" /> + {cleanUrl(source.source)} + </a> + ), + )} </div> </> )} |