jugglechat-websdk 1.7.4 → 1.7.8
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/index.d.ts +455 -0
- package/index.js +42 -40
- package/package.json +1 -1
package/index.d.ts
ADDED
|
@@ -0,0 +1,455 @@
|
|
|
1
|
+
interface EVENT {
|
|
2
|
+
STATE_CHANGED: string;
|
|
3
|
+
MESSAGE_RECEIVED: string;
|
|
4
|
+
MESSAGE_RECALLED: string;
|
|
5
|
+
MESSAGE_UPDATED: string;
|
|
6
|
+
MESSAGE_READ: string;
|
|
7
|
+
MESSAGE_REMOVED: string;
|
|
8
|
+
MESSAGE_CLEAN: string;
|
|
9
|
+
MESSAGE_CLEAN_SOMEONE: string;
|
|
10
|
+
MESSAGE_REACTION_CHANGED: string;
|
|
11
|
+
TAG_ADDED: string;
|
|
12
|
+
TAG_REMOVED: string;
|
|
13
|
+
TAG_CHANGED: string;
|
|
14
|
+
TAG_CONVERSATION_ADDED: string;
|
|
15
|
+
TAG_CONVERSATION_REMOVED: string;
|
|
16
|
+
CONVERSATION_SYNC_FINISHED: string;
|
|
17
|
+
CONVERSATION_UNDISTURBED: string;
|
|
18
|
+
CONVERSATION_TOP: string;
|
|
19
|
+
CONVERSATION_CLEARUNREAD: string;
|
|
20
|
+
CLEAR_TOTAL_UNREADCOUNT: string;
|
|
21
|
+
CONVERSATION_CHANGED: string;
|
|
22
|
+
CONVERSATION_ADDED: string;
|
|
23
|
+
CONVERSATION_REMOVED: string;
|
|
24
|
+
CHATROOM_ATTRIBUTE_UPDATED: string;
|
|
25
|
+
CHATROOM_ATTRIBUTE_DELETED: string;
|
|
26
|
+
CHATROOM_DESTROYED: string;
|
|
27
|
+
CHATROOM_USER_QUIT: string;
|
|
28
|
+
CHATROOM_USER_KICKED: string;
|
|
29
|
+
};
|
|
30
|
+
interface CONNECT_STATE {
|
|
31
|
+
CONNECTED,
|
|
32
|
+
CONNECTING,
|
|
33
|
+
DISCONNECTED,
|
|
34
|
+
CONNECT_FAILED,
|
|
35
|
+
DB_OPENED,
|
|
36
|
+
DB_CLOSED,
|
|
37
|
+
RECONNECTING,
|
|
38
|
+
}
|
|
39
|
+
interface CONVERATION_TYPE {
|
|
40
|
+
PRIVATE,
|
|
41
|
+
GROUP,
|
|
42
|
+
CHATROOM,
|
|
43
|
+
SYSTEM,
|
|
44
|
+
}
|
|
45
|
+
interface MESSAGE_ORDER {
|
|
46
|
+
FORWARD,
|
|
47
|
+
BACKWARD,
|
|
48
|
+
}
|
|
49
|
+
interface CONVERSATION_ORDER {
|
|
50
|
+
BACKWARD,
|
|
51
|
+
FORWARD,
|
|
52
|
+
}
|
|
53
|
+
interface MENTION_ORDER {
|
|
54
|
+
BACKWARD,
|
|
55
|
+
FORWARD,
|
|
56
|
+
}
|
|
57
|
+
interface UPLOAD_TYPE {
|
|
58
|
+
NONE,
|
|
59
|
+
QINIU,
|
|
60
|
+
ALI,
|
|
61
|
+
}
|
|
62
|
+
interface UNDISTURB_TYPE {
|
|
63
|
+
DISTURB,
|
|
64
|
+
UNDISTURB,
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
interface MESSAGE_TYPE {
|
|
68
|
+
TEXT,
|
|
69
|
+
IMAGE,
|
|
70
|
+
VOICE,
|
|
71
|
+
VIDEO,
|
|
72
|
+
FILE,
|
|
73
|
+
MERGE,
|
|
74
|
+
RECALL,
|
|
75
|
+
RECALL_INFO,
|
|
76
|
+
READ_MSG,
|
|
77
|
+
READ_GROUP_MSG,
|
|
78
|
+
MODIFY,
|
|
79
|
+
CLEAR_MSG,
|
|
80
|
+
CLEAR_UNREAD,
|
|
81
|
+
COMMAND_DELETE_MSGS,
|
|
82
|
+
COMMAND_UNDISTURB,
|
|
83
|
+
COMMAND_TOPCONVERS,
|
|
84
|
+
COMMAND_REMOVE_CONVERS,
|
|
85
|
+
COMMAND_ADD_CONVER,
|
|
86
|
+
COMMAND_CLEAR_TOTALUNREAD,
|
|
87
|
+
COMMAND_MARK_UNREAD,
|
|
88
|
+
COMMAND_LOG_REPORT,
|
|
89
|
+
COMMAND_MSG_EXSET,
|
|
90
|
+
COMMAND_CONVERSATION_TAG_ADD,
|
|
91
|
+
COMMAND_REMOVE_CONVERS_FROM_TAG,
|
|
92
|
+
COMMAND_CONVERSATION_TAG_REMOVE,
|
|
93
|
+
CLIENT_REMOVE_MSGS,
|
|
94
|
+
CLIENT_REMOVE_CONVERS,
|
|
95
|
+
CLIENT_RECALL_MSG,
|
|
96
|
+
CLIENT_MARK_UNREAD,
|
|
97
|
+
}
|
|
98
|
+
interface MENTION_TYPE {
|
|
99
|
+
ALL,
|
|
100
|
+
SOMEONE,
|
|
101
|
+
ALL_SOMEONE,
|
|
102
|
+
}
|
|
103
|
+
interface FILE_TYPE {
|
|
104
|
+
IMAGE,
|
|
105
|
+
AUDIO,
|
|
106
|
+
VIDEO,
|
|
107
|
+
FILE,
|
|
108
|
+
}
|
|
109
|
+
interface MESSAGE_SENT_STATE {
|
|
110
|
+
NONE,
|
|
111
|
+
SENDING,
|
|
112
|
+
SUCCESS,
|
|
113
|
+
FAILED,
|
|
114
|
+
UPLOADING,
|
|
115
|
+
}
|
|
116
|
+
interface DISCONNECT_TYPE {
|
|
117
|
+
DISCONNECT,
|
|
118
|
+
CLOSE,
|
|
119
|
+
ERROR,
|
|
120
|
+
SERVER,
|
|
121
|
+
}
|
|
122
|
+
interface UNREAD_TAG {
|
|
123
|
+
READ,
|
|
124
|
+
UNREAD,
|
|
125
|
+
}
|
|
126
|
+
interface SET_SEARCH_CONTENT_TYPE {
|
|
127
|
+
APPEND,
|
|
128
|
+
REPLACE,
|
|
129
|
+
}
|
|
130
|
+
interface CONVERATION_TAG_TYPE {
|
|
131
|
+
USER,
|
|
132
|
+
SYSNTEM,
|
|
133
|
+
GLOBAL,
|
|
134
|
+
}
|
|
135
|
+
|
|
136
|
+
interface Error {
|
|
137
|
+
code: number,
|
|
138
|
+
msg: string
|
|
139
|
+
}
|
|
140
|
+
declare class IMUser {
|
|
141
|
+
id?: string;
|
|
142
|
+
name?: string;
|
|
143
|
+
portrait?: string;
|
|
144
|
+
token?: string;
|
|
145
|
+
exts?: string;
|
|
146
|
+
}
|
|
147
|
+
declare class ERROR_TYPE {
|
|
148
|
+
CONNECT_SUCCESS: Error;
|
|
149
|
+
CONNECT_ERROR: Error;
|
|
150
|
+
CONNECT_APPKEY_IS_REQUIRE: Error;
|
|
151
|
+
CONNECT_TOKEN_NOT_EXISTS: Error;
|
|
152
|
+
CONNECT_APPKEY_NOT_EXISTS: Error;
|
|
153
|
+
CONNECT_TOKEN_ILLEGAL: Error;
|
|
154
|
+
CONNECT_TOKEN_UNAUTHORIZED: Error;
|
|
155
|
+
CONNECT_TOKEN_EXPIRE: Error;
|
|
156
|
+
CONNECT_REDIRECT: Error;
|
|
157
|
+
CONNECT_UNSUPPORT_PLATFORM: Error;
|
|
158
|
+
CONNECT_APP_BLOCKED: Error;
|
|
159
|
+
CONNECT_USER_BLOCKED: Error;
|
|
160
|
+
CONNECT_USER_KICKED: Error;
|
|
161
|
+
CONNECT_USER_LOGOUT: Error;
|
|
162
|
+
CHATROOM_NOT_JOIN: Error;
|
|
163
|
+
CHATROOM_ATTR_EXCEED_LIMIT: Error;
|
|
164
|
+
CHATROOM_ATTR_EXISTS: Error;
|
|
165
|
+
CHATROOM_NOT_EXISTS: Error;
|
|
166
|
+
PB_ERROR: Error;
|
|
167
|
+
GROUP_NOT_EXISTS: Error;
|
|
168
|
+
ILLEGAL_PARAMS: Error;
|
|
169
|
+
CONNECTION_EXISTS: Error;
|
|
170
|
+
CONNECTION_NOT_READY: Error;
|
|
171
|
+
ILLEGAL_TYPE_PARAMS: Error;
|
|
172
|
+
COMMAND_FAILED: Error;
|
|
173
|
+
UPLOAD_PLUGIN_ERROR: Error;
|
|
174
|
+
UPLOAD_PLUGIN_NOTMATCH: Error;
|
|
175
|
+
UPLOADING_FILE_ERROR: Error;
|
|
176
|
+
TRANSFER_MESSAGE_COUNT_EXCEED: Error;
|
|
177
|
+
DATABASE_NOT_OPENED: Error;
|
|
178
|
+
SDK_FUNC_NOT_DEFINED: Error;
|
|
179
|
+
SEND_REFER_MESSAGE_ERROR: Error;
|
|
180
|
+
IM_SERVER_CONNECT_ERROR: Error;
|
|
181
|
+
ILLEGAL_PARAMS_EMPTY: Error;
|
|
182
|
+
REPREAT_CONNECTION: Error;
|
|
183
|
+
MESSAGE_RECALL_SUCCESS: Error;
|
|
184
|
+
COMMAND_SUCCESS: Error;
|
|
185
|
+
CONNECT_SIGNAL_UNSUPPORT: Error;
|
|
186
|
+
COMMAND_OVER_FREQUENCY: Error;
|
|
187
|
+
CONNECT_USER_NOT_EXISTS: Error;
|
|
188
|
+
PARAMS_TIMEZONE_ILLEGAL: Error;
|
|
189
|
+
PARAMS_MESSAGE_ILLEGAL: Error;
|
|
190
|
+
REJECTED_BY_BLACKLIST: Error;
|
|
191
|
+
KV_DUPLICATION: Error;
|
|
192
|
+
MESSAGE_SENSITIVE_WORDS: Error;
|
|
193
|
+
GROUP_NOT_GROUP_MEMBER: Error;
|
|
194
|
+
GROUP_BANNED: Error;
|
|
195
|
+
GROUP_MEMBER_BANNED: Error;
|
|
196
|
+
GROUP_MEMBER_OVERFLOW: Error;
|
|
197
|
+
CHATROOM_KV_NOT_EXISTS: Error;
|
|
198
|
+
CHATROOM_DESTROY: Error;
|
|
199
|
+
CHATROOM_MEMBER_BANNED: Error;
|
|
200
|
+
CHATROOM_MEMBER_BLOCKED: Error;
|
|
201
|
+
}
|
|
202
|
+
declare class Message {
|
|
203
|
+
conversationId: string;
|
|
204
|
+
conversationType: CONVERATION_TYPE;
|
|
205
|
+
conversationTitle?: string;
|
|
206
|
+
conversationPortrait?: string;
|
|
207
|
+
conversationExts?: string;
|
|
208
|
+
tid?: string;
|
|
209
|
+
messageId?: string;
|
|
210
|
+
name: string;
|
|
211
|
+
content: Object;
|
|
212
|
+
sentState?: number;
|
|
213
|
+
sentTime?: number;
|
|
214
|
+
sender?: IMUser;
|
|
215
|
+
attribute?: string;
|
|
216
|
+
referMsg?: Message;
|
|
217
|
+
isMass?: boolean;
|
|
218
|
+
isUpdated?: boolean;
|
|
219
|
+
isSender?: boolean;
|
|
220
|
+
isRead?: boolean;
|
|
221
|
+
readCount?: number;
|
|
222
|
+
unreadCount?: number;
|
|
223
|
+
reactions?: any;
|
|
224
|
+
}
|
|
225
|
+
declare class Conversation {
|
|
226
|
+
conversationId: string;
|
|
227
|
+
conversationType: number;
|
|
228
|
+
conversationTitle?: string;
|
|
229
|
+
conversationPortrait?: string;
|
|
230
|
+
conversationExts?: string;
|
|
231
|
+
latestMessage?: Message;
|
|
232
|
+
draft?: string;
|
|
233
|
+
isTop?: boolean;
|
|
234
|
+
latestReadIndex?: number;
|
|
235
|
+
latestUnreadIndex?: number;
|
|
236
|
+
undisturbType?: number;
|
|
237
|
+
sortTime?: number;
|
|
238
|
+
unreadCount?: number;
|
|
239
|
+
unreadTag?: number;
|
|
240
|
+
}
|
|
241
|
+
declare class ChatroomAttribute {
|
|
242
|
+
key: string;
|
|
243
|
+
value: string;
|
|
244
|
+
isForce: boolean;
|
|
245
|
+
isDel: boolean;
|
|
246
|
+
}
|
|
247
|
+
|
|
248
|
+
declare class Chatroom {
|
|
249
|
+
id: string;
|
|
250
|
+
attributes?: ChatroomAttribute[];
|
|
251
|
+
}
|
|
252
|
+
|
|
253
|
+
interface GetConversationOptions {
|
|
254
|
+
order?: number;
|
|
255
|
+
count?: number;
|
|
256
|
+
time?: number;
|
|
257
|
+
}
|
|
258
|
+
interface TotalUnreadResult{
|
|
259
|
+
total: number;
|
|
260
|
+
}
|
|
261
|
+
interface GetTotalOptions{
|
|
262
|
+
conversationTypes?: CONVERATION_TYPE[];
|
|
263
|
+
ignoreConversations?: Conversation[];
|
|
264
|
+
}
|
|
265
|
+
declare class TimeZone{
|
|
266
|
+
start: string;
|
|
267
|
+
end: string;
|
|
268
|
+
}
|
|
269
|
+
declare class DisturbInfo {
|
|
270
|
+
type: UNDISTURB_TYPE,
|
|
271
|
+
timezone: string,
|
|
272
|
+
times: TimeZone[];
|
|
273
|
+
}
|
|
274
|
+
declare class TagInfo {
|
|
275
|
+
id: string;
|
|
276
|
+
name?: string;
|
|
277
|
+
conversations?: Conversation[]
|
|
278
|
+
}
|
|
279
|
+
interface SendMsgCallbacks{
|
|
280
|
+
onbefore?(message: Message): any;
|
|
281
|
+
onerror?(error: Error): any;
|
|
282
|
+
onprogress?({ percent?: number, message: Message, count?: number, total?: number }):any;
|
|
283
|
+
oncompleted?({ messages: Message[] }): any;
|
|
284
|
+
}
|
|
285
|
+
interface GetMsgByIdOptions{
|
|
286
|
+
conversationType: CONVERATION_TYPE,
|
|
287
|
+
conversationId: string;
|
|
288
|
+
messageIds: string[];
|
|
289
|
+
}
|
|
290
|
+
interface ClearMsgsOptions{
|
|
291
|
+
conversationType: CONVERATION_TYPE,
|
|
292
|
+
conversationId: string;
|
|
293
|
+
time: number;
|
|
294
|
+
}
|
|
295
|
+
interface ReadMember{
|
|
296
|
+
readTime: number;
|
|
297
|
+
member: IMUser;
|
|
298
|
+
}
|
|
299
|
+
interface GetGroupMessageDetailResult{
|
|
300
|
+
readCount: number;
|
|
301
|
+
unreadCount: number;
|
|
302
|
+
unreadMembers: ReadMember[];
|
|
303
|
+
readMembers: ReadMember[];
|
|
304
|
+
}
|
|
305
|
+
interface GetMentionOptions{
|
|
306
|
+
conversationType: CONVERATION_TYPE,
|
|
307
|
+
conversationId: string;
|
|
308
|
+
messageIndex: number;
|
|
309
|
+
count?: number;
|
|
310
|
+
order?: number;
|
|
311
|
+
}
|
|
312
|
+
interface SendMergeOptions{
|
|
313
|
+
conversationType: CONVERATION_TYPE,
|
|
314
|
+
conversationId: string;
|
|
315
|
+
messageIdList: string[];
|
|
316
|
+
previewList: Array;
|
|
317
|
+
title: string;
|
|
318
|
+
}
|
|
319
|
+
interface SearchOptions{
|
|
320
|
+
conversationType?: CONVERATION_TYPE,
|
|
321
|
+
conversationId?: string;
|
|
322
|
+
keywords: string[];
|
|
323
|
+
senderIds?: string[];
|
|
324
|
+
messageNames?: string[];
|
|
325
|
+
startTime?: number;
|
|
326
|
+
endTime?: number;
|
|
327
|
+
page?: number;
|
|
328
|
+
pageSize?: number;
|
|
329
|
+
}
|
|
330
|
+
interface SearchMatchMsg{
|
|
331
|
+
conversationType: CONVERATION_TYPE;
|
|
332
|
+
conversationId: string;
|
|
333
|
+
conversationExts: string;
|
|
334
|
+
conversationPortrait: string;
|
|
335
|
+
conversationTitle: string;
|
|
336
|
+
matchedCount: number;
|
|
337
|
+
matchedList: Message[];
|
|
338
|
+
}
|
|
339
|
+
interface SearchResult{
|
|
340
|
+
isFinished: boolean;
|
|
341
|
+
total: number;
|
|
342
|
+
list: SearchMatchMsg[];
|
|
343
|
+
}
|
|
344
|
+
interface ReactionOptions{
|
|
345
|
+
conversationType: CONVERATION_TYPE;
|
|
346
|
+
conversationId: string;
|
|
347
|
+
messageId: string;
|
|
348
|
+
reactionId: string;
|
|
349
|
+
}
|
|
350
|
+
declare class IMProvider {
|
|
351
|
+
connect: (user: IMUser) => Promise<>;
|
|
352
|
+
disconnect: () => Promise<any>;
|
|
353
|
+
getDevice: () => Promise<any>;
|
|
354
|
+
isConnected: () => boolean;
|
|
355
|
+
getCurrentUser: () => IMUser;
|
|
356
|
+
joinChatroom: (chatroom: Chatroom) => Promise<any>;
|
|
357
|
+
quitChatroom: (chatroom: Chatroom) => Promise<any>;
|
|
358
|
+
setChatroomAttributes: (chatroom: Chatroom) => Promise<any>;
|
|
359
|
+
getChatroomAttributes: (chatroom: Chatroom) => Promise<Chatroom>;
|
|
360
|
+
removeChatroomAttributes: (chatroom: Chatroom) => Promise<any>;
|
|
361
|
+
getAllChatRoomAttributes: (chatroom: Chatroom) => Promise<Chatroom>;
|
|
362
|
+
getConversations: (options?: GetConversationOptions) => Promise<{ conversations: Conversation[], isFinished: boolean }>;
|
|
363
|
+
removeConversation: (conversations: Conversation[]) => Promise<any>;
|
|
364
|
+
insertConversation: (conversation: Conversation) => Promise<any>;
|
|
365
|
+
getConversation: (conversation: Conversation) => Promise<Conversation>;
|
|
366
|
+
markUnread: (conversation: Conversation) => Promise<any>;
|
|
367
|
+
disturbConversation: (conversation: Conversation | Conversation[]) => Promise<any>;
|
|
368
|
+
setTopConversation: (conversation: Conversation | Conversation[]) => Promise<any>;
|
|
369
|
+
getTopConversations: () => Promise<{ conversations: Conversation[] }>;
|
|
370
|
+
clearUnreadcount: (conversation: Conversation | Conversation[]) => Promise<any>;
|
|
371
|
+
getTotalUnreadcount: (options?: GetTotalOptions) => Promise<TotalUnreadResult>;
|
|
372
|
+
clearTotalUnreadcount: () => Promise<any>;
|
|
373
|
+
setDraft: (conversation: Conversation) => Promise<any>;
|
|
374
|
+
getDraft: (conversation: Conversation) => Promise<string>;
|
|
375
|
+
removeDraft: (conversation: Conversation) => Promise<any>;
|
|
376
|
+
setAllDisturb: (options: DisturbInfo) => Promise<any>;
|
|
377
|
+
getAllDisturb: () => Promise<DisturbInfo>;
|
|
378
|
+
createConversationTag: (tag: TagInfo) => Promise<any>;
|
|
379
|
+
destroyConversationTag: (tag: TagInfo) => Promise<any>;
|
|
380
|
+
getConversationTags: () => Promise<{ tags: TagInfo[] }>;
|
|
381
|
+
addConversationsToTag: (tag: TagInfo) => Promise<any>;
|
|
382
|
+
removeConversationsFromTag: (tag: TagInfo) => Promise<any>;
|
|
383
|
+
sendMessage: (message: Message, callbacks?: SendMsgCallbacks) => Promise<Message>;
|
|
384
|
+
sendMassMessage: (messages: Message[], callbacks?: SendMsgCallbacks) => Promise<any>;
|
|
385
|
+
getMessages: (conversation: Conversation) => Promise<{ isFinished: boolean, messages: Message[] }>;
|
|
386
|
+
removeMessages: (messages: Messages[]) => Promise<any>;
|
|
387
|
+
getMessagesByIds: (options: GetMsgByIdOptions) => Promise<{ messages: Message[] }>;
|
|
388
|
+
clearMessage: (options: ClearMsgsOptions) => Promise<any>;
|
|
389
|
+
recallMessage: (message: Message) => Promise<any>;
|
|
390
|
+
readMessage: (messages: Message[]) => Promise<any>;
|
|
391
|
+
getMessageReadDetails: (message: Message) => Promise<GetGroupMessageDetailResult>;
|
|
392
|
+
updateMessage: (message: Message) => Promise<any>;
|
|
393
|
+
insertMessage: (message: Message) => Promise<any>;
|
|
394
|
+
updateMessageAttr: (message: Message) => Promise<any>;
|
|
395
|
+
setSearchContent: (message: Message) => Promise<any>;
|
|
396
|
+
getMentionMessages: (options: GetMentionOptions) => Promise<{ isFinished: boolean, messages: Message[] }>;
|
|
397
|
+
getFileToken: (params: any) => Promise<any>;
|
|
398
|
+
sendFileMessage: (message: Message, callbacks?: SendMsgCallbacks) => Promise<Message>;
|
|
399
|
+
sendImageMessage: (message: Message, callbacks?: SendMsgCallbacks) => Promise<Message>;
|
|
400
|
+
sendVoiceMessage: (message: Message, callbacks?: SendMsgCallbacks) => Promise<Message>;
|
|
401
|
+
sendVideoMessage: (message: Message, callbacks?: SendMsgCallbacks) => Promise<Message>;
|
|
402
|
+
sendMergeMessage: (options: SendMergeOptions, callbacks?: SendMsgCallbacks) => Promise<Message>;
|
|
403
|
+
getMergeMessages: (message: Message) => Promise<{ isFinished: boolean, messages: Message[] }>;
|
|
404
|
+
getFirstUnreadMessage: (conversation: Conversation) => Promise<{ message: Message }>;
|
|
405
|
+
searchMessages: (options: SearchOptions) => Promise<SearchResult>;
|
|
406
|
+
addMessageReaction: (message: ReactionOptions) => Promise<any>;
|
|
407
|
+
removeMessageReaction: (message: ReactionOptions) => Promise<any>;
|
|
408
|
+
Event: EVENT;
|
|
409
|
+
ConnectionState: CONNECT_STATE;
|
|
410
|
+
ConversationType: CONVERATION_TYPE;
|
|
411
|
+
MessageType: MESSAGE_TYPE;
|
|
412
|
+
ConversationOrder: CONVERSATION_ORDER;
|
|
413
|
+
MentionType: MENTION_TYPE;
|
|
414
|
+
MessageOrder: MESSAGE_ORDER;
|
|
415
|
+
MentionOrder: MENTION_ORDER;
|
|
416
|
+
FileType: FILE_TYPE;
|
|
417
|
+
UndisturbType: UNDISTURB_TYPE;
|
|
418
|
+
SentState: MESSAGE_SENT_STATE;
|
|
419
|
+
UnreadTag: UNREAD_TAG;
|
|
420
|
+
ConversationTagType: CONVERATION_TAG_TYPE;
|
|
421
|
+
ErrorType: ERROR_TYPE;
|
|
422
|
+
Message: Message;
|
|
423
|
+
InitOptions: InitOptions;
|
|
424
|
+
IMProvider: IMProvider;
|
|
425
|
+
}
|
|
426
|
+
|
|
427
|
+
interface InitOptions {
|
|
428
|
+
appkey: string;
|
|
429
|
+
navList?: Array;
|
|
430
|
+
isSync?: boolean;
|
|
431
|
+
upload?: Object;
|
|
432
|
+
}
|
|
433
|
+
|
|
434
|
+
declare namespace IMCore {
|
|
435
|
+
export function init(options: InitOptions): IMProvider;
|
|
436
|
+
export let Event: EVENT;
|
|
437
|
+
export let ConnectionState: CONNECT_STATE;
|
|
438
|
+
export let ConversationType: CONVERATION_TYPE;
|
|
439
|
+
export let MessageType: MESSAGE_TYPE;
|
|
440
|
+
export let ConversationOrder: CONVERSATION_ORDER;
|
|
441
|
+
export let MentionType: MENTION_TYPE;
|
|
442
|
+
export let MessageOrder: MESSAGE_ORDER;
|
|
443
|
+
export let MentionOrder: MENTION_ORDER;
|
|
444
|
+
export let FileType: FILE_TYPE;
|
|
445
|
+
export let UndisturbType: UNDISTURB_TYPE;
|
|
446
|
+
export let SentState: MESSAGE_SENT_STATE;
|
|
447
|
+
export let UnreadTag: UNREAD_TAG;
|
|
448
|
+
export let ConversationTagType: CONVERATION_TAG_TYPE;
|
|
449
|
+
export let ErrorType: ERROR_TYPE;
|
|
450
|
+
export let Message: Message;
|
|
451
|
+
export let InitOptions: InitOptions;
|
|
452
|
+
export let IMProvider: IMProvider;
|
|
453
|
+
}
|
|
454
|
+
|
|
455
|
+
export default { ...IMCore };
|