tf-checkout-react 1.0.54 → 1.0.58
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/components/billing-info-container/index.d.ts +3 -1
- package/dist/components/confirmationContainer/index.d.ts +1 -1
- package/dist/components/paymentContainer/index.d.ts +3 -1
- package/dist/tf-checkout-react.cjs.development.css +1 -1
- package/dist/tf-checkout-react.cjs.development.js +87 -70
- 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 +88 -71
- package/dist/tf-checkout-react.esm.js.map +1 -1
- package/package.json +1 -1
- package/src/components/billing-info-container/index.tsx +74 -87
- package/src/components/billing-info-container/utils.ts +8 -0
- package/src/components/confirmationContainer/index.tsx +4 -3
- package/src/components/loginModal/index.tsx +1 -0
- package/src/components/paymentContainer/index.tsx +5 -1
- package/src/components/stripePayment/index.tsx +17 -13
- package/src/components/waitingList/index.tsx +2 -1
- package/src/components/waitingList/style.css +6 -0
|
@@ -24,8 +24,10 @@ export interface IBillingInfoPage {
|
|
|
24
24
|
onAuthorizeSuccess?: () => void;
|
|
25
25
|
onAuthorizeError?: (e: AxiosError) => void;
|
|
26
26
|
onLogin?: () => void;
|
|
27
|
+
onLoginSuccess?: () => void;
|
|
27
28
|
initialValues?: FormikValues;
|
|
28
29
|
buttonName?: string;
|
|
29
30
|
theme?: 'light' | 'dark';
|
|
31
|
+
isLoggedIn?: boolean;
|
|
30
32
|
}
|
|
31
|
-
export declare const BillingInfoContainer: ({ data, ticketHoldersFields, initialValues, buttonName, handleSubmit, theme, onRegisterSuccess, onRegisterError, onSubmitError, onGetCartSuccess, onGetCartError, onGetCountriesSuccess, onGetCountriesError, onGetStatesSuccess, onGetStatesError, onGetProfileDataSuccess, onGetProfileDataError, onAuthorizeSuccess, onAuthorizeError, onLogin, }: IBillingInfoPage) => JSX.Element;
|
|
33
|
+
export declare const BillingInfoContainer: ({ data, ticketHoldersFields, initialValues, buttonName, handleSubmit, theme, onRegisterSuccess, onRegisterError, onSubmitError, onGetCartSuccess, onGetCartError, onGetCountriesSuccess, onGetCountriesError, onGetStatesSuccess, onGetStatesError, onGetProfileDataSuccess, onGetProfileDataError, onAuthorizeSuccess, onAuthorizeError, onLogin, onLoginSuccess, isLoggedIn: pIsLoggedIn, }: IBillingInfoPage) => JSX.Element;
|
|
@@ -21,4 +21,4 @@ export interface IConfirmationPage {
|
|
|
21
21
|
onGetConfirmationDataSuccess: (res: any) => void;
|
|
22
22
|
onGetConfirmationDataError: (e: AxiosError) => void;
|
|
23
23
|
}
|
|
24
|
-
export declare const ConfirmationContainer: ({ referralPromotions, shareButtons, shareLink, onGetConfirmationDataSuccess, onGetConfirmationDataError, }: IConfirmationPage) => JSX.Element;
|
|
24
|
+
export declare const ConfirmationContainer: ({ isReferralEnabled, referralPromotions, shareButtons, shareLink, onGetConfirmationDataSuccess, onGetConfirmationDataError, }: IConfirmationPage) => JSX.Element;
|
|
@@ -2,6 +2,7 @@
|
|
|
2
2
|
import { AxiosError } from 'axios';
|
|
3
3
|
import './style.css';
|
|
4
4
|
import { IPaymentField } from '../../types';
|
|
5
|
+
import { StripeCardNumberElementOptions } from '@stripe/stripe-js';
|
|
5
6
|
export interface IPaymentPage {
|
|
6
7
|
paymentFields: IPaymentField[];
|
|
7
8
|
handlePayment: any;
|
|
@@ -12,5 +13,6 @@ export interface IPaymentPage {
|
|
|
12
13
|
onGetPaymentDataSuccess: (value: any) => void;
|
|
13
14
|
onGetPaymentDataError: (value: AxiosError) => void;
|
|
14
15
|
onPaymentError: (value: AxiosError) => void;
|
|
16
|
+
stripeCardOptions?: StripeCardNumberElementOptions;
|
|
15
17
|
}
|
|
16
|
-
export declare const PaymentContainer: ({ paymentFields, handlePayment, formTitle, errorText, checkoutData, onErrorClose, onGetPaymentDataSuccess, onGetPaymentDataError, onPaymentError, }: IPaymentPage) => JSX.Element;
|
|
18
|
+
export declare const PaymentContainer: ({ paymentFields, handlePayment, formTitle, errorText, checkoutData, onErrorClose, onGetPaymentDataSuccess, onGetPaymentDataError, onPaymentError, stripeCardOptions, }: IPaymentPage) => JSX.Element;
|
|
@@ -5,4 +5,4 @@
|
|
|
5
5
|
.style_card_form_inner__7vzGq{background:#232323;border-radius:8px;margin:0 auto 20px;min-width:325px;padding:15px;width:50%}.style_card_form_inner__7vzGq .style_card_label_text__F7GFa{color:#fff}.style_card_form_inner__7vzGq .style_StripeElement__jS5TJ{margin:5px 0 10px}.style_card_label_text__F7GFa{color:#fff}.style_payment_button__2rkp8{padding-top:15px;text-align:center}.style_payment_button__2rkp8 button{background-color:#212529;border-radius:8px;color:#fff;cursor:pointer;font-size:26px;padding:15px 30px;transition:opacity .5s;width:200px}.style_payment_button__2rkp8 button:hover{opacity:.7}.style_disabled-payment-button__3MiUR button{opacity:.3;pointer-events:none;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.style_checkout_error_block__3LUN5{color:#e53935;font-weight:600;padding:15px 0}.style_zip_element__31oFa p{margin-bottom:0}.style_zip_element__31oFa input{background-color:#232323;border:none;color:#fff;font-size:18px;margin-top:5px;outline:none;width:100%}
|
|
6
6
|
.style_confirmation-page__1F9Sh{margin:0 auto;max-width:1024px}.style_confirmation-page__1F9Sh .style_strong-text__27fPG{font-weight:700}.style_confirmation-page__1F9Sh .style_title__2Al5H{color:#333;font-size:24px;font-weight:600}.style_confirmation-page__1F9Sh .style_share-message-section__3tRfP{background:#dff0d8;border:1px solid #d6e9c6;border-radius:5px;color:#2c7221;display:flex;flex-direction:column;margin:20px 0;padding:15px}.style_confirmation-page__1F9Sh .style_main__3LBFA{font-size:15px;font-weight:700}.style_confirmation-page__1F9Sh .style_helper__3L5l6,.style_confirmation-page__1F9Sh .style_main__3LBFA{font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen,Ubuntu,Cantarell,Open Sans,Helvetica Neue,Icons16,sans-serif}.style_confirmation-page__1F9Sh .style_helper__3L5l6{font-size:14px;margin-top:5px}.style_confirmation-page__1F9Sh .style_referral_text_image_section__1shCe{align-items:center;display:flex;flex-wrap:wrap;justify-content:space-between;margin:20px -10px}.style_confirmation-page__1F9Sh .style_referral_text_image_section__1shCe .style_referral_text_section__3dvbC{margin:10px}.style_confirmation-page__1F9Sh .style_referral_text_image_section__1shCe .style_referral_title_text__1zFZX{color:#f08057;font-size:28px;padding-bottom:10px}.style_confirmation-page__1F9Sh .style_referral_text_image_section__1shCe .style_referral_text__2tAKA{font-size:18px}.style_confirmation-page__1F9Sh .style_referral_text_image_section__1shCe img{margin:10px;max-width:200px}.style_confirmation-page__1F9Sh .style_share_wrapper__3JrMz{-moz-column-gap:5rem;column-gap:5rem;display:grid;grid-template-columns:repeat(auto-fit,minmax(240px,1fr));margin:10px}.style_confirmation-page__1F9Sh .style_share_wrapper__3JrMz .style_invitation_title__x4iqi{font-size:22px;padding-bottom:12px;padding-top:12px}.style_confirmation-page__1F9Sh .style_share_wrapper__3JrMz .style_share_section__2XjM2{display:flex;flex-wrap:wrap;justify-content:space-between;margin:0 -10px}.style_confirmation-page__1F9Sh .style_share_wrapper__3JrMz .style_share_section__2XjM2 .style_invitation_section__1xH0Z{flex:1 1;padding:0 5px}.style_confirmation-page__1F9Sh .style_share_wrapper__3JrMz .style_share_section__2XjM2 .style_invitation_section__1xH0Z .style_share_buttons__2C4eT{display:grid;flex-wrap:wrap;margin:0 -7px}.style_confirmation-page__1F9Sh .style_share_wrapper__3JrMz .style_share_section__2XjM2 .style_invitation_section__1xH0Z .style_share_buttons__2C4eT .style_social-media-btns__2kCat{display:grid;grid-template-columns:repeat(auto-fit,minmax(150px,1fr))}.style_confirmation-page__1F9Sh .style_share_wrapper__3JrMz .style_share_section__2XjM2 .style_invitation_section__1xH0Z .style_share_buttons__2C4eT .style_social-media-btns__2kCat .style_sharing-btn__IVnek{min-width:130px}.style_confirmation-page__1F9Sh .style_share_wrapper__3JrMz .style_share_section__2XjM2 .style_invitation_section__1xH0Z .style_share-btn-inner__2HBGQ.style_share-by-link-copy__25qUa{padding:0;text-align:left}.style_confirmation-page__1F9Sh .style_share_wrapper__3JrMz .style_share_section__2XjM2 .style_invitation_section__1xH0Z .style_sharing-button__3R2yU{flex:1 1}.style_confirmation-page__1F9Sh .style_share_wrapper__3JrMz .style_share_section__2XjM2 .style_invitation_section__1xH0Z .style_convenient_buttons__2RFH8.style_sharing-btn__IVnek{display:inline}.style_confirmation-page__1F9Sh .style_share_wrapper__3JrMz .style_share_section__2XjM2 .style_invitation_section__1xH0Z .style_share-by-link__2B83J{background:#000;color:#fff;padding:0}.style_confirmation-page__1F9Sh .style_share_wrapper__3JrMz .style_share_section__2XjM2 .style_invitation_section__1xH0Z .style_share-by-link__2B83J.style_label__3FIno{margin:0;padding:0;text-align:left}.style_confirmation-page__1F9Sh .style_share_wrapper__3JrMz .style_share_section__2XjM2 .style_invitation_section__1xH0Z .style_sharing-btn__IVnek{flex:1 1;padding:7px;text-align:center}.style_confirmation-page__1F9Sh .style_share_wrapper__3JrMz .style_share_section__2XjM2 .style_invitation_section__1xH0Z .style_share-btn-inner__2HBGQ{background:#000;color:#fff;padding:10px}.style_confirmation-page__1F9Sh .style_share_wrapper__3JrMz .style_share_section__2XjM2 .style_invitation_section__1xH0Z .style_share-btn-inner__2HBGQ .style_svg_wrapper__268DZ{display:inline}.style_confirmation-page__1F9Sh .style_share_wrapper__3JrMz .style_share_section__2XjM2 .style_invitation_section__1xH0Z .style_share-btn-inner__2HBGQ .style_share-input__2Pp7g{background-color:#fff;text-align:left;width:300px}.style_confirmation-page__1F9Sh .style_share_wrapper__3JrMz .style_share_section__2XjM2 .style_invitation_section__1xH0Z .style_share-text__V36JV{display:block;font-size:13px;font-weight:600;padding-top:8px;width:100%}.style_confirmation-page__1F9Sh .style_share_wrapper__3JrMz .style_pricing-section_wrapper__1aDnf{background:#e3e3e3;border:1px solid #dcdcdc;display:grid;grid-template-columns:1fr 1fr;margin:10px 0;padding:15px}.style_confirmation-page__1F9Sh .style_share_wrapper__3JrMz .style_pricing-section_wrapper__1aDnf.style_free_price__3Hd0-{background:#e9835b;border:1px solid #eb7b4a;color:#fff}.style_confirmation-page__1F9Sh .style_share_wrapper__3JrMz .style_pricing-section_label__3SVoy{font-weight:600}.style_confirmation-page__1F9Sh .style_share_wrapper__3JrMz .style_pricing-section_sublabel__2Ckqd{font-size:14px;font-weight:100}.style_confirmation-page__1F9Sh .style_share_wrapper__3JrMz .style_pricing-section_price__3v8bL{font-weight:600;text-align:right}
|
|
7
7
|
body{margin:0;padding:0}.style_get-tickets-page__11KeR{width:100%}.style_event-detail__tier__2CcMs{background-color:#fff;padding:17px 35px 20px}.style_event-detail__tier-name__116US{color:#000;font-family:Inter-Bold;font-family:Bebas Neue;font-size:.85rem;font-weight:700;letter-spacing:.2em;line-height:1.3;margin-bottom:8px;margin-top:16px;padding-right:20%;text-transform:uppercase}.style_event-detail__tier-status__IbqO1{align-items:center;display:flex;flex-direction:row;flex-wrap:wrap;justify-content:space-between;margin-top:8px;width:100%}.style_event-detail__tier-status__IbqO1.style_ticket-button__Nty1u{background-color:#212529;border:3px solid #000;border-radius:0;color:#fff;cursor:pointer;font-weight:700;letter-spacing:.2em;line-height:1.5;margin-bottom:10px;width:200px}.style_event-tickets-container__3vdaQ{align-items:center;display:flex;justify-content:space-between}.style_event-detail__tier-status__IbqO1.style_ticket-button__Nty1u.style_true__g6yhC{background-color:#c1c3c6;border-color:#afb0b1}.style_event-detail__tier-price__3doIb{color:#000;font-family:Inter-Bold;font-size:1.5rem;font-weight:700;line-height:1;text-align:center}.style_event-detail__tier-price__3doIb p{margin:0}.style_event-detail__tier-price__3doIb .style_fees__19QjH{font-size:14px;font-weight:400;margin-top:4px;text-align:left}.style_event-detail__tier-price__3doIb .style_old-price__2mSOJ{color:red;font-size:1.3rem;margin-bottom:5px;text-decoration:line-through}.style_alert-info__24Mx5{background-color:#d9edf7;border:1px solid #bce8f1;border-radius:4px;color:#3a87ad;font-size:1em;margin:0 35px;padding:8px 15px;text-align:center;text-shadow:0 1px 0 hsla(0,0%,100%,.5)}.style_event-detail__tier-state__2ethF{color:#30bc9d;font-family:Inter-Bold;font-size:.75rem;font-weight:300;line-height:1;text-align:right;text-transform:uppercase}.style_promo-code-block__ttqVr input{font-size:14px;padding:1px 8px}.style_book-button__1krJI{background-color:#212529;border:3px solid #000;border-radius:0;color:#fff;cursor:pointer;display:block;font-size:26px;font-weight:700;height:50px;letter-spacing:.2em;line-height:1.5;margin:25px auto 10px;text-align:center;width:100%}.style_book-button__1krJI:hover{background-color:#505050;border-color:#505050}.style_loader-container__3iPe2{align-items:center;display:flex;height:100%;justify-content:center;width:100%}.style_get-tickets-paper__3ZF-f::-webkit-scrollbar{width:5px}.style_get-tickets-paper__3ZF-f::-webkit-scrollbar-track{background:#f1f1f1}.style_get-tickets-paper__3ZF-f::-webkit-scrollbar-thumb{background:#888}.style_get-tickets-paper__3ZF-f::-webkit-scrollbar-thumb:hover{background:#555}.style_get-tickets__3Sghy .style_get-tickets__selectbox__2ApAj{width:100%}.style_disabled__310xq{pointer-events:none;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.style_hidden__ceCor{display:none}
|
|
8
|
-
.style_waiting-list__2sJxM{padding:17px 35px 20px}.style_waiting-list__2sJxM .style_field-item__34MYc{margin-bottom:30px}.style_waiting-list__2sJxM .style_waiting-list-button__tO7D2{width:100%!important}.style_waiting-list__2sJxM .style_waiting-list-button__tO7D2:hover{background-color:#505050}.style_waiting-list__2sJxM .style_success-message__BvF3R h3{margin:10px 0}.style_waiting-list__2sJxM .style_success-message__BvF3R p{margin:0}
|
|
8
|
+
.style_waiting-list__2sJxM{padding:17px 35px 20px}.style_waiting-list__2sJxM .style_field-item__34MYc{margin-bottom:30px}.style_waiting-list__2sJxM .style_waiting-list-button__tO7D2{width:100%!important}.style_waiting-list__2sJxM .style_waiting-list-button__tO7D2:hover{background-color:#505050}.style_waiting-list__2sJxM .style_success-message__BvF3R h3{margin:10px 0}.style_waiting-list__2sJxM .style_success-message__BvF3R p{margin:0}.style_waiting-list__2sJxM .style_no-tickets-text__zGdaP{text-align:center}.style_waiting-list__2sJxM .style_added-success-message__FbPZS{font-size:22px}
|
|
@@ -1255,7 +1255,11 @@ var LoginModal = function LoginModal(_ref) {
|
|
|
1255
1255
|
onSubmit: props.handleSubmit
|
|
1256
1256
|
}, React__default.createElement("div", {
|
|
1257
1257
|
className: "modal-title"
|
|
1258
|
-
}, "Login"), React__default.createElement("
|
|
1258
|
+
}, "Login"), React__default.createElement("img", {
|
|
1259
|
+
className: "login-logo-tff",
|
|
1260
|
+
src: "https://www.ticketfairy.com/resources/images/logo-ttf-black.svg",
|
|
1261
|
+
alt: ""
|
|
1262
|
+
}), React__default.createElement("div", {
|
|
1259
1263
|
className: "server_auth__error"
|
|
1260
1264
|
}, error), alreadyHasUser && React__default.createElement("p", {
|
|
1261
1265
|
className: "info-text-for-login"
|
|
@@ -1522,8 +1526,12 @@ var getInitialValues = function getInitialValues(data, propsInitialValues, userV
|
|
|
1522
1526
|
|
|
1523
1527
|
_forEach(results, function (item) {
|
|
1524
1528
|
initialValues[item] = propsInitialValues[item] || userValues[item] || '';
|
|
1525
|
-
});
|
|
1529
|
+
}); // set logged in user as first ticket holder
|
|
1526
1530
|
|
|
1531
|
+
|
|
1532
|
+
initialValues['holderFirstName-0'] = propsInitialValues.firstName || userValues.firstName || '';
|
|
1533
|
+
initialValues['holderLastName-0'] = propsInitialValues.lastName || userValues.lastName || '';
|
|
1534
|
+
initialValues['holderEmail-0'] = propsInitialValues.email || userValues.email || '';
|
|
1527
1535
|
return initialValues;
|
|
1528
1536
|
};
|
|
1529
1537
|
var createRegisterFormData = function createRegisterFormData(values, checkoutBody) {
|
|
@@ -1924,7 +1932,10 @@ var LogicRunner = function LogicRunner(_ref) {
|
|
|
1924
1932
|
brand_opt_in: (parsedData == null ? void 0 : parsedData.brand_opt_in) || '',
|
|
1925
1933
|
city: (parsedData == null ? void 0 : parsedData.city) || '',
|
|
1926
1934
|
confirmPassword: '',
|
|
1927
|
-
password: ''
|
|
1935
|
+
password: '',
|
|
1936
|
+
'holderFirstName-0': (parsedData == null ? void 0 : parsedData.first_name) || '',
|
|
1937
|
+
'holderLastName-0': (parsedData == null ? void 0 : parsedData.last_name) || '',
|
|
1938
|
+
'holderEmail-0': (parsedData == null ? void 0 : parsedData.email) || ''
|
|
1928
1939
|
};
|
|
1929
1940
|
setValues(mappedValues);
|
|
1930
1941
|
setUserValues(mappedValues);
|
|
@@ -1981,47 +1992,56 @@ var BillingInfoContainer = function BillingInfoContainer(_ref3) {
|
|
|
1981
1992
|
_ref3$onAuthorizeErro = _ref3.onAuthorizeError,
|
|
1982
1993
|
onAuthorizeError = _ref3$onAuthorizeErro === void 0 ? function () {} : _ref3$onAuthorizeErro,
|
|
1983
1994
|
_ref3$onLogin = _ref3.onLogin,
|
|
1984
|
-
onLogin = _ref3$onLogin === void 0 ? function () {} : _ref3$onLogin
|
|
1985
|
-
|
|
1986
|
-
|
|
1995
|
+
onLogin = _ref3$onLogin === void 0 ? function () {} : _ref3$onLogin,
|
|
1996
|
+
_ref3$onLoginSuccess = _ref3.onLoginSuccess,
|
|
1997
|
+
onLoginSuccess = _ref3$onLoginSuccess === void 0 ? function () {} : _ref3$onLoginSuccess,
|
|
1998
|
+
_ref3$isLoggedIn = _ref3.isLoggedIn,
|
|
1999
|
+
pIsLoggedIn = _ref3$isLoggedIn === void 0 ? false : _ref3$isLoggedIn;
|
|
2000
|
+
var isWindowDefined = typeof window !== 'undefined';
|
|
2001
|
+
var userData = isWindowDefined && window.localStorage.getItem('user_data') ? JSON.parse(window.localStorage.getItem('user_data') || '') : {};
|
|
2002
|
+
var access_token = isWindowDefined && window.localStorage.getItem('access_token') ? window.localStorage.getItem('access_token') || '' : '';
|
|
1987
2003
|
|
|
1988
2004
|
var _useState = React.useState(data),
|
|
1989
2005
|
dataWithUniqueIds = _useState[0],
|
|
1990
2006
|
setDataWithUniqueIds = _useState[1];
|
|
1991
2007
|
|
|
1992
|
-
var _useState2 = React.useState(
|
|
1993
|
-
|
|
1994
|
-
|
|
2008
|
+
var _useState2 = React.useState(!!access_token),
|
|
2009
|
+
isLoggedIn = _useState2[0],
|
|
2010
|
+
setIsLoggedIn = _useState2[1];
|
|
1995
2011
|
|
|
1996
|
-
var _useState3 = React.useState(
|
|
1997
|
-
|
|
1998
|
-
|
|
2012
|
+
var _useState3 = React.useState({}),
|
|
2013
|
+
cartInfoData = _useState3[0],
|
|
2014
|
+
setCartInfo = _useState3[1];
|
|
1999
2015
|
|
|
2000
2016
|
var _useState4 = React.useState([]),
|
|
2001
|
-
|
|
2002
|
-
|
|
2017
|
+
countries = _useState4[0],
|
|
2018
|
+
setCountries = _useState4[1];
|
|
2003
2019
|
|
|
2004
|
-
var _useState5 = React.useState(
|
|
2005
|
-
|
|
2006
|
-
|
|
2020
|
+
var _useState5 = React.useState([]),
|
|
2021
|
+
states = _useState5[0],
|
|
2022
|
+
setStates = _useState5[1];
|
|
2007
2023
|
|
|
2008
2024
|
var _useState6 = React.useState(false),
|
|
2009
|
-
|
|
2010
|
-
|
|
2025
|
+
showModalLogin = _useState6[0],
|
|
2026
|
+
setShowModalLogin = _useState6[1];
|
|
2011
2027
|
|
|
2012
2028
|
var _useState7 = React.useState(false),
|
|
2013
|
-
|
|
2014
|
-
|
|
2029
|
+
alreadyHasUser = _useState7[0],
|
|
2030
|
+
setAlreadyHasUser = _useState7[1];
|
|
2015
2031
|
|
|
2016
2032
|
var _useState8 = React.useState(false),
|
|
2017
|
-
|
|
2018
|
-
|
|
2033
|
+
userExpired = _useState8[0],
|
|
2034
|
+
setUserExpired = _useState8[1];
|
|
2035
|
+
|
|
2036
|
+
var _useState9 = React.useState(false),
|
|
2037
|
+
showModalRegister = _useState9[0],
|
|
2038
|
+
setShowModalRegister = _useState9[1];
|
|
2019
2039
|
|
|
2020
|
-
var
|
|
2021
|
-
ticketsQuantity =
|
|
2022
|
-
setTicketsQuantity =
|
|
2040
|
+
var _useState10 = React.useState([]),
|
|
2041
|
+
ticketsQuantity = _useState10[0],
|
|
2042
|
+
setTicketsQuantity = _useState10[1];
|
|
2023
2043
|
|
|
2024
|
-
var
|
|
2044
|
+
var _useState11 = React.useState({
|
|
2025
2045
|
firstName: '',
|
|
2026
2046
|
lastName: '',
|
|
2027
2047
|
email: '',
|
|
@@ -2036,10 +2056,8 @@ var BillingInfoContainer = function BillingInfoContainer(_ref3) {
|
|
|
2036
2056
|
state: '',
|
|
2037
2057
|
zip: ''
|
|
2038
2058
|
}),
|
|
2039
|
-
userValues =
|
|
2040
|
-
setUserValues =
|
|
2041
|
-
|
|
2042
|
-
var isLoggedIn = !!access_token;
|
|
2059
|
+
userValues = _useState11[0],
|
|
2060
|
+
setUserValues = _useState11[1];
|
|
2043
2061
|
|
|
2044
2062
|
var emailLogged = _get(userData, 'email', '') || _get(userValues, 'email', '');
|
|
2045
2063
|
|
|
@@ -2048,7 +2066,6 @@ var BillingInfoContainer = function BillingInfoContainer(_ref3) {
|
|
|
2048
2066
|
var lastNameLogged = _get(userData, 'last_name', '') || _get(userValues, 'last_name', '');
|
|
2049
2067
|
|
|
2050
2068
|
var showDOB = getQueryVariable('age_required') === 'true';
|
|
2051
|
-
var showTicketHolderName = getQueryVariable('names_required') === 'true';
|
|
2052
2069
|
var eventId = getQueryVariable('event_id');
|
|
2053
2070
|
|
|
2054
2071
|
var optedInFieldValue = _get(cartInfoData, 'optedIn', false);
|
|
@@ -2069,8 +2086,13 @@ var BillingInfoContainer = function BillingInfoContainer(_ref3) {
|
|
|
2069
2086
|
qty += +item.quantity;
|
|
2070
2087
|
});
|
|
2071
2088
|
return qty;
|
|
2072
|
-
};
|
|
2089
|
+
};
|
|
2073
2090
|
|
|
2091
|
+
React.useEffect(function () {
|
|
2092
|
+
if ((pIsLoggedIn || access_token) && !isLoggedIn) {
|
|
2093
|
+
setIsLoggedIn(true);
|
|
2094
|
+
}
|
|
2095
|
+
}, [pIsLoggedIn, isLoggedIn, access_token]); //just once
|
|
2074
2096
|
|
|
2075
2097
|
React.useEffect(function () {
|
|
2076
2098
|
// fetch countries data
|
|
@@ -2179,7 +2201,7 @@ var BillingInfoContainer = function BillingInfoContainer(_ref3) {
|
|
|
2179
2201
|
case 0:
|
|
2180
2202
|
_context4.prev = 0;
|
|
2181
2203
|
|
|
2182
|
-
if (!(
|
|
2204
|
+
if (!(isWindowDefined && token)) {
|
|
2183
2205
|
_context4.next = 10;
|
|
2184
2206
|
break;
|
|
2185
2207
|
}
|
|
@@ -2260,7 +2282,7 @@ var BillingInfoContainer = function BillingInfoContainer(_ref3) {
|
|
|
2260
2282
|
_profileSpecifiedData = _get(updatedUserData, 'data.data');
|
|
2261
2283
|
_profileDataObj = setLoggedUserData(_profileSpecifiedData);
|
|
2262
2284
|
|
|
2263
|
-
if (
|
|
2285
|
+
if (isWindowDefined) {
|
|
2264
2286
|
window.localStorage.setItem('user_data', JSON.stringify(_profileDataObj));
|
|
2265
2287
|
}
|
|
2266
2288
|
|
|
@@ -2338,7 +2360,7 @@ var BillingInfoContainer = function BillingInfoContainer(_ref3) {
|
|
|
2338
2360
|
profileSpecifiedData = _get(profileData, 'data.data');
|
|
2339
2361
|
profileDataObj = setLoggedUserData(profileSpecifiedData);
|
|
2340
2362
|
|
|
2341
|
-
if (
|
|
2363
|
+
if (isWindowDefined) {
|
|
2342
2364
|
window.localStorage.setItem('user_data', JSON.stringify(profileDataObj));
|
|
2343
2365
|
}
|
|
2344
2366
|
|
|
@@ -2362,7 +2384,7 @@ var BillingInfoContainer = function BillingInfoContainer(_ref3) {
|
|
|
2362
2384
|
|
|
2363
2385
|
if (axios.isAxiosError(_context5.t1)) {
|
|
2364
2386
|
if (((_e$response2 = _context5.t1.response) == null ? void 0 : _e$response2.data.error) === 'invalid_token') {
|
|
2365
|
-
if (
|
|
2387
|
+
if (isWindowDefined) {
|
|
2366
2388
|
window.localStorage.removeItem('user_data');
|
|
2367
2389
|
window.localStorage.removeItem('access_token');
|
|
2368
2390
|
setUserExpired(true);
|
|
@@ -2415,35 +2437,18 @@ var BillingInfoContainer = function BillingInfoContainer(_ref3) {
|
|
|
2415
2437
|
var label = item.label,
|
|
2416
2438
|
labelClassName = item.labelClassName,
|
|
2417
2439
|
fields = item.fields;
|
|
2418
|
-
|
|
2419
|
-
if (label === 'Ticket Holders' && !showTicketHolderName && !showDOB) {
|
|
2420
|
-
return null;
|
|
2421
|
-
}
|
|
2422
|
-
|
|
2423
2440
|
return React__default.createElement(React__default.Fragment, {
|
|
2424
2441
|
key: item.uniqueId
|
|
2425
2442
|
}, React__default.createElement("p", {
|
|
2426
2443
|
className: labelClassName
|
|
2427
2444
|
}, label), _map(fields, function (group) {
|
|
2428
2445
|
var groupClassname = group.groupClassname,
|
|
2429
|
-
groupItems = group.groupItems
|
|
2430
|
-
groupLabel = group.groupLabel,
|
|
2431
|
-
groupLabelClassName = group.groupLabelClassName;
|
|
2446
|
+
groupItems = group.groupItems;
|
|
2432
2447
|
return React__default.createElement(React__default.Fragment, {
|
|
2433
2448
|
key: group.uniqueId
|
|
2434
|
-
},
|
|
2435
|
-
className: groupLabelClassName
|
|
2436
|
-
}, groupLabel), React__default.createElement("div", {
|
|
2449
|
+
}, React__default.createElement("div", {
|
|
2437
2450
|
className: groupClassname
|
|
2438
2451
|
}, _map(groupItems.filter(function (el) {
|
|
2439
|
-
if (el.name === 'holderFirstName' && !showTicketHolderName) {
|
|
2440
|
-
return false;
|
|
2441
|
-
}
|
|
2442
|
-
|
|
2443
|
-
if (el.name === 'holderLastName' && !showTicketHolderName) {
|
|
2444
|
-
return false;
|
|
2445
|
-
}
|
|
2446
|
-
|
|
2447
2452
|
if (el.name === 'holderAge' && !showDOB) {
|
|
2448
2453
|
return false;
|
|
2449
2454
|
}
|
|
@@ -2454,7 +2459,7 @@ var BillingInfoContainer = function BillingInfoContainer(_ref3) {
|
|
|
2454
2459
|
|
|
2455
2460
|
return true;
|
|
2456
2461
|
}), function (element) {
|
|
2457
|
-
return ['password', 'confirmPassword'].includes(element.name) && isLoggedIn ? null : React__default.createElement(React__default.Fragment, {
|
|
2462
|
+
return ['password', 'confirmPassword', 'password-info'].includes(element.name) && isLoggedIn ? null : React__default.createElement(React__default.Fragment, {
|
|
2458
2463
|
key: element.uniqueId
|
|
2459
2464
|
}, element.name === 'email' ? React__default.createElement("div", {
|
|
2460
2465
|
className: "email-checking"
|
|
@@ -2471,7 +2476,7 @@ var BillingInfoContainer = function BillingInfoContainer(_ref3) {
|
|
|
2471
2476
|
})));
|
|
2472
2477
|
})));
|
|
2473
2478
|
}));
|
|
2474
|
-
}),
|
|
2479
|
+
}), React__default.createElement("div", {
|
|
2475
2480
|
className: "ticket-holders-fields"
|
|
2476
2481
|
}, React__default.createElement("p", null, ticketHoldersFields.label), _map(ticketsQuantity, function (_item, index) {
|
|
2477
2482
|
return React__default.createElement("div", {
|
|
@@ -2497,7 +2502,7 @@ var BillingInfoContainer = function BillingInfoContainer(_ref3) {
|
|
|
2497
2502
|
}));
|
|
2498
2503
|
})));
|
|
2499
2504
|
}));
|
|
2500
|
-
}))
|
|
2505
|
+
})), React__default.createElement("div", {
|
|
2501
2506
|
className: "button-container"
|
|
2502
2507
|
}, React__default.createElement(LoadingButton, {
|
|
2503
2508
|
type: "submit",
|
|
@@ -2517,6 +2522,7 @@ var BillingInfoContainer = function BillingInfoContainer(_ref3) {
|
|
|
2517
2522
|
onLogin: function onLogin() {
|
|
2518
2523
|
setShowModalLogin(false);
|
|
2519
2524
|
setUserExpired(false);
|
|
2525
|
+
onLoginSuccess();
|
|
2520
2526
|
},
|
|
2521
2527
|
alreadyHasUser: alreadyHasUser,
|
|
2522
2528
|
userExpired: userExpired,
|
|
@@ -2610,6 +2616,9 @@ var options = {
|
|
|
2610
2616
|
fontSize: '18px',
|
|
2611
2617
|
color: '#ffffff',
|
|
2612
2618
|
letterSpacing: '1px',
|
|
2619
|
+
':-webkit-autofill': {
|
|
2620
|
+
color: '#ffffff'
|
|
2621
|
+
},
|
|
2613
2622
|
'::placeholder': {
|
|
2614
2623
|
color: 'rgba(201, 201, 201, 0.5)'
|
|
2615
2624
|
}
|
|
@@ -2625,7 +2634,7 @@ var CheckoutForm = function CheckoutForm(_ref) {
|
|
|
2625
2634
|
_ref$onSubmit = _ref.onSubmit,
|
|
2626
2635
|
onSubmit = _ref$onSubmit === void 0 ? _identity : _ref$onSubmit,
|
|
2627
2636
|
_ref$stripeCardOption = _ref.stripeCardOptions,
|
|
2628
|
-
stripeCardOptions = _ref$stripeCardOption === void 0 ?
|
|
2637
|
+
stripeCardOptions = _ref$stripeCardOption === void 0 ? {} : _ref$stripeCardOption,
|
|
2629
2638
|
_ref$error = _ref.error,
|
|
2630
2639
|
error = _ref$error === void 0 ? null : _ref$error,
|
|
2631
2640
|
stripe_client_secret = _ref.stripe_client_secret,
|
|
@@ -2812,7 +2821,7 @@ var CheckoutForm = function CheckoutForm(_ref) {
|
|
|
2812
2821
|
}, React__default.createElement("span", {
|
|
2813
2822
|
className: "card_label_text"
|
|
2814
2823
|
}, "Card number"), React__default.createElement(reactStripeJs.CardNumberElement, {
|
|
2815
|
-
options: stripeCardOptions,
|
|
2824
|
+
options: _extends({}, options, stripeCardOptions),
|
|
2816
2825
|
onReady: _identity,
|
|
2817
2826
|
onChange: _identity,
|
|
2818
2827
|
onBlur: _identity,
|
|
@@ -2822,13 +2831,13 @@ var CheckoutForm = function CheckoutForm(_ref) {
|
|
|
2822
2831
|
}, React__default.createElement("span", {
|
|
2823
2832
|
className: "card_label_text"
|
|
2824
2833
|
}, "Expiration date"), React__default.createElement(reactStripeJs.CardExpiryElement, {
|
|
2825
|
-
options: stripeCardOptions
|
|
2834
|
+
options: _extends({}, options, stripeCardOptions)
|
|
2826
2835
|
})), React__default.createElement("label", {
|
|
2827
2836
|
className: "cvc_element"
|
|
2828
2837
|
}, React__default.createElement("span", {
|
|
2829
2838
|
className: "card_label_text"
|
|
2830
2839
|
}, "CVC"), React__default.createElement(reactStripeJs.CardCvcElement, {
|
|
2831
|
-
options: stripeCardOptions
|
|
2840
|
+
options: _extends({}, options, stripeCardOptions)
|
|
2832
2841
|
})), React__default.createElement("label", {
|
|
2833
2842
|
className: "zip_element"
|
|
2834
2843
|
}, React__default.createElement("p", {
|
|
@@ -2894,7 +2903,9 @@ var PaymentContainer = function PaymentContainer(_ref) {
|
|
|
2894
2903
|
_ref$onGetPaymentData2 = _ref.onGetPaymentDataError,
|
|
2895
2904
|
onGetPaymentDataError = _ref$onGetPaymentData2 === void 0 ? function () {} : _ref$onGetPaymentData2,
|
|
2896
2905
|
_ref$onPaymentError = _ref.onPaymentError,
|
|
2897
|
-
onPaymentError = _ref$onPaymentError === void 0 ? function () {} : _ref$onPaymentError
|
|
2906
|
+
onPaymentError = _ref$onPaymentError === void 0 ? function () {} : _ref$onPaymentError,
|
|
2907
|
+
_ref$stripeCardOption = _ref.stripeCardOptions,
|
|
2908
|
+
stripeCardOptions = _ref$stripeCardOption === void 0 ? {} : _ref$stripeCardOption;
|
|
2898
2909
|
|
|
2899
2910
|
var _useState = React.useState(initialReviewValues),
|
|
2900
2911
|
reviewData = _useState[0],
|
|
@@ -3115,13 +3126,15 @@ var PaymentContainer = function PaymentContainer(_ref) {
|
|
|
3115
3126
|
handleSetLoading: function handleSetLoading(value) {
|
|
3116
3127
|
return setPaymentIsLoading(value);
|
|
3117
3128
|
},
|
|
3118
|
-
conditions: conditions
|
|
3129
|
+
conditions: conditions,
|
|
3130
|
+
stripeCardOptions: stripeCardOptions
|
|
3119
3131
|
}))))));
|
|
3120
3132
|
};
|
|
3121
3133
|
|
|
3122
3134
|
var defaultSvg = 'https://img.icons8.com/ios-filled/50/000000/facebook-new.svg';
|
|
3123
3135
|
var ConfirmationContainer = function ConfirmationContainer(_ref) {
|
|
3124
|
-
var
|
|
3136
|
+
var isReferralEnabled = _ref.isReferralEnabled,
|
|
3137
|
+
_ref$referralPromotio = _ref.referralPromotions,
|
|
3125
3138
|
referralPromotions = _ref$referralPromotio === void 0 ? [] : _ref$referralPromotio,
|
|
3126
3139
|
_ref$shareButtons = _ref.shareButtons,
|
|
3127
3140
|
shareButtons = _ref$shareButtons === void 0 ? [] : _ref$shareButtons,
|
|
@@ -3181,7 +3194,7 @@ var ConfirmationContainer = function ConfirmationContainer(_ref) {
|
|
|
3181
3194
|
}
|
|
3182
3195
|
}, _callee, null, [[4, 13]]);
|
|
3183
3196
|
}))();
|
|
3184
|
-
}, [
|
|
3197
|
+
}, []);
|
|
3185
3198
|
return React__default.createElement("div", {
|
|
3186
3199
|
className: "confirmation-page"
|
|
3187
3200
|
}, React__default.createElement("p", {
|
|
@@ -3192,7 +3205,7 @@ var ConfirmationContainer = function ConfirmationContainer(_ref) {
|
|
|
3192
3205
|
className: "main"
|
|
3193
3206
|
}, "Your tickets have been emailed to you"), React__default.createElement("span", {
|
|
3194
3207
|
className: "helper"
|
|
3195
|
-
}, "Please bring them with you to the event")), data.disable_referral === false && React__default.createElement(React__default.Fragment, null, React__default.createElement("div", {
|
|
3208
|
+
}, "Please bring them with you to the event")), data.disable_referral === false && isReferralEnabled && React__default.createElement(React__default.Fragment, null, React__default.createElement("div", {
|
|
3196
3209
|
className: "referral_text_image_section"
|
|
3197
3210
|
}, React__default.createElement("div", {
|
|
3198
3211
|
className: "referral_text_section"
|
|
@@ -3503,9 +3516,13 @@ var WaitingList = function WaitingList(_ref) {
|
|
|
3503
3516
|
|
|
3504
3517
|
return React__default.createElement("div", {
|
|
3505
3518
|
className: "waiting-list"
|
|
3506
|
-
},
|
|
3519
|
+
}, React__default.createElement("p", {
|
|
3520
|
+
className: "no-tickets-text"
|
|
3521
|
+
}, "No tickets are currently available for this event."), showSuccessMessage ? React__default.createElement("div", {
|
|
3507
3522
|
className: "success-message"
|
|
3508
|
-
}, React__default.createElement("
|
|
3523
|
+
}, React__default.createElement("p", {
|
|
3524
|
+
className: "added-success-message"
|
|
3525
|
+
}, "You've been added to the waiting list!"), React__default.createElement("p", null, "You'll be notified if tickets become available.")) : React__default.createElement(React__default.Fragment, null, React__default.createElement("h2", null, "WAITING LIST"), React__default.createElement(formik.Formik, {
|
|
3509
3526
|
initialValues: {
|
|
3510
3527
|
ticketTypeId: '',
|
|
3511
3528
|
quantity: '',
|