quickblox-react-ui-kit 0.1.0
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/.prettierignore +4 -0
- package/.prettierrc +8 -0
- package/LICENSE.md +19 -0
- package/README.md +255 -0
- package/dist/App.d.ts +4 -0
- package/dist/CommonTypes/FunctionResult.d.ts +4 -0
- package/dist/Data/Stubs.d.ts +29 -0
- package/dist/Data/dto/dialog/LocalDialogDTO.d.ts +16 -0
- package/dist/Data/dto/dialog/LocalDialogsDTO.d.ts +9 -0
- package/dist/Data/dto/dialog/RemoteDialogDTO.d.ts +18 -0
- package/dist/Data/dto/dialog/RemoteDialogsDTO.d.ts +9 -0
- package/dist/Data/dto/file/LocalFileDTO.d.ts +10 -0
- package/dist/Data/dto/file/RemoteFileDTO.d.ts +10 -0
- package/dist/Data/dto/message/LocalMessageDTO.d.ts +20 -0
- package/dist/Data/dto/message/LocalMessagesDTO.d.ts +9 -0
- package/dist/Data/dto/message/RemoteMessageDTO.d.ts +20 -0
- package/dist/Data/dto/message/RemoteMessagesDTO.d.ts +9 -0
- package/dist/Data/dto/user/LocalUserDTO.d.ts +14 -0
- package/dist/Data/dto/user/LocalUsersDTO.d.ts +9 -0
- package/dist/Data/dto/user/RemoteUserDTO.d.ts +14 -0
- package/dist/Data/dto/user/RemoteUsersDTO.d.ts +9 -0
- package/dist/Data/mapper/DialogLocalDTOMapper.d.ts +17 -0
- package/dist/Data/mapper/DialogRemoteDTOMapper.d.ts +18 -0
- package/dist/Data/mapper/FileLocalDTOMapper.d.ts +8 -0
- package/dist/Data/mapper/FileRemoteDTOMapper.d.ts +8 -0
- package/dist/Data/mapper/IMapper.d.ts +4 -0
- package/dist/Data/mapper/MessageLocalDTOMapper.d.ts +8 -0
- package/dist/Data/mapper/MessageRemoteDTOMapper.d.ts +8 -0
- package/dist/Data/mapper/UserLocalDTOMapper.d.ts +9 -0
- package/dist/Data/mapper/UserRemoteDTOMapper.d.ts +9 -0
- package/dist/Data/repository/ConnectionRepository.d.ts +15 -0
- package/dist/Data/repository/DialogsRepository.d.ts +28 -0
- package/dist/Data/repository/EventMessagesRepository.d.ts +35 -0
- package/dist/Data/repository/FileRepository.d.ts +14 -0
- package/dist/Data/repository/MessagesRepository.d.ts +24 -0
- package/dist/Data/repository/UsersRepository.d.ts +18 -0
- package/dist/Data/source/exception/LocalDataSourceException.d.ts +10 -0
- package/dist/Data/source/exception/MapperDTOException.d.ts +9 -0
- package/dist/Data/source/exception/RemoteDataSourceException.d.ts +15 -0
- package/dist/Data/source/exception/RepositoryException.d.ts +15 -0
- package/dist/Data/source/local/ChatLocalStorageDataSource.d.ts +8 -0
- package/dist/Data/source/local/ILocalDataSource.d.ts +25 -0
- package/dist/Data/source/local/ILocalFileDataSource.d.ts +7 -0
- package/dist/Data/source/local/LocalDataSource.d.ts +28 -0
- package/dist/Data/source/local/LocalFileDataSource.d.ts +8 -0
- package/dist/Data/source/remote/IRemoteDataSource.d.ts +36 -0
- package/dist/Data/source/remote/Mapper/DialogDTOMapper.d.ts +7 -0
- package/dist/Data/source/remote/Mapper/FileDTOMapper.d.ts +7 -0
- package/dist/Data/source/remote/Mapper/IDTOMapper.d.ts +4 -0
- package/dist/Data/source/remote/Mapper/MessageDTOMapper.d.ts +9 -0
- package/dist/Data/source/remote/Mapper/UserDTOMapper.d.ts +7 -0
- package/dist/Data/source/remote/RemoteDataSource.d.ts +81 -0
- package/dist/Domain/entity/Chat.d.ts +4 -0
- package/dist/Domain/entity/ChatMessageAttachmentEntity.d.ts +14 -0
- package/dist/Domain/entity/CustomDataEntity.d.ts +3 -0
- package/dist/Domain/entity/DialogEntity.d.ts +13 -0
- package/dist/Domain/entity/DialogEventInfo.d.ts +14 -0
- package/dist/Domain/entity/DialogTypes.d.ts +5 -0
- package/dist/Domain/entity/EventMessageType.d.ts +5 -0
- package/dist/Domain/entity/FileEntity.d.ts +10 -0
- package/dist/Domain/entity/FileTypes.d.ts +6 -0
- package/dist/Domain/entity/GroupDialogEntity.d.ts +19 -0
- package/dist/Domain/entity/LastMessageEntity.d.ts +5 -0
- package/dist/Domain/entity/MessageEntity.d.ts +21 -0
- package/dist/Domain/entity/NotificationTypes.d.ts +5 -0
- package/dist/Domain/entity/PrivateDialogEntity.d.ts +16 -0
- package/dist/Domain/entity/PublicDialogEntity.d.ts +18 -0
- package/dist/Domain/entity/UserEntity.d.ts +12 -0
- package/dist/Domain/exception/domain/DomainExecption.d.ts +4 -0
- package/dist/Domain/repository/IDialogsRepository.d.ts +20 -0
- package/dist/Domain/repository/IFileRepository.d.ts +6 -0
- package/dist/Domain/repository/IMessagesRepository.d.ts +15 -0
- package/dist/Domain/repository/IUsersRepository.d.ts +8 -0
- package/dist/Domain/repository/Pagination.d.ts +16 -0
- package/dist/Domain/use_cases/CreateDialogUseCase.d.ts +12 -0
- package/dist/Domain/use_cases/GetAllDialogsUseCase.d.ts +8 -0
- package/dist/Domain/use_cases/GetAllDialogsUseCaseWithMock.d.ts +10 -0
- package/dist/Domain/use_cases/GetAllMessagesForDialog.d.ts +11 -0
- package/dist/Domain/use_cases/GetAllUsersUseCase.d.ts +11 -0
- package/dist/Domain/use_cases/GetDialogByIdUseCase.d.ts +9 -0
- package/dist/Domain/use_cases/GetUsersByIdsUseCase.d.ts +9 -0
- package/dist/Domain/use_cases/LeaveDialogUseCase.d.ts +18 -0
- package/dist/Domain/use_cases/RemoveUsersFromTheDialogUseCase.d.ts +12 -0
- package/dist/Domain/use_cases/SendTextMessageUseCase.d.ts +9 -0
- package/dist/Domain/use_cases/SubscribeToDialogEventsUseCase.d.ts +16 -0
- package/dist/Domain/use_cases/SubscribeToDialogsUpdatesUseCase.d.ts +11 -0
- package/dist/Domain/use_cases/SubscribeToDialogsUpdatesUseCaseWithMock.d.ts +11 -0
- package/dist/Domain/use_cases/SyncDialogsUseCase.d.ts +23 -0
- package/dist/Domain/use_cases/UpdateDialogUseCase.d.ts +12 -0
- package/dist/Domain/use_cases/UploadFileUseCase.d.ts +9 -0
- package/dist/Domain/use_cases/UserTypingMessageUseCase.d.ts +13 -0
- package/dist/Domain/use_cases/base/BaseUseCase.d.ts +5 -0
- package/dist/Domain/use_cases/base/IUseCase.d.ts +5 -0
- package/dist/Domain/use_cases/base/Subscribable/ISubscribable.d.ts +5 -0
- package/dist/Domain/use_cases/base/Subscribable/SubscriptionPerformer.d.ts +24 -0
- package/dist/MyButton/MyButton.d.ts +9 -0
- package/dist/MyInput/MyInput.d.ts +10 -0
- package/dist/Presentation/Views/Base/BaseViewModel.d.ts +23 -0
- package/dist/Presentation/Views/CreateDialogFlow/CreateNewDialogFlow.d.ts +7 -0
- package/dist/Presentation/Views/Dialogs/DialogViewModel.d.ts +16 -0
- package/dist/Presentation/Views/Dialogs/Dialogs.d.ts +20 -0
- package/dist/Presentation/Views/Dialogs/useDialogsViewModel.d.ts +2 -0
- package/dist/Presentation/Views/Dialogs/useDialogsViewModelWithMockUseCase.d.ts +4 -0
- package/dist/Presentation/assets/DarkTheme.d.ts +21 -0
- package/dist/Presentation/assets/LightTheme.d.ts +21 -0
- package/dist/Presentation/assets/Theme.d.ts +20 -0
- package/dist/Presentation/assets/ThemeScheme.d.ts +43 -0
- package/dist/Presentation/components/Button.d.ts +4 -0
- package/dist/Presentation/components/Navbar.d.ts +2 -0
- package/dist/Presentation/components/TextInput.d.ts +1 -0
- package/dist/Presentation/components/UI/ DefaultThemes/CustomTheme.d.ts +6 -0
- package/dist/Presentation/components/UI/ DefaultThemes/DefaultTheme.d.ts +21 -0
- package/dist/Presentation/components/UI/Buttons/ActiveButton/ActiveButton.d.ts +9 -0
- package/dist/Presentation/components/UI/Buttons/MainBoundedButton/MainBoundedButton.d.ts +11 -0
- package/dist/Presentation/components/UI/Buttons/MainButton/MainButton.d.ts +21 -0
- package/dist/Presentation/components/UI/Dialogs/CreateDialog/CreateDialog.d.ts +13 -0
- package/dist/Presentation/components/UI/Dialogs/DialogInformation/DialogInformation.d.ts +12 -0
- package/dist/Presentation/components/UI/Dialogs/DialogInformation/DialogMemberButton/DialogMembersButton.d.ts +10 -0
- package/dist/Presentation/components/UI/Dialogs/DialogInformation/UsersList/SingleUser/SingleUser.d.ts +9 -0
- package/dist/Presentation/components/UI/Dialogs/DialogInformation/UsersList/UsersList.d.ts +10 -0
- package/dist/Presentation/components/UI/Dialogs/DialogInformation/UsersList/UsersListViewModel.d.ts +10 -0
- package/dist/Presentation/components/UI/Dialogs/DialogInformation/UsersList/useUsersListViewModel.d.ts +3 -0
- package/dist/Presentation/components/UI/Dialogs/EditDialog/EditDialog.d.ts +19 -0
- package/dist/Presentation/components/UI/Dialogs/EditDialog/UserAvatar/UserAvatar.d.ts +11 -0
- package/dist/Presentation/components/UI/Dialogs/HeaderDialogs/HeaderDialogs.d.ts +15 -0
- package/dist/Presentation/components/UI/Dialogs/InviteMembers/InviteMembers.d.ts +14 -0
- package/dist/Presentation/components/UI/Dialogs/InviteMembers/InviteMembersViewModel.d.ts +13 -0
- package/dist/Presentation/components/UI/Dialogs/InviteMembers/InviteUsersList/SingleUserWithCheckBox/SingleUserWithCheckBox.d.ts +13 -0
- package/dist/Presentation/components/UI/Dialogs/InviteMembers/InviteUsersResultViewModel.d.ts +6 -0
- package/dist/Presentation/components/UI/Dialogs/InviteMembers/NotFoundContent/NotFoundContent.d.ts +7 -0
- package/dist/Presentation/components/UI/Dialogs/InviteMembers/useInviteMembersViewModel.d.ts +2 -0
- package/dist/Presentation/components/UI/Dialogs/MembersList/MembersList.d.ts +10 -0
- package/dist/Presentation/components/UI/Dialogs/MessagesView/AudioAttachmentComponent/AudioAttachmentComponent.d.ts +8 -0
- package/dist/Presentation/components/UI/Dialogs/MessagesView/HeaderMessages/HeaderMessages.d.ts +12 -0
- package/dist/Presentation/components/UI/Dialogs/MessagesView/ImageAttachmentComponent/ImageAttachmentComponent.d.ts +8 -0
- package/dist/Presentation/components/UI/Dialogs/MessagesView/MessagesView.d.ts +11 -0
- package/dist/Presentation/components/UI/Dialogs/MessagesView/MessagesViewModel.d.ts +14 -0
- package/dist/Presentation/components/UI/Dialogs/MessagesView/VideoAttachmentComponent/VideoAttachmentComponent.d.ts +8 -0
- package/dist/Presentation/components/UI/Dialogs/MessagesView/VoiceRecordingProgress/VoiceRecordingProgress.d.ts +10 -0
- package/dist/Presentation/components/UI/Dialogs/MessagesView/useMessagesViewModelWithMockUseCase.d.ts +4 -0
- package/dist/Presentation/components/UI/Dialogs/PreviewDialog/PreviewDialog.d.ts +34 -0
- package/dist/Presentation/components/UI/Dialogs/PreviewDialog/PreviewDialogViewModel.d.ts +11 -0
- package/dist/Presentation/components/UI/Dialogs/YesNoQuestion/YesNoQuestion.d.ts +14 -0
- package/dist/Presentation/components/UI/Elements/SwitchButton/SwitchButton.d.ts +11 -0
- package/dist/Presentation/components/UI/Placeholders/ErrorComponent/ErrorComponent.d.ts +12 -0
- package/dist/Presentation/components/UI/Placeholders/LoaderComponent/LoaderComponent.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/ActiveSvg/ActiveSvg.d.ts +10 -0
- package/dist/Presentation/components/UI/svgs/Icons/Actions/Add/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Actions/AddContact/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Actions/Archive/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Actions/Copy/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Actions/Delete/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Actions/Download/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Actions/Edit/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Actions/EditDots/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Actions/Emoji/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Actions/ForwardFilled/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Actions/Hungup/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Actions/IncomeCall/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Actions/Like/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Actions/NewChat/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Actions/OutcomeCall/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Actions/Phone/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Actions/PhoneFilled/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Actions/Remove/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Actions/Remove2/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Actions/ReplyFilled/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Actions/Send/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Actions/Share/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Actions/SwapCamera/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Actions/Unarchive/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Actions/VideoIcon/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Actions/Voice/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Contents/Brodcast/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Contents/Chat/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Contents/ChatFilled/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Contents/Conference/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Contents/Contact/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Contents/ContactFilled/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Contents/GroupChat/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Contents/Notifications/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Contents/PrivateChat/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Contents/PublicChannel/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Contents/Stream/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Contents/StreamFilled/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Contents/User/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/IconsCommonTypes.d.ts +6 -0
- package/dist/Presentation/components/UI/svgs/Icons/Media/Attachment/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Media/AudioFile/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Media/BrokenFile/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Media/Camera/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Media/GifFile/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Media/ImageEmpty/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Media/ImageFile/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Media/ImageFilled/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Media/LinkWeb/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Media/Location/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Media/TextDocument/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Media/VideoFile/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Moderation/Admin/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Moderation/Banned/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Moderation/Freeze/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Moderation/Moderations/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Moderation/Muted/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Navigation/ArrowLeft/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Navigation/ArrowRight/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Navigation/Back/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Navigation/Close/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Navigation/Down/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Navigation/Leave/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Navigation/More/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Navigation/Next/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Navigation/Plus/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Navigation/Refresh/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Navigation/Search/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Navigation/Settings/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Navigation/SettingsField/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Status/Error/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Status/Help/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Status/Information/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Status/InformationFill/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Status/Loader/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Status/Mention/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Status/Sent/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Status/ViewedDelivered/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Toggle/CameraOff/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Toggle/CameraOn/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Toggle/CheckOff/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Toggle/CheckOn/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Toggle/Favourite/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Toggle/FavouriteFilled/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Toggle/FullScreen/inex.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Toggle/Hide/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Toggle/ImagePlay/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Toggle/Louder/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Toggle/MicOff/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Toggle/MicOn/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Toggle/Minimize/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Toggle/NotifyOff/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Toggle/NotifyOn/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Toggle/Pause/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Toggle/Quite/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Toggle/Record/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Toggle/Screenshare/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Toggle/Show/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Toggle/Speaker/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Toggle/SpeakerOff/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Toggle/StopRecord/index.d.ts +4 -0
- package/dist/Presentation/components/UI/svgs/Icons/Toggle/StopShare/index.d.ts +4 -0
- package/dist/Presentation/components/containers/ColumnContainer/ColumnContainer.d.ts +5 -0
- package/dist/Presentation/components/containers/RowCenterContainer/RowCenterContainer.d.ts +33 -0
- package/dist/Presentation/components/containers/RowLeftContainer/RowLeftContainer.d.ts +33 -0
- package/dist/Presentation/components/containers/RowRightContainer/RowRightContainer.d.ts +33 -0
- package/dist/Presentation/components/containers/ScrollableContainer/ScrollableContainer.d.ts +14 -0
- package/dist/Presentation/components/layouts/Desktop/Desktop.d.ts +4 -0
- package/dist/Presentation/components/layouts/Desktop/DesktopLayoutForMockModels.d.ts +9 -0
- package/dist/Presentation/components/layouts/LayoutCommonTypes.d.ts +6 -0
- package/dist/Presentation/components/layouts/TestStage/LoginView/Login.d.ts +9 -0
- package/dist/Presentation/components/layouts/TestStage/TestStageMarkup.d.ts +4 -0
- package/dist/Presentation/components/layouts/TestStage/TestStageWithMockData/TestStageWithMockData.d.ts +3 -0
- package/dist/Presentation/components/providers/ModalContextProvider/Modal.d.ts +14 -0
- package/dist/Presentation/components/providers/ModalContextProvider/ModalContextProvider.d.ts +4 -0
- package/dist/Presentation/components/providers/ModalContextProvider/useModal.d.ts +11 -0
- package/dist/Presentation/components/providers/ProviderProps.d.ts +4 -0
- package/dist/Presentation/components/providers/QuickBloxUIKitProvider/QuickBloxUIKitProvider.d.ts +41 -0
- package/dist/Presentation/components/providers/QuickBloxUIKitProvider/useEventMessagesRepository.d.ts +3 -0
- package/dist/Presentation/components/providers/QuickBloxUIKitProvider/useQBConnection.d.ts +7 -0
- package/dist/Presentation/components/providers/QuickBloxUIKitProvider/useQbDataContext.d.ts +3 -0
- package/dist/QBconfig.d.ts +29 -0
- package/dist/index-ui.d.ts +25 -0
- package/dist/index-ui.js +2589 -0
- package/dist/index.d.ts +1 -0
- package/dist/qb-api-calls/index.d.ts +59 -0
- package/dist/setupTests.d.ts +1 -0
- package/dist/utils/DateTimeFormatter.d.ts +4 -0
- package/dist/utils/parse.d.ts +6 -0
- package/global.d.ts +855 -0
- package/package.json +104 -0
- package/public/favicon.ico +0 -0
- package/public/index.html +47 -0
- package/public/logo192.png +0 -0
- package/public/logo512.png +0 -0
- package/public/manifest.json +25 -0
- package/public/quickblox.js +54609 -0
- package/public/robots.txt +3 -0
- package/src/App.scss +0 -0
- package/src/App.tsx +230 -0
- package/src/CommonTypes/FunctionResult.ts +4 -0
- package/src/Data/Stubs.ts +1131 -0
- package/src/Data/dto/dialog/LocalDialogDTO.ts +42 -0
- package/src/Data/dto/dialog/LocalDialogsDTO.ts +21 -0
- package/src/Data/dto/dialog/RemoteDialogDTO.ts +58 -0
- package/src/Data/dto/dialog/RemoteDialogsDTO.ts +21 -0
- package/src/Data/dto/file/LocalFileDTO.ts +26 -0
- package/src/Data/dto/file/RemoteFileDTO.ts +26 -0
- package/src/Data/dto/message/LocalMessageDTO.ts +51 -0
- package/src/Data/dto/message/LocalMessagesDTO.ts +21 -0
- package/src/Data/dto/message/RemoteMessageDTO.ts +51 -0
- package/src/Data/dto/message/RemoteMessagesDTO.ts +21 -0
- package/src/Data/dto/user/LocalUserDTO.ts +37 -0
- package/src/Data/dto/user/LocalUsersDTO.ts +23 -0
- package/src/Data/dto/user/RemoteUserDTO.ts +37 -0
- package/src/Data/dto/user/RemoteUsersDTO.ts +21 -0
- package/src/Data/mapper/DialogLocalDTOMapper.ts +742 -0
- package/src/Data/mapper/DialogRemoteDTOMapper.ts +776 -0
- package/src/Data/mapper/FileLocalDTOMapper.ts +253 -0
- package/src/Data/mapper/FileRemoteDTOMapper.ts +265 -0
- package/src/Data/mapper/IMapper.ts +14 -0
- package/src/Data/mapper/MessageLocalDTOMapper.ts +425 -0
- package/src/Data/mapper/MessageRemoteDTOMapper.ts +430 -0
- package/src/Data/mapper/UserLocalDTOMapper.ts +381 -0
- package/src/Data/mapper/UserRemoteDTOMapper.ts +393 -0
- package/src/Data/repository/ConnectionRepository.ts +128 -0
- package/src/Data/repository/DialogsRepository.ts +422 -0
- package/src/Data/repository/EventMessagesRepository.ts +291 -0
- package/src/Data/repository/FileRepository.ts +110 -0
- package/src/Data/repository/MessagesRepository.ts +288 -0
- package/src/Data/repository/UsersRepository.ts +324 -0
- package/src/Data/source/exception/LocalDataSourceException.ts +17 -0
- package/src/Data/source/exception/MapperDTOException.ts +19 -0
- package/src/Data/source/exception/RemoteDataSourceException.ts +28 -0
- package/src/Data/source/exception/RepositoryException.ts +27 -0
- package/src/Data/source/local/ChatLocalStorageDataSource.ts +262 -0
- package/src/Data/source/local/ILocalDataSource.ts +45 -0
- package/src/Data/source/local/ILocalFileDataSource.ts +11 -0
- package/src/Data/source/local/LocalDataSource.ts +377 -0
- package/src/Data/source/local/LocalFileDataSource.ts +22 -0
- package/src/Data/source/remote/IRemoteDataSource.ts +112 -0
- package/src/Data/source/remote/Mapper/DialogDTOMapper.ts +401 -0
- package/src/Data/source/remote/Mapper/FileDTOMapper.ts +276 -0
- package/src/Data/source/remote/Mapper/IDTOMapper.ts +4 -0
- package/src/Data/source/remote/Mapper/MessageDTOMapper.ts +399 -0
- package/src/Data/source/remote/Mapper/UserDTOMapper.ts +344 -0
- package/src/Data/source/remote/RemoteDataSource.ts +1278 -0
- package/src/Domain/entity/Chat.ts +4 -0
- package/src/Domain/entity/ChatMessageAttachmentEntity.ts +15 -0
- package/src/Domain/entity/CustomDataEntity.ts +3 -0
- package/src/Domain/entity/DialogEntity.ts +15 -0
- package/src/Domain/entity/DialogEventInfo.ts +15 -0
- package/src/Domain/entity/DialogTypes.ts +7 -0
- package/src/Domain/entity/EventMessageType.ts +7 -0
- package/src/Domain/entity/FileEntity.ts +11 -0
- package/src/Domain/entity/FileTypes.ts +9 -0
- package/src/Domain/entity/GroupDialogEntity.ts +54 -0
- package/src/Domain/entity/LastMessageEntity.ts +5 -0
- package/src/Domain/entity/MessageEntity.ts +25 -0
- package/src/Domain/entity/NotificationTypes.ts +7 -0
- package/src/Domain/entity/PrivateDialogEntity.ts +46 -0
- package/src/Domain/entity/PublicDialogEntity.ts +72 -0
- package/src/Domain/entity/UserEntity.ts +22 -0
- package/src/Domain/exception/domain/DomainExecption.ts +5 -0
- package/src/Domain/repository/IDialogsRepository.ts +40 -0
- package/src/Domain/repository/IFileRepository.ts +9 -0
- package/src/Domain/repository/IMessagesRepository.ts +28 -0
- package/src/Domain/repository/IUsersRepository.ts +13 -0
- package/src/Domain/repository/Pagination.ts +48 -0
- package/src/Domain/use_cases/CreateDialogUseCase.ts +73 -0
- package/src/Domain/use_cases/GetAllDialogsUseCase.ts +20 -0
- package/src/Domain/use_cases/GetAllDialogsUseCaseWithMock.ts +45 -0
- package/src/Domain/use_cases/GetAllMessagesForDialog.ts +61 -0
- package/src/Domain/use_cases/GetAllUsersUseCase.ts +34 -0
- package/src/Domain/use_cases/GetDialogByIdUseCase.ts +28 -0
- package/src/Domain/use_cases/GetUsersByIdsUseCase.ts +22 -0
- package/src/Domain/use_cases/LeaveDialogUseCase.ts +109 -0
- package/src/Domain/use_cases/RemoveUsersFromTheDialogUseCase.ts +103 -0
- package/src/Domain/use_cases/SendTextMessageUseCase.ts +26 -0
- package/src/Domain/use_cases/SubscribeToDialogEventsUseCase.ts +141 -0
- package/src/Domain/use_cases/SubscribeToDialogsUpdatesUseCase.ts +69 -0
- package/src/Domain/use_cases/SubscribeToDialogsUpdatesUseCaseWithMock.ts +61 -0
- package/src/Domain/use_cases/SyncDialogsUseCase.ts +246 -0
- package/src/Domain/use_cases/UpdateDialogUseCase.ts +65 -0
- package/src/Domain/use_cases/UploadFileUseCase.ts +24 -0
- package/src/Domain/use_cases/UserTypingMessageUseCase.ts +51 -0
- package/src/Domain/use_cases/base/BaseUseCase.ts +77 -0
- package/src/Domain/use_cases/base/IUseCase.ts +5 -0
- package/src/Domain/use_cases/base/Subscribable/ISubscribable.ts +6 -0
- package/src/Domain/use_cases/base/Subscribable/SubscriptionPerformer.ts +143 -0
- package/src/MyButton/MyButton.scss +11 -0
- package/src/MyButton/MyButton.tsx +25 -0
- package/src/MyInput/MyInput.scss +9 -0
- package/src/MyInput/MyInput.tsx +36 -0
- package/src/Presentation/.gitkeep +0 -0
- package/src/Presentation/Views/Base/BaseViewModel.ts +66 -0
- package/src/Presentation/Views/CreateDialogFlow/CreateNewDialogFlow.tsx +187 -0
- package/src/Presentation/Views/Dialogs/DialogViewModel.ts +23 -0
- package/src/Presentation/Views/Dialogs/Dialogs.scss +66 -0
- package/src/Presentation/Views/Dialogs/Dialogs.tsx +372 -0
- package/src/Presentation/Views/Dialogs/useDialogsViewModel.ts +136 -0
- package/src/Presentation/Views/Dialogs/useDialogsViewModelWithMockUseCase.ts +345 -0
- package/src/Presentation/Views/Navigation/More.svg +7 -0
- package/src/Presentation/assets/DarkTheme.ts +58 -0
- package/src/Presentation/assets/LightTheme.ts +58 -0
- package/src/Presentation/assets/Theme.ts +143 -0
- package/src/Presentation/assets/ThemeScheme.ts +83 -0
- package/src/Presentation/assets/fonts/.gitkeep +0 -0
- package/src/Presentation/assets/fonts/Roboto-Bold.eot +0 -0
- package/src/Presentation/assets/fonts/Roboto-Bold.ttf +0 -0
- package/src/Presentation/assets/fonts/Roboto-Bold.woff +0 -0
- package/src/Presentation/assets/fonts/Roboto-Bold.woff2 +0 -0
- package/src/Presentation/assets/fonts/Roboto-Medium.eot +0 -0
- package/src/Presentation/assets/fonts/Roboto-Medium.ttf +0 -0
- package/src/Presentation/assets/fonts/Roboto-Medium.woff +0 -0
- package/src/Presentation/assets/fonts/Roboto-Medium.woff2 +0 -0
- package/src/Presentation/assets/fonts/Roboto-Regular.eot +0 -0
- package/src/Presentation/assets/fonts/Roboto-Regular.ttf +0 -0
- package/src/Presentation/assets/fonts/Roboto-Regular.woff +0 -0
- package/src/Presentation/assets/fonts/Roboto-Regular.woff2 +0 -0
- package/src/Presentation/assets/img/Artem_Koltunov_Selfi.png +0 -0
- package/src/Presentation/assets/img/bee-img.png +0 -0
- package/src/Presentation/assets/styles/_fonts.scss +32 -0
- package/src/Presentation/assets/styles/_reset-styles.scss +435 -0
- package/src/Presentation/assets/styles/_theme_colors_scheme.scss +56 -0
- package/src/Presentation/assets/styles/_theme_dark.scss +33 -0
- package/src/Presentation/assets/styles/_theme_light.scss +33 -0
- package/src/Presentation/assets/styles/_variables.scss +2 -0
- package/src/Presentation/components/Button.js +5 -0
- package/src/Presentation/components/Navbar.tsx +45 -0
- package/src/Presentation/components/TextInput.js +10 -0
- package/src/Presentation/components/UI/ DefaultThemes/CustomTheme.ts +13 -0
- package/src/Presentation/components/UI/ DefaultThemes/DefaultTheme.ts +58 -0
- package/src/Presentation/components/UI/Buttons/ActiveButton/ActiveButton.tsx +40 -0
- package/src/Presentation/components/UI/Buttons/MainBoundedButton/MainBoundedButton.scss +0 -0
- package/src/Presentation/components/UI/Buttons/MainBoundedButton/MainBoundedButton.tsx +30 -0
- package/src/Presentation/components/UI/Buttons/MainButton/MainButton.scss +127 -0
- package/src/Presentation/components/UI/Buttons/MainButton/MainButton.tsx +62 -0
- package/src/Presentation/components/UI/Dialogs/CreateDialog/CreateDialog.scss +45 -0
- package/src/Presentation/components/UI/Dialogs/CreateDialog/CreateDialog.tsx +77 -0
- package/src/Presentation/components/UI/Dialogs/DialogInformation/DialogInformation.scss +429 -0
- package/src/Presentation/components/UI/Dialogs/DialogInformation/DialogInformation.tsx +646 -0
- package/src/Presentation/components/UI/Dialogs/DialogInformation/DialogMemberButton/DialogMembersButton.scss +42 -0
- package/src/Presentation/components/UI/Dialogs/DialogInformation/DialogMemberButton/DialogMembersButton.tsx +26 -0
- package/src/Presentation/components/UI/Dialogs/DialogInformation/UsersList/SingleUser/SingleUser.scss +95 -0
- package/src/Presentation/components/UI/Dialogs/DialogInformation/UsersList/SingleUser/SingleUser.tsx +42 -0
- package/src/Presentation/components/UI/Dialogs/DialogInformation/UsersList/UsersList.scss +60 -0
- package/src/Presentation/components/UI/Dialogs/DialogInformation/UsersList/UsersList.tsx +65 -0
- package/src/Presentation/components/UI/Dialogs/DialogInformation/UsersList/UsersListViewModel.ts +13 -0
- package/src/Presentation/components/UI/Dialogs/DialogInformation/UsersList/useUsersListViewModel.ts +81 -0
- package/src/Presentation/components/UI/Dialogs/EditDialog/EditDialog.scss +183 -0
- package/src/Presentation/components/UI/Dialogs/EditDialog/EditDialog.tsx +262 -0
- package/src/Presentation/components/UI/Dialogs/EditDialog/UserAvatar/UserAvatar.scss +32 -0
- package/src/Presentation/components/UI/Dialogs/EditDialog/UserAvatar/UserAvatar.tsx +59 -0
- package/src/Presentation/components/UI/Dialogs/HeaderDialogs/HeaderDialogs.scss +67 -0
- package/src/Presentation/components/UI/Dialogs/HeaderDialogs/HeaderDialogs.tsx +112 -0
- package/src/Presentation/components/UI/Dialogs/InviteMembers/InviteMembers.scss +146 -0
- package/src/Presentation/components/UI/Dialogs/InviteMembers/InviteMembers.tsx +374 -0
- package/src/Presentation/components/UI/Dialogs/InviteMembers/InviteMembersViewModel.ts +18 -0
- package/src/Presentation/components/UI/Dialogs/InviteMembers/InviteUsersList/SingleUserWithCheckBox/SingleUserWithCheckBox.scss +113 -0
- package/src/Presentation/components/UI/Dialogs/InviteMembers/InviteUsersList/SingleUserWithCheckBox/SingleUserWithCheckBox.tsx +87 -0
- package/src/Presentation/components/UI/Dialogs/InviteMembers/InviteUsersResultViewModel.ts +12 -0
- package/src/Presentation/components/UI/Dialogs/InviteMembers/NotFoundContent/NotFoundContent.scss +37 -0
- package/src/Presentation/components/UI/Dialogs/InviteMembers/NotFoundContent/NotFoundContent.tsx +22 -0
- package/src/Presentation/components/UI/Dialogs/InviteMembers/useInviteMembersViewModel.ts +116 -0
- package/src/Presentation/components/UI/Dialogs/MembersList/MembersList.scss +128 -0
- package/src/Presentation/components/UI/Dialogs/MembersList/MembersList.tsx +89 -0
- package/src/Presentation/components/UI/Dialogs/MessagesView/AudioAttachmentComponent/AudioAttachmentComponent.scss +7 -0
- package/src/Presentation/components/UI/Dialogs/MessagesView/AudioAttachmentComponent/AudioAttachmentComponent.tsx +27 -0
- package/src/Presentation/components/UI/Dialogs/MessagesView/HeaderMessages/HeaderMessages.scss +133 -0
- package/src/Presentation/components/UI/Dialogs/MessagesView/HeaderMessages/HeaderMessages.tsx +137 -0
- package/src/Presentation/components/UI/Dialogs/MessagesView/ImageAttachmentComponent/ImageAttachmentComponent.scss +11 -0
- package/src/Presentation/components/UI/Dialogs/MessagesView/ImageAttachmentComponent/ImageAttachmentComponent.tsx +25 -0
- package/src/Presentation/components/UI/Dialogs/MessagesView/MessagesView.scss +327 -0
- package/src/Presentation/components/UI/Dialogs/MessagesView/MessagesView.tsx +794 -0
- package/src/Presentation/components/UI/Dialogs/MessagesView/MessagesViewModel.ts +20 -0
- package/src/Presentation/components/UI/Dialogs/MessagesView/VideoAttachmentComponent/VideoAttachmentComponent.scss +7 -0
- package/src/Presentation/components/UI/Dialogs/MessagesView/VideoAttachmentComponent/VideoAttachmentComponent.tsx +33 -0
- package/src/Presentation/components/UI/Dialogs/MessagesView/VoiceRecordingProgress/VoiceRecordingProgress.scss +35 -0
- package/src/Presentation/components/UI/Dialogs/MessagesView/VoiceRecordingProgress/VoiceRecordingProgress.tsx +86 -0
- package/src/Presentation/components/UI/Dialogs/MessagesView/useMessagesViewModelWithMockUseCase.ts +452 -0
- package/src/Presentation/components/UI/Dialogs/PreviewDialog/PreviewDialog.scss +100 -0
- package/src/Presentation/components/UI/Dialogs/PreviewDialog/PreviewDialog.tsx +405 -0
- package/src/Presentation/components/UI/Dialogs/PreviewDialog/PreviewDialogViewModel.ts +42 -0
- package/src/Presentation/components/UI/Dialogs/YesNoQuestion/YesNoQuestion.scss +35 -0
- package/src/Presentation/components/UI/Dialogs/YesNoQuestion/YesNoQuestion.tsx +89 -0
- package/src/Presentation/components/UI/Elements/SwitchButton/SwitchButton.scss +61 -0
- package/src/Presentation/components/UI/Elements/SwitchButton/SwitchButton.tsx +48 -0
- package/src/Presentation/components/UI/Placeholders/ErrorComponent/ErrorComponent.scss +74 -0
- package/src/Presentation/components/UI/Placeholders/ErrorComponent/ErrorComponent.tsx +72 -0
- package/src/Presentation/components/UI/Placeholders/LoaderComponent/LoaderComponent.scss +21 -0
- package/src/Presentation/components/UI/Placeholders/LoaderComponent/LoaderComponent.tsx +41 -0
- package/src/Presentation/components/UI/svgs/ActiveSvg/ActiveSvg.scss +3 -0
- package/src/Presentation/components/UI/svgs/ActiveSvg/ActiveSvg.tsx +41 -0
- package/src/Presentation/components/UI/svgs/Icons/Actions/Add/Add.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Actions/Add/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Actions/AddContact/Add contact.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Actions/AddContact/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Actions/Archive/Archive.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Actions/Archive/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Actions/Copy/Copy.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Actions/Copy/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Actions/Delete/Delete.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Actions/Delete/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Actions/Download/Download.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Actions/Download/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Actions/Edit/Edit.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Actions/Edit/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Actions/EditDots/EditDots.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Actions/EditDots/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Actions/Emoji/Emoji.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Actions/Emoji/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Actions/ForwardFilled/Forward filled.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Actions/ForwardFilled/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Actions/Hungup/Hungup.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Actions/Hungup/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Actions/IncomeCall/Income call.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Actions/IncomeCall/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Actions/Like/Like.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Actions/Like/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Actions/NewChat/New chat.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Actions/NewChat/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Actions/OutcomeCall/Outcome call.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Actions/OutcomeCall/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Actions/Phone/Phone.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Actions/Phone/index.tsx +35 -0
- package/src/Presentation/components/UI/svgs/Icons/Actions/PhoneFilled/Phone filled.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Actions/PhoneFilled/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Actions/Remove/Remove.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Actions/Remove/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Actions/Remove2/Remove2.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Actions/Remove2/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Actions/ReplyFilled/Reply filled.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Actions/ReplyFilled/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Actions/Send/Send.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Actions/Send/index.tsx +38 -0
- package/src/Presentation/components/UI/svgs/Icons/Actions/Share/Share.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Actions/Share/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Actions/SwapCamera/Swap camera.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Actions/SwapCamera/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Actions/Unarchive/Unarchive.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Actions/Unarchive/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Actions/VideoIcon/Video.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Actions/VideoIcon/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Actions/Voice/Voice.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Actions/Voice/index.tsx +35 -0
- package/src/Presentation/components/UI/svgs/Icons/Contents/Brodcast/Broadcast.svg +7 -0
- package/src/Presentation/components/UI/svgs/Icons/Contents/Brodcast/index.tsx +38 -0
- package/src/Presentation/components/UI/svgs/Icons/Contents/Chat/Chat.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Contents/Chat/index.tsx +35 -0
- package/src/Presentation/components/UI/svgs/Icons/Contents/ChatFilled/Chat filled.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Contents/ChatFilled/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Contents/Conference/Conference.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Contents/Conference/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Contents/Contact/Contact.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Contents/Contact/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Contents/ContactFilled/Contact filled.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Contents/ContactFilled/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Contents/GroupChat/Group chat.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Contents/GroupChat/index.tsx +35 -0
- package/src/Presentation/components/UI/svgs/Icons/Contents/Notifications/Notifications.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Contents/Notifications/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Contents/PrivateChat/Private chat.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Contents/PrivateChat/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Contents/PublicChannel/Public channel.svg +7 -0
- package/src/Presentation/components/UI/svgs/Icons/Contents/PublicChannel/index.tsx +67 -0
- package/src/Presentation/components/UI/svgs/Icons/Contents/Stream/Stream.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Contents/Stream/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Contents/StreamFilled/Stream filled.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Contents/StreamFilled/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Contents/User/User.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Contents/User/index.tsx +35 -0
- package/src/Presentation/components/UI/svgs/Icons/IconsCommonTypes.ts +6 -0
- package/src/Presentation/components/UI/svgs/Icons/Media/Attachment/Attachment.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Media/Attachment/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Media/AudioFile/Audio file.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Media/AudioFile/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Media/BrokenFile/Broken file.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Media/BrokenFile/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Media/Camera/Camera.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Media/Camera/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Media/GifFile/GIF file.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Media/GifFile/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Media/ImageEmpty/Image.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Media/ImageEmpty/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Media/ImageFile/File.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Media/ImageFile/index.tsx +35 -0
- package/src/Presentation/components/UI/svgs/Icons/Media/ImageFilled/Image filled.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Media/ImageFilled/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Media/LinkWeb/Link.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Media/LinkWeb/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Media/Location/Location.svg +4 -0
- package/src/Presentation/components/UI/svgs/Icons/Media/Location/index.tsx +26 -0
- package/src/Presentation/components/UI/svgs/Icons/Media/TextDocument/Text document.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Media/TextDocument/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Media/VideoFile/Video file.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Media/VideoFile/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Moderation/Admin/Admin.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Moderation/Admin/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Moderation/Banned/Banned.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Moderation/Banned/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Moderation/Freeze/Freeze.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Moderation/Freeze/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Moderation/Moderations/Moderations.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Moderation/Moderations/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Moderation/Muted/Muted.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Moderation/Muted/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Navigation/ArrowLeft/Arrow left.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Navigation/ArrowLeft/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Navigation/ArrowRight/Arrow right.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Navigation/ArrowRight/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Navigation/Back/Back.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Navigation/Back/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Navigation/Close/Close.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Navigation/Close/index.tsx +35 -0
- package/src/Presentation/components/UI/svgs/Icons/Navigation/Down/Down.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Navigation/Down/index.tsx +35 -0
- package/src/Presentation/components/UI/svgs/Icons/Navigation/Leave/Leave.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Navigation/Leave/index.tsx +35 -0
- package/src/Presentation/components/UI/svgs/Icons/Navigation/More/More.svg +7 -0
- package/src/Presentation/components/UI/svgs/Icons/Navigation/More/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Navigation/Next/Next.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Navigation/Next/index.tsx +35 -0
- package/src/Presentation/components/UI/svgs/Icons/Navigation/Plus/Plus.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Navigation/Plus/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Navigation/Refresh/Refresh.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Navigation/Refresh/index.tsx +36 -0
- package/src/Presentation/components/UI/svgs/Icons/Navigation/Search/Search.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Navigation/Search/index.tsx +35 -0
- package/src/Presentation/components/UI/svgs/Icons/Navigation/Settings/Settings.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Navigation/Settings/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Navigation/SettingsField/Settings filled.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Navigation/SettingsField/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Status/Error/Error.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Status/Error/index.tsx +36 -0
- package/src/Presentation/components/UI/svgs/Icons/Status/Help/Help.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Status/Help/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Status/Information/Information.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Status/Information/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Status/InformationFill/index.tsx +35 -0
- package/src/Presentation/components/UI/svgs/Icons/Status/Loader/Loader.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Status/Loader/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Status/Mention/Mention.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Status/Mention/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Status/Sent/Sent.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Status/Sent/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Status/ViewedDelivered/Viewed_Delivered.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Status/ViewedDelivered/index.tsx +38 -0
- package/src/Presentation/components/UI/svgs/Icons/Toggle/CameraOff/Camera off.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Toggle/CameraOff/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Toggle/CameraOn/Camera on.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Toggle/CameraOn/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Toggle/CheckOff/Check off.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Toggle/CheckOff/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Toggle/CheckOn/Check on.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Toggle/CheckOn/index.tsx +24 -0
- package/src/Presentation/components/UI/svgs/Icons/Toggle/Favourite/Favourite.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Toggle/Favourite/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Toggle/FavouriteFilled/Favourite filled.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Toggle/FavouriteFilled/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Toggle/FullScreen/Full screen.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Toggle/FullScreen/inex.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Toggle/Hide/Hide.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Toggle/Hide/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Toggle/ImagePlay/Play.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Toggle/ImagePlay/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Toggle/Louder/Louder.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Toggle/Louder/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Toggle/MicOff/Mic off.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Toggle/MicOff/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Toggle/MicOn/Mic on.svg +4 -0
- package/src/Presentation/components/UI/svgs/Icons/Toggle/MicOn/index.tsx +26 -0
- package/src/Presentation/components/UI/svgs/Icons/Toggle/Minimize/Minimize.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Toggle/Minimize/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Toggle/NotifyOff/Notify off.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Toggle/NotifyOff/index.tsx +35 -0
- package/src/Presentation/components/UI/svgs/Icons/Toggle/NotifyOn/Notify on.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Toggle/NotifyOn/index.tsx +35 -0
- package/src/Presentation/components/UI/svgs/Icons/Toggle/Pause/Pause.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Toggle/Pause/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Toggle/Quite/Quite.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Toggle/Quite/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Toggle/Record/Record.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Toggle/Record/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Toggle/Screenshare/Screenshare.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Toggle/Screenshare/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Toggle/Show/Show.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Toggle/Show/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Toggle/Speaker/Speaker.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Toggle/Speaker/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Toggle/SpeakerOff/Speaker off.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Toggle/SpeakerOff/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Toggle/StopRecord/Stop record.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Toggle/StopRecord/index.tsx +22 -0
- package/src/Presentation/components/UI/svgs/Icons/Toggle/StopShare/Stop share.svg +3 -0
- package/src/Presentation/components/UI/svgs/Icons/Toggle/StopShare/index.tsx +22 -0
- package/src/Presentation/components/containers/ColumnContainer/ColumnContainer.scss +6 -0
- package/src/Presentation/components/containers/ColumnContainer/ColumnContainer.tsx +24 -0
- package/src/Presentation/components/containers/RowCenterContainer/RowCenterContainer.scss +45 -0
- package/src/Presentation/components/containers/RowCenterContainer/RowCenterContainer.tsx +95 -0
- package/src/Presentation/components/containers/RowLeftContainer/RowLeftContainer.scss +45 -0
- package/src/Presentation/components/containers/RowLeftContainer/RowLeftContainer.tsx +97 -0
- package/src/Presentation/components/containers/RowRightContainer/RowRightContainer.scss +46 -0
- package/src/Presentation/components/containers/RowRightContainer/RowRightContainer.tsx +97 -0
- package/src/Presentation/components/containers/ScrollableContainer/ScrollableContainer.scss +46 -0
- package/src/Presentation/components/containers/ScrollableContainer/ScrollableContainer.tsx +85 -0
- package/src/Presentation/components/layouts/Desktop/Desktop.tsx +103 -0
- package/src/Presentation/components/layouts/Desktop/DesktopLayout.scss +31 -0
- package/src/Presentation/components/layouts/Desktop/DesktopLayoutForMockModels.tsx +31 -0
- package/src/Presentation/components/layouts/LayoutCommonTypes.ts +7 -0
- package/src/Presentation/components/layouts/TestStage/LoginView/Login.scss +71 -0
- package/src/Presentation/components/layouts/TestStage/LoginView/Login.tsx +116 -0
- package/src/Presentation/components/layouts/TestStage/TestStageMarkup.scss +24 -0
- package/src/Presentation/components/layouts/TestStage/TestStageMarkup.tsx +1109 -0
- package/src/Presentation/components/layouts/TestStage/TestStageWithMockData/TestStageWithMockData.tsx +209 -0
- package/src/Presentation/components/providers/ModalContextProvider/Modal.scss +71 -0
- package/src/Presentation/components/providers/ModalContextProvider/Modal.tsx +131 -0
- package/src/Presentation/components/providers/ModalContextProvider/ModalContextProvider.tsx +38 -0
- package/src/Presentation/components/providers/ModalContextProvider/useModal.ts +39 -0
- package/src/Presentation/components/providers/ProviderProps.ts +5 -0
- package/src/Presentation/components/providers/QuickBloxUIKitProvider/QuickBloxUIKitProvider.tsx +255 -0
- package/src/Presentation/components/providers/QuickBloxUIKitProvider/useEventMessagesRepository.ts +10 -0
- package/src/Presentation/components/providers/QuickBloxUIKitProvider/useQBConnection.ts +38 -0
- package/src/Presentation/components/providers/QuickBloxUIKitProvider/useQbDataContext.ts +82 -0
- package/src/QBconfig.ts +41 -0
- package/src/index-ui.ts +60 -0
- package/src/index.scss +74 -0
- package/src/index.tsx +25 -0
- package/src/logo.svg +1 -0
- package/src/qb-api-calls/index.ts +543 -0
- package/src/react-app-env.d.ts +1 -0
- package/src/setupTests.ts +5 -0
- package/src/utils/DateTimeFormatter.ts +35 -0
- package/src/utils/parse.ts +74 -0
- package/tsconfig.json +33 -0
- package/typedoc.json +4 -0
- package/webpack.config.js +56 -0
package/global.d.ts
ADDED
|
@@ -0,0 +1,855 @@
|
|
|
1
|
+
type Dictionary<T> = Record<string, T>;
|
|
2
|
+
|
|
3
|
+
type DictionaryByKey<T, V> = {
|
|
4
|
+
[K in keyof T]?: V;
|
|
5
|
+
};
|
|
6
|
+
|
|
7
|
+
type Primitive = string | number | boolean | undefined | null | Date | File;
|
|
8
|
+
|
|
9
|
+
type SetTails<T, R extends Primitive> = T extends Array<unknown>
|
|
10
|
+
? Array<T[number] extends Primitive ? R : SetTails<T[number], R>>
|
|
11
|
+
: {
|
|
12
|
+
[K in keyof T]: T[K] extends Primitive ? R : SetTails<T[K], R>;
|
|
13
|
+
};
|
|
14
|
+
|
|
15
|
+
interface DateRange {
|
|
16
|
+
from: Date;
|
|
17
|
+
to: Date;
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
interface QBConfig {
|
|
21
|
+
debug: boolean;
|
|
22
|
+
endpoints: {
|
|
23
|
+
chat?: string;
|
|
24
|
+
api?: string;
|
|
25
|
+
};
|
|
26
|
+
webrtc?: {
|
|
27
|
+
iceServers?: RTCIceServer[];
|
|
28
|
+
};
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
interface QBError {
|
|
32
|
+
code?: number;
|
|
33
|
+
status?: string;
|
|
34
|
+
detail?: string | string[] | Dictionary<string | string[]>;
|
|
35
|
+
message: string | string[] | Dictionary<string | string[]>;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
interface QBUser {
|
|
39
|
+
id: number;
|
|
40
|
+
full_name: string;
|
|
41
|
+
email: string;
|
|
42
|
+
login: string;
|
|
43
|
+
phone: string;
|
|
44
|
+
website: string;
|
|
45
|
+
/** Date ISO string */
|
|
46
|
+
created_at: string;
|
|
47
|
+
/** Date ISO string */
|
|
48
|
+
updated_at: string;
|
|
49
|
+
/** Date ISO string */
|
|
50
|
+
last_request_at: string;
|
|
51
|
+
external_user_id: null;
|
|
52
|
+
facebook_id: string | null;
|
|
53
|
+
blob_id: null;
|
|
54
|
+
custom_data: string | null;
|
|
55
|
+
age_over16: boolean;
|
|
56
|
+
allow_statistics_analysis: boolean;
|
|
57
|
+
allow_sales_activities: boolean;
|
|
58
|
+
parents_contacts: string;
|
|
59
|
+
user_tags: string | null;
|
|
60
|
+
password?: string;
|
|
61
|
+
old_password?: string;
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
type QBUserCustomData = Partial<{
|
|
65
|
+
full_name: string;
|
|
66
|
+
address: string;
|
|
67
|
+
birthdate: string;
|
|
68
|
+
description: string;
|
|
69
|
+
gender: string;
|
|
70
|
+
language: string;
|
|
71
|
+
avatar: {
|
|
72
|
+
id: number;
|
|
73
|
+
uid: string;
|
|
74
|
+
};
|
|
75
|
+
}>;
|
|
76
|
+
|
|
77
|
+
interface QBUserWithCustomData extends Omit<QBUser, 'custom_data'> {
|
|
78
|
+
custom_data: QBUserCustomData;
|
|
79
|
+
}
|
|
80
|
+
|
|
81
|
+
interface QBSession {
|
|
82
|
+
_id: string;
|
|
83
|
+
application_id: number;
|
|
84
|
+
/** Date ISO string */
|
|
85
|
+
created_at: string;
|
|
86
|
+
id: number;
|
|
87
|
+
nonce: number;
|
|
88
|
+
token: string;
|
|
89
|
+
ts: number;
|
|
90
|
+
/** Date ISO string */
|
|
91
|
+
updated_at: string;
|
|
92
|
+
user_id: QBUser['id'];
|
|
93
|
+
}
|
|
94
|
+
|
|
95
|
+
type ChatConnectParams =
|
|
96
|
+
| {
|
|
97
|
+
userId: number;
|
|
98
|
+
/** user's password or session token */
|
|
99
|
+
password: string;
|
|
100
|
+
}
|
|
101
|
+
| {
|
|
102
|
+
jid: string;
|
|
103
|
+
/** user's password or session token */
|
|
104
|
+
password: string;
|
|
105
|
+
}
|
|
106
|
+
| {
|
|
107
|
+
email: string;
|
|
108
|
+
/** user's password or session token */
|
|
109
|
+
password: string;
|
|
110
|
+
};
|
|
111
|
+
|
|
112
|
+
interface ChatMessageAttachment {
|
|
113
|
+
/** ID of the file on QuickBlox server (UID of file from QB.content.createAndUpload) */
|
|
114
|
+
id: string | number;
|
|
115
|
+
uid?: string;
|
|
116
|
+
/** Type of attachment. Example: audio, video, image or other */
|
|
117
|
+
type: string;
|
|
118
|
+
/** Link to a file in Internet */
|
|
119
|
+
url?: string;
|
|
120
|
+
name?: string;
|
|
121
|
+
size?: number;
|
|
122
|
+
[key: string]: unknown;
|
|
123
|
+
}
|
|
124
|
+
|
|
125
|
+
enum QBChatDialogType {
|
|
126
|
+
PUBLIC = 1,
|
|
127
|
+
GROUP = 2,
|
|
128
|
+
PRIVATE = 3,
|
|
129
|
+
}
|
|
130
|
+
|
|
131
|
+
interface QBChatDialog {
|
|
132
|
+
_id: string;
|
|
133
|
+
/** Date ISO string */
|
|
134
|
+
created_at: string;
|
|
135
|
+
data?: { [key: string]: string };
|
|
136
|
+
last_message: string | null;
|
|
137
|
+
/** Date ISO string */
|
|
138
|
+
last_message_date_sent: string | null;
|
|
139
|
+
last_message_id: string | null;
|
|
140
|
+
last_message_user_id: QBUser['id'] | null;
|
|
141
|
+
name: string;
|
|
142
|
+
occupants_ids: number[];
|
|
143
|
+
new_occupants_ids: number[];
|
|
144
|
+
photo: null | string;
|
|
145
|
+
type: typeof QBChatDialogType | number;
|
|
146
|
+
/** Date ISO string */
|
|
147
|
+
updated_at: string;
|
|
148
|
+
user_id: QBUser['id'];
|
|
149
|
+
xmpp_room_jid: string | null;
|
|
150
|
+
unread_messages_count: number | null;
|
|
151
|
+
joined?: boolean;
|
|
152
|
+
}
|
|
153
|
+
|
|
154
|
+
interface QBChatMessage {
|
|
155
|
+
_id: string;
|
|
156
|
+
attachments: ChatMessageAttachment[];
|
|
157
|
+
chat_dialog_id: QBChatDialog['_id'];
|
|
158
|
+
/** Date ISO string */
|
|
159
|
+
created_at: string;
|
|
160
|
+
/** Date timestamp */
|
|
161
|
+
date_sent: number;
|
|
162
|
+
delivered_ids?: Array<QBUser['id']>;
|
|
163
|
+
message: string;
|
|
164
|
+
read_ids?: Array<QBUser['id']>;
|
|
165
|
+
read: 0 | 1;
|
|
166
|
+
recipient_id: QBUser['id'] | null;
|
|
167
|
+
sender_id: QBUser['id'];
|
|
168
|
+
/** Date ISO string */
|
|
169
|
+
updated_at: string;
|
|
170
|
+
notification_type?: string;
|
|
171
|
+
}
|
|
172
|
+
|
|
173
|
+
interface QBMessageStatusParams {
|
|
174
|
+
messageId: QBChatMessage['_id'];
|
|
175
|
+
dialogId: QBChatDialog['_id'];
|
|
176
|
+
userId: QBUser['id'];
|
|
177
|
+
}
|
|
178
|
+
|
|
179
|
+
interface QBChatNewMessage {
|
|
180
|
+
type: 'chat' | 'groupchat';
|
|
181
|
+
body: string;
|
|
182
|
+
notification_type?: string;
|
|
183
|
+
dialog_id?: QBChatDialog['_id'];
|
|
184
|
+
extension: {
|
|
185
|
+
attachments?: ChatMessageAttachment[];
|
|
186
|
+
save_to_history: 0 | 1;
|
|
187
|
+
dialog_id: QBChatDialog['_id'];
|
|
188
|
+
notification_type?: string;
|
|
189
|
+
sender_id?: QBUser['id'];
|
|
190
|
+
};
|
|
191
|
+
markable: 0 | 1;
|
|
192
|
+
}
|
|
193
|
+
|
|
194
|
+
interface QBChatXMPPMessage {
|
|
195
|
+
id: string;
|
|
196
|
+
dialog_id: QBChatDialog['_id'];
|
|
197
|
+
recipient_id: null;
|
|
198
|
+
type: 'chat' | 'groupchat';
|
|
199
|
+
notification_type?: string;
|
|
200
|
+
body: string;
|
|
201
|
+
delay: null;
|
|
202
|
+
markable: 0 | 1;
|
|
203
|
+
extension: {
|
|
204
|
+
attachments?: ChatMessageAttachment[];
|
|
205
|
+
date_sent: string;
|
|
206
|
+
notification_type?: string;
|
|
207
|
+
save_to_history?: 0 | 1;
|
|
208
|
+
dialog_id?: QBChatDialog['_id'];
|
|
209
|
+
sender_id?: QBUser['id'];
|
|
210
|
+
};
|
|
211
|
+
}
|
|
212
|
+
|
|
213
|
+
interface QBSystemMessageExtension {
|
|
214
|
+
[key: string]: string | undefined;
|
|
215
|
+
notification_type: string;
|
|
216
|
+
action?: 'read' | 'delete';
|
|
217
|
+
}
|
|
218
|
+
|
|
219
|
+
interface QBSystemMessage {
|
|
220
|
+
id: string;
|
|
221
|
+
userId: QBUser['id'];
|
|
222
|
+
body: null | string;
|
|
223
|
+
extension: QBSystemMessageExtension;
|
|
224
|
+
}
|
|
225
|
+
|
|
226
|
+
interface QBGetDialogResult {
|
|
227
|
+
items: QBChatDialog[];
|
|
228
|
+
limit: number;
|
|
229
|
+
skip: number;
|
|
230
|
+
total_entries: number;
|
|
231
|
+
}
|
|
232
|
+
|
|
233
|
+
type GetMessagesResult = {
|
|
234
|
+
items: QBChatMessage[];
|
|
235
|
+
limit: number;
|
|
236
|
+
skip: number;
|
|
237
|
+
};
|
|
238
|
+
|
|
239
|
+
interface QBChatModule {
|
|
240
|
+
dialog: {
|
|
241
|
+
create(
|
|
242
|
+
params: Dictionary<unknown>,
|
|
243
|
+
callback: (error?: QBError, result: QBChatDialog) => void,
|
|
244
|
+
): void;
|
|
245
|
+
list(
|
|
246
|
+
params: Dictionary<unknown>,
|
|
247
|
+
callback: (error?: QBError, result: QBGetDialogResult) => void,
|
|
248
|
+
): void;
|
|
249
|
+
update(
|
|
250
|
+
id: string,
|
|
251
|
+
data: Dictionary<unknown>,
|
|
252
|
+
callback: (error?: QBError, result: QBChatDialog) => void,
|
|
253
|
+
): void;
|
|
254
|
+
delete(
|
|
255
|
+
dialogIds: Array<QBChatDialog['_id']>,
|
|
256
|
+
callback: (error?: QBError) => void,
|
|
257
|
+
): void;
|
|
258
|
+
};
|
|
259
|
+
message: {
|
|
260
|
+
list(
|
|
261
|
+
params: Dictionary<unknown>,
|
|
262
|
+
callback: (error?: QBError, result: GetMessagesResult) => void,
|
|
263
|
+
): void;
|
|
264
|
+
};
|
|
265
|
+
isConnected: boolean;
|
|
266
|
+
send<T extends QBChatNewMessage>(
|
|
267
|
+
jidOrUserId: QBUser['id'] | string,
|
|
268
|
+
message: T,
|
|
269
|
+
): string;
|
|
270
|
+
sendSystemMessage(
|
|
271
|
+
jidOrUserId: QBUser['id'] | string,
|
|
272
|
+
message: { extension: QBSystemMessage['extension'] },
|
|
273
|
+
): string;
|
|
274
|
+
sendDeliveredStatus(params: QBMessageStatusParams): void;
|
|
275
|
+
sendReadStatus(params: QBMessageStatusParams): void;
|
|
276
|
+
sendIsTypingStatus(jidOrUserId: QBUser['id'] | string): void;
|
|
277
|
+
sendIsStopTypingStatus(jidOrUserId: QBUser['id'] | string): void;
|
|
278
|
+
connect: (
|
|
279
|
+
params: ChatConnectParams,
|
|
280
|
+
callback: (error?: QBError, result: unknown) => void,
|
|
281
|
+
) => void;
|
|
282
|
+
disconnect: () => void;
|
|
283
|
+
ping(jidOrUserId: string | number, callback: (error: unknown) => void): void;
|
|
284
|
+
ping(callback: (error?: QBError) => void): void;
|
|
285
|
+
muc: {
|
|
286
|
+
join(
|
|
287
|
+
dialogJid: string,
|
|
288
|
+
callback: (error?: QBError, result: unknown) => void,
|
|
289
|
+
): void;
|
|
290
|
+
leave(
|
|
291
|
+
dialogJid: string,
|
|
292
|
+
callback: (error?: QBError, result: unknown) => void,
|
|
293
|
+
): void;
|
|
294
|
+
};
|
|
295
|
+
helpers: {
|
|
296
|
+
getDialogJid(dialogId: QBChatDialog['_id']): string;
|
|
297
|
+
getUserCurrentJid(): string;
|
|
298
|
+
getUserJid(userId: QBUser['id'], appId?: string | number): string;
|
|
299
|
+
getRoomJidFromDialogId(dialogId: QBChatDialog['_id']): string;
|
|
300
|
+
getRecipientId(
|
|
301
|
+
occupantsIds: Array<QBUser['id']>,
|
|
302
|
+
userId: QBUser['id'],
|
|
303
|
+
): number;
|
|
304
|
+
};
|
|
305
|
+
onMessageListener?: (
|
|
306
|
+
senderId: QBUser['id'],
|
|
307
|
+
message: QBChatXMPPMessage,
|
|
308
|
+
) => void;
|
|
309
|
+
onMessageErrorListener?: (messageId: string, error: unknown) => void;
|
|
310
|
+
onMessageTypingListener?: (
|
|
311
|
+
isTyping: boolean,
|
|
312
|
+
userId: QBUser['id'],
|
|
313
|
+
dialogId: QBChatDialog['_id'],
|
|
314
|
+
) => void;
|
|
315
|
+
onDeliveredStatusListener?: (
|
|
316
|
+
messageId: string,
|
|
317
|
+
dialogId: QBChatDialog['_id'],
|
|
318
|
+
userId: QBUser['id'],
|
|
319
|
+
) => void;
|
|
320
|
+
onReadStatusListener?: (
|
|
321
|
+
messageId: string,
|
|
322
|
+
dialogId: QBChatDialog['_id'],
|
|
323
|
+
userId: QBUser['id'],
|
|
324
|
+
) => void;
|
|
325
|
+
onSystemMessageListener?: (message: QBSystemMessage) => void;
|
|
326
|
+
onReconnectFailedListener?: (error: unknown) => void;
|
|
327
|
+
onDisconnectedListener?: VoidFunction;
|
|
328
|
+
onReconnectListener?: VoidFunction;
|
|
329
|
+
onSessionExpiredListener?: (error?: QBError) => void;
|
|
330
|
+
}
|
|
331
|
+
interface QBContentParam {
|
|
332
|
+
name: string;
|
|
333
|
+
file: any;
|
|
334
|
+
type: string;
|
|
335
|
+
size: number;
|
|
336
|
+
public: boolean; // optional, "false" by default
|
|
337
|
+
}
|
|
338
|
+
|
|
339
|
+
interface QBContentObject {
|
|
340
|
+
account_id: number;
|
|
341
|
+
app_id: number;
|
|
342
|
+
content_type: string;
|
|
343
|
+
created_at: string;
|
|
344
|
+
id: number;
|
|
345
|
+
name: string;
|
|
346
|
+
public: boolean;
|
|
347
|
+
size: number;
|
|
348
|
+
uid: string;
|
|
349
|
+
updated_at: string;
|
|
350
|
+
}
|
|
351
|
+
|
|
352
|
+
interface QBCustomObject {
|
|
353
|
+
/**
|
|
354
|
+
* ID of the record
|
|
355
|
+
* Generated automatically by the server after record creation
|
|
356
|
+
*/
|
|
357
|
+
_id: string;
|
|
358
|
+
/** ID of the user who created the record */
|
|
359
|
+
user_id: QBUser['id'];
|
|
360
|
+
/** ID of parent object (Relations) */
|
|
361
|
+
_parent_id: string | null;
|
|
362
|
+
/** Date & time when a record was created, filled automatically */
|
|
363
|
+
created_at: number;
|
|
364
|
+
/** Date & time when record was updated, filled automatically */
|
|
365
|
+
updated_at: number;
|
|
366
|
+
}
|
|
367
|
+
|
|
368
|
+
interface QBAppointment extends QBCustomObject {
|
|
369
|
+
priority: number;
|
|
370
|
+
client_id: QBUser['id'];
|
|
371
|
+
provider_id: QBUser['id'];
|
|
372
|
+
dialog_id: QBChatDialog['_id'];
|
|
373
|
+
description: string;
|
|
374
|
+
notes: string;
|
|
375
|
+
conclusion?: string;
|
|
376
|
+
date_start?: string;
|
|
377
|
+
date_end?: string;
|
|
378
|
+
language?: string;
|
|
379
|
+
records?: Array<QBContentObject['id']>;
|
|
380
|
+
}
|
|
381
|
+
|
|
382
|
+
interface QBSchedule extends QBCustomObject {
|
|
383
|
+
provider_id: QBUser['id'];
|
|
384
|
+
duration: number;
|
|
385
|
+
timezone: string;
|
|
386
|
+
holidays: string[] | null;
|
|
387
|
+
sunday: string[] | null;
|
|
388
|
+
monday: string[] | null;
|
|
389
|
+
tuesday: string[] | null;
|
|
390
|
+
wednesday: string[] | null;
|
|
391
|
+
thursday: string[] | null;
|
|
392
|
+
friday: string[] | null;
|
|
393
|
+
saturday: string[] | null;
|
|
394
|
+
}
|
|
395
|
+
|
|
396
|
+
interface QBCalendarEvent extends QBCustomObject {
|
|
397
|
+
date: string;
|
|
398
|
+
duration: number;
|
|
399
|
+
provider_id: QBUser['id'];
|
|
400
|
+
client_id: QBUser['id'];
|
|
401
|
+
appointment_id: QBAppointment['_id'];
|
|
402
|
+
}
|
|
403
|
+
|
|
404
|
+
type CreateAndUploadParams = {
|
|
405
|
+
file: File;
|
|
406
|
+
name: File['name'];
|
|
407
|
+
type: File['type'];
|
|
408
|
+
size: File['size'];
|
|
409
|
+
public?: boolean;
|
|
410
|
+
};
|
|
411
|
+
|
|
412
|
+
interface QBContentModule {
|
|
413
|
+
privateUrl(fileUID: string): string;
|
|
414
|
+
publicUrl(fileUID: string): string;
|
|
415
|
+
getInfo(
|
|
416
|
+
id: number,
|
|
417
|
+
callback: (error?: QBError, file: { blob: QBContentObject }) => void,
|
|
418
|
+
);
|
|
419
|
+
delete(id: number, callback: (error?: QBError, file: unknown) => void);
|
|
420
|
+
createAndUpload(
|
|
421
|
+
param: QBContentParam,
|
|
422
|
+
callback: (error?: QBError, file: { blob: QBContentObject }) => void,
|
|
423
|
+
);
|
|
424
|
+
}
|
|
425
|
+
|
|
426
|
+
interface QBDataDeletedResponse {
|
|
427
|
+
deleted: Array<QBCustomObject['_id']>;
|
|
428
|
+
deletedCount: number;
|
|
429
|
+
}
|
|
430
|
+
|
|
431
|
+
interface QBDataModule {
|
|
432
|
+
create<T extends QBCustomObject>(
|
|
433
|
+
className: string,
|
|
434
|
+
data: Dictionary<unknown>,
|
|
435
|
+
callback: (error?: QBError, customObject: T) => void,
|
|
436
|
+
): void;
|
|
437
|
+
delete<T extends QBCustomObject['_id'] | Array<QBCustomObject['_id']>>(
|
|
438
|
+
className: string,
|
|
439
|
+
ids: T,
|
|
440
|
+
callback: (error?: QBError, res: QBDataDeletedResponse) => void,
|
|
441
|
+
): void;
|
|
442
|
+
list<T extends QBCustomObject>(
|
|
443
|
+
className: string,
|
|
444
|
+
filters: Dictionary<unknown>,
|
|
445
|
+
callback: (
|
|
446
|
+
error?: QBError,
|
|
447
|
+
result: {
|
|
448
|
+
class_name: string;
|
|
449
|
+
items: T[];
|
|
450
|
+
limit: number;
|
|
451
|
+
skip: number;
|
|
452
|
+
},
|
|
453
|
+
) => void,
|
|
454
|
+
): void;
|
|
455
|
+
update<
|
|
456
|
+
D extends { _id: string } & Dictionary<unknown>,
|
|
457
|
+
T extends QBCustomObject,
|
|
458
|
+
>(
|
|
459
|
+
className: string,
|
|
460
|
+
data: D,
|
|
461
|
+
callback: (error?: QBError, result: T) => void,
|
|
462
|
+
): void;
|
|
463
|
+
}
|
|
464
|
+
|
|
465
|
+
interface QBCreateUserWithLogin {
|
|
466
|
+
login: string;
|
|
467
|
+
password: string;
|
|
468
|
+
blob_id?: number;
|
|
469
|
+
custom_data?: string;
|
|
470
|
+
email?: string;
|
|
471
|
+
external_user_id?: string | number;
|
|
472
|
+
facebook_id?: string;
|
|
473
|
+
full_name?: string;
|
|
474
|
+
phone?: string;
|
|
475
|
+
tag_list?: string | string[];
|
|
476
|
+
twitter_id?: string;
|
|
477
|
+
website?: string;
|
|
478
|
+
}
|
|
479
|
+
|
|
480
|
+
interface QBCreateUserWithEmail {
|
|
481
|
+
email: string;
|
|
482
|
+
password: string;
|
|
483
|
+
blob_id?: number;
|
|
484
|
+
custom_data?: string;
|
|
485
|
+
external_user_id?: string | number;
|
|
486
|
+
facebook_id?: string;
|
|
487
|
+
full_name?: string;
|
|
488
|
+
login?: string;
|
|
489
|
+
phone?: string;
|
|
490
|
+
tag_list?: string | string[];
|
|
491
|
+
twitter_id?: string;
|
|
492
|
+
website?: string;
|
|
493
|
+
}
|
|
494
|
+
|
|
495
|
+
type QBCreateUserParams = QBCreateUserWithLogin | QBCreateUserWithEmail;
|
|
496
|
+
|
|
497
|
+
type GetUserParam =
|
|
498
|
+
| { login: string }
|
|
499
|
+
| { full_name: string }
|
|
500
|
+
| { facebook_id: string }
|
|
501
|
+
| { twitter_id: string }
|
|
502
|
+
| { phone: string }
|
|
503
|
+
| { email: string }
|
|
504
|
+
| { tags: string }
|
|
505
|
+
| { external: string };
|
|
506
|
+
|
|
507
|
+
type GetUserParams =
|
|
508
|
+
| GetUserParam
|
|
509
|
+
| {
|
|
510
|
+
page?: number;
|
|
511
|
+
per_page?: number;
|
|
512
|
+
};
|
|
513
|
+
|
|
514
|
+
type ListUserParams = {
|
|
515
|
+
page?: number;
|
|
516
|
+
per_page?: number;
|
|
517
|
+
filter?: Dictionary<unknown>;
|
|
518
|
+
order?: string;
|
|
519
|
+
};
|
|
520
|
+
|
|
521
|
+
interface ListUserResponse {
|
|
522
|
+
current_page: number;
|
|
523
|
+
per_page: number;
|
|
524
|
+
total_entries: number;
|
|
525
|
+
items: Array<{ user: QBUser }>;
|
|
526
|
+
}
|
|
527
|
+
|
|
528
|
+
interface QBUsersModule {
|
|
529
|
+
get(
|
|
530
|
+
params: number,
|
|
531
|
+
callback: (error?: QBError, response?: QBUser) => void,
|
|
532
|
+
): void;
|
|
533
|
+
get(
|
|
534
|
+
params: GetUserParams,
|
|
535
|
+
callback: (error?: QBError, response: ListUserResponse) => void,
|
|
536
|
+
): void;
|
|
537
|
+
listUsers(
|
|
538
|
+
params: ListUserParams,
|
|
539
|
+
callback: (error?: QBError, response: ListUserResponse) => void,
|
|
540
|
+
): void;
|
|
541
|
+
create(
|
|
542
|
+
params: QBCreateUserParams,
|
|
543
|
+
callback: (error?: QBError, user: QBUser) => void,
|
|
544
|
+
): void;
|
|
545
|
+
update(
|
|
546
|
+
userId: number,
|
|
547
|
+
user: Partial<QBUser>,
|
|
548
|
+
callback: (error?: QBError, user: QBUser) => void,
|
|
549
|
+
): void;
|
|
550
|
+
}
|
|
551
|
+
|
|
552
|
+
interface QBGetUserMediaParams {
|
|
553
|
+
audio: MediaStreamConstraints['audio'];
|
|
554
|
+
video: MediaStreamConstraints['video'];
|
|
555
|
+
/** Id attribute of HTMLVideoElement */
|
|
556
|
+
elemId?: string;
|
|
557
|
+
options?: {
|
|
558
|
+
muted?: boolean;
|
|
559
|
+
mirror?: boolean;
|
|
560
|
+
};
|
|
561
|
+
}
|
|
562
|
+
|
|
563
|
+
interface QBWebRTCSession {
|
|
564
|
+
State: {
|
|
565
|
+
NEW: 1;
|
|
566
|
+
ACTIVE: 2;
|
|
567
|
+
HUNGUP: 3;
|
|
568
|
+
REJECTED: 4;
|
|
569
|
+
CLOSED: 5;
|
|
570
|
+
};
|
|
571
|
+
ID: string;
|
|
572
|
+
/**
|
|
573
|
+
* One of {@link QBWebRTCSession#State}
|
|
574
|
+
*/
|
|
575
|
+
state: number;
|
|
576
|
+
initiatorID: number;
|
|
577
|
+
opponentsIDs: number[];
|
|
578
|
+
peerConnections: { [userId: number]: RTCPeerConnection };
|
|
579
|
+
callType: 1 | 2;
|
|
580
|
+
startCallTime?: Date;
|
|
581
|
+
localStream?: MediaStream;
|
|
582
|
+
mediaParams: QBGetUserMediaParams | null;
|
|
583
|
+
getUserMedia(
|
|
584
|
+
params: QBGetUserMediaParams,
|
|
585
|
+
callback: (error?: QBError, stream?: MediaStream) => void,
|
|
586
|
+
): void;
|
|
587
|
+
/** Attach media stream to audio/video element */
|
|
588
|
+
attachMediaStream(
|
|
589
|
+
videoElemId: string,
|
|
590
|
+
stream: MediaStream,
|
|
591
|
+
options?: QBGetUserMediaParams['options'],
|
|
592
|
+
): void;
|
|
593
|
+
/** Detach media stream from audio/video element */
|
|
594
|
+
detachMediaStream(videoElemId: string): void;
|
|
595
|
+
mute(type: 'audio' | 'video'): void;
|
|
596
|
+
unmute(type: 'audio' | 'video'): void;
|
|
597
|
+
/** Innitiate a call */
|
|
598
|
+
call(params: Dictionary<unknown>): void;
|
|
599
|
+
/** Accept call */
|
|
600
|
+
accept(params: Dictionary<unknown>): void;
|
|
601
|
+
/** Reject call */
|
|
602
|
+
reject(params: Dictionary<unknown>): void;
|
|
603
|
+
/** Stop call (Hang up) */
|
|
604
|
+
stop(params: Dictionary<unknown>): void;
|
|
605
|
+
switchMediaTracks(
|
|
606
|
+
deviceIds: { audio?: { exact: string }; video?: { exact: string } },
|
|
607
|
+
callback: (error?: QBError, stream?: MediaStream) => void,
|
|
608
|
+
): void;
|
|
609
|
+
/** Add tracks from provided stream to local stream (and replace in peers) */
|
|
610
|
+
_replaceTracks(stream: MediaStream): void;
|
|
611
|
+
}
|
|
612
|
+
|
|
613
|
+
interface QBWebRTCModule {
|
|
614
|
+
CallType: {
|
|
615
|
+
VIDEO: 1;
|
|
616
|
+
AUDIO: 2;
|
|
617
|
+
};
|
|
618
|
+
getMediaDevices(kind?: MediaDeviceKind): Promise<MediaDeviceInfo[]>;
|
|
619
|
+
createNewSession(opponentsIds: number[], callType: 1 | 2): QBWebRTCSession;
|
|
620
|
+
onAcceptCallListener?: (
|
|
621
|
+
session: QBWebRTCSession,
|
|
622
|
+
userId: number,
|
|
623
|
+
userInfo: Dictionary<unknown>,
|
|
624
|
+
) => void;
|
|
625
|
+
onCallListener?: (
|
|
626
|
+
session: QBWebRTCSession,
|
|
627
|
+
userInfo: Dictionary<unknown>,
|
|
628
|
+
) => void;
|
|
629
|
+
onCallStatsReport?: (
|
|
630
|
+
session: QBWebRTCSession,
|
|
631
|
+
userId: number,
|
|
632
|
+
stats: string[],
|
|
633
|
+
) => void;
|
|
634
|
+
onRejectCallListener?: (
|
|
635
|
+
session: QBWebRTCSession,
|
|
636
|
+
userId: number,
|
|
637
|
+
userInfo: Dictionary<unknown>,
|
|
638
|
+
) => void;
|
|
639
|
+
onRemoteStreamListener?: (
|
|
640
|
+
sesion: QBWebRTCSession,
|
|
641
|
+
userId: number,
|
|
642
|
+
stream: MediaStream,
|
|
643
|
+
) => void;
|
|
644
|
+
onSessionCloseListener?: (session: QBWebRTCSession) => void;
|
|
645
|
+
onSessionConnectionStateChangedListener?: (
|
|
646
|
+
sesion: QBWebRTCSession,
|
|
647
|
+
userId: number,
|
|
648
|
+
state: unknown,
|
|
649
|
+
) => void;
|
|
650
|
+
onStopCallListener?: (
|
|
651
|
+
session: QBWebRTCSession,
|
|
652
|
+
userId: number,
|
|
653
|
+
userInfo: Dictionary<unknown>,
|
|
654
|
+
) => void;
|
|
655
|
+
onUpdateCallListener?: (
|
|
656
|
+
session: QBWebRTCSession,
|
|
657
|
+
userId: number,
|
|
658
|
+
userInfo: Dictionary<unknown>,
|
|
659
|
+
) => void;
|
|
660
|
+
onUserNotAnswerListener?: (session: QBWebRTCSession, userId: number) => void;
|
|
661
|
+
}
|
|
662
|
+
|
|
663
|
+
type QBLoginParams =
|
|
664
|
+
| {
|
|
665
|
+
login: string;
|
|
666
|
+
password: string;
|
|
667
|
+
}
|
|
668
|
+
| {
|
|
669
|
+
email: string;
|
|
670
|
+
password: string;
|
|
671
|
+
}
|
|
672
|
+
| {
|
|
673
|
+
provider: 'firebase_phone';
|
|
674
|
+
firebase_phone: { access_token: string; project_id: string };
|
|
675
|
+
};
|
|
676
|
+
|
|
677
|
+
interface Quickblox {
|
|
678
|
+
auth: {
|
|
679
|
+
createSession: VoidFunction;
|
|
680
|
+
};
|
|
681
|
+
buildNumber: string;
|
|
682
|
+
chat: QBChatModule;
|
|
683
|
+
content: QBContentModule;
|
|
684
|
+
createSession(
|
|
685
|
+
params?: QBLoginParams,
|
|
686
|
+
callback: (error?: QBError, session: QBSession) => void,
|
|
687
|
+
): void;
|
|
688
|
+
data: QBDataModule;
|
|
689
|
+
destroySession(callback: (error?: QBError, res: unknown) => void): void;
|
|
690
|
+
getSession(
|
|
691
|
+
callback: (error?: QBError, response?: { session: QBSession }) => void,
|
|
692
|
+
): void;
|
|
693
|
+
init(
|
|
694
|
+
appIdOrToken: string | number,
|
|
695
|
+
authKeyOrAppId: string | number,
|
|
696
|
+
authSecret?: string,
|
|
697
|
+
accountKey: string,
|
|
698
|
+
config?: QBConfig,
|
|
699
|
+
): void;
|
|
700
|
+
login(
|
|
701
|
+
params: QBLoginParams,
|
|
702
|
+
callback: (error: unknown, user: QBUser) => void,
|
|
703
|
+
): void;
|
|
704
|
+
logout(callback: (error: unknown, res: unknown) => void): void;
|
|
705
|
+
service: {
|
|
706
|
+
qbInst: {
|
|
707
|
+
config: {
|
|
708
|
+
webrtc: {
|
|
709
|
+
answerTimeInterval: number;
|
|
710
|
+
};
|
|
711
|
+
endpoints: {
|
|
712
|
+
api: string;
|
|
713
|
+
};
|
|
714
|
+
urls: {
|
|
715
|
+
blobs: string;
|
|
716
|
+
type: string;
|
|
717
|
+
data: string;
|
|
718
|
+
};
|
|
719
|
+
};
|
|
720
|
+
};
|
|
721
|
+
};
|
|
722
|
+
users: QBUsersModule;
|
|
723
|
+
webrtc: QBWebRTCModule;
|
|
724
|
+
version: string;
|
|
725
|
+
}
|
|
726
|
+
|
|
727
|
+
interface QuickbloxConstructor {
|
|
728
|
+
prototype: Quickblox;
|
|
729
|
+
new (): Quickblox;
|
|
730
|
+
}
|
|
731
|
+
|
|
732
|
+
interface QB extends Quickblox {
|
|
733
|
+
QuickBlox: QuickbloxConstructor;
|
|
734
|
+
}
|
|
735
|
+
|
|
736
|
+
declare const QB: QB;
|
|
737
|
+
|
|
738
|
+
interface QBMediaRecorderConstructorProps {
|
|
739
|
+
/** Preferred MIME type */
|
|
740
|
+
mimeType?: string;
|
|
741
|
+
workerPath?: string;
|
|
742
|
+
/**
|
|
743
|
+
* The minimum number of milliseconds of data to return
|
|
744
|
+
* in a single Blob, fire 'ondataavaible' callback
|
|
745
|
+
* (isn't need to use with 'audio/wav' of 'audio/mp3')
|
|
746
|
+
*
|
|
747
|
+
* @default 1000
|
|
748
|
+
*/
|
|
749
|
+
timeslice?: number;
|
|
750
|
+
/**
|
|
751
|
+
* What to do with a muted input MediaStreamTrack,
|
|
752
|
+
* e.g. insert black frames/zero audio volume in the recording
|
|
753
|
+
* or ignore altogether
|
|
754
|
+
*
|
|
755
|
+
* @default true
|
|
756
|
+
*/
|
|
757
|
+
ignoreMutedMedia?: boolean;
|
|
758
|
+
/** Recording start event handler */
|
|
759
|
+
onstart?: VoidFunction;
|
|
760
|
+
/** Recording stop event handler */
|
|
761
|
+
onstop?: (file: Blob) => void;
|
|
762
|
+
/** Recording pause event handler */
|
|
763
|
+
onpause?: VoidFunction;
|
|
764
|
+
/** Recording resume event handler */
|
|
765
|
+
onresume?: VoidFunction;
|
|
766
|
+
/** Error event handler */
|
|
767
|
+
onerror?: (error: unknown) => void;
|
|
768
|
+
/**
|
|
769
|
+
* `dataavailable` event handler.
|
|
770
|
+
* The Blob of recorded data is contained in this event (callback
|
|
771
|
+
* isn't supported if use 'audio/wav' of 'audio/mp3' for recording)
|
|
772
|
+
*/
|
|
773
|
+
ondataavailable?: (event: { data: Blob }) => void;
|
|
774
|
+
}
|
|
775
|
+
|
|
776
|
+
interface QBMediaRecorder {
|
|
777
|
+
/**
|
|
778
|
+
* Switch recording Blob objects to the specified
|
|
779
|
+
* MIME type if `MediaRecorder` support it.
|
|
780
|
+
*/
|
|
781
|
+
toggleMimeType(mimeType: string): void;
|
|
782
|
+
/**
|
|
783
|
+
* Returns current `MediaRecorder` state
|
|
784
|
+
*/
|
|
785
|
+
getState(): 'inactive' | 'recording' | 'paused';
|
|
786
|
+
/**
|
|
787
|
+
* Starts recording a stream.
|
|
788
|
+
* Fires `onstart` callback.
|
|
789
|
+
*/
|
|
790
|
+
start(stream: MediaStream): void;
|
|
791
|
+
/**
|
|
792
|
+
* Stops recording a stream
|
|
793
|
+
*
|
|
794
|
+
* @fires `onstop` callback and passing there Blob recorded
|
|
795
|
+
*/
|
|
796
|
+
stop(): void;
|
|
797
|
+
/** Pausing stream recording */
|
|
798
|
+
pause(): void;
|
|
799
|
+
/** Resumes stream recording */
|
|
800
|
+
resume(): void;
|
|
801
|
+
/**
|
|
802
|
+
* Change record source
|
|
803
|
+
*/
|
|
804
|
+
change(stream: MediaStream): void;
|
|
805
|
+
/**
|
|
806
|
+
* Create a file from blob and download as file.
|
|
807
|
+
* This method will call `stop` if recording is in progress.
|
|
808
|
+
*
|
|
809
|
+
* @param {string} filename Name of video file to be downloaded
|
|
810
|
+
* (default to `Date.now()`)
|
|
811
|
+
*/
|
|
812
|
+
download(filename?: string): void;
|
|
813
|
+
_getBlobRecorded(): Blob;
|
|
814
|
+
callbacks: Pick<
|
|
815
|
+
QBMediaRecorderConstructorProps,
|
|
816
|
+
| 'onstart'
|
|
817
|
+
| 'onstop'
|
|
818
|
+
| 'onpause'
|
|
819
|
+
| 'onresume'
|
|
820
|
+
| 'ondataavailable'
|
|
821
|
+
| 'onerror'
|
|
822
|
+
>;
|
|
823
|
+
}
|
|
824
|
+
|
|
825
|
+
declare const QBMediaRecorder: {
|
|
826
|
+
/**
|
|
827
|
+
* Checks capability of recording in the environment.
|
|
828
|
+
* Checks `MediaRecorder`, `MediaRecorder.isTypeSupported` and `Blob`.
|
|
829
|
+
*/
|
|
830
|
+
isAvailable(): boolean;
|
|
831
|
+
/**
|
|
832
|
+
* Checks if AudioContext API is available.
|
|
833
|
+
* Checks `window.AudioContext` or `window.webkitAudioContext`.
|
|
834
|
+
*/
|
|
835
|
+
isAudioContext(): boolean;
|
|
836
|
+
/**
|
|
837
|
+
* The `QBMediaRecorder.isTypeSupported()` static method returns
|
|
838
|
+
* a Boolean which is true if the MIME type specified is one
|
|
839
|
+
* the user agent should be able to successfully record.
|
|
840
|
+
* @param mimeType The MIME media type to check.
|
|
841
|
+
*
|
|
842
|
+
* @returns true if the `MediaRecorder` implementation is capable of
|
|
843
|
+
* recording `Blob` objects for the specified MIME type. Recording may
|
|
844
|
+
* still fail if there are insufficient resources to support the
|
|
845
|
+
* recording and encoding process. If the value is false, the user
|
|
846
|
+
* agent is incapable of recording the specified format.
|
|
847
|
+
*/
|
|
848
|
+
isTypeSupported(mimeType: string): boolean;
|
|
849
|
+
/**
|
|
850
|
+
* Return supported mime types
|
|
851
|
+
* @param type video or audio (dafault to 'video')
|
|
852
|
+
*/
|
|
853
|
+
getSupportedMimeTypes(type: 'audio' | 'video' = 'video'): string[];
|
|
854
|
+
new (config: QBMediaRecorderConstructorProps): QBMediaRecorder;
|
|
855
|
+
};
|