@funkit/connect-rn 11.0.0 → 11.2.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.
Files changed (362) hide show
  1. package/CHANGELOG.md +194 -0
  2. package/README.md +46 -0
  3. package/dist/{chunk-4YEMLHEX.js → chunk-7SP2UUHA.js} +22 -2
  4. package/dist/chunk-7SP2UUHA.js.map +7 -0
  5. package/dist/{chunk-HD4PRG6A.js → chunk-AXAQRGDI.js} +2 -2
  6. package/dist/{chunk-W2JG7SK2.js → chunk-KRQW5S2X.js} +261 -44
  7. package/dist/chunk-KRQW5S2X.js.map +7 -0
  8. package/dist/clients/lighter.js +1 -1
  9. package/dist/clients/nado.js +2 -2
  10. package/dist/index.d.ts +2 -1
  11. package/dist/index.d.ts.map +1 -1
  12. package/dist/index.js +25066 -16962
  13. package/dist/index.js.map +4 -4
  14. package/dist/preview.js +404 -15
  15. package/dist/preview.js.map +4 -4
  16. package/dist/src/components/BlurBand.d.ts.map +1 -1
  17. package/dist/src/components/ConnectedBadge.d.ts +2 -0
  18. package/dist/src/components/ConnectedBadge.d.ts.map +1 -0
  19. package/dist/src/components/GlassSurface.d.ts +5 -1
  20. package/dist/src/components/GlassSurface.d.ts.map +1 -1
  21. package/dist/src/components/Grabber.d.ts +3 -1
  22. package/dist/src/components/Grabber.d.ts.map +1 -1
  23. package/dist/src/components/PillButton.d.ts +2 -0
  24. package/dist/src/components/PillButton.d.ts.map +1 -1
  25. package/dist/src/components/SelectableAssetRow.d.ts +9 -1
  26. package/dist/src/components/SelectableAssetRow.d.ts.map +1 -1
  27. package/dist/src/components/TopBar.d.ts +5 -1
  28. package/dist/src/components/TopBar.d.ts.map +1 -1
  29. package/dist/src/components/v2/IconDisc.d.ts +15 -1
  30. package/dist/src/components/v2/IconDisc.d.ts.map +1 -1
  31. package/dist/src/components/v2/ListRow.d.ts +3 -1
  32. package/dist/src/components/v2/ListRow.d.ts.map +1 -1
  33. package/dist/src/components/v2/PaymentMethodPicker.d.ts +7 -1
  34. package/dist/src/components/v2/PaymentMethodPicker.d.ts.map +1 -1
  35. package/dist/src/fiat/common/FiatTermsNotice.d.ts +3 -1
  36. package/dist/src/fiat/common/FiatTermsNotice.d.ts.map +1 -1
  37. package/dist/src/fiat/common/FiatUnsupportedStep.d.ts.map +1 -1
  38. package/dist/src/fiat/common/stepDetails.d.ts +4 -0
  39. package/dist/src/fiat/common/stepDetails.d.ts.map +1 -1
  40. package/dist/src/fiat/contact/FiatContactScreen.d.ts.map +1 -1
  41. package/dist/src/fiat/contact/phoneRegionRedirect.d.ts +17 -0
  42. package/dist/src/fiat/contact/phoneRegionRedirect.d.ts.map +1 -0
  43. package/dist/src/fiat/contact/useRedirectHold.d.ts +31 -0
  44. package/dist/src/fiat/contact/useRedirectHold.d.ts.map +1 -0
  45. package/dist/src/fiat/entry/heldRound.d.ts +17 -0
  46. package/dist/src/fiat/entry/heldRound.d.ts.map +1 -0
  47. package/dist/src/fiat/entry/useCaptureHold.d.ts +8 -5
  48. package/dist/src/fiat/entry/useCaptureHold.d.ts.map +1 -1
  49. package/dist/src/fiat/entry/useClientRecipient.d.ts +16 -0
  50. package/dist/src/fiat/entry/useClientRecipient.d.ts.map +1 -0
  51. package/dist/src/fiat/entry/useEntryPress.d.ts +1 -0
  52. package/dist/src/fiat/entry/useEntryPress.d.ts.map +1 -1
  53. package/dist/src/fiat/entry/useEntryQuote.d.ts +3 -3
  54. package/dist/src/fiat/entry/useEntryQuote.d.ts.map +1 -1
  55. package/dist/src/fiat/entry/useFiatDirectDelivery.d.ts +6 -2
  56. package/dist/src/fiat/entry/useFiatDirectDelivery.d.ts.map +1 -1
  57. package/dist/src/fiat/form/FiatFormScreen.d.ts +7 -1
  58. package/dist/src/fiat/form/FiatFormScreen.d.ts.map +1 -1
  59. package/dist/src/fiat/form/useStandingRefusals.d.ts +4 -0
  60. package/dist/src/fiat/form/useStandingRefusals.d.ts.map +1 -1
  61. package/dist/src/fiat/kyc/FiatDocumentCaptureStep.d.ts +3 -1
  62. package/dist/src/fiat/kyc/FiatDocumentCaptureStep.d.ts.map +1 -1
  63. package/dist/src/fiat/kyc/FiatKycIntroLayout.d.ts +3 -3
  64. package/dist/src/fiat/kyc/FiatKycIntroLayout.d.ts.map +1 -1
  65. package/dist/src/fiat/kyc/FiatKycIntroScreen.d.ts +7 -2
  66. package/dist/src/fiat/kyc/FiatKycIntroScreen.d.ts.map +1 -1
  67. package/dist/src/fiat/kyc/kycCapture.d.ts.map +1 -1
  68. package/dist/src/fiat/kyc/kycRoutes.d.ts.map +1 -1
  69. package/dist/src/fiat/kyc/kycVerdict.d.ts +1 -0
  70. package/dist/src/fiat/kyc/kycVerdict.d.ts.map +1 -1
  71. package/dist/src/fiat/kyc/useKycLimitSheet.d.ts +15 -0
  72. package/dist/src/fiat/kyc/useKycLimitSheet.d.ts.map +1 -0
  73. package/dist/src/fiat/otp/useFunSession.d.ts +24 -6
  74. package/dist/src/fiat/otp/useFunSession.d.ts.map +1 -1
  75. package/dist/src/fiat/payment/applePayAttempt.d.ts.map +1 -1
  76. package/dist/src/fiat/payment/failoverKind.d.ts +24 -7
  77. package/dist/src/fiat/payment/failoverKind.d.ts.map +1 -1
  78. package/dist/src/fiat/payment/failoverPrompt.d.ts +4 -3
  79. package/dist/src/fiat/payment/failoverPrompt.d.ts.map +1 -1
  80. package/dist/src/fiat/payment/paymentReroute.d.ts +6 -2
  81. package/dist/src/fiat/payment/paymentReroute.d.ts.map +1 -1
  82. package/dist/src/fiat/payment/providerFailover.d.ts +36 -10
  83. package/dist/src/fiat/payment/providerFailover.d.ts.map +1 -1
  84. package/dist/src/fiat/payment/usePaymentAttempts.d.ts +1 -1
  85. package/dist/src/fiat/payment/usePaymentAttempts.d.ts.map +1 -1
  86. package/dist/src/fiat/payment/usePaymentFailureAnswer.d.ts +27 -34
  87. package/dist/src/fiat/payment/usePaymentFailureAnswer.d.ts.map +1 -1
  88. package/dist/src/fiat/payment/useRerouteProbe.d.ts.map +1 -1
  89. package/dist/src/fiat/processing/DepositCardSheet.d.ts +11 -1
  90. package/dist/src/fiat/processing/DepositCardSheet.d.ts.map +1 -1
  91. package/dist/src/fiat/processing/FailoverPrompt.d.ts +16 -3
  92. package/dist/src/fiat/processing/FailoverPrompt.d.ts.map +1 -1
  93. package/dist/src/fiat/providerFlow.d.ts +149 -0
  94. package/dist/src/fiat/providerFlow.d.ts.map +1 -0
  95. package/dist/src/fiat/providerFlows.d.ts +13 -0
  96. package/dist/src/fiat/providerFlows.d.ts.map +1 -0
  97. package/dist/src/fiat/providerHandoff.d.ts +18 -0
  98. package/dist/src/fiat/providerHandoff.d.ts.map +1 -0
  99. package/dist/src/fiat/providers/checkout/continueButton.d.ts +8 -0
  100. package/dist/src/fiat/providers/checkout/continueButton.d.ts.map +1 -0
  101. package/dist/src/fiat/providers/checkout/slotOutlets.d.ts +14 -0
  102. package/dist/src/fiat/providers/checkout/slotOutlets.d.ts.map +1 -0
  103. package/dist/src/fiat/providers/checkout/statusScreens.d.ts +39 -0
  104. package/dist/src/fiat/providers/checkout/statusScreens.d.ts.map +1 -0
  105. package/dist/src/fiat/providers/checkout/useFiatNextApi.d.ts +8 -0
  106. package/dist/src/fiat/providers/checkout/useFiatNextApi.d.ts.map +1 -0
  107. package/dist/src/fiat/providers/coinbase/next/Checkout.d.ts +10 -0
  108. package/dist/src/fiat/providers/coinbase/next/Checkout.d.ts.map +1 -0
  109. package/dist/src/fiat/providers/coinbase/next/index.d.ts +4 -0
  110. package/dist/src/fiat/providers/coinbase/next/index.d.ts.map +1 -0
  111. package/dist/src/fiat/providers/coinbase/next/useCoinbaseCheckout.d.ts +75 -0
  112. package/dist/src/fiat/providers/coinbase/next/useCoinbaseCheckout.d.ts.map +1 -0
  113. package/dist/src/fiat/providers/moonpay/Capture.d.ts +15 -0
  114. package/dist/src/fiat/providers/moonpay/Capture.d.ts.map +1 -0
  115. package/dist/src/fiat/providers/moonpay/Checkout.d.ts +4 -0
  116. package/dist/src/fiat/providers/moonpay/Checkout.d.ts.map +1 -0
  117. package/dist/src/fiat/providers/moonpay/KycForm.d.ts +30 -0
  118. package/dist/src/fiat/providers/moonpay/KycForm.d.ts.map +1 -0
  119. package/dist/src/fiat/providers/moonpay/checkoutScreens.d.ts +7 -0
  120. package/dist/src/fiat/providers/moonpay/checkoutScreens.d.ts.map +1 -0
  121. package/dist/src/fiat/providers/moonpay/documents.d.ts +12 -0
  122. package/dist/src/fiat/providers/moonpay/documents.d.ts.map +1 -0
  123. package/dist/src/fiat/providers/moonpay/errors.d.ts +45 -0
  124. package/dist/src/fiat/providers/moonpay/errors.d.ts.map +1 -0
  125. package/dist/src/fiat/providers/moonpay/events.d.ts +35 -0
  126. package/dist/src/fiat/providers/moonpay/events.d.ts.map +1 -0
  127. package/dist/src/fiat/providers/moonpay/index.d.ts +3 -0
  128. package/dist/src/fiat/providers/moonpay/index.d.ts.map +1 -0
  129. package/dist/src/fiat/providers/moonpay/moonpaySharingConsent.d.ts.map +1 -1
  130. package/dist/src/fiat/providers/moonpay/reask.d.ts +5 -0
  131. package/dist/src/fiat/providers/moonpay/reask.d.ts.map +1 -0
  132. package/dist/src/fiat/providers/moonpay/screens.d.ts +8 -0
  133. package/dist/src/fiat/providers/moonpay/screens.d.ts.map +1 -0
  134. package/dist/src/fiat/providers/moonpay/sdk/ApplePayButton.d.ts +29 -0
  135. package/dist/src/fiat/providers/moonpay/sdk/ApplePayButton.d.ts.map +1 -0
  136. package/dist/src/fiat/providers/moonpay/sdk/Challenge.d.ts +23 -0
  137. package/dist/src/fiat/providers/moonpay/sdk/Challenge.d.ts.map +1 -0
  138. package/dist/src/fiat/providers/moonpay/sdk/Host.d.ts +9 -0
  139. package/dist/src/fiat/providers/moonpay/sdk/Host.d.ts.map +1 -0
  140. package/dist/src/fiat/providers/moonpay/sdk/connection.d.ts +35 -0
  141. package/dist/src/fiat/providers/moonpay/sdk/connection.d.ts.map +1 -0
  142. package/dist/src/fiat/providers/moonpay/sdk/deviceQuote.d.ts +14 -0
  143. package/dist/src/fiat/providers/moonpay/sdk/deviceQuote.d.ts.map +1 -0
  144. package/dist/src/fiat/providers/moonpay/sdk/transaction.d.ts +44 -0
  145. package/dist/src/fiat/providers/moonpay/sdk/transaction.d.ts.map +1 -0
  146. package/dist/src/fiat/providers/moonpay/useCheckoutCalls.d.ts +15 -0
  147. package/dist/src/fiat/providers/moonpay/useCheckoutCalls.d.ts.map +1 -0
  148. package/dist/src/fiat/providers/moonpay/useCheckoutModel.d.ts +93 -0
  149. package/dist/src/fiat/providers/moonpay/useCheckoutModel.d.ts.map +1 -0
  150. package/dist/src/fiat/providers/moonpay/useReadiness.d.ts +20 -0
  151. package/dist/src/fiat/providers/moonpay/useReadiness.d.ts.map +1 -0
  152. package/dist/src/fiat/providers/stripe/next/Checkout.d.ts +11 -0
  153. package/dist/src/fiat/providers/stripe/next/Checkout.d.ts.map +1 -0
  154. package/dist/src/fiat/providers/stripe/next/index.d.ts +4 -0
  155. package/dist/src/fiat/providers/stripe/next/index.d.ts.map +1 -0
  156. package/dist/src/fiat/providers/stripe/next/useStripeCheckout.d.ts +55 -0
  157. package/dist/src/fiat/providers/stripe/next/useStripeCheckout.d.ts.map +1 -0
  158. package/dist/src/fiat/providers/stripe/next/useStripeCheckoutCalls.d.ts +10 -0
  159. package/dist/src/fiat/providers/stripe/next/useStripeCheckoutCalls.d.ts.map +1 -0
  160. package/dist/src/fiat/providers/stripe/next/useStripeExit.d.ts +15 -0
  161. package/dist/src/fiat/providers/stripe/next/useStripeExit.d.ts.map +1 -0
  162. package/dist/src/fiat/providers/stripe/next/useStripeFunnel.d.ts +4 -0
  163. package/dist/src/fiat/providers/stripe/next/useStripeFunnel.d.ts.map +1 -0
  164. package/dist/src/fiat/providers/stripe/next/useStripeIdentity.d.ts +23 -0
  165. package/dist/src/fiat/providers/stripe/next/useStripeIdentity.d.ts.map +1 -0
  166. package/dist/src/fiat/providers/stripe/next/useStripeKycForm.d.ts +17 -0
  167. package/dist/src/fiat/providers/stripe/next/useStripeKycForm.d.ts.map +1 -0
  168. package/dist/src/fiat/providers/stripe/next/useStripeOrderSlot.d.ts +17 -0
  169. package/dist/src/fiat/providers/stripe/next/useStripeOrderSlot.d.ts.map +1 -0
  170. package/dist/src/fiat/providers/stripe/next/useStripePayment.d.ts +24 -0
  171. package/dist/src/fiat/providers/stripe/next/useStripePayment.d.ts.map +1 -0
  172. package/dist/src/fiat/providers/stripe/next/useStripeReview.d.ts +7 -0
  173. package/dist/src/fiat/providers/stripe/next/useStripeReview.d.ts.map +1 -0
  174. package/dist/src/fiat/providers/stripe/next/useStripeSignIn.d.ts +21 -0
  175. package/dist/src/fiat/providers/stripe/next/useStripeSignIn.d.ts.map +1 -0
  176. package/dist/src/fiat/providers/stripe/stripeRoundPush.d.ts +2 -0
  177. package/dist/src/fiat/providers/stripe/stripeRoundPush.d.ts.map +1 -1
  178. package/dist/src/fiat/providers/stripe/useStripeKycPush.d.ts.map +1 -1
  179. package/dist/src/fiat/providers/sumsub/SumsubNativeKycSurface.d.ts.map +1 -1
  180. package/dist/src/fiat/quote/providerSelection.d.ts +10 -4
  181. package/dist/src/fiat/quote/providerSelection.d.ts.map +1 -1
  182. package/dist/src/fiat/quote/quoteRefusal.d.ts +2 -0
  183. package/dist/src/fiat/quote/quoteRefusal.d.ts.map +1 -1
  184. package/dist/src/fiat/quote/quoteRouting.d.ts +18 -2
  185. package/dist/src/fiat/quote/quoteRouting.d.ts.map +1 -1
  186. package/dist/src/fiat/quote/useStaleQuoteRecovery.d.ts +2 -4
  187. package/dist/src/fiat/quote/useStaleQuoteRecovery.d.ts.map +1 -1
  188. package/dist/src/fiat/settlement/depositSettlement.d.ts +8 -1
  189. package/dist/src/fiat/settlement/depositSettlement.d.ts.map +1 -1
  190. package/dist/src/fiat/settlement/useDepositSettlement.d.ts +3 -1
  191. package/dist/src/fiat/settlement/useDepositSettlement.d.ts.map +1 -1
  192. package/dist/src/fiat/surface/ScreenSurfaceCover.d.ts +6 -1
  193. package/dist/src/fiat/surface/ScreenSurfaceCover.d.ts.map +1 -1
  194. package/dist/src/fiat/surface/SurfaceSlot.d.ts +3 -1
  195. package/dist/src/fiat/surface/SurfaceSlot.d.ts.map +1 -1
  196. package/dist/src/fiat/surface/stepSurface.d.ts +1 -0
  197. package/dist/src/fiat/surface/stepSurface.d.ts.map +1 -1
  198. package/dist/src/fiat/surface/useFailureAnnouncements.d.ts.map +1 -1
  199. package/dist/src/fiat/useProviderCheckout.d.ts +60 -0
  200. package/dist/src/fiat/useProviderCheckout.d.ts.map +1 -0
  201. package/dist/src/flow/AddressCopiedToast.d.ts.map +1 -1
  202. package/dist/src/flow/CryptoAddressPage.d.ts.map +1 -1
  203. package/dist/src/flow/CryptoDepositStep.d.ts +4 -0
  204. package/dist/src/flow/CryptoDepositStep.d.ts.map +1 -1
  205. package/dist/src/flow/CryptoLearnMorePage.d.ts.map +1 -1
  206. package/dist/src/flow/CryptoListPage.d.ts +15 -3
  207. package/dist/src/flow/CryptoListPage.d.ts.map +1 -1
  208. package/dist/src/flow/CryptoNetworkPage.d.ts.map +1 -1
  209. package/dist/src/flow/CryptoTokenPage.d.ts.map +1 -1
  210. package/dist/src/flow/DepositAmountStep.d.ts +9 -1
  211. package/dist/src/flow/DepositAmountStep.d.ts.map +1 -1
  212. package/dist/src/flow/DepositFlowContent.d.ts +12 -2
  213. package/dist/src/flow/DepositFlowContent.d.ts.map +1 -1
  214. package/dist/src/flow/Drawer.d.ts +9 -1
  215. package/dist/src/flow/Drawer.d.ts.map +1 -1
  216. package/dist/src/flow/FiatDepositAmountStep.d.ts +4 -6
  217. package/dist/src/flow/FiatDepositAmountStep.d.ts.map +1 -1
  218. package/dist/src/flow/FlowSheet.d.ts +22 -2
  219. package/dist/src/flow/FlowSheet.d.ts.map +1 -1
  220. package/dist/src/flow/FunkitFlowProvider.d.ts +7 -3
  221. package/dist/src/flow/FunkitFlowProvider.d.ts.map +1 -1
  222. package/dist/src/flow/PaymentMethodPickerSheet.d.ts +10 -4
  223. package/dist/src/flow/PaymentMethodPickerSheet.d.ts.map +1 -1
  224. package/dist/src/flow/PaymentMethodRows.d.ts +13 -2
  225. package/dist/src/flow/PaymentMethodRows.d.ts.map +1 -1
  226. package/dist/src/flow/WalletConnectingAction.d.ts +9 -0
  227. package/dist/src/flow/WalletConnectingAction.d.ts.map +1 -0
  228. package/dist/src/flow/WalletDepositStep.d.ts +9 -1
  229. package/dist/src/flow/WalletDepositStep.d.ts.map +1 -1
  230. package/dist/src/flow/cryptoDepositFlow.d.ts +5 -3
  231. package/dist/src/flow/cryptoDepositFlow.d.ts.map +1 -1
  232. package/dist/src/flow/cryptoNetworkHeight.d.ts +3 -0
  233. package/dist/src/flow/cryptoNetworkHeight.d.ts.map +1 -0
  234. package/dist/src/flow/cryptoSheetSearch.d.ts +2 -0
  235. package/dist/src/flow/cryptoSheetSearch.d.ts.map +1 -1
  236. package/dist/src/flow/cryptoTokenList.d.ts +17 -11
  237. package/dist/src/flow/cryptoTokenList.d.ts.map +1 -1
  238. package/dist/src/flow/depositFlowConfig.d.ts +14 -1
  239. package/dist/src/flow/depositFlowConfig.d.ts.map +1 -1
  240. package/dist/src/flow/entryBanners.d.ts +8 -1
  241. package/dist/src/flow/entryBanners.d.ts.map +1 -1
  242. package/dist/src/flow/fiatStepScreens.d.ts.map +1 -1
  243. package/dist/src/flow/fiatSubmitRenderer.d.ts +16 -0
  244. package/dist/src/flow/fiatSubmitRenderer.d.ts.map +1 -1
  245. package/dist/src/flow/renderFiatFlowScreen.d.ts +15 -2
  246. package/dist/src/flow/renderFiatFlowScreen.d.ts.map +1 -1
  247. package/dist/src/flow/screenBundles.d.ts +0 -1
  248. package/dist/src/flow/screenBundles.d.ts.map +1 -1
  249. package/dist/src/flow/sheetSizing.d.ts.map +1 -1
  250. package/dist/src/flow/swappedLongtail.d.ts +55 -0
  251. package/dist/src/flow/swappedLongtail.d.ts.map +1 -0
  252. package/dist/src/flow/swappedMethodRows.d.ts +45 -0
  253. package/dist/src/flow/swappedMethodRows.d.ts.map +1 -0
  254. package/dist/src/flow/useCopiedToast.d.ts +1 -1
  255. package/dist/src/flow/useV2DepositEnabled.d.ts.map +1 -1
  256. package/dist/src/flow/useWalletDeposit.d.ts +24 -2
  257. package/dist/src/flow/useWalletDeposit.d.ts.map +1 -1
  258. package/dist/src/flow/v1DepositCustomers.d.ts +2 -0
  259. package/dist/src/flow/v1DepositCustomers.d.ts.map +1 -0
  260. package/dist/src/flow/withdrawalFlowConfig.d.ts +71 -6
  261. package/dist/src/flow/withdrawalFlowConfig.d.ts.map +1 -1
  262. package/dist/src/flow/withdrawalMethods.d.ts +2 -2
  263. package/dist/src/flow/withdrawalMethods.d.ts.map +1 -1
  264. package/dist/src/hooks/track/events.d.ts +2 -2
  265. package/dist/src/hooks/track/events.d.ts.map +1 -1
  266. package/dist/src/hooks/track/useDepositOutcomeEvents.d.ts.map +1 -1
  267. package/dist/src/hooks/track/useProviderCheckoutEvents.d.ts +37 -0
  268. package/dist/src/hooks/track/useProviderCheckoutEvents.d.ts.map +1 -0
  269. package/dist/src/hooks/useAnchoredMenu.d.ts +43 -0
  270. package/dist/src/hooks/useAnchoredMenu.d.ts.map +1 -0
  271. package/dist/src/hooks/useNestedSheet.d.ts +8 -1
  272. package/dist/src/hooks/useNestedSheet.d.ts.map +1 -1
  273. package/dist/src/icons/ChainAvatar.d.ts +1 -3
  274. package/dist/src/icons/ChainAvatar.d.ts.map +1 -1
  275. package/dist/src/icons/FunIcon.d.ts +6 -2
  276. package/dist/src/icons/FunIcon.d.ts.map +1 -1
  277. package/dist/src/icons/assetLogos.d.ts.map +1 -1
  278. package/dist/src/icons/cryptoBrandSvgs.d.ts +2 -0
  279. package/dist/src/icons/cryptoBrandSvgs.d.ts.map +1 -0
  280. package/dist/src/icons/iconSvg.d.ts.map +1 -1
  281. package/dist/src/native/glassEffect.d.ts +3 -0
  282. package/dist/src/native/glassEffect.d.ts.map +1 -1
  283. package/dist/src/preview/PreviewPaymentMethodPicker.d.ts +3 -0
  284. package/dist/src/preview/PreviewPaymentMethodPicker.d.ts.map +1 -1
  285. package/dist/src/preview/fixtures/moonPayChallenge.d.ts +10 -0
  286. package/dist/src/preview/fixtures/moonPayChallenge.d.ts.map +1 -0
  287. package/dist/src/preview/flowPreview.d.ts +48 -1
  288. package/dist/src/preview/flowPreview.d.ts.map +1 -1
  289. package/dist/src/preview/previewFetch.d.ts.map +1 -1
  290. package/dist/src/preview/replay/replayFetch.d.ts.map +1 -1
  291. package/dist/src/preview/scenarioCatalog.d.ts +93 -2
  292. package/dist/src/preview/scenarioCatalog.d.ts.map +1 -1
  293. package/dist/src/preview/scenarios.d.ts +7 -2
  294. package/dist/src/preview/scenarios.d.ts.map +1 -1
  295. package/dist/src/providers/IdentityContext.d.ts +2 -0
  296. package/dist/src/providers/IdentityContext.d.ts.map +1 -1
  297. package/dist/src/providers/useFunkitCheckout.d.ts +1 -1
  298. package/dist/src/screens/DepositAmountScreen.d.ts +9 -1
  299. package/dist/src/screens/DepositAmountScreen.d.ts.map +1 -1
  300. package/dist/src/screens/PaymentConfirmScreen.d.ts.map +1 -1
  301. package/dist/src/screens/depositMetrics.d.ts +6 -3
  302. package/dist/src/screens/depositMetrics.d.ts.map +1 -1
  303. package/dist/src/swapped/SwappedIframe.d.ts +9 -0
  304. package/dist/src/swapped/SwappedIframe.d.ts.map +1 -0
  305. package/dist/src/swapped/SwappedScreen.d.ts +9 -1
  306. package/dist/src/swapped/SwappedScreen.d.ts.map +1 -1
  307. package/dist/src/swapped/SwappedScreenShell.d.ts +9 -1
  308. package/dist/src/swapped/SwappedScreenShell.d.ts.map +1 -1
  309. package/dist/src/swapped/SwappedWebView.d.ts +19 -6
  310. package/dist/src/swapped/SwappedWebView.d.ts.map +1 -1
  311. package/dist/src/swapped/buildSwappedTheme.d.ts.map +1 -1
  312. package/dist/src/swapped/iframeSwappedTransport.d.ts +22 -0
  313. package/dist/src/swapped/iframeSwappedTransport.d.ts.map +1 -0
  314. package/dist/src/swapped/paymentNavigation.d.ts +3 -0
  315. package/dist/src/swapped/paymentNavigation.d.ts.map +1 -1
  316. package/dist/src/swapped/swappedV2Env.d.ts +24 -0
  317. package/dist/src/swapped/swappedV2Env.d.ts.map +1 -0
  318. package/dist/src/swapped/swappedV2Theme.d.ts +9 -0
  319. package/dist/src/swapped/swappedV2Theme.d.ts.map +1 -0
  320. package/dist/src/swapped/useSwappedEmbed.d.ts +37 -0
  321. package/dist/src/swapped/useSwappedEmbed.d.ts.map +1 -0
  322. package/dist/src/theme/buildFunkitTheme.d.ts +16 -0
  323. package/dist/src/theme/buildFunkitTheme.d.ts.map +1 -1
  324. package/dist/src/theme/restyle.d.ts +528 -0
  325. package/dist/src/theme/restyle.d.ts.map +1 -1
  326. package/dist/src/theme/toRestyleTheme.d.ts +48 -0
  327. package/dist/src/theme/toRestyleTheme.d.ts.map +1 -1
  328. package/dist/src/theme/typeScale.d.ts +84 -0
  329. package/dist/src/theme/typeScale.d.ts.map +1 -1
  330. package/dist/src/transfer/DepositQrCode.d.ts +3 -1
  331. package/dist/src/transfer/DepositQrCode.d.ts.map +1 -1
  332. package/dist/src/transfer/DepositQrGlyph.d.ts +3 -1
  333. package/dist/src/transfer/DepositQrGlyph.d.ts.map +1 -1
  334. package/dist/src/transfer/fops.d.ts +7 -1
  335. package/dist/src/transfer/fops.d.ts.map +1 -1
  336. package/dist/src/transfer/hooks/useWithdrawalFops.d.ts.map +1 -1
  337. package/dist/src/utils/withAlpha.d.ts +19 -0
  338. package/dist/src/utils/withAlpha.d.ts.map +1 -1
  339. package/dist/src/withdrawal/decimalCompare.d.ts +9 -0
  340. package/dist/src/withdrawal/decimalCompare.d.ts.map +1 -0
  341. package/dist/src/withdrawal/useWithdrawalExecution.d.ts +3 -2
  342. package/dist/src/withdrawal/useWithdrawalExecution.d.ts.map +1 -1
  343. package/dist/src/withdrawal/venueBalance.d.ts +18 -0
  344. package/dist/src/withdrawal/venueBalance.d.ts.map +1 -0
  345. package/dist/src/withdrawal/walletlessWithdrawal.d.ts +11 -2
  346. package/dist/src/withdrawal/walletlessWithdrawal.d.ts.map +1 -1
  347. package/dist/src/withdrawal/withdrawalPayer.d.ts +22 -0
  348. package/dist/src/withdrawal/withdrawalPayer.d.ts.map +1 -0
  349. package/ios/FunkitGlassEffectModule.swift +10 -0
  350. package/ios/GlassView.swift +28 -0
  351. package/package.json +8 -8
  352. package/dist/chunk-4YEMLHEX.js.map +0 -7
  353. package/dist/chunk-W2JG7SK2.js.map +0 -7
  354. package/dist/src/flow/MethodPickerStep.d.ts +0 -10
  355. package/dist/src/flow/MethodPickerStep.d.ts.map +0 -1
  356. package/dist/src/flow/useWalletSceneTransition.d.ts +0 -58
  357. package/dist/src/flow/useWalletSceneTransition.d.ts.map +0 -1
  358. package/dist/src/flow/v2DepositCustomers.d.ts +0 -2
  359. package/dist/src/flow/v2DepositCustomers.d.ts.map +0 -1
  360. package/dist/src/icons/phantomIcon.d.ts +0 -2
  361. package/dist/src/icons/phantomIcon.d.ts.map +0 -1
  362. /package/dist/{chunk-HD4PRG6A.js.map → chunk-AXAQRGDI.js.map} +0 -0
package/CHANGELOG.md CHANGED
@@ -1,5 +1,199 @@
1
1
  # @funkit/connect-rn
2
2
 
3
+ ## 11.2.0
4
+
5
+ ### Minor Changes
6
+
7
+ - 6d971f1: A preview seed can force provider checkouts on in dev and testing builds, so QA can run a `/fiat/next` flow before its gate is on.
8
+ - f1e80f9: Add Stripe's `/fiat/next` checkout, off until its feature gate is created.
9
+ - 603a11f: Run Stripe on `/fiat/next` behind the `enable-fiat-provider-flow-stripe` gate.
10
+ - 65ac448: Stripe's `/fiat/next` checkout tells the amount screen how it ended and hands over its order.
11
+ - e75a0e5: Stripe's `/fiat/next` checkout collects KYC consent and the identity rounds.
12
+ - 7679085: Stripe's `/fiat/next` checkout pays with Apple Pay.
13
+ - a259dff: Stripe's `/fiat/next` checkout shows an identity review as on hold once it outlasts its polling.
14
+ - 9739eab: Stripe's `/fiat/next` checkout signs the buyer in to Link.
15
+
16
+ ### Patch Changes
17
+
18
+ - e2b51aa: After a closed Apple Pay sheet, the "Don't see your card?" prompt waits half a second and switches providers only on Continue.
19
+ - 90a7b61: Introduce MoonPay's extra `/fiat/next` verification with the legacy card, and return to the amount screen when the buyer closes it.
20
+ - 90a7b61: Stop counting a MoonPay `/fiat/next` identity check the buyer closed without passing as a completed KYC.
21
+ - 533e850: Offer another card or provider when a MoonPay `/fiat/next` payment is declined or fails, as the legacy MoonPay flow does.
22
+ - 533e850: Log why MoonPay `/fiat/next` prices a quote again after the payment-failed sheet or a failed prewarm.
23
+ - 533e850: Keep the MoonPay `/fiat/next` checkout in place when the buyer swipes away the payment-failed sheet, instead of starting a new one.
24
+ - bc0ec94: Keep a MoonPay `/fiat/next` sign-in from closing on an edge swipe while it loads, and return to the amount screen when the buyer backs out of it.
25
+ - 9b8f9cd: Log MoonPay `/fiat/next` payment attempts and checkout events under the same names as the legacy MoonPay flow.
26
+ - bc0ec94: Reopen MoonPay's `/fiat/next` terms, not its sign-in, when the buyer taps Continue after backing out of terms.
27
+ - 94b01c4: A buyer who enters a non-US phone number for Coinbase continues straight to MoonPay.
28
+ - 4b168cc: Provider selections can mark a provider as preferred, so it is quoted before the rest.
29
+ - c20e983: After Coinbase declines a prepaid card, the prompt switches providers only on Continue; closing it pays again at Coinbase.
30
+ - 84692ae: Log the processing, settled and error-screen funnel steps for provider-run fiat checkouts.
31
+ - df78da2: Kraken and Lighter keep V1 deposit until the `enable-rn-v2-deposit` gate opens for them.
32
+ - 198a7d3: Open the V2 deposit flow before Statsig loads, so a first session no longer shows the V1 picker once
33
+ - aba9f10: Add `getApiBaseUrl` and `setApiBaseUrl` so an app can point the SDK at another Fun API stage at runtime; a saved Fun login is never sent to another stage.
34
+ - e93ddf1: Internal: share one no-op callback across the fiat flow; no behavior change.
35
+ - 2d2ad0b: A phone number Stripe can't read keeps the buyer on the form to fix it, instead of moving to another provider.
36
+ - Updated dependencies [04538e1]
37
+ - Updated dependencies [90a7b61]
38
+ - Updated dependencies [533e850]
39
+ - Updated dependencies [533e850]
40
+ - Updated dependencies [4b168cc]
41
+ - Updated dependencies [df78da2]
42
+ - Updated dependencies [aba9f10]
43
+ - Updated dependencies [a193409]
44
+ - Updated dependencies [80a9caa]
45
+ - Updated dependencies [7f392a7]
46
+ - Updated dependencies [0bc9fe2]
47
+ - Updated dependencies [7f9b271]
48
+ - Updated dependencies [3631733]
49
+ - @funkit/connect-core@13.1.0
50
+ - @funkit/api-base@10.2.0
51
+
52
+ ## 11.1.0
53
+
54
+ ### Minor Changes
55
+
56
+ - 97d76a1: The V2 amount screen's payment options can list Swapped's long-tail methods (bank transfer, pay-by-link wallets) and open them with the typed amount.
57
+ - 97d76a1: Fun login sends its deposit recipient, and the asset it wants, on the routing table, quotes and `POST /fiat/next`, so the backend converts the deposit; a MoonPay checkout waits for a recipient and reprices when it changes before payment.
58
+ - 97d76a1: `signOut` from `useFunkitCheckout` takes an optional `externalUserId` (or the wallet address when the host passes none) and ends that user's Fun email login, for a host that has already moved on to the next user, including one that now mints identity assertions. Omitted, it ends the current user's login, as before. `funSessionStorageKey` is exported: the key each user's login is kept under.
59
+ - 97d76a1: Add MoonPay’s provider-owned Apple Pay checkout using the existing verification screens.
60
+ - 97d76a1: Cash withdrawal methods are offered without a `withdrawalWallet` when `submitFiatWithdrawal` is set, and the flow opens on the payout-method list.
61
+ - 97d76a1: Hosts without a `withdrawalWallet` can now offer cash withdrawals by setting `submitFiatWithdrawal`, which receives each Swapped order for the venue to pay from its own account, capped at the balance the host reports.
62
+ - 97d76a1: Wallet link-outs and payment-method rows accept an optional `iconUrl`, and Phantom now shows its CDN artwork, falling back to its bundled mark if the artwork can't load. Wallet and token icon URLs with a query string, fragment or uppercase `.SVG` now render as SVG.
63
+ - 97d76a1: Add optional `connected` to payment method rows to show a Connected badge.
64
+
65
+ ### Patch Changes
66
+
67
+ - 97d76a1: Keep payment lists inside their sheets and headers tracking drags after scrolling.
68
+ - 97d76a1: Clarify deposit token eligibility, alphabetize additional currencies, and allow network sheets to expand fully.
69
+ - 97d76a1: Let buyers retry failed Coinbase payments from Continue without creating extra orders.
70
+ - 97d76a1: Fix Coinbase checkout after changing the deposit amount or retrying a failed payment.
71
+ - 97d76a1: After the buyer changes the amount, a verification step the new amount needs waits for their Continue instead of opening by itself. A checkout refused over the provider's limit is logged as its own event.
72
+ - 97d76a1: Fix closing Coinbase payment-failure sheets after a declined payment.
73
+ - 97d76a1: Coinbase checkouts show a subsidized fee struck through with "FREE with debit cards", and the fee details sheet opens.
74
+ - 97d76a1: Run Coinbase on `/fiat/next` behind the `enable-fiat-provider-flow-coinbase` gate: terms, phone and code, the limit upgrade, then Coinbase's own Apple Pay button and the order.
75
+ - 97d76a1: Fix Coinbase `/fiat/next` checkout for hosts that use Fun login.
76
+ - 97d76a1: Avoid extra Coinbase `/fiat/next` orders when changing the amount or closing a failed payment, and wait for the buyer to retry.
77
+ - 97d76a1: Coinbase on `/fiat/next` matches the legacy code screens: a rate-limited code request shows the legacy "Please wait" copy and offers Try Again only after the wait, and a phone number Coinbase refuses can be edited once. If a second number is refused too, the buyer is offered another provider.
78
+ - 97d76a1: Coinbase on `/fiat/next` matches the legacy flow: its sign-in and KYC screens wait for the buyer's Continue, a closed Apple Pay sheet offers another way to pay, and an amount over Coinbase's limit shows the limit with "Deposit Max".
79
+ - 97d76a1: A tap on Coinbase's pay button now counts as a payment attempt, so a declined or closed payment is logged with its attempt.
80
+ - 97d76a1: The Coinbase checkout moves the buyer to the next provider, instead of crashing, when the backend sends a step this app version does not know.
81
+ - 97d76a1: Resize embedded Send Crypto addresses to the compact sheet while preserving payment navigation.
82
+ - 97d76a1: Capture the documents MoonPay asks for with Sumsub, explaining why a retake is needed.
83
+ - 97d76a1: Recover from MoonPay checkout outages of the identity provider and of Fun's own services.
84
+ - 97d76a1: Skip MoonPay's KYC form when there is nothing to fill in, and say why MoonPay asks for details again.
85
+ - 97d76a1: Wait for a MoonPay payment that is still processing, and let the buyer pay again when the card is declined.
86
+ - 97d76a1: Mint the MoonPay session when the backend asks for it before signing the buyer in.
87
+ - 97d76a1: Show MoonPay's KYC sharing disclosure after Fun's KYC consent and before document capture.
88
+ - 97d76a1: Fix three MoonPay checkout display issues. A verified buyer no longer sees the identity intro flash after sign-in. The wait after Continue keeps its label. The charged Apple Pay button stays mounted until the order settles, so Apple's sheet finishes on success.
89
+ - 97d76a1: Swapped's long-tail methods open its production design, with its v2 design available behind a feature gate.
90
+ - 97d76a1: Swapped's long-tail methods show as pending rows in the payment options while they are being fetched, and fill in without the sheet being reopened.
91
+ - 97d76a1: Swapped's embed is themed with opaque colors, so a brand whose surfaces are authored with alpha no longer renders them as solid white.
92
+ - 97d76a1: The Swapped embed can open in Swapped's v2 design on a named payment method.
93
+ - 97d76a1: Adds the filter that keeps Swapped's long-tail payment methods apart from the V2 amount screen's native Apple Pay and card rails.
94
+ - 97d76a1: The V2 amount screen's payment options can list Swapped's long-tail methods under the host's rows.
95
+ - 97d76a1: A Swapped embed in the v2 design loads from Swapped's v2 environment and keeps its sign-in inside the sheet.
96
+ - 97d76a1: Fix Swapped themes and deposit callbacks on react-native-web.
97
+ - 97d76a1: Restyle the deposit address copy confirmation to read "Copied address" with a leading check, matching the design.
98
+ - 97d76a1: Add space between the icon and the name on the Send Crypto supported-network chips.
99
+ - 97d76a1: Fix opening the crypto currency list and search.
100
+ - 97d76a1: Keep currency search readable with a gradual blur beneath its floating glass controls as the keyboard moves.
101
+ - 97d76a1: A failover after a closed Apple Pay sheet or a prepaid card no longer rules the first provider out for the rest of the deposit; it is tried after the others.
102
+ - 97d76a1: After insufficient funds, the lowered amount is priced at once and the failover sheet offers its pay button directly.
103
+ - 97d76a1: After a declined card, the failover sheet shows the provider's own pay button to try again, instead of sending the buyer back to the amount screen.
104
+ - 97d76a1: After a closed Apple Pay sheet or a declined prepaid card, the next provider is priced at once, and the sheet's Continue takes the buyer into its next step.
105
+ - 97d76a1: After a failover, the "Verified" sheet also follows the new provider's identity check, not only its sign-in.
106
+ - 97d76a1: The amount screen's "No fees" line stays up while the price and checkout load, instead of flashing.
107
+ - 97d76a1: Restore checkout progress and payment-readiness reporting for Coinbase and MoonPay on `/fiat/next`.
108
+ - 97d76a1: On Coinbase and MoonPay `/fiat/next`, a tapped consent Continue shows only the spinner, as the legacy flow does.
109
+ - 97d76a1: Prepare Coinbase checkouts to deliver long-tail tokens once the backend offers it.
110
+ - 97d76a1: Deliver the requested token, not MoonPay's, when a MoonPay checkout buys a token MoonPay does not sell.
111
+ - 97d76a1: A fiat deposit that goes back for a new price says why in its quote analytics and logs, and never shows the old price again.
112
+ - 97d76a1: With the routing table on, the amount screen mounts MoonPay's checkout from the table, and a `REQUOTE` exit falls to the interval's next provider.
113
+ - 97d76a1: Prevent enlarged pressed controls from clipping in floating drawer headers.
114
+ - 97d76a1: Fun-login MoonPay checkout calls to `POST /fiat/next` carry the Fun session, so they are no longer anonymous.
115
+ - 97d76a1: Fun's email login keeps each user's login apart on a shared device, by `externalUserId` (or the wallet when there is none); a host that passes neither keeps the login only while the app runs. Signing out ends the login on Fun's server, even right after launch, and finishes at the next launch when Fun can't be reached. A login saved by an earlier version is ended on upgrade, and the user verifies their email once more.
116
+ - 97d76a1: Hide the base sheet grabber while a nested sheet is open.
117
+ - 97d76a1: Show the daily deposit limit as a sheet over the amount screen; Try again starts verification.
118
+ - 97d76a1: The daily limit notice points at the payment method picker instead of the fee line above it.
119
+ - 97d76a1: Enforce linked-wallet deposit minimums and distinguish empty wallets from insufficient spendable balances.
120
+ - 97d76a1: Keep MoonPay document consent visible while verification capture is prepared.
121
+ - 97d76a1: Enable the registered MoonPay checkout through its frontend rollout gate.
122
+ - 97d76a1: Restore MoonPay Continue steps before KYC and the legacy sign-in loading indicator.
123
+ - 97d76a1: MoonPay checkouts show the processing card while a paid order is confirmed, as other Apple Pay payments do.
124
+ - 97d76a1: Keep polling a second MoonPay review in the same checkout instead of showing it as on hold at once.
125
+ - 97d76a1: MoonPay checkout: an in-app Sumsub failure returns to the capture intro and still reports the capture, a returning buyer's review receipt no longer flashes over the amount screen before Continue, and closing after an unrecorded charge logs the order and transaction ids.
126
+ - 97d76a1: The MoonPay checkout moves the buyer to the next provider, instead of crashing, when the backend sends a step this app version does not know.
127
+ - 97d76a1: Keep verification review visible while preparing a follow-up MoonPay document capture.
128
+ - 97d76a1: Wait for Continue before opening MoonPay sign-in when checkout terms were already accepted.
129
+ - 97d76a1: Stop Payment Options from rubber-banding and remove the opaque top overlay from currency, network and wallet lists.
130
+ - 97d76a1: Explain when Phantom refuses a read-only account, and log the wallet's error code and how Phantom returned when a wallet connection or transfer fails.
131
+ - 97d76a1: Show one connecting indicator through wallet approval and account loading, then transition directly to the ready amount screen or a retryable error.
132
+ - 97d76a1: Explain wallet connection failures (declined, session ended, request already open, wallet error) with translated copy by error code, never the wallet's own text.
133
+ - 97d76a1: Payment-failure preview scenarios open the order for the quote paid instead of a settled MoonPay one.
134
+ - 97d76a1: Keep provider-owned checkouts, fees, and recovery connected to the deposit flow.
135
+ - 97d76a1: Use properly sized, adaptive system icons on native crypto glass controls while preserving readable raised buttons on unsupported platforms.
136
+ - 97d76a1: Match crypto pickers to the design's typography, icon sizes, and vector artwork for common tokens and networks.
137
+ - 97d76a1: Adjust Currency picker and search typography for Inter while preserving custom header fonts and alignment.
138
+ - 97d76a1: Rank USDC, USDT, ETH, BTC and SOL first on the crypto deposit currency page, and describe the other tokens as 1,000+.
139
+ - 97d76a1: Show the whole deposit address after it is tapped, wrapping it to a second line instead of truncating it.
140
+ - 97d76a1: Move currency search controls with the keyboard instead of an independent spring.
141
+ - 97d76a1: Preserve grouped currency lists until a nonempty search term is entered.
142
+ - 97d76a1: Keep Currency search above the keyboard without double-lifting inside bounded payment sheets.
143
+ - 97d76a1: Adjust Send Crypto typography for Inter and use the native system monospace face for iOS addresses.
144
+ - 97d76a1: Keep Transfer Crypto inside the current checkout across payment methods without dismissing the sheet or losing the entered amount; the host-handled amount screen now shows a payment-method chip that calls `onPaymentMethodPress` or opens `paymentMethodPicker` when either is set.
145
+ - 97d76a1: Preserve rounded crypto-sheet borders and smoothly fade scrolling content behind floating headers.
146
+ - 97d76a1: Keep linked-wallet amount controls aligned while swiping the main deposit sheet down.
147
+ - 97d76a1: Add token-redacted diagnostics for failed native identity-verification launches.
148
+ - 97d76a1: Open currency pickers with five supported tokens, fit network pickers to content, and expand currency sheets before scrolling in standalone and embedded deposits.
149
+ - 97d76a1: Match the Send Crypto sheet to the UDA spec: a tinted QR center tile with a light chain mark, and a title-case Copy Address button.
150
+ - 97d76a1: Fix the deposit amount shifting right or going blank during layout updates.
151
+ - 97d76a1: Default to a usable wallet asset, group low-balance assets as disabled, and scroll long asset lists within the sheet.
152
+ - 97d76a1: Show combined supported wallet balances in USD and default the currency selector to the largest USD holding.
153
+ - 97d76a1: Show wallet connection failures in a dismissible banner and align transfer warnings with the review design.
154
+ - 97d76a1: Show an insufficient-balance state with disabled presets when a connected wallet cannot fund a deposit, with a way back to Payment Options from its asset sheet.
155
+ - 97d76a1: Restyle the deposit amount preset chips for every payment method, and add a 75% wallet deposit preset.
156
+ - 97d76a1: Label the wallet deposit review action clearly and align its text size with the design.
157
+ - 97d76a1: Present wallet review as a translucent sheet over the preserved amount screen; a pending payment's review can be pulled away to leave the checkout.
158
+ - 97d76a1: Connect immediately from wallet picker taps and clear stale connection errors when retrying or switching methods.
159
+ - 97d76a1: Allow unlinking a connected wallet before reconnecting with another account, without clearing pending transfers; link-out apps opt in by implementing the new optional `disconnect`.
160
+ - Updated dependencies [97d76a1]
161
+ - Updated dependencies [97d76a1]
162
+ - Updated dependencies [97d76a1]
163
+ - Updated dependencies [97d76a1]
164
+ - Updated dependencies [97d76a1]
165
+ - Updated dependencies [97d76a1]
166
+ - Updated dependencies [97d76a1]
167
+ - Updated dependencies [97d76a1]
168
+ - Updated dependencies [97d76a1]
169
+ - Updated dependencies [97d76a1]
170
+ - Updated dependencies [97d76a1]
171
+ - Updated dependencies [97d76a1]
172
+ - Updated dependencies [97d76a1]
173
+ - Updated dependencies [97d76a1]
174
+ - Updated dependencies [97d76a1]
175
+ - Updated dependencies [97d76a1]
176
+ - Updated dependencies [97d76a1]
177
+ - Updated dependencies [97d76a1]
178
+ - Updated dependencies [97d76a1]
179
+ - Updated dependencies [97d76a1]
180
+ - Updated dependencies [97d76a1]
181
+ - Updated dependencies [97d76a1]
182
+ - Updated dependencies [97d76a1]
183
+ - Updated dependencies [97d76a1]
184
+ - Updated dependencies [97d76a1]
185
+ - Updated dependencies [97d76a1]
186
+ - Updated dependencies [97d76a1]
187
+ - Updated dependencies [97d76a1]
188
+ - Updated dependencies [97d76a1]
189
+ - Updated dependencies [97d76a1]
190
+ - Updated dependencies [97d76a1]
191
+ - Updated dependencies [97d76a1]
192
+ - Updated dependencies [97d76a1]
193
+ - Updated dependencies [97d76a1]
194
+ - @funkit/connect-core@13.0.0
195
+ - @funkit/api-base@10.1.0
196
+
3
197
  ## 11.0.0
4
198
 
5
199
  ### Major Changes
package/README.md CHANGED
@@ -59,6 +59,52 @@ Limits, quotes, confirmation screens, and settlement retain their existing
59
59
  denominations. Configure withdrawal ceilings separately using the maximum
60
60
  callbacks; a EUR ceiling does not implicitly select an entry currency.
61
61
 
62
+ ## Cash withdrawals paid by the venue (no wallet)
63
+
64
+ A venue that pays out of an omnibus account has no end-user signer to hand the
65
+ SDK, so it passes no `withdrawalWallet`. Cash withdrawals (card, bank transfer,
66
+ paid out by Swapped) still work: set `submitFiatWithdrawal`, and the SDK offers
67
+ the cash methods, lets the user place the order in the Swapped embed, and then
68
+ hands you the order to pay instead of signing a transfer itself.
69
+
70
+ ```tsx
71
+ beginWithdrawal({
72
+ sourceToken: { chainId: '8453', address: USDC_BASE, symbol: 'USDC', decimals: 6 },
73
+ // Your accounting. `sourceUsdBalance` caps the Swapped sell.
74
+ withdrawalSourceTokenBalance: () => balanceUsdc,
75
+ sourceUsdBalance: balanceUsdc,
76
+ submitFiatWithdrawal: async ({ orderId, depositAddress, acceptedToken, amountTokenUnits }) => {
77
+ // Your server: check balance and limits, hold, pay `amountTokenUnits` of
78
+ // `acceptedToken` to `depositAddress`, and store `orderId` against your
79
+ // own transaction id for the payout webhook.
80
+ const { txHash } = await api.payCashWithdrawal({ orderId, depositAddress, acceptedToken, amountTokenUnits })
81
+ return { txHash }
82
+ },
83
+ })
84
+ ```
85
+
86
+ What the callback receives is the order Swapped validated: its id, its deposit
87
+ address, the token it accepts and how much of it to deliver. The SDK neither
88
+ quotes nor executes anything on this rail; deliver that amount and Swapped
89
+ credits the user. A throw refuses the order and its message reaches the user;
90
+ resolving marks the order submitted and fires `onWithdrawalSubmitted` with the
91
+ hash you returned, or Swapped's deposit address if you returned none.
92
+
93
+ One adjustment happens before the hand-off. Swapped prices a sell with its own
94
+ fee and spread, so a user withdrawing their whole balance gets an order for
95
+ slightly more than they hold. When the source and accepted token are the same
96
+ asset, the SDK caps `amountTokenUnits` at the balance
97
+ `withdrawalSourceTokenBalance` reports and sets `clampedToBalance`; the amount
98
+ Swapped asked for stays on `requestedAmountTokenUnits`. Swapped credits
99
+ pro-rata on what arrives, so the order settles for slightly less fiat than
100
+ shown instead of being refused.
101
+
102
+ Fun runs no balance or limit check before the order reaches you, so your server
103
+ must, before it pays.
104
+
105
+ Without the callback and without a wallet, cash methods are withheld and the
106
+ flow opens on the crypto amount step.
107
+
62
108
  ## Payment deposit metadata
63
109
 
64
110
  `clientMetadata.authorizedAmountBaseUnit` is an explicit maximum gross deposit
@@ -82,6 +82,9 @@ function ActiveFlowPreview({
82
82
  );
83
83
  return /* @__PURE__ */ jsx2(ActivePreviewContext.Provider, { value: preview, children });
84
84
  }
85
+ function usePreviewHandoffProviders() {
86
+ return useContext2(ActivePreviewContext).deposit?.fiat?.handoffProviders;
87
+ }
85
88
  function openingStep(seed) {
86
89
  const step = seed?.step;
87
90
  return typeof step === "function" ? step() : step;
@@ -90,6 +93,15 @@ var SEED = {
90
93
  fiatAmount: (p) => p.deposit?.fiat?.amount,
91
94
  fiatStep: (p) => openingStep(p.deposit?.fiat),
92
95
  fiatPressEntry: (p) => p.deposit?.fiat?.pressEntry,
96
+ moonPayCaptureRedoing: (p) => p.deposit?.fiat?.moonPayCaptureRedoing,
97
+ moonPayBuyerRequested: (p) => p.deposit?.fiat?.pressEntry ?? (p.deposit?.fiat?.moonPayChallenge === void 0 ? void 0 : true),
98
+ moonPayChallenge: (p) => p.deposit?.fiat?.moonPayChallenge,
99
+ coinbaseBuyerRequested: (p) => p.deposit?.fiat?.pressEntry,
100
+ stripeBuyerRequested: (p) => p.deposit?.fiat?.pressEntry,
101
+ moonPayKycIntroduced: (p) => {
102
+ const page = p.deposit?.fiat?.identity?.page;
103
+ return page === void 0 ? void 0 : page === "form";
104
+ },
93
105
  fiatSubmitOnOpen: (p) => p.deposit?.fiat?.submitOnOpen,
94
106
  fiatSurfaceFailure: (p) => p.deposit?.fiat?.surfaceFailure,
95
107
  fiatQuoteSurfaceFailure: (p) => p.deposit?.fiat?.quoteSurfaceFailure,
@@ -101,6 +113,9 @@ var SEED = {
101
113
  fiatFunReauth: (p) => p.deposit?.fiat?.funReauth,
102
114
  fiatPaymentMethodContent: (p) => p.deposit?.fiat?.paymentMethodContent,
103
115
  fiatPaymentMethodCrypto: (p) => p.deposit?.fiat?.paymentMethodCrypto,
116
+ fiatPaymentMethodSwapped: (p) => p.deposit?.fiat?.paymentMethodSwapped,
117
+ fiatPaymentMethodSwappedPending: (p) => p.deposit?.fiat?.paymentMethodSwappedPending,
118
+ fiatRedirectHold: (p) => p.deposit?.fiat?.redirectHold,
104
119
  kycCompletion: (p) => p.deposit?.fiat?.kycCompletion,
105
120
  identityPage: (p) => p.deposit?.fiat?.identity?.page,
106
121
  identitySection: (p) => {
@@ -116,10 +131,14 @@ var SEED = {
116
131
  walletDeposit: (p) => p.deposit?.wallet,
117
132
  walletAccount: (p) => {
118
133
  const wallet = p.deposit?.wallet;
119
- return wallet && { address: wallet.from, tokens: wallet.tokens };
134
+ return wallet && wallet.connection !== "failed" ? { address: wallet.from, tokens: wallet.tokens } : void 0;
120
135
  },
121
136
  walletAmount: (p) => p.deposit?.wallet?.amount,
122
137
  walletStatus: (p) => p.deposit?.wallet?.status,
138
+ walletConnection: (p) => p.deposit?.wallet?.connection,
139
+ walletMenuOpen: (p) => p.deposit?.wallet?.menuOpen,
140
+ walletUnlinkFailed: (p) => p.deposit?.wallet?.unlinkFailed,
141
+ walletAssetListOpen: (p) => p.deposit?.wallet?.assetListOpen,
123
142
  walletToken: (p) => p.deposit?.wallet?.tokens[0],
124
143
  withdrawalMethodId: (p) => p.withdrawal?.methodId,
125
144
  withdrawalAmount: (p) => p.withdrawal?.amount,
@@ -424,6 +443,7 @@ export {
424
443
  FunkitFlowPreview,
425
444
  useHostFlowPreview,
426
445
  ActiveFlowPreview,
446
+ usePreviewHandoffProviders,
427
447
  openingStep,
428
448
  SEED,
429
449
  useSeed,
@@ -451,4 +471,4 @@ export {
451
471
  PERSONA_PRIVACY_POLICY_URL,
452
472
  kycProviderDisplayName
453
473
  };
454
- //# sourceMappingURL=chunk-4YEMLHEX.js.map
474
+ //# sourceMappingURL=chunk-7SP2UUHA.js.map
@@ -0,0 +1,7 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["../src/preview/replay/FunkitSessionReplay.tsx", "../src/preview/flowPreview.tsx", "../src/fiat/kyc/legalLinks.ts", "../src/fiat/form/formLayout.ts", "../src/fiat/form/keyboardReturnKey.ts", "../src/fiat/country/postalCodeCountries.ts"],
4
+ "sourcesContent": ["import type { TapeEnding } from '@funkit/connect-core'\nimport {\n type ReactNode,\n createContext,\n useContext,\n useLayoutEffect,\n useMemo,\n} from 'react'\n\n/** Which recorded ending a screen can play. */\ninterface EndingMatch {\n /** Its code starts with this: a Stripe stage, `perform_checkout:`. */\n prefix?: string\n /** A sign-in screen plays only what ended a sign-in, and a payment screen only the rest. */\n auth?: boolean\n}\n\n/** The provider screens' recorded endings, each played back once. */\nexport interface RecordedEndings {\n /** The next unplayed one recorded for `provider` that this screen can play. */\n next: (provider: string, match?: EndingMatch) => TapeEnding | undefined\n played: (ending: TapeEnding) => void\n}\n\n/** The screen a sign-in surface draws on, as the failure logs name it. */\nconst AUTH_SCREEN = 'AUTH_CAPTURE'\n\nfunction recordedEndings(endings: readonly TapeEnding[]): RecordedEndings {\n const played = new Set<TapeEnding>()\n // a tape from before endings named their screen plays on any\n const fits = (ending: TapeEnding, auth: boolean | undefined) =>\n auth === undefined ||\n ending.screen === undefined ||\n (ending.screen === AUTH_SCREEN) === auth\n return {\n next: (provider, { prefix = '', auth }: EndingMatch = {}) =>\n endings.find(\n (ending) =>\n !played.has(ending) &&\n ending.provider === provider &&\n ending.code.startsWith(prefix) &&\n fits(ending, auth),\n ),\n played: (ending) => {\n played.add(ending)\n },\n }\n}\n\nconst NONE = recordedEndings([])\n\nconst ReplayContext = createContext({ active: false, endings: NONE })\n\n/** Read where no context reaches: which adapter claims a surface is decided outside render. */\nlet replayMounted = false\nexport const isReplayMounted = (): boolean => replayMounted\n\n/**\n * Marks the flows below it as running on a recorded attempt's answers (`createReplayFetch`),\n * so provider screens, which need a live provider session, stand aside.\n * - `endings` are how the buyer's provider screens failed or closed: the backend never hears a\n * decline, so the stand-ins play them back.\n */\nexport function FunkitSessionReplay({\n active,\n endings,\n children,\n}: {\n active: boolean\n endings?: readonly TapeEnding[]\n children: ReactNode\n}) {\n useLayoutEffect(() => {\n replayMounted = active\n return () => {\n replayMounted = false\n }\n }, [active])\n const value = useMemo(\n () => ({\n active,\n endings: endings === undefined ? NONE : recordedEndings(endings),\n }),\n [active, endings],\n )\n return (\n <ReplayContext.Provider value={value}>{children}</ReplayContext.Provider>\n )\n}\n\nexport function useIsReplaying(): boolean {\n return useContext(ReplayContext).active\n}\n\nexport function useRecordedEndings(): RecordedEndings {\n return useContext(ReplayContext).endings\n}\n", "import type {\n FiatProvider,\n FiatStepResponse,\n MoonPayCheckoutState,\n} from '@funkit/connect-core'\nimport {\n type Dispatch,\n type ReactNode,\n type SetStateAction,\n createContext,\n useContext,\n useEffect,\n useMemo,\n useState,\n} from 'react'\n\nimport type { HeldContact } from '../fiat/contact/phoneRegionRedirect'\nimport type { KycCompletion } from '../fiat/kyc/useKycCompletion'\nimport type { KycSection } from '../fiat/form/formLayout'\nimport type { CryptoFlowScreen } from '../flow/cryptoDepositFlow'\nimport type { FlowScreen } from '../flow/FunkitFlowProvider'\nimport type { DepositMatchTerms } from '../flow/depositFlowConfig'\nimport type { DepositLinkOutApp } from '../flow/depositFlowConfig'\nimport type { AssetBalanceInfo } from '@funkit/api-base'\n\n/**\n * Where the fiat session opens. Each field seeds one piece of state a user would otherwise reach\n * by tapping through, so any screen of the rail is one seed away.\n */\nexport interface FiatPreviewSeed {\n /**\n * The step response the session opens on, as if the backend had just sent it.\n * - A function builds it as the session opens, for a step whose times count from then.\n */\n step?: FiatStepResponse | (() => FiatStepResponse)\n /** The amount entry's value. */\n amount?: string\n /** Presses the entry CTA once it is ready: opens the contact round, or the KYC options card. */\n pressEntry?: boolean\n /** An identity round's consent intro, or its form open at a section. */\n identity?: { page: 'consent' } | { page: 'form'; section?: KycSection }\n /** Past the document-capture intro, onto the provider's own surface. */\n documentStarted?: boolean\n /** The provider asked for its capture again after the buyer finished one. */\n captureReissued?: boolean\n /** Past the MoonPay retake choice, onto the document intro. */\n moonPayCaptureRedoing?: boolean\n /**\n * A handed-off MoonPay checkout opens at MoonPay's own extra check, past the buyer's Continue:\n * its intro, or its \"additional verification\" card after one completed check.\n * - Builds the checkout's state from its start, so the replay ships with the preview entry only.\n */\n moonPayChallenge?: (start: MoonPayCheckoutState) => MoonPayCheckoutState\n /** The acknowledgement a finished identity form shows before its verdict. */\n kycCompletion?: KycCompletion\n /** A provider surface that failed, as the adapter reports it. */\n surfaceFailure?: { code: string; detail?: string }\n /** The buyer signed in where a payment failover moved them: the payment waits for a tap. */\n failoverVerified?: boolean\n /** The quote's own pay sheet failed, reported once a quote has drawn it. */\n quoteSurfaceFailure?: { code: string; detail?: string }\n /** Submits the seeded step's CTA with this id on open \u2014 how a failed send is reached. */\n submitOnOpen?: string\n /** The host's identity minter refused this account. */\n accountIneligible?: boolean\n /** Turns the deposit-match preview on, as the host's internal flag does. */\n depositMatch?: DepositMatchTerms\n /** The pay sheet already took the payment, so the seeded order is one the buyer just paid for. */\n paymentCaptured?: boolean\n /** The payment-method picker open over the amount; a stand-in when the host supplies none. */\n paymentMethodPicker?: boolean\n /** Fun's login ended over the seeded order, so the flow asks the buyer to sign in again. */\n funReauth?: boolean\n /** A stand-in host payment-method page inside the open picker. */\n paymentMethodContent?: boolean\n /** The crypto page inside the open payment-method picker, with its back history. */\n paymentMethodCrypto?: CryptoFlowScreen\n /** Stand-in Swapped long-tail methods under the open picker's host rows. */\n paymentMethodSwapped?: boolean\n /** Swapped's section in the open picker while `/fops` is still answering. */\n paymentMethodSwappedPending?: boolean\n /** The contact screen a non-US-number redirect holds up while MoonPay quotes. */\n redirectHold?: HeldContact\n /**\n * The provider checkouts this session hands quotes to, whatever their Statsig gates say: how QA\n * runs a `/fiat/next` flow before its gate is on. Held for the whole session, not one mount.\n */\n handoffProviders?: readonly FiatProvider[]\n}\n\nexport interface DepositPreviewSeed {\n /**\n * The screen the flow opens on; defaults to the root `beginDeposit` picks.\n * Transfer opens above it; a crypto page opens above the pages before it.\n */\n screen?: Extract<\n FlowScreen,\n | 'depositAmount'\n | 'walletConfirm'\n | 'addMoney'\n | 'transfer'\n | 'cryptoToken'\n | 'cryptoNetwork'\n | 'cryptoAddress'\n | 'cryptoLearnMore'\n >\n fiat?: FiatPreviewSeed\n /** A simulated link-out session: no wallet connection, signing, or submission. */\n wallet?: {\n app: DepositLinkOutApp\n from: string\n to: string\n tokens: AssetBalanceInfo[]\n amount: string\n status: 'idle' | 'sent' | 'failed' | 'pending'\n /** Where the wallet connection stands, before any account is linked. */\n connection?: 'connecting' | 'failed'\n menuOpen?: boolean\n assetListOpen?: boolean\n /** The asset sheet open on its failed-unlink notice. */\n unlinkFailed?: boolean\n }\n /** The deposit chain, by id, as if picked from the Crypto row \u2014 Transfer needs one. */\n chainId?: string\n /** A locked deposit's source token, by symbol, as if picked with `chainId` \u2014 its Transfer needs both. */\n sourceSymbol?: string\n /** The V2 crypto currency page's search, open on this query (`''` for an empty field). */\n tokenQuery?: string\n /** The V2 crypto address page's address, tapped open to its full length. */\n addressExpanded?: boolean\n}\n\ntype WithdrawalStackScreen = Extract<\n FlowScreen,\n | 'withdrawMethod'\n | 'withdrawAmount'\n | 'withdrawAddress'\n | 'withdrawReceiveToken'\n>\n\n/** The submitted withdrawal the completion screen reports on. */\nexport interface WithdrawalPreviewCompletion {\n txHash: `0x${string}`\n amountLabel: string\n usdLabel?: string\n tokenLabel?: string\n}\n\ninterface WithdrawalPreviewFields {\n /** The payout method picked on the list, by `WithdrawalMethodOption.id`. */\n methodId?: string\n amount?: string\n recipient?: string\n /** The paste-panel address field, open for editing (its tail gives way to the address start). */\n addressFocused?: boolean\n /** The retryable error that replaces every screen after a failed execution. */\n executionError?: boolean\n}\n\n/**\n * The withdrawal flow's opening state. The type rules out the stacks that render nothing: an\n * empty one, and a completion screen with no withdrawal to report.\n */\nexport type WithdrawalPreviewSeed = WithdrawalPreviewFields &\n (\n | {\n /** The screens on the stack, root first; defaults to the payout-method list. */\n stack?: [WithdrawalStackScreen, ...WithdrawalStackScreen[]]\n complete?: undefined\n }\n | { stack: ['withdrawComplete']; complete: WithdrawalPreviewCompletion }\n )\n\n/**\n * A state to open the SDK's flow at, for hosted previews and QA builds.\n * - Consumed by the next matching `begin*` only; closing and reopening starts clean.\n * - Never set in production: every read falls back to the flow's own start.\n */\nexport interface FlowPreviewSeed {\n deposit?: DepositPreviewSeed\n withdrawal?: WithdrawalPreviewSeed\n}\n\nconst HostPreviewContext = createContext<FlowPreviewSeed | undefined>(undefined)\n\n/**\n * Opens the next `beginDeposit` / `beginWithdrawal` below it at `seed`.\n * - Mount it above `<FunkitProvider>`.\n * - Memoize `seed`: a new object is a new preview, so one built inline reopens every flow seeded.\n */\nexport function FunkitFlowPreview({\n seed,\n children,\n}: {\n seed: FlowPreviewSeed | undefined\n children: ReactNode\n}) {\n return (\n <HostPreviewContext.Provider value={seed}>\n {children}\n </HostPreviewContext.Provider>\n )\n}\n\n/** The seed a host mounted; read by the flow provider when a flow opens. */\nexport function useHostFlowPreview(): FlowPreviewSeed | undefined {\n return useContext(HostPreviewContext)\n}\n\n/** The seeds of the flow session a host preview opened; empty everywhere else. */\nexport interface ActivePreview {\n deposit?: DepositPreviewSeed\n withdrawal?: WithdrawalPreviewSeed\n}\n\nconst NO_PREVIEW: ActivePreview = {}\nconst ActivePreviewContext = createContext<ActivePreview>(NO_PREVIEW)\n\n/** Scopes a consumed seed to the one flow session it opened. */\nexport function ActiveFlowPreview({\n deposit,\n withdrawal,\n children,\n}: {\n deposit?: DepositPreviewSeed\n withdrawal?: WithdrawalPreviewSeed\n children: ReactNode\n}) {\n // The value names the session: readers are tracked against it.\n const preview = useMemo(\n () =>\n deposit === undefined && withdrawal === undefined\n ? NO_PREVIEW\n : { deposit, withdrawal },\n [deposit, withdrawal],\n )\n return (\n <ActivePreviewContext.Provider value={preview}>\n {children}\n </ActivePreviewContext.Provider>\n )\n}\n\n/** The session's forced provider checkouts, if its preview names any. Read on every mount. */\nexport function usePreviewHandoffProviders():\n | readonly FiatProvider[]\n | undefined {\n return useContext(ActivePreviewContext).deposit?.fiat?.handoffProviders\n}\n\n/** The step a fiat seed opens on, built now when it is timed. */\nexport function openingStep(\n seed: FiatPreviewSeed | undefined,\n): FiatStepResponse | undefined {\n const step = seed?.step\n return typeof step === 'function' ? step() : step\n}\n\n/** Reads one seed value out of the session's preview. */\nexport type PreviewPick<T> = (preview: ActivePreview) => T | undefined\n\n/**\n * Every seed value a flow reads, one reader each. Readers are tracked by identity, so each is\n * declared once here rather than inline where it is read.\n */\nexport const SEED = {\n fiatAmount: (p) => p.deposit?.fiat?.amount,\n fiatStep: (p) => openingStep(p.deposit?.fiat),\n fiatPressEntry: (p) => p.deposit?.fiat?.pressEntry,\n moonPayCaptureRedoing: (p) => p.deposit?.fiat?.moonPayCaptureRedoing,\n moonPayBuyerRequested: (p) =>\n p.deposit?.fiat?.pressEntry ??\n (p.deposit?.fiat?.moonPayChallenge === undefined ? undefined : true),\n moonPayChallenge: (p) => p.deposit?.fiat?.moonPayChallenge,\n coinbaseBuyerRequested: (p) => p.deposit?.fiat?.pressEntry,\n stripeBuyerRequested: (p) => p.deposit?.fiat?.pressEntry,\n moonPayKycIntroduced: (p) => {\n const page = p.deposit?.fiat?.identity?.page\n return page === undefined ? undefined : page === 'form'\n },\n fiatSubmitOnOpen: (p) => p.deposit?.fiat?.submitOnOpen,\n fiatSurfaceFailure: (p) => p.deposit?.fiat?.surfaceFailure,\n fiatQuoteSurfaceFailure: (p) => p.deposit?.fiat?.quoteSurfaceFailure,\n fiatFailoverVerified: (p) => p.deposit?.fiat?.failoverVerified,\n fiatAccountIneligible: (p) => p.deposit?.fiat?.accountIneligible,\n fiatDepositMatch: (p) => p.deposit?.fiat?.depositMatch,\n fiatPaymentCaptured: (p) => p.deposit?.fiat?.paymentCaptured,\n fiatPaymentMethodPicker: (p) => p.deposit?.fiat?.paymentMethodPicker,\n fiatFunReauth: (p) => p.deposit?.fiat?.funReauth,\n fiatPaymentMethodContent: (p) => p.deposit?.fiat?.paymentMethodContent,\n fiatPaymentMethodCrypto: (p) => p.deposit?.fiat?.paymentMethodCrypto,\n fiatPaymentMethodSwapped: (p) => p.deposit?.fiat?.paymentMethodSwapped,\n fiatPaymentMethodSwappedPending: (p) =>\n p.deposit?.fiat?.paymentMethodSwappedPending,\n fiatRedirectHold: (p) => p.deposit?.fiat?.redirectHold,\n kycCompletion: (p) => p.deposit?.fiat?.kycCompletion,\n identityPage: (p) => p.deposit?.fiat?.identity?.page,\n identitySection: (p) => {\n const identity = p.deposit?.fiat?.identity\n return identity?.page === 'form' ? identity.section : undefined\n },\n documentStarted: (p) => p.deposit?.fiat?.documentStarted,\n fiatCaptureReissued: (p) => p.deposit?.fiat?.captureReissued,\n depositChainId: (p) => p.deposit?.chainId,\n depositSourceSymbol: (p) => p.deposit?.sourceSymbol,\n cryptoTokenQuery: (p) => p.deposit?.tokenQuery,\n cryptoAddressExpanded: (p) => p.deposit?.addressExpanded,\n walletDeposit: (p) => p.deposit?.wallet,\n walletAccount: (p) => {\n const wallet = p.deposit?.wallet\n // A failed connection never linked an account.\n return wallet && wallet.connection !== 'failed'\n ? { address: wallet.from, tokens: wallet.tokens }\n : undefined\n },\n walletAmount: (p) => p.deposit?.wallet?.amount,\n walletStatus: (p) => p.deposit?.wallet?.status,\n walletConnection: (p) => p.deposit?.wallet?.connection,\n walletMenuOpen: (p) => p.deposit?.wallet?.menuOpen,\n walletUnlinkFailed: (p) => p.deposit?.wallet?.unlinkFailed,\n walletAssetListOpen: (p) => p.deposit?.wallet?.assetListOpen,\n walletToken: (p) => p.deposit?.wallet?.tokens[0],\n withdrawalMethodId: (p) => p.withdrawal?.methodId,\n withdrawalAmount: (p) => p.withdrawal?.amount,\n withdrawalRecipient: (p) => p.withdrawal?.recipient,\n withdrawalAddressFocused: (p) => p.withdrawal?.addressFocused,\n withdrawalComplete: (p) => p.withdrawal?.complete,\n withdrawalExecutionError: (p) => p.withdrawal?.executionError,\n} satisfies Record<string, PreviewPick<unknown>>\n\nconst readers = new WeakMap<ActivePreview, Set<PreviewPick<unknown>>>()\n\n/**\n * The seed value for the first mount that reads it; `undefined` for every mount after.\n * - A later mount of the same reader is the user moving on (a new round, a return to the entry),\n * so a seed never re-applies after the state it describes.\n * - Marked read on commit, so Strict Mode's double render still sees it.\n */\nexport function useSeed<T>(pick: PreviewPick<T>): T | undefined {\n const preview = useContext(ActivePreviewContext)\n const [seed] = useState(() =>\n readers.get(preview)?.has(pick) === true ? undefined : pick(preview),\n )\n useEffect(() => {\n if (preview === NO_PREVIEW) {\n return\n }\n const read = readers.get(preview) ?? new Set()\n read.add(pick)\n readers.set(preview, read)\n }, [preview, pick])\n return seed\n}\n\n/**\n * `useState` whose initial value a host preview may seed; production always starts at `initial`.\n * `fromSeed` shapes a seed value into the state when the two differ.\n */\nexport function useSeededState<T>(\n pick: PreviewPick<T>,\n initial: T,\n): [T, Dispatch<SetStateAction<T>>]\nexport function useSeededState<S, T>(\n pick: PreviewPick<S>,\n initial: T,\n fromSeed: (seed: S) => T,\n): [T, Dispatch<SetStateAction<T>>]\nexport function useSeededState<S, T>(\n pick: PreviewPick<S>,\n initial: T,\n fromSeed?: (seed: S) => T,\n): [T, Dispatch<SetStateAction<T>>] {\n const seed = useSeed(pick)\n return useState<T>(() => {\n if (seed === undefined) {\n return initial\n }\n return fromSeed === undefined ? (seed as unknown as T) : fromSeed(seed)\n })\n}\n", "import type { FiatProvider, KYCProvider } from '@funkit/connect-core'\n\n/**\n * The documents the identity step points at.\n *\n * Held together because two screens link them, and a provider change is one\n * edit rather than a hunt through the copy.\n */\n\n/** Fun's own policy, linked from the consent the buyer has to give. */\nexport const PRIVACY_POLICY_URL = 'https://fun.xyz/privacy'\n\n/**\n * Bumped whenever the consent copy changes, and logged and recorded with every\n * consent, so a record can be matched to the words the buyer actually read.\n * The backend must publish the same revision (`FUN_KYC_CONSENT_TERMS`).\n */\nexport const CONSENT_COPY_VERSION = 'fun-kyc-consent-2026-09-11'\n\n/** Persona's policy, linked from MoonPay's sharing disclosure (`MOONPAY_SHARING_CONSENT_VERSION`). */\nexport const PERSONA_PRIVACY_POLICY_URL =\n 'https://withpersona.com/legal/privacy-policy'\n\n/**\n * The terms of the provider that settles the order, keyed by the provider the\n * round names.\n *\n * Only verified URLs belong here. A provider absent from the map is named in\n * the copy without a link and logged (`kyc_provider_terms_url_missing`) \u2014 it\n * is never guessed, and never falls back to another provider's terms.\n */\nconst PROVIDER_TERMS_URLS: Partial<Record<FiatProvider, string>> = {\n BANXA: 'https://banxa.com/terms-of-use/',\n}\n\n/** How each provider writes its own name; the enum is upper-case. */\nconst PROVIDER_NAMES: Partial<Record<FiatProvider, string>> = {\n BANXA: 'Banxa',\n TRANSAK: 'Transak',\n}\n\n/** The identity vendors, which settle no orders and so are kept apart. */\nconst KYC_PROVIDER_NAMES: Partial<Record<KYCProvider, string>> = {\n SUMSUB: 'Sumsub',\n}\n\n/** Title-cases an upper-case enum member for a provider with no name on record. */\nconst titleCase = (value: string) =>\n value.charAt(0) + value.slice(1).toLowerCase()\n\n/** The provider's terms, or `undefined` when none is on record for it. */\nexport function providerTermsUrl(\n provider: FiatProvider | undefined,\n): string | undefined {\n return provider === undefined ? undefined : PROVIDER_TERMS_URLS[provider]\n}\n\n/**\n * The provider's name as the copy should print it. `fallback` is what a\n * screen drawn with no round to name one says instead.\n */\nexport function providerDisplayName(\n provider: FiatProvider | undefined,\n fallback: string,\n): string {\n if (provider === undefined) {\n return fallback\n }\n return PROVIDER_NAMES[provider] ?? titleCase(provider)\n}\n\n/**\n * The identity vendor's name as the copy should print it. Separate from the\n * settling provider: the two enums name different things and never mix.\n */\nexport function kycProviderDisplayName(\n provider: KYCProvider | undefined,\n fallback: string,\n): string {\n if (provider === undefined) {\n return fallback\n }\n return KYC_PROVIDER_NAMES[provider] ?? titleCase(provider)\n}\n", "import type { FormField, KycFieldId } from '@funkit/connect-core'\nimport { isValueField } from '@funkit/connect-core'\nimport { Platform, type TextInputProps } from 'react-native'\n\nimport { PADS_WITHOUT_RETURN_KEY } from './keyboardReturnKey'\nimport {\n type PostalCodeForm,\n postalCodeForm,\n} from '../country/postalCodeCountries'\n\n/**\n * The pages the US form is drawn as, in the order the design steps them.\n *\n * Figma \"EDIT: KYC Enhancements\": 1508:2616 (name), 1844:17471 (date of\n * birth), 1631:7256 (address), 1631:7883 (SSN). `DETAILS` is not a frame \u2014 it\n * is where a field the design never drew goes, so a form the server words its\n * own way still renders.\n */\nexport type KycSection =\n | 'NAME'\n | 'DOB'\n | 'NATIONALITY'\n | 'COUNTRY'\n | 'ADDRESS'\n | 'SSN'\n | 'PHONE'\n | 'OCCUPATION'\n | 'EMPLOYMENT'\n | 'PURPOSE'\n | 'SOURCE_OF_WEALTH'\n | 'INCOME'\n | 'NET_WORTH'\n | 'ACTIVITY'\n | 'DETAILS'\n\nexport interface KycSectionPage {\n section: KycSection\n /** Drawn as one card with a rule between rows, rather than loose boxes. */\n grouped: boolean\n /** Fields sharing a row sit side by side, as the design pairs them. */\n rows: FormField[][]\n}\n\n/**\n * The questionnaire answers this build draws a page for. The contract types a\n * questionnaire id as a template; any other lands in `DETAILS`.\n */\nexport const GROSS_ANNUAL_INCOME =\n 'QUESTIONNAIRE_RESPONSE:customerDueDiligence:grossAnnualIncome'\nexport const EXPECTED_AMOUNT_PER_MONTH =\n 'QUESTIONNAIRE_RESPONSE:customerDueDiligence:expectedTransactionAmountPerMonth'\nexport const TRANSACTIONS_PER_MONTH =\n 'QUESTIONNAIRE_RESPONSE:customerDueDiligence:transactionFrequencyPerMonth'\nexport const NET_WORTH = 'QUESTIONNAIRE_RESPONSE:enhancedDueDiligence:netWorth'\n\n/**\n * - `FormField` has no currency key, so a figure's reporting currency rides its\n * label as a trailing \" (XXX)\".\n * - Any other label names no currency.\n */\nconst LABELLED_CURRENCY = / \\(([A-Z]{3})\\)$/\n\nexport function fieldCurrency(field: FormField): string | undefined {\n return LABELLED_CURRENCY.exec(field.labelFallback)?.[1]\n}\n\n/** The label without its currency, for a field whose caption already names it. */\nexport function withoutLabelledCurrency(field: FormField): FormField {\n return {\n ...field,\n labelFallback: field.labelFallback.replace(LABELLED_CURRENCY, ''),\n }\n}\n\n/**\n * Which page a field belongs to, by id.\n *\n * The contract closes the id set, so these are the canonical names and there\n * is no second spelling to carry. An id with no page here lands in `DETAILS`\n * rather than being refused: the server owns the list, and a form is not\n * undrawable just because it asks for something the frames do not group.\n */\nconst SECTION_BY_ID: Readonly<Partial<Record<KycFieldId, KycSection>>> = {\n // 1508:2616 \u2014 \"First name\", \"M.I.\", \"Last Name\".\n LEGAL_FIRST_NAME: 'NAME',\n LEGAL_MIDDLE_NAME: 'NAME',\n LEGAL_LAST_NAME: 'NAME',\n // 1844:17471 \u2014 its own page, asked for on its own over the date picker.\n DATE_OF_BIRTH: 'DOB',\n NATIONALITY: 'NATIONALITY',\n // 1631:7256 \u2014 \"Address\", \"Apartment, suite, etc.\", \"City\", \"State\", \"ZIP code\".\n RESIDENTIAL_ADDRESS_LINE_1: 'ADDRESS',\n RESIDENTIAL_ADDRESS_LINE_2: 'ADDRESS',\n RESIDENTIAL_ADDRESS_CITY: 'ADDRESS',\n RESIDENTIAL_ADDRESS_REGION: 'ADDRESS',\n RESIDENTIAL_ADDRESS_POSTAL_CODE: 'ADDRESS',\n RESIDENTIAL_ADDRESS_COUNTRY: 'COUNTRY',\n // 1631:7883 \u2014 \"SSN\".\n TAX_IDENTIFIER: 'SSN',\n TAX_RESIDENCE_COUNTRY: 'COUNTRY',\n OCCUPATION_TITLE: 'OCCUPATION',\n OCCUPATION_INDUSTRY: 'OCCUPATION',\n PURPOSE_OF_TRANSACTION: 'PURPOSE',\n PURPOSE_OF_SERVICE: 'PURPOSE',\n // MoonPay's customer due diligence round, asked after the SSN.\n PHONE_NUMBER: 'PHONE',\n EMPLOYMENT_STATUS: 'EMPLOYMENT',\n SOURCE_OF_WEALTH_DECLARATION: 'SOURCE_OF_WEALTH',\n [GROSS_ANNUAL_INCOME]: 'INCOME',\n [EXPECTED_AMOUNT_PER_MONTH]: 'ACTIVITY',\n [TRANSACTIONS_PER_MONTH]: 'ACTIVITY',\n [NET_WORTH]: 'NET_WORTH',\n}\n\n/**\n * The keyboard a typed field raises. The SSN page is drawn over a number pad\n * (1631:7883) and the due-diligence figures over the pads that fit them;\n * every other page in the form is drawn over letters.\n */\nconst KEYBOARD_BY_ID: Readonly<\n Partial<Record<KycFieldId, TextInputProps['keyboardType']>>\n> = {\n PHONE_NUMBER: 'phone-pad',\n [GROSS_ANNUAL_INCOME]: 'decimal-pad',\n [EXPECTED_AMOUNT_PER_MONTH]: 'decimal-pad',\n [TRANSACTIONS_PER_MONTH]: 'number-pad',\n [NET_WORTH]: 'decimal-pad',\n}\n\n/**\n * Field types a page can draw. A date and a country are typed into the same\n * filled box as any other answer; a hosted step is an errand the user runs\n * elsewhere and a document streams to an endpoint this build has not\n * installed, so neither has a box to draw.\n */\nconst DRAWN_TYPES = new Set(['TEXT', 'SELECT', 'DATE', 'COUNTRY'])\n\n/** One card ruled between its rows (1631:7256, \"address\"). */\nconst GROUPED_SECTIONS = new Set<KycSection>(['ADDRESS'])\n\n/**\n * The order 1508:2616 \u2192 1844:17471 \u2192 1631:7256 \u2192 1631:7883 walks, anything\n * else trailing.\n */\nconst SECTION_ORDER: readonly KycSection[] = [\n 'NAME',\n 'DOB',\n 'NATIONALITY',\n 'COUNTRY',\n 'ADDRESS',\n 'SSN',\n 'PHONE',\n 'OCCUPATION',\n 'EMPLOYMENT',\n 'PURPOSE',\n 'SOURCE_OF_WEALTH',\n 'INCOME',\n 'NET_WORTH',\n 'ACTIVITY',\n 'DETAILS',\n]\n\n/**\n * The page's field a date picker can answer, when that is the whole page.\n *\n * A picker takes the keyboard's slot, so it can only be offered on a page\n * with nothing else to type: a date beside two names would leave one of the\n * two controls covering the other. Anywhere else the date is typed.\n */\nconst IDENTITY_SECTIONS: ReadonlySet<KycSection> = new Set<KycSection>([\n 'NAME',\n 'DOB',\n 'NATIONALITY',\n 'COUNTRY',\n 'ADDRESS',\n 'SSN',\n])\n\n/**\n * The server owns the field list, so an id this build does not know is not\n * identity: only the frames that collect who someone is qualify.\n */\nexport function isIdentityField(field: FormField): boolean {\n const section = SECTION_BY_ID[field.id]\n return section !== undefined && IDENTITY_SECTIONS.has(section)\n}\n\n/**\n * The pages that draw their answers on the page rather than behind a chooser\n * (2475:8992).\n *\n * Named, not inferred from the field's type: `DETAILS` also collects a\n * `SELECT`, but it holds whatever the server asks for that no frame drew, and\n * a list of unknown length is what the chooser's sheet is for.\n */\nconst INLINE_CHOICE_SECTIONS: ReadonlySet<KycSection> = new Set<KycSection>([\n 'OCCUPATION',\n 'EMPLOYMENT',\n 'PURPOSE',\n 'SOURCE_OF_WEALTH',\n])\n\nexport function isInlineChoiceSection(section: KycSection): boolean {\n return INLINE_CHOICE_SECTIONS.has(section)\n}\n\nexport function pickedDateField(page: KycSectionPage): FormField | undefined {\n const fields = page.rows.flat()\n const only = fields.length === 1 ? fields[0] : undefined\n return only?.type === 'DATE' ? only : undefined\n}\n\n/**\n * Whether the field is typed into, and so takes a turn in the return-key\n * chain. A choice is not.\n */\nexport function isFocusableField(field: FormField): boolean {\n return field.type === 'TEXT' || field.type === 'DATE'\n}\n\n/** Pages whose keyboards read \"next\" on the field that tries the page too (1950:2055, 1951:9265). */\nconst NEXT_TO_TRY_SECTIONS: ReadonlySet<KycSection> = new Set<KycSection>([\n 'NAME',\n 'ADDRESS',\n])\n\nexport interface ReturnHop {\n label: 'next' | 'done'\n /** Absent where the return key tries the page instead. */\n to?: FormField\n}\n\n/**\n * Where a typed field's return key goes: the next required typed field.\n *\n * - An optional line is stepped over (2334:7164) but still hands on when the\n * user taps into it.\n */\nexport function returnHop(\n section: KycSection,\n typedFields: readonly FormField[],\n fieldId: string,\n): ReturnHop | undefined {\n const at = typedFields.findIndex((field) => field.id === fieldId)\n if (at < 0) {\n return undefined\n }\n const to = typedFields.slice(at + 1).find((field) => field.required)\n if (to !== undefined) {\n return { label: 'next', to }\n }\n return { label: NEXT_TO_TRY_SECTIONS.has(section) ? 'next' : 'done' }\n}\n\n/**\n * - Digits alone take the number pad, whose missing return key the page\n * answers with Continue (`isDigitsField`).\n * - A hyphen or space needs iOS's digits-first keyboard, which can type it;\n * Android has none, so it keeps letters.\n */\nconst POSTAL_CODE_KEYBOARD: Readonly<\n Record<PostalCodeForm, TextInputProps['keyboardType']>\n> = {\n digits: 'number-pad',\n separated: Platform.OS === 'ios' ? 'numbers-and-punctuation' : undefined,\n}\n\n/**\n * The country a field's keyboard and choices follow.\n *\n * - The tax ID takes the tax residence's, which also names it in the heading.\n * - Every other field takes the address's.\n */\nexport function fieldCountry(\n field: FormField,\n countries: { address?: string; taxResidence?: string },\n): string | undefined {\n return field.id === 'TAX_IDENTIFIER'\n ? countries.taxResidence\n : countries.address\n}\n\n/** `country` is the field's own, from `fieldCountry`. */\nexport function fieldKeyboardType(\n field: FormField,\n country?: string,\n): TextInputProps['keyboardType'] | undefined {\n if (field.type !== 'TEXT') {\n return undefined\n }\n if (field.id === 'RESIDENTIAL_ADDRESS_POSTAL_CODE') {\n const form = postalCodeForm(country)\n return form === undefined ? undefined : POSTAL_CODE_KEYBOARD[form]\n }\n if (field.id === 'TAX_IDENTIFIER') {\n return taxIdentifierKeyboard(country)\n }\n return KEYBOARD_BY_ID[field.id]\n}\n\nconst DIGIT_TAX_IDENTIFIER_COUNTRIES: ReadonlySet<string> = new Set([\n 'US',\n 'BR',\n])\n\nfunction taxIdentifierKeyboard(\n country: string | undefined,\n): TextInputProps['keyboardType'] | undefined {\n if (\n country === undefined ||\n DIGIT_TAX_IDENTIFIER_COUNTRIES.has(country.toUpperCase())\n ) {\n return 'number-pad'\n }\n return undefined\n}\n\n/** Whether the field raises a pad rather than letters, and so has no return key. */\nexport function isDigitsField(field: FormField, country?: string): boolean {\n const keyboardType = fieldKeyboardType(field, country)\n return keyboardType !== undefined && PADS_WITHOUT_RETURN_KEY.has(keyboardType)\n}\n\n/** Whether the field is drawn at a fixed width rather than growing to fill. */\nexport function isFixedWidthField(field: FormField): boolean {\n return field.id === 'LEGAL_MIDDLE_NAME'\n}\n\n/**\n * The form's fields that no page draws.\n *\n * Type only: an unknown id has a page (`DETAILS`), so refusing one would\n * reject a whole form over a field the screens can draw perfectly well. A\n * form with any of these cannot be completed here, so the caller shows its\n * unsupported state rather than a form missing a field the server requires.\n */\nexport function unsupportedFields(fields: readonly FormField[]): FormField[] {\n return fields.filter((field) => !DRAWN_TYPES.has(field.type))\n}\n\n/**\n * Splits a form into the pages the design steps through.\n *\n * Pages keep the design's order; fields keep the server's, so a page that\n * gains a field it already draws renders it without a client release. A page\n * with no fields is not a page.\n */\nexport function sectionPages(fields: readonly FormField[]): KycSectionPage[] {\n const bySection = new Map<KycSection, FormField[]>()\n for (const field of fields) {\n if (!DRAWN_TYPES.has(field.type)) {\n continue\n }\n // A state the provider does not require is not asked: European\n // addresses have none, and the design draws no row for it.\n if (field.id === 'RESIDENTIAL_ADDRESS_REGION' && !field.required) {\n continue\n }\n const section = SECTION_BY_ID[field.id] ?? 'DETAILS'\n const collected = bySection.get(section) ?? []\n collected.push(field)\n bySection.set(section, collected)\n }\n\n return SECTION_ORDER.flatMap<KycSectionPage>((section) => {\n const collected = bySection.get(section)\n if (collected === undefined) {\n return []\n }\n if (isInlineChoiceSection(section) || section === 'DETAILS') {\n return collected.map((field) => ({\n section,\n grouped: false,\n rows: [[field]],\n }))\n }\n return [\n {\n section,\n grouped: GROUPED_SECTIONS.has(section),\n rows:\n section === 'ADDRESS'\n ? addressRows(collected)\n : collected.map((field) => [field]),\n },\n ]\n })\n}\n\n/**\n * The address card as the design lays it out for the country (1631:7256):\n * the street, the apartment line, then the city with the state and ZIP paired\n * under it \u2014 or, where the provider asks for no state, the postal code paired\n * before the city, as a European address reads. A field the design does not\n * place trails on its own row.\n */\nfunction addressRows(fields: readonly FormField[]): FormField[][] {\n const byId = new Map(fields.map((field) => [field.id, field]))\n const take = (id: KycFieldId) => {\n const field = byId.get(id)\n byId.delete(id)\n return field\n }\n const line1 = take('RESIDENTIAL_ADDRESS_LINE_1')\n const line2 = take('RESIDENTIAL_ADDRESS_LINE_2')\n const city = take('RESIDENTIAL_ADDRESS_CITY')\n const region = take('RESIDENTIAL_ADDRESS_REGION')\n const postal = take('RESIDENTIAL_ADDRESS_POSTAL_CODE')\n const rows: (FormField | undefined)[][] = [[line1], [line2]]\n if (region === undefined) {\n rows.push([postal, city])\n } else {\n rows.push([city], [region, postal])\n }\n return [...rows, ...[...byId.values()].map((field) => [field])]\n .map((row) => row.filter((field) => field !== undefined))\n .filter((row) => row.length > 0)\n}\n", "import type { TextInputProps } from 'react-native'\n\n/**\n * Keyboards with no return key. iOS draws a floating button of its own when\n * one of these is asked for a return key, and it lands over the screen's\n * bottom-right \u2014 where the advance control already is.\n */\nexport const PADS_WITHOUT_RETURN_KEY = new Set<TextInputProps['keyboardType']>([\n 'number-pad',\n 'numeric',\n 'decimal-pad',\n 'phone-pad',\n])\n", "/**\n * How a country writes its postal codes, where Google's address metadata\n * (libaddressinput, chromium-i18n.appspot.com/ssl-address/data) and\n * `postcode-validator` agree. Anywhere they disagree is on neither list, so\n * the keyboard stays letters (`postalCodeCountries.drift.test.ts`).\n *\n * - `digits`: codes are written as digits alone. The US ZIP+4 extension and\n * FR's space are optional, and neither is how the post office writes them.\n * - `separated`: digits the country writes split by a hyphen or space\n * (`12345-678`, `123 45`), which a number pad cannot type.\n * - A country whose codes carry any letter (GB, CA, NL, IE, AR, MT, LV\u2026), or\n * that has no postal code, is on neither list.\n */\nexport type PostalCodeForm = 'digits' | 'separated'\n\nconst codes = (list: string): ReadonlySet<string> =>\n new Set(list.trim().split(/\\s+/))\n\nconst DIGIT_COUNTRIES = codes(`\n AF AL AM AS AT AU AX AZ BA BD BE BG BH BL BT BY CC CH CL CN CO CU CV\n CX CY DE DK DO DZ EC EE EG EH ES ET FI FM FO FR GE GF GL GN GP GT GU\n GW HM HN HR HT HU ID IL IN IQ IS IT JO KE KG KH KR KW KZ LA LI LK LR\n LS LT LU MA MC MD ME MF MG MH MK MM MN MP MQ MV MX MY MZ NA NC NE NF\n NG NO NP NZ PF PG PH PK PM PR PW PY RE RO RS RU SA SD SG SI SJ SM SN\n TH TJ TM TN TR TW TZ UA UM US UY UZ VA VE VI VN WF XK YT ZA ZM\n`)\n\nconst SEPARATED_COUNTRIES = codes(`\n BR CR CZ GR IR JP LB PL PT SE SK\n`)\n\nexport function postalCodeForm(\n alpha2: string | undefined,\n): PostalCodeForm | undefined {\n const code = alpha2?.toUpperCase()\n if (code === undefined) {\n return undefined\n }\n if (DIGIT_COUNTRIES.has(code)) {\n return 'digits'\n }\n return SEPARATED_COUNTRIES.has(code) ?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AAC,QAAQ,MAAM,CAAC;AAAA,EACpC;AACA,SAAO,CAAC,GAAG,MAAM,GAAG,CAAC,GAAG,KAAK,OAAO,CAAC,EAAE,IAAI,CAAC,UAAU,CAAC,KAAK,CAAC,CAAC,EAC3D,IAAI,CAAC,QAAQ,IAAI,OAAO,CAAC,UAAU,UAAU,MAAS,CAAC,EACvD,OAAO,CAAC,QAAQ,IAAI,SAAS,CAAC;AACnC;",
6
+ "names": ["createContext", "useContext", "useMemo", "jsx"]
7
+ }
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  useFunkitIdentity
3
- } from "./chunk-W2JG7SK2.js";
3
+ } from "./chunk-KRQW5S2X.js";
4
4
  import {
5
5
  logger
6
6
  } from "./chunk-2HFFVYAZ.js";
@@ -114,4 +114,4 @@ export {
114
114
  useIsStablecoin,
115
115
  useSourceTokenUsdPrice
116
116
  };
117
- //# sourceMappingURL=chunk-HD4PRG6A.js.map
117
+ //# sourceMappingURL=chunk-AXAQRGDI.js.map