@vocdoni/proto 1.15.3 → 1.15.4
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/build/js/client-store/index.js +51 -71
- package/build/js/client-store/index.mjs +51 -71
- package/build/js/{index-fe26a63a.d.ts → index-5d7943a4.d.ts} +664 -1788
- package/build/js/index.d.ts +1 -1
- package/build/js/index.js +406 -588
- package/build/js/index.mjs +406 -588
- package/build/js/metadata/index.js +133 -80
- package/build/js/metadata/index.mjs +133 -80
- package/build/js/vochain/index.d.ts +1 -1
- package/build/js/vochain/index.js +234 -445
- package/build/js/vochain/index.mjs +234 -441
- package/package.json +5 -3
package/build/js/index.js
CHANGED
|
@@ -1201,7 +1201,11 @@ var require_reader = __commonJS({
|
|
|
1201
1201
|
this.pos += length;
|
|
1202
1202
|
if (Array.isArray(this.buf))
|
|
1203
1203
|
return this.buf.slice(start, end);
|
|
1204
|
-
|
|
1204
|
+
if (start === end) {
|
|
1205
|
+
var nativeBuffer = util.Buffer;
|
|
1206
|
+
return nativeBuffer ? nativeBuffer.alloc(0) : new this.buf.constructor(0);
|
|
1207
|
+
}
|
|
1208
|
+
return this._slice.call(this.buf, start, end);
|
|
1205
1209
|
};
|
|
1206
1210
|
Reader.prototype.string = function read_string() {
|
|
1207
1211
|
var bytes = this.bytes();
|
|
@@ -1483,7 +1487,9 @@ var EntityMetadataStore = {
|
|
|
1483
1487
|
return message;
|
|
1484
1488
|
},
|
|
1485
1489
|
fromJSON(object) {
|
|
1486
|
-
return {
|
|
1490
|
+
return {
|
|
1491
|
+
items: globalThis.Array.isArray(object?.items) ? object.items.map((e) => EntityMetadata.fromJSON(e)) : []
|
|
1492
|
+
};
|
|
1487
1493
|
},
|
|
1488
1494
|
toJSON(message) {
|
|
1489
1495
|
const obj = {};
|
|
@@ -1668,8 +1674,8 @@ var EntityMetadata = {
|
|
|
1668
1674
|
},
|
|
1669
1675
|
fromJSON(object) {
|
|
1670
1676
|
return {
|
|
1671
|
-
version: isSet(object.version) ? String(object.version) : "",
|
|
1672
|
-
languages: Array.isArray(object?.languages) ? object.languages.map((e) => String(e)) : [],
|
|
1677
|
+
version: isSet(object.version) ? globalThis.String(object.version) : "",
|
|
1678
|
+
languages: globalThis.Array.isArray(object?.languages) ? object.languages.map((e) => globalThis.String(e)) : [],
|
|
1673
1679
|
name: isObject(object.name) ? Object.entries(object.name).reduce((acc, [key, value]) => {
|
|
1674
1680
|
acc[key] = String(value);
|
|
1675
1681
|
return acc;
|
|
@@ -1684,11 +1690,11 @@ var EntityMetadata = {
|
|
|
1684
1690
|
return acc;
|
|
1685
1691
|
}, {}) : {},
|
|
1686
1692
|
media: isSet(object.media) ? EntityMetadata_Media.fromJSON(object.media) : void 0,
|
|
1687
|
-
actions: Array.isArray(object?.actions) ? object.actions.map((e) => EntityMetadata_Action.fromJSON(e)) : [],
|
|
1688
|
-
bootEntities: Array.isArray(object?.bootEntities) ? object.bootEntities.map((e) => EntityReference.fromJSON(e)) : [],
|
|
1689
|
-
fallbackBootNodeEntities: Array.isArray(object?.fallbackBootNodeEntities) ? object.fallbackBootNodeEntities.map((e) => EntityReference.fromJSON(e)) : [],
|
|
1690
|
-
trustedEntities: Array.isArray(object?.trustedEntities) ? object.trustedEntities.map((e) => EntityReference.fromJSON(e)) : [],
|
|
1691
|
-
censusServiceManagedEntities: Array.isArray(object?.censusServiceManagedEntities) ? object.censusServiceManagedEntities.map((e) => EntityReference.fromJSON(e)) : [],
|
|
1693
|
+
actions: globalThis.Array.isArray(object?.actions) ? object.actions.map((e) => EntityMetadata_Action.fromJSON(e)) : [],
|
|
1694
|
+
bootEntities: globalThis.Array.isArray(object?.bootEntities) ? object.bootEntities.map((e) => EntityReference.fromJSON(e)) : [],
|
|
1695
|
+
fallbackBootNodeEntities: globalThis.Array.isArray(object?.fallbackBootNodeEntities) ? object.fallbackBootNodeEntities.map((e) => EntityReference.fromJSON(e)) : [],
|
|
1696
|
+
trustedEntities: globalThis.Array.isArray(object?.trustedEntities) ? object.trustedEntities.map((e) => EntityReference.fromJSON(e)) : [],
|
|
1697
|
+
censusServiceManagedEntities: globalThis.Array.isArray(object?.censusServiceManagedEntities) ? object.censusServiceManagedEntities.map((e) => EntityReference.fromJSON(e)) : [],
|
|
1692
1698
|
meta: isObject(object.meta) ? Object.entries(object.meta).reduce((acc, [key, value]) => {
|
|
1693
1699
|
acc[key] = String(value);
|
|
1694
1700
|
return acc;
|
|
@@ -1771,14 +1777,14 @@ var EntityMetadata = {
|
|
|
1771
1777
|
message.languages = object.languages?.map((e) => e) || [];
|
|
1772
1778
|
message.name = Object.entries(object.name ?? {}).reduce((acc, [key, value]) => {
|
|
1773
1779
|
if (value !== void 0) {
|
|
1774
|
-
acc[key] = String(value);
|
|
1780
|
+
acc[key] = globalThis.String(value);
|
|
1775
1781
|
}
|
|
1776
1782
|
return acc;
|
|
1777
1783
|
}, {});
|
|
1778
1784
|
message.description = Object.entries(object.description ?? {}).reduce(
|
|
1779
1785
|
(acc, [key, value]) => {
|
|
1780
1786
|
if (value !== void 0) {
|
|
1781
|
-
acc[key] = String(value);
|
|
1787
|
+
acc[key] = globalThis.String(value);
|
|
1782
1788
|
}
|
|
1783
1789
|
return acc;
|
|
1784
1790
|
},
|
|
@@ -1787,7 +1793,7 @@ var EntityMetadata = {
|
|
|
1787
1793
|
message.votingProcesses = object.votingProcesses !== void 0 && object.votingProcesses !== null ? EntityMetadata_VotingProcesses.fromPartial(object.votingProcesses) : void 0;
|
|
1788
1794
|
message.newsFeed = Object.entries(object.newsFeed ?? {}).reduce((acc, [key, value]) => {
|
|
1789
1795
|
if (value !== void 0) {
|
|
1790
|
-
acc[key] = String(value);
|
|
1796
|
+
acc[key] = globalThis.String(value);
|
|
1791
1797
|
}
|
|
1792
1798
|
return acc;
|
|
1793
1799
|
}, {});
|
|
@@ -1799,7 +1805,7 @@ var EntityMetadata = {
|
|
|
1799
1805
|
message.censusServiceManagedEntities = object.censusServiceManagedEntities?.map((e) => EntityReference.fromPartial(e)) || [];
|
|
1800
1806
|
message.meta = Object.entries(object.meta ?? {}).reduce((acc, [key, value]) => {
|
|
1801
1807
|
if (value !== void 0) {
|
|
1802
|
-
acc[key] = String(value);
|
|
1808
|
+
acc[key] = globalThis.String(value);
|
|
1803
1809
|
}
|
|
1804
1810
|
return acc;
|
|
1805
1811
|
}, {});
|
|
@@ -1847,7 +1853,10 @@ var EntityMetadata_NameEntry = {
|
|
|
1847
1853
|
return message;
|
|
1848
1854
|
},
|
|
1849
1855
|
fromJSON(object) {
|
|
1850
|
-
return {
|
|
1856
|
+
return {
|
|
1857
|
+
key: isSet(object.key) ? globalThis.String(object.key) : "",
|
|
1858
|
+
value: isSet(object.value) ? globalThis.String(object.value) : ""
|
|
1859
|
+
};
|
|
1851
1860
|
},
|
|
1852
1861
|
toJSON(message) {
|
|
1853
1862
|
const obj = {};
|
|
@@ -1910,7 +1919,10 @@ var EntityMetadata_DescriptionEntry = {
|
|
|
1910
1919
|
return message;
|
|
1911
1920
|
},
|
|
1912
1921
|
fromJSON(object) {
|
|
1913
|
-
return {
|
|
1922
|
+
return {
|
|
1923
|
+
key: isSet(object.key) ? globalThis.String(object.key) : "",
|
|
1924
|
+
value: isSet(object.value) ? globalThis.String(object.value) : ""
|
|
1925
|
+
};
|
|
1914
1926
|
},
|
|
1915
1927
|
toJSON(message) {
|
|
1916
1928
|
const obj = {};
|
|
@@ -1974,8 +1986,8 @@ var EntityMetadata_VotingProcesses = {
|
|
|
1974
1986
|
},
|
|
1975
1987
|
fromJSON(object) {
|
|
1976
1988
|
return {
|
|
1977
|
-
active: Array.isArray(object?.active) ? object.active.map((e) => String(e)) : [],
|
|
1978
|
-
ended: Array.isArray(object?.ended) ? object.ended.map((e) => String(e)) : []
|
|
1989
|
+
active: globalThis.Array.isArray(object?.active) ? object.active.map((e) => globalThis.String(e)) : [],
|
|
1990
|
+
ended: globalThis.Array.isArray(object?.ended) ? object.ended.map((e) => globalThis.String(e)) : []
|
|
1979
1991
|
};
|
|
1980
1992
|
},
|
|
1981
1993
|
toJSON(message) {
|
|
@@ -2039,7 +2051,10 @@ var EntityMetadata_NewsFeedEntry = {
|
|
|
2039
2051
|
return message;
|
|
2040
2052
|
},
|
|
2041
2053
|
fromJSON(object) {
|
|
2042
|
-
return {
|
|
2054
|
+
return {
|
|
2055
|
+
key: isSet(object.key) ? globalThis.String(object.key) : "",
|
|
2056
|
+
value: isSet(object.value) ? globalThis.String(object.value) : ""
|
|
2057
|
+
};
|
|
2043
2058
|
},
|
|
2044
2059
|
toJSON(message) {
|
|
2045
2060
|
const obj = {};
|
|
@@ -2103,8 +2118,8 @@ var EntityMetadata_Media = {
|
|
|
2103
2118
|
},
|
|
2104
2119
|
fromJSON(object) {
|
|
2105
2120
|
return {
|
|
2106
|
-
avatar: isSet(object.avatar) ? String(object.avatar) : "",
|
|
2107
|
-
header: isSet(object.header) ? String(object.header) : ""
|
|
2121
|
+
avatar: isSet(object.avatar) ? globalThis.String(object.avatar) : "",
|
|
2122
|
+
header: isSet(object.header) ? globalThis.String(object.header) : ""
|
|
2108
2123
|
};
|
|
2109
2124
|
},
|
|
2110
2125
|
toJSON(message) {
|
|
@@ -2208,15 +2223,15 @@ var EntityMetadata_Action = {
|
|
|
2208
2223
|
},
|
|
2209
2224
|
fromJSON(object) {
|
|
2210
2225
|
return {
|
|
2211
|
-
type: isSet(object.type) ? String(object.type) : "",
|
|
2212
|
-
actionKey: isSet(object.actionKey) ? String(object.actionKey) : "",
|
|
2226
|
+
type: isSet(object.type) ? globalThis.String(object.type) : "",
|
|
2227
|
+
actionKey: isSet(object.actionKey) ? globalThis.String(object.actionKey) : "",
|
|
2213
2228
|
name: isObject(object.name) ? Object.entries(object.name).reduce((acc, [key, value]) => {
|
|
2214
2229
|
acc[key] = String(value);
|
|
2215
2230
|
return acc;
|
|
2216
2231
|
}, {}) : {},
|
|
2217
|
-
visible: isSet(object.visible) ? String(object.visible) : "",
|
|
2218
|
-
url: isSet(object.url) ? String(object.url) : "",
|
|
2219
|
-
imageSources: Array.isArray(object?.imageSources) ? object.imageSources.map((e) => EntityMetadata_Action_ImageSource.fromJSON(e)) : []
|
|
2232
|
+
visible: isSet(object.visible) ? globalThis.String(object.visible) : "",
|
|
2233
|
+
url: isSet(object.url) ? globalThis.String(object.url) : "",
|
|
2234
|
+
imageSources: globalThis.Array.isArray(object?.imageSources) ? object.imageSources.map((e) => EntityMetadata_Action_ImageSource.fromJSON(e)) : []
|
|
2220
2235
|
};
|
|
2221
2236
|
},
|
|
2222
2237
|
toJSON(message) {
|
|
@@ -2256,7 +2271,7 @@ var EntityMetadata_Action = {
|
|
|
2256
2271
|
message.actionKey = object.actionKey ?? "";
|
|
2257
2272
|
message.name = Object.entries(object.name ?? {}).reduce((acc, [key, value]) => {
|
|
2258
2273
|
if (value !== void 0) {
|
|
2259
|
-
acc[key] = String(value);
|
|
2274
|
+
acc[key] = globalThis.String(value);
|
|
2260
2275
|
}
|
|
2261
2276
|
return acc;
|
|
2262
2277
|
}, {});
|
|
@@ -2307,7 +2322,10 @@ var EntityMetadata_Action_NameEntry = {
|
|
|
2307
2322
|
return message;
|
|
2308
2323
|
},
|
|
2309
2324
|
fromJSON(object) {
|
|
2310
|
-
return {
|
|
2325
|
+
return {
|
|
2326
|
+
key: isSet(object.key) ? globalThis.String(object.key) : "",
|
|
2327
|
+
value: isSet(object.value) ? globalThis.String(object.value) : ""
|
|
2328
|
+
};
|
|
2311
2329
|
},
|
|
2312
2330
|
toJSON(message) {
|
|
2313
2331
|
const obj = {};
|
|
@@ -2401,10 +2419,10 @@ var EntityMetadata_Action_ImageSource = {
|
|
|
2401
2419
|
},
|
|
2402
2420
|
fromJSON(object) {
|
|
2403
2421
|
return {
|
|
2404
|
-
type: isSet(object.type) ? String(object.type) : "",
|
|
2405
|
-
name: isSet(object.name) ? String(object.name) : "",
|
|
2406
|
-
orientation: isSet(object.orientation) ? String(object.orientation) : "",
|
|
2407
|
-
overlay: isSet(object.overlay) ? String(object.overlay) : "",
|
|
2422
|
+
type: isSet(object.type) ? globalThis.String(object.type) : "",
|
|
2423
|
+
name: isSet(object.name) ? globalThis.String(object.name) : "",
|
|
2424
|
+
orientation: isSet(object.orientation) ? globalThis.String(object.orientation) : "",
|
|
2425
|
+
overlay: isSet(object.overlay) ? globalThis.String(object.overlay) : "",
|
|
2408
2426
|
caption: isObject(object.caption) ? Object.entries(object.caption).reduce((acc, [key, value]) => {
|
|
2409
2427
|
acc[key] = String(value);
|
|
2410
2428
|
return acc;
|
|
@@ -2447,7 +2465,7 @@ var EntityMetadata_Action_ImageSource = {
|
|
|
2447
2465
|
message.overlay = object.overlay ?? "";
|
|
2448
2466
|
message.caption = Object.entries(object.caption ?? {}).reduce((acc, [key, value]) => {
|
|
2449
2467
|
if (value !== void 0) {
|
|
2450
|
-
acc[key] = String(value);
|
|
2468
|
+
acc[key] = globalThis.String(value);
|
|
2451
2469
|
}
|
|
2452
2470
|
return acc;
|
|
2453
2471
|
}, {});
|
|
@@ -2495,7 +2513,10 @@ var EntityMetadata_Action_ImageSource_CaptionEntry = {
|
|
|
2495
2513
|
return message;
|
|
2496
2514
|
},
|
|
2497
2515
|
fromJSON(object) {
|
|
2498
|
-
return {
|
|
2516
|
+
return {
|
|
2517
|
+
key: isSet(object.key) ? globalThis.String(object.key) : "",
|
|
2518
|
+
value: isSet(object.value) ? globalThis.String(object.value) : ""
|
|
2519
|
+
};
|
|
2499
2520
|
},
|
|
2500
2521
|
toJSON(message) {
|
|
2501
2522
|
const obj = {};
|
|
@@ -2558,7 +2579,10 @@ var EntityMetadata_MetaEntry = {
|
|
|
2558
2579
|
return message;
|
|
2559
2580
|
},
|
|
2560
2581
|
fromJSON(object) {
|
|
2561
|
-
return {
|
|
2582
|
+
return {
|
|
2583
|
+
key: isSet(object.key) ? globalThis.String(object.key) : "",
|
|
2584
|
+
value: isSet(object.value) ? globalThis.String(object.value) : ""
|
|
2585
|
+
};
|
|
2562
2586
|
},
|
|
2563
2587
|
toJSON(message) {
|
|
2564
2588
|
const obj = {};
|
|
@@ -2622,8 +2646,8 @@ var EntityReference = {
|
|
|
2622
2646
|
},
|
|
2623
2647
|
fromJSON(object) {
|
|
2624
2648
|
return {
|
|
2625
|
-
entityId: isSet(object.entityId) ? String(object.entityId) : "",
|
|
2626
|
-
entryPoints: Array.isArray(object?.entryPoints) ? object.entryPoints.map((e) => String(e)) : []
|
|
2649
|
+
entityId: isSet(object.entityId) ? globalThis.String(object.entityId) : "",
|
|
2650
|
+
entryPoints: globalThis.Array.isArray(object?.entryPoints) ? object.entryPoints.map((e) => globalThis.String(e)) : []
|
|
2627
2651
|
};
|
|
2628
2652
|
},
|
|
2629
2653
|
toJSON(message) {
|
|
@@ -2754,8 +2778,8 @@ var Wallet = {
|
|
|
2754
2778
|
fromJSON(object) {
|
|
2755
2779
|
return {
|
|
2756
2780
|
encryptedMnemonic: isSet2(object.encryptedMnemonic) ? bytesFromBase64(object.encryptedMnemonic) : new Uint8Array(0),
|
|
2757
|
-
hdPath: isSet2(object.hdPath) ? String(object.hdPath) : "",
|
|
2758
|
-
locale: isSet2(object.locale) ? String(object.locale) : "",
|
|
2781
|
+
hdPath: isSet2(object.hdPath) ? globalThis.String(object.hdPath) : "",
|
|
2782
|
+
locale: isSet2(object.locale) ? globalThis.String(object.locale) : "",
|
|
2759
2783
|
authMethod: isSet2(object.authMethod) ? wallet_AuthMethodFromJSON(object.authMethod) : 0
|
|
2760
2784
|
};
|
|
2761
2785
|
},
|
|
@@ -2787,26 +2811,11 @@ var Wallet = {
|
|
|
2787
2811
|
return message;
|
|
2788
2812
|
}
|
|
2789
2813
|
};
|
|
2790
|
-
var tsProtoGlobalThis = (() => {
|
|
2791
|
-
if (typeof globalThis !== "undefined") {
|
|
2792
|
-
return globalThis;
|
|
2793
|
-
}
|
|
2794
|
-
if (typeof self !== "undefined") {
|
|
2795
|
-
return self;
|
|
2796
|
-
}
|
|
2797
|
-
if (typeof window !== "undefined") {
|
|
2798
|
-
return window;
|
|
2799
|
-
}
|
|
2800
|
-
if (typeof global !== "undefined") {
|
|
2801
|
-
return global;
|
|
2802
|
-
}
|
|
2803
|
-
throw "Unable to locate global object";
|
|
2804
|
-
})();
|
|
2805
2814
|
function bytesFromBase64(b64) {
|
|
2806
|
-
if (
|
|
2807
|
-
return Uint8Array.from(
|
|
2815
|
+
if (globalThis.Buffer) {
|
|
2816
|
+
return Uint8Array.from(globalThis.Buffer.from(b64, "base64"));
|
|
2808
2817
|
} else {
|
|
2809
|
-
const bin =
|
|
2818
|
+
const bin = globalThis.atob(b64);
|
|
2810
2819
|
const arr = new Uint8Array(bin.length);
|
|
2811
2820
|
for (let i = 0; i < bin.length; ++i) {
|
|
2812
2821
|
arr[i] = bin.charCodeAt(i);
|
|
@@ -2815,14 +2824,14 @@ function bytesFromBase64(b64) {
|
|
|
2815
2824
|
}
|
|
2816
2825
|
}
|
|
2817
2826
|
function base64FromBytes(arr) {
|
|
2818
|
-
if (
|
|
2819
|
-
return
|
|
2827
|
+
if (globalThis.Buffer) {
|
|
2828
|
+
return globalThis.Buffer.from(arr).toString("base64");
|
|
2820
2829
|
} else {
|
|
2821
2830
|
const bin = [];
|
|
2822
2831
|
arr.forEach((byte) => {
|
|
2823
|
-
bin.push(String.fromCharCode(byte));
|
|
2832
|
+
bin.push(globalThis.String.fromCharCode(byte));
|
|
2824
2833
|
});
|
|
2825
|
-
return
|
|
2834
|
+
return globalThis.btoa(bin.join(""));
|
|
2826
2835
|
}
|
|
2827
2836
|
}
|
|
2828
2837
|
function isSet2(value) {
|
|
@@ -2862,7 +2871,7 @@ var AccountsStore = {
|
|
|
2862
2871
|
return message;
|
|
2863
2872
|
},
|
|
2864
2873
|
fromJSON(object) {
|
|
2865
|
-
return { items: Array.isArray(object?.items) ? object.items.map((e) => Account.fromJSON(e)) : [] };
|
|
2874
|
+
return { items: globalThis.Array.isArray(object?.items) ? object.items.map((e) => Account.fromJSON(e)) : [] };
|
|
2866
2875
|
},
|
|
2867
2876
|
toJSON(message) {
|
|
2868
2877
|
const obj = {};
|
|
@@ -2961,10 +2970,10 @@ var Account = {
|
|
|
2961
2970
|
},
|
|
2962
2971
|
fromJSON(object) {
|
|
2963
2972
|
return {
|
|
2964
|
-
name: isSet3(object.name) ? String(object.name) : "",
|
|
2973
|
+
name: isSet3(object.name) ? globalThis.String(object.name) : "",
|
|
2965
2974
|
wallet: isSet3(object.wallet) ? Wallet.fromJSON(object.wallet) : void 0,
|
|
2966
|
-
address: isSet3(object.address) ? String(object.address) : "",
|
|
2967
|
-
hasBackup: isSet3(object.hasBackup) ? Boolean(object.hasBackup) : false,
|
|
2975
|
+
address: isSet3(object.address) ? globalThis.String(object.address) : "",
|
|
2976
|
+
hasBackup: isSet3(object.hasBackup) ? globalThis.Boolean(object.hasBackup) : false,
|
|
2968
2977
|
extra: isSet3(object.extra) ? Account_Extra.fromJSON(object.extra) : void 0,
|
|
2969
2978
|
meta: isObject2(object.meta) ? Object.entries(object.meta).reduce((acc, [key, value]) => {
|
|
2970
2979
|
acc[key] = String(value);
|
|
@@ -3012,7 +3021,7 @@ var Account = {
|
|
|
3012
3021
|
message.extra = object.extra !== void 0 && object.extra !== null ? Account_Extra.fromPartial(object.extra) : void 0;
|
|
3013
3022
|
message.meta = Object.entries(object.meta ?? {}).reduce((acc, [key, value]) => {
|
|
3014
3023
|
if (value !== void 0) {
|
|
3015
|
-
acc[key] = String(value);
|
|
3024
|
+
acc[key] = globalThis.String(value);
|
|
3016
3025
|
}
|
|
3017
3026
|
return acc;
|
|
3018
3027
|
}, {});
|
|
@@ -3061,8 +3070,8 @@ var Account_AppVoter = {
|
|
|
3061
3070
|
},
|
|
3062
3071
|
fromJSON(object) {
|
|
3063
3072
|
return {
|
|
3064
|
-
appAnalyticsID: isSet3(object.appAnalyticsID) ? String(object.appAnalyticsID) : "",
|
|
3065
|
-
entities: Array.isArray(object?.entities) ? object.entities.map((e) => EntityReference.fromJSON(e)) : []
|
|
3073
|
+
appAnalyticsID: isSet3(object.appAnalyticsID) ? globalThis.String(object.appAnalyticsID) : "",
|
|
3074
|
+
entities: globalThis.Array.isArray(object?.entities) ? object.entities.map((e) => EntityReference.fromJSON(e)) : []
|
|
3066
3075
|
};
|
|
3067
3076
|
},
|
|
3068
3077
|
toJSON(message) {
|
|
@@ -3117,7 +3126,7 @@ var Account_WebEntity = {
|
|
|
3117
3126
|
return message;
|
|
3118
3127
|
},
|
|
3119
3128
|
fromJSON(object) {
|
|
3120
|
-
return { webAnalyticsID: isSet3(object.webAnalyticsID) ? String(object.webAnalyticsID) : "" };
|
|
3129
|
+
return { webAnalyticsID: isSet3(object.webAnalyticsID) ? globalThis.String(object.webAnalyticsID) : "" };
|
|
3121
3130
|
},
|
|
3122
3131
|
toJSON(message) {
|
|
3123
3132
|
const obj = {};
|
|
@@ -3247,7 +3256,10 @@ var Account_MetaEntry = {
|
|
|
3247
3256
|
return message;
|
|
3248
3257
|
},
|
|
3249
3258
|
fromJSON(object) {
|
|
3250
|
-
return {
|
|
3259
|
+
return {
|
|
3260
|
+
key: isSet3(object.key) ? globalThis.String(object.key) : "",
|
|
3261
|
+
value: isSet3(object.value) ? globalThis.String(object.value) : ""
|
|
3262
|
+
};
|
|
3251
3263
|
},
|
|
3252
3264
|
toJSON(message) {
|
|
3253
3265
|
const obj = {};
|
|
@@ -3480,8 +3492,8 @@ var WalletBackup = {
|
|
|
3480
3492
|
},
|
|
3481
3493
|
fromJSON(object) {
|
|
3482
3494
|
return {
|
|
3483
|
-
name: isSet4(object.name) ? String(object.name) : "",
|
|
3484
|
-
timestamp: isSet4(object.timestamp) ? Number(object.timestamp) : 0,
|
|
3495
|
+
name: isSet4(object.name) ? globalThis.String(object.name) : "",
|
|
3496
|
+
timestamp: isSet4(object.timestamp) ? globalThis.Number(object.timestamp) : 0,
|
|
3485
3497
|
wallet: isSet4(object.wallet) ? Wallet.fromJSON(object.wallet) : void 0,
|
|
3486
3498
|
passphraseRecovery: isSet4(object.passphraseRecovery) ? WalletBackup_Recovery.fromJSON(object.passphraseRecovery) : void 0
|
|
3487
3499
|
};
|
|
@@ -3565,7 +3577,7 @@ var WalletBackup_Recovery = {
|
|
|
3565
3577
|
},
|
|
3566
3578
|
fromJSON(object) {
|
|
3567
3579
|
return {
|
|
3568
|
-
questionIds: Array.isArray(object?.questionIds) ? object.questionIds.map((e) => walletBackup_Recovery_QuestionEnumFromJSON(e)) : [],
|
|
3580
|
+
questionIds: globalThis.Array.isArray(object?.questionIds) ? object.questionIds.map((e) => walletBackup_Recovery_QuestionEnumFromJSON(e)) : [],
|
|
3569
3581
|
encryptedPassphrase: isSet4(object.encryptedPassphrase) ? bytesFromBase642(object.encryptedPassphrase) : new Uint8Array(0)
|
|
3570
3582
|
};
|
|
3571
3583
|
},
|
|
@@ -3589,26 +3601,11 @@ var WalletBackup_Recovery = {
|
|
|
3589
3601
|
return message;
|
|
3590
3602
|
}
|
|
3591
3603
|
};
|
|
3592
|
-
var tsProtoGlobalThis2 = (() => {
|
|
3593
|
-
if (typeof globalThis !== "undefined") {
|
|
3594
|
-
return globalThis;
|
|
3595
|
-
}
|
|
3596
|
-
if (typeof self !== "undefined") {
|
|
3597
|
-
return self;
|
|
3598
|
-
}
|
|
3599
|
-
if (typeof window !== "undefined") {
|
|
3600
|
-
return window;
|
|
3601
|
-
}
|
|
3602
|
-
if (typeof global !== "undefined") {
|
|
3603
|
-
return global;
|
|
3604
|
-
}
|
|
3605
|
-
throw "Unable to locate global object";
|
|
3606
|
-
})();
|
|
3607
3604
|
function bytesFromBase642(b64) {
|
|
3608
|
-
if (
|
|
3609
|
-
return Uint8Array.from(
|
|
3605
|
+
if (globalThis.Buffer) {
|
|
3606
|
+
return Uint8Array.from(globalThis.Buffer.from(b64, "base64"));
|
|
3610
3607
|
} else {
|
|
3611
|
-
const bin =
|
|
3608
|
+
const bin = globalThis.atob(b64);
|
|
3612
3609
|
const arr = new Uint8Array(bin.length);
|
|
3613
3610
|
for (let i = 0; i < bin.length; ++i) {
|
|
3614
3611
|
arr[i] = bin.charCodeAt(i);
|
|
@@ -3617,19 +3614,19 @@ function bytesFromBase642(b64) {
|
|
|
3617
3614
|
}
|
|
3618
3615
|
}
|
|
3619
3616
|
function base64FromBytes2(arr) {
|
|
3620
|
-
if (
|
|
3621
|
-
return
|
|
3617
|
+
if (globalThis.Buffer) {
|
|
3618
|
+
return globalThis.Buffer.from(arr).toString("base64");
|
|
3622
3619
|
} else {
|
|
3623
3620
|
const bin = [];
|
|
3624
3621
|
arr.forEach((byte) => {
|
|
3625
|
-
bin.push(String.fromCharCode(byte));
|
|
3622
|
+
bin.push(globalThis.String.fromCharCode(byte));
|
|
3626
3623
|
});
|
|
3627
|
-
return
|
|
3624
|
+
return globalThis.btoa(bin.join(""));
|
|
3628
3625
|
}
|
|
3629
3626
|
}
|
|
3630
3627
|
function longToNumber(long) {
|
|
3631
|
-
if (long.gt(Number.MAX_SAFE_INTEGER)) {
|
|
3632
|
-
throw new
|
|
3628
|
+
if (long.gt(globalThis.Number.MAX_SAFE_INTEGER)) {
|
|
3629
|
+
throw new globalThis.Error("Value is larger than Number.MAX_SAFE_INTEGER");
|
|
3633
3630
|
}
|
|
3634
3631
|
return long.toNumber();
|
|
3635
3632
|
}
|
|
@@ -3783,7 +3780,7 @@ var BootNodeGateways = {
|
|
|
3783
3780
|
message.rinkeby = object.rinkeby !== void 0 && object.rinkeby !== null ? BootNodeGateways_NetworkNodes.fromPartial(object.rinkeby) : void 0;
|
|
3784
3781
|
message.meta = Object.entries(object.meta ?? {}).reduce((acc, [key, value]) => {
|
|
3785
3782
|
if (value !== void 0) {
|
|
3786
|
-
acc[key] = String(value);
|
|
3783
|
+
acc[key] = globalThis.String(value);
|
|
3787
3784
|
}
|
|
3788
3785
|
return acc;
|
|
3789
3786
|
}, {});
|
|
@@ -3832,8 +3829,8 @@ var BootNodeGateways_NetworkNodes = {
|
|
|
3832
3829
|
},
|
|
3833
3830
|
fromJSON(object) {
|
|
3834
3831
|
return {
|
|
3835
|
-
dvote: Array.isArray(object?.dvote) ? object.dvote.map((e) => BootNodeGateways_NetworkNodes_DVote.fromJSON(e)) : [],
|
|
3836
|
-
web3: Array.isArray(object?.web3) ? object.web3.map((e) => BootNodeGateways_NetworkNodes_Web3.fromJSON(e)) : []
|
|
3832
|
+
dvote: globalThis.Array.isArray(object?.dvote) ? object.dvote.map((e) => BootNodeGateways_NetworkNodes_DVote.fromJSON(e)) : [],
|
|
3833
|
+
web3: globalThis.Array.isArray(object?.web3) ? object.web3.map((e) => BootNodeGateways_NetworkNodes_Web3.fromJSON(e)) : []
|
|
3837
3834
|
};
|
|
3838
3835
|
},
|
|
3839
3836
|
toJSON(message) {
|
|
@@ -3907,9 +3904,9 @@ var BootNodeGateways_NetworkNodes_DVote = {
|
|
|
3907
3904
|
},
|
|
3908
3905
|
fromJSON(object) {
|
|
3909
3906
|
return {
|
|
3910
|
-
uri: isSet5(object.uri) ? String(object.uri) : "",
|
|
3911
|
-
apis: Array.isArray(object?.apis) ? object.apis.map((e) => String(e)) : [],
|
|
3912
|
-
pubKey: isSet5(object.pubKey) ? String(object.pubKey) : ""
|
|
3907
|
+
uri: isSet5(object.uri) ? globalThis.String(object.uri) : "",
|
|
3908
|
+
apis: globalThis.Array.isArray(object?.apis) ? object.apis.map((e) => globalThis.String(e)) : [],
|
|
3909
|
+
pubKey: isSet5(object.pubKey) ? globalThis.String(object.pubKey) : ""
|
|
3913
3910
|
};
|
|
3914
3911
|
},
|
|
3915
3912
|
toJSON(message) {
|
|
@@ -3968,7 +3965,7 @@ var BootNodeGateways_NetworkNodes_Web3 = {
|
|
|
3968
3965
|
return message;
|
|
3969
3966
|
},
|
|
3970
3967
|
fromJSON(object) {
|
|
3971
|
-
return { uri: isSet5(object.uri) ? String(object.uri) : "" };
|
|
3968
|
+
return { uri: isSet5(object.uri) ? globalThis.String(object.uri) : "" };
|
|
3972
3969
|
},
|
|
3973
3970
|
toJSON(message) {
|
|
3974
3971
|
const obj = {};
|
|
@@ -4027,7 +4024,10 @@ var BootNodeGateways_MetaEntry = {
|
|
|
4027
4024
|
return message;
|
|
4028
4025
|
},
|
|
4029
4026
|
fromJSON(object) {
|
|
4030
|
-
return {
|
|
4027
|
+
return {
|
|
4028
|
+
key: isSet5(object.key) ? globalThis.String(object.key) : "",
|
|
4029
|
+
value: isSet5(object.value) ? globalThis.String(object.value) : ""
|
|
4030
|
+
};
|
|
4031
4031
|
},
|
|
4032
4032
|
toJSON(message) {
|
|
4033
4033
|
const obj = {};
|
|
@@ -4125,7 +4125,7 @@ var FeedStore = {
|
|
|
4125
4125
|
return message;
|
|
4126
4126
|
},
|
|
4127
4127
|
fromJSON(object) {
|
|
4128
|
-
return { items: Array.isArray(object?.items) ? object.items.map((e) => Feed.fromJSON(e)) : [] };
|
|
4128
|
+
return { items: globalThis.Array.isArray(object?.items) ? object.items.map((e) => Feed.fromJSON(e)) : [] };
|
|
4129
4129
|
},
|
|
4130
4130
|
toJSON(message) {
|
|
4131
4131
|
const obj = {};
|
|
@@ -4271,15 +4271,15 @@ var Feed = {
|
|
|
4271
4271
|
},
|
|
4272
4272
|
fromJSON(object) {
|
|
4273
4273
|
return {
|
|
4274
|
-
version: isSet6(object.version) ? String(object.version) : "",
|
|
4275
|
-
title: isSet6(object.title) ? String(object.title) : "",
|
|
4276
|
-
homePageUrl: isSet6(object.homePageUrl) ? String(object.homePageUrl) : "",
|
|
4277
|
-
description: isSet6(object.description) ? String(object.description) : "",
|
|
4278
|
-
feedUrl: isSet6(object.feedUrl) ? String(object.feedUrl) : "",
|
|
4279
|
-
icon: isSet6(object.icon) ? String(object.icon) : "",
|
|
4280
|
-
favicon: isSet6(object.favicon) ? String(object.favicon) : "",
|
|
4281
|
-
expired: isSet6(object.expired) ? Boolean(object.expired) : false,
|
|
4282
|
-
items: Array.isArray(object?.items) ? object.items.map((e) => FeedPost.fromJSON(e)) : [],
|
|
4274
|
+
version: isSet6(object.version) ? globalThis.String(object.version) : "",
|
|
4275
|
+
title: isSet6(object.title) ? globalThis.String(object.title) : "",
|
|
4276
|
+
homePageUrl: isSet6(object.homePageUrl) ? globalThis.String(object.homePageUrl) : "",
|
|
4277
|
+
description: isSet6(object.description) ? globalThis.String(object.description) : "",
|
|
4278
|
+
feedUrl: isSet6(object.feedUrl) ? globalThis.String(object.feedUrl) : "",
|
|
4279
|
+
icon: isSet6(object.icon) ? globalThis.String(object.icon) : "",
|
|
4280
|
+
favicon: isSet6(object.favicon) ? globalThis.String(object.favicon) : "",
|
|
4281
|
+
expired: isSet6(object.expired) ? globalThis.Boolean(object.expired) : false,
|
|
4282
|
+
items: globalThis.Array.isArray(object?.items) ? object.items.map((e) => FeedPost.fromJSON(e)) : [],
|
|
4283
4283
|
meta: isObject4(object.meta) ? Object.entries(object.meta).reduce((acc, [key, value]) => {
|
|
4284
4284
|
acc[key] = String(value);
|
|
4285
4285
|
return acc;
|
|
@@ -4342,7 +4342,7 @@ var Feed = {
|
|
|
4342
4342
|
message.items = object.items?.map((e) => FeedPost.fromPartial(e)) || [];
|
|
4343
4343
|
message.meta = Object.entries(object.meta ?? {}).reduce((acc, [key, value]) => {
|
|
4344
4344
|
if (value !== void 0) {
|
|
4345
|
-
acc[key] = String(value);
|
|
4345
|
+
acc[key] = globalThis.String(value);
|
|
4346
4346
|
}
|
|
4347
4347
|
return acc;
|
|
4348
4348
|
}, {});
|
|
@@ -4390,7 +4390,10 @@ var Feed_MetaEntry = {
|
|
|
4390
4390
|
return message;
|
|
4391
4391
|
},
|
|
4392
4392
|
fromJSON(object) {
|
|
4393
|
-
return {
|
|
4393
|
+
return {
|
|
4394
|
+
key: isSet6(object.key) ? globalThis.String(object.key) : "",
|
|
4395
|
+
value: isSet6(object.value) ? globalThis.String(object.value) : ""
|
|
4396
|
+
};
|
|
4394
4397
|
},
|
|
4395
4398
|
toJSON(message) {
|
|
4396
4399
|
const obj = {};
|
|
@@ -4547,16 +4550,16 @@ var FeedPost = {
|
|
|
4547
4550
|
},
|
|
4548
4551
|
fromJSON(object) {
|
|
4549
4552
|
return {
|
|
4550
|
-
id: isSet6(object.id) ? String(object.id) : "",
|
|
4551
|
-
title: isSet6(object.title) ? String(object.title) : "",
|
|
4552
|
-
summary: isSet6(object.summary) ? String(object.summary) : "",
|
|
4553
|
-
contentText: isSet6(object.contentText) ? String(object.contentText) : "",
|
|
4554
|
-
contentHtml: isSet6(object.contentHtml) ? String(object.contentHtml) : "",
|
|
4555
|
-
url: isSet6(object.url) ? String(object.url) : "",
|
|
4556
|
-
image: isSet6(object.image) ? String(object.image) : "",
|
|
4557
|
-
tags: Array.isArray(object?.tags) ? object.tags.map((e) => String(e)) : [],
|
|
4558
|
-
datePublished: isSet6(object.datePublished) ? String(object.datePublished) : "",
|
|
4559
|
-
dateModified: isSet6(object.dateModified) ? String(object.dateModified) : "",
|
|
4553
|
+
id: isSet6(object.id) ? globalThis.String(object.id) : "",
|
|
4554
|
+
title: isSet6(object.title) ? globalThis.String(object.title) : "",
|
|
4555
|
+
summary: isSet6(object.summary) ? globalThis.String(object.summary) : "",
|
|
4556
|
+
contentText: isSet6(object.contentText) ? globalThis.String(object.contentText) : "",
|
|
4557
|
+
contentHtml: isSet6(object.contentHtml) ? globalThis.String(object.contentHtml) : "",
|
|
4558
|
+
url: isSet6(object.url) ? globalThis.String(object.url) : "",
|
|
4559
|
+
image: isSet6(object.image) ? globalThis.String(object.image) : "",
|
|
4560
|
+
tags: globalThis.Array.isArray(object?.tags) ? object.tags.map((e) => globalThis.String(e)) : [],
|
|
4561
|
+
datePublished: isSet6(object.datePublished) ? globalThis.String(object.datePublished) : "",
|
|
4562
|
+
dateModified: isSet6(object.dateModified) ? globalThis.String(object.dateModified) : "",
|
|
4560
4563
|
author: isSet6(object.author) ? FeedPost_Author.fromJSON(object.author) : void 0
|
|
4561
4564
|
};
|
|
4562
4565
|
},
|
|
@@ -4657,7 +4660,10 @@ var FeedPost_Author = {
|
|
|
4657
4660
|
return message;
|
|
4658
4661
|
},
|
|
4659
4662
|
fromJSON(object) {
|
|
4660
|
-
return {
|
|
4663
|
+
return {
|
|
4664
|
+
name: isSet6(object.name) ? globalThis.String(object.name) : "",
|
|
4665
|
+
url: isSet6(object.url) ? globalThis.String(object.url) : ""
|
|
4666
|
+
};
|
|
4661
4667
|
},
|
|
4662
4668
|
toJSON(message) {
|
|
4663
4669
|
const obj = {};
|
|
@@ -4720,7 +4726,9 @@ var ProcessMetadataStore = {
|
|
|
4720
4726
|
return message;
|
|
4721
4727
|
},
|
|
4722
4728
|
fromJSON(object) {
|
|
4723
|
-
return {
|
|
4729
|
+
return {
|
|
4730
|
+
items: globalThis.Array.isArray(object?.items) ? object.items.map((e) => ProcessMetadata.fromJSON(e)) : []
|
|
4731
|
+
};
|
|
4724
4732
|
},
|
|
4725
4733
|
toJSON(message) {
|
|
4726
4734
|
const obj = {};
|
|
@@ -4837,7 +4845,7 @@ var ProcessMetadata = {
|
|
|
4837
4845
|
},
|
|
4838
4846
|
fromJSON(object) {
|
|
4839
4847
|
return {
|
|
4840
|
-
version: isSet7(object.version) ? String(object.version) : "",
|
|
4848
|
+
version: isSet7(object.version) ? globalThis.String(object.version) : "",
|
|
4841
4849
|
title: isObject5(object.title) ? Object.entries(object.title).reduce((acc, [key, value]) => {
|
|
4842
4850
|
acc[key] = String(value);
|
|
4843
4851
|
return acc;
|
|
@@ -4850,7 +4858,7 @@ var ProcessMetadata = {
|
|
|
4850
4858
|
acc[key] = String(value);
|
|
4851
4859
|
return acc;
|
|
4852
4860
|
}, {}) : {},
|
|
4853
|
-
questions: Array.isArray(object?.questions) ? object.questions.map((e) => ProcessMetadata_Question.fromJSON(e)) : [],
|
|
4861
|
+
questions: globalThis.Array.isArray(object?.questions) ? object.questions.map((e) => ProcessMetadata_Question.fromJSON(e)) : [],
|
|
4854
4862
|
results: isSet7(object.results) ? ProcessMetadata_Results.fromJSON(object.results) : void 0,
|
|
4855
4863
|
meta: isObject5(object.meta) ? Object.entries(object.meta).reduce((acc, [key, value]) => {
|
|
4856
4864
|
acc[key] = String(value);
|
|
@@ -4915,14 +4923,14 @@ var ProcessMetadata = {
|
|
|
4915
4923
|
message.version = object.version ?? "";
|
|
4916
4924
|
message.title = Object.entries(object.title ?? {}).reduce((acc, [key, value]) => {
|
|
4917
4925
|
if (value !== void 0) {
|
|
4918
|
-
acc[key] = String(value);
|
|
4926
|
+
acc[key] = globalThis.String(value);
|
|
4919
4927
|
}
|
|
4920
4928
|
return acc;
|
|
4921
4929
|
}, {});
|
|
4922
4930
|
message.description = Object.entries(object.description ?? {}).reduce(
|
|
4923
4931
|
(acc, [key, value]) => {
|
|
4924
4932
|
if (value !== void 0) {
|
|
4925
|
-
acc[key] = String(value);
|
|
4933
|
+
acc[key] = globalThis.String(value);
|
|
4926
4934
|
}
|
|
4927
4935
|
return acc;
|
|
4928
4936
|
},
|
|
@@ -4930,7 +4938,7 @@ var ProcessMetadata = {
|
|
|
4930
4938
|
);
|
|
4931
4939
|
message.media = Object.entries(object.media ?? {}).reduce((acc, [key, value]) => {
|
|
4932
4940
|
if (value !== void 0) {
|
|
4933
|
-
acc[key] = String(value);
|
|
4941
|
+
acc[key] = globalThis.String(value);
|
|
4934
4942
|
}
|
|
4935
4943
|
return acc;
|
|
4936
4944
|
}, {});
|
|
@@ -4938,7 +4946,7 @@ var ProcessMetadata = {
|
|
|
4938
4946
|
message.results = object.results !== void 0 && object.results !== null ? ProcessMetadata_Results.fromPartial(object.results) : void 0;
|
|
4939
4947
|
message.meta = Object.entries(object.meta ?? {}).reduce((acc, [key, value]) => {
|
|
4940
4948
|
if (value !== void 0) {
|
|
4941
|
-
acc[key] = String(value);
|
|
4949
|
+
acc[key] = globalThis.String(value);
|
|
4942
4950
|
}
|
|
4943
4951
|
return acc;
|
|
4944
4952
|
}, {});
|
|
@@ -4986,7 +4994,10 @@ var ProcessMetadata_TitleEntry = {
|
|
|
4986
4994
|
return message;
|
|
4987
4995
|
},
|
|
4988
4996
|
fromJSON(object) {
|
|
4989
|
-
return {
|
|
4997
|
+
return {
|
|
4998
|
+
key: isSet7(object.key) ? globalThis.String(object.key) : "",
|
|
4999
|
+
value: isSet7(object.value) ? globalThis.String(object.value) : ""
|
|
5000
|
+
};
|
|
4990
5001
|
},
|
|
4991
5002
|
toJSON(message) {
|
|
4992
5003
|
const obj = {};
|
|
@@ -5049,7 +5060,10 @@ var ProcessMetadata_DescriptionEntry = {
|
|
|
5049
5060
|
return message;
|
|
5050
5061
|
},
|
|
5051
5062
|
fromJSON(object) {
|
|
5052
|
-
return {
|
|
5063
|
+
return {
|
|
5064
|
+
key: isSet7(object.key) ? globalThis.String(object.key) : "",
|
|
5065
|
+
value: isSet7(object.value) ? globalThis.String(object.value) : ""
|
|
5066
|
+
};
|
|
5053
5067
|
},
|
|
5054
5068
|
toJSON(message) {
|
|
5055
5069
|
const obj = {};
|
|
@@ -5112,7 +5126,10 @@ var ProcessMetadata_MediaEntry = {
|
|
|
5112
5126
|
return message;
|
|
5113
5127
|
},
|
|
5114
5128
|
fromJSON(object) {
|
|
5115
|
-
return {
|
|
5129
|
+
return {
|
|
5130
|
+
key: isSet7(object.key) ? globalThis.String(object.key) : "",
|
|
5131
|
+
value: isSet7(object.value) ? globalThis.String(object.value) : ""
|
|
5132
|
+
};
|
|
5116
5133
|
},
|
|
5117
5134
|
toJSON(message) {
|
|
5118
5135
|
const obj = {};
|
|
@@ -5199,7 +5216,7 @@ var ProcessMetadata_Question = {
|
|
|
5199
5216
|
acc[key] = String(value);
|
|
5200
5217
|
return acc;
|
|
5201
5218
|
}, {}) : {},
|
|
5202
|
-
choices: Array.isArray(object?.choices) ? object.choices.map((e) => ProcessMetadata_Question_VoteOption.fromJSON(e)) : []
|
|
5219
|
+
choices: globalThis.Array.isArray(object?.choices) ? object.choices.map((e) => ProcessMetadata_Question_VoteOption.fromJSON(e)) : []
|
|
5203
5220
|
};
|
|
5204
5221
|
},
|
|
5205
5222
|
toJSON(message) {
|
|
@@ -5234,14 +5251,14 @@ var ProcessMetadata_Question = {
|
|
|
5234
5251
|
const message = createBaseProcessMetadata_Question();
|
|
5235
5252
|
message.title = Object.entries(object.title ?? {}).reduce((acc, [key, value]) => {
|
|
5236
5253
|
if (value !== void 0) {
|
|
5237
|
-
acc[key] = String(value);
|
|
5254
|
+
acc[key] = globalThis.String(value);
|
|
5238
5255
|
}
|
|
5239
5256
|
return acc;
|
|
5240
5257
|
}, {});
|
|
5241
5258
|
message.description = Object.entries(object.description ?? {}).reduce(
|
|
5242
5259
|
(acc, [key, value]) => {
|
|
5243
5260
|
if (value !== void 0) {
|
|
5244
|
-
acc[key] = String(value);
|
|
5261
|
+
acc[key] = globalThis.String(value);
|
|
5245
5262
|
}
|
|
5246
5263
|
return acc;
|
|
5247
5264
|
},
|
|
@@ -5292,7 +5309,10 @@ var ProcessMetadata_Question_TitleEntry = {
|
|
|
5292
5309
|
return message;
|
|
5293
5310
|
},
|
|
5294
5311
|
fromJSON(object) {
|
|
5295
|
-
return {
|
|
5312
|
+
return {
|
|
5313
|
+
key: isSet7(object.key) ? globalThis.String(object.key) : "",
|
|
5314
|
+
value: isSet7(object.value) ? globalThis.String(object.value) : ""
|
|
5315
|
+
};
|
|
5296
5316
|
},
|
|
5297
5317
|
toJSON(message) {
|
|
5298
5318
|
const obj = {};
|
|
@@ -5355,7 +5375,10 @@ var ProcessMetadata_Question_DescriptionEntry = {
|
|
|
5355
5375
|
return message;
|
|
5356
5376
|
},
|
|
5357
5377
|
fromJSON(object) {
|
|
5358
|
-
return {
|
|
5378
|
+
return {
|
|
5379
|
+
key: isSet7(object.key) ? globalThis.String(object.key) : "",
|
|
5380
|
+
value: isSet7(object.value) ? globalThis.String(object.value) : ""
|
|
5381
|
+
};
|
|
5359
5382
|
},
|
|
5360
5383
|
toJSON(message) {
|
|
5361
5384
|
const obj = {};
|
|
@@ -5426,7 +5449,7 @@ var ProcessMetadata_Question_VoteOption = {
|
|
|
5426
5449
|
acc[key] = String(value);
|
|
5427
5450
|
return acc;
|
|
5428
5451
|
}, {}) : {},
|
|
5429
|
-
value: isSet7(object.value) ? Number(object.value) : 0
|
|
5452
|
+
value: isSet7(object.value) ? globalThis.Number(object.value) : 0
|
|
5430
5453
|
};
|
|
5431
5454
|
},
|
|
5432
5455
|
toJSON(message) {
|
|
@@ -5452,7 +5475,7 @@ var ProcessMetadata_Question_VoteOption = {
|
|
|
5452
5475
|
const message = createBaseProcessMetadata_Question_VoteOption();
|
|
5453
5476
|
message.title = Object.entries(object.title ?? {}).reduce((acc, [key, value]) => {
|
|
5454
5477
|
if (value !== void 0) {
|
|
5455
|
-
acc[key] = String(value);
|
|
5478
|
+
acc[key] = globalThis.String(value);
|
|
5456
5479
|
}
|
|
5457
5480
|
return acc;
|
|
5458
5481
|
}, {});
|
|
@@ -5501,7 +5524,10 @@ var ProcessMetadata_Question_VoteOption_TitleEntry = {
|
|
|
5501
5524
|
return message;
|
|
5502
5525
|
},
|
|
5503
5526
|
fromJSON(object) {
|
|
5504
|
-
return {
|
|
5527
|
+
return {
|
|
5528
|
+
key: isSet7(object.key) ? globalThis.String(object.key) : "",
|
|
5529
|
+
value: isSet7(object.value) ? globalThis.String(object.value) : ""
|
|
5530
|
+
};
|
|
5505
5531
|
},
|
|
5506
5532
|
toJSON(message) {
|
|
5507
5533
|
const obj = {};
|
|
@@ -5565,8 +5591,8 @@ var ProcessMetadata_Results = {
|
|
|
5565
5591
|
},
|
|
5566
5592
|
fromJSON(object) {
|
|
5567
5593
|
return {
|
|
5568
|
-
aggregation: isSet7(object.aggregation) ? String(object.aggregation) : "",
|
|
5569
|
-
display: isSet7(object.display) ? String(object.display) : ""
|
|
5594
|
+
aggregation: isSet7(object.aggregation) ? globalThis.String(object.aggregation) : "",
|
|
5595
|
+
display: isSet7(object.display) ? globalThis.String(object.display) : ""
|
|
5570
5596
|
};
|
|
5571
5597
|
},
|
|
5572
5598
|
toJSON(message) {
|
|
@@ -5630,7 +5656,10 @@ var ProcessMetadata_MetaEntry = {
|
|
|
5630
5656
|
return message;
|
|
5631
5657
|
},
|
|
5632
5658
|
fromJSON(object) {
|
|
5633
|
-
return {
|
|
5659
|
+
return {
|
|
5660
|
+
key: isSet7(object.key) ? globalThis.String(object.key) : "",
|
|
5661
|
+
value: isSet7(object.value) ? globalThis.String(object.value) : ""
|
|
5662
|
+
};
|
|
5634
5663
|
},
|
|
5635
5664
|
toJSON(message) {
|
|
5636
5665
|
const obj = {};
|
|
@@ -5672,7 +5701,6 @@ __export(vochain_exports, {
|
|
|
5672
5701
|
EnvelopeType: () => EnvelopeType,
|
|
5673
5702
|
FaucetPackage: () => FaucetPackage,
|
|
5674
5703
|
FaucetPayload: () => FaucetPayload,
|
|
5675
|
-
MintTokensTx: () => MintTokensTx,
|
|
5676
5704
|
NewProcessTx: () => NewProcessTx,
|
|
5677
5705
|
OracleList: () => OracleList,
|
|
5678
5706
|
Process: () => Process,
|
|
@@ -5689,8 +5717,6 @@ __export(vochain_exports, {
|
|
|
5689
5717
|
ProofCA_Type: () => ProofCA_Type,
|
|
5690
5718
|
ProofEthereumAccount: () => ProofEthereumAccount,
|
|
5691
5719
|
ProofEthereumStorage: () => ProofEthereumStorage,
|
|
5692
|
-
ProofGraviton: () => ProofGraviton,
|
|
5693
|
-
ProofIden3: () => ProofIden3,
|
|
5694
5720
|
ProofMinime: () => ProofMinime,
|
|
5695
5721
|
ProofZkSNARK: () => ProofZkSNARK,
|
|
5696
5722
|
QuestionResult: () => QuestionResult,
|
|
@@ -5706,7 +5732,6 @@ __export(vochain_exports, {
|
|
|
5706
5732
|
SourceNetworkId: () => SourceNetworkId,
|
|
5707
5733
|
StoredKeys: () => StoredKeys,
|
|
5708
5734
|
TendermintHeader: () => TendermintHeader,
|
|
5709
|
-
Treasurer: () => Treasurer,
|
|
5710
5735
|
Tx: () => Tx,
|
|
5711
5736
|
TxType: () => TxType,
|
|
5712
5737
|
Validator: () => Validator,
|
|
@@ -5748,9 +5773,7 @@ var TxType = /* @__PURE__ */ ((TxType2) => {
|
|
|
5748
5773
|
TxType2[TxType2["VOTE"] = 11] = "VOTE";
|
|
5749
5774
|
TxType2[TxType2["SET_PROCESS_RESULTS"] = 12] = "SET_PROCESS_RESULTS";
|
|
5750
5775
|
TxType2[TxType2["REGISTER_VOTER_KEY"] = 13] = "REGISTER_VOTER_KEY";
|
|
5751
|
-
TxType2[TxType2["MINT_TOKENS"] = 14] = "MINT_TOKENS";
|
|
5752
5776
|
TxType2[TxType2["SEND_TOKENS"] = 15] = "SEND_TOKENS";
|
|
5753
|
-
TxType2[TxType2["SET_TRANSACTION_COSTS"] = 16] = "SET_TRANSACTION_COSTS";
|
|
5754
5777
|
TxType2[TxType2["SET_ACCOUNT_INFO_URI"] = 17] = "SET_ACCOUNT_INFO_URI";
|
|
5755
5778
|
TxType2[TxType2["ADD_DELEGATE_FOR_ACCOUNT"] = 18] = "ADD_DELEGATE_FOR_ACCOUNT";
|
|
5756
5779
|
TxType2[TxType2["DEL_DELEGATE_FOR_ACCOUNT"] = 19] = "DEL_DELEGATE_FOR_ACCOUNT";
|
|
@@ -5761,6 +5784,7 @@ var TxType = /* @__PURE__ */ ((TxType2) => {
|
|
|
5761
5784
|
TxType2[TxType2["SET_ACCOUNT_SIK"] = 24] = "SET_ACCOUNT_SIK";
|
|
5762
5785
|
TxType2[TxType2["DEL_ACCOUNT_SIK"] = 25] = "DEL_ACCOUNT_SIK";
|
|
5763
5786
|
TxType2[TxType2["REGISTER_SIK"] = 26] = "REGISTER_SIK";
|
|
5787
|
+
TxType2[TxType2["SET_ACCOUNT_VALIDATOR"] = 27] = "SET_ACCOUNT_VALIDATOR";
|
|
5764
5788
|
TxType2[TxType2["UNRECOGNIZED"] = -1] = "UNRECOGNIZED";
|
|
5765
5789
|
return TxType2;
|
|
5766
5790
|
})(TxType || {});
|
|
@@ -5808,15 +5832,9 @@ function txTypeFromJSON(object) {
|
|
|
5808
5832
|
case 13:
|
|
5809
5833
|
case "REGISTER_VOTER_KEY":
|
|
5810
5834
|
return 13 /* REGISTER_VOTER_KEY */;
|
|
5811
|
-
case 14:
|
|
5812
|
-
case "MINT_TOKENS":
|
|
5813
|
-
return 14 /* MINT_TOKENS */;
|
|
5814
5835
|
case 15:
|
|
5815
5836
|
case "SEND_TOKENS":
|
|
5816
5837
|
return 15 /* SEND_TOKENS */;
|
|
5817
|
-
case 16:
|
|
5818
|
-
case "SET_TRANSACTION_COSTS":
|
|
5819
|
-
return 16 /* SET_TRANSACTION_COSTS */;
|
|
5820
5838
|
case 17:
|
|
5821
5839
|
case "SET_ACCOUNT_INFO_URI":
|
|
5822
5840
|
return 17 /* SET_ACCOUNT_INFO_URI */;
|
|
@@ -5847,6 +5865,9 @@ function txTypeFromJSON(object) {
|
|
|
5847
5865
|
case 26:
|
|
5848
5866
|
case "REGISTER_SIK":
|
|
5849
5867
|
return 26 /* REGISTER_SIK */;
|
|
5868
|
+
case 27:
|
|
5869
|
+
case "SET_ACCOUNT_VALIDATOR":
|
|
5870
|
+
return 27 /* SET_ACCOUNT_VALIDATOR */;
|
|
5850
5871
|
case -1:
|
|
5851
5872
|
case "UNRECOGNIZED":
|
|
5852
5873
|
default:
|
|
@@ -5883,12 +5904,8 @@ function txTypeToJSON(object) {
|
|
|
5883
5904
|
return "SET_PROCESS_RESULTS";
|
|
5884
5905
|
case 13 /* REGISTER_VOTER_KEY */:
|
|
5885
5906
|
return "REGISTER_VOTER_KEY";
|
|
5886
|
-
case 14 /* MINT_TOKENS */:
|
|
5887
|
-
return "MINT_TOKENS";
|
|
5888
5907
|
case 15 /* SEND_TOKENS */:
|
|
5889
5908
|
return "SEND_TOKENS";
|
|
5890
|
-
case 16 /* SET_TRANSACTION_COSTS */:
|
|
5891
|
-
return "SET_TRANSACTION_COSTS";
|
|
5892
5909
|
case 17 /* SET_ACCOUNT_INFO_URI */:
|
|
5893
5910
|
return "SET_ACCOUNT_INFO_URI";
|
|
5894
5911
|
case 18 /* ADD_DELEGATE_FOR_ACCOUNT */:
|
|
@@ -5909,6 +5926,8 @@ function txTypeToJSON(object) {
|
|
|
5909
5926
|
return "DEL_ACCOUNT_SIK";
|
|
5910
5927
|
case 26 /* REGISTER_SIK */:
|
|
5911
5928
|
return "REGISTER_SIK";
|
|
5929
|
+
case 27 /* SET_ACCOUNT_VALIDATOR */:
|
|
5930
|
+
return "SET_ACCOUNT_VALIDATOR";
|
|
5912
5931
|
case -1 /* UNRECOGNIZED */:
|
|
5913
5932
|
default:
|
|
5914
5933
|
return "UNRECOGNIZED";
|
|
@@ -6158,8 +6177,6 @@ var Census_Type = /* @__PURE__ */ ((Census_Type2) => {
|
|
|
6158
6177
|
Census_Type2[Census_Type2["ETHEREUMSTORAGE"] = 3] = "ETHEREUMSTORAGE";
|
|
6159
6178
|
Census_Type2[Census_Type2["ETHEREUMACCOUNT"] = 4] = "ETHEREUMACCOUNT";
|
|
6160
6179
|
Census_Type2[Census_Type2["CA"] = 5] = "CA";
|
|
6161
|
-
Census_Type2[Census_Type2["GRAVITON"] = 1001] = "GRAVITON";
|
|
6162
|
-
Census_Type2[Census_Type2["IDEN3"] = 1002] = "IDEN3";
|
|
6163
6180
|
Census_Type2[Census_Type2["UNRECOGNIZED"] = -1] = "UNRECOGNIZED";
|
|
6164
6181
|
return Census_Type2;
|
|
6165
6182
|
})(Census_Type || {});
|
|
@@ -6183,12 +6200,6 @@ function census_TypeFromJSON(object) {
|
|
|
6183
6200
|
case 5:
|
|
6184
6201
|
case "CA":
|
|
6185
6202
|
return 5 /* CA */;
|
|
6186
|
-
case 1001:
|
|
6187
|
-
case "GRAVITON":
|
|
6188
|
-
return 1001 /* GRAVITON */;
|
|
6189
|
-
case 1002:
|
|
6190
|
-
case "IDEN3":
|
|
6191
|
-
return 1002 /* IDEN3 */;
|
|
6192
6203
|
case -1:
|
|
6193
6204
|
case "UNRECOGNIZED":
|
|
6194
6205
|
default:
|
|
@@ -6209,10 +6220,6 @@ function census_TypeToJSON(object) {
|
|
|
6209
6220
|
return "ETHEREUMACCOUNT";
|
|
6210
6221
|
case 5 /* CA */:
|
|
6211
6222
|
return "CA";
|
|
6212
|
-
case 1001 /* GRAVITON */:
|
|
6213
|
-
return "GRAVITON";
|
|
6214
|
-
case 1002 /* IDEN3 */:
|
|
6215
|
-
return "IDEN3";
|
|
6216
6223
|
case -1 /* UNRECOGNIZED */:
|
|
6217
6224
|
default:
|
|
6218
6225
|
return "UNRECOGNIZED";
|
|
@@ -6428,7 +6435,7 @@ var VoteEnvelope = {
|
|
|
6428
6435
|
proof: isSet8(object.proof) ? Proof.fromJSON(object.proof) : void 0,
|
|
6429
6436
|
votePackage: isSet8(object.votePackage) ? bytesFromBase643(object.votePackage) : new Uint8Array(0),
|
|
6430
6437
|
nullifier: isSet8(object.nullifier) ? bytesFromBase643(object.nullifier) : new Uint8Array(0),
|
|
6431
|
-
encryptionKeyIndexes: Array.isArray(object?.encryptionKeyIndexes) ? object.encryptionKeyIndexes.map((e) => Number(e)) : []
|
|
6438
|
+
encryptionKeyIndexes: globalThis.Array.isArray(object?.encryptionKeyIndexes) ? object.encryptionKeyIndexes.map((e) => globalThis.Number(e)) : []
|
|
6432
6439
|
};
|
|
6433
6440
|
},
|
|
6434
6441
|
toJSON(message) {
|
|
@@ -6510,12 +6517,6 @@ function createBaseProof() {
|
|
|
6510
6517
|
var Proof = {
|
|
6511
6518
|
encode(message, writer = import_minimal8.default.Writer.create()) {
|
|
6512
6519
|
switch (message.payload?.$case) {
|
|
6513
|
-
case "graviton":
|
|
6514
|
-
ProofGraviton.encode(message.payload.graviton, writer.uint32(10).fork()).ldelim();
|
|
6515
|
-
break;
|
|
6516
|
-
case "iden3":
|
|
6517
|
-
ProofIden3.encode(message.payload.iden3, writer.uint32(18).fork()).ldelim();
|
|
6518
|
-
break;
|
|
6519
6520
|
case "ethereumStorage":
|
|
6520
6521
|
ProofEthereumStorage.encode(message.payload.ethereumStorage, writer.uint32(26).fork()).ldelim();
|
|
6521
6522
|
break;
|
|
@@ -6544,18 +6545,6 @@ var Proof = {
|
|
|
6544
6545
|
while (reader.pos < end) {
|
|
6545
6546
|
const tag = reader.uint32();
|
|
6546
6547
|
switch (tag >>> 3) {
|
|
6547
|
-
case 1:
|
|
6548
|
-
if (tag !== 10) {
|
|
6549
|
-
break;
|
|
6550
|
-
}
|
|
6551
|
-
message.payload = { $case: "graviton", graviton: ProofGraviton.decode(reader, reader.uint32()) };
|
|
6552
|
-
continue;
|
|
6553
|
-
case 2:
|
|
6554
|
-
if (tag !== 18) {
|
|
6555
|
-
break;
|
|
6556
|
-
}
|
|
6557
|
-
message.payload = { $case: "iden3", iden3: ProofIden3.decode(reader, reader.uint32()) };
|
|
6558
|
-
continue;
|
|
6559
6548
|
case 3:
|
|
6560
6549
|
if (tag !== 26) {
|
|
6561
6550
|
break;
|
|
@@ -6608,17 +6597,11 @@ var Proof = {
|
|
|
6608
6597
|
},
|
|
6609
6598
|
fromJSON(object) {
|
|
6610
6599
|
return {
|
|
6611
|
-
payload: isSet8(object.
|
|
6600
|
+
payload: isSet8(object.ethereumStorage) ? { $case: "ethereumStorage", ethereumStorage: ProofEthereumStorage.fromJSON(object.ethereumStorage) } : isSet8(object.ethereumAccount) ? { $case: "ethereumAccount", ethereumAccount: ProofEthereumAccount.fromJSON(object.ethereumAccount) } : isSet8(object.ca) ? { $case: "ca", ca: ProofCA.fromJSON(object.ca) } : isSet8(object.arbo) ? { $case: "arbo", arbo: ProofArbo.fromJSON(object.arbo) } : isSet8(object.zkSnark) ? { $case: "zkSnark", zkSnark: ProofZkSNARK.fromJSON(object.zkSnark) } : isSet8(object.minimeStorage) ? { $case: "minimeStorage", minimeStorage: ProofMinime.fromJSON(object.minimeStorage) } : void 0
|
|
6612
6601
|
};
|
|
6613
6602
|
},
|
|
6614
6603
|
toJSON(message) {
|
|
6615
6604
|
const obj = {};
|
|
6616
|
-
if (message.payload?.$case === "graviton") {
|
|
6617
|
-
obj.graviton = ProofGraviton.toJSON(message.payload.graviton);
|
|
6618
|
-
}
|
|
6619
|
-
if (message.payload?.$case === "iden3") {
|
|
6620
|
-
obj.iden3 = ProofIden3.toJSON(message.payload.iden3);
|
|
6621
|
-
}
|
|
6622
6605
|
if (message.payload?.$case === "ethereumStorage") {
|
|
6623
6606
|
obj.ethereumStorage = ProofEthereumStorage.toJSON(message.payload.ethereumStorage);
|
|
6624
6607
|
}
|
|
@@ -6644,12 +6627,6 @@ var Proof = {
|
|
|
6644
6627
|
},
|
|
6645
6628
|
fromPartial(object) {
|
|
6646
6629
|
const message = createBaseProof();
|
|
6647
|
-
if (object.payload?.$case === "graviton" && object.payload?.graviton !== void 0 && object.payload?.graviton !== null) {
|
|
6648
|
-
message.payload = { $case: "graviton", graviton: ProofGraviton.fromPartial(object.payload.graviton) };
|
|
6649
|
-
}
|
|
6650
|
-
if (object.payload?.$case === "iden3" && object.payload?.iden3 !== void 0 && object.payload?.iden3 !== null) {
|
|
6651
|
-
message.payload = { $case: "iden3", iden3: ProofIden3.fromPartial(object.payload.iden3) };
|
|
6652
|
-
}
|
|
6653
6630
|
if (object.payload?.$case === "ethereumStorage" && object.payload?.ethereumStorage !== void 0 && object.payload?.ethereumStorage !== null) {
|
|
6654
6631
|
message.payload = {
|
|
6655
6632
|
$case: "ethereumStorage",
|
|
@@ -6680,106 +6657,6 @@ var Proof = {
|
|
|
6680
6657
|
return message;
|
|
6681
6658
|
}
|
|
6682
6659
|
};
|
|
6683
|
-
function createBaseProofGraviton() {
|
|
6684
|
-
return { siblings: new Uint8Array(0) };
|
|
6685
|
-
}
|
|
6686
|
-
var ProofGraviton = {
|
|
6687
|
-
encode(message, writer = import_minimal8.default.Writer.create()) {
|
|
6688
|
-
if (message.siblings.length !== 0) {
|
|
6689
|
-
writer.uint32(10).bytes(message.siblings);
|
|
6690
|
-
}
|
|
6691
|
-
return writer;
|
|
6692
|
-
},
|
|
6693
|
-
decode(input, length) {
|
|
6694
|
-
const reader = input instanceof import_minimal8.default.Reader ? input : import_minimal8.default.Reader.create(input);
|
|
6695
|
-
let end = length === void 0 ? reader.len : reader.pos + length;
|
|
6696
|
-
const message = createBaseProofGraviton();
|
|
6697
|
-
while (reader.pos < end) {
|
|
6698
|
-
const tag = reader.uint32();
|
|
6699
|
-
switch (tag >>> 3) {
|
|
6700
|
-
case 1:
|
|
6701
|
-
if (tag !== 10) {
|
|
6702
|
-
break;
|
|
6703
|
-
}
|
|
6704
|
-
message.siblings = reader.bytes();
|
|
6705
|
-
continue;
|
|
6706
|
-
}
|
|
6707
|
-
if ((tag & 7) === 4 || tag === 0) {
|
|
6708
|
-
break;
|
|
6709
|
-
}
|
|
6710
|
-
reader.skipType(tag & 7);
|
|
6711
|
-
}
|
|
6712
|
-
return message;
|
|
6713
|
-
},
|
|
6714
|
-
fromJSON(object) {
|
|
6715
|
-
return { siblings: isSet8(object.siblings) ? bytesFromBase643(object.siblings) : new Uint8Array(0) };
|
|
6716
|
-
},
|
|
6717
|
-
toJSON(message) {
|
|
6718
|
-
const obj = {};
|
|
6719
|
-
if (message.siblings.length !== 0) {
|
|
6720
|
-
obj.siblings = base64FromBytes3(message.siblings);
|
|
6721
|
-
}
|
|
6722
|
-
return obj;
|
|
6723
|
-
},
|
|
6724
|
-
create(base) {
|
|
6725
|
-
return ProofGraviton.fromPartial(base ?? {});
|
|
6726
|
-
},
|
|
6727
|
-
fromPartial(object) {
|
|
6728
|
-
const message = createBaseProofGraviton();
|
|
6729
|
-
message.siblings = object.siblings ?? new Uint8Array(0);
|
|
6730
|
-
return message;
|
|
6731
|
-
}
|
|
6732
|
-
};
|
|
6733
|
-
function createBaseProofIden3() {
|
|
6734
|
-
return { siblings: new Uint8Array(0) };
|
|
6735
|
-
}
|
|
6736
|
-
var ProofIden3 = {
|
|
6737
|
-
encode(message, writer = import_minimal8.default.Writer.create()) {
|
|
6738
|
-
if (message.siblings.length !== 0) {
|
|
6739
|
-
writer.uint32(10).bytes(message.siblings);
|
|
6740
|
-
}
|
|
6741
|
-
return writer;
|
|
6742
|
-
},
|
|
6743
|
-
decode(input, length) {
|
|
6744
|
-
const reader = input instanceof import_minimal8.default.Reader ? input : import_minimal8.default.Reader.create(input);
|
|
6745
|
-
let end = length === void 0 ? reader.len : reader.pos + length;
|
|
6746
|
-
const message = createBaseProofIden3();
|
|
6747
|
-
while (reader.pos < end) {
|
|
6748
|
-
const tag = reader.uint32();
|
|
6749
|
-
switch (tag >>> 3) {
|
|
6750
|
-
case 1:
|
|
6751
|
-
if (tag !== 10) {
|
|
6752
|
-
break;
|
|
6753
|
-
}
|
|
6754
|
-
message.siblings = reader.bytes();
|
|
6755
|
-
continue;
|
|
6756
|
-
}
|
|
6757
|
-
if ((tag & 7) === 4 || tag === 0) {
|
|
6758
|
-
break;
|
|
6759
|
-
}
|
|
6760
|
-
reader.skipType(tag & 7);
|
|
6761
|
-
}
|
|
6762
|
-
return message;
|
|
6763
|
-
},
|
|
6764
|
-
fromJSON(object) {
|
|
6765
|
-
return { siblings: isSet8(object.siblings) ? bytesFromBase643(object.siblings) : new Uint8Array(0) };
|
|
6766
|
-
},
|
|
6767
|
-
toJSON(message) {
|
|
6768
|
-
const obj = {};
|
|
6769
|
-
if (message.siblings.length !== 0) {
|
|
6770
|
-
obj.siblings = base64FromBytes3(message.siblings);
|
|
6771
|
-
}
|
|
6772
|
-
return obj;
|
|
6773
|
-
},
|
|
6774
|
-
create(base) {
|
|
6775
|
-
return ProofIden3.fromPartial(base ?? {});
|
|
6776
|
-
},
|
|
6777
|
-
fromPartial(object) {
|
|
6778
|
-
const message = createBaseProofIden3();
|
|
6779
|
-
message.siblings = object.siblings ?? new Uint8Array(0);
|
|
6780
|
-
return message;
|
|
6781
|
-
}
|
|
6782
|
-
};
|
|
6783
6660
|
function createBaseProofEthereumStorage() {
|
|
6784
6661
|
return { key: new Uint8Array(0), value: new Uint8Array(0), siblings: [] };
|
|
6785
6662
|
}
|
|
@@ -6833,7 +6710,7 @@ var ProofEthereumStorage = {
|
|
|
6833
6710
|
return {
|
|
6834
6711
|
key: isSet8(object.key) ? bytesFromBase643(object.key) : new Uint8Array(0),
|
|
6835
6712
|
value: isSet8(object.value) ? bytesFromBase643(object.value) : new Uint8Array(0),
|
|
6836
|
-
siblings: Array.isArray(object?.siblings) ? object.siblings.map((e) => bytesFromBase643(e)) : []
|
|
6713
|
+
siblings: globalThis.Array.isArray(object?.siblings) ? object.siblings.map((e) => bytesFromBase643(e)) : []
|
|
6837
6714
|
};
|
|
6838
6715
|
},
|
|
6839
6716
|
toJSON(message) {
|
|
@@ -6939,7 +6816,7 @@ var ProofEthereumAccount = {
|
|
|
6939
6816
|
balance: isSet8(object.balance) ? bytesFromBase643(object.balance) : new Uint8Array(0),
|
|
6940
6817
|
storageHash: isSet8(object.storageHash) ? bytesFromBase643(object.storageHash) : new Uint8Array(0),
|
|
6941
6818
|
codeHash: isSet8(object.codeHash) ? bytesFromBase643(object.codeHash) : new Uint8Array(0),
|
|
6942
|
-
siblings: Array.isArray(object?.siblings) ? object.siblings.map((e) => bytesFromBase643(e)) : []
|
|
6819
|
+
siblings: globalThis.Array.isArray(object?.siblings) ? object.siblings.map((e) => bytesFromBase643(e)) : []
|
|
6943
6820
|
};
|
|
6944
6821
|
},
|
|
6945
6822
|
toJSON(message) {
|
|
@@ -7369,11 +7246,11 @@ var ProofZkSNARK = {
|
|
|
7369
7246
|
},
|
|
7370
7247
|
fromJSON(object) {
|
|
7371
7248
|
return {
|
|
7372
|
-
circuitParametersIndex: isSet8(object.circuitParametersIndex) ? Number(object.circuitParametersIndex) : 0,
|
|
7373
|
-
a: Array.isArray(object?.a) ? object.a.map((e) => String(e)) : [],
|
|
7374
|
-
b: Array.isArray(object?.b) ? object.b.map((e) => String(e)) : [],
|
|
7375
|
-
c: Array.isArray(object?.c) ? object.c.map((e) => String(e)) : [],
|
|
7376
|
-
publicInputs: Array.isArray(object?.publicInputs) ? object.publicInputs.map((e) => String(e)) : []
|
|
7249
|
+
circuitParametersIndex: isSet8(object.circuitParametersIndex) ? globalThis.Number(object.circuitParametersIndex) : 0,
|
|
7250
|
+
a: globalThis.Array.isArray(object?.a) ? object.a.map((e) => globalThis.String(e)) : [],
|
|
7251
|
+
b: globalThis.Array.isArray(object?.b) ? object.b.map((e) => globalThis.String(e)) : [],
|
|
7252
|
+
c: globalThis.Array.isArray(object?.c) ? object.c.map((e) => globalThis.String(e)) : [],
|
|
7253
|
+
publicInputs: globalThis.Array.isArray(object?.publicInputs) ? object.publicInputs.map((e) => globalThis.String(e)) : []
|
|
7377
7254
|
};
|
|
7378
7255
|
},
|
|
7379
7256
|
toJSON(message) {
|
|
@@ -7477,11 +7354,11 @@ var Account2 = {
|
|
|
7477
7354
|
},
|
|
7478
7355
|
fromJSON(object) {
|
|
7479
7356
|
return {
|
|
7480
|
-
balance: isSet8(object.balance) ? Number(object.balance) : 0,
|
|
7481
|
-
nonce: isSet8(object.nonce) ? Number(object.nonce) : 0,
|
|
7482
|
-
infoURI: isSet8(object.infoURI) ? String(object.infoURI) : "",
|
|
7483
|
-
delegateAddrs: Array.isArray(object?.delegateAddrs) ? object.delegateAddrs.map((e) => bytesFromBase643(e)) : [],
|
|
7484
|
-
processIndex: isSet8(object.processIndex) ? Number(object.processIndex) : 0
|
|
7357
|
+
balance: isSet8(object.balance) ? globalThis.Number(object.balance) : 0,
|
|
7358
|
+
nonce: isSet8(object.nonce) ? globalThis.Number(object.nonce) : 0,
|
|
7359
|
+
infoURI: isSet8(object.infoURI) ? globalThis.String(object.infoURI) : "",
|
|
7360
|
+
delegateAddrs: globalThis.Array.isArray(object?.delegateAddrs) ? object.delegateAddrs.map((e) => bytesFromBase643(e)) : [],
|
|
7361
|
+
processIndex: isSet8(object.processIndex) ? globalThis.Number(object.processIndex) : 0
|
|
7485
7362
|
};
|
|
7486
7363
|
},
|
|
7487
7364
|
toJSON(message) {
|
|
@@ -7516,72 +7393,6 @@ var Account2 = {
|
|
|
7516
7393
|
return message;
|
|
7517
7394
|
}
|
|
7518
7395
|
};
|
|
7519
|
-
function createBaseTreasurer() {
|
|
7520
|
-
return { address: new Uint8Array(0), nonce: 0 };
|
|
7521
|
-
}
|
|
7522
|
-
var Treasurer = {
|
|
7523
|
-
encode(message, writer = import_minimal8.default.Writer.create()) {
|
|
7524
|
-
if (message.address.length !== 0) {
|
|
7525
|
-
writer.uint32(10).bytes(message.address);
|
|
7526
|
-
}
|
|
7527
|
-
if (message.nonce !== 0) {
|
|
7528
|
-
writer.uint32(16).uint32(message.nonce);
|
|
7529
|
-
}
|
|
7530
|
-
return writer;
|
|
7531
|
-
},
|
|
7532
|
-
decode(input, length) {
|
|
7533
|
-
const reader = input instanceof import_minimal8.default.Reader ? input : import_minimal8.default.Reader.create(input);
|
|
7534
|
-
let end = length === void 0 ? reader.len : reader.pos + length;
|
|
7535
|
-
const message = createBaseTreasurer();
|
|
7536
|
-
while (reader.pos < end) {
|
|
7537
|
-
const tag = reader.uint32();
|
|
7538
|
-
switch (tag >>> 3) {
|
|
7539
|
-
case 1:
|
|
7540
|
-
if (tag !== 10) {
|
|
7541
|
-
break;
|
|
7542
|
-
}
|
|
7543
|
-
message.address = reader.bytes();
|
|
7544
|
-
continue;
|
|
7545
|
-
case 2:
|
|
7546
|
-
if (tag !== 16) {
|
|
7547
|
-
break;
|
|
7548
|
-
}
|
|
7549
|
-
message.nonce = reader.uint32();
|
|
7550
|
-
continue;
|
|
7551
|
-
}
|
|
7552
|
-
if ((tag & 7) === 4 || tag === 0) {
|
|
7553
|
-
break;
|
|
7554
|
-
}
|
|
7555
|
-
reader.skipType(tag & 7);
|
|
7556
|
-
}
|
|
7557
|
-
return message;
|
|
7558
|
-
},
|
|
7559
|
-
fromJSON(object) {
|
|
7560
|
-
return {
|
|
7561
|
-
address: isSet8(object.address) ? bytesFromBase643(object.address) : new Uint8Array(0),
|
|
7562
|
-
nonce: isSet8(object.nonce) ? Number(object.nonce) : 0
|
|
7563
|
-
};
|
|
7564
|
-
},
|
|
7565
|
-
toJSON(message) {
|
|
7566
|
-
const obj = {};
|
|
7567
|
-
if (message.address.length !== 0) {
|
|
7568
|
-
obj.address = base64FromBytes3(message.address);
|
|
7569
|
-
}
|
|
7570
|
-
if (message.nonce !== 0) {
|
|
7571
|
-
obj.nonce = Math.round(message.nonce);
|
|
7572
|
-
}
|
|
7573
|
-
return obj;
|
|
7574
|
-
},
|
|
7575
|
-
create(base) {
|
|
7576
|
-
return Treasurer.fromPartial(base ?? {});
|
|
7577
|
-
},
|
|
7578
|
-
fromPartial(object) {
|
|
7579
|
-
const message = createBaseTreasurer();
|
|
7580
|
-
message.address = object.address ?? new Uint8Array(0);
|
|
7581
|
-
message.nonce = object.nonce ?? 0;
|
|
7582
|
-
return message;
|
|
7583
|
-
}
|
|
7584
|
-
};
|
|
7585
7396
|
function createBaseTx() {
|
|
7586
7397
|
return { payload: void 0 };
|
|
7587
7398
|
}
|
|
@@ -7603,9 +7414,6 @@ var Tx = {
|
|
|
7603
7414
|
case "registerKey":
|
|
7604
7415
|
RegisterKeyTx.encode(message.payload.registerKey, writer.uint32(42).fork()).ldelim();
|
|
7605
7416
|
break;
|
|
7606
|
-
case "mintTokens":
|
|
7607
|
-
MintTokensTx.encode(message.payload.mintTokens, writer.uint32(50).fork()).ldelim();
|
|
7608
|
-
break;
|
|
7609
7417
|
case "sendTokens":
|
|
7610
7418
|
SendTokensTx.encode(message.payload.sendTokens, writer.uint32(58).fork()).ldelim();
|
|
7611
7419
|
break;
|
|
@@ -7670,12 +7478,6 @@ var Tx = {
|
|
|
7670
7478
|
}
|
|
7671
7479
|
message.payload = { $case: "registerKey", registerKey: RegisterKeyTx.decode(reader, reader.uint32()) };
|
|
7672
7480
|
continue;
|
|
7673
|
-
case 6:
|
|
7674
|
-
if (tag !== 50) {
|
|
7675
|
-
break;
|
|
7676
|
-
}
|
|
7677
|
-
message.payload = { $case: "mintTokens", mintTokens: MintTokensTx.decode(reader, reader.uint32()) };
|
|
7678
|
-
continue;
|
|
7679
7481
|
case 7:
|
|
7680
7482
|
if (tag !== 58) {
|
|
7681
7483
|
break;
|
|
@@ -7737,7 +7539,7 @@ var Tx = {
|
|
|
7737
7539
|
},
|
|
7738
7540
|
fromJSON(object) {
|
|
7739
7541
|
return {
|
|
7740
|
-
payload: isSet8(object.vote) ? { $case: "vote", vote: VoteEnvelope.fromJSON(object.vote) } : isSet8(object.newProcess) ? { $case: "newProcess", newProcess: NewProcessTx.fromJSON(object.newProcess) } : isSet8(object.admin) ? { $case: "admin", admin: AdminTx.fromJSON(object.admin) } : isSet8(object.setProcess) ? { $case: "setProcess", setProcess: SetProcessTx.fromJSON(object.setProcess) } : isSet8(object.registerKey) ? { $case: "registerKey", registerKey: RegisterKeyTx.fromJSON(object.registerKey) } : isSet8(object.
|
|
7542
|
+
payload: isSet8(object.vote) ? { $case: "vote", vote: VoteEnvelope.fromJSON(object.vote) } : isSet8(object.newProcess) ? { $case: "newProcess", newProcess: NewProcessTx.fromJSON(object.newProcess) } : isSet8(object.admin) ? { $case: "admin", admin: AdminTx.fromJSON(object.admin) } : isSet8(object.setProcess) ? { $case: "setProcess", setProcess: SetProcessTx.fromJSON(object.setProcess) } : isSet8(object.registerKey) ? { $case: "registerKey", registerKey: RegisterKeyTx.fromJSON(object.registerKey) } : isSet8(object.sendTokens) ? { $case: "sendTokens", sendTokens: SendTokensTx.fromJSON(object.sendTokens) } : isSet8(object.setTransactionCosts) ? {
|
|
7741
7543
|
$case: "setTransactionCosts",
|
|
7742
7544
|
setTransactionCosts: SetTransactionCostsTx.fromJSON(object.setTransactionCosts)
|
|
7743
7545
|
} : isSet8(object.setAccount) ? { $case: "setAccount", setAccount: SetAccountTx.fromJSON(object.setAccount) } : isSet8(object.collectFaucet) ? { $case: "collectFaucet", collectFaucet: CollectFaucetTx.fromJSON(object.collectFaucet) } : isSet8(object.setKeykeeper) ? { $case: "setKeykeeper", setKeykeeper: SetKeykeeperTx.fromJSON(object.setKeykeeper) } : isSet8(object.setSIK) ? { $case: "setSIK", setSIK: SIKTx.fromJSON(object.setSIK) } : isSet8(object.delSIK) ? { $case: "delSIK", delSIK: SIKTx.fromJSON(object.delSIK) } : isSet8(object.registerSIK) ? { $case: "registerSIK", registerSIK: RegisterSIKTx.fromJSON(object.registerSIK) } : void 0
|
|
@@ -7760,9 +7562,6 @@ var Tx = {
|
|
|
7760
7562
|
if (message.payload?.$case === "registerKey") {
|
|
7761
7563
|
obj.registerKey = RegisterKeyTx.toJSON(message.payload.registerKey);
|
|
7762
7564
|
}
|
|
7763
|
-
if (message.payload?.$case === "mintTokens") {
|
|
7764
|
-
obj.mintTokens = MintTokensTx.toJSON(message.payload.mintTokens);
|
|
7765
|
-
}
|
|
7766
7565
|
if (message.payload?.$case === "sendTokens") {
|
|
7767
7566
|
obj.sendTokens = SendTokensTx.toJSON(message.payload.sendTokens);
|
|
7768
7567
|
}
|
|
@@ -7809,9 +7608,6 @@ var Tx = {
|
|
|
7809
7608
|
if (object.payload?.$case === "registerKey" && object.payload?.registerKey !== void 0 && object.payload?.registerKey !== null) {
|
|
7810
7609
|
message.payload = { $case: "registerKey", registerKey: RegisterKeyTx.fromPartial(object.payload.registerKey) };
|
|
7811
7610
|
}
|
|
7812
|
-
if (object.payload?.$case === "mintTokens" && object.payload?.mintTokens !== void 0 && object.payload?.mintTokens !== null) {
|
|
7813
|
-
message.payload = { $case: "mintTokens", mintTokens: MintTokensTx.fromPartial(object.payload.mintTokens) };
|
|
7814
|
-
}
|
|
7815
7611
|
if (object.payload?.$case === "sendTokens" && object.payload?.sendTokens !== void 0 && object.payload?.sendTokens !== null) {
|
|
7816
7612
|
message.payload = { $case: "sendTokens", sendTokens: SendTokensTx.fromPartial(object.payload.sendTokens) };
|
|
7817
7613
|
}
|
|
@@ -7966,7 +7762,7 @@ var NewProcessTx = {
|
|
|
7966
7762
|
fromJSON(object) {
|
|
7967
7763
|
return {
|
|
7968
7764
|
txtype: isSet8(object.txtype) ? txTypeFromJSON(object.txtype) : 0,
|
|
7969
|
-
nonce: isSet8(object.nonce) ? Number(object.nonce) : 0,
|
|
7765
|
+
nonce: isSet8(object.nonce) ? globalThis.Number(object.nonce) : 0,
|
|
7970
7766
|
process: isSet8(object.process) ? Process.fromJSON(object.process) : void 0
|
|
7971
7767
|
};
|
|
7972
7768
|
},
|
|
@@ -8120,15 +7916,15 @@ var SetProcessTx = {
|
|
|
8120
7916
|
fromJSON(object) {
|
|
8121
7917
|
return {
|
|
8122
7918
|
txtype: isSet8(object.txtype) ? txTypeFromJSON(object.txtype) : 0,
|
|
8123
|
-
nonce: isSet8(object.nonce) ? Number(object.nonce) : 0,
|
|
7919
|
+
nonce: isSet8(object.nonce) ? globalThis.Number(object.nonce) : 0,
|
|
8124
7920
|
processId: isSet8(object.processId) ? bytesFromBase643(object.processId) : new Uint8Array(0),
|
|
8125
7921
|
status: isSet8(object.status) ? processStatusFromJSON(object.status) : void 0,
|
|
8126
|
-
questionIndex: isSet8(object.questionIndex) ? Number(object.questionIndex) : void 0,
|
|
7922
|
+
questionIndex: isSet8(object.questionIndex) ? globalThis.Number(object.questionIndex) : void 0,
|
|
8127
7923
|
censusRoot: isSet8(object.censusRoot) ? bytesFromBase643(object.censusRoot) : void 0,
|
|
8128
|
-
censusURI: isSet8(object.censusURI) ? String(object.censusURI) : void 0,
|
|
7924
|
+
censusURI: isSet8(object.censusURI) ? globalThis.String(object.censusURI) : void 0,
|
|
8129
7925
|
proof: isSet8(object.proof) ? Proof.fromJSON(object.proof) : void 0,
|
|
8130
7926
|
results: isSet8(object.results) ? ProcessResult.fromJSON(object.results) : void 0,
|
|
8131
|
-
tempSIKs: isSet8(object.tempSIKs) ? Boolean(object.tempSIKs) : void 0
|
|
7927
|
+
tempSIKs: isSet8(object.tempSIKs) ? globalThis.Boolean(object.tempSIKs) : void 0
|
|
8132
7928
|
};
|
|
8133
7929
|
},
|
|
8134
7930
|
toJSON(message) {
|
|
@@ -8303,10 +8099,10 @@ var AdminTx = {
|
|
|
8303
8099
|
address: isSet8(object.address) ? bytesFromBase643(object.address) : void 0,
|
|
8304
8100
|
encryptionPrivateKey: isSet8(object.encryptionPrivateKey) ? bytesFromBase643(object.encryptionPrivateKey) : void 0,
|
|
8305
8101
|
encryptionPublicKey: isSet8(object.encryptionPublicKey) ? bytesFromBase643(object.encryptionPublicKey) : void 0,
|
|
8306
|
-
keyIndex: isSet8(object.keyIndex) ? Number(object.keyIndex) : void 0,
|
|
8307
|
-
power: isSet8(object.power) ? Number(object.power) : void 0,
|
|
8102
|
+
keyIndex: isSet8(object.keyIndex) ? globalThis.Number(object.keyIndex) : void 0,
|
|
8103
|
+
power: isSet8(object.power) ? globalThis.Number(object.power) : void 0,
|
|
8308
8104
|
publicKey: isSet8(object.publicKey) ? bytesFromBase643(object.publicKey) : void 0,
|
|
8309
|
-
nonce: isSet8(object.nonce) ? Number(object.nonce) : 0
|
|
8105
|
+
nonce: isSet8(object.nonce) ? globalThis.Number(object.nonce) : 0
|
|
8310
8106
|
};
|
|
8311
8107
|
},
|
|
8312
8108
|
toJSON(message) {
|
|
@@ -8426,11 +8222,11 @@ var RegisterKeyTx = {
|
|
|
8426
8222
|
},
|
|
8427
8223
|
fromJSON(object) {
|
|
8428
8224
|
return {
|
|
8429
|
-
nonce: isSet8(object.nonce) ? Number(object.nonce) : 0,
|
|
8225
|
+
nonce: isSet8(object.nonce) ? globalThis.Number(object.nonce) : 0,
|
|
8430
8226
|
processId: isSet8(object.processId) ? bytesFromBase643(object.processId) : new Uint8Array(0),
|
|
8431
8227
|
proof: isSet8(object.proof) ? Proof.fromJSON(object.proof) : void 0,
|
|
8432
8228
|
newKey: isSet8(object.newKey) ? bytesFromBase643(object.newKey) : new Uint8Array(0),
|
|
8433
|
-
weight: isSet8(object.weight) ? String(object.weight) : ""
|
|
8229
|
+
weight: isSet8(object.weight) ? globalThis.String(object.weight) : ""
|
|
8434
8230
|
};
|
|
8435
8231
|
},
|
|
8436
8232
|
toJSON(message) {
|
|
@@ -8465,100 +8261,6 @@ var RegisterKeyTx = {
|
|
|
8465
8261
|
return message;
|
|
8466
8262
|
}
|
|
8467
8263
|
};
|
|
8468
|
-
function createBaseMintTokensTx() {
|
|
8469
|
-
return { txtype: 0, nonce: 0, to: new Uint8Array(0), value: 0 };
|
|
8470
|
-
}
|
|
8471
|
-
var MintTokensTx = {
|
|
8472
|
-
encode(message, writer = import_minimal8.default.Writer.create()) {
|
|
8473
|
-
if (message.txtype !== 0) {
|
|
8474
|
-
writer.uint32(8).int32(message.txtype);
|
|
8475
|
-
}
|
|
8476
|
-
if (message.nonce !== 0) {
|
|
8477
|
-
writer.uint32(16).uint32(message.nonce);
|
|
8478
|
-
}
|
|
8479
|
-
if (message.to.length !== 0) {
|
|
8480
|
-
writer.uint32(26).bytes(message.to);
|
|
8481
|
-
}
|
|
8482
|
-
if (message.value !== 0) {
|
|
8483
|
-
writer.uint32(32).uint64(message.value);
|
|
8484
|
-
}
|
|
8485
|
-
return writer;
|
|
8486
|
-
},
|
|
8487
|
-
decode(input, length) {
|
|
8488
|
-
const reader = input instanceof import_minimal8.default.Reader ? input : import_minimal8.default.Reader.create(input);
|
|
8489
|
-
let end = length === void 0 ? reader.len : reader.pos + length;
|
|
8490
|
-
const message = createBaseMintTokensTx();
|
|
8491
|
-
while (reader.pos < end) {
|
|
8492
|
-
const tag = reader.uint32();
|
|
8493
|
-
switch (tag >>> 3) {
|
|
8494
|
-
case 1:
|
|
8495
|
-
if (tag !== 8) {
|
|
8496
|
-
break;
|
|
8497
|
-
}
|
|
8498
|
-
message.txtype = reader.int32();
|
|
8499
|
-
continue;
|
|
8500
|
-
case 2:
|
|
8501
|
-
if (tag !== 16) {
|
|
8502
|
-
break;
|
|
8503
|
-
}
|
|
8504
|
-
message.nonce = reader.uint32();
|
|
8505
|
-
continue;
|
|
8506
|
-
case 3:
|
|
8507
|
-
if (tag !== 26) {
|
|
8508
|
-
break;
|
|
8509
|
-
}
|
|
8510
|
-
message.to = reader.bytes();
|
|
8511
|
-
continue;
|
|
8512
|
-
case 4:
|
|
8513
|
-
if (tag !== 32) {
|
|
8514
|
-
break;
|
|
8515
|
-
}
|
|
8516
|
-
message.value = longToNumber2(reader.uint64());
|
|
8517
|
-
continue;
|
|
8518
|
-
}
|
|
8519
|
-
if ((tag & 7) === 4 || tag === 0) {
|
|
8520
|
-
break;
|
|
8521
|
-
}
|
|
8522
|
-
reader.skipType(tag & 7);
|
|
8523
|
-
}
|
|
8524
|
-
return message;
|
|
8525
|
-
},
|
|
8526
|
-
fromJSON(object) {
|
|
8527
|
-
return {
|
|
8528
|
-
txtype: isSet8(object.txtype) ? txTypeFromJSON(object.txtype) : 0,
|
|
8529
|
-
nonce: isSet8(object.nonce) ? Number(object.nonce) : 0,
|
|
8530
|
-
to: isSet8(object.to) ? bytesFromBase643(object.to) : new Uint8Array(0),
|
|
8531
|
-
value: isSet8(object.value) ? Number(object.value) : 0
|
|
8532
|
-
};
|
|
8533
|
-
},
|
|
8534
|
-
toJSON(message) {
|
|
8535
|
-
const obj = {};
|
|
8536
|
-
if (message.txtype !== 0) {
|
|
8537
|
-
obj.txtype = txTypeToJSON(message.txtype);
|
|
8538
|
-
}
|
|
8539
|
-
if (message.nonce !== 0) {
|
|
8540
|
-
obj.nonce = Math.round(message.nonce);
|
|
8541
|
-
}
|
|
8542
|
-
if (message.to.length !== 0) {
|
|
8543
|
-
obj.to = base64FromBytes3(message.to);
|
|
8544
|
-
}
|
|
8545
|
-
if (message.value !== 0) {
|
|
8546
|
-
obj.value = Math.round(message.value);
|
|
8547
|
-
}
|
|
8548
|
-
return obj;
|
|
8549
|
-
},
|
|
8550
|
-
create(base) {
|
|
8551
|
-
return MintTokensTx.fromPartial(base ?? {});
|
|
8552
|
-
},
|
|
8553
|
-
fromPartial(object) {
|
|
8554
|
-
const message = createBaseMintTokensTx();
|
|
8555
|
-
message.txtype = object.txtype ?? 0;
|
|
8556
|
-
message.nonce = object.nonce ?? 0;
|
|
8557
|
-
message.to = object.to ?? new Uint8Array(0);
|
|
8558
|
-
message.value = object.value ?? 0;
|
|
8559
|
-
return message;
|
|
8560
|
-
}
|
|
8561
|
-
};
|
|
8562
8264
|
function createBaseSendTokensTx() {
|
|
8563
8265
|
return { txtype: 0, nonce: 0, from: new Uint8Array(0), to: new Uint8Array(0), value: 0 };
|
|
8564
8266
|
}
|
|
@@ -8629,10 +8331,10 @@ var SendTokensTx = {
|
|
|
8629
8331
|
fromJSON(object) {
|
|
8630
8332
|
return {
|
|
8631
8333
|
txtype: isSet8(object.txtype) ? txTypeFromJSON(object.txtype) : 0,
|
|
8632
|
-
nonce: isSet8(object.nonce) ? Number(object.nonce) : 0,
|
|
8334
|
+
nonce: isSet8(object.nonce) ? globalThis.Number(object.nonce) : 0,
|
|
8633
8335
|
from: isSet8(object.from) ? bytesFromBase643(object.from) : new Uint8Array(0),
|
|
8634
8336
|
to: isSet8(object.to) ? bytesFromBase643(object.to) : new Uint8Array(0),
|
|
8635
|
-
value: isSet8(object.value) ? Number(object.value) : 0
|
|
8337
|
+
value: isSet8(object.value) ? globalThis.Number(object.value) : 0
|
|
8636
8338
|
};
|
|
8637
8339
|
},
|
|
8638
8340
|
toJSON(message) {
|
|
@@ -8719,8 +8421,8 @@ var SetTransactionCostsTx = {
|
|
|
8719
8421
|
fromJSON(object) {
|
|
8720
8422
|
return {
|
|
8721
8423
|
txtype: isSet8(object.txtype) ? txTypeFromJSON(object.txtype) : 0,
|
|
8722
|
-
nonce: isSet8(object.nonce) ? Number(object.nonce) : 0,
|
|
8723
|
-
value: isSet8(object.value) ? Number(object.value) : 0
|
|
8424
|
+
nonce: isSet8(object.nonce) ? globalThis.Number(object.nonce) : 0,
|
|
8425
|
+
value: isSet8(object.value) ? globalThis.Number(object.value) : 0
|
|
8724
8426
|
};
|
|
8725
8427
|
},
|
|
8726
8428
|
toJSON(message) {
|
|
@@ -8755,7 +8457,9 @@ function createBaseSetAccountTx() {
|
|
|
8755
8457
|
account: void 0,
|
|
8756
8458
|
faucetPackage: void 0,
|
|
8757
8459
|
delegates: [],
|
|
8758
|
-
SIK: void 0
|
|
8460
|
+
SIK: void 0,
|
|
8461
|
+
publicKey: void 0,
|
|
8462
|
+
name: void 0
|
|
8759
8463
|
};
|
|
8760
8464
|
}
|
|
8761
8465
|
var SetAccountTx = {
|
|
@@ -8781,6 +8485,12 @@ var SetAccountTx = {
|
|
|
8781
8485
|
if (message.SIK !== void 0) {
|
|
8782
8486
|
writer.uint32(58).bytes(message.SIK);
|
|
8783
8487
|
}
|
|
8488
|
+
if (message.publicKey !== void 0) {
|
|
8489
|
+
writer.uint32(66).bytes(message.publicKey);
|
|
8490
|
+
}
|
|
8491
|
+
if (message.name !== void 0) {
|
|
8492
|
+
writer.uint32(74).string(message.name);
|
|
8493
|
+
}
|
|
8784
8494
|
return writer;
|
|
8785
8495
|
},
|
|
8786
8496
|
decode(input, length) {
|
|
@@ -8832,6 +8542,18 @@ var SetAccountTx = {
|
|
|
8832
8542
|
}
|
|
8833
8543
|
message.SIK = reader.bytes();
|
|
8834
8544
|
continue;
|
|
8545
|
+
case 8:
|
|
8546
|
+
if (tag !== 66) {
|
|
8547
|
+
break;
|
|
8548
|
+
}
|
|
8549
|
+
message.publicKey = reader.bytes();
|
|
8550
|
+
continue;
|
|
8551
|
+
case 9:
|
|
8552
|
+
if (tag !== 74) {
|
|
8553
|
+
break;
|
|
8554
|
+
}
|
|
8555
|
+
message.name = reader.string();
|
|
8556
|
+
continue;
|
|
8835
8557
|
}
|
|
8836
8558
|
if ((tag & 7) === 4 || tag === 0) {
|
|
8837
8559
|
break;
|
|
@@ -8843,12 +8565,14 @@ var SetAccountTx = {
|
|
|
8843
8565
|
fromJSON(object) {
|
|
8844
8566
|
return {
|
|
8845
8567
|
txtype: isSet8(object.txtype) ? txTypeFromJSON(object.txtype) : 0,
|
|
8846
|
-
nonce: isSet8(object.nonce) ? Number(object.nonce) : void 0,
|
|
8847
|
-
infoURI: isSet8(object.infoURI) ? String(object.infoURI) : void 0,
|
|
8568
|
+
nonce: isSet8(object.nonce) ? globalThis.Number(object.nonce) : void 0,
|
|
8569
|
+
infoURI: isSet8(object.infoURI) ? globalThis.String(object.infoURI) : void 0,
|
|
8848
8570
|
account: isSet8(object.account) ? bytesFromBase643(object.account) : void 0,
|
|
8849
8571
|
faucetPackage: isSet8(object.faucetPackage) ? FaucetPackage.fromJSON(object.faucetPackage) : void 0,
|
|
8850
|
-
delegates: Array.isArray(object?.delegates) ? object.delegates.map((e) => bytesFromBase643(e)) : [],
|
|
8851
|
-
SIK: isSet8(object.SIK) ? bytesFromBase643(object.SIK) : void 0
|
|
8572
|
+
delegates: globalThis.Array.isArray(object?.delegates) ? object.delegates.map((e) => bytesFromBase643(e)) : [],
|
|
8573
|
+
SIK: isSet8(object.SIK) ? bytesFromBase643(object.SIK) : void 0,
|
|
8574
|
+
publicKey: isSet8(object.publicKey) ? bytesFromBase643(object.publicKey) : void 0,
|
|
8575
|
+
name: isSet8(object.name) ? globalThis.String(object.name) : void 0
|
|
8852
8576
|
};
|
|
8853
8577
|
},
|
|
8854
8578
|
toJSON(message) {
|
|
@@ -8874,6 +8598,12 @@ var SetAccountTx = {
|
|
|
8874
8598
|
if (message.SIK !== void 0) {
|
|
8875
8599
|
obj.SIK = base64FromBytes3(message.SIK);
|
|
8876
8600
|
}
|
|
8601
|
+
if (message.publicKey !== void 0) {
|
|
8602
|
+
obj.publicKey = base64FromBytes3(message.publicKey);
|
|
8603
|
+
}
|
|
8604
|
+
if (message.name !== void 0) {
|
|
8605
|
+
obj.name = message.name;
|
|
8606
|
+
}
|
|
8877
8607
|
return obj;
|
|
8878
8608
|
},
|
|
8879
8609
|
create(base) {
|
|
@@ -8888,17 +8618,22 @@ var SetAccountTx = {
|
|
|
8888
8618
|
message.faucetPackage = object.faucetPackage !== void 0 && object.faucetPackage !== null ? FaucetPackage.fromPartial(object.faucetPackage) : void 0;
|
|
8889
8619
|
message.delegates = object.delegates?.map((e) => e) || [];
|
|
8890
8620
|
message.SIK = object.SIK ?? void 0;
|
|
8621
|
+
message.publicKey = object.publicKey ?? void 0;
|
|
8622
|
+
message.name = object.name ?? void 0;
|
|
8891
8623
|
return message;
|
|
8892
8624
|
}
|
|
8893
8625
|
};
|
|
8894
8626
|
function createBaseSIKTx() {
|
|
8895
|
-
return { txtype: 0, SIK: void 0 };
|
|
8627
|
+
return { txtype: 0, nonce: void 0, SIK: void 0 };
|
|
8896
8628
|
}
|
|
8897
8629
|
var SIKTx = {
|
|
8898
8630
|
encode(message, writer = import_minimal8.default.Writer.create()) {
|
|
8899
8631
|
if (message.txtype !== 0) {
|
|
8900
8632
|
writer.uint32(8).int32(message.txtype);
|
|
8901
8633
|
}
|
|
8634
|
+
if (message.nonce !== void 0) {
|
|
8635
|
+
writer.uint32(16).uint32(message.nonce);
|
|
8636
|
+
}
|
|
8902
8637
|
if (message.SIK !== void 0) {
|
|
8903
8638
|
writer.uint32(26).bytes(message.SIK);
|
|
8904
8639
|
}
|
|
@@ -8917,6 +8652,12 @@ var SIKTx = {
|
|
|
8917
8652
|
}
|
|
8918
8653
|
message.txtype = reader.int32();
|
|
8919
8654
|
continue;
|
|
8655
|
+
case 2:
|
|
8656
|
+
if (tag !== 16) {
|
|
8657
|
+
break;
|
|
8658
|
+
}
|
|
8659
|
+
message.nonce = reader.uint32();
|
|
8660
|
+
continue;
|
|
8920
8661
|
case 3:
|
|
8921
8662
|
if (tag !== 26) {
|
|
8922
8663
|
break;
|
|
@@ -8934,6 +8675,7 @@ var SIKTx = {
|
|
|
8934
8675
|
fromJSON(object) {
|
|
8935
8676
|
return {
|
|
8936
8677
|
txtype: isSet8(object.txtype) ? txTypeFromJSON(object.txtype) : 0,
|
|
8678
|
+
nonce: isSet8(object.nonce) ? globalThis.Number(object.nonce) : void 0,
|
|
8937
8679
|
SIK: isSet8(object.SIK) ? bytesFromBase643(object.SIK) : void 0
|
|
8938
8680
|
};
|
|
8939
8681
|
},
|
|
@@ -8942,6 +8684,9 @@ var SIKTx = {
|
|
|
8942
8684
|
if (message.txtype !== 0) {
|
|
8943
8685
|
obj.txtype = txTypeToJSON(message.txtype);
|
|
8944
8686
|
}
|
|
8687
|
+
if (message.nonce !== void 0) {
|
|
8688
|
+
obj.nonce = Math.round(message.nonce);
|
|
8689
|
+
}
|
|
8945
8690
|
if (message.SIK !== void 0) {
|
|
8946
8691
|
obj.SIK = base64FromBytes3(message.SIK);
|
|
8947
8692
|
}
|
|
@@ -8953,6 +8698,7 @@ var SIKTx = {
|
|
|
8953
8698
|
fromPartial(object) {
|
|
8954
8699
|
const message = createBaseSIKTx();
|
|
8955
8700
|
message.txtype = object.txtype ?? 0;
|
|
8701
|
+
message.nonce = object.nonce ?? void 0;
|
|
8956
8702
|
message.SIK = object.SIK ?? void 0;
|
|
8957
8703
|
return message;
|
|
8958
8704
|
}
|
|
@@ -9090,7 +8836,7 @@ var CollectFaucetTx = {
|
|
|
9090
8836
|
return {
|
|
9091
8837
|
txType: isSet8(object.txType) ? txTypeFromJSON(object.txType) : 0,
|
|
9092
8838
|
faucetPackage: isSet8(object.faucetPackage) ? FaucetPackage.fromJSON(object.faucetPackage) : void 0,
|
|
9093
|
-
nonce: isSet8(object.nonce) ? Number(object.nonce) : 0
|
|
8839
|
+
nonce: isSet8(object.nonce) ? globalThis.Number(object.nonce) : 0
|
|
9094
8840
|
};
|
|
9095
8841
|
},
|
|
9096
8842
|
toJSON(message) {
|
|
@@ -9168,9 +8914,9 @@ var FaucetPayload = {
|
|
|
9168
8914
|
},
|
|
9169
8915
|
fromJSON(object) {
|
|
9170
8916
|
return {
|
|
9171
|
-
identifier: isSet8(object.identifier) ? Number(object.identifier) : 0,
|
|
8917
|
+
identifier: isSet8(object.identifier) ? globalThis.Number(object.identifier) : 0,
|
|
9172
8918
|
to: isSet8(object.to) ? bytesFromBase643(object.to) : new Uint8Array(0),
|
|
9173
|
-
amount: isSet8(object.amount) ? Number(object.amount) : 0
|
|
8919
|
+
amount: isSet8(object.amount) ? globalThis.Number(object.amount) : 0
|
|
9174
8920
|
};
|
|
9175
8921
|
},
|
|
9176
8922
|
toJSON(message) {
|
|
@@ -9315,7 +9061,7 @@ var SetKeykeeperTx = {
|
|
|
9315
9061
|
fromJSON(object) {
|
|
9316
9062
|
return {
|
|
9317
9063
|
txtype: isSet8(object.txtype) ? txTypeFromJSON(object.txtype) : 0,
|
|
9318
|
-
nonce: isSet8(object.nonce) ? Number(object.nonce) : 0,
|
|
9064
|
+
nonce: isSet8(object.nonce) ? globalThis.Number(object.nonce) : 0,
|
|
9319
9065
|
keykeeper: isSet8(object.keykeeper) ? bytesFromBase643(object.keykeeper) : new Uint8Array(0)
|
|
9320
9066
|
};
|
|
9321
9067
|
},
|
|
@@ -9680,35 +9426,35 @@ var Process = {
|
|
|
9680
9426
|
return {
|
|
9681
9427
|
processId: isSet8(object.processId) ? bytesFromBase643(object.processId) : new Uint8Array(0),
|
|
9682
9428
|
entityId: isSet8(object.entityId) ? bytesFromBase643(object.entityId) : new Uint8Array(0),
|
|
9683
|
-
startBlock: isSet8(object.startBlock) ? Number(object.startBlock) : 0,
|
|
9684
|
-
blockCount: isSet8(object.blockCount) ? Number(object.blockCount) : 0,
|
|
9429
|
+
startBlock: isSet8(object.startBlock) ? globalThis.Number(object.startBlock) : 0,
|
|
9430
|
+
blockCount: isSet8(object.blockCount) ? globalThis.Number(object.blockCount) : 0,
|
|
9685
9431
|
censusRoot: isSet8(object.censusRoot) ? bytesFromBase643(object.censusRoot) : new Uint8Array(0),
|
|
9686
|
-
censusURI: isSet8(object.censusURI) ? String(object.censusURI) : void 0,
|
|
9687
|
-
encryptionPrivateKeys: Array.isArray(object?.encryptionPrivateKeys) ? object.encryptionPrivateKeys.map((e) => String(e)) : [],
|
|
9688
|
-
encryptionPublicKeys: Array.isArray(object?.encryptionPublicKeys) ? object.encryptionPublicKeys.map((e) => String(e)) : [],
|
|
9689
|
-
keyIndex: isSet8(object.keyIndex) ? Number(object.keyIndex) : void 0,
|
|
9432
|
+
censusURI: isSet8(object.censusURI) ? globalThis.String(object.censusURI) : void 0,
|
|
9433
|
+
encryptionPrivateKeys: globalThis.Array.isArray(object?.encryptionPrivateKeys) ? object.encryptionPrivateKeys.map((e) => globalThis.String(e)) : [],
|
|
9434
|
+
encryptionPublicKeys: globalThis.Array.isArray(object?.encryptionPublicKeys) ? object.encryptionPublicKeys.map((e) => globalThis.String(e)) : [],
|
|
9435
|
+
keyIndex: isSet8(object.keyIndex) ? globalThis.Number(object.keyIndex) : void 0,
|
|
9690
9436
|
status: isSet8(object.status) ? processStatusFromJSON(object.status) : 0,
|
|
9691
9437
|
paramsSignature: isSet8(object.paramsSignature) ? bytesFromBase643(object.paramsSignature) : void 0,
|
|
9692
|
-
namespace: isSet8(object.namespace) ? Number(object.namespace) : 0,
|
|
9438
|
+
namespace: isSet8(object.namespace) ? globalThis.Number(object.namespace) : 0,
|
|
9693
9439
|
envelopeType: isSet8(object.envelopeType) ? EnvelopeType.fromJSON(object.envelopeType) : void 0,
|
|
9694
9440
|
mode: isSet8(object.mode) ? ProcessMode.fromJSON(object.mode) : void 0,
|
|
9695
|
-
questionIndex: isSet8(object.questionIndex) ? Number(object.questionIndex) : void 0,
|
|
9696
|
-
questionCount: isSet8(object.questionCount) ? Number(object.questionCount) : void 0,
|
|
9441
|
+
questionIndex: isSet8(object.questionIndex) ? globalThis.Number(object.questionIndex) : void 0,
|
|
9442
|
+
questionCount: isSet8(object.questionCount) ? globalThis.Number(object.questionCount) : void 0,
|
|
9697
9443
|
voteOptions: isSet8(object.voteOptions) ? ProcessVoteOptions.fromJSON(object.voteOptions) : void 0,
|
|
9698
9444
|
censusOrigin: isSet8(object.censusOrigin) ? censusOriginFromJSON(object.censusOrigin) : 0,
|
|
9699
9445
|
results: isSet8(object.results) ? ProcessResult.fromJSON(object.results) : void 0,
|
|
9700
|
-
ethIndexSlot: isSet8(object.ethIndexSlot) ? Number(object.ethIndexSlot) : void 0,
|
|
9701
|
-
sourceBlockHeight: isSet8(object.sourceBlockHeight) ? Number(object.sourceBlockHeight) : void 0,
|
|
9446
|
+
ethIndexSlot: isSet8(object.ethIndexSlot) ? globalThis.Number(object.ethIndexSlot) : void 0,
|
|
9447
|
+
sourceBlockHeight: isSet8(object.sourceBlockHeight) ? globalThis.Number(object.sourceBlockHeight) : void 0,
|
|
9702
9448
|
owner: isSet8(object.owner) ? bytesFromBase643(object.owner) : void 0,
|
|
9703
|
-
metadata: isSet8(object.metadata) ? String(object.metadata) : void 0,
|
|
9449
|
+
metadata: isSet8(object.metadata) ? globalThis.String(object.metadata) : void 0,
|
|
9704
9450
|
sourceNetworkId: isSet8(object.sourceNetworkId) ? sourceNetworkIdFromJSON(object.sourceNetworkId) : 0,
|
|
9705
|
-
maxCensusSize: isSet8(object.maxCensusSize) ? Number(object.maxCensusSize) : 0,
|
|
9451
|
+
maxCensusSize: isSet8(object.maxCensusSize) ? globalThis.Number(object.maxCensusSize) : 0,
|
|
9706
9452
|
rollingCensusRoot: isSet8(object.rollingCensusRoot) ? bytesFromBase643(object.rollingCensusRoot) : void 0,
|
|
9707
|
-
rollingCensusSize: isSet8(object.rollingCensusSize) ? Number(object.rollingCensusSize) : void 0,
|
|
9453
|
+
rollingCensusSize: isSet8(object.rollingCensusSize) ? globalThis.Number(object.rollingCensusSize) : void 0,
|
|
9708
9454
|
nullifiersRoot: isSet8(object.nullifiersRoot) ? bytesFromBase643(object.nullifiersRoot) : void 0,
|
|
9709
9455
|
sourceNetworkContractAddr: isSet8(object.sourceNetworkContractAddr) ? bytesFromBase643(object.sourceNetworkContractAddr) : void 0,
|
|
9710
|
-
tokenDecimals: isSet8(object.tokenDecimals) ? Number(object.tokenDecimals) : void 0,
|
|
9711
|
-
tempSIKs: isSet8(object.tempSIKs) ? Boolean(object.tempSIKs) : void 0
|
|
9456
|
+
tokenDecimals: isSet8(object.tokenDecimals) ? globalThis.Number(object.tokenDecimals) : void 0,
|
|
9457
|
+
tempSIKs: isSet8(object.tempSIKs) ? globalThis.Boolean(object.tempSIKs) : void 0
|
|
9712
9458
|
};
|
|
9713
9459
|
},
|
|
9714
9460
|
toJSON(message) {
|
|
@@ -9916,11 +9662,11 @@ var EnvelopeType = {
|
|
|
9916
9662
|
},
|
|
9917
9663
|
fromJSON(object) {
|
|
9918
9664
|
return {
|
|
9919
|
-
serial: isSet8(object.serial) ? Boolean(object.serial) : false,
|
|
9920
|
-
anonymous: isSet8(object.anonymous) ? Boolean(object.anonymous) : false,
|
|
9921
|
-
encryptedVotes: isSet8(object.encryptedVotes) ? Boolean(object.encryptedVotes) : false,
|
|
9922
|
-
uniqueValues: isSet8(object.uniqueValues) ? Boolean(object.uniqueValues) : false,
|
|
9923
|
-
costFromWeight: isSet8(object.costFromWeight) ? Boolean(object.costFromWeight) : false
|
|
9665
|
+
serial: isSet8(object.serial) ? globalThis.Boolean(object.serial) : false,
|
|
9666
|
+
anonymous: isSet8(object.anonymous) ? globalThis.Boolean(object.anonymous) : false,
|
|
9667
|
+
encryptedVotes: isSet8(object.encryptedVotes) ? globalThis.Boolean(object.encryptedVotes) : false,
|
|
9668
|
+
uniqueValues: isSet8(object.uniqueValues) ? globalThis.Boolean(object.uniqueValues) : false,
|
|
9669
|
+
costFromWeight: isSet8(object.costFromWeight) ? globalThis.Boolean(object.costFromWeight) : false
|
|
9924
9670
|
};
|
|
9925
9671
|
},
|
|
9926
9672
|
toJSON(message) {
|
|
@@ -10024,11 +9770,11 @@ var ProcessMode = {
|
|
|
10024
9770
|
},
|
|
10025
9771
|
fromJSON(object) {
|
|
10026
9772
|
return {
|
|
10027
|
-
autoStart: isSet8(object.autoStart) ? Boolean(object.autoStart) : false,
|
|
10028
|
-
interruptible: isSet8(object.interruptible) ? Boolean(object.interruptible) : false,
|
|
10029
|
-
dynamicCensus: isSet8(object.dynamicCensus) ? Boolean(object.dynamicCensus) : false,
|
|
10030
|
-
encryptedMetaData: isSet8(object.encryptedMetaData) ? Boolean(object.encryptedMetaData) : false,
|
|
10031
|
-
preRegister: isSet8(object.preRegister) ? Boolean(object.preRegister) : false
|
|
9773
|
+
autoStart: isSet8(object.autoStart) ? globalThis.Boolean(object.autoStart) : false,
|
|
9774
|
+
interruptible: isSet8(object.interruptible) ? globalThis.Boolean(object.interruptible) : false,
|
|
9775
|
+
dynamicCensus: isSet8(object.dynamicCensus) ? globalThis.Boolean(object.dynamicCensus) : false,
|
|
9776
|
+
encryptedMetaData: isSet8(object.encryptedMetaData) ? globalThis.Boolean(object.encryptedMetaData) : false,
|
|
9777
|
+
preRegister: isSet8(object.preRegister) ? globalThis.Boolean(object.preRegister) : false
|
|
10032
9778
|
};
|
|
10033
9779
|
},
|
|
10034
9780
|
toJSON(message) {
|
|
@@ -10132,11 +9878,11 @@ var ProcessVoteOptions = {
|
|
|
10132
9878
|
},
|
|
10133
9879
|
fromJSON(object) {
|
|
10134
9880
|
return {
|
|
10135
|
-
maxCount: isSet8(object.maxCount) ? Number(object.maxCount) : 0,
|
|
10136
|
-
maxValue: isSet8(object.maxValue) ? Number(object.maxValue) : 0,
|
|
10137
|
-
maxVoteOverwrites: isSet8(object.maxVoteOverwrites) ? Number(object.maxVoteOverwrites) : 0,
|
|
10138
|
-
maxTotalCost: isSet8(object.maxTotalCost) ? Number(object.maxTotalCost) : 0,
|
|
10139
|
-
costExponent: isSet8(object.costExponent) ? Number(object.costExponent) : 0
|
|
9881
|
+
maxCount: isSet8(object.maxCount) ? globalThis.Number(object.maxCount) : 0,
|
|
9882
|
+
maxValue: isSet8(object.maxValue) ? globalThis.Number(object.maxValue) : 0,
|
|
9883
|
+
maxVoteOverwrites: isSet8(object.maxVoteOverwrites) ? globalThis.Number(object.maxVoteOverwrites) : 0,
|
|
9884
|
+
maxTotalCost: isSet8(object.maxTotalCost) ? globalThis.Number(object.maxTotalCost) : 0,
|
|
9885
|
+
costExponent: isSet8(object.costExponent) ? globalThis.Number(object.costExponent) : 0
|
|
10140
9886
|
};
|
|
10141
9887
|
},
|
|
10142
9888
|
toJSON(message) {
|
|
@@ -10203,7 +9949,9 @@ var OracleList = {
|
|
|
10203
9949
|
return message;
|
|
10204
9950
|
},
|
|
10205
9951
|
fromJSON(object) {
|
|
10206
|
-
return {
|
|
9952
|
+
return {
|
|
9953
|
+
oracles: globalThis.Array.isArray(object?.oracles) ? object.oracles.map((e) => bytesFromBase643(e)) : []
|
|
9954
|
+
};
|
|
10207
9955
|
},
|
|
10208
9956
|
toJSON(message) {
|
|
10209
9957
|
const obj = {};
|
|
@@ -10254,7 +10002,7 @@ var ValidatorList = {
|
|
|
10254
10002
|
},
|
|
10255
10003
|
fromJSON(object) {
|
|
10256
10004
|
return {
|
|
10257
|
-
validators: Array.isArray(object?.validators) ? object.validators.map((e) => Validator.fromJSON(e)) : []
|
|
10005
|
+
validators: globalThis.Array.isArray(object?.validators) ? object.validators.map((e) => Validator.fromJSON(e)) : []
|
|
10258
10006
|
};
|
|
10259
10007
|
},
|
|
10260
10008
|
toJSON(message) {
|
|
@@ -10274,7 +10022,18 @@ var ValidatorList = {
|
|
|
10274
10022
|
}
|
|
10275
10023
|
};
|
|
10276
10024
|
function createBaseValidator() {
|
|
10277
|
-
return {
|
|
10025
|
+
return {
|
|
10026
|
+
address: new Uint8Array(0),
|
|
10027
|
+
pubKey: new Uint8Array(0),
|
|
10028
|
+
power: 0,
|
|
10029
|
+
name: "",
|
|
10030
|
+
keyIndex: 0,
|
|
10031
|
+
height: 0,
|
|
10032
|
+
proposals: 0,
|
|
10033
|
+
votes: 0,
|
|
10034
|
+
validatorAddress: new Uint8Array(0),
|
|
10035
|
+
score: 0
|
|
10036
|
+
};
|
|
10278
10037
|
}
|
|
10279
10038
|
var Validator = {
|
|
10280
10039
|
encode(message, writer = import_minimal8.default.Writer.create()) {
|
|
@@ -10293,6 +10052,21 @@ var Validator = {
|
|
|
10293
10052
|
if (message.keyIndex !== 0) {
|
|
10294
10053
|
writer.uint32(40).uint32(message.keyIndex);
|
|
10295
10054
|
}
|
|
10055
|
+
if (message.height !== 0) {
|
|
10056
|
+
writer.uint32(48).uint64(message.height);
|
|
10057
|
+
}
|
|
10058
|
+
if (message.proposals !== 0) {
|
|
10059
|
+
writer.uint32(56).uint64(message.proposals);
|
|
10060
|
+
}
|
|
10061
|
+
if (message.votes !== 0) {
|
|
10062
|
+
writer.uint32(64).uint64(message.votes);
|
|
10063
|
+
}
|
|
10064
|
+
if (message.validatorAddress.length !== 0) {
|
|
10065
|
+
writer.uint32(74).bytes(message.validatorAddress);
|
|
10066
|
+
}
|
|
10067
|
+
if (message.score !== 0) {
|
|
10068
|
+
writer.uint32(80).uint32(message.score);
|
|
10069
|
+
}
|
|
10296
10070
|
return writer;
|
|
10297
10071
|
},
|
|
10298
10072
|
decode(input, length) {
|
|
@@ -10332,6 +10106,36 @@ var Validator = {
|
|
|
10332
10106
|
}
|
|
10333
10107
|
message.keyIndex = reader.uint32();
|
|
10334
10108
|
continue;
|
|
10109
|
+
case 6:
|
|
10110
|
+
if (tag !== 48) {
|
|
10111
|
+
break;
|
|
10112
|
+
}
|
|
10113
|
+
message.height = longToNumber2(reader.uint64());
|
|
10114
|
+
continue;
|
|
10115
|
+
case 7:
|
|
10116
|
+
if (tag !== 56) {
|
|
10117
|
+
break;
|
|
10118
|
+
}
|
|
10119
|
+
message.proposals = longToNumber2(reader.uint64());
|
|
10120
|
+
continue;
|
|
10121
|
+
case 8:
|
|
10122
|
+
if (tag !== 64) {
|
|
10123
|
+
break;
|
|
10124
|
+
}
|
|
10125
|
+
message.votes = longToNumber2(reader.uint64());
|
|
10126
|
+
continue;
|
|
10127
|
+
case 9:
|
|
10128
|
+
if (tag !== 74) {
|
|
10129
|
+
break;
|
|
10130
|
+
}
|
|
10131
|
+
message.validatorAddress = reader.bytes();
|
|
10132
|
+
continue;
|
|
10133
|
+
case 10:
|
|
10134
|
+
if (tag !== 80) {
|
|
10135
|
+
break;
|
|
10136
|
+
}
|
|
10137
|
+
message.score = reader.uint32();
|
|
10138
|
+
continue;
|
|
10335
10139
|
}
|
|
10336
10140
|
if ((tag & 7) === 4 || tag === 0) {
|
|
10337
10141
|
break;
|
|
@@ -10344,9 +10148,14 @@ var Validator = {
|
|
|
10344
10148
|
return {
|
|
10345
10149
|
address: isSet8(object.address) ? bytesFromBase643(object.address) : new Uint8Array(0),
|
|
10346
10150
|
pubKey: isSet8(object.pubKey) ? bytesFromBase643(object.pubKey) : new Uint8Array(0),
|
|
10347
|
-
power: isSet8(object.power) ? Number(object.power) : 0,
|
|
10348
|
-
name: isSet8(object.name) ? String(object.name) : "",
|
|
10349
|
-
keyIndex: isSet8(object.keyIndex) ? Number(object.keyIndex) : 0
|
|
10151
|
+
power: isSet8(object.power) ? globalThis.Number(object.power) : 0,
|
|
10152
|
+
name: isSet8(object.name) ? globalThis.String(object.name) : "",
|
|
10153
|
+
keyIndex: isSet8(object.keyIndex) ? globalThis.Number(object.keyIndex) : 0,
|
|
10154
|
+
height: isSet8(object.height) ? globalThis.Number(object.height) : 0,
|
|
10155
|
+
proposals: isSet8(object.proposals) ? globalThis.Number(object.proposals) : 0,
|
|
10156
|
+
votes: isSet8(object.votes) ? globalThis.Number(object.votes) : 0,
|
|
10157
|
+
validatorAddress: isSet8(object.validatorAddress) ? bytesFromBase643(object.validatorAddress) : new Uint8Array(0),
|
|
10158
|
+
score: isSet8(object.score) ? globalThis.Number(object.score) : 0
|
|
10350
10159
|
};
|
|
10351
10160
|
},
|
|
10352
10161
|
toJSON(message) {
|
|
@@ -10366,6 +10175,21 @@ var Validator = {
|
|
|
10366
10175
|
if (message.keyIndex !== 0) {
|
|
10367
10176
|
obj.keyIndex = Math.round(message.keyIndex);
|
|
10368
10177
|
}
|
|
10178
|
+
if (message.height !== 0) {
|
|
10179
|
+
obj.height = Math.round(message.height);
|
|
10180
|
+
}
|
|
10181
|
+
if (message.proposals !== 0) {
|
|
10182
|
+
obj.proposals = Math.round(message.proposals);
|
|
10183
|
+
}
|
|
10184
|
+
if (message.votes !== 0) {
|
|
10185
|
+
obj.votes = Math.round(message.votes);
|
|
10186
|
+
}
|
|
10187
|
+
if (message.validatorAddress.length !== 0) {
|
|
10188
|
+
obj.validatorAddress = base64FromBytes3(message.validatorAddress);
|
|
10189
|
+
}
|
|
10190
|
+
if (message.score !== 0) {
|
|
10191
|
+
obj.score = Math.round(message.score);
|
|
10192
|
+
}
|
|
10369
10193
|
return obj;
|
|
10370
10194
|
},
|
|
10371
10195
|
create(base) {
|
|
@@ -10378,6 +10202,11 @@ var Validator = {
|
|
|
10378
10202
|
message.power = object.power ?? 0;
|
|
10379
10203
|
message.name = object.name ?? "";
|
|
10380
10204
|
message.keyIndex = object.keyIndex ?? 0;
|
|
10205
|
+
message.height = object.height ?? 0;
|
|
10206
|
+
message.proposals = object.proposals ?? 0;
|
|
10207
|
+
message.votes = object.votes ?? 0;
|
|
10208
|
+
message.validatorAddress = object.validatorAddress ?? new Uint8Array(0);
|
|
10209
|
+
message.score = object.score ?? 0;
|
|
10381
10210
|
return message;
|
|
10382
10211
|
}
|
|
10383
10212
|
};
|
|
@@ -10536,9 +10365,9 @@ var TendermintHeader = {
|
|
|
10536
10365
|
},
|
|
10537
10366
|
fromJSON(object) {
|
|
10538
10367
|
return {
|
|
10539
|
-
chainId: isSet8(object.chainId) ? String(object.chainId) : "",
|
|
10540
|
-
height: isSet8(object.height) ? Number(object.height) : 0,
|
|
10541
|
-
timestamp: isSet8(object.timestamp) ? Number(object.timestamp) : 0,
|
|
10368
|
+
chainId: isSet8(object.chainId) ? globalThis.String(object.chainId) : "",
|
|
10369
|
+
height: isSet8(object.height) ? globalThis.Number(object.height) : 0,
|
|
10370
|
+
timestamp: isSet8(object.timestamp) ? globalThis.Number(object.timestamp) : 0,
|
|
10542
10371
|
blockID: isSet8(object.blockID) ? bytesFromBase643(object.blockID) : new Uint8Array(0),
|
|
10543
10372
|
lastCommitHash: isSet8(object.lastCommitHash) ? bytesFromBase643(object.lastCommitHash) : new Uint8Array(0),
|
|
10544
10373
|
dataHash: isSet8(object.dataHash) ? bytesFromBase643(object.dataHash) : new Uint8Array(0),
|
|
@@ -10647,7 +10476,9 @@ var ProcessResult = {
|
|
|
10647
10476
|
return message;
|
|
10648
10477
|
},
|
|
10649
10478
|
fromJSON(object) {
|
|
10650
|
-
return {
|
|
10479
|
+
return {
|
|
10480
|
+
votes: globalThis.Array.isArray(object?.votes) ? object.votes.map((e) => QuestionResult.fromJSON(e)) : []
|
|
10481
|
+
};
|
|
10651
10482
|
},
|
|
10652
10483
|
toJSON(message) {
|
|
10653
10484
|
const obj = {};
|
|
@@ -10697,7 +10528,9 @@ var QuestionResult = {
|
|
|
10697
10528
|
return message;
|
|
10698
10529
|
},
|
|
10699
10530
|
fromJSON(object) {
|
|
10700
|
-
return {
|
|
10531
|
+
return {
|
|
10532
|
+
question: globalThis.Array.isArray(object?.question) ? object.question.map((e) => bytesFromBase643(e)) : []
|
|
10533
|
+
};
|
|
10701
10534
|
},
|
|
10702
10535
|
toJSON(message) {
|
|
10703
10536
|
const obj = {};
|
|
@@ -10748,7 +10581,7 @@ var ProcessEndingList = {
|
|
|
10748
10581
|
},
|
|
10749
10582
|
fromJSON(object) {
|
|
10750
10583
|
return {
|
|
10751
|
-
processList: Array.isArray(object?.processList) ? object.processList.map((e) => bytesFromBase643(e)) : []
|
|
10584
|
+
processList: globalThis.Array.isArray(object?.processList) ? object.processList.map((e) => bytesFromBase643(e)) : []
|
|
10752
10585
|
};
|
|
10753
10586
|
},
|
|
10754
10587
|
toJSON(message) {
|
|
@@ -10799,7 +10632,7 @@ var StoredKeys = {
|
|
|
10799
10632
|
return message;
|
|
10800
10633
|
},
|
|
10801
10634
|
fromJSON(object) {
|
|
10802
|
-
return { pids: Array.isArray(object?.pids) ? object.pids.map((e) => bytesFromBase643(e)) : [] };
|
|
10635
|
+
return { pids: globalThis.Array.isArray(object?.pids) ? object.pids.map((e) => bytesFromBase643(e)) : [] };
|
|
10803
10636
|
},
|
|
10804
10637
|
toJSON(message) {
|
|
10805
10638
|
const obj = {};
|
|
@@ -10817,26 +10650,11 @@ var StoredKeys = {
|
|
|
10817
10650
|
return message;
|
|
10818
10651
|
}
|
|
10819
10652
|
};
|
|
10820
|
-
var tsProtoGlobalThis3 = (() => {
|
|
10821
|
-
if (typeof globalThis !== "undefined") {
|
|
10822
|
-
return globalThis;
|
|
10823
|
-
}
|
|
10824
|
-
if (typeof self !== "undefined") {
|
|
10825
|
-
return self;
|
|
10826
|
-
}
|
|
10827
|
-
if (typeof window !== "undefined") {
|
|
10828
|
-
return window;
|
|
10829
|
-
}
|
|
10830
|
-
if (typeof global !== "undefined") {
|
|
10831
|
-
return global;
|
|
10832
|
-
}
|
|
10833
|
-
throw "Unable to locate global object";
|
|
10834
|
-
})();
|
|
10835
10653
|
function bytesFromBase643(b64) {
|
|
10836
|
-
if (
|
|
10837
|
-
return Uint8Array.from(
|
|
10654
|
+
if (globalThis.Buffer) {
|
|
10655
|
+
return Uint8Array.from(globalThis.Buffer.from(b64, "base64"));
|
|
10838
10656
|
} else {
|
|
10839
|
-
const bin =
|
|
10657
|
+
const bin = globalThis.atob(b64);
|
|
10840
10658
|
const arr = new Uint8Array(bin.length);
|
|
10841
10659
|
for (let i = 0; i < bin.length; ++i) {
|
|
10842
10660
|
arr[i] = bin.charCodeAt(i);
|
|
@@ -10845,19 +10663,19 @@ function bytesFromBase643(b64) {
|
|
|
10845
10663
|
}
|
|
10846
10664
|
}
|
|
10847
10665
|
function base64FromBytes3(arr) {
|
|
10848
|
-
if (
|
|
10849
|
-
return
|
|
10666
|
+
if (globalThis.Buffer) {
|
|
10667
|
+
return globalThis.Buffer.from(arr).toString("base64");
|
|
10850
10668
|
} else {
|
|
10851
10669
|
const bin = [];
|
|
10852
10670
|
arr.forEach((byte) => {
|
|
10853
|
-
bin.push(String.fromCharCode(byte));
|
|
10671
|
+
bin.push(globalThis.String.fromCharCode(byte));
|
|
10854
10672
|
});
|
|
10855
|
-
return
|
|
10673
|
+
return globalThis.btoa(bin.join(""));
|
|
10856
10674
|
}
|
|
10857
10675
|
}
|
|
10858
10676
|
function longToNumber2(long) {
|
|
10859
|
-
if (long.gt(Number.MAX_SAFE_INTEGER)) {
|
|
10860
|
-
throw new
|
|
10677
|
+
if (long.gt(globalThis.Number.MAX_SAFE_INTEGER)) {
|
|
10678
|
+
throw new globalThis.Error("Value is larger than Number.MAX_SAFE_INTEGER");
|
|
10861
10679
|
}
|
|
10862
10680
|
return long.toNumber();
|
|
10863
10681
|
}
|