@agentscope-ai/chat 1.1.7 → 1.1.8
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/lib/Bubble/ScrollToBottom.js +1 -1
- package/lib/ChatAnywhere/Header/index.js +1 -1
- package/lib/ChatAnywhere/Input/index.js +8 -5
- package/lib/ChatAnywhere/SessionList/index.js +1 -1
- package/lib/ChatAnywhere/hooks/useInput.d.ts +2 -0
- package/lib/ChatAnywhere/hooks/useInput.js +8 -2
- package/lib/Conversations/Item.js +1 -1
- package/lib/DefaultCards/Footer/index.js +1 -1
- package/lib/Markdown/CodeBlock.js +1 -1
- package/lib/Markdown/cursor/Dot.js +2 -1
- package/lib/Markdown/cursor/Underline.js +2 -1
- package/lib/Markdown/index.js +14 -18
- package/lib/Markdown/style.js +1 -7
- package/lib/Mermaid/index.js +1 -1
- package/lib/Provider/index.js +1 -1
- package/lib/ResponsesAPI/index.js +0 -0
- package/lib/Sender/ModeSelect/index.js +1 -1
- package/lib/Sender/components/ActionButton.js +1 -1
- package/lib/Sender/index.js +1 -1
- package/package.json +2 -2
- /package/lib/{index.less → ResponsesAPI/index.d.ts} +0 -0
|
@@ -2,7 +2,7 @@ import React from 'react';
|
|
|
2
2
|
import { useProviderContext } from "./..";
|
|
3
3
|
import cls from 'classnames';
|
|
4
4
|
import { useStickToBottomContext } from 'use-stick-to-bottom';
|
|
5
|
-
import { IconButton } from "@
|
|
5
|
+
import { IconButton } from "@agentscope-ai/design";
|
|
6
6
|
import { SparkDownArrowLine } from '@agentscope-ai/icons';
|
|
7
7
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
8
8
|
var ScrollToBottomButton = function ScrollToBottomButton(_, ref) {
|
|
@@ -4,7 +4,7 @@ import { isMobileHook } from "../Layout";
|
|
|
4
4
|
import { useChatAnywhere } from "../hooks/ChatAnywhereProvider";
|
|
5
5
|
import { useSessionList } from "../hooks/useSessionList";
|
|
6
6
|
import useStyle from "./style";
|
|
7
|
-
import { IconButton } from "@
|
|
7
|
+
import { IconButton } from "@agentscope-ai/design";
|
|
8
8
|
import { SparkOperateLeftLine, SparkOperateRightLine } from "@agentscope-ai/icons";
|
|
9
9
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
10
10
|
import { jsxs as _jsxs } from "react/jsx-runtime";
|
|
@@ -13,14 +13,14 @@ function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o =
|
|
|
13
13
|
function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i]; return arr2; }
|
|
14
14
|
function _iterableToArrayLimit(r, l) { var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t.return && (u = t.return(), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } }
|
|
15
15
|
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
16
|
-
import React, { forwardRef,
|
|
16
|
+
import React, { forwardRef, useEffect } from 'react';
|
|
17
17
|
import { useProviderContext, ChatInput, Sender, Attachments } from "../..";
|
|
18
18
|
import cls from 'classnames';
|
|
19
19
|
import { useChatAnywhere } from "../hooks/ChatAnywhereProvider";
|
|
20
20
|
import { useInput } from "../hooks/useInput";
|
|
21
21
|
import { Upload } from 'antd';
|
|
22
22
|
import useStyle from "./style";
|
|
23
|
-
import { IconButton } from "@
|
|
23
|
+
import { IconButton } from "@agentscope-ai/design";
|
|
24
24
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
25
25
|
import { createElement as _createElement } from "react";
|
|
26
26
|
import { Fragment as _Fragment } from "react/jsx-runtime";
|
|
@@ -34,11 +34,14 @@ export default /*#__PURE__*/forwardRef(function (_, ref) {
|
|
|
34
34
|
var onUpload = useChatAnywhere(function (v) {
|
|
35
35
|
return v.onUpload;
|
|
36
36
|
});
|
|
37
|
-
var resetData =
|
|
38
|
-
var _React$useState3 = React.useState(resetData
|
|
37
|
+
var resetData = new Array((onUpload === null || onUpload === void 0 ? void 0 : onUpload.length) || 0).fill([]);
|
|
38
|
+
var _React$useState3 = React.useState(resetData),
|
|
39
39
|
_React$useState4 = _slicedToArray(_React$useState3, 2),
|
|
40
40
|
attachedFiles = _React$useState4[0],
|
|
41
41
|
setAttachedFiles = _React$useState4[1];
|
|
42
|
+
useEffect(function () {
|
|
43
|
+
setAttachedFiles(resetData);
|
|
44
|
+
}, [resetData.length]);
|
|
42
45
|
var inputContext = useInput();
|
|
43
46
|
var uiConfig = useChatAnywhere(function (v) {
|
|
44
47
|
return v.uiConfig;
|
|
@@ -171,7 +174,7 @@ export default /*#__PURE__*/forwardRef(function (_, ref) {
|
|
|
171
174
|
fileList: submitFileList
|
|
172
175
|
});
|
|
173
176
|
setContent('');
|
|
174
|
-
setAttachedFiles(resetData
|
|
177
|
+
setAttachedFiles(resetData);
|
|
175
178
|
case 8:
|
|
176
179
|
case "end":
|
|
177
180
|
return _context2.stop();
|
|
@@ -2,7 +2,7 @@ import React, { useEffect } from 'react';
|
|
|
2
2
|
import { Conversations } from "../..";
|
|
3
3
|
import cls from 'classnames';
|
|
4
4
|
import { useProviderContext } from "../..";
|
|
5
|
-
import { Button, IconButton } from "@
|
|
5
|
+
import { Button, IconButton } from "@agentscope-ai/design";
|
|
6
6
|
import { useChatAnywhere } from "../hooks/ChatAnywhereProvider";
|
|
7
7
|
import { useSessionList } from "../hooks/useSessionList";
|
|
8
8
|
import { useMessages } from "../hooks/useMessages";
|
|
@@ -3,7 +3,9 @@ export function useInput() {
|
|
|
3
3
|
var _useChatAnywhere = useChatAnywhere(function (v) {
|
|
4
4
|
return {
|
|
5
5
|
loading: v.loading,
|
|
6
|
+
getLoading: v.getLoading,
|
|
6
7
|
disabled: v.disabled,
|
|
8
|
+
getDisabled: v.getDisabled,
|
|
7
9
|
setLoading: v.setLoading,
|
|
8
10
|
setDisabled: v.setDisabled
|
|
9
11
|
};
|
|
@@ -11,11 +13,15 @@ export function useInput() {
|
|
|
11
13
|
loading = _useChatAnywhere.loading,
|
|
12
14
|
disabled = _useChatAnywhere.disabled,
|
|
13
15
|
setLoading = _useChatAnywhere.setLoading,
|
|
14
|
-
setDisabled = _useChatAnywhere.setDisabled
|
|
16
|
+
setDisabled = _useChatAnywhere.setDisabled,
|
|
17
|
+
getLoading = _useChatAnywhere.getLoading,
|
|
18
|
+
getDisabled = _useChatAnywhere.getDisabled;
|
|
15
19
|
return {
|
|
16
20
|
loading: loading,
|
|
17
21
|
disabled: disabled,
|
|
18
22
|
setLoading: setLoading,
|
|
19
|
-
setDisabled: setDisabled
|
|
23
|
+
setDisabled: setDisabled,
|
|
24
|
+
getLoading: getLoading,
|
|
25
|
+
getDisabled: getDisabled
|
|
20
26
|
};
|
|
21
27
|
}
|
|
@@ -18,7 +18,7 @@ import classnames from 'classnames';
|
|
|
18
18
|
import React, { useEffect, useMemo, useRef, useState } from 'react';
|
|
19
19
|
import pickAttrs from 'rc-util/lib/pickAttrs';
|
|
20
20
|
import { SparkMoreLine } from '@agentscope-ai/icons';
|
|
21
|
-
import { IconButton } from "@
|
|
21
|
+
import { IconButton } from "@agentscope-ai/design";
|
|
22
22
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
23
23
|
import { jsxs as _jsxs } from "react/jsx-runtime";
|
|
24
24
|
var stopPropagation = function stopPropagation(e) {
|
|
@@ -2,7 +2,7 @@ var _templateObject;
|
|
|
2
2
|
function _taggedTemplateLiteral(strings, raw) { if (!raw) { raw = strings.slice(0); } return Object.freeze(Object.defineProperties(strings, { raw: { value: Object.freeze(raw) } })); }
|
|
3
3
|
import React from 'react';
|
|
4
4
|
import { createGlobalStyle, useProviderContext } from "../..";
|
|
5
|
-
import { IconButton } from "@
|
|
5
|
+
import { IconButton } from "@agentscope-ai/design";
|
|
6
6
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
7
7
|
import { jsxs as _jsxs } from "react/jsx-runtime";
|
|
8
8
|
import { Fragment as _Fragment } from "react/jsx-runtime";
|
|
@@ -7,7 +7,7 @@ function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len
|
|
|
7
7
|
function _iterableToArrayLimit(r, l) { var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t.return && (u = t.return(), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } }
|
|
8
8
|
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
9
9
|
import React, { useState } from 'react';
|
|
10
|
-
import { CodeBlock as Code, CodeBlockLangExtensionsMap } from "@
|
|
10
|
+
import { CodeBlock as Code, CodeBlockLangExtensionsMap } from "@agentscope-ai/design";
|
|
11
11
|
import { createStyles } from 'antd-style';
|
|
12
12
|
import { useProviderContext, Mermaid } from "./..";
|
|
13
13
|
import { theme as AntdTheme } from 'antd';
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
var _templateObject;
|
|
2
2
|
function _taggedTemplateLiteral(strings, raw) { if (!raw) { raw = strings.slice(0); } return Object.freeze(Object.defineProperties(strings, { raw: { value: Object.freeze(raw) } })); }
|
|
3
3
|
import { createGlobalStyle, useProviderContext } from "../..";
|
|
4
|
+
import classNames from 'classnames';
|
|
4
5
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
5
6
|
import { jsxs as _jsxs } from "react/jsx-runtime";
|
|
6
7
|
import { Fragment as _Fragment } from "react/jsx-runtime";
|
|
@@ -18,7 +19,7 @@ export default function () {
|
|
|
18
19
|
var Style = useStyle();
|
|
19
20
|
return /*#__PURE__*/_jsxs(_Fragment, {
|
|
20
21
|
children: [/*#__PURE__*/_jsx(Style, {}), /*#__PURE__*/_jsxs("span", {
|
|
21
|
-
className: prefixCls,
|
|
22
|
+
className: classNames(prefixCls, getPrefixCls('markdown-cursor')),
|
|
22
23
|
children: [/*#__PURE__*/_jsx("span", {
|
|
23
24
|
style: {
|
|
24
25
|
opacity: 0,
|
|
@@ -2,6 +2,7 @@ var _templateObject;
|
|
|
2
2
|
function _taggedTemplateLiteral(strings, raw) { if (!raw) { raw = strings.slice(0); } return Object.freeze(Object.defineProperties(strings, { raw: { value: Object.freeze(raw) } })); }
|
|
3
3
|
import React from 'react';
|
|
4
4
|
import { createGlobalStyle, useProviderContext } from "../..";
|
|
5
|
+
import classNames from 'classnames';
|
|
5
6
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
6
7
|
import { Fragment as _Fragment } from "react/jsx-runtime";
|
|
7
8
|
import { jsxs as _jsxs } from "react/jsx-runtime";
|
|
@@ -13,7 +14,7 @@ export default function () {
|
|
|
13
14
|
var Style = useStyle();
|
|
14
15
|
return /*#__PURE__*/_jsxs(_Fragment, {
|
|
15
16
|
children: [/*#__PURE__*/_jsx(Style, {}), /*#__PURE__*/_jsx("span", {
|
|
16
|
-
className: prefixCls
|
|
17
|
+
className: classNames(prefixCls, getPrefixCls('markdown-cursor'))
|
|
17
18
|
})]
|
|
18
19
|
});
|
|
19
20
|
}
|
package/lib/Markdown/index.js
CHANGED
|
@@ -1,9 +1,10 @@
|
|
|
1
1
|
import React, { memo } from 'react';
|
|
2
2
|
import Markdown from "./Markdown";
|
|
3
|
-
import { ConfigProvider, Typography } from 'antd';
|
|
4
3
|
import useStyle from "./style";
|
|
5
4
|
import { useGlobalContext, useProviderContext } from "./..";
|
|
5
|
+
import classnames from 'classnames';
|
|
6
6
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
7
|
+
import { Fragment as _Fragment } from "react/jsx-runtime";
|
|
7
8
|
import { jsxs as _jsxs } from "react/jsx-runtime";
|
|
8
9
|
function MarkdownComponent(props) {
|
|
9
10
|
var _useGlobalContext = useGlobalContext(),
|
|
@@ -18,25 +19,20 @@ function MarkdownComponent(props) {
|
|
|
18
19
|
var _useProviderContext = useProviderContext(),
|
|
19
20
|
getPrefixCls = _useProviderContext.getPrefixCls;
|
|
20
21
|
var prefixCls = getPrefixCls('markdown');
|
|
21
|
-
return /*#__PURE__*/_jsxs(
|
|
22
|
-
|
|
23
|
-
|
|
22
|
+
return /*#__PURE__*/_jsxs(_Fragment, {
|
|
23
|
+
children: [/*#__PURE__*/_jsx(Style, {}), /*#__PURE__*/_jsx("div", {
|
|
24
|
+
className: classnames(prefixCls, props.className),
|
|
25
|
+
style: {
|
|
24
26
|
fontSize: baseFontSize,
|
|
25
27
|
lineHeight: baseLineHeight
|
|
26
|
-
}
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
citationsMap: props.citationsMap,
|
|
35
|
-
allowHtml: props.allowHtml,
|
|
36
|
-
components: props.components,
|
|
37
|
-
cursor: props.cursor,
|
|
38
|
-
children: content
|
|
39
|
-
})
|
|
28
|
+
},
|
|
29
|
+
children: raw ? content : /*#__PURE__*/_jsx(Markdown, {
|
|
30
|
+
citations: props.citations,
|
|
31
|
+
citationsMap: props.citationsMap,
|
|
32
|
+
allowHtml: props.allowHtml,
|
|
33
|
+
components: props.components,
|
|
34
|
+
cursor: props.cursor,
|
|
35
|
+
children: content
|
|
40
36
|
})
|
|
41
37
|
})]
|
|
42
38
|
});
|
package/lib/Markdown/style.js
CHANGED
|
@@ -1,9 +1,7 @@
|
|
|
1
1
|
var _templateObject;
|
|
2
2
|
function _taggedTemplateLiteral(strings, raw) { if (!raw) { raw = strings.slice(0); } return Object.freeze(Object.defineProperties(strings, { raw: { value: Object.freeze(raw) } })); }
|
|
3
3
|
import { createGlobalStyle } from "./..";
|
|
4
|
-
export default createGlobalStyle(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n.", "-markdown
|
|
5
|
-
return p.prefix;
|
|
6
|
-
}, function (p) {
|
|
4
|
+
export default createGlobalStyle(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n.", "-markdown {\n color: inherit;\n\n .katex-display {\n font-size: 1.3em;\n }\n\n .katex-html {\n display: none;\n }\n\n .katex-error {\n color: inherit !important;\n }\n\n .cm-gutter-lint {\n width: 0;\n }\n\n .cm-line {\n background-color: transparent !important;\n }\n\n .cm-activeLineGutter {\n background-color: transparent !important;\n color: inherit !important;\n }\n\n .\u037C1.cm-focused {\n outline: 0 !important;\n }\n\n mstyle[mathcolor=\"#cc0000\"] {\n opacity: 0;\n }\n\n ol, ul {\n padding-left: 30px;\n }\n\n blockquote {\n padding-inline: 0.6em 0;\n padding-block: 0;\n margin: 1em 0;\n border-inline-start: 4px solid rgba(100, 100, 100, 0.2);\n opacity: 0.85;\n }\n\n &-cursor {}\n\n figure {\n margin: 0;\n }\n\n figure img {\n display: block;\n cursor: pointer;\n }\n\n code .", "-markdown-cursor,\n pre .", "-markdown-cursor,\n table .", "-markdown-cursor {\n display: none;\n }\n\n @keyframes typography-cursor {\n 0% {\n opacity: 1;\n }\n\n 100% {\n opacity: 0;\n }\n }\n\n code {\n font-size: 0.8571428571428571em;\n border: 0 !important;\n }\n\n pre code {\n font-size: 0.8571428571428571em;\n }\n\n h1,\n h2,\n h3,\n h4,\n h5,\n h6 {\n margin-top: 0.5714285714285714em !important;\n margin-bottom: 0.5714285714285714em !important;\n font-weight: 500;\n line-height: 1.7777;\n color: inherit !important;\n }\n\n p {\n margin-top: 0.5714285714285714em !important;\n margin-bottom: 0.5714285714285714em !important;\n }\n\n h1 {\n font-size: 1.2857142857142858em;\n }\n\n h2 {\n font-size: 1.1428571428571428em;\n }\n\n h3 {\n font-size: 1em;\n }\n\n h4 {\n font-size: 1em;\n }\n\n h5 {\n font-size: 1em;\n }\n\n h6 {\n font-size: 1em;\n }\n\n hr {\n border-color: ", ";\n border-style: solid;\n border-width: 1px 0 0 0;\n margin: 1em 0;\n }\n\n table {\n border-collapse: collapse;\n display: block;\n width: max-content;\n max-width: 100%;\n overflow: auto;\n }\n\n table th {\n background: ", ";\n text-align: left;\n }\n\n table td,\n table th {\n padding: 0.75em 1.5em;\n border: 1px solid ", ";\n white-space: pre;\n }\n\n .", "-image {\n min-width: 70%;\n }\n\n}\n\n.", "-markdown-video {\n position: relative;\n width: 30%;\n padding-top: 18%;\n border-radius: 8px;\n cursor: pointer;\n background-color: #000;\n\n &-play {\n position: absolute;\n top: 50%;\n left: 50%;\n transform: translate(-50%, -50%);\n z-index: 1;\n color: #ccc;\n font-size: 30px;\n }\n}\n\n\n.", "-markdown .", "-image {\n cursor: pointer;\n overflow: hidden;\n border-radius: 8px;\n}\n\n.", "-markdown > *:last-child {\n margin-bottom: 0 !important;\n}\n\n.", "-markdown > *:first-child {\n margin-top: 0 !important;\n}\n\n@keyframes fade-in {\n 0% {\n opacity: 0;\n }\n\n 100% {\n opacity: 1;\n }\n}\n\n\n.animate-fade-in {\n animation: fade-in 1s;\n}\n\n"])), function (p) {
|
|
7
5
|
return p.prefix;
|
|
8
6
|
}, function (p) {
|
|
9
7
|
return p.prefix;
|
|
@@ -29,8 +27,4 @@ export default createGlobalStyle(_templateObject || (_templateObject = _taggedTe
|
|
|
29
27
|
return p.prefix;
|
|
30
28
|
}, function (p) {
|
|
31
29
|
return p.prefix;
|
|
32
|
-
}, function (p) {
|
|
33
|
-
return p.prefix;
|
|
34
|
-
}, function (p) {
|
|
35
|
-
return p.prefix;
|
|
36
30
|
});
|
package/lib/Mermaid/index.js
CHANGED
|
@@ -10,7 +10,7 @@ function _regeneratorRuntime() { "use strict"; /*! regenerator-runtime -- Copyri
|
|
|
10
10
|
function asyncGeneratorStep(gen, resolve, reject, _next, _throw, key, arg) { try { var info = gen[key](arg); var value = info.value; } catch (error) { reject(error); return; } if (info.done) { resolve(value); } else { Promise.resolve(value).then(_next, _throw); } }
|
|
11
11
|
function _asyncToGenerator(fn) { return function () { var self = this, args = arguments; return new Promise(function (resolve, reject) { var gen = fn.apply(self, args); function _next(value) { asyncGeneratorStep(gen, resolve, reject, _next, _throw, "next", value); } function _throw(err) { asyncGeneratorStep(gen, resolve, reject, _next, _throw, "throw", err); } _next(undefined); }); }; }
|
|
12
12
|
function _taggedTemplateLiteral(strings, raw) { if (!raw) { raw = strings.slice(0); } return Object.freeze(Object.defineProperties(strings, { raw: { value: Object.freeze(raw) } })); }
|
|
13
|
-
import { Image } from "@
|
|
13
|
+
import { Image } from "@agentscope-ai/design";
|
|
14
14
|
import { useAsyncEffect } from 'ahooks';
|
|
15
15
|
import { theme as AntdTheme } from 'antd';
|
|
16
16
|
import { kebabCase } from 'lodash';
|
package/lib/Provider/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ConfigProvider } from "@
|
|
1
|
+
import { ConfigProvider } from "@agentscope-ai/design";
|
|
2
2
|
import React from "react";
|
|
3
3
|
import { CustomCardsProvider, CustomCardsContext, useCustomCardsContext } from "./CustomCardsProvider";
|
|
4
4
|
import { GlobalProvider, GlobalContext, useGlobalContext } from "./GlobalProvider";
|
|
File without changes
|
|
@@ -9,7 +9,7 @@ function _taggedTemplateLiteral(strings, raw) { if (!raw) { raw = strings.slice(
|
|
|
9
9
|
import React, { useMemo } from "react";
|
|
10
10
|
import { createGlobalStyle, useProviderContext } from "../..";
|
|
11
11
|
import { SparkFalseLine } from "@agentscope-ai/icons";
|
|
12
|
-
import { Tooltip } from "@
|
|
12
|
+
import { Tooltip } from "@agentscope-ai/design";
|
|
13
13
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
14
14
|
import { jsxs as _jsxs } from "react/jsx-runtime";
|
|
15
15
|
import { Fragment as _Fragment } from "react/jsx-runtime";
|
|
@@ -7,7 +7,7 @@ function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol"
|
|
|
7
7
|
function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
|
|
8
8
|
function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
|
|
9
9
|
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
|
10
|
-
import { IconButton } from "@
|
|
10
|
+
import { IconButton } from "@agentscope-ai/design";
|
|
11
11
|
import classNames from 'classnames';
|
|
12
12
|
import * as React from 'react';
|
|
13
13
|
import { jsx as _jsx } from "react/jsx-runtime";
|
package/lib/Sender/index.js
CHANGED
|
@@ -35,7 +35,7 @@ import useStyle from "./style";
|
|
|
35
35
|
import useSpeech from "./useSpeech";
|
|
36
36
|
import ModeSelect from "./ModeSelect";
|
|
37
37
|
import { SparkEnlargeLine, SparkShrinkLine } from '@agentscope-ai/icons';
|
|
38
|
-
import { IconButton } from "@
|
|
38
|
+
import { IconButton } from "@agentscope-ai/design";
|
|
39
39
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
40
40
|
import { jsxs as _jsxs } from "react/jsx-runtime";
|
|
41
41
|
import { Fragment as _Fragment } from "react/jsx-runtime";
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@agentscope-ai/chat",
|
|
3
|
-
"version": "1.1.
|
|
3
|
+
"version": "1.1.8",
|
|
4
4
|
"description": "a free and open-source chat framework for building excellent LLM-powered chat experiences",
|
|
5
5
|
"sideEffects": [
|
|
6
6
|
"*.less",
|
|
@@ -15,6 +15,7 @@
|
|
|
15
15
|
"license": "Apache-2.0",
|
|
16
16
|
"scripts": {
|
|
17
17
|
"build": "npm run src:build && npm run docs:build",
|
|
18
|
+
"build:publish": "NPM_PUBLISH=1 npm run src:build",
|
|
18
19
|
"build:doc-api": "rm -rf node_modules && tnpm i && npm run start",
|
|
19
20
|
"build:watch": "father dev",
|
|
20
21
|
"dev": "dumi dev",
|
|
@@ -26,7 +27,6 @@
|
|
|
26
27
|
"lint:es": "eslint \"{src,test}/**/*.{js,jsx,ts,tsx}\"",
|
|
27
28
|
"llms:build": "rm -rf llms && LLM=true dumi build",
|
|
28
29
|
"prepare": "husky install && dumi setup",
|
|
29
|
-
"prepublishOnly": "npm run build",
|
|
30
30
|
"src:build": "father build",
|
|
31
31
|
"start": "npm run dev"
|
|
32
32
|
},
|
|
File without changes
|