@burtson-labs/bandit-engine 2.0.149 → 2.0.150
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/{chat-Z4SQGSMN.mjs → chat-YOT2RPWD.mjs} +4 -4
- package/dist/{chunk-P5IJLX6I.mjs → chunk-7P7IS6UA.mjs} +4 -2
- package/dist/chunk-7P7IS6UA.mjs.map +1 -0
- package/dist/{chunk-F735W34E.mjs → chunk-FFVGZK5D.mjs} +36 -1
- package/dist/chunk-FFVGZK5D.mjs.map +1 -0
- package/dist/{chunk-JQSZNGII.mjs → chunk-IJTDHBHP.mjs} +5 -5
- package/dist/{chunk-K6IV4LYZ.mjs → chunk-L37EUHMZ.mjs} +2 -2
- package/dist/{chunk-ANX33XAO.mjs → chunk-YEPJ7DWZ.mjs} +3 -3
- package/dist/index.js +44 -0
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +5 -5
- package/dist/management/management.js +44 -0
- package/dist/management/management.js.map +1 -1
- package/dist/management/management.mjs +4 -4
- package/dist/modals/chat-modal/chat-modal.js +35 -0
- package/dist/modals/chat-modal/chat-modal.js.map +1 -1
- package/dist/modals/chat-modal/chat-modal.mjs +2 -2
- package/package.json +1 -1
- package/dist/chunk-F735W34E.mjs.map +0 -1
- package/dist/chunk-P5IJLX6I.mjs.map +0 -1
- /package/dist/{chat-Z4SQGSMN.mjs.map → chat-YOT2RPWD.mjs.map} +0 -0
- /package/dist/{chunk-JQSZNGII.mjs.map → chunk-IJTDHBHP.mjs.map} +0 -0
- /package/dist/{chunk-K6IV4LYZ.mjs.map → chunk-L37EUHMZ.mjs.map} +0 -0
- /package/dist/{chunk-ANX33XAO.mjs.map → chunk-YEPJ7DWZ.mjs.map} +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
2
|
StreamingMarkdown_default
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-7P7IS6UA.mjs";
|
|
4
4
|
import {
|
|
5
5
|
aiProviderInitService
|
|
6
6
|
} from "./chunk-F7JXIW6T.mjs";
|
|
@@ -14,7 +14,7 @@ import {
|
|
|
14
14
|
} from "./chunk-K2JGFKEB.mjs";
|
|
15
15
|
import {
|
|
16
16
|
chat_modal_default
|
|
17
|
-
} from "./chunk-
|
|
17
|
+
} from "./chunk-L37EUHMZ.mjs";
|
|
18
18
|
import {
|
|
19
19
|
AddIcon,
|
|
20
20
|
ArchiveIcon,
|
|
@@ -83,7 +83,7 @@ import {
|
|
|
83
83
|
predefinedThemes,
|
|
84
84
|
useNotificationService,
|
|
85
85
|
useVoiceStore
|
|
86
|
-
} from "./chunk-
|
|
86
|
+
} from "./chunk-FFVGZK5D.mjs";
|
|
87
87
|
import {
|
|
88
88
|
TOPICS,
|
|
89
89
|
brandingService_default,
|
|
@@ -9811,7 +9811,7 @@ var MCPToolsTabV2_default = MCPToolsTabV2;
|
|
|
9811
9811
|
|
|
9812
9812
|
// src/management/management.tsx
|
|
9813
9813
|
import { jsx as jsx14, jsxs as jsxs14 } from "react/jsx-runtime";
|
|
9814
|
-
var preloadChatPage = () => import("./chat-
|
|
9814
|
+
var preloadChatPage = () => import("./chat-YOT2RPWD.mjs");
|
|
9815
9815
|
var buildCapabilitiesUrl = (gatewayApiUrl) => {
|
|
9816
9816
|
const trimmed = gatewayApiUrl.replace(/\/$/, "");
|
|
9817
9817
|
if (trimmed.endsWith("/api")) {
|
|
@@ -11184,4 +11184,4 @@ export {
|
|
|
11184
11184
|
useGatewayMemory,
|
|
11185
11185
|
management_default
|
|
11186
11186
|
};
|
|
11187
|
-
//# sourceMappingURL=chunk-
|
|
11187
|
+
//# sourceMappingURL=chunk-IJTDHBHP.mjs.map
|
|
@@ -24,7 +24,7 @@ import {
|
|
|
24
24
|
useNotificationService,
|
|
25
25
|
useTTS,
|
|
26
26
|
useVoiceStore
|
|
27
|
-
} from "./chunk-
|
|
27
|
+
} from "./chunk-FFVGZK5D.mjs";
|
|
28
28
|
import {
|
|
29
29
|
brandingService_default,
|
|
30
30
|
toTitleCase,
|
|
@@ -2941,4 +2941,4 @@ export {
|
|
|
2941
2941
|
MAX_WINDOWED_HEIGHT,
|
|
2942
2942
|
chat_modal_default
|
|
2943
2943
|
};
|
|
2944
|
-
//# sourceMappingURL=chunk-
|
|
2944
|
+
//# sourceMappingURL=chunk-L37EUHMZ.mjs.map
|
|
@@ -3,7 +3,7 @@ import {
|
|
|
3
3
|
} from "./chunk-ONQMRE2G.mjs";
|
|
4
4
|
import {
|
|
5
5
|
StreamingMarkdown_default
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-7P7IS6UA.mjs";
|
|
7
7
|
import {
|
|
8
8
|
useMCPToolsStore
|
|
9
9
|
} from "./chunk-K2JGFKEB.mjs";
|
|
@@ -36,7 +36,7 @@ import {
|
|
|
36
36
|
useNotificationService,
|
|
37
37
|
useTTS,
|
|
38
38
|
useVoiceStore
|
|
39
|
-
} from "./chunk-
|
|
39
|
+
} from "./chunk-FFVGZK5D.mjs";
|
|
40
40
|
import {
|
|
41
41
|
brandingService_default,
|
|
42
42
|
detectMessageMood,
|
|
@@ -11544,4 +11544,4 @@ var chat_default = Chat;
|
|
|
11544
11544
|
export {
|
|
11545
11545
|
chat_default
|
|
11546
11546
|
};
|
|
11547
|
-
//# sourceMappingURL=chunk-
|
|
11547
|
+
//# sourceMappingURL=chunk-YEPJ7DWZ.mjs.map
|
package/dist/index.js
CHANGED
|
@@ -11424,6 +11424,46 @@ var init_lucide_icons = __esm({
|
|
|
11424
11424
|
}
|
|
11425
11425
|
});
|
|
11426
11426
|
|
|
11427
|
+
// src/utils/openFileLink.ts
|
|
11428
|
+
var FILE_EXT_RE, isStandalonePwa, isFileLink, maybeHandleFileLinkClick;
|
|
11429
|
+
var init_openFileLink = __esm({
|
|
11430
|
+
"src/utils/openFileLink.ts"() {
|
|
11431
|
+
"use strict";
|
|
11432
|
+
init_debugLogger();
|
|
11433
|
+
FILE_EXT_RE = /\.(docx|pptx|xlsx|csv|json|md|txt|html|xml|ya?ml|pdf|zip)(?:[?#]|$)/i;
|
|
11434
|
+
isStandalonePwa = () => typeof window !== "undefined" && (window.matchMedia?.("(display-mode: standalone)").matches || window.navigator.standalone === true);
|
|
11435
|
+
isFileLink = (href) => Boolean(href && FILE_EXT_RE.test(href));
|
|
11436
|
+
maybeHandleFileLinkClick = (event, href) => {
|
|
11437
|
+
if (!href || !isStandalonePwa() || !isFileLink(href)) return;
|
|
11438
|
+
event.preventDefault();
|
|
11439
|
+
void (async () => {
|
|
11440
|
+
try {
|
|
11441
|
+
const res = await fetch(href);
|
|
11442
|
+
if (!res.ok) throw new Error(`fetch ${res.status}`);
|
|
11443
|
+
const blob = await res.blob();
|
|
11444
|
+
const rawName = new URL(href, window.location.href).pathname.split("/").pop() || "download";
|
|
11445
|
+
const name = decodeURIComponent(rawName);
|
|
11446
|
+
const file = new File([blob], name, {
|
|
11447
|
+
type: blob.type || "application/octet-stream"
|
|
11448
|
+
});
|
|
11449
|
+
const nav = navigator;
|
|
11450
|
+
if (nav.canShare?.({ files: [file] }) && nav.share) {
|
|
11451
|
+
await nav.share({ files: [file], title: name });
|
|
11452
|
+
return;
|
|
11453
|
+
}
|
|
11454
|
+
window.location.href = URL.createObjectURL(blob);
|
|
11455
|
+
} catch (error) {
|
|
11456
|
+
debugLogger.warn("openFileLink: share flow failed, falling back", {
|
|
11457
|
+
error: error instanceof Error ? error.message : String(error)
|
|
11458
|
+
});
|
|
11459
|
+
if (error?.name === "AbortError") return;
|
|
11460
|
+
window.open(href, "_blank", "noopener");
|
|
11461
|
+
}
|
|
11462
|
+
})();
|
|
11463
|
+
};
|
|
11464
|
+
}
|
|
11465
|
+
});
|
|
11466
|
+
|
|
11427
11467
|
// src/components/StreamingMarkdown.tsx
|
|
11428
11468
|
var import_react10, import_material4, import_react_markdown, import_remark_gfm, import_rehype_raw, import_rehype_sanitize2, import_styles2, import_jsx_runtime6, StreamingMarkdown, arePropsEqual, StreamingMarkdown_default;
|
|
11429
11469
|
var init_StreamingMarkdown = __esm({
|
|
@@ -11439,6 +11479,7 @@ var init_StreamingMarkdown = __esm({
|
|
|
11439
11479
|
init_lowlight();
|
|
11440
11480
|
init_markdownRendering();
|
|
11441
11481
|
init_lucide_icons();
|
|
11482
|
+
init_openFileLink();
|
|
11442
11483
|
import_jsx_runtime6 = require("react/jsx-runtime");
|
|
11443
11484
|
StreamingMarkdown = ({
|
|
11444
11485
|
content,
|
|
@@ -11592,6 +11633,7 @@ ${listMarkdown}`;
|
|
|
11592
11633
|
href,
|
|
11593
11634
|
target: "_blank",
|
|
11594
11635
|
rel: "noopener noreferrer",
|
|
11636
|
+
onClick: (e) => maybeHandleFileLinkClick(e, href),
|
|
11595
11637
|
style: {
|
|
11596
11638
|
color: theme.palette.info?.main ?? theme.palette.primary.main,
|
|
11597
11639
|
textDecoration: "underline",
|
|
@@ -14509,6 +14551,7 @@ var init_ai_response_text_field = __esm({
|
|
|
14509
14551
|
init_lowlight();
|
|
14510
14552
|
init_markdownRendering();
|
|
14511
14553
|
init_lucide_icons();
|
|
14554
|
+
init_openFileLink();
|
|
14512
14555
|
init_ai_response_action_bar();
|
|
14513
14556
|
import_jsx_runtime13 = require("react/jsx-runtime");
|
|
14514
14557
|
brainIcon = "https://cdn.burtson.ai/images/brain-icon.png";
|
|
@@ -14941,6 +14984,7 @@ ${sourcesMarkdownList.join("\n")}`;
|
|
|
14941
14984
|
},
|
|
14942
14985
|
target: "_blank",
|
|
14943
14986
|
rel: "noopener noreferrer",
|
|
14987
|
+
onClick: (e) => maybeHandleFileLinkClick(e, href),
|
|
14944
14988
|
children
|
|
14945
14989
|
}
|
|
14946
14990
|
);
|