decentralcardgame-cardchain-client-ts 0.0.2 → 0.0.3
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/DecentralCardGame.cardchain.cardchain/module.ts +493 -458
- package/DecentralCardGame.cardchain.cardchain/registry.ts +71 -69
- package/DecentralCardGame.cardchain.cardchain/rest.ts +11 -1
- package/DecentralCardGame.cardchain.cardchain/types/cardchain/cardchain/card.ts +33 -6
- package/DecentralCardGame.cardchain.cardchain/types/cardchain/cardchain/council.ts +11 -17
- package/DecentralCardGame.cardchain.cardchain/types/cardchain/cardchain/query.ts +1 -252
- package/DecentralCardGame.cardchain.cardchain/types/cardchain/cardchain/tx.ts +203 -11
- package/DecentralCardGame.cardchain.cardchain/types/cardchain/cardchain/user.ts +8 -77
- package/DecentralCardGame.cardchain.cardchain/types.ts +22 -20
- package/package.json +1 -1
|
@@ -1,86 +1,88 @@
|
|
|
1
1
|
import { GeneratedType } from "@cosmjs/proto-signing";
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
11
|
-
import { MsgApointMatchReporter } from "./types/cardchain/tx";
|
|
12
|
-
import {
|
|
13
|
-
import {
|
|
14
|
-
import {
|
|
15
|
-
import {
|
|
16
|
-
import {
|
|
17
|
-
import {
|
|
18
|
-
import {
|
|
19
|
-
import {
|
|
20
|
-
import {
|
|
21
|
-
import {
|
|
22
|
-
import {
|
|
23
|
-
import {
|
|
24
|
-
import {
|
|
25
|
-
import {
|
|
26
|
-
import {
|
|
27
|
-
import {
|
|
28
|
-
import {
|
|
29
|
-
import {
|
|
30
|
-
import {
|
|
31
|
-
import {
|
|
32
|
-
import {
|
|
33
|
-
import { MsgSetCollectionStoryWriter } from "./types/cardchain/tx";
|
|
34
|
-
import {
|
|
35
|
-
import {
|
|
36
|
-
import {
|
|
37
|
-
import {
|
|
38
|
-
import {
|
|
39
|
-
import {
|
|
40
|
-
import {
|
|
41
|
-
import {
|
|
2
|
+
import { MsgCreateCouncil } from "./types/cardchain/cardchain/tx";
|
|
3
|
+
import { MsgCommitCouncilResponse } from "./types/cardchain/cardchain/tx";
|
|
4
|
+
import { MsgFinalizeCollection } from "./types/cardchain/cardchain/tx";
|
|
5
|
+
import { MsgSetCardRarity } from "./types/cardchain/cardchain/tx";
|
|
6
|
+
import { MsgAddContributorToCollection } from "./types/cardchain/cardchain/tx";
|
|
7
|
+
import { MsgTransferCard } from "./types/cardchain/cardchain/tx";
|
|
8
|
+
import { MsgSetUserBiography } from "./types/cardchain/cardchain/tx";
|
|
9
|
+
import { MsgRemoveSellOffer } from "./types/cardchain/cardchain/tx";
|
|
10
|
+
import { MsgCreateCollection } from "./types/cardchain/cardchain/tx";
|
|
11
|
+
import { MsgApointMatchReporter } from "./types/cardchain/cardchain/tx";
|
|
12
|
+
import { MsgSetProfileCard } from "./types/cardchain/cardchain/tx";
|
|
13
|
+
import { MsgDonateToCard } from "./types/cardchain/cardchain/tx";
|
|
14
|
+
import { MsgRemoveContributorFromCollection } from "./types/cardchain/cardchain/tx";
|
|
15
|
+
import { MsgAddStoryToCollection } from "./types/cardchain/cardchain/tx";
|
|
16
|
+
import { MsgSubmitCopyrightProposal } from "./types/cardchain/cardchain/tx";
|
|
17
|
+
import { MsgMultiVoteCard } from "./types/cardchain/cardchain/tx";
|
|
18
|
+
import { MsgAddArtwork } from "./types/cardchain/cardchain/tx";
|
|
19
|
+
import { MsgRegisterForCouncil } from "./types/cardchain/cardchain/tx";
|
|
20
|
+
import { MsgSetUserWebsite } from "./types/cardchain/cardchain/tx";
|
|
21
|
+
import { MsgSaveCardContent } from "./types/cardchain/cardchain/tx";
|
|
22
|
+
import { MsgOpenBoosterPack } from "./types/cardchain/cardchain/tx";
|
|
23
|
+
import { MsgReportMatch } from "./types/cardchain/cardchain/tx";
|
|
24
|
+
import { MsgBuyCollection } from "./types/cardchain/cardchain/tx";
|
|
25
|
+
import { MsgAddCardToCollection } from "./types/cardchain/cardchain/tx";
|
|
26
|
+
import { MsgSubmitCollectionProposal } from "./types/cardchain/cardchain/tx";
|
|
27
|
+
import { MsgRewokeCouncilRegistration } from "./types/cardchain/cardchain/tx";
|
|
28
|
+
import { MsgVoteCard } from "./types/cardchain/cardchain/tx";
|
|
29
|
+
import { MsgTransferBoosterPack } from "./types/cardchain/cardchain/tx";
|
|
30
|
+
import { MsgRestartCouncil } from "./types/cardchain/cardchain/tx";
|
|
31
|
+
import { MsgBuyCardScheme } from "./types/cardchain/cardchain/tx";
|
|
32
|
+
import { MsgSubmitMatchReporterProposal } from "./types/cardchain/cardchain/tx";
|
|
33
|
+
import { MsgSetCollectionStoryWriter } from "./types/cardchain/cardchain/tx";
|
|
34
|
+
import { MsgCreateuser } from "./types/cardchain/cardchain/tx";
|
|
35
|
+
import { MsgAddArtworkToCollection } from "./types/cardchain/cardchain/tx";
|
|
36
|
+
import { MsgBuyCard } from "./types/cardchain/cardchain/tx";
|
|
37
|
+
import { MsgSetCollectionArtist } from "./types/cardchain/cardchain/tx";
|
|
38
|
+
import { MsgRevealCouncilResponse } from "./types/cardchain/cardchain/tx";
|
|
39
|
+
import { MsgConfirmMatch } from "./types/cardchain/cardchain/tx";
|
|
40
|
+
import { MsgChangeArtist } from "./types/cardchain/cardchain/tx";
|
|
41
|
+
import { MsgCreateSellOffer } from "./types/cardchain/cardchain/tx";
|
|
42
|
+
import { MsgRemoveCardFromCollection } from "./types/cardchain/cardchain/tx";
|
|
42
43
|
|
|
43
44
|
const msgTypes: Array<[string, GeneratedType]> = [
|
|
44
|
-
["/DecentralCardGame.cardchain.cardchain.
|
|
45
|
-
["/DecentralCardGame.cardchain.cardchain.MsgRestartCouncil", MsgRestartCouncil],
|
|
45
|
+
["/DecentralCardGame.cardchain.cardchain.MsgCreateCouncil", MsgCreateCouncil],
|
|
46
46
|
["/DecentralCardGame.cardchain.cardchain.MsgCommitCouncilResponse", MsgCommitCouncilResponse],
|
|
47
|
-
["/DecentralCardGame.cardchain.cardchain.MsgOpenBoosterPack", MsgOpenBoosterPack],
|
|
48
|
-
["/DecentralCardGame.cardchain.cardchain.MsgRemoveCardFromCollection", MsgRemoveCardFromCollection],
|
|
49
|
-
["/DecentralCardGame.cardchain.cardchain.MsgBuyCollection", MsgBuyCollection],
|
|
50
|
-
["/DecentralCardGame.cardchain.cardchain.MsgBuyCard", MsgBuyCard],
|
|
51
|
-
["/DecentralCardGame.cardchain.cardchain.MsgConfirmMatch", MsgConfirmMatch],
|
|
52
|
-
["/DecentralCardGame.cardchain.cardchain.MsgAddArtwork", MsgAddArtwork],
|
|
53
|
-
["/DecentralCardGame.cardchain.cardchain.MsgApointMatchReporter", MsgApointMatchReporter],
|
|
54
|
-
["/DecentralCardGame.cardchain.cardchain.MsgRegisterForCouncil", MsgRegisterForCouncil],
|
|
55
47
|
["/DecentralCardGame.cardchain.cardchain.MsgFinalizeCollection", MsgFinalizeCollection],
|
|
56
|
-
["/DecentralCardGame.cardchain.cardchain.
|
|
48
|
+
["/DecentralCardGame.cardchain.cardchain.MsgSetCardRarity", MsgSetCardRarity],
|
|
57
49
|
["/DecentralCardGame.cardchain.cardchain.MsgAddContributorToCollection", MsgAddContributorToCollection],
|
|
58
|
-
["/DecentralCardGame.cardchain.cardchain.
|
|
50
|
+
["/DecentralCardGame.cardchain.cardchain.MsgTransferCard", MsgTransferCard],
|
|
51
|
+
["/DecentralCardGame.cardchain.cardchain.MsgSetUserBiography", MsgSetUserBiography],
|
|
59
52
|
["/DecentralCardGame.cardchain.cardchain.MsgRemoveSellOffer", MsgRemoveSellOffer],
|
|
60
|
-
["/DecentralCardGame.cardchain.cardchain.
|
|
61
|
-
["/DecentralCardGame.cardchain.cardchain.
|
|
53
|
+
["/DecentralCardGame.cardchain.cardchain.MsgCreateCollection", MsgCreateCollection],
|
|
54
|
+
["/DecentralCardGame.cardchain.cardchain.MsgApointMatchReporter", MsgApointMatchReporter],
|
|
55
|
+
["/DecentralCardGame.cardchain.cardchain.MsgSetProfileCard", MsgSetProfileCard],
|
|
56
|
+
["/DecentralCardGame.cardchain.cardchain.MsgDonateToCard", MsgDonateToCard],
|
|
62
57
|
["/DecentralCardGame.cardchain.cardchain.MsgRemoveContributorFromCollection", MsgRemoveContributorFromCollection],
|
|
58
|
+
["/DecentralCardGame.cardchain.cardchain.MsgAddStoryToCollection", MsgAddStoryToCollection],
|
|
59
|
+
["/DecentralCardGame.cardchain.cardchain.MsgSubmitCopyrightProposal", MsgSubmitCopyrightProposal],
|
|
60
|
+
["/DecentralCardGame.cardchain.cardchain.MsgMultiVoteCard", MsgMultiVoteCard],
|
|
61
|
+
["/DecentralCardGame.cardchain.cardchain.MsgAddArtwork", MsgAddArtwork],
|
|
62
|
+
["/DecentralCardGame.cardchain.cardchain.MsgRegisterForCouncil", MsgRegisterForCouncil],
|
|
63
|
+
["/DecentralCardGame.cardchain.cardchain.MsgSetUserWebsite", MsgSetUserWebsite],
|
|
64
|
+
["/DecentralCardGame.cardchain.cardchain.MsgSaveCardContent", MsgSaveCardContent],
|
|
65
|
+
["/DecentralCardGame.cardchain.cardchain.MsgOpenBoosterPack", MsgOpenBoosterPack],
|
|
66
|
+
["/DecentralCardGame.cardchain.cardchain.MsgReportMatch", MsgReportMatch],
|
|
67
|
+
["/DecentralCardGame.cardchain.cardchain.MsgBuyCollection", MsgBuyCollection],
|
|
68
|
+
["/DecentralCardGame.cardchain.cardchain.MsgAddCardToCollection", MsgAddCardToCollection],
|
|
69
|
+
["/DecentralCardGame.cardchain.cardchain.MsgSubmitCollectionProposal", MsgSubmitCollectionProposal],
|
|
70
|
+
["/DecentralCardGame.cardchain.cardchain.MsgRewokeCouncilRegistration", MsgRewokeCouncilRegistration],
|
|
63
71
|
["/DecentralCardGame.cardchain.cardchain.MsgVoteCard", MsgVoteCard],
|
|
64
|
-
["/DecentralCardGame.cardchain.cardchain.MsgSetProfileCard", MsgSetProfileCard],
|
|
65
72
|
["/DecentralCardGame.cardchain.cardchain.MsgTransferBoosterPack", MsgTransferBoosterPack],
|
|
66
|
-
["/DecentralCardGame.cardchain.cardchain.
|
|
67
|
-
["/DecentralCardGame.cardchain.cardchain.MsgSetUserBiography", MsgSetUserBiography],
|
|
73
|
+
["/DecentralCardGame.cardchain.cardchain.MsgRestartCouncil", MsgRestartCouncil],
|
|
68
74
|
["/DecentralCardGame.cardchain.cardchain.MsgBuyCardScheme", MsgBuyCardScheme],
|
|
69
|
-
["/DecentralCardGame.cardchain.cardchain.MsgAddStoryToCollection", MsgAddStoryToCollection],
|
|
70
|
-
["/DecentralCardGame.cardchain.cardchain.MsgSaveCardContent", MsgSaveCardContent],
|
|
71
75
|
["/DecentralCardGame.cardchain.cardchain.MsgSubmitMatchReporterProposal", MsgSubmitMatchReporterProposal],
|
|
72
|
-
["/DecentralCardGame.cardchain.cardchain.MsgSubmitCopyrightProposal", MsgSubmitCopyrightProposal],
|
|
73
|
-
["/DecentralCardGame.cardchain.cardchain.MsgChangeArtist", MsgChangeArtist],
|
|
74
|
-
["/DecentralCardGame.cardchain.cardchain.MsgTransferCard", MsgTransferCard],
|
|
75
76
|
["/DecentralCardGame.cardchain.cardchain.MsgSetCollectionStoryWriter", MsgSetCollectionStoryWriter],
|
|
76
|
-
["/DecentralCardGame.cardchain.cardchain.
|
|
77
|
-
["/DecentralCardGame.cardchain.cardchain.MsgSetCollectionArtist", MsgSetCollectionArtist],
|
|
78
|
-
["/DecentralCardGame.cardchain.cardchain.MsgCreateCollection", MsgCreateCollection],
|
|
79
|
-
["/DecentralCardGame.cardchain.cardchain.MsgDonateToCard", MsgDonateToCard],
|
|
77
|
+
["/DecentralCardGame.cardchain.cardchain.MsgCreateuser", MsgCreateuser],
|
|
80
78
|
["/DecentralCardGame.cardchain.cardchain.MsgAddArtworkToCollection", MsgAddArtworkToCollection],
|
|
81
|
-
["/DecentralCardGame.cardchain.cardchain.
|
|
82
|
-
["/DecentralCardGame.cardchain.cardchain.
|
|
83
|
-
["/DecentralCardGame.cardchain.cardchain.
|
|
79
|
+
["/DecentralCardGame.cardchain.cardchain.MsgBuyCard", MsgBuyCard],
|
|
80
|
+
["/DecentralCardGame.cardchain.cardchain.MsgSetCollectionArtist", MsgSetCollectionArtist],
|
|
81
|
+
["/DecentralCardGame.cardchain.cardchain.MsgRevealCouncilResponse", MsgRevealCouncilResponse],
|
|
82
|
+
["/DecentralCardGame.cardchain.cardchain.MsgConfirmMatch", MsgConfirmMatch],
|
|
83
|
+
["/DecentralCardGame.cardchain.cardchain.MsgChangeArtist", MsgChangeArtist],
|
|
84
|
+
["/DecentralCardGame.cardchain.cardchain.MsgCreateSellOffer", MsgCreateSellOffer],
|
|
85
|
+
["/DecentralCardGame.cardchain.cardchain.MsgRemoveCardFromCollection", MsgRemoveCardFromCollection],
|
|
84
86
|
|
|
85
87
|
];
|
|
86
88
|
|
|
@@ -126,6 +126,8 @@ export type CardchainMsgDonateToCardResponse = object;
|
|
|
126
126
|
|
|
127
127
|
export type CardchainMsgFinalizeCollectionResponse = object;
|
|
128
128
|
|
|
129
|
+
export type CardchainMsgMultiVoteCardResponse = object;
|
|
130
|
+
|
|
129
131
|
export type CardchainMsgOpenBoosterPackResponse = object;
|
|
130
132
|
|
|
131
133
|
export type CardchainMsgRegisterForCouncilResponse = object;
|
|
@@ -209,6 +211,8 @@ export interface CardchainOutpCard {
|
|
|
209
211
|
|
|
210
212
|
/** @format int64 */
|
|
211
213
|
nerflevel?: string;
|
|
214
|
+
balanceAnchor?: boolean;
|
|
215
|
+
hash?: string;
|
|
212
216
|
}
|
|
213
217
|
|
|
214
218
|
export interface CardchainOutpCollection {
|
|
@@ -385,6 +389,12 @@ export interface CardchainServer {
|
|
|
385
389
|
validReports?: string;
|
|
386
390
|
}
|
|
387
391
|
|
|
392
|
+
export interface CardchainSingleVote {
|
|
393
|
+
/** @format uint64 */
|
|
394
|
+
cardId?: string;
|
|
395
|
+
voteType?: string;
|
|
396
|
+
}
|
|
397
|
+
|
|
388
398
|
export interface CardchainUser {
|
|
389
399
|
alias?: string;
|
|
390
400
|
ownedCardSchemes?: string[];
|
|
@@ -613,7 +623,7 @@ export class HttpClient<SecurityDataType = unknown> {
|
|
|
613
623
|
}
|
|
614
624
|
|
|
615
625
|
/**
|
|
616
|
-
* @title cardchain/card.proto
|
|
626
|
+
* @title cardchain/cardchain/card.proto
|
|
617
627
|
* @version version not set
|
|
618
628
|
*/
|
|
619
629
|
export class Api<SecurityDataType extends unknown> extends HttpClient<SecurityDataType> {
|
|
@@ -14,7 +14,6 @@ export enum Status {
|
|
|
14
14
|
bannedSoon = 6,
|
|
15
15
|
bannedVerySoon = 7,
|
|
16
16
|
none = 8,
|
|
17
|
-
inCouncil = 9,
|
|
18
17
|
UNRECOGNIZED = -1,
|
|
19
18
|
}
|
|
20
19
|
|
|
@@ -47,9 +46,6 @@ export function statusFromJSON(object: any): Status {
|
|
|
47
46
|
case 8:
|
|
48
47
|
case "none":
|
|
49
48
|
return Status.none;
|
|
50
|
-
case 9:
|
|
51
|
-
case "inCouncil":
|
|
52
|
-
return Status.inCouncil;
|
|
53
49
|
case -1:
|
|
54
50
|
case "UNRECOGNIZED":
|
|
55
51
|
default:
|
|
@@ -77,8 +73,6 @@ export function statusToJSON(object: Status): string {
|
|
|
77
73
|
return "bannedVerySoon";
|
|
78
74
|
case Status.none:
|
|
79
75
|
return "none";
|
|
80
|
-
case Status.inCouncil:
|
|
81
|
-
return "inCouncil";
|
|
82
76
|
case Status.UNRECOGNIZED:
|
|
83
77
|
default:
|
|
84
78
|
return "UNRECOGNIZED";
|
|
@@ -100,6 +94,7 @@ export interface Card {
|
|
|
100
94
|
underpoweredVotes: number;
|
|
101
95
|
inappropriateVotes: number;
|
|
102
96
|
nerflevel: number;
|
|
97
|
+
balanceAnchor: boolean;
|
|
103
98
|
}
|
|
104
99
|
|
|
105
100
|
export interface OutpCard {
|
|
@@ -117,6 +112,8 @@ export interface OutpCard {
|
|
|
117
112
|
underpoweredVotes: number;
|
|
118
113
|
inappropriateVotes: number;
|
|
119
114
|
nerflevel: number;
|
|
115
|
+
balanceAnchor: boolean;
|
|
116
|
+
hash: string;
|
|
120
117
|
}
|
|
121
118
|
|
|
122
119
|
function createBaseCard(): Card {
|
|
@@ -135,6 +132,7 @@ function createBaseCard(): Card {
|
|
|
135
132
|
underpoweredVotes: 0,
|
|
136
133
|
inappropriateVotes: 0,
|
|
137
134
|
nerflevel: 0,
|
|
135
|
+
balanceAnchor: false,
|
|
138
136
|
};
|
|
139
137
|
}
|
|
140
138
|
|
|
@@ -182,6 +180,9 @@ export const Card = {
|
|
|
182
180
|
if (message.nerflevel !== 0) {
|
|
183
181
|
writer.uint32(104).int64(message.nerflevel);
|
|
184
182
|
}
|
|
183
|
+
if (message.balanceAnchor === true) {
|
|
184
|
+
writer.uint32(120).bool(message.balanceAnchor);
|
|
185
|
+
}
|
|
185
186
|
return writer;
|
|
186
187
|
},
|
|
187
188
|
|
|
@@ -234,6 +235,9 @@ export const Card = {
|
|
|
234
235
|
case 13:
|
|
235
236
|
message.nerflevel = longToNumber(reader.int64() as Long);
|
|
236
237
|
break;
|
|
238
|
+
case 15:
|
|
239
|
+
message.balanceAnchor = reader.bool();
|
|
240
|
+
break;
|
|
237
241
|
default:
|
|
238
242
|
reader.skipType(tag & 7);
|
|
239
243
|
break;
|
|
@@ -258,6 +262,7 @@ export const Card = {
|
|
|
258
262
|
underpoweredVotes: isSet(object.underpoweredVotes) ? Number(object.underpoweredVotes) : 0,
|
|
259
263
|
inappropriateVotes: isSet(object.inappropriateVotes) ? Number(object.inappropriateVotes) : 0,
|
|
260
264
|
nerflevel: isSet(object.nerflevel) ? Number(object.nerflevel) : 0,
|
|
265
|
+
balanceAnchor: isSet(object.balanceAnchor) ? Boolean(object.balanceAnchor) : false,
|
|
261
266
|
};
|
|
262
267
|
},
|
|
263
268
|
|
|
@@ -282,6 +287,7 @@ export const Card = {
|
|
|
282
287
|
message.underpoweredVotes !== undefined && (obj.underpoweredVotes = Math.round(message.underpoweredVotes));
|
|
283
288
|
message.inappropriateVotes !== undefined && (obj.inappropriateVotes = Math.round(message.inappropriateVotes));
|
|
284
289
|
message.nerflevel !== undefined && (obj.nerflevel = Math.round(message.nerflevel));
|
|
290
|
+
message.balanceAnchor !== undefined && (obj.balanceAnchor = message.balanceAnchor);
|
|
285
291
|
return obj;
|
|
286
292
|
},
|
|
287
293
|
|
|
@@ -301,6 +307,7 @@ export const Card = {
|
|
|
301
307
|
message.underpoweredVotes = object.underpoweredVotes ?? 0;
|
|
302
308
|
message.inappropriateVotes = object.inappropriateVotes ?? 0;
|
|
303
309
|
message.nerflevel = object.nerflevel ?? 0;
|
|
310
|
+
message.balanceAnchor = object.balanceAnchor ?? false;
|
|
304
311
|
return message;
|
|
305
312
|
},
|
|
306
313
|
};
|
|
@@ -321,6 +328,8 @@ function createBaseOutpCard(): OutpCard {
|
|
|
321
328
|
underpoweredVotes: 0,
|
|
322
329
|
inappropriateVotes: 0,
|
|
323
330
|
nerflevel: 0,
|
|
331
|
+
balanceAnchor: false,
|
|
332
|
+
hash: "",
|
|
324
333
|
};
|
|
325
334
|
}
|
|
326
335
|
|
|
@@ -368,6 +377,12 @@ export const OutpCard = {
|
|
|
368
377
|
if (message.nerflevel !== 0) {
|
|
369
378
|
writer.uint32(104).int64(message.nerflevel);
|
|
370
379
|
}
|
|
380
|
+
if (message.balanceAnchor === true) {
|
|
381
|
+
writer.uint32(120).bool(message.balanceAnchor);
|
|
382
|
+
}
|
|
383
|
+
if (message.hash !== "") {
|
|
384
|
+
writer.uint32(130).string(message.hash);
|
|
385
|
+
}
|
|
371
386
|
return writer;
|
|
372
387
|
},
|
|
373
388
|
|
|
@@ -420,6 +435,12 @@ export const OutpCard = {
|
|
|
420
435
|
case 13:
|
|
421
436
|
message.nerflevel = longToNumber(reader.int64() as Long);
|
|
422
437
|
break;
|
|
438
|
+
case 15:
|
|
439
|
+
message.balanceAnchor = reader.bool();
|
|
440
|
+
break;
|
|
441
|
+
case 16:
|
|
442
|
+
message.hash = reader.string();
|
|
443
|
+
break;
|
|
423
444
|
default:
|
|
424
445
|
reader.skipType(tag & 7);
|
|
425
446
|
break;
|
|
@@ -444,6 +465,8 @@ export const OutpCard = {
|
|
|
444
465
|
underpoweredVotes: isSet(object.underpoweredVotes) ? Number(object.underpoweredVotes) : 0,
|
|
445
466
|
inappropriateVotes: isSet(object.inappropriateVotes) ? Number(object.inappropriateVotes) : 0,
|
|
446
467
|
nerflevel: isSet(object.nerflevel) ? Number(object.nerflevel) : 0,
|
|
468
|
+
balanceAnchor: isSet(object.balanceAnchor) ? Boolean(object.balanceAnchor) : false,
|
|
469
|
+
hash: isSet(object.hash) ? String(object.hash) : "",
|
|
447
470
|
};
|
|
448
471
|
},
|
|
449
472
|
|
|
@@ -467,6 +490,8 @@ export const OutpCard = {
|
|
|
467
490
|
message.underpoweredVotes !== undefined && (obj.underpoweredVotes = Math.round(message.underpoweredVotes));
|
|
468
491
|
message.inappropriateVotes !== undefined && (obj.inappropriateVotes = Math.round(message.inappropriateVotes));
|
|
469
492
|
message.nerflevel !== undefined && (obj.nerflevel = Math.round(message.nerflevel));
|
|
493
|
+
message.balanceAnchor !== undefined && (obj.balanceAnchor = message.balanceAnchor);
|
|
494
|
+
message.hash !== undefined && (obj.hash = message.hash);
|
|
470
495
|
return obj;
|
|
471
496
|
},
|
|
472
497
|
|
|
@@ -486,6 +511,8 @@ export const OutpCard = {
|
|
|
486
511
|
message.underpoweredVotes = object.underpoweredVotes ?? 0;
|
|
487
512
|
message.inappropriateVotes = object.inappropriateVotes ?? 0;
|
|
488
513
|
message.nerflevel = object.nerflevel ?? 0;
|
|
514
|
+
message.balanceAnchor = object.balanceAnchor ?? false;
|
|
515
|
+
message.hash = object.hash ?? "";
|
|
489
516
|
return message;
|
|
490
517
|
},
|
|
491
518
|
};
|
|
@@ -44,37 +44,33 @@ export function responseToJSON(object: Response): string {
|
|
|
44
44
|
}
|
|
45
45
|
|
|
46
46
|
export enum CouncelingStatus {
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
suggestionsMade = 6,
|
|
47
|
+
councilOpen = 0,
|
|
48
|
+
councilCreated = 1,
|
|
49
|
+
councilClosed = 2,
|
|
50
|
+
commited = 3,
|
|
51
|
+
revealed = 4,
|
|
52
|
+
suggestionsMade = 5,
|
|
54
53
|
UNRECOGNIZED = -1,
|
|
55
54
|
}
|
|
56
55
|
|
|
57
56
|
export function councelingStatusFromJSON(object: any): CouncelingStatus {
|
|
58
57
|
switch (object) {
|
|
59
58
|
case 0:
|
|
60
|
-
case "councilDoesNotExist":
|
|
61
|
-
return CouncelingStatus.councilDoesNotExist;
|
|
62
|
-
case 1:
|
|
63
59
|
case "councilOpen":
|
|
64
60
|
return CouncelingStatus.councilOpen;
|
|
65
|
-
case
|
|
61
|
+
case 1:
|
|
66
62
|
case "councilCreated":
|
|
67
63
|
return CouncelingStatus.councilCreated;
|
|
68
|
-
case
|
|
64
|
+
case 2:
|
|
69
65
|
case "councilClosed":
|
|
70
66
|
return CouncelingStatus.councilClosed;
|
|
71
|
-
case
|
|
67
|
+
case 3:
|
|
72
68
|
case "commited":
|
|
73
69
|
return CouncelingStatus.commited;
|
|
74
|
-
case
|
|
70
|
+
case 4:
|
|
75
71
|
case "revealed":
|
|
76
72
|
return CouncelingStatus.revealed;
|
|
77
|
-
case
|
|
73
|
+
case 5:
|
|
78
74
|
case "suggestionsMade":
|
|
79
75
|
return CouncelingStatus.suggestionsMade;
|
|
80
76
|
case -1:
|
|
@@ -86,8 +82,6 @@ export function councelingStatusFromJSON(object: any): CouncelingStatus {
|
|
|
86
82
|
|
|
87
83
|
export function councelingStatusToJSON(object: CouncelingStatus): string {
|
|
88
84
|
switch (object) {
|
|
89
|
-
case CouncelingStatus.councilDoesNotExist:
|
|
90
|
-
return "councilDoesNotExist";
|
|
91
85
|
case CouncelingStatus.councilOpen:
|
|
92
86
|
return "councilOpen";
|
|
93
87
|
case CouncelingStatus.councilCreated:
|