@funkit/connect 9.23.2-next.0 → 9.24.0-next.0
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 +10 -1
- package/dist/clients/aave.d.ts +1 -1
- package/dist/clients/chunk-A32VN2DX.js +2382 -0
- package/dist/clients/chunk-GUWXVR5S.js +186 -0
- package/dist/clients/chunk-JBWB54MX.js +69 -0
- package/dist/clients/chunk-NPPIETHZ.js +54 -0
- package/dist/clients/chunk-YYMIRDCQ.js +230 -0
- package/dist/clients/lighter.d.ts +19 -1
- package/dist/clients/lighter.js +7 -2
- package/dist/clients/mallard.d.ts +1 -1
- package/dist/clients/polymarket/PolymarketDepositAccountDropdown.d.ts +1 -1
- package/dist/clients/polymarket/createPolymarketDepositConfig.d.ts +1 -1
- package/dist/clients/polymarket/polymarket.d.ts +2 -2
- package/dist/clients/rolly.d.ts +1 -1
- package/dist/components/ApprovalMethodToggle/ApprovalMethodToggle.d.ts +1 -1
- package/dist/components/Dropdown/ChainDropdown.d.ts +1 -1
- package/dist/components/Dropdown/TokenAndChainDropdown.d.ts +1 -1
- package/dist/components/Dropdown/TokenDropdown.d.ts +1 -1
- package/dist/components/FunAsset/FunAssetItem.d.ts +1 -1
- package/dist/components/FunCheckoutHistory/AddTokenToWalletButton.d.ts +1 -1
- package/dist/components/FunCheckoutHistory/FunDirectExecutionHistoryBottomBar.d.ts +1 -1
- package/dist/components/FunCheckoutHistory/FunDirectExecutionHistoryDetail.d.ts +1 -1
- package/dist/components/FunCheckoutHistory/PendingSuccessScreen.d.ts +2 -2
- package/dist/components/FunCheckoutHistory/YouSendItem.d.ts +1 -1
- package/dist/components/FunNotificationBanner/FunNotificationBannerIcon.d.ts +1 -1
- package/dist/components/FunPayments/FunPaymentMethods.d.ts +1 -1
- package/dist/components/FunSelectBrokerage/FunSelectBrokerage.d.ts +1 -1
- package/dist/components/FunTransactionSummary/DestinationYieldRows.d.ts +1 -1
- package/dist/components/FunTransactionSummary/PaymentAmountSummary.d.ts +3 -3
- package/dist/components/FunTransactionSummary/PaymentFeesSummary.d.ts +2 -2
- package/dist/components/FunTransactionSummary/PaymentFeesSummary.track.d.ts +2 -2
- package/dist/components/FunTransactionSummary/PaymentMethodSummary.d.ts +2 -2
- package/dist/components/FunTransactionSummary/PaymentRouteSummary.d.ts +1 -1
- package/dist/components/ModalHeightAnimationLayer/FunCheckoutModalHeightAnimationWrapper.d.ts +2 -2
- package/dist/components/NewTokenDepositAlert/NewTokenDepositAlert.d.ts +1 -1
- package/dist/components/ReceiveAmount/ReceiveAmount.d.ts +2 -2
- package/dist/components/SourcePaymentMethodItem/SourcePaymentMethodItem.d.ts +1 -1
- package/dist/components/TransactionStatus/AnimatedSpinner/AnimatedSpinner.d.ts +1 -1
- package/dist/components/TransactionStatus/StepSpinner.d.ts +1 -1
- package/dist/components/TransactionStatus/TransactionStatus.d.ts +2 -2
- package/dist/components/TransferTokenDetails/TransferTokenDetails.d.ts +1 -1
- package/dist/consts/customers.d.ts +1 -1
- package/dist/domains/aave.d.ts +1 -1
- package/dist/domains/asset.d.ts +2 -2
- package/dist/domains/checkout.d.ts +1 -1
- package/dist/domains/checkoutErrors.d.ts +2 -2
- package/dist/domains/checkoutRecipient.d.ts +1 -1
- package/dist/domains/clientMetadata.d.ts +1 -1
- package/dist/domains/dynamicRouting.d.ts +1 -1
- package/dist/domains/fees.d.ts +3 -3
- package/dist/domains/paymentMethods.d.ts +1 -1
- package/dist/domains/quote.d.ts +5 -5
- package/dist/domains/quoteMode/exactOut.d.ts +1 -1
- package/dist/domains/quoteMode/resolveQuoteMode.d.ts +1 -1
- package/dist/domains/quoteMode/types.d.ts +2 -2
- package/dist/hooks/queries/useLightningQuote.d.ts +1 -1
- package/dist/hooks/queries/useMeldDefaultCurrency.d.ts +1 -1
- package/dist/hooks/queries/useRecentCheckouts.d.ts +1 -1
- package/dist/hooks/queries/useRecentDeposits.d.ts +1 -1
- package/dist/hooks/queries/useWithdrawalQuote.d.ts +31 -31
- package/dist/hooks/track/useTrack.d.ts +1 -1
- package/dist/hooks/useBluvo.d.ts +3 -3
- package/dist/hooks/useCheckoutDirectExecution.d.ts +3 -3
- package/dist/hooks/useCheckoutDirectExecutionHistory.d.ts +1 -1
- package/dist/hooks/useCheckoutItemDisplay.d.ts +2 -2
- package/dist/hooks/useCheckoutTimeEstimate.d.ts +2 -2
- package/dist/hooks/useCountdown.d.ts +1 -1
- package/dist/hooks/useEnabledTokenTransferChainTokens.d.ts +1 -1
- package/dist/hooks/useExchangeOptions.d.ts +1 -1
- package/dist/hooks/useFrogAccount.d.ts +1 -1
- package/dist/hooks/useIsBlacklisted.d.ts +1 -1
- package/dist/hooks/useIsDynamicRoutingEnabled.d.ts +1 -1
- package/dist/hooks/useMinDeposit.d.ts +1 -1
- package/dist/hooks/useNewTokenBanner.d.ts +1 -1
- package/dist/hooks/useOnNewNotification.d.ts +1 -1
- package/dist/hooks/usePaymentMethodTabs.d.ts +1 -1
- package/dist/hooks/usePaymentSources.d.ts +2 -2
- package/dist/hooks/useRelayBypass.d.ts +1 -1
- package/dist/hooks/useStepQueryReadiness.d.ts +3 -3
- package/dist/hooks/useTokenAndChainDropdown.d.ts +1 -1
- package/dist/hooks/useTokenTransfer.d.ts +1 -1
- package/dist/hooks/useTokenTransferConfig.d.ts +1 -1
- package/dist/hooks/useUserIpInfo.d.ts +1 -1
- package/dist/index.js +11 -4
- package/dist/interfaces/identity.d.ts +1 -1
- package/dist/modals/ChainModal/Chain.d.ts +1 -1
- package/dist/modals/CheckoutModal/Brokerage/BrokerageSuccessModal.d.ts +1 -1
- package/dist/modals/CheckoutModal/Brokerage/BrokerageTwoFA.d.ts +2 -2
- package/dist/modals/CheckoutModal/Brokerage/ConnectExchange.d.ts +2 -2
- package/dist/modals/CheckoutModal/Brokerage/SelectBrokerage.d.ts +2 -2
- package/dist/modals/CheckoutModal/ConfirmationStep/CheckoutPrimaryInfo.d.ts +2 -2
- package/dist/modals/CheckoutModal/ConfirmationStep/ConfirmationStep.d.ts +1 -1
- package/dist/modals/CheckoutModal/ConfirmationStep/DisclaimerText.d.ts +1 -1
- package/dist/modals/CheckoutModal/ConfirmationStep/mapRetryAction.d.ts +1 -1
- package/dist/modals/CheckoutModal/ConfirmationStep/useCheckoutConfirmation.d.ts +1 -1
- package/dist/modals/CheckoutModal/ConfirmationStep/useCheckoutQuote.d.ts +2 -2
- package/dist/modals/CheckoutModal/ConfirmationStep/usePostCheckout.d.ts +2 -2
- package/dist/modals/CheckoutModal/ConfirmationStep/useQuoteRefresh.d.ts +1 -1
- package/dist/modals/CheckoutModal/ConfirmationStep/useSourceAssetConfirm.d.ts +2 -2
- package/dist/modals/CheckoutModal/InputAmount/InputAmount.d.ts +1 -1
- package/dist/modals/CheckoutModal/InputAmount/InputAmountLoaded.d.ts +2 -2
- package/dist/modals/CheckoutModal/InputAmount/state.d.ts +3 -3
- package/dist/modals/CheckoutModal/InputAmount/useAaveNativeSupply.d.ts +3 -3
- package/dist/modals/CheckoutModal/InputAmount/useAmountInput.d.ts +1 -1
- package/dist/modals/CheckoutModal/InputAmount/useAvailableBalanceForCheckout.d.ts +3 -3
- package/dist/modals/CheckoutModal/InputAmount/useCheckoutAmountLimits.d.ts +2 -2
- package/dist/modals/CheckoutModal/InputAmount/useMeld.d.ts +1 -1
- package/dist/modals/CheckoutModal/InputAmount/utils.d.ts +2 -2
- package/dist/modals/CheckoutModal/LightningInvoice/LightningInvoice.d.ts +1 -1
- package/dist/modals/CheckoutModal/LightningInvoice/LightningInvoiceQrCode.d.ts +1 -1
- package/dist/modals/CheckoutModal/MeldCurrencySelect/MeldCurrencySelect.d.ts +1 -1
- package/dist/modals/CheckoutModal/MeldQuotes/MeldQuotes.d.ts +1 -1
- package/dist/modals/CheckoutModal/MeldRedirect/MeldRedirect.d.ts +1 -1
- package/dist/modals/CheckoutModal/SelectAsset/SelectAsset.d.ts +4 -4
- package/dist/modals/CheckoutModal/SelectAsset/SelectAssetInfoSection.d.ts +2 -2
- package/dist/modals/CheckoutModal/SelectAsset/SelectAssetList.d.ts +2 -2
- package/dist/modals/CheckoutModal/SourceChange/ConnectedSource.d.ts +1 -1
- package/dist/modals/CheckoutModal/SourceChange/CryptoCashToggle.d.ts +2 -2
- package/dist/modals/CheckoutModal/SourceChange/SourceChange.d.ts +2 -2
- package/dist/modals/CheckoutModal/SourceChange/useSourceChangeLayout.d.ts +1 -1
- package/dist/modals/CheckoutModal/SwappedIframe/SwappedIframeController.d.ts +2 -2
- package/dist/modals/CheckoutModal/TransferToken/CheckoutNotification.d.ts +1 -1
- package/dist/modals/CheckoutModal/TransferToken/CheckoutNotifications.track.d.ts +1 -1
- package/dist/modals/CheckoutModal/TransferToken/DirectExecutionNotification.d.ts +1 -1
- package/dist/modals/CheckoutModal/TransferToken/TransferToken.d.ts +1 -1
- package/dist/modals/CheckoutModal/TransferToken/types.d.ts +1 -1
- package/dist/modals/CheckoutModal/VirtualFiatAccount/BridgeCustomer.d.ts +2 -2
- package/dist/modals/CheckoutModal/VirtualFiatAccount/BridgeKyc.d.ts +1 -1
- package/dist/modals/CheckoutModal/VirtualFiatAccount/ErrorScreen.d.ts +1 -1
- package/dist/modals/CheckoutModal/VirtualFiatAccount/FiatAccountDetail.d.ts +1 -1
- package/dist/modals/CheckoutModal/VirtualFiatAccount/KycIframe.d.ts +2 -2
- package/dist/modals/CheckoutModal/VirtualFiatAccount/VirtualFiatAccount.d.ts +2 -2
- package/dist/modals/CheckoutModal/Withdrawal/WithdrawalComplete.d.ts +2 -2
- package/dist/modals/CheckoutModal/Withdrawal/WithdrawalEnterAmount.d.ts +2 -2
- package/dist/modals/CheckoutModal/stepTransition.d.ts +5 -5
- package/dist/modals/CheckoutModal/stepTransition.track.d.ts +2 -2
- package/dist/modals/ProfileDetails/FunProfileViews/Home/HomeCheckoutDisplayRow.d.ts +2 -2
- package/dist/modals/ProfileDetails/FunProfileViews/Home/HomeTokenDisplayRow.d.ts +1 -1
- package/dist/modals/ProfileDetails/FunProfileViews/Home/ProfileTitleSection.d.ts +2 -2
- package/dist/modals/ProfileDetails/FunProfileViews/Home/index.d.ts +1 -1
- package/dist/modals/WithdrawalModal/ErrorMessage.d.ts +2 -2
- package/dist/modals/WithdrawalModal/LighterWithdrawal.d.ts +4 -4
- package/dist/modals/WithdrawalModal/RecipientAddress.d.ts +1 -1
- package/dist/modals/WithdrawalModal/WithdrawAmountInput.d.ts +1 -1
- package/dist/modals/WithdrawalModal/WithdrawalCallbackSuccess.d.ts +1 -1
- package/dist/modals/WithdrawalModal/WithdrawalContent.d.ts +1 -1
- package/dist/modals/WithdrawalModal/WithdrawalModal.d.ts +1 -1
- package/dist/modals/WithdrawalModal/WithdrawalTypeSelect.d.ts +1 -1
- package/dist/modals/WithdrawalModal/useWithdrawal.d.ts +3 -3
- package/dist/providers/FunkitBrokerageProvider.d.ts +2 -2
- package/dist/providers/FunkitCheckoutContext/index.d.ts +1 -1
- package/dist/providers/FunkitCheckoutContext/track.d.ts +4 -4
- package/dist/providers/FunkitCheckoutContext/types.d.ts +16 -0
- package/dist/providers/FunkitConfigContext.d.ts +3 -3
- package/dist/providers/FunkitHistoryContext.d.ts +2 -2
- package/dist/providers/FunkitProvider.d.ts +2 -2
- package/dist/providers/FunkitQuoteContext.track.d.ts +4 -4
- package/dist/providers/GeneralWalletProvider.d.ts +2 -2
- package/dist/providers/QuoteModeContext.d.ts +1 -1
- package/dist/providers/SwappedProvider.d.ts +1 -1
- package/dist/utils/assets.d.ts +1 -1
- package/dist/utils/bluvo.d.ts +3 -3
- package/dist/utils/checkout.d.ts +3 -3
- package/dist/utils/depositCutoff.d.ts +1 -1
- package/dist/utils/funkitProvider.d.ts +1 -1
- package/dist/utils/payment.d.ts +1 -1
- package/dist/utils/polygonRpcCheck.d.ts +1 -1
- package/dist/utils/purifyCheckoutHistoryItem.d.ts +1 -1
- package/dist/utils/swapped.d.ts +1 -1
- package/dist/utils/withdrawal.d.ts +1 -1
- package/dist/wallets/walletConnectors/index.js +58 -58
- package/package.json +4 -4
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import type { FunkitWithdrawalConfig, MultiMethodWithdrawalConfig } from '
|
|
2
|
+
import type { FunkitWithdrawalConfig, MultiMethodWithdrawalConfig } from '../../providers/FunkitCheckoutContext';
|
|
3
3
|
export interface SourceTokenOption {
|
|
4
4
|
symbol: string;
|
|
5
5
|
/** Display label (may differ from symbol, e.g. "USDC (Perps)") */
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import type { Hex } from 'viem';
|
|
3
|
-
import type { CustomWithdrawalConfig, FunkitActiveWithdrawalItem, FunkitCheckoutConfig, WalletWithdrawalConfig } from '
|
|
3
|
+
import type { CustomWithdrawalConfig, FunkitActiveWithdrawalItem, FunkitCheckoutConfig, WalletWithdrawalConfig } from '../../providers/FunkitCheckoutContext';
|
|
4
4
|
import { type WithdrawalFormData } from './useWithdrawal';
|
|
5
5
|
/**
|
|
6
6
|
* WithdrawalContent only operates on concrete single-method withdrawal configs.
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import type { FunkitWithdrawalConfig } from '
|
|
2
|
+
import type { FunkitWithdrawalConfig } from '../../providers/FunkitCheckoutContext';
|
|
3
3
|
export declare const WITHDRAWAL_MODAL_CONTENT_ID = "withdrawal-modal-content";
|
|
4
4
|
export interface WithdrawalModalProps {
|
|
5
5
|
open: boolean;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import type { WithdrawalMethodOption } from '
|
|
2
|
+
import type { WithdrawalMethodOption } from '../../providers/FunkitCheckoutContext/types';
|
|
3
3
|
interface WithdrawalTypeSelectProps {
|
|
4
4
|
/** Section label shown above the list (e.g. "Crypto"). */
|
|
5
5
|
sectionTitle?: string;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import type { Address, Hex } from 'viem';
|
|
2
|
-
import { type CheckoutConfirmationError } from '
|
|
3
|
-
import type { FunkitCheckoutQuoteResult } from '
|
|
4
|
-
import { type FunkitActiveWithdrawalItem, type FunkitWithdrawalConfig } from '
|
|
2
|
+
import { type CheckoutConfirmationError } from '../../domains/checkoutErrors';
|
|
3
|
+
import type { FunkitCheckoutQuoteResult } from '../../domains/quote';
|
|
4
|
+
import { type FunkitActiveWithdrawalItem, type FunkitWithdrawalConfig } from '../../providers/FunkitCheckoutContext';
|
|
5
5
|
interface UseWithdrawalResult {
|
|
6
6
|
handleWithdrawal: (withdrawal: WithdrawalFormData) => Promise<void>;
|
|
7
7
|
isWithdrawing: boolean;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { type UseBluvoFlowHook } from '@bluvo/react';
|
|
2
2
|
import React, { type ReactNode } from 'react';
|
|
3
|
-
import { type BluvoBrokerageMinMax, type BluvoExchangeType } from '
|
|
4
|
-
import type { BrokerageAssetHoldingsItem } from '
|
|
3
|
+
import { type BluvoBrokerageMinMax, type BluvoExchangeType } from '../consts/bluvo';
|
|
4
|
+
import type { BrokerageAssetHoldingsItem } from '../domains/wallet';
|
|
5
5
|
type BluvoLocalStorageData = Partial<Record<BluvoExchangeType, string>>;
|
|
6
6
|
interface FunkitBrokerageContextProps {
|
|
7
7
|
bluvoClient: UseBluvoFlowHook;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import React, { type ReactNode } from 'react';
|
|
2
2
|
import type { Address } from 'viem';
|
|
3
|
-
import { type ApplyDynamicRoutingPath } from '
|
|
3
|
+
import { type ApplyDynamicRoutingPath } from '../../domains/dynamicRouting';
|
|
4
4
|
import { type PaymentMethodInfo } from '../../domains/paymentMethods';
|
|
5
5
|
import type { AssetHoldingsItem } from '../../utils/assets';
|
|
6
6
|
import type { WithdrawalClient, WithdrawalTransaction } from '../../wallets/Wallet';
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import type { RelayTxHash, RelayVmType } from '@funkit/fun-relay';
|
|
2
|
-
import type { FunkitCheckoutQuoteResult } from '
|
|
3
|
-
import { CheckoutModalEvent } from '
|
|
4
|
-
import type { WithdrawModalEvent } from '
|
|
5
|
-
import type { TrackEventData } from '
|
|
2
|
+
import type { FunkitCheckoutQuoteResult } from '../../domains/quote';
|
|
3
|
+
import { CheckoutModalEvent } from '../../hooks/track/CheckoutModalEvent';
|
|
4
|
+
import type { WithdrawModalEvent } from '../../hooks/track/WithdrawModalEvent';
|
|
5
|
+
import type { TrackEventData } from '../../hooks/track/useTrack';
|
|
6
6
|
import type { FunkitActiveCheckoutItem, FunkitActiveWithdrawalItem } from './index';
|
|
7
7
|
export declare const trackEventFromActiveItem: (activeItem: FunkitActiveCheckoutItem | FunkitActiveWithdrawalItem, eventName: CheckoutModalEvent | WithdrawModalEvent) => TrackEventData;
|
|
8
8
|
export declare const trackEventFromDirectExecutionConfirmed: ({ txHash, checkoutItem, latestQuote, }: {
|
|
@@ -203,6 +203,22 @@ export interface WithdrawalConfigBase {
|
|
|
203
203
|
* stays live without triggering unnecessary re-renders.
|
|
204
204
|
*/
|
|
205
205
|
withdrawalSourceTokenBalance?: () => string | number;
|
|
206
|
+
/**
|
|
207
|
+
* Optional async hook fired the moment the user commits to the withdrawal —
|
|
208
|
+
* after they tap the withdraw CTA but **before** the SDK fetches any nonce,
|
|
209
|
+
* prompts the wallet to sign, or submits the transaction. It is awaited, so
|
|
210
|
+
* async work completes before signing begins.
|
|
211
|
+
*
|
|
212
|
+
* The motivating case is venues where automated activity shares the signing
|
|
213
|
+
* account: cancelling in-flight strategies here guarantees the withdrawal's
|
|
214
|
+
* signing nonce is still valid by the time the wallet prompt fires.
|
|
215
|
+
*
|
|
216
|
+
* Throw to abort the withdrawal — the thrown error message is surfaced to the
|
|
217
|
+
* user verbatim in the standard error UI, and no nonce is consumed. Runs on
|
|
218
|
+
* every withdrawal method and before
|
|
219
|
+
* {@link WalletWithdrawalConfig['preWithdrawalAction']}.
|
|
220
|
+
*/
|
|
221
|
+
onBeforeSign?: () => Promise<void> | void;
|
|
206
222
|
}
|
|
207
223
|
export interface WalletWithdrawalConfig extends WithdrawalConfigBase {
|
|
208
224
|
/** Wallet instance used to execute the quote */
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { type ComponentType, type JSX, type ReactNode } from 'react';
|
|
2
|
-
import type { BluvoExchangeType } from '
|
|
3
|
-
import type { PaymentMethod } from '
|
|
4
|
-
import type { SourceChangeTopComponentProps } from '
|
|
2
|
+
import type { BluvoExchangeType } from '../consts/bluvo';
|
|
3
|
+
import type { PaymentMethod } from '../domains/paymentMethods';
|
|
4
|
+
import type { SourceChangeTopComponentProps } from '../modals/CheckoutModal/stepTransition';
|
|
5
5
|
export interface FunkitTextCustomizationsConfig {
|
|
6
6
|
virtualFiat: string;
|
|
7
7
|
brokerageOrExchange: string;
|
|
@@ -3,8 +3,8 @@ import React, { type ReactNode } from 'react';
|
|
|
3
3
|
import type { Address, Hex } from 'viem';
|
|
4
4
|
import { type MergedCheckoutHistoryItem } from '../utils/checkout';
|
|
5
5
|
import { type PurifiedCheckoutHistoryItem } from '../utils/purifyCheckoutHistoryItem';
|
|
6
|
-
export type { HistoricalCheckoutItem, ServerCheckoutConfig, } from '
|
|
7
|
-
export type { FunkitCheckoutQuoteResult } from '
|
|
6
|
+
export type { HistoricalCheckoutItem, ServerCheckoutConfig, } from '../domains/clientMetadata';
|
|
7
|
+
export type { FunkitCheckoutQuoteResult } from '../domains/quote';
|
|
8
8
|
interface FunkitCheckoutHistoryContextInterface {
|
|
9
9
|
checkoutHistoryList: MergedCheckoutHistoryItem[];
|
|
10
10
|
isCheckoutHistoryInited: boolean;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { type QueryClient } from '@tanstack/react-query';
|
|
2
2
|
import React, { type ReactNode } from 'react';
|
|
3
|
-
import type { Chain } from '
|
|
4
|
-
import type { Locale } from '
|
|
3
|
+
import type { Chain } from '../wagmi/chains';
|
|
4
|
+
import type { Locale } from '../locales';
|
|
5
5
|
import { type CreateFunkitWagmiConfigParameters } from '../config/getDefaultConfig';
|
|
6
6
|
import { type AvatarComponent } from './AvatarContext';
|
|
7
7
|
import { type FunkitConfig } from './FunkitConfigContext';
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import type { QuoteMode } from '
|
|
2
|
-
import type { CheckoutModalEvent } from '
|
|
3
|
-
import type { WithdrawModalEvent } from '
|
|
4
|
-
import type { TrackEventData } from '
|
|
1
|
+
import type { QuoteMode } from '../domains/quoteMode';
|
|
2
|
+
import type { CheckoutModalEvent } from '../hooks/track/CheckoutModalEvent';
|
|
3
|
+
import type { WithdrawModalEvent } from '../hooks/track/WithdrawModalEvent';
|
|
4
|
+
import type { TrackEventData } from '../hooks/track/useTrack';
|
|
5
5
|
import type { FunkitActiveCheckoutItem } from './FunkitCheckoutContext';
|
|
6
6
|
import type { FunkitCheckoutQuoteResult } from './FunkitHistoryContext';
|
|
7
7
|
export declare const trackEventFromBaseQuote: (checkoutItem: FunkitActiveCheckoutItem, eventName: CheckoutModalEvent | WithdrawModalEvent, quoteMode?: QuoteMode) => TrackEventData;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import type { AssetBalanceInfo } from '@funkit/api-base';
|
|
2
2
|
import React, { type ReactNode } from 'react';
|
|
3
3
|
import type { Address } from 'viem';
|
|
4
|
-
import type { IdentityProvider } from '
|
|
5
|
-
import { type UseDisconnectReturnType, type UseReconnectReturnType } from '
|
|
4
|
+
import type { IdentityProvider } from '../interfaces/identity';
|
|
5
|
+
import { type UseDisconnectReturnType, type UseReconnectReturnType } from '../wagmi/hooks';
|
|
6
6
|
import { type FunkitUserInfo } from '../consts/funkit';
|
|
7
7
|
import { LoginType } from '../utils/userInfo';
|
|
8
8
|
/** AssetBalanceInfo with known price and totalUsdValue */
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React, { type ReactNode } from 'react';
|
|
2
|
-
import { type QuoteBuilder } from '
|
|
2
|
+
import { type QuoteBuilder } from '../domains/quoteMode';
|
|
3
3
|
export declare function QuoteModeProvider({ children }: {
|
|
4
4
|
children: ReactNode;
|
|
5
5
|
}): React.JSX.Element;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import type { FormOfPaymentType } from '@funkit/api-base';
|
|
2
2
|
import { type SwappedTransport } from '@funkit/connect-core';
|
|
3
3
|
import React from 'react';
|
|
4
|
-
import { type SwappedTheme } from '
|
|
4
|
+
import { type SwappedTheme } from '../utils/swapped';
|
|
5
5
|
interface SwappedContextValue {
|
|
6
6
|
iframeUrl: string | null;
|
|
7
7
|
isSwappedReady: boolean;
|
package/dist/utils/assets.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import type { DynamicTargetAssetCandidate, FunkitCheckoutConfig } from '../providers/FunkitCheckoutContext';
|
|
2
|
-
export type { AssetHoldingsItem, AssetHoldingsMap, KnownAssetHoldingsItem, } from '
|
|
2
|
+
export type { AssetHoldingsItem, AssetHoldingsMap, KnownAssetHoldingsItem, } from '../domains/wallet';
|
|
3
3
|
export declare const getNormalizedTokenBalance: (tokenBalance: bigint | number | string, decimals: number) => number;
|
|
4
4
|
export declare const getDefaultDynamicTargetAsset: (checkoutConfig: FunkitCheckoutConfig | undefined) => DynamicTargetAssetCandidate;
|
package/dist/utils/bluvo.d.ts
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import type { WalletwithdrawbalancebalanceResponse } from '@bluvo/sdk-ts';
|
|
2
2
|
type WithdrawableBalance = WalletwithdrawbalancebalanceResponse['balances'][number];
|
|
3
3
|
import { type BluvoExecuteWithdrawalResponse, BluvoWithdrawalError } from '@funkit/api-base';
|
|
4
|
-
import type { BluvoExchangeType } from '
|
|
5
|
-
import type { AssetHoldingsItem, AssetHoldingsMap, BrokerageAssetHoldingsItem } from '
|
|
6
|
-
import { type MinTransferConfig } from '
|
|
4
|
+
import type { BluvoExchangeType } from '../consts/bluvo';
|
|
5
|
+
import type { AssetHoldingsItem, AssetHoldingsMap, BrokerageAssetHoldingsItem } from '../domains/wallet';
|
|
6
|
+
import { type MinTransferConfig } from '../hooks/useTokenTransfer';
|
|
7
7
|
export declare const isBrokerageAsset: (asset: AssetHoldingsItem) => asset is BrokerageAssetHoldingsItem & {
|
|
8
8
|
usdAmount: number;
|
|
9
9
|
};
|
package/dist/utils/checkout.d.ts
CHANGED
|
@@ -2,9 +2,9 @@ export { isCheckoutHistoryDirectExecution, isCheckoutValid, type MergedCheckoutH
|
|
|
2
2
|
import { type ApiFunkitCheckoutQuoteResult, type CheckoutQuoteResponse } from '@funkit/utils';
|
|
3
3
|
import type { Dnum } from 'dnum';
|
|
4
4
|
import { type Address } from 'viem';
|
|
5
|
-
import type { ServerCheckoutConfig } from '
|
|
6
|
-
import type { FunkitCheckoutQuoteResult } from '
|
|
7
|
-
import type { Config, UseConfigReturnType } from '
|
|
5
|
+
import type { ServerCheckoutConfig } from '../domains/clientMetadata';
|
|
6
|
+
import type { FunkitCheckoutQuoteResult } from '../domains/quote';
|
|
7
|
+
import type { Config, UseConfigReturnType } from '../wagmi/hooks';
|
|
8
8
|
import { type FunkitCheckoutActionParams, type FunkitCheckoutConfig } from '../providers/FunkitCheckoutContext';
|
|
9
9
|
export declare const MOONPAY_TIME_ESTIMATE_MS = 120000;
|
|
10
10
|
export declare const BROKERAGE_TIME_ESTIMATE_MS = 0;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { CheckoutQuoteResponse } from '@funkit/utils';
|
|
2
|
-
import type { FunkitCheckoutConfig } from '
|
|
2
|
+
import type { FunkitCheckoutConfig } from '../providers/FunkitCheckoutContext';
|
|
3
3
|
export declare const DEFAULT_TX_DELAYED_CUTOFF = 60;
|
|
4
4
|
/**
|
|
5
5
|
* Returns the delayed auto trigger cutoff (in seconds) for slow deposits.
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { FunkitCheckoutConfig } from '
|
|
1
|
+
import type { FunkitCheckoutConfig } from '../providers/FunkitCheckoutContext';
|
|
2
2
|
import type { FunkitProviderProps } from '../providers/FunkitProvider';
|
|
3
3
|
export declare function getInitialChainIdFromFunkitProviderProps(props: FunkitProviderProps): number | undefined;
|
|
4
4
|
export declare function generateSyntheticUserId(apiKey: string, externalUserId: string): string;
|
package/dist/utils/payment.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { LoginType } from '
|
|
1
|
+
import { LoginType } from '../providers/GeneralWalletProvider';
|
|
2
2
|
import { type PaymentMethodInfo } from '../domains/paymentMethods';
|
|
3
3
|
/**
|
|
4
4
|
* Generate a string for backend to indicate the source of a checkout funds
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { type CheckoutHistoryItem, type CheckoutState } from '@funkit/api-base';
|
|
2
2
|
import type { ApiFunkitCheckoutActionParams } from '@funkit/utils';
|
|
3
3
|
import type { Address, Hex } from 'viem';
|
|
4
|
-
import type { MergedMultiStepDirectExecution } from '
|
|
4
|
+
import type { MergedMultiStepDirectExecution } from '../domains/checkoutNotifications';
|
|
5
5
|
export type PurifiedCheckoutHistoryItem = {
|
|
6
6
|
depositAddr?: Address;
|
|
7
7
|
directExecution: boolean;
|
package/dist/utils/swapped.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { SwappedTheme } from '@funkit/connect-core';
|
|
2
|
-
import type { ThemeVars } from '
|
|
2
|
+
import type { ThemeVars } from '../css/sprinkles.css';
|
|
3
3
|
export { getSavedFormOfPaymentDisplayName, getSavedFormOfPaymentIcon, getSwappedIcon, getSwappedOrigin, isSavedFormOfPaymentType, isSwappedOrigin, SWAPPED_CARD_BRANDS, } from '@funkit/connect-core';
|
|
4
4
|
export type { SwappedTheme };
|
|
5
5
|
export declare function resolveCssValue(value: string): string;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { CustomWithdrawalConfig, FunkitWithdrawalConfig, MultiMethodWithdrawalConfig, WalletWithdrawalConfig } from '
|
|
1
|
+
import type { CustomWithdrawalConfig, FunkitWithdrawalConfig, MultiMethodWithdrawalConfig, WalletWithdrawalConfig } from '../providers/FunkitCheckoutContext';
|
|
2
2
|
/**
|
|
3
3
|
* Type guard to check if withdrawal config uses wallet-based flow
|
|
4
4
|
*/
|
|
@@ -3,56 +3,59 @@ import {
|
|
|
3
3
|
zerionWallet
|
|
4
4
|
} from "./chunk-RVOY537T.js";
|
|
5
5
|
import {
|
|
6
|
-
|
|
7
|
-
} from "./chunk-
|
|
6
|
+
xdefiWallet
|
|
7
|
+
} from "./chunk-JN5I3DNC.js";
|
|
8
|
+
import {
|
|
9
|
+
tahoWallet
|
|
10
|
+
} from "./chunk-7ZYCBDQ4.js";
|
|
8
11
|
import {
|
|
9
12
|
tokenPocketWallet
|
|
10
13
|
} from "./chunk-HTHAK6XB.js";
|
|
11
|
-
import {
|
|
12
|
-
tokenaryWallet
|
|
13
|
-
} from "./chunk-VH3THHJY.js";
|
|
14
|
-
import {
|
|
15
|
-
safeWallet
|
|
16
|
-
} from "./chunk-RCY66YHF.js";
|
|
17
|
-
import {
|
|
18
|
-
rainbowWallet
|
|
19
|
-
} from "./chunk-2VP2F6EK.js";
|
|
20
14
|
import {
|
|
21
15
|
trustWallet
|
|
22
16
|
} from "./chunk-ZNX4EMPB.js";
|
|
17
|
+
import {
|
|
18
|
+
talismanWallet
|
|
19
|
+
} from "./chunk-4DCO3TGL.js";
|
|
23
20
|
import {
|
|
24
21
|
uniswapWallet
|
|
25
22
|
} from "./chunk-Z3PPW6NC.js";
|
|
23
|
+
import {
|
|
24
|
+
tokenaryWallet
|
|
25
|
+
} from "./chunk-VH3THHJY.js";
|
|
26
26
|
import {
|
|
27
27
|
walletConnectWallet
|
|
28
28
|
} from "./chunk-3FCWJRI4.js";
|
|
29
29
|
import {
|
|
30
|
-
|
|
31
|
-
} from "./chunk-
|
|
32
|
-
import {
|
|
33
|
-
safeheronWallet
|
|
34
|
-
} from "./chunk-76S7R2ND.js";
|
|
35
|
-
import {
|
|
36
|
-
safepalWallet
|
|
37
|
-
} from "./chunk-VTM6EECM.js";
|
|
38
|
-
import {
|
|
39
|
-
tahoWallet
|
|
40
|
-
} from "./chunk-7ZYCBDQ4.js";
|
|
41
|
-
import {
|
|
42
|
-
talismanWallet
|
|
43
|
-
} from "./chunk-4DCO3TGL.js";
|
|
30
|
+
zealWallet
|
|
31
|
+
} from "./chunk-52QXXLDS.js";
|
|
44
32
|
import {
|
|
45
|
-
|
|
46
|
-
} from "./chunk-
|
|
33
|
+
rainbowWallet
|
|
34
|
+
} from "./chunk-2VP2F6EK.js";
|
|
47
35
|
import {
|
|
48
36
|
rabbyWallet
|
|
49
37
|
} from "./chunk-RB66PKPA.js";
|
|
50
38
|
import {
|
|
51
39
|
roninWallet
|
|
52
40
|
} from "./chunk-VAPGUPHO.js";
|
|
41
|
+
import {
|
|
42
|
+
ramperWallet
|
|
43
|
+
} from "./chunk-OQB55QXP.js";
|
|
44
|
+
import {
|
|
45
|
+
safeWallet
|
|
46
|
+
} from "./chunk-RCY66YHF.js";
|
|
47
|
+
import {
|
|
48
|
+
safeheronWallet
|
|
49
|
+
} from "./chunk-76S7R2ND.js";
|
|
50
|
+
import {
|
|
51
|
+
safepalWallet
|
|
52
|
+
} from "./chunk-VTM6EECM.js";
|
|
53
53
|
import {
|
|
54
54
|
subWallet
|
|
55
55
|
} from "./chunk-X6CGV36L.js";
|
|
56
|
+
import {
|
|
57
|
+
metaMaskWallet
|
|
58
|
+
} from "./chunk-CCQV2ZET.js";
|
|
56
59
|
import {
|
|
57
60
|
mewWallet
|
|
58
61
|
} from "./chunk-MQM45ADF.js";
|
|
@@ -62,21 +65,21 @@ import {
|
|
|
62
65
|
import {
|
|
63
66
|
okxWallet
|
|
64
67
|
} from "./chunk-STVVP43G.js";
|
|
65
|
-
import {
|
|
66
|
-
omniWallet
|
|
67
|
-
} from "./chunk-2CX7LX4J.js";
|
|
68
68
|
import {
|
|
69
69
|
oneInchWallet
|
|
70
70
|
} from "./chunk-QG6ZHI7B.js";
|
|
71
71
|
import {
|
|
72
|
-
|
|
73
|
-
} from "./chunk-
|
|
72
|
+
omniWallet
|
|
73
|
+
} from "./chunk-2CX7LX4J.js";
|
|
74
74
|
import {
|
|
75
75
|
phantomWallet
|
|
76
76
|
} from "./chunk-QY53O7WG.js";
|
|
77
77
|
import {
|
|
78
|
-
|
|
79
|
-
} from "./chunk-
|
|
78
|
+
oneKeyWallet
|
|
79
|
+
} from "./chunk-WVT6BBJH.js";
|
|
80
|
+
import {
|
|
81
|
+
desigWallet
|
|
82
|
+
} from "./chunk-FW3WZETT.js";
|
|
80
83
|
import {
|
|
81
84
|
frameWallet
|
|
82
85
|
} from "./chunk-BU3ZAT5X.js";
|
|
@@ -90,63 +93,60 @@ import {
|
|
|
90
93
|
injectedWallet
|
|
91
94
|
} from "./chunk-T6LGKC3F.js";
|
|
92
95
|
import {
|
|
93
|
-
|
|
94
|
-
} from "./chunk-
|
|
96
|
+
kresusWallet
|
|
97
|
+
} from "./chunk-RICTB3FA.js";
|
|
95
98
|
import {
|
|
96
99
|
imTokenWallet
|
|
97
100
|
} from "./chunk-WNAGGFMG.js";
|
|
98
101
|
import {
|
|
99
|
-
|
|
100
|
-
} from "./chunk-
|
|
102
|
+
ledgerWallet
|
|
103
|
+
} from "./chunk-RPV27V2Y.js";
|
|
101
104
|
import {
|
|
102
|
-
|
|
103
|
-
} from "./chunk-
|
|
105
|
+
braveWallet
|
|
106
|
+
} from "./chunk-DS73TZ6O.js";
|
|
104
107
|
import {
|
|
105
108
|
clvWallet
|
|
106
109
|
} from "./chunk-UK7C2JXW.js";
|
|
107
|
-
import {
|
|
108
|
-
coinbaseWallet
|
|
109
|
-
} from "./chunk-2DLDAZRH.js";
|
|
110
110
|
import {
|
|
111
111
|
coin98Wallet
|
|
112
112
|
} from "./chunk-6BW3HLBG.js";
|
|
113
113
|
import {
|
|
114
|
-
|
|
115
|
-
} from "./chunk-
|
|
116
|
-
import {
|
|
117
|
-
bybitWallet
|
|
118
|
-
} from "./chunk-F5XEEVG6.js";
|
|
114
|
+
coinbaseWallet
|
|
115
|
+
} from "./chunk-2DLDAZRH.js";
|
|
119
116
|
import {
|
|
120
117
|
dawnWallet
|
|
121
118
|
} from "./chunk-G2PHTVL6.js";
|
|
122
119
|
import {
|
|
123
|
-
|
|
124
|
-
} from "./chunk-
|
|
120
|
+
coreWallet
|
|
121
|
+
} from "./chunk-RB3HR4R2.js";
|
|
122
|
+
import {
|
|
123
|
+
foxWallet
|
|
124
|
+
} from "./chunk-MIQTHJ6X.js";
|
|
125
125
|
import {
|
|
126
126
|
enkryptWallet
|
|
127
127
|
} from "./chunk-HBQK5RD5.js";
|
|
128
|
-
import {
|
|
129
|
-
argentWallet
|
|
130
|
-
} from "./chunk-NTMBEOR2.js";
|
|
131
128
|
import {
|
|
132
129
|
bifrostWallet
|
|
133
130
|
} from "./chunk-4T6ZSRJF.js";
|
|
131
|
+
import {
|
|
132
|
+
argentWallet
|
|
133
|
+
} from "./chunk-NTMBEOR2.js";
|
|
134
134
|
import {
|
|
135
135
|
bitgetWallet
|
|
136
136
|
} from "./chunk-CPI4TD43.js";
|
|
137
137
|
import {
|
|
138
138
|
bitskiWallet
|
|
139
139
|
} from "./chunk-7HRFUZFX.js";
|
|
140
|
+
import {
|
|
141
|
+
bitverseWallet
|
|
142
|
+
} from "./chunk-NSK6A7TI.js";
|
|
140
143
|
import {
|
|
141
144
|
bloomWallet
|
|
142
145
|
} from "./chunk-PJ7Y57EH.js";
|
|
143
146
|
import {
|
|
144
|
-
|
|
145
|
-
} from "./chunk-
|
|
147
|
+
bybitWallet
|
|
148
|
+
} from "./chunk-F5XEEVG6.js";
|
|
146
149
|
import "./chunk-OLZ7626J.js";
|
|
147
|
-
import {
|
|
148
|
-
bitverseWallet
|
|
149
|
-
} from "./chunk-NSK6A7TI.js";
|
|
150
150
|
import "./chunk-N4IJLYFY.js";
|
|
151
151
|
import "./chunk-IGKXZBTA.js";
|
|
152
152
|
export {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@funkit/connect",
|
|
3
|
-
"version": "9.
|
|
3
|
+
"version": "9.24.0-next.0",
|
|
4
4
|
"description": "Funkit Connect SDK elevates DeFi apps via web2 sign-ins and one-click checkouts.",
|
|
5
5
|
"files": [
|
|
6
6
|
"dist",
|
|
@@ -112,10 +112,10 @@
|
|
|
112
112
|
"use-debounce": "^10.0.5",
|
|
113
113
|
"uuid": "^11.1.1",
|
|
114
114
|
"@funkit/api-base": "4.5.1",
|
|
115
|
-
"@funkit/
|
|
116
|
-
"@funkit/connect-core": "1.1.0",
|
|
115
|
+
"@funkit/fun-relay": "2.8.3",
|
|
117
116
|
"@funkit/utils": "3.1.0",
|
|
118
|
-
"@funkit/
|
|
117
|
+
"@funkit/connect-core": "1.1.0",
|
|
118
|
+
"@funkit/chains": "2.1.1"
|
|
119
119
|
},
|
|
120
120
|
"repository": {
|
|
121
121
|
"type": "git",
|