@ranty/ranty-sdk 3.16.0-beta.0 → 3.16.0-beta.1

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.
@@ -925,7 +925,7 @@ function ie(t) {
925
925
  */
926
926
  var by;
927
927
  ((by = window.HTMLSlotElement) === null || by === void 0 ? void 0 : by.prototype.assignedElements) != null;
928
- const w8 = "@ranty/ranty-sdk", x8 = "3.16.0-beta.0", _8 = "Ranty sdk", C8 = "dist/index.js", B8 = {
928
+ const w8 = "@ranty/ranty-sdk", x8 = "3.16.0-beta.1", _8 = "Ranty sdk", C8 = "dist/index.js", B8 = {
929
929
  ".": "./dist/index.js"
930
930
  }, E8 = "types/index.d.ts", k8 = [
931
931
  "dist",
@@ -3390,7 +3390,7 @@ RA.getInstance = GB.getInstance;
3390
3390
  return n.ReCaptchaInstance;
3391
3391
  } });
3392
3392
  })(KB);
3393
- const QT = () => Pt.getConfig().VITE_DATADOG_ENV !== "production", W = {
3393
+ const QT = () => jt.getConfig().VITE_DATADOG_ENV !== "production", W = {
3394
3394
  info: (t, e = {}) => {
3395
3395
  QT() && console.log(t, e), C5.logger.info(t, e);
3396
3396
  },
@@ -3410,7 +3410,7 @@ class MT {
3410
3410
  }
3411
3411
  createTokenCaptcha(e) {
3412
3412
  return de(this, null, function* () {
3413
- if (Pt.getConfig().VITE_ENV === "sandbox")
3413
+ if (jt.getConfig().VITE_ENV === "sandbox")
3414
3414
  return sessionStorage.setItem("key", e), e;
3415
3415
  const s = yield (yield KB.load(e)).execute("submit");
3416
3416
  return sessionStorage.setItem("key", e), sessionStorage.setItem("token", s), s;
@@ -3419,7 +3419,7 @@ class MT {
3419
3419
  signer(e, n, s, r, i = 3) {
3420
3420
  return de(this, null, function* () {
3421
3421
  try {
3422
- const o = yield this.createTokenCaptcha(e), { data: a } = yield Pt.instance.post(
3422
+ const o = yield this.createTokenCaptcha(e), { data: a } = yield jt.instance.post(
3423
3423
  "/sdk/signer",
3424
3424
  {},
3425
3425
  { headers: { "x-recaptcha-token": o } }
@@ -3517,7 +3517,7 @@ const BA = new MT(), N_ = (t = !1) => {
3517
3517
  return s.response.status >= 500 || ((r = s.response) == null ? void 0 : r.status) === 401 || s.code === "ECONNABORTED";
3518
3518
  }
3519
3519
  });
3520
- const n = Pt.getConfig();
3520
+ const n = jt.getConfig();
3521
3521
  return e.interceptors.request.use(
3522
3522
  (s) => de(void 0, null, function* () {
3523
3523
  const r = BA.region === n.VITE_COGNITO_REGION_2 ? n.VITE_API_RANTY_DOMAIN_API_REGION_2 : n.VITE_API_RANTY_DOMAIN_API_REGION_1;
@@ -3674,7 +3674,7 @@ const BA = new MT(), N_ = (t = !1) => {
3674
3674
  }, L_ = (t) => {
3675
3675
  if (!(t in dv))
3676
3676
  throw new Error(`Environment ${t} not found`);
3677
- }, Pt = {
3677
+ }, jt = {
3678
3678
  instance: void 0,
3679
3679
  instanceWithRetries: void 0,
3680
3680
  currentEnvironment: void 0,
@@ -3686,7 +3686,7 @@ const BA = new MT(), N_ = (t = !1) => {
3686
3686
  L_(t), this.currentEnvironment = t, this.instance = N_(!1), this.instanceWithRetries = N_(!0);
3687
3687
  }
3688
3688
  }, zT = (t, e, n) => de(void 0, null, function* () {
3689
- return (yield Pt.instanceWithRetries.post(
3689
+ return (yield jt.instanceWithRetries.post(
3690
3690
  "/sdk/a2a/save_token",
3691
3691
  {
3692
3692
  code: t,
@@ -3696,9 +3696,9 @@ const BA = new MT(), N_ = (t = !1) => {
3696
3696
  {}
3697
3697
  )).data;
3698
3698
  }), WB = (t, e, n) => de(void 0, null, function* () {
3699
- return (yield Pt.instanceWithRetries.delete(`/sdk/a2a/delete_token/${t}/${e}/${n}`)).data;
3699
+ return (yield jt.instanceWithRetries.delete(`/sdk/a2a/delete_token/${t}/${e}/${n}`)).data;
3700
3700
  }), YB = (t, e) => de(void 0, null, function* () {
3701
- return (yield Pt.instanceWithRetries.post(
3701
+ return (yield jt.instanceWithRetries.post(
3702
3702
  "/sdk/a2a/payments/direct",
3703
3703
  {
3704
3704
  payment_request_id: t,
@@ -3707,9 +3707,9 @@ const BA = new MT(), N_ = (t = !1) => {
3707
3707
  {}
3708
3708
  )).data;
3709
3709
  }), JB = (t) => de(void 0, null, function* () {
3710
- return (yield Pt.instanceWithRetries.get(`/sdk/a2a/get_pcps/${t}`, {})).data;
3710
+ return (yield jt.instanceWithRetries.get(`/sdk/a2a/get_pcps/${t}`, {})).data;
3711
3711
  }), XB = (t) => de(void 0, null, function* () {
3712
- return (yield Pt.instanceWithRetries.get(`/sdk/a2a/get_a2a_data/${t}?new_code_challenges=true`)).data;
3712
+ return (yield jt.instanceWithRetries.get(`/sdk/a2a/get_a2a_data/${t}?new_code_challenges=true`)).data;
3713
3713
  });
3714
3714
  var HT = "0123456789abcdefghijklmnopqrstuvwxyz";
3715
3715
  function sa(t) {
@@ -6635,7 +6635,7 @@ function YU(t) {
6635
6635
  }
6636
6636
  const Bw = (t) => de(void 0, null, function* () {
6637
6637
  try {
6638
- const { data: e } = yield Pt.instance.post("/sdk/payments/direct", t, {});
6638
+ const { data: e } = yield jt.instance.post("/sdk/payments/direct", t, {});
6639
6639
  return e;
6640
6640
  } catch (e) {
6641
6641
  if (e) {
@@ -6663,7 +6663,7 @@ const Bw = (t) => de(void 0, null, function* () {
6663
6663
  ];
6664
6664
  }, Ew = (t, e, n, s = "manual_input") => de(void 0, null, function* () {
6665
6665
  var N, q, D, K;
6666
- const r = Pt.getConfig(), { id: i, additional_info: o, external_payment_id: a, flag: d } = t, { creditNumber: l, codSeg: c, expired: u, dni: h, passport: p, email: m, name: y } = e, x = yield o6(
6666
+ const r = jt.getConfig(), { id: i, additional_info: o, external_payment_id: a, flag: d } = t, { creditNumber: l, codSeg: c, expired: u, dni: h, passport: p, email: m, name: y } = e, x = yield o6(
6667
6667
  r.VITE_ENCRYPT_DIRECT_PUBLIC_KEY,
6668
6668
  `${l.replaceAll(" ", "")}:${c}:${u}`
6669
6669
  ), v = h ? "DNI" : "PASAPORTE", _ = h || p || "", U = (q = (N = _a.settings.customerProperties) == null ? void 0 : N.validate_card) != null ? q : !1;
@@ -6700,17 +6700,17 @@ const Bw = (t) => de(void 0, null, function* () {
6700
6700
  payment_input: s
6701
6701
  };
6702
6702
  }), a5 = (t, e) => {
6703
- const n = Pt.getConfig();
6703
+ const n = jt.getConfig();
6704
6704
  let s = "";
6705
6705
  e ? s = n.VITE_ENCRYPT_DIRECT_PUBLIC_KEY : s = n.VITE_ENCRYPT_VALUES_PUBLIC_KEY;
6706
6706
  const r = new t6();
6707
6707
  return r.setPublicKey(s), r.encrypt(t);
6708
6708
  }, Ch = (t, e = !0) => de(void 0, null, function* () {
6709
- const n = e ? "" : "?legacy=false", s = yield Pt.instanceWithRetries.get(`/sdk/payments/${t}${n}`, {});
6710
- return e ? s.data.response : XU(s.data.response);
6709
+ const n = jt.getConfig().VITE_ENV === "sandbox", r = !e || n ? "?legacy=false" : "", i = yield jt.instanceWithRetries.get(`/sdk/payments/${t}${r}`, {});
6710
+ return e ? i.data.response : XU(i.data.response);
6711
6711
  }), a6 = (t) => de(void 0, null, function* () {
6712
6712
  try {
6713
- const { data: e } = yield Pt.instance.post("/sdk/payment", t, {});
6713
+ const { data: e } = yield jt.instance.post("/sdk/payment", t, {});
6714
6714
  return e;
6715
6715
  } catch (e) {
6716
6716
  const { message: n, code: s } = e;
@@ -6718,7 +6718,7 @@ const Bw = (t) => de(void 0, null, function* () {
6718
6718
  }
6719
6719
  }), d6 = (t, e, n, s = "manual_input") => de(void 0, null, function* () {
6720
6720
  var q, D;
6721
- const r = Pt.getConfig(), { id: i, additional_info: o, external_payment_id: a, transactions: d } = t, { creditNumber: l, codSeg: c, expired: u, dni: h, passport: p, email: m, name: y } = e, x = t.external_payment_datetime ? t.external_payment_datetime : "", v = yield o6(
6721
+ const r = jt.getConfig(), { id: i, additional_info: o, external_payment_id: a, transactions: d } = t, { creditNumber: l, codSeg: c, expired: u, dni: h, passport: p, email: m, name: y } = e, x = t.external_payment_datetime ? t.external_payment_datetime : "", v = yield o6(
6722
6722
  r.VITE_ENCRYPT_DIRECT_PUBLIC_KEY,
6723
6723
  `${l.replaceAll(" ", "")}:${c}:${u}`
6724
6724
  ), _ = h ? "DNI" : "PASAPORTE", U = h || p || "", N = (D = (q = _a.settings.customerProperties) == null ? void 0 : q.validate_card) != null ? D : !1;
@@ -6784,7 +6784,7 @@ const Bw = (t) => de(void 0, null, function* () {
6784
6784
  additional_info: t.additional_info || { platform: "hosted-checkout" }
6785
6785
  });
6786
6786
  }, ZU = (t) => de(void 0, null, function* () {
6787
- return (yield Pt.instanceWithRetries.get(`/sdk/scof/payment_request/${t}`, {})).data.response;
6787
+ return (yield jt.instanceWithRetries.get(`/sdk/scof/payment_request/${t}`, {})).data.response;
6788
6788
  }), $U = (t) => de(void 0, null, function* () {
6789
6789
  const { status: e, payment_id: n, payment_type: s } = t, r = {
6790
6790
  error: !0,
@@ -6831,10 +6831,10 @@ const Bw = (t) => de(void 0, null, function* () {
6831
6831
  const { payment_type: e } = t;
6832
6832
  return [As.ECOMMERCE, As.MIT].includes(e);
6833
6833
  }, l6 = (t) => de(void 0, null, function* () {
6834
- return (yield Pt.instanceWithRetries.get(`/sdk/scof/get_scof_data/${t}`)).data;
6834
+ return (yield jt.instanceWithRetries.get(`/sdk/scof/get_scof_data/${t}`)).data;
6835
6835
  }), tj = "en_US", c6 = (t) => de(void 0, null, function* () {
6836
6836
  const { pos_id: e, mail: n, encPaymentInstrument: s, userId: r, docType: i, docNumber: o, cardBrand: a } = t;
6837
- return (yield Pt.instanceWithRetries.post(
6837
+ return (yield jt.instanceWithRetries.post(
6838
6838
  `/sdk/scof/provisioning/${e}`,
6839
6839
  {
6840
6840
  mail: n,
@@ -6848,26 +6848,26 @@ const Bw = (t) => de(void 0, null, function* () {
6848
6848
  {}
6849
6849
  )).data;
6850
6850
  }), A6 = (t) => de(void 0, null, function* () {
6851
- return (yield Pt.instanceWithRetries.post(
6851
+ return (yield jt.instanceWithRetries.post(
6852
6852
  "/sdk/scof/checkout",
6853
6853
  je({}, t),
6854
6854
  {}
6855
6855
  )).data;
6856
6856
  }), u6 = (t) => de(void 0, null, function* () {
6857
- return (yield Pt.instanceWithRetries.post(
6857
+ return (yield jt.instanceWithRetries.post(
6858
6858
  `/sdk/scof/checkout?isAsync=${!1}`,
6859
6859
  je({}, t),
6860
6860
  {}
6861
6861
  )).data;
6862
6862
  }), p6 = (t, e) => de(void 0, null, function* () {
6863
- return (yield Pt.instanceWithRetries.delete(
6863
+ return (yield jt.instanceWithRetries.delete(
6864
6864
  `/sdk/scof/scofDeleteTokenById/${t}/${e}`,
6865
6865
  {}
6866
6866
  )).data;
6867
6867
  }), nj = (t) => de(void 0, null, function* () {
6868
6868
  if (t.length > 0)
6869
6869
  try {
6870
- const { data: e } = yield Pt.instance.get("/sdk/bin/" + t, {});
6870
+ const { data: e } = yield jt.instance.get("/sdk/bin/" + t, {});
6871
6871
  return e;
6872
6872
  } catch (e) {
6873
6873
  if (e) {
@@ -6990,7 +6990,7 @@ function cj(t, e) {
6990
6990
  }
6991
6991
  const Aj = (t) => de(void 0, null, function* () {
6992
6992
  try {
6993
- const e = yield Pt.instance.post("sdk/click2pay/checkout", t, {});
6993
+ const e = yield jt.instance.post("sdk/click2pay/checkout", t, {});
6994
6994
  return W.info("makeC2PCheckout", { tag: "MAKE_C2P_CHECKOUT", contextObject: e }), e.data;
6995
6995
  } catch (e) {
6996
6996
  throw W.error("makeC2PCheckout error", { tag: "MAKE_C2P_CHECKOUT_ERROR" }, e), e;
@@ -10219,10 +10219,10 @@ function vD(t, e, n, s) {
10219
10219
  }
10220
10220
  const Fp = qR(vD);
10221
10221
  qF(jo(), "DD_LOGS", Fp);
10222
- const wD = "@ranty/ranty-sdk", xD = "3.16.0-beta.0", _D = 3, CD = !0, BD = {
10222
+ const wD = "@ranty/ranty-sdk", xD = "3.16.0-beta.1", _D = 3, CD = !0, BD = {
10223
10223
  "": {
10224
10224
  name: "@ranty/ranty-sdk",
10225
- version: "3.16.0-beta.0",
10225
+ version: "3.16.0-beta.1",
10226
10226
  license: "ISC",
10227
10227
  dependencies: {
10228
10228
  "@datadog/browser-logs": "^6.17.0",
@@ -32381,7 +32381,7 @@ const wD = "@ranty/ranty-sdk", xD = "3.16.0-beta.0", _D = 3, CD = !0, BD = {
32381
32381
  }), SD = (t) => {
32382
32382
  if (ID())
32383
32383
  return Fp.init(kD(t)), Fp.logger.setContext({ version: ED.version }), Fp;
32384
- }, ID = () => !(Pt.getConfig().VITE_ENV === "sandbox" || Pt.getConfig().VITE_ENV === "production" && window.location.hostname === "localhost"), C5 = Fp;
32384
+ }, ID = () => !(jt.getConfig().VITE_ENV === "sandbox" || jt.getConfig().VITE_ENV === "production" && window.location.hostname === "localhost"), C5 = Fp;
32385
32385
  class TD {
32386
32386
  constructor() {
32387
32387
  this.errorEvent = new Event("service-error");
@@ -32440,7 +32440,7 @@ const UD = new TD(), jD = [
32440
32440
  class Js {
32441
32441
  static getSettingsCircuitBreaker(e) {
32442
32442
  return de(this, null, function* () {
32443
- return e ? (yield Pt.instanceWithRetries.get(`/sdk/settings/hosted/${e}`, {})).data : fE;
32443
+ return e ? (yield jt.instanceWithRetries.get(`/sdk/settings/hosted/${e}`, {})).data : fE;
32444
32444
  });
32445
32445
  }
32446
32446
  }
@@ -32452,7 +32452,7 @@ const I0 = (t) => de(void 0, null, function* () {
32452
32452
  Js.currentSetting = fE[0];
32453
32453
  return;
32454
32454
  }
32455
- const e = Pt.getConfig().VITE_ENV === "sandbox" ? jD : yield Js.getSettingsCircuitBreaker(t.additional_info.platform.toLowerCase());
32455
+ const e = jt.getConfig().VITE_ENV === "sandbox" ? jD : yield Js.getSettingsCircuitBreaker(t.additional_info.platform.toLowerCase());
32456
32456
  Js.currentSetting = e.map((n) => n)[0];
32457
32457
  });
32458
32458
  class Yn {
@@ -32512,7 +32512,7 @@ const mE = (t) => {
32512
32512
  const e = (o = (i = t == null ? void 0 : t.payment_settings) == null ? void 0 : i.payment_types.ecommerce) == null ? void 0 : o.payment_inputs.card_not_present, n = (d = (a = t == null ? void 0 : t.payment_settings) == null ? void 0 : a.payment_types.ecommerce) == null ? void 0 : d.payment_inputs.manual_input, s = (u = (c = (l = t == null ? void 0 : t.payment_settings) == null ? void 0 : l.payment_types) == null ? void 0 : c.payment_link) == null ? void 0 : u.payment_inputs.card_not_present, r = (m = (p = (h = t == null ? void 0 : t.payment_settings) == null ? void 0 : h.payment_types) == null ? void 0 : p.payment_link) == null ? void 0 : m.payment_inputs.manual_input;
32513
32513
  return !!((e || n || s || r) && Yn.sonqoCardPaymentIsActive && Yn.manualInput);
32514
32514
  }, Mw = (t) => (Yn.validateQRCircuitBreaker(t), (Yn.coelsaQRIsActive || Yn.sonqoQRIsActive) && Yn.wallet && Js.allowWallet), zw = (t) => (Yn.paymentInputsEnabled(t), Yn.accountToAccount && t.payment_type === As.ECOMMERCE), wv = (t) => (Yn.paymentInputsEnabled(t), Yn.cardOnFile && t.payment_type === As.ECOMMERCE), Xs = (t, e = "payment_request", n = !1) => de(void 0, null, function* () {
32515
- const i = `/sdk/${e === "token" ? "payment-link" : "payment_request"}/${t}${n && e === "payment_request" ? "?legacy=false" : ""}`, o = yield Pt.instanceWithRetries.get(i, {}), a = e === "token" ? {
32515
+ const i = `/sdk/${e === "token" ? "payment-link" : "payment_request"}/${t}${n && e === "payment_request" ? "?legacy=false" : ""}`, o = yield jt.instanceWithRetries.get(i, {}), a = e === "token" ? {
32516
32516
  data: {
32517
32517
  response: o.data
32518
32518
  }
@@ -32582,7 +32582,7 @@ const mE = (t) => {
32582
32582
  };
32583
32583
  xv.getInstallmentPlans = (t, e, n) => de(void 0, null, function* () {
32584
32584
  try {
32585
- const { data: s } = yield Pt.instanceWithRetries.get("/sdk/installment/stores/" + void 0, {
32585
+ const { data: s } = yield jt.instanceWithRetries.get("/sdk/installment/stores/" + void 0, {
32586
32586
  params: {
32587
32587
  paymentRequestId: t,
32588
32588
  platform: e,
@@ -32664,7 +32664,7 @@ $l.remainingTime = 0;
32664
32664
  $l.pollingServiceInstance = new $l();
32665
32665
  let hn = $l;
32666
32666
  const T0 = (t) => de(void 0, null, function* () {
32667
- return Object.values(t).some((s) => s === void 0) ? [] : (Pt.getConfig().VITE_ENV === "sandbox" ? { data: [] } : yield Pt.instanceWithRetries.get("/sdk/promotions", {
32667
+ return Object.values(t).some((s) => s === void 0) ? [] : (jt.getConfig().VITE_ENV === "sandbox" ? { data: [] } : yield jt.instanceWithRetries.get("/sdk/promotions", {
32668
32668
  params: t
32669
32669
  })).data;
32670
32670
  });
@@ -41967,7 +41967,7 @@ const Ap = hA, ri = class extends EventTarget {
41967
41967
  }
41968
41968
  static getSignedUrl() {
41969
41969
  return de(this, null, function* () {
41970
- const e = Pt.getConfig(), n = BA.region === e.VITE_COGNITO_REGION_1 ? e.VITE_COGNITO_REGION_1 : e.VITE_COGNITO_REGION_2, s = n === e.VITE_COGNITO_REGION_1 ? e.VITE_IDENTITY_POOL_ID_1 : e.VITE_IDENTITY_POOL_ID_2, r = "execute-api", i = BA.region === e.VITE_COGNITO_REGION_1 ? `${e.VITE_WS_DOMAIN_REGION_1}/notify` : `${e.VITE_WS_DOMAIN_REGION_2}/notify`;
41970
+ const e = jt.getConfig(), n = BA.region === e.VITE_COGNITO_REGION_1 ? e.VITE_COGNITO_REGION_1 : e.VITE_COGNITO_REGION_2, s = n === e.VITE_COGNITO_REGION_1 ? e.VITE_IDENTITY_POOL_ID_1 : e.VITE_IDENTITY_POOL_ID_2, r = "execute-api", i = BA.region === e.VITE_COGNITO_REGION_1 ? `${e.VITE_WS_DOMAIN_REGION_1}/notify` : `${e.VITE_WS_DOMAIN_REGION_2}/notify`;
41971
41971
  U0.configure({ identityPoolId: s, identityPoolRegion: n, identityPoolService: r });
41972
41972
  const o = Vv.essentialCredentials(yield Vv.currentCredentials());
41973
41973
  return OO.signUrl(
@@ -42023,7 +42023,7 @@ ri.webSocketServiceInstance = new ri();
42023
42023
  let Et = ri;
42024
42024
  const oM = () => de(void 0, null, function* () {
42025
42025
  try {
42026
- const { data: t } = yield Pt.instance.get("/sdk/version");
42026
+ const { data: t } = yield jt.instance.get("/sdk/version");
42027
42027
  return t;
42028
42028
  } catch (t) {
42029
42029
  console.log(t);
@@ -43578,7 +43578,7 @@ var i4 = /* @__PURE__ */ ((t) => (t.CARD_PAYMENT = "card_payment", t.TRANSFER_PA
43578
43578
  (o = t[i]) && (r = (s ? o(e, n, r) : o(r)) || r);
43579
43579
  return s && r && o9(e, n, r), r;
43580
43580
  };
43581
- const jt = "payfac-context", nf = "payfac-sdk";
43581
+ const Pt = "payfac-context", nf = "payfac-sdk";
43582
43582
  let Co = class t extends Ve {
43583
43583
  constructor() {
43584
43584
  super(...arguments), this.mode = "default", this.env = "production", this.publicKey = "", this.paymentRequestId = "", this.isEmbedded = "true", this.paymentSync = "false", this.paymentLinkId = "", this.payfacContext = { isReady: !1 }, this.messageErrorDefault = {
@@ -43590,7 +43590,7 @@ let Co = class t extends Ve {
43590
43590
  args: () => [this.publicKey],
43591
43591
  task: () => de(this, null, function* () {
43592
43592
  var e, n;
43593
- Pt.setConfig(this.env), SD(Pt.getConfig()), this.payfacContext.config = Pt.getConfig(), this.payfacContext.isEmbedded = this.isEmbedded === "true", this.payfacContext.paymentSync = this.paymentSync === "true" || this.env === "sandbox" || this.paymentLinkId !== "", this.payfacContext.paymentLinkId = this.paymentLinkId, this.payfacContext.context = (e = this.mode) == null ? void 0 : e.toUpperCase();
43593
+ jt.setConfig(this.env), SD(jt.getConfig()), this.payfacContext.config = jt.getConfig(), this.payfacContext.isEmbedded = this.isEmbedded === "true", this.payfacContext.paymentSync = this.paymentSync === "true" || this.env === "sandbox" || this.paymentLinkId !== "", this.payfacContext.paymentLinkId = this.paymentLinkId, this.payfacContext.context = (e = this.mode) == null ? void 0 : e.toUpperCase();
43594
43594
  try {
43595
43595
  const s = yield BA.createToken(
43596
43596
  this.publicKey,
@@ -43598,7 +43598,7 @@ let Co = class t extends Ve {
43598
43598
  this.payfacContext.isEmbedded,
43599
43599
  this.paymentRequestId || this.paymentLinkId
43600
43600
  );
43601
- if ((!this.payfacContext.isEmbedded || this.env !== "sandbox") && (yield aM(this.mode.toUpperCase(), this.payfacContext.isEmbedded, this.paymentRequestId)), this.payfacContext.token = s == null ? void 0 : s.access_token, yield this.getPaymentRequest(), !this.payfacContext.paymentRequest && this.mode !== "a2a_feedback") {
43601
+ if (!this.payfacContext.isEmbedded && this.env !== "sandbox" && (yield aM(this.mode.toUpperCase(), this.payfacContext.isEmbedded, this.paymentRequestId)), this.payfacContext.token = s == null ? void 0 : s.access_token, yield this.getPaymentRequest(), !this.payfacContext.paymentRequest && this.mode !== "a2a_feedback") {
43602
43602
  const r = wU("payment-request-not-found");
43603
43603
  throw this.messageError = {
43604
43604
  title: r.title,
@@ -43760,7 +43760,7 @@ Ia([
43760
43760
  I({ type: String })
43761
43761
  ], Co.prototype, "paymentLinkId", 2);
43762
43762
  Ia([
43763
- tr({ context: jt }),
43763
+ tr({ context: Pt }),
43764
43764
  ie()
43765
43765
  ], Co.prototype, "payfacContext", 2);
43766
43766
  Co = Ia([
@@ -43849,7 +43849,7 @@ Ta([
43849
43849
  I({ type: Object })
43850
43850
  ], Bo.prototype, "stateStatus", 2);
43851
43851
  Ta([
43852
- Ie({ context: jt, subscribe: !0 }),
43852
+ Ie({ context: Pt, subscribe: !0 }),
43853
43853
  ie()
43854
43854
  ], Bo.prototype, "payfacContext", 2);
43855
43855
  Bo = Ta([
@@ -44402,7 +44402,7 @@ Ua([
44402
44402
  ie()
44403
44403
  ], Oi.prototype, "stateStatus", 2);
44404
44404
  Ua([
44405
- Ie({ context: jt, subscribe: !0 }),
44405
+ Ie({ context: Pt, subscribe: !0 }),
44406
44406
  ie()
44407
44407
  ], Oi.prototype, "payfacContext", 2);
44408
44408
  Oi = Ua([
@@ -45386,7 +45386,7 @@ Pa([
45386
45386
  ie()
45387
45387
  ], Li.prototype, "stateScofStatus", 2);
45388
45388
  Pa([
45389
- Ie({ context: jt, subscribe: !0 }),
45389
+ Ie({ context: Pt, subscribe: !0 }),
45390
45390
  ie()
45391
45391
  ], Li.prototype, "payfacContext", 2);
45392
45392
  Pa([
@@ -46016,7 +46016,7 @@ di([
46016
46016
  ie()
46017
46017
  ], hr.prototype, "stateScofProps", 2);
46018
46018
  di([
46019
- Ie({ context: jt, subscribe: !0 }),
46019
+ Ie({ context: Pt, subscribe: !0 }),
46020
46020
  ie()
46021
46021
  ], hr.prototype, "payfacContext", 2);
46022
46022
  di([
@@ -46325,7 +46325,7 @@ Fa([
46325
46325
  ie()
46326
46326
  ], Qi.prototype, "stateScof", 2);
46327
46327
  Fa([
46328
- Ie({ context: jt, subscribe: !0 }),
46328
+ Ie({ context: Pt, subscribe: !0 }),
46329
46329
  ie()
46330
46330
  ], Qi.prototype, "payfacContext", 2);
46331
46331
  Fa([
@@ -46581,7 +46581,7 @@ Kd([
46581
46581
  ie()
46582
46582
  ], ko.prototype, "stateHolderScof", 2);
46583
46583
  Kd([
46584
- Ie({ context: jt, subscribe: !0 }),
46584
+ Ie({ context: Pt, subscribe: !0 }),
46585
46585
  ie()
46586
46586
  ], ko.prototype, "payfacContext", 2);
46587
46587
  ko = Kd([
@@ -46766,7 +46766,7 @@ J0([
46766
46766
  ie()
46767
46767
  ], KA.prototype, "stateScof", 2);
46768
46768
  J0([
46769
- Ie({ context: jt, subscribe: !0 }),
46769
+ Ie({ context: Pt, subscribe: !0 }),
46770
46770
  ie()
46771
46771
  ], KA.prototype, "payfacContext", 2);
46772
46772
  KA = J0([
@@ -46925,7 +46925,7 @@ nr([
46925
46925
  ie()
46926
46926
  ], Cs.prototype, "stateScofStatus", 2);
46927
46927
  nr([
46928
- Ie({ context: jt, subscribe: !0 }),
46928
+ Ie({ context: Pt, subscribe: !0 }),
46929
46929
  ie()
46930
46930
  ], Cs.prototype, "payfacContext", 2);
46931
46931
  nr([
@@ -47124,7 +47124,7 @@ hc([
47124
47124
  ie()
47125
47125
  ], ma.prototype, "stateScofStatus", 2);
47126
47126
  hc([
47127
- Ie({ context: jt, subscribe: !0 }),
47127
+ Ie({ context: Pt, subscribe: !0 }),
47128
47128
  ie()
47129
47129
  ], ma.prototype, "payfacContext", 2);
47130
47130
  hc([
@@ -47215,7 +47215,7 @@ Ph.styles = Ye`
47215
47215
  ${We(uz)}
47216
47216
  `;
47217
47217
  gz([
47218
- Ie({ context: jt, subscribe: !0 }),
47218
+ Ie({ context: Pt, subscribe: !0 }),
47219
47219
  ie()
47220
47220
  ], Ph.prototype, "payfacContext", 2);
47221
47221
  var fz = Object.defineProperty, mz = Object.getOwnPropertyDescriptor, c4 = (t, e, n, s) => {
@@ -47308,7 +47308,7 @@ let Mm = class t extends Ve {
47308
47308
  _loadFraudScripts() {
47309
47309
  return de(this, null, function* () {
47310
47310
  var n, s, r, i, o, a, d;
47311
- const e = Pt.getConfig();
47311
+ const e = jt.getConfig();
47312
47312
  if (!this.contextFraudPreventionData.config)
47313
47313
  throw new Error("Unable to load fraud prevention tooling");
47314
47314
  if (this.contextFraudPreventionData.config.option === "SIFT") {
@@ -47386,7 +47386,7 @@ dx([
47386
47386
  ie()
47387
47387
  ], Mm.prototype, "contextFraudPreventionData", 2);
47388
47388
  dx([
47389
- Ie({ context: jt, subscribe: !0 }),
47389
+ Ie({ context: Pt, subscribe: !0 }),
47390
47390
  ie()
47391
47391
  ], Mm.prototype, "_payfacContext", 2);
47392
47392
  Mm = dx([
@@ -47675,7 +47675,7 @@ Ra([
47675
47675
  ie()
47676
47676
  ], Mi.prototype, "stateStatus", 2);
47677
47677
  Ra([
47678
- Ie({ context: jt, subscribe: !0 }),
47678
+ Ie({ context: Pt, subscribe: !0 }),
47679
47679
  ie()
47680
47680
  ], Mi.prototype, "payfacContext", 2);
47681
47681
  Ra([
@@ -48042,7 +48042,7 @@ li([
48042
48042
  ie()
48043
48043
  ], gr.prototype, "props", 2);
48044
48044
  li([
48045
- Ie({ context: jt, subscribe: !0 }),
48045
+ Ie({ context: Pt, subscribe: !0 }),
48046
48046
  ie()
48047
48047
  ], gr.prototype, "payfacContext", 2);
48048
48048
  li([
@@ -48301,7 +48301,7 @@ Gd([
48301
48301
  ie()
48302
48302
  ], So.prototype, "state", 2);
48303
48303
  Gd([
48304
- Ie({ context: jt, subscribe: !0 }),
48304
+ Ie({ context: Pt, subscribe: !0 }),
48305
48305
  ie()
48306
48306
  ], So.prototype, "payfacContext", 2);
48307
48307
  So = Gd([
@@ -48497,7 +48497,7 @@ $0([
48497
48497
  ie()
48498
48498
  ], GA.prototype, "state", 2);
48499
48499
  $0([
48500
- Ie({ context: jt, subscribe: !0 }),
48500
+ Ie({ context: Pt, subscribe: !0 }),
48501
48501
  ie()
48502
48502
  ], GA.prototype, "payfacContext", 2);
48503
48503
  GA = $0([
@@ -48760,7 +48760,7 @@ sr([
48760
48760
  ie()
48761
48761
  ], Bs.prototype, "status", 2);
48762
48762
  sr([
48763
- Ie({ context: jt, subscribe: !0 }),
48763
+ Ie({ context: Pt, subscribe: !0 }),
48764
48764
  ie()
48765
48765
  ], Bs.prototype, "payfacContext", 2);
48766
48766
  sr([
@@ -48973,7 +48973,7 @@ mu([
48973
48973
  ie()
48974
48974
  ], Pd.prototype, "status", 2);
48975
48975
  mu([
48976
- Ie({ context: jt, subscribe: !0 }),
48976
+ Ie({ context: Pt, subscribe: !0 }),
48977
48977
  ie()
48978
48978
  ], Pd.prototype, "payfacContext", 2);
48979
48979
  mu([
@@ -49339,7 +49339,7 @@ Da([
49339
49339
  ie()
49340
49340
  ], zi.prototype, "state", 2);
49341
49341
  Da([
49342
- Ie({ context: jt, subscribe: !0 }),
49342
+ Ie({ context: Pt, subscribe: !0 }),
49343
49343
  ie()
49344
49344
  ], zi.prototype, "payfacContext", 2);
49345
49345
  Da([
@@ -49594,7 +49594,7 @@ e1([
49594
49594
  ie()
49595
49595
  ], WA.prototype, "state", 2);
49596
49596
  e1([
49597
- Ie({ context: jt, subscribe: !0 }),
49597
+ Ie({ context: Pt, subscribe: !0 }),
49598
49598
  ie()
49599
49599
  ], WA.prototype, "payfacContext", 2);
49600
49600
  e1([
@@ -49773,7 +49773,7 @@ yu([
49773
49773
  ie()
49774
49774
  ], Fd.prototype, "state", 2);
49775
49775
  yu([
49776
- Ie({ context: jt, subscribe: !0 }),
49776
+ Ie({ context: Pt, subscribe: !0 }),
49777
49777
  ie()
49778
49778
  ], Fd.prototype, "payfacContext", 2);
49779
49779
  yu([
@@ -49862,7 +49862,7 @@ Rh([
49862
49862
  ie()
49863
49863
  ], nc.prototype, "state", 2);
49864
49864
  Rh([
49865
- Ie({ context: jt, subscribe: !0 }),
49865
+ Ie({ context: Pt, subscribe: !0 }),
49866
49866
  ie()
49867
49867
  ], nc.prototype, "payfacContext", 2);
49868
49868
  Rh([
@@ -50038,7 +50038,7 @@ Dh([
50038
50038
  ie()
50039
50039
  ], sc.prototype, "state", 2);
50040
50040
  Dh([
50041
- Ie({ context: jt, subscribe: !0 }),
50041
+ Ie({ context: Pt, subscribe: !0 }),
50042
50042
  ie()
50043
50043
  ], sc.prototype, "payfacContext", 2);
50044
50044
  Dh([
@@ -51615,7 +51615,7 @@ qm.styles = Ye`
51615
51615
  ${We(ox)}
51616
51616
  `;
51617
51617
  S4([
51618
- Ie({ context: jt, subscribe: !0 }),
51618
+ Ie({ context: Pt, subscribe: !0 }),
51619
51619
  ie()
51620
51620
  ], qm.prototype, "payfacContext", 2);
51621
51621
  qm = S4([
@@ -52145,7 +52145,7 @@ let Io = class t extends Ve {
52145
52145
  startPolling() {
52146
52146
  var n;
52147
52147
  hn.isPollingRunning() && hn.stopPolling("manual");
52148
- const e = Pt.getConfig().VITE_ENV === "staging" ? 5 : 1;
52148
+ const e = jt.getConfig().VITE_ENV === "staging" ? 5 : 1;
52149
52149
  hn.startPolling(this.payfacContext.paymentRequest.id, 10, "seconds", e, "minutes"), W.info("STARTPOLLING", {
52150
52150
  context: ne.DEFAULT,
52151
52151
  tag: "START_POLLING",
@@ -52197,7 +52197,7 @@ Yd([
52197
52197
  ie()
52198
52198
  ], Io.prototype, "state", 2);
52199
52199
  Yd([
52200
- Ie({ context: jt, subscribe: !0 }),
52200
+ Ie({ context: Pt, subscribe: !0 }),
52201
52201
  ie()
52202
52202
  ], Io.prototype, "payfacContext", 2);
52203
52203
  Yd([
@@ -65086,7 +65086,7 @@ function(t) {
65086
65086
  */
65087
65087
  function(t) {
65088
65088
  function e() {
65089
- return (yt.canvg ? Promise.resolve(yt.canvg) : import("./index.es-3dfbd0fd.js")).catch(function(n) {
65089
+ return (yt.canvg ? Promise.resolve(yt.canvg) : import("./index.es-e41e5bb7.js")).catch(function(n) {
65090
65090
  return Promise.reject(new Error("Could not load canvg: " + n));
65091
65091
  }).then(function(n) {
65092
65092
  return n.default ? n.default : n;
@@ -66805,7 +66805,7 @@ Zn([
66805
66805
  I({ type: Object })
66806
66806
  ], Qn.prototype, "stateStatus", 2);
66807
66807
  Zn([
66808
- Ie({ context: jt, subscribe: !0 }),
66808
+ Ie({ context: Pt, subscribe: !0 }),
66809
66809
  ie()
66810
66810
  ], Qn.prototype, "_payfacContext", 2);
66811
66811
  Qn = Zn([
@@ -67020,7 +67020,7 @@ let er = class extends Ve {
67020
67020
  });
67021
67021
  }
67022
67022
  _getMasterSDKUrl() {
67023
- const t = Pt.getConfig(), e = this._c2pProps.dpaId, n = this._c2pProps.locale;
67023
+ const t = jt.getConfig(), e = this._c2pProps.dpaId, n = this._c2pProps.locale;
67024
67024
  return `${t.VITE_MASTER_BASE_URL}/srci/integration/2/lib.js?srcDpaId=${e}&locale=${n}`;
67025
67025
  }
67026
67026
  _getInitPayload() {
@@ -67143,7 +67143,7 @@ Or([
67143
67143
  ie()
67144
67144
  ], er.prototype, "_stateC2p", 2);
67145
67145
  Or([
67146
- Ie({ context: jt, subscribe: !0 }),
67146
+ Ie({ context: Pt, subscribe: !0 }),
67147
67147
  ie()
67148
67148
  ], er.prototype, "_payfacContext", 2);
67149
67149
  Or([
@@ -67385,7 +67385,7 @@ Qo([
67385
67385
  ie()
67386
67386
  ], Hi.prototype, "stateStatus", 2);
67387
67387
  Qo([
67388
- Ie({ context: jt, subscribe: !0 }),
67388
+ Ie({ context: Pt, subscribe: !0 }),
67389
67389
  ie()
67390
67390
  ], Hi.prototype, "_payfacContext", 2);
67391
67391
  Hi = Qo([
@@ -68179,7 +68179,7 @@ fn([
68179
68179
  ie()
68180
68180
  ], ln.prototype, "_c2pState", 2);
68181
68181
  fn([
68182
- Ie({ context: jt, subscribe: !0 }),
68182
+ Ie({ context: Pt, subscribe: !0 }),
68183
68183
  ie()
68184
68184
  ], ln.prototype, "_payfacContext", 2);
68185
68185
  fn([
@@ -69382,7 +69382,7 @@ rs([
69382
69382
  ie()
69383
69383
  ], Mn.prototype, "_stateStatus", 2);
69384
69384
  rs([
69385
- Ie({ context: jt, subscribe: !0 }),
69385
+ Ie({ context: Pt, subscribe: !0 }),
69386
69386
  ie()
69387
69387
  ], Mn.prototype, "_payfacContext", 2);
69388
69388
  rs([
@@ -69584,7 +69584,7 @@ yc([
69584
69584
  ie()
69585
69585
  ], wa.prototype, "_stateHolderC2p", 2);
69586
69586
  yc([
69587
- Ie({ context: jt, subscribe: !0 }),
69587
+ Ie({ context: Pt, subscribe: !0 }),
69588
69588
  ie()
69589
69589
  ], wa.prototype, "_payfacContextData", 2);
69590
69590
  yc([
@@ -70542,7 +70542,7 @@ Na([
70542
70542
  ie()
70543
70543
  ], Vi.prototype, "status", 2);
70544
70544
  Na([
70545
- Ie({ context: jt, subscribe: !0 }),
70545
+ Ie({ context: Pt, subscribe: !0 }),
70546
70546
  ie()
70547
70547
  ], Vi.prototype, "payfacContext", 2);
70548
70548
  Na([
@@ -70649,7 +70649,7 @@ b1([
70649
70649
  ie()
70650
70650
  ], eu.prototype, "props", 2);
70651
70651
  b1([
70652
- Ie({ context: jt, subscribe: !0 }),
70652
+ Ie({ context: Pt, subscribe: !0 }),
70653
70653
  ie()
70654
70654
  ], eu.prototype, "payfacContext", 2);
70655
70655
  eu = b1([
@@ -71139,7 +71139,7 @@ La([
71139
71139
  ie()
71140
71140
  ], Ki.prototype, "holderData", 2);
71141
71141
  La([
71142
- Ie({ context: jt, subscribe: !0 }),
71142
+ Ie({ context: Pt, subscribe: !0 }),
71143
71143
  ie()
71144
71144
  ], Ki.prototype, "payfacContextData", 2);
71145
71145
  La([
@@ -71898,7 +71898,7 @@ Xd([
71898
71898
  ie()
71899
71899
  ], Uo.prototype, "status", 2);
71900
71900
  Xd([
71901
- Ie({ context: jt, subscribe: !0 }),
71901
+ Ie({ context: Pt, subscribe: !0 }),
71902
71902
  ie()
71903
71903
  ], Uo.prototype, "payfacContext", 2);
71904
71904
  Uo = Xd([
@@ -72414,7 +72414,7 @@ Mh([
72414
72414
  ie()
72415
72415
  ], ic.prototype, "props", 2);
72416
72416
  Mh([
72417
- Ie({ context: jt, subscribe: !0 }),
72417
+ Ie({ context: Pt, subscribe: !0 }),
72418
72418
  ie()
72419
72419
  ], ic.prototype, "payfacContext", 2);
72420
72420
  Mh([
@@ -72583,7 +72583,7 @@ Bu([
72583
72583
  ie()
72584
72584
  ], Ld.prototype, "state", 2);
72585
72585
  Bu([
72586
- Ie({ context: jt, subscribe: !0 }),
72586
+ Ie({ context: Pt, subscribe: !0 }),
72587
72587
  ie()
72588
72588
  ], Ld.prototype, "payfacContext", 2);
72589
72589
  Bu([
@@ -72761,7 +72761,7 @@ zh([
72761
72761
  ie()
72762
72762
  ], oc.prototype, "state", 2);
72763
72763
  zh([
72764
- Ie({ context: jt, subscribe: !0 }),
72764
+ Ie({ context: Pt, subscribe: !0 }),
72765
72765
  ie()
72766
72766
  ], oc.prototype, "payfacContext", 2);
72767
72767
  zh([
@@ -72848,7 +72848,7 @@ Hh([
72848
72848
  ie()
72849
72849
  ], ac.prototype, "state", 2);
72850
72850
  Hh([
72851
- Ie({ context: jt, subscribe: !0 }),
72851
+ Ie({ context: Pt, subscribe: !0 }),
72852
72852
  ie()
72853
72853
  ], ac.prototype, "payfacContext", 2);
72854
72854
  Hh([
@@ -73121,7 +73121,7 @@ Eu([
73121
73121
  ie()
73122
73122
  ], Qd.prototype, "state", 2);
73123
73123
  Eu([
73124
- Ie({ context: jt, subscribe: !0 }),
73124
+ Ie({ context: Pt, subscribe: !0 }),
73125
73125
  ie()
73126
73126
  ], Qd.prototype, "payfacContext", 2);
73127
73127
  Qd = Eu([
@@ -1,4 +1,4 @@
1
- import { c as Ke, _ as za, g as _o } from "./index-01a99894.js";
1
+ import { c as Ke, _ as za, g as _o } from "./index-bf02547b.js";
2
2
  var vt = function(a) {
3
3
  return a && a.Math === Math && a;
4
4
  }, V = (
package/dist/index.js CHANGED
@@ -1,4 +1,4 @@
1
- import { as as o, ao as t, ar as e, ah as n, av as r, at as C, au as i, ai as p, af as A, an as m, am as l, ag as u, aq as c, ap as d, aj as F, ak as S, al as P, A as f, O as I, Y as y, T as D, B as O, ae as L, a2 as k, $ as H, a7 as g, Z as M, a8 as v, a9 as b, aa as x, h as E, f as h, ad as Q, ac as B, a0 as j, a1 as q, a3 as w, a4 as N, a5 as z, C as G, k as J, x as K, a as R, d as T, ab as U, y as V, M as W, z as X, X as Y, L as Z, G as $, J as _, K as aa, D as sa, a6 as oa, E as ta, e as ea, m as na, b as ra, F as Ca, H as ia, I as pa, W as Aa, N as ma, l as la, U as ua, P as ca, n as da, R as Fa, V as Sa, Q as Pa, S as fa, o as Ia, j as ya, p as Da, q as Oa, r as La, i as ka, v as Ha, s as ga, t as Ma, u as va, w as ba } from "./index-01a99894.js";
1
+ import { as as o, ao as t, ar as e, ah as n, av as r, at as C, au as i, ai as p, af as A, an as m, am as l, ag as u, aq as c, ap as d, aj as F, ak as S, al as P, A as f, O as I, Y as y, T as D, B as O, ae as L, a2 as k, $ as H, a7 as g, Z as M, a8 as v, a9 as b, aa as x, h as E, f as h, ad as Q, ac as B, a0 as j, a1 as q, a3 as w, a4 as N, a5 as z, C as G, k as J, x as K, a as R, d as T, ab as U, y as V, M as W, z as X, X as Y, L as Z, G as $, J as _, K as aa, D as sa, a6 as oa, E as ta, e as ea, m as na, b as ra, F as Ca, H as ia, I as pa, W as Aa, N as ma, l as la, U as ua, P as ca, n as da, R as Fa, V as Sa, Q as Pa, S as fa, o as Ia, j as ya, p as Da, q as Oa, r as La, i as ka, v as Ha, s as ga, t as Ma, u as va, w as ba } from "./index-bf02547b.js";
2
2
  export {
3
3
  o as A2AAccountDetails,
4
4
  t as A2AAccountList,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ranty/ranty-sdk",
3
- "version": "3.16.0-beta.0",
3
+ "version": "3.16.0-beta.1",
4
4
  "description": "Ranty sdk",
5
5
  "main": "dist/index.js",
6
6
  "exports": {