mezon-js 2.7.73 → 2.7.75
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/mezon-js.cjs.js +1 -1
- package/dist/mezon-js.esm.mjs +1 -1
- package/dist/socket.d.ts +3 -1
- package/package.json +1 -1
- package/socket.ts +5 -2
package/dist/mezon-js.cjs.js
CHANGED
@@ -4828,7 +4828,7 @@ var _DefaultSocket = class _DefaultSocket {
|
|
4828
4828
|
writeCustomStatus(clan_id, status) {
|
4829
4829
|
return __async(this, null, function* () {
|
4830
4830
|
const response = yield this.send({ custom_status_event: { clan_id, status } });
|
4831
|
-
return response.
|
4831
|
+
return response.custom_status_event;
|
4832
4832
|
});
|
4833
4833
|
}
|
4834
4834
|
pingPong() {
|
package/dist/mezon-js.esm.mjs
CHANGED
@@ -4799,7 +4799,7 @@ var _DefaultSocket = class _DefaultSocket {
|
|
4799
4799
|
writeCustomStatus(clan_id, status) {
|
4800
4800
|
return __async(this, null, function* () {
|
4801
4801
|
const response = yield this.send({ custom_status_event: { clan_id, status } });
|
4802
|
-
return response.
|
4802
|
+
return response.custom_status_event;
|
4803
4803
|
});
|
4804
4804
|
}
|
4805
4805
|
pingPong() {
|
package/dist/socket.d.ts
CHANGED
@@ -431,6 +431,8 @@ export interface Socket {
|
|
431
431
|
writeLastSeenMessage(clan_id: string, channel_id: string, mode: number, message_id: string, timestamp: string): Promise<LastSeenMessageEvent>;
|
432
432
|
/** Send last pin message */
|
433
433
|
writeLastPinMessage(clan_id: string, channel_id: string, mode: number, message_id: string, timestamp: string, operation: number): Promise<LastPinMessageEvent>;
|
434
|
+
/** Send custom user status */
|
435
|
+
writeCustomStatus(clan_id: string, status: string): Promise<CustomStatusEvent>;
|
434
436
|
/** send voice joined */
|
435
437
|
writeVoiceJoined(id: string, clanId: string, clanName: string, voiceChannelId: string, voiceChannelLabel: string, participant: string, lastScreenshot: string): Promise<VoiceJoinedEvent>;
|
436
438
|
/** send voice leaved */
|
@@ -525,7 +527,7 @@ export declare class DefaultSocket implements Socket {
|
|
525
527
|
onstreamdata(streamData: StreamData): void;
|
526
528
|
onheartbeattimeout(): void;
|
527
529
|
oncustomstatus(statusEvent: CustomStatusEvent): void;
|
528
|
-
send(message: ChannelJoin | ChannelLeave | ChannelMessageSend | ChannelMessageUpdate | ChannelMessageRemove | MessageTypingEvent | LastSeenMessageEvent | Rpc | StatusFollow | StatusUnfollow | StatusUpdate | Ping, sendTimeout?: number): Promise<any>;
|
530
|
+
send(message: ChannelJoin | ChannelLeave | ChannelMessageSend | ChannelMessageUpdate | CustomStatusEvent | ChannelMessageRemove | MessageTypingEvent | LastSeenMessageEvent | Rpc | StatusFollow | StatusUnfollow | StatusUpdate | Ping, sendTimeout?: number): Promise<any>;
|
529
531
|
followUsers(userIds: string[]): Promise<Status>;
|
530
532
|
joinClanChat(clan_id: string): Promise<ClanJoin>;
|
531
533
|
joinChat(clan_id: string, channel_id: string, mode: number, type: number, persistence: boolean, hidden: boolean): Promise<Channel>;
|
package/package.json
CHANGED
package/socket.ts
CHANGED
@@ -598,6 +598,9 @@ export interface Socket {
|
|
598
598
|
/** Send last pin message */
|
599
599
|
writeLastPinMessage(clan_id: string, channel_id: string, mode: number, message_id: string, timestamp: string, operation: number) : Promise<LastPinMessageEvent>;
|
600
600
|
|
601
|
+
/** Send custom user status */
|
602
|
+
writeCustomStatus(clan_id: string, status: string) : Promise<CustomStatusEvent>;
|
603
|
+
|
601
604
|
/** send voice joined */
|
602
605
|
writeVoiceJoined(id: string, clanId: string, clanName: string, voiceChannelId: string, voiceChannelLabel: string, participant: string, lastScreenshot: string) : Promise<VoiceJoinedEvent>;
|
603
606
|
|
@@ -994,7 +997,7 @@ export class DefaultSocket implements Socket {
|
|
994
997
|
}
|
995
998
|
}
|
996
999
|
|
997
|
-
send(message: ChannelJoin | ChannelLeave | ChannelMessageSend | ChannelMessageUpdate |
|
1000
|
+
send(message: ChannelJoin | ChannelLeave | ChannelMessageSend | ChannelMessageUpdate | CustomStatusEvent |
|
998
1001
|
ChannelMessageRemove | MessageTypingEvent | LastSeenMessageEvent | Rpc | StatusFollow | StatusUnfollow | StatusUpdate | Ping, sendTimeout = DefaultSocket.DefaultSendTimeoutMs): Promise<any> {
|
999
1002
|
const untypedMessage = message as any;
|
1000
1003
|
|
@@ -1148,7 +1151,7 @@ export class DefaultSocket implements Socket {
|
|
1148
1151
|
|
1149
1152
|
async writeCustomStatus(clan_id: string, status: string) : Promise<CustomStatusEvent> {
|
1150
1153
|
const response = await this.send({custom_status_event: {clan_id: clan_id, status: status}});
|
1151
|
-
return response.
|
1154
|
+
return response.custom_status_event
|
1152
1155
|
}
|
1153
1156
|
|
1154
1157
|
private async pingPong() : Promise<void> {
|