@yuku123/z-team-component 0.2.104 → 0.2.105
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/{ChangeLogView-DG-ogBff.js → ChangeLogView-B0ML82u0.js} +1 -1
- package/dist/{ComponentDoc-BW1SyDxk.js → ComponentDoc-C_289lsE.js} +12 -12
- package/dist/{InvitationManagementPage-hYvoPEcm.js → InvitationManagementPage-D2ezz4ZQ.js} +1 -1
- package/dist/{OnboardingPage-KDp-DrzY.js → OnboardingPage-BXsJ-kcJ.js} +2 -2
- package/dist/{ScheduledTasks-CErSDgyW.js → ScheduledTasks-Cn8BsDkN.js} +6 -6
- package/dist/{SystemShell-DvrY4Bl7.js → SystemShell-gcfNlt2L.js} +4 -4
- package/dist/{admin-logs-uPnnclwN.js → admin-logs-B6K1DwRL.js} +5 -5
- package/dist/api-BdP8mK8v.js +101 -0
- package/dist/{api-B__qdRIf.js → api-DxSgE7qw.js} +1 -1
- package/dist/{createWorkspaceWsHandler-BXbn5-Ft.js → createWorkspaceWsHandler-DcNA1pfi.js} +3 -3
- package/dist/{index-D-xPVrY3.js → index-54iTaRVW.js} +1 -1
- package/dist/{index-0smeCTnr.js → index-BCw3Oxp1.js} +1255 -1255
- package/dist/{index-ByhCWenF.js → index-BDq0ofl2.js} +102 -188
- package/dist/{index-DtHoMz1H.js → index-BN-o5nZM.js} +1 -1
- package/dist/{index-BwJPAN8f.js → index-Bf1K9zpk.js} +19 -19
- package/dist/{index-Cb88Xdh4.js → index-BfMFQ6RD.js} +3 -3
- package/dist/{index-DIFIvVWE.js → index-C-8n6xxK.js} +2 -2
- package/dist/{index-aI2EXKED.js → index-C8m8s-SU.js} +26 -26
- package/dist/{index-BK3YDeXH.js → index-CXJXSmhB.js} +6 -6
- package/dist/{index-BnJ8UEeZ.js → index-CdugR2_4.js} +3 -3
- package/dist/{index-YVtm1SRy.js → index-CeCsncoT.js} +28 -28
- package/dist/{index-CkWKJORv.js → index-CgCB0-yK.js} +1 -1
- package/dist/{index-DcurzowX.js → index-Cjddvrij.js} +4 -4
- package/dist/{index-q_TPea69.js → index-D487Inba.js} +15 -15
- package/dist/{index-BOJm25by.js → index-DK71mfJn.js} +1 -1
- package/dist/{index-C9fGup9t.js → index-DLHcoHS9.js} +3 -3
- package/dist/{index-Cih0yoxc.js → index-DUiFk01c.js} +5 -5
- package/dist/{index-2isWwv1X.js → index-DgN13A-E.js} +9 -9
- package/dist/{index-DOgCfVB2.js → index-DpLamT1r.js} +2 -2
- package/dist/{index-DBnH-lRh.js → index-DszzQwsc.js} +1 -1
- package/dist/index-HJ3Kt-NT.js +358 -0
- package/dist/{index-BC8f-JP9.js → index-Nj-dlFKY.js} +3 -3
- package/dist/{index-C2_tfpEj.js → index-ZuYJoo9E.js} +2 -2
- package/dist/{index-DAGa9v8r.js → index-etyS3HY2.js} +2 -2
- package/dist/{index-CsaGecGX.js → index-jIh52A4c.js} +6 -6
- package/dist/index.js +1 -1
- package/dist/{instance-pdQ_wAhB.js → instance-p-ezisoS.js} +5 -5
- package/dist/{menuPermission-CCQjJVXg.js → menuPermission-u3Gd_c8S.js} +11 -11
- package/dist/pages.js +1 -1
- package/dist/{send-default-agent-team-message-BzeR4ahf.js → send-default-agent-team-message-BhIV6T6O.js} +1 -1
- package/dist/{sso-user-DI7oiDdc.js → sso-user-Ib1jhF7t.js} +1 -1
- package/dist/{training-Bz7Sr5yC.js → training-D3Uy5K_M.js} +1 -1
- package/dist/{webide-NcHLDiSn.js → webide-BGQnArzY.js} +3 -3
- package/dist/z-team-component.css +1 -1
- package/package.json +1 -1
|
@@ -1,178 +1,92 @@
|
|
|
1
|
-
import { jsxs as
|
|
2
|
-
import { useState as
|
|
3
|
-
import {
|
|
1
|
+
import { jsxs as t, jsx as n, Fragment as _ } from "react/jsx-runtime";
|
|
2
|
+
import { useState as i, useRef as D, useCallback as B, useEffect as N } from "react";
|
|
3
|
+
import { u as j } from "./ComponentDoc-C_289lsE.js";
|
|
4
4
|
/* empty css */
|
|
5
|
-
|
|
6
|
-
const n = await o.text().catch(() => "");
|
|
7
|
-
let t = {};
|
|
8
|
-
if (n)
|
|
9
|
-
try {
|
|
10
|
-
t = JSON.parse(n);
|
|
11
|
-
} catch {
|
|
12
|
-
if (!o.ok) throw new Error(s);
|
|
13
|
-
return n;
|
|
14
|
-
}
|
|
15
|
-
if (typeof t.success == "boolean") {
|
|
16
|
-
if (t.success)
|
|
17
|
-
return U(t.data !== void 0 ? t.data : !0);
|
|
18
|
-
throw new Error(t.message || s);
|
|
19
|
-
}
|
|
20
|
-
if (!o.ok) throw new Error(s);
|
|
21
|
-
return U(t);
|
|
22
|
-
}
|
|
23
|
-
const m = O;
|
|
24
|
-
async function q(o, s) {
|
|
25
|
-
const n = s ? `?token=${encodeURIComponent(s)}` : "", t = { ...o, extend_params: { skip_init_task: "true" } }, r = await fetch(`${m}/scenario-instances${n}`, {
|
|
26
|
-
method: "POST",
|
|
27
|
-
credentials: "include",
|
|
28
|
-
headers: {
|
|
29
|
-
Accept: "application/json",
|
|
30
|
-
"Content-Type": "application/json",
|
|
31
|
-
"project-env": "local"
|
|
32
|
-
},
|
|
33
|
-
body: JSON.stringify(t)
|
|
34
|
-
});
|
|
35
|
-
return y(r, "Failed to create scenario instance");
|
|
36
|
-
}
|
|
37
|
-
async function K(o) {
|
|
38
|
-
const s = o ? `?token=${encodeURIComponent(o)}` : "", n = await fetch(`${m}/scenario-instances${s}`, {
|
|
39
|
-
credentials: "include",
|
|
40
|
-
headers: {
|
|
41
|
-
Accept: "application/json",
|
|
42
|
-
"project-env": "local"
|
|
43
|
-
}
|
|
44
|
-
});
|
|
45
|
-
return y(n, "Failed to list scenario instances");
|
|
46
|
-
}
|
|
47
|
-
async function G(o, s, n) {
|
|
48
|
-
const t = n ? `?token=${encodeURIComponent(n)}` : "", r = await fetch(
|
|
49
|
-
`${m}/scenario-instances/${o}/messages${t}`,
|
|
50
|
-
{
|
|
51
|
-
method: "POST",
|
|
52
|
-
credentials: "include",
|
|
53
|
-
headers: {
|
|
54
|
-
Accept: "application/json",
|
|
55
|
-
"Content-Type": "application/json",
|
|
56
|
-
"project-env": "local"
|
|
57
|
-
},
|
|
58
|
-
body: JSON.stringify(s)
|
|
59
|
-
}
|
|
60
|
-
);
|
|
61
|
-
return y(r, "Failed to send message");
|
|
62
|
-
}
|
|
63
|
-
async function _(o, s = 50, n, t) {
|
|
64
|
-
const r = new URLSearchParams({ limit: String(s) });
|
|
65
|
-
t && r.set("token", t);
|
|
66
|
-
const h = await fetch(
|
|
67
|
-
`${m}/scenario-instances/${o}/messages?${r}`,
|
|
68
|
-
{
|
|
69
|
-
credentials: "include",
|
|
70
|
-
headers: {
|
|
71
|
-
Accept: "application/json",
|
|
72
|
-
"project-env": "local"
|
|
73
|
-
}
|
|
74
|
-
}
|
|
75
|
-
);
|
|
76
|
-
return y(h, "Failed to list messages");
|
|
77
|
-
}
|
|
78
|
-
async function J(o, s) {
|
|
79
|
-
const n = s ? `?token=${encodeURIComponent(s)}` : "", t = await fetch(
|
|
80
|
-
// 后端成员列表在 /team(TeamController),没有 /members
|
|
81
|
-
`${m}/scenario-instances/${o}/team${n}`,
|
|
82
|
-
{
|
|
83
|
-
credentials: "include",
|
|
84
|
-
headers: {
|
|
85
|
-
Accept: "application/json",
|
|
86
|
-
"project-env": "local"
|
|
87
|
-
}
|
|
88
|
-
}
|
|
89
|
-
);
|
|
90
|
-
return y(t, "Failed to list members");
|
|
91
|
-
}
|
|
5
|
+
import { l as F, c as G, a as z, b as K, p as W } from "./api-BdP8mK8v.js";
|
|
92
6
|
const L = "dev_brain_scenario";
|
|
93
|
-
function
|
|
7
|
+
function q() {
|
|
94
8
|
var M;
|
|
95
|
-
const [
|
|
9
|
+
const [y, E] = i([]), [r, R] = i(
|
|
96
10
|
null
|
|
97
|
-
), [
|
|
11
|
+
), [d, g] = i([]), [c, H] = i([]), [m, h] = i(""), [O, u] = i(!1), [f, x] = i(!1), [b, v] = i(""), S = D(null), { token: s } = j(), w = B(() => {
|
|
98
12
|
var e;
|
|
99
|
-
(e =
|
|
13
|
+
(e = S.current) == null || e.scrollIntoView({ behavior: "smooth" });
|
|
100
14
|
}, []);
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
}, [
|
|
104
|
-
|
|
15
|
+
N(() => {
|
|
16
|
+
w();
|
|
17
|
+
}, [d, w]), N(() => {
|
|
18
|
+
T();
|
|
105
19
|
}, []);
|
|
106
|
-
const
|
|
20
|
+
const T = async () => {
|
|
107
21
|
try {
|
|
108
|
-
const e = await
|
|
109
|
-
|
|
22
|
+
const e = await F(s || void 0);
|
|
23
|
+
E(e || []);
|
|
110
24
|
} catch (e) {
|
|
111
25
|
console.error("Failed to load instances:", e);
|
|
112
26
|
}
|
|
113
|
-
},
|
|
114
|
-
const e =
|
|
27
|
+
}, A = async () => {
|
|
28
|
+
const e = b.trim();
|
|
115
29
|
if (e) {
|
|
116
|
-
|
|
30
|
+
x(!0);
|
|
117
31
|
try {
|
|
118
|
-
const
|
|
32
|
+
const o = await G(
|
|
119
33
|
{ scenario_code: L, name: e },
|
|
120
|
-
|
|
34
|
+
s || void 0
|
|
121
35
|
);
|
|
122
|
-
|
|
123
|
-
} catch (
|
|
124
|
-
alert(
|
|
36
|
+
v(""), await T(), k(o);
|
|
37
|
+
} catch (o) {
|
|
38
|
+
alert(o instanceof Error ? o.message : "Create failed");
|
|
125
39
|
} finally {
|
|
126
|
-
|
|
40
|
+
x(!1);
|
|
127
41
|
}
|
|
128
42
|
}
|
|
129
|
-
},
|
|
130
|
-
|
|
43
|
+
}, k = async (e) => {
|
|
44
|
+
R(e), u(!0);
|
|
131
45
|
try {
|
|
132
|
-
const [
|
|
133
|
-
|
|
134
|
-
|
|
46
|
+
const [o, l] = await Promise.all([
|
|
47
|
+
z(e.id, 50, void 0, s || void 0),
|
|
48
|
+
K(e.id, s || void 0)
|
|
135
49
|
]);
|
|
136
|
-
|
|
137
|
-
} catch (
|
|
138
|
-
console.error("Failed to load instance data:",
|
|
50
|
+
g(o || []), H(l || []);
|
|
51
|
+
} catch (o) {
|
|
52
|
+
console.error("Failed to load instance data:", o);
|
|
139
53
|
} finally {
|
|
140
|
-
|
|
54
|
+
u(!1);
|
|
141
55
|
}
|
|
142
|
-
},
|
|
143
|
-
const e =
|
|
144
|
-
if (!e || !
|
|
145
|
-
const
|
|
146
|
-
let
|
|
147
|
-
for (const
|
|
148
|
-
if (e.includes(`@${
|
|
149
|
-
|
|
56
|
+
}, I = async () => {
|
|
57
|
+
const e = m.trim();
|
|
58
|
+
if (!e || !r) return;
|
|
59
|
+
const o = c.filter((a) => a.memberType === "AGENT");
|
|
60
|
+
let l, C = "TEXT";
|
|
61
|
+
for (const a of o)
|
|
62
|
+
if (e.includes(`@${a.displayName}`)) {
|
|
63
|
+
l = String(a.id), C = "AT_AGENT";
|
|
150
64
|
break;
|
|
151
65
|
}
|
|
152
|
-
|
|
66
|
+
h("");
|
|
153
67
|
try {
|
|
154
|
-
await
|
|
155
|
-
|
|
68
|
+
await W(
|
|
69
|
+
r.id,
|
|
156
70
|
{
|
|
157
71
|
content: e,
|
|
158
|
-
message_type:
|
|
159
|
-
...
|
|
72
|
+
message_type: C,
|
|
73
|
+
...l ? { at_agent_ref_id: l } : {}
|
|
160
74
|
},
|
|
161
|
-
|
|
75
|
+
s || void 0
|
|
162
76
|
);
|
|
163
|
-
const
|
|
164
|
-
|
|
77
|
+
const a = await z(
|
|
78
|
+
r.id,
|
|
165
79
|
50,
|
|
166
80
|
void 0,
|
|
167
|
-
|
|
81
|
+
s || void 0
|
|
168
82
|
);
|
|
169
|
-
|
|
170
|
-
} catch (
|
|
171
|
-
alert(
|
|
83
|
+
g(a || []);
|
|
84
|
+
} catch (a) {
|
|
85
|
+
alert(a instanceof Error ? a.message : "Send failed");
|
|
172
86
|
}
|
|
173
|
-
},
|
|
174
|
-
return /* @__PURE__ */
|
|
175
|
-
/* @__PURE__ */
|
|
87
|
+
}, p = c.filter((e) => e.memberType === "AGENT"), U = c.filter((e) => e.memberType === "HUMAN");
|
|
88
|
+
return /* @__PURE__ */ t("div", { style: { display: "flex", height: "100vh", fontFamily: "sans-serif" }, children: [
|
|
89
|
+
/* @__PURE__ */ t(
|
|
176
90
|
"div",
|
|
177
91
|
{
|
|
178
92
|
style: {
|
|
@@ -183,10 +97,10 @@ function Z() {
|
|
|
183
97
|
background: "#fafafa"
|
|
184
98
|
},
|
|
185
99
|
children: [
|
|
186
|
-
/* @__PURE__ */
|
|
187
|
-
/* @__PURE__ */
|
|
188
|
-
/* @__PURE__ */
|
|
189
|
-
/* @__PURE__ */
|
|
100
|
+
/* @__PURE__ */ t("div", { style: { padding: 16, borderBottom: "1px solid #e8e8e8" }, children: [
|
|
101
|
+
/* @__PURE__ */ n("h3", { style: { margin: "0 0 12px" }, children: "Scenario Instances" }),
|
|
102
|
+
/* @__PURE__ */ t("div", { style: { display: "flex", gap: 8 }, children: [
|
|
103
|
+
/* @__PURE__ */ n(
|
|
190
104
|
"input",
|
|
191
105
|
{
|
|
192
106
|
style: {
|
|
@@ -196,12 +110,12 @@ function Z() {
|
|
|
196
110
|
borderRadius: 4
|
|
197
111
|
},
|
|
198
112
|
placeholder: "Instance name",
|
|
199
|
-
value:
|
|
200
|
-
onChange: (e) =>
|
|
201
|
-
onKeyDown: (e) => e.key === "Enter" &&
|
|
113
|
+
value: b,
|
|
114
|
+
onChange: (e) => v(e.target.value),
|
|
115
|
+
onKeyDown: (e) => e.key === "Enter" && A()
|
|
202
116
|
}
|
|
203
117
|
),
|
|
204
|
-
/* @__PURE__ */
|
|
118
|
+
/* @__PURE__ */ n(
|
|
205
119
|
"button",
|
|
206
120
|
{
|
|
207
121
|
style: {
|
|
@@ -210,29 +124,29 @@ function Z() {
|
|
|
210
124
|
color: "#fff",
|
|
211
125
|
border: "none",
|
|
212
126
|
borderRadius: 4,
|
|
213
|
-
cursor:
|
|
127
|
+
cursor: f ? "not-allowed" : "pointer"
|
|
214
128
|
},
|
|
215
|
-
disabled:
|
|
216
|
-
onClick:
|
|
217
|
-
children:
|
|
129
|
+
disabled: f,
|
|
130
|
+
onClick: A,
|
|
131
|
+
children: f ? "..." : "+"
|
|
218
132
|
}
|
|
219
133
|
)
|
|
220
134
|
] })
|
|
221
135
|
] }),
|
|
222
|
-
/* @__PURE__ */
|
|
223
|
-
|
|
136
|
+
/* @__PURE__ */ t("div", { style: { flex: 1, overflow: "auto" }, children: [
|
|
137
|
+
y.map((e) => /* @__PURE__ */ t(
|
|
224
138
|
"div",
|
|
225
139
|
{
|
|
226
|
-
onClick: () =>
|
|
140
|
+
onClick: () => k(e),
|
|
227
141
|
style: {
|
|
228
142
|
padding: "10px 16px",
|
|
229
143
|
cursor: "pointer",
|
|
230
|
-
background: (
|
|
144
|
+
background: (r == null ? void 0 : r.id) === e.id ? "#e6f4ff" : "transparent",
|
|
231
145
|
borderBottom: "1px solid #f0f0f0"
|
|
232
146
|
},
|
|
233
147
|
children: [
|
|
234
|
-
/* @__PURE__ */
|
|
235
|
-
/* @__PURE__ */
|
|
148
|
+
/* @__PURE__ */ n("div", { style: { fontWeight: 500, fontSize: 13 }, children: e.name }),
|
|
149
|
+
/* @__PURE__ */ t("div", { style: { fontSize: 11, color: "#999" }, children: [
|
|
236
150
|
e.scenarioCode,
|
|
237
151
|
" · ",
|
|
238
152
|
e.status
|
|
@@ -241,13 +155,13 @@ function Z() {
|
|
|
241
155
|
},
|
|
242
156
|
e.id
|
|
243
157
|
)),
|
|
244
|
-
|
|
158
|
+
y.length === 0 ? /* @__PURE__ */ n("div", { style: { padding: 16, color: "#999", fontSize: 12 }, children: "No instances yet. Create one above." }) : null
|
|
245
159
|
] })
|
|
246
160
|
]
|
|
247
161
|
}
|
|
248
162
|
),
|
|
249
|
-
/* @__PURE__ */
|
|
250
|
-
/* @__PURE__ */
|
|
163
|
+
/* @__PURE__ */ n("div", { style: { flex: 1, display: "flex", flexDirection: "column" }, children: r ? /* @__PURE__ */ t(_, { children: [
|
|
164
|
+
/* @__PURE__ */ t(
|
|
251
165
|
"div",
|
|
252
166
|
{
|
|
253
167
|
style: {
|
|
@@ -258,25 +172,25 @@ function Z() {
|
|
|
258
172
|
alignItems: "center"
|
|
259
173
|
},
|
|
260
174
|
children: [
|
|
261
|
-
/* @__PURE__ */
|
|
262
|
-
/* @__PURE__ */
|
|
263
|
-
/* @__PURE__ */
|
|
175
|
+
/* @__PURE__ */ t("div", { children: [
|
|
176
|
+
/* @__PURE__ */ n("span", { style: { fontWeight: 600, fontSize: 15 }, children: r.name }),
|
|
177
|
+
/* @__PURE__ */ t("span", { style: { marginLeft: 8, fontSize: 12, color: "#999" }, children: [
|
|
264
178
|
"ID: ",
|
|
265
|
-
|
|
179
|
+
r.id
|
|
266
180
|
] })
|
|
267
181
|
] }),
|
|
268
|
-
/* @__PURE__ */
|
|
182
|
+
/* @__PURE__ */ t("div", { style: { fontSize: 12, color: "#666" }, children: [
|
|
269
183
|
"Members: ",
|
|
270
|
-
|
|
184
|
+
U.length,
|
|
271
185
|
" human · ",
|
|
272
|
-
|
|
186
|
+
p.length,
|
|
273
187
|
" ",
|
|
274
188
|
"agent"
|
|
275
189
|
] })
|
|
276
190
|
]
|
|
277
191
|
}
|
|
278
192
|
),
|
|
279
|
-
/* @__PURE__ */
|
|
193
|
+
/* @__PURE__ */ t(
|
|
280
194
|
"div",
|
|
281
195
|
{
|
|
282
196
|
style: {
|
|
@@ -286,14 +200,14 @@ function Z() {
|
|
|
286
200
|
background: "#fff"
|
|
287
201
|
},
|
|
288
202
|
children: [
|
|
289
|
-
|
|
203
|
+
d.length === 0 ? /* @__PURE__ */ n(
|
|
290
204
|
"div",
|
|
291
205
|
{
|
|
292
206
|
style: { color: "#999", textAlign: "center", marginTop: 80 },
|
|
293
207
|
children: "Send a message to start. Use @agent_name to mention an agent."
|
|
294
208
|
}
|
|
295
209
|
) : null,
|
|
296
|
-
|
|
210
|
+
d.map((e) => /* @__PURE__ */ t(
|
|
297
211
|
"div",
|
|
298
212
|
{
|
|
299
213
|
style: {
|
|
@@ -303,7 +217,7 @@ function Z() {
|
|
|
303
217
|
gap: 8
|
|
304
218
|
},
|
|
305
219
|
children: [
|
|
306
|
-
/* @__PURE__ */
|
|
220
|
+
/* @__PURE__ */ n(
|
|
307
221
|
"div",
|
|
308
222
|
{
|
|
309
223
|
style: {
|
|
@@ -321,8 +235,8 @@ function Z() {
|
|
|
321
235
|
children: e.senderType === "HUMAN" ? "U" : "A"
|
|
322
236
|
}
|
|
323
237
|
),
|
|
324
|
-
/* @__PURE__ */
|
|
325
|
-
/* @__PURE__ */
|
|
238
|
+
/* @__PURE__ */ t("div", { style: { maxWidth: "70%" }, children: [
|
|
239
|
+
/* @__PURE__ */ t(
|
|
326
240
|
"div",
|
|
327
241
|
{
|
|
328
242
|
style: {
|
|
@@ -339,7 +253,7 @@ function Z() {
|
|
|
339
253
|
]
|
|
340
254
|
}
|
|
341
255
|
),
|
|
342
|
-
/* @__PURE__ */
|
|
256
|
+
/* @__PURE__ */ n(
|
|
343
257
|
"div",
|
|
344
258
|
{
|
|
345
259
|
style: {
|
|
@@ -359,11 +273,11 @@ function Z() {
|
|
|
359
273
|
},
|
|
360
274
|
e.id
|
|
361
275
|
)),
|
|
362
|
-
/* @__PURE__ */
|
|
276
|
+
/* @__PURE__ */ n("div", { ref: S })
|
|
363
277
|
]
|
|
364
278
|
}
|
|
365
279
|
),
|
|
366
|
-
/* @__PURE__ */
|
|
280
|
+
/* @__PURE__ */ t(
|
|
367
281
|
"div",
|
|
368
282
|
{
|
|
369
283
|
style: {
|
|
@@ -374,7 +288,7 @@ function Z() {
|
|
|
374
288
|
background: "#fafafa"
|
|
375
289
|
},
|
|
376
290
|
children: [
|
|
377
|
-
/* @__PURE__ */
|
|
291
|
+
/* @__PURE__ */ n(
|
|
378
292
|
"textarea",
|
|
379
293
|
{
|
|
380
294
|
style: {
|
|
@@ -387,15 +301,15 @@ function Z() {
|
|
|
387
301
|
maxHeight: 120,
|
|
388
302
|
fontSize: 13
|
|
389
303
|
},
|
|
390
|
-
placeholder:
|
|
391
|
-
value:
|
|
392
|
-
onChange: (e) =>
|
|
304
|
+
placeholder: p.length > 0 ? `Type message. @${(M = p[0]) == null ? void 0 : M.displayName} to mention agent.` : "Type message...",
|
|
305
|
+
value: m,
|
|
306
|
+
onChange: (e) => h(e.target.value),
|
|
393
307
|
onKeyDown: (e) => {
|
|
394
|
-
e.key === "Enter" && !e.shiftKey && (e.preventDefault(),
|
|
308
|
+
e.key === "Enter" && !e.shiftKey && (e.preventDefault(), I());
|
|
395
309
|
}
|
|
396
310
|
}
|
|
397
311
|
),
|
|
398
|
-
/* @__PURE__ */
|
|
312
|
+
/* @__PURE__ */ n(
|
|
399
313
|
"button",
|
|
400
314
|
{
|
|
401
315
|
style: {
|
|
@@ -407,14 +321,14 @@ function Z() {
|
|
|
407
321
|
cursor: "pointer",
|
|
408
322
|
fontSize: 13
|
|
409
323
|
},
|
|
410
|
-
onClick:
|
|
324
|
+
onClick: I,
|
|
411
325
|
children: "Send"
|
|
412
326
|
}
|
|
413
327
|
)
|
|
414
328
|
]
|
|
415
329
|
}
|
|
416
330
|
)
|
|
417
|
-
] }) : /* @__PURE__ */
|
|
331
|
+
] }) : /* @__PURE__ */ n(
|
|
418
332
|
"div",
|
|
419
333
|
{
|
|
420
334
|
style: {
|
|
@@ -430,5 +344,5 @@ function Z() {
|
|
|
430
344
|
] });
|
|
431
345
|
}
|
|
432
346
|
export {
|
|
433
|
-
|
|
347
|
+
q as default
|
|
434
348
|
};
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { jsxs as
|
|
1
|
+
import { jsxs as u, jsx as t } from "react/jsx-runtime";
|
|
2
2
|
import { useState as L, useMemo as p } from "react";
|
|
3
3
|
import { useNavigate as v, useLocation as A } from "react-router-dom";
|
|
4
4
|
import { DownOutlined as k, RightOutlined as w } from "@ant-design/icons";
|
|
5
|
-
import { P as W, R as $ } from "./index-
|
|
6
|
-
import { f as E, M as g } from "./menuPermission-
|
|
7
|
-
import {
|
|
5
|
+
import { P as W, R as $ } from "./index-C-8n6xxK.js";
|
|
6
|
+
import { f as E, M as g } from "./menuPermission-u3Gd_c8S.js";
|
|
7
|
+
import { u as j } from "./ComponentDoc-C_289lsE.js";
|
|
8
8
|
const H = "_shell_1jjcx_7", M = "_sidebar_1jjcx_15", R = "_menuList_1jjcx_37", T = "_menuGroup_1jjcx_43", C = "_menuGroupHeader_1jjcx_47", P = "_menuGroupIcon_1jjcx_65", z = "_menuGroupLabel_1jjcx_70", K = "_menuGroupArrow_1jjcx_74", U = "_menuSubList_1jjcx_80", Z = "_menuSubItem_1jjcx_86", B = "_menuSubItemActive_1jjcx_103", D = "_menuSubItemIcon_1jjcx_110", O = "_menuSubItemLabel_1jjcx_115", q = "_menuSubItemWrap_1jjcx_119", F = "_main_1jjcx_123", J = "_empty_1jjcx_134", Q = "_emptyIcon_1jjcx_144", V = "_emptyText_1jjcx_149", n = {
|
|
9
9
|
shell: H,
|
|
10
10
|
sidebar: M,
|
|
@@ -36,12 +36,12 @@ function X(m, r) {
|
|
|
36
36
|
return null;
|
|
37
37
|
}
|
|
38
38
|
function Y({ text: m }) {
|
|
39
|
-
return /* @__PURE__ */
|
|
39
|
+
return /* @__PURE__ */ u("div", { className: n.empty, children: [
|
|
40
40
|
/* @__PURE__ */ t("div", { className: n.emptyIcon, children: "⚙️" }),
|
|
41
41
|
/* @__PURE__ */ t("div", { className: n.emptyText, children: m })
|
|
42
42
|
] });
|
|
43
43
|
}
|
|
44
|
-
function
|
|
44
|
+
function oe({
|
|
45
45
|
groups: m,
|
|
46
46
|
routes: r,
|
|
47
47
|
mode: s,
|
|
@@ -56,25 +56,25 @@ function ue({
|
|
|
56
56
|
[m, d, b]
|
|
57
57
|
), f = p(() => {
|
|
58
58
|
const e = _ ?? a;
|
|
59
|
-
for (const
|
|
60
|
-
for (const c of
|
|
59
|
+
for (const o of l)
|
|
60
|
+
for (const c of o.items)
|
|
61
61
|
if (c.path === e) return c.key;
|
|
62
62
|
return null;
|
|
63
63
|
}, [l, _, a]), G = (e) => {
|
|
64
|
-
S((
|
|
65
|
-
const c = new Set(
|
|
64
|
+
S((o) => {
|
|
65
|
+
const c = new Set(o);
|
|
66
66
|
return c.has(e) ? c.delete(e) : c.add(e), c;
|
|
67
67
|
});
|
|
68
68
|
}, y = (e) => {
|
|
69
69
|
I(`${e.path}?mode=${s}`);
|
|
70
70
|
}, N = p(() => X(r, a), [r, a]);
|
|
71
|
-
return /* @__PURE__ */
|
|
72
|
-
/* @__PURE__ */
|
|
71
|
+
return /* @__PURE__ */ u("div", { className: n.shell, children: [
|
|
72
|
+
/* @__PURE__ */ u("aside", { className: n.sidebar, children: [
|
|
73
73
|
/* @__PURE__ */ t(g, {}),
|
|
74
74
|
/* @__PURE__ */ t("nav", { className: n.menuList, children: l.map((e) => {
|
|
75
|
-
const
|
|
76
|
-
return /* @__PURE__ */
|
|
77
|
-
/* @__PURE__ */
|
|
75
|
+
const o = x.has(e.title);
|
|
76
|
+
return /* @__PURE__ */ u("div", { className: n.menuGroup, children: [
|
|
77
|
+
/* @__PURE__ */ u(
|
|
78
78
|
"div",
|
|
79
79
|
{
|
|
80
80
|
className: n.menuGroupHeader,
|
|
@@ -82,11 +82,11 @@ function ue({
|
|
|
82
82
|
children: [
|
|
83
83
|
/* @__PURE__ */ t("span", { className: n.menuGroupIcon, children: e.icon }),
|
|
84
84
|
/* @__PURE__ */ t("span", { className: n.menuGroupLabel, children: e.title }),
|
|
85
|
-
/* @__PURE__ */ t("span", { className: n.menuGroupArrow, children:
|
|
85
|
+
/* @__PURE__ */ t("span", { className: n.menuGroupArrow, children: o ? /* @__PURE__ */ t(k, {}) : /* @__PURE__ */ t(w, {}) })
|
|
86
86
|
]
|
|
87
87
|
}
|
|
88
88
|
),
|
|
89
|
-
|
|
89
|
+
o && /* @__PURE__ */ t("ul", { className: n.menuSubList, children: e.items.map((c) => /* @__PURE__ */ u(
|
|
90
90
|
"li",
|
|
91
91
|
{
|
|
92
92
|
className: `${n.menuSubItemWrap} ${n.menuSubItem} ${f === c.key ? n.menuSubItemActive : ""}`,
|
|
@@ -101,12 +101,12 @@ function ue({
|
|
|
101
101
|
] }, e.title);
|
|
102
102
|
}) })
|
|
103
103
|
] }),
|
|
104
|
-
h ? null : /* @__PURE__ */
|
|
104
|
+
h ? null : /* @__PURE__ */ u("main", { className: n.main, children: [
|
|
105
105
|
/* @__PURE__ */ t(W, {}),
|
|
106
106
|
/* @__PURE__ */ t($, { resetKey: a, children: N ?? /* @__PURE__ */ t(Y, { text: i }) })
|
|
107
107
|
] })
|
|
108
108
|
] });
|
|
109
109
|
}
|
|
110
110
|
export {
|
|
111
|
-
|
|
111
|
+
oe as W
|
|
112
112
|
};
|
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
import { jsx as r, jsxs as x } from "react/jsx-runtime";
|
|
2
2
|
import { f as z, r as T } from "./ctc-sso-DtJHC-2M.js";
|
|
3
|
-
import { r as D, h as U, s as F } from "./sso-user-
|
|
3
|
+
import { r as D, h as U, s as F } from "./sso-user-Ib1jhF7t.js";
|
|
4
4
|
import { CheckCircleFilled as W } from "@ant-design/icons";
|
|
5
5
|
import { Result as B, Button as H, Spin as G } from "antd";
|
|
6
6
|
import J from "query-string";
|
|
7
7
|
import { useState as d, useRef as K, useCallback as O, useMemo as R, useEffect as E } from "react";
|
|
8
8
|
import { useLocation as Q } from "react-router-dom";
|
|
9
9
|
import { h as b } from "./history-BlrA1eaW.js";
|
|
10
|
-
import {
|
|
10
|
+
import { u as s, j as V, k as X } from "./ComponentDoc-C_289lsE.js";
|
|
11
11
|
import { b as Y } from "./mobile-client-O3yr9h6t.js";
|
|
12
|
-
import { s as Z } from "./send-default-agent-team-message-
|
|
12
|
+
import { s as Z } from "./send-default-agent-team-message-BhIV6T6O.js";
|
|
13
13
|
function ue() {
|
|
14
14
|
const h = Q(), f = J.parse(h.search), c = String(
|
|
15
15
|
f.scenarioCode ?? f.scenario_code ?? ""
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { jsxs as c, jsx as a } from "react/jsx-runtime";
|
|
2
2
|
import v, { useState as d, useEffect as _, useMemo as h } from "react";
|
|
3
3
|
import { useLocation as N } from "react-router-dom";
|
|
4
|
-
import { w as b, x as g } from "./ComponentDoc-
|
|
5
|
-
import { i as x, P as K } from "./index-
|
|
4
|
+
import { w as b, x as g } from "./ComponentDoc-C_289lsE.js";
|
|
5
|
+
import { i as x, P as K } from "./index-54iTaRVW.js";
|
|
6
6
|
const E = "_banner_2v7mc_1", S = "_dot_2v7mc_18", f = "_text_2v7mc_26", A = "_retry_2v7mc_31", F = "_dismiss_2v7mc_44", P = "_details_2v7mc_57", k = "_method_2v7mc_85", C = "_status_2v7mc_86", D = "_statusNet_2v7mc_87", $ = "_url_2v7mc_88", e = {
|
|
7
7
|
banner: E,
|
|
8
8
|
dot: S,
|