@dfinity/sns 1.0.1 → 1.0.2
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/dist/candid/sns_governance.did +1 -1
- package/dist/candid/sns_governance_test.did +1 -1
- package/dist/candid/sns_root.did +1 -1
- package/dist/candid/sns_swap.certified.idl.js +14 -1
- package/dist/candid/sns_swap.d.ts +7 -0
- package/dist/candid/sns_swap.did +15 -3
- package/dist/candid/sns_swap.idl.js +14 -1
- package/dist/cjs/index.cjs.js +1 -1
- package/dist/cjs/index.cjs.js.map +2 -2
- package/dist/esm/{chunk-46J4XXKY.js → chunk-M5DB43UG.js} +2 -2
- package/dist/esm/chunk-ZF2AGKNK.js +2 -0
- package/dist/esm/chunk-ZF2AGKNK.js.map +7 -0
- package/dist/esm/index.js +1 -1
- package/dist/esm/sns.js +1 -1
- package/dist/esm/swap.canister.js +1 -1
- package/package.json +1 -1
- package/dist/esm/chunk-6AXPCLGQ.js +0 -2
- package/dist/esm/chunk-6AXPCLGQ.js.map +0 -7
- /package/dist/esm/{chunk-46J4XXKY.js.map → chunk-M5DB43UG.js.map} +0 -0
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
// Generated from IC repo commit
|
|
1
|
+
// Generated from IC repo commit dd51544944987556c978e774aa7a1992e5c11542 'rs/sns/governance/canister/governance.did' by import-candid
|
|
2
2
|
type Account = record { owner : opt principal; subaccount : opt Subaccount };
|
|
3
3
|
type Action = variant {
|
|
4
4
|
ManageNervousSystemParameters : NervousSystemParameters;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
// Generated from IC repo commit
|
|
1
|
+
// Generated from IC repo commit dd51544944987556c978e774aa7a1992e5c11542 'rs/sns/governance/canister/governance_test.did' by import-candid
|
|
2
2
|
type Account = record { owner : opt principal; subaccount : opt Subaccount };
|
|
3
3
|
type Action = variant {
|
|
4
4
|
ManageNervousSystemParameters : NervousSystemParameters;
|
package/dist/candid/sns_root.did
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
// Generated from IC repo commit
|
|
1
|
+
// Generated from IC repo commit dd51544944987556c978e774aa7a1992e5c11542 'rs/sns/root/canister/root.did' by import-candid
|
|
2
2
|
type AuthzChangeOp = variant {
|
|
3
3
|
Authorize : record { add_self : bool };
|
|
4
4
|
Deauthorize;
|
|
@@ -17,6 +17,7 @@ export const idlFactory = ({ IDL }) => {
|
|
|
17
17
|
'min_direct_participation_threshold_icp_e8s' : IDL.Opt(IDL.Nat64),
|
|
18
18
|
});
|
|
19
19
|
const CfNeuron = IDL.Record({
|
|
20
|
+
'has_created_neuron_recipes' : IDL.Opt(IDL.Bool),
|
|
20
21
|
'nns_neuron_id' : IDL.Nat64,
|
|
21
22
|
'amount_icp_e8s' : IDL.Nat64,
|
|
22
23
|
});
|
|
@@ -31,6 +32,7 @@ export const idlFactory = ({ IDL }) => {
|
|
|
31
32
|
const Init = IDL.Record({
|
|
32
33
|
'nns_proposal_id' : IDL.Opt(IDL.Nat64),
|
|
33
34
|
'sns_root_canister_id' : IDL.Text,
|
|
35
|
+
'neurons_fund_participation' : IDL.Opt(IDL.Bool),
|
|
34
36
|
'min_participant_icp_e8s' : IDL.Opt(IDL.Nat64),
|
|
35
37
|
'neuron_basket_construction_parameters' : IDL.Opt(
|
|
36
38
|
NeuronBasketConstructionParameters
|
|
@@ -54,8 +56,10 @@ export const idlFactory = ({ IDL }) => {
|
|
|
54
56
|
'should_auto_finalize' : IDL.Opt(IDL.Bool),
|
|
55
57
|
'max_participant_icp_e8s' : IDL.Opt(IDL.Nat64),
|
|
56
58
|
'sns_governance_canister_id' : IDL.Text,
|
|
59
|
+
'min_direct_participation_icp_e8s' : IDL.Opt(IDL.Nat64),
|
|
57
60
|
'restricted_countries' : IDL.Opt(Countries),
|
|
58
61
|
'min_icp_e8s' : IDL.Opt(IDL.Nat64),
|
|
62
|
+
'max_direct_participation_icp_e8s' : IDL.Opt(IDL.Nat64),
|
|
59
63
|
});
|
|
60
64
|
const ErrorRefundIcpRequest = IDL.Record({
|
|
61
65
|
'source_principal_id' : IDL.Opt(IDL.Principal),
|
|
@@ -139,7 +143,10 @@ export const idlFactory = ({ IDL }) => {
|
|
|
139
143
|
'amount_transferred_e8s' : IDL.Opt(IDL.Nat64),
|
|
140
144
|
'transfer_success_timestamp_seconds' : IDL.Nat64,
|
|
141
145
|
});
|
|
142
|
-
const BuyerState = IDL.Record({
|
|
146
|
+
const BuyerState = IDL.Record({
|
|
147
|
+
'icp' : IDL.Opt(TransferableAmount),
|
|
148
|
+
'has_created_neuron_recipes' : IDL.Opt(IDL.Bool),
|
|
149
|
+
});
|
|
143
150
|
const GetBuyerStateResponse = IDL.Record({
|
|
144
151
|
'buyer_state' : IDL.Opt(BuyerState),
|
|
145
152
|
});
|
|
@@ -202,7 +209,9 @@ export const idlFactory = ({ IDL }) => {
|
|
|
202
209
|
'sns_token_e8s' : IDL.Nat64,
|
|
203
210
|
'sale_delay_seconds' : IDL.Opt(IDL.Nat64),
|
|
204
211
|
'max_participant_icp_e8s' : IDL.Nat64,
|
|
212
|
+
'min_direct_participation_icp_e8s' : IDL.Opt(IDL.Nat64),
|
|
205
213
|
'min_icp_e8s' : IDL.Nat64,
|
|
214
|
+
'max_direct_participation_icp_e8s' : IDL.Opt(IDL.Nat64),
|
|
206
215
|
});
|
|
207
216
|
const GetSaleParametersResponse = IDL.Record({ 'params' : IDL.Opt(Params) });
|
|
208
217
|
const NeuronId = IDL.Record({ 'id' : IDL.Vec(IDL.Nat8) });
|
|
@@ -402,6 +411,7 @@ export const init = ({ IDL }) => {
|
|
|
402
411
|
'min_direct_participation_threshold_icp_e8s' : IDL.Opt(IDL.Nat64),
|
|
403
412
|
});
|
|
404
413
|
const CfNeuron = IDL.Record({
|
|
414
|
+
'has_created_neuron_recipes' : IDL.Opt(IDL.Bool),
|
|
405
415
|
'nns_neuron_id' : IDL.Nat64,
|
|
406
416
|
'amount_icp_e8s' : IDL.Nat64,
|
|
407
417
|
});
|
|
@@ -416,6 +426,7 @@ export const init = ({ IDL }) => {
|
|
|
416
426
|
const Init = IDL.Record({
|
|
417
427
|
'nns_proposal_id' : IDL.Opt(IDL.Nat64),
|
|
418
428
|
'sns_root_canister_id' : IDL.Text,
|
|
429
|
+
'neurons_fund_participation' : IDL.Opt(IDL.Bool),
|
|
419
430
|
'min_participant_icp_e8s' : IDL.Opt(IDL.Nat64),
|
|
420
431
|
'neuron_basket_construction_parameters' : IDL.Opt(
|
|
421
432
|
NeuronBasketConstructionParameters
|
|
@@ -439,8 +450,10 @@ export const init = ({ IDL }) => {
|
|
|
439
450
|
'should_auto_finalize' : IDL.Opt(IDL.Bool),
|
|
440
451
|
'max_participant_icp_e8s' : IDL.Opt(IDL.Nat64),
|
|
441
452
|
'sns_governance_canister_id' : IDL.Text,
|
|
453
|
+
'min_direct_participation_icp_e8s' : IDL.Opt(IDL.Nat64),
|
|
442
454
|
'restricted_countries' : IDL.Opt(Countries),
|
|
443
455
|
'min_icp_e8s' : IDL.Opt(IDL.Nat64),
|
|
456
|
+
'max_direct_participation_icp_e8s' : IDL.Opt(IDL.Nat64),
|
|
444
457
|
});
|
|
445
458
|
return [Init];
|
|
446
459
|
};
|
|
@@ -3,6 +3,7 @@ import type { Principal } from "@dfinity/principal";
|
|
|
3
3
|
|
|
4
4
|
export interface BuyerState {
|
|
5
5
|
icp: [] | [TransferableAmount];
|
|
6
|
+
has_created_neuron_recipes: [] | [boolean];
|
|
6
7
|
}
|
|
7
8
|
export interface CanisterCallError {
|
|
8
9
|
code: [] | [number];
|
|
@@ -25,6 +26,7 @@ export interface CfInvestment {
|
|
|
25
26
|
nns_neuron_id: bigint;
|
|
26
27
|
}
|
|
27
28
|
export interface CfNeuron {
|
|
29
|
+
has_created_neuron_recipes: [] | [boolean];
|
|
28
30
|
nns_neuron_id: bigint;
|
|
29
31
|
amount_icp_e8s: bigint;
|
|
30
32
|
}
|
|
@@ -137,6 +139,7 @@ export interface Icrc1Account {
|
|
|
137
139
|
export interface Init {
|
|
138
140
|
nns_proposal_id: [] | [bigint];
|
|
139
141
|
sns_root_canister_id: string;
|
|
142
|
+
neurons_fund_participation: [] | [boolean];
|
|
140
143
|
min_participant_icp_e8s: [] | [bigint];
|
|
141
144
|
neuron_basket_construction_parameters:
|
|
142
145
|
| []
|
|
@@ -160,8 +163,10 @@ export interface Init {
|
|
|
160
163
|
should_auto_finalize: [] | [boolean];
|
|
161
164
|
max_participant_icp_e8s: [] | [bigint];
|
|
162
165
|
sns_governance_canister_id: string;
|
|
166
|
+
min_direct_participation_icp_e8s: [] | [bigint];
|
|
163
167
|
restricted_countries: [] | [Countries];
|
|
164
168
|
min_icp_e8s: [] | [bigint];
|
|
169
|
+
max_direct_participation_icp_e8s: [] | [bigint];
|
|
165
170
|
}
|
|
166
171
|
export interface InvalidUserAmount {
|
|
167
172
|
min_amount_icp_e8s_included: bigint;
|
|
@@ -244,7 +249,9 @@ export interface Params {
|
|
|
244
249
|
sns_token_e8s: bigint;
|
|
245
250
|
sale_delay_seconds: [] | [bigint];
|
|
246
251
|
max_participant_icp_e8s: bigint;
|
|
252
|
+
min_direct_participation_icp_e8s: [] | [bigint];
|
|
247
253
|
min_icp_e8s: bigint;
|
|
254
|
+
max_direct_participation_icp_e8s: [] | [bigint];
|
|
248
255
|
}
|
|
249
256
|
export interface Participant {
|
|
250
257
|
participation: [] | [BuyerState];
|
package/dist/candid/sns_swap.did
CHANGED
|
@@ -1,5 +1,8 @@
|
|
|
1
|
-
// Generated from IC repo commit
|
|
2
|
-
type BuyerState = record {
|
|
1
|
+
// Generated from IC repo commit dd51544944987556c978e774aa7a1992e5c11542 'rs/sns/swap/canister/swap.did' by import-candid
|
|
2
|
+
type BuyerState = record {
|
|
3
|
+
icp : opt TransferableAmount;
|
|
4
|
+
has_created_neuron_recipes : opt bool;
|
|
5
|
+
};
|
|
3
6
|
type CanisterCallError = record { code : opt int32; description : text };
|
|
4
7
|
type CanisterStatusResultV2 = record {
|
|
5
8
|
status : CanisterStatusType;
|
|
@@ -11,7 +14,11 @@ type CanisterStatusResultV2 = record {
|
|
|
11
14
|
};
|
|
12
15
|
type CanisterStatusType = variant { stopped; stopping; running };
|
|
13
16
|
type CfInvestment = record { hotkey_principal : text; nns_neuron_id : nat64 };
|
|
14
|
-
type CfNeuron = record {
|
|
17
|
+
type CfNeuron = record {
|
|
18
|
+
has_created_neuron_recipes : opt bool;
|
|
19
|
+
nns_neuron_id : nat64;
|
|
20
|
+
amount_icp_e8s : nat64;
|
|
21
|
+
};
|
|
15
22
|
type CfParticipant = record {
|
|
16
23
|
hotkey_principal : text;
|
|
17
24
|
cf_neurons : vec CfNeuron;
|
|
@@ -85,6 +92,7 @@ type Icrc1Account = record { owner : opt principal; subaccount : opt vec nat8 };
|
|
|
85
92
|
type Init = record {
|
|
86
93
|
nns_proposal_id : opt nat64;
|
|
87
94
|
sns_root_canister_id : text;
|
|
95
|
+
neurons_fund_participation : opt bool;
|
|
88
96
|
min_participant_icp_e8s : opt nat64;
|
|
89
97
|
neuron_basket_construction_parameters : opt NeuronBasketConstructionParameters;
|
|
90
98
|
fallback_controller_principal_ids : vec text;
|
|
@@ -104,8 +112,10 @@ type Init = record {
|
|
|
104
112
|
should_auto_finalize : opt bool;
|
|
105
113
|
max_participant_icp_e8s : opt nat64;
|
|
106
114
|
sns_governance_canister_id : text;
|
|
115
|
+
min_direct_participation_icp_e8s : opt nat64;
|
|
107
116
|
restricted_countries : opt Countries;
|
|
108
117
|
min_icp_e8s : opt nat64;
|
|
118
|
+
max_direct_participation_icp_e8s : opt nat64;
|
|
109
119
|
};
|
|
110
120
|
type InvalidUserAmount = record {
|
|
111
121
|
min_amount_icp_e8s_included : nat64;
|
|
@@ -175,7 +185,9 @@ type Params = record {
|
|
|
175
185
|
sns_token_e8s : nat64;
|
|
176
186
|
sale_delay_seconds : opt nat64;
|
|
177
187
|
max_participant_icp_e8s : nat64;
|
|
188
|
+
min_direct_participation_icp_e8s : opt nat64;
|
|
178
189
|
min_icp_e8s : nat64;
|
|
190
|
+
max_direct_participation_icp_e8s : opt nat64;
|
|
179
191
|
};
|
|
180
192
|
type Participant = record {
|
|
181
193
|
participation : opt BuyerState;
|
|
@@ -17,6 +17,7 @@ export const idlFactory = ({ IDL }) => {
|
|
|
17
17
|
'min_direct_participation_threshold_icp_e8s' : IDL.Opt(IDL.Nat64),
|
|
18
18
|
});
|
|
19
19
|
const CfNeuron = IDL.Record({
|
|
20
|
+
'has_created_neuron_recipes' : IDL.Opt(IDL.Bool),
|
|
20
21
|
'nns_neuron_id' : IDL.Nat64,
|
|
21
22
|
'amount_icp_e8s' : IDL.Nat64,
|
|
22
23
|
});
|
|
@@ -31,6 +32,7 @@ export const idlFactory = ({ IDL }) => {
|
|
|
31
32
|
const Init = IDL.Record({
|
|
32
33
|
'nns_proposal_id' : IDL.Opt(IDL.Nat64),
|
|
33
34
|
'sns_root_canister_id' : IDL.Text,
|
|
35
|
+
'neurons_fund_participation' : IDL.Opt(IDL.Bool),
|
|
34
36
|
'min_participant_icp_e8s' : IDL.Opt(IDL.Nat64),
|
|
35
37
|
'neuron_basket_construction_parameters' : IDL.Opt(
|
|
36
38
|
NeuronBasketConstructionParameters
|
|
@@ -54,8 +56,10 @@ export const idlFactory = ({ IDL }) => {
|
|
|
54
56
|
'should_auto_finalize' : IDL.Opt(IDL.Bool),
|
|
55
57
|
'max_participant_icp_e8s' : IDL.Opt(IDL.Nat64),
|
|
56
58
|
'sns_governance_canister_id' : IDL.Text,
|
|
59
|
+
'min_direct_participation_icp_e8s' : IDL.Opt(IDL.Nat64),
|
|
57
60
|
'restricted_countries' : IDL.Opt(Countries),
|
|
58
61
|
'min_icp_e8s' : IDL.Opt(IDL.Nat64),
|
|
62
|
+
'max_direct_participation_icp_e8s' : IDL.Opt(IDL.Nat64),
|
|
59
63
|
});
|
|
60
64
|
const ErrorRefundIcpRequest = IDL.Record({
|
|
61
65
|
'source_principal_id' : IDL.Opt(IDL.Principal),
|
|
@@ -139,7 +143,10 @@ export const idlFactory = ({ IDL }) => {
|
|
|
139
143
|
'amount_transferred_e8s' : IDL.Opt(IDL.Nat64),
|
|
140
144
|
'transfer_success_timestamp_seconds' : IDL.Nat64,
|
|
141
145
|
});
|
|
142
|
-
const BuyerState = IDL.Record({
|
|
146
|
+
const BuyerState = IDL.Record({
|
|
147
|
+
'icp' : IDL.Opt(TransferableAmount),
|
|
148
|
+
'has_created_neuron_recipes' : IDL.Opt(IDL.Bool),
|
|
149
|
+
});
|
|
143
150
|
const GetBuyerStateResponse = IDL.Record({
|
|
144
151
|
'buyer_state' : IDL.Opt(BuyerState),
|
|
145
152
|
});
|
|
@@ -202,7 +209,9 @@ export const idlFactory = ({ IDL }) => {
|
|
|
202
209
|
'sns_token_e8s' : IDL.Nat64,
|
|
203
210
|
'sale_delay_seconds' : IDL.Opt(IDL.Nat64),
|
|
204
211
|
'max_participant_icp_e8s' : IDL.Nat64,
|
|
212
|
+
'min_direct_participation_icp_e8s' : IDL.Opt(IDL.Nat64),
|
|
205
213
|
'min_icp_e8s' : IDL.Nat64,
|
|
214
|
+
'max_direct_participation_icp_e8s' : IDL.Opt(IDL.Nat64),
|
|
206
215
|
});
|
|
207
216
|
const GetSaleParametersResponse = IDL.Record({ 'params' : IDL.Opt(Params) });
|
|
208
217
|
const NeuronId = IDL.Record({ 'id' : IDL.Vec(IDL.Nat8) });
|
|
@@ -410,6 +419,7 @@ export const init = ({ IDL }) => {
|
|
|
410
419
|
'min_direct_participation_threshold_icp_e8s' : IDL.Opt(IDL.Nat64),
|
|
411
420
|
});
|
|
412
421
|
const CfNeuron = IDL.Record({
|
|
422
|
+
'has_created_neuron_recipes' : IDL.Opt(IDL.Bool),
|
|
413
423
|
'nns_neuron_id' : IDL.Nat64,
|
|
414
424
|
'amount_icp_e8s' : IDL.Nat64,
|
|
415
425
|
});
|
|
@@ -424,6 +434,7 @@ export const init = ({ IDL }) => {
|
|
|
424
434
|
const Init = IDL.Record({
|
|
425
435
|
'nns_proposal_id' : IDL.Opt(IDL.Nat64),
|
|
426
436
|
'sns_root_canister_id' : IDL.Text,
|
|
437
|
+
'neurons_fund_participation' : IDL.Opt(IDL.Bool),
|
|
427
438
|
'min_participant_icp_e8s' : IDL.Opt(IDL.Nat64),
|
|
428
439
|
'neuron_basket_construction_parameters' : IDL.Opt(
|
|
429
440
|
NeuronBasketConstructionParameters
|
|
@@ -447,8 +458,10 @@ export const init = ({ IDL }) => {
|
|
|
447
458
|
'should_auto_finalize' : IDL.Opt(IDL.Bool),
|
|
448
459
|
'max_participant_icp_e8s' : IDL.Opt(IDL.Nat64),
|
|
449
460
|
'sns_governance_canister_id' : IDL.Text,
|
|
461
|
+
'min_direct_participation_icp_e8s' : IDL.Opt(IDL.Nat64),
|
|
450
462
|
'restricted_countries' : IDL.Opt(Countries),
|
|
451
463
|
'min_icp_e8s' : IDL.Opt(IDL.Nat64),
|
|
464
|
+
'max_direct_participation_icp_e8s' : IDL.Opt(IDL.Nat64),
|
|
452
465
|
});
|
|
453
466
|
return [Init];
|
|
454
467
|
};
|