bhd-components 0.11.17 → 0.11.18
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 +154 -153
- package/dist/index.esm.es5.development.js +17 -1
- 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/virtuosoList/index.js +14 -0
- package/es2017/AIMessageList/components/virtuosoList/index.module.less +1 -0
- package/esm/AIMessageList/components/virtuosoList/index.js +16 -0
- package/esm/AIMessageList/components/virtuosoList/index.module.less +1 -0
- package/package.json +1 -1
|
@@ -143,11 +143,18 @@ const VirtuosoList = /*#__PURE__*/ forwardRef((props, ref)=>{
|
|
|
143
143
|
return item;
|
|
144
144
|
});
|
|
145
145
|
});
|
|
146
|
+
recordRef.current.dataSource = recordRef.current.dataSource.map((item)=>{
|
|
147
|
+
if (item.id == id) {
|
|
148
|
+
return _object_spread({}, item, obj);
|
|
149
|
+
}
|
|
150
|
+
return item;
|
|
151
|
+
});
|
|
146
152
|
},
|
|
147
153
|
clearInputing () {
|
|
148
154
|
setDataSource((data)=>{
|
|
149
155
|
return data.filter((item)=>item.id !== "inputing");
|
|
150
156
|
});
|
|
157
|
+
recordRef.current.dataSource = recordRef.current.dataSource.filter((item)=>item.id !== "inputing");
|
|
151
158
|
},
|
|
152
159
|
recordMsg: (msg)=>{
|
|
153
160
|
onRecordMessage(msg);
|
|
@@ -164,9 +171,16 @@ const VirtuosoList = /*#__PURE__*/ forwardRef((props, ref)=>{
|
|
|
164
171
|
return item;
|
|
165
172
|
});
|
|
166
173
|
});
|
|
174
|
+
recordRef.current.dataSource = recordRef.current.dataSource.map((item)=>{
|
|
175
|
+
if (item.id == id) {
|
|
176
|
+
return _object_spread({}, item, obj);
|
|
177
|
+
}
|
|
178
|
+
return item;
|
|
179
|
+
});
|
|
167
180
|
},
|
|
168
181
|
changeDataSource: (data)=>{
|
|
169
182
|
setDataSource(data);
|
|
183
|
+
recordRef.current.dataSource = data;
|
|
170
184
|
},
|
|
171
185
|
scrollToBottom,
|
|
172
186
|
setSendingId: (id)=>{
|
|
@@ -149,6 +149,12 @@ var VirtuosoList = /*#__PURE__*/ forwardRef(function(props, ref) {
|
|
|
149
149
|
return item;
|
|
150
150
|
});
|
|
151
151
|
});
|
|
152
|
+
recordRef.current.dataSource = recordRef.current.dataSource.map(function(item) {
|
|
153
|
+
if (item.id == id) {
|
|
154
|
+
return _object_spread({}, item, obj);
|
|
155
|
+
}
|
|
156
|
+
return item;
|
|
157
|
+
});
|
|
152
158
|
},
|
|
153
159
|
clearInputing: function clearInputing() {
|
|
154
160
|
setDataSource(function(data) {
|
|
@@ -156,6 +162,9 @@ var VirtuosoList = /*#__PURE__*/ forwardRef(function(props, ref) {
|
|
|
156
162
|
return item.id !== "inputing";
|
|
157
163
|
});
|
|
158
164
|
});
|
|
165
|
+
recordRef.current.dataSource = recordRef.current.dataSource.filter(function(item) {
|
|
166
|
+
return item.id !== "inputing";
|
|
167
|
+
});
|
|
159
168
|
},
|
|
160
169
|
recordMsg: function(msg) {
|
|
161
170
|
onRecordMessage(msg);
|
|
@@ -172,9 +181,16 @@ var VirtuosoList = /*#__PURE__*/ forwardRef(function(props, ref) {
|
|
|
172
181
|
return item;
|
|
173
182
|
});
|
|
174
183
|
});
|
|
184
|
+
recordRef.current.dataSource = recordRef.current.dataSource.map(function(item) {
|
|
185
|
+
if (item.id == id) {
|
|
186
|
+
return _object_spread({}, item, obj);
|
|
187
|
+
}
|
|
188
|
+
return item;
|
|
189
|
+
});
|
|
175
190
|
},
|
|
176
191
|
changeDataSource: function(data) {
|
|
177
192
|
setDataSource(data);
|
|
193
|
+
recordRef.current.dataSource = data;
|
|
178
194
|
},
|
|
179
195
|
scrollToBottom: scrollToBottom,
|
|
180
196
|
setSendingId: function(id) {
|