@b3dotfun/sdk 0.1.66 → 0.1.68

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 (365) hide show
  1. package/dist/cjs/anyspend/react/components/AnySpend.d.ts +9 -0
  2. package/dist/cjs/anyspend/react/components/AnySpend.js +40 -11
  3. package/dist/cjs/anyspend/react/components/AnySpendBondKit.d.ts +6 -1
  4. package/dist/cjs/anyspend/react/components/AnySpendBondKit.js +2 -2
  5. package/dist/cjs/anyspend/react/components/AnySpendBuySpin.d.ts +7 -1
  6. package/dist/cjs/anyspend/react/components/AnySpendBuySpin.js +2 -2
  7. package/dist/cjs/anyspend/react/components/AnySpendCollectorClubPurchase.d.ts +5 -1
  8. package/dist/cjs/anyspend/react/components/AnySpendCollectorClubPurchase.js +2 -2
  9. package/dist/cjs/anyspend/react/components/AnySpendCustom.d.ts +9 -0
  10. package/dist/cjs/anyspend/react/components/AnySpendCustom.js +16 -14
  11. package/dist/cjs/anyspend/react/components/AnySpendCustomExactIn.d.ts +9 -0
  12. package/dist/cjs/anyspend/react/components/AnySpendCustomExactIn.js +40 -10
  13. package/dist/cjs/anyspend/react/components/AnySpendDeposit.d.ts +10 -1
  14. package/dist/cjs/anyspend/react/components/AnySpendDeposit.js +5 -4
  15. package/dist/cjs/anyspend/react/components/AnySpendDepositUpside.d.ts +7 -1
  16. package/dist/cjs/anyspend/react/components/AnySpendDepositUpside.js +2 -2
  17. package/dist/cjs/anyspend/react/components/AnySpendNFT.d.ts +7 -1
  18. package/dist/cjs/anyspend/react/components/AnySpendNFT.js +2 -2
  19. package/dist/cjs/anyspend/react/components/AnySpendStakeB3.d.ts +7 -1
  20. package/dist/cjs/anyspend/react/components/AnySpendStakeB3.js +2 -2
  21. package/dist/cjs/anyspend/react/components/AnySpendStakeB3ExactIn.d.ts +7 -1
  22. package/dist/cjs/anyspend/react/components/AnySpendStakeB3ExactIn.js +2 -2
  23. package/dist/cjs/anyspend/react/components/AnySpendStakeUpside.d.ts +7 -1
  24. package/dist/cjs/anyspend/react/components/AnySpendStakeUpside.js +2 -2
  25. package/dist/cjs/anyspend/react/components/AnySpendStakeUpsideExactIn.d.ts +7 -1
  26. package/dist/cjs/anyspend/react/components/AnySpendStakeUpsideExactIn.js +2 -2
  27. package/dist/cjs/anyspend/react/components/AnySpendTournament.d.ts +11 -0
  28. package/dist/cjs/anyspend/react/components/AnySpendTournament.js +2 -2
  29. package/dist/cjs/anyspend/react/components/AnyspendDepositHype.d.ts +7 -1
  30. package/dist/cjs/anyspend/react/components/AnyspendDepositHype.js +2 -2
  31. package/dist/cjs/anyspend/react/components/AnyspendSignatureMint.d.ts +5 -1
  32. package/dist/cjs/anyspend/react/components/AnyspendSignatureMint.js +2 -2
  33. package/dist/cjs/anyspend/react/components/checkout/AddressForm.d.ts +9 -0
  34. package/dist/cjs/anyspend/react/components/checkout/AddressForm.js +14 -0
  35. package/dist/cjs/anyspend/react/components/checkout/AnySpendCheckout.d.ts +117 -0
  36. package/dist/cjs/anyspend/react/components/checkout/AnySpendCheckout.js +158 -0
  37. package/dist/cjs/anyspend/react/components/checkout/AnySpendCheckoutTrigger.d.ts +81 -0
  38. package/dist/cjs/anyspend/react/components/checkout/AnySpendCheckoutTrigger.js +61 -0
  39. package/dist/cjs/anyspend/react/components/checkout/CartItemRow.d.ts +8 -0
  40. package/dist/cjs/anyspend/react/components/checkout/CartItemRow.js +9 -0
  41. package/dist/cjs/anyspend/react/components/checkout/CartSummary.d.ts +30 -0
  42. package/dist/cjs/anyspend/react/components/checkout/CartSummary.js +20 -0
  43. package/dist/cjs/anyspend/react/components/checkout/CheckoutCartPanel.d.ts +32 -0
  44. package/dist/cjs/anyspend/react/components/checkout/CheckoutCartPanel.js +27 -0
  45. package/dist/cjs/anyspend/react/components/checkout/CheckoutFormField.d.ts +10 -0
  46. package/dist/cjs/anyspend/react/components/checkout/CheckoutFormField.js +31 -0
  47. package/dist/cjs/anyspend/react/components/checkout/CheckoutFormPanel.d.ts +39 -0
  48. package/dist/cjs/anyspend/react/components/checkout/CheckoutFormPanel.js +75 -0
  49. package/dist/cjs/anyspend/react/components/checkout/CheckoutLayout.d.ts +10 -0
  50. package/dist/cjs/anyspend/react/components/checkout/CheckoutLayout.js +13 -0
  51. package/dist/cjs/anyspend/react/components/checkout/CheckoutOrderStatus.d.ts +28 -0
  52. package/dist/cjs/anyspend/react/components/checkout/CheckoutOrderStatus.js +65 -0
  53. package/dist/cjs/anyspend/react/components/checkout/CheckoutPaymentPanel.d.ts +31 -0
  54. package/dist/cjs/anyspend/react/components/checkout/CheckoutPaymentPanel.js +64 -0
  55. package/dist/cjs/anyspend/react/components/checkout/CheckoutSuccess.d.ts +10 -0
  56. package/dist/cjs/anyspend/react/components/checkout/CheckoutSuccess.js +31 -0
  57. package/dist/cjs/anyspend/react/components/checkout/CoinbaseCheckoutPanel.d.ts +20 -0
  58. package/dist/cjs/anyspend/react/components/checkout/CoinbaseCheckoutPanel.js +170 -0
  59. package/dist/cjs/anyspend/react/components/checkout/CryptoPayPanel.d.ts +23 -0
  60. package/dist/cjs/anyspend/react/components/checkout/CryptoPayPanel.js +324 -0
  61. package/dist/cjs/anyspend/react/components/checkout/DiscountCodeInput.d.ts +12 -0
  62. package/dist/cjs/anyspend/react/components/checkout/DiscountCodeInput.js +62 -0
  63. package/dist/cjs/anyspend/react/components/checkout/FiatCheckoutPanel.d.ts +20 -0
  64. package/dist/cjs/anyspend/react/components/checkout/FiatCheckoutPanel.js +269 -0
  65. package/dist/cjs/anyspend/react/components/checkout/PoweredByBranding.d.ts +8 -0
  66. package/dist/cjs/anyspend/react/components/checkout/PoweredByBranding.js +9 -0
  67. package/dist/cjs/anyspend/react/components/checkout/ShippingSelector.d.ts +11 -0
  68. package/dist/cjs/anyspend/react/components/checkout/ShippingSelector.js +20 -0
  69. package/dist/cjs/anyspend/react/components/common/ConnectWalletPayment.js +19 -5
  70. package/dist/cjs/anyspend/react/components/common/CryptoPaySection.js +1 -1
  71. package/dist/cjs/anyspend/react/components/common/CryptoPaymentMethodDisplay.js +1 -1
  72. package/dist/cjs/anyspend/react/components/common/CryptoReceiveSection.js +1 -1
  73. package/dist/cjs/anyspend/react/components/common/OrderDetailsCollapsible.js +4 -4
  74. package/dist/cjs/anyspend/react/components/common/OrderStatus.d.ts +2 -1
  75. package/dist/cjs/anyspend/react/components/common/OrderStatus.js +93 -19
  76. package/dist/cjs/anyspend/react/components/common/PanelOnramp.js +4 -4
  77. package/dist/cjs/anyspend/react/components/common/PaySection.js +1 -1
  78. package/dist/cjs/anyspend/react/components/common/StepProgress.d.ts +5 -1
  79. package/dist/cjs/anyspend/react/components/common/StepProgress.js +6 -11
  80. package/dist/cjs/anyspend/react/components/common/TransferCryptoDetails.js +1 -1
  81. package/dist/cjs/anyspend/react/components/common/TransferResultScreen.js +5 -1
  82. package/dist/cjs/anyspend/react/components/context/AnySpendCustomizationContext.d.ts +16 -0
  83. package/dist/cjs/anyspend/react/components/context/AnySpendCustomizationContext.js +92 -0
  84. package/dist/cjs/anyspend/react/components/icons/AnimatedCheckmark.d.ts +23 -0
  85. package/dist/cjs/anyspend/react/components/icons/AnimatedCheckmark.js +71 -0
  86. package/dist/cjs/anyspend/react/components/index.d.ts +8 -1
  87. package/dist/cjs/anyspend/react/components/index.js +10 -1
  88. package/dist/cjs/anyspend/react/components/types/classes.d.ts +50 -0
  89. package/dist/cjs/anyspend/react/components/types/customization.d.ts +75 -0
  90. package/dist/cjs/anyspend/react/components/types/customization.js +2 -0
  91. package/dist/cjs/anyspend/react/hooks/useAnyspendCreateOnrampOrder.d.ts +8 -2
  92. package/dist/cjs/anyspend/react/hooks/useAnyspendCreateOrder.d.ts +8 -2
  93. package/dist/cjs/anyspend/react/hooks/useAnyspendFlow.d.ts +15 -3
  94. package/dist/cjs/anyspend/react/hooks/useAnyspendFlow.js +3 -2
  95. package/dist/cjs/anyspend/react/hooks/useCreateDepositFirstOrder.d.ts +9 -2
  96. package/dist/cjs/anyspend/react/hooks/useCreateDepositFirstOrder.js +1 -0
  97. package/dist/cjs/anyspend/services/anyspend.d.ts +1 -0
  98. package/dist/cjs/anyspend/services/anyspend.js +17 -2
  99. package/dist/cjs/anyspend/types/forms.d.ts +92 -0
  100. package/dist/cjs/anyspend/types/forms.js +8 -0
  101. package/dist/cjs/anyspend/utils/format.js +12 -3
  102. package/dist/cjs/app.shared.js +8 -0
  103. package/dist/cjs/global-account/react/components/B3DynamicModal.js +9 -3
  104. package/dist/cjs/global-account/react/components/WalletImage/WalletImage.d.ts +1 -1
  105. package/dist/cjs/global-account/react/components/ui/command.d.ts +7 -7
  106. package/dist/cjs/global-account/react/components/ui/dialog.d.ts +2 -0
  107. package/dist/cjs/global-account/react/components/ui/dialog.js +2 -2
  108. package/dist/cjs/global-account/react/components/ui/drawer.d.ts +3 -1
  109. package/dist/cjs/global-account/react/components/ui/drawer.js +1 -1
  110. package/dist/cjs/global-account/react/hooks/useAuth.d.ts +1 -1
  111. package/dist/cjs/global-account/react/hooks/useAuthentication.d.ts +1 -1
  112. package/dist/cjs/global-account/react/hooks/useFirstEOA.d.ts +4 -4
  113. package/dist/cjs/global-account/react/hooks/useUser.d.ts +1 -1
  114. package/dist/cjs/global-account/react/hooks/useUserQuery.d.ts +1 -1
  115. package/dist/cjs/global-account/react/stores/useModalStore.d.ts +53 -1
  116. package/dist/cjs/shared/constants/chains/b3Chain.d.ts +2 -2
  117. package/dist/cjs/shared/constants/chains/supported.d.ts +3 -3
  118. package/dist/cjs/shared/utils/number.d.ts +5 -0
  119. package/dist/cjs/shared/utils/number.js +13 -0
  120. package/dist/esm/anyspend/react/components/AnySpend.d.ts +9 -0
  121. package/dist/esm/anyspend/react/components/AnySpend.js +41 -12
  122. package/dist/esm/anyspend/react/components/AnySpendBondKit.d.ts +6 -1
  123. package/dist/esm/anyspend/react/components/AnySpendBondKit.js +2 -2
  124. package/dist/esm/anyspend/react/components/AnySpendBuySpin.d.ts +7 -1
  125. package/dist/esm/anyspend/react/components/AnySpendBuySpin.js +2 -2
  126. package/dist/esm/anyspend/react/components/AnySpendCollectorClubPurchase.d.ts +5 -1
  127. package/dist/esm/anyspend/react/components/AnySpendCollectorClubPurchase.js +2 -2
  128. package/dist/esm/anyspend/react/components/AnySpendCustom.d.ts +9 -0
  129. package/dist/esm/anyspend/react/components/AnySpendCustom.js +16 -14
  130. package/dist/esm/anyspend/react/components/AnySpendCustomExactIn.d.ts +9 -0
  131. package/dist/esm/anyspend/react/components/AnySpendCustomExactIn.js +42 -12
  132. package/dist/esm/anyspend/react/components/AnySpendDeposit.d.ts +10 -1
  133. package/dist/esm/anyspend/react/components/AnySpendDeposit.js +5 -4
  134. package/dist/esm/anyspend/react/components/AnySpendDepositUpside.d.ts +7 -1
  135. package/dist/esm/anyspend/react/components/AnySpendDepositUpside.js +2 -2
  136. package/dist/esm/anyspend/react/components/AnySpendNFT.d.ts +7 -1
  137. package/dist/esm/anyspend/react/components/AnySpendNFT.js +2 -2
  138. package/dist/esm/anyspend/react/components/AnySpendStakeB3.d.ts +7 -1
  139. package/dist/esm/anyspend/react/components/AnySpendStakeB3.js +2 -2
  140. package/dist/esm/anyspend/react/components/AnySpendStakeB3ExactIn.d.ts +7 -1
  141. package/dist/esm/anyspend/react/components/AnySpendStakeB3ExactIn.js +2 -2
  142. package/dist/esm/anyspend/react/components/AnySpendStakeUpside.d.ts +7 -1
  143. package/dist/esm/anyspend/react/components/AnySpendStakeUpside.js +2 -2
  144. package/dist/esm/anyspend/react/components/AnySpendStakeUpsideExactIn.d.ts +7 -1
  145. package/dist/esm/anyspend/react/components/AnySpendStakeUpsideExactIn.js +2 -2
  146. package/dist/esm/anyspend/react/components/AnySpendTournament.d.ts +11 -0
  147. package/dist/esm/anyspend/react/components/AnySpendTournament.js +2 -2
  148. package/dist/esm/anyspend/react/components/AnyspendDepositHype.d.ts +7 -1
  149. package/dist/esm/anyspend/react/components/AnyspendDepositHype.js +2 -2
  150. package/dist/esm/anyspend/react/components/AnyspendSignatureMint.d.ts +5 -1
  151. package/dist/esm/anyspend/react/components/AnyspendSignatureMint.js +2 -2
  152. package/dist/esm/anyspend/react/components/checkout/AddressForm.d.ts +9 -0
  153. package/dist/esm/anyspend/react/components/checkout/AddressForm.js +11 -0
  154. package/dist/esm/anyspend/react/components/checkout/AnySpendCheckout.d.ts +117 -0
  155. package/dist/esm/anyspend/react/components/checkout/AnySpendCheckout.js +155 -0
  156. package/dist/esm/anyspend/react/components/checkout/AnySpendCheckoutTrigger.d.ts +81 -0
  157. package/dist/esm/anyspend/react/components/checkout/AnySpendCheckoutTrigger.js +58 -0
  158. package/dist/esm/anyspend/react/components/checkout/CartItemRow.d.ts +8 -0
  159. package/dist/esm/anyspend/react/components/checkout/CartItemRow.js +6 -0
  160. package/dist/esm/anyspend/react/components/checkout/CartSummary.d.ts +30 -0
  161. package/dist/esm/anyspend/react/components/checkout/CartSummary.js +17 -0
  162. package/dist/esm/anyspend/react/components/checkout/CheckoutCartPanel.d.ts +32 -0
  163. package/dist/esm/anyspend/react/components/checkout/CheckoutCartPanel.js +24 -0
  164. package/dist/esm/anyspend/react/components/checkout/CheckoutFormField.d.ts +10 -0
  165. package/dist/esm/anyspend/react/components/checkout/CheckoutFormField.js +28 -0
  166. package/dist/esm/anyspend/react/components/checkout/CheckoutFormPanel.d.ts +39 -0
  167. package/dist/esm/anyspend/react/components/checkout/CheckoutFormPanel.js +72 -0
  168. package/dist/esm/anyspend/react/components/checkout/CheckoutLayout.d.ts +10 -0
  169. package/dist/esm/anyspend/react/components/checkout/CheckoutLayout.js +10 -0
  170. package/dist/esm/anyspend/react/components/checkout/CheckoutOrderStatus.d.ts +28 -0
  171. package/dist/esm/anyspend/react/components/checkout/CheckoutOrderStatus.js +62 -0
  172. package/dist/esm/anyspend/react/components/checkout/CheckoutPaymentPanel.d.ts +31 -0
  173. package/dist/esm/anyspend/react/components/checkout/CheckoutPaymentPanel.js +61 -0
  174. package/dist/esm/anyspend/react/components/checkout/CheckoutSuccess.d.ts +10 -0
  175. package/dist/esm/anyspend/react/components/checkout/CheckoutSuccess.js +28 -0
  176. package/dist/esm/anyspend/react/components/checkout/CoinbaseCheckoutPanel.d.ts +20 -0
  177. package/dist/esm/anyspend/react/components/checkout/CoinbaseCheckoutPanel.js +167 -0
  178. package/dist/esm/anyspend/react/components/checkout/CryptoPayPanel.d.ts +23 -0
  179. package/dist/esm/anyspend/react/components/checkout/CryptoPayPanel.js +321 -0
  180. package/dist/esm/anyspend/react/components/checkout/DiscountCodeInput.d.ts +12 -0
  181. package/dist/esm/anyspend/react/components/checkout/DiscountCodeInput.js +59 -0
  182. package/dist/esm/anyspend/react/components/checkout/FiatCheckoutPanel.d.ts +20 -0
  183. package/dist/esm/anyspend/react/components/checkout/FiatCheckoutPanel.js +266 -0
  184. package/dist/esm/anyspend/react/components/checkout/PoweredByBranding.d.ts +8 -0
  185. package/dist/esm/anyspend/react/components/checkout/PoweredByBranding.js +6 -0
  186. package/dist/esm/anyspend/react/components/checkout/ShippingSelector.d.ts +11 -0
  187. package/dist/esm/anyspend/react/components/checkout/ShippingSelector.js +17 -0
  188. package/dist/esm/anyspend/react/components/common/ConnectWalletPayment.js +19 -5
  189. package/dist/esm/anyspend/react/components/common/CryptoPaySection.js +1 -1
  190. package/dist/esm/anyspend/react/components/common/CryptoPaymentMethodDisplay.js +1 -1
  191. package/dist/esm/anyspend/react/components/common/CryptoReceiveSection.js +1 -1
  192. package/dist/esm/anyspend/react/components/common/OrderDetailsCollapsible.js +4 -4
  193. package/dist/esm/anyspend/react/components/common/OrderStatus.d.ts +2 -1
  194. package/dist/esm/anyspend/react/components/common/OrderStatus.js +96 -22
  195. package/dist/esm/anyspend/react/components/common/PanelOnramp.js +4 -4
  196. package/dist/esm/anyspend/react/components/common/PaySection.js +1 -1
  197. package/dist/esm/anyspend/react/components/common/StepProgress.d.ts +5 -1
  198. package/dist/esm/anyspend/react/components/common/StepProgress.js +6 -11
  199. package/dist/esm/anyspend/react/components/common/TransferCryptoDetails.js +1 -1
  200. package/dist/esm/anyspend/react/components/common/TransferResultScreen.js +7 -3
  201. package/dist/esm/anyspend/react/components/context/AnySpendCustomizationContext.d.ts +16 -0
  202. package/dist/esm/anyspend/react/components/context/AnySpendCustomizationContext.js +88 -0
  203. package/dist/esm/anyspend/react/components/icons/AnimatedCheckmark.d.ts +23 -0
  204. package/dist/esm/anyspend/react/components/icons/AnimatedCheckmark.js +68 -0
  205. package/dist/esm/anyspend/react/components/index.d.ts +8 -1
  206. package/dist/esm/anyspend/react/components/index.js +5 -0
  207. package/dist/esm/anyspend/react/components/types/classes.d.ts +50 -0
  208. package/dist/esm/anyspend/react/components/types/customization.d.ts +75 -0
  209. package/dist/esm/anyspend/react/components/types/customization.js +1 -0
  210. package/dist/esm/anyspend/react/hooks/useAnyspendCreateOnrampOrder.d.ts +8 -2
  211. package/dist/esm/anyspend/react/hooks/useAnyspendCreateOrder.d.ts +8 -2
  212. package/dist/esm/anyspend/react/hooks/useAnyspendFlow.d.ts +15 -3
  213. package/dist/esm/anyspend/react/hooks/useAnyspendFlow.js +3 -2
  214. package/dist/esm/anyspend/react/hooks/useCreateDepositFirstOrder.d.ts +9 -2
  215. package/dist/esm/anyspend/react/hooks/useCreateDepositFirstOrder.js +1 -0
  216. package/dist/esm/anyspend/services/anyspend.d.ts +1 -0
  217. package/dist/esm/anyspend/services/anyspend.js +17 -2
  218. package/dist/esm/anyspend/types/forms.d.ts +92 -0
  219. package/dist/esm/anyspend/types/forms.js +7 -0
  220. package/dist/esm/anyspend/utils/format.js +12 -3
  221. package/dist/esm/app.shared.js +8 -0
  222. package/dist/esm/global-account/react/components/B3DynamicModal.js +9 -3
  223. package/dist/esm/global-account/react/components/WalletImage/WalletImage.d.ts +1 -1
  224. package/dist/esm/global-account/react/components/ui/command.d.ts +7 -7
  225. package/dist/esm/global-account/react/components/ui/dialog.d.ts +2 -0
  226. package/dist/esm/global-account/react/components/ui/dialog.js +2 -2
  227. package/dist/esm/global-account/react/components/ui/drawer.d.ts +3 -1
  228. package/dist/esm/global-account/react/components/ui/drawer.js +1 -1
  229. package/dist/esm/global-account/react/hooks/useAuth.d.ts +1 -1
  230. package/dist/esm/global-account/react/hooks/useAuthentication.d.ts +1 -1
  231. package/dist/esm/global-account/react/hooks/useFirstEOA.d.ts +4 -4
  232. package/dist/esm/global-account/react/hooks/useUser.d.ts +1 -1
  233. package/dist/esm/global-account/react/hooks/useUserQuery.d.ts +1 -1
  234. package/dist/esm/global-account/react/stores/useModalStore.d.ts +53 -1
  235. package/dist/esm/shared/constants/chains/b3Chain.d.ts +2 -2
  236. package/dist/esm/shared/constants/chains/supported.d.ts +3 -3
  237. package/dist/esm/shared/utils/number.d.ts +5 -0
  238. package/dist/esm/shared/utils/number.js +12 -0
  239. package/dist/styles/index.css +1 -1
  240. package/dist/types/anyspend/react/components/AnySpend.d.ts +9 -0
  241. package/dist/types/anyspend/react/components/AnySpendBondKit.d.ts +6 -1
  242. package/dist/types/anyspend/react/components/AnySpendBuySpin.d.ts +7 -1
  243. package/dist/types/anyspend/react/components/AnySpendCollectorClubPurchase.d.ts +5 -1
  244. package/dist/types/anyspend/react/components/AnySpendCustom.d.ts +9 -0
  245. package/dist/types/anyspend/react/components/AnySpendCustomExactIn.d.ts +9 -0
  246. package/dist/types/anyspend/react/components/AnySpendDeposit.d.ts +10 -1
  247. package/dist/types/anyspend/react/components/AnySpendDepositUpside.d.ts +7 -1
  248. package/dist/types/anyspend/react/components/AnySpendNFT.d.ts +7 -1
  249. package/dist/types/anyspend/react/components/AnySpendStakeB3.d.ts +7 -1
  250. package/dist/types/anyspend/react/components/AnySpendStakeB3ExactIn.d.ts +7 -1
  251. package/dist/types/anyspend/react/components/AnySpendStakeUpside.d.ts +7 -1
  252. package/dist/types/anyspend/react/components/AnySpendStakeUpsideExactIn.d.ts +7 -1
  253. package/dist/types/anyspend/react/components/AnySpendTournament.d.ts +11 -0
  254. package/dist/types/anyspend/react/components/AnyspendDepositHype.d.ts +7 -1
  255. package/dist/types/anyspend/react/components/AnyspendSignatureMint.d.ts +5 -1
  256. package/dist/types/anyspend/react/components/checkout/AddressForm.d.ts +9 -0
  257. package/dist/types/anyspend/react/components/checkout/AnySpendCheckout.d.ts +117 -0
  258. package/dist/types/anyspend/react/components/checkout/AnySpendCheckoutTrigger.d.ts +81 -0
  259. package/dist/types/anyspend/react/components/checkout/CartItemRow.d.ts +8 -0
  260. package/dist/types/anyspend/react/components/checkout/CartSummary.d.ts +30 -0
  261. package/dist/types/anyspend/react/components/checkout/CheckoutCartPanel.d.ts +32 -0
  262. package/dist/types/anyspend/react/components/checkout/CheckoutFormField.d.ts +10 -0
  263. package/dist/types/anyspend/react/components/checkout/CheckoutFormPanel.d.ts +39 -0
  264. package/dist/types/anyspend/react/components/checkout/CheckoutLayout.d.ts +10 -0
  265. package/dist/types/anyspend/react/components/checkout/CheckoutOrderStatus.d.ts +28 -0
  266. package/dist/types/anyspend/react/components/checkout/CheckoutPaymentPanel.d.ts +31 -0
  267. package/dist/types/anyspend/react/components/checkout/CheckoutSuccess.d.ts +10 -0
  268. package/dist/types/anyspend/react/components/checkout/CoinbaseCheckoutPanel.d.ts +20 -0
  269. package/dist/types/anyspend/react/components/checkout/CryptoPayPanel.d.ts +23 -0
  270. package/dist/types/anyspend/react/components/checkout/DiscountCodeInput.d.ts +12 -0
  271. package/dist/types/anyspend/react/components/checkout/FiatCheckoutPanel.d.ts +20 -0
  272. package/dist/types/anyspend/react/components/checkout/PoweredByBranding.d.ts +8 -0
  273. package/dist/types/anyspend/react/components/checkout/ShippingSelector.d.ts +11 -0
  274. package/dist/types/anyspend/react/components/common/OrderStatus.d.ts +2 -1
  275. package/dist/types/anyspend/react/components/common/StepProgress.d.ts +5 -1
  276. package/dist/types/anyspend/react/components/context/AnySpendCustomizationContext.d.ts +16 -0
  277. package/dist/types/anyspend/react/components/icons/AnimatedCheckmark.d.ts +23 -0
  278. package/dist/types/anyspend/react/components/index.d.ts +8 -1
  279. package/dist/types/anyspend/react/components/types/classes.d.ts +50 -0
  280. package/dist/types/anyspend/react/components/types/customization.d.ts +75 -0
  281. package/dist/types/anyspend/react/hooks/useAnyspendCreateOnrampOrder.d.ts +8 -2
  282. package/dist/types/anyspend/react/hooks/useAnyspendCreateOrder.d.ts +8 -2
  283. package/dist/types/anyspend/react/hooks/useAnyspendFlow.d.ts +15 -3
  284. package/dist/types/anyspend/react/hooks/useCreateDepositFirstOrder.d.ts +9 -2
  285. package/dist/types/anyspend/services/anyspend.d.ts +1 -0
  286. package/dist/types/anyspend/types/forms.d.ts +92 -0
  287. package/dist/types/global-account/react/components/WalletImage/WalletImage.d.ts +1 -1
  288. package/dist/types/global-account/react/components/ui/command.d.ts +7 -7
  289. package/dist/types/global-account/react/components/ui/dialog.d.ts +2 -0
  290. package/dist/types/global-account/react/components/ui/drawer.d.ts +3 -1
  291. package/dist/types/global-account/react/hooks/useAuth.d.ts +1 -1
  292. package/dist/types/global-account/react/hooks/useAuthentication.d.ts +1 -1
  293. package/dist/types/global-account/react/hooks/useFirstEOA.d.ts +4 -4
  294. package/dist/types/global-account/react/hooks/useUser.d.ts +1 -1
  295. package/dist/types/global-account/react/hooks/useUserQuery.d.ts +1 -1
  296. package/dist/types/global-account/react/stores/useModalStore.d.ts +53 -1
  297. package/dist/types/shared/constants/chains/b3Chain.d.ts +2 -2
  298. package/dist/types/shared/constants/chains/supported.d.ts +3 -3
  299. package/dist/types/shared/utils/number.d.ts +5 -0
  300. package/package.json +1 -1
  301. package/src/anyspend/react/components/AnySpend.tsx +84 -37
  302. package/src/anyspend/react/components/AnySpendBondKit.tsx +12 -1
  303. package/src/anyspend/react/components/AnySpendBuySpin.tsx +14 -0
  304. package/src/anyspend/react/components/AnySpendCollectorClubPurchase.tsx +10 -0
  305. package/src/anyspend/react/components/AnySpendCustom.tsx +38 -20
  306. package/src/anyspend/react/components/AnySpendCustomExactIn.tsx +82 -35
  307. package/src/anyspend/react/components/AnySpendDeposit.tsx +24 -2
  308. package/src/anyspend/react/components/AnySpendDepositUpside.tsx +14 -0
  309. package/src/anyspend/react/components/AnySpendNFT.tsx +14 -0
  310. package/src/anyspend/react/components/AnySpendStakeB3.tsx +14 -0
  311. package/src/anyspend/react/components/AnySpendStakeB3ExactIn.tsx +14 -0
  312. package/src/anyspend/react/components/AnySpendStakeUpside.tsx +14 -0
  313. package/src/anyspend/react/components/AnySpendStakeUpsideExactIn.tsx +14 -0
  314. package/src/anyspend/react/components/AnySpendTournament.tsx +19 -0
  315. package/src/anyspend/react/components/AnyspendDepositHype.tsx +14 -0
  316. package/src/anyspend/react/components/AnyspendSignatureMint.tsx +10 -0
  317. package/src/anyspend/react/components/checkout/AddressForm.tsx +98 -0
  318. package/src/anyspend/react/components/checkout/AnySpendCheckout.tsx +398 -0
  319. package/src/anyspend/react/components/checkout/AnySpendCheckoutTrigger.tsx +221 -0
  320. package/src/anyspend/react/components/checkout/CartItemRow.tsx +58 -0
  321. package/src/anyspend/react/components/checkout/CartSummary.tsx +158 -0
  322. package/src/anyspend/react/components/checkout/CheckoutCartPanel.tsx +98 -0
  323. package/src/anyspend/react/components/checkout/CheckoutFormField.tsx +129 -0
  324. package/src/anyspend/react/components/checkout/CheckoutFormPanel.tsx +241 -0
  325. package/src/anyspend/react/components/checkout/CheckoutLayout.tsx +52 -0
  326. package/src/anyspend/react/components/checkout/CheckoutOrderStatus.tsx +224 -0
  327. package/src/anyspend/react/components/checkout/CheckoutPaymentPanel.tsx +341 -0
  328. package/src/anyspend/react/components/checkout/CheckoutSuccess.tsx +110 -0
  329. package/src/anyspend/react/components/checkout/CoinbaseCheckoutPanel.tsx +279 -0
  330. package/src/anyspend/react/components/checkout/CryptoPayPanel.tsx +630 -0
  331. package/src/anyspend/react/components/checkout/DiscountCodeInput.tsx +127 -0
  332. package/src/anyspend/react/components/checkout/FiatCheckoutPanel.tsx +612 -0
  333. package/src/anyspend/react/components/checkout/PoweredByBranding.tsx +42 -0
  334. package/src/anyspend/react/components/checkout/ShippingSelector.tsx +73 -0
  335. package/src/anyspend/react/components/common/ConnectWalletPayment.tsx +29 -7
  336. package/src/anyspend/react/components/common/CryptoPaySection.tsx +1 -1
  337. package/src/anyspend/react/components/common/CryptoPaymentMethodDisplay.tsx +1 -1
  338. package/src/anyspend/react/components/common/CryptoReceiveSection.tsx +2 -2
  339. package/src/anyspend/react/components/common/OrderDetailsCollapsible.tsx +5 -5
  340. package/src/anyspend/react/components/common/OrderStatus.tsx +140 -34
  341. package/src/anyspend/react/components/common/PanelOnramp.tsx +9 -9
  342. package/src/anyspend/react/components/common/PaySection.tsx +1 -1
  343. package/src/anyspend/react/components/common/StepProgress.tsx +40 -52
  344. package/src/anyspend/react/components/common/TokenBalance.tsx +0 -12
  345. package/src/anyspend/react/components/common/TransferCryptoDetails.tsx +1 -9
  346. package/src/anyspend/react/components/common/TransferResultScreen.tsx +19 -11
  347. package/src/anyspend/react/components/context/AnySpendCustomizationContext.tsx +124 -0
  348. package/src/anyspend/react/components/icons/AnimatedCheckmark.tsx +119 -0
  349. package/src/anyspend/react/components/index.ts +33 -0
  350. package/src/anyspend/react/components/types/classes.ts +70 -0
  351. package/src/anyspend/react/components/types/customization.ts +99 -0
  352. package/src/anyspend/react/hooks/useAnyspendCreateOnrampOrder.ts +3 -2
  353. package/src/anyspend/react/hooks/useAnyspendCreateOrder.ts +3 -2
  354. package/src/anyspend/react/hooks/useAnyspendFlow.ts +5 -1
  355. package/src/anyspend/react/hooks/useCreateDepositFirstOrder.ts +5 -2
  356. package/src/anyspend/services/anyspend.ts +19 -2
  357. package/src/anyspend/types/forms.ts +97 -0
  358. package/src/anyspend/utils/format.ts +12 -3
  359. package/src/app.shared.ts +11 -0
  360. package/src/global-account/react/components/B3DynamicModal.tsx +13 -4
  361. package/src/global-account/react/components/ui/dialog.tsx +17 -8
  362. package/src/global-account/react/components/ui/drawer.tsx +2 -2
  363. package/src/global-account/react/stores/useModalStore.ts +52 -1
  364. package/src/shared/utils/number.ts +12 -0
  365. package/src/styles/index.css +48 -2
@@ -11,6 +11,8 @@ type DialogContentElement = React.ElementRef<typeof DialogPrimitive.Content>;
11
11
  type DialogContentProps = React.ComponentPropsWithoutRef<typeof DialogPrimitive.Content> & {
12
12
  hideCloseButton?: boolean;
13
13
  closeBtnClassName?: string;
14
+ /** Hide the "Global Account" branding footer below the modal */
15
+ hideGABranding?: boolean;
14
16
  };
15
17
  declare const DialogContent: React.ForwardRefExoticComponent<DialogContentProps & React.RefAttributes<DialogContentElement>>;
16
18
  declare const DialogHeader: {
@@ -51,9 +51,9 @@ exports.DialogClose = DialogClose;
51
51
  const DialogOverlay = React.forwardRef(({ className, ...props }, ref) => ((0, jsx_runtime_1.jsx)(DialogPrimitive.Overlay, { ref: ref, className: (0, utils_1.cn)("fixed inset-0 z-50 bg-black/80 backdrop-blur-[20px]", "data-[state=open]:animate-in data-[state=closed]:animate-out", "data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0", "data-[state=closed]:backdrop-blur-none data-[state=open]:backdrop-blur-[20px]", "transition-all duration-300", className), ...props })));
52
52
  exports.DialogOverlay = DialogOverlay;
53
53
  DialogOverlay.displayName = DialogPrimitive.Overlay.displayName;
54
- const DialogContent = React.forwardRef(({ className, children, hideCloseButton = true, closeBtnClassName, ...props }, ref) => {
54
+ const DialogContent = React.forwardRef(({ className, children, hideCloseButton = true, closeBtnClassName, hideGABranding, ...props }, ref) => {
55
55
  const container = typeof window !== "undefined" ? document.getElementById("b3-root") : null;
56
- return ((0, jsx_runtime_1.jsxs)(DialogPortal, { container: container, children: [(0, jsx_runtime_1.jsx)(DialogOverlay, {}), (0, jsx_runtime_1.jsxs)(DialogPrimitive.Content, { ref: ref, className: (0, utils_1.cn)("fixed left-1/2 top-1/2 z-50 grid w-full max-w-lg -translate-x-1/2 -translate-y-1/2 border shadow-lg !outline-none", "data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 duration-500", "data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95", "data-[state=closed]:slide-out-to-left-1/2 data-[state=closed]:slide-out-to-top-[48%] data-[state=open]:slide-in-from-left-1/2 data-[state=open]:slide-in-from-top-[48%]", "[perspective:1200px] [transform-style:preserve-3d] sm:rounded-xl", "transition-all ease-out", className), ...props, children: [(0, jsx_runtime_1.jsxs)("div", { className: "modal-inner-content mb-[23px] flex flex-1 flex-col overflow-hidden rounded-xl border border-[#D1D1D6] bg-white shadow-[0_20px_24px_-4px_rgba(10,13,18,0.08),0_8px_8px_-4px_rgba(10,13,18,0.03),0_3px_3px_-1.5px_rgba(10,13,18,0.04)]", children: [children, !hideCloseButton && ((0, jsx_runtime_1.jsxs)(DialogPrimitive.Close, { className: (0, utils_1.cn)("modal-close-button data-[state=open]:bg-b3-react-background data-[state=open]:text-b3-react-muted-foreground absolute right-2 top-2 rounded-sm opacity-70 transition-opacity hover:opacity-100 focus:outline-none disabled:pointer-events-none dark:data-[state=open]:bg-gray-800 dark:data-[state=open]:text-gray-400", closeBtnClassName), children: [(0, jsx_runtime_1.jsx)(lucide_react_1.X, { className: "h-5 w-5" }), (0, jsx_runtime_1.jsx)("span", { className: "sr-only", children: "Close" })] }))] }), (0, jsx_runtime_1.jsxs)("div", { className: "b3-modal-ga-branding absolute bottom-[10px] left-0 right-0 flex items-center justify-center gap-1.5 pt-[10px]", children: [(0, jsx_runtime_1.jsx)("img", { src: "https://cdn.b3.fun/b3_logo.svg", alt: "B3", className: "h-4 w-4" }), (0, jsx_runtime_1.jsx)("span", { className: "font-neue-montreal-semibold text-xs uppercase leading-none tracking-[0.72px] text-[#0B57C2]", children: "Global Account" })] })] })] }));
56
+ return ((0, jsx_runtime_1.jsxs)(DialogPortal, { container: container, children: [(0, jsx_runtime_1.jsx)(DialogOverlay, {}), (0, jsx_runtime_1.jsxs)(DialogPrimitive.Content, { ref: ref, className: (0, utils_1.cn)("fixed left-1/2 top-1/2 z-50 grid w-full max-w-lg -translate-x-1/2 -translate-y-1/2 border shadow-lg !outline-none", "data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 duration-500", "data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95", "data-[state=closed]:slide-out-to-left-1/2 data-[state=closed]:slide-out-to-top-[48%] data-[state=open]:slide-in-from-left-1/2 data-[state=open]:slide-in-from-top-[48%]", "[perspective:1200px] [transform-style:preserve-3d] sm:rounded-xl", "transition-all ease-out", className), ...props, children: [(0, jsx_runtime_1.jsxs)("div", { className: (0, utils_1.cn)("modal-inner-content flex flex-1 flex-col overflow-hidden rounded-xl border border-[#D1D1D6] bg-white shadow-[0_20px_24px_-4px_rgba(10,13,18,0.08),0_8px_8px_-4px_rgba(10,13,18,0.03),0_3px_3px_-1.5px_rgba(10,13,18,0.04)] dark:border-neutral-700 dark:bg-neutral-900", !hideGABranding && "mb-[23px]"), children: [children, !hideCloseButton && ((0, jsx_runtime_1.jsxs)(DialogPrimitive.Close, { className: (0, utils_1.cn)("modal-close-button data-[state=open]:bg-b3-react-background data-[state=open]:text-b3-react-muted-foreground absolute right-2 top-2 rounded-sm opacity-70 transition-opacity hover:opacity-100 focus:outline-none disabled:pointer-events-none dark:data-[state=open]:bg-gray-800 dark:data-[state=open]:text-gray-400", closeBtnClassName), children: [(0, jsx_runtime_1.jsx)(lucide_react_1.X, { className: "h-5 w-5" }), (0, jsx_runtime_1.jsx)("span", { className: "sr-only", children: "Close" })] }))] }), !hideGABranding && ((0, jsx_runtime_1.jsxs)("div", { className: "b3-modal-ga-branding absolute bottom-[10px] left-0 right-0 flex items-center justify-center gap-1.5 pt-[10px]", children: [(0, jsx_runtime_1.jsx)("img", { src: "https://cdn.b3.fun/b3_logo.svg", alt: "B3", className: "h-4 w-4" }), (0, jsx_runtime_1.jsx)("span", { className: "font-neue-montreal-semibold text-xs uppercase leading-none tracking-[0.72px] text-[#0B57C2]", children: "Global Account" })] }))] })] }));
57
57
  });
58
58
  exports.DialogContent = DialogContent;
59
59
  DialogContent.displayName = DialogPrimitive.Content.displayName;
@@ -8,7 +8,9 @@ declare const DrawerTrigger: React.ForwardRefExoticComponent<import("@radix-ui/r
8
8
  declare const DrawerPortal: typeof import("vaul").Portal;
9
9
  declare const DrawerClose: React.ForwardRefExoticComponent<import("@radix-ui/react-dialog").DialogCloseProps & React.RefAttributes<HTMLButtonElement>>;
10
10
  declare const DrawerOverlay: React.ForwardRefExoticComponent<Omit<Omit<import("@radix-ui/react-dialog").DialogOverlayProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
11
- declare const DrawerContent: React.ForwardRefExoticComponent<Omit<Omit<import("@radix-ui/react-dialog").DialogContentProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
11
+ declare const DrawerContent: React.ForwardRefExoticComponent<Omit<Omit<import("@radix-ui/react-dialog").DialogContentProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>, "ref"> & {
12
+ hideGABranding?: boolean;
13
+ } & React.RefAttributes<HTMLDivElement>>;
12
14
  declare const DrawerHeader: {
13
15
  ({ className, ...props }: React.HTMLAttributes<HTMLDivElement>): import("react/jsx-runtime").JSX.Element;
14
16
  displayName: string;
@@ -51,7 +51,7 @@ exports.DrawerClose = DrawerClose;
51
51
  const DrawerOverlay = React.forwardRef(({ className, ...props }, ref) => ((0, jsx_runtime_1.jsx)(vaul_1.Drawer.Overlay, { ref: ref, className: (0, utils_1.cn)("fixed inset-0 z-50 bg-black/80", className), ...props })));
52
52
  exports.DrawerOverlay = DrawerOverlay;
53
53
  DrawerOverlay.displayName = vaul_1.Drawer.Overlay.displayName;
54
- const DrawerContent = React.forwardRef(({ className, children, ...props }, ref) => {
54
+ const DrawerContent = React.forwardRef(({ className, children, hideGABranding: _hideGABranding, ...props }, ref) => {
55
55
  const container = typeof window !== "undefined" ? document.getElementById("b3-root") : null;
56
56
  return ((0, jsx_runtime_1.jsxs)(DrawerPortal, { container: container, children: [(0, jsx_runtime_1.jsx)(DrawerOverlay, {}), (0, jsx_runtime_1.jsx)(vaul_1.Drawer.Content, { ref: ref, className: (0, utils_1.cn)("bg-b3-react-background fixed inset-x-0 bottom-0 z-50 mt-24 flex h-auto flex-col rounded-t-[10px] border py-6 pt-5", className), ...props, children: children })] }));
57
57
  });
@@ -48,8 +48,8 @@ export declare function useAuth(): {
48
48
  name?: string | undefined;
49
49
  address?: string | undefined;
50
50
  email?: string | undefined;
51
- username?: string | undefined;
52
51
  phone?: string | undefined;
52
+ username?: string | undefined;
53
53
  fid?: string | undefined;
54
54
  };
55
55
  }[] | undefined;
@@ -41,8 +41,8 @@ export declare function useAuthentication(partnerId: string): {
41
41
  name?: string | undefined;
42
42
  address?: string | undefined;
43
43
  email?: string | undefined;
44
- username?: string | undefined;
45
44
  phone?: string | undefined;
45
+ username?: string | undefined;
46
46
  fid?: string | undefined;
47
47
  };
48
48
  }[] | undefined;
@@ -7451,6 +7451,8 @@ export declare function useFirstEOA(chain?: {
7451
7451
  [x: `bool[${string}]`]: undefined;
7452
7452
  [x: `bytes[${string}]`]: undefined;
7453
7453
  [x: `bytes1[${string}]`]: undefined;
7454
+ [x: `bytes4[${string}]`]: undefined;
7455
+ [x: `bytes30[${string}]`]: undefined;
7454
7456
  [x: `bytes18[${string}]`]: undefined;
7455
7457
  [x: `bytes6[${string}]`]: undefined;
7456
7458
  [x: `bytes9[${string}]`]: undefined;
@@ -7458,7 +7460,6 @@ export declare function useFirstEOA(chain?: {
7458
7460
  [x: `bytes10[${string}]`]: undefined;
7459
7461
  [x: `bytes2[${string}]`]: undefined;
7460
7462
  [x: `bytes3[${string}]`]: undefined;
7461
- [x: `bytes4[${string}]`]: undefined;
7462
7463
  [x: `bytes5[${string}]`]: undefined;
7463
7464
  [x: `bytes7[${string}]`]: undefined;
7464
7465
  [x: `bytes11[${string}]`]: undefined;
@@ -7479,7 +7480,6 @@ export declare function useFirstEOA(chain?: {
7479
7480
  [x: `bytes27[${string}]`]: undefined;
7480
7481
  [x: `bytes28[${string}]`]: undefined;
7481
7482
  [x: `bytes29[${string}]`]: undefined;
7482
- [x: `bytes30[${string}]`]: undefined;
7483
7483
  [x: `bytes31[${string}]`]: undefined;
7484
7484
  [x: `bytes32[${string}]`]: undefined;
7485
7485
  [x: `int[${string}]`]: undefined;
@@ -7553,6 +7553,8 @@ export declare function useFirstEOA(chain?: {
7553
7553
  bool?: undefined;
7554
7554
  bytes?: undefined;
7555
7555
  bytes1?: undefined;
7556
+ bytes4?: undefined;
7557
+ bytes30?: undefined;
7556
7558
  bytes18?: undefined;
7557
7559
  bytes6?: undefined;
7558
7560
  bytes9?: undefined;
@@ -7560,7 +7562,6 @@ export declare function useFirstEOA(chain?: {
7560
7562
  bytes10?: undefined;
7561
7563
  bytes2?: undefined;
7562
7564
  bytes3?: undefined;
7563
- bytes4?: undefined;
7564
7565
  bytes5?: undefined;
7565
7566
  bytes7?: undefined;
7566
7567
  bytes11?: undefined;
@@ -7581,7 +7582,6 @@ export declare function useFirstEOA(chain?: {
7581
7582
  bytes27?: undefined;
7582
7583
  bytes28?: undefined;
7583
7584
  bytes29?: undefined;
7584
- bytes30?: undefined;
7585
7585
  bytes31?: undefined;
7586
7586
  bytes32?: undefined;
7587
7587
  int56?: undefined;
@@ -32,8 +32,8 @@ export declare function useUser(): {
32
32
  name?: string | undefined;
33
33
  address?: string | undefined;
34
34
  email?: string | undefined;
35
- username?: string | undefined;
36
35
  phone?: string | undefined;
36
+ username?: string | undefined;
37
37
  fid?: string | undefined;
38
38
  };
39
39
  }[] | undefined;
@@ -36,8 +36,8 @@ export declare function useUserQuery(): {
36
36
  name?: string | undefined;
37
37
  address?: string | undefined;
38
38
  email?: string | undefined;
39
- username?: string | undefined;
40
39
  phone?: string | undefined;
40
+ username?: string | undefined;
41
41
  fid?: string | undefined;
42
42
  };
43
43
  }[] | undefined;
@@ -481,6 +481,58 @@ export interface AnySpendCollectorClubPurchaseProps extends BaseModalProps {
481
481
  * Props for the AnySpend Workflow Trigger modal
482
482
  * Handles payments that trigger b3os-workflow runs
483
483
  */
484
+ /**
485
+ * Props for the AnySpend Checkout Trigger modal
486
+ * Shopify-style checkout with predefined destination token and amount
487
+ */
488
+ export interface AnySpendCheckoutTriggerModalProps extends BaseModalProps {
489
+ /** Modal type identifier */
490
+ type: "anySpendCheckoutTrigger";
491
+ /** Payment recipient address (hex) */
492
+ recipientAddress: string;
493
+ /** Destination token address */
494
+ destinationTokenAddress: string;
495
+ /** Destination chain ID */
496
+ destinationTokenChainId: number;
497
+ /** Line items to display in the cart (optional — if omitted, only the payment panel is shown) */
498
+ items?: Array<{
499
+ id?: string;
500
+ name: string;
501
+ description?: string;
502
+ imageUrl?: string;
503
+ amount: string;
504
+ quantity: number;
505
+ }>;
506
+ /** Total amount in wei — required when items are not provided */
507
+ totalAmount?: string;
508
+ /** Organization name */
509
+ organizationName?: string;
510
+ /** Organization logo URL */
511
+ organizationLogo?: string;
512
+ /** Theme color (hex) */
513
+ themeColor?: string;
514
+ /** Custom button text */
515
+ buttonText?: string;
516
+ /** Workflow ID to trigger on payment */
517
+ workflowId?: string;
518
+ /** Organization ID that owns the workflow */
519
+ orgId?: string;
520
+ /** Optional callback metadata merged into the order */
521
+ callbackMetadata?: {
522
+ inputs?: Record<string, unknown>;
523
+ } & Record<string, unknown>;
524
+ /** Called on successful payment */
525
+ onSuccess?: (result: {
526
+ txHash?: string;
527
+ orderId?: string;
528
+ }) => void;
529
+ /** Called on payment error */
530
+ onError?: (error: Error) => void;
531
+ /** URL to redirect to after payment */
532
+ returnUrl?: string;
533
+ /** Label for the return button */
534
+ returnLabel?: string;
535
+ }
484
536
  export interface AnySpendWorkflowTriggerModalProps extends BaseModalProps {
485
537
  /** Modal type identifier */
486
538
  type: "anySpendWorkflowTrigger";
@@ -574,7 +626,7 @@ export interface AnySpendDepositModalProps extends BaseModalProps {
574
626
  /**
575
627
  * Union type of all possible modal content types
576
628
  */
577
- export type ModalContentType = SignInWithB3ModalProps | RequestPermissionsModalProps | ManageAccountModalProps | AnySpendModalProps | AnyspendOrderDetailsProps | AnySpendNftProps | AnySpendJoinTournamentProps | AnySpendFundTournamentProps | AnySpendOrderHistoryProps | AnySpendStakeB3Props | AnySpendStakeB3ExactInProps | AnySpendStakeUpsideProps | AnySpendStakeUpsideExactInProps | AnySpendDepositUpsideProps | AnySpendBuySpinProps | AnySpendSignatureMintProps | AnySpendBondKitProps | LinkAccountModalProps | LinkNewAccountModalProps | AnySpendDepositHypeProps | AvatarEditorModalProps | DepositModalProps | SendModalProps | NotificationsModalProps | AnySpendCollectorClubPurchaseProps | AnySpendDepositModalProps | AnySpendWorkflowTriggerModalProps;
629
+ export type ModalContentType = SignInWithB3ModalProps | RequestPermissionsModalProps | ManageAccountModalProps | AnySpendModalProps | AnyspendOrderDetailsProps | AnySpendNftProps | AnySpendJoinTournamentProps | AnySpendFundTournamentProps | AnySpendOrderHistoryProps | AnySpendStakeB3Props | AnySpendStakeB3ExactInProps | AnySpendStakeUpsideProps | AnySpendStakeUpsideExactInProps | AnySpendDepositUpsideProps | AnySpendBuySpinProps | AnySpendSignatureMintProps | AnySpendBondKitProps | LinkAccountModalProps | LinkNewAccountModalProps | AnySpendDepositHypeProps | AvatarEditorModalProps | DepositModalProps | SendModalProps | NotificationsModalProps | AnySpendCollectorClubPurchaseProps | AnySpendDepositModalProps | AnySpendWorkflowTriggerModalProps | AnySpendCheckoutTriggerModalProps;
578
630
  /**
579
631
  * State interface for the modal store
580
632
  */
@@ -92,9 +92,9 @@ export declare const getViemChainConfig: (config: ChainNetworks) => {
92
92
  readonly rpc: string;
93
93
  readonly icon: {
94
94
  format: string;
95
- height: number;
96
- width: number;
97
95
  url: string;
96
+ width: number;
97
+ height: number;
98
98
  };
99
99
  };
100
100
  export declare const thirdwebB3Testnet: ThirdwebChain;
@@ -35,13 +35,13 @@ export declare const supportedChainNetworks: {
35
35
  uri: string;
36
36
  }[];
37
37
  };
38
+ _id: string | {};
38
39
  icon: {
39
40
  format: string;
40
- height: number;
41
- width: number;
42
41
  url: string;
42
+ width: number;
43
+ height: number;
43
44
  };
44
- _id: string | {};
45
45
  }[];
46
46
  export declare const coingeckoChains: Record<number, {
47
47
  coingecko_id: string;
@@ -8,4 +8,9 @@ export declare const formatDisplayNumber: (value: string | bigint | number | und
8
8
  fallback?: string;
9
9
  showSubscripts?: boolean;
10
10
  }) => string;
11
+ /**
12
+ * Safely convert a string to BigInt, returning 0n for invalid values.
13
+ * Use this for consumer-provided amount strings that may not be valid wei values.
14
+ */
15
+ export declare function safeBigInt(value: string): bigint;
11
16
  export declare function formatUnits(value: string, decimals?: number): string;
@@ -4,6 +4,7 @@ exports.formatDisplayNumber = void 0;
4
4
  exports.toRawString = toRawString;
5
5
  exports.divideBigIntToString = divideBigIntToString;
6
6
  exports.formatTokenAmount = formatTokenAmount;
7
+ exports.safeBigInt = safeBigInt;
7
8
  exports.formatUnits = formatUnits;
8
9
  function toRawString(amountInWei, decimals) {
9
10
  const factor = BigInt(10 ** decimals);
@@ -93,6 +94,18 @@ const formatDisplayNumber = (value, options) => {
93
94
  return formatter.format(v);
94
95
  };
95
96
  exports.formatDisplayNumber = formatDisplayNumber;
97
+ /**
98
+ * Safely convert a string to BigInt, returning 0n for invalid values.
99
+ * Use this for consumer-provided amount strings that may not be valid wei values.
100
+ */
101
+ function safeBigInt(value) {
102
+ try {
103
+ return BigInt(value);
104
+ }
105
+ catch {
106
+ return BigInt(0);
107
+ }
108
+ }
96
109
  function formatUnits(value, decimals = 18) {
97
110
  const factor = BigInt(10) ** BigInt(decimals);
98
111
  const wholePart = BigInt(value) / factor;
@@ -1,5 +1,6 @@
1
1
  import { components } from "../../types/api";
2
2
  import type { AnySpendClasses } from "./types/classes";
3
+ import type { AnySpendContent, AnySpendSlots, AnySpendTheme } from "./types/customization";
3
4
  export interface RecipientOption {
4
5
  address: string;
5
6
  icon?: string;
@@ -55,4 +56,12 @@ export declare function AnySpend(props: {
55
56
  destinationTokenAmount?: string;
56
57
  /** Opaque metadata passed to the order for callbacks (e.g., workflow form data) */
57
58
  callbackMetadata?: Record<string, unknown>;
59
+ /** Optional sender (payer) address — pre-fills token balances when the user address is known ahead of time */
60
+ senderAddress?: string;
61
+ /** Render function overrides for replaceable UI elements */
62
+ slots?: AnySpendSlots;
63
+ /** String or ReactNode overrides for text/messages */
64
+ content?: AnySpendContent;
65
+ /** Structured color/theme configuration */
66
+ theme?: AnySpendTheme;
58
67
  }): import("react/jsx-runtime").JSX.Element;
@@ -9,7 +9,8 @@ import { getThirdwebChain } from "../../../shared/constants/chains/supported.js"
9
9
  import { cn } from "../../../shared/utils/cn.js";
10
10
  import { formatTokenAmount } from "../../../shared/utils/number.js";
11
11
  import invariant from "invariant";
12
- import { ArrowDown, CheckCircle, HistoryIcon, Loader2 } from "lucide-react";
12
+ import { ArrowDown, HistoryIcon, Loader2 } from "lucide-react";
13
+ import { AnimatedCheckmark } from "./icons/AnimatedCheckmark.js";
13
14
  import { motion } from "motion/react";
14
15
  import { useCallback, useEffect, useMemo, useRef, useState } from "react";
15
16
  import { formatUnits, parseUnits } from "viem";
@@ -34,6 +35,7 @@ import { PanelOnrampPayment } from "./common/PanelOnrampPayment.js";
34
35
  import { PointsDetailPanel } from "./common/PointsDetailPanel.js";
35
36
  import { RecipientSelection } from "./common/RecipientSelection.js";
36
37
  import { TabSection } from "./common/TabSection.js";
38
+ import { AnySpendCustomizationProvider, useAnySpendCustomization } from "./context/AnySpendCustomizationContext.js";
37
39
  const baseChain = getThirdwebChain(8453);
38
40
  export var PanelView;
39
41
  (function (PanelView) {
@@ -52,10 +54,10 @@ export var PanelView;
52
54
  const ANYSPEND_RECIPIENTS_KEY = "anyspend_recipients";
53
55
  export function AnySpend(props) {
54
56
  const fingerprintConfig = getFingerprintConfig();
55
- console.log("[mitch] AnySpend rendered with fingerprintConfig:", props, fingerprintConfig);
56
- return (_jsx(AnySpendFingerprintWrapper, { fingerprint: fingerprintConfig, children: _jsx(AnySpendInner, { ...props }) }));
57
+ return (_jsx(AnySpendFingerprintWrapper, { fingerprint: fingerprintConfig, children: _jsx(AnySpendCustomizationProvider, { slots: props.slots, content: props.content, theme: props.theme, children: _jsx(AnySpendInner, { ...props }) }) }));
57
58
  }
58
- function AnySpendInner({ sourceChainId, destinationTokenAddress, destinationTokenChainId, mode = "modal", defaultActiveTab = "crypto", loadOrder, hideTransactionHistoryButton, recipientAddress: recipientAddressFromProps, onTokenSelect, onSuccess, customUsdInputValues, hideHeader, hideBottomNavigation = false, disableUrlParamManagement = false, returnToHomeUrl, customRecipientLabel, returnHomeLabel, classes, allowDirectTransfer = false, destinationTokenAmount, callbackMetadata, }) {
59
+ function AnySpendInner({ sourceChainId, destinationTokenAddress, destinationTokenChainId, mode = "modal", defaultActiveTab = "crypto", loadOrder, hideTransactionHistoryButton, recipientAddress: recipientAddressFromProps, onTokenSelect, onSuccess, customUsdInputValues, hideHeader, hideBottomNavigation = false, disableUrlParamManagement = false, returnToHomeUrl, customRecipientLabel, returnHomeLabel, classes, allowDirectTransfer = false, destinationTokenAmount, callbackMetadata, senderAddress, }) {
60
+ const { slots, content } = useAnySpendCustomization();
59
61
  const searchParams = useSearchParamsSSR();
60
62
  const router = useRouter();
61
63
  const { partnerId } = useB3Config();
@@ -358,9 +360,10 @@ function AnySpendInner({ sourceChainId, destinationTokenAddress, destinationToke
358
360
  const recipientProfile = useProfile({ address: effectiveRecipientAddress, fresh: true });
359
361
  const recipientName = recipientProfile.data?.name;
360
362
  // Check token balance for crypto payments
363
+ const effectiveBalanceAddress = senderAddress || connectedEOAWallet?.getAccount()?.address;
361
364
  const { rawBalance, isLoading: isBalanceLoading } = useTokenBalanceDirect({
362
365
  token: selectedSrcToken,
363
- address: connectedEOAWallet?.getAccount()?.address,
366
+ address: effectiveBalanceAddress,
364
367
  });
365
368
  // Check if user has enough balanceuseAutoSetActiveWalletFromWagmi
366
369
  const hasEnoughBalance = useMemo(() => {
@@ -712,7 +715,7 @@ function AnySpendInner({ sourceChainId, destinationTokenAddress, destinationToke
712
715
  : selectedDstToken,
713
716
  srcAmount: srcAmountBigInt.toString(),
714
717
  expectedDstAmount: anyspendQuote?.data?.currencyOut?.amount || "0",
715
- creatorAddress: globalAddress,
718
+ creatorAddress: senderAddress || globalAddress,
716
719
  callbackMetadata,
717
720
  });
718
721
  }
@@ -787,7 +790,7 @@ function AnySpendInner({ sourceChainId, destinationTokenAddress, destinationToke
787
790
  redirectUrl: window.location.origin === "https://basement.fun" ? "https://basement.fun/deposit" : window.location.origin,
788
791
  },
789
792
  expectedDstAmount: anyspendQuote?.data?.currencyOut?.amount?.toString() || "0",
790
- creatorAddress: globalAddress,
793
+ creatorAddress: senderAddress || globalAddress,
791
794
  callbackMetadata,
792
795
  });
793
796
  }
@@ -905,10 +908,15 @@ function AnySpendInner({ sourceChainId, destinationTokenAddress, destinationToke
905
908
  }, children: _jsx("div", { className: "relative flex items-center justify-center transition-opacity", children: _jsx(ArrowDown, { className: "text-as-primary/50 h-5 w-5" }) }) }) })), activeTab === "crypto" && (_jsx(CryptoReceiveSection, { isDepositMode: false, isBuyMode: isBuyMode, effectiveRecipientAddress: effectiveRecipientAddress, recipientName: recipientName || undefined, customRecipientLabel: customRecipientLabel, onSelectRecipient: () => navigateToPanel(PanelView.RECIPIENT_SELECTION, "forward"), dstAmount: dstAmount, dstToken: selectedDstToken, selectedDstChainId: selectedDstChainId, setSelectedDstChainId: setSelectedDstChainId, setSelectedDstToken: setSelectedDstToken, isSrcInputDirty: isSrcInputDirty, onChangeDstAmount: value => {
906
909
  setIsSrcInputDirty(false);
907
910
  setDstAmount(value);
908
- }, disableAmountInput: !!destinationTokenAmount, anyspendQuote: isDirectTransfer ? undefined : anyspendQuote, onShowPointsDetail: isDirectTransfer ? undefined : () => navigateToPanel(PanelView.POINTS_DETAIL, "forward"), onShowFeeDetail: isDirectTransfer ? undefined : () => navigateToPanel(PanelView.FEE_DETAIL, "forward") }))] }), gasPriceData && !isLoadingGas && activeTab === "crypto" && !isDirectTransfer && (_jsx(GasIndicator, { gasPrice: gasPriceData, className: classes?.gasIndicator || "mt-2 w-full" })), _jsxs(motion.div, { initial: { opacity: 0, y: 20, filter: "blur(10px)" }, animate: { opacity: 1, y: 0, filter: "blur(0px)" }, transition: { duration: 0.3, delay: 0.2, ease: "easeInOut" }, className: cn("mt-4 flex w-full max-w-[460px] flex-col gap-2"), children: [_jsx(ShinyButton, { accentColor: "hsl(var(--as-brand))", disabled: btnInfo.disable, onClick: onMainButtonClick, className: (btnInfo.error && classes?.mainButtonError) ||
911
+ }, disableAmountInput: !!destinationTokenAmount, anyspendQuote: isDirectTransfer ? undefined : anyspendQuote, onShowPointsDetail: isDirectTransfer ? undefined : () => navigateToPanel(PanelView.POINTS_DETAIL, "forward"), onShowFeeDetail: isDirectTransfer ? undefined : () => navigateToPanel(PanelView.FEE_DETAIL, "forward") }))] }), gasPriceData && !isLoadingGas && activeTab === "crypto" && !isDirectTransfer && (_jsx(GasIndicator, { gasPrice: gasPriceData, className: classes?.gasIndicator || "mt-2 w-full" })), _jsxs(motion.div, { initial: { opacity: 0, y: 20, filter: "blur(10px)" }, animate: { opacity: 1, y: 0, filter: "blur(0px)" }, transition: { duration: 0.3, delay: 0.2, ease: "easeInOut" }, className: cn("mt-4 flex w-full max-w-[460px] flex-col gap-2"), children: [slots.actionButton ? (slots.actionButton({
912
+ onClick: onMainButtonClick,
913
+ disabled: btnInfo.disable,
914
+ loading: btnInfo.loading,
915
+ text: btnInfo.text,
916
+ })) : (_jsx(ShinyButton, { accentColor: "hsl(var(--as-brand))", disabled: btnInfo.disable, onClick: onMainButtonClick, className: (btnInfo.error && classes?.mainButtonError) ||
909
917
  (btnInfo.disable && classes?.mainButtonDisabled) ||
910
918
  classes?.mainButton ||
911
- cn("as-main-button relative w-full", btnInfo.error ? "!bg-as-red" : btnInfo.disable ? "!bg-as-on-surface-2" : "!bg-as-brand"), textClassName: cn(btnInfo.error ? "text-white" : btnInfo.disable ? "text-as-secondary" : "text-white"), children: _jsxs("div", { className: "flex items-center justify-center gap-2", children: [btnInfo.loading && _jsx(Loader2, { className: "h-4 w-4 animate-spin" }), btnInfo.text] }) }), !hideTransactionHistoryButton && (globalAddress || effectiveRecipientAddress) ? (_jsxs(Button, { variant: "link", onClick: onClickHistory, className: classes?.historyButton ||
919
+ cn("as-main-button relative w-full", btnInfo.error ? "!bg-as-red" : btnInfo.disable ? "!bg-as-on-surface-2" : "!bg-as-brand"), textClassName: cn(btnInfo.error ? "text-white" : btnInfo.disable ? "text-as-secondary" : "text-white"), children: _jsxs("div", { className: "flex items-center justify-center gap-2", children: [btnInfo.loading && _jsx(Loader2, { className: "h-4 w-4 animate-spin" }), btnInfo.text] }) })), !hideTransactionHistoryButton && (globalAddress || effectiveRecipientAddress) ? (_jsxs(Button, { variant: "link", onClick: onClickHistory, className: classes?.historyButton ||
912
920
  "text-as-primary/50 hover:text-as-primary flex items-center gap-1 transition-colors", children: [_jsx(HistoryIcon, { className: "h-4 w-4" }), " ", _jsx("span", { className: "pr-4", children: "Transaction History" })] })) : null] })] }), _jsx("div", { className: "w-full", children: _jsx(TabsPrimitive, { defaultValue: "swap", onValueChange: value => {
913
921
  if (value === "settings" || value === "home") {
914
922
  setB3ModalContentType({
@@ -961,13 +969,34 @@ function AnySpendInner({ sourceChainId, destinationTokenAddress, destinationToke
961
969
  }, srcAmountOnRamp: srcAmountOnRamp }));
962
970
  const pointsDetailView = (_jsx(PointsDetailPanel, { pointsAmount: anyspendQuote?.data?.pointsAmount || 0, onBack: navigateBack }));
963
971
  const feeDetailView = anyspendQuote?.data?.fee ? (_jsx(FeeDetailPanel, { fee: anyspendQuote.data.fee, transactionAmountUsd: activeTab === "crypto" ? Number(anyspendQuote.data.currencyIn?.amountUsd) : parseFloat(srcAmountOnRamp), onBack: navigateBack })) : null;
964
- const directTransferSuccessView = (_jsxs("div", { className: "mx-auto flex w-[460px] max-w-full flex-col items-center gap-6 p-5", children: [_jsxs("div", { className: "flex flex-col items-center gap-4", children: [_jsx("div", { className: "bg-as-brand/10 flex h-16 w-16 items-center justify-center rounded-full", children: _jsx(CheckCircle, { className: "text-as-brand h-8 w-8" }) }), _jsxs("div", { className: "text-center", children: [_jsx("h2", { className: "text-as-primary text-xl font-bold", children: "Transfer Complete" }), _jsxs("p", { className: "text-as-secondary mt-1 text-sm", children: ["Your ", selectedSrcToken.symbol, " has been sent to ", effectiveRecipientAddress?.slice(0, 6), "...", effectiveRecipientAddress?.slice(-4), " on ", getChainName(selectedSrcChainId)] })] })] }), directTransferTxHash && (_jsx("a", { href: getExplorerTxUrl(selectedSrcChainId, directTransferTxHash), target: "_blank", rel: "noopener noreferrer", className: "text-as-brand hover:text-as-brand/80 text-sm underline", children: "View transaction" })), _jsx("div", { className: "flex w-full flex-col gap-2", children: returnToHomeUrl ? (_jsx(Button, { onClick: () => {
972
+ const defaultSuccessTitle = content.successTitle || "Transfer Complete";
973
+ const defaultSuccessDesc = content.successDescription ||
974
+ `Your ${selectedSrcToken.symbol} has been sent to ${effectiveRecipientAddress?.slice(0, 6)}...${effectiveRecipientAddress?.slice(-4)} on ${getChainName(selectedSrcChainId)}`;
975
+ const resolvedReturnLabel = content.returnButtonLabel || returnHomeLabel;
976
+ const directTransferSuccessView = slots.successScreen ? (slots.successScreen({
977
+ title: typeof defaultSuccessTitle === "string" ? defaultSuccessTitle : "Transfer Complete",
978
+ description: typeof defaultSuccessDesc === "string" ? defaultSuccessDesc : "",
979
+ txHash: directTransferTxHash,
980
+ explorerUrl: directTransferTxHash ? getExplorerTxUrl(selectedSrcChainId, directTransferTxHash) : undefined,
981
+ onDone: () => {
982
+ if (returnToHomeUrl) {
983
+ window.location.href = returnToHomeUrl;
984
+ }
985
+ else {
986
+ onSuccess?.(directTransferTxHash);
987
+ setDirectTransferTxHash(undefined);
988
+ setB3ModalOpen(false);
989
+ }
990
+ },
991
+ returnUrl: returnToHomeUrl,
992
+ returnLabel: resolvedReturnLabel || undefined,
993
+ })) : (_jsxs("div", { className: "mx-auto flex w-[460px] max-w-full flex-col items-center gap-6 p-5", children: [_jsxs("div", { className: "flex flex-col items-center gap-4", children: [_jsx(AnimatedCheckmark, { className: "h-16 w-16" }), _jsxs("div", { className: "text-center", children: [_jsx("h2", { className: "text-as-primary text-xl font-bold", children: defaultSuccessTitle }), _jsx("p", { className: "text-as-secondary mt-1 text-sm", children: defaultSuccessDesc })] })] }), directTransferTxHash && (_jsx("a", { href: getExplorerTxUrl(selectedSrcChainId, directTransferTxHash), target: "_blank", rel: "noopener noreferrer", className: "text-as-brand hover:text-as-brand/80 text-sm underline", children: "View transaction" })), _jsx("div", { className: "flex w-full flex-col gap-2", children: returnToHomeUrl ? (_jsx(Button, { onClick: () => {
965
994
  window.location.href = returnToHomeUrl;
966
- }, className: "bg-as-brand hover:bg-as-brand/90 w-full text-white", children: returnHomeLabel || "Return to Home" })) : (_jsx(Button, { onClick: () => {
995
+ }, className: "bg-as-brand hover:bg-as-brand/90 w-full text-white", children: resolvedReturnLabel || "Return to Home" })) : (_jsx(Button, { onClick: () => {
967
996
  onSuccess?.(directTransferTxHash);
968
997
  setDirectTransferTxHash(undefined);
969
998
  setB3ModalOpen(false);
970
- }, className: "bg-as-brand hover:bg-as-brand/90 w-full text-white", children: returnHomeLabel || "Done" })) })] }));
999
+ }, className: "bg-as-brand hover:bg-as-brand/90 w-full text-white", children: resolvedReturnLabel || "Done" })) })] }));
971
1000
  // Add tabs to the main component when no order is loaded
972
1001
  return (_jsx(StyleRoot, { children: _jsx("div", { className: classes?.container ||
973
1002
  cn("anyspend-container font-inter mx-auto w-full max-w-[460px]", mode === "page" &&
@@ -1,2 +1,7 @@
1
1
  import { AnySpendBondKitProps } from "../../../global-account/react/stores/useModalStore";
2
- export declare function AnySpendBondKit({ mode, recipientAddress, contractAddress, minTokensOut, imageUrl, b3Amount: initialB3Amount, onSuccess, }: AnySpendBondKitProps): import("react/jsx-runtime").JSX.Element;
2
+ import type { AnySpendContent, AnySpendSlots, AnySpendTheme } from "./types/customization";
3
+ export declare function AnySpendBondKit({ mode, recipientAddress, contractAddress, minTokensOut, imageUrl, b3Amount: initialB3Amount, onSuccess, slots, content, theme, }: AnySpendBondKitProps & {
4
+ slots?: AnySpendSlots;
5
+ content?: AnySpendContent;
6
+ theme?: AnySpendTheme;
7
+ }): import("react/jsx-runtime").JSX.Element;
@@ -20,7 +20,7 @@ function formatNumberWithCommas(x) {
20
20
  parts[0] = parts[0].replace(/\B(?=(\d{3})+(?!\d))/g, ",");
21
21
  return parts.join(".");
22
22
  }
23
- export function AnySpendBondKit({ mode = "modal", recipientAddress, contractAddress, minTokensOut = "0", imageUrl, b3Amount: initialB3Amount, onSuccess, }) {
23
+ export function AnySpendBondKit({ mode = "modal", recipientAddress, contractAddress, minTokensOut = "0", imageUrl, b3Amount: initialB3Amount, onSuccess, slots, content, theme, }) {
24
24
  const hasMounted = useHasMounted();
25
25
  const [showAmountPrompt, setShowAmountPrompt] = useState(!initialB3Amount);
26
26
  const [b3Amount, setB3Amount] = useState(initialB3Amount || "");
@@ -200,5 +200,5 @@ export function AnySpendBondKit({ mode = "modal", recipientAddress, contractAddr
200
200
  });
201
201
  return (_jsx(AnySpendCustom, { mode: mode, recipientAddress: recipientAddress, orderType: "custom", dstChainId: baseMainnet.id, dstToken: dstToken, dstAmount: parseEther(b3Amount).toString(), contractAddress: contractAddress, encodedData: encodedData, metadata: {
202
202
  action: "BondKit Buy",
203
- }, header: header, onSuccess: onSuccess, showRecipient: true }));
203
+ }, header: header, onSuccess: onSuccess, showRecipient: true, slots: slots, content: content, theme: theme }));
204
204
  }
@@ -1,4 +1,5 @@
1
- export declare function AnySpendBuySpin({ loadOrder, mode, spinwheelContractAddress, chainId, recipientAddress, prefillQuantity, onSuccess, }: {
1
+ import type { AnySpendContent, AnySpendSlots, AnySpendTheme } from "./types/customization";
2
+ export declare function AnySpendBuySpin({ loadOrder, mode, spinwheelContractAddress, chainId, recipientAddress, prefillQuantity, onSuccess, senderAddress, slots, content, theme, }: {
2
3
  loadOrder?: string;
3
4
  mode?: "modal" | "page";
4
5
  spinwheelContractAddress: string;
@@ -6,4 +7,9 @@ export declare function AnySpendBuySpin({ loadOrder, mode, spinwheelContractAddr
6
7
  recipientAddress: string;
7
8
  prefillQuantity?: string;
8
9
  onSuccess?: (txHash?: string) => void;
10
+ /** Optional sender (payer) address — pre-fills token balances when the user address is known ahead of time */
11
+ senderAddress?: string;
12
+ slots?: AnySpendSlots;
13
+ content?: AnySpendContent;
14
+ theme?: AnySpendTheme;
9
15
  }): import("react/jsx-runtime").JSX.Element;
@@ -84,7 +84,7 @@ const basePublicClient = createPublicClient({
84
84
  chain: baseMainnet,
85
85
  transport: http(PUBLIC_BASE_RPC_URL),
86
86
  });
87
- export function AnySpendBuySpin({ loadOrder, mode = "modal", spinwheelContractAddress, chainId, recipientAddress, prefillQuantity, onSuccess, }) {
87
+ export function AnySpendBuySpin({ loadOrder, mode = "modal", spinwheelContractAddress, chainId, recipientAddress, prefillQuantity, onSuccess, senderAddress, slots, content, theme, }) {
88
88
  const hasMounted = useHasMounted();
89
89
  const { setB3ModalOpen } = useModalStore();
90
90
  // Payment config state
@@ -390,5 +390,5 @@ export function AnySpendBuySpin({ loadOrder, mode = "modal", spinwheelContractAd
390
390
  const encodedData = generateEncodedDataForBuyEntriesAndSpin(address || "", userSpinQuantity);
391
391
  return (_jsx(AnySpendCustom, { loadOrder: loadOrder, mode: mode, recipientAddress: recipientAddress, orderType: "custom", dstChainId: chainId, dstToken: B3_TOKEN, dstAmount: totalCost.toString(), contractAddress: spinwheelContractAddress, spenderAddress: paymentConfig.entryModule, encodedData: encodedData, metadata: {
392
392
  action: `buy ${userSpinQuantity} spin${userSpinQuantity !== "1" ? "s" : ""}`,
393
- }, header: header, onSuccess: txHash => onSuccess?.(txHash), showRecipient: false }));
393
+ }, header: header, onSuccess: txHash => onSuccess?.(txHash), showRecipient: false, senderAddress: senderAddress, slots: slots, content: content, theme: theme }));
394
394
  }
@@ -1,6 +1,7 @@
1
1
  import { components } from "../../../anyspend/types/api";
2
2
  import { GetQuoteResponse } from "../../../anyspend/types/api_req_res";
3
3
  import React from "react";
4
+ import type { AnySpendContent, AnySpendSlots, AnySpendTheme } from "./types/customization";
4
5
  export interface AnySpendCollectorClubPurchaseProps {
5
6
  /**
6
7
  * Optional order ID to load existing order
@@ -74,5 +75,8 @@ export interface AnySpendCollectorClubPurchaseProps {
74
75
  * When provided, validates on-chain and adjusts the price accordingly.
75
76
  */
76
77
  discountCode?: string;
78
+ slots?: AnySpendSlots;
79
+ content?: AnySpendContent;
80
+ theme?: AnySpendTheme;
77
81
  }
78
- export declare function AnySpendCollectorClubPurchase({ loadOrder, mode, activeTab, packId, packAmount, pricePerPack, paymentToken, recipientAddress, spenderAddress, isStaging, onSuccess, header, showRecipient, vendingMachineId, packType, forceFiatPayment, discountCode, }: AnySpendCollectorClubPurchaseProps): import("react/jsx-runtime").JSX.Element;
82
+ export declare function AnySpendCollectorClubPurchase({ loadOrder, mode, activeTab, packId, packAmount, pricePerPack, paymentToken, recipientAddress, spenderAddress, isStaging, onSuccess, header, showRecipient, vendingMachineId, packType, forceFiatPayment, discountCode, slots, content, theme, }: AnySpendCollectorClubPurchaseProps): import("react/jsx-runtime").JSX.Element;
@@ -41,7 +41,7 @@ const basePublicClient = createPublicClient({
41
41
  chain: base,
42
42
  transport: http(PUBLIC_BASE_RPC_URL),
43
43
  });
44
- export function AnySpendCollectorClubPurchase({ loadOrder, mode = "modal", activeTab = "crypto", packId, packAmount, pricePerPack, paymentToken = USDC_BASE, recipientAddress, spenderAddress, isStaging = false, onSuccess, header, showRecipient = true, vendingMachineId, packType, forceFiatPayment, discountCode, }) {
44
+ export function AnySpendCollectorClubPurchase({ loadOrder, mode = "modal", activeTab = "crypto", packId, packAmount, pricePerPack, paymentToken = USDC_BASE, recipientAddress, spenderAddress, isStaging = false, onSuccess, header, showRecipient = true, vendingMachineId, packType, forceFiatPayment, discountCode, slots, content, theme, }) {
45
45
  const ccShopAddress = isStaging ? CC_SHOP_ADDRESS_STAGING : CC_SHOP_ADDRESS;
46
46
  // Calculate total amount needed (pricePerPack * packAmount)
47
47
  const totalAmount = useMemo(() => {
@@ -215,5 +215,5 @@ export function AnySpendCollectorClubPurchase({ loadOrder, mode = "modal", activ
215
215
  ...(discountCode && discountInfo.isValid
216
216
  ? { discountCode, discountAmount: discountInfo.discountAmount.toString() }
217
217
  : {}),
218
- }, header: header || defaultHeader, onSuccess: onSuccess, showRecipient: showRecipient, srcFiatAmount: srcFiatAmount, forceFiatPayment: forceFiatPayment }));
218
+ }, header: header || defaultHeader, onSuccess: onSuccess, showRecipient: showRecipient, srcFiatAmount: srcFiatAmount, forceFiatPayment: forceFiatPayment, slots: slots, content: content, theme: theme }));
219
219
  }
@@ -1,6 +1,7 @@
1
1
  import { components } from "../../../anyspend/types/api";
2
2
  import { GetQuoteResponse } from "../../../anyspend/types/api_req_res";
3
3
  import React from "react";
4
+ import type { AnySpendContent, AnySpendSlots, AnySpendTheme } from "./types/customization";
4
5
  export declare function AnySpendCustom(props: {
5
6
  loadOrder?: string;
6
7
  mode?: "modal" | "page";
@@ -24,4 +25,12 @@ export declare function AnySpendCustom(props: {
24
25
  onShowPointsDetail?: () => void;
25
26
  /** Fiat amount in USD for fiat payments */
26
27
  srcFiatAmount?: string;
28
+ /** Optional sender (payer) address — pre-fills token balances when the user address is known ahead of time */
29
+ senderAddress?: string;
30
+ /** Render function overrides for replaceable UI elements */
31
+ slots?: AnySpendSlots;
32
+ /** String or ReactNode overrides for text/messages */
33
+ content?: AnySpendContent;
34
+ /** Structured color/theme configuration */
35
+ theme?: AnySpendTheme;
27
36
  }): import("react/jsx-runtime").JSX.Element;