@flamingo-stack/openframe-frontend-core 0.0.663 → 0.0.664-2366.7030.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{chunk-HK7R7HSW.cjs → chunk-3SS37SNM.cjs} +10 -10
- package/dist/{chunk-HK7R7HSW.cjs.map → chunk-3SS37SNM.cjs.map} +1 -1
- package/dist/{chunk-BASKR3Z4.cjs → chunk-5R4QMTML.cjs} +8 -4
- package/dist/chunk-5R4QMTML.cjs.map +1 -0
- package/dist/{chunk-B5DZ37OG.cjs → chunk-6FD7ZEBY.cjs} +248 -248
- package/dist/{chunk-B5DZ37OG.cjs.map → chunk-6FD7ZEBY.cjs.map} +1 -1
- package/dist/{chunk-ARMNWO4M.cjs → chunk-6W5N23LC.cjs} +38 -38
- package/dist/{chunk-ARMNWO4M.cjs.map → chunk-6W5N23LC.cjs.map} +1 -1
- package/dist/{chunk-EPV6XTB5.js → chunk-77WMNQTE.js} +3 -3
- package/dist/{chunk-B2LSPZFR.js → chunk-BKCPXDOE.js} +3 -3
- package/dist/{chunk-IXLJIH6U.js → chunk-BPKEDLGR.js} +7 -7
- package/dist/{chunk-OZTH6T4W.js → chunk-CJ5CFXYX.js} +2 -2
- package/dist/{chunk-PW5QV4FH.js → chunk-CQJXOBWK.js} +5 -5
- package/dist/{chunk-WB32HEBY.js → chunk-DNFC6RYF.js} +4 -4
- package/dist/{chunk-ISPIEV7D.cjs → chunk-EMJAT6IK.cjs} +44 -44
- package/dist/{chunk-ISPIEV7D.cjs.map → chunk-EMJAT6IK.cjs.map} +1 -1
- package/dist/{chunk-K56K55H2.cjs → chunk-FGQSSFP4.cjs} +10 -10
- package/dist/{chunk-K56K55H2.cjs.map → chunk-FGQSSFP4.cjs.map} +1 -1
- package/dist/{chunk-WDE7ETA5.cjs → chunk-FJNGXGJW.cjs} +5 -5
- package/dist/{chunk-WDE7ETA5.cjs.map → chunk-FJNGXGJW.cjs.map} +1 -1
- package/dist/{chunk-MRBXYWEX.js → chunk-GDTFJ5QN.js} +2 -2
- package/dist/{chunk-A3L5AJNX.js → chunk-JHAS6Y7P.js} +6 -6
- package/dist/{chunk-4IQC3VKQ.cjs → chunk-JHH7NETU.cjs} +5 -5
- package/dist/{chunk-4IQC3VKQ.cjs.map → chunk-JHH7NETU.cjs.map} +1 -1
- package/dist/{chunk-XCA5HIVS.cjs → chunk-KBUYG5N6.cjs} +33 -33
- package/dist/{chunk-XCA5HIVS.cjs.map → chunk-KBUYG5N6.cjs.map} +1 -1
- package/dist/{chunk-SAM7XUKM.cjs → chunk-L4ZNA3NX.cjs} +3 -3
- package/dist/{chunk-SAM7XUKM.cjs.map → chunk-L4ZNA3NX.cjs.map} +1 -1
- package/dist/{chunk-67DMHSF7.cjs → chunk-LCYYTWRF.cjs} +7 -7
- package/dist/{chunk-67DMHSF7.cjs.map → chunk-LCYYTWRF.cjs.map} +1 -1
- package/dist/{chunk-4AAPEV7A.cjs → chunk-LTW2GWJ2.cjs} +25 -25
- package/dist/{chunk-4AAPEV7A.cjs.map → chunk-LTW2GWJ2.cjs.map} +1 -1
- package/dist/{chunk-UGR37VMX.cjs → chunk-LXL3PZE2.cjs} +12 -12
- package/dist/{chunk-UGR37VMX.cjs.map → chunk-LXL3PZE2.cjs.map} +1 -1
- package/dist/{chunk-TXKAFOSY.js → chunk-MBLACUCE.js} +5 -5
- package/dist/{chunk-BSETJKSW.cjs → chunk-MNUR6PAJ.cjs} +105 -68
- package/dist/chunk-MNUR6PAJ.cjs.map +1 -0
- package/dist/{chunk-JOBTZDZZ.js → chunk-O3GB7JFL.js} +4 -4
- package/dist/{chunk-J75M5PKR.js → chunk-OLCI3UA5.js} +7 -7
- package/dist/{chunk-RP4TSHMY.js → chunk-OMTLCMQB.js} +768 -731
- package/dist/chunk-OMTLCMQB.js.map +1 -0
- package/dist/{chunk-6IU4FW4G.js → chunk-QR3NUFA5.js} +2 -2
- package/dist/{chunk-RZ4UO3OK.js → chunk-RM4S53GB.js} +2 -2
- package/dist/{chunk-SHUKF2HE.js → chunk-RT5JNTCN.js} +4 -4
- package/dist/{chunk-KU7HL52F.js → chunk-VQZXJIPY.js} +8 -4
- package/dist/chunk-VQZXJIPY.js.map +1 -0
- package/dist/{chunk-XWQOOMT2.cjs → chunk-X32X52VN.cjs} +75 -75
- package/dist/{chunk-XWQOOMT2.cjs.map → chunk-X32X52VN.cjs.map} +1 -1
- package/dist/{chunk-KPXGWKFF.cjs → chunk-XCACXPCM.cjs} +22 -22
- package/dist/{chunk-KPXGWKFF.cjs.map → chunk-XCACXPCM.cjs.map} +1 -1
- package/dist/{chunk-2MRQ3XK2.js → chunk-YRMKUDOE.js} +5 -5
- package/dist/{chunk-UZMPTJ5B.js → chunk-Z2MJPTIB.js} +3 -3
- package/dist/{chunk-KYOOTRYM.cjs → chunk-ZGPST26T.cjs} +51 -51
- package/dist/{chunk-KYOOTRYM.cjs.map → chunk-ZGPST26T.cjs.map} +1 -1
- package/dist/{chunk-RDYUPNDO.cjs → chunk-ZMZUF6FX.cjs} +3 -3
- package/dist/{chunk-RDYUPNDO.cjs.map → chunk-ZMZUF6FX.cjs.map} +1 -1
- package/dist/components/case-studies/index.cjs +20 -20
- package/dist/components/case-studies/index.js +5 -5
- package/dist/components/chat/chat-dialog-menu-items.d.ts +15 -0
- package/dist/components/chat/chat-dialog-menu-items.d.ts.map +1 -0
- package/dist/components/chat/chat-panel-header-mobile.d.ts +1 -1
- package/dist/components/chat/chat-panel-header-mobile.d.ts.map +1 -1
- package/dist/components/chat/chat-panel-header.d.ts +6 -4
- package/dist/components/chat/chat-panel-header.d.ts.map +1 -1
- package/dist/components/chat/embeddable-chat.d.ts +2 -1
- package/dist/components/chat/embeddable-chat.d.ts.map +1 -1
- package/dist/components/chat/index.cjs +3 -3
- package/dist/components/chat/index.js +2 -2
- package/dist/components/chat/mingo-chat-history.d.ts +6 -4
- package/dist/components/chat/mingo-chat-history.d.ts.map +1 -1
- package/dist/components/chat/mingo-history-rail.d.ts +6 -4
- package/dist/components/chat/mingo-history-rail.d.ts.map +1 -1
- package/dist/components/chat/types/unified-chat-state.types.d.ts +9 -3
- package/dist/components/chat/types/unified-chat-state.types.d.ts.map +1 -1
- package/dist/components/contact/index.cjs +6 -6
- package/dist/components/contact/index.js +5 -5
- package/dist/components/docs/index.cjs +9 -9
- package/dist/components/docs/index.js +8 -8
- package/dist/components/embeds/index.cjs +6 -6
- package/dist/components/embeds/index.js +5 -5
- package/dist/components/faq/index.cjs +6 -6
- package/dist/components/faq/index.js +5 -5
- package/dist/components/features/index.cjs +5 -5
- package/dist/components/features/index.js +4 -4
- package/dist/components/help-center-pages/index.cjs +25 -25
- package/dist/components/help-center-pages/index.js +16 -16
- package/dist/components/icons/empty-vendor-icon.d.ts.map +1 -1
- package/dist/components/icons/index.cjs +2 -2
- package/dist/components/icons/index.js +1 -1
- package/dist/components/index.cjs +42 -42
- package/dist/components/index.js +15 -15
- package/dist/components/meeting-scheduler/index.cjs +28 -28
- package/dist/components/meeting-scheduler/index.js +4 -4
- package/dist/components/navigation/index.cjs +8 -8
- package/dist/components/navigation/index.js +7 -7
- package/dist/components/onboarding-guides/index.cjs +8 -8
- package/dist/components/onboarding-guides/index.js +7 -7
- package/dist/components/tickets/index.cjs +9 -9
- package/dist/components/tickets/index.js +8 -8
- package/dist/components/ui/index.cjs +5 -5
- package/dist/components/ui/index.js +4 -4
- package/dist/hooks/index.cjs +3 -3
- package/dist/hooks/index.js +2 -2
- package/dist/index.cjs +9 -9
- package/dist/index.js +8 -8
- package/package.json +1 -1
- package/src/components/chat/__tests__/chat-dialog-menu-items.test.tsx +39 -0
- package/src/components/chat/chat-dialog-menu-items.tsx +51 -0
- package/src/components/chat/chat-panel-header-mobile.tsx +7 -7
- package/src/components/chat/chat-panel-header.tsx +11 -10
- package/src/components/chat/embeddable-chat.tsx +17 -7
- package/src/components/chat/mingo-chat-history.tsx +18 -22
- package/src/components/chat/mingo-history-rail.tsx +7 -3
- package/src/components/chat/types/unified-chat-state.types.ts +9 -3
- package/src/components/icons/empty-vendor-icon.tsx +10 -4
- package/dist/chunk-BASKR3Z4.cjs.map +0 -1
- package/dist/chunk-BSETJKSW.cjs.map +0 -1
- package/dist/chunk-KU7HL52F.js.map +0 -1
- package/dist/chunk-RP4TSHMY.js.map +0 -1
- /package/dist/{chunk-EPV6XTB5.js.map → chunk-77WMNQTE.js.map} +0 -0
- /package/dist/{chunk-B2LSPZFR.js.map → chunk-BKCPXDOE.js.map} +0 -0
- /package/dist/{chunk-IXLJIH6U.js.map → chunk-BPKEDLGR.js.map} +0 -0
- /package/dist/{chunk-OZTH6T4W.js.map → chunk-CJ5CFXYX.js.map} +0 -0
- /package/dist/{chunk-PW5QV4FH.js.map → chunk-CQJXOBWK.js.map} +0 -0
- /package/dist/{chunk-WB32HEBY.js.map → chunk-DNFC6RYF.js.map} +0 -0
- /package/dist/{chunk-MRBXYWEX.js.map → chunk-GDTFJ5QN.js.map} +0 -0
- /package/dist/{chunk-A3L5AJNX.js.map → chunk-JHAS6Y7P.js.map} +0 -0
- /package/dist/{chunk-TXKAFOSY.js.map → chunk-MBLACUCE.js.map} +0 -0
- /package/dist/{chunk-JOBTZDZZ.js.map → chunk-O3GB7JFL.js.map} +0 -0
- /package/dist/{chunk-J75M5PKR.js.map → chunk-OLCI3UA5.js.map} +0 -0
- /package/dist/{chunk-6IU4FW4G.js.map → chunk-QR3NUFA5.js.map} +0 -0
- /package/dist/{chunk-RZ4UO3OK.js.map → chunk-RM4S53GB.js.map} +0 -0
- /package/dist/{chunk-SHUKF2HE.js.map → chunk-RT5JNTCN.js.map} +0 -0
- /package/dist/{chunk-2MRQ3XK2.js.map → chunk-YRMKUDOE.js.map} +0 -0
- /package/dist/{chunk-UZMPTJ5B.js.map → chunk-Z2MJPTIB.js.map} +0 -0
|
@@ -42,7 +42,7 @@ import {
|
|
|
42
42
|
WhatsAppIcon,
|
|
43
43
|
XLogo,
|
|
44
44
|
YouTubeIcon
|
|
45
|
-
} from "./chunk-
|
|
45
|
+
} from "./chunk-VQZXJIPY.js";
|
|
46
46
|
import {
|
|
47
47
|
AlertCircleIcon,
|
|
48
48
|
AlertTriangleIcon,
|
|
@@ -98,14 +98,17 @@ import {
|
|
|
98
98
|
HubspotLogoGreyIcon,
|
|
99
99
|
InfoCircleIcon,
|
|
100
100
|
LayersIcon,
|
|
101
|
+
Link01HorizontalIcon,
|
|
101
102
|
MapIcon,
|
|
102
103
|
Megaphone01Icon,
|
|
103
104
|
MicrophoneIcon,
|
|
104
105
|
MoneyBillDollarIcon,
|
|
105
106
|
NewspaperIcon,
|
|
106
107
|
OpenaiLogoGreyIcon,
|
|
108
|
+
PackageCheckIcon,
|
|
107
109
|
PackageIcon,
|
|
108
110
|
PackagePlusIcon,
|
|
111
|
+
PenEditIcon,
|
|
109
112
|
PlusCircleIcon,
|
|
110
113
|
PlusIcon,
|
|
111
114
|
PresentationBarIcon,
|
|
@@ -9409,8 +9412,46 @@ import { useCallback as useCallback9, useMemo as useMemo16, useState as useState
|
|
|
9409
9412
|
// src/components/chat/mingo-chat-history.tsx
|
|
9410
9413
|
import { useState as useState19, useMemo as useMemo15, useRef as useRef10, useEffect as useEffect11 } from "react";
|
|
9411
9414
|
|
|
9415
|
+
// src/components/chat/chat-dialog-menu-items.tsx
|
|
9416
|
+
import { jsx as jsx50 } from "react/jsx-runtime";
|
|
9417
|
+
var chatMenuIconClassName = "h-full w-full text-ods-text-secondary";
|
|
9418
|
+
function chatDialogMenuItems({
|
|
9419
|
+
onCopyLink,
|
|
9420
|
+
onRename,
|
|
9421
|
+
onCompact,
|
|
9422
|
+
onArchive
|
|
9423
|
+
}) {
|
|
9424
|
+
const items = [
|
|
9425
|
+
onCopyLink && {
|
|
9426
|
+
id: "copy-link",
|
|
9427
|
+
label: "Copy Chat Link",
|
|
9428
|
+
icon: /* @__PURE__ */ jsx50(Link01HorizontalIcon, { className: chatMenuIconClassName }),
|
|
9429
|
+
onClick: onCopyLink
|
|
9430
|
+
},
|
|
9431
|
+
onRename && {
|
|
9432
|
+
id: "rename",
|
|
9433
|
+
label: "Rename Chat",
|
|
9434
|
+
icon: /* @__PURE__ */ jsx50(PenEditIcon, { className: chatMenuIconClassName }),
|
|
9435
|
+
onClick: onRename
|
|
9436
|
+
},
|
|
9437
|
+
onCompact && {
|
|
9438
|
+
id: "compact",
|
|
9439
|
+
label: "Compact Chat Memory",
|
|
9440
|
+
icon: /* @__PURE__ */ jsx50(PackageCheckIcon, { className: chatMenuIconClassName }),
|
|
9441
|
+
onClick: onCompact
|
|
9442
|
+
},
|
|
9443
|
+
onArchive && {
|
|
9444
|
+
id: "archive",
|
|
9445
|
+
label: "Archive Chat",
|
|
9446
|
+
icon: /* @__PURE__ */ jsx50(BoxArchiveIcon, { className: chatMenuIconClassName }),
|
|
9447
|
+
onClick: onArchive
|
|
9448
|
+
}
|
|
9449
|
+
];
|
|
9450
|
+
return items.filter((item) => !!item);
|
|
9451
|
+
}
|
|
9452
|
+
|
|
9412
9453
|
// src/components/chat/chat-list-empty-state.tsx
|
|
9413
|
-
import { jsx as
|
|
9454
|
+
import { jsx as jsx51, jsxs as jsxs37 } from "react/jsx-runtime";
|
|
9414
9455
|
function ChatListEmptyState({ icon, title, description, className }) {
|
|
9415
9456
|
return /* @__PURE__ */ jsxs37(
|
|
9416
9457
|
"div",
|
|
@@ -9420,10 +9461,10 @@ function ChatListEmptyState({ icon, title, description, className }) {
|
|
|
9420
9461
|
className
|
|
9421
9462
|
),
|
|
9422
9463
|
children: [
|
|
9423
|
-
/* @__PURE__ */
|
|
9464
|
+
/* @__PURE__ */ jsx51("span", { className: "flex size-6 shrink-0 items-center justify-center", children: icon }),
|
|
9424
9465
|
/* @__PURE__ */ jsxs37("div", { className: "flex flex-col", children: [
|
|
9425
|
-
/* @__PURE__ */
|
|
9426
|
-
description && /* @__PURE__ */
|
|
9466
|
+
/* @__PURE__ */ jsx51("p", { className: "text-h4", children: title }),
|
|
9467
|
+
description && /* @__PURE__ */ jsx51("p", { className: "text-h6", children: description })
|
|
9427
9468
|
] })
|
|
9428
9469
|
]
|
|
9429
9470
|
}
|
|
@@ -9431,7 +9472,7 @@ function ChatListEmptyState({ icon, title, description, className }) {
|
|
|
9431
9472
|
}
|
|
9432
9473
|
|
|
9433
9474
|
// src/components/chat/mingo-chat-history.tsx
|
|
9434
|
-
import { jsx as
|
|
9475
|
+
import { jsx as jsx52, jsxs as jsxs38 } from "react/jsx-runtime";
|
|
9435
9476
|
function dialogTime(d) {
|
|
9436
9477
|
if (!d.timestamp) return null;
|
|
9437
9478
|
const t = typeof d.timestamp === "string" ? Date.parse(d.timestamp) : d.timestamp.getTime();
|
|
@@ -9462,31 +9503,21 @@ function MingoChatHistoryRow({
|
|
|
9462
9503
|
onSelect,
|
|
9463
9504
|
onRequestCopyLink,
|
|
9464
9505
|
onRequestRename,
|
|
9506
|
+
onRequestCompact,
|
|
9465
9507
|
onRequestArchive
|
|
9466
9508
|
}) {
|
|
9467
9509
|
const title = dialog.title || "Untitled Chat";
|
|
9468
9510
|
const unread = dialog.unreadMessagesCount ?? 0;
|
|
9469
|
-
const hasMenu = !!onRequestRename || !!onRequestArchive || !!onRequestCopyLink;
|
|
9511
|
+
const hasMenu = !!onRequestRename || !!onRequestArchive || !!onRequestCopyLink || !!onRequestCompact;
|
|
9470
9512
|
const owner = dialog.owner;
|
|
9471
9513
|
const hasAvatar = !!(owner?.name || owner?.avatarUrl);
|
|
9472
9514
|
const [menuOpen, setMenuOpen] = useState19(false);
|
|
9473
|
-
const menuItems =
|
|
9474
|
-
onRequestCopyLink &&
|
|
9475
|
-
|
|
9476
|
-
|
|
9477
|
-
|
|
9478
|
-
|
|
9479
|
-
onRequestRename && {
|
|
9480
|
-
id: "rename",
|
|
9481
|
-
label: "Rename chat",
|
|
9482
|
-
onClick: () => onRequestRename(dialog)
|
|
9483
|
-
},
|
|
9484
|
-
onRequestArchive && {
|
|
9485
|
-
id: "archive",
|
|
9486
|
-
label: "Archive chat",
|
|
9487
|
-
onClick: () => onRequestArchive(dialog)
|
|
9488
|
-
}
|
|
9489
|
-
].filter(Boolean);
|
|
9515
|
+
const menuItems = chatDialogMenuItems({
|
|
9516
|
+
onCopyLink: onRequestCopyLink && (() => onRequestCopyLink(dialog)),
|
|
9517
|
+
onRename: onRequestRename && (() => onRequestRename(dialog)),
|
|
9518
|
+
onCompact: onRequestCompact && (() => onRequestCompact(dialog)),
|
|
9519
|
+
onArchive: onRequestArchive && (() => onRequestArchive(dialog))
|
|
9520
|
+
});
|
|
9490
9521
|
return /* @__PURE__ */ jsxs38(
|
|
9491
9522
|
"div",
|
|
9492
9523
|
{
|
|
@@ -9498,7 +9529,7 @@ function MingoChatHistoryRow({
|
|
|
9498
9529
|
isActive ? "bg-ods-accent-secondary" : "bg-ods-bg hover:bg-ods-bg-hover"
|
|
9499
9530
|
),
|
|
9500
9531
|
children: [
|
|
9501
|
-
isActive ? /* @__PURE__ */
|
|
9532
|
+
isActive ? /* @__PURE__ */ jsx52("span", { "aria-hidden": true, className: "pointer-events-none absolute inset-y-0 left-0 w-1 bg-ods-accent" }) : null,
|
|
9502
9533
|
/* @__PURE__ */ jsxs38(
|
|
9503
9534
|
"div",
|
|
9504
9535
|
{
|
|
@@ -9513,8 +9544,8 @@ function MingoChatHistoryRow({
|
|
|
9513
9544
|
},
|
|
9514
9545
|
className: "flex min-w-0 flex-1 cursor-pointer items-center gap-[var(--spacing-system-xsf)] p-[var(--spacing-system-s)] focus:outline-none focus-visible:ring-2 focus-visible:ring-inset focus-visible:ring-ods-accent",
|
|
9515
9546
|
children: [
|
|
9516
|
-
unread > 0 ? /* @__PURE__ */
|
|
9517
|
-
/* @__PURE__ */
|
|
9547
|
+
unread > 0 ? /* @__PURE__ */ jsx52("span", { className: "flex h-8 min-w-8 shrink-0 items-center justify-center rounded-md bg-ods-accent px-[var(--spacing-system-xsf)] text-ods-text-on-accent text-h5", children: unread > 99 ? "99+" : unread }) : null,
|
|
9548
|
+
/* @__PURE__ */ jsx52(
|
|
9518
9549
|
"span",
|
|
9519
9550
|
{
|
|
9520
9551
|
className: cn("min-w-0 flex-1 truncate text-h4", isActive ? "text-ods-accent" : "text-ods-text-primary"),
|
|
@@ -9537,7 +9568,7 @@ function MingoChatHistoryRow({
|
|
|
9537
9568
|
// is open. Hidden on mobile — it's a hover affordance. `peer/menu`
|
|
9538
9569
|
// so the avatar layer (a later sibling) can fade when the trigger
|
|
9539
9570
|
// holds keyboard focus.
|
|
9540
|
-
/* @__PURE__ */
|
|
9571
|
+
/* @__PURE__ */ jsx52(
|
|
9541
9572
|
"span",
|
|
9542
9573
|
{
|
|
9543
9574
|
onClick: (e) => e.stopPropagation(),
|
|
@@ -9545,7 +9576,7 @@ function MingoChatHistoryRow({
|
|
|
9545
9576
|
"peer/menu absolute inset-0 transition-opacity max-md:hidden",
|
|
9546
9577
|
menuOpen ? "opacity-100" : "opacity-0 focus-within:opacity-100 group-hover/row:opacity-100"
|
|
9547
9578
|
),
|
|
9548
|
-
children: /* @__PURE__ */
|
|
9579
|
+
children: /* @__PURE__ */ jsx52(
|
|
9549
9580
|
ActionsMenuDropdown,
|
|
9550
9581
|
{
|
|
9551
9582
|
triggerAriaLabel: "Chat actions",
|
|
@@ -9553,14 +9584,14 @@ function MingoChatHistoryRow({
|
|
|
9553
9584
|
open: menuOpen,
|
|
9554
9585
|
onOpenChange: setMenuOpen,
|
|
9555
9586
|
onCloseAutoFocus: (e) => e.preventDefault(),
|
|
9556
|
-
customTrigger: /* @__PURE__ */
|
|
9587
|
+
customTrigger: /* @__PURE__ */ jsx52(
|
|
9557
9588
|
Button,
|
|
9558
9589
|
{
|
|
9559
9590
|
variant: "transparent",
|
|
9560
9591
|
size: "icon",
|
|
9561
9592
|
"aria-label": "Chat actions",
|
|
9562
9593
|
className: "h-full w-full rounded-none p-0 text-ods-text-secondary hover:text-ods-text-primary md:h-full",
|
|
9563
|
-
children: /* @__PURE__ */
|
|
9594
|
+
children: /* @__PURE__ */ jsx52(Ellipsis01Icon, {})
|
|
9564
9595
|
}
|
|
9565
9596
|
)
|
|
9566
9597
|
}
|
|
@@ -9572,7 +9603,7 @@ function MingoChatHistoryRow({
|
|
|
9572
9603
|
// Avatar layer — clicks fall through to row selection (it covers
|
|
9573
9604
|
// the cell whenever the menu trigger is faded out). On desktop it
|
|
9574
9605
|
// fades for the menu swap; on mobile it's always shown.
|
|
9575
|
-
/* @__PURE__ */
|
|
9606
|
+
/* @__PURE__ */ jsx52(
|
|
9576
9607
|
"span",
|
|
9577
9608
|
{
|
|
9578
9609
|
onClick: () => onSelect?.(dialog.id),
|
|
@@ -9581,7 +9612,7 @@ function MingoChatHistoryRow({
|
|
|
9581
9612
|
"absolute inset-0 flex cursor-pointer items-center justify-center transition-opacity",
|
|
9582
9613
|
hasMenu && (menuOpen ? "pointer-events-none opacity-0" : "md:group-hover/row:pointer-events-none md:group-hover/row:opacity-0 md:peer-[:focus-within]/menu:pointer-events-none md:peer-[:focus-within]/menu:opacity-0")
|
|
9583
9614
|
),
|
|
9584
|
-
children: /* @__PURE__ */
|
|
9615
|
+
children: /* @__PURE__ */ jsx52(
|
|
9585
9616
|
SquareAvatar,
|
|
9586
9617
|
{
|
|
9587
9618
|
variant: "round",
|
|
@@ -9606,18 +9637,18 @@ function MingoChatHistorySkeleton({ className }) {
|
|
|
9606
9637
|
["w-3/5", "w-4/5", "w-2/5", "w-3/4"],
|
|
9607
9638
|
["w-1/2", "w-2/3"]
|
|
9608
9639
|
];
|
|
9609
|
-
return /* @__PURE__ */
|
|
9640
|
+
return /* @__PURE__ */ jsx52(
|
|
9610
9641
|
"div",
|
|
9611
9642
|
{
|
|
9612
9643
|
"aria-hidden": true,
|
|
9613
9644
|
className: cn("flex min-h-0 flex-1 flex-col gap-[var(--spacing-system-m)] overflow-hidden", className),
|
|
9614
9645
|
children: groups.map((widths, g) => /* @__PURE__ */ jsxs38("div", { className: "flex shrink-0 flex-col gap-[var(--spacing-system-xxs)]", children: [
|
|
9615
|
-
/* @__PURE__ */
|
|
9616
|
-
/* @__PURE__ */
|
|
9646
|
+
/* @__PURE__ */ jsx52("div", { className: "h-3 w-16 animate-pulse rounded bg-ods-border" }),
|
|
9647
|
+
/* @__PURE__ */ jsx52("div", { className: "overflow-hidden rounded-md border border-ods-border", children: widths.map((w, i) => /* @__PURE__ */ jsx52(
|
|
9617
9648
|
"div",
|
|
9618
9649
|
{
|
|
9619
9650
|
className: "flex h-12 items-center border-b border-ods-border bg-ods-bg px-[var(--spacing-system-s)] last:border-b-0",
|
|
9620
|
-
children: /* @__PURE__ */
|
|
9651
|
+
children: /* @__PURE__ */ jsx52("div", { className: cn("h-4 animate-pulse rounded bg-ods-border", w) })
|
|
9621
9652
|
},
|
|
9622
9653
|
i
|
|
9623
9654
|
)) })
|
|
@@ -9631,6 +9662,7 @@ function MingoChatHistory({
|
|
|
9631
9662
|
onSelectDialog,
|
|
9632
9663
|
onRequestCopyLink,
|
|
9633
9664
|
onRequestRename,
|
|
9665
|
+
onRequestCompact,
|
|
9634
9666
|
onRequestArchive,
|
|
9635
9667
|
searchQuery,
|
|
9636
9668
|
hasMore = false,
|
|
@@ -9664,7 +9696,7 @@ function MingoChatHistory({
|
|
|
9664
9696
|
io.observe(sentinel);
|
|
9665
9697
|
return () => io.disconnect();
|
|
9666
9698
|
}, [hasMore, isLoadingMore, dialogCount, scrollRef]);
|
|
9667
|
-
return /* @__PURE__ */
|
|
9699
|
+
return /* @__PURE__ */ jsx52("div", { className: cn("relative flex min-h-0 flex-1 flex-col gap-[var(--spacing-system-m)]", className), children: /* @__PURE__ */ jsxs38("div", { className: "relative flex min-h-0 flex-1 flex-col", children: [
|
|
9668
9700
|
/* @__PURE__ */ jsxs38(
|
|
9669
9701
|
"div",
|
|
9670
9702
|
{
|
|
@@ -9675,17 +9707,17 @@ function MingoChatHistory({
|
|
|
9675
9707
|
noSearchResults ? (
|
|
9676
9708
|
// No search matches — same centred glyph + title + caption layout as
|
|
9677
9709
|
// the other chat-list empty states (Figma 113:60939).
|
|
9678
|
-
/* @__PURE__ */
|
|
9710
|
+
/* @__PURE__ */ jsx52(
|
|
9679
9711
|
ChatListEmptyState,
|
|
9680
9712
|
{
|
|
9681
|
-
icon: /* @__PURE__ */
|
|
9713
|
+
icon: /* @__PURE__ */ jsx52(SearchXmarkIcon, { size: 24 }),
|
|
9682
9714
|
title: "No Chats Found",
|
|
9683
9715
|
description: "Try a different search term"
|
|
9684
9716
|
}
|
|
9685
9717
|
)
|
|
9686
9718
|
) : groups.map((group) => /* @__PURE__ */ jsxs38("div", { className: "flex flex-col gap-[var(--spacing-system-xxs)]", children: [
|
|
9687
|
-
/* @__PURE__ */
|
|
9688
|
-
/* @__PURE__ */
|
|
9719
|
+
/* @__PURE__ */ jsx52("p", { className: "text-ods-text-secondary text-h5", children: group.label }),
|
|
9720
|
+
/* @__PURE__ */ jsx52("div", { className: "overflow-hidden rounded-md border border-ods-border", children: group.items.map((dialog) => /* @__PURE__ */ jsx52(
|
|
9689
9721
|
MingoChatHistoryRow,
|
|
9690
9722
|
{
|
|
9691
9723
|
dialog,
|
|
@@ -9693,22 +9725,23 @@ function MingoChatHistory({
|
|
|
9693
9725
|
onSelect: onSelectDialog,
|
|
9694
9726
|
onRequestCopyLink,
|
|
9695
9727
|
onRequestRename,
|
|
9728
|
+
onRequestCompact,
|
|
9696
9729
|
onRequestArchive
|
|
9697
9730
|
},
|
|
9698
9731
|
dialog.id
|
|
9699
9732
|
)) })
|
|
9700
9733
|
] }, group.key)),
|
|
9701
|
-
hasMore ? /* @__PURE__ */
|
|
9734
|
+
hasMore ? /* @__PURE__ */ jsx52("div", { ref: sentinelRef, className: "h-px shrink-0" }) : null
|
|
9702
9735
|
]
|
|
9703
9736
|
}
|
|
9704
9737
|
),
|
|
9705
|
-
/* @__PURE__ */
|
|
9706
|
-
/* @__PURE__ */
|
|
9738
|
+
/* @__PURE__ */ jsx52(ScrollFadeOverlay, { edge: "top", visible: fadeTop, color: "var(--color-bg-card)", className: "h-12" }),
|
|
9739
|
+
/* @__PURE__ */ jsx52(ScrollFadeOverlay, { edge: "bottom", visible: fadeBottom, color: "var(--color-bg-card)", className: "h-12" })
|
|
9707
9740
|
] }) });
|
|
9708
9741
|
}
|
|
9709
9742
|
|
|
9710
9743
|
// src/components/chat/mingo-welcome.tsx
|
|
9711
|
-
import { Fragment as Fragment13, jsx as
|
|
9744
|
+
import { Fragment as Fragment13, jsx as jsx53, jsxs as jsxs39 } from "react/jsx-runtime";
|
|
9712
9745
|
var DEFAULT_SUBTITLE = "Ready to help with your technical tasks. What can I do for you?";
|
|
9713
9746
|
var DEFAULT_PROMO = {
|
|
9714
9747
|
title: "New to OpenFrame?",
|
|
@@ -9769,21 +9802,21 @@ function MingoWelcome({
|
|
|
9769
9802
|
),
|
|
9770
9803
|
children: [
|
|
9771
9804
|
dialogHistory ?? (loadError ? /* @__PURE__ */ jsxs39("div", { className: "flex min-h-0 flex-1 flex-col items-center justify-center gap-[var(--spacing-system-m)] text-center", children: [
|
|
9772
|
-
/* @__PURE__ */
|
|
9805
|
+
/* @__PURE__ */ jsx53(AlertCircleIcon, { className: "h-8 w-8 shrink-0 text-ods-text-secondary" }),
|
|
9773
9806
|
/* @__PURE__ */ jsxs39("div", { className: "flex flex-col gap-[var(--spacing-system-xxs)]", children: [
|
|
9774
|
-
/* @__PURE__ */
|
|
9775
|
-
/* @__PURE__ */
|
|
9807
|
+
/* @__PURE__ */ jsx53("p", { className: "text-ods-text-primary text-h4", children: "Couldn\u2019t load your chats" }),
|
|
9808
|
+
/* @__PURE__ */ jsx53("p", { className: "text-body-sm text-ods-text-secondary", children: "Something went wrong reaching the server. Check your connection and try again." })
|
|
9776
9809
|
] }),
|
|
9777
|
-
onRetry && /* @__PURE__ */
|
|
9778
|
-
] }) : isLoadingHistory ? /* @__PURE__ */
|
|
9779
|
-
/* @__PURE__ */
|
|
9810
|
+
onRetry && /* @__PURE__ */ jsx53(Button, { variant: "outline", size: "small", leftIcon: /* @__PURE__ */ jsx53(Refresh01RightIcon, {}), onClick: onRetry, children: "Try again" })
|
|
9811
|
+
] }) : isLoadingHistory ? /* @__PURE__ */ jsx53(MingoChatHistorySkeleton, {}) : /* @__PURE__ */ jsx53(Fragment13, { children: /* @__PURE__ */ jsxs39("div", { className: "relative flex min-h-0 flex-1 flex-col", children: [
|
|
9812
|
+
/* @__PURE__ */ jsx53(
|
|
9780
9813
|
"div",
|
|
9781
9814
|
{
|
|
9782
9815
|
ref: scrollRef,
|
|
9783
9816
|
onScroll: updateScrollFade,
|
|
9784
9817
|
className: "flex min-h-0 flex-1 flex-col gap-[var(--spacing-system-m)] overflow-y-auto overscroll-contain",
|
|
9785
9818
|
children: /* @__PURE__ */ jsxs39("div", { className: "flex flex-1 flex-col items-center justify-center gap-[var(--spacing-system-l)] px-[var(--spacing-system-l)] py-[var(--spacing-system-xxl)] text-center", children: [
|
|
9786
|
-
/* @__PURE__ */
|
|
9819
|
+
/* @__PURE__ */ jsx53(
|
|
9787
9820
|
MingoIcon,
|
|
9788
9821
|
{
|
|
9789
9822
|
className: "h-12 w-12",
|
|
@@ -9793,45 +9826,45 @@ function MingoWelcome({
|
|
|
9793
9826
|
}
|
|
9794
9827
|
),
|
|
9795
9828
|
/* @__PURE__ */ jsxs39("div", { className: "flex w-full flex-col gap-[var(--spacing-system-l)]", children: [
|
|
9796
|
-
/* @__PURE__ */
|
|
9797
|
-
/* @__PURE__ */
|
|
9829
|
+
/* @__PURE__ */ jsx53("p", { className: "text-ods-text-primary text-h2", children: heading }),
|
|
9830
|
+
/* @__PURE__ */ jsx53("p", { className: "text-ods-text-secondary text-h4", children: subtitle })
|
|
9798
9831
|
] })
|
|
9799
9832
|
] })
|
|
9800
9833
|
}
|
|
9801
9834
|
),
|
|
9802
|
-
/* @__PURE__ */
|
|
9803
|
-
/* @__PURE__ */
|
|
9835
|
+
/* @__PURE__ */ jsx53(ScrollFadeOverlay, { edge: "top", visible: fadeTop, className: "h-12" }),
|
|
9836
|
+
/* @__PURE__ */ jsx53(ScrollFadeOverlay, { edge: "bottom", visible: fadeBottom, className: "h-12" })
|
|
9804
9837
|
] }) })),
|
|
9805
9838
|
showPinnedRegion && /* @__PURE__ */ jsxs39("div", { className: "flex shrink-0 flex-col gap-[var(--spacing-system-m)]", children: [
|
|
9806
9839
|
resolvedPromo && !promoDismissed && /* @__PURE__ */ jsxs39("div", { className: "relative flex shrink-0 items-center gap-[var(--spacing-system-m)] rounded-md border border-ods-border bg-ods-bg p-[var(--spacing-system-m)] pr-[var(--spacing-system-xl)]", children: [
|
|
9807
|
-
/* @__PURE__ */
|
|
9840
|
+
/* @__PURE__ */ jsx53("span", { className: "hidden size-4 shrink-0 items-center justify-center text-ods-text-primary @2xl:flex", children: /* @__PURE__ */ jsx53(Arrow01DownIcon, { size: 16 }) }),
|
|
9808
9841
|
/* @__PURE__ */ jsxs39("div", { className: "flex min-w-0 flex-col items-start gap-1", children: [
|
|
9809
|
-
/* @__PURE__ */
|
|
9810
|
-
/* @__PURE__ */
|
|
9842
|
+
/* @__PURE__ */ jsx53("span", { className: "text-ods-text-primary text-h3", children: resolvedPromo.title }),
|
|
9843
|
+
/* @__PURE__ */ jsx53("span", { className: "text-ods-text-secondary text-h6", children: resolvedPromo.description })
|
|
9811
9844
|
] }),
|
|
9812
|
-
/* @__PURE__ */
|
|
9845
|
+
/* @__PURE__ */ jsx53(
|
|
9813
9846
|
"button",
|
|
9814
9847
|
{
|
|
9815
9848
|
type: "button",
|
|
9816
9849
|
onClick: dismissPromo,
|
|
9817
9850
|
"aria-label": "Dismiss",
|
|
9818
9851
|
className: "absolute right-2 top-2 rounded-sm text-ods-text-secondary transition-colors hover:text-ods-text-primary focus:outline-none focus-visible:ring-2 focus-visible:ring-ods-accent",
|
|
9819
|
-
children: /* @__PURE__ */
|
|
9852
|
+
children: /* @__PURE__ */ jsx53(XmarkIcon, { size: 16 })
|
|
9820
9853
|
}
|
|
9821
9854
|
)
|
|
9822
9855
|
] }),
|
|
9823
9856
|
(onStartGuideChat || quickActions && quickActions.length > 0) && /* @__PURE__ */ jsxs39("div", { className: "flex shrink-0 flex-col gap-[var(--chip-wall-gap)]", children: [
|
|
9824
|
-
onStartGuideChat && /* @__PURE__ */
|
|
9857
|
+
onStartGuideChat && /* @__PURE__ */ jsx53(
|
|
9825
9858
|
QuickActionChipButton,
|
|
9826
9859
|
{
|
|
9827
9860
|
label: "Start Guide Chat",
|
|
9828
|
-
icon: /* @__PURE__ */
|
|
9861
|
+
icon: /* @__PURE__ */ jsx53(CompassIcon, { size: 16 }),
|
|
9829
9862
|
variant: hasExistingChats ? "outline" : "primary",
|
|
9830
9863
|
onSelect: onStartGuideChat,
|
|
9831
9864
|
className: "self-start"
|
|
9832
9865
|
}
|
|
9833
9866
|
),
|
|
9834
|
-
quickActions && quickActions.length > 0 && /* @__PURE__ */
|
|
9867
|
+
quickActions && quickActions.length > 0 && /* @__PURE__ */ jsx53(
|
|
9835
9868
|
QuickActionWall,
|
|
9836
9869
|
{
|
|
9837
9870
|
chips: quickActions.map((action) => ({
|
|
@@ -9863,7 +9896,7 @@ function MingoWelcome({
|
|
|
9863
9896
|
|
|
9864
9897
|
// src/components/chat/guide-welcome.tsx
|
|
9865
9898
|
import { useMemo as useMemo17 } from "react";
|
|
9866
|
-
import { jsx as
|
|
9899
|
+
import { jsx as jsx54, jsxs as jsxs40 } from "react/jsx-runtime";
|
|
9867
9900
|
var DEFAULT_TITLE = "Guide Mode Chat";
|
|
9868
9901
|
function GuideWelcome({
|
|
9869
9902
|
title = DEFAULT_TITLE,
|
|
@@ -9913,8 +9946,8 @@ function GuideWelcome({
|
|
|
9913
9946
|
icon && (icon.name || icon.url) ? (
|
|
9914
9947
|
// Agent-mode identity glyph (chat-config Identity tab). Sized to
|
|
9915
9948
|
// match the default Mingo mark (48px).
|
|
9916
|
-
/* @__PURE__ */
|
|
9917
|
-
) : /* @__PURE__ */
|
|
9949
|
+
/* @__PURE__ */ jsx54(EntityIcon, { icon: { name: icon.name, url: icon.url, props: icon.props }, size: 48 })
|
|
9950
|
+
) : /* @__PURE__ */ jsx54(
|
|
9918
9951
|
MingoIcon,
|
|
9919
9952
|
{
|
|
9920
9953
|
className: "h-12 w-12",
|
|
@@ -9924,18 +9957,18 @@ function GuideWelcome({
|
|
|
9924
9957
|
}
|
|
9925
9958
|
),
|
|
9926
9959
|
/* @__PURE__ */ jsxs40("div", { className: "flex w-full flex-col gap-[var(--spacing-system-l)]", children: [
|
|
9927
|
-
/* @__PURE__ */
|
|
9928
|
-
subtitle ? /* @__PURE__ */
|
|
9960
|
+
/* @__PURE__ */ jsx54("p", { className: "text-ods-text-primary text-h2", children: title }),
|
|
9961
|
+
subtitle ? /* @__PURE__ */ jsx54("p", { className: "text-ods-text-secondary text-h4", children: subtitle }) : subtitleLoading ? /* @__PURE__ */ jsx54("div", { className: "flex w-full justify-center", children: /* @__PURE__ */ jsx54(Skeleton, { className: "h-5 w-3/4 max-w-80 rounded-sm" }) }) : null
|
|
9929
9962
|
] })
|
|
9930
9963
|
] }),
|
|
9931
9964
|
children
|
|
9932
9965
|
]
|
|
9933
9966
|
}
|
|
9934
9967
|
),
|
|
9935
|
-
/* @__PURE__ */
|
|
9936
|
-
/* @__PURE__ */
|
|
9968
|
+
/* @__PURE__ */ jsx54(ScrollFadeOverlay, { edge: "top", visible: fadeTop, className: "h-12" }),
|
|
9969
|
+
/* @__PURE__ */ jsx54(ScrollFadeOverlay, { edge: "bottom", visible: fadeBottom, className: "h-12" })
|
|
9937
9970
|
] }),
|
|
9938
|
-
quickActions.length > 0 && /* @__PURE__ */
|
|
9971
|
+
quickActions.length > 0 && /* @__PURE__ */ jsx54(
|
|
9939
9972
|
QuickActionWall,
|
|
9940
9973
|
{
|
|
9941
9974
|
chips: chipItems,
|
|
@@ -9954,7 +9987,7 @@ function GuideWelcome({
|
|
|
9954
9987
|
}
|
|
9955
9988
|
|
|
9956
9989
|
// src/components/chat/guide-mode-banner.tsx
|
|
9957
|
-
import { jsx as
|
|
9990
|
+
import { jsx as jsx55, jsxs as jsxs41 } from "react/jsx-runtime";
|
|
9958
9991
|
var DEFAULT_LABEL = "Guide Mode Chat";
|
|
9959
9992
|
var DEFAULT_TOOLTIP = "A quick session chat for exploring OpenFrame. Mingo answers how-to questions and guides you through configuration, but won\u2019t touch devices, run scripts, or perform any actions.";
|
|
9960
9993
|
function GuideModeBanner({ label = DEFAULT_LABEL, tooltip = DEFAULT_TOOLTIP, className }) {
|
|
@@ -9966,19 +9999,19 @@ function GuideModeBanner({ label = DEFAULT_LABEL, tooltip = DEFAULT_TOOLTIP, cla
|
|
|
9966
9999
|
className
|
|
9967
10000
|
),
|
|
9968
10001
|
children: [
|
|
9969
|
-
/* @__PURE__ */
|
|
9970
|
-
/* @__PURE__ */
|
|
9971
|
-
tooltip != null && /* @__PURE__ */
|
|
9972
|
-
/* @__PURE__ */
|
|
10002
|
+
/* @__PURE__ */ jsx55(CompassIcon, { size: 16, className: "shrink-0 text-ods-text-on-accent" }),
|
|
10003
|
+
/* @__PURE__ */ jsx55("p", { className: "flex-1 truncate uppercase text-ods-text-on-accent text-h5", children: label }),
|
|
10004
|
+
tooltip != null && /* @__PURE__ */ jsx55(TooltipProvider, { delayDuration: 0, children: /* @__PURE__ */ jsxs41(Tooltip, { children: [
|
|
10005
|
+
/* @__PURE__ */ jsx55(TooltipTrigger, { asChild: true, children: /* @__PURE__ */ jsx55(
|
|
9973
10006
|
"button",
|
|
9974
10007
|
{
|
|
9975
10008
|
type: "button",
|
|
9976
10009
|
"aria-label": "About Guide Mode",
|
|
9977
10010
|
className: "shrink-0 rounded-sm text-ods-text-on-accent focus:outline-none focus-visible:ring-2 focus-visible:ring-ods-text-on-accent",
|
|
9978
|
-
children: /* @__PURE__ */
|
|
10011
|
+
children: /* @__PURE__ */ jsx55(QuestionCircleIcon, { size: 16 })
|
|
9979
10012
|
}
|
|
9980
10013
|
) }),
|
|
9981
|
-
/* @__PURE__ */
|
|
10014
|
+
/* @__PURE__ */ jsx55(TooltipContent, { side: "bottom", align: "end", className: "max-w-[280px] normal-case text-h6", children: tooltip })
|
|
9982
10015
|
] }) })
|
|
9983
10016
|
]
|
|
9984
10017
|
}
|
|
@@ -9986,7 +10019,7 @@ function GuideModeBanner({ label = DEFAULT_LABEL, tooltip = DEFAULT_TOOLTIP, cla
|
|
|
9986
10019
|
}
|
|
9987
10020
|
|
|
9988
10021
|
// src/components/ui/tab-selector.tsx
|
|
9989
|
-
import { jsx as
|
|
10022
|
+
import { jsx as jsx56, jsxs as jsxs42 } from "react/jsx-runtime";
|
|
9990
10023
|
function TabSelector({
|
|
9991
10024
|
value,
|
|
9992
10025
|
onValueChange,
|
|
@@ -10007,8 +10040,8 @@ function TabSelector({
|
|
|
10007
10040
|
label && // Label for family/color; 'large' (text-h4) is this component's
|
|
10008
10041
|
// long-standing label scale — neighbours opt into the same scale via
|
|
10009
10042
|
// their `labelVariant="large"` when a design puts them side by side.
|
|
10010
|
-
/* @__PURE__ */
|
|
10011
|
-
/* @__PURE__ */
|
|
10043
|
+
/* @__PURE__ */ jsx56(Label, { variant: "large", children: label }),
|
|
10044
|
+
/* @__PURE__ */ jsx56(
|
|
10012
10045
|
"div",
|
|
10013
10046
|
{
|
|
10014
10047
|
className: cn(
|
|
@@ -10036,7 +10069,7 @@ function TabSelector({
|
|
|
10036
10069
|
isDisabled ? isActive ? "cursor-not-allowed bg-ods-bg-surface text-ods-text-secondary" : "cursor-not-allowed bg-transparent text-ods-text-secondary" : isActive ? variant === "primary" ? "cursor-default bg-ods-accent text-ods-text-on-accent" : "cursor-default bg-ods-bg-surface text-ods-text-primary" : "cursor-pointer bg-transparent text-ods-text-primary hover:bg-ods-bg-hover"
|
|
10037
10070
|
),
|
|
10038
10071
|
children: [
|
|
10039
|
-
item.icon && /* @__PURE__ */
|
|
10072
|
+
item.icon && /* @__PURE__ */ jsx56("span", { className: "flex size-4 shrink-0 items-center justify-center md:size-6", children: item.icon }),
|
|
10040
10073
|
item.label,
|
|
10041
10074
|
item.badge && item.badge
|
|
10042
10075
|
]
|
|
@@ -10052,7 +10085,7 @@ function TabSelector({
|
|
|
10052
10085
|
}
|
|
10053
10086
|
|
|
10054
10087
|
// src/components/chat/mingo-history-rail.tsx
|
|
10055
|
-
import { jsx as
|
|
10088
|
+
import { jsx as jsx57, jsxs as jsxs43 } from "react/jsx-runtime";
|
|
10056
10089
|
function MingoHistoryRail({
|
|
10057
10090
|
dialogs,
|
|
10058
10091
|
activeDialogId,
|
|
@@ -10061,6 +10094,7 @@ function MingoHistoryRail({
|
|
|
10061
10094
|
onRequestRename,
|
|
10062
10095
|
onRequestArchive,
|
|
10063
10096
|
onRequestCopyLink,
|
|
10097
|
+
onRequestCompact,
|
|
10064
10098
|
scope,
|
|
10065
10099
|
onScopeChange,
|
|
10066
10100
|
searchQuery,
|
|
@@ -10082,18 +10116,18 @@ function MingoHistoryRail({
|
|
|
10082
10116
|
className
|
|
10083
10117
|
),
|
|
10084
10118
|
children: [
|
|
10085
|
-
onNewChat && /* @__PURE__ */
|
|
10119
|
+
onNewChat && /* @__PURE__ */ jsx57(
|
|
10086
10120
|
Button,
|
|
10087
10121
|
{
|
|
10088
10122
|
variant: "outline",
|
|
10089
10123
|
fullWidth: true,
|
|
10090
|
-
leftIcon: /* @__PURE__ */
|
|
10124
|
+
leftIcon: /* @__PURE__ */ jsx57(PlusCircleIcon, { size: 20 }),
|
|
10091
10125
|
onClick: onNewChat,
|
|
10092
10126
|
className: "shrink-0 justify-start",
|
|
10093
10127
|
children: "Start New Chat"
|
|
10094
10128
|
}
|
|
10095
10129
|
),
|
|
10096
|
-
scope && onScopeChange && !loadError ? /* @__PURE__ */
|
|
10130
|
+
scope && onScopeChange && !loadError ? /* @__PURE__ */ jsx57(
|
|
10097
10131
|
TabSelector,
|
|
10098
10132
|
{
|
|
10099
10133
|
className: "shrink-0",
|
|
@@ -10106,13 +10140,13 @@ function MingoHistoryRail({
|
|
|
10106
10140
|
}
|
|
10107
10141
|
) : null,
|
|
10108
10142
|
loadError ? /* @__PURE__ */ jsxs43("div", { className: "flex min-h-0 flex-1 flex-col items-center justify-center gap-[var(--spacing-system-m)] text-center", children: [
|
|
10109
|
-
/* @__PURE__ */
|
|
10143
|
+
/* @__PURE__ */ jsx57(AlertCircleIcon, { className: "h-8 w-8 shrink-0 text-ods-text-secondary" }),
|
|
10110
10144
|
/* @__PURE__ */ jsxs43("div", { className: "flex flex-col gap-[var(--spacing-system-xxs)]", children: [
|
|
10111
|
-
/* @__PURE__ */
|
|
10112
|
-
/* @__PURE__ */
|
|
10145
|
+
/* @__PURE__ */ jsx57("p", { className: "text-ods-text-primary text-h4", children: "Couldn\u2019t load your chats" }),
|
|
10146
|
+
/* @__PURE__ */ jsx57("p", { className: "text-ods-text-secondary text-h6", children: "Something went wrong reaching the server. Try again." })
|
|
10113
10147
|
] }),
|
|
10114
|
-
onRetry && /* @__PURE__ */
|
|
10115
|
-
] }) : isLoadingHistory ? /* @__PURE__ */
|
|
10148
|
+
onRetry && /* @__PURE__ */ jsx57(Button, { variant: "outline", size: "small", leftIcon: /* @__PURE__ */ jsx57(Refresh01RightIcon, {}), onClick: onRetry, children: "Try again" })
|
|
10149
|
+
] }) : isLoadingHistory ? /* @__PURE__ */ jsx57(MingoChatHistorySkeleton, {}) : hasList ? /* @__PURE__ */ jsx57(
|
|
10116
10150
|
MingoChatHistory,
|
|
10117
10151
|
{
|
|
10118
10152
|
dialogs,
|
|
@@ -10121,6 +10155,7 @@ function MingoHistoryRail({
|
|
|
10121
10155
|
onRequestRename,
|
|
10122
10156
|
onRequestArchive,
|
|
10123
10157
|
onRequestCopyLink,
|
|
10158
|
+
onRequestCompact,
|
|
10124
10159
|
searchQuery,
|
|
10125
10160
|
hasMore,
|
|
10126
10161
|
isLoadingMore,
|
|
@@ -10128,10 +10163,10 @@ function MingoHistoryRail({
|
|
|
10128
10163
|
}
|
|
10129
10164
|
) : (
|
|
10130
10165
|
// Figma 113:60939 — no-chats empty state.
|
|
10131
|
-
/* @__PURE__ */
|
|
10166
|
+
/* @__PURE__ */ jsx57(
|
|
10132
10167
|
ChatListEmptyState,
|
|
10133
10168
|
{
|
|
10134
|
-
icon: /* @__PURE__ */
|
|
10169
|
+
icon: /* @__PURE__ */ jsx57(ChatsIcon, { size: 24 }),
|
|
10135
10170
|
title: "No Current Chats",
|
|
10136
10171
|
description: "Previous Mingo sessions will show here"
|
|
10137
10172
|
}
|
|
@@ -10148,7 +10183,7 @@ import { useState as useState22 } from "react";
|
|
|
10148
10183
|
// src/components/ui/modal-v2.tsx
|
|
10149
10184
|
import { createContext as createContext4, forwardRef as forwardRef20, useContext as useContext4, useRef as useRef11, useEffect as useEffect12, useState as useState21 } from "react";
|
|
10150
10185
|
import { RemoveScroll } from "react-remove-scroll";
|
|
10151
|
-
import { jsx as
|
|
10186
|
+
import { jsx as jsx58, jsxs as jsxs44 } from "react/jsx-runtime";
|
|
10152
10187
|
var ANIMATION_DURATION = 200;
|
|
10153
10188
|
var ModalContext = createContext4({});
|
|
10154
10189
|
var MODAL_V2_SIZE_CLASSES = {
|
|
@@ -10258,13 +10293,13 @@ var Modal = forwardRef20(
|
|
|
10258
10293
|
// gap. Cloning onto the child instead leaves only the `fixed` overlay,
|
|
10259
10294
|
// which is out of flow and therefore not a flex/grid item at all.
|
|
10260
10295
|
// The child must stay a single element for `Children.only`.
|
|
10261
|
-
/* @__PURE__ */
|
|
10296
|
+
/* @__PURE__ */ jsx58(RemoveScroll, { enabled: isOpen, removeScrollBar: false, forwardProps: true, children: /* @__PURE__ */ jsxs44(
|
|
10262
10297
|
"div",
|
|
10263
10298
|
{
|
|
10264
10299
|
className: "fixed inset-0 z-[1300] flex items-end justify-center transition-[padding] duration-200 md:items-center",
|
|
10265
10300
|
style: { paddingBottom: "var(--of-keyboard-inset, 0px)" },
|
|
10266
10301
|
children: [
|
|
10267
|
-
/* @__PURE__ */
|
|
10302
|
+
/* @__PURE__ */ jsx58(
|
|
10268
10303
|
"div",
|
|
10269
10304
|
{
|
|
10270
10305
|
"data-state": state,
|
|
@@ -10282,7 +10317,7 @@ var Modal = forwardRef20(
|
|
|
10282
10317
|
"aria-hidden": "true"
|
|
10283
10318
|
}
|
|
10284
10319
|
),
|
|
10285
|
-
/* @__PURE__ */
|
|
10320
|
+
/* @__PURE__ */ jsx58(
|
|
10286
10321
|
"div",
|
|
10287
10322
|
{
|
|
10288
10323
|
ref: (node) => {
|
|
@@ -10333,7 +10368,7 @@ var Modal = forwardRef20(
|
|
|
10333
10368
|
),
|
|
10334
10369
|
role: "dialog",
|
|
10335
10370
|
"aria-modal": "true",
|
|
10336
|
-
children: /* @__PURE__ */
|
|
10371
|
+
children: /* @__PURE__ */ jsx58(ModalContext.Provider, { value: { onClose }, children })
|
|
10337
10372
|
}
|
|
10338
10373
|
)
|
|
10339
10374
|
]
|
|
@@ -10343,36 +10378,36 @@ var Modal = forwardRef20(
|
|
|
10343
10378
|
}
|
|
10344
10379
|
);
|
|
10345
10380
|
Modal.displayName = "ModalV2";
|
|
10346
|
-
var ModalContent = forwardRef20(({ children, className }, ref) => /* @__PURE__ */
|
|
10381
|
+
var ModalContent = forwardRef20(({ children, className }, ref) => /* @__PURE__ */ jsx58("div", { ref, className: cn("min-h-0 flex-1 overflow-y-auto", className), children }));
|
|
10347
10382
|
ModalContent.displayName = "ModalV2Content";
|
|
10348
|
-
var ModalTwoColumn = forwardRef20(({ left, right, className }, ref) => /* @__PURE__ */
|
|
10349
|
-
/* @__PURE__ */
|
|
10350
|
-
/* @__PURE__ */
|
|
10383
|
+
var ModalTwoColumn = forwardRef20(({ left, right, className }, ref) => /* @__PURE__ */ jsx58("div", { ref, className: cn("min-h-0 flex-1 overflow-y-auto lg:overflow-hidden", className), children: /* @__PURE__ */ jsxs44("div", { className: "grid grid-cols-1 gap-[var(--spacing-system-xl)] lg:h-full lg:min-h-0 lg:grid-cols-2 lg:grid-rows-[minmax(0,1fr)]", children: [
|
|
10384
|
+
/* @__PURE__ */ jsx58("div", { className: "min-h-0 space-y-[var(--spacing-system-lf)] lg:overflow-y-auto lg:pr-[var(--spacing-system-sf)]", children: left }),
|
|
10385
|
+
/* @__PURE__ */ jsx58("div", { className: "min-h-0 space-y-[var(--spacing-system-lf)] lg:overflow-y-auto lg:pr-[var(--spacing-system-sf)]", children: right })
|
|
10351
10386
|
] }) }));
|
|
10352
10387
|
ModalTwoColumn.displayName = "ModalV2TwoColumn";
|
|
10353
10388
|
var ModalHeader = forwardRef20(({ children, className }, ref) => {
|
|
10354
10389
|
const { onClose } = useContext4(ModalContext);
|
|
10355
10390
|
return /* @__PURE__ */ jsxs44("div", { ref, className: cn("flex items-center gap-[var(--spacing-system-sf)]", className), children: [
|
|
10356
|
-
/* @__PURE__ */
|
|
10357
|
-
onClose && /* @__PURE__ */
|
|
10391
|
+
/* @__PURE__ */ jsx58("div", { className: "flex min-w-0 flex-1 flex-col", children }),
|
|
10392
|
+
onClose && /* @__PURE__ */ jsx58(
|
|
10358
10393
|
"button",
|
|
10359
10394
|
{
|
|
10360
10395
|
onClick: onClose,
|
|
10361
10396
|
className: "hidden shrink-0 text-ods-text-secondary transition-colors hover:text-ods-text-primary md:flex",
|
|
10362
10397
|
"aria-label": "Close",
|
|
10363
|
-
children: /* @__PURE__ */
|
|
10398
|
+
children: /* @__PURE__ */ jsx58(XmarkIcon, { className: "size-6" })
|
|
10364
10399
|
}
|
|
10365
10400
|
)
|
|
10366
10401
|
] });
|
|
10367
10402
|
});
|
|
10368
10403
|
ModalHeader.displayName = "ModalV2Header";
|
|
10369
|
-
var ModalTitle = forwardRef20(({ children, className }, ref) => /* @__PURE__ */
|
|
10404
|
+
var ModalTitle = forwardRef20(({ children, className }, ref) => /* @__PURE__ */ jsx58("h2", { ref, className: cn("text-ods-text-primary text-h2", className), children }));
|
|
10370
10405
|
ModalTitle.displayName = "ModalV2Title";
|
|
10371
|
-
var ModalFooter = forwardRef20(({ children, className }, ref) => /* @__PURE__ */
|
|
10406
|
+
var ModalFooter = forwardRef20(({ children, className }, ref) => /* @__PURE__ */ jsx58("div", { ref, className: cn("flex gap-4", className), children }));
|
|
10372
10407
|
ModalFooter.displayName = "ModalV2Footer";
|
|
10373
10408
|
|
|
10374
10409
|
// src/components/chat/mingo-chat-modals.tsx
|
|
10375
|
-
import { Fragment as Fragment14, jsx as
|
|
10410
|
+
import { Fragment as Fragment14, jsx as jsx59, jsxs as jsxs45 } from "react/jsx-runtime";
|
|
10376
10411
|
var footerBtn = "flex-1 min-w-0 rounded-md px-[var(--spacing-system-m)] py-[var(--spacing-system-sf)] text-h3 transition-colors focus:outline-none focus-visible:ring-2 focus-visible:ring-ods-accent disabled:opacity-50 disabled:cursor-not-allowed";
|
|
10377
10412
|
var cancelBtn = cn(footerBtn, "border border-ods-border bg-transparent text-ods-text-primary hover:bg-ods-bg-hover");
|
|
10378
10413
|
var saveBtn = cn(footerBtn, "bg-ods-accent text-ods-text-on-accent hover:bg-ods-accent-hover");
|
|
@@ -10389,10 +10424,10 @@ function RenameChatModal({ isOpen, initialName = "", onClose, onSave }) {
|
|
|
10389
10424
|
if (canSave) onSave(name.trim());
|
|
10390
10425
|
};
|
|
10391
10426
|
return /* @__PURE__ */ jsxs45(Modal, { isOpen, onClose, className: "md:max-w-[600px]", children: [
|
|
10392
|
-
/* @__PURE__ */
|
|
10427
|
+
/* @__PURE__ */ jsx59(ModalHeader, { children: /* @__PURE__ */ jsx59(ModalTitle, { children: "Rename Chat" }) }),
|
|
10393
10428
|
/* @__PURE__ */ jsxs45("div", { className: "flex w-full flex-col gap-[var(--spacing-system-xxs)]", children: [
|
|
10394
|
-
/* @__PURE__ */
|
|
10395
|
-
/* @__PURE__ */
|
|
10429
|
+
/* @__PURE__ */ jsx59("label", { htmlFor: "rename-chat-input", className: "text-ods-text-primary text-h4", children: "Chat Name" }),
|
|
10430
|
+
/* @__PURE__ */ jsx59(
|
|
10396
10431
|
"input",
|
|
10397
10432
|
{
|
|
10398
10433
|
id: "rename-chat-input",
|
|
@@ -10407,28 +10442,28 @@ function RenameChatModal({ isOpen, initialName = "", onClose, onSave }) {
|
|
|
10407
10442
|
)
|
|
10408
10443
|
] }),
|
|
10409
10444
|
/* @__PURE__ */ jsxs45(ModalFooter, { children: [
|
|
10410
|
-
/* @__PURE__ */
|
|
10411
|
-
/* @__PURE__ */
|
|
10445
|
+
/* @__PURE__ */ jsx59("button", { type: "button", onClick: onClose, className: cancelBtn, children: "Cancel" }),
|
|
10446
|
+
/* @__PURE__ */ jsx59("button", { type: "button", onClick: save, disabled: !canSave, className: saveBtn, children: "Save" })
|
|
10412
10447
|
] })
|
|
10413
10448
|
] });
|
|
10414
10449
|
}
|
|
10415
10450
|
function ArchiveChatModal({ isOpen, onClose, onConfirm }) {
|
|
10416
10451
|
return /* @__PURE__ */ jsxs45(Modal, { isOpen, onClose, className: "md:max-w-[600px]", children: [
|
|
10417
|
-
/* @__PURE__ */
|
|
10418
|
-
/* @__PURE__ */
|
|
10452
|
+
/* @__PURE__ */ jsx59(ModalHeader, { children: /* @__PURE__ */ jsx59(ModalTitle, { children: "Archive Chat" }) }),
|
|
10453
|
+
/* @__PURE__ */ jsx59("p", { className: "w-full text-ods-text-primary text-h4", children: "This chat will be hidden from your current chats." }),
|
|
10419
10454
|
/* @__PURE__ */ jsxs45(ModalFooter, { children: [
|
|
10420
|
-
/* @__PURE__ */
|
|
10421
|
-
/* @__PURE__ */
|
|
10455
|
+
/* @__PURE__ */ jsx59("button", { type: "button", onClick: onClose, className: cancelBtn, children: "Cancel" }),
|
|
10456
|
+
/* @__PURE__ */ jsx59("button", { type: "button", onClick: onConfirm, className: dangerBtn, children: "Archive Chat" })
|
|
10422
10457
|
] })
|
|
10423
10458
|
] });
|
|
10424
10459
|
}
|
|
10425
10460
|
function UnarchiveChatModal({ isOpen, onClose, onConfirm }) {
|
|
10426
10461
|
return /* @__PURE__ */ jsxs45(Modal, { isOpen, onClose, className: "md:max-w-[600px]", children: [
|
|
10427
|
-
/* @__PURE__ */
|
|
10428
|
-
/* @__PURE__ */
|
|
10462
|
+
/* @__PURE__ */ jsx59(ModalHeader, { children: /* @__PURE__ */ jsx59(ModalTitle, { children: "Unarchive Chat" }) }),
|
|
10463
|
+
/* @__PURE__ */ jsx59("p", { className: "w-full text-ods-text-primary text-h4", children: "This chat will be moved back to your current chats." }),
|
|
10429
10464
|
/* @__PURE__ */ jsxs45(ModalFooter, { children: [
|
|
10430
|
-
/* @__PURE__ */
|
|
10431
|
-
/* @__PURE__ */
|
|
10465
|
+
/* @__PURE__ */ jsx59("button", { type: "button", onClick: onClose, className: cancelBtn, children: "Cancel" }),
|
|
10466
|
+
/* @__PURE__ */ jsx59("button", { type: "button", onClick: onConfirm, className: saveBtn, children: "Unarchive Chat" })
|
|
10432
10467
|
] })
|
|
10433
10468
|
] });
|
|
10434
10469
|
}
|
|
@@ -10444,7 +10479,7 @@ function ChatDialogModals({
|
|
|
10444
10479
|
onConfirmRestore
|
|
10445
10480
|
}) {
|
|
10446
10481
|
return /* @__PURE__ */ jsxs45(Fragment14, { children: [
|
|
10447
|
-
/* @__PURE__ */
|
|
10482
|
+
/* @__PURE__ */ jsx59(
|
|
10448
10483
|
RenameChatModal,
|
|
10449
10484
|
{
|
|
10450
10485
|
isOpen: renameTarget != null,
|
|
@@ -10453,7 +10488,7 @@ function ChatDialogModals({
|
|
|
10453
10488
|
onSave: onConfirmRename
|
|
10454
10489
|
}
|
|
10455
10490
|
),
|
|
10456
|
-
/* @__PURE__ */
|
|
10491
|
+
/* @__PURE__ */ jsx59(
|
|
10457
10492
|
ArchiveChatModal,
|
|
10458
10493
|
{
|
|
10459
10494
|
isOpen: archiveTarget != null,
|
|
@@ -10461,7 +10496,7 @@ function ChatDialogModals({
|
|
|
10461
10496
|
onConfirm: onConfirmArchive
|
|
10462
10497
|
}
|
|
10463
10498
|
),
|
|
10464
|
-
/* @__PURE__ */
|
|
10499
|
+
/* @__PURE__ */ jsx59(
|
|
10465
10500
|
UnarchiveChatModal,
|
|
10466
10501
|
{
|
|
10467
10502
|
isOpen: restoreTarget != null,
|
|
@@ -10474,9 +10509,9 @@ function ChatDialogModals({
|
|
|
10474
10509
|
|
|
10475
10510
|
// src/components/chat/chat-header-icon-button.tsx
|
|
10476
10511
|
import { forwardRef as forwardRef21 } from "react";
|
|
10477
|
-
import { jsx as
|
|
10512
|
+
import { jsx as jsx60 } from "react/jsx-runtime";
|
|
10478
10513
|
var ChatHeaderIconButton = forwardRef21(
|
|
10479
|
-
({ className, children, type = "button", divider = "left", ...props }, ref) => /* @__PURE__ */
|
|
10514
|
+
({ className, children, type = "button", divider = "left", ...props }, ref) => /* @__PURE__ */ jsx60(
|
|
10480
10515
|
"button",
|
|
10481
10516
|
{
|
|
10482
10517
|
ref,
|
|
@@ -10498,7 +10533,7 @@ ChatHeaderIconButton.displayName = "ChatHeaderIconButton";
|
|
|
10498
10533
|
|
|
10499
10534
|
// src/components/chat/chat-header-search-field.tsx
|
|
10500
10535
|
import { useState as useState23, useRef as useRef12, useEffect as useEffect13, useCallback as useCallback10 } from "react";
|
|
10501
|
-
import { jsx as
|
|
10536
|
+
import { jsx as jsx61, jsxs as jsxs46 } from "react/jsx-runtime";
|
|
10502
10537
|
function ChatHeaderSearchField({
|
|
10503
10538
|
initialValue,
|
|
10504
10539
|
onSearchChange,
|
|
@@ -10550,14 +10585,14 @@ function ChatHeaderSearchField({
|
|
|
10550
10585
|
className
|
|
10551
10586
|
),
|
|
10552
10587
|
children: [
|
|
10553
|
-
/* @__PURE__ */
|
|
10588
|
+
/* @__PURE__ */ jsx61(
|
|
10554
10589
|
SearchIcon,
|
|
10555
10590
|
{
|
|
10556
10591
|
size: 24,
|
|
10557
10592
|
className: "shrink-0 text-ods-text-secondary duration-300 ease-out animate-in fade-in-0 zoom-in-75"
|
|
10558
10593
|
}
|
|
10559
10594
|
),
|
|
10560
|
-
/* @__PURE__ */
|
|
10595
|
+
/* @__PURE__ */ jsx61(
|
|
10561
10596
|
"input",
|
|
10562
10597
|
{
|
|
10563
10598
|
autoFocus,
|
|
@@ -10594,7 +10629,7 @@ function ChatHeaderSearchField({
|
|
|
10594
10629
|
}
|
|
10595
10630
|
|
|
10596
10631
|
// src/components/chat/chat-panel-header-mobile.tsx
|
|
10597
|
-
import { jsx as
|
|
10632
|
+
import { jsx as jsx62, jsxs as jsxs47 } from "react/jsx-runtime";
|
|
10598
10633
|
function ChatPanelHeaderMobile({
|
|
10599
10634
|
showBack = false,
|
|
10600
10635
|
title,
|
|
@@ -10605,6 +10640,7 @@ function ChatPanelHeaderMobile({
|
|
|
10605
10640
|
onRestore,
|
|
10606
10641
|
onRename,
|
|
10607
10642
|
onArchive,
|
|
10643
|
+
onCompact,
|
|
10608
10644
|
onCopyLink,
|
|
10609
10645
|
onOpenArchive,
|
|
10610
10646
|
className
|
|
@@ -10612,16 +10648,14 @@ function ChatPanelHeaderMobile({
|
|
|
10612
10648
|
const menuItems = [
|
|
10613
10649
|
!showBack && onOpenArchive && {
|
|
10614
10650
|
id: "open-archive",
|
|
10615
|
-
label: "Chat
|
|
10616
|
-
icon: /* @__PURE__ */
|
|
10651
|
+
label: "Chat Archive",
|
|
10652
|
+
icon: /* @__PURE__ */ jsx62(ClockHistoryIcon, { className: chatMenuIconClassName }),
|
|
10617
10653
|
onClick: onOpenArchive
|
|
10618
10654
|
},
|
|
10619
|
-
isArchivedView && onRestore && { id: "unarchive", label: "Unarchive
|
|
10620
|
-
|
|
10621
|
-
|
|
10622
|
-
|
|
10623
|
-
].filter(Boolean);
|
|
10624
|
-
return /* @__PURE__ */ jsx61(
|
|
10655
|
+
isArchivedView && onRestore && { id: "unarchive", label: "Unarchive Chat", onClick: onRestore },
|
|
10656
|
+
...isArchivedView ? [] : chatDialogMenuItems({ onCopyLink, onRename, onCompact, onArchive })
|
|
10657
|
+
].filter((item) => !!item);
|
|
10658
|
+
return /* @__PURE__ */ jsx62(
|
|
10625
10659
|
"div",
|
|
10626
10660
|
{
|
|
10627
10661
|
className: cn(
|
|
@@ -10630,10 +10664,10 @@ function ChatPanelHeaderMobile({
|
|
|
10630
10664
|
className
|
|
10631
10665
|
),
|
|
10632
10666
|
children: /* @__PURE__ */ jsxs47("div", { className: "flex w-full items-end gap-[var(--spacing-system-sf)]", children: [
|
|
10633
|
-
showBack && /* @__PURE__ */
|
|
10667
|
+
showBack && /* @__PURE__ */ jsx62(Button, { variant: "outline", size: "icon", "aria-label": backAriaLabel, onClick: onBack, className: "shrink-0", children: /* @__PURE__ */ jsx62(Chevron02LeftIcon, {}) }),
|
|
10634
10668
|
/* @__PURE__ */ jsxs47("div", { className: "flex min-w-0 flex-1 items-end gap-[var(--spacing-system-m)] pt-[var(--spacing-system-xl)]", children: [
|
|
10635
|
-
/* @__PURE__ */
|
|
10636
|
-
menuItems.length > 0 && /* @__PURE__ */
|
|
10669
|
+
/* @__PURE__ */ jsx62("div", { className: "flex min-w-0 flex-1 flex-col gap-[var(--spacing-system-xs)]", children: /* @__PURE__ */ jsx62("p", { className: "min-w-0 truncate text-ods-text-primary text-h2", title, children: title }) }),
|
|
10670
|
+
menuItems.length > 0 && /* @__PURE__ */ jsx62(
|
|
10637
10671
|
ActionsMenuDropdown,
|
|
10638
10672
|
{
|
|
10639
10673
|
groups: [{ items: menuItems }],
|
|
@@ -10641,7 +10675,7 @@ function ChatPanelHeaderMobile({
|
|
|
10641
10675
|
triggerClassName: "flex shrink-0 items-center justify-center border-ods-border bg-ods-card hover:bg-ods-bg-hover focus-visible:ring-0"
|
|
10642
10676
|
}
|
|
10643
10677
|
),
|
|
10644
|
-
onClose && /* @__PURE__ */
|
|
10678
|
+
onClose && /* @__PURE__ */ jsx62(Button, { variant: "outline", size: "icon", "aria-label": "Close chat", onClick: onClose, className: "shrink-0", children: /* @__PURE__ */ jsx62(XmarkIcon, {}) })
|
|
10645
10679
|
] })
|
|
10646
10680
|
] })
|
|
10647
10681
|
}
|
|
@@ -10649,7 +10683,7 @@ function ChatPanelHeaderMobile({
|
|
|
10649
10683
|
}
|
|
10650
10684
|
|
|
10651
10685
|
// src/components/chat/chat-panel-header.tsx
|
|
10652
|
-
import { Fragment as Fragment15, jsx as
|
|
10686
|
+
import { Fragment as Fragment15, jsx as jsx63, jsxs as jsxs48 } from "react/jsx-runtime";
|
|
10653
10687
|
function ChatPanelHeader({
|
|
10654
10688
|
showBack = false,
|
|
10655
10689
|
title,
|
|
@@ -10662,6 +10696,7 @@ function ChatPanelHeader({
|
|
|
10662
10696
|
onRestore,
|
|
10663
10697
|
onRename,
|
|
10664
10698
|
onArchive,
|
|
10699
|
+
onCompact,
|
|
10665
10700
|
onCopyLink,
|
|
10666
10701
|
onOpenArchive,
|
|
10667
10702
|
compact = false,
|
|
@@ -10671,13 +10706,9 @@ function ChatPanelHeader({
|
|
|
10671
10706
|
onSearchChange
|
|
10672
10707
|
}) {
|
|
10673
10708
|
const searchInline = searchActive && !!onSearchChange;
|
|
10674
|
-
const menuItems =
|
|
10675
|
-
onCopyLink && { id: "copy-link", label: "Copy chat link", onClick: onCopyLink },
|
|
10676
|
-
onRename && { id: "rename", label: "Rename chat", onClick: onRename },
|
|
10677
|
-
onArchive && { id: "archive", label: "Archive chat", onClick: onArchive }
|
|
10678
|
-
].filter(Boolean);
|
|
10709
|
+
const menuItems = chatDialogMenuItems({ onCopyLink, onRename, onCompact, onArchive });
|
|
10679
10710
|
return /* @__PURE__ */ jsxs48(Fragment15, { children: [
|
|
10680
|
-
!compact && /* @__PURE__ */
|
|
10711
|
+
!compact && /* @__PURE__ */ jsx63(
|
|
10681
10712
|
ChatPanelHeaderMobile,
|
|
10682
10713
|
{
|
|
10683
10714
|
className: "flex md:hidden",
|
|
@@ -10691,6 +10722,7 @@ function ChatPanelHeader({
|
|
|
10691
10722
|
onRestore,
|
|
10692
10723
|
onRename,
|
|
10693
10724
|
onArchive,
|
|
10725
|
+
onCompact,
|
|
10694
10726
|
onCopyLink,
|
|
10695
10727
|
onOpenArchive
|
|
10696
10728
|
}
|
|
@@ -10703,11 +10735,11 @@ function ChatPanelHeader({
|
|
|
10703
10735
|
compact ? "flex" : "hidden md:flex"
|
|
10704
10736
|
),
|
|
10705
10737
|
children: [
|
|
10706
|
-
showBack && /* @__PURE__ */
|
|
10738
|
+
showBack && /* @__PURE__ */ jsx63(ChatHeaderIconButton, { divider: "right", onClick: onBack, "aria-label": backAriaLabel, children: /* @__PURE__ */ jsx63(Chevron02LeftIcon, { size: 24 }) }),
|
|
10707
10739
|
searchInline ? (
|
|
10708
10740
|
// Search open — the inline field takes over the title area in place
|
|
10709
10741
|
// (Figma 116:51217); the magnifier toggle below is hidden.
|
|
10710
|
-
/* @__PURE__ */
|
|
10742
|
+
/* @__PURE__ */ jsx63(
|
|
10711
10743
|
ChatHeaderSearchField,
|
|
10712
10744
|
{
|
|
10713
10745
|
initialValue: searchQuery,
|
|
@@ -10717,12 +10749,12 @@ function ChatPanelHeader({
|
|
|
10717
10749
|
)
|
|
10718
10750
|
) : /* @__PURE__ */ jsxs48("div", { className: "flex min-w-0 flex-1 items-center gap-[var(--spacing-system-m)] px-[var(--spacing-system-mf)] py-[var(--spacing-system-sf)]", children: [
|
|
10719
10751
|
/* @__PURE__ */ jsxs48("div", { className: "flex min-w-0 flex-col", children: [
|
|
10720
|
-
/* @__PURE__ */
|
|
10721
|
-
subtitle && /* @__PURE__ */
|
|
10752
|
+
/* @__PURE__ */ jsx63("p", { className: "truncate leading-tight text-ods-text-primary text-h3", children: title }),
|
|
10753
|
+
subtitle && /* @__PURE__ */ jsx63("p", { className: "truncate leading-tight text-ods-text-secondary text-h6", children: subtitle })
|
|
10722
10754
|
] }),
|
|
10723
10755
|
avatar && (avatar.name || avatar.avatarUrl) ? (
|
|
10724
10756
|
// Owner avatar at the title cell's right edge (Figma 113:63273).
|
|
10725
|
-
/* @__PURE__ */
|
|
10757
|
+
/* @__PURE__ */ jsx63(
|
|
10726
10758
|
SquareAvatar,
|
|
10727
10759
|
{
|
|
10728
10760
|
variant: "round",
|
|
@@ -10737,19 +10769,19 @@ function ChatPanelHeader({
|
|
|
10737
10769
|
)
|
|
10738
10770
|
) : null
|
|
10739
10771
|
] }),
|
|
10740
|
-
isArchivedView && onRestore && /* @__PURE__ */
|
|
10741
|
-
showBack && !isArchivedView && menuItems.length > 0 && /* @__PURE__ */
|
|
10772
|
+
isArchivedView && onRestore && /* @__PURE__ */ jsx63(ChatHeaderIconButton, { onClick: onRestore, "aria-label": "Unarchive chat", children: /* @__PURE__ */ jsx63(Refresh01LeftIcon, { size: 24 }) }),
|
|
10773
|
+
showBack && !isArchivedView && menuItems.length > 0 && /* @__PURE__ */ jsx63(
|
|
10742
10774
|
ActionsMenuDropdown,
|
|
10743
10775
|
{
|
|
10744
10776
|
triggerAriaLabel: "Chat actions",
|
|
10745
10777
|
onCloseAutoFocus: (e) => e.preventDefault(),
|
|
10746
10778
|
groups: [{ items: menuItems }],
|
|
10747
|
-
customTrigger: /* @__PURE__ */
|
|
10779
|
+
customTrigger: /* @__PURE__ */ jsx63(ChatHeaderIconButton, { "aria-label": "Chat actions", children: /* @__PURE__ */ jsx63(Ellipsis01Icon, { size: 24 }) })
|
|
10748
10780
|
}
|
|
10749
10781
|
),
|
|
10750
|
-
!showBack && !searchInline && onToggleSearch && /* @__PURE__ */
|
|
10751
|
-
!showBack && onOpenArchive && /* @__PURE__ */
|
|
10752
|
-
/* @__PURE__ */
|
|
10782
|
+
!showBack && !searchInline && onToggleSearch && /* @__PURE__ */ jsx63(ChatHeaderIconButton, { onClick: onToggleSearch, "aria-label": "Search chats", "aria-pressed": searchActive, children: /* @__PURE__ */ jsx63(SearchIcon, { size: 24 }) }),
|
|
10783
|
+
!showBack && onOpenArchive && /* @__PURE__ */ jsx63(ChatHeaderIconButton, { onClick: onOpenArchive, "aria-label": "Chat archive", children: /* @__PURE__ */ jsx63(ClockHistoryIcon, { size: 24 }) }),
|
|
10784
|
+
/* @__PURE__ */ jsx63(ChatHeaderIconButton, { onClick: onClose, "aria-label": "Close", children: /* @__PURE__ */ jsx63(XmarkIcon, { size: 24 }) })
|
|
10753
10785
|
]
|
|
10754
10786
|
}
|
|
10755
10787
|
)
|
|
@@ -10814,7 +10846,7 @@ function stripChatAttachmentMarkdown(text2) {
|
|
|
10814
10846
|
}
|
|
10815
10847
|
|
|
10816
10848
|
// src/components/chat/chat-attachment-bar.tsx
|
|
10817
|
-
import { Fragment as Fragment16, jsx as
|
|
10849
|
+
import { Fragment as Fragment16, jsx as jsx64, jsxs as jsxs49 } from "react/jsx-runtime";
|
|
10818
10850
|
var CHAT_ATTACHMENT_MIME_TYPES = [
|
|
10819
10851
|
"image/jpeg",
|
|
10820
10852
|
"image/png",
|
|
@@ -10836,7 +10868,7 @@ function ChatAttachmentAddButton({
|
|
|
10836
10868
|
const compact = size2 === "compact";
|
|
10837
10869
|
const boxClass = compact ? "h-6 w-6" : "h-7 w-7";
|
|
10838
10870
|
if (!attachmentsEnabled) {
|
|
10839
|
-
return /* @__PURE__ */
|
|
10871
|
+
return /* @__PURE__ */ jsx64("span", { "aria-hidden": "true", className: cn("inline-block shrink-0", boxClass) });
|
|
10840
10872
|
}
|
|
10841
10873
|
const slotsAvailable = Math.max(0, CHAT_ATTACHMENT_CONCURRENT_UPLOADS_PER_USER - attachmentsCount);
|
|
10842
10874
|
const canAddMore = slotsAvailable > 0 && !disabled;
|
|
@@ -10845,7 +10877,7 @@ function ChatAttachmentAddButton({
|
|
|
10845
10877
|
fileInputRef.current?.click();
|
|
10846
10878
|
};
|
|
10847
10879
|
return /* @__PURE__ */ jsxs49(Fragment16, { children: [
|
|
10848
|
-
/* @__PURE__ */
|
|
10880
|
+
/* @__PURE__ */ jsx64(
|
|
10849
10881
|
"input",
|
|
10850
10882
|
{
|
|
10851
10883
|
ref: fileInputRef,
|
|
@@ -10863,7 +10895,7 @@ function ChatAttachmentAddButton({
|
|
|
10863
10895
|
}
|
|
10864
10896
|
}
|
|
10865
10897
|
),
|
|
10866
|
-
/* @__PURE__ */
|
|
10898
|
+
/* @__PURE__ */ jsx64(
|
|
10867
10899
|
Button,
|
|
10868
10900
|
{
|
|
10869
10901
|
type: "button",
|
|
@@ -10873,7 +10905,7 @@ function ChatAttachmentAddButton({
|
|
|
10873
10905
|
disabled: !canAddMore,
|
|
10874
10906
|
"aria-label": canAddMore ? "Add attachments" : "Attachment limit reached",
|
|
10875
10907
|
title: canAddMore ? "Add attachments" : `Limit reached (${CHAT_ATTACHMENT_CONCURRENT_UPLOADS_PER_USER})`,
|
|
10876
|
-
leftIcon: /* @__PURE__ */
|
|
10908
|
+
leftIcon: /* @__PURE__ */ jsx64(PlusIcon, { className: compact ? "h-3.5 w-3.5" : "h-4 w-4" }),
|
|
10877
10909
|
className: cn(
|
|
10878
10910
|
"shrink-0 !p-0 text-ods-text-muted hover:text-ods-text-primary",
|
|
10879
10911
|
compact ? "!h-6 !w-6" : "!h-7 !w-7"
|
|
@@ -10890,7 +10922,7 @@ function ChatAttachmentChipStrip({
|
|
|
10890
10922
|
}) {
|
|
10891
10923
|
if (attachments.length === 0) return null;
|
|
10892
10924
|
const compact = size2 === "compact";
|
|
10893
|
-
return /* @__PURE__ */
|
|
10925
|
+
return /* @__PURE__ */ jsx64("div", { className: cn("flex-shrink-0", compact ? "px-3 pb-1.5" : "px-5 pb-2"), children: /* @__PURE__ */ jsx64("div", { className: cn("flex flex-wrap items-center", compact ? "gap-1.5" : "gap-2"), children: attachments.map((att) => /* @__PURE__ */ jsx64(
|
|
10894
10926
|
AttachmentChip,
|
|
10895
10927
|
{
|
|
10896
10928
|
attachment: att,
|
|
@@ -10920,8 +10952,8 @@ function AttachmentChip({ attachment, onRemove, disabled, size: size2 = "default
|
|
|
10920
10952
|
isImage && blobUrl ? (
|
|
10921
10953
|
// cannot go through next/image; this is a transient pre-upload
|
|
10922
10954
|
// preview, NOT the chat-history render path.
|
|
10923
|
-
/* @__PURE__ */
|
|
10924
|
-
) : /* @__PURE__ */
|
|
10955
|
+
/* @__PURE__ */ jsx64("img", { src: blobUrl, alt: file.name, className: "h-full w-full object-cover" })
|
|
10956
|
+
) : /* @__PURE__ */ jsx64(
|
|
10925
10957
|
"div",
|
|
10926
10958
|
{
|
|
10927
10959
|
className: cn(
|
|
@@ -10931,18 +10963,18 @@ function AttachmentChip({ attachment, onRemove, disabled, size: size2 = "default
|
|
|
10931
10963
|
children: extLabel(file.name)
|
|
10932
10964
|
}
|
|
10933
10965
|
),
|
|
10934
|
-
status === "uploading" && /* @__PURE__ */
|
|
10966
|
+
status === "uploading" && /* @__PURE__ */ jsx64("div", { className: "absolute inset-x-0 bottom-0 h-1 bg-ods-bg", children: /* @__PURE__ */ jsx64("div", { className: "h-full bg-ods-accent transition-[width]", style: { width: `${progress}%` } }) })
|
|
10935
10967
|
] }),
|
|
10936
10968
|
/* @__PURE__ */ jsxs49("div", { className: "min-w-0 flex-1", children: [
|
|
10937
|
-
/* @__PURE__ */
|
|
10969
|
+
/* @__PURE__ */ jsx64("div", { className: "truncate text-ods-text-primary text-h6", title: file.name, children: file.name }),
|
|
10938
10970
|
(!compact || status !== "ready") && /* @__PURE__ */ jsxs49("div", { className: "text-ods-text-muted text-h6", children: [
|
|
10939
10971
|
status === "sniffing" && "Checking\u2026",
|
|
10940
10972
|
status === "uploading" && `${progress}% \xB7 ${formatFileSize(file.size)}`,
|
|
10941
10973
|
status === "ready" && formatFileSize(file.size),
|
|
10942
|
-
status === "error" && /* @__PURE__ */
|
|
10974
|
+
status === "error" && /* @__PURE__ */ jsx64("span", { className: "text-ods-error", title: errorMessage, children: errorMessage ?? "Upload failed" })
|
|
10943
10975
|
] })
|
|
10944
10976
|
] }),
|
|
10945
|
-
/* @__PURE__ */
|
|
10977
|
+
/* @__PURE__ */ jsx64(
|
|
10946
10978
|
Button,
|
|
10947
10979
|
{
|
|
10948
10980
|
type: "button",
|
|
@@ -10951,7 +10983,7 @@ function AttachmentChip({ attachment, onRemove, disabled, size: size2 = "default
|
|
|
10951
10983
|
onClick: onRemove,
|
|
10952
10984
|
disabled,
|
|
10953
10985
|
"aria-label": `Remove ${file.name}`,
|
|
10954
|
-
leftIcon: /* @__PURE__ */
|
|
10986
|
+
leftIcon: /* @__PURE__ */ jsx64(XmarkIcon, { className: compact ? "h-3 w-3" : "h-3.5 w-3.5" }),
|
|
10955
10987
|
className: cn(
|
|
10956
10988
|
"shrink-0 !p-0 text-ods-text-muted hover:text-ods-text-primary",
|
|
10957
10989
|
compact ? "!h-4 !w-4" : "!h-5 !w-5"
|
|
@@ -10990,7 +11022,7 @@ function useObjectUrl(file) {
|
|
|
10990
11022
|
|
|
10991
11023
|
// src/components/chat/chat-context-memory-bar.tsx
|
|
10992
11024
|
import { useEffect as useEffect15, useRef as useRef14, useState as useState24 } from "react";
|
|
10993
|
-
import { jsx as
|
|
11025
|
+
import { jsx as jsx65, jsxs as jsxs50 } from "react/jsx-runtime";
|
|
10994
11026
|
var itemKey3 = (item) => `${item.type}:${item.id}`;
|
|
10995
11027
|
function ChatContextMemoryBar({
|
|
10996
11028
|
items,
|
|
@@ -11040,7 +11072,7 @@ function ChatContextMemoryBar({
|
|
|
11040
11072
|
items.length === 1 ? "item" : "items",
|
|
11041
11073
|
" in context"
|
|
11042
11074
|
] }),
|
|
11043
|
-
/* @__PURE__ */
|
|
11075
|
+
/* @__PURE__ */ jsx65(
|
|
11044
11076
|
"button",
|
|
11045
11077
|
{
|
|
11046
11078
|
type: "button",
|
|
@@ -11053,10 +11085,10 @@ function ChatContextMemoryBar({
|
|
|
11053
11085
|
open ? "text-ods-text-primary" : "text-ods-text-secondary hover:text-ods-text-primary",
|
|
11054
11086
|
"focus-visible:text-ods-text-primary"
|
|
11055
11087
|
),
|
|
11056
|
-
children: /* @__PURE__ */
|
|
11088
|
+
children: /* @__PURE__ */ jsx65(Ellipsis01Icon, { size: 16 })
|
|
11057
11089
|
}
|
|
11058
11090
|
),
|
|
11059
|
-
open && /* @__PURE__ */
|
|
11091
|
+
open && /* @__PURE__ */ jsx65(
|
|
11060
11092
|
"div",
|
|
11061
11093
|
{
|
|
11062
11094
|
role: "list",
|
|
@@ -11066,9 +11098,9 @@ function ChatContextMemoryBar({
|
|
|
11066
11098
|
// Not a `<button>`: the row itself is inert (only the `×` acts), so
|
|
11067
11099
|
// the remove control isn't nested inside another button.
|
|
11068
11100
|
/* @__PURE__ */ jsxs50("div", { role: "listitem", className: CONTEXT_ROW_CLASS, children: [
|
|
11069
|
-
resolveIcon2 && /* @__PURE__ */
|
|
11070
|
-
/* @__PURE__ */
|
|
11071
|
-
onRemove && /* @__PURE__ */
|
|
11101
|
+
resolveIcon2 && /* @__PURE__ */ jsx65("span", { className: CONTEXT_ICON_CLASS, children: resolveIcon2(item) }),
|
|
11102
|
+
/* @__PURE__ */ jsx65("span", { className: CONTEXT_LABEL_CLASS, title: item.label, children: item.label }),
|
|
11103
|
+
onRemove && /* @__PURE__ */ jsx65(
|
|
11072
11104
|
"button",
|
|
11073
11105
|
{
|
|
11074
11106
|
type: "button",
|
|
@@ -11076,7 +11108,7 @@ function ChatContextMemoryBar({
|
|
|
11076
11108
|
disabled,
|
|
11077
11109
|
"aria-label": `Remove ${item.label} from context`,
|
|
11078
11110
|
className: "flex size-4 shrink-0 items-center justify-center text-ods-text-secondary outline-none transition-colors hover:text-ods-text-primary focus-visible:text-ods-text-primary disabled:cursor-not-allowed disabled:opacity-40 md:size-6",
|
|
11079
|
-
children: /* @__PURE__ */
|
|
11111
|
+
children: /* @__PURE__ */ jsx65(XmarkCircleIcon, { className: "size-4 shrink-0 md:size-6" })
|
|
11080
11112
|
}
|
|
11081
11113
|
)
|
|
11082
11114
|
] }, itemKey3(item))
|
|
@@ -11095,7 +11127,7 @@ import React3 from "react";
|
|
|
11095
11127
|
// src/components/hover-card.tsx
|
|
11096
11128
|
import * as HoverCardPrimitive from "@radix-ui/react-hover-card";
|
|
11097
11129
|
import { forwardRef as forwardRef22 } from "react";
|
|
11098
|
-
import { jsx as
|
|
11130
|
+
import { jsx as jsx66 } from "react/jsx-runtime";
|
|
11099
11131
|
var HoverCard = HoverCardPrimitive.Root;
|
|
11100
11132
|
var HoverCardTrigger = HoverCardPrimitive.Trigger;
|
|
11101
11133
|
var HoverCardContent = forwardRef22(
|
|
@@ -11114,7 +11146,7 @@ var HoverCardContent = forwardRef22(
|
|
|
11114
11146
|
}, ref) => (
|
|
11115
11147
|
// Portalled so an `overflow: hidden` ancestor (a table cell, a card) cannot
|
|
11116
11148
|
// clip it.
|
|
11117
|
-
/* @__PURE__ */
|
|
11149
|
+
/* @__PURE__ */ jsx66(HoverCardPrimitive.Portal, { container: usePortalContainer(), children: /* @__PURE__ */ jsx66(
|
|
11118
11150
|
HoverCardPrimitive.Content,
|
|
11119
11151
|
{
|
|
11120
11152
|
ref,
|
|
@@ -11141,21 +11173,21 @@ var HoverCardContent = forwardRef22(
|
|
|
11141
11173
|
HoverCardContent.displayName = HoverCardPrimitive.Content.displayName;
|
|
11142
11174
|
|
|
11143
11175
|
// src/components/chat/model-display.tsx
|
|
11144
|
-
import { jsx as
|
|
11176
|
+
import { jsx as jsx67, jsxs as jsxs51 } from "react/jsx-runtime";
|
|
11145
11177
|
var getProviderIcon = (provider) => {
|
|
11146
11178
|
if (!provider) return null;
|
|
11147
11179
|
const providerLower = provider.toLowerCase();
|
|
11148
11180
|
switch (providerLower) {
|
|
11149
11181
|
case "anthropic":
|
|
11150
11182
|
case "claude":
|
|
11151
|
-
return /* @__PURE__ */
|
|
11183
|
+
return /* @__PURE__ */ jsx67(AnthropicLogoGreyIcon, { className: "h-4 w-4" });
|
|
11152
11184
|
case "openai":
|
|
11153
|
-
return /* @__PURE__ */
|
|
11185
|
+
return /* @__PURE__ */ jsx67(OpenaiLogoGreyIcon, { size: 16, color: "currentColor" });
|
|
11154
11186
|
case "google":
|
|
11155
11187
|
case "gemini":
|
|
11156
11188
|
case "google-gemini":
|
|
11157
11189
|
case "google_gemini":
|
|
11158
|
-
return /* @__PURE__ */
|
|
11190
|
+
return /* @__PURE__ */ jsx67(GeminiLogoGreyIcon, { size: 16 });
|
|
11159
11191
|
default:
|
|
11160
11192
|
return null;
|
|
11161
11193
|
}
|
|
@@ -11189,8 +11221,8 @@ var ModelDisplay = React3.forwardRef(
|
|
|
11189
11221
|
const icon = getProviderIcon(provider);
|
|
11190
11222
|
const name = displayName || modelName;
|
|
11191
11223
|
const inline = /* @__PURE__ */ jsxs51("div", { ref, className: cn("flex items-center gap-1 text-ods-text-secondary", "text-h6", className), ...props, children: [
|
|
11192
|
-
icon && /* @__PURE__ */
|
|
11193
|
-
/* @__PURE__ */
|
|
11224
|
+
icon && /* @__PURE__ */ jsx67("span", { className: "flex items-center justify-center", children: icon }),
|
|
11225
|
+
/* @__PURE__ */ jsx67("span", { className: "font-body", children: name }),
|
|
11194
11226
|
contextWindow != null && /* @__PURE__ */ jsxs51("span", { className: "ml-auto opacity-70 text-h6", children: [
|
|
11195
11227
|
usedTokens != null ? formatTokenCount(usedTokens) : "\u2014",
|
|
11196
11228
|
"/",
|
|
@@ -11200,7 +11232,7 @@ var ModelDisplay = React3.forwardRef(
|
|
|
11200
11232
|
] });
|
|
11201
11233
|
if (!hasAnyBreakdownRow(breakdown)) return inline;
|
|
11202
11234
|
return /* @__PURE__ */ jsxs51(HoverCard, { openDelay: 150, closeDelay: 100, children: [
|
|
11203
|
-
/* @__PURE__ */
|
|
11235
|
+
/* @__PURE__ */ jsx67(HoverCardTrigger, { asChild: true, children: /* @__PURE__ */ jsx67("div", { className: "cursor-help", children: inline }) }),
|
|
11204
11236
|
/* @__PURE__ */ jsxs51(
|
|
11205
11237
|
HoverCardContent,
|
|
11206
11238
|
{
|
|
@@ -11208,9 +11240,9 @@ var ModelDisplay = React3.forwardRef(
|
|
|
11208
11240
|
align: "end",
|
|
11209
11241
|
sideOffset: 6,
|
|
11210
11242
|
children: [
|
|
11211
|
-
/* @__PURE__ */
|
|
11212
|
-
/* @__PURE__ */
|
|
11213
|
-
breakdown.haikuRewriter && /* @__PURE__ */
|
|
11243
|
+
/* @__PURE__ */ jsx67("div", { className: "mb-2 font-semibold text-ods-text-primary text-h6", children: "Token breakdown" }),
|
|
11244
|
+
/* @__PURE__ */ jsx67(BreakdownRow, { label: `Answer (${name ?? "model"})`, input: inputTokens, output: outputTokens, isAnswer: true }),
|
|
11245
|
+
breakdown.haikuRewriter && /* @__PURE__ */ jsx67(
|
|
11214
11246
|
BreakdownRow,
|
|
11215
11247
|
{
|
|
11216
11248
|
label: "Query rewriter (Haiku)",
|
|
@@ -11218,7 +11250,7 @@ var ModelDisplay = React3.forwardRef(
|
|
|
11218
11250
|
output: breakdown.haikuRewriter.output
|
|
11219
11251
|
}
|
|
11220
11252
|
),
|
|
11221
|
-
breakdown.haikuClassifier && /* @__PURE__ */
|
|
11253
|
+
breakdown.haikuClassifier && /* @__PURE__ */ jsx67(
|
|
11222
11254
|
BreakdownRow,
|
|
11223
11255
|
{
|
|
11224
11256
|
label: "Intent classifier (Haiku)",
|
|
@@ -11226,7 +11258,7 @@ var ModelDisplay = React3.forwardRef(
|
|
|
11226
11258
|
output: breakdown.haikuClassifier.output
|
|
11227
11259
|
}
|
|
11228
11260
|
),
|
|
11229
|
-
breakdown.haikuSummarizer && /* @__PURE__ */
|
|
11261
|
+
breakdown.haikuSummarizer && /* @__PURE__ */ jsx67(
|
|
11230
11262
|
BreakdownRow,
|
|
11231
11263
|
{
|
|
11232
11264
|
label: "History summarizer (Haiku)",
|
|
@@ -11252,7 +11284,7 @@ function BreakdownRow({
|
|
|
11252
11284
|
isAnswer
|
|
11253
11285
|
}) {
|
|
11254
11286
|
return /* @__PURE__ */ jsxs51("div", { className: "flex items-center justify-between py-1 text-h6", children: [
|
|
11255
|
-
/* @__PURE__ */
|
|
11287
|
+
/* @__PURE__ */ jsx67("span", { className: cn("text-ods-text-secondary", isAnswer && "font-medium text-ods-text-primary"), children: label }),
|
|
11256
11288
|
/* @__PURE__ */ jsxs51("span", { className: "tabular-nums text-ods-text-secondary", children: [
|
|
11257
11289
|
input != null ? formatTokenCount(input) : "\u2014",
|
|
11258
11290
|
" in / ",
|
|
@@ -11264,15 +11296,15 @@ function BreakdownRow({
|
|
|
11264
11296
|
ModelDisplay.displayName = "ModelDisplay";
|
|
11265
11297
|
var ModelDisplaySkeleton = React3.forwardRef(
|
|
11266
11298
|
({ className, showTokens = false, ...props }, ref) => /* @__PURE__ */ jsxs51("div", { ref, "aria-hidden": true, className: cn("flex items-center gap-1 text-h6", className), ...props, children: [
|
|
11267
|
-
/* @__PURE__ */
|
|
11268
|
-
/* @__PURE__ */
|
|
11269
|
-
showTokens && /* @__PURE__ */
|
|
11299
|
+
/* @__PURE__ */ jsx67(Skeleton, { className: "h-5 w-4 shrink-0 rounded-sm" }),
|
|
11300
|
+
/* @__PURE__ */ jsx67(Skeleton, { className: "h-5 w-24" }),
|
|
11301
|
+
showTokens && /* @__PURE__ */ jsx67(Skeleton, { className: "ml-auto h-3 w-32" })
|
|
11270
11302
|
] })
|
|
11271
11303
|
);
|
|
11272
11304
|
ModelDisplaySkeleton.displayName = "ModelDisplaySkeleton";
|
|
11273
11305
|
|
|
11274
11306
|
// src/components/chat/chat-composer.tsx
|
|
11275
|
-
import { jsx as
|
|
11307
|
+
import { jsx as jsx68, jsxs as jsxs52 } from "react/jsx-runtime";
|
|
11276
11308
|
function ChatComposer({
|
|
11277
11309
|
archived = false,
|
|
11278
11310
|
inputRef,
|
|
@@ -11311,7 +11343,7 @@ function ChatComposer({
|
|
|
11311
11343
|
return map;
|
|
11312
11344
|
}, [entityTypes]);
|
|
11313
11345
|
const resolveContextIcon = useCallback11((item) => iconByType.get(item.type), [iconByType]);
|
|
11314
|
-
const inputNode = /* @__PURE__ */
|
|
11346
|
+
const inputNode = /* @__PURE__ */ jsx68(
|
|
11315
11347
|
ChatInput,
|
|
11316
11348
|
{
|
|
11317
11349
|
ref: inputRef,
|
|
@@ -11328,13 +11360,13 @@ function ChatComposer({
|
|
|
11328
11360
|
onMentionQueryChange: contextEnabled ? onMentionQueryChange : void 0,
|
|
11329
11361
|
onValueChange: contextEnabled ? onValueChange : void 0,
|
|
11330
11362
|
hideBorder: contextEnabled,
|
|
11331
|
-
startIcon: contextEnabled ? /* @__PURE__ */
|
|
11363
|
+
startIcon: contextEnabled ? /* @__PURE__ */ jsx68(
|
|
11332
11364
|
ChatComposerPlusMenu,
|
|
11333
11365
|
{
|
|
11334
11366
|
onToggle: () => contextPickerOpen ? onCloseContextPicker?.() : onOpenContextPicker?.(),
|
|
11335
11367
|
open: contextPickerOpen,
|
|
11336
11368
|
disabled: attachmentsDisabled,
|
|
11337
|
-
dropdown: contextPicker ? /* @__PURE__ */
|
|
11369
|
+
dropdown: contextPicker ? /* @__PURE__ */ jsx68(
|
|
11338
11370
|
ChatContextPicker,
|
|
11339
11371
|
{
|
|
11340
11372
|
open: contextPickerOpen,
|
|
@@ -11357,9 +11389,9 @@ function ChatComposer({
|
|
|
11357
11389
|
paddingBottom: "max(var(--spacing-system-xxs), env(safe-area-inset-bottom))"
|
|
11358
11390
|
},
|
|
11359
11391
|
children: [
|
|
11360
|
-
/* @__PURE__ */
|
|
11361
|
-
/* @__PURE__ */
|
|
11362
|
-
/* @__PURE__ */
|
|
11392
|
+
/* @__PURE__ */ jsx68("div", { children: /* @__PURE__ */ jsx68(ChatFooter, { className: "!p-0", fullWidth: true, children: archived ? /* @__PURE__ */ jsxs52("div", { className: "flex w-full items-center justify-center gap-[var(--spacing-system-xs)] rounded-md border border-ods-border bg-ods-card p-[var(--spacing-system-sf)]", children: [
|
|
11393
|
+
/* @__PURE__ */ jsx68(BoxArchiveIcon, { size: 24, className: "shrink-0 text-ods-text-secondary" }),
|
|
11394
|
+
/* @__PURE__ */ jsx68("p", { className: "truncate text-ods-text-secondary text-h4", children: "Unarchive the chat to continue" })
|
|
11363
11395
|
] }) : contextEnabled ? (
|
|
11364
11396
|
// Unified card (Figma 1:6073 / 271:38656): the context-memory
|
|
11365
11397
|
// summary strip and the assigned-chip strip (both `bg-ods-bg`,
|
|
@@ -11373,7 +11405,7 @@ function ChatComposer({
|
|
|
11373
11405
|
// is a `contentEditable` div (`data-editor`), not a `<textarea>`, so we
|
|
11374
11406
|
// target its data attribute rather than the element name.
|
|
11375
11407
|
/* @__PURE__ */ jsxs52("div", { className: "rounded-md border border-ods-border bg-ods-card transition-colors has-[[data-editor]:focus]:border-ods-accent", children: [
|
|
11376
|
-
/* @__PURE__ */
|
|
11408
|
+
/* @__PURE__ */ jsx68(
|
|
11377
11409
|
ChatContextMemoryBar,
|
|
11378
11410
|
{
|
|
11379
11411
|
items: memory,
|
|
@@ -11383,7 +11415,7 @@ function ChatComposer({
|
|
|
11383
11415
|
className: "rounded-t-md"
|
|
11384
11416
|
}
|
|
11385
11417
|
),
|
|
11386
|
-
selected.length > 0 && /* @__PURE__ */
|
|
11418
|
+
selected.length > 0 && /* @__PURE__ */ jsx68(
|
|
11387
11419
|
ChatContextChipStrip,
|
|
11388
11420
|
{
|
|
11389
11421
|
items: selected,
|
|
@@ -11401,7 +11433,7 @@ function ChatComposer({
|
|
|
11401
11433
|
] })
|
|
11402
11434
|
) : inputNode }) }),
|
|
11403
11435
|
/* @__PURE__ */ jsxs52("div", { className: "flex w-full items-center gap-2", children: [
|
|
11404
|
-
!contextEnabled && showAttachmentButton && onAddFiles && /* @__PURE__ */
|
|
11436
|
+
!contextEnabled && showAttachmentButton && onAddFiles && /* @__PURE__ */ jsx68(
|
|
11405
11437
|
ChatAttachmentAddButton,
|
|
11406
11438
|
{
|
|
11407
11439
|
attachmentsEnabled: true,
|
|
@@ -11410,7 +11442,7 @@ function ChatComposer({
|
|
|
11410
11442
|
disabled: attachmentsDisabled
|
|
11411
11443
|
}
|
|
11412
11444
|
),
|
|
11413
|
-
/* @__PURE__ */
|
|
11445
|
+
/* @__PURE__ */ jsx68("div", { className: "min-w-0 flex-1", children: /* @__PURE__ */ jsx68(ModelDisplay, { ...model }) })
|
|
11414
11446
|
] })
|
|
11415
11447
|
]
|
|
11416
11448
|
}
|
|
@@ -11418,12 +11450,12 @@ function ChatComposer({
|
|
|
11418
11450
|
}
|
|
11419
11451
|
|
|
11420
11452
|
// src/components/chat/chat-archive-page.tsx
|
|
11421
|
-
import { Fragment as Fragment17, jsx as
|
|
11453
|
+
import { Fragment as Fragment17, jsx as jsx69, jsxs as jsxs53 } from "react/jsx-runtime";
|
|
11422
11454
|
function ChatArchivePage(props) {
|
|
11423
11455
|
const { dialogs, onSelectDialog, isLoading = false, isFetching = false, hasMore = false, onLoadMore } = props;
|
|
11424
11456
|
const suppressEmptyStateWhileFetching = isFetching;
|
|
11425
11457
|
return /* @__PURE__ */ jsxs53(Fragment17, { children: [
|
|
11426
|
-
!props.embedded && /* @__PURE__ */
|
|
11458
|
+
!props.embedded && /* @__PURE__ */ jsx69(
|
|
11427
11459
|
ChatPanelHeaderMobile,
|
|
11428
11460
|
{
|
|
11429
11461
|
className: "flex md:hidden",
|
|
@@ -11435,11 +11467,11 @@ function ChatArchivePage(props) {
|
|
|
11435
11467
|
}
|
|
11436
11468
|
),
|
|
11437
11469
|
!props.embedded && /* @__PURE__ */ jsxs53("div", { className: "hidden h-14 w-full flex-shrink-0 overflow-hidden border-b border-ods-border bg-ods-card md:flex", children: [
|
|
11438
|
-
/* @__PURE__ */
|
|
11439
|
-
/* @__PURE__ */
|
|
11440
|
-
/* @__PURE__ */
|
|
11470
|
+
/* @__PURE__ */ jsx69(ChatHeaderIconButton, { divider: "right", onClick: props.onBack, "aria-label": "Back", children: /* @__PURE__ */ jsx69(Chevron02LeftIcon, { size: 24 }) }),
|
|
11471
|
+
/* @__PURE__ */ jsx69("div", { className: "flex min-w-0 flex-1 items-center px-[var(--spacing-system-mf)] py-[var(--spacing-system-sf)]", children: /* @__PURE__ */ jsx69("span", { className: "truncate text-ods-text-primary text-h3", children: "Chat Archive" }) }),
|
|
11472
|
+
/* @__PURE__ */ jsx69(ChatHeaderIconButton, { onClick: props.onClose, "aria-label": "Close", children: /* @__PURE__ */ jsx69(XmarkIcon, { size: 24 }) })
|
|
11441
11473
|
] }),
|
|
11442
|
-
/* @__PURE__ */
|
|
11474
|
+
/* @__PURE__ */ jsx69("div", { className: "flex min-h-0 flex-1 flex-col p-[var(--spacing-system-m)]", children: dialogs.length > 0 ? /* @__PURE__ */ jsx69(
|
|
11443
11475
|
MingoChatHistory,
|
|
11444
11476
|
{
|
|
11445
11477
|
dialogs,
|
|
@@ -11452,14 +11484,14 @@ function ChatArchivePage(props) {
|
|
|
11452
11484
|
// First-load skeleton — the SAME grouped/bordered placeholder the
|
|
11453
11485
|
// active list uses, so the archive loads and lands without a layout
|
|
11454
11486
|
// shift or a mismatched flat-list skeleton.
|
|
11455
|
-
/* @__PURE__ */
|
|
11487
|
+
/* @__PURE__ */ jsx69(MingoChatHistorySkeleton, {})
|
|
11456
11488
|
) : suppressEmptyStateWhileFetching ? null : (
|
|
11457
11489
|
// Empty state — mirrors the "Current Chats" rail empty state
|
|
11458
11490
|
// (Figma 113:60939): centred 24px muted glyph + h4 title + h6 caption.
|
|
11459
|
-
/* @__PURE__ */
|
|
11491
|
+
/* @__PURE__ */ jsx69(
|
|
11460
11492
|
ChatListEmptyState,
|
|
11461
11493
|
{
|
|
11462
|
-
icon: /* @__PURE__ */
|
|
11494
|
+
icon: /* @__PURE__ */ jsx69(BoxArchiveIcon, { size: 24 }),
|
|
11463
11495
|
title: "No Archived Chats",
|
|
11464
11496
|
description: "Archived Mingo sessions will show here"
|
|
11465
11497
|
}
|
|
@@ -11473,7 +11505,7 @@ import { forwardRef as forwardRef24, useRef as useRef15, useEffect as useEffect1
|
|
|
11473
11505
|
|
|
11474
11506
|
// src/components/chat/chat-sidebar-skeleton.tsx
|
|
11475
11507
|
import { forwardRef as forwardRef23 } from "react";
|
|
11476
|
-
import { jsx as
|
|
11508
|
+
import { jsx as jsx70, jsxs as jsxs54 } from "react/jsx-runtime";
|
|
11477
11509
|
var DialogListItemSkeleton = forwardRef23(
|
|
11478
11510
|
({ className, ...props }, ref) => {
|
|
11479
11511
|
return /* @__PURE__ */ jsxs54(
|
|
@@ -11490,10 +11522,10 @@ var DialogListItemSkeleton = forwardRef23(
|
|
|
11490
11522
|
...props,
|
|
11491
11523
|
children: [
|
|
11492
11524
|
/* @__PURE__ */ jsxs54("div", { className: "flex flex-1 flex-col items-start justify-center gap-1", children: [
|
|
11493
|
-
/* @__PURE__ */
|
|
11494
|
-
/* @__PURE__ */
|
|
11525
|
+
/* @__PURE__ */ jsx70("div", { className: "flex w-full items-center", children: /* @__PURE__ */ jsx70("div", { className: "h-6 w-full max-w-[200px] animate-pulse rounded bg-ods-border" }) }),
|
|
11526
|
+
/* @__PURE__ */ jsx70("div", { className: "h-4 w-32 animate-pulse rounded bg-ods-border" })
|
|
11495
11527
|
] }),
|
|
11496
|
-
/* @__PURE__ */
|
|
11528
|
+
/* @__PURE__ */ jsx70("div", { className: "size-6 shrink-0 animate-pulse rounded bg-ods-border" })
|
|
11497
11529
|
]
|
|
11498
11530
|
}
|
|
11499
11531
|
);
|
|
@@ -11509,17 +11541,17 @@ var ChatSidebarSkeleton = forwardRef23(
|
|
|
11509
11541
|
className: cn("flex h-full w-80 flex-col", "bg-ods-bg", "border-r border-ods-border", className),
|
|
11510
11542
|
...props,
|
|
11511
11543
|
children: [
|
|
11512
|
-
showNewChatButton && /* @__PURE__ */
|
|
11544
|
+
showNewChatButton && /* @__PURE__ */ jsx70("div", { className: "flex shrink-0 items-center justify-center border-b border-ods-border bg-ods-card px-4 py-1", children: /* @__PURE__ */ jsx70(
|
|
11513
11545
|
Button,
|
|
11514
11546
|
{
|
|
11515
11547
|
variant: "transparent",
|
|
11516
11548
|
disabled: true,
|
|
11517
|
-
leftIcon: /* @__PURE__ */
|
|
11549
|
+
leftIcon: /* @__PURE__ */ jsx70(ChatPlusIcon, { className: "size-6 text-ods-text-secondary" }),
|
|
11518
11550
|
className: "flex-1 cursor-not-allowed justify-center text-ods-text-secondary text-h3 hover:bg-transparent",
|
|
11519
11551
|
children: "Start New Chat"
|
|
11520
11552
|
}
|
|
11521
11553
|
) }),
|
|
11522
|
-
/* @__PURE__ */
|
|
11554
|
+
/* @__PURE__ */ jsx70("div", { className: "flex min-h-0 flex-1 flex-col", children: /* @__PURE__ */ jsx70("div", { className: "min-h-0 flex-1 overflow-y-auto overscroll-contain", children: /* @__PURE__ */ jsx70("div", { className: "flex flex-col", children: Array.from({ length: dialogCount }).map((_, index) => /* @__PURE__ */ jsx70(DialogListItemSkeleton, {}, index)) }) }) })
|
|
11523
11555
|
]
|
|
11524
11556
|
}
|
|
11525
11557
|
);
|
|
@@ -11528,7 +11560,7 @@ var ChatSidebarSkeleton = forwardRef23(
|
|
|
11528
11560
|
ChatSidebarSkeleton.displayName = "ChatSidebarSkeleton";
|
|
11529
11561
|
|
|
11530
11562
|
// src/components/chat/chat-sidebar.tsx
|
|
11531
|
-
import { Fragment as Fragment18, jsx as
|
|
11563
|
+
import { Fragment as Fragment18, jsx as jsx71, jsxs as jsxs55 } from "react/jsx-runtime";
|
|
11532
11564
|
var DialogListItem = forwardRef24(
|
|
11533
11565
|
({ className, dialog, isActive, onDialogSelect, onClick, ...props }, ref) => {
|
|
11534
11566
|
const handleClick = (e) => {
|
|
@@ -11555,7 +11587,7 @@ var DialogListItem = forwardRef24(
|
|
|
11555
11587
|
...props,
|
|
11556
11588
|
children: [
|
|
11557
11589
|
/* @__PURE__ */ jsxs55("div", { className: "flex min-w-0 flex-1 flex-col items-start justify-center gap-1", children: [
|
|
11558
|
-
/* @__PURE__ */
|
|
11590
|
+
/* @__PURE__ */ jsx71("div", { className: "flex w-full min-w-0 items-center", children: /* @__PURE__ */ jsx71(
|
|
11559
11591
|
"h3",
|
|
11560
11592
|
{
|
|
11561
11593
|
className: cn(
|
|
@@ -11567,9 +11599,9 @@ var DialogListItem = forwardRef24(
|
|
|
11567
11599
|
children: dialog.title || "Untitled Chat"
|
|
11568
11600
|
}
|
|
11569
11601
|
) }),
|
|
11570
|
-
dialog.timestamp && /* @__PURE__ */
|
|
11602
|
+
dialog.timestamp && /* @__PURE__ */ jsx71("p", { className: "w-full min-w-0 truncate text-ods-text-secondary text-h6", children: formatTimestamp(dialog.timestamp) })
|
|
11571
11603
|
] }),
|
|
11572
|
-
/* @__PURE__ */
|
|
11604
|
+
/* @__PURE__ */ jsx71("div", { className: "ml-2 flex-shrink-0", children: dialog.unreadMessagesCount && dialog.unreadMessagesCount > 0 ? /* @__PURE__ */ jsx71("div", { className: "flex size-6 items-center justify-center rounded-md bg-ods-accent p-2", children: /* @__PURE__ */ jsx71("span", { className: "text-ods-text-on-accent text-h6", children: dialog.unreadMessagesCount > 99 ? "99+" : dialog.unreadMessagesCount }) }) : /* @__PURE__ */ jsx71(Chevron02RightIcon, { className: "size-6 text-ods-text-secondary" }) })
|
|
11573
11605
|
]
|
|
11574
11606
|
}
|
|
11575
11607
|
);
|
|
@@ -11615,7 +11647,7 @@ var ChatSidebar = forwardRef24(
|
|
|
11615
11647
|
return () => observer.disconnect();
|
|
11616
11648
|
}, [hasNextPage]);
|
|
11617
11649
|
if (isLoading && dialogs.length === 0 && !children) {
|
|
11618
|
-
return /* @__PURE__ */
|
|
11650
|
+
return /* @__PURE__ */ jsx71(ChatSidebarSkeleton, { className, dialogCount: 8, showNewChatButton: true });
|
|
11619
11651
|
}
|
|
11620
11652
|
return /* @__PURE__ */ jsxs55(
|
|
11621
11653
|
"div",
|
|
@@ -11624,33 +11656,33 @@ var ChatSidebar = forwardRef24(
|
|
|
11624
11656
|
className: cn("flex h-full w-80 flex-col", "bg-ods-bg", "border-r border-ods-border", className),
|
|
11625
11657
|
...props,
|
|
11626
11658
|
children: [
|
|
11627
|
-
/* @__PURE__ */
|
|
11659
|
+
/* @__PURE__ */ jsx71("div", { className: "flex shrink-0 items-center justify-center border-b border-ods-border bg-ods-card px-4 py-1", children: /* @__PURE__ */ jsx71(
|
|
11628
11660
|
Button,
|
|
11629
11661
|
{
|
|
11630
11662
|
onClick: onNewChat,
|
|
11631
11663
|
variant: "transparent",
|
|
11632
11664
|
disabled: isLoading || isCreatingDialog,
|
|
11633
|
-
leftIcon: /* @__PURE__ */
|
|
11665
|
+
leftIcon: /* @__PURE__ */ jsx71(ChatPlusIcon, { className: "size-6 text-ods-text-secondary" }),
|
|
11634
11666
|
className: "flex-1 justify-center text-ods-text-primary text-h3 hover:bg-ods-bg-hover focus-visible:ring-0",
|
|
11635
11667
|
children: "Start New Chat"
|
|
11636
11668
|
}
|
|
11637
11669
|
) }),
|
|
11638
|
-
/* @__PURE__ */
|
|
11670
|
+
/* @__PURE__ */ jsx71("div", { className: "flex min-h-0 flex-1 flex-col", children: showEmptyState ? (
|
|
11639
11671
|
/* Empty State */
|
|
11640
11672
|
/* @__PURE__ */ jsxs55("div", { className: "flex flex-1 flex-col items-center justify-center gap-6 p-6", children: [
|
|
11641
|
-
/* @__PURE__ */
|
|
11673
|
+
/* @__PURE__ */ jsx71(ChatsIcon, { className: "h-6 w-6 text-ods-text-secondary" }),
|
|
11642
11674
|
/* @__PURE__ */ jsxs55("div", { className: "space-y-2 text-center", children: [
|
|
11643
|
-
/* @__PURE__ */
|
|
11644
|
-
/* @__PURE__ */
|
|
11675
|
+
/* @__PURE__ */ jsx71("h3", { className: "text-ods-text-secondary text-h4", children: "No Current Chats" }),
|
|
11676
|
+
/* @__PURE__ */ jsx71("p", { className: "text-ods-text-secondary text-h6", children: "Previous Mingo sessions will show here" })
|
|
11645
11677
|
] })
|
|
11646
11678
|
] })
|
|
11647
11679
|
) : children ? (
|
|
11648
11680
|
/* Custom children content */
|
|
11649
|
-
/* @__PURE__ */
|
|
11681
|
+
/* @__PURE__ */ jsx71("div", { className: "flex-1 overflow-y-auto overscroll-contain", children })
|
|
11650
11682
|
) : (
|
|
11651
11683
|
/* Dialogs List */
|
|
11652
|
-
/* @__PURE__ */
|
|
11653
|
-
dialogs.map((dialog) => /* @__PURE__ */
|
|
11684
|
+
/* @__PURE__ */ jsx71("div", { ref: scrollContainerRef, className: "min-h-0 flex-1 overflow-y-auto overscroll-contain", children: /* @__PURE__ */ jsxs55("div", { className: "flex flex-col", children: [
|
|
11685
|
+
dialogs.map((dialog) => /* @__PURE__ */ jsx71(
|
|
11654
11686
|
DialogListItem,
|
|
11655
11687
|
{
|
|
11656
11688
|
dialog,
|
|
@@ -11659,10 +11691,10 @@ var ChatSidebar = forwardRef24(
|
|
|
11659
11691
|
},
|
|
11660
11692
|
dialog.id
|
|
11661
11693
|
)),
|
|
11662
|
-
hasNextPage && /* @__PURE__ */
|
|
11663
|
-
/* @__PURE__ */
|
|
11664
|
-
/* @__PURE__ */
|
|
11665
|
-
/* @__PURE__ */
|
|
11694
|
+
hasNextPage && /* @__PURE__ */ jsx71("div", { ref: loadMoreRef, children: isFetchingNextPage && /* @__PURE__ */ jsxs55(Fragment18, { children: [
|
|
11695
|
+
/* @__PURE__ */ jsx71(DialogListItemSkeleton, {}),
|
|
11696
|
+
/* @__PURE__ */ jsx71(DialogListItemSkeleton, {}),
|
|
11697
|
+
/* @__PURE__ */ jsx71(DialogListItemSkeleton, {})
|
|
11666
11698
|
] }) })
|
|
11667
11699
|
] }) })
|
|
11668
11700
|
) })
|
|
@@ -11779,7 +11811,7 @@ function handleChatNavClick(event, runtime, { href, path, targetPlatform }, fall
|
|
|
11779
11811
|
}
|
|
11780
11812
|
|
|
11781
11813
|
// src/components/chat/nav-link-anchor-via-runtime.tsx
|
|
11782
|
-
import { jsx as
|
|
11814
|
+
import { jsx as jsx72 } from "react/jsx-runtime";
|
|
11783
11815
|
function NavLinkAnchorViaRuntime({
|
|
11784
11816
|
href,
|
|
11785
11817
|
path,
|
|
@@ -11803,12 +11835,12 @@ function NavLinkAnchorViaRuntime({
|
|
|
11803
11835
|
});
|
|
11804
11836
|
if (handled && !isNewTab && panel?.closeChat) panel.closeChat();
|
|
11805
11837
|
};
|
|
11806
|
-
return /* @__PURE__ */
|
|
11838
|
+
return /* @__PURE__ */ jsx72("a", { href: resolvedHref, ...newTabAnchorAttrs(isNewTab), onClick, className, children });
|
|
11807
11839
|
}
|
|
11808
11840
|
|
|
11809
11841
|
// src/components/chat/source-action-button.tsx
|
|
11810
11842
|
import { MessageSquare as MessageSquare2, FileText as FileText2 } from "lucide-react";
|
|
11811
|
-
import { jsx as
|
|
11843
|
+
import { jsx as jsx73 } from "react/jsx-runtime";
|
|
11812
11844
|
var DENSITY_STYLES = {
|
|
11813
11845
|
inline: {
|
|
11814
11846
|
size: "icon",
|
|
@@ -11846,8 +11878,8 @@ function SourceActionButton({
|
|
|
11846
11878
|
};
|
|
11847
11879
|
const styles = DENSITY_STYLES[density];
|
|
11848
11880
|
const IconComponent = isDisplay ? FileText2 : MessageSquare2;
|
|
11849
|
-
const icon = /* @__PURE__ */
|
|
11850
|
-
return /* @__PURE__ */
|
|
11881
|
+
const icon = /* @__PURE__ */ jsx73(IconComponent, { className: styles.iconSize });
|
|
11882
|
+
return /* @__PURE__ */ jsx73(
|
|
11851
11883
|
Button,
|
|
11852
11884
|
{
|
|
11853
11885
|
variant: "transparent",
|
|
@@ -11863,7 +11895,7 @@ function SourceActionButton({
|
|
|
11863
11895
|
}
|
|
11864
11896
|
|
|
11865
11897
|
// src/components/chat/entity-cards/admin-content-card-grid.tsx
|
|
11866
|
-
import { jsx as
|
|
11898
|
+
import { jsx as jsx74, jsxs as jsxs56 } from "react/jsx-runtime";
|
|
11867
11899
|
var ADMIN_CONTENT_CARD_GRID_CLASS = "grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-[var(--spacing-system-lf)]";
|
|
11868
11900
|
function AdminContentCardSkeleton({ className }) {
|
|
11869
11901
|
return /* @__PURE__ */ jsxs56(
|
|
@@ -11874,21 +11906,21 @@ function AdminContentCardSkeleton({ className }) {
|
|
|
11874
11906
|
className
|
|
11875
11907
|
),
|
|
11876
11908
|
children: [
|
|
11877
|
-
/* @__PURE__ */
|
|
11909
|
+
/* @__PURE__ */ jsx74("div", { className: "aspect-[3/2] w-full shrink-0 bg-ods-border/20" }),
|
|
11878
11910
|
/* @__PURE__ */ jsxs56("div", { className: "flex flex-1 flex-col gap-[var(--spacing-system-sf)] p-5", children: [
|
|
11879
|
-
/* @__PURE__ */
|
|
11880
|
-
/* @__PURE__ */
|
|
11881
|
-
/* @__PURE__ */
|
|
11911
|
+
/* @__PURE__ */ jsx74("div", { className: "h-[2lh] w-full rounded bg-ods-border text-h3" }),
|
|
11912
|
+
/* @__PURE__ */ jsx74("div", { className: "h-[1lh] w-1/2 rounded bg-ods-border text-h6" }),
|
|
11913
|
+
/* @__PURE__ */ jsx74("div", { className: "h-[2lh] w-full rounded bg-ods-border text-h6" }),
|
|
11882
11914
|
/* @__PURE__ */ jsxs56("div", { className: "flex h-7 items-center gap-[var(--spacing-system-xsf)]", children: [
|
|
11883
|
-
/* @__PURE__ */
|
|
11884
|
-
/* @__PURE__ */
|
|
11915
|
+
/* @__PURE__ */ jsx74("div", { className: "h-5 w-20 rounded-full bg-ods-border" }),
|
|
11916
|
+
/* @__PURE__ */ jsx74("div", { className: "h-5 w-24 rounded-full bg-ods-border" })
|
|
11885
11917
|
] }),
|
|
11886
|
-
/* @__PURE__ */
|
|
11918
|
+
/* @__PURE__ */ jsx74("div", { className: "h-[1lh] w-32 rounded bg-ods-border text-h6" }),
|
|
11887
11919
|
/* @__PURE__ */ jsxs56("div", { className: "mt-auto flex items-center justify-between border-t border-ods-border pt-[var(--spacing-system-sf)]", children: [
|
|
11888
|
-
/* @__PURE__ */
|
|
11920
|
+
/* @__PURE__ */ jsx74("div", { className: "h-10 w-24 rounded bg-ods-border" }),
|
|
11889
11921
|
/* @__PURE__ */ jsxs56("div", { className: "flex gap-[var(--spacing-system-xsf)]", children: [
|
|
11890
|
-
/* @__PURE__ */
|
|
11891
|
-
/* @__PURE__ */
|
|
11922
|
+
/* @__PURE__ */ jsx74("div", { className: "h-10 w-20 rounded bg-ods-border" }),
|
|
11923
|
+
/* @__PURE__ */ jsx74("div", { className: "h-10 w-20 rounded bg-ods-border" })
|
|
11892
11924
|
] })
|
|
11893
11925
|
] })
|
|
11894
11926
|
] })
|
|
@@ -11908,18 +11940,18 @@ function AdminContentCardGrid({
|
|
|
11908
11940
|
}) {
|
|
11909
11941
|
const gridClass = cn(ADMIN_CONTENT_CARD_GRID_CLASS, className);
|
|
11910
11942
|
if (loading) {
|
|
11911
|
-
return /* @__PURE__ */
|
|
11943
|
+
return /* @__PURE__ */ jsx74("div", { className: gridClass, "data-state": "loading", children: Array.from({ length: pageSize }, (_, i) => /* @__PURE__ */ jsx74(Skeleton2, {}, i)) });
|
|
11912
11944
|
}
|
|
11913
|
-
const slots = Array.from({ length: Math.max(0, pageSize - items.length) }, (_, i) => /* @__PURE__ */
|
|
11945
|
+
const slots = Array.from({ length: Math.max(0, pageSize - items.length) }, (_, i) => /* @__PURE__ */ jsx74(Skeleton2, { className: "invisible" }, `slot-${i}`));
|
|
11914
11946
|
if (items.length === 0) {
|
|
11915
11947
|
return /* @__PURE__ */ jsxs56("div", { className: "relative", "data-state": "empty", children: [
|
|
11916
|
-
/* @__PURE__ */
|
|
11917
|
-
/* @__PURE__ */
|
|
11948
|
+
/* @__PURE__ */ jsx74("div", { "aria-hidden": true, className: gridClass, children: slots }),
|
|
11949
|
+
/* @__PURE__ */ jsx74("div", { className: "absolute inset-x-0 top-0", children: empty })
|
|
11918
11950
|
] });
|
|
11919
11951
|
}
|
|
11920
11952
|
return /* @__PURE__ */ jsxs56("div", { className: gridClass, "data-state": "items", children: [
|
|
11921
|
-
items.map((item) => /* @__PURE__ */
|
|
11922
|
-
slots.length > 0 && /* @__PURE__ */
|
|
11953
|
+
items.map((item) => /* @__PURE__ */ jsx74("div", { className: "h-full", children: renderCard(item) }, itemKey4(item))),
|
|
11954
|
+
slots.length > 0 && /* @__PURE__ */ jsx74("div", { "aria-hidden": true, className: "contents", children: slots })
|
|
11923
11955
|
] });
|
|
11924
11956
|
}
|
|
11925
11957
|
|
|
@@ -11965,7 +11997,7 @@ function captionsEntityTypeForDocType(docType) {
|
|
|
11965
11997
|
}
|
|
11966
11998
|
|
|
11967
11999
|
// src/components/layout/page-heading.tsx
|
|
11968
|
-
import { Fragment as Fragment19, jsx as
|
|
12000
|
+
import { Fragment as Fragment19, jsx as jsx75, jsxs as jsxs57 } from "react/jsx-runtime";
|
|
11969
12001
|
var PAGE_HEADING_CLASS = "text-h1 text-ods-text-primary";
|
|
11970
12002
|
var SECTION_HEADING_CLASS = "text-h2 text-ods-text-primary";
|
|
11971
12003
|
var DESCRIPTION_CLASS = "mt-6 max-w-[640px] font-body text-[16px] md:text-[18px] leading-[24px] md:leading-[28px] text-ods-text-secondary";
|
|
@@ -11980,15 +12012,15 @@ function PageHeading({
|
|
|
11980
12012
|
const descClass = descriptionClassName ? `${DESCRIPTION_CLASS} ${descriptionClassName}` : DESCRIPTION_CLASS;
|
|
11981
12013
|
const hasDescription = description != null && description !== "" && typeof description !== "boolean";
|
|
11982
12014
|
return /* @__PURE__ */ jsxs57(Fragment19, { children: [
|
|
11983
|
-
/* @__PURE__ */
|
|
11984
|
-
hasDescription && /* @__PURE__ */
|
|
12015
|
+
/* @__PURE__ */ jsx75(Tag2, { className: headingClass, children }),
|
|
12016
|
+
hasDescription && /* @__PURE__ */ jsx75("p", { className: descClass, children: description })
|
|
11985
12017
|
] });
|
|
11986
12018
|
}
|
|
11987
12019
|
|
|
11988
12020
|
// src/components/ui/tabs.tsx
|
|
11989
12021
|
import * as TabsPrimitive from "@radix-ui/react-tabs";
|
|
11990
12022
|
import { forwardRef as forwardRef25 } from "react";
|
|
11991
|
-
import { jsx as
|
|
12023
|
+
import { jsx as jsx76 } from "react/jsx-runtime";
|
|
11992
12024
|
var Tabs = TabsPrimitive.Root;
|
|
11993
12025
|
var TABS_LIST_BASE = "inline-flex h-10 items-center justify-center rounded-md bg-muted p-1 text-muted-foreground";
|
|
11994
12026
|
var tabsListVariantClasses = {
|
|
@@ -12014,19 +12046,19 @@ var tabsTriggerVariantClasses = {
|
|
|
12014
12046
|
var ADMIN_RAIL_WRAPPER_CLASS = "w-full border-b border-ods-border overflow-x-auto";
|
|
12015
12047
|
var TabsList = forwardRef25(
|
|
12016
12048
|
({ className, variant = "default", ...props }, ref) => {
|
|
12017
|
-
const list = /* @__PURE__ */
|
|
12049
|
+
const list = /* @__PURE__ */ jsx76(TabsPrimitive.List, { ref, className: cn(tabsListVariantClasses[variant], className), ...props });
|
|
12018
12050
|
if (variant === "admin-rail") {
|
|
12019
|
-
return /* @__PURE__ */
|
|
12051
|
+
return /* @__PURE__ */ jsx76("div", { className: ADMIN_RAIL_WRAPPER_CLASS, children: list });
|
|
12020
12052
|
}
|
|
12021
12053
|
return list;
|
|
12022
12054
|
}
|
|
12023
12055
|
);
|
|
12024
12056
|
TabsList.displayName = TabsPrimitive.List.displayName;
|
|
12025
12057
|
var TabsTrigger = forwardRef25(
|
|
12026
|
-
({ className, variant = "default", ...props }, ref) => /* @__PURE__ */
|
|
12058
|
+
({ className, variant = "default", ...props }, ref) => /* @__PURE__ */ jsx76(TabsPrimitive.Trigger, { ref, className: cn(tabsTriggerVariantClasses[variant], className), ...props })
|
|
12027
12059
|
);
|
|
12028
12060
|
TabsTrigger.displayName = TabsPrimitive.Trigger.displayName;
|
|
12029
|
-
var TabsContent = forwardRef25(({ className, ...props }, ref) => /* @__PURE__ */
|
|
12061
|
+
var TabsContent = forwardRef25(({ className, ...props }, ref) => /* @__PURE__ */ jsx76(
|
|
12030
12062
|
TabsPrimitive.Content,
|
|
12031
12063
|
{
|
|
12032
12064
|
ref,
|
|
@@ -12172,7 +12204,7 @@ function useVideoWarmup({
|
|
|
12172
12204
|
}
|
|
12173
12205
|
|
|
12174
12206
|
// src/components/features/video-center-badge.tsx
|
|
12175
|
-
import { jsx as
|
|
12207
|
+
import { jsx as jsx77 } from "react/jsx-runtime";
|
|
12176
12208
|
var SIZES = {
|
|
12177
12209
|
sm: 20,
|
|
12178
12210
|
// gallery thumbnails
|
|
@@ -12183,7 +12215,7 @@ var SIZES = {
|
|
|
12183
12215
|
};
|
|
12184
12216
|
var GLYPH_SHADOW = "var(--ods-shadow-glyph)";
|
|
12185
12217
|
function VideoPlayBadge({ size: size2 = "md", className }) {
|
|
12186
|
-
return /* @__PURE__ */
|
|
12218
|
+
return /* @__PURE__ */ jsx77(
|
|
12187
12219
|
"div",
|
|
12188
12220
|
{
|
|
12189
12221
|
className: cn(
|
|
@@ -12197,12 +12229,12 @@ function VideoPlayBadge({ size: size2 = "md", className }) {
|
|
|
12197
12229
|
className
|
|
12198
12230
|
),
|
|
12199
12231
|
style: { filter: GLYPH_SHADOW },
|
|
12200
|
-
children: /* @__PURE__ */
|
|
12232
|
+
children: /* @__PURE__ */ jsx77(PlayFilledIcon, { size: SIZES[size2], color: "currentColor" })
|
|
12201
12233
|
}
|
|
12202
12234
|
);
|
|
12203
12235
|
}
|
|
12204
12236
|
function VideoUnmuteGlyph({ size: size2 = "md", className }) {
|
|
12205
|
-
return /* @__PURE__ */
|
|
12237
|
+
return /* @__PURE__ */ jsx77(
|
|
12206
12238
|
VolumeOffFilledIcon,
|
|
12207
12239
|
{
|
|
12208
12240
|
size: SIZES[size2],
|
|
@@ -12214,7 +12246,7 @@ function VideoUnmuteGlyph({ size: size2 = "md", className }) {
|
|
|
12214
12246
|
}
|
|
12215
12247
|
|
|
12216
12248
|
// src/components/features/video.tsx
|
|
12217
|
-
import { jsx as
|
|
12249
|
+
import { jsx as jsx78, jsxs as jsxs58 } from "react/jsx-runtime";
|
|
12218
12250
|
function videoPerfDebugEnabled() {
|
|
12219
12251
|
if (process.env.NODE_ENV !== "production") return true;
|
|
12220
12252
|
try {
|
|
@@ -12333,10 +12365,10 @@ function VideoErrorOverlay({
|
|
|
12333
12365
|
watchOnYouTubeId
|
|
12334
12366
|
}) {
|
|
12335
12367
|
return /* @__PURE__ */ jsxs58("div", { className: "absolute inset-0 z-10 flex flex-col items-center justify-center gap-[var(--spacing-system-sf)] bg-ods-overlay p-[var(--spacing-system-lf)] text-center", children: [
|
|
12336
|
-
/* @__PURE__ */
|
|
12368
|
+
/* @__PURE__ */ jsx78("p", { className: "text-ods-text-secondary text-h6", children: "This video failed to play." }),
|
|
12337
12369
|
/* @__PURE__ */ jsxs58("div", { className: "flex items-center gap-[var(--spacing-system-sf)]", children: [
|
|
12338
|
-
/* @__PURE__ */
|
|
12339
|
-
watchOnYouTubeId ? /* @__PURE__ */
|
|
12370
|
+
/* @__PURE__ */ jsx78(Button, { variant: "outline", size: "small", onClick: onRetry, children: "Try again" }),
|
|
12371
|
+
watchOnYouTubeId ? /* @__PURE__ */ jsx78(
|
|
12340
12372
|
Button,
|
|
12341
12373
|
{
|
|
12342
12374
|
variant: "transparent",
|
|
@@ -12389,7 +12421,7 @@ function Video2(props) {
|
|
|
12389
12421
|
const layout = props.layout ?? "native";
|
|
12390
12422
|
if (props.lazy && !isNear) {
|
|
12391
12423
|
return wrapWithLayout(
|
|
12392
|
-
/* @__PURE__ */
|
|
12424
|
+
/* @__PURE__ */ jsx78(
|
|
12393
12425
|
"div",
|
|
12394
12426
|
{
|
|
12395
12427
|
ref: nearRef,
|
|
@@ -12401,7 +12433,7 @@ function Video2(props) {
|
|
|
12401
12433
|
layout
|
|
12402
12434
|
);
|
|
12403
12435
|
}
|
|
12404
|
-
const inner = effectiveKind === "youtube" ? /* @__PURE__ */
|
|
12436
|
+
const inner = effectiveKind === "youtube" ? /* @__PURE__ */ jsx78(
|
|
12405
12437
|
YouTubeFacade,
|
|
12406
12438
|
{
|
|
12407
12439
|
url,
|
|
@@ -12411,7 +12443,7 @@ function Video2(props) {
|
|
|
12411
12443
|
minimalControls: props.minimalControls,
|
|
12412
12444
|
...pickYouTube(props)
|
|
12413
12445
|
}
|
|
12414
|
-
) : "firstFrameOnly" in props && props.firstFrameOnly ? /* @__PURE__ */
|
|
12446
|
+
) : "firstFrameOnly" in props && props.firstFrameOnly ? /* @__PURE__ */ jsx78(
|
|
12415
12447
|
FirstFramePreview,
|
|
12416
12448
|
{
|
|
12417
12449
|
url,
|
|
@@ -12419,7 +12451,7 @@ function Video2(props) {
|
|
|
12419
12451
|
fit: "fit" in props ? props.fit : void 0,
|
|
12420
12452
|
className: props.className
|
|
12421
12453
|
}
|
|
12422
|
-
) : /* @__PURE__ */
|
|
12454
|
+
) : /* @__PURE__ */ jsx78(
|
|
12423
12455
|
FilePlayer,
|
|
12424
12456
|
{
|
|
12425
12457
|
url,
|
|
@@ -12442,11 +12474,11 @@ function resolveKind(props, url) {
|
|
|
12442
12474
|
function wrapWithLayout(inner, layout) {
|
|
12443
12475
|
switch (layout) {
|
|
12444
12476
|
case "centered":
|
|
12445
|
-
return /* @__PURE__ */
|
|
12477
|
+
return /* @__PURE__ */ jsx78("div", { className: "flex w-full justify-center", children: /* @__PURE__ */ jsx78("div", { className: "aspect-video w-full max-w-3xl overflow-hidden rounded-lg border border-ods-border", children: inner }) });
|
|
12446
12478
|
case "fill":
|
|
12447
|
-
return /* @__PURE__ */
|
|
12479
|
+
return /* @__PURE__ */ jsx78("div", { className: "absolute inset-0 h-full w-full", children: inner });
|
|
12448
12480
|
case "wide":
|
|
12449
|
-
return /* @__PURE__ */
|
|
12481
|
+
return /* @__PURE__ */ jsx78("div", { className: "aspect-video w-full overflow-hidden rounded-lg bg-ods-bg", children: inner });
|
|
12450
12482
|
case "native":
|
|
12451
12483
|
default:
|
|
12452
12484
|
return inner;
|
|
@@ -12458,13 +12490,13 @@ function FirstFramePreview({
|
|
|
12458
12490
|
fit,
|
|
12459
12491
|
className
|
|
12460
12492
|
}) {
|
|
12461
|
-
return /* @__PURE__ */
|
|
12493
|
+
return /* @__PURE__ */ jsx78(
|
|
12462
12494
|
"div",
|
|
12463
12495
|
{
|
|
12464
12496
|
"aria-hidden": true,
|
|
12465
12497
|
className: "h-full w-full",
|
|
12466
12498
|
style: { "--media-background-color": "transparent" },
|
|
12467
|
-
children: /* @__PURE__ */
|
|
12499
|
+
children: /* @__PURE__ */ jsx78(FilePlayer, { url: `${url}#t=0.1`, poster, fit, muted: true, chromeless: true, className })
|
|
12468
12500
|
}
|
|
12469
12501
|
);
|
|
12470
12502
|
}
|
|
@@ -12827,8 +12859,8 @@ function FilePlayer({
|
|
|
12827
12859
|
} catch {
|
|
12828
12860
|
}
|
|
12829
12861
|
}, [clearStallTimer]);
|
|
12830
|
-
const errorOverlay = monitorHealth && playbackFailed ? /* @__PURE__ */
|
|
12831
|
-
const player = /* @__PURE__ */
|
|
12862
|
+
const errorOverlay = monitorHealth && playbackFailed ? /* @__PURE__ */ jsx78(VideoErrorOverlay, { onRetry: retryPlayback }) : null;
|
|
12863
|
+
const player = /* @__PURE__ */ jsx78(
|
|
12832
12864
|
MuxPlayer,
|
|
12833
12865
|
{
|
|
12834
12866
|
ref: hoverPlayerRef,
|
|
@@ -12858,10 +12890,10 @@ function FilePlayer({
|
|
|
12858
12890
|
...chromeless ? { "--controls": "none" } : {},
|
|
12859
12891
|
...fit === "cover" ? { "--media-object-fit": "cover" } : {}
|
|
12860
12892
|
},
|
|
12861
|
-
children: resolvedCaptionsUrl ? /* @__PURE__ */
|
|
12893
|
+
children: resolvedCaptionsUrl ? /* @__PURE__ */ jsx78("track", { kind: "captions", src: resolvedCaptionsUrl, srcLang: "en", label: "English", default: true }) : null
|
|
12862
12894
|
}
|
|
12863
12895
|
);
|
|
12864
|
-
const unmuteBadge = hoverMutedFallback && !hideMutedBadge ? /* @__PURE__ */
|
|
12896
|
+
const unmuteBadge = hoverMutedFallback && !hideMutedBadge ? /* @__PURE__ */ jsx78(
|
|
12865
12897
|
"button",
|
|
12866
12898
|
{
|
|
12867
12899
|
type: "button",
|
|
@@ -12869,7 +12901,7 @@ function FilePlayer({
|
|
|
12869
12901
|
title: "Unmute",
|
|
12870
12902
|
onClick: unmuteNow,
|
|
12871
12903
|
className: "absolute inset-0 z-10 m-auto flex h-14 w-14 items-center justify-center text-ods-text-primary transition-colors hover:text-ods-accent",
|
|
12872
|
-
children: /* @__PURE__ */
|
|
12904
|
+
children: /* @__PURE__ */ jsx78(VideoUnmuteGlyph, {})
|
|
12873
12905
|
}
|
|
12874
12906
|
) : null;
|
|
12875
12907
|
if (playOnHover && !hoverControlled) {
|
|
@@ -12901,7 +12933,7 @@ function YouTubeFacade({
|
|
|
12901
12933
|
}) {
|
|
12902
12934
|
const videoId = extractYouTubeId(url);
|
|
12903
12935
|
if (!videoId) return null;
|
|
12904
|
-
return /* @__PURE__ */
|
|
12936
|
+
return /* @__PURE__ */ jsx78(
|
|
12905
12937
|
YouTubeFacadeInner,
|
|
12906
12938
|
{
|
|
12907
12939
|
videoId,
|
|
@@ -13038,10 +13070,10 @@ function YouTubeFacadeInner({
|
|
|
13038
13070
|
const wrapperClass = `relative w-full ${className ?? ""}`;
|
|
13039
13071
|
const wrapperStyle = { paddingBottom: "56.25%" };
|
|
13040
13072
|
if (activated && failed) {
|
|
13041
|
-
return /* @__PURE__ */
|
|
13073
|
+
return /* @__PURE__ */ jsx78("div", { className: wrapperClass, style: wrapperStyle, children: /* @__PURE__ */ jsx78(VideoErrorOverlay, { onRetry: retry, watchOnYouTubeId: videoId }) });
|
|
13042
13074
|
}
|
|
13043
13075
|
if (activated) {
|
|
13044
|
-
return /* @__PURE__ */
|
|
13076
|
+
return /* @__PURE__ */ jsx78("div", { className: wrapperClass, style: wrapperStyle, children: /* @__PURE__ */ jsx78(
|
|
13045
13077
|
"iframe",
|
|
13046
13078
|
{
|
|
13047
13079
|
ref: iframeRef,
|
|
@@ -13055,7 +13087,7 @@ function YouTubeFacadeInner({
|
|
|
13055
13087
|
reloadNonce
|
|
13056
13088
|
) });
|
|
13057
13089
|
}
|
|
13058
|
-
return /* @__PURE__ */
|
|
13090
|
+
return /* @__PURE__ */ jsx78("div", { className: wrapperClass, style: wrapperStyle, children: /* @__PURE__ */ jsxs58(
|
|
13059
13091
|
"button",
|
|
13060
13092
|
{
|
|
13061
13093
|
type: "button",
|
|
@@ -13064,8 +13096,8 @@ function YouTubeFacadeInner({
|
|
|
13064
13096
|
className: "group absolute inset-0 m-0 cursor-pointer overflow-hidden rounded-lg border border-ods-border bg-ods-card p-0",
|
|
13065
13097
|
children: [
|
|
13066
13098
|
/* @__PURE__ */ jsxs58("picture", { children: [
|
|
13067
|
-
/* @__PURE__ */
|
|
13068
|
-
/* @__PURE__ */
|
|
13099
|
+
/* @__PURE__ */ jsx78("source", { type: "image/webp", srcSet: posterWebp }),
|
|
13100
|
+
/* @__PURE__ */ jsx78(
|
|
13069
13101
|
"img",
|
|
13070
13102
|
{
|
|
13071
13103
|
src: posterJpg,
|
|
@@ -13078,7 +13110,7 @@ function YouTubeFacadeInner({
|
|
|
13078
13110
|
}
|
|
13079
13111
|
)
|
|
13080
13112
|
] }),
|
|
13081
|
-
/* @__PURE__ */
|
|
13113
|
+
/* @__PURE__ */ jsx78("div", { className: "absolute inset-0 flex items-center justify-center bg-ods-bg bg-opacity-20 transition-opacity duration-200 group-hover:bg-opacity-30", children: /* @__PURE__ */ jsx78(
|
|
13082
13114
|
VideoPlayBadge,
|
|
13083
13115
|
{
|
|
13084
13116
|
size: "lg",
|
|
@@ -13094,7 +13126,7 @@ function YouTubeFacadeInner({
|
|
|
13094
13126
|
import { useMemo as useMemo23, useRef as useRef19, useState as useState28 } from "react";
|
|
13095
13127
|
|
|
13096
13128
|
// src/components/user-display.tsx
|
|
13097
|
-
import { jsx as
|
|
13129
|
+
import { jsx as jsx79, jsxs as jsxs59 } from "react/jsx-runtime";
|
|
13098
13130
|
function UserDisplay({
|
|
13099
13131
|
name,
|
|
13100
13132
|
avatarUrl,
|
|
@@ -13105,7 +13137,7 @@ function UserDisplay({
|
|
|
13105
13137
|
className
|
|
13106
13138
|
}) {
|
|
13107
13139
|
return /* @__PURE__ */ jsxs59("div", { className: cn("flex min-w-0 items-center gap-2", className), children: [
|
|
13108
|
-
/* @__PURE__ */
|
|
13140
|
+
/* @__PURE__ */ jsx79(
|
|
13109
13141
|
SquareAvatar,
|
|
13110
13142
|
{
|
|
13111
13143
|
src: avatarUrl ? getProxiedImageUrl(avatarUrl) || avatarUrl : void 0,
|
|
@@ -13116,14 +13148,14 @@ function UserDisplay({
|
|
|
13116
13148
|
}
|
|
13117
13149
|
),
|
|
13118
13150
|
/* @__PURE__ */ jsxs59("div", { className: "min-w-0 flex-1", children: [
|
|
13119
|
-
/* @__PURE__ */
|
|
13120
|
-
subtitle && /* @__PURE__ */
|
|
13151
|
+
/* @__PURE__ */ jsx79("p", { className: cn("truncate text-ods-text-primary", compact ? "text-h6" : "text-h4"), children: name }),
|
|
13152
|
+
subtitle && /* @__PURE__ */ jsx79("span", { className: cn("block truncate text-ods-text-secondary text-h6"), children: subtitle })
|
|
13121
13153
|
] })
|
|
13122
13154
|
] });
|
|
13123
13155
|
}
|
|
13124
13156
|
|
|
13125
13157
|
// src/components/features/card-hit-layer.tsx
|
|
13126
|
-
import { jsx as
|
|
13158
|
+
import { jsx as jsx80 } from "react/jsx-runtime";
|
|
13127
13159
|
var HIT_LAYER_BASE = "absolute inset-0 block h-full w-full appearance-none border-0 bg-transparent p-0 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-inset focus-visible:ring-ods-focus";
|
|
13128
13160
|
function CardHitLayer({
|
|
13129
13161
|
label,
|
|
@@ -13135,7 +13167,7 @@ function CardHitLayer({
|
|
|
13135
13167
|
}) {
|
|
13136
13168
|
const a11y = decorative ? { "aria-hidden": true, tabIndex: -1 } : { "aria-label": label };
|
|
13137
13169
|
if (href) {
|
|
13138
|
-
return /* @__PURE__ */
|
|
13170
|
+
return /* @__PURE__ */ jsx80(
|
|
13139
13171
|
"a",
|
|
13140
13172
|
{
|
|
13141
13173
|
href,
|
|
@@ -13146,7 +13178,7 @@ function CardHitLayer({
|
|
|
13146
13178
|
}
|
|
13147
13179
|
);
|
|
13148
13180
|
}
|
|
13149
|
-
return /* @__PURE__ */
|
|
13181
|
+
return /* @__PURE__ */ jsx80(
|
|
13150
13182
|
"button",
|
|
13151
13183
|
{
|
|
13152
13184
|
type: "button",
|
|
@@ -13160,7 +13192,7 @@ function CardHitLayer({
|
|
|
13160
13192
|
|
|
13161
13193
|
// src/components/features/cards-strip.tsx
|
|
13162
13194
|
import React5, { useCallback as useCallback13, useEffect as useEffect20, useMemo as useMemo22, useRef as useRef17, useState as useState26 } from "react";
|
|
13163
|
-
import { Fragment as Fragment20, jsx as
|
|
13195
|
+
import { Fragment as Fragment20, jsx as jsx81, jsxs as jsxs60 } from "react/jsx-runtime";
|
|
13164
13196
|
var TRACK_GAP_PX = 16;
|
|
13165
13197
|
var CHEVRON_SUPPRESS_MS = 4e3;
|
|
13166
13198
|
var USER_SCROLL_SUPPRESS_MS = 3e3;
|
|
@@ -13175,7 +13207,7 @@ function ManagedCell({
|
|
|
13175
13207
|
const hintedWidth = React5.isValidElement(item) ? item.props["data-strip-cell-width"] : void 0;
|
|
13176
13208
|
const desktopWidth = typeof hintedWidth === "number" ? hintedWidth : cardWidthDesktop;
|
|
13177
13209
|
const cloneRef = useSuppressCloneFocus(ctx.isClone);
|
|
13178
|
-
return /* @__PURE__ */
|
|
13210
|
+
return /* @__PURE__ */ jsx81(
|
|
13179
13211
|
"div",
|
|
13180
13212
|
{
|
|
13181
13213
|
className: "shrink-0 self-stretch",
|
|
@@ -13188,7 +13220,7 @@ function ManagedCell({
|
|
|
13188
13220
|
if (e.currentTarget.contains(e.relatedTarget)) return;
|
|
13189
13221
|
ctx.onDeactivate(ctx.cardKey);
|
|
13190
13222
|
},
|
|
13191
|
-
children: /* @__PURE__ */
|
|
13223
|
+
children: /* @__PURE__ */ jsx81("div", { ref: cloneRef, className: "h-full [&>*]:h-full [&>a>*]:h-full", "aria-hidden": ctx.isClone || void 0, children: item })
|
|
13192
13224
|
}
|
|
13193
13225
|
);
|
|
13194
13226
|
}
|
|
@@ -13480,7 +13512,7 @@ function CardsStrip(props) {
|
|
|
13480
13512
|
if (!childrenMode) {
|
|
13481
13513
|
return props.renderCard(item, ctx);
|
|
13482
13514
|
}
|
|
13483
|
-
return /* @__PURE__ */
|
|
13515
|
+
return /* @__PURE__ */ jsx81(ManagedCell, { item, ctx, cardWidthMobile, cardWidthDesktop });
|
|
13484
13516
|
};
|
|
13485
13517
|
if (items.length === 0) return null;
|
|
13486
13518
|
const copies = marqueeActive ? 2 : 1;
|
|
@@ -13493,10 +13525,10 @@ function CardsStrip(props) {
|
|
|
13493
13525
|
},
|
|
13494
13526
|
className: cn("flex w-full min-w-0 flex-col gap-6", className),
|
|
13495
13527
|
children: [
|
|
13496
|
-
showTitle && title && /* @__PURE__ */
|
|
13528
|
+
showTitle && title && /* @__PURE__ */ jsx81("h2", { className: `${SECTION_HEADING_CLASS} break-words`, children: title }),
|
|
13497
13529
|
headerSlot,
|
|
13498
13530
|
/* @__PURE__ */ jsxs60("div", { className: "relative", children: [
|
|
13499
|
-
/* @__PURE__ */
|
|
13531
|
+
/* @__PURE__ */ jsx81(
|
|
13500
13532
|
"div",
|
|
13501
13533
|
{
|
|
13502
13534
|
ref: scrollerRef,
|
|
@@ -13509,7 +13541,7 @@ function CardsStrip(props) {
|
|
|
13509
13541
|
onPointerLeave: onHoverPointerLeave,
|
|
13510
13542
|
onPointerCancel: clearHover,
|
|
13511
13543
|
onScroll: onSeamWarp,
|
|
13512
|
-
children: /* @__PURE__ */
|
|
13544
|
+
children: /* @__PURE__ */ jsx81("div", { ref: trackRef, "data-copies": copies, className: "flex w-max items-stretch gap-4", children: Array.from(
|
|
13513
13545
|
{ length: copies },
|
|
13514
13546
|
(_, copyIndex) => items.map((item, i) => {
|
|
13515
13547
|
const key = `${getItemKey(item, i)}__${copyIndex}__${i}`;
|
|
@@ -13520,7 +13552,7 @@ function CardsStrip(props) {
|
|
|
13520
13552
|
// ctx.isClone) and the managed cell's job in children mode.
|
|
13521
13553
|
// The engine itself adds no wrapper here in render-prop mode
|
|
13522
13554
|
// so the card root stays the track's direct child.
|
|
13523
|
-
/* @__PURE__ */
|
|
13555
|
+
/* @__PURE__ */ jsx81(React5.Fragment, { children: renderItem(item, {
|
|
13524
13556
|
index: i,
|
|
13525
13557
|
cardKey: key,
|
|
13526
13558
|
isClone,
|
|
@@ -13538,7 +13570,7 @@ function CardsStrip(props) {
|
|
|
13538
13570
|
}
|
|
13539
13571
|
),
|
|
13540
13572
|
showChevrons && overflows && /* @__PURE__ */ jsxs60(Fragment20, { children: [
|
|
13541
|
-
/* @__PURE__ */
|
|
13573
|
+
/* @__PURE__ */ jsx81(
|
|
13542
13574
|
Button,
|
|
13543
13575
|
{
|
|
13544
13576
|
type: "button",
|
|
@@ -13547,10 +13579,10 @@ function CardsStrip(props) {
|
|
|
13547
13579
|
"aria-label": prevLabel,
|
|
13548
13580
|
onClick: () => scrollByCard(-1),
|
|
13549
13581
|
className: "absolute left-2 top-1/2 z-10 -translate-y-1/2",
|
|
13550
|
-
leftIcon: /* @__PURE__ */
|
|
13582
|
+
leftIcon: /* @__PURE__ */ jsx81(Chevron02LeftIcon, {})
|
|
13551
13583
|
}
|
|
13552
13584
|
),
|
|
13553
|
-
/* @__PURE__ */
|
|
13585
|
+
/* @__PURE__ */ jsx81(
|
|
13554
13586
|
Button,
|
|
13555
13587
|
{
|
|
13556
13588
|
type: "button",
|
|
@@ -13559,7 +13591,7 @@ function CardsStrip(props) {
|
|
|
13559
13591
|
"aria-label": nextLabel,
|
|
13560
13592
|
onClick: () => scrollByCard(1),
|
|
13561
13593
|
className: "absolute right-2 top-1/2 z-10 -translate-y-1/2",
|
|
13562
|
-
leftIcon: /* @__PURE__ */
|
|
13594
|
+
leftIcon: /* @__PURE__ */ jsx81(Chevron02RightIcon, {})
|
|
13563
13595
|
}
|
|
13564
13596
|
)
|
|
13565
13597
|
] })
|
|
@@ -13571,7 +13603,7 @@ function CardsStrip(props) {
|
|
|
13571
13603
|
|
|
13572
13604
|
// src/components/features/video-hover-preview.tsx
|
|
13573
13605
|
import { useEffect as useEffect21, useRef as useRef18, useState as useState27 } from "react";
|
|
13574
|
-
import { Fragment as Fragment21, jsx as
|
|
13606
|
+
import { Fragment as Fragment21, jsx as jsx82, jsxs as jsxs61 } from "react/jsx-runtime";
|
|
13575
13607
|
function VideoHoverPreviewSurface({
|
|
13576
13608
|
url,
|
|
13577
13609
|
posterUrl = null,
|
|
@@ -13610,8 +13642,8 @@ function VideoHoverPreviewSurface({
|
|
|
13610
13642
|
const showMedia = continuation || (gateControlled ? playerMounted : isNear);
|
|
13611
13643
|
const { src: posterSrc, onError: onPosterError } = useCoverImageFallback(posterUrl);
|
|
13612
13644
|
const facadeSkipped = preload === "none" && !posterSrc;
|
|
13613
|
-
return /* @__PURE__ */
|
|
13614
|
-
posterSrc ? /* @__PURE__ */
|
|
13645
|
+
return /* @__PURE__ */ jsx82("div", { ref: rootElRef, className: cn("absolute inset-0", className), inert: isClone || void 0, children: showMedia ? /* @__PURE__ */ jsxs61(Fragment21, { children: [
|
|
13646
|
+
posterSrc ? /* @__PURE__ */ jsx82(
|
|
13615
13647
|
next_image_default,
|
|
13616
13648
|
{
|
|
13617
13649
|
src: posterSrc,
|
|
@@ -13622,14 +13654,14 @@ function VideoHoverPreviewSurface({
|
|
|
13622
13654
|
onError: onPosterError,
|
|
13623
13655
|
className: "object-cover"
|
|
13624
13656
|
}
|
|
13625
|
-
) : facadeSkipped ? /* @__PURE__ */
|
|
13626
|
-
badge === "play" && !active && !continuation && /* @__PURE__ */
|
|
13627
|
-
/* @__PURE__ */
|
|
13657
|
+
) : facadeSkipped ? /* @__PURE__ */ jsx82("div", { className: "absolute inset-0 bg-ods-card" }) : /* @__PURE__ */ jsx82(Video2, { kind: "file", url: previewUrl, firstFrameOnly: true, layout: "fill", fit }),
|
|
13658
|
+
badge === "play" && !active && !continuation && /* @__PURE__ */ jsx82(VideoPlayBadge, { className: "absolute inset-0 z-10 m-auto" }),
|
|
13659
|
+
/* @__PURE__ */ jsx82(
|
|
13628
13660
|
"div",
|
|
13629
13661
|
{
|
|
13630
13662
|
className: "absolute inset-0",
|
|
13631
13663
|
style: { "--media-background-color": "transparent" },
|
|
13632
|
-
children: /* @__PURE__ */
|
|
13664
|
+
children: /* @__PURE__ */ jsx82(
|
|
13633
13665
|
Video2,
|
|
13634
13666
|
{
|
|
13635
13667
|
kind: "file",
|
|
@@ -13655,11 +13687,11 @@ function VideoHoverPreviewSurface({
|
|
|
13655
13687
|
)
|
|
13656
13688
|
}
|
|
13657
13689
|
)
|
|
13658
|
-
] }) : /* @__PURE__ */
|
|
13690
|
+
] }) : /* @__PURE__ */ jsx82("div", { className: "absolute inset-0 bg-ods-card" }) });
|
|
13659
13691
|
}
|
|
13660
13692
|
|
|
13661
13693
|
// src/components/features/video-ratio-tabs.tsx
|
|
13662
|
-
import { Fragment as Fragment22, jsx as
|
|
13694
|
+
import { Fragment as Fragment22, jsx as jsx83, jsxs as jsxs62 } from "react/jsx-runtime";
|
|
13663
13695
|
var TAB_TRIGGER_CLASS = "rounded-none border-b-2 border-transparent data-[state=active]:border-ods-accent data-[state=active]:bg-transparent data-[state=active]:shadow-none px-4 py-2 text-h6 text-ods-text-secondary data-[state=active]:text-ods-text-primary";
|
|
13664
13696
|
var RATIO_GRID_CLASS = {
|
|
13665
13697
|
portrait: "grid grid-cols-2 md:grid-cols-3 gap-4",
|
|
@@ -13680,17 +13712,17 @@ function RatioTabs({ groups, defaultTab, className = "" }) {
|
|
|
13680
13712
|
const activeTabs = RATIO_TAB_CONFIG.filter((t) => groups[t.key].count > 0);
|
|
13681
13713
|
if (activeTabs.length <= 1) {
|
|
13682
13714
|
const active = activeTabs[0];
|
|
13683
|
-
return active ? /* @__PURE__ */
|
|
13715
|
+
return active ? /* @__PURE__ */ jsx83(Fragment22, { children: groups[active.key].render() }) : null;
|
|
13684
13716
|
}
|
|
13685
13717
|
const firstTab = defaultTab && groups[defaultTab].count > 0 ? defaultTab : activeTabs[0].key;
|
|
13686
13718
|
return /* @__PURE__ */ jsxs62(Tabs, { defaultValue: firstTab, className: `w-full ${className}`, children: [
|
|
13687
|
-
/* @__PURE__ */
|
|
13719
|
+
/* @__PURE__ */ jsx83(TabsList, { className: "mb-2 inline-flex h-auto justify-start gap-0 rounded-none bg-transparent p-0", children: activeTabs.map((t) => /* @__PURE__ */ jsxs62(TabsTrigger, { value: t.key, className: TAB_TRIGGER_CLASS, children: [
|
|
13688
13720
|
t.label,
|
|
13689
13721
|
" (",
|
|
13690
13722
|
groups[t.key].count,
|
|
13691
13723
|
")"
|
|
13692
13724
|
] }, t.key)) }),
|
|
13693
|
-
activeTabs.map((t) => /* @__PURE__ */
|
|
13725
|
+
activeTabs.map((t) => /* @__PURE__ */ jsx83(TabsContent, { value: t.key, forceMount: true, className: "data-[state=inactive]:hidden", children: groups[t.key].render() }, t.key))
|
|
13694
13726
|
] });
|
|
13695
13727
|
}
|
|
13696
13728
|
function detectAspectRatio(ratioString, width, height) {
|
|
@@ -13723,7 +13755,7 @@ function groupByAspectRatio(items, getAspectRatio) {
|
|
|
13723
13755
|
}
|
|
13724
13756
|
|
|
13725
13757
|
// src/components/features/video-bites-strip.tsx
|
|
13726
|
-
import { Fragment as Fragment23, jsx as
|
|
13758
|
+
import { Fragment as Fragment23, jsx as jsx84, jsxs as jsxs63 } from "react/jsx-runtime";
|
|
13727
13759
|
function VideoBitesStrip({
|
|
13728
13760
|
bites,
|
|
13729
13761
|
title = DEFAULT_VIDEO_BITES_TITLE,
|
|
@@ -13747,7 +13779,7 @@ function VideoBitesStrip({
|
|
|
13747
13779
|
return filtered.sort(sortComparator);
|
|
13748
13780
|
}, [bites, filterPublished, sortComparator]);
|
|
13749
13781
|
const warmup = useVideoWarmup({ videoUrl: items[0]?.url || null });
|
|
13750
|
-
return /* @__PURE__ */
|
|
13782
|
+
return /* @__PURE__ */ jsx84(
|
|
13751
13783
|
CardsStrip,
|
|
13752
13784
|
{
|
|
13753
13785
|
items,
|
|
@@ -13763,7 +13795,7 @@ function VideoBitesStrip({
|
|
|
13763
13795
|
nextLabel: "Next videos",
|
|
13764
13796
|
rootRef: warmup.ref,
|
|
13765
13797
|
className,
|
|
13766
|
-
renderCard: (bite, ctx) => /* @__PURE__ */
|
|
13798
|
+
renderCard: (bite, ctx) => /* @__PURE__ */ jsx84(
|
|
13767
13799
|
VideoBiteCard,
|
|
13768
13800
|
{
|
|
13769
13801
|
bite,
|
|
@@ -13842,7 +13874,7 @@ function VideoBiteCard({
|
|
|
13842
13874
|
// (line-clamp-2) and the editor must render identically. rows=1 +
|
|
13843
13875
|
// auto-grow keeps short titles single-line; max-height caps at the
|
|
13844
13876
|
// same two lines the clamp allows.
|
|
13845
|
-
/* @__PURE__ */
|
|
13877
|
+
/* @__PURE__ */ jsx84(
|
|
13846
13878
|
"textarea",
|
|
13847
13879
|
{
|
|
13848
13880
|
value: bite.title || "",
|
|
@@ -13860,9 +13892,9 @@ function VideoBiteCard({
|
|
|
13860
13892
|
)
|
|
13861
13893
|
}
|
|
13862
13894
|
)
|
|
13863
|
-
) : bite.title && /* @__PURE__ */
|
|
13895
|
+
) : bite.title && /* @__PURE__ */ jsx84("p", { className: cn(titleClass, "line-clamp-2"), children: bite.title }),
|
|
13864
13896
|
(profile || hasTarget) && /* @__PURE__ */ jsxs63("div", { className: "flex min-w-0 items-center gap-2", children: [
|
|
13865
|
-
profile && /* @__PURE__ */
|
|
13897
|
+
profile && /* @__PURE__ */ jsx84(
|
|
13866
13898
|
UserDisplay,
|
|
13867
13899
|
{
|
|
13868
13900
|
name: profile.name,
|
|
@@ -13874,7 +13906,7 @@ function VideoBiteCard({
|
|
|
13874
13906
|
className: "flex-1"
|
|
13875
13907
|
}
|
|
13876
13908
|
),
|
|
13877
|
-
hasTarget && /* @__PURE__ */
|
|
13909
|
+
hasTarget && /* @__PURE__ */ jsx84(Chevron02RightIcon, { className: "ml-auto h-5 w-5 shrink-0 text-ods-text-primary" })
|
|
13878
13910
|
] })
|
|
13879
13911
|
] });
|
|
13880
13912
|
const overlayClass = cn(
|
|
@@ -13892,7 +13924,7 @@ function VideoBiteCard({
|
|
|
13892
13924
|
className: "relative w-full",
|
|
13893
13925
|
style: { aspectRatio: cssAspect, ...height !== void 0 ? { height, maxWidth: STRIP_CELL_MAX_WIDTH } : {} },
|
|
13894
13926
|
children: [
|
|
13895
|
-
/* @__PURE__ */
|
|
13927
|
+
/* @__PURE__ */ jsx84(
|
|
13896
13928
|
VideoHoverPreviewSurface,
|
|
13897
13929
|
{
|
|
13898
13930
|
url: bite.url,
|
|
@@ -13909,7 +13941,7 @@ function VideoBiteCard({
|
|
|
13909
13941
|
// not clickable and showed no pointer cursor even though the glyph
|
|
13910
13942
|
// accented on hover. One interactive element, no a11y duplication.
|
|
13911
13943
|
/* @__PURE__ */ jsxs63(Fragment23, { children: [
|
|
13912
|
-
/* @__PURE__ */
|
|
13944
|
+
/* @__PURE__ */ jsx84(
|
|
13913
13945
|
CardHitLayer,
|
|
13914
13946
|
{
|
|
13915
13947
|
label: `Open ${bite.title || "source content"}`,
|
|
@@ -13919,9 +13951,9 @@ function VideoBiteCard({
|
|
|
13919
13951
|
decorative: isClone
|
|
13920
13952
|
}
|
|
13921
13953
|
),
|
|
13922
|
-
/* @__PURE__ */
|
|
13954
|
+
/* @__PURE__ */ jsx84("div", { className: cn(overlayClass, "pointer-events-none"), children: overlayContent })
|
|
13923
13955
|
] })
|
|
13924
|
-
) : /* @__PURE__ */
|
|
13956
|
+
) : /* @__PURE__ */ jsx84("div", { className: overlayClass, children: overlayContent })
|
|
13925
13957
|
]
|
|
13926
13958
|
}
|
|
13927
13959
|
);
|
|
@@ -13947,14 +13979,14 @@ function VideoBiteCard({
|
|
|
13947
13979
|
toolbar && // Solid-surface action row UNDER the media (WCAG non-text contrast —
|
|
13948
13980
|
// see the `toolbar` prop doc). Part of the card, so hovering it keeps
|
|
13949
13981
|
// hover playback alive.
|
|
13950
|
-
/* @__PURE__ */
|
|
13982
|
+
/* @__PURE__ */ jsx84("div", { className: "flex items-center justify-between gap-1 border-t border-ods-border bg-ods-card px-2 py-1.5", children: toolbar })
|
|
13951
13983
|
]
|
|
13952
13984
|
}
|
|
13953
13985
|
);
|
|
13954
13986
|
}
|
|
13955
13987
|
|
|
13956
13988
|
// src/components/features/entity-video-section.tsx
|
|
13957
|
-
import { Fragment as Fragment24, jsx as
|
|
13989
|
+
import { Fragment as Fragment24, jsx as jsx85, jsxs as jsxs64 } from "react/jsx-runtime";
|
|
13958
13990
|
function EntityVideoSection({
|
|
13959
13991
|
mainVideoUrl,
|
|
13960
13992
|
youtubeUrl,
|
|
@@ -13993,7 +14025,7 @@ function EntityVideoSection({
|
|
|
13993
14025
|
return /* @__PURE__ */ jsxs64(Fragment24, { children: [
|
|
13994
14026
|
hasVideo && (fullVideoUrl && hasHighlight ? /* @__PURE__ */ jsxs64(Tabs, { defaultValue: "full-video", className: "w-full", children: [
|
|
13995
14027
|
/* @__PURE__ */ jsxs64(TabsList, { className: "inline-flex h-auto justify-start gap-0 rounded-none bg-transparent p-0", children: [
|
|
13996
|
-
/* @__PURE__ */
|
|
14028
|
+
/* @__PURE__ */ jsx85(
|
|
13997
14029
|
TabsTrigger,
|
|
13998
14030
|
{
|
|
13999
14031
|
value: "full-video",
|
|
@@ -14001,7 +14033,7 @@ function EntityVideoSection({
|
|
|
14001
14033
|
children: "Full Video"
|
|
14002
14034
|
}
|
|
14003
14035
|
),
|
|
14004
|
-
/* @__PURE__ */
|
|
14036
|
+
/* @__PURE__ */ jsx85(
|
|
14005
14037
|
TabsTrigger,
|
|
14006
14038
|
{
|
|
14007
14039
|
value: "highlights",
|
|
@@ -14010,7 +14042,7 @@ function EntityVideoSection({
|
|
|
14010
14042
|
}
|
|
14011
14043
|
)
|
|
14012
14044
|
] }),
|
|
14013
|
-
/* @__PURE__ */
|
|
14045
|
+
/* @__PURE__ */ jsx85(TabsContent, { value: "full-video", className: "mt-4", children: /* @__PURE__ */ jsx85(
|
|
14014
14046
|
Video2,
|
|
14015
14047
|
{
|
|
14016
14048
|
kind: fullVideoKind,
|
|
@@ -14023,7 +14055,7 @@ function EntityVideoSection({
|
|
|
14023
14055
|
priority
|
|
14024
14056
|
}
|
|
14025
14057
|
) }),
|
|
14026
|
-
/* @__PURE__ */
|
|
14058
|
+
/* @__PURE__ */ jsx85(TabsContent, { value: "highlights", className: "mt-4", children: /* @__PURE__ */ jsx85(
|
|
14027
14059
|
Video2,
|
|
14028
14060
|
{
|
|
14029
14061
|
url: highlightVideoUrl,
|
|
@@ -14032,7 +14064,7 @@ function EntityVideoSection({
|
|
|
14032
14064
|
layout: "centered"
|
|
14033
14065
|
}
|
|
14034
14066
|
) })
|
|
14035
|
-
] }) : fullVideoUrl ? /* @__PURE__ */
|
|
14067
|
+
] }) : fullVideoUrl ? /* @__PURE__ */ jsx85(
|
|
14036
14068
|
Video2,
|
|
14037
14069
|
{
|
|
14038
14070
|
kind: fullVideoKind,
|
|
@@ -14044,7 +14076,7 @@ function EntityVideoSection({
|
|
|
14044
14076
|
layout: "centered",
|
|
14045
14077
|
priority
|
|
14046
14078
|
}
|
|
14047
|
-
) : highlightVideoUrl ? /* @__PURE__ */
|
|
14079
|
+
) : highlightVideoUrl ? /* @__PURE__ */ jsx85(
|
|
14048
14080
|
Video2,
|
|
14049
14081
|
{
|
|
14050
14082
|
url: highlightVideoUrl,
|
|
@@ -14055,10 +14087,10 @@ function EntityVideoSection({
|
|
|
14055
14087
|
}
|
|
14056
14088
|
) : null),
|
|
14057
14089
|
videoSummary && MarkdownRenderer && /* @__PURE__ */ jsxs64("div", { className: "flex w-full min-w-0 flex-col gap-6", children: [
|
|
14058
|
-
/* @__PURE__ */
|
|
14059
|
-
/* @__PURE__ */
|
|
14090
|
+
/* @__PURE__ */ jsx85("h2", { className: `${SECTION_HEADING_CLASS} break-words`, children: "Summary" }),
|
|
14091
|
+
/* @__PURE__ */ jsx85("div", { className: "overflow-hidden break-words text-ods-text-primary text-h4", children: /* @__PURE__ */ jsx85(MarkdownRenderer, { content: videoSummary }) })
|
|
14060
14092
|
] }),
|
|
14061
|
-
videoBites && videoBites.length > 0 && /* @__PURE__ */
|
|
14093
|
+
videoBites && videoBites.length > 0 && /* @__PURE__ */ jsx85(
|
|
14062
14094
|
VideoBitesStrip,
|
|
14063
14095
|
{
|
|
14064
14096
|
bites: videoBites,
|
|
@@ -14075,7 +14107,7 @@ function EntityVideoSection({
|
|
|
14075
14107
|
}
|
|
14076
14108
|
|
|
14077
14109
|
// src/components/chat/entity-cards/chat-video-entity-card.tsx
|
|
14078
|
-
import { jsx as
|
|
14110
|
+
import { jsx as jsx86 } from "react/jsx-runtime";
|
|
14079
14111
|
function readString(value) {
|
|
14080
14112
|
return typeof value === "string" && value.length > 0 ? value : null;
|
|
14081
14113
|
}
|
|
@@ -14086,7 +14118,7 @@ function ChatVideoEntityCard({ chatRef }) {
|
|
|
14086
14118
|
const poster = readString(m.videoPoster);
|
|
14087
14119
|
const highlightUrl = readString(m.highlightVideoUrl);
|
|
14088
14120
|
const highlightPoster = readString(m.highlightVideoPoster);
|
|
14089
|
-
return /* @__PURE__ */
|
|
14121
|
+
return /* @__PURE__ */ jsx86(
|
|
14090
14122
|
EntityVideoSection,
|
|
14091
14123
|
{
|
|
14092
14124
|
mainVideoUrl: videoUrl,
|
|
@@ -14103,7 +14135,7 @@ function ChatVideoEntityCard({ chatRef }) {
|
|
|
14103
14135
|
// src/components/chat/entity-cards/github-activity-card.tsx
|
|
14104
14136
|
import { GitPullRequest, Eye, ExternalLink } from "lucide-react";
|
|
14105
14137
|
import React6 from "react";
|
|
14106
|
-
import { Fragment as Fragment25, jsx as
|
|
14138
|
+
import { Fragment as Fragment25, jsx as jsx87, jsxs as jsxs65 } from "react/jsx-runtime";
|
|
14107
14139
|
function parseRepoFromUrl(url) {
|
|
14108
14140
|
if (!url) return null;
|
|
14109
14141
|
try {
|
|
@@ -14118,12 +14150,12 @@ function parseRepoFromUrl(url) {
|
|
|
14118
14150
|
function kindIcon(kind, className = "h-4 w-4") {
|
|
14119
14151
|
switch (kind) {
|
|
14120
14152
|
case "pull_request":
|
|
14121
|
-
return /* @__PURE__ */
|
|
14153
|
+
return /* @__PURE__ */ jsx87(GitPullRequest, { className: `${className} shrink-0` });
|
|
14122
14154
|
case "pr_review":
|
|
14123
|
-
return /* @__PURE__ */
|
|
14155
|
+
return /* @__PURE__ */ jsx87(Eye, { className: `${className} shrink-0` });
|
|
14124
14156
|
case "commit":
|
|
14125
14157
|
default:
|
|
14126
|
-
return /* @__PURE__ */
|
|
14158
|
+
return /* @__PURE__ */ jsx87(GitHubIcon, { className: `${className} shrink-0` });
|
|
14127
14159
|
}
|
|
14128
14160
|
}
|
|
14129
14161
|
function kindLabel(kind) {
|
|
@@ -14198,7 +14230,7 @@ function reviewStateLabel(state) {
|
|
|
14198
14230
|
}
|
|
14199
14231
|
function ReviewStateBadge({ state, className = "" }) {
|
|
14200
14232
|
const { label, className: paint } = REVIEW_STATE_STYLE[state] ?? REVIEW_STATE_STYLE.COMMENTED;
|
|
14201
|
-
return /* @__PURE__ */
|
|
14233
|
+
return /* @__PURE__ */ jsx87("span", { className: `inline-flex shrink-0 items-center rounded px-1.5 py-0.5 text-h5 ${paint} ${className}`, children: label });
|
|
14202
14234
|
}
|
|
14203
14235
|
function GitHubActivityCard({ item, variant = "compact", className, anchorProps }) {
|
|
14204
14236
|
const kind = item.kind ?? "commit";
|
|
@@ -14211,52 +14243,52 @@ function GitHubActivityCard({ item, variant = "compact", className, anchorProps
|
|
|
14211
14243
|
return /* @__PURE__ */ jsxs65("div", { className: `flex min-w-0 items-center gap-3 ${className ?? ""}`, children: [
|
|
14212
14244
|
/* @__PURE__ */ jsxs65("span", { className: "flex w-28 shrink-0 items-center gap-2", children: [
|
|
14213
14245
|
kindIcon(kind, "h-3.5 w-3.5"),
|
|
14214
|
-
/* @__PURE__ */
|
|
14246
|
+
/* @__PURE__ */ jsx87("code", { className: "truncate text-ods-text-secondary text-code", children: idLabel })
|
|
14215
14247
|
] }),
|
|
14216
14248
|
/* @__PURE__ */ jsxs65("span", { className: "flex min-w-0 flex-1 items-center gap-2 text-ods-text-primary text-h6", children: [
|
|
14217
|
-
reviewState ? /* @__PURE__ */
|
|
14218
|
-
/* @__PURE__ */
|
|
14249
|
+
reviewState ? /* @__PURE__ */ jsx87(ReviewStateBadge, { state: reviewState }) : null,
|
|
14250
|
+
/* @__PURE__ */ jsx87("span", { className: "truncate", children: primaryText })
|
|
14219
14251
|
] }),
|
|
14220
|
-
repo ? /* @__PURE__ */
|
|
14221
|
-
dateText ? /* @__PURE__ */
|
|
14252
|
+
repo ? /* @__PURE__ */ jsx87("span", { className: "max-w-[240px] shrink-0 truncate text-ods-text-secondary text-code", children: repo }) : null,
|
|
14253
|
+
dateText ? /* @__PURE__ */ jsx87("span", { className: "w-24 shrink-0 text-right text-ods-text-secondary text-h6", children: dateText }) : null
|
|
14222
14254
|
] });
|
|
14223
14255
|
}
|
|
14224
14256
|
const metaParts = [];
|
|
14225
14257
|
metaParts.push(
|
|
14226
|
-
/* @__PURE__ */
|
|
14258
|
+
/* @__PURE__ */ jsx87("span", { className: "uppercase text-h6", children: kindLabel(kind) }, "kind")
|
|
14227
14259
|
);
|
|
14228
14260
|
if (idLabel)
|
|
14229
14261
|
metaParts.push(
|
|
14230
|
-
/* @__PURE__ */
|
|
14262
|
+
/* @__PURE__ */ jsx87("code", { className: "font-mono", children: idLabel }, "id")
|
|
14231
14263
|
);
|
|
14232
14264
|
if (repo)
|
|
14233
14265
|
metaParts.push(
|
|
14234
|
-
/* @__PURE__ */
|
|
14266
|
+
/* @__PURE__ */ jsx87("span", { className: "truncate font-mono", children: repo }, "repo")
|
|
14235
14267
|
);
|
|
14236
14268
|
if (dateText)
|
|
14237
14269
|
metaParts.push(
|
|
14238
|
-
/* @__PURE__ */
|
|
14270
|
+
/* @__PURE__ */ jsx87("span", { className: "whitespace-nowrap", children: dateText }, "date")
|
|
14239
14271
|
);
|
|
14240
14272
|
const href = safeHref(item.url);
|
|
14241
14273
|
const body = /* @__PURE__ */ jsxs65(Fragment25, { children: [
|
|
14242
|
-
/* @__PURE__ */
|
|
14274
|
+
/* @__PURE__ */ jsx87("span", { className: COMPACT_CARD_ICON_SLOT, children: kindIcon(kind, "h-5 w-5") }),
|
|
14243
14275
|
/* @__PURE__ */ jsxs65("span", { className: COMPACT_CARD_TEXT_COL, children: [
|
|
14244
14276
|
/* @__PURE__ */ jsxs65("span", { className: `${COMPACT_CARD_TITLE_ROW} flex-nowrap gap-1.5`, children: [
|
|
14245
|
-
reviewState ? /* @__PURE__ */
|
|
14246
|
-
/* @__PURE__ */
|
|
14277
|
+
reviewState ? /* @__PURE__ */ jsx87(ReviewStateBadge, { state: reviewState }) : null,
|
|
14278
|
+
/* @__PURE__ */ jsx87("span", { className: COMPACT_CARD_TITLE, children: primaryText })
|
|
14247
14279
|
] }),
|
|
14248
|
-
/* @__PURE__ */
|
|
14249
|
-
i > 0 ? /* @__PURE__ */
|
|
14250
|
-
/* @__PURE__ */
|
|
14280
|
+
/* @__PURE__ */ jsx87("span", { className: COMPACT_CARD_META_ROW_BOX, children: /* @__PURE__ */ jsx87("span", { className: COMPACT_CARD_META_ROW, children: metaParts.map((part, i) => /* @__PURE__ */ jsxs65(React6.Fragment, { children: [
|
|
14281
|
+
i > 0 ? /* @__PURE__ */ jsx87("span", { className: "shrink-0 text-ods-text-secondary/40", children: "\xB7" }) : null,
|
|
14282
|
+
/* @__PURE__ */ jsx87("span", { className: "min-w-0 truncate", children: part })
|
|
14251
14283
|
] }, i)) }) }),
|
|
14252
|
-
/* @__PURE__ */
|
|
14284
|
+
/* @__PURE__ */ jsx87("span", { className: COMPACT_CARD_META_ROW_BOX, children: /* @__PURE__ */ jsx87("span", { className: COMPACT_CARD_SUMMARY, children: COMPACT_CARD_ROW_FILLER }) })
|
|
14253
14285
|
] }),
|
|
14254
|
-
href ? /* @__PURE__ */
|
|
14286
|
+
href ? /* @__PURE__ */ jsx87("span", { className: "flex h-5 shrink-0 items-center self-start text-ods-text-secondary", children: /* @__PURE__ */ jsx87(ExternalLink, { className: "h-3.5 w-3.5" }) }) : null
|
|
14255
14287
|
] });
|
|
14256
14288
|
if (anchorProps) {
|
|
14257
|
-
return /* @__PURE__ */
|
|
14289
|
+
return /* @__PURE__ */ jsx87("a", { ...anchorProps, className: `${COMPACT_CARD_OUTER} ${className ?? ""}`, children: body });
|
|
14258
14290
|
}
|
|
14259
|
-
return href ? /* @__PURE__ */
|
|
14291
|
+
return href ? /* @__PURE__ */ jsx87("a", { href, target: "_blank", rel: "noopener noreferrer", className: `${COMPACT_CARD_OUTER} ${className ?? ""}`, children: body }) : /* @__PURE__ */ jsx87("span", { className: `${COMPACT_CARD_OUTER_STATIC} ${className ?? ""}`, "aria-label": "No link available", children: body });
|
|
14260
14292
|
}
|
|
14261
14293
|
function GitHubActivityCardSkeleton({
|
|
14262
14294
|
variant = "compact",
|
|
@@ -14265,29 +14297,29 @@ function GitHubActivityCardSkeleton({
|
|
|
14265
14297
|
if (variant === "row") {
|
|
14266
14298
|
return /* @__PURE__ */ jsxs65("div", { className: `flex min-w-0 animate-pulse items-center gap-3 ${className ?? ""}`, children: [
|
|
14267
14299
|
/* @__PURE__ */ jsxs65("div", { className: "flex w-28 shrink-0 items-center gap-2", children: [
|
|
14268
|
-
/* @__PURE__ */
|
|
14269
|
-
/* @__PURE__ */
|
|
14300
|
+
/* @__PURE__ */ jsx87("div", { className: "h-3.5 w-3.5 rounded bg-ods-bg" }),
|
|
14301
|
+
/* @__PURE__ */ jsx87("div", { className: "h-3 w-16 rounded bg-ods-bg" })
|
|
14270
14302
|
] }),
|
|
14271
|
-
/* @__PURE__ */
|
|
14272
|
-
/* @__PURE__ */
|
|
14273
|
-
/* @__PURE__ */
|
|
14303
|
+
/* @__PURE__ */ jsx87("div", { className: "h-3 w-2/3 flex-1 rounded bg-ods-bg" }),
|
|
14304
|
+
/* @__PURE__ */ jsx87("div", { className: "h-3 w-40 shrink-0 rounded bg-ods-bg/60" }),
|
|
14305
|
+
/* @__PURE__ */ jsx87("div", { className: "h-3 w-20 shrink-0 rounded bg-ods-bg/60" })
|
|
14274
14306
|
] });
|
|
14275
14307
|
}
|
|
14276
14308
|
return /* @__PURE__ */ jsxs65("span", { className: `${COMPACT_CARD_SKELETON_OUTER} ${className ?? ""}`, children: [
|
|
14277
|
-
/* @__PURE__ */
|
|
14309
|
+
/* @__PURE__ */ jsx87("span", { className: COMPACT_CARD_SKELETON_IMAGE_SLOT }),
|
|
14278
14310
|
/* @__PURE__ */ jsxs65("span", { className: COMPACT_CARD_TEXT_COL, children: [
|
|
14279
|
-
/* @__PURE__ */
|
|
14280
|
-
/* @__PURE__ */
|
|
14281
|
-
/* @__PURE__ */
|
|
14311
|
+
/* @__PURE__ */ jsx87("span", { className: COMPACT_CARD_TITLE_ROW, children: /* @__PURE__ */ jsx87("span", { className: "h-3.5 w-2/3 rounded bg-ods-bg" }) }),
|
|
14312
|
+
/* @__PURE__ */ jsx87("span", { className: COMPACT_CARD_META_ROW_BOX, children: /* @__PURE__ */ jsx87("span", { className: "h-3 w-1/2 rounded bg-ods-bg/70" }) }),
|
|
14313
|
+
/* @__PURE__ */ jsx87("span", { className: COMPACT_CARD_META_ROW_BOX, children: /* @__PURE__ */ jsx87("span", { className: COMPACT_CARD_SUMMARY, children: COMPACT_CARD_ROW_FILLER }) })
|
|
14282
14314
|
] }),
|
|
14283
|
-
/* @__PURE__ */
|
|
14315
|
+
/* @__PURE__ */ jsx87("span", { className: "flex h-5 shrink-0 items-center self-start", children: /* @__PURE__ */ jsx87("span", { className: "h-3.5 w-3.5 rounded bg-ods-bg" }) })
|
|
14284
14316
|
] });
|
|
14285
14317
|
}
|
|
14286
14318
|
|
|
14287
14319
|
// src/components/chat/entity-cards/slack-message-card.tsx
|
|
14288
14320
|
import { ExternalLink as ExternalLink2, Hash } from "lucide-react";
|
|
14289
14321
|
import React7 from "react";
|
|
14290
|
-
import { Fragment as Fragment26, jsx as
|
|
14322
|
+
import { Fragment as Fragment26, jsx as jsx88, jsxs as jsxs66 } from "react/jsx-runtime";
|
|
14291
14323
|
function parseChannelFromUrl(url) {
|
|
14292
14324
|
if (!url) return null;
|
|
14293
14325
|
try {
|
|
@@ -14305,46 +14337,46 @@ function SlackMessageCard({ item, variant = "compact", className, anchorProps })
|
|
|
14305
14337
|
const dateText = formatDateUTC(item.dateUpdated, { fallback: "", timezone: "local" });
|
|
14306
14338
|
if (variant === "row") {
|
|
14307
14339
|
return /* @__PURE__ */ jsxs66("div", { className: `flex min-w-0 items-center gap-3 ${className ?? ""}`, children: [
|
|
14308
|
-
/* @__PURE__ */
|
|
14309
|
-
/* @__PURE__ */
|
|
14310
|
-
item.preview ? /* @__PURE__ */
|
|
14340
|
+
/* @__PURE__ */ jsx88(SlackIcon, { className: "h-3.5 w-3.5 shrink-0" }),
|
|
14341
|
+
/* @__PURE__ */ jsx88("span", { className: "max-w-[180px] shrink-0 truncate text-ods-text-primary text-h6", children: item.title }),
|
|
14342
|
+
item.preview ? /* @__PURE__ */ jsx88("span", { className: "min-w-0 flex-1 truncate text-ods-text-secondary text-h6", children: item.preview }) : null,
|
|
14311
14343
|
channel ? /* @__PURE__ */ jsxs66("span", { className: "max-w-[140px] shrink-0 truncate text-ods-text-secondary text-code", children: [
|
|
14312
|
-
/* @__PURE__ */
|
|
14344
|
+
/* @__PURE__ */ jsx88(Hash, { className: "inline h-3 w-3" }),
|
|
14313
14345
|
channel
|
|
14314
14346
|
] }) : null,
|
|
14315
|
-
dateText ? /* @__PURE__ */
|
|
14347
|
+
dateText ? /* @__PURE__ */ jsx88("span", { className: "w-24 shrink-0 text-right text-ods-text-secondary text-h6", children: dateText }) : null
|
|
14316
14348
|
] });
|
|
14317
14349
|
}
|
|
14318
14350
|
const metaParts = [];
|
|
14319
14351
|
if (channel) {
|
|
14320
14352
|
metaParts.push(
|
|
14321
14353
|
/* @__PURE__ */ jsxs66("span", { className: "flex min-w-0 items-center gap-0.5", children: [
|
|
14322
|
-
/* @__PURE__ */
|
|
14323
|
-
/* @__PURE__ */
|
|
14354
|
+
/* @__PURE__ */ jsx88(Hash, { className: "h-3 w-3 shrink-0" }),
|
|
14355
|
+
/* @__PURE__ */ jsx88("span", { className: "truncate font-mono", children: channel })
|
|
14324
14356
|
] }, "channel")
|
|
14325
14357
|
);
|
|
14326
14358
|
}
|
|
14327
14359
|
if (dateText)
|
|
14328
14360
|
metaParts.push(
|
|
14329
|
-
/* @__PURE__ */
|
|
14361
|
+
/* @__PURE__ */ jsx88("span", { className: "whitespace-nowrap", children: dateText }, "date")
|
|
14330
14362
|
);
|
|
14331
14363
|
const href = safeHref(item.url);
|
|
14332
14364
|
const body = /* @__PURE__ */ jsxs66(Fragment26, { children: [
|
|
14333
|
-
/* @__PURE__ */
|
|
14365
|
+
/* @__PURE__ */ jsx88("span", { className: COMPACT_CARD_ICON_SLOT, children: /* @__PURE__ */ jsx88(SlackIcon, { className: "h-5 w-5" }) }),
|
|
14334
14366
|
/* @__PURE__ */ jsxs66("span", { className: COMPACT_CARD_TEXT_COL, children: [
|
|
14335
|
-
/* @__PURE__ */
|
|
14336
|
-
/* @__PURE__ */
|
|
14337
|
-
/* @__PURE__ */
|
|
14338
|
-
i > 0 ? /* @__PURE__ */
|
|
14339
|
-
/* @__PURE__ */
|
|
14340
|
-
] }, i)) : /* @__PURE__ */
|
|
14367
|
+
/* @__PURE__ */ jsx88("span", { className: COMPACT_CARD_TITLE_ROW, children: /* @__PURE__ */ jsx88("span", { className: COMPACT_CARD_TITLE, children: item.title }) }),
|
|
14368
|
+
/* @__PURE__ */ jsx88("span", { className: COMPACT_CARD_META_ROW_BOX, children: /* @__PURE__ */ jsx88("span", { className: COMPACT_CARD_SUMMARY, children: item.preview || COMPACT_CARD_ROW_FILLER }) }),
|
|
14369
|
+
/* @__PURE__ */ jsx88("span", { className: COMPACT_CARD_META_ROW_BOX, children: /* @__PURE__ */ jsx88("span", { className: COMPACT_CARD_META_ROW, children: metaParts.length > 0 ? metaParts.map((part, i) => /* @__PURE__ */ jsxs66(React7.Fragment, { children: [
|
|
14370
|
+
i > 0 ? /* @__PURE__ */ jsx88("span", { className: "shrink-0 text-ods-text-secondary/40", children: "\xB7" }) : null,
|
|
14371
|
+
/* @__PURE__ */ jsx88("span", { className: "min-w-0 truncate", children: part })
|
|
14372
|
+
] }, i)) : /* @__PURE__ */ jsx88("span", { className: COMPACT_CARD_SUMMARY, children: COMPACT_CARD_ROW_FILLER }) }) })
|
|
14341
14373
|
] }),
|
|
14342
|
-
href ? /* @__PURE__ */
|
|
14374
|
+
href ? /* @__PURE__ */ jsx88("span", { className: "flex h-5 shrink-0 items-center self-start text-ods-text-secondary", children: /* @__PURE__ */ jsx88(ExternalLink2, { className: "h-3.5 w-3.5" }) }) : null
|
|
14343
14375
|
] });
|
|
14344
14376
|
if (anchorProps) {
|
|
14345
|
-
return /* @__PURE__ */
|
|
14377
|
+
return /* @__PURE__ */ jsx88("a", { ...anchorProps, className: `${COMPACT_CARD_OUTER} ${className ?? ""}`, children: body });
|
|
14346
14378
|
}
|
|
14347
|
-
return href ? /* @__PURE__ */
|
|
14379
|
+
return href ? /* @__PURE__ */ jsx88("a", { href, target: "_blank", rel: "noopener noreferrer", className: `${COMPACT_CARD_OUTER} ${className ?? ""}`, children: body }) : /* @__PURE__ */ jsx88("span", { className: `${COMPACT_CARD_OUTER_STATIC} ${className ?? ""}`, "aria-label": "No link available", children: body });
|
|
14348
14380
|
}
|
|
14349
14381
|
function SlackMessageCardSkeleton({
|
|
14350
14382
|
variant = "compact",
|
|
@@ -14352,28 +14384,28 @@ function SlackMessageCardSkeleton({
|
|
|
14352
14384
|
}) {
|
|
14353
14385
|
if (variant === "row") {
|
|
14354
14386
|
return /* @__PURE__ */ jsxs66("div", { className: `flex min-w-0 animate-pulse items-center gap-3 ${className ?? ""}`, children: [
|
|
14355
|
-
/* @__PURE__ */
|
|
14356
|
-
/* @__PURE__ */
|
|
14357
|
-
/* @__PURE__ */
|
|
14358
|
-
/* @__PURE__ */
|
|
14359
|
-
/* @__PURE__ */
|
|
14387
|
+
/* @__PURE__ */ jsx88("div", { className: "h-3.5 w-3.5 shrink-0 rounded bg-ods-bg" }),
|
|
14388
|
+
/* @__PURE__ */ jsx88("div", { className: "h-3 w-32 shrink-0 rounded bg-ods-bg" }),
|
|
14389
|
+
/* @__PURE__ */ jsx88("div", { className: "h-3 w-2/3 flex-1 rounded bg-ods-bg/60" }),
|
|
14390
|
+
/* @__PURE__ */ jsx88("div", { className: "h-3 w-24 shrink-0 rounded bg-ods-bg/60" }),
|
|
14391
|
+
/* @__PURE__ */ jsx88("div", { className: "h-3 w-20 shrink-0 rounded bg-ods-bg/60" })
|
|
14360
14392
|
] });
|
|
14361
14393
|
}
|
|
14362
14394
|
return /* @__PURE__ */ jsxs66("span", { className: `${COMPACT_CARD_SKELETON_OUTER} ${className ?? ""}`, children: [
|
|
14363
|
-
/* @__PURE__ */
|
|
14395
|
+
/* @__PURE__ */ jsx88("span", { className: COMPACT_CARD_SKELETON_IMAGE_SLOT }),
|
|
14364
14396
|
/* @__PURE__ */ jsxs66("span", { className: COMPACT_CARD_TEXT_COL, children: [
|
|
14365
|
-
/* @__PURE__ */
|
|
14366
|
-
/* @__PURE__ */
|
|
14367
|
-
/* @__PURE__ */
|
|
14397
|
+
/* @__PURE__ */ jsx88("span", { className: COMPACT_CARD_TITLE_ROW, children: /* @__PURE__ */ jsx88("span", { className: "h-3.5 w-2/3 rounded bg-ods-bg" }) }),
|
|
14398
|
+
/* @__PURE__ */ jsx88("span", { className: COMPACT_CARD_META_ROW_BOX, children: /* @__PURE__ */ jsx88("span", { className: "h-3 w-5/6 rounded bg-ods-bg/60" }) }),
|
|
14399
|
+
/* @__PURE__ */ jsx88("span", { className: COMPACT_CARD_META_ROW_BOX, children: /* @__PURE__ */ jsx88("span", { className: "h-3 w-1/3 rounded bg-ods-bg/70" }) })
|
|
14368
14400
|
] }),
|
|
14369
|
-
/* @__PURE__ */
|
|
14401
|
+
/* @__PURE__ */ jsx88("span", { className: "flex h-5 shrink-0 items-center self-start", children: /* @__PURE__ */ jsx88("span", { className: "h-3.5 w-3.5 rounded bg-ods-bg" }) })
|
|
14370
14402
|
] });
|
|
14371
14403
|
}
|
|
14372
14404
|
|
|
14373
14405
|
// src/components/chat/entity-cards/hubspot-ticket-card.tsx
|
|
14374
14406
|
import { ExternalLink as ExternalLink3 } from "lucide-react";
|
|
14375
14407
|
import React8 from "react";
|
|
14376
|
-
import { Fragment as Fragment27, jsx as
|
|
14408
|
+
import { Fragment as Fragment27, jsx as jsx89, jsxs as jsxs67 } from "react/jsx-runtime";
|
|
14377
14409
|
function formatToken(token) {
|
|
14378
14410
|
if (!token) return null;
|
|
14379
14411
|
const lower = token.toLowerCase().replace(/_/g, " ");
|
|
@@ -14398,28 +14430,28 @@ function HubspotTicketCard({ item, variant = "compact", className, anchorProps }
|
|
|
14398
14430
|
const dateText = formatDateUTC(item.dateUpdated, { fallback: "", timezone: "local" });
|
|
14399
14431
|
if (variant === "row") {
|
|
14400
14432
|
return /* @__PURE__ */ jsxs67("div", { className: `flex min-w-0 items-center gap-3 ${className ?? ""}`, children: [
|
|
14401
|
-
/* @__PURE__ */
|
|
14402
|
-
item.preview ? /* @__PURE__ */
|
|
14403
|
-
statusText ? /* @__PURE__ */
|
|
14404
|
-
dateText ? /* @__PURE__ */
|
|
14433
|
+
/* @__PURE__ */ jsx89("span", { className: "max-w-[260px] shrink-0 truncate text-ods-text-primary text-h6", children: item.title }),
|
|
14434
|
+
item.preview ? /* @__PURE__ */ jsx89("span", { className: "min-w-0 flex-1 truncate text-ods-text-secondary text-h6", children: item.preview }) : null,
|
|
14435
|
+
statusText ? /* @__PURE__ */ jsx89(StatusBadge, { text: statusText, variant: "button", colorScheme: statusScheme(item.status) }) : null,
|
|
14436
|
+
dateText ? /* @__PURE__ */ jsx89("span", { className: "w-24 shrink-0 text-right text-ods-text-secondary text-h6", children: dateText }) : null
|
|
14405
14437
|
] });
|
|
14406
14438
|
}
|
|
14407
14439
|
const metaParts = [];
|
|
14408
14440
|
if (item.customerCompany) {
|
|
14409
14441
|
metaParts.push(
|
|
14410
|
-
/* @__PURE__ */
|
|
14442
|
+
/* @__PURE__ */ jsx89("span", { className: "min-w-0 truncate", children: item.customerCompany }, "company")
|
|
14411
14443
|
);
|
|
14412
14444
|
}
|
|
14413
14445
|
if (dateText)
|
|
14414
14446
|
metaParts.push(
|
|
14415
|
-
/* @__PURE__ */
|
|
14447
|
+
/* @__PURE__ */ jsx89("span", { className: "whitespace-nowrap", children: dateText }, "date")
|
|
14416
14448
|
);
|
|
14417
14449
|
const href = safeHref(item.url);
|
|
14418
14450
|
const body = /* @__PURE__ */ jsxs67(Fragment27, { children: [
|
|
14419
14451
|
/* @__PURE__ */ jsxs67("span", { className: COMPACT_CARD_TEXT_COL, children: [
|
|
14420
14452
|
/* @__PURE__ */ jsxs67("span", { className: "flex min-w-0 flex-wrap items-center gap-1.5", children: [
|
|
14421
|
-
/* @__PURE__ */
|
|
14422
|
-
priorityText ? /* @__PURE__ */
|
|
14453
|
+
/* @__PURE__ */ jsx89("span", { className: `${COMPACT_CARD_TITLE} min-w-0 shrink`, children: item.title }),
|
|
14454
|
+
priorityText ? /* @__PURE__ */ jsx89(
|
|
14423
14455
|
StatusBadge,
|
|
14424
14456
|
{
|
|
14425
14457
|
text: priorityText,
|
|
@@ -14428,7 +14460,7 @@ function HubspotTicketCard({ item, variant = "compact", className, anchorProps }
|
|
|
14428
14460
|
className: "shrink-0"
|
|
14429
14461
|
}
|
|
14430
14462
|
) : null,
|
|
14431
|
-
statusText ? /* @__PURE__ */
|
|
14463
|
+
statusText ? /* @__PURE__ */ jsx89(
|
|
14432
14464
|
StatusBadge,
|
|
14433
14465
|
{
|
|
14434
14466
|
text: statusText,
|
|
@@ -14439,21 +14471,21 @@ function HubspotTicketCard({ item, variant = "compact", className, anchorProps }
|
|
|
14439
14471
|
) : null
|
|
14440
14472
|
] }),
|
|
14441
14473
|
item.customerEmail ? /* @__PURE__ */ jsxs67("span", { className: "flex min-w-0 items-center gap-1 text-ods-text-secondary text-h6", children: [
|
|
14442
|
-
/* @__PURE__ */
|
|
14443
|
-
/* @__PURE__ */
|
|
14474
|
+
/* @__PURE__ */ jsx89("span", { className: "shrink-0 text-ods-text-secondary/70", children: "From:" }),
|
|
14475
|
+
/* @__PURE__ */ jsx89("span", { className: "min-w-0 truncate", children: item.customerEmail })
|
|
14444
14476
|
] }) : null,
|
|
14445
|
-
/* @__PURE__ */
|
|
14446
|
-
metaParts.length > 0 ? /* @__PURE__ */
|
|
14447
|
-
i > 0 ? /* @__PURE__ */
|
|
14448
|
-
/* @__PURE__ */
|
|
14477
|
+
/* @__PURE__ */ jsx89("span", { className: "flex min-w-0", children: /* @__PURE__ */ jsx89("span", { className: "line-clamp-4 whitespace-pre-wrap break-words text-ods-text-secondary text-h6", children: item.preview || /* @__PURE__ */ jsx89("span", { className: "italic text-ods-text-secondary/60", children: "No description provided." }) }) }),
|
|
14478
|
+
metaParts.length > 0 ? /* @__PURE__ */ jsx89("span", { className: COMPACT_CARD_META_ROW_BOX, children: /* @__PURE__ */ jsx89("span", { className: COMPACT_CARD_META_ROW, children: metaParts.map((part, i) => /* @__PURE__ */ jsxs67(React8.Fragment, { children: [
|
|
14479
|
+
i > 0 ? /* @__PURE__ */ jsx89("span", { className: "shrink-0 text-ods-text-secondary/40", children: "\xB7" }) : null,
|
|
14480
|
+
/* @__PURE__ */ jsx89("span", { className: "min-w-0 truncate", children: part })
|
|
14449
14481
|
] }, i)) }) }) : null
|
|
14450
14482
|
] }),
|
|
14451
|
-
href ? /* @__PURE__ */
|
|
14483
|
+
href ? /* @__PURE__ */ jsx89("span", { className: "flex h-5 shrink-0 items-center self-start text-ods-text-secondary", children: /* @__PURE__ */ jsx89(ExternalLink3, { className: "h-3.5 w-3.5" }) }) : null
|
|
14452
14484
|
] });
|
|
14453
14485
|
if (anchorProps) {
|
|
14454
|
-
return /* @__PURE__ */
|
|
14486
|
+
return /* @__PURE__ */ jsx89("a", { ...anchorProps, className: `${COMPACT_CARD_OUTER} ${className ?? ""}`, children: body });
|
|
14455
14487
|
}
|
|
14456
|
-
return href ? /* @__PURE__ */
|
|
14488
|
+
return href ? /* @__PURE__ */ jsx89("a", { href, target: "_blank", rel: "noopener noreferrer", className: `${COMPACT_CARD_OUTER} ${className ?? ""}`, children: body }) : /* @__PURE__ */ jsx89("span", { className: `${COMPACT_CARD_OUTER_STATIC} ${className ?? ""}`, "aria-label": "No link available", children: body });
|
|
14457
14489
|
}
|
|
14458
14490
|
function HubspotTicketCardSkeleton({
|
|
14459
14491
|
variant = "compact",
|
|
@@ -14461,116 +14493,116 @@ function HubspotTicketCardSkeleton({
|
|
|
14461
14493
|
}) {
|
|
14462
14494
|
if (variant === "row") {
|
|
14463
14495
|
return /* @__PURE__ */ jsxs67("div", { className: `flex min-w-0 animate-pulse items-center gap-3 ${className ?? ""}`, children: [
|
|
14464
|
-
/* @__PURE__ */
|
|
14465
|
-
/* @__PURE__ */
|
|
14466
|
-
/* @__PURE__ */
|
|
14467
|
-
/* @__PURE__ */
|
|
14496
|
+
/* @__PURE__ */ jsx89("div", { className: "h-3 w-40 shrink-0 rounded bg-ods-bg" }),
|
|
14497
|
+
/* @__PURE__ */ jsx89("div", { className: "h-3 w-2/3 flex-1 rounded bg-ods-bg/60" }),
|
|
14498
|
+
/* @__PURE__ */ jsx89("div", { className: "h-3 w-16 shrink-0 rounded bg-ods-bg/60" }),
|
|
14499
|
+
/* @__PURE__ */ jsx89("div", { className: "h-3 w-20 shrink-0 rounded bg-ods-bg/60" })
|
|
14468
14500
|
] });
|
|
14469
14501
|
}
|
|
14470
14502
|
return /* @__PURE__ */ jsxs67("span", { className: `${COMPACT_CARD_SKELETON_OUTER} ${className ?? ""}`, children: [
|
|
14471
14503
|
/* @__PURE__ */ jsxs67("span", { className: COMPACT_CARD_TEXT_COL, children: [
|
|
14472
14504
|
/* @__PURE__ */ jsxs67("span", { className: "flex min-w-0 flex-wrap items-center gap-1.5", children: [
|
|
14473
|
-
/* @__PURE__ */
|
|
14474
|
-
/* @__PURE__ */
|
|
14475
|
-
/* @__PURE__ */
|
|
14505
|
+
/* @__PURE__ */ jsx89("span", { className: "h-3.5 w-2/3 rounded bg-ods-bg" }),
|
|
14506
|
+
/* @__PURE__ */ jsx89("span", { className: "h-4 w-12 rounded-full bg-ods-bg/60" }),
|
|
14507
|
+
/* @__PURE__ */ jsx89("span", { className: "h-4 w-16 rounded-full bg-ods-bg/60" })
|
|
14476
14508
|
] }),
|
|
14477
|
-
/* @__PURE__ */
|
|
14509
|
+
/* @__PURE__ */ jsx89("span", { className: "h-4 w-1/2 rounded bg-ods-bg/60" }),
|
|
14478
14510
|
/* @__PURE__ */ jsxs67("span", { className: "flex min-w-0 flex-col gap-0", children: [
|
|
14479
|
-
/* @__PURE__ */
|
|
14480
|
-
/* @__PURE__ */
|
|
14481
|
-
/* @__PURE__ */
|
|
14482
|
-
/* @__PURE__ */
|
|
14511
|
+
/* @__PURE__ */ jsx89("span", { className: "h-5 w-5/6 rounded bg-ods-bg/60" }),
|
|
14512
|
+
/* @__PURE__ */ jsx89("span", { className: "h-5 w-4/6 rounded bg-ods-bg/60" }),
|
|
14513
|
+
/* @__PURE__ */ jsx89("span", { className: "h-5 w-3/4 rounded bg-ods-bg/60" }),
|
|
14514
|
+
/* @__PURE__ */ jsx89("span", { className: "h-5 w-2/5 rounded bg-ods-bg/60" })
|
|
14483
14515
|
] }),
|
|
14484
|
-
/* @__PURE__ */
|
|
14516
|
+
/* @__PURE__ */ jsx89("span", { className: COMPACT_CARD_META_ROW_BOX, children: /* @__PURE__ */ jsx89("span", { className: "h-3 w-1/3 rounded bg-ods-bg/70" }) })
|
|
14485
14517
|
] }),
|
|
14486
|
-
/* @__PURE__ */
|
|
14518
|
+
/* @__PURE__ */ jsx89("span", { className: "flex h-5 shrink-0 items-center self-start", children: /* @__PURE__ */ jsx89("span", { className: "h-3.5 w-3.5 rounded bg-ods-bg" }) })
|
|
14487
14519
|
] });
|
|
14488
14520
|
}
|
|
14489
14521
|
|
|
14490
14522
|
// src/components/chat/entity-cards/data-room-doc-card.tsx
|
|
14491
14523
|
import { ExternalLink as ExternalLink4 } from "lucide-react";
|
|
14492
|
-
import { Fragment as Fragment28, jsx as
|
|
14524
|
+
import { Fragment as Fragment28, jsx as jsx90, jsxs as jsxs68 } from "react/jsx-runtime";
|
|
14493
14525
|
function DataRoomDocCard({ item, className, badgeText, anchorProps }) {
|
|
14494
14526
|
const body = /* @__PURE__ */ jsxs68(Fragment28, { children: [
|
|
14495
14527
|
/* @__PURE__ */ jsxs68("span", { className: COMPACT_CARD_TEXT_COL, children: [
|
|
14496
14528
|
/* @__PURE__ */ jsxs68("span", { className: "flex min-w-0 flex-wrap items-center gap-1.5", children: [
|
|
14497
|
-
/* @__PURE__ */
|
|
14498
|
-
/* @__PURE__ */
|
|
14529
|
+
/* @__PURE__ */ jsx90("span", { className: `${COMPACT_CARD_TITLE} min-w-0 shrink`, children: item.title }),
|
|
14530
|
+
/* @__PURE__ */ jsx90(StatusBadge, { text: badgeText, variant: "button", colorScheme: "cyan", className: "shrink-0" })
|
|
14499
14531
|
] }),
|
|
14500
14532
|
item.path ? /* @__PURE__ */ jsxs68("span", { className: "flex min-w-0 items-center gap-1 text-ods-text-secondary text-h6", children: [
|
|
14501
|
-
/* @__PURE__ */
|
|
14502
|
-
/* @__PURE__ */
|
|
14533
|
+
/* @__PURE__ */ jsx90("span", { className: "shrink-0 text-ods-text-secondary/70", children: "Path:" }),
|
|
14534
|
+
/* @__PURE__ */ jsx90("span", { className: "min-w-0 truncate font-mono", children: item.path })
|
|
14503
14535
|
] }) : null,
|
|
14504
|
-
item.preview ? /* @__PURE__ */
|
|
14536
|
+
item.preview ? /* @__PURE__ */ jsx90("span", { className: "flex min-w-0", children: /* @__PURE__ */ jsx90("span", { className: "line-clamp-2 whitespace-pre-wrap break-words text-ods-text-secondary text-h6", children: item.preview }) }) : null
|
|
14505
14537
|
] }),
|
|
14506
|
-
anchorProps?.href ? /* @__PURE__ */
|
|
14538
|
+
anchorProps?.href ? /* @__PURE__ */ jsx90("span", { className: "flex h-5 shrink-0 items-center self-start text-ods-text-secondary", children: /* @__PURE__ */ jsx90(ExternalLink4, { className: "h-3.5 w-3.5" }) }) : null
|
|
14507
14539
|
] });
|
|
14508
14540
|
if (!anchorProps) {
|
|
14509
|
-
return /* @__PURE__ */
|
|
14541
|
+
return /* @__PURE__ */ jsx90("span", { className: `${COMPACT_CARD_OUTER_STATIC} ${className ?? ""}`, "aria-label": "No link available", children: body });
|
|
14510
14542
|
}
|
|
14511
|
-
return /* @__PURE__ */
|
|
14543
|
+
return /* @__PURE__ */ jsx90("a", { ...anchorProps, className: `${COMPACT_CARD_OUTER} ${className ?? ""}`, children: body });
|
|
14512
14544
|
}
|
|
14513
14545
|
function DataRoomDocCardSkeleton({ className }) {
|
|
14514
14546
|
return /* @__PURE__ */ jsxs68("span", { className: `${COMPACT_CARD_SKELETON_OUTER} ${className ?? ""}`, children: [
|
|
14515
14547
|
/* @__PURE__ */ jsxs68("span", { className: COMPACT_CARD_TEXT_COL, children: [
|
|
14516
14548
|
/* @__PURE__ */ jsxs68("span", { className: "flex min-w-0 items-center gap-1.5", children: [
|
|
14517
|
-
/* @__PURE__ */
|
|
14518
|
-
/* @__PURE__ */
|
|
14549
|
+
/* @__PURE__ */ jsx90("span", { className: "h-3.5 w-2/3 rounded bg-ods-bg" }),
|
|
14550
|
+
/* @__PURE__ */ jsx90("span", { className: "h-4 w-16 rounded-full bg-ods-bg/60" })
|
|
14519
14551
|
] }),
|
|
14520
|
-
/* @__PURE__ */
|
|
14552
|
+
/* @__PURE__ */ jsx90("span", { className: "h-4 w-1/2 rounded bg-ods-bg/60" }),
|
|
14521
14553
|
/* @__PURE__ */ jsxs68("span", { className: "flex min-w-0 flex-col gap-0", children: [
|
|
14522
|
-
/* @__PURE__ */
|
|
14523
|
-
/* @__PURE__ */
|
|
14554
|
+
/* @__PURE__ */ jsx90("span", { className: "h-5 w-5/6 rounded bg-ods-bg/60" }),
|
|
14555
|
+
/* @__PURE__ */ jsx90("span", { className: "h-5 w-3/4 rounded bg-ods-bg/60" })
|
|
14524
14556
|
] })
|
|
14525
14557
|
] }),
|
|
14526
|
-
/* @__PURE__ */
|
|
14558
|
+
/* @__PURE__ */ jsx90("span", { className: "flex h-5 shrink-0 items-center self-start", children: /* @__PURE__ */ jsx90("span", { className: "h-3.5 w-3.5 rounded bg-ods-bg" }) })
|
|
14527
14559
|
] });
|
|
14528
14560
|
}
|
|
14529
14561
|
|
|
14530
14562
|
// src/components/chat/entity-cards/campaign-card-admin.tsx
|
|
14531
14563
|
import { Megaphone as Megaphone3 } from "lucide-react";
|
|
14532
|
-
import { Fragment as Fragment29, jsx as
|
|
14564
|
+
import { Fragment as Fragment29, jsx as jsx91, jsxs as jsxs69 } from "react/jsx-runtime";
|
|
14533
14565
|
function CampaignCardAdmin({ campaign, className, anchorProps }) {
|
|
14534
14566
|
const goalsCount = campaign.goals?.length || 0;
|
|
14535
14567
|
const innerChildren = /* @__PURE__ */ jsxs69(Fragment29, { children: [
|
|
14536
|
-
/* @__PURE__ */
|
|
14568
|
+
/* @__PURE__ */ jsx91("span", { className: COMPACT_CARD_ICON_SLOT, children: /* @__PURE__ */ jsx91(Megaphone3, { className: "h-5 w-5" }) }),
|
|
14537
14569
|
/* @__PURE__ */ jsxs69("span", { className: COMPACT_CARD_TEXT_COL, children: [
|
|
14538
|
-
/* @__PURE__ */
|
|
14539
|
-
/* @__PURE__ */
|
|
14570
|
+
/* @__PURE__ */ jsx91("span", { className: COMPACT_CARD_TITLE_ROW, children: /* @__PURE__ */ jsx91("span", { className: COMPACT_CARD_TITLE, children: campaign.name }) }),
|
|
14571
|
+
/* @__PURE__ */ jsx91("span", { className: COMPACT_CARD_META_ROW_BOX, children: /* @__PURE__ */ jsx91("span", { className: COMPACT_CARD_SUBTITLE, children: [
|
|
14540
14572
|
campaign.start_date ? formatDateShort(campaign.start_date) : null,
|
|
14541
14573
|
goalsCount > 0 ? `${goalsCount} goal${goalsCount !== 1 ? "s" : ""}` : null,
|
|
14542
14574
|
"Marketing campaign"
|
|
14543
14575
|
].filter(Boolean).join(" \xB7 ") }) }),
|
|
14544
|
-
/* @__PURE__ */
|
|
14576
|
+
/* @__PURE__ */ jsx91("span", { className: COMPACT_CARD_META_ROW_BOX, children: /* @__PURE__ */ jsx91("span", { className: COMPACT_CARD_SUMMARY, children: campaign.description || COMPACT_CARD_ROW_FILLER }) })
|
|
14545
14577
|
] })
|
|
14546
14578
|
] });
|
|
14547
14579
|
if (anchorProps) {
|
|
14548
|
-
return /* @__PURE__ */
|
|
14580
|
+
return /* @__PURE__ */ jsx91("a", { ...anchorProps, className: `${COMPACT_CARD_OUTER} ${className ?? ""}`, children: innerChildren });
|
|
14549
14581
|
}
|
|
14550
|
-
return /* @__PURE__ */
|
|
14582
|
+
return /* @__PURE__ */ jsx91("span", { className: `${COMPACT_CARD_OUTER_STATIC} ${className ?? ""}`, "aria-label": "No link available", children: innerChildren });
|
|
14551
14583
|
}
|
|
14552
14584
|
function CampaignCardAdminSkeleton({ className }) {
|
|
14553
14585
|
return /* @__PURE__ */ jsxs69("span", { className: `${COMPACT_CARD_SKELETON_OUTER} ${className ?? ""}`, children: [
|
|
14554
|
-
/* @__PURE__ */
|
|
14586
|
+
/* @__PURE__ */ jsx91("span", { className: COMPACT_CARD_SKELETON_IMAGE_SLOT }),
|
|
14555
14587
|
/* @__PURE__ */ jsxs69("span", { className: COMPACT_CARD_TEXT_COL, children: [
|
|
14556
|
-
/* @__PURE__ */
|
|
14557
|
-
/* @__PURE__ */
|
|
14558
|
-
/* @__PURE__ */
|
|
14588
|
+
/* @__PURE__ */ jsx91("span", { className: COMPACT_CARD_TITLE_ROW, children: /* @__PURE__ */ jsx91("span", { className: "h-3.5 w-3/5 rounded bg-ods-bg" }) }),
|
|
14589
|
+
/* @__PURE__ */ jsx91("span", { className: COMPACT_CARD_META_ROW_BOX, children: /* @__PURE__ */ jsx91("span", { className: "h-3 w-1/2 rounded bg-ods-bg/70" }) }),
|
|
14590
|
+
/* @__PURE__ */ jsx91("span", { className: COMPACT_CARD_META_ROW_BOX, children: /* @__PURE__ */ jsx91("span", { className: "h-3 w-11/12 rounded bg-ods-bg/40" }) })
|
|
14559
14591
|
] })
|
|
14560
14592
|
] });
|
|
14561
14593
|
}
|
|
14562
14594
|
|
|
14563
14595
|
// src/components/chat/entity-cards/generic-entity-card.tsx
|
|
14564
14596
|
import { ExternalLink as ExternalLink5 } from "lucide-react";
|
|
14565
|
-
import { Fragment as Fragment30, jsx as
|
|
14597
|
+
import { Fragment as Fragment30, jsx as jsx92, jsxs as jsxs70 } from "react/jsx-runtime";
|
|
14566
14598
|
function GenericEntityCard({ item, className, anchorProps }) {
|
|
14567
14599
|
const href = safeHref(item.url);
|
|
14568
14600
|
const dateText = formatDateUTC(item.dateUpdated, { fallback: "", timezone: "local" });
|
|
14569
14601
|
const body = /* @__PURE__ */ jsxs70(Fragment30, { children: [
|
|
14570
14602
|
/* @__PURE__ */ jsxs70("span", { className: COMPACT_CARD_TEXT_COL, children: [
|
|
14571
14603
|
/* @__PURE__ */ jsxs70("span", { className: "flex min-w-0 flex-wrap items-center gap-1.5", children: [
|
|
14572
|
-
/* @__PURE__ */
|
|
14573
|
-
item.badge ? /* @__PURE__ */
|
|
14604
|
+
/* @__PURE__ */ jsx92("span", { className: `${COMPACT_CARD_TITLE} min-w-0 shrink`, children: item.title }),
|
|
14605
|
+
item.badge ? /* @__PURE__ */ jsx92(
|
|
14574
14606
|
StatusBadge,
|
|
14575
14607
|
{
|
|
14576
14608
|
text: item.badge.text,
|
|
@@ -14580,39 +14612,39 @@ function GenericEntityCard({ item, className, anchorProps }) {
|
|
|
14580
14612
|
}
|
|
14581
14613
|
) : null
|
|
14582
14614
|
] }),
|
|
14583
|
-
item.subtitle ? /* @__PURE__ */
|
|
14584
|
-
item.preview ? /* @__PURE__ */
|
|
14585
|
-
item.facts && item.facts.length > 0 ? /* @__PURE__ */
|
|
14615
|
+
item.subtitle ? /* @__PURE__ */ jsx92("span", { className: "flex min-w-0 items-center gap-1 text-ods-text-secondary text-h6", children: /* @__PURE__ */ jsx92("span", { className: "min-w-0 truncate font-mono", children: item.subtitle }) }) : null,
|
|
14616
|
+
item.preview ? /* @__PURE__ */ jsx92("span", { className: "flex min-w-0", children: /* @__PURE__ */ jsx92("span", { className: "line-clamp-2 whitespace-pre-wrap break-words text-ods-text-secondary text-h6", children: item.preview }) }) : null,
|
|
14617
|
+
item.facts && item.facts.length > 0 ? /* @__PURE__ */ jsx92("span", { className: "flex min-w-0 flex-wrap items-center gap-x-3 gap-y-0.5 text-h6", children: item.facts.map((f, i) => /* @__PURE__ */ jsxs70("span", { className: "inline-flex min-w-0 items-center gap-1 truncate", children: [
|
|
14586
14618
|
/* @__PURE__ */ jsxs70("span", { className: "shrink-0 text-ods-text-secondary/70", children: [
|
|
14587
14619
|
f.label,
|
|
14588
14620
|
":"
|
|
14589
14621
|
] }),
|
|
14590
|
-
/* @__PURE__ */
|
|
14622
|
+
/* @__PURE__ */ jsx92("span", { className: "truncate font-medium text-ods-text-primary", children: f.value })
|
|
14591
14623
|
] }, i)) }) : null,
|
|
14592
|
-
dateText ? /* @__PURE__ */
|
|
14624
|
+
dateText ? /* @__PURE__ */ jsx92("span", { className: COMPACT_CARD_META_ROW_BOX, children: /* @__PURE__ */ jsx92("span", { className: COMPACT_CARD_META_ROW, children: /* @__PURE__ */ jsx92("span", { className: "whitespace-nowrap", children: dateText }) }) }) : null
|
|
14593
14625
|
] }),
|
|
14594
|
-
href ? /* @__PURE__ */
|
|
14626
|
+
href ? /* @__PURE__ */ jsx92("span", { className: "flex h-5 shrink-0 items-center self-start text-ods-text-secondary", children: /* @__PURE__ */ jsx92(ExternalLink5, { className: "h-3.5 w-3.5" }) }) : null
|
|
14595
14627
|
] });
|
|
14596
14628
|
if (anchorProps) {
|
|
14597
|
-
return /* @__PURE__ */
|
|
14629
|
+
return /* @__PURE__ */ jsx92("a", { ...anchorProps, className: `${COMPACT_CARD_OUTER} ${className ?? ""}`, children: body });
|
|
14598
14630
|
}
|
|
14599
|
-
return href ? /* @__PURE__ */
|
|
14631
|
+
return href ? /* @__PURE__ */ jsx92("a", { href, className: `${COMPACT_CARD_OUTER} ${className ?? ""}`, children: body }) : /* @__PURE__ */ jsx92("span", { className: `${COMPACT_CARD_OUTER_STATIC} ${className ?? ""}`, "aria-label": "No link available", children: body });
|
|
14600
14632
|
}
|
|
14601
14633
|
function GenericEntityCardSkeleton({ className }) {
|
|
14602
14634
|
return /* @__PURE__ */ jsxs70("span", { className: `${COMPACT_CARD_SKELETON_OUTER} ${className ?? ""}`, children: [
|
|
14603
14635
|
/* @__PURE__ */ jsxs70("span", { className: COMPACT_CARD_TEXT_COL, children: [
|
|
14604
14636
|
/* @__PURE__ */ jsxs70("span", { className: "flex min-w-0 items-center gap-1.5", children: [
|
|
14605
|
-
/* @__PURE__ */
|
|
14606
|
-
/* @__PURE__ */
|
|
14637
|
+
/* @__PURE__ */ jsx92("span", { className: "h-3.5 w-2/3 rounded bg-ods-bg" }),
|
|
14638
|
+
/* @__PURE__ */ jsx92("span", { className: "h-4 w-16 rounded-full bg-ods-bg/60" })
|
|
14607
14639
|
] }),
|
|
14608
|
-
/* @__PURE__ */
|
|
14640
|
+
/* @__PURE__ */ jsx92("span", { className: "h-4 w-1/2 rounded bg-ods-bg/60" }),
|
|
14609
14641
|
/* @__PURE__ */ jsxs70("span", { className: "flex min-w-0 flex-col gap-0", children: [
|
|
14610
|
-
/* @__PURE__ */
|
|
14611
|
-
/* @__PURE__ */
|
|
14642
|
+
/* @__PURE__ */ jsx92("span", { className: "h-5 w-5/6 rounded bg-ods-bg/60" }),
|
|
14643
|
+
/* @__PURE__ */ jsx92("span", { className: "h-5 w-3/4 rounded bg-ods-bg/60" })
|
|
14612
14644
|
] }),
|
|
14613
|
-
/* @__PURE__ */
|
|
14645
|
+
/* @__PURE__ */ jsx92("span", { className: "h-3 w-1/4 rounded bg-ods-bg/70" })
|
|
14614
14646
|
] }),
|
|
14615
|
-
/* @__PURE__ */
|
|
14647
|
+
/* @__PURE__ */ jsx92("span", { className: "flex h-5 shrink-0 items-center self-start", children: /* @__PURE__ */ jsx92("span", { className: "h-3.5 w-3.5 rounded bg-ods-bg" }) })
|
|
14616
14648
|
] });
|
|
14617
14649
|
}
|
|
14618
14650
|
|
|
@@ -14679,12 +14711,12 @@ function useChatCardItem(type, id) {
|
|
|
14679
14711
|
}
|
|
14680
14712
|
|
|
14681
14713
|
// src/components/chat/mingo-info-card.tsx
|
|
14682
|
-
import { Fragment as Fragment31, jsx as
|
|
14714
|
+
import { Fragment as Fragment31, jsx as jsx93, jsxs as jsxs71 } from "react/jsx-runtime";
|
|
14683
14715
|
function CardMedia({ imageSrc, imageAlt, icon }) {
|
|
14684
14716
|
if (imageSrc) {
|
|
14685
14717
|
return /* @__PURE__ */ jsxs71("span", { className: "relative block size-10 shrink-0", children: [
|
|
14686
|
-
/* @__PURE__ */
|
|
14687
|
-
/* @__PURE__ */
|
|
14718
|
+
/* @__PURE__ */ jsx93("span", { className: "absolute inset-0 flex items-center justify-center rounded-sm border border-ods-border bg-ods-bg text-ods-text-primary text-h6", children: personInitials(imageAlt) || "?" }),
|
|
14719
|
+
/* @__PURE__ */ jsx93(
|
|
14688
14720
|
next_image_default,
|
|
14689
14721
|
{
|
|
14690
14722
|
src: imageSrc,
|
|
@@ -14702,7 +14734,7 @@ function CardMedia({ imageSrc, imageAlt, icon }) {
|
|
|
14702
14734
|
] });
|
|
14703
14735
|
}
|
|
14704
14736
|
if (icon) {
|
|
14705
|
-
return /* @__PURE__ */
|
|
14737
|
+
return /* @__PURE__ */ jsx93("span", { className: "flex size-10 shrink-0 items-center justify-center overflow-hidden rounded-md border border-ods-border bg-ods-bg text-ods-text-secondary", children: /* @__PURE__ */ jsx93("span", { className: "flex size-6 items-center justify-center", children: icon }) });
|
|
14706
14738
|
}
|
|
14707
14739
|
return null;
|
|
14708
14740
|
}
|
|
@@ -14715,12 +14747,12 @@ function MingoInfoCardSkeleton({ className }) {
|
|
|
14715
14747
|
className
|
|
14716
14748
|
),
|
|
14717
14749
|
children: [
|
|
14718
|
-
/* @__PURE__ */
|
|
14750
|
+
/* @__PURE__ */ jsx93("span", { className: "block size-10 shrink-0 rounded-md border border-ods-border bg-ods-bg" }),
|
|
14719
14751
|
/* @__PURE__ */ jsxs71("span", { className: "flex min-w-0 flex-1 flex-col justify-center gap-1.5", children: [
|
|
14720
|
-
/* @__PURE__ */
|
|
14721
|
-
/* @__PURE__ */
|
|
14752
|
+
/* @__PURE__ */ jsx93("span", { className: "block h-4 w-1/2 rounded bg-ods-bg" }),
|
|
14753
|
+
/* @__PURE__ */ jsx93("span", { className: "block h-3 w-3/4 rounded bg-ods-bg/60" })
|
|
14722
14754
|
] }),
|
|
14723
|
-
/* @__PURE__ */
|
|
14755
|
+
/* @__PURE__ */ jsx93("span", { className: "block h-5 w-16 shrink-0 rounded bg-ods-bg/60" })
|
|
14724
14756
|
]
|
|
14725
14757
|
}
|
|
14726
14758
|
);
|
|
@@ -14743,15 +14775,15 @@ function MingoInfoCard({
|
|
|
14743
14775
|
const isAnchor = !!anchorProps;
|
|
14744
14776
|
const isInteractive = isAnchor || !!onClick;
|
|
14745
14777
|
const content = /* @__PURE__ */ jsxs71(Fragment31, { children: [
|
|
14746
|
-
hasMedia && /* @__PURE__ */
|
|
14778
|
+
hasMedia && /* @__PURE__ */ jsx93(CardMedia, { imageSrc, imageAlt, icon }),
|
|
14747
14779
|
/* @__PURE__ */ jsxs71("span", { className: "flex min-w-0 flex-1 flex-col justify-center", children: [
|
|
14748
|
-
/* @__PURE__ */
|
|
14749
|
-
description ? /* @__PURE__ */
|
|
14780
|
+
/* @__PURE__ */ jsx93("span", { className: "truncate text-ods-text-primary text-h4", children: title }),
|
|
14781
|
+
description ? /* @__PURE__ */ jsx93("span", { className: "truncate text-ods-text-secondary text-h6", children: description }) : null
|
|
14750
14782
|
] }),
|
|
14751
14783
|
status ? (
|
|
14752
14784
|
// Reuse the shared Tag palette (single source of truth for colours)
|
|
14753
14785
|
// without rendering Tag's `<div>` — span-only for `<p>` validity.
|
|
14754
|
-
/* @__PURE__ */
|
|
14786
|
+
/* @__PURE__ */ jsx93("span", { className: cn(tagVariants({ variant: status.variant ?? "success" }), "shrink-0"), children: /* @__PURE__ */ jsx93("span", { className: "truncate uppercase tracking-[-0.28px]", children: status.label }) })
|
|
14755
14787
|
) : null
|
|
14756
14788
|
] });
|
|
14757
14789
|
const contentClass = cn(
|
|
@@ -14767,20 +14799,20 @@ function MingoInfoCard({
|
|
|
14767
14799
|
className
|
|
14768
14800
|
),
|
|
14769
14801
|
children: [
|
|
14770
|
-
isAnchor ? /* @__PURE__ */
|
|
14771
|
-
hasMenu && /* @__PURE__ */
|
|
14802
|
+
isAnchor ? /* @__PURE__ */ jsx93("a", { ...anchorProps, className: cn(contentClass, "no-underline"), children: content }) : onClick ? /* @__PURE__ */ jsx93("button", { type: "button", onClick, className: contentClass, children: content }) : /* @__PURE__ */ jsx93("span", { className: contentClass, children: content }),
|
|
14803
|
+
hasMenu && /* @__PURE__ */ jsx93(
|
|
14772
14804
|
ActionsMenuDropdown,
|
|
14773
14805
|
{
|
|
14774
14806
|
groups: menuGroups,
|
|
14775
14807
|
triggerAriaLabel: menuAriaLabel,
|
|
14776
14808
|
onCloseAutoFocus: (e) => e.preventDefault(),
|
|
14777
|
-
customTrigger: /* @__PURE__ */
|
|
14809
|
+
customTrigger: /* @__PURE__ */ jsx93(
|
|
14778
14810
|
"button",
|
|
14779
14811
|
{
|
|
14780
14812
|
type: "button",
|
|
14781
14813
|
"aria-label": menuAriaLabel,
|
|
14782
14814
|
className: "flex w-[56px] shrink-0 items-center justify-center self-stretch text-ods-text-secondary transition-colors hover:bg-ods-bg-hover hover:text-ods-text-primary focus:outline-none focus-visible:ring-2 focus-visible:ring-inset focus-visible:ring-ods-accent active:bg-ods-bg-active active:text-ods-text-primary md:w-[68px]",
|
|
14783
|
-
children: /* @__PURE__ */
|
|
14815
|
+
children: /* @__PURE__ */ jsx93(Ellipsis01Icon, { size: 24 })
|
|
14784
14816
|
}
|
|
14785
14817
|
)
|
|
14786
14818
|
}
|
|
@@ -15415,14 +15447,14 @@ function resolveSourceIcon(input, ctx = {}) {
|
|
|
15415
15447
|
|
|
15416
15448
|
// src/components/chat/entity-cards/deleted-data-card.tsx
|
|
15417
15449
|
import { Trash2 } from "lucide-react";
|
|
15418
|
-
import { jsx as
|
|
15450
|
+
import { jsx as jsx94, jsxs as jsxs72 } from "react/jsx-runtime";
|
|
15419
15451
|
function DeletedDataCard({ title, entityLabel, recoveryNote, className }) {
|
|
15420
15452
|
const label = entityLabel || "Item";
|
|
15421
15453
|
return /* @__PURE__ */ jsxs72("div", { className: `${COMPACT_CARD_OUTER_STATIC} opacity-70 ${className ?? ""}`, children: [
|
|
15422
|
-
/* @__PURE__ */
|
|
15454
|
+
/* @__PURE__ */ jsx94("div", { className: COMPACT_CARD_ICON_SLOT, children: /* @__PURE__ */ jsx94(Trash2, { className: "h-4 w-4 text-ods-text-secondary" }) }),
|
|
15423
15455
|
/* @__PURE__ */ jsxs72("div", { className: COMPACT_CARD_TEXT_COL, children: [
|
|
15424
|
-
/* @__PURE__ */
|
|
15425
|
-
/* @__PURE__ */
|
|
15456
|
+
/* @__PURE__ */ jsx94("div", { className: COMPACT_CARD_TITLE_ROW, children: /* @__PURE__ */ jsx94("span", { className: `${COMPACT_CARD_TITLE} text-ods-text-secondary line-through`, children: title || `Deleted ${label.toLowerCase()}` }) }),
|
|
15457
|
+
/* @__PURE__ */ jsx94("div", { className: COMPACT_CARD_META_ROW, children: /* @__PURE__ */ jsxs72("span", { className: "text-ods-text-secondary", children: [
|
|
15426
15458
|
label,
|
|
15427
15459
|
" deleted",
|
|
15428
15460
|
recoveryNote ? ` \xB7 ${recoveryNote}` : ""
|
|
@@ -15432,16 +15464,16 @@ function DeletedDataCard({ title, entityLabel, recoveryNote, className }) {
|
|
|
15432
15464
|
}
|
|
15433
15465
|
|
|
15434
15466
|
// src/components/chat/entity-cards/dispatch.tsx
|
|
15435
|
-
import { Fragment as Fragment32, jsx as
|
|
15467
|
+
import { Fragment as Fragment32, jsx as jsx95, jsxs as jsxs73 } from "react/jsx-runtime";
|
|
15436
15468
|
function githubKindIcon(kind) {
|
|
15437
15469
|
switch (kind) {
|
|
15438
15470
|
case "pull_request":
|
|
15439
|
-
return /* @__PURE__ */
|
|
15471
|
+
return /* @__PURE__ */ jsx95(CodingPullRequestIcon, { size: 24 });
|
|
15440
15472
|
case "pr_review":
|
|
15441
|
-
return /* @__PURE__ */
|
|
15473
|
+
return /* @__PURE__ */ jsx95(CodeIcon, { size: 24 });
|
|
15442
15474
|
case "commit":
|
|
15443
15475
|
default:
|
|
15444
|
-
return /* @__PURE__ */
|
|
15476
|
+
return /* @__PURE__ */ jsx95(CodingCommitIcon, { size: 24 });
|
|
15445
15477
|
}
|
|
15446
15478
|
}
|
|
15447
15479
|
function reviewStateToVariant(state) {
|
|
@@ -15470,7 +15502,7 @@ function GitHubChatCard({
|
|
|
15470
15502
|
const idLabel = formatActivityId(chatRef.id, kind);
|
|
15471
15503
|
const dateText = formatDateUTC(chatRef.date ?? null, { fallback: "", timezone: "local" });
|
|
15472
15504
|
const description = [idLabel, dateText].filter(Boolean).join(" \xB7 ") || void 0;
|
|
15473
|
-
return /* @__PURE__ */
|
|
15505
|
+
return /* @__PURE__ */ jsx95(
|
|
15474
15506
|
MingoInfoCard,
|
|
15475
15507
|
{
|
|
15476
15508
|
title,
|
|
@@ -15497,12 +15529,12 @@ function cardMenuGroups(href, discuss, openDetails, externalLink) {
|
|
|
15497
15529
|
items.push({
|
|
15498
15530
|
id: "open-details",
|
|
15499
15531
|
label: openDetails?.label ?? "Open Details",
|
|
15500
|
-
icon: openDetails?.icon ?? /* @__PURE__ */
|
|
15532
|
+
icon: openDetails?.icon ?? /* @__PURE__ */ jsx95(EyeIcon, { size: 20 }),
|
|
15501
15533
|
// Main row → open the entity (same tab, soft Link nav).
|
|
15502
15534
|
href,
|
|
15503
15535
|
// Trailing 40px ↗ side-button → open in a new tab.
|
|
15504
15536
|
iconAction: {
|
|
15505
|
-
icon: /* @__PURE__ */
|
|
15537
|
+
icon: /* @__PURE__ */ jsx95(ArrowRightUpIcon, { size: 20 }),
|
|
15506
15538
|
"aria-label": "Open in new tab",
|
|
15507
15539
|
href,
|
|
15508
15540
|
openInNewTab: true
|
|
@@ -15577,12 +15609,12 @@ function itemVideoMetadata(item) {
|
|
|
15577
15609
|
return out.videoUrl || out.youtubeUrl || out.highlightVideoUrl ? out : null;
|
|
15578
15610
|
}
|
|
15579
15611
|
function CardLoadFailure({ label, id, detail }) {
|
|
15580
|
-
return /* @__PURE__ */
|
|
15612
|
+
return /* @__PURE__ */ jsx95(
|
|
15581
15613
|
MingoInfoCard,
|
|
15582
15614
|
{
|
|
15583
15615
|
title: label,
|
|
15584
15616
|
description: `${detail} \xB7 id: ${id}`,
|
|
15585
|
-
icon: /* @__PURE__ */
|
|
15617
|
+
icon: /* @__PURE__ */ jsx95(AlertTriangleIcon, { size: 24 }),
|
|
15586
15618
|
status: { label: "FAILED", variant: "error" },
|
|
15587
15619
|
menuAriaLabel: "Card failed to load"
|
|
15588
15620
|
}
|
|
@@ -15617,17 +15649,17 @@ function HubspotTicketChatCard({
|
|
|
15617
15649
|
const status = typeof chatRef.metadata?.status === "string" ? chatRef.metadata.status : void 0;
|
|
15618
15650
|
const statusLabel = typeof chatRef.metadata?.statusLabel === "string" ? chatRef.metadata.statusLabel : void 0;
|
|
15619
15651
|
const statusText = statusLabel ?? formatStatusToken(status);
|
|
15620
|
-
return /* @__PURE__ */
|
|
15652
|
+
return /* @__PURE__ */ jsx95(
|
|
15621
15653
|
MingoInfoCard,
|
|
15622
15654
|
{
|
|
15623
15655
|
title: chatRef.title,
|
|
15624
15656
|
description: chatRef.preview ?? void 0,
|
|
15625
|
-
icon: /* @__PURE__ */
|
|
15657
|
+
icon: /* @__PURE__ */ jsx95(TagIcon, { size: 24 }),
|
|
15626
15658
|
status: statusText ? { label: statusText, variant: hubspotStatusToVariant(status) } : void 0,
|
|
15627
15659
|
anchorProps: buildAnchorProps(chatRef.url, isNewTab),
|
|
15628
15660
|
menuGroups: cardMenuGroups(chatRef.url, discuss, {
|
|
15629
15661
|
label: "Open Ticket Details",
|
|
15630
|
-
icon: /* @__PURE__ */
|
|
15662
|
+
icon: /* @__PURE__ */ jsx95(TagIcon, { size: 20 })
|
|
15631
15663
|
}),
|
|
15632
15664
|
menuAriaLabel: "Ticket actions"
|
|
15633
15665
|
}
|
|
@@ -15640,12 +15672,12 @@ function FaqChatCard({
|
|
|
15640
15672
|
}) {
|
|
15641
15673
|
const section = typeof chatRef.metadata?.section === "string" ? chatRef.metadata.section.trim() : void 0;
|
|
15642
15674
|
const statusLabel = section && section.length > 0 ? section : "FAQ";
|
|
15643
|
-
return /* @__PURE__ */
|
|
15675
|
+
return /* @__PURE__ */ jsx95(
|
|
15644
15676
|
MingoInfoCard,
|
|
15645
15677
|
{
|
|
15646
15678
|
title: chatRef.title,
|
|
15647
15679
|
description: chatRef.preview ?? void 0,
|
|
15648
|
-
icon: /* @__PURE__ */
|
|
15680
|
+
icon: /* @__PURE__ */ jsx95(QuestionCircleIcon, { size: 24 }),
|
|
15649
15681
|
status: { label: statusLabel, variant: "grey" },
|
|
15650
15682
|
anchorProps: buildAnchorProps(chatRef.url, isNewTab),
|
|
15651
15683
|
menuGroups: cardMenuGroups(chatRef.url, discuss),
|
|
@@ -15661,12 +15693,12 @@ function SlackChatCard({
|
|
|
15661
15693
|
const channelName = typeof chatRef.metadata?.channelName === "string" ? chatRef.metadata.channelName.trim() : void 0;
|
|
15662
15694
|
const channelPretty = channelName ? channelName.startsWith("#") ? channelName : `#${channelName}` : void 0;
|
|
15663
15695
|
const title = channelPretty ? `${chatRef.title} \xB7 ${channelPretty}` : chatRef.title;
|
|
15664
|
-
return /* @__PURE__ */
|
|
15696
|
+
return /* @__PURE__ */ jsx95(
|
|
15665
15697
|
MingoInfoCard,
|
|
15666
15698
|
{
|
|
15667
15699
|
title,
|
|
15668
15700
|
description: chatRef.preview ?? void 0,
|
|
15669
|
-
icon: /* @__PURE__ */
|
|
15701
|
+
icon: /* @__PURE__ */ jsx95(SlackLogoGreyIcon, { size: 24 }),
|
|
15670
15702
|
anchorProps: buildAnchorProps(chatRef.url, isNewTab),
|
|
15671
15703
|
menuGroups: cardMenuGroups(chatRef.url, discuss),
|
|
15672
15704
|
menuAriaLabel: "Message actions"
|
|
@@ -15679,7 +15711,7 @@ function GlyphChatCard({
|
|
|
15679
15711
|
isNewTab,
|
|
15680
15712
|
discuss
|
|
15681
15713
|
}) {
|
|
15682
|
-
return /* @__PURE__ */
|
|
15714
|
+
return /* @__PURE__ */ jsx95(
|
|
15683
15715
|
MingoInfoCard,
|
|
15684
15716
|
{
|
|
15685
15717
|
title: chatRef.title,
|
|
@@ -15697,12 +15729,12 @@ function DataRoomDocChatCard({
|
|
|
15697
15729
|
discuss
|
|
15698
15730
|
}) {
|
|
15699
15731
|
const badgeText = chatRef.sourceRepo ? getSourceLabel(chatRef.sourceRepo) : "Document";
|
|
15700
|
-
return /* @__PURE__ */
|
|
15732
|
+
return /* @__PURE__ */ jsx95(
|
|
15701
15733
|
MingoInfoCard,
|
|
15702
15734
|
{
|
|
15703
15735
|
title: chatRef.title,
|
|
15704
15736
|
description: chatRef.preview ?? void 0,
|
|
15705
|
-
icon: /* @__PURE__ */
|
|
15737
|
+
icon: /* @__PURE__ */ jsx95(FileContentIcon, { size: 24 }),
|
|
15706
15738
|
status: { label: badgeText, variant: "grey" },
|
|
15707
15739
|
anchorProps: buildAnchorProps(chatRef.url, isNewTab),
|
|
15708
15740
|
menuGroups: cardMenuGroups(chatRef.url, discuss),
|
|
@@ -15717,7 +15749,7 @@ function GenericFinancialChatCard({
|
|
|
15717
15749
|
discuss
|
|
15718
15750
|
}) {
|
|
15719
15751
|
const subtitle = typeof chatRef.metadata?.subtitle === "string" ? chatRef.metadata.subtitle : void 0;
|
|
15720
|
-
return /* @__PURE__ */
|
|
15752
|
+
return /* @__PURE__ */ jsx95(
|
|
15721
15753
|
MingoInfoCard,
|
|
15722
15754
|
{
|
|
15723
15755
|
title: chatRef.title,
|
|
@@ -15732,8 +15764,8 @@ function GenericFinancialChatCard({
|
|
|
15732
15764
|
function ChatInlineVideoPill({ chatRef }) {
|
|
15733
15765
|
const title = chatRef.title || "Video";
|
|
15734
15766
|
return /* @__PURE__ */ jsxs73("span", { className: "inline-flex items-center gap-1 rounded border border-ods-border bg-ods-card px-1.5 py-0.5 align-middle text-xs text-ods-text-primary", children: [
|
|
15735
|
-
/* @__PURE__ */
|
|
15736
|
-
/* @__PURE__ */
|
|
15767
|
+
/* @__PURE__ */ jsx95("span", { "aria-hidden": "true", className: "text-ods-text-secondary", children: "\u25B6" }),
|
|
15768
|
+
/* @__PURE__ */ jsx95("span", { className: "max-w-[220px] truncate", children: title })
|
|
15737
15769
|
] });
|
|
15738
15770
|
}
|
|
15739
15771
|
function ChatCardWithDiscuss({
|
|
@@ -15749,11 +15781,11 @@ function ChatCardWithDiscuss({
|
|
|
15749
15781
|
});
|
|
15750
15782
|
const idDisplay = chatRef.id && (chatRef.id.length > 24 ? `${chatRef.id.slice(0, 24)}\u2026` : chatRef.id);
|
|
15751
15783
|
const useDisplay = displayAction && !!onDisplay;
|
|
15752
|
-
const cardBody = /* @__PURE__ */
|
|
15784
|
+
const cardBody = /* @__PURE__ */ jsx95("span", { className: "block [&>*]:!my-0", children });
|
|
15753
15785
|
return /* @__PURE__ */ jsxs73("span", { className: "mb-2 mt-1.5 block w-full", children: [
|
|
15754
15786
|
cardBody,
|
|
15755
15787
|
/* @__PURE__ */ jsxs73("span", { className: "mt-1 flex items-center justify-between gap-2 pl-0.5", children: [
|
|
15756
|
-
/* @__PURE__ */
|
|
15788
|
+
/* @__PURE__ */ jsx95(
|
|
15757
15789
|
SourceActionButton,
|
|
15758
15790
|
{
|
|
15759
15791
|
chatRef,
|
|
@@ -15762,15 +15794,15 @@ function ChatCardWithDiscuss({
|
|
|
15762
15794
|
density: "card"
|
|
15763
15795
|
}
|
|
15764
15796
|
),
|
|
15765
|
-
!onDiscuss && !useDisplay ? /* @__PURE__ */
|
|
15797
|
+
!onDiscuss && !useDisplay ? /* @__PURE__ */ jsx95("span", {}) : null,
|
|
15766
15798
|
idDisplay ? /* @__PURE__ */ jsxs73(
|
|
15767
15799
|
"span",
|
|
15768
15800
|
{
|
|
15769
15801
|
className: "inline-flex shrink-0 items-center gap-1 text-ods-text-secondary opacity-60 transition-opacity text-code hover:text-ods-text-primary hover:opacity-100",
|
|
15770
15802
|
title: `${sourceLabel} \xB7 ${chatRef.id}`,
|
|
15771
15803
|
children: [
|
|
15772
|
-
/* @__PURE__ */
|
|
15773
|
-
/* @__PURE__ */
|
|
15804
|
+
/* @__PURE__ */ jsx95(SourceIcon, { className: "h-3 w-3 shrink-0" }),
|
|
15805
|
+
/* @__PURE__ */ jsx95("span", { className: "max-w-[180px] truncate", children: idDisplay })
|
|
15774
15806
|
]
|
|
15775
15807
|
}
|
|
15776
15808
|
) : null
|
|
@@ -15786,13 +15818,13 @@ function ProductReleaseChatCard({
|
|
|
15786
15818
|
}) {
|
|
15787
15819
|
const releaseProps = buildProps(item);
|
|
15788
15820
|
const status = item?.version ? { label: String(item.version), variant: "grey" } : { label: "Release", variant: "grey" };
|
|
15789
|
-
return /* @__PURE__ */
|
|
15821
|
+
return /* @__PURE__ */ jsx95(
|
|
15790
15822
|
EntityMingoCard,
|
|
15791
15823
|
{
|
|
15792
15824
|
title: item?.title ?? "",
|
|
15793
15825
|
description: item?.summary || releaseProps.formattedDate || void 0,
|
|
15794
15826
|
cover: releaseProps.coverImage || void 0,
|
|
15795
|
-
fallbackIcon: /* @__PURE__ */
|
|
15827
|
+
fallbackIcon: /* @__PURE__ */ jsx95(Rocket02Icon, { size: 24 }),
|
|
15796
15828
|
status,
|
|
15797
15829
|
chatRef,
|
|
15798
15830
|
isNewTab,
|
|
@@ -15813,12 +15845,12 @@ function CampaignChatCard({
|
|
|
15813
15845
|
goalsCount > 0 ? `${goalsCount} goal${goalsCount !== 1 ? "s" : ""}` : null,
|
|
15814
15846
|
"Marketing campaign"
|
|
15815
15847
|
].filter(Boolean).join(" \xB7 ");
|
|
15816
|
-
return /* @__PURE__ */
|
|
15848
|
+
return /* @__PURE__ */ jsx95(
|
|
15817
15849
|
EntityMingoCard,
|
|
15818
15850
|
{
|
|
15819
15851
|
title: item?.name ?? "",
|
|
15820
15852
|
description: meta || item?.description || void 0,
|
|
15821
|
-
fallbackIcon: /* @__PURE__ */
|
|
15853
|
+
fallbackIcon: /* @__PURE__ */ jsx95(Megaphone01Icon, { size: 24 }),
|
|
15822
15854
|
chatRef,
|
|
15823
15855
|
isNewTab,
|
|
15824
15856
|
discuss,
|
|
@@ -15839,7 +15871,7 @@ function EntityMingoCard({
|
|
|
15839
15871
|
openDetails,
|
|
15840
15872
|
externalLink
|
|
15841
15873
|
}) {
|
|
15842
|
-
return /* @__PURE__ */
|
|
15874
|
+
return /* @__PURE__ */ jsx95(
|
|
15843
15875
|
MingoInfoCard,
|
|
15844
15876
|
{
|
|
15845
15877
|
title,
|
|
@@ -15874,13 +15906,13 @@ function BlogChatCard({
|
|
|
15874
15906
|
}) {
|
|
15875
15907
|
const category = Array.isArray(item?.categories) ? item.categories.find((c) => c?.name)?.name ?? void 0 : void 0;
|
|
15876
15908
|
const status = hasEmbeddedVideo ? { label: "Video", variant: "primary" } : category ? { label: category, variant: "grey" } : void 0;
|
|
15877
|
-
return /* @__PURE__ */
|
|
15909
|
+
return /* @__PURE__ */ jsx95(
|
|
15878
15910
|
EntityMingoCard,
|
|
15879
15911
|
{
|
|
15880
15912
|
title: item?.title ?? "",
|
|
15881
15913
|
description: item?.summary ?? void 0,
|
|
15882
15914
|
cover: entityCover(item?.featured_image, ogPlaceholder),
|
|
15883
|
-
fallbackIcon: /* @__PURE__ */
|
|
15915
|
+
fallbackIcon: /* @__PURE__ */ jsx95(NewspaperIcon, { size: 24 }),
|
|
15884
15916
|
status,
|
|
15885
15917
|
chatRef,
|
|
15886
15918
|
isNewTab,
|
|
@@ -15897,13 +15929,13 @@ function CaseStudyChatCard({
|
|
|
15897
15929
|
discuss
|
|
15898
15930
|
}) {
|
|
15899
15931
|
const meta = [item?.msp?.name, item?.user?.full_name].filter(Boolean).join(" \xB7 ");
|
|
15900
|
-
return /* @__PURE__ */
|
|
15932
|
+
return /* @__PURE__ */ jsx95(
|
|
15901
15933
|
EntityMingoCard,
|
|
15902
15934
|
{
|
|
15903
15935
|
title: item?.title ?? "",
|
|
15904
15936
|
description: item?.summary || meta || void 0,
|
|
15905
15937
|
cover: entityCover(item?.featured_image, ogPlaceholder),
|
|
15906
|
-
fallbackIcon: /* @__PURE__ */
|
|
15938
|
+
fallbackIcon: /* @__PURE__ */ jsx95(TrophyIcon, { size: 24 }),
|
|
15907
15939
|
status: { label: "Case study", variant: "grey" },
|
|
15908
15940
|
chatRef,
|
|
15909
15941
|
isNewTab,
|
|
@@ -15920,13 +15952,13 @@ function CustomerInterviewChatCard({
|
|
|
15920
15952
|
discuss
|
|
15921
15953
|
}) {
|
|
15922
15954
|
const meta = [item?.user?.full_name, item?.msp?.name].filter(Boolean).join(" \xB7 ");
|
|
15923
|
-
return /* @__PURE__ */
|
|
15955
|
+
return /* @__PURE__ */ jsx95(
|
|
15924
15956
|
EntityMingoCard,
|
|
15925
15957
|
{
|
|
15926
15958
|
title: item?.title ?? "",
|
|
15927
15959
|
description: item?.video_summary || meta || void 0,
|
|
15928
15960
|
cover: entityCover(item?.featured_image, ogPlaceholder),
|
|
15929
|
-
fallbackIcon: /* @__PURE__ */
|
|
15961
|
+
fallbackIcon: /* @__PURE__ */ jsx95(MicrophoneIcon, { size: 24 }),
|
|
15930
15962
|
status: { label: "Interview", variant: "grey" },
|
|
15931
15963
|
chatRef,
|
|
15932
15964
|
isNewTab,
|
|
@@ -15943,13 +15975,13 @@ function InvestorUpdateChatCard({
|
|
|
15943
15975
|
discuss
|
|
15944
15976
|
}) {
|
|
15945
15977
|
const title = item?.title || `Update #${item?.update_number ?? "?"}`;
|
|
15946
|
-
return /* @__PURE__ */
|
|
15978
|
+
return /* @__PURE__ */ jsx95(
|
|
15947
15979
|
EntityMingoCard,
|
|
15948
15980
|
{
|
|
15949
15981
|
title,
|
|
15950
15982
|
description: item?.strategic_update || item?.content || formatInvestorUpdatePeriod(item?.period_start ?? null, item?.period_end ?? null) || void 0,
|
|
15951
15983
|
cover: entityCover(item?.featured_image, ogPlaceholder),
|
|
15952
|
-
fallbackIcon: /* @__PURE__ */
|
|
15984
|
+
fallbackIcon: /* @__PURE__ */ jsx95(PresentationLineIcon, { size: 24 }),
|
|
15953
15985
|
status: { label: "Investor update", variant: "grey" },
|
|
15954
15986
|
chatRef,
|
|
15955
15987
|
isNewTab,
|
|
@@ -15966,13 +15998,13 @@ function OnboardingGuideChatCard({
|
|
|
15966
15998
|
discuss
|
|
15967
15999
|
}) {
|
|
15968
16000
|
const cover = entityCover(item?.featured_image) ?? entityCover(item?.main_video_thumbnail) ?? entityCover(item?.og_image_url, ogPlaceholder);
|
|
15969
|
-
return /* @__PURE__ */
|
|
16001
|
+
return /* @__PURE__ */ jsx95(
|
|
15970
16002
|
EntityMingoCard,
|
|
15971
16003
|
{
|
|
15972
16004
|
title: item?.title ?? "",
|
|
15973
16005
|
description: item?.summary ?? item?.description ?? void 0,
|
|
15974
16006
|
cover,
|
|
15975
|
-
fallbackIcon: /* @__PURE__ */
|
|
16007
|
+
fallbackIcon: /* @__PURE__ */ jsx95(CompassIcon, { size: 24 }),
|
|
15976
16008
|
status: { label: "Guide", variant: "grey" },
|
|
15977
16009
|
chatRef,
|
|
15978
16010
|
isNewTab,
|
|
@@ -15990,9 +16022,9 @@ function ProgramChatCard({
|
|
|
15990
16022
|
ogPlaceholder,
|
|
15991
16023
|
discuss
|
|
15992
16024
|
}) {
|
|
15993
|
-
const icon = configKey === "webinar" ? /* @__PURE__ */
|
|
16025
|
+
const icon = configKey === "webinar" ? /* @__PURE__ */ jsx95(PresentationBarIcon, { size: 24 }) : configKey === "event" ? /* @__PURE__ */ jsx95(CalendarIcon, { size: 24 }) : /* @__PURE__ */ jsx95(MicrophoneIcon, { size: 24 });
|
|
15994
16026
|
const { line: meta } = programMetaLine(item ?? {}, configKey, programMetaFormatters(PROGRAM_META_RENDERERS));
|
|
15995
|
-
return /* @__PURE__ */
|
|
16027
|
+
return /* @__PURE__ */ jsx95(
|
|
15996
16028
|
EntityMingoCard,
|
|
15997
16029
|
{
|
|
15998
16030
|
title: item?.title ?? "",
|
|
@@ -16016,16 +16048,16 @@ function RoadmapChatCard({
|
|
|
16016
16048
|
}) {
|
|
16017
16049
|
const logoUrl = typeof item?.icon === "string" && item.icon.startsWith("http") ? item.icon : void 0;
|
|
16018
16050
|
const useTypeIcon = cardType === "internal_task" || !logoUrl && item?.customItemId != null;
|
|
16019
|
-
const defaultIcon = cardType === "delivery_item" ? /* @__PURE__ */
|
|
16020
|
-
const icon = useTypeIcon ? /* @__PURE__ */
|
|
16051
|
+
const defaultIcon = cardType === "delivery_item" ? /* @__PURE__ */ jsx95(TruckFastIcon, { size: 24 }) : cardType === "internal_task" ? /* @__PURE__ */ jsx95(CheckSquareIcon, { size: 24 }) : /* @__PURE__ */ jsx95(MapIcon, { size: 24 });
|
|
16052
|
+
const icon = useTypeIcon ? /* @__PURE__ */ jsx95(TaskTypeIcon, { customItemId: item?.customItemId, className: "size-6" }) : logoUrl ? (
|
|
16021
16053
|
// Contained (not full-bleed) so the integration logo keeps its aspect
|
|
16022
16054
|
// ratio inside the bordered icon box — matches RoadmapCard.
|
|
16023
|
-
/* @__PURE__ */
|
|
16055
|
+
/* @__PURE__ */ jsx95(next_image_default, { src: logoUrl, alt: "", className: "size-6 object-contain", width: 24, height: 24, unoptimized: true })
|
|
16024
16056
|
) : defaultIcon;
|
|
16025
16057
|
const clickupHref = clickupTaskUrl(chatRef.id);
|
|
16026
|
-
const clickupIcon = /* @__PURE__ */
|
|
16058
|
+
const clickupIcon = /* @__PURE__ */ jsx95(ClickupLogoIcon, { size: 20 });
|
|
16027
16059
|
const cardUrlIsClickup = cardType === "internal_task";
|
|
16028
|
-
return /* @__PURE__ */
|
|
16060
|
+
return /* @__PURE__ */ jsx95(
|
|
16029
16061
|
EntityMingoCard,
|
|
16030
16062
|
{
|
|
16031
16063
|
title: item?.title ?? "",
|
|
@@ -16048,16 +16080,16 @@ function refHydratedEntry(docType, label, renderRef) {
|
|
|
16048
16080
|
contentRefType: docType,
|
|
16049
16081
|
noComposedHref: true,
|
|
16050
16082
|
fallbackHref: (item) => item?.url ?? null,
|
|
16051
|
-
skeleton: () => /* @__PURE__ */
|
|
16083
|
+
skeleton: () => /* @__PURE__ */ jsx95(MingoInfoCardSkeleton, {}),
|
|
16052
16084
|
render: (item, chatRef, opts) => renderRef(fetchedItemDisplayRef(item, chatRef), opts)
|
|
16053
16085
|
};
|
|
16054
16086
|
}
|
|
16055
16087
|
var FINANCIAL_CARD_CONFIGS = {
|
|
16056
|
-
financial_kpi: { label: "Financial KPI", icon: () => /* @__PURE__ */
|
|
16057
|
-
cap_table: { label: "Cap table entry", icon: () => /* @__PURE__ */
|
|
16058
|
-
profit_loss: { label: "P&L period", icon: () => /* @__PURE__ */
|
|
16059
|
-
balance_sheet: { label: "Balance sheet", icon: () => /* @__PURE__ */
|
|
16060
|
-
cash_flow: { label: "Cash flow", icon: () => /* @__PURE__ */
|
|
16088
|
+
financial_kpi: { label: "Financial KPI", icon: () => /* @__PURE__ */ jsx95(ChartBar01VerIcon, { size: 24 }) },
|
|
16089
|
+
cap_table: { label: "Cap table entry", icon: () => /* @__PURE__ */ jsx95(ChartPieIcon, { size: 24 }) },
|
|
16090
|
+
profit_loss: { label: "P&L period", icon: () => /* @__PURE__ */ jsx95(MoneyBillDollarIcon, { size: 24 }) },
|
|
16091
|
+
balance_sheet: { label: "Balance sheet", icon: () => /* @__PURE__ */ jsx95(BankIcon, { size: 24 }) },
|
|
16092
|
+
cash_flow: { label: "Cash flow", icon: () => /* @__PURE__ */ jsx95(CoinsExchangeCurrencyIcon, { size: 24 }) }
|
|
16061
16093
|
};
|
|
16062
16094
|
function registryEntries(configs, build) {
|
|
16063
16095
|
const out = {};
|
|
@@ -16067,7 +16099,7 @@ function registryEntries(configs, build) {
|
|
|
16067
16099
|
function financialRegistryEntries() {
|
|
16068
16100
|
return registryEntries(
|
|
16069
16101
|
FINANCIAL_CARD_CONFIGS,
|
|
16070
|
-
(cfg, docType) => refHydratedEntry(docType, cfg.label, (displayRef, opts) => /* @__PURE__ */
|
|
16102
|
+
(cfg, docType) => refHydratedEntry(docType, cfg.label, (displayRef, opts) => /* @__PURE__ */ jsx95(
|
|
16071
16103
|
GenericFinancialChatCard,
|
|
16072
16104
|
{
|
|
16073
16105
|
chatRef: displayRef,
|
|
@@ -16088,24 +16120,24 @@ var GITHUB_CARD_CONFIGS = {
|
|
|
16088
16120
|
};
|
|
16089
16121
|
var OpenFrameGlyph = resolveIcon("openframe");
|
|
16090
16122
|
var REF_GLYPH_CARD_CONFIGS = {
|
|
16091
|
-
design_doc: { label: "Design doc", icon: () => /* @__PURE__ */
|
|
16092
|
-
openframe_tenant: { label: "OpenFrame tenant", icon: () => /* @__PURE__ */
|
|
16093
|
-
prospect_call: { label: "Prospect call", icon: () => /* @__PURE__ */
|
|
16123
|
+
design_doc: { label: "Design doc", icon: () => /* @__PURE__ */ jsx95(FileContentIcon, { size: 24 }) },
|
|
16124
|
+
openframe_tenant: { label: "OpenFrame tenant", icon: () => /* @__PURE__ */ jsx95(OpenFrameGlyph, { size: 24 }) },
|
|
16125
|
+
prospect_call: { label: "Prospect call", icon: () => /* @__PURE__ */ jsx95(CallIcon, { size: 24 }), media: true },
|
|
16094
16126
|
// Code intelligence (product-hub internal): the review rules a repository is
|
|
16095
16127
|
// held to, the repositories themselves, and one row per deployment
|
|
16096
16128
|
// environment. Glyph cards like their siblings — none of the three has a
|
|
16097
16129
|
// cover image, and a rule is read in the admin screen it links to.
|
|
16098
|
-
code_rule: { label: "Code rule", icon: () => /* @__PURE__ */
|
|
16099
|
-
code_repo: { label: "Repository", icon: () => /* @__PURE__ */
|
|
16100
|
-
code_deployment: { label: "Deployment", icon: () => /* @__PURE__ */
|
|
16130
|
+
code_rule: { label: "Code rule", icon: () => /* @__PURE__ */ jsx95(BracketCurlyCheckIcon, { size: 24 }) },
|
|
16131
|
+
code_repo: { label: "Repository", icon: () => /* @__PURE__ */ jsx95(CodingBranchIcon, { size: 24 }) },
|
|
16132
|
+
code_deployment: { label: "Deployment", icon: () => /* @__PURE__ */ jsx95(PackageIcon, { size: 24 }) },
|
|
16101
16133
|
// The graph's own objects: one source file's public surface, one public
|
|
16102
16134
|
// symbol, a near-duplicate cluster, and a pull request's blast radius.
|
|
16103
16135
|
// Glyph cards for the same reason as their three siblings — none carries a
|
|
16104
16136
|
// cover image, and each links to the admin screen that renders it in full.
|
|
16105
|
-
code_file: { label: "Code file", icon: () => /* @__PURE__ */
|
|
16106
|
-
code_symbol: { label: "Code symbol", icon: () => /* @__PURE__ */
|
|
16107
|
-
code_duplicate: { label: "Duplicate code", icon: () => /* @__PURE__ */
|
|
16108
|
-
code_impact: { label: "Change impact", icon: () => /* @__PURE__ */
|
|
16137
|
+
code_file: { label: "Code file", icon: () => /* @__PURE__ */ jsx95(FileCodeIcon, { size: 24 }) },
|
|
16138
|
+
code_symbol: { label: "Code symbol", icon: () => /* @__PURE__ */ jsx95(CodeSquareIcon, { size: 24 }) },
|
|
16139
|
+
code_duplicate: { label: "Duplicate code", icon: () => /* @__PURE__ */ jsx95(Copy01Icon, { size: 24 }) },
|
|
16140
|
+
code_impact: { label: "Change impact", icon: () => /* @__PURE__ */ jsx95(CodingPullRequestIcon, { size: 24 }) }
|
|
16109
16141
|
};
|
|
16110
16142
|
function refGlyphRegistryEntries() {
|
|
16111
16143
|
return registryEntries(
|
|
@@ -16113,7 +16145,7 @@ function refGlyphRegistryEntries() {
|
|
|
16113
16145
|
(cfg, docType) => refHydratedEntry(
|
|
16114
16146
|
docType,
|
|
16115
16147
|
cfg.label,
|
|
16116
|
-
(displayRef, opts) => cfg.media ? /* @__PURE__ */
|
|
16148
|
+
(displayRef, opts) => cfg.media ? /* @__PURE__ */ jsx95(
|
|
16117
16149
|
EntityMingoCard,
|
|
16118
16150
|
{
|
|
16119
16151
|
title: displayRef.title,
|
|
@@ -16129,7 +16161,7 @@ function refGlyphRegistryEntries() {
|
|
|
16129
16161
|
discuss: opts.discuss,
|
|
16130
16162
|
menuAriaLabel: `${cfg.label} actions`
|
|
16131
16163
|
}
|
|
16132
|
-
) : /* @__PURE__ */
|
|
16164
|
+
) : /* @__PURE__ */ jsx95(GlyphChatCard, { chatRef: displayRef, icon: cfg.icon(), isNewTab: opts.isNewTab, discuss: opts.discuss })
|
|
16133
16165
|
)
|
|
16134
16166
|
);
|
|
16135
16167
|
}
|
|
@@ -16142,17 +16174,17 @@ function fetchedEmployeeEntryDisplayRef(item, chatRef) {
|
|
|
16142
16174
|
return { ...chatRef, title, preview: preview.length > 0 ? preview : chatRef.preview };
|
|
16143
16175
|
}
|
|
16144
16176
|
var EMPLOYEE_ENTRY_CARD_CONFIGS = {
|
|
16145
|
-
what_i_shipped: { label: "What I Shipped", icon: () => /* @__PURE__ */
|
|
16146
|
-
how_i_work: { label: "How I Work", icon: () => /* @__PURE__ */
|
|
16147
|
-
ai_prompt: { label: "Squawkbox", icon: () => /* @__PURE__ */
|
|
16177
|
+
what_i_shipped: { label: "What I Shipped", icon: () => /* @__PURE__ */ jsx95(Rocket02Icon, { size: 24 }) },
|
|
16178
|
+
how_i_work: { label: "How I Work", icon: () => /* @__PURE__ */ jsx95(ClipboardListIcon, { size: 24 }) },
|
|
16179
|
+
ai_prompt: { label: "Squawkbox", icon: () => /* @__PURE__ */ jsx95(ChatQuoteIcon, { size: 24 }) }
|
|
16148
16180
|
};
|
|
16149
16181
|
function employeeEntryRegistryEntries() {
|
|
16150
16182
|
return registryEntries(EMPLOYEE_ENTRY_CARD_CONFIGS, (cfg, docType) => ({
|
|
16151
16183
|
label: cfg.label,
|
|
16152
16184
|
bareInline: true,
|
|
16153
16185
|
contentRefType: docType,
|
|
16154
|
-
skeleton: () => /* @__PURE__ */
|
|
16155
|
-
render: (item, chatRef, opts) => /* @__PURE__ */
|
|
16186
|
+
skeleton: () => /* @__PURE__ */ jsx95(MingoInfoCardSkeleton, {}),
|
|
16187
|
+
render: (item, chatRef, opts) => /* @__PURE__ */ jsx95(
|
|
16156
16188
|
GlyphChatCard,
|
|
16157
16189
|
{
|
|
16158
16190
|
chatRef: fetchedEmployeeEntryDisplayRef(item, chatRef),
|
|
@@ -16166,7 +16198,7 @@ function employeeEntryRegistryEntries() {
|
|
|
16166
16198
|
function githubRegistryEntries() {
|
|
16167
16199
|
return registryEntries(
|
|
16168
16200
|
GITHUB_CARD_CONFIGS,
|
|
16169
|
-
(cfg, docType) => refHydratedEntry(docType, cfg.label, (displayRef, opts) => /* @__PURE__ */
|
|
16201
|
+
(cfg, docType) => refHydratedEntry(docType, cfg.label, (displayRef, opts) => /* @__PURE__ */ jsx95(GitHubChatCard, { chatRef: displayRef, kind: cfg.kind, isNewTab: opts.isNewTab, discuss: opts.discuss }))
|
|
16170
16202
|
);
|
|
16171
16203
|
}
|
|
16172
16204
|
var PROGRAM_CARD_CONFIGS = {
|
|
@@ -16179,8 +16211,8 @@ function programRegistryEntries() {
|
|
|
16179
16211
|
label: cfg.label,
|
|
16180
16212
|
contentRefType: cfg.contentRefType,
|
|
16181
16213
|
bareInline: true,
|
|
16182
|
-
skeleton: () => /* @__PURE__ */
|
|
16183
|
-
render: (item, chatRef, opts) => /* @__PURE__ */
|
|
16214
|
+
skeleton: () => /* @__PURE__ */ jsx95(ProgramCardSkeleton, { size: "sm" }),
|
|
16215
|
+
render: (item, chatRef, opts) => /* @__PURE__ */ jsx95(
|
|
16184
16216
|
ProgramChatCard,
|
|
16185
16217
|
{
|
|
16186
16218
|
item,
|
|
@@ -16220,8 +16252,8 @@ function roadmapRegistryEntries() {
|
|
|
16220
16252
|
bareInline: true,
|
|
16221
16253
|
...cfg.noComposedHref ? { noComposedHref: true } : {},
|
|
16222
16254
|
...cfg.fallbackHref ? { fallbackHref: cfg.fallbackHref } : {},
|
|
16223
|
-
skeleton: () => /* @__PURE__ */
|
|
16224
|
-
render: (item, chatRef, opts) => /* @__PURE__ */
|
|
16255
|
+
skeleton: () => /* @__PURE__ */ jsx95(RoadmapCardSkeleton, { size: "sm" }),
|
|
16256
|
+
render: (item, chatRef, opts) => /* @__PURE__ */ jsx95(
|
|
16225
16257
|
RoadmapChatCard,
|
|
16226
16258
|
{
|
|
16227
16259
|
item,
|
|
@@ -16248,7 +16280,7 @@ var CHAT_CARD_REGISTRY = {
|
|
|
16248
16280
|
// null and the card renders its generic "Deleted item" tombstone. The
|
|
16249
16281
|
// descriptor's `title` defaults to the raw cardId — suppress it so the
|
|
16250
16282
|
// strikethrough line never shows an opaque id.
|
|
16251
|
-
render: (_item, chatRef) => /* @__PURE__ */
|
|
16283
|
+
render: (_item, chatRef) => /* @__PURE__ */ jsx95(
|
|
16252
16284
|
DeletedDataCard,
|
|
16253
16285
|
{
|
|
16254
16286
|
title: chatRef.title && chatRef.title !== chatRef.id ? chatRef.title : null,
|
|
@@ -16260,7 +16292,7 @@ var CHAT_CARD_REGISTRY = {
|
|
|
16260
16292
|
// ───────── ref-only types (no list endpoint; the ChatRef IS the card) ─────────
|
|
16261
16293
|
...refGlyphRegistryEntries(),
|
|
16262
16294
|
...employeeEntryRegistryEntries(),
|
|
16263
|
-
slack_message: refHydratedEntry("slack_message", "Slack message", (displayRef, opts) => /* @__PURE__ */
|
|
16295
|
+
slack_message: refHydratedEntry("slack_message", "Slack message", (displayRef, opts) => /* @__PURE__ */ jsx95(SlackChatCard, { chatRef: displayRef, isNewTab: opts.isNewTab, discuss: opts.discuss })),
|
|
16264
16296
|
// FAQ hydrates from its EXISTING public list API (`/api/faqs?ids=` —
|
|
16265
16297
|
// also feeding related-content rails, so its base path must not move).
|
|
16266
16298
|
// Rows are faq-shaped, not ChatRef-shaped, hence the bespoke row→display
|
|
@@ -16271,24 +16303,24 @@ var CHAT_CARD_REGISTRY = {
|
|
|
16271
16303
|
contentRefType: "faq",
|
|
16272
16304
|
noComposedHref: true,
|
|
16273
16305
|
fallbackHref: (item) => item?.id != null ? `/faqs#${faqItemAnchor(item.id)}` : null,
|
|
16274
|
-
skeleton: () => /* @__PURE__ */
|
|
16275
|
-
render: (item, chatRef, opts) => /* @__PURE__ */
|
|
16306
|
+
skeleton: () => /* @__PURE__ */ jsx95(MingoInfoCardSkeleton, {}),
|
|
16307
|
+
render: (item, chatRef, opts) => /* @__PURE__ */ jsx95(FaqChatCard, { chatRef: fetchedFaqDisplayRef(item, chatRef), isNewTab: opts.isNewTab, discuss: opts.discuss })
|
|
16276
16308
|
},
|
|
16277
|
-
hubspot_ticket: refHydratedEntry("hubspot_ticket", "HubSpot ticket", (displayRef, opts) => /* @__PURE__ */
|
|
16278
|
-
hubspot_ticket_anon: refHydratedEntry("hubspot_ticket_anon", "HubSpot ticket (anon)", (displayRef, opts) => /* @__PURE__ */
|
|
16309
|
+
hubspot_ticket: refHydratedEntry("hubspot_ticket", "HubSpot ticket", (displayRef, opts) => /* @__PURE__ */ jsx95(HubspotTicketChatCard, { chatRef: displayRef, isNewTab: opts.isNewTab, discuss: opts.discuss })),
|
|
16310
|
+
hubspot_ticket_anon: refHydratedEntry("hubspot_ticket_anon", "HubSpot ticket (anon)", (displayRef, opts) => /* @__PURE__ */ jsx95(HubspotTicketChatCard, { chatRef: displayRef, isNewTab: opts.isNewTab, discuss: opts.discuss })),
|
|
16279
16311
|
// Self tickets hydrate via the session-scoped `GET /api/tickets?ids=`
|
|
16280
16312
|
// (`selfScopeFilter` ACL) instead of the generic endpoint — the self
|
|
16281
16313
|
// config's searchFilter is deliberately fail-closed there. Same
|
|
16282
16314
|
// ChatRef item shape (`buildHubspotTicketSelfRef` SSOT), same preset.
|
|
16283
|
-
hubspot_ticket_self: refHydratedEntry("hubspot_ticket_self", "HubSpot ticket (self)", (displayRef, opts) => /* @__PURE__ */
|
|
16284
|
-
data_room_doc: refHydratedEntry("data_room_doc", "Data-room doc", (displayRef, opts) => /* @__PURE__ */
|
|
16285
|
-
markdown: refHydratedEntry("markdown", "Doc page (markdown)", (displayRef, opts) => /* @__PURE__ */
|
|
16315
|
+
hubspot_ticket_self: refHydratedEntry("hubspot_ticket_self", "HubSpot ticket (self)", (displayRef, opts) => /* @__PURE__ */ jsx95(HubspotTicketChatCard, { chatRef: displayRef, isNewTab: opts.isNewTab, discuss: opts.discuss })),
|
|
16316
|
+
data_room_doc: refHydratedEntry("data_room_doc", "Data-room doc", (displayRef, opts) => /* @__PURE__ */ jsx95(DataRoomDocChatCard, { chatRef: displayRef, isNewTab: opts.isNewTab, discuss: opts.discuss })),
|
|
16317
|
+
markdown: refHydratedEntry("markdown", "Doc page (markdown)", (displayRef, opts) => /* @__PURE__ */ jsx95(DataRoomDocChatCard, { chatRef: displayRef, isNewTab: opts.isNewTab, discuss: opts.discuss })),
|
|
16286
16318
|
// Body-synthesized video ids (`shortVideoId` content hashes / YouTube
|
|
16287
16319
|
// ids) have no backing table row to fetch — ref-only by nature.
|
|
16288
16320
|
video: {
|
|
16289
16321
|
label: "Video",
|
|
16290
16322
|
bareInline: true,
|
|
16291
|
-
render: (_item, chatRef) => /* @__PURE__ */
|
|
16323
|
+
render: (_item, chatRef) => /* @__PURE__ */ jsx95(ChatInlineVideoPill, { chatRef })
|
|
16292
16324
|
},
|
|
16293
16325
|
...financialRegistryEntries(),
|
|
16294
16326
|
// ───────── content types: full rows from their public list APIs ─────────
|
|
@@ -16296,8 +16328,8 @@ var CHAT_CARD_REGISTRY = {
|
|
|
16296
16328
|
label: "Blog post",
|
|
16297
16329
|
contentRefType: "blog_post_existing",
|
|
16298
16330
|
bareInline: true,
|
|
16299
|
-
skeleton: () => /* @__PURE__ */
|
|
16300
|
-
render: (item, chatRef, opts) => /* @__PURE__ */
|
|
16331
|
+
skeleton: () => /* @__PURE__ */ jsx95(BlogCardSkeleton, { size: "sm" }),
|
|
16332
|
+
render: (item, chatRef, opts) => /* @__PURE__ */ jsx95(
|
|
16301
16333
|
BlogChatCard,
|
|
16302
16334
|
{
|
|
16303
16335
|
item,
|
|
@@ -16313,8 +16345,8 @@ var CHAT_CARD_REGISTRY = {
|
|
|
16313
16345
|
label: "Case study",
|
|
16314
16346
|
contentRefType: "case_study",
|
|
16315
16347
|
bareInline: true,
|
|
16316
|
-
skeleton: () => /* @__PURE__ */
|
|
16317
|
-
render: (item, chatRef, opts) => /* @__PURE__ */
|
|
16348
|
+
skeleton: () => /* @__PURE__ */ jsx95(CaseStudyCardSkeleton, { size: "sm" }),
|
|
16349
|
+
render: (item, chatRef, opts) => /* @__PURE__ */ jsx95(
|
|
16318
16350
|
CaseStudyChatCard,
|
|
16319
16351
|
{
|
|
16320
16352
|
item,
|
|
@@ -16329,8 +16361,8 @@ var CHAT_CARD_REGISTRY = {
|
|
|
16329
16361
|
label: "Customer interview",
|
|
16330
16362
|
contentRefType: "customer_interview",
|
|
16331
16363
|
bareInline: true,
|
|
16332
|
-
skeleton: () => /* @__PURE__ */
|
|
16333
|
-
render: (item, chatRef, opts) => /* @__PURE__ */
|
|
16364
|
+
skeleton: () => /* @__PURE__ */ jsx95(CustomerInterviewCardSkeleton, { size: "sm" }),
|
|
16365
|
+
render: (item, chatRef, opts) => /* @__PURE__ */ jsx95(
|
|
16334
16366
|
CustomerInterviewChatCard,
|
|
16335
16367
|
{
|
|
16336
16368
|
item,
|
|
@@ -16345,10 +16377,10 @@ var CHAT_CARD_REGISTRY = {
|
|
|
16345
16377
|
label: "Product release",
|
|
16346
16378
|
contentRefType: "product_release",
|
|
16347
16379
|
bareInline: true,
|
|
16348
|
-
skeleton: () => /* @__PURE__ */
|
|
16380
|
+
skeleton: () => /* @__PURE__ */ jsx95(ProductReleaseCardSkeleton, { size: "sm" }),
|
|
16349
16381
|
render: (item, chatRef, opts) => {
|
|
16350
16382
|
const builder = opts?.extras?.buildProductReleaseCardProps ?? defaultBuildProductReleaseCardProps;
|
|
16351
|
-
return /* @__PURE__ */
|
|
16383
|
+
return /* @__PURE__ */ jsx95(
|
|
16352
16384
|
ProductReleaseChatCard,
|
|
16353
16385
|
{
|
|
16354
16386
|
item,
|
|
@@ -16365,8 +16397,8 @@ var CHAT_CARD_REGISTRY = {
|
|
|
16365
16397
|
label: "Investor update",
|
|
16366
16398
|
contentRefType: "investor_update",
|
|
16367
16399
|
bareInline: true,
|
|
16368
|
-
skeleton: () => /* @__PURE__ */
|
|
16369
|
-
render: (item, chatRef, opts) => /* @__PURE__ */
|
|
16400
|
+
skeleton: () => /* @__PURE__ */ jsx95(InvestorUpdateCardSkeleton, { size: "sm" }),
|
|
16401
|
+
render: (item, chatRef, opts) => /* @__PURE__ */ jsx95(
|
|
16370
16402
|
InvestorUpdateChatCard,
|
|
16371
16403
|
{
|
|
16372
16404
|
item,
|
|
@@ -16383,8 +16415,8 @@ var CHAT_CARD_REGISTRY = {
|
|
|
16383
16415
|
bareInline: true,
|
|
16384
16416
|
// "Display" affordance (verbatim guide body) instead of "Ask".
|
|
16385
16417
|
displayAction: true,
|
|
16386
|
-
skeleton: () => /* @__PURE__ */
|
|
16387
|
-
render: (item, chatRef, opts) => /* @__PURE__ */
|
|
16418
|
+
skeleton: () => /* @__PURE__ */ jsx95(OnboardingGuideCardSkeleton, { size: "sm" }),
|
|
16419
|
+
render: (item, chatRef, opts) => /* @__PURE__ */ jsx95(
|
|
16388
16420
|
OnboardingGuideChatCard,
|
|
16389
16421
|
{
|
|
16390
16422
|
item,
|
|
@@ -16399,11 +16431,11 @@ var CHAT_CARD_REGISTRY = {
|
|
|
16399
16431
|
label: "Marketing campaign",
|
|
16400
16432
|
contentRefType: "marketing_campaign",
|
|
16401
16433
|
bareInline: true,
|
|
16402
|
-
skeleton: () => /* @__PURE__ */
|
|
16434
|
+
skeleton: () => /* @__PURE__ */ jsx95(CampaignCardAdminSkeleton, {}),
|
|
16403
16435
|
// No public viewer — synthesize the hub-internal admin URL post-fetch
|
|
16404
16436
|
// so the wrapper + isNewTab computation see the actual destination.
|
|
16405
16437
|
fallbackHref: (item) => item?.id ? `/admin/campaigns/${encodeURIComponent(String(item.id))}` : null,
|
|
16406
|
-
render: (item, chatRef, opts) => /* @__PURE__ */
|
|
16438
|
+
render: (item, chatRef, opts) => /* @__PURE__ */ jsx95(CampaignChatCard, { item, chatRef, isNewTab: opts.isNewTab, discuss: opts.discuss })
|
|
16407
16439
|
},
|
|
16408
16440
|
...roadmapRegistryEntries()
|
|
16409
16441
|
};
|
|
@@ -16432,7 +16464,7 @@ function ChatCardNavWrap({
|
|
|
16432
16464
|
e.stopPropagation();
|
|
16433
16465
|
if (!isNewTab && panel?.closeChat) panel.closeChat();
|
|
16434
16466
|
};
|
|
16435
|
-
return /* @__PURE__ */
|
|
16467
|
+
return /* @__PURE__ */ jsx95("span", { className: "contents", onClickCapture, children });
|
|
16436
16468
|
}
|
|
16437
16469
|
function ChatCardLoader({
|
|
16438
16470
|
chatRef,
|
|
@@ -16494,7 +16526,7 @@ function ChatCardLoader({
|
|
|
16494
16526
|
const discussFn = useDisplay ? onDisplay : onDiscuss;
|
|
16495
16527
|
const discuss = discussFn ? {
|
|
16496
16528
|
label: useDisplay ? "Display" : "Ask Mingo",
|
|
16497
|
-
icon: useDisplay ? /* @__PURE__ */
|
|
16529
|
+
icon: useDisplay ? /* @__PURE__ */ jsx95(FileContentIcon, { size: 20 }) : /* @__PURE__ */ jsx95(
|
|
16498
16530
|
MingoIcon,
|
|
16499
16531
|
{
|
|
16500
16532
|
className: "size-5",
|
|
@@ -16513,7 +16545,7 @@ function ChatCardLoader({
|
|
|
16513
16545
|
discuss
|
|
16514
16546
|
};
|
|
16515
16547
|
const path = typeof finalChatRef.metadata?.path === "string" ? finalChatRef.metadata.path : null;
|
|
16516
|
-
const navWrap = (children) => /* @__PURE__ */
|
|
16548
|
+
const navWrap = (children) => /* @__PURE__ */ jsx95(
|
|
16517
16549
|
ChatCardNavWrap,
|
|
16518
16550
|
{
|
|
16519
16551
|
href: finalChatRef.url ?? null,
|
|
@@ -16523,7 +16555,7 @@ function ChatCardLoader({
|
|
|
16523
16555
|
children
|
|
16524
16556
|
}
|
|
16525
16557
|
);
|
|
16526
|
-
const finish = (node) => entry.bareInline ? /* @__PURE__ */
|
|
16558
|
+
const finish = (node) => entry.bareInline ? /* @__PURE__ */ jsx95(Fragment32, { children: navWrap(node) }) : /* @__PURE__ */ jsx95(
|
|
16527
16559
|
ChatCardWithDiscuss,
|
|
16528
16560
|
{
|
|
16529
16561
|
chatRef: finalChatRef,
|
|
@@ -16536,15 +16568,15 @@ function ChatCardLoader({
|
|
|
16536
16568
|
if (!fetchEntry) {
|
|
16537
16569
|
return finish(entry.render(void 0, finalChatRef, renderOpts));
|
|
16538
16570
|
}
|
|
16539
|
-
if (isLoading) return /* @__PURE__ */
|
|
16571
|
+
if (isLoading) return /* @__PURE__ */ jsx95(Fragment32, { children: fetchEntry.skeleton?.() ?? null });
|
|
16540
16572
|
if (!item) {
|
|
16541
16573
|
if (isError) {
|
|
16542
|
-
return /* @__PURE__ */
|
|
16574
|
+
return /* @__PURE__ */ jsx95(CardLoadFailure, { label: entry.label, id: finalChatRef.id, detail: "Failed to load" });
|
|
16543
16575
|
}
|
|
16544
16576
|
if (!isFetched) {
|
|
16545
|
-
return /* @__PURE__ */
|
|
16577
|
+
return /* @__PURE__ */ jsx95(CardLoadFailure, { label: entry.label, id: finalChatRef.id, detail: "Not loadable" });
|
|
16546
16578
|
}
|
|
16547
|
-
return /* @__PURE__ */
|
|
16579
|
+
return /* @__PURE__ */ jsx95(CardLoadFailure, { label: entry.label, id: finalChatRef.id, detail: "Not found" });
|
|
16548
16580
|
}
|
|
16549
16581
|
const videoMeta = itemVideoMetadata(item);
|
|
16550
16582
|
if (videoMeta) {
|
|
@@ -16558,7 +16590,7 @@ function ChatCardLoader({
|
|
|
16558
16590
|
// the spacing between any two hoisted blocks.
|
|
16559
16591
|
/* @__PURE__ */ jsxs73("div", { className: "flex min-w-0 flex-col gap-3", children: [
|
|
16560
16592
|
finish(entry.render(item, finalChatRef, renderOpts)),
|
|
16561
|
-
/* @__PURE__ */
|
|
16593
|
+
/* @__PURE__ */ jsx95(ChatVideoEntityCard, { chatRef: videoRef })
|
|
16562
16594
|
] })
|
|
16563
16595
|
);
|
|
16564
16596
|
}
|
|
@@ -16566,7 +16598,7 @@ function ChatCardLoader({
|
|
|
16566
16598
|
}
|
|
16567
16599
|
function renderChatInlineEntityCard(chatRef, options = {}) {
|
|
16568
16600
|
const { onDiscuss, onDisplay, baseRoute, chipBasePlatform, extras } = options;
|
|
16569
|
-
const loader = /* @__PURE__ */
|
|
16601
|
+
const loader = /* @__PURE__ */ jsx95(
|
|
16570
16602
|
ChatCardLoader,
|
|
16571
16603
|
{
|
|
16572
16604
|
chatRef,
|
|
@@ -16586,7 +16618,7 @@ function renderChatInlineEntityCard(chatRef, options = {}) {
|
|
|
16586
16618
|
url: chatRef.url ?? decoded.videoUrl ?? (decoded.youtubeUrl ? `https://www.youtube.com/watch?v=${decoded.youtubeUrl}` : null),
|
|
16587
16619
|
metadata: { ...chatRef.metadata ?? {}, ...decoded }
|
|
16588
16620
|
};
|
|
16589
|
-
return /* @__PURE__ */
|
|
16621
|
+
return /* @__PURE__ */ jsx95(BlockCard, { inline: /* @__PURE__ */ jsx95(ChatInlineVideoPill, { chatRef: displayRef }), children: /* @__PURE__ */ jsx95(ChatVideoEntityCard, { chatRef: displayRef }) });
|
|
16590
16622
|
}
|
|
16591
16623
|
return loader;
|
|
16592
16624
|
}
|
|
@@ -17946,7 +17978,7 @@ function useChatAttachments() {
|
|
|
17946
17978
|
|
|
17947
17979
|
// src/components/chat/hooks/use-chat-attachment-image-gallery.tsx
|
|
17948
17980
|
import { useCallback as useCallback17, useEffect as useEffect28, useRef as useRef24, useState as useState34 } from "react";
|
|
17949
|
-
import { jsx as
|
|
17981
|
+
import { jsx as jsx96 } from "react/jsx-runtime";
|
|
17950
17982
|
var CLOSED = { isOpen: false, images: [], initialIndex: 0 };
|
|
17951
17983
|
function useChatAttachmentImageGallery() {
|
|
17952
17984
|
const runtime = useRequiredChatRuntime();
|
|
@@ -17982,7 +18014,7 @@ function useChatAttachmentImageGallery() {
|
|
|
17982
18014
|
root.addEventListener("click", onClick);
|
|
17983
18015
|
return () => root.removeEventListener("click", onClick);
|
|
17984
18016
|
}, [viewUrlPrefix]);
|
|
17985
|
-
const modal = state.isOpen ? /* @__PURE__ */
|
|
18017
|
+
const modal = state.isOpen ? /* @__PURE__ */ jsx96(
|
|
17986
18018
|
ImageGalleryModal,
|
|
17987
18019
|
{
|
|
17988
18020
|
images: state.images,
|
|
@@ -23991,13 +24023,13 @@ import {
|
|
|
23991
24023
|
useRef as useRef33,
|
|
23992
24024
|
useState as useState45
|
|
23993
24025
|
} from "react";
|
|
23994
|
-
import { jsx as
|
|
24026
|
+
import { jsx as jsx97, jsxs as jsxs74 } from "react/jsx-runtime";
|
|
23995
24027
|
var OVERLAY_BACKDROP_CLASS = "bg-ods-overlay";
|
|
23996
24028
|
var Drawer = DialogPrimitive.Root;
|
|
23997
24029
|
var DrawerTrigger = DialogPrimitive.Trigger;
|
|
23998
24030
|
var DrawerClose = DialogPrimitive.Close;
|
|
23999
24031
|
var DrawerPortal = DialogPrimitive.Portal;
|
|
24000
|
-
var DrawerOverlay = forwardRef26(({ className, ...props }, ref) => /* @__PURE__ */
|
|
24032
|
+
var DrawerOverlay = forwardRef26(({ className, ...props }, ref) => /* @__PURE__ */ jsx97(
|
|
24001
24033
|
DialogPrimitive.Overlay,
|
|
24002
24034
|
{
|
|
24003
24035
|
ref,
|
|
@@ -24192,7 +24224,7 @@ function DrawerResizeHandle({ side, size: size2, minSize, maxSize, onSize, ariaL
|
|
|
24192
24224
|
const trackPosition = side === "right" ? "right-full top-4 bottom-4 w-3 items-center justify-end pr-1" : side === "left" ? "left-full top-4 bottom-4 w-3 items-center justify-start pl-1" : side === "bottom" ? "bottom-full left-4 right-4 h-3 justify-center items-end pb-1" : "top-full left-4 right-4 h-3 justify-center items-start pt-1";
|
|
24193
24225
|
const cursorClass = isHorizontal ? "cursor-col-resize" : "cursor-row-resize";
|
|
24194
24226
|
const gripClass = isHorizontal ? "h-10 w-1" : "w-10 h-1";
|
|
24195
|
-
return /* @__PURE__ */
|
|
24227
|
+
return /* @__PURE__ */ jsx97(
|
|
24196
24228
|
"div",
|
|
24197
24229
|
{
|
|
24198
24230
|
role: "separator",
|
|
@@ -24213,7 +24245,7 @@ function DrawerResizeHandle({ side, size: size2, minSize, maxSize, onSize, ariaL
|
|
|
24213
24245
|
trackPosition,
|
|
24214
24246
|
cursorClass
|
|
24215
24247
|
),
|
|
24216
|
-
children: /* @__PURE__ */
|
|
24248
|
+
children: /* @__PURE__ */ jsx97("div", { "aria-hidden": true, className: cn("rounded-full bg-ods-bg-surface", gripClass) })
|
|
24217
24249
|
}
|
|
24218
24250
|
);
|
|
24219
24251
|
}
|
|
@@ -24262,7 +24294,7 @@ var DrawerContent = forwardRef26(
|
|
|
24262
24294
|
const applyInlineSize = resizable && !isMobile;
|
|
24263
24295
|
const sizeStyle = applyInlineSize ? isHorizontal ? { width: resizedSize } : { height: resizedSize } : {};
|
|
24264
24296
|
return /* @__PURE__ */ jsxs74(DrawerPortal, { children: [
|
|
24265
|
-
/* @__PURE__ */
|
|
24297
|
+
/* @__PURE__ */ jsx97(DrawerOverlay, { className: overlayClassName }),
|
|
24266
24298
|
/* @__PURE__ */ jsxs74(
|
|
24267
24299
|
DialogPrimitive.Content,
|
|
24268
24300
|
{
|
|
@@ -24271,7 +24303,7 @@ var DrawerContent = forwardRef26(
|
|
|
24271
24303
|
style: { ...offsetHeader ? { top: headerHeight } : {}, ...style },
|
|
24272
24304
|
...props,
|
|
24273
24305
|
children: [
|
|
24274
|
-
applyInlineSize ? /* @__PURE__ */
|
|
24306
|
+
applyInlineSize ? /* @__PURE__ */ jsx97(
|
|
24275
24307
|
DrawerResizeHandle,
|
|
24276
24308
|
{
|
|
24277
24309
|
side: resolvedSide,
|
|
@@ -24282,7 +24314,7 @@ var DrawerContent = forwardRef26(
|
|
|
24282
24314
|
ariaLabel: resizeAriaLabel
|
|
24283
24315
|
}
|
|
24284
24316
|
) : null,
|
|
24285
|
-
/* @__PURE__ */
|
|
24317
|
+
/* @__PURE__ */ jsx97(
|
|
24286
24318
|
"div",
|
|
24287
24319
|
{
|
|
24288
24320
|
className: cn(drawerPanelVariants({ side, flush, size: size2 }), className, panelClassName),
|
|
@@ -24297,11 +24329,11 @@ var DrawerContent = forwardRef26(
|
|
|
24297
24329
|
}
|
|
24298
24330
|
);
|
|
24299
24331
|
DrawerContent.displayName = "DrawerContent";
|
|
24300
|
-
var DrawerHeader = ({ className, children, ...props }) => /* @__PURE__ */
|
|
24332
|
+
var DrawerHeader = ({ className, children, ...props }) => /* @__PURE__ */ jsx97("div", { className: cn("flex flex-col gap-4", className), ...props, children });
|
|
24301
24333
|
DrawerHeader.displayName = "DrawerHeader";
|
|
24302
24334
|
var DrawerTitle = forwardRef26(
|
|
24303
24335
|
({ className, children, actions, hideClose, ...props }, ref) => /* @__PURE__ */ jsxs74("div", { className: "flex items-start gap-4", children: [
|
|
24304
|
-
/* @__PURE__ */
|
|
24336
|
+
/* @__PURE__ */ jsx97(
|
|
24305
24337
|
DialogPrimitive.Title,
|
|
24306
24338
|
{
|
|
24307
24339
|
ref,
|
|
@@ -24312,13 +24344,13 @@ var DrawerTitle = forwardRef26(
|
|
|
24312
24344
|
),
|
|
24313
24345
|
actions,
|
|
24314
24346
|
!hideClose && /* @__PURE__ */ jsxs74(DialogPrimitive.Close, { className: "shrink-0 rounded-sm text-ods-text-secondary outline-none ring-0 transition-colors hover:text-ods-text-primary focus:outline-none focus:ring-0 focus-visible:outline-none focus-visible:ring-0", children: [
|
|
24315
|
-
/* @__PURE__ */
|
|
24316
|
-
/* @__PURE__ */
|
|
24347
|
+
/* @__PURE__ */ jsx97(X, { className: "size-6" }),
|
|
24348
|
+
/* @__PURE__ */ jsx97("span", { className: "sr-only", children: "Close" })
|
|
24317
24349
|
] })
|
|
24318
24350
|
] })
|
|
24319
24351
|
);
|
|
24320
24352
|
DrawerTitle.displayName = "DrawerTitle";
|
|
24321
|
-
var DrawerDescription = forwardRef26(({ className, ...props }, ref) => /* @__PURE__ */
|
|
24353
|
+
var DrawerDescription = forwardRef26(({ className, ...props }, ref) => /* @__PURE__ */ jsx97(
|
|
24322
24354
|
DialogPrimitive.Description,
|
|
24323
24355
|
{
|
|
24324
24356
|
ref,
|
|
@@ -24327,16 +24359,16 @@ var DrawerDescription = forwardRef26(({ className, ...props }, ref) => /* @__PUR
|
|
|
24327
24359
|
}
|
|
24328
24360
|
));
|
|
24329
24361
|
DrawerDescription.displayName = "DrawerDescription";
|
|
24330
|
-
var DrawerBody = ({ className, ...props }) => /* @__PURE__ */
|
|
24362
|
+
var DrawerBody = ({ className, ...props }) => /* @__PURE__ */ jsx97("div", { className: cn("flex flex-1 flex-col gap-4 overflow-y-auto", className), ...props });
|
|
24331
24363
|
DrawerBody.displayName = "DrawerBody";
|
|
24332
|
-
var DrawerFooter = ({ className, ...props }) => /* @__PURE__ */
|
|
24364
|
+
var DrawerFooter = ({ className, ...props }) => /* @__PURE__ */ jsx97("div", { className: cn("mt-auto flex flex-col gap-2", className), ...props });
|
|
24333
24365
|
DrawerFooter.displayName = "DrawerFooter";
|
|
24334
24366
|
|
|
24335
24367
|
// src/components/ui/hover-dropdown.tsx
|
|
24336
24368
|
import { useState as useState46, useRef as useRef34, useCallback as useCallback26 } from "react";
|
|
24337
|
-
import { Fragment as Fragment33, jsx as
|
|
24369
|
+
import { Fragment as Fragment33, jsx as jsx98, jsxs as jsxs75 } from "react/jsx-runtime";
|
|
24338
24370
|
function DefaultAnchor({ href, className, children }) {
|
|
24339
|
-
return /* @__PURE__ */
|
|
24371
|
+
return /* @__PURE__ */ jsx98("a", { href, className, children });
|
|
24340
24372
|
}
|
|
24341
24373
|
function HoverDropdown({
|
|
24342
24374
|
children,
|
|
@@ -24389,24 +24421,24 @@ function HoverDropdown({
|
|
|
24389
24421
|
clearTimeout(timeoutRef.current);
|
|
24390
24422
|
setOpen((prev) => !prev);
|
|
24391
24423
|
}, []);
|
|
24392
|
-
if (items.length === 0) return /* @__PURE__ */
|
|
24424
|
+
if (items.length === 0) return /* @__PURE__ */ jsx98(Fragment33, { children });
|
|
24393
24425
|
const renderAnchorFn = renderAnchor ?? DefaultAnchor;
|
|
24394
24426
|
return /* @__PURE__ */ jsxs75("div", { ref: containerRef, className: "relative inline-flex", onMouseEnter: show, onMouseLeave: hide, onClick: toggle, children: [
|
|
24395
24427
|
children,
|
|
24396
|
-
open && /* @__PURE__ */
|
|
24428
|
+
open && /* @__PURE__ */ jsx98(
|
|
24397
24429
|
"div",
|
|
24398
24430
|
{
|
|
24399
24431
|
className: `fixed z-[9999] max-h-[420px] min-w-[220px] max-w-[340px] overflow-y-auto rounded-lg border border-ods-border bg-ods-card p-1 shadow-xl ${className || ""}`,
|
|
24400
24432
|
ref: panelRef,
|
|
24401
24433
|
children: items.map((item, i) => {
|
|
24402
24434
|
const content = /* @__PURE__ */ jsxs75(Fragment33, { children: [
|
|
24403
|
-
item.icon && /* @__PURE__ */
|
|
24404
|
-
/* @__PURE__ */
|
|
24435
|
+
item.icon && /* @__PURE__ */ jsx98("span", { className: "flex-shrink-0 [&_svg]:size-3.5", children: item.icon }),
|
|
24436
|
+
/* @__PURE__ */ jsx98("span", { className: "min-w-0 flex-1 truncate", children: item.label })
|
|
24405
24437
|
] });
|
|
24406
24438
|
const rowClass = "group flex w-full items-center gap-1.5 pl-2 pr-1 py-1.5 rounded text-h6 text-ods-text-secondary hover:bg-ods-accent/10 transition-colors text-left";
|
|
24407
24439
|
const primaryClass = "flex flex-1 items-center gap-1.5 min-w-0 hover:text-ods-accent cursor-pointer no-underline";
|
|
24408
24440
|
const secondaryAction = item.secondaryAction;
|
|
24409
|
-
const secondary = secondaryAction ? /* @__PURE__ */
|
|
24441
|
+
const secondary = secondaryAction ? /* @__PURE__ */ jsx98(
|
|
24410
24442
|
"button",
|
|
24411
24443
|
{
|
|
24412
24444
|
onClick: (e) => {
|
|
@@ -24435,12 +24467,12 @@ function HoverDropdown({
|
|
|
24435
24467
|
}
|
|
24436
24468
|
if (!item.onClick) {
|
|
24437
24469
|
return /* @__PURE__ */ jsxs75("div", { className: rowClass, children: [
|
|
24438
|
-
/* @__PURE__ */
|
|
24470
|
+
/* @__PURE__ */ jsx98("span", { className: `${primaryClass} cursor-default hover:!text-ods-text-secondary`, children: content }),
|
|
24439
24471
|
secondary
|
|
24440
24472
|
] }, i);
|
|
24441
24473
|
}
|
|
24442
24474
|
return /* @__PURE__ */ jsxs75("div", { className: rowClass, children: [
|
|
24443
|
-
/* @__PURE__ */
|
|
24475
|
+
/* @__PURE__ */ jsx98("button", { onClick: item.onClick, className: primaryClass, children: content }),
|
|
24444
24476
|
secondary
|
|
24445
24477
|
] }, i);
|
|
24446
24478
|
})
|
|
@@ -24683,7 +24715,7 @@ function pruneTimestampCache(timestampCache, liveIds) {
|
|
|
24683
24715
|
}
|
|
24684
24716
|
|
|
24685
24717
|
// src/components/chat/embeddable-chat.tsx
|
|
24686
|
-
import { Fragment as Fragment34, jsx as
|
|
24718
|
+
import { Fragment as Fragment34, jsx as jsx99, jsxs as jsxs76 } from "react/jsx-runtime";
|
|
24687
24719
|
var HISTORY_RAIL_WIDTH = 320;
|
|
24688
24720
|
var CHAT_BLOCK_MIN_WIDTH = 400;
|
|
24689
24721
|
var SPLIT_MIN_WIDTH = HISTORY_RAIL_WIDTH + CHAT_BLOCK_MIN_WIDTH;
|
|
@@ -24734,7 +24766,7 @@ function RailSlot({
|
|
|
24734
24766
|
innerClassName,
|
|
24735
24767
|
children
|
|
24736
24768
|
}) {
|
|
24737
|
-
return /* @__PURE__ */
|
|
24769
|
+
return /* @__PURE__ */ jsx99(
|
|
24738
24770
|
"div",
|
|
24739
24771
|
{
|
|
24740
24772
|
className: cn(
|
|
@@ -24743,7 +24775,7 @@ function RailSlot({
|
|
|
24743
24775
|
"shrink-0 overflow-hidden border-r border-ods-border transition-[width,opacity] ease-out",
|
|
24744
24776
|
active ? "duration-[240ms] w-80 opacity-100" : "duration-[300ms] w-0 opacity-0"
|
|
24745
24777
|
),
|
|
24746
|
-
children: /* @__PURE__ */
|
|
24778
|
+
children: /* @__PURE__ */ jsx99("div", { className: cn("h-full w-80", innerClassName), children })
|
|
24747
24779
|
}
|
|
24748
24780
|
);
|
|
24749
24781
|
}
|
|
@@ -24800,7 +24832,7 @@ function SourceChip({
|
|
|
24800
24832
|
sourceRowCtxFromRuntime(runtime, { baseRoute, chipBasePlatform })
|
|
24801
24833
|
);
|
|
24802
24834
|
const Icon = cta.icon;
|
|
24803
|
-
const icon = /* @__PURE__ */
|
|
24835
|
+
const icon = /* @__PURE__ */ jsx99(Icon, { className: "h-3.5 w-3.5" });
|
|
24804
24836
|
const chipClass = chatChipClass({ tone: "secondary" });
|
|
24805
24837
|
const decideTab = (href, targetPlatform) => computeIsNewTab(runtime, href, targetPlatform);
|
|
24806
24838
|
if (src.items && src.items.length > 0) {
|
|
@@ -24823,12 +24855,12 @@ function SourceChip({
|
|
|
24823
24855
|
// A client-built group keeps each row's own citation number, so the
|
|
24824
24856
|
// `[3]` in the answer is findable inside the dropdown.
|
|
24825
24857
|
label: item.index === void 0 ? item.name : `[${item.index}] ${item.name}`,
|
|
24826
|
-
icon: /* @__PURE__ */
|
|
24858
|
+
icon: /* @__PURE__ */ jsx99(ItemIcon, { className: "h-3.5 w-3.5" }),
|
|
24827
24859
|
href: itemCta.href ?? void 0,
|
|
24828
24860
|
targetPlatform: itemCta.targetPlatform,
|
|
24829
24861
|
path: item.path ?? null,
|
|
24830
24862
|
secondaryAction: onDiscuss && itemCta.askable && itemChatRef ? {
|
|
24831
|
-
icon: /* @__PURE__ */
|
|
24863
|
+
icon: /* @__PURE__ */ jsx99(MessageSquare3, {}),
|
|
24832
24864
|
label: `Ask about ${item.name}`,
|
|
24833
24865
|
onClick: () => onDiscuss(itemChatRef)
|
|
24834
24866
|
} : void 0
|
|
@@ -24836,11 +24868,11 @@ function SourceChip({
|
|
|
24836
24868
|
});
|
|
24837
24869
|
const itemIndices = src.items.flatMap((item) => item.index === void 0 ? [] : [item.index]);
|
|
24838
24870
|
const groupIndices = itemIndices.length > 0 ? formatCitationIndices(itemIndices) : `${src.index}`;
|
|
24839
|
-
return /* @__PURE__ */
|
|
24871
|
+
return /* @__PURE__ */ jsx99(
|
|
24840
24872
|
HoverDropdown,
|
|
24841
24873
|
{
|
|
24842
24874
|
items: dropdownItems,
|
|
24843
|
-
renderAnchor: ({ href, targetPlatform, path, className, children }) => /* @__PURE__ */
|
|
24875
|
+
renderAnchor: ({ href, targetPlatform, path, className, children }) => /* @__PURE__ */ jsx99(
|
|
24844
24876
|
NavLinkAnchorViaRuntime,
|
|
24845
24877
|
{
|
|
24846
24878
|
href,
|
|
@@ -24874,7 +24906,7 @@ function SourceChip({
|
|
|
24874
24906
|
] });
|
|
24875
24907
|
const wrapChip = (clickable) => /* @__PURE__ */ jsxs76("span", { className: "inline-flex items-center", children: [
|
|
24876
24908
|
clickable,
|
|
24877
|
-
/* @__PURE__ */
|
|
24909
|
+
/* @__PURE__ */ jsx99(SourceActionButton, { chatRef: cta.chatRef, onDiscuss, density: "inline", className: "-mr-1 ml-1" })
|
|
24878
24910
|
] });
|
|
24879
24911
|
const buildClickHandler = (href, path, targetPlatform, isNewTab) => (e) => {
|
|
24880
24912
|
const handled = executeNavigation({
|
|
@@ -24891,7 +24923,7 @@ function SourceChip({
|
|
|
24891
24923
|
const resolvedHref = resolveHrefForRuntime(cta.href, runtime);
|
|
24892
24924
|
const isNewTab = decideTab(resolvedHref, cta.targetPlatform ?? null);
|
|
24893
24925
|
return wrapChip(
|
|
24894
|
-
/* @__PURE__ */
|
|
24926
|
+
/* @__PURE__ */ jsx99(
|
|
24895
24927
|
"a",
|
|
24896
24928
|
{
|
|
24897
24929
|
href: resolvedHref,
|
|
@@ -24907,7 +24939,7 @@ function SourceChip({
|
|
|
24907
24939
|
const resolvedHref = resolveHrefForRuntime(cta.href, runtime);
|
|
24908
24940
|
const isNewTab = decideTab(resolvedHref, cta.targetPlatform ?? null);
|
|
24909
24941
|
return wrapChip(
|
|
24910
|
-
/* @__PURE__ */
|
|
24942
|
+
/* @__PURE__ */ jsx99(
|
|
24911
24943
|
"a",
|
|
24912
24944
|
{
|
|
24913
24945
|
href: resolvedHref,
|
|
@@ -24921,7 +24953,7 @@ function SourceChip({
|
|
|
24921
24953
|
);
|
|
24922
24954
|
}
|
|
24923
24955
|
return wrapChip(
|
|
24924
|
-
/* @__PURE__ */
|
|
24956
|
+
/* @__PURE__ */ jsx99("span", { className: `${chipClass} cursor-default`, title: displayName, children: chipBody(displayName) })
|
|
24925
24957
|
);
|
|
24926
24958
|
}
|
|
24927
24959
|
function SourceChips({
|
|
@@ -24937,8 +24969,8 @@ function SourceChips({
|
|
|
24937
24969
|
const fallback = uncited.slice(0, FALLBACK_TOP_RETRIEVED);
|
|
24938
24970
|
if (fallback.length === 0) return null;
|
|
24939
24971
|
return /* @__PURE__ */ jsxs76("div", { className: "mt-2 flex flex-col gap-1.5 border-t border-ods-border pt-2", children: [
|
|
24940
|
-
/* @__PURE__ */
|
|
24941
|
-
/* @__PURE__ */
|
|
24972
|
+
/* @__PURE__ */ jsx99("span", { className: "uppercase text-ods-text-muted text-h6", children: "Top retrieved sources" }),
|
|
24973
|
+
/* @__PURE__ */ jsx99("div", { className: "flex flex-wrap gap-1.5", children: fallback.map((src) => /* @__PURE__ */ jsx99(
|
|
24942
24974
|
SourceChip,
|
|
24943
24975
|
{
|
|
24944
24976
|
src,
|
|
@@ -24954,9 +24986,9 @@ function SourceChips({
|
|
|
24954
24986
|
const hiddenCount = uncited.length;
|
|
24955
24987
|
const hasOverflow = hiddenCount > 0;
|
|
24956
24988
|
return /* @__PURE__ */ jsxs76("div", { className: "mt-2 flex flex-col gap-1.5 border-t border-ods-border pt-2", children: [
|
|
24957
|
-
/* @__PURE__ */
|
|
24989
|
+
/* @__PURE__ */ jsx99("span", { className: "uppercase text-ods-text-muted text-h6", children: "Sources" }),
|
|
24958
24990
|
/* @__PURE__ */ jsxs76("div", { className: `flex flex-wrap gap-1.5 ${expanded ? "max-h-[200px] overflow-y-auto overscroll-contain" : ""}`, children: [
|
|
24959
|
-
cited.map((src) => /* @__PURE__ */
|
|
24991
|
+
cited.map((src) => /* @__PURE__ */ jsx99(
|
|
24960
24992
|
SourceChip,
|
|
24961
24993
|
{
|
|
24962
24994
|
src,
|
|
@@ -24967,7 +24999,7 @@ function SourceChips({
|
|
|
24967
24999
|
},
|
|
24968
25000
|
src.index
|
|
24969
25001
|
)),
|
|
24970
|
-
expanded && uncited.map((src) => /* @__PURE__ */
|
|
25002
|
+
expanded && uncited.map((src) => /* @__PURE__ */ jsx99(
|
|
24971
25003
|
SourceChip,
|
|
24972
25004
|
{
|
|
24973
25005
|
src,
|
|
@@ -24978,7 +25010,7 @@ function SourceChips({
|
|
|
24978
25010
|
},
|
|
24979
25011
|
src.index
|
|
24980
25012
|
)),
|
|
24981
|
-
hasOverflow && /* @__PURE__ */
|
|
25013
|
+
hasOverflow && /* @__PURE__ */ jsx99(
|
|
24982
25014
|
"button",
|
|
24983
25015
|
{
|
|
24984
25016
|
onClick: () => setExpanded(!expanded),
|
|
@@ -24993,7 +25025,7 @@ function SourceChips({
|
|
|
24993
25025
|
}
|
|
24994
25026
|
var EmbeddableChat = React10.forwardRef(
|
|
24995
25027
|
function EmbeddableChatImpl(props, ref) {
|
|
24996
|
-
return /* @__PURE__ */
|
|
25028
|
+
return /* @__PURE__ */ jsx99(EmbeddableChatInner, { ...props, handleRef: ref });
|
|
24997
25029
|
}
|
|
24998
25030
|
);
|
|
24999
25031
|
EmbeddableChat.displayName = "EmbeddableChat";
|
|
@@ -25328,7 +25360,7 @@ function EmbeddableChatInner({
|
|
|
25328
25360
|
[discussRef, displayRef, resolvedBaseRoute, chipBasePlatform, extras]
|
|
25329
25361
|
);
|
|
25330
25362
|
const mingoAssistantIcon = useMemo31(
|
|
25331
|
-
() => effectiveAssistantIcon ? /* @__PURE__ */
|
|
25363
|
+
() => effectiveAssistantIcon ? /* @__PURE__ */ jsx99(EntityIcon, { icon: effectiveAssistantIcon, size: 24 }) : /* @__PURE__ */ jsx99(MingoIcon, { className: "h-6 w-6", cornerColor: "var(--ods-flamingo-cyan-base)" }),
|
|
25332
25364
|
[effectiveAssistantIcon]
|
|
25333
25365
|
);
|
|
25334
25366
|
const [timestampCache] = useState48(() => /* @__PURE__ */ new Map());
|
|
@@ -25487,7 +25519,7 @@ function EmbeddableChatInner({
|
|
|
25487
25519
|
if (chatLoading && index === messages.length - 1) return null;
|
|
25488
25520
|
const { cited, uncited } = splitCitedSources(message.sources, flattenAssistantContent(message.content));
|
|
25489
25521
|
if (cited.length === 0 && uncited.length === 0) return null;
|
|
25490
|
-
return /* @__PURE__ */
|
|
25522
|
+
return /* @__PURE__ */ jsx99("div", { className: "pb-2", children: /* @__PURE__ */ jsx99(
|
|
25491
25523
|
SourceChips,
|
|
25492
25524
|
{
|
|
25493
25525
|
cited,
|
|
@@ -25558,6 +25590,7 @@ function EmbeddableChatInner({
|
|
|
25558
25590
|
const headerOnRename = activeDialogId && activeDialog && mingoCaps.canRename ? () => setRenameTarget(activeDialog) : void 0;
|
|
25559
25591
|
const headerOnArchive = activeDialogId && activeDialog && mingoCaps.canArchive ? () => setArchiveTarget(activeDialog) : void 0;
|
|
25560
25592
|
const headerOnCopyLink = activeDialogId && activeDialog && mingoCaps.onCopyLink ? () => mingoCaps.onCopyLink?.(activeDialog) : void 0;
|
|
25593
|
+
const headerOnCompact = activeDialogId && activeDialog && mingoCaps.compactDialog ? () => mingoCaps.compactDialog?.(activeDialog) : void 0;
|
|
25561
25594
|
const headerOnOpenArchive = fetchArchivedDialogs ? openArchive : void 0;
|
|
25562
25595
|
const headerOwner = hasConversation ? activeDialog?.owner : void 0;
|
|
25563
25596
|
const headerPersonName = headerOwner?.name?.trim() || headerUserName;
|
|
@@ -25606,11 +25639,12 @@ function EmbeddableChatInner({
|
|
|
25606
25639
|
}),
|
|
25607
25640
|
[resetToNewChat, contextMaxItems]
|
|
25608
25641
|
);
|
|
25609
|
-
const splitHeaderMenuItems =
|
|
25610
|
-
|
|
25611
|
-
|
|
25612
|
-
|
|
25613
|
-
|
|
25642
|
+
const splitHeaderMenuItems = chatDialogMenuItems({
|
|
25643
|
+
onCopyLink: headerOnCopyLink,
|
|
25644
|
+
onRename: headerOnRename,
|
|
25645
|
+
onCompact: headerOnCompact,
|
|
25646
|
+
onArchive: headerOnArchive
|
|
25647
|
+
});
|
|
25614
25648
|
const narrowMingoEmpty = isMingoMode && !hasConversation && !archiveOpen && !emptyListSkipped;
|
|
25615
25649
|
const narrowHeaderProps = narrowMingoEmpty ? composeOpen ? {
|
|
25616
25650
|
showBack: true,
|
|
@@ -25641,16 +25675,17 @@ function EmbeddableChatInner({
|
|
|
25641
25675
|
onRestore: headerOnRestore,
|
|
25642
25676
|
onRename: headerOnRename,
|
|
25643
25677
|
onArchive: headerOnArchive,
|
|
25678
|
+
onCompact: headerOnCompact,
|
|
25644
25679
|
onCopyLink: headerOnCopyLink,
|
|
25645
25680
|
onOpenArchive: headerOnOpenArchive
|
|
25646
25681
|
};
|
|
25647
|
-
const body = /* @__PURE__ */
|
|
25648
|
-
/* @__PURE__ */
|
|
25682
|
+
const body = /* @__PURE__ */ jsx99(PortalContainerContext.Provider, { value: portalHost, children: /* @__PURE__ */ jsxs76(CollisionBoundaryContext.Provider, { value: panelBoundary, children: [
|
|
25683
|
+
/* @__PURE__ */ jsx99(
|
|
25649
25684
|
"div",
|
|
25650
25685
|
{
|
|
25651
25686
|
ref: setPanelNode,
|
|
25652
25687
|
className: `flex h-full flex-col overflow-hidden transition-colors duration-200 ${archiveOpen && !splitActive || stackedListView ? "bg-ods-card" : "bg-ods-bg"} ${previewMode ? "pointer-events-none select-none" : ""}`,
|
|
25653
|
-
children: archiveOpen && !splitActive ? /* @__PURE__ */
|
|
25688
|
+
children: archiveOpen && !splitActive ? /* @__PURE__ */ jsx99("div", { className: "flex min-h-0 flex-1 flex-col duration-200 animate-in fade-in-0", children: /* @__PURE__ */ jsx99(
|
|
25654
25689
|
ChatArchivePage,
|
|
25655
25690
|
{
|
|
25656
25691
|
dialogs: archivedDialogs,
|
|
@@ -25679,15 +25714,15 @@ function EmbeddableChatInner({
|
|
|
25679
25714
|
// sub-`md` viewport would split the body yet drop to the mobile
|
|
25680
25715
|
// single-bar header (no rail search / collapse controls).
|
|
25681
25716
|
/* @__PURE__ */ jsxs76("div", { className: "flex h-14 w-full flex-shrink-0 overflow-hidden border-b border-ods-border bg-ods-card", children: [
|
|
25682
|
-
railPresence.mounted && /* @__PURE__ */
|
|
25717
|
+
railPresence.mounted && /* @__PURE__ */ jsx99(RailSlot, { active: railPresence.active, innerClassName: "flex overflow-hidden", children: archiveOpen ? (
|
|
25683
25718
|
// Archive open in the wide layout — the rail header
|
|
25684
25719
|
// turns into a "Chat Archive" back bar (the list itself
|
|
25685
25720
|
// renders in the rail below); the chat block is untouched.
|
|
25686
25721
|
// Back is a full-height leading cell, matching the other
|
|
25687
25722
|
// header cells (not a small inline chevron).
|
|
25688
25723
|
/* @__PURE__ */ jsxs76(Fragment34, { children: [
|
|
25689
|
-
/* @__PURE__ */
|
|
25690
|
-
/* @__PURE__ */
|
|
25724
|
+
/* @__PURE__ */ jsx99(ChatHeaderIconButton, { divider: "right", onClick: closeArchive, "aria-label": "Back to chats", children: /* @__PURE__ */ jsx99(Chevron02LeftIcon, { size: 24 }) }),
|
|
25725
|
+
/* @__PURE__ */ jsx99("div", { className: "flex min-w-0 flex-1 items-center px-[var(--spacing-system-mf)]", children: /* @__PURE__ */ jsx99("span", { className: "min-w-0 flex-1 truncate text-ods-text-primary text-h3", children: "Chat Archive" }) })
|
|
25691
25726
|
] })
|
|
25692
25727
|
) : (
|
|
25693
25728
|
// "Current Chats" rail header — title fills, then the
|
|
@@ -25695,7 +25730,7 @@ function EmbeddableChatInner({
|
|
|
25695
25730
|
// inline field takes over the title area in place
|
|
25696
25731
|
// (Figma 116:51217) and the magnifier toggle is hidden.
|
|
25697
25732
|
/* @__PURE__ */ jsxs76(Fragment34, { children: [
|
|
25698
|
-
railSearchOpen && mingoCaps.onSearchChange ? /* @__PURE__ */
|
|
25733
|
+
railSearchOpen && mingoCaps.onSearchChange ? /* @__PURE__ */ jsx99(
|
|
25699
25734
|
ChatHeaderSearchField,
|
|
25700
25735
|
{
|
|
25701
25736
|
initialValue: mingoCaps.searchQuery,
|
|
@@ -25703,22 +25738,22 @@ function EmbeddableChatInner({
|
|
|
25703
25738
|
onCollapse: () => setRailSearchOpen(false)
|
|
25704
25739
|
}
|
|
25705
25740
|
) : /* @__PURE__ */ jsxs76(Fragment34, { children: [
|
|
25706
|
-
/* @__PURE__ */
|
|
25707
|
-
mingoCaps.onSearchChange && /* @__PURE__ */
|
|
25741
|
+
/* @__PURE__ */ jsx99("div", { className: "flex min-w-0 flex-1 items-center px-[var(--spacing-system-mf)]", children: /* @__PURE__ */ jsx99("span", { className: "min-w-0 flex-1 truncate text-ods-text-primary text-h3", children: "Current Chats" }) }),
|
|
25742
|
+
mingoCaps.onSearchChange && /* @__PURE__ */ jsx99(
|
|
25708
25743
|
ChatHeaderIconButton,
|
|
25709
25744
|
{
|
|
25710
25745
|
onClick: () => setRailSearchOpen((o) => !o),
|
|
25711
25746
|
"aria-label": "Search chats",
|
|
25712
25747
|
"aria-pressed": railSearchOpen,
|
|
25713
|
-
children: /* @__PURE__ */
|
|
25748
|
+
children: /* @__PURE__ */ jsx99(SearchIcon, { size: 24 })
|
|
25714
25749
|
}
|
|
25715
25750
|
)
|
|
25716
25751
|
] }),
|
|
25717
|
-
headerOnOpenArchive && /* @__PURE__ */
|
|
25752
|
+
headerOnOpenArchive && /* @__PURE__ */ jsx99(ChatHeaderIconButton, { onClick: headerOnOpenArchive, "aria-label": "Chat archive", children: /* @__PURE__ */ jsx99(ClockHistoryIcon, { size: 24 }) })
|
|
25718
25753
|
] })
|
|
25719
25754
|
) }),
|
|
25720
25755
|
/* @__PURE__ */ jsxs76("div", { className: "flex min-w-0 flex-1", children: [
|
|
25721
|
-
/* @__PURE__ */
|
|
25756
|
+
/* @__PURE__ */ jsx99(
|
|
25722
25757
|
"button",
|
|
25723
25758
|
{
|
|
25724
25759
|
type: "button",
|
|
@@ -25726,17 +25761,17 @@ function EmbeddableChatInner({
|
|
|
25726
25761
|
"aria-label": splitActive ? "Collapse chat list" : "Show chat list",
|
|
25727
25762
|
"aria-pressed": !splitActive,
|
|
25728
25763
|
className: "flex size-14 shrink-0 items-center justify-center border-r border-ods-border text-ods-text-secondary transition-colors hover:bg-ods-bg-hover hover:text-ods-text-primary focus:outline-none focus-visible:ring-2 focus-visible:ring-ods-accent",
|
|
25729
|
-
children: splitActive ? /* @__PURE__ */
|
|
25764
|
+
children: splitActive ? /* @__PURE__ */ jsx99(Arrow02RightIcon, { size: 24 }) : /* @__PURE__ */ jsx99(Arrow02LeftIcon, { size: 24 })
|
|
25730
25765
|
}
|
|
25731
25766
|
),
|
|
25732
25767
|
/* @__PURE__ */ jsxs76("div", { className: "flex min-w-0 flex-1 items-center gap-[var(--spacing-system-m)] px-[var(--spacing-system-mf)] py-[var(--spacing-system-sf)]", children: [
|
|
25733
25768
|
/* @__PURE__ */ jsxs76("div", { className: "flex min-w-0 flex-col", children: [
|
|
25734
|
-
/* @__PURE__ */
|
|
25735
|
-
headerPersonName && /* @__PURE__ */
|
|
25769
|
+
/* @__PURE__ */ jsx99("p", { className: "truncate leading-tight text-ods-text-primary text-h3", children: headerShowBack || isGuideEmpty ? headerTitle : freshConversationTitle }),
|
|
25770
|
+
headerPersonName && /* @__PURE__ */ jsx99("p", { className: "truncate leading-tight text-ods-text-secondary text-h6", children: headerPersonName })
|
|
25736
25771
|
] }),
|
|
25737
25772
|
headerAvatar ? (
|
|
25738
25773
|
// Owner avatar at the title cell's right edge (Figma 113:63273).
|
|
25739
|
-
/* @__PURE__ */
|
|
25774
|
+
/* @__PURE__ */ jsx99(
|
|
25740
25775
|
SquareAvatar,
|
|
25741
25776
|
{
|
|
25742
25777
|
variant: "round",
|
|
@@ -25751,17 +25786,17 @@ function EmbeddableChatInner({
|
|
|
25751
25786
|
)
|
|
25752
25787
|
) : null
|
|
25753
25788
|
] }),
|
|
25754
|
-
isViewingArchived && headerOnRestore && /* @__PURE__ */
|
|
25755
|
-
headerShowBack && !isViewingArchived && splitHeaderMenuItems.length > 0 && /* @__PURE__ */
|
|
25789
|
+
isViewingArchived && headerOnRestore && /* @__PURE__ */ jsx99(ChatHeaderIconButton, { onClick: headerOnRestore, "aria-label": "Unarchive chat", children: /* @__PURE__ */ jsx99(Refresh01LeftIcon, { size: 24 }) }),
|
|
25790
|
+
headerShowBack && !isViewingArchived && splitHeaderMenuItems.length > 0 && /* @__PURE__ */ jsx99(
|
|
25756
25791
|
ActionsMenuDropdown,
|
|
25757
25792
|
{
|
|
25758
25793
|
triggerAriaLabel: "Chat actions",
|
|
25759
25794
|
onCloseAutoFocus: (e) => e.preventDefault(),
|
|
25760
25795
|
groups: [{ items: splitHeaderMenuItems }],
|
|
25761
|
-
customTrigger: /* @__PURE__ */
|
|
25796
|
+
customTrigger: /* @__PURE__ */ jsx99(ChatHeaderIconButton, { "aria-label": "Chat actions", children: /* @__PURE__ */ jsx99(Ellipsis01Icon, { size: 24 }) })
|
|
25762
25797
|
}
|
|
25763
25798
|
),
|
|
25764
|
-
/* @__PURE__ */
|
|
25799
|
+
/* @__PURE__ */ jsx99(ChatHeaderIconButton, { onClick: handleClose, "aria-label": "Close", children: /* @__PURE__ */ jsx99(XmarkIcon, { size: 24 }) })
|
|
25765
25800
|
] })
|
|
25766
25801
|
] })
|
|
25767
25802
|
) : (
|
|
@@ -25769,14 +25804,14 @@ function EmbeddableChatInner({
|
|
|
25769
25804
|
// guide, resolved into `narrowHeaderProps` above. (Wide layouts,
|
|
25770
25805
|
// including rail-collapsed, use the wide header above.) Embedded
|
|
25771
25806
|
// previews (hero demo tabs) force the compact bar via `compact`.
|
|
25772
|
-
/* @__PURE__ */
|
|
25807
|
+
/* @__PURE__ */ jsx99(ChatPanelHeader, { ...narrowHeaderProps, compact: previewMode })
|
|
25773
25808
|
),
|
|
25774
|
-
activeMode === "guide" && hasMingoMode && /* @__PURE__ */
|
|
25809
|
+
activeMode === "guide" && hasMingoMode && /* @__PURE__ */ jsx99(GuideModeBanner, { className: "duration-200 animate-in fade-in-0" }),
|
|
25775
25810
|
/* @__PURE__ */ jsxs76("div", { className: "flex min-h-0 flex-1 overflow-hidden", children: [
|
|
25776
|
-
railPresence.mounted && /* @__PURE__ */
|
|
25811
|
+
railPresence.mounted && /* @__PURE__ */ jsx99(RailSlot, { active: railPresence.active, innerClassName: "flex flex-col min-h-0 bg-ods-card", children: archiveOpen ? (
|
|
25777
25812
|
// Archive list inside the rail (header lives in the split
|
|
25778
25813
|
// header's left cell above). Right chat block stays put.
|
|
25779
|
-
/* @__PURE__ */
|
|
25814
|
+
/* @__PURE__ */ jsx99(
|
|
25780
25815
|
ChatArchivePage,
|
|
25781
25816
|
{
|
|
25782
25817
|
embedded: true,
|
|
@@ -25790,7 +25825,7 @@ function EmbeddableChatInner({
|
|
|
25790
25825
|
}
|
|
25791
25826
|
}
|
|
25792
25827
|
)
|
|
25793
|
-
) : /* @__PURE__ */
|
|
25828
|
+
) : /* @__PURE__ */ jsx99(
|
|
25794
25829
|
MingoHistoryRail,
|
|
25795
25830
|
{
|
|
25796
25831
|
dialogs,
|
|
@@ -25800,6 +25835,7 @@ function EmbeddableChatInner({
|
|
|
25800
25835
|
onRequestRename: mingoCaps.canRename ? setRenameTarget : void 0,
|
|
25801
25836
|
onRequestArchive: mingoCaps.canArchive ? setArchiveTarget : void 0,
|
|
25802
25837
|
onRequestCopyLink: mingoCaps.onCopyLink,
|
|
25838
|
+
onRequestCompact: mingoCaps.compactDialog,
|
|
25803
25839
|
scope: dialogScope,
|
|
25804
25840
|
onScopeChange: setDialogScope,
|
|
25805
25841
|
searchQuery: mingoCaps.searchQuery,
|
|
@@ -25813,11 +25849,11 @@ function EmbeddableChatInner({
|
|
|
25813
25849
|
onRetry: reloadDialogs
|
|
25814
25850
|
}
|
|
25815
25851
|
) }),
|
|
25816
|
-
/* @__PURE__ */
|
|
25852
|
+
/* @__PURE__ */ jsx99("div", { className: "flex min-h-0 min-w-0 flex-1 flex-col", children: stackedListView ? (
|
|
25817
25853
|
// Narrow "Current Chats" list (Figma 341:36190) — the default
|
|
25818
25854
|
// single-column view. No composer here; "Start New Chat" opens
|
|
25819
25855
|
// the compose view.
|
|
25820
|
-
/* @__PURE__ */
|
|
25856
|
+
/* @__PURE__ */ jsx99(
|
|
25821
25857
|
MingoHistoryRail,
|
|
25822
25858
|
{
|
|
25823
25859
|
className: "duration-200 animate-in fade-in-0",
|
|
@@ -25828,6 +25864,7 @@ function EmbeddableChatInner({
|
|
|
25828
25864
|
onRequestRename: mingoCaps.canRename ? setRenameTarget : void 0,
|
|
25829
25865
|
onRequestArchive: mingoCaps.canArchive ? setArchiveTarget : void 0,
|
|
25830
25866
|
onRequestCopyLink: mingoCaps.onCopyLink,
|
|
25867
|
+
onRequestCompact: mingoCaps.compactDialog,
|
|
25831
25868
|
scope: dialogScope,
|
|
25832
25869
|
onScopeChange: setDialogScope,
|
|
25833
25870
|
searchQuery: mingoCaps.searchQuery,
|
|
@@ -25842,11 +25879,11 @@ function EmbeddableChatInner({
|
|
|
25842
25879
|
}
|
|
25843
25880
|
)
|
|
25844
25881
|
) : /* @__PURE__ */ jsxs76(Fragment34, { children: [
|
|
25845
|
-
/* @__PURE__ */
|
|
25882
|
+
/* @__PURE__ */ jsx99("div", { ref: galleryPanelRef, className: "flex min-h-0 flex-1 flex-col p-[var(--spacing-system-m)]", children: /* @__PURE__ */ jsx99(
|
|
25846
25883
|
"div",
|
|
25847
25884
|
{
|
|
25848
25885
|
className: "flex min-h-0 flex-1 flex-col duration-200 animate-in fade-in-0",
|
|
25849
|
-
children: hasConversation ? /* @__PURE__ */
|
|
25886
|
+
children: hasConversation ? /* @__PURE__ */ jsx99("div", { className: "flex min-h-0 flex-1 flex-col", children: messagesInitialLoading ? (
|
|
25850
25887
|
// Match the real list's `fullWidth` layout so swapping
|
|
25851
25888
|
// skeleton → bubbles doesn't shift the column. The panel
|
|
25852
25889
|
// wrapper above already pads (`p-[var(--spacing-system-m)]`),
|
|
@@ -25857,8 +25894,8 @@ function EmbeddableChatInner({
|
|
|
25857
25894
|
// skeleton overflows a short panel and grows its OWN
|
|
25858
25895
|
// scrollbar — ugly. `fill` top-anchors + clips overflow so
|
|
25859
25896
|
// it reads as "the whole panel is loading" and never scrolls.
|
|
25860
|
-
/* @__PURE__ */
|
|
25861
|
-
) : /* @__PURE__ */
|
|
25897
|
+
/* @__PURE__ */ jsx99(ChatMessageListSkeleton, { fullWidth: true, fill: previewMode, className: "flex-1" })
|
|
25898
|
+
) : /* @__PURE__ */ jsx99(
|
|
25862
25899
|
ChatMessageList,
|
|
25863
25900
|
{
|
|
25864
25901
|
messages,
|
|
@@ -25888,7 +25925,7 @@ function EmbeddableChatInner({
|
|
|
25888
25925
|
centred greeting + capability grid + Guide-chat promo +
|
|
25889
25926
|
quick-action chips. Guide mode keeps the slash-command
|
|
25890
25927
|
onboarding list below. */
|
|
25891
|
-
/* @__PURE__ */
|
|
25928
|
+
/* @__PURE__ */ jsx99(
|
|
25892
25929
|
MingoWelcome,
|
|
25893
25930
|
{
|
|
25894
25931
|
onStartGuideChat: effectiveModes.guide ? () => handleActiveModeChange("guide") : void 0,
|
|
@@ -25903,7 +25940,7 @@ function EmbeddableChatInner({
|
|
|
25903
25940
|
/* Figma node 7532:328214 — Guide-mode empty state: greeting
|
|
25904
25941
|
+ slash-command onboarding list share one scroll region,
|
|
25905
25942
|
with a pinned quick-action chip row above the composer. */
|
|
25906
|
-
/* @__PURE__ */
|
|
25943
|
+
/* @__PURE__ */ jsx99(
|
|
25907
25944
|
GuideWelcome,
|
|
25908
25945
|
{
|
|
25909
25946
|
subtitle: effectiveGreeting ?? void 0,
|
|
@@ -25920,7 +25957,7 @@ function EmbeddableChatInner({
|
|
|
25920
25957
|
onQuickActionHoverEnd: () => setQuickActionPreview(null),
|
|
25921
25958
|
agentSlug: activeAgentSlug,
|
|
25922
25959
|
children: (chipCommands.length > 0 || !commandsLoaded) && /* @__PURE__ */ jsxs76("div", { className: "shrink-0 overflow-hidden rounded-md border border-ods-border", children: [
|
|
25923
|
-
!commandsLoaded && chipCommands.length === 0 && SKELETON_ROW_VARIANTS.map((variant, i) => /* @__PURE__ */
|
|
25960
|
+
!commandsLoaded && chipCommands.length === 0 && SKELETON_ROW_VARIANTS.map((variant, i) => /* @__PURE__ */ jsx99(
|
|
25924
25961
|
MingoOnboardingCardSkeleton,
|
|
25925
25962
|
{
|
|
25926
25963
|
titleWidth: variant.titleWidth,
|
|
@@ -25938,10 +25975,10 @@ function EmbeddableChatInner({
|
|
|
25938
25975
|
label: action.label,
|
|
25939
25976
|
onClick: () => dispatchSlashCommandAction(action.id, cmdId, chatInputRef)
|
|
25940
25977
|
}));
|
|
25941
|
-
return /* @__PURE__ */
|
|
25978
|
+
return /* @__PURE__ */ jsx99(
|
|
25942
25979
|
MingoOnboardingCard,
|
|
25943
25980
|
{
|
|
25944
|
-
icon: /* @__PURE__ */
|
|
25981
|
+
icon: /* @__PURE__ */ jsx99(Icon, { size: 16 }),
|
|
25945
25982
|
title: label,
|
|
25946
25983
|
slashCommand: `/${cmdId}`,
|
|
25947
25984
|
description: cmd.description,
|
|
@@ -25957,7 +25994,7 @@ function EmbeddableChatInner({
|
|
|
25957
25994
|
},
|
|
25958
25995
|
contentViewKey
|
|
25959
25996
|
) }),
|
|
25960
|
-
/* @__PURE__ */
|
|
25997
|
+
/* @__PURE__ */ jsx99(
|
|
25961
25998
|
ChatAttachmentChipStrip,
|
|
25962
25999
|
{
|
|
25963
26000
|
attachments: stagedAttachments,
|
|
@@ -25965,7 +26002,7 @@ function EmbeddableChatInner({
|
|
|
25965
26002
|
disabled: chatLoading
|
|
25966
26003
|
}
|
|
25967
26004
|
),
|
|
25968
|
-
/* @__PURE__ */
|
|
26005
|
+
/* @__PURE__ */ jsx99(
|
|
25969
26006
|
ChatComposer,
|
|
25970
26007
|
{
|
|
25971
26008
|
archived: isViewingArchived,
|
|
@@ -26011,7 +26048,7 @@ function EmbeddableChatInner({
|
|
|
26011
26048
|
}
|
|
26012
26049
|
),
|
|
26013
26050
|
galleryModal,
|
|
26014
|
-
/* @__PURE__ */
|
|
26051
|
+
/* @__PURE__ */ jsx99(
|
|
26015
26052
|
ChatDialogModals,
|
|
26016
26053
|
{
|
|
26017
26054
|
renameTarget,
|
|
@@ -26025,15 +26062,15 @@ function EmbeddableChatInner({
|
|
|
26025
26062
|
onConfirmRestore: handleConfirmRestore
|
|
26026
26063
|
}
|
|
26027
26064
|
),
|
|
26028
|
-
/* @__PURE__ */
|
|
26065
|
+
/* @__PURE__ */ jsx99("div", { ref: setPortalHost, style: { display: "contents" } })
|
|
26029
26066
|
] }) });
|
|
26030
26067
|
const panel = shellLess ? /* @__PURE__ */ jsxs76(ChatPanelContext.Provider, { value: chatPanelHandle, children: [
|
|
26031
|
-
/* @__PURE__ */
|
|
26068
|
+
/* @__PURE__ */ jsx99(VisuallyHidden, { children: /* @__PURE__ */ jsxs76(DialogPrimitive2.Title, { children: [
|
|
26032
26069
|
sourceLabel,
|
|
26033
26070
|
" AI Assistant"
|
|
26034
26071
|
] }) }),
|
|
26035
26072
|
body
|
|
26036
|
-
] }) : /* @__PURE__ */
|
|
26073
|
+
] }) : /* @__PURE__ */ jsx99(Drawer, { open: isOpen, onOpenChange: (o) => !o && handleClose(), children: /* @__PURE__ */ jsx99(ChatPanelContext.Provider, { value: chatPanelHandle, children: /* @__PURE__ */ jsxs76(
|
|
26037
26074
|
DrawerContent,
|
|
26038
26075
|
{
|
|
26039
26076
|
side: "right",
|
|
@@ -26048,7 +26085,7 @@ function EmbeddableChatInner({
|
|
|
26048
26085
|
"aria-describedby": void 0,
|
|
26049
26086
|
className: "mingo-chat-content w-screen !bg-ods-bg shadow-2xl focus:outline-none focus-visible:outline-none md:w-auto",
|
|
26050
26087
|
children: [
|
|
26051
|
-
/* @__PURE__ */
|
|
26088
|
+
/* @__PURE__ */ jsx99(VisuallyHidden, { children: /* @__PURE__ */ jsxs76(DialogPrimitive2.Title, { children: [
|
|
26052
26089
|
sourceLabel,
|
|
26053
26090
|
" AI Assistant"
|
|
26054
26091
|
] }) }),
|
|
@@ -26057,16 +26094,16 @@ function EmbeddableChatInner({
|
|
|
26057
26094
|
}
|
|
26058
26095
|
) }) });
|
|
26059
26096
|
return /* @__PURE__ */ jsxs76(Fragment34, { children: [
|
|
26060
|
-
showInternalTrigger && !shellLess && /* @__PURE__ */
|
|
26097
|
+
showInternalTrigger && !shellLess && /* @__PURE__ */ jsx99(
|
|
26061
26098
|
"div",
|
|
26062
26099
|
{
|
|
26063
26100
|
"aria-hidden": isOpen,
|
|
26064
26101
|
className: `pointer-events-none sticky bottom-0 z-[9990] h-0 ${isOpen ? "opacity-0" : "opacity-100"}`,
|
|
26065
|
-
children: /* @__PURE__ */
|
|
26102
|
+
children: /* @__PURE__ */ jsx99("div", { className: "absolute bottom-4 right-4 md:bottom-6 md:right-6", children: /* @__PURE__ */ jsx99(
|
|
26066
26103
|
Button,
|
|
26067
26104
|
{
|
|
26068
26105
|
onClick: handleOpen,
|
|
26069
|
-
leftIcon: /* @__PURE__ */
|
|
26106
|
+
leftIcon: /* @__PURE__ */ jsx99(MingoIcon, { className: "h-5 w-5", color: "currentColor" }),
|
|
26070
26107
|
tabIndex: isOpen ? -1 : 0,
|
|
26071
26108
|
className: `pointer-events-auto !w-auto shadow-lg ${isOpen ? "!pointer-events-none" : ""}`,
|
|
26072
26109
|
children: "Ask AI"
|
|
@@ -26470,4 +26507,4 @@ export {
|
|
|
26470
26507
|
buildStreamFrames,
|
|
26471
26508
|
EmbeddableChat
|
|
26472
26509
|
};
|
|
26473
|
-
//# sourceMappingURL=chunk-
|
|
26510
|
+
//# sourceMappingURL=chunk-OMTLCMQB.js.map
|