@arkade-os/sdk 0.4.75 → 0.4.76
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/adapters/expo.cjs +5 -5
- package/dist/adapters/expo.d.cts +2 -2
- package/dist/adapters/expo.d.ts +2 -2
- package/dist/adapters/expo.js +3 -3
- package/dist/adapters/indexedDB.cjs +5 -5
- package/dist/adapters/indexedDB.js +4 -4
- package/dist/{asyncStorageTaskQueue-5k0H_cDM.d.cts → asyncStorageTaskQueue-D7BU-BdP.d.cts} +1 -1
- package/dist/{asyncStorageTaskQueue-DjwCbb07.d.ts → asyncStorageTaskQueue-DrKbfleJ.d.ts} +1 -1
- package/dist/{chunk-YA3L3WL4.cjs → chunk-2KFXM3N5.cjs} +17 -17
- package/dist/{chunk-YA3L3WL4.cjs.map → chunk-2KFXM3N5.cjs.map} +1 -1
- package/dist/{chunk-PS564TAU.js → chunk-54W6QBXL.js} +3 -3
- package/dist/{chunk-PS564TAU.js.map → chunk-54W6QBXL.js.map} +1 -1
- package/dist/{chunk-4GLSOP6L.js → chunk-7UJLIZQU.js} +3 -3
- package/dist/{chunk-4GLSOP6L.js.map → chunk-7UJLIZQU.js.map} +1 -1
- package/dist/{chunk-YYWEBYFJ.cjs → chunk-CQNX4BTA.cjs} +49 -49
- package/dist/{chunk-YYWEBYFJ.cjs.map → chunk-CQNX4BTA.cjs.map} +1 -1
- package/dist/{chunk-UKFA7NVE.js → chunk-F6YOCYWU.js} +3 -3
- package/dist/{chunk-UKFA7NVE.js.map → chunk-F6YOCYWU.js.map} +1 -1
- package/dist/{chunk-EHJYR4E5.cjs → chunk-LHSVPDFJ.cjs} +501 -464
- package/dist/chunk-LHSVPDFJ.cjs.map +1 -0
- package/dist/{chunk-2Q2PYU3Y.cjs → chunk-LQM6RHNT.cjs} +10 -10
- package/dist/{chunk-2Q2PYU3Y.cjs.map → chunk-LQM6RHNT.cjs.map} +1 -1
- package/dist/{chunk-2ULUCL6A.js → chunk-MUBPGYUE.js} +4 -4
- package/dist/{chunk-2ULUCL6A.js.map → chunk-MUBPGYUE.js.map} +1 -1
- package/dist/{chunk-SKAL4MCW.js → chunk-O2BIWLZC.js} +4 -4
- package/dist/{chunk-SKAL4MCW.js.map → chunk-O2BIWLZC.js.map} +1 -1
- package/dist/{chunk-J5EX3OMM.cjs → chunk-P53OHGXY.cjs} +3 -3
- package/dist/{chunk-J5EX3OMM.cjs.map → chunk-P53OHGXY.cjs.map} +1 -1
- package/dist/{chunk-SH23SRZE.cjs → chunk-T327OEMV.cjs} +17 -17
- package/dist/{chunk-SH23SRZE.cjs.map → chunk-T327OEMV.cjs.map} +1 -1
- package/dist/{chunk-FTLPTF3R.js → chunk-WMHELOHH.js} +52 -15
- package/dist/chunk-WMHELOHH.js.map +1 -0
- package/dist/contracts/handlers/index.cjs +9 -9
- package/dist/contracts/handlers/index.d.cts +3 -3
- package/dist/contracts/handlers/index.d.ts +3 -3
- package/dist/contracts/handlers/index.js +2 -2
- package/dist/{delegate-D_sW61rj.d.ts → delegate-BAYpqkEx.d.ts} +1 -1
- package/dist/{delegate-D0v8yT-a.d.cts → delegate-CR7msIXK.d.cts} +1 -1
- package/dist/{hdWalletCapable-DHCNbAgl.d.ts → hdWalletCapable-BSF29IjK.d.ts} +2 -2
- package/dist/{hdWalletCapable-66hG5KQP.d.cts → hdWalletCapable-BbZxCUeZ.d.cts} +2 -2
- package/dist/{index-B2JSxDi1.d.cts → index-4NF3srcg.d.cts} +2 -2
- package/dist/{index-TZBbMNqA.d.ts → index-B_RYn9rg.d.cts} +4 -0
- package/dist/{index-TZBbMNqA.d.cts → index-B_RYn9rg.d.ts} +4 -0
- package/dist/{index-vUeTpifq.d.ts → index-Dj2yOhQ2.d.ts} +2 -2
- package/dist/index.cjs +303 -303
- package/dist/index.d.cts +8 -8
- package/dist/index.d.ts +8 -8
- package/dist/index.js +4 -4
- package/dist/repositories/realm/index.cjs +19 -19
- package/dist/repositories/realm/index.d.cts +2 -2
- package/dist/repositories/realm/index.d.ts +2 -2
- package/dist/repositories/realm/index.js +5 -5
- package/dist/repositories/sqlite/index.cjs +18 -18
- package/dist/repositories/sqlite/index.d.cts +2 -2
- package/dist/repositories/sqlite/index.d.ts +2 -2
- package/dist/repositories/sqlite/index.js +5 -5
- package/dist/{taskRunner-CAAPpdyi.d.cts → taskRunner-DGxde-YU.d.cts} +1 -1
- package/dist/{taskRunner-CairkunF.d.ts → taskRunner-TzGUhxP-.d.ts} +1 -1
- package/dist/wallet/expo/background.cjs +14 -14
- package/dist/wallet/expo/background.d.cts +3 -3
- package/dist/wallet/expo/background.d.ts +3 -3
- package/dist/wallet/expo/background.js +6 -6
- package/dist/wallet/expo/index.cjs +14 -14
- package/dist/wallet/expo/index.d.cts +4 -4
- package/dist/wallet/expo/index.d.ts +4 -4
- package/dist/wallet/expo/index.js +5 -5
- package/dist/worker/expo/index.cjs +9 -9
- package/dist/worker/expo/index.d.cts +4 -4
- package/dist/worker/expo/index.d.ts +4 -4
- package/dist/worker/expo/index.js +5 -5
- package/package.json +1 -1
- package/dist/chunk-EHJYR4E5.cjs.map +0 -1
- package/dist/chunk-FTLPTF3R.js.map +0 -1
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var chunkP53OHGXY_cjs = require('./chunk-P53OHGXY.cjs');
|
|
4
4
|
var chunk5BLDMQED_cjs = require('./chunk-5BLDMQED.cjs');
|
|
5
5
|
var base = require('@scure/base');
|
|
6
6
|
var descriptorsScure = require('@bitcoinerlab/descriptors-scure');
|
|
@@ -76,14 +76,14 @@ var ContractHandlerRegistry = class {
|
|
|
76
76
|
var contractHandlers = new ContractHandlerRegistry();
|
|
77
77
|
exports.DefaultVtxo = void 0;
|
|
78
78
|
((DefaultVtxo2) => {
|
|
79
|
-
class Script3 extends
|
|
79
|
+
class Script3 extends chunkP53OHGXY_cjs.VtxoScript {
|
|
80
80
|
/** Create the default virtual output script with one forfeit path and one exit path. */
|
|
81
81
|
constructor(options) {
|
|
82
82
|
const { pubKey, serverPubKey, csvTimelock } = options;
|
|
83
|
-
const forfeitScript =
|
|
83
|
+
const forfeitScript = chunkP53OHGXY_cjs.MultisigTapscript.encode({
|
|
84
84
|
pubkeys: [pubKey, serverPubKey]
|
|
85
85
|
}).script;
|
|
86
|
-
const exitScript =
|
|
86
|
+
const exitScript = chunkP53OHGXY_cjs.CSVMultisigTapscript.encode({
|
|
87
87
|
timelock: csvTimelock,
|
|
88
88
|
pubkeys: [pubKey]
|
|
89
89
|
}).script;
|
|
@@ -288,7 +288,7 @@ function extractPubKeyBytes(value) {
|
|
|
288
288
|
return base.hex.decode(extractPubKey(normalizeToDescriptor(value)));
|
|
289
289
|
}
|
|
290
290
|
function deserializeCsvTimelock(value) {
|
|
291
|
-
return value !== void 0 && value !== "" ?
|
|
291
|
+
return value !== void 0 && value !== "" ? chunkP53OHGXY_cjs.sequenceToTimelock(Number(value)) : exports.DefaultVtxo.Script.DEFAULT_TIMELOCK;
|
|
292
292
|
}
|
|
293
293
|
var CLTV_HEIGHT_THRESHOLD = 500000000n;
|
|
294
294
|
function isCltvSatisfied(context, locktime) {
|
|
@@ -330,7 +330,7 @@ function assertVhtlcSpendableNow(contract, context) {
|
|
|
330
330
|
function isCsvSpendable(context, sequence) {
|
|
331
331
|
if (sequence === void 0) return true;
|
|
332
332
|
if (!context.vtxo) return false;
|
|
333
|
-
const timelock =
|
|
333
|
+
const timelock = chunkP53OHGXY_cjs.sequenceToTimelock(sequence);
|
|
334
334
|
if (timelock.type === "blocks") {
|
|
335
335
|
if (context.blockHeight === void 0 || context.vtxo.status.block_height === void 0) {
|
|
336
336
|
return false;
|
|
@@ -388,21 +388,21 @@ function forfeitExitSpendablePaths(script, contract, context) {
|
|
|
388
388
|
async function detectUsedScripts(indexerProvider, scriptHexes) {
|
|
389
389
|
const used = /* @__PURE__ */ new Set();
|
|
390
390
|
const unique = [...new Set(scriptHexes)];
|
|
391
|
-
for (let offset = 0; offset < unique.length; offset +=
|
|
392
|
-
const scripts = unique.slice(offset, offset +
|
|
391
|
+
for (let offset = 0; offset < unique.length; offset += chunkP53OHGXY_cjs.SCRIPT_QUERY_CHUNK_SIZE) {
|
|
392
|
+
const scripts = unique.slice(offset, offset + chunkP53OHGXY_cjs.SCRIPT_QUERY_CHUNK_SIZE);
|
|
393
393
|
const remaining = new Set(scripts);
|
|
394
394
|
let pageIndex = 0;
|
|
395
395
|
let hasMore = true;
|
|
396
396
|
while (hasMore && remaining.size > 0) {
|
|
397
|
-
const { vtxos, page } = await
|
|
397
|
+
const { vtxos, page } = await chunkP53OHGXY_cjs.getNormalizedVtxos(indexerProvider, {
|
|
398
398
|
scripts,
|
|
399
399
|
pageIndex,
|
|
400
|
-
pageSize:
|
|
400
|
+
pageSize: chunkP53OHGXY_cjs.DEFAULT_PAGE_SIZE
|
|
401
401
|
});
|
|
402
402
|
for (const vtxo of vtxos) {
|
|
403
403
|
if (remaining.delete(vtxo.script)) used.add(vtxo.script);
|
|
404
404
|
}
|
|
405
|
-
hasMore = page ? vtxos.length ===
|
|
405
|
+
hasMore = page ? vtxos.length === chunkP53OHGXY_cjs.DEFAULT_PAGE_SIZE : false;
|
|
406
406
|
pageIndex++;
|
|
407
407
|
}
|
|
408
408
|
}
|
|
@@ -463,7 +463,7 @@ var DefaultContractHandler = {
|
|
|
463
463
|
return {
|
|
464
464
|
pubKey: base.hex.encode(params.pubKey),
|
|
465
465
|
serverPubKey: base.hex.encode(params.serverPubKey),
|
|
466
|
-
csvTimelock:
|
|
466
|
+
csvTimelock: chunkP53OHGXY_cjs.timelockToSequence(params.csvTimelock).toString()
|
|
467
467
|
};
|
|
468
468
|
},
|
|
469
469
|
deserializeParams(params) {
|
|
@@ -498,7 +498,7 @@ function defaultCandidatesAt(_index, descriptor, deps) {
|
|
|
498
498
|
params: {
|
|
499
499
|
pubKey: base.hex.encode(c.pubKey),
|
|
500
500
|
serverPubKey: base.hex.encode(c.serverPubKey),
|
|
501
|
-
csvTimelock:
|
|
501
|
+
csvTimelock: chunkP53OHGXY_cjs.timelockToSequence(c.csvTimelock).toString()
|
|
502
502
|
},
|
|
503
503
|
script: c.scriptHex,
|
|
504
504
|
address: c.script.address(deps.network.hrp, c.serverPubKey).encode()
|
|
@@ -514,12 +514,12 @@ function discoverDefaultRange(entries, deps) {
|
|
|
514
514
|
}
|
|
515
515
|
exports.DelegateVtxo = void 0;
|
|
516
516
|
((DelegateVtxo2) => {
|
|
517
|
-
class Script3 extends
|
|
517
|
+
class Script3 extends chunkP53OHGXY_cjs.VtxoScript {
|
|
518
518
|
/** Create a delegated virtual output script with forfeit, exit, and delegate paths. */
|
|
519
519
|
constructor(options) {
|
|
520
520
|
const defaultVtxo = new exports.DefaultVtxo.Script(options);
|
|
521
521
|
const { delegatePubKey, pubKey, serverPubKey } = options;
|
|
522
|
-
const delegateScript =
|
|
522
|
+
const delegateScript = chunkP53OHGXY_cjs.MultisigTapscript.encode({
|
|
523
523
|
pubkeys: [pubKey, delegatePubKey, serverPubKey]
|
|
524
524
|
}).script;
|
|
525
525
|
super([...defaultVtxo.scripts, delegateScript]);
|
|
@@ -558,7 +558,7 @@ var DelegateContractHandler = {
|
|
|
558
558
|
pubKey: base.hex.encode(params.pubKey),
|
|
559
559
|
serverPubKey: base.hex.encode(params.serverPubKey),
|
|
560
560
|
delegatePubKey: base.hex.encode(params.delegatePubKey),
|
|
561
|
-
csvTimelock:
|
|
561
|
+
csvTimelock: chunkP53OHGXY_cjs.timelockToSequence(params.csvTimelock).toString()
|
|
562
562
|
};
|
|
563
563
|
},
|
|
564
564
|
deserializeParams(params) {
|
|
@@ -602,7 +602,7 @@ function delegateCandidatesAt(_index, descriptor, deps) {
|
|
|
602
602
|
pubKey: base.hex.encode(c.pubKey),
|
|
603
603
|
serverPubKey: base.hex.encode(c.serverPubKey),
|
|
604
604
|
delegatePubKey: base.hex.encode(delegatePubKey),
|
|
605
|
-
csvTimelock:
|
|
605
|
+
csvTimelock: chunkP53OHGXY_cjs.timelockToSequence(c.csvTimelock).toString()
|
|
606
606
|
},
|
|
607
607
|
script: c.scriptHex,
|
|
608
608
|
address: c.script.address(deps.network.hrp, c.serverPubKey).encode()
|
|
@@ -1452,7 +1452,7 @@ function computeArkadeScriptPublicKey(pubKey, script) {
|
|
|
1452
1452
|
// src/script/vhtlc.ts
|
|
1453
1453
|
exports.VHTLC = void 0;
|
|
1454
1454
|
((VHTLC2) => {
|
|
1455
|
-
class BaseScript extends
|
|
1455
|
+
class BaseScript extends chunkP53OHGXY_cjs.VtxoScript {
|
|
1456
1456
|
options;
|
|
1457
1457
|
claimScript;
|
|
1458
1458
|
refundScript;
|
|
@@ -1479,27 +1479,27 @@ exports.VHTLC = void 0;
|
|
|
1479
1479
|
unilateralRefundWithoutReceiverDelay
|
|
1480
1480
|
} = options;
|
|
1481
1481
|
const conditionScript = preimageCondition(preimageHash);
|
|
1482
|
-
const claimScript =
|
|
1482
|
+
const claimScript = chunkP53OHGXY_cjs.ConditionMultisigTapscript.encode({
|
|
1483
1483
|
conditionScript,
|
|
1484
1484
|
pubkeys: [receiver, server]
|
|
1485
1485
|
}).script;
|
|
1486
|
-
const refundScript =
|
|
1486
|
+
const refundScript = chunkP53OHGXY_cjs.MultisigTapscript.encode({
|
|
1487
1487
|
pubkeys: [sender, receiver, server]
|
|
1488
1488
|
}).script;
|
|
1489
|
-
const refundWithoutReceiverScript =
|
|
1489
|
+
const refundWithoutReceiverScript = chunkP53OHGXY_cjs.CLTVMultisigTapscript.encode({
|
|
1490
1490
|
absoluteTimelock: refundLocktime,
|
|
1491
1491
|
pubkeys: [sender, server]
|
|
1492
1492
|
}).script;
|
|
1493
|
-
const unilateralClaimScript =
|
|
1493
|
+
const unilateralClaimScript = chunkP53OHGXY_cjs.ConditionCSVMultisigTapscript.encode({
|
|
1494
1494
|
conditionScript,
|
|
1495
1495
|
timelock: unilateralClaimDelay,
|
|
1496
1496
|
pubkeys: [receiver]
|
|
1497
1497
|
}).script;
|
|
1498
|
-
const unilateralRefundScript =
|
|
1498
|
+
const unilateralRefundScript = chunkP53OHGXY_cjs.CSVMultisigTapscript.encode({
|
|
1499
1499
|
timelock: unilateralRefundDelay,
|
|
1500
1500
|
pubkeys: [sender, receiver]
|
|
1501
1501
|
}).script;
|
|
1502
|
-
const unilateralRefundWithoutReceiverScript =
|
|
1502
|
+
const unilateralRefundWithoutReceiverScript = chunkP53OHGXY_cjs.CSVMultisigTapscript.encode({
|
|
1503
1503
|
timelock: unilateralRefundWithoutReceiverDelay,
|
|
1504
1504
|
pubkeys: [sender]
|
|
1505
1505
|
}).script;
|
|
@@ -1519,7 +1519,7 @@ exports.VHTLC = void 0;
|
|
|
1519
1519
|
const covenants = options.nonInteractiveParameters;
|
|
1520
1520
|
if (covenants) {
|
|
1521
1521
|
arkadeScriptNic = enforcePayToMaybeAsset(covenants.receiverPkScript, options.asset);
|
|
1522
|
-
nonInteractiveClaimScript =
|
|
1522
|
+
nonInteractiveClaimScript = chunkP53OHGXY_cjs.ConditionMultisigTapscript.encode({
|
|
1523
1523
|
conditionScript,
|
|
1524
1524
|
pubkeys: [
|
|
1525
1525
|
server,
|
|
@@ -1532,12 +1532,12 @@ exports.VHTLC = void 0;
|
|
|
1532
1532
|
covenants.emulatorPubkey,
|
|
1533
1533
|
arkadeScriptNir
|
|
1534
1534
|
);
|
|
1535
|
-
nonInteractiveRefundScript =
|
|
1535
|
+
nonInteractiveRefundScript = chunkP53OHGXY_cjs.MultisigTapscript.encode({
|
|
1536
1536
|
pubkeys: [server, receiver, nirCosigner]
|
|
1537
1537
|
}).script;
|
|
1538
1538
|
scripts.push(nonInteractiveRefundScript);
|
|
1539
1539
|
if (covenants.legacy !== "preTimelockedRefund") {
|
|
1540
|
-
nonInteractiveRefundWithoutReceiverScript =
|
|
1540
|
+
nonInteractiveRefundWithoutReceiverScript = chunkP53OHGXY_cjs.CLTVMultisigTapscript.encode({
|
|
1541
1541
|
absoluteTimelock: refundLocktime,
|
|
1542
1542
|
pubkeys: [server, nirCosigner]
|
|
1543
1543
|
}).script;
|
|
@@ -1851,9 +1851,9 @@ var VHTLCContractHandler = {
|
|
|
1851
1851
|
server: base.hex.encode(params.server),
|
|
1852
1852
|
hash: base.hex.encode(params.preimageHash),
|
|
1853
1853
|
refundLocktime: params.refundLocktime.toString(),
|
|
1854
|
-
claimDelay:
|
|
1855
|
-
refundDelay:
|
|
1856
|
-
refundNoReceiverDelay:
|
|
1854
|
+
claimDelay: chunkP53OHGXY_cjs.timelockToSequence(params.unilateralClaimDelay).toString(),
|
|
1855
|
+
refundDelay: chunkP53OHGXY_cjs.timelockToSequence(params.unilateralRefundDelay).toString(),
|
|
1856
|
+
refundNoReceiverDelay: chunkP53OHGXY_cjs.timelockToSequence(
|
|
1857
1857
|
params.unilateralRefundWithoutReceiverDelay
|
|
1858
1858
|
).toString()
|
|
1859
1859
|
};
|
|
@@ -1865,9 +1865,9 @@ var VHTLCContractHandler = {
|
|
|
1865
1865
|
server: base.hex.decode(params.server),
|
|
1866
1866
|
preimageHash: base.hex.decode(params.hash),
|
|
1867
1867
|
refundLocktime: BigInt(params.refundLocktime),
|
|
1868
|
-
unilateralClaimDelay:
|
|
1869
|
-
unilateralRefundDelay:
|
|
1870
|
-
unilateralRefundWithoutReceiverDelay:
|
|
1868
|
+
unilateralClaimDelay: chunkP53OHGXY_cjs.sequenceToTimelock(Number(params.claimDelay)),
|
|
1869
|
+
unilateralRefundDelay: chunkP53OHGXY_cjs.sequenceToTimelock(Number(params.refundDelay)),
|
|
1870
|
+
unilateralRefundWithoutReceiverDelay: chunkP53OHGXY_cjs.sequenceToTimelock(
|
|
1871
1871
|
Number(params.refundNoReceiverDelay)
|
|
1872
1872
|
)
|
|
1873
1873
|
};
|
|
@@ -2113,9 +2113,9 @@ var VHTLCV2ContractHandler = {
|
|
|
2113
2113
|
server: base.hex.encode(params.server),
|
|
2114
2114
|
hash: base.hex.encode(params.preimageHash),
|
|
2115
2115
|
refundLocktime: params.refundLocktime.toString(),
|
|
2116
|
-
claimDelay:
|
|
2117
|
-
refundDelay:
|
|
2118
|
-
refundNoReceiverDelay:
|
|
2116
|
+
claimDelay: chunkP53OHGXY_cjs.timelockToSequence(params.unilateralClaimDelay).toString(),
|
|
2117
|
+
refundDelay: chunkP53OHGXY_cjs.timelockToSequence(params.unilateralRefundDelay).toString(),
|
|
2118
|
+
refundNoReceiverDelay: chunkP53OHGXY_cjs.timelockToSequence(
|
|
2119
2119
|
params.unilateralRefundWithoutReceiverDelay
|
|
2120
2120
|
).toString(),
|
|
2121
2121
|
// The on-disk keys keep their per-leaf names even though the typed
|
|
@@ -2215,9 +2215,9 @@ var VHTLCV2ContractHandler = {
|
|
|
2215
2215
|
preimageHash: base.hex.decode(params.hash),
|
|
2216
2216
|
refundLocktime: BigInt(params.refundLocktime),
|
|
2217
2217
|
...asset && { asset },
|
|
2218
|
-
unilateralClaimDelay:
|
|
2219
|
-
unilateralRefundDelay:
|
|
2220
|
-
unilateralRefundWithoutReceiverDelay:
|
|
2218
|
+
unilateralClaimDelay: chunkP53OHGXY_cjs.sequenceToTimelock(Number(params.claimDelay)),
|
|
2219
|
+
unilateralRefundDelay: chunkP53OHGXY_cjs.sequenceToTimelock(Number(params.refundDelay)),
|
|
2220
|
+
unilateralRefundWithoutReceiverDelay: chunkP53OHGXY_cjs.sequenceToTimelock(
|
|
2221
2221
|
Number(params.refundNoReceiverDelay)
|
|
2222
2222
|
),
|
|
2223
2223
|
...claim && refund && {
|
|
@@ -2490,7 +2490,7 @@ var BoardingContractHandler = {
|
|
|
2490
2490
|
const coins = await deps.onchainProvider.getCoins(onchainAddress);
|
|
2491
2491
|
if (coins.length === 0) return [];
|
|
2492
2492
|
const scriptHex = base.hex.encode(script.pkScript);
|
|
2493
|
-
const boardingSeq =
|
|
2493
|
+
const boardingSeq = chunkP53OHGXY_cjs.timelockToSequence(deps.boardingTimelock);
|
|
2494
2494
|
return [
|
|
2495
2495
|
{
|
|
2496
2496
|
type: "boarding",
|
|
@@ -2651,27 +2651,27 @@ function encodeTapscriptSegment(seg, pubkeys, args) {
|
|
|
2651
2651
|
if (seg.csv) {
|
|
2652
2652
|
const timelock = { type: seg.csv.type, value: resolveTimelockValue(seg.csv.value, args) };
|
|
2653
2653
|
if (seg.asm) {
|
|
2654
|
-
return
|
|
2654
|
+
return chunkP53OHGXY_cjs.ConditionCSVMultisigTapscript.encode({
|
|
2655
2655
|
conditionScript: resolveAsm(seg.asm, args),
|
|
2656
2656
|
timelock,
|
|
2657
2657
|
pubkeys
|
|
2658
2658
|
});
|
|
2659
2659
|
}
|
|
2660
|
-
return
|
|
2660
|
+
return chunkP53OHGXY_cjs.CSVMultisigTapscript.encode({ timelock, pubkeys });
|
|
2661
2661
|
}
|
|
2662
2662
|
if (seg.cltv !== void 0) {
|
|
2663
|
-
return
|
|
2663
|
+
return chunkP53OHGXY_cjs.CLTVMultisigTapscript.encode({
|
|
2664
2664
|
absoluteTimelock: resolveTimelockValue(seg.cltv, args),
|
|
2665
2665
|
pubkeys
|
|
2666
2666
|
});
|
|
2667
2667
|
}
|
|
2668
2668
|
if (seg.asm) {
|
|
2669
|
-
return
|
|
2669
|
+
return chunkP53OHGXY_cjs.ConditionMultisigTapscript.encode({
|
|
2670
2670
|
conditionScript: resolveAsm(seg.asm, args),
|
|
2671
2671
|
pubkeys
|
|
2672
2672
|
});
|
|
2673
2673
|
}
|
|
2674
|
-
return
|
|
2674
|
+
return chunkP53OHGXY_cjs.MultisigTapscript.encode({ pubkeys });
|
|
2675
2675
|
}
|
|
2676
2676
|
function compileFunctions(program, args, keys) {
|
|
2677
2677
|
if (program.version !== SUPPORTED_PROGRAM_VERSION) {
|
|
@@ -2701,7 +2701,7 @@ function compileFunctions(program, args, keys) {
|
|
|
2701
2701
|
return { name: names[i], def, leafScript, arkadeScript, signerKeys: pubkeys };
|
|
2702
2702
|
});
|
|
2703
2703
|
}
|
|
2704
|
-
var ArkadeProgramScript = class extends
|
|
2704
|
+
var ArkadeProgramScript = class extends chunkP53OHGXY_cjs.VtxoScript {
|
|
2705
2705
|
constructor(program, args, keys) {
|
|
2706
2706
|
const partial = compileFunctions(program, args, keys);
|
|
2707
2707
|
super(partial.map((p) => p.leafScript));
|
|
@@ -2914,7 +2914,7 @@ function pathsFor(script, context, opts) {
|
|
|
2914
2914
|
continue;
|
|
2915
2915
|
}
|
|
2916
2916
|
if (requiresServer) continue;
|
|
2917
|
-
const sequence = csv ? Number(
|
|
2917
|
+
const sequence = csv ? Number(chunkP53OHGXY_cjs.timelockToSequence(csv)) : void 0;
|
|
2918
2918
|
if (opts.checkTimelocks && csv && !isCsvSpendable(context, sequence)) continue;
|
|
2919
2919
|
if (opts.checkTimelocks && cltv !== void 0 && !isCltvSatisfied(context, cltv)) {
|
|
2920
2920
|
continue;
|
|
@@ -3043,5 +3043,5 @@ exports.toASM = toASM;
|
|
|
3043
3043
|
exports.toXOnly = toXOnly;
|
|
3044
3044
|
exports.validateProgram = validateProgram;
|
|
3045
3045
|
exports.witnessRefToBytes = witnessRefToBytes;
|
|
3046
|
-
//# sourceMappingURL=chunk-
|
|
3047
|
-
//# sourceMappingURL=chunk-
|
|
3046
|
+
//# sourceMappingURL=chunk-CQNX4BTA.cjs.map
|
|
3047
|
+
//# sourceMappingURL=chunk-CQNX4BTA.cjs.map
|