|
1 | 1 | import { useEffect, useMemo, useRef, useState } from "react"; |
2 | 2 | import type { ReactNode } from "react"; |
3 | | -import { |
4 | | - Activity, |
5 | | - Globe, |
6 | | - MessageSquareCode, |
7 | | - PanelRightClose, |
8 | | -} from "lucide-react"; |
| 3 | +import { Activity, Globe, MessageSquareCode, PanelRightClose } from "lucide-react"; |
9 | 4 | import { useIntl } from "react-intl"; |
10 | 5 | import type { PromptRead } from "@/generated/types"; |
11 | 6 | import { Badge } from "@/components/ui/badge"; |
12 | 7 | import { Button } from "@/components/ui/button"; |
13 | 8 | import { InlineTagAdd } from "@/components/ui/inline-tag-add"; |
14 | 9 | import { Tabs, TabsContent, TabsList, TabsTrigger } from "@/components/ui/tabs"; |
| 10 | +import { CopyValue } from "@/components/ui/copy-value"; |
15 | 11 | import { cn } from "@/lib/utils"; |
16 | 12 | import { getTagDisplay } from "@/components/gateways/utils"; |
17 | 13 | import { formatDateTime } from "@/utils/format"; |
@@ -291,6 +287,37 @@ export function PromptDetailsPanel({ |
291 | 287 | : intl.formatMessage({ id: "prompts.details.notAvailable" })} |
292 | 288 | </span> |
293 | 289 | </DetailRow> |
| 290 | + <DetailRow |
| 291 | + label={intl.formatMessage({ id: "prompts.details.label.technicalName" })} |
| 292 | + > |
| 293 | + <CopyValue |
| 294 | + label={intl.formatMessage({ id: "prompts.details.label.technicalName" })} |
| 295 | + value={selected.name} |
| 296 | + /> |
| 297 | + </DetailRow> |
| 298 | + {selected.federationSource && ( |
| 299 | + <DetailRow |
| 300 | + label={intl.formatMessage({ id: "prompts.details.label.sourceUrl" })} |
| 301 | + > |
| 302 | + <CopyValue |
| 303 | + label={intl.formatMessage({ id: "prompts.details.label.sourceUrl" })} |
| 304 | + value={selected.federationSource} |
| 305 | + /> |
| 306 | + </DetailRow> |
| 307 | + )} |
| 308 | + <DetailRow label={intl.formatMessage({ id: "prompts.details.label.promptId" })}> |
| 309 | + <CopyValue |
| 310 | + label={intl.formatMessage({ id: "prompts.details.label.promptId" })} |
| 311 | + value={selected.id} |
| 312 | + /> |
| 313 | + </DetailRow> |
| 314 | + {selected.version != null && ( |
| 315 | + <DetailRow |
| 316 | + label={intl.formatMessage({ id: "prompts.details.label.version" })} |
| 317 | + > |
| 318 | + {selected.version} |
| 319 | + </DetailRow> |
| 320 | + )} |
294 | 321 | {(() => { |
295 | 322 | const tagLabels = (selected.tags || []).map( |
296 | 323 | (tag, index) => getTagDisplay(tag, index).label, |
|
0 commit comments