@zero-library/chat-agent 2.2.4 → 2.2.5

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.cjs.js CHANGED
@@ -914,7 +914,6 @@ function createChatStore() {
914
914
  conversation.messages[msg.conversationId].loading = true;
915
915
  messages[idx] = {
916
916
  ...messages[idx],
917
- params: messages[idx]?.params || msg.params,
918
917
  type: msg.type,
919
918
  tempContent: msg.msgContent
920
919
  };
@@ -926,7 +925,9 @@ function createChatStore() {
926
925
  conversation.messages[msg.conversationId].loading = true;
927
926
  messages[idx] = {
928
927
  ...messages[idx],
928
+ msgFiles: messages[idx]?.msgFiles?.length ? messages[idx].msgFiles : msg.msgFiles,
929
929
  params: messages[idx]?.params || msg.params,
930
+ quoteMsg: messages[idx]?.quoteMsg || msg.quoteMsg,
930
931
  type: msg.type,
931
932
  tempContent: "",
932
933
  msgContent: messages[idx].msgContent + (msg.msgContent || "")
@@ -960,12 +961,10 @@ function createChatStore() {
960
961
  if (idx === -1) return;
961
962
  messages[idx] = {
962
963
  ...messages[idx],
963
- params: messages[idx]?.params || msg.params,
964
964
  tempContent: msg.msgContent,
965
965
  type: void 0,
966
966
  // 报错后清空消息内容
967
- msgContent: "",
968
- citations: ""
967
+ msgContent: ""
969
968
  };
970
969
  conversation.messages[msg.conversationId].loading = false;
971
970
  };