mezon-js-protobuf 1.8.76 → 1.8.77
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/api/api.ts +131 -9
- package/dist/mezon-js-protobuf/api/api.d.ts +53 -15
- package/dist/mezon-js-protobuf/rtapi/realtime.d.ts +621 -543
- package/dist/mezon-js-protobuf.cjs.js +142 -10
- package/dist/mezon-js-protobuf.esm.mjs +142 -10
- package/package.json +1 -1
- package/rtapi/realtime.ts +54 -9
|
@@ -5505,7 +5505,7 @@ function createBaseNotification() {
|
|
|
5505
5505
|
return {
|
|
5506
5506
|
id: "",
|
|
5507
5507
|
subject: "",
|
|
5508
|
-
content:
|
|
5508
|
+
content: new Uint8Array(0),
|
|
5509
5509
|
code: 0,
|
|
5510
5510
|
sender_id: "",
|
|
5511
5511
|
create_time: void 0,
|
|
@@ -5527,8 +5527,8 @@ var Notification = {
|
|
|
5527
5527
|
if (message.subject !== "") {
|
|
5528
5528
|
writer.uint32(18).string(message.subject);
|
|
5529
5529
|
}
|
|
5530
|
-
if (message.content !==
|
|
5531
|
-
writer.uint32(26).
|
|
5530
|
+
if (message.content.length !== 0) {
|
|
5531
|
+
writer.uint32(26).bytes(message.content);
|
|
5532
5532
|
}
|
|
5533
5533
|
if (message.code !== 0) {
|
|
5534
5534
|
writer.uint32(32).int32(message.code);
|
|
@@ -5588,7 +5588,7 @@ var Notification = {
|
|
|
5588
5588
|
if (tag !== 26) {
|
|
5589
5589
|
break;
|
|
5590
5590
|
}
|
|
5591
|
-
message.content = reader.
|
|
5591
|
+
message.content = reader.bytes();
|
|
5592
5592
|
continue;
|
|
5593
5593
|
case 4:
|
|
5594
5594
|
if (tag !== 32) {
|
|
@@ -5668,7 +5668,7 @@ var Notification = {
|
|
|
5668
5668
|
return {
|
|
5669
5669
|
id: isSet3(object.id) ? globalThis.String(object.id) : "",
|
|
5670
5670
|
subject: isSet3(object.subject) ? globalThis.String(object.subject) : "",
|
|
5671
|
-
content: isSet3(object.content) ?
|
|
5671
|
+
content: isSet3(object.content) ? bytesFromBase64(object.content) : new Uint8Array(0),
|
|
5672
5672
|
code: isSet3(object.code) ? globalThis.Number(object.code) : 0,
|
|
5673
5673
|
sender_id: isSet3(object.sender_id) ? globalThis.String(object.sender_id) : "",
|
|
5674
5674
|
create_time: isSet3(object.create_time) ? fromJsonTimestamp(object.create_time) : void 0,
|
|
@@ -5690,8 +5690,8 @@ var Notification = {
|
|
|
5690
5690
|
if (message.subject !== "") {
|
|
5691
5691
|
obj.subject = message.subject;
|
|
5692
5692
|
}
|
|
5693
|
-
if (message.content !==
|
|
5694
|
-
obj.content = message.content;
|
|
5693
|
+
if (message.content.length !== 0) {
|
|
5694
|
+
obj.content = base64FromBytes(message.content);
|
|
5695
5695
|
}
|
|
5696
5696
|
if (message.code !== 0) {
|
|
5697
5697
|
obj.code = Math.round(message.code);
|
|
@@ -5736,7 +5736,7 @@ var Notification = {
|
|
|
5736
5736
|
const message = createBaseNotification();
|
|
5737
5737
|
message.id = (_a = object.id) != null ? _a : "";
|
|
5738
5738
|
message.subject = (_b = object.subject) != null ? _b : "";
|
|
5739
|
-
message.content = (_c = object.content) != null ? _c :
|
|
5739
|
+
message.content = (_c = object.content) != null ? _c : new Uint8Array(0);
|
|
5740
5740
|
message.code = (_d = object.code) != null ? _d : 0;
|
|
5741
5741
|
message.sender_id = (_e = object.sender_id) != null ? _e : "";
|
|
5742
5742
|
message.create_time = (_f = object.create_time) != null ? _f : void 0;
|
|
@@ -14746,6 +14746,108 @@ var MessageRefList = {
|
|
|
14746
14746
|
return message;
|
|
14747
14747
|
}
|
|
14748
14748
|
};
|
|
14749
|
+
function createBaseListClanBadgeCountRequest() {
|
|
14750
|
+
return { clan_id: "" };
|
|
14751
|
+
}
|
|
14752
|
+
var ListClanBadgeCountRequest = {
|
|
14753
|
+
encode(message, writer = import_minimal4.default.Writer.create()) {
|
|
14754
|
+
if (message.clan_id !== "") {
|
|
14755
|
+
writer.uint32(10).string(message.clan_id);
|
|
14756
|
+
}
|
|
14757
|
+
return writer;
|
|
14758
|
+
},
|
|
14759
|
+
decode(input, length) {
|
|
14760
|
+
const reader = input instanceof import_minimal4.default.Reader ? input : import_minimal4.default.Reader.create(input);
|
|
14761
|
+
let end = length === void 0 ? reader.len : reader.pos + length;
|
|
14762
|
+
const message = createBaseListClanBadgeCountRequest();
|
|
14763
|
+
while (reader.pos < end) {
|
|
14764
|
+
const tag = reader.uint32();
|
|
14765
|
+
switch (tag >>> 3) {
|
|
14766
|
+
case 1:
|
|
14767
|
+
if (tag !== 10) {
|
|
14768
|
+
break;
|
|
14769
|
+
}
|
|
14770
|
+
message.clan_id = reader.string();
|
|
14771
|
+
continue;
|
|
14772
|
+
}
|
|
14773
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
14774
|
+
break;
|
|
14775
|
+
}
|
|
14776
|
+
reader.skipType(tag & 7);
|
|
14777
|
+
}
|
|
14778
|
+
return message;
|
|
14779
|
+
},
|
|
14780
|
+
fromJSON(object) {
|
|
14781
|
+
return { clan_id: isSet3(object.clan_id) ? globalThis.String(object.clan_id) : "" };
|
|
14782
|
+
},
|
|
14783
|
+
toJSON(message) {
|
|
14784
|
+
const obj = {};
|
|
14785
|
+
if (message.clan_id !== "") {
|
|
14786
|
+
obj.clan_id = message.clan_id;
|
|
14787
|
+
}
|
|
14788
|
+
return obj;
|
|
14789
|
+
},
|
|
14790
|
+
create(base) {
|
|
14791
|
+
return ListClanBadgeCountRequest.fromPartial(base != null ? base : {});
|
|
14792
|
+
},
|
|
14793
|
+
fromPartial(object) {
|
|
14794
|
+
var _a;
|
|
14795
|
+
const message = createBaseListClanBadgeCountRequest();
|
|
14796
|
+
message.clan_id = (_a = object.clan_id) != null ? _a : "";
|
|
14797
|
+
return message;
|
|
14798
|
+
}
|
|
14799
|
+
};
|
|
14800
|
+
function createBaseListClanBadgeCountResponse() {
|
|
14801
|
+
return { badge_count: 0 };
|
|
14802
|
+
}
|
|
14803
|
+
var ListClanBadgeCountResponse = {
|
|
14804
|
+
encode(message, writer = import_minimal4.default.Writer.create()) {
|
|
14805
|
+
if (message.badge_count !== 0) {
|
|
14806
|
+
writer.uint32(8).int32(message.badge_count);
|
|
14807
|
+
}
|
|
14808
|
+
return writer;
|
|
14809
|
+
},
|
|
14810
|
+
decode(input, length) {
|
|
14811
|
+
const reader = input instanceof import_minimal4.default.Reader ? input : import_minimal4.default.Reader.create(input);
|
|
14812
|
+
let end = length === void 0 ? reader.len : reader.pos + length;
|
|
14813
|
+
const message = createBaseListClanBadgeCountResponse();
|
|
14814
|
+
while (reader.pos < end) {
|
|
14815
|
+
const tag = reader.uint32();
|
|
14816
|
+
switch (tag >>> 3) {
|
|
14817
|
+
case 1:
|
|
14818
|
+
if (tag !== 8) {
|
|
14819
|
+
break;
|
|
14820
|
+
}
|
|
14821
|
+
message.badge_count = reader.int32();
|
|
14822
|
+
continue;
|
|
14823
|
+
}
|
|
14824
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
14825
|
+
break;
|
|
14826
|
+
}
|
|
14827
|
+
reader.skipType(tag & 7);
|
|
14828
|
+
}
|
|
14829
|
+
return message;
|
|
14830
|
+
},
|
|
14831
|
+
fromJSON(object) {
|
|
14832
|
+
return { badge_count: isSet3(object.badge_count) ? globalThis.Number(object.badge_count) : 0 };
|
|
14833
|
+
},
|
|
14834
|
+
toJSON(message) {
|
|
14835
|
+
const obj = {};
|
|
14836
|
+
if (message.badge_count !== 0) {
|
|
14837
|
+
obj.badge_count = Math.round(message.badge_count);
|
|
14838
|
+
}
|
|
14839
|
+
return obj;
|
|
14840
|
+
},
|
|
14841
|
+
create(base) {
|
|
14842
|
+
return ListClanBadgeCountResponse.fromPartial(base != null ? base : {});
|
|
14843
|
+
},
|
|
14844
|
+
fromPartial(object) {
|
|
14845
|
+
var _a;
|
|
14846
|
+
const message = createBaseListClanBadgeCountResponse();
|
|
14847
|
+
message.badge_count = (_a = object.badge_count) != null ? _a : 0;
|
|
14848
|
+
return message;
|
|
14849
|
+
}
|
|
14850
|
+
};
|
|
14749
14851
|
function bytesFromBase64(b64) {
|
|
14750
14852
|
if (globalThis.Buffer) {
|
|
14751
14853
|
return Uint8Array.from(globalThis.Buffer.from(b64, "base64"));
|
|
@@ -25463,7 +25565,9 @@ function createBaseListDataSocket() {
|
|
|
25463
25565
|
category_list: void 0,
|
|
25464
25566
|
stream_user_list: void 0,
|
|
25465
25567
|
list_unread_msg_indicator_req: void 0,
|
|
25466
|
-
unread_msg_indicator: void 0
|
|
25568
|
+
unread_msg_indicator: void 0,
|
|
25569
|
+
list_clan_badge_count_req: void 0,
|
|
25570
|
+
clan_badge_count: void 0
|
|
25467
25571
|
};
|
|
25468
25572
|
}
|
|
25469
25573
|
var ListDataSocket = {
|
|
@@ -25666,6 +25770,12 @@ var ListDataSocket = {
|
|
|
25666
25770
|
if (message.unread_msg_indicator !== void 0) {
|
|
25667
25771
|
ListClanUnreadMsgIndicatorResponse.encode(message.unread_msg_indicator, writer.uint32(530).fork()).ldelim();
|
|
25668
25772
|
}
|
|
25773
|
+
if (message.list_clan_badge_count_req !== void 0) {
|
|
25774
|
+
ListClanBadgeCountRequest.encode(message.list_clan_badge_count_req, writer.uint32(538).fork()).ldelim();
|
|
25775
|
+
}
|
|
25776
|
+
if (message.clan_badge_count !== void 0) {
|
|
25777
|
+
ListClanBadgeCountResponse.encode(message.clan_badge_count, writer.uint32(546).fork()).ldelim();
|
|
25778
|
+
}
|
|
25669
25779
|
return writer;
|
|
25670
25780
|
},
|
|
25671
25781
|
decode(input, length) {
|
|
@@ -26074,6 +26184,18 @@ var ListDataSocket = {
|
|
|
26074
26184
|
}
|
|
26075
26185
|
message.unread_msg_indicator = ListClanUnreadMsgIndicatorResponse.decode(reader, reader.uint32());
|
|
26076
26186
|
continue;
|
|
26187
|
+
case 67:
|
|
26188
|
+
if (tag !== 538) {
|
|
26189
|
+
break;
|
|
26190
|
+
}
|
|
26191
|
+
message.list_clan_badge_count_req = ListClanBadgeCountRequest.decode(reader, reader.uint32());
|
|
26192
|
+
continue;
|
|
26193
|
+
case 68:
|
|
26194
|
+
if (tag !== 546) {
|
|
26195
|
+
break;
|
|
26196
|
+
}
|
|
26197
|
+
message.clan_badge_count = ListClanBadgeCountResponse.decode(reader, reader.uint32());
|
|
26198
|
+
continue;
|
|
26077
26199
|
}
|
|
26078
26200
|
if ((tag & 7) === 4 || tag === 0) {
|
|
26079
26201
|
break;
|
|
@@ -26149,7 +26271,9 @@ var ListDataSocket = {
|
|
|
26149
26271
|
category_list: isSet4(object.category_list) ? CategoryDescList.fromJSON(object.category_list) : void 0,
|
|
26150
26272
|
stream_user_list: isSet4(object.stream_user_list) ? StreamingChannelUserList.fromJSON(object.stream_user_list) : void 0,
|
|
26151
26273
|
list_unread_msg_indicator_req: isSet4(object.list_unread_msg_indicator_req) ? ListClanUnreadMsgIndicatorRequest.fromJSON(object.list_unread_msg_indicator_req) : void 0,
|
|
26152
|
-
unread_msg_indicator: isSet4(object.unread_msg_indicator) ? ListClanUnreadMsgIndicatorResponse.fromJSON(object.unread_msg_indicator) : void 0
|
|
26274
|
+
unread_msg_indicator: isSet4(object.unread_msg_indicator) ? ListClanUnreadMsgIndicatorResponse.fromJSON(object.unread_msg_indicator) : void 0,
|
|
26275
|
+
list_clan_badge_count_req: isSet4(object.list_clan_badge_count_req) ? ListClanBadgeCountRequest.fromJSON(object.list_clan_badge_count_req) : void 0,
|
|
26276
|
+
clan_badge_count: isSet4(object.clan_badge_count) ? ListClanBadgeCountResponse.fromJSON(object.clan_badge_count) : void 0
|
|
26153
26277
|
};
|
|
26154
26278
|
},
|
|
26155
26279
|
toJSON(message) {
|
|
@@ -26356,6 +26480,12 @@ var ListDataSocket = {
|
|
|
26356
26480
|
if (message.unread_msg_indicator !== void 0) {
|
|
26357
26481
|
obj.unread_msg_indicator = ListClanUnreadMsgIndicatorResponse.toJSON(message.unread_msg_indicator);
|
|
26358
26482
|
}
|
|
26483
|
+
if (message.list_clan_badge_count_req !== void 0) {
|
|
26484
|
+
obj.list_clan_badge_count_req = ListClanBadgeCountRequest.toJSON(message.list_clan_badge_count_req);
|
|
26485
|
+
}
|
|
26486
|
+
if (message.clan_badge_count !== void 0) {
|
|
26487
|
+
obj.clan_badge_count = ListClanBadgeCountResponse.toJSON(message.clan_badge_count);
|
|
26488
|
+
}
|
|
26359
26489
|
return obj;
|
|
26360
26490
|
},
|
|
26361
26491
|
create(base) {
|
|
@@ -26430,6 +26560,8 @@ var ListDataSocket = {
|
|
|
26430
26560
|
message.stream_user_list = object.stream_user_list !== void 0 && object.stream_user_list !== null ? StreamingChannelUserList.fromPartial(object.stream_user_list) : void 0;
|
|
26431
26561
|
message.list_unread_msg_indicator_req = object.list_unread_msg_indicator_req !== void 0 && object.list_unread_msg_indicator_req !== null ? ListClanUnreadMsgIndicatorRequest.fromPartial(object.list_unread_msg_indicator_req) : void 0;
|
|
26432
26562
|
message.unread_msg_indicator = object.unread_msg_indicator !== void 0 && object.unread_msg_indicator !== null ? ListClanUnreadMsgIndicatorResponse.fromPartial(object.unread_msg_indicator) : void 0;
|
|
26563
|
+
message.list_clan_badge_count_req = object.list_clan_badge_count_req !== void 0 && object.list_clan_badge_count_req !== null ? ListClanBadgeCountRequest.fromPartial(object.list_clan_badge_count_req) : void 0;
|
|
26564
|
+
message.clan_badge_count = object.clan_badge_count !== void 0 && object.clan_badge_count !== null ? ListClanBadgeCountResponse.fromPartial(object.clan_badge_count) : void 0;
|
|
26433
26565
|
return message;
|
|
26434
26566
|
}
|
|
26435
26567
|
};
|
|
@@ -5488,7 +5488,7 @@ function createBaseNotification() {
|
|
|
5488
5488
|
return {
|
|
5489
5489
|
id: "",
|
|
5490
5490
|
subject: "",
|
|
5491
|
-
content:
|
|
5491
|
+
content: new Uint8Array(0),
|
|
5492
5492
|
code: 0,
|
|
5493
5493
|
sender_id: "",
|
|
5494
5494
|
create_time: void 0,
|
|
@@ -5510,8 +5510,8 @@ var Notification = {
|
|
|
5510
5510
|
if (message.subject !== "") {
|
|
5511
5511
|
writer.uint32(18).string(message.subject);
|
|
5512
5512
|
}
|
|
5513
|
-
if (message.content !==
|
|
5514
|
-
writer.uint32(26).
|
|
5513
|
+
if (message.content.length !== 0) {
|
|
5514
|
+
writer.uint32(26).bytes(message.content);
|
|
5515
5515
|
}
|
|
5516
5516
|
if (message.code !== 0) {
|
|
5517
5517
|
writer.uint32(32).int32(message.code);
|
|
@@ -5571,7 +5571,7 @@ var Notification = {
|
|
|
5571
5571
|
if (tag !== 26) {
|
|
5572
5572
|
break;
|
|
5573
5573
|
}
|
|
5574
|
-
message.content = reader.
|
|
5574
|
+
message.content = reader.bytes();
|
|
5575
5575
|
continue;
|
|
5576
5576
|
case 4:
|
|
5577
5577
|
if (tag !== 32) {
|
|
@@ -5651,7 +5651,7 @@ var Notification = {
|
|
|
5651
5651
|
return {
|
|
5652
5652
|
id: isSet3(object.id) ? globalThis.String(object.id) : "",
|
|
5653
5653
|
subject: isSet3(object.subject) ? globalThis.String(object.subject) : "",
|
|
5654
|
-
content: isSet3(object.content) ?
|
|
5654
|
+
content: isSet3(object.content) ? bytesFromBase64(object.content) : new Uint8Array(0),
|
|
5655
5655
|
code: isSet3(object.code) ? globalThis.Number(object.code) : 0,
|
|
5656
5656
|
sender_id: isSet3(object.sender_id) ? globalThis.String(object.sender_id) : "",
|
|
5657
5657
|
create_time: isSet3(object.create_time) ? fromJsonTimestamp(object.create_time) : void 0,
|
|
@@ -5673,8 +5673,8 @@ var Notification = {
|
|
|
5673
5673
|
if (message.subject !== "") {
|
|
5674
5674
|
obj.subject = message.subject;
|
|
5675
5675
|
}
|
|
5676
|
-
if (message.content !==
|
|
5677
|
-
obj.content = message.content;
|
|
5676
|
+
if (message.content.length !== 0) {
|
|
5677
|
+
obj.content = base64FromBytes(message.content);
|
|
5678
5678
|
}
|
|
5679
5679
|
if (message.code !== 0) {
|
|
5680
5680
|
obj.code = Math.round(message.code);
|
|
@@ -5719,7 +5719,7 @@ var Notification = {
|
|
|
5719
5719
|
const message = createBaseNotification();
|
|
5720
5720
|
message.id = (_a = object.id) != null ? _a : "";
|
|
5721
5721
|
message.subject = (_b = object.subject) != null ? _b : "";
|
|
5722
|
-
message.content = (_c = object.content) != null ? _c :
|
|
5722
|
+
message.content = (_c = object.content) != null ? _c : new Uint8Array(0);
|
|
5723
5723
|
message.code = (_d = object.code) != null ? _d : 0;
|
|
5724
5724
|
message.sender_id = (_e = object.sender_id) != null ? _e : "";
|
|
5725
5725
|
message.create_time = (_f = object.create_time) != null ? _f : void 0;
|
|
@@ -14729,6 +14729,108 @@ var MessageRefList = {
|
|
|
14729
14729
|
return message;
|
|
14730
14730
|
}
|
|
14731
14731
|
};
|
|
14732
|
+
function createBaseListClanBadgeCountRequest() {
|
|
14733
|
+
return { clan_id: "" };
|
|
14734
|
+
}
|
|
14735
|
+
var ListClanBadgeCountRequest = {
|
|
14736
|
+
encode(message, writer = import_minimal4.default.Writer.create()) {
|
|
14737
|
+
if (message.clan_id !== "") {
|
|
14738
|
+
writer.uint32(10).string(message.clan_id);
|
|
14739
|
+
}
|
|
14740
|
+
return writer;
|
|
14741
|
+
},
|
|
14742
|
+
decode(input, length) {
|
|
14743
|
+
const reader = input instanceof import_minimal4.default.Reader ? input : import_minimal4.default.Reader.create(input);
|
|
14744
|
+
let end = length === void 0 ? reader.len : reader.pos + length;
|
|
14745
|
+
const message = createBaseListClanBadgeCountRequest();
|
|
14746
|
+
while (reader.pos < end) {
|
|
14747
|
+
const tag = reader.uint32();
|
|
14748
|
+
switch (tag >>> 3) {
|
|
14749
|
+
case 1:
|
|
14750
|
+
if (tag !== 10) {
|
|
14751
|
+
break;
|
|
14752
|
+
}
|
|
14753
|
+
message.clan_id = reader.string();
|
|
14754
|
+
continue;
|
|
14755
|
+
}
|
|
14756
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
14757
|
+
break;
|
|
14758
|
+
}
|
|
14759
|
+
reader.skipType(tag & 7);
|
|
14760
|
+
}
|
|
14761
|
+
return message;
|
|
14762
|
+
},
|
|
14763
|
+
fromJSON(object) {
|
|
14764
|
+
return { clan_id: isSet3(object.clan_id) ? globalThis.String(object.clan_id) : "" };
|
|
14765
|
+
},
|
|
14766
|
+
toJSON(message) {
|
|
14767
|
+
const obj = {};
|
|
14768
|
+
if (message.clan_id !== "") {
|
|
14769
|
+
obj.clan_id = message.clan_id;
|
|
14770
|
+
}
|
|
14771
|
+
return obj;
|
|
14772
|
+
},
|
|
14773
|
+
create(base) {
|
|
14774
|
+
return ListClanBadgeCountRequest.fromPartial(base != null ? base : {});
|
|
14775
|
+
},
|
|
14776
|
+
fromPartial(object) {
|
|
14777
|
+
var _a;
|
|
14778
|
+
const message = createBaseListClanBadgeCountRequest();
|
|
14779
|
+
message.clan_id = (_a = object.clan_id) != null ? _a : "";
|
|
14780
|
+
return message;
|
|
14781
|
+
}
|
|
14782
|
+
};
|
|
14783
|
+
function createBaseListClanBadgeCountResponse() {
|
|
14784
|
+
return { badge_count: 0 };
|
|
14785
|
+
}
|
|
14786
|
+
var ListClanBadgeCountResponse = {
|
|
14787
|
+
encode(message, writer = import_minimal4.default.Writer.create()) {
|
|
14788
|
+
if (message.badge_count !== 0) {
|
|
14789
|
+
writer.uint32(8).int32(message.badge_count);
|
|
14790
|
+
}
|
|
14791
|
+
return writer;
|
|
14792
|
+
},
|
|
14793
|
+
decode(input, length) {
|
|
14794
|
+
const reader = input instanceof import_minimal4.default.Reader ? input : import_minimal4.default.Reader.create(input);
|
|
14795
|
+
let end = length === void 0 ? reader.len : reader.pos + length;
|
|
14796
|
+
const message = createBaseListClanBadgeCountResponse();
|
|
14797
|
+
while (reader.pos < end) {
|
|
14798
|
+
const tag = reader.uint32();
|
|
14799
|
+
switch (tag >>> 3) {
|
|
14800
|
+
case 1:
|
|
14801
|
+
if (tag !== 8) {
|
|
14802
|
+
break;
|
|
14803
|
+
}
|
|
14804
|
+
message.badge_count = reader.int32();
|
|
14805
|
+
continue;
|
|
14806
|
+
}
|
|
14807
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
14808
|
+
break;
|
|
14809
|
+
}
|
|
14810
|
+
reader.skipType(tag & 7);
|
|
14811
|
+
}
|
|
14812
|
+
return message;
|
|
14813
|
+
},
|
|
14814
|
+
fromJSON(object) {
|
|
14815
|
+
return { badge_count: isSet3(object.badge_count) ? globalThis.Number(object.badge_count) : 0 };
|
|
14816
|
+
},
|
|
14817
|
+
toJSON(message) {
|
|
14818
|
+
const obj = {};
|
|
14819
|
+
if (message.badge_count !== 0) {
|
|
14820
|
+
obj.badge_count = Math.round(message.badge_count);
|
|
14821
|
+
}
|
|
14822
|
+
return obj;
|
|
14823
|
+
},
|
|
14824
|
+
create(base) {
|
|
14825
|
+
return ListClanBadgeCountResponse.fromPartial(base != null ? base : {});
|
|
14826
|
+
},
|
|
14827
|
+
fromPartial(object) {
|
|
14828
|
+
var _a;
|
|
14829
|
+
const message = createBaseListClanBadgeCountResponse();
|
|
14830
|
+
message.badge_count = (_a = object.badge_count) != null ? _a : 0;
|
|
14831
|
+
return message;
|
|
14832
|
+
}
|
|
14833
|
+
};
|
|
14732
14834
|
function bytesFromBase64(b64) {
|
|
14733
14835
|
if (globalThis.Buffer) {
|
|
14734
14836
|
return Uint8Array.from(globalThis.Buffer.from(b64, "base64"));
|
|
@@ -25446,7 +25548,9 @@ function createBaseListDataSocket() {
|
|
|
25446
25548
|
category_list: void 0,
|
|
25447
25549
|
stream_user_list: void 0,
|
|
25448
25550
|
list_unread_msg_indicator_req: void 0,
|
|
25449
|
-
unread_msg_indicator: void 0
|
|
25551
|
+
unread_msg_indicator: void 0,
|
|
25552
|
+
list_clan_badge_count_req: void 0,
|
|
25553
|
+
clan_badge_count: void 0
|
|
25450
25554
|
};
|
|
25451
25555
|
}
|
|
25452
25556
|
var ListDataSocket = {
|
|
@@ -25649,6 +25753,12 @@ var ListDataSocket = {
|
|
|
25649
25753
|
if (message.unread_msg_indicator !== void 0) {
|
|
25650
25754
|
ListClanUnreadMsgIndicatorResponse.encode(message.unread_msg_indicator, writer.uint32(530).fork()).ldelim();
|
|
25651
25755
|
}
|
|
25756
|
+
if (message.list_clan_badge_count_req !== void 0) {
|
|
25757
|
+
ListClanBadgeCountRequest.encode(message.list_clan_badge_count_req, writer.uint32(538).fork()).ldelim();
|
|
25758
|
+
}
|
|
25759
|
+
if (message.clan_badge_count !== void 0) {
|
|
25760
|
+
ListClanBadgeCountResponse.encode(message.clan_badge_count, writer.uint32(546).fork()).ldelim();
|
|
25761
|
+
}
|
|
25652
25762
|
return writer;
|
|
25653
25763
|
},
|
|
25654
25764
|
decode(input, length) {
|
|
@@ -26057,6 +26167,18 @@ var ListDataSocket = {
|
|
|
26057
26167
|
}
|
|
26058
26168
|
message.unread_msg_indicator = ListClanUnreadMsgIndicatorResponse.decode(reader, reader.uint32());
|
|
26059
26169
|
continue;
|
|
26170
|
+
case 67:
|
|
26171
|
+
if (tag !== 538) {
|
|
26172
|
+
break;
|
|
26173
|
+
}
|
|
26174
|
+
message.list_clan_badge_count_req = ListClanBadgeCountRequest.decode(reader, reader.uint32());
|
|
26175
|
+
continue;
|
|
26176
|
+
case 68:
|
|
26177
|
+
if (tag !== 546) {
|
|
26178
|
+
break;
|
|
26179
|
+
}
|
|
26180
|
+
message.clan_badge_count = ListClanBadgeCountResponse.decode(reader, reader.uint32());
|
|
26181
|
+
continue;
|
|
26060
26182
|
}
|
|
26061
26183
|
if ((tag & 7) === 4 || tag === 0) {
|
|
26062
26184
|
break;
|
|
@@ -26132,7 +26254,9 @@ var ListDataSocket = {
|
|
|
26132
26254
|
category_list: isSet4(object.category_list) ? CategoryDescList.fromJSON(object.category_list) : void 0,
|
|
26133
26255
|
stream_user_list: isSet4(object.stream_user_list) ? StreamingChannelUserList.fromJSON(object.stream_user_list) : void 0,
|
|
26134
26256
|
list_unread_msg_indicator_req: isSet4(object.list_unread_msg_indicator_req) ? ListClanUnreadMsgIndicatorRequest.fromJSON(object.list_unread_msg_indicator_req) : void 0,
|
|
26135
|
-
unread_msg_indicator: isSet4(object.unread_msg_indicator) ? ListClanUnreadMsgIndicatorResponse.fromJSON(object.unread_msg_indicator) : void 0
|
|
26257
|
+
unread_msg_indicator: isSet4(object.unread_msg_indicator) ? ListClanUnreadMsgIndicatorResponse.fromJSON(object.unread_msg_indicator) : void 0,
|
|
26258
|
+
list_clan_badge_count_req: isSet4(object.list_clan_badge_count_req) ? ListClanBadgeCountRequest.fromJSON(object.list_clan_badge_count_req) : void 0,
|
|
26259
|
+
clan_badge_count: isSet4(object.clan_badge_count) ? ListClanBadgeCountResponse.fromJSON(object.clan_badge_count) : void 0
|
|
26136
26260
|
};
|
|
26137
26261
|
},
|
|
26138
26262
|
toJSON(message) {
|
|
@@ -26339,6 +26463,12 @@ var ListDataSocket = {
|
|
|
26339
26463
|
if (message.unread_msg_indicator !== void 0) {
|
|
26340
26464
|
obj.unread_msg_indicator = ListClanUnreadMsgIndicatorResponse.toJSON(message.unread_msg_indicator);
|
|
26341
26465
|
}
|
|
26466
|
+
if (message.list_clan_badge_count_req !== void 0) {
|
|
26467
|
+
obj.list_clan_badge_count_req = ListClanBadgeCountRequest.toJSON(message.list_clan_badge_count_req);
|
|
26468
|
+
}
|
|
26469
|
+
if (message.clan_badge_count !== void 0) {
|
|
26470
|
+
obj.clan_badge_count = ListClanBadgeCountResponse.toJSON(message.clan_badge_count);
|
|
26471
|
+
}
|
|
26342
26472
|
return obj;
|
|
26343
26473
|
},
|
|
26344
26474
|
create(base) {
|
|
@@ -26413,6 +26543,8 @@ var ListDataSocket = {
|
|
|
26413
26543
|
message.stream_user_list = object.stream_user_list !== void 0 && object.stream_user_list !== null ? StreamingChannelUserList.fromPartial(object.stream_user_list) : void 0;
|
|
26414
26544
|
message.list_unread_msg_indicator_req = object.list_unread_msg_indicator_req !== void 0 && object.list_unread_msg_indicator_req !== null ? ListClanUnreadMsgIndicatorRequest.fromPartial(object.list_unread_msg_indicator_req) : void 0;
|
|
26415
26545
|
message.unread_msg_indicator = object.unread_msg_indicator !== void 0 && object.unread_msg_indicator !== null ? ListClanUnreadMsgIndicatorResponse.fromPartial(object.unread_msg_indicator) : void 0;
|
|
26546
|
+
message.list_clan_badge_count_req = object.list_clan_badge_count_req !== void 0 && object.list_clan_badge_count_req !== null ? ListClanBadgeCountRequest.fromPartial(object.list_clan_badge_count_req) : void 0;
|
|
26547
|
+
message.clan_badge_count = object.clan_badge_count !== void 0 && object.clan_badge_count !== null ? ListClanBadgeCountResponse.fromPartial(object.clan_badge_count) : void 0;
|
|
26416
26548
|
return message;
|
|
26417
26549
|
}
|
|
26418
26550
|
};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "mezon-js-protobuf",
|
|
3
|
-
"version": "1.8.
|
|
3
|
+
"version": "1.8.77",
|
|
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",
|
package/rtapi/realtime.ts
CHANGED
|
@@ -38,6 +38,8 @@ import {
|
|
|
38
38
|
ListChannelDetailRequest,
|
|
39
39
|
ListChannelMessagesRequest,
|
|
40
40
|
ListChannelUsersRequest,
|
|
41
|
+
ListClanBadgeCountRequest,
|
|
42
|
+
ListClanBadgeCountResponse,
|
|
41
43
|
ListClanDescRequest,
|
|
42
44
|
ListClanUnreadMsgIndicatorRequest,
|
|
43
45
|
ListClanUnreadMsgIndicatorResponse,
|
|
@@ -1743,6 +1745,8 @@ export interface ListDataSocket {
|
|
|
1743
1745
|
stream_user_list: StreamingChannelUserList | undefined;
|
|
1744
1746
|
list_unread_msg_indicator_req: ListClanUnreadMsgIndicatorRequest | undefined;
|
|
1745
1747
|
unread_msg_indicator: ListClanUnreadMsgIndicatorResponse | undefined;
|
|
1748
|
+
list_clan_badge_count_req: ListClanBadgeCountRequest | undefined;
|
|
1749
|
+
clan_badge_count: ListClanBadgeCountResponse | undefined;
|
|
1746
1750
|
}
|
|
1747
1751
|
|
|
1748
1752
|
export interface MeetParticipantEvent {
|
|
@@ -1773,7 +1777,7 @@ export interface FcmDataPayload {
|
|
|
1773
1777
|
command_type: number;
|
|
1774
1778
|
receiver_id: string;
|
|
1775
1779
|
title: string;
|
|
1776
|
-
body:
|
|
1780
|
+
body: Uint8Array;
|
|
1777
1781
|
user_role_ids: string[];
|
|
1778
1782
|
user_sent_ids: string[];
|
|
1779
1783
|
priority: number;
|
|
@@ -14673,6 +14677,8 @@ function createBaseListDataSocket(): ListDataSocket {
|
|
|
14673
14677
|
stream_user_list: undefined,
|
|
14674
14678
|
list_unread_msg_indicator_req: undefined,
|
|
14675
14679
|
unread_msg_indicator: undefined,
|
|
14680
|
+
list_clan_badge_count_req: undefined,
|
|
14681
|
+
clan_badge_count: undefined,
|
|
14676
14682
|
};
|
|
14677
14683
|
}
|
|
14678
14684
|
|
|
@@ -14878,6 +14884,12 @@ export const ListDataSocket = {
|
|
|
14878
14884
|
if (message.unread_msg_indicator !== undefined) {
|
|
14879
14885
|
ListClanUnreadMsgIndicatorResponse.encode(message.unread_msg_indicator, writer.uint32(530).fork()).ldelim();
|
|
14880
14886
|
}
|
|
14887
|
+
if (message.list_clan_badge_count_req !== undefined) {
|
|
14888
|
+
ListClanBadgeCountRequest.encode(message.list_clan_badge_count_req, writer.uint32(538).fork()).ldelim();
|
|
14889
|
+
}
|
|
14890
|
+
if (message.clan_badge_count !== undefined) {
|
|
14891
|
+
ListClanBadgeCountResponse.encode(message.clan_badge_count, writer.uint32(546).fork()).ldelim();
|
|
14892
|
+
}
|
|
14881
14893
|
return writer;
|
|
14882
14894
|
},
|
|
14883
14895
|
|
|
@@ -15353,6 +15365,20 @@ export const ListDataSocket = {
|
|
|
15353
15365
|
|
|
15354
15366
|
message.unread_msg_indicator = ListClanUnreadMsgIndicatorResponse.decode(reader, reader.uint32());
|
|
15355
15367
|
continue;
|
|
15368
|
+
case 67:
|
|
15369
|
+
if (tag !== 538) {
|
|
15370
|
+
break;
|
|
15371
|
+
}
|
|
15372
|
+
|
|
15373
|
+
message.list_clan_badge_count_req = ListClanBadgeCountRequest.decode(reader, reader.uint32());
|
|
15374
|
+
continue;
|
|
15375
|
+
case 68:
|
|
15376
|
+
if (tag !== 546) {
|
|
15377
|
+
break;
|
|
15378
|
+
}
|
|
15379
|
+
|
|
15380
|
+
message.clan_badge_count = ListClanBadgeCountResponse.decode(reader, reader.uint32());
|
|
15381
|
+
continue;
|
|
15356
15382
|
}
|
|
15357
15383
|
if ((tag & 7) === 4 || tag === 0) {
|
|
15358
15384
|
break;
|
|
@@ -15518,6 +15544,12 @@ export const ListDataSocket = {
|
|
|
15518
15544
|
unread_msg_indicator: isSet(object.unread_msg_indicator)
|
|
15519
15545
|
? ListClanUnreadMsgIndicatorResponse.fromJSON(object.unread_msg_indicator)
|
|
15520
15546
|
: undefined,
|
|
15547
|
+
list_clan_badge_count_req: isSet(object.list_clan_badge_count_req)
|
|
15548
|
+
? ListClanBadgeCountRequest.fromJSON(object.list_clan_badge_count_req)
|
|
15549
|
+
: undefined,
|
|
15550
|
+
clan_badge_count: isSet(object.clan_badge_count)
|
|
15551
|
+
? ListClanBadgeCountResponse.fromJSON(object.clan_badge_count)
|
|
15552
|
+
: undefined,
|
|
15521
15553
|
};
|
|
15522
15554
|
},
|
|
15523
15555
|
|
|
@@ -15725,6 +15757,12 @@ export const ListDataSocket = {
|
|
|
15725
15757
|
if (message.unread_msg_indicator !== undefined) {
|
|
15726
15758
|
obj.unread_msg_indicator = ListClanUnreadMsgIndicatorResponse.toJSON(message.unread_msg_indicator);
|
|
15727
15759
|
}
|
|
15760
|
+
if (message.list_clan_badge_count_req !== undefined) {
|
|
15761
|
+
obj.list_clan_badge_count_req = ListClanBadgeCountRequest.toJSON(message.list_clan_badge_count_req);
|
|
15762
|
+
}
|
|
15763
|
+
if (message.clan_badge_count !== undefined) {
|
|
15764
|
+
obj.clan_badge_count = ListClanBadgeCountResponse.toJSON(message.clan_badge_count);
|
|
15765
|
+
}
|
|
15728
15766
|
return obj;
|
|
15729
15767
|
},
|
|
15730
15768
|
|
|
@@ -15942,6 +15980,13 @@ export const ListDataSocket = {
|
|
|
15942
15980
|
message.unread_msg_indicator = (object.unread_msg_indicator !== undefined && object.unread_msg_indicator !== null)
|
|
15943
15981
|
? ListClanUnreadMsgIndicatorResponse.fromPartial(object.unread_msg_indicator)
|
|
15944
15982
|
: undefined;
|
|
15983
|
+
message.list_clan_badge_count_req =
|
|
15984
|
+
(object.list_clan_badge_count_req !== undefined && object.list_clan_badge_count_req !== null)
|
|
15985
|
+
? ListClanBadgeCountRequest.fromPartial(object.list_clan_badge_count_req)
|
|
15986
|
+
: undefined;
|
|
15987
|
+
message.clan_badge_count = (object.clan_badge_count !== undefined && object.clan_badge_count !== null)
|
|
15988
|
+
? ListClanBadgeCountResponse.fromPartial(object.clan_badge_count)
|
|
15989
|
+
: undefined;
|
|
15945
15990
|
return message;
|
|
15946
15991
|
},
|
|
15947
15992
|
};
|
|
@@ -16307,7 +16352,7 @@ function createBaseFcmDataPayload(): FcmDataPayload {
|
|
|
16307
16352
|
command_type: 0,
|
|
16308
16353
|
receiver_id: "",
|
|
16309
16354
|
title: "",
|
|
16310
|
-
body:
|
|
16355
|
+
body: new Uint8Array(0),
|
|
16311
16356
|
user_role_ids: [],
|
|
16312
16357
|
user_sent_ids: [],
|
|
16313
16358
|
priority: 0,
|
|
@@ -16332,8 +16377,8 @@ export const FcmDataPayload = {
|
|
|
16332
16377
|
if (message.title !== "") {
|
|
16333
16378
|
writer.uint32(26).string(message.title);
|
|
16334
16379
|
}
|
|
16335
|
-
if (message.body !==
|
|
16336
|
-
writer.uint32(34).
|
|
16380
|
+
if (message.body.length !== 0) {
|
|
16381
|
+
writer.uint32(34).bytes(message.body);
|
|
16337
16382
|
}
|
|
16338
16383
|
for (const v of message.user_role_ids) {
|
|
16339
16384
|
writer.uint32(42).string(v!);
|
|
@@ -16401,7 +16446,7 @@ export const FcmDataPayload = {
|
|
|
16401
16446
|
break;
|
|
16402
16447
|
}
|
|
16403
16448
|
|
|
16404
|
-
message.body = reader.
|
|
16449
|
+
message.body = reader.bytes();
|
|
16405
16450
|
continue;
|
|
16406
16451
|
case 5:
|
|
16407
16452
|
if (tag !== 42) {
|
|
@@ -16487,7 +16532,7 @@ export const FcmDataPayload = {
|
|
|
16487
16532
|
command_type: isSet(object.command_type) ? globalThis.Number(object.command_type) : 0,
|
|
16488
16533
|
receiver_id: isSet(object.receiver_id) ? globalThis.String(object.receiver_id) : "",
|
|
16489
16534
|
title: isSet(object.title) ? globalThis.String(object.title) : "",
|
|
16490
|
-
body: isSet(object.body) ?
|
|
16535
|
+
body: isSet(object.body) ? bytesFromBase64(object.body) : new Uint8Array(0),
|
|
16491
16536
|
user_role_ids: globalThis.Array.isArray(object?.user_role_ids)
|
|
16492
16537
|
? object.user_role_ids.map((e: any) => globalThis.String(e))
|
|
16493
16538
|
: [],
|
|
@@ -16522,8 +16567,8 @@ export const FcmDataPayload = {
|
|
|
16522
16567
|
if (message.title !== "") {
|
|
16523
16568
|
obj.title = message.title;
|
|
16524
16569
|
}
|
|
16525
|
-
if (message.body !==
|
|
16526
|
-
obj.body = message.body;
|
|
16570
|
+
if (message.body.length !== 0) {
|
|
16571
|
+
obj.body = base64FromBytes(message.body);
|
|
16527
16572
|
}
|
|
16528
16573
|
if (message.user_role_ids?.length) {
|
|
16529
16574
|
obj.user_role_ids = message.user_role_ids;
|
|
@@ -16566,7 +16611,7 @@ export const FcmDataPayload = {
|
|
|
16566
16611
|
message.command_type = object.command_type ?? 0;
|
|
16567
16612
|
message.receiver_id = object.receiver_id ?? "";
|
|
16568
16613
|
message.title = object.title ?? "";
|
|
16569
|
-
message.body = object.body ??
|
|
16614
|
+
message.body = object.body ?? new Uint8Array(0);
|
|
16570
16615
|
message.user_role_ids = object.user_role_ids?.map((e) => e) || [];
|
|
16571
16616
|
message.user_sent_ids = object.user_sent_ids?.map((e) => e) || [];
|
|
16572
16617
|
message.priority = object.priority ?? 0;
|