@flamingo-stack/openframe-frontend-core 0.0.816 → 0.0.817
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/build/export-map.json +1 -1
- package/dist/{case-study-card-NLT2JVI7.cjs → case-study-card-IZBMHA6R.cjs} +3 -3
- package/dist/{chunk-7ERD34HQ.cjs → chunk-24M2JYM5.cjs} +566 -774
- package/dist/{chunk-3E4FIJAM.cjs → chunk-4ROR52OW.cjs} +15 -15
- package/dist/{chunk-SWBLTIN4.cjs → chunk-5TSYOIIZ.cjs} +54 -52
- package/dist/{chunk-JH65CEO4.cjs → chunk-6F4YGHGM.cjs} +36 -36
- package/dist/{chunk-VDXI26G7.cjs → chunk-7KBHLP4E.cjs} +81 -78
- package/dist/{chunk-CNTBGJA7.cjs → chunk-A34UNP5V.cjs} +65 -1
- package/dist/{chunk-633NTKO2.cjs → chunk-BL2J5RJK.cjs} +31 -53
- package/dist/{chunk-7NYWHEQM.cjs → chunk-C2OUXL3Q.cjs} +15 -15
- package/dist/{chunk-53JJLHJM.cjs → chunk-DSBRWP5M.cjs} +20 -20
- package/dist/chunk-DVHSYPDB.cjs +471 -0
- package/dist/{chunk-5TUR7O7H.cjs → chunk-EX7M3VQC.cjs} +90 -90
- package/dist/{chunk-EJCUAADF.cjs → chunk-F2LVBRHC.cjs} +4 -4
- package/dist/{chunk-GAR2IIU6.cjs → chunk-IM366HS6.cjs} +105 -157
- package/dist/{chunk-FUEK43FL.cjs → chunk-IOFIHVVW.cjs} +206 -200
- package/dist/{chunk-JOOZTRXQ.cjs → chunk-JMOCM2SW.cjs} +4 -4
- package/dist/{chunk-PAI4A3UM.cjs → chunk-K5IICQNF.cjs} +61 -54
- package/dist/{chunk-JOKOQOLJ.cjs → chunk-LUID2IB3.cjs} +2 -2
- package/dist/{chunk-L7W4455K.cjs → chunk-MAHJY2PO.cjs} +3 -3
- package/dist/{chunk-4PMD3JUC.cjs → chunk-NPNZAAOB.cjs} +2 -2
- package/dist/{chunk-EB7YAUER.cjs → chunk-P7JQGOX4.cjs} +19 -19
- package/dist/{chunk-O6VWD2SB.cjs → chunk-RDHF3F5R.cjs} +3 -3
- package/dist/{chunk-HM7VCQSX.cjs → chunk-SBFBNOKU.cjs} +4 -4
- package/dist/{chunk-7O7EX7HQ.cjs → chunk-T266OITJ.cjs} +28 -20
- package/dist/{chunk-ZAWHRYJZ.cjs → chunk-TKEYWSDZ.cjs} +45 -45
- package/dist/{chunk-F4ZJRMMM.cjs → chunk-UDLDXVY4.cjs} +8 -8
- package/dist/{chunk-Y6MJMPHV.cjs → chunk-UEULXVW2.cjs} +32 -84
- package/dist/{chunk-RYJJHSHV.cjs → chunk-UFBVOBYR.cjs} +23 -23
- package/dist/{chunk-IKB6AZPV.cjs → chunk-ZECG6GU5.cjs} +2 -2
- package/dist/{chunk-3ELDGEM2.cjs → chunk-ZP4JMX7G.cjs} +87 -84
- package/dist/{cloud-tenants-SRTX2FZC.cjs → cloud-tenants-NMAXIJLL.cjs} +11 -11
- package/dist/components/announcement-bar.d.ts.map +1 -1
- package/dist/components/announcement-bar.js +5 -5
- package/dist/components/case-studies/index.cjs +26 -26
- package/dist/components/chat/chat-markdown-link.d.ts +15 -0
- package/dist/components/chat/chat-markdown-link.d.ts.map +1 -0
- package/dist/components/chat/chat-markdown-link.js +22 -0
- package/dist/components/chat/chat-message-enhanced.d.ts.map +1 -1
- package/dist/components/chat/chat-message-enhanced.js +3 -9
- package/dist/components/chat/embeddable-chat.d.ts +4 -0
- package/dist/components/chat/embeddable-chat.d.ts.map +1 -1
- package/dist/components/chat/embeddable-chat.js +30 -67
- package/dist/components/chat/entity-cards/chat-card-disclosure.d.ts.map +1 -1
- package/dist/components/chat/entity-cards/chat-card-disclosure.js +8 -11
- package/dist/components/chat/entity-cards/dispatch.d.ts +5 -5
- package/dist/components/chat/entity-cards/dispatch.d.ts.map +1 -1
- package/dist/components/chat/entity-cards/dispatch.js +18 -17
- package/dist/components/chat/entity-cards/github-activity-card.d.ts +1 -1
- package/dist/components/chat/entity-cards/use-entity-card-link.d.ts +3 -2
- package/dist/components/chat/entity-cards/use-entity-card-link.d.ts.map +1 -1
- package/dist/components/chat/entity-cards/use-entity-card-link.js +6 -4
- package/dist/components/chat/index.cjs +28 -21
- package/dist/components/chat/index.d.ts +2 -2
- package/dist/components/chat/index.d.ts.map +1 -1
- package/dist/components/chat/index.js +4 -3
- package/dist/components/chat/{inline-app-link-chip.d.ts → inline-chip.d.ts} +1 -14
- package/dist/components/chat/inline-chip.d.ts.map +1 -0
- package/dist/components/chat/inline-chip.js +27 -0
- package/dist/components/chat/nav-link-anchor-via-runtime.d.ts +45 -11
- package/dist/components/chat/nav-link-anchor-via-runtime.d.ts.map +1 -1
- package/dist/components/chat/nav-link-anchor-via-runtime.js +32 -24
- package/dist/components/chat/source-action-button.d.ts +12 -3
- package/dist/components/chat/source-action-button.d.ts.map +1 -1
- package/dist/components/chat/source-action-button.js +41 -26
- package/dist/components/chat/types/component.types.d.ts +1 -1
- package/dist/components/chat/types/message.types.d.ts +1 -1
- package/dist/components/chat/types/message.types.d.ts.map +1 -1
- package/dist/components/chat/utils/chat-nav-resolution.d.ts +1 -6
- package/dist/components/chat/utils/chat-nav-resolution.d.ts.map +1 -1
- package/dist/components/chat/utils/chat-nav-resolution.js +2 -3
- package/dist/components/chat/utils/decide-new-tab.d.ts +0 -3
- package/dist/components/chat/utils/decide-new-tab.d.ts.map +1 -1
- package/dist/components/chat/utils/decide-new-tab.js +0 -1
- package/dist/components/chat/utils/execute-navigation.d.ts +36 -34
- package/dist/components/chat/utils/execute-navigation.d.ts.map +1 -1
- package/dist/components/chat/utils/execute-navigation.js +23 -19
- package/dist/components/chat/utils/index.d.ts +5 -5
- package/dist/components/chat/utils/index.d.ts.map +1 -1
- package/dist/components/chat/utils/index.js +14 -6
- package/dist/components/chat/utils/nav-anchor-props.d.ts +35 -8
- package/dist/components/chat/utils/nav-anchor-props.d.ts.map +1 -1
- package/dist/components/chat/utils/nav-anchor-props.js +14 -5
- package/dist/components/chat/utils/new-tab-rel.d.ts +15 -0
- package/dist/components/chat/utils/new-tab-rel.d.ts.map +1 -0
- package/dist/components/chat/utils/new-tab-rel.js +25 -0
- package/dist/components/contact/index.cjs +12 -12
- package/dist/components/docs/index.cjs +15 -15
- package/dist/components/embeds/index.cjs +12 -12
- package/dist/components/faq/index.cjs +13 -13
- package/dist/components/features/devices/devices-table-columns.d.ts.map +1 -1
- package/dist/components/features/devices/devices-table-columns.js +4 -1
- package/dist/components/features/index.cjs +11 -11
- package/dist/components/help-center-pages/index.cjs +105 -105
- package/dist/components/index.cjs +91 -83
- package/dist/components/meeting-scheduler/index.cjs +50 -50
- package/dist/components/navigation/app-header.d.ts +1 -4
- package/dist/components/navigation/app-header.d.ts.map +1 -1
- package/dist/components/navigation/app-header.js +0 -2
- package/dist/components/navigation/index.cjs +14 -14
- package/dist/components/navigation/ticket-alerts-button.d.ts +1 -4
- package/dist/components/navigation/ticket-alerts-button.d.ts.map +1 -1
- package/dist/components/navigation/ticket-alerts-button.js +5 -5
- package/dist/components/onboarding-guides/index.cjs +14 -14
- package/dist/components/product-demo/index.cjs +20 -20
- package/dist/components/related-content/card-registry.d.ts +1 -1
- package/dist/components/related-content/index.cjs +7 -7
- package/dist/components/related-content/related-content-section.d.ts +3 -3
- package/dist/components/related-content/related-content-section.d.ts.map +1 -1
- package/dist/components/related-content/related-content-section.js +5 -3
- package/dist/components/shared/doc-search/resolve-search-result-action.d.ts +10 -3
- package/dist/components/shared/doc-search/resolve-search-result-action.d.ts.map +1 -1
- package/dist/components/shared/doc-search/resolve-search-result-action.js +8 -17
- package/dist/components/shared/doc-search/use-doc-search.d.ts.map +1 -1
- package/dist/components/shared/doc-search/use-doc-search.js +15 -27
- package/dist/components/shared/product-release/product-release-card.d.ts +2 -2
- package/dist/components/shared/product-release/product-releases-view.d.ts.map +1 -1
- package/dist/components/shared/product-release/product-releases-view.js +1 -3
- package/dist/components/tickets/index.cjs +18 -18
- package/dist/components/tickets/ticket-detail-drawer.d.ts.map +1 -1
- package/dist/components/tickets/ticket-detail-drawer.js +6 -3
- package/dist/components/tickets/types.d.ts +1 -1
- package/dist/components/ui/button/button.d.ts +1 -1
- package/dist/components/ui/hover-dropdown.d.ts +2 -2
- package/dist/components/ui/index.cjs +31 -23
- package/dist/components/ui/service-card.d.ts.map +1 -1
- package/dist/components/ui/service-card.js +4 -1
- package/dist/components/vendor-display-button.d.ts.map +1 -1
- package/dist/components/vendor-display-button.js +4 -1
- package/dist/contexts/chat-runtime-context.d.ts +11 -11
- package/dist/contexts/chat-runtime-context.d.ts.map +1 -1
- package/dist/{devices-DL4YU64N.cjs → devices-QBKWVHE6.cjs} +12 -12
- package/dist/{embeddable-chat-YRKMPFDY.cjs → embeddable-chat-WNPCPMDL.cjs} +96 -137
- package/dist/hooks/index.cjs +5 -5
- package/dist/hooks/use-contact-submission.d.ts.map +1 -1
- package/dist/hooks/use-contact-submission.js +11 -8
- package/dist/index.cjs +40 -34
- package/dist/{knowledge-VQW5JL2Z.cjs → knowledge-FSAYWM25.cjs} +12 -12
- package/dist/{logs-IY3WBLMW.cjs → logs-OZX4SYHG.cjs} +19 -19
- package/dist/{policies-IXWTWMJO.cjs → policies-LPCUCTLX.cjs} +15 -15
- package/dist/{scripts-D5CLO5EG.cjs → scripts-ZNFZSONW.cjs} +16 -16
- package/dist/{software-update-ULNP6CKJ.cjs → software-update-BRYOVQVY.cjs} +14 -14
- package/dist/utils/index.cjs +116 -89
- package/dist/utils/open-in-new-tab.d.ts +2 -1
- package/dist/utils/open-in-new-tab.d.ts.map +1 -1
- package/dist/utils/open-in-new-tab.js +2 -1
- package/dist/utils/scroll-into-view.d.ts +1 -1
- package/eslint-config/base.js +11 -0
- package/eslint-config/navigation.js +142 -0
- package/package.json +1 -1
- package/src/components/announcement-bar.tsx +8 -6
- package/src/components/chat/chat-markdown-link.tsx +42 -0
- package/src/components/chat/chat-message-enhanced.tsx +10 -36
- package/src/components/chat/embeddable-chat.tsx +63 -106
- package/src/components/chat/entity-cards/chat-card-disclosure.tsx +9 -13
- package/src/components/chat/entity-cards/dispatch.tsx +45 -35
- package/src/components/chat/entity-cards/github-activity-card.tsx +1 -1
- package/src/components/chat/entity-cards/use-entity-card-link.ts +11 -16
- package/src/components/chat/index.ts +3 -1
- package/src/components/chat/{inline-app-link-chip.tsx → inline-chip.tsx} +1 -27
- package/src/components/chat/nav-link-anchor-via-runtime.tsx +73 -33
- package/src/components/chat/source-action-button.tsx +57 -33
- package/src/components/chat/types/component.types.ts +1 -1
- package/src/components/chat/types/message.types.ts +1 -1
- package/src/components/chat/utils/chat-nav-resolution.ts +3 -8
- package/src/components/chat/utils/decide-new-tab.ts +0 -3
- package/src/components/chat/utils/execute-navigation.ts +58 -58
- package/src/components/chat/utils/index.ts +13 -6
- package/src/components/chat/utils/nav-anchor-props.ts +56 -9
- package/src/components/chat/utils/new-tab-rel.ts +39 -0
- package/src/components/features/devices/devices-table-columns.tsx +4 -1
- package/src/components/navigation/app-header.tsx +0 -5
- package/src/components/navigation/ticket-alerts-button.tsx +7 -8
- package/src/components/related-content/card-registry.tsx +1 -1
- package/src/components/related-content/related-content-section.tsx +10 -10
- package/src/components/shared/doc-search/resolve-search-result-action.ts +19 -33
- package/src/components/shared/doc-search/use-doc-search.ts +21 -44
- package/src/components/shared/product-release/product-release-card.tsx +4 -4
- package/src/components/shared/product-release/product-releases-view.tsx +2 -5
- package/src/components/tickets/ticket-detail-drawer.tsx +7 -4
- package/src/components/tickets/types.ts +1 -1
- package/src/components/ui/button/button.tsx +2 -2
- package/src/components/ui/hover-dropdown.tsx +2 -2
- package/src/components/ui/service-card.tsx +4 -1
- package/src/components/vendor-display-button.tsx +5 -2
- package/src/contexts/chat-runtime-context.tsx +15 -12
- package/src/hooks/use-contact-submission.ts +13 -8
- package/src/utils/index.ts +1 -1
- package/src/utils/open-in-new-tab.ts +4 -2
- package/src/utils/scroll-into-view.ts +1 -1
- package/dist/chunk-RD66AGUI.cjs +0 -156
- package/dist/components/chat/inline-app-link-chip.d.ts.map +0 -1
- package/dist/components/chat/inline-app-link-chip.js +0 -37
|
@@ -57,8 +57,7 @@ require('./chunk-24I6RFVU.cjs');
|
|
|
57
57
|
|
|
58
58
|
|
|
59
59
|
|
|
60
|
-
|
|
61
|
-
var _chunk7ERD34HQcjs = require('./chunk-7ERD34HQ.cjs');
|
|
60
|
+
var _chunk24M2JYM5cjs = require('./chunk-24M2JYM5.cjs');
|
|
62
61
|
|
|
63
62
|
|
|
64
63
|
var _chunkOBQ5WUNGcjs = require('./chunk-OBQ5WUNG.cjs');
|
|
@@ -1872,24 +1871,17 @@ require('./chunk-LMBYZITR.cjs');
|
|
|
1872
1871
|
require('./chunk-TMVC7S2R.cjs');
|
|
1873
1872
|
require('./chunk-IYHH5EIO.cjs');
|
|
1874
1873
|
require('./chunk-XIBCMGBW.cjs');
|
|
1875
|
-
require('./chunk-
|
|
1874
|
+
require('./chunk-A34UNP5V.cjs');
|
|
1876
1875
|
require('./chunk-QDDBOCG3.cjs');
|
|
1877
1876
|
require('./chunk-JKX2C3I2.cjs');
|
|
1878
1877
|
|
|
1879
1878
|
|
|
1880
|
-
var _chunk7DNL734Scjs = require('./chunk-7DNL734S.cjs');
|
|
1881
|
-
|
|
1882
|
-
|
|
1883
1879
|
var _chunkWWUSFOJ7cjs = require('./chunk-WWUSFOJ7.cjs');
|
|
1884
1880
|
require('./chunk-SKI6NKOE.cjs');
|
|
1881
|
+
require('./chunk-IM366HS6.cjs');
|
|
1885
1882
|
|
|
1886
1883
|
|
|
1887
|
-
var
|
|
1888
|
-
|
|
1889
|
-
|
|
1890
|
-
|
|
1891
|
-
|
|
1892
|
-
var _chunkY6MJMPHVcjs = require('./chunk-Y6MJMPHV.cjs');
|
|
1884
|
+
var _chunkUEULXVW2cjs = require('./chunk-UEULXVW2.cjs');
|
|
1893
1885
|
require('./chunk-QQT23JJ7.cjs');
|
|
1894
1886
|
require('./chunk-USUVHAQ7.cjs');
|
|
1895
1887
|
require('./chunk-25HBH4J6.cjs');
|
|
@@ -1903,7 +1895,7 @@ require('./chunk-4IYNDV3G.cjs');
|
|
|
1903
1895
|
require('./chunk-6VOOPMP5.cjs');
|
|
1904
1896
|
require('./chunk-ORO54HDF.cjs');
|
|
1905
1897
|
require('./chunk-RUHKTWGB.cjs');
|
|
1906
|
-
require('./chunk-
|
|
1898
|
+
require('./chunk-DVHSYPDB.cjs');
|
|
1907
1899
|
require('./chunk-FX35L4Y6.cjs');
|
|
1908
1900
|
require('./chunk-NTPX5GXI.cjs');
|
|
1909
1901
|
require('./chunk-MG3HJIGG.cjs');
|
|
@@ -1936,10 +1928,9 @@ var _chunkFCZAUK4Dcjs = require('./chunk-FCZAUK4D.cjs');
|
|
|
1936
1928
|
|
|
1937
1929
|
|
|
1938
1930
|
|
|
1939
|
-
var _chunk63A4GZMBcjs = require('./chunk-63A4GZMB.cjs');
|
|
1940
|
-
|
|
1941
1931
|
|
|
1942
|
-
var
|
|
1932
|
+
var _chunk63A4GZMBcjs = require('./chunk-63A4GZMB.cjs');
|
|
1933
|
+
require('./chunk-V45KLJQP.cjs');
|
|
1943
1934
|
require('./chunk-QDB2JO55.cjs');
|
|
1944
1935
|
|
|
1945
1936
|
// src/components/chat/embeddable-chat.tsx
|
|
@@ -2011,7 +2002,7 @@ function useChatDialogManager({
|
|
|
2011
2002
|
setArchivedLoading(true);
|
|
2012
2003
|
}
|
|
2013
2004
|
try {
|
|
2014
|
-
const result = await fetchArchivedDialogs({ cursor, limit:
|
|
2005
|
+
const result = await fetchArchivedDialogs({ cursor, limit: _chunk24M2JYM5cjs.CHAT_HISTORY_PAGE_SIZE });
|
|
2015
2006
|
if (!isCurrent()) return;
|
|
2016
2007
|
setArchivedCursor(result.nextCursor);
|
|
2017
2008
|
setArchivedDialogs((prev) => cursor ? [...prev, ...result.dialogs] : result.dialogs);
|
|
@@ -2138,7 +2129,7 @@ function splitCitedSources(sources, content) {
|
|
|
2138
2129
|
}
|
|
2139
2130
|
const cited = sources.filter((source) => firstMentionAt.has(source.index)).sort((a, b) => (_nullishCoalesce(firstMentionAt.get(a.index), () => ( 0))) - (_nullishCoalesce(firstMentionAt.get(b.index), () => ( 0))));
|
|
2140
2131
|
const uncited = sources.filter((source) => !firstMentionAt.has(source.index));
|
|
2141
|
-
return { cited:
|
|
2132
|
+
return { cited: _chunk24M2JYM5cjs.groupSourcesByTable.call(void 0, cited), uncited: _chunk24M2JYM5cjs.groupSourcesByTable.call(void 0, uncited) };
|
|
2142
2133
|
}
|
|
2143
2134
|
|
|
2144
2135
|
// src/components/chat/utils/host-message.ts
|
|
@@ -2189,7 +2180,7 @@ function pruneTimestampCache(timestampCache, liveIds) {
|
|
|
2189
2180
|
// src/components/chat/embeddable-chat.tsx
|
|
2190
2181
|
var _jsxruntime = require('react/jsx-runtime');
|
|
2191
2182
|
var HISTORY_RAIL_WIDTH = 320;
|
|
2192
|
-
var SPLIT_MIN_WIDTH = HISTORY_RAIL_WIDTH +
|
|
2183
|
+
var SPLIT_MIN_WIDTH = HISTORY_RAIL_WIDTH + _chunk24M2JYM5cjs.CHAT_BLOCK_MIN_WIDTH;
|
|
2193
2184
|
var DRAWER_DEFAULT_WIDTH_RATIO = 0.5;
|
|
2194
2185
|
var DRAWER_WIDTH_KEY = "mingo-chat-width-v4";
|
|
2195
2186
|
var DRAWER_DEFAULT_WIDTH_PX = 750;
|
|
@@ -2262,7 +2253,7 @@ function dispatchSlashCommandAction(actionId, cmdId, ref) {
|
|
|
2262
2253
|
if (!input) return;
|
|
2263
2254
|
switch (actionId) {
|
|
2264
2255
|
case "browse":
|
|
2265
|
-
input.submit(
|
|
2256
|
+
input.submit(_chunk24M2JYM5cjs.formatSingularLookupInvocation.call(void 0, cmdId));
|
|
2266
2257
|
return;
|
|
2267
2258
|
case "search":
|
|
2268
2259
|
input.setValue(`/${cmdId} `);
|
|
@@ -2280,26 +2271,21 @@ function dispatchSlashCommandAction(actionId, cmdId, ref) {
|
|
|
2280
2271
|
}
|
|
2281
2272
|
}
|
|
2282
2273
|
var ONE_TEXT_LINE = "\xA0";
|
|
2283
|
-
var SOURCE_CHIP_SKELETON_COUNT =
|
|
2284
|
-
function SourceChipSkeleton(
|
|
2285
|
-
return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "span", { "aria-hidden": true, className:
|
|
2286
|
-
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "span", { className:
|
|
2274
|
+
var SOURCE_CHIP_SKELETON_COUNT = 1;
|
|
2275
|
+
function SourceChipSkeleton(props) {
|
|
2276
|
+
return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "span", { "aria-hidden": true, className: "pointer-events-none inline-flex shrink-0 items-center", ..._chunk63A4GZMBcjs.loadingItemProps.call(void 0, props), children: [
|
|
2277
|
+
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "span", { className: _chunk24M2JYM5cjs.chatChipClass.call(void 0, { tone: "secondary" }), children: [
|
|
2287
2278
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: _chunk63A4GZMBcjs.cn.call(void 0, _chunk3TOWCFIKcjs.SKELETON_SURFACE_CLASS, "inline-block h-3.5 w-3.5 rounded-sm") }),
|
|
2288
2279
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: _chunk63A4GZMBcjs.cn.call(void 0, _chunk3TOWCFIKcjs.SKELETON_SURFACE_CLASS, "w-28 rounded-sm"), children: ONE_TEXT_LINE })
|
|
2289
2280
|
] }),
|
|
2290
2281
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: _chunk63A4GZMBcjs.cn.call(void 0, _chunk3TOWCFIKcjs.SKELETON_SURFACE_CLASS, "-mr-1 ml-1 inline-block h-5 w-5 rounded-sm") })
|
|
2291
2282
|
] });
|
|
2292
2283
|
}
|
|
2293
|
-
function SourceChip({
|
|
2294
|
-
src,
|
|
2295
|
-
|
|
2296
|
-
chipBasePlatform,
|
|
2297
|
-
onClose,
|
|
2298
|
-
onDiscuss
|
|
2299
|
-
}) {
|
|
2284
|
+
function SourceChip(props) {
|
|
2285
|
+
const { src, baseRoute, chipBasePlatform, onDiscuss } = props;
|
|
2286
|
+
const marks = _chunk63A4GZMBcjs.loadingItemProps.call(void 0, props);
|
|
2300
2287
|
const runtime = _chunkUJ7AXHRZcjs.useRequiredChatRuntime.call(void 0, );
|
|
2301
|
-
const
|
|
2302
|
-
const cta = _chunk7ERD34HQcjs.resolveSourceRowCTA.call(void 0,
|
|
2288
|
+
const cta = _chunk24M2JYM5cjs.resolveSourceRowCTA.call(void 0,
|
|
2303
2289
|
{
|
|
2304
2290
|
sourceRepo: src.sourceRepo,
|
|
2305
2291
|
documentType: src.documentType,
|
|
@@ -2309,15 +2295,14 @@ function SourceChip({
|
|
|
2309
2295
|
targetPlatform: _nullishCoalesce(src.targetPlatform, () => ( null)),
|
|
2310
2296
|
path: src.path
|
|
2311
2297
|
},
|
|
2312
|
-
|
|
2298
|
+
_chunk24M2JYM5cjs.sourceRowCtxFromRuntime.call(void 0, runtime, { baseRoute, chipBasePlatform })
|
|
2313
2299
|
);
|
|
2314
2300
|
const Icon = cta.icon;
|
|
2315
2301
|
const icon = /* @__PURE__ */ _jsxruntime.jsx.call(void 0, Icon, { className: "h-3.5 w-3.5" });
|
|
2316
|
-
const chipClass =
|
|
2317
|
-
const decideTab = (href, targetPlatform) => _chunkY6MJMPHVcjs.computeIsNewTab.call(void 0, runtime, href, targetPlatform);
|
|
2302
|
+
const chipClass = _chunk24M2JYM5cjs.chatChipClass.call(void 0, { tone: "secondary" });
|
|
2318
2303
|
if (src.items && src.items.length > 0) {
|
|
2319
2304
|
const dropdownItems = src.items.map((item) => {
|
|
2320
|
-
const itemCta =
|
|
2305
|
+
const itemCta = _chunk24M2JYM5cjs.resolveSourceRowCTA.call(void 0,
|
|
2321
2306
|
{
|
|
2322
2307
|
sourceRepo: src.sourceRepo,
|
|
2323
2308
|
documentType: item.documentType,
|
|
@@ -2327,7 +2312,7 @@ function SourceChip({
|
|
|
2327
2312
|
targetPlatform: _nullishCoalesce(item.targetPlatform, () => ( null)),
|
|
2328
2313
|
path: item.path
|
|
2329
2314
|
},
|
|
2330
|
-
|
|
2315
|
+
_chunk24M2JYM5cjs.sourceRowCtxFromRuntime.call(void 0, runtime, { baseRoute, chipBasePlatform })
|
|
2331
2316
|
);
|
|
2332
2317
|
const ItemIcon = itemCta.icon;
|
|
2333
2318
|
const itemChatRef = itemCta.chatRef;
|
|
@@ -2347,13 +2332,13 @@ function SourceChip({
|
|
|
2347
2332
|
};
|
|
2348
2333
|
});
|
|
2349
2334
|
const itemIndices = src.items.flatMap((item) => item.index === void 0 ? [] : [item.index]);
|
|
2350
|
-
const groupIndices = itemIndices.length > 0 ?
|
|
2351
|
-
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
2335
|
+
const groupIndices = itemIndices.length > 0 ? _chunk24M2JYM5cjs.formatCitationIndices.call(void 0, itemIndices) : `${src.index}`;
|
|
2336
|
+
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "inline-flex", ...marks, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
2352
2337
|
_chunkEHANO6UEcjs.HoverDropdown,
|
|
2353
2338
|
{
|
|
2354
2339
|
items: dropdownItems,
|
|
2355
2340
|
renderAnchor: ({ href, targetPlatform, path, className, children }) => /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
2356
|
-
|
|
2341
|
+
_chunk24M2JYM5cjs.NavLinkAnchorViaRuntime,
|
|
2357
2342
|
{
|
|
2358
2343
|
href,
|
|
2359
2344
|
targetPlatform: _nullishCoalesce(targetPlatform, () => ( null)),
|
|
@@ -2372,7 +2357,7 @@ function SourceChip({
|
|
|
2372
2357
|
] })
|
|
2373
2358
|
] })
|
|
2374
2359
|
}
|
|
2375
|
-
);
|
|
2360
|
+
) });
|
|
2376
2361
|
}
|
|
2377
2362
|
const displayName = src.name || formatRelativePath(src.path);
|
|
2378
2363
|
const chipBody = (label) => /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _jsxruntime.Fragment, { children: [
|
|
@@ -2384,50 +2369,22 @@ function SourceChip({
|
|
|
2384
2369
|
label
|
|
2385
2370
|
] })
|
|
2386
2371
|
] });
|
|
2387
|
-
const wrapChip = (clickable) => /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "span", { className: "inline-flex items-center", children: [
|
|
2372
|
+
const wrapChip = (clickable) => /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "span", { className: "inline-flex items-center", ...marks, children: [
|
|
2388
2373
|
clickable,
|
|
2389
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
2374
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk24M2JYM5cjs.SourceActionButton, { chatRef: cta.chatRef, onDiscuss, density: "inline", className: "-mr-1 ml-1" })
|
|
2390
2375
|
] });
|
|
2391
|
-
const buildClickHandler = (href, path, targetPlatform, isNewTab) => (e) => {
|
|
2392
|
-
const handled = _chunk7ERD34HQcjs.executeNavigation.call(void 0, {
|
|
2393
|
-
event: e,
|
|
2394
|
-
runtime,
|
|
2395
|
-
href,
|
|
2396
|
-
path,
|
|
2397
|
-
targetPlatform,
|
|
2398
|
-
fallbackNavigate: router.push
|
|
2399
|
-
});
|
|
2400
|
-
if (handled && !isNewTab && onClose) onClose();
|
|
2401
|
-
};
|
|
2402
|
-
if (cta.href && !!src.externalUrl) {
|
|
2403
|
-
const resolvedHref = _chunkGAR2IIU6cjs.resolveHrefForRuntime.call(void 0, cta.href, runtime);
|
|
2404
|
-
const isNewTab = decideTab(resolvedHref, _nullishCoalesce(cta.targetPlatform, () => ( null)));
|
|
2405
|
-
return wrapChip(
|
|
2406
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
2407
|
-
_chunkV45KLJQPcjs.next_link_default,
|
|
2408
|
-
{
|
|
2409
|
-
href: resolvedHref,
|
|
2410
|
-
..._chunkY6MJMPHVcjs.newTabAnchorAttrs.call(void 0, isNewTab),
|
|
2411
|
-
onClick: buildClickHandler(resolvedHref, null, _nullishCoalesce(cta.targetPlatform, () => ( null)), isNewTab),
|
|
2412
|
-
className: chipClass,
|
|
2413
|
-
children: chipBody(src.name)
|
|
2414
|
-
}
|
|
2415
|
-
)
|
|
2416
|
-
);
|
|
2417
|
-
}
|
|
2418
2376
|
if (cta.href) {
|
|
2419
|
-
const
|
|
2420
|
-
const isNewTab = decideTab(resolvedHref, _nullishCoalesce(cta.targetPlatform, () => ( null)));
|
|
2377
|
+
const isEntity = !!src.externalUrl;
|
|
2421
2378
|
return wrapChip(
|
|
2422
2379
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
2423
|
-
|
|
2380
|
+
_chunk24M2JYM5cjs.NavLinkAnchorViaRuntime,
|
|
2424
2381
|
{
|
|
2425
|
-
href:
|
|
2426
|
-
|
|
2427
|
-
|
|
2382
|
+
href: cta.href,
|
|
2383
|
+
path: isEntity ? null : src.path,
|
|
2384
|
+
targetPlatform: _nullishCoalesce(cta.targetPlatform, () => ( null)),
|
|
2428
2385
|
className: chipClass,
|
|
2429
|
-
title: displayName,
|
|
2430
|
-
children: chipBody(displayName)
|
|
2386
|
+
title: isEntity ? void 0 : displayName,
|
|
2387
|
+
children: chipBody(isEntity ? src.name : displayName)
|
|
2431
2388
|
}
|
|
2432
2389
|
)
|
|
2433
2390
|
);
|
|
@@ -2441,15 +2398,15 @@ function SourceChips({
|
|
|
2441
2398
|
uncited,
|
|
2442
2399
|
baseRoute,
|
|
2443
2400
|
chipBasePlatform,
|
|
2444
|
-
onClose,
|
|
2445
2401
|
onDiscuss,
|
|
2446
|
-
loading
|
|
2402
|
+
loading,
|
|
2403
|
+
skeletonCount
|
|
2447
2404
|
}) {
|
|
2448
2405
|
const [expanded, setExpanded] = _react.useState.call(void 0, false);
|
|
2449
2406
|
if (loading) {
|
|
2450
2407
|
return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { "aria-hidden": true, className: "mt-2 flex flex-col gap-1.5 border-t border-ods-border pt-2", children: [
|
|
2451
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "uppercase text-ods-text-muted text-h6", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
2452
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "flex flex-nowrap gap-1.5 overflow-hidden", children:
|
|
2408
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "uppercase text-ods-text-muted text-h6", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk24M2JYM5cjs.TextHold, { children: "Sources" }) }),
|
|
2409
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "flex flex-nowrap gap-1.5 overflow-hidden", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk63A4GZMBcjs.LoadingItems, { count: skeletonCount, children: () => /* @__PURE__ */ _jsxruntime.jsx.call(void 0, SourceChipSkeleton, { "data-loading-item": true }) }) })
|
|
2453
2410
|
] });
|
|
2454
2411
|
}
|
|
2455
2412
|
if (cited.length === 0) {
|
|
@@ -2460,10 +2417,10 @@ function SourceChips({
|
|
|
2460
2417
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "flex flex-wrap gap-1.5", children: fallback.map((src) => /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
2461
2418
|
SourceChip,
|
|
2462
2419
|
{
|
|
2420
|
+
"data-loading-item": true,
|
|
2463
2421
|
src,
|
|
2464
2422
|
baseRoute,
|
|
2465
2423
|
chipBasePlatform,
|
|
2466
|
-
onClose,
|
|
2467
2424
|
onDiscuss
|
|
2468
2425
|
},
|
|
2469
2426
|
src.index
|
|
@@ -2478,10 +2435,10 @@ function SourceChips({
|
|
|
2478
2435
|
cited.map((src) => /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
2479
2436
|
SourceChip,
|
|
2480
2437
|
{
|
|
2438
|
+
"data-loading-item": true,
|
|
2481
2439
|
src,
|
|
2482
2440
|
baseRoute,
|
|
2483
2441
|
chipBasePlatform,
|
|
2484
|
-
onClose,
|
|
2485
2442
|
onDiscuss
|
|
2486
2443
|
},
|
|
2487
2444
|
src.index
|
|
@@ -2489,10 +2446,10 @@ function SourceChips({
|
|
|
2489
2446
|
expanded && uncited.map((src) => /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
2490
2447
|
SourceChip,
|
|
2491
2448
|
{
|
|
2449
|
+
"data-loading-item": true,
|
|
2492
2450
|
src,
|
|
2493
2451
|
baseRoute,
|
|
2494
2452
|
chipBasePlatform,
|
|
2495
|
-
onClose,
|
|
2496
2453
|
onDiscuss
|
|
2497
2454
|
},
|
|
2498
2455
|
src.index
|
|
@@ -2522,6 +2479,7 @@ EmbeddableChat.displayName = "EmbeddableChat";
|
|
|
2522
2479
|
function EmbeddableChatInner({
|
|
2523
2480
|
baseRoute,
|
|
2524
2481
|
chipBasePlatform,
|
|
2482
|
+
sourceSkeletonCount = SOURCE_CHIP_SKELETON_COUNT,
|
|
2525
2483
|
enabledRagTableIds = null,
|
|
2526
2484
|
emptyStateGreeting = null,
|
|
2527
2485
|
suggestedQueries = null,
|
|
@@ -2572,7 +2530,7 @@ function EmbeddableChatInner({
|
|
|
2572
2530
|
const runtime = _chunkUJ7AXHRZcjs.useRequiredChatRuntime.call(void 0, );
|
|
2573
2531
|
const source = _nullishCoalesce(runtime.source, () => ( ""));
|
|
2574
2532
|
const commandsUrl = runtime.endpoints.commandsUrl;
|
|
2575
|
-
const { attachmentsEnabled, user: identityUser } =
|
|
2533
|
+
const { attachmentsEnabled, user: identityUser } = _chunk24M2JYM5cjs.useChatIdentity.call(void 0, );
|
|
2576
2534
|
const viewUrlPrefix = runtime.endpoints.attachmentViewUrlPrefix;
|
|
2577
2535
|
_react.useEffect.call(void 0, () => {
|
|
2578
2536
|
if (process.env.NODE_ENV !== "production") {
|
|
@@ -2626,9 +2584,9 @@ function EmbeddableChatInner({
|
|
|
2626
2584
|
const [quickActionPreview, setQuickActionPreview] = _react.useState.call(void 0, null);
|
|
2627
2585
|
const slashCommandsProp = _react.useMemo.call(void 0,
|
|
2628
2586
|
() => ({
|
|
2629
|
-
fetchCommands: (prefix, signal) =>
|
|
2587
|
+
fetchCommands: (prefix, signal) => _chunk24M2JYM5cjs.fetchSlashCommands.call(void 0, prefix, signal, commandsUrl),
|
|
2630
2588
|
resolveSourceIcon: (sourceId) => {
|
|
2631
|
-
const iconName =
|
|
2589
|
+
const iconName = _chunk24M2JYM5cjs.getSourceIconName.call(void 0, sourceId);
|
|
2632
2590
|
if (!iconName) return void 0;
|
|
2633
2591
|
return { Icon: _chunkQOAA7ZHBcjs.resolveIcon.call(void 0, iconName, { variant: "brand" }), label: sourceId };
|
|
2634
2592
|
},
|
|
@@ -2657,7 +2615,7 @@ function EmbeddableChatInner({
|
|
|
2657
2615
|
},
|
|
2658
2616
|
[controlledActiveMode, onActiveModeChange]
|
|
2659
2617
|
);
|
|
2660
|
-
const { commands: commandsList, loaded: commandsLoaded } =
|
|
2618
|
+
const { commands: commandsList, loaded: commandsLoaded } = _chunk24M2JYM5cjs.useSlashCommandRegistry.call(void 0, commandsUrl, {
|
|
2661
2619
|
enabled: activeMode === "guide"
|
|
2662
2620
|
});
|
|
2663
2621
|
const commandsById = _react.useMemo.call(void 0, () => {
|
|
@@ -2668,7 +2626,7 @@ function EmbeddableChatInner({
|
|
|
2668
2626
|
const resolveAgentConfigUrl = _nullishCoalesce(_nullishCoalesce(aiAgentConfigUrlProp, () => ( runtime.endpoints.aiAgentConfigUrl)), () => ( DEFAULT_AI_AGENT_CONFIG_URL));
|
|
2669
2627
|
const agentConfigUrl = activeAgentSlug ? resolveAgentConfigUrl(activeAgentSlug) : void 0;
|
|
2670
2628
|
const emptyStateUrl = _nullishCoalesce(agentConfigUrl, () => ( runtime.endpoints.emptyStateUrl));
|
|
2671
|
-
const { config: emptyStateConfig, loading: emptyStateLoading } =
|
|
2629
|
+
const { config: emptyStateConfig, loading: emptyStateLoading } = _chunk24M2JYM5cjs.useEmptyStateConfig.call(void 0, emptyStateUrl, {
|
|
2672
2630
|
enabled: activeMode === "guide" || !!activeAgentSlug
|
|
2673
2631
|
});
|
|
2674
2632
|
const effectiveGreeting = _nullishCoalesce(emptyStateConfig.greeting, () => ( emptyStateGreeting));
|
|
@@ -2715,7 +2673,7 @@ function EmbeddableChatInner({
|
|
|
2715
2673
|
hasMoreMessages,
|
|
2716
2674
|
loadMoreMessages,
|
|
2717
2675
|
dialogCapabilities
|
|
2718
|
-
} =
|
|
2676
|
+
} = _chunk24M2JYM5cjs.useUnifiedChat.call(void 0, {
|
|
2719
2677
|
modes: effectiveModes,
|
|
2720
2678
|
activeMode,
|
|
2721
2679
|
mingoStateOverride: mingoState,
|
|
@@ -2762,8 +2720,8 @@ function EmbeddableChatInner({
|
|
|
2762
2720
|
addFiles: addAttachmentFiles,
|
|
2763
2721
|
removeAttachment,
|
|
2764
2722
|
clear: clearAttachments
|
|
2765
|
-
} =
|
|
2766
|
-
const { panelRef: galleryPanelRef, modal: galleryModal } =
|
|
2723
|
+
} = _chunk24M2JYM5cjs.useChatAttachments.call(void 0, );
|
|
2724
|
+
const { panelRef: galleryPanelRef, modal: galleryModal } = _chunk24M2JYM5cjs.useChatAttachmentImageGallery.call(void 0, );
|
|
2767
2725
|
const contextMaxItems = _nullishCoalesce(_optionalChain([contextPicker, 'optionalAccess', _16 => _16.maxItems]), () => ( 10));
|
|
2768
2726
|
const contextPickerForMode = activeMode === "mingo" ? contextPicker : void 0;
|
|
2769
2727
|
const [contextItems, setContextItems] = _react.useState.call(void 0, NO_CONTEXT_ITEMS);
|
|
@@ -2883,7 +2841,7 @@ function EmbeddableChatInner({
|
|
|
2883
2841
|
const askAboutRef = _react.useRef.call(void 0, discussRef);
|
|
2884
2842
|
const askAbout = _react.useCallback.call(void 0, (reference) => askAboutRef.current(reference), []);
|
|
2885
2843
|
const renderEntityCard = _react.useCallback.call(void 0,
|
|
2886
|
-
(reference) =>
|
|
2844
|
+
(reference) => _chunk24M2JYM5cjs.renderChatInlineEntityCard.call(void 0, reference, {
|
|
2887
2845
|
onDiscuss: askAbout,
|
|
2888
2846
|
onDisplay: displayRef,
|
|
2889
2847
|
baseRoute: resolvedBaseRoute,
|
|
@@ -2893,7 +2851,7 @@ function EmbeddableChatInner({
|
|
|
2893
2851
|
[askAbout, displayRef, resolvedBaseRoute, chipBasePlatform, extras]
|
|
2894
2852
|
);
|
|
2895
2853
|
const mingoAssistantIcon = _react.useMemo.call(void 0,
|
|
2896
|
-
() => effectiveAssistantIcon ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
2854
|
+
() => effectiveAssistantIcon ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkUEULXVW2cjs.EntityIcon, { icon: effectiveAssistantIcon, size: 24 }) : /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkOBQ5WUNGcjs.AgentMark, { agent: "mingo", className: "h-6 w-6" }),
|
|
2897
2855
|
[effectiveAssistantIcon]
|
|
2898
2856
|
);
|
|
2899
2857
|
const [timestampCache] = _react.useState.call(void 0, () => /* @__PURE__ */ new Map());
|
|
@@ -2905,7 +2863,7 @@ function EmbeddableChatInner({
|
|
|
2905
2863
|
pruneTimestampCache(timestampCache, new Set(rawMessages.map((m) => m.id)));
|
|
2906
2864
|
return mapped;
|
|
2907
2865
|
}, [rawMessages, guideUserName, guideUserAvatar, timestampCache]);
|
|
2908
|
-
const whatToAsk =
|
|
2866
|
+
const whatToAsk = _chunk24M2JYM5cjs.useWhatToAsk.call(void 0, {
|
|
2909
2867
|
dialogId: activeDialogId,
|
|
2910
2868
|
content: typeof whatToAskContent === "function" ? void 0 : whatToAskContent,
|
|
2911
2869
|
user: {
|
|
@@ -2924,7 +2882,7 @@ function EmbeddableChatInner({
|
|
|
2924
2882
|
noteWhatToAskSend();
|
|
2925
2883
|
let augmentedText = text;
|
|
2926
2884
|
if (readyAttachments.length > 0) {
|
|
2927
|
-
const markdown = readyAttachments.map((att) =>
|
|
2885
|
+
const markdown = readyAttachments.map((att) => _chunk24M2JYM5cjs.formatChatAttachmentMarkdownForBubble.call(void 0, att, viewUrlPrefix)).join("");
|
|
2928
2886
|
augmentedText = `${text}${markdown}`;
|
|
2929
2887
|
}
|
|
2930
2888
|
void sendMessage(augmentedText, {
|
|
@@ -2963,7 +2921,7 @@ function EmbeddableChatInner({
|
|
|
2963
2921
|
// agent/persona (`icon_props.color`) wins; the built-in slug map
|
|
2964
2922
|
// (fae→pink, mingo→cyan) is only the fallback for unconfigured
|
|
2965
2923
|
// built-in agents.
|
|
2966
|
-
accent: _nullishCoalesce(
|
|
2924
|
+
accent: _nullishCoalesce(_chunk24M2JYM5cjs.accentFromIdentityIcon.call(void 0, effectiveAssistantIcon), () => ( _chunk24M2JYM5cjs.getAgentAccent.call(void 0, activeAgentSlug)))
|
|
2967
2925
|
}));
|
|
2968
2926
|
}
|
|
2969
2927
|
return (_nullishCoalesce(effectiveSuggestedQueries, () => ( []))).map((q, i) => ({
|
|
@@ -3011,7 +2969,7 @@ function EmbeddableChatInner({
|
|
|
3011
2969
|
unarchiveDialog: mingoCaps.unarchiveDialog
|
|
3012
2970
|
});
|
|
3013
2971
|
const handleOpen = _react.useCallback.call(void 0, () => setIsOpen(true), [setIsOpen]);
|
|
3014
|
-
|
|
2972
|
+
_chunk24M2JYM5cjs.useCloseOnNavigation.call(void 0, handleNavigationClose, null);
|
|
3015
2973
|
_react.useEffect.call(void 0, () => {
|
|
3016
2974
|
const handler = (e) => {
|
|
3017
2975
|
const detail = e.detail;
|
|
@@ -3019,8 +2977,8 @@ function EmbeddableChatInner({
|
|
|
3019
2977
|
setIsOpen(true);
|
|
3020
2978
|
setTimeout(() => askAbout(detail.ref), 0);
|
|
3021
2979
|
};
|
|
3022
|
-
window.addEventListener(
|
|
3023
|
-
return () => window.removeEventListener(
|
|
2980
|
+
window.addEventListener(_chunk24M2JYM5cjs.ASK_AI_OPEN_WITH_REF_EVENT, handler);
|
|
2981
|
+
return () => window.removeEventListener(_chunk24M2JYM5cjs.ASK_AI_OPEN_WITH_REF_EVENT, handler);
|
|
3024
2982
|
}, [source, askAbout, setIsOpen]);
|
|
3025
2983
|
const pendingAskRef = _react.useRef.call(void 0, null);
|
|
3026
2984
|
const isDraft = activeDialogId == null && messages.length === 0;
|
|
@@ -3054,10 +3012,10 @@ function EmbeddableChatInner({
|
|
|
3054
3012
|
const prompt = typeof detail.prompt === "string" ? detail.prompt.trim() : "";
|
|
3055
3013
|
if (prompt) setTimeout(() => sendAskPrompt(prompt), 0);
|
|
3056
3014
|
};
|
|
3057
|
-
window.addEventListener(
|
|
3058
|
-
return () => window.removeEventListener(
|
|
3015
|
+
window.addEventListener(_chunk24M2JYM5cjs.ASK_AI_OPEN_EVENT, handler);
|
|
3016
|
+
return () => window.removeEventListener(_chunk24M2JYM5cjs.ASK_AI_OPEN_EVENT, handler);
|
|
3059
3017
|
}, [source, setIsOpen, sendAskPrompt]);
|
|
3060
|
-
_react.useEffect.call(void 0, () =>
|
|
3018
|
+
_react.useEffect.call(void 0, () => _chunk24M2JYM5cjs.chatListensForAskAiOpens.call(void 0, ), []);
|
|
3061
3019
|
const hasMessages = messages.length > 0;
|
|
3062
3020
|
const dialogsInitialLoading = isDialogsLoading && dialogs.length === 0;
|
|
3063
3021
|
const dialogsLoadError = dialogsError && dialogs.length === 0;
|
|
@@ -3094,19 +3052,20 @@ function EmbeddableChatInner({
|
|
|
3094
3052
|
(message, index) => {
|
|
3095
3053
|
if (message.role !== "assistant") return null;
|
|
3096
3054
|
if (chatLoading && index === messages.length - 1) {
|
|
3055
|
+
if (sourceSkeletonCount <= 0) return null;
|
|
3097
3056
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "pb-2", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
3098
3057
|
SourceChips,
|
|
3099
3058
|
{
|
|
3100
3059
|
loading: true,
|
|
3060
|
+
skeletonCount: sourceSkeletonCount,
|
|
3101
3061
|
cited: [],
|
|
3102
3062
|
uncited: [],
|
|
3103
3063
|
baseRoute: resolvedBaseRoute,
|
|
3104
|
-
chipBasePlatform
|
|
3105
|
-
onClose: handleNavigationClose
|
|
3064
|
+
chipBasePlatform
|
|
3106
3065
|
}
|
|
3107
3066
|
) });
|
|
3108
3067
|
}
|
|
3109
|
-
const { cited, uncited } = splitCitedSources(message.sources,
|
|
3068
|
+
const { cited, uncited } = splitCitedSources(message.sources, _chunk24M2JYM5cjs.flattenAssistantContent.call(void 0, message.content));
|
|
3110
3069
|
if (cited.length === 0 && uncited.length === 0) return null;
|
|
3111
3070
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "pb-2", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
3112
3071
|
SourceChips,
|
|
@@ -3115,16 +3074,16 @@ function EmbeddableChatInner({
|
|
|
3115
3074
|
uncited,
|
|
3116
3075
|
baseRoute: resolvedBaseRoute,
|
|
3117
3076
|
chipBasePlatform,
|
|
3118
|
-
|
|
3119
|
-
|
|
3077
|
+
onDiscuss: askAbout,
|
|
3078
|
+
skeletonCount: sourceSkeletonCount
|
|
3120
3079
|
}
|
|
3121
3080
|
) });
|
|
3122
3081
|
},
|
|
3123
|
-
[chatLoading, messages.length, resolvedBaseRoute, chipBasePlatform,
|
|
3082
|
+
[chatLoading, messages.length, resolvedBaseRoute, chipBasePlatform, askAbout, sourceSkeletonCount]
|
|
3124
3083
|
);
|
|
3125
3084
|
const [portalHost, setPortalHost] = _react.useState.call(void 0, null);
|
|
3126
3085
|
const [panelBoundary, setPanelBoundary] = _react.useState.call(void 0, null);
|
|
3127
|
-
const splitMinWidth = (isV2 ?
|
|
3086
|
+
const splitMinWidth = (isV2 ? _chunk24M2JYM5cjs.MINGO_V2_RAIL_WIDTH : HISTORY_RAIL_WIDTH) + _chunk24M2JYM5cjs.CHAT_BLOCK_MIN_WIDTH;
|
|
3128
3087
|
const [canSplit, setCanSplit] = _react.useState.call(void 0, false);
|
|
3129
3088
|
_react.useEffect.call(void 0, () => {
|
|
3130
3089
|
if (!panelBoundary || typeof ResizeObserver === "undefined") return void 0;
|
|
@@ -3143,7 +3102,7 @@ function EmbeddableChatInner({
|
|
|
3143
3102
|
[splitMinWidth]
|
|
3144
3103
|
);
|
|
3145
3104
|
const [railCollapsed, setRailCollapsed] = _react.useState.call(void 0, false);
|
|
3146
|
-
const railStorageHydrated =
|
|
3105
|
+
const railStorageHydrated = _chunk24M2JYM5cjs.useIsHydrated.call(void 0, );
|
|
3147
3106
|
const [railStorageRead, setRailStorageRead] = _react.useState.call(void 0, false);
|
|
3148
3107
|
if (railStorageHydrated && !railStorageRead) {
|
|
3149
3108
|
setRailStorageRead(true);
|
|
@@ -3197,7 +3156,7 @@ function EmbeddableChatInner({
|
|
|
3197
3156
|
resetToNewChat();
|
|
3198
3157
|
}, [clearWhatToAskDraft, resetToNewChat]);
|
|
3199
3158
|
const activeDialogStatus = activeDialog && dialogStatusOf ? dialogStatusOf(activeDialog) : void 0;
|
|
3200
|
-
const isChatBlocked = !!composerLock || chatLoading || activeDialogStatus === "working" || activeDialogStatus === "approval" || (_nullishCoalesce(_optionalChain([pendingApprovals, 'optionalAccess', _65 => _65.length]), () => ( 0))) > 0 ||
|
|
3159
|
+
const isChatBlocked = !!composerLock || chatLoading || activeDialogStatus === "working" || activeDialogStatus === "approval" || (_nullishCoalesce(_optionalChain([pendingApprovals, 'optionalAccess', _65 => _65.length]), () => ( 0))) > 0 || _chunk24M2JYM5cjs.awaitsDecision.call(void 0, hostMessages);
|
|
3201
3160
|
const showWhatToAsk = (content) => {
|
|
3202
3161
|
whatToAsk.clearDraft();
|
|
3203
3162
|
resetToNewChat();
|
|
@@ -3293,7 +3252,7 @@ function EmbeddableChatInner({
|
|
|
3293
3252
|
}),
|
|
3294
3253
|
[resetToNewChat, contextMaxItems]
|
|
3295
3254
|
);
|
|
3296
|
-
const splitHeaderMenuItems =
|
|
3255
|
+
const splitHeaderMenuItems = _chunk24M2JYM5cjs.chatDialogMenuItems.call(void 0, {
|
|
3297
3256
|
onCopyLink: headerOnCopyLink,
|
|
3298
3257
|
onRename: headerOnRename,
|
|
3299
3258
|
onCompact: headerOnCompact,
|
|
@@ -3373,7 +3332,7 @@ function EmbeddableChatInner({
|
|
|
3373
3332
|
onRetry: reloadDialogs
|
|
3374
3333
|
};
|
|
3375
3334
|
const v2Header = isV2 && !stackedListView ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "col-start-2 row-start-1 min-w-0", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
3376
|
-
|
|
3335
|
+
_chunk24M2JYM5cjs.MingoChatHeader,
|
|
3377
3336
|
{
|
|
3378
3337
|
title: archiveOpen ? "Chat Archive" : headerShowBack || isGuideEmpty ? headerTitle : freshConversationTitle,
|
|
3379
3338
|
subtitle: archiveOpen ? void 0 : headerPersonName,
|
|
@@ -3393,7 +3352,7 @@ function EmbeddableChatInner({
|
|
|
3393
3352
|
const body = (
|
|
3394
3353
|
// The whole panel reads the appearance (the composer's footer too), not
|
|
3395
3354
|
// only the thread `ChatMessageList` provides it to.
|
|
3396
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
3355
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk24M2JYM5cjs.ChatAppearanceContext.Provider, { value: appearance, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkS3QXLD4Xcjs.PortalContainerContext.Provider, { value: portalHost, children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkS3QXLD4Xcjs.CollisionBoundaryContext.Provider, { value: panelBoundary, children: [
|
|
3397
3356
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
3398
3357
|
"div",
|
|
3399
3358
|
{
|
|
@@ -3401,7 +3360,7 @@ function EmbeddableChatInner({
|
|
|
3401
3360
|
"data-surface": isV2 ? "mingo" : void 0,
|
|
3402
3361
|
className: `flex h-full flex-col overflow-hidden transition-colors duration-200 ${!isV2 && (archiveOpen && !splitActive || stackedListView) ? "bg-ods-card" : "bg-ods-bg"} ${previewMode ? "pointer-events-none select-none" : ""}`,
|
|
3403
3362
|
children: archiveOpen && !splitActive ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "flex min-h-0 flex-1 flex-col duration-200 animate-in fade-in-0", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
3404
|
-
|
|
3363
|
+
_chunk24M2JYM5cjs.ChatArchivePage,
|
|
3405
3364
|
{
|
|
3406
3365
|
dialogs: archivedDialogs,
|
|
3407
3366
|
onSelectDialog: handleArchivedSelect,
|
|
@@ -3431,7 +3390,7 @@ function EmbeddableChatInner({
|
|
|
3431
3390
|
narrow: true,
|
|
3432
3391
|
className: "col-start-1 row-span-3 row-start-1",
|
|
3433
3392
|
innerClassName: "flex min-h-0 flex-col",
|
|
3434
|
-
children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
3393
|
+
children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk24M2JYM5cjs.MingoChatRail, { ...mingoRailProps, className: "w-full border-r-0" })
|
|
3435
3394
|
}
|
|
3436
3395
|
),
|
|
3437
3396
|
isV2 ? v2Header : showWideHeader ? (
|
|
@@ -3470,7 +3429,7 @@ function EmbeddableChatInner({
|
|
|
3470
3429
|
// (Figma 116:51217) and the magnifier toggle is hidden.
|
|
3471
3430
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _jsxruntime.Fragment, { children: [
|
|
3472
3431
|
railSearchOpen && mingoCaps.onSearchChange ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
3473
|
-
|
|
3432
|
+
_chunk24M2JYM5cjs.ChatHeaderSearchField,
|
|
3474
3433
|
{
|
|
3475
3434
|
initialValue: mingoCaps.searchQuery,
|
|
3476
3435
|
onSearchChange: mingoCaps.onSearchChange,
|
|
@@ -3557,10 +3516,10 @@ function EmbeddableChatInner({
|
|
|
3557
3516
|
// guide, resolved into `narrowHeaderProps` above. (Wide layouts,
|
|
3558
3517
|
// including rail-collapsed, use the wide header above.) Embedded
|
|
3559
3518
|
// previews (hero demo tabs) force the compact bar via `compact`.
|
|
3560
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
3519
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk24M2JYM5cjs.ChatPanelHeader, { ...narrowHeaderProps, compact: previewMode })
|
|
3561
3520
|
),
|
|
3562
3521
|
activeMode === "guide" && hasMingoMode && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
3563
|
-
|
|
3522
|
+
_chunk24M2JYM5cjs.GuideModeBanner,
|
|
3564
3523
|
{
|
|
3565
3524
|
className: _chunk63A4GZMBcjs.cn.call(void 0, "duration-200 animate-in fade-in-0", isV2 && "col-start-2 row-start-2")
|
|
3566
3525
|
}
|
|
@@ -3570,7 +3529,7 @@ function EmbeddableChatInner({
|
|
|
3570
3529
|
// Archive list inside the rail (header lives in the split
|
|
3571
3530
|
// header's left cell above). Right chat block stays put.
|
|
3572
3531
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
3573
|
-
|
|
3532
|
+
_chunk24M2JYM5cjs.ChatArchivePage,
|
|
3574
3533
|
{
|
|
3575
3534
|
embedded: true,
|
|
3576
3535
|
dialogs: archivedDialogs,
|
|
@@ -3584,7 +3543,7 @@ function EmbeddableChatInner({
|
|
|
3584
3543
|
}
|
|
3585
3544
|
)
|
|
3586
3545
|
) : /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
3587
|
-
|
|
3546
|
+
_chunk24M2JYM5cjs.MingoHistoryRail,
|
|
3588
3547
|
{
|
|
3589
3548
|
dialogs,
|
|
3590
3549
|
activeDialogId: _nullishCoalesce(activeDialogId, () => ( void 0)),
|
|
@@ -3612,7 +3571,7 @@ function EmbeddableChatInner({
|
|
|
3612
3571
|
// v2: the archive opens in the chat column under the chat's
|
|
3613
3572
|
// header; the list stays, and "Chat Archive" there toggles back.
|
|
3614
3573
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
3615
|
-
|
|
3574
|
+
_chunk24M2JYM5cjs.MingoArchiveList,
|
|
3616
3575
|
{
|
|
3617
3576
|
dialogs: archivedDialogs,
|
|
3618
3577
|
onSelectDialog: handleArchivedSelect,
|
|
@@ -3625,7 +3584,7 @@ function EmbeddableChatInner({
|
|
|
3625
3584
|
}
|
|
3626
3585
|
)
|
|
3627
3586
|
) : stackedListView && isV2 ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
3628
|
-
|
|
3587
|
+
_chunk24M2JYM5cjs.MingoChatRail,
|
|
3629
3588
|
{
|
|
3630
3589
|
...mingoRailProps,
|
|
3631
3590
|
onNewChat: () => setComposeOpen(true),
|
|
@@ -3644,7 +3603,7 @@ function EmbeddableChatInner({
|
|
|
3644
3603
|
// single-column view. No composer here; "Start New Chat" opens
|
|
3645
3604
|
// the compose view.
|
|
3646
3605
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
3647
|
-
|
|
3606
|
+
_chunk24M2JYM5cjs.MingoHistoryRail,
|
|
3648
3607
|
{
|
|
3649
3608
|
className: "duration-200 animate-in fade-in-0",
|
|
3650
3609
|
dialogs,
|
|
@@ -3687,14 +3646,14 @@ function EmbeddableChatInner({
|
|
|
3687
3646
|
{
|
|
3688
3647
|
className: "flex min-h-0 flex-1 flex-col duration-200 animate-in fade-in-0",
|
|
3689
3648
|
children: hasConversation ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "flex min-h-0 flex-1 flex-col", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
3690
|
-
|
|
3649
|
+
_chunk24M2JYM5cjs.ChatMessageList,
|
|
3691
3650
|
{
|
|
3692
3651
|
messages,
|
|
3693
3652
|
isLoading: messagesInitialLoading,
|
|
3694
3653
|
fill: previewMode,
|
|
3695
3654
|
appearance,
|
|
3696
3655
|
isTyping: chatLoading,
|
|
3697
|
-
typingMessage: streamingProgress ?
|
|
3656
|
+
typingMessage: streamingProgress ? _chunk24M2JYM5cjs.chatProgressLabel.call(void 0, streamingProgress) : void 0,
|
|
3698
3657
|
pendingApprovals,
|
|
3699
3658
|
autoScroll: !previewMode,
|
|
3700
3659
|
pinBottom: previewMode,
|
|
@@ -3707,7 +3666,7 @@ function EmbeddableChatInner({
|
|
|
3707
3666
|
renderMention,
|
|
3708
3667
|
renderAfterMessage: renderMessageSources,
|
|
3709
3668
|
onAskSelect: chatLoading || previewMode ? void 0 : handleAskSelect,
|
|
3710
|
-
NavLinkAnchor:
|
|
3669
|
+
NavLinkAnchor: _chunk24M2JYM5cjs.NavLinkAnchorViaRuntime,
|
|
3711
3670
|
className: previewMode ? "pointer-events-auto flex-1" : "flex-1 [scrollbar-width:none] [&::-webkit-scrollbar]:hidden",
|
|
3712
3671
|
contentClassName: "max-w-none pb-0",
|
|
3713
3672
|
fullWidth: true,
|
|
@@ -3721,7 +3680,7 @@ function EmbeddableChatInner({
|
|
|
3721
3680
|
quick-action chips. Guide mode keeps the slash-command
|
|
3722
3681
|
onboarding list below. */
|
|
3723
3682
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
3724
|
-
|
|
3683
|
+
_chunk24M2JYM5cjs.MingoWelcome,
|
|
3725
3684
|
{
|
|
3726
3685
|
onStartGuideChat: effectiveModes.guide ? () => handleActiveModeChange("guide") : void 0,
|
|
3727
3686
|
historyPageSize,
|
|
@@ -3737,7 +3696,7 @@ function EmbeddableChatInner({
|
|
|
3737
3696
|
+ slash-command onboarding list share one scroll region,
|
|
3738
3697
|
with a pinned quick-action chip row above the composer. */
|
|
3739
3698
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
3740
|
-
|
|
3699
|
+
_chunk24M2JYM5cjs.GuideWelcome,
|
|
3741
3700
|
{
|
|
3742
3701
|
subtitle: _nullishCoalesce(effectiveGreeting, () => ( void 0)),
|
|
3743
3702
|
subtitleLoading: emptyStateLoading,
|
|
@@ -3794,7 +3753,7 @@ function EmbeddableChatInner({
|
|
|
3794
3753
|
}
|
|
3795
3754
|
),
|
|
3796
3755
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
3797
|
-
|
|
3756
|
+
_chunk24M2JYM5cjs.ChatAttachmentChipStrip,
|
|
3798
3757
|
{
|
|
3799
3758
|
attachments: stagedAttachments,
|
|
3800
3759
|
onRemove: removeAttachment,
|
|
@@ -3802,7 +3761,7 @@ function EmbeddableChatInner({
|
|
|
3802
3761
|
}
|
|
3803
3762
|
),
|
|
3804
3763
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
3805
|
-
|
|
3764
|
+
_chunk24M2JYM5cjs.ChatComposer,
|
|
3806
3765
|
{
|
|
3807
3766
|
archived: isViewingArchived,
|
|
3808
3767
|
lock: composerLock,
|
|
@@ -3854,7 +3813,7 @@ function EmbeddableChatInner({
|
|
|
3854
3813
|
),
|
|
3855
3814
|
galleryModal,
|
|
3856
3815
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
3857
|
-
|
|
3816
|
+
_chunk24M2JYM5cjs.ChatDialogModals,
|
|
3858
3817
|
{
|
|
3859
3818
|
renameTarget,
|
|
3860
3819
|
setRenameTarget,
|
|
@@ -3870,13 +3829,13 @@ function EmbeddableChatInner({
|
|
|
3870
3829
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { ref: setPortalHost, style: { display: "contents" } })
|
|
3871
3830
|
] }) }) })
|
|
3872
3831
|
);
|
|
3873
|
-
const panel = shellLess ? /* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
|
|
3832
|
+
const panel = shellLess ? /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk24M2JYM5cjs.ChatPanelContext.Provider, { value: chatPanelHandle, children: [
|
|
3874
3833
|
shell === "none" && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _reactvisuallyhidden.VisuallyHidden, { children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, DialogPrimitive.Title, { children: [
|
|
3875
3834
|
sourceLabel,
|
|
3876
3835
|
" AI Assistant"
|
|
3877
3836
|
] }) }),
|
|
3878
3837
|
body
|
|
3879
|
-
] }) : /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkEHANO6UEcjs.Drawer, { open: isOpen, onOpenChange: (o) => !o && handleClose(), children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
3838
|
+
] }) : /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkEHANO6UEcjs.Drawer, { open: isOpen, onOpenChange: (o) => !o && handleClose(), children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk24M2JYM5cjs.ChatPanelContext.Provider, { value: chatPanelHandle, children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
|
|
3880
3839
|
_chunkEHANO6UEcjs.DrawerContent,
|
|
3881
3840
|
{
|
|
3882
3841
|
side: "right",
|