mezon-js 2.8.73 → 2.8.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.
@@ -5092,15 +5092,17 @@ var _DefaultSocket = class _DefaultSocket {
5092
5092
  return response.clan_join;
5093
5093
  });
5094
5094
  }
5095
- joinChat(clan_id, channel_id, channel_type, is_public) {
5095
+ joinChat(clan_id, parent_id, channel_id, channel_type, is_public, is_parent_public) {
5096
5096
  return __async(this, null, function* () {
5097
5097
  const response = yield this.send(
5098
5098
  {
5099
5099
  channel_join: {
5100
5100
  clan_id,
5101
+ parent_id,
5101
5102
  channel_id,
5102
5103
  channel_type,
5103
- is_public
5104
+ is_public,
5105
+ is_parent_public
5104
5106
  }
5105
5107
  }
5106
5108
  );
@@ -5063,15 +5063,17 @@ var _DefaultSocket = class _DefaultSocket {
5063
5063
  return response.clan_join;
5064
5064
  });
5065
5065
  }
5066
- joinChat(clan_id, channel_id, channel_type, is_public) {
5066
+ joinChat(clan_id, parent_id, channel_id, channel_type, is_public, is_parent_public) {
5067
5067
  return __async(this, null, function* () {
5068
5068
  const response = yield this.send(
5069
5069
  {
5070
5070
  channel_join: {
5071
5071
  clan_id,
5072
+ parent_id,
5072
5073
  channel_id,
5073
5074
  channel_type,
5074
- is_public
5075
+ is_public,
5076
+ is_parent_public
5075
5077
  }
5076
5078
  }
5077
5079
  );
package/dist/socket.d.ts CHANGED
@@ -84,6 +84,8 @@ export interface UserChannelAddedEvent {
84
84
  clan_id: string;
85
85
  channel_type: number;
86
86
  is_public: boolean;
87
+ parent_id: string;
88
+ is_parent_public: boolean;
87
89
  }
88
90
  export interface AddUsers {
89
91
  user_id: string;
@@ -281,6 +283,8 @@ export interface ChannelCreatedEvent {
281
283
  channel_private: number;
282
284
  channel_type: number;
283
285
  status: number;
286
+ parent_id: string;
287
+ is_parent_public: boolean;
284
288
  }
285
289
  export interface ChannelDeletedEvent {
286
290
  clan_id: string;
@@ -512,7 +516,7 @@ export interface Socket {
512
516
  /** Join clan chat */
513
517
  joinClanChat(clan_id: string): Promise<ClanJoin>;
514
518
  /** Join a chat channel on the server. */
515
- joinChat(clan_id: string, channel_id: string, channel_type: number, is_public: boolean): Promise<Channel>;
519
+ joinChat(clan_id: string, parent_id: string, channel_id: string, channel_type: number, is_public: boolean, is_parent_public: boolean): Promise<Channel>;
516
520
  /** Leave a chat channel on the server. */
517
521
  leaveChat(clan_id: string, channel_id: string, channel_type: number, is_public: boolean): Promise<void>;
518
522
  /** Remove a chat message from a chat channel on the server. */
@@ -667,7 +671,7 @@ export declare class DefaultSocket implements Socket {
667
671
  send(message: ChannelJoin | ChannelLeave | ChannelMessageSend | ChannelMessageUpdate | CustomStatusEvent | ChannelMessageRemove | MessageTypingEvent | LastSeenMessageEvent | Rpc | StatusFollow | StatusUnfollow | StatusUpdate | Ping, sendTimeout?: number): Promise<any>;
668
672
  followUsers(userIds: string[]): Promise<Status>;
669
673
  joinClanChat(clan_id: string): Promise<ClanJoin>;
670
- joinChat(clan_id: string, channel_id: string, channel_type: number, is_public: boolean): Promise<Channel>;
674
+ joinChat(clan_id: string, parent_id: string, channel_id: string, channel_type: number, is_public: boolean, is_parent_public: boolean): Promise<Channel>;
671
675
  leaveChat(clan_id: string, channel_id: string, channel_type: number, is_public: boolean): Promise<void>;
672
676
  removeChatMessage(clan_id: string, channel_id: string, mode: number, is_public: boolean, message_id: string): Promise<ChannelMessageAck>;
673
677
  removePartyMember(party_id: string, member: Presence): Promise<void>;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "mezon-js",
3
- "version": "2.8.73",
3
+ "version": "2.8.75",
4
4
  "scripts": {
5
5
  "build": "npx tsc && npx rollup -c --bundleConfigAsCjs && node build.mjs"
6
6
  },
package/socket.ts CHANGED
@@ -111,6 +111,10 @@ export interface UserChannelAddedEvent {
111
111
  channel_type: number;
112
112
  // is public
113
113
  is_public: boolean;
114
+ // parent id
115
+ parent_id: string;
116
+ // parent public
117
+ is_parent_public: boolean;
114
118
  }
115
119
 
116
120
  export interface AddUsers {
@@ -413,6 +417,10 @@ export interface ChannelCreatedEvent {
413
417
  channel_type: number;
414
418
  // status
415
419
  status: number;
420
+ // parent
421
+ parent_id: string;
422
+ // parent public
423
+ is_parent_public: boolean;
416
424
  }
417
425
 
418
426
  export interface ChannelDeletedEvent {
@@ -769,7 +777,7 @@ export interface Socket {
769
777
  joinClanChat(clan_id: string) : Promise<ClanJoin>;
770
778
 
771
779
  /** Join a chat channel on the server. */
772
- joinChat(clan_id: string, channel_id: string, channel_type: number, is_public: boolean) : Promise<Channel>;
780
+ joinChat(clan_id: string, parent_id: string, channel_id: string, channel_type: number, is_public: boolean, is_parent_public: boolean) : Promise<Channel>;
773
781
 
774
782
  /** Leave a chat channel on the server. */
775
783
  leaveChat(clan_id: string, channel_id: string, channel_type: number, is_public: boolean) : Promise<void>;
@@ -1377,14 +1385,16 @@ export class DefaultSocket implements Socket {
1377
1385
  return response.clan_join;
1378
1386
  }
1379
1387
 
1380
- async joinChat(clan_id: string, channel_id: string, channel_type: number, is_public: boolean): Promise<Channel> {
1388
+ async joinChat(clan_id: string, parent_id: string, channel_id: string, channel_type: number, is_public: boolean, is_parent_public: boolean): Promise<Channel> {
1381
1389
 
1382
1390
  const response = await this.send({
1383
1391
  channel_join: {
1384
1392
  clan_id: clan_id,
1393
+ parent_id: parent_id,
1385
1394
  channel_id: channel_id,
1386
1395
  channel_type: channel_type,
1387
- is_public: is_public
1396
+ is_public: is_public,
1397
+ is_parent_public: is_parent_public
1388
1398
  }
1389
1399
  }
1390
1400
  );