@circle-vibe/shared 1.1.28 → 1.1.30

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.
Files changed (39) hide show
  1. package/build/index.js +1 -1
  2. package/build/src/components/layout/centered-vertical-layout/centered-vertical-layout.js +3 -3
  3. package/build/src/components/layout/centered-vertical-layout/centered-vertical-layout.js.map +1 -1
  4. package/build/src/components/layout/cluster-layout/cluster-layout.js +3 -3
  5. package/build/src/components/layout/cluster-layout/cluster-layout.js.map +1 -1
  6. package/build/src/components/layout/stack-layout/stack-layout.js +3 -3
  7. package/build/src/components/layout/stack-layout/stack-layout.js.map +1 -1
  8. package/build/src/constants/document-regex.d.ts +1 -0
  9. package/build/src/constants/document-regex.js +5 -0
  10. package/build/src/constants/document-regex.js.map +1 -0
  11. package/build/src/constants/index.d.ts +2 -0
  12. package/build/src/constants/index.js +2 -0
  13. package/build/src/constants/index.js.map +1 -1
  14. package/build/src/constants/ms-document.regex.d.ts +1 -0
  15. package/build/src/constants/ms-document.regex.js +5 -0
  16. package/build/src/constants/ms-document.regex.js.map +1 -0
  17. package/build/src/enums/chat-socket-keys.d.ts +3 -1
  18. package/build/src/enums/chat-socket-keys.js +2 -0
  19. package/build/src/enums/chat-socket-keys.js.map +1 -1
  20. package/build/src/enums/file-video-server-socket-keys.d.ts +8 -0
  21. package/build/src/enums/file-video-server-socket-keys.js +13 -0
  22. package/build/src/enums/file-video-server-socket-keys.js.map +1 -0
  23. package/build/src/enums/gateway-namespaces.d.ts +5 -0
  24. package/build/src/enums/gateway-namespaces.js +9 -0
  25. package/build/src/enums/gateway-namespaces.js.map +1 -0
  26. package/build/src/enums/index.d.ts +1 -0
  27. package/build/src/enums/index.js +1 -0
  28. package/build/src/enums/index.js.map +1 -1
  29. package/build/src/enums/message-file-type.d.ts +10 -1
  30. package/build/src/enums/message-file-type.js +17 -7
  31. package/build/src/enums/message-file-type.js.map +1 -1
  32. package/build/src/types/chat-socket-params.d.ts +34 -3
  33. package/build/src/types/file-vido-socket-params.d.ts +10 -0
  34. package/build/src/types/file-vido-socket-params.js +3 -0
  35. package/build/src/types/file-vido-socket-params.js.map +1 -0
  36. package/build/src/types/index.d.ts +1 -0
  37. package/build/src/types/index.js +1 -0
  38. package/build/src/types/index.js.map +1 -1
  39. package/package.json +1 -1
@@ -6,9 +6,9 @@ Object.defineProperty(exports, "__esModule", { value: true });
6
6
  exports.CenteredVertialLayout = void 0;
7
7
  const react_1 = __importDefault(require("react"));
8
8
  require("./centered-vertial-layout.scss");
9
- const CenteredVertialLayout = ({ space = 'initial', justifyContent = 'initial', children }) => (react_1.default.createElement("div", { className: "centered-vertical-layout", style: {
9
+ const CenteredVertialLayout = ({ space = 'initial', justifyContent = 'initial', children, ...rest }) => (react_1.default.createElement("div", { className: "centered-vertical-layout", style: {
10
10
  '--space': space,
11
- '--justify-content': justifyContent
12
- } }, children));
11
+ '--justify-content': justifyContent,
12
+ }, ...rest }, children));
13
13
  exports.CenteredVertialLayout = CenteredVertialLayout;
14
14
  //# sourceMappingURL=centered-vertical-layout.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"centered-vertical-layout.js","sourceRoot":"","sources":["../../../../../src/components/layout/centered-vertical-layout/centered-vertical-layout.tsx"],"names":[],"mappings":";;;;;;AAAA,kDAA0B;AAI1B,0CAAwC;AAOjC,MAAM,qBAAqB,GAAiE,CAAC,EAClG,KAAK,GAAG,SAAS,EACjB,cAAc,GAAG,SAAS,EAC1B,QAAQ,EACT,EAAE,EAAE,CAAC,CACJ,uCAAK,SAAS,EAAC,0BAA0B,EAAC,KAAK,EAAE;QAC/C,SAAS,EAAE,KAAK;QAChB,mBAAmB,EAAE,cAAc;KACd,IAAG,QAAQ,CAAO,CAC1C,CAAA;AATY,QAAA,qBAAqB,yBASjC"}
1
+ {"version":3,"file":"centered-vertical-layout.js","sourceRoot":"","sources":["../../../../../src/components/layout/centered-vertical-layout/centered-vertical-layout.tsx"],"names":[],"mappings":";;;;;;AAAA,kDAA0B;AAI1B,0CAAwC;AAOjC,MAAM,qBAAqB,GAAiE,CAAC,EAClG,KAAK,GAAG,SAAS,EACjB,cAAc,GAAG,SAAS,EAC1B,QAAQ,EACR,GAAG,IAAI,EACR,EAAE,EAAE,CAAC,CACJ,uCACE,SAAS,EAAC,0BAA0B,EACpC,KAAK,EACH;QACE,SAAS,EAAE,KAAK;QAChB,mBAAmB,EAAE,cAAc;KACd,KAErB,IAAI,IAEP,QAAQ,CACL,CACP,CAAC;AAlBW,QAAA,qBAAqB,yBAkBhC"}
@@ -6,10 +6,10 @@ Object.defineProperty(exports, "__esModule", { value: true });
6
6
  exports.ClusterLayout = void 0;
7
7
  const react_1 = __importDefault(require("react"));
8
8
  require("./cluster-layout.scss");
9
- const ClusterLayout = ({ children, alignItems = 'initial', justifyContent = 'initial', className, space = '1rem' }) => (react_1.default.createElement("div", { className: `cluster-layout ${className ?? ''}`, style: {
9
+ const ClusterLayout = ({ children, alignItems = 'initial', justifyContent = 'initial', className, space = '1rem', ...rest }) => (react_1.default.createElement("div", { className: `cluster-layout ${className ?? ''}`, style: {
10
10
  '--space': space,
11
11
  '--justify-content': justifyContent,
12
- '--align-items': alignItems
13
- } }, children));
12
+ '--align-items': alignItems,
13
+ }, ...rest }, children));
14
14
  exports.ClusterLayout = ClusterLayout;
15
15
  //# sourceMappingURL=cluster-layout.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"cluster-layout.js","sourceRoot":"","sources":["../../../../../src/components/layout/cluster-layout/cluster-layout.tsx"],"names":[],"mappings":";;;;;;AAAA,kDAA0B;AAI1B,iCAA+B;AASxB,MAAM,aAAa,GAAyD,CAAC,EAClF,QAAQ,EACR,UAAU,GAAG,SAAS,EACtB,cAAc,GAAG,SAAS,EAC1B,SAAS,EACT,KAAK,GAAG,MAAM,EACf,EAAE,EAAE,CAAC,CACJ,uCAAK,SAAS,EAAE,kBAAkB,SAAS,IAAI,EAAE,EAAE,EAAE,KAAK,EAAE;QAC1D,SAAS,EAAE,KAAK;QAChB,mBAAmB,EAAE,cAAc;QACnC,eAAe,EAAE,UAAU;KACN,IAAG,QAAQ,CAAO,CAC1C,CAAA;AAZY,QAAA,aAAa,iBAYzB"}
1
+ {"version":3,"file":"cluster-layout.js","sourceRoot":"","sources":["../../../../../src/components/layout/cluster-layout/cluster-layout.tsx"],"names":[],"mappings":";;;;;;AAAA,kDAA0B;AAI1B,iCAA+B;AASxB,MAAM,aAAa,GAAyD,CAAC,EAClF,QAAQ,EACR,UAAU,GAAG,SAAS,EACtB,cAAc,GAAG,SAAS,EAC1B,SAAS,EACT,KAAK,GAAG,MAAM,EACd,GAAG,IAAI,EACR,EAAE,EAAE,CAAC,CACJ,uCACE,SAAS,EAAE,kBAAkB,SAAS,IAAI,EAAE,EAAE,EAC9C,KAAK,EACH;QACE,SAAS,EAAE,KAAK;QAChB,mBAAmB,EAAE,cAAc;QACnC,eAAe,EAAE,UAAU;KACN,KAErB,IAAI,IAEP,QAAQ,CACL,CACP,CAAC;AArBW,QAAA,aAAa,iBAqBxB"}
@@ -6,10 +6,10 @@ Object.defineProperty(exports, "__esModule", { value: true });
6
6
  exports.StackLayout = void 0;
7
7
  const react_1 = __importDefault(require("react"));
8
8
  require("./stack-layout.scss");
9
- const StackLayout = ({ children, alignItems = 'initial', justifyContent = 'initial', className, space = '1rem' }) => (react_1.default.createElement("div", { className: `stack-layout ${className ?? ''}`, style: {
9
+ const StackLayout = ({ children, alignItems = 'initial', justifyContent = 'initial', className, space = '1rem', ...rest }) => (react_1.default.createElement("div", { className: `stack-layout ${className ?? ''}`, style: {
10
10
  '--space': space,
11
11
  '--justify-content': justifyContent,
12
- '--align-items': alignItems
13
- } }, children));
12
+ '--align-items': alignItems,
13
+ }, ...rest }, children));
14
14
  exports.StackLayout = StackLayout;
15
15
  //# sourceMappingURL=stack-layout.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"stack-layout.js","sourceRoot":"","sources":["../../../../../src/components/layout/stack-layout/stack-layout.tsx"],"names":[],"mappings":";;;;;;AAAA,kDAA0B;AAG1B,+BAA6B;AAStB,MAAM,WAAW,GAAuD,CAAC,EAC9E,QAAQ,EACR,UAAU,GAAG,SAAS,EACtB,cAAc,GAAG,SAAS,EAC1B,SAAS,EACT,KAAK,GAAG,MAAM,EACf,EAAE,EAAE,CAAC,CACJ,uCAAK,SAAS,EAAE,gBAAgB,SAAS,IAAI,EAAE,EAAE,EAAE,KAAK,EAAE;QACxD,SAAS,EAAE,KAAK;QAChB,mBAAmB,EAAE,cAAc;QACnC,eAAe,EAAE,UAAU;KACN,IAAG,QAAQ,CAAO,CAC1C,CAAA;AAZY,QAAA,WAAW,eAYvB"}
1
+ {"version":3,"file":"stack-layout.js","sourceRoot":"","sources":["../../../../../src/components/layout/stack-layout/stack-layout.tsx"],"names":[],"mappings":";;;;;;AAAA,kDAA0B;AAG1B,+BAA6B;AAStB,MAAM,WAAW,GAAuD,CAAC,EAC9E,QAAQ,EACR,UAAU,GAAG,SAAS,EACtB,cAAc,GAAG,SAAS,EAC1B,SAAS,EACT,KAAK,GAAG,MAAM,EACd,GAAG,IAAI,EACR,EAAE,EAAE,CAAC,CACJ,uCACE,SAAS,EAAE,gBAAgB,SAAS,IAAI,EAAE,EAAE,EAC5C,KAAK,EACH;QACE,SAAS,EAAE,KAAK;QAChB,mBAAmB,EAAE,cAAc;QACnC,eAAe,EAAE,UAAU;KACN,KAErB,IAAI,IAEP,QAAQ,CACL,CACP,CAAC;AArBW,QAAA,WAAW,eAqBtB"}
@@ -0,0 +1 @@
1
+ export declare const documentRegex: RegExp;
@@ -0,0 +1,5 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.documentRegex = void 0;
4
+ exports.documentRegex = /\.(pdf|odt|ods|odp|rtf|txt)$/i;
5
+ //# sourceMappingURL=document-regex.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"document-regex.js","sourceRoot":"","sources":["../../../src/constants/document-regex.ts"],"names":[],"mappings":";;;AAAa,QAAA,aAAa,GAAG,+BAA+B,CAAC"}
@@ -6,3 +6,5 @@ export * from './default-tooltip-animation';
6
6
  export * from './animation-in-bottom-position';
7
7
  export * from './country-codes';
8
8
  export * from './nationality-codes';
9
+ export * from './ms-document.regex';
10
+ export * from './document-regex';
@@ -22,4 +22,6 @@ __exportStar(require("./default-tooltip-animation"), exports);
22
22
  __exportStar(require("./animation-in-bottom-position"), exports);
23
23
  __exportStar(require("./country-codes"), exports);
24
24
  __exportStar(require("./nationality-codes"), exports);
25
+ __exportStar(require("./ms-document.regex"), exports);
26
+ __exportStar(require("./document-regex"), exports);
25
27
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/constants/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,mDAAiC;AACjC,yCAAuB;AACvB,+CAA6B;AAC7B,uDAAqC;AACrC,8DAA4C;AAC5C,iEAA+C;AAC/C,kDAAgC;AAChC,sDAAoC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/constants/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,mDAAiC;AACjC,yCAAuB;AACvB,+CAA6B;AAC7B,uDAAqC;AACrC,8DAA4C;AAC5C,iEAA+C;AAC/C,kDAAgC;AAChC,sDAAoC;AACpC,sDAAoC;AACpC,mDAAiC"}
@@ -0,0 +1 @@
1
+ export declare const msDocumnetRegex: RegExp;
@@ -0,0 +1,5 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.msDocumnetRegex = void 0;
4
+ exports.msDocumnetRegex = /\.(docx?|xlsx?|pptx?)$/i;
5
+ //# sourceMappingURL=ms-document.regex.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ms-document.regex.js","sourceRoot":"","sources":["../../../src/constants/ms-document.regex.ts"],"names":[],"mappings":";;;AAAa,QAAA,eAAe,GAAG,yBAAyB,CAAC"}
@@ -4,5 +4,7 @@ export declare enum ChatSocketCommand {
4
4
  REFRESH_CHATS = "refresh_chats",
5
5
  SEND_MESSAGE = "send_message",
6
6
  JOIN_CHAT = "join_chat",
7
- CREATE_CHAT = "create_chat"
7
+ CREATE_CHAT = "create_chat",
8
+ SEND_VIDEO_FILE_MESSAGE = "SEND_VIDEO_FILE_MESSAGE",
9
+ SEND_FILE_MESSAGE = "SEND_FILE_MESSAGE"
8
10
  }
@@ -9,5 +9,7 @@ var ChatSocketCommand;
9
9
  ChatSocketCommand["SEND_MESSAGE"] = "send_message";
10
10
  ChatSocketCommand["JOIN_CHAT"] = "join_chat";
11
11
  ChatSocketCommand["CREATE_CHAT"] = "create_chat";
12
+ ChatSocketCommand["SEND_VIDEO_FILE_MESSAGE"] = "SEND_VIDEO_FILE_MESSAGE";
13
+ ChatSocketCommand["SEND_FILE_MESSAGE"] = "SEND_FILE_MESSAGE";
12
14
  })(ChatSocketCommand = exports.ChatSocketCommand || (exports.ChatSocketCommand = {}));
13
15
  //# sourceMappingURL=chat-socket-keys.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"chat-socket-keys.js","sourceRoot":"","sources":["../../../src/enums/chat-socket-keys.ts"],"names":[],"mappings":";;;AAAA,IAAY,iBAOX;AAPD,WAAY,iBAAiB;IAC3B,0DAAqC,CAAA;IACrC,8CAAyB,CAAA;IACzB,oDAA+B,CAAA;IAC/B,kDAA6B,CAAA;IAC7B,4CAAuB,CAAA;IACvB,gDAA2B,CAAA;AAC7B,CAAC,EAPW,iBAAiB,GAAjB,yBAAiB,KAAjB,yBAAiB,QAO5B"}
1
+ {"version":3,"file":"chat-socket-keys.js","sourceRoot":"","sources":["../../../src/enums/chat-socket-keys.ts"],"names":[],"mappings":";;;AAAA,IAAY,iBASX;AATD,WAAY,iBAAiB;IAC3B,0DAAqC,CAAA;IACrC,8CAAyB,CAAA;IACzB,oDAA+B,CAAA;IAC/B,kDAA6B,CAAA;IAC7B,4CAAuB,CAAA;IACvB,gDAA2B,CAAA;IAC3B,wEAAmD,CAAA;IACnD,4DAAuC,CAAA;AACzC,CAAC,EATW,iBAAiB,GAAjB,yBAAiB,KAAjB,yBAAiB,QAS5B"}
@@ -0,0 +1,8 @@
1
+ export declare enum FileServerSocketKeys {
2
+ START_VIDEO_UPLOAD = "START_VIDEO_UPLOAD",
3
+ UPLOAD_VIDEO_STARTED = "UPLOAD_VIDEO_STARTED",
4
+ UPLOAD_VIDEO_ERROR = "UPLOAD_VIDEO_ERROR",
5
+ UPLOAD_VIDEO_END = "UPLOAD_VIDEO_END",
6
+ UPLOAD_VIDEO_SUCCESS = "UPLOAD_VIDEO_SUCCESS",
7
+ UPLOAD_VIDEO_CHUNK = "UPLOAD_VIDEO_CHUNK"
8
+ }
@@ -0,0 +1,13 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.FileServerSocketKeys = void 0;
4
+ var FileServerSocketKeys;
5
+ (function (FileServerSocketKeys) {
6
+ FileServerSocketKeys["START_VIDEO_UPLOAD"] = "START_VIDEO_UPLOAD";
7
+ FileServerSocketKeys["UPLOAD_VIDEO_STARTED"] = "UPLOAD_VIDEO_STARTED";
8
+ FileServerSocketKeys["UPLOAD_VIDEO_ERROR"] = "UPLOAD_VIDEO_ERROR";
9
+ FileServerSocketKeys["UPLOAD_VIDEO_END"] = "UPLOAD_VIDEO_END";
10
+ FileServerSocketKeys["UPLOAD_VIDEO_SUCCESS"] = "UPLOAD_VIDEO_SUCCESS";
11
+ FileServerSocketKeys["UPLOAD_VIDEO_CHUNK"] = "UPLOAD_VIDEO_CHUNK";
12
+ })(FileServerSocketKeys = exports.FileServerSocketKeys || (exports.FileServerSocketKeys = {}));
13
+ //# sourceMappingURL=file-video-server-socket-keys.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"file-video-server-socket-keys.js","sourceRoot":"","sources":["../../../src/enums/file-video-server-socket-keys.ts"],"names":[],"mappings":";;;AAAA,IAAY,oBAOX;AAPD,WAAY,oBAAoB;IAC9B,iEAAyC,CAAA;IACzC,qEAA6C,CAAA;IAC7C,iEAAyC,CAAA;IACzC,6DAAqC,CAAA;IACrC,qEAA6C,CAAA;IAC7C,iEAAyC,CAAA;AAC3C,CAAC,EAPW,oBAAoB,GAApB,4BAAoB,KAApB,4BAAoB,QAO/B"}
@@ -0,0 +1,5 @@
1
+ export declare const GatewayNamespaces: {
2
+ VIDEO_UPLOAD: string;
3
+ CHAT_MAIN: string;
4
+ FILE_SERVER: string;
5
+ };
@@ -0,0 +1,9 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.GatewayNamespaces = void 0;
4
+ exports.GatewayNamespaces = {
5
+ VIDEO_UPLOAD: 'video-upload',
6
+ CHAT_MAIN: 'chat-main',
7
+ FILE_SERVER: 'main-file'
8
+ };
9
+ //# sourceMappingURL=gateway-namespaces.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"gateway-namespaces.js","sourceRoot":"","sources":["../../../src/enums/gateway-namespaces.ts"],"names":[],"mappings":";;;AAAa,QAAA,iBAAiB,GAAG;IAC/B,YAAY,EAAE,cAAc;IAC5B,SAAS,EAAE,WAAW;IACtB,WAAW,EAAE,WAAW;CACzB,CAAA"}
@@ -11,3 +11,4 @@ export * from './user-chat-role';
11
11
  export * from './message-file-entity-type';
12
12
  export * from './sort-direction';
13
13
  export * from './user-chat-status';
14
+ export * from './gateway-namespaces';
@@ -27,4 +27,5 @@ __exportStar(require("./user-chat-role"), exports);
27
27
  __exportStar(require("./message-file-entity-type"), exports);
28
28
  __exportStar(require("./sort-direction"), exports);
29
29
  __exportStar(require("./user-chat-status"), exports);
30
+ __exportStar(require("./gateway-namespaces"), exports);
30
31
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/enums/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,sDAAoC;AACpC,8CAA4B;AAC5B,mDAAiC;AACjC,iDAA+B;AAC/B,8CAA4B;AAC5B,qDAAmC;AACnC,qDAAmC;AACnC,iDAA+B;AAC/B,8CAA4B;AAC5B,mDAAiC;AACjC,6DAA2C;AAC3C,mDAAiC;AACjC,qDAAmC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/enums/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,sDAAoC;AACpC,8CAA4B;AAC5B,mDAAiC;AACjC,iDAA+B;AAC/B,8CAA4B;AAC5B,qDAAmC;AACnC,qDAAmC;AACnC,iDAA+B;AAC/B,8CAA4B;AAC5B,mDAAiC;AACjC,6DAA2C;AAC3C,mDAAiC;AACjC,qDAAmC;AACnC,uDAAqC"}
@@ -1,4 +1,4 @@
1
- export declare enum MessageFileType {
1
+ export declare enum MessageFileTypeForBrowser {
2
2
  MP4 = "video/mp4",
3
3
  OGG = "video/ogg",
4
4
  WEBM = "video/webm",
@@ -6,3 +6,12 @@ export declare enum MessageFileType {
6
6
  DOCUMENT = "document",
7
7
  MS_DOCUMENT = "ms_document"
8
8
  }
9
+ export declare enum MessageFileType {
10
+ MP4 = "MP4",
11
+ OGG = "OGG",
12
+ WEBM = "WEBM",
13
+ AVI = "AVI",
14
+ IMAGE = "IMAGE",
15
+ DOCUMENT = "DOCUMENT",
16
+ MS_DOCUMENT = "MS_DOCUMENT"
17
+ }
@@ -1,13 +1,23 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.MessageFileType = void 0;
3
+ exports.MessageFileType = exports.MessageFileTypeForBrowser = void 0;
4
+ var MessageFileTypeForBrowser;
5
+ (function (MessageFileTypeForBrowser) {
6
+ MessageFileTypeForBrowser["MP4"] = "video/mp4";
7
+ MessageFileTypeForBrowser["OGG"] = "video/ogg";
8
+ MessageFileTypeForBrowser["WEBM"] = "video/webm";
9
+ MessageFileTypeForBrowser["AVI"] = "video/avi";
10
+ MessageFileTypeForBrowser["DOCUMENT"] = "document";
11
+ MessageFileTypeForBrowser["MS_DOCUMENT"] = "ms_document";
12
+ })(MessageFileTypeForBrowser = exports.MessageFileTypeForBrowser || (exports.MessageFileTypeForBrowser = {}));
4
13
  var MessageFileType;
5
14
  (function (MessageFileType) {
6
- MessageFileType["MP4"] = "video/mp4";
7
- MessageFileType["OGG"] = "video/ogg";
8
- MessageFileType["WEBM"] = "video/webm";
9
- MessageFileType["AVI"] = "video/avi";
10
- MessageFileType["DOCUMENT"] = "document";
11
- MessageFileType["MS_DOCUMENT"] = "ms_document";
15
+ MessageFileType["MP4"] = "MP4";
16
+ MessageFileType["OGG"] = "OGG";
17
+ MessageFileType["WEBM"] = "WEBM";
18
+ MessageFileType["AVI"] = "AVI";
19
+ MessageFileType["IMAGE"] = "IMAGE";
20
+ MessageFileType["DOCUMENT"] = "DOCUMENT";
21
+ MessageFileType["MS_DOCUMENT"] = "MS_DOCUMENT";
12
22
  })(MessageFileType = exports.MessageFileType || (exports.MessageFileType = {}));
13
23
  //# sourceMappingURL=message-file-type.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"message-file-type.js","sourceRoot":"","sources":["../../../src/enums/message-file-type.ts"],"names":[],"mappings":";;;AAAA,IAAY,eAOX;AAPD,WAAY,eAAe;IACzB,oCAAiB,CAAA;IACjB,oCAAiB,CAAA;IACjB,sCAAmB,CAAA;IACnB,oCAAiB,CAAA;IACjB,wCAAqB,CAAA;IACrB,8CAA2B,CAAA;AAC7B,CAAC,EAPW,eAAe,GAAf,uBAAe,KAAf,uBAAe,QAO1B"}
1
+ {"version":3,"file":"message-file-type.js","sourceRoot":"","sources":["../../../src/enums/message-file-type.ts"],"names":[],"mappings":";;;AAAA,IAAY,yBAOX;AAPD,WAAY,yBAAyB;IACnC,8CAAiB,CAAA;IACjB,8CAAiB,CAAA;IACjB,gDAAmB,CAAA;IACnB,8CAAiB,CAAA;IACjB,kDAAqB,CAAA;IACrB,wDAA2B,CAAA;AAC7B,CAAC,EAPW,yBAAyB,GAAzB,iCAAyB,KAAzB,iCAAyB,QAOpC;AAED,IAAY,eAQX;AARD,WAAY,eAAe;IACzB,8BAAW,CAAA;IACX,8BAAW,CAAA;IACX,gCAAa,CAAA;IACb,8BAAW,CAAA;IACX,kCAAe,CAAA;IACf,wCAAqB,CAAA;IACrB,8CAA2B,CAAA;AAC7B,CAAC,EARW,eAAe,GAAf,uBAAe,KAAf,uBAAe,QAQ1B"}
@@ -1,5 +1,4 @@
1
- import { ChatType } from 'src/enums';
2
- import { Message } from 'src/models';
1
+ import { ChatType, MessageFileEntityType, MessageFileType, MessageType } from 'src/enums';
3
2
  export interface RefreshChatsSocketParams {
4
3
  chatId: number;
5
4
  cursor?: number;
@@ -18,7 +17,39 @@ export type CreateChatSocketParams = {
18
17
  type: ChatType;
19
18
  usersLimit?: number;
20
19
  };
20
+ export interface SendMessageChatSocketParams {
21
+ content: string;
22
+ chatId: number;
23
+ senderId: number;
24
+ threadId: number | null;
25
+ hidden: boolean;
26
+ messageType: MessageType;
27
+ }
28
+ export interface SendFileMessagePartChatSocketParams {
29
+ content: string;
30
+ chatId: number;
31
+ senderId: number;
32
+ threadId: number | null;
33
+ hidden: boolean;
34
+ messageType: MessageType;
35
+ fileMeta: SendFileMessageMetaInput;
36
+ }
37
+ export interface SendFileMessageChatSocketParams {
38
+ message: SendFileMessagePartChatSocketParams;
39
+ file: File;
40
+ }
21
41
  export interface SendMessageSocketParams {
42
+ content: string;
22
43
  chatId: number;
23
- message: Message;
44
+ senderId: number;
45
+ threadId?: number;
46
+ hidden: boolean;
47
+ messageType: MessageType;
48
+ }
49
+ export interface SendFileMessageMetaInput {
50
+ fileName: string;
51
+ description?: string;
52
+ type: MessageFileType;
53
+ fileType: string;
54
+ entityType: MessageFileEntityType;
24
55
  }
@@ -0,0 +1,10 @@
1
+ export interface FileVideoSocketConnectionAuthParams {
2
+ token: string;
3
+ }
4
+ export interface FileVideoSocketStartUploadParams {
5
+ fileName: string;
6
+ }
7
+ export type FileVideoSocketErrorOutput = string;
8
+ export interface FileVideoSocketSuccessOutput {
9
+ filePath: string;
10
+ }
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ //# sourceMappingURL=file-vido-socket-params.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"file-vido-socket-params.js","sourceRoot":"","sources":["../../../src/types/file-vido-socket-params.ts"],"names":[],"mappings":""}
@@ -1,3 +1,4 @@
1
1
  export * from './custom-css-variables';
2
2
  export * from './extended-react-functional-component';
3
3
  export * from './chat-socket-params';
4
+ export * from './file-vido-socket-params';
@@ -17,4 +17,5 @@ Object.defineProperty(exports, "__esModule", { value: true });
17
17
  __exportStar(require("./custom-css-variables"), exports);
18
18
  __exportStar(require("./extended-react-functional-component"), exports);
19
19
  __exportStar(require("./chat-socket-params"), exports);
20
+ __exportStar(require("./file-vido-socket-params"), exports);
20
21
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/types/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,yDAAuC;AACvC,wEAAsD;AACtD,uDAAqC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/types/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,yDAAuC;AACvC,wEAAsD;AACtD,uDAAqC;AACrC,4DAA0C"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@circle-vibe/shared",
3
- "version": "1.1.28",
3
+ "version": "1.1.30",
4
4
  "types": "./build/index.d.ts",
5
5
  "description": "Shared componenets, utils, hooks",
6
6
  "scripts": {