@myun/gimi-chat 0.0.5 → 0.0.6

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 (49) hide show
  1. package/dist/components/ai-chat-dialogue/index.js +181 -135
  2. package/dist/components/ai-correction/index.js +38 -25
  3. package/dist/components/ai-loading/index.js +12 -8
  4. package/dist/components/answer-item/index.js +135 -113
  5. package/dist/components/ask-card/index.js +42 -33
  6. package/dist/components/chat-input/index.js +135 -114
  7. package/dist/components/chat-voice/VoiceCommunication.js +23 -21
  8. package/dist/components/chat-voice/VoiceRecord.js +24 -21
  9. package/dist/components/conversation-delete/index.js +10 -8
  10. package/dist/components/dots-loading/index.js +10 -7
  11. package/dist/components/empty/index.js +12 -7
  12. package/dist/components/excel-components/ExcelCard.js +7 -3
  13. package/dist/components/excel-components/ExcelExcuting.js +60 -43
  14. package/dist/components/excel-components/ExcelFailCard.js +15 -10
  15. package/dist/components/excel-components/ExcelSuccessCard.js +3 -2
  16. package/dist/components/file-card/fileCardSidebar.js +23 -16
  17. package/dist/components/file-card/index.js +68 -49
  18. package/dist/components/file-preview/index.js +36 -29
  19. package/dist/components/file-upload/index.js +10 -7
  20. package/dist/components/file-upload/uploadV1.js +33 -27
  21. package/dist/components/gimi-sidebar/index.js +20 -13
  22. package/dist/components/header/index.js +18 -11
  23. package/dist/components/iconfont-com/index.js +2 -1
  24. package/dist/components/knowledge-trace/KnowledgeIconComponent.js +28 -22
  25. package/dist/components/knowledge-trace/classList.js +37 -28
  26. package/dist/components/knowledge-trace/documentList.js +36 -27
  27. package/dist/components/knowledge-trace/index.js +28 -21
  28. package/dist/components/knowledge-trace/videoList.js +46 -36
  29. package/dist/components/lottie-img/index.js +10 -8
  30. package/dist/components/message-actions/CopyButton.js +25 -22
  31. package/dist/components/message-actions/LikeButton.js +25 -22
  32. package/dist/components/message-actions/RegenerateButton.js +21 -18
  33. package/dist/components/message-actions/UnLikeButton.js +25 -22
  34. package/dist/components/message-actions/VoicePlay.js +25 -22
  35. package/dist/components/message-list/index.js +85 -72
  36. package/dist/components/no-microphone-root/index.js +39 -29
  37. package/dist/components/preset-agent-content/index.js +20 -15
  38. package/dist/components/reasoning-content/index.js +55 -42
  39. package/dist/components/reference-content/index.js +72 -63
  40. package/dist/components/templates/CommonChat.js +78 -64
  41. package/dist/components/templates/GimiChatComponent.js +13 -6
  42. package/dist/components/templates/demo/demo.js +104 -102
  43. package/dist/components/upload-list/index.js +56 -41
  44. package/dist/components/voice-bars/index.js +22 -19
  45. package/dist/components/voice-check-dialog/index.js +24 -17
  46. package/dist/components/voice-recording/index.js +57 -42
  47. package/dist/components/work-flow-content/demo.js +2 -1
  48. package/dist/components/work-flow-content/index.js +12 -9
  49. package/package.json +6 -5
@@ -3,25 +3,28 @@
3
3
  import { Tooltip } from '@douyinfe/semi-ui';
4
4
  import React from 'react';
5
5
  import { IconRedoStroked } from '@douyinfe/semi-icons';
6
+ import { jsx as _jsx } from "react/jsx-runtime";
6
7
  var RegenerateButton = function RegenerateButton(_ref) {
7
8
  var onRegenerateClick = _ref.onRegenerateClick;
8
- return /*#__PURE__*/React.createElement(Tooltip, {
9
- content: "\u91CD\u65B0\u751F\u6210"
10
- }, /*#__PURE__*/React.createElement("div", {
11
- style: {
12
- display: 'flex',
13
- alignItems: 'center',
14
- cursor: 'pointer',
15
- userSelect: 'none'
16
- },
17
- onClick: function onClick() {
18
- onRegenerateClick === null || onRegenerateClick === void 0 || onRegenerateClick();
19
- }
20
- }, /*#__PURE__*/React.createElement(IconRedoStroked, {
21
- style: {
22
- width: 18,
23
- height: 18
24
- }
25
- })));
9
+ return /*#__PURE__*/_jsx(Tooltip, {
10
+ content: "\u91CD\u65B0\u751F\u6210",
11
+ children: /*#__PURE__*/_jsx("div", {
12
+ style: {
13
+ display: 'flex',
14
+ alignItems: 'center',
15
+ cursor: 'pointer',
16
+ userSelect: 'none'
17
+ },
18
+ onClick: function onClick() {
19
+ onRegenerateClick === null || onRegenerateClick === void 0 || onRegenerateClick();
20
+ },
21
+ children: /*#__PURE__*/_jsx(IconRedoStroked, {
22
+ style: {
23
+ width: 18,
24
+ height: 18
25
+ }
26
+ })
27
+ })
28
+ });
26
29
  };
27
30
  export default RegenerateButton;
@@ -3,32 +3,35 @@ import unloveActive from "../../assets/image/unlike_active.png";
3
3
  import unlove from "../../assets/image/unlove.png";
4
4
  import { Tooltip } from '@douyinfe/semi-ui';
5
5
  import React from 'react';
6
+ import { jsx as _jsx } from "react/jsx-runtime";
6
7
  var UnLikeButton = function UnLikeButton(_ref) {
7
8
  var item = _ref.item,
8
9
  onUnLikeCallback = _ref.onUnLikeCallback;
9
10
  var _usePureChatActions = usePureChatActions(),
10
11
  handleUnlove = _usePureChatActions.handleUnlove;
11
- return /*#__PURE__*/React.createElement(Tooltip, {
12
- content: "".concat(item.mark === 1 ? '已点踩' : '点踩')
13
- }, /*#__PURE__*/React.createElement("div", {
14
- style: {
15
- display: 'flex',
16
- alignItems: 'center',
17
- cursor: 'pointer',
18
- userSelect: 'none'
19
- },
20
- onClick: function onClick() {
21
- handleUnlove(item, 'unlove');
22
- onUnLikeCallback === null || onUnLikeCallback === void 0 || onUnLikeCallback();
23
- }
24
- }, /*#__PURE__*/React.createElement("img", {
25
- width: 18,
26
- height: 18,
27
- style: {
28
- display: 'flex',
29
- alignItems: 'center'
30
- },
31
- src: item.mark === 1 ? unloveActive : unlove
32
- })));
12
+ return /*#__PURE__*/_jsx(Tooltip, {
13
+ content: "".concat(item.mark === 1 ? '已点踩' : '点踩'),
14
+ children: /*#__PURE__*/_jsx("div", {
15
+ style: {
16
+ display: 'flex',
17
+ alignItems: 'center',
18
+ cursor: 'pointer',
19
+ userSelect: 'none'
20
+ },
21
+ onClick: function onClick() {
22
+ handleUnlove(item, 'unlove');
23
+ onUnLikeCallback === null || onUnLikeCallback === void 0 || onUnLikeCallback();
24
+ },
25
+ children: /*#__PURE__*/_jsx("img", {
26
+ width: 18,
27
+ height: 18,
28
+ style: {
29
+ display: 'flex',
30
+ alignItems: 'center'
31
+ },
32
+ src: item.mark === 1 ? unloveActive : unlove
33
+ })
34
+ })
35
+ });
33
36
  };
34
37
  export default UnLikeButton;
@@ -8,6 +8,7 @@ import { Tooltip } from '@douyinfe/semi-ui';
8
8
  import { useAppSelector, useAppDispatch } from "../../store/hooks";
9
9
  import { setCurrentMessageId } from "../../store/slices/gimiMenuSlice";
10
10
  import LottieImg from "../lottie-img";
11
+ import { jsx as _jsx } from "react/jsx-runtime";
11
12
  var getCleanReadText = function getCleanReadText(text) {
12
13
  // 移除<knowledge>标签及内容
13
14
  var newText = text.replace(/<knowledge>.*?<\/knowledge>/g, '').replace(/<excel>.*?<\/excel>/g, '');
@@ -48,27 +49,29 @@ var VoicePlay = function VoicePlay(props) {
48
49
  return _ref.apply(this, arguments);
49
50
  };
50
51
  }();
51
- return /*#__PURE__*/React.createElement(Tooltip, {
52
- content: isActive ? '暂停朗读' : '语音朗读'
53
- }, /*#__PURE__*/React.createElement("div", {
54
- style: {
55
- display: 'flex',
56
- alignItems: 'center',
57
- justifyContent: 'center',
58
- cursor: 'pointer'
59
- },
60
- onClick: handleClick
61
- }, isActive ? /*#__PURE__*/React.createElement(LottieImg, {
62
- name: "aiVoicePlay",
63
- size: [30, 20]
64
- }) : /*#__PURE__*/React.createElement("img", {
65
- width: 18,
66
- height: 18,
67
- style: {
68
- display: 'flex',
69
- alignItems: 'center'
70
- },
71
- src: soundOutIcon
72
- })));
52
+ return /*#__PURE__*/_jsx(Tooltip, {
53
+ content: isActive ? '暂停朗读' : '语音朗读',
54
+ children: /*#__PURE__*/_jsx("div", {
55
+ style: {
56
+ display: 'flex',
57
+ alignItems: 'center',
58
+ justifyContent: 'center',
59
+ cursor: 'pointer'
60
+ },
61
+ onClick: handleClick,
62
+ children: isActive ? /*#__PURE__*/_jsx(LottieImg, {
63
+ name: "aiVoicePlay",
64
+ size: [30, 20]
65
+ }) : /*#__PURE__*/_jsx("img", {
66
+ width: 18,
67
+ height: 18,
68
+ style: {
69
+ display: 'flex',
70
+ alignItems: 'center'
71
+ },
72
+ src: soundOutIcon
73
+ })
74
+ })
75
+ });
73
76
  };
74
77
  export default VoicePlay;
@@ -16,6 +16,9 @@ import { useGimiFileUpload } from "../../hooks/useFile";
16
16
  import { FileStatus } from "../../interfaces/fileInterface";
17
17
  import useChatActions from "../../hooks/useChatActions";
18
18
  import CopyButton from "../message-actions/CopyButton";
19
+ import { jsx as _jsx } from "react/jsx-runtime";
20
+ import { Fragment as _Fragment } from "react/jsx-runtime";
21
+ import { jsxs as _jsxs } from "react/jsx-runtime";
19
22
  var MessageList = function MessageList(_ref) {
20
23
  var chatList = _ref.chatList,
21
24
  handleSend = _ref.handleSend,
@@ -88,77 +91,87 @@ var MessageList = function MessageList(_ref) {
88
91
  var handleShowCourse = useCallback(function (v) {
89
92
  chatUI.showCourse(v.messageId ? v.messageId : v.chatId, v.videoResourceList);
90
93
  }, [chatUI]);
91
- return /*#__PURE__*/React.createElement("div", {
92
- className: classNames(styles.main)
93
- }, /*#__PURE__*/React.createElement("div", {
94
- className: classNames(model === 'sidebar' ? styles.small_container : styles.container)
95
- }, chatList.length > 0 && /*#__PURE__*/React.createElement("div", {
96
- className: styles.textWrap
97
- }, chatList.map(function (v) {
98
- var _v$quoteTeachModelLis, _v$quoteProductList;
99
- return /*#__PURE__*/React.createElement("div", {
100
- key: v.id
101
- }, v.isSystemAuto !== 1 && /*#__PURE__*/React.createElement("div", {
102
- key: String(v.id),
103
- className: classNames(styles.textItem, _defineProperty({}, styles.question, (v === null || v === void 0 ? void 0 : v.type) === 0)),
104
- onMouseLeave: function onMouseLeave() {
105
- return chatUI.setShowCopyId(0);
106
- },
107
- onMouseEnter: function onMouseEnter() {
108
- if (!v.loading) chatUI.setShowCopyId(v.id);
109
- }
110
- }, (v === null || v === void 0 ? void 0 : v.type) === 0 && /*#__PURE__*/React.createElement(React.Fragment, null, v.status !== 1 && /*#__PURE__*/React.createElement("div", {
111
- className: styles.qusetionOpera
112
- }, v.status === 0 && /*#__PURE__*/React.createElement(Spin, {
113
- size: "small"
114
- })), (((_v$quoteTeachModelLis = v.quoteTeachModelList) === null || _v$quoteTeachModelLis === void 0 ? void 0 : _v$quoteTeachModelLis.length) > 0 || ((_v$quoteProductList = v.quoteProductList) === null || _v$quoteProductList === void 0 ? void 0 : _v$quoteProductList.length) > 0) && /*#__PURE__*/React.createElement(References, {
115
- quoteProductList: v.quoteProductList,
116
- quoteTeachModelList: v.quoteTeachModelList
117
- }), v.content && /*#__PURE__*/React.createElement("div", {
118
- className: styles.title
119
- }, replaceBraces(v.content)), v.messageFiles &&
120
- /*#__PURE__*/
121
- // 增加fileUrl校验,确保文件已上传
122
- React.createElement("div", {
123
- className: styles.listBox
124
- }, /*#__PURE__*/React.createElement(UploadList, {
125
- file: v.messageFiles,
126
- showDel: false,
127
- handleDelFile: function handleDelFile() {},
128
- handleReTry: handleReTry
129
- })), v.content && /*#__PURE__*/React.createElement("div", {
130
- className: styles.copyBtn
131
- }, /*#__PURE__*/React.createElement(CopyButton, {
132
- item: v,
133
- onCopyCallback: onCopyCallback
134
- }))), (v === null || v === void 0 ? void 0 : v.type) === 1 && /*#__PURE__*/React.createElement(AnswerItem, {
135
- item: v,
136
- showOpera: showOpera,
137
- onSucess: onSucessExcel,
138
- onFailure: onFailureExcel,
139
- onRetry: onRetryExcel,
140
- onCopyCallback: onCopyCallback,
141
- onLikeCallback: onLikeCallback,
142
- onUnLikeCallback: onUnLikeCallback,
143
- showCommend: showCommend,
144
- handleClickPromptWord: handleClickPromptWord,
145
- handleShowCourse: handleShowCourse,
146
- handleClickAskList: handleClickAskList,
147
- playTTSByText: playTTSByText,
148
- stopTTSByText: stopTTSByText,
149
- isVoicePlaying: isPlaying,
150
- onRegenerateClick: onRegenerateClick,
151
- enableCopy: enableCopy,
152
- enableLike: enableLike,
153
- enableUnLike: enableUnLike,
154
- enableRegenerate: enableRegenerate,
155
- enableVoicePlay: enableVoicePlay
156
- })));
157
- }), msgLoading && /*#__PURE__*/React.createElement("div", {
158
- className: styles.answerLoading
159
- }, /*#__PURE__*/React.createElement(LottieImg, {
160
- name: "aiLoading",
161
- size: [20, 40]
162
- })))));
94
+ return /*#__PURE__*/_jsx("div", {
95
+ className: classNames(styles.main),
96
+ children: /*#__PURE__*/_jsx("div", {
97
+ className: classNames(model === 'sidebar' ? styles.small_container : styles.container),
98
+ children: chatList.length > 0 && /*#__PURE__*/_jsxs("div", {
99
+ className: styles.textWrap,
100
+ children: [chatList.map(function (v) {
101
+ var _v$quoteTeachModelLis, _v$quoteProductList;
102
+ return /*#__PURE__*/_jsx("div", {
103
+ children: v.isSystemAuto !== 1 && /*#__PURE__*/_jsxs("div", {
104
+ className: classNames(styles.textItem, _defineProperty({}, styles.question, (v === null || v === void 0 ? void 0 : v.type) === 0)),
105
+ onMouseLeave: function onMouseLeave() {
106
+ return chatUI.setShowCopyId(0);
107
+ },
108
+ onMouseEnter: function onMouseEnter() {
109
+ if (!v.loading) chatUI.setShowCopyId(v.id);
110
+ },
111
+ children: [(v === null || v === void 0 ? void 0 : v.type) === 0 && /*#__PURE__*/_jsxs(_Fragment, {
112
+ children: [v.status !== 1 && /*#__PURE__*/_jsx("div", {
113
+ className: styles.qusetionOpera,
114
+ children: v.status === 0 && /*#__PURE__*/_jsx(Spin, {
115
+ size: "small"
116
+ })
117
+ }), (((_v$quoteTeachModelLis = v.quoteTeachModelList) === null || _v$quoteTeachModelLis === void 0 ? void 0 : _v$quoteTeachModelLis.length) > 0 || ((_v$quoteProductList = v.quoteProductList) === null || _v$quoteProductList === void 0 ? void 0 : _v$quoteProductList.length) > 0) && /*#__PURE__*/_jsx(References, {
118
+ quoteProductList: v.quoteProductList,
119
+ quoteTeachModelList: v.quoteTeachModelList
120
+ }), v.content && /*#__PURE__*/_jsx("div", {
121
+ className: styles.title,
122
+ children: replaceBraces(v.content)
123
+ }), v.messageFiles &&
124
+ /*#__PURE__*/
125
+ // 增加fileUrl校验,确保文件已上传
126
+ _jsx("div", {
127
+ className: styles.listBox,
128
+ children: /*#__PURE__*/_jsx(UploadList, {
129
+ file: v.messageFiles,
130
+ showDel: false,
131
+ handleDelFile: function handleDelFile() {},
132
+ handleReTry: handleReTry
133
+ })
134
+ }), v.content && /*#__PURE__*/_jsx("div", {
135
+ className: styles.copyBtn,
136
+ children: /*#__PURE__*/_jsx(CopyButton, {
137
+ item: v,
138
+ onCopyCallback: onCopyCallback
139
+ })
140
+ })]
141
+ }), (v === null || v === void 0 ? void 0 : v.type) === 1 && /*#__PURE__*/_jsx(AnswerItem, {
142
+ item: v,
143
+ showOpera: showOpera,
144
+ onSucess: onSucessExcel,
145
+ onFailure: onFailureExcel,
146
+ onRetry: onRetryExcel,
147
+ onCopyCallback: onCopyCallback,
148
+ onLikeCallback: onLikeCallback,
149
+ onUnLikeCallback: onUnLikeCallback,
150
+ showCommend: showCommend,
151
+ handleClickPromptWord: handleClickPromptWord,
152
+ handleShowCourse: handleShowCourse,
153
+ handleClickAskList: handleClickAskList,
154
+ playTTSByText: playTTSByText,
155
+ stopTTSByText: stopTTSByText,
156
+ isVoicePlaying: isPlaying,
157
+ onRegenerateClick: onRegenerateClick,
158
+ enableCopy: enableCopy,
159
+ enableLike: enableLike,
160
+ enableUnLike: enableUnLike,
161
+ enableRegenerate: enableRegenerate,
162
+ enableVoicePlay: enableVoicePlay
163
+ })]
164
+ }, String(v.id))
165
+ }, v.id);
166
+ }), msgLoading && /*#__PURE__*/_jsx("div", {
167
+ className: styles.answerLoading,
168
+ children: /*#__PURE__*/_jsx(LottieImg, {
169
+ name: "aiLoading",
170
+ size: [20, 40]
171
+ })
172
+ })]
173
+ })
174
+ })
175
+ });
163
176
  };
164
177
  export default MessageList;
@@ -2,35 +2,45 @@ import React from 'react';
2
2
  import { Button } from '@douyinfe/semi-ui';
3
3
  import styles from "./index.module.css";
4
4
  import { IconClose, IconMicrophoneOffStroked } from '@douyinfe/semi-icons';
5
+ import { jsx as _jsx } from "react/jsx-runtime";
6
+ import { jsxs as _jsxs } from "react/jsx-runtime";
5
7
  export default function NoMicrophoneModalContent(_ref) {
6
8
  var onOk = _ref.onOk;
7
- return /*#__PURE__*/React.createElement("div", {
8
- className: styles.root
9
- }, /*#__PURE__*/React.createElement("div", {
10
- className: styles.title
11
- }, /*#__PURE__*/React.createElement("span", null, "\u5C1A\u672A\u83B7\u5F97\u9EA6\u514B\u98CE\u6743\u9650"), /*#__PURE__*/React.createElement(Button, {
12
- theme: "borderless",
13
- size: "small",
14
- icon: /*#__PURE__*/React.createElement(IconClose, null),
15
- onClick: onOk
16
- })), /*#__PURE__*/React.createElement("div", {
17
- className: styles.desc
18
- }, "\u8BED\u97F3\u901A\u8BDD\u9700\u8981\u5F00\u542F\u6D4F\u89C8\u5668\u7684\u9EA6\u514B\u98CE\u6743\u9650\uFF0C\u8BF7\u70B9\u51FB\u524D\u5F80\u8BBE\u7F6E\u8FDB\u884C\u5F00\u542F"), /*#__PURE__*/React.createElement("div", {
19
- className: styles.imgArea
20
- }, /*#__PURE__*/React.createElement(IconMicrophoneOffStroked, {
21
- style: {
22
- fontSize: 40,
23
- color: '#1478ddff'
24
- }
25
- })), /*#__PURE__*/React.createElement("div", {
26
- className: styles.footer
27
- }, /*#__PURE__*/React.createElement(Button, {
28
- type: "primary",
29
- size: "small",
30
- style: {
31
- borderRadius: '24px',
32
- padding: '10px'
33
- },
34
- onClick: onOk
35
- }, "\u6211\u77E5\u9053\u4E86")));
9
+ return /*#__PURE__*/_jsxs("div", {
10
+ className: styles.root,
11
+ children: [/*#__PURE__*/_jsxs("div", {
12
+ className: styles.title,
13
+ children: [/*#__PURE__*/_jsx("span", {
14
+ children: "\u5C1A\u672A\u83B7\u5F97\u9EA6\u514B\u98CE\u6743\u9650"
15
+ }), /*#__PURE__*/_jsx(Button, {
16
+ theme: "borderless",
17
+ size: "small",
18
+ icon: /*#__PURE__*/_jsx(IconClose, {}),
19
+ onClick: onOk
20
+ })]
21
+ }), /*#__PURE__*/_jsx("div", {
22
+ className: styles.desc,
23
+ children: "\u8BED\u97F3\u901A\u8BDD\u9700\u8981\u5F00\u542F\u6D4F\u89C8\u5668\u7684\u9EA6\u514B\u98CE\u6743\u9650\uFF0C\u8BF7\u70B9\u51FB\u524D\u5F80\u8BBE\u7F6E\u8FDB\u884C\u5F00\u542F"
24
+ }), /*#__PURE__*/_jsx("div", {
25
+ className: styles.imgArea,
26
+ children: /*#__PURE__*/_jsx(IconMicrophoneOffStroked, {
27
+ style: {
28
+ fontSize: 40,
29
+ color: '#1478ddff'
30
+ }
31
+ })
32
+ }), /*#__PURE__*/_jsx("div", {
33
+ className: styles.footer,
34
+ children: /*#__PURE__*/_jsx(Button, {
35
+ type: "primary",
36
+ size: "small",
37
+ style: {
38
+ borderRadius: '24px',
39
+ padding: '10px'
40
+ },
41
+ onClick: onOk,
42
+ children: "\u6211\u77E5\u9053\u4E86"
43
+ })
44
+ })]
45
+ });
36
46
  }
@@ -1,24 +1,29 @@
1
1
  import React from 'react';
2
2
  import styles from "./index.module.css";
3
+ import { jsx as _jsx } from "react/jsx-runtime";
4
+ import { jsxs as _jsxs } from "react/jsx-runtime";
3
5
  var PresetAgentContent = function PresetAgentContent(_ref) {
4
6
  var prologue = _ref.prologue,
5
7
  questionList = _ref.questionList,
6
8
  setInputValue = _ref.setInputValue;
7
9
  if (!questionList || questionList.length === 0) return null;
8
- return /*#__PURE__*/React.createElement("div", {
9
- className: styles.container
10
- }, prologue && /*#__PURE__*/React.createElement("div", {
11
- className: styles.prologue
12
- }, prologue), /*#__PURE__*/React.createElement("div", {
13
- className: styles.quickInputList
14
- }, questionList.map(function (item, index) {
15
- return /*#__PURE__*/React.createElement("div", {
16
- className: styles.quickInputItem,
17
- key: index,
18
- onClick: function onClick() {
19
- return setInputValue(item.question);
20
- }
21
- }, item.question);
22
- })));
10
+ return /*#__PURE__*/_jsxs("div", {
11
+ className: styles.container,
12
+ children: [prologue && /*#__PURE__*/_jsx("div", {
13
+ className: styles.prologue,
14
+ children: prologue
15
+ }), /*#__PURE__*/_jsx("div", {
16
+ className: styles.quickInputList,
17
+ children: questionList.map(function (item, index) {
18
+ return /*#__PURE__*/_jsx("div", {
19
+ className: styles.quickInputItem,
20
+ onClick: function onClick() {
21
+ return setInputValue(item.question);
22
+ },
23
+ children: item.question
24
+ }, index);
25
+ })
26
+ })]
27
+ });
23
28
  };
24
29
  export default PresetAgentContent;
@@ -22,6 +22,8 @@ import KnowledgeIconGroup from "../knowledge-trace/KnowledgeIconComponent";
22
22
  import { IconChevronUp, IconChevronDown } from '@douyinfe/semi-icons';
23
23
  import { useAppSelector, useAppDispatch } from "../../store/hooks";
24
24
  import { setMessageList } from "../../store/slices/gimiMenuSlice";
25
+ import { jsxs as _jsxs } from "react/jsx-runtime";
26
+ import { jsx as _jsx } from "react/jsx-runtime";
25
27
  var ResoningContent = function ResoningContent(_ref) {
26
28
  var item = _ref.item;
27
29
  var containerRef = useRef(null);
@@ -70,47 +72,58 @@ var ResoningContent = function ResoningContent(_ref) {
70
72
  }
71
73
  };
72
74
  // item.expand ? styles.expand : ''
73
- return /*#__PURE__*/React.createElement("div", {
74
- className: styles.container
75
- }, /*#__PURE__*/React.createElement("div", {
76
- className: styles.header,
77
- onClick: handleClickExpand
78
- }, /*#__PURE__*/React.createElement("div", {
79
- className: styles.title
80
- }, "GIMI", renderStatusText()), item.expand ? /*#__PURE__*/React.createElement(IconChevronUp, null) : /*#__PURE__*/React.createElement(IconChevronDown, null)), item.expand ? /*#__PURE__*/React.createElement("div", {
81
- className: styles.deeping,
82
- ref: containerRef,
83
- style: item.reasoningStatus === 1 ? {
84
- maxHeight: 240
85
- } : {}
86
- }, /*#__PURE__*/React.createElement("div", {
87
- className: styles.thinkQuery
88
- }, item.query && /*#__PURE__*/React.createElement("div", {
89
- className: styles.label,
90
- style: {
91
- marginTop: 0
92
- }
93
- }, "\u5F00\u59CB\u5206\u6790\u95EE\u9898"), item.query && /*#__PURE__*/React.createElement("div", {
94
- className: styles.queryTitle
95
- }, item.query)), /*#__PURE__*/React.createElement("div", {
96
- className: styles.deepThink
97
- }, item.query && /*#__PURE__*/React.createElement("div", {
98
- className: styles.label
99
- }, "\u8FDB\u884C\u6DF1\u5EA6\u601D\u8003"), item.reasoningContent && /*#__PURE__*/React.createElement("div", {
100
- className: styles.deepThink_content
101
- }, /*#__PURE__*/React.createElement(MMarkdown, {
102
- content: processString(item.reasoningContent),
103
- isDeep: true,
104
- customRender: [{
105
- type: 'knowledge',
106
- component: KnowledgeIconGroup
107
- }],
108
- showLoading: item.reasoningLoading
109
- }))), item.msgLoading && /*#__PURE__*/React.createElement("div", {
110
- className: styles.answerLoading
111
- }, /*#__PURE__*/React.createElement(LottieImg, {
112
- name: "aiLoading",
113
- size: [20, 40]
114
- }))) : null);
75
+ return /*#__PURE__*/_jsxs("div", {
76
+ className: styles.container,
77
+ children: [/*#__PURE__*/_jsxs("div", {
78
+ className: styles.header,
79
+ onClick: handleClickExpand,
80
+ children: [/*#__PURE__*/_jsxs("div", {
81
+ className: styles.title,
82
+ children: ["GIMI", renderStatusText()]
83
+ }), item.expand ? /*#__PURE__*/_jsx(IconChevronUp, {}) : /*#__PURE__*/_jsx(IconChevronDown, {})]
84
+ }), item.expand ? /*#__PURE__*/_jsxs("div", {
85
+ className: styles.deeping,
86
+ ref: containerRef,
87
+ style: item.reasoningStatus === 1 ? {
88
+ maxHeight: 240
89
+ } : {},
90
+ children: [/*#__PURE__*/_jsxs("div", {
91
+ className: styles.thinkQuery,
92
+ children: [item.query && /*#__PURE__*/_jsx("div", {
93
+ className: styles.label,
94
+ style: {
95
+ marginTop: 0
96
+ },
97
+ children: "\u5F00\u59CB\u5206\u6790\u95EE\u9898"
98
+ }), item.query && /*#__PURE__*/_jsx("div", {
99
+ className: styles.queryTitle,
100
+ children: item.query
101
+ })]
102
+ }), /*#__PURE__*/_jsxs("div", {
103
+ className: styles.deepThink,
104
+ children: [item.query && /*#__PURE__*/_jsx("div", {
105
+ className: styles.label,
106
+ children: "\u8FDB\u884C\u6DF1\u5EA6\u601D\u8003"
107
+ }), item.reasoningContent && /*#__PURE__*/_jsx("div", {
108
+ className: styles.deepThink_content,
109
+ children: /*#__PURE__*/_jsx(MMarkdown, {
110
+ content: processString(item.reasoningContent),
111
+ isDeep: true,
112
+ customRender: [{
113
+ type: 'knowledge',
114
+ component: KnowledgeIconGroup
115
+ }],
116
+ showLoading: item.reasoningLoading
117
+ })
118
+ })]
119
+ }), item.msgLoading && /*#__PURE__*/_jsx("div", {
120
+ className: styles.answerLoading,
121
+ children: /*#__PURE__*/_jsx(LottieImg, {
122
+ name: "aiLoading",
123
+ size: [20, 40]
124
+ })
125
+ })]
126
+ }) : null]
127
+ });
115
128
  };
116
129
  export default ResoningContent;