quickblox-react-ui-kit 0.2.7-beta.1 → 0.2.7-release-final
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/Data/Creator.d.ts +30 -0
- package/dist/Data/Stubs.d.ts +3 -3
- package/dist/Data/dto/message/RemoteMessageDTO.d.ts +1 -1
- package/dist/Data/dto/user/LocalUserDTO.d.ts +1 -1
- package/dist/Data/dto/user/RemoteUserDTO.d.ts +1 -1
- package/dist/Data/source/exception/RepositoryException.d.ts +1 -1
- package/dist/Data/source/remote/Mapper/MessageDTOMapper.d.ts +2 -2
- package/dist/Domain/entity/MessageEntity.d.ts +1 -1
- package/dist/Domain/entity/UserEntity.d.ts +1 -0
- package/dist/Presentation/Views/Dialog/AIComponents/AIAssistComponent/AIAssistComponent.d.ts +4 -3
- package/dist/Presentation/Views/Dialog/AIComponents/AITranslateComponent/AITranslateComponent.d.ts +4 -3
- package/dist/Presentation/Views/Dialog/AIWidgets/AIRephraseWidget/AIRephraseWidget.d.ts +1 -0
- package/dist/Presentation/Views/Dialog/{AttachmentMessage/AttachmentMessage.d.ts → AttachmentUploader/AttachmentUploader.d.ts} +2 -2
- package/dist/Presentation/Views/Dialog/ForwardMessageFlow/DialogsWithSearch/{ItemForListComponent/ItemDialogList.d.ts → DialogListItem/DialogListItem.d.ts} +8 -8
- package/dist/Presentation/Views/Dialog/Message/IncomingForwardedMessage/IncomingForwardedMessage.d.ts +27 -0
- package/dist/Presentation/Views/Dialog/{IncomingMessage → Message/IncomingMessage}/IncomingMessage.d.ts +6 -5
- package/dist/Presentation/Views/Dialog/Message/IncomingMessage/MessageContentComponent/MessageContentComponent.d.ts +11 -0
- package/dist/Presentation/Views/Dialog/Message/IncomingRepliedMessage/IncomingRepliedMessage.d.ts +27 -0
- package/dist/Presentation/Views/Dialog/Message/MessageAttachment/AudioAttachment/AudioAttachment.d.ts +8 -0
- package/dist/Presentation/Views/Dialog/Message/MessageAttachment/DefaultAttachment/DefaultAttachment.d.ts +8 -0
- package/dist/Presentation/Views/Dialog/Message/MessageAttachment/ImageAttachment/ImageAttachment.d.ts +8 -0
- package/dist/Presentation/Views/Dialog/Message/MessageAttachment/MessageAttachment.d.ts +11 -0
- package/dist/Presentation/Views/Dialog/Message/MessageAttachment/VideoAttachment/VideoAttachment.d.ts +8 -0
- package/dist/Presentation/Views/Dialog/Message/MessageContextMenu/MessageContextMenu.d.ts +15 -0
- package/dist/Presentation/Views/Dialog/Message/OutgoinForwardedMessage/OutgoinForwardedMessage.d.ts +18 -0
- package/dist/Presentation/Views/Dialog/{ContextMenu/MessageContextMenu/MessageContextMenu.d.ts → Message/OutgoingMessage/OutgoingMessage.d.ts} +6 -5
- package/dist/Presentation/Views/Dialog/Message/OutgoingRepliedMessage/OutgoingRepliedMessage.d.ts +16 -0
- package/dist/Presentation/components/UI/svgs/ActiveSvg/ActiveSvg.d.ts +2 -2
- package/dist/Presentation/components/containers/SectionList/hooks/createUseComponent.d.ts +3 -0
- package/dist/Presentation/components/containers/SectionList/hooks/index.d.ts +4 -0
- package/dist/Presentation/components/containers/SectionList/hooks/useMobileLayout.d.ts +1 -0
- package/dist/Presentation/components/containers/SectionList/hooks/usePrevious.d.ts +1 -0
- package/dist/Presentation/components/containers/SectionList/hooks/useVisibility.d.ts +1 -0
- package/dist/Presentation/components/containers/SectionList/index.d.ts +4 -0
- package/dist/Presentation/components/containers/SectionList/useComponent.d.ts +28 -0
- package/dist/index-ui.d.ts +2 -2
- package/dist/index-ui.js +501 -325
- package/dist/utils/DateTimeFormatter.d.ts +1 -0
- package/global.d.ts +4 -5
- package/package.json +2 -2
- package/dist/Presentation/Views/Dialog/AudioAttachmentComponent/AudioAttachmentComponent.d.ts +0 -8
- package/dist/Presentation/Views/Dialog/DefaultAttachmentComponent/DefaultAttachmentComponent.d.ts +0 -8
- package/dist/Presentation/Views/Dialog/ImageAttachmentComponent/ImageAttachmentComponent.d.ts +0 -8
- package/dist/Presentation/Views/Dialog/IncomingForwardedRepliedMessage/IncomingForwardedRepliedMessage.d.ts +0 -25
- package/dist/Presentation/Views/Dialog/IncomingMessage/AttachmentContentComponent/AttachmentContentComponent.d.ts +0 -8
- package/dist/Presentation/Views/Dialog/IncomingMessage/MessageContentComponent/MessageContentComponent.d.ts +0 -10
- package/dist/Presentation/Views/Dialog/OutgoingForwardedRepliedMessage/OutgoingForwardedRepliedMessage.d.ts +0 -17
- package/dist/Presentation/Views/Dialog/OutgoingMessage/OutgoingMessage.d.ts +0 -14
- package/dist/Presentation/Views/Dialog/VideoAttachmentComponent/VideoAttachmentComponent.d.ts +0 -8
- /package/dist/Presentation/Views/Dialog/{HighLightLink → Message/HighLightLink}/HighLightLink.d.ts +0 -0
- /package/dist/Presentation/Views/Dialog/{IncomingMessage → Message/IncomingMessage}/AvatarContentIncomingUser/AvatarContentIncomingUser.d.ts +0 -0
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import ChatMessageAttachmentEntity from '../Domain/entity/ChatMessageAttachmentEntity';
|
|
2
|
+
import { DialogType } from '../Domain/entity/DialogTypes';
|
|
3
|
+
import { MessageEntity } from '../Domain/entity/MessageEntity';
|
|
4
|
+
import { FileEntity } from '../Domain/entity/FileEntity';
|
|
5
|
+
export type MessageEntityParams = {
|
|
6
|
+
id?: string;
|
|
7
|
+
dialogId: string;
|
|
8
|
+
message: string;
|
|
9
|
+
created_at?: string;
|
|
10
|
+
date_sent?: number;
|
|
11
|
+
updated_at?: string;
|
|
12
|
+
delivered_ids?: Array<number>;
|
|
13
|
+
read_ids?: Array<number>;
|
|
14
|
+
read?: number;
|
|
15
|
+
sender_id: number;
|
|
16
|
+
recipient_id: number;
|
|
17
|
+
attachments?: ChatMessageAttachmentEntity[];
|
|
18
|
+
notification_type?: string;
|
|
19
|
+
dialog_type?: DialogType;
|
|
20
|
+
};
|
|
21
|
+
export declare class Creator {
|
|
22
|
+
static createPhotoByBlob: (blob_id: number | string | null) => Promise<string>;
|
|
23
|
+
static createBlobFromUrl(imageSrc: string): Promise<{
|
|
24
|
+
imgSrc: string;
|
|
25
|
+
blobFile: Blob | undefined;
|
|
26
|
+
}>;
|
|
27
|
+
private static getInfoPromise;
|
|
28
|
+
static createMessageEntity(params: MessageEntityParams): MessageEntity;
|
|
29
|
+
static createFileEntity(): FileEntity;
|
|
30
|
+
}
|
package/dist/Data/Stubs.d.ts
CHANGED
|
@@ -7,6 +7,8 @@ import ChatMessageAttachmentEntity from '../Domain/entity/ChatMessageAttachmentE
|
|
|
7
7
|
import { LocalDataSource } from './source/local/LocalDataSource';
|
|
8
8
|
import { FileEntity } from '../Domain/entity/FileEntity';
|
|
9
9
|
export declare class Stubs {
|
|
10
|
+
static createMessageEntityWithParams(id: string, dialogId: string, message: string, created_at: string, date_sent: number, updated_at: string, delivered_ids: Array<number>, read_ids: Array<number>, read: number, sender_id: number, recipient_id: number, attachments?: ChatMessageAttachmentEntity[], notification_type?: string, dialog_type?: DialogType): MessageEntity;
|
|
11
|
+
static createFileEntityWithDefaultValues(): FileEntity;
|
|
10
12
|
static initializeWithUsersMockData(ds: LocalDataSource): Promise<void>;
|
|
11
13
|
static initializeWithDialogsMockData(ds: LocalDataSource): Promise<void>;
|
|
12
14
|
static initializeWithMessagesMockData(ds: LocalDataSource): Promise<void>;
|
|
@@ -20,10 +22,8 @@ export declare class Stubs {
|
|
|
20
22
|
static createPrivateDialogQBWithEmptyValues(): QBChatDialog;
|
|
21
23
|
static createGroupDialogQBWithEmptyValues(): QBChatDialog;
|
|
22
24
|
static createDialogEntityWithParams(dialogType: DialogType, id: string, name: string, dateSentLastMessage: string, textLastMessage: string, userIdLastMessage: number, ownerId: string, unreadMessageCount: number, updatedAt: string, participantId: number, photo?: string, participantIds?: number[]): DialogEntity;
|
|
23
|
-
static createUserEntityWithParams(id: number, full_name: string, email: string, login: string, created_at: string, updated_at: string, last_request_at: string, custom_data?: string | null, user_tags?: string | null, blob_id?: string): UserEntity;
|
|
24
|
-
static createMessageEntityWithParams(id: string, dialogId: string, message: string, created_at: string, date_sent: number, updated_at: string, delivered_ids: Array<number>, read_ids: Array<number>, read: number, sender_id: number, recipient_id: number, attachments?: ChatMessageAttachmentEntity[], notification_type?: string, dialog_type?: DialogType): MessageEntity;
|
|
25
|
+
static createUserEntityWithParams(id: number, full_name: string, email: string, login: string, created_at: string, updated_at: string, last_request_at: string, custom_data?: string | null, user_tags?: string | null, blob_id?: string, photo?: string): UserEntity;
|
|
25
26
|
static createDialogsForTest(): Array<DialogEntity>;
|
|
26
27
|
static createUsersForTest(): Array<UserEntity>;
|
|
27
28
|
static createMessagesForTest(): Array<MessageEntity>;
|
|
28
|
-
static createFileEntityWithDefaultValues(): FileEntity;
|
|
29
29
|
}
|
|
@@ -16,7 +16,7 @@ export declare class RemoteMessageDTO {
|
|
|
16
16
|
dialog_type?: DialogType;
|
|
17
17
|
markable?: string;
|
|
18
18
|
attachments: ChatMessageAttachmentEntity[];
|
|
19
|
-
qb_message_action?:
|
|
19
|
+
qb_message_action?: 'forward' | 'reply';
|
|
20
20
|
origin_sender_name?: string;
|
|
21
21
|
qb_original_messages?: RemoteMessageDTO[];
|
|
22
22
|
constructor();
|
|
@@ -6,7 +6,7 @@ export declare const DIALOG_ENTITY_REPOSITORY_EXCEPTION_MESSAGE = "Error. Dialog
|
|
|
6
6
|
export declare const DIALOG_ENTITY_REPOSITORY_EXCEPTION_CODE = 103;
|
|
7
7
|
export declare const MESSAGE_ENTITY_REPOSITORY_EXCEPTION_MESSAGE = "Error. MessageId raise Message Entity exception.";
|
|
8
8
|
export declare const MESSAGE_ENTITY_REPOSITORY_EXCEPTION_CODE = 103;
|
|
9
|
-
export declare const FILE_ENTITY_REPOSITORY_EXCEPTION_MESSAGE = "Error.
|
|
9
|
+
export declare const FILE_ENTITY_REPOSITORY_EXCEPTION_MESSAGE = "Error. id raise File Entity exception.";
|
|
10
10
|
export declare const FILE_ENTITY_REPOSITORY_EXCEPTION_CODE = 104;
|
|
11
11
|
export default class RepositoryException extends Error {
|
|
12
12
|
message: string;
|
|
@@ -8,8 +8,8 @@ export declare class MessageDTOMapper implements IDTOMapper {
|
|
|
8
8
|
private QBChatMessageToRemoteMessageDTO;
|
|
9
9
|
static convertAttachment(attachment: ChatMessageAttachmentEntity): ChatMessageAttachment;
|
|
10
10
|
static convertToQBChatNewMessage(messages: RemoteMessageDTO[]): QBChatMessage[];
|
|
11
|
-
static translateOriginalDataToJSON(qb_original_message
|
|
12
|
-
static translateJSONToOriginalData(json_data
|
|
11
|
+
static translateOriginalDataToJSON(qb_original_message?: QBChatMessage[]): string;
|
|
12
|
+
static translateJSONToOriginalData(json_data?: string): QBChatMessage[] | undefined;
|
|
13
13
|
static formatMessage(qbMessage: string): string;
|
|
14
14
|
private static getMessageParts;
|
|
15
15
|
private static validateDTO;
|
package/dist/Presentation/Views/Dialog/AIComponents/AIAssistComponent/AIAssistComponent.d.ts
CHANGED
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import './AIAssistComponent.scss';
|
|
3
3
|
import { FunctionTypeVoidToVoid } from '../../../../../CommonTypes/BaseViewModel';
|
|
4
|
-
|
|
4
|
+
interface AIAssistComponentProps {
|
|
5
5
|
onAssistAnswer: FunctionTypeVoidToVoid;
|
|
6
6
|
waitAIWidget: boolean;
|
|
7
|
-
}
|
|
8
|
-
export default AIAssistComponent;
|
|
7
|
+
}
|
|
8
|
+
export default function AIAssistComponent(props: AIAssistComponentProps): JSX.Element;
|
|
9
|
+
export {};
|
package/dist/Presentation/Views/Dialog/AIComponents/AITranslateComponent/AITranslateComponent.d.ts
CHANGED
|
@@ -1,11 +1,12 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import './AITranslateComponent.scss';
|
|
3
3
|
import { FunctionTypeStringToVoid, FunctionTypeVoidToVoid } from '../../../../../CommonTypes/BaseViewModel';
|
|
4
|
-
|
|
4
|
+
interface AITranslateComponentProps {
|
|
5
5
|
onTranslate: FunctionTypeStringToVoid;
|
|
6
6
|
onClickOriginalText: FunctionTypeVoidToVoid;
|
|
7
7
|
originalTextMessage: boolean;
|
|
8
8
|
waitAITranslateWidget: boolean;
|
|
9
9
|
languagesForAITranslate: string[];
|
|
10
|
-
}
|
|
11
|
-
export default AITranslateComponent;
|
|
10
|
+
}
|
|
11
|
+
export default function AITranslateComponent(props: AITranslateComponentProps): JSX.Element;
|
|
12
|
+
export {};
|
|
@@ -17,6 +17,7 @@ type AIRephraseWidgetProps = {
|
|
|
17
17
|
maxTokensForAIRephrase: number;
|
|
18
18
|
rephraseTones: Tone[];
|
|
19
19
|
theme?: UiKitTheme;
|
|
20
|
+
setPrevValueText: FunctionTypeStringToVoid;
|
|
20
21
|
};
|
|
21
22
|
declare const AIRephraseWidget: React.FC<AIRephraseWidgetProps>;
|
|
22
23
|
export default AIRephraseWidget;
|
|
@@ -3,5 +3,5 @@ type AttachmentMessageProps = {
|
|
|
3
3
|
icon: React.ReactNode;
|
|
4
4
|
onChangeFile: (event: React.ChangeEvent<HTMLInputElement>) => void;
|
|
5
5
|
};
|
|
6
|
-
declare const
|
|
7
|
-
export default
|
|
6
|
+
declare const AttachmentUploader: React.FC<AttachmentMessageProps>;
|
|
7
|
+
export default AttachmentUploader;
|
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import './
|
|
2
|
+
import './DialogListItem.scss';
|
|
3
3
|
import { FunctionTypeStringToVoid } from '../../../../../../CommonTypes/BaseViewModel';
|
|
4
4
|
import { DialogType } from '../../../../../../Domain/entity/DialogTypes';
|
|
5
|
-
type
|
|
6
|
-
|
|
7
|
-
|
|
5
|
+
type DialogListItemProps = {
|
|
6
|
+
name: string;
|
|
7
|
+
avatar: string;
|
|
8
8
|
typeDialog: DialogType;
|
|
9
|
-
|
|
10
|
-
|
|
9
|
+
id: string;
|
|
10
|
+
checked: boolean;
|
|
11
11
|
onSelect: FunctionTypeStringToVoid;
|
|
12
12
|
};
|
|
13
|
-
declare const
|
|
14
|
-
export default
|
|
13
|
+
declare const DialogListItem: React.FC<DialogListItemProps>;
|
|
14
|
+
export default DialogListItem;
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import './IncomingForwardedMessage.scss';
|
|
3
|
+
import { AvatarContentIncomingUserProps } from '../IncomingMessage/AvatarContentIncomingUser/AvatarContentIncomingUser';
|
|
4
|
+
import UiKitTheme from '../../../../themes/UiKitTheme';
|
|
5
|
+
import { MessageEntity } from '../../../../../Domain/entity/MessageEntity';
|
|
6
|
+
import { FunctionTypeMessageEntityToVoid } from '../../../../../CommonTypes/BaseViewModel';
|
|
7
|
+
import { AIMessageWidget } from '../../AIWidgets/AIMessageWidget';
|
|
8
|
+
declare function IncomingForwardedMessage(props: {
|
|
9
|
+
theme?: UiKitTheme;
|
|
10
|
+
messages: MessageEntity[];
|
|
11
|
+
date_sent: string;
|
|
12
|
+
userIconRenderer?: (props: AvatarContentIncomingUserProps) => React.ReactElement;
|
|
13
|
+
onReply: FunctionTypeMessageEntityToVoid;
|
|
14
|
+
onForward: FunctionTypeMessageEntityToVoid;
|
|
15
|
+
repliedUserName: string;
|
|
16
|
+
renderOringinalMessage: React.ReactNode;
|
|
17
|
+
AITranslation?: AIMessageWidget;
|
|
18
|
+
AIAnswerToMessage?: AIMessageWidget;
|
|
19
|
+
onStartLoader: () => void;
|
|
20
|
+
onStopLoader: () => void;
|
|
21
|
+
onErrorToast: (messageError: string) => void;
|
|
22
|
+
currentUserId?: number;
|
|
23
|
+
messagesToView: MessageEntity[];
|
|
24
|
+
enableForwarding: boolean;
|
|
25
|
+
enableReplying: boolean;
|
|
26
|
+
}): JSX.Element;
|
|
27
|
+
export default IncomingForwardedMessage;
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import './IncomingMessage.scss';
|
|
3
|
-
import UiKitTheme from '
|
|
4
|
-
import { MessageEntity } from '
|
|
5
|
-
import { AIMessageWidget } from '
|
|
6
|
-
import { UserEntity } from '
|
|
3
|
+
import UiKitTheme from '../../../../themes/UiKitTheme';
|
|
4
|
+
import { MessageEntity } from '../../../../../Domain/entity/MessageEntity';
|
|
5
|
+
import { AIMessageWidget } from '../../AIWidgets/AIMessageWidget';
|
|
6
|
+
import { UserEntity } from '../../../../../Domain/entity/UserEntity';
|
|
7
7
|
import { AvatarContentIncomingUserProps } from './AvatarContentIncomingUser/AvatarContentIncomingUser';
|
|
8
|
-
import { FunctionTypeMessageEntityToVoid } from '
|
|
8
|
+
import { FunctionTypeMessageEntityToVoid } from '../../../../../CommonTypes/BaseViewModel';
|
|
9
9
|
export type GetUserNameFct = (props: {
|
|
10
10
|
userId?: number;
|
|
11
11
|
sender?: UserEntity;
|
|
@@ -14,6 +14,7 @@ export declare function IncomingMessage(props: {
|
|
|
14
14
|
theme: UiKitTheme | undefined;
|
|
15
15
|
senderNameFct: GetUserNameFct;
|
|
16
16
|
message: MessageEntity;
|
|
17
|
+
date_sent: string;
|
|
17
18
|
onReply: FunctionTypeMessageEntityToVoid;
|
|
18
19
|
onForward: FunctionTypeMessageEntityToVoid;
|
|
19
20
|
onStartLoader: () => void;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { FC } from 'react';
|
|
2
|
+
import { MessageEntity } from '../../../../../../Domain/entity/MessageEntity';
|
|
3
|
+
import UiKitTheme from '../../../../../themes/UiKitTheme';
|
|
4
|
+
type MessageContentComponentProps = {
|
|
5
|
+
messageEntity: MessageEntity;
|
|
6
|
+
originalTextMessage: boolean;
|
|
7
|
+
widgetTextContent: string;
|
|
8
|
+
theme?: UiKitTheme;
|
|
9
|
+
};
|
|
10
|
+
declare const MessageContentComponent: FC<MessageContentComponentProps>;
|
|
11
|
+
export default MessageContentComponent;
|
package/dist/Presentation/Views/Dialog/Message/IncomingRepliedMessage/IncomingRepliedMessage.d.ts
ADDED
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import './IncomingRepliedMessage.scss';
|
|
3
|
+
import UiKitTheme from '../../../../themes/UiKitTheme';
|
|
4
|
+
import { MessageEntity } from '../../../../../Domain/entity/MessageEntity';
|
|
5
|
+
import { FunctionTypeMessageEntityToVoid } from '../../../../../CommonTypes/BaseViewModel';
|
|
6
|
+
import { AIMessageWidget } from '../../AIWidgets/AIMessageWidget';
|
|
7
|
+
import { AvatarContentIncomingUserProps } from '../IncomingMessage/AvatarContentIncomingUser/AvatarContentIncomingUser';
|
|
8
|
+
declare function IncomingRepliedMessage(props: {
|
|
9
|
+
theme: UiKitTheme | undefined;
|
|
10
|
+
messages: MessageEntity[];
|
|
11
|
+
date_sent?: string;
|
|
12
|
+
userIconRenderer?: (props: AvatarContentIncomingUserProps) => React.ReactElement;
|
|
13
|
+
onReply: FunctionTypeMessageEntityToVoid;
|
|
14
|
+
onForward: FunctionTypeMessageEntityToVoid;
|
|
15
|
+
repliedUserName: string;
|
|
16
|
+
renderOringinalMessage: React.ReactNode;
|
|
17
|
+
AITranslation?: AIMessageWidget;
|
|
18
|
+
AIAnswerToMessage?: AIMessageWidget;
|
|
19
|
+
onStartLoader: () => void;
|
|
20
|
+
onStopLoader: () => void;
|
|
21
|
+
onErrorToast: (messageError: string) => void;
|
|
22
|
+
currentUserId?: number;
|
|
23
|
+
messagesToView: MessageEntity[];
|
|
24
|
+
enableForwarding: boolean;
|
|
25
|
+
enableReplying: boolean;
|
|
26
|
+
}): JSX.Element;
|
|
27
|
+
export default IncomingRepliedMessage;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import './AudioAttachment.scss';
|
|
3
|
+
import { FileEntity } from '../../../../../../Domain/entity/FileEntity';
|
|
4
|
+
type AudioAttachmentComponentProps = {
|
|
5
|
+
audioFile: FileEntity;
|
|
6
|
+
};
|
|
7
|
+
declare const AudioAttachment: React.FC<AudioAttachmentComponentProps>;
|
|
8
|
+
export default AudioAttachment;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import './ImageAttachment.scss';
|
|
3
|
+
import { FileEntity } from '../../../../../../Domain/entity/FileEntity';
|
|
4
|
+
type ImageAttachmentComponentProps = {
|
|
5
|
+
imageFile: FileEntity;
|
|
6
|
+
};
|
|
7
|
+
declare const ImageAttachment: React.FC<ImageAttachmentComponentProps>;
|
|
8
|
+
export default ImageAttachment;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import ChatMessageAttachmentEntity from '../../../../../Domain/entity/ChatMessageAttachmentEntity';
|
|
3
|
+
import UiKitTheme from '../../../../themes/UiKitTheme';
|
|
4
|
+
type AttachmentProps = {
|
|
5
|
+
attachment: ChatMessageAttachmentEntity;
|
|
6
|
+
};
|
|
7
|
+
type AttachmentContentComponentProps = AttachmentProps & {
|
|
8
|
+
theme?: UiKitTheme;
|
|
9
|
+
};
|
|
10
|
+
declare function MessageAttachment({ attachment, theme, }: AttachmentContentComponentProps): JSX.Element;
|
|
11
|
+
export default MessageAttachment;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import './VideoAttachment.scss';
|
|
3
|
+
import { FileEntity } from '../../../../../../Domain/entity/FileEntity';
|
|
4
|
+
type VideoAttachmentComponentProps = {
|
|
5
|
+
videoFile: FileEntity;
|
|
6
|
+
};
|
|
7
|
+
declare const VideoAttachment: React.FC<VideoAttachmentComponentProps>;
|
|
8
|
+
export default VideoAttachment;
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import './MessageContextMenu.scss';
|
|
3
|
+
import UiKitTheme from '../../../../themes/UiKitTheme';
|
|
4
|
+
import { MessageEntity } from '../../../../../Domain/entity/MessageEntity';
|
|
5
|
+
import { FunctionTypeMessageEntityToVoid } from '../../../../../CommonTypes/BaseViewModel';
|
|
6
|
+
interface MessageContextMenuProps {
|
|
7
|
+
theme?: UiKitTheme;
|
|
8
|
+
message: MessageEntity;
|
|
9
|
+
onReply: FunctionTypeMessageEntityToVoid;
|
|
10
|
+
onForward: FunctionTypeMessageEntityToVoid;
|
|
11
|
+
enableForwarding: boolean;
|
|
12
|
+
enableReplying: boolean;
|
|
13
|
+
}
|
|
14
|
+
export default function MessageContextMenu(props: MessageContextMenuProps): JSX.Element;
|
|
15
|
+
export {};
|
package/dist/Presentation/Views/Dialog/Message/OutgoinForwardedMessage/OutgoinForwardedMessage.d.ts
ADDED
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import './OutgoinForwardedMessage.scss';
|
|
3
|
+
import UiKitTheme from '../../../../themes/UiKitTheme';
|
|
4
|
+
import { MessageEntity } from '../../../../../Domain/entity/MessageEntity';
|
|
5
|
+
import { FunctionTypeMessageEntityToVoid } from '../../../../../CommonTypes/BaseViewModel';
|
|
6
|
+
declare function OutgoingForwardedMessage(props: {
|
|
7
|
+
theme: UiKitTheme | undefined;
|
|
8
|
+
messages: MessageEntity[];
|
|
9
|
+
onReply: FunctionTypeMessageEntityToVoid;
|
|
10
|
+
onForward: FunctionTypeMessageEntityToVoid;
|
|
11
|
+
repliedUserName: string;
|
|
12
|
+
renderOringinalMessage: React.ReactNode;
|
|
13
|
+
date_sent: string;
|
|
14
|
+
status_message: number;
|
|
15
|
+
enableForwarding: boolean;
|
|
16
|
+
enableReplying: boolean;
|
|
17
|
+
}): JSX.Element;
|
|
18
|
+
export default OutgoingForwardedMessage;
|
|
@@ -1,14 +1,15 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
import './
|
|
3
|
-
import UiKitTheme from '../../../../themes/UiKitTheme';
|
|
2
|
+
import './OutgoingMessage.scss';
|
|
4
3
|
import { MessageEntity } from '../../../../../Domain/entity/MessageEntity';
|
|
4
|
+
import UiKitTheme from '../../../../themes/UiKitTheme';
|
|
5
5
|
import { FunctionTypeMessageEntityToVoid } from '../../../../../CommonTypes/BaseViewModel';
|
|
6
|
-
declare function
|
|
7
|
-
theme: UiKitTheme | undefined;
|
|
6
|
+
export declare function OutgoingMessage(props: {
|
|
8
7
|
message: MessageEntity;
|
|
8
|
+
date_sent: string;
|
|
9
9
|
onReply: FunctionTypeMessageEntityToVoid;
|
|
10
10
|
onForward: FunctionTypeMessageEntityToVoid;
|
|
11
|
+
theme: UiKitTheme | undefined;
|
|
12
|
+
element: JSX.Element;
|
|
11
13
|
enableForwarding: boolean;
|
|
12
14
|
enableReplying: boolean;
|
|
13
15
|
}): JSX.Element;
|
|
14
|
-
export default MessageContextMenu;
|
package/dist/Presentation/Views/Dialog/Message/OutgoingRepliedMessage/OutgoingRepliedMessage.d.ts
ADDED
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import './OutgoingRepliedMessage.scss';
|
|
3
|
+
import UiKitTheme from '../../../../themes/UiKitTheme';
|
|
4
|
+
import { MessageEntity } from '../../../../../Domain/entity/MessageEntity';
|
|
5
|
+
import { FunctionTypeMessageEntityToVoid } from '../../../../../CommonTypes/BaseViewModel';
|
|
6
|
+
declare function OutgoingRepliedMessage(props: {
|
|
7
|
+
theme: UiKitTheme | undefined;
|
|
8
|
+
messages: MessageEntity[];
|
|
9
|
+
onReply: FunctionTypeMessageEntityToVoid;
|
|
10
|
+
onForward: FunctionTypeMessageEntityToVoid;
|
|
11
|
+
repliedUserName: string;
|
|
12
|
+
renderOringinalMessage: React.ReactNode;
|
|
13
|
+
enableForwarding: boolean;
|
|
14
|
+
enableReplying: boolean;
|
|
15
|
+
}): JSX.Element;
|
|
16
|
+
export default OutgoingRepliedMessage;
|
|
@@ -3,8 +3,8 @@ import { FunctionTypeVoidToVoid } from '../../../../../CommonTypes/BaseViewModel
|
|
|
3
3
|
import './ActiveSvg.scss';
|
|
4
4
|
type ActiveSvgContainerProps = {
|
|
5
5
|
content: React.ReactNode;
|
|
6
|
-
|
|
7
|
-
|
|
6
|
+
onTouch?: FunctionTypeVoidToVoid;
|
|
7
|
+
onClick?: FunctionTypeVoidToVoid;
|
|
8
8
|
};
|
|
9
9
|
declare const ActiveSvg: React.FC<ActiveSvgContainerProps>;
|
|
10
10
|
export default ActiveSvg;
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
type TUseComponent<P, R, S, D, F, A, H> = (props: P) => (R extends undefined ? unknown : Record<'refs', R>) & (S extends undefined ? unknown : Record<'store', S>) & (D extends undefined ? unknown : Record<'data', D>) & (F extends undefined ? unknown : Record<'forms', F>) & (A extends undefined ? unknown : Record<'actions', A>) & (H extends undefined ? unknown : Record<'handlers', H>);
|
|
2
|
+
export default function createUseComponent<P = void, R = undefined, S = undefined, D = undefined, F = undefined, A = undefined, H = undefined>(useComponent: TUseComponent<P, R, S, D, F, A, H>): TUseComponent<P, R, S, D, F, A, H>;
|
|
3
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export default function useMobileLayout(): boolean;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export default function usePrevious<T>(value: T): T | undefined;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export default function useVisibility(): boolean;
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import { ReactNode } from 'react';
|
|
2
|
+
export interface SectionItem<T> {
|
|
3
|
+
title: string;
|
|
4
|
+
data: Dictionary<T[]>;
|
|
5
|
+
}
|
|
6
|
+
export interface SectionListProps<T> {
|
|
7
|
+
className?: string;
|
|
8
|
+
refreshing?: boolean;
|
|
9
|
+
resetScroll?: boolean;
|
|
10
|
+
sections: ReadonlyArray<SectionItem<T>>;
|
|
11
|
+
onEndReached: VoidFunction;
|
|
12
|
+
/**
|
|
13
|
+
* How far from the end (in units of visible length of the list) the bottom edge of the
|
|
14
|
+
* list must be from the end of the content to trigger the `onEndReached` callback.
|
|
15
|
+
* Thus a value of 0.5 will trigger `onEndReached` when the end of the content is
|
|
16
|
+
* within half the visible length of the list.
|
|
17
|
+
*/
|
|
18
|
+
onEndReachedThreshold?: number;
|
|
19
|
+
renderItem: (item: [string, T[]]) => ReactNode;
|
|
20
|
+
renderSectionHeader?: (section: SectionItem<T>) => ReactNode;
|
|
21
|
+
renderSectionFooter?: (section: SectionItem<T>) => ReactNode;
|
|
22
|
+
}
|
|
23
|
+
declare const _default: <T>(props: SectionListProps<T>) => Record<"refs", {
|
|
24
|
+
listContentRef: import("react").RefObject<HTMLDivElement>;
|
|
25
|
+
}> & Record<"handlers", {
|
|
26
|
+
scrollHandler: () => void;
|
|
27
|
+
}>;
|
|
28
|
+
export default _default;
|
package/dist/index-ui.d.ts
CHANGED
|
@@ -29,7 +29,7 @@ import { AISource, IChatMessage } from './Data/source/AISource';
|
|
|
29
29
|
import AIWidgetIcon from './Presentation/components/UI/svgs/Icons/AIWidgets/AIWidget';
|
|
30
30
|
import ErrorMessageIcon from './Presentation/Views/Dialog/AIWidgets/ErrorMessageIcon';
|
|
31
31
|
import PreviewDialogViewModel from './Presentation/Views/PreviewDialog/PreviewDialogViewModel';
|
|
32
|
-
import { AvatarContentIncomingUserProps } from './Presentation/Views/Dialog/IncomingMessage/AvatarContentIncomingUser/AvatarContentIncomingUser';
|
|
32
|
+
import { AvatarContentIncomingUserProps } from './Presentation/Views/Dialog/Message/IncomingMessage/AvatarContentIncomingUser/AvatarContentIncomingUser';
|
|
33
33
|
import { FunctionTypeViewModelToVoid } from './CommonTypes/BaseViewModel';
|
|
34
|
-
import { GetUserNameFct } from './Presentation/Views/Dialog/IncomingMessage/IncomingMessage';
|
|
34
|
+
import { GetUserNameFct } from './Presentation/Views/Dialog/Message/IncomingMessage/IncomingMessage';
|
|
35
35
|
export { MainButton, TypeButton, type LoginData, type AuthorizationData, QuickBloxUIKitProvider, qbDataContext, type QBDataContextType, RemoteDataSource, LocalDataSource, useQBConnection, useQbInitializedDataContext, useQbUIKitDataContext, useEventMessagesRepository, type DialogListViewModel, useDialogListViewModel, SubscribeToDialogEventsUseCase, Pagination, type DialogEventInfo, EventMessageType, NotificationTypes, stringifyError, DesktopLayout, DialogList, Dialog, DialogInfo, type DialogEntity, BaseViewModel, QuickBloxUIKitDesktopLayout, DefaultTheme, type UiKitTheme, type AIMessageWidget, AISource, type IChatMessage, AIWidgetIcon, ErrorMessageIcon, PreviewDialogViewModel, type FunctionTypeViewModelToVoid, type AvatarContentIncomingUserProps, type GetUserNameFct };
|