quickblox-react-ui-kit 0.5.1-join-dialog-off.5 → 0.5.2-alpha.1

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 (182) hide show
  1. package/.claude/settings.local.json +14 -0
  2. package/dist/CommonTypes/BaseViewModel.d.ts +0 -2
  3. package/dist/CommonTypes/BaseViewModel.d.ts.map +1 -1
  4. package/dist/Data/mapper/DialogLocalDTOMapper.d.ts.map +1 -1
  5. package/dist/Data/mapper/DialogRemoteDTOMapper.d.ts.map +1 -1
  6. package/dist/Data/repository/ConnectionRepository.d.ts.map +1 -1
  7. package/dist/Data/repository/DialogsRepository.d.ts +0 -4
  8. package/dist/Data/repository/DialogsRepository.d.ts.map +1 -1
  9. package/dist/Data/source/remote/IRemoteDataSource.d.ts +0 -4
  10. package/dist/Data/source/remote/IRemoteDataSource.d.ts.map +1 -1
  11. package/dist/Data/source/remote/Mapper/MessageDTOMapper.d.ts +1 -0
  12. package/dist/Data/source/remote/Mapper/MessageDTOMapper.d.ts.map +1 -1
  13. package/dist/Data/source/remote/RemoteDataSource.d.ts +0 -4
  14. package/dist/Data/source/remote/RemoteDataSource.d.ts.map +1 -1
  15. package/dist/Domain/entity/ChatMessageAttachmentEntity.d.ts +2 -2
  16. package/dist/Domain/entity/ChatMessageAttachmentEntity.d.ts.map +1 -1
  17. package/dist/Domain/entity/FileEntity.d.ts +2 -2
  18. package/dist/Domain/entity/FileEntity.d.ts.map +1 -1
  19. package/dist/Domain/entity/GroupDialogEntity.d.ts +1 -1
  20. package/dist/Domain/entity/GroupDialogEntity.d.ts.map +1 -1
  21. package/dist/Domain/repository/IDialogsRepository.d.ts +0 -4
  22. package/dist/Domain/repository/IDialogsRepository.d.ts.map +1 -1
  23. package/dist/Domain/use_cases/SyncDialogsUseCase.d.ts.map +1 -1
  24. package/dist/Domain/use_cases/UserTypingMessageUseCase.d.ts.map +1 -1
  25. package/dist/Presentation/Views/Dialog/Message/MessageAttachment/AudioAttachment/AudioAttachment.d.ts.map +1 -1
  26. package/dist/Presentation/Views/DialogInfo/DialogInfo.d.ts.map +1 -1
  27. package/dist/Presentation/Views/DialogList/DialogListViewModel.d.ts +1 -5
  28. package/dist/Presentation/Views/DialogList/DialogListViewModel.d.ts.map +1 -1
  29. package/dist/Presentation/Views/DialogList/useDialogListViewModel.d.ts.map +1 -1
  30. package/dist/Presentation/Views/EditDialog/EditDialog.d.ts +0 -5
  31. package/dist/Presentation/Views/EditDialog/EditDialog.d.ts.map +1 -1
  32. package/dist/Presentation/Views/Flow/CreateDialogFlow/CreateNewDialogFlow.d.ts.map +1 -1
  33. package/dist/Presentation/ui-components/MessageInput/VoiceRecordingProgress/VoiceRecordingProgress.d.ts.map +1 -1
  34. package/dist/index-ui.js +43513 -59614
  35. package/dist/qb-api-calls/index.d.ts +0 -1
  36. package/dist/qb-api-calls/index.d.ts.map +1 -1
  37. package/package.json +14 -8
  38. package/src/CommonTypes/BaseViewModel.ts +0 -4
  39. package/src/Data/DefaultConfigurations.ts +4 -4
  40. package/src/Data/mapper/DialogLocalDTOMapper.ts +9 -10
  41. package/src/Data/mapper/DialogRemoteDTOMapper.ts +9 -10
  42. package/src/Data/repository/ConnectionRepository.ts +3 -2
  43. package/src/Data/repository/DialogsRepository.ts +0 -85
  44. package/src/Data/source/remote/IRemoteDataSource.ts +0 -12
  45. package/src/Data/source/remote/Mapper/MessageDTOMapper.ts +39 -22
  46. package/src/Data/source/remote/RemoteDataSource.ts +65 -246
  47. package/src/Domain/entity/ChatMessageAttachmentEntity.ts +2 -2
  48. package/src/Domain/entity/FileEntity.ts +2 -2
  49. package/src/Domain/entity/GroupDialogEntity.ts +1 -1
  50. package/src/Domain/repository/IDialogsRepository.ts +0 -12
  51. package/src/Domain/use_cases/SyncDialogsUseCase.ts +3 -3
  52. package/src/Domain/use_cases/UserTypingMessageUseCase.ts +4 -2
  53. package/src/Presentation/Views/Dialog/Message/MessageAttachment/AudioAttachment/AudioAttachment.tsx +4 -9
  54. package/src/Presentation/Views/DialogInfo/DialogInfo.tsx +4 -39
  55. package/src/Presentation/Views/DialogList/DialogListViewModel.ts +1 -5
  56. package/src/Presentation/Views/DialogList/useDialogListViewModel.ts +0 -147
  57. package/src/Presentation/Views/EditDialog/EditDialog.scss +2 -21
  58. package/src/Presentation/Views/EditDialog/EditDialog.tsx +1 -47
  59. package/src/Presentation/Views/Flow/CreateDialogFlow/CreateNewDialogFlow.tsx +13 -49
  60. package/src/Presentation/layouts/Desktop/QuickBloxUIKitDesktopLayout.tsx +2 -2
  61. package/src/Presentation/ui-components/Message/Bubble/AttachmentBubble/AttachmentBubble.tsx +2 -2
  62. package/src/Presentation/ui-components/MessageInput/ReplyMessagePreview/ReplyImagePreviewAttachment/ReplyImagePreviewAttachment.tsx +2 -2
  63. package/src/Presentation/ui-components/MessageInput/VoiceRecordingProgress/VoiceRecordingProgress.tsx +24 -8
  64. package/src/QBconfig.ts +4 -4
  65. package/src/qb-api-calls/index.ts +2 -59
  66. package/storybook-static/161.77e7dbc5.iframe.bundle.js +2 -0
  67. package/storybook-static/217.cb8da73c.iframe.bundle.js +408 -0
  68. package/storybook-static/217.cb8da73c.iframe.bundle.js.map +1 -0
  69. package/storybook-static/263.f039edee.iframe.bundle.js +2 -0
  70. package/storybook-static/294.7ed84cb5.iframe.bundle.js +1 -0
  71. package/storybook-static/338.ed5286bb.iframe.bundle.js +2 -0
  72. package/storybook-static/363.fe646024.iframe.bundle.js +2 -0
  73. package/storybook-static/{363.64281ecc.iframe.bundle.js.LICENSE.txt → 363.fe646024.iframe.bundle.js.LICENSE.txt} +0 -7
  74. package/storybook-static/364.fb3fc9b4.iframe.bundle.js +1 -0
  75. package/storybook-static/488.a47f0de8.iframe.bundle.js +1 -0
  76. package/storybook-static/559.fdf11e08.iframe.bundle.js +2 -0
  77. package/storybook-static/618.ab5566c8.iframe.bundle.js +1 -0
  78. package/storybook-static/844.5804474b.iframe.bundle.js +95 -0
  79. package/storybook-static/844.5804474b.iframe.bundle.js.map +1 -0
  80. package/storybook-static/936.ba75ae44.iframe.bundle.js +1 -0
  81. package/storybook-static/Presentation-ui-components-Avatar-avatar-stories.6977856e.iframe.bundle.js +2 -0
  82. package/storybook-static/Presentation-ui-components-Badge-Badge-stories.d77c6500.iframe.bundle.js +2 -0
  83. package/storybook-static/Presentation-ui-components-Button-Button-stories.05f2f5b7.iframe.bundle.js +2 -0
  84. package/storybook-static/Presentation-ui-components-DialogBanner-DialogBanner-stories.118df514.iframe.bundle.js +1 -0
  85. package/storybook-static/Presentation-ui-components-DialogItemPreview-DialogItemPreview-stories.e9d3dc6b.iframe.bundle.js +2 -0
  86. package/storybook-static/Presentation-ui-components-DialogWindow-DialogWindow-stories.7d74bffa.iframe.bundle.js +2 -0
  87. package/storybook-static/Presentation-ui-components-Dropdown-Dropdown-stories.d92e6904.iframe.bundle.js +2 -0
  88. package/storybook-static/Presentation-ui-components-Header-Header-stories.b9a00187.iframe.bundle.js +2 -0
  89. package/storybook-static/Presentation-ui-components-Loader-Loader-stories.f484b131.iframe.bundle.js +2 -0
  90. package/storybook-static/Presentation-ui-components-Message-Message-stories.66867b7e.iframe.bundle.js +2 -0
  91. package/storybook-static/Presentation-ui-components-MessageInput-MessageInput-stories.d72f098b.iframe.bundle.js +1 -0
  92. package/storybook-static/Presentation-ui-components-MessageSeparator-MessageSeparator-stories.7d9e0991.iframe.bundle.js +1 -0
  93. package/storybook-static/Presentation-ui-components-Placeholder-Placeholder-stories.1e6bd1cd.iframe.bundle.js +2 -0
  94. package/storybook-static/Presentation-ui-components-PreviewFileMessage-PreviewFileMessage-stories.44c68c03.iframe.bundle.js +2 -0
  95. package/storybook-static/Presentation-ui-components-SettingsItem-SettingsItem-stories.3e87329b.iframe.bundle.js +2 -0
  96. package/storybook-static/Presentation-ui-components-TextField-TextField-stories.ec3e7d5f.iframe.bundle.js +2 -0
  97. package/storybook-static/Presentation-ui-components-Toast-Toast-stories.2721621c.iframe.bundle.js +1 -0
  98. package/storybook-static/Presentation-ui-components-UserListItem-UserListItem-stories.33b23eab.iframe.bundle.js +2 -0
  99. package/storybook-static/docs-Introduction-mdx.416f8bf9.iframe.bundle.js +1 -0
  100. package/storybook-static/docs-Styling-mdx.c119b271.iframe.bundle.js +1 -0
  101. package/storybook-static/iframe.html +5 -3
  102. package/storybook-static/main.bfaba8e3.iframe.bundle.js +1 -0
  103. package/storybook-static/project.json +1 -1
  104. package/storybook-static/runtime~main.b1ec3380.iframe.bundle.js +1 -0
  105. package/storybook-static/sb-addons/chromatic-com-storybook-10/manager-bundle.js +27 -27
  106. package/storybook-static/sb-addons/essentials-actions-3/manager-bundle.js +1 -1
  107. package/storybook-static/sb-addons/essentials-backgrounds-5/manager-bundle.js +1 -1
  108. package/storybook-static/sb-addons/essentials-controls-2/manager-bundle.js +74 -71
  109. package/storybook-static/sb-addons/essentials-docs-4/manager-bundle.js +73 -70
  110. package/storybook-static/sb-addons/essentials-viewport-6/manager-bundle.js +1 -1
  111. package/storybook-static/sb-addons/interactions-11/manager-bundle.js +6 -6
  112. package/storybook-static/sb-addons/onboarding-1/manager-bundle.js +18 -18
  113. package/storybook-static/sb-manager/globals-runtime.js +10691 -11043
  114. package/storybook-static/sb-preview/runtime.js +238 -238
  115. package/dist/Domain/use_cases/CreateDialogSetUpAutoJoinUseCase.d.ts +0 -14
  116. package/dist/Domain/use_cases/CreateDialogSetUpAutoJoinUseCase.d.ts.map +0 -1
  117. package/dist/Domain/use_cases/CreateDialogWithAutoJoinUseCase.d.ts +0 -14
  118. package/dist/Domain/use_cases/CreateDialogWithAutoJoinUseCase.d.ts.map +0 -1
  119. package/dist/Domain/use_cases/JoinFromTheDialogUseCase.d.ts +0 -12
  120. package/dist/Domain/use_cases/JoinFromTheDialogUseCase.d.ts.map +0 -1
  121. package/dist/Domain/use_cases/UnJoinFromTheDialogUseCase.d.ts +0 -12
  122. package/dist/Domain/use_cases/UnJoinFromTheDialogUseCase.d.ts.map +0 -1
  123. package/src/Domain/use_cases/CreateDialogSetUpAutoJoinUseCase.ts +0 -77
  124. package/src/Domain/use_cases/CreateDialogWithAutoJoinUseCase.ts +0 -77
  125. package/src/Domain/use_cases/JoinFromTheDialogUseCase.ts +0 -61
  126. package/src/Domain/use_cases/UnJoinFromTheDialogUseCase.ts +0 -61
  127. package/storybook-static/161.53da4e03.iframe.bundle.js +0 -2
  128. package/storybook-static/167.88fc69a9.iframe.bundle.js +0 -1
  129. package/storybook-static/217.bd248edb.iframe.bundle.js +0 -405
  130. package/storybook-static/217.bd248edb.iframe.bundle.js.map +0 -1
  131. package/storybook-static/294.b81cdbca.iframe.bundle.js +0 -1
  132. package/storybook-static/363.64281ecc.iframe.bundle.js +0 -2
  133. package/storybook-static/364.988cd801.iframe.bundle.js +0 -1
  134. package/storybook-static/488.3cd3942e.iframe.bundle.js +0 -1
  135. package/storybook-static/559.9e64a6f5.iframe.bundle.js +0 -2
  136. package/storybook-static/735.3121b1b2.iframe.bundle.js +0 -2
  137. package/storybook-static/844.815b57b5.iframe.bundle.js +0 -95
  138. package/storybook-static/844.815b57b5.iframe.bundle.js.map +0 -1
  139. package/storybook-static/936.8546c1d8.iframe.bundle.js +0 -1
  140. package/storybook-static/961.d47fc2bc.iframe.bundle.js +0 -2
  141. package/storybook-static/Presentation-ui-components-Avatar-avatar-stories.a1656796.iframe.bundle.js +0 -2
  142. package/storybook-static/Presentation-ui-components-Badge-Badge-stories.58880259.iframe.bundle.js +0 -2
  143. package/storybook-static/Presentation-ui-components-Button-Button-stories.f456d20f.iframe.bundle.js +0 -2
  144. package/storybook-static/Presentation-ui-components-DialogBanner-DialogBanner-stories.cd797979.iframe.bundle.js +0 -1
  145. package/storybook-static/Presentation-ui-components-DialogItemPreview-DialogItemPreview-stories.2dae7689.iframe.bundle.js +0 -2
  146. package/storybook-static/Presentation-ui-components-DialogWindow-DialogWindow-stories.cd0c68a8.iframe.bundle.js +0 -2
  147. package/storybook-static/Presentation-ui-components-Dropdown-Dropdown-stories.c88a1bf9.iframe.bundle.js +0 -2
  148. package/storybook-static/Presentation-ui-components-Header-Header-stories.dd4b2b7b.iframe.bundle.js +0 -2
  149. package/storybook-static/Presentation-ui-components-Loader-Loader-stories.500e777d.iframe.bundle.js +0 -2
  150. package/storybook-static/Presentation-ui-components-Message-Message-stories.93af3d2d.iframe.bundle.js +0 -2
  151. package/storybook-static/Presentation-ui-components-MessageInput-MessageInput-stories.d1c68a8a.iframe.bundle.js +0 -1
  152. package/storybook-static/Presentation-ui-components-MessageSeparator-MessageSeparator-stories.2b4362f7.iframe.bundle.js +0 -1
  153. package/storybook-static/Presentation-ui-components-Placeholder-Placeholder-stories.34dfadb1.iframe.bundle.js +0 -2
  154. package/storybook-static/Presentation-ui-components-PreviewFileMessage-PreviewFileMessage-stories.9b4eff15.iframe.bundle.js +0 -2
  155. package/storybook-static/Presentation-ui-components-SettingsItem-SettingsItem-stories.8574dbe1.iframe.bundle.js +0 -2
  156. package/storybook-static/Presentation-ui-components-TextField-TextField-stories.058998bf.iframe.bundle.js +0 -2
  157. package/storybook-static/Presentation-ui-components-Toast-Toast-stories.c4dfb1a6.iframe.bundle.js +0 -1
  158. package/storybook-static/Presentation-ui-components-UserListItem-UserListItem-stories.371bcb5d.iframe.bundle.js +0 -2
  159. package/storybook-static/docs-Introduction-mdx.5addfa61.iframe.bundle.js +0 -1
  160. package/storybook-static/docs-Styling-mdx.9f4235f1.iframe.bundle.js +0 -1
  161. package/storybook-static/main.d176ed27.iframe.bundle.js +0 -1
  162. package/storybook-static/runtime~main.bc0704e8.iframe.bundle.js +0 -1
  163. /package/storybook-static/{161.53da4e03.iframe.bundle.js.LICENSE.txt → 161.77e7dbc5.iframe.bundle.js.LICENSE.txt} +0 -0
  164. /package/storybook-static/{217.bd248edb.iframe.bundle.js.LICENSE.txt → 217.cb8da73c.iframe.bundle.js.LICENSE.txt} +0 -0
  165. /package/storybook-static/{961.d47fc2bc.iframe.bundle.js.LICENSE.txt → 263.f039edee.iframe.bundle.js.LICENSE.txt} +0 -0
  166. /package/storybook-static/{735.3121b1b2.iframe.bundle.js.LICENSE.txt → 338.ed5286bb.iframe.bundle.js.LICENSE.txt} +0 -0
  167. /package/storybook-static/{559.9e64a6f5.iframe.bundle.js.LICENSE.txt → 559.fdf11e08.iframe.bundle.js.LICENSE.txt} +0 -0
  168. /package/storybook-static/{844.815b57b5.iframe.bundle.js.LICENSE.txt → 844.5804474b.iframe.bundle.js.LICENSE.txt} +0 -0
  169. /package/storybook-static/{Presentation-ui-components-Avatar-avatar-stories.a1656796.iframe.bundle.js.LICENSE.txt → Presentation-ui-components-Avatar-avatar-stories.6977856e.iframe.bundle.js.LICENSE.txt} +0 -0
  170. /package/storybook-static/{Presentation-ui-components-Badge-Badge-stories.58880259.iframe.bundle.js.LICENSE.txt → Presentation-ui-components-Badge-Badge-stories.d77c6500.iframe.bundle.js.LICENSE.txt} +0 -0
  171. /package/storybook-static/{Presentation-ui-components-Button-Button-stories.f456d20f.iframe.bundle.js.LICENSE.txt → Presentation-ui-components-Button-Button-stories.05f2f5b7.iframe.bundle.js.LICENSE.txt} +0 -0
  172. /package/storybook-static/{Presentation-ui-components-DialogItemPreview-DialogItemPreview-stories.2dae7689.iframe.bundle.js.LICENSE.txt → Presentation-ui-components-DialogItemPreview-DialogItemPreview-stories.e9d3dc6b.iframe.bundle.js.LICENSE.txt} +0 -0
  173. /package/storybook-static/{Presentation-ui-components-DialogWindow-DialogWindow-stories.cd0c68a8.iframe.bundle.js.LICENSE.txt → Presentation-ui-components-DialogWindow-DialogWindow-stories.7d74bffa.iframe.bundle.js.LICENSE.txt} +0 -0
  174. /package/storybook-static/{Presentation-ui-components-Dropdown-Dropdown-stories.c88a1bf9.iframe.bundle.js.LICENSE.txt → Presentation-ui-components-Dropdown-Dropdown-stories.d92e6904.iframe.bundle.js.LICENSE.txt} +0 -0
  175. /package/storybook-static/{Presentation-ui-components-Header-Header-stories.dd4b2b7b.iframe.bundle.js.LICENSE.txt → Presentation-ui-components-Header-Header-stories.b9a00187.iframe.bundle.js.LICENSE.txt} +0 -0
  176. /package/storybook-static/{Presentation-ui-components-Loader-Loader-stories.500e777d.iframe.bundle.js.LICENSE.txt → Presentation-ui-components-Loader-Loader-stories.f484b131.iframe.bundle.js.LICENSE.txt} +0 -0
  177. /package/storybook-static/{Presentation-ui-components-Message-Message-stories.93af3d2d.iframe.bundle.js.LICENSE.txt → Presentation-ui-components-Message-Message-stories.66867b7e.iframe.bundle.js.LICENSE.txt} +0 -0
  178. /package/storybook-static/{Presentation-ui-components-Placeholder-Placeholder-stories.34dfadb1.iframe.bundle.js.LICENSE.txt → Presentation-ui-components-Placeholder-Placeholder-stories.1e6bd1cd.iframe.bundle.js.LICENSE.txt} +0 -0
  179. /package/storybook-static/{Presentation-ui-components-PreviewFileMessage-PreviewFileMessage-stories.9b4eff15.iframe.bundle.js.LICENSE.txt → Presentation-ui-components-PreviewFileMessage-PreviewFileMessage-stories.44c68c03.iframe.bundle.js.LICENSE.txt} +0 -0
  180. /package/storybook-static/{Presentation-ui-components-SettingsItem-SettingsItem-stories.8574dbe1.iframe.bundle.js.LICENSE.txt → Presentation-ui-components-SettingsItem-SettingsItem-stories.3e87329b.iframe.bundle.js.LICENSE.txt} +0 -0
  181. /package/storybook-static/{Presentation-ui-components-TextField-TextField-stories.058998bf.iframe.bundle.js.LICENSE.txt → Presentation-ui-components-TextField-TextField-stories.ec3e7d5f.iframe.bundle.js.LICENSE.txt} +0 -0
  182. /package/storybook-static/{Presentation-ui-components-UserListItem-UserListItem-stories.371bcb5d.iframe.bundle.js.LICENSE.txt → Presentation-ui-components-UserListItem-UserListItem-stories.33b23eab.iframe.bundle.js.LICENSE.txt} +0 -0
@@ -46,7 +46,6 @@ export declare function QBCreatePrivateDialog(userId: QBUser['id'], dialogName?:
46
46
  export declare function QBCreateGroupDialog(userIds: Array<QBUser['id']>, dialogName?: string, data?: Dictionary<unknown>): Promise<QBUIKitChatDialog>;
47
47
  export declare function QBCreatePrivateDialogWithAutojoinFalse(userId: QBUser['id'], dialogName?: string, data?: Dictionary<unknown>): Promise<QBUIKitChatDialog>;
48
48
  export declare function QBCreateGroupDialogWithAutojoinFalse(userIds: Array<QBUser['id']>, dialogName?: string, data?: Dictionary<unknown>): Promise<QBUIKitChatDialog>;
49
- export declare function QBCreateGroupDialogWithAutojoinTrue(userIds: Array<QBUser['id']>, dialogName?: string, data?: Dictionary<unknown>): Promise<QBUIKitChatDialog>;
50
49
  export declare function QBUpdateDialog(dialogId: QBUIKitChatDialog['_id'], data: Dictionary<unknown>): Promise<QBUIKitChatDialog>;
51
50
  export declare function QBJoinGroupDialog(dialogId: QBUIKitChatDialog['_id']): Promise<unknown>;
52
51
  export declare function QBDeleteDialog(dialogIds: Array<QBUIKitChatDialog['_id']>): Promise<void>;
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/qb-api-calls/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,EAAE,EACT,gBAAgB,EAChB,aAAa,EACb,iBAAiB,EACjB,iBAAiB,EACjB,aAAa,EACb,cAAc,EACd,gBAAgB,EAChB,MAAM,EACN,wBAAwB,EAExB,cAAc,EACd,qBAAqB,EACrB,iBAAiB,EACjB,aAAa,EACb,aAAa,EACb,qBAAqB,EACrB,SAAS,EACT,eAAe,EACf,MAAM,EACN,kBAAkB,EAClB,eAAe,EAChB,MAAM,qBAAqB,CAAC;AAE7B,OAAO,EAEL,iBAAiB,EACjB,qBAAqB,EACrB,aAAa,EACd,MAAM,4BAA4B,CAAC;AAEpC,MAAM,MAAM,YAAY,GAAG;IACzB,YAAY,EAAE,MAAM,GAAG,MAAM,CAAC;IAC9B,cAAc,EAAE,MAAM,GAAG,MAAM,CAAC;IAChC,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,UAAU,EAAE,MAAM,CAAC;IACnB,MAAM,CAAC,EAAE,aAAa,CAAC;CACxB,CAAC;AAGF,eAAO,IAAI,KAAK,EAAE,OAAO,EAAE,GAAG,SAAS,CAAC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M,EAAE,iBAAiB,EACzB,QAAQ,EAAE,MAAM,CAAC,IAAI,CAAC,QAiBvB;AAGD,wBAAgB,iBAAiB,CAC/B,EAAE,EAAE,MAAM,GAAG,MAAM,EAAE,iBAAiB;AACtC,OAAO,EAAE,qBAAqB,mBAQ/B;AAED,wBAAgB,uBAAuB,CACrC,EAAE,EAAE,MAAM,CAAC,IAAI,CAAC,GAAG,MAAM,EACzB,OAAO,EAAE;IAAE,SAAS,EAAE,eAAe,CAAC,WAAW,CAAC,CAAA;CAAE,mBAQrD;AAED,wBAAgB,qBAAqB,CAAC,MAAM,EAAE,qBAAqB,QAKlE;AAED,wBAAgB,0BAA0B,CAAC,MAAM,EAAE,qBAAqB,QAKvE;AAED,wBAAgB,2BAA2B,CACzC,OAAO,EAAE,eAAe,EACxB,MAAM,EAAE,aAAa,oCAWtB;AAED,wBAAgB,cAAc,CAC5B,oBAAoB,EAAE,MAAM,EAC5B,eAAe,EAAE,MAAM,EACvB,OAAO,EAAE,aAAa,6BAoBvB;AAED,wBAAgB,WAAW,CACzB,oBAAoB,EAAE,MAAM,EAC5B,eAAe,EAAE,MAAM,EACvB,YAAY,EAAE,MAAM,6BAoBrB"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "quickblox-react-ui-kit",
3
- "version": "0.5.1-join-dialog-off.5",
3
+ "version": "0.5.2-alpha.1",
4
4
  "main": "dist/index-ui.js",
5
5
  "types": "dist/index-ui.d.ts",
6
6
  "license": "MIT",
@@ -8,12 +8,12 @@
8
8
  "@types/react": "^18.0.26",
9
9
  "@types/react-dom": "^18.0.9",
10
10
  "classnames": "^2.3.2",
11
+ "media-recorder-js": "^2.1.0",
11
12
  "qb-ai-answer-assistant": "^0.1.2",
12
13
  "qb-ai-core": "^0.1.3",
13
14
  "qb-ai-rephrase": "^0.1.2",
14
15
  "qb-ai-translate": "^0.1.2",
15
- "quickblox": "2.21.4",
16
- "media-recorder-js": "^2.1.0",
16
+ "quickblox": "2.22.0-alpha.1",
17
17
  "react": "^19.0.0",
18
18
  "react-dom": "^19.0.0",
19
19
  "react-router-dom": "^6.11.1",
@@ -42,7 +42,8 @@
42
42
  "@testing-library/react": "^16.2.0",
43
43
  "@testing-library/user-event": "^14.6.1",
44
44
  "@types/jest": "^27.5.2",
45
- "@types/node": "^20.17.19",
45
+ "@types/node": "^20.17.30",
46
+ "@typescript-eslint/eslint-plugin": "^5.62.0",
46
47
  "@typescript-eslint/eslint-plugin-tslint": "^5.45.1",
47
48
  "@typescript-eslint/parser": "^5.45.1",
48
49
  "babel-loader": "^9.2.1",
@@ -63,6 +64,7 @@
63
64
  "eslint-plugin-storybook": "^0.11.3",
64
65
  "file-loader": "^6.2.0",
65
66
  "html-webpack-plugin": "^5.6.3",
67
+ "jest": "^30.2.0",
66
68
  "mini-css-extract-plugin": "^2.9.2",
67
69
  "path-browserify": "^1.0.1",
68
70
  "prettier": "^2.8.0",
@@ -75,15 +77,16 @@
75
77
  "ts-loader": "^9.4.2",
76
78
  "url-loader": "^4.1.1",
77
79
  "web-vitals": "^2.1.4",
78
- "webpack": "^5.82.1",
79
- "webpack-cli": "^5.1.1",
80
- "webpack-dev-server": "^4.11.1"
80
+ "webpack": "^5.105.2",
81
+ "webpack-cli": "^6.0.1",
82
+ "webpack-dev-server": "^5.2.3"
81
83
  },
82
84
  "scripts": {
83
85
  "start": "webpack serve --config webpack.app.config.js --mode development",
86
+ "build": "npm run build:app",
84
87
  "build:app": "webpack --config webpack.app.config.js --mode production",
85
88
  "build:lib": "webpack --config webpack.lib.config.js --mode production",
86
- "test": "jest",
89
+ "test": "jest --passWithNoTests",
87
90
  "lint": "eslint ./src",
88
91
  "format": "prettier --write .",
89
92
  "storybook": "storybook dev -p 6006",
@@ -101,6 +104,9 @@
101
104
  "plugin:storybook/recommended"
102
105
  ]
103
106
  },
107
+ "engines": {
108
+ "node": ">=20"
109
+ },
104
110
  "browserslist": {
105
111
  "production": [
106
112
  ">0.2%",
@@ -29,7 +29,6 @@ export type FunctionTypeViewModelToVoid<TResult> = (
29
29
  export type EditDialogParams = {
30
30
  dialogTitle: string;
31
31
  dialogAvatar: File | string | null;
32
- disableAutoJoin: boolean | null;
33
32
  };
34
33
 
35
34
  export type ForwardMessagesParams = {
@@ -68,9 +67,6 @@ export type FunctionTypeEditDialogParamsToVoid = (
68
67
  export type FunctionTypeDialogEntityToDialogEntity = (
69
68
  entity: GroupDialogEntity,
70
69
  ) => Promise<DialogEntity>;
71
- export type FunctionTypeDialogEntityWithAutoJoinToDialogEntity = (
72
- entity: GroupDialogEntity, disableAutoJoin: boolean | null
73
- ) => Promise<DialogEntity>;
74
70
  export type FunctionTypeDialogEntityToBoolean = (
75
71
  entity: GroupDialogEntity,
76
72
  ) => Promise<boolean>;
@@ -137,10 +137,10 @@ export class DefaultConfigurations {
137
137
  static getDefaultQBConfig(): QBUIKitConfig {
138
138
  return {
139
139
  credentials: {
140
- appId: 75949,
141
- accountKey: 'uK_8uinNyz8-npTNB6tx',
142
- authKey: 'DdS7zxMEm5Q7DaS',
143
- authSecret: 'g88RhdOjnDOqFkv',
140
+ appId: -1,
141
+ accountKey: '',
142
+ authKey: '',
143
+ authSecret: '',
144
144
  sessionToken: '',
145
145
  },
146
146
  configAIApi: {
@@ -49,7 +49,7 @@ export class DialogLocalDTOMapper implements IMapper {
49
49
 
50
50
  dialog.name = DialogLocalDTOMapper.getDialogName(dialogEntity);
51
51
 
52
- dialog.photo = String(DialogLocalDTOMapper.getPhoto(dialogEntity));
52
+ dialog.photo = DialogLocalDTOMapper.getPhoto(dialogEntity);
53
53
 
54
54
  return Promise.resolve(dialog as TResult);
55
55
  }
@@ -167,7 +167,7 @@ export class DialogLocalDTOMapper implements IMapper {
167
167
  return dialogEntity;
168
168
  }
169
169
 
170
- private static getPhoto(dialogEntity: unknown): string | number {
170
+ private static getPhoto(dialogEntity: unknown): string {
171
171
  if (
172
172
  dialogEntity instanceof GroupDialogEntity ||
173
173
  dialogEntity instanceof PublicDialogEntity
@@ -503,8 +503,7 @@ export class DialogLocalDTOMapper implements IMapper {
503
503
  photo(v: unknown): v is GroupDialogEntity['photo'] {
504
504
  const { photo } = v as PublicDialogEntity;
505
505
 
506
- // return photo !== undefined && photo !== null;
507
- return true
506
+ return photo !== undefined && photo !== null;
508
507
  },
509
508
 
510
509
  participantIds(v: unknown): v is GroupDialogEntity['participantIds'] {
@@ -562,12 +561,12 @@ export class DialogLocalDTOMapper implements IMapper {
562
561
  INCORRECT_DATA_MAPPER_DTO_EXCEPTION_CODE,
563
562
  'field {name} does not exist or empty',
564
563
  );
565
- // if (!groupDialogEntityValidator.photo(dialogEntity))
566
- // throw new MapperDTOException(
567
- // INCORRECT_DATA_MAPPER_DTO_EXCEPTION_MESSAGE,
568
- // INCORRECT_DATA_MAPPER_DTO_EXCEPTION_CODE,
569
- // 'field {photo} does not exist or empty',
570
- // );
564
+ if (!groupDialogEntityValidator.photo(dialogEntity))
565
+ throw new MapperDTOException(
566
+ INCORRECT_DATA_MAPPER_DTO_EXCEPTION_MESSAGE,
567
+ INCORRECT_DATA_MAPPER_DTO_EXCEPTION_CODE,
568
+ 'field {photo} does not exist or empty',
569
+ );
571
570
  if (!groupDialogEntityValidator.participantIds(dialogEntity))
572
571
  throw new MapperDTOException(
573
572
  INCORRECT_DATA_MAPPER_DTO_EXCEPTION_MESSAGE,
@@ -59,7 +59,7 @@ export class DialogRemoteDTOMapper implements IMapper {
59
59
 
60
60
  dialog.name = DialogRemoteDTOMapper.getDialogName(dialogEntity);
61
61
 
62
- dialog.photo = String(DialogRemoteDTOMapper.getPhoto(dialogEntity)) || '';
62
+ dialog.photo = DialogRemoteDTOMapper.getPhoto(dialogEntity) || '';
63
63
  } catch (e) {
64
64
  console.log('MAPPER ERROR for entity: ', JSON.stringify(entity));
65
65
  }
@@ -165,7 +165,7 @@ export class DialogRemoteDTOMapper implements IMapper {
165
165
  return Promise.resolve(entity as unknown as TResult);
166
166
  }
167
167
 
168
- private static getPhoto(entity: unknown): string| number | null | undefined {
168
+ private static getPhoto(entity: unknown): string | null {
169
169
  const dialogEntity = entity as DialogEntity;
170
170
 
171
171
  if (dialogEntity && dialogEntity.type === DialogType.public)
@@ -495,8 +495,7 @@ export class DialogRemoteDTOMapper implements IMapper {
495
495
  photo(v: unknown): v is GroupDialogEntity['photo'] {
496
496
  const { photo } = v as PublicDialogEntity;
497
497
 
498
- // return photo !== undefined && photo !== null;
499
- return true
498
+ return photo !== undefined && photo !== null;
500
499
  },
501
500
 
502
501
  participantIds(v: unknown): v is GroupDialogEntity['participantIds'] {
@@ -554,12 +553,12 @@ export class DialogRemoteDTOMapper implements IMapper {
554
553
  INCORRECT_DATA_MAPPER_DTO_EXCEPTION_CODE,
555
554
  'field {name} does not exist or empty',
556
555
  );
557
- // if (!groupDialogEntityValidator.photo(dialogEntity))
558
- // throw new MapperDTOException(
559
- // INCORRECT_DATA_MAPPER_DTO_EXCEPTION_MESSAGE,
560
- // INCORRECT_DATA_MAPPER_DTO_EXCEPTION_CODE,
561
- // 'field {photo} does not exist or empty',
562
- // );
556
+ if (!groupDialogEntityValidator.photo(dialogEntity))
557
+ throw new MapperDTOException(
558
+ INCORRECT_DATA_MAPPER_DTO_EXCEPTION_MESSAGE,
559
+ INCORRECT_DATA_MAPPER_DTO_EXCEPTION_CODE,
560
+ 'field {photo} does not exist or empty',
561
+ );
563
562
  if (!groupDialogEntityValidator.participantIds(dialogEntity))
564
563
  throw new MapperDTOException(
565
564
  INCORRECT_DATA_MAPPER_DTO_EXCEPTION_MESSAGE,
@@ -3,7 +3,7 @@ import { stringifyError } from '../../utils/parse';
3
3
  import { getQB } from '../../qb-api-calls';
4
4
 
5
5
  export default class ConnectionRepository extends SubscriptionPerformer<boolean> {
6
- private timerId: NodeJS.Timeout | null = null; // Используем Timeout вместо Timer
6
+ private timerId: ReturnType<typeof setInterval> | undefined;
7
7
 
8
8
  private _needInit: boolean;
9
9
 
@@ -97,7 +97,8 @@ export default class ConnectionRepository extends SubscriptionPerformer<boolean>
97
97
 
98
98
  public stopKeepAlive() {
99
99
  if (this.timerId) {
100
- clearTimeout(this.timerId);
100
+ clearInterval(this.timerId);
101
+ this.timerId = undefined;
101
102
  }
102
103
  }
103
104
 
@@ -131,62 +131,6 @@ export default class DialogsRepository implements IDialogsRepository {
131
131
  }
132
132
  }
133
133
 
134
- async createDialogWithAutojoinInRemote(entity: DialogEntity): Promise<DialogEntity> {
135
- console.log(
136
- 'call createDialogInRemote in Repository with param: ',
137
- JSON.stringify(entity),
138
- );
139
- const remoteDialogDTO: RemoteDialogDTO =
140
- await this.dialogRemoteDTOMapper.fromEntity(entity);
141
-
142
- console.log('have remoteDialogDTO: ', JSON.stringify(remoteDialogDTO));
143
-
144
- try {
145
- const resultDTO: RemoteDialogDTO =
146
- await this.remoteDataSource.createDialogWithAutojoin(remoteDialogDTO);
147
- const resultEntity: DialogEntity =
148
- await this.dialogRemoteDTOMapper.toEntity(resultDTO);
149
-
150
- console.log(
151
- 'have result entity in createDialogInRemote:',
152
- JSON.stringify(resultEntity),
153
- );
154
-
155
- return Promise.resolve(resultEntity);
156
- } catch (e) {
157
- return Promise.reject(e);
158
- }
159
- }
160
-
161
- async createDialogSetUpAutojoinInRemote(entity: DialogEntity): Promise<DialogEntity> {
162
- console.log(
163
- 'call createDialogInRemote in Repository with param: ',
164
- JSON.stringify(entity),
165
- );
166
- const remoteDialogDTO: RemoteDialogDTO =
167
- await this.dialogRemoteDTOMapper.fromEntity(entity);
168
-
169
- console.log('have remoteDialogDTO: ', JSON.stringify(remoteDialogDTO));
170
-
171
- try {
172
- const resultDTO: RemoteDialogDTO =
173
- await this.remoteDataSource.createDialogSetUpAutojoin(remoteDialogDTO);
174
- const resultEntity: DialogEntity =
175
- await this.dialogRemoteDTOMapper.toEntity(resultDTO);
176
-
177
- console.log(
178
- 'have result entity in createDialogInRemote:',
179
- JSON.stringify(resultEntity),
180
- );
181
-
182
- return Promise.resolve(resultEntity);
183
- } catch (e) {
184
- return Promise.reject(e);
185
- }
186
- }
187
-
188
-
189
-
190
134
  async updateDialogInLocal(entity: DialogEntity): Promise<DialogEntity> {
191
135
  try {
192
136
  const dto: LocalDialogDTO = await this.dialogLocalDTOMapper.fromEntity(
@@ -429,33 +373,4 @@ export default class DialogsRepository implements IDialogsRepository {
429
373
  return Promise.reject(e);
430
374
  }
431
375
  }
432
-
433
- async unjoinUsersFromDialog(
434
- dialogId: string,
435
- ): Promise<boolean> {
436
- const dialogDTO: RemoteDialogDTO = new RemoteDialogDTO();
437
-
438
- dialogDTO.id = dialogId;
439
-
440
- await this.remoteDataSource.unjoinUsersFromDialog(
441
- dialogDTO,
442
- );
443
-
444
- return Promise.resolve(true);
445
- }
446
-
447
- async joinUsersFromDialog(
448
- dialogId: string,
449
- ): Promise<boolean> {
450
- const dialogDTO: RemoteDialogDTO = new RemoteDialogDTO();
451
-
452
- dialogDTO.id = dialogId;
453
-
454
-
455
- await this.remoteDataSource.joinDialog(
456
- dialogDTO,
457
- );
458
-
459
- return Promise.resolve(true);
460
- }
461
376
  }
@@ -52,10 +52,6 @@ export interface IRemoteDataSource extends IRemoteMessaging<RemoteMessageDTO> {
52
52
  эксепшны с диаграмы: коннекш фейлд, нет авторизации, запрещен доступ, некоректные данные
53
53
  */
54
54
  createDialog(dto: RemoteDialogDTO): Promise<RemoteDialogDTO>;
55
-
56
- createDialogWithAutojoin(dto: RemoteDialogDTO): Promise<RemoteDialogDTO>;
57
-
58
- createDialogSetUpAutojoin(dto: RemoteDialogDTO): Promise<RemoteDialogDTO>;
59
55
  /*
60
56
  негативный тест - нет такого диалога
61
57
  */
@@ -82,14 +78,6 @@ export interface IRemoteDataSource extends IRemoteMessaging<RemoteMessageDTO> {
82
78
  usersDTO: Array<RemoteUserDTO>,
83
79
  ): Promise<void>;
84
80
 
85
- unjoinUsersFromDialog(
86
- dialogDto: RemoteDialogDTO,
87
- ): Promise<void>;
88
-
89
- joinDialog(
90
- dialogDto: RemoteDialogDTO,
91
- ): Promise<void>;
92
-
93
81
  getUser(dto: RemoteUserDTO): Promise<RemoteUserDTO>;
94
82
 
95
83
  getUsers(dto: RemoteUsersDTO): Promise<RemoteUsersDTO>;
@@ -14,6 +14,16 @@ type DtoValidator<T> = {
14
14
  };
15
15
 
16
16
  export class MessageDTOMapper implements IDTOMapper {
17
+ private static normalizeUidToString(
18
+ uid: string | number | undefined,
19
+ ): string | undefined {
20
+ if (uid === undefined || uid === null) {
21
+ return undefined;
22
+ }
23
+
24
+ return String(uid);
25
+ }
26
+
17
27
  // eslint-disable-next-line class-methods-use-this
18
28
  fromDTO<TArg, TResult>(dto: TArg): Promise<TResult> {
19
29
  const messageDTO: RemoteMessageDTO = dto as RemoteMessageDTO;
@@ -46,20 +56,24 @@ export class MessageDTOMapper implements IDTOMapper {
46
56
  ) {
47
57
  const result: ChatMessageAttachmentEntity[] = qbAtts.map((item) => {
48
58
  const QB = getQB();
59
+ const normalizedUid = MessageDTOMapper.normalizeUidToString(item.uid);
60
+ const normalizedUrl = normalizedUid
61
+ ? QB.content.privateUrl(normalizedUid)
62
+ : undefined;
49
63
  const newItem: ChatMessageAttachmentEntity = {
50
64
  id: item.id,
51
65
  name: item.name,
52
66
  size: item.size,
53
67
  type: item.type,
54
- uid: item.uid,
55
- url: item.uid && QB.content.privateUrl(String(item.uid)),
68
+ uid: normalizedUid,
69
+ url: normalizedUrl,
56
70
  file: {
57
71
  id: item.id,
58
72
  name: item.name,
59
73
  size: item.size,
60
74
  type: item.type,
61
- uid: item.uid || '',
62
- url: item.uid && QB.content.privateUrl(String(item.uid)),
75
+ uid: normalizedUid || '',
76
+ url: normalizedUrl,
63
77
  },
64
78
  };
65
79
  const messageParts = MessageDTOMapper.getMessageParts(qbMessage);
@@ -73,11 +87,16 @@ export class MessageDTOMapper implements IDTOMapper {
73
87
  newItem.name = messageParts[1];
74
88
  // eslint-disable-next-line prefer-destructuring
75
89
  newItem.type = messageParts[3];
76
- newItem.url = newItem.uid && QB.content.privateUrl(newItem.uid);
90
+ const parsedUid = MessageDTOMapper.normalizeUidToString(newItem.uid);
91
+
92
+ newItem.uid = parsedUid;
93
+ newItem.url = parsedUid ? QB.content.privateUrl(parsedUid) : undefined;
77
94
  if (newItem.file) {
78
- newItem.file.uid = newItem.uid;
95
+ newItem.file.uid = parsedUid || '';
79
96
  newItem.file.name = newItem.name;
80
- newItem.file.url = newItem.uid && QB.content.privateUrl(newItem.uid);
97
+ newItem.file.url = parsedUid
98
+ ? QB.content.privateUrl(parsedUid)
99
+ : undefined;
81
100
  newItem.file.type = newItem.type;
82
101
  }
83
102
  }
@@ -143,7 +162,6 @@ export class MessageDTOMapper implements IDTOMapper {
143
162
  console.error(e);
144
163
  }
145
164
 
146
-
147
165
  dto.id = qbMessage._id;
148
166
  dto.dialogId = qbMessage.chat_dialog_id;
149
167
  dto.message = qbMessage.message; // MessageDTOMapper.formatMessage(qbMessage.message);
@@ -200,21 +218,20 @@ export class MessageDTOMapper implements IDTOMapper {
200
218
  // size: attachment.size || 0,
201
219
  // };
202
220
  // }
203
- public static convertAttachment(
204
- attachment: ChatMessageAttachmentEntity,
205
- ): ChatMessageAttachment {
206
- return {
207
- id: attachment.id.toString(),
208
- uid: attachment.uid?.toString() || '',
209
- type: attachment.type.toString(),
210
- url: attachment.url?.toString() || '',
211
- name: attachment.name?.toString() || '',
212
- size: attachment.size?.toString() || '',
213
- } as ChatMessageAttachment;
214
- }
215
-
221
+ public static convertAttachment(
222
+ attachment: ChatMessageAttachmentEntity,
223
+ ): ChatMessageAttachment {
224
+ return {
225
+ id: attachment.id.toString(),
226
+ uid: attachment.uid?.toString() || '',
227
+ type: attachment.type.toString(),
228
+ url: attachment.url?.toString() || '',
229
+ name: attachment.name?.toString() || '',
230
+ size: attachment.size?.toString() || '',
231
+ } as ChatMessageAttachment;
232
+ }
216
233
 
217
- public static convertToQBChatNewMessage(
234
+ public static convertToQBChatNewMessage(
218
235
  messages: RemoteMessageDTO[],
219
236
  ): QBChatMessage[] {
220
237
  return messages.map((message) => {