tf-checkout-react 1.3.46 → 1.3.47-beta.2
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/.DS_Store +0 -0
- package/dist/api/index.d.ts +10 -0
- package/dist/components/addonsContainer/utils/index.d.ts +1 -4
- package/dist/components/billing-info-container/utils.d.ts +20 -1
- package/dist/components/myTicketsContainer/tableConfig.d.ts +1 -4
- package/dist/components/ticketsContainer/TicketRow.d.ts +6 -1
- package/dist/components/ticketsContainer/TicketsSection.d.ts +6 -1
- package/dist/components/ticketsContainer/crypto.d.ts +24 -0
- package/dist/tf-checkout-react.cjs.development.js +4701 -1324
- 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 +4702 -1324
- package/dist/tf-checkout-react.esm.js.map +1 -1
- package/dist/tf-checkout-styles.css +1 -1
- package/dist/types/billing-info-data.d.ts +5 -0
- package/dist/utils/getWalletName.d.ts +1 -0
- package/dist/utils/loadProfile.d.ts +32 -0
- package/package.json +3 -1
- package/src/.DS_Store +0 -0
- package/src/api/index.ts +42 -1
- package/src/assets/.DS_Store +0 -0
- package/src/components/addonsContainer/utils/index.tsx +1 -1
- package/src/components/billing-info-container/index.tsx +271 -11
- package/src/components/billing-info-container/style.css +1 -1
- package/src/components/billing-info-container/utils.ts +98 -5
- package/src/components/loginModal/index.tsx +70 -5
- package/src/components/loginModal/style.css +2 -2
- package/src/components/ticketsContainer/TicketRow.tsx +55 -5
- package/src/components/ticketsContainer/TicketsSection.tsx +15 -1
- package/src/components/ticketsContainer/crypto.js +528 -0
- package/src/components/ticketsContainer/index.tsx +216 -2
- package/src/components/waitingList/index.tsx +1 -1
- package/src/env.ts +2 -2
- package/src/types/billing-info-data.ts +6 -0
- package/src/utils/getWalletName.tsx +10 -0
- package/src/utils/loadProfile.tsx +47 -0
- package/src/components/common/dist/PhoneNumberField.js +0 -96
package/dist/.DS_Store
ADDED
|
Binary file
|
package/dist/api/index.d.ts
CHANGED
|
@@ -10,6 +10,7 @@ export declare const authorize: (data: {
|
|
|
10
10
|
email: string;
|
|
11
11
|
password: string;
|
|
12
12
|
}) => Promise<AxiosResponse<any, any>>;
|
|
13
|
+
export declare const authorizeWithWallet: (address: string, signature: string, blockchain: string) => Promise<AxiosResponse<any, any>>;
|
|
13
14
|
export declare const register: (data: FormData) => Promise<AxiosResponse<any, any>>;
|
|
14
15
|
export declare const getAccessToken: (data: FormData) => Promise<AxiosResponse<any, any>>;
|
|
15
16
|
export declare const getPaymentData: (hash: string) => Promise<AxiosResponse<any, any>>;
|
|
@@ -38,7 +39,16 @@ export declare const resetPassword: (data: IResetPasswordData) => Promise<AxiosR
|
|
|
38
39
|
export declare const processTicket: (hash: string) => Promise<AxiosResponse<any, any>>;
|
|
39
40
|
export declare const declineInvitation: (hash: string) => Promise<AxiosResponse<any, any>>;
|
|
40
41
|
export declare const sendRSVPInfo: (eventId: number, data: any) => Promise<AxiosResponse<any, any>>;
|
|
42
|
+
export declare const temporalNonce: () => Promise<AxiosResponse<any, any>>;
|
|
41
43
|
export declare const validatePhoneNumber: (phone: string) => Promise<any>;
|
|
44
|
+
export declare const connectMetamask: (blockchain: string, form: FormData) => Promise<AxiosResponse<any, any>>;
|
|
45
|
+
export declare const confirmMetamask: (blockchain: string, form: FormData) => Promise<AxiosResponse<any, any>>;
|
|
46
|
+
export declare const onConfirmConnectMetamask: (form: FormData) => Promise<AxiosResponse<any, any>>;
|
|
47
|
+
export declare const onUnconnectMetamask: () => Promise<AxiosResponse<any, any>>;
|
|
48
|
+
export declare const cryptoAccount: (blockchain: string) => Promise<AxiosResponse<any, any>>;
|
|
49
|
+
export declare const cryptoAddress: (blockchain: string, address: string) => Promise<AxiosResponse<any, any>>;
|
|
50
|
+
export declare const cryptoConnect: (blockchain: string, address: string, signature: string) => void;
|
|
51
|
+
export declare const cryptoA0K1: (address: string, ticketHash: string, amount: string) => Promise<AxiosResponse<any, any>>;
|
|
42
52
|
export declare const getAddons: (eventId: string) => Promise<any>;
|
|
43
53
|
export declare const selectAddons: (data: any) => void;
|
|
44
54
|
export declare const getCheckoutPageConfigs: () => Promise<any>;
|
|
@@ -1,10 +1,7 @@
|
|
|
1
1
|
interface ObjectLiteral {
|
|
2
2
|
[key: string]: any;
|
|
3
3
|
}
|
|
4
|
-
export declare const generateSelectOptions: (minCount?: number, maxCount?: number) =>
|
|
5
|
-
label: number;
|
|
6
|
-
value: number;
|
|
7
|
-
}[];
|
|
4
|
+
export declare const generateSelectOptions: (minCount?: number, maxCount?: number) => any[];
|
|
8
5
|
export declare const getAddonSelectOptions: (addons: any, choosedTicketCount: any) => {
|
|
9
6
|
addonsWithOptions: ObjectLiteral;
|
|
10
7
|
groupsWithSelectedVariantsInfo: ObjectLiteral;
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import { FormikErrors, FormikValues } from 'formik';
|
|
3
3
|
import { IGroupItem } from '../../types';
|
|
4
|
+
import { IBillingCryptoData } from "../../types/billing-info-data";
|
|
4
5
|
export interface ILoggedInValues {
|
|
5
6
|
emailLogged?: string;
|
|
6
7
|
firstNameLogged?: string;
|
|
@@ -14,7 +15,7 @@ export declare const createRegisterFormData: (values: IValues | undefined, check
|
|
|
14
15
|
attributes: {
|
|
15
16
|
[key: string]: any;
|
|
16
17
|
};
|
|
17
|
-
}, flagFreeTicket
|
|
18
|
+
}, flagFreeTicket: boolean | undefined, cryptoData: IBillingCryptoData) => FormData;
|
|
18
19
|
interface ICheckoutBody {
|
|
19
20
|
attributes: {
|
|
20
21
|
[key: string]: any;
|
|
@@ -34,6 +35,7 @@ interface IUserData {
|
|
|
34
35
|
zip?: string;
|
|
35
36
|
zipCode?: string;
|
|
36
37
|
stateId?: string;
|
|
38
|
+
linkedCryptoWallets?: string[];
|
|
37
39
|
}
|
|
38
40
|
export declare const setLoggedUserData: (data: IUserData) => {
|
|
39
41
|
id: string;
|
|
@@ -47,12 +49,29 @@ export declare const setLoggedUserData: (data: IUserData) => {
|
|
|
47
49
|
street_address: string;
|
|
48
50
|
state: string;
|
|
49
51
|
zip: string;
|
|
52
|
+
linkedCryptoWallets: string[];
|
|
50
53
|
};
|
|
51
54
|
export declare const createCheckoutDataBody: (ticketsQuantity: number, values?: IValues, logedInValues?: ILoggedInValues, includeDob?: boolean) => ICheckoutBody;
|
|
52
55
|
export declare const getValidateFunctions: (element: IGroupItem, states: {
|
|
53
56
|
[key: string]: any;
|
|
54
57
|
}[], values: FormikValues, errors: FormikErrors<any>) => (...value: any) => any;
|
|
55
58
|
export declare const assingUniqueIds: (data: any) => any;
|
|
59
|
+
export declare const signSubmit: ({ hasAccount, ethNonce, permittedBlockchains, cryptoWrapper, selectedBlockchain }: {
|
|
60
|
+
hasAccount: string;
|
|
61
|
+
ethNonce: string;
|
|
62
|
+
permittedBlockchains: any;
|
|
63
|
+
cryptoWrapper: any;
|
|
64
|
+
selectedBlockchain: string;
|
|
65
|
+
}) => Promise<{
|
|
66
|
+
usedAddress?: string;
|
|
67
|
+
signature?: string;
|
|
68
|
+
override_crypto_address?: boolean;
|
|
69
|
+
}>;
|
|
70
|
+
export declare const returnSelectedBlockchain: (permittedBlockchains: any, detectedWallets: string[]) => {
|
|
71
|
+
selectedBlockchain: string;
|
|
72
|
+
linkedAddress: string;
|
|
73
|
+
sessionAddress: string;
|
|
74
|
+
};
|
|
56
75
|
export declare const isRequiredField: (element: IGroupItem) => boolean;
|
|
57
76
|
export declare const getFieldLabel: (element: IGroupItem) => string | JSX.Element;
|
|
58
77
|
export declare const getFieldComponent: (element: IGroupItem) => any;
|
|
@@ -5,6 +5,11 @@ interface ITicketRowProps {
|
|
|
5
5
|
prevTicketTier: any;
|
|
6
6
|
selectedTickets: any;
|
|
7
7
|
handleTicketSelect: any;
|
|
8
|
+
walletNotVerified: boolean;
|
|
9
|
+
noWalletConnected: boolean;
|
|
10
|
+
cryptoIdentifier: any;
|
|
11
|
+
cryptoButtonDisabled: boolean;
|
|
12
|
+
walletConnect: (cryptoEventIdentifier: any, ethNonce: any) => void;
|
|
8
13
|
}
|
|
9
|
-
export declare const TicketRow: ({ ticketTier, prevTicketTier, selectedTickets, handleTicketSelect, }: ITicketRowProps) => JSX.Element;
|
|
14
|
+
export declare const TicketRow: ({ ticketTier, prevTicketTier, selectedTickets, handleTicketSelect, noWalletConnected, walletNotVerified, cryptoIdentifier, cryptoButtonDisabled, walletConnect }: ITicketRowProps) => JSX.Element;
|
|
10
15
|
export {};
|
|
@@ -10,6 +10,11 @@ interface ITicketsSectionProps {
|
|
|
10
10
|
ticketsHeaderComponent?: ReactNode;
|
|
11
11
|
showGroupNameBlock?: boolean;
|
|
12
12
|
currencySybmol?: string;
|
|
13
|
+
cryptoIdentifier: any;
|
|
14
|
+
cryptoButtonDisabled: boolean;
|
|
15
|
+
walletConnect: (cryptoEventIdentifier: any, ethNonce: any) => void;
|
|
16
|
+
walletNotVerified: boolean;
|
|
17
|
+
noWalletConnected: boolean;
|
|
13
18
|
}
|
|
14
|
-
export declare const TicketsSection: ({ event, ticketsList, selectedTickets, handleTicketSelect, sortBySoldOut, ticketsHeaderComponent, hideTicketsHeader, showGroupNameBlock, currencySybmol, }: ITicketsSectionProps) => JSX.Element;
|
|
19
|
+
export declare const TicketsSection: ({ event, ticketsList, selectedTickets, handleTicketSelect, sortBySoldOut, ticketsHeaderComponent, hideTicketsHeader, showGroupNameBlock, currencySybmol, cryptoIdentifier, cryptoButtonDisabled, walletConnect, noWalletConnected, walletNotVerified, }: ITicketsSectionProps) => JSX.Element;
|
|
15
20
|
export {};
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
export function CryptoIntegration(): {
|
|
2
|
+
isSupported: () => any;
|
|
3
|
+
enable: () => any;
|
|
4
|
+
getAuthenticatedUserAddress: () => Promise<any>;
|
|
5
|
+
getAddress: () => any;
|
|
6
|
+
getNonceFromAddress: (address: any) => Promise<any>;
|
|
7
|
+
getSignature: (address: any, nonce: any, message: any) => any;
|
|
8
|
+
authAddress: (address: any, signature: any) => Promise<any>;
|
|
9
|
+
connectAddress: (address: any, signature: any) => Promise<any>;
|
|
10
|
+
setBlockchain: (blockchain: any) => void;
|
|
11
|
+
getA0k1verseNFTs: (address: any, ticketHash: any, amount: any) => any;
|
|
12
|
+
hasAccountChanged: () => any;
|
|
13
|
+
ERRORS: {
|
|
14
|
+
API_KEY_MISSING: number;
|
|
15
|
+
ACCOUNT_NOT_FOUND: number;
|
|
16
|
+
CONNECTION_REJECTED: number;
|
|
17
|
+
SIGNATURE_REJECTED: number;
|
|
18
|
+
SIGNATURE_MISMATCHED: number;
|
|
19
|
+
NOT_AUTHENTICATED: number;
|
|
20
|
+
WEB3_ERROR: number;
|
|
21
|
+
SERVER_ERROR: number;
|
|
22
|
+
METHOD_NOT_SUPPORTED_BY_BLOCKCHAIN: number;
|
|
23
|
+
};
|
|
24
|
+
};
|