@lucid-evolution/wallet 0.2.1 → 0.2.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/dist/index.cjs +281 -221
- package/dist/index.js +283 -223
- package/package.json +4 -4
package/dist/index.cjs
CHANGED
|
@@ -63,237 +63,297 @@ function walletFromSeed(seed, options = {}) {
|
|
|
63
63
|
(0, import_core_utils.fromHex)(entropy),
|
|
64
64
|
options?.password ? new TextEncoder().encode(options.password) : new Uint8Array()
|
|
65
65
|
);
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
66
|
+
return (0, import_core_utils.withCMLScope)((own) => {
|
|
67
|
+
own(rootKey);
|
|
68
|
+
const accountKey = own(
|
|
69
|
+
own(own(rootKey.derive(harden(1852))).derive(harden(1815))).derive(
|
|
70
|
+
harden(accountIndex)
|
|
71
|
+
)
|
|
72
|
+
);
|
|
73
|
+
const paymentKey = own(
|
|
74
|
+
own(own(accountKey.derive(0)).derive(0)).to_raw_key()
|
|
75
|
+
);
|
|
76
|
+
const stakeKey = own(own(own(accountKey.derive(2)).derive(0)).to_raw_key());
|
|
77
|
+
const paymentKeyHash = own(own(paymentKey.to_public()).hash());
|
|
78
|
+
const stakeKeyHash = own(own(stakeKey.to_public()).hash());
|
|
79
|
+
const networkId = network === "Mainnet" ? 1 : 0;
|
|
80
|
+
const address = addressType === "Base" ? own(
|
|
81
|
+
own(
|
|
82
|
+
CML.BaseAddress.new(
|
|
83
|
+
networkId,
|
|
84
|
+
own(CML.Credential.new_pub_key(paymentKeyHash)),
|
|
85
|
+
own(CML.Credential.new_pub_key(stakeKeyHash))
|
|
86
|
+
)
|
|
87
|
+
).to_address()
|
|
88
|
+
).to_bech32(void 0) : own(
|
|
89
|
+
own(
|
|
90
|
+
CML.EnterpriseAddress.new(
|
|
91
|
+
networkId,
|
|
92
|
+
own(CML.Credential.new_pub_key(paymentKeyHash))
|
|
93
|
+
)
|
|
94
|
+
).to_address()
|
|
95
|
+
).to_bech32(void 0);
|
|
96
|
+
const rewardAddress = addressType === "Base" ? own(
|
|
97
|
+
own(
|
|
98
|
+
CML.RewardAddress.new(
|
|
99
|
+
networkId,
|
|
100
|
+
own(CML.Credential.new_pub_key(stakeKeyHash))
|
|
101
|
+
)
|
|
102
|
+
).to_address()
|
|
103
|
+
).to_bech32(void 0) : null;
|
|
104
|
+
return {
|
|
105
|
+
address,
|
|
106
|
+
rewardAddress,
|
|
107
|
+
paymentKey: paymentKey.to_bech32(),
|
|
108
|
+
stakeKey: addressType === "Base" ? stakeKey.to_bech32() : null
|
|
109
|
+
};
|
|
110
|
+
});
|
|
91
111
|
}
|
|
92
112
|
function discoverOwnUsedTxKeyHashes(tx, ownKeyHashes, ownUtxos) {
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
const
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
113
|
+
return (0, import_core_utils.withCMLScope)((own) => {
|
|
114
|
+
const usedKeyHashes = [];
|
|
115
|
+
const txBody = own(tx.body());
|
|
116
|
+
const inputs = own(txBody.inputs());
|
|
117
|
+
for (let i = 0; i < inputs.len(); i++) {
|
|
118
|
+
const input = own(inputs.get(i));
|
|
119
|
+
const txHash = own(input.transaction_id()).to_hex();
|
|
120
|
+
const outputIndex = Number(input.index());
|
|
121
|
+
const utxo = ownUtxos.find(
|
|
122
|
+
(utxo2) => utxo2.txHash === txHash && utxo2.outputIndex === outputIndex
|
|
123
|
+
);
|
|
124
|
+
if (utxo) {
|
|
125
|
+
const { paymentCredential } = (0, import_utils.getAddressDetails)(utxo.address);
|
|
126
|
+
usedKeyHashes.push(paymentCredential?.hash);
|
|
127
|
+
}
|
|
105
128
|
}
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
129
|
+
function keyHashFromCert(txBody2) {
|
|
130
|
+
const certs = own(txBody2.certs());
|
|
131
|
+
if (!certs) return;
|
|
132
|
+
for (let i = 0; i < certs.len(); i++) {
|
|
133
|
+
const cert = own(certs.get(i));
|
|
134
|
+
switch (cert.kind()) {
|
|
135
|
+
case 0:
|
|
136
|
+
break;
|
|
137
|
+
case 1: {
|
|
138
|
+
const credential = own(
|
|
139
|
+
own(cert.as_stake_deregistration())?.stake_credential()
|
|
140
|
+
);
|
|
141
|
+
switch (credential?.kind()) {
|
|
142
|
+
case 0:
|
|
143
|
+
usedKeyHashes.push(own(credential.as_pub_key())?.to_hex());
|
|
144
|
+
break;
|
|
145
|
+
case 1:
|
|
146
|
+
usedKeyHashes.push(own(credential.as_script())?.to_hex());
|
|
147
|
+
break;
|
|
148
|
+
}
|
|
149
|
+
break;
|
|
125
150
|
}
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
151
|
+
case 2: {
|
|
152
|
+
const credential = own(
|
|
153
|
+
own(cert.as_stake_delegation())?.stake_credential()
|
|
154
|
+
);
|
|
155
|
+
if (credential?.kind() === 0) {
|
|
156
|
+
const keyHash = own(credential.as_pub_key())?.to_hex();
|
|
157
|
+
usedKeyHashes.push(keyHash);
|
|
158
|
+
}
|
|
159
|
+
break;
|
|
133
160
|
}
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
161
|
+
case 3: {
|
|
162
|
+
const poolParams = own(
|
|
163
|
+
own(cert.as_pool_registration())?.pool_params()
|
|
164
|
+
);
|
|
165
|
+
const owners = own(poolParams?.pool_owners());
|
|
166
|
+
if (!owners) break;
|
|
167
|
+
for (let i2 = 0; i2 < owners.len(); i2++) {
|
|
168
|
+
const keyHash = own(owners.get(i2)).to_hex();
|
|
169
|
+
usedKeyHashes.push(keyHash);
|
|
170
|
+
}
|
|
171
|
+
const operator = own(poolParams.operator()).to_hex();
|
|
172
|
+
usedKeyHashes.push(operator);
|
|
173
|
+
break;
|
|
143
174
|
}
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
usedKeyHashes.push(operator);
|
|
151
|
-
break;
|
|
152
|
-
}
|
|
153
|
-
case 6: {
|
|
154
|
-
const credential = cert.as_unreg_cert()?.stake_credential();
|
|
155
|
-
if (credential) {
|
|
156
|
-
usedKeyHashes.push(credential.as_pub_key()?.to_hex());
|
|
175
|
+
case 4: {
|
|
176
|
+
const operator = own(
|
|
177
|
+
own(cert.as_pool_retirement())?.pool()
|
|
178
|
+
)?.to_hex();
|
|
179
|
+
usedKeyHashes.push(operator);
|
|
180
|
+
break;
|
|
157
181
|
}
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
182
|
+
case 6: {
|
|
183
|
+
const credential = own(
|
|
184
|
+
own(cert.as_unreg_cert())?.stake_credential()
|
|
185
|
+
);
|
|
186
|
+
if (credential) {
|
|
187
|
+
usedKeyHashes.push(own(credential.as_pub_key())?.to_hex());
|
|
188
|
+
}
|
|
189
|
+
break;
|
|
164
190
|
}
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
191
|
+
case 7: {
|
|
192
|
+
const credential = own(
|
|
193
|
+
own(cert.as_vote_deleg_cert())?.stake_credential()
|
|
194
|
+
);
|
|
195
|
+
if (credential) {
|
|
196
|
+
usedKeyHashes.push(own(credential.as_pub_key())?.to_hex());
|
|
197
|
+
}
|
|
198
|
+
break;
|
|
171
199
|
}
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
200
|
+
case 8: {
|
|
201
|
+
const credential = own(
|
|
202
|
+
own(cert.as_stake_vote_deleg_cert())?.stake_credential()
|
|
203
|
+
);
|
|
204
|
+
if (credential) {
|
|
205
|
+
usedKeyHashes.push(own(credential.as_pub_key())?.to_hex());
|
|
206
|
+
}
|
|
207
|
+
break;
|
|
178
208
|
}
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
209
|
+
case 9: {
|
|
210
|
+
const credential = own(
|
|
211
|
+
own(cert.as_stake_reg_deleg_cert())?.stake_credential()
|
|
212
|
+
);
|
|
213
|
+
if (credential) {
|
|
214
|
+
usedKeyHashes.push(own(credential.as_pub_key())?.to_hex());
|
|
215
|
+
}
|
|
216
|
+
break;
|
|
185
217
|
}
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
218
|
+
case 10: {
|
|
219
|
+
const credential = own(
|
|
220
|
+
own(cert.as_vote_reg_deleg_cert())?.stake_credential()
|
|
221
|
+
);
|
|
222
|
+
if (credential) {
|
|
223
|
+
usedKeyHashes.push(own(credential.as_pub_key())?.to_hex());
|
|
224
|
+
}
|
|
225
|
+
break;
|
|
192
226
|
}
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
227
|
+
case 11: {
|
|
228
|
+
const credential = own(
|
|
229
|
+
own(cert.as_stake_vote_reg_deleg_cert())?.stake_credential()
|
|
230
|
+
);
|
|
231
|
+
if (credential) {
|
|
232
|
+
usedKeyHashes.push(own(credential.as_pub_key())?.to_hex());
|
|
233
|
+
}
|
|
234
|
+
break;
|
|
199
235
|
}
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
236
|
+
case 12: {
|
|
237
|
+
const credential = own(
|
|
238
|
+
own(
|
|
239
|
+
cert.as_auth_committee_hot_cert()
|
|
240
|
+
)?.committee_cold_credential()
|
|
241
|
+
);
|
|
242
|
+
if (credential) {
|
|
243
|
+
usedKeyHashes.push(own(credential.as_pub_key())?.to_hex());
|
|
244
|
+
}
|
|
245
|
+
break;
|
|
206
246
|
}
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
247
|
+
case 13: {
|
|
248
|
+
const credential = own(
|
|
249
|
+
own(
|
|
250
|
+
cert.as_resign_committee_cold_cert()
|
|
251
|
+
)?.committee_cold_credential()
|
|
252
|
+
);
|
|
253
|
+
if (credential) {
|
|
254
|
+
usedKeyHashes.push(own(credential.as_pub_key())?.to_hex());
|
|
255
|
+
}
|
|
256
|
+
break;
|
|
213
257
|
}
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
258
|
+
case 14: {
|
|
259
|
+
const credential = own(
|
|
260
|
+
own(cert.as_reg_drep_cert())?.drep_credential()
|
|
261
|
+
);
|
|
262
|
+
if (credential) {
|
|
263
|
+
usedKeyHashes.push(own(credential.as_pub_key())?.to_hex());
|
|
264
|
+
}
|
|
265
|
+
break;
|
|
220
266
|
}
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
267
|
+
case 15: {
|
|
268
|
+
const credential = own(
|
|
269
|
+
own(cert.as_unreg_drep_cert())?.drep_credential()
|
|
270
|
+
);
|
|
271
|
+
if (credential) {
|
|
272
|
+
usedKeyHashes.push(own(credential.as_pub_key())?.to_hex());
|
|
273
|
+
}
|
|
274
|
+
break;
|
|
275
|
+
}
|
|
276
|
+
case 16: {
|
|
277
|
+
const credential = own(
|
|
278
|
+
own(cert.as_update_drep_cert())?.drep_credential()
|
|
279
|
+
);
|
|
280
|
+
if (credential) {
|
|
281
|
+
usedKeyHashes.push(own(credential.as_pub_key())?.to_hex());
|
|
282
|
+
}
|
|
283
|
+
break;
|
|
227
284
|
}
|
|
228
|
-
|
|
285
|
+
default:
|
|
286
|
+
break;
|
|
229
287
|
}
|
|
230
|
-
default:
|
|
231
|
-
break;
|
|
232
288
|
}
|
|
233
289
|
}
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
290
|
+
keyHashFromCert(txBody);
|
|
291
|
+
const withdrawals = own(txBody.withdrawals());
|
|
292
|
+
function keyHashFromWithdrawal(withdrawals2) {
|
|
293
|
+
const rewardAddresses = own(withdrawals2.keys());
|
|
294
|
+
for (let i = 0; i < rewardAddresses.len(); i++) {
|
|
295
|
+
const credential = own(own(rewardAddresses.get(i)).payment());
|
|
296
|
+
switch (credential.kind()) {
|
|
297
|
+
case 0:
|
|
298
|
+
usedKeyHashes.push(own(credential.as_pub_key())?.to_hex());
|
|
299
|
+
break;
|
|
300
|
+
case 1:
|
|
301
|
+
usedKeyHashes.push(own(credential.as_script())?.to_hex());
|
|
302
|
+
break;
|
|
303
|
+
}
|
|
248
304
|
}
|
|
249
305
|
}
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
306
|
+
if (withdrawals) keyHashFromWithdrawal(withdrawals);
|
|
307
|
+
const scripts = own(own(tx.witness_set()).native_scripts());
|
|
308
|
+
function keyHashFromScript(scripts2) {
|
|
309
|
+
for (let i = 0; i < scripts2.len(); i++) {
|
|
310
|
+
const script = own(scripts2.get(i));
|
|
311
|
+
if (script.kind() === 0) {
|
|
312
|
+
const keyHash = own(
|
|
313
|
+
own(script.as_script_pubkey())?.ed25519_key_hash()
|
|
314
|
+
)?.to_hex();
|
|
315
|
+
usedKeyHashes.push(keyHash);
|
|
316
|
+
}
|
|
317
|
+
if (script.kind() === 1) {
|
|
318
|
+
keyHashFromScript(own(own(script.as_script_all()).native_scripts()));
|
|
319
|
+
return;
|
|
320
|
+
}
|
|
321
|
+
if (script.kind() === 2) {
|
|
322
|
+
keyHashFromScript(own(own(script.as_script_any()).native_scripts()));
|
|
323
|
+
return;
|
|
324
|
+
}
|
|
325
|
+
if (script.kind() === 3) {
|
|
326
|
+
keyHashFromScript(
|
|
327
|
+
own(own(script.as_script_n_of_k()).native_scripts())
|
|
328
|
+
);
|
|
329
|
+
return;
|
|
330
|
+
}
|
|
271
331
|
}
|
|
272
332
|
}
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
333
|
+
if (scripts) keyHashFromScript(scripts);
|
|
334
|
+
const requiredSigners = own(txBody.required_signers());
|
|
335
|
+
if (requiredSigners) {
|
|
336
|
+
for (let i = 0; i < requiredSigners.len(); i++) {
|
|
337
|
+
usedKeyHashes.push(own(requiredSigners.get(i)).to_hex());
|
|
338
|
+
}
|
|
279
339
|
}
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
340
|
+
const collateral = own(txBody.collateral_inputs());
|
|
341
|
+
if (collateral) {
|
|
342
|
+
for (let i = 0; i < collateral.len(); i++) {
|
|
343
|
+
const input = own(collateral.get(i));
|
|
344
|
+
const txHash = own(input.transaction_id()).to_hex();
|
|
345
|
+
const outputIndex = Number(input.index());
|
|
346
|
+
const utxo = ownUtxos.find(
|
|
347
|
+
(utxo2) => utxo2.txHash === txHash && utxo2.outputIndex === outputIndex
|
|
348
|
+
);
|
|
349
|
+
if (utxo) {
|
|
350
|
+
const { paymentCredential } = (0, import_utils.getAddressDetails)(utxo.address);
|
|
351
|
+
usedKeyHashes.push(paymentCredential?.hash);
|
|
352
|
+
}
|
|
293
353
|
}
|
|
294
354
|
}
|
|
295
|
-
|
|
296
|
-
|
|
355
|
+
return usedKeyHashes.filter((k) => ownKeyHashes.includes(k));
|
|
356
|
+
});
|
|
297
357
|
}
|
|
298
358
|
|
|
299
359
|
// src/wallet_selection.ts
|
|
@@ -362,16 +422,15 @@ var makeWalletFromSeed = (provider, network, seed, options) => {
|
|
|
362
422
|
const utxos = config.overriddenUTxOs !== void 0 ? config.overriddenUTxOs : await provider.getUtxos(address);
|
|
363
423
|
const ownKeyHashes = [paymentKeyHash, stakeKeyHash];
|
|
364
424
|
const usedKeyHashes = discoverOwnUsedTxKeyHashes(tx, ownKeyHashes, utxos);
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
const
|
|
368
|
-
const
|
|
369
|
-
CML.
|
|
370
|
-
priv
|
|
371
|
-
|
|
372
|
-
txWitnessSetBuilder.
|
|
373
|
-
}
|
|
374
|
-
return txWitnessSetBuilder.build();
|
|
425
|
+
return (0, import_core_utils2.withCMLScope)((own) => {
|
|
426
|
+
const txWitnessSetBuilder = own(CML.TransactionWitnessSetBuilder.new());
|
|
427
|
+
const txHash = own(CML.hash_transaction(own(tx.body())));
|
|
428
|
+
for (const keyHash of usedKeyHashes) {
|
|
429
|
+
const priv = own(CML.PrivateKey.from_bech32(privKeyHashMap[keyHash]));
|
|
430
|
+
txWitnessSetBuilder.add_vkey(own(CML.make_vkey_witness(txHash, priv)));
|
|
431
|
+
}
|
|
432
|
+
return txWitnessSetBuilder.build();
|
|
433
|
+
});
|
|
375
434
|
};
|
|
376
435
|
return {
|
|
377
436
|
overrideUTxOs: (utxos) => config.overriddenUTxOs = utxos,
|
|
@@ -420,13 +479,14 @@ var makeWalletFromPrivateKey = (provider, network, privateKey) => {
|
|
|
420
479
|
overriddenUTxOs: void 0
|
|
421
480
|
};
|
|
422
481
|
const signTx = async (tx) => {
|
|
423
|
-
|
|
424
|
-
|
|
425
|
-
|
|
426
|
-
|
|
427
|
-
|
|
428
|
-
|
|
429
|
-
|
|
482
|
+
return (0, import_core_utils2.withCMLScope)((own) => {
|
|
483
|
+
const witness = own(
|
|
484
|
+
CML.make_vkey_witness(own(CML.hash_transaction(own(tx.body()))), priv)
|
|
485
|
+
);
|
|
486
|
+
const txWitnessSetBuilder = own(CML.TransactionWitnessSetBuilder.new());
|
|
487
|
+
txWitnessSetBuilder.add_vkey(witness);
|
|
488
|
+
return txWitnessSetBuilder.build();
|
|
489
|
+
});
|
|
430
490
|
};
|
|
431
491
|
return {
|
|
432
492
|
overrideUTxOs: (utxos) => config.overriddenUTxOs = utxos,
|
package/dist/index.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
// src/wallet.ts
|
|
2
2
|
import { getAddressDetails } from "@lucid-evolution/utils";
|
|
3
|
-
import { fromHex } from "@lucid-evolution/core-utils";
|
|
3
|
+
import { fromHex, withCMLScope } from "@lucid-evolution/core-utils";
|
|
4
4
|
|
|
5
5
|
// src/core.ts
|
|
6
6
|
import * as CML from "@anastasia-labs/cardano-multiplatform-lib-nodejs";
|
|
@@ -22,241 +22,301 @@ function walletFromSeed(seed, options = {}) {
|
|
|
22
22
|
fromHex(entropy),
|
|
23
23
|
options?.password ? new TextEncoder().encode(options.password) : new Uint8Array()
|
|
24
24
|
);
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
25
|
+
return withCMLScope((own) => {
|
|
26
|
+
own(rootKey);
|
|
27
|
+
const accountKey = own(
|
|
28
|
+
own(own(rootKey.derive(harden(1852))).derive(harden(1815))).derive(
|
|
29
|
+
harden(accountIndex)
|
|
30
|
+
)
|
|
31
|
+
);
|
|
32
|
+
const paymentKey = own(
|
|
33
|
+
own(own(accountKey.derive(0)).derive(0)).to_raw_key()
|
|
34
|
+
);
|
|
35
|
+
const stakeKey = own(own(own(accountKey.derive(2)).derive(0)).to_raw_key());
|
|
36
|
+
const paymentKeyHash = own(own(paymentKey.to_public()).hash());
|
|
37
|
+
const stakeKeyHash = own(own(stakeKey.to_public()).hash());
|
|
38
|
+
const networkId = network === "Mainnet" ? 1 : 0;
|
|
39
|
+
const address = addressType === "Base" ? own(
|
|
40
|
+
own(
|
|
41
|
+
CML.BaseAddress.new(
|
|
42
|
+
networkId,
|
|
43
|
+
own(CML.Credential.new_pub_key(paymentKeyHash)),
|
|
44
|
+
own(CML.Credential.new_pub_key(stakeKeyHash))
|
|
45
|
+
)
|
|
46
|
+
).to_address()
|
|
47
|
+
).to_bech32(void 0) : own(
|
|
48
|
+
own(
|
|
49
|
+
CML.EnterpriseAddress.new(
|
|
50
|
+
networkId,
|
|
51
|
+
own(CML.Credential.new_pub_key(paymentKeyHash))
|
|
52
|
+
)
|
|
53
|
+
).to_address()
|
|
54
|
+
).to_bech32(void 0);
|
|
55
|
+
const rewardAddress = addressType === "Base" ? own(
|
|
56
|
+
own(
|
|
57
|
+
CML.RewardAddress.new(
|
|
58
|
+
networkId,
|
|
59
|
+
own(CML.Credential.new_pub_key(stakeKeyHash))
|
|
60
|
+
)
|
|
61
|
+
).to_address()
|
|
62
|
+
).to_bech32(void 0) : null;
|
|
63
|
+
return {
|
|
64
|
+
address,
|
|
65
|
+
rewardAddress,
|
|
66
|
+
paymentKey: paymentKey.to_bech32(),
|
|
67
|
+
stakeKey: addressType === "Base" ? stakeKey.to_bech32() : null
|
|
68
|
+
};
|
|
69
|
+
});
|
|
50
70
|
}
|
|
51
71
|
function discoverOwnUsedTxKeyHashes(tx, ownKeyHashes, ownUtxos) {
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
const
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
72
|
+
return withCMLScope((own) => {
|
|
73
|
+
const usedKeyHashes = [];
|
|
74
|
+
const txBody = own(tx.body());
|
|
75
|
+
const inputs = own(txBody.inputs());
|
|
76
|
+
for (let i = 0; i < inputs.len(); i++) {
|
|
77
|
+
const input = own(inputs.get(i));
|
|
78
|
+
const txHash = own(input.transaction_id()).to_hex();
|
|
79
|
+
const outputIndex = Number(input.index());
|
|
80
|
+
const utxo = ownUtxos.find(
|
|
81
|
+
(utxo2) => utxo2.txHash === txHash && utxo2.outputIndex === outputIndex
|
|
82
|
+
);
|
|
83
|
+
if (utxo) {
|
|
84
|
+
const { paymentCredential } = getAddressDetails(utxo.address);
|
|
85
|
+
usedKeyHashes.push(paymentCredential?.hash);
|
|
86
|
+
}
|
|
64
87
|
}
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
88
|
+
function keyHashFromCert(txBody2) {
|
|
89
|
+
const certs = own(txBody2.certs());
|
|
90
|
+
if (!certs) return;
|
|
91
|
+
for (let i = 0; i < certs.len(); i++) {
|
|
92
|
+
const cert = own(certs.get(i));
|
|
93
|
+
switch (cert.kind()) {
|
|
94
|
+
case 0:
|
|
95
|
+
break;
|
|
96
|
+
case 1: {
|
|
97
|
+
const credential = own(
|
|
98
|
+
own(cert.as_stake_deregistration())?.stake_credential()
|
|
99
|
+
);
|
|
100
|
+
switch (credential?.kind()) {
|
|
101
|
+
case 0:
|
|
102
|
+
usedKeyHashes.push(own(credential.as_pub_key())?.to_hex());
|
|
103
|
+
break;
|
|
104
|
+
case 1:
|
|
105
|
+
usedKeyHashes.push(own(credential.as_script())?.to_hex());
|
|
106
|
+
break;
|
|
107
|
+
}
|
|
108
|
+
break;
|
|
84
109
|
}
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
110
|
+
case 2: {
|
|
111
|
+
const credential = own(
|
|
112
|
+
own(cert.as_stake_delegation())?.stake_credential()
|
|
113
|
+
);
|
|
114
|
+
if (credential?.kind() === 0) {
|
|
115
|
+
const keyHash = own(credential.as_pub_key())?.to_hex();
|
|
116
|
+
usedKeyHashes.push(keyHash);
|
|
117
|
+
}
|
|
118
|
+
break;
|
|
92
119
|
}
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
120
|
+
case 3: {
|
|
121
|
+
const poolParams = own(
|
|
122
|
+
own(cert.as_pool_registration())?.pool_params()
|
|
123
|
+
);
|
|
124
|
+
const owners = own(poolParams?.pool_owners());
|
|
125
|
+
if (!owners) break;
|
|
126
|
+
for (let i2 = 0; i2 < owners.len(); i2++) {
|
|
127
|
+
const keyHash = own(owners.get(i2)).to_hex();
|
|
128
|
+
usedKeyHashes.push(keyHash);
|
|
129
|
+
}
|
|
130
|
+
const operator = own(poolParams.operator()).to_hex();
|
|
131
|
+
usedKeyHashes.push(operator);
|
|
132
|
+
break;
|
|
102
133
|
}
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
usedKeyHashes.push(operator);
|
|
110
|
-
break;
|
|
111
|
-
}
|
|
112
|
-
case 6: {
|
|
113
|
-
const credential = cert.as_unreg_cert()?.stake_credential();
|
|
114
|
-
if (credential) {
|
|
115
|
-
usedKeyHashes.push(credential.as_pub_key()?.to_hex());
|
|
134
|
+
case 4: {
|
|
135
|
+
const operator = own(
|
|
136
|
+
own(cert.as_pool_retirement())?.pool()
|
|
137
|
+
)?.to_hex();
|
|
138
|
+
usedKeyHashes.push(operator);
|
|
139
|
+
break;
|
|
116
140
|
}
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
141
|
+
case 6: {
|
|
142
|
+
const credential = own(
|
|
143
|
+
own(cert.as_unreg_cert())?.stake_credential()
|
|
144
|
+
);
|
|
145
|
+
if (credential) {
|
|
146
|
+
usedKeyHashes.push(own(credential.as_pub_key())?.to_hex());
|
|
147
|
+
}
|
|
148
|
+
break;
|
|
123
149
|
}
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
150
|
+
case 7: {
|
|
151
|
+
const credential = own(
|
|
152
|
+
own(cert.as_vote_deleg_cert())?.stake_credential()
|
|
153
|
+
);
|
|
154
|
+
if (credential) {
|
|
155
|
+
usedKeyHashes.push(own(credential.as_pub_key())?.to_hex());
|
|
156
|
+
}
|
|
157
|
+
break;
|
|
130
158
|
}
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
159
|
+
case 8: {
|
|
160
|
+
const credential = own(
|
|
161
|
+
own(cert.as_stake_vote_deleg_cert())?.stake_credential()
|
|
162
|
+
);
|
|
163
|
+
if (credential) {
|
|
164
|
+
usedKeyHashes.push(own(credential.as_pub_key())?.to_hex());
|
|
165
|
+
}
|
|
166
|
+
break;
|
|
137
167
|
}
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
168
|
+
case 9: {
|
|
169
|
+
const credential = own(
|
|
170
|
+
own(cert.as_stake_reg_deleg_cert())?.stake_credential()
|
|
171
|
+
);
|
|
172
|
+
if (credential) {
|
|
173
|
+
usedKeyHashes.push(own(credential.as_pub_key())?.to_hex());
|
|
174
|
+
}
|
|
175
|
+
break;
|
|
144
176
|
}
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
177
|
+
case 10: {
|
|
178
|
+
const credential = own(
|
|
179
|
+
own(cert.as_vote_reg_deleg_cert())?.stake_credential()
|
|
180
|
+
);
|
|
181
|
+
if (credential) {
|
|
182
|
+
usedKeyHashes.push(own(credential.as_pub_key())?.to_hex());
|
|
183
|
+
}
|
|
184
|
+
break;
|
|
151
185
|
}
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
186
|
+
case 11: {
|
|
187
|
+
const credential = own(
|
|
188
|
+
own(cert.as_stake_vote_reg_deleg_cert())?.stake_credential()
|
|
189
|
+
);
|
|
190
|
+
if (credential) {
|
|
191
|
+
usedKeyHashes.push(own(credential.as_pub_key())?.to_hex());
|
|
192
|
+
}
|
|
193
|
+
break;
|
|
158
194
|
}
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
195
|
+
case 12: {
|
|
196
|
+
const credential = own(
|
|
197
|
+
own(
|
|
198
|
+
cert.as_auth_committee_hot_cert()
|
|
199
|
+
)?.committee_cold_credential()
|
|
200
|
+
);
|
|
201
|
+
if (credential) {
|
|
202
|
+
usedKeyHashes.push(own(credential.as_pub_key())?.to_hex());
|
|
203
|
+
}
|
|
204
|
+
break;
|
|
165
205
|
}
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
206
|
+
case 13: {
|
|
207
|
+
const credential = own(
|
|
208
|
+
own(
|
|
209
|
+
cert.as_resign_committee_cold_cert()
|
|
210
|
+
)?.committee_cold_credential()
|
|
211
|
+
);
|
|
212
|
+
if (credential) {
|
|
213
|
+
usedKeyHashes.push(own(credential.as_pub_key())?.to_hex());
|
|
214
|
+
}
|
|
215
|
+
break;
|
|
172
216
|
}
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
217
|
+
case 14: {
|
|
218
|
+
const credential = own(
|
|
219
|
+
own(cert.as_reg_drep_cert())?.drep_credential()
|
|
220
|
+
);
|
|
221
|
+
if (credential) {
|
|
222
|
+
usedKeyHashes.push(own(credential.as_pub_key())?.to_hex());
|
|
223
|
+
}
|
|
224
|
+
break;
|
|
179
225
|
}
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
226
|
+
case 15: {
|
|
227
|
+
const credential = own(
|
|
228
|
+
own(cert.as_unreg_drep_cert())?.drep_credential()
|
|
229
|
+
);
|
|
230
|
+
if (credential) {
|
|
231
|
+
usedKeyHashes.push(own(credential.as_pub_key())?.to_hex());
|
|
232
|
+
}
|
|
233
|
+
break;
|
|
234
|
+
}
|
|
235
|
+
case 16: {
|
|
236
|
+
const credential = own(
|
|
237
|
+
own(cert.as_update_drep_cert())?.drep_credential()
|
|
238
|
+
);
|
|
239
|
+
if (credential) {
|
|
240
|
+
usedKeyHashes.push(own(credential.as_pub_key())?.to_hex());
|
|
241
|
+
}
|
|
242
|
+
break;
|
|
186
243
|
}
|
|
187
|
-
|
|
244
|
+
default:
|
|
245
|
+
break;
|
|
188
246
|
}
|
|
189
|
-
default:
|
|
190
|
-
break;
|
|
191
247
|
}
|
|
192
248
|
}
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
249
|
+
keyHashFromCert(txBody);
|
|
250
|
+
const withdrawals = own(txBody.withdrawals());
|
|
251
|
+
function keyHashFromWithdrawal(withdrawals2) {
|
|
252
|
+
const rewardAddresses = own(withdrawals2.keys());
|
|
253
|
+
for (let i = 0; i < rewardAddresses.len(); i++) {
|
|
254
|
+
const credential = own(own(rewardAddresses.get(i)).payment());
|
|
255
|
+
switch (credential.kind()) {
|
|
256
|
+
case 0:
|
|
257
|
+
usedKeyHashes.push(own(credential.as_pub_key())?.to_hex());
|
|
258
|
+
break;
|
|
259
|
+
case 1:
|
|
260
|
+
usedKeyHashes.push(own(credential.as_script())?.to_hex());
|
|
261
|
+
break;
|
|
262
|
+
}
|
|
207
263
|
}
|
|
208
264
|
}
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
265
|
+
if (withdrawals) keyHashFromWithdrawal(withdrawals);
|
|
266
|
+
const scripts = own(own(tx.witness_set()).native_scripts());
|
|
267
|
+
function keyHashFromScript(scripts2) {
|
|
268
|
+
for (let i = 0; i < scripts2.len(); i++) {
|
|
269
|
+
const script = own(scripts2.get(i));
|
|
270
|
+
if (script.kind() === 0) {
|
|
271
|
+
const keyHash = own(
|
|
272
|
+
own(script.as_script_pubkey())?.ed25519_key_hash()
|
|
273
|
+
)?.to_hex();
|
|
274
|
+
usedKeyHashes.push(keyHash);
|
|
275
|
+
}
|
|
276
|
+
if (script.kind() === 1) {
|
|
277
|
+
keyHashFromScript(own(own(script.as_script_all()).native_scripts()));
|
|
278
|
+
return;
|
|
279
|
+
}
|
|
280
|
+
if (script.kind() === 2) {
|
|
281
|
+
keyHashFromScript(own(own(script.as_script_any()).native_scripts()));
|
|
282
|
+
return;
|
|
283
|
+
}
|
|
284
|
+
if (script.kind() === 3) {
|
|
285
|
+
keyHashFromScript(
|
|
286
|
+
own(own(script.as_script_n_of_k()).native_scripts())
|
|
287
|
+
);
|
|
288
|
+
return;
|
|
289
|
+
}
|
|
230
290
|
}
|
|
231
291
|
}
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
292
|
+
if (scripts) keyHashFromScript(scripts);
|
|
293
|
+
const requiredSigners = own(txBody.required_signers());
|
|
294
|
+
if (requiredSigners) {
|
|
295
|
+
for (let i = 0; i < requiredSigners.len(); i++) {
|
|
296
|
+
usedKeyHashes.push(own(requiredSigners.get(i)).to_hex());
|
|
297
|
+
}
|
|
238
298
|
}
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
299
|
+
const collateral = own(txBody.collateral_inputs());
|
|
300
|
+
if (collateral) {
|
|
301
|
+
for (let i = 0; i < collateral.len(); i++) {
|
|
302
|
+
const input = own(collateral.get(i));
|
|
303
|
+
const txHash = own(input.transaction_id()).to_hex();
|
|
304
|
+
const outputIndex = Number(input.index());
|
|
305
|
+
const utxo = ownUtxos.find(
|
|
306
|
+
(utxo2) => utxo2.txHash === txHash && utxo2.outputIndex === outputIndex
|
|
307
|
+
);
|
|
308
|
+
if (utxo) {
|
|
309
|
+
const { paymentCredential } = getAddressDetails(utxo.address);
|
|
310
|
+
usedKeyHashes.push(paymentCredential?.hash);
|
|
311
|
+
}
|
|
252
312
|
}
|
|
253
313
|
}
|
|
254
|
-
|
|
255
|
-
|
|
314
|
+
return usedKeyHashes.filter((k) => ownKeyHashes.includes(k));
|
|
315
|
+
});
|
|
256
316
|
}
|
|
257
317
|
|
|
258
318
|
// src/wallet_selection.ts
|
|
259
|
-
import { fromHex as fromHex2, toHex } from "@lucid-evolution/core-utils";
|
|
319
|
+
import { fromHex as fromHex2, toHex, withCMLScope as withCMLScope2 } from "@lucid-evolution/core-utils";
|
|
260
320
|
import {
|
|
261
321
|
coreToUtxo,
|
|
262
322
|
credentialToRewardAddress,
|
|
@@ -326,16 +386,15 @@ var makeWalletFromSeed = (provider, network, seed, options) => {
|
|
|
326
386
|
const utxos = config.overriddenUTxOs !== void 0 ? config.overriddenUTxOs : await provider.getUtxos(address);
|
|
327
387
|
const ownKeyHashes = [paymentKeyHash, stakeKeyHash];
|
|
328
388
|
const usedKeyHashes = discoverOwnUsedTxKeyHashes(tx, ownKeyHashes, utxos);
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
const
|
|
332
|
-
const
|
|
333
|
-
CML.
|
|
334
|
-
priv
|
|
335
|
-
|
|
336
|
-
txWitnessSetBuilder.
|
|
337
|
-
}
|
|
338
|
-
return txWitnessSetBuilder.build();
|
|
389
|
+
return withCMLScope2((own) => {
|
|
390
|
+
const txWitnessSetBuilder = own(CML.TransactionWitnessSetBuilder.new());
|
|
391
|
+
const txHash = own(CML.hash_transaction(own(tx.body())));
|
|
392
|
+
for (const keyHash of usedKeyHashes) {
|
|
393
|
+
const priv = own(CML.PrivateKey.from_bech32(privKeyHashMap[keyHash]));
|
|
394
|
+
txWitnessSetBuilder.add_vkey(own(CML.make_vkey_witness(txHash, priv)));
|
|
395
|
+
}
|
|
396
|
+
return txWitnessSetBuilder.build();
|
|
397
|
+
});
|
|
339
398
|
};
|
|
340
399
|
return {
|
|
341
400
|
overrideUTxOs: (utxos) => config.overriddenUTxOs = utxos,
|
|
@@ -384,13 +443,14 @@ var makeWalletFromPrivateKey = (provider, network, privateKey) => {
|
|
|
384
443
|
overriddenUTxOs: void 0
|
|
385
444
|
};
|
|
386
445
|
const signTx = async (tx) => {
|
|
387
|
-
|
|
388
|
-
|
|
389
|
-
|
|
390
|
-
|
|
391
|
-
|
|
392
|
-
|
|
393
|
-
|
|
446
|
+
return withCMLScope2((own) => {
|
|
447
|
+
const witness = own(
|
|
448
|
+
CML.make_vkey_witness(own(CML.hash_transaction(own(tx.body()))), priv)
|
|
449
|
+
);
|
|
450
|
+
const txWitnessSetBuilder = own(CML.TransactionWitnessSetBuilder.new());
|
|
451
|
+
txWitnessSetBuilder.add_vkey(witness);
|
|
452
|
+
return txWitnessSetBuilder.build();
|
|
453
|
+
});
|
|
394
454
|
};
|
|
395
455
|
return {
|
|
396
456
|
overrideUTxOs: (utxos) => config.overriddenUTxOs = utxos,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@lucid-evolution/wallet",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.3",
|
|
4
4
|
"description": "",
|
|
5
5
|
"main": "./dist/index.js",
|
|
6
6
|
"types": "./dist/index.d.ts",
|
|
@@ -29,9 +29,9 @@
|
|
|
29
29
|
"@anastasia-labs/cardano-multiplatform-lib-nodejs": "6.2.0-1",
|
|
30
30
|
"bip39": "^3.1.0",
|
|
31
31
|
"@lucid-evolution/core-types": "0.3.0",
|
|
32
|
-
"@lucid-evolution/
|
|
33
|
-
"@lucid-evolution/
|
|
34
|
-
"@lucid-evolution/utils": "0.1.
|
|
32
|
+
"@lucid-evolution/sign_data": "0.1.32",
|
|
33
|
+
"@lucid-evolution/core-utils": "0.1.17",
|
|
34
|
+
"@lucid-evolution/utils": "0.1.75"
|
|
35
35
|
},
|
|
36
36
|
"devDependencies": {
|
|
37
37
|
"@types/node": "^20.12.8",
|