@burdenoff/microfe-botmanor 2026.819.1 → 2026.925.1
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/botlit/BotlitRoutes.js.map +1 -1
- package/dist/botlit/BotmanorRoot.js.map +1 -1
- package/dist/botlit/BotmanorRootInner.js +4 -4
- package/dist/botlit/BotmanorRootInner.js.map +1 -1
- package/dist/botlit/components/ErrorState.js +33 -29
- package/dist/botlit/components/ErrorState.js.map +1 -1
- package/dist/botlit/components/RouteLoader.js +52 -48
- package/dist/botlit/components/RouteLoader.js.map +1 -1
- package/dist/botlit/components/VersionHistoryPanel.js +74 -77
- package/dist/botlit/components/VersionHistoryPanel.js.map +1 -1
- package/dist/botlit/components/WorkspaceRequired.js +31 -30
- package/dist/botlit/components/WorkspaceRequired.js.map +1 -1
- package/dist/botlit/hooks/internal/workspaceGateway.js.map +1 -1
- package/dist/botlit/hooks/useConversations.js.map +1 -1
- package/dist/botlit/hooks/useLLMProviders.js.map +1 -1
- package/dist/botlit/hooks/useMCPServers.js +60 -49
- package/dist/botlit/hooks/useMCPServers.js.map +1 -1
- package/dist/botlit/pages/A2AAgentDetailPage.js +1 -1
- package/dist/botlit/pages/A2AAgentDetailPage.js.map +1 -1
- package/dist/botlit/pages/A2ARegistryPage.js +116 -124
- package/dist/botlit/pages/A2ARegistryPage.js.map +1 -1
- package/dist/botlit/pages/AgentDetailPage.js +169 -172
- package/dist/botlit/pages/AgentDetailPage.js.map +1 -1
- package/dist/botlit/pages/AgentsListPage.js +96 -90
- package/dist/botlit/pages/AgentsListPage.js.map +1 -1
- package/dist/botlit/pages/BotChannelsTab.js.map +1 -1
- package/dist/botlit/pages/BotDetailPage.js +228 -231
- package/dist/botlit/pages/BotDetailPage.js.map +1 -1
- package/dist/botlit/pages/BotWorkflowTab.js +84 -87
- package/dist/botlit/pages/BotWorkflowTab.js.map +1 -1
- package/dist/botlit/pages/BotsListPage.js +144 -147
- package/dist/botlit/pages/BotsListPage.js.map +1 -1
- package/dist/botlit/pages/BucketsPage.js +3 -3
- package/dist/botlit/pages/BucketsPage.js.map +1 -1
- package/dist/botlit/pages/ChannelDetailPage.js +1 -1
- package/dist/botlit/pages/ChannelDetailPage.js.map +1 -1
- package/dist/botlit/pages/ChannelsPage.js +156 -149
- package/dist/botlit/pages/ChannelsPage.js.map +1 -1
- package/dist/botlit/pages/ChatPage.js +126 -129
- package/dist/botlit/pages/ChatPage.js.map +1 -1
- package/dist/botlit/pages/DashboardPage.js +111 -114
- package/dist/botlit/pages/DashboardPage.js.map +1 -1
- package/dist/botlit/pages/ExecutionsPage.js +163 -159
- package/dist/botlit/pages/ExecutionsPage.js.map +1 -1
- package/dist/botlit/pages/InstalledPackagesPage.js +3 -3
- package/dist/botlit/pages/InstalledPackagesPage.js.map +1 -1
- package/dist/botlit/pages/KnowledgeBasesPage.js +84 -78
- package/dist/botlit/pages/KnowledgeBasesPage.js.map +1 -1
- package/dist/botlit/pages/MCPServerDetailPage.js +295 -238
- package/dist/botlit/pages/MCPServerDetailPage.js.map +1 -1
- package/dist/botlit/pages/MCPServersPage.js +159 -154
- package/dist/botlit/pages/MCPServersPage.js.map +1 -1
- package/dist/botlit/pages/PoliciesPage.js +119 -114
- package/dist/botlit/pages/PoliciesPage.js.map +1 -1
- package/dist/botlit/pages/RetrievalProfilesPage.js +102 -109
- package/dist/botlit/pages/RetrievalProfilesPage.js.map +1 -1
- package/dist/botlit/pages/SettingsPage.js +144 -159
- package/dist/botlit/pages/SettingsPage.js.map +1 -1
- package/dist/botlit/pages/SkillsPage.js +122 -105
- package/dist/botlit/pages/SkillsPage.js.map +1 -1
- package/dist/botlit/pages/StorePage.js +176 -175
- package/dist/botlit/pages/StorePage.js.map +1 -1
- package/dist/botlit/providers/BotlitProvider.js.map +1 -1
- package/dist/botlit/store/botlitStore.js +1 -1
- package/dist/botlit/store/botlitStore.js.map +1 -1
- package/dist/botlit/utils/navigation.js.map +1 -1
- package/dist/generated/wspace-operations.js +45 -29
- package/dist/generated/wspace-operations.js.map +1 -1
- package/dist/generated/wspace-types.js.map +1 -1
- package/dist/shared/hooks/useTr.js +14 -0
- package/dist/shared/hooks/useTr.js.map +1 -0
- package/package.json +33 -9
|
@@ -1,32 +1,32 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
1
|
+
import { useTr as e } from "../../shared/hooks/useTr.js";
|
|
2
|
+
import { useBotlit as t } from "../providers/BotlitProvider.js";
|
|
3
|
+
import { useBot as n, useCreateBot as r, useDeleteBot as ee, useUpdateBot as te } from "../hooks/useBots.js";
|
|
4
|
+
import { useAgents as ne } from "../hooks/useAgents.js";
|
|
5
|
+
import { cn as re } from "../utils/cn.js";
|
|
6
|
+
import { formatNumber as ie, formatRelativeTime as i } from "../utils/formatters.js";
|
|
7
|
+
import { PageLayout as a } from "../components/PageLayout.js";
|
|
8
|
+
import { Card as o, CardContent as s, CardDescription as c, CardHeader as l, CardTitle as u } from "../components/Card.js";
|
|
9
|
+
import { Button as d } from "../components/Button.js";
|
|
10
|
+
import { Badge as f, StatusBadge as p } from "../components/Badge.js";
|
|
10
11
|
import { EmptyState as ae } from "../components/EmptyState.js";
|
|
11
|
-
import { FormField as
|
|
12
|
-
import { toUnion as
|
|
12
|
+
import { FormField as m, Input as h, Textarea as g } from "../components/Input.js";
|
|
13
|
+
import { toUnion as _ } from "../utils/unions.js";
|
|
13
14
|
import { QuotaExhaustedDialog as oe } from "../components/QuotaExhaustedDialog.js";
|
|
14
15
|
import { BotChannelsTab as se } from "./BotChannelsTab.js";
|
|
15
|
-
import { Suspense as ce, lazy as
|
|
16
|
-
import { GlassCard as
|
|
17
|
-
import { Fragment as fe, jsx as
|
|
16
|
+
import { Suspense as ce, lazy as v, useEffect as y, useState as b } from "react";
|
|
17
|
+
import { GlassCard as le, NextSteps as ue, PagePurpose as de } from "@burdenoff/fe-libs/ui";
|
|
18
|
+
import { Fragment as fe, jsx as x, jsxs as S } from "react/jsx-runtime";
|
|
18
19
|
import { Link as pe, useParams as me, useSearchParams as he } from "react-router";
|
|
19
20
|
import { isQuotaExhaustedError as ge } from "@burdenoff/fe-libs/shared/utils";
|
|
20
|
-
import { ArrowLeft as
|
|
21
|
-
import {
|
|
22
|
-
import { toast as j } from "sonner";
|
|
21
|
+
import { ArrowLeft as C, BarChart3 as _e, Bot as w, Edit as ve, GitBranch as ye, Layers as T, MessageSquare as E, Radio as D, Save as O, Shield as k, Trash2 as A, Workflow as j } from "lucide-react";
|
|
22
|
+
import { toast as M } from "sonner";
|
|
23
23
|
//#region src/botlit/pages/BotDetailPage.tsx
|
|
24
|
-
var
|
|
24
|
+
var N = v(() => import("./BotWorkflowTab.js").then((e) => ({ default: e.BotWorkflowTab }))), P = [
|
|
25
25
|
"SINGLE",
|
|
26
26
|
"ROUND_ROBIN",
|
|
27
27
|
"INTELLIGENT",
|
|
28
28
|
"CUSTOM"
|
|
29
|
-
],
|
|
29
|
+
], be = "ASSISTANT", F = {
|
|
30
30
|
name: "",
|
|
31
31
|
slug: "",
|
|
32
32
|
description: "",
|
|
@@ -36,19 +36,19 @@ var M = _(() => import("./BotWorkflowTab.js").then((e) => ({ default: e.BotWorkf
|
|
|
36
36
|
fallbackMessage: "",
|
|
37
37
|
defaultAgentId: ""
|
|
38
38
|
};
|
|
39
|
-
function
|
|
39
|
+
function xe(e) {
|
|
40
40
|
return {
|
|
41
41
|
name: e.name,
|
|
42
42
|
slug: e.slug,
|
|
43
43
|
description: e.description ?? "",
|
|
44
|
-
icon: e.icon ||
|
|
45
|
-
routingStrategy:
|
|
44
|
+
icon: e.icon || F.icon,
|
|
45
|
+
routingStrategy: _(e.routingStrategy, P, "SINGLE"),
|
|
46
46
|
welcomeMessage: e.welcomeMessage ?? "",
|
|
47
47
|
fallbackMessage: e.fallbackMessage ?? "",
|
|
48
48
|
defaultAgentId: e.defaultAgentId ?? ""
|
|
49
49
|
};
|
|
50
50
|
}
|
|
51
|
-
var
|
|
51
|
+
var I = [
|
|
52
52
|
"overview",
|
|
53
53
|
"workflow",
|
|
54
54
|
"routing",
|
|
@@ -57,46 +57,43 @@ var F = [
|
|
|
57
57
|
"guardrails",
|
|
58
58
|
"releases"
|
|
59
59
|
];
|
|
60
|
-
function
|
|
60
|
+
function Se(e) {
|
|
61
61
|
if (e.get("code") && e.get("state")) return "channels";
|
|
62
62
|
let t = e.get("tab");
|
|
63
|
-
return
|
|
63
|
+
return I.find((e) => e === t) ?? "overview";
|
|
64
64
|
}
|
|
65
|
-
var
|
|
66
|
-
let {
|
|
67
|
-
let n = I(e);
|
|
68
|
-
return n === e ? t : n;
|
|
69
|
-
}, { botId: R } = me(), [we] = he(), { navigateTo: z, getPath: Te, workspaceId: B, navigate: V } = e(), { data: H, loading: Ee, refetch: U } = t(_ ? void 0 : R), { data: W } = r(), [De, Oe] = n(), [G, K] = te(), [ke, Ae] = ee(), [q, J] = v(() => Ce(we)), [Y, X] = v(P), [je, Z] = v(!1), Q = () => {
|
|
65
|
+
var L = ({ isNew: v, isEditing: I }) => {
|
|
66
|
+
let L = e(), { botId: R } = me(), [Ce] = he(), { navigateTo: z, getPath: we, workspaceId: B, navigate: V } = t(), { data: H, loading: Te, refetch: U } = n(v ? void 0 : R), { data: W } = ne(), [Ee, De] = r(), [G, K] = te(), [Oe, ke] = ee(), [q, J] = b(() => Se(Ce)), [Y, X] = b(F), [Ae, Z] = b(!1), je = () => {
|
|
70
67
|
if (V) {
|
|
71
68
|
V("/billing");
|
|
72
69
|
return;
|
|
73
70
|
}
|
|
74
71
|
window.location.assign("/billing");
|
|
75
72
|
};
|
|
76
|
-
|
|
77
|
-
H && !
|
|
78
|
-
}, [H,
|
|
79
|
-
let
|
|
73
|
+
y(() => {
|
|
74
|
+
H && !v && X(xe(H));
|
|
75
|
+
}, [H, v]);
|
|
76
|
+
let Q = async () => {
|
|
80
77
|
if (!(!Y.name || !B)) try {
|
|
81
|
-
let e = await
|
|
78
|
+
let e = await Ee({
|
|
82
79
|
workspaceId: B,
|
|
83
80
|
name: Y.name,
|
|
84
81
|
slug: Y.slug || Y.name.toLowerCase().replace(/\s+/g, "-"),
|
|
85
|
-
type:
|
|
82
|
+
type: be,
|
|
86
83
|
routingStrategy: Y.routingStrategy,
|
|
87
84
|
description: Y.description || void 0,
|
|
88
85
|
icon: Y.icon || void 0
|
|
89
86
|
});
|
|
90
|
-
|
|
87
|
+
M.success(`${L("botlit.botDetail.create.successPrefix", "Bot")} "${Y.name}" ${L("botlit.botDetail.create.successSuffix", "created successfully")}`), e?.id && z(`bots/${e.id}?tab=workflow`);
|
|
91
88
|
} catch (e) {
|
|
92
89
|
if (ge(e)) {
|
|
93
90
|
Z(!0);
|
|
94
91
|
return;
|
|
95
92
|
}
|
|
96
93
|
let t = e instanceof Error ? e.message : L("botlit.botDetail.create.error", "Failed to create bot");
|
|
97
|
-
|
|
94
|
+
M.error(t);
|
|
98
95
|
}
|
|
99
|
-
},
|
|
96
|
+
}, Me = async () => {
|
|
100
97
|
if (R) try {
|
|
101
98
|
await G({
|
|
102
99
|
botId: R,
|
|
@@ -110,37 +107,37 @@ var I = ({ isNew: _, isEditing: F }) => {
|
|
|
110
107
|
fallbackMessage: Y.fallbackMessage || null,
|
|
111
108
|
defaultAgentId: Y.defaultAgentId || null
|
|
112
109
|
}
|
|
113
|
-
}), await U(),
|
|
110
|
+
}), await U(), M.success(`${L("botlit.botDetail.update.successPrefix", "Bot")} "${Y.name}" ${L("botlit.botDetail.update.successSuffix", "updated successfully")}`), I && z(`bots/${R}`);
|
|
114
111
|
} catch (e) {
|
|
115
112
|
let t = e instanceof Error ? e.message : L("botlit.botDetail.update.error", "Failed to update bot");
|
|
116
|
-
|
|
113
|
+
M.error(t);
|
|
117
114
|
}
|
|
118
115
|
};
|
|
119
|
-
if (
|
|
116
|
+
if (v) return /* @__PURE__ */ S(fe, { children: [/* @__PURE__ */ x(a, {
|
|
120
117
|
title: L("botlit.botDetail.createPage.title", "Create New Bot"),
|
|
121
118
|
description: L("botlit.botDetail.createPage.description", "Set up a new AI-powered bot"),
|
|
122
|
-
actions: /* @__PURE__ */
|
|
119
|
+
actions: /* @__PURE__ */ S("div", {
|
|
123
120
|
className: "flex gap-2",
|
|
124
|
-
children: [/* @__PURE__ */
|
|
121
|
+
children: [/* @__PURE__ */ x(d, {
|
|
125
122
|
variant: "outline",
|
|
126
123
|
onClick: () => z("bots"),
|
|
127
124
|
children: L("botlit.common.cancel", "Cancel")
|
|
128
|
-
}), /* @__PURE__ */
|
|
129
|
-
leftIcon: /* @__PURE__ */
|
|
130
|
-
onClick:
|
|
131
|
-
isLoading:
|
|
125
|
+
}), /* @__PURE__ */ x(d, {
|
|
126
|
+
leftIcon: /* @__PURE__ */ x(O, { size: 16 }),
|
|
127
|
+
onClick: Q,
|
|
128
|
+
isLoading: De.loading,
|
|
132
129
|
disabled: !Y.name || !B,
|
|
133
130
|
children: L("botlit.botDetail.createPage.actions.createBot", "Create Bot")
|
|
134
131
|
})]
|
|
135
132
|
}),
|
|
136
|
-
children: /* @__PURE__ */
|
|
133
|
+
children: /* @__PURE__ */ x(o, {
|
|
137
134
|
className: "max-w-2xl",
|
|
138
|
-
children: /* @__PURE__ */
|
|
135
|
+
children: /* @__PURE__ */ S(s, {
|
|
139
136
|
className: "pt-6 space-y-6",
|
|
140
137
|
children: [
|
|
141
|
-
/* @__PURE__ */
|
|
138
|
+
/* @__PURE__ */ S("div", {
|
|
142
139
|
className: "flex items-center gap-4",
|
|
143
|
-
children: [/* @__PURE__ */
|
|
140
|
+
children: [/* @__PURE__ */ x("button", {
|
|
144
141
|
className: "text-5xl p-4 rounded-lg border-2 border-dashed border-border-subtle hover:border-primary transition-colors",
|
|
145
142
|
onClick: () => {
|
|
146
143
|
let e = [
|
|
@@ -161,16 +158,16 @@ var I = ({ isNew: _, isEditing: F }) => {
|
|
|
161
158
|
});
|
|
162
159
|
},
|
|
163
160
|
children: Y.icon
|
|
164
|
-
}), /* @__PURE__ */
|
|
161
|
+
}), /* @__PURE__ */ x("p", {
|
|
165
162
|
className: "text-sm text-text-secondary",
|
|
166
163
|
children: L("botlit.botDetail.form.clickToChangeIcon", "Click to change icon")
|
|
167
164
|
})]
|
|
168
165
|
}),
|
|
169
|
-
/* @__PURE__ */
|
|
166
|
+
/* @__PURE__ */ x(m, {
|
|
170
167
|
label: L("botlit.botDetail.form.botName", "Bot Name"),
|
|
171
168
|
required: !0,
|
|
172
169
|
htmlFor: "name",
|
|
173
|
-
children: /* @__PURE__ */
|
|
170
|
+
children: /* @__PURE__ */ x(h, {
|
|
174
171
|
id: "name",
|
|
175
172
|
placeholder: L("botlit.botDetail.form.botNamePlaceholder", "e.g., Customer Support Bot"),
|
|
176
173
|
value: Y.name,
|
|
@@ -180,10 +177,10 @@ var I = ({ isNew: _, isEditing: F }) => {
|
|
|
180
177
|
})
|
|
181
178
|
})
|
|
182
179
|
}),
|
|
183
|
-
/* @__PURE__ */
|
|
180
|
+
/* @__PURE__ */ x(m, {
|
|
184
181
|
label: L("botlit.botDetail.form.slug", "Slug"),
|
|
185
182
|
htmlFor: "slug",
|
|
186
|
-
children: /* @__PURE__ */
|
|
183
|
+
children: /* @__PURE__ */ x(h, {
|
|
187
184
|
id: "slug",
|
|
188
185
|
placeholder: L("botlit.botDetail.form.slugPlaceholder", "customer-support-bot"),
|
|
189
186
|
value: Y.slug,
|
|
@@ -193,10 +190,10 @@ var I = ({ isNew: _, isEditing: F }) => {
|
|
|
193
190
|
})
|
|
194
191
|
})
|
|
195
192
|
}),
|
|
196
|
-
/* @__PURE__ */
|
|
193
|
+
/* @__PURE__ */ x(m, {
|
|
197
194
|
label: L("botlit.botDetail.form.description", "Description"),
|
|
198
195
|
htmlFor: "description",
|
|
199
|
-
children: /* @__PURE__ */
|
|
196
|
+
children: /* @__PURE__ */ x(g, {
|
|
200
197
|
id: "description",
|
|
201
198
|
placeholder: L("botlit.botDetail.form.descriptionPlaceholder", "Describe what this bot does..."),
|
|
202
199
|
value: Y.description,
|
|
@@ -207,29 +204,29 @@ var I = ({ isNew: _, isEditing: F }) => {
|
|
|
207
204
|
rows: 4
|
|
208
205
|
})
|
|
209
206
|
}),
|
|
210
|
-
/* @__PURE__ */
|
|
207
|
+
/* @__PURE__ */ x(m, {
|
|
211
208
|
label: L("botlit.botDetail.form.routingStrategy", "Routing Strategy"),
|
|
212
|
-
children: /* @__PURE__ */
|
|
209
|
+
children: /* @__PURE__ */ S("select", {
|
|
213
210
|
className: "flex h-10 w-full rounded-md border border-border-default bg-bg-surface px-3 py-2 text-sm",
|
|
214
211
|
value: Y.routingStrategy,
|
|
215
212
|
onChange: (e) => X({
|
|
216
213
|
...Y,
|
|
217
|
-
routingStrategy:
|
|
214
|
+
routingStrategy: _(e.target.value, P, "SINGLE")
|
|
218
215
|
}),
|
|
219
216
|
children: [
|
|
220
|
-
/* @__PURE__ */
|
|
217
|
+
/* @__PURE__ */ x("option", {
|
|
221
218
|
value: "SINGLE",
|
|
222
219
|
children: L("botlit.botDetail.routing.single", "Single")
|
|
223
220
|
}),
|
|
224
|
-
/* @__PURE__ */
|
|
221
|
+
/* @__PURE__ */ x("option", {
|
|
225
222
|
value: "ROUND_ROBIN",
|
|
226
223
|
children: L("botlit.botDetail.routing.roundRobin", "Round Robin")
|
|
227
224
|
}),
|
|
228
|
-
/* @__PURE__ */
|
|
225
|
+
/* @__PURE__ */ x("option", {
|
|
229
226
|
value: "INTELLIGENT",
|
|
230
227
|
children: L("botlit.botDetail.routing.intelligent", "Intelligent")
|
|
231
228
|
}),
|
|
232
|
-
/* @__PURE__ */
|
|
229
|
+
/* @__PURE__ */ x("option", {
|
|
233
230
|
value: "CUSTOM",
|
|
234
231
|
children: L("botlit.botDetail.routing.custom", "Custom")
|
|
235
232
|
})
|
|
@@ -239,61 +236,61 @@ var I = ({ isNew: _, isEditing: F }) => {
|
|
|
239
236
|
]
|
|
240
237
|
})
|
|
241
238
|
})
|
|
242
|
-
}), /* @__PURE__ */
|
|
243
|
-
open:
|
|
239
|
+
}), /* @__PURE__ */ x(oe, {
|
|
240
|
+
open: Ae,
|
|
244
241
|
title: L("botlit.usage.botQuota.title", "Bot Limit Reached"),
|
|
245
242
|
description: L("botlit.usage.botQuota.description", "You have reached the number of bots allowed on your current plan."),
|
|
246
243
|
onClose: () => Z(!1),
|
|
247
|
-
onViewBilling:
|
|
244
|
+
onViewBilling: je
|
|
248
245
|
})] });
|
|
249
|
-
if (
|
|
246
|
+
if (Te) return /* @__PURE__ */ x(a, {
|
|
250
247
|
title: L("botlit.common.loading", "Loading..."),
|
|
251
|
-
children: /* @__PURE__ */
|
|
248
|
+
children: /* @__PURE__ */ x("div", { className: "h-96 bg-bg-sunken motion-safe:animate-vc-shimmer rounded-lg" })
|
|
252
249
|
});
|
|
253
|
-
if (!H) return /* @__PURE__ */
|
|
250
|
+
if (!H) return /* @__PURE__ */ x(a, {
|
|
254
251
|
title: L("botlit.botDetail.notFound.title", "Bot Not Found"),
|
|
255
|
-
children: /* @__PURE__ */
|
|
252
|
+
children: /* @__PURE__ */ x(ae, {
|
|
256
253
|
illustration: "empty-agents",
|
|
257
254
|
title: L("botlit.botDetail.notFound.title", "Bot Not Found"),
|
|
258
255
|
description: L("botlit.botDetail.notFound.description", "The bot you're looking for doesn't exist."),
|
|
259
|
-
action: /* @__PURE__ */
|
|
256
|
+
action: /* @__PURE__ */ x(d, {
|
|
260
257
|
onClick: () => z("bots"),
|
|
261
258
|
children: L("botlit.botDetail.notFound.backAction", "Back to Bots")
|
|
262
259
|
})
|
|
263
260
|
})
|
|
264
261
|
});
|
|
265
|
-
if (
|
|
266
|
-
title: /* @__PURE__ */
|
|
262
|
+
if (I && H) return /* @__PURE__ */ x(a, {
|
|
263
|
+
title: /* @__PURE__ */ S("div", {
|
|
267
264
|
className: "flex items-center gap-3",
|
|
268
|
-
children: [/* @__PURE__ */
|
|
265
|
+
children: [/* @__PURE__ */ x(d, {
|
|
269
266
|
variant: "ghost",
|
|
270
267
|
size: "icon",
|
|
271
268
|
onClick: () => z(`bots/${R}`),
|
|
272
|
-
children: /* @__PURE__ */
|
|
273
|
-
}), /* @__PURE__ */
|
|
269
|
+
children: /* @__PURE__ */ x(C, { size: 20 })
|
|
270
|
+
}), /* @__PURE__ */ x("span", { children: L("botlit.botDetail.editPage.title", "Edit Bot") })]
|
|
274
271
|
}),
|
|
275
|
-
actions: /* @__PURE__ */
|
|
272
|
+
actions: /* @__PURE__ */ S("div", {
|
|
276
273
|
className: "flex gap-2",
|
|
277
|
-
children: [/* @__PURE__ */
|
|
274
|
+
children: [/* @__PURE__ */ x(d, {
|
|
278
275
|
variant: "outline",
|
|
279
276
|
onClick: () => z(`bots/${R}`),
|
|
280
277
|
children: L("botlit.common.cancel", "Cancel")
|
|
281
|
-
}), /* @__PURE__ */
|
|
282
|
-
leftIcon: /* @__PURE__ */
|
|
283
|
-
onClick:
|
|
278
|
+
}), /* @__PURE__ */ x(d, {
|
|
279
|
+
leftIcon: /* @__PURE__ */ x(O, { size: 16 }),
|
|
280
|
+
onClick: Me,
|
|
284
281
|
isLoading: K.loading,
|
|
285
282
|
disabled: !Y.name,
|
|
286
283
|
children: L("botlit.botDetail.editPage.actions.saveChanges", "Save Changes")
|
|
287
284
|
})]
|
|
288
285
|
}),
|
|
289
|
-
children: /* @__PURE__ */
|
|
286
|
+
children: /* @__PURE__ */ x(o, {
|
|
290
287
|
className: "max-w-2xl",
|
|
291
|
-
children: /* @__PURE__ */
|
|
288
|
+
children: /* @__PURE__ */ S(s, {
|
|
292
289
|
className: "pt-6 space-y-6",
|
|
293
290
|
children: [
|
|
294
|
-
/* @__PURE__ */
|
|
291
|
+
/* @__PURE__ */ S("div", {
|
|
295
292
|
className: "flex items-center gap-4",
|
|
296
|
-
children: [/* @__PURE__ */
|
|
293
|
+
children: [/* @__PURE__ */ x("button", {
|
|
297
294
|
className: "text-5xl p-4 rounded-lg border-2 border-dashed border-border-subtle hover:border-primary transition-colors",
|
|
298
295
|
onClick: () => {
|
|
299
296
|
let e = [
|
|
@@ -314,16 +311,16 @@ var I = ({ isNew: _, isEditing: F }) => {
|
|
|
314
311
|
});
|
|
315
312
|
},
|
|
316
313
|
children: Y.icon
|
|
317
|
-
}), /* @__PURE__ */
|
|
314
|
+
}), /* @__PURE__ */ x("p", {
|
|
318
315
|
className: "text-sm text-text-secondary",
|
|
319
316
|
children: L("botlit.botDetail.form.clickToChangeIcon", "Click to change icon")
|
|
320
317
|
})]
|
|
321
318
|
}),
|
|
322
|
-
/* @__PURE__ */
|
|
319
|
+
/* @__PURE__ */ x(m, {
|
|
323
320
|
label: L("botlit.botDetail.form.botName", "Bot Name"),
|
|
324
321
|
required: !0,
|
|
325
322
|
htmlFor: "edit-name",
|
|
326
|
-
children: /* @__PURE__ */
|
|
323
|
+
children: /* @__PURE__ */ x(h, {
|
|
327
324
|
id: "edit-name",
|
|
328
325
|
placeholder: L("botlit.botDetail.form.botNamePlaceholder", "e.g., Customer Support Bot"),
|
|
329
326
|
value: Y.name,
|
|
@@ -333,10 +330,10 @@ var I = ({ isNew: _, isEditing: F }) => {
|
|
|
333
330
|
})
|
|
334
331
|
})
|
|
335
332
|
}),
|
|
336
|
-
/* @__PURE__ */
|
|
333
|
+
/* @__PURE__ */ x(m, {
|
|
337
334
|
label: L("botlit.botDetail.form.slug", "Slug"),
|
|
338
335
|
htmlFor: "edit-slug",
|
|
339
|
-
children: /* @__PURE__ */
|
|
336
|
+
children: /* @__PURE__ */ x(h, {
|
|
340
337
|
id: "edit-slug",
|
|
341
338
|
placeholder: L("botlit.botDetail.form.slugPlaceholder", "customer-support-bot"),
|
|
342
339
|
value: Y.slug,
|
|
@@ -346,10 +343,10 @@ var I = ({ isNew: _, isEditing: F }) => {
|
|
|
346
343
|
})
|
|
347
344
|
})
|
|
348
345
|
}),
|
|
349
|
-
/* @__PURE__ */
|
|
346
|
+
/* @__PURE__ */ x(m, {
|
|
350
347
|
label: L("botlit.botDetail.form.description", "Description"),
|
|
351
348
|
htmlFor: "edit-description",
|
|
352
|
-
children: /* @__PURE__ */
|
|
349
|
+
children: /* @__PURE__ */ x(g, {
|
|
353
350
|
id: "edit-description",
|
|
354
351
|
placeholder: L("botlit.botDetail.form.descriptionPlaceholder", "Describe what this bot does..."),
|
|
355
352
|
value: Y.description,
|
|
@@ -360,39 +357,39 @@ var I = ({ isNew: _, isEditing: F }) => {
|
|
|
360
357
|
rows: 4
|
|
361
358
|
})
|
|
362
359
|
}),
|
|
363
|
-
/* @__PURE__ */
|
|
360
|
+
/* @__PURE__ */ x(m, {
|
|
364
361
|
label: L("botlit.botDetail.form.routingStrategy", "Routing Strategy"),
|
|
365
|
-
children: /* @__PURE__ */
|
|
362
|
+
children: /* @__PURE__ */ S("select", {
|
|
366
363
|
className: "flex h-10 w-full rounded-md border border-border-default bg-bg-surface px-3 py-2 text-sm",
|
|
367
364
|
value: Y.routingStrategy,
|
|
368
365
|
onChange: (e) => X({
|
|
369
366
|
...Y,
|
|
370
|
-
routingStrategy:
|
|
367
|
+
routingStrategy: _(e.target.value, P, "SINGLE")
|
|
371
368
|
}),
|
|
372
369
|
children: [
|
|
373
|
-
/* @__PURE__ */
|
|
370
|
+
/* @__PURE__ */ x("option", {
|
|
374
371
|
value: "SINGLE",
|
|
375
372
|
children: L("botlit.botDetail.routing.single", "Single")
|
|
376
373
|
}),
|
|
377
|
-
/* @__PURE__ */
|
|
374
|
+
/* @__PURE__ */ x("option", {
|
|
378
375
|
value: "ROUND_ROBIN",
|
|
379
376
|
children: L("botlit.botDetail.routing.roundRobin", "Round Robin")
|
|
380
377
|
}),
|
|
381
|
-
/* @__PURE__ */
|
|
378
|
+
/* @__PURE__ */ x("option", {
|
|
382
379
|
value: "INTELLIGENT",
|
|
383
380
|
children: L("botlit.botDetail.routing.intelligent", "Intelligent")
|
|
384
381
|
}),
|
|
385
|
-
/* @__PURE__ */
|
|
382
|
+
/* @__PURE__ */ x("option", {
|
|
386
383
|
value: "CUSTOM",
|
|
387
384
|
children: L("botlit.botDetail.routing.custom", "Custom")
|
|
388
385
|
})
|
|
389
386
|
]
|
|
390
387
|
})
|
|
391
388
|
}),
|
|
392
|
-
/* @__PURE__ */
|
|
389
|
+
/* @__PURE__ */ x(m, {
|
|
393
390
|
label: L("botlit.botDetail.form.welcomeMessage", "Welcome Message"),
|
|
394
391
|
htmlFor: "edit-welcome",
|
|
395
|
-
children: /* @__PURE__ */
|
|
392
|
+
children: /* @__PURE__ */ x(g, {
|
|
396
393
|
id: "edit-welcome",
|
|
397
394
|
placeholder: L("botlit.botDetail.form.welcomeMessagePlaceholder", "Welcome message shown to users..."),
|
|
398
395
|
value: Y.welcomeMessage,
|
|
@@ -403,10 +400,10 @@ var I = ({ isNew: _, isEditing: F }) => {
|
|
|
403
400
|
rows: 3
|
|
404
401
|
})
|
|
405
402
|
}),
|
|
406
|
-
/* @__PURE__ */
|
|
403
|
+
/* @__PURE__ */ x(m, {
|
|
407
404
|
label: L("botlit.botDetail.form.fallbackMessage", "Fallback Message"),
|
|
408
405
|
htmlFor: "edit-fallback",
|
|
409
|
-
children: /* @__PURE__ */
|
|
406
|
+
children: /* @__PURE__ */ x(h, {
|
|
410
407
|
id: "edit-fallback",
|
|
411
408
|
placeholder: L("botlit.botDetail.form.fallbackMessagePlaceholder", "Message when agent can't respond..."),
|
|
412
409
|
value: Y.fallbackMessage,
|
|
@@ -416,19 +413,19 @@ var I = ({ isNew: _, isEditing: F }) => {
|
|
|
416
413
|
})
|
|
417
414
|
})
|
|
418
415
|
}),
|
|
419
|
-
/* @__PURE__ */
|
|
416
|
+
/* @__PURE__ */ x(m, {
|
|
420
417
|
label: L("botlit.botDetail.form.defaultAgent", "Default Agent"),
|
|
421
|
-
children: /* @__PURE__ */
|
|
418
|
+
children: /* @__PURE__ */ S("select", {
|
|
422
419
|
className: "flex h-10 w-full rounded-md border border-border-default bg-bg-surface px-3 py-2 text-sm",
|
|
423
420
|
value: Y.defaultAgentId,
|
|
424
421
|
onChange: (e) => X({
|
|
425
422
|
...Y,
|
|
426
423
|
defaultAgentId: e.target.value
|
|
427
424
|
}),
|
|
428
|
-
children: [/* @__PURE__ */
|
|
425
|
+
children: [/* @__PURE__ */ x("option", {
|
|
429
426
|
value: "",
|
|
430
427
|
children: L("botlit.botDetail.form.noDefaultAgent", "No default agent")
|
|
431
|
-
}), W?.map((e) => /* @__PURE__ */
|
|
428
|
+
}), W?.map((e) => /* @__PURE__ */ x("option", {
|
|
432
429
|
value: e.id,
|
|
433
430
|
children: e.name
|
|
434
431
|
}, e.id))]
|
|
@@ -438,77 +435,77 @@ var I = ({ isNew: _, isEditing: F }) => {
|
|
|
438
435
|
})
|
|
439
436
|
})
|
|
440
437
|
});
|
|
441
|
-
let
|
|
438
|
+
let Ne = [
|
|
442
439
|
{
|
|
443
440
|
id: "overview",
|
|
444
441
|
label: L("botlit.botDetail.tabs.overview", "Overview"),
|
|
445
|
-
icon: /* @__PURE__ */
|
|
442
|
+
icon: /* @__PURE__ */ x(_e, { size: 16 })
|
|
446
443
|
},
|
|
447
444
|
{
|
|
448
445
|
id: "workflow",
|
|
449
446
|
label: L("botlit.botDetail.tabs.workflow", "Workflow"),
|
|
450
|
-
icon: /* @__PURE__ */
|
|
447
|
+
icon: /* @__PURE__ */ x(j, { size: 16 })
|
|
451
448
|
},
|
|
452
449
|
{
|
|
453
450
|
id: "routing",
|
|
454
451
|
label: L("botlit.botDetail.tabs.routing", "Routing"),
|
|
455
|
-
icon: /* @__PURE__ */
|
|
452
|
+
icon: /* @__PURE__ */ x(ye, { size: 16 })
|
|
456
453
|
},
|
|
457
454
|
{
|
|
458
455
|
id: "agents",
|
|
459
456
|
label: L("botlit.botDetail.tabs.agents", "Agents"),
|
|
460
|
-
icon: /* @__PURE__ */
|
|
457
|
+
icon: /* @__PURE__ */ x(w, { size: 16 })
|
|
461
458
|
},
|
|
462
459
|
{
|
|
463
460
|
id: "channels",
|
|
464
461
|
label: L("botlit.botDetail.tabs.channels", "Channels"),
|
|
465
|
-
icon: /* @__PURE__ */
|
|
462
|
+
icon: /* @__PURE__ */ x(D, { size: 16 })
|
|
466
463
|
},
|
|
467
464
|
{
|
|
468
465
|
id: "guardrails",
|
|
469
466
|
label: L("botlit.botDetail.tabs.guardrails", "Guardrails"),
|
|
470
|
-
icon: /* @__PURE__ */
|
|
467
|
+
icon: /* @__PURE__ */ x(k, { size: 16 })
|
|
471
468
|
},
|
|
472
469
|
{
|
|
473
470
|
id: "releases",
|
|
474
471
|
label: L("botlit.botDetail.tabs.releases", "Releases"),
|
|
475
|
-
icon: /* @__PURE__ */
|
|
472
|
+
icon: /* @__PURE__ */ x(T, { size: 16 })
|
|
476
473
|
}
|
|
477
474
|
], $ = H.defaultAgentId ? W?.find((e) => e.id === H.defaultAgentId) : null;
|
|
478
|
-
return /* @__PURE__ */
|
|
479
|
-
title: /* @__PURE__ */
|
|
475
|
+
return /* @__PURE__ */ x(a, {
|
|
476
|
+
title: /* @__PURE__ */ S("div", {
|
|
480
477
|
className: "flex items-center gap-3",
|
|
481
478
|
children: [
|
|
482
|
-
/* @__PURE__ */
|
|
479
|
+
/* @__PURE__ */ x(d, {
|
|
483
480
|
variant: "ghost",
|
|
484
481
|
size: "icon",
|
|
485
482
|
onClick: () => z("bots"),
|
|
486
|
-
children: /* @__PURE__ */
|
|
483
|
+
children: /* @__PURE__ */ x(C, { size: 20 })
|
|
487
484
|
}),
|
|
488
|
-
/* @__PURE__ */
|
|
485
|
+
/* @__PURE__ */ x("span", {
|
|
489
486
|
className: "text-3xl",
|
|
490
487
|
children: H.icon
|
|
491
488
|
}),
|
|
492
|
-
/* @__PURE__ */
|
|
489
|
+
/* @__PURE__ */ S("div", { children: [/* @__PURE__ */ S("div", {
|
|
493
490
|
className: "flex items-center gap-2",
|
|
494
491
|
children: [
|
|
495
|
-
/* @__PURE__ */
|
|
496
|
-
/* @__PURE__ */
|
|
497
|
-
/* @__PURE__ */
|
|
492
|
+
/* @__PURE__ */ x("span", { children: H.name }),
|
|
493
|
+
/* @__PURE__ */ x(p, { status: H.status }),
|
|
494
|
+
/* @__PURE__ */ x(f, {
|
|
498
495
|
variant: "outline",
|
|
499
496
|
children: H.slug
|
|
500
497
|
})
|
|
501
498
|
]
|
|
502
|
-
}), /* @__PURE__ */
|
|
499
|
+
}), /* @__PURE__ */ x("p", {
|
|
503
500
|
className: "text-sm font-normal text-text-secondary",
|
|
504
501
|
children: H.description
|
|
505
502
|
})] })
|
|
506
503
|
]
|
|
507
504
|
}),
|
|
508
|
-
actions: /* @__PURE__ */
|
|
505
|
+
actions: /* @__PURE__ */ S("div", {
|
|
509
506
|
className: "flex gap-2",
|
|
510
507
|
children: [
|
|
511
|
-
H.status === "DRAFT" || H.status === "ARCHIVED" ? /* @__PURE__ */
|
|
508
|
+
H.status === "DRAFT" || H.status === "ARCHIVED" ? /* @__PURE__ */ x(d, {
|
|
512
509
|
variant: "default",
|
|
513
510
|
isLoading: K.loading,
|
|
514
511
|
onClick: async () => {
|
|
@@ -517,13 +514,13 @@ var I = ({ isNew: _, isEditing: F }) => {
|
|
|
517
514
|
await G({
|
|
518
515
|
botId: R,
|
|
519
516
|
input: { status: "ACTIVE" }
|
|
520
|
-
}), await U(),
|
|
517
|
+
}), await U(), M.success(`${L("botlit.botDetail.activate.successPrefix", "Bot")} "${H.name}" ${L("botlit.botDetail.activate.successSuffix", "activated")}`);
|
|
521
518
|
} catch (e) {
|
|
522
|
-
|
|
519
|
+
M.error(e instanceof Error ? e.message : L("botlit.botDetail.activate.error", "Failed to activate bot"));
|
|
523
520
|
}
|
|
524
521
|
},
|
|
525
522
|
children: L("botlit.botDetail.actions.activate", "Activate")
|
|
526
|
-
}) : /* @__PURE__ */
|
|
523
|
+
}) : /* @__PURE__ */ x(d, {
|
|
527
524
|
variant: "outline",
|
|
528
525
|
isLoading: K.loading,
|
|
529
526
|
onClick: async () => {
|
|
@@ -532,68 +529,68 @@ var I = ({ isNew: _, isEditing: F }) => {
|
|
|
532
529
|
await G({
|
|
533
530
|
botId: R,
|
|
534
531
|
input: { status: "DRAFT" }
|
|
535
|
-
}), await U(),
|
|
532
|
+
}), await U(), M.success(`${L("botlit.botDetail.deactivate.successPrefix", "Bot")} "${H.name}" ${L("botlit.botDetail.deactivate.successSuffix", "deactivated")}`);
|
|
536
533
|
} catch (e) {
|
|
537
|
-
|
|
534
|
+
M.error(e instanceof Error ? e.message : L("botlit.botDetail.deactivate.error", "Failed to deactivate bot"));
|
|
538
535
|
}
|
|
539
536
|
},
|
|
540
537
|
children: L("botlit.botDetail.actions.deactivate", "Deactivate")
|
|
541
538
|
}),
|
|
542
|
-
/* @__PURE__ */
|
|
539
|
+
/* @__PURE__ */ x(d, {
|
|
543
540
|
variant: "outline",
|
|
544
|
-
leftIcon: /* @__PURE__ */
|
|
541
|
+
leftIcon: /* @__PURE__ */ x(ve, { size: 16 }),
|
|
545
542
|
onClick: () => z(`bots/${R}/edit`),
|
|
546
543
|
children: L("botlit.botDetail.actions.editBot", "Edit Bot")
|
|
547
544
|
}),
|
|
548
|
-
/* @__PURE__ */
|
|
545
|
+
/* @__PURE__ */ x(d, {
|
|
549
546
|
variant: "outline",
|
|
550
|
-
leftIcon: /* @__PURE__ */
|
|
547
|
+
leftIcon: /* @__PURE__ */ x(E, { size: 16 }),
|
|
551
548
|
onClick: () => {
|
|
552
549
|
let e = H?.defaultAgentId;
|
|
553
550
|
z(e ? `chat/${e}` : "chat");
|
|
554
551
|
},
|
|
555
552
|
children: L("botlit.botDetail.actions.testBot", "Test Bot")
|
|
556
553
|
}),
|
|
557
|
-
/* @__PURE__ */
|
|
554
|
+
/* @__PURE__ */ x(d, {
|
|
558
555
|
variant: "destructive",
|
|
559
|
-
leftIcon: /* @__PURE__ */
|
|
560
|
-
isLoading:
|
|
556
|
+
leftIcon: /* @__PURE__ */ x(A, { size: 16 }),
|
|
557
|
+
isLoading: ke.loading,
|
|
561
558
|
onClick: async () => {
|
|
562
559
|
if (R && confirm(`${L("botlit.botDetail.delete.confirmPrefix", "Are you sure you want to delete")} "${H.name}"? ${L("botlit.botDetail.delete.confirmSuffix", "This action cannot be undone.")}`)) try {
|
|
563
|
-
await
|
|
560
|
+
await Oe(R), M.success(`${L("botlit.botDetail.delete.successPrefix", "Bot")} "${H.name}" ${L("botlit.botDetail.delete.successSuffix", "deleted successfully")}`), z("bots");
|
|
564
561
|
} catch (e) {
|
|
565
|
-
|
|
562
|
+
M.error(e instanceof Error ? e.message : L("botlit.botDetail.delete.error", "Failed to delete bot"));
|
|
566
563
|
}
|
|
567
564
|
},
|
|
568
565
|
children: L("botlit.common.delete", "Delete")
|
|
569
566
|
})
|
|
570
567
|
]
|
|
571
568
|
}),
|
|
572
|
-
children: /* @__PURE__ */
|
|
569
|
+
children: /* @__PURE__ */ S("div", {
|
|
573
570
|
className: "space-y-6",
|
|
574
571
|
children: [
|
|
575
|
-
/* @__PURE__ */
|
|
576
|
-
icon: /* @__PURE__ */
|
|
572
|
+
/* @__PURE__ */ x(de, {
|
|
573
|
+
icon: /* @__PURE__ */ x(w, { size: 18 }),
|
|
577
574
|
children: L("botlit.botDetail.purpose", "This is everything that makes up a single bot — the agent that answers, how requests are routed, which channels it is live on, its guardrails and its release history. Use the tabs to wire it up: assign a default agent, connect a channel and activate it so real users can start chatting.")
|
|
578
575
|
}),
|
|
579
|
-
/* @__PURE__ */
|
|
576
|
+
/* @__PURE__ */ x("div", {
|
|
580
577
|
className: "flex gap-1 border-b border-border-subtle overflow-x-auto",
|
|
581
|
-
children:
|
|
578
|
+
children: Ne.map((e) => /* @__PURE__ */ S("button", {
|
|
582
579
|
onClick: () => J(e.id),
|
|
583
|
-
className:
|
|
580
|
+
className: re("flex items-center gap-2 px-4 py-2 text-sm font-medium border-b-2 transition-colors whitespace-nowrap", q === e.id ? "border-primary text-primary" : "border-transparent text-text-secondary hover:text-text-primary"),
|
|
584
581
|
children: [e.icon, e.label]
|
|
585
582
|
}, e.id))
|
|
586
583
|
}),
|
|
587
|
-
q === "overview" && /* @__PURE__ */
|
|
584
|
+
q === "overview" && /* @__PURE__ */ S("div", {
|
|
588
585
|
className: "space-y-6",
|
|
589
|
-
children: [/* @__PURE__ */
|
|
586
|
+
children: [/* @__PURE__ */ x(ue, {
|
|
590
587
|
storageKey: `botlit-bot-${R}`,
|
|
591
588
|
steps: [
|
|
592
589
|
{
|
|
593
590
|
id: "workflow",
|
|
594
591
|
label: L("botlit.botDetail.nextSteps.workflow", "Design the workflow"),
|
|
595
592
|
description: L("botlit.botDetail.nextSteps.workflowDesc", "Lay out what the bot does on the FluidGrids canvas."),
|
|
596
|
-
icon: /* @__PURE__ */
|
|
593
|
+
icon: /* @__PURE__ */ x(j, { size: 16 }),
|
|
597
594
|
onClick: () => J("workflow"),
|
|
598
595
|
done: !!H.workflowId
|
|
599
596
|
},
|
|
@@ -601,7 +598,7 @@ var I = ({ isNew: _, isEditing: F }) => {
|
|
|
601
598
|
id: "agent",
|
|
602
599
|
label: L("botlit.botDetail.nextSteps.agent", "Assign a default agent"),
|
|
603
600
|
description: L("botlit.botDetail.nextSteps.agentDesc", "Choose which agent answers when this bot is messaged."),
|
|
604
|
-
icon: /* @__PURE__ */
|
|
601
|
+
icon: /* @__PURE__ */ x(w, { size: 16 }),
|
|
605
602
|
onClick: () => J("agents"),
|
|
606
603
|
done: !!H.defaultAgentId
|
|
607
604
|
},
|
|
@@ -609,14 +606,14 @@ var I = ({ isNew: _, isEditing: F }) => {
|
|
|
609
606
|
id: "channel",
|
|
610
607
|
label: L("botlit.botDetail.nextSteps.channel", "Connect a channel"),
|
|
611
608
|
description: L("botlit.botDetail.nextSteps.channelDesc", "Put the bot on Slack, a web widget or another channel."),
|
|
612
|
-
icon: /* @__PURE__ */
|
|
609
|
+
icon: /* @__PURE__ */ x(D, { size: 16 }),
|
|
613
610
|
onClick: () => J("channels")
|
|
614
611
|
},
|
|
615
612
|
{
|
|
616
613
|
id: "test",
|
|
617
614
|
label: L("botlit.botDetail.nextSteps.test", "Test the bot"),
|
|
618
615
|
description: L("botlit.botDetail.nextSteps.testDesc", "Send a message to check the experience end to end."),
|
|
619
|
-
icon: /* @__PURE__ */
|
|
616
|
+
icon: /* @__PURE__ */ x(E, { size: 16 }),
|
|
620
617
|
onClick: () => {
|
|
621
618
|
let e = H?.defaultAgentId;
|
|
622
619
|
z(e ? `chat/${e}` : "chat");
|
|
@@ -626,108 +623,108 @@ var I = ({ isNew: _, isEditing: F }) => {
|
|
|
626
623
|
id: "activate",
|
|
627
624
|
label: L("botlit.botDetail.nextSteps.activate", "Activate the bot"),
|
|
628
625
|
description: L("botlit.botDetail.nextSteps.activateDesc", "Make it live so it starts handling conversations."),
|
|
629
|
-
icon: /* @__PURE__ */
|
|
626
|
+
icon: /* @__PURE__ */ x(k, { size: 16 }),
|
|
630
627
|
onClick: () => z(`bots/${R}/edit`),
|
|
631
628
|
done: H.status === "ACTIVE"
|
|
632
629
|
}
|
|
633
630
|
]
|
|
634
|
-
}), /* @__PURE__ */
|
|
631
|
+
}), /* @__PURE__ */ S("div", {
|
|
635
632
|
className: "grid grid-cols-1 lg:grid-cols-3 gap-6",
|
|
636
633
|
children: [
|
|
637
|
-
/* @__PURE__ */
|
|
634
|
+
/* @__PURE__ */ S(o, { children: [/* @__PURE__ */ x(l, { children: /* @__PURE__ */ x(u, { children: "Details" }) }), /* @__PURE__ */ S(s, {
|
|
638
635
|
className: "space-y-4",
|
|
639
636
|
children: [
|
|
640
|
-
/* @__PURE__ */
|
|
637
|
+
/* @__PURE__ */ S("div", { children: [/* @__PURE__ */ x("p", {
|
|
641
638
|
className: "text-sm text-text-secondary",
|
|
642
639
|
children: "Status"
|
|
643
|
-
}), /* @__PURE__ */
|
|
644
|
-
/* @__PURE__ */
|
|
640
|
+
}), /* @__PURE__ */ x(p, { status: H.status })] }),
|
|
641
|
+
/* @__PURE__ */ S("div", { children: [/* @__PURE__ */ x("p", {
|
|
645
642
|
className: "text-sm text-text-secondary",
|
|
646
643
|
children: "Visibility"
|
|
647
|
-
}), /* @__PURE__ */
|
|
644
|
+
}), /* @__PURE__ */ x(f, {
|
|
648
645
|
variant: "outline",
|
|
649
646
|
children: H.visibility
|
|
650
647
|
})] }),
|
|
651
|
-
/* @__PURE__ */
|
|
648
|
+
/* @__PURE__ */ S("div", { children: [/* @__PURE__ */ x("p", {
|
|
652
649
|
className: "text-sm text-text-secondary",
|
|
653
650
|
children: "Routing Strategy"
|
|
654
|
-
}), /* @__PURE__ */
|
|
651
|
+
}), /* @__PURE__ */ x(f, {
|
|
655
652
|
variant: "outline",
|
|
656
653
|
children: H.routingStrategy
|
|
657
654
|
})] }),
|
|
658
|
-
/* @__PURE__ */
|
|
655
|
+
/* @__PURE__ */ S("div", { children: [/* @__PURE__ */ x("p", {
|
|
659
656
|
className: "text-sm text-text-secondary",
|
|
660
657
|
children: "Default Agent"
|
|
661
|
-
}), /* @__PURE__ */
|
|
658
|
+
}), /* @__PURE__ */ x("p", {
|
|
662
659
|
className: "font-medium",
|
|
663
660
|
children: H.defaultAgentId ? "1 agent assigned" : "No agents"
|
|
664
661
|
})] }),
|
|
665
|
-
/* @__PURE__ */
|
|
662
|
+
/* @__PURE__ */ S("div", { children: [/* @__PURE__ */ x("p", {
|
|
666
663
|
className: "text-sm text-text-secondary",
|
|
667
664
|
children: "Channels"
|
|
668
|
-
}), /* @__PURE__ */
|
|
665
|
+
}), /* @__PURE__ */ x("p", {
|
|
669
666
|
className: "font-medium",
|
|
670
667
|
children: "0 channels"
|
|
671
668
|
})] }),
|
|
672
|
-
/* @__PURE__ */
|
|
669
|
+
/* @__PURE__ */ S("div", { children: [/* @__PURE__ */ x("p", {
|
|
673
670
|
className: "text-sm text-text-secondary",
|
|
674
671
|
children: "Created"
|
|
675
|
-
}), /* @__PURE__ */
|
|
672
|
+
}), /* @__PURE__ */ x("p", {
|
|
676
673
|
className: "font-medium",
|
|
677
|
-
children:
|
|
674
|
+
children: i(H.createdAt)
|
|
678
675
|
})] }),
|
|
679
|
-
/* @__PURE__ */
|
|
676
|
+
/* @__PURE__ */ S("div", { children: [/* @__PURE__ */ x("p", {
|
|
680
677
|
className: "text-sm text-text-secondary",
|
|
681
678
|
children: "Executions"
|
|
682
|
-
}), /* @__PURE__ */
|
|
679
|
+
}), /* @__PURE__ */ x("p", {
|
|
683
680
|
className: "font-medium",
|
|
684
|
-
children:
|
|
681
|
+
children: ie(H.executionCount)
|
|
685
682
|
})] })
|
|
686
683
|
]
|
|
687
684
|
})] }),
|
|
688
|
-
/* @__PURE__ */
|
|
685
|
+
/* @__PURE__ */ S(le, {
|
|
689
686
|
treatment: "glass",
|
|
690
687
|
glow: !0,
|
|
691
688
|
className: "lg:col-span-2 p-6",
|
|
692
|
-
children: [/* @__PURE__ */
|
|
689
|
+
children: [/* @__PURE__ */ S("div", {
|
|
693
690
|
className: "mb-4 flex flex-row items-center justify-between",
|
|
694
|
-
children: [/* @__PURE__ */
|
|
691
|
+
children: [/* @__PURE__ */ S("div", { children: [/* @__PURE__ */ x("h3", {
|
|
695
692
|
className: "text-lg font-semibold tracking-tight text-text-primary",
|
|
696
693
|
children: "Default Agent"
|
|
697
|
-
}), /* @__PURE__ */
|
|
694
|
+
}), /* @__PURE__ */ x("p", {
|
|
698
695
|
className: "text-sm text-text-secondary",
|
|
699
696
|
children: "Agent configured for this bot"
|
|
700
|
-
})] }), /* @__PURE__ */
|
|
697
|
+
})] }), /* @__PURE__ */ x(d, {
|
|
701
698
|
size: "sm",
|
|
702
699
|
variant: "outline",
|
|
703
700
|
onClick: () => J("agents"),
|
|
704
701
|
children: "Manage"
|
|
705
702
|
})]
|
|
706
|
-
}), /* @__PURE__ */
|
|
703
|
+
}), /* @__PURE__ */ x("div", { children: $ ? /* @__PURE__ */ x("div", {
|
|
707
704
|
className: "space-y-3",
|
|
708
|
-
children: /* @__PURE__ */
|
|
709
|
-
to:
|
|
705
|
+
children: /* @__PURE__ */ S(pe, {
|
|
706
|
+
to: we(`agents/${$.id}`),
|
|
710
707
|
className: "flex items-center justify-between p-3 rounded-lg border border-border-subtle hover:bg-accent transition-colors",
|
|
711
|
-
children: [/* @__PURE__ */
|
|
708
|
+
children: [/* @__PURE__ */ S("div", {
|
|
712
709
|
className: "flex items-center gap-3",
|
|
713
|
-
children: [/* @__PURE__ */
|
|
710
|
+
children: [/* @__PURE__ */ x("span", {
|
|
714
711
|
className: "text-2xl",
|
|
715
712
|
children: "🤖"
|
|
716
|
-
}), /* @__PURE__ */
|
|
713
|
+
}), /* @__PURE__ */ S("div", { children: [/* @__PURE__ */ x("p", {
|
|
717
714
|
className: "font-medium text-text-primary",
|
|
718
715
|
children: $.name
|
|
719
|
-
}), /* @__PURE__ */
|
|
716
|
+
}), /* @__PURE__ */ x("p", {
|
|
720
717
|
className: "text-xs text-text-secondary",
|
|
721
718
|
children: "Default Agent"
|
|
722
719
|
})] })]
|
|
723
|
-
}), /* @__PURE__ */
|
|
720
|
+
}), /* @__PURE__ */ x(p, { status: $.status })]
|
|
724
721
|
})
|
|
725
|
-
}) : /* @__PURE__ */
|
|
722
|
+
}) : /* @__PURE__ */ S("div", {
|
|
726
723
|
className: "text-center py-8 text-text-secondary",
|
|
727
724
|
children: [
|
|
728
|
-
/* @__PURE__ */
|
|
729
|
-
/* @__PURE__ */
|
|
730
|
-
/* @__PURE__ */
|
|
725
|
+
/* @__PURE__ */ x(w, { className: "h-8 w-8 mx-auto mb-2 opacity-50" }),
|
|
726
|
+
/* @__PURE__ */ x("p", { children: "No default agent assigned" }),
|
|
727
|
+
/* @__PURE__ */ x(d, {
|
|
731
728
|
size: "sm",
|
|
732
729
|
className: "mt-3",
|
|
733
730
|
onClick: () => J("agents"),
|
|
@@ -736,11 +733,11 @@ var I = ({ isNew: _, isEditing: F }) => {
|
|
|
736
733
|
]
|
|
737
734
|
}) })]
|
|
738
735
|
}),
|
|
739
|
-
(H.tagIds || []).length > 0 && /* @__PURE__ */
|
|
736
|
+
(H.tagIds || []).length > 0 && /* @__PURE__ */ S(o, {
|
|
740
737
|
className: "lg:col-span-3",
|
|
741
|
-
children: [/* @__PURE__ */
|
|
738
|
+
children: [/* @__PURE__ */ x(l, { children: /* @__PURE__ */ x(u, { children: "Tags" }) }), /* @__PURE__ */ x(s, { children: /* @__PURE__ */ x("div", {
|
|
742
739
|
className: "flex flex-wrap gap-2",
|
|
743
|
-
children: (H.tagIds || []).map((e) => /* @__PURE__ */
|
|
740
|
+
children: (H.tagIds || []).map((e) => /* @__PURE__ */ x(f, {
|
|
744
741
|
variant: "outline",
|
|
745
742
|
children: e
|
|
746
743
|
}, e))
|
|
@@ -749,9 +746,9 @@ var I = ({ isNew: _, isEditing: F }) => {
|
|
|
749
746
|
]
|
|
750
747
|
})]
|
|
751
748
|
}),
|
|
752
|
-
q === "workflow" && R && /* @__PURE__ */
|
|
753
|
-
fallback: /* @__PURE__ */
|
|
754
|
-
children: /* @__PURE__ */
|
|
749
|
+
q === "workflow" && R && /* @__PURE__ */ x(ce, {
|
|
750
|
+
fallback: /* @__PURE__ */ x("div", { className: "h-64 bg-bg-sunken motion-safe:animate-vc-shimmer rounded-lg" }),
|
|
751
|
+
children: /* @__PURE__ */ x(N, {
|
|
755
752
|
botId: R,
|
|
756
753
|
botName: H.name,
|
|
757
754
|
workflowId: H.workflowId,
|
|
@@ -760,54 +757,54 @@ var I = ({ isNew: _, isEditing: F }) => {
|
|
|
760
757
|
}
|
|
761
758
|
})
|
|
762
759
|
}),
|
|
763
|
-
q === "routing" && /* @__PURE__ */
|
|
760
|
+
q === "routing" && /* @__PURE__ */ S("div", {
|
|
764
761
|
className: "space-y-6",
|
|
765
|
-
children: [/* @__PURE__ */
|
|
762
|
+
children: [/* @__PURE__ */ S(o, { children: [/* @__PURE__ */ S(l, { children: [/* @__PURE__ */ x(u, { children: "Routing Configuration" }), /* @__PURE__ */ x(c, { children: "How requests are routed to agents" })] }), /* @__PURE__ */ x(s, {
|
|
766
763
|
className: "space-y-4",
|
|
767
|
-
children: /* @__PURE__ */
|
|
764
|
+
children: /* @__PURE__ */ S("div", {
|
|
768
765
|
className: "grid grid-cols-2 gap-4",
|
|
769
|
-
children: [/* @__PURE__ */
|
|
766
|
+
children: [/* @__PURE__ */ S("div", { children: [/* @__PURE__ */ x("p", {
|
|
770
767
|
className: "text-sm text-text-secondary",
|
|
771
768
|
children: "Strategy"
|
|
772
|
-
}), /* @__PURE__ */
|
|
769
|
+
}), /* @__PURE__ */ x(f, {
|
|
773
770
|
variant: "outline",
|
|
774
771
|
className: "mt-1",
|
|
775
772
|
children: H.routingStrategy
|
|
776
|
-
})] }), H.defaultAgentId && /* @__PURE__ */
|
|
773
|
+
})] }), H.defaultAgentId && /* @__PURE__ */ S("div", { children: [/* @__PURE__ */ x("p", {
|
|
777
774
|
className: "text-sm text-text-secondary",
|
|
778
775
|
children: "Default Agent"
|
|
779
|
-
}), /* @__PURE__ */
|
|
776
|
+
}), /* @__PURE__ */ x("p", {
|
|
780
777
|
className: "font-mono text-sm mt-1",
|
|
781
778
|
children: H.defaultAgentId
|
|
782
779
|
})] })]
|
|
783
780
|
})
|
|
784
|
-
})] }), /* @__PURE__ */
|
|
781
|
+
})] }), /* @__PURE__ */ S(o, { children: [/* @__PURE__ */ S(l, { children: [/* @__PURE__ */ x(u, { children: "Routing Rules" }), /* @__PURE__ */ x(c, { children: "No routing rules configured" })] }), /* @__PURE__ */ x(s, { children: /* @__PURE__ */ x("p", {
|
|
785
782
|
className: "text-text-secondary",
|
|
786
783
|
children: "No routing rules configured. Routing rules will be available in a future update."
|
|
787
784
|
}) })] })]
|
|
788
785
|
}),
|
|
789
|
-
q === "agents" && /* @__PURE__ */
|
|
786
|
+
q === "agents" && /* @__PURE__ */ S(o, { children: [/* @__PURE__ */ S(l, { children: [/* @__PURE__ */ x(u, { children: "Default Agent" }), /* @__PURE__ */ x(c, { children: "Select the default agent for this bot" })] }), /* @__PURE__ */ S(s, {
|
|
790
787
|
className: "space-y-4",
|
|
791
788
|
children: [
|
|
792
|
-
$ && /* @__PURE__ */
|
|
789
|
+
$ && /* @__PURE__ */ S("div", {
|
|
793
790
|
className: "flex items-center justify-between p-4 border border-border-subtle rounded-lg",
|
|
794
|
-
children: [/* @__PURE__ */
|
|
791
|
+
children: [/* @__PURE__ */ S("div", {
|
|
795
792
|
className: "flex items-center gap-3",
|
|
796
|
-
children: [/* @__PURE__ */
|
|
793
|
+
children: [/* @__PURE__ */ x("span", {
|
|
797
794
|
className: "text-2xl",
|
|
798
795
|
children: "🤖"
|
|
799
|
-
}), /* @__PURE__ */
|
|
796
|
+
}), /* @__PURE__ */ S("div", { children: [/* @__PURE__ */ x("p", {
|
|
800
797
|
className: "font-medium",
|
|
801
798
|
children: $.name
|
|
802
|
-
}), /* @__PURE__ */
|
|
799
|
+
}), /* @__PURE__ */ x(f, {
|
|
803
800
|
variant: "success",
|
|
804
801
|
children: "Default"
|
|
805
802
|
})] })]
|
|
806
|
-
}), /* @__PURE__ */
|
|
803
|
+
}), /* @__PURE__ */ x(p, { status: $.status })]
|
|
807
804
|
}),
|
|
808
|
-
/* @__PURE__ */
|
|
805
|
+
/* @__PURE__ */ x("div", {
|
|
809
806
|
className: "flex items-center gap-3",
|
|
810
|
-
children: /* @__PURE__ */
|
|
807
|
+
children: /* @__PURE__ */ S("select", {
|
|
811
808
|
className: "flex h-10 flex-1 rounded-md border border-border-default bg-bg-surface px-3 py-2 text-sm",
|
|
812
809
|
value: H.defaultAgentId || "",
|
|
813
810
|
onChange: async (e) => {
|
|
@@ -815,48 +812,48 @@ var I = ({ isNew: _, isEditing: F }) => {
|
|
|
815
812
|
await G({
|
|
816
813
|
botId: R,
|
|
817
814
|
input: { defaultAgentId: e.target.value || null }
|
|
818
|
-
}),
|
|
815
|
+
}), M.success(e.target.value ? "Default agent assigned" : "Default agent removed");
|
|
819
816
|
} catch (e) {
|
|
820
817
|
let t = e instanceof Error ? e.message : "Failed to assign agent";
|
|
821
|
-
|
|
818
|
+
M.error(t);
|
|
822
819
|
}
|
|
823
820
|
},
|
|
824
|
-
children: [/* @__PURE__ */
|
|
821
|
+
children: [/* @__PURE__ */ x("option", {
|
|
825
822
|
value: "",
|
|
826
823
|
children: "No default agent"
|
|
827
|
-
}), W?.map((e) => /* @__PURE__ */
|
|
824
|
+
}), W?.map((e) => /* @__PURE__ */ x("option", {
|
|
828
825
|
value: e.id,
|
|
829
826
|
children: e.name
|
|
830
827
|
}, e.id))]
|
|
831
828
|
})
|
|
832
829
|
}),
|
|
833
|
-
!$ && !W?.length && /* @__PURE__ */
|
|
830
|
+
!$ && !W?.length && /* @__PURE__ */ S("div", {
|
|
834
831
|
className: "text-center py-8 text-text-secondary",
|
|
835
|
-
children: [/* @__PURE__ */
|
|
832
|
+
children: [/* @__PURE__ */ x(w, { className: "h-8 w-8 mx-auto mb-2 opacity-50" }), /* @__PURE__ */ x("p", { children: "No agents available. Create an agent first." })]
|
|
836
833
|
})
|
|
837
834
|
]
|
|
838
835
|
})] }),
|
|
839
|
-
q === "channels" && R && /* @__PURE__ */
|
|
836
|
+
q === "channels" && R && /* @__PURE__ */ x(se, {
|
|
840
837
|
botId: R,
|
|
841
838
|
botName: H.name
|
|
842
839
|
}),
|
|
843
|
-
q === "guardrails" && /* @__PURE__ */
|
|
840
|
+
q === "guardrails" && /* @__PURE__ */ S(o, { children: [/* @__PURE__ */ S(l, { children: [/* @__PURE__ */ x(u, { children: "Policy Bindings" }), /* @__PURE__ */ x(c, { children: "Guardrails and policies attached to this bot" })] }), /* @__PURE__ */ x(s, { children: /* @__PURE__ */ S("div", {
|
|
844
841
|
className: "text-center py-8 text-text-secondary",
|
|
845
842
|
children: [
|
|
846
|
-
/* @__PURE__ */
|
|
847
|
-
/* @__PURE__ */
|
|
848
|
-
/* @__PURE__ */
|
|
843
|
+
/* @__PURE__ */ x(k, { className: "h-8 w-8 mx-auto mb-2 opacity-50" }),
|
|
844
|
+
/* @__PURE__ */ x("p", { children: "Not configured" }),
|
|
845
|
+
/* @__PURE__ */ x("p", {
|
|
849
846
|
className: "text-sm mt-1",
|
|
850
847
|
children: "Policy bindings will be available in a future update."
|
|
851
848
|
})
|
|
852
849
|
]
|
|
853
850
|
}) })] }),
|
|
854
|
-
q === "releases" && /* @__PURE__ */
|
|
851
|
+
q === "releases" && /* @__PURE__ */ S(o, { children: [/* @__PURE__ */ S(l, { children: [/* @__PURE__ */ x(u, { children: "Release Tracks" }), /* @__PURE__ */ x(c, { children: "Version deployments across environments" })] }), /* @__PURE__ */ x(s, { children: /* @__PURE__ */ S("div", {
|
|
855
852
|
className: "text-center py-8 text-text-secondary",
|
|
856
853
|
children: [
|
|
857
|
-
/* @__PURE__ */
|
|
858
|
-
/* @__PURE__ */
|
|
859
|
-
/* @__PURE__ */
|
|
854
|
+
/* @__PURE__ */ x(T, { className: "h-8 w-8 mx-auto mb-2 opacity-50" }),
|
|
855
|
+
/* @__PURE__ */ x("p", { children: "Not configured" }),
|
|
856
|
+
/* @__PURE__ */ x("p", {
|
|
860
857
|
className: "text-sm mt-1",
|
|
861
858
|
children: "Release tracks will be available in a future update."
|
|
862
859
|
})
|
|
@@ -867,6 +864,6 @@ var I = ({ isNew: _, isEditing: F }) => {
|
|
|
867
864
|
});
|
|
868
865
|
};
|
|
869
866
|
//#endregion
|
|
870
|
-
export {
|
|
867
|
+
export { L as BotDetailPage };
|
|
871
868
|
|
|
872
869
|
//# sourceMappingURL=BotDetailPage.js.map
|