mezon-js 2.12.20 → 2.12.22

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.
@@ -7109,15 +7109,13 @@ var _DefaultSocket = class _DefaultSocket {
7109
7109
  message.dropdown_box_selected
7110
7110
  );
7111
7111
  } else if (message.voice_reaction_send) {
7112
- this.onVoiceReactionMessage(
7112
+ this.onvoicereactionmessage(
7113
7113
  message.voice_reaction_send
7114
7114
  );
7115
7115
  } else if (message.webrtc_signaling_fwd) {
7116
7116
  this.onwebrtcsignalingfwd(
7117
7117
  message.webrtc_signaling_fwd
7118
7118
  );
7119
- } else if (message.sfu_signaling_fwd) {
7120
- this.onsfusignalingfwd(message.sfu_signaling_fwd);
7121
7119
  } else if (message.list_activity) {
7122
7120
  this.onactivityupdated(message.list_activity);
7123
7121
  } else if (message.sd_topic_event) {
@@ -7457,7 +7455,7 @@ var _DefaultSocket = class _DefaultSocket {
7457
7455
  console.log(msg);
7458
7456
  }
7459
7457
  }
7460
- onVoiceReactionMessage(event) {
7458
+ onvoicereactionmessage(event) {
7461
7459
  if (this.verbose && window && window.console) {
7462
7460
  console.log(event);
7463
7461
  }
@@ -7467,11 +7465,6 @@ var _DefaultSocket = class _DefaultSocket {
7467
7465
  console.log(event);
7468
7466
  }
7469
7467
  }
7470
- onsfusignalingfwd(event) {
7471
- if (this.verbose && window && window.console) {
7472
- console.log(event);
7473
- }
7474
- }
7475
7468
  onactivityupdated(list_activity) {
7476
7469
  if (this.verbose && window && window.console) {
7477
7470
  console.log(list_activity);
@@ -7810,20 +7803,6 @@ var _DefaultSocket = class _DefaultSocket {
7810
7803
  return response.webrtc_signaling_fwd;
7811
7804
  });
7812
7805
  }
7813
- forwardSFUSignaling(user_id, data_type, json_data, channel_id, clan_id) {
7814
- return __async(this, null, function* () {
7815
- const response = yield this.send({
7816
- sfu_signaling_fwd: {
7817
- user_id,
7818
- data_type,
7819
- json_data,
7820
- channel_id,
7821
- clan_id
7822
- }
7823
- });
7824
- return response.sfu_signaling_fwd;
7825
- });
7826
- }
7827
7806
  makeCallPush(receiver_id, json_data, channel_id, caller_id) {
7828
7807
  return __async(this, null, function* () {
7829
7808
  const response = yield this.send({
@@ -7075,15 +7075,13 @@ var _DefaultSocket = class _DefaultSocket {
7075
7075
  message.dropdown_box_selected
7076
7076
  );
7077
7077
  } else if (message.voice_reaction_send) {
7078
- this.onVoiceReactionMessage(
7078
+ this.onvoicereactionmessage(
7079
7079
  message.voice_reaction_send
7080
7080
  );
7081
7081
  } else if (message.webrtc_signaling_fwd) {
7082
7082
  this.onwebrtcsignalingfwd(
7083
7083
  message.webrtc_signaling_fwd
7084
7084
  );
7085
- } else if (message.sfu_signaling_fwd) {
7086
- this.onsfusignalingfwd(message.sfu_signaling_fwd);
7087
7085
  } else if (message.list_activity) {
7088
7086
  this.onactivityupdated(message.list_activity);
7089
7087
  } else if (message.sd_topic_event) {
@@ -7423,7 +7421,7 @@ var _DefaultSocket = class _DefaultSocket {
7423
7421
  console.log(msg);
7424
7422
  }
7425
7423
  }
7426
- onVoiceReactionMessage(event) {
7424
+ onvoicereactionmessage(event) {
7427
7425
  if (this.verbose && window && window.console) {
7428
7426
  console.log(event);
7429
7427
  }
@@ -7433,11 +7431,6 @@ var _DefaultSocket = class _DefaultSocket {
7433
7431
  console.log(event);
7434
7432
  }
7435
7433
  }
7436
- onsfusignalingfwd(event) {
7437
- if (this.verbose && window && window.console) {
7438
- console.log(event);
7439
- }
7440
- }
7441
7434
  onactivityupdated(list_activity) {
7442
7435
  if (this.verbose && window && window.console) {
7443
7436
  console.log(list_activity);
@@ -7776,20 +7769,6 @@ var _DefaultSocket = class _DefaultSocket {
7776
7769
  return response.webrtc_signaling_fwd;
7777
7770
  });
7778
7771
  }
7779
- forwardSFUSignaling(user_id, data_type, json_data, channel_id, clan_id) {
7780
- return __async(this, null, function* () {
7781
- const response = yield this.send({
7782
- sfu_signaling_fwd: {
7783
- user_id,
7784
- data_type,
7785
- json_data,
7786
- channel_id,
7787
- clan_id
7788
- }
7789
- });
7790
- return response.sfu_signaling_fwd;
7791
- });
7792
- }
7793
7772
  makeCallPush(receiver_id, json_data, channel_id, caller_id) {
7794
7773
  return __async(this, null, function* () {
7795
7774
  const response = yield this.send({
package/dist/socket.d.ts CHANGED
@@ -740,13 +740,6 @@ export interface WebrtcSignalingFwd {
740
740
  channel_id: string;
741
741
  caller_id: string;
742
742
  }
743
- export interface SFUSignalingFwd {
744
- data_type: number;
745
- json_data: string;
746
- channel_id: string;
747
- clan_id: string;
748
- user_id: string;
749
- }
750
743
  export interface ListActivity {
751
744
  acts: ApiUserActivity[];
752
745
  }
@@ -829,7 +822,6 @@ export interface Socket {
829
822
  handleDropdownBoxSelected: (message_id: string, channel_id: string, selectbox_id: string, sender_id: string, user_id: string, value: Array<string>) => Promise<DropdownBoxSelected>;
830
823
  writeVoiceReaction: (emojis: Array<string>, channel_id: string) => Promise<VoiceReactionSend>;
831
824
  forwardWebrtcSignaling: (receiverId: string, dataType: number, jsonData: string, channelId: string, caller_id: string) => Promise<WebrtcSignalingFwd>;
832
- forwardSFUSignaling: (user_id: string, data_type: number, json_data: string, channel_id: string, clan_id: string) => Promise<SFUSignalingFwd>;
833
825
  makeCallPush: (receiverId: string, jsonData: string, channelId: string, caller_id: string) => Promise<IncomingCallPush>;
834
826
  writeChannelAppEvent: (clan_id: string, channel_id: string, action: number) => Promise<ChannelAppEvent>;
835
827
  /** Handle disconnect events received from the socket. */
@@ -896,8 +888,7 @@ export interface Socket {
896
888
  onmessagebuttonclicked: (event: MessageButtonClicked) => void;
897
889
  onmessagedropdownboxselected: (event: DropdownBoxSelected) => void;
898
890
  onwebrtcsignalingfwd: (event: WebrtcSignalingFwd) => void;
899
- onVoiceReactionMessage: (event: VoiceReactionSend) => void;
900
- onsfusignalingfwd: (event: SFUSignalingFwd) => void;
891
+ onvoicereactionmessage: (event: VoiceReactionSend) => void;
901
892
  oneventcreated: (clan_event_created: ApiCreateEventRequest) => void;
902
893
  oncoffeegiven: (give_coffee_event: ApiGiveCoffeeEvent) => void;
903
894
  oneventemoji: (event_emoji: EventEmoji) => void;
@@ -1003,9 +994,8 @@ export declare class DefaultSocket implements Socket {
1003
994
  ontokensent(tokenSentEvent: ApiTokenSentEvent): void;
1004
995
  onmessagebuttonclicked(messageButtonClicked: MessageButtonClicked): void;
1005
996
  onmessagedropdownboxselected(msg: DropdownBoxSelected): void;
1006
- onVoiceReactionMessage(event: VoiceReactionSend): void;
997
+ onvoicereactionmessage(event: VoiceReactionSend): void;
1007
998
  onwebrtcsignalingfwd(event: WebrtcSignalingFwd): void;
1008
- onsfusignalingfwd(event: SFUSignalingFwd): void;
1009
999
  onactivityupdated(list_activity: ListActivity): void;
1010
1000
  onsdtopicevent(sd_topic_event: SdTopicEvent): void;
1011
1001
  onchannelappevent(event: ChannelAppEvent): void;
@@ -1034,7 +1024,6 @@ export declare class DefaultSocket implements Socket {
1034
1024
  checkDuplicateName(name: string, condition_id: string, type: number): Promise<CheckNameExistedEvent>;
1035
1025
  writeVoiceReaction(emojis: Array<string>, channel_id: string): Promise<VoiceReactionSend>;
1036
1026
  forwardWebrtcSignaling(receiver_id: string, data_type: number, json_data: string, channel_id: string, caller_id: string): Promise<WebrtcSignalingFwd>;
1037
- forwardSFUSignaling(user_id: string, data_type: number, json_data: string, channel_id: string, clan_id: string): Promise<SFUSignalingFwd>;
1038
1027
  makeCallPush(receiver_id: string, json_data: string, channel_id: string, caller_id: string): Promise<IncomingCallPush>;
1039
1028
  handleDropdownBoxSelected(message_id: string, channel_id: string, selectbox_id: string, sender_id: string, user_id: string, value: Array<string>): Promise<DropdownBoxSelected>;
1040
1029
  handleMessageButtonClick(message_id: string, channel_id: string, button_id: string, sender_id: string, user_id: string, extra_data: string): Promise<MessageButtonClicked>;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "mezon-js",
3
3
 
4
- "version": "2.12.20",
4
+ "version": "2.12.22",
5
5
 
6
6
  "scripts": {
7
7
  "build": "npx tsc && npx rollup -c --bundleConfigAsCjs && node build.mjs"
package/socket.ts CHANGED
@@ -1057,14 +1057,6 @@ export interface WebrtcSignalingFwd {
1057
1057
  caller_id: string;
1058
1058
  }
1059
1059
 
1060
- export interface SFUSignalingFwd {
1061
- data_type: number;
1062
- json_data: string;
1063
- channel_id: string;
1064
- clan_id: string;
1065
- user_id: string;
1066
- }
1067
-
1068
1060
  export interface ListActivity {
1069
1061
  acts: ApiUserActivity[];
1070
1062
  }
@@ -1393,14 +1385,6 @@ export interface Socket {
1393
1385
  caller_id: string
1394
1386
  ) => Promise<WebrtcSignalingFwd>;
1395
1387
 
1396
- forwardSFUSignaling: (
1397
- user_id: string,
1398
- data_type: number,
1399
- json_data: string,
1400
- channel_id: string,
1401
- clan_id: string
1402
- ) => Promise<SFUSignalingFwd>;
1403
-
1404
1388
  makeCallPush: (
1405
1389
  receiverId: string,
1406
1390
  jsonData: string,
@@ -1533,9 +1517,7 @@ export interface Socket {
1533
1517
 
1534
1518
  onwebrtcsignalingfwd: (event: WebrtcSignalingFwd) => void;
1535
1519
 
1536
- onVoiceReactionMessage: (event: VoiceReactionSend) => void;
1537
-
1538
- onsfusignalingfwd: (event: SFUSignalingFwd) => void;
1520
+ onvoicereactionmessage: (event: VoiceReactionSend) => void;
1539
1521
 
1540
1522
  oneventcreated: (clan_event_created: ApiCreateEventRequest) => void;
1541
1523
 
@@ -1809,15 +1791,13 @@ export class DefaultSocket implements Socket {
1809
1791
  <DropdownBoxSelected>message.dropdown_box_selected
1810
1792
  );
1811
1793
  } else if (message.voice_reaction_send) {
1812
- this.onVoiceReactionMessage(
1794
+ this.onvoicereactionmessage(
1813
1795
  <VoiceReactionSend>message.voice_reaction_send
1814
1796
  );
1815
1797
  } else if (message.webrtc_signaling_fwd) {
1816
1798
  this.onwebrtcsignalingfwd(
1817
1799
  <WebrtcSignalingFwd>message.webrtc_signaling_fwd
1818
1800
  );
1819
- } else if (message.sfu_signaling_fwd) {
1820
- this.onsfusignalingfwd(<SFUSignalingFwd>message.sfu_signaling_fwd);
1821
1801
  } else if (message.list_activity) {
1822
1802
  this.onactivityupdated(<ListActivity>message.list_activity);
1823
1803
  } else if (message.sd_topic_event) {
@@ -2221,7 +2201,7 @@ export class DefaultSocket implements Socket {
2221
2201
  }
2222
2202
  }
2223
2203
 
2224
- onVoiceReactionMessage(event: VoiceReactionSend) {
2204
+ onvoicereactionmessage(event: VoiceReactionSend) {
2225
2205
  if (this.verbose && window && window.console) {
2226
2206
  console.log(event);
2227
2207
  }
@@ -2233,12 +2213,6 @@ export class DefaultSocket implements Socket {
2233
2213
  }
2234
2214
  }
2235
2215
 
2236
- onsfusignalingfwd(event: SFUSignalingFwd) {
2237
- if (this.verbose && window && window.console) {
2238
- console.log(event);
2239
- }
2240
- }
2241
-
2242
2216
  onactivityupdated(list_activity: ListActivity) {
2243
2217
  if (this.verbose && window && window.console) {
2244
2218
  console.log(list_activity);
@@ -2718,25 +2692,6 @@ export class DefaultSocket implements Socket {
2718
2692
  return response.webrtc_signaling_fwd;
2719
2693
  }
2720
2694
 
2721
- async forwardSFUSignaling(
2722
- user_id: string,
2723
- data_type: number,
2724
- json_data: string,
2725
- channel_id: string,
2726
- clan_id: string
2727
- ): Promise<SFUSignalingFwd> {
2728
- const response = await this.send({
2729
- sfu_signaling_fwd: {
2730
- user_id: user_id,
2731
- data_type: data_type,
2732
- json_data: json_data,
2733
- channel_id: channel_id,
2734
- clan_id: clan_id,
2735
- },
2736
- });
2737
- return response.sfu_signaling_fwd;
2738
- }
2739
-
2740
2695
  async makeCallPush(
2741
2696
  receiver_id: string,
2742
2697
  json_data: string,