@yuku123/z-team-component 0.2.8 → 0.2.9

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.
Files changed (33) hide show
  1. package/dist/{InvitationManagementPage-DEBZvFZU.js → InvitationManagementPage-Bu_T6Qnk.js} +2 -2
  2. package/dist/{OnboardingPage-Bi3S5eug.js → OnboardingPage-CVQsHBNI.js} +2 -2
  3. package/dist/ProjectApp-CZp1-5DE.js +5417 -0
  4. package/dist/admin-logs-CjrLXc1w.js +199 -0
  5. package/dist/{api-3Ur1kq2A.js → api-C3oQuHQN.js} +653 -549
  6. package/dist/api-CGeI8Nl6.js +19 -0
  7. package/dist/{createWorkspaceWsHandler-CSAGqlPX.js → createWorkspaceWsHandler--EYvkQTh.js} +71 -71
  8. package/dist/{ctc-sso-C-QWy9F8.js → ctc-sso-B62FfkZg.js} +1 -0
  9. package/dist/index-89atN3Sn.js +3299 -0
  10. package/dist/index-B3WkjkoJ.js +13641 -0
  11. package/dist/{index-CsCPAoPb.js → index-BAbMvA6l.js} +18 -18
  12. package/dist/{index-DMEjkEMq.js → index-BbXwe7Mu.js} +4 -4
  13. package/dist/{index-C8uSn9eX.js → index-BnXt3lMS.js} +2 -2
  14. package/dist/{index-D3DF6vFc.js → index-CC82pWGq.js} +5 -5
  15. package/dist/{index-wXqXyXmm.js → index-CibhFgCi.js} +3 -3
  16. package/dist/{index-DNyYOedu.js → index-DH7Mt7zI.js} +58 -63
  17. package/dist/{index-Cml0C09P.js → index-DL3Nsor4.js} +2580 -2460
  18. package/dist/{index-BIVN--Bi.js → index-DnqloQgt.js} +1 -1
  19. package/dist/{index-CPUeMpa8.js → index-EPCmZ1QV.js} +5 -5
  20. package/dist/{index-C6SfK489.js → index-psNYztRR.js} +7 -7
  21. package/dist/index.js +1 -1
  22. package/dist/{instance-ClduEMxs.js → instance-DUBRC_44.js} +1 -1
  23. package/dist/pages.js +1 -1
  24. package/dist/{send-default-agent-team-message-B3Qon0X2.js → send-default-agent-team-message-DHaZl06Z.js} +1 -1
  25. package/dist/{sso-user-BOEGMUJA.js → sso-user-BRC1vEjR.js} +1 -1
  26. package/dist/{useAppStore-D8PnbXea.js → useAppStore-D1Z2M3Za.js} +1 -1
  27. package/dist/z-team-component.css +1 -1
  28. package/package.json +3 -2
  29. package/dist/LowCodePage-yemTBcZ4.js +0 -17
  30. package/dist/ProjectApp-9qtrgr7d.js +0 -6710
  31. package/dist/admin-logs-BIRWnOwM.js +0 -254
  32. package/dist/api-B2d2enyL.js +0 -20
  33. package/dist/index-B_YVSwmJ.js +0 -11710
@@ -0,0 +1,19 @@
1
+ import "@yuku123/z-frontend-common";
2
+ import { a } from "./ProjectApp-CZp1-5DE.js";
3
+ import "react/jsx-runtime";
4
+ import "react";
5
+ import "antd";
6
+ import "@ant-design/icons";
7
+ const r = () => a.get("/ctc/authn/my-tenants"), p = (t, s) => a.post("/ctc/authn/select-tenant", { tenantCode: t, domainCode: "" }), v = (t) => a.post("/ctc/ac/invitations", t), l = (t) => a.post("/ctc/ac/invitations/accept", { token: t }), d = (t) => a.post("/ctc/ac/invitations/redeem", { code: t }), u = (t) => a.get("/ctc/ac/invitations", { params: { tenantCode: t } }), b = (t, s) => a.post(`/ctc/ac/invitations/${t}/revoke`, null, { params: { tenantCode: s } }), g = (t) => a.get("/ctc/ac/invitations/members", { params: { tenantCode: t } }), I = (t, s) => a.post(`/ctc/ac/invitations/members/${t}/remove`, null, { params: { tenantCode: s } }), h = (t) => a.post("/ctc/ac/invitations/leave", null, { params: { tenantCode: t } });
8
+ export {
9
+ l as a,
10
+ g as b,
11
+ h as c,
12
+ I as d,
13
+ b as e,
14
+ v as f,
15
+ r as g,
16
+ u as l,
17
+ d as r,
18
+ p as s
19
+ };
@@ -3,13 +3,13 @@ import { ShareAltOutlined as ro, EditOutlined as io, EyeOutlined as Ar, FileText
3
3
  import { message as Ue, Drawer as Ss, Spin as lt, Input as pn, Button as Xe, Segmented as zr, AutoComplete as Jr, Modal as Ln, Typography as jt, Checkbox as _s, Space as rn, Radio as ma, Skeleton as Gn, Popover as gs, Timeline as pa, Tag as at, Tooltip as qn, Tree as Kr, Empty as cn, Dropdown as Qr, Progress as Yr, Collapse as ha } from "antd";
4
4
  import ot, { useState as N, useRef as ve, useEffect as de, useCallback as U, useMemo as Ne, useLayoutEffect as _o, memo as go, useImperativeHandle as Xr } from "react";
5
5
  import { createPortal as fo } from "react-dom";
6
- import { e as Ie, az as Ke, aA as Bt, f as Pe, d as ht, B as Fe, at as Zr, m as Ut, X as yo, H as ei, t as we, aB as ti, aC as ni, aD as si, K as Ee, aE as ai, i as ln, aF as oi, aG as ri, v as ii, Y as ci, aH as _a, T as ws, aI as Nt, a3 as ga, s as li, a8 as di, aJ as ui, aK as fa, aL as ya, aM as mi, aN as pi, aO as hi } from "./api-3Ur1kq2A.js";
7
- import { c as _i, d as gi, j as fi, g as yi, r as ki, e as bi, h as vi, i as Ti, k as Ni } from "./instance-ClduEMxs.js";
8
- import { u as O, i as ko, s as z, a as Is, n as Xn, h as Ci, r as bo, b as vo, m as Si, c as To, d as No, e as Co, p as wi, g as Ii, j as Ai, k as xi, l as Et, o as Ft, q as qi, t as Li, v as Bi, w as Ri, x as Pi, y as $i, z as Di, A as Mi, B as Ei, C as Fi, D as Oi, E as Hi, F as As, G as So, H as ka, I as Gi } from "./useAppStore-D8PnbXea.js";
6
+ import { e as Ie, aD as Ke, aE as Bt, f as Pe, d as ht, B as Fe, ax as Zr, m as Ut, X as yo, H as ei, t as we, aF as ti, aG as ni, aH as si, K as Ee, aI as ws, aJ as ko, aK as fs, aL as Is, aM as ai, aN as oi, aO as ri, i as ln, aP as ii, aQ as ci, v as li, Y as di, aR as _a, T as As, aS as Nt, a3 as ga, s as ui, a8 as mi, aT as pi, aU as fa, aV as ya, aW as hi, aX as _i, aY as gi } from "./api-C3oQuHQN.js";
7
+ import { c as fi, d as yi, j as ki, g as bi, r as vi, e as Ti, h as Ni, i as Ci, k as Si } from "./instance-DUBRC_44.js";
8
+ import { u as O, i as bo, s as z, a as xs, n as Xn, h as wi, r as vo, b as To, m as Ii, c as No, d as Co, e as So, p as Ai, g as xi, j as qi, k as Li, l as Et, o as Ft, q as Bi, t as Ri, v as Pi, w as $i, x as Di, y as Mi, z as Ei, A as Fi, B as Oi, C as Hi, D as Gi, E as Wi, F as qs, G as wo, H as ka, I as Ui } from "./useAppStore-D1Z2M3Za.js";
9
9
  import kt from "react-markdown";
10
10
  import xn from "rehype-highlight";
11
11
  import bt from "remark-gfm";
12
- import { g as Wi, u as Ui, b as ji, h as xs, i as wo, r as fs, j as qs, k as Vi, l as zi, m as Ji, n as Ki, t as Qi } from "./admin-logs-BIRWnOwM.js";
12
+ import { g as ji, u as Vi, b as zi, h as Ji, i as Ki, t as Qi } from "./admin-logs-CjrLXc1w.js";
13
13
  import Oe from "handlebars";
14
14
  const ba = (t) => Symbol.iterator in t, va = (t) => (
15
15
  // HACK: avoid checking entries type
@@ -347,7 +347,7 @@ function mc({
347
347
  }) {
348
348
  const [m, u] = N(!1), [k, l] = N(null), [y, w] = N("edit"), [f, S] = N(""), [b, V] = N(""), [B, R] = N(!1), [ee, L] = N("idle"), [$, I] = N(!1), v = ve(null), E = ve(null), ie = ve(""), A = ve("");
349
349
  de(() => {
350
- !t || !a || (u(!0), R(!1), L("idle"), Wi(a, s, c || "", i).then((T) => {
350
+ !t || !a || (u(!0), R(!1), L("idle"), ji(a, s, c || "", i).then((T) => {
351
351
  l(T), S(T.title), V(T.content ?? ""), E.current = T.id, ie.current = T.content ?? "", A.current = T.title, d == null || d(!!(T.content && T.content.trim()));
352
352
  }).catch(() => {
353
353
  l(null);
@@ -355,7 +355,7 @@ function mc({
355
355
  }, [t, a, s, c, i]);
356
356
  const W = U(() => {
357
357
  const T = E.current;
358
- T != null && (L("saving"), Ui(
358
+ T != null && (L("saving"), Vi(
359
359
  T,
360
360
  { title: A.current, content: ie.current },
361
361
  i
@@ -377,7 +377,7 @@ function mc({
377
377
  if (k) {
378
378
  I(!0);
379
379
  try {
380
- const T = await ji(k.id, i), K = `${window.location.origin}/note/shared?token=${T}`;
380
+ const T = await zi(k.id, i), K = `${window.location.origin}/note/shared?token=${T}`;
381
381
  let Z = !1;
382
382
  try {
383
383
  await navigator.clipboard.writeText(K), Z = !0;
@@ -1892,7 +1892,7 @@ function iu(t) {
1892
1892
  }
1893
1893
  function cu(t) {
1894
1894
  const { openDialog: n, openSkillPicker: a } = t, s = O((_) => _.currentUser), c = O((_) => _.currentProject), i = O((_) => _.isLocal), d = O((_) => _.deleteScenarioInstance), m = O((_) => _.forkScenarioInstance), u = O((_) => _.updateScenarioInstance), k = O((_) => _.deleteFile), l = O((_) => _.uploadFile), y = O((_) => _.uploadFolder), w = O((_) => _.downloadFile), f = O((_) => _.refreshAgentSkills), S = O((_) => _.refreshAllAgentSkills), b = O((_) => _.syncFromProduction), V = Ne(
1895
- () => ko(s),
1895
+ () => bo(s),
1896
1896
  [s]
1897
1897
  ), [B, R] = N(null), [ee, L] = N({ x: 0, y: 0 }), [$, I] = N(!1), v = ve(null), E = ve(null);
1898
1898
  de(() => {
@@ -2305,7 +2305,7 @@ function vu({
2305
2305
  const Tu = go(vu);
2306
2306
  function Nu() {
2307
2307
  const t = O((A) => A.currentProject), n = O((A) => A.currentUser), a = O((A) => A.allSkills), s = O((A) => A.skills), c = O((A) => A.loadFileTree), i = O((A) => A.updateScenarioInstance), d = O((A) => A.renameFile), m = O((A) => A.createFile), u = O((A) => A.createFolder), k = O((A) => A.loadAllSkills), l = O((A) => A.addProjectSkill), y = O((A) => A.removeProjectSkill), { hasTabs: w } = Ro(), f = Ne(
2308
- () => ko(n),
2308
+ () => bo(n),
2309
2309
  [n]
2310
2310
  ), [S, b] = N(null), [V, B] = N(!1), R = U(() => B(!0), []), { handleContextMenu: ee, menuNode: L } = cu({
2311
2311
  openDialog: b,
@@ -2972,7 +2972,7 @@ function $1(t) {
2972
2972
  return [{ type: "reasoning", name: s, text: a }];
2973
2973
  }
2974
2974
  function D1(t) {
2975
- return $1(t).filter((n) => !Is(n)).map((n) => ({
2975
+ return $1(t).filter((n) => !xs(n)).map((n) => ({
2976
2976
  ...n,
2977
2977
  type: "reasoning"
2978
2978
  }));
@@ -4273,13 +4273,13 @@ function Xo(t) {
4273
4273
  return Ps(t.fields);
4274
4274
  }
4275
4275
  function wk(t) {
4276
- return t === To ? "已提交" : t === No ? "已取消" : t === Co ? "已失败" : null;
4276
+ return t === No ? "已提交" : t === Co ? "已取消" : t === So ? "已失败" : null;
4277
4277
  }
4278
4278
  function Qn(t) {
4279
4279
  const n = t.cardForm ? Xo(t.cardForm) : [];
4280
4280
  if (n.length === 0)
4281
4281
  return {};
4282
- const a = Sk(n), s = bo(t);
4282
+ const a = Sk(n), s = vo(t);
4283
4283
  for (const c of n)
4284
4284
  s[c.name] !== void 0 && (a[c.name] = Ds(
4285
4285
  c,
@@ -4295,18 +4295,18 @@ function Zo(t) {
4295
4295
  if (!t)
4296
4296
  return !1;
4297
4297
  const n = t.humanTaskStatus;
4298
- return n === To || n === No || n === Co || ((a = t.cardForm) == null ? void 0 : a.status) === "submitted";
4298
+ return n === No || n === Co || n === So || ((a = t.cardForm) == null ? void 0 : a.status) === "submitted";
4299
4299
  }
4300
4300
  function Ga(t, n) {
4301
- return !(t != null && t.humanTaskId) || !n ? !1 : Ci(bo(t)) ? !0 : !(Zo(t) || t.pending === !1);
4301
+ return !(t != null && t.humanTaskId) || !n ? !1 : wi(vo(t)) ? !0 : !(Zo(t) || t.pending === !1);
4302
4302
  }
4303
4303
  async function Ak(t, n) {
4304
- const a = vo(t) ?? t, s = Qn(a);
4304
+ const a = To(t) ?? t, s = Qn(a);
4305
4305
  if (!Zo(a) || Ik(s))
4306
4306
  return a;
4307
4307
  try {
4308
- const c = await xs(a.humanTaskId ?? n);
4309
- return Si(a, c);
4308
+ const c = await ws(a.humanTaskId ?? n);
4309
+ return Ii(a, c);
4310
4310
  } catch {
4311
4311
  return a;
4312
4312
  }
@@ -4615,7 +4615,7 @@ function er({
4615
4615
  (L) => {
4616
4616
  L.stopPropagation(), u(
4617
4617
  "continue",
4618
- () => wo(t.id),
4618
+ () => ko(t.id),
4619
4619
  1,
4620
4620
  "Agent 已重新调度,继续执行中…"
4621
4621
  );
@@ -4645,7 +4645,7 @@ function er({
4645
4645
  (L) => {
4646
4646
  L.stopPropagation(), u(
4647
4647
  "complete",
4648
- () => qs(t.id, t.result ?? void 0),
4648
+ () => Is(t.id, t.result ?? void 0),
4649
4649
  3,
4650
4650
  "任务已完成"
4651
4651
  );
@@ -4655,7 +4655,7 @@ function er({
4655
4655
  (L) => {
4656
4656
  L.stopPropagation(), u(
4657
4657
  "suspend",
4658
- () => Vi(t.id),
4658
+ () => ai(t.id),
4659
4659
  2,
4660
4660
  "任务已挂起,可在任务会话中继续沟通"
4661
4661
  );
@@ -4663,7 +4663,7 @@ function er({
4663
4663
  [u, t.id]
4664
4664
  ), S = U(
4665
4665
  (L) => {
4666
- L.stopPropagation(), u("cancel", () => zi(t.id), 5, "任务已取消");
4666
+ L.stopPropagation(), u("cancel", () => oi(t.id), 5, "任务已取消");
4667
4667
  },
4668
4668
  [u, t.id]
4669
4669
  );
@@ -4752,7 +4752,7 @@ function tr({
4752
4752
  messages: n,
4753
4753
  onScrollToMessage: a
4754
4754
  }) {
4755
- const s = wi(t.content), c = Ii(t.content), i = Ai(t, n);
4755
+ const s = Ai(t.content), c = xi(t.content), i = qi(t, n);
4756
4756
  return c ? /* @__PURE__ */ r("div", { className: o.turnSummaryInline, children: [
4757
4757
  (s == null ? void 0 : s.triggerMessageId) != null && a ? /* @__PURE__ */ r(
4758
4758
  "button",
@@ -4770,7 +4770,7 @@ function tr({
4770
4770
  ] }) : null;
4771
4771
  }
4772
4772
  const tn = (t) => {
4773
- const n = t.src, a = n && n.startsWith("https://cdn.nlark.com/") ? `${ai}/image-proxy?url=${encodeURIComponent(n)}` : n;
4773
+ const n = t.src, a = n && n.startsWith("https://cdn.nlark.com/") ? `${ri}/image-proxy?url=${encodeURIComponent(n)}` : n;
4774
4774
  return /* @__PURE__ */ e("img", { ...t, src: a });
4775
4775
  }, Wn = 6e3;
4776
4776
  function us({
@@ -5043,7 +5043,7 @@ function Yb({
5043
5043
  function ja(t) {
5044
5044
  const n = [];
5045
5045
  for (const a of t) {
5046
- if (Is(a))
5046
+ if (xs(a))
5047
5047
  continue;
5048
5048
  const s = n[n.length - 1];
5049
5049
  if (a.type === "reasoning" && (s == null ? void 0 : s.type) === "reasoning") {
@@ -5232,7 +5232,7 @@ function za({ taskId: t, agentName: n }) {
5232
5232
  const a = O((m) => m.openTaskChat), [s, c] = N(null);
5233
5233
  de(() => {
5234
5234
  let m = !0;
5235
- return xs(t).then((u) => {
5235
+ return ws(t).then((u) => {
5236
5236
  !m || !u || c({
5237
5237
  id: we(u.id ?? t),
5238
5238
  status: Number(u.status ?? 0),
@@ -5296,7 +5296,7 @@ function rv({
5296
5296
  }
5297
5297
  s(!0);
5298
5298
  try {
5299
- await qs(c.taskId, c.resultPreview), z("任务已完成");
5299
+ await Is(c.taskId, c.resultPreview), z("任务已完成");
5300
5300
  } catch (d) {
5301
5301
  z(d instanceof Error ? d.message : "确认失败", "error");
5302
5302
  } finally {
@@ -5397,7 +5397,7 @@ const cv = ot.memo(
5397
5397
  plain: ((J = F[0]) == null ? void 0 : J.text) ?? n.content
5398
5398
  };
5399
5399
  }, [n.id, n.content, n.sender_type]), $ = Ne(
5400
- () => xi(n, c),
5400
+ () => Li(n, c),
5401
5401
  [n, c]
5402
5402
  ), I = n.sender_type === "AGENT", v = I, E = O((F) => F.openAgentProfile), ie = O((F) => F.humanAssistCards), A = (() => {
5403
5403
  if (!I) return null;
@@ -5993,7 +5993,7 @@ const cv = ot.memo(
5993
5993
  }
5994
5994
  );
5995
5995
  }
5996
- const p = qi(n.content) && n.content !== "已取消" && n.content !== "已挂起", D = {
5996
+ const p = Bi(n.content) && n.content !== "已取消" && n.content !== "已挂起", D = {
5997
5997
  width: "fit-content",
5998
5998
  maxWidth: "100%"
5999
5999
  }, te = u && !k, ue = nr(n.ext || null), qe = (F, ae = te) => {
@@ -6013,7 +6013,7 @@ const cv = ot.memo(
6013
6013
  };
6014
6014
  })();
6015
6015
  if (!H.hasStructuredBlocks) {
6016
- const j = H.plain, P = Li(n), ge = !P && /[#*_`()>|~\-]/.test(j);
6016
+ const j = H.plain, P = Ri(n), ge = !P && /[#*_`()>|~\-]/.test(j);
6017
6017
  if (Mt(j)) {
6018
6018
  const me = j.search(/\[\[CARD_FORM:/i), Ce = j.indexOf("{"), Re = me >= 0 ? me : Ce >= 0 && (j.includes('"fields"') || j.includes('"title"')) ? Ce : -1, Ge = Re > 0 ? j.slice(0, Re).trim() : "", Ve = (Re >= 0 ? j.slice(Re) : j).replace(/\[\[CARD_FORM:[^\]]+\]\]/gi, "").replace(/\[\[\/CARD_FORM\]\]/gi, "").trim();
6019
6019
  return /* @__PURE__ */ r(be, { children: [
@@ -6146,7 +6146,7 @@ const cv = ot.memo(
6146
6146
  return /* @__PURE__ */ e("div", { className: o.toolCollapsedSummary, children: me }, P);
6147
6147
  }
6148
6148
  if (j.type === "reasoning")
6149
- return Is(j) ? null : /* @__PURE__ */ e(
6149
+ return xs(j) ? null : /* @__PURE__ */ e(
6150
6150
  Yb,
6151
6151
  {
6152
6152
  name: j.name,
@@ -6855,14 +6855,14 @@ const Fs = ot.memo(function({
6855
6855
  var J;
6856
6856
  (J = document.getElementById(`chat-msg-${H}`)) == null || J.scrollIntoView({ behavior: "smooth", block: "center" });
6857
6857
  }, F = Ne(
6858
- () => Bi(a),
6858
+ () => Pi(a),
6859
6859
  [a]
6860
6860
  ), ae = Ne(() => {
6861
6861
  const H = /* @__PURE__ */ new Set();
6862
6862
  return F.forEach((J) => {
6863
6863
  H.add(J.id);
6864
6864
  }), a.filter(
6865
- (J) => !H.has(J.id) && !Ri(J)
6865
+ (J) => !H.has(J.id) && !$i(J)
6866
6866
  );
6867
6867
  }, [a, F]);
6868
6868
  return /* @__PURE__ */ r(be, { children: [
@@ -6885,7 +6885,7 @@ const Fs = ot.memo(function({
6885
6885
  ] }),
6886
6886
  s && !c && a.length === 0 ? /* @__PURE__ */ e("div", { className: o.emptyMessages, children: "暂无消息" }) : null,
6887
6887
  s && ae.map((H) => {
6888
- if (Pi(H))
6888
+ if (Di(H))
6889
6889
  return /* @__PURE__ */ e("div", { id: `chat-msg-${H.id}`, children: /* @__PURE__ */ e(
6890
6890
  tr,
6891
6891
  {
@@ -6894,17 +6894,17 @@ const Fs = ot.memo(function({
6894
6894
  onScrollToMessage: qe
6895
6895
  }
6896
6896
  ) }, H.id);
6897
- H.sender_type === "AGENT" && (H.content === "处理中..." || H.content === "🔄 正在处理中..." || $i(H.content));
6898
- const J = Di(
6897
+ H.sender_type === "AGENT" && (H.content === "处理中..." || H.content === "🔄 正在处理中..." || Mi(H.content));
6898
+ const J = Ei(
6899
6899
  H,
6900
6900
  V
6901
- ), re = J != null ? V[J] : void 0, j = (re == null ? void 0 : re.stepName) === "排队中", P = J != null && H.content !== "已取消" && !j || Mi(H, a) && Ei(H, V), ge = H.sender_type === "AGENT" ? F.get(H.id) : void 0;
6901
+ ), re = J != null ? V[J] : void 0, j = (re == null ? void 0 : re.stepName) === "排队中", P = J != null && H.content !== "已取消" && !j || Fi(H, a) && Oi(H, V), ge = H.sender_type === "AGENT" ? F.get(H.id) : void 0;
6902
6902
  return /* @__PURE__ */ e("div", { id: `chat-msg-${H.id}`, children: /* @__PURE__ */ e(
6903
6903
  cv,
6904
6904
  {
6905
6905
  msg: H,
6906
- formatTime: Fi,
6907
- isOwn: Oi(
6906
+ formatTime: Hi,
6907
+ isOwn: Gi(
6908
6908
  n,
6909
6909
  H,
6910
6910
  f,
@@ -6975,7 +6975,7 @@ const Fs = ot.memo(function({
6975
6975
  });
6976
6976
  function mv(t, n, a, s, c) {
6977
6977
  const i = ve(-1), d = ve(""), m = U(() => {
6978
- const w = Hi;
6978
+ const w = Wi;
6979
6979
  return t.filter((f) => w(f, n, a, s)).map((f) => f.content).reverse();
6980
6980
  }, [t, n, a, s, c]), u = U(() => i.current !== -1, []), k = U(
6981
6981
  (w) => {
@@ -7009,14 +7009,14 @@ const Qa = 40, pv = 480, hv = 640, _v = 0.6, gv = ot.forwardRef(function({
7009
7009
  const k = O((h) => h.hideToolCalls), l = O((h) => h.toggleHideToolCalls), y = O((h) => h.members), w = O((h) => h.skills), f = O((h) => h.currentProject), S = O((h) => h.currentUser), b = O((h) => h.messages), V = O(
7010
7010
  (h) => h.markPendingTeamChatContent
7011
7011
  ), B = O((h) => h.sendTeamMessage), R = O((h) => h.loadMembers), ee = O((h) => h.clearTeamMessages), L = O((h) => h.sendTaskChatMessage), $ = O((h) => h.activeTaskChat), I = O((h) => h.taskMessages), v = Ne(
7012
- () => As(y, S) ?? null,
7012
+ () => qs(y, S) ?? null,
7013
7013
  [S, y]
7014
7014
  ), E = s === "task" ? I : b, { navigateUp: ie, navigateDown: A, resetHistory: W, isNavigating: q } = mv(E, v, S, y, s), [X, ce] = N(""), [_, M] = N(!1), T = ve(!1), K = ve(0), [Z, _e] = N({ show: !1, query: "", cursor: 0, selectedIndex: 0 }), [xe, x] = N(!1), [p, D] = N(!1), [te, ue] = N("dispatch");
7015
7015
  de(() => {
7016
7016
  const h = f == null ? void 0 : f.id;
7017
7017
  if (!h) return;
7018
7018
  let ne = !1;
7019
- return oi(h).then((le) => {
7019
+ return ii(h).then((le) => {
7020
7020
  ne || ue(le);
7021
7021
  }).catch(() => {
7022
7022
  }), () => {
@@ -7031,7 +7031,7 @@ const Qa = 40, pv = 480, hv = 640, _v = 0.6, gv = ot.forwardRef(function({
7031
7031
  const le = te;
7032
7032
  ue(h);
7033
7033
  try {
7034
- const Q = await ri(ne, h);
7034
+ const Q = await ci(ne, h);
7035
7035
  ue(Q), z(
7036
7036
  h === "human" ? "已切换为真人模式,下一条消息起生效" : h === "shadow" ? "已切换为旁路观察" : "已切换为派单模式"
7037
7037
  );
@@ -7117,7 +7117,7 @@ const Qa = 40, pv = 480, hv = 640, _v = 0.6, gv = ot.forwardRef(function({
7117
7117
  };
7118
7118
  return document.addEventListener("mousedown", h), () => document.removeEventListener("mousedown", h);
7119
7119
  }, [p]), de(() => {
7120
- f && _i(f.id).then(rt).catch(console.error);
7120
+ f && fi(f.id).then(rt).catch(console.error);
7121
7121
  }, [f == null ? void 0 : f.id]), de(() => {
7122
7122
  if (!dt) return;
7123
7123
  const h = (ne) => {
@@ -7196,7 +7196,7 @@ const Qa = 40, pv = 480, hv = 640, _v = 0.6, gv = ot.forwardRef(function({
7196
7196
  if (F.length > 0) {
7197
7197
  J(!0);
7198
7198
  try {
7199
- Q = await ii(F);
7199
+ Q = await li(F);
7200
7200
  } catch ($e) {
7201
7201
  console.error("图片上传失败", $e), z("图片上传失败,请重试", "error"), J(!1);
7202
7202
  return;
@@ -7642,7 +7642,7 @@ const Qa = 40, pv = 480, hv = 640, _v = 0.6, gv = ot.forwardRef(function({
7642
7642
  )) {
7643
7643
  Ve(!0), D(!1);
7644
7644
  try {
7645
- const h = await ci(f.id);
7645
+ const h = await di(f.id);
7646
7646
  z(
7647
7647
  (h == null ? void 0 : h.message) || "技能已刷新",
7648
7648
  (h == null ? void 0 : h.ok) === !1 ? "warning" : "success"
@@ -8251,7 +8251,7 @@ function yv({
8251
8251
  loadTaskMessages: W.loadTaskMessages
8252
8252
  }))
8253
8253
  ), [S, b] = N(!1), [V, B] = N(null), [R, ee] = N(null), L = U(() => B(null), []), $ = Ne(
8254
- () => As(s, a) ?? null,
8254
+ () => qs(s, a) ?? null,
8255
8255
  [a, s]
8256
8256
  );
8257
8257
  de(() => {
@@ -8260,7 +8260,7 @@ function yv({
8260
8260
  return;
8261
8261
  }
8262
8262
  let W = !1;
8263
- return xs(l.taskId).then((q) => {
8263
+ return ws(l.taskId).then((q) => {
8264
8264
  W || ee({
8265
8265
  id: String(q.id ?? ""),
8266
8266
  status: Number(q.status ?? 0),
@@ -8282,7 +8282,7 @@ function yv({
8282
8282
  ([, q]) => q.task_id === l.taskId
8283
8283
  )
8284
8284
  );
8285
- return So(W);
8285
+ return wo(W);
8286
8286
  }, [l, c]), E = U(
8287
8287
  async (W) => {
8288
8288
  try {
@@ -8477,7 +8477,7 @@ function Nv() {
8477
8477
  u(!0), l(null);
8478
8478
  try {
8479
8479
  const _ = await fetch(
8480
- `${ws}/tasks/project/${t.id}`,
8480
+ `${As}/tasks/project/${t.id}`,
8481
8481
  {
8482
8482
  credentials: "include",
8483
8483
  headers: {
@@ -8512,7 +8512,7 @@ function Nv() {
8512
8512
  ), ee = U(
8513
8513
  async (_) => {
8514
8514
  try {
8515
- await qs(_.id, _.result ?? void 0), z("任务已完成"), await B();
8515
+ await Is(_.id, _.result ?? void 0), z("任务已完成"), await B();
8516
8516
  } catch (M) {
8517
8517
  z(M instanceof Error ? M.message : "完成任务失败", "error");
8518
8518
  }
@@ -8530,7 +8530,7 @@ function Nv() {
8530
8530
  ), $ = U(
8531
8531
  async (_) => {
8532
8532
  try {
8533
- await wo(_.id), z("已触发执行"), await B();
8533
+ await ko(_.id), z("已触发执行"), await B();
8534
8534
  } catch (M) {
8535
8535
  z(M instanceof Error ? M.message : "执行失败", "error");
8536
8536
  }
@@ -9505,11 +9505,11 @@ function UT({
9505
9505
  return (async () => {
9506
9506
  i(!0);
9507
9507
  try {
9508
- const D = await gi(a);
9508
+ const D = await yi(a);
9509
9509
  if (x) return;
9510
9510
  const te = we(D.scenario_instance_id);
9511
- if (v.current = te, m(te), await fi(te, a), x) return;
9512
- const ue = await di(te);
9511
+ if (v.current = te, m(te), await ki(te, a), x) return;
9512
+ const ue = await mi(te);
9513
9513
  if (x) return;
9514
9514
  const qe = ue.map((H) => ({
9515
9515
  ...H,
@@ -9532,7 +9532,7 @@ function UT({
9532
9532
  const X = U(
9533
9533
  (x) => {
9534
9534
  ce();
9535
- const p = ui(x, a), D = new WebSocket(p);
9535
+ const p = pi(x, a), D = new WebSocket(p);
9536
9536
  I.current = D, D.onopen = () => {
9537
9537
  ie.current = 0, console.log("[SelfSupport WS] connected");
9538
9538
  }, D.onmessage = (te) => {
@@ -9624,7 +9624,7 @@ function UT({
9624
9624
  ref_id: ue.ref_id
9625
9625
  } : qe = { content: x, message_type: "TEXT" }, ee(!0), B(""), $({ show: !1, query: "", cursor: 0, selectedIndex: 0 });
9626
9626
  try {
9627
- const F = await li(d, qe, a);
9627
+ const F = await ui(d, qe, a);
9628
9628
  F && k((ae) => [...ae, F]);
9629
9629
  } catch (F) {
9630
9630
  console.error("[SelfSupportDrawer] send error:", F), B(x);
@@ -9789,7 +9789,7 @@ function UT({
9789
9789
  );
9790
9790
  }
9791
9791
  async function Pn(t, n) {
9792
- const a = n != null && n.params ? `?${new URLSearchParams(n.params).toString()}` : "", c = await (await fetch(`${ws}${t}${a}`, {
9792
+ const a = n != null && n.params ? `?${new URLSearchParams(n.params).toString()}` : "", c = await (await fetch(`${As}${t}${a}`, {
9793
9793
  credentials: "include",
9794
9794
  headers: {
9795
9795
  Accept: "application/json",
@@ -9817,7 +9817,7 @@ async function MS(t) {
9817
9817
  var n;
9818
9818
  try {
9819
9819
  const s = await (await fetch(
9820
- `${ws}/fone/scenario-instance?workItemId=${encodeURIComponent(
9820
+ `${As}/fone/scenario-instance?workItemId=${encodeURIComponent(
9821
9821
  t
9822
9822
  )}`,
9823
9823
  {
@@ -11184,7 +11184,7 @@ function OS({
11184
11184
  ), qt = U(
11185
11185
  async (g) => {
11186
11186
  try {
11187
- const G = await mi(g);
11187
+ const G = await hi(g);
11188
11188
  G.ok ? z("已重置为待审批", "success") : z(G.error || "操作失败", "error");
11189
11189
  } catch (G) {
11190
11190
  console.error("重置失败", G), Ee(G) || z("操作失败,请稍后重试", "error");
@@ -11418,7 +11418,7 @@ function OS({
11418
11418
  }
11419
11419
  }, [l == null ? void 0 : l.workspace_path, l == null ? void 0 : l.id]);
11420
11420
  de(() => {
11421
- (me || Dn) && l && Re.length === 0 && yi(l.id).then(Ge).catch((g) => console.error("[ChatPanel] 获取关单标签失败:", g));
11421
+ (me || Dn) && l && Re.length === 0 && bi(l.id).then(Ge).catch((g) => console.error("[ChatPanel] 获取关单标签失败:", g));
11422
11422
  }, [
11423
11423
  me,
11424
11424
  Dn,
@@ -11435,9 +11435,9 @@ function OS({
11435
11435
  const g = Object.fromEntries(
11436
11436
  Object.entries(S).filter(([, G]) => !G.task_id)
11437
11437
  );
11438
- return So(g);
11438
+ return wo(g);
11439
11439
  }, [S]), pr = Ne(
11440
- () => As(f, y) ?? null,
11440
+ () => qs(f, y) ?? null,
11441
11441
  [y, f]
11442
11442
  ), [hr, Vs] = N(!0), [oS, zs] = N(!1);
11443
11443
  de(() => {
@@ -11526,7 +11526,7 @@ function OS({
11526
11526
  if (l) {
11527
11527
  if (bn) {
11528
11528
  try {
11529
- const g = await ki(l.id);
11529
+ const g = await vi(l.id);
11530
11530
  O.setState((G) => {
11531
11531
  var Le;
11532
11532
  return {
@@ -11558,7 +11558,7 @@ function OS({
11558
11558
  }
11559
11559
  ut(!0);
11560
11560
  try {
11561
- const g = await bi(l.id, {
11561
+ const g = await Ti(l.id, {
11562
11562
  feedback: Ze.trim(),
11563
11563
  tags: We
11564
11564
  });
@@ -11597,7 +11597,7 @@ function OS({
11597
11597
  if (!(!l || vn)) {
11598
11598
  Ks(!0);
11599
11599
  try {
11600
- const g = await pi(l.id);
11600
+ const g = await _i(l.id);
11601
11601
  g.success ? z("图片解析已触发", "success") : z(g.message || "图片解析失败", "error"), await On(l.id);
11602
11602
  } catch (g) {
11603
11603
  z((g == null ? void 0 : g.message) || "图片解析失败", "error");
@@ -11609,7 +11609,7 @@ function OS({
11609
11609
  if (!(!l || Yt)) {
11610
11610
  Qs(!0);
11611
11611
  try {
11612
- const g = await vi(l.id);
11612
+ const g = await Ni(l.id);
11613
11613
  z(g || "初始化补偿已触发", "success");
11614
11614
  } catch (g) {
11615
11615
  z((g == null ? void 0 : g.message) || "初始化补偿失败", "error");
@@ -11638,7 +11638,7 @@ function OS({
11638
11638
  if (l) {
11639
11639
  _t(!0);
11640
11640
  try {
11641
- const g = await Ti(l.id);
11641
+ const g = await Ci(l.id);
11642
11642
  ze(g);
11643
11643
  } catch (g) {
11644
11644
  console.error("[ChatPanel] 获取 Fork 列表失败:", g), ze([]);
@@ -11660,7 +11660,7 @@ function OS({
11660
11660
  }
11661
11661
  Vt(!0);
11662
11662
  try {
11663
- const Le = O.getState().token, se = await Ni(g, Le);
11663
+ const Le = O.getState().token, se = await Si(g, Le);
11664
11664
  Hn(se);
11665
11665
  } catch (Le) {
11666
11666
  console.error("[ChatPanel] 获取父单失败:", Le), z("获取父单失败", "error");
@@ -12652,7 +12652,7 @@ function OS({
12652
12652
  onSubmit: async (g) => {
12653
12653
  if (mt(!1), !!l)
12654
12654
  try {
12655
- const G = await hi(String(l.id), "", g);
12655
+ const G = await gi(String(l.id), "", g);
12656
12656
  z(`克隆完成:${(G == null ? void 0 : G.path) ?? "代码分析"}`, "success"), await O.getState().loadFileTree(void 0, !0);
12657
12657
  } catch {
12658
12658
  }
@@ -12783,7 +12783,7 @@ function HS(t) {
12783
12783
  if (I.type === "human_assist") {
12784
12784
  const A = we(v.agentTaskId), W = we(v.humanTaskId), q = O.getState(), X = v.humanAssistCard ?? v.human_assist_card;
12785
12785
  if (X) {
12786
- const ce = vo(X), _ = (ln(ce == null ? void 0 : ce.agentTaskId) ? ce.agentTaskId : null) ?? (ln(A) ? A : null);
12786
+ const ce = To(X), _ = (ln(ce == null ? void 0 : ce.agentTaskId) ? ce.agentTaskId : null) ?? (ln(A) ? A : null);
12787
12787
  ce != null && ce.humanTaskId && _ != null && q.setHumanAssistCard(_, ce);
12788
12788
  }
12789
12789
  ln(A) && q.bumpHumanAssistRevision(A), ln(W) && q.bumpHumanAssistRevision(W);
@@ -12956,7 +12956,7 @@ function HS(t) {
12956
12956
  }
12957
12957
  if (I.type === "mode_changed") {
12958
12958
  const A = O.getState();
12959
- if (Gi(A.currentProject, A.currentUser))
12959
+ if (Ui(A.currentProject, A.currentUser))
12960
12960
  return;
12961
12961
  const W = v.mode;
12962
12962
  O.setState({ agentMode: W }), localStorage.setItem("ft_agent_mode", W);
@@ -24,6 +24,7 @@ async function l() {
24
24
  const a = new AbortController(), e = setTimeout(() => a.abort(), 1500), o = await fetch("/kapi/z-ctc/api/ctc/authn/whoami", {
25
25
  method: "GET",
26
26
  credentials: "include",
27
+ headers: { Accept: "application/json" },
27
28
  signal: a.signal
28
29
  });
29
30
  if (clearTimeout(e), o.status === 401)