@burtson-labs/bandit-engine 2.0.85 → 2.0.86
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-ASHS5XCL.mjs → chat-QMGKUFBI.mjs} +4 -4
- package/dist/{chunk-OHDMP7FI.mjs → chunk-7SQLHCBV.mjs} +2 -2
- package/dist/{chunk-XHPSNERM.mjs → chunk-AJSGL2XJ.mjs} +2 -2
- package/dist/{chunk-GNTQR7L6.mjs → chunk-C2L6ZSWR.mjs} +3 -3
- package/dist/{chunk-GNTQR7L6.mjs.map → chunk-C2L6ZSWR.mjs.map} +1 -1
- package/dist/{chunk-B2HUBOJ6.mjs → chunk-FIZVBEAY.mjs} +76 -18
- package/dist/{chunk-B2HUBOJ6.mjs.map → chunk-FIZVBEAY.mjs.map} +1 -1
- package/dist/{chunk-R64BOUIU.mjs → chunk-OICDRDQZ.mjs} +5 -5
- package/dist/index.js +76 -16
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +5 -5
- package/dist/management/management.js +76 -16
- package/dist/management/management.js.map +1 -1
- package/dist/management/management.mjs +4 -4
- package/dist/modals/chat-modal/chat-modal.js +2 -2
- 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/{chat-ASHS5XCL.mjs.map → chat-QMGKUFBI.mjs.map} +0 -0
- /package/dist/{chunk-OHDMP7FI.mjs.map → chunk-7SQLHCBV.mjs.map} +0 -0
- /package/dist/{chunk-XHPSNERM.mjs.map → chunk-AJSGL2XJ.mjs.map} +0 -0
- /package/dist/{chunk-R64BOUIU.mjs.map → chunk-OICDRDQZ.mjs.map} +0 -0
|
@@ -3,7 +3,7 @@ import {
|
|
|
3
3
|
} from "./chunk-ONQMRE2G.mjs";
|
|
4
4
|
import {
|
|
5
5
|
StreamingMarkdown_default
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-7SQLHCBV.mjs";
|
|
7
7
|
import {
|
|
8
8
|
useMCPToolsStore
|
|
9
9
|
} from "./chunk-WQLKBI3Y.mjs";
|
|
@@ -43,7 +43,7 @@ import {
|
|
|
43
43
|
useNotificationService,
|
|
44
44
|
useTTS,
|
|
45
45
|
useVoiceStore
|
|
46
|
-
} from "./chunk-
|
|
46
|
+
} from "./chunk-C2L6ZSWR.mjs";
|
|
47
47
|
import {
|
|
48
48
|
authenticationService,
|
|
49
49
|
brandingService_default,
|
|
@@ -6744,7 +6744,7 @@ import {
|
|
|
6744
6744
|
Avatar as Avatar7,
|
|
6745
6745
|
Chip as Chip4
|
|
6746
6746
|
} from "@mui/material";
|
|
6747
|
-
import { X as CloseIcon5, X as ClearIcon2, Search as SearchIcon2, Folder as FolderIcon5, MoreVertical as MoreVertIcon4, Trash2 as DeleteSweepIcon2, Inbox as InboxIcon4, Plus as AddIcon5 } from "lucide-react";
|
|
6747
|
+
import { X as CloseIcon5, X as ClearIcon2, Search as SearchIcon2, Folder as FolderIcon5, MoreVertical as MoreVertIcon4, Trash2 as DeleteSweepIcon2, Inbox as InboxIcon4, Plus as AddIcon5, Settings as SettingsIcon3, Brain as MemoryIcon2 } from "lucide-react";
|
|
6748
6748
|
import { useTheme as useTheme11, alpha as alpha7 } from "@mui/material/styles";
|
|
6749
6749
|
import { Fragment as Fragment7, jsx as jsx14, jsxs as jsxs11 } from "react/jsx-runtime";
|
|
6750
6750
|
var BANDIT_AVATAR2 = "https://cdn.burtson.ai/images/bandit-head.png";
|
|
@@ -6798,6 +6798,7 @@ var EnhancedMobileConversationsModal = ({
|
|
|
6798
6798
|
deleteProject
|
|
6799
6799
|
} = useProjectStore();
|
|
6800
6800
|
const [projectManagementOpen, setProjectManagementOpen] = useState13(false);
|
|
6801
|
+
const [memoryModalOpen, setMemoryModalOpen] = useState13(false);
|
|
6801
6802
|
const [collapsedProjects, setCollapsedProjects] = useState13(/* @__PURE__ */ new Set());
|
|
6802
6803
|
const didInitCollapseRef = useRef9(false);
|
|
6803
6804
|
const [searchQuery, setSearchQuery] = useState13("");
|
|
@@ -6842,21 +6843,49 @@ var EnhancedMobileConversationsModal = ({
|
|
|
6842
6843
|
return void 0;
|
|
6843
6844
|
}, [user, userDisplayName]);
|
|
6844
6845
|
useEffect11(() => {
|
|
6845
|
-
|
|
6846
|
+
if (!open) return;
|
|
6847
|
+
const fresh = readPersistedToken();
|
|
6848
|
+
const authStore = useAuthenticationStore.getState();
|
|
6849
|
+
if (fresh && fresh !== authStore.token) authStore.setToken(fresh);
|
|
6850
|
+
let active2 = true;
|
|
6851
|
+
let objectUrl = null;
|
|
6852
|
+
const resolveAvatar = async () => {
|
|
6853
|
+
try {
|
|
6854
|
+
const avatarId = getCustomClaim("avatarUrl");
|
|
6855
|
+
const fileStorageApiUrl = usePackageSettingsStore.getState().settings?.fileStorageApiUrl;
|
|
6856
|
+
const token = useAuthenticationStore.getState().token;
|
|
6857
|
+
if (avatarId && fileStorageApiUrl && token) {
|
|
6858
|
+
const base = fileStorageApiUrl.replace(/\/$/, "");
|
|
6859
|
+
const res = await fetch(`${base}/app-asset/download/${encodeURIComponent(avatarId)}`, {
|
|
6860
|
+
headers: { Authorization: `Bearer ${token}` }
|
|
6861
|
+
});
|
|
6862
|
+
if (res.ok) {
|
|
6863
|
+
const blob = await res.blob();
|
|
6864
|
+
if (active2) {
|
|
6865
|
+
objectUrl = URL.createObjectURL(blob);
|
|
6866
|
+
setAvatarImage(objectUrl);
|
|
6867
|
+
}
|
|
6868
|
+
return;
|
|
6869
|
+
}
|
|
6870
|
+
}
|
|
6871
|
+
} catch {
|
|
6872
|
+
}
|
|
6846
6873
|
try {
|
|
6847
6874
|
const branding = await brandingService_default.getBranding();
|
|
6848
|
-
setAvatarImage(branding?.logoBase64 || BANDIT_AVATAR2);
|
|
6875
|
+
if (active2) setAvatarImage(branding?.logoBase64 || BANDIT_AVATAR2);
|
|
6849
6876
|
} catch (error) {
|
|
6850
6877
|
debugLogger.error("Failed to load branding avatar", {
|
|
6851
6878
|
error: error instanceof Error ? error.message : String(error)
|
|
6852
6879
|
});
|
|
6853
|
-
setAvatarImage(BANDIT_AVATAR2);
|
|
6880
|
+
if (active2) setAvatarImage(BANDIT_AVATAR2);
|
|
6854
6881
|
}
|
|
6855
6882
|
};
|
|
6856
|
-
|
|
6857
|
-
|
|
6858
|
-
|
|
6859
|
-
|
|
6883
|
+
resolveAvatar();
|
|
6884
|
+
return () => {
|
|
6885
|
+
active2 = false;
|
|
6886
|
+
if (objectUrl) URL.revokeObjectURL(objectUrl);
|
|
6887
|
+
};
|
|
6888
|
+
}, [open, getCustomClaim]);
|
|
6860
6889
|
const avatarLabel = userDisplayName || user?.email || "Bandit";
|
|
6861
6890
|
const avatarInitials = useMemo3(() => deriveInitials2(avatarLabel), [avatarLabel]);
|
|
6862
6891
|
const buildSnippet = (text, query, idx) => {
|
|
@@ -7100,6 +7129,15 @@ var EnhancedMobileConversationsModal = ({
|
|
|
7100
7129
|
}
|
|
7101
7130
|
}
|
|
7102
7131
|
),
|
|
7132
|
+
/* @__PURE__ */ jsx14(
|
|
7133
|
+
IconButton8,
|
|
7134
|
+
{
|
|
7135
|
+
onClick: () => setMemoryModalOpen(true),
|
|
7136
|
+
"aria-label": "Memory",
|
|
7137
|
+
sx: { color: theme.palette.text.secondary },
|
|
7138
|
+
children: /* @__PURE__ */ jsx14(MemoryIcon2, {})
|
|
7139
|
+
}
|
|
7140
|
+
),
|
|
7103
7141
|
/* @__PURE__ */ jsx14(
|
|
7104
7142
|
IconButton8,
|
|
7105
7143
|
{
|
|
@@ -7509,6 +7547,9 @@ var EnhancedMobileConversationsModal = ({
|
|
|
7509
7547
|
/* @__PURE__ */ jsxs11(
|
|
7510
7548
|
Box11,
|
|
7511
7549
|
{
|
|
7550
|
+
onClick: user ? () => {
|
|
7551
|
+
window.location.href = "/profile";
|
|
7552
|
+
} : void 0,
|
|
7512
7553
|
sx: {
|
|
7513
7554
|
mt: "auto",
|
|
7514
7555
|
px: 2,
|
|
@@ -7516,10 +7557,9 @@ var EnhancedMobileConversationsModal = ({
|
|
|
7516
7557
|
borderTop: `1px solid ${alpha7(theme.palette.divider, 0.6)}`,
|
|
7517
7558
|
display: "flex",
|
|
7518
7559
|
alignItems: "center",
|
|
7519
|
-
justifyContent: "center",
|
|
7520
7560
|
gap: 1.25,
|
|
7521
7561
|
bgcolor: alpha7(theme.palette.background.default, 0.88),
|
|
7522
|
-
|
|
7562
|
+
cursor: user ? "pointer" : "default"
|
|
7523
7563
|
},
|
|
7524
7564
|
children: [
|
|
7525
7565
|
/* @__PURE__ */ jsx14(
|
|
@@ -7537,7 +7577,7 @@ var EnhancedMobileConversationsModal = ({
|
|
|
7537
7577
|
children: avatarInitials
|
|
7538
7578
|
}
|
|
7539
7579
|
),
|
|
7540
|
-
/* @__PURE__ */ jsxs11(Box11, { sx: { display: "flex", flexDirection: "column",
|
|
7580
|
+
/* @__PURE__ */ jsxs11(Box11, { sx: { display: "flex", flexDirection: "column", flex: 1, minWidth: 0, gap: 0.25 }, children: [
|
|
7541
7581
|
/* @__PURE__ */ jsx14(
|
|
7542
7582
|
Typography8,
|
|
7543
7583
|
{
|
|
@@ -7547,16 +7587,33 @@ var EnhancedMobileConversationsModal = ({
|
|
|
7547
7587
|
children: user ? userDisplayName : "Not signed in"
|
|
7548
7588
|
}
|
|
7549
7589
|
),
|
|
7550
|
-
|
|
7590
|
+
/* @__PURE__ */ jsx14(
|
|
7551
7591
|
Typography8,
|
|
7552
7592
|
{
|
|
7553
7593
|
variant: "caption",
|
|
7554
|
-
sx: { color: theme.palette.text.secondary },
|
|
7555
7594
|
noWrap: true,
|
|
7556
|
-
|
|
7595
|
+
sx: { color: theme.palette.text.secondary },
|
|
7596
|
+
children: user ? "View profile & settings" : "Connect your account to sync chats"
|
|
7557
7597
|
}
|
|
7558
7598
|
)
|
|
7559
|
-
] })
|
|
7599
|
+
] }),
|
|
7600
|
+
user && /* @__PURE__ */ jsx14(
|
|
7601
|
+
Box11,
|
|
7602
|
+
{
|
|
7603
|
+
sx: {
|
|
7604
|
+
flexShrink: 0,
|
|
7605
|
+
display: "flex",
|
|
7606
|
+
alignItems: "center",
|
|
7607
|
+
justifyContent: "center",
|
|
7608
|
+
width: 30,
|
|
7609
|
+
height: 30,
|
|
7610
|
+
borderRadius: "50%",
|
|
7611
|
+
border: `1px solid ${alpha7(theme.palette.divider, 0.8)}`,
|
|
7612
|
+
color: theme.palette.text.secondary
|
|
7613
|
+
},
|
|
7614
|
+
children: /* @__PURE__ */ jsx14(SettingsIcon3, { size: 16 })
|
|
7615
|
+
}
|
|
7616
|
+
)
|
|
7560
7617
|
]
|
|
7561
7618
|
}
|
|
7562
7619
|
)
|
|
@@ -7572,6 +7629,7 @@ var EnhancedMobileConversationsModal = ({
|
|
|
7572
7629
|
onClose: () => setProjectManagementOpen(false)
|
|
7573
7630
|
}
|
|
7574
7631
|
),
|
|
7632
|
+
/* @__PURE__ */ jsx14(memory_modal_default, { open: memoryModalOpen, onClose: () => setMemoryModalOpen(false) }),
|
|
7575
7633
|
conversationToMove && /* @__PURE__ */ jsx14(
|
|
7576
7634
|
move_conversation_modal_default,
|
|
7577
7635
|
{
|
|
@@ -10321,4 +10379,4 @@ var chat_default = Chat;
|
|
|
10321
10379
|
export {
|
|
10322
10380
|
chat_default
|
|
10323
10381
|
};
|
|
10324
|
-
//# sourceMappingURL=chunk-
|
|
10382
|
+
//# sourceMappingURL=chunk-FIZVBEAY.mjs.map
|