tf-checkout-react 1.4.25 → 1.4.26
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/api/index.d.ts +1 -1
- package/dist/components/stripePayment/index.d.ts +2 -1
- package/dist/tf-checkout-react.cjs.development.js +17 -11
- package/dist/tf-checkout-react.cjs.development.js.map +1 -1
- package/dist/tf-checkout-react.cjs.production.min.js +1 -1
- package/dist/tf-checkout-react.cjs.production.min.js.map +1 -1
- package/dist/tf-checkout-react.esm.js +17 -11
- package/dist/tf-checkout-react.esm.js.map +1 -1
- package/package.json +1 -1
- package/src/api/index.ts +5 -2
- package/src/components/paymentContainer/index.tsx +1 -0
- package/src/components/stripePayment/index.tsx +4 -2
package/dist/api/index.d.ts
CHANGED
|
@@ -71,4 +71,4 @@ export declare const updateVerificationStatus: () => Promise<{
|
|
|
71
71
|
data: UpdateVerificationStatusResponseData;
|
|
72
72
|
}>;
|
|
73
73
|
export declare const checkCustomerOrder: (orderHash: string) => Promise<any>;
|
|
74
|
-
export declare const refreshSeatReservation: (eventId: string) => Promise<AxiosResponse<any, AxiosRequestConfig<any>>>;
|
|
74
|
+
export declare const refreshSeatReservation: (eventId: string, orderId: string) => Promise<AxiosResponse<any, AxiosRequestConfig<any>>>;
|
|
@@ -17,6 +17,7 @@ export interface ICheckoutForm {
|
|
|
17
17
|
disableZipSection: boolean;
|
|
18
18
|
paymentButtonText?: string;
|
|
19
19
|
forPaymentPlan?: boolean;
|
|
20
|
+
orderId?: string;
|
|
20
21
|
}
|
|
21
|
-
declare const CheckoutForm: ({ total, onSubmit, stripeCardOptions, error, stripe_client_secret, currency, billing_info, isLoading, handleSetLoading, conditions, disableZipSection, paymentButtonText, forPaymentPlan, }: ICheckoutForm) => JSX.Element;
|
|
22
|
+
declare const CheckoutForm: ({ total, orderId, onSubmit, stripeCardOptions, error, stripe_client_secret, currency, billing_info, isLoading, handleSetLoading, conditions, disableZipSection, paymentButtonText, forPaymentPlan, }: ICheckoutForm) => JSX.Element;
|
|
22
23
|
export default CheckoutForm;
|
|
@@ -1795,13 +1795,15 @@ var checkCustomerOrder = /*#__PURE__*/function () {
|
|
|
1795
1795
|
};
|
|
1796
1796
|
}();
|
|
1797
1797
|
var refreshSeatReservation = /*#__PURE__*/function () {
|
|
1798
|
-
var _ref11 = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee11(eventId) {
|
|
1798
|
+
var _ref11 = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee11(eventId, orderId) {
|
|
1799
1799
|
var response;
|
|
1800
1800
|
return _regeneratorRuntime().wrap(function _callee11$(_context11) {
|
|
1801
1801
|
while (1) switch (_context11.prev = _context11.next) {
|
|
1802
1802
|
case 0:
|
|
1803
1803
|
_context11.next = 2;
|
|
1804
|
-
return publicRequest.patch("event/" + eventId + "/reservation/refresh/"
|
|
1804
|
+
return publicRequest.patch("event/" + eventId + "/reservation/refresh/", {
|
|
1805
|
+
order_id: orderId
|
|
1806
|
+
});
|
|
1805
1807
|
case 2:
|
|
1806
1808
|
response = _context11.sent;
|
|
1807
1809
|
return _context11.abrupt("return", response);
|
|
@@ -1811,7 +1813,7 @@ var refreshSeatReservation = /*#__PURE__*/function () {
|
|
|
1811
1813
|
}
|
|
1812
1814
|
}, _callee11);
|
|
1813
1815
|
}));
|
|
1814
|
-
return function refreshSeatReservation(_x11) {
|
|
1816
|
+
return function refreshSeatReservation(_x11, _x12) {
|
|
1815
1817
|
return _ref11.apply(this, arguments);
|
|
1816
1818
|
};
|
|
1817
1819
|
}();
|
|
@@ -4356,6 +4358,7 @@ var options = {
|
|
|
4356
4358
|
};
|
|
4357
4359
|
var CheckoutForm = function CheckoutForm(_ref) {
|
|
4358
4360
|
var total = _ref.total,
|
|
4361
|
+
orderId = _ref.orderId,
|
|
4359
4362
|
_ref$onSubmit = _ref.onSubmit,
|
|
4360
4363
|
onSubmit = _ref$onSubmit === void 0 ? _identity : _ref$onSubmit,
|
|
4361
4364
|
_ref$stripeCardOption = _ref.stripeCardOptions,
|
|
@@ -4473,26 +4476,28 @@ var CheckoutForm = function CheckoutForm(_ref) {
|
|
|
4473
4476
|
_yield$stripe$confirm = _context.sent;
|
|
4474
4477
|
_error = _yield$stripe$confirm.error;
|
|
4475
4478
|
if (!_error) {
|
|
4476
|
-
_context.next =
|
|
4479
|
+
_context.next = 37;
|
|
4477
4480
|
break;
|
|
4478
4481
|
}
|
|
4479
|
-
|
|
4482
|
+
_context.next = 34;
|
|
4483
|
+
return refreshSeatReservation(eventId, orderId || '');
|
|
4484
|
+
case 34:
|
|
4480
4485
|
setStripeError(_error.message);
|
|
4481
4486
|
handleSetLoading(false);
|
|
4482
4487
|
return _context.abrupt("return");
|
|
4483
|
-
case
|
|
4488
|
+
case 37:
|
|
4484
4489
|
onSubmit(null);
|
|
4485
|
-
_context.next =
|
|
4490
|
+
_context.next = 43;
|
|
4486
4491
|
break;
|
|
4487
|
-
case
|
|
4488
|
-
_context.prev =
|
|
4492
|
+
case 40:
|
|
4493
|
+
_context.prev = 40;
|
|
4489
4494
|
_context.t0 = _context["catch"](1);
|
|
4490
4495
|
onSubmit(_context.t0);
|
|
4491
|
-
case
|
|
4496
|
+
case 43:
|
|
4492
4497
|
case "end":
|
|
4493
4498
|
return _context.stop();
|
|
4494
4499
|
}
|
|
4495
|
-
}, _callee, null, [[1,
|
|
4500
|
+
}, _callee, null, [[1, 40]]);
|
|
4496
4501
|
}));
|
|
4497
4502
|
return function handleSubmit(_x) {
|
|
4498
4503
|
return _ref2.apply(this, arguments);
|
|
@@ -5152,6 +5157,7 @@ var PaymentContainer = function PaymentContainer(_ref) {
|
|
|
5152
5157
|
total: orderData.guest_count ? orderData.pay_now : orderData.total,
|
|
5153
5158
|
onSubmit: handlePaymentMiddleWare,
|
|
5154
5159
|
error: error,
|
|
5160
|
+
orderId: orderData.id,
|
|
5155
5161
|
currency: orderData.currency,
|
|
5156
5162
|
billing_info: reviewData.billing_info,
|
|
5157
5163
|
isLoading: paymentIsLoading,
|