@yuku123/z-team-component 0.2.102 → 0.2.103
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/package.json +1 -1
- package/dist/ChangeLogView-BIlT58NX.js +0 -542
- package/dist/ComponentDoc-bhNM4jiY.js +0 -8035
- package/dist/InvitationManagementPage-9AmXUw6E.js +0 -495
- package/dist/OnboardingPage-B9oWippy.js +0 -393
- package/dist/ScheduledTasks-CkNxtgeb.js +0 -12127
- package/dist/SystemShell-Cz3bn2dt.js +0 -688
- package/dist/_commonjsHelpers-B52_cu2H.js +0 -26
- package/dist/admin-logs-BuwxECUY.js +0 -198
- package/dist/api-DL_MM5cW.js +0 -20
- package/dist/browser-jb_PFvU3.js +0 -1538
- package/dist/createWorkspaceWsHandler-B6LYCL3Q.js +0 -13142
- package/dist/ctc-sso-DtJHC-2M.js +0 -117
- package/dist/echarts-B1OU1xr4.js +0 -16
- package/dist/history-BlrA1eaW.js +0 -41
- package/dist/index-2dGExnjZ.js +0 -2217
- package/dist/index-B1AYMWHS.js +0 -10169
- package/dist/index-B5F1N9_V.js +0 -42049
- package/dist/index-B8O2io7L.js +0 -315
- package/dist/index-BIXeUFLa.js +0 -479
- package/dist/index-BPqoN-aE.js +0 -242
- package/dist/index-BTs7b4SV.js +0 -118
- package/dist/index-BYMhgsLe.js +0 -178
- package/dist/index-BZBxvwcT.js +0 -169
- package/dist/index-BZCQSW-G.js +0 -1222
- package/dist/index-B_LJRFsK.js +0 -339
- package/dist/index-BdmM-NHL.js +0 -5892
- package/dist/index-BmHFHD_e.js +0 -112
- package/dist/index-BohoJQPr.js +0 -7631
- package/dist/index-C1wsTstT.js +0 -434
- package/dist/index-C1wtrBjM.js +0 -8
- package/dist/index-C815hPWS.js +0 -430
- package/dist/index-CbH8YeqA.js +0 -913
- package/dist/index-CsweV-yM.js +0 -142
- package/dist/index-D3vyICxK.js +0 -2699
- package/dist/index-DKgyKXWm.js +0 -1640
- package/dist/index-DQHEr9-I.js +0 -93
- package/dist/index-DU-PHfEr.js +0 -189
- package/dist/index-DWsfQMp8.js +0 -208
- package/dist/index-DhDdFRHC.js +0 -279
- package/dist/index-DvTMESfc.js +0 -132
- package/dist/index-fl0m6QYf.js +0 -316
- package/dist/index-lux3nNJP.js +0 -574
- package/dist/index-mwtsohOK.js +0 -951
- package/dist/index-qd4awhFI.js +0 -956
- package/dist/index.js +0 -10
- package/dist/index.module-CAa-2T7m.js +0 -72
- package/dist/index.module-UI0iz8K0.js +0 -42
- package/dist/instance-4ACm8YFK.js +0 -216
- package/dist/menuPermission-C7yt7uNG.js +0 -60
- package/dist/mobile-client-O3yr9h6t.js +0 -24
- package/dist/pages.js +0 -21
- package/dist/send-default-agent-team-message-YRd0CkeT.js +0 -35
- package/dist/spark-md5-Dld54a-T.js +0 -178
- package/dist/sso-user-GnlYnP83.js +0 -43
- package/dist/training-CyK00fwu.js +0 -450
- package/dist/webide-SjnHsCZF.js +0 -5233
- package/dist/z-team-component.css +0 -1
package/dist/index-DhDdFRHC.js
DELETED
|
@@ -1,279 +0,0 @@
|
|
|
1
|
-
import { jsxs as n, jsx as a } from "react/jsx-runtime";
|
|
2
|
-
import { FilePptOutlined as P, EditOutlined as O, ScheduleOutlined as A, FileImageOutlined as $, CloseOutlined as F } from "@ant-design/icons";
|
|
3
|
-
import { useState as m, useCallback as x } from "react";
|
|
4
|
-
import { h as w } from "./history-BlrA1eaW.js";
|
|
5
|
-
const R = "_portalRoot_1sa2c_7", q = "_portalHeader_1sa2c_47", B = "_brandRow_1sa2c_53", D = "_brandLogo_1sa2c_59", L = "_brandTitle_1sa2c_63", M = "_brandSubtitle_1sa2c_70", G = "_portalMain_1sa2c_76", H = "_sectionTitle_1sa2c_85", j = "_cardGrid_1sa2c_92", K = "_scenarioCard_1sa2c_98", W = "_cardTop_1sa2c_114", z = "_cardIcon_1sa2c_119", Z = "_cardInfo_1sa2c_123", Q = "_cardTitle_1sa2c_127", J = "_cardTags_1sa2c_134", U = "_tag_1sa2c_139", X = "_cardDesc_1sa2c_148", Y = "_cardAction_1sa2c_154", V = "_btnCreate_1sa2c_159", ee = "_portalFooter_1sa2c_184", ae = "_linkWorkspace_1sa2c_190", oe = "_modalOverlay_1sa2c_206", te = "_modalBox_1sa2c_217", re = "_modalHeader_1sa2c_226", ne = "_modalIcon_1sa2c_239", ce = "_modalClose_1sa2c_242", le = "_modalBody_1sa2c_255", ie = "_modalDesc_1sa2c_258", se = "_fieldGroup_1sa2c_264", de = "_fieldLabel_1sa2c_269", _e = "_required_1sa2c_274", pe = "_fieldInput_1sa2c_278", me = "_fieldInputError_1sa2c_298", ue = "_fieldTextarea_1sa2c_301", fe = "_fieldTextareaError_1sa2c_325", he = "_fieldError_1sa2c_328", ge = "_modalFooter_1sa2c_333", Ce = "_btnCancel_1sa2c_339", be = "_btnConfirm_1sa2c_354", e = {
|
|
6
|
-
portalRoot: R,
|
|
7
|
-
portalHeader: q,
|
|
8
|
-
brandRow: B,
|
|
9
|
-
brandLogo: D,
|
|
10
|
-
brandTitle: L,
|
|
11
|
-
brandSubtitle: M,
|
|
12
|
-
portalMain: G,
|
|
13
|
-
sectionTitle: H,
|
|
14
|
-
cardGrid: j,
|
|
15
|
-
scenarioCard: K,
|
|
16
|
-
cardTop: W,
|
|
17
|
-
cardIcon: z,
|
|
18
|
-
cardInfo: Z,
|
|
19
|
-
cardTitle: Q,
|
|
20
|
-
cardTags: J,
|
|
21
|
-
tag: U,
|
|
22
|
-
cardDesc: X,
|
|
23
|
-
cardAction: Y,
|
|
24
|
-
btnCreate: V,
|
|
25
|
-
portalFooter: ee,
|
|
26
|
-
linkWorkspace: ae,
|
|
27
|
-
modalOverlay: oe,
|
|
28
|
-
modalBox: te,
|
|
29
|
-
modalHeader: re,
|
|
30
|
-
modalIcon: ne,
|
|
31
|
-
modalClose: ce,
|
|
32
|
-
modalBody: le,
|
|
33
|
-
modalDesc: ie,
|
|
34
|
-
fieldGroup: se,
|
|
35
|
-
fieldLabel: de,
|
|
36
|
-
required: _e,
|
|
37
|
-
fieldInput: pe,
|
|
38
|
-
fieldInputError: me,
|
|
39
|
-
fieldTextarea: ue,
|
|
40
|
-
fieldTextareaError: fe,
|
|
41
|
-
fieldError: he,
|
|
42
|
-
modalFooter: ge,
|
|
43
|
-
btnCancel: Ce,
|
|
44
|
-
btnConfirm: be
|
|
45
|
-
}, Ne = window.ZTEAM_USE_KAPI === !0 ? "/kapi/z-team/api" : "/z-team/api", Te = [
|
|
46
|
-
{
|
|
47
|
-
key: "ppt-creation",
|
|
48
|
-
icon: /* @__PURE__ */ a(P, {}),
|
|
49
|
-
title: "PPT 制作",
|
|
50
|
-
description: "PPT 制作:主题/受众/页数 → 大纲生成 → 逐页内容填充 → 风格与可视化建议",
|
|
51
|
-
scenarioCode: "ppt_creation",
|
|
52
|
-
source: "ppt_creation",
|
|
53
|
-
tags: ["大纲生成", "内容填充", "风格建议"],
|
|
54
|
-
inputConfig: {
|
|
55
|
-
label: "PPT 主题与需求",
|
|
56
|
-
placeholder: `请输入 PPT 主题、受众、页数、风格等关键信息,例如:
|
|
57
|
-
主题:2026 Q3 产品回顾
|
|
58
|
-
受众:公司管理层
|
|
59
|
-
页数:15 页
|
|
60
|
-
风格:商务简洁,重点突出数据`,
|
|
61
|
-
required: !0,
|
|
62
|
-
paramKey: "topic",
|
|
63
|
-
multiline: !0
|
|
64
|
-
}
|
|
65
|
-
},
|
|
66
|
-
{
|
|
67
|
-
key: "longform-writing",
|
|
68
|
-
icon: /* @__PURE__ */ a(O, {}),
|
|
69
|
-
title: "长文写作",
|
|
70
|
-
description: "长文写作:主题/关键词/风格 → 结构化大纲 → Markdown 正文 → 润色与精简",
|
|
71
|
-
scenarioCode: "longform_writing",
|
|
72
|
-
source: "longform_writing",
|
|
73
|
-
tags: ["结构化", "Markdown", "风格可控"],
|
|
74
|
-
inputConfig: {
|
|
75
|
-
label: "写作主题与要求",
|
|
76
|
-
placeholder: `请输入主题、关键词、目标读者、风格等关键信息,例如:
|
|
77
|
-
主题:z-opc 平台 2026 年度回顾
|
|
78
|
-
读者:全体员工
|
|
79
|
-
风格:积极、突出成绩、控制在 2000 字以内`,
|
|
80
|
-
required: !0,
|
|
81
|
-
paramKey: "topic",
|
|
82
|
-
multiline: !0
|
|
83
|
-
}
|
|
84
|
-
},
|
|
85
|
-
{
|
|
86
|
-
key: "weekly-report",
|
|
87
|
-
icon: /* @__PURE__ */ a(A, {}),
|
|
88
|
-
title: "周报月报",
|
|
89
|
-
description: "周报/月报:碎片记录/时间段 → 自动汇总 → 模板化输出(本周工作/下周计划/风险对齐)",
|
|
90
|
-
scenarioCode: "weekly_report",
|
|
91
|
-
source: "weekly_report",
|
|
92
|
-
tags: ["自动汇总", "模板化", "目标对齐"],
|
|
93
|
-
inputConfig: {
|
|
94
|
-
label: "碎片记录与时间段",
|
|
95
|
-
placeholder: `粘贴或描述一段时间内的碎片工作记录,例如:
|
|
96
|
-
时间段:2026-08-25 ~ 2026-08-31
|
|
97
|
-
记录:
|
|
98
|
-
- 完成 X 功能开发
|
|
99
|
-
- 修复 Y 故障
|
|
100
|
-
- 与 Z 团队对齐方案`,
|
|
101
|
-
required: !0,
|
|
102
|
-
paramKey: "topic",
|
|
103
|
-
multiline: !0
|
|
104
|
-
}
|
|
105
|
-
},
|
|
106
|
-
{
|
|
107
|
-
key: "image-understanding",
|
|
108
|
-
icon: /* @__PURE__ */ a($, {}),
|
|
109
|
-
title: "图片理解",
|
|
110
|
-
description: "图片理解:图片 + 问题 → OCR 文本提取 → 图表/表格识别 → 智能问答",
|
|
111
|
-
scenarioCode: "image_understanding",
|
|
112
|
-
source: "image_understanding",
|
|
113
|
-
tags: ["OCR", "图表识别", "智能问答"],
|
|
114
|
-
inputConfig: {
|
|
115
|
-
label: "图片描述或问题",
|
|
116
|
-
placeholder: `粘贴图片链接或描述图片内容,并附上你的问题,例如:
|
|
117
|
-
图片:https://example.com/sales-chart.png
|
|
118
|
-
问题:分析 2026 Q3 各区域销售额同比变化及异常原因`,
|
|
119
|
-
required: !0,
|
|
120
|
-
paramKey: "topic",
|
|
121
|
-
multiline: !0
|
|
122
|
-
}
|
|
123
|
-
}
|
|
124
|
-
];
|
|
125
|
-
function ye({
|
|
126
|
-
scenario: o,
|
|
127
|
-
onClose: c,
|
|
128
|
-
onCreated: d
|
|
129
|
-
}) {
|
|
130
|
-
var g, C, b, N, T;
|
|
131
|
-
const [r, s] = m(""), [u, f] = m(!1), [l, i] = m(""), E = !!((g = o.inputConfig) != null && g.multiline), h = x(async () => {
|
|
132
|
-
var y, k, I;
|
|
133
|
-
const t = r.trim();
|
|
134
|
-
if ((y = o.inputConfig) != null && y.required && !t) {
|
|
135
|
-
i(`请填写${o.inputConfig.label}`);
|
|
136
|
-
return;
|
|
137
|
-
}
|
|
138
|
-
i(""), f(!0);
|
|
139
|
-
try {
|
|
140
|
-
const _ = ((k = t.split(`
|
|
141
|
-
`)[0]) == null ? void 0 : k.trim()) ?? "", S = _.length > 0 ? _.length > 32 ? `${_.slice(0, 32)}…` : _ : `${Date.now()}`, v = `${o.title}-${S}`, p = await (await fetch(`${Ne}/scenario-instances/`, {
|
|
142
|
-
method: "POST",
|
|
143
|
-
credentials: "include",
|
|
144
|
-
headers: {
|
|
145
|
-
Accept: "application/json",
|
|
146
|
-
"Content-Type": "application/json"
|
|
147
|
-
},
|
|
148
|
-
body: JSON.stringify({
|
|
149
|
-
name: v,
|
|
150
|
-
description: `${o.title}:${t.length > 120 ? `${t.slice(0, 120)}…` : t}`,
|
|
151
|
-
workspace_path: v,
|
|
152
|
-
scenario_code: o.scenarioCode,
|
|
153
|
-
extend_params: {
|
|
154
|
-
[o.inputConfig.paramKey]: t,
|
|
155
|
-
source: o.source
|
|
156
|
-
}
|
|
157
|
-
})
|
|
158
|
-
})).json();
|
|
159
|
-
p.success && ((I = p.data) != null && I.id) ? d(p.data.id) : i(p.message || "创建失败,请重试");
|
|
160
|
-
} catch {
|
|
161
|
-
i("网络错误,请检查服务是否可用");
|
|
162
|
-
} finally {
|
|
163
|
-
f(!1);
|
|
164
|
-
}
|
|
165
|
-
}, [r, o, d]);
|
|
166
|
-
return /* @__PURE__ */ a("div", { className: e.modalOverlay, onClick: c, children: /* @__PURE__ */ n("div", { className: e.modalBox, onClick: (t) => t.stopPropagation(), children: [
|
|
167
|
-
/* @__PURE__ */ n("div", { className: e.modalHeader, children: [
|
|
168
|
-
/* @__PURE__ */ a("span", { className: e.modalIcon, children: o.icon }),
|
|
169
|
-
/* @__PURE__ */ a("h3", { children: o.title }),
|
|
170
|
-
/* @__PURE__ */ a("button", { className: e.modalClose, onClick: c, children: /* @__PURE__ */ a(F, {}) })
|
|
171
|
-
] }),
|
|
172
|
-
/* @__PURE__ */ n("div", { className: e.modalBody, children: [
|
|
173
|
-
/* @__PURE__ */ a("p", { className: e.modalDesc, children: o.description }),
|
|
174
|
-
/* @__PURE__ */ n("div", { className: e.fieldGroup, children: [
|
|
175
|
-
/* @__PURE__ */ n("label", { className: e.fieldLabel, children: [
|
|
176
|
-
(C = o.inputConfig) == null ? void 0 : C.label,
|
|
177
|
-
((b = o.inputConfig) == null ? void 0 : b.required) && /* @__PURE__ */ a("span", { className: e.required, children: "*" })
|
|
178
|
-
] }),
|
|
179
|
-
E ? /* @__PURE__ */ a(
|
|
180
|
-
"textarea",
|
|
181
|
-
{
|
|
182
|
-
className: `${e.fieldTextarea} ${l ? e.fieldTextareaError : ""}`,
|
|
183
|
-
value: r,
|
|
184
|
-
placeholder: (N = o.inputConfig) == null ? void 0 : N.placeholder,
|
|
185
|
-
onChange: (t) => {
|
|
186
|
-
s(t.target.value), l && i("");
|
|
187
|
-
},
|
|
188
|
-
rows: 5,
|
|
189
|
-
autoFocus: !0
|
|
190
|
-
}
|
|
191
|
-
) : /* @__PURE__ */ a(
|
|
192
|
-
"input",
|
|
193
|
-
{
|
|
194
|
-
className: `${e.fieldInput} ${l ? e.fieldInputError : ""}`,
|
|
195
|
-
type: "text",
|
|
196
|
-
value: r,
|
|
197
|
-
placeholder: (T = o.inputConfig) == null ? void 0 : T.placeholder,
|
|
198
|
-
onChange: (t) => {
|
|
199
|
-
s(t.target.value), l && i("");
|
|
200
|
-
},
|
|
201
|
-
onKeyDown: (t) => {
|
|
202
|
-
t.key === "Enter" && h();
|
|
203
|
-
},
|
|
204
|
-
autoFocus: !0
|
|
205
|
-
}
|
|
206
|
-
),
|
|
207
|
-
l && /* @__PURE__ */ a("p", { className: e.fieldError, children: l })
|
|
208
|
-
] })
|
|
209
|
-
] }),
|
|
210
|
-
/* @__PURE__ */ n("div", { className: e.modalFooter, children: [
|
|
211
|
-
/* @__PURE__ */ a("button", { className: e.btnCancel, onClick: c, children: "取消" }),
|
|
212
|
-
/* @__PURE__ */ a(
|
|
213
|
-
"button",
|
|
214
|
-
{
|
|
215
|
-
className: e.btnConfirm,
|
|
216
|
-
onClick: h,
|
|
217
|
-
disabled: u,
|
|
218
|
-
children: u ? "创建中..." : "确认并开始"
|
|
219
|
-
}
|
|
220
|
-
)
|
|
221
|
-
] })
|
|
222
|
-
] }) });
|
|
223
|
-
}
|
|
224
|
-
function Ee() {
|
|
225
|
-
const [o, c] = m(
|
|
226
|
-
null
|
|
227
|
-
), d = x((r) => {
|
|
228
|
-
localStorage.setItem("ft_last_project_id", String(r)), localStorage.removeItem("ft_last_file_path"), w.push("/workspace");
|
|
229
|
-
}, []);
|
|
230
|
-
return /* @__PURE__ */ n("div", { className: e.portalRoot, children: [
|
|
231
|
-
/* @__PURE__ */ n("header", { className: e.portalHeader, children: [
|
|
232
|
-
/* @__PURE__ */ n("div", { className: e.brandRow, children: [
|
|
233
|
-
/* @__PURE__ */ a("img", { src: "/logo.svg", alt: "logo", className: e.brandLogo }),
|
|
234
|
-
/* @__PURE__ */ a("h1", { className: e.brandTitle, children: "Z-OPC 一人公司基建" })
|
|
235
|
-
] }),
|
|
236
|
-
/* @__PURE__ */ a("p", { className: e.brandSubtitle, children: "一人公司的 AI 基建 — 选择场景,即刻启动智能协作" })
|
|
237
|
-
] }),
|
|
238
|
-
/* @__PURE__ */ n("main", { className: e.portalMain, children: [
|
|
239
|
-
/* @__PURE__ */ a("h2", { className: e.sectionTitle, children: "可用场景" }),
|
|
240
|
-
/* @__PURE__ */ a("div", { className: e.cardGrid, children: Te.map((r) => /* @__PURE__ */ n("div", { className: e.scenarioCard, children: [
|
|
241
|
-
/* @__PURE__ */ n("div", { className: e.cardTop, children: [
|
|
242
|
-
/* @__PURE__ */ a("span", { className: e.cardIcon, children: r.icon }),
|
|
243
|
-
/* @__PURE__ */ n("div", { className: e.cardInfo, children: [
|
|
244
|
-
/* @__PURE__ */ a("h3", { className: e.cardTitle, children: r.title }),
|
|
245
|
-
/* @__PURE__ */ a("div", { className: e.cardTags, children: r.tags.map((s) => /* @__PURE__ */ a("span", { className: e.tag, children: s }, s)) })
|
|
246
|
-
] })
|
|
247
|
-
] }),
|
|
248
|
-
/* @__PURE__ */ a("p", { className: e.cardDesc, children: r.description }),
|
|
249
|
-
/* @__PURE__ */ a("div", { className: e.cardAction, children: /* @__PURE__ */ a(
|
|
250
|
-
"button",
|
|
251
|
-
{
|
|
252
|
-
className: e.btnCreate,
|
|
253
|
-
onClick: () => c(r),
|
|
254
|
-
children: "创建"
|
|
255
|
-
}
|
|
256
|
-
) })
|
|
257
|
-
] }, r.key)) })
|
|
258
|
-
] }),
|
|
259
|
-
/* @__PURE__ */ a("footer", { className: e.portalFooter, children: /* @__PURE__ */ a(
|
|
260
|
-
"button",
|
|
261
|
-
{
|
|
262
|
-
className: e.linkWorkspace,
|
|
263
|
-
onClick: () => w.push("/workspace"),
|
|
264
|
-
children: "进入工作台 →"
|
|
265
|
-
}
|
|
266
|
-
) }),
|
|
267
|
-
o && /* @__PURE__ */ a(
|
|
268
|
-
ye,
|
|
269
|
-
{
|
|
270
|
-
scenario: o,
|
|
271
|
-
onClose: () => c(null),
|
|
272
|
-
onCreated: d
|
|
273
|
-
}
|
|
274
|
-
)
|
|
275
|
-
] });
|
|
276
|
-
}
|
|
277
|
-
export {
|
|
278
|
-
Ee as default
|
|
279
|
-
};
|
package/dist/index-DvTMESfc.js
DELETED
|
@@ -1,132 +0,0 @@
|
|
|
1
|
-
import { jsx as s, jsxs as C } from "react/jsx-runtime";
|
|
2
|
-
import { f as z, r as v } from "./ctc-sso-DtJHC-2M.js";
|
|
3
|
-
import { r as L, h as N, s as T } from "./sso-user-GnlYnP83.js";
|
|
4
|
-
import { CheckCircleFilled as q } from "@ant-design/icons";
|
|
5
|
-
import { Spin as R } from "antd";
|
|
6
|
-
import W from "query-string";
|
|
7
|
-
import { useMemo as P, useState as p, useCallback as A, useEffect as U } from "react";
|
|
8
|
-
import { useLocation as F } from "react-router-dom";
|
|
9
|
-
import { h as H } from "./history-BlrA1eaW.js";
|
|
10
|
-
import { d as m, e as Y, j as B } from "./ComponentDoc-bhNM4jiY.js";
|
|
11
|
-
/* empty css */
|
|
12
|
-
import { b as G } from "./mobile-client-O3yr9h6t.js";
|
|
13
|
-
function oe() {
|
|
14
|
-
const i = F(), g = W.parse(i.search), S = P(
|
|
15
|
-
() => String(g.name ?? "WebIDE 在线咨询").trim(),
|
|
16
|
-
[i.search]
|
|
17
|
-
), _ = P(
|
|
18
|
-
() => String(g.source ?? "z-team-webide").trim(),
|
|
19
|
-
[i.search]
|
|
20
|
-
), [b, E] = p(!1), [I, y] = p("正在登录…"), [w, M] = p([]), [j, x] = p(""), { currentUser: d, updateCurrentUser: u, expandProject: $ } = m(), f = A((e, o) => {
|
|
21
|
-
M((a) => [...a, e]), y(o);
|
|
22
|
-
}, []);
|
|
23
|
-
return U(() => {
|
|
24
|
-
let e = !1, o = 0;
|
|
25
|
-
const a = 100;
|
|
26
|
-
let r = !1, n = 0;
|
|
27
|
-
const h = 3;
|
|
28
|
-
return (() => {
|
|
29
|
-
if (e) return;
|
|
30
|
-
const l = async () => {
|
|
31
|
-
if (e) return;
|
|
32
|
-
let t = L();
|
|
33
|
-
if ((!t || !N(t)) && !r) {
|
|
34
|
-
r = !0;
|
|
35
|
-
try {
|
|
36
|
-
const c = await z();
|
|
37
|
-
c.kind === "authenticated" ? t = c.user : c.kind === "unauthenticated" && (n += 1);
|
|
38
|
-
} catch {
|
|
39
|
-
} finally {
|
|
40
|
-
r = !1;
|
|
41
|
-
}
|
|
42
|
-
}
|
|
43
|
-
if (t && N(t)) {
|
|
44
|
-
u(T(t));
|
|
45
|
-
const c = m.getState().token;
|
|
46
|
-
B().then((D) => {
|
|
47
|
-
e || u(D);
|
|
48
|
-
}).catch(() => {
|
|
49
|
-
!e && c && (localStorage.removeItem("z_team_token"), m.setState({ token: "" }));
|
|
50
|
-
}).finally(() => {
|
|
51
|
-
e || E(!0);
|
|
52
|
-
});
|
|
53
|
-
return;
|
|
54
|
-
}
|
|
55
|
-
if (n >= h) {
|
|
56
|
-
v();
|
|
57
|
-
return;
|
|
58
|
-
}
|
|
59
|
-
if (o += 1, o >= a) {
|
|
60
|
-
v();
|
|
61
|
-
return;
|
|
62
|
-
}
|
|
63
|
-
window.setTimeout(() => void l(), 150);
|
|
64
|
-
};
|
|
65
|
-
l();
|
|
66
|
-
})(), () => {
|
|
67
|
-
e = !0;
|
|
68
|
-
};
|
|
69
|
-
}, [u]), U(() => {
|
|
70
|
-
if (!b || !d) return;
|
|
71
|
-
let e = !1;
|
|
72
|
-
return (async () => {
|
|
73
|
-
try {
|
|
74
|
-
const a = m.getState(), r = /* @__PURE__ */ new Date(), n = (c) => String(c).padStart(2, "0"), h = `${r.getFullYear()}-${n(r.getMonth() + 1)}-${n(
|
|
75
|
-
r.getDate()
|
|
76
|
-
)} ${n(r.getHours())}:${n(r.getMinutes())}`, k = `${S} - ${d.display_name || d.username} - ${h}`;
|
|
77
|
-
y("正在创建咨询群组…");
|
|
78
|
-
const l = await Y(
|
|
79
|
-
{
|
|
80
|
-
name: k,
|
|
81
|
-
description: `${_} 发起的在线咨询`,
|
|
82
|
-
workspace_path: `webide_consult_${Date.now()}`,
|
|
83
|
-
scenario_code: "z_team_webide_console_scenario"
|
|
84
|
-
},
|
|
85
|
-
a.token
|
|
86
|
-
);
|
|
87
|
-
if (e || (f("群组已创建", "正在初始化工作区…"), await $(l), e)) return;
|
|
88
|
-
const t = m.getState();
|
|
89
|
-
if (t.currentProject && await t.refreshProjectPanels(
|
|
90
|
-
t.currentProject.id,
|
|
91
|
-
t.projectSwitchSeq,
|
|
92
|
-
!1
|
|
93
|
-
), e) return;
|
|
94
|
-
f("工作区已就绪", "即将进入工作台…"), H.replace(
|
|
95
|
-
G({
|
|
96
|
-
projectId: l.id,
|
|
97
|
-
search: i.search
|
|
98
|
-
})
|
|
99
|
-
);
|
|
100
|
-
} catch (a) {
|
|
101
|
-
e || x(a instanceof Error ? a.message : "创建群组失败");
|
|
102
|
-
}
|
|
103
|
-
})(), () => {
|
|
104
|
-
e = !0;
|
|
105
|
-
};
|
|
106
|
-
}, [
|
|
107
|
-
b,
|
|
108
|
-
d,
|
|
109
|
-
S,
|
|
110
|
-
_,
|
|
111
|
-
$,
|
|
112
|
-
f,
|
|
113
|
-
i.search
|
|
114
|
-
]), j ? /* @__PURE__ */ s("div", { className: "embed-chat-page embed-chat-page--error", children: /* @__PURE__ */ s("p", { children: j }) }) : /* @__PURE__ */ s("div", { className: "embed-chat-page embed-chat-page--loading", children: /* @__PURE__ */ C("div", { className: "embed-chat-page__panel", children: [
|
|
115
|
-
/* @__PURE__ */ s(R, { size: "large" }),
|
|
116
|
-
/* @__PURE__ */ s("p", { className: "embed-chat-page__step", children: I }),
|
|
117
|
-
w.length > 0 ? /* @__PURE__ */ s("ul", { className: "embed-chat-page__done-list", children: w.filter((e) => e.trim().length > 0).map((e, o) => /* @__PURE__ */ C(
|
|
118
|
-
"li",
|
|
119
|
-
{
|
|
120
|
-
className: "embed-chat-page__done-item",
|
|
121
|
-
children: [
|
|
122
|
-
/* @__PURE__ */ s(q, { className: "embed-chat-page__done-icon" }),
|
|
123
|
-
/* @__PURE__ */ s("span", { children: e })
|
|
124
|
-
]
|
|
125
|
-
},
|
|
126
|
-
`${o}-${e}`
|
|
127
|
-
)) }) : null
|
|
128
|
-
] }) });
|
|
129
|
-
}
|
|
130
|
-
export {
|
|
131
|
-
oe as default
|
|
132
|
-
};
|