@sparkdreamnft/sparkdreamjs 0.0.31 → 0.0.33
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/esm/sparkdream/commons/v1/genesis.js +128 -1
- package/esm/sparkdream/rep/v1/challenge.js +13 -0
- package/esm/sparkdream/rep/v1/initiative.js +24 -1
- package/esm/sparkdream/rep/v1/params.js +37 -1
- package/esm/sparkdream/rep/v1/query.js +126 -120
- package/esm/sparkdream/rep/v1/query.lcd.js +21 -9
- package/esm/sparkdream/rep/v1/query.rpc.Query.js +3 -9
- package/esm/sparkdream/rep/v1/tx.js +157 -0
- package/esm/sparkdream/rep/v1/tx.registry.js +20 -2
- package/esm/sparkdream/rep/v1/tx.rpc.msg.js +7 -1
- package/package.json +1 -1
- package/sparkdream/bundle.d.ts +56 -6
- package/sparkdream/commons/v1/genesis.d.ts +114 -0
- package/sparkdream/commons/v1/genesis.js +129 -2
- package/sparkdream/rep/v1/challenge.d.ts +8 -0
- package/sparkdream/rep/v1/challenge.js +13 -0
- package/sparkdream/rep/v1/initiative.d.ts +16 -0
- package/sparkdream/rep/v1/initiative.js +24 -1
- package/sparkdream/rep/v1/params.d.ts +36 -0
- package/sparkdream/rep/v1/params.js +37 -1
- package/sparkdream/rep/v1/query.d.ts +97 -20
- package/sparkdream/rep/v1/query.js +126 -120
- package/sparkdream/rep/v1/query.lcd.d.ts +3 -3
- package/sparkdream/rep/v1/query.lcd.js +21 -9
- package/sparkdream/rep/v1/query.rpc.Query.d.ts +9 -9
- package/sparkdream/rep/v1/query.rpc.Query.js +3 -9
- package/sparkdream/rep/v1/tx.d.ts +95 -0
- package/sparkdream/rep/v1/tx.js +158 -1
- package/sparkdream/rep/v1/tx.registry.d.ts +13 -1
- package/sparkdream/rep/v1/tx.registry.js +19 -1
- package/sparkdream/rep/v1/tx.rpc.msg.d.ts +4 -1
- package/sparkdream/rep/v1/tx.rpc.msg.js +6 -0
- package/sparkdream/rpc.query.d.ts +3 -3
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.ProposalVotes = exports.PolicyVersionEntry = exports.PolicyWithAddress = exports.CouncilMembers = exports.GenesisState = void 0;
|
|
3
|
+
exports.ProposalVotes = exports.PolicyVersionEntry = exports.PolicyWithAddress = exports.CouncilMembers = exports.FoundingMember = exports.GenesisState = void 0;
|
|
4
4
|
//@ts-nocheck
|
|
5
5
|
const params_1 = require("./params");
|
|
6
6
|
const policy_permissions_1 = require("./policy_permissions");
|
|
@@ -23,7 +23,8 @@ function createBaseGenesisState() {
|
|
|
23
23
|
categoryMap: [],
|
|
24
24
|
nextCategoryId: BigInt(0),
|
|
25
25
|
recurringSpends: [],
|
|
26
|
-
nextRecurringSpendId: BigInt(0)
|
|
26
|
+
nextRecurringSpendId: BigInt(0),
|
|
27
|
+
foundingMembers: []
|
|
27
28
|
};
|
|
28
29
|
}
|
|
29
30
|
/**
|
|
@@ -77,6 +78,9 @@ exports.GenesisState = {
|
|
|
77
78
|
if (message.nextRecurringSpendId !== BigInt(0)) {
|
|
78
79
|
writer.uint32(112).uint64(message.nextRecurringSpendId);
|
|
79
80
|
}
|
|
81
|
+
for (const v of message.foundingMembers) {
|
|
82
|
+
exports.FoundingMember.encode(v, writer.uint32(122).fork()).ldelim();
|
|
83
|
+
}
|
|
80
84
|
return writer;
|
|
81
85
|
},
|
|
82
86
|
decode(input, length) {
|
|
@@ -128,6 +132,9 @@ exports.GenesisState = {
|
|
|
128
132
|
case 14:
|
|
129
133
|
message.nextRecurringSpendId = reader.uint64();
|
|
130
134
|
break;
|
|
135
|
+
case 15:
|
|
136
|
+
message.foundingMembers.push(exports.FoundingMember.decode(reader, reader.uint32()));
|
|
137
|
+
break;
|
|
131
138
|
default:
|
|
132
139
|
reader.skipType(tag & 7);
|
|
133
140
|
break;
|
|
@@ -151,6 +158,7 @@ exports.GenesisState = {
|
|
|
151
158
|
message.nextCategoryId = object.nextCategoryId !== undefined && object.nextCategoryId !== null ? BigInt(object.nextCategoryId.toString()) : BigInt(0);
|
|
152
159
|
message.recurringSpends = object.recurringSpends?.map(e => recurring_spend_1.RecurringSpend.fromPartial(e)) || [];
|
|
153
160
|
message.nextRecurringSpendId = object.nextRecurringSpendId !== undefined && object.nextRecurringSpendId !== null ? BigInt(object.nextRecurringSpendId.toString()) : BigInt(0);
|
|
161
|
+
message.foundingMembers = object.foundingMembers?.map(e => exports.FoundingMember.fromPartial(e)) || [];
|
|
154
162
|
return message;
|
|
155
163
|
},
|
|
156
164
|
fromAmino(object) {
|
|
@@ -179,6 +187,7 @@ exports.GenesisState = {
|
|
|
179
187
|
if (object.next_recurring_spend_id !== undefined && object.next_recurring_spend_id !== null) {
|
|
180
188
|
message.nextRecurringSpendId = BigInt(object.next_recurring_spend_id);
|
|
181
189
|
}
|
|
190
|
+
message.foundingMembers = object.founding_members?.map(e => exports.FoundingMember.fromAmino(e)) || [];
|
|
182
191
|
return message;
|
|
183
192
|
},
|
|
184
193
|
toAmino(message) {
|
|
@@ -242,6 +251,12 @@ exports.GenesisState = {
|
|
|
242
251
|
obj.recurring_spends = message.recurringSpends;
|
|
243
252
|
}
|
|
244
253
|
obj.next_recurring_spend_id = message.nextRecurringSpendId !== BigInt(0) ? message.nextRecurringSpendId?.toString() : undefined;
|
|
254
|
+
if (message.foundingMembers) {
|
|
255
|
+
obj.founding_members = message.foundingMembers.map(e => e ? exports.FoundingMember.toAmino(e) : undefined);
|
|
256
|
+
}
|
|
257
|
+
else {
|
|
258
|
+
obj.founding_members = message.foundingMembers;
|
|
259
|
+
}
|
|
245
260
|
return obj;
|
|
246
261
|
},
|
|
247
262
|
fromAminoMsg(object) {
|
|
@@ -260,6 +275,118 @@ exports.GenesisState = {
|
|
|
260
275
|
};
|
|
261
276
|
}
|
|
262
277
|
};
|
|
278
|
+
function createBaseFoundingMember() {
|
|
279
|
+
return {
|
|
280
|
+
address: "",
|
|
281
|
+
displayName: "",
|
|
282
|
+
handles: [],
|
|
283
|
+
founder: false
|
|
284
|
+
};
|
|
285
|
+
}
|
|
286
|
+
/**
|
|
287
|
+
* FoundingMember is one governance founding member for the InitGenesis
|
|
288
|
+
* bootstrap: a seat on the founding councils, a seeded x/name display name,
|
|
289
|
+
* and optionally pre-claimed x/name handles (first handle becomes primary).
|
|
290
|
+
* Exactly one entry must set founder=true; that account additionally anchors
|
|
291
|
+
* the Technical and Ecosystem councils and their committees.
|
|
292
|
+
* @name FoundingMember
|
|
293
|
+
* @package sparkdream.commons.v1
|
|
294
|
+
* @see proto type: sparkdream.commons.v1.FoundingMember
|
|
295
|
+
*/
|
|
296
|
+
exports.FoundingMember = {
|
|
297
|
+
typeUrl: "/sparkdream.commons.v1.FoundingMember",
|
|
298
|
+
encode(message, writer = binary_1.BinaryWriter.create()) {
|
|
299
|
+
if (message.address !== "") {
|
|
300
|
+
writer.uint32(10).string(message.address);
|
|
301
|
+
}
|
|
302
|
+
if (message.displayName !== "") {
|
|
303
|
+
writer.uint32(18).string(message.displayName);
|
|
304
|
+
}
|
|
305
|
+
for (const v of message.handles) {
|
|
306
|
+
writer.uint32(26).string(v);
|
|
307
|
+
}
|
|
308
|
+
if (message.founder === true) {
|
|
309
|
+
writer.uint32(32).bool(message.founder);
|
|
310
|
+
}
|
|
311
|
+
return writer;
|
|
312
|
+
},
|
|
313
|
+
decode(input, length) {
|
|
314
|
+
const reader = input instanceof binary_1.BinaryReader ? input : new binary_1.BinaryReader(input);
|
|
315
|
+
let end = length === undefined ? reader.len : reader.pos + length;
|
|
316
|
+
const message = createBaseFoundingMember();
|
|
317
|
+
while (reader.pos < end) {
|
|
318
|
+
const tag = reader.uint32();
|
|
319
|
+
switch (tag >>> 3) {
|
|
320
|
+
case 1:
|
|
321
|
+
message.address = reader.string();
|
|
322
|
+
break;
|
|
323
|
+
case 2:
|
|
324
|
+
message.displayName = reader.string();
|
|
325
|
+
break;
|
|
326
|
+
case 3:
|
|
327
|
+
message.handles.push(reader.string());
|
|
328
|
+
break;
|
|
329
|
+
case 4:
|
|
330
|
+
message.founder = reader.bool();
|
|
331
|
+
break;
|
|
332
|
+
default:
|
|
333
|
+
reader.skipType(tag & 7);
|
|
334
|
+
break;
|
|
335
|
+
}
|
|
336
|
+
}
|
|
337
|
+
return message;
|
|
338
|
+
},
|
|
339
|
+
fromPartial(object) {
|
|
340
|
+
const message = createBaseFoundingMember();
|
|
341
|
+
message.address = object.address ?? "";
|
|
342
|
+
message.displayName = object.displayName ?? "";
|
|
343
|
+
message.handles = object.handles?.map(e => e) || [];
|
|
344
|
+
message.founder = object.founder ?? false;
|
|
345
|
+
return message;
|
|
346
|
+
},
|
|
347
|
+
fromAmino(object) {
|
|
348
|
+
const message = createBaseFoundingMember();
|
|
349
|
+
if (object.address !== undefined && object.address !== null) {
|
|
350
|
+
message.address = object.address;
|
|
351
|
+
}
|
|
352
|
+
if (object.display_name !== undefined && object.display_name !== null) {
|
|
353
|
+
message.displayName = object.display_name;
|
|
354
|
+
}
|
|
355
|
+
message.handles = object.handles?.map(e => e) || [];
|
|
356
|
+
if (object.founder !== undefined && object.founder !== null) {
|
|
357
|
+
message.founder = object.founder;
|
|
358
|
+
}
|
|
359
|
+
return message;
|
|
360
|
+
},
|
|
361
|
+
toAmino(message) {
|
|
362
|
+
const obj = {};
|
|
363
|
+
obj.address = message.address === "" ? undefined : message.address;
|
|
364
|
+
obj.display_name = message.displayName === "" ? undefined : message.displayName;
|
|
365
|
+
if (message.handles) {
|
|
366
|
+
obj.handles = message.handles.map(e => e);
|
|
367
|
+
}
|
|
368
|
+
else {
|
|
369
|
+
obj.handles = message.handles;
|
|
370
|
+
}
|
|
371
|
+
obj.founder = message.founder === false ? undefined : message.founder;
|
|
372
|
+
return obj;
|
|
373
|
+
},
|
|
374
|
+
fromAminoMsg(object) {
|
|
375
|
+
return exports.FoundingMember.fromAmino(object.value);
|
|
376
|
+
},
|
|
377
|
+
fromProtoMsg(message) {
|
|
378
|
+
return exports.FoundingMember.decode(message.value);
|
|
379
|
+
},
|
|
380
|
+
toProto(message) {
|
|
381
|
+
return exports.FoundingMember.encode(message).finish();
|
|
382
|
+
},
|
|
383
|
+
toProtoMsg(message) {
|
|
384
|
+
return {
|
|
385
|
+
typeUrl: "/sparkdream.commons.v1.FoundingMember",
|
|
386
|
+
value: exports.FoundingMember.encode(message).finish()
|
|
387
|
+
};
|
|
388
|
+
}
|
|
389
|
+
};
|
|
263
390
|
function createBaseCouncilMembers() {
|
|
264
391
|
return {
|
|
265
392
|
councilName: "",
|
|
@@ -5,6 +5,14 @@ export declare enum ChallengeStatus {
|
|
|
5
5
|
CHALLENGE_STATUS_IN_JURY_REVIEW = 1,
|
|
6
6
|
CHALLENGE_STATUS_UPHELD = 2,
|
|
7
7
|
CHALLENGE_STATUS_REJECTED = 3,
|
|
8
|
+
/**
|
|
9
|
+
* CHALLENGE_STATUS_VOIDED - VOIDED terminates a challenge without a verdict when the underlying
|
|
10
|
+
* initiative is discarded out from under it — specifically when the parent
|
|
11
|
+
* project is cancelled. The challenger's stake is refunded in full (no burn,
|
|
12
|
+
* no reward) because the dispute was never adjudicated; any pending jury
|
|
13
|
+
* review is closed INCONCLUSIVE.
|
|
14
|
+
*/
|
|
15
|
+
CHALLENGE_STATUS_VOIDED = 4,
|
|
8
16
|
UNRECOGNIZED = -1
|
|
9
17
|
}
|
|
10
18
|
export declare const ChallengeStatusAmino: typeof ChallengeStatus;
|
|
@@ -11,6 +11,14 @@ var ChallengeStatus;
|
|
|
11
11
|
ChallengeStatus[ChallengeStatus["CHALLENGE_STATUS_IN_JURY_REVIEW"] = 1] = "CHALLENGE_STATUS_IN_JURY_REVIEW";
|
|
12
12
|
ChallengeStatus[ChallengeStatus["CHALLENGE_STATUS_UPHELD"] = 2] = "CHALLENGE_STATUS_UPHELD";
|
|
13
13
|
ChallengeStatus[ChallengeStatus["CHALLENGE_STATUS_REJECTED"] = 3] = "CHALLENGE_STATUS_REJECTED";
|
|
14
|
+
/**
|
|
15
|
+
* CHALLENGE_STATUS_VOIDED - VOIDED terminates a challenge without a verdict when the underlying
|
|
16
|
+
* initiative is discarded out from under it — specifically when the parent
|
|
17
|
+
* project is cancelled. The challenger's stake is refunded in full (no burn,
|
|
18
|
+
* no reward) because the dispute was never adjudicated; any pending jury
|
|
19
|
+
* review is closed INCONCLUSIVE.
|
|
20
|
+
*/
|
|
21
|
+
ChallengeStatus[ChallengeStatus["CHALLENGE_STATUS_VOIDED"] = 4] = "CHALLENGE_STATUS_VOIDED";
|
|
14
22
|
ChallengeStatus[ChallengeStatus["UNRECOGNIZED"] = -1] = "UNRECOGNIZED";
|
|
15
23
|
})(ChallengeStatus || (exports.ChallengeStatus = ChallengeStatus = {}));
|
|
16
24
|
exports.ChallengeStatusAmino = ChallengeStatus;
|
|
@@ -28,6 +36,9 @@ function challengeStatusFromJSON(object) {
|
|
|
28
36
|
case 3:
|
|
29
37
|
case "CHALLENGE_STATUS_REJECTED":
|
|
30
38
|
return ChallengeStatus.CHALLENGE_STATUS_REJECTED;
|
|
39
|
+
case 4:
|
|
40
|
+
case "CHALLENGE_STATUS_VOIDED":
|
|
41
|
+
return ChallengeStatus.CHALLENGE_STATUS_VOIDED;
|
|
31
42
|
case -1:
|
|
32
43
|
case "UNRECOGNIZED":
|
|
33
44
|
default:
|
|
@@ -44,6 +55,8 @@ function challengeStatusToJSON(object) {
|
|
|
44
55
|
return "CHALLENGE_STATUS_UPHELD";
|
|
45
56
|
case ChallengeStatus.CHALLENGE_STATUS_REJECTED:
|
|
46
57
|
return "CHALLENGE_STATUS_REJECTED";
|
|
58
|
+
case ChallengeStatus.CHALLENGE_STATUS_VOIDED:
|
|
59
|
+
return "CHALLENGE_STATUS_VOIDED";
|
|
47
60
|
case ChallengeStatus.UNRECOGNIZED:
|
|
48
61
|
default:
|
|
49
62
|
return "UNRECOGNIZED";
|
|
@@ -35,6 +35,12 @@ export declare enum InitiativeStatus {
|
|
|
35
35
|
INITIATIVE_STATUS_COMPLETED = 5,
|
|
36
36
|
INITIATIVE_STATUS_REJECTED = 6,
|
|
37
37
|
INITIATIVE_STATUS_ABANDONED = 7,
|
|
38
|
+
/**
|
|
39
|
+
* INITIATIVE_STATUS_CANCELLED - Retired by the project creator (or Operations Committee) while still
|
|
40
|
+
* OPEN and unassigned. Distinct from ABANDONED, which records an assignee
|
|
41
|
+
* walking away from work they had taken on.
|
|
42
|
+
*/
|
|
43
|
+
INITIATIVE_STATUS_CANCELLED = 8,
|
|
38
44
|
UNRECOGNIZED = -1
|
|
39
45
|
}
|
|
40
46
|
export declare const InitiativeStatusAmino: typeof InitiativeStatus;
|
|
@@ -75,6 +81,11 @@ export interface Initiative {
|
|
|
75
81
|
* Conviction propagated from linked content
|
|
76
82
|
*/
|
|
77
83
|
propagatedConviction: string;
|
|
84
|
+
/**
|
|
85
|
+
* DREAM locked by a self-assigning project creator (budget-backed projects
|
|
86
|
+
* only). Returned on completion/abandonment, burned on upheld challenge.
|
|
87
|
+
*/
|
|
88
|
+
selfAssignBond: string;
|
|
78
89
|
}
|
|
79
90
|
export interface InitiativeProtoMsg {
|
|
80
91
|
typeUrl: "/sparkdream.rep.v1.Initiative";
|
|
@@ -115,6 +126,11 @@ export interface InitiativeAmino {
|
|
|
115
126
|
* Conviction propagated from linked content
|
|
116
127
|
*/
|
|
117
128
|
propagated_conviction?: string;
|
|
129
|
+
/**
|
|
130
|
+
* DREAM locked by a self-assigning project creator (budget-backed projects
|
|
131
|
+
* only). Returned on completion/abandonment, burned on upheld challenge.
|
|
132
|
+
*/
|
|
133
|
+
self_assign_bond?: string;
|
|
118
134
|
}
|
|
119
135
|
export interface InitiativeAminoMsg {
|
|
120
136
|
type: "/sparkdream.rep.v1.Initiative";
|
|
@@ -144,6 +144,12 @@ var InitiativeStatus;
|
|
|
144
144
|
InitiativeStatus[InitiativeStatus["INITIATIVE_STATUS_COMPLETED"] = 5] = "INITIATIVE_STATUS_COMPLETED";
|
|
145
145
|
InitiativeStatus[InitiativeStatus["INITIATIVE_STATUS_REJECTED"] = 6] = "INITIATIVE_STATUS_REJECTED";
|
|
146
146
|
InitiativeStatus[InitiativeStatus["INITIATIVE_STATUS_ABANDONED"] = 7] = "INITIATIVE_STATUS_ABANDONED";
|
|
147
|
+
/**
|
|
148
|
+
* INITIATIVE_STATUS_CANCELLED - Retired by the project creator (or Operations Committee) while still
|
|
149
|
+
* OPEN and unassigned. Distinct from ABANDONED, which records an assignee
|
|
150
|
+
* walking away from work they had taken on.
|
|
151
|
+
*/
|
|
152
|
+
InitiativeStatus[InitiativeStatus["INITIATIVE_STATUS_CANCELLED"] = 8] = "INITIATIVE_STATUS_CANCELLED";
|
|
147
153
|
InitiativeStatus[InitiativeStatus["UNRECOGNIZED"] = -1] = "UNRECOGNIZED";
|
|
148
154
|
})(InitiativeStatus || (exports.InitiativeStatus = InitiativeStatus = {}));
|
|
149
155
|
exports.InitiativeStatusAmino = InitiativeStatus;
|
|
@@ -173,6 +179,9 @@ function initiativeStatusFromJSON(object) {
|
|
|
173
179
|
case 7:
|
|
174
180
|
case "INITIATIVE_STATUS_ABANDONED":
|
|
175
181
|
return InitiativeStatus.INITIATIVE_STATUS_ABANDONED;
|
|
182
|
+
case 8:
|
|
183
|
+
case "INITIATIVE_STATUS_CANCELLED":
|
|
184
|
+
return InitiativeStatus.INITIATIVE_STATUS_CANCELLED;
|
|
176
185
|
case -1:
|
|
177
186
|
case "UNRECOGNIZED":
|
|
178
187
|
default:
|
|
@@ -197,6 +206,8 @@ function initiativeStatusToJSON(object) {
|
|
|
197
206
|
return "INITIATIVE_STATUS_REJECTED";
|
|
198
207
|
case InitiativeStatus.INITIATIVE_STATUS_ABANDONED:
|
|
199
208
|
return "INITIATIVE_STATUS_ABANDONED";
|
|
209
|
+
case InitiativeStatus.INITIATIVE_STATUS_CANCELLED:
|
|
210
|
+
return "INITIATIVE_STATUS_CANCELLED";
|
|
200
211
|
case InitiativeStatus.UNRECOGNIZED:
|
|
201
212
|
default:
|
|
202
213
|
return "UNRECOGNIZED";
|
|
@@ -228,7 +239,8 @@ function createBaseInitiative() {
|
|
|
228
239
|
status: 0,
|
|
229
240
|
createdAt: BigInt(0),
|
|
230
241
|
completedAt: BigInt(0),
|
|
231
|
-
propagatedConviction: ""
|
|
242
|
+
propagatedConviction: "",
|
|
243
|
+
selfAssignBond: ""
|
|
232
244
|
};
|
|
233
245
|
}
|
|
234
246
|
/**
|
|
@@ -315,6 +327,9 @@ exports.Initiative = {
|
|
|
315
327
|
if (message.propagatedConviction !== "") {
|
|
316
328
|
writer.uint32(202).string(math_1.Decimal.fromUserInput(message.propagatedConviction, 18).atomics);
|
|
317
329
|
}
|
|
330
|
+
if (message.selfAssignBond !== "") {
|
|
331
|
+
writer.uint32(210).string(message.selfAssignBond);
|
|
332
|
+
}
|
|
318
333
|
return writer;
|
|
319
334
|
},
|
|
320
335
|
decode(input, length) {
|
|
@@ -399,6 +414,9 @@ exports.Initiative = {
|
|
|
399
414
|
case 25:
|
|
400
415
|
message.propagatedConviction = math_1.Decimal.fromAtomics(reader.string(), 18).toString();
|
|
401
416
|
break;
|
|
417
|
+
case 26:
|
|
418
|
+
message.selfAssignBond = reader.string();
|
|
419
|
+
break;
|
|
402
420
|
default:
|
|
403
421
|
reader.skipType(tag & 7);
|
|
404
422
|
break;
|
|
@@ -433,6 +451,7 @@ exports.Initiative = {
|
|
|
433
451
|
message.createdAt = object.createdAt !== undefined && object.createdAt !== null ? BigInt(object.createdAt.toString()) : BigInt(0);
|
|
434
452
|
message.completedAt = object.completedAt !== undefined && object.completedAt !== null ? BigInt(object.completedAt.toString()) : BigInt(0);
|
|
435
453
|
message.propagatedConviction = object.propagatedConviction ?? "";
|
|
454
|
+
message.selfAssignBond = object.selfAssignBond ?? "";
|
|
436
455
|
return message;
|
|
437
456
|
},
|
|
438
457
|
fromAmino(object) {
|
|
@@ -508,6 +527,9 @@ exports.Initiative = {
|
|
|
508
527
|
if (object.propagated_conviction !== undefined && object.propagated_conviction !== null) {
|
|
509
528
|
message.propagatedConviction = object.propagated_conviction;
|
|
510
529
|
}
|
|
530
|
+
if (object.self_assign_bond !== undefined && object.self_assign_bond !== null) {
|
|
531
|
+
message.selfAssignBond = object.self_assign_bond;
|
|
532
|
+
}
|
|
511
533
|
return message;
|
|
512
534
|
},
|
|
513
535
|
toAmino(message) {
|
|
@@ -547,6 +569,7 @@ exports.Initiative = {
|
|
|
547
569
|
obj.created_at = message.createdAt !== BigInt(0) ? message.createdAt?.toString() : undefined;
|
|
548
570
|
obj.completed_at = message.completedAt !== BigInt(0) ? message.completedAt?.toString() : undefined;
|
|
549
571
|
obj.propagated_conviction = message.propagatedConviction === "" ? undefined : message.propagatedConviction;
|
|
572
|
+
obj.self_assign_bond = message.selfAssignBond === "" ? undefined : message.selfAssignBond;
|
|
550
573
|
return obj;
|
|
551
574
|
},
|
|
552
575
|
fromAminoMsg(object) {
|
|
@@ -375,6 +375,24 @@ export interface Params {
|
|
|
375
375
|
* pollution by stale unapproved proposals. Must be positive.
|
|
376
376
|
*/
|
|
377
377
|
proposedProjectExpiryBlocks: bigint;
|
|
378
|
+
/**
|
|
379
|
+
* Fraction of the initiative budget locked as a DREAM bond when the project
|
|
380
|
+
* creator self-assigns on a budget-backed project (permissionless projects
|
|
381
|
+
* are exempt — no treasury exposure). Bond is returned on completion or
|
|
382
|
+
* abandonment and burned when a challenge is upheld. Range [0, 1]; 0 disables.
|
|
383
|
+
*/
|
|
384
|
+
selfAssignedBondRate: string;
|
|
385
|
+
/**
|
|
386
|
+
* External-conviction ratio applied instead of external_conviction_ratio when
|
|
387
|
+
* the assignee is the project creator. Must be >= external_conviction_ratio
|
|
388
|
+
* and <= 1. Default 1.0: the community alone vouches for self-assigned work.
|
|
389
|
+
*/
|
|
390
|
+
selfAssignedExternalConvictionRatio: string;
|
|
391
|
+
/**
|
|
392
|
+
* Multiplier applied to the challenge window for creator-assigned
|
|
393
|
+
* initiatives. Must be >= 1. Default 2.
|
|
394
|
+
*/
|
|
395
|
+
selfAssignedChallengeMultiplier: bigint;
|
|
378
396
|
}
|
|
379
397
|
export interface ParamsProtoMsg {
|
|
380
398
|
typeUrl: "/sparkdream.rep.v1.Params";
|
|
@@ -665,6 +683,24 @@ export interface ParamsAmino {
|
|
|
665
683
|
* pollution by stale unapproved proposals. Must be positive.
|
|
666
684
|
*/
|
|
667
685
|
proposed_project_expiry_blocks?: string;
|
|
686
|
+
/**
|
|
687
|
+
* Fraction of the initiative budget locked as a DREAM bond when the project
|
|
688
|
+
* creator self-assigns on a budget-backed project (permissionless projects
|
|
689
|
+
* are exempt — no treasury exposure). Bond is returned on completion or
|
|
690
|
+
* abandonment and burned when a challenge is upheld. Range [0, 1]; 0 disables.
|
|
691
|
+
*/
|
|
692
|
+
self_assigned_bond_rate?: string;
|
|
693
|
+
/**
|
|
694
|
+
* External-conviction ratio applied instead of external_conviction_ratio when
|
|
695
|
+
* the assignee is the project creator. Must be >= external_conviction_ratio
|
|
696
|
+
* and <= 1. Default 1.0: the community alone vouches for self-assigned work.
|
|
697
|
+
*/
|
|
698
|
+
self_assigned_external_conviction_ratio?: string;
|
|
699
|
+
/**
|
|
700
|
+
* Multiplier applied to the challenge window for creator-assigned
|
|
701
|
+
* initiatives. Must be >= 1. Default 2.
|
|
702
|
+
*/
|
|
703
|
+
self_assigned_challenge_multiplier?: string;
|
|
668
704
|
}
|
|
669
705
|
export interface ParamsAminoMsg {
|
|
670
706
|
type: "sparkdream/x/rep/Params";
|
|
@@ -414,7 +414,10 @@ function createBaseParams() {
|
|
|
414
414
|
maxDreamMintPerEpoch: "",
|
|
415
415
|
maxProjectRequestedBudget: "",
|
|
416
416
|
maxProjectRequestedSpark: "",
|
|
417
|
-
proposedProjectExpiryBlocks: BigInt(0)
|
|
417
|
+
proposedProjectExpiryBlocks: BigInt(0),
|
|
418
|
+
selfAssignedBondRate: "",
|
|
419
|
+
selfAssignedExternalConvictionRatio: "",
|
|
420
|
+
selfAssignedChallengeMultiplier: BigInt(0)
|
|
418
421
|
};
|
|
419
422
|
}
|
|
420
423
|
/**
|
|
@@ -700,6 +703,15 @@ exports.Params = {
|
|
|
700
703
|
if (message.proposedProjectExpiryBlocks !== BigInt(0)) {
|
|
701
704
|
writer.uint32(720).int64(message.proposedProjectExpiryBlocks);
|
|
702
705
|
}
|
|
706
|
+
if (message.selfAssignedBondRate !== "") {
|
|
707
|
+
writer.uint32(738).string(math_1.Decimal.fromUserInput(message.selfAssignedBondRate, 18).atomics);
|
|
708
|
+
}
|
|
709
|
+
if (message.selfAssignedExternalConvictionRatio !== "") {
|
|
710
|
+
writer.uint32(746).string(math_1.Decimal.fromUserInput(message.selfAssignedExternalConvictionRatio, 18).atomics);
|
|
711
|
+
}
|
|
712
|
+
if (message.selfAssignedChallengeMultiplier !== BigInt(0)) {
|
|
713
|
+
writer.uint32(752).int64(message.selfAssignedChallengeMultiplier);
|
|
714
|
+
}
|
|
703
715
|
return writer;
|
|
704
716
|
},
|
|
705
717
|
decode(input, length) {
|
|
@@ -982,6 +994,15 @@ exports.Params = {
|
|
|
982
994
|
case 90:
|
|
983
995
|
message.proposedProjectExpiryBlocks = reader.int64();
|
|
984
996
|
break;
|
|
997
|
+
case 92:
|
|
998
|
+
message.selfAssignedBondRate = math_1.Decimal.fromAtomics(reader.string(), 18).toString();
|
|
999
|
+
break;
|
|
1000
|
+
case 93:
|
|
1001
|
+
message.selfAssignedExternalConvictionRatio = math_1.Decimal.fromAtomics(reader.string(), 18).toString();
|
|
1002
|
+
break;
|
|
1003
|
+
case 94:
|
|
1004
|
+
message.selfAssignedChallengeMultiplier = reader.int64();
|
|
1005
|
+
break;
|
|
985
1006
|
default:
|
|
986
1007
|
reader.skipType(tag & 7);
|
|
987
1008
|
break;
|
|
@@ -1082,6 +1103,9 @@ exports.Params = {
|
|
|
1082
1103
|
message.maxProjectRequestedBudget = object.maxProjectRequestedBudget ?? "";
|
|
1083
1104
|
message.maxProjectRequestedSpark = object.maxProjectRequestedSpark ?? "";
|
|
1084
1105
|
message.proposedProjectExpiryBlocks = object.proposedProjectExpiryBlocks !== undefined && object.proposedProjectExpiryBlocks !== null ? BigInt(object.proposedProjectExpiryBlocks.toString()) : BigInt(0);
|
|
1106
|
+
message.selfAssignedBondRate = object.selfAssignedBondRate ?? "";
|
|
1107
|
+
message.selfAssignedExternalConvictionRatio = object.selfAssignedExternalConvictionRatio ?? "";
|
|
1108
|
+
message.selfAssignedChallengeMultiplier = object.selfAssignedChallengeMultiplier !== undefined && object.selfAssignedChallengeMultiplier !== null ? BigInt(object.selfAssignedChallengeMultiplier.toString()) : BigInt(0);
|
|
1085
1109
|
return message;
|
|
1086
1110
|
},
|
|
1087
1111
|
fromAmino(object) {
|
|
@@ -1359,6 +1383,15 @@ exports.Params = {
|
|
|
1359
1383
|
if (object.proposed_project_expiry_blocks !== undefined && object.proposed_project_expiry_blocks !== null) {
|
|
1360
1384
|
message.proposedProjectExpiryBlocks = BigInt(object.proposed_project_expiry_blocks);
|
|
1361
1385
|
}
|
|
1386
|
+
if (object.self_assigned_bond_rate !== undefined && object.self_assigned_bond_rate !== null) {
|
|
1387
|
+
message.selfAssignedBondRate = object.self_assigned_bond_rate;
|
|
1388
|
+
}
|
|
1389
|
+
if (object.self_assigned_external_conviction_ratio !== undefined && object.self_assigned_external_conviction_ratio !== null) {
|
|
1390
|
+
message.selfAssignedExternalConvictionRatio = object.self_assigned_external_conviction_ratio;
|
|
1391
|
+
}
|
|
1392
|
+
if (object.self_assigned_challenge_multiplier !== undefined && object.self_assigned_challenge_multiplier !== null) {
|
|
1393
|
+
message.selfAssignedChallengeMultiplier = BigInt(object.self_assigned_challenge_multiplier);
|
|
1394
|
+
}
|
|
1362
1395
|
return message;
|
|
1363
1396
|
},
|
|
1364
1397
|
toAmino(message) {
|
|
@@ -1454,6 +1487,9 @@ exports.Params = {
|
|
|
1454
1487
|
obj.max_project_requested_budget = message.maxProjectRequestedBudget === "" ? undefined : message.maxProjectRequestedBudget;
|
|
1455
1488
|
obj.max_project_requested_spark = message.maxProjectRequestedSpark === "" ? undefined : message.maxProjectRequestedSpark;
|
|
1456
1489
|
obj.proposed_project_expiry_blocks = message.proposedProjectExpiryBlocks !== BigInt(0) ? message.proposedProjectExpiryBlocks?.toString() : undefined;
|
|
1490
|
+
obj.self_assigned_bond_rate = message.selfAssignedBondRate === "" ? undefined : message.selfAssignedBondRate;
|
|
1491
|
+
obj.self_assigned_external_conviction_ratio = message.selfAssignedExternalConvictionRatio === "" ? undefined : message.selfAssignedExternalConvictionRatio;
|
|
1492
|
+
obj.self_assigned_challenge_multiplier = message.selfAssignedChallengeMultiplier !== BigInt(0) ? message.selfAssignedChallengeMultiplier?.toString() : undefined;
|
|
1457
1493
|
return obj;
|
|
1458
1494
|
},
|
|
1459
1495
|
fromAminoMsg(object) {
|