@zero-library/chat-copilot 3.1.16 → 3.1.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.cjs.js CHANGED
@@ -159,10 +159,11 @@ var Attachments_default = React10.forwardRef(({ fileUpload, fileUploadConfig, fi
159
159
  const { data } = await fileUpload(formData, abortController.signal);
160
160
  const uploadedFile = data[0];
161
161
  let previewUrl = uploadedFile.id;
162
- if (uploadedFile.conversationId && uploadedFile.path) {
162
+ if (uploadedFile.workspaceId && uploadedFile.path) {
163
163
  previewUrl = chatStore.config.services.request.getPreviewUrl({
164
164
  path: uploadedFile.path,
165
- workspaceId: uploadedFile.conversationId
165
+ workspaceId: uploadedFile.workspaceId,
166
+ workspaceType: uploadedFile.workspaceType
166
167
  });
167
168
  }
168
169
  setAttachedFiles(
@@ -267,6 +268,15 @@ var index_module_default = {
267
268
  };
268
269
 
269
270
  // src/core/constants.ts
271
+ var WorkspaceTypeEnum = /* @__PURE__ */ ((WorkspaceTypeEnum2) => {
272
+ WorkspaceTypeEnum2["GLOBAL"] = "global";
273
+ WorkspaceTypeEnum2["SKILL"] = "skill";
274
+ WorkspaceTypeEnum2["CONVERSATION"] = "conversation";
275
+ WorkspaceTypeEnum2["KNOWLEDGE"] = "knowledge";
276
+ WorkspaceTypeEnum2["PROJECT"] = "project";
277
+ WorkspaceTypeEnum2["DEV_SKILL"] = "devSkill";
278
+ return WorkspaceTypeEnum2;
279
+ })(WorkspaceTypeEnum || {});
270
280
  var CONV_MODE = {
271
281
  PROD: 1};
272
282
  var TOKEN_KEY = "NS-TOKEN";
@@ -6701,6 +6711,7 @@ var layouts_default = React10.forwardRef(({ theme: theme5, params, hooks, layout
6701
6711
  exports.Attachments = Attachments_default;
6702
6712
  exports.ChatCopilot = layouts_default;
6703
6713
  exports.ChatSender = ChatSender_default;
6714
+ exports.WorkspaceTypeEnum = WorkspaceTypeEnum;
6704
6715
  exports.getFileIcon = getFileIcon;
6705
6716
  exports.getFileUrl = getFileUrl;
6706
6717
  //# sourceMappingURL=index.cjs.js.map