@zohoim/client-sdk 1.0.0-poc76 → 1.0.0-poc79

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.
@@ -58,6 +58,10 @@ export default class Message {
58
58
  return type === MessageTypes.ATTACHMENT;
59
59
  }
60
60
 
61
+ static isAutoSent(systemMsgType) {
62
+ return !!systemMsgType;
63
+ }
64
+
61
65
  toJSON() {
62
66
  return { ...this.data
63
67
  };
@@ -1,3 +1,4 @@
1
+ import { AttachmentStatus } from "../../enum";
1
2
  const AttachmentSchema = {
2
3
  id: {
3
4
  type: 'string',
@@ -25,7 +26,8 @@ const AttachmentSchema = {
25
26
  },
26
27
  status: {
27
28
  type: 'string',
28
- required: false
29
+ required: false,
30
+ enum: Object.values(AttachmentStatus)
29
31
  }
30
32
  };
31
33
  export default AttachmentSchema;
@@ -14,7 +14,8 @@ export default class AttachmentAdapter extends IAdapter {
14
14
  type: attachmentData.type,
15
15
  createdTime: attachmentData.createdTime,
16
16
  size: attachmentData.size,
17
- url: attachmentData.url
17
+ url: attachmentData.url,
18
+ status: attachmentData.status
18
19
  }).toJSON();
19
20
  } catch (error) {
20
21
  throw new AdapterError(`Failed to adapt attachment: ${error.message}`);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@zohoim/client-sdk",
3
- "version": "1.0.0-poc76",
3
+ "version": "1.0.0-poc79",
4
4
  "description": "To have the client sdk for the IM",
5
5
  "main": "es/index.js",
6
6
  "module": "es/index.js",