@axiom-lattice/react-sdk 2.1.18 → 2.1.20
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/index.d.mts +1 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.js +138 -47
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +210 -119
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -972,8 +972,8 @@ var useStyle = createStyles(({ token, css }) => {
|
|
|
972
972
|
font-family: ${token.fontFamily}, sans-serif;
|
|
973
973
|
position: relative;
|
|
974
974
|
overflow: hidden;
|
|
975
|
-
padding:
|
|
976
|
-
gap:
|
|
975
|
+
padding: 8px;
|
|
976
|
+
gap: 8px;
|
|
977
977
|
|
|
978
978
|
.ant-prompts {
|
|
979
979
|
color: ${token.colorText};
|
|
@@ -994,14 +994,14 @@ var useStyle = createStyles(({ token, css }) => {
|
|
|
994
994
|
&.open {
|
|
995
995
|
background: transparent;
|
|
996
996
|
box-shadow: none;
|
|
997
|
-
margin-left: -
|
|
997
|
+
margin-left: -8px;
|
|
998
998
|
height: 100%;
|
|
999
999
|
}
|
|
1000
1000
|
|
|
1001
1001
|
&.collapsed {
|
|
1002
|
-
width:
|
|
1002
|
+
width: 8px;
|
|
1003
1003
|
height: 100%;
|
|
1004
|
-
margin-right: -
|
|
1004
|
+
margin-right: -8px;
|
|
1005
1005
|
.ant-conversations {
|
|
1006
1006
|
width: 64px;
|
|
1007
1007
|
}
|
|
@@ -1291,7 +1291,7 @@ import { useState as useState9 } from "react";
|
|
|
1291
1291
|
|
|
1292
1292
|
// src/components/GenUI/MDResponse.tsx
|
|
1293
1293
|
import XMarkdown from "@ant-design/x-markdown";
|
|
1294
|
-
import { useRef as useRef5, useState as useState8 } from "react";
|
|
1294
|
+
import { useRef as useRef5, useState as useState8, useMemo as useMemo2 } from "react";
|
|
1295
1295
|
import { createStyles as createStyles2 } from "antd-style";
|
|
1296
1296
|
|
|
1297
1297
|
// src/components/GenUI/Code.tsx
|
|
@@ -1521,6 +1521,7 @@ var mdComponents = {
|
|
|
1521
1521
|
|
|
1522
1522
|
// src/components/GenUI/MDResponse.tsx
|
|
1523
1523
|
import { jsx as jsx9 } from "react/jsx-runtime";
|
|
1524
|
+
var memoizedMdComponents = mdComponents;
|
|
1524
1525
|
var useStyles = createStyles2(({ token, css }) => ({
|
|
1525
1526
|
markdownTableContainer: css`
|
|
1526
1527
|
overflow-x: auto;
|
|
@@ -1610,10 +1611,11 @@ var MDResponse = ({
|
|
|
1610
1611
|
noGenUI
|
|
1611
1612
|
}) => {
|
|
1612
1613
|
const { styles } = useStyles();
|
|
1614
|
+
const stableComponents = useMemo2(() => memoizedMdComponents, []);
|
|
1613
1615
|
return /* @__PURE__ */ jsx9("div", { className: styles.markdownContainer, children: /* @__PURE__ */ jsx9(
|
|
1614
1616
|
XMarkdown,
|
|
1615
1617
|
{
|
|
1616
|
-
components:
|
|
1618
|
+
components: stableComponents,
|
|
1617
1619
|
content,
|
|
1618
1620
|
paragraphTag: "div"
|
|
1619
1621
|
}
|
|
@@ -2228,7 +2230,7 @@ var WriteTodos = ({
|
|
|
2228
2230
|
};
|
|
2229
2231
|
|
|
2230
2232
|
// src/components/GenUI/FileExplorer.tsx
|
|
2231
|
-
import { useState as useState11, useEffect as useEffect6, useMemo as
|
|
2233
|
+
import { useState as useState11, useEffect as useEffect6, useMemo as useMemo3 } from "react";
|
|
2232
2234
|
import { Splitter, Tree, Empty, Button as Button4, Tooltip, message } from "antd";
|
|
2233
2235
|
import {
|
|
2234
2236
|
FolderOutlined,
|
|
@@ -2500,7 +2502,7 @@ var FileExplorer = ({
|
|
|
2500
2502
|
setSelectedKey(list[0].name);
|
|
2501
2503
|
}
|
|
2502
2504
|
}, [files]);
|
|
2503
|
-
const treeData =
|
|
2505
|
+
const treeData = useMemo3(
|
|
2504
2506
|
() => buildTreeData(fileList, expandedKeys),
|
|
2505
2507
|
[fileList, expandedKeys]
|
|
2506
2508
|
);
|
|
@@ -2521,7 +2523,7 @@ var FileExplorer = ({
|
|
|
2521
2523
|
setExpandedKeys(getAllKeys(treeData));
|
|
2522
2524
|
}
|
|
2523
2525
|
}, [treeData.length]);
|
|
2524
|
-
const selectedFile =
|
|
2526
|
+
const selectedFile = useMemo3(() => {
|
|
2525
2527
|
return fileList.find((f) => f.name === selectedKey);
|
|
2526
2528
|
}, [fileList, selectedKey]);
|
|
2527
2529
|
const handleCopy = () => {
|
|
@@ -3464,7 +3466,7 @@ import {
|
|
|
3464
3466
|
memo,
|
|
3465
3467
|
useCallback as useCallback7,
|
|
3466
3468
|
useEffect as useEffect9,
|
|
3467
|
-
useMemo as
|
|
3469
|
+
useMemo as useMemo4,
|
|
3468
3470
|
useRef as useRef7,
|
|
3469
3471
|
useState as useState15
|
|
3470
3472
|
} from "react";
|
|
@@ -3552,7 +3554,7 @@ ${JSON.stringify(tool_call)}
|
|
|
3552
3554
|
const content_md = [content, ...tool_calls_md].join("\n");
|
|
3553
3555
|
return /* @__PURE__ */ jsx25(Space10, { direction: "vertical", style: { width: "100%" }, children: /* @__PURE__ */ jsx25(MDResponse, { content: content_md }) });
|
|
3554
3556
|
}, []);
|
|
3555
|
-
const items =
|
|
3557
|
+
const items = useMemo4(
|
|
3556
3558
|
() => messages.map((message5, index) => ({
|
|
3557
3559
|
key: message5.id,
|
|
3558
3560
|
role: message5.role,
|
|
@@ -3636,7 +3638,7 @@ import {
|
|
|
3636
3638
|
Button as Button11,
|
|
3637
3639
|
message as message3
|
|
3638
3640
|
} from "antd";
|
|
3639
|
-
import
|
|
3641
|
+
import React7, { useEffect as useEffect10, useRef as useRef8, useState as useState16 } from "react";
|
|
3640
3642
|
|
|
3641
3643
|
// src/components/GenUI/HITLContainer.tsx
|
|
3642
3644
|
import {
|
|
@@ -3783,12 +3785,12 @@ var FileExplorerButton = ({}) => {
|
|
|
3783
3785
|
|
|
3784
3786
|
// src/components/Chat/AgentHeader.tsx
|
|
3785
3787
|
import { Welcome } from "@ant-design/x";
|
|
3786
|
-
import { useMemo as
|
|
3788
|
+
import { useMemo as useMemo5 } from "react";
|
|
3787
3789
|
import { jsx as jsx29, jsxs as jsxs16 } from "react/jsx-runtime";
|
|
3788
3790
|
var { Text: Text10 } = Typography12;
|
|
3789
3791
|
var AgentHeader = (props) => {
|
|
3790
3792
|
const { description, avatar, name, extra, extraMeta } = props;
|
|
3791
|
-
const extraMetaComponents =
|
|
3793
|
+
const extraMetaComponents = useMemo5(() => {
|
|
3792
3794
|
if (extraMeta && extraMeta.length > 0) {
|
|
3793
3795
|
return extraMeta.map((meta) => {
|
|
3794
3796
|
const Element = getElement(meta.id)?.card_view;
|
|
@@ -3817,7 +3819,17 @@ var AgentHeader = (props) => {
|
|
|
3817
3819
|
style: { padding: 8 },
|
|
3818
3820
|
variant: "borderless",
|
|
3819
3821
|
description: description ? /* @__PURE__ */ jsx29(Text10, { ellipsis: { tooltip: description }, children: description }) : void 0,
|
|
3820
|
-
icon:
|
|
3822
|
+
icon: /* @__PURE__ */ jsx29(
|
|
3823
|
+
"div",
|
|
3824
|
+
{
|
|
3825
|
+
style: {
|
|
3826
|
+
display: "flex",
|
|
3827
|
+
alignItems: "center",
|
|
3828
|
+
justifyContent: "center"
|
|
3829
|
+
},
|
|
3830
|
+
children: avatar ? /* @__PURE__ */ jsx29(Avatar2, { src: avatar, size: 48 }) : /* @__PURE__ */ jsx29(Avatar2, { size: 48, children: name?.charAt(0).toUpperCase() })
|
|
3831
|
+
}
|
|
3832
|
+
),
|
|
3821
3833
|
title: name ? name : void 0,
|
|
3822
3834
|
extra: /* @__PURE__ */ jsxs16(Space12, { children: [
|
|
3823
3835
|
extra,
|
|
@@ -3860,7 +3872,7 @@ var Chating = ({
|
|
|
3860
3872
|
const { styles } = useStyle();
|
|
3861
3873
|
const [headerOpen, setHeaderOpen] = useState16(false);
|
|
3862
3874
|
const attachmentsRef = useRef8(null);
|
|
3863
|
-
const senderRef =
|
|
3875
|
+
const senderRef = React7.useRef(null);
|
|
3864
3876
|
const {
|
|
3865
3877
|
messages,
|
|
3866
3878
|
sendMessage,
|
|
@@ -4509,9 +4521,9 @@ var SideAppViewBrowser = () => {
|
|
|
4509
4521
|
};
|
|
4510
4522
|
|
|
4511
4523
|
// src/components/Chat/LatticeChat.tsx
|
|
4512
|
-
import { jsx as jsx34 } from "react/jsx-runtime";
|
|
4524
|
+
import { jsx as jsx34, jsxs as jsxs20 } from "react/jsx-runtime";
|
|
4513
4525
|
var LatticeChat = (props) => {
|
|
4514
|
-
const { assistant_id, thread_id = "", menu, ...chatingProps } = props;
|
|
4526
|
+
const { assistant_id, thread_id = "", menu, header, ...chatingProps } = props;
|
|
4515
4527
|
return /* @__PURE__ */ jsx34(
|
|
4516
4528
|
AgentThreadProvider,
|
|
4517
4529
|
{
|
|
@@ -4522,12 +4534,26 @@ var LatticeChat = (props) => {
|
|
|
4522
4534
|
enableReturnStateWhenStreamCompleted: true,
|
|
4523
4535
|
enableResumeStream: true
|
|
4524
4536
|
},
|
|
4525
|
-
children: /* @__PURE__ */ jsx34(ChatUIContextProvider, { children: /* @__PURE__ */
|
|
4526
|
-
|
|
4537
|
+
children: /* @__PURE__ */ jsx34(ChatUIContextProvider, { children: /* @__PURE__ */ jsxs20(
|
|
4538
|
+
"div",
|
|
4527
4539
|
{
|
|
4528
|
-
|
|
4529
|
-
|
|
4530
|
-
|
|
4540
|
+
style: {
|
|
4541
|
+
display: "flex",
|
|
4542
|
+
flexDirection: "column",
|
|
4543
|
+
width: "100%",
|
|
4544
|
+
height: "100%"
|
|
4545
|
+
},
|
|
4546
|
+
children: [
|
|
4547
|
+
header,
|
|
4548
|
+
/* @__PURE__ */ jsx34(
|
|
4549
|
+
ColumnLayout,
|
|
4550
|
+
{
|
|
4551
|
+
menu,
|
|
4552
|
+
left: thread_id ? /* @__PURE__ */ jsx34(Chating, { ...chatingProps }) : /* @__PURE__ */ jsx34("div", { children: "\u9700\u8981\u5148\u521B\u5EFA\u4F1A\u8BDD" }),
|
|
4553
|
+
right: /* @__PURE__ */ jsx34(SideAppViewBrowser, {})
|
|
4554
|
+
}
|
|
4555
|
+
)
|
|
4556
|
+
]
|
|
4531
4557
|
}
|
|
4532
4558
|
) })
|
|
4533
4559
|
}
|
|
@@ -4540,7 +4566,7 @@ import {
|
|
|
4540
4566
|
useCallback as useCallback10,
|
|
4541
4567
|
useContext as useContext6,
|
|
4542
4568
|
useEffect as useEffect13,
|
|
4543
|
-
useMemo as
|
|
4569
|
+
useMemo as useMemo7,
|
|
4544
4570
|
useRef as useRef10,
|
|
4545
4571
|
useState as useState20
|
|
4546
4572
|
} from "react";
|
|
@@ -4551,7 +4577,7 @@ import {
|
|
|
4551
4577
|
useCallback as useCallback9,
|
|
4552
4578
|
useContext as useContext5,
|
|
4553
4579
|
useEffect as useEffect12,
|
|
4554
|
-
useMemo as
|
|
4580
|
+
useMemo as useMemo6,
|
|
4555
4581
|
useRef as useRef9,
|
|
4556
4582
|
useState as useState19
|
|
4557
4583
|
} from "react";
|
|
@@ -4705,7 +4731,7 @@ var AssistantContextProvider = ({
|
|
|
4705
4731
|
const {
|
|
4706
4732
|
config: { baseURL, apiKey = "", transport = "sse" }
|
|
4707
4733
|
} = useLatticeChatShellContext();
|
|
4708
|
-
const client =
|
|
4734
|
+
const client = useMemo6(
|
|
4709
4735
|
() => new Client2({
|
|
4710
4736
|
baseURL,
|
|
4711
4737
|
apiKey,
|
|
@@ -4979,7 +5005,7 @@ var ConversationContextProvider = ({
|
|
|
4979
5005
|
const {
|
|
4980
5006
|
config: { baseURL, apiKey = "", transport = "sse" }
|
|
4981
5007
|
} = useLatticeChatShellContext();
|
|
4982
|
-
const client =
|
|
5008
|
+
const client = useMemo7(
|
|
4983
5009
|
() => new Client3({
|
|
4984
5010
|
baseURL,
|
|
4985
5011
|
apiKey,
|
|
@@ -5077,7 +5103,7 @@ var ConversationContextProvider = ({
|
|
|
5077
5103
|
prevAssistantIdRef.current = null;
|
|
5078
5104
|
}
|
|
5079
5105
|
}, [assistantId, loadThreads]);
|
|
5080
|
-
const thread =
|
|
5106
|
+
const thread = useMemo7(() => {
|
|
5081
5107
|
if (!assistantId || !threadId) {
|
|
5082
5108
|
return null;
|
|
5083
5109
|
}
|
|
@@ -5236,7 +5262,7 @@ var useConversationContext = () => {
|
|
|
5236
5262
|
// src/components/Chat/AgentConversations.tsx
|
|
5237
5263
|
import { Conversations } from "@ant-design/x";
|
|
5238
5264
|
import { theme } from "antd";
|
|
5239
|
-
import { useMemo as
|
|
5265
|
+
import { useMemo as useMemo8 } from "react";
|
|
5240
5266
|
import { jsx as jsx38 } from "react/jsx-runtime";
|
|
5241
5267
|
var AgentConversations = () => {
|
|
5242
5268
|
const { token } = theme.useToken();
|
|
@@ -5254,7 +5280,7 @@ var AgentConversations = () => {
|
|
|
5254
5280
|
background: "transparent",
|
|
5255
5281
|
borderRadius: token.borderRadius
|
|
5256
5282
|
};
|
|
5257
|
-
const threadItems =
|
|
5283
|
+
const threadItems = useMemo8(() => {
|
|
5258
5284
|
return threads || [];
|
|
5259
5285
|
}, [threads]);
|
|
5260
5286
|
const items = threadItems.map((thread2) => ({
|
|
@@ -5285,8 +5311,8 @@ var AgentConversations = () => {
|
|
|
5285
5311
|
};
|
|
5286
5312
|
|
|
5287
5313
|
// src/components/Chat/ChatSidebar.tsx
|
|
5288
|
-
import { useState as useState21 } from "react";
|
|
5289
|
-
import { Divider as Divider2 } from "antd";
|
|
5314
|
+
import { useState as useState21, useEffect as useEffect14, useRef as useRef11 } from "react";
|
|
5315
|
+
import { Divider as Divider2, Tooltip as Tooltip4 } from "antd";
|
|
5290
5316
|
import {
|
|
5291
5317
|
MenuFoldOutlined,
|
|
5292
5318
|
MenuUnfoldOutlined,
|
|
@@ -5335,7 +5361,7 @@ var AssistantList = () => {
|
|
|
5335
5361
|
|
|
5336
5362
|
// src/components/Chat/ChatSidebar.tsx
|
|
5337
5363
|
import { createStyles as createStyles11 } from "antd-style";
|
|
5338
|
-
import { Fragment as Fragment5, jsx as jsx40, jsxs as
|
|
5364
|
+
import { Fragment as Fragment5, jsx as jsx40, jsxs as jsxs21 } from "react/jsx-runtime";
|
|
5339
5365
|
var useStyles3 = createStyles11(({ token, css }) => ({
|
|
5340
5366
|
sidebar: css`
|
|
5341
5367
|
display: flex;
|
|
@@ -5346,6 +5372,11 @@ var useStyles3 = createStyles11(({ token, css }) => ({
|
|
|
5346
5372
|
background: transparent;
|
|
5347
5373
|
border-radius: ${token.borderRadiusLG}px;
|
|
5348
5374
|
overflow: visible;
|
|
5375
|
+
|
|
5376
|
+
&.firstTimeHighlight {
|
|
5377
|
+
border: 2px dashed ${token.colorPrimary};
|
|
5378
|
+
background: ${token.colorPrimaryBg};
|
|
5379
|
+
}
|
|
5349
5380
|
`,
|
|
5350
5381
|
content: css`
|
|
5351
5382
|
flex: 1;
|
|
@@ -5504,8 +5535,34 @@ var useStyles3 = createStyles11(({ token, css }) => ({
|
|
|
5504
5535
|
divider: css`
|
|
5505
5536
|
margin: ${token.marginMD}px 0;
|
|
5506
5537
|
border-color: ${token.colorBorderSecondary};
|
|
5538
|
+
`,
|
|
5539
|
+
hintTooltip: css`
|
|
5540
|
+
position: absolute;
|
|
5541
|
+
top: ${token.paddingMD}px;
|
|
5542
|
+
left: ${token.paddingMD}px;
|
|
5543
|
+
right: ${token.paddingMD}px;
|
|
5544
|
+
padding: ${token.paddingSM}px ${token.paddingMD}px;
|
|
5545
|
+
background: ${token.colorPrimary};
|
|
5546
|
+
color: ${token.colorTextLightSolid};
|
|
5547
|
+
border-radius: ${token.borderRadius}px;
|
|
5548
|
+
font-size: ${token.fontSizeSM}px;
|
|
5549
|
+
z-index: 1001;
|
|
5550
|
+
animation: slideIn 0.3s ease-out;
|
|
5551
|
+
box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
|
|
5552
|
+
|
|
5553
|
+
@keyframes slideIn {
|
|
5554
|
+
from {
|
|
5555
|
+
opacity: 0;
|
|
5556
|
+
transform: translateY(-10px);
|
|
5557
|
+
}
|
|
5558
|
+
to {
|
|
5559
|
+
opacity: 1;
|
|
5560
|
+
transform: translateY(0);
|
|
5561
|
+
}
|
|
5562
|
+
}
|
|
5507
5563
|
`
|
|
5508
5564
|
}));
|
|
5565
|
+
var FIRST_COLLAPSE_KEY = "chat-sidebar-first-collapse-seen";
|
|
5509
5566
|
var ChatSidebar = ({
|
|
5510
5567
|
onSettingsClick,
|
|
5511
5568
|
defaultCollapsed = false
|
|
@@ -5514,6 +5571,8 @@ var ChatSidebar = ({
|
|
|
5514
5571
|
const { setMenuCollapsed, menuCollapsed, sideAppVisible } = useChatUIContext();
|
|
5515
5572
|
const { setSettingsModalOpen } = useLatticeChatShellContext();
|
|
5516
5573
|
const [isHovered, setIsHovered] = useState21(false);
|
|
5574
|
+
const [isFirstCollapse, setIsFirstCollapse] = useState21(false);
|
|
5575
|
+
const prevIsCollapsedRef = useRef11(false);
|
|
5517
5576
|
const handleToggleCollapse = () => {
|
|
5518
5577
|
setMenuCollapsed(!menuCollapsed);
|
|
5519
5578
|
};
|
|
@@ -5522,77 +5581,109 @@ var ChatSidebar = ({
|
|
|
5522
5581
|
onSettingsClick?.();
|
|
5523
5582
|
};
|
|
5524
5583
|
const isCollapsed = menuCollapsed || sideAppVisible;
|
|
5584
|
+
useEffect14(() => {
|
|
5585
|
+
const prevIsCollapsed = prevIsCollapsedRef.current;
|
|
5586
|
+
if (isCollapsed) {
|
|
5587
|
+
const hasSeenFirstCollapse = localStorage.getItem(FIRST_COLLAPSE_KEY);
|
|
5588
|
+
if (!hasSeenFirstCollapse) {
|
|
5589
|
+
setIsFirstCollapse(true);
|
|
5590
|
+
}
|
|
5591
|
+
} else if (prevIsCollapsed && !isCollapsed) {
|
|
5592
|
+
setIsFirstCollapse((prev) => {
|
|
5593
|
+
if (prev) {
|
|
5594
|
+
return false;
|
|
5595
|
+
}
|
|
5596
|
+
return prev;
|
|
5597
|
+
});
|
|
5598
|
+
}
|
|
5599
|
+
prevIsCollapsedRef.current = isCollapsed;
|
|
5600
|
+
}, [isCollapsed]);
|
|
5525
5601
|
const handleMouseEnter = () => {
|
|
5526
5602
|
if (isCollapsed) {
|
|
5527
5603
|
setIsHovered(true);
|
|
5604
|
+
if (isFirstCollapse) {
|
|
5605
|
+
localStorage.setItem(FIRST_COLLAPSE_KEY, "true");
|
|
5606
|
+
setIsFirstCollapse(false);
|
|
5607
|
+
}
|
|
5528
5608
|
}
|
|
5529
5609
|
};
|
|
5530
5610
|
const handleMouseLeave = () => {
|
|
5531
5611
|
setIsHovered(false);
|
|
5532
5612
|
};
|
|
5533
|
-
return /* @__PURE__ */
|
|
5534
|
-
/* @__PURE__ */
|
|
5613
|
+
return /* @__PURE__ */ jsxs21(Fragment5, { children: [
|
|
5614
|
+
/* @__PURE__ */ jsxs21(
|
|
5535
5615
|
"div",
|
|
5536
5616
|
{
|
|
5537
|
-
className: styles.sidebar
|
|
5617
|
+
className: `${styles.sidebar} ${isFirstCollapse ? "firstTimeHighlight" : ""}`,
|
|
5538
5618
|
onMouseEnter: handleMouseEnter,
|
|
5539
5619
|
onMouseLeave: handleMouseLeave,
|
|
5540
|
-
children:
|
|
5541
|
-
/* @__PURE__ */
|
|
5542
|
-
|
|
5543
|
-
|
|
5544
|
-
|
|
5620
|
+
children: [
|
|
5621
|
+
/* @__PURE__ */ jsx40(
|
|
5622
|
+
Tooltip4,
|
|
5623
|
+
{
|
|
5624
|
+
title: "Move the mouse over the collapsed sidebar to see the assistants and threads",
|
|
5625
|
+
open: isFirstCollapse,
|
|
5626
|
+
placement: "right",
|
|
5627
|
+
children: isFirstCollapse && /* @__PURE__ */ jsx40("div", { style: { marginTop: "400px" } })
|
|
5628
|
+
}
|
|
5629
|
+
),
|
|
5630
|
+
!isCollapsed && /* @__PURE__ */ jsxs21(Fragment5, { children: [
|
|
5631
|
+
/* @__PURE__ */ jsxs21("div", { className: styles.content, children: [
|
|
5632
|
+
/* @__PURE__ */ jsxs21("div", { className: styles.section, children: [
|
|
5633
|
+
/* @__PURE__ */ jsx40("div", { className: styles.sectionTitle, children: "Assistants" }),
|
|
5634
|
+
/* @__PURE__ */ jsx40(AssistantList, {})
|
|
5635
|
+
] }),
|
|
5636
|
+
/* @__PURE__ */ jsx40(Divider2, { className: styles.divider }),
|
|
5637
|
+
/* @__PURE__ */ jsxs21("div", { className: styles.section, children: [
|
|
5638
|
+
/* @__PURE__ */ jsx40("div", { className: styles.sectionTitle, children: "Threads" }),
|
|
5639
|
+
/* @__PURE__ */ jsx40(AgentConversations, {})
|
|
5640
|
+
] })
|
|
5545
5641
|
] }),
|
|
5546
|
-
/* @__PURE__ */
|
|
5547
|
-
|
|
5548
|
-
|
|
5549
|
-
|
|
5642
|
+
/* @__PURE__ */ jsxs21("div", { className: styles.footer, children: [
|
|
5643
|
+
/* @__PURE__ */ jsx40(
|
|
5644
|
+
"button",
|
|
5645
|
+
{
|
|
5646
|
+
className: styles.actionButton,
|
|
5647
|
+
onClick: handleToggleCollapse,
|
|
5648
|
+
title: isCollapsed ? "Expand sidebar" : "Collapse sidebar",
|
|
5649
|
+
"aria-label": isCollapsed ? "Expand sidebar" : "Collapse sidebar",
|
|
5650
|
+
children: isCollapsed ? /* @__PURE__ */ jsx40(MenuUnfoldOutlined, {}) : /* @__PURE__ */ jsx40(MenuFoldOutlined, {})
|
|
5651
|
+
}
|
|
5652
|
+
),
|
|
5653
|
+
/* @__PURE__ */ jsx40(
|
|
5654
|
+
"button",
|
|
5655
|
+
{
|
|
5656
|
+
className: styles.actionButton,
|
|
5657
|
+
onClick: handleSettingsClick,
|
|
5658
|
+
title: "Settings",
|
|
5659
|
+
"aria-label": "Settings",
|
|
5660
|
+
children: /* @__PURE__ */ jsx40(SettingOutlined, {})
|
|
5661
|
+
}
|
|
5662
|
+
)
|
|
5550
5663
|
] })
|
|
5551
|
-
] }),
|
|
5552
|
-
/* @__PURE__ */ jsxs20("div", { className: styles.footer, children: [
|
|
5553
|
-
/* @__PURE__ */ jsx40(
|
|
5554
|
-
"button",
|
|
5555
|
-
{
|
|
5556
|
-
className: styles.actionButton,
|
|
5557
|
-
onClick: handleToggleCollapse,
|
|
5558
|
-
title: isCollapsed ? "Expand sidebar" : "Collapse sidebar",
|
|
5559
|
-
"aria-label": isCollapsed ? "Expand sidebar" : "Collapse sidebar",
|
|
5560
|
-
children: isCollapsed ? /* @__PURE__ */ jsx40(MenuUnfoldOutlined, {}) : /* @__PURE__ */ jsx40(MenuFoldOutlined, {})
|
|
5561
|
-
}
|
|
5562
|
-
),
|
|
5563
|
-
/* @__PURE__ */ jsx40(
|
|
5564
|
-
"button",
|
|
5565
|
-
{
|
|
5566
|
-
className: styles.actionButton,
|
|
5567
|
-
onClick: handleSettingsClick,
|
|
5568
|
-
title: "Settings",
|
|
5569
|
-
"aria-label": "Settings",
|
|
5570
|
-
children: /* @__PURE__ */ jsx40(SettingOutlined, {})
|
|
5571
|
-
}
|
|
5572
|
-
)
|
|
5573
5664
|
] })
|
|
5574
|
-
]
|
|
5665
|
+
]
|
|
5575
5666
|
}
|
|
5576
5667
|
),
|
|
5577
|
-
isCollapsed && /* @__PURE__ */
|
|
5668
|
+
isCollapsed && /* @__PURE__ */ jsxs21(
|
|
5578
5669
|
"div",
|
|
5579
5670
|
{
|
|
5580
5671
|
className: `${styles.hoverOverlay} ${isHovered ? "visible" : ""}`,
|
|
5581
5672
|
onMouseEnter: handleMouseEnter,
|
|
5582
5673
|
onMouseLeave: handleMouseLeave,
|
|
5583
5674
|
children: [
|
|
5584
|
-
/* @__PURE__ */
|
|
5585
|
-
/* @__PURE__ */
|
|
5675
|
+
/* @__PURE__ */ jsxs21("div", { className: styles.hoverContent, children: [
|
|
5676
|
+
/* @__PURE__ */ jsxs21("div", { className: styles.section, children: [
|
|
5586
5677
|
/* @__PURE__ */ jsx40("div", { className: styles.sectionTitle, children: "Assistants" }),
|
|
5587
5678
|
/* @__PURE__ */ jsx40(AssistantList, {})
|
|
5588
5679
|
] }),
|
|
5589
5680
|
/* @__PURE__ */ jsx40(Divider2, { className: styles.divider }),
|
|
5590
|
-
/* @__PURE__ */
|
|
5681
|
+
/* @__PURE__ */ jsxs21("div", { className: styles.section, children: [
|
|
5591
5682
|
/* @__PURE__ */ jsx40("div", { className: styles.sectionTitle, children: "Threads" }),
|
|
5592
5683
|
/* @__PURE__ */ jsx40(AgentConversations, {})
|
|
5593
5684
|
] })
|
|
5594
5685
|
] }),
|
|
5595
|
-
/* @__PURE__ */
|
|
5686
|
+
/* @__PURE__ */ jsxs21("div", { className: styles.footer, children: [
|
|
5596
5687
|
/* @__PURE__ */ jsx40(
|
|
5597
5688
|
"button",
|
|
5598
5689
|
{
|
|
@@ -5652,7 +5743,7 @@ var LatticeChatView = (props) => {
|
|
|
5652
5743
|
};
|
|
5653
5744
|
|
|
5654
5745
|
// src/components/Chat/SettingsModal.tsx
|
|
5655
|
-
import { useState as useState22, useEffect as
|
|
5746
|
+
import { useState as useState22, useEffect as useEffect15, useRef as useRef12 } from "react";
|
|
5656
5747
|
import {
|
|
5657
5748
|
Modal,
|
|
5658
5749
|
Input,
|
|
@@ -5678,7 +5769,7 @@ import {
|
|
|
5678
5769
|
CloudServerOutlined
|
|
5679
5770
|
} from "@ant-design/icons";
|
|
5680
5771
|
import { createStyles as createStyles12 } from "antd-style";
|
|
5681
|
-
import { Fragment as Fragment6, jsx as jsx42, jsxs as
|
|
5772
|
+
import { Fragment as Fragment6, jsx as jsx42, jsxs as jsxs22 } from "react/jsx-runtime";
|
|
5682
5773
|
var { Text: Text13, Title: Title2 } = Typography15;
|
|
5683
5774
|
var { TextArea } = Input;
|
|
5684
5775
|
var useStyles4 = createStyles12(({ token, css }) => ({
|
|
@@ -6065,8 +6156,8 @@ var SettingsModal = ({
|
|
|
6065
6156
|
return [];
|
|
6066
6157
|
});
|
|
6067
6158
|
const [serverConfigs, setServerConfigs] = useState22({});
|
|
6068
|
-
const connectionsRef =
|
|
6069
|
-
|
|
6159
|
+
const connectionsRef = useRef12(connections);
|
|
6160
|
+
useEffect15(() => {
|
|
6070
6161
|
connectionsRef.current = connections;
|
|
6071
6162
|
}, [connections]);
|
|
6072
6163
|
const [activeTabKey, setActiveTabKey] = useState22(
|
|
@@ -6268,7 +6359,7 @@ var SettingsModal = ({
|
|
|
6268
6359
|
console.error("Failed to load models configuration:", error);
|
|
6269
6360
|
}
|
|
6270
6361
|
};
|
|
6271
|
-
|
|
6362
|
+
useEffect15(() => {
|
|
6272
6363
|
if (open && activeTabKey) {
|
|
6273
6364
|
initializeServerConfig(activeTabKey);
|
|
6274
6365
|
const connection = connections.find((c) => c.id === activeTabKey);
|
|
@@ -6277,7 +6368,7 @@ var SettingsModal = ({
|
|
|
6277
6368
|
}
|
|
6278
6369
|
}
|
|
6279
6370
|
}, [open, activeTabKey]);
|
|
6280
|
-
|
|
6371
|
+
useEffect15(() => {
|
|
6281
6372
|
if (open && activeTabKey) {
|
|
6282
6373
|
const connection = connections.find((c) => c.id === activeTabKey);
|
|
6283
6374
|
if (connection?.connected) {
|
|
@@ -6478,13 +6569,13 @@ var SettingsModal = ({
|
|
|
6478
6569
|
}
|
|
6479
6570
|
}));
|
|
6480
6571
|
};
|
|
6481
|
-
return /* @__PURE__ */
|
|
6572
|
+
return /* @__PURE__ */ jsxs22("div", { className: styles.formContainer, children: [
|
|
6482
6573
|
/* @__PURE__ */ jsx42(
|
|
6483
6574
|
Alert3,
|
|
6484
6575
|
{
|
|
6485
6576
|
message: "Configuration Effect",
|
|
6486
|
-
description: /* @__PURE__ */
|
|
6487
|
-
/* @__PURE__ */
|
|
6577
|
+
description: /* @__PURE__ */ jsxs22("div", { children: [
|
|
6578
|
+
/* @__PURE__ */ jsxs22("div", { style: { marginBottom: 8 }, children: [
|
|
6488
6579
|
/* @__PURE__ */ jsx42(
|
|
6489
6580
|
CheckCircleOutlined4,
|
|
6490
6581
|
{
|
|
@@ -6494,7 +6585,7 @@ var SettingsModal = ({
|
|
|
6494
6585
|
/* @__PURE__ */ jsx42("strong", { children: "Immediately effective:" }),
|
|
6495
6586
|
" QUEUE_SERVICE_TYPE, REDIS_URL, REDIS_PASSWORD, QUEUE_NAME"
|
|
6496
6587
|
] }),
|
|
6497
|
-
/* @__PURE__ */
|
|
6588
|
+
/* @__PURE__ */ jsxs22("div", { children: [
|
|
6498
6589
|
/* @__PURE__ */ jsx42(ReloadOutlined2, { style: { color: "#faad14", marginRight: 8 } }),
|
|
6499
6590
|
/* @__PURE__ */ jsx42("strong", { children: "Requires restart:" }),
|
|
6500
6591
|
" PORT (server must be restarted to change port)"
|
|
@@ -6583,10 +6674,10 @@ QUEUE_NAME=tasks`,
|
|
|
6583
6674
|
}));
|
|
6584
6675
|
}
|
|
6585
6676
|
};
|
|
6586
|
-
return /* @__PURE__ */
|
|
6677
|
+
return /* @__PURE__ */ jsxs22("div", { className: styles.formContainer, children: [
|
|
6587
6678
|
/* @__PURE__ */ jsx42("div", { style: { marginBottom: 32 }, children: /* @__PURE__ */ jsx42(Text13, { type: "secondary", style: { fontSize: 14, lineHeight: 1.6 }, children: "Configure model lattices. Each model will be registered with the provided key and can be used by agents." }) }),
|
|
6588
|
-
config.models.map((model, index) => /* @__PURE__ */
|
|
6589
|
-
/* @__PURE__ */
|
|
6679
|
+
config.models.map((model, index) => /* @__PURE__ */ jsxs22("div", { className: styles.card, children: [
|
|
6680
|
+
/* @__PURE__ */ jsxs22(
|
|
6590
6681
|
"div",
|
|
6591
6682
|
{
|
|
6592
6683
|
style: {
|
|
@@ -6598,12 +6689,12 @@ QUEUE_NAME=tasks`,
|
|
|
6598
6689
|
borderBottom: "1px solid rgba(0, 0, 0, 0.06)"
|
|
6599
6690
|
},
|
|
6600
6691
|
children: [
|
|
6601
|
-
/* @__PURE__ */
|
|
6602
|
-
/* @__PURE__ */
|
|
6692
|
+
/* @__PURE__ */ jsxs22("div", { children: [
|
|
6693
|
+
/* @__PURE__ */ jsxs22(Text13, { strong: true, style: { fontSize: 16 }, children: [
|
|
6603
6694
|
"Model ",
|
|
6604
6695
|
index + 1
|
|
6605
6696
|
] }),
|
|
6606
|
-
model.key && /* @__PURE__ */
|
|
6697
|
+
model.key && /* @__PURE__ */ jsxs22(
|
|
6607
6698
|
Text13,
|
|
6608
6699
|
{
|
|
6609
6700
|
type: "secondary",
|
|
@@ -6633,8 +6724,8 @@ QUEUE_NAME=tasks`,
|
|
|
6633
6724
|
]
|
|
6634
6725
|
}
|
|
6635
6726
|
),
|
|
6636
|
-
/* @__PURE__ */
|
|
6637
|
-
/* @__PURE__ */
|
|
6727
|
+
/* @__PURE__ */ jsxs22(Space14, { direction: "vertical", style: { width: "100%" }, size: "large", children: [
|
|
6728
|
+
/* @__PURE__ */ jsxs22("div", { children: [
|
|
6638
6729
|
/* @__PURE__ */ jsx42(Text13, { className: styles.formLabel, children: "Key *" }),
|
|
6639
6730
|
/* @__PURE__ */ jsx42(
|
|
6640
6731
|
Input,
|
|
@@ -6647,7 +6738,7 @@ QUEUE_NAME=tasks`,
|
|
|
6647
6738
|
),
|
|
6648
6739
|
/* @__PURE__ */ jsx42(Text13, { className: styles.formDescription, children: "Unique identifier for this model" })
|
|
6649
6740
|
] }),
|
|
6650
|
-
/* @__PURE__ */
|
|
6741
|
+
/* @__PURE__ */ jsxs22("div", { children: [
|
|
6651
6742
|
/* @__PURE__ */ jsx42(Text13, { className: styles.formLabel, children: "Provider *" }),
|
|
6652
6743
|
/* @__PURE__ */ jsx42(
|
|
6653
6744
|
Select,
|
|
@@ -6665,7 +6756,7 @@ QUEUE_NAME=tasks`,
|
|
|
6665
6756
|
}
|
|
6666
6757
|
)
|
|
6667
6758
|
] }),
|
|
6668
|
-
/* @__PURE__ */
|
|
6759
|
+
/* @__PURE__ */ jsxs22("div", { children: [
|
|
6669
6760
|
/* @__PURE__ */ jsx42(Text13, { className: styles.formLabel, children: "Model Name *" }),
|
|
6670
6761
|
/* @__PURE__ */ jsx42(
|
|
6671
6762
|
Input,
|
|
@@ -6677,7 +6768,7 @@ QUEUE_NAME=tasks`,
|
|
|
6677
6768
|
}
|
|
6678
6769
|
)
|
|
6679
6770
|
] }),
|
|
6680
|
-
/* @__PURE__ */
|
|
6771
|
+
/* @__PURE__ */ jsxs22("div", { children: [
|
|
6681
6772
|
/* @__PURE__ */ jsx42(Text13, { className: styles.formLabel, children: "API Key" }),
|
|
6682
6773
|
/* @__PURE__ */ jsx42(
|
|
6683
6774
|
Input.Password,
|
|
@@ -6690,7 +6781,7 @@ QUEUE_NAME=tasks`,
|
|
|
6690
6781
|
),
|
|
6691
6782
|
/* @__PURE__ */ jsx42(Text13, { className: styles.formDescription, children: "API key for the model provider. Leave empty to use environment variable." })
|
|
6692
6783
|
] }),
|
|
6693
|
-
/* @__PURE__ */
|
|
6784
|
+
/* @__PURE__ */ jsxs22("div", { children: [
|
|
6694
6785
|
/* @__PURE__ */ jsx42(Text13, { className: styles.formLabel, children: "Base URL" }),
|
|
6695
6786
|
/* @__PURE__ */ jsx42(
|
|
6696
6787
|
Input,
|
|
@@ -6703,7 +6794,7 @@ QUEUE_NAME=tasks`,
|
|
|
6703
6794
|
),
|
|
6704
6795
|
/* @__PURE__ */ jsx42(Text13, { className: styles.formDescription, children: "Optional custom base URL for the API" })
|
|
6705
6796
|
] }),
|
|
6706
|
-
/* @__PURE__ */ jsx42("div", { children: /* @__PURE__ */
|
|
6797
|
+
/* @__PURE__ */ jsx42("div", { children: /* @__PURE__ */ jsxs22(Space14, { children: [
|
|
6707
6798
|
/* @__PURE__ */ jsx42(
|
|
6708
6799
|
Switch,
|
|
6709
6800
|
{
|
|
@@ -6713,8 +6804,8 @@ QUEUE_NAME=tasks`,
|
|
|
6713
6804
|
),
|
|
6714
6805
|
/* @__PURE__ */ jsx42(Text13, { children: "Enable Streaming" })
|
|
6715
6806
|
] }) }),
|
|
6716
|
-
/* @__PURE__ */
|
|
6717
|
-
/* @__PURE__ */
|
|
6807
|
+
/* @__PURE__ */ jsxs22("div", { style: { display: "flex", gap: 20 }, children: [
|
|
6808
|
+
/* @__PURE__ */ jsxs22("div", { style: { flex: 1 }, children: [
|
|
6718
6809
|
/* @__PURE__ */ jsx42(Text13, { className: styles.formLabel, children: "Max Tokens" }),
|
|
6719
6810
|
/* @__PURE__ */ jsx42(
|
|
6720
6811
|
Input,
|
|
@@ -6731,7 +6822,7 @@ QUEUE_NAME=tasks`,
|
|
|
6731
6822
|
}
|
|
6732
6823
|
)
|
|
6733
6824
|
] }),
|
|
6734
|
-
/* @__PURE__ */
|
|
6825
|
+
/* @__PURE__ */ jsxs22("div", { style: { flex: 1 }, children: [
|
|
6735
6826
|
/* @__PURE__ */ jsx42(Text13, { className: styles.formLabel, children: "Temperature" }),
|
|
6736
6827
|
/* @__PURE__ */ jsx42(
|
|
6737
6828
|
Input,
|
|
@@ -6780,7 +6871,7 @@ QUEUE_NAME=tasks`,
|
|
|
6780
6871
|
);
|
|
6781
6872
|
const currentConnection = connections.find((c) => c.id === activeTabKey);
|
|
6782
6873
|
const renderTabLabel = (connection) => {
|
|
6783
|
-
return /* @__PURE__ */
|
|
6874
|
+
return /* @__PURE__ */ jsxs22("div", { style: { display: "flex", alignItems: "center" }, children: [
|
|
6784
6875
|
/* @__PURE__ */ jsx42(
|
|
6785
6876
|
CloudServerOutlined,
|
|
6786
6877
|
{
|
|
@@ -6808,8 +6899,8 @@ QUEUE_NAME=tasks`,
|
|
|
6808
6899
|
const tabItems = connections.map((connection) => ({
|
|
6809
6900
|
key: connection.id,
|
|
6810
6901
|
label: renderTabLabel(connection),
|
|
6811
|
-
children: /* @__PURE__ */ jsx42("div", { className: styles.tabContent, children: connection.connected ? /* @__PURE__ */ jsx42(Fragment6, { children: /* @__PURE__ */
|
|
6812
|
-
/* @__PURE__ */ jsx42("div", { className: styles.sidebar, children: SETTINGS_MENU_ITEMS.map((item) => /* @__PURE__ */
|
|
6902
|
+
children: /* @__PURE__ */ jsx42("div", { className: styles.tabContent, children: connection.connected ? /* @__PURE__ */ jsx42(Fragment6, { children: /* @__PURE__ */ jsxs22("div", { style: { display: "flex", height: "100%" }, children: [
|
|
6903
|
+
/* @__PURE__ */ jsx42("div", { className: styles.sidebar, children: SETTINGS_MENU_ITEMS.map((item) => /* @__PURE__ */ jsxs22(
|
|
6813
6904
|
"div",
|
|
6814
6905
|
{
|
|
6815
6906
|
className: `${styles.menuItem} ${activeMenu === item.key ? "active" : ""}`,
|
|
@@ -6821,16 +6912,16 @@ QUEUE_NAME=tasks`,
|
|
|
6821
6912
|
},
|
|
6822
6913
|
item.key
|
|
6823
6914
|
)) }),
|
|
6824
|
-
/* @__PURE__ */
|
|
6825
|
-
/* @__PURE__ */
|
|
6826
|
-
/* @__PURE__ */
|
|
6915
|
+
/* @__PURE__ */ jsxs22("div", { className: styles.content, children: [
|
|
6916
|
+
/* @__PURE__ */ jsxs22("div", { className: styles.contentHeader, children: [
|
|
6917
|
+
/* @__PURE__ */ jsxs22("div", { className: styles.contentHeaderLeft, children: [
|
|
6827
6918
|
/* @__PURE__ */ jsx42(Title2, { level: 3, className: styles.contentTitle, children: activeMenuItem?.label }),
|
|
6828
|
-
/* @__PURE__ */
|
|
6919
|
+
/* @__PURE__ */ jsxs22(Text13, { className: styles.contentDescription, children: [
|
|
6829
6920
|
activeMenu === "environment" && "Manage environment variables for the gateway server",
|
|
6830
6921
|
activeMenu === "models" && "Configure and register model lattices for use by agents"
|
|
6831
6922
|
] })
|
|
6832
6923
|
] }),
|
|
6833
|
-
/* @__PURE__ */
|
|
6924
|
+
/* @__PURE__ */ jsxs22("div", { className: styles.contentHeaderRight, children: [
|
|
6834
6925
|
/* @__PURE__ */ jsx42(Button14, { onClick: onClose, children: "Cancel" }),
|
|
6835
6926
|
/* @__PURE__ */ jsx42(
|
|
6836
6927
|
Button14,
|
|
@@ -6858,14 +6949,14 @@ QUEUE_NAME=tasks`,
|
|
|
6858
6949
|
gap: 16,
|
|
6859
6950
|
padding: 48
|
|
6860
6951
|
},
|
|
6861
|
-
children: connection.connecting ? /* @__PURE__ */
|
|
6952
|
+
children: connection.connecting ? /* @__PURE__ */ jsxs22(Fragment6, { children: [
|
|
6862
6953
|
/* @__PURE__ */ jsx42(LinkOutlined, { style: { fontSize: 64, color: "#1890ff" }, spin: true }),
|
|
6863
6954
|
/* @__PURE__ */ jsx42(Title2, { level: 4, children: "Connecting..." }),
|
|
6864
|
-
/* @__PURE__ */
|
|
6955
|
+
/* @__PURE__ */ jsxs22(Text13, { type: "secondary", style: { textAlign: "center" }, children: [
|
|
6865
6956
|
"Connecting to ",
|
|
6866
6957
|
connection.url
|
|
6867
6958
|
] })
|
|
6868
|
-
] }) : /* @__PURE__ */
|
|
6959
|
+
] }) : /* @__PURE__ */ jsxs22(Fragment6, { children: [
|
|
6869
6960
|
/* @__PURE__ */ jsx42(LinkOutlined, { style: { fontSize: 64, color: "#d9d9d9" } }),
|
|
6870
6961
|
/* @__PURE__ */ jsx42(Title2, { level: 4, type: "secondary", children: connection.error || "Not Connected" }),
|
|
6871
6962
|
/* @__PURE__ */ jsx42(
|
|
@@ -6892,7 +6983,7 @@ QUEUE_NAME=tasks`,
|
|
|
6892
6983
|
) }),
|
|
6893
6984
|
closable: connections.length > 1
|
|
6894
6985
|
}));
|
|
6895
|
-
return /* @__PURE__ */
|
|
6986
|
+
return /* @__PURE__ */ jsxs22(Fragment6, { children: [
|
|
6896
6987
|
/* @__PURE__ */ jsx42(
|
|
6897
6988
|
Modal,
|
|
6898
6989
|
{
|
|
@@ -6916,7 +7007,7 @@ QUEUE_NAME=tasks`,
|
|
|
6916
7007
|
}
|
|
6917
7008
|
},
|
|
6918
7009
|
items: tabItems,
|
|
6919
|
-
addIcon: /* @__PURE__ */
|
|
7010
|
+
addIcon: /* @__PURE__ */ jsxs22(
|
|
6920
7011
|
"div",
|
|
6921
7012
|
{
|
|
6922
7013
|
style: {
|
|
@@ -6949,8 +7040,8 @@ QUEUE_NAME=tasks`,
|
|
|
6949
7040
|
},
|
|
6950
7041
|
confirmLoading: addingServer,
|
|
6951
7042
|
className: styles.addServerModal,
|
|
6952
|
-
children: /* @__PURE__ */
|
|
6953
|
-
/* @__PURE__ */
|
|
7043
|
+
children: /* @__PURE__ */ jsxs22(Space14, { direction: "vertical", style: { width: "100%" }, size: "large", children: [
|
|
7044
|
+
/* @__PURE__ */ jsxs22("div", { children: [
|
|
6954
7045
|
/* @__PURE__ */ jsx42(Text13, { strong: true, style: { display: "block", marginBottom: 8 }, children: "Server Name" }),
|
|
6955
7046
|
/* @__PURE__ */ jsx42(
|
|
6956
7047
|
Input,
|
|
@@ -6963,7 +7054,7 @@ QUEUE_NAME=tasks`,
|
|
|
6963
7054
|
),
|
|
6964
7055
|
/* @__PURE__ */ jsx42(Text13, { type: "secondary", style: { fontSize: 12, marginTop: 4 }, children: "Optional: Leave empty to use URL as name" })
|
|
6965
7056
|
] }),
|
|
6966
|
-
/* @__PURE__ */
|
|
7057
|
+
/* @__PURE__ */ jsxs22("div", { children: [
|
|
6967
7058
|
/* @__PURE__ */ jsx42(Text13, { strong: true, style: { display: "block", marginBottom: 8 }, children: "Server URL *" }),
|
|
6968
7059
|
/* @__PURE__ */ jsx42(
|
|
6969
7060
|
Input,
|
|
@@ -6976,7 +7067,7 @@ QUEUE_NAME=tasks`,
|
|
|
6976
7067
|
),
|
|
6977
7068
|
/* @__PURE__ */ jsx42(Text13, { type: "secondary", style: { fontSize: 12, marginTop: 4 }, children: "Enter the full URL of the gateway server" })
|
|
6978
7069
|
] }),
|
|
6979
|
-
/* @__PURE__ */
|
|
7070
|
+
/* @__PURE__ */ jsxs22("div", { children: [
|
|
6980
7071
|
/* @__PURE__ */ jsx42(Text13, { strong: true, style: { display: "block", marginBottom: 8 }, children: "API Key" }),
|
|
6981
7072
|
/* @__PURE__ */ jsx42(
|
|
6982
7073
|
Input.Password,
|
|
@@ -7009,9 +7100,9 @@ var AgentServerSetting = () => {
|
|
|
7009
7100
|
};
|
|
7010
7101
|
|
|
7011
7102
|
// src/components/Chat/LatticeChatShell.tsx
|
|
7012
|
-
import { jsx as jsx44, jsxs as
|
|
7103
|
+
import { jsx as jsx44, jsxs as jsxs23 } from "react/jsx-runtime";
|
|
7013
7104
|
var LatticeChatShell = (props) => {
|
|
7014
|
-
return /* @__PURE__ */
|
|
7105
|
+
return /* @__PURE__ */ jsxs23(LatticeChatShellContextProvider, { ...props, children: [
|
|
7015
7106
|
/* @__PURE__ */ jsx44(AssistantContextProvider, { autoLoad: true, children: /* @__PURE__ */ jsx44(ConversationContextProvider, { children: /* @__PURE__ */ jsx44(LatticeChatView, {}) }) }),
|
|
7016
7107
|
/* @__PURE__ */ jsx44(AgentServerSetting, {})
|
|
7017
7108
|
] });
|