tf-checkout-react 1.0.99-beta.24 → 1.0.99-beta.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/api/auth.d.ts +4 -0
- package/dist/api/cart.d.ts +2 -0
- package/dist/api/checkout.d.ts +1 -0
- package/dist/api/common.d.ts +6 -0
- package/dist/api/index.d.ts +9 -40
- package/dist/api/interceptors.d.ts +1 -0
- package/dist/api/orders.d.ts +2 -0
- package/dist/api/payment.d.ts +5 -0
- package/dist/api/publicRequest.d.ts +8 -0
- package/dist/api/resale.d.ts +5 -0
- package/dist/components/billing-info-container/FieldsSection.d.ts +16 -0
- package/dist/components/billing-info-container/LogicRunner.d.ts +11 -0
- package/dist/components/billing-info-container/index.d.ts +2 -44
- package/dist/components/billing-info-container/types.d.ts +43 -0
- package/dist/components/billing-info-container/utils.d.ts +17 -37
- package/dist/components/common/CustomField.d.ts +6 -9
- package/dist/components/confirmModal/index.d.ts +1 -1
- package/dist/components/confirmationContainer/index.d.ts +6 -5
- package/dist/components/index.d.ts +1 -0
- package/dist/components/myTicketsContainer/index.d.ts +1 -1
- package/dist/components/myTicketsContainer/row.d.ts +1 -1
- package/dist/components/myTicketsContainer/tableConfig.d.ts +2 -1
- package/dist/components/orderDetailsContainer/index.d.ts +2 -2
- package/dist/components/orderDetailsContainer/ticketsTable.d.ts +4 -21
- package/dist/components/paymentContainer/index.d.ts +5 -6
- package/dist/components/rsvpContainer/index.d.ts +1 -1
- package/dist/components/stripePayment/index.d.ts +8 -10
- package/dist/components/ticketResaleModal/index.d.ts +5 -3
- package/dist/components/ticketsContainer/TicketsSection.d.ts +2 -1
- package/dist/components/ticketsContainer/index.d.ts +8 -19
- package/dist/components/timerWidget/index.d.ts +2 -2
- package/dist/env.d.ts +0 -10
- package/dist/tf-checkout-react.cjs.development.js +2372 -1853
- 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 +2362 -1843
- package/dist/tf-checkout-react.esm.js.map +1 -1
- package/dist/tf-checkout-styles.css +1 -1
- package/dist/types/index.d.ts +0 -2
- package/dist/types/referral-promotion.d.ts +1 -1
- package/dist/utils/createCheckoutDataBodyWithDefaultHolder.d.ts +1 -6
- package/dist/utils/localStorage.d.ts +8 -0
- package/dist/utils/setConfigs.d.ts +0 -3
- package/package.json +12 -1
- package/src/api/auth.ts +39 -0
- package/src/api/cart.ts +31 -0
- package/src/api/checkout.ts +16 -0
- package/src/api/common.ts +95 -0
- package/src/api/index.ts +31 -313
- package/src/api/interceptors.ts +82 -0
- package/src/api/orders.ts +31 -0
- package/src/api/payment.ts +80 -0
- package/src/api/publicRequest.ts +32 -0
- package/src/api/resale.ts +32 -0
- package/src/api/types.ts +39 -0
- package/src/components/billing-info-container/FieldsSection.tsx +161 -0
- package/src/components/billing-info-container/LogicRunner.tsx +97 -0
- package/src/components/billing-info-container/index.tsx +128 -349
- package/src/components/billing-info-container/style.css +21 -1
- package/src/components/billing-info-container/types.ts +48 -0
- package/src/components/billing-info-container/utils.ts +84 -89
- package/src/components/common/CheckboxField.tsx +12 -8
- package/src/components/common/CustomField.tsx +21 -24
- package/src/components/confirmModal/index.tsx +26 -26
- package/src/components/confirmationContainer/index.tsx +44 -40
- package/src/components/index.ts +1 -0
- package/src/components/loginModal/index.tsx +1 -1
- package/src/components/myTicketsContainer/index.tsx +32 -35
- package/src/components/myTicketsContainer/row.tsx +21 -22
- package/src/components/myTicketsContainer/tableConfig.tsx +14 -13
- package/src/components/orderDetailsContainer/index.tsx +79 -64
- package/src/components/orderDetailsContainer/ticketsTable.tsx +41 -57
- package/src/components/paymentContainer/index.tsx +120 -116
- package/src/components/registerModal/index.tsx +13 -20
- package/src/components/rsvpContainer/index.tsx +22 -14
- package/src/components/stripePayment/index.tsx +40 -38
- package/src/components/ticketResaleModal/index.tsx +114 -73
- package/src/components/ticketsContainer/PromoCodeSection.tsx +2 -2
- package/src/components/ticketsContainer/ReferralLogic.tsx +1 -11
- package/src/components/ticketsContainer/TicketsSection.tsx +7 -4
- package/src/components/ticketsContainer/index.tsx +146 -179
- package/src/components/timerWidget/index.tsx +4 -4
- package/src/components/waitingList/index.tsx +2 -7
- package/src/env.ts +3 -18
- package/src/types/api/auth.d.ts +55 -0
- package/src/types/api/axiosResponse.d.ts +6 -0
- package/src/types/api/cart.d.ts +56 -0
- package/src/types/api/checkout.d.ts +38 -0
- package/src/types/api/common.d.ts +112 -0
- package/src/types/api/orders.d.ts +100 -0
- package/src/types/api/payment.d.ts +156 -0
- package/src/types/api/ticketResale.d.ts +13 -0
- package/src/types/billing.d.ts +40 -0
- package/src/types/index.ts +0 -2
- package/src/types/referral-promotion.ts +4 -4
- package/src/utils/createCheckoutDataBodyWithDefaultHolder.ts +22 -40
- package/src/utils/downloadPDF.tsx +1 -8
- package/src/utils/localStorage.ts +34 -0
- package/src/utils/setConfigs.ts +9 -10
- package/src/validators/index.ts +10 -6
- package/dist/types/billing-info-data.d.ts +0 -27
- package/dist/types/order-data.d.ts +0 -9
- package/src/types/billing-info-data.ts +0 -37
- package/src/types/order-data.ts +0 -10
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
export declare const authorize: (data: IAuthorizeRequestData) => Promise<IProfileResponse>;
|
|
2
|
+
export declare const signUp: (data: ISignupRequestData) => Promise<IProfileResponse>;
|
|
3
|
+
export declare const getProfileData: () => Promise<IProfileResponse>;
|
|
4
|
+
export declare const logout: () => Promise<IAxiosResponseData>;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const postOnCheckout: (data: ICheckoutData) => Promise<ICheckoutResponse>;
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
export declare const getEvent: (id: string | number) => Promise<IEventResponse>;
|
|
2
|
+
export declare const getTickets: (eventId: string | number, promoCode: string) => Promise<ITicketsAdaptedResponse>;
|
|
3
|
+
export declare const getCountries: () => Promise<ICountriesResponse>;
|
|
4
|
+
export declare const getStates: (countryId: string | number) => Promise<IStatesResponse>;
|
|
5
|
+
export declare const sendRSVPInfo: (eventId: number, data: IRSVPRequestData) => Promise<IRSVPResponse>;
|
|
6
|
+
export declare const addToWaitingList: (id: number, data: IWaitingListRequestData) => Promise<IWaitingListResponse>;
|
package/dist/api/index.d.ts
CHANGED
|
@@ -1,40 +1,9 @@
|
|
|
1
|
-
import
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
}
|
|
7
|
-
export
|
|
8
|
-
export
|
|
9
|
-
export
|
|
10
|
-
export declare function getEvent(id: string | number): Promise<AxiosResponse<any, any>>;
|
|
11
|
-
export declare function getTickets(id: string | number, promoCode: string): Promise<AxiosResponse<any, any>>;
|
|
12
|
-
export declare const addToCart: (id: string | number, data: any) => Promise<AxiosResponse<any, any>>;
|
|
13
|
-
export declare const getCart: () => Promise<AxiosResponse<any, any>>;
|
|
14
|
-
export declare const postOnCheckout: (data: any, accessToken?: string | undefined) => Promise<AxiosResponse<any, any>>;
|
|
15
|
-
export declare const authorize: (data: {
|
|
16
|
-
email: string;
|
|
17
|
-
password: string;
|
|
18
|
-
}) => Promise<AxiosResponse<any, any>>;
|
|
19
|
-
export declare const register: (data: FormData) => Promise<AxiosResponse<any, any>>;
|
|
20
|
-
export declare const getAccessToken: (data: FormData) => Promise<AxiosResponse<any, any>>;
|
|
21
|
-
export declare const getPaymentData: (hash: string) => Promise<AxiosResponse<any, any>>;
|
|
22
|
-
export declare const handlePaymentData: (orderHash: string, data: any) => Promise<AxiosResponse<any, any>>;
|
|
23
|
-
export declare const handlePaymentSuccess: (orderHash: string) => Promise<AxiosResponse<any, any>>;
|
|
24
|
-
export declare const handleFreeSuccess: (orderHash: string) => Promise<AxiosResponse<any, any>>;
|
|
25
|
-
export declare const getProfileData: (accessToken?: string | undefined) => Promise<any>;
|
|
26
|
-
export declare const getCountries: () => Promise<AxiosResponse<any, any>>;
|
|
27
|
-
export declare const getConfirmationData: (orderHash: string) => Promise<AxiosResponse<any, any>>;
|
|
28
|
-
export declare const getStates: (countryId: string) => Promise<AxiosResponse<any, any>>;
|
|
29
|
-
export declare const getOrders: (page: number, limit: number, eventSlug: string) => Promise<AxiosResponse<any, any>>;
|
|
30
|
-
export declare const getOrderDetails: (orderId: string) => Promise<AxiosResponse<any, any>>;
|
|
31
|
-
export declare const addToWaitingList: (id: number, data: any) => Promise<AxiosResponse<any, any>>;
|
|
32
|
-
export declare const getConditions: (eventId: string) => Promise<AxiosResponse<any, any>>;
|
|
33
|
-
export declare const resaleTicket: (data: any, hash: string) => Promise<AxiosResponse<any, any>>;
|
|
34
|
-
export declare const removeFromResale: (hash: string) => Promise<AxiosResponse<any, any>>;
|
|
35
|
-
export declare const postReferralVisits: (eventId: string, referralId: string) => Promise<AxiosResponse<any, any>>;
|
|
36
|
-
export declare const logout: () => Promise<AxiosResponse<any, any>>;
|
|
37
|
-
export declare const processTicket: (hash: string) => Promise<AxiosResponse<any, any>>;
|
|
38
|
-
export declare const declineInvitation: (hash: string) => Promise<AxiosResponse<any, any>>;
|
|
39
|
-
export declare const sendRSVPInfo: (eventId: number, data: any) => Promise<AxiosResponse<any, any>>;
|
|
40
|
-
export {};
|
|
1
|
+
import './interceptors';
|
|
2
|
+
export { authorize, getProfileData, signUp, logout } from './auth';
|
|
3
|
+
export { setAxiosHeader, setBaseUrl } from './publicRequest';
|
|
4
|
+
export { getOrders, getOrderDetails } from './orders';
|
|
5
|
+
export { addToCart, getCart } from './cart';
|
|
6
|
+
export { postOnCheckout } from './checkout';
|
|
7
|
+
export { getEvent, getTickets, getCountries, getStates, addToWaitingList, sendRSVPInfo, } from './common';
|
|
8
|
+
export { getPaymentData, getConditions, handlePaymentSuccess, handleFreeSuccess, getConfirmationData, } from './payment';
|
|
9
|
+
export { resaleTicket, removeFromResale, processTicket, declineInvitation, } from './resale';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
export declare const getPaymentData: (hash: string) => Promise<IPaymentDataResponse>;
|
|
2
|
+
export declare const handlePaymentSuccess: (orderHash: string) => Promise<IPaymentSuccessDataResponse>;
|
|
3
|
+
export declare const handleFreeSuccess: (orderHash: string) => Promise<IFreeRegistrationDataResponse>;
|
|
4
|
+
export declare const getConfirmationData: (orderHash: string) => Promise<ICheckoutCompleteDataResponse>;
|
|
5
|
+
export declare const getConditions: (eventId: string) => Promise<IConditionsAdaptedDataResponse>;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { AxiosInstance } from 'axios';
|
|
2
|
+
export declare const setAxiosHeader: (key: string, value: string | number) => void;
|
|
3
|
+
interface IPublicRequest extends AxiosInstance {
|
|
4
|
+
setBaseUrl: (baseUrl: string) => void;
|
|
5
|
+
}
|
|
6
|
+
export declare const publicRequest: IPublicRequest;
|
|
7
|
+
export declare const setBaseUrl: (baseUrl: string) => void;
|
|
8
|
+
export {};
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import { AxiosResponse } from 'axios';
|
|
2
|
+
export declare const resaleTicket: (data: IResaleTicketRequestData, hash: string) => Promise<IResaleTicketResponse>;
|
|
3
|
+
export declare const removeFromResale: (hash: string) => Promise<IRemoveFromResaleResponse>;
|
|
4
|
+
export declare const processTicket: (hash: string) => Promise<AxiosResponse<any, any>>;
|
|
5
|
+
export declare const declineInvitation: (hash: string) => Promise<AxiosResponse<any, any>>;
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
export interface IFieldsSectionProps {
|
|
3
|
+
data?: IBillingInfoData[];
|
|
4
|
+
isLoggedIn?: boolean;
|
|
5
|
+
countries?: ICountriesAdaptedData[];
|
|
6
|
+
states?: IStatesData[];
|
|
7
|
+
showTicketHolderName?: boolean;
|
|
8
|
+
showDOB?: boolean;
|
|
9
|
+
flagRequirePhone: boolean;
|
|
10
|
+
hideTtfOptIn: boolean;
|
|
11
|
+
values: any;
|
|
12
|
+
setFieldValue: (field: string, value: any, shouldValidate?: boolean | undefined) => void;
|
|
13
|
+
handleBlur: any;
|
|
14
|
+
theme: 'dark' | 'light';
|
|
15
|
+
}
|
|
16
|
+
export declare const FieldsSection: ({ data, isLoggedIn, countries, states, showTicketHolderName, showDOB, flagRequirePhone, hideTtfOptIn, values, setFieldValue, handleBlur, theme, }: IFieldsSectionProps) => JSX.Element;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import React, { FC } from 'react';
|
|
2
|
+
export declare const LogicRunner: FC<{
|
|
3
|
+
values: any;
|
|
4
|
+
setStates: React.Dispatch<any>;
|
|
5
|
+
setFieldValue: any;
|
|
6
|
+
setValues: any;
|
|
7
|
+
setUserValues: any;
|
|
8
|
+
onGetStatesSuccess: any;
|
|
9
|
+
onGetStatesError: any;
|
|
10
|
+
shouldFetchCountries: boolean;
|
|
11
|
+
}>;
|
|
@@ -1,46 +1,4 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
import { AxiosError } from 'axios';
|
|
3
|
-
import { FormikHelpers, FormikValues } from 'formik';
|
|
4
2
|
import './style.css';
|
|
5
|
-
import {
|
|
6
|
-
|
|
7
|
-
import { CSSProperties } from '@mui/styles';
|
|
8
|
-
export interface IBillingInfoPage {
|
|
9
|
-
data?: IBillingInfoData[];
|
|
10
|
-
ticketHoldersFields?: IBillingInfoData;
|
|
11
|
-
handleSubmit?: (values: FormikValues, formikHelpers: FormikHelpers<FormikValues>, eventId: any, res: any) => void;
|
|
12
|
-
onRegisterSuccess?: (value: any) => void;
|
|
13
|
-
onRegisterError?: (e: AxiosError, email: string) => void;
|
|
14
|
-
onSubmitError?: (e: AxiosError) => void;
|
|
15
|
-
onGetCartSuccess?: (res: any) => void;
|
|
16
|
-
onGetCartError?: (e: AxiosError) => void;
|
|
17
|
-
onGetCountriesSuccess?: (res: any) => void;
|
|
18
|
-
onGetCountriesError?: (e: AxiosError) => void;
|
|
19
|
-
onGetStatesSuccess?: (res: any) => void;
|
|
20
|
-
onGetStatesError?: (e: AxiosError) => void;
|
|
21
|
-
onGetProfileDataSuccess?: (res: any) => void;
|
|
22
|
-
onGetProfileDataError?: (e: AxiosError) => void;
|
|
23
|
-
onAuthorizeSuccess?: () => void;
|
|
24
|
-
onAuthorizeError?: (e: AxiosError) => void;
|
|
25
|
-
onLogin?: () => void;
|
|
26
|
-
onLoginSuccess?: () => void;
|
|
27
|
-
onErrorClose?: () => void;
|
|
28
|
-
initialValues?: FormikValues;
|
|
29
|
-
buttonName?: string;
|
|
30
|
-
theme?: 'light' | 'dark';
|
|
31
|
-
isLoggedIn?: boolean;
|
|
32
|
-
accountInfoTitle?: string | JSX.Element;
|
|
33
|
-
hideLogo?: boolean;
|
|
34
|
-
themeOptions?: ThemeOptions & {
|
|
35
|
-
input?: CSSProperties;
|
|
36
|
-
checkbox?: CSSProperties;
|
|
37
|
-
};
|
|
38
|
-
hideErrorsAlertSection?: boolean;
|
|
39
|
-
onSkipBillingPage: (data: any) => void;
|
|
40
|
-
skipPage?: boolean;
|
|
41
|
-
canSkipHolderNames?: boolean;
|
|
42
|
-
shouldFetchCountries?: boolean;
|
|
43
|
-
onCountdownFinish?: () => void;
|
|
44
|
-
enableTimer?: boolean;
|
|
45
|
-
}
|
|
46
|
-
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, accountInfoTitle, hideLogo, themeOptions, onErrorClose, hideErrorsAlertSection, onSkipBillingPage, skipPage, canSkipHolderNames, shouldFetchCountries, onCountdownFinish, enableTimer }: IBillingInfoPage) => JSX.Element;
|
|
3
|
+
import { IBillingInfoPage } from './types';
|
|
4
|
+
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, accountInfoTitle, hideLogo, themeOptions, onErrorClose, hideErrorsAlertSection, onSkipBillingPage, skipPage, canSkipHolderNames, shouldFetchCountries, onCountdownFinish, enableTimer, }: IBillingInfoPage) => JSX.Element;
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { ThemeOptions } from '@mui/material';
|
|
3
|
+
import { CSSProperties } from '@mui/styles';
|
|
4
|
+
import { AxiosError } from 'axios';
|
|
5
|
+
import { FormikHelpers, FormikValues } from 'formik';
|
|
6
|
+
export interface IBillingInfoPage {
|
|
7
|
+
data?: IBillingInfoData[];
|
|
8
|
+
ticketHoldersFields?: ITicketHoldersData;
|
|
9
|
+
handleSubmit?: (values: FormikValues, formikHelpers: FormikHelpers<FormikValues>, eventId: any, res: any) => void;
|
|
10
|
+
onRegisterSuccess?: (value: any) => void;
|
|
11
|
+
onRegisterError?: (e: AxiosError, email: string) => void;
|
|
12
|
+
onSubmitError?: (e: AxiosError) => void;
|
|
13
|
+
onGetCartSuccess?: (res: any) => void;
|
|
14
|
+
onGetCartError?: (e: AxiosError) => void;
|
|
15
|
+
onGetCountriesSuccess?: (res: any) => void;
|
|
16
|
+
onGetCountriesError?: (e: AxiosError) => void;
|
|
17
|
+
onGetStatesSuccess?: (res: any) => void;
|
|
18
|
+
onGetStatesError?: (e: AxiosError) => void;
|
|
19
|
+
onGetProfileDataSuccess?: (res: any) => void;
|
|
20
|
+
onGetProfileDataError?: (e: AxiosError) => void;
|
|
21
|
+
onAuthorizeSuccess?: () => void;
|
|
22
|
+
onAuthorizeError?: (e: AxiosError) => void;
|
|
23
|
+
onLogin?: () => void;
|
|
24
|
+
onLoginSuccess?: () => void;
|
|
25
|
+
onErrorClose?: () => void;
|
|
26
|
+
initialValues?: FormikValues;
|
|
27
|
+
buttonName?: string;
|
|
28
|
+
theme?: 'light' | 'dark';
|
|
29
|
+
isLoggedIn?: boolean;
|
|
30
|
+
accountInfoTitle?: string | JSX.Element;
|
|
31
|
+
hideLogo?: boolean;
|
|
32
|
+
themeOptions?: ThemeOptions & {
|
|
33
|
+
input?: CSSProperties;
|
|
34
|
+
checkbox?: CSSProperties;
|
|
35
|
+
};
|
|
36
|
+
hideErrorsAlertSection?: boolean;
|
|
37
|
+
onSkipBillingPage: (data: any) => void;
|
|
38
|
+
skipPage?: boolean;
|
|
39
|
+
canSkipHolderNames?: boolean;
|
|
40
|
+
shouldFetchCountries?: boolean;
|
|
41
|
+
onCountdownFinish?: () => void;
|
|
42
|
+
enableTimer?: boolean;
|
|
43
|
+
}
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import { IGroupItem } from '../../types';
|
|
2
1
|
import { FormikValues } from 'formik';
|
|
3
2
|
export interface ILoggedInValues {
|
|
4
3
|
emailLogged?: string;
|
|
@@ -9,47 +8,28 @@ export interface IValues {
|
|
|
9
8
|
[key: string]: any;
|
|
10
9
|
}
|
|
11
10
|
export declare const getInitialValues: (data?: any, propsInitialValues?: IValues, userValues?: any) => IValues;
|
|
12
|
-
export declare const createRegisterFormData: (
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
};
|
|
16
|
-
}) => FormData;
|
|
17
|
-
interface ICheckoutBody {
|
|
18
|
-
attributes: {
|
|
19
|
-
[key: string]: any;
|
|
20
|
-
};
|
|
21
|
-
}
|
|
22
|
-
interface IUserData {
|
|
23
|
-
id: string;
|
|
11
|
+
export declare const createRegisterFormData: (data?: IValues) => ISignupRequestData;
|
|
12
|
+
export declare const setLoggedUserData: (data: IProfileData) => {
|
|
13
|
+
id: string | number;
|
|
24
14
|
firstName: string;
|
|
25
15
|
lastName: string;
|
|
26
16
|
email: string;
|
|
27
|
-
city?: string;
|
|
28
|
-
country?: string;
|
|
29
|
-
countryId?: string;
|
|
30
|
-
phone?: string;
|
|
31
|
-
streetAddress?: string;
|
|
32
|
-
state?: string;
|
|
33
|
-
zip?: string;
|
|
34
|
-
zipCode?: string;
|
|
35
|
-
stateId?: string;
|
|
36
|
-
}
|
|
37
|
-
export declare const setLoggedUserData: (data: IUserData) => {
|
|
38
|
-
id: string;
|
|
39
|
-
first_name: string;
|
|
40
|
-
last_name: string;
|
|
41
|
-
email: string;
|
|
42
17
|
confirmEmail: string;
|
|
43
18
|
city: string;
|
|
44
|
-
country: string;
|
|
19
|
+
country: string | number;
|
|
45
20
|
phone: string;
|
|
46
|
-
|
|
47
|
-
state: string;
|
|
48
|
-
zip: string;
|
|
21
|
+
streetAddress: string;
|
|
22
|
+
state: string | number;
|
|
23
|
+
zip: string | number;
|
|
49
24
|
};
|
|
50
|
-
export declare const createCheckoutDataBody: (ticketsQuantity: number, values?: IValues, logedInValues?: ILoggedInValues, includeDob?: boolean) =>
|
|
51
|
-
export declare const getValidateFunctions: (element
|
|
52
|
-
|
|
53
|
-
|
|
25
|
+
export declare const createCheckoutDataBody: (ticketsQuantity: number, values?: IValues, logedInValues?: ILoggedInValues, includeDob?: boolean) => ICheckoutData;
|
|
26
|
+
export declare const getValidateFunctions: ({ element, states, values, flagRequirePhone, }: {
|
|
27
|
+
element: IBillingFieldData;
|
|
28
|
+
states: IStatesData[];
|
|
29
|
+
values: FormikValues;
|
|
30
|
+
flagRequirePhone: boolean;
|
|
31
|
+
}) => (...value: any) => any;
|
|
54
32
|
export declare const assingUniqueIds: (data: any) => any;
|
|
55
|
-
export {
|
|
33
|
+
export declare const getTicketHoldersData: (ticketHoldersValues: {
|
|
34
|
+
[key: string]: string;
|
|
35
|
+
}, loggedUserData: IProfileData, quantity: number) => ITicketHolderData[];
|
|
@@ -1,20 +1,17 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
import {
|
|
2
|
+
import { TextFieldProps } from '@mui/material/TextField';
|
|
3
|
+
import { FieldInputProps, FormikProps, FormikValues } from 'formik';
|
|
3
4
|
export interface ISelectOption {
|
|
4
5
|
label: string | number;
|
|
5
6
|
value?: string | number;
|
|
6
|
-
|
|
7
|
+
disabled?: boolean;
|
|
7
8
|
}
|
|
8
9
|
export interface ICustomField {
|
|
9
10
|
label: string;
|
|
10
|
-
field: FieldInputProps<
|
|
11
|
-
form: FormikProps<
|
|
11
|
+
field: FieldInputProps<string | number | null | undefined>;
|
|
12
|
+
form: FormikProps<FormikValues>;
|
|
12
13
|
theme: 'dark' | 'light';
|
|
13
14
|
type?: string;
|
|
14
15
|
selectOptions?: ISelectOption[];
|
|
15
16
|
}
|
|
16
|
-
|
|
17
|
-
[key: string]: any;
|
|
18
|
-
}
|
|
19
|
-
export declare const CustomField: ({ label, type, field, selectOptions, form: { touched, errors, submitCount }, theme, inputProps: pInputProps, InputProps, inputRef, }: ICustomField & IOtherProps) => JSX.Element;
|
|
20
|
-
export {};
|
|
17
|
+
export declare const CustomField: ({ label, type, field, selectOptions, form: { touched, errors, submitCount }, theme, inputProps: pInputProps, InputProps, inputRef, }: ICustomField & TextFieldProps) => JSX.Element;
|
|
@@ -7,14 +7,15 @@ export interface IShareButton {
|
|
|
7
7
|
platform: string;
|
|
8
8
|
shareData: any;
|
|
9
9
|
}
|
|
10
|
-
|
|
10
|
+
interface IConfirmationPage {
|
|
11
11
|
isReferralEnabled: boolean;
|
|
12
12
|
showDefaultShareButtons: boolean;
|
|
13
13
|
messengerAppId: string;
|
|
14
|
+
orderHash?: string;
|
|
14
15
|
shareButtons: IShareButton[];
|
|
15
|
-
onGetConfirmationDataSuccess: (
|
|
16
|
-
onGetConfirmationDataError: (
|
|
16
|
+
onGetConfirmationDataSuccess: (response: any) => void;
|
|
17
|
+
onGetConfirmationDataError: (error: AxiosError) => void;
|
|
17
18
|
onLinkCopied: () => void;
|
|
18
|
-
orderHash?: string;
|
|
19
19
|
}
|
|
20
|
-
export declare const ConfirmationContainer: ({ isReferralEnabled, showDefaultShareButtons, messengerAppId, shareButtons, onGetConfirmationDataSuccess, onGetConfirmationDataError,
|
|
20
|
+
export declare const ConfirmationContainer: ({ isReferralEnabled, showDefaultShareButtons, messengerAppId, orderHash, shareButtons, onGetConfirmationDataSuccess, onGetConfirmationDataError, onLinkCopied, }: IConfirmationPage) => JSX.Element;
|
|
21
|
+
export {};
|
|
@@ -5,3 +5,4 @@ export { TicketsContainer } from './ticketsContainer';
|
|
|
5
5
|
export { MyTicketsContainer } from './myTicketsContainer';
|
|
6
6
|
export { OrderDetailsContainer } from './orderDetailsContainer';
|
|
7
7
|
export { TicketResaleContainer } from './ticketResale';
|
|
8
|
+
export { RsvpContainer } from './rsvpContainer';
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import './style.css';
|
|
3
3
|
interface OrderDetailsTypes {
|
|
4
|
-
onGetOrdersSuccess: (res:
|
|
5
|
-
onGetOrdersError: (err:
|
|
4
|
+
onGetOrdersSuccess: (res: IOrderResponse) => void;
|
|
5
|
+
onGetOrdersError: (err: unknown) => void;
|
|
6
6
|
}
|
|
7
7
|
export declare const OrderDetailsContainer: ({ onGetOrdersSuccess, onGetOrdersError, }: OrderDetailsTypes) => JSX.Element;
|
|
8
8
|
export {};
|
|
@@ -1,25 +1,8 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
interface IAddOnTypes {
|
|
3
|
-
name: string;
|
|
4
|
-
status: string;
|
|
5
|
-
}
|
|
6
|
-
export interface ITicketTypes {
|
|
7
|
-
add_ons?: IAddOnTypes[];
|
|
8
|
-
hash: string;
|
|
9
|
-
ticket_type: string;
|
|
10
|
-
holder_name: string;
|
|
11
|
-
status: string;
|
|
12
|
-
pdf_link: string;
|
|
13
|
-
is_sellable: boolean;
|
|
14
|
-
is_on_sale?: boolean;
|
|
15
|
-
event_name: string;
|
|
16
|
-
currency: string;
|
|
17
|
-
resale_fee_amount: number | string;
|
|
18
|
-
}
|
|
19
2
|
interface TicketsTableTypes {
|
|
20
|
-
tickets:
|
|
21
|
-
handleSellTicket: (ticket:
|
|
22
|
-
handleRemoveFromResale: (ticket:
|
|
3
|
+
tickets: IOrderTicketData[];
|
|
4
|
+
handleSellTicket: (ticket: IOrderTicketData) => void;
|
|
5
|
+
handleRemoveFromResale: (ticket: IOrderTicketData) => void;
|
|
23
6
|
}
|
|
24
|
-
declare const TicketsTable: ({ tickets, handleSellTicket, handleRemoveFromResale }: TicketsTableTypes) => JSX.Element;
|
|
7
|
+
declare const TicketsTable: ({ tickets, handleSellTicket, handleRemoveFromResale, }: TicketsTableTypes) => JSX.Element;
|
|
25
8
|
export default TicketsTable;
|
|
@@ -1,19 +1,18 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
import { AxiosError } from 'axios';
|
|
3
|
-
import { StripeElementsOptions } from '@stripe/stripe-js';
|
|
4
2
|
import './style.css';
|
|
5
|
-
import { IPaymentField } from '../../types';
|
|
6
|
-
import { StripeCardNumberElementOptions } from '@stripe/stripe-js';
|
|
7
3
|
import { ThemeOptions } from '@mui/material';
|
|
8
4
|
import { CSSProperties } from '@mui/styles';
|
|
5
|
+
import { StripeCardNumberElementOptions, StripeElementsOptions } from '@stripe/stripe-js';
|
|
6
|
+
import { AxiosError } from 'axios';
|
|
7
|
+
import { IPaymentField } from '../../types';
|
|
9
8
|
export interface IPaymentPage {
|
|
10
9
|
paymentFields: IPaymentField[];
|
|
11
|
-
handlePayment:
|
|
10
|
+
handlePayment: (value: IFreeRegistrationDataResponse | IPaymentSuccessDataResponse) => void;
|
|
12
11
|
checkoutData: any;
|
|
13
12
|
formTitle?: string;
|
|
14
13
|
errorText?: string;
|
|
15
14
|
onErrorClose?: () => void;
|
|
16
|
-
onGetPaymentDataSuccess: (value:
|
|
15
|
+
onGetPaymentDataSuccess: (value: IPaymentData) => void;
|
|
17
16
|
onGetPaymentDataError: (value: AxiosError) => void;
|
|
18
17
|
onPaymentError: (value: AxiosError) => void;
|
|
19
18
|
stripeCardOptions?: StripeCardNumberElementOptions;
|
|
@@ -3,5 +3,5 @@ interface IRsvpContainerPage {
|
|
|
3
3
|
showSection?: boolean;
|
|
4
4
|
eventId: number;
|
|
5
5
|
}
|
|
6
|
-
export declare const RsvpContainer: ({ showSection, eventId }: IRsvpContainerPage) => JSX.Element | null;
|
|
6
|
+
export declare const RsvpContainer: ({ showSection, eventId, }: IRsvpContainerPage) => JSX.Element | null;
|
|
7
7
|
export {};
|
|
@@ -1,20 +1,18 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
import { StripeCardNumberElementOptions } from '@stripe/stripe-js';
|
|
3
2
|
import './style.css';
|
|
3
|
+
import { StripeCardNumberElementOptions } from '@stripe/stripe-js';
|
|
4
4
|
export interface ICheckoutForm {
|
|
5
|
-
total: string;
|
|
5
|
+
total: string | number;
|
|
6
6
|
currency: string;
|
|
7
7
|
onSubmit: (error: any) => Promise<any>;
|
|
8
8
|
error?: string | null;
|
|
9
9
|
stripeCardOptions?: StripeCardNumberElementOptions;
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
handleSetLoading: (loading: any) => void;
|
|
16
|
-
conditions: any;
|
|
10
|
+
stripeClientSecret: string;
|
|
11
|
+
billingInfo: IShippingBillingInfoData;
|
|
12
|
+
isLoading: boolean;
|
|
13
|
+
handleSetLoading: (loading: boolean) => void;
|
|
14
|
+
conditions: IConditionsAdaptedData[];
|
|
17
15
|
disableZipSection: boolean;
|
|
18
16
|
}
|
|
19
|
-
declare const CheckoutForm: ({ total, onSubmit, stripeCardOptions, error,
|
|
17
|
+
declare const CheckoutForm: ({ total, onSubmit, stripeCardOptions, error, stripeClientSecret, currency, billingInfo, isLoading, handleSetLoading, conditions, disableZipSection, }: ICheckoutForm) => JSX.Element;
|
|
20
18
|
export default CheckoutForm;
|
|
@@ -1,13 +1,15 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
import { ITicketTypes } from '../orderDetailsContainer/ticketsTable';
|
|
3
2
|
import './style.css';
|
|
3
|
+
export interface IExtendedOrderTicketData extends IOrderTicketData {
|
|
4
|
+
ticketTypeIsActive?: boolean;
|
|
5
|
+
}
|
|
4
6
|
interface Props {
|
|
5
|
-
ticket:
|
|
7
|
+
ticket: IExtendedOrderTicketData;
|
|
6
8
|
onClose: () => void;
|
|
7
9
|
onSubmit: (values: InitialValuesTypes) => void;
|
|
8
10
|
}
|
|
9
11
|
export interface InitialValuesTypes {
|
|
10
|
-
to:
|
|
12
|
+
to: 'friend' | 'anyone';
|
|
11
13
|
first_name: string;
|
|
12
14
|
last_name: string;
|
|
13
15
|
email: string;
|
|
@@ -6,6 +6,7 @@ interface ITicketsSectionProps {
|
|
|
6
6
|
handleTicketSelect: any;
|
|
7
7
|
sortBySoldOut: boolean;
|
|
8
8
|
ticketsHeaderComponent?: ReactNode;
|
|
9
|
+
hideTicketsHeader: boolean;
|
|
9
10
|
}
|
|
10
|
-
export declare const TicketsSection: ({ ticketsList, selectedTickets, handleTicketSelect, sortBySoldOut, ticketsHeaderComponent }: ITicketsSectionProps) => JSX.Element;
|
|
11
|
+
export declare const TicketsSection: ({ ticketsList, selectedTickets, handleTicketSelect, sortBySoldOut, ticketsHeaderComponent, hideTicketsHeader }: ITicketsSectionProps) => JSX.Element;
|
|
11
12
|
export {};
|
|
@@ -3,25 +3,16 @@ import { AxiosError } from 'axios';
|
|
|
3
3
|
import './style.css';
|
|
4
4
|
import { ThemeOptions } from '@mui/material';
|
|
5
5
|
import { CSSProperties } from '@mui/styles';
|
|
6
|
-
interface CartSuccess {
|
|
7
|
-
skip_billing_page: boolean;
|
|
8
|
-
names_required: boolean;
|
|
9
|
-
age_required: boolean;
|
|
10
|
-
phone_required: boolean;
|
|
11
|
-
event_id: string;
|
|
12
|
-
hash?: string;
|
|
13
|
-
total?: string;
|
|
14
|
-
}
|
|
15
6
|
export interface IGetTickets {
|
|
16
7
|
eventId: number;
|
|
17
|
-
onAddToCartSuccess: (response:
|
|
8
|
+
onAddToCartSuccess: (response: ICartResponseExtendedData) => void;
|
|
18
9
|
getTicketsLabel?: string;
|
|
19
10
|
contentStyle?: React.CSSProperties;
|
|
20
|
-
onAddToCartError: (
|
|
11
|
+
onAddToCartError: (error: AxiosError) => void;
|
|
21
12
|
onGetTicketsSuccess: (response: any) => void;
|
|
22
|
-
onGetTicketsError: (
|
|
13
|
+
onGetTicketsError: (error: AxiosError) => void;
|
|
23
14
|
onLogoutSuccess: () => void;
|
|
24
|
-
onLogoutError: (
|
|
15
|
+
onLogoutError: (error: AxiosError) => void;
|
|
25
16
|
onLoginSuccess: () => void;
|
|
26
17
|
theme?: 'light' | 'dark';
|
|
27
18
|
queryPromoCode?: string;
|
|
@@ -40,13 +31,11 @@ export interface IGetTickets {
|
|
|
40
31
|
isLoggedIn?: boolean;
|
|
41
32
|
actionsSectionComponent?: any;
|
|
42
33
|
ticketsHeaderComponent?: ReactNode;
|
|
34
|
+
hideTicketsHeader?: boolean;
|
|
43
35
|
}
|
|
44
36
|
export interface ITicket {
|
|
45
|
-
id: string
|
|
46
|
-
|
|
47
|
-
}
|
|
48
|
-
export interface ISelectedTickets {
|
|
37
|
+
id: string;
|
|
38
|
+
price: number;
|
|
49
39
|
[key: string]: string | number;
|
|
50
40
|
}
|
|
51
|
-
export declare const TicketsContainer: ({ onLoginSuccess, getTicketsLabel, eventId, onAddToCartSuccess, contentStyle, onAddToCartError, onGetTicketsSuccess, onGetTicketsError, onLogoutSuccess, onLogoutError, theme, queryPromoCode, isPromotionsEnabled, themeOptions, isAccessCodeEnabled, hideSessionButtons, hideWaitingList, enableBillingInfoAutoCreate, isButtonScrollable, sortBySoldOut, disableCountdownLeadingZero, isLoggedIn, actionsSectionComponent: ActionsSectionComponent, ticketsHeaderComponent }: IGetTickets) => JSX.Element;
|
|
52
|
-
export {};
|
|
41
|
+
export declare const TicketsContainer: ({ onLoginSuccess, getTicketsLabel, eventId, onAddToCartSuccess, contentStyle, onAddToCartError, onGetTicketsSuccess, onGetTicketsError, onLogoutSuccess, onLogoutError, theme, queryPromoCode, isPromotionsEnabled, themeOptions, isAccessCodeEnabled, hideSessionButtons, hideWaitingList, enableBillingInfoAutoCreate, isButtonScrollable, sortBySoldOut, disableCountdownLeadingZero, isLoggedIn, actionsSectionComponent: ActionsSectionComponent, ticketsHeaderComponent, hideTicketsHeader, }: IGetTickets) => JSX.Element;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import './style.css';
|
|
3
3
|
export interface ITimerWidgetPage {
|
|
4
|
-
|
|
4
|
+
expiresAt: number;
|
|
5
5
|
buyLoading?: boolean;
|
|
6
6
|
onCountdownFinish?: () => void;
|
|
7
7
|
}
|
|
@@ -11,5 +11,5 @@ export interface IRenderer {
|
|
|
11
11
|
completed: number;
|
|
12
12
|
handleCountdownFinish: () => void;
|
|
13
13
|
}
|
|
14
|
-
declare const _default: React.MemoExoticComponent<({
|
|
14
|
+
declare const _default: React.MemoExoticComponent<({ expiresAt, buyLoading, onCountdownFinish, }: ITimerWidgetPage) => JSX.Element | null>;
|
|
15
15
|
export default _default;
|
package/dist/env.d.ts
CHANGED
|
@@ -1,15 +1,5 @@
|
|
|
1
1
|
export declare const ENV: {
|
|
2
2
|
EVENT_ID: number;
|
|
3
3
|
BASE_URL: string;
|
|
4
|
-
CLIENT_ID: string;
|
|
5
|
-
CLIENT_SECRET: string;
|
|
6
|
-
STRIPE_PUBLISHABLE_KEY: string;
|
|
7
4
|
BRAND_SLUG: string;
|
|
8
5
|
};
|
|
9
|
-
export declare const ENV_PROD: {
|
|
10
|
-
EVENT_ID: number;
|
|
11
|
-
BASE_URL: string;
|
|
12
|
-
CLIENT_ID: string;
|
|
13
|
-
CLIENT_SECRET: string;
|
|
14
|
-
STRIPE_PUBLISHABLE_KEY: string;
|
|
15
|
-
};
|