@glodon-aiot/agent-cli-ui 3.0.5-beta.0 → 3.0.5
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.
|
@@ -46,7 +46,7 @@ const u = (o) => {
|
|
|
46
46
|
const r = JSON.parse(JSON.stringify(o)) || [], a = (t = r == null ? void 0 : r.pop()) == null ? void 0 : t.pop();
|
|
47
47
|
return a ? (a == null ? void 0 : a.type) === "BEFORE_CALL" || (a == null ? void 0 : a.type) === "FUNCTION_CALL" : !1;
|
|
48
48
|
}, Ke = (o) => {
|
|
49
|
-
var S, b, E, k, T, A,
|
|
49
|
+
var S, b, E, k, T, A, x, O, F;
|
|
50
50
|
const {
|
|
51
51
|
application: r,
|
|
52
52
|
currentSession: a,
|
|
@@ -118,6 +118,7 @@ const u = (o) => {
|
|
|
118
118
|
children: /* @__PURE__ */ e("span", {
|
|
119
119
|
className: "item-user-content",
|
|
120
120
|
children: /* @__PURE__ */ e(C, {
|
|
121
|
+
showLatex: !1,
|
|
121
122
|
children: Se(t.content)
|
|
122
123
|
})
|
|
123
124
|
})
|
|
@@ -296,7 +297,7 @@ const u = (o) => {
|
|
|
296
297
|
}), /* @__PURE__ */ e(C, {
|
|
297
298
|
children: t.content
|
|
298
299
|
})]
|
|
299
|
-
}), (A = t == null ? void 0 : t.reference) != null && A.length && !((
|
|
300
|
+
}), (A = t == null ? void 0 : t.reference) != null && A.length && !((x = i == null ? void 0 : i.reference) != null && x.referenceFirst) ? /* @__PURE__ */ e(K, {
|
|
300
301
|
history: t,
|
|
301
302
|
docViewerUrl: g
|
|
302
303
|
}) : null, t.isRelatedQuestion && h ? /* @__PURE__ */ e("div", {
|
|
@@ -315,7 +316,7 @@ const u = (o) => {
|
|
|
315
316
|
size: 4,
|
|
316
317
|
text: "思考中"
|
|
317
318
|
})
|
|
318
|
-
}), (i == null ? void 0 : i.relate) && h && !!((
|
|
319
|
+
}), (i == null ? void 0 : i.relate) && h && !!((O = t.relatedQuesion) != null && O.length) && /* @__PURE__ */ e(Ce, {
|
|
319
320
|
relatedQuesion: t.relatedQuesion,
|
|
320
321
|
onRelatedClick: Y
|
|
321
322
|
}), !t.isSensitive && !!t.messageId && /* @__PURE__ */ e(ae, {
|
|
@@ -1,53 +1,69 @@
|
|
|
1
|
-
var
|
|
2
|
-
var
|
|
3
|
-
var
|
|
4
|
-
var
|
|
5
|
-
var
|
|
6
|
-
for (var o in
|
|
7
|
-
|
|
8
|
-
if (
|
|
9
|
-
for (var o of
|
|
10
|
-
|
|
11
|
-
return
|
|
12
|
-
},
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
1
|
+
var c = Object.defineProperty, g = Object.defineProperties;
|
|
2
|
+
var h = Object.getOwnPropertyDescriptors;
|
|
3
|
+
var t = Object.getOwnPropertySymbols;
|
|
4
|
+
var l = Object.prototype.hasOwnProperty, s = Object.prototype.propertyIsEnumerable;
|
|
5
|
+
var f = (r, e, o) => e in r ? c(r, e, { enumerable: !0, configurable: !0, writable: !0, value: o }) : r[e] = o, a = (r, e) => {
|
|
6
|
+
for (var o in e || (e = {}))
|
|
7
|
+
l.call(e, o) && f(r, o, e[o]);
|
|
8
|
+
if (t)
|
|
9
|
+
for (var o of t(e))
|
|
10
|
+
s.call(e, o) && f(r, o, e[o]);
|
|
11
|
+
return r;
|
|
12
|
+
}, d = (r, e) => g(r, h(e));
|
|
13
|
+
var k = (r, e) => {
|
|
14
|
+
var o = {};
|
|
15
|
+
for (var m in r)
|
|
16
|
+
l.call(r, m) && e.indexOf(m) < 0 && (o[m] = r[m]);
|
|
17
|
+
if (r != null && t)
|
|
18
|
+
for (var m of t(r))
|
|
19
|
+
e.indexOf(m) < 0 && s.call(r, m) && (o[m] = r[m]);
|
|
20
|
+
return o;
|
|
21
|
+
};
|
|
22
|
+
import { jsx as i } from "../../_virtual/jsx-runtime.mjs";
|
|
23
|
+
import { useRef as w } from "react";
|
|
24
|
+
import x from "react-markdown";
|
|
25
|
+
import M from "remark-gfm";
|
|
26
|
+
import y from "rehype-raw";
|
|
27
|
+
import R from "rehype-external-links";
|
|
19
28
|
import "../../node_modules/katex/dist/katex.min.css.mjs";
|
|
20
29
|
import "./style.less.mjs";
|
|
21
|
-
import
|
|
22
|
-
import
|
|
23
|
-
import { replaceLatexDelimiters as
|
|
24
|
-
import
|
|
25
|
-
import
|
|
26
|
-
const
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
30
|
+
import L from "./Image/index.mjs";
|
|
31
|
+
import P from "./Code/index.mjs";
|
|
32
|
+
import { replaceLatexDelimiters as b } from "../../utils/index.mjs";
|
|
33
|
+
import j from "../../node_modules/rehype-katex/lib/index.mjs";
|
|
34
|
+
import v from "../../node_modules/remark-math/lib/index.mjs";
|
|
35
|
+
const H = (m) => {
|
|
36
|
+
var p = m, {
|
|
37
|
+
showLatex: r = !0,
|
|
38
|
+
children: e
|
|
39
|
+
} = p, o = k(p, [
|
|
40
|
+
"showLatex",
|
|
41
|
+
"children"
|
|
42
|
+
]);
|
|
43
|
+
const u = w(null);
|
|
44
|
+
return /* @__PURE__ */ i("div", {
|
|
45
|
+
ref: u,
|
|
46
|
+
children: /* @__PURE__ */ i(x, d(a({
|
|
31
47
|
className: "markdown",
|
|
32
|
-
rehypePlugins: [
|
|
48
|
+
rehypePlugins: [j, y, [R, {
|
|
33
49
|
target: "_blank"
|
|
34
50
|
}]],
|
|
35
|
-
remarkPlugins: [
|
|
51
|
+
remarkPlugins: [v, [M, {
|
|
36
52
|
singleTilde: !1
|
|
37
53
|
}]]
|
|
38
|
-
},
|
|
39
|
-
children:
|
|
54
|
+
}, o), {
|
|
55
|
+
children: r ? b(e) : e,
|
|
40
56
|
components: {
|
|
41
|
-
img(
|
|
42
|
-
return /* @__PURE__ */
|
|
57
|
+
img(n) {
|
|
58
|
+
return /* @__PURE__ */ i(L, a({}, n));
|
|
43
59
|
},
|
|
44
|
-
code(
|
|
45
|
-
return /* @__PURE__ */
|
|
60
|
+
code(n) {
|
|
61
|
+
return /* @__PURE__ */ i(P, a({}, n));
|
|
46
62
|
}
|
|
47
63
|
}
|
|
48
64
|
}))
|
|
49
65
|
});
|
|
50
66
|
};
|
|
51
67
|
export {
|
|
52
|
-
|
|
68
|
+
H as default
|
|
53
69
|
};
|