@b3dotfun/sdk 0.0.88 → 0.0.89-alpha.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 (281) hide show
  1. package/dist/cjs/anyspend/constants/index.d.ts +2 -0
  2. package/dist/cjs/anyspend/constants/index.js +3 -1
  3. package/dist/cjs/anyspend/index.d.ts +2 -0
  4. package/dist/cjs/anyspend/index.js +3 -0
  5. package/dist/cjs/anyspend/react/components/AnySpend.d.ts +6 -0
  6. package/dist/cjs/anyspend/react/components/AnySpend.js +9 -6
  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 +1 -0
  10. package/dist/cjs/anyspend/react/components/AnySpendCustom.js +3 -3
  11. package/dist/cjs/anyspend/react/components/AnySpendCustomExactIn.d.ts +6 -0
  12. package/dist/cjs/anyspend/react/components/AnySpendCustomExactIn.js +24 -20
  13. package/dist/cjs/anyspend/react/components/AnySpendDeposit.d.ts +7 -1
  14. package/dist/cjs/anyspend/react/components/AnySpendDeposit.js +3 -3
  15. package/dist/cjs/anyspend/react/components/AnyspendDepositHype.d.ts +4 -0
  16. package/dist/cjs/anyspend/react/components/common/CryptoPaymentMethod.js +14 -1
  17. package/dist/cjs/anyspend/react/components/common/CryptoReceiveSection.d.ts +3 -1
  18. package/dist/cjs/anyspend/react/components/common/CryptoReceiveSection.js +3 -2
  19. package/dist/cjs/anyspend/react/components/common/GasIndicator.d.ts +6 -0
  20. package/dist/cjs/anyspend/react/components/common/GasIndicator.js +34 -0
  21. package/dist/cjs/anyspend/react/components/common/OrderDetails.d.ts +4 -0
  22. package/dist/cjs/anyspend/react/components/common/OrderDetails.js +34 -6
  23. package/dist/cjs/anyspend/react/components/common/PanelOnramp.d.ts +3 -1
  24. package/dist/cjs/anyspend/react/components/common/PanelOnramp.js +3 -2
  25. package/dist/cjs/anyspend/react/components/common/PaymentStripeWeb2.js +3 -4
  26. package/dist/cjs/anyspend/react/hooks/index.d.ts +1 -0
  27. package/dist/cjs/anyspend/react/hooks/index.js +1 -0
  28. package/dist/cjs/anyspend/react/hooks/useAnyspendCreateOnrampOrder.js +1 -1
  29. package/dist/cjs/anyspend/react/hooks/useAnyspendCreateOrder.js +1 -1
  30. package/dist/cjs/anyspend/react/hooks/useCreateDepositFirstOrder.js +1 -1
  31. package/dist/cjs/anyspend/react/hooks/useGasPrice.d.ts +37 -0
  32. package/dist/cjs/anyspend/react/hooks/useGasPrice.js +43 -0
  33. package/dist/cjs/anyspend/react/hooks/useValidatedClientReferenceId.js +1 -1
  34. package/dist/cjs/anyspend/services/gas.d.ts +21 -0
  35. package/dist/cjs/anyspend/services/gas.js +65 -0
  36. package/dist/cjs/anyspend/types/gas.d.ts +61 -0
  37. package/dist/cjs/anyspend/types/gas.js +2 -0
  38. package/dist/cjs/global-account/react/components/B3DynamicModal.js +2 -3
  39. package/dist/cjs/global-account/react/components/B3Provider/AuthenticationProvider.d.ts +5 -0
  40. package/dist/cjs/global-account/react/components/B3Provider/AuthenticationProvider.js +12 -0
  41. package/dist/cjs/global-account/react/components/B3Provider/B3Provider.d.ts +2 -18
  42. package/dist/cjs/global-account/react/components/B3Provider/B3Provider.js +35 -52
  43. package/dist/cjs/global-account/react/components/B3Provider/B3Provider.native.d.ts +5 -5
  44. package/dist/cjs/global-account/react/components/B3Provider/B3Provider.native.js +38 -35
  45. package/dist/cjs/global-account/react/components/B3Provider/RelayKitProviderWrapper.js +3 -1
  46. package/dist/cjs/global-account/react/components/B3Provider/useB3.d.ts +14 -4
  47. package/dist/cjs/global-account/react/components/B3Provider/useB3.js +4 -11
  48. package/dist/cjs/global-account/react/components/B3Provider/useB3Account.js +5 -2
  49. package/dist/cjs/global-account/react/components/B3Provider/useB3Config.d.ts +10 -2
  50. package/dist/cjs/global-account/react/components/B3Provider/useB3Config.js +18 -17
  51. package/dist/cjs/global-account/react/components/ManageAccount/ProfileSection.js +1 -2
  52. package/dist/cjs/global-account/react/components/ManageAccount/channels/DiscordChannel.js +6 -6
  53. package/dist/cjs/global-account/react/components/ManageAccount/channels/EmailChannel.js +7 -7
  54. package/dist/cjs/global-account/react/components/ManageAccount/channels/PhoneChannel.js +7 -7
  55. package/dist/cjs/global-account/react/components/ManageAccount/channels/TelegramChannel.js +5 -5
  56. package/dist/cjs/global-account/react/components/RequestPermissions/RequestPermissions.js +8 -9
  57. package/dist/cjs/global-account/react/components/SignInWithB3/SignIn.js +1 -1
  58. package/dist/cjs/global-account/react/components/SignInWithB3/SignInWithB3Flow.js +76 -20
  59. package/dist/cjs/global-account/react/components/SignInWithB3/SignInWithB3Privy.js +1 -1
  60. package/dist/cjs/global-account/react/components/SignInWithB3/steps/LoginStep.js +1 -1
  61. package/dist/cjs/global-account/react/components/SignInWithB3/steps/LoginStepCustom.js +1 -1
  62. package/dist/cjs/global-account/react/components/StyleRoot.js +3 -3
  63. package/dist/cjs/global-account/react/components/TurnkeyAuthModal.js +3 -1
  64. package/dist/cjs/global-account/react/components/custom/ManageAccountButton.js +1 -2
  65. package/dist/cjs/global-account/react/components/index.d.ts +1 -2
  66. package/dist/cjs/global-account/react/components/index.js +3 -6
  67. package/dist/cjs/global-account/react/hooks/index.d.ts +2 -0
  68. package/dist/cjs/global-account/react/hooks/index.js +5 -1
  69. package/dist/cjs/global-account/react/hooks/useAuth.d.ts +76 -0
  70. package/dist/cjs/global-account/react/hooks/useAuth.js +337 -0
  71. package/dist/cjs/global-account/react/hooks/useClient.js +1 -1
  72. package/dist/cjs/global-account/react/hooks/useHandleConnectWithPrivy.js +1 -1
  73. package/dist/cjs/global-account/react/hooks/useNotifications.js +14 -14
  74. package/dist/cjs/global-account/react/hooks/useTWAuth.d.ts +3 -0
  75. package/dist/cjs/global-account/react/hooks/useTWAuth.js +8 -0
  76. package/dist/cjs/global-account/react/hooks/useTokenBalance.js +5 -5
  77. package/dist/cjs/global-account/react/hooks/useTokenBalancesByChain.js +4 -2
  78. package/dist/cjs/global-account/react/hooks/useTurnkeyAuth.js +50 -22
  79. package/dist/cjs/global-account/react/hooks/useUser.d.ts +60 -0
  80. package/dist/cjs/global-account/react/hooks/useUser.js +20 -0
  81. package/dist/cjs/global-account/react/hooks/useUserQuery.js +9 -35
  82. package/dist/cjs/global-account/react/index.native.d.ts +0 -2
  83. package/dist/cjs/global-account/react/index.native.js +1 -5
  84. package/dist/cjs/global-account/react/stores/configStore.d.ts +24 -0
  85. package/dist/cjs/global-account/react/stores/configStore.js +30 -0
  86. package/dist/cjs/global-account/react/stores/index.d.ts +1 -0
  87. package/dist/cjs/global-account/react/stores/index.js +3 -1
  88. package/dist/cjs/global-account/react/stores/useModalStore.d.ts +10 -0
  89. package/dist/cjs/global-account/react/stores/userStore.d.ts +22 -0
  90. package/dist/cjs/global-account/react/stores/userStore.js +30 -0
  91. package/dist/esm/anyspend/constants/index.d.ts +2 -0
  92. package/dist/esm/anyspend/constants/index.js +2 -0
  93. package/dist/esm/anyspend/index.d.ts +2 -0
  94. package/dist/esm/anyspend/index.js +3 -0
  95. package/dist/esm/anyspend/react/components/AnySpend.d.ts +6 -0
  96. package/dist/esm/anyspend/react/components/AnySpend.js +11 -8
  97. package/dist/esm/anyspend/react/components/AnySpendCollectorClubPurchase.d.ts +5 -1
  98. package/dist/esm/anyspend/react/components/AnySpendCollectorClubPurchase.js +2 -2
  99. package/dist/esm/anyspend/react/components/AnySpendCustom.d.ts +1 -0
  100. package/dist/esm/anyspend/react/components/AnySpendCustom.js +3 -3
  101. package/dist/esm/anyspend/react/components/AnySpendCustomExactIn.d.ts +6 -0
  102. package/dist/esm/anyspend/react/components/AnySpendCustomExactIn.js +8 -4
  103. package/dist/esm/anyspend/react/components/AnySpendDeposit.d.ts +7 -1
  104. package/dist/esm/anyspend/react/components/AnySpendDeposit.js +3 -3
  105. package/dist/esm/anyspend/react/components/AnyspendDepositHype.d.ts +4 -0
  106. package/dist/esm/anyspend/react/components/common/CryptoPaymentMethod.js +14 -1
  107. package/dist/esm/anyspend/react/components/common/CryptoReceiveSection.d.ts +3 -1
  108. package/dist/esm/anyspend/react/components/common/CryptoReceiveSection.js +3 -2
  109. package/dist/esm/anyspend/react/components/common/GasIndicator.d.ts +6 -0
  110. package/dist/esm/anyspend/react/components/common/GasIndicator.js +31 -0
  111. package/dist/esm/anyspend/react/components/common/OrderDetails.d.ts +4 -0
  112. package/dist/esm/anyspend/react/components/common/OrderDetails.js +36 -8
  113. package/dist/esm/anyspend/react/components/common/PanelOnramp.d.ts +3 -1
  114. package/dist/esm/anyspend/react/components/common/PanelOnramp.js +3 -2
  115. package/dist/esm/anyspend/react/components/common/PaymentStripeWeb2.js +3 -4
  116. package/dist/esm/anyspend/react/hooks/index.d.ts +1 -0
  117. package/dist/esm/anyspend/react/hooks/index.js +1 -0
  118. package/dist/esm/anyspend/react/hooks/useAnyspendCreateOnrampOrder.js +2 -2
  119. package/dist/esm/anyspend/react/hooks/useAnyspendCreateOrder.js +2 -2
  120. package/dist/esm/anyspend/react/hooks/useCreateDepositFirstOrder.js +2 -2
  121. package/dist/esm/anyspend/react/hooks/useGasPrice.d.ts +37 -0
  122. package/dist/esm/anyspend/react/hooks/useGasPrice.js +40 -0
  123. package/dist/esm/anyspend/react/hooks/useValidatedClientReferenceId.js +2 -2
  124. package/dist/esm/anyspend/services/gas.d.ts +21 -0
  125. package/dist/esm/anyspend/services/gas.js +59 -0
  126. package/dist/esm/anyspend/types/gas.d.ts +61 -0
  127. package/dist/esm/anyspend/types/gas.js +1 -0
  128. package/dist/esm/global-account/react/components/B3DynamicModal.js +3 -4
  129. package/dist/esm/global-account/react/components/B3Provider/AuthenticationProvider.d.ts +5 -0
  130. package/dist/esm/global-account/react/components/B3Provider/AuthenticationProvider.js +10 -0
  131. package/dist/esm/global-account/react/components/B3Provider/B3Provider.d.ts +2 -18
  132. package/dist/esm/global-account/react/components/B3Provider/B3Provider.js +34 -53
  133. package/dist/esm/global-account/react/components/B3Provider/B3Provider.native.d.ts +5 -5
  134. package/dist/esm/global-account/react/components/B3Provider/B3Provider.native.js +36 -36
  135. package/dist/esm/global-account/react/components/B3Provider/RelayKitProviderWrapper.js +3 -1
  136. package/dist/esm/global-account/react/components/B3Provider/useB3.d.ts +14 -4
  137. package/dist/esm/global-account/react/components/B3Provider/useB3.js +4 -11
  138. package/dist/esm/global-account/react/components/B3Provider/useB3Account.js +5 -2
  139. package/dist/esm/global-account/react/components/B3Provider/useB3Config.d.ts +10 -2
  140. package/dist/esm/global-account/react/components/B3Provider/useB3Config.js +18 -17
  141. package/dist/esm/global-account/react/components/ManageAccount/ProfileSection.js +2 -3
  142. package/dist/esm/global-account/react/components/ManageAccount/channels/DiscordChannel.js +2 -2
  143. package/dist/esm/global-account/react/components/ManageAccount/channels/EmailChannel.js +2 -2
  144. package/dist/esm/global-account/react/components/ManageAccount/channels/PhoneChannel.js +2 -2
  145. package/dist/esm/global-account/react/components/ManageAccount/channels/TelegramChannel.js +2 -2
  146. package/dist/esm/global-account/react/components/RequestPermissions/RequestPermissions.js +2 -3
  147. package/dist/esm/global-account/react/components/SignInWithB3/SignIn.js +2 -2
  148. package/dist/esm/global-account/react/components/SignInWithB3/SignInWithB3Flow.js +76 -20
  149. package/dist/esm/global-account/react/components/SignInWithB3/SignInWithB3Privy.js +2 -2
  150. package/dist/esm/global-account/react/components/SignInWithB3/steps/LoginStep.js +2 -2
  151. package/dist/esm/global-account/react/components/SignInWithB3/steps/LoginStepCustom.js +2 -2
  152. package/dist/esm/global-account/react/components/StyleRoot.js +3 -3
  153. package/dist/esm/global-account/react/components/TurnkeyAuthModal.js +5 -3
  154. package/dist/esm/global-account/react/components/custom/ManageAccountButton.js +2 -3
  155. package/dist/esm/global-account/react/components/index.d.ts +1 -2
  156. package/dist/esm/global-account/react/components/index.js +1 -2
  157. package/dist/esm/global-account/react/hooks/index.d.ts +2 -0
  158. package/dist/esm/global-account/react/hooks/index.js +2 -0
  159. package/dist/esm/global-account/react/hooks/useAuth.d.ts +76 -0
  160. package/dist/esm/global-account/react/hooks/useAuth.js +331 -0
  161. package/dist/esm/global-account/react/hooks/useClient.js +2 -2
  162. package/dist/esm/global-account/react/hooks/useHandleConnectWithPrivy.js +2 -2
  163. package/dist/esm/global-account/react/hooks/useNotifications.js +2 -2
  164. package/dist/esm/global-account/react/hooks/useTWAuth.d.ts +3 -0
  165. package/dist/esm/global-account/react/hooks/useTWAuth.js +8 -0
  166. package/dist/esm/global-account/react/hooks/useTokenBalance.js +6 -6
  167. package/dist/esm/global-account/react/hooks/useTokenBalancesByChain.js +4 -2
  168. package/dist/esm/global-account/react/hooks/useTurnkeyAuth.js +50 -22
  169. package/dist/esm/global-account/react/hooks/useUser.d.ts +60 -0
  170. package/dist/esm/global-account/react/hooks/useUser.js +17 -0
  171. package/dist/esm/global-account/react/hooks/useUserQuery.js +1 -27
  172. package/dist/esm/global-account/react/index.native.d.ts +0 -2
  173. package/dist/esm/global-account/react/index.native.js +0 -2
  174. package/dist/esm/global-account/react/stores/configStore.d.ts +24 -0
  175. package/dist/esm/global-account/react/stores/configStore.js +27 -0
  176. package/dist/esm/global-account/react/stores/index.d.ts +1 -0
  177. package/dist/esm/global-account/react/stores/index.js +1 -0
  178. package/dist/esm/global-account/react/stores/useModalStore.d.ts +10 -0
  179. package/dist/esm/global-account/react/stores/userStore.d.ts +22 -0
  180. package/dist/esm/global-account/react/stores/userStore.js +27 -0
  181. package/dist/styles/index.css +1 -1
  182. package/dist/types/anyspend/constants/index.d.ts +2 -0
  183. package/dist/types/anyspend/index.d.ts +2 -0
  184. package/dist/types/anyspend/react/components/AnySpend.d.ts +6 -0
  185. package/dist/types/anyspend/react/components/AnySpendCollectorClubPurchase.d.ts +5 -1
  186. package/dist/types/anyspend/react/components/AnySpendCustom.d.ts +1 -0
  187. package/dist/types/anyspend/react/components/AnySpendCustomExactIn.d.ts +6 -0
  188. package/dist/types/anyspend/react/components/AnySpendDeposit.d.ts +7 -1
  189. package/dist/types/anyspend/react/components/AnyspendDepositHype.d.ts +4 -0
  190. package/dist/types/anyspend/react/components/common/CryptoReceiveSection.d.ts +3 -1
  191. package/dist/types/anyspend/react/components/common/GasIndicator.d.ts +6 -0
  192. package/dist/types/anyspend/react/components/common/OrderDetails.d.ts +4 -0
  193. package/dist/types/anyspend/react/components/common/PanelOnramp.d.ts +3 -1
  194. package/dist/types/anyspend/react/hooks/index.d.ts +1 -0
  195. package/dist/types/anyspend/react/hooks/useGasPrice.d.ts +37 -0
  196. package/dist/types/anyspend/services/gas.d.ts +21 -0
  197. package/dist/types/anyspend/types/gas.d.ts +61 -0
  198. package/dist/types/global-account/react/components/B3Provider/AuthenticationProvider.d.ts +5 -0
  199. package/dist/types/global-account/react/components/B3Provider/B3Provider.d.ts +2 -18
  200. package/dist/types/global-account/react/components/B3Provider/B3Provider.native.d.ts +5 -5
  201. package/dist/types/global-account/react/components/B3Provider/useB3.d.ts +14 -4
  202. package/dist/types/global-account/react/components/B3Provider/useB3Config.d.ts +10 -2
  203. package/dist/types/global-account/react/components/index.d.ts +1 -2
  204. package/dist/types/global-account/react/hooks/index.d.ts +2 -0
  205. package/dist/types/global-account/react/hooks/useAuth.d.ts +76 -0
  206. package/dist/types/global-account/react/hooks/useTWAuth.d.ts +3 -0
  207. package/dist/types/global-account/react/hooks/useUser.d.ts +60 -0
  208. package/dist/types/global-account/react/index.native.d.ts +0 -2
  209. package/dist/types/global-account/react/stores/configStore.d.ts +24 -0
  210. package/dist/types/global-account/react/stores/index.d.ts +1 -0
  211. package/dist/types/global-account/react/stores/useModalStore.d.ts +10 -0
  212. package/dist/types/global-account/react/stores/userStore.d.ts +22 -0
  213. package/package.json +1 -1
  214. package/src/anyspend/constants/index.ts +3 -0
  215. package/src/anyspend/index.ts +4 -0
  216. package/src/anyspend/react/components/AnySpend.tsx +28 -2
  217. package/src/anyspend/react/components/AnySpendCollectorClubPurchase.tsx +6 -0
  218. package/src/anyspend/react/components/AnySpendCustom.tsx +52 -47
  219. package/src/anyspend/react/components/AnySpendCustomExactIn.tsx +23 -0
  220. package/src/anyspend/react/components/AnySpendDeposit.tsx +27 -18
  221. package/src/anyspend/react/components/AnyspendDepositHype.tsx +4 -0
  222. package/src/anyspend/react/components/common/CryptoPaymentMethod.tsx +15 -1
  223. package/src/anyspend/react/components/common/CryptoReceiveSection.tsx +5 -1
  224. package/src/anyspend/react/components/common/GasIndicator.tsx +59 -0
  225. package/src/anyspend/react/components/common/OrderDetails.tsx +60 -42
  226. package/src/anyspend/react/components/common/PanelOnramp.tsx +5 -1
  227. package/src/anyspend/react/components/common/PaymentStripeWeb2.tsx +3 -4
  228. package/src/anyspend/react/hooks/index.ts +1 -0
  229. package/src/anyspend/react/hooks/useAnyspendCreateOnrampOrder.ts +2 -2
  230. package/src/anyspend/react/hooks/useAnyspendCreateOrder.ts +2 -2
  231. package/src/anyspend/react/hooks/useCreateDepositFirstOrder.ts +2 -2
  232. package/src/anyspend/react/hooks/useGasPrice.ts +70 -0
  233. package/src/anyspend/react/hooks/useValidatedClientReferenceId.ts +2 -2
  234. package/src/anyspend/services/gas.test.ts +31 -0
  235. package/src/anyspend/services/gas.ts +73 -0
  236. package/src/anyspend/types/gas.ts +66 -0
  237. package/src/global-account/react/components/B3DynamicModal.tsx +3 -4
  238. package/src/global-account/react/components/B3Provider/AuthenticationProvider.tsx +19 -0
  239. package/src/global-account/react/components/B3Provider/B3Provider.native.tsx +43 -54
  240. package/src/global-account/react/components/B3Provider/B3Provider.tsx +44 -106
  241. package/src/global-account/react/components/B3Provider/RelayKitProviderWrapper.tsx +4 -1
  242. package/src/global-account/react/components/B3Provider/useB3.ts +4 -13
  243. package/src/global-account/react/components/B3Provider/useB3Account.ts +6 -2
  244. package/src/global-account/react/components/B3Provider/useB3Config.ts +18 -31
  245. package/src/global-account/react/components/ManageAccount/ProfileSection.tsx +2 -4
  246. package/src/global-account/react/components/ManageAccount/channels/DiscordChannel.tsx +2 -2
  247. package/src/global-account/react/components/ManageAccount/channels/EmailChannel.tsx +2 -2
  248. package/src/global-account/react/components/ManageAccount/channels/PhoneChannel.tsx +2 -2
  249. package/src/global-account/react/components/ManageAccount/channels/TelegramChannel.tsx +2 -2
  250. package/src/global-account/react/components/RequestPermissions/RequestPermissions.tsx +4 -4
  251. package/src/global-account/react/components/SignInWithB3/SignIn.tsx +2 -2
  252. package/src/global-account/react/components/SignInWithB3/SignInWithB3Flow.tsx +168 -100
  253. package/src/global-account/react/components/SignInWithB3/SignInWithB3Privy.tsx +2 -2
  254. package/src/global-account/react/components/SignInWithB3/steps/LoginStep.tsx +2 -2
  255. package/src/global-account/react/components/SignInWithB3/steps/LoginStepCustom.tsx +2 -2
  256. package/src/global-account/react/components/StyleRoot.tsx +3 -3
  257. package/src/global-account/react/components/TurnkeyAuthModal.tsx +7 -4
  258. package/src/global-account/react/components/custom/ManageAccountButton.tsx +2 -3
  259. package/src/global-account/react/components/index.ts +1 -2
  260. package/src/global-account/react/hooks/index.ts +2 -0
  261. package/src/global-account/react/hooks/useAuth.ts +379 -0
  262. package/src/global-account/react/hooks/useClient.ts +2 -2
  263. package/src/global-account/react/hooks/useHandleConnectWithPrivy.tsx +2 -2
  264. package/src/global-account/react/hooks/useNotifications.ts +2 -2
  265. package/src/global-account/react/hooks/useTWAuth.tsx +10 -0
  266. package/src/global-account/react/hooks/useTokenBalance.tsx +8 -7
  267. package/src/global-account/react/hooks/useTokenBalancesByChain.tsx +4 -2
  268. package/src/global-account/react/hooks/useTurnkeyAuth.ts +54 -23
  269. package/src/global-account/react/hooks/useUser.ts +20 -0
  270. package/src/global-account/react/hooks/useUserQuery.ts +1 -40
  271. package/src/global-account/react/index.native.ts +0 -2
  272. package/src/global-account/react/stores/configStore.ts +51 -0
  273. package/src/global-account/react/stores/index.ts +1 -0
  274. package/src/global-account/react/stores/useModalStore.ts +10 -0
  275. package/src/global-account/react/stores/userStore.ts +41 -0
  276. package/dist/cjs/global-account/react/components/B3Provider/types.d.ts +0 -27
  277. package/dist/cjs/global-account/react/components/B3Provider/types.js +0 -24
  278. package/dist/esm/global-account/react/components/B3Provider/types.d.ts +0 -27
  279. package/dist/esm/global-account/react/components/B3Provider/types.js +0 -21
  280. package/dist/types/global-account/react/components/B3Provider/types.d.ts +0 -27
  281. package/src/global-account/react/components/B3Provider/types.ts +0 -50
@@ -1,24 +1,16 @@
1
1
  import { PermissionsConfig } from "@b3dotfun/sdk/global-account/types/permissions";
2
2
  import { QueryClient, QueryClientProvider } from "@tanstack/react-query";
3
- import { ThirdwebProvider, useActiveAccount } from "thirdweb/react";
3
+ import { useEffect } from "react";
4
+ import { ThirdwebProvider } from "thirdweb/react";
4
5
  import { Account, Wallet } from "thirdweb/wallets";
5
6
 
6
7
  import { ClientType } from "../../../client-manager";
7
8
 
8
9
  import { WagmiProvider } from "wagmi";
10
+ import { useB3ConfigStore } from "../../stores/configStore";
9
11
  import { createWagmiConfig } from "../../utils/createWagmiConfig";
12
+ import AuthenticationProvider from "./AuthenticationProvider";
10
13
  import { LocalSDKProvider } from "./LocalSDKProvider";
11
- import { B3Context, B3ContextType } from "./types";
12
-
13
- /**
14
- * Default permissions configuration for B3 provider
15
- */
16
- const DEFAULT_PERMISSIONS = {
17
- approvedTargets: ["0xa8e42121e318e3D3BeD7f5969AF6D360045317DD"], // Example contract
18
- nativeTokenLimitPerTransaction: 0.1, // in ETH
19
- startDate: new Date(),
20
- endDate: new Date(Date.now() + 1000 * 60 * 60 * 24 * 365), // 1 year from now
21
- };
22
14
 
23
15
  // Create queryClient instance
24
16
  const queryClient = new QueryClient();
@@ -35,44 +27,53 @@ export function B3Provider({
35
27
  partnerId,
36
28
  rpcUrls,
37
29
  onConnect,
30
+ defaultPermissions,
38
31
  }: {
39
32
  theme: "light" | "dark";
40
33
  children: React.ReactNode;
41
34
  accountOverride?: Account;
42
- environment: B3ContextType["environment"];
35
+ environment?: "development" | "production";
43
36
  clientType?: ClientType;
44
37
  partnerId: string;
45
38
  rpcUrls?: Record<number, string>;
46
39
  onConnect?: (wallet: Wallet, b3Jwt: string) => void | Promise<void>;
40
+ defaultPermissions?: PermissionsConfig;
47
41
  }) {
42
+ const setConfig = useB3ConfigStore(state => state.setConfig);
43
+
44
+ // Initialize config store on mount - props are static and never change
45
+ useEffect(() => {
46
+ setConfig({
47
+ accountOverride,
48
+ environment: environment ?? "development",
49
+ automaticallySetFirstEoa: false,
50
+ theme,
51
+ clientType,
52
+ partnerId,
53
+ defaultPermissions,
54
+ });
55
+ }, []); // eslint-disable-line react-hooks/exhaustive-deps
56
+
48
57
  return (
49
58
  <ThirdwebProvider>
50
59
  <LocalSDKProvider onConnectCallback={onConnect}>
51
- <InnerProvider
52
- accountOverride={accountOverride}
53
- environment={environment}
54
- theme={theme}
55
- clientType={clientType}
56
- partnerId={partnerId}
57
- rpcUrls={rpcUrls}
58
- >
59
- {/* <RelayKitProviderWrapper> */}
60
- {children}
61
- {/* </RelayKitProviderWrapper> */}
62
- </InnerProvider>
60
+ {/* <RelayKitProviderWrapper> */}
61
+ {children}
62
+ <AuthenticationProvider partnerId={partnerId} automaticallySetFirstEoa={false} />
63
+ {/* </RelayKitProviderWrapper> */}
63
64
  </LocalSDKProvider>
64
65
  </ThirdwebProvider>
65
66
  );
66
67
  }
67
68
 
68
69
  /**
69
- * Inner provider component that provides the actual B3Context
70
+ * Inner provider component for native
70
71
  */
71
72
  export function InnerProvider({
72
73
  children,
73
74
  accountOverride,
74
75
  environment,
75
- defaultPermissions = DEFAULT_PERMISSIONS,
76
+ defaultPermissions,
76
77
  theme = "light",
77
78
  clientType = "socket",
78
79
  partnerId,
@@ -80,44 +81,32 @@ export function InnerProvider({
80
81
  }: {
81
82
  children: React.ReactNode;
82
83
  accountOverride?: Account;
83
- environment: B3ContextType["environment"];
84
+ environment?: "development" | "production";
84
85
  defaultPermissions?: PermissionsConfig;
85
86
  theme: "light" | "dark";
86
87
  clientType?: ClientType;
87
88
  partnerId: string;
88
89
  rpcUrls?: Record<number, string>;
89
90
  }) {
90
- const activeAccount = useActiveAccount();
91
- //const { user, setUser, refetchUser } = useAuthentication(partnerId);
91
+ const setConfig = useB3ConfigStore(state => state.setConfig);
92
92
  const wagmiConfig = createWagmiConfig({ partnerId, rpcUrls });
93
93
 
94
- // Use given accountOverride or activeAccount from thirdweb
95
- const effectiveAccount = accountOverride || activeAccount;
94
+ // Initialize config store on mount - props are static and never change
95
+ useEffect(() => {
96
+ setConfig({
97
+ accountOverride,
98
+ environment: environment ?? "development",
99
+ automaticallySetFirstEoa: false,
100
+ theme,
101
+ clientType,
102
+ partnerId,
103
+ defaultPermissions,
104
+ });
105
+ }, []); // eslint-disable-line react-hooks/exhaustive-deps
96
106
 
97
107
  return (
98
108
  <WagmiProvider config={wagmiConfig}>
99
- <QueryClientProvider client={queryClient}>
100
- <B3Context.Provider
101
- value={{
102
- //account: effectiveAccount,
103
- automaticallySetFirstEoa: false,
104
- //setWallet: () => {},
105
- wallet: undefined,
106
- //user,
107
- //setUser,
108
- initialized: true,
109
- ready: !!effectiveAccount,
110
- environment,
111
- defaultPermissions,
112
- theme,
113
- clientType,
114
- partnerId,
115
- //refetchUser,
116
- }}
117
- >
118
- {children}
119
- </B3Context.Provider>
120
- </QueryClientProvider>
109
+ <QueryClientProvider client={queryClient}>{children}</QueryClientProvider>
121
110
  </WagmiProvider>
122
111
  );
123
112
  }
@@ -1,31 +1,21 @@
1
1
  import { CreateOnrampOrderParams } from "@b3dotfun/sdk/anyspend/react/hooks/useAnyspendCreateOnrampOrder";
2
2
  import { CreateOrderParams } from "@b3dotfun/sdk/anyspend/react/hooks/useAnyspendCreateOrder";
3
- import { RelayKitProviderWrapper, TooltipProvider, useAuthStore } from "@b3dotfun/sdk/global-account/react";
4
- import { useAutoSelectWallet } from "@b3dotfun/sdk/global-account/react/hooks/useAutoSelectWallet";
3
+ import { RelayKitProviderWrapper, TooltipProvider } from "@b3dotfun/sdk/global-account/react";
5
4
  import { createWagmiConfig } from "@b3dotfun/sdk/global-account/react/utils/createWagmiConfig";
6
5
  import { PermissionsConfig } from "@b3dotfun/sdk/global-account/types/permissions";
7
6
  import { loadGA4Script } from "@b3dotfun/sdk/global-account/utils/analytics";
8
7
  import "@relayprotocol/relay-kit-ui/styles.css";
9
8
  import { QueryClient, QueryClientProvider } from "@tanstack/react-query";
10
9
  import { useEffect, useMemo } from "react";
11
- import { ThirdwebProvider, useActiveAccount } from "thirdweb/react";
10
+ import { ThirdwebProvider } from "thirdweb/react";
12
11
  import { Account, Wallet } from "thirdweb/wallets";
13
12
  import { CreateConnectorFn, WagmiProvider } from "wagmi";
14
13
  import { ClientType, setClientType } from "../../../client-manager";
14
+ import { useB3ConfigStore } from "../../stores/configStore";
15
15
  import { StyleRoot } from "../StyleRoot";
16
16
  import { setToastContext, ToastProvider, useToastContext } from "../Toast/index";
17
+ import AuthenticationProvider from "./AuthenticationProvider";
17
18
  import { LocalSDKProvider } from "./LocalSDKProvider";
18
- import { B3Context, B3ContextType } from "./types";
19
-
20
- /**
21
- * Default permissions configuration for B3 provider
22
- */
23
- const DEFAULT_PERMISSIONS = {
24
- approvedTargets: ["0xa8e42121e318e3D3BeD7f5969AF6D360045317DD"], // Example contract
25
- nativeTokenLimitPerTransaction: 0.1, // in ETH
26
- startDate: new Date(),
27
- endDate: new Date(Date.now() + 1000 * 60 * 60 * 24 * 365), // 1 year from now
28
- };
29
19
 
30
20
  // Create queryClient instance
31
21
  const queryClient = new QueryClient();
@@ -51,11 +41,12 @@ export function B3Provider({
51
41
  overrideDefaultConnectors = false,
52
42
  createClientReferenceId,
53
43
  enableTurnkey = false,
44
+ defaultPermissions,
54
45
  }: {
55
46
  theme: "light" | "dark";
56
47
  children: React.ReactNode;
57
48
  accountOverride?: Account;
58
- environment: B3ContextType["environment"];
49
+ environment?: "development" | "production";
59
50
  automaticallySetFirstEoa?: boolean;
60
51
  simDuneApiKey?: string;
61
52
  toaster?: {
@@ -72,7 +63,38 @@ export function B3Provider({
72
63
  overrideDefaultConnectors?: boolean;
73
64
  createClientReferenceId?: (params: CreateOrderParams | CreateOnrampOrderParams) => Promise<string>;
74
65
  enableTurnkey?: boolean;
66
+ defaultPermissions?: PermissionsConfig;
75
67
  }) {
68
+ const setConfig = useB3ConfigStore(state => state.setConfig);
69
+
70
+ // Initialize config store on mount
71
+ useEffect(() => {
72
+ setConfig({
73
+ accountOverride,
74
+ environment: environment ?? "development",
75
+ automaticallySetFirstEoa: !!automaticallySetFirstEoa,
76
+ theme,
77
+ clientType,
78
+ partnerId,
79
+ stripePublishableKey,
80
+ createClientReferenceId,
81
+ enableTurnkey,
82
+ defaultPermissions,
83
+ });
84
+ }, [
85
+ accountOverride,
86
+ environment,
87
+ automaticallySetFirstEoa,
88
+ theme,
89
+ clientType,
90
+ partnerId,
91
+ stripePublishableKey,
92
+ createClientReferenceId,
93
+ enableTurnkey,
94
+ defaultPermissions,
95
+ setConfig,
96
+ ]); // eslint-disable-line react-hooks/exhaustive-deps
97
+
76
98
  // Initialize Google Analytics on mount
77
99
  useEffect(() => {
78
100
  loadGA4Script();
@@ -95,24 +117,13 @@ export function B3Provider({
95
117
  <TooltipProvider>
96
118
  <ToastProvider>
97
119
  <LocalSDKProvider onConnectCallback={onConnect}>
98
- <InnerProvider
99
- accountOverride={accountOverride}
100
- environment={environment}
101
- theme={theme}
102
- automaticallySetFirstEoa={!!automaticallySetFirstEoa}
103
- clientType={clientType}
104
- partnerId={partnerId}
105
- stripePublishableKey={stripePublishableKey}
106
- createClientReferenceId={createClientReferenceId}
107
- enableTurnkey={enableTurnkey}
108
- >
109
- <ToastContextConnector />
110
- <RelayKitProviderWrapper simDuneApiKey={simDuneApiKey}>
111
- {children}
112
- {/* For the modal https://github.com/b3-fun/b3/blob/main/packages/sdk/src/global-account/react/components/ui/dialog.tsx#L46 */}
113
- <StyleRoot id="b3-root" />
114
- </RelayKitProviderWrapper>
115
- </InnerProvider>
120
+ <ToastContextConnector />
121
+ <RelayKitProviderWrapper simDuneApiKey={simDuneApiKey}>
122
+ {children}
123
+ {/* For the modal https://github.com/b3-fun/b3/blob/main/packages/sdk/src/global-account/react/components/ui/dialog.tsx#L46 */}
124
+ <StyleRoot id="b3-root" />
125
+ </RelayKitProviderWrapper>
126
+ <AuthenticationProvider partnerId={partnerId} automaticallySetFirstEoa={!!automaticallySetFirstEoa} />
116
127
  </LocalSDKProvider>
117
128
  </ToastProvider>
118
129
  </TooltipProvider>
@@ -122,79 +133,6 @@ export function B3Provider({
122
133
  );
123
134
  }
124
135
 
125
- /**
126
- * Inner provider component that provides the actual B3Context
127
- */
128
- export function InnerProvider({
129
- children,
130
- accountOverride,
131
- environment,
132
- defaultPermissions = DEFAULT_PERMISSIONS,
133
- automaticallySetFirstEoa,
134
- theme = "light",
135
- clientType = "socket",
136
- partnerId,
137
- stripePublishableKey,
138
- createClientReferenceId,
139
- enableTurnkey,
140
- }: {
141
- children: React.ReactNode;
142
- accountOverride?: Account;
143
- environment: B3ContextType["environment"];
144
- defaultPermissions?: PermissionsConfig;
145
- automaticallySetFirstEoa: boolean;
146
- theme: "light" | "dark";
147
- clientType?: ClientType;
148
- partnerId: string;
149
- stripePublishableKey?: string;
150
- createClientReferenceId?: (params: CreateOrderParams | CreateOnrampOrderParams) => Promise<string>;
151
- enableTurnkey?: boolean;
152
- }) {
153
- const activeAccount = useActiveAccount();
154
- const isAuthenticated = useAuthStore(state => state.isAuthenticated);
155
- //const isConnected = useAuthStore(state => state.isConnected);
156
- //const justCompletedLogin = useAuthStore(state => state.justCompletedLogin);
157
-
158
- // Use given accountOverride or activeAccount from thirdweb
159
- // WOJ: why if isAuthenticated is false, we don't use activeAccount, which should be undefined?
160
- // skip isAuthenticated check ?
161
- const effectiveAccount = isAuthenticated ? accountOverride || activeAccount : undefined;
162
-
163
- // Wrapper to set active wallet via thirdweb
164
- // Note: `wallet` in context is deprecated - use useActiveWallet() from thirdweb/react instead
165
-
166
- // Auto-select first EOA wallet when enabled
167
- useAutoSelectWallet({
168
- enabled: automaticallySetFirstEoa,
169
- });
170
-
171
- return (
172
- <B3Context.Provider
173
- value={{
174
- account: effectiveAccount,
175
- // setWallet,
176
- //wallet: undefined, // Deprecated: use useActiveWallet() from thirdweb/react instead
177
- //user,
178
- //setUser,
179
- //refetchUser,
180
- initialized: true,
181
- ready: !!effectiveAccount,
182
- automaticallySetFirstEoa,
183
- environment,
184
- defaultPermissions,
185
- theme,
186
- clientType,
187
- partnerId: partnerId,
188
- stripePublishableKey,
189
- createClientReferenceId,
190
- enableTurnkey,
191
- }}
192
- >
193
- {children}
194
- </B3Context.Provider>
195
- );
196
- }
197
-
198
136
  /**
199
137
  * Component to connect the toast context to the global toast API
200
138
  */
@@ -19,6 +19,9 @@ export function RelayKitProviderWrapper({
19
19
  fetchChains();
20
20
  }, []);
21
21
 
22
+ const isTurnkeyPrimary = process.env.NEXT_PUBLIC_TURNKEY_PRIMARY === "true";
23
+ const appName = isTurnkeyPrimary ? "Smart Wallet" : "AnySpend";
24
+
22
25
  return (
23
26
  <RelayKitProvider
24
27
  options={{
@@ -30,7 +33,7 @@ export function RelayKitProviderWrapper({
30
33
  },
31
34
  chains: relayChains,
32
35
  privateChainIds: undefined,
33
- appName: "AnySpend",
36
+ appName,
34
37
  useGasFeeEstimations: true,
35
38
  }}
36
39
  >
@@ -1,18 +1,9 @@
1
- import { useContext, useMemo } from "react";
2
- import { B3Context } from "./types";
1
+ import { useB3Config } from "./useB3Config";
3
2
 
4
3
  /**
5
- * Hook to access the B3 context
6
- * @throws Error if used outside a B3Provider
7
- * @deprecated Use useB3Config or useB3Account instead
4
+ * Hook to access the B3 configuration
5
+ * @deprecated This is just an alias for useB3Config. Use useB3Config directly instead.
8
6
  */
9
7
  export function useB3() {
10
- const context = useContext(B3Context);
11
-
12
- if (!context.initialized) {
13
- throw new Error("useB3 must be used within a B3Provider");
14
- }
15
-
16
- // Return a stable reference
17
- return useMemo(() => context, [context]);
8
+ return useB3Config();
18
9
  }
@@ -1,7 +1,11 @@
1
1
  import { useActiveAccount } from "thirdweb/react";
2
+ import { useAuthStore } from "../../stores/useAuthStore";
2
3
 
3
4
  // Wrapper around useActiveAccount
4
5
  export const useB3Account = () => {
5
- const account = useActiveAccount();
6
- return account;
6
+ const isAuthenticated = useAuthStore(state => state.isAuthenticated);
7
+ const activeAccount = useActiveAccount();
8
+ const effectiveAccount = isAuthenticated ? activeAccount : undefined;
9
+
10
+ return effectiveAccount;
7
11
  };
@@ -1,34 +1,21 @@
1
- import { useContext, useMemo } from "react";
2
- import { B3Context } from "./types";
1
+ import { useB3ConfigStore } from "../../stores/configStore";
3
2
 
3
+ /**
4
+ * Hook to access B3 configuration
5
+ * Returns all config values from the Zustand store
6
+ * Since config is static (set once at initialization), destructuring is fine here
7
+ */
4
8
  export const useB3Config = () => {
5
- const context = useContext(B3Context);
6
-
7
- if (!context) {
8
- throw new Error("useB3 must be used within a B3Provider");
9
- }
10
-
11
- const {
12
- automaticallySetFirstEoa,
13
- environment,
14
- theme,
15
- clientType,
16
- partnerId,
17
- createClientReferenceId,
18
- enableTurnkey,
19
- } = context;
20
-
21
- // Return a stable reference
22
- return useMemo(
23
- () => ({
24
- automaticallySetFirstEoa,
25
- environment,
26
- theme,
27
- clientType,
28
- partnerId,
29
- createClientReferenceId,
30
- enableTurnkey,
31
- }),
32
- [automaticallySetFirstEoa, environment, theme, clientType, partnerId, createClientReferenceId, enableTurnkey],
33
- );
9
+ return useB3ConfigStore(state => ({
10
+ automaticallySetFirstEoa: state.automaticallySetFirstEoa,
11
+ environment: state.environment,
12
+ theme: state.theme,
13
+ clientType: state.clientType,
14
+ partnerId: state.partnerId,
15
+ createClientReferenceId: state.createClientReferenceId,
16
+ enableTurnkey: state.enableTurnkey,
17
+ stripePublishableKey: state.stripePublishableKey,
18
+ defaultPermissions: state.defaultPermissions,
19
+ accountOverride: state.accountOverride,
20
+ }));
34
21
  };
@@ -1,10 +1,9 @@
1
1
  import {
2
2
  useAccountWallet,
3
- useAuthentication,
4
- useB3Config,
5
3
  useModalStore,
6
4
  useProfile,
7
5
  useSimBalance,
6
+ useUser,
8
7
  } from "@b3dotfun/sdk/global-account/react";
9
8
  import { formatUsername } from "@b3dotfun/sdk/shared/utils";
10
9
  import { formatDisplayNumber } from "@b3dotfun/sdk/shared/utils/number";
@@ -22,8 +21,7 @@ const ProfileSection = () => {
22
21
  address: eoaAddress || account?.address,
23
22
  fresh: true,
24
23
  });
25
- const { partnerId } = useB3Config();
26
- const { user } = useAuthentication(partnerId);
24
+ const { user } = useUser();
27
25
  const setB3ModalOpen = useModalStore(state => state.setB3ModalOpen);
28
26
  const setB3ModalContentType = useModalStore(state => state.setB3ModalContentType);
29
27
  const navigateBack = useModalStore(state => state.navigateBack);
@@ -1,7 +1,7 @@
1
+ import { useB3Config } from "@b3dotfun/sdk/global-account/react";
1
2
  import { debugB3React } from "@b3dotfun/sdk/shared/utils/debug";
2
3
  import { useState } from "react";
3
4
  import { notificationsAPI } from "../../../utils/notificationsAPI";
4
- import { useB3 } from "../../B3Provider/useB3";
5
5
  import { toast } from "../../Toast/toastApi";
6
6
  import { NotificationChannel } from "../NotificationChannel";
7
7
 
@@ -26,7 +26,7 @@ export const DiscordChannel = ({
26
26
  onConnectionChange,
27
27
  onToggle,
28
28
  }: DiscordChannelProps) => {
29
- const { partnerId } = useB3();
29
+ const { partnerId } = useB3Config();
30
30
 
31
31
  const [discordId, setDiscordId] = useState("");
32
32
  const [isConnecting, setIsConnecting] = useState(false);
@@ -1,7 +1,7 @@
1
+ import { useB3Config } from "@b3dotfun/sdk/global-account/react";
1
2
  import { debugB3React } from "@b3dotfun/sdk/shared/utils/debug";
2
3
  import { useState } from "react";
3
4
  import { notificationsAPI } from "../../../utils/notificationsAPI";
4
- import { useB3 } from "../../B3Provider/useB3";
5
5
  import { toast } from "../../Toast/toastApi";
6
6
  import { NotificationChannel } from "../NotificationChannel";
7
7
 
@@ -31,7 +31,7 @@ export const EmailChannel = ({
31
31
  onConnectionChange,
32
32
  onToggle,
33
33
  }: EmailChannelProps) => {
34
- const { partnerId } = useB3();
34
+ const { partnerId } = useB3Config();
35
35
 
36
36
  const [email, setEmail] = useState("");
37
37
  const [emailError, setEmailError] = useState<string | null>(null);
@@ -1,7 +1,7 @@
1
+ import { useB3Config } from "@b3dotfun/sdk/global-account/react";
1
2
  import { debugB3React } from "@b3dotfun/sdk/shared/utils/debug";
2
3
  import { useState } from "react";
3
4
  import { notificationsAPI } from "../../../utils/notificationsAPI";
4
- import { useB3 } from "../../B3Provider/useB3";
5
5
  import { toast } from "../../Toast/toastApi";
6
6
  import { NotificationChannel } from "../NotificationChannel";
7
7
 
@@ -32,7 +32,7 @@ export const PhoneChannel = ({
32
32
  onConnectionChange,
33
33
  onToggle,
34
34
  }: PhoneChannelProps) => {
35
- const { partnerId } = useB3();
35
+ const { partnerId } = useB3Config();
36
36
 
37
37
  const [phoneNumber, setPhoneNumber] = useState("");
38
38
  const [isConnectingSMS, setIsConnectingSMS] = useState(false);
@@ -1,7 +1,7 @@
1
+ import { useB3Config } from "@b3dotfun/sdk/global-account/react";
1
2
  import { debugB3React } from "@b3dotfun/sdk/shared/utils/debug";
2
3
  import { useState } from "react";
3
4
  import { notificationsAPI } from "../../../utils/notificationsAPI";
4
- import { useB3 } from "../../B3Provider/useB3";
5
5
  import { toast } from "../../Toast/toastApi";
6
6
  import { NotificationChannel } from "../NotificationChannel";
7
7
 
@@ -26,7 +26,7 @@ export const TelegramChannel = ({
26
26
  onConnectionChange,
27
27
  onToggle,
28
28
  }: TelegramChannelProps) => {
29
- const { partnerId } = useB3();
29
+ const { partnerId } = useB3Config();
30
30
 
31
31
  const [isConnecting, setIsConnecting] = useState(false);
32
32
  const [status, setStatus] = useState<"idle" | "pending" | "connected">("idle");
@@ -1,11 +1,11 @@
1
1
  import {
2
2
  Button,
3
- useB3,
3
+ PermissionItem,
4
+ RequestPermissionsModalProps,
4
5
  useAddTWSessionKey,
6
+ useB3Config,
5
7
  useGetAllTWSigners,
6
- RequestPermissionsModalProps,
7
8
  } from "@b3dotfun/sdk/global-account/react";
8
- import { PermissionItem } from "@b3dotfun/sdk/global-account/react";
9
9
  import { PermissionsConfig } from "@b3dotfun/sdk/global-account/types/permissions";
10
10
  import { debugB3React } from "@b3dotfun/sdk/shared/utils/debug";
11
11
  import { formatAddress } from "@b3dotfun/sdk/shared/utils/formatAddress";
@@ -30,7 +30,7 @@ export function RequestPermissions({
30
30
  }: RequestPermissionsModalProps) {
31
31
  const [isApproving, setIsApproving] = useState(false);
32
32
  const account = useActiveAccount();
33
- const { defaultPermissions } = useB3();
33
+ const { defaultPermissions } = useB3Config();
34
34
  const DEFAULT_PERMISSIONS = useMemo(
35
35
  () => permissions ?? (defaultPermissions as PermissionsConfig),
36
36
  [defaultPermissions, permissions],
@@ -5,7 +5,7 @@ import {
5
5
  StyleRoot,
6
6
  useAccountWallet,
7
7
  useAuthentication,
8
- useB3,
8
+ useB3Config,
9
9
  useIsMobile,
10
10
  } from "@b3dotfun/sdk/global-account/react";
11
11
  import Icon from "@b3dotfun/sdk/global-account/react/components/custom/Icon";
@@ -30,7 +30,7 @@ type SignInWithB3Props = Omit<SignInWithB3ModalProps, "type" | "showBackButton">
30
30
 
31
31
  export function SignIn(props: SignInWithB3Props) {
32
32
  const { className } = props;
33
- const { automaticallySetFirstEoa, partnerId } = useB3();
33
+ const { automaticallySetFirstEoa, partnerId } = useB3Config();
34
34
  const {
35
35
  address: globalAddress,
36
36
  ensName,