@miden-npm/react 2.1.6 → 2.1.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.cjs +12 -8
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +12 -8
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -3627,6 +3627,7 @@ function PayByCard({
|
|
|
3627
3627
|
{
|
|
3628
3628
|
label: "Card Pin",
|
|
3629
3629
|
required: true,
|
|
3630
|
+
type: "password",
|
|
3630
3631
|
rules: ["numeric"],
|
|
3631
3632
|
value: payForm.cardPin,
|
|
3632
3633
|
mask: "0000",
|
|
@@ -3681,7 +3682,7 @@ function PayByCard({
|
|
|
3681
3682
|
}
|
|
3682
3683
|
),
|
|
3683
3684
|
/* @__PURE__ */ (0, import_jsx_runtime36.jsxs)("div", { className: "flex items-center justify-between gap-4 mt-6", children: [
|
|
3684
|
-
formIndex
|
|
3685
|
+
formIndex < 2 && /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
|
|
3685
3686
|
BaseButton,
|
|
3686
3687
|
{
|
|
3687
3688
|
label: "Previous",
|
|
@@ -3703,12 +3704,13 @@ function PayByCard({
|
|
|
3703
3704
|
disabled: isMakingPayment
|
|
3704
3705
|
}
|
|
3705
3706
|
),
|
|
3706
|
-
formIndex === 2 && /* @__PURE__ */ (0, import_jsx_runtime36.jsx)("div", { className: "w-
|
|
3707
|
+
formIndex === 2 && /* @__PURE__ */ (0, import_jsx_runtime36.jsx)("div", { className: "w-full", children: /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
|
|
3707
3708
|
BaseButton,
|
|
3708
3709
|
{
|
|
3709
3710
|
label: "Validate OTP",
|
|
3710
3711
|
type: "primary",
|
|
3711
3712
|
caller,
|
|
3713
|
+
customClass: "w-full",
|
|
3712
3714
|
loading: isValidatingOtp,
|
|
3713
3715
|
onClick: proceedHandler
|
|
3714
3716
|
}
|
|
@@ -4229,23 +4231,25 @@ var PayByStableCoin = ({
|
|
|
4229
4231
|
caller
|
|
4230
4232
|
);
|
|
4231
4233
|
if (response?.isSuccessful) {
|
|
4232
|
-
setPaymentReferenceDetails(
|
|
4233
|
-
|
|
4234
|
+
setPaymentReferenceDetails(
|
|
4235
|
+
caller === "buzapay" ? response.data : response
|
|
4236
|
+
);
|
|
4237
|
+
const needsConfirm = paymentReferenceDetails?.finalTransactionStatus == null || paymentReferenceDetails?.paymentStatus == null;
|
|
4234
4238
|
if (needsConfirm) {
|
|
4235
4239
|
setMessage("Transaction not confirmed !!");
|
|
4236
4240
|
setPaymentReferenceStatus("pending");
|
|
4237
4241
|
onPaymentAuthorized?.({
|
|
4238
4242
|
paymentId: transactionReference,
|
|
4239
|
-
paymentDate:
|
|
4243
|
+
paymentDate: paymentReferenceDetails?.updatedAt ?? (/* @__PURE__ */ new Date()).toISOString(),
|
|
4240
4244
|
paymentStatus: "pending",
|
|
4241
4245
|
message
|
|
4242
4246
|
});
|
|
4243
|
-
} else if (
|
|
4247
|
+
} else if (paymentReferenceDetails?.finalTransactionStatus === "Success" || paymentReferenceDetails?.paymentStatus === "Payment Received") {
|
|
4244
4248
|
setMessage("Transaction confirmed !!");
|
|
4245
4249
|
setPaymentReferenceStatus("confirmed");
|
|
4246
4250
|
onPaymentAuthorized?.({
|
|
4247
4251
|
paymentId: transactionReference,
|
|
4248
|
-
paymentDate:
|
|
4252
|
+
paymentDate: paymentReferenceDetails?.updatedAt ?? (/* @__PURE__ */ new Date()).toISOString(),
|
|
4249
4253
|
paymentStatus: "confirmed",
|
|
4250
4254
|
message
|
|
4251
4255
|
});
|
|
@@ -4255,7 +4259,7 @@ var PayByStableCoin = ({
|
|
|
4255
4259
|
setMessage(response.responseMessage || "");
|
|
4256
4260
|
onPaymentAuthorized?.({
|
|
4257
4261
|
paymentId: transactionReference,
|
|
4258
|
-
paymentDate:
|
|
4262
|
+
paymentDate: (/* @__PURE__ */ new Date()).toISOString(),
|
|
4259
4263
|
paymentStatus: "used",
|
|
4260
4264
|
message
|
|
4261
4265
|
});
|