mezon-js-protobuf 1.8.41 → 1.8.42

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.
@@ -7837,7 +7837,7 @@ var ListThreadRequest = {
7837
7837
  }
7838
7838
  };
7839
7839
  function createBaseListChannelDescsRequest() {
7840
- return { limit: void 0, state: void 0, cursor: "", clan_id: "", channel_type: 0 };
7840
+ return { limit: void 0, state: void 0, cursor: "", clan_id: "", channel_type: 0, is_mobile: false };
7841
7841
  }
7842
7842
  var ListChannelDescsRequest = {
7843
7843
  encode(message, writer = import_minimal4.default.Writer.create()) {
@@ -7856,6 +7856,9 @@ var ListChannelDescsRequest = {
7856
7856
  if (message.channel_type !== 0) {
7857
7857
  writer.uint32(40).int32(message.channel_type);
7858
7858
  }
7859
+ if (message.is_mobile !== false) {
7860
+ writer.uint32(48).bool(message.is_mobile);
7861
+ }
7859
7862
  return writer;
7860
7863
  },
7861
7864
  decode(input, length) {
@@ -7895,6 +7898,12 @@ var ListChannelDescsRequest = {
7895
7898
  }
7896
7899
  message.channel_type = reader.int32();
7897
7900
  continue;
7901
+ case 6:
7902
+ if (tag !== 48) {
7903
+ break;
7904
+ }
7905
+ message.is_mobile = reader.bool();
7906
+ continue;
7898
7907
  }
7899
7908
  if ((tag & 7) === 4 || tag === 0) {
7900
7909
  break;
@@ -7909,7 +7918,8 @@ var ListChannelDescsRequest = {
7909
7918
  state: isSet3(object.state) ? Number(object.state) : void 0,
7910
7919
  cursor: isSet3(object.cursor) ? globalThis.String(object.cursor) : "",
7911
7920
  clan_id: isSet3(object.clan_id) ? globalThis.String(object.clan_id) : "",
7912
- channel_type: isSet3(object.channel_type) ? globalThis.Number(object.channel_type) : 0
7921
+ channel_type: isSet3(object.channel_type) ? globalThis.Number(object.channel_type) : 0,
7922
+ is_mobile: isSet3(object.is_mobile) ? globalThis.Boolean(object.is_mobile) : false
7913
7923
  };
7914
7924
  },
7915
7925
  toJSON(message) {
@@ -7929,19 +7939,23 @@ var ListChannelDescsRequest = {
7929
7939
  if (message.channel_type !== 0) {
7930
7940
  obj.channel_type = Math.round(message.channel_type);
7931
7941
  }
7942
+ if (message.is_mobile !== false) {
7943
+ obj.is_mobile = message.is_mobile;
7944
+ }
7932
7945
  return obj;
7933
7946
  },
7934
7947
  create(base) {
7935
7948
  return ListChannelDescsRequest.fromPartial(base != null ? base : {});
7936
7949
  },
7937
7950
  fromPartial(object) {
7938
- var _a, _b, _c, _d, _e;
7951
+ var _a, _b, _c, _d, _e, _f;
7939
7952
  const message = createBaseListChannelDescsRequest();
7940
7953
  message.limit = (_a = object.limit) != null ? _a : void 0;
7941
7954
  message.state = (_b = object.state) != null ? _b : void 0;
7942
7955
  message.cursor = (_c = object.cursor) != null ? _c : "";
7943
7956
  message.clan_id = (_d = object.clan_id) != null ? _d : "";
7944
7957
  message.channel_type = (_e = object.channel_type) != null ? _e : 0;
7958
+ message.is_mobile = (_f = object.is_mobile) != null ? _f : false;
7945
7959
  return message;
7946
7960
  }
7947
7961
  };
@@ -11238,7 +11252,7 @@ var AllUsersAddChannelRequest = {
11238
11252
  }
11239
11253
  };
11240
11254
  function createBaseAllUsersAddChannelResponse() {
11241
- return { channel_id: "", user_ids: [], limit: void 0 };
11255
+ return { channel_id: "", user_ids: [], limit: void 0, usernames: [], display_names: [], avatars: [], onlines: [] };
11242
11256
  }
11243
11257
  var AllUsersAddChannelResponse = {
11244
11258
  encode(message, writer = import_minimal4.default.Writer.create()) {
@@ -11251,6 +11265,20 @@ var AllUsersAddChannelResponse = {
11251
11265
  if (message.limit !== void 0) {
11252
11266
  Int32Value.encode({ value: message.limit }, writer.uint32(26).fork()).ldelim();
11253
11267
  }
11268
+ for (const v of message.usernames) {
11269
+ writer.uint32(34).string(v);
11270
+ }
11271
+ for (const v of message.display_names) {
11272
+ writer.uint32(42).string(v);
11273
+ }
11274
+ for (const v of message.avatars) {
11275
+ writer.uint32(50).string(v);
11276
+ }
11277
+ writer.uint32(58).fork();
11278
+ for (const v of message.onlines) {
11279
+ writer.bool(v);
11280
+ }
11281
+ writer.ldelim();
11254
11282
  return writer;
11255
11283
  },
11256
11284
  decode(input, length) {
@@ -11278,6 +11306,37 @@ var AllUsersAddChannelResponse = {
11278
11306
  }
11279
11307
  message.limit = Int32Value.decode(reader, reader.uint32()).value;
11280
11308
  continue;
11309
+ case 4:
11310
+ if (tag !== 34) {
11311
+ break;
11312
+ }
11313
+ message.usernames.push(reader.string());
11314
+ continue;
11315
+ case 5:
11316
+ if (tag !== 42) {
11317
+ break;
11318
+ }
11319
+ message.display_names.push(reader.string());
11320
+ continue;
11321
+ case 6:
11322
+ if (tag !== 50) {
11323
+ break;
11324
+ }
11325
+ message.avatars.push(reader.string());
11326
+ continue;
11327
+ case 7:
11328
+ if (tag === 56) {
11329
+ message.onlines.push(reader.bool());
11330
+ continue;
11331
+ }
11332
+ if (tag === 58) {
11333
+ const end2 = reader.uint32() + reader.pos;
11334
+ while (reader.pos < end2) {
11335
+ message.onlines.push(reader.bool());
11336
+ }
11337
+ continue;
11338
+ }
11339
+ break;
11281
11340
  }
11282
11341
  if ((tag & 7) === 4 || tag === 0) {
11283
11342
  break;
@@ -11290,11 +11349,15 @@ var AllUsersAddChannelResponse = {
11290
11349
  return {
11291
11350
  channel_id: isSet3(object.channel_id) ? globalThis.String(object.channel_id) : "",
11292
11351
  user_ids: globalThis.Array.isArray(object == null ? void 0 : object.user_ids) ? object.user_ids.map((e) => globalThis.String(e)) : [],
11293
- limit: isSet3(object.limit) ? Number(object.limit) : void 0
11352
+ limit: isSet3(object.limit) ? Number(object.limit) : void 0,
11353
+ usernames: globalThis.Array.isArray(object == null ? void 0 : object.usernames) ? object.usernames.map((e) => globalThis.String(e)) : [],
11354
+ display_names: globalThis.Array.isArray(object == null ? void 0 : object.display_names) ? object.display_names.map((e) => globalThis.String(e)) : [],
11355
+ avatars: globalThis.Array.isArray(object == null ? void 0 : object.avatars) ? object.avatars.map((e) => globalThis.String(e)) : [],
11356
+ onlines: globalThis.Array.isArray(object == null ? void 0 : object.onlines) ? object.onlines.map((e) => globalThis.Boolean(e)) : []
11294
11357
  };
11295
11358
  },
11296
11359
  toJSON(message) {
11297
- var _a;
11360
+ var _a, _b, _c, _d, _e;
11298
11361
  const obj = {};
11299
11362
  if (message.channel_id !== "") {
11300
11363
  obj.channel_id = message.channel_id;
@@ -11305,17 +11368,33 @@ var AllUsersAddChannelResponse = {
11305
11368
  if (message.limit !== void 0) {
11306
11369
  obj.limit = message.limit;
11307
11370
  }
11371
+ if ((_b = message.usernames) == null ? void 0 : _b.length) {
11372
+ obj.usernames = message.usernames;
11373
+ }
11374
+ if ((_c = message.display_names) == null ? void 0 : _c.length) {
11375
+ obj.display_names = message.display_names;
11376
+ }
11377
+ if ((_d = message.avatars) == null ? void 0 : _d.length) {
11378
+ obj.avatars = message.avatars;
11379
+ }
11380
+ if ((_e = message.onlines) == null ? void 0 : _e.length) {
11381
+ obj.onlines = message.onlines;
11382
+ }
11308
11383
  return obj;
11309
11384
  },
11310
11385
  create(base) {
11311
11386
  return AllUsersAddChannelResponse.fromPartial(base != null ? base : {});
11312
11387
  },
11313
11388
  fromPartial(object) {
11314
- var _a, _b, _c;
11389
+ var _a, _b, _c, _d, _e, _f, _g;
11315
11390
  const message = createBaseAllUsersAddChannelResponse();
11316
11391
  message.channel_id = (_a = object.channel_id) != null ? _a : "";
11317
11392
  message.user_ids = ((_b = object.user_ids) == null ? void 0 : _b.map((e) => e)) || [];
11318
11393
  message.limit = (_c = object.limit) != null ? _c : void 0;
11394
+ message.usernames = ((_d = object.usernames) == null ? void 0 : _d.map((e) => e)) || [];
11395
+ message.display_names = ((_e = object.display_names) == null ? void 0 : _e.map((e) => e)) || [];
11396
+ message.avatars = ((_f = object.avatars) == null ? void 0 : _f.map((e) => e)) || [];
11397
+ message.onlines = ((_g = object.onlines) == null ? void 0 : _g.map((e) => e)) || [];
11319
11398
  return message;
11320
11399
  }
11321
11400
  };
@@ -7824,7 +7824,7 @@ var ListThreadRequest = {
7824
7824
  }
7825
7825
  };
7826
7826
  function createBaseListChannelDescsRequest() {
7827
- return { limit: void 0, state: void 0, cursor: "", clan_id: "", channel_type: 0 };
7827
+ return { limit: void 0, state: void 0, cursor: "", clan_id: "", channel_type: 0, is_mobile: false };
7828
7828
  }
7829
7829
  var ListChannelDescsRequest = {
7830
7830
  encode(message, writer = import_minimal4.default.Writer.create()) {
@@ -7843,6 +7843,9 @@ var ListChannelDescsRequest = {
7843
7843
  if (message.channel_type !== 0) {
7844
7844
  writer.uint32(40).int32(message.channel_type);
7845
7845
  }
7846
+ if (message.is_mobile !== false) {
7847
+ writer.uint32(48).bool(message.is_mobile);
7848
+ }
7846
7849
  return writer;
7847
7850
  },
7848
7851
  decode(input, length) {
@@ -7882,6 +7885,12 @@ var ListChannelDescsRequest = {
7882
7885
  }
7883
7886
  message.channel_type = reader.int32();
7884
7887
  continue;
7888
+ case 6:
7889
+ if (tag !== 48) {
7890
+ break;
7891
+ }
7892
+ message.is_mobile = reader.bool();
7893
+ continue;
7885
7894
  }
7886
7895
  if ((tag & 7) === 4 || tag === 0) {
7887
7896
  break;
@@ -7896,7 +7905,8 @@ var ListChannelDescsRequest = {
7896
7905
  state: isSet3(object.state) ? Number(object.state) : void 0,
7897
7906
  cursor: isSet3(object.cursor) ? globalThis.String(object.cursor) : "",
7898
7907
  clan_id: isSet3(object.clan_id) ? globalThis.String(object.clan_id) : "",
7899
- channel_type: isSet3(object.channel_type) ? globalThis.Number(object.channel_type) : 0
7908
+ channel_type: isSet3(object.channel_type) ? globalThis.Number(object.channel_type) : 0,
7909
+ is_mobile: isSet3(object.is_mobile) ? globalThis.Boolean(object.is_mobile) : false
7900
7910
  };
7901
7911
  },
7902
7912
  toJSON(message) {
@@ -7916,19 +7926,23 @@ var ListChannelDescsRequest = {
7916
7926
  if (message.channel_type !== 0) {
7917
7927
  obj.channel_type = Math.round(message.channel_type);
7918
7928
  }
7929
+ if (message.is_mobile !== false) {
7930
+ obj.is_mobile = message.is_mobile;
7931
+ }
7919
7932
  return obj;
7920
7933
  },
7921
7934
  create(base) {
7922
7935
  return ListChannelDescsRequest.fromPartial(base != null ? base : {});
7923
7936
  },
7924
7937
  fromPartial(object) {
7925
- var _a, _b, _c, _d, _e;
7938
+ var _a, _b, _c, _d, _e, _f;
7926
7939
  const message = createBaseListChannelDescsRequest();
7927
7940
  message.limit = (_a = object.limit) != null ? _a : void 0;
7928
7941
  message.state = (_b = object.state) != null ? _b : void 0;
7929
7942
  message.cursor = (_c = object.cursor) != null ? _c : "";
7930
7943
  message.clan_id = (_d = object.clan_id) != null ? _d : "";
7931
7944
  message.channel_type = (_e = object.channel_type) != null ? _e : 0;
7945
+ message.is_mobile = (_f = object.is_mobile) != null ? _f : false;
7932
7946
  return message;
7933
7947
  }
7934
7948
  };
@@ -11225,7 +11239,7 @@ var AllUsersAddChannelRequest = {
11225
11239
  }
11226
11240
  };
11227
11241
  function createBaseAllUsersAddChannelResponse() {
11228
- return { channel_id: "", user_ids: [], limit: void 0 };
11242
+ return { channel_id: "", user_ids: [], limit: void 0, usernames: [], display_names: [], avatars: [], onlines: [] };
11229
11243
  }
11230
11244
  var AllUsersAddChannelResponse = {
11231
11245
  encode(message, writer = import_minimal4.default.Writer.create()) {
@@ -11238,6 +11252,20 @@ var AllUsersAddChannelResponse = {
11238
11252
  if (message.limit !== void 0) {
11239
11253
  Int32Value.encode({ value: message.limit }, writer.uint32(26).fork()).ldelim();
11240
11254
  }
11255
+ for (const v of message.usernames) {
11256
+ writer.uint32(34).string(v);
11257
+ }
11258
+ for (const v of message.display_names) {
11259
+ writer.uint32(42).string(v);
11260
+ }
11261
+ for (const v of message.avatars) {
11262
+ writer.uint32(50).string(v);
11263
+ }
11264
+ writer.uint32(58).fork();
11265
+ for (const v of message.onlines) {
11266
+ writer.bool(v);
11267
+ }
11268
+ writer.ldelim();
11241
11269
  return writer;
11242
11270
  },
11243
11271
  decode(input, length) {
@@ -11265,6 +11293,37 @@ var AllUsersAddChannelResponse = {
11265
11293
  }
11266
11294
  message.limit = Int32Value.decode(reader, reader.uint32()).value;
11267
11295
  continue;
11296
+ case 4:
11297
+ if (tag !== 34) {
11298
+ break;
11299
+ }
11300
+ message.usernames.push(reader.string());
11301
+ continue;
11302
+ case 5:
11303
+ if (tag !== 42) {
11304
+ break;
11305
+ }
11306
+ message.display_names.push(reader.string());
11307
+ continue;
11308
+ case 6:
11309
+ if (tag !== 50) {
11310
+ break;
11311
+ }
11312
+ message.avatars.push(reader.string());
11313
+ continue;
11314
+ case 7:
11315
+ if (tag === 56) {
11316
+ message.onlines.push(reader.bool());
11317
+ continue;
11318
+ }
11319
+ if (tag === 58) {
11320
+ const end2 = reader.uint32() + reader.pos;
11321
+ while (reader.pos < end2) {
11322
+ message.onlines.push(reader.bool());
11323
+ }
11324
+ continue;
11325
+ }
11326
+ break;
11268
11327
  }
11269
11328
  if ((tag & 7) === 4 || tag === 0) {
11270
11329
  break;
@@ -11277,11 +11336,15 @@ var AllUsersAddChannelResponse = {
11277
11336
  return {
11278
11337
  channel_id: isSet3(object.channel_id) ? globalThis.String(object.channel_id) : "",
11279
11338
  user_ids: globalThis.Array.isArray(object == null ? void 0 : object.user_ids) ? object.user_ids.map((e) => globalThis.String(e)) : [],
11280
- limit: isSet3(object.limit) ? Number(object.limit) : void 0
11339
+ limit: isSet3(object.limit) ? Number(object.limit) : void 0,
11340
+ usernames: globalThis.Array.isArray(object == null ? void 0 : object.usernames) ? object.usernames.map((e) => globalThis.String(e)) : [],
11341
+ display_names: globalThis.Array.isArray(object == null ? void 0 : object.display_names) ? object.display_names.map((e) => globalThis.String(e)) : [],
11342
+ avatars: globalThis.Array.isArray(object == null ? void 0 : object.avatars) ? object.avatars.map((e) => globalThis.String(e)) : [],
11343
+ onlines: globalThis.Array.isArray(object == null ? void 0 : object.onlines) ? object.onlines.map((e) => globalThis.Boolean(e)) : []
11281
11344
  };
11282
11345
  },
11283
11346
  toJSON(message) {
11284
- var _a;
11347
+ var _a, _b, _c, _d, _e;
11285
11348
  const obj = {};
11286
11349
  if (message.channel_id !== "") {
11287
11350
  obj.channel_id = message.channel_id;
@@ -11292,17 +11355,33 @@ var AllUsersAddChannelResponse = {
11292
11355
  if (message.limit !== void 0) {
11293
11356
  obj.limit = message.limit;
11294
11357
  }
11358
+ if ((_b = message.usernames) == null ? void 0 : _b.length) {
11359
+ obj.usernames = message.usernames;
11360
+ }
11361
+ if ((_c = message.display_names) == null ? void 0 : _c.length) {
11362
+ obj.display_names = message.display_names;
11363
+ }
11364
+ if ((_d = message.avatars) == null ? void 0 : _d.length) {
11365
+ obj.avatars = message.avatars;
11366
+ }
11367
+ if ((_e = message.onlines) == null ? void 0 : _e.length) {
11368
+ obj.onlines = message.onlines;
11369
+ }
11295
11370
  return obj;
11296
11371
  },
11297
11372
  create(base) {
11298
11373
  return AllUsersAddChannelResponse.fromPartial(base != null ? base : {});
11299
11374
  },
11300
11375
  fromPartial(object) {
11301
- var _a, _b, _c;
11376
+ var _a, _b, _c, _d, _e, _f, _g;
11302
11377
  const message = createBaseAllUsersAddChannelResponse();
11303
11378
  message.channel_id = (_a = object.channel_id) != null ? _a : "";
11304
11379
  message.user_ids = ((_b = object.user_ids) == null ? void 0 : _b.map((e) => e)) || [];
11305
11380
  message.limit = (_c = object.limit) != null ? _c : void 0;
11381
+ message.usernames = ((_d = object.usernames) == null ? void 0 : _d.map((e) => e)) || [];
11382
+ message.display_names = ((_e = object.display_names) == null ? void 0 : _e.map((e) => e)) || [];
11383
+ message.avatars = ((_f = object.avatars) == null ? void 0 : _f.map((e) => e)) || [];
11384
+ message.onlines = ((_g = object.onlines) == null ? void 0 : _g.map((e) => e)) || [];
11306
11385
  return message;
11307
11386
  }
11308
11387
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "mezon-js-protobuf",
3
- "version": "1.8.41",
3
+ "version": "1.8.42",
4
4
  "description": "Websocket adapter adding protocol buffer support to the Mezon Javascript client.",
5
5
  "main": "dist/mezon-js-protobuf.cjs.js",
6
6
  "module": "dist/mezon-js-protobuf.esm.mjs",