@fractalpay/fractalpay-next-dev 0.0.270 → 0.0.271
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.d.ts +1 -0
- package/dist/index.js +83 -52
- package/dist/index.js.map +1 -1
- package/next.config.ts +1 -0
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
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-dev",
|
|
42
|
-
version: "0.0.
|
|
42
|
+
version: "0.0.271",
|
|
43
43
|
private: false,
|
|
44
44
|
type: "module",
|
|
45
45
|
scripts: {
|
|
@@ -236,8 +236,8 @@ var Loader_default = Loader;
|
|
|
236
236
|
var { name } = require_package();
|
|
237
237
|
var S3Url = "https://fractal-userdata-upload.s3.us-east-1.amazonaws.com/";
|
|
238
238
|
if (name === "@fractalpay/fractalpay-next-dev") {
|
|
239
|
-
masterBaseUrl = "https://
|
|
240
|
-
baseUrl = "https://widget.
|
|
239
|
+
masterBaseUrl = "https://dev-sky-node.fractalpay.com/";
|
|
240
|
+
baseUrl = "https://dev-widget.fractalpay.com/";
|
|
241
241
|
fractalGatewayUrl = "https://api-dev.merchant-trends.com/";
|
|
242
242
|
datacapUrl = "https://token-cert.dcap.com/v1/client";
|
|
243
243
|
threedsSecurePublicKey = "pk_test_51RH5Wc2SlJvyNZ80hpUDy88r4rVdpijfKbNaWaUyQEE6rOrPmG2JQyAj7G5amBD5z5daC56WaeT4jfNhrrPcGOEP00UyKu6AOw";
|
|
@@ -1058,9 +1058,10 @@ function RequestPayment(props) {
|
|
|
1058
1058
|
let cash_discount = CalculateCashDiscount(props == null ? void 0 : props.amount, props == null ? void 0 : props.surcharge);
|
|
1059
1059
|
setCashDiscount(cash_discount);
|
|
1060
1060
|
}
|
|
1061
|
-
}, [props == null ? void 0 : props.pass_fee]);
|
|
1061
|
+
}, [props == null ? void 0 : props.pass_fee, show]);
|
|
1062
1062
|
const handleClose = () => {
|
|
1063
1063
|
setShow(false);
|
|
1064
|
+
setCashDiscount(0);
|
|
1064
1065
|
setErrors({});
|
|
1065
1066
|
};
|
|
1066
1067
|
const handleShow = () => setShow(true);
|
|
@@ -2458,6 +2459,20 @@ position:relative;
|
|
|
2458
2459
|
border: 0;
|
|
2459
2460
|
border-right: 1px solid #dee2e6;
|
|
2460
2461
|
}
|
|
2462
|
+
|
|
2463
|
+
.frac-fee-text{
|
|
2464
|
+
display: block;
|
|
2465
|
+
padding: 10px 0 4px;
|
|
2466
|
+
font-family: 'IBM Plex Mono', monospace !important;
|
|
2467
|
+
color: #727272 !important;
|
|
2468
|
+
font-size: 12px;
|
|
2469
|
+
line-height: 1.4;
|
|
2470
|
+
text-align: start !important;
|
|
2471
|
+
}
|
|
2472
|
+
.frac-fee-amount{
|
|
2473
|
+
color: #c62828 !important;
|
|
2474
|
+
}
|
|
2475
|
+
|
|
2461
2476
|
` });
|
|
2462
2477
|
}
|
|
2463
2478
|
|
|
@@ -3298,7 +3313,7 @@ var FractalFields = ({ fractalStyles, tokenizerRef, isAddCard = false, isSky = f
|
|
|
3298
3313
|
{
|
|
3299
3314
|
id: "exp_month",
|
|
3300
3315
|
className: "form-control required card-cvv-in",
|
|
3301
|
-
style: { height: "
|
|
3316
|
+
style: { height: "38px", display: "block", minHeight: "38px" }
|
|
3302
3317
|
}
|
|
3303
3318
|
) }),
|
|
3304
3319
|
/* @__PURE__ */ jsx17("div", { className: "exp-year form-group input-main-wrap-frac", children: /* @__PURE__ */ jsx17(
|
|
@@ -3306,7 +3321,7 @@ var FractalFields = ({ fractalStyles, tokenizerRef, isAddCard = false, isSky = f
|
|
|
3306
3321
|
{
|
|
3307
3322
|
id: "exp_year",
|
|
3308
3323
|
className: "form-control required card-cvv-in",
|
|
3309
|
-
style: { height: "
|
|
3324
|
+
style: { height: "38px", display: "block", minHeight: "38px" }
|
|
3310
3325
|
}
|
|
3311
3326
|
) }),
|
|
3312
3327
|
/* @__PURE__ */ jsx17("div", { className: "security-digit form-group input-main-wrap-frac", children: /* @__PURE__ */ jsx17(
|
|
@@ -3314,7 +3329,7 @@ var FractalFields = ({ fractalStyles, tokenizerRef, isAddCard = false, isSky = f
|
|
|
3314
3329
|
{
|
|
3315
3330
|
id: "cvv",
|
|
3316
3331
|
className: "form-control card-cvv-in required",
|
|
3317
|
-
style: { height: "
|
|
3332
|
+
style: { height: "38px", display: "block", minHeight: "38px" }
|
|
3318
3333
|
}
|
|
3319
3334
|
) })
|
|
3320
3335
|
] }) })
|
|
@@ -3595,6 +3610,8 @@ function GetPaymentPage(props) {
|
|
|
3595
3610
|
const [selectedCard, setSelectedCard] = useState4();
|
|
3596
3611
|
const [selectedReader, setSelectedReader] = useState4(void 0);
|
|
3597
3612
|
const [cashDiscount, setCashDiscount] = useState4(Number(props == null ? void 0 : props.amount));
|
|
3613
|
+
const [bankAmount, setBankAmount] = useState4(Number(props == null ? void 0 : props.amount));
|
|
3614
|
+
const [bankFeeAmount, setBankFeeAmount] = useState4(0);
|
|
3598
3615
|
const [paymentData, setPaymentData] = useState4();
|
|
3599
3616
|
let [tranId, setTranId] = useState4("");
|
|
3600
3617
|
const tokenizerRef = useRef3(null);
|
|
@@ -3629,7 +3646,25 @@ function GetPaymentPage(props) {
|
|
|
3629
3646
|
useEffect8(() => {
|
|
3630
3647
|
if (show) {
|
|
3631
3648
|
let cash_discount = CalculateCashDiscount(props == null ? void 0 : props.amount, (props == null ? void 0 : props.surcharge) || 0);
|
|
3649
|
+
let bankAmount2 = cash_discount;
|
|
3650
|
+
if ((props == null ? void 0 : props.bankFeeAmount) && Number(props == null ? void 0 : props.bankFeeAmount) > 0) {
|
|
3651
|
+
bankAmount2 = Number(cash_discount) + Number(props == null ? void 0 : props.bankFeeAmount);
|
|
3652
|
+
}
|
|
3653
|
+
setBankAmount(bankAmount2);
|
|
3632
3654
|
setCashDiscount(cash_discount);
|
|
3655
|
+
const cardFeeAmount = Number((Number(props == null ? void 0 : props.amount) - Number(cash_discount || 0)).toFixed(2));
|
|
3656
|
+
const bankFeeAmount2 = Number((props == null ? void 0 : props.bankFeeAmount) || 0);
|
|
3657
|
+
const bankSavingsAmount = Math.max(bankFeeAmount2 > 0 ? cardFeeAmount - bankFeeAmount2 : cardFeeAmount, 0);
|
|
3658
|
+
const bankSavingsText = bankSavingsAmount > 0 ? `Save ${formatUSD(bankSavingsAmount.toFixed(2))}` : "";
|
|
3659
|
+
setBankFeeAmount(bankFeeAmount2);
|
|
3660
|
+
console.log({
|
|
3661
|
+
cash_discount,
|
|
3662
|
+
bankAmount: bankAmount2,
|
|
3663
|
+
cardFeeAmount,
|
|
3664
|
+
bankFeeAmount: bankFeeAmount2,
|
|
3665
|
+
bankSavingsAmount,
|
|
3666
|
+
bankSavingsText
|
|
3667
|
+
});
|
|
3633
3668
|
}
|
|
3634
3669
|
}, [show, props == null ? void 0 : props.pass_fee, props == null ? void 0 : props.amount, props == null ? void 0 : props.surcharge]);
|
|
3635
3670
|
const handleClose = () => {
|
|
@@ -3980,7 +4015,7 @@ function GetPaymentPage(props) {
|
|
|
3980
4015
|
routing_number: achData == null ? void 0 : achData.routingNumber,
|
|
3981
4016
|
bank_name: achData == null ? void 0 : achData.bankName,
|
|
3982
4017
|
account_type: achData == null ? void 0 : achData.accountType,
|
|
3983
|
-
amount: String(
|
|
4018
|
+
amount: String(bankAmount || 0),
|
|
3984
4019
|
isSaveAch: saveACHinfo,
|
|
3985
4020
|
customer_id: props == null ? void 0 : props.customerId,
|
|
3986
4021
|
order_id: props == null ? void 0 : props.orderID,
|
|
@@ -4062,11 +4097,11 @@ function GetPaymentPage(props) {
|
|
|
4062
4097
|
let amount = String(props == null ? void 0 : props.amount);
|
|
4063
4098
|
let card_id = selectedCard == null ? void 0 : selectedCard.id;
|
|
4064
4099
|
let card_type = selectedCard == null ? void 0 : selectedCard.card_type;
|
|
4065
|
-
if (fractalpayPublicKey && order_id && amount &&
|
|
4100
|
+
if (fractalpayPublicKey && order_id && amount && bankAmount) {
|
|
4066
4101
|
if (customer_id) {
|
|
4067
4102
|
if (card_id) {
|
|
4068
4103
|
let chargeobj = __spreadValues({
|
|
4069
|
-
amount: card_type === "Bank" ? `${
|
|
4104
|
+
amount: card_type === "Bank" ? `${bankAmount}` : amount,
|
|
4070
4105
|
order_id,
|
|
4071
4106
|
customer_id,
|
|
4072
4107
|
card_id,
|
|
@@ -4305,22 +4340,21 @@ function GetPaymentPage(props) {
|
|
|
4305
4340
|
/* @__PURE__ */ jsx19("div", { className: "pay-amount-conatiner", children: /* @__PURE__ */ jsx19("small", { className: "pay-payment-amount", children: "Select paymet type" }) }),
|
|
4306
4341
|
/* @__PURE__ */ jsxs11("div", { className: "frac-card-bank-radio-main", children: [
|
|
4307
4342
|
/* @__PURE__ */ jsx19(CardBankRadio, { label: "Card", amount: (_a = Number(props == null ? void 0 : props.amount)) == null ? void 0 : _a.toFixed(2), value: "card", onChange: handletabchange, activetab }),
|
|
4308
|
-
(paymentData == null ? void 0 : paymentData.isSkyFiAccount) && /* @__PURE__ */ jsx19(CardBankRadio, { label: "Bank", amount: (_b = Number(
|
|
4343
|
+
(paymentData == null ? void 0 : paymentData.isSkyFiAccount) && /* @__PURE__ */ jsx19(CardBankRadio, { label: "Bank", amount: (_b = Number(bankAmount)) == null ? void 0 : _b.toFixed(2), value: "ach", onChange: handletabchange, activetab }),
|
|
4309
4344
|
(props == null ? void 0 : props.isReader) && (paymentData == null ? void 0 : paymentData.paymentDeviceList) && ((_c = paymentData == null ? void 0 : paymentData.paymentDeviceList) == null ? void 0 : _c.length) > 0 && /* @__PURE__ */ jsx19(CardBankRadio, { label: "Reader", amount: (_d = Number(props == null ? void 0 : props.amount)) == null ? void 0 : _d.toFixed(2), value: "reader", onChange: handletabchange, activetab })
|
|
4310
4345
|
] }),
|
|
4311
|
-
!loading &&
|
|
4312
|
-
/* @__PURE__ */ jsxs11("small", { children: [
|
|
4313
|
-
|
|
4314
|
-
"
|
|
4315
|
-
|
|
4316
|
-
/* @__PURE__ */ jsx19("p", { children: formatUSD((Number(props.amount) - cashDiscount).toFixed(2)) })
|
|
4317
|
-
] }) : null : cashDiscount && cashDiscount > 0 && (props == null ? void 0 : props.pass_fee) && (activetab === "card" || activetab === "reader") ? /* @__PURE__ */ jsxs11("div", { className: "frac-cash-discount-fee", children: [
|
|
4318
|
-
/* @__PURE__ */ jsxs11("small", { children: [
|
|
4319
|
-
activetab === "card" || activetab === "reader" ? "Surcharge" : null,
|
|
4320
|
-
" "
|
|
4346
|
+
!loading && /* @__PURE__ */ jsxs11("div", { className: "", children: [
|
|
4347
|
+
activetab == "ach" && bankFeeAmount > 0 && /* @__PURE__ */ jsxs11("small", { className: "frac-fee-text", children: [
|
|
4348
|
+
"There is a processing fee of ",
|
|
4349
|
+
/* @__PURE__ */ jsx19("span", { className: "frac-fee-amount", children: formatUSD(bankFeeAmount.toFixed(2)) }),
|
|
4350
|
+
"."
|
|
4321
4351
|
] }),
|
|
4322
|
-
/* @__PURE__ */
|
|
4323
|
-
|
|
4352
|
+
(activetab === "card" || activetab === "reader") && (props == null ? void 0 : props.pass_fee) && cashDiscount && cashDiscount > 0 && /* @__PURE__ */ jsxs11("small", { className: "frac-fee-text", children: [
|
|
4353
|
+
"Credit cards include a fee amount of ",
|
|
4354
|
+
/* @__PURE__ */ jsx19("span", { className: "frac-fee-amount", children: formatUSD((Number(props.amount) - cashDiscount).toFixed(2)) }),
|
|
4355
|
+
"."
|
|
4356
|
+
] })
|
|
4357
|
+
] })
|
|
4324
4358
|
] })
|
|
4325
4359
|
] }),
|
|
4326
4360
|
/* @__PURE__ */ jsxs11("div", { className: "pay-conatiner-one-last", children: [
|
|
@@ -4625,7 +4659,7 @@ function GetPaymentPage(props) {
|
|
|
4625
4659
|
/* @__PURE__ */ jsx19(CardList, { listHeading: "Banks", paymentGateway: paymentData == null ? void 0 : paymentData.paymentGateway, ListItems: bankList, selectedCard, setSelectedCard, handleDeleteCard, otherButtonLabel: "Pay With Other Bank", otherButtonAction: () => {
|
|
4626
4660
|
setActiveinBank("form");
|
|
4627
4661
|
} }),
|
|
4628
|
-
/* @__PURE__ */ jsx19("div", { className: "form-group", style: { padding: "0" }, children: /* @__PURE__ */ jsx19("button", { className: "pay-button", style: { margin: "0px" }, type: "submit", onClick: handlepayment, children: formatUSD((_n = Number(
|
|
4662
|
+
/* @__PURE__ */ jsx19("div", { className: "form-group", style: { padding: "0" }, children: /* @__PURE__ */ jsx19("button", { className: "pay-button", style: { margin: "0px" }, type: "submit", onClick: handlepayment, children: formatUSD((_n = Number(bankAmount)) == null ? void 0 : _n.toFixed(2)) }) })
|
|
4629
4663
|
] }) : /* @__PURE__ */ jsxs11("form", { id: "ACHPaymentForm", style: { textAlign: "start" }, onSubmit: submitFunc, autoComplete: "off", onKeyDown: (e) => {
|
|
4630
4664
|
if (e.key === "Enter" && loading2) {
|
|
4631
4665
|
e.preventDefault();
|
|
@@ -4772,7 +4806,7 @@ function GetPaymentPage(props) {
|
|
|
4772
4806
|
errorBankConsentOther && /* @__PURE__ */ jsx19("span", { className: "error-span", children: errorBankConsentOther })
|
|
4773
4807
|
] })
|
|
4774
4808
|
] }),
|
|
4775
|
-
/* @__PURE__ */ jsx19("div", { className: "form-group ", children: /* @__PURE__ */ jsx19("button", { className: "pay-button", style: { margin: "20px 0 0" }, type: "submit", children: formatUSD((_v = Number(
|
|
4809
|
+
/* @__PURE__ */ jsx19("div", { className: "form-group ", children: /* @__PURE__ */ jsx19("button", { className: "pay-button", style: { margin: "20px 0 0" }, type: "submit", children: formatUSD((_v = Number(bankAmount)) == null ? void 0 : _v.toFixed(2)) }) })
|
|
4776
4810
|
] })
|
|
4777
4811
|
] }),
|
|
4778
4812
|
/* @__PURE__ */ jsxs11("div", { id: "reader", style: { display: activetab === "reader" ? "block" : "none" }, className: "tabcontent", children: [
|
|
@@ -7482,7 +7516,7 @@ import { IoArrowBack as IoArrowBack3 } from "react-icons/io5";
|
|
|
7482
7516
|
import { NumericFormat } from "react-number-format";
|
|
7483
7517
|
import { Fragment as Fragment17, jsx as jsx28, jsxs as jsxs17 } from "react/jsx-runtime";
|
|
7484
7518
|
function PartialPayment(props) {
|
|
7485
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x, _y, _z
|
|
7519
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x, _y, _z;
|
|
7486
7520
|
const buttonRef = useRef8(null);
|
|
7487
7521
|
useEffect13(() => {
|
|
7488
7522
|
if (props.onTriggerPay) {
|
|
@@ -8281,10 +8315,7 @@ function PartialPayment(props) {
|
|
|
8281
8315
|
] }),
|
|
8282
8316
|
/* @__PURE__ */ jsxs17("div", { className: "amt-pay-con", children: [
|
|
8283
8317
|
/* @__PURE__ */ jsx28("div", { className: "pay-amount-conatiner", children: /* @__PURE__ */ jsx28("small", { className: "pay-payment-amount", children: "Select payment type" }) }),
|
|
8284
|
-
/* @__PURE__ */
|
|
8285
|
-
/* @__PURE__ */ jsx28(CardBankRadio, { label: "Card", amount: (_a = Number(aftertaxAmount)) == null ? void 0 : _a.toFixed(2), value: "card", onChange: handletabchange, activetab }),
|
|
8286
|
-
(paymentData == null ? void 0 : paymentData.isSkyFiAccount) && /* @__PURE__ */ jsx28(CardBankRadio, { label: "Bank", amount: (_b = Number(cashDiscount)) == null ? void 0 : _b.toFixed(2), value: "ach", onChange: handletabchange, activetab })
|
|
8287
|
-
] }),
|
|
8318
|
+
/* @__PURE__ */ jsx28("div", { className: "frac-card-bank-radio-main", children: /* @__PURE__ */ jsx28(CardBankRadio, { label: "Card", amount: (_a = Number(aftertaxAmount)) == null ? void 0 : _a.toFixed(2), value: "card", onChange: handletabchange, activetab }) }),
|
|
8288
8319
|
numberToBoolean(paymentData == null ? void 0 : paymentData.showSurcharge) ? cashDiscount && cashDiscount > 0 && (props == null ? void 0 : props.pass_fee) ? /* @__PURE__ */ jsxs17("div", { className: "frac-cash-discount-fee", children: [
|
|
8289
8320
|
/* @__PURE__ */ jsxs17("small", { children: [
|
|
8290
8321
|
activetab === "card" ? "Cash Discount" : "Cash Discount Savings",
|
|
@@ -8353,7 +8384,7 @@ function PartialPayment(props) {
|
|
|
8353
8384
|
/* @__PURE__ */ jsx28("small", { className: "pay-payment-amount", children: "Payment Amount" }),
|
|
8354
8385
|
/* @__PURE__ */ jsxs17("strong", { className: "pay-amount", children: [
|
|
8355
8386
|
"$",
|
|
8356
|
-
(
|
|
8387
|
+
(_b = Number(aftertaxAmount)) == null ? void 0 : _b.toFixed(2)
|
|
8357
8388
|
] })
|
|
8358
8389
|
] }),
|
|
8359
8390
|
activetab != "ach" && /* @__PURE__ */ jsxs17("div", { children: [
|
|
@@ -8395,7 +8426,7 @@ function PartialPayment(props) {
|
|
|
8395
8426
|
/* @__PURE__ */ jsx28("small", { className: "pay-payment-amount", children: "Payment Amount" }),
|
|
8396
8427
|
/* @__PURE__ */ jsxs17("strong", { className: "pay-amount", children: [
|
|
8397
8428
|
"$",
|
|
8398
|
-
(
|
|
8429
|
+
(_c = Number(aftertaxAmount)) == null ? void 0 : _c.toFixed(2)
|
|
8399
8430
|
] })
|
|
8400
8431
|
] }),
|
|
8401
8432
|
/* @__PURE__ */ jsxs17("div", { children: [
|
|
@@ -8430,7 +8461,7 @@ function PartialPayment(props) {
|
|
|
8430
8461
|
/* @__PURE__ */ jsx28(CardList, { listHeading: "Cards", paymentGateway: paymentData == null ? void 0 : paymentData.paymentGateway, ListItems: cardList, selectedCard, setSelectedCard, handleDeleteCard, otherButtonLabel: "Pay With Other Card", otherButtonAction: () => {
|
|
8431
8462
|
setActiveinCard("form");
|
|
8432
8463
|
} }),
|
|
8433
|
-
/* @__PURE__ */ jsx28("div", { className: "form-group", style: { padding: "0" }, children: /* @__PURE__ */ jsx28("button", { className: "pay-button", style: { margin: "0px" }, type: "submit", onClick: handlepayment, children: partialAmount && !partialError ? formatUSD((
|
|
8464
|
+
/* @__PURE__ */ jsx28("div", { className: "form-group", style: { padding: "0" }, children: /* @__PURE__ */ jsx28("button", { className: "pay-button", style: { margin: "0px" }, type: "submit", onClick: handlepayment, children: partialAmount && !partialError ? formatUSD((_d = Number(partialAmount)) == null ? void 0 : _d.toFixed(2)) : formatUSD((_e = Number(aftertaxAmount)) == null ? void 0 : _e.toFixed(2)) }) })
|
|
8434
8465
|
] }) : (paymentData == null ? void 0 : paymentData.paymentGateway) === 32 ? /* @__PURE__ */ jsxs17(
|
|
8435
8466
|
"form",
|
|
8436
8467
|
{
|
|
@@ -8474,14 +8505,14 @@ function PartialPayment(props) {
|
|
|
8474
8505
|
maxLength: 100,
|
|
8475
8506
|
placeholder: "Order Id",
|
|
8476
8507
|
disabled: true,
|
|
8477
|
-
value: (
|
|
8508
|
+
value: (_f = props == null ? void 0 : props.orderID) != null ? _f : "",
|
|
8478
8509
|
style: { background: "#F6F6F7", color: "#727272" }
|
|
8479
8510
|
}
|
|
8480
8511
|
)
|
|
8481
8512
|
] }),
|
|
8482
8513
|
/* @__PURE__ */ jsxs17("div", { className: "form-group", children: [
|
|
8483
8514
|
/* @__PURE__ */ jsx28("label", { htmlFor: "zip", children: "ZIP" }),
|
|
8484
|
-
/* @__PURE__ */ jsx28("input", { type: "text", className: "form-control", maxLength: 100, placeholder: "000000", value: (
|
|
8515
|
+
/* @__PURE__ */ jsx28("input", { type: "text", className: "form-control", maxLength: 100, placeholder: "000000", value: (_g = cardData == null ? void 0 : cardData.zipCode) != null ? _g : "", onChange: (e) => handleCardChange("zipCode", e.target.value) }),
|
|
8485
8516
|
(cardError == null ? void 0 : cardError.zipCode) && /* @__PURE__ */ jsx28("span", { className: "error-span", children: cardError == null ? void 0 : cardError.zipCode })
|
|
8486
8517
|
] }),
|
|
8487
8518
|
(props == null ? void 0 : props.customerId) && /* @__PURE__ */ jsx28("div", { className: "form-group", children: /* @__PURE__ */ jsxs17("div", { style: { display: "flex", alignItems: "center", gap: "10px", paddingTop: "10px" }, children: [
|
|
@@ -8508,8 +8539,8 @@ function PartialPayment(props) {
|
|
|
8508
8539
|
] }) })
|
|
8509
8540
|
] }),
|
|
8510
8541
|
/* @__PURE__ */ jsxs17("div", { className: "form-group", style: { marginTop: "20px", padding: "0" }, children: [
|
|
8511
|
-
(paymentData == null ? void 0 : paymentData.paymentDeviceList) && ((
|
|
8512
|
-
/* @__PURE__ */ jsx28("button", { type: "submit", style: { margin: 0 }, className: "pay-button", children: partialAmount && !partialError ? formatUSD((
|
|
8542
|
+
(paymentData == null ? void 0 : paymentData.paymentDeviceList) && ((_h = paymentData == null ? void 0 : paymentData.paymentDeviceList) == null ? void 0 : _h.length) > 0 && /* @__PURE__ */ jsx28("button", { type: "button", style: { marginBottom: "10px" }, className: "pay-button", onClick: () => setActiveForm(!activeForm), children: activeForm ? "Pay With Reader" : "Pay With Card" }),
|
|
8543
|
+
/* @__PURE__ */ jsx28("button", { type: "submit", style: { margin: 0 }, className: "pay-button", children: partialAmount && !partialError ? formatUSD((_i = Number(partialAmount)) == null ? void 0 : _i.toFixed(2)) : formatUSD((_j = Number(aftertaxAmount)) == null ? void 0 : _j.toFixed(2)) })
|
|
8513
8544
|
] })
|
|
8514
8545
|
]
|
|
8515
8546
|
}
|
|
@@ -8548,14 +8579,14 @@ function PartialPayment(props) {
|
|
|
8548
8579
|
maxLength: 100,
|
|
8549
8580
|
placeholder: "Order Id",
|
|
8550
8581
|
disabled: true,
|
|
8551
|
-
value: (
|
|
8582
|
+
value: (_k = props == null ? void 0 : props.orderID) != null ? _k : "",
|
|
8552
8583
|
style: { background: "#F6F6F7", color: "#727272" }
|
|
8553
8584
|
}
|
|
8554
8585
|
)
|
|
8555
8586
|
] }),
|
|
8556
8587
|
/* @__PURE__ */ jsxs17("div", { className: "form-group", children: [
|
|
8557
8588
|
/* @__PURE__ */ jsx28("label", { htmlFor: "zip", children: "ZIP" }),
|
|
8558
|
-
/* @__PURE__ */ jsx28("input", { type: "text", className: "form-control", maxLength: 100, placeholder: "000000", value: (
|
|
8589
|
+
/* @__PURE__ */ jsx28("input", { type: "text", className: "form-control", maxLength: 100, placeholder: "000000", value: (_l = cardData == null ? void 0 : cardData.zipCode) != null ? _l : "", onChange: (e) => handleCardChange("zipCode", e.target.value) }),
|
|
8559
8590
|
(cardError == null ? void 0 : cardError.zipCode) && /* @__PURE__ */ jsx28("span", { className: "error-span", children: cardError == null ? void 0 : cardError.zipCode })
|
|
8560
8591
|
] }),
|
|
8561
8592
|
(props == null ? void 0 : props.customerId) && /* @__PURE__ */ jsx28("div", { className: "form-group", children: /* @__PURE__ */ jsxs17("div", { style: { display: "flex", alignItems: "center", gap: "10px", paddingTop: "10px" }, children: [
|
|
@@ -8582,8 +8613,8 @@ function PartialPayment(props) {
|
|
|
8582
8613
|
] }) })
|
|
8583
8614
|
] }),
|
|
8584
8615
|
/* @__PURE__ */ jsxs17("div", { className: "form-group", style: { marginTop: "20px", padding: "0" }, children: [
|
|
8585
|
-
(paymentData == null ? void 0 : paymentData.paymentDeviceList) && ((
|
|
8586
|
-
/* @__PURE__ */ jsx28("button", { type: "submit", style: { margin: 0 }, className: "pay-button", children: partialAmount && !partialError ? formatUSD((
|
|
8616
|
+
(paymentData == null ? void 0 : paymentData.paymentDeviceList) && ((_m = paymentData == null ? void 0 : paymentData.paymentDeviceList) == null ? void 0 : _m.length) > 0 && /* @__PURE__ */ jsx28("button", { type: "button", style: { marginBottom: "10px" }, className: "pay-button", onClick: () => setActiveForm(!activeForm), children: activeForm ? "Pay With Reader" : "Pay With Card" }),
|
|
8617
|
+
/* @__PURE__ */ jsx28("button", { type: "submit", style: { margin: 0 }, className: "pay-button", children: partialAmount && !partialError ? formatUSD((_n = Number(partialAmount)) == null ? void 0 : _n.toFixed(2)) : formatUSD((_o = Number(aftertaxAmount)) == null ? void 0 : _o.toFixed(2)) })
|
|
8587
8618
|
] })
|
|
8588
8619
|
] })
|
|
8589
8620
|
] }),
|
|
@@ -8599,7 +8630,7 @@ function PartialPayment(props) {
|
|
|
8599
8630
|
/* @__PURE__ */ jsx28(CardList, { listHeading: "Banks", paymentGateway: paymentData == null ? void 0 : paymentData.paymentGateway, ListItems: bankList, selectedCard, setSelectedCard, handleDeleteCard, otherButtonLabel: "Pay With Other Bank", otherButtonAction: () => {
|
|
8600
8631
|
setActiveinBank("form");
|
|
8601
8632
|
} }),
|
|
8602
|
-
/* @__PURE__ */ jsx28("div", { className: "form-group", style: { padding: "0" }, children: /* @__PURE__ */ jsx28("button", { className: "pay-button", style: { margin: "0px" }, type: "submit", onClick: handlepayment, children: partialAmount && !partialError ? formatUSD((
|
|
8633
|
+
/* @__PURE__ */ jsx28("div", { className: "form-group", style: { padding: "0" }, children: /* @__PURE__ */ jsx28("button", { className: "pay-button", style: { margin: "0px" }, type: "submit", onClick: handlepayment, children: partialAmount && !partialError ? formatUSD((_p = Number(partialAmount)) == null ? void 0 : _p.toFixed(2)) : formatUSD((_q = Number(cashDiscount)) == null ? void 0 : _q.toFixed(2)) }) })
|
|
8603
8634
|
] }) : /* @__PURE__ */ jsxs17("form", { id: "ACHPaymentForm", style: { textAlign: "start" }, onSubmit: submitFunc, autoComplete: "off", onKeyDown: (e) => {
|
|
8604
8635
|
if (e.key === "Enter" && loading2) {
|
|
8605
8636
|
e.preventDefault();
|
|
@@ -8612,7 +8643,7 @@ function PartialPayment(props) {
|
|
|
8612
8643
|
}, children: [
|
|
8613
8644
|
/* @__PURE__ */ jsxs17("div", { className: "form-group mb-4", children: [
|
|
8614
8645
|
/* @__PURE__ */ jsx28("label", { htmlFor: "nameonaccount", children: "Name on account" }),
|
|
8615
|
-
/* @__PURE__ */ jsx28("input", { type: "text", id: "nameonaccount", className: "form-control", maxLength: 100, placeholder: "John Doe", name: "name", value: (
|
|
8646
|
+
/* @__PURE__ */ jsx28("input", { type: "text", id: "nameonaccount", className: "form-control", maxLength: 100, placeholder: "John Doe", name: "name", value: (_r = achData == null ? void 0 : achData.name) != null ? _r : "", onChange: handleChangeAch }),
|
|
8616
8647
|
(achError == null ? void 0 : achError.name) && /* @__PURE__ */ jsx28("span", { className: "error-span", children: achError == null ? void 0 : achError.name })
|
|
8617
8648
|
] }),
|
|
8618
8649
|
/* @__PURE__ */ jsxs17("div", { className: "form-group mb-4", children: [
|
|
@@ -8626,7 +8657,7 @@ function PartialPayment(props) {
|
|
|
8626
8657
|
maxLength: 9,
|
|
8627
8658
|
placeholder: "000000000",
|
|
8628
8659
|
name: "routingNumber",
|
|
8629
|
-
value: (
|
|
8660
|
+
value: (_s = achData == null ? void 0 : achData.routingNumber) != null ? _s : "",
|
|
8630
8661
|
onChange: handleChangeAch
|
|
8631
8662
|
}
|
|
8632
8663
|
),
|
|
@@ -8643,7 +8674,7 @@ function PartialPayment(props) {
|
|
|
8643
8674
|
maxLength: 16,
|
|
8644
8675
|
placeholder: "0000000000",
|
|
8645
8676
|
name: "accountNumber",
|
|
8646
|
-
value: (
|
|
8677
|
+
value: (_t = achData == null ? void 0 : achData.accountNumber) != null ? _t : "",
|
|
8647
8678
|
onChange: handleChangeAch
|
|
8648
8679
|
}
|
|
8649
8680
|
),
|
|
@@ -8660,7 +8691,7 @@ function PartialPayment(props) {
|
|
|
8660
8691
|
maxLength: 16,
|
|
8661
8692
|
placeholder: "0000000000",
|
|
8662
8693
|
name: "confirmAccountNumber",
|
|
8663
|
-
value: (
|
|
8694
|
+
value: (_u = achData == null ? void 0 : achData.confirmAccountNumber) != null ? _u : "",
|
|
8664
8695
|
onChange: handleChangeAch
|
|
8665
8696
|
}
|
|
8666
8697
|
),
|
|
@@ -8677,7 +8708,7 @@ function PartialPayment(props) {
|
|
|
8677
8708
|
maxLength: 100,
|
|
8678
8709
|
placeholder: "My Bank",
|
|
8679
8710
|
name: "bankName",
|
|
8680
|
-
value: (
|
|
8711
|
+
value: (_v = achData == null ? void 0 : achData.bankName) != null ? _v : "",
|
|
8681
8712
|
onChange: handleChangeAch
|
|
8682
8713
|
}
|
|
8683
8714
|
),
|
|
@@ -8694,7 +8725,7 @@ function PartialPayment(props) {
|
|
|
8694
8725
|
maxLength: 100,
|
|
8695
8726
|
placeholder: "My Company",
|
|
8696
8727
|
name: "companyName",
|
|
8697
|
-
value: (
|
|
8728
|
+
value: (_w = achData == null ? void 0 : achData.companyName) != null ? _w : "",
|
|
8698
8729
|
onChange: handleChangeAch
|
|
8699
8730
|
}
|
|
8700
8731
|
),
|
|
@@ -8702,7 +8733,7 @@ function PartialPayment(props) {
|
|
|
8702
8733
|
] }),
|
|
8703
8734
|
/* @__PURE__ */ jsxs17("div", { className: "form-group mb-4", children: [
|
|
8704
8735
|
/* @__PURE__ */ jsx28("label", { htmlFor: "accounttype", children: "Select account type" }),
|
|
8705
|
-
/* @__PURE__ */ jsxs17("select", { name: "accountType", id: "accounttype", className: "form-control", value: (
|
|
8736
|
+
/* @__PURE__ */ jsxs17("select", { name: "accountType", id: "accounttype", className: "form-control", value: (_x = achData == null ? void 0 : achData.accountType) != null ? _x : "", onChange: handleChangeAch, children: [
|
|
8706
8737
|
/* @__PURE__ */ jsx28("option", { value: "", children: "Select account" }),
|
|
8707
8738
|
accountTypes.map((type) => /* @__PURE__ */ jsx28("option", { value: type.value, children: type.label }, type.value))
|
|
8708
8739
|
] })
|
|
@@ -8749,7 +8780,7 @@ function PartialPayment(props) {
|
|
|
8749
8780
|
errorBankConsentOther && /* @__PURE__ */ jsx28("span", { className: "error-span", children: errorBankConsentOther })
|
|
8750
8781
|
] })
|
|
8751
8782
|
] }),
|
|
8752
|
-
/* @__PURE__ */ jsx28("div", { className: "form-group ", children: /* @__PURE__ */ jsx28("button", { className: "pay-button", style: { margin: "20px 0 0" }, type: "submit", children: partialAmount && !partialError ? formatUSD((
|
|
8783
|
+
/* @__PURE__ */ jsx28("div", { className: "form-group ", children: /* @__PURE__ */ jsx28("button", { className: "pay-button", style: { margin: "20px 0 0" }, type: "submit", children: partialAmount && !partialError ? formatUSD((_y = Number(partialAmount)) == null ? void 0 : _y.toFixed(2)) : formatUSD((_z = Number(cashDiscount)) == null ? void 0 : _z.toFixed(2)) }) })
|
|
8753
8784
|
] })
|
|
8754
8785
|
] })
|
|
8755
8786
|
] }) }) })
|
|
@@ -12196,7 +12227,7 @@ form#ACHPaymentForm .ach-scrl {
|
|
|
12196
12227
|
}
|
|
12197
12228
|
@media screen and (max-width: 375px) {
|
|
12198
12229
|
.frac-payment-form-div .exp-date-year-container {
|
|
12199
|
-
flex-direction: column;
|
|
12230
|
+
// flex-direction: column;
|
|
12200
12231
|
}
|
|
12201
12232
|
.parent-pay-container {
|
|
12202
12233
|
padding: 10px;
|
|
@@ -12297,7 +12328,7 @@ padding:0px !important;
|
|
|
12297
12328
|
padding: 0px 10px;
|
|
12298
12329
|
}
|
|
12299
12330
|
.toggle-num-wrapper-new .input-main-wrap-frac {
|
|
12300
|
-
height:
|
|
12331
|
+
height: 38px;
|
|
12301
12332
|
}
|
|
12302
12333
|
.toggle-num-wrapper-new:focus {
|
|
12303
12334
|
border: 1px solid #004eab !important;
|