diff --git a/src/interface/web/app/components/referencePanel/referencePanel.tsx b/src/interface/web/app/components/referencePanel/referencePanel.tsx index 4419b289..1dd9c92b 100644 --- a/src/interface/web/app/components/referencePanel/referencePanel.tsx +++ b/src/interface/web/app/components/referencePanel/referencePanel.tsx @@ -31,6 +31,7 @@ import { import { Popover, PopoverContent, PopoverTrigger } from "@/components/ui/popover"; import DOMPurify from "dompurify"; import { getIconFromFilename } from "@/app/common/iconUtils"; +import Link from "next/link"; interface NotesContextReferenceData { title: string; @@ -68,18 +69,25 @@ function NotesContextReferenceCard(props: NotesContextReferenceCardProps) { setIsHovering(true)} onMouseLeave={() => setIsHovering(false)} - className={`${props.showFullContent ? "w-auto" : "w-[200px]"} overflow-hidden break-words text-balance rounded-lg border-none p-2 bg-muted`} + className={`${props.showFullContent ? "w-auto bg-muted" : "w-auto"} overflow-hidden break-words text-balance rounded-lg border-none p-2`} > -

- {fileIcon} - {props.showFullContent ? props.title : fileName} -

-

+ { + !props.showFullContent ? + + : + <> +

+ {fileIcon} + {props.showFullContent ? props.title : fileName} +

+

+ + }
@@ -204,25 +212,30 @@ function CodeContextReferenceCard(props: CodeContextReferenceCardProps) { setIsHovering(true)} onMouseLeave={() => setIsHovering(false)} - className={`${props.showFullContent ? "w-auto" : "w-[200px]"} overflow-hidden break-words text-balance rounded-lg border-none p-2 bg-muted`} + className={`${props.showFullContent ? "w-auto bg-muted" : "w-auto"} overflow-hidden break-words text-balance rounded-lg border-none p-2`} > -
-
- {fileIcon} -

- code {props.output_files?.length > 0 ? "artifacts" : ""} -

-
-
 0 ? "hidden" : "overflow-hidden line-clamp-3"}`}
-                            >
-                                {sanitizedCodeSnippet}
-                            
- {props.output_files?.length > 0 && - renderOutputFiles(props.output_files, false)} -
+ { + !props.showFullContent ? + + : +
+
+ {fileIcon} +

+ code {props.output_files?.length > 0 ? "artifacts" : ""} +

+
+
 0 ? "hidden" : "overflow-hidden line-clamp-3"}`}
+                                    >
+                                        {sanitizedCodeSnippet}
+                                    
+ {props.output_files?.length > 0 && + renderOutputFiles(props.output_files, false)} +
+ }
@@ -299,35 +312,37 @@ function GenericOnlineReferenceCard(props: OnlineReferenceCardProps) { -
- -
- + { + !props.showFullContent ? + + : +
+ { + +
+ +

+ {domain} +

+
+ + }

- {domain} + {props.title}

+

+ {props.description} +

-

- {props.title} -

-

- {props.description} -

-
-
+ } @@ -609,17 +624,29 @@ export default function ReferencePanel(props: ReferencePanelDataProps) { {codeDataToShow.map((code, index) => { return ( - + ); })} {notesDataToShow.map((note, index) => { return ( - + ); })} {onlineDataToShow.map((online, index) => { return ( - + ); })}