@funkit/connect-rn 9.0.1 → 9.1.1
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 +154 -0
- package/README.md +101 -1
- package/app.plugin.js +92 -0
- package/dist/{chunk-GCPIOARQ.js → chunk-5Y2EMQYX.js} +6 -2
- package/dist/chunk-5Y2EMQYX.js.map +7 -0
- package/dist/{chunk-ZBWCG4O6.js → chunk-OBY3O4LU.js} +60 -6
- package/dist/chunk-OBY3O4LU.js.map +7 -0
- package/dist/{chunk-MMXSERQM.js → chunk-RPYWTS42.js} +441 -481
- package/dist/chunk-RPYWTS42.js.map +7 -0
- package/dist/clients/lighter.js +1 -1
- package/dist/clients/nado.js +2 -2
- package/dist/index.d.ts +1 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +7713 -4510
- package/dist/index.js.map +4 -4
- package/dist/preview.js +595 -15
- package/dist/preview.js.map +3 -3
- package/dist/src/components/v2/PaymentMethodPicker.d.ts +10 -1
- package/dist/src/components/v2/PaymentMethodPicker.d.ts.map +1 -1
- package/dist/src/components/v2/QuickAmountsRow.d.ts +3 -1
- package/dist/src/components/v2/QuickAmountsRow.d.ts.map +1 -1
- package/dist/src/components/v2/methodMerge.d.ts +40 -0
- package/dist/src/components/v2/methodMerge.d.ts.map +1 -0
- package/dist/src/fiat/FiatContactScreen.d.ts.map +1 -1
- package/dist/src/fiat/FiatDocumentCaptureStep.d.ts +2 -1
- package/dist/src/fiat/FiatDocumentCaptureStep.d.ts.map +1 -1
- package/dist/src/fiat/FiatErrorScreen.d.ts +16 -0
- package/dist/src/fiat/FiatErrorScreen.d.ts.map +1 -0
- package/dist/src/fiat/FiatFormFieldRow.d.ts +6 -3
- package/dist/src/fiat/FiatFormFieldRow.d.ts.map +1 -1
- package/dist/src/fiat/FiatFormScreen.d.ts +4 -5
- package/dist/src/fiat/FiatFormScreen.d.ts.map +1 -1
- package/dist/src/fiat/FiatIdentityStep.d.ts +7 -2
- package/dist/src/fiat/FiatIdentityStep.d.ts.map +1 -1
- package/dist/src/fiat/FiatKycIntroLayout.d.ts +34 -0
- package/dist/src/fiat/FiatKycIntroLayout.d.ts.map +1 -0
- package/dist/src/fiat/FiatKycIntroScreen.d.ts +2 -0
- package/dist/src/fiat/FiatKycIntroScreen.d.ts.map +1 -1
- package/dist/src/fiat/FiatKycOptionRow.d.ts.map +1 -1
- package/dist/src/fiat/FiatKycOptionsScreen.d.ts +3 -8
- package/dist/src/fiat/FiatKycOptionsScreen.d.ts.map +1 -1
- package/dist/src/fiat/FiatKycOutcomeScreen.d.ts.map +1 -1
- package/dist/src/fiat/FiatKycPhoneField.d.ts +2 -1
- package/dist/src/fiat/FiatKycPhoneField.d.ts.map +1 -1
- package/dist/src/fiat/FiatOptionsScreen.d.ts +21 -0
- package/dist/src/fiat/FiatOptionsScreen.d.ts.map +1 -0
- package/dist/src/fiat/FiatOtpScreen.d.ts +1 -1
- package/dist/src/fiat/FiatOtpScreen.d.ts.map +1 -1
- package/dist/src/fiat/FiatPaymentFailedSheet.d.ts +26 -0
- package/dist/src/fiat/FiatPaymentFailedSheet.d.ts.map +1 -0
- package/dist/src/fiat/FiatPhoneField.d.ts.map +1 -1
- package/dist/src/fiat/FiatReceipt.d.ts +6 -3
- package/dist/src/fiat/FiatReceipt.d.ts.map +1 -1
- package/dist/src/fiat/FiatRegionUnsupportedScreen.d.ts +3 -1
- package/dist/src/fiat/FiatRegionUnsupportedScreen.d.ts.map +1 -1
- package/dist/src/fiat/FiatSharingConsentNotice.d.ts +3 -0
- package/dist/src/fiat/FiatSharingConsentNotice.d.ts.map +1 -0
- package/dist/src/fiat/FiatStepFailedScreen.d.ts +17 -0
- package/dist/src/fiat/FiatStepFailedScreen.d.ts.map +1 -0
- package/dist/src/fiat/FiatTermsNotice.d.ts +6 -0
- package/dist/src/fiat/FiatTermsNotice.d.ts.map +1 -1
- package/dist/src/fiat/FiatUnavailableScreen.d.ts +14 -0
- package/dist/src/fiat/FiatUnavailableScreen.d.ts.map +1 -0
- package/dist/src/fiat/PaymentDisclosureNotice.d.ts +6 -0
- package/dist/src/fiat/PaymentDisclosureNotice.d.ts.map +1 -0
- package/dist/src/fiat/closeFailure.d.ts +1 -1
- package/dist/src/fiat/closeFailure.d.ts.map +1 -1
- package/dist/src/fiat/ctaLabel.d.ts +2 -0
- package/dist/src/fiat/ctaLabel.d.ts.map +1 -1
- package/dist/src/fiat/depositMatch.d.ts +17 -0
- package/dist/src/fiat/depositMatch.d.ts.map +1 -0
- package/dist/src/fiat/depositOutcome.d.ts +6 -0
- package/dist/src/fiat/depositOutcome.d.ts.map +1 -1
- package/dist/src/fiat/disclosureFooter.d.ts +21 -0
- package/dist/src/fiat/disclosureFooter.d.ts.map +1 -0
- package/dist/src/fiat/disclosureFooterContent.d.ts +28 -0
- package/dist/src/fiat/disclosureFooterContent.d.ts.map +1 -0
- package/dist/src/fiat/formLayout.d.ts +18 -5
- package/dist/src/fiat/formLayout.d.ts.map +1 -1
- package/dist/src/fiat/formScreenProps.d.ts.map +1 -1
- package/dist/src/fiat/kycFormState.d.ts +5 -3
- package/dist/src/fiat/kycFormState.d.ts.map +1 -1
- package/dist/src/fiat/kycOptionRows.d.ts +23 -0
- package/dist/src/fiat/kycOptionRows.d.ts.map +1 -0
- package/dist/src/fiat/kycWait.d.ts +20 -0
- package/dist/src/fiat/kycWait.d.ts.map +1 -0
- package/dist/src/fiat/legalLinks.d.ts +2 -0
- package/dist/src/fiat/legalLinks.d.ts.map +1 -1
- package/dist/src/fiat/paymentReroute.d.ts +22 -4
- package/dist/src/fiat/paymentReroute.d.ts.map +1 -1
- package/dist/src/fiat/paymentSurfaceFailure.d.ts +31 -37
- package/dist/src/fiat/paymentSurfaceFailure.d.ts.map +1 -1
- package/dist/src/fiat/providers/adapter.d.ts +28 -4
- package/dist/src/fiat/providers/adapter.d.ts.map +1 -1
- package/dist/src/fiat/providers/{banxaRedirect.d.ts → banxa/banxaRedirect.d.ts} +1 -1
- package/dist/src/fiat/providers/banxa/banxaRedirect.d.ts.map +1 -0
- package/dist/src/fiat/providers/{CoinbaseCheckoutSurface.d.ts → coinbase/CoinbaseCheckoutSurface.d.ts} +2 -3
- package/dist/src/fiat/providers/coinbase/CoinbaseCheckoutSurface.d.ts.map +1 -0
- package/dist/src/fiat/providers/coinbase/CoinbaseWarmup.d.ts +38 -0
- package/dist/src/fiat/providers/coinbase/CoinbaseWarmup.d.ts.map +1 -0
- package/dist/src/fiat/providers/{coinbaseApplePay.d.ts → coinbase/coinbaseApplePay.d.ts} +1 -1
- package/dist/src/fiat/providers/coinbase/coinbaseApplePay.d.ts.map +1 -0
- package/dist/src/fiat/providers/coinbase/coinbaseCardRefusal.d.ts +2 -0
- package/dist/src/fiat/providers/coinbase/coinbaseCardRefusal.d.ts.map +1 -0
- package/dist/src/fiat/providers/coinbase/coinbaseOnrampEvents.d.ts.map +1 -0
- package/dist/src/fiat/providers/coinbase/coinbasePreparedPayment.d.ts +18 -0
- package/dist/src/fiat/providers/coinbase/coinbasePreparedPayment.d.ts.map +1 -0
- package/dist/src/fiat/providers/coinbase/coinbaseWarmupStore.d.ts +40 -0
- package/dist/src/fiat/providers/coinbase/coinbaseWarmupStore.d.ts.map +1 -0
- package/dist/src/fiat/providers/coinbase/useCoinbaseWarmupGate.d.ts +4 -0
- package/dist/src/fiat/providers/coinbase/useCoinbaseWarmupGate.d.ts.map +1 -0
- package/dist/src/fiat/providers/kycIntro.d.ts +15 -0
- package/dist/src/fiat/providers/kycIntro.d.ts.map +1 -1
- package/dist/src/fiat/providers/{moonpay.d.ts → moonpay/moonpay.d.ts} +4 -2
- package/dist/src/fiat/providers/moonpay/moonpay.d.ts.map +1 -0
- package/dist/src/fiat/providers/moonpay/moonpayApplePayPainted.d.ts.map +1 -0
- package/dist/src/fiat/providers/{moonpayApplePayStyle.d.ts → moonpay/moonpayApplePayStyle.d.ts} +1 -1
- package/dist/src/fiat/providers/moonpay/moonpayApplePayStyle.d.ts.map +1 -0
- package/dist/src/fiat/providers/moonpay/moonpayAuthStyle.d.ts +58 -0
- package/dist/src/fiat/providers/moonpay/moonpayAuthStyle.d.ts.map +1 -0
- package/dist/src/fiat/providers/moonpay/moonpayCardRefusal.d.ts +7 -0
- package/dist/src/fiat/providers/moonpay/moonpayCardRefusal.d.ts.map +1 -0
- package/dist/src/fiat/providers/{moonpayFeeQuote.d.ts → moonpay/moonpayFeeQuote.d.ts} +1 -1
- package/dist/src/fiat/providers/moonpay/moonpayFeeQuote.d.ts.map +1 -0
- package/dist/src/fiat/providers/moonpay/moonpayHandoffCard.d.ts +11 -0
- package/dist/src/fiat/providers/moonpay/moonpayHandoffCard.d.ts.map +1 -0
- package/dist/src/fiat/providers/moonpay/moonpayPaymentDisclosures.d.ts +15 -0
- package/dist/src/fiat/providers/moonpay/moonpayPaymentDisclosures.d.ts.map +1 -0
- package/dist/src/fiat/providers/moonpay/moonpayPreparedPayment.d.ts +7 -0
- package/dist/src/fiat/providers/moonpay/moonpayPreparedPayment.d.ts.map +1 -0
- package/dist/src/fiat/providers/moonpay/moonpaySharingConsent.d.ts +14 -0
- package/dist/src/fiat/providers/moonpay/moonpaySharingConsent.d.ts.map +1 -0
- package/dist/src/fiat/providers/stripe/StripeSessionAuthScreen.d.ts.map +1 -0
- package/dist/src/fiat/providers/stripe/stripeAccountCreation.d.ts +22 -0
- package/dist/src/fiat/providers/stripe/stripeAccountCreation.d.ts.map +1 -0
- package/dist/src/fiat/providers/stripe/stripeApplePayButton.d.ts +15 -0
- package/dist/src/fiat/providers/stripe/stripeApplePayButton.d.ts.map +1 -0
- package/dist/src/fiat/providers/stripe/stripeApplePayReady.d.ts +9 -0
- package/dist/src/fiat/providers/stripe/stripeApplePayReady.d.ts.map +1 -0
- package/dist/src/fiat/providers/{stripeAuthorize.d.ts → stripe/stripeAuthorize.d.ts} +1 -1
- package/dist/src/fiat/providers/stripe/stripeAuthorize.d.ts.map +1 -0
- package/dist/src/fiat/providers/stripe/stripeCardRefusal.d.ts +2 -0
- package/dist/src/fiat/providers/stripe/stripeCardRefusal.d.ts.map +1 -0
- package/dist/src/fiat/providers/{stripeCheckout.d.ts → stripe/stripeCheckout.d.ts} +1 -1
- package/dist/src/fiat/providers/stripe/stripeCheckout.d.ts.map +1 -0
- package/dist/src/fiat/providers/stripe/stripeErrorDetail.d.ts +6 -0
- package/dist/src/fiat/providers/stripe/stripeErrorDetail.d.ts.map +1 -0
- package/dist/src/fiat/providers/{stripeKyc.d.ts → stripe/stripeKyc.d.ts} +1 -1
- package/dist/src/fiat/providers/stripe/stripeKyc.d.ts.map +1 -0
- package/dist/src/fiat/providers/stripe/stripeKycInfo.d.ts.map +1 -0
- package/dist/src/fiat/providers/stripe/stripeKycIntro.d.ts +32 -0
- package/dist/src/fiat/providers/stripe/stripeKycIntro.d.ts.map +1 -0
- package/dist/src/fiat/providers/{stripeOnramp.d.ts → stripe/stripeOnramp.d.ts} +14 -0
- package/dist/src/fiat/providers/stripe/stripeOnramp.d.ts.map +1 -0
- package/dist/src/fiat/providers/stripe/stripeOnrampBridge.d.ts.map +1 -0
- package/dist/src/fiat/providers/{stripePayment.d.ts → stripe/stripePayment.d.ts} +1 -3
- package/dist/src/fiat/providers/stripe/stripePayment.d.ts.map +1 -0
- package/dist/src/fiat/providers/{stripeRoundPush.d.ts → stripe/stripeRoundPush.d.ts} +10 -4
- package/dist/src/fiat/providers/stripe/stripeRoundPush.d.ts.map +1 -0
- package/dist/src/fiat/providers/{stripeSdk.d.ts → stripe/stripeSdk.d.ts} +1 -1
- package/dist/src/fiat/providers/stripe/stripeSdk.d.ts.map +1 -0
- package/dist/src/fiat/providers/stripe/stripeSeamlessSignIn.d.ts.map +1 -0
- package/dist/src/fiat/providers/stripe/stripeSessionAuth.d.ts.map +1 -0
- package/dist/src/fiat/providers/stripe/stripeSignInStep.d.ts +23 -0
- package/dist/src/fiat/providers/stripe/stripeSignInStep.d.ts.map +1 -0
- package/dist/src/fiat/providers/stripe/useCreateStripeAccountWithExistingUserData.d.ts +41 -0
- package/dist/src/fiat/providers/stripe/useCreateStripeAccountWithExistingUserData.d.ts.map +1 -0
- package/dist/src/fiat/providers/{useStripeOnrampClient.d.ts → stripe/useStripeOnrampClient.d.ts} +1 -1
- package/dist/src/fiat/providers/stripe/useStripeOnrampClient.d.ts.map +1 -0
- package/dist/src/fiat/providers/{useStripeSessionAuth.d.ts → stripe/useStripeSessionAuth.d.ts} +2 -8
- package/dist/src/fiat/providers/stripe/useStripeSessionAuth.d.ts.map +1 -0
- package/dist/src/fiat/providers/sumsub/SumsubKycSurface.d.ts.map +1 -0
- package/dist/src/fiat/providers/sumsub/SumsubNativeKycSurface.d.ts +23 -0
- package/dist/src/fiat/providers/sumsub/SumsubNativeKycSurface.d.ts.map +1 -0
- package/dist/src/fiat/providers/{sumsubKyc.d.ts → sumsub/sumsubKyc.d.ts} +7 -1
- package/dist/src/fiat/providers/sumsub/sumsubKyc.d.ts.map +1 -0
- package/dist/src/fiat/providers/sumsub/sumsubNativeLaunch.d.ts +34 -0
- package/dist/src/fiat/providers/sumsub/sumsubNativeLaunch.d.ts.map +1 -0
- package/dist/src/fiat/providers/sumsub/sumsubSdk.d.ts +58 -0
- package/dist/src/fiat/providers/sumsub/sumsubSdk.d.ts.map +1 -0
- package/dist/src/fiat/providers/sumsub/sumsubTheme.d.ts +51 -0
- package/dist/src/fiat/providers/sumsub/sumsubTheme.d.ts.map +1 -0
- package/dist/src/fiat/providers/transak/TransakApplePaySurface.d.ts.map +1 -0
- package/dist/src/fiat/providers/{transakApplePay.d.ts → transak/transakApplePay.d.ts} +1 -1
- package/dist/src/fiat/providers/transak/transakApplePay.d.ts.map +1 -0
- package/dist/src/fiat/quoteNoRoute.d.ts +10 -0
- package/dist/src/fiat/quoteNoRoute.d.ts.map +1 -1
- package/dist/src/fiat/refusedFields.d.ts +9 -0
- package/dist/src/fiat/refusedFields.d.ts.map +1 -0
- package/dist/src/fiat/renderCaptureSurface.d.ts +3 -1
- package/dist/src/fiat/renderCaptureSurface.d.ts.map +1 -1
- package/dist/src/fiat/sectionDetail.d.ts +3 -1
- package/dist/src/fiat/sectionDetail.d.ts.map +1 -1
- package/dist/src/fiat/shownFieldIssues.d.ts +3 -2
- package/dist/src/fiat/shownFieldIssues.d.ts.map +1 -1
- package/dist/src/fiat/stepDetails.d.ts +25 -4
- package/dist/src/fiat/stepDetails.d.ts.map +1 -1
- package/dist/src/fiat/useIdentityAssertion.d.ts.map +1 -1
- package/dist/src/fiat/useKycCaptureRound.d.ts.map +1 -1
- package/dist/src/fiat/useKycRoundReporting.d.ts +12 -0
- package/dist/src/fiat/useKycRoundReporting.d.ts.map +1 -0
- package/dist/src/fiat/usePaymentFailureAnswer.d.ts +71 -0
- package/dist/src/fiat/usePaymentFailureAnswer.d.ts.map +1 -0
- package/dist/src/fiat/useReceiptTitles.d.ts.map +1 -1
- package/dist/src/fiat/useResendCooldown.d.ts +25 -0
- package/dist/src/fiat/useResendCooldown.d.ts.map +1 -0
- package/dist/src/fiat/useSharingConsent.d.ts +15 -0
- package/dist/src/fiat/useSharingConsent.d.ts.map +1 -0
- package/dist/src/fiat/useStandingRefusals.d.ts +5 -0
- package/dist/src/fiat/useStandingRefusals.d.ts.map +1 -0
- package/dist/src/flow/DepositFlowContent.d.ts.map +1 -1
- package/dist/src/flow/DepositMatchSheet.d.ts +12 -0
- package/dist/src/flow/DepositMatchSheet.d.ts.map +1 -0
- package/dist/src/flow/DepositPreload.d.ts +13 -0
- package/dist/src/flow/DepositPreload.d.ts.map +1 -0
- package/dist/src/flow/Drawer.d.ts +7 -1
- package/dist/src/flow/Drawer.d.ts.map +1 -1
- package/dist/src/flow/FiatDepositAmountStep.d.ts +2 -5
- package/dist/src/flow/FiatDepositAmountStep.d.ts.map +1 -1
- package/dist/src/flow/FunkitFlowProvider.d.ts +6 -2
- package/dist/src/flow/FunkitFlowProvider.d.ts.map +1 -1
- package/dist/src/flow/WithdrawalFlowContent.d.ts.map +1 -1
- package/dist/src/flow/depositFlowConfig.d.ts +11 -3
- package/dist/src/flow/depositFlowConfig.d.ts.map +1 -1
- package/dist/src/flow/depositMethods.d.ts +8 -0
- package/dist/src/flow/depositMethods.d.ts.map +1 -1
- package/dist/src/flow/overlayStep.d.ts +25 -0
- package/dist/src/flow/overlayStep.d.ts.map +1 -0
- package/dist/src/flow/pageTurn.d.ts +19 -2
- package/dist/src/flow/pageTurn.d.ts.map +1 -1
- package/dist/src/flow/quickAmounts.d.ts +8 -0
- package/dist/src/flow/quickAmounts.d.ts.map +1 -0
- package/dist/src/flow/storedChain.d.ts +14 -0
- package/dist/src/flow/storedChain.d.ts.map +1 -0
- package/dist/src/flow/useKeyboardHeight.d.ts.map +1 -1
- package/dist/src/flow/withdrawalFlowConfig.d.ts +3 -1
- package/dist/src/flow/withdrawalFlowConfig.d.ts.map +1 -1
- package/dist/src/flow/withdrawalMethods.d.ts +8 -0
- package/dist/src/flow/withdrawalMethods.d.ts.map +1 -0
- package/dist/src/geo/useUserIpInfo.d.ts +7 -0
- package/dist/src/geo/useUserIpInfo.d.ts.map +1 -1
- package/dist/src/hooks/useNestedSheetHeight.d.ts +14 -0
- package/dist/src/hooks/useNestedSheetHeight.d.ts.map +1 -1
- package/dist/src/icons/ApplePayMark.d.ts +3 -1
- package/dist/src/icons/ApplePayMark.d.ts.map +1 -1
- package/dist/src/icons/KycOutcomeIcon.d.ts.map +1 -1
- package/dist/src/preview/fixtures/kycForms.d.ts +2 -0
- package/dist/src/preview/fixtures/kycForms.d.ts.map +1 -1
- package/dist/src/preview/flowPreview.d.ts +10 -3
- package/dist/src/preview/flowPreview.d.ts.map +1 -1
- package/dist/src/preview/previewFetch.d.ts.map +1 -1
- package/dist/src/preview/scenarioCatalog.d.ts +117 -3
- package/dist/src/preview/scenarioCatalog.d.ts.map +1 -1
- package/dist/src/preview/scenarios.d.ts +33 -3
- package/dist/src/preview/scenarios.d.ts.map +1 -1
- package/dist/src/providers/FunkitProvider.d.ts +1 -1
- package/dist/src/providers/FunkitProvider.d.ts.map +1 -1
- package/dist/src/providers/NativeCapabilitiesContext.d.ts +1 -1
- package/dist/src/providers/NativeCapabilitiesContext.d.ts.map +1 -1
- package/dist/src/screens/DepositAmountScreen.d.ts +28 -4
- package/dist/src/screens/DepositAmountScreen.d.ts.map +1 -1
- package/dist/src/screens/DepositMatchScreen.d.ts +20 -0
- package/dist/src/screens/DepositMatchScreen.d.ts.map +1 -0
- package/dist/src/screens/FeeDetailsScreen.d.ts +4 -0
- package/dist/src/screens/FeeDetailsScreen.d.ts.map +1 -1
- package/dist/src/swapped/SwappedWebView.d.ts +2 -2
- package/dist/src/swapped/webViewSwappedTransport.d.ts +4 -35
- package/dist/src/swapped/webViewSwappedTransport.d.ts.map +1 -1
- package/dist/src/theme/FunkitThemeProvider.d.ts +6 -0
- package/dist/src/theme/FunkitThemeProvider.d.ts.map +1 -1
- package/dist/src/theme/buildFunkitTheme.d.ts +3 -0
- package/dist/src/theme/buildFunkitTheme.d.ts.map +1 -1
- package/dist/src/theme/legibleBrandColor.d.ts +12 -0
- package/dist/src/theme/legibleBrandColor.d.ts.map +1 -0
- package/dist/src/theme/restyle.d.ts +99 -0
- package/dist/src/theme/restyle.d.ts.map +1 -1
- package/dist/src/theme/toRestyleTheme.d.ts +9 -0
- package/dist/src/theme/toRestyleTheme.d.ts.map +1 -1
- package/dist/src/theme/typeScale.d.ts +18 -0
- package/dist/src/theme/typeScale.d.ts.map +1 -1
- package/dist/src/utils/formatAmount.d.ts +2 -0
- package/dist/src/utils/formatAmount.d.ts.map +1 -1
- package/ios/FunkitGlassEffect.podspec +2 -0
- package/ios/assets/funkit-connect-rn/sumsub-back.png +0 -0
- package/package.json +16 -8
- package/dist/chunk-GCPIOARQ.js.map +0 -7
- package/dist/chunk-MMXSERQM.js.map +0 -7
- package/dist/chunk-ZBWCG4O6.js.map +0 -7
- package/dist/src/fiat/FiatKycPosition.d.ts +0 -7
- package/dist/src/fiat/FiatKycPosition.d.ts.map +0 -1
- package/dist/src/fiat/kycWalk.d.ts +0 -22
- package/dist/src/fiat/kycWalk.d.ts.map +0 -1
- package/dist/src/fiat/providers/CoinbaseCheckoutSurface.d.ts.map +0 -1
- package/dist/src/fiat/providers/StripeSessionAuthScreen.d.ts.map +0 -1
- package/dist/src/fiat/providers/SumsubKycSurface.d.ts.map +0 -1
- package/dist/src/fiat/providers/TransakApplePaySurface.d.ts.map +0 -1
- package/dist/src/fiat/providers/banxaRedirect.d.ts.map +0 -1
- package/dist/src/fiat/providers/coinbaseApplePay.d.ts.map +0 -1
- package/dist/src/fiat/providers/coinbaseFailureCopy.d.ts +0 -25
- package/dist/src/fiat/providers/coinbaseFailureCopy.d.ts.map +0 -1
- package/dist/src/fiat/providers/coinbaseOnrampEvents.d.ts.map +0 -1
- package/dist/src/fiat/providers/moonpay.d.ts.map +0 -1
- package/dist/src/fiat/providers/moonpayApplePayPainted.d.ts.map +0 -1
- package/dist/src/fiat/providers/moonpayApplePayStyle.d.ts.map +0 -1
- package/dist/src/fiat/providers/moonpayAuthStyle.d.ts +0 -19
- package/dist/src/fiat/providers/moonpayAuthStyle.d.ts.map +0 -1
- package/dist/src/fiat/providers/moonpayFailureCopy.d.ts +0 -15
- package/dist/src/fiat/providers/moonpayFailureCopy.d.ts.map +0 -1
- package/dist/src/fiat/providers/moonpayFeeQuote.d.ts.map +0 -1
- package/dist/src/fiat/providers/stripeAccountCreation.d.ts +0 -12
- package/dist/src/fiat/providers/stripeAccountCreation.d.ts.map +0 -1
- package/dist/src/fiat/providers/stripeAuthorize.d.ts.map +0 -1
- package/dist/src/fiat/providers/stripeCheckout.d.ts.map +0 -1
- package/dist/src/fiat/providers/stripeFailureCopy.d.ts +0 -16
- package/dist/src/fiat/providers/stripeFailureCopy.d.ts.map +0 -1
- package/dist/src/fiat/providers/stripeKyc.d.ts.map +0 -1
- package/dist/src/fiat/providers/stripeKycInfo.d.ts.map +0 -1
- package/dist/src/fiat/providers/stripeKycIntro.d.ts +0 -10
- package/dist/src/fiat/providers/stripeKycIntro.d.ts.map +0 -1
- package/dist/src/fiat/providers/stripeOnramp.d.ts.map +0 -1
- package/dist/src/fiat/providers/stripeOnrampBridge.d.ts.map +0 -1
- package/dist/src/fiat/providers/stripePayment.d.ts.map +0 -1
- package/dist/src/fiat/providers/stripeRoundPush.d.ts.map +0 -1
- package/dist/src/fiat/providers/stripeSdk.d.ts.map +0 -1
- package/dist/src/fiat/providers/stripeSeamlessSignIn.d.ts.map +0 -1
- package/dist/src/fiat/providers/stripeSessionAuth.d.ts.map +0 -1
- package/dist/src/fiat/providers/sumsubKyc.d.ts.map +0 -1
- package/dist/src/fiat/providers/transakApplePay.d.ts.map +0 -1
- package/dist/src/fiat/providers/useStripeOnrampClient.d.ts.map +0 -1
- package/dist/src/fiat/providers/useStripeSessionAuth.d.ts.map +0 -1
- /package/dist/src/fiat/providers/{coinbaseOnrampEvents.d.ts → coinbase/coinbaseOnrampEvents.d.ts} +0 -0
- /package/dist/src/fiat/providers/{moonpayApplePayPainted.d.ts → moonpay/moonpayApplePayPainted.d.ts} +0 -0
- /package/dist/src/fiat/providers/{StripeSessionAuthScreen.d.ts → stripe/StripeSessionAuthScreen.d.ts} +0 -0
- /package/dist/src/fiat/providers/{stripeKycInfo.d.ts → stripe/stripeKycInfo.d.ts} +0 -0
- /package/dist/src/fiat/providers/{stripeOnrampBridge.d.ts → stripe/stripeOnrampBridge.d.ts} +0 -0
- /package/dist/src/fiat/providers/{stripeSeamlessSignIn.d.ts → stripe/stripeSeamlessSignIn.d.ts} +0 -0
- /package/dist/src/fiat/providers/{stripeSessionAuth.d.ts → stripe/stripeSessionAuth.d.ts} +0 -0
- /package/dist/src/fiat/providers/{SumsubKycSurface.d.ts → sumsub/SumsubKycSurface.d.ts} +0 -0
- /package/dist/src/fiat/providers/{TransakApplePaySurface.d.ts → transak/TransakApplePaySurface.d.ts} +0 -0
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,159 @@
|
|
|
1
1
|
# @funkit/connect-rn
|
|
2
2
|
|
|
3
|
+
## 9.1.1
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- cdcfffa: No consumer-facing changes.
|
|
8
|
+
- b915315: No consumer-facing changes.
|
|
9
|
+
- 792b1cf: No consumer-facing changes.
|
|
10
|
+
- 0f40901: No consumer-facing changes.
|
|
11
|
+
- fc2addd: No consumer-facing changes.
|
|
12
|
+
- d92a3c0: No consumer-facing changes.
|
|
13
|
+
- 31755eb: No consumer-facing changes.
|
|
14
|
+
- 180c23e: Coinbase Apple Pay shows its pay button without a second request when the quote already carries the payment session.
|
|
15
|
+
- d786575: Add a way to load Coinbase's Apple Pay button sooner.
|
|
16
|
+
- 4c2c64e: No consumer-facing changes.
|
|
17
|
+
- 84bac60: Rename the deposit amount screen's "Change to maximum" action to "Deposit Max".
|
|
18
|
+
- 64f0659: Rename the deposit amount screen's "Change to minimum" action to "Deposit Min".
|
|
19
|
+
- 8f26c47: No consumer-facing changes.
|
|
20
|
+
- afe1638: No consumer-facing changes.
|
|
21
|
+
- f2a0f19: Stop reopening the provider's payment page after an Apple Pay payment, and give a paid order that fails with no recovery a way back to the amount: "Try again" with a new quote when it can be retried, "Done" when it cannot.
|
|
22
|
+
- 20f085d: Show fiat deposit prices right away for buyers on a fresh install.
|
|
23
|
+
- 15d4bc7: No consumer-facing changes.
|
|
24
|
+
- a2ebd7e: No consumer-facing changes.
|
|
25
|
+
- 862ed94: No consumer-facing changes.
|
|
26
|
+
- 628dcf9: No consumer-facing changes.
|
|
27
|
+
- 976e3a5: No consumer-facing changes.
|
|
28
|
+
- 46cc128: Treat a KYC step answered by the order call as a payment that was never taken, so a KYC call that fails after it is retried as KYC instead of replayed as a charge (ENG-6743).
|
|
29
|
+
- 526493a: Highlight the refused detail and say which one in a one-line notice when a KYC form submission is refused.
|
|
30
|
+
- 2bb575b: No consumer-facing changes.
|
|
31
|
+
- 128f5c9: No consumer-facing changes.
|
|
32
|
+
- 46be8d1: No consumer-facing changes.
|
|
33
|
+
- 6e71bc1: MoonPay Apple Pay keeps working after the buyer switches apps and comes back.
|
|
34
|
+
- 4e86e6a: No consumer-facing changes.
|
|
35
|
+
- 532a981: Show the payment-failed screen for orders that fail, expire, or are refunded after Apple Pay completes.
|
|
36
|
+
- b2875c1: No consumer-facing changes.
|
|
37
|
+
- 81476cd: No consumer-facing changes.
|
|
38
|
+
- fb18139: No consumer-facing changes.
|
|
39
|
+
- 4eca6d3: No consumer-facing changes.
|
|
40
|
+
- 7b6bfc8: No consumer-facing changes.
|
|
41
|
+
- 63bf53b: The fiat amount screen asks for identity verification on a deposit above one provider's limit, instead of capping it at that limit.
|
|
42
|
+
- 3a1fb26: No consumer-facing changes.
|
|
43
|
+
- 23064e7: No consumer-facing changes.
|
|
44
|
+
- 87fdc2b: Log when Stripe's Apple Pay button is ready to press.
|
|
45
|
+
- 008a83b: No consumer-facing changes.
|
|
46
|
+
- bd11373: No consumer-facing changes.
|
|
47
|
+
- b7992b8: No consumer-facing changes.
|
|
48
|
+
- 7f1c833: No consumer-facing changes.
|
|
49
|
+
- 74b8168: No consumer-facing changes.
|
|
50
|
+
- e7ec68c: No consumer-facing changes.
|
|
51
|
+
- 80537cc: Fix the refused KYC phone field drawing its number in white on the yellow highlight; it now reads dark like the other KYC fields.
|
|
52
|
+
- 7693407: Deposit fee line reads "$50 bonus if eligible" on a matched deposit and "~~$1.00 fee~~ FREE" on a subsidized one
|
|
53
|
+
- 758805c: Drop "No fees" from the deposit match drawer when the quote is unsubsidized
|
|
54
|
+
- d23b5b0: Show a subsidized fiat fee as free, with or without the deposit match
|
|
55
|
+
- 62f8aae: Show the fee subsidy on MoonPay deposits that sign in before paying
|
|
56
|
+
- 7b0e593: Stop a subsidized deposit's total from exceeding the charge when the provider's fee isn't fully itemized
|
|
57
|
+
- 28a241f: Every full-screen fiat error now reports an error log.
|
|
58
|
+
- 05b1128: Centre the one-time code digits in their boxes and the phone field's flag beside the dial code.
|
|
59
|
+
- 33c894c: An amount between two providers' ranges is under the upper range's minimum: the amount screen names that floor and offers "Change to minimum", instead of the nearer edge.
|
|
60
|
+
- 66126c1: Send a rate-limited fiat step once and ask the buyer to wait for the time the backend names; any other 429 fails as before.
|
|
61
|
+
- a245240: Region, ineligible-account and unavailable-deposit screens say why and offer the host's other payment methods.
|
|
62
|
+
- d0eb3fc: A fiat step or provider page that fails before payment now shows the payment-failed screen, offering to try again or pick a different payment method.
|
|
63
|
+
- 5bc0d0b: The verification banner no longer names a deposit limit after identity verification; it named the route's maximum instead of the buyer's.
|
|
64
|
+
- 75ff0e7: Keep MoonPay's card check below the status bar on iPhone, so its close button stays visible.
|
|
65
|
+
- 43a83b1: Show the quick-amount chips loading while the buyer's currency is looked up, instead of a disabled "Enter an amount" button.
|
|
66
|
+
- 724d43b: Continue a deposit with a provider that serves the amount when the one a buyer just signed in to refuses it over its cap, instead of offering "Change to maximum".
|
|
67
|
+
- 3db4010: Keep the search bar at the bottom of the country and state pickers when they open while the keyboard is still closing.
|
|
68
|
+
- 3523eb6: Fill a Stripe identity round from what the backend already holds, and push it without a form when every required field is held. A form is never left showing only an optional field.
|
|
69
|
+
- 543ed57: Show Stripe's own reason when it refuses a Link registration or KYC push, tell a rate-limited buyer to wait instead of to check their details, and log every message Stripe attaches to a failure.
|
|
70
|
+
- d5f8f54: Keep the amount screen in place while a Stripe Link account is created from details already on file, instead of turning a page onto a copy of it.
|
|
71
|
+
- Updated dependencies [dabbef7]
|
|
72
|
+
- Updated dependencies [eda0f63]
|
|
73
|
+
- Updated dependencies [20f085d]
|
|
74
|
+
- Updated dependencies [d786575]
|
|
75
|
+
- Updated dependencies [6a11ead]
|
|
76
|
+
- Updated dependencies [180c23e]
|
|
77
|
+
- Updated dependencies [619c66f]
|
|
78
|
+
- Updated dependencies [9fade05]
|
|
79
|
+
- Updated dependencies [ecd661d]
|
|
80
|
+
- Updated dependencies [33c894c]
|
|
81
|
+
- Updated dependencies [66126c1]
|
|
82
|
+
- Updated dependencies [5bc0d0b]
|
|
83
|
+
- Updated dependencies [724d43b]
|
|
84
|
+
- @funkit/api-base@9.0.0
|
|
85
|
+
- @funkit/connect-core@9.0.0
|
|
86
|
+
|
|
87
|
+
## 9.1.0
|
|
88
|
+
|
|
89
|
+
### Minor Changes
|
|
90
|
+
|
|
91
|
+
- 4f31cae: MoonPay's required payment disclosures are shown instead of failing the payment.
|
|
92
|
+
- 4f31cae: The deposit amount, quick amounts and limits are written in the buyer's own currency.
|
|
93
|
+
- 4f31cae: The tax ID step names the tax ID the buyer's country uses and lets them type letters where it has them.
|
|
94
|
+
- 6866896: Ask MoonPay's net-worth question on its own page; iOS hosts must declare photo library access for Sumsub document uploads.
|
|
95
|
+
- 20a4d9c: Ask MoonPay buyers for document-sharing consent before ID and selfie capture.
|
|
96
|
+
- da26152: A failed Apple Pay payment now offers a choice to try another card or request a new quote
|
|
97
|
+
- 355d69b: A failed Apple Pay payment opens a full screen offering another card, a new quote when another provider can price it, or the host's payment-method picker when none can.
|
|
98
|
+
- b84836e: Run Sumsub identity capture in Sumsub's native SDK, themed from the host's theme, when `@sumsub/react-native-mobilesdk-module` is installed, with an Expo config plugin for its native setup
|
|
99
|
+
- 496f340: Report the outcome of Sumsub document capture to the backend.
|
|
100
|
+
|
|
101
|
+
### Patch Changes
|
|
102
|
+
|
|
103
|
+
- 50c74d0: Add a deposit-match drawer that shows the waived fee and the bonus total.
|
|
104
|
+
- ccf7f04: The deposit amount screen can call out a deposit match in green on its fee line.
|
|
105
|
+
- 84a797a: The fiat amount screen can preview a deposit match and waived fee.
|
|
106
|
+
- bcbd0f3: When an amount falls between providers' ranges, buyers can change it to the nearest amount a provider serves.
|
|
107
|
+
- 429dc32: Refresh routing limits using authenticated provider information when available.
|
|
108
|
+
- 9609cdc: Fiat KYC, contact, OTP, receipt and Stripe Link screens no longer drag under a finger when their content already fits the screen.
|
|
109
|
+
- 9cef7e9: Keep the KYC Continue button flush over the keyboard: it now follows the keyboard down when the iOS suggestion row closes instead of holding the row's height.
|
|
110
|
+
- d16cefa: Show the new deposit limit on the banner after identity verification passes.
|
|
111
|
+
- 19f136d: After MoonPay's sharing consent, identity verification opens only when the buyer taps its button.
|
|
112
|
+
- b947fc2: Show a KYC round the provider sent back for correction with every field and its notice, including one that returns after the verifying screen
|
|
113
|
+
- 4384bcb: A Stripe buyer sent from the quick check straight on to the next round opens it on its fields, without a second faceplate.
|
|
114
|
+
- 5705269: Remove the "Have any questions?" link from the KYC review and hold screens
|
|
115
|
+
- 0fd8f33: Stop the name page flashing up when a KYC round whose name was already given is submitted
|
|
116
|
+
- 031f333: Keep the ID verification banner in progress after a recheck until the deposit can be paid, instead of briefly showing it as completed.
|
|
117
|
+
- 30047c2: Remove the step indicator dots from the KYC screens; a supplemental round made them read as a walk that never ended.
|
|
118
|
+
- 3a7271b: Verification screens now slide forward, and leaving them for the amount slides back
|
|
119
|
+
- 2e0ecca: While identity details are being verified, the screen tells the buyer they may be asked for more information.
|
|
120
|
+
- fe7bd78: When no provider will take the selected payment method, the amount screen folds its action into the payment-method row instead of showing a disabled "not available" button: the row drops the method for "Pick a payment method", and a toast says to try a different method.
|
|
121
|
+
- c2b0d16: MoonPay's hosted identity check now opens for the signed-in customer instead of closing straight away.
|
|
122
|
+
- 3da0768: MoonPay's hosted identity check now fills the screen, draws in the host's theme, and has a back button.
|
|
123
|
+
- 5c31014: Resume deposits after completing MoonPay identity verification and describe further verification without implying rejection.
|
|
124
|
+
- 38acaef: The fiat amount screen no longer shows the "Identity Verification Required" or "ID Verification in Progress" toasts; the button says it instead.
|
|
125
|
+
- cf21cbc: The fiat code screen stays put on a resend, shows "Sending…", then waits 60 seconds before another resend
|
|
126
|
+
- 88b2cce: A fiat deposit whose provider stops sending verification codes now explains the wait on a banner, and Continue retries once it passes.
|
|
127
|
+
- d7aa455: Stripe Apple Pay deposits use Apple's native "Pay with Apple Pay" button
|
|
128
|
+
- c3e65a5: Open the crypto-only deposit picker already populated instead of on a loading state
|
|
129
|
+
- 4c1f95f: Fix preview scenarios ending on "Try again" when they re-quote with fiat routing on.
|
|
130
|
+
- aef0114: Open crypto-only deposits on the crypto picker instead of the Add money screen
|
|
131
|
+
- c3e65a5: Open a withdrawal with only one crypto method on the amount step instead of the method list
|
|
132
|
+
- 7246d1c: Fail a refused Stripe identity check over to the next provider from the amount screen, instead of ending the flow on a support screen
|
|
133
|
+
- aa97719: Closing Stripe's code sheet goes back to the amount instead of a "Continue with Stripe" page whose only action reopened the same sheet.
|
|
134
|
+
- cc68c6a: Stripe buyers no longer retype account details Fun already holds when creating a Link account.
|
|
135
|
+
- 32e18d4: Stripe's Link code sheet opens over the screen that asked for it, such as the phone number the buyer just typed, instead of sending them back to the amount screen first.
|
|
136
|
+
- e9f096f: Keep Stripe's account form up after the buyer sends it, so its Link code sheet opens over that form instead of the amount screen
|
|
137
|
+
- c452755: Stop routing a fiat deposit to Stripe when the host passes no Stripe config
|
|
138
|
+
- 73d2148: Sumsub's native verification screen now closes with Fun's back chevron, on the left.
|
|
139
|
+
- 8d223a7: Closing a verification sheet that opens over the app returns to its introduction instead of the deposit amount.
|
|
140
|
+
- b84836e: Match the Sumsub WebView identity capture to Fun's colors, Inter type and rounded controls
|
|
141
|
+
- 2a14614: Fix card payments timing out after 15 seconds in the Swapped WebView.
|
|
142
|
+
- 4f31cae: The deposit footer shows a quote's payment disclosures beside the Apple Pay button and the provider's short terms everywhere else.
|
|
143
|
+
- Updated dependencies [08cdd7d]
|
|
144
|
+
- Updated dependencies [429dc32]
|
|
145
|
+
- Updated dependencies [429dc32]
|
|
146
|
+
- Updated dependencies [8ac4858]
|
|
147
|
+
- Updated dependencies [19f136d]
|
|
148
|
+
- Updated dependencies [20a4d9c]
|
|
149
|
+
- Updated dependencies [cf21cbc]
|
|
150
|
+
- Updated dependencies [4f4c319]
|
|
151
|
+
- Updated dependencies [cc68c6a]
|
|
152
|
+
- Updated dependencies [496f340]
|
|
153
|
+
- @funkit/api-base@8.7.0
|
|
154
|
+
- @funkit/connect-core@8.7.0
|
|
155
|
+
- @funkit/chains@2.5.0
|
|
156
|
+
|
|
3
157
|
## 9.0.1
|
|
4
158
|
|
|
5
159
|
### Patch Changes
|
package/README.md
CHANGED
|
@@ -140,6 +140,102 @@ import 'react-native-get-random-values'
|
|
|
140
140
|
MoonPay 1.17.0 includes the `about:srcdoc` WebView origin allowance. Consumers no
|
|
141
141
|
longer need a dependency patch for MoonPay's authorization frame.
|
|
142
142
|
|
|
143
|
+
## Identity verification permissions (iOS)
|
|
144
|
+
|
|
145
|
+
Sumsub's document capture photographs an ID, takes a selfie and uploads documents
|
|
146
|
+
such as proof of address, so iOS hosts must declare both usage strings:
|
|
147
|
+
|
|
148
|
+
```json
|
|
149
|
+
{
|
|
150
|
+
"expo": {
|
|
151
|
+
"ios": {
|
|
152
|
+
"infoPlist": {
|
|
153
|
+
"NSCameraUsageDescription": "Used to photograph your ID and take a selfie when identity verification is required for a deposit.",
|
|
154
|
+
"NSPhotoLibraryUsageDescription": "Used to upload a photo of your ID or a document such as proof of address when identity verification is required for a deposit."
|
|
155
|
+
}
|
|
156
|
+
}
|
|
157
|
+
}
|
|
158
|
+
}
|
|
159
|
+
```
|
|
160
|
+
|
|
161
|
+
In bare React Native, add the same two keys to `ios/<App>/Info.plist`.
|
|
162
|
+
|
|
163
|
+
## Sumsub's native SDK (optional)
|
|
164
|
+
|
|
165
|
+
Sumsub's identity capture runs in a WebView by default. Its WebSDK takes no
|
|
166
|
+
colors, fonts or radii from code, so it never matches your theme. Install
|
|
167
|
+
Sumsub's mobile SDK and the same step opens Sumsub's native screens, themed
|
|
168
|
+
from your connect-rn theme (light/dark colors, brand overrides, Inter, button
|
|
169
|
+
and card radii).
|
|
170
|
+
|
|
171
|
+
`@sumsub/react-native-mobilesdk-module` is an **optional peer**. Without it, or
|
|
172
|
+
in a binary that doesn't link it (Expo Go included), Sumsub stays in the
|
|
173
|
+
WebView, unchanged. Sumsub's screens present modally over your app, so our back
|
|
174
|
+
button and step dots don't show on them; closing Sumsub before submitting
|
|
175
|
+
counts as a cancel.
|
|
176
|
+
|
|
177
|
+
### Expo
|
|
178
|
+
|
|
179
|
+
```sh
|
|
180
|
+
npx expo install @sumsub/react-native-mobilesdk-module
|
|
181
|
+
```
|
|
182
|
+
|
|
183
|
+
Add connect-rn's config plugin, and embed the Inter cuts natively with
|
|
184
|
+
`expo-font` — Sumsub's native screens can't see a font loaded at runtime:
|
|
185
|
+
|
|
186
|
+
```json
|
|
187
|
+
{
|
|
188
|
+
"expo": {
|
|
189
|
+
"plugins": [
|
|
190
|
+
[
|
|
191
|
+
"expo-font",
|
|
192
|
+
{
|
|
193
|
+
"fonts": [
|
|
194
|
+
"node_modules/@expo-google-fonts/inter/400Regular/Inter_400Regular.ttf",
|
|
195
|
+
"node_modules/@expo-google-fonts/inter/500Medium/Inter_500Medium.ttf",
|
|
196
|
+
"node_modules/@expo-google-fonts/inter/600SemiBold/Inter_600SemiBold.ttf"
|
|
197
|
+
]
|
|
198
|
+
}
|
|
199
|
+
],
|
|
200
|
+
[
|
|
201
|
+
"@funkit/connect-rn",
|
|
202
|
+
{
|
|
203
|
+
"sumsub": {
|
|
204
|
+
"cameraPermission": "Used to photograph your ID and take a selfie.",
|
|
205
|
+
"microphonePermission": "Used to record a short video when asked.",
|
|
206
|
+
"photoLibraryPermission": "Used to upload a photo of your ID or a document.",
|
|
207
|
+
"locationPermission": "Used to confirm your country when asked."
|
|
208
|
+
}
|
|
209
|
+
}
|
|
210
|
+
]
|
|
211
|
+
]
|
|
212
|
+
}
|
|
213
|
+
}
|
|
214
|
+
```
|
|
215
|
+
|
|
216
|
+
The plugin:
|
|
217
|
+
|
|
218
|
+
- adds Sumsub's CocoaPods spec repo (`https://github.com/sumsub/Specs.git`) and
|
|
219
|
+
the CocoaPods CDN to the Podfile;
|
|
220
|
+
- adds Sumsub's Maven repository (`https://maven.sumsub.com/repository/maven-public/`)
|
|
221
|
+
to the Android project;
|
|
222
|
+
- sets `NSCameraUsageDescription`, `NSMicrophoneUsageDescription`,
|
|
223
|
+
`NSPhotoLibraryUsageDescription` and `NSLocationWhenInUseUsageDescription`.
|
|
224
|
+
Each `sumsub` option overrides its key; without one, a reason your app
|
|
225
|
+
already declares is kept, and a default is written otherwise.
|
|
226
|
+
|
|
227
|
+
Every option is optional, so `"@funkit/connect-rn"` alone works. Pass
|
|
228
|
+
`{ "sumsub": false }` to skip the native setup. Then rebuild the native app
|
|
229
|
+
(`npx expo prebuild` / `expo run:ios`).
|
|
230
|
+
|
|
231
|
+
### Bare React Native
|
|
232
|
+
|
|
233
|
+
Follow [Sumsub's React Native setup](https://docs.sumsub.com/docs/react-native-module):
|
|
234
|
+
the two `source` lines at the top of the Podfile, the Maven repository, and the
|
|
235
|
+
four Info.plist keys above. Bundle the Inter `.ttf` files natively (`UIAppFonts`
|
|
236
|
+
on iOS, `android/app/src/main/assets/fonts` on Android), named
|
|
237
|
+
`Inter-Regular`, `Inter-Medium` and `Inter-SemiBold` as the theme uses them.
|
|
238
|
+
|
|
143
239
|
## Peer dependencies
|
|
144
240
|
|
|
145
241
|
These are declared as **peer dependencies** (not bundled), so the host app links a
|
|
@@ -199,13 +295,17 @@ Two deliberate choices keep it that way:
|
|
|
199
295
|
- **Stripe is an optional peer, loaded on demand.** `@stripe/stripe-react-native`
|
|
200
296
|
is a native module *not* in Expo Go, and it throws at import time on a binary
|
|
201
297
|
without its pod. Nothing names the package outside the guarded `import()` in
|
|
202
|
-
`src/fiat/providers/stripeSdk.ts`, which `StripeOnrampBridge` runs only after a
|
|
298
|
+
`src/fiat/providers/stripe/stripeSdk.ts`, which `StripeOnrampBridge` runs only after a
|
|
203
299
|
host passed `stripeOnramp` to `FunkitProvider`. A host that never configures
|
|
204
300
|
Stripe never installs it and never links it. A host that wants Stripe installs
|
|
205
301
|
it, enables its Onramp module (Expo: the config plugin with
|
|
206
302
|
`includeOnramp: true`; bare RN: `stripe-react-native/Onramp` in the Podfile and
|
|
207
303
|
`StripeSdk_includeOnramp=true` in `gradle.properties`), and rebuilds; that
|
|
208
304
|
rail cannot run in Expo Go.
|
|
305
|
+
- **Sumsub's native SDK is an optional peer, loaded on demand.** The capture
|
|
306
|
+
step checks for its native module first and `import()`s
|
|
307
|
+
`@sumsub/react-native-mobilesdk-module` only when it is linked
|
|
308
|
+
(`src/fiat/providers/sumsub/sumsubSdk.ts`); otherwise Sumsub runs in the WebView.
|
|
209
309
|
- **The glass module is optional at runtime.** `FunkitGlassEffect` (this
|
|
210
310
|
package's `ios/`) is not in Expo Go. `src/native/glassEffect.ts` looks it up
|
|
211
311
|
with `requireOptionalNativeModule`, so an unlinked binary renders the
|
package/app.plugin.js
ADDED
|
@@ -0,0 +1,92 @@
|
|
|
1
|
+
// plugin/index.ts
|
|
2
|
+
import configPlugins from "expo/config-plugins.js";
|
|
3
|
+
|
|
4
|
+
// plugin/sumsubNative.ts
|
|
5
|
+
var SUMSUB_SPECS = "source 'https://github.com/sumsub/Specs.git'";
|
|
6
|
+
var COCOAPODS_CDN = "source 'https://cdn.cocoapods.org/'";
|
|
7
|
+
var SUMSUB_MAVEN = "https://maven.sumsub.com/repository/maven-public/";
|
|
8
|
+
var MAVEN_MARKER = "// @funkit/connect-rn: Sumsub mobile SDK";
|
|
9
|
+
var SUMSUB_USAGE_DESCRIPTIONS = {
|
|
10
|
+
NSCameraUsageDescription: "Used to photograph your ID and take a selfie when identity verification is required.",
|
|
11
|
+
NSMicrophoneUsageDescription: "Used to record a short video when identity verification asks for one.",
|
|
12
|
+
NSPhotoLibraryUsageDescription: "Used to upload a photo of your ID or a document when identity verification is required.",
|
|
13
|
+
NSLocationWhenInUseUsageDescription: "Used to confirm your country when identity verification asks for it."
|
|
14
|
+
};
|
|
15
|
+
var OPTION_FOR_KEY = {
|
|
16
|
+
NSCameraUsageDescription: "cameraPermission",
|
|
17
|
+
NSMicrophoneUsageDescription: "microphonePermission",
|
|
18
|
+
NSPhotoLibraryUsageDescription: "photoLibraryPermission",
|
|
19
|
+
NSLocationWhenInUseUsageDescription: "locationPermission"
|
|
20
|
+
};
|
|
21
|
+
function addSumsubPodSources(podfile) {
|
|
22
|
+
if (podfile.includes(SUMSUB_SPECS)) {
|
|
23
|
+
return podfile;
|
|
24
|
+
}
|
|
25
|
+
const sources = podfile.includes(COCOAPODS_CDN) ? [SUMSUB_SPECS] : [COCOAPODS_CDN, SUMSUB_SPECS];
|
|
26
|
+
return `${sources.join("\n")}
|
|
27
|
+
${podfile}`;
|
|
28
|
+
}
|
|
29
|
+
function addSumsubMavenRepository(buildGradle) {
|
|
30
|
+
if (buildGradle.includes(SUMSUB_MAVEN)) {
|
|
31
|
+
return buildGradle;
|
|
32
|
+
}
|
|
33
|
+
return `${buildGradle.trimEnd()}
|
|
34
|
+
|
|
35
|
+
${MAVEN_MARKER}
|
|
36
|
+
allprojects {
|
|
37
|
+
repositories {
|
|
38
|
+
maven { url "${SUMSUB_MAVEN}" }
|
|
39
|
+
}
|
|
40
|
+
}
|
|
41
|
+
`;
|
|
42
|
+
}
|
|
43
|
+
function withSumsubUsageDescriptions(infoPlist, options = {}) {
|
|
44
|
+
const next = { ...infoPlist };
|
|
45
|
+
for (const [key, fallback] of Object.entries(SUMSUB_USAGE_DESCRIPTIONS)) {
|
|
46
|
+
const override = options[OPTION_FOR_KEY[key]];
|
|
47
|
+
if (override !== void 0) {
|
|
48
|
+
next[key] = override;
|
|
49
|
+
} else if (typeof next[key] !== "string" || next[key] === "") {
|
|
50
|
+
next[key] = fallback;
|
|
51
|
+
}
|
|
52
|
+
}
|
|
53
|
+
return next;
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
// plugin/index.ts
|
|
57
|
+
var {
|
|
58
|
+
createRunOncePlugin,
|
|
59
|
+
withInfoPlist,
|
|
60
|
+
withPodfile,
|
|
61
|
+
withProjectBuildGradle
|
|
62
|
+
} = configPlugins;
|
|
63
|
+
var withSumsubNative = (config, options) => {
|
|
64
|
+
config = withPodfile(config, (podfile) => {
|
|
65
|
+
podfile.modResults.contents = addSumsubPodSources(
|
|
66
|
+
podfile.modResults.contents
|
|
67
|
+
);
|
|
68
|
+
return podfile;
|
|
69
|
+
});
|
|
70
|
+
config = withProjectBuildGradle(config, (gradle) => {
|
|
71
|
+
if (gradle.modResults.language === "groovy") {
|
|
72
|
+
gradle.modResults.contents = addSumsubMavenRepository(
|
|
73
|
+
gradle.modResults.contents
|
|
74
|
+
);
|
|
75
|
+
}
|
|
76
|
+
return gradle;
|
|
77
|
+
});
|
|
78
|
+
return withInfoPlist(config, (plist) => {
|
|
79
|
+
plist.modResults = withSumsubUsageDescriptions(plist.modResults, options);
|
|
80
|
+
return plist;
|
|
81
|
+
});
|
|
82
|
+
};
|
|
83
|
+
var withFunkitConnectRn = (config, options = {}) => {
|
|
84
|
+
if (options.sumsub === false) {
|
|
85
|
+
return config;
|
|
86
|
+
}
|
|
87
|
+
return withSumsubNative(config, options.sumsub ?? {});
|
|
88
|
+
};
|
|
89
|
+
var index_default = createRunOncePlugin(withFunkitConnectRn, "@funkit/connect-rn");
|
|
90
|
+
export {
|
|
91
|
+
index_default as default
|
|
92
|
+
};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
2
|
useFunkitIdentity
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-RPYWTS42.js";
|
|
4
4
|
import {
|
|
5
5
|
logger
|
|
6
6
|
} from "./chunk-ZE77GVDW.js";
|
|
@@ -22,6 +22,9 @@ function useUserIpInfo() {
|
|
|
22
22
|
requireState: true
|
|
23
23
|
});
|
|
24
24
|
}
|
|
25
|
+
function refreshUserIpInfo(queryClient) {
|
|
26
|
+
void queryClient.invalidateQueries({ queryKey: ["getUserIpInfo"] });
|
|
27
|
+
}
|
|
25
28
|
|
|
26
29
|
// src/statsig/useDynamicConfig.ts
|
|
27
30
|
var useDynamicConfig = (name, options) => {
|
|
@@ -106,8 +109,9 @@ function useSourceTokenUsdPrice(sourceToken, {
|
|
|
106
109
|
|
|
107
110
|
export {
|
|
108
111
|
useUserIpInfo,
|
|
112
|
+
refreshUserIpInfo,
|
|
109
113
|
useDynamicConfig,
|
|
110
114
|
useIsStablecoin,
|
|
111
115
|
useSourceTokenUsdPrice
|
|
112
116
|
};
|
|
113
|
-
//# sourceMappingURL=chunk-
|
|
117
|
+
//# sourceMappingURL=chunk-5Y2EMQYX.js.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../src/statsig/useDynamicConfig.ts", "../src/geo/useUserIpInfo.ts", "../src/withdrawal/useSourceTokenUsdPrice.ts", "../src/hooks/useIsStablecoin.ts"],
|
|
4
|
+
"sourcesContent": ["import {\n type DynamicConfigName,\n type DynamicConfigValue,\n useDynamicConfig as useCoreDynamicConfig,\n} from '@funkit/connect-core'\n\nimport { useUserIpInfo } from '../geo/useUserIpInfo'\n\n// RN counterpart of `@funkit/connect`'s `hooks/statsig/useDynamicConfig`. The\n// core hook takes `countryCode` as a parameter so it stays platform-agnostic;\n// this wrapper threads the user's IP-derived `alpha2` (Moonpay/ipapi) so\n// country-conditional variant configs (e.g. `enableswappeddeposit`) resolve\n// against the real region instead of falling to their default branch.\nexport type { DynamicConfigName, DynamicConfigValue }\n\nexport const useDynamicConfig = <Name extends DynamicConfigName>(\n name: Name,\n options?: {\n bypassCountryCode?: boolean\n },\n): DynamicConfigValue<Name> => {\n const { userIpInfo } = useUserIpInfo()\n return useCoreDynamicConfig(name, {\n bypassCountryCode: options?.bypassCountryCode,\n countryCode: userIpInfo?.alpha2,\n })\n}\n", "import { useUserIpInfo as useCoreUserIpInfo } from '@funkit/connect-core'\nimport type { QueryClient } from '@tanstack/react-query'\n\nimport { useFunkitIdentity } from '../identity/IdentityContext'\nimport { logger } from '../logging/logger'\n\n// Re-exported so existing RN importers (isCountryBlocked, the flow hooks, tests)\n// keep their type source unchanged after the fetch logic moved to core.\nexport type {\n FunkitUserIpInfo,\n UseUserIpInfoResult,\n} from '@funkit/connect-core'\n\n// Thin RN wrapper over the shared core `useUserIpInfo` (V1 PR13 moved the\n// Moonpay\u2192ipapi fetch logic there so web and RN don't duplicate it). RN is\n// login-agnostic, so the lookup always runs (`enabled: true`); web's wrapper\n// gates on `isUserLoggedIn` instead. `apiKey` lets the core hook reach the\n// first-party geo endpoint; the chain it picks is Statsig-driven.\nexport function useUserIpInfo() {\n const { apiKey } = useFunkitIdentity()\n\n // Login-agnostic + session-stable: always run, never go stale. The fiat\n // rail prices a US buyer by state, so a stateless answer is worth a second\n // provider here; web reads only the country and leaves this off.\n return useCoreUserIpInfo({\n logger,\n apiKey,\n enabled: true,\n staleTime: Number.POSITIVE_INFINITY,\n requireState: true,\n })\n}\n\n/**\n * Re-asks for the location in the background; a cached answer keeps rendering\n * until the new one lands. Matches the core hook's query key, which\n * `useUserIpInfo.test.tsx` pins.\n */\nexport function refreshUserIpInfo(queryClient: QueryClient): void {\n void queryClient.invalidateQueries({ queryKey: ['getUserIpInfo'] })\n}\n", "import { getAssetPriceInfoWithFallback } from '@funkit/connect-core'\nimport { useQuery } from '@tanstack/react-query'\n\nimport { useIsStablecoin } from '../hooks/useIsStablecoin'\nimport { useFunkitIdentity } from '../identity/IdentityContext'\nimport { logger } from '../logging/logger'\n\nconst SOURCE_TOKEN_PRICE_QUERY_KEY = 'sourceTokenUsdPrice'\n\n/** Long enough that typing doesn't refetch, short enough to stay honest. */\nconst PRICE_STALE_TIME_MS = 60_000\n\n/** What a dollar stablecoin is worth, without asking anyone. */\nconst STABLECOIN_USD_PRICE = 1\n\n/**\n * Spot USD price of the source token, for the USD floor and ceiling the host\n * configures (`getMinWithdrawalUSD`, `getMaxWithdrawalFiat`, or\n * `getMaxWithdrawalUSD`).\n *\n * A dollar stablecoin is priced from its symbol and never fetched, as web's\n * `useAssetAddressPrice` does \u2014 it is the common withdrawal source, and the\n * amount screen was waiting on a round trip to be told a dollar is a dollar.\n *\n * `0` means \"unknown\", which is what the core validator reads as \"no price\" \u2014\n * so a failed or in-flight lookup leaves the USD limits inert rather than\n * judging an amount against a made-up rate. Per-token limits and the balance\n * check are unaffected either way.\n *\n * Not every source has a price: Lighter's L2 assets are addressed by index, not\n * by an ERC-20 funkit's price API knows, so that lookup 404s and core's Relay\n * fallback is what prices them.\n */\nexport function useSourceTokenUsdPrice(\n sourceToken:\n | { chainId: string | number; address: string; symbol: string }\n | undefined,\n {\n enabled = true,\n refetchInterval = false,\n }: {\n enabled?: boolean\n refetchInterval?: number | false\n } = {},\n) {\n const { apiKey } = useFunkitIdentity()\n const isStablecoin = useIsStablecoin()\n const chainId = sourceToken ? String(sourceToken.chainId) : undefined\n const isStable = !!sourceToken && isStablecoin(sourceToken.symbol)\n const unavailable = enabled && !!sourceToken && !isStable && !apiKey\n\n const query = useQuery({\n queryKey: [\n SOURCE_TOKEN_PRICE_QUERY_KEY,\n apiKey,\n chainId,\n sourceToken?.address,\n ],\n queryFn: async () => {\n if (!sourceToken || !chainId) {\n throw new Error('Missing price inputs')\n }\n const info = await getAssetPriceInfoWithFallback({\n chainId,\n assetTokenAddress: sourceToken.address as `0x${string}`,\n apiKey,\n logger,\n })\n const unitPrice = info.unitPrice\n if (!Number.isFinite(unitPrice) || unitPrice <= 0) {\n // Reported here, not on read: a cached bad price would otherwise warn\n // on every render. A non-positive price would silently scale every USD\n // limit to nothing.\n logger.warn('connect-rn:withdrawal:unusable_source_price', {\n chainId: sourceToken.chainId,\n address: sourceToken.address,\n unitPrice,\n })\n return 0\n }\n return unitPrice\n },\n enabled: enabled && !!sourceToken && !isStable && !unavailable,\n staleTime: PRICE_STALE_TIME_MS,\n refetchInterval: isStable ? false : refetchInterval,\n retry: false,\n })\n\n return {\n refetch: query.refetch,\n data: isStable ? STABLECOIN_USD_PRICE : (query.data ?? 0),\n isUnavailable: unavailable,\n isPending: !isStable && !unavailable && query.isPending,\n isError: !isStable && (unavailable || query.isError),\n isFetching: !isStable && query.isFetching,\n }\n}\n", "import { useCallback } from 'react'\nimport { useDynamicConfig } from '../statsig/useDynamicConfig'\n\nexport type IsStablecoinFn = (symbol: string) => boolean\n\nexport function useIsStablecoin(): IsStablecoinFn {\n const stablecoinSymbols = useDynamicConfig('stablecoinsymbols')\n return useCallback(\n (symbol: string) =>\n stablecoinSymbols.some((stable) =>\n symbol.toLowerCase().includes(stable.toLowerCase()),\n ),\n [stablecoinSymbols],\n )\n}\n"],
|
|
5
|
+
"mappings": ";;;;;;;;AAAA;AAAA,EAGE,oBAAoB;AAAA,OACf;;;ACJP,SAAS,iBAAiB,yBAAyB;AAkB5C,SAAS,gBAAgB;AAC9B,QAAM,EAAE,OAAO,IAAI,kBAAkB;AAKrC,SAAO,kBAAkB;AAAA,IACvB;AAAA,IACA;AAAA,IACA,SAAS;AAAA,IACT,WAAW,OAAO;AAAA,IAClB,cAAc;AAAA,EAChB,CAAC;AACH;AAOO,SAAS,kBAAkB,aAAgC;AAChE,OAAK,YAAY,kBAAkB,EAAE,UAAU,CAAC,eAAe,EAAE,CAAC;AACpE;;;ADzBO,IAAM,mBAAmB,CAC9B,MACA,YAG6B;AAC7B,QAAM,EAAE,WAAW,IAAI,cAAc;AACrC,SAAO,qBAAqB,MAAM;AAAA,IAChC,mBAAmB,SAAS;AAAA,IAC5B,aAAa,YAAY;AAAA,EAC3B,CAAC;AACH;;;AE1BA,SAAS,qCAAqC;AAC9C,SAAS,gBAAgB;;;ACDzB,SAAS,mBAAmB;AAKrB,SAAS,kBAAkC;AAChD,QAAM,oBAAoB,iBAAiB,mBAAmB;AAC9D,SAAO;AAAA,IACL,CAAC,WACC,kBAAkB;AAAA,MAAK,CAAC,WACtB,OAAO,YAAY,EAAE,SAAS,OAAO,YAAY,CAAC;AAAA,IACpD;AAAA,IACF,CAAC,iBAAiB;AAAA,EACpB;AACF;;;ADPA,IAAM,+BAA+B;AAGrC,IAAM,sBAAsB;AAG5B,IAAM,uBAAuB;AAoBtB,SAAS,uBACd,aAGA;AAAA,EACE,UAAU;AAAA,EACV,kBAAkB;AACpB,IAGI,CAAC,GACL;AACA,QAAM,EAAE,OAAO,IAAI,kBAAkB;AACrC,QAAM,eAAe,gBAAgB;AACrC,QAAM,UAAU,cAAc,OAAO,YAAY,OAAO,IAAI;AAC5D,QAAM,WAAW,CAAC,CAAC,eAAe,aAAa,YAAY,MAAM;AACjE,QAAM,cAAc,WAAW,CAAC,CAAC,eAAe,CAAC,YAAY,CAAC;AAE9D,QAAM,QAAQ,SAAS;AAAA,IACrB,UAAU;AAAA,MACR;AAAA,MACA;AAAA,MACA;AAAA,MACA,aAAa;AAAA,IACf;AAAA,IACA,SAAS,YAAY;AACnB,UAAI,CAAC,eAAe,CAAC,SAAS;AAC5B,cAAM,IAAI,MAAM,sBAAsB;AAAA,MACxC;AACA,YAAM,OAAO,MAAM,8BAA8B;AAAA,QAC/C;AAAA,QACA,mBAAmB,YAAY;AAAA,QAC/B;AAAA,QACA;AAAA,MACF,CAAC;AACD,YAAM,YAAY,KAAK;AACvB,UAAI,CAAC,OAAO,SAAS,SAAS,KAAK,aAAa,GAAG;AAIjD,eAAO,KAAK,+CAA+C;AAAA,UACzD,SAAS,YAAY;AAAA,UACrB,SAAS,YAAY;AAAA,UACrB;AAAA,QACF,CAAC;AACD,eAAO;AAAA,MACT;AACA,aAAO;AAAA,IACT;AAAA,IACA,SAAS,WAAW,CAAC,CAAC,eAAe,CAAC,YAAY,CAAC;AAAA,IACnD,WAAW;AAAA,IACX,iBAAiB,WAAW,QAAQ;AAAA,IACpC,OAAO;AAAA,EACT,CAAC;AAED,SAAO;AAAA,IACL,SAAS,MAAM;AAAA,IACf,MAAM,WAAW,uBAAwB,MAAM,QAAQ;AAAA,IACvD,eAAe;AAAA,IACf,WAAW,CAAC,YAAY,CAAC,eAAe,MAAM;AAAA,IAC9C,SAAS,CAAC,aAAa,eAAe,MAAM;AAAA,IAC5C,YAAY,CAAC,YAAY,MAAM;AAAA,EACjC;AACF;",
|
|
6
|
+
"names": []
|
|
7
|
+
}
|
|
@@ -36,7 +36,8 @@ var SEED = {
|
|
|
36
36
|
fiatPressEntry: (p) => p.deposit?.fiat?.pressEntry,
|
|
37
37
|
fiatSubmitOnOpen: (p) => p.deposit?.fiat?.submitOnOpen,
|
|
38
38
|
fiatSurfaceFailure: (p) => p.deposit?.fiat?.surfaceFailure,
|
|
39
|
-
|
|
39
|
+
fiatAccountIneligible: (p) => p.deposit?.fiat?.accountIneligible,
|
|
40
|
+
fiatDepositMatch: (p) => p.deposit?.fiat?.depositMatch,
|
|
40
41
|
kycCompletion: (p) => p.deposit?.fiat?.kycCompletion,
|
|
41
42
|
identityPage: (p) => p.deposit?.fiat?.identity?.page,
|
|
42
43
|
identitySection: (p) => {
|
|
@@ -44,6 +45,7 @@ var SEED = {
|
|
|
44
45
|
return identity?.page === "form" ? identity.section : void 0;
|
|
45
46
|
},
|
|
46
47
|
documentStarted: (p) => p.deposit?.fiat?.documentStarted,
|
|
48
|
+
fiatCaptureReissued: (p) => p.deposit?.fiat?.captureReissued,
|
|
47
49
|
depositChainId: (p) => p.deposit?.chainId,
|
|
48
50
|
withdrawalMethodId: (p) => p.withdrawal?.methodId,
|
|
49
51
|
withdrawalAmount: (p) => p.withdrawal?.amount,
|
|
@@ -77,6 +79,21 @@ function useSeededState(pick, initial, fromSeed) {
|
|
|
77
79
|
});
|
|
78
80
|
}
|
|
79
81
|
|
|
82
|
+
// src/fiat/legalLinks.ts
|
|
83
|
+
var PRIVACY_POLICY_URL = "https://fun.xyz/privacy";
|
|
84
|
+
var CONSENT_COPY_VERSION = "fun-kyc-consent-2026-09-11";
|
|
85
|
+
var PERSONA_PRIVACY_POLICY_URL = "https://withpersona.com/legal/privacy-policy";
|
|
86
|
+
var KYC_PROVIDER_NAMES = {
|
|
87
|
+
SUMSUB: "Sumsub"
|
|
88
|
+
};
|
|
89
|
+
var titleCase = (value) => value.charAt(0) + value.slice(1).toLowerCase();
|
|
90
|
+
function kycProviderDisplayName(provider, fallback) {
|
|
91
|
+
if (provider === void 0) {
|
|
92
|
+
return fallback;
|
|
93
|
+
}
|
|
94
|
+
return KYC_PROVIDER_NAMES[provider] ?? titleCase(provider);
|
|
95
|
+
}
|
|
96
|
+
|
|
80
97
|
// src/fiat/formLayout.ts
|
|
81
98
|
import { Platform } from "react-native";
|
|
82
99
|
|
|
@@ -116,6 +133,17 @@ function postalCodeForm(alpha2) {
|
|
|
116
133
|
var GROSS_ANNUAL_INCOME = "QUESTIONNAIRE_RESPONSE:customerDueDiligence:grossAnnualIncome";
|
|
117
134
|
var EXPECTED_AMOUNT_PER_MONTH = "QUESTIONNAIRE_RESPONSE:customerDueDiligence:expectedTransactionAmountPerMonth";
|
|
118
135
|
var TRANSACTIONS_PER_MONTH = "QUESTIONNAIRE_RESPONSE:customerDueDiligence:transactionFrequencyPerMonth";
|
|
136
|
+
var NET_WORTH = "QUESTIONNAIRE_RESPONSE:enhancedDueDiligence:netWorth";
|
|
137
|
+
var LABELLED_CURRENCY = / \(([A-Z]{3})\)$/;
|
|
138
|
+
function fieldCurrency(field) {
|
|
139
|
+
return LABELLED_CURRENCY.exec(field.labelFallback)?.[1];
|
|
140
|
+
}
|
|
141
|
+
function withoutLabelledCurrency(field) {
|
|
142
|
+
return {
|
|
143
|
+
...field,
|
|
144
|
+
labelFallback: field.labelFallback.replace(LABELLED_CURRENCY, "")
|
|
145
|
+
};
|
|
146
|
+
}
|
|
119
147
|
var SECTION_BY_ID = {
|
|
120
148
|
// 1508:2616 — "First name", "M.I.", "Last Name".
|
|
121
149
|
LEGAL_FIRST_NAME: "NAME",
|
|
@@ -144,14 +172,15 @@ var SECTION_BY_ID = {
|
|
|
144
172
|
SOURCE_OF_WEALTH_DECLARATION: "SOURCE_OF_WEALTH",
|
|
145
173
|
[GROSS_ANNUAL_INCOME]: "INCOME",
|
|
146
174
|
[EXPECTED_AMOUNT_PER_MONTH]: "ACTIVITY",
|
|
147
|
-
[TRANSACTIONS_PER_MONTH]: "ACTIVITY"
|
|
175
|
+
[TRANSACTIONS_PER_MONTH]: "ACTIVITY",
|
|
176
|
+
[NET_WORTH]: "NET_WORTH"
|
|
148
177
|
};
|
|
149
178
|
var KEYBOARD_BY_ID = {
|
|
150
|
-
TAX_IDENTIFIER: "number-pad",
|
|
151
179
|
PHONE_NUMBER: "phone-pad",
|
|
152
180
|
[GROSS_ANNUAL_INCOME]: "decimal-pad",
|
|
153
181
|
[EXPECTED_AMOUNT_PER_MONTH]: "decimal-pad",
|
|
154
|
-
[TRANSACTIONS_PER_MONTH]: "number-pad"
|
|
182
|
+
[TRANSACTIONS_PER_MONTH]: "number-pad",
|
|
183
|
+
[NET_WORTH]: "decimal-pad"
|
|
155
184
|
};
|
|
156
185
|
var DRAWN_TYPES = /* @__PURE__ */ new Set(["TEXT", "SELECT", "DATE", "COUNTRY"]);
|
|
157
186
|
var GROUPED_SECTIONS = /* @__PURE__ */ new Set(["ADDRESS"]);
|
|
@@ -168,6 +197,7 @@ var SECTION_ORDER = [
|
|
|
168
197
|
"PURPOSE",
|
|
169
198
|
"SOURCE_OF_WEALTH",
|
|
170
199
|
"INCOME",
|
|
200
|
+
"NET_WORTH",
|
|
171
201
|
"ACTIVITY",
|
|
172
202
|
"DETAILS"
|
|
173
203
|
];
|
|
@@ -219,6 +249,9 @@ var POSTAL_CODE_KEYBOARD = {
|
|
|
219
249
|
digits: "number-pad",
|
|
220
250
|
separated: Platform.OS === "ios" ? "numbers-and-punctuation" : void 0
|
|
221
251
|
};
|
|
252
|
+
function fieldCountry(field, countries) {
|
|
253
|
+
return field.id === "TAX_IDENTIFIER" ? countries.taxResidence : countries.address;
|
|
254
|
+
}
|
|
222
255
|
function fieldKeyboardType(field, country) {
|
|
223
256
|
if (field.type !== "TEXT") {
|
|
224
257
|
return void 0;
|
|
@@ -227,8 +260,21 @@ function fieldKeyboardType(field, country) {
|
|
|
227
260
|
const form = postalCodeForm(country);
|
|
228
261
|
return form === void 0 ? void 0 : POSTAL_CODE_KEYBOARD[form];
|
|
229
262
|
}
|
|
263
|
+
if (field.id === "TAX_IDENTIFIER") {
|
|
264
|
+
return taxIdentifierKeyboard(country);
|
|
265
|
+
}
|
|
230
266
|
return KEYBOARD_BY_ID[field.id];
|
|
231
267
|
}
|
|
268
|
+
var DIGIT_TAX_IDENTIFIER_COUNTRIES = /* @__PURE__ */ new Set([
|
|
269
|
+
"US",
|
|
270
|
+
"BR"
|
|
271
|
+
]);
|
|
272
|
+
function taxIdentifierKeyboard(country) {
|
|
273
|
+
if (country === void 0 || DIGIT_TAX_IDENTIFIER_COUNTRIES.has(country.toUpperCase())) {
|
|
274
|
+
return "number-pad";
|
|
275
|
+
}
|
|
276
|
+
return void 0;
|
|
277
|
+
}
|
|
232
278
|
function isDigitsField(field, country) {
|
|
233
279
|
const keyboardType = fieldKeyboardType(field, country);
|
|
234
280
|
return keyboardType !== void 0 && PADS_WITHOUT_RETURN_KEY.has(keyboardType);
|
|
@@ -306,15 +352,23 @@ export {
|
|
|
306
352
|
GROSS_ANNUAL_INCOME,
|
|
307
353
|
EXPECTED_AMOUNT_PER_MONTH,
|
|
308
354
|
TRANSACTIONS_PER_MONTH,
|
|
355
|
+
NET_WORTH,
|
|
356
|
+
fieldCurrency,
|
|
357
|
+
withoutLabelledCurrency,
|
|
309
358
|
isIdentityField,
|
|
310
359
|
isInlineChoiceSection,
|
|
311
360
|
pickedDateField,
|
|
312
361
|
isFocusableField,
|
|
313
362
|
returnHop,
|
|
363
|
+
fieldCountry,
|
|
314
364
|
fieldKeyboardType,
|
|
315
365
|
isDigitsField,
|
|
316
366
|
isFixedWidthField,
|
|
317
367
|
unsupportedFields,
|
|
318
|
-
sectionPages
|
|
368
|
+
sectionPages,
|
|
369
|
+
PRIVACY_POLICY_URL,
|
|
370
|
+
CONSENT_COPY_VERSION,
|
|
371
|
+
PERSONA_PRIVACY_POLICY_URL,
|
|
372
|
+
kycProviderDisplayName
|
|
319
373
|
};
|
|
320
|
-
//# sourceMappingURL=chunk-
|
|
374
|
+
//# sourceMappingURL=chunk-OBY3O4LU.js.map
|