@fractalpay/fractalpay-next 0.0.26 → 0.0.27

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -39,7 +39,7 @@ var require_package = __commonJS({
39
39
  "package.json"(exports, module) {
40
40
  module.exports = {
41
41
  name: "@fractalpay/fractalpay-next",
42
- version: "0.0.26",
42
+ version: "0.0.27",
43
43
  private: false,
44
44
  type: "module",
45
45
  scripts: {
@@ -97,12 +97,7 @@ var require_package = __commonJS({
97
97
  },
98
98
  author: "Mukul",
99
99
  license: "MIT",
100
- keywords: [
101
- "nextjs",
102
- "next",
103
- "typescript",
104
- "tailwindcss"
105
- ],
100
+ keywords: ["nextjs", "next", "typescript", "tailwindcss"],
106
101
  publishConfig: {
107
102
  access: "public"
108
103
  }
@@ -3173,7 +3168,7 @@ var FractalFields = ({ fractalStyles, tokenizerRef, isAddCard = false, isSky = f
3173
3168
  {
3174
3169
  id: "card_number",
3175
3170
  className: "form-control card-number-new",
3176
- style: { height: "46px" }
3171
+ style: { height: "46px", display: "inline-block" }
3177
3172
  }
3178
3173
  ),
3179
3174
  /* @__PURE__ */ jsx17("div", { className: "card-dtl", children: /* @__PURE__ */ jsxs10("div", { className: "exp-cvc-container exp-cvc-container-wrap", style: { margin: 0 }, children: [
@@ -3214,32 +3209,32 @@ var FractalFields = ({ fractalStyles, tokenizerRef, isAddCard = false, isSky = f
3214
3209
  {
3215
3210
  id: "card_number",
3216
3211
  className: "form-control card-number-new",
3217
- style: { height: `${isSky ? "36px" : "46px"}` }
3212
+ style: { height: `${isSky ? "36px" : "46px"}`, display: "inline-block" }
3218
3213
  }
3219
3214
  ),
3220
3215
  /* @__PURE__ */ jsx17("div", { className: "card-crdi card-expiry-new", children: /* @__PURE__ */ jsxs10("div", { className: "exp-date-year-container", children: [
3221
- /* @__PURE__ */ jsx17("div", { className: "exp-date form-group", children: /* @__PURE__ */ jsx17(
3216
+ /* @__PURE__ */ jsx17("div", { className: "exp-date form-group input-main-wrap-frac", children: /* @__PURE__ */ jsx17(
3222
3217
  "div",
3223
3218
  {
3224
3219
  id: "exp_month",
3225
3220
  className: "form-control required card-cvv-in",
3226
- style: { height: "36px" }
3221
+ style: { height: "36px", display: "inline-block" }
3227
3222
  }
3228
3223
  ) }),
3229
- /* @__PURE__ */ jsx17("div", { className: "exp-year form-group", children: /* @__PURE__ */ jsx17(
3224
+ /* @__PURE__ */ jsx17("div", { className: "exp-year form-group input-main-wrap-frac", children: /* @__PURE__ */ jsx17(
3230
3225
  "div",
3231
3226
  {
3232
3227
  id: "exp_year",
3233
3228
  className: "form-control required card-cvv-in",
3234
- style: { height: "36px" }
3229
+ style: { height: "36px", display: "inline-block" }
3235
3230
  }
3236
3231
  ) }),
3237
- /* @__PURE__ */ jsx17("div", { className: "security-digit form-group", children: /* @__PURE__ */ jsx17(
3232
+ /* @__PURE__ */ jsx17("div", { className: "security-digit form-group input-main-wrap-frac", children: /* @__PURE__ */ jsx17(
3238
3233
  "div",
3239
3234
  {
3240
3235
  id: "cvv",
3241
3236
  className: "form-control card-cvv-in required",
3242
- style: { height: "36px" }
3237
+ style: { height: "36px", display: "inline-block" }
3243
3238
  }
3244
3239
  ) })
3245
3240
  ] }) })
@@ -6636,7 +6631,8 @@ var FractalFieldsAddCardSky = ({ fractalStyles, tokenizerRef, extraInputs }) =>
6636
6631
  "div",
6637
6632
  {
6638
6633
  id: "card_number",
6639
- className: "form-control card-number-new"
6634
+ className: "form-control card-number-new",
6635
+ style: { display: "inline-block" }
6640
6636
  }
6641
6637
  )
6642
6638
  ] }) }),
@@ -6650,7 +6646,8 @@ var FractalFieldsAddCardSky = ({ fractalStyles, tokenizerRef, extraInputs }) =>
6650
6646
  "div",
6651
6647
  {
6652
6648
  id: "exp_month",
6653
- className: "form-control required card-cvv-in"
6649
+ className: "form-control required card-cvv-in",
6650
+ style: { display: "inline-block" }
6654
6651
  }
6655
6652
  )
6656
6653
  ] }),
@@ -6663,7 +6660,8 @@ var FractalFieldsAddCardSky = ({ fractalStyles, tokenizerRef, extraInputs }) =>
6663
6660
  "div",
6664
6661
  {
6665
6662
  id: "exp_year",
6666
- className: "form-control required card-cvv-in"
6663
+ className: "form-control required card-cvv-in",
6664
+ style: { display: "inline-block" }
6667
6665
  }
6668
6666
  )
6669
6667
  ] }),
@@ -6676,7 +6674,8 @@ var FractalFieldsAddCardSky = ({ fractalStyles, tokenizerRef, extraInputs }) =>
6676
6674
  "div",
6677
6675
  {
6678
6676
  id: "cvv",
6679
- className: "form-control card-cvv-in required"
6677
+ className: "form-control card-cvv-in required",
6678
+ style: { display: "inline-block" }
6680
6679
  }
6681
6680
  )
6682
6681
  ] }),
@@ -9339,7 +9338,10 @@ position:relative;
9339
9338
  .exp-date-year-container .form-group {
9340
9339
  flex: 1;
9341
9340
  }
9342
-
9341
+ .input-main-wrap-frac{
9342
+ margin:0px !important;
9343
+ padding:0px !important;
9344
+ }
9343
9345
 
9344
9346
 
9345
9347
 
@@ -9571,9 +9573,9 @@ var ModelContentSky = ({ amount, bankAmount, submitBtnText = "Pay", session_toke
9571
9573
  }
9572
9574
  };
9573
9575
  const handleCharge = async (data) => {
9574
- var _a2, _b2, _c2, _d2, _e2, _f2, _g2, _h2, _i2, _j2, _k2, _l2, _m2, _n2, _o2, _p2, _q2, _r2;
9576
+ var _a2, _b2, _c2, _d2, _e2, _f2, _g2, _h2, _i2;
9575
9577
  try {
9576
- let dataObj = {
9578
+ let dataObj = __spreadValues({
9577
9579
  pass_fee_amount: Number(amount) - cashDiscount,
9578
9580
  pass_fee,
9579
9581
  Token: data == null ? void 0 : data.Token,
@@ -9582,106 +9584,69 @@ var ModelContentSky = ({ amount, bankAmount, submitBtnText = "Pay", session_toke
9582
9584
  require3ds,
9583
9585
  isPartial,
9584
9586
  orderGuid: orderGuid || ordGuid
9585
- };
9587
+ }, saveCardInfo ? {
9588
+ card: {
9589
+ postal_code: cardData == null ? void 0 : cardData.zipCode,
9590
+ customer_id: customerId,
9591
+ gateway_token: (data == null ? void 0 : data.Token) || (data == null ? void 0 : data.gateway_token),
9592
+ name: cardData == null ? void 0 : cardData.cardName
9593
+ }
9594
+ } : null);
9586
9595
  if (require3ds && (data == null ? void 0 : data.stripe_3ds_auth_id)) {
9587
9596
  dataObj.stripe_3ds_auth_id = data == null ? void 0 : data.stripe_3ds_auth_id;
9588
9597
  }
9589
9598
  const chargeResponse = await axios9.post(`${masterBaseUrl}api/v1/gateway/charge/${session_token}`, dataObj);
9590
9599
  if ((_a2 = chargeResponse == null ? void 0 : chargeResponse.data) == null ? void 0 : _a2.result) {
9591
- let addCard;
9592
- if (saveCardInfo && customerId) {
9593
- try {
9594
- let obj = {
9595
- postal_code: cardData == null ? void 0 : cardData.zipCode,
9596
- customer_id: customerId,
9597
- gateway_token: (data == null ? void 0 : data.gateway_token) || (data == null ? void 0 : data.Token)
9598
- };
9599
- addCard = await axios9.post(`${masterBaseUrl}api/v1/gateway/add-card/${session_token}`, obj);
9600
- if ((_b2 = addCard == null ? void 0 : addCard.data) == null ? void 0 : _b2.result) {
9601
- addCard = (_c2 = addCard == null ? void 0 : addCard.data) == null ? void 0 : _c2.data;
9602
- }
9603
- } catch (error2) {
9604
- console.log(error2, "error");
9605
- hideLoader();
9606
- callback({
9607
- error: ((_e2 = (_d2 = error2 == null ? void 0 : error2.response) == null ? void 0 : _d2.data) == null ? void 0 : _e2.message) || "Something went wrong!",
9608
- result: (_g2 = (_f2 = error2 == null ? void 0 : error2.response) == null ? void 0 : _f2.data) == null ? void 0 : _g2.result,
9609
- statusCode: (_h2 = error2 == null ? void 0 : error2.response) == null ? void 0 : _h2.status
9610
- });
9611
- setError(((_j2 = (_i2 = error2 == null ? void 0 : error2.response) == null ? void 0 : _i2.data) == null ? void 0 : _j2.message) || "Something went wrong!");
9612
- }
9613
- }
9614
9600
  let callbackdata = {
9615
- cardDetails: __spreadValues(__spreadValues({}, addCard), data),
9616
- callback: __spreadProps(__spreadValues({}, (_k2 = chargeResponse == null ? void 0 : chargeResponse.data) == null ? void 0 : _k2.data), { name: cardData == null ? void 0 : cardData.cardName, isPreAuth })
9601
+ // cardDetails: { ...addCard, ...data },
9602
+ callback: __spreadProps(__spreadValues({}, (_b2 = chargeResponse == null ? void 0 : chargeResponse.data) == null ? void 0 : _b2.data), { name: cardData == null ? void 0 : cardData.cardName, isPreAuth })
9617
9603
  };
9618
- if (!saveCardInfo) {
9619
- delete callbackdata.cardDetails;
9620
- }
9621
9604
  callback(callbackdata);
9622
9605
  hideLoader();
9623
9606
  handleClose();
9624
9607
  }
9625
9608
  } catch (error2) {
9626
- setError(((_m2 = (_l2 = error2 == null ? void 0 : error2.response) == null ? void 0 : _l2.data) == null ? void 0 : _m2.message) || "Something went wrong!");
9609
+ setError(((_d2 = (_c2 = error2 == null ? void 0 : error2.response) == null ? void 0 : _c2.data) == null ? void 0 : _d2.message) || "Something went wrong!");
9627
9610
  callback({
9628
- error: ((_o2 = (_n2 = error2 == null ? void 0 : error2.response) == null ? void 0 : _n2.data) == null ? void 0 : _o2.message) || "Something went wrong!",
9629
- result: (_q2 = (_p2 = error2 == null ? void 0 : error2.response) == null ? void 0 : _p2.data) == null ? void 0 : _q2.result,
9630
- statusCode: (_r2 = error2 == null ? void 0 : error2.response) == null ? void 0 : _r2.status
9611
+ error: ((_f2 = (_e2 = error2 == null ? void 0 : error2.response) == null ? void 0 : _e2.data) == null ? void 0 : _f2.message) || "Something went wrong!",
9612
+ result: (_h2 = (_g2 = error2 == null ? void 0 : error2.response) == null ? void 0 : _g2.data) == null ? void 0 : _h2.result,
9613
+ statusCode: (_i2 = error2 == null ? void 0 : error2.response) == null ? void 0 : _i2.status
9631
9614
  });
9632
9615
  hideLoader();
9633
9616
  }
9634
9617
  };
9635
9618
  const handlePreAuth = async (data) => {
9636
- var _a2, _b2, _c2, _d2, _e2, _f2, _g2, _h2, _i2, _j2, _k2, _l2, _m2, _n2, _o2, _p2, _q2, _r2;
9619
+ var _a2, _b2, _c2, _d2, _e2, _f2, _g2, _h2, _i2;
9637
9620
  try {
9638
- let dataObj = {
9621
+ let dataObj = __spreadValues({
9639
9622
  Token: data == null ? void 0 : data.Token,
9640
9623
  amount,
9641
9624
  postal_code: data == null ? void 0 : data.postalCode
9642
- };
9625
+ }, saveCardInfo ? {
9626
+ card: {
9627
+ postal_code: cardData == null ? void 0 : cardData.zipCode,
9628
+ customer_id: customerId,
9629
+ gateway_token: (data == null ? void 0 : data.Token) || (data == null ? void 0 : data.gateway_token),
9630
+ name: cardData == null ? void 0 : cardData.cardName
9631
+ }
9632
+ } : null);
9643
9633
  const preAuthResponse = await axios9.post(`${masterBaseUrl}api/v1/gateway/preauth/${session_token}`, dataObj);
9644
9634
  if ((_a2 = preAuthResponse == null ? void 0 : preAuthResponse.data) == null ? void 0 : _a2.result) {
9645
9635
  let addCard;
9646
- if (saveCardInfo && customerId) {
9647
- try {
9648
- let obj = {
9649
- postal_code: cardData == null ? void 0 : cardData.zipCode,
9650
- customer_id: customerId,
9651
- gateway_token: (data == null ? void 0 : data.Token) || (data == null ? void 0 : data.gateway_token)
9652
- };
9653
- addCard = await axios9.post(`${masterBaseUrl}api/v1/gateway/add-card/${session_token}`, obj);
9654
- if ((_b2 = addCard == null ? void 0 : addCard.data) == null ? void 0 : _b2.result) {
9655
- addCard = (_c2 = addCard == null ? void 0 : addCard.data) == null ? void 0 : _c2.data;
9656
- }
9657
- } catch (error2) {
9658
- console.log(error2, "error");
9659
- hideLoader();
9660
- setError(((_e2 = (_d2 = error2 == null ? void 0 : error2.response) == null ? void 0 : _d2.data) == null ? void 0 : _e2.message) || "Something went wrong!");
9661
- callback({
9662
- error: ((_g2 = (_f2 = error2 == null ? void 0 : error2.response) == null ? void 0 : _f2.data) == null ? void 0 : _g2.message) || "Something went wrong!",
9663
- result: (_i2 = (_h2 = error2 == null ? void 0 : error2.response) == null ? void 0 : _h2.data) == null ? void 0 : _i2.result,
9664
- statusCode: (_j2 = error2 == null ? void 0 : error2.response) == null ? void 0 : _j2.status
9665
- });
9666
- }
9667
- }
9668
9636
  let callbackdata = {
9669
- cardDetails: __spreadValues(__spreadValues({}, addCard), data),
9670
- callback: __spreadProps(__spreadValues({}, (_k2 = preAuthResponse == null ? void 0 : preAuthResponse.data) == null ? void 0 : _k2.data), { name: cardData == null ? void 0 : cardData.cardName, isPreAuth })
9637
+ // cardDetails: { ...addCard, ...data },
9638
+ callback: __spreadProps(__spreadValues({}, (_b2 = preAuthResponse == null ? void 0 : preAuthResponse.data) == null ? void 0 : _b2.data), { name: cardData == null ? void 0 : cardData.cardName, isPreAuth })
9671
9639
  };
9672
- if (!saveCardInfo) {
9673
- delete callbackdata.cardDetails;
9674
- }
9675
9640
  callback(callbackdata);
9676
9641
  hideLoader();
9677
9642
  handleClose();
9678
9643
  }
9679
9644
  } catch (error2) {
9680
- setError(((_m2 = (_l2 = error2 == null ? void 0 : error2.response) == null ? void 0 : _l2.data) == null ? void 0 : _m2.message) || "Something went wrong!");
9645
+ setError(((_d2 = (_c2 = error2 == null ? void 0 : error2.response) == null ? void 0 : _c2.data) == null ? void 0 : _d2.message) || "Something went wrong!");
9681
9646
  callback({
9682
- error: ((_o2 = (_n2 = error2 == null ? void 0 : error2.response) == null ? void 0 : _n2.data) == null ? void 0 : _o2.message) || "Something went wrong!",
9683
- result: (_q2 = (_p2 = error2 == null ? void 0 : error2.response) == null ? void 0 : _p2.data) == null ? void 0 : _q2.result,
9684
- statusCode: (_r2 = error2 == null ? void 0 : error2.response) == null ? void 0 : _r2.status
9647
+ error: ((_f2 = (_e2 = error2 == null ? void 0 : error2.response) == null ? void 0 : _e2.data) == null ? void 0 : _f2.message) || "Something went wrong!",
9648
+ result: (_h2 = (_g2 = error2 == null ? void 0 : error2.response) == null ? void 0 : _g2.data) == null ? void 0 : _h2.result,
9649
+ statusCode: (_i2 = error2 == null ? void 0 : error2.response) == null ? void 0 : _i2.status
9685
9650
  });
9686
9651
  hideLoader();
9687
9652
  }
@@ -9892,7 +9857,7 @@ var ModelContentSky = ({ amount, bankAmount, submitBtnText = "Pay", session_toke
9892
9857
  return validCard && validCVV && validExpirationDate;
9893
9858
  };
9894
9859
  const submitFunc = async (e) => {
9895
- var _a2, _b2, _c2, _d2, _e2, _f2, _g2, _h2, _i2, _j2, _k2, _l2, _m2, _n2, _o2, _p2, _q2, _r2, _s2, _t, _u, _v, _w, _x;
9860
+ var _a2, _b2, _c2, _d2, _e2, _f2, _g2, _h2, _i2, _j2, _k2, _l2, _m2, _n2, _o2, _p2;
9896
9861
  e.preventDefault();
9897
9862
  const el = document.activeElement;
9898
9863
  if (el instanceof HTMLElement) {
@@ -9942,7 +9907,7 @@ var ModelContentSky = ({ amount, bankAmount, submitBtnText = "Pay", session_toke
9942
9907
  } else {
9943
9908
  let callbackdata;
9944
9909
  try {
9945
- const payByBank = await axios9.post(`${masterBaseUrl}api/v1/gateway/bank-charge/${session_token}`, {
9910
+ const payByBank = await axios9.post(`${masterBaseUrl}api/v1/gateway/bank-charge/${session_token}`, __spreadValues({
9946
9911
  label: achData == null ? void 0 : achData.name,
9947
9912
  account_number: achData == null ? void 0 : achData.accountNumber,
9948
9913
  routing_number: achData == null ? void 0 : achData.routingNumber,
@@ -9956,36 +9921,20 @@ var ModelContentSky = ({ amount, bankAmount, submitBtnText = "Pay", session_toke
9956
9921
  surcharge: "0.00",
9957
9922
  order_id: "",
9958
9923
  company_name: (achData == null ? void 0 : achData.companyName) || ""
9959
- });
9960
- if ((_f2 = payByBank == null ? void 0 : payByBank.data) == null ? void 0 : _f2.result) {
9961
- if (saveACHinfo && customerId) {
9962
- try {
9963
- const result2 = await axios9.post(`${masterBaseUrl}api/v1/gateway/add-bank/${session_token}`, {
9964
- name: achData == null ? void 0 : achData.name,
9965
- account_number: achData == null ? void 0 : achData.accountNumber,
9966
- routing_number: achData == null ? void 0 : achData.routingNumber,
9967
- bank_name: achData == null ? void 0 : achData.bankName,
9968
- account_type: achData == null ? void 0 : achData.accountType,
9969
- customer_id: customerId || "",
9970
- company_name: (achData == null ? void 0 : achData.companyName) || ""
9971
- });
9972
- if (result2.data.result) {
9973
- callbackdata = {
9974
- bankDetails: __spreadProps(__spreadValues({}, (_g2 = result2 == null ? void 0 : result2.data) == null ? void 0 : _g2.data), { account_type: achData == null ? void 0 : achData.accountType })
9975
- };
9976
- }
9977
- } catch (error2) {
9978
- hideLoader();
9979
- setError(((_i2 = (_h2 = error2 == null ? void 0 : error2.response) == null ? void 0 : _h2.data) == null ? void 0 : _i2.message) || "Something went wrong!");
9980
- callback({
9981
- error: ((_k2 = (_j2 = error2 == null ? void 0 : error2.response) == null ? void 0 : _j2.data) == null ? void 0 : _k2.message) || "Something went wrong!",
9982
- result: (_m2 = (_l2 = error2 == null ? void 0 : error2.response) == null ? void 0 : _l2.data) == null ? void 0 : _m2.result,
9983
- statusCode: (_n2 = error2 == null ? void 0 : error2.response) == null ? void 0 : _n2.status
9984
- });
9985
- }
9924
+ }, saveACHinfo ? {
9925
+ bank: {
9926
+ name: achData == null ? void 0 : achData.name,
9927
+ account_number: achData == null ? void 0 : achData.accountNumber,
9928
+ routing_number: achData == null ? void 0 : achData.routingNumber,
9929
+ bank_name: achData == null ? void 0 : achData.bankName,
9930
+ account_type: achData == null ? void 0 : achData.accountType,
9931
+ customer_id: customerId || "",
9932
+ company_name: (achData == null ? void 0 : achData.companyName) || ""
9986
9933
  }
9934
+ } : null));
9935
+ if ((_f2 = payByBank == null ? void 0 : payByBank.data) == null ? void 0 : _f2.result) {
9987
9936
  callbackdata = __spreadProps(__spreadValues({}, callbackdata), {
9988
- callback: __spreadProps(__spreadValues({}, (_o2 = payByBank == null ? void 0 : payByBank.data) == null ? void 0 : _o2.data), { name: achData == null ? void 0 : achData.name, isPreAuth })
9937
+ callback: __spreadProps(__spreadValues({}, (_g2 = payByBank == null ? void 0 : payByBank.data) == null ? void 0 : _g2.data), { name: achData == null ? void 0 : achData.name, isPreAuth })
9989
9938
  });
9990
9939
  callback(callbackdata);
9991
9940
  handleClose();
@@ -9993,7 +9942,7 @@ var ModelContentSky = ({ amount, bankAmount, submitBtnText = "Pay", session_toke
9993
9942
  }
9994
9943
  } catch (error2) {
9995
9944
  console.log(error2, "errororor");
9996
- let data = (_p2 = error2 == null ? void 0 : error2.response) == null ? void 0 : _p2.data;
9945
+ let data = (_h2 = error2 == null ? void 0 : error2.response) == null ? void 0 : _h2.data;
9997
9946
  if (typeof (data == null ? void 0 : data.message) == "object") {
9998
9947
  Object.values(data == null ? void 0 : data.message).forEach((message) => {
9999
9948
  var _a3;
@@ -10009,7 +9958,7 @@ var ModelContentSky = ({ amount, bankAmount, submitBtnText = "Pay", session_toke
10009
9958
  callback({
10010
9959
  error: (data == null ? void 0 : data.message) || "Something went wrong!",
10011
9960
  result: (data == null ? void 0 : data.result) || false,
10012
- statusCode: (_q2 = error2 == null ? void 0 : error2.response) == null ? void 0 : _q2.status
9961
+ statusCode: (_i2 = error2 == null ? void 0 : error2.response) == null ? void 0 : _i2.status
10013
9962
  });
10014
9963
  }
10015
9964
  hideLoader();
@@ -10019,11 +9968,11 @@ var ModelContentSky = ({ amount, bankAmount, submitBtnText = "Pay", session_toke
10019
9968
  } catch (error2) {
10020
9969
  hideLoader();
10021
9970
  callback({
10022
- error: ((_s2 = (_r2 = error2 == null ? void 0 : error2.response) == null ? void 0 : _r2.data) == null ? void 0 : _s2.message) || "Something went wrong!",
10023
- result: (_u = (_t = error2 == null ? void 0 : error2.response) == null ? void 0 : _t.data) == null ? void 0 : _u.result,
10024
- statusCode: (_v = error2 == null ? void 0 : error2.response) == null ? void 0 : _v.status
9971
+ error: ((_k2 = (_j2 = error2 == null ? void 0 : error2.response) == null ? void 0 : _j2.data) == null ? void 0 : _k2.message) || "Something went wrong!",
9972
+ result: (_m2 = (_l2 = error2 == null ? void 0 : error2.response) == null ? void 0 : _l2.data) == null ? void 0 : _m2.result,
9973
+ statusCode: (_n2 = error2 == null ? void 0 : error2.response) == null ? void 0 : _n2.status
10025
9974
  });
10026
- setError(((_x = (_w = error2 == null ? void 0 : error2.response) == null ? void 0 : _w.data) == null ? void 0 : _x.message) || "Something went wrong!");
9975
+ setError(((_p2 = (_o2 = error2 == null ? void 0 : error2.response) == null ? void 0 : _o2.data) == null ? void 0 : _p2.message) || "Something went wrong!");
10027
9976
  }
10028
9977
  };
10029
9978
  const handleCardChange = (field, value) => {