@meshsdk/core 1.5.7-beta.1 → 1.5.7

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/core.js CHANGED
@@ -1,24 +1,12 @@
1
- import * as n from "@emurgo/cardano-serialization-lib-asmjs";
2
- import j from "axios";
3
- import { mnemonicToEntropy as ye, generateMnemonic as $e } from "bip39";
4
- import { COSEKey as Ce, COSESign1 as ze, Label as J, Int as _t, BigNum as Kt, KeyType as We, AlgorithmId as we, CBORValue as Nt, HeaderMap as Wt, Headers as Je, ProtectedHeaderMap as je, COSESign1Builder as Xe } from "@emurgo/cardano-message-signing-asmjs";
5
- const Ze = ["testnet", "preview", "preprod", "mainnet"], ts = (s) => Ze.includes(s);
6
- let es = (s) => crypto.getRandomValues(new Uint8Array(s)), ss = (s, e, t) => {
7
- let r = (2 << Math.log(s.length - 1) / Math.LN2) - 1, a = -~(1.6 * r * e / s.length);
8
- return (i = e) => {
9
- let o = "";
10
- for (; ; ) {
11
- let c = t(a), u = a;
12
- for (; u--; )
13
- if (o += s[c[u] & r] || "", o.length === i)
14
- return o;
15
- }
16
- };
17
- }, Be = (s, e = 21) => ss(s, e, es);
18
- const Ee = {
1
+ import { customAlphabet as ye } from "nanoid";
2
+ import * as i from "@emurgo/cardano-serialization-lib-nodejs";
3
+ import L from "axios";
4
+ import { mnemonicToEntropy as Ce, generateMnemonic as $e } from "bip39";
5
+ import { COSEKey as we, COSESign1 as ze, Label as j, Int as yt, BigNum as Nt, KeyType as We, AlgorithmId as Be, CBORValue as Pt, HeaderMap as Wt, Headers as Je, ProtectedHeaderMap as je, COSESign1Builder as Xe } from "@emurgo/cardano-message-signing-nodejs";
6
+ const Ze = ["testnet", "preview", "preprod", "mainnet"], ts = (s) => Ze.includes(s), xe = {
19
7
  mem: 7e6,
20
8
  steps: 3e9
21
- }, q = {
9
+ }, G = {
22
10
  epoch: 0,
23
11
  coinsPerUTxOSize: "4310",
24
12
  priceMem: 0.0577,
@@ -39,23 +27,23 @@ const Ee = {
39
27
  maxTxExSteps: "10000000000",
40
28
  maxBlockExMem: "80000000",
41
29
  maxBlockExSteps: "40000000000"
42
- }, kt = 2147483648, Et = {
43
- V1: n.Language.new_plutus_v1(),
44
- V2: n.Language.new_plutus_v2()
45
- }, F = 56, rs = {
46
- CERT: n.RedeemerTag.new_cert(),
47
- MINT: n.RedeemerTag.new_mint(),
48
- REWARD: n.RedeemerTag.new_reward(),
49
- SPEND: n.RedeemerTag.new_spend()
50
- }, xt = {
30
+ }, Ut = 2147483648, xt = {
31
+ V1: i.Language.new_plutus_v1(),
32
+ V2: i.Language.new_plutus_v2()
33
+ }, M = 56, es = {
34
+ CERT: i.RedeemerTag.new_cert(),
35
+ MINT: i.RedeemerTag.new_mint(),
36
+ REWARD: i.RedeemerTag.new_reward(),
37
+ SPEND: i.RedeemerTag.new_spend()
38
+ }, Et = {
51
39
  testnet: ["74", "1598400", "1595967616", "432000"],
52
40
  preview: ["183", "15811222", "1682467200", "86400"],
53
41
  preprod: ["65", "26438400", "1682121600", "432000"],
54
42
  mainnet: ["208", "4492800", "1596059091", "432000"]
55
43
  }, Jt = {
56
- ALONZO: n.TxBuilderConstants.plutus_alonzo_cost_models(),
44
+ ALONZO: i.TxBuilderConstants.plutus_alonzo_cost_models(),
57
45
  BABBAGE: (() => {
58
- const s = n.Costmdls.new(), e = n.CostModel.new();
46
+ const s = i.Costmdls.new(), e = i.CostModel.new();
59
47
  Object.values({
60
48
  "addInteger-cpu-arguments-intercept": 205665,
61
49
  "addInteger-cpu-arguments-slope": 812,
@@ -223,8 +211,8 @@ const Ee = {
223
211
  "verifyEd25519Signature-cpu-arguments-intercept": 57996947,
224
212
  "verifyEd25519Signature-cpu-arguments-slope": 18975,
225
213
  "verifyEd25519Signature-memory-arguments": 10
226
- }).forEach((r, a) => e.set(a, n.Int.new_i32(r)));
227
- const t = n.CostModel.new();
214
+ }).forEach((r, a) => e.set(a, i.Int.new_i32(r)));
215
+ const t = i.CostModel.new();
228
216
  return Object.values({
229
217
  "addInteger-cpu-arguments-intercept": 205665,
230
218
  "addInteger-cpu-arguments-slope": 812,
@@ -401,9 +389,9 @@ const Ee = {
401
389
  "verifySchnorrSecp256k1Signature-cpu-arguments-intercept": 38887044,
402
390
  "verifySchnorrSecp256k1Signature-cpu-arguments-slope": 32947,
403
391
  "verifySchnorrSecp256k1Signature-memory-arguments": 10
404
- }).forEach((r, a) => t.set(a, n.Int.new_i32(r))), s.insert(n.Language.new_plutus_v1(), e), s.insert(n.Language.new_plutus_v2(), t), s;
392
+ }).forEach((r, a) => t.set(a, i.Int.new_i32(r))), s.insert(i.Language.new_plutus_v1(), e), s.insert(i.Language.new_plutus_v2(), t), s;
405
393
  })()
406
- }, as = {
394
+ }, ss = {
407
395
  ALONZO: {
408
396
  V1: "a141005901d59f1a000302590001011a00060bc719026d00011a000249f01903e800011a000249f018201a0025cea81971f70419744d186419744d186419744d186419744d186419744d186419744d18641864186419744d18641a000249f018201a000249f018201a000249f018201a000249f01903e800011a000249f018201a000249f01903e800081a000242201a00067e2318760001011a000249f01903e800081a000249f01a0001b79818f7011a000249f0192710011a0002155e19052e011903e81a000249f01903e8011a000249f018201a000249f018201a000249f0182001011a000249f0011a000249f0041a000194af18f8011a000194af18f8011a0002377c190556011a0002bdea1901f1011a000249f018201a000249f018201a000249f018201a000249f018201a000249f018201a000249f018201a000242201a00067e23187600010119f04c192bd200011a000249f018201a000242201a00067e2318760001011a000242201a00067e2318760001011a0025cea81971f704001a000141bb041a000249f019138800011a000249f018201a000302590001011a000249f018201a000249f018201a000249f018201a000249f018201a000249f018201a000249f018201a000249f018201a00330da70101ff"
409
397
  },
@@ -411,15 +399,15 @@ const Ee = {
411
399
  V1: "a141005901b69f1a0003236119032c01011903e819023b00011903e8195e7104011903e818201a0001ca761928eb041959d818641959d818641959d818641959d818641959d818641959d81864186418641959d81864194c5118201a0002acfa182019b551041a000363151901ff00011a00015c3518201a000797751936f404021a0002ff941a0006ea7818dc0001011903e8196ff604021a0003bd081a00034ec5183e011a00102e0f19312a011a00032e801901a5011a0002da781903e819cf06011a00013a34182019a8f118201903e818201a00013aac0119e143041903e80a1a00030219189c011a00030219189c011a0003207c1901d9011a000330001901ff0119ccf3182019fd40182019ffd5182019581e18201940b318201a00012adf18201a0002ff941a0006ea7818dc0001011a00010f92192da7000119eabb18201a0002ff941a0006ea7818dc0001011a0002ff941a0006ea7818dc0001011a000c504e197712041a001d6af61a0001425b041a00040c660004001a00014fab18201a0003236119032c010119a0de18201a00033d7618201979f41820197fb8182019a95d1820197df718201995aa18201a009063b91903fd0aff",
412
400
  V2: "a20198af1a0003236119032c01011903e819023b00011903e8195e7104011903e818201a0001ca761928eb041959d818641959d818641959d818641959d818641959d818641959d81864186418641959d81864194c5118201a0002acfa182019b551041a000363151901ff00011a00015c3518201a000797751936f404021a0002ff941a0006ea7818dc0001011903e8196ff604021a0003bd081a00034ec5183e011a00102e0f19312a011a00032e801901a5011a0002da781903e819cf06011a00013a34182019a8f118201903e818201a00013aac0119e143041903e80a1a00030219189c011a00030219189c011a0003207c1901d9011a000330001901ff0119ccf3182019fd40182019ffd5182019581e18201940b318201a00012adf18201a0002ff941a0006ea7818dc0001011a00010f92192da7000119eabb18201a0002ff941a0006ea7818dc0001011a0002ff941a0006ea7818dc0001011a0011b22c1a0005fdde00021a000c504e197712041a001d6af61a0001425b041a00040c660004001a00014fab18201a0003236119032c010119a0de18201a00033d7618201979f41820197fb8182019a95d1820197df718201995aa18201b00000004a817c8001b00000004a817c8001a009063b91903fd0a1b00000004a817c800001b00000004a817c80041005901b69f1a0003236119032c01011903e819023b00011903e8195e7104011903e818201a0001ca761928eb041959d818641959d818641959d818641959d818641959d818641959d81864186418641959d81864194c5118201a0002acfa182019b551041a000363151901ff00011a00015c3518201a000797751936f404021a0002ff941a0006ea7818dc0001011903e8196ff604021a0003bd081a00034ec5183e011a00102e0f19312a011a00032e801901a5011a0002da781903e819cf06011a00013a34182019a8f118201903e818201a00013aac0119e143041903e80a1a00030219189c011a00030219189c011a0003207c1901d9011a000330001901ff0119ccf3182019fd40182019ffd5182019581e18201940b318201a00012adf18201a0002ff941a0006ea7818dc0001011a00010f92192da7000119eabb18201a0002ff941a0006ea7818dc0001011a0002ff941a0006ea7818dc0001011a000c504e197712041a001d6af61a0001425b041a00040c660004001a00014fab18201a0003236119032c010119a0de18201a00033d7618201979f41820197fb8182019a95d1820197df718201995aa18201a009063b91903fd0aff"
413
401
  }
414
- }, Tt = {
415
- [n.NetworkInfo.testnet().network_id()]: "8d18d786e92776c824607fd8e193ec535c79dc61ea2405ddf3b09fe3",
416
- [n.NetworkInfo.mainnet().network_id()]: "f0ff48bbb7bbe9d59a40f1ce90e9e9d0ff5002ec48f232b49ca0fb9a"
417
- }, ns = {
402
+ }, Mt = {
403
+ [i.NetworkInfo.testnet().network_id()]: "8d18d786e92776c824607fd8e193ec535c79dc61ea2405ddf3b09fe3",
404
+ [i.NetworkInfo.mainnet().network_id()]: "f0ff48bbb7bbe9d59a40f1ce90e9e9d0ff5002ec48f232b49ca0fb9a"
405
+ }, rs = {
418
406
  mainnet: "wss://ogmios-api.mainnet.dandelion.link",
419
407
  preprod: "wss://ogmios-api.iohk-preprod.dandelion.link",
420
408
  preview: "__TBD_SOON_TM__",
421
409
  testnet: "wss://ogmios-api.testnet.dandelion.link"
422
- }, is = {
410
+ }, as = {
423
411
  LQ: "da8c30857834c6ae7203935b89278c532b3995245295456f993e1d244c51",
424
412
  MIN: "29d222ce763455e3d7a09a665ce554f00ac89d2e99a1a83d267170c64d494e",
425
413
  NTX: "edfd7a1d77bcb8b884c474bdc92a16002d1fb720e454fa6e993444794e5458",
@@ -458,124 +446,124 @@ const Ee = {
458
446
  "gerowallet",
459
447
  "typhoncip30",
460
448
  "vespr"
461
- ], os = (s, e, t = "5000000") => {
462
- const r = n.BigNum.from_str(s.get("lovelace") ?? "0").checked_add(n.BigNum.from_str(t)), a = e.filter((c) => c.output.amount.filter((u) => u.unit !== "lovelace").some((u) => s.has(u.unit))), i = gs(a);
449
+ ], ns = (s, e, t = "5000000") => {
450
+ const r = i.BigNum.from_str(s.get("lovelace") ?? "0").checked_add(i.BigNum.from_str(t)), a = e.filter((c) => c.output.amount.filter((u) => u.unit !== "lovelace").some((u) => s.has(u.unit))), n = us(a);
463
451
  return [
464
- ...i.less_than(r) ? ds(r.clamped_sub(i).to_str(), e.filter((c) => !a.some((u) => u.input.txHash === c.input.txHash && u.input.outputIndex === c.input.outputIndex))) : [],
452
+ ...n.less_than(r) ? As(r.clamped_sub(n).to_str(), e.filter((c) => !a.some((u) => u.input.txHash === c.input.txHash && u.input.outputIndex === c.input.outputIndex))) : [],
465
453
  ...a
466
454
  ];
467
- }, Ar = (s, e, t = !1, { maxTxSize: r, minFeeA: a, minFeeB: i } = q) => {
468
- const o = e.filter((g) => xe(g) === !1).sort(Mt), c = n.BigNum.from_str(Ge(r, a, i)), u = t ? n.BigNum.from_str(s).checked_add(c).to_str() : s;
469
- return gt(o, /* @__PURE__ */ new Map([
455
+ }, ir = (s, e, t = !1, { maxTxSize: r, minFeeA: a, minFeeB: n } = G) => {
456
+ const o = e.filter((g) => Ee(g) === !1).sort(Ht), c = i.BigNum.from_str(Le(r, a, n)), u = t ? i.BigNum.from_str(s).checked_add(c).to_str() : s;
457
+ return lt(o, /* @__PURE__ */ new Map([
470
458
  ["lovelace", u]
471
459
  ]));
472
- }, cs = (s, e, t = !1, r = q) => {
473
- const a = e.filter(xe).sort(Mt), i = As(r), o = s.get("lovelace") ?? "0", c = t ? n.BigNum.from_str(o).checked_add(i).to_str() : o;
474
- return s.set("lovelace", c), gt(a, s);
475
- }, us = (s, e) => Array.from(e, (t) => ({ unit: t[0], quantity: n.BigNum.from_str(t[1]) })).every((t) => s.filter((r) => r.output.amount.find((a) => a.unit === t.unit) !== void 0).reduce((r, a) => {
476
- const i = a.output.amount.reduce((o, c) => o.checked_add(n.BigNum.from_str(t.unit === c.unit ? c.quantity : "0")), n.BigNum.from_str("0"));
477
- return r.checked_add(i);
478
- }, n.BigNum.from_str("0")).less_than(t.quantity) === !1), Mt = (s, e) => {
479
- var a, i;
480
- const t = n.BigNum.from_str(((a = s.output.amount.find((o) => o.unit === "lovelace")) == null ? void 0 : a.quantity) ?? "0");
481
- return n.BigNum.from_str(((i = e.output.amount.find((o) => o.unit === "lovelace")) == null ? void 0 : i.quantity) ?? "0").compare(t);
482
- }, As = (s) => {
460
+ }, is = (s, e, t = !1, r = G) => {
461
+ const a = e.filter(Ee).sort(Ht), n = cs(r), o = s.get("lovelace") ?? "0", c = t ? i.BigNum.from_str(o).checked_add(n).to_str() : o;
462
+ return s.set("lovelace", c), lt(a, s);
463
+ }, os = (s, e) => Array.from(e, (t) => ({ unit: t[0], quantity: i.BigNum.from_str(t[1]) })).every((t) => s.filter((r) => r.output.amount.find((a) => a.unit === t.unit) !== void 0).reduce((r, a) => {
464
+ const n = a.output.amount.reduce((o, c) => o.checked_add(i.BigNum.from_str(t.unit === c.unit ? c.quantity : "0")), i.BigNum.from_str("0"));
465
+ return r.checked_add(n);
466
+ }, i.BigNum.from_str("0")).less_than(t.quantity) === !1), Ht = (s, e) => {
467
+ var a, n;
468
+ const t = i.BigNum.from_str(((a = s.output.amount.find((o) => o.unit === "lovelace")) == null ? void 0 : a.quantity) ?? "0");
469
+ return i.BigNum.from_str(((n = e.output.amount.find((o) => o.unit === "lovelace")) == null ? void 0 : n.quantity) ?? "0").compare(t);
470
+ }, cs = (s) => {
483
471
  const { maxTxSize: e, minFeeA: t, minFeeB: r } = s;
484
- return n.BigNum.from_str(Ge(e, t, r));
485
- }, xe = (s) => s.output.amount.length > 1, gs = (s) => s.reduce((e, t) => {
472
+ return i.BigNum.from_str(Le(e, t, r));
473
+ }, Ee = (s) => s.output.amount.length > 1, us = (s) => s.reduce((e, t) => {
486
474
  var a;
487
- const r = ((a = t.output.amount.find((i) => i.unit === "lovelace")) == null ? void 0 : a.quantity) ?? "0";
488
- return e.checked_add(n.BigNum.from_str(r));
489
- }, n.BigNum.from_str("0")), ds = (s, e) => {
490
- const t = e.sort(Mt);
491
- return gt(t, /* @__PURE__ */ new Map([
475
+ const r = ((a = t.output.amount.find((n) => n.unit === "lovelace")) == null ? void 0 : a.quantity) ?? "0";
476
+ return e.checked_add(i.BigNum.from_str(r));
477
+ }, i.BigNum.from_str("0")), As = (s, e) => {
478
+ const t = e.sort(Ht);
479
+ return lt(t, /* @__PURE__ */ new Map([
492
480
  ["lovelace", s]
493
481
  ]));
494
- }, gt = (s, e, t = []) => s.length === 0 || us(t, e) ? t : ls(s[0], e) ? gt(s.slice(1), e, [...t, s[0]]) : gt(s.slice(1), e, t), ls = (s, e) => Array.from(e.keys()).some((t) => s.output.amount.find((r) => r.unit === t) !== void 0), hs = (s, e) => {
495
- const t = ms(e), r = ps(s, e);
482
+ }, lt = (s, e, t = []) => s.length === 0 || os(t, e) ? t : ds(s[0], e) ? lt(s.slice(1), e, [...t, s[0]]) : lt(s.slice(1), e, t), ds = (s, e) => Array.from(e.keys()).some((t) => s.output.amount.find((r) => r.unit === t) !== void 0), gs = (s, e) => {
483
+ const t = hs(e), r = Is(s, e);
496
484
  return {
497
- coseKey: b(t.to_bytes()),
498
- coseSign1: b(r.to_bytes())
485
+ coseKey: D(t.to_bytes()),
486
+ coseSign1: D(r.to_bytes())
499
487
  };
500
- }, gr = (s, e, { key: t, signature: r }) => {
488
+ }, or = (s, e, { key: t, signature: r }) => {
501
489
  var o, c;
502
- const a = Ce.from_bytes(m(t)), i = ze.from_bytes(m(r));
490
+ const a = we.from_bytes(m(t)), n = ze.from_bytes(m(r));
503
491
  if ((s == null ? void 0 : s.length) > 0) {
504
- const u = b(i.payload() ?? new Uint8Array());
492
+ const u = D(n.payload() ?? new Uint8Array());
505
493
  if (S(s) !== u)
506
494
  return !1;
507
495
  }
508
496
  if ((e == null ? void 0 : e.length) > 0) {
509
- const A = (o = i.headers().protected().deserialized_headers().header(J.new_text("address"))) == null ? void 0 : o.as_bytes();
497
+ const A = (o = n.headers().protected().deserialized_headers().header(j.new_text("address"))) == null ? void 0 : o.as_bytes();
510
498
  if (A === void 0)
511
499
  throw new Error("Couldn't find a signer address in signature");
512
- const d = (c = a.header(J.new_int(_t.new_negative(Kt.from_str("2"))))) == null ? void 0 : c.as_bytes();
513
- if (d === void 0)
500
+ const l = (c = a.header(j.new_int(yt.new_negative(Nt.from_str("2"))))) == null ? void 0 : c.as_bytes();
501
+ if (l === void 0)
514
502
  throw new Error("Couldn't find a signer key in signature");
515
- const g = et(b(A)), I = Rs(b(d));
516
- if (Is(e, g, I) === !1)
503
+ const g = st(D(A)), I = Vs(D(l));
504
+ if (ls(e, g, I) === !1)
517
505
  throw new Error("Couldn't check signature because of address mismatch");
518
- const _ = Ls(b(i.signature())), x = i.signed_data().to_bytes();
519
- return I.verify(x, _);
506
+ const f = Os(D(n.signature())), y = n.signed_data().to_bytes();
507
+ return I.verify(y, f);
520
508
  }
521
509
  return !1;
522
- }, Is = (s, e, t) => {
510
+ }, ls = (s, e, t) => {
523
511
  if (s !== e.to_bech32())
524
512
  return !1;
525
513
  try {
526
- return At(s) === t.hash().to_hex();
514
+ return dt(s) === t.hash().to_hex();
527
515
  } catch {
528
516
  return !1;
529
517
  }
530
- }, ms = (s) => {
531
- const e = Ce.new(J.from_key_type(We.OKP));
532
- return e.set_algorithm_id(J.from_algorithm_id(we.EdDSA)), e.set_header(J.new_int(_t.new_negative(Kt.from_str("1"))), Nt.new_int(_t.new_i32(6))), e.set_header(J.new_int(_t.new_negative(Kt.from_str("2"))), Nt.new_bytes(s.key.to_public().as_bytes())), e;
533
- }, ps = (s, e) => {
518
+ }, hs = (s) => {
519
+ const e = we.new(j.from_key_type(We.OKP));
520
+ return e.set_algorithm_id(j.from_algorithm_id(Be.EdDSA)), e.set_header(j.new_int(yt.new_negative(Nt.from_str("1"))), Pt.new_int(yt.new_i32(6))), e.set_header(j.new_int(yt.new_negative(Nt.from_str("2"))), Pt.new_bytes(s.key.to_public().as_bytes())), e;
521
+ }, Is = (s, e) => {
534
522
  const t = Wt.new(), r = Wt.new();
535
- t.set_algorithm_id(J.from_algorithm_id(we.EdDSA)), t.set_header(J.new_text("address"), Nt.new_bytes(e.address.to_bytes()));
536
- const a = Je.new(je.new(t), r), i = Xe.new(a, m(s.payload), !1);
537
- s.externalAAD !== void 0 && i.set_external_aad(m(s.externalAAD));
538
- const o = i.make_data_to_sign(), c = e.key.sign(o.to_bytes());
539
- return i.build(c.to_bytes());
523
+ t.set_algorithm_id(j.from_algorithm_id(Be.EdDSA)), t.set_header(j.new_text("address"), Pt.new_bytes(e.address.to_bytes()));
524
+ const a = Je.new(je.new(t), r), n = Xe.new(a, m(s.payload), !1);
525
+ s.externalAAD !== void 0 && n.set_external_aad(m(s.externalAAD));
526
+ const o = n.make_data_to_sign(), c = e.key.sign(o.to_bytes());
527
+ return n.build(c.to_bytes());
540
528
  };
541
529
  var Xt = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : typeof global < "u" ? global : typeof self < "u" ? self : {}, Se = {}, Q = { exports: {} };
542
- G.notEqual = _s;
543
- G.notOk = ys;
544
- G.equal = fs;
545
- G.ok = G;
546
- var Qe = G;
547
- function fs(s, e, t) {
548
- G(s == e, t);
530
+ R.notEqual = ps;
531
+ R.notOk = fs;
532
+ R.equal = ms;
533
+ R.ok = R;
534
+ var Qe = R;
535
+ function ms(s, e, t) {
536
+ R(s == e, t);
549
537
  }
550
- function _s(s, e, t) {
551
- G(s != e, t);
538
+ function ps(s, e, t) {
539
+ R(s != e, t);
552
540
  }
553
- function ys(s, e) {
554
- G(!s, e);
541
+ function fs(s, e) {
542
+ R(!s, e);
555
543
  }
556
- function G(s, e) {
544
+ function R(s, e) {
557
545
  if (!s)
558
546
  throw new Error(e || "AssertionError");
559
547
  }
560
- var M = { exports: {} };
561
- function Cs(s) {
548
+ var O = { exports: {} };
549
+ function _s(s) {
562
550
  throw new Error('Could not dynamically require "' + s + '". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.');
563
551
  }
564
- var ws = Ht;
565
- Ht.supported = typeof WebAssembly < "u";
566
- function Ht(s) {
567
- if (!Ht.supported)
552
+ var ys = Ot;
553
+ Ot.supported = typeof WebAssembly < "u";
554
+ function Ot(s) {
555
+ if (!Ot.supported)
568
556
  return null;
569
- var e = s && s.imports, t = Bs("AGFzbQEAAAABEANgAn9/AGADf39/AGABfwADBQQAAQICBQUBAQroBwdNBQZtZW1vcnkCAAxibGFrZTJiX2luaXQAAA5ibGFrZTJiX3VwZGF0ZQABDWJsYWtlMmJfZmluYWwAAhBibGFrZTJiX2NvbXByZXNzAAMK00AElgMAIABCADcDACAAQQhqQgA3AwAgAEEQakIANwMAIABBGGpCADcDACAAQSBqQgA3AwAgAEEoakIANwMAIABBMGpCADcDACAAQThqQgA3AwAgAEHAAGpCADcDACAAQcgAakIANwMAIABB0ABqQgA3AwAgAEHYAGpCADcDACAAQeAAakIANwMAIABB6ABqQgA3AwAgAEHwAGpCADcDACAAQfgAakIANwMAIABBgAFqQoiS853/zPmE6gBBACkDAIU3AwAgAEGIAWpCu86qptjQ67O7f0EIKQMAhTcDACAAQZABakKr8NP0r+68tzxBECkDAIU3AwAgAEGYAWpC8e30+KWn/aelf0EYKQMAhTcDACAAQaABakLRhZrv+s+Uh9EAQSApAwCFNwMAIABBqAFqQp/Y+dnCkdqCm39BKCkDAIU3AwAgAEGwAWpC6/qG2r+19sEfQTApAwCFNwMAIABBuAFqQvnC+JuRo7Pw2wBBOCkDAIU3AwAgAEHAAWpCADcDACAAQcgBakIANwMAIABB0AFqQgA3AwALbQEDfyAAQcABaiEDIABByAFqIQQgBCkDAKchBQJAA0AgASACRg0BIAVBgAFGBEAgAyADKQMAIAWtfDcDAEEAIQUgABADCyAAIAVqIAEtAAA6AAAgBUEBaiEFIAFBAWohAQwACwsgBCAFrTcDAAtkAQN/IABBwAFqIQEgAEHIAWohAiABIAEpAwAgAikDAHw3AwAgAEHQAWpCfzcDACACKQ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DCANfCEMIAcgDIVCGIohByACIAcgE3x8IQIgDSAChUIQiiENIAwgDXwhDCAHIAyFQj+KIQcgAyAIIBx8fCEDIA4gA4VCIIohDiAJIA58IQkgCCAJhUIYiiEIIAMgCCAYfHwhAyAOIAOFQhCKIQ4gCSAOfCEJIAggCYVCP4ohCCAEIAUgFnx8IQQgDyAEhUIgiiEPIAogD3whCiAFIAqFQhiKIQUgBCAFIBR8fCEEIA8gBIVCEIohDyAKIA98IQogBSAKhUI/iiEFICEgISkDACABIAmFhTcDACAiICIpAwAgAiAKhYU3AwAgIyAjKQMAIAMgC4WFNwMAICQgJCkDACAEIAyFhTcDACAlICUpAwAgBSANhYU3AwAgJiAmKQMAIAYgDoWFNwMAICcgJykDACAHIA+FhTcDACAoICgpAwAgCCAQhYU3AwAL"), r = null, a = {
557
+ var e = s && s.imports, t = Cs("AGFzbQEAAAABEANgAn9/AGADf39/AGABfwADBQQAAQICBQUBAQroBwdNBQZtZW1vcnkCAAxibGFrZTJiX2luaXQAAA5ibGFrZTJiX3VwZGF0ZQABDWJsYWtlMmJfZmluYWwAAhBibGFrZTJiX2NvbXByZXNzAAMK00AElgMAIABCADcDACAAQQhqQgA3AwAgAEEQakIANwMAIABBGGpCADcDACAAQSBqQgA3AwAgAEEoakIANwMAIABBMGpCADcDACAAQThqQgA3AwAgAEHAAGpCADcDACAAQcgAakIANwMAIABB0ABqQgA3AwAgAEHYAGpCADcDACAAQeAAakIANwMAIABB6ABqQgA3AwAgAEHwAGpCADcDACAAQfgAakIANwMAIABBgAFqQoiS853/zPmE6gBBACkDAIU3AwAgAEGIAWpCu86qptjQ67O7f0EIKQMAhTcDACAAQZABakKr8NP0r+68tzxBECkDAIU3AwAgAEGYAWpC8e30+KWn/aelf0EYKQMAhTcDACAAQaABakLRhZrv+s+Uh9EAQSApAwCFNwMAIABBqAFqQp/Y+dnCkdqCm39BKCkDAIU3AwAgAEGwAWpC6/qG2r+19sEfQTApAwCFNwMAIABBuAFqQvnC+JuRo7Pw2wBBOCkDAIU3AwAgAEHAAWpCADcDACAAQcgBakIANwMAIABB0AFqQgA3AwALbQEDfyAAQcABaiEDIABByAFqIQQgBCkDAKchBQJAA0AgASACRg0BIAVBgAFGBEAgAyADKQMAIAWtfDcDAEEAIQUgABADCyAAIAVqIAEtAAA6AAAgBUEBaiEFIAFBAWohAQwACwsgBCAFrTcDAAtkAQN/IABBwAFqIQEgAEHIAWohAiABIAEpAwAgAikDAHw3AwAgAEHQAWpCfzcDACACKQMApyEDAkADQCADQYABRg0BIAAgA2pBADoAACADQQFqIQMMAAsLIAIgA603AwAgABADC+U7AiB+CX8gAEGAAWohISAAQYgBaiEiIABBkAFqISMgAEGYAWohJCAAQaABaiElIABBqAFqISYgAEGwAWohJyAAQbgBaiEoICEpAwAhASAiKQMAIQIgIykDACEDICQpAwAhBCAlKQMAIQUgJikDACEGICcpAwAhByAoKQMAIQhCiJLznf/M+YTqACEJQrvOqqbY0Ouzu38hCkKr8NP0r+68tzwhC0Lx7fT4paf9p6V/IQxC0YWa7/rPlIfRACENQp/Y+dnCkdqCm38hDkLr+obav7X2wR8hD0L5wvibkaOz8NsAIRAgACkDACERIABBCGopAwAhEiAAQRBqKQMAIRMgAEEYaikDACEUIABBIGopAwAhFSAAQShqKQMAIRYgAEEwaikDACEXIABBOGopAwAhGCAAQcAAaikDACEZIABByABqKQMAIRogAEHQAGopAwAhGyAAQdgAaikDACEcIABB4ABqKQMAIR0gAEHoAGopAwAhHiAAQfAAaikDACEfIABB+ABqKQMAISAgDSAAQcABaikDAIUhDSAPIABB0AFqKQMAhSEPIAEgBSARfHwhASANIAGFQiCKIQ0gCSANfCEJIAUgCYVCGIohBSABIAUgEnx8IQEgDSABhUIQiiENIAkgDXwhCSAFIAmFQj+KIQUgAiAGIBN8fCECIA4gAoVCIIohDiAKIA58IQogBiAKhUIYiiEGIAIgBiAUfHwhAiAOIAKFQhCKIQ4gCiAOfCEKIAYgCoVCP4ohBiADIAcgFXx8IQMgDyADhUIgii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IAcgIHx8IQMgDyADhUIQiiEPIAsgD3whCyAHIAuFQj+KIQcgBCAIIB58fCEEIBAgBIVCIIohECAMIBB8IQwgCCAMhUIYiiEIIAQgCCAXfHwhBCAQIASFQhCKIRAgDCAQfCEMIAggDIVCP4ohCCABIAYgEnx8IQEgECABhUIgiiEQIAsgEHwhCyAGIAuFQhiKIQYgASAGIB18fCEBIBAgAYVCEIohECALIBB8IQsgBiALhUI/iiEGIAIgByARfHwhAiANIAKFQiCKIQ0gDCANfCEMIAcgDIVCGIohByACIAcgE3x8IQIgDSAChUIQiiENIAwgDXwhDCAHIAyFQj+KIQcgAyAIIBx8fCEDIA4gA4VCIIohDiAJIA58IQkgCCAJhUIYiiEIIAMgCCAYfHwhAyAOIAOFQhCKIQ4gCSAOfCEJIAggCYVCP4ohCCAEIAUgFnx8IQQgDyAEhUIgiiEPIAogD3whCiAFIAqFQhiKIQUgBCAFIBR8fCEEIA8gBIVCEIohDyAKIA98IQogBSAKhUI/iiEFICEgISkDACABIAmFhTcDACAiICIpAwAgAiAKhYU3AwAgIyAjKQMAIAMgC4WFNwMAICQgJCkDACAEIAyFhTcDACAlICUpAwAgBSANhYU3AwAgJiAmKQMAIAYgDoWFNwMAICcgJykDACAHIA+FhTcDACAoICgpAwAgCCAQhYU3AwAL"), r = null, a = {
570
558
  buffer: t,
571
559
  memory: null,
572
560
  exports: null,
573
- realloc: i,
561
+ realloc: n,
574
562
  onload: o
575
563
  };
576
564
  return o(function() {
577
565
  }), a;
578
- function i(u) {
566
+ function n(u) {
579
567
  a.exports.memory.grow(Math.ceil(Math.abs(u - a.memory.length) / 65536)), a.memory = new Uint8Array(a.exports.memory.buffer);
580
568
  }
581
569
  function o(u) {
@@ -598,82 +586,82 @@ function Ht(s) {
598
586
  a.exports = u.instance.exports, a.memory = a.exports.memory && a.exports.memory.buffer && new Uint8Array(a.exports.memory.buffer);
599
587
  }
600
588
  }
601
- function Bs(s) {
602
- return typeof atob == "function" ? new Uint8Array(atob(s).split("").map(Es)) : new (Cs("buffer")).Buffer(s, "base64");
589
+ function Cs(s) {
590
+ return typeof atob == "function" ? new Uint8Array(atob(s).split("").map(ws)) : new (_s("buffer")).Buffer(s, "base64");
603
591
  }
604
- function Es(s) {
592
+ function ws(s) {
605
593
  return s.charCodeAt(0);
606
594
  }
607
- var K = Qe, f = ws(), V = 64, yt = [];
608
- M.exports = D;
609
- var Zt = M.exports.BYTES_MIN = 16, te = M.exports.BYTES_MAX = 64;
610
- M.exports.BYTES = 32;
611
- var ee = M.exports.KEYBYTES_MIN = 16, se = M.exports.KEYBYTES_MAX = 64;
612
- M.exports.KEYBYTES = 32;
613
- var re = M.exports.SALTBYTES = 16, ae = M.exports.PERSONALBYTES = 16;
614
- function D(s, e, t, r, a) {
615
- if (!(this instanceof D))
616
- return new D(s, e, t, r, a);
617
- if (!(f && f.exports))
595
+ var P = Qe, _ = ys(), Y = 64, Ct = [];
596
+ O.exports = v;
597
+ var Zt = O.exports.BYTES_MIN = 16, te = O.exports.BYTES_MAX = 64;
598
+ O.exports.BYTES = 32;
599
+ var ee = O.exports.KEYBYTES_MIN = 16, se = O.exports.KEYBYTES_MAX = 64;
600
+ O.exports.KEYBYTES = 32;
601
+ var re = O.exports.SALTBYTES = 16, ae = O.exports.PERSONALBYTES = 16;
602
+ function v(s, e, t, r, a) {
603
+ if (!(this instanceof v))
604
+ return new v(s, e, t, r, a);
605
+ if (!(_ && _.exports))
618
606
  throw new Error("WASM not loaded. Wait for Blake2b.ready(cb)");
619
- s || (s = 32), a !== !0 && (K(s >= Zt, "digestLength must be at least " + Zt + ", was given " + s), K(s <= te, "digestLength must be at most " + te + ", was given " + s), e != null && K(e.length >= ee, "key must be at least " + ee + ", was given " + e.length), e != null && K(e.length <= se, "key must be at least " + se + ", was given " + e.length), t != null && K(t.length === re, "salt must be exactly " + re + ", was given " + t.length), r != null && K(r.length === ae, "personal must be exactly " + ae + ", was given " + r.length)), yt.length || (yt.push(V), V += 216), this.digestLength = s, this.finalized = !1, this.pointer = yt.pop(), f.memory.fill(0, 0, 64), f.memory[0] = this.digestLength, f.memory[1] = e ? e.length : 0, f.memory[2] = 1, f.memory[3] = 1, t && f.memory.set(t, 32), r && f.memory.set(r, 48), this.pointer + 216 > f.memory.length && f.realloc(this.pointer + 216), f.exports.blake2b_init(this.pointer, this.digestLength), e && (this.update(e), f.memory.fill(0, V, V + e.length), f.memory[this.pointer + 200] = 128);
607
+ s || (s = 32), a !== !0 && (P(s >= Zt, "digestLength must be at least " + Zt + ", was given " + s), P(s <= te, "digestLength must be at most " + te + ", was given " + s), e != null && P(e.length >= ee, "key must be at least " + ee + ", was given " + e.length), e != null && P(e.length <= se, "key must be at least " + se + ", was given " + e.length), t != null && P(t.length === re, "salt must be exactly " + re + ", was given " + t.length), r != null && P(r.length === ae, "personal must be exactly " + ae + ", was given " + r.length)), Ct.length || (Ct.push(Y), Y += 216), this.digestLength = s, this.finalized = !1, this.pointer = Ct.pop(), _.memory.fill(0, 0, 64), _.memory[0] = this.digestLength, _.memory[1] = e ? e.length : 0, _.memory[2] = 1, _.memory[3] = 1, t && _.memory.set(t, 32), r && _.memory.set(r, 48), this.pointer + 216 > _.memory.length && _.realloc(this.pointer + 216), _.exports.blake2b_init(this.pointer, this.digestLength), e && (this.update(e), _.memory.fill(0, Y, Y + e.length), _.memory[this.pointer + 200] = 128);
620
608
  }
621
- D.prototype.update = function(s) {
622
- return K(this.finalized === !1, "Hash instance finalized"), K(s, "input must be TypedArray or Buffer"), V + s.length > f.memory.length && f.realloc(V + s.length), f.memory.set(s, V), f.exports.blake2b_update(this.pointer, V, V + s.length), this;
609
+ v.prototype.update = function(s) {
610
+ return P(this.finalized === !1, "Hash instance finalized"), P(s, "input must be TypedArray or Buffer"), Y + s.length > _.memory.length && _.realloc(Y + s.length), _.memory.set(s, Y), _.exports.blake2b_update(this.pointer, Y, Y + s.length), this;
623
611
  };
624
- D.prototype.digest = function(s) {
625
- if (K(this.finalized === !1, "Hash instance finalized"), this.finalized = !0, yt.push(this.pointer), f.exports.blake2b_final(this.pointer), !s || s === "binary")
626
- return f.memory.slice(this.pointer + 128, this.pointer + 128 + this.digestLength);
612
+ v.prototype.digest = function(s) {
613
+ if (P(this.finalized === !1, "Hash instance finalized"), this.finalized = !0, Ct.push(this.pointer), _.exports.blake2b_final(this.pointer), !s || s === "binary")
614
+ return _.memory.slice(this.pointer + 128, this.pointer + 128 + this.digestLength);
627
615
  if (s === "hex")
628
- return Ss(f.memory, this.pointer + 128, this.digestLength);
629
- K(s.length >= this.digestLength, "input must be TypedArray or Buffer");
616
+ return xs(_.memory, this.pointer + 128, this.digestLength);
617
+ P(s.length >= this.digestLength, "input must be TypedArray or Buffer");
630
618
  for (var e = 0; e < this.digestLength; e++)
631
- s[e] = f.memory[this.pointer + 128 + e];
619
+ s[e] = _.memory[this.pointer + 128 + e];
632
620
  return s;
633
621
  };
634
- D.prototype.final = D.prototype.digest;
635
- D.WASM = f && f.buffer;
636
- D.SUPPORTED = typeof WebAssembly < "u";
637
- D.ready = function(s) {
638
- if (s || (s = xs), !f)
622
+ v.prototype.final = v.prototype.digest;
623
+ v.WASM = _ && _.buffer;
624
+ v.SUPPORTED = typeof WebAssembly < "u";
625
+ v.ready = function(s) {
626
+ if (s || (s = Bs), !_)
639
627
  return s(new Error("WebAssembly not supported"));
640
628
  var e = new Promise(function(t, r) {
641
- f.onload(function(a) {
629
+ _.onload(function(a) {
642
630
  a ? r() : t(), s(a);
643
631
  });
644
632
  });
645
633
  return e;
646
634
  };
647
- D.prototype.ready = D.ready;
648
- function xs() {
635
+ v.prototype.ready = v.ready;
636
+ function Bs() {
649
637
  }
650
- function Ss(s, e, t) {
638
+ function xs(s, e, t) {
651
639
  for (var r = "", a = 0; a < t; a++)
652
- r += Qs(s[e + a]);
640
+ r += Es(s[e + a]);
653
641
  return r;
654
642
  }
655
- function Qs(s) {
643
+ function Es(s) {
656
644
  return s < 16 ? "0" + s.toString(16) : s.toString(16);
657
645
  }
658
- var bs = M.exports, W = Qe, dt = bs;
659
- function It(s, e, t) {
646
+ var J = Qe, ht = O.exports;
647
+ function mt(s, e, t) {
660
648
  var r = s[e] + s[t], a = s[e + 1] + s[t + 1];
661
649
  r >= 4294967296 && a++, s[e] = r, s[e + 1] = a;
662
650
  }
663
651
  function ne(s, e, t, r) {
664
652
  var a = s[e] + t;
665
653
  t < 0 && (a += 4294967296);
666
- var i = s[e + 1] + r;
667
- a >= 4294967296 && i++, s[e] = a, s[e + 1] = i;
654
+ var n = s[e + 1] + r;
655
+ a >= 4294967296 && n++, s[e] = a, s[e + 1] = n;
668
656
  }
669
657
  function be(s, e) {
670
658
  return s[e] ^ s[e + 1] << 8 ^ s[e + 2] << 16 ^ s[e + 3] << 24;
671
659
  }
672
- function $(s, e, t, r, a, i) {
673
- var o = ut[a], c = ut[a + 1], u = ut[i], A = ut[i + 1];
674
- It(h, s, e), ne(h, s, o, c);
675
- var d = h[r] ^ h[s], g = h[r + 1] ^ h[s + 1];
676
- h[r] = g, h[r + 1] = d, It(h, t, r), d = h[e] ^ h[t], g = h[e + 1] ^ h[t + 1], h[e] = d >>> 24 ^ g << 8, h[e + 1] = g >>> 24 ^ d << 8, It(h, s, e), ne(h, s, u, A), d = h[r] ^ h[s], g = h[r + 1] ^ h[s + 1], h[r] = d >>> 16 ^ g << 16, h[r + 1] = g >>> 16 ^ d << 16, It(h, t, r), d = h[e] ^ h[t], g = h[e + 1] ^ h[t + 1], h[e] = g >>> 31 ^ d << 1, h[e + 1] = d >>> 31 ^ g << 1;
660
+ function z(s, e, t, r, a, n) {
661
+ var o = At[a], c = At[a + 1], u = At[n], A = At[n + 1];
662
+ mt(h, s, e), ne(h, s, o, c);
663
+ var l = h[r] ^ h[s], g = h[r + 1] ^ h[s + 1];
664
+ h[r] = g, h[r + 1] = l, mt(h, t, r), l = h[e] ^ h[t], g = h[e + 1] ^ h[t + 1], h[e] = l >>> 24 ^ g << 8, h[e + 1] = g >>> 24 ^ l << 8, mt(h, s, e), ne(h, s, u, A), l = h[r] ^ h[s], g = h[r + 1] ^ h[s + 1], h[r] = l >>> 16 ^ g << 16, h[r + 1] = g >>> 16 ^ l << 16, mt(h, t, r), l = h[e] ^ h[t], g = h[e + 1] ^ h[t + 1], h[e] = g >>> 31 ^ l << 1, h[e + 1] = l >>> 31 ^ g << 1;
677
665
  }
678
666
  var De = new Uint32Array([
679
667
  4089235720,
@@ -692,7 +680,7 @@ var De = new Uint32Array([
692
680
  528734635,
693
681
  327033209,
694
682
  1541459225
695
- ]), Ds = [
683
+ ]), Ss = [
696
684
  0,
697
685
  1,
698
686
  2,
@@ -885,118 +873,102 @@ var De = new Uint32Array([
885
873
  7,
886
874
  5,
887
875
  3
888
- ], B = new Uint8Array(Ds.map(function(s) {
876
+ ], x = new Uint8Array(Ss.map(function(s) {
889
877
  return s * 2;
890
- })), h = new Uint32Array(32), ut = new Uint32Array(32);
878
+ })), h = new Uint32Array(32), At = new Uint32Array(32);
891
879
  function ve(s, e) {
892
880
  var t = 0;
893
881
  for (t = 0; t < 16; t++)
894
882
  h[t] = s.h[t], h[t + 16] = De[t];
895
883
  for (h[24] = h[24] ^ s.t, h[25] = h[25] ^ s.t / 4294967296, e && (h[28] = ~h[28], h[29] = ~h[29]), t = 0; t < 32; t++)
896
- ut[t] = be(s.b, 4 * t);
884
+ At[t] = be(s.b, 4 * t);
897
885
  for (t = 0; t < 12; t++)
898
- $(0, 8, 16, 24, B[t * 16 + 0], B[t * 16 + 1]), $(2, 10, 18, 26, B[t * 16 + 2], B[t * 16 + 3]), $(4, 12, 20, 28, B[t * 16 + 4], B[t * 16 + 5]), $(6, 14, 22, 30, B[t * 16 + 6], B[t * 16 + 7]), $(0, 10, 20, 30, B[t * 16 + 8], B[t * 16 + 9]), $(2, 12, 22, 24, B[t * 16 + 10], B[t * 16 + 11]), $(4, 14, 16, 26, B[t * 16 + 12], B[t * 16 + 13]), $(6, 8, 18, 28, B[t * 16 + 14], B[t * 16 + 15]);
886
+ z(0, 8, 16, 24, x[t * 16 + 0], x[t * 16 + 1]), z(2, 10, 18, 26, x[t * 16 + 2], x[t * 16 + 3]), z(4, 12, 20, 28, x[t * 16 + 4], x[t * 16 + 5]), z(6, 14, 22, 30, x[t * 16 + 6], x[t * 16 + 7]), z(0, 10, 20, 30, x[t * 16 + 8], x[t * 16 + 9]), z(2, 12, 22, 24, x[t * 16 + 10], x[t * 16 + 11]), z(4, 14, 16, 26, x[t * 16 + 12], x[t * 16 + 13]), z(6, 8, 18, 28, x[t * 16 + 14], x[t * 16 + 15]);
899
887
  for (t = 0; t < 16; t++)
900
888
  s.h[t] = s.h[t] ^ h[t] ^ h[t + 16];
901
889
  }
902
- var z = new Uint8Array([
890
+ var W = new Uint8Array([
903
891
  0,
904
892
  0,
905
893
  0,
906
894
  0,
907
- // 0: outlen, keylen, fanout, depth
908
895
  0,
909
896
  0,
910
897
  0,
911
898
  0,
912
- // 4: leaf length, sequential mode
913
899
  0,
914
900
  0,
915
901
  0,
916
902
  0,
917
- // 8: node offset
918
903
  0,
919
904
  0,
920
905
  0,
921
906
  0,
922
- // 12: node offset
923
907
  0,
924
908
  0,
925
909
  0,
926
910
  0,
927
- // 16: node depth, inner length, rfu
928
911
  0,
929
912
  0,
930
913
  0,
931
914
  0,
932
- // 20: rfu
933
915
  0,
934
916
  0,
935
917
  0,
936
918
  0,
937
- // 24: rfu
938
919
  0,
939
920
  0,
940
921
  0,
941
922
  0,
942
- // 28: rfu
943
923
  0,
944
924
  0,
945
925
  0,
946
926
  0,
947
- // 32: salt
948
927
  0,
949
928
  0,
950
929
  0,
951
930
  0,
952
- // 36: salt
953
931
  0,
954
932
  0,
955
933
  0,
956
934
  0,
957
- // 40: salt
958
935
  0,
959
936
  0,
960
937
  0,
961
938
  0,
962
- // 44: salt
963
939
  0,
964
940
  0,
965
941
  0,
966
942
  0,
967
- // 48: personal
968
943
  0,
969
944
  0,
970
945
  0,
971
946
  0,
972
- // 52: personal
973
947
  0,
974
948
  0,
975
949
  0,
976
950
  0,
977
- // 56: personal
978
951
  0,
979
952
  0,
980
953
  0,
981
954
  0
982
- // 60: personal
983
955
  ]);
984
- function at(s, e, t, r) {
985
- z.fill(0), this.b = new Uint8Array(128), this.h = new Uint32Array(16), this.t = 0, this.c = 0, this.outlen = s, z[0] = s, e && (z[1] = e.length), z[2] = 1, z[3] = 1, t && z.set(t, 32), r && z.set(r, 48);
956
+ function nt(s, e, t, r) {
957
+ W.fill(0), this.b = new Uint8Array(128), this.h = new Uint32Array(16), this.t = 0, this.c = 0, this.outlen = s, W[0] = s, e && (W[1] = e.length), W[2] = 1, W[3] = 1, t && W.set(t, 32), r && W.set(r, 48);
986
958
  for (var a = 0; a < 16; a++)
987
- this.h[a] = De[a] ^ be(z, a * 4);
959
+ this.h[a] = De[a] ^ be(W, a * 4);
988
960
  e && (ke(this, e), this.c = 128);
989
961
  }
990
- at.prototype.update = function(s) {
991
- return W(s != null, "input must be Uint8Array or Buffer"), ke(this, s), this;
962
+ nt.prototype.update = function(s) {
963
+ return J(s != null, "input must be Uint8Array or Buffer"), ke(this, s), this;
992
964
  };
993
- at.prototype.digest = function(s) {
965
+ nt.prototype.digest = function(s) {
994
966
  var e = !s || s === "binary" || s === "hex" ? new Uint8Array(this.outlen) : s;
995
- return W(e.length >= this.outlen, "out must have at least outlen bytes of space"), vs(this, e), s === "hex" ? ks(e) : e;
967
+ return J(e.length >= this.outlen, "out must have at least outlen bytes of space"), Qs(this, e), s === "hex" ? bs(e) : e;
996
968
  };
997
- at.prototype.final = at.prototype.digest;
998
- at.ready = function(s) {
999
- dt.ready(function() {
969
+ nt.prototype.final = nt.prototype.digest;
970
+ nt.ready = function(s) {
971
+ ht.ready(function() {
1000
972
  s();
1001
973
  });
1002
974
  };
@@ -1004,7 +976,7 @@ function ke(s, e) {
1004
976
  for (var t = 0; t < e.length; t++)
1005
977
  s.c === 128 && (s.t += s.c, ve(s, !1), s.c = 0), s.b[s.c++] = e[t];
1006
978
  }
1007
- function vs(s, e) {
979
+ function Qs(s, e) {
1008
980
  for (s.t += s.c; s.c < 128; )
1009
981
  s.b[s.c++] = 0;
1010
982
  ve(s, !0);
@@ -1012,86 +984,86 @@ function vs(s, e) {
1012
984
  e[t] = s.h[t >> 2] >> 8 * (t & 3);
1013
985
  return e;
1014
986
  }
1015
- function ks(s) {
987
+ function bs(s) {
1016
988
  for (var e = "", t = 0; t < s.length; t++)
1017
- e += Us(s[t]);
989
+ e += Ds(s[t]);
1018
990
  return e;
1019
991
  }
1020
- function Us(s) {
992
+ function Ds(s) {
1021
993
  return s < 16 ? "0" + s.toString(16) : s.toString(16);
1022
994
  }
1023
- var Ue = at;
1024
- Q.exports = function(e, t, r, a, i) {
1025
- return i !== !0 && (W(e >= ie, "outlen must be at least " + ie + ", was given " + e), W(e <= oe, "outlen must be at most " + oe + ", was given " + e), t != null && W(t.length >= ce, "key must be at least " + ce + ", was given " + t.length), t != null && W(t.length <= ue, "key must be at most " + ue + ", was given " + t.length), r != null && W(r.length === Ae, "salt must be exactly " + Ae + ", was given " + r.length), a != null && W(a.length === ge, "personal must be exactly " + ge + ", was given " + a.length)), new Ue(e, t, r, a);
995
+ var Ue = nt;
996
+ Q.exports = function(e, t, r, a, n) {
997
+ return n !== !0 && (J(e >= ie, "outlen must be at least " + ie + ", was given " + e), J(e <= oe, "outlen must be at most " + oe + ", was given " + e), t != null && J(t.length >= ce, "key must be at least " + ce + ", was given " + t.length), t != null && J(t.length <= ue, "key must be at most " + ue + ", was given " + t.length), r != null && J(r.length === Ae, "salt must be exactly " + Ae + ", was given " + r.length), a != null && J(a.length === de, "personal must be exactly " + de + ", was given " + a.length)), new Ue(e, t, r, a);
1026
998
  };
1027
999
  Q.exports.ready = function(s) {
1028
- dt.ready(function() {
1000
+ ht.ready(function() {
1029
1001
  s();
1030
1002
  });
1031
1003
  };
1032
- Q.exports.WASM_SUPPORTED = dt.SUPPORTED;
1004
+ Q.exports.WASM_SUPPORTED = ht.SUPPORTED;
1033
1005
  Q.exports.WASM_LOADED = !1;
1034
1006
  var ie = Q.exports.BYTES_MIN = 16, oe = Q.exports.BYTES_MAX = 64;
1035
1007
  Q.exports.BYTES = 32;
1036
1008
  var ce = Q.exports.KEYBYTES_MIN = 16, ue = Q.exports.KEYBYTES_MAX = 64;
1037
1009
  Q.exports.KEYBYTES = 32;
1038
- var Ae = Q.exports.SALTBYTES = 16, ge = Q.exports.PERSONALBYTES = 16;
1039
- dt.ready(function(s) {
1040
- s || (Q.exports.WASM_LOADED = !0, Ue = dt);
1010
+ var Ae = Q.exports.SALTBYTES = 16, de = Q.exports.PERSONALBYTES = 16;
1011
+ ht.ready(function(s) {
1012
+ s || (Q.exports.WASM_LOADED = !0, Ue = ht);
1041
1013
  });
1042
- var Ks = Q.exports, nt = {};
1043
- Object.defineProperty(nt, "__esModule", { value: !0 });
1044
- nt.bech32m = nt.bech32 = void 0;
1014
+ var it = {};
1015
+ Object.defineProperty(it, "__esModule", { value: !0 });
1016
+ it.bech32m = it.bech32 = void 0;
1045
1017
  const St = "qpzry9x8gf2tvdw0s3jn54khce6mua7l", Ke = {};
1046
1018
  for (let s = 0; s < St.length; s++) {
1047
1019
  const e = St.charAt(s);
1048
1020
  Ke[e] = s;
1049
1021
  }
1050
- function rt(s) {
1022
+ function at(s) {
1051
1023
  const e = s >> 25;
1052
1024
  return (s & 33554431) << 5 ^ -(e >> 0 & 1) & 996825010 ^ -(e >> 1 & 1) & 642813549 ^ -(e >> 2 & 1) & 513874426 ^ -(e >> 3 & 1) & 1027748829 ^ -(e >> 4 & 1) & 705979059;
1053
1025
  }
1054
- function de(s) {
1026
+ function ge(s) {
1055
1027
  let e = 1;
1056
1028
  for (let t = 0; t < s.length; ++t) {
1057
1029
  const r = s.charCodeAt(t);
1058
1030
  if (r < 33 || r > 126)
1059
1031
  return "Invalid prefix (" + s + ")";
1060
- e = rt(e) ^ r >> 5;
1032
+ e = at(e) ^ r >> 5;
1061
1033
  }
1062
- e = rt(e);
1034
+ e = at(e);
1063
1035
  for (let t = 0; t < s.length; ++t) {
1064
1036
  const r = s.charCodeAt(t);
1065
- e = rt(e) ^ r & 31;
1037
+ e = at(e) ^ r & 31;
1066
1038
  }
1067
1039
  return e;
1068
1040
  }
1069
- function Ot(s, e, t, r) {
1070
- let a = 0, i = 0;
1041
+ function Vt(s, e, t, r) {
1042
+ let a = 0, n = 0;
1071
1043
  const o = (1 << t) - 1, c = [];
1072
1044
  for (let u = 0; u < s.length; ++u)
1073
- for (a = a << e | s[u], i += e; i >= t; )
1074
- i -= t, c.push(a >> i & o);
1045
+ for (a = a << e | s[u], n += e; n >= t; )
1046
+ n -= t, c.push(a >> n & o);
1075
1047
  if (r)
1076
- i > 0 && c.push(a << t - i & o);
1048
+ n > 0 && c.push(a << t - n & o);
1077
1049
  else {
1078
- if (i >= e)
1050
+ if (n >= e)
1079
1051
  return "Excess padding";
1080
- if (a << t - i & o)
1052
+ if (a << t - n & o)
1081
1053
  return "Non-zero padding";
1082
1054
  }
1083
1055
  return c;
1084
1056
  }
1085
- function Ns(s) {
1086
- return Ot(s, 8, 5, !0);
1057
+ function vs(s) {
1058
+ return Vt(s, 8, 5, !0);
1087
1059
  }
1088
- function Ps(s) {
1089
- const e = Ot(s, 5, 8, !1);
1060
+ function ks(s) {
1061
+ const e = Vt(s, 5, 8, !1);
1090
1062
  if (Array.isArray(e))
1091
1063
  return e;
1092
1064
  }
1093
- function Fs(s) {
1094
- const e = Ot(s, 5, 8, !1);
1065
+ function Us(s) {
1066
+ const e = Vt(s, 5, 8, !1);
1095
1067
  if (Array.isArray(e))
1096
1068
  return e;
1097
1069
  throw new Error(e);
@@ -1103,24 +1075,24 @@ function Ne(s) {
1103
1075
  if (u = u || 90, o.length + 7 + c.length > u)
1104
1076
  throw new TypeError("Exceeds length limit");
1105
1077
  o = o.toLowerCase();
1106
- let A = de(o);
1078
+ let A = ge(o);
1107
1079
  if (typeof A == "string")
1108
1080
  throw new Error(A);
1109
- let d = o + "1";
1081
+ let l = o + "1";
1110
1082
  for (let g = 0; g < c.length; ++g) {
1111
1083
  const I = c[g];
1112
- if (I >> 5)
1084
+ if (I >> 5 !== 0)
1113
1085
  throw new Error("Non 5-bit word");
1114
- A = rt(A) ^ I, d += St.charAt(I);
1086
+ A = at(A) ^ I, l += St.charAt(I);
1115
1087
  }
1116
1088
  for (let g = 0; g < 6; ++g)
1117
- A = rt(A);
1089
+ A = at(A);
1118
1090
  A ^= e;
1119
1091
  for (let g = 0; g < 6; ++g) {
1120
1092
  const I = A >> (5 - g) * 5 & 31;
1121
- d += St.charAt(I);
1093
+ l += St.charAt(I);
1122
1094
  }
1123
- return d;
1095
+ return l;
1124
1096
  }
1125
1097
  function r(o, c) {
1126
1098
  if (c = c || 90, o.length < 8)
@@ -1131,32 +1103,32 @@ function Ne(s) {
1131
1103
  if (o !== u && o !== A)
1132
1104
  return "Mixed-case string " + o;
1133
1105
  o = u;
1134
- const d = o.lastIndexOf("1");
1135
- if (d === -1)
1106
+ const l = o.lastIndexOf("1");
1107
+ if (l === -1)
1136
1108
  return "No separator character for " + o;
1137
- if (d === 0)
1109
+ if (l === 0)
1138
1110
  return "Missing prefix for " + o;
1139
- const g = o.slice(0, d), I = o.slice(d + 1);
1111
+ const g = o.slice(0, l), I = o.slice(l + 1);
1140
1112
  if (I.length < 6)
1141
1113
  return "Data too short";
1142
- let _ = de(g);
1143
- if (typeof _ == "string")
1144
- return _;
1145
- const x = [];
1146
- for (let H = 0; H < I.length; ++H) {
1147
- const R = I.charAt(H), p = Ke[R];
1114
+ let f = ge(g);
1115
+ if (typeof f == "string")
1116
+ return f;
1117
+ const y = [];
1118
+ for (let b = 0; b < I.length; ++b) {
1119
+ const k = I.charAt(b), p = Ke[k];
1148
1120
  if (p === void 0)
1149
- return "Unknown character " + R;
1150
- _ = rt(_) ^ p, !(H + 6 >= I.length) && x.push(p);
1121
+ return "Unknown character " + k;
1122
+ f = at(f) ^ p, !(b + 6 >= I.length) && y.push(p);
1151
1123
  }
1152
- return _ !== e ? "Invalid checksum for " + o : { prefix: g, words: x };
1124
+ return f !== e ? "Invalid checksum for " + o : { prefix: g, words: y };
1153
1125
  }
1154
1126
  function a(o, c) {
1155
1127
  const u = r(o, c);
1156
1128
  if (typeof u == "object")
1157
1129
  return u;
1158
1130
  }
1159
- function i(o, c) {
1131
+ function n(o, c) {
1160
1132
  const u = r(o, c);
1161
1133
  if (typeof u == "object")
1162
1134
  return u;
@@ -1164,58 +1136,57 @@ function Ne(s) {
1164
1136
  }
1165
1137
  return {
1166
1138
  decodeUnsafe: a,
1167
- decode: i,
1139
+ decode: n,
1168
1140
  encode: t,
1169
- toWords: Ns,
1170
- fromWordsUnsafe: Ps,
1171
- fromWords: Fs
1141
+ toWords: vs,
1142
+ fromWordsUnsafe: ks,
1143
+ fromWords: Us
1172
1144
  };
1173
1145
  }
1174
- nt.bech32 = Ne("bech32");
1175
- nt.bech32m = Ne("bech32m");
1176
- var Ts = Xt && Xt.__importDefault || function(s) {
1146
+ it.bech32 = Ne("bech32");
1147
+ it.bech32m = Ne("bech32m");
1148
+ var Ks = Xt && Xt.__importDefault || function(s) {
1177
1149
  return s && s.__esModule ? s : { default: s };
1178
1150
  };
1179
1151
  Object.defineProperty(Se, "__esModule", { value: !0 });
1180
- const Ms = Ts(Ks), mt = nt, Ut = "asset";
1181
- let Hs = class Ct {
1152
+ const Ns = Ks(Q.exports), pt = it, Kt = "asset";
1153
+ class gt {
1182
1154
  constructor(e) {
1183
1155
  this.hashBuf = e;
1184
1156
  }
1185
1157
  static fromHash(e) {
1186
- return new Ct(e);
1158
+ return new gt(e);
1187
1159
  }
1188
1160
  static fromParts(e, t) {
1189
- const r = (0, Ms.default)(20).update(new Uint8Array([...e, ...t])).digest("binary");
1190
- return Ct.fromHash(r);
1161
+ const r = (0, Ns.default)(20).update(new Uint8Array([...e, ...t])).digest("binary");
1162
+ return gt.fromHash(r);
1191
1163
  }
1192
1164
  static fromBech32(e) {
1193
- const { prefix: t, words: r } = mt.bech32.decode(e);
1194
- if (t !== Ut)
1165
+ const { prefix: t, words: r } = pt.bech32.decode(e);
1166
+ if (t !== Kt)
1195
1167
  throw new Error("Invalid asset fingerprint");
1196
- const a = Buffer.from(mt.bech32.fromWords(r));
1197
- return Ct.fromHash(a);
1168
+ const a = Buffer.from(pt.bech32.fromWords(r));
1169
+ return gt.fromHash(a);
1198
1170
  }
1199
1171
  fingerprint() {
1200
- const e = mt.bech32.toWords(this.hashBuf);
1201
- return mt.bech32.encode(Ut, e);
1172
+ const e = pt.bech32.toWords(this.hashBuf);
1173
+ return pt.bech32.encode(Kt, e);
1202
1174
  }
1203
1175
  hash() {
1204
1176
  return Buffer.from(this.hashBuf).toString("hex");
1205
1177
  }
1206
1178
  prefix() {
1207
- return Ut;
1179
+ return Kt;
1208
1180
  }
1209
- // The last six characters of the data part form a checksum and contain no information
1210
1181
  checksum() {
1211
1182
  return this.fingerprint().slice(-6);
1212
1183
  }
1213
- };
1214
- var Os = Se.default = Hs;
1215
- const Vs = Os, Ys = (s, e) => {
1216
- const t = qs(s), r = t.derive(kt + 1852).derive(kt + 1815).derive(kt + e), a = r.derive(0).derive(0).to_raw_key(), i = r.derive(2).derive(0).to_raw_key();
1217
- return r.free(), t.free(), { paymentKey: a, stakeKey: i };
1218
- }, et = (s) => n.Address.from_bytes(m(s)), qs = (s) => n.Bip32PrivateKey.from_bytes(m(s)), Gs = (s) => n.DataHash.from_bytes(m(s)), P = (s) => n.Ed25519KeyHash.from_bytes(m(s)), Ls = (s) => n.Ed25519Signature.from_bytes(m(s)), bt = (s) => n.NativeScript.from_bytes(m(s)), Rs = (s) => n.PublicKey.from_bytes(m(s)), Pe = (s) => n.PlutusData.from_bytes(m(s)), it = (s, e) => n.PlutusScript.from_bytes_with_version(m(s), Et[e]), $s = (s) => n.ScriptRef.from_bytes(m(s)), zs = (s) => n.ScriptHash.from_bytes(m(s)), Y = (s) => n.Transaction.from_bytes(m(s)), Fe = (s) => n.TransactionHash.from_bytes(m(s)), le = (s) => n.TransactionUnspentOutput.from_bytes(m(s)), Ws = (s) => n.TransactionWitnessSet.from_bytes(m(s)), Js = (s) => n.Value.from_bytes(m(s)), T = (s) => n.Address.from_bech32(s), Vt = (s) => n.BaseAddress.from_address(T(s)), Te = (s) => n.EnterpriseAddress.from_address(T(s)), Me = (s) => n.RewardAddress.from_address(T(s)), b = (s) => Buffer.from(s).toString("hex"), m = (s) => s.length % 2 === 0 && /^[0-9A-F]*$/i.test(s) ? Buffer.from(s, "hex") : Buffer.from(s, "utf-8"), Dt = (s) => {
1184
+ }
1185
+ var Ps = Se.default = gt;
1186
+ const Fs = Ps, Ts = (s, e) => {
1187
+ const t = Ms(s), r = t.derive(Ut + 1852).derive(Ut + 1815).derive(Ut + e), a = r.derive(0).derive(0).to_raw_key(), n = r.derive(2).derive(0).to_raw_key();
1188
+ return r.free(), t.free(), { paymentKey: a, stakeKey: n };
1189
+ }, st = (s) => i.Address.from_bytes(m(s)), Ms = (s) => i.Bip32PrivateKey.from_bytes(m(s)), Hs = (s) => i.DataHash.from_bytes(m(s)), T = (s) => i.Ed25519KeyHash.from_bytes(m(s)), Os = (s) => i.Ed25519Signature.from_bytes(m(s)), bt = (s) => i.NativeScript.from_bytes(m(s)), Vs = (s) => i.PublicKey.from_bytes(m(s)), Pe = (s) => i.PlutusData.from_bytes(m(s)), ot = (s, e) => i.PlutusScript.from_bytes_with_version(m(s), xt[e]), Ys = (s) => i.ScriptRef.from_bytes(m(s)), qs = (s) => i.ScriptHash.from_bytes(m(s)), q = (s) => i.Transaction.from_bytes(m(s)), Fe = (s) => i.TransactionHash.from_bytes(m(s)), le = (s) => i.TransactionUnspentOutput.from_bytes(m(s)), Ls = (s) => i.TransactionWitnessSet.from_bytes(m(s)), Gs = (s) => i.Value.from_bytes(m(s)), H = (s) => i.Address.from_bech32(s), Yt = (s) => i.BaseAddress.from_address(H(s)), Te = (s) => i.EnterpriseAddress.from_address(H(s)), Me = (s) => i.RewardAddress.from_address(H(s)), D = (s) => Buffer.from(s).toString("hex"), m = (s) => s.length % 2 === 0 && /^[0-9A-F]*$/i.test(s) ? Buffer.from(s, "hex") : Buffer.from(s, "utf-8"), Dt = (s) => {
1219
1190
  const e = (t) => {
1220
1191
  const r = new Array();
1221
1192
  for (let a = 0; a < t.len(); a += 1)
@@ -1223,21 +1194,21 @@ const Vs = Os, Ys = (s, e) => {
1223
1194
  return r;
1224
1195
  };
1225
1196
  switch (s.kind()) {
1226
- case n.NativeScriptKind.ScriptAll: {
1197
+ case i.NativeScriptKind.ScriptAll: {
1227
1198
  const t = s.as_script_all();
1228
1199
  return {
1229
1200
  type: "all",
1230
1201
  scripts: e(t.native_scripts())
1231
1202
  };
1232
1203
  }
1233
- case n.NativeScriptKind.ScriptAny: {
1204
+ case i.NativeScriptKind.ScriptAny: {
1234
1205
  const t = s.as_script_any();
1235
1206
  return {
1236
1207
  type: "any",
1237
1208
  scripts: e(t.native_scripts())
1238
1209
  };
1239
1210
  }
1240
- case n.NativeScriptKind.ScriptNOfK: {
1211
+ case i.NativeScriptKind.ScriptNOfK: {
1241
1212
  const t = s.as_script_n_of_k();
1242
1213
  return {
1243
1214
  type: "atLeast",
@@ -1245,47 +1216,53 @@ const Vs = Os, Ys = (s, e) => {
1245
1216
  scripts: e(t.native_scripts())
1246
1217
  };
1247
1218
  }
1248
- case n.NativeScriptKind.TimelockStart:
1219
+ case i.NativeScriptKind.TimelockStart: {
1220
+ const t = s.as_timelock_start();
1249
1221
  return {
1250
1222
  type: "after",
1251
- slot: s.as_timelock_start().slot_bignum().to_str()
1223
+ slot: t.slot_bignum().to_str()
1252
1224
  };
1253
- case n.NativeScriptKind.TimelockExpiry:
1225
+ }
1226
+ case i.NativeScriptKind.TimelockExpiry: {
1227
+ const t = s.as_timelock_expiry();
1254
1228
  return {
1255
1229
  type: "before",
1256
- slot: s.as_timelock_expiry().slot_bignum().to_str()
1230
+ slot: t.slot_bignum().to_str()
1257
1231
  };
1258
- case n.NativeScriptKind.ScriptPubkey:
1232
+ }
1233
+ case i.NativeScriptKind.ScriptPubkey: {
1234
+ const t = s.as_script_pubkey();
1259
1235
  return {
1260
1236
  type: "sig",
1261
- keyHash: s.as_script_pubkey().addr_keyhash().to_hex()
1237
+ keyHash: t.addr_keyhash().to_hex()
1262
1238
  };
1239
+ }
1263
1240
  default:
1264
1241
  throw new Error(`Script Kind: ${s.kind()}, is not supported`);
1265
1242
  }
1266
1243
  }, vt = (s) => {
1267
1244
  const e = (t) => {
1268
- const r = n.NativeScripts.new();
1245
+ const r = i.NativeScripts.new();
1269
1246
  return t.forEach((a) => {
1270
1247
  r.add(vt(a));
1271
1248
  }), r;
1272
1249
  };
1273
1250
  switch (s.type) {
1274
1251
  case "all":
1275
- return n.NativeScript.new_script_all(n.ScriptAll.new(e(s.scripts)));
1252
+ return i.NativeScript.new_script_all(i.ScriptAll.new(e(s.scripts)));
1276
1253
  case "any":
1277
- return n.NativeScript.new_script_any(n.ScriptAny.new(e(s.scripts)));
1254
+ return i.NativeScript.new_script_any(i.ScriptAny.new(e(s.scripts)));
1278
1255
  case "atLeast":
1279
- return n.NativeScript.new_script_n_of_k(n.ScriptNOfK.new(s.required, e(s.scripts)));
1256
+ return i.NativeScript.new_script_n_of_k(i.ScriptNOfK.new(s.required, e(s.scripts)));
1280
1257
  case "after":
1281
- return n.NativeScript.new_timelock_start(n.TimelockStart.new_timelockstart(n.BigNum.from_str(s.slot)));
1258
+ return i.NativeScript.new_timelock_start(i.TimelockStart.new_timelockstart(i.BigNum.from_str(s.slot)));
1282
1259
  case "before":
1283
- return n.NativeScript.new_timelock_expiry(n.TimelockExpiry.new_timelockexpiry(n.BigNum.from_str(s.slot)));
1260
+ return i.NativeScript.new_timelock_expiry(i.TimelockExpiry.new_timelockexpiry(i.BigNum.from_str(s.slot)));
1284
1261
  case "sig":
1285
- return n.NativeScript.new_script_pubkey(n.ScriptPubkey.new(P(s.keyHash)));
1262
+ return i.NativeScript.new_script_pubkey(i.ScriptPubkey.new(T(s.keyHash)));
1286
1263
  }
1287
1264
  }, wt = (s) => {
1288
- var r, a, i;
1265
+ var r, a, n;
1289
1266
  const e = (o) => {
1290
1267
  const c = [];
1291
1268
  for (let u = 0; u < o.len(); u += 1)
@@ -1294,90 +1271,90 @@ const Vs = Os, Ys = (s, e) => {
1294
1271
  }, t = (o) => {
1295
1272
  const c = /* @__PURE__ */ new Map();
1296
1273
  for (let u = 0; u < o.len(); u += 1) {
1297
- const A = o.keys().get(u), d = o.get(A) ?? n.PlutusData.from_hex(S("NO_ITEM_FOUND_INSIDE_GOLD_ROOM"));
1298
- c.set(wt(A), wt(d));
1274
+ const A = o.keys().get(u), l = o.get(A) ?? i.PlutusData.from_hex(S("NO_ITEM_FOUND_INSIDE_GOLD_ROOM"));
1275
+ c.set(wt(A), wt(l));
1299
1276
  }
1300
1277
  return c;
1301
1278
  };
1302
1279
  switch (s.kind()) {
1303
- case n.PlutusDataKind.Bytes:
1304
- return b(s.as_bytes() ?? new Uint8Array());
1305
- case n.PlutusDataKind.Integer:
1280
+ case i.PlutusDataKind.Bytes:
1281
+ return D(s.as_bytes() ?? new Uint8Array());
1282
+ case i.PlutusDataKind.Integer:
1306
1283
  return parseInt(((r = s.as_integer()) == null ? void 0 : r.to_str()) ?? "0", 10);
1307
- case n.PlutusDataKind.List:
1308
- return e(s.as_list() ?? n.PlutusList.new());
1309
- case n.PlutusDataKind.Map:
1310
- return t(s.as_map() ?? n.PlutusMap.new());
1311
- case n.PlutusDataKind.ConstrPlutusData:
1284
+ case i.PlutusDataKind.List:
1285
+ return e(s.as_list() ?? i.PlutusList.new());
1286
+ case i.PlutusDataKind.Map:
1287
+ return t(s.as_map() ?? i.PlutusMap.new());
1288
+ case i.PlutusDataKind.ConstrPlutusData:
1312
1289
  return {
1313
1290
  alternative: parseInt(((a = s.as_constr_plutus_data()) == null ? void 0 : a.alternative().to_str()) ?? "0", 10),
1314
- fields: e(((i = s.as_constr_plutus_data()) == null ? void 0 : i.data()) ?? n.PlutusList.new())
1291
+ fields: e(((n = s.as_constr_plutus_data()) == null ? void 0 : n.data()) ?? i.PlutusList.new())
1315
1292
  };
1316
1293
  default:
1317
1294
  throw new Error(`PlutusData Kind: ${s.kind()}, is not supported`);
1318
1295
  }
1319
- }, Z = (s) => {
1296
+ }, tt = (s) => {
1320
1297
  const e = (t) => {
1321
- const r = n.PlutusList.new();
1298
+ const r = i.PlutusList.new();
1322
1299
  return t.forEach((a) => {
1323
- r.add(Z(a));
1300
+ r.add(tt(a));
1324
1301
  }), r;
1325
1302
  };
1326
1303
  switch (typeof s) {
1327
1304
  case "string":
1328
- return n.PlutusData.new_bytes(m(s));
1305
+ return i.PlutusData.new_bytes(m(s));
1329
1306
  case "number":
1330
- return n.PlutusData.new_integer(n.BigInt.from_str(s.toString()));
1307
+ return i.PlutusData.new_integer(i.BigInt.from_str(s.toString()));
1331
1308
  case "object":
1332
1309
  if (s instanceof Array) {
1333
1310
  const t = e(s);
1334
- return n.PlutusData.new_list(t);
1311
+ return i.PlutusData.new_list(t);
1335
1312
  } else if (s instanceof Map) {
1336
- const t = n.PlutusMap.new();
1313
+ const t = i.PlutusMap.new();
1337
1314
  return s.forEach((r, a) => {
1338
- t.insert(Z(a), Z(r));
1339
- }), n.PlutusData.new_map(t);
1315
+ t.insert(tt(a), tt(r));
1316
+ }), i.PlutusData.new_map(t);
1340
1317
  } else
1341
- return n.PlutusData.new_constr_plutus_data(n.ConstrPlutusData.new(n.BigNum.from_str(s.alternative.toString()), e(s.fields)));
1318
+ return i.PlutusData.new_constr_plutus_data(i.ConstrPlutusData.new(i.BigNum.from_str(s.alternative.toString()), e(s.fields)));
1342
1319
  }
1343
- }, js = (s) => {
1344
- const e = n.Relays.new();
1320
+ }, Rs = (s) => {
1321
+ const e = i.Relays.new();
1345
1322
  throw s.relays.forEach((t) => {
1346
- e.add(Xs(t));
1323
+ e.add($s(t));
1347
1324
  }), new Error("toPoolParams not implemented.");
1348
1325
  }, He = (s) => {
1349
- const e = (t) => rs[t];
1350
- return n.Redeemer.new(e(s.tag), n.BigNum.from_str(s.index.toString()), Z(s.data), n.ExUnits.new(n.BigNum.from_str(s.budget.mem.toString()), n.BigNum.from_str(s.budget.steps.toString())));
1351
- }, Xs = (s) => {
1326
+ const e = (t) => es[t];
1327
+ return i.Redeemer.new(e(s.tag), i.BigNum.from_str(s.index.toString()), tt(s.data), i.ExUnits.new(i.BigNum.from_str(s.budget.mem.toString()), i.BigNum.from_str(s.budget.steps.toString())));
1328
+ }, $s = (s) => {
1352
1329
  switch (s.type) {
1353
1330
  case "SingleHostAddr": {
1354
- const e = s.IPV4 ? n.Ipv4.new(new Uint8Array(s.IPV4.split(".").map((r) => parseInt(r)))) : void 0, t = s.IPV6 ? n.Ipv6.new(m(s.IPV6.replaceAll(":", ""))) : void 0;
1355
- return n.Relay.new_single_host_addr(n.SingleHostAddr.new(s.port, e, t));
1331
+ const e = s.IPV4 ? i.Ipv4.new(new Uint8Array(s.IPV4.split(".").map((r) => parseInt(r)))) : void 0, t = s.IPV6 ? i.Ipv6.new(m(s.IPV6.replaceAll(":", ""))) : void 0;
1332
+ return i.Relay.new_single_host_addr(i.SingleHostAddr.new(s.port, e, t));
1356
1333
  }
1357
1334
  case "SingleHostName":
1358
- return n.Relay.new_single_host_name(n.SingleHostName.new(s.port, n.DNSRecordAorAAAA.new(s.domainName)));
1335
+ return i.Relay.new_single_host_name(i.SingleHostName.new(s.port, i.DNSRecordAorAAAA.new(s.domainName)));
1359
1336
  case "MultiHostName":
1360
- return n.Relay.new_multi_host_name(n.MultiHostName.new(n.DNSRecordSRV.new(s.domainName)));
1337
+ return i.Relay.new_multi_host_name(i.MultiHostName.new(i.DNSRecordSRV.new(s.domainName)));
1361
1338
  }
1362
1339
  }, Oe = (s) => {
1363
1340
  if (s.is_plutus_script()) {
1364
1341
  const t = s.plutus_script();
1365
1342
  return {
1366
1343
  code: t.to_hex(),
1367
- version: Object.keys(Et).find((r) => Et[r].to_hex() === t.language_version().to_hex())
1344
+ version: Object.keys(xt).find((r) => xt[r].to_hex() === t.language_version().to_hex())
1368
1345
  };
1369
1346
  }
1370
1347
  const e = s.native_script();
1371
1348
  return Dt(e);
1372
- }, lt = (s) => {
1349
+ }, ct = (s) => {
1373
1350
  if ("code" in s) {
1374
- const e = it(s.code, s.version);
1375
- return n.ScriptRef.new_plutus_script(e);
1351
+ const e = ot(s.code, s.version);
1352
+ return i.ScriptRef.new_plutus_script(e);
1376
1353
  }
1377
- return n.ScriptRef.new_native_script(vt(s));
1354
+ return i.ScriptRef.new_native_script(vt(s));
1378
1355
  }, Qt = (s) => {
1379
- var a, i, o;
1380
- const e = s.output().has_data_hash() ? (a = s.output().data_hash()) == null ? void 0 : a.to_hex() : void 0, t = s.output().has_plutus_data() ? (i = s.output().plutus_data()) == null ? void 0 : i.to_hex() : void 0, r = s.output().has_script_ref() ? (o = s.output().script_ref()) == null ? void 0 : o.to_hex() : void 0;
1356
+ var a, n, o;
1357
+ const e = s.output().has_data_hash() ? (a = s.output().data_hash()) == null ? void 0 : a.to_hex() : void 0, t = s.output().has_plutus_data() ? (n = s.output().plutus_data()) == null ? void 0 : n.to_hex() : void 0, r = s.output().has_script_ref() ? (o = s.output().script_ref()) == null ? void 0 : o.to_hex() : void 0;
1381
1358
  return {
1382
1359
  input: {
1383
1360
  outputIndex: s.input().index(),
@@ -1391,121 +1368,121 @@ const Vs = Os, Ys = (s, e) => {
1391
1368
  scriptRef: r
1392
1369
  }
1393
1370
  };
1394
- }, N = (s) => {
1395
- const e = n.TransactionInput.new(Fe(s.input.txHash), s.input.outputIndex), t = n.TransactionOutput.new(T(s.output.address), Bt(s.output.amount));
1396
- return s.output.dataHash !== void 0 && t.set_data_hash(Gs(s.output.dataHash)), s.output.plutusData !== void 0 && t.set_plutus_data(Pe(s.output.plutusData)), s.output.scriptRef !== void 0 && t.set_script_ref($s(s.output.scriptRef)), n.TransactionUnspentOutput.new(e, t);
1371
+ }, F = (s) => {
1372
+ const e = i.TransactionInput.new(Fe(s.input.txHash), s.input.outputIndex), t = i.TransactionOutput.new(H(s.output.address), Bt(s.output.amount));
1373
+ return s.output.dataHash !== void 0 && t.set_data_hash(Hs(s.output.dataHash)), s.output.plutusData !== void 0 && t.set_plutus_data(Pe(s.output.plutusData)), s.output.scriptRef !== void 0 && t.set_script_ref(Ys(s.output.scriptRef)), i.TransactionUnspentOutput.new(e, t);
1397
1374
  }, he = (s) => {
1398
1375
  const e = s.split(".")[1] ?? "0", t = `${parseInt(e, 10)}`, r = "1" + "0".repeat(e.length);
1399
- return n.UnitInterval.new(n.BigNum.from_str(t), n.BigNum.from_str(r));
1400
- }, S = (s) => s.length % 2 === 0 && /^[0-9A-F]*$/i.test(s) ? s : b(Buffer.from(s, "utf-8")), Yt = (s) => Buffer.from(s, "hex").toString("utf-8"), Ve = (s) => {
1376
+ return i.UnitInterval.new(i.BigNum.from_str(t), i.BigNum.from_str(r));
1377
+ }, S = (s) => s.length % 2 === 0 && /^[0-9A-F]*$/i.test(s) ? s : D(Buffer.from(s, "utf-8")), qt = (s) => Buffer.from(s, "hex").toString("utf-8"), Ve = (s) => {
1401
1378
  const e = [
1402
1379
  { unit: "lovelace", quantity: s.coin().to_str() }
1403
1380
  ], t = s.multiasset();
1404
1381
  if (t !== void 0) {
1405
1382
  const r = t.keys();
1406
1383
  for (let a = 0; a < r.len(); a += 1) {
1407
- const i = r.get(a), o = t.get(i);
1384
+ const n = r.get(a), o = t.get(n);
1408
1385
  if (o !== void 0) {
1409
1386
  const c = o.keys();
1410
1387
  for (let u = 0; u < c.len(); u += 1) {
1411
- const A = c.get(u), d = o.get(A) ?? n.BigNum.from_str("0"), g = i.to_hex() + b(A.name());
1412
- e.push({ unit: g, quantity: d.to_str() });
1388
+ const A = c.get(u), l = o.get(A) ?? i.BigNum.from_str("0"), g = n.to_hex() + D(A.name());
1389
+ e.push({ unit: g, quantity: l.to_str() });
1413
1390
  }
1414
1391
  }
1415
1392
  }
1416
1393
  }
1417
1394
  return e;
1418
1395
  }, Bt = (s) => {
1419
- const e = s.find((i) => i.unit === "lovelace"), t = Array.from(new Set(s.filter((i) => i.unit !== "lovelace").map((i) => i.unit.slice(0, F)))), r = n.MultiAsset.new();
1420
- t.forEach((i) => {
1421
- const o = n.Assets.new();
1422
- s.filter((c) => c.unit.slice(0, F) === i).forEach((c) => {
1423
- o.insert(n.AssetName.new(m(c.unit.slice(F))), n.BigNum.from_str(c.quantity));
1424
- }), r.insert(zs(i), o);
1396
+ const e = s.find((n) => n.unit === "lovelace"), t = Array.from(new Set(s.filter((n) => n.unit !== "lovelace").map((n) => n.unit.slice(0, M)))), r = i.MultiAsset.new();
1397
+ t.forEach((n) => {
1398
+ const o = i.Assets.new();
1399
+ s.filter((c) => c.unit.slice(0, M) === n).forEach((c) => {
1400
+ o.insert(i.AssetName.new(m(c.unit.slice(M))), i.BigNum.from_str(c.quantity));
1401
+ }), r.insert(qs(n), o);
1425
1402
  });
1426
- const a = n.Value.new(n.BigNum.from_str(e ? e.quantity : "0"));
1403
+ const a = i.Value.new(i.BigNum.from_str(e ? e.quantity : "0"));
1427
1404
  return (s.length > 1 || !e) && a.set_multiasset(r), a;
1428
- }, Ie = (s, e, t) => n.BaseAddress.new(s, n.StakeCredential.from_keyhash(e), n.StakeCredential.from_keyhash(t)), Ye = (s, e = "") => n.Bip32PrivateKey.from_bip39_entropy(m(s), m(S(e))), me = (s) => n.DataCost.new_coins_per_byte(n.BigNum.from_str(s)), Zs = (s) => {
1405
+ }, Ie = (s, e, t) => i.BaseAddress.new(s, i.StakeCredential.from_keyhash(e), i.StakeCredential.from_keyhash(t)), Ye = (s, e = "") => i.Bip32PrivateKey.from_bip39_entropy(m(s), m(S(e))), me = (s) => i.DataCost.new_coins_per_byte(i.BigNum.from_str(s)), zs = (s) => {
1429
1406
  if (typeof s != "object" || !("input" in s))
1430
- return n.DatumSource.new(Z(s));
1431
- const e = N(s);
1407
+ return i.DatumSource.new(tt(s));
1408
+ const e = F(s);
1432
1409
  if (e.output().has_plutus_data())
1433
- return n.DatumSource.new_ref_input(e.input());
1410
+ return i.DatumSource.new_ref_input(e.input());
1434
1411
  throw new Error(`No inline datum found in UTxO: ${e.input().transaction_id().to_hex()}`);
1435
- }, pe = (s, e) => n.EnterpriseAddress.new(s, n.StakeCredential.from_keyhash(e)), fe = (s, e) => {
1412
+ }, pe = (s, e) => i.EnterpriseAddress.new(s, i.StakeCredential.from_keyhash(e)), fe = (s, e) => {
1436
1413
  if (typeof s == "string")
1437
- return n.MintWitness.new_native_script(bt(s));
1414
+ return i.MintWitness.new_native_script(bt(s));
1438
1415
  if (e === void 0)
1439
1416
  throw new Error("Minting with plutus requires a redeemer to be defined");
1440
1417
  if (e.tag !== "MINT")
1441
1418
  throw new Error("Minting redeemer's tag must be defined as 'MINT'");
1442
- return n.MintWitness.new_plutus_script(qe(s), He({
1419
+ return i.MintWitness.new_plutus_script(qe(s), He({
1443
1420
  tag: "MINT",
1444
1421
  index: 0,
1445
- budget: Ee,
1422
+ budget: xe,
1446
1423
  data: {
1447
1424
  alternative: 0,
1448
1425
  fields: []
1449
1426
  },
1450
1427
  ...e
1451
1428
  }));
1452
- }, Pt = (s, e) => n.RewardAddress.new(s, n.StakeCredential.from_keyhash(e)), qe = (s) => {
1429
+ }, Ft = (s, e) => i.RewardAddress.new(s, i.StakeCredential.from_keyhash(e)), qe = (s) => {
1453
1430
  if ("code" in s)
1454
- return n.PlutusScriptSource.new(it(s.code, s.version));
1455
- const e = N(s);
1431
+ return i.PlutusScriptSource.new(ot(s.code, s.version));
1432
+ const e = F(s);
1456
1433
  if (e.output().has_script_ref()) {
1457
1434
  const t = e.output().script_ref();
1458
1435
  if (t.is_plutus_script()) {
1459
- const r = Oe(t), a = it(r.code, r.version).hash();
1460
- return n.PlutusScriptSource.new_ref_input_with_lang_ver(a, e.input(), Et[r.version]);
1436
+ const r = Oe(t), a = ot(r.code, r.version).hash();
1437
+ return i.PlutusScriptSource.new_ref_input_with_lang_ver(a, e.input(), xt[r.version]);
1461
1438
  }
1462
1439
  }
1463
1440
  throw new Error(`No plutus script reference found in UTxO: ${e.input().transaction_id().to_hex()}`);
1464
- }, pt = (s) => {
1465
- const e = n.ScriptPubkey.new(s);
1466
- return n.NativeScript.new_script_pubkey(e);
1467
- }, tr = (s = q) => {
1468
- const e = n.TransactionBuilderConfigBuilder.new().coins_per_utxo_byte(n.BigNum.from_str(s.coinsPerUTxOSize)).ex_unit_prices(n.ExUnitPrices.new(he(s.priceMem.toString()), he(s.priceStep.toString()))).fee_algo(n.LinearFee.new(n.BigNum.from_str(s.minFeeA.toString()), n.BigNum.from_str(s.minFeeB.toString()))).key_deposit(n.BigNum.from_str(s.keyDeposit)).max_tx_size(s.maxTxSize).max_value_size(parseInt(s.maxValSize, 10)).pool_deposit(n.BigNum.from_str(s.poolDeposit)).build();
1469
- return n.TransactionBuilder.new(e);
1441
+ }, ft = (s) => {
1442
+ const e = i.ScriptPubkey.new(s);
1443
+ return i.NativeScript.new_script_pubkey(e);
1444
+ }, Ws = (s = G) => {
1445
+ const e = i.TransactionBuilderConfigBuilder.new().coins_per_utxo_byte(i.BigNum.from_str(s.coinsPerUTxOSize)).ex_unit_prices(i.ExUnitPrices.new(he(s.priceMem.toString()), he(s.priceStep.toString()))).fee_algo(i.LinearFee.new(i.BigNum.from_str(s.minFeeA.toString()), i.BigNum.from_str(s.minFeeB.toString()))).key_deposit(i.BigNum.from_str(s.keyDeposit)).max_tx_size(s.maxTxSize).max_value_size(parseInt(s.maxValSize, 10)).pool_deposit(i.BigNum.from_str(s.poolDeposit)).build();
1446
+ return i.TransactionBuilder.new(e);
1470
1447
  }, _e = (s) => {
1471
- const e = n.TxInputsBuilder.new();
1472
- return s.map((t) => t instanceof n.TransactionUnspentOutput ? t : N(t)).forEach((t) => {
1448
+ const e = i.TxInputsBuilder.new();
1449
+ return s.map((t) => t instanceof i.TransactionUnspentOutput ? t : F(t)).forEach((t) => {
1473
1450
  e.add_input(t.output().address(), t.input(), t.output().amount());
1474
1451
  }), e;
1475
- }, ft = (s) => {
1452
+ }, _t = (s) => {
1476
1453
  if (typeof s == "string")
1477
- return n.TransactionOutputBuilder.new().with_address(T(s));
1478
- let e = n.TransactionOutputBuilder.new().with_address(T(s.address));
1454
+ return i.TransactionOutputBuilder.new().with_address(H(s));
1455
+ let e = i.TransactionOutputBuilder.new().with_address(H(s.address));
1479
1456
  if (s.datum) {
1480
- const { value: t, inline: r } = s.datum, a = Z(t);
1481
- e = e.with_data_hash(n.hash_plutus_data(a)), r && (e = e.with_plutus_data(a));
1457
+ const { value: t, inline: r } = s.datum, a = tt(t);
1458
+ e = e.with_data_hash(i.hash_plutus_data(a)), r && (e = e.with_plutus_data(a));
1482
1459
  }
1483
1460
  if (s.script) {
1484
- const t = lt(s.script);
1461
+ const t = ct(s.script);
1485
1462
  e = e.with_script_ref(t);
1486
1463
  }
1487
1464
  return e;
1488
- }, ot = (s) => {
1489
- const e = s.slice(0, F), t = s.includes(".") ? S(s.split(".")[1]) : s.slice(F);
1465
+ }, X = (s) => {
1466
+ const e = s.slice(0, M), t = s.includes(".") ? S(s.split(".")[1]) : s.slice(M);
1490
1467
  return { policyId: e, assetName: t };
1491
- }, l = (s) => j.isAxiosError(s) ? s.response ? JSON.stringify({
1468
+ }, d = (s) => L.isAxiosError(s) ? s.response ? JSON.stringify({
1492
1469
  data: s.response.data,
1493
1470
  headers: s.response.headers,
1494
1471
  status: s.response.status
1495
- }) : s.request ? JSON.stringify(s.request) : s.message : JSON.stringify(s), dr = (s) => {
1496
- const e = Z(s);
1497
- return n.hash_plutus_data(e).to_hex();
1498
- }, lr = (s, e = Date.now()) => {
1499
- if (xt[s]) {
1500
- const [t, r, a, i] = xt[s];
1501
- return parseInt(n.BigNum.from_str(e.toString()).div_floor(n.BigNum.from_str("1000")).checked_sub(n.BigNum.from_str(a)).div_floor(n.BigNum.from_str(i)).checked_add(n.BigNum.from_str(t)).to_str(), 10);
1472
+ }) : s.request ? JSON.stringify(s.request) : s.message : JSON.stringify(s), cr = (s) => {
1473
+ const e = tt(s);
1474
+ return i.hash_plutus_data(e).to_hex();
1475
+ }, ur = (s, e = Date.now()) => {
1476
+ if (Et[s]) {
1477
+ const [t, r, a, n] = Et[s];
1478
+ return parseInt(i.BigNum.from_str(e.toString()).div_floor(i.BigNum.from_str("1000")).checked_sub(i.BigNum.from_str(a)).div_floor(i.BigNum.from_str(n)).checked_add(i.BigNum.from_str(t)).to_str(), 10);
1502
1479
  }
1503
1480
  throw new Error(`Couldn't resolve EpochNo for network: ${s}`);
1504
- }, er = (s, e) => Vs.fromParts(m(s), m(e)).fingerprint(), hr = (s, e) => as[s][e], Ir = (s) => vt(s).hash().to_hex(), st = (s) => {
1481
+ }, Js = (s, e) => Fs.fromParts(m(s), m(e)).fingerprint(), Ar = (s, e) => ss[s][e], dr = (s) => vt(s).hash().to_hex(), rt = (s) => {
1505
1482
  var e, t;
1506
1483
  try {
1507
1484
  const r = [
1508
- (e = Vt(s)) == null ? void 0 : e.payment_cred().to_keyhash(),
1485
+ (e = Yt(s)) == null ? void 0 : e.payment_cred().to_keyhash(),
1509
1486
  (t = Te(s)) == null ? void 0 : t.payment_cred().to_keyhash()
1510
1487
  ].find((a) => a !== void 0);
1511
1488
  if (r !== void 0)
@@ -1514,10 +1491,10 @@ const Vs = Os, Ys = (s, e) => {
1514
1491
  } catch (r) {
1515
1492
  throw new Error(`An error occurred during resolvePaymentKeyHash: ${r}.`);
1516
1493
  }
1517
- }, mr = (s, e = 0) => {
1518
- const t = it(s.code, s.version);
1519
- return n.EnterpriseAddress.new(e, n.StakeCredential.from_scripthash(t.hash())).to_address().to_bech32();
1520
- }, pr = (s) => {
1494
+ }, gr = (s, e = 0) => {
1495
+ const t = ot(s.code, s.version);
1496
+ return i.EnterpriseAddress.new(e, i.StakeCredential.from_scripthash(t.hash())).to_address().to_bech32();
1497
+ }, lr = (s) => {
1521
1498
  try {
1522
1499
  const e = Te(s), t = e == null ? void 0 : e.payment_cred().to_scripthash();
1523
1500
  if (t !== void 0)
@@ -1526,29 +1503,29 @@ const Vs = Os, Ys = (s, e) => {
1526
1503
  } catch (e) {
1527
1504
  throw new Error(`An error occurred during resolveScriptHash: ${e}.`);
1528
1505
  }
1529
- }, fr = (s) => n.Ed25519KeyHash.from_hex(s).to_bech32("pool1"), _r = (s) => {
1530
- const e = ye(s.join(" ")), t = Ye(e), r = t.to_bech32();
1506
+ }, hr = (s) => i.Ed25519KeyHash.from_hex(s).to_bech32("pool1"), Ir = (s) => {
1507
+ const e = Ce(s.join(" ")), t = Ye(e), r = t.to_bech32();
1531
1508
  return t.free(), r;
1532
- }, yr = (s) => lt(s).to_hex(), Cr = (s, e = Date.now()) => {
1533
- if (xt[s]) {
1534
- const [t, r, a] = xt[s];
1535
- return n.BigNum.from_str(e.toString()).div_floor(n.BigNum.from_str("1000")).checked_sub(n.BigNum.from_str(a)).checked_add(n.BigNum.from_str(r)).to_str();
1509
+ }, mr = (s) => ct(s).to_hex(), pr = (s, e = Date.now()) => {
1510
+ if (Et[s]) {
1511
+ const [t, r, a] = Et[s];
1512
+ return i.BigNum.from_str(e.toString()).div_floor(i.BigNum.from_str("1000")).checked_sub(i.BigNum.from_str(a)).checked_add(i.BigNum.from_str(r)).to_str();
1536
1513
  }
1537
1514
  throw new Error(`Couldn't resolve SlotNo for network: ${s}`);
1538
- }, qt = (s) => {
1515
+ }, kt = (s) => {
1539
1516
  try {
1540
- const e = T(s), t = Vt(s), r = t == null ? void 0 : t.stake_cred().to_keyhash();
1517
+ const e = H(s), t = Yt(s), r = t == null ? void 0 : t.stake_cred().to_keyhash();
1541
1518
  if (r !== void 0)
1542
- return Pt(e.network_id(), r).to_address().to_bech32();
1519
+ return Ft(e.network_id(), r).to_address().to_bech32();
1543
1520
  throw new Error(`Couldn't resolve reward address from address: ${s}`);
1544
1521
  } catch (e) {
1545
1522
  throw new Error(`An error occurred during resolveRewardAddress: ${e}.`);
1546
1523
  }
1547
- }, At = (s) => {
1524
+ }, dt = (s) => {
1548
1525
  var e, t;
1549
1526
  try {
1550
1527
  const r = [
1551
- (e = Vt(s)) == null ? void 0 : e.stake_cred().to_keyhash(),
1528
+ (e = Yt(s)) == null ? void 0 : e.stake_cred().to_keyhash(),
1552
1529
  (t = Me(s)) == null ? void 0 : t.payment_cred().to_keyhash()
1553
1530
  ].find((a) => a !== void 0);
1554
1531
  if (r !== void 0)
@@ -1557,44 +1534,44 @@ const Vs = Os, Ys = (s, e) => {
1557
1534
  } catch (r) {
1558
1535
  throw new Error(`An error occurred during resolveStakeKeyHash: ${r}.`);
1559
1536
  }
1560
- }, Ge = (s, e = q.minFeeA, t = q.minFeeB) => (BigInt(e) * BigInt(s) + BigInt(t)).toString(), sr = (s) => {
1561
- const e = Y(s).body();
1562
- return n.hash_transaction(e).to_hex();
1563
- }, wr = (s = "", e = 32) => {
1537
+ }, Le = (s, e = G.minFeeA, t = G.minFeeB) => (BigInt(e) * BigInt(s) + BigInt(t)).toString(), js = (s) => {
1538
+ const e = q(s).body();
1539
+ return i.hash_transaction(e).to_hex();
1540
+ }, fr = (s = "", e = 32) => {
1564
1541
  if (e <= 0 || e > 2048)
1565
1542
  throw new Error("Length must be bewteen 1 and 2048");
1566
- const r = Be("ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789")(e);
1543
+ const r = ye("ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789")(e);
1567
1544
  return S(`${s}${r}`);
1568
- }, Le = (s, e) => {
1545
+ }, Ge = (s, e) => {
1569
1546
  const t = s.vkeys();
1570
1547
  if (t !== void 0) {
1571
1548
  const r = /* @__PURE__ */ new Set();
1572
- for (let i = 0; i < t.len(); i += 1)
1573
- r.add(t.get(i).to_hex());
1574
- for (let i = 0; i < e.len(); i += 1)
1575
- r.add(e.get(i).to_hex());
1576
- const a = n.Vkeywitnesses.new();
1577
- return r.forEach((i) => {
1578
- a.add(n.Vkeywitness.from_hex(i));
1549
+ for (let n = 0; n < t.len(); n += 1)
1550
+ r.add(t.get(n).to_hex());
1551
+ for (let n = 0; n < e.len(); n += 1)
1552
+ r.add(e.get(n).to_hex());
1553
+ const a = i.Vkeywitnesses.new();
1554
+ return r.forEach((n) => {
1555
+ a.add(i.Vkeywitness.from_hex(n));
1579
1556
  }), a;
1580
1557
  }
1581
1558
  return e;
1582
- }, Br = (s) => wt(Pe(s)), Er = (s) => Y(s).to_js_value();
1583
- class xr {
1559
+ }, _r = (s) => wt(Pe(s)), yr = (s) => q(s).to_js_value();
1560
+ class Cr {
1584
1561
  _axiosInstance;
1585
1562
  constructor(...e) {
1586
1563
  if (typeof e[0] == "string" && e[0].startsWith("http"))
1587
- this._axiosInstance = j.create({ baseURL: e[0] });
1564
+ this._axiosInstance = L.create({ baseURL: e[0] });
1588
1565
  else {
1589
1566
  const t = e[0], r = t.slice(0, 7);
1590
- this._axiosInstance = j.create({
1567
+ this._axiosInstance = L.create({
1591
1568
  baseURL: `https://cardano-${r}.blockfrost.io/api/v${e[1] ?? 0}`,
1592
1569
  headers: { project_id: t }
1593
1570
  });
1594
1571
  }
1595
1572
  }
1596
1573
  async fetchAccountInfo(e) {
1597
- const t = e.startsWith("addr") ? qt(e) : e;
1574
+ const t = e.startsWith("addr") ? kt(e) : e;
1598
1575
  try {
1599
1576
  const { data: r, status: a } = await this._axiosInstance.get(`accounts/${t}`);
1600
1577
  if (a === 200)
@@ -1605,28 +1582,28 @@ class xr {
1605
1582
  rewards: r.withdrawable_amount,
1606
1583
  withdrawals: r.withdrawals_sum
1607
1584
  };
1608
- throw l(r);
1585
+ throw d(r);
1609
1586
  } catch (r) {
1610
- throw l(r);
1587
+ throw d(r);
1611
1588
  }
1612
1589
  }
1613
1590
  async fetchAddressUTxOs(e, t) {
1614
- const r = t !== void 0 ? `/${t}` : "", a = `addresses/${e}/utxos` + r, i = async (u = 1, A = []) => {
1615
- const { data: d, status: g } = await this._axiosInstance.get(`${a}?page=${u}`);
1591
+ const r = t !== void 0 ? `/${t}` : "", a = `addresses/${e}/utxos` + r, n = async (u = 1, A = []) => {
1592
+ const { data: l, status: g } = await this._axiosInstance.get(`${a}?page=${u}`);
1616
1593
  if (g === 200)
1617
- return d.length > 0 ? i(u + 1, [...A, ...await Promise.all(d.map(c))]) : A;
1618
- throw l(d);
1594
+ return l.length > 0 ? n(u + 1, [...A, ...await Promise.all(l.map(c))]) : A;
1595
+ throw d(l);
1619
1596
  }, o = async (u) => {
1620
1597
  if (u) {
1621
- const { data: A, status: d } = await this._axiosInstance.get(`scripts/${u}`);
1622
- if (d === 200) {
1598
+ const { data: A, status: l } = await this._axiosInstance.get(`scripts/${u}`);
1599
+ if (l === 200) {
1623
1600
  const g = A.type.startsWith("plutus") ? {
1624
1601
  code: await this.fetchPlutusScriptCBOR(u),
1625
1602
  version: A.type.replace("plutus", "")
1626
1603
  } : await this.fetchNativeScriptJSON(u);
1627
- return lt(g).to_hex();
1604
+ return ct(g).to_hex();
1628
1605
  }
1629
- throw l(A);
1606
+ throw d(A);
1630
1607
  }
1631
1608
  }, c = async (u) => ({
1632
1609
  input: {
@@ -1642,17 +1619,17 @@ class xr {
1642
1619
  }
1643
1620
  });
1644
1621
  try {
1645
- return await i();
1622
+ return await n();
1646
1623
  } catch {
1647
1624
  return [];
1648
1625
  }
1649
1626
  }
1650
1627
  async fetchAssetAddresses(e) {
1651
1628
  const t = async (r = 1, a = []) => {
1652
- const { policyId: i, assetName: o } = ot(e), { data: c, status: u } = await this._axiosInstance.get(`assets/${i}${o}/addresses?page=${r}`);
1629
+ const { policyId: n, assetName: o } = X(e), { data: c, status: u } = await this._axiosInstance.get(`assets/${n}${o}/addresses?page=${r}`);
1653
1630
  if (u === 200)
1654
1631
  return c.length > 0 ? t(r + 1, [...a, ...c]) : a;
1655
- throw l(c);
1632
+ throw d(c);
1656
1633
  };
1657
1634
  try {
1658
1635
  return await t();
@@ -1662,14 +1639,14 @@ class xr {
1662
1639
  }
1663
1640
  async fetchAssetMetadata(e) {
1664
1641
  try {
1665
- const { policyId: t, assetName: r } = ot(e), { data: a, status: i } = await this._axiosInstance.get(`assets/${t}${r}`);
1666
- if (i === 200)
1642
+ const { policyId: t, assetName: r } = X(e), { data: a, status: n } = await this._axiosInstance.get(`assets/${t}${r}`);
1643
+ if (n === 200)
1667
1644
  return {
1668
1645
  ...a.onchain_metadata
1669
1646
  };
1670
- throw l(a);
1647
+ throw d(a);
1671
1648
  } catch (t) {
1672
- throw l(t);
1649
+ throw d(t);
1673
1650
  }
1674
1651
  }
1675
1652
  async fetchBlockInfo(e) {
@@ -1693,9 +1670,9 @@ class xr {
1693
1670
  txCount: t.tx_count,
1694
1671
  VRFKey: t.block_vrf
1695
1672
  };
1696
- throw l(t);
1673
+ throw d(t);
1697
1674
  } catch (t) {
1698
- throw l(t);
1675
+ throw d(t);
1699
1676
  }
1700
1677
  }
1701
1678
  async fetchCollectionAssets(e, t = 1) {
@@ -1703,25 +1680,25 @@ class xr {
1703
1680
  const { data: r, status: a } = await this._axiosInstance.get(`assets/policy/${e}?page=${t}`);
1704
1681
  if (a === 200)
1705
1682
  return {
1706
- assets: r.map((i) => ({
1707
- unit: i.asset,
1708
- quantity: i.quantity
1683
+ assets: r.map((n) => ({
1684
+ unit: n.asset,
1685
+ quantity: n.quantity
1709
1686
  })),
1710
1687
  next: r.length === 100 ? t + 1 : null
1711
1688
  };
1712
- throw l(r);
1689
+ throw d(r);
1713
1690
  } catch {
1714
1691
  return { assets: [], next: null };
1715
1692
  }
1716
1693
  }
1717
1694
  async fetchHandleAddress(e) {
1718
1695
  try {
1719
- const t = S(e.replace("$", "")), { data: r, status: a } = await this._axiosInstance.get(`assets/${Tt[1]}${t}/addresses`);
1696
+ const t = S(e.replace("$", "")), { data: r, status: a } = await this._axiosInstance.get(`assets/${Mt[1]}${t}/addresses`);
1720
1697
  if (a === 200)
1721
1698
  return r[0].address;
1722
- throw l(r);
1699
+ throw d(r);
1723
1700
  } catch (t) {
1724
- throw l(t);
1701
+ throw d(t);
1725
1702
  }
1726
1703
  }
1727
1704
  async fetchProtocolParameters(e = Number.NaN) {
@@ -1750,9 +1727,9 @@ class xr {
1750
1727
  priceMem: t.price_mem,
1751
1728
  priceStep: t.price_step
1752
1729
  };
1753
- throw l(t);
1730
+ throw d(t);
1754
1731
  } catch (t) {
1755
- throw l(t);
1732
+ throw d(t);
1756
1733
  }
1757
1734
  }
1758
1735
  async fetchTxInfo(e) {
@@ -1770,17 +1747,17 @@ class xr {
1770
1747
  slot: t.slot.toString(),
1771
1748
  size: t.size
1772
1749
  };
1773
- throw l(t);
1750
+ throw d(t);
1774
1751
  } catch (t) {
1775
- throw l(t);
1752
+ throw d(t);
1776
1753
  }
1777
1754
  }
1778
1755
  onTxConfirmed(e, t, r = 100) {
1779
1756
  let a = 0;
1780
- const i = setInterval(() => {
1781
- a >= r && clearInterval(i), this.fetchTxInfo(e).then((o) => {
1757
+ const n = setInterval(() => {
1758
+ a >= r && clearInterval(n), this.fetchTxInfo(e).then((o) => {
1782
1759
  this.fetchBlockInfo(o.block).then((c) => {
1783
- (c == null ? void 0 : c.confirmations) > 0 && (clearInterval(i), t());
1760
+ (c == null ? void 0 : c.confirmations) > 0 && (clearInterval(n), t());
1784
1761
  }).catch(() => {
1785
1762
  a += 1;
1786
1763
  });
@@ -1794,54 +1771,54 @@ class xr {
1794
1771
  const t = { "Content-Type": "application/cbor" }, { data: r, status: a } = await this._axiosInstance.post("tx/submit", m(e), { headers: t });
1795
1772
  if (a === 200)
1796
1773
  return r;
1797
- throw l(r);
1774
+ throw d(r);
1798
1775
  } catch (t) {
1799
- throw l(t);
1776
+ throw d(t);
1800
1777
  }
1801
1778
  }
1802
1779
  async fetchPlutusScriptCBOR(e) {
1803
1780
  const { data: t, status: r } = await this._axiosInstance.get(`scripts/${e}/cbor`);
1804
1781
  if (r === 200)
1805
1782
  return t.cbor;
1806
- throw l(t);
1783
+ throw d(t);
1807
1784
  }
1808
1785
  async fetchNativeScriptJSON(e) {
1809
1786
  const { data: t, status: r } = await this._axiosInstance.get(`scripts/${e}/json`);
1810
1787
  if (r === 200)
1811
1788
  return t.json;
1812
- throw l(t);
1789
+ throw d(t);
1813
1790
  }
1814
1791
  }
1815
- class Sr {
1792
+ class wr {
1816
1793
  _axiosInstance;
1817
1794
  constructor(e, t, r) {
1818
- const a = r.host ?? "ipfs.infura.io", i = r.port ?? 5001, o = r.version ?? 0;
1819
- this._axiosInstance = j.create({
1820
- baseURL: `https://${a}:${i}/api/v${o}`,
1795
+ const a = r.host ?? "ipfs.infura.io", n = r.port ?? 5001, o = r.version ?? 0;
1796
+ this._axiosInstance = L.create({
1797
+ baseURL: `https://${a}:${n}/api/v${o}`,
1821
1798
  auth: { username: e, password: t }
1822
1799
  });
1823
1800
  }
1824
1801
  async uploadContent(e, t = !1) {
1825
1802
  try {
1826
- const r = { "Content-Type": "multipart/form-data" }, { data: a, status: i } = await this._axiosInstance.post(`add?recursive=${t}`, e, { headers: r });
1827
- if (i === 200)
1803
+ const r = { "Content-Type": "multipart/form-data" }, { data: a, status: n } = await this._axiosInstance.post(`add?recursive=${t}`, e, { headers: r });
1804
+ if (n === 200)
1828
1805
  return a;
1829
- throw l(a);
1806
+ throw d(a);
1830
1807
  } catch (r) {
1831
- throw l(r);
1808
+ throw d(r);
1832
1809
  }
1833
1810
  }
1834
1811
  }
1835
- class Qr {
1812
+ class Br {
1836
1813
  _axiosInstance;
1837
1814
  constructor(...e) {
1838
- typeof e[0] == "string" && e[0].startsWith("http") ? this._axiosInstance = j.create({ baseURL: e[0] }) : this._axiosInstance = j.create({
1815
+ typeof e[0] == "string" && e[0].startsWith("http") ? this._axiosInstance = L.create({ baseURL: e[0] }) : this._axiosInstance = L.create({
1839
1816
  baseURL: `https://${e[0]}.koios.rest/api/v${e[1] ?? 0}`
1840
1817
  });
1841
1818
  }
1842
1819
  async fetchAccountInfo(e) {
1843
1820
  try {
1844
- const t = e.startsWith("addr") ? qt(e) : e, { data: r, status: a } = await this._axiosInstance.post("account_info", { _stake_addresses: [t] });
1821
+ const t = e.startsWith("addr") ? kt(e) : e, { data: r, status: a } = await this._axiosInstance.post("account_info", { _stake_addresses: [t] });
1845
1822
  if (a === 200)
1846
1823
  return {
1847
1824
  poolId: r[0].delegated_pool,
@@ -1850,24 +1827,24 @@ class Qr {
1850
1827
  rewards: r[0].rewards_available,
1851
1828
  withdrawals: r[0].withdrawals
1852
1829
  };
1853
- throw l(r);
1830
+ throw d(r);
1854
1831
  } catch (t) {
1855
- throw l(t);
1832
+ throw d(t);
1856
1833
  }
1857
1834
  }
1858
1835
  async fetchAddressUTxOs(e, t) {
1859
1836
  const r = (a) => {
1860
1837
  if (a) {
1861
- const i = a.type.startsWith("plutus") ? {
1838
+ const n = a.type.startsWith("plutus") ? {
1862
1839
  code: a.bytes,
1863
1840
  version: a.type.replace("plutus", "")
1864
1841
  } : Dt(bt(a.bytes));
1865
- return lt(i).to_hex();
1842
+ return ct(n).to_hex();
1866
1843
  }
1867
1844
  };
1868
1845
  try {
1869
- const { data: a, status: i } = await this._axiosInstance.post("address_info", { _addresses: [e] });
1870
- if (i === 200) {
1846
+ const { data: a, status: n } = await this._axiosInstance.post("address_info", { _addresses: [e] });
1847
+ if (n === 200) {
1871
1848
  const o = a.flatMap((c) => c.utxo_set).map((c) => {
1872
1849
  var u;
1873
1850
  return {
@@ -1892,34 +1869,34 @@ class Qr {
1892
1869
  });
1893
1870
  return t !== void 0 ? o.filter((c) => c.output.amount.find((u) => u.unit === t) !== void 0) : o;
1894
1871
  }
1895
- throw l(a);
1872
+ throw d(a);
1896
1873
  } catch {
1897
1874
  return [];
1898
1875
  }
1899
1876
  }
1900
1877
  async fetchAssetAddresses(e) {
1901
1878
  try {
1902
- const { policyId: t, assetName: r } = ot(e), { data: a, status: i } = await this._axiosInstance.get(`asset_address_list?_asset_policy=${t}&_asset_name=${r}`);
1903
- if (i === 200)
1879
+ const { policyId: t, assetName: r } = X(e), { data: a, status: n } = await this._axiosInstance.get(`asset_address_list?_asset_policy=${t}&_asset_name=${r}`);
1880
+ if (n === 200)
1904
1881
  return a.map((o) => ({
1905
1882
  address: o.payment_address,
1906
1883
  quantity: o.quantity
1907
1884
  }));
1908
- throw l(a);
1885
+ throw d(a);
1909
1886
  } catch (t) {
1910
- throw l(t);
1887
+ throw d(t);
1911
1888
  }
1912
1889
  }
1913
1890
  async fetchAssetMetadata(e) {
1914
1891
  try {
1915
- const { policyId: t, assetName: r } = ot(e), { data: a, status: i } = await this._axiosInstance.get(`asset_info?_asset_policy=${t}&_asset_name=${r}`);
1916
- if (i === 200)
1892
+ const { policyId: t, assetName: r } = X(e), { data: a, status: n } = await this._axiosInstance.get(`asset_info?_asset_policy=${t}&_asset_name=${r}`);
1893
+ if (n === 200)
1917
1894
  return {
1918
- ...a[0].minting_tx_metadata[721][t][Yt(r)]
1895
+ ...a[0].minting_tx_metadata[721][t][qt(r)]
1919
1896
  };
1920
- throw l(a);
1897
+ throw d(a);
1921
1898
  } catch (t) {
1922
- throw l(t);
1899
+ throw d(t);
1923
1900
  }
1924
1901
  }
1925
1902
  async fetchBlockInfo(e) {
@@ -1943,9 +1920,9 @@ class Qr {
1943
1920
  txCount: t[0].tx_count,
1944
1921
  VRFKey: t[0].vrf_key
1945
1922
  };
1946
- throw l(t);
1923
+ throw d(t);
1947
1924
  } catch (t) {
1948
- throw l(t);
1925
+ throw d(t);
1949
1926
  }
1950
1927
  }
1951
1928
  async fetchCollectionAssets(e, t = 0) {
@@ -1953,25 +1930,25 @@ class Qr {
1953
1930
  const { data: r, status: a } = await this._axiosInstance.get(`asset_policy_info?_asset_policy=${e}&limit=100&offset=${t}`);
1954
1931
  if (a === 200)
1955
1932
  return {
1956
- assets: r.map((i) => ({
1957
- unit: `${e}${i.asset_name}`,
1958
- quantity: i.total_supply
1933
+ assets: r.map((n) => ({
1934
+ unit: `${e}${n.asset_name}`,
1935
+ quantity: n.total_supply
1959
1936
  })),
1960
1937
  next: r.length === 100 ? t + 100 : null
1961
1938
  };
1962
- throw l(r);
1939
+ throw d(r);
1963
1940
  } catch (r) {
1964
- throw l(r);
1941
+ throw d(r);
1965
1942
  }
1966
1943
  }
1967
1944
  async fetchHandleAddress(e) {
1968
1945
  try {
1969
- const t = S(e.replace("$", "")), { data: r, status: a } = await this._axiosInstance.get(`asset_address_list?_asset_policy=${Tt[1]}&_asset_name=${t}`);
1946
+ const t = S(e.replace("$", "")), { data: r, status: a } = await this._axiosInstance.get(`asset_address_list?_asset_policy=${Mt[1]}&_asset_name=${t}`);
1970
1947
  if (a === 200)
1971
1948
  return r[0].payment_address;
1972
- throw l(r);
1949
+ throw d(r);
1973
1950
  } catch (t) {
1974
- throw l(t);
1951
+ throw d(t);
1975
1952
  }
1976
1953
  }
1977
1954
  async fetchProtocolParameters(e) {
@@ -2000,16 +1977,16 @@ class Qr {
2000
1977
  priceMem: t[0].price_mem,
2001
1978
  priceStep: t[0].price_step
2002
1979
  };
2003
- throw l(t);
1980
+ throw d(t);
2004
1981
  } catch (t) {
2005
- throw l(t);
1982
+ throw d(t);
2006
1983
  }
2007
1984
  }
2008
1985
  async fetchTxInfo(e) {
2009
1986
  var t, r;
2010
1987
  try {
2011
- const { data: a, status: i } = await this._axiosInstance.post("tx_info", { _tx_hashes: [e] });
2012
- if (i === 200)
1988
+ const { data: a, status: n } = await this._axiosInstance.post("tx_info", { _tx_hashes: [e] });
1989
+ if (n === 200)
2013
1990
  return {
2014
1991
  block: a[0].block_hash,
2015
1992
  deposit: a[0].deposit,
@@ -2021,17 +1998,17 @@ class Qr {
2021
1998
  slot: a[0].absolute_slot.toString(),
2022
1999
  size: a[0].tx_size
2023
2000
  };
2024
- throw l(a);
2001
+ throw d(a);
2025
2002
  } catch (a) {
2026
- throw l(a);
2003
+ throw d(a);
2027
2004
  }
2028
2005
  }
2029
2006
  onTxConfirmed(e, t, r = 100) {
2030
2007
  let a = 0;
2031
- const i = setInterval(() => {
2032
- a >= r && clearInterval(i), this.fetchTxInfo(e).then((o) => {
2008
+ const n = setInterval(() => {
2009
+ a >= r && clearInterval(n), this.fetchTxInfo(e).then((o) => {
2033
2010
  this.fetchBlockInfo(o.block).then((c) => {
2034
- (c == null ? void 0 : c.confirmations) > 0 && (clearInterval(i), t());
2011
+ (c == null ? void 0 : c.confirmations) > 0 && (clearInterval(n), t());
2035
2012
  }).catch(() => {
2036
2013
  a += 1;
2037
2014
  });
@@ -2045,25 +2022,25 @@ class Qr {
2045
2022
  const t = { "Content-Type": "application/cbor" }, { data: r, status: a } = await this._axiosInstance.post("submittx", m(e), { headers: t });
2046
2023
  if (a === 202)
2047
2024
  return r;
2048
- throw l(r);
2025
+ throw d(r);
2049
2026
  } catch (t) {
2050
- throw l(t);
2027
+ throw d(t);
2051
2028
  }
2052
2029
  }
2053
2030
  }
2054
- class br {
2031
+ class xr {
2055
2032
  _baseUrl;
2056
2033
  constructor(...e) {
2057
- this._baseUrl = ts(e[0]) ? ns[e[0]] : e[0];
2034
+ this._baseUrl = ts(e[0]) ? rs[e[0]] : e[0];
2058
2035
  }
2059
2036
  async evaluateTx(e) {
2060
2037
  const t = await this.open();
2061
2038
  return this.send(t, "EvaluateTx", {
2062
2039
  evaluate: e
2063
2040
  }), new Promise((r, a) => {
2064
- t.addEventListener("message", (i) => {
2041
+ t.addEventListener("message", (n) => {
2065
2042
  try {
2066
- const { result: o } = JSON.parse(i.data);
2043
+ const { result: o } = JSON.parse(n.data);
2067
2044
  o.EvaluationResult ? r(Object.keys(o.EvaluationResult).map((c) => ({
2068
2045
  index: parseInt(c.split(":")[1], 10),
2069
2046
  tag: c.split(":")[0].toUpperCase(),
@@ -2092,9 +2069,9 @@ class br {
2092
2069
  return this.send(t, "SubmitTx", {
2093
2070
  submit: e
2094
2071
  }), new Promise((r, a) => {
2095
- t.addEventListener("message", (i) => {
2072
+ t.addEventListener("message", (n) => {
2096
2073
  try {
2097
- const { result: o } = JSON.parse(i.data);
2074
+ const { result: o } = JSON.parse(n.data);
2098
2075
  o.SubmitSuccess ? r(o.SubmitSuccess.txId) : a(o.SubmitFail), t.close();
2099
2076
  } catch (o) {
2100
2077
  a(o);
@@ -2118,10 +2095,10 @@ class br {
2118
2095
  }));
2119
2096
  }
2120
2097
  }
2121
- class Dr {
2098
+ class Er {
2122
2099
  _axiosInstance;
2123
2100
  constructor(e, t, r, a = 1) {
2124
- this._axiosInstance = j.create({
2101
+ this._axiosInstance = L.create({
2125
2102
  baseURL: `https://cardano-${e}.tangocrypto.com/${t}/v${a}`,
2126
2103
  headers: { "x-api-key": r }
2127
2104
  });
@@ -2138,14 +2115,14 @@ class Dr {
2138
2115
  steps: a.unit_steps
2139
2116
  }
2140
2117
  }));
2141
- throw l(t);
2118
+ throw d(t);
2142
2119
  } catch (t) {
2143
- throw l(t);
2120
+ throw d(t);
2144
2121
  }
2145
2122
  }
2146
2123
  async fetchAccountInfo(e) {
2147
2124
  try {
2148
- const t = e.startsWith("addr") ? qt(e) : e, { data: r, status: a } = await this._axiosInstance.get(`wallets/${t}`);
2125
+ const t = e.startsWith("addr") ? kt(e) : e, { data: r, status: a } = await this._axiosInstance.get(`wallets/${t}`);
2149
2126
  if (a === 200)
2150
2127
  return {
2151
2128
  poolId: r.pool_id,
@@ -2154,40 +2131,40 @@ class Dr {
2154
2131
  rewards: r.rewards_sum,
2155
2132
  withdrawals: r.withdrawals_sum
2156
2133
  };
2157
- throw l(r);
2134
+ throw d(r);
2158
2135
  } catch (t) {
2159
- throw l(t);
2136
+ throw d(t);
2160
2137
  }
2161
2138
  }
2162
2139
  async fetchAddressUTxOs(e, t) {
2163
- const r = t !== void 0 ? `/assets/${t}` : "", a = `addresses/${e}${r}/utxos?size=50`, i = async (A = "", d = []) => {
2164
- var _;
2140
+ const r = t !== void 0 ? `/assets/${t}` : "", a = `addresses/${e}${r}/utxos?size=50`, n = async (A = "", l = []) => {
2141
+ var f;
2165
2142
  const { data: g, status: I } = await this._axiosInstance.get(`${a}&cursor=${A}`);
2166
2143
  if (I === 200)
2167
- return g.cursor !== null && ((_ = g.cursor) == null ? void 0 : _.length) > 0 ? i(g.cursor, [...d, ...g.data.map(u)]) : g.data.map(u);
2168
- throw l(g);
2169
- }, o = (A, d) => {
2144
+ return g.cursor !== null && ((f = g.cursor) == null ? void 0 : f.length) > 0 ? n(g.cursor, [...l, ...g.data.map(u)]) : g.data.map(u);
2145
+ throw d(g);
2146
+ }, o = (A, l) => {
2170
2147
  const g = [{
2171
2148
  unit: "lovelace",
2172
2149
  quantity: A.toString()
2173
2150
  }];
2174
- return d.forEach((I) => {
2175
- const _ = S(I.asset_name);
2151
+ return l.forEach((I) => {
2152
+ const f = S(I.asset_name);
2176
2153
  g.push({
2177
- unit: `${I.policy_id}${_}`,
2154
+ unit: `${I.policy_id}${f}`,
2178
2155
  quantity: I.quantity.toString()
2179
2156
  });
2180
2157
  }), g;
2181
2158
  }, c = (A) => {
2182
2159
  if (A) {
2183
- const d = A.type.startsWith("plutus") ? {
2160
+ const l = A.type.startsWith("plutus") ? {
2184
2161
  code: A.code,
2185
2162
  version: A.type.replace("plutus", "")
2186
2163
  } : Dt(bt(A.json));
2187
- return lt(d).to_hex();
2164
+ return ct(l).to_hex();
2188
2165
  }
2189
2166
  }, u = (A) => {
2190
- var d;
2167
+ var l;
2191
2168
  return {
2192
2169
  input: {
2193
2170
  outputIndex: A.index,
@@ -2197,13 +2174,13 @@ class Dr {
2197
2174
  address: e,
2198
2175
  amount: o(A.value, A.assets),
2199
2176
  dataHash: void 0,
2200
- plutusData: ((d = A.inline_datum) == null ? void 0 : d.value_raw) ?? void 0,
2177
+ plutusData: ((l = A.inline_datum) == null ? void 0 : l.value_raw) ?? void 0,
2201
2178
  scriptRef: c(A.reference_script)
2202
2179
  }
2203
2180
  };
2204
2181
  };
2205
2182
  try {
2206
- return await i();
2183
+ return await n();
2207
2184
  } catch {
2208
2185
  return [];
2209
2186
  }
@@ -2212,12 +2189,12 @@ class Dr {
2212
2189
  const t = (a) => ({
2213
2190
  address: a.address,
2214
2191
  quantity: a.quantity.toString()
2215
- }), r = async (a = "", i = []) => {
2216
- var d;
2217
- const { policyId: o, assetName: c } = ot(e), { data: u, status: A } = await this._axiosInstance.get(`assets/${o}${c}/addresses?size=100&cursor=${a}`);
2192
+ }), r = async (a = "", n = []) => {
2193
+ var l;
2194
+ const { policyId: o, assetName: c } = X(e), { data: u, status: A } = await this._axiosInstance.get(`assets/${o}${c}/addresses?size=100&cursor=${a}`);
2218
2195
  if (A === 200)
2219
- return u.cursor !== null && ((d = u.cursor) == null ? void 0 : d.length) > 0 ? r(u.cursor, [...i, ...u.data.map(t)]) : u.data.map(t);
2220
- throw l(u);
2196
+ return u.cursor !== null && ((l = u.cursor) == null ? void 0 : l.length) > 0 ? r(u.cursor, [...n, ...u.data.map(t)]) : u.data.map(t);
2197
+ throw d(u);
2221
2198
  };
2222
2199
  try {
2223
2200
  return await r();
@@ -2228,14 +2205,14 @@ class Dr {
2228
2205
  async fetchAssetMetadata(e) {
2229
2206
  var t;
2230
2207
  try {
2231
- const { policyId: r, assetName: a } = ot(e), { data: i, status: o } = await this._axiosInstance.get(`assets/${r}${a}`);
2208
+ const { policyId: r, assetName: a } = X(e), { data: n, status: o } = await this._axiosInstance.get(`assets/${r}${a}`);
2232
2209
  if (o === 200)
2233
2210
  return {
2234
- ...(t = i.metadata.find((c) => c.label === 721)) == null ? void 0 : t.json[r][Yt(a)]
2211
+ ...(t = n.metadata.find((c) => c.label === 721)) == null ? void 0 : t.json[r][qt(a)]
2235
2212
  };
2236
- throw l(i);
2213
+ throw d(n);
2237
2214
  } catch (r) {
2238
- throw l(r);
2215
+ throw d(r);
2239
2216
  }
2240
2217
  }
2241
2218
  async fetchBlockInfo(e) {
@@ -2259,9 +2236,9 @@ class Dr {
2259
2236
  txCount: t.tx_count,
2260
2237
  VRFKey: t.vrf_key
2261
2238
  };
2262
- throw l(t);
2239
+ throw d(t);
2263
2240
  } catch (t) {
2264
- throw l(t);
2241
+ throw d(t);
2265
2242
  }
2266
2243
  }
2267
2244
  async fetchCollectionAssets(e, t = "") {
@@ -2269,25 +2246,25 @@ class Dr {
2269
2246
  const { data: r, status: a } = await this._axiosInstance.get(`policies/${e}/assets?size=100&cursor=${t}`);
2270
2247
  if (a === 200)
2271
2248
  return {
2272
- assets: r.data.map((i) => ({
2273
- unit: `${i.policy_id}${i.asset_name}`,
2274
- quantity: i.quantity
2249
+ assets: r.data.map((n) => ({
2250
+ unit: `${n.policy_id}${n.asset_name}`,
2251
+ quantity: n.quantity
2275
2252
  })),
2276
2253
  next: r.cursor
2277
2254
  };
2278
- throw l(r);
2255
+ throw d(r);
2279
2256
  } catch {
2280
2257
  return { assets: [], next: null };
2281
2258
  }
2282
2259
  }
2283
2260
  async fetchHandleAddress(e) {
2284
2261
  try {
2285
- const t = S(e.replace("$", "")), { data: r, status: a } = await this._axiosInstance.get(`assets/${Tt[1]}${t}/addresses`);
2262
+ const t = S(e.replace("$", "")), { data: r, status: a } = await this._axiosInstance.get(`assets/${Mt[1]}${t}/addresses`);
2286
2263
  if (a === 200)
2287
2264
  return r.data[0].address;
2288
- throw l(r);
2265
+ throw d(r);
2289
2266
  } catch (t) {
2290
- throw l(t);
2267
+ throw d(t);
2291
2268
  }
2292
2269
  }
2293
2270
  async fetchProtocolParameters(e) {
@@ -2316,9 +2293,9 @@ class Dr {
2316
2293
  priceMem: t.price_mem,
2317
2294
  priceStep: t.price_step
2318
2295
  };
2319
- throw l(t);
2296
+ throw d(t);
2320
2297
  } catch (t) {
2321
- throw l(t);
2298
+ throw d(t);
2322
2299
  }
2323
2300
  }
2324
2301
  async fetchTxInfo(e) {
@@ -2336,17 +2313,17 @@ class Dr {
2336
2313
  slot: t.block.slot_no.toString(),
2337
2314
  size: t.size
2338
2315
  };
2339
- throw l(t);
2316
+ throw d(t);
2340
2317
  } catch (t) {
2341
- throw l(t);
2318
+ throw d(t);
2342
2319
  }
2343
2320
  }
2344
2321
  onTxConfirmed(e, t, r = 100) {
2345
2322
  let a = 0;
2346
- const i = setInterval(() => {
2347
- a >= r && clearInterval(i), this.fetchTxInfo(e).then((o) => {
2323
+ const n = setInterval(() => {
2324
+ a >= r && clearInterval(n), this.fetchTxInfo(e).then((o) => {
2348
2325
  this.fetchBlockInfo(o.block).then((c) => {
2349
- (c == null ? void 0 : c.confirmations) > 0 && (clearInterval(i), t());
2326
+ (c == null ? void 0 : c.confirmations) > 0 && (clearInterval(n), t());
2350
2327
  }).catch(() => {
2351
2328
  a += 1;
2352
2329
  });
@@ -2360,67 +2337,317 @@ class Dr {
2360
2337
  const t = { "Content-Type": "application/json" }, { data: r, status: a } = await this._axiosInstance.post("transactions/submit", { tx: e }, { headers: t });
2361
2338
  if (a === 200)
2362
2339
  return r.tx_id;
2363
- throw l(r);
2340
+ throw d(r);
2364
2341
  } catch (t) {
2365
- throw l(t);
2342
+ throw d(t);
2366
2343
  }
2367
2344
  }
2368
2345
  }
2369
- class vr {
2346
+ class Sr {
2347
+ _axiosInstance;
2348
+ submitUrl;
2349
+ constructor({ network: e, apiKey: t, turboSubmit: r = !1 }) {
2350
+ this._axiosInstance = L.create({
2351
+ baseURL: `https://${e}.gomaestro-api.org/v1`,
2352
+ headers: { "api-key": t }
2353
+ }), this.submitUrl = r ? "txmanager" : "txmanager/turbosubmit";
2354
+ }
2355
+ async fetchAccountInfo(e) {
2356
+ const t = e.startsWith("addr") ? kt(e) : e;
2357
+ try {
2358
+ const { data: r, status: a } = await this._axiosInstance.get(`accounts/${t}`);
2359
+ if (a === 200) {
2360
+ const n = r.data;
2361
+ return {
2362
+ poolId: n.delegated_pool,
2363
+ active: n.registered,
2364
+ balance: n.total_balance.toString(),
2365
+ rewards: n.rewards_available.toString(),
2366
+ withdrawals: n.total_withdrawn.toString()
2367
+ };
2368
+ }
2369
+ throw d(r);
2370
+ } catch (r) {
2371
+ throw d(r);
2372
+ }
2373
+ }
2374
+ async fetchAddressUTxOs(e, t) {
2375
+ const r = (() => e.startsWith("addr_vkh") || e.startsWith("addr_shared_vkh") ? `addresses/cred/${e}` : `addresses/${e}`)(), a = t ? `&asset=${t}` : "", n = (u) => {
2376
+ if (u.reference_script) {
2377
+ const A = u.reference_script.type === "native" ? u.reference_script.json : {
2378
+ code: u.reference_script.bytes,
2379
+ version: u.reference_script.type.replace("plutusv", "V")
2380
+ };
2381
+ return ct(A).to_hex();
2382
+ } else
2383
+ return;
2384
+ }, o = async (u = null, A = []) => {
2385
+ const l = u === null ? "" : `&cursor=${u}`, { data: g, status: I } = await this._axiosInstance.get(`${r}/utxos?count=100${a}${l}`);
2386
+ if (I === 200) {
2387
+ const y = g.data.map(c), b = [...A, ...y], k = g.next_cursor;
2388
+ return k == null ? b : o(k, b);
2389
+ }
2390
+ throw d(g);
2391
+ }, c = (u) => {
2392
+ var A, l;
2393
+ return {
2394
+ input: {
2395
+ outputIndex: u.index,
2396
+ txHash: u.tx_hash
2397
+ },
2398
+ output: {
2399
+ address: e,
2400
+ amount: u.assets.map((g) => ({
2401
+ unit: g.unit,
2402
+ quantity: g.amount.toString()
2403
+ })),
2404
+ dataHash: (A = u.datum) == null ? void 0 : A.hash,
2405
+ plutusData: (l = u.datum) == null ? void 0 : l.bytes,
2406
+ scriptRef: n(u)
2407
+ }
2408
+ };
2409
+ };
2410
+ try {
2411
+ return await o();
2412
+ } catch {
2413
+ return [];
2414
+ }
2415
+ }
2416
+ async fetchAssetAddresses(e) {
2417
+ const { policyId: t, assetName: r } = X(e), a = async (n = null, o = []) => {
2418
+ const c = n === null ? "" : `&cursor=${n}`, { data: u, status: A } = await this._axiosInstance.get(`assets/${t}${r}/addresses?count=100${c}`);
2419
+ if (A === 200) {
2420
+ const g = u.data.map((y) => ({ address: y.address, quantity: y.amount.toString() })), I = u.next_cursor, f = [...o, ...g];
2421
+ return I == null ? f : a(I, f);
2422
+ }
2423
+ throw d(u);
2424
+ };
2425
+ try {
2426
+ return await a();
2427
+ } catch {
2428
+ return [];
2429
+ }
2430
+ }
2431
+ async fetchAssetMetadata(e) {
2432
+ try {
2433
+ const { policyId: t, assetName: r } = X(e), { data: a, status: n } = await this._axiosInstance.get(`assets/${t}${r}`);
2434
+ if (n === 200) {
2435
+ const o = a.data;
2436
+ return {
2437
+ ...o.asset_standards.cip25_metadata,
2438
+ ...o.asset_standards.cip68_metadata
2439
+ };
2440
+ }
2441
+ throw d(a);
2442
+ } catch (t) {
2443
+ throw d(t);
2444
+ }
2445
+ }
2446
+ async fetchBlockInfo(e) {
2447
+ var t;
2448
+ try {
2449
+ const { data: r, status: a } = await this._axiosInstance.get(`blocks/${e}`);
2450
+ if (a === 200) {
2451
+ const n = r.data;
2452
+ return {
2453
+ confirmations: n.confirmations,
2454
+ epoch: n.epoch,
2455
+ epochSlot: n.epoch_slot.toString(),
2456
+ fees: n.total_fees.toString(),
2457
+ hash: n.hash,
2458
+ nextBlock: n.next_block ?? "",
2459
+ operationalCertificate: (t = n.operational_certificate) == null ? void 0 : t.hot_vkey,
2460
+ output: n.total_output_lovelace ?? "0",
2461
+ previousBlock: n.previous_block,
2462
+ size: n.size,
2463
+ slot: n.absolute_slot.toString(),
2464
+ slotLeader: n.block_producer ?? "",
2465
+ time: Date.parse(n.timestamp) / 1e3,
2466
+ txCount: n.tx_hashes.length,
2467
+ VRFKey: i.VRFVKey.from_hex(n.vrf_key).to_bech32("vrf_vk")
2468
+ };
2469
+ }
2470
+ throw d(r);
2471
+ } catch (r) {
2472
+ throw d(r);
2473
+ }
2474
+ }
2475
+ async fetchCollectionAssets(e, t) {
2476
+ try {
2477
+ const { data: r, status: a } = await this._axiosInstance.get(`assets/policy/${e}?count=100${t ? `&cursor=${t}` : ""}`);
2478
+ if (console.log(r), a === 200)
2479
+ return {
2480
+ assets: r.data.map((o) => ({
2481
+ unit: e + o.asset_name,
2482
+ quantity: o.total_supply.toString()
2483
+ })),
2484
+ next: r.next_cursor
2485
+ };
2486
+ throw d(r);
2487
+ } catch {
2488
+ return { assets: [], next: null };
2489
+ }
2490
+ }
2491
+ async fetchHandleAddress(e) {
2492
+ try {
2493
+ const t = e.charAt(0) === "$" ? e.substring(1) : e, { data: r, status: a } = await this._axiosInstance.get(`ecosystem/adahandle/${t}`);
2494
+ if (a === 200)
2495
+ return r.data;
2496
+ throw d(r);
2497
+ } catch (t) {
2498
+ throw d(t);
2499
+ }
2500
+ }
2501
+ async fetchProtocolParameters(e = Number.NaN) {
2502
+ if (!isNaN(e))
2503
+ throw new Error("Maestro only supports fetching Protocol parameters of the latest completed epoch.");
2504
+ const t = (r) => {
2505
+ const a = r.indexOf("/");
2506
+ return parseInt(r.slice(0, a)) / parseInt(r.slice(a + 1));
2507
+ };
2508
+ try {
2509
+ const { data: r, status: a } = await this._axiosInstance.get("protocol-params");
2510
+ if (a === 200) {
2511
+ const n = r.data;
2512
+ try {
2513
+ const { data: o, status: c } = await this._axiosInstance.get("epochs/current");
2514
+ if (c === 200) {
2515
+ const u = o.data;
2516
+ return {
2517
+ coinsPerUTxOSize: n.coins_per_utxo_byte.toString(),
2518
+ collateralPercent: parseInt(n.collateral_percentage),
2519
+ decentralisation: 0,
2520
+ epoch: parseInt(u.epoch_no),
2521
+ keyDeposit: n.stake_key_deposit.toString(),
2522
+ maxBlockExMem: n.max_execution_units_per_block.memory.toString(),
2523
+ maxBlockExSteps: n.max_execution_units_per_block.steps.toString(),
2524
+ maxBlockHeaderSize: parseInt(n.max_block_header_size),
2525
+ maxBlockSize: parseInt(n.max_block_body_size),
2526
+ maxCollateralInputs: parseInt(n.max_collateral_inputs),
2527
+ maxTxExMem: n.max_execution_units_per_transaction.memory.toString(),
2528
+ maxTxExSteps: n.max_execution_units_per_transaction.steps.toString(),
2529
+ maxTxSize: parseInt(n.max_tx_size),
2530
+ maxValSize: n.max_value_size.toString(),
2531
+ minFeeA: n.min_fee_coefficient,
2532
+ minFeeB: n.min_fee_constant,
2533
+ minPoolCost: n.min_pool_cost.toString(),
2534
+ poolDeposit: n.pool_deposit.toString(),
2535
+ priceMem: t(n.prices.memory),
2536
+ priceStep: t(n.prices.steps)
2537
+ };
2538
+ }
2539
+ throw d(o);
2540
+ } catch (o) {
2541
+ throw d(o);
2542
+ }
2543
+ }
2544
+ throw d(r);
2545
+ } catch (r) {
2546
+ throw d(r);
2547
+ }
2548
+ }
2549
+ async fetchTxInfo(e) {
2550
+ try {
2551
+ const { data: t, status: r } = await this._axiosInstance.get(`transactions/${e}`);
2552
+ if (r === 200) {
2553
+ const a = t.data;
2554
+ return {
2555
+ block: a.block_hash,
2556
+ deposit: a.deposit.toString(),
2557
+ fees: a.fee.toString(),
2558
+ hash: a.tx_hash,
2559
+ index: a.block_tx_index,
2560
+ invalidAfter: a.invalid_hereafter ?? "",
2561
+ invalidBefore: a.invalid_before ?? "",
2562
+ slot: a.block_absolute_slot.toString(),
2563
+ size: a.size - 1
2564
+ };
2565
+ }
2566
+ throw d(t);
2567
+ } catch (t) {
2568
+ throw d(t);
2569
+ }
2570
+ }
2571
+ onTxConfirmed(e, t, r = 100) {
2572
+ let a = 0;
2573
+ const n = setInterval(() => {
2574
+ a >= r && clearInterval(n), this.fetchTxInfo(e).then((o) => {
2575
+ this.fetchBlockInfo(o.block).then((c) => {
2576
+ (c == null ? void 0 : c.confirmations) > 0 && (clearInterval(n), t());
2577
+ }).catch(() => {
2578
+ a += 1;
2579
+ });
2580
+ }).catch(() => {
2581
+ a += 1;
2582
+ });
2583
+ }, 5e3);
2584
+ }
2585
+ async submitTx(e) {
2586
+ try {
2587
+ const t = { "Content-Type": "application/cbor" }, { data: r, status: a } = await this._axiosInstance.post(this.submitUrl, m(e), { headers: t });
2588
+ if (a === 202)
2589
+ return r;
2590
+ throw d(r);
2591
+ } catch (t) {
2592
+ throw d(t);
2593
+ }
2594
+ }
2595
+ }
2596
+ class Qr {
2370
2597
  static withOneSignature(e) {
2371
- const t = P(st(e));
2372
- return pt(t).to_hex();
2598
+ const t = T(rt(e));
2599
+ return ft(t).to_hex();
2373
2600
  }
2374
2601
  static withAtLeastNSignatures(e, t) {
2375
- const r = n.NativeScripts.new();
2376
- e.forEach((i) => {
2377
- const o = P(st(i));
2378
- r.add(pt(o));
2602
+ const r = i.NativeScripts.new();
2603
+ e.forEach((n) => {
2604
+ const o = T(rt(n));
2605
+ r.add(ft(o));
2379
2606
  });
2380
- const a = n.ScriptNOfK.new(t, r);
2381
- return n.NativeScript.new_script_any(a).to_hex();
2607
+ const a = i.ScriptNOfK.new(t, r);
2608
+ return i.NativeScript.new_script_any(a).to_hex();
2382
2609
  }
2383
2610
  static withAnySignature(e) {
2384
- const t = n.NativeScripts.new();
2611
+ const t = i.NativeScripts.new();
2385
2612
  e.forEach((a) => {
2386
- const i = P(st(a));
2387
- t.add(pt(i));
2613
+ const n = T(rt(a));
2614
+ t.add(ft(n));
2388
2615
  });
2389
- const r = n.ScriptAny.new(t);
2390
- return n.NativeScript.new_script_any(r).to_hex();
2616
+ const r = i.ScriptAny.new(t);
2617
+ return i.NativeScript.new_script_any(r).to_hex();
2391
2618
  }
2392
2619
  static withAllSignatures(e) {
2393
- const t = n.NativeScripts.new();
2620
+ const t = i.NativeScripts.new();
2394
2621
  e.forEach((a) => {
2395
- const i = P(st(a));
2396
- t.add(pt(i));
2622
+ const n = T(rt(a));
2623
+ t.add(ft(n));
2397
2624
  });
2398
- const r = n.ScriptAll.new(t);
2399
- return n.NativeScript.new_script_any(r).to_hex();
2625
+ const r = i.ScriptAll.new(t);
2626
+ return i.NativeScript.new_script_any(r).to_hex();
2400
2627
  }
2401
2628
  static fromNativeScript(e) {
2402
2629
  return vt(e).to_hex();
2403
2630
  }
2404
2631
  }
2405
- function X(s, e, t, r) {
2406
- var a = arguments.length, i = a < 3 ? e : r === null ? r = Object.getOwnPropertyDescriptor(e, t) : r, o;
2632
+ function Z(s, e, t, r) {
2633
+ var a = arguments.length, n = a < 3 ? e : r === null ? r = Object.getOwnPropertyDescriptor(e, t) : r, o;
2407
2634
  if (typeof Reflect == "object" && typeof Reflect.decorate == "function")
2408
- i = Reflect.decorate(s, e, t, r);
2635
+ n = Reflect.decorate(s, e, t, r);
2409
2636
  else
2410
2637
  for (var c = s.length - 1; c >= 0; c--)
2411
- (o = s[c]) && (i = (a < 3 ? o(i) : a > 3 ? o(e, t, i) : o(e, t)) || i);
2412
- return a > 3 && i && Object.defineProperty(e, t, i), i;
2638
+ (o = s[c]) && (n = (a < 3 ? o(n) : a > 3 ? o(e, t, n) : o(e, t)) || n);
2639
+ return a > 3 && n && Object.defineProperty(e, t, n), n;
2413
2640
  }
2414
- const rr = (s) => class extends s {
2641
+ const Xs = (s) => class extends s {
2415
2642
  __visits = [];
2416
- }, tt = () => function(s, e, t) {
2643
+ }, et = () => function(s, e, t) {
2417
2644
  const r = t.value;
2418
2645
  t.value = function(...a) {
2419
- const i = r.call(this, ...a);
2420
- return this.__visits && this.__visits.push(e), i;
2646
+ const n = r.call(this, ...a);
2647
+ return this.__visits && this.__visits.push(e), n;
2421
2648
  };
2422
2649
  };
2423
- let L = class {
2650
+ let $ = class {
2424
2651
  _changeAddress;
2425
2652
  _txOutputs = /* @__PURE__ */ new Map();
2426
2653
  _recipients = /* @__PURE__ */ new Map();
@@ -2435,29 +2662,29 @@ let L = class {
2435
2662
  _txInputsBuilder;
2436
2663
  _txWithdrawals;
2437
2664
  constructor(e = {}) {
2438
- this._era = e.era, this._initiator = e.initiator, this._mintBuilder = n.MintBuilder.new(), this._protocolParameters = e.parameters ?? q, this._txBuilder = tr(e.parameters), this._txCertificates = n.Certificates.new(), this._txInputsBuilder = n.TxInputsBuilder.new(), this._txWithdrawals = n.Withdrawals.new();
2665
+ this._era = e.era, this._initiator = e.initiator, this._mintBuilder = i.MintBuilder.new(), this._protocolParameters = e.parameters ?? G, this._txBuilder = Ws(e.parameters), this._txCertificates = i.Certificates.new(), this._txInputsBuilder = i.TxInputsBuilder.new(), this._txWithdrawals = i.Withdrawals.new();
2439
2666
  }
2440
2667
  static maskMetadata(e, t = "BABBAGE") {
2441
- var i;
2442
- const r = Y(e), a = (i = r.auxiliary_data()) == null ? void 0 : i.metadata();
2668
+ var n;
2669
+ const r = q(e), a = (n = r.auxiliary_data()) == null ? void 0 : n.metadata();
2443
2670
  if (a !== void 0) {
2444
- const o = n.GeneralTransactionMetadata.new();
2671
+ const o = i.GeneralTransactionMetadata.new();
2445
2672
  for (let u = 0; u < a.len(); u += 1) {
2446
- const A = a.keys().get(u), d = a.get(A);
2447
- o.insert(A, n.TransactionMetadatum.from_hex("0".repeat(((d == null ? void 0 : d.to_hex()) ?? "").length)));
2673
+ const A = a.keys().get(u), l = a.get(A);
2674
+ o.insert(A, i.TransactionMetadatum.from_hex("0".repeat(((l == null ? void 0 : l.to_hex()) ?? "").length)));
2448
2675
  }
2449
2676
  const c = r.auxiliary_data();
2450
- return c !== void 0 && (c.set_metadata(o), c.set_prefer_alonzo_format(t === "ALONZO")), n.Transaction.new(r.body(), r.witness_set(), c).to_hex();
2677
+ return c !== void 0 && (c.set_metadata(o), c.set_prefer_alonzo_format(t === "ALONZO")), i.Transaction.new(r.body(), r.witness_set(), c).to_hex();
2451
2678
  }
2452
2679
  return e;
2453
2680
  }
2454
2681
  static readMetadata(e) {
2455
2682
  var r, a;
2456
- return ((a = (r = Y(e).auxiliary_data()) == null ? void 0 : r.metadata()) == null ? void 0 : a.to_hex()) ?? "";
2683
+ return ((a = (r = q(e).auxiliary_data()) == null ? void 0 : r.metadata()) == null ? void 0 : a.to_hex()) ?? "";
2457
2684
  }
2458
2685
  static writeMetadata(e, t, r = "BABBAGE") {
2459
- const a = Y(e), i = a.auxiliary_data() ?? n.AuxiliaryData.new();
2460
- return i.set_metadata(n.GeneralTransactionMetadata.from_hex(t)), i.set_prefer_alonzo_format(r === "ALONZO"), n.Transaction.new(a.body(), a.witness_set(), i).to_hex();
2686
+ const a = q(e), n = a.auxiliary_data() ?? i.AuxiliaryData.new();
2687
+ return n.set_metadata(i.GeneralTransactionMetadata.from_hex(t)), n.set_prefer_alonzo_format(r === "ALONZO"), i.Transaction.new(a.body(), a.witness_set(), n).to_hex();
2461
2688
  }
2462
2689
  get size() {
2463
2690
  return this._txBuilder.full_size();
@@ -2470,39 +2697,39 @@ let L = class {
2470
2697
  }
2471
2698
  }
2472
2699
  burnAsset(e, t, r) {
2473
- const a = this._totalBurns.has(t.unit) ? n.BigNum.from_str(this._totalBurns.get(t.unit) ?? "0").checked_add(n.BigNum.from_str(t.quantity)).to_str() : t.quantity;
2474
- return this._mintBuilder.add_asset(fe(e, r), n.AssetName.new(m(t.unit.slice(F))), n.Int.new_negative(n.BigNum.from_str(t.quantity))), this._totalBurns.set(t.unit, a), this;
2700
+ const a = this._totalBurns.has(t.unit) ? i.BigNum.from_str(this._totalBurns.get(t.unit) ?? "0").checked_add(i.BigNum.from_str(t.quantity)).to_str() : t.quantity;
2701
+ return this._mintBuilder.add_asset(fe(e, r), i.AssetName.new(m(t.unit.slice(M))), i.Int.new_negative(i.BigNum.from_str(t.quantity))), this._totalBurns.set(t.unit, a), this;
2475
2702
  }
2476
2703
  delegateStake(e, t) {
2477
- const r = n.Certificate.new_stake_delegation(n.StakeDelegation.new(n.StakeCredential.from_keyhash(P(At(e))), n.Ed25519KeyHash.from_bech32(t)));
2704
+ const r = i.Certificate.new_stake_delegation(i.StakeDelegation.new(i.StakeCredential.from_keyhash(T(dt(e))), i.Ed25519KeyHash.from_bech32(t)));
2478
2705
  return this._txCertificates.add(r), this;
2479
2706
  }
2480
2707
  deregisterStake(e) {
2481
- const t = n.Certificate.new_stake_deregistration(n.StakeDeregistration.new(n.StakeCredential.from_keyhash(P(At(e)))));
2708
+ const t = i.Certificate.new_stake_deregistration(i.StakeDeregistration.new(i.StakeCredential.from_keyhash(T(dt(e)))));
2482
2709
  return this._txCertificates.add(t), this;
2483
2710
  }
2484
2711
  mintAsset(e, t, r) {
2485
- var A, d;
2712
+ var A, l;
2486
2713
  const a = (g, I) => {
2487
- const _ = typeof g == "string" ? bt(g).hash().to_hex() : i(g).hash().to_hex(), x = S(I.assetName);
2714
+ const f = typeof g == "string" ? bt(g).hash().to_hex() : n(g).hash().to_hex(), y = S(I.assetName);
2488
2715
  return {
2489
- unit: `${_}${x}`,
2716
+ unit: `${f}${y}`,
2490
2717
  quantity: I.assetQuantity
2491
2718
  };
2492
- }, i = (g) => {
2719
+ }, n = (g) => {
2493
2720
  if ("code" in g)
2494
- return it(g.code, g.version);
2495
- const I = N(g);
2721
+ return ot(g.code, g.version);
2722
+ const I = F(g);
2496
2723
  if (I.output().has_script_ref()) {
2497
- const _ = I.output().script_ref();
2498
- if (_.is_plutus_script()) {
2499
- const x = Oe(_);
2500
- return it(x.code, x.version);
2724
+ const f = I.output().script_ref();
2725
+ if (f.is_plutus_script()) {
2726
+ const y = Oe(f);
2727
+ return ot(y.code, y.version);
2501
2728
  }
2502
2729
  }
2503
2730
  throw new Error(`No plutus script reference found in UTxO: ${I.input().transaction_id().to_hex()}`);
2504
- }, o = a(e, t), u = n.BigNum.from_str(((A = this._totalMints.get(o.unit)) == null ? void 0 : A.assetQuantity) ?? "0").checked_add(n.BigNum.from_str(o.quantity));
2505
- return this._mintBuilder.add_asset(fe(e, r), n.AssetName.new(m(S(t.assetName))), n.Int.new(n.BigNum.from_str(o.quantity))), this._recipients.has(t.recipient) ? (d = this._recipients.get(t.recipient)) == null || d.push(o) : this._recipients.set(t.recipient, [o]), this._totalMints.set(o.unit, {
2731
+ }, o = a(e, t), u = i.BigNum.from_str(((A = this._totalMints.get(o.unit)) == null ? void 0 : A.assetQuantity) ?? "0").checked_add(i.BigNum.from_str(o.quantity));
2732
+ return this._mintBuilder.add_asset(fe(e, r), i.AssetName.new(m(S(t.assetName))), i.Int.new(i.BigNum.from_str(o.quantity))), this._recipients.has(t.recipient) ? (l = this._recipients.get(t.recipient)) == null || l.push(o) : this._recipients.set(t.recipient, [o]), this._totalMints.set(o.unit, {
2506
2733
  ...t,
2507
2734
  assetQuantity: u.to_str()
2508
2735
  }), this;
@@ -2510,178 +2737,95 @@ let L = class {
2510
2737
  redeemValue(e) {
2511
2738
  const t = {
2512
2739
  tag: "SPEND",
2513
- budget: Ee,
2740
+ budget: xe,
2514
2741
  index: this._txInputsBuilder.inputs().len(),
2515
2742
  data: {
2516
2743
  alternative: 0,
2517
2744
  fields: []
2518
2745
  },
2519
2746
  ...e.redeemer
2520
- }, r = N(e.value), a = n.PlutusWitness.new_with_ref(qe(e.script), Zs(e.datum), He(t));
2747
+ }, r = F(e.value), a = i.PlutusWitness.new_with_ref(qe(e.script), zs(e.datum), He(t));
2521
2748
  return this._txInputsBuilder.add_plutus_script_input(a, r.input(), r.output().amount()), this;
2522
2749
  }
2523
2750
  registerStake(e) {
2524
- const t = n.Certificate.new_stake_registration(n.StakeRegistration.new(n.StakeCredential.from_keyhash(P(At(e)))));
2751
+ const t = i.Certificate.new_stake_registration(i.StakeRegistration.new(i.StakeCredential.from_keyhash(T(dt(e)))));
2525
2752
  return this._txCertificates.add(t), this;
2526
2753
  }
2527
2754
  registerPool(e) {
2528
- const t = n.Certificate.new_pool_registration(n.PoolRegistration.new(js(e)));
2755
+ const t = i.Certificate.new_pool_registration(i.PoolRegistration.new(Rs(e)));
2529
2756
  return this._txCertificates.add(t), this;
2530
2757
  }
2531
2758
  retirePool(e, t) {
2532
- const r = n.Certificate.new_pool_retirement(n.PoolRetirement.new(n.Ed25519KeyHash.from_bech32(e), t));
2759
+ const r = i.Certificate.new_pool_retirement(i.PoolRetirement.new(i.Ed25519KeyHash.from_bech32(e), t));
2533
2760
  return this._txCertificates.add(r), this;
2534
2761
  }
2535
- /**
2536
- * Adds an output to the transaction.
2537
- *
2538
- * @param recipient The recipient of the output.
2539
- * @param assets The assets to send.
2540
- * @returns The transaction builder.
2541
- * @see {@link https://meshjs.dev/apis/transaction#sendAssets}
2542
- */
2543
2762
  sendAssets(e, t) {
2544
2763
  const r = Bt(t), a = r.multiasset();
2545
2764
  if (r.is_zero() || a === void 0)
2546
2765
  return this;
2547
- const i = ft(e).next(), o = r.coin().is_zero() ? i.with_asset_and_min_required_coin_by_utxo_cost(a, me(this._protocolParameters.coinsPerUTxOSize)).build() : i.with_coin_and_asset(r.coin(), a).build();
2766
+ const n = _t(e).next(), o = r.coin().is_zero() ? n.with_asset_and_min_required_coin_by_utxo_cost(a, me(this._protocolParameters.coinsPerUTxOSize)).build() : n.with_coin_and_asset(r.coin(), a).build();
2548
2767
  return t.forEach((c) => {
2549
2768
  this.setTxOutput(c);
2550
2769
  }), this._txBuilder.add_output(o), this;
2551
2770
  }
2552
- /**
2553
- * Adds a transaction output to the transaction.
2554
- *
2555
- * @param {Recipient} recipient The recipient of the transaction.
2556
- * @param {string} lovelace The amount of lovelace to send.
2557
- * @returns {Transaction} The Transaction object.
2558
- * @see {@link https://meshjs.dev/apis/transaction#sendAda}
2559
- */
2560
2771
  sendLovelace(e, t) {
2561
- const a = ft(e).next().with_coin(n.BigNum.from_str(t)).build();
2772
+ const a = _t(e).next().with_coin(i.BigNum.from_str(t)).build();
2562
2773
  return this.setTxOutput({
2563
2774
  unit: "lovelace",
2564
2775
  quantity: t
2565
2776
  }), this._txBuilder.add_output(a), this;
2566
2777
  }
2567
- /**
2568
- * Adds stable coins transaction output to the transaction.
2569
- * @param {Recipient} recipient The recipient of the transaction.
2570
- * @param {Token} ticker The ticker of the token to send.
2571
- * @param {string} amount The amount of the token to send.
2572
- * @returns {Transaction} The Transaction object.
2573
- * @see {@link https://meshjs.dev/apis/transaction#sendToken}
2574
- */
2575
2778
  sendToken(e, t, r) {
2576
2779
  return this.sendAssets(e, [{
2577
2780
  quantity: r,
2578
- unit: is[t]
2781
+ unit: as[t]
2579
2782
  }]), this;
2580
2783
  }
2581
- /**
2582
- * Adds an output to the transaction.
2583
- *
2584
- * @param {Recipient} recipient The recipient of the output.
2585
- * @param {UTxO} value The UTxO value of the output.
2586
- * @returns {Transaction} The Transaction object.
2587
- */
2588
2784
  sendValue(e, t) {
2589
- const r = Bt(t.output.amount), i = ft(e).next().with_value(r).build();
2785
+ const r = Bt(t.output.amount), n = _t(e).next().with_value(r).build();
2590
2786
  return t.output.amount.forEach((o) => {
2591
2787
  this.setTxOutput(o);
2592
- }), this._txBuilder.add_output(i), this;
2593
- }
2594
- /**
2595
- * Sets the change address for the transaction.
2596
- *
2597
- * @param {string} changeAddress The change address.
2598
- * @returns {Transaction} The Transaction object.
2599
- */
2788
+ }), this._txBuilder.add_output(n), this;
2789
+ }
2600
2790
  setChangeAddress(e) {
2601
- return this._changeAddress = T(e), this;
2602
- }
2603
- /**
2604
- * Sets the collateral for the transaction.
2605
- *
2606
- * @param {UTxO[]} collateral - Set the UTxO for collateral.
2607
- * @returns {Transaction} The Transaction object.
2608
- */
2791
+ return this._changeAddress = H(e), this;
2792
+ }
2609
2793
  setCollateral(e) {
2610
2794
  const t = _e(e);
2611
2795
  return this._txBuilder.set_collateral(t), this;
2612
2796
  }
2613
- /**
2614
- * Add a JSON metadata entry to the transaction.
2615
- *
2616
- * @param {number} key The key to use for the metadata entry.
2617
- * @param {unknown} value The value to use for the metadata entry.
2618
- * @returns {Transaction} The Transaction object.
2619
- * @see {@link https://meshjs.dev/apis/transaction#setMetadata}
2620
- */
2621
2797
  setMetadata(e, t) {
2622
- return this._txBuilder.add_json_metadatum_with_schema(n.BigNum.from_str(e.toString()), JSON.stringify(t), n.MetadataJsonSchema.NoConversions), this;
2623
- }
2624
- /**
2625
- * Sets the required signers for the transaction.
2626
- *
2627
- * @param {string[]} addresses The addresses of the required signers.
2628
- * @returns {Transaction} The Transaction object.
2629
- */
2798
+ return this._txBuilder.add_json_metadatum_with_schema(i.BigNum.from_str(e.toString()), JSON.stringify(t), i.MetadataJsonSchema.NoConversions), this;
2799
+ }
2630
2800
  setRequiredSigners(e) {
2631
- return Array.from(new Set(e.map((r) => r.startsWith("addr") ? st(r) : At(r)).map((r) => P(r)))).forEach((r) => {
2801
+ return Array.from(new Set(e.map((r) => r.startsWith("addr") ? rt(r) : dt(r)).map((r) => T(r)))).forEach((r) => {
2632
2802
  this._txBuilder.add_required_signer(r);
2633
2803
  }), this;
2634
2804
  }
2635
- /**
2636
- * Sets the start slot for the transaction.
2637
- *
2638
- * @param {string} slot The start slot for the transaction.
2639
- * @returns {Transaction} The Transaction object.
2640
- * @see {@link https://meshjs.dev/apis/transaction#setTimeLimit}
2641
- */
2642
2805
  setTimeToStart(e) {
2643
- return this._txBuilder.set_validity_start_interval_bignum(n.BigNum.from_str(e)), this;
2644
- }
2645
- /**
2646
- * Set the time to live for the transaction.
2647
- *
2648
- * @param {string} slot The slot number to expire the transaction at.
2649
- * @returns {Transaction} The Transaction object.
2650
- * @see {@link https://meshjs.dev/apis/transaction#setTimeLimit}
2651
- */
2806
+ return this._txBuilder.set_validity_start_interval_bignum(i.BigNum.from_str(e)), this;
2807
+ }
2652
2808
  setTimeToExpire(e) {
2653
- return this._txBuilder.set_ttl_bignum(n.BigNum.from_str(e)), this;
2654
- }
2655
- /**
2656
- * Sets the inputs for the transaction.
2657
- *
2658
- * @param {UTxO[]} inputs The inputs to set.
2659
- * @returns {Transaction} The transaction.
2660
- */
2809
+ return this._txBuilder.set_ttl_bignum(i.BigNum.from_str(e)), this;
2810
+ }
2661
2811
  setTxInputs(e) {
2662
- return e.map((t) => N(t)).forEach((t) => {
2812
+ return e.map((t) => F(t)).forEach((t) => {
2663
2813
  this._txInputsBuilder.add_input(t.output().address(), t.input(), t.output().amount());
2664
2814
  }), this;
2665
2815
  }
2666
- /**
2667
- * Sets the reference inputs for the transaction.
2668
- *
2669
- * @param {UTxO[]} inputs The reference inputs to set.
2670
- * @returns {Transaction} The transaction.
2671
- */
2672
2816
  setTxRefInputs(e) {
2673
- return e.map((t) => N(t)).forEach((t) => {
2817
+ return e.map((t) => F(t)).forEach((t) => {
2674
2818
  this._txBuilder.add_reference_input(t.input());
2675
2819
  }), this;
2676
2820
  }
2677
2821
  withdrawRewards(e, t) {
2678
2822
  const r = Me(e);
2679
- return r !== void 0 && this._txWithdrawals.insert(r, n.BigNum.from_str(t)), this;
2823
+ return r !== void 0 && this._txWithdrawals.insert(r, i.BigNum.from_str(t)), this;
2680
2824
  }
2681
2825
  async addBurnInputsIfNeeded() {
2682
2826
  if (this._initiator && this._totalBurns.size > 0 && this.notVisited("setTxInputs")) {
2683
2827
  const e = await this._initiator.getUsedUTxOs();
2684
- cs(this._totalBurns, e.map((r) => Qt(r))).map((r) => N(r)).forEach((r) => {
2828
+ is(this._totalBurns, e.map((r) => Qt(r))).map((r) => F(r)).forEach((r) => {
2685
2829
  this._txInputsBuilder.add_input(r.output().address(), r.input(), r.output().amount());
2686
2830
  });
2687
2831
  }
@@ -2701,14 +2845,14 @@ let L = class {
2701
2845
  }
2702
2846
  async addRequiredSignersIfNeeded() {
2703
2847
  if (this._initiator && this.notVisited("setRequiredSigners")) {
2704
- const e = await this._initiator.getUsedAddress(), t = st(e.to_bech32());
2705
- this._txBuilder.add_required_signer(P(t));
2848
+ const e = await this._initiator.getUsedAddress(), t = rt(e.to_bech32());
2849
+ this._txBuilder.add_required_signer(T(t));
2706
2850
  }
2707
2851
  }
2708
2852
  async addTxInputsAsNeeded() {
2709
2853
  if (this.notVisited("setTxInputs")) {
2710
2854
  const e = await this.filterAvailableUTxOs();
2711
- os(this._txOutputs, e.map((r) => Qt(r))).map((r) => N(r)).forEach((r) => {
2855
+ ns(this._txOutputs, e.map((r) => Qt(r))).map((r) => F(r)).forEach((r) => {
2712
2856
  this._txInputsBuilder.add_input(r.output().address(), r.input(), r.output().amount());
2713
2857
  });
2714
2858
  }
@@ -2719,10 +2863,12 @@ let L = class {
2719
2863
  }
2720
2864
  async forgeAssetsIfNeeded() {
2721
2865
  const e = (t, r) => {
2722
- const a = t.data.assetName, i = t.data.metadata, o = t.unit.slice(0, F);
2866
+ const a = t.data.assetName, n = t.data.metadata, o = t.unit.slice(0, M);
2867
+ if (t.data.label === "777")
2868
+ return n;
2723
2869
  if (r && r[o]) {
2724
2870
  const { [o]: c, ...u } = r, A = {
2725
- [a]: i,
2871
+ [a]: n,
2726
2872
  ...c
2727
2873
  };
2728
2874
  return {
@@ -2734,18 +2880,18 @@ let L = class {
2734
2880
  }
2735
2881
  return r !== void 0 ? {
2736
2882
  [o]: {
2737
- [a]: i
2883
+ [a]: n
2738
2884
  },
2739
2885
  ...r
2740
2886
  } : {
2741
- [o]: { [a]: i }
2887
+ [o]: { [a]: n }
2742
2888
  };
2743
2889
  };
2744
2890
  await this.addBurnInputsIfNeeded(), Array.from(this._totalMints, (t) => ({
2745
2891
  unit: t[0],
2746
2892
  data: t[1]
2747
2893
  })).reduce((t, r) => t.set(r.data.label, e(r, t.get(r.data.label))), /* @__PURE__ */ new Map()).forEach((t, r) => {
2748
- this._txBuilder.add_json_metadatum(n.BigNum.from_str(r), JSON.stringify(t));
2894
+ this._txBuilder.add_json_metadatum(i.BigNum.from_str(r), JSON.stringify(t));
2749
2895
  }), this.addMintOutputs();
2750
2896
  }
2751
2897
  async filterAvailableUTxOs(e = []) {
@@ -2755,7 +2901,7 @@ let L = class {
2755
2901
  this._recipients.forEach((e, t) => {
2756
2902
  const a = Bt(e).multiasset();
2757
2903
  if (a !== void 0) {
2758
- const o = ft(t).next().with_asset_and_min_required_coin_by_utxo_cost(a, me(this._protocolParameters.coinsPerUTxOSize)).build();
2904
+ const o = _t(t).next().with_asset_and_min_required_coin_by_utxo_cost(a, me(this._protocolParameters.coinsPerUTxOSize)).build();
2759
2905
  this._txBuilder.add_output(o);
2760
2906
  }
2761
2907
  });
@@ -2764,35 +2910,35 @@ let L = class {
2764
2910
  return this.__visits.includes(e) === !1;
2765
2911
  }
2766
2912
  setTxOutput(e) {
2767
- const r = n.BigNum.from_str(this._txOutputs.get(e.unit) ?? "0").checked_add(n.BigNum.from_str(e.quantity)).to_str();
2913
+ const r = i.BigNum.from_str(this._txOutputs.get(e.unit) ?? "0").checked_add(i.BigNum.from_str(e.quantity)).to_str();
2768
2914
  this._txOutputs.set(e.unit, r);
2769
2915
  }
2770
2916
  };
2771
- X([
2772
- tt()
2773
- ], L.prototype, "mintAsset", null);
2774
- X([
2775
- tt()
2776
- ], L.prototype, "redeemValue", null);
2777
- X([
2778
- tt()
2779
- ], L.prototype, "sendAssets", null);
2780
- X([
2781
- tt()
2782
- ], L.prototype, "sendValue", null);
2783
- X([
2784
- tt()
2785
- ], L.prototype, "setCollateral", null);
2786
- X([
2787
- tt()
2788
- ], L.prototype, "setRequiredSigners", null);
2789
- X([
2790
- tt()
2791
- ], L.prototype, "setTxInputs", null);
2792
- L = X([
2793
- rr
2794
- ], L);
2795
- class C {
2917
+ Z([
2918
+ et()
2919
+ ], $.prototype, "mintAsset", null);
2920
+ Z([
2921
+ et()
2922
+ ], $.prototype, "redeemValue", null);
2923
+ Z([
2924
+ et()
2925
+ ], $.prototype, "sendAssets", null);
2926
+ Z([
2927
+ et()
2928
+ ], $.prototype, "sendValue", null);
2929
+ Z([
2930
+ et()
2931
+ ], $.prototype, "setCollateral", null);
2932
+ Z([
2933
+ et()
2934
+ ], $.prototype, "setRequiredSigners", null);
2935
+ Z([
2936
+ et()
2937
+ ], $.prototype, "setTxInputs", null);
2938
+ $ = Z([
2939
+ Xs
2940
+ ], $);
2941
+ class w {
2796
2942
  _networkId;
2797
2943
  _encryptedSecret;
2798
2944
  constructor(e, t) {
@@ -2800,9 +2946,9 @@ class C {
2800
2946
  }
2801
2947
  getAccount(e, t) {
2802
2948
  return this.accountContext(e, t, (r, a) => {
2803
- const i = Ie(this._networkId, r.to_public().hash(), a.to_public().hash()).to_address().to_bech32(), o = pe(this._networkId, r.to_public().hash()).to_address().to_bech32(), c = Pt(this._networkId, a.to_public().hash()).to_address().to_bech32();
2949
+ const n = Ie(this._networkId, r.to_public().hash(), a.to_public().hash()).to_address().to_bech32(), o = pe(this._networkId, r.to_public().hash()).to_address().to_bech32(), c = Ft(this._networkId, a.to_public().hash()).to_address().to_bech32();
2804
2950
  return {
2805
- baseAddress: i,
2951
+ baseAddress: n,
2806
2952
  enterpriseAddress: o,
2807
2953
  rewardAddress: c
2808
2954
  };
@@ -2810,28 +2956,28 @@ class C {
2810
2956
  }
2811
2957
  signData(e, t, r, a) {
2812
2958
  try {
2813
- return this.accountContext(e, t, (i, o) => {
2959
+ return this.accountContext(e, t, (n, o) => {
2814
2960
  const c = { payload: a }, u = {
2815
- address: C.resolveAddress(this._networkId, r, i, o),
2816
- key: r.startsWith("stake") ? o : i
2817
- }, { coseSign1: A, coseKey: d } = hs(c, u);
2818
- return { signature: A, key: d };
2961
+ address: w.resolveAddress(this._networkId, r, n, o),
2962
+ key: r.startsWith("stake") ? o : n
2963
+ }, { coseSign1: A, coseKey: l } = gs(c, u);
2964
+ return { signature: A, key: l };
2819
2965
  });
2820
- } catch (i) {
2821
- throw new Error(`An error occurred during signData: ${i}.`);
2966
+ } catch (n) {
2967
+ throw new Error(`An error occurred during signData: ${n}.`);
2822
2968
  }
2823
2969
  }
2824
- signTx(e, t, r, a, i) {
2970
+ signTx(e, t, r, a, n) {
2825
2971
  try {
2826
- const o = Fe(sr(a));
2972
+ const o = Fe(js(a));
2827
2973
  return this.accountContext(e, t, (c, u) => {
2828
- const A = n.Vkeywitnesses.new();
2829
- return C.resolveSigners(a, r, c.to_public().hash().to_hex()).forEach((g) => {
2974
+ const A = i.Vkeywitnesses.new();
2975
+ return w.resolveSigners(a, r, c.to_public().hash().to_hex()).forEach((g) => {
2830
2976
  if (g === c.to_public().hash().to_hex())
2831
- A.add(n.make_vkey_witness(o, c));
2977
+ A.add(i.make_vkey_witness(o, c));
2832
2978
  else if (g === u.to_public().hash().to_hex())
2833
- A.add(n.make_vkey_witness(o, u));
2834
- else if (i === !1)
2979
+ A.add(i.make_vkey_witness(o, u));
2980
+ else if (n === !1)
2835
2981
  throw new Error(`Missing key witness for: ${g}`);
2836
2982
  }), A;
2837
2983
  });
@@ -2840,130 +2986,130 @@ class C {
2840
2986
  }
2841
2987
  }
2842
2988
  static encryptMnemonic(e, t) {
2843
- const r = ye(e.join(" ")), a = Ye(r), i = b(a.as_bytes());
2844
- return a.free(), C.encrypt(i, t);
2989
+ const r = Ce(e.join(" ")), a = Ye(r), n = D(a.as_bytes());
2990
+ return a.free(), w.encrypt(n, t);
2845
2991
  }
2846
2992
  static encryptPrivateKey(e, t) {
2847
- const r = n.Bip32PrivateKey.from_bech32(e), a = b(r.as_bytes());
2848
- return r.free(), C.encrypt(a, t);
2993
+ const r = i.Bip32PrivateKey.from_bech32(e), a = D(r.as_bytes());
2994
+ return r.free(), w.encrypt(a, t);
2849
2995
  }
2850
2996
  static encryptSigningKeys(e, t, r) {
2851
- const a = C.encrypt(e.slice(4), r), i = C.encrypt(t.slice(4), r);
2852
- return [a, i];
2997
+ const a = w.encrypt(e.slice(4), r), n = w.encrypt(t.slice(4), r);
2998
+ return [a, n];
2853
2999
  }
2854
3000
  static generateMnemonic(e = 256) {
2855
3001
  return $e(e).split(" ");
2856
3002
  }
2857
3003
  accountContext(e, t, r) {
2858
- const { paymentKey: a, stakeKey: i } = C.resolveKeys(e, t, this._encryptedSecret), o = r(a, i);
2859
- return a.free(), i.free(), o;
3004
+ const { paymentKey: a, stakeKey: n } = w.resolveKeys(e, t, this._encryptedSecret), o = r(a, n);
3005
+ return a.free(), n.free(), o;
2860
3006
  }
2861
3007
  static decrypt(e, t) {
2862
3008
  try {
2863
- return n.decrypt_with_password(S(t), e);
3009
+ return i.decrypt_with_password(S(t), e);
2864
3010
  } catch {
2865
3011
  throw new Error("The password is incorrect.");
2866
3012
  }
2867
3013
  }
2868
3014
  static encrypt(e, t) {
2869
- const r = Be("0123456789abcdef"), a = r(64), i = r(24);
2870
- return n.encrypt_with_password(S(t), a, i, e);
3015
+ const r = ye("0123456789abcdef"), a = r(64), n = r(24);
3016
+ return i.encrypt_with_password(S(t), a, n, e);
2871
3017
  }
2872
3018
  static resolveAddress(e, t, r, a) {
2873
- const i = [
3019
+ const n = [
2874
3020
  Ie(e, r.to_public().hash(), a.to_public().hash()),
2875
3021
  pe(e, r.to_public().hash()),
2876
- Pt(e, a.to_public().hash())
3022
+ Ft(e, a.to_public().hash())
2877
3023
  ].find((o) => o.to_address().to_bech32() === t);
2878
- if (i !== void 0)
2879
- return i.to_address();
3024
+ if (n !== void 0)
3025
+ return n.to_address();
2880
3026
  throw new Error(`Address: ${t} doesn't belong to this account.`);
2881
3027
  }
2882
3028
  static resolveKeys(e, t, r) {
2883
3029
  if (typeof r == "string") {
2884
- const o = C.decrypt(r, t);
2885
- return Ys(o, e);
3030
+ const o = w.decrypt(r, t);
3031
+ return Ts(o, e);
2886
3032
  }
2887
- const a = C.decrypt(r[0], t), i = C.decrypt(r[1], t);
3033
+ const a = w.decrypt(r[0], t), n = w.decrypt(r[1], t);
2888
3034
  return {
2889
- paymentKey: n.PrivateKey.from_hex(a),
2890
- stakeKey: n.PrivateKey.from_hex(i)
3035
+ paymentKey: i.PrivateKey.from_hex(a),
3036
+ stakeKey: i.PrivateKey.from_hex(n)
2891
3037
  };
2892
3038
  }
2893
3039
  static resolveSigners(e, t, r) {
2894
3040
  const a = (c) => {
2895
- const u = (p, E = [], w = 0) => {
2896
- var ht, ct, Gt, Lt, Rt;
2897
- if (p === void 0 || w >= p.len())
3041
+ const u = (p, E = [], B = 0) => {
3042
+ var It, ut, Lt, Gt, Rt;
3043
+ if (p === void 0 || B >= p.len())
2898
3044
  return E;
2899
- const v = p.get(w), k = new Array();
2900
- switch (v.kind()) {
2901
- case n.CertificateKind.StakeDeregistration: {
2902
- const y = (ht = v.as_stake_deregistration()) == null ? void 0 : ht.stake_credential(), O = (y == null ? void 0 : y.kind()) === n.StakeCredKind.Key ? y.to_keyhash() : void 0;
2903
- O && k.push(O.to_hex());
3045
+ const U = p.get(B), K = new Array();
3046
+ switch (U.kind()) {
3047
+ case i.CertificateKind.StakeDeregistration: {
3048
+ const C = (It = U.as_stake_deregistration()) == null ? void 0 : It.stake_credential(), V = (C == null ? void 0 : C.kind()) === i.StakeCredKind.Key ? C.to_keyhash() : void 0;
3049
+ V && K.push(V.to_hex());
2904
3050
  break;
2905
3051
  }
2906
- case n.CertificateKind.StakeDelegation: {
2907
- const y = (ct = v.as_stake_delegation()) == null ? void 0 : ct.stake_credential(), O = (y == null ? void 0 : y.kind()) === n.StakeCredKind.Key ? y.to_keyhash() : void 0;
2908
- O && k.push(O.to_hex());
3052
+ case i.CertificateKind.StakeDelegation: {
3053
+ const C = (ut = U.as_stake_delegation()) == null ? void 0 : ut.stake_credential(), V = (C == null ? void 0 : C.kind()) === i.StakeCredKind.Key ? C.to_keyhash() : void 0;
3054
+ V && K.push(V.to_hex());
2909
3055
  break;
2910
3056
  }
2911
- case n.CertificateKind.PoolRegistration: {
2912
- const y = (Gt = v.as_pool_registration()) == null ? void 0 : Gt.pool_params().pool_owners();
2913
- k.push(...d(y));
3057
+ case i.CertificateKind.PoolRegistration: {
3058
+ const C = (Lt = U.as_pool_registration()) == null ? void 0 : Lt.pool_params().pool_owners();
3059
+ K.push(...l(C));
2914
3060
  break;
2915
3061
  }
2916
- case n.CertificateKind.PoolRetirement: {
2917
- const y = (Lt = v.as_pool_retirement()) == null ? void 0 : Lt.pool_keyhash();
2918
- y && k.push(y.to_hex());
3062
+ case i.CertificateKind.PoolRetirement: {
3063
+ const C = (Gt = U.as_pool_retirement()) == null ? void 0 : Gt.pool_keyhash();
3064
+ C && K.push(C.to_hex());
2919
3065
  break;
2920
3066
  }
2921
- case n.CertificateKind.MoveInstantaneousRewardsCert: {
2922
- const y = (Rt = v.as_move_instantaneous_rewards_cert()) == null ? void 0 : Rt.move_instantaneous_reward().as_to_stake_creds();
2923
- if (y)
2924
- for (let O = 0; O < y.len(); O += 1) {
2925
- const $t = y.keys().get(O), zt = $t.kind() === n.StakeCredKind.Key ? $t.to_keyhash() : void 0;
2926
- zt && k.push(zt.to_hex());
3067
+ case i.CertificateKind.MoveInstantaneousRewardsCert: {
3068
+ const C = (Rt = U.as_move_instantaneous_rewards_cert()) == null ? void 0 : Rt.move_instantaneous_reward().as_to_stake_creds();
3069
+ if (C)
3070
+ for (let V = 0; V < C.len(); V += 1) {
3071
+ const $t = C.keys().get(V), zt = $t.kind() === i.StakeCredKind.Key ? $t.to_keyhash() : void 0;
3072
+ zt && K.push(zt.to_hex());
2927
3073
  }
2928
3074
  break;
2929
3075
  }
2930
3076
  }
2931
- return u(p, [...E, ...k], w + 1);
2932
- }, A = (p, E = [], w = 0) => {
2933
- if (p === void 0 || w >= p.len())
3077
+ return u(p, [...E, ...K], B + 1);
3078
+ }, A = (p, E = [], B = 0) => {
3079
+ if (p === void 0 || B >= p.len())
2934
3080
  return E;
2935
- const v = p.get(w).index(), k = p.get(w).transaction_id(), ht = t.find((ct) => ct.input.outputIndex === v && ct.input.txHash === k.to_hex()) !== void 0 ? r : "OUR_PRINCESS_IS_IN_ANOTHER_CASTLE";
2936
- return A(p, [...E, ht], w + 1);
2937
- }, d = (p, E = [], w = 0) => p === void 0 || w >= p.len() ? E : d(p, [...E, p.get(w).to_hex()], w + 1), g = (p, E = [], w = 0) => {
2938
- if (p === void 0 || w >= p.len())
3081
+ const U = p.get(B).index(), K = p.get(B).transaction_id(), It = t.find((ut) => ut.input.outputIndex === U && ut.input.txHash === K.to_hex()) !== void 0 ? r : "OUR_PRINCESS_IS_IN_ANOTHER_CASTLE";
3082
+ return A(p, [...E, It], B + 1);
3083
+ }, l = (p, E = [], B = 0) => p === void 0 || B >= p.len() ? E : l(p, [...E, p.get(B).to_hex()], B + 1), g = (p, E = [], B = 0) => {
3084
+ if (p === void 0 || B >= p.len())
2939
3085
  return E;
2940
- const v = p.keys().get(w).payment_cred(), k = v.kind() === n.StakeCredKind.Key ? v.to_keyhash() : void 0;
2941
- return g(p, k ? [...E, k.to_hex()] : E, w + 1);
2942
- }, I = c.certs(), _ = c.collateral(), x = c.inputs(), H = c.required_signers(), R = c.withdrawals();
3086
+ const U = p.keys().get(B).payment_cred(), K = U.kind() === i.StakeCredKind.Key ? U.to_keyhash() : void 0;
3087
+ return g(p, K ? [...E, K.to_hex()] : E, B + 1);
3088
+ }, I = c.certs(), f = c.collateral(), y = c.inputs(), b = c.required_signers(), k = c.withdrawals();
2943
3089
  return [
2944
3090
  ...u(I),
2945
- ...A(_),
2946
- ...A(x),
2947
- ...d(H),
2948
- ...g(R)
3091
+ ...A(f),
3092
+ ...A(y),
3093
+ ...l(b),
3094
+ ...g(k)
2949
3095
  ];
2950
- }, i = (c) => {
2951
- const u = (d, g = []) => {
2952
- var I, _, x, H;
2953
- if (d)
2954
- for (let R = 0; R < d.len(); R += 1) {
2955
- const p = d.get(R);
3096
+ }, n = (c) => {
3097
+ const u = (l, g = []) => {
3098
+ var I, f, y, b;
3099
+ if (l)
3100
+ for (let k = 0; k < l.len(); k += 1) {
3101
+ const p = l.get(k);
2956
3102
  switch (p.kind()) {
2957
- case n.NativeScriptKind.ScriptPubkey: {
3103
+ case i.NativeScriptKind.ScriptPubkey: {
2958
3104
  const E = (I = p.as_script_pubkey()) == null ? void 0 : I.addr_keyhash().to_hex();
2959
3105
  return E ? [...g, E] : g;
2960
3106
  }
2961
- case n.NativeScriptKind.ScriptAll:
2962
- return u((_ = p.as_script_all()) == null ? void 0 : _.native_scripts(), g);
2963
- case n.NativeScriptKind.ScriptAny:
2964
- return u((x = p.as_script_any()) == null ? void 0 : x.native_scripts(), g);
2965
- case n.NativeScriptKind.ScriptNOfK:
2966
- return u((H = p.as_script_n_of_k()) == null ? void 0 : H.native_scripts(), g);
3107
+ case i.NativeScriptKind.ScriptAll:
3108
+ return u((f = p.as_script_all()) == null ? void 0 : f.native_scripts(), g);
3109
+ case i.NativeScriptKind.ScriptAny:
3110
+ return u((y = p.as_script_any()) == null ? void 0 : y.native_scripts(), g);
3111
+ case i.NativeScriptKind.ScriptNOfK:
3112
+ return u((b = p.as_script_n_of_k()) == null ? void 0 : b.native_scripts(), g);
2967
3113
  }
2968
3114
  }
2969
3115
  return g;
@@ -2971,61 +3117,61 @@ class C {
2971
3117
  return [
2972
3118
  ...u(A)
2973
3119
  ];
2974
- }, o = Y(e);
3120
+ }, o = q(e);
2975
3121
  return /* @__PURE__ */ new Set([
2976
3122
  ...a(o.body()),
2977
- ...i(o.witness_set())
3123
+ ...n(o.witness_set())
2978
3124
  ]);
2979
3125
  }
2980
3126
  }
2981
- const U = "MARI0TIME";
2982
- class Ur {
3127
+ const N = "MARI0TIME";
3128
+ class Dr {
2983
3129
  _fetcher;
2984
3130
  _submitter;
2985
3131
  _wallet;
2986
3132
  constructor(e) {
2987
3133
  switch (this._fetcher = e.fetcher, this._submitter = e.submitter, e.key.type) {
2988
3134
  case "mnemonic":
2989
- this._wallet = new C(e.networkId, C.encryptMnemonic(e.key.words, U));
3135
+ this._wallet = new w(e.networkId, w.encryptMnemonic(e.key.words, N));
2990
3136
  break;
2991
3137
  case "root":
2992
- this._wallet = new C(e.networkId, C.encryptPrivateKey(e.key.bech32, U));
3138
+ this._wallet = new w(e.networkId, w.encryptPrivateKey(e.key.bech32, N));
2993
3139
  break;
2994
3140
  case "cli":
2995
- this._wallet = new C(e.networkId, C.encryptSigningKeys(e.key.payment, e.key.stake ?? "f0".repeat(34), U));
3141
+ this._wallet = new w(e.networkId, w.encryptSigningKeys(e.key.payment, e.key.stake ?? "f0".repeat(34), N));
2996
3142
  }
2997
3143
  }
2998
3144
  getBaseAddress(e = 0) {
2999
- return this._wallet.getAccount(e, U).baseAddress;
3145
+ return this._wallet.getAccount(e, N).baseAddress;
3000
3146
  }
3001
3147
  getPaymentAddress(e = 0) {
3002
- return this._wallet.getAccount(e, U).enterpriseAddress;
3148
+ return this._wallet.getAccount(e, N).enterpriseAddress;
3003
3149
  }
3004
3150
  getRewardAddress(e = 0) {
3005
- return this._wallet.getAccount(e, U).rewardAddress;
3151
+ return this._wallet.getAccount(e, N).rewardAddress;
3006
3152
  }
3007
3153
  getUsedAddress(e = 0) {
3008
- const t = this._wallet.getAccount(e, U);
3009
- return T(t.enterpriseAddress);
3154
+ const t = this._wallet.getAccount(e, N);
3155
+ return H(t.enterpriseAddress);
3010
3156
  }
3011
- getUsedCollateral(e = q.maxCollateralInputs) {
3157
+ getUsedCollateral(e = G.maxCollateralInputs) {
3012
3158
  throw new Error("getUsedCollateral not implemented.");
3013
3159
  }
3014
3160
  async getUsedUTxOs(e = 0) {
3015
- const t = this._wallet.getAccount(e, U);
3016
- return (await this._fetcher.fetchAddressUTxOs(t.enterpriseAddress)).map((a) => N(a));
3161
+ const t = this._wallet.getAccount(e, N);
3162
+ return (await this._fetcher.fetchAddressUTxOs(t.enterpriseAddress)).map((a) => F(a));
3017
3163
  }
3018
3164
  signData(e, t, r = 0) {
3019
3165
  try {
3020
- return this._wallet.signData(r, U, e, t);
3166
+ return this._wallet.signData(r, N, e, t);
3021
3167
  } catch (a) {
3022
3168
  throw new Error(`[AppWallet] An error occurred during signData: ${a}.`);
3023
3169
  }
3024
3170
  }
3025
3171
  async signTx(e, t = !1, r = 0) {
3026
3172
  try {
3027
- const a = this._wallet.getAccount(r, U), i = await this._fetcher.fetchAddressUTxOs(a.enterpriseAddress), o = this._wallet.signTx(r, U, i, e, t), c = Y(e), u = c.witness_set(), A = Le(u, o);
3028
- return u.set_vkeys(A), n.Transaction.new(c.body(), u, c.auxiliary_data()).to_hex();
3173
+ const a = this._wallet.getAccount(r, N), n = await this._fetcher.fetchAddressUTxOs(a.enterpriseAddress), o = this._wallet.signTx(r, N, n, e, t), c = q(e), u = c.witness_set(), A = Ge(u, o);
3174
+ return u.set_vkeys(A), i.Transaction.new(c.body(), u, c.auxiliary_data()).to_hex();
3029
3175
  } catch (a) {
3030
3176
  throw new Error(`[AppWallet] An error occurred during signTx: ${a}.`);
3031
3177
  }
@@ -3034,10 +3180,10 @@ class Ur {
3034
3180
  return this._submitter.submitTx(e);
3035
3181
  }
3036
3182
  static brew(e = 256) {
3037
- return C.generateMnemonic(e);
3183
+ return w.generateMnemonic(e);
3038
3184
  }
3039
3185
  }
3040
- class Ft {
3186
+ class Tt {
3041
3187
  _walletInstance;
3042
3188
  constructor(e) {
3043
3189
  this._walletInstance = e;
@@ -3051,9 +3197,9 @@ class Ft {
3051
3197
  }
3052
3198
  static async enable(e) {
3053
3199
  try {
3054
- const t = await Ft.resolveInstance(e);
3200
+ const t = await Tt.resolveInstance(e);
3055
3201
  if (t !== void 0)
3056
- return new Ft(t);
3202
+ return new Tt(t);
3057
3203
  throw new Error(`Couldn't create an instance of wallet: ${e}`);
3058
3204
  } catch (t) {
3059
3205
  throw new Error(`[BrowserWallet] An error occurred during enable: ${t}.`);
@@ -3061,38 +3207,38 @@ class Ft {
3061
3207
  }
3062
3208
  async getBalance() {
3063
3209
  const e = await this._walletInstance.getBalance();
3064
- return Ve(Js(e));
3210
+ return Ve(Gs(e));
3065
3211
  }
3066
3212
  async getChangeAddress() {
3067
3213
  const e = await this._walletInstance.getChangeAddress();
3068
- return et(e).to_bech32();
3214
+ return st(e).to_bech32();
3069
3215
  }
3070
- async getCollateral(e = q.maxCollateralInputs) {
3216
+ async getCollateral(e = G.maxCollateralInputs) {
3071
3217
  return (await this.getUsedCollateral(e)).map((r) => Qt(r));
3072
3218
  }
3073
3219
  getNetworkId() {
3074
3220
  return this._walletInstance.getNetworkId();
3075
3221
  }
3076
3222
  async getRewardAddresses() {
3077
- return (await this._walletInstance.getRewardAddresses()).map((t) => et(t).to_bech32());
3223
+ return (await this._walletInstance.getRewardAddresses()).map((t) => st(t).to_bech32());
3078
3224
  }
3079
3225
  async getUnusedAddresses() {
3080
- return (await this._walletInstance.getUnusedAddresses()).map((t) => et(t).to_bech32());
3226
+ return (await this._walletInstance.getUnusedAddresses()).map((t) => st(t).to_bech32());
3081
3227
  }
3082
3228
  async getUsedAddresses() {
3083
- return (await this._walletInstance.getUsedAddresses()).map((t) => et(t).to_bech32());
3229
+ return (await this._walletInstance.getUsedAddresses()).map((t) => st(t).to_bech32());
3084
3230
  }
3085
3231
  async getUtxos() {
3086
3232
  return (await this.getUsedUTxOs()).map((t) => Qt(t));
3087
3233
  }
3088
3234
  signData(e, t) {
3089
- const r = T(e).to_hex();
3235
+ const r = H(e).to_hex();
3090
3236
  return this._walletInstance.signData(r, S(t));
3091
3237
  }
3092
3238
  async signTx(e, t = !1) {
3093
3239
  try {
3094
- const r = Y(e), a = r.witness_set(), i = await this._walletInstance.signTx(e, t), o = Ws(i).vkeys() ?? n.Vkeywitnesses.new(), c = Le(a, o);
3095
- return a.set_vkeys(c), b(n.Transaction.new(r.body(), a, r.auxiliary_data()).to_bytes());
3240
+ const r = q(e), a = r.witness_set(), n = await this._walletInstance.signTx(e, t), o = Ls(n).vkeys() ?? i.Vkeywitnesses.new(), c = Ge(a, o);
3241
+ return a.set_vkeys(c), D(i.Transaction.new(r.body(), a, r.auxiliary_data()).to_bytes());
3096
3242
  } catch (r) {
3097
3243
  throw new Error(`[BrowserWallet] An error occurred during signTx: ${JSON.stringify(r)}.`);
3098
3244
  }
@@ -3102,9 +3248,9 @@ class Ft {
3102
3248
  }
3103
3249
  async getUsedAddress() {
3104
3250
  const e = await this._walletInstance.getUsedAddresses();
3105
- return et(e[0]);
3251
+ return st(e[0]);
3106
3252
  }
3107
- async getUsedCollateral(e = q.maxCollateralInputs) {
3253
+ async getUsedCollateral(e = G.maxCollateralInputs) {
3108
3254
  return (await this._walletInstance.experimental.getCollateral() ?? []).map((r) => le(r)).slice(0, e);
3109
3255
  }
3110
3256
  async getUsedUTxOs() {
@@ -3112,12 +3258,12 @@ class Ft {
3112
3258
  }
3113
3259
  async getAssets() {
3114
3260
  return (await this.getBalance()).filter((t) => t.unit !== "lovelace").map((t) => {
3115
- const r = t.unit.slice(0, F), a = t.unit.slice(F), i = er(r, a);
3261
+ const r = t.unit.slice(0, M), a = t.unit.slice(M), n = Js(r, a);
3116
3262
  return {
3117
3263
  unit: t.unit,
3118
3264
  policyId: r,
3119
- assetName: Yt(a),
3120
- fingerprint: i,
3265
+ assetName: qt(a),
3266
+ fingerprint: n,
3121
3267
  quantity: t.quantity
3122
3268
  };
3123
3269
  });
@@ -3131,7 +3277,7 @@ class Ft {
3131
3277
  }
3132
3278
  async getPolicyIds() {
3133
3279
  const e = await this.getBalance();
3134
- return Array.from(new Set(e.map((t) => t.unit.slice(0, F)))).filter((t) => t !== "lovelace");
3280
+ return Array.from(new Set(e.map((t) => t.unit.slice(0, M)))).filter((t) => t !== "lovelace");
3135
3281
  }
3136
3282
  static resolveInstance(e) {
3137
3283
  if (window.cardano === void 0)
@@ -3140,25 +3286,24 @@ class Ft {
3140
3286
  return t == null ? void 0 : t.enable();
3141
3287
  }
3142
3288
  }
3143
- const Re = "http://localhost:4000/", ar = "http://localhost:5000/", nr = `${Re}access`, ir = `${Re}transaction/signtx`;
3144
- class Kr {
3289
+ const Re = "http://localhost:4000/", Zs = "http://localhost:5000/", tr = `${Re}access`, er = `${Re}transaction/signtx`;
3290
+ class vr {
3145
3291
  static getAxiosInstance() {
3146
- return j.create({
3147
- baseURL: ar,
3292
+ return L.create({
3293
+ baseURL: Zs,
3148
3294
  withCredentials: !0
3149
3295
  });
3150
3296
  }
3151
3297
  static getAppId() {
3152
3298
  return window.location.hostname;
3153
3299
  }
3154
- // TODO, popup blocker issue, need to create html modal instead
3155
3300
  static async openMinaFrontend(e) {
3156
3301
  const t = this.getAppId();
3157
3302
  e.includes("?") ? e = `${e}&appId=${t}` : e = `${e}?appId=${t}`;
3158
3303
  const r = "left=100,top=100,width=540,height=540", a = window.open(e, "meshWindow", r);
3159
- return a || console.error("the window did not open", a), await (async () => new Promise((i) => {
3304
+ return a || console.error("the window did not open", a), await (async () => new Promise((n) => {
3160
3305
  window.addEventListener("message", async (o) => {
3161
- o.data.target == "minaWallet" && i(o.data);
3306
+ o.data.target == "minaWallet" && n(o.data);
3162
3307
  });
3163
3308
  }))();
3164
3309
  }
@@ -3178,7 +3323,7 @@ class Kr {
3178
3323
  }
3179
3324
  }
3180
3325
  static async enable() {
3181
- return await this.get("wallet/getuserwalletsmeta") === void 0 ? await this.openMinaFrontend(nr) : !0;
3326
+ return await this.get("wallet/getuserwalletsmeta") === void 0 ? await this.openMinaFrontend(tr) : !0;
3182
3327
  }
3183
3328
  static async getChangeAddress(e = void 0, t = void 0) {
3184
3329
  return await this.get("wallet/getchangeaddress", {
@@ -3195,11 +3340,11 @@ class Kr {
3195
3340
  static async signTx(e, t = !1) {
3196
3341
  const r = await this.get("wallet/getuserwalletsmeta");
3197
3342
  if (console.log("userWalletsMeta", r), r) {
3198
- const a = await this.openMinaFrontend(`${ir}?unsignedTx=${e}&partialSign=${t}`);
3199
- if (a instanceof n.Vkeywitnesses) {
3200
- const i = Y(e), o = i.witness_set();
3343
+ const a = await this.openMinaFrontend(`${er}?unsignedTx=${e}&partialSign=${t}`);
3344
+ if (a instanceof i.Vkeywitnesses) {
3345
+ const n = q(e), o = n.witness_set();
3201
3346
  o.set_vkeys(a);
3202
- const c = n.Transaction.new(i.body(), o, i.auxiliary_data()).to_hex();
3347
+ const c = i.Transaction.new(n.body(), o, n.auxiliary_data()).to_hex();
3203
3348
  return console.log("signedTx", c), c;
3204
3349
  }
3205
3350
  } else
@@ -3207,41 +3352,42 @@ class Kr {
3207
3352
  }
3208
3353
  }
3209
3354
  export {
3210
- Ur as AppWallet,
3211
- xr as BlockfrostProvider,
3212
- Ft as BrowserWallet,
3213
- C as EmbeddedWallet,
3214
- vr as ForgeScript,
3215
- Sr as InfuraProvider,
3216
- Qr as KoiosProvider,
3217
- Kr as MinaWallet,
3218
- br as OgmiosProvider,
3219
- Dr as TangoProvider,
3220
- L as Transaction,
3221
- gr as checkSignature,
3222
- wr as generateNonce,
3355
+ Dr as AppWallet,
3356
+ Cr as BlockfrostProvider,
3357
+ Tt as BrowserWallet,
3358
+ w as EmbeddedWallet,
3359
+ Qr as ForgeScript,
3360
+ wr as InfuraProvider,
3361
+ Br as KoiosProvider,
3362
+ Sr as MaestroProvider,
3363
+ vr as MinaWallet,
3364
+ xr as OgmiosProvider,
3365
+ Er as TangoProvider,
3366
+ $ as Transaction,
3367
+ or as checkSignature,
3368
+ fr as generateNonce,
3223
3369
  ts as isNetwork,
3224
- os as keepRelevant,
3225
- Ar as largestFirst,
3226
- cs as largestFirstMultiAsset,
3227
- ot as parseAssetUnit,
3228
- l as parseHttpError,
3229
- Br as readPlutusData,
3230
- Er as readTransaction,
3231
- dr as resolveDataHash,
3232
- lr as resolveEpochNo,
3233
- er as resolveFingerprint,
3234
- hr as resolveLanguageView,
3235
- Ir as resolveNativeScriptHash,
3236
- st as resolvePaymentKeyHash,
3237
- mr as resolvePlutusScriptAddress,
3238
- pr as resolvePlutusScriptHash,
3239
- fr as resolvePoolId,
3240
- _r as resolvePrivateKey,
3241
- qt as resolveRewardAddress,
3242
- yr as resolveScriptRef,
3243
- Cr as resolveSlotNo,
3244
- At as resolveStakeKeyHash,
3245
- Ge as resolveTxFees,
3246
- sr as resolveTxHash
3370
+ ns as keepRelevant,
3371
+ ir as largestFirst,
3372
+ is as largestFirstMultiAsset,
3373
+ X as parseAssetUnit,
3374
+ d as parseHttpError,
3375
+ _r as readPlutusData,
3376
+ yr as readTransaction,
3377
+ cr as resolveDataHash,
3378
+ ur as resolveEpochNo,
3379
+ Js as resolveFingerprint,
3380
+ Ar as resolveLanguageView,
3381
+ dr as resolveNativeScriptHash,
3382
+ rt as resolvePaymentKeyHash,
3383
+ gr as resolvePlutusScriptAddress,
3384
+ lr as resolvePlutusScriptHash,
3385
+ hr as resolvePoolId,
3386
+ Ir as resolvePrivateKey,
3387
+ kt as resolveRewardAddress,
3388
+ mr as resolveScriptRef,
3389
+ pr as resolveSlotNo,
3390
+ dt as resolveStakeKeyHash,
3391
+ Le as resolveTxFees,
3392
+ js as resolveTxHash
3247
3393
  };