@flamingo-stack/openframe-frontend-core 0.0.608-snapshot.20260908153450 → 0.0.608
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-QX4ANESW.js → chunk-4LGYBV7U.js} +6 -6
- package/dist/{chunk-DKNXAJMP.cjs → chunk-4Y7LBWRN.cjs} +159 -159
- package/dist/{chunk-DKNXAJMP.cjs.map → chunk-4Y7LBWRN.cjs.map} +1 -1
- package/dist/{chunk-TCEALWE3.cjs → chunk-4ZBC4YSQ.cjs} +33 -33
- package/dist/{chunk-TCEALWE3.cjs.map → chunk-4ZBC4YSQ.cjs.map} +1 -1
- package/dist/{chunk-MVBRMQGU.js → chunk-5QHY4HCC.js} +2 -2
- package/dist/{chunk-L2JWC5VS.cjs → chunk-6T3252KL.cjs} +43 -43
- package/dist/{chunk-L2JWC5VS.cjs.map → chunk-6T3252KL.cjs.map} +1 -1
- package/dist/{chunk-3N4FXBVJ.cjs → chunk-7ADEWG65.cjs} +3 -3
- package/dist/{chunk-3N4FXBVJ.cjs.map → chunk-7ADEWG65.cjs.map} +1 -1
- package/dist/{chunk-D3DTC7SZ.cjs → chunk-7EETXACY.cjs} +15 -15
- package/dist/{chunk-D3DTC7SZ.cjs.map → chunk-7EETXACY.cjs.map} +1 -1
- package/dist/{chunk-HGVW7OHI.js → chunk-AQGQVYDC.js} +2 -2
- package/dist/{chunk-GMOBT5NP.cjs → chunk-BEAO6SUX.cjs} +70 -70
- package/dist/{chunk-GMOBT5NP.cjs.map → chunk-BEAO6SUX.cjs.map} +1 -1
- package/dist/{chunk-C7CTEUU7.js → chunk-BKZCYRGG.js} +2 -2
- package/dist/{chunk-ZRLFBLME.cjs → chunk-C3FIMKT7.cjs} +3 -3
- package/dist/{chunk-ZRLFBLME.cjs.map → chunk-C3FIMKT7.cjs.map} +1 -1
- package/dist/{chunk-JKM5FH63.js → chunk-FK5WVAC3.js} +3 -3
- package/dist/{chunk-RZM6FPOT.cjs → chunk-FRRNSQOG.cjs} +25 -25
- package/dist/{chunk-RZM6FPOT.cjs.map → chunk-FRRNSQOG.cjs.map} +1 -1
- package/dist/{chunk-JR7I2AGL.js → chunk-HONE2UX4.js} +3 -3
- package/dist/{chunk-6MLRFM3T.js → chunk-IK2MM26F.js} +5 -5
- package/dist/{chunk-BSMPCPOZ.js → chunk-JGSEBZYO.js} +38 -155
- package/dist/{chunk-BSMPCPOZ.js.map → chunk-JGSEBZYO.js.map} +1 -1
- package/dist/{chunk-45XXK2VU.cjs → chunk-JIPSQ4P7.cjs} +10 -10
- package/dist/{chunk-45XXK2VU.cjs.map → chunk-JIPSQ4P7.cjs.map} +1 -1
- package/dist/{chunk-NJUSDREV.cjs → chunk-JZBRMXB7.cjs} +22 -22
- package/dist/{chunk-NJUSDREV.cjs.map → chunk-JZBRMXB7.cjs.map} +1 -1
- package/dist/{chunk-O2M4T34Q.cjs → chunk-L77QUPE5.cjs} +4 -4
- package/dist/{chunk-O2M4T34Q.cjs.map → chunk-L77QUPE5.cjs.map} +1 -1
- package/dist/{chunk-SEW25Y2W.cjs → chunk-LJMTURDD.cjs} +10 -10
- package/dist/{chunk-SEW25Y2W.cjs.map → chunk-LJMTURDD.cjs.map} +1 -1
- package/dist/{chunk-LA2W5L6K.js → chunk-MDXSLZML.js} +2 -2
- package/dist/{chunk-FYG7QNAO.cjs → chunk-N25MIHYE.cjs} +5 -5
- package/dist/{chunk-FYG7QNAO.cjs.map → chunk-N25MIHYE.cjs.map} +1 -1
- package/dist/{chunk-VCYRJY7J.js → chunk-N6GFOA4J.js} +4 -4
- package/dist/{chunk-B7LYKBCD.js → chunk-ORGNII3T.js} +5 -5
- package/dist/{chunk-B3UXNGVM.js → chunk-PLPRL4YX.js} +3 -3
- package/dist/{chunk-BUXGWBTF.js → chunk-RN3DBEWX.js} +2 -2
- package/dist/{chunk-JOCVQZGT.js → chunk-UCKFVNYV.js} +5 -5
- package/dist/{chunk-XNDTYTVT.cjs → chunk-VK743MVL.cjs} +71 -188
- package/dist/chunk-VK743MVL.cjs.map +1 -0
- package/dist/{chunk-OTYV6SDN.js → chunk-WHHA3LVL.js} +3 -3
- package/dist/{chunk-CZTOSG7Q.cjs → chunk-WZROKAJT.cjs} +22 -22
- package/dist/{chunk-CZTOSG7Q.cjs.map → chunk-WZROKAJT.cjs.map} +1 -1
- package/dist/{chunk-TJ3GFULR.js → chunk-XATCZQGR.js} +3 -3
- package/dist/{chunk-3XNMDLGB.cjs → chunk-YTXKRN6K.cjs} +9 -9
- package/dist/{chunk-3XNMDLGB.cjs.map → chunk-YTXKRN6K.cjs.map} +1 -1
- package/dist/components/case-studies/index.cjs +9 -9
- package/dist/components/case-studies/index.js +3 -3
- package/dist/components/chat/index.cjs +2 -2
- package/dist/components/chat/index.js +1 -1
- package/dist/components/chat/utils/history-merge.d.ts +2 -4
- package/dist/components/chat/utils/history-merge.d.ts.map +1 -1
- package/dist/components/contact/index.cjs +4 -4
- package/dist/components/contact/index.js +3 -3
- package/dist/components/docs/index.cjs +7 -7
- package/dist/components/docs/index.js +6 -6
- package/dist/components/embeds/index.cjs +4 -4
- package/dist/components/embeds/index.js +3 -3
- package/dist/components/faq/index.cjs +4 -4
- package/dist/components/faq/index.js +3 -3
- package/dist/components/features/index.cjs +3 -3
- package/dist/components/features/index.js +2 -2
- package/dist/components/help-center-pages/index.cjs +23 -23
- package/dist/components/help-center-pages/index.js +14 -14
- package/dist/components/index.cjs +38 -38
- package/dist/components/index.js +13 -13
- package/dist/components/meeting-scheduler/index.cjs +24 -24
- package/dist/components/meeting-scheduler/index.js +2 -2
- package/dist/components/navigation/index.cjs +6 -6
- package/dist/components/navigation/index.js +5 -5
- package/dist/components/onboarding-guides/index.cjs +6 -6
- package/dist/components/onboarding-guides/index.js +5 -5
- package/dist/components/tickets/index.cjs +7 -7
- package/dist/components/tickets/index.js +6 -6
- package/dist/components/ui/index.cjs +3 -3
- package/dist/components/ui/index.js +2 -2
- package/dist/index.cjs +7 -7
- package/dist/index.js +6 -6
- package/package.json +1 -1
- package/src/components/chat/utils/__tests__/history-merge.test.ts +0 -292
- package/src/components/chat/utils/history-merge.ts +56 -276
- package/dist/chunk-XNDTYTVT.cjs.map +0 -1
- /package/dist/{chunk-QX4ANESW.js.map → chunk-4LGYBV7U.js.map} +0 -0
- /package/dist/{chunk-MVBRMQGU.js.map → chunk-5QHY4HCC.js.map} +0 -0
- /package/dist/{chunk-HGVW7OHI.js.map → chunk-AQGQVYDC.js.map} +0 -0
- /package/dist/{chunk-C7CTEUU7.js.map → chunk-BKZCYRGG.js.map} +0 -0
- /package/dist/{chunk-JKM5FH63.js.map → chunk-FK5WVAC3.js.map} +0 -0
- /package/dist/{chunk-JR7I2AGL.js.map → chunk-HONE2UX4.js.map} +0 -0
- /package/dist/{chunk-6MLRFM3T.js.map → chunk-IK2MM26F.js.map} +0 -0
- /package/dist/{chunk-LA2W5L6K.js.map → chunk-MDXSLZML.js.map} +0 -0
- /package/dist/{chunk-VCYRJY7J.js.map → chunk-N6GFOA4J.js.map} +0 -0
- /package/dist/{chunk-B7LYKBCD.js.map → chunk-ORGNII3T.js.map} +0 -0
- /package/dist/{chunk-B3UXNGVM.js.map → chunk-PLPRL4YX.js.map} +0 -0
- /package/dist/{chunk-BUXGWBTF.js.map → chunk-RN3DBEWX.js.map} +0 -0
- /package/dist/{chunk-JOCVQZGT.js.map → chunk-UCKFVNYV.js.map} +0 -0
- /package/dist/{chunk-OTYV6SDN.js.map → chunk-WHHA3LVL.js.map} +0 -0
- /package/dist/{chunk-TJ3GFULR.js.map → chunk-XATCZQGR.js.map} +0 -0
|
@@ -22729,18 +22729,6 @@ var SYNTHETIC_REALTIME_ID_PREFIXES = ["assistant-", "user-", "direct-", "system-
|
|
|
22729
22729
|
function isSyntheticRealtimeId(id) {
|
|
22730
22730
|
return SYNTHETIC_REALTIME_ID_PREFIXES.some((prefix) => id.startsWith(prefix));
|
|
22731
22731
|
}
|
|
22732
|
-
function isOptimisticId(id) {
|
|
22733
|
-
return id.startsWith("optimistic-");
|
|
22734
|
-
}
|
|
22735
|
-
function isUserRequestSyntheticId(id) {
|
|
22736
|
-
return id.startsWith("user-");
|
|
22737
|
-
}
|
|
22738
|
-
function isClientMintedId(id) {
|
|
22739
|
-
return isSyntheticRealtimeId(id) || isOptimisticId(id);
|
|
22740
|
-
}
|
|
22741
|
-
function isWelcomeId(id) {
|
|
22742
|
-
return id.startsWith("welcome-");
|
|
22743
|
-
}
|
|
22744
22732
|
function assistantAnswerText(content) {
|
|
22745
22733
|
if (typeof content === "string") return content.trim();
|
|
22746
22734
|
if (!Array.isArray(content)) return "";
|
|
@@ -22773,45 +22761,13 @@ function turnRequestKeys(content) {
|
|
|
22773
22761
|
}
|
|
22774
22762
|
return keys;
|
|
22775
22763
|
}
|
|
22776
|
-
function sharesRequestKey(
|
|
22777
|
-
if (keys.size === 0
|
|
22778
|
-
for (const key of
|
|
22779
|
-
if (
|
|
22764
|
+
function sharesRequestKey(content, keys) {
|
|
22765
|
+
if (keys.size === 0) return false;
|
|
22766
|
+
for (const key of turnRequestKeys(content)) {
|
|
22767
|
+
if (keys.has(key)) return true;
|
|
22780
22768
|
}
|
|
22781
22769
|
return false;
|
|
22782
22770
|
}
|
|
22783
|
-
function userText(m) {
|
|
22784
|
-
return m.role === "user" && typeof m.content === "string" ? m.content : "";
|
|
22785
|
-
}
|
|
22786
|
-
function collectTwinSignals(rows) {
|
|
22787
|
-
const signals = { requestKeys: /* @__PURE__ */ new Set(), assistantTexts: /* @__PURE__ */ new Map(), userContents: /* @__PURE__ */ new Map() };
|
|
22788
|
-
for (const row of rows) {
|
|
22789
|
-
for (const key of turnRequestKeys(row.content)) signals.requestKeys.add(key);
|
|
22790
|
-
if (row.role === "assistant") {
|
|
22791
|
-
const text2 = assistantAnswerText(row.content);
|
|
22792
|
-
if (text2 !== "") signals.assistantTexts.set(text2, (_nullishCoalesce(signals.assistantTexts.get(text2), () => ( 0))) + 1);
|
|
22793
|
-
continue;
|
|
22794
|
-
}
|
|
22795
|
-
const text = userText(row);
|
|
22796
|
-
if (text !== "") signals.userContents.set(text, (_nullishCoalesce(signals.userContents.get(text), () => ( 0))) + 1);
|
|
22797
|
-
}
|
|
22798
|
-
return signals;
|
|
22799
|
-
}
|
|
22800
|
-
function twinVerdict(signals, m) {
|
|
22801
|
-
if (m.role !== "assistant") {
|
|
22802
|
-
const text2 = userText(m);
|
|
22803
|
-
if (text2 === "") return "unknown";
|
|
22804
|
-
return signals.userContents.has(text2) ? "twin" : "distinct";
|
|
22805
|
-
}
|
|
22806
|
-
const keys = turnRequestKeys(m.content);
|
|
22807
|
-
if (keys.size > 0) return sharesRequestKey(keys, signals.requestKeys) ? "twin" : "distinct";
|
|
22808
|
-
const text = assistantAnswerText(m.content);
|
|
22809
|
-
if (text === "") return "unknown";
|
|
22810
|
-
for (const other of signals.assistantTexts.keys()) {
|
|
22811
|
-
if (other.startsWith(text) || text.startsWith(other)) return "twin";
|
|
22812
|
-
}
|
|
22813
|
-
return "distinct";
|
|
22814
|
-
}
|
|
22815
22771
|
function flattenMessagePagesChronological(pages) {
|
|
22816
22772
|
if (!pages) return [];
|
|
22817
22773
|
return [...pages].reverse().flatMap((page) => [...page.messages].reverse());
|
|
@@ -22876,7 +22832,7 @@ function mergeHistoryWithRealtime(input) {
|
|
|
22876
22832
|
const persistedSize = historyTrailingAssistant.content.length;
|
|
22877
22833
|
const persistedSeq = _nullishCoalesce(historyTrailingAssistant.streamSeq, () => ( 0));
|
|
22878
22834
|
const trailingKeys = turnRequestKeys(historyTrailingAssistant.content);
|
|
22879
|
-
const isSameTurn = (m) => m.id === historyTrailingAssistant.id || sharesRequestKey(
|
|
22835
|
+
const isSameTurn = (m) => m.id === historyTrailingAssistant.id || trailingKeys.size > 0 && sharesRequestKey(m.content, trailingKeys);
|
|
22880
22836
|
const richerTwin = existingMessages.find(
|
|
22881
22837
|
(m) => m !== historyTrailingAssistant && m.role === "assistant" && Array.isArray(m.content) && isSameTurn(m) && // A STILL-STREAMING twin wins outright: it is the copy the chunks are
|
|
22882
22838
|
// landing in, so "richer" is a property it is about to have anyway,
|
|
@@ -22893,64 +22849,30 @@ function mergeHistoryWithRealtime(input) {
|
|
|
22893
22849
|
}
|
|
22894
22850
|
const lastProcessed = processedToUse[processedToUse.length - 1];
|
|
22895
22851
|
const trailingAssistantText = lastProcessed && lastProcessed.role === "assistant" ? assistantAnswerText(lastProcessed.content) : "";
|
|
22896
|
-
const
|
|
22897
|
-
const
|
|
22898
|
-
|
|
22899
|
-
|
|
22900
|
-
const isPersistedOlder = (m) => !isClientMintedId(m.id) && (_nullishCoalesce(_optionalChain([m, 'access', _755 => _755.timestamp, 'optionalAccess', _756 => _756.getTime, 'call', _757 => _757()]), () => ( 0))) <= historyFetchedAt;
|
|
22901
|
-
let lastOlderPersistedIndex = -1;
|
|
22902
|
-
if (firstWindowIndex < 0) {
|
|
22903
|
-
for (const [index, m] of existingMessages.entries()) {
|
|
22904
|
-
if (isPersistedOlder(m) && !pinnedSyntheticIds.has(m.id) && !droppedSyntheticIds.has(m.id)) {
|
|
22905
|
-
lastOlderPersistedIndex = index;
|
|
22906
|
-
}
|
|
22852
|
+
const persistedUserContentCounts = /* @__PURE__ */ new Map();
|
|
22853
|
+
for (const pm of processedToUse) {
|
|
22854
|
+
if (pm.role === "user" && typeof pm.content === "string") {
|
|
22855
|
+
persistedUserContentCounts.set(pm.content, (_nullishCoalesce(persistedUserContentCounts.get(pm.content), () => ( 0))) + 1);
|
|
22907
22856
|
}
|
|
22908
22857
|
}
|
|
22909
|
-
|
|
22910
|
-
|
|
22911
|
-
|
|
22912
|
-
|
|
22913
|
-
if (
|
|
22914
|
-
|
|
22915
|
-
|
|
22916
|
-
|
|
22917
|
-
|
|
22918
|
-
const time = _optionalChain([pm, 'access', _758 => _758.timestamp, 'optionalAccess', _759 => _759.getTime, 'call', _760 => _760()]);
|
|
22919
|
-
if (typeof time === "number" && time < windowMinTime) windowMinTime = time;
|
|
22920
|
-
}
|
|
22921
|
-
const threadHasClientMintedRow = existingMessages.some((m) => isClientMintedId(m.id));
|
|
22922
|
-
const seqCanMislead = (m) => m.role === "assistant" ? windowHasUnstampedAssistant : isUserRequestSyntheticId(m.id) || isOptimisticId(m.id);
|
|
22923
|
-
const isOlderThanWindow = (m, index) => {
|
|
22924
|
-
if (m.id === streamingMessageId) return false;
|
|
22925
|
-
if (firstWindowIndex >= 0) {
|
|
22926
|
-
if (index >= firstWindowIndex) return false;
|
|
22927
|
-
return !(isClientMintedId(m.id) && sharesRequestKey(turnRequestKeys(m.content), windowSignals.requestKeys));
|
|
22928
|
-
}
|
|
22929
|
-
if (index < lastOlderPersistedIndex) return true;
|
|
22930
|
-
if (!isClientMintedId(m.id)) return isPersistedOlder(m);
|
|
22931
|
-
if (typeof m.streamSeq === "number") {
|
|
22932
|
-
if (!Number.isFinite(windowMinSeq) || m.streamSeq >= windowMinSeq) return false;
|
|
22933
|
-
const verdict = twinVerdict(windowSignals, m);
|
|
22934
|
-
return verdict === "unknown" ? !seqCanMislead(m) : verdict === "distinct";
|
|
22935
|
-
}
|
|
22936
|
-
const time = _optionalChain([m, 'access', _761 => _761.timestamp, 'optionalAccess', _762 => _762.getTime, 'call', _763 => _763()]);
|
|
22937
|
-
if (typeof time !== "number" || time > historyFetchedAt) return false;
|
|
22938
|
-
if (!Number.isFinite(windowMinTime) || time >= windowMinTime) return false;
|
|
22939
|
-
return twinVerdict(windowSignals, m) === "distinct";
|
|
22940
|
-
};
|
|
22941
|
-
const keepRealtime = (m) => {
|
|
22942
|
-
if (m.role === "user" && isOptimisticId(m.id) && typeof m.content === "string") {
|
|
22943
|
-
const canBeInSnapshot = (_nullishCoalesce(_optionalChain([m, 'access', _764 => _764.timestamp, 'optionalAccess', _765 => _765.getTime, 'call', _766 => _766()]), () => ( 0))) <= historyFetchedAt;
|
|
22944
|
-
return !(canBeInSnapshot && windowSignals.userContents.has(m.content));
|
|
22858
|
+
const seenUserSyntheticByContent = /* @__PURE__ */ new Map();
|
|
22859
|
+
const realtimeMessages = existingMessages.filter((m) => {
|
|
22860
|
+
if (pinnedSyntheticIds.has(m.id)) return true;
|
|
22861
|
+
if (droppedSyntheticIds.has(m.id)) return false;
|
|
22862
|
+
if (processedIds.has(m.id)) return false;
|
|
22863
|
+
if (_optionalChain([rawHistoryIds, 'optionalAccess', _753 => _753.has, 'call', _754 => _754(m.id)])) return false;
|
|
22864
|
+
if (m.role === "user" && m.id.startsWith("optimistic-") && typeof m.content === "string") {
|
|
22865
|
+
const canBeInSnapshot = (_nullishCoalesce(_optionalChain([m, 'access', _755 => _755.timestamp, 'optionalAccess', _756 => _756.getTime, 'call', _757 => _757()]), () => ( 0))) <= historyFetchedAt;
|
|
22866
|
+
return !(canBeInSnapshot && processedToUse.some((pm) => pm.role === "user" && pm.content === m.content));
|
|
22945
22867
|
}
|
|
22946
22868
|
if (isSyntheticRealtimeId(m.id) && m.id !== streamingMessageId) {
|
|
22947
22869
|
if (m.role === "assistant" && trailingAssistantText && assistantAnswerText(m.content) === trailingAssistantText) {
|
|
22948
22870
|
return false;
|
|
22949
22871
|
}
|
|
22950
|
-
if (m.role === "user" &&
|
|
22872
|
+
if (m.role === "user" && m.id.startsWith("user-") && typeof m.content === "string") {
|
|
22951
22873
|
const seen = (_nullishCoalesce(seenUserSyntheticByContent.get(m.content), () => ( 0))) + 1;
|
|
22952
22874
|
seenUserSyntheticByContent.set(m.content, seen);
|
|
22953
|
-
if ((_nullishCoalesce(
|
|
22875
|
+
if ((_nullishCoalesce(persistedUserContentCounts.get(m.content), () => ( 0))) < seen) return true;
|
|
22954
22876
|
if (typeof m.streamSeq !== "number" || historyMaxStreamSeq <= 0) return false;
|
|
22955
22877
|
if (historyMaxStreamSeq >= m.streamSeq) return false;
|
|
22956
22878
|
const lastPersisted = processedToUse[processedToUse.length - 1];
|
|
@@ -22964,76 +22886,37 @@ function mergeHistoryWithRealtime(input) {
|
|
|
22964
22886
|
} else if (typeof m.streamSeq === "number") {
|
|
22965
22887
|
covered = historyMaxStreamSeq > 0 && historyMaxStreamSeq >= m.streamSeq;
|
|
22966
22888
|
} else {
|
|
22967
|
-
covered = historyCoversRealtime !== null ? historyCoversRealtime : (_nullishCoalesce(_optionalChain([m, 'access',
|
|
22889
|
+
covered = historyCoversRealtime !== null ? historyCoversRealtime : (_nullishCoalesce(_optionalChain([m, 'access', _758 => _758.timestamp, 'optionalAccess', _759 => _759.getTime, 'call', _760 => _760()]), () => ( 0))) <= historyFetchedAt;
|
|
22968
22890
|
}
|
|
22969
22891
|
if (covered) return false;
|
|
22970
22892
|
}
|
|
22971
22893
|
return true;
|
|
22972
|
-
};
|
|
22973
|
-
|
|
22974
|
-
const realtimeMessages = [];
|
|
22975
|
-
for (const [index, m] of existingMessages.entries()) {
|
|
22976
|
-
if (pinnedSyntheticIds.has(m.id)) {
|
|
22977
|
-
realtimeMessages.push(m);
|
|
22978
|
-
continue;
|
|
22979
|
-
}
|
|
22980
|
-
if (droppedSyntheticIds.has(m.id) || isInWindow(m)) continue;
|
|
22981
|
-
if (firstWindowIndex < 0 && !threadHasClientMintedRow && isPersistedOlder(m) && !isWelcomeId(m.id)) continue;
|
|
22982
|
-
if (isOlderThanWindow(m, index)) {
|
|
22983
|
-
olderThanWindowMessages.push(m);
|
|
22984
|
-
continue;
|
|
22985
|
-
}
|
|
22986
|
-
if (keepRealtime(m)) realtimeMessages.push(m);
|
|
22987
|
-
}
|
|
22988
|
-
return [...olderThanWindowMessages, ...processedToUse, ...realtimeMessages];
|
|
22894
|
+
});
|
|
22895
|
+
return [...processedToUse, ...realtimeMessages];
|
|
22989
22896
|
}
|
|
22990
22897
|
function computeHistoryPrepend(processedHistory, existingMessages) {
|
|
22991
22898
|
const existingIds = new Set(existingMessages.map((m) => m.id));
|
|
22992
|
-
const
|
|
22993
|
-
|
|
22994
|
-
|
|
22995
|
-
|
|
22996
|
-
|
|
22997
|
-
|
|
22998
|
-
const liveSignals = collectTwinSignals(liveAboveBoundary);
|
|
22999
|
-
const userTwinsLeft = new Map(liveSignals.userContents);
|
|
23000
|
-
const assistantTwinsLeft = new Map(liveSignals.assistantTexts);
|
|
23001
|
-
for (let i = newEnd - 1; i >= 0; i--) {
|
|
23002
|
-
const pm = processedHistory[i];
|
|
23003
|
-
if (pm.role === "user") {
|
|
23004
|
-
const text = userText(pm);
|
|
23005
|
-
const left = text === "" ? 0 : _nullishCoalesce(userTwinsLeft.get(text), () => ( 0));
|
|
23006
|
-
if (left === 0) continue;
|
|
23007
|
-
userTwinsLeft.set(text, left - 1);
|
|
23008
|
-
twinIndices.add(i);
|
|
23009
|
-
} else if (pm.role === "assistant") {
|
|
23010
|
-
const keys = turnRequestKeys(pm.content);
|
|
23011
|
-
if (keys.size > 0) {
|
|
23012
|
-
if (sharesRequestKey(keys, liveSignals.requestKeys)) twinIndices.add(i);
|
|
23013
|
-
continue;
|
|
23014
|
-
}
|
|
23015
|
-
const text = assistantAnswerText(pm.content);
|
|
23016
|
-
if (text === "") continue;
|
|
23017
|
-
for (const [liveText, left] of assistantTwinsLeft) {
|
|
23018
|
-
if (left === 0 || !text.startsWith(liveText)) continue;
|
|
23019
|
-
assistantTwinsLeft.set(liveText, left - 1);
|
|
23020
|
-
twinIndices.add(i);
|
|
23021
|
-
break;
|
|
23022
|
-
}
|
|
23023
|
-
}
|
|
22899
|
+
const newMessages = [];
|
|
22900
|
+
let boundaryMessageIndex = -1;
|
|
22901
|
+
for (let i = 0; i < processedHistory.length; i++) {
|
|
22902
|
+
if (existingIds.has(processedHistory[i].id)) {
|
|
22903
|
+
boundaryMessageIndex = i;
|
|
22904
|
+
break;
|
|
23024
22905
|
}
|
|
22906
|
+
newMessages.push(processedHistory[i]);
|
|
23025
22907
|
}
|
|
23026
|
-
const newMessages = processedHistory.slice(0, newEnd).filter((_, i) => !twinIndices.has(i));
|
|
23027
22908
|
let boundaryMessageId;
|
|
23028
22909
|
let boundaryUpdates;
|
|
23029
|
-
if (
|
|
22910
|
+
if (boundaryMessageIndex >= 0) {
|
|
23030
22911
|
const boundaryMessage = processedHistory[boundaryMessageIndex];
|
|
23031
|
-
const existingBoundary = existingMessages
|
|
23032
|
-
|
|
23033
|
-
|
|
23034
|
-
|
|
23035
|
-
|
|
23036
|
-
|
|
22912
|
+
const existingBoundary = existingMessages.find((m) => m.id === boundaryMessage.id);
|
|
22913
|
+
if (existingBoundary) {
|
|
22914
|
+
const existingContent = JSON.stringify(existingBoundary.content);
|
|
22915
|
+
const newContent = JSON.stringify(boundaryMessage.content);
|
|
22916
|
+
if (existingContent !== newContent) {
|
|
22917
|
+
boundaryMessageId = boundaryMessage.id;
|
|
22918
|
+
boundaryUpdates = { content: boundaryMessage.content };
|
|
22919
|
+
}
|
|
23037
22920
|
}
|
|
23038
22921
|
}
|
|
23039
22922
|
if (newMessages.length === 0 && !boundaryUpdates) return null;
|
|
@@ -23073,7 +22956,7 @@ function normalizeHistoricalMessageData(md) {
|
|
|
23073
22956
|
function isHistoricalUserTurn(m) {
|
|
23074
22957
|
return !!m.owner;
|
|
23075
22958
|
}
|
|
23076
|
-
var isTextSegment = (d) => _optionalChain([d, 'optionalAccess',
|
|
22959
|
+
var isTextSegment = (d) => _optionalChain([d, 'optionalAccess', _761 => _761.type]) === "TEXT" && typeof d.text === "string";
|
|
23077
22960
|
var THINK_MS = 550;
|
|
23078
22961
|
var TOKEN_MS = 55;
|
|
23079
22962
|
var USER_MS = 480;
|
|
@@ -23693,7 +23576,7 @@ function useChatDialogManager({
|
|
|
23693
23576
|
const handleConfirmRestore = _react.useCallback.call(void 0, async () => {
|
|
23694
23577
|
if (restoreTarget) {
|
|
23695
23578
|
try {
|
|
23696
|
-
await _optionalChain([unarchiveDialog, 'optionalCall',
|
|
23579
|
+
await _optionalChain([unarchiveDialog, 'optionalCall', _762 => _762(restoreTarget.id)]);
|
|
23697
23580
|
} catch (err) {
|
|
23698
23581
|
console.error("[useChatDialogManager] unarchive failed:", err);
|
|
23699
23582
|
return;
|
|
@@ -24176,7 +24059,7 @@ function EmbeddableChatInner({
|
|
|
24176
24059
|
}),
|
|
24177
24060
|
[commandsUrl]
|
|
24178
24061
|
);
|
|
24179
|
-
const headerUserName = _optionalChain([identityUser, 'optionalAccess',
|
|
24062
|
+
const headerUserName = _optionalChain([identityUser, 'optionalAccess', _763 => _763.name, 'optionalAccess', _764 => _764.trim, 'call', _765 => _765()]) || [_optionalChain([identityUser, 'optionalAccess', _766 => _766.firstName]), _optionalChain([identityUser, 'optionalAccess', _767 => _767.lastName])].filter(Boolean).join(" ").trim() || _optionalChain([userDisplayName, 'optionalAccess', _768 => _768.trim, 'call', _769 => _769()]) || void 0;
|
|
24180
24063
|
const effectiveModes = _react.useMemo.call(void 0, () => {
|
|
24181
24064
|
if (modes) return modes;
|
|
24182
24065
|
const guideOptions = tableIdForDocumentType ? { tableIdForDocumentType } : {};
|
|
@@ -24191,7 +24074,7 @@ function EmbeddableChatInner({
|
|
|
24191
24074
|
if (controlledActiveMode === void 0) {
|
|
24192
24075
|
setUncontrolledActiveMode(next);
|
|
24193
24076
|
}
|
|
24194
|
-
_optionalChain([onActiveModeChange, 'optionalCall',
|
|
24077
|
+
_optionalChain([onActiveModeChange, 'optionalCall', _770 => _770(next)]);
|
|
24195
24078
|
},
|
|
24196
24079
|
[controlledActiveMode, onActiveModeChange]
|
|
24197
24080
|
);
|
|
@@ -24218,7 +24101,7 @@ function EmbeddableChatInner({
|
|
|
24218
24101
|
);
|
|
24219
24102
|
const effectiveAssistantName = emptyStateConfig.name;
|
|
24220
24103
|
const effectiveAssistantIcon = emptyStateConfig.icon;
|
|
24221
|
-
const headerAssistantName = _nullishCoalesce(effectiveAssistantName, () => ( (typeof _optionalChain([guideWelcome, 'optionalAccess',
|
|
24104
|
+
const headerAssistantName = _nullishCoalesce(effectiveAssistantName, () => ( (typeof _optionalChain([guideWelcome, 'optionalAccess', _771 => _771.title]) === "string" ? guideWelcome.title : null)));
|
|
24222
24105
|
const {
|
|
24223
24106
|
messages: rawMessages,
|
|
24224
24107
|
isLoading: chatLoading,
|
|
@@ -24261,8 +24144,8 @@ function EmbeddableChatInner({
|
|
|
24261
24144
|
const mingoCaps = _react.useMemo.call(void 0,
|
|
24262
24145
|
() => ({
|
|
24263
24146
|
...dialogCapabilities,
|
|
24264
|
-
canRename: _nullishCoalesce(_optionalChain([dialogCapabilities, 'optionalAccess',
|
|
24265
|
-
canArchive: _nullishCoalesce(_optionalChain([dialogCapabilities, 'optionalAccess',
|
|
24147
|
+
canRename: _nullishCoalesce(_optionalChain([dialogCapabilities, 'optionalAccess', _772 => _772.canRename]), () => ( false)),
|
|
24148
|
+
canArchive: _nullishCoalesce(_optionalChain([dialogCapabilities, 'optionalAccess', _773 => _773.canArchive]), () => ( false))
|
|
24266
24149
|
}),
|
|
24267
24150
|
[dialogCapabilities]
|
|
24268
24151
|
);
|
|
@@ -24277,7 +24160,7 @@ function EmbeddableChatInner({
|
|
|
24277
24160
|
void sendMessage(guidePendingPrompt).catch((err) => {
|
|
24278
24161
|
console.error("[EmbeddableChat] guide launcher prompt failed:", err);
|
|
24279
24162
|
});
|
|
24280
|
-
_optionalChain([onGuidePromptConsumed, 'optionalCall',
|
|
24163
|
+
_optionalChain([onGuidePromptConsumed, 'optionalCall', _774 => _774()]);
|
|
24281
24164
|
}, [guidePendingPrompt, activeMode, sendMessage, onGuidePromptConsumed]);
|
|
24282
24165
|
const {
|
|
24283
24166
|
attachments: stagedAttachments,
|
|
@@ -24288,7 +24171,7 @@ function EmbeddableChatInner({
|
|
|
24288
24171
|
clear: clearAttachments
|
|
24289
24172
|
} = useChatAttachments();
|
|
24290
24173
|
const { panelRef: galleryPanelRef, modal: galleryModal } = useChatAttachmentImageGallery();
|
|
24291
|
-
const contextMaxItems = _nullishCoalesce(_optionalChain([contextPicker, 'optionalAccess',
|
|
24174
|
+
const contextMaxItems = _nullishCoalesce(_optionalChain([contextPicker, 'optionalAccess', _775 => _775.maxItems]), () => ( 10));
|
|
24292
24175
|
const contextPickerForMode = activeMode === "mingo" ? contextPicker : void 0;
|
|
24293
24176
|
const [contextItems, setContextItems] = _react.useState.call(void 0, NO_CONTEXT_ITEMS);
|
|
24294
24177
|
const [contextPickerOpen, setContextPickerOpen] = _react.useState.call(void 0, false);
|
|
@@ -24309,10 +24192,10 @@ function EmbeddableChatInner({
|
|
|
24309
24192
|
}, [activeDialogId, activeMode]);
|
|
24310
24193
|
const mentionMarkerByType = _react.useMemo.call(void 0, () => {
|
|
24311
24194
|
const m = /* @__PURE__ */ new Map();
|
|
24312
|
-
for (const t of _nullishCoalesce(_optionalChain([contextPicker, 'optionalAccess',
|
|
24195
|
+
for (const t of _nullishCoalesce(_optionalChain([contextPicker, 'optionalAccess', _776 => _776.entityTypes]), () => ( []))) if (t.marker) m.set(t.type, t.marker);
|
|
24313
24196
|
return m;
|
|
24314
|
-
}, [_optionalChain([contextPicker, 'optionalAccess',
|
|
24315
|
-
const contextEntityTypes = _optionalChain([contextPicker, 'optionalAccess',
|
|
24197
|
+
}, [_optionalChain([contextPicker, 'optionalAccess', _777 => _777.entityTypes])]);
|
|
24198
|
+
const contextEntityTypes = _optionalChain([contextPicker, 'optionalAccess', _778 => _778.entityTypes]);
|
|
24316
24199
|
const resolveContextIcon = _react.useMemo.call(void 0, () => {
|
|
24317
24200
|
const byType = /* @__PURE__ */ new Map();
|
|
24318
24201
|
for (const t of _nullishCoalesce(contextEntityTypes, () => ( []))) byType.set(t.type, t.icon);
|
|
@@ -24324,7 +24207,7 @@ function EmbeddableChatInner({
|
|
|
24324
24207
|
if (mentionActiveRef.current) {
|
|
24325
24208
|
if (contextItems.some((p) => `${p.type}:${p.id}` === key)) return;
|
|
24326
24209
|
if (contextItems.length >= contextMaxItems) return;
|
|
24327
|
-
_optionalChain([chatInputRef, 'access',
|
|
24210
|
+
_optionalChain([chatInputRef, 'access', _779 => _779.current, 'optionalAccess', _780 => _780.commitMention, 'call', _781 => _781(mentionTokenOf(key, mentionMarkerByType), {
|
|
24328
24211
|
label: item.label,
|
|
24329
24212
|
icon: resolveContextIcon(item)
|
|
24330
24213
|
})]);
|
|
@@ -24347,9 +24230,9 @@ function EmbeddableChatInner({
|
|
|
24347
24230
|
setContextItems((prev) => prev.filter((p) => `${p.type}:${p.id}` !== key));
|
|
24348
24231
|
if (mentionKeysRef.current.has(key)) {
|
|
24349
24232
|
mentionKeysRef.current.delete(key);
|
|
24350
|
-
const cur = _nullishCoalesce(_optionalChain([chatInputRef, 'access',
|
|
24233
|
+
const cur = _nullishCoalesce(_optionalChain([chatInputRef, 'access', _782 => _782.current, 'optionalAccess', _783 => _783.getValue, 'call', _784 => _784()]), () => ( ""));
|
|
24351
24234
|
const next = cur.replace(`@${mentionTokenOf(key, mentionMarkerByType)}`, "").replace(/\s{2,}/g, " ").trimStart();
|
|
24352
|
-
_optionalChain([chatInputRef, 'access',
|
|
24235
|
+
_optionalChain([chatInputRef, 'access', _785 => _785.current, 'optionalAccess', _786 => _786.setValue, 'call', _787 => _787(next)]);
|
|
24353
24236
|
}
|
|
24354
24237
|
},
|
|
24355
24238
|
[mentionMarkerByType]
|
|
@@ -24371,7 +24254,7 @@ function EmbeddableChatInner({
|
|
|
24371
24254
|
}, []);
|
|
24372
24255
|
const closeContextPicker = _react.useCallback.call(void 0, () => {
|
|
24373
24256
|
if (mentionActiveRef.current) {
|
|
24374
|
-
_optionalChain([chatInputRef, 'access',
|
|
24257
|
+
_optionalChain([chatInputRef, 'access', _788 => _788.current, 'optionalAccess', _789 => _789.removeMentionTrigger, 'call', _790 => _790()]);
|
|
24375
24258
|
}
|
|
24376
24259
|
setContextPickerOpen(false);
|
|
24377
24260
|
setMentionQuery(null);
|
|
@@ -24405,8 +24288,8 @@ function EmbeddableChatInner({
|
|
|
24405
24288
|
[effectiveAssistantIcon]
|
|
24406
24289
|
);
|
|
24407
24290
|
const [timestampCache] = _react.useState.call(void 0, () => /* @__PURE__ */ new Map());
|
|
24408
|
-
const guideUserName = activeMode === "guide" ? [_optionalChain([identityUser, 'optionalAccess',
|
|
24409
|
-
const guideUserAvatar = activeMode === "guide" ? _optionalChain([identityUser, 'optionalAccess',
|
|
24291
|
+
const guideUserName = activeMode === "guide" ? [_optionalChain([identityUser, 'optionalAccess', _791 => _791.firstName]), _optionalChain([identityUser, 'optionalAccess', _792 => _792.lastName])].filter(Boolean).join(" ").trim() || _optionalChain([identityUser, 'optionalAccess', _793 => _793.name, 'optionalAccess', _794 => _794.trim, 'call', _795 => _795()]) || void 0 : void 0;
|
|
24292
|
+
const guideUserAvatar = activeMode === "guide" ? _optionalChain([identityUser, 'optionalAccess', _796 => _796.avatarUrl, 'optionalAccess', _797 => _797.trim, 'call', _798 => _798()]) || void 0 : void 0;
|
|
24410
24293
|
const messages = _react.useMemo.call(void 0, () => {
|
|
24411
24294
|
const cache = timestampCache;
|
|
24412
24295
|
const seenIds = /* @__PURE__ */ new Set();
|
|
@@ -24596,9 +24479,9 @@ function EmbeddableChatInner({
|
|
|
24596
24479
|
const lastAssistantMsg = [...rawMessages].reverse().find((m) => m.role === "assistant");
|
|
24597
24480
|
const lastSources = _react.useMemo.call(void 0, () => {
|
|
24598
24481
|
if (chatLoading) return void 0;
|
|
24599
|
-
const sources = _optionalChain([lastAssistantMsg, 'optionalAccess',
|
|
24482
|
+
const sources = _optionalChain([lastAssistantMsg, 'optionalAccess', _799 => _799.sources]);
|
|
24600
24483
|
if (!sources || sources.length === 0) return void 0;
|
|
24601
|
-
const content = _optionalChain([lastAssistantMsg, 'optionalAccess',
|
|
24484
|
+
const content = _optionalChain([lastAssistantMsg, 'optionalAccess', _800 => _800.content]) || "";
|
|
24602
24485
|
const citationOrder = [...content.matchAll(/\[(\d+)\]/g)].map((m) => parseInt(m[1], 10));
|
|
24603
24486
|
const seenOrder = /* @__PURE__ */ new Map();
|
|
24604
24487
|
citationOrder.forEach((idx) => {
|
|
@@ -24614,7 +24497,7 @@ function EmbeddableChatInner({
|
|
|
24614
24497
|
_react.useEffect.call(void 0, () => {
|
|
24615
24498
|
if (!panelBoundary || typeof ResizeObserver === "undefined") return void 0;
|
|
24616
24499
|
const ro = new ResizeObserver((entries) => {
|
|
24617
|
-
const w = _optionalChain([entries, 'access',
|
|
24500
|
+
const w = _optionalChain([entries, 'access', _801 => _801[0], 'optionalAccess', _802 => _802.contentRect, 'optionalAccess', _803 => _803.width]);
|
|
24618
24501
|
if (typeof w === "number") setPanelWidth(w);
|
|
24619
24502
|
});
|
|
24620
24503
|
ro.observe(panelBoundary);
|
|
@@ -24658,17 +24541,17 @@ function EmbeddableChatInner({
|
|
|
24658
24541
|
const stackedListView = isMingoMode && !hasConversation && !archiveOpen && !wideMingo && !composeOpen && !emptyListSkipped;
|
|
24659
24542
|
const headerShowBack = hasConversation || guideCanReturnToMingo;
|
|
24660
24543
|
const freshConversationTitle = isGuideEmpty ? _nullishCoalesce(headerAssistantName, () => ( "Mingo Guide")) : "New Chat";
|
|
24661
|
-
const headerTitle = hasConversation ? _optionalChain([activeDialog, 'optionalAccess',
|
|
24544
|
+
const headerTitle = hasConversation ? _optionalChain([activeDialog, 'optionalAccess', _804 => _804.title]) || freshConversationTitle : isGuideEmpty ? freshConversationTitle : "Current Chats";
|
|
24662
24545
|
const headerBackAriaLabel = hasConversation ? isViewingArchived ? "Back to archive" : "Back" : "Back to Mingo";
|
|
24663
24546
|
const headerOnBack = hasConversation ? handleBack : () => handleActiveModeChange("mingo");
|
|
24664
24547
|
const headerOnRestore = isViewingArchived && unarchiveDialog && activeDialog ? () => setRestoreTarget(activeDialog) : void 0;
|
|
24665
24548
|
const headerOnRename = activeDialogId && activeDialog && mingoCaps.canRename ? () => setRenameTarget(activeDialog) : void 0;
|
|
24666
24549
|
const headerOnArchive = activeDialogId && activeDialog && mingoCaps.canArchive ? () => setArchiveTarget(activeDialog) : void 0;
|
|
24667
|
-
const headerOnCopyLink = activeDialogId && activeDialog && mingoCaps.onCopyLink ? () => _optionalChain([mingoCaps, 'access',
|
|
24550
|
+
const headerOnCopyLink = activeDialogId && activeDialog && mingoCaps.onCopyLink ? () => _optionalChain([mingoCaps, 'access', _805 => _805.onCopyLink, 'optionalCall', _806 => _806(activeDialog)]) : void 0;
|
|
24668
24551
|
const headerOnOpenArchive = fetchArchivedDialogs ? openArchive : void 0;
|
|
24669
|
-
const headerOwner = hasConversation ? _optionalChain([activeDialog, 'optionalAccess',
|
|
24670
|
-
const headerPersonName = _optionalChain([headerOwner, 'optionalAccess',
|
|
24671
|
-
const headerPersonAvatarUrl = headerOwner ? _optionalChain([headerOwner, 'access',
|
|
24552
|
+
const headerOwner = hasConversation ? _optionalChain([activeDialog, 'optionalAccess', _807 => _807.owner]) : void 0;
|
|
24553
|
+
const headerPersonName = _optionalChain([headerOwner, 'optionalAccess', _808 => _808.name, 'optionalAccess', _809 => _809.trim, 'call', _810 => _810()]) || headerUserName;
|
|
24554
|
+
const headerPersonAvatarUrl = headerOwner ? _optionalChain([headerOwner, 'access', _811 => _811.avatarUrl, 'optionalAccess', _812 => _812.trim, 'call', _813 => _813()]) || void 0 : _optionalChain([identityUser, 'optionalAccess', _814 => _814.avatarUrl, 'optionalAccess', _815 => _815.trim, 'call', _816 => _816()]) || _optionalChain([userAvatarUrl, 'optionalAccess', _817 => _817.trim, 'call', _818 => _818()]) || void 0;
|
|
24672
24555
|
const headerAvatar = headerPersonName || headerPersonAvatarUrl ? { name: headerPersonName, avatarUrl: headerPersonAvatarUrl } : void 0;
|
|
24673
24556
|
const handleNewChat = _react.useCallback.call(void 0, () => {
|
|
24674
24557
|
resetToNewChat();
|
|
@@ -24998,9 +24881,9 @@ function EmbeddableChatInner({
|
|
|
24998
24881
|
subtitle: _nullishCoalesce(effectiveGreeting, () => ( void 0)),
|
|
24999
24882
|
subtitleLoading: emptyStateLoading,
|
|
25000
24883
|
...guideWelcome,
|
|
25001
|
-
title: _nullishCoalesce(effectiveAssistantName, () => ( _optionalChain([guideWelcome, 'optionalAccess',
|
|
25002
|
-
icon: _nullishCoalesce(effectiveAssistantIcon, () => ( _optionalChain([guideWelcome, 'optionalAccess',
|
|
25003
|
-
quickActions: agentConfigUrl && guideSuggestedActions.length > 0 ? guideSuggestedActions : _nullishCoalesce(_optionalChain([guideWelcome, 'optionalAccess',
|
|
24884
|
+
title: _nullishCoalesce(effectiveAssistantName, () => ( _optionalChain([guideWelcome, 'optionalAccess', _819 => _819.title]))),
|
|
24885
|
+
icon: _nullishCoalesce(effectiveAssistantIcon, () => ( _optionalChain([guideWelcome, 'optionalAccess', _820 => _820.icon]))),
|
|
24886
|
+
quickActions: agentConfigUrl && guideSuggestedActions.length > 0 ? guideSuggestedActions : _nullishCoalesce(_optionalChain([guideWelcome, 'optionalAccess', _821 => _821.quickActions]), () => ( guideSuggestedActions)),
|
|
25004
24887
|
onQuickAction: (action) => {
|
|
25005
24888
|
setQuickActionPreview(null);
|
|
25006
24889
|
handleSend(_nullishCoalesce(action.prompt, () => ( action.label)));
|
|
@@ -25074,8 +24957,8 @@ function EmbeddableChatInner({
|
|
|
25074
24957
|
selectedContextItems: contextItems,
|
|
25075
24958
|
onToggleContextItem: toggleContextItem,
|
|
25076
24959
|
onRemoveContextItem: removeContextItem,
|
|
25077
|
-
contextMemoryItems: _optionalChain([contextMemory, 'optionalAccess',
|
|
25078
|
-
onRemoveContextMemoryItem: _optionalChain([contextMemory, 'optionalAccess',
|
|
24960
|
+
contextMemoryItems: _optionalChain([contextMemory, 'optionalAccess', _822 => _822.items]),
|
|
24961
|
+
onRemoveContextMemoryItem: _optionalChain([contextMemory, 'optionalAccess', _823 => _823.onRemove]),
|
|
25079
24962
|
contextPickerOpen,
|
|
25080
24963
|
onOpenContextPicker: openContextPicker,
|
|
25081
24964
|
onCloseContextPicker: closeContextPicker,
|
|
@@ -25541,4 +25424,4 @@ function EmbeddableChatInner({
|
|
|
25541
25424
|
|
|
25542
25425
|
|
|
25543
25426
|
exports.FloatingTooltip = FloatingTooltip; exports.tagVariants = tagVariants; exports.Tag = Tag; exports.formatTicketRelativeTime = formatTicketRelativeTime; exports.formatTicketFullTimestamp = formatTicketFullTimestamp; exports.formatRelativeTime = formatRelativeTime; exports.formatAbsoluteDate = formatAbsoluteDate; exports.formatDateTime = formatDateTime; exports.getDetailedTimeDifference = getDetailedTimeDifference; exports.isToday = isToday; exports.isWithinMinutes = isWithinMinutes; exports.createUTCTimestamp = createUTCTimestamp; exports.DESIGN_PALETTE = DESIGN_PALETTE; exports.getContrastRatio = getContrastRatio; exports.pickReadableTextColor = pickReadableTextColor; exports.extractDominantColor = extractDominantColor; exports.getBestContrastColor = getBestContrastColor; exports.analyzeImageColor = analyzeImageColor; exports.extractImageEdgeColorAsync = extractImageEdgeColorAsync; exports.getCurrentPlatform = getCurrentPlatform; exports.switchPlatformTheme = switchPlatformTheme; exports.getSemanticColor = getSemanticColor; exports.getPlatformConfig = getPlatformConfig; exports.usePlatformColors = usePlatformColors; exports.getReadableTextColor = getReadableTextColor; exports.HEX_PATTERN = HEX_PATTERN; exports.hexToRgb = hexToRgb2; exports.rgbToHex = rgbToHex; exports.deriveHoverColor = deriveHoverColor; exports.deriveActiveColor = deriveActiveColor; exports.rgbToHsl = rgbToHsl; exports.hslToRgb = hslToRgb; exports.ActionsMenu = ActionsMenu; exports.ActionsMenuDropdown = ActionsMenuDropdown; exports.ColorSwatch = ColorSwatch; exports.TooltipProvider = TooltipProvider; exports.Tooltip = Tooltip; exports.TooltipTrigger = TooltipTrigger; exports.TooltipContent = TooltipContent; exports.resolveTicketStatus = resolveTicketStatus; exports.getTicketStatusConfig = getTicketStatusConfig; exports.getTicketStatusTag = getTicketStatusTag; exports.kindToCanonicalStatus = kindToCanonicalStatus; exports.usesCanonicalStatusStyle = usesCanonicalStatusStyle; exports.resolveStatusTagProps = resolveStatusTagProps; exports.TicketStatusTag = TicketStatusTag; exports.useScrollFade = useScrollFade; exports.ScrollFadeOverlay = ScrollFadeOverlay; exports.ScrollShadow = ScrollShadow; exports.Modal = Modal; exports.ModalContent = ModalContent; exports.ModalTwoColumn = ModalTwoColumn; exports.ModalHeader = ModalHeader; exports.ModalTitle = ModalTitle; exports.ModalFooter = ModalFooter; exports.OVERLAY_BACKDROP_CLASS = OVERLAY_BACKDROP_CLASS; exports.Drawer = Drawer; exports.DrawerTrigger = DrawerTrigger; exports.DrawerClose = DrawerClose; exports.DrawerPortal = DrawerPortal; exports.DrawerOverlay = DrawerOverlay; exports.DrawerContent = DrawerContent; exports.DrawerHeader = DrawerHeader; exports.DrawerTitle = DrawerTitle; exports.DrawerDescription = DrawerDescription; exports.DrawerBody = DrawerBody; exports.DrawerFooter = DrawerFooter; exports.Tabs = Tabs; exports.TabsList = TabsList; exports.TabsTrigger = TabsTrigger; exports.TabsContent = TabsContent; exports.stripInlineMarkdown = stripInlineMarkdown; exports.markdownToPlainText = markdownToPlainText; exports.buildHeadingIdMap = buildHeadingIdMap; exports.useHeadingIdMap = useHeadingIdMap; exports.extractText = extractText; exports.useIsHydrated = useIsHydrated; exports.MermaidDiagram = MermaidDiagram; exports.hasRenderableSrc = hasRenderableSrc; exports.buildStandardLeafRenderers = buildStandardLeafRenderers; exports.SAFE_HTML_TAGS = SAFE_HTML_TAGS; exports.SVG_TAGS = SVG_TAGS; exports.buildEffectiveTagSet = buildEffectiveTagSet; exports.buildSanitizeSchema = buildSanitizeSchema; exports.rehypeStripUnsafe = rehypeStripUnsafe; exports.escapeUnknownHtmlTags = escapeUnknownHtmlTags; exports.cardAwareUrlTransform = cardAwareUrlTransform; exports.splitStreamingBlocks = splitStreamingBlocks; exports.completeStreamingTail = completeStreamingTail; exports.TEXT_SIZE_PRESETS = TEXT_SIZE_PRESETS; exports.resolveTextSizeConfig = resolveTextSizeConfig; exports.NO_BROKEN_LINKS = NO_BROKEN_LINKS; exports.MarkdownEngine = MarkdownEngine; exports.SimpleMarkdownRenderer = SimpleMarkdownRenderer; exports.fetchPriorityProp = fetchPriorityProp; exports.MUX_STREAM_ORIGIN = MUX_STREAM_ORIGIN; exports.MUX_IMAGE_ORIGIN = MUX_IMAGE_ORIGIN; exports.saveDataEnabled = saveDataEnabled; exports.useVideoOriginPreconnect = useVideoOriginPreconnect; exports.useVideoWarmup = useVideoWarmup; exports.VideoPlayBadge = VideoPlayBadge; exports.VideoUnmuteGlyph = VideoUnmuteGlyph; exports.extractYouTubeId = extractYouTubeId; exports.VIDEO_PLAYBACK_FAILED_EVENT = VIDEO_PLAYBACK_FAILED_EVENT; exports.Video = Video2; exports.HoverDropdown = HoverDropdown; exports.ExpandChevron = ExpandChevron; exports.useCollapsible = useCollapsible; exports.getCommandText = getCommandText; exports.ArgRow = ArgRow; exports.ResultBlock = ResultBlock; exports.CommandBlock = CommandBlock; exports.ApprovalStatusTag = ApprovalStatusTag; exports.ApprovalBatchMessage = ApprovalBatchMessage; exports.ApprovalRequestMessage = ApprovalRequestMessage; exports.EscalationOfferMessage = EscalationOfferMessage; exports.formatTime = formatTime; exports.AiAssistantInfo = AiAssistantInfo; exports.TicketEscalatedMessage = TicketEscalatedMessage; exports.MESSAGE_TYPE = MESSAGE_TYPE; exports.SCROLL_ANCHOR = SCROLL_ANCHOR; exports.TICKET_EVENT_KIND = TICKET_EVENT_KIND; exports.TicketEventMessage = TicketEventMessage; exports.ContextCompactionDisplay = ContextCompactionDisplay; exports.ThinkingDisplay = ThinkingDisplay; exports.AskDisplay = AskDisplay; exports.ErrorMessageDisplay = ErrorMessageDisplay; exports.MspOrganizationCard = MspOrganizationCard; exports.MspOrganizationCardSkeleton = MspOrganizationCardSkeleton; exports.ChatContainer = ChatContainer; exports.ChatHeader = ChatHeader; exports.ChatContent = ChatContent; exports.ChatFooter = ChatFooter; exports.ChatTypingIndicator = ChatTypingIndicator; exports.MingoOnboardingCard = MingoOnboardingCard; exports.ICON_REGISTRY = ICON_REGISTRY; exports.normalizeIconKey = normalizeIconKey; exports.getIconComponent = getIconComponent; exports.getDynamicIcon = getDynamicIcon; exports.ICON_ALIASES = ICON_ALIASES; exports.resolveIcon = resolveIcon; exports.ICON_OPTIONS = ICON_OPTIONS; exports.SlashCommandSuggestions = SlashCommandSuggestions; exports.ChatInput = ChatInput; exports.CONTEXT_ROW_CLASS = CONTEXT_ROW_CLASS; exports.CONTEXT_ICON_CLASS = CONTEXT_ICON_CLASS; exports.CONTEXT_LABEL_CLASS = CONTEXT_LABEL_CLASS; exports.CONTEXT_BACK_CLASS = CONTEXT_BACK_CLASS; exports.CONTEXT_STATE_CLASS = CONTEXT_STATE_CLASS; exports.ContextMenuRow = ContextMenuRow; exports.ContextItemsSkeleton = ContextItemsSkeleton; exports.ContextItemsList = ContextItemsList; exports.ContextErrorBoundary = ContextErrorBoundary; exports.CHAT_CONTEXT_ITEMS_DEFAULT_MAX = CHAT_CONTEXT_ITEMS_DEFAULT_MAX; exports.ChatComposerPlusMenu = ChatComposerPlusMenu; exports.ChatContextPicker = ChatContextPicker; exports.ChatContextChipStrip = ChatContextChipStrip; exports.BlockCard = BlockCard; exports.remarkCardLinks = remarkCardLinks; exports.remarkMentionChips = remarkMentionChips; exports.ToolExecutionDisplay = ToolExecutionDisplay; exports.MemoizedChatMessageEnhanced = MemoizedChatMessageEnhanced; exports.ChatMessageSkeleton = ChatMessageSkeleton; exports.ChatMessageListSkeleton = ChatMessageListSkeleton; exports.ChatMessageList = ChatMessageList; exports.useProxiedImageUrl = useProxiedImageUrl; exports.ChatMessageRow = ChatMessageRow; exports.ChatMessageRowSkeleton = ChatMessageRowSkeleton; exports.FAE_AVATAR_DATA_URI = FAE_AVATAR_DATA_URI; exports.AgentMark = AgentMark; exports.EntityIcon = EntityIcon; exports.getAgentAccent = getAgentAccent; exports.accentFromIdentityIcon = accentFromIdentityIcon; exports.isQuickActionIconSpec = isQuickActionIconSpec; exports.renderQuickActionIcon = renderQuickActionIcon; exports.QuickActionChipSkeleton = QuickActionChipSkeleton; exports.QuickActionChipButton = QuickActionChipButton; exports.QuickActionChipFromData = QuickActionChipFromData; exports.useMarqueeSync = useMarqueeSync; exports.getMarqueeTrackOffset = getMarqueeTrackOffset; exports.getMarqueeAppliedOffset = getMarqueeAppliedOffset; exports.getMarqueeCloneTwin = getMarqueeCloneTwin; exports.MarqueeWallFades = MarqueeWallFades; exports.MarqueeWall = MarqueeWall; exports.WALL_SKELETON_LABEL_CH = WALL_SKELETON_LABEL_CH; exports.interleave = interleave; exports.QuickActionWall = QuickActionWall; exports.QuickActionMarquee = QuickActionMarquee; exports.ChatTicketItem = ChatTicketItem; exports.ChatTicketList = ChatTicketList; exports.MingoOnboardingCardSkeleton = MingoOnboardingCardSkeleton; exports.MingoOnboardingListSkeleton = MingoOnboardingListSkeleton; exports.MingoChatHistorySkeleton = MingoChatHistorySkeleton; exports.MingoChatHistory = MingoChatHistory; exports.MingoWelcome = MingoWelcome; exports.GuideWelcome = GuideWelcome; exports.GuideModeBanner = GuideModeBanner; exports.TabSelector = TabSelector; exports.MingoHistoryRail = MingoHistoryRail; exports.RenameChatModal = RenameChatModal; exports.ArchiveChatModal = ArchiveChatModal; exports.UnarchiveChatModal = UnarchiveChatModal; exports.ChatDialogModals = ChatDialogModals; exports.ChatHeaderIconButton = ChatHeaderIconButton; exports.ChatHeaderSearchField = ChatHeaderSearchField; exports.ChatPanelHeader = ChatPanelHeader; exports.CHAT_ATTACHMENT_VIEW_URL_PREFIX = CHAT_ATTACHMENT_VIEW_URL_PREFIX; exports.CHAT_ATTACHMENT_VIEW_TOKEN_QUERY_PARAM = CHAT_ATTACHMENT_VIEW_TOKEN_QUERY_PARAM; exports.ANTHROPIC_SUPPORTED_IMAGE_MIME = ANTHROPIC_SUPPORTED_IMAGE_MIME; exports.buildChatAttachmentViewUrl = buildChatAttachmentViewUrl; exports.escapeMarkdownInline = escapeMarkdownInline; exports.formatChatAttachmentMarkdownForBubble = formatChatAttachmentMarkdownForBubble; exports.CHAT_ATTACHMENT_VIEW_URL_PREFIX_REGEX_ESCAPED = CHAT_ATTACHMENT_VIEW_URL_PREFIX_REGEX_ESCAPED; exports.CHAT_ATTACHMENT_MARKDOWN_PATTERN = CHAT_ATTACHMENT_MARKDOWN_PATTERN; exports.stripChatAttachmentMarkdown = stripChatAttachmentMarkdown; exports.CHAT_ATTACHMENT_MIME_TYPES = CHAT_ATTACHMENT_MIME_TYPES; exports.CHAT_ATTACHMENT_CONCURRENT_UPLOADS_PER_USER = CHAT_ATTACHMENT_CONCURRENT_UPLOADS_PER_USER; exports.ChatAttachmentAddButton = ChatAttachmentAddButton; exports.ChatAttachmentChipStrip = ChatAttachmentChipStrip; exports.ChatContextMemoryBar = ChatContextMemoryBar; exports.HoverCard = HoverCard; exports.HoverCardTrigger = HoverCardTrigger; exports.HoverCardContent = HoverCardContent; exports.ModelDisplay = ModelDisplay; exports.ModelDisplaySkeleton = ModelDisplaySkeleton; exports.ChatComposer = ChatComposer; exports.ChatArchivePage = ChatArchivePage; exports.DialogListItem = DialogListItem; exports.ChatSidebar = ChatSidebar; exports.NEW_TAB_FEATURES = NEW_TAB_FEATURES; exports.isModifierClick = isModifierClick; exports.stripSameOriginToPath = stripSameOriginToPath; exports.resolveExternalNavigation = resolveExternalNavigation; exports.executeNavigation = executeNavigation; exports.executeNavigationImperative = executeNavigationImperative; exports.handleChatNavClick = handleChatNavClick; exports.NavLinkAnchorViaRuntime = NavLinkAnchorViaRuntime; exports.SourceActionButton = SourceActionButton; exports.getCaptionsUrl = getCaptionsUrl; exports.rebaseCaptionsUrl = rebaseCaptionsUrl; exports.buildCaptionsUrl = buildCaptionsUrl; exports.getEntityCaptionUrls = getEntityCaptionUrls; exports.getEntityCaptionUrlsById = getEntityCaptionUrlsById; exports.captionsEntityTypeForDocType = captionsEntityTypeForDocType; exports.PAGE_HEADING_CLASS = PAGE_HEADING_CLASS; exports.SECTION_HEADING_CLASS = SECTION_HEADING_CLASS; exports.PageHeading = PageHeading; exports.useCaptions = useCaptions; exports.UserDisplay = UserDisplay; exports.CardHitLayer = CardHitLayer; exports.STRIP_CELL_MAX_WIDTH = STRIP_CELL_MAX_WIDTH; exports.CardsStrip = CardsStrip; exports.VideoHoverPreviewSurface = VideoHoverPreviewSurface; exports.RATIO_GRID_CLASS = RATIO_GRID_CLASS; exports.RATIO_TO_CSS_ASPECT = RATIO_TO_CSS_ASPECT; exports.RatioTabs = RatioTabs; exports.detectAspectRatio = detectAspectRatio; exports.ratioToCategory = ratioToCategory; exports.groupByAspectRatio = groupByAspectRatio; exports.VideoBitesStrip = VideoBitesStrip; exports.VideoBiteCard = VideoBiteCard; exports.EntityVideoSection = EntityVideoSection; exports.ChatVideoEntityCard = ChatVideoEntityCard; exports.GitHubActivityCard = GitHubActivityCard; exports.GitHubActivityCardSkeleton = GitHubActivityCardSkeleton; exports.SlackMessageCard = SlackMessageCard; exports.SlackMessageCardSkeleton = SlackMessageCardSkeleton; exports.HubspotTicketCard = HubspotTicketCard; exports.HubspotTicketCardSkeleton = HubspotTicketCardSkeleton; exports.DataRoomDocCard = DataRoomDocCard; exports.DataRoomDocCardSkeleton = DataRoomDocCardSkeleton; exports.CampaignCardAdmin = CampaignCardAdmin; exports.CampaignCardAdminSkeleton = CampaignCardAdminSkeleton; exports.GenericEntityCard = GenericEntityCard; exports.GenericEntityCardSkeleton = GenericEntityCardSkeleton; exports.faqSectionSlug = faqSectionSlug; exports.faqItemAnchor = faqItemAnchor; exports.parseFaqHash = parseFaqHash; exports.useChatCardItem = useChatCardItem; exports.clickupTaskUrl = clickupTaskUrl; exports.readFetchedCardTitle = readFetchedCardTitle; exports.resolveFetchedCardHref = resolveFetchedCardHref; exports.SOURCE_ICON_NAMES = SOURCE_ICON_NAMES; exports.getSourceIconName = getSourceIconName; exports.SOURCE_LABELS_BY_TABLE = SOURCE_LABELS_BY_TABLE; exports.getSourceLabel = getSourceLabel; exports.DEFAULT_DOCUMENT_TYPE_TO_TABLE_ID = DEFAULT_DOCUMENT_TYPE_TO_TABLE_ID; exports.defaultTableIdForDocumentType = defaultTableIdForDocumentType; exports.resolveSourceRowCTA = resolveSourceRowCTA; exports.resolveSourceIcon = resolveSourceIcon; exports.ChatCardLoader = ChatCardLoader; exports.renderChatInlineEntityCard = renderChatInlineEntityCard; exports.CHAT_TYPE = CHAT_TYPE; exports.OWNER_TYPE = OWNER_TYPE; exports.MESSAGE_ROLE = MESSAGE_ROLE; exports.ASSISTANT_TYPE = ASSISTANT_TYPE; exports.AUTHOR_TYPE = AUTHOR_TYPE; exports.APPROVAL_STATUS = APPROVAL_STATUS; exports.APPROVAL_BLOCK_VARIANT = APPROVAL_BLOCK_VARIANT; exports.CONNECTION_STATUS = CONNECTION_STATUS; exports.isStructuredContent = isStructuredContent; exports.normalizeContent = normalizeContent2; exports.NETWORK_CONFIG = NETWORK_CONFIG; exports.EMPTY_DIALOG_CAPABILITIES = EMPTY_DIALOG_CAPABILITIES; exports.useChunkCatchup = useChunkCatchup; exports.useScriptedStream = useScriptedStream; exports.RESYNC_AFTER_HIDDEN_MS = RESYNC_AFTER_HIDDEN_MS; exports.useJetStreamDialogSubscription = useJetStreamDialogSubscription; exports.useNatsDialogSubscription = useNatsDialogSubscription; exports.buildNatsWsUrl = buildNatsWsUrl; exports.fetchSlashCommands = fetchSlashCommands; exports.useSlashCommands = useSlashCommands; exports.useSlashCommandRegistry = useSlashCommandRegistry; exports.fetchEmptyStateConfig = fetchEmptyStateConfig; exports.useEmptyStateConfig = useEmptyStateConfig; exports.useChatAttachments = useChatAttachments; exports.useChatAttachmentImageGallery = useChatAttachmentImageGallery; exports.ChatIdentityProvider = ChatIdentityProvider; exports.useChatIdentity = useChatIdentity; exports.useCloseOnNavigation = useCloseOnNavigation; exports.useSSE = useSSE; exports.useChat = useChat; exports.approvalDisplaysInline = approvalDisplaysInline; exports.appendToTrailingAssistant = appendToTrailingAssistant; exports.upsertTrailingCompaction = upsertTrailingCompaction; exports.applyToolExecutionToMessages = applyToolExecutionToMessages; exports.MessageSegmentAccumulator = MessageSegmentAccumulator; exports.createMessageSegmentAccumulator = createMessageSegmentAccumulator; exports.SCROLL_ANCHOR_WIRE_KEY = SCROLL_ANCHOR_WIRE_KEY; exports.parseScrollAnchor = parseScrollAnchor; exports.createEmptyTurnMeta = createEmptyTurnMeta; exports.createChatStreamReducer = createChatStreamReducer; exports.DEFAULT_DIALOG_SIDE = DEFAULT_DIALOG_SIDE; exports.DEFAULT_MAX_REDUCERS = DEFAULT_MAX_REDUCERS; exports.MAX_PENDING_RETAIN_KEYS = MAX_PENDING_RETAIN_KEYS; exports.createChatDialogStore = createChatDialogStore; exports.createDeltaBatcher = createDeltaBatcher; exports.useChatStreamReducer = useChatStreamReducer; exports.createChatConversationsApi = createChatConversationsApi; exports.parseWireCommandOverride = parseWireCommandOverride; exports.sanitizeTitleForChat = sanitizeTitleForChat; exports.formatSingularLookupInvocation = formatSingularLookupInvocation; exports.extractEntityIdFilter = extractEntityIdFilter; exports.buildDiscussAddendum = buildDiscussAddendum; exports.buildDiscussPrompt = buildDiscussPrompt; exports.AUTO_CONTINUATION_DIRECTIVE_PREFIX = AUTO_CONTINUATION_DIRECTIVE_PREFIX; exports.buildAutoContinuationDirective = buildAutoContinuationDirective; exports.useManagedDialogList = useManagedDialogList; exports.useSseChatAdapter = useSseChatAdapter; exports.extractIncompleteMessageState = extractIncompleteMessageState; exports.extractIncompleteTailState = extractIncompleteTailState; exports.decodeHistoricalMessageData = decodeHistoricalMessageData; exports.processHistoricalMessages = processHistoricalMessages; exports.extractErrorMessages = extractErrorMessages; exports.processHistoricalMessagesWithErrors = processHistoricalMessagesWithErrors; exports.mapProcessedToUnified = mapProcessedToUnified; exports.historicalToUnified = historicalToUnified; exports.useNatsChatAdapter = useNatsChatAdapter; exports.useStableShallow = useStableShallow; exports.useUnifiedChat = useUnifiedChat; exports.SYNTHETIC_REALTIME_ID_PREFIXES = SYNTHETIC_REALTIME_ID_PREFIXES; exports.flattenMessagePagesChronological = flattenMessagePagesChronological; exports.maxPersistedStreamSeq = maxPersistedStreamSeq; exports.mergeHistoryWithRealtime = mergeHistoryWithRealtime; exports.computeHistoryPrepend = computeHistoryPrepend; exports.CHIP_ACTION_BUTTON_CLASS = CHIP_ACTION_BUTTON_CLASS; exports.chatChipClass = chatChipClass; exports.flattenAssistantContent = flattenAssistantContent; exports.normalizeHistoricalMessageData = normalizeHistoricalMessageData; exports.isHistoricalUserTurn = isHistoricalUserTurn; exports.buildStreamFrames = buildStreamFrames; exports.EmbeddableChat = EmbeddableChat;
|
|
25544
|
-
//# sourceMappingURL=chunk-
|
|
25427
|
+
//# sourceMappingURL=chunk-VK743MVL.cjs.map
|