@lydianpay/sdk-web 3.18.2 → 3.18.4

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.
@@ -1,11 +1,11 @@
1
- const S = ["USD", "TRY", "PHP"];
2
- function F(e) {
3
- return typeof e == "string" && S.includes(e);
1
+ const E = ["USD", "TRY", "PHP"];
2
+ function U(e) {
3
+ return typeof e == "string" && E.includes(e);
4
4
  }
5
- function d(e) {
5
+ function u(e) {
6
6
  return "sessionID" in e && typeof e.sessionID == "string" && e.sessionID.length > 0;
7
7
  }
8
- class W extends Error {
8
+ class O extends Error {
9
9
  constructor({
10
10
  statusText: t,
11
11
  errorCode: a,
@@ -14,19 +14,19 @@ class W extends Error {
14
14
  super(t, { cause: n }), this.name = "GatewayRequestError", this.errorCode = a;
15
15
  }
16
16
  }
17
- async function h(e) {
17
+ async function m(e) {
18
18
  const t = await e.clone().json().catch(() => null);
19
- return new W({
19
+ return new O({
20
20
  statusText: e.statusText,
21
- errorCode: $(t),
21
+ errorCode: F(t),
22
22
  response: e
23
23
  });
24
24
  }
25
- function $(e) {
25
+ function F(e) {
26
26
  if (!(typeof e != "object" || e === null || !("errorCode" in e)))
27
27
  return typeof e.errorCode == "number" ? e.errorCode : void 0;
28
28
  }
29
- class u {
29
+ class y {
30
30
  // Optional: a caller-supplied session has no key and needs none (see Sessions).
31
31
  // The key is still required when the SDK creates the session, enforced in
32
32
  // index.ts where that is known.
@@ -44,7 +44,7 @@ class u {
44
44
  const n = `${this.baseUri}${t}`, o = this.headers({ "Content-Type": "application/json", ...a == null ? void 0 : a.headers }), r = Object.assign({}, a, { headers: o }), s = await fetch(n, r);
45
45
  if (s.ok)
46
46
  return await s.json();
47
- throw await h(s);
47
+ throw await m(s);
48
48
  }
49
49
  // For endpoints that reply text/plain rather than JSON (e.g. PATCH
50
50
  // /customer/otp -> "OTP sent"). Sends the same JSON request headers but does
@@ -53,22 +53,21 @@ class u {
53
53
  const n = `${this.baseUri}${t}`, o = this.headers({ "Content-Type": "application/json" }), r = Object.assign({}, a, { headers: o }), s = await fetch(n, r);
54
54
  if (s.ok)
55
55
  return await s.text();
56
- throw await h(s);
56
+ throw await m(s);
57
57
  }
58
58
  async requestWithFormData(t, a) {
59
59
  const n = `${this.baseUri}${t}`, o = this.headers(), r = Object.assign({}, a, { headers: o }), s = await fetch(n, r);
60
60
  if (s.ok)
61
61
  return await s.json();
62
- throw await h(s);
62
+ throw await m(s);
63
63
  }
64
64
  }
65
- const c = "transaction", x = [
65
+ const c = "transaction", W = [
66
66
  "firstName",
67
67
  "lastName",
68
68
  "email",
69
69
  "street",
70
70
  "city",
71
- "subdivision",
72
71
  "region",
73
72
  "postalCode",
74
73
  "country",
@@ -81,7 +80,7 @@ const c = "transaction", x = [
81
80
  "nationalIDNumber",
82
81
  "customerIDNumber"
83
82
  ];
84
- class B extends u {
83
+ class $ extends y {
85
84
  async getCryptoTransaction(t) {
86
85
  return await this.request(`/${c}/${t}`);
87
86
  }
@@ -123,7 +122,7 @@ class B extends u {
123
122
  }
124
123
  async kycVerification(t, a) {
125
124
  const n = new FormData();
126
- return n.append("asset", a.asset), n.append("network", a.network), x.forEach((o) => {
125
+ return n.append("asset", a.asset), n.append("network", a.network), W.forEach((o) => {
127
126
  const r = a[o];
128
127
  r && n.append(o, r);
129
128
  }), n.append("storeKYC", a.storeKYC ? "true" : "false"), a.customerUUID && n.append("customerUUID", a.customerUUID), a.walletAddress && n.append("walletAddress", a.walletAddress), a.documentType && n.append("documentType", a.documentType), a.documentFiles.forEach(
@@ -146,7 +145,7 @@ function Y(e, t) {
146
145
  });
147
146
  }
148
147
  const k = "customer/otp";
149
- class M extends u {
148
+ class x extends y {
150
149
  // PATCH /customer/otp -> text/plain "OTP sent" (no JSON body).
151
150
  async sendCustomerOTP(t) {
152
151
  return await this.requestText(`/${k}`, {
@@ -162,23 +161,17 @@ class M extends u {
162
161
  });
163
162
  }
164
163
  }
165
- const C = "places", P = { "X-User": "lydian" };
166
- class G extends u {
164
+ const B = "places", M = { "X-User": "lydian" };
165
+ class _ extends y {
167
166
  async getCountries(t) {
168
- return await this.request(`/${C}/countries`, {
169
- headers: P,
167
+ return await this.request(`/${B}/countries`, {
168
+ headers: M,
170
169
  signal: t
171
170
  });
172
171
  }
173
- async getStates(t, a) {
174
- return await this.request(
175
- `/${C}/states?country=${encodeURIComponent(t)}`,
176
- { headers: P, signal: a }
177
- );
178
- }
179
172
  }
180
173
  const l = "session";
181
- class _ extends u {
174
+ class q extends y {
182
175
  async createSession(t) {
183
176
  return await this.request(`/${l}`, {
184
177
  method: "POST",
@@ -214,11 +207,11 @@ class _ extends u {
214
207
  });
215
208
  }
216
209
  }
217
- class D extends u {
210
+ class v extends y {
218
211
  }
219
- Y(D, [B, M, G, _]);
220
- const q = D;
221
- var y = {
212
+ Y(v, [$, x, _, q]);
213
+ const G = v;
214
+ var d = {
222
215
  COMPLIANCE_PENDING: -10,
223
216
  API_CANCELLED: -9,
224
217
  PAYMENT_TIMEOUT: -8,
@@ -235,21 +228,21 @@ var y = {
235
228
  FRAUD: -1,
236
229
  PENDING: 0,
237
230
  SUCCESS: 1
238
- }, de = {
231
+ }, j = {
239
232
  PARTIALLY_PAID: 1,
240
233
  OVERPAID: 3
241
- }, j = {
234
+ }, H = {
242
235
  PENDING: 0,
243
236
  CONFIRMED: 1
244
- }, m = {
237
+ }, w = {
245
238
  dev: "https://api.lydian.dev",
246
239
  sandbox: "https://api.sandbox.lydian.com",
247
240
  prod: "https://api.lydian.com"
248
241
  };
249
- function H(e) {
250
- return e.gatewayUrl ? new URL(e.gatewayUrl).origin : e.dev ? m.dev : e.sandbox ? m.sandbox : m.prod;
242
+ function K(e) {
243
+ return e.gatewayUrl ? new URL(e.gatewayUrl).origin : e.dev ? w.dev : e.sandbox ? w.sandbox : w.prod;
251
244
  }
252
- function A({
245
+ function S({
253
246
  options: e,
254
247
  unsupportedKeys: t,
255
248
  entryPoint: a
@@ -257,14 +250,14 @@ function A({
257
250
  const n = t.filter((o) => e[o] !== void 0);
258
251
  return n.length === 0 ? null : `${n.join(" and ")} ${n.length > 1 ? "are" : "is"} not used by ${a}. Passing it has no effect, so this is almost always a mistake.`;
259
252
  }
260
- function N(e) {
253
+ function D(e) {
261
254
  var t;
262
255
  return (t = e.flow) != null && t.walletConnect && !e.walletConnectProjectId ? "walletConnectProjectId is required when flow.walletConnect is on" : null;
263
256
  }
264
- function I(e) {
265
- return e.gatewayUrl === void 0 || K(e.gatewayUrl) ? null : `gatewayUrl must be an http(s) origin such as http://localhost:8000, with no path, got ${JSON.stringify(e.gatewayUrl)}`;
257
+ function A(e) {
258
+ return e.gatewayUrl === void 0 || z(e.gatewayUrl) ? null : `gatewayUrl must be an http(s) origin such as http://localhost:8000, with no path, got ${JSON.stringify(e.gatewayUrl)}`;
266
259
  }
267
- function K(e) {
260
+ function z(e) {
268
261
  let t;
269
262
  try {
270
263
  t = new URL(e);
@@ -274,19 +267,19 @@ function K(e) {
274
267
  return (t.protocol === "http:" || t.protocol === "https:") && t.pathname === "/" && t.search === "" && t.hash === "";
275
268
  }
276
269
  function ue(e) {
277
- return e !== null && !d(e) && !!e.publishableKey;
270
+ return e !== null && !u(e) && !!e.publishableKey;
278
271
  }
279
272
  function ye(e) {
280
- return e !== null && !d(e);
273
+ return e !== null && !u(e);
281
274
  }
282
275
  function pe({
283
276
  options: e,
284
277
  session: t,
285
278
  settled: a
286
279
  }) {
287
- return !a && t !== null && e !== null && d(e);
280
+ return !a && t !== null && e !== null && u(e);
288
281
  }
289
- function L(e, t, a) {
282
+ function N(e, t, a) {
290
283
  try {
291
284
  e == null || e(t, a);
292
285
  } catch (n) {
@@ -304,69 +297,69 @@ function p(e) {
304
297
  }
305
298
  return t.protocol === "https:" || t.protocol === "http:" ? e : void 0;
306
299
  }
307
- async function z({
300
+ async function J({
308
301
  api: e,
309
302
  options: t,
310
303
  emit: a
311
304
  }) {
312
305
  try {
313
- const n = await Q({ api: e, options: t }), { session: o, sessionPromoted: r } = await X({ api: e, sessionID: n });
306
+ const n = await X({ api: e, options: t }), { session: o, sessionPromoted: r } = await V({ api: e, sessionID: n });
314
307
  a("session.loaded", Z(o));
315
- const s = await V({
308
+ const s = await ee({
316
309
  api: e,
317
310
  transactionID: o.transactionID
318
311
  });
319
312
  return { ok: !0, session: o, sessionPromoted: r, linkedTransaction: s };
320
313
  } catch (n) {
321
- return { ok: !1, ...await J(n) };
314
+ return { ok: !1, ...await Q(n) };
322
315
  }
323
316
  }
324
- async function J(e) {
317
+ async function Q(e) {
325
318
  const t = e instanceof Error ? e.cause : void 0;
326
319
  if (!(t instanceof Response && t.status === 404))
327
320
  return {};
328
321
  try {
329
322
  const n = await t.json();
330
323
  return {
331
- failureURL: T(n == null ? void 0 : n.failureURL),
332
- cancelURL: T(n == null ? void 0 : n.cancelURL)
324
+ failureURL: C(n == null ? void 0 : n.failureURL),
325
+ cancelURL: C(n == null ? void 0 : n.cancelURL)
333
326
  };
334
327
  } catch {
335
328
  return {};
336
329
  }
337
330
  }
338
- function T(e) {
331
+ function C(e) {
339
332
  return typeof e == "string" ? p(e) : void 0;
340
333
  }
341
- async function Q({
334
+ async function X({
342
335
  api: e,
343
336
  options: t
344
337
  }) {
345
- return d(t) ? t.sessionID : (await e.createSession({
338
+ return u(t) ? t.sessionID : (await e.createSession({
346
339
  amount: t.transaction.amount,
347
340
  amountCurrency: t.transaction.currency,
348
341
  descriptor: t.transaction.descriptor,
349
342
  referenceNumber: t.transaction.referenceNumber
350
343
  })).sessionID;
351
344
  }
352
- async function X({
345
+ async function V({
353
346
  api: e,
354
347
  sessionID: t
355
348
  }) {
356
349
  const a = await e.getSession(t);
357
- return { session: a, sessionPromoted: R(a) };
350
+ return { session: a, sessionPromoted: I(a) };
358
351
  }
359
352
  function Z(e) {
360
353
  return {
361
354
  sessionID: e.sessionID,
362
355
  merchantName: e.merchantName,
363
- alreadyPromoted: R(e)
356
+ alreadyPromoted: I(e)
364
357
  };
365
358
  }
366
- function R(e) {
359
+ function I(e) {
367
360
  return !!e.transactionID;
368
361
  }
369
- async function V({
362
+ async function ee({
370
363
  api: e,
371
364
  transactionID: t
372
365
  }) {
@@ -378,7 +371,7 @@ async function V({
378
371
  return console.error("Failed to resolve the session transaction:", a), null;
379
372
  }
380
373
  }
381
- function E({
374
+ function P({
382
375
  message: e,
383
376
  reason: t,
384
377
  shouldEndCheckout: a,
@@ -398,7 +391,7 @@ function E({
398
391
  }
399
392
  };
400
393
  }
401
- const ee = {
394
+ const te = {
402
395
  "common.cancelTransaction": "Cancel Transaction",
403
396
  "common.cancel": "Cancel",
404
397
  "common.back": "Back",
@@ -473,17 +466,16 @@ const ee = {
473
466
  "kyc.lastNameLabel": "Last name",
474
467
  "kyc.lastNamePlaceholder": "Enter last name",
475
468
  "kyc.emailPlaceholder": "Enter email address",
476
- "kyc.streetLabel": "Address",
469
+ "kyc.streetLabel": "Address line 1",
477
470
  "kyc.streetPlaceholder": "Enter address",
478
- "kyc.cityLabel": "City",
479
- "kyc.cityPlaceholder": "Enter city",
480
- "kyc.subdivisionLabel": "Barangay",
481
- "kyc.subdivisionPlaceholder": "Enter barangay",
482
- "kyc.regionLabel": "Province",
483
- "kyc.regionPlaceholder": "Enter province",
484
- "kyc.regionSelectPlaceholder": "Select province",
485
- "kyc.postalCodeLabel": "ZIP or Postal code",
486
- "kyc.postalCodePlaceholder": "Enter ZIP or postal code",
471
+ "kyc.street2Label": "Address line 2 (optional)",
472
+ "kyc.street2Placeholder": "Enter address",
473
+ "kyc.regionLabel": "State or province",
474
+ "kyc.regionPlaceholder": "Enter state or province",
475
+ "kyc.cityLabel": "Town or city",
476
+ "kyc.cityPlaceholder": "Enter town or city",
477
+ "kyc.postalCodeLabel": "Postcode",
478
+ "kyc.postalCodePlaceholder": "Enter postcode",
487
479
  "kyc.walletAddressLabel": "Wallet address",
488
480
  "kyc.walletAddressPlaceholder": "Enter wallet address",
489
481
  "kyc.dateOfBirthLabel": "Date of birth",
@@ -491,6 +483,7 @@ const ee = {
491
483
  "kyc.dateAndPlaceOfBirthChoice": "Place and date of birth",
492
484
  "kyc.physicalAddressChoice": "Address",
493
485
  "kyc.cityOfBirthLabel": "City of birth",
486
+ "kyc.cityOfBirthPlaceholder": "Enter city",
494
487
  "kyc.nationalIdLabel": "ID number",
495
488
  "kyc.nationalIdPlaceholder": "Enter 16-digit ID number",
496
489
  "kyc.nationalIdChoice": "National ID number",
@@ -617,6 +610,7 @@ const ee = {
617
610
  "errors.assetNetworkRequired": "Choose a coin and network to continue.",
618
611
  "errors.notInitialized": "Checkout isn't ready yet. Please refresh the page and try again.",
619
612
  "errors.paymentCouldNotComplete": "Your payment could not be completed. Please try again and choose an available payment method.",
613
+ "errors.paymentShortRefundRequested": "Less than the full amount arrived, so this payment can't be completed. A refund of the amount received has been requested.",
620
614
  "errors.unableToCollectUnderpaid": "We couldn't set up the remaining balance. Please try again.",
621
615
  "errors.paymentTimedOut": "Your payment timed out. Please try again and choose an available payment method.",
622
616
  "errors.paymentStatusUnavailable": "We’re having trouble confirming your payment. If you’ve already sent it, it will still be picked up — keep this page open.",
@@ -644,34 +638,35 @@ const ee = {
644
638
  "validation.customerDetailsMissing": "Customer details are missing.",
645
639
  "validation.invalidOtp": "Please enter a valid 6-digit code.",
646
640
  "terms.notice": 'By continuing, you agree to Lydian <a href="https://lydian.com/privacy" target="_blank" rel="noopener noreferrer">Terms and Conditions</a> and understand your data will be processed according to the <a href="https://lydian.com/privacy" target="_blank" rel="noopener noreferrer">Privacy Notice</a>.'
647
- }, v = { en: ee }, U = "en";
648
- let O = U;
641
+ }, T = { en: te }, L = "en";
642
+ let R = L;
649
643
  function he() {
650
- return O;
644
+ return R;
651
645
  }
652
- function w(e, t) {
646
+ function h(e, t) {
653
647
  var n;
654
- const a = ((n = v[O]) == null ? void 0 : n[e]) ?? v[U][e] ?? e;
648
+ const a = ((n = T[R]) == null ? void 0 : n[e]) ?? T[L][e] ?? e;
655
649
  return t ? a.replace(
656
650
  /\{(\w+)\}/g,
657
651
  (o, r) => t[r] != null ? String(t[r]) : `{${r}}`
658
652
  ) : a;
659
653
  }
660
- function te(e) {
661
- return e === y.SUCCESS ? "succeeded" : e < y.PENDING && e !== y.KYC_VERIFICATION_PENDING && e !== y.COMPLIANCE_PENDING ? "failed" : "active";
654
+ function ae(e) {
655
+ return e === d.SUCCESS ? "succeeded" : e < d.PENDING && e !== d.KYC_VERIFICATION_PENDING && e !== d.COMPLIANCE_PENDING ? "failed" : "active";
662
656
  }
663
- function ae({
657
+ function ne({
664
658
  transaction: e,
665
659
  session: t
666
660
  }) {
667
661
  var o, r, s;
668
- const a = te(e.status);
662
+ const a = ae(e.status);
669
663
  if (a === "active")
670
664
  return null;
671
- if (a === "failed")
665
+ if (a === "failed") {
666
+ const i = e.status === d.PAYMENT_TIMEOUT && e.paymentStatus === j.PARTIALLY_PAID;
672
667
  return {
673
668
  outcome: a,
674
- message: w("errors.paymentCouldNotComplete"),
669
+ message: h(i ? "errors.paymentShortRefundRequested" : "errors.paymentCouldNotComplete"),
675
670
  failure: {
676
671
  shouldEndCheckout: !0,
677
672
  // Negative (non-KYC) status — cancelled / fraud / timeout.
@@ -680,8 +675,9 @@ function ae({
680
675
  redirectURL: p(t == null ? void 0 : t.failureURL)
681
676
  }
682
677
  };
678
+ }
683
679
  const n = (o = e.payments) == null ? void 0 : o.find(
684
- (i) => i.status === j.CONFIRMED
680
+ (i) => i.status === H.CONFIRMED
685
681
  );
686
682
  return {
687
683
  outcome: a,
@@ -701,13 +697,13 @@ function ae({
701
697
  }
702
698
  };
703
699
  }
704
- function ne() {
700
+ function oe() {
705
701
  let e = null;
706
702
  return {
707
703
  setOptions: (t) => {
708
704
  e = t;
709
705
  },
710
- emit: (t, a) => L(e == null ? void 0 : e.onEvent, t, a),
706
+ emit: (t, a) => N(e == null ? void 0 : e.onEvent, t, a),
711
707
  paymentFailed: (t, a) => {
712
708
  var n;
713
709
  return (n = e == null ? void 0 : e.paymentFailedListener) == null ? void 0 : n.call(e, t, a);
@@ -722,7 +718,7 @@ function ne() {
722
718
  }
723
719
  };
724
720
  }
725
- class oe extends HTMLElement {
721
+ class re extends HTMLElement {
726
722
  constructor() {
727
723
  super(), this.engine = null, this.engineLoadPromise = null, this.isTornDown = !1, this.shadow = this.attachShadow({ mode: "open" });
728
724
  }
@@ -732,7 +728,7 @@ class oe extends HTMLElement {
732
728
  this.isTornDown = !1;
733
729
  }
734
730
  async initialize(t) {
735
- const a = re(t), n = se({ api: a, options: t }), o = await this.loadEngine(t, n);
731
+ const a = se(t), n = ie({ api: a, options: t }), o = await this.loadEngine(t, n);
736
732
  !o || this.isTornDown || (this.engine = o, await o.initialize(t, { api: a, sessionLoad: n }));
737
733
  }
738
734
  async loadEngine(t, a) {
@@ -760,7 +756,7 @@ class oe extends HTMLElement {
760
756
  // Not started in the constructor: a page can carry the tag and never check out.
761
757
  // Overlapping initialize() calls share one download.
762
758
  getOrLoadEngine() {
763
- return this.engineLoadPromise ?? (this.engineLoadPromise = import("./mountEngine-DURf9AtR.js").then((t) => t.m).then((t) => {
759
+ return this.engineLoadPromise ?? (this.engineLoadPromise = import("./mountEngine-DLOTZV_w.js").then((t) => t.m).then((t) => {
764
760
  const a = t.mountCheckoutEngine({
765
761
  host: this,
766
762
  shadowRoot: this.shadow
@@ -793,9 +789,9 @@ class oe extends HTMLElement {
793
789
  const n = await a;
794
790
  if (this.isDismissedByHost)
795
791
  return;
796
- const o = ne();
792
+ const o = oe();
797
793
  o.setOptions(t);
798
- const r = n.ok && n.linkedTransaction ? ae({
794
+ const r = n.ok && n.linkedTransaction ? ne({
799
795
  transaction: n.linkedTransaction,
800
796
  session: n.session
801
797
  }) : null;
@@ -816,7 +812,7 @@ class oe extends HTMLElement {
816
812
  return;
817
813
  }
818
814
  if (!n.ok && n.failureURL) {
819
- const g = w("errors.unableToCreateSession"), b = E({
815
+ const g = h("errors.unableToCreateSession"), b = P({
820
816
  message: g,
821
817
  reason: "sessionExpired",
822
818
  shouldEndCheckout: !0,
@@ -825,7 +821,7 @@ class oe extends HTMLElement {
825
821
  o.emit("payment.failed", b.event), o.paymentFailed(g, b.failure);
826
822
  return;
827
823
  }
828
- const s = w("errors.checkoutUnavailable"), i = E({
824
+ const s = h("errors.checkoutUnavailable"), i = P({
829
825
  message: s,
830
826
  reason: "error",
831
827
  shouldEndCheckout: !0,
@@ -839,38 +835,38 @@ class oe extends HTMLElement {
839
835
  t == null || t.teardown(), t == null || t.unmount(), this.engine = null, this.engineLoadPromise = null;
840
836
  }
841
837
  }
842
- function re(e) {
843
- return new q(
844
- H(e),
845
- d(e) ? void 0 : e.publishableKey
838
+ function se(e) {
839
+ return new G(
840
+ K(e),
841
+ u(e) ? void 0 : e.publishableKey
846
842
  );
847
843
  }
848
- function se({
844
+ function ie({
849
845
  api: e,
850
846
  options: t
851
847
  }) {
852
- return z({
848
+ return J({
853
849
  api: e,
854
850
  options: t,
855
- emit: (a, n) => L(t.onEvent, a, n)
851
+ emit: (a, n) => N(t.onEvent, a, n)
856
852
  });
857
853
  }
858
- customElements.get("lydian-checkout") || customElements.define("lydian-checkout", oe);
854
+ customElements.get("lydian-checkout") || customElements.define("lydian-checkout", re);
859
855
  function f() {
860
856
  return document.querySelector("lydian-checkout");
861
857
  }
862
- async function ie(e) {
858
+ async function ce(e) {
863
859
  if (!e.publishableKey || !e.transaction.amount || !e.transaction.currency)
864
860
  throw new Error("SDK initialization requires publishableKey and a transaction");
865
- const t = N(e);
861
+ const t = D(e);
866
862
  if (t)
867
863
  throw new Error(t);
868
- const a = I(e);
864
+ const a = A(e);
869
865
  if (a)
870
866
  throw new Error(a);
871
- if (!F(e.transaction.currency))
872
- throw new Error("Invalid value for currency, valid values are: " + S.join(", "));
873
- const n = A({
867
+ if (!U(e.transaction.currency))
868
+ throw new Error("Invalid value for currency, valid values are: " + E.join(", "));
869
+ const n = S({
874
870
  options: e,
875
871
  unsupportedKeys: ["sessionID"],
876
872
  entryPoint: "init"
@@ -879,16 +875,16 @@ async function ie(e) {
879
875
  throw new Error(n);
880
876
  await f().initialize(e);
881
877
  }
882
- async function ce(e) {
878
+ async function le(e) {
883
879
  if (!e.sessionID)
884
880
  throw new Error("initExistingSession requires a sessionID");
885
- const t = N(e);
881
+ const t = D(e);
886
882
  if (t)
887
883
  throw new Error(t);
888
- const a = I(e);
884
+ const a = A(e);
889
885
  if (a)
890
886
  throw new Error(a);
891
- const n = A({
887
+ const n = S({
892
888
  options: e,
893
889
  unsupportedKeys: ["publishableKey", "transaction"],
894
890
  entryPoint: "initExistingSession"
@@ -897,31 +893,31 @@ async function ce(e) {
897
893
  throw new Error(n);
898
894
  await f().initialize(e);
899
895
  }
900
- async function le(e) {
896
+ async function de(e) {
901
897
  await f().updateTransaction(e);
902
898
  }
903
- window.Lydian = { init: ie, initExistingSession: ce, updateTransaction: le };
899
+ window.Lydian = { init: ce, initExistingSession: le, updateTransaction: de };
904
900
  export {
905
- W as G,
906
- de as P,
907
- y as T,
908
- j as a,
901
+ O as G,
902
+ j as P,
903
+ d as T,
904
+ H as a,
909
905
  ye as b,
910
- S as c,
911
- X as d,
906
+ E as c,
907
+ V as d,
912
908
  Z as e,
913
- V as f,
909
+ ee as f,
914
910
  he as g,
915
- d as h,
916
- F as i,
917
- te as j,
918
- ae as k,
919
- R as l,
911
+ u as h,
912
+ U as i,
913
+ ae as j,
914
+ ne as k,
915
+ I as l,
920
916
  pe as m,
921
- E as n,
917
+ P as n,
922
918
  ue as o,
923
- ne as p,
924
- Q as r,
919
+ oe as p,
920
+ X as r,
925
921
  p as s,
926
- w as t
922
+ h as t
927
923
  };
@@ -1,5 +1,5 @@
1
- import { d as Si, g as wi } from "./mountEngine-DURf9AtR.js";
2
- import { r as Ti } from "./index-CF-D_uxJ.js";
1
+ import { d as Si, g as wi } from "./mountEngine-DLOTZV_w.js";
2
+ import { r as Ti } from "./index-1dDAk3NM.js";
3
3
  function Pi(r, u) {
4
4
  for (var f = 0; f < u.length; f++) {
5
5
  const h = u[f];