@funkit/connect-rn 6.1.0 → 7.0.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 +120 -0
- package/README.md +79 -4
- package/dist/{chunk-MKOPF7Y5.js → chunk-HRJNTNCV.js} +2 -2
- package/dist/{chunk-HMAJXI66.js → chunk-P3OLDPDC.js} +354 -49
- package/dist/chunk-P3OLDPDC.js.map +7 -0
- package/dist/clients/lighter.js +1 -1
- package/dist/clients/nado/useNadoWithdrawal.d.ts.map +1 -1
- package/dist/clients/nado.js +3 -3
- package/dist/clients/nado.js.map +2 -2
- package/dist/index.d.ts +7 -2
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +5992 -2320
- package/dist/index.js.map +4 -4
- package/dist/src/components/LoadingSpinner.d.ts.map +1 -1
- package/dist/src/components/PillButton.d.ts.map +1 -1
- package/dist/src/components/v2/QuickAmountsRow.d.ts.map +1 -1
- package/dist/src/fiat/FiatChoiceField.d.ts +7 -1
- package/dist/src/fiat/FiatChoiceField.d.ts.map +1 -1
- package/dist/src/fiat/FiatCountrySheet.d.ts +11 -0
- package/dist/src/fiat/FiatCountrySheet.d.ts.map +1 -1
- package/dist/src/fiat/FiatFailureBanner.d.ts +14 -0
- package/dist/src/fiat/FiatFailureBanner.d.ts.map +1 -0
- package/dist/src/fiat/FiatFormScreen.d.ts +11 -1
- package/dist/src/fiat/FiatFormScreen.d.ts.map +1 -1
- package/dist/src/fiat/FiatIdentityStep.d.ts.map +1 -1
- package/dist/src/fiat/FiatKycFieldControl.d.ts +9 -2
- package/dist/src/fiat/FiatKycFieldControl.d.ts.map +1 -1
- package/dist/src/fiat/FiatKycOptionsScreen.d.ts.map +1 -1
- package/dist/src/fiat/FiatKycOutcomeScreen.d.ts +15 -2
- package/dist/src/fiat/FiatKycOutcomeScreen.d.ts.map +1 -1
- package/dist/src/fiat/FiatKycPhoneField.d.ts +21 -0
- package/dist/src/fiat/FiatKycPhoneField.d.ts.map +1 -0
- package/dist/src/fiat/FiatReceipt.d.ts +21 -0
- package/dist/src/fiat/FiatReceipt.d.ts.map +1 -0
- package/dist/src/fiat/FiatRegionUnsupportedScreen.d.ts +11 -0
- package/dist/src/fiat/FiatRegionUnsupportedScreen.d.ts.map +1 -0
- package/dist/src/fiat/FiatStatusScreen.d.ts.map +1 -1
- package/dist/src/fiat/FiatSubmissionIndicator.d.ts.map +1 -1
- package/dist/src/fiat/FiatTermsNotice.d.ts +3 -1
- package/dist/src/fiat/FiatTermsNotice.d.ts.map +1 -1
- package/dist/src/fiat/KycGlassBackdrop.d.ts.map +1 -1
- package/dist/src/fiat/ScreenSurfaceCover.d.ts +11 -0
- package/dist/src/fiat/ScreenSurfaceCover.d.ts.map +1 -0
- package/dist/src/fiat/SurfaceSlot.d.ts +12 -1
- package/dist/src/fiat/SurfaceSlot.d.ts.map +1 -1
- package/dist/src/fiat/depositOutcome.d.ts +33 -0
- package/dist/src/fiat/depositOutcome.d.ts.map +1 -0
- package/dist/src/fiat/fieldAutofill.d.ts.map +1 -1
- package/dist/src/fiat/formLayout.d.ts +12 -5
- package/dist/src/fiat/formLayout.d.ts.map +1 -1
- package/dist/src/fiat/formScreenProps.d.ts +4 -2
- package/dist/src/fiat/formScreenProps.d.ts.map +1 -1
- package/dist/src/fiat/kycFormPosition.d.ts +25 -1
- package/dist/src/fiat/kycFormPosition.d.ts.map +1 -1
- package/dist/src/fiat/kycFormState.d.ts +10 -0
- package/dist/src/fiat/kycFormState.d.ts.map +1 -1
- package/dist/src/fiat/kycUnavailableAlert.d.ts +21 -1
- package/dist/src/fiat/kycUnavailableAlert.d.ts.map +1 -1
- package/dist/src/fiat/methodName.d.ts +8 -0
- package/dist/src/fiat/methodName.d.ts.map +1 -0
- package/dist/src/fiat/otpScreenProps.d.ts +5 -0
- package/dist/src/fiat/otpScreenProps.d.ts.map +1 -1
- package/dist/src/fiat/providerFailover.d.ts +12 -0
- package/dist/src/fiat/providerFailover.d.ts.map +1 -0
- package/dist/src/fiat/providers/CoinbaseCheckoutSurface.d.ts +4 -2
- package/dist/src/fiat/providers/CoinbaseCheckoutSurface.d.ts.map +1 -1
- package/dist/src/fiat/providers/StripeSessionAuthController.d.ts +29 -0
- package/dist/src/fiat/providers/StripeSessionAuthController.d.ts.map +1 -0
- package/dist/src/fiat/providers/StripeSessionAuthScreen.d.ts +10 -0
- package/dist/src/fiat/providers/StripeSessionAuthScreen.d.ts.map +1 -0
- package/dist/src/fiat/providers/adapter.d.ts +6 -0
- package/dist/src/fiat/providers/adapter.d.ts.map +1 -1
- package/dist/src/fiat/providers/coinbaseOnrampEvents.d.ts +7 -3
- package/dist/src/fiat/providers/coinbaseOnrampEvents.d.ts.map +1 -1
- package/dist/src/fiat/providers/describeThrown.d.ts +14 -0
- package/dist/src/fiat/providers/describeThrown.d.ts.map +1 -0
- package/dist/src/fiat/providers/moonpay.d.ts.map +1 -1
- package/dist/src/fiat/providers/moonpayTrace.d.ts +25 -0
- package/dist/src/fiat/providers/moonpayTrace.d.ts.map +1 -0
- package/dist/src/fiat/providers/stripeAccountCreation.d.ts +12 -0
- package/dist/src/fiat/providers/stripeAccountCreation.d.ts.map +1 -0
- package/dist/src/fiat/providers/stripeAuthorize.d.ts +5 -0
- package/dist/src/fiat/providers/stripeAuthorize.d.ts.map +1 -0
- package/dist/src/fiat/providers/stripeCheckout.d.ts +28 -0
- package/dist/src/fiat/providers/stripeCheckout.d.ts.map +1 -0
- package/dist/src/fiat/providers/stripeKyc.d.ts +56 -0
- package/dist/src/fiat/providers/stripeKyc.d.ts.map +1 -0
- package/dist/src/fiat/providers/stripeKycInfo.d.ts +11 -0
- package/dist/src/fiat/providers/stripeKycInfo.d.ts.map +1 -0
- package/dist/src/fiat/providers/stripeOnramp.d.ts +135 -0
- package/dist/src/fiat/providers/stripeOnramp.d.ts.map +1 -0
- package/dist/src/fiat/providers/stripeOnrampBridge.d.ts +20 -0
- package/dist/src/fiat/providers/stripeOnrampBridge.d.ts.map +1 -0
- package/dist/src/fiat/providers/stripePayment.d.ts +34 -0
- package/dist/src/fiat/providers/stripePayment.d.ts.map +1 -0
- package/dist/src/fiat/providers/stripeSdk.d.ts +19 -0
- package/dist/src/fiat/providers/stripeSdk.d.ts.map +1 -0
- package/dist/src/fiat/providers/stripeSeamlessSignIn.d.ts +18 -0
- package/dist/src/fiat/providers/stripeSeamlessSignIn.d.ts.map +1 -0
- package/dist/src/fiat/providers/stripeSessionAuth.d.ts +43 -0
- package/dist/src/fiat/providers/stripeSessionAuth.d.ts.map +1 -0
- package/dist/src/fiat/providers/useStripeOnrampClient.d.ts +35 -0
- package/dist/src/fiat/providers/useStripeOnrampClient.d.ts.map +1 -0
- package/dist/src/fiat/quoteRefusal.d.ts +6 -2
- package/dist/src/fiat/quoteRefusal.d.ts.map +1 -1
- package/dist/src/fiat/renderCaptureSurface.d.ts +1 -1
- package/dist/src/fiat/renderCaptureSurface.d.ts.map +1 -1
- package/dist/src/fiat/sectionDetail.d.ts.map +1 -1
- package/dist/src/fiat/stepDetails.d.ts +5 -1
- package/dist/src/fiat/stepDetails.d.ts.map +1 -1
- package/dist/src/fiat/useKycCompletion.d.ts +11 -3
- package/dist/src/fiat/useKycCompletion.d.ts.map +1 -1
- package/dist/src/fiat/useStaleQuoteRecovery.d.ts +8 -1
- package/dist/src/fiat/useStaleQuoteRecovery.d.ts.map +1 -1
- package/dist/src/flow/DepositAmountStep.d.ts +4 -2
- package/dist/src/flow/DepositAmountStep.d.ts.map +1 -1
- package/dist/src/flow/DepositFlowContent.d.ts +4 -1
- package/dist/src/flow/DepositFlowContent.d.ts.map +1 -1
- package/dist/src/flow/DepositReceivedToast.d.ts +17 -0
- package/dist/src/flow/DepositReceivedToast.d.ts.map +1 -0
- package/dist/src/flow/Drawer.d.ts +3 -2
- package/dist/src/flow/Drawer.d.ts.map +1 -1
- package/dist/src/flow/FeeDetailsSheet.d.ts.map +1 -1
- package/dist/src/flow/FiatDepositAmountStep.d.ts +6 -2
- package/dist/src/flow/FiatDepositAmountStep.d.ts.map +1 -1
- package/dist/src/flow/FiatRegionBlockedStep.d.ts +14 -0
- package/dist/src/flow/FiatRegionBlockedStep.d.ts.map +1 -0
- package/dist/src/flow/FiatRegionPendingStep.d.ts +10 -0
- package/dist/src/flow/FiatRegionPendingStep.d.ts.map +1 -0
- package/dist/src/flow/FlowSheet.d.ts +10 -3
- package/dist/src/flow/FlowSheet.d.ts.map +1 -1
- package/dist/src/flow/FunkitFlowProvider.d.ts +11 -1
- package/dist/src/flow/FunkitFlowProvider.d.ts.map +1 -1
- package/dist/src/flow/StepPage.d.ts +16 -0
- package/dist/src/flow/StepPage.d.ts.map +1 -0
- package/dist/src/flow/accountContext.d.ts +6 -0
- package/dist/src/flow/accountContext.d.ts.map +1 -0
- package/dist/src/flow/depositFlowConfig.d.ts +95 -26
- package/dist/src/flow/depositFlowConfig.d.ts.map +1 -1
- package/dist/src/flow/depositMethods.d.ts +21 -0
- package/dist/src/flow/depositMethods.d.ts.map +1 -0
- package/dist/src/flow/depositRailCopy.d.ts +20 -0
- package/dist/src/flow/depositRailCopy.d.ts.map +1 -0
- package/dist/src/flow/flowError.d.ts +37 -0
- package/dist/src/flow/flowError.d.ts.map +1 -0
- package/dist/src/flow/useDepositReceivedToast.d.ts +22 -0
- package/dist/src/flow/useDepositReceivedToast.d.ts.map +1 -0
- package/dist/src/flow/withdrawalFlowConfig.d.ts +12 -5
- package/dist/src/flow/withdrawalFlowConfig.d.ts.map +1 -1
- package/dist/src/geo/useFiatRegionSupport.d.ts +23 -0
- package/dist/src/geo/useFiatRegionSupport.d.ts.map +1 -0
- package/dist/src/hooks/useGuardedAmountInput.d.ts +15 -15
- package/dist/src/hooks/useGuardedAmountInput.d.ts.map +1 -1
- package/dist/src/hooks/usePressScale.d.ts +22 -3
- package/dist/src/hooks/usePressScale.d.ts.map +1 -1
- package/dist/src/icons/FigmaSystemIcons.d.ts +1 -0
- package/dist/src/icons/FigmaSystemIcons.d.ts.map +1 -1
- package/dist/src/icons/KycIdentityIcon.d.ts +2 -1
- package/dist/src/icons/KycIdentityIcon.d.ts.map +1 -1
- package/dist/src/icons/KycStatusIcon.d.ts +1 -1
- package/dist/src/icons/KycStatusIcon.d.ts.map +1 -1
- package/dist/src/icons/kycArtwork.d.ts +15 -0
- package/dist/src/icons/kycArtwork.d.ts.map +1 -1
- package/dist/src/identity/IdentityContext.d.ts +3 -4
- package/dist/src/identity/IdentityContext.d.ts.map +1 -1
- package/dist/src/logging/debugBridge.d.ts +11 -0
- package/dist/src/logging/debugBridge.d.ts.map +1 -0
- package/dist/src/providers/FunkitProvider.d.ts +19 -1
- package/dist/src/providers/FunkitProvider.d.ts.map +1 -1
- package/dist/src/providers/NativeCapabilitiesContext.d.ts +17 -4
- package/dist/src/providers/NativeCapabilitiesContext.d.ts.map +1 -1
- package/dist/src/providers/useFrozenIdentity.d.ts +19 -0
- package/dist/src/providers/useFrozenIdentity.d.ts.map +1 -0
- package/dist/src/screens/DepositAmountScreen.d.ts +1 -1
- package/dist/src/screens/DepositAmountScreen.d.ts.map +1 -1
- package/dist/src/screens/FeeDetailsScreen.d.ts +16 -10
- package/dist/src/screens/FeeDetailsScreen.d.ts.map +1 -1
- package/dist/src/screens/depositMetrics.d.ts +2 -8
- package/dist/src/screens/depositMetrics.d.ts.map +1 -1
- package/dist/src/statsig/useStatsigReady.d.ts +11 -0
- package/dist/src/statsig/useStatsigReady.d.ts.map +1 -0
- package/dist/src/theme/buildFunkitTheme.d.ts +15 -11
- package/dist/src/theme/buildFunkitTheme.d.ts.map +1 -1
- package/dist/src/theme/restyle.d.ts +495 -363
- package/dist/src/theme/restyle.d.ts.map +1 -1
- package/dist/src/theme/toRestyleTheme.d.ts +45 -33
- package/dist/src/theme/toRestyleTheme.d.ts.map +1 -1
- package/dist/src/theme/tokens.d.ts +5 -5
- package/dist/src/theme/tokens.d.ts.map +1 -1
- package/dist/src/transfer/hooks/useWithdrawalFops.d.ts.map +1 -1
- package/dist/src/utils/formatAmount.d.ts +4 -3
- package/dist/src/utils/formatAmount.d.ts.map +1 -1
- package/dist/src/utils/motion.d.ts +8 -0
- package/dist/src/utils/motion.d.ts.map +1 -1
- package/dist/src/withdrawal/useCryptoWithdrawalExecution.d.ts.map +1 -1
- package/dist/src/withdrawal/useCryptoWithdrawalForm.d.ts.map +1 -1
- package/dist/src/withdrawal/useCryptoWithdrawalValidation.d.ts.map +1 -1
- package/dist/src/withdrawal/useWithdrawalExecution.d.ts.map +1 -1
- package/dist/src/withdrawal/useWithdrawalSourceTokenBalance.d.ts +11 -0
- package/dist/src/withdrawal/useWithdrawalSourceTokenBalance.d.ts.map +1 -0
- package/dist/src/withdrawal/walletlessWithdrawal.d.ts +7 -0
- package/dist/src/withdrawal/walletlessWithdrawal.d.ts.map +1 -0
- package/package.json +10 -5
- package/dist/chunk-HMAJXI66.js.map +0 -7
- package/dist/src/hooks/useMinimumAmountValidation.d.ts +0 -21
- package/dist/src/hooks/useMinimumAmountValidation.d.ts.map +0 -1
- package/dist/src/hooks/useTrailingTrue.d.ts +0 -7
- package/dist/src/hooks/useTrailingTrue.d.ts.map +0 -1
- /package/dist/{chunk-MKOPF7Y5.js.map → chunk-HRJNTNCV.js.map} +0 -0
|
@@ -1,6 +1,7 @@
|
|
|
1
|
-
import type { CheckoutTokenTransferConfig, DynamicTargetAssetCandidate, MinDepositTarget } from '@funkit/connect-core';
|
|
1
|
+
import type { CheckoutTokenTransferConfig, DynamicTargetAssetCandidate, FiatRoutingOverrides, MinDepositTarget } from '@funkit/connect-core';
|
|
2
2
|
import type { ReactNode } from 'react';
|
|
3
3
|
import type { SupportedToken, TokenChainFilter } from '../transfer/supportedTokens';
|
|
4
|
+
import type { FunkitFlowError } from './flowError';
|
|
4
5
|
export type { DynamicTargetAssetCandidate } from '@funkit/connect-core';
|
|
5
6
|
/**
|
|
6
7
|
* Host-supplied identifiers correlating this deposit with the host's own
|
|
@@ -63,24 +64,28 @@ export interface ChainOption {
|
|
|
63
64
|
*/
|
|
64
65
|
export interface DepositAmountEntryConfig {
|
|
65
66
|
/**
|
|
66
|
-
*
|
|
67
|
-
*
|
|
68
|
-
* there. Without `fiat` an omitted rate shows no fee at all.
|
|
67
|
+
* @deprecated The rail quotes its own fee. Fee charged on the entered
|
|
68
|
+
* amount, as a fraction (0.005 = 0.5%), shown only while no rail is wired.
|
|
69
69
|
*/
|
|
70
70
|
feeRate?: number;
|
|
71
71
|
/**
|
|
72
|
-
* The
|
|
73
|
-
* the fee-details drawer
|
|
74
|
-
* the figures alone.
|
|
72
|
+
* @deprecated The SDK names the rail from {@link DepositFlowConfig.methods}.
|
|
73
|
+
* Overrides how the fee-details drawer names it.
|
|
75
74
|
*/
|
|
76
75
|
methodName?: string;
|
|
77
76
|
/** Header title; defaults to the SDK's own translated "Deposit". */
|
|
78
77
|
title?: string;
|
|
79
|
-
/**
|
|
80
|
-
|
|
78
|
+
/**
|
|
79
|
+
* @deprecated The SDK words the submit from {@link DepositFlowConfig.methods}
|
|
80
|
+
* in the user's locale. Overrides that label.
|
|
81
|
+
*/
|
|
82
|
+
submitLabel?: string;
|
|
81
83
|
/** Quick-amount presets in whole dollars; defaults to 10/20/50/100. */
|
|
82
84
|
quickAmountsUsd?: string[];
|
|
83
|
-
/**
|
|
85
|
+
/**
|
|
86
|
+
* Hard input cap in dollars. With {@link fiat} configured it defaults to
|
|
87
|
+
* $2,500; without `fiat` an omitted cap means no limit.
|
|
88
|
+
*/
|
|
84
89
|
limitUsd?: string;
|
|
85
90
|
/**
|
|
86
91
|
* Smallest amount the source will take, in dollars. Below it the CTA names
|
|
@@ -89,20 +94,37 @@ export interface DepositAmountEntryConfig {
|
|
|
89
94
|
minLimitUsd?: string;
|
|
90
95
|
/** Brand glyph beside the title; the title stands alone without one. */
|
|
91
96
|
brandIcon?: ReactNode;
|
|
92
|
-
/**
|
|
97
|
+
/**
|
|
98
|
+
* @deprecated The SDK draws the rail's mark from
|
|
99
|
+
* {@link DepositFlowConfig.methods}. Overrides the fee line's badge.
|
|
100
|
+
*/
|
|
93
101
|
methodBadge?: ReactNode;
|
|
94
102
|
/** Host account context in the header (label + balance + avatar). */
|
|
95
|
-
accountContext?:
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
/** Links back out to the host context (e.g. the profile page). */
|
|
101
|
-
onPress?: () => void;
|
|
102
|
-
};
|
|
103
|
-
/** Routes amount entry through the fiat backend. */
|
|
103
|
+
accountContext?: DepositAccountContext;
|
|
104
|
+
/**
|
|
105
|
+
* @deprecated Name the rail in {@link DepositFlowConfig.methods}; it delivers
|
|
106
|
+
* to `checkoutConfig`, so the destination is not repeated here.
|
|
107
|
+
*/
|
|
104
108
|
fiat?: FiatRailConfig;
|
|
105
109
|
}
|
|
110
|
+
/**
|
|
111
|
+
* The host's balance beside the title. The SDK formats it like every other
|
|
112
|
+
* amount on the screen, so give it the number, not the words.
|
|
113
|
+
*/
|
|
114
|
+
export type DepositAccountContext = {
|
|
115
|
+
label: string;
|
|
116
|
+
avatar?: ReactNode;
|
|
117
|
+
/** Links back out to the host context (e.g. the profile page). */
|
|
118
|
+
onPress?: () => void;
|
|
119
|
+
} & ({
|
|
120
|
+
/** Decimal string in dollars, e.g. `"366715.12"`. */
|
|
121
|
+
amountUsd: string;
|
|
122
|
+
value?: undefined;
|
|
123
|
+
} | {
|
|
124
|
+
/** @deprecated Pass {@link amountUsd}; the SDK formats it. */
|
|
125
|
+
value: string;
|
|
126
|
+
amountUsd?: undefined;
|
|
127
|
+
});
|
|
106
128
|
/**
|
|
107
129
|
* A fixed fiat amount to prefill the deposit amount screen with — the value
|
|
108
130
|
* the user pays, not a crypto amount. Distinct from any provider's approved
|
|
@@ -116,7 +138,30 @@ export interface DepositInitialAmount {
|
|
|
116
138
|
/** ISO 4217 currency code, e.g. `"USD"`. */
|
|
117
139
|
currency: string;
|
|
118
140
|
}
|
|
119
|
-
/**
|
|
141
|
+
/** What a fiat method needs beyond its type to be quoted. */
|
|
142
|
+
export interface FiatDepositMethodOptions {
|
|
143
|
+
/** Ticker the onramp quote API uses for the checkout target. */
|
|
144
|
+
fiatTargetAssetTicker?: string;
|
|
145
|
+
/**
|
|
146
|
+
* Test tooling for exercising one provider integration at a time. Sandbox
|
|
147
|
+
* and local backends only; production refuses a quote carrying it. The
|
|
148
|
+
* prefix keeps it out of a host's tab-completion for that reason.
|
|
149
|
+
*/
|
|
150
|
+
unstable_routingOverrides?: FiatRoutingOverrides;
|
|
151
|
+
}
|
|
152
|
+
/** A way to fund the deposit. */
|
|
153
|
+
export type DepositMethod = ({
|
|
154
|
+
type: 'apple_pay';
|
|
155
|
+
} & FiatDepositMethodOptions) | ({
|
|
156
|
+
type: 'card';
|
|
157
|
+
} & FiatDepositMethodOptions) | {
|
|
158
|
+
type: 'crypto';
|
|
159
|
+
};
|
|
160
|
+
/**
|
|
161
|
+
* The fiat onramp rail behind the V2 amount screen. Derived from
|
|
162
|
+
* {@link DepositFlowConfig.methods} and the active checkout chain; hosts no
|
|
163
|
+
* longer write one directly.
|
|
164
|
+
*/
|
|
120
165
|
export interface FiatRailConfig {
|
|
121
166
|
/** The rail quoted and fired, e.g. `apple_pay`. */
|
|
122
167
|
paymentMethod: string;
|
|
@@ -130,6 +175,8 @@ export interface FiatRailConfig {
|
|
|
130
175
|
cryptoCurrencyAddress: string;
|
|
131
176
|
/** Destination chain id used for the quote. */
|
|
132
177
|
chainId: string;
|
|
178
|
+
/** See {@link FiatDepositMethodOptions.unstable_routingOverrides}. */
|
|
179
|
+
unstable_routingOverrides?: FiatRoutingOverrides;
|
|
133
180
|
}
|
|
134
181
|
/**
|
|
135
182
|
* Data the managed deposit flow renders.
|
|
@@ -145,6 +192,14 @@ export interface FiatRailConfig {
|
|
|
145
192
|
* `beginDeposit` ultimately takes just a target, like the web `beginCheckout`.
|
|
146
193
|
*/
|
|
147
194
|
export interface DepositFlowConfig {
|
|
195
|
+
/**
|
|
196
|
+
* What the deposit offers. Order is a hint; Fun ranks per user. With
|
|
197
|
+
* `amountEntry`, the first fiat entry is the rail behind submit and needs a
|
|
198
|
+
* ticker for the active checkout target.
|
|
199
|
+
* Without `amountEntry`, a list omitting `crypto` drops the Crypto row from
|
|
200
|
+
* Add money. Omitted, the V1 method list stands.
|
|
201
|
+
*/
|
|
202
|
+
methods?: DepositMethod[];
|
|
148
203
|
/**
|
|
149
204
|
* Opt into the V2 amount-first deposit surface: the flow opens on the
|
|
150
205
|
* full-screen amount screen instead of the Add money method list.
|
|
@@ -177,7 +232,10 @@ export interface DepositFlowConfig {
|
|
|
177
232
|
* (no identity). Display formatting (truncation) is applied by the flow.
|
|
178
233
|
*/
|
|
179
234
|
depositAddress?: string;
|
|
180
|
-
/**
|
|
235
|
+
/**
|
|
236
|
+
* @deprecated Ignored — the supported-tokens screen lists the curated
|
|
237
|
+
* tokens the SDK resolves itself.
|
|
238
|
+
*/
|
|
181
239
|
supportedTokens?: SupportedToken[];
|
|
182
240
|
tokenChainFilters?: TokenChainFilter[];
|
|
183
241
|
/**
|
|
@@ -206,10 +264,21 @@ export interface DepositFlowCallbacks {
|
|
|
206
264
|
onClose?: () => void;
|
|
207
265
|
onCheckoutBlocked?: () => void;
|
|
208
266
|
/**
|
|
209
|
-
*
|
|
210
|
-
*
|
|
211
|
-
*
|
|
212
|
-
*
|
|
267
|
+
* The deposit is on its way and the SDK is finished with it: the flow has
|
|
268
|
+
* closed and its confirmation is up. `orderId` is the provider's; `method`
|
|
269
|
+
* is the rail's {@link DepositMethod} type. Fires only where the rail pays
|
|
270
|
+
* the recipient directly — an order the backend still has to sweep has not
|
|
271
|
+
* arrived, so nothing is claimed for it.
|
|
272
|
+
*/
|
|
273
|
+
onDepositSubmitted?: (orderId: string, method: DepositMethod['type']) => void;
|
|
274
|
+
/**
|
|
275
|
+
* The deposit ended short of an order, or the order failed. `cancelled`
|
|
276
|
+
* is the user leaving; see {@link FunkitFlowError} for the rest.
|
|
277
|
+
*/
|
|
278
|
+
onDepositError?: (error: FunkitFlowError) => void;
|
|
279
|
+
/**
|
|
280
|
+
* @deprecated Name a rail in {@link DepositFlowConfig.methods}; it owns the
|
|
281
|
+
* submit. Fires only while no rail is wired.
|
|
213
282
|
*/
|
|
214
283
|
onSubmitAmount?: (amountUsd: string) => void;
|
|
215
284
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"depositFlowConfig.d.ts","sourceRoot":"","sources":["../../../src/flow/depositFlowConfig.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,2BAA2B,EAC3B,2BAA2B,EAC3B,gBAAgB,EACjB,MAAM,sBAAsB,CAAA;AAC7B,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAA;AAEtC,OAAO,KAAK,EACV,cAAc,EACd,gBAAgB,EACjB,MAAM,6BAA6B,CAAA;
|
|
1
|
+
{"version":3,"file":"depositFlowConfig.d.ts","sourceRoot":"","sources":["../../../src/flow/depositFlowConfig.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,2BAA2B,EAC3B,2BAA2B,EAC3B,oBAAoB,EACpB,gBAAgB,EACjB,MAAM,sBAAsB,CAAA;AAC7B,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAA;AAEtC,OAAO,KAAK,EACV,cAAc,EACd,gBAAgB,EACjB,MAAM,6BAA6B,CAAA;AACpC,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,aAAa,CAAA;AAElD,YAAY,EAAE,2BAA2B,EAAE,MAAM,sBAAsB,CAAA;AAEvE;;;;;GAKG;AACH,MAAM,WAAW,qBAAqB;IACpC,kCAAkC;IAClC,cAAc,CAAC,EAAE,MAAM,CAAA;IACvB,mEAAmE;IACnE,mBAAmB,CAAC,EAAE,GAAG,MAAM,EAAE,CAAA;CAClC;AAED;;;;;GAKG;AACH,MAAM,MAAM,qBAAqB,GAAG,2BAA2B,GAC7D,IAAI,CAAC,gBAAgB,EAAE,kBAAkB,CAAC,CAAA;AAE5C;;;;;;;;;;;;GAYG;A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CAAA;IACpB,0EAA0E;IAC1E,gBAAgB,CAAC,EAAE,MAAM,CAAA;IACzB;;;;OAIG;IACH,cAAc,CAAC,EAAE,MAAM,CAAA;IACvB;;;OAGG;IACH,eAAe,CAAC,EAAE,cAAc,EAAE,CAAA;IAClC,iBAAiB,CAAC,EAAE,gBAAgB,EAAE,CAAA;IACtC;;;OAGG;IACH,MAAM,CAAC,EAAE,SAAS,CAAA;IAClB,yCAAyC;IACzC,cAAc,CAAC,EAAE,qBAAqB,CAAA;IACtC;;;OAGG;IACH,aAAa,CAAC,EAAE,oBAAoB,CAAA;IACpC;;;;;OAKG;IACH,UAAU,CAAC,EAAE,OAAO,CAAA;CACrB;AAED,yDAAyD;AACzD,MAAM,WAAW,oBAAoB;IACnC,MAAM,CAAC,EAAE,MAAM,IAAI,CAAA;IACnB,OAAO,CAAC,EAAE,MAAM,IAAI,CAAA;IACpB,iBAAiB,CAAC,EAAE,MAAM,IAAI,CAAA;IAC9B;;;;;;OAMG;IACH,kBAAkB,CAAC,EAAE,CAAC,OAAO,EAAE,MAAM,EAAE,MAAM,EAAE,aAAa,CAAC,MAAM,CAAC,KAAK,IAAI,CAAA;IAC7E;;;OAGG;IACH,cAAc,CAAC,EAAE,CAAC,KAAK,EAAE,eAAe,KAAK,IAAI,CAAA;IACjD;;;OAGG;IACH,cAAc,CAAC,EAAE,CAAC,SAAS,EAAE,MAAM,KAAK,IAAI,CAAA;CAC7C"}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { type DepositCheckoutConfig, type DepositFlowConfig, type DepositMethod, type FiatRailConfig } from './depositFlowConfig';
|
|
2
|
+
/** The checkout target selected when a deposit first opens. */
|
|
3
|
+
export declare function resolveInitialDepositCheckoutConfig(config: DepositFlowConfig): DepositCheckoutConfig | undefined;
|
|
4
|
+
/**
|
|
5
|
+
* The methods a config offers, with the older shapes mapped onto the list: a
|
|
6
|
+
* deprecated `amountEntry.fiat` names its one rail, and no opt-in at all
|
|
7
|
+
* leaves the V1 list to Add money.
|
|
8
|
+
*/
|
|
9
|
+
export declare function resolveDepositMethods(config: DepositFlowConfig): DepositMethod[] | undefined;
|
|
10
|
+
/** Whether the deposit was configured to quote a fiat rail. */
|
|
11
|
+
export declare function hasFiatMethod(config: DepositFlowConfig): boolean;
|
|
12
|
+
/**
|
|
13
|
+
* The fiat rail behind the amount screen, or `undefined` when none is
|
|
14
|
+
* configured. An explicit method list wins over deprecated configuration. Its
|
|
15
|
+
* first fiat method supplies the target ticker, while the active checkout
|
|
16
|
+
* config supplies its address and chain.
|
|
17
|
+
*/
|
|
18
|
+
export declare function resolveFiatRail(config: DepositFlowConfig, checkoutConfig?: DepositCheckoutConfig | undefined): FiatRailConfig | undefined;
|
|
19
|
+
/** A method list that leaves `crypto` out drops the Crypto row from Add money. */
|
|
20
|
+
export declare function omitsCryptoDeposit(methods: DepositMethod[] | undefined): boolean;
|
|
21
|
+
//# sourceMappingURL=depositMethods.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"depositMethods.d.ts","sourceRoot":"","sources":["../../../src/flow/depositMethods.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,qBAAqB,EAC1B,KAAK,iBAAiB,EACtB,KAAK,aAAa,EAClB,KAAK,cAAc,EAEpB,MAAM,qBAAqB,CAAA;AAiB5B,+DAA+D;AAC/D,wBAAgB,mCAAmC,CACjD,MAAM,EAAE,iBAAiB,GACxB,qBAAqB,GAAG,SAAS,CAanC;AAED;;;;GAIG;AACH,wBAAgB,qBAAqB,CACnC,MAAM,EAAE,iBAAiB,GACxB,aAAa,EAAE,GAAG,SAAS,CAU7B;AAED,+DAA+D;AAC/D,wBAAgB,aAAa,CAAC,MAAM,EAAE,iBAAiB,GAAG,OAAO,CAKhE;AAED;;;;;GAKG;AACH,wBAAgB,eAAe,CAC7B,MAAM,EAAE,iBAAiB,EACzB,cAAc,GAAE,qBAAqB,GAAG,SAAiC,GACxE,cAAc,GAAG,SAAS,CAqB5B;AAED,kFAAkF;AAClF,wBAAgB,kBAAkB,CAChC,OAAO,EAAE,aAAa,EAAE,GAAG,SAAS,GACnC,OAAO,CAET"}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import type { TFunction } from 'i18next';
|
|
2
|
+
import type { ReactNode } from 'react';
|
|
3
|
+
import type { DepositAmountEntryConfig } from './depositFlowConfig';
|
|
4
|
+
/** The words and mark the amount screen draws for its rail. */
|
|
5
|
+
export interface DepositRailCopy {
|
|
6
|
+
/** The submit's default label, before the server relabels a step. */
|
|
7
|
+
submitLabel: string;
|
|
8
|
+
/** How the fee drawer names the rail; `undefined` leaves the summary out. */
|
|
9
|
+
methodName: string | undefined;
|
|
10
|
+
/** Badge on the fee line's leading side. */
|
|
11
|
+
methodBadge: ReactNode | undefined;
|
|
12
|
+
}
|
|
13
|
+
/**
|
|
14
|
+
* Rail copy comes from the rail, so no host writes "Deposit with Apple Pay":
|
|
15
|
+
* the SDK names the method in the user's locale and draws its mark. The
|
|
16
|
+
* deprecated `submitLabel`, `methodName` and `methodBadge` still win while
|
|
17
|
+
* they are set.
|
|
18
|
+
*/
|
|
19
|
+
export declare function resolveDepositRailCopy(config: DepositAmountEntryConfig, paymentMethod: string | undefined, t: TFunction): DepositRailCopy;
|
|
20
|
+
//# sourceMappingURL=depositRailCopy.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"depositRailCopy.d.ts","sourceRoot":"","sources":["../../../src/flow/depositRailCopy.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,SAAS,CAAA;AACxC,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAA;AAGtC,OAAO,KAAK,EAAE,wBAAwB,EAAE,MAAM,qBAAqB,CAAA;AAEnE,+DAA+D;AAC/D,MAAM,WAAW,eAAe;IAC9B,qEAAqE;IACrE,WAAW,EAAE,MAAM,CAAA;IACnB,6EAA6E;IAC7E,UAAU,EAAE,MAAM,GAAG,SAAS,CAAA;IAC9B,4CAA4C;IAC5C,WAAW,EAAE,SAAS,GAAG,SAAS,CAAA;CACnC;AAkBD;;;;;GAKG;AACH,wBAAgB,sBAAsB,CACpC,MAAM,EAAE,wBAAwB,EAChC,aAAa,EAAE,MAAM,GAAG,SAAS,EACjC,CAAC,EAAE,SAAS,GACX,eAAe,CAcjB"}
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Why a managed flow ended short of its outcome. One shape for deposits and
|
|
3
|
+
* withdrawals, so a host branches on `code` and the two flags rather than on
|
|
4
|
+
* message text.
|
|
5
|
+
*/
|
|
6
|
+
export type FunkitFlowErrorCode =
|
|
7
|
+
/** The user dismissed the flow before anything was submitted. */
|
|
8
|
+
'cancelled'
|
|
9
|
+
/** Fun will not serve this user, region, asset or amount. */
|
|
10
|
+
| 'blocked'
|
|
11
|
+
/** The host's `getIdentityAssertion` threw. */
|
|
12
|
+
| 'identity_assertion_failed'
|
|
13
|
+
/** The wallet refused to sign. */
|
|
14
|
+
| 'signer_rejected'
|
|
15
|
+
/** The config cannot open a flow; fix the integration. */
|
|
16
|
+
| 'misconfigured'
|
|
17
|
+
/** Every provider, or the payment instrument, declined. */
|
|
18
|
+
| 'payment_declined' | 'unknown';
|
|
19
|
+
export interface FunkitFlowError {
|
|
20
|
+
code: FunkitFlowErrorCode;
|
|
21
|
+
/** Trying again, unchanged, has a chance. */
|
|
22
|
+
isRetryable: boolean;
|
|
23
|
+
/** Nothing the user does in this flow recovers it. */
|
|
24
|
+
isFatal: boolean;
|
|
25
|
+
/** Fit to show the user. */
|
|
26
|
+
message: string;
|
|
27
|
+
}
|
|
28
|
+
/** Builds an error with the code's usual flags; a caller that knows better overrides them. */
|
|
29
|
+
export declare function flowError(code: FunkitFlowErrorCode, message: string, flags?: Partial<Pick<FunkitFlowError, 'isRetryable' | 'isFatal'>>): FunkitFlowError;
|
|
30
|
+
/** Thrown by `beginDeposit` when the config cannot open a flow. */
|
|
31
|
+
export declare class FunkitMisconfiguredError extends Error implements FunkitFlowError {
|
|
32
|
+
readonly code = "misconfigured";
|
|
33
|
+
readonly isRetryable = false;
|
|
34
|
+
readonly isFatal = true;
|
|
35
|
+
constructor(message: string);
|
|
36
|
+
}
|
|
37
|
+
//# sourceMappingURL=flowError.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"flowError.d.ts","sourceRoot":"","sources":["../../../src/flow/flowError.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AACH,MAAM,MAAM,mBAAmB;AAC7B,iEAAiE;AAC/D,WAAW;AACb,6DAA6D;GAC3D,SAAS;AACX,+CAA+C;GAC7C,2BAA2B;AAC7B,kCAAkC;GAChC,iBAAiB;AACnB,0DAA0D;GACxD,eAAe;AACjB,2DAA2D;GACzD,kBAAkB,GAClB,SAAS,CAAA;AAEb,MAAM,WAAW,eAAe;IAC9B,IAAI,EAAE,mBAAmB,CAAA;IACzB,6CAA6C;IAC7C,WAAW,EAAE,OAAO,CAAA;IACpB,sDAAsD;IACtD,OAAO,EAAE,OAAO,CAAA;IAChB,4BAA4B;IAC5B,OAAO,EAAE,MAAM,CAAA;CAChB;AAeD,8FAA8F;AAC9F,wBAAgB,SAAS,CACvB,IAAI,EAAE,mBAAmB,EACzB,OAAO,EAAE,MAAM,EACf,KAAK,GAAE,OAAO,CAAC,IAAI,CAAC,eAAe,EAAE,aAAa,GAAG,SAAS,CAAC,CAAM,GACpE,eAAe,CAEjB;AAED,mEAAmE;AACnE,qBAAa,wBAAyB,SAAQ,KAAM,YAAW,eAAe;IAC5E,QAAQ,CAAC,IAAI,mBAAkB;IAC/B,QAAQ,CAAC,WAAW,SAAQ;IAC5B,QAAQ,CAAC,OAAO,QAAO;gBAEX,OAAO,EAAE,MAAM;CAI5B"}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { type ReactNode } from 'react';
|
|
2
|
+
import { DepositReceivedToast } from './DepositReceivedToast';
|
|
3
|
+
/** What the card says: the amount that landed, and where it came from. */
|
|
4
|
+
export interface DepositReceipt {
|
|
5
|
+
title: string;
|
|
6
|
+
detail: string;
|
|
7
|
+
}
|
|
8
|
+
interface DepositReceivedToast {
|
|
9
|
+
/** The overlay to render; the caller owns only where it sits in the tree. */
|
|
10
|
+
depositToast: ReactNode;
|
|
11
|
+
showDepositToast: (receipt: DepositReceipt) => void;
|
|
12
|
+
clearDepositToast: () => void;
|
|
13
|
+
}
|
|
14
|
+
/**
|
|
15
|
+
* The deposit confirmation that replaces the payment sheet.
|
|
16
|
+
*
|
|
17
|
+
* It is raised as the flow closes and has to outlive it, so it is mounted
|
|
18
|
+
* beside the sheet rather than inside it — and `closeFlow` leaves it alone.
|
|
19
|
+
*/
|
|
20
|
+
export declare function useDepositReceivedToast(): DepositReceivedToast;
|
|
21
|
+
export {};
|
|
22
|
+
//# sourceMappingURL=useDepositReceivedToast.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useDepositReceivedToast.d.ts","sourceRoot":"","sources":["../../../src/flow/useDepositReceivedToast.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,SAAS,EAA4C,MAAM,OAAO,CAAA;AAKhF,OAAO,EAAE,oBAAoB,EAAE,MAAM,wBAAwB,CAAA;AAU7D,0EAA0E;AAC1E,MAAM,WAAW,cAAc;IAC7B,KAAK,EAAE,MAAM,CAAA;IACb,MAAM,EAAE,MAAM,CAAA;CACf;AAED,UAAU,oBAAoB;IAC5B,6EAA6E;IAC7E,YAAY,EAAE,SAAS,CAAA;IACvB,gBAAgB,EAAE,CAAC,OAAO,EAAE,cAAc,KAAK,IAAI,CAAA;IACnD,iBAAiB,EAAE,MAAM,IAAI,CAAA;CAC9B;AAED;;;;;GAKG;AACH,wBAAgB,uBAAuB,IAAI,oBAAoB,CA6C9D"}
|
|
@@ -71,11 +71,12 @@ export interface WithdrawalFlowConfig {
|
|
|
71
71
|
/**
|
|
72
72
|
* Crypto rail: spendable balance of a source token, in that token's units.
|
|
73
73
|
* The integrator is authoritative — it knows about locks, pending orders and
|
|
74
|
-
* borrow limits the SDK can't see on-chain.
|
|
75
|
-
* cheap and referentially stable; a
|
|
76
|
-
*
|
|
74
|
+
* borrow limits the SDK can't see on-chain. A plain value is read on render,
|
|
75
|
+
* so keep it cheap and referentially stable; a promise is awaited once per
|
|
76
|
+
* source token, with the balance held at zero until it settles. A throw or
|
|
77
|
+
* a nonsense value is treated as a zero balance rather than breaking the form.
|
|
77
78
|
*/
|
|
78
|
-
withdrawalSourceTokenBalance?: (params: WithdrawalSourceTokenParams) => string | number
|
|
79
|
+
withdrawalSourceTokenBalance?: (params: WithdrawalSourceTokenParams) => string | number | Promise<string | number>;
|
|
79
80
|
/** Crypto rail: minimum withdrawal in USD. Defaults to $0.01. */
|
|
80
81
|
getMinWithdrawalUSD?: (params: WithdrawalSourceTokenParams) => number;
|
|
81
82
|
/**
|
|
@@ -108,8 +109,14 @@ export interface WithdrawalFlowConfig {
|
|
|
108
109
|
* Host-provided signer that executes the on-chain leg (the host app owns the
|
|
109
110
|
* keys — the SDK never touches key material). Implement the `WithdrawalClient`
|
|
110
111
|
* interface over your wallet stack (viem, wagmi, WalletConnect, …).
|
|
112
|
+
*
|
|
113
|
+
* Omit it when there is no end-user signer to offer — Fun moves the funds
|
|
114
|
+
* from the client's omnibus account, so the host holds no keys for this user.
|
|
115
|
+
* The flow still renders and quotes (priced against the zero address), but it
|
|
116
|
+
* cannot put a transfer on-chain itself: cash payout methods are withheld,
|
|
117
|
+
* and submitting throws unless {@link submitWithdrawal} takes over.
|
|
111
118
|
*/
|
|
112
|
-
withdrawalWallet
|
|
119
|
+
withdrawalWallet?: WithdrawalClient;
|
|
113
120
|
/**
|
|
114
121
|
* Replaces relay execution: the venue moves the funds itself and resolves with
|
|
115
122
|
* the address it sent them to. The quote is priced for display and never
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"withdrawalFlowConfig.d.ts","sour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IAClC;;;;OAIG;IACH,mBAAmB,CAAC,EAAE,MAAM,CAAA;IAC5B;;;;;OAKG;IACH,oBAAoB,CAAC,EAAE,OAAO,CAAA;IAC9B;;;;OAIG;IACH,iBAAiB,CAAC,EAAE,MAAM,CAAA;IAC1B;;;;;;OAMG;IACH,gBAAgB,CAAC,EAAE,MAAM,GAAG,CAAC,MAAM,MAAM,GAAG,OAAO,CAAC,MAAM,CAAC,CAAC,CAAA;CAC7D;AAED,yDAAyD;AACzD,MAAM,WAAW,uBAAuB;IACtC,MAAM,CAAC,EAAE,MAAM,IAAI,CAAA;IACnB,OAAO,CAAC,EAAE,MAAM,IAAI,CAAA;IACpB,iBAAiB,CAAC,EAAE,MAAM,IAAI,CAAA;IAC9B;;;;OAIG;IACH,iBAAiB,CAAC,EAAE,CAAC,KAAK,EAAE,oBAAoB,KAAK,IAAI,CAAA;IACzD;;;;;;;OAOG;IACH,qBAAqB,CAAC,EAAE,CACtB,OAAO,EAAE,MAAM,EACf,oBAAoB,EAAE,MAAM,KACzB,IAAI,CAAA;IACT;;;OAGG;IACH,mBAAmB,CAAC,EAAE,CAAC,IAAI,CAAC,EAAE,OAAO,KAAK,IAAI,CAAA;IAC9C,wEAAwE;IACxE,iBAAiB,CAAC,EAAE,CAAC,KAAK,EAAE;QAAE,OAAO,EAAE,MAAM,CAAA;KAAE,KAAK,IAAI,CAAA;CACzD"}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { type FiatRegionVerdict } from '@funkit/connect-core';
|
|
2
|
+
export interface UseFiatRegionSupportResult {
|
|
3
|
+
verdict: FiatRegionVerdict;
|
|
4
|
+
/**
|
|
5
|
+
* The verdict is provisional: either the buyer's location or the policy
|
|
6
|
+
* itself is still resolving. A provisional verdict always reads as supported,
|
|
7
|
+
* so a caller that acts on it admits a buyer the settled policy may deny.
|
|
8
|
+
*/
|
|
9
|
+
isLoading: boolean;
|
|
10
|
+
}
|
|
11
|
+
/**
|
|
12
|
+
* Whether fiat deposits are served where the buyer is, from their IP alone.
|
|
13
|
+
*
|
|
14
|
+
* Both inputs are already cached by the screens that follow — the geo lookup
|
|
15
|
+
* is session-stable and the config is the one Statsig resolves against that
|
|
16
|
+
* same country — so asking here costs no request and no wait.
|
|
17
|
+
*
|
|
18
|
+
* While the location is resolving the verdict reads as supported, which is
|
|
19
|
+
* what keeps a buyer off a refusal we have not decided yet. A location that
|
|
20
|
+
* never resolves is the existing compliance gate's to answer, not this one's.
|
|
21
|
+
*/
|
|
22
|
+
export declare function useFiatRegionSupport(): UseFiatRegionSupportResult;
|
|
23
|
+
//# sourceMappingURL=useFiatRegionSupport.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useFiatRegionSupport.d.ts","sourceRoot":"","sources":["../../../src/geo/useFiatRegionSupport.ts"],"names":[],"mappings":"AACA,OAAO,EACL,KAAK,iBAAiB,EAGvB,MAAM,sBAAsB,CAAA;AAO7B,MAAM,WAAW,0BAA0B;IACzC,OAAO,EAAE,iBAAiB,CAAA;IAC1B;;;;OAIG;IACH,SAAS,EAAE,OAAO,CAAA;CACnB;AAED;;;;;;;;;;GAUG;AACH,wBAAgB,oBAAoB,IAAI,0BAA0B,CAiDjE"}
|
|
@@ -1,11 +1,9 @@
|
|
|
1
1
|
import { type NumpadKey } from '../utils/numpadInput';
|
|
2
2
|
/**
|
|
3
|
-
*
|
|
4
|
-
*
|
|
5
|
-
* Only the cap refuses. A floor is a state the amount is allowed to sit in —
|
|
6
|
-
* the screen answers that one, and the keypad stays out of its way.
|
|
3
|
+
* The value sits over the source's ceiling — the floor's mirror, and read the
|
|
4
|
+
* same way: a state the amount is allowed to hold while the screen names it.
|
|
7
5
|
*/
|
|
8
|
-
export
|
|
6
|
+
export declare function isAboveMaximum(value: string, limitUsd?: string): boolean;
|
|
9
7
|
/**
|
|
10
8
|
* The value sits under the source's floor. Empty and zero are the untouched
|
|
11
9
|
* state rather than a violation — there is nothing yet to be too small.
|
|
@@ -14,26 +12,27 @@ export declare function isBelowMinimum(value: string, minLimitUsd?: string): boo
|
|
|
14
12
|
/**
|
|
15
13
|
* An amount screen's input policy, separate from its layout. Every way a value
|
|
16
14
|
* enters — a numpad key or a quick-amount chip — commits through this hook, so
|
|
17
|
-
* the
|
|
18
|
-
*
|
|
19
|
-
*
|
|
20
|
-
*
|
|
21
|
-
*
|
|
15
|
+
* the policy lives in exactly one place.
|
|
16
|
+
*
|
|
17
|
+
* `limitUsd` is the source's maximum, wherever it came from — the host's own
|
|
18
|
+
* figure, the corridor's, or the one a refusal reports. The digit lands, the
|
|
19
|
+
* amount jolts, and the screen names the bound and offers the way back, so the
|
|
20
|
+
* buyer is always told the number they can have rather than left guessing at
|
|
21
|
+
* a key that does nothing.
|
|
22
22
|
*
|
|
23
|
-
*
|
|
24
|
-
*
|
|
23
|
+
* Only a meaningless edit is refused outright besides — deleting from zero, or
|
|
24
|
+
* any edit while `disabled` — and a zero typed onto zero is a no-op that swells
|
|
25
|
+
* to acknowledge it.
|
|
25
26
|
*/
|
|
26
27
|
export declare function useGuardedAmountInput({ input, onChangeInput, limitUsd, disabled, }: {
|
|
27
28
|
input: string;
|
|
28
29
|
onChangeInput: (input: string) => void;
|
|
29
|
-
/**
|
|
30
|
+
/** The source's maximum; a value past it lands and the screen names it. */
|
|
30
31
|
limitUsd?: string;
|
|
31
32
|
/** Locks the value: every numpad/chip commit rejects instead of applying. */
|
|
32
33
|
disabled?: boolean;
|
|
33
34
|
}): {
|
|
34
35
|
hasWarning: boolean;
|
|
35
|
-
refusal: AmountRefusal;
|
|
36
|
-
isLocked: boolean;
|
|
37
36
|
feedbackStyle: import("react-native-reanimated/lib/typescript/hook/commonTypes").AnimatedStyleHandle<{
|
|
38
37
|
transform: ({
|
|
39
38
|
translateX: number;
|
|
@@ -45,5 +44,6 @@ export declare function useGuardedAmountInput({ input, onChangeInput, limitUsd,
|
|
|
45
44
|
}>;
|
|
46
45
|
commitInput: (next: string) => void;
|
|
47
46
|
handleNumpadKey: (key: NumpadKey) => void;
|
|
47
|
+
pulseAmount: () => void;
|
|
48
48
|
};
|
|
49
49
|
//# sourceMappingURL=useGuardedAmountInput.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useGuardedAmountInput.d.ts","sourceRoot":"","sources":["../../../src/hooks/useGuardedAmountInput.ts"],"names":[],"mappings":"AAWA,OAAO,EAAE,KAAK,SAAS,EAAkB,MAAM,sBAAsB,CAAA;
|
|
1
|
+
{"version":3,"file":"useGuardedAmountInput.d.ts","sourceRoot":"","sources":["../../../src/hooks/useGuardedAmountInput.ts"],"names":[],"mappings":"AAWA,OAAO,EAAE,KAAK,SAAS,EAAkB,MAAM,sBAAsB,CAAA;AAuBrE;;;GAGG;AACH,wBAAgB,cAAc,CAAC,KAAK,EAAE,MAAM,EAAE,QAAQ,CAAC,EAAE,MAAM,GAAG,OAAO,CAKxE;AAED;;;GAGG;AACH,wBAAgB,cAAc,CAAC,KAAK,EAAE,MAAM,EAAE,WAAW,CAAC,EAAE,MAAM,GAAG,OAAO,CAM3E;AAOD;;;;;;;;;;;;;;GAcG;AACH,wBAAgB,qBAAqB,CAAC,EACpC,KAAK,EACL,aAAa,EACb,QAAQ,EACR,QAAgB,GACjB,EAAE;IACD,KAAK,EAAE,MAAM,CAAA;IACb,aAAa,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAA;IACtC,2EAA2E;IAC3E,QAAQ,CAAC,EAAE,MAAM,CAAA;IACjB,6EAA6E;IAC7E,QAAQ,CAAC,EAAE,OAAO,CAAA;CACnB;;;;;;;;;;;wBA4DU,MAAM;2BA2BP,SAAS;;EAiClB"}
|
|
@@ -1,16 +1,35 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* A row or a disclosure gives a little; the action a deposit turns on gives
|
|
3
|
+
* more, because it is the one press a buyer needs to feel they have made.
|
|
4
|
+
*/
|
|
5
|
+
export declare const ACTION_PRESSED_SCALE = 0.95;
|
|
6
|
+
export declare const ACTION_PRESSED_DIM = 0.85;
|
|
7
|
+
export interface PressScaleOptions {
|
|
8
|
+
/** Scale at the bottom of the press. */
|
|
9
|
+
scale?: number;
|
|
10
|
+
/** Opacity at the bottom of the press; 1 leaves the control at full strength. */
|
|
11
|
+
dim?: number;
|
|
12
|
+
/** Fire a tap as the finger lands. Off for controls that are not an action. */
|
|
13
|
+
haptics?: boolean;
|
|
14
|
+
}
|
|
1
15
|
/**
|
|
2
16
|
* Press feedback for a control the design gives no pressed fill: it dips under
|
|
3
17
|
* the finger on press-in and springs back on press-out. Scale takes the label
|
|
4
18
|
* and any icon with it, which is what makes it read as one physical object.
|
|
5
19
|
*
|
|
6
|
-
*
|
|
7
|
-
*
|
|
20
|
+
* Dip and dim run off one value, so the control is at its darkest exactly at
|
|
21
|
+
* the bottom of the travel rather than drifting against it.
|
|
22
|
+
*
|
|
23
|
+
* Reduced motion drops the dip but keeps the dim, applied without a ramp: the
|
|
24
|
+
* press still has to answer, and a control that changes strength in place asks
|
|
25
|
+
* nothing of a vestibular system. The tap is unaffected — it is not motion.
|
|
8
26
|
*/
|
|
9
|
-
export declare function usePressScale(): {
|
|
27
|
+
export declare function usePressScale({ scale, dim, haptics, }?: PressScaleOptions): {
|
|
10
28
|
pressStyle: import("react-native-reanimated/lib/typescript/hook/commonTypes").AnimatedStyleHandle<{
|
|
11
29
|
transform: {
|
|
12
30
|
scale: number;
|
|
13
31
|
}[];
|
|
32
|
+
opacity: number;
|
|
14
33
|
}>;
|
|
15
34
|
onPressIn: () => void;
|
|
16
35
|
onPressOut: () => void;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"usePressScale.d.ts","sourceRoot":"","sources":["../../../src/hooks/usePressScale.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"usePressScale.d.ts","sourceRoot":"","sources":["../../../src/hooks/usePressScale.ts"],"names":[],"mappings":"AAgBA;;;GAGG;AACH,eAAO,MAAM,oBAAoB,OAAO,CAAA;AACxC,eAAO,MAAM,kBAAkB,OAAO,CAAA;AAEtC,MAAM,WAAW,iBAAiB;IAChC,wCAAwC;IACxC,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,iFAAiF;IACjF,GAAG,CAAC,EAAE,MAAM,CAAA;IACZ,+EAA+E;IAC/E,OAAO,CAAC,EAAE,OAAO,CAAA;CAClB;AAED;;;;;;;;;;;GAWG;AACH,wBAAgB,aAAa,CAAC,EAC5B,KAAqB,EACrB,GAAO,EACP,OAAe,GAChB,GAAE,iBAAsB;;;;;;;;;EA6BxB"}
|
|
@@ -18,5 +18,6 @@ export declare function FigmaInfoCircleIcon({ size, color }: IconProps): import(
|
|
|
18
18
|
export declare function FigmaPlusIcon({ size, color }: IconProps): import("react").JSX.Element;
|
|
19
19
|
export declare function FigmaSearchIcon({ size, color }: IconProps): import("react").JSX.Element;
|
|
20
20
|
export declare function FigmaAlertCircleIcon({ size, color }: IconProps): import("react").JSX.Element;
|
|
21
|
+
export declare function FigmaAlertCircleOutlineIcon({ size, color }: IconProps): import("react").JSX.Element;
|
|
21
22
|
export {};
|
|
22
23
|
//# sourceMappingURL=FigmaSystemIcons.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"FigmaSystemIcons.d.ts","sourceRoot":"","sources":["../../../src/icons/FigmaSystemIcons.tsx"],"names":[],"mappings":"AAIA,KAAK,SAAS,GAAG;IACf,IAAI,CAAC,EAAE,MAAM,CAAA;IACb,KAAK,CAAC,EAAE,MAAM,CAAA;CACf,CAAA;AA0DD,wBAAgB,cAAc,CAAC,EAAE,IAAS,EAAE,KAAK,EAAE,EAAE,SAAS,+BAE7D;AAED,wBAAgB,eAAe,CAAC,EAAE,IAAS,EAAE,KAAK,EAAE,EAAE,SAAS,+BAE9D;AAED,wBAAgB,aAAa,CAAC,EAAE,IAAS,EAAE,KAAK,EAAE,EAAE,SAAS,+BAE5D;AAED,wBAAgB,cAAc,CAAC,EAAE,IAAS,EAAE,KAAK,EAAE,EAAE,SA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E,SAAS,+BAE5D;AAED,wBAAgB,cAAc,CAAC,EAAE,IAAS,EAAE,KAAK,EAAE,EAAE,SAAS,+BAE7D;AAED,wBAAgB,qBAAqB,CAAC,EAAE,IAAS,EAAE,KAAK,EAAE,EAAE,SAAS,+BAEpE;AAED,wBAAgB,oBAAoB,CAAC,EAAE,IAAS,EAAE,KAAK,EAAE,EAAE,SAAS,+BAEnE;AAED,wBAAgB,qBAAqB,CAAC,EAAE,IAAS,EAAE,EAAE;IAAE,IAAI,CAAC,EAAE,MAAM,CAAA;CAAE,+BAErE;AAED,wBAAgB,oBAAoB,CAAC,EAAE,IAAS,EAAE,KAAK,EAAE,EAAE,SAAS,+BAEnE;AAED,wBAAgB,aAAa,CAAC,EAAE,IAAS,EAAE,KAAK,EAAE,EAAE,SAAS,+BAE5D;AAED,wBAAgB,cAAc,CAAC,EAAE,IAAS,EAAE,KAAK,EAAE,EAAE,SAAS,+BAE7D;AAKD,wBAAgB,mBAAmB,CAAC,EAAE,IAAS,EAAE,KAAK,EAAE,EAAE,SAAS,+BAElE;AAUD,wBAAgB,aAAa,CAAC,EAAE,IAAS,EAAE,KAAK,EAAE,EAAE,SAAS,+BAE5D;AAOD,wBAAgB,eAAe,CAAC,EAAE,IAAS,EAAE,KAAK,EAAE,EAAE,SAAS,+BAE9D;AAKD,wBAAgB,oBAAoB,CAAC,EAAE,IAAS,EAAE,KAAK,EAAE,EAAE,SAAS,+BAEnE;AASD,wBAAgB,2BAA2B,CAAC,EAAE,IAAS,EAAE,KAAK,EAAE,EAAE,SAAS,+BAE1E"}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* The export carries opacity but no colour, so the ramp has to be tinted or it
|
|
3
|
-
* falls back to black and vanishes on a dark modal.
|
|
3
|
+
* falls back to black and vanishes on a dark modal. The frame runs the wash
|
|
4
|
+
* top-centre to bottom-left, so the vector is the export's own.
|
|
4
5
|
*/
|
|
5
6
|
export declare function KycIdentityIcon({ color }: {
|
|
6
7
|
color: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"KycIdentityIcon.d.ts","sourceRoot":"","sources":["../../../src/icons/KycIdentityIcon.tsx"],"names":[],"mappings":"AAQA
|
|
1
|
+
{"version":3,"file":"KycIdentityIcon.d.ts","sourceRoot":"","sources":["../../../src/icons/KycIdentityIcon.tsx"],"names":[],"mappings":"AAQA;;;;GAIG;AACH,wBAAgB,eAAe,CAAC,EAAE,KAAK,EAAE,EAAE;IAAE,KAAK,EAAE,MAAM,CAAA;CAAE,+BAS3D"}
|
|
@@ -2,7 +2,7 @@ export type KycStatusGlyph = 'complete' | 'pending' | 'soft' | 'hard' | 'require
|
|
|
2
2
|
export declare function KycStatusIcon({ glyph, color, faded, height: drawn, }: {
|
|
3
3
|
glyph: KycStatusGlyph;
|
|
4
4
|
color?: string;
|
|
5
|
-
/** The card's
|
|
5
|
+
/** The card's brand-to-tint wash; the banner leaves it off. */
|
|
6
6
|
faded?: boolean;
|
|
7
7
|
/** Drawn height; the width follows. The banner omits it, the card sets it. */
|
|
8
8
|
height?: number;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"KycStatusIcon.d.ts","sourceRoot":"","sources":["../../../src/icons/KycStatusIcon.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"KycStatusIcon.d.ts","sourceRoot":"","sources":["../../../src/icons/KycStatusIcon.tsx"],"names":[],"mappings":"AAKA,MAAM,MAAM,cAAc,GACtB,UAAU,GACV,SAAS,GACT,MAAM,GACN,MAAM,GACN,UAAU,CAAA;AAoDd,wBAAgB,aAAa,CAAC,EAC5B,KAAK,EACL,KAAK,EACL,KAAa,EACb,MAAM,EAAE,KAAK,GACd,EAAE;IACD,KAAK,EAAE,cAAc,CAAA;IACrB,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,+DAA+D;IAC/D,KAAK,CAAC,EAAE,OAAO,CAAA;IACf,8EAA8E;IAC9E,MAAM,CAAC,EAAE,MAAM,CAAA;CAChB,+BAmBA"}
|
|
@@ -1,3 +1,18 @@
|
|
|
1
1
|
import type { FunkitTheme } from '../theme/toRestyleTheme';
|
|
2
|
+
/**
|
|
3
|
+
* An 8-digit token in a gradient stop renders opaque black, so the alpha has to
|
|
4
|
+
* ride on `stop-opacity` and only the solid colour reach the stop.
|
|
5
|
+
*/
|
|
6
|
+
export declare const splitColorToken: (token: string) => {
|
|
7
|
+
solid: string;
|
|
8
|
+
alpha: number;
|
|
9
|
+
};
|
|
10
|
+
/** One `<stop>`, with any alpha moved off the colour. */
|
|
11
|
+
export declare const colorStop: (token: string, offset?: number) => string;
|
|
12
|
+
/**
|
|
13
|
+
* Repaints a KYC artwork export's two-stop ramp (Fun Mobile V2, 2812:1236):
|
|
14
|
+
* the host's brand at the top, the text colour at the bottom. The export's own
|
|
15
|
+
* 5–15% opacity is dropped — it makes the symbol vanish on a dark host.
|
|
16
|
+
*/
|
|
2
17
|
export declare function tintKycArtwork(xml: string, theme: FunkitTheme, color?: string): string;
|
|
3
18
|
//# sourceMappingURL=kycArtwork.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"kycArtwork.d.ts","sourceRoot":"","sources":["../../../src/icons/kycArtwork.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"kycArtwork.d.ts","sourceRoot":"","sources":["../../../src/icons/kycArtwork.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,yBAAyB,CAAA;AAE1D;;;GAGG;AACH,eAAO,MAAM,eAAe,GAAI,OAAO,MAAM;;;CAGb,CAAA;AAEhC,yDAAyD;AACzD,eAAO,MAAM,SAAS,GAAI,OAAO,MAAM,EAAE,SAAS,MAAM,WAIvD,CAAA;AAED;;;;GAIG;AACH,wBAAgB,cAAc,CAC5B,GAAG,EAAE,MAAM,EACX,KAAK,EAAE,WAAW,EAClB,KAAK,SAAiC,UAWvC"}
|
|
@@ -51,10 +51,9 @@ export interface FunkitConfig {
|
|
|
51
51
|
*/
|
|
52
52
|
prefillFiatEmail?: string;
|
|
53
53
|
/**
|
|
54
|
-
*
|
|
55
|
-
*
|
|
56
|
-
* derive their recipient from it.
|
|
57
|
-
* has no such option yet.
|
|
54
|
+
* @deprecated Leave `crypto` out of `DepositFlowConfig.methods` instead.
|
|
55
|
+
* Hides the built-in "Crypto" row on Add money; address generation still
|
|
56
|
+
* runs, since the fiat rails derive their recipient from it.
|
|
58
57
|
*/
|
|
59
58
|
hideCryptoDeposit?: boolean;
|
|
60
59
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"IdentityContext.d.ts","sourceRoot":"","sources":["../../../src/identity/IdentityContext.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,SAAS,EAA6B,MAAM,OAAO,CAAA;AAIjE;;;;;GAKG;AACH,MAAM,WAAW,cAAc;IAC7B,sBAAsB;IACtB,MAAM,EAAE,MAAM,CAAA;IACd,sCAAsC;IACtC,MAAM,EAAE,MAAM,CAAA;IACd,8DAA8D;IAC9D,aAAa,EAAE,MAAM,CAAA;IACrB,6DAA6D;IAC7D,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB,iFAAiF;IACjF,gBAAgB,CAAC,EAAE,MAAM,CAAA;IACzB,2EAA2E;IAC3E,iBAAiB,EAAE,OAAO,CAAA;IAC1B,qDAAqD;IACrD,oBAAoB,CAAC,EAAE,MAAM,OAAO,CAAC,MAAM,CAAC,CAAA;CAC7C;AAED;;;;;;;GAOG;AACH,MAAM,WAAW,YAAY;IAC3B,sBAAsB;IACtB,MAAM,EAAE,MAAM,CAAA;IACd;;;;OAIG;IACH,cAAc,CAAC,EAAE,MAAM,CAAA;IACvB,6DAA6D;IAC7D,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB;;;;;;;;OAQG;IACH,gBAAgB,CAAC,EAAE,MAAM,CAAA;IACzB
|
|
1
|
+
{"version":3,"file":"IdentityContext.d.ts","sourceRoot":"","sources":["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