isometrik-plugin-chat-sdk 2.0.9 → 2.0.11
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/cjs/attachment-preview_22.cjs.entry.js +253 -36
- package/dist/cjs/attachment-preview_22.cjs.entry.js.map +1 -1
- package/dist/cjs/isometrik-webchat.cjs.js +1 -1
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/collection/components/ChatUIComponent/Footer/ChatFooter.js +29 -23
- package/dist/collection/components/ChatUIComponent/Footer/ChatFooter.js.map +1 -1
- package/dist/collection/components/ChatUIComponent/Header/WebChatHeader.js +19 -8
- package/dist/collection/components/ChatUIComponent/Header/WebChatHeader.js.map +1 -1
- package/dist/collection/components/ChatUIComponent/shared/contact-info/contact-info.js +129 -3
- package/dist/collection/components/ChatUIComponent/shared/contact-info/contact-info.js.map +1 -1
- package/dist/collection/components/my-component/web-chat/WebchatRightSide.js +17 -2
- package/dist/collection/components/my-component/web-chat/WebchatRightSide.js.map +1 -1
- package/dist/collection/lib/chat/group-title.js +8 -0
- package/dist/collection/lib/chat/group-title.js.map +1 -0
- package/dist/collection/lib/chat/index.js +2 -0
- package/dist/collection/lib/chat/index.js.map +1 -1
- package/dist/collection/lib/chat/mentioned-users.js +59 -0
- package/dist/collection/lib/chat/mentioned-users.js.map +1 -0
- package/dist/components/ChatFooter.js +87 -23
- package/dist/components/ChatFooter.js.map +1 -1
- package/dist/components/WebChatHeader.js +19 -8
- package/dist/components/WebChatHeader.js.map +1 -1
- package/dist/components/WebchatRightSide.js +17 -2
- package/dist/components/WebchatRightSide.js.map +1 -1
- package/dist/components/contact-info2.js +138 -5
- package/dist/components/contact-info2.js.map +1 -1
- package/dist/esm/attachment-preview_22.entry.js +253 -36
- package/dist/esm/attachment-preview_22.entry.js.map +1 -1
- package/dist/esm/isometrik-webchat.js +1 -1
- package/dist/esm/loader.js +1 -1
- package/dist/isometrik-webchat/isometrik-webchat.esm.js +1 -1
- package/dist/isometrik-webchat/isometrik-webchat.esm.js.map +1 -1
- package/dist/isometrik-webchat/p-2d69086d.entry.js +2 -0
- package/dist/isometrik-webchat/p-2d69086d.entry.js.map +1 -0
- package/dist/types/components/ChatUIComponent/Footer/ChatFooter.d.ts +7 -3
- package/dist/types/components/ChatUIComponent/Header/WebChatHeader.d.ts +1 -0
- package/dist/types/components/ChatUIComponent/shared/contact-info/contact-info.d.ts +15 -0
- package/dist/types/lib/chat/group-title.d.ts +2 -0
- package/dist/types/lib/chat/index.d.ts +2 -0
- package/dist/types/lib/chat/mentioned-users.d.ts +18 -0
- package/package.json +1 -1
- package/dist/isometrik-webchat/p-9f036163.entry.js +0 -2
- package/dist/isometrik-webchat/p-9f036163.entry.js.map +0 -1
|
@@ -8,10 +8,12 @@ interface MediaPreview {
|
|
|
8
8
|
src: string;
|
|
9
9
|
file: File;
|
|
10
10
|
}
|
|
11
|
+
/** Picker may send `{userId,userName}`; API needs `{userId,wordCount,order}`. */
|
|
11
12
|
interface MentionedUser {
|
|
12
|
-
wordCount: number;
|
|
13
13
|
userId: string;
|
|
14
|
-
|
|
14
|
+
userName?: string;
|
|
15
|
+
wordCount?: number;
|
|
16
|
+
order?: number;
|
|
15
17
|
}
|
|
16
18
|
interface ConversationConfig {
|
|
17
19
|
pushNotifications: boolean;
|
|
@@ -121,9 +123,11 @@ declare class ChatFooter {
|
|
|
121
123
|
generateSearchableTags: (body: string) => string[];
|
|
122
124
|
handleFileUpload: (event: CustomEvent) => void;
|
|
123
125
|
updateConversationListOnMessageSend(localMessage: any): Promise<void>;
|
|
126
|
+
/** API payload only — strips userName, sets wordCount + order. */
|
|
127
|
+
private mentionedUsersForApi;
|
|
124
128
|
createLocalMessage: (messageBody: string, attachments: any, messageId: string) => {
|
|
125
129
|
metaData: Record<string, any>;
|
|
126
|
-
mentionedUsers: MentionedUser[];
|
|
130
|
+
mentionedUsers: import("../../../lib/chat/mentioned-users").MentionedUserPayload[] | MentionedUser[];
|
|
127
131
|
attachments: any;
|
|
128
132
|
body: string;
|
|
129
133
|
messageId: string;
|
|
@@ -62,6 +62,10 @@ export declare class ContactInfo {
|
|
|
62
62
|
docItems: any[];
|
|
63
63
|
previewTry: Record<string, number>;
|
|
64
64
|
memberMenuUserId: string | null;
|
|
65
|
+
titleEditing: boolean;
|
|
66
|
+
titleDraft: string;
|
|
67
|
+
imageUploading: boolean;
|
|
68
|
+
private imageFileInput?;
|
|
65
69
|
closeRightSidebar: EventEmitter<{
|
|
66
70
|
type: string;
|
|
67
71
|
}>;
|
|
@@ -74,6 +78,17 @@ export declare class ContactInfo {
|
|
|
74
78
|
private confirmExitGroup;
|
|
75
79
|
private openAddMember;
|
|
76
80
|
private isSelfAdmin;
|
|
81
|
+
/** Admin-only rename + photo (same gate). */
|
|
82
|
+
private canEditGroupInfo;
|
|
83
|
+
private startTitleEdit;
|
|
84
|
+
private openImagePicker;
|
|
85
|
+
private onImageFileChange;
|
|
86
|
+
private cancelTitleEdit;
|
|
87
|
+
private onTitleDraftInput;
|
|
88
|
+
private onTitleDraftKeyDown;
|
|
89
|
+
private saveTitleEdit;
|
|
90
|
+
onConversationChange(): void;
|
|
91
|
+
onContactImageChange(): void;
|
|
77
92
|
private toggleMemberMenu;
|
|
78
93
|
private closeMemberMenu;
|
|
79
94
|
private emitMemberEvent;
|
|
@@ -10,3 +10,5 @@ export { ATTACHMENT_BODY_PLACEHOLDER, mediaTypeFromMime, customTypeFromMime, isA
|
|
|
10
10
|
export { MAX_MEDIA_PER_MESSAGE, takeMediaFiles, mediaLimitToastMessage, } from './media-limits';
|
|
11
11
|
export { filesToOutboxMedia, outboxMediaToFiles, MAX_OUTBOX_MEDIA_BYTES } from './media-outbox';
|
|
12
12
|
export { isPdfAttachment, previewKindFromAttachment, deliveryUiState } from './preview-kind';
|
|
13
|
+
export { toMentionedUsersPayload, type MentionedUserPayload, } from './mentioned-users';
|
|
14
|
+
export { normalizeGroupTitle } from './group-title';
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* API `mentionedUsers` shape for postMessages.
|
|
3
|
+
* Callers (custom UI / HOA) may pass `{ userId, userName }`; we map to
|
|
4
|
+
* `{ userId, wordCount, order }` before send.
|
|
5
|
+
*/
|
|
6
|
+
export type MentionedUserPayload = {
|
|
7
|
+
userId: string;
|
|
8
|
+
wordCount: number;
|
|
9
|
+
order: number;
|
|
10
|
+
};
|
|
11
|
+
/**
|
|
12
|
+
* Build API mention list from composer body + picker selections.
|
|
13
|
+
* - Prefers `userName` to locate `@Name` in body and derive wordCount
|
|
14
|
+
* - Drops mentions no longer present in body
|
|
15
|
+
* - One entry per userId (first appearance wins)
|
|
16
|
+
* - `order` is 1-based by appearance in body
|
|
17
|
+
*/
|
|
18
|
+
export declare function toMentionedUsersPayload(body: string, list: unknown): MentionedUserPayload[];
|