@glodon-aiot/agent-cli-ui 3.9.0-beta.10 → 3.11.0

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 (109) hide show
  1. package/dist/es/Dialog/AgentChat/HistoryItem/FileItem/index.mjs +12 -12
  2. package/dist/es/Dialog/AgentChat/HistoryItem/SessionRefer/index.mjs +11 -11
  3. package/dist/es/Dialog/AgentChat/HistoryItem/SessionRelated/index.mjs +2 -2
  4. package/dist/es/Dialog/AgentChat/HistoryItem/index.mjs +118 -133
  5. package/dist/es/Dialog/AgentChat/Tools/UploadKnowledgeFiles/index.mjs +1 -1
  6. package/dist/es/Dialog/AgentChat/index.mjs +573 -604
  7. package/dist/es/Dialog/SessionList/index.mjs +218 -271
  8. package/dist/es/ReactTextGenerationUI/components/TextSiders/index.mjs +53 -53
  9. package/dist/es/components/FilePreview/index.mjs +6 -6
  10. package/dist/es/components/Iconfont/index.mjs +3 -3
  11. package/dist/es/constant.mjs +4 -4
  12. package/dist/es/{packages → node_modules/@glodon-aiot}/react-components/dist/es/components/Markdown/Code/index.mjs +1 -1
  13. package/dist/es/{packages → node_modules/@glodon-aiot}/react-components/dist/es/components/Markdown/Image/index.mjs +3 -3
  14. package/dist/es/{packages → node_modules/@glodon-aiot}/react-components/dist/es/components/Markdown/index.mjs +25 -24
  15. package/dist/es/{packages → node_modules/@glodon-aiot}/react-components/dist/es/index.mjs +1 -1
  16. package/dist/es/node_modules/hast-util-from-parse5/lib/index.mjs +162 -0
  17. package/dist/es/node_modules/hast-util-from-parse5/node_modules/property-information/index.mjs +12 -0
  18. package/dist/es/node_modules/hast-util-from-parse5/node_modules/property-information/lib/aria.mjs +61 -0
  19. package/dist/es/node_modules/hast-util-from-parse5/node_modules/property-information/lib/find.mjs +33 -0
  20. package/dist/es/node_modules/hast-util-from-parse5/node_modules/property-information/lib/html.mjs +368 -0
  21. package/dist/es/node_modules/hast-util-from-parse5/node_modules/property-information/lib/normalize.mjs +6 -0
  22. package/dist/es/node_modules/hast-util-from-parse5/node_modules/property-information/lib/svg.mjs +566 -0
  23. package/dist/es/node_modules/hast-util-from-parse5/node_modules/property-information/lib/util/case-insensitive-transform.mjs +7 -0
  24. package/dist/es/node_modules/hast-util-from-parse5/node_modules/property-information/lib/util/case-sensitive-transform.mjs +6 -0
  25. package/dist/es/node_modules/hast-util-from-parse5/node_modules/property-information/lib/util/create.mjs +14 -0
  26. package/dist/es/node_modules/hast-util-from-parse5/node_modules/property-information/lib/util/defined-info.mjs +36 -0
  27. package/dist/es/node_modules/hast-util-from-parse5/node_modules/property-information/lib/util/info.mjs +28 -0
  28. package/dist/es/node_modules/hast-util-from-parse5/node_modules/property-information/lib/util/merge.mjs +10 -0
  29. package/dist/es/node_modules/hast-util-from-parse5/node_modules/property-information/lib/util/schema.mjs +21 -0
  30. package/dist/es/node_modules/hast-util-from-parse5/node_modules/property-information/lib/util/types.mjs +15 -0
  31. package/dist/es/node_modules/hast-util-from-parse5/node_modules/property-information/lib/xlink.mjs +19 -0
  32. package/dist/es/node_modules/hast-util-from-parse5/node_modules/property-information/lib/xml.mjs +15 -0
  33. package/dist/es/node_modules/hast-util-from-parse5/node_modules/property-information/lib/xmlns.mjs +16 -0
  34. package/dist/es/node_modules/hast-util-from-parse5/node_modules/vfile-location/lib/index.mjs +47 -0
  35. package/dist/es/node_modules/hast-util-from-parse5/node_modules/web-namespaces/index.mjs +11 -0
  36. package/dist/es/node_modules/rehype-raw/lib/index.mjs +26 -0
  37. package/dist/es/node_modules/rehype-raw/node_modules/entities/dist/esm/decode-codepoint.mjs +38 -0
  38. package/dist/es/node_modules/rehype-raw/node_modules/entities/dist/esm/decode.mjs +251 -0
  39. package/dist/es/node_modules/rehype-raw/node_modules/entities/dist/esm/generated/decode-data-html.mjs +7 -0
  40. package/dist/es/node_modules/rehype-raw/node_modules/hast-util-raw/lib/index.mjs +249 -0
  41. package/dist/es/node_modules/rehype-raw/node_modules/hast-util-to-parse5/lib/index.mjs +125 -0
  42. package/dist/es/node_modules/rehype-raw/node_modules/html-void-elements/index.mjs +4 -0
  43. package/dist/es/node_modules/rehype-raw/node_modules/parse5/dist/common/doctype.mjs +34 -0
  44. package/dist/es/node_modules/rehype-raw/node_modules/parse5/dist/common/error-codes.mjs +7 -0
  45. package/dist/es/node_modules/rehype-raw/node_modules/parse5/dist/common/foreign-content.mjs +103 -0
  46. package/dist/es/node_modules/rehype-raw/node_modules/parse5/dist/common/html.mjs +44 -0
  47. package/dist/es/node_modules/rehype-raw/node_modules/parse5/dist/common/token.mjs +14 -0
  48. package/dist/es/node_modules/rehype-raw/node_modules/parse5/dist/common/unicode.mjs +38 -0
  49. package/dist/es/node_modules/rehype-raw/node_modules/parse5/dist/parser/formatting-element-list.mjs +91 -0
  50. package/dist/es/node_modules/rehype-raw/node_modules/parse5/dist/parser/index.mjs +2308 -0
  51. package/dist/es/node_modules/rehype-raw/node_modules/parse5/dist/parser/open-element-stack.mjs +220 -0
  52. package/dist/es/node_modules/rehype-raw/node_modules/parse5/dist/serializer/index.mjs +2 -0
  53. package/dist/es/node_modules/rehype-raw/node_modules/parse5/dist/tokenizer/index.mjs +1948 -0
  54. package/dist/es/node_modules/rehype-raw/node_modules/parse5/dist/tokenizer/preprocessor.mjs +92 -0
  55. package/dist/es/node_modules/rehype-raw/node_modules/parse5/dist/tree-adapters/default.mjs +173 -0
  56. package/dist/es/node_modules/rehype-raw/node_modules/property-information/index.mjs +12 -0
  57. package/dist/es/node_modules/rehype-raw/node_modules/property-information/lib/aria.mjs +61 -0
  58. package/dist/es/node_modules/rehype-raw/node_modules/property-information/lib/find.mjs +33 -0
  59. package/dist/es/node_modules/rehype-raw/node_modules/property-information/lib/html.mjs +368 -0
  60. package/dist/es/node_modules/rehype-raw/node_modules/property-information/lib/normalize.mjs +6 -0
  61. package/dist/es/node_modules/rehype-raw/node_modules/property-information/lib/svg.mjs +566 -0
  62. package/dist/es/node_modules/rehype-raw/node_modules/property-information/lib/util/case-insensitive-transform.mjs +7 -0
  63. package/dist/es/node_modules/rehype-raw/node_modules/property-information/lib/util/case-sensitive-transform.mjs +6 -0
  64. package/dist/es/node_modules/rehype-raw/node_modules/property-information/lib/util/create.mjs +17 -0
  65. package/dist/es/node_modules/rehype-raw/node_modules/property-information/lib/util/defined-info.mjs +27 -0
  66. package/dist/es/node_modules/rehype-raw/node_modules/property-information/lib/util/info.mjs +23 -0
  67. package/dist/es/node_modules/rehype-raw/node_modules/property-information/lib/util/merge.mjs +11 -0
  68. package/dist/es/node_modules/rehype-raw/node_modules/property-information/lib/util/schema.mjs +17 -0
  69. package/dist/es/node_modules/rehype-raw/node_modules/property-information/lib/util/types.mjs +15 -0
  70. package/dist/es/node_modules/rehype-raw/node_modules/property-information/lib/xlink.mjs +19 -0
  71. package/dist/es/node_modules/rehype-raw/node_modules/property-information/lib/xml.mjs +15 -0
  72. package/dist/es/node_modules/rehype-raw/node_modules/property-information/lib/xmlns.mjs +16 -0
  73. package/dist/es/node_modules/rehype-raw/node_modules/unist-util-visit/lib/index.mjs +16 -0
  74. package/dist/es/node_modules/rehype-raw/node_modules/web-namespaces/index.mjs +11 -0
  75. package/dist/es/node_modules/zwitch/index.mjs +18 -0
  76. package/dist/es/packages/agent-cli-ui/package.json.mjs +3 -3
  77. package/dist/es/src/style11.css +1 -1
  78. package/dist/es/src/style12.css +1 -1
  79. package/dist/es/src/style13.css +1 -1
  80. package/dist/es/src/style14.css +1 -1
  81. package/dist/es/src/style15.css +1 -1
  82. package/dist/es/src/style16.css +1 -1
  83. package/dist/es/src/style17.css +1 -1
  84. package/dist/es/src/style18.css +1 -1
  85. package/dist/es/src/style19.css +1 -1
  86. package/dist/es/src/style20.css +1 -1
  87. package/dist/es/src/style21.css +1 -1
  88. package/dist/es/src/style22.css +1 -1
  89. package/dist/es/src/style23.css +1 -1
  90. package/dist/es/src/style26.css +1 -1
  91. package/dist/es/src/style27.css +1 -1
  92. package/dist/es/src/style28.css +1 -1
  93. package/dist/es/src/style30.css +1 -1
  94. package/dist/es/src/style31.css +1 -1
  95. package/dist/es/src/style32.css +1 -1
  96. package/dist/es/src/style5.css +1 -1
  97. package/dist/es/src/style6.css +1 -1
  98. package/dist/es/src/style8.css +1 -1
  99. package/dist/es/src/style9.css +1 -1
  100. package/dist/lib/index.css +1 -1
  101. package/dist/lib/index.js +68 -69
  102. package/dist/src/constant.d.ts +2 -2
  103. package/package.json +3 -3
  104. /package/dist/es/{packages → node_modules/@glodon-aiot}/react-components/dist/es/Iconfont/index.mjs +0 -0
  105. /package/dist/es/{packages → node_modules/@glodon-aiot}/react-components/dist/es/components/Copy/index.mjs +0 -0
  106. /package/dist/es/{packages → node_modules/@glodon-aiot}/react-components/dist/es/components/Markdown/ATag/index.mjs +0 -0
  107. /package/dist/es/{packages → node_modules/@glodon-aiot}/react-components/dist/es/components/Markdown/Video/index.mjs +0 -0
  108. /package/dist/es/{packages → node_modules/@glodon-aiot}/react-components/dist/es/utils/clipboard.mjs +0 -0
  109. /package/dist/es/{packages → node_modules/@glodon-aiot}/react-components/dist/es/utils/markdown/index.mjs +0 -0
@@ -1,4 +1,4 @@
1
- import { jsxs as g, jsx as o } from "react/jsx-runtime";
1
+ import { jsxs as g, jsx as r } from "react/jsx-runtime";
2
2
  import { useContext as b, useState as x, useEffect as v } from "react";
3
3
  /* empty css */import { Typography as w, message as m } from "antd";
4
4
  import { getFileExtension as C, formatFileSize as y, isValidImageUrlWithAnyExtension as I } from "../../../../utils/index.mjs";
@@ -12,7 +12,7 @@ const K = (u) => {
12
12
  docViewerUrl: f
13
13
  } = u, {
14
14
  service: l,
15
- popupContainer: r
15
+ popupContainer: o
16
16
  } = b(E), [e, h] = x(), [t, p] = x("");
17
17
  v(() => {
18
18
  var n;
@@ -33,7 +33,7 @@ const K = (u) => {
33
33
  const F = (n) => {
34
34
  if (!(n != null && n.url)) {
35
35
  m.config({
36
- getContainer: () => (r == null ? void 0 : r.current) || document.body,
36
+ getContainer: () => (o == null ? void 0 : o.current) || document.body,
37
37
  prefixCls: "gbot-message"
38
38
  }), m.error("链接不存在"), m.config({
39
39
  getContainer: void 0,
@@ -43,7 +43,7 @@ const K = (u) => {
43
43
  }
44
44
  if (!I(n.url)) {
45
45
  m.config({
46
- getContainer: () => (r == null ? void 0 : r.current) || document.body,
46
+ getContainer: () => (o == null ? void 0 : o.current) || document.body,
47
47
  prefixCls: "gbot-message"
48
48
  }), m.error("链接格式不正确"), m.config({
49
49
  getContainer: void 0,
@@ -51,22 +51,22 @@ const K = (u) => {
51
51
  });
52
52
  return;
53
53
  }
54
- window.open(`${f}#/doc?url=${encodeURIComponent(n == null ? void 0 : n.url)}`);
54
+ window.open(`${f}?url=${encodeURIComponent(n == null ? void 0 : n.url)}`);
55
55
  };
56
56
  return /* @__PURE__ */ g("div", {
57
57
  className: "file-item",
58
58
  onClick: () => F(e),
59
- children: [/* @__PURE__ */ o("div", {
59
+ children: [/* @__PURE__ */ r("div", {
60
60
  className: "item-left",
61
- children: /* @__PURE__ */ o("img", {
61
+ children: /* @__PURE__ */ r("img", {
62
62
  className: "file-icon",
63
63
  src: U[t]
64
64
  })
65
65
  }), /* @__PURE__ */ g("div", {
66
66
  className: "item-main",
67
- children: [/* @__PURE__ */ o("div", {
67
+ children: [/* @__PURE__ */ r("div", {
68
68
  className: "file-name",
69
- children: /* @__PURE__ */ o(w.Paragraph, {
69
+ children: /* @__PURE__ */ r(w.Paragraph, {
70
70
  style: {
71
71
  margin: 0,
72
72
  width: "100%"
@@ -79,11 +79,11 @@ const K = (u) => {
79
79
  })
80
80
  }), /* @__PURE__ */ g("div", {
81
81
  className: "file-desc",
82
- children: [/* @__PURE__ */ o("span", {
82
+ children: [/* @__PURE__ */ r("span", {
83
83
  children: t == null ? void 0 : t.toUpperCase()
84
- }), /* @__PURE__ */ o("span", {
84
+ }), /* @__PURE__ */ r("span", {
85
85
  children: ","
86
- }), /* @__PURE__ */ o("span", {
86
+ }), /* @__PURE__ */ r("span", {
87
87
  children: y((e == null ? void 0 : e.size) || 0)
88
88
  })]
89
89
  })]
@@ -1,24 +1,24 @@
1
- var F = Object.defineProperty, R = Object.defineProperties;
2
- var T = Object.getOwnPropertyDescriptors;
1
+ var R = Object.defineProperty, T = Object.defineProperties;
2
+ var U = Object.getOwnPropertyDescriptors;
3
3
  var f = Object.getOwnPropertySymbols;
4
- var U = Object.prototype.hasOwnProperty, b = Object.prototype.propertyIsEnumerable;
5
- var h = (a, e, n) => e in a ? F(a, e, { enumerable: !0, configurable: !0, writable: !0, value: n }) : a[e] = n, w = (a, e) => {
4
+ var $ = Object.prototype.hasOwnProperty, b = Object.prototype.propertyIsEnumerable;
5
+ var h = (a, e, n) => e in a ? R(a, e, { enumerable: !0, configurable: !0, writable: !0, value: n }) : a[e] = n, w = (a, e) => {
6
6
  for (var n in e || (e = {}))
7
- U.call(e, n) && h(a, n, e[n]);
7
+ $.call(e, n) && h(a, n, e[n]);
8
8
  if (f)
9
9
  for (var n of f(e))
10
10
  b.call(e, n) && h(a, n, e[n]);
11
11
  return a;
12
- }, k = (a, e) => R(a, T(e));
12
+ }, k = (a, e) => T(a, U(e));
13
13
  import { jsxs as t, jsx as s } from "react/jsx-runtime";
14
14
  import { useContext as j } from "react";
15
15
  import { Space as I, Collapse as C } from "antd";
16
16
  import z from "../../../../components/Iconfont/index.mjs";
17
17
  /* empty css */import { ISourceType as g } from "@glodon-aiot/apis";
18
- import "../../../../packages/react-components/dist/es/index.mjs";
18
+ import "../../../../node_modules/@glodon-aiot/react-components/dist/es/index.mjs";
19
19
  import A from "./ReferItem/index.mjs";
20
20
  import K from "../../../../context.mjs";
21
- import { Markdown as L } from "../../../../packages/react-components/dist/es/components/Markdown/index.mjs";
21
+ import { Markdown as L } from "../../../../node_modules/@glodon-aiot/react-components/dist/es/components/Markdown/index.mjs";
22
22
  const {
23
23
  Panel: P
24
24
  } = C, X = (a) => {
@@ -36,7 +36,7 @@ const {
36
36
  window.open(o.webLink);
37
37
  return;
38
38
  }
39
- o.sourceType === g.SourceFile && window.open(`${n}#/doc?url=${encodeURIComponent(o.sourceFileUrl)}&page=${i || 0}`);
39
+ o.sourceType === g.SourceFile && window.open(`${n}?page=${i || 0}&url=${encodeURIComponent(o.sourceFileUrl)}`);
40
40
  }
41
41
  };
42
42
  return /* @__PURE__ */ t("div", {
@@ -69,8 +69,8 @@ const {
69
69
  children: [i + 1, "."]
70
70
  }), d && /* @__PURE__ */ s(A, {
71
71
  data: o,
72
- loadPage: (x, S, D) => d.getKnowledgeIdFileIdData(x, S, D).then(($) => {
73
- const l = ($ || []).find((y) => y.key === "pages_from");
72
+ loadPage: (x, S, D) => d.getKnowledgeIdFileIdData(x, S, D).then((y) => {
73
+ const l = (y || []).find((F) => F.key === "pages_from");
74
74
  return (l == null ? void 0 : l.value) || 0;
75
75
  }),
76
76
  onClick: v
@@ -2,8 +2,8 @@ import { jsxs as o, jsx as e } from "react/jsx-runtime";
2
2
  import { Space as r } from "antd";
3
3
  /* empty css */import { removeNewlines as m } from "../../../../utils/index.mjs";
4
4
  import c from "../../../../components/Iconfont/index.mjs";
5
- import "../../../../packages/react-components/dist/es/index.mjs";
6
- import { Markdown as l } from "../../../../packages/react-components/dist/es/components/Markdown/index.mjs";
5
+ import "../../../../node_modules/@glodon-aiot/react-components/dist/es/index.mjs";
6
+ import { Markdown as l } from "../../../../node_modules/@glodon-aiot/react-components/dist/es/components/Markdown/index.mjs";
7
7
  const z = (n) => {
8
8
  const {
9
9
  history: d,
@@ -1,36 +1,36 @@
1
- var ye = Object.defineProperty, ve = Object.defineProperties;
2
- var Le = Object.getOwnPropertyDescriptors;
3
- var Y = Object.getOwnPropertySymbols;
4
- var Re = Object.prototype.hasOwnProperty, be = Object.prototype.propertyIsEnumerable;
5
- var Z = (s, i, l) => i in s ? ye(s, i, { enumerable: !0, configurable: !0, writable: !0, value: l }) : s[i] = l, L = (s, i) => {
1
+ var he = Object.defineProperty, ge = Object.defineProperties;
2
+ var Ne = Object.getOwnPropertyDescriptors;
3
+ var X = Object.getOwnPropertySymbols;
4
+ var fe = Object.prototype.hasOwnProperty, Ce = Object.prototype.propertyIsEnumerable;
5
+ var Y = (s, i, l) => i in s ? he(s, i, { enumerable: !0, configurable: !0, writable: !0, value: l }) : s[i] = l, y = (s, i) => {
6
6
  for (var l in i || (i = {}))
7
- Re.call(i, l) && Z(s, l, i[l]);
8
- if (Y)
9
- for (var l of Y(i))
10
- be.call(i, l) && Z(s, l, i[l]);
7
+ fe.call(i, l) && Y(s, l, i[l]);
8
+ if (X)
9
+ for (var l of X(i))
10
+ Ce.call(i, l) && Y(s, l, i[l]);
11
11
  return s;
12
- }, R = (s, i) => ve(s, Le(i));
12
+ }, R = (s, i) => ge(s, Ne(i));
13
13
  import { jsxs as o, jsx as e } from "react/jsx-runtime";
14
- import { memo as N, useContext as Se, useState as Ee } from "react";
15
- import p from "./InputProgress/index.mjs";
16
- import ke from "./SessionRefer/index.mjs";
17
- import xe from "./SessionAction/index.mjs";
18
- import { IHistoryRole as ee, ApplicationTypes as ne, IThinkingStatus as te } from "@glodon-aiot/apis";
19
- import Ae from "./FileItem/index.mjs";
20
- import { Row as ie, Col as le, Popover as Te, Space as se, Button as re, Collapse as ae, Divider as Oe, message as b } from "antd";
21
- import Fe from "./SearchReference/index.mjs";
22
- /* empty css */import "../../../packages/react-components/dist/es/index.mjs";
23
- import _e from "classnames";
24
- import m from "../../../components/Iconfont/index.mjs";
25
- import { CheckOutlined as oe, CloseOutlined as de, LoadingOutlined as Ie } from "@ant-design/icons";
26
- import u from "../../../components/JsonDisplay/index.mjs";
27
- import Ue from "../../../context.mjs";
28
- import je from "./SessionRelated/index.mjs";
29
- import ze from "copy-to-clipboard";
30
- import { escapeSlash as we } from "../../../utils/index.mjs";
31
- import Be from "../../../assets/think.svg.mjs";
32
- import { Markdown as Me } from "../../../packages/react-components/dist/es/components/Markdown/index.mjs";
33
- const Je = (s) => {
14
+ import { memo as g, useContext as Le, useState as ve } from "react";
15
+ import c from "./InputProgress/index.mjs";
16
+ import ye from "./SessionRefer/index.mjs";
17
+ import Re from "./SessionAction/index.mjs";
18
+ import { IHistoryRole as Z, IThinkingStatus as ee } from "@glodon-aiot/apis";
19
+ import be from "./FileItem/index.mjs";
20
+ import { Popover as Se, Space as ne, Button as te, Row as Ee, Col as ke, Collapse as ie, Divider as xe, message as b } from "antd";
21
+ import Te from "./SearchReference/index.mjs";
22
+ /* empty css */import "../../../node_modules/@glodon-aiot/react-components/dist/es/index.mjs";
23
+ import Ae from "classnames";
24
+ import p from "../../../components/Iconfont/index.mjs";
25
+ import { CheckOutlined as le, CloseOutlined as se, LoadingOutlined as Oe } from "@ant-design/icons";
26
+ import m from "../../../components/JsonDisplay/index.mjs";
27
+ import Fe from "../../../context.mjs";
28
+ import _e from "./SessionRelated/index.mjs";
29
+ import Ie from "copy-to-clipboard";
30
+ import { escapeSlash as Ue } from "../../../utils/index.mjs";
31
+ import ze from "../../../assets/think.svg.mjs";
32
+ import { Markdown as je } from "../../../node_modules/@glodon-aiot/react-components/dist/es/components/Markdown/index.mjs";
33
+ const Be = (s) => {
34
34
  if (!s)
35
35
  return s;
36
36
  try {
@@ -38,7 +38,7 @@ const Je = (s) => {
38
38
  } catch (i) {
39
39
  return s;
40
40
  }
41
- }, Pe = N(Fe), ce = N(ke), h = N(Me), pe = N(Ae), g = (s) => {
41
+ }, we = g(Te), re = g(ye), u = g(je), Me = g(be), h = (s) => {
42
42
  if (!s)
43
43
  return !1;
44
44
  try {
@@ -47,41 +47,41 @@ const Je = (s) => {
47
47
  } catch (i) {
48
48
  return !0;
49
49
  }
50
- }, me = (s) => {
50
+ }, ae = (s) => {
51
51
  var n;
52
52
  const i = JSON.parse(JSON.stringify(s)) || [], l = (n = i == null ? void 0 : i.pop()) == null ? void 0 : n.pop();
53
53
  return l ? (l == null ? void 0 : l.type) === "BEFORE_CALL" || (l == null ? void 0 : l.type) === "FUNCTION_CALL" : !1;
54
- }, mn = (s) => {
55
- var x, A, T, O, F, _, I, U, j, z, w, B;
54
+ }, cn = (s) => {
55
+ var x, T, A, O, F, _, I, U, z, j, B;
56
56
  const {
57
57
  application: i,
58
58
  currentSession: l,
59
59
  history: n,
60
- isLastHistory: f,
61
- onRelatedClick: ue,
62
- onAgainClick: he,
63
- isLoading: Qe,
64
- docViewerUrl: d,
60
+ isLastHistory: N,
61
+ onRelatedClick: oe,
62
+ onAgainClick: de,
63
+ isLoading: Je,
64
+ docViewerUrl: f,
65
65
  onEditClick: C,
66
- actions: ge = !0,
67
- markdown: c
66
+ actions: ce = !0,
67
+ markdown: d
68
68
  } = s, {
69
69
  debug: S,
70
70
  transform: r,
71
- popupContainer: y
72
- } = Se(Ue), E = n.role === ee.User, k = n.role === ee.Robot, {
73
- Panel: Ne
74
- } = ae, [v, fe] = Ee(!0), Ce = () => {
71
+ popupContainer: L
72
+ } = Le(Fe), E = n.role === Z.User, k = n.role === Z.Robot, {
73
+ Panel: pe
74
+ } = ie, [v, me] = ve(!0), ue = () => {
75
75
  b.config({
76
- getContainer: () => (y == null ? void 0 : y.current) || document.body,
76
+ getContainer: () => (L == null ? void 0 : L.current) || document.body,
77
77
  prefixCls: "gbot-message"
78
- }), ze(n.content), b.success("复制成功"), b.config({
78
+ }), Ie(n.content), b.success("复制成功"), b.config({
79
79
  getContainer: void 0,
80
80
  prefixCls: "gbot-message"
81
81
  });
82
82
  };
83
83
  return /* @__PURE__ */ o("div", {
84
- className: _e({
84
+ className: Ae({
85
85
  "history-item": !0,
86
86
  "history-item__user": E,
87
87
  "history-item__bot": k
@@ -90,55 +90,40 @@ const Je = (s) => {
90
90
  className: "history-item-user",
91
91
  children: [i.type === 0 && ((x = n == null ? void 0 : n.imageContent) == null ? void 0 : x.length) && /* @__PURE__ */ e("div", {
92
92
  className: "item-user-images",
93
- children: /* @__PURE__ */ e(h, {
94
- children: n.imageContent.map((t, M) => `![](${t})`).join(`
93
+ children: /* @__PURE__ */ e(u, {
94
+ children: n.imageContent.map((t, w) => `![](${t})`).join(`
95
95
 
96
96
  `)
97
97
  })
98
- }), i.type === ne.Dialog && /* @__PURE__ */ e("div", {
99
- className: "item-user-file-dialog",
100
- children: /* @__PURE__ */ e(ie, {
101
- gutter: [12, 12],
102
- justify: "end",
103
- wrap: !0,
104
- children: (A = n.files) == null ? void 0 : A.map((t) => /* @__PURE__ */ e(le, {
105
- className: "user-file-col",
106
- children: /* @__PURE__ */ e(pe, {
107
- docViewerUrl: d,
108
- currentSession: l,
109
- file: t
110
- })
111
- }, t.id))
112
- })
113
98
  }), /* @__PURE__ */ e("div", {
114
99
  className: "item-user-panel",
115
- children: /* @__PURE__ */ e(Te, {
100
+ children: /* @__PURE__ */ e(Se, {
116
101
  placement: "topLeft",
117
102
  overlayStyle: {
118
103
  padding: 4
119
104
  },
120
105
  overlayClassName: "session-item-overlay-popover",
121
106
  getPopupContainer: (t) => t.parentNode,
122
- content: r != null && r.userEdit || r != null && r.userCopy ? /* @__PURE__ */ o(se, {
107
+ content: r != null && r.userEdit || r != null && r.userCopy ? /* @__PURE__ */ o(ne, {
123
108
  className: "item-user-popover",
124
109
  size: 4,
125
110
  children: [(r == null ? void 0 : r.userEdit) && /* @__PURE__ */ e("div", {
126
111
  className: "user-pannel-item",
127
112
  onClick: () => C == null ? void 0 : C(n.content),
128
- children: /* @__PURE__ */ e(re, {
113
+ children: /* @__PURE__ */ e(te, {
129
114
  type: "link",
130
115
  size: "small",
131
- icon: /* @__PURE__ */ e(m, {
116
+ icon: /* @__PURE__ */ e(p, {
132
117
  type: "icon-bianji2"
133
118
  })
134
119
  })
135
120
  }), (r == null ? void 0 : r.userCopy) && /* @__PURE__ */ e("div", {
136
121
  className: "user-pannel-item",
137
- onClick: Ce,
138
- children: /* @__PURE__ */ e(re, {
122
+ onClick: ue,
123
+ children: /* @__PURE__ */ e(te, {
139
124
  type: "link",
140
125
  size: "small",
141
- icon: /* @__PURE__ */ e(m, {
126
+ icon: /* @__PURE__ */ e(p, {
142
127
  type: "icon-fuzhi",
143
128
  style: {
144
129
  fontSize: "16px"
@@ -151,23 +136,23 @@ const Je = (s) => {
151
136
  className: "user-panel-main",
152
137
  children: /* @__PURE__ */ e("span", {
153
138
  className: "item-user-content",
154
- children: /* @__PURE__ */ e(h, {
139
+ children: /* @__PURE__ */ e(u, {
155
140
  showLatex: !1,
156
- children: we(n.content)
141
+ children: Ue(n.content)
157
142
  })
158
143
  })
159
144
  })
160
145
  })
161
- }), i.type === ne.Agent && /* @__PURE__ */ e("div", {
146
+ }), /* @__PURE__ */ e("div", {
162
147
  className: "item-user-file",
163
- children: /* @__PURE__ */ e(ie, {
148
+ children: /* @__PURE__ */ e(Ee, {
164
149
  gutter: [12, 12],
165
150
  justify: "end",
166
151
  wrap: !0,
167
- children: (T = n.files) == null ? void 0 : T.map((t) => /* @__PURE__ */ e(le, {
152
+ children: (T = n.files) == null ? void 0 : T.map((t) => /* @__PURE__ */ e(ke, {
168
153
  className: "user-file-col",
169
- children: /* @__PURE__ */ e(pe, {
170
- docViewerUrl: d,
154
+ children: /* @__PURE__ */ e(Me, {
155
+ docViewerUrl: f,
171
156
  currentSession: l,
172
157
  file: t
173
158
  })
@@ -180,47 +165,47 @@ const Je = (s) => {
180
165
  className: "bot-content-wrapper",
181
166
  children: [i.type === 2 && /* @__PURE__ */ o("div", {
182
167
  className: "item-bot-plugin",
183
- children: [/* @__PURE__ */ e(ae, {
168
+ children: [/* @__PURE__ */ e(ie, {
184
169
  ghost: !0,
185
170
  expandIconPosition: "right",
186
- children: (O = n.actions) == null ? void 0 : O.map((t, M) => {
187
- var J, P, Q, q, D, H, $, V, W, G, K, X;
188
- return /* @__PURE__ */ o(Ne, {
171
+ children: (A = n.actions) == null ? void 0 : A.map((t, w) => {
172
+ var M, J, P, Q, q, H, D, V, W, $, G, K;
173
+ return /* @__PURE__ */ o(pe, {
189
174
  collapsible: S ? "header" : "icon",
190
175
  showArrow: S,
191
- header: /* @__PURE__ */ o(se, {
176
+ header: /* @__PURE__ */ o(ne, {
192
177
  size: 8,
193
178
  style: {
194
179
  width: "100%"
195
180
  },
196
181
  children: [/* @__PURE__ */ o("span", {
197
182
  className: "bot-plugin-status",
198
- children: [(t[t.length - 1].type === "RESULT" || t[t.length - 1].type === "AFTER_CALL") && g((J = t.find((a) => a.type === "RESULT")) == null ? void 0 : J.data.result) && /* @__PURE__ */ e("span", {
183
+ children: [(t[t.length - 1].type === "RESULT" || t[t.length - 1].type === "AFTER_CALL") && h((M = t.find((a) => a.type === "RESULT")) == null ? void 0 : M.data.result) && /* @__PURE__ */ e("span", {
199
184
  className: "plugin-status-success",
200
- children: /* @__PURE__ */ e(oe, {})
185
+ children: /* @__PURE__ */ e(le, {})
201
186
  }), t[t.length - 1].type === "ABORT" && /* @__PURE__ */ e("span", {
202
187
  className: "plugin-status-error",
203
- children: /* @__PURE__ */ e(de, {})
204
- }), (t[t.length - 1].type === "RESULT" || t[t.length - 1].type === "AFTER_CALL") && !g((P = t.find((a) => a.type === "RESULT")) == null ? void 0 : P.data.result) && /* @__PURE__ */ e("span", {
188
+ children: /* @__PURE__ */ e(se, {})
189
+ }), (t[t.length - 1].type === "RESULT" || t[t.length - 1].type === "AFTER_CALL") && !h((J = t.find((a) => a.type === "RESULT")) == null ? void 0 : J.data.result) && /* @__PURE__ */ e("span", {
205
190
  className: "plugin-status-error",
206
- children: /* @__PURE__ */ e(de, {})
191
+ children: /* @__PURE__ */ e(se, {})
207
192
  }), (t[t.length - 1].type === "BEFORE_CALL" || t[t.length - 1].type === "FUNCTION_CALL") && /* @__PURE__ */ e("span", {
208
193
  className: "plugin-status-loading",
209
- children: /* @__PURE__ */ e(Ie, {})
194
+ children: /* @__PURE__ */ e(Oe, {})
210
195
  })]
211
196
  }), /* @__PURE__ */ e("span", {
212
197
  className: "bot-plugin-title",
213
- children: ((Q = t[t.length - 1].data) == null ? void 0 : Q.pluginName) || ((q = t[t.length - 1].data) == null ? void 0 : q.pluginCode)
198
+ children: ((P = t[t.length - 1].data) == null ? void 0 : P.pluginName) || ((Q = t[t.length - 1].data) == null ? void 0 : Q.pluginCode)
214
199
  }), /* @__PURE__ */ e("span", {
215
200
  className: "bot-plugin-action",
216
- children: ((D = t[t.length - 1].data) == null ? void 0 : D.funcName) || ((H = t[t.length - 1].data) == null ? void 0 : H.funcCode)
201
+ children: ((q = t[t.length - 1].data) == null ? void 0 : q.funcName) || ((H = t[t.length - 1].data) == null ? void 0 : H.funcCode)
217
202
  }), (t[t.length - 1].type === "BEFORE_CALL" || t[t.length - 1].type === "FUNCTION_CALL") && /* @__PURE__ */ e("span", {
218
203
  className: "bot-plugin-result",
219
204
  children: "执行中"
220
- }), (t[t.length - 1].type === "RESULT" || t[t.length - 1].type === "AFTER_CALL") && g(($ = t.find((a) => a.type === "RESULT")) == null ? void 0 : $.data.result) && /* @__PURE__ */ e("span", {
205
+ }), (t[t.length - 1].type === "RESULT" || t[t.length - 1].type === "AFTER_CALL") && h((D = t.find((a) => a.type === "RESULT")) == null ? void 0 : D.data.result) && /* @__PURE__ */ e("span", {
221
206
  className: "bot-plugin-result",
222
207
  children: "执行成功"
223
- }), (t[t.length - 1].type === "RESULT" || t[t.length - 1].type === "AFTER_CALL") && !g((V = t.find((a) => a.type === "RESULT")) == null ? void 0 : V.data.result) && /* @__PURE__ */ e("span", {
208
+ }), (t[t.length - 1].type === "RESULT" || t[t.length - 1].type === "AFTER_CALL") && !h((V = t.find((a) => a.type === "RESULT")) == null ? void 0 : V.data.result) && /* @__PURE__ */ e("span", {
224
209
  className: "bot-plugin-result",
225
210
  children: "执行失败"
226
211
  }), t[t.length - 1].type === "ABORT" && /* @__PURE__ */ e("span", {
@@ -233,7 +218,7 @@ const Je = (s) => {
233
218
  children: "thought"
234
219
  }), /* @__PURE__ */ e("div", {
235
220
  className: "bot-plugin-json",
236
- children: /* @__PURE__ */ e(u, {
221
+ children: /* @__PURE__ */ e(m, {
237
222
  josn: (W = t.find((a) => a.type === "BEFORE_CALL")) == null ? void 0 : W.data.thought
238
223
  })
239
224
  }), /* @__PURE__ */ e("div", {
@@ -241,47 +226,47 @@ const Je = (s) => {
241
226
  children: "parameters"
242
227
  }), /* @__PURE__ */ e("div", {
243
228
  className: "bot-plugin-json",
244
- children: /* @__PURE__ */ e(u, {
245
- josn: (G = t.find((a) => a.type === "BEFORE_CALL")) == null ? void 0 : G.data.parameters
229
+ children: /* @__PURE__ */ e(m, {
230
+ josn: ($ = t.find((a) => a.type === "BEFORE_CALL")) == null ? void 0 : $.data.parameters
246
231
  })
247
232
  }), /* @__PURE__ */ e("div", {
248
233
  className: "bot-plugin-content",
249
234
  children: "requestBody"
250
235
  }), /* @__PURE__ */ e("div", {
251
236
  className: "bot-plugin-json",
252
- children: /* @__PURE__ */ e(u, {
253
- josn: (K = t.find((a) => a.type === "BEFORE_CALL")) == null ? void 0 : K.data.requestBody
237
+ children: /* @__PURE__ */ e(m, {
238
+ josn: (G = t.find((a) => a.type === "BEFORE_CALL")) == null ? void 0 : G.data.requestBody
254
239
  })
255
240
  }), /* @__PURE__ */ e("div", {
256
241
  className: "bot-plugin-content",
257
242
  children: "Response"
258
243
  }), /* @__PURE__ */ e("div", {
259
244
  className: "bot-plugin-json",
260
- children: /* @__PURE__ */ e(u, {
261
- josn: Je((X = t.find((a) => a.type === "RESULT")) == null ? void 0 : X.data.result)
245
+ children: /* @__PURE__ */ e(m, {
246
+ josn: Be((K = t.find((a) => a.type === "RESULT")) == null ? void 0 : K.data.result)
262
247
  })
263
248
  })]
264
- }, M);
249
+ }, w);
265
250
  })
266
251
  }), n.isLoading && /* @__PURE__ */ e("div", {
267
252
  className: "history-input-progress",
268
253
  style: {
269
254
  padding: "4px 0"
270
255
  },
271
- children: n.content || me(n.actions) ? null : /* @__PURE__ */ e(p, {
256
+ children: n.content || ae(n.actions) ? null : /* @__PURE__ */ e(c, {
272
257
  size: 4,
273
258
  text: "思考中"
274
259
  })
275
260
  })]
276
- }), !!((F = n.searchReference) != null && F.length) && /* @__PURE__ */ e("div", {
261
+ }), !!((O = n.searchReference) != null && O.length) && /* @__PURE__ */ e("div", {
277
262
  className: "item-bot-net",
278
- children: /* @__PURE__ */ e(Pe, {
263
+ children: /* @__PURE__ */ e(we, {
279
264
  history: n
280
265
  })
281
- }), (_ = n == null ? void 0 : n.reference) != null && _.length && ((I = r == null ? void 0 : r.reference) != null && I.referenceFirst) ? /* @__PURE__ */ e(ce, {
266
+ }), (F = n == null ? void 0 : n.reference) != null && F.length && ((_ = r == null ? void 0 : r.reference) != null && _.referenceFirst) ? /* @__PURE__ */ e(re, {
282
267
  history: n,
283
- docViewerUrl: d,
284
- markdown: c
268
+ docViewerUrl: f,
269
+ markdown: d
285
270
  }) : null, /* @__PURE__ */ o("div", {
286
271
  className: "item-bot-content",
287
272
  children: [(n == null ? void 0 : n.reasoningContent) && /* @__PURE__ */ o("div", {
@@ -289,10 +274,10 @@ const Je = (s) => {
289
274
  children: [(n == null ? void 0 : n.reasoningContent) && /* @__PURE__ */ o("div", {
290
275
  className: "think-top",
291
276
  onClick: () => {
292
- fe(!v);
277
+ me(!v);
293
278
  },
294
279
  children: [/* @__PURE__ */ e("img", {
295
- src: Be,
280
+ src: ze,
296
281
  alt: ""
297
282
  }), (n == null ? void 0 : n.reasoningContent) && !(n != null && n.content) && /* @__PURE__ */ e("span", {
298
283
  children: "我正在推理思考…"
@@ -300,47 +285,47 @@ const Je = (s) => {
300
285
  children: ["已完成推理(用时 ", (n == null ? void 0 : n.thinkingSecs) || 0, " 秒)"]
301
286
  }), /* @__PURE__ */ e("span", {
302
287
  className: "think-action",
303
- children: v ? /* @__PURE__ */ e(m, {
288
+ children: v ? /* @__PURE__ */ e(p, {
304
289
  type: "icon-zhankai",
305
290
  style: {
306
291
  fontSize: 16
307
292
  }
308
- }) : /* @__PURE__ */ e(m, {
293
+ }) : /* @__PURE__ */ e(p, {
309
294
  type: "icon-shouqi",
310
295
  style: {
311
296
  fontSize: 16
312
297
  }
313
298
  })
314
299
  })]
315
- }), !!((U = n == null ? void 0 : n.reasoningContent) != null && U.trim()) && v && /* @__PURE__ */ o("div", {
300
+ }), !!((I = n == null ? void 0 : n.reasoningContent) != null && I.trim()) && v && /* @__PURE__ */ o("div", {
316
301
  className: "think-bottom",
317
302
  children: [/* @__PURE__ */ o("div", {
318
303
  className: "bottom-left",
319
- children: [(n == null ? void 0 : n.thinkingStatus) === te.Start && /* @__PURE__ */ e("div", {
304
+ children: [(n == null ? void 0 : n.thinkingStatus) === ee.Start && /* @__PURE__ */ e("div", {
320
305
  className: "thinking"
321
- }), (n == null ? void 0 : n.thinkingStatus) === te.End && /* @__PURE__ */ e("div", {
306
+ }), (n == null ? void 0 : n.thinkingStatus) === ee.End && /* @__PURE__ */ e("div", {
322
307
  className: "thinked",
323
- children: /* @__PURE__ */ e(oe, {})
308
+ children: /* @__PURE__ */ e(le, {})
324
309
  })]
325
310
  }), /* @__PURE__ */ e("div", {
326
311
  className: "bottom-right",
327
- children: /* @__PURE__ */ e(h, R(L({}, c), {
312
+ children: /* @__PURE__ */ e(u, R(y({}, d), {
328
313
  children: (n == null ? void 0 : n.reasoningContent) || ""
329
314
  }))
330
315
  })]
331
316
  })]
332
- }), /* @__PURE__ */ e(h, R(L({}, c), {
317
+ }), /* @__PURE__ */ e(u, R(y({}, d), {
333
318
  children: n.content
334
319
  }))]
335
- }), (j = n == null ? void 0 : n.reference) != null && j.length && !((z = r == null ? void 0 : r.reference) != null && z.referenceFirst) ? /* @__PURE__ */ e(ce, {
320
+ }), (U = n == null ? void 0 : n.reference) != null && U.length && !((z = r == null ? void 0 : r.reference) != null && z.referenceFirst) ? /* @__PURE__ */ e(re, {
336
321
  history: n,
337
- docViewerUrl: d,
338
- markdown: c
339
- }) : null, n.isRelatedQuestion && f ? /* @__PURE__ */ e("div", {
322
+ docViewerUrl: f,
323
+ markdown: d
324
+ }) : null, n.isRelatedQuestion && N ? /* @__PURE__ */ e("div", {
340
325
  style: {
341
326
  paddingBottom: 12
342
327
  },
343
- children: /* @__PURE__ */ e(p, {
328
+ children: /* @__PURE__ */ e(c, {
344
329
  size: 4
345
330
  })
346
331
  }) : null, n.isRelateLoading && /* @__PURE__ */ e("div", {
@@ -348,23 +333,23 @@ const Je = (s) => {
348
333
  style: {
349
334
  padding: "4px 0"
350
335
  },
351
- children: me(n.actions) ? null : /* @__PURE__ */ e(p, {
336
+ children: ae(n.actions) ? null : /* @__PURE__ */ e(c, {
352
337
  size: 4,
353
338
  text: "思考中"
354
339
  })
355
- }), i.arrange[0].recommendQuestionOpen && (r == null ? void 0 : r.relate) && f && !!((w = n.relatedQuesion) != null && w.length) && /* @__PURE__ */ e(je, {
340
+ }), i.arrange[0].recommendQuestionOpen && (r == null ? void 0 : r.relate) && N && !!((j = n.relatedQuesion) != null && j.length) && /* @__PURE__ */ e(_e, {
356
341
  relatedQuesion: n.relatedQuesion,
357
- onRelatedClick: ue
358
- }), ge && !n.isSensitive && !!n.messageId && /* @__PURE__ */ e(xe, {
342
+ onRelatedClick: oe
343
+ }), ce && !n.isSensitive && !!n.messageId && /* @__PURE__ */ e(Re, {
359
344
  appId: i.id,
360
345
  history: n,
361
346
  sessionId: (B = l == null ? void 0 : l.data) == null ? void 0 : B.id,
362
- onAgainClick: he,
363
- isLastHistory: f,
347
+ onAgainClick: de,
348
+ isLastHistory: N,
364
349
  currentSession: l
365
350
  })]
366
351
  })
367
- }), n.isContext && /* @__PURE__ */ o(Oe, {
352
+ }), n.isContext && /* @__PURE__ */ o(xe, {
368
353
  children: [/* @__PURE__ */ e("div", {
369
354
  style: {
370
355
  color: "#84868C",
@@ -374,7 +359,7 @@ const Je = (s) => {
374
359
  }), " "]
375
360
  }), n.isWaiting && /* @__PURE__ */ e("div", {
376
361
  className: "history-input-progress",
377
- children: /* @__PURE__ */ e(p, {
362
+ children: /* @__PURE__ */ e(c, {
378
363
  size: 4,
379
364
  text: "思考中"
380
365
  })
@@ -382,6 +367,6 @@ const Je = (s) => {
382
367
  });
383
368
  };
384
369
  export {
385
- mn as default,
386
- g as isResultExec
370
+ cn as default,
371
+ h as isResultExec
387
372
  };
@@ -335,7 +335,7 @@ const Ae = he((L, P) => {
335
335
  });
336
336
  return;
337
337
  }
338
- window.open(`${q}#/doc?url=${encodeURIComponent(e == null ? void 0 : e.url)}`);
338
+ window.open(`${q}?url=${encodeURIComponent(e == null ? void 0 : e.url)}`);
339
339
  },
340
340
  remove: () => {
341
341
  ie(e);