@funkit/connect 5.0.2 → 5.0.3
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/CHANGELOG.md +20 -0
- package/dist/{chunk-LEZIQHUN.js → chunk-3LPXAPO7.js} +4 -0
- package/dist/{chunk-3OKZVQR2.js → chunk-TPZ2ZISU.js} +4 -0
- package/dist/components/Box/Box.d.ts +28 -28
- package/dist/components/Dialog/DialogContent.css.d.ts +2 -0
- package/dist/components/FunButton/FunButton.d.ts +2 -1
- package/dist/{modals/FunCheckoutHistoryModal → components/FunCheckoutHistory}/FunCheckoutHistoryContent.d.ts +3 -2
- package/dist/{modals/FunCheckoutHistoryModal → components/FunCheckoutHistory}/FunCheckoutHistoryDetail.d.ts +3 -1
- package/dist/{modals/FunCheckoutHistoryModal → components/FunCheckoutHistory}/FunCheckoutHistoryHelp.d.ts +6 -2
- package/dist/components/FunCheckoutHistory/FunCheckoutHistoryTransaction.css.d.ts +1 -0
- package/dist/{modals/FunCheckoutHistoryModal → components/FunCheckoutHistory}/FunCheckoutHistoryTransaction.d.ts +4 -0
- package/dist/components/FunNotificationBanner/FunNotificationBanner.css.d.ts +1 -1
- package/dist/components/FunNotificationBanner/FunNotificationBanner.d.ts +3 -4
- package/dist/components/FunNotificationBanner/FunNotificationBannerIcon.css.d.ts +4 -0
- package/dist/components/FunNotificationBanner/FunNotificationBannerIcon.d.ts +3 -2
- package/dist/components/FunNotificationBanner/FunNotificationBannerSummary.d.ts +3 -7
- package/dist/components/FunNotificationBanner/FunNotificationShowMoreButton.d.ts +8 -0
- package/dist/components/FunTransactionSummary/FunTxSummaryComponents.d.ts +1 -5
- package/dist/components/FunTransactionSummary/PaymentFeesSummary.css.d.ts +1 -0
- package/dist/components/Icons/Icons.css.d.ts +2 -0
- package/dist/components/Icons/SpinnerIconWithBackground.d.ts +6 -0
- package/dist/consts/layout.d.ts +1 -0
- package/dist/css/sprinkles.css.d.ts +36 -28
- package/dist/domains/checkoutState.d.ts +1 -0
- package/dist/hooks/queries/useCheckout.d.ts +3 -0
- package/dist/hooks/queries/useRecentCheckouts.d.ts +17 -0
- package/dist/hooks/useCheckoutAccountBalanceTransfer.d.ts +1 -1
- package/dist/hooks/useUpdateActiveFunkitCheckout.d.ts +8 -0
- package/dist/index.css +1536 -1257
- package/dist/index.d.ts +1 -1
- package/dist/index.js +2691 -1738
- package/dist/modals/CheckoutModal/CheckoutComplete/CheckoutComplete.d.ts +8 -3
- package/dist/modals/CheckoutModal/CheckoutComplete/useLogCheckoutCompletion.d.ts +3 -0
- package/dist/modals/CheckoutModal/CheckoutHelp/CheckoutHelp.d.ts +9 -0
- package/dist/modals/CheckoutModal/CheckoutNotification.d.ts +12 -0
- package/dist/modals/CheckoutModal/CheckoutNotifications.d.ts +9 -0
- package/dist/modals/CheckoutModal/stepTransition.d.ts +10 -2
- package/dist/providers/FunkitCheckoutContext.d.ts +1 -0
- package/dist/providers/FunkitProvider.d.ts +0 -6
- package/dist/providers/FunkitThemeProvider.d.ts +12 -0
- package/dist/providers/GeneralWalletProvider.d.ts +8 -8
- package/dist/providers/ModalContext.d.ts +0 -4
- package/dist/themes/darkTheme.js +1 -1
- package/dist/themes/lightTheme.js +1 -1
- package/dist/utils/checkout.d.ts +5 -1
- package/dist/utils/checkoutHistory.d.ts +0 -8
- package/dist/utils/flags/config.d.ts +4 -0
- package/dist/wallets/walletConnectors/index.js +53 -53
- package/package.json +5 -5
- package/dist/modals/CheckoutModal/CheckoutComplete/useRedirectToCheckoutHistory.d.ts +0 -3
- package/dist/modals/FunCheckoutHistoryModal/FunCheckoutHistoryModal.d.ts +0 -10
- package/dist/modals/FunCheckoutHistoryModal/FunCheckoutHistoryTransaction.css.d.ts +0 -3
- package/dist/providers/AppContext.d.ts +0 -20
- /package/dist/{modals/FunCheckoutHistoryModal → components/FunCheckoutHistory}/FunCheckoutStatus.css.d.ts +0 -0
- /package/dist/{modals/FunCheckoutHistoryModal → components/FunCheckoutHistory}/FunCheckoutStatus.d.ts +0 -0
- /package/dist/{modals/FunCheckoutHistoryModal → components/FunCheckoutHistory}/useCustomStatusAnimationAboveTopbar.d.ts +0 -0
|
@@ -1,8 +1,13 @@
|
|
|
1
|
+
import React from 'react';
|
|
1
2
|
import type { Address } from 'viem';
|
|
2
|
-
import type
|
|
3
|
+
import { type CheckoutModalCommonState, FunCheckoutStep, type ModalStepComponentProps, type ModalStepInfo } from '../stepTransition';
|
|
3
4
|
export type CheckoutCompleteState = CheckoutModalCommonState & {
|
|
4
5
|
depositAddress: Address;
|
|
5
6
|
};
|
|
7
|
+
export type CheckoutCompleteNext = Record<string, never>;
|
|
8
|
+
export type ConfirmationStepNext = {
|
|
9
|
+
depositAddress: Address;
|
|
10
|
+
};
|
|
6
11
|
export declare const CheckoutCompleteInfo: ModalStepInfo<FunCheckoutStep.CHECKOUT_COMPLETE>;
|
|
7
|
-
/** A
|
|
8
|
-
export declare function CheckoutComplete({ modalState, onClose, }: ModalStepComponentProps<FunCheckoutStep.CHECKOUT_COMPLETE>):
|
|
12
|
+
/** A checkout detail component to handle redirecting to the checkout history page */
|
|
13
|
+
export declare function CheckoutComplete({ modalState, onClose, onNext, }: ModalStepComponentProps<FunCheckoutStep.CHECKOUT_COMPLETE>): React.JSX.Element;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import type { Address } from 'viem';
|
|
3
|
+
import type { CheckoutModalCommonState, FunCheckoutStep, ModalStepComponentProps, ModalStepInfo } from '../stepTransition';
|
|
4
|
+
export type CheckoutHelpState = CheckoutModalCommonState & {
|
|
5
|
+
depositAddress: Address;
|
|
6
|
+
};
|
|
7
|
+
export declare const CheckoutHelpInfo: ModalStepInfo<FunCheckoutStep.CHECKOUT_HELP>;
|
|
8
|
+
/** Help Form in checkout modal */
|
|
9
|
+
export declare function CheckoutHelp({ modalState, onClose, onBack, }: ModalStepComponentProps<FunCheckoutStep.CHECKOUT_HELP>): React.JSX.Element;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import type { CheckoutHistoryItem } from '@funkit/api-base';
|
|
3
|
+
import type { Address } from 'viem';
|
|
4
|
+
import { type CheckoutStatus } from '~/domains/checkoutState';
|
|
5
|
+
export type NotificationStatus = CheckoutStatus | 'delayed';
|
|
6
|
+
interface CheckoutNotificationProps {
|
|
7
|
+
checkout: CheckoutHistoryItem;
|
|
8
|
+
onClose: (id: string) => void;
|
|
9
|
+
onHelp: (depositAddress: Address) => void;
|
|
10
|
+
}
|
|
11
|
+
export declare const CheckoutNotification: ({ checkout: defaultCheckout, onClose, onHelp, }: CheckoutNotificationProps) => React.JSX.Element | null;
|
|
12
|
+
export {};
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import type { Address } from 'viem';
|
|
3
|
+
interface CheckoutNotificationsProps {
|
|
4
|
+
onHelp: (depositAddress: Address) => void;
|
|
5
|
+
/** To control notifications visibility on specific pages, without changing internal dismissal state */
|
|
6
|
+
isVisible: boolean;
|
|
7
|
+
}
|
|
8
|
+
export declare const CheckoutNotifications: ({ onHelp, isVisible, }: CheckoutNotificationsProps) => React.JSX.Element | null;
|
|
9
|
+
export {};
|
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import { type ComponentType, type SetStateAction } from 'react';
|
|
2
2
|
import type { FunkitActiveCheckoutItem } from '../../providers/FunkitCheckoutContext';
|
|
3
3
|
import { type FunkitTextCustomizationsConfig } from '../../providers/FunkitConfigContext';
|
|
4
|
-
import { type CheckoutCompleteState } from './CheckoutComplete/CheckoutComplete';
|
|
4
|
+
import { type CheckoutCompleteNext, type CheckoutCompleteState } from './CheckoutComplete/CheckoutComplete';
|
|
5
|
+
import { type CheckoutHelpState } from './CheckoutHelp/CheckoutHelp';
|
|
5
6
|
import { type ConfirmationStepNext, type ConfirmationStepState } from './ConfirmationStep/ConfirmationStep';
|
|
6
7
|
import { type ConnectExchangeNext, type ConnectExchangeState } from './ConnectExchange';
|
|
7
8
|
import { type InputAmountNext, type InputAmountState } from './InputAmount/InputAmount';
|
|
@@ -37,6 +38,7 @@ export declare enum FunCheckoutStep {
|
|
|
37
38
|
SELECT_ASSET = "select_asset",
|
|
38
39
|
MESH_VERIFICATION = "mesh_verification",
|
|
39
40
|
CHECKOUT_COMPLETE = "checkout_complete",
|
|
41
|
+
CHECKOUT_HELP = "checkout_help",
|
|
40
42
|
TRANSFER_TOKEN = "transfer_token"
|
|
41
43
|
}
|
|
42
44
|
export type ModalStepInfo<S extends FunCheckoutStep> = {
|
|
@@ -47,6 +49,8 @@ export type ModalStepInfo<S extends FunCheckoutStep> = {
|
|
|
47
49
|
showFullHeight?: boolean;
|
|
48
50
|
/** Defaults to checkoutItem.initSettings.config.modalTitle (returning undefined uses default) */
|
|
49
51
|
title?(textCustomizations: FunkitTextCustomizationsConfig, isDydx: boolean): string | undefined;
|
|
52
|
+
/** If title is not defined in config nor with the title() function, this is used instead. Defaults to 'Checkout' */
|
|
53
|
+
fallbackTitle?: string;
|
|
50
54
|
};
|
|
51
55
|
export declare const CheckoutModalSteps: {
|
|
52
56
|
[S in FunCheckoutStep]: ModalStepInfo<S>;
|
|
@@ -54,6 +58,7 @@ export declare const CheckoutModalSteps: {
|
|
|
54
58
|
type CheckoutModalState<S extends FunCheckoutStep = FunCheckoutStep> = {
|
|
55
59
|
[T in S]: {
|
|
56
60
|
[FunCheckoutStep.CHECKOUT_COMPLETE]: CheckoutCompleteState;
|
|
61
|
+
[FunCheckoutStep.CHECKOUT_HELP]: CheckoutHelpState;
|
|
57
62
|
[FunCheckoutStep.CONFIRMATION]: ConfirmationStepState;
|
|
58
63
|
[FunCheckoutStep.CONNECT_EXCHANGE]: ConnectExchangeState;
|
|
59
64
|
[FunCheckoutStep.INPUT_AMOUNT]: InputAmountState;
|
|
@@ -69,7 +74,8 @@ type CheckoutModalState<S extends FunCheckoutStep = FunCheckoutStep> = {
|
|
|
69
74
|
};
|
|
70
75
|
}[S];
|
|
71
76
|
type NextPayload<S extends FunCheckoutStep = FunCheckoutStep> = {
|
|
72
|
-
[FunCheckoutStep.
|
|
77
|
+
[FunCheckoutStep.CHECKOUT_HELP]: null;
|
|
78
|
+
[FunCheckoutStep.CHECKOUT_COMPLETE]: CheckoutCompleteNext;
|
|
73
79
|
[FunCheckoutStep.CONFIRMATION]: ConfirmationStepNext;
|
|
74
80
|
[FunCheckoutStep.CONNECT_EXCHANGE]: ConnectExchangeNext;
|
|
75
81
|
[FunCheckoutStep.INPUT_AMOUNT]: InputAmountNext;
|
|
@@ -90,6 +96,8 @@ export declare function useCheckoutModalTransition(checkoutItem: FunkitActiveChe
|
|
|
90
96
|
onBack: () => void;
|
|
91
97
|
onCloseWrapper: () => void;
|
|
92
98
|
onNext: (payload: NextPayload) => void;
|
|
99
|
+
/** Only use as a last resort. Prefer next/back for proper navigation */
|
|
100
|
+
onStepChange: (nextState: CheckoutModalState) => void;
|
|
93
101
|
setModalState: import("react").Dispatch<SetStateAction<CheckoutModalState<FunCheckoutStep>>>;
|
|
94
102
|
hasHistoryEntry: boolean;
|
|
95
103
|
};
|
|
@@ -101,6 +101,7 @@ export interface FunkitActiveCheckoutItem extends Omit<ApiCheckoutClientMetadata
|
|
|
101
101
|
interface FunkitCheckoutContextInterface {
|
|
102
102
|
checkoutItem: FunkitActiveCheckoutItem | null;
|
|
103
103
|
initNewCheckout(initSettings: UseFunkitCheckoutPropsWithFullConfig): string;
|
|
104
|
+
updateModalTitleMeta(newMeta: string): void;
|
|
104
105
|
updateSourceAsset(selectedSource: Omit<AssetHoldingsItem, 'amount' | 'usdAmount' | 'chainSymbolKey'>): void;
|
|
105
106
|
updateTargetAssetAmount(newTargetAssetAmount: number): void;
|
|
106
107
|
updateTargetAsset(asset: {
|
|
@@ -3,7 +3,6 @@ import React, { type ReactNode } from 'react';
|
|
|
3
3
|
import type { Chain } from 'wagmi/chains';
|
|
4
4
|
import type { Locale } from '~/locales';
|
|
5
5
|
import { type CreateFunkitWagmiConfigParameters } from '../config/getDefaultConfig';
|
|
6
|
-
import { type DisclaimerComponent } from './AppContext';
|
|
7
6
|
import { type AvatarComponent } from './AvatarContext';
|
|
8
7
|
import { type FunkitConfig } from './FunkitConfigContext';
|
|
9
8
|
import { type Theme } from './FunkitThemeProvider';
|
|
@@ -16,11 +15,6 @@ interface FunkitProviderInnerProps {
|
|
|
16
15
|
id?: string;
|
|
17
16
|
children: ReactNode;
|
|
18
17
|
theme?: Theme;
|
|
19
|
-
appInfo?: {
|
|
20
|
-
appName?: string;
|
|
21
|
-
learnMoreUrl?: string;
|
|
22
|
-
disclaimer?: DisclaimerComponent;
|
|
23
|
-
};
|
|
24
18
|
avatar?: AvatarComponent;
|
|
25
19
|
/** @deprecated This currently has no effect, localization is not yet supported */
|
|
26
20
|
locale?: Locale;
|
|
@@ -51,6 +51,7 @@ export declare const useActiveTheme: () => {
|
|
|
51
51
|
hoverState: string;
|
|
52
52
|
lightStroke: string;
|
|
53
53
|
mediumStroke: string;
|
|
54
|
+
heavyStroke: string;
|
|
54
55
|
strokeColor: string;
|
|
55
56
|
dydxSwitchActiveBackground: string;
|
|
56
57
|
primaryText: string;
|
|
@@ -87,6 +88,8 @@ export declare const useActiveTheme: () => {
|
|
|
87
88
|
badgeBackgroundSuccess: string;
|
|
88
89
|
badgeBorderSuccess: string;
|
|
89
90
|
badgeTextSuccess: string;
|
|
91
|
+
announceGradientFrom: string;
|
|
92
|
+
announceGradientTo: string;
|
|
90
93
|
};
|
|
91
94
|
fonts: {
|
|
92
95
|
body: string;
|
|
@@ -155,6 +158,7 @@ export declare const useActiveTheme: () => {
|
|
|
155
158
|
selectedOption: string;
|
|
156
159
|
selectedWallet: string;
|
|
157
160
|
dropdown: string;
|
|
161
|
+
notification: string;
|
|
158
162
|
vertexDropdown: string;
|
|
159
163
|
};
|
|
160
164
|
blurs: {
|
|
@@ -195,6 +199,7 @@ export declare const useActiveTheme: () => {
|
|
|
195
199
|
hoverState: string;
|
|
196
200
|
lightStroke: string;
|
|
197
201
|
mediumStroke: string;
|
|
202
|
+
heavyStroke: string;
|
|
198
203
|
strokeColor: string;
|
|
199
204
|
dydxSwitchActiveBackground: string;
|
|
200
205
|
primaryText: string;
|
|
@@ -231,6 +236,8 @@ export declare const useActiveTheme: () => {
|
|
|
231
236
|
badgeBackgroundSuccess: string;
|
|
232
237
|
badgeBorderSuccess: string;
|
|
233
238
|
badgeTextSuccess: string;
|
|
239
|
+
announceGradientFrom: string;
|
|
240
|
+
announceGradientTo: string;
|
|
234
241
|
};
|
|
235
242
|
fonts: {
|
|
236
243
|
body: string;
|
|
@@ -299,6 +306,7 @@ export declare const useActiveTheme: () => {
|
|
|
299
306
|
selectedOption: string;
|
|
300
307
|
selectedWallet: string;
|
|
301
308
|
dropdown: string;
|
|
309
|
+
notification: string;
|
|
302
310
|
vertexDropdown: string;
|
|
303
311
|
};
|
|
304
312
|
blurs: {
|
|
@@ -337,6 +345,7 @@ export declare const useActiveTheme: () => {
|
|
|
337
345
|
hoverState: string;
|
|
338
346
|
lightStroke: string;
|
|
339
347
|
mediumStroke: string;
|
|
348
|
+
heavyStroke: string;
|
|
340
349
|
strokeColor: string;
|
|
341
350
|
dydxSwitchActiveBackground: string;
|
|
342
351
|
primaryText: string;
|
|
@@ -373,6 +382,8 @@ export declare const useActiveTheme: () => {
|
|
|
373
382
|
badgeBackgroundSuccess: string;
|
|
374
383
|
badgeBorderSuccess: string;
|
|
375
384
|
badgeTextSuccess: string;
|
|
385
|
+
announceGradientFrom: string;
|
|
386
|
+
announceGradientTo: string;
|
|
376
387
|
};
|
|
377
388
|
fonts: {
|
|
378
389
|
body: string;
|
|
@@ -441,6 +452,7 @@ export declare const useActiveTheme: () => {
|
|
|
441
452
|
selectedOption: string;
|
|
442
453
|
selectedWallet: string;
|
|
443
454
|
dropdown: string;
|
|
455
|
+
notification: string;
|
|
444
456
|
vertexDropdown: string;
|
|
445
457
|
};
|
|
446
458
|
blurs: {
|
|
@@ -96,15 +96,15 @@ export declare const useFunkitDisconnect: () => {
|
|
|
96
96
|
error: null;
|
|
97
97
|
data: undefined;
|
|
98
98
|
status: "idle";
|
|
99
|
+
isPaused: boolean;
|
|
100
|
+
context: unknown;
|
|
99
101
|
isError: false;
|
|
100
102
|
isPending: false;
|
|
101
103
|
isSuccess: false;
|
|
102
104
|
failureCount: number;
|
|
103
105
|
failureReason: import("@wagmi/core").DisconnectErrorType | null;
|
|
104
|
-
isPaused: boolean;
|
|
105
106
|
variables: undefined;
|
|
106
107
|
isIdle: true;
|
|
107
|
-
context: unknown;
|
|
108
108
|
submittedAt: number;
|
|
109
109
|
connectors: readonly import("wagmi").Connector[];
|
|
110
110
|
} | {
|
|
@@ -114,15 +114,15 @@ export declare const useFunkitDisconnect: () => {
|
|
|
114
114
|
error: null;
|
|
115
115
|
data: undefined;
|
|
116
116
|
status: "pending";
|
|
117
|
+
isPaused: boolean;
|
|
118
|
+
context: unknown;
|
|
117
119
|
isError: false;
|
|
118
120
|
isPending: true;
|
|
119
121
|
isSuccess: false;
|
|
120
122
|
failureCount: number;
|
|
121
123
|
failureReason: import("@wagmi/core").DisconnectErrorType | null;
|
|
122
|
-
isPaused: boolean;
|
|
123
124
|
variables: import("wagmi/query").DisconnectVariables;
|
|
124
125
|
isIdle: false;
|
|
125
|
-
context: unknown;
|
|
126
126
|
submittedAt: number;
|
|
127
127
|
connectors: readonly import("wagmi").Connector[];
|
|
128
128
|
} | {
|
|
@@ -132,15 +132,15 @@ export declare const useFunkitDisconnect: () => {
|
|
|
132
132
|
error: import("@wagmi/core").DisconnectErrorType;
|
|
133
133
|
data: undefined;
|
|
134
134
|
status: "error";
|
|
135
|
+
isPaused: boolean;
|
|
136
|
+
context: unknown;
|
|
135
137
|
isError: true;
|
|
136
138
|
isPending: false;
|
|
137
139
|
isSuccess: false;
|
|
138
140
|
failureCount: number;
|
|
139
141
|
failureReason: import("@wagmi/core").DisconnectErrorType | null;
|
|
140
|
-
isPaused: boolean;
|
|
141
142
|
variables: import("wagmi/query").DisconnectVariables;
|
|
142
143
|
isIdle: false;
|
|
143
|
-
context: unknown;
|
|
144
144
|
submittedAt: number;
|
|
145
145
|
connectors: readonly import("wagmi").Connector[];
|
|
146
146
|
} | {
|
|
@@ -150,15 +150,15 @@ export declare const useFunkitDisconnect: () => {
|
|
|
150
150
|
error: null;
|
|
151
151
|
data: void;
|
|
152
152
|
status: "success";
|
|
153
|
+
isPaused: boolean;
|
|
154
|
+
context: unknown;
|
|
153
155
|
isError: false;
|
|
154
156
|
isPending: false;
|
|
155
157
|
isSuccess: true;
|
|
156
158
|
failureCount: number;
|
|
157
159
|
failureReason: import("@wagmi/core").DisconnectErrorType | null;
|
|
158
|
-
isPaused: boolean;
|
|
159
160
|
variables: import("wagmi/query").DisconnectVariables;
|
|
160
161
|
isIdle: false;
|
|
161
|
-
context: unknown;
|
|
162
162
|
submittedAt: number;
|
|
163
163
|
connectors: readonly import("wagmi").Connector[];
|
|
164
164
|
};
|
|
@@ -29,8 +29,4 @@ export declare function useFunCheckoutModal(): {
|
|
|
29
29
|
funCheckoutModalOpen: boolean;
|
|
30
30
|
openFunCheckoutModal: ((checkoutId: string) => void) | undefined;
|
|
31
31
|
};
|
|
32
|
-
export declare function useFunCheckoutHistoryModal(): {
|
|
33
|
-
funCheckoutHistoryModalOpen: boolean;
|
|
34
|
-
openFunCheckoutHistoryModal: ((depositAddressInitialPageCombined: string) => void) | undefined;
|
|
35
|
-
};
|
|
36
32
|
export {};
|
package/dist/themes/darkTheme.js
CHANGED
package/dist/utils/checkout.d.ts
CHANGED
|
@@ -51,6 +51,7 @@ export declare function getFunkitEnvForCheckoutEstimation({ chainId, bypassWalle
|
|
|
51
51
|
bypassInit: boolean;
|
|
52
52
|
apiKey?: string;
|
|
53
53
|
nonce?: bigint | undefined;
|
|
54
|
+
logger?: import("@funkit/api-base").Logger | undefined;
|
|
54
55
|
fee?: {
|
|
55
56
|
token?: string;
|
|
56
57
|
amount?: number;
|
|
@@ -58,7 +59,6 @@ export declare function getFunkitEnvForCheckoutEstimation({ chainId, bypassWalle
|
|
|
58
59
|
recipient: Address;
|
|
59
60
|
} | undefined;
|
|
60
61
|
skipDBAction?: boolean | undefined;
|
|
61
|
-
logger?: import("@funkit/api-base").Logger | undefined;
|
|
62
62
|
};
|
|
63
63
|
export type TokenInfo = {
|
|
64
64
|
symbol: string;
|
|
@@ -118,3 +118,7 @@ export declare function isCheckoutCrFlow(checkoutItem: FunkitActiveCheckoutItem)
|
|
|
118
118
|
* @param config can be either be a config from live checkoutItem OR from checkout history's clientMetadata
|
|
119
119
|
*/
|
|
120
120
|
export declare function isCheckoutPostActionRequired(config: FunkitCheckoutConfig | ServerCheckoutConfig): boolean;
|
|
121
|
+
/**
|
|
122
|
+
* @returns whether we should show the checkout to the user (ie. supported in current sdk version & not cancelled)
|
|
123
|
+
*/
|
|
124
|
+
export declare const isCheckoutValid: (checkout: CheckoutHistoryItem) => boolean;
|
|
@@ -3,14 +3,6 @@ export declare enum HistoryContentPages {
|
|
|
3
3
|
DETAIL = "detail",
|
|
4
4
|
HELP = "help"
|
|
5
5
|
}
|
|
6
|
-
export declare const combineDepositAddressAndInitialPage: ({ depositAddress, initialPage, }: {
|
|
7
|
-
depositAddress: string;
|
|
8
|
-
initialPage: HistoryContentPages;
|
|
9
|
-
}) => string;
|
|
10
|
-
export declare const deconstructDepositAddressAndInitialPage: (combined: string) => {
|
|
11
|
-
depositAddress: `0x${string}`;
|
|
12
|
-
initialPage: HistoryContentPages;
|
|
13
|
-
};
|
|
14
6
|
export declare function getLatestReportSubmitTime(): number;
|
|
15
7
|
export declare function setLatestReportSubmitTime(timeMs: number): void;
|
|
16
8
|
export declare function clearLatestWalletId(): void;
|
|
@@ -6,65 +6,65 @@ import {
|
|
|
6
6
|
zerionWallet
|
|
7
7
|
} from "./chunk-AXWP3GD4.js";
|
|
8
8
|
import {
|
|
9
|
-
|
|
10
|
-
} from "./chunk-
|
|
9
|
+
xdefiWallet
|
|
10
|
+
} from "./chunk-NO7XMBB5.js";
|
|
11
|
+
import {
|
|
12
|
+
safeWallet
|
|
13
|
+
} from "./chunk-BQQQL6UD.js";
|
|
11
14
|
import {
|
|
12
15
|
tahoWallet
|
|
13
16
|
} from "./chunk-6P2EMPZI.js";
|
|
14
17
|
import {
|
|
15
|
-
|
|
16
|
-
} from "./chunk-
|
|
18
|
+
tokenaryWallet
|
|
19
|
+
} from "./chunk-SLOIIJGP.js";
|
|
17
20
|
import {
|
|
18
|
-
|
|
19
|
-
} from "./chunk-
|
|
21
|
+
tokenPocketWallet
|
|
22
|
+
} from "./chunk-IDKVN5CF.js";
|
|
20
23
|
import {
|
|
21
24
|
talismanWallet
|
|
22
25
|
} from "./chunk-ABFSXBE6.js";
|
|
23
26
|
import {
|
|
24
|
-
|
|
25
|
-
} from "./chunk-
|
|
27
|
+
trustWallet
|
|
28
|
+
} from "./chunk-ISIBREBO.js";
|
|
26
29
|
import {
|
|
27
30
|
walletConnectWallet
|
|
28
31
|
} from "./chunk-NP5QGWNL.js";
|
|
29
|
-
import {
|
|
30
|
-
xdefiWallet
|
|
31
|
-
} from "./chunk-NO7XMBB5.js";
|
|
32
32
|
import {
|
|
33
33
|
uniswapWallet
|
|
34
34
|
} from "./chunk-LH7BMNFZ.js";
|
|
35
35
|
import {
|
|
36
|
-
|
|
37
|
-
} from "./chunk-
|
|
36
|
+
phantomWallet
|
|
37
|
+
} from "./chunk-ZSVTX6EK.js";
|
|
38
38
|
import {
|
|
39
|
-
|
|
40
|
-
} from "./chunk-
|
|
39
|
+
oneKeyWallet
|
|
40
|
+
} from "./chunk-4AD7VI2P.js";
|
|
41
41
|
import {
|
|
42
42
|
rainbowWallet
|
|
43
43
|
} from "./chunk-2UCNRD7H.js";
|
|
44
44
|
import {
|
|
45
45
|
roninWallet
|
|
46
46
|
} from "./chunk-63YLN6R5.js";
|
|
47
|
-
import {
|
|
48
|
-
safeheronWallet
|
|
49
|
-
} from "./chunk-R6RWZRFF.js";
|
|
50
47
|
import {
|
|
51
48
|
ramperWallet
|
|
52
49
|
} from "./chunk-PIUNLQJG.js";
|
|
50
|
+
import {
|
|
51
|
+
safepalWallet
|
|
52
|
+
} from "./chunk-MSFKSQBY.js";
|
|
53
|
+
import {
|
|
54
|
+
safeheronWallet
|
|
55
|
+
} from "./chunk-R6RWZRFF.js";
|
|
53
56
|
import {
|
|
54
57
|
subWallet
|
|
55
58
|
} from "./chunk-AD2KIJB6.js";
|
|
56
|
-
import {
|
|
57
|
-
safeWallet
|
|
58
|
-
} from "./chunk-BQQQL6UD.js";
|
|
59
59
|
import {
|
|
60
60
|
ledgerWallet
|
|
61
61
|
} from "./chunk-BRBKM4PW.js";
|
|
62
|
-
import {
|
|
63
|
-
mewWallet
|
|
64
|
-
} from "./chunk-V57WLZEE.js";
|
|
65
62
|
import {
|
|
66
63
|
metaMaskWallet
|
|
67
64
|
} from "./chunk-G73C6P5P.js";
|
|
65
|
+
import {
|
|
66
|
+
mewWallet
|
|
67
|
+
} from "./chunk-V57WLZEE.js";
|
|
68
68
|
import {
|
|
69
69
|
oktoWallet
|
|
70
70
|
} from "./chunk-ADIXAKUL.js";
|
|
@@ -75,11 +75,14 @@ import {
|
|
|
75
75
|
okxWallet
|
|
76
76
|
} from "./chunk-4WEHDI4Y.js";
|
|
77
77
|
import {
|
|
78
|
-
|
|
79
|
-
} from "./chunk-
|
|
78
|
+
oneInchWallet
|
|
79
|
+
} from "./chunk-OESTDX6I.js";
|
|
80
80
|
import {
|
|
81
|
-
|
|
82
|
-
} from "./chunk-
|
|
81
|
+
rabbyWallet
|
|
82
|
+
} from "./chunk-BVX4XGNP.js";
|
|
83
|
+
import {
|
|
84
|
+
dawnWallet
|
|
85
|
+
} from "./chunk-LN7OD5EC.js";
|
|
83
86
|
import {
|
|
84
87
|
frameWallet
|
|
85
88
|
} from "./chunk-ZMYVTWDF.js";
|
|
@@ -87,38 +90,35 @@ import {
|
|
|
87
90
|
frontierWallet
|
|
88
91
|
} from "./chunk-3S2U24BJ.js";
|
|
89
92
|
import {
|
|
90
|
-
|
|
91
|
-
} from "./chunk-
|
|
92
|
-
import {
|
|
93
|
-
imTokenWallet
|
|
94
|
-
} from "./chunk-COZ7MIQS.js";
|
|
93
|
+
gateWallet
|
|
94
|
+
} from "./chunk-GSOYKKIS.js";
|
|
95
95
|
import {
|
|
96
96
|
kresusWallet
|
|
97
97
|
} from "./chunk-MJXPRJZT.js";
|
|
98
|
+
import {
|
|
99
|
+
imTokenWallet
|
|
100
|
+
} from "./chunk-COZ7MIQS.js";
|
|
98
101
|
import {
|
|
99
102
|
injectedWallet
|
|
100
103
|
} from "./chunk-VCVVV2K7.js";
|
|
101
|
-
import {
|
|
102
|
-
gateWallet
|
|
103
|
-
} from "./chunk-GSOYKKIS.js";
|
|
104
104
|
import {
|
|
105
105
|
bybitWallet
|
|
106
106
|
} from "./chunk-6ONTSPEY.js";
|
|
107
|
+
import {
|
|
108
|
+
coin98Wallet
|
|
109
|
+
} from "./chunk-DTRYS3MO.js";
|
|
110
|
+
import {
|
|
111
|
+
coinbaseWallet
|
|
112
|
+
} from "./chunk-H4IRCEZN.js";
|
|
107
113
|
import {
|
|
108
114
|
clvWallet
|
|
109
115
|
} from "./chunk-KR6JBW5E.js";
|
|
116
|
+
import {
|
|
117
|
+
desigWallet
|
|
118
|
+
} from "./chunk-CTU6JCOK.js";
|
|
110
119
|
import {
|
|
111
120
|
coreWallet
|
|
112
121
|
} from "./chunk-HBA36GW3.js";
|
|
113
|
-
import {
|
|
114
|
-
bitgetWallet
|
|
115
|
-
} from "./chunk-A5APNTGL.js";
|
|
116
|
-
import {
|
|
117
|
-
dawnWallet
|
|
118
|
-
} from "./chunk-LN7OD5EC.js";
|
|
119
|
-
import {
|
|
120
|
-
coinbaseWallet
|
|
121
|
-
} from "./chunk-H4IRCEZN.js";
|
|
122
122
|
import {
|
|
123
123
|
enkryptWallet
|
|
124
124
|
} from "./chunk-SJTXS4ZW.js";
|
|
@@ -129,24 +129,24 @@ import {
|
|
|
129
129
|
argentWallet
|
|
130
130
|
} from "./chunk-WSQ2YJO2.js";
|
|
131
131
|
import {
|
|
132
|
-
|
|
133
|
-
} from "./chunk-
|
|
132
|
+
bitverseWallet
|
|
133
|
+
} from "./chunk-3HZRRP4Y.js";
|
|
134
134
|
import {
|
|
135
135
|
bitskiWallet
|
|
136
136
|
} from "./chunk-P74YPRF6.js";
|
|
137
|
+
import {
|
|
138
|
+
bitgetWallet
|
|
139
|
+
} from "./chunk-A5APNTGL.js";
|
|
137
140
|
import {
|
|
138
141
|
bloomWallet
|
|
139
142
|
} from "./chunk-S27IADFU.js";
|
|
140
143
|
import {
|
|
141
|
-
|
|
142
|
-
} from "./chunk-
|
|
144
|
+
bifrostWallet
|
|
145
|
+
} from "./chunk-W6N74MS3.js";
|
|
146
|
+
import "./chunk-23WIEY36.js";
|
|
143
147
|
import {
|
|
144
148
|
braveWallet
|
|
145
149
|
} from "./chunk-PB254NQ4.js";
|
|
146
|
-
import {
|
|
147
|
-
coin98Wallet
|
|
148
|
-
} from "./chunk-DTRYS3MO.js";
|
|
149
|
-
import "./chunk-23WIEY36.js";
|
|
150
150
|
import "./chunk-WRA2DVJ7.js";
|
|
151
151
|
export {
|
|
152
152
|
argentWallet,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@funkit/connect",
|
|
3
|
-
"version": "5.0.
|
|
3
|
+
"version": "5.0.3",
|
|
4
4
|
"description": "Funkit Connect SDK elevates DeFi apps via web2 sign-ins and one-click checkouts.",
|
|
5
5
|
"files": [
|
|
6
6
|
"dist",
|
|
@@ -90,11 +90,11 @@
|
|
|
90
90
|
"react-virtuoso": "4.10.1",
|
|
91
91
|
"ua-parser-js": "^1.0.37",
|
|
92
92
|
"uuid": "^9.0.1",
|
|
93
|
-
"@funkit/api-base": "1.5.
|
|
94
|
-
"@funkit/core": "2.3.7",
|
|
93
|
+
"@funkit/api-base": "1.5.7",
|
|
95
94
|
"@funkit/chains": "0.1.2",
|
|
96
|
-
"@funkit/wagmi-tools": "3.0.
|
|
97
|
-
"@funkit/utils": "1.0.
|
|
95
|
+
"@funkit/wagmi-tools": "3.0.30",
|
|
96
|
+
"@funkit/utils": "1.0.7",
|
|
97
|
+
"@funkit/core": "2.3.8"
|
|
98
98
|
},
|
|
99
99
|
"repository": {
|
|
100
100
|
"type": "git",
|
|
@@ -1,3 +0,0 @@
|
|
|
1
|
-
import type { Address } from 'viem';
|
|
2
|
-
import type { FunkitActiveCheckoutItem } from '~/providers/FunkitCheckoutContext';
|
|
3
|
-
export declare function useRedirectToCheckoutHistory(checkoutItem: FunkitActiveCheckoutItem | null, onClose: () => void): (depositAddress: Address) => void;
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import { HistoryContentPages } from '../../utils/checkoutHistory';
|
|
3
|
-
interface FunCheckoutHistoryModalProps {
|
|
4
|
-
open: boolean;
|
|
5
|
-
onClose: () => void;
|
|
6
|
-
depositAddress: `0x${string}`;
|
|
7
|
-
initialPage: HistoryContentPages;
|
|
8
|
-
}
|
|
9
|
-
export declare function FunCheckoutHistoryModal({ onClose, open, depositAddress, initialPage, }: FunCheckoutHistoryModalProps): React.JSX.Element;
|
|
10
|
-
export {};
|
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
import React, { type ReactNode } from 'react';
|
|
2
|
-
export type DisclaimerComponent = React.FunctionComponent<{
|
|
3
|
-
Text: React.FunctionComponent<{
|
|
4
|
-
children: ReactNode;
|
|
5
|
-
}>;
|
|
6
|
-
Link: React.FunctionComponent<{
|
|
7
|
-
children: ReactNode;
|
|
8
|
-
href: string;
|
|
9
|
-
}>;
|
|
10
|
-
}>;
|
|
11
|
-
export declare const defaultAppInfo: {
|
|
12
|
-
appName: undefined;
|
|
13
|
-
disclaimer: undefined;
|
|
14
|
-
learnMoreUrl: string;
|
|
15
|
-
};
|
|
16
|
-
export declare const AppContext: React.Context<{
|
|
17
|
-
appName?: string;
|
|
18
|
-
learnMoreUrl?: string;
|
|
19
|
-
disclaimer?: DisclaimerComponent;
|
|
20
|
-
}>;
|
|
File without changes
|
|
File without changes
|