@vocdoni/proto 1.16.1 → 1.18.0
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/{index-b19a326e.d.ts → index-f9ff5e35.d.ts} +142 -0
- package/build/js/index.d.ts +1 -1
- package/build/js/index.js +110 -8
- package/build/js/index.mjs +110 -8
- package/build/js/vochain/index.d.ts +1 -1
- package/build/js/vochain/index.js +110 -8
- package/build/js/vochain/index.mjs +110 -8
- package/package.json +1 -1
|
@@ -1562,6 +1562,7 @@ var TxType = /* @__PURE__ */ ((TxType2) => {
|
|
|
1562
1562
|
TxType2[TxType2["REGISTER_SIK"] = 26] = "REGISTER_SIK";
|
|
1563
1563
|
TxType2[TxType2["SET_ACCOUNT_VALIDATOR"] = 27] = "SET_ACCOUNT_VALIDATOR";
|
|
1564
1564
|
TxType2[TxType2["SET_PROCESS_DURATION"] = 28] = "SET_PROCESS_DURATION";
|
|
1565
|
+
TxType2[TxType2["SET_PROCESS_METADATA"] = 29] = "SET_PROCESS_METADATA";
|
|
1565
1566
|
TxType2[TxType2["UNRECOGNIZED"] = -1] = "UNRECOGNIZED";
|
|
1566
1567
|
return TxType2;
|
|
1567
1568
|
})(TxType || {});
|
|
@@ -1648,6 +1649,9 @@ function txTypeFromJSON(object) {
|
|
|
1648
1649
|
case 28:
|
|
1649
1650
|
case "SET_PROCESS_DURATION":
|
|
1650
1651
|
return 28 /* SET_PROCESS_DURATION */;
|
|
1652
|
+
case 29:
|
|
1653
|
+
case "SET_PROCESS_METADATA":
|
|
1654
|
+
return 29 /* SET_PROCESS_METADATA */;
|
|
1651
1655
|
case -1:
|
|
1652
1656
|
case "UNRECOGNIZED":
|
|
1653
1657
|
default:
|
|
@@ -1710,6 +1714,8 @@ function txTypeToJSON(object) {
|
|
|
1710
1714
|
return "SET_ACCOUNT_VALIDATOR";
|
|
1711
1715
|
case 28 /* SET_PROCESS_DURATION */:
|
|
1712
1716
|
return "SET_PROCESS_DURATION";
|
|
1717
|
+
case 29 /* SET_PROCESS_METADATA */:
|
|
1718
|
+
return "SET_PROCESS_METADATA";
|
|
1713
1719
|
case -1 /* UNRECOGNIZED */:
|
|
1714
1720
|
default:
|
|
1715
1721
|
return "UNRECOGNIZED";
|
|
@@ -2090,7 +2096,8 @@ function createBaseVoteEnvelope() {
|
|
|
2090
2096
|
votePackage: new Uint8Array(0),
|
|
2091
2097
|
nullifier: new Uint8Array(0),
|
|
2092
2098
|
encryptionKeyIndexes: [],
|
|
2093
|
-
memo: void 0
|
|
2099
|
+
memo: void 0,
|
|
2100
|
+
metadataHash: void 0
|
|
2094
2101
|
};
|
|
2095
2102
|
}
|
|
2096
2103
|
var VoteEnvelope = {
|
|
@@ -2118,6 +2125,9 @@ var VoteEnvelope = {
|
|
|
2118
2125
|
if (message.memo !== void 0) {
|
|
2119
2126
|
writer.uint32(58).bytes(message.memo);
|
|
2120
2127
|
}
|
|
2128
|
+
if (message.metadataHash !== void 0) {
|
|
2129
|
+
writer.uint32(66).bytes(message.metadataHash);
|
|
2130
|
+
}
|
|
2121
2131
|
return writer;
|
|
2122
2132
|
},
|
|
2123
2133
|
decode(input, length) {
|
|
@@ -2176,6 +2186,12 @@ var VoteEnvelope = {
|
|
|
2176
2186
|
}
|
|
2177
2187
|
message.memo = reader.bytes();
|
|
2178
2188
|
continue;
|
|
2189
|
+
case 8:
|
|
2190
|
+
if (tag !== 66) {
|
|
2191
|
+
break;
|
|
2192
|
+
}
|
|
2193
|
+
message.metadataHash = reader.bytes();
|
|
2194
|
+
continue;
|
|
2179
2195
|
}
|
|
2180
2196
|
if ((tag & 7) === 4 || tag === 0) {
|
|
2181
2197
|
break;
|
|
@@ -2192,7 +2208,8 @@ var VoteEnvelope = {
|
|
|
2192
2208
|
votePackage: isSet(object.votePackage) ? bytesFromBase64(object.votePackage) : new Uint8Array(0),
|
|
2193
2209
|
nullifier: isSet(object.nullifier) ? bytesFromBase64(object.nullifier) : new Uint8Array(0),
|
|
2194
2210
|
encryptionKeyIndexes: globalThis.Array.isArray(object?.encryptionKeyIndexes) ? object.encryptionKeyIndexes.map((e) => globalThis.Number(e)) : [],
|
|
2195
|
-
memo: isSet(object.memo) ? bytesFromBase64(object.memo) : void 0
|
|
2211
|
+
memo: isSet(object.memo) ? bytesFromBase64(object.memo) : void 0,
|
|
2212
|
+
metadataHash: isSet(object.metadataHash) ? bytesFromBase64(object.metadataHash) : void 0
|
|
2196
2213
|
};
|
|
2197
2214
|
},
|
|
2198
2215
|
toJSON(message) {
|
|
@@ -2218,6 +2235,9 @@ var VoteEnvelope = {
|
|
|
2218
2235
|
if (message.memo !== void 0) {
|
|
2219
2236
|
obj.memo = base64FromBytes(message.memo);
|
|
2220
2237
|
}
|
|
2238
|
+
if (message.metadataHash !== void 0) {
|
|
2239
|
+
obj.metadataHash = base64FromBytes(message.metadataHash);
|
|
2240
|
+
}
|
|
2221
2241
|
return obj;
|
|
2222
2242
|
},
|
|
2223
2243
|
create(base) {
|
|
@@ -2232,6 +2252,7 @@ var VoteEnvelope = {
|
|
|
2232
2252
|
message.nullifier = object.nullifier ?? new Uint8Array(0);
|
|
2233
2253
|
message.encryptionKeyIndexes = object.encryptionKeyIndexes?.map((e) => e) || [];
|
|
2234
2254
|
message.memo = object.memo ?? void 0;
|
|
2255
|
+
message.metadataHash = object.metadataHash ?? void 0;
|
|
2235
2256
|
return message;
|
|
2236
2257
|
}
|
|
2237
2258
|
};
|
|
@@ -3273,7 +3294,9 @@ function createBaseSetProcessTx() {
|
|
|
3273
3294
|
tempSIKs: void 0,
|
|
3274
3295
|
duration: void 0,
|
|
3275
3296
|
censusSize: void 0,
|
|
3276
|
-
faucetPackage: void 0
|
|
3297
|
+
faucetPackage: void 0,
|
|
3298
|
+
metadata: void 0,
|
|
3299
|
+
metadataHash: void 0
|
|
3277
3300
|
};
|
|
3278
3301
|
}
|
|
3279
3302
|
var SetProcessTx = {
|
|
@@ -3317,6 +3340,12 @@ var SetProcessTx = {
|
|
|
3317
3340
|
if (message.faucetPackage !== void 0) {
|
|
3318
3341
|
FaucetPackage.encode(message.faucetPackage, writer.uint32(106).fork()).ldelim();
|
|
3319
3342
|
}
|
|
3343
|
+
if (message.metadata !== void 0) {
|
|
3344
|
+
writer.uint32(114).string(message.metadata);
|
|
3345
|
+
}
|
|
3346
|
+
if (message.metadataHash !== void 0) {
|
|
3347
|
+
writer.uint32(122).bytes(message.metadataHash);
|
|
3348
|
+
}
|
|
3320
3349
|
return writer;
|
|
3321
3350
|
},
|
|
3322
3351
|
decode(input, length) {
|
|
@@ -3404,6 +3433,18 @@ var SetProcessTx = {
|
|
|
3404
3433
|
}
|
|
3405
3434
|
message.faucetPackage = FaucetPackage.decode(reader, reader.uint32());
|
|
3406
3435
|
continue;
|
|
3436
|
+
case 14:
|
|
3437
|
+
if (tag !== 114) {
|
|
3438
|
+
break;
|
|
3439
|
+
}
|
|
3440
|
+
message.metadata = reader.string();
|
|
3441
|
+
continue;
|
|
3442
|
+
case 15:
|
|
3443
|
+
if (tag !== 122) {
|
|
3444
|
+
break;
|
|
3445
|
+
}
|
|
3446
|
+
message.metadataHash = reader.bytes();
|
|
3447
|
+
continue;
|
|
3407
3448
|
}
|
|
3408
3449
|
if ((tag & 7) === 4 || tag === 0) {
|
|
3409
3450
|
break;
|
|
@@ -3426,7 +3467,9 @@ var SetProcessTx = {
|
|
|
3426
3467
|
tempSIKs: isSet(object.tempSIKs) ? globalThis.Boolean(object.tempSIKs) : void 0,
|
|
3427
3468
|
duration: isSet(object.duration) ? globalThis.Number(object.duration) : void 0,
|
|
3428
3469
|
censusSize: isSet(object.censusSize) ? globalThis.Number(object.censusSize) : void 0,
|
|
3429
|
-
faucetPackage: isSet(object.faucetPackage) ? FaucetPackage.fromJSON(object.faucetPackage) : void 0
|
|
3470
|
+
faucetPackage: isSet(object.faucetPackage) ? FaucetPackage.fromJSON(object.faucetPackage) : void 0,
|
|
3471
|
+
metadata: isSet(object.metadata) ? globalThis.String(object.metadata) : void 0,
|
|
3472
|
+
metadataHash: isSet(object.metadataHash) ? bytesFromBase64(object.metadataHash) : void 0
|
|
3430
3473
|
};
|
|
3431
3474
|
},
|
|
3432
3475
|
toJSON(message) {
|
|
@@ -3470,6 +3513,12 @@ var SetProcessTx = {
|
|
|
3470
3513
|
if (message.faucetPackage !== void 0) {
|
|
3471
3514
|
obj.faucetPackage = FaucetPackage.toJSON(message.faucetPackage);
|
|
3472
3515
|
}
|
|
3516
|
+
if (message.metadata !== void 0) {
|
|
3517
|
+
obj.metadata = message.metadata;
|
|
3518
|
+
}
|
|
3519
|
+
if (message.metadataHash !== void 0) {
|
|
3520
|
+
obj.metadataHash = base64FromBytes(message.metadataHash);
|
|
3521
|
+
}
|
|
3473
3522
|
return obj;
|
|
3474
3523
|
},
|
|
3475
3524
|
create(base) {
|
|
@@ -3490,6 +3539,8 @@ var SetProcessTx = {
|
|
|
3490
3539
|
message.duration = object.duration ?? void 0;
|
|
3491
3540
|
message.censusSize = object.censusSize ?? void 0;
|
|
3492
3541
|
message.faucetPackage = object.faucetPackage !== void 0 && object.faucetPackage !== null ? FaucetPackage.fromPartial(object.faucetPackage) : void 0;
|
|
3542
|
+
message.metadata = object.metadata ?? void 0;
|
|
3543
|
+
message.metadataHash = object.metadataHash ?? void 0;
|
|
3493
3544
|
return message;
|
|
3494
3545
|
}
|
|
3495
3546
|
};
|
|
@@ -4651,7 +4702,8 @@ function createBaseProcess() {
|
|
|
4651
4702
|
tokenDecimals: void 0,
|
|
4652
4703
|
tempSIKs: void 0,
|
|
4653
4704
|
startTime: 0,
|
|
4654
|
-
duration: 0
|
|
4705
|
+
duration: 0,
|
|
4706
|
+
metadataHash: void 0
|
|
4655
4707
|
};
|
|
4656
4708
|
}
|
|
4657
4709
|
var Process = {
|
|
@@ -4755,6 +4807,9 @@ var Process = {
|
|
|
4755
4807
|
if (message.duration !== 0) {
|
|
4756
4808
|
writer.uint32(288).uint32(message.duration);
|
|
4757
4809
|
}
|
|
4810
|
+
if (message.metadataHash !== void 0) {
|
|
4811
|
+
writer.uint32(298).bytes(message.metadataHash);
|
|
4812
|
+
}
|
|
4758
4813
|
return writer;
|
|
4759
4814
|
},
|
|
4760
4815
|
decode(input, length) {
|
|
@@ -4962,6 +5017,12 @@ var Process = {
|
|
|
4962
5017
|
}
|
|
4963
5018
|
message.duration = reader.uint32();
|
|
4964
5019
|
continue;
|
|
5020
|
+
case 37:
|
|
5021
|
+
if (tag !== 298) {
|
|
5022
|
+
break;
|
|
5023
|
+
}
|
|
5024
|
+
message.metadataHash = reader.bytes();
|
|
5025
|
+
continue;
|
|
4965
5026
|
}
|
|
4966
5027
|
if ((tag & 7) === 4 || tag === 0) {
|
|
4967
5028
|
break;
|
|
@@ -5004,7 +5065,8 @@ var Process = {
|
|
|
5004
5065
|
tokenDecimals: isSet(object.tokenDecimals) ? globalThis.Number(object.tokenDecimals) : void 0,
|
|
5005
5066
|
tempSIKs: isSet(object.tempSIKs) ? globalThis.Boolean(object.tempSIKs) : void 0,
|
|
5006
5067
|
startTime: isSet(object.startTime) ? globalThis.Number(object.startTime) : 0,
|
|
5007
|
-
duration: isSet(object.duration) ? globalThis.Number(object.duration) : 0
|
|
5068
|
+
duration: isSet(object.duration) ? globalThis.Number(object.duration) : 0,
|
|
5069
|
+
metadataHash: isSet(object.metadataHash) ? bytesFromBase64(object.metadataHash) : void 0
|
|
5008
5070
|
};
|
|
5009
5071
|
},
|
|
5010
5072
|
toJSON(message) {
|
|
@@ -5108,6 +5170,9 @@ var Process = {
|
|
|
5108
5170
|
if (message.duration !== 0) {
|
|
5109
5171
|
obj.duration = Math.round(message.duration);
|
|
5110
5172
|
}
|
|
5173
|
+
if (message.metadataHash !== void 0) {
|
|
5174
|
+
obj.metadataHash = base64FromBytes(message.metadataHash);
|
|
5175
|
+
}
|
|
5111
5176
|
return obj;
|
|
5112
5177
|
},
|
|
5113
5178
|
create(base) {
|
|
@@ -5148,6 +5213,7 @@ var Process = {
|
|
|
5148
5213
|
message.tempSIKs = object.tempSIKs ?? void 0;
|
|
5149
5214
|
message.startTime = object.startTime ?? 0;
|
|
5150
5215
|
message.duration = object.duration ?? 0;
|
|
5216
|
+
message.metadataHash = object.metadataHash ?? void 0;
|
|
5151
5217
|
return message;
|
|
5152
5218
|
}
|
|
5153
5219
|
};
|
|
@@ -5368,7 +5434,15 @@ var ProcessMode = {
|
|
|
5368
5434
|
}
|
|
5369
5435
|
};
|
|
5370
5436
|
function createBaseProcessVoteOptions() {
|
|
5371
|
-
return {
|
|
5437
|
+
return {
|
|
5438
|
+
maxCount: 0,
|
|
5439
|
+
maxValue: 0,
|
|
5440
|
+
maxVoteOverwrites: 0,
|
|
5441
|
+
maxTotalCost: 0,
|
|
5442
|
+
costExponent: 0,
|
|
5443
|
+
minValue: 0,
|
|
5444
|
+
minTotalCost: 0
|
|
5445
|
+
};
|
|
5372
5446
|
}
|
|
5373
5447
|
var ProcessVoteOptions = {
|
|
5374
5448
|
encode(message, writer = import_minimal.default.Writer.create()) {
|
|
@@ -5387,6 +5461,12 @@ var ProcessVoteOptions = {
|
|
|
5387
5461
|
if (message.costExponent !== 0) {
|
|
5388
5462
|
writer.uint32(40).uint32(message.costExponent);
|
|
5389
5463
|
}
|
|
5464
|
+
if (message.minValue !== 0) {
|
|
5465
|
+
writer.uint32(48).uint32(message.minValue);
|
|
5466
|
+
}
|
|
5467
|
+
if (message.minTotalCost !== 0) {
|
|
5468
|
+
writer.uint32(56).uint32(message.minTotalCost);
|
|
5469
|
+
}
|
|
5390
5470
|
return writer;
|
|
5391
5471
|
},
|
|
5392
5472
|
decode(input, length) {
|
|
@@ -5426,6 +5506,18 @@ var ProcessVoteOptions = {
|
|
|
5426
5506
|
}
|
|
5427
5507
|
message.costExponent = reader.uint32();
|
|
5428
5508
|
continue;
|
|
5509
|
+
case 6:
|
|
5510
|
+
if (tag !== 48) {
|
|
5511
|
+
break;
|
|
5512
|
+
}
|
|
5513
|
+
message.minValue = reader.uint32();
|
|
5514
|
+
continue;
|
|
5515
|
+
case 7:
|
|
5516
|
+
if (tag !== 56) {
|
|
5517
|
+
break;
|
|
5518
|
+
}
|
|
5519
|
+
message.minTotalCost = reader.uint32();
|
|
5520
|
+
continue;
|
|
5429
5521
|
}
|
|
5430
5522
|
if ((tag & 7) === 4 || tag === 0) {
|
|
5431
5523
|
break;
|
|
@@ -5440,7 +5532,9 @@ var ProcessVoteOptions = {
|
|
|
5440
5532
|
maxValue: isSet(object.maxValue) ? globalThis.Number(object.maxValue) : 0,
|
|
5441
5533
|
maxVoteOverwrites: isSet(object.maxVoteOverwrites) ? globalThis.Number(object.maxVoteOverwrites) : 0,
|
|
5442
5534
|
maxTotalCost: isSet(object.maxTotalCost) ? globalThis.Number(object.maxTotalCost) : 0,
|
|
5443
|
-
costExponent: isSet(object.costExponent) ? globalThis.Number(object.costExponent) : 0
|
|
5535
|
+
costExponent: isSet(object.costExponent) ? globalThis.Number(object.costExponent) : 0,
|
|
5536
|
+
minValue: isSet(object.minValue) ? globalThis.Number(object.minValue) : 0,
|
|
5537
|
+
minTotalCost: isSet(object.minTotalCost) ? globalThis.Number(object.minTotalCost) : 0
|
|
5444
5538
|
};
|
|
5445
5539
|
},
|
|
5446
5540
|
toJSON(message) {
|
|
@@ -5460,6 +5554,12 @@ var ProcessVoteOptions = {
|
|
|
5460
5554
|
if (message.costExponent !== 0) {
|
|
5461
5555
|
obj.costExponent = Math.round(message.costExponent);
|
|
5462
5556
|
}
|
|
5557
|
+
if (message.minValue !== 0) {
|
|
5558
|
+
obj.minValue = Math.round(message.minValue);
|
|
5559
|
+
}
|
|
5560
|
+
if (message.minTotalCost !== 0) {
|
|
5561
|
+
obj.minTotalCost = Math.round(message.minTotalCost);
|
|
5562
|
+
}
|
|
5463
5563
|
return obj;
|
|
5464
5564
|
},
|
|
5465
5565
|
create(base) {
|
|
@@ -5472,6 +5572,8 @@ var ProcessVoteOptions = {
|
|
|
5472
5572
|
message.maxVoteOverwrites = object.maxVoteOverwrites ?? 0;
|
|
5473
5573
|
message.maxTotalCost = object.maxTotalCost ?? 0;
|
|
5474
5574
|
message.costExponent = object.costExponent ?? 0;
|
|
5575
|
+
message.minValue = object.minValue ?? 0;
|
|
5576
|
+
message.minTotalCost = object.minTotalCost ?? 0;
|
|
5475
5577
|
return message;
|
|
5476
5578
|
}
|
|
5477
5579
|
};
|
|
@@ -1498,6 +1498,7 @@ var TxType = /* @__PURE__ */ ((TxType2) => {
|
|
|
1498
1498
|
TxType2[TxType2["REGISTER_SIK"] = 26] = "REGISTER_SIK";
|
|
1499
1499
|
TxType2[TxType2["SET_ACCOUNT_VALIDATOR"] = 27] = "SET_ACCOUNT_VALIDATOR";
|
|
1500
1500
|
TxType2[TxType2["SET_PROCESS_DURATION"] = 28] = "SET_PROCESS_DURATION";
|
|
1501
|
+
TxType2[TxType2["SET_PROCESS_METADATA"] = 29] = "SET_PROCESS_METADATA";
|
|
1501
1502
|
TxType2[TxType2["UNRECOGNIZED"] = -1] = "UNRECOGNIZED";
|
|
1502
1503
|
return TxType2;
|
|
1503
1504
|
})(TxType || {});
|
|
@@ -1584,6 +1585,9 @@ function txTypeFromJSON(object) {
|
|
|
1584
1585
|
case 28:
|
|
1585
1586
|
case "SET_PROCESS_DURATION":
|
|
1586
1587
|
return 28 /* SET_PROCESS_DURATION */;
|
|
1588
|
+
case 29:
|
|
1589
|
+
case "SET_PROCESS_METADATA":
|
|
1590
|
+
return 29 /* SET_PROCESS_METADATA */;
|
|
1587
1591
|
case -1:
|
|
1588
1592
|
case "UNRECOGNIZED":
|
|
1589
1593
|
default:
|
|
@@ -1646,6 +1650,8 @@ function txTypeToJSON(object) {
|
|
|
1646
1650
|
return "SET_ACCOUNT_VALIDATOR";
|
|
1647
1651
|
case 28 /* SET_PROCESS_DURATION */:
|
|
1648
1652
|
return "SET_PROCESS_DURATION";
|
|
1653
|
+
case 29 /* SET_PROCESS_METADATA */:
|
|
1654
|
+
return "SET_PROCESS_METADATA";
|
|
1649
1655
|
case -1 /* UNRECOGNIZED */:
|
|
1650
1656
|
default:
|
|
1651
1657
|
return "UNRECOGNIZED";
|
|
@@ -2026,7 +2032,8 @@ function createBaseVoteEnvelope() {
|
|
|
2026
2032
|
votePackage: new Uint8Array(0),
|
|
2027
2033
|
nullifier: new Uint8Array(0),
|
|
2028
2034
|
encryptionKeyIndexes: [],
|
|
2029
|
-
memo: void 0
|
|
2035
|
+
memo: void 0,
|
|
2036
|
+
metadataHash: void 0
|
|
2030
2037
|
};
|
|
2031
2038
|
}
|
|
2032
2039
|
var VoteEnvelope = {
|
|
@@ -2054,6 +2061,9 @@ var VoteEnvelope = {
|
|
|
2054
2061
|
if (message.memo !== void 0) {
|
|
2055
2062
|
writer.uint32(58).bytes(message.memo);
|
|
2056
2063
|
}
|
|
2064
|
+
if (message.metadataHash !== void 0) {
|
|
2065
|
+
writer.uint32(66).bytes(message.metadataHash);
|
|
2066
|
+
}
|
|
2057
2067
|
return writer;
|
|
2058
2068
|
},
|
|
2059
2069
|
decode(input, length) {
|
|
@@ -2112,6 +2122,12 @@ var VoteEnvelope = {
|
|
|
2112
2122
|
}
|
|
2113
2123
|
message.memo = reader.bytes();
|
|
2114
2124
|
continue;
|
|
2125
|
+
case 8:
|
|
2126
|
+
if (tag !== 66) {
|
|
2127
|
+
break;
|
|
2128
|
+
}
|
|
2129
|
+
message.metadataHash = reader.bytes();
|
|
2130
|
+
continue;
|
|
2115
2131
|
}
|
|
2116
2132
|
if ((tag & 7) === 4 || tag === 0) {
|
|
2117
2133
|
break;
|
|
@@ -2128,7 +2144,8 @@ var VoteEnvelope = {
|
|
|
2128
2144
|
votePackage: isSet(object.votePackage) ? bytesFromBase64(object.votePackage) : new Uint8Array(0),
|
|
2129
2145
|
nullifier: isSet(object.nullifier) ? bytesFromBase64(object.nullifier) : new Uint8Array(0),
|
|
2130
2146
|
encryptionKeyIndexes: globalThis.Array.isArray(object?.encryptionKeyIndexes) ? object.encryptionKeyIndexes.map((e) => globalThis.Number(e)) : [],
|
|
2131
|
-
memo: isSet(object.memo) ? bytesFromBase64(object.memo) : void 0
|
|
2147
|
+
memo: isSet(object.memo) ? bytesFromBase64(object.memo) : void 0,
|
|
2148
|
+
metadataHash: isSet(object.metadataHash) ? bytesFromBase64(object.metadataHash) : void 0
|
|
2132
2149
|
};
|
|
2133
2150
|
},
|
|
2134
2151
|
toJSON(message) {
|
|
@@ -2154,6 +2171,9 @@ var VoteEnvelope = {
|
|
|
2154
2171
|
if (message.memo !== void 0) {
|
|
2155
2172
|
obj.memo = base64FromBytes(message.memo);
|
|
2156
2173
|
}
|
|
2174
|
+
if (message.metadataHash !== void 0) {
|
|
2175
|
+
obj.metadataHash = base64FromBytes(message.metadataHash);
|
|
2176
|
+
}
|
|
2157
2177
|
return obj;
|
|
2158
2178
|
},
|
|
2159
2179
|
create(base) {
|
|
@@ -2168,6 +2188,7 @@ var VoteEnvelope = {
|
|
|
2168
2188
|
message.nullifier = object.nullifier ?? new Uint8Array(0);
|
|
2169
2189
|
message.encryptionKeyIndexes = object.encryptionKeyIndexes?.map((e) => e) || [];
|
|
2170
2190
|
message.memo = object.memo ?? void 0;
|
|
2191
|
+
message.metadataHash = object.metadataHash ?? void 0;
|
|
2171
2192
|
return message;
|
|
2172
2193
|
}
|
|
2173
2194
|
};
|
|
@@ -3209,7 +3230,9 @@ function createBaseSetProcessTx() {
|
|
|
3209
3230
|
tempSIKs: void 0,
|
|
3210
3231
|
duration: void 0,
|
|
3211
3232
|
censusSize: void 0,
|
|
3212
|
-
faucetPackage: void 0
|
|
3233
|
+
faucetPackage: void 0,
|
|
3234
|
+
metadata: void 0,
|
|
3235
|
+
metadataHash: void 0
|
|
3213
3236
|
};
|
|
3214
3237
|
}
|
|
3215
3238
|
var SetProcessTx = {
|
|
@@ -3253,6 +3276,12 @@ var SetProcessTx = {
|
|
|
3253
3276
|
if (message.faucetPackage !== void 0) {
|
|
3254
3277
|
FaucetPackage.encode(message.faucetPackage, writer.uint32(106).fork()).ldelim();
|
|
3255
3278
|
}
|
|
3279
|
+
if (message.metadata !== void 0) {
|
|
3280
|
+
writer.uint32(114).string(message.metadata);
|
|
3281
|
+
}
|
|
3282
|
+
if (message.metadataHash !== void 0) {
|
|
3283
|
+
writer.uint32(122).bytes(message.metadataHash);
|
|
3284
|
+
}
|
|
3256
3285
|
return writer;
|
|
3257
3286
|
},
|
|
3258
3287
|
decode(input, length) {
|
|
@@ -3340,6 +3369,18 @@ var SetProcessTx = {
|
|
|
3340
3369
|
}
|
|
3341
3370
|
message.faucetPackage = FaucetPackage.decode(reader, reader.uint32());
|
|
3342
3371
|
continue;
|
|
3372
|
+
case 14:
|
|
3373
|
+
if (tag !== 114) {
|
|
3374
|
+
break;
|
|
3375
|
+
}
|
|
3376
|
+
message.metadata = reader.string();
|
|
3377
|
+
continue;
|
|
3378
|
+
case 15:
|
|
3379
|
+
if (tag !== 122) {
|
|
3380
|
+
break;
|
|
3381
|
+
}
|
|
3382
|
+
message.metadataHash = reader.bytes();
|
|
3383
|
+
continue;
|
|
3343
3384
|
}
|
|
3344
3385
|
if ((tag & 7) === 4 || tag === 0) {
|
|
3345
3386
|
break;
|
|
@@ -3362,7 +3403,9 @@ var SetProcessTx = {
|
|
|
3362
3403
|
tempSIKs: isSet(object.tempSIKs) ? globalThis.Boolean(object.tempSIKs) : void 0,
|
|
3363
3404
|
duration: isSet(object.duration) ? globalThis.Number(object.duration) : void 0,
|
|
3364
3405
|
censusSize: isSet(object.censusSize) ? globalThis.Number(object.censusSize) : void 0,
|
|
3365
|
-
faucetPackage: isSet(object.faucetPackage) ? FaucetPackage.fromJSON(object.faucetPackage) : void 0
|
|
3406
|
+
faucetPackage: isSet(object.faucetPackage) ? FaucetPackage.fromJSON(object.faucetPackage) : void 0,
|
|
3407
|
+
metadata: isSet(object.metadata) ? globalThis.String(object.metadata) : void 0,
|
|
3408
|
+
metadataHash: isSet(object.metadataHash) ? bytesFromBase64(object.metadataHash) : void 0
|
|
3366
3409
|
};
|
|
3367
3410
|
},
|
|
3368
3411
|
toJSON(message) {
|
|
@@ -3406,6 +3449,12 @@ var SetProcessTx = {
|
|
|
3406
3449
|
if (message.faucetPackage !== void 0) {
|
|
3407
3450
|
obj.faucetPackage = FaucetPackage.toJSON(message.faucetPackage);
|
|
3408
3451
|
}
|
|
3452
|
+
if (message.metadata !== void 0) {
|
|
3453
|
+
obj.metadata = message.metadata;
|
|
3454
|
+
}
|
|
3455
|
+
if (message.metadataHash !== void 0) {
|
|
3456
|
+
obj.metadataHash = base64FromBytes(message.metadataHash);
|
|
3457
|
+
}
|
|
3409
3458
|
return obj;
|
|
3410
3459
|
},
|
|
3411
3460
|
create(base) {
|
|
@@ -3426,6 +3475,8 @@ var SetProcessTx = {
|
|
|
3426
3475
|
message.duration = object.duration ?? void 0;
|
|
3427
3476
|
message.censusSize = object.censusSize ?? void 0;
|
|
3428
3477
|
message.faucetPackage = object.faucetPackage !== void 0 && object.faucetPackage !== null ? FaucetPackage.fromPartial(object.faucetPackage) : void 0;
|
|
3478
|
+
message.metadata = object.metadata ?? void 0;
|
|
3479
|
+
message.metadataHash = object.metadataHash ?? void 0;
|
|
3429
3480
|
return message;
|
|
3430
3481
|
}
|
|
3431
3482
|
};
|
|
@@ -4587,7 +4638,8 @@ function createBaseProcess() {
|
|
|
4587
4638
|
tokenDecimals: void 0,
|
|
4588
4639
|
tempSIKs: void 0,
|
|
4589
4640
|
startTime: 0,
|
|
4590
|
-
duration: 0
|
|
4641
|
+
duration: 0,
|
|
4642
|
+
metadataHash: void 0
|
|
4591
4643
|
};
|
|
4592
4644
|
}
|
|
4593
4645
|
var Process = {
|
|
@@ -4691,6 +4743,9 @@ var Process = {
|
|
|
4691
4743
|
if (message.duration !== 0) {
|
|
4692
4744
|
writer.uint32(288).uint32(message.duration);
|
|
4693
4745
|
}
|
|
4746
|
+
if (message.metadataHash !== void 0) {
|
|
4747
|
+
writer.uint32(298).bytes(message.metadataHash);
|
|
4748
|
+
}
|
|
4694
4749
|
return writer;
|
|
4695
4750
|
},
|
|
4696
4751
|
decode(input, length) {
|
|
@@ -4898,6 +4953,12 @@ var Process = {
|
|
|
4898
4953
|
}
|
|
4899
4954
|
message.duration = reader.uint32();
|
|
4900
4955
|
continue;
|
|
4956
|
+
case 37:
|
|
4957
|
+
if (tag !== 298) {
|
|
4958
|
+
break;
|
|
4959
|
+
}
|
|
4960
|
+
message.metadataHash = reader.bytes();
|
|
4961
|
+
continue;
|
|
4901
4962
|
}
|
|
4902
4963
|
if ((tag & 7) === 4 || tag === 0) {
|
|
4903
4964
|
break;
|
|
@@ -4940,7 +5001,8 @@ var Process = {
|
|
|
4940
5001
|
tokenDecimals: isSet(object.tokenDecimals) ? globalThis.Number(object.tokenDecimals) : void 0,
|
|
4941
5002
|
tempSIKs: isSet(object.tempSIKs) ? globalThis.Boolean(object.tempSIKs) : void 0,
|
|
4942
5003
|
startTime: isSet(object.startTime) ? globalThis.Number(object.startTime) : 0,
|
|
4943
|
-
duration: isSet(object.duration) ? globalThis.Number(object.duration) : 0
|
|
5004
|
+
duration: isSet(object.duration) ? globalThis.Number(object.duration) : 0,
|
|
5005
|
+
metadataHash: isSet(object.metadataHash) ? bytesFromBase64(object.metadataHash) : void 0
|
|
4944
5006
|
};
|
|
4945
5007
|
},
|
|
4946
5008
|
toJSON(message) {
|
|
@@ -5044,6 +5106,9 @@ var Process = {
|
|
|
5044
5106
|
if (message.duration !== 0) {
|
|
5045
5107
|
obj.duration = Math.round(message.duration);
|
|
5046
5108
|
}
|
|
5109
|
+
if (message.metadataHash !== void 0) {
|
|
5110
|
+
obj.metadataHash = base64FromBytes(message.metadataHash);
|
|
5111
|
+
}
|
|
5047
5112
|
return obj;
|
|
5048
5113
|
},
|
|
5049
5114
|
create(base) {
|
|
@@ -5084,6 +5149,7 @@ var Process = {
|
|
|
5084
5149
|
message.tempSIKs = object.tempSIKs ?? void 0;
|
|
5085
5150
|
message.startTime = object.startTime ?? 0;
|
|
5086
5151
|
message.duration = object.duration ?? 0;
|
|
5152
|
+
message.metadataHash = object.metadataHash ?? void 0;
|
|
5087
5153
|
return message;
|
|
5088
5154
|
}
|
|
5089
5155
|
};
|
|
@@ -5304,7 +5370,15 @@ var ProcessMode = {
|
|
|
5304
5370
|
}
|
|
5305
5371
|
};
|
|
5306
5372
|
function createBaseProcessVoteOptions() {
|
|
5307
|
-
return {
|
|
5373
|
+
return {
|
|
5374
|
+
maxCount: 0,
|
|
5375
|
+
maxValue: 0,
|
|
5376
|
+
maxVoteOverwrites: 0,
|
|
5377
|
+
maxTotalCost: 0,
|
|
5378
|
+
costExponent: 0,
|
|
5379
|
+
minValue: 0,
|
|
5380
|
+
minTotalCost: 0
|
|
5381
|
+
};
|
|
5308
5382
|
}
|
|
5309
5383
|
var ProcessVoteOptions = {
|
|
5310
5384
|
encode(message, writer = import_minimal.default.Writer.create()) {
|
|
@@ -5323,6 +5397,12 @@ var ProcessVoteOptions = {
|
|
|
5323
5397
|
if (message.costExponent !== 0) {
|
|
5324
5398
|
writer.uint32(40).uint32(message.costExponent);
|
|
5325
5399
|
}
|
|
5400
|
+
if (message.minValue !== 0) {
|
|
5401
|
+
writer.uint32(48).uint32(message.minValue);
|
|
5402
|
+
}
|
|
5403
|
+
if (message.minTotalCost !== 0) {
|
|
5404
|
+
writer.uint32(56).uint32(message.minTotalCost);
|
|
5405
|
+
}
|
|
5326
5406
|
return writer;
|
|
5327
5407
|
},
|
|
5328
5408
|
decode(input, length) {
|
|
@@ -5362,6 +5442,18 @@ var ProcessVoteOptions = {
|
|
|
5362
5442
|
}
|
|
5363
5443
|
message.costExponent = reader.uint32();
|
|
5364
5444
|
continue;
|
|
5445
|
+
case 6:
|
|
5446
|
+
if (tag !== 48) {
|
|
5447
|
+
break;
|
|
5448
|
+
}
|
|
5449
|
+
message.minValue = reader.uint32();
|
|
5450
|
+
continue;
|
|
5451
|
+
case 7:
|
|
5452
|
+
if (tag !== 56) {
|
|
5453
|
+
break;
|
|
5454
|
+
}
|
|
5455
|
+
message.minTotalCost = reader.uint32();
|
|
5456
|
+
continue;
|
|
5365
5457
|
}
|
|
5366
5458
|
if ((tag & 7) === 4 || tag === 0) {
|
|
5367
5459
|
break;
|
|
@@ -5376,7 +5468,9 @@ var ProcessVoteOptions = {
|
|
|
5376
5468
|
maxValue: isSet(object.maxValue) ? globalThis.Number(object.maxValue) : 0,
|
|
5377
5469
|
maxVoteOverwrites: isSet(object.maxVoteOverwrites) ? globalThis.Number(object.maxVoteOverwrites) : 0,
|
|
5378
5470
|
maxTotalCost: isSet(object.maxTotalCost) ? globalThis.Number(object.maxTotalCost) : 0,
|
|
5379
|
-
costExponent: isSet(object.costExponent) ? globalThis.Number(object.costExponent) : 0
|
|
5471
|
+
costExponent: isSet(object.costExponent) ? globalThis.Number(object.costExponent) : 0,
|
|
5472
|
+
minValue: isSet(object.minValue) ? globalThis.Number(object.minValue) : 0,
|
|
5473
|
+
minTotalCost: isSet(object.minTotalCost) ? globalThis.Number(object.minTotalCost) : 0
|
|
5380
5474
|
};
|
|
5381
5475
|
},
|
|
5382
5476
|
toJSON(message) {
|
|
@@ -5396,6 +5490,12 @@ var ProcessVoteOptions = {
|
|
|
5396
5490
|
if (message.costExponent !== 0) {
|
|
5397
5491
|
obj.costExponent = Math.round(message.costExponent);
|
|
5398
5492
|
}
|
|
5493
|
+
if (message.minValue !== 0) {
|
|
5494
|
+
obj.minValue = Math.round(message.minValue);
|
|
5495
|
+
}
|
|
5496
|
+
if (message.minTotalCost !== 0) {
|
|
5497
|
+
obj.minTotalCost = Math.round(message.minTotalCost);
|
|
5498
|
+
}
|
|
5399
5499
|
return obj;
|
|
5400
5500
|
},
|
|
5401
5501
|
create(base) {
|
|
@@ -5408,6 +5508,8 @@ var ProcessVoteOptions = {
|
|
|
5408
5508
|
message.maxVoteOverwrites = object.maxVoteOverwrites ?? 0;
|
|
5409
5509
|
message.maxTotalCost = object.maxTotalCost ?? 0;
|
|
5410
5510
|
message.costExponent = object.costExponent ?? 0;
|
|
5511
|
+
message.minValue = object.minValue ?? 0;
|
|
5512
|
+
message.minTotalCost = object.minTotalCost ?? 0;
|
|
5411
5513
|
return message;
|
|
5412
5514
|
}
|
|
5413
5515
|
};
|