bhd-components 0.11.21 → 0.11.23
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/dist/index.esm.es5.development.css +158 -158
- package/dist/index.esm.es5.development.js +3 -2
- package/dist/index.esm.es5.production.css +1 -1
- package/dist/index.esm.es5.production.js +1 -1
- package/dist/vendor.esm.es5.development.js +1 -1
- package/dist/vendor.esm.es5.production.js +1 -1
- package/es2017/AIMessageList/components/footer/index.js +2 -1
- package/es2017/AIMessageList/components/virtuosoList/index.module.less +22 -19
- package/es2017/AIMessageList/type.d.ts +2 -0
- package/esm/AIMessageList/components/footer/index.js +2 -1
- package/esm/AIMessageList/components/virtuosoList/index.module.less +22 -19
- package/esm/AIMessageList/type.d.ts +2 -0
- package/package.json +1 -1
|
@@ -29,7 +29,7 @@ const defaultFileUploadProps = {
|
|
|
29
29
|
};
|
|
30
30
|
const Footer = /*#__PURE__*/ forwardRef((props, ref)=>{
|
|
31
31
|
let { footerConfig, prefix, errorCallback, apiRef } = props;
|
|
32
|
-
let { placeholder = defaultProps.placeholder, className = defaultProps.className, maxLength = defaultProps.maxLength, renderAction, fileUpload, sendMsgAjaxParams, onClickStop = ()=>{}, conversionContent = (str)=>str, renderTopContent, inputingText = "正在输入...", canStopMessage = true, speed = 0, textAreaProps = {} } = footerConfig;
|
|
32
|
+
let { placeholder = defaultProps.placeholder, className = defaultProps.className, maxLength = defaultProps.maxLength, renderAction, fileUpload, sendMsgAjaxParams, onClickStop = ()=>{}, conversionContent = (str)=>str, renderTopContent, inputingText = "正在输入...", canStopMessage = true, speed = 0, textAreaProps = {}, onChange = ()=>{} } = footerConfig;
|
|
33
33
|
if (speed < 0) {
|
|
34
34
|
speed = 0;
|
|
35
35
|
}
|
|
@@ -126,6 +126,7 @@ const Footer = /*#__PURE__*/ forwardRef((props, ref)=>{
|
|
|
126
126
|
recordRef.current.sending = sending;
|
|
127
127
|
recordRef.current.fileCanSending = fileCanSending;
|
|
128
128
|
apiRef.contentApi && apiRef.contentApi.setIsSending(sending);
|
|
129
|
+
onChange();
|
|
129
130
|
}, [
|
|
130
131
|
textValue,
|
|
131
132
|
referencesSource,
|
|
@@ -363,26 +363,14 @@
|
|
|
363
363
|
.msgItem-text-aibody{
|
|
364
364
|
color: #1f2a28;
|
|
365
365
|
.msgItem-richText{
|
|
366
|
-
font-size: 13.5px;
|
|
367
|
-
line-height: 1.88;
|
|
368
|
-
color: #1f2a28;
|
|
369
|
-
white-space: normal;
|
|
370
|
-
word-break: break-all;
|
|
371
366
|
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
margin-top: 10px;
|
|
380
|
-
margin-bottom: 0;
|
|
381
|
-
}
|
|
382
|
-
& > *:first-child {
|
|
383
|
-
margin-top: 0;
|
|
384
|
-
}
|
|
385
|
-
:global {
|
|
367
|
+
font-size: 13.5px;
|
|
368
|
+
line-height: 1.88;
|
|
369
|
+
color: #1f2a28;
|
|
370
|
+
white-space: normal;
|
|
371
|
+
word-break: break-all;
|
|
372
|
+
|
|
373
|
+
:global {
|
|
386
374
|
--primary: #69c89e;
|
|
387
375
|
--primary-light: #eef8f3;
|
|
388
376
|
--primary-deep: #48b385;
|
|
@@ -597,6 +585,21 @@
|
|
|
597
585
|
}
|
|
598
586
|
/* 操作按钮组:固定在内容末尾,与上方内容保持明显间距 */
|
|
599
587
|
}
|
|
588
|
+
|
|
589
|
+
/*
|
|
590
|
+
* AI 内容排版系统
|
|
591
|
+
* 规则:所有间距只用 margin-top,margin-bottom 统一为 0
|
|
592
|
+
* 层级:H2(22px) > H3(16px) > 段落/列表(10px) > 紧跟标签后内容(5px)
|
|
593
|
+
*/
|
|
594
|
+
/* 统一重置:所有直接子元素默认上间距 10px,无下间距 */
|
|
595
|
+
& > * {
|
|
596
|
+
margin-top: 10px;
|
|
597
|
+
margin-bottom: 0;
|
|
598
|
+
}
|
|
599
|
+
& > *:first-child {
|
|
600
|
+
margin-top: 0;
|
|
601
|
+
}
|
|
602
|
+
|
|
600
603
|
}
|
|
601
604
|
|
|
602
605
|
}
|
|
@@ -122,6 +122,8 @@ export interface footerConfigProps {
|
|
|
122
122
|
inputingText?: string;
|
|
123
123
|
canStopMessage?: boolean;//是否允许停止消息 默认为true
|
|
124
124
|
speed?:number;// 控制文字每次输出的速度 默认为0 即不控制
|
|
125
|
+
textAreaProps:any;
|
|
126
|
+
onChange:()=>void;//底部数据变更 内容 文件上传等
|
|
125
127
|
}
|
|
126
128
|
|
|
127
129
|
export interface onOpenProps {
|
|
@@ -33,7 +33,7 @@ var Footer = /*#__PURE__*/ forwardRef(function(props, ref) {
|
|
|
33
33
|
var footerConfig = props.footerConfig, prefix = props.prefix, errorCallback = props.errorCallback, apiRef = props.apiRef;
|
|
34
34
|
var _footerConfig_placeholder = footerConfig.placeholder, placeholder = _footerConfig_placeholder === void 0 ? defaultProps.placeholder : _footerConfig_placeholder, _footerConfig_className = footerConfig.className, className = _footerConfig_className === void 0 ? defaultProps.className : _footerConfig_className, _footerConfig_maxLength = footerConfig.maxLength, maxLength = _footerConfig_maxLength === void 0 ? defaultProps.maxLength : _footerConfig_maxLength, renderAction = footerConfig.renderAction, fileUpload = footerConfig.fileUpload, sendMsgAjaxParams = footerConfig.sendMsgAjaxParams, _footerConfig_onClickStop = footerConfig.onClickStop, onClickStop = _footerConfig_onClickStop === void 0 ? function() {} : _footerConfig_onClickStop, _footerConfig_conversionContent = footerConfig.conversionContent, conversionContent = _footerConfig_conversionContent === void 0 ? function(str) {
|
|
35
35
|
return str;
|
|
36
|
-
} : _footerConfig_conversionContent, renderTopContent = footerConfig.renderTopContent, _footerConfig_inputingText = footerConfig.inputingText, inputingText = _footerConfig_inputingText === void 0 ? "正在输入..." : _footerConfig_inputingText, _footerConfig_canStopMessage = footerConfig.canStopMessage, canStopMessage = _footerConfig_canStopMessage === void 0 ? true : _footerConfig_canStopMessage, _footerConfig_speed = footerConfig.speed, speed = _footerConfig_speed === void 0 ? 0 : _footerConfig_speed, _footerConfig_textAreaProps = footerConfig.textAreaProps, textAreaProps = _footerConfig_textAreaProps === void 0 ? {} : _footerConfig_textAreaProps;
|
|
36
|
+
} : _footerConfig_conversionContent, renderTopContent = footerConfig.renderTopContent, _footerConfig_inputingText = footerConfig.inputingText, inputingText = _footerConfig_inputingText === void 0 ? "正在输入..." : _footerConfig_inputingText, _footerConfig_canStopMessage = footerConfig.canStopMessage, canStopMessage = _footerConfig_canStopMessage === void 0 ? true : _footerConfig_canStopMessage, _footerConfig_speed = footerConfig.speed, speed = _footerConfig_speed === void 0 ? 0 : _footerConfig_speed, _footerConfig_textAreaProps = footerConfig.textAreaProps, textAreaProps = _footerConfig_textAreaProps === void 0 ? {} : _footerConfig_textAreaProps, _footerConfig_onChange = footerConfig.onChange, onChange = _footerConfig_onChange === void 0 ? function() {} : _footerConfig_onChange;
|
|
37
37
|
if (speed < 0) {
|
|
38
38
|
speed = 0;
|
|
39
39
|
}
|
|
@@ -130,6 +130,7 @@ var Footer = /*#__PURE__*/ forwardRef(function(props, ref) {
|
|
|
130
130
|
recordRef.current.sending = sending;
|
|
131
131
|
recordRef.current.fileCanSending = fileCanSending;
|
|
132
132
|
apiRef.contentApi && apiRef.contentApi.setIsSending(sending);
|
|
133
|
+
onChange();
|
|
133
134
|
}, [
|
|
134
135
|
textValue,
|
|
135
136
|
referencesSource,
|
|
@@ -363,26 +363,14 @@
|
|
|
363
363
|
.msgItem-text-aibody{
|
|
364
364
|
color: #1f2a28;
|
|
365
365
|
.msgItem-richText{
|
|
366
|
-
font-size: 13.5px;
|
|
367
|
-
line-height: 1.88;
|
|
368
|
-
color: #1f2a28;
|
|
369
|
-
white-space: normal;
|
|
370
|
-
word-break: break-all;
|
|
371
366
|
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
margin-top: 10px;
|
|
380
|
-
margin-bottom: 0;
|
|
381
|
-
}
|
|
382
|
-
& > *:first-child {
|
|
383
|
-
margin-top: 0;
|
|
384
|
-
}
|
|
385
|
-
:global {
|
|
367
|
+
font-size: 13.5px;
|
|
368
|
+
line-height: 1.88;
|
|
369
|
+
color: #1f2a28;
|
|
370
|
+
white-space: normal;
|
|
371
|
+
word-break: break-all;
|
|
372
|
+
|
|
373
|
+
:global {
|
|
386
374
|
--primary: #69c89e;
|
|
387
375
|
--primary-light: #eef8f3;
|
|
388
376
|
--primary-deep: #48b385;
|
|
@@ -597,6 +585,21 @@
|
|
|
597
585
|
}
|
|
598
586
|
/* 操作按钮组:固定在内容末尾,与上方内容保持明显间距 */
|
|
599
587
|
}
|
|
588
|
+
|
|
589
|
+
/*
|
|
590
|
+
* AI 内容排版系统
|
|
591
|
+
* 规则:所有间距只用 margin-top,margin-bottom 统一为 0
|
|
592
|
+
* 层级:H2(22px) > H3(16px) > 段落/列表(10px) > 紧跟标签后内容(5px)
|
|
593
|
+
*/
|
|
594
|
+
/* 统一重置:所有直接子元素默认上间距 10px,无下间距 */
|
|
595
|
+
& > * {
|
|
596
|
+
margin-top: 10px;
|
|
597
|
+
margin-bottom: 0;
|
|
598
|
+
}
|
|
599
|
+
& > *:first-child {
|
|
600
|
+
margin-top: 0;
|
|
601
|
+
}
|
|
602
|
+
|
|
600
603
|
}
|
|
601
604
|
|
|
602
605
|
}
|
|
@@ -122,6 +122,8 @@ export interface footerConfigProps {
|
|
|
122
122
|
inputingText?: string;
|
|
123
123
|
canStopMessage?: boolean;//是否允许停止消息 默认为true
|
|
124
124
|
speed?:number;// 控制文字每次输出的速度 默认为0 即不控制
|
|
125
|
+
textAreaProps:any;
|
|
126
|
+
onChange:()=>void;//底部数据变更 内容 文件上传等
|
|
125
127
|
}
|
|
126
128
|
|
|
127
129
|
export interface onOpenProps {
|