@ray-js/t-agent-ui-ray 0.1.0-beta-13 → 0.1.0-beta-15
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.
|
@@ -10,6 +10,12 @@ interface Props {
|
|
|
10
10
|
assistant?: 'start' | 'end' | string;
|
|
11
11
|
[key: string]: 'start' | 'end' | string;
|
|
12
12
|
};
|
|
13
|
+
historyLimit?: {
|
|
14
|
+
/** 历史消息数量限制 */
|
|
15
|
+
count: number;
|
|
16
|
+
/** 超过限制时显示的提示文本 */
|
|
17
|
+
tipText: string;
|
|
18
|
+
};
|
|
13
19
|
}
|
|
14
20
|
export default function MessageList(props: Props): React.JSX.Element;
|
|
15
21
|
export {};
|
|
@@ -19,7 +19,8 @@ export default function MessageList(props) {
|
|
|
19
19
|
roleSide,
|
|
20
20
|
style,
|
|
21
21
|
wrapperClassName,
|
|
22
|
-
wrapperStyle
|
|
22
|
+
wrapperStyle,
|
|
23
|
+
historyLimit
|
|
23
24
|
} = props;
|
|
24
25
|
const {
|
|
25
26
|
messages
|
|
@@ -107,7 +108,9 @@ export default function MessageList(props) {
|
|
|
107
108
|
isLatestMessage: index === 0,
|
|
108
109
|
side: side
|
|
109
110
|
});
|
|
110
|
-
}), /*#__PURE__*/React.createElement(View, {
|
|
111
|
+
}), historyLimit && historyLimit.count < reversed.length && /*#__PURE__*/React.createElement(View, {
|
|
112
|
+
className: "t-agent-message-list-history-tip"
|
|
113
|
+
}, historyLimit.tipText), /*#__PURE__*/React.createElement(View, {
|
|
111
114
|
className: "t-agent-message-list-padding-start"
|
|
112
115
|
})));
|
|
113
116
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ray-js/t-agent-ui-ray",
|
|
3
|
-
"version": "0.1.0-beta-
|
|
3
|
+
"version": "0.1.0-beta-15",
|
|
4
4
|
"author": "Tuya.inc",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"private": false,
|
|
@@ -41,5 +41,5 @@
|
|
|
41
41
|
"@types/echarts": "^4.9.22",
|
|
42
42
|
"@types/markdown-it": "^14.1.1"
|
|
43
43
|
},
|
|
44
|
-
"gitHead": "
|
|
44
|
+
"gitHead": "ac02ec83e8c37e48ff1e192e2aa8fcf0a82f1029"
|
|
45
45
|
}
|