@sparkdreamnft/sparkdreamjs 0.0.47 → 0.0.49
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/akash/bundle.d.ts +134 -134
- package/akash/bundle.js +150 -150
- package/amino-schema.d.ts +86 -0
- package/amino-schema.js +1 -1
- package/cosmos/bundle.d.ts +160 -160
- package/cosmos/bundle.js +182 -182
- package/esm/akash/bundle.js +150 -150
- package/esm/amino-schema.js +1 -1
- package/esm/cosmos/bundle.js +182 -182
- package/esm/ibc/bundle.js +116 -116
- package/esm/sparkdream/artifact/v1/query.js +125 -0
- package/esm/sparkdream/artifact/v1/query.lcd.js +7 -0
- package/esm/sparkdream/artifact/v1/query.rpc.Query.js +12 -1
- package/esm/sparkdream/artifact/v1/tx.js +13 -1
- package/esm/sparkdream/artifact/v1/types.js +25 -1
- package/esm/sparkdream/blog/v1/genesis.js +97 -1
- package/esm/sparkdream/bundle.js +447 -439
- package/esm/sparkdream/collect/v1/genesis.js +308 -3
- package/esm/sparkdream/collect/v1/tx.js +170 -0
- package/esm/sparkdream/collect/v1/tx.registry.js +20 -2
- package/esm/sparkdream/collect/v1/tx.rpc.msg.js +10 -1
- package/esm/sparkdream/collect/v1/types.js +51 -3
- package/esm/sparkdream/commons/v1/genesis.js +756 -27
- package/esm/sparkdream/commons/v1/group.js +130 -2
- package/esm/sparkdream/commons/v1/poll.js +281 -0
- package/esm/sparkdream/commons/v1/poll_vote.js +107 -0
- package/esm/sparkdream/commons/v1/query.js +759 -0
- package/esm/sparkdream/commons/v1/query.lcd.js +46 -0
- package/esm/sparkdream/commons/v1/query.rpc.Query.js +49 -1
- package/esm/sparkdream/commons/v1/tx.js +730 -4
- package/esm/sparkdream/commons/v1/tx.registry.js +74 -2
- package/esm/sparkdream/commons/v1/tx.rpc.msg.js +25 -1
- package/esm/sparkdream/commons/v1/voter_tree.js +208 -0
- package/esm/sparkdream/federation/v1/genesis.js +212 -2
- package/esm/sparkdream/federation/v1/tx.js +196 -0
- package/esm/sparkdream/federation/v1/tx.registry.js +20 -2
- package/esm/sparkdream/federation/v1/tx.rpc.msg.js +8 -1
- package/esm/sparkdream/federation/v1/types.js +194 -2
- package/esm/sparkdream/forum/v1/archive_metadata.js +13 -1
- package/esm/sparkdream/forum/v1/genesis.js +428 -1
- package/esm/sparkdream/forum/v1/params.js +182 -254
- package/esm/sparkdream/forum/v1/query.js +112 -7
- package/esm/sparkdream/forum/v1/user_reaction_limit.js +62 -1
- package/esm/sparkdream/futarchy/v1/market.js +37 -1
- package/esm/sparkdream/futarchy/v1/tx.js +13 -1
- package/esm/sparkdream/name/v1/dispute.js +13 -1
- package/esm/sparkdream/rep/v1/genesis.js +272 -2
- package/esm/sparkdream/rep/v1/initiative_review.js +13 -1
- package/esm/sparkdream/rep/v1/invitation.js +25 -1
- package/esm/sparkdream/rep/v1/member_report.js +335 -1
- package/esm/sparkdream/rep/v1/migration.js +27 -2
- package/esm/sparkdream/rep/v1/params.js +13 -1
- package/esm/sparkdream/rep/v1/query.js +304 -1
- package/esm/sparkdream/rep/v1/query.lcd.js +19 -0
- package/esm/sparkdream/rep/v1/query.rpc.Query.js +22 -1
- package/esm/sparkdream/rep/v1/stake.js +10 -0
- package/esm/sparkdream/rep/v1/tx.js +372 -14
- package/esm/sparkdream/rep/v1/tx.registry.js +38 -2
- package/esm/sparkdream/rep/v1/tx.rpc.msg.js +16 -2
- package/esm/sparkdream/reveal/v1/types.js +9 -21
- package/esm/sparkdream/season/v1/display_name_moderation.js +40 -1
- package/esm/sparkdream/season/v1/epoch_xp_tracker.js +13 -1
- package/esm/sparkdream/season/v1/genesis.js +125 -1
- package/esm/sparkdream/season/v1/guild_invite.js +13 -1
- package/esm/sparkdream/season/v1/guild_membership.js +13 -1
- package/esm/sparkdream/season/v1/member_profile.js +13 -1
- package/esm/sparkdream/season/v1/member_quest_progress.js +13 -1
- package/esm/sparkdream/season/v1/member_season_snapshot.js +16 -1
- package/esm/sparkdream/season/v1/nomination.js +37 -1
- package/esm/sparkdream/season/v1/query.js +26 -35
- package/esm/sparkdream/season/v1/query.lcd.js +1 -1
- package/esm/sparkdream/season/v1/quest.js +13 -1
- package/esm/sparkdream/season/v1/season.js +13 -1
- package/esm/sparkdream/season/v1/season_stats_counters.js +121 -0
- package/esm/sparkdream/season/v1/season_title_eligibility.js +4 -1
- package/esm/sparkdream/service/v1/genesis.js +126 -1
- package/esm/sparkdream/service/v1/refile_cooldown.js +20 -7
- package/esm/sparkdream/session/v1/genesis.js +303 -1
- package/esm/sparkdream/session/v1/params.js +24 -0
- package/esm/sparkdream/shield/v1/genesis.js +56 -2
- package/esm/sparkdream/shield/v1/params.js +13 -1
- package/esm/sparkdream/shield/v1/types.js +202 -1
- package/esm/sparkdream/vault/v1/genesis.js +25 -1
- package/esm/sparkdream/vault/v1/query.js +15 -2
- package/esm/sparkdream/vault/v1/query.lcd.js +3 -0
- package/esm/sparkdream/vault/v1/tx.js +301 -0
- package/esm/sparkdream/vault/v1/tx.registry.js +38 -2
- package/esm/sparkdream/vault/v1/tx.rpc.msg.js +13 -1
- package/esm/sparkdream/vault/v1/vault_signer.js +15 -2
- package/esm/tendermint/bundle.js +20 -20
- package/ibc/bundle.d.ts +99 -99
- package/ibc/bundle.js +116 -116
- package/package.json +1 -1
- package/sparkdream/artifact/v1/query.d.ts +86 -0
- package/sparkdream/artifact/v1/query.js +126 -1
- package/sparkdream/artifact/v1/query.lcd.d.ts +2 -1
- package/sparkdream/artifact/v1/query.lcd.js +7 -0
- package/sparkdream/artifact/v1/query.rpc.Query.d.ts +9 -1
- package/sparkdream/artifact/v1/query.rpc.Query.js +11 -0
- package/sparkdream/artifact/v1/tx.d.ts +14 -0
- package/sparkdream/artifact/v1/tx.js +13 -1
- package/sparkdream/artifact/v1/types.d.ts +14 -0
- package/sparkdream/artifact/v1/types.js +25 -1
- package/sparkdream/blog/v1/genesis.d.ts +60 -0
- package/sparkdream/blog/v1/genesis.js +98 -2
- package/sparkdream/bundle.d.ts +17133 -16131
- package/sparkdream/bundle.js +447 -439
- package/sparkdream/collect/v1/genesis.d.ts +186 -0
- package/sparkdream/collect/v1/genesis.js +309 -4
- package/sparkdream/collect/v1/tx.d.ts +100 -0
- package/sparkdream/collect/v1/tx.js +171 -1
- package/sparkdream/collect/v1/tx.registry.d.ts +13 -1
- package/sparkdream/collect/v1/tx.registry.js +19 -1
- package/sparkdream/collect/v1/tx.rpc.msg.d.ts +9 -1
- package/sparkdream/collect/v1/tx.rpc.msg.js +9 -0
- package/sparkdream/collect/v1/types.d.ts +52 -0
- package/sparkdream/collect/v1/types.js +51 -3
- package/sparkdream/commons/v1/genesis.d.ts +443 -22
- package/sparkdream/commons/v1/genesis.js +756 -27
- package/sparkdream/commons/v1/group.d.ts +75 -0
- package/sparkdream/commons/v1/group.js +133 -3
- package/sparkdream/commons/v1/poll.d.ts +135 -0
- package/sparkdream/commons/v1/poll.js +286 -0
- package/sparkdream/commons/v1/poll_vote.d.ts +58 -0
- package/sparkdream/commons/v1/poll_vote.js +110 -0
- package/sparkdream/commons/v1/query.d.ts +465 -0
- package/sparkdream/commons/v1/query.js +760 -1
- package/sparkdream/commons/v1/query.lcd.d.ts +6 -1
- package/sparkdream/commons/v1/query.lcd.js +46 -0
- package/sparkdream/commons/v1/query.rpc.Query.d.ts +30 -1
- package/sparkdream/commons/v1/query.rpc.Query.js +48 -0
- package/sparkdream/commons/v1/tx.d.ts +475 -1
- package/sparkdream/commons/v1/tx.js +731 -4
- package/sparkdream/commons/v1/tx.registry.d.ts +49 -1
- package/sparkdream/commons/v1/tx.registry.js +73 -1
- package/sparkdream/commons/v1/tx.rpc.msg.d.ts +13 -1
- package/sparkdream/commons/v1/tx.rpc.msg.js +24 -0
- package/sparkdream/commons/v1/voter_tree.d.ts +132 -0
- package/sparkdream/commons/v1/voter_tree.js +211 -0
- package/sparkdream/federation/v1/genesis.d.ts +136 -1
- package/sparkdream/federation/v1/genesis.js +212 -2
- package/sparkdream/federation/v1/tx.d.ts +138 -0
- package/sparkdream/federation/v1/tx.js +198 -1
- package/sparkdream/federation/v1/tx.registry.d.ts +13 -1
- package/sparkdream/federation/v1/tx.registry.js +19 -1
- package/sparkdream/federation/v1/tx.rpc.msg.d.ts +7 -1
- package/sparkdream/federation/v1/tx.rpc.msg.js +7 -0
- package/sparkdream/federation/v1/types.d.ts +166 -0
- package/sparkdream/federation/v1/types.js +197 -3
- package/sparkdream/forum/v1/archive_metadata.d.ts +12 -0
- package/sparkdream/forum/v1/archive_metadata.js +13 -1
- package/sparkdream/forum/v1/genesis.d.ts +256 -0
- package/sparkdream/forum/v1/genesis.js +429 -2
- package/sparkdream/forum/v1/params.d.ts +0 -30
- package/sparkdream/forum/v1/params.js +182 -254
- package/sparkdream/forum/v1/query.d.ts +70 -0
- package/sparkdream/forum/v1/query.js +112 -7
- package/sparkdream/forum/v1/user_reaction_limit.d.ts +25 -0
- package/sparkdream/forum/v1/user_reaction_limit.js +65 -2
- package/sparkdream/futarchy/v1/market.d.ts +32 -0
- package/sparkdream/futarchy/v1/market.js +37 -1
- package/sparkdream/futarchy/v1/tx.d.ts +10 -0
- package/sparkdream/futarchy/v1/tx.js +13 -1
- package/sparkdream/name/v1/dispute.d.ts +14 -0
- package/sparkdream/name/v1/dispute.js +13 -1
- package/sparkdream/rep/v1/genesis.d.ts +151 -1
- package/sparkdream/rep/v1/genesis.js +272 -2
- package/sparkdream/rep/v1/initiative_review.d.ts +14 -0
- package/sparkdream/rep/v1/initiative_review.js +13 -1
- package/sparkdream/rep/v1/invitation.d.ts +32 -0
- package/sparkdream/rep/v1/invitation.js +25 -1
- package/sparkdream/rep/v1/member_report.d.ts +215 -0
- package/sparkdream/rep/v1/member_report.js +336 -2
- package/sparkdream/rep/v1/migration.d.ts +34 -1
- package/sparkdream/rep/v1/migration.js +27 -2
- package/sparkdream/rep/v1/params.d.ts +18 -0
- package/sparkdream/rep/v1/params.js +13 -1
- package/sparkdream/rep/v1/query.d.ts +187 -1
- package/sparkdream/rep/v1/query.js +304 -1
- package/sparkdream/rep/v1/query.lcd.d.ts +3 -1
- package/sparkdream/rep/v1/query.lcd.js +19 -0
- package/sparkdream/rep/v1/query.rpc.Query.d.ts +16 -1
- package/sparkdream/rep/v1/query.rpc.Query.js +21 -0
- package/sparkdream/rep/v1/stake.d.ts +5 -0
- package/sparkdream/rep/v1/stake.js +10 -0
- package/sparkdream/rep/v1/tx.d.ts +340 -39
- package/sparkdream/rep/v1/tx.js +375 -17
- package/sparkdream/rep/v1/tx.registry.d.ts +25 -1
- package/sparkdream/rep/v1/tx.registry.js +37 -1
- package/sparkdream/rep/v1/tx.rpc.msg.d.ts +12 -2
- package/sparkdream/rep/v1/tx.rpc.msg.js +15 -1
- package/sparkdream/reveal/v1/types.d.ts +0 -8
- package/sparkdream/reveal/v1/types.js +9 -21
- package/sparkdream/rpc.query.d.ts +8 -0
- package/sparkdream/season/v1/display_name_moderation.d.ts +28 -0
- package/sparkdream/season/v1/display_name_moderation.js +40 -1
- package/sparkdream/season/v1/epoch_xp_tracker.d.ts +10 -0
- package/sparkdream/season/v1/epoch_xp_tracker.js +13 -1
- package/sparkdream/season/v1/genesis.d.ts +75 -0
- package/sparkdream/season/v1/genesis.js +126 -2
- package/sparkdream/season/v1/guild_invite.d.ts +10 -0
- package/sparkdream/season/v1/guild_invite.js +13 -1
- package/sparkdream/season/v1/guild_membership.d.ts +12 -0
- package/sparkdream/season/v1/guild_membership.js +13 -1
- package/sparkdream/season/v1/member_profile.d.ts +12 -0
- package/sparkdream/season/v1/member_profile.js +13 -1
- package/sparkdream/season/v1/member_quest_progress.d.ts +8 -0
- package/sparkdream/season/v1/member_quest_progress.js +13 -1
- package/sparkdream/season/v1/member_season_snapshot.d.ts +14 -0
- package/sparkdream/season/v1/member_season_snapshot.js +16 -1
- package/sparkdream/season/v1/nomination.d.ts +32 -0
- package/sparkdream/season/v1/nomination.js +37 -1
- package/sparkdream/season/v1/query.d.ts +10 -6
- package/sparkdream/season/v1/query.js +26 -35
- package/sparkdream/season/v1/query.lcd.js +1 -1
- package/sparkdream/season/v1/quest.d.ts +12 -0
- package/sparkdream/season/v1/quest.js +13 -1
- package/sparkdream/season/v1/season.d.ts +12 -0
- package/sparkdream/season/v1/season.js +13 -1
- package/sparkdream/season/v1/season_stats_counters.d.ts +86 -0
- package/sparkdream/season/v1/season_stats_counters.js +124 -0
- package/sparkdream/season/v1/season_title_eligibility.d.ts +12 -3
- package/sparkdream/season/v1/season_title_eligibility.js +4 -1
- package/sparkdream/service/v1/genesis.d.ts +71 -0
- package/sparkdream/service/v1/genesis.js +127 -2
- package/sparkdream/service/v1/refile_cooldown.d.ts +35 -22
- package/sparkdream/service/v1/refile_cooldown.js +20 -7
- package/sparkdream/session/v1/genesis.d.ts +190 -0
- package/sparkdream/session/v1/genesis.js +304 -2
- package/sparkdream/session/v1/params.d.ts +18 -0
- package/sparkdream/session/v1/params.js +24 -0
- package/sparkdream/shield/v1/genesis.d.ts +37 -1
- package/sparkdream/shield/v1/genesis.js +55 -1
- package/sparkdream/shield/v1/params.d.ts +26 -2
- package/sparkdream/shield/v1/params.js +13 -1
- package/sparkdream/shield/v1/types.d.ts +122 -0
- package/sparkdream/shield/v1/types.js +203 -2
- package/sparkdream/vault/v1/genesis.d.ts +14 -0
- package/sparkdream/vault/v1/genesis.js +25 -1
- package/sparkdream/vault/v1/query.d.ts +16 -3
- package/sparkdream/vault/v1/query.js +15 -2
- package/sparkdream/vault/v1/query.lcd.js +3 -0
- package/sparkdream/vault/v1/tx.d.ts +219 -0
- package/sparkdream/vault/v1/tx.js +302 -1
- package/sparkdream/vault/v1/tx.registry.d.ts +25 -1
- package/sparkdream/vault/v1/tx.registry.js +37 -1
- package/sparkdream/vault/v1/tx.rpc.msg.d.ts +7 -1
- package/sparkdream/vault/v1/tx.rpc.msg.js +12 -0
- package/sparkdream/vault/v1/vault_signer.d.ts +22 -3
- package/sparkdream/vault/v1/vault_signer.js +15 -2
- package/tendermint/bundle.d.ts +844 -844
- package/tendermint/bundle.js +20 -20
|
@@ -1,6 +1,27 @@
|
|
|
1
1
|
import { Any, AnyAmino } from "../../../google/protobuf/any";
|
|
2
2
|
import { BinaryReader, BinaryWriter } from "../../../binary";
|
|
3
3
|
import { DeepPartial } from "../../../helpers";
|
|
4
|
+
/** BallotMode is a group's proposal voting mode. */
|
|
5
|
+
export declare enum BallotMode {
|
|
6
|
+
/**
|
|
7
|
+
* BALLOT_MODE_UNSPECIFIED - UNSPECIFIED is OPEN on a group; on MsgUpdateGroupConfig it leaves the
|
|
8
|
+
* mode unchanged.
|
|
9
|
+
*/
|
|
10
|
+
BALLOT_MODE_UNSPECIFIED = 0,
|
|
11
|
+
/** BALLOT_MODE_OPEN - OPEN: members vote with MsgVoteProposal. */
|
|
12
|
+
BALLOT_MODE_OPEN = 1,
|
|
13
|
+
/**
|
|
14
|
+
* BALLOT_MODE_SECRET - SECRET: every proposal is a secret ballot (MsgAnonymousVoteProposal via
|
|
15
|
+
* x/shield). Needs equal member weights and enough registered ZK keys.
|
|
16
|
+
*/
|
|
17
|
+
BALLOT_MODE_SECRET = 2,
|
|
18
|
+
/** BALLOT_MODE_PROPOSER_CHOICE - PROPOSER_CHOICE: the proposer picks per proposal (secret_ballot). */
|
|
19
|
+
BALLOT_MODE_PROPOSER_CHOICE = 3,
|
|
20
|
+
UNRECOGNIZED = -1
|
|
21
|
+
}
|
|
22
|
+
export declare const BallotModeAmino: typeof BallotMode;
|
|
23
|
+
export declare function ballotModeFromJSON(object: any): BallotMode;
|
|
24
|
+
export declare function ballotModeToJSON(object: BallotMode): string;
|
|
4
25
|
/** ProposalStatus defines the possible states of a council proposal. */
|
|
5
26
|
export declare enum ProposalStatus {
|
|
6
27
|
/** PROPOSAL_STATUS_UNSPECIFIED - PROPOSAL_STATUS_UNSPECIFIED is the default value. */
|
|
@@ -64,6 +85,17 @@ export interface Group {
|
|
|
64
85
|
lastParentUpdate: bigint;
|
|
65
86
|
futarchyEnabled: boolean;
|
|
66
87
|
vetoPolicyAddress: string;
|
|
88
|
+
/**
|
|
89
|
+
* last_config_update is when the parent last changed this group's config
|
|
90
|
+
* with MsgUpdateGroupConfig (unix seconds; 0 = never). update_cooldown
|
|
91
|
+
* throttles the parent from it.
|
|
92
|
+
*/
|
|
93
|
+
lastConfigUpdate: bigint;
|
|
94
|
+
/**
|
|
95
|
+
* ballot_mode decides how the group's proposals are voted. UNSPECIFIED
|
|
96
|
+
* means OPEN.
|
|
97
|
+
*/
|
|
98
|
+
ballotMode: BallotMode;
|
|
67
99
|
}
|
|
68
100
|
export interface GroupProtoMsg {
|
|
69
101
|
typeUrl: "/sparkdream.commons.v1.Group";
|
|
@@ -92,6 +124,17 @@ export interface GroupAmino {
|
|
|
92
124
|
last_parent_update?: string;
|
|
93
125
|
futarchy_enabled?: boolean;
|
|
94
126
|
veto_policy_address?: string;
|
|
127
|
+
/**
|
|
128
|
+
* last_config_update is when the parent last changed this group's config
|
|
129
|
+
* with MsgUpdateGroupConfig (unix seconds; 0 = never). update_cooldown
|
|
130
|
+
* throttles the parent from it.
|
|
131
|
+
*/
|
|
132
|
+
last_config_update?: string;
|
|
133
|
+
/**
|
|
134
|
+
* ballot_mode decides how the group's proposals are voted. UNSPECIFIED
|
|
135
|
+
* means OPEN.
|
|
136
|
+
*/
|
|
137
|
+
ballot_mode?: BallotMode;
|
|
95
138
|
}
|
|
96
139
|
export interface GroupAminoMsg {
|
|
97
140
|
type: "/sparkdream.commons.v1.Group";
|
|
@@ -269,6 +312,22 @@ export interface Proposal {
|
|
|
269
312
|
* failed_reason stores the reason if execution failed
|
|
270
313
|
*/
|
|
271
314
|
failedReason: string;
|
|
315
|
+
/**
|
|
316
|
+
* secret_ballot proposals are voted only with MsgAnonymousVoteProposal,
|
|
317
|
+
* against the voter snapshot taken at submission.
|
|
318
|
+
*/
|
|
319
|
+
secretBallot: boolean;
|
|
320
|
+
/**
|
|
321
|
+
* voter_root is the Merkle root of the voter snapshot (secret ballots).
|
|
322
|
+
*/
|
|
323
|
+
voterRoot: Uint8Array;
|
|
324
|
+
/**
|
|
325
|
+
* ballot_member_count and ballot_member_weight are the group's member
|
|
326
|
+
* count and (equal) member weight at submission; a secret ballot's
|
|
327
|
+
* threshold is computed against them.
|
|
328
|
+
*/
|
|
329
|
+
ballotMemberCount: bigint;
|
|
330
|
+
ballotMemberWeight: string;
|
|
272
331
|
}
|
|
273
332
|
export interface ProposalProtoMsg {
|
|
274
333
|
typeUrl: "/sparkdream.commons.v1.Proposal";
|
|
@@ -326,6 +385,22 @@ export interface ProposalAmino {
|
|
|
326
385
|
* failed_reason stores the reason if execution failed
|
|
327
386
|
*/
|
|
328
387
|
failed_reason?: string;
|
|
388
|
+
/**
|
|
389
|
+
* secret_ballot proposals are voted only with MsgAnonymousVoteProposal,
|
|
390
|
+
* against the voter snapshot taken at submission.
|
|
391
|
+
*/
|
|
392
|
+
secret_ballot?: boolean;
|
|
393
|
+
/**
|
|
394
|
+
* voter_root is the Merkle root of the voter snapshot (secret ballots).
|
|
395
|
+
*/
|
|
396
|
+
voter_root?: string;
|
|
397
|
+
/**
|
|
398
|
+
* ballot_member_count and ballot_member_weight are the group's member
|
|
399
|
+
* count and (equal) member weight at submission; a secret ballot's
|
|
400
|
+
* threshold is computed against them.
|
|
401
|
+
*/
|
|
402
|
+
ballot_member_count?: string;
|
|
403
|
+
ballot_member_weight?: string;
|
|
329
404
|
}
|
|
330
405
|
export interface ProposalAminoMsg {
|
|
331
406
|
type: "/sparkdream.commons.v1.Proposal";
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.AnonVoteTally = exports.TallyResult = exports.Proposal = exports.Vote = exports.DecisionPolicy = exports.Member = exports.Group = exports.VoteOptionAmino = exports.VoteOption = exports.ProposalStatusAmino = exports.ProposalStatus = void 0;
|
|
3
|
+
exports.AnonVoteTally = exports.TallyResult = exports.Proposal = exports.Vote = exports.DecisionPolicy = exports.Member = exports.Group = exports.VoteOptionAmino = exports.VoteOption = exports.ProposalStatusAmino = exports.ProposalStatus = exports.BallotModeAmino = exports.BallotMode = void 0;
|
|
4
|
+
exports.ballotModeFromJSON = ballotModeFromJSON;
|
|
5
|
+
exports.ballotModeToJSON = ballotModeToJSON;
|
|
4
6
|
exports.proposalStatusFromJSON = proposalStatusFromJSON;
|
|
5
7
|
exports.proposalStatusToJSON = proposalStatusToJSON;
|
|
6
8
|
exports.voteOptionFromJSON = voteOptionFromJSON;
|
|
@@ -8,6 +10,62 @@ exports.voteOptionToJSON = voteOptionToJSON;
|
|
|
8
10
|
//@ts-nocheck
|
|
9
11
|
const any_1 = require("../../../google/protobuf/any");
|
|
10
12
|
const binary_1 = require("../../../binary");
|
|
13
|
+
const helpers_1 = require("../../../helpers");
|
|
14
|
+
/** BallotMode is a group's proposal voting mode. */
|
|
15
|
+
var BallotMode;
|
|
16
|
+
(function (BallotMode) {
|
|
17
|
+
/**
|
|
18
|
+
* BALLOT_MODE_UNSPECIFIED - UNSPECIFIED is OPEN on a group; on MsgUpdateGroupConfig it leaves the
|
|
19
|
+
* mode unchanged.
|
|
20
|
+
*/
|
|
21
|
+
BallotMode[BallotMode["BALLOT_MODE_UNSPECIFIED"] = 0] = "BALLOT_MODE_UNSPECIFIED";
|
|
22
|
+
/** BALLOT_MODE_OPEN - OPEN: members vote with MsgVoteProposal. */
|
|
23
|
+
BallotMode[BallotMode["BALLOT_MODE_OPEN"] = 1] = "BALLOT_MODE_OPEN";
|
|
24
|
+
/**
|
|
25
|
+
* BALLOT_MODE_SECRET - SECRET: every proposal is a secret ballot (MsgAnonymousVoteProposal via
|
|
26
|
+
* x/shield). Needs equal member weights and enough registered ZK keys.
|
|
27
|
+
*/
|
|
28
|
+
BallotMode[BallotMode["BALLOT_MODE_SECRET"] = 2] = "BALLOT_MODE_SECRET";
|
|
29
|
+
/** BALLOT_MODE_PROPOSER_CHOICE - PROPOSER_CHOICE: the proposer picks per proposal (secret_ballot). */
|
|
30
|
+
BallotMode[BallotMode["BALLOT_MODE_PROPOSER_CHOICE"] = 3] = "BALLOT_MODE_PROPOSER_CHOICE";
|
|
31
|
+
BallotMode[BallotMode["UNRECOGNIZED"] = -1] = "UNRECOGNIZED";
|
|
32
|
+
})(BallotMode || (exports.BallotMode = BallotMode = {}));
|
|
33
|
+
exports.BallotModeAmino = BallotMode;
|
|
34
|
+
function ballotModeFromJSON(object) {
|
|
35
|
+
switch (object) {
|
|
36
|
+
case 0:
|
|
37
|
+
case "BALLOT_MODE_UNSPECIFIED":
|
|
38
|
+
return BallotMode.BALLOT_MODE_UNSPECIFIED;
|
|
39
|
+
case 1:
|
|
40
|
+
case "BALLOT_MODE_OPEN":
|
|
41
|
+
return BallotMode.BALLOT_MODE_OPEN;
|
|
42
|
+
case 2:
|
|
43
|
+
case "BALLOT_MODE_SECRET":
|
|
44
|
+
return BallotMode.BALLOT_MODE_SECRET;
|
|
45
|
+
case 3:
|
|
46
|
+
case "BALLOT_MODE_PROPOSER_CHOICE":
|
|
47
|
+
return BallotMode.BALLOT_MODE_PROPOSER_CHOICE;
|
|
48
|
+
case -1:
|
|
49
|
+
case "UNRECOGNIZED":
|
|
50
|
+
default:
|
|
51
|
+
return BallotMode.UNRECOGNIZED;
|
|
52
|
+
}
|
|
53
|
+
}
|
|
54
|
+
function ballotModeToJSON(object) {
|
|
55
|
+
switch (object) {
|
|
56
|
+
case BallotMode.BALLOT_MODE_UNSPECIFIED:
|
|
57
|
+
return "BALLOT_MODE_UNSPECIFIED";
|
|
58
|
+
case BallotMode.BALLOT_MODE_OPEN:
|
|
59
|
+
return "BALLOT_MODE_OPEN";
|
|
60
|
+
case BallotMode.BALLOT_MODE_SECRET:
|
|
61
|
+
return "BALLOT_MODE_SECRET";
|
|
62
|
+
case BallotMode.BALLOT_MODE_PROPOSER_CHOICE:
|
|
63
|
+
return "BALLOT_MODE_PROPOSER_CHOICE";
|
|
64
|
+
case BallotMode.UNRECOGNIZED:
|
|
65
|
+
default:
|
|
66
|
+
return "UNRECOGNIZED";
|
|
67
|
+
}
|
|
68
|
+
}
|
|
11
69
|
/** ProposalStatus defines the possible states of a council proposal. */
|
|
12
70
|
var ProposalStatus;
|
|
13
71
|
(function (ProposalStatus) {
|
|
@@ -158,7 +216,9 @@ function createBaseGroup() {
|
|
|
158
216
|
activationTime: BigInt(0),
|
|
159
217
|
lastParentUpdate: BigInt(0),
|
|
160
218
|
futarchyEnabled: false,
|
|
161
|
-
vetoPolicyAddress: ""
|
|
219
|
+
vetoPolicyAddress: "",
|
|
220
|
+
lastConfigUpdate: BigInt(0),
|
|
221
|
+
ballotMode: 0
|
|
162
222
|
};
|
|
163
223
|
}
|
|
164
224
|
/**
|
|
@@ -218,6 +278,12 @@ exports.Group = {
|
|
|
218
278
|
if (message.vetoPolicyAddress !== "") {
|
|
219
279
|
writer.uint32(130).string(message.vetoPolicyAddress);
|
|
220
280
|
}
|
|
281
|
+
if (message.lastConfigUpdate !== BigInt(0)) {
|
|
282
|
+
writer.uint32(136).int64(message.lastConfigUpdate);
|
|
283
|
+
}
|
|
284
|
+
if (message.ballotMode !== 0) {
|
|
285
|
+
writer.uint32(144).int32(message.ballotMode);
|
|
286
|
+
}
|
|
221
287
|
return writer;
|
|
222
288
|
},
|
|
223
289
|
decode(input, length) {
|
|
@@ -275,6 +341,12 @@ exports.Group = {
|
|
|
275
341
|
case 16:
|
|
276
342
|
message.vetoPolicyAddress = reader.string();
|
|
277
343
|
break;
|
|
344
|
+
case 17:
|
|
345
|
+
message.lastConfigUpdate = reader.int64();
|
|
346
|
+
break;
|
|
347
|
+
case 18:
|
|
348
|
+
message.ballotMode = reader.int32();
|
|
349
|
+
break;
|
|
278
350
|
default:
|
|
279
351
|
reader.skipType(tag & 7);
|
|
280
352
|
break;
|
|
@@ -300,6 +372,8 @@ exports.Group = {
|
|
|
300
372
|
message.lastParentUpdate = object.lastParentUpdate !== undefined && object.lastParentUpdate !== null ? BigInt(object.lastParentUpdate.toString()) : BigInt(0);
|
|
301
373
|
message.futarchyEnabled = object.futarchyEnabled ?? false;
|
|
302
374
|
message.vetoPolicyAddress = object.vetoPolicyAddress ?? "";
|
|
375
|
+
message.lastConfigUpdate = object.lastConfigUpdate !== undefined && object.lastConfigUpdate !== null ? BigInt(object.lastConfigUpdate.toString()) : BigInt(0);
|
|
376
|
+
message.ballotMode = object.ballotMode ?? 0;
|
|
303
377
|
return message;
|
|
304
378
|
},
|
|
305
379
|
fromAmino(object) {
|
|
@@ -352,6 +426,12 @@ exports.Group = {
|
|
|
352
426
|
if (object.veto_policy_address !== undefined && object.veto_policy_address !== null) {
|
|
353
427
|
message.vetoPolicyAddress = object.veto_policy_address;
|
|
354
428
|
}
|
|
429
|
+
if (object.last_config_update !== undefined && object.last_config_update !== null) {
|
|
430
|
+
message.lastConfigUpdate = BigInt(object.last_config_update);
|
|
431
|
+
}
|
|
432
|
+
if (object.ballot_mode !== undefined && object.ballot_mode !== null) {
|
|
433
|
+
message.ballotMode = object.ballot_mode;
|
|
434
|
+
}
|
|
355
435
|
return message;
|
|
356
436
|
},
|
|
357
437
|
toAmino(message) {
|
|
@@ -372,6 +452,8 @@ exports.Group = {
|
|
|
372
452
|
obj.last_parent_update = message.lastParentUpdate !== BigInt(0) ? message.lastParentUpdate?.toString() : undefined;
|
|
373
453
|
obj.futarchy_enabled = message.futarchyEnabled === false ? undefined : message.futarchyEnabled;
|
|
374
454
|
obj.veto_policy_address = message.vetoPolicyAddress === "" ? undefined : message.vetoPolicyAddress;
|
|
455
|
+
obj.last_config_update = message.lastConfigUpdate !== BigInt(0) ? message.lastConfigUpdate?.toString() : undefined;
|
|
456
|
+
obj.ballot_mode = message.ballotMode === 0 ? undefined : message.ballotMode;
|
|
375
457
|
return obj;
|
|
376
458
|
},
|
|
377
459
|
fromAminoMsg(object) {
|
|
@@ -718,7 +800,11 @@ function createBaseProposal() {
|
|
|
718
800
|
policyVersion: BigInt(0),
|
|
719
801
|
metadata: "",
|
|
720
802
|
executionTime: BigInt(0),
|
|
721
|
-
failedReason: ""
|
|
803
|
+
failedReason: "",
|
|
804
|
+
secretBallot: false,
|
|
805
|
+
voterRoot: new Uint8Array(),
|
|
806
|
+
ballotMemberCount: BigInt(0),
|
|
807
|
+
ballotMemberWeight: ""
|
|
722
808
|
};
|
|
723
809
|
}
|
|
724
810
|
/**
|
|
@@ -766,6 +852,18 @@ exports.Proposal = {
|
|
|
766
852
|
if (message.failedReason !== "") {
|
|
767
853
|
writer.uint32(98).string(message.failedReason);
|
|
768
854
|
}
|
|
855
|
+
if (message.secretBallot === true) {
|
|
856
|
+
writer.uint32(104).bool(message.secretBallot);
|
|
857
|
+
}
|
|
858
|
+
if (message.voterRoot.length !== 0) {
|
|
859
|
+
writer.uint32(114).bytes(message.voterRoot);
|
|
860
|
+
}
|
|
861
|
+
if (message.ballotMemberCount !== BigInt(0)) {
|
|
862
|
+
writer.uint32(120).uint64(message.ballotMemberCount);
|
|
863
|
+
}
|
|
864
|
+
if (message.ballotMemberWeight !== "") {
|
|
865
|
+
writer.uint32(130).string(message.ballotMemberWeight);
|
|
866
|
+
}
|
|
769
867
|
return writer;
|
|
770
868
|
},
|
|
771
869
|
decode(input, length) {
|
|
@@ -811,6 +909,18 @@ exports.Proposal = {
|
|
|
811
909
|
case 12:
|
|
812
910
|
message.failedReason = reader.string();
|
|
813
911
|
break;
|
|
912
|
+
case 13:
|
|
913
|
+
message.secretBallot = reader.bool();
|
|
914
|
+
break;
|
|
915
|
+
case 14:
|
|
916
|
+
message.voterRoot = reader.bytes();
|
|
917
|
+
break;
|
|
918
|
+
case 15:
|
|
919
|
+
message.ballotMemberCount = reader.uint64();
|
|
920
|
+
break;
|
|
921
|
+
case 16:
|
|
922
|
+
message.ballotMemberWeight = reader.string();
|
|
923
|
+
break;
|
|
814
924
|
default:
|
|
815
925
|
reader.skipType(tag & 7);
|
|
816
926
|
break;
|
|
@@ -832,6 +942,10 @@ exports.Proposal = {
|
|
|
832
942
|
message.metadata = object.metadata ?? "";
|
|
833
943
|
message.executionTime = object.executionTime !== undefined && object.executionTime !== null ? BigInt(object.executionTime.toString()) : BigInt(0);
|
|
834
944
|
message.failedReason = object.failedReason ?? "";
|
|
945
|
+
message.secretBallot = object.secretBallot ?? false;
|
|
946
|
+
message.voterRoot = object.voterRoot ?? new Uint8Array();
|
|
947
|
+
message.ballotMemberCount = object.ballotMemberCount !== undefined && object.ballotMemberCount !== null ? BigInt(object.ballotMemberCount.toString()) : BigInt(0);
|
|
948
|
+
message.ballotMemberWeight = object.ballotMemberWeight ?? "";
|
|
835
949
|
return message;
|
|
836
950
|
},
|
|
837
951
|
fromAmino(object) {
|
|
@@ -870,6 +984,18 @@ exports.Proposal = {
|
|
|
870
984
|
if (object.failed_reason !== undefined && object.failed_reason !== null) {
|
|
871
985
|
message.failedReason = object.failed_reason;
|
|
872
986
|
}
|
|
987
|
+
if (object.secret_ballot !== undefined && object.secret_ballot !== null) {
|
|
988
|
+
message.secretBallot = object.secret_ballot;
|
|
989
|
+
}
|
|
990
|
+
if (object.voter_root !== undefined && object.voter_root !== null) {
|
|
991
|
+
message.voterRoot = (0, helpers_1.bytesFromBase64)(object.voter_root);
|
|
992
|
+
}
|
|
993
|
+
if (object.ballot_member_count !== undefined && object.ballot_member_count !== null) {
|
|
994
|
+
message.ballotMemberCount = BigInt(object.ballot_member_count);
|
|
995
|
+
}
|
|
996
|
+
if (object.ballot_member_weight !== undefined && object.ballot_member_weight !== null) {
|
|
997
|
+
message.ballotMemberWeight = object.ballot_member_weight;
|
|
998
|
+
}
|
|
873
999
|
return message;
|
|
874
1000
|
},
|
|
875
1001
|
toAmino(message) {
|
|
@@ -891,6 +1017,10 @@ exports.Proposal = {
|
|
|
891
1017
|
obj.metadata = message.metadata === "" ? undefined : message.metadata;
|
|
892
1018
|
obj.execution_time = message.executionTime !== BigInt(0) ? message.executionTime?.toString() : undefined;
|
|
893
1019
|
obj.failed_reason = message.failedReason === "" ? undefined : message.failedReason;
|
|
1020
|
+
obj.secret_ballot = message.secretBallot === false ? undefined : message.secretBallot;
|
|
1021
|
+
obj.voter_root = message.voterRoot ? (0, helpers_1.base64FromBytes)(message.voterRoot) : undefined;
|
|
1022
|
+
obj.ballot_member_count = message.ballotMemberCount !== BigInt(0) ? message.ballotMemberCount?.toString() : undefined;
|
|
1023
|
+
obj.ballot_member_weight = message.ballotMemberWeight === "" ? undefined : message.ballotMemberWeight;
|
|
894
1024
|
return obj;
|
|
895
1025
|
},
|
|
896
1026
|
fromAminoMsg(object) {
|
|
@@ -0,0 +1,135 @@
|
|
|
1
|
+
import { BinaryReader, BinaryWriter } from "../../../binary";
|
|
2
|
+
import { DeepPartial } from "../../../helpers";
|
|
3
|
+
/** PollStatus is a poll's lifecycle state. */
|
|
4
|
+
export declare enum PollStatus {
|
|
5
|
+
POLL_STATUS_UNSPECIFIED = 0,
|
|
6
|
+
/** POLL_STATUS_OPEN - OPEN: voting is open until the deadline. */
|
|
7
|
+
POLL_STATUS_OPEN = 1,
|
|
8
|
+
/** POLL_STATUS_CLOSED - CLOSED: the deadline passed; tallies are final. */
|
|
9
|
+
POLL_STATUS_CLOSED = 2,
|
|
10
|
+
/** POLL_STATUS_CANCELLED - CANCELLED: the creator withdrew it before any vote. */
|
|
11
|
+
POLL_STATUS_CANCELLED = 3,
|
|
12
|
+
UNRECOGNIZED = -1
|
|
13
|
+
}
|
|
14
|
+
export declare const PollStatusAmino: typeof PollStatus;
|
|
15
|
+
export declare function pollStatusFromJSON(object: any): PollStatus;
|
|
16
|
+
export declare function pollStatusToJSON(object: PollStatus): string;
|
|
17
|
+
/**
|
|
18
|
+
* Poll is a non-binding, single-choice question put to a group's members.
|
|
19
|
+
* It never executes anything.
|
|
20
|
+
* @name Poll
|
|
21
|
+
* @package sparkdream.commons.v1
|
|
22
|
+
* @see proto type: sparkdream.commons.v1.Poll
|
|
23
|
+
*/
|
|
24
|
+
export interface Poll {
|
|
25
|
+
id: bigint;
|
|
26
|
+
/**
|
|
27
|
+
* council_name is the group whose members vote.
|
|
28
|
+
*/
|
|
29
|
+
councilName: string;
|
|
30
|
+
creator: string;
|
|
31
|
+
question: string;
|
|
32
|
+
options: string[];
|
|
33
|
+
/**
|
|
34
|
+
* secret_ballot polls are voted with MsgAnonymousVotePoll against the
|
|
35
|
+
* voter snapshot taken at opening.
|
|
36
|
+
*/
|
|
37
|
+
secretBallot: boolean;
|
|
38
|
+
openedAt: bigint;
|
|
39
|
+
/**
|
|
40
|
+
* deadline is the unix time voting closes.
|
|
41
|
+
*/
|
|
42
|
+
deadline: bigint;
|
|
43
|
+
status: PollStatus;
|
|
44
|
+
/**
|
|
45
|
+
* tallies[i] counts the votes for options[i] (one member, one vote).
|
|
46
|
+
*/
|
|
47
|
+
tallies: bigint[];
|
|
48
|
+
/**
|
|
49
|
+
* voter_root is the Merkle root of the voter snapshot (secret ballots).
|
|
50
|
+
*/
|
|
51
|
+
voterRoot: Uint8Array;
|
|
52
|
+
/**
|
|
53
|
+
* eligible_voters is the number of members who could vote at opening:
|
|
54
|
+
* the group's member count for an open poll, the snapshot's leaf count
|
|
55
|
+
* (members with a registered ZK key) for a secret one.
|
|
56
|
+
*/
|
|
57
|
+
eligibleVoters: bigint;
|
|
58
|
+
/**
|
|
59
|
+
* closed_at is when the poll closed or was cancelled (0 while open).
|
|
60
|
+
*/
|
|
61
|
+
closedAt: bigint;
|
|
62
|
+
}
|
|
63
|
+
export interface PollProtoMsg {
|
|
64
|
+
typeUrl: "/sparkdream.commons.v1.Poll";
|
|
65
|
+
value: Uint8Array;
|
|
66
|
+
}
|
|
67
|
+
/**
|
|
68
|
+
* Poll is a non-binding, single-choice question put to a group's members.
|
|
69
|
+
* It never executes anything.
|
|
70
|
+
* @name PollAmino
|
|
71
|
+
* @package sparkdream.commons.v1
|
|
72
|
+
* @see proto type: sparkdream.commons.v1.Poll
|
|
73
|
+
*/
|
|
74
|
+
export interface PollAmino {
|
|
75
|
+
id?: string;
|
|
76
|
+
/**
|
|
77
|
+
* council_name is the group whose members vote.
|
|
78
|
+
*/
|
|
79
|
+
council_name?: string;
|
|
80
|
+
creator?: string;
|
|
81
|
+
question?: string;
|
|
82
|
+
options?: string[];
|
|
83
|
+
/**
|
|
84
|
+
* secret_ballot polls are voted with MsgAnonymousVotePoll against the
|
|
85
|
+
* voter snapshot taken at opening.
|
|
86
|
+
*/
|
|
87
|
+
secret_ballot?: boolean;
|
|
88
|
+
opened_at?: string;
|
|
89
|
+
/**
|
|
90
|
+
* deadline is the unix time voting closes.
|
|
91
|
+
*/
|
|
92
|
+
deadline?: string;
|
|
93
|
+
status?: PollStatus;
|
|
94
|
+
/**
|
|
95
|
+
* tallies[i] counts the votes for options[i] (one member, one vote).
|
|
96
|
+
*/
|
|
97
|
+
tallies?: string[];
|
|
98
|
+
/**
|
|
99
|
+
* voter_root is the Merkle root of the voter snapshot (secret ballots).
|
|
100
|
+
*/
|
|
101
|
+
voter_root?: string;
|
|
102
|
+
/**
|
|
103
|
+
* eligible_voters is the number of members who could vote at opening:
|
|
104
|
+
* the group's member count for an open poll, the snapshot's leaf count
|
|
105
|
+
* (members with a registered ZK key) for a secret one.
|
|
106
|
+
*/
|
|
107
|
+
eligible_voters?: string;
|
|
108
|
+
/**
|
|
109
|
+
* closed_at is when the poll closed or was cancelled (0 while open).
|
|
110
|
+
*/
|
|
111
|
+
closed_at?: string;
|
|
112
|
+
}
|
|
113
|
+
export interface PollAminoMsg {
|
|
114
|
+
type: "/sparkdream.commons.v1.Poll";
|
|
115
|
+
value: PollAmino;
|
|
116
|
+
}
|
|
117
|
+
/**
|
|
118
|
+
* Poll is a non-binding, single-choice question put to a group's members.
|
|
119
|
+
* It never executes anything.
|
|
120
|
+
* @name Poll
|
|
121
|
+
* @package sparkdream.commons.v1
|
|
122
|
+
* @see proto type: sparkdream.commons.v1.Poll
|
|
123
|
+
*/
|
|
124
|
+
export declare const Poll: {
|
|
125
|
+
typeUrl: string;
|
|
126
|
+
encode(message: Poll, writer?: BinaryWriter): BinaryWriter;
|
|
127
|
+
decode(input: BinaryReader | Uint8Array, length?: number): Poll;
|
|
128
|
+
fromPartial(object: DeepPartial<Poll>): Poll;
|
|
129
|
+
fromAmino(object: PollAmino): Poll;
|
|
130
|
+
toAmino(message: Poll): PollAmino;
|
|
131
|
+
fromAminoMsg(object: PollAminoMsg): Poll;
|
|
132
|
+
fromProtoMsg(message: PollProtoMsg): Poll;
|
|
133
|
+
toProto(message: Poll): Uint8Array;
|
|
134
|
+
toProtoMsg(message: Poll): PollProtoMsg;
|
|
135
|
+
};
|