@b3dotfun/sdk 0.0.7-alpha.12 → 0.0.7-alpha.14
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/anyspend/abis/abi-usdc-base.js +97 -97
- package/dist/cjs/anyspend/abis/erc20-staking.js +51 -51
- package/dist/cjs/anyspend/constants/index.js +10 -10
- package/dist/cjs/anyspend/react/components/AnySpend.d.ts +1 -1
- package/dist/cjs/anyspend/react/components/AnySpend.js +20 -20
- package/dist/cjs/anyspend/react/components/AnySpendBuySpin.d.ts +1 -1
- package/dist/cjs/anyspend/react/components/AnySpendBuySpin.js +32 -32
- package/dist/cjs/anyspend/react/components/AnySpendCustom.d.ts +2 -2
- package/dist/cjs/anyspend/react/components/AnySpendCustom.js +29 -29
- package/dist/cjs/anyspend/react/components/AnySpendNFT.d.ts +1 -1
- package/dist/cjs/anyspend/react/components/AnySpendNFT.js +4 -4
- package/dist/cjs/anyspend/react/components/AnySpendNFTButton.js +1 -1
- package/dist/cjs/anyspend/react/components/AnySpendStakeB3.d.ts +1 -1
- package/dist/cjs/anyspend/react/components/AnySpendStakeB3.js +17 -17
- package/dist/cjs/anyspend/react/components/AnySpendTournament.js +4 -4
- package/dist/cjs/anyspend/react/components/common/ChainTokenIcon.d.ts +1 -1
- package/dist/cjs/anyspend/react/components/common/ChainTokenIcon.js +1 -1
- package/dist/cjs/anyspend/react/components/common/OrderDetails.js +9 -9
- package/dist/cjs/anyspend/react/components/common/OrderToken.d.ts +1 -1
- package/dist/cjs/anyspend/react/components/common/OrderToken.js +4 -4
- package/dist/cjs/anyspend/react/components/common/OrderTokenAmount.d.ts +1 -1
- package/dist/cjs/anyspend/react/components/common/OrderTokenAmount.js +2 -2
- package/dist/cjs/anyspend/react/components/common/PanelOnramp.d.ts +1 -1
- package/dist/cjs/anyspend/react/components/common/PanelOnramp.js +2 -2
- package/dist/cjs/anyspend/react/components/common/PanelOnrampPayment.d.ts +1 -1
- package/dist/cjs/anyspend/react/components/common/PanelOnrampPayment.js +7 -7
- package/dist/cjs/anyspend/react/components/common/PaymentMethodIcons.js +1 -1
- package/dist/cjs/anyspend/react/components/common/PaymentOneClick.js +3 -3
- package/dist/cjs/anyspend/react/components/common/PaymentStripeWeb2.js +12 -12
- package/dist/cjs/anyspend/react/components/common/TokenBalance.d.ts +1 -1
- package/dist/cjs/anyspend/react/components/common/TokenBalance.js +2 -2
- package/dist/cjs/anyspend/react/components/index.d.ts +1 -0
- package/dist/cjs/anyspend/react/components/index.js +3 -1
- package/dist/cjs/anyspend/react/components/modals/EnterRecipientModal.d.ts +1 -1
- package/dist/cjs/anyspend/react/components/modals/EnterRecipientModal.js +1 -1
- package/dist/cjs/anyspend/react/components/webview/WebviewOnrampPayment.d.ts +1 -1
- package/dist/cjs/anyspend/react/components/webview/WebviewOnrampPayment.js +14 -14
- package/dist/cjs/anyspend/react/hooks/useAnyspendCreateOnrampOrder.js +6 -6
- package/dist/cjs/anyspend/react/hooks/useAnyspendCreateOrder.js +6 -6
- package/dist/cjs/anyspend/react/hooks/useAnyspendOrderAndTransactions.d.ts +10 -0
- package/dist/cjs/anyspend/react/hooks/useAnyspendOrderAndTransactions.js +2 -2
- package/dist/cjs/anyspend/react/hooks/useAnyspendOrderHistory.d.ts +10 -0
- package/dist/cjs/anyspend/react/hooks/useAnyspendOrderHistory.js +3 -3
- package/dist/cjs/anyspend/react/hooks/useAnyspendQuote.js +2 -2
- package/dist/cjs/anyspend/react/hooks/useAnyspendSendPermitData.js +3 -3
- package/dist/cjs/anyspend/react/hooks/useAnyspendTokens.js +3 -3
- package/dist/cjs/anyspend/react/hooks/useCoinbaseOnrampOptions.js +2 -2
- package/dist/cjs/anyspend/react/hooks/useGeoOnrampOptions.js +2 -2
- package/dist/cjs/anyspend/react/hooks/useGetGeo.js +1 -1
- package/dist/cjs/anyspend/react/hooks/usePermitData.js +19 -19
- package/dist/cjs/anyspend/react/hooks/useStripeClientSecret.js +2 -2
- package/dist/cjs/anyspend/react/hooks/useStripeSupport.js +2 -2
- package/dist/cjs/anyspend/react/providers/AnyspendProvider.js +3 -3
- package/dist/cjs/anyspend/services/anyspend.d.ts +6 -1
- package/dist/cjs/anyspend/services/anyspend.js +13 -13
- package/dist/cjs/anyspend/types/custom.js +2 -2
- package/dist/cjs/anyspend/types/globalWallet.js +1 -1
- package/dist/cjs/anyspend/types/nft.js +6 -6
- package/dist/cjs/anyspend/types/onramp.d.ts +3 -0
- package/dist/cjs/anyspend/types/onramp.js +2 -1
- package/dist/cjs/anyspend/types/order.d.ts +30 -0
- package/dist/cjs/anyspend/types/order.js +7 -7
- package/dist/cjs/anyspend/types/permit.js +1 -1
- package/dist/cjs/anyspend/types/req-res/createOrder.d.ts +70 -0
- package/dist/cjs/anyspend/types/req-res/createOrder.js +9 -9
- package/dist/cjs/anyspend/types/req-res/getCoinbaseOnrampOptions.js +5 -5
- package/dist/cjs/anyspend/types/req-res/getOrderAndTransactions.d.ts +45 -0
- package/dist/cjs/anyspend/types/req-res/getOrderAndTransactions.js +4 -4
- package/dist/cjs/anyspend/types/req-res/getOrderByCreator.js +2 -2
- package/dist/cjs/anyspend/types/req-res/getOrderHistory.d.ts +35 -0
- package/dist/cjs/anyspend/types/req-res/getOrderHistory.js +1 -1
- package/dist/cjs/anyspend/types/req-res/getQuote.d.ts +26 -0
- package/dist/cjs/anyspend/types/req-res/getQuote.js +10 -8
- package/dist/cjs/anyspend/types/req-res/getTokenList.js +3 -3
- package/dist/cjs/anyspend/types/req-res/sendPermitData.js +2 -2
- package/dist/cjs/anyspend/types/swap.js +2 -2
- package/dist/cjs/anyspend/types/token.js +2 -2
- package/dist/cjs/anyspend/types/tournament.js +4 -4
- package/dist/cjs/anyspend/types/transaction.js +4 -4
- package/dist/cjs/anyspend/utils/chain.js +16 -16
- package/dist/cjs/anyspend/utils/format.js +2 -2
- package/dist/cjs/anyspend/utils/orderPayload.js +6 -6
- package/dist/cjs/anyspend/utils/token.js +10 -10
- package/dist/cjs/global-account/app.js +4 -4
- package/dist/cjs/global-account/app.native.js +4 -4
- package/dist/cjs/global-account/bsmnt.js +4 -4
- package/dist/cjs/global-account/bsmnt.native.js +4 -4
- package/dist/cjs/global-account/react/components/B3DynamicModal.js +1 -1
- package/dist/cjs/global-account/react/components/B3Provider/B3Provider.d.ts +2 -2
- package/dist/cjs/global-account/react/components/B3Provider/B3Provider.js +5 -5
- package/dist/cjs/global-account/react/components/B3Provider/B3Provider.native.d.ts +2 -2
- package/dist/cjs/global-account/react/components/B3Provider/B3Provider.native.js +4 -4
- package/dist/cjs/global-account/react/components/B3Provider/types.js +1 -1
- package/dist/cjs/global-account/react/components/ManageAccount/ManageAccount.d.ts +1 -1
- package/dist/cjs/global-account/react/components/ManageAccount/ManageAccount.js +5 -5
- package/dist/cjs/global-account/react/components/MintButton/MintButton.d.ts +1 -1
- package/dist/cjs/global-account/react/components/MintButton/MintButton.js +5 -5
- package/dist/cjs/global-account/react/components/RelayKitProviderWrapper.js +2 -2
- package/dist/cjs/global-account/react/components/RequestPermissions/RequestPermissions.d.ts +1 -1
- package/dist/cjs/global-account/react/components/RequestPermissions/RequestPermissions.js +5 -5
- package/dist/cjs/global-account/react/components/RequestPermissions/RequestPermissionsButton.d.ts +1 -1
- package/dist/cjs/global-account/react/components/RequestPermissions/RequestPermissionsButton.js +2 -2
- package/dist/cjs/global-account/react/components/SignInWithB3/SignIn.js +1 -1
- package/dist/cjs/global-account/react/components/SignInWithB3/SignInWithB3.js +1 -1
- package/dist/cjs/global-account/react/components/SignInWithB3/SignInWithB3Flow.d.ts +1 -1
- package/dist/cjs/global-account/react/components/SignInWithB3/SignInWithB3Flow.js +12 -12
- package/dist/cjs/global-account/react/components/SignInWithB3/SignInWithB3Privy.js +1 -1
- package/dist/cjs/global-account/react/components/SignInWithB3/components/AuthButton.d.ts +1 -1
- package/dist/cjs/global-account/react/components/SignInWithB3/components/AuthButton.js +1 -1
- package/dist/cjs/global-account/react/components/SignInWithB3/components/WalletRow.d.ts +1 -1
- package/dist/cjs/global-account/react/components/SignInWithB3/components/WalletRow.js +1 -1
- package/dist/cjs/global-account/react/components/SignInWithB3/steps/LoginStep.js +9 -9
- package/dist/cjs/global-account/react/components/SignInWithB3/steps/LoginStepCustom.d.ts +1 -1
- package/dist/cjs/global-account/react/components/SignInWithB3/steps/LoginStepCustom.js +2 -2
- package/dist/cjs/global-account/react/components/SignInWithB3/utils/signInUtils.js +2 -2
- package/dist/cjs/global-account/react/components/Transak/TransakModal.js +4 -4
- package/dist/cjs/global-account/react/components/custom/Button.js +5 -5
- package/dist/cjs/global-account/react/components/custom/Icon.js +1 -1
- package/dist/cjs/global-account/react/components/custom/ManageAccountButton.js +1 -1
- package/dist/cjs/global-account/react/components/custom/StaggeredFadeLoader.js +3 -3
- package/dist/cjs/global-account/react/components/index.d.ts +4 -4
- package/dist/cjs/global-account/react/components/magicui/AnimatedLottie.js +1 -1
- package/dist/cjs/global-account/react/components/ui/Loading.js +2 -2
- package/dist/cjs/global-account/react/components/ui/ShinyButton.d.ts +1 -1
- package/dist/cjs/global-account/react/components/ui/ShinyButton.js +3 -3
- package/dist/cjs/global-account/react/components/ui/TabSystem.js +1 -1
- package/dist/cjs/global-account/react/components/ui/Tabs.d.ts +1 -1
- package/dist/cjs/global-account/react/components/ui/Tabs.js +1 -1
- package/dist/cjs/global-account/react/components/ui/badge.js +4 -4
- package/dist/cjs/global-account/react/components/ui/button.js +5 -5
- package/dist/cjs/global-account/react/components/ui/command.d.ts +1 -1
- package/dist/cjs/global-account/react/components/ui/dialog.d.ts +1 -1
- package/dist/cjs/global-account/react/components/ui/drawer.d.ts +1 -1
- package/dist/cjs/global-account/react/components/ui/glare-card-rounded.js +12 -12
- package/dist/cjs/global-account/react/components/ui/glare-card.js +11 -11
- package/dist/cjs/global-account/react/components/ui/input.js +1 -1
- package/dist/cjs/global-account/react/components/ui/text-loop.d.ts +1 -1
- package/dist/cjs/global-account/react/components/ui/text-loop.js +2 -2
- package/dist/cjs/global-account/react/components/ui/text-shimmer.js +2 -2
- package/dist/cjs/global-account/react/hooks/useAccountAssets.js +4 -4
- package/dist/cjs/global-account/react/hooks/useAccountWallet.js +4 -4
- package/dist/cjs/global-account/react/hooks/useAddTWSessionKey.d.ts +2 -2
- package/dist/cjs/global-account/react/hooks/useAddTWSessionKey.js +6 -6
- package/dist/cjs/global-account/react/hooks/useAuthentication.js +3 -3
- package/dist/cjs/global-account/react/hooks/useB3BalanceFromAddresses.js +7 -7
- package/dist/cjs/global-account/react/hooks/useB3EnsName.js +5 -5
- package/dist/cjs/global-account/react/hooks/useBestTransactionPath.d.ts +1 -1
- package/dist/cjs/global-account/react/hooks/useBestTransactionPath.js +10 -10
- package/dist/cjs/global-account/react/hooks/useBsmntProfile.js +1 -1
- package/dist/cjs/global-account/react/hooks/useChainSwitchWithAction.js +3 -3
- package/dist/cjs/global-account/react/hooks/useClaim.js +4 -4
- package/dist/cjs/global-account/react/hooks/useConnect.js +3 -3
- package/dist/cjs/global-account/react/hooks/useExchangeRate.js +3 -3
- package/dist/cjs/global-account/react/hooks/useGetAllTWSigners.js +7 -7
- package/dist/cjs/global-account/react/hooks/useGetGeo.js +1 -1
- package/dist/cjs/global-account/react/hooks/useHandleConnectWithPrivy.js +2 -2
- package/dist/cjs/global-account/react/hooks/useNativeBalance.js +6 -6
- package/dist/cjs/global-account/react/hooks/useOnchainName.js +10 -10
- package/dist/cjs/global-account/react/hooks/useOneBalance.js +2 -2
- package/dist/cjs/global-account/react/hooks/useRemoveSessionKey.d.ts +1 -1
- package/dist/cjs/global-account/react/hooks/useRemoveSessionKey.js +3 -3
- package/dist/cjs/global-account/react/hooks/useRouter.js +6 -6
- package/dist/cjs/global-account/react/hooks/useSiwe.js +4 -4
- package/dist/cjs/global-account/react/hooks/useTokenBalance.js +6 -6
- package/dist/cjs/global-account/react/hooks/useTokenBalancesByChain.d.ts +1 -1
- package/dist/cjs/global-account/react/hooks/useTokenBalancesByChain.js +9 -9
- package/dist/cjs/global-account/react/hooks/useTokenData.js +3 -3
- package/dist/cjs/global-account/react/hooks/useTokenFromUrl.js +10 -10
- package/dist/cjs/global-account/react/hooks/useTokenPrice.d.ts +1 -1
- package/dist/cjs/global-account/react/hooks/useTokenPrice.js +6 -6
- package/dist/cjs/global-account/react/hooks/useTokenPriceWithFallback.d.ts +1 -1
- package/dist/cjs/global-account/react/hooks/useTokenPriceWithFallback.js +7 -7
- package/dist/cjs/global-account/react/hooks/useTokensFromAddress.d.ts +1 -1
- package/dist/cjs/global-account/react/hooks/useTokensFromAddress.js +2 -2
- package/dist/cjs/global-account/react/hooks/useURLParams.js +1 -1
- package/dist/cjs/global-account/react/stores/index.d.ts +1 -1
- package/dist/cjs/global-account/react/stores/useAuthStore.js +3 -3
- package/dist/cjs/global-account/react/stores/useModalStore.js +3 -3
- package/dist/cjs/global-account/server.js +3 -3
- package/dist/cjs/global-account/types/chain-networks.js +8 -8
- package/dist/cjs/global-account/types/feature-flags.js +1 -1
- package/dist/cjs/shared/constants/chains/b3Chain.js +35 -35
- package/dist/cjs/shared/constants/chains/chainPlatformMap.js +1 -1
- package/dist/cjs/shared/constants/chains/supported.js +1 -1
- package/dist/cjs/shared/constants/index.js +1 -1
- package/dist/cjs/shared/thirdweb/initiateClient.js +2 -2
- package/dist/cjs/shared/thirdweb/openapi-ts.config.js +1 -1
- package/dist/cjs/shared/utils/b3Ens.js +4 -4
- package/dist/cjs/shared/utils/chain-transformers.js +9 -9
- package/dist/cjs/shared/utils/fetchBalances.js +4 -4
- package/dist/cjs/shared/utils/insights.js +28 -28
- package/dist/cjs/shared/utils/ipfs.js +1 -1
- package/dist/cjs/shared/utils/number.js +3 -3
- package/dist/cjs/shared/utils/simplehash.js +22 -22
- package/dist/cjs/shared/utils/thirdweb-insights.js +15 -15
- package/dist/esm/anyspend/abis/abi-usdc-base.js +97 -97
- package/dist/esm/anyspend/abis/erc20-staking.js +51 -51
- package/dist/esm/anyspend/constants/index.js +10 -10
- package/dist/esm/anyspend/react/components/AnySpend.d.ts +1 -1
- package/dist/esm/anyspend/react/components/AnySpend.js +22 -22
- package/dist/esm/anyspend/react/components/AnySpendBuySpin.d.ts +1 -1
- package/dist/esm/anyspend/react/components/AnySpendBuySpin.js +33 -33
- package/dist/esm/anyspend/react/components/AnySpendCustom.d.ts +2 -2
- package/dist/esm/anyspend/react/components/AnySpendCustom.js +31 -31
- package/dist/esm/anyspend/react/components/AnySpendNFT.d.ts +1 -1
- package/dist/esm/anyspend/react/components/AnySpendNFT.js +4 -4
- package/dist/esm/anyspend/react/components/AnySpendNFTButton.js +1 -1
- package/dist/esm/anyspend/react/components/AnySpendStakeB3.d.ts +1 -1
- package/dist/esm/anyspend/react/components/AnySpendStakeB3.js +18 -18
- package/dist/esm/anyspend/react/components/AnySpendTournament.js +4 -4
- package/dist/esm/anyspend/react/components/common/ChainTokenIcon.d.ts +1 -1
- package/dist/esm/anyspend/react/components/common/ChainTokenIcon.js +1 -1
- package/dist/esm/anyspend/react/components/common/OrderDetails.js +12 -12
- package/dist/esm/anyspend/react/components/common/OrderToken.d.ts +1 -1
- package/dist/esm/anyspend/react/components/common/OrderToken.js +4 -4
- package/dist/esm/anyspend/react/components/common/OrderTokenAmount.d.ts +1 -1
- package/dist/esm/anyspend/react/components/common/OrderTokenAmount.js +2 -2
- package/dist/esm/anyspend/react/components/common/PanelOnramp.d.ts +1 -1
- package/dist/esm/anyspend/react/components/common/PanelOnramp.js +2 -2
- package/dist/esm/anyspend/react/components/common/PanelOnrampPayment.d.ts +1 -1
- package/dist/esm/anyspend/react/components/common/PanelOnrampPayment.js +8 -8
- package/dist/esm/anyspend/react/components/common/PaymentMethodIcons.js +1 -1
- package/dist/esm/anyspend/react/components/common/PaymentOneClick.js +3 -3
- package/dist/esm/anyspend/react/components/common/PaymentStripeWeb2.js +12 -12
- package/dist/esm/anyspend/react/components/common/TokenBalance.d.ts +1 -1
- package/dist/esm/anyspend/react/components/common/TokenBalance.js +2 -2
- package/dist/esm/anyspend/react/components/index.d.ts +1 -0
- package/dist/esm/anyspend/react/components/index.js +1 -0
- package/dist/esm/anyspend/react/components/modals/EnterRecipientModal.d.ts +1 -1
- package/dist/esm/anyspend/react/components/modals/EnterRecipientModal.js +1 -1
- package/dist/esm/anyspend/react/components/webview/WebviewOnrampPayment.d.ts +1 -1
- package/dist/esm/anyspend/react/components/webview/WebviewOnrampPayment.js +15 -15
- package/dist/esm/anyspend/react/hooks/useAnyspendCreateOnrampOrder.js +6 -6
- package/dist/esm/anyspend/react/hooks/useAnyspendCreateOrder.js +6 -6
- package/dist/esm/anyspend/react/hooks/useAnyspendOrderAndTransactions.d.ts +10 -0
- package/dist/esm/anyspend/react/hooks/useAnyspendOrderAndTransactions.js +2 -2
- package/dist/esm/anyspend/react/hooks/useAnyspendOrderHistory.d.ts +10 -0
- package/dist/esm/anyspend/react/hooks/useAnyspendOrderHistory.js +3 -3
- package/dist/esm/anyspend/react/hooks/useAnyspendQuote.js +2 -2
- package/dist/esm/anyspend/react/hooks/useAnyspendSendPermitData.js +3 -3
- package/dist/esm/anyspend/react/hooks/useAnyspendTokens.js +3 -3
- package/dist/esm/anyspend/react/hooks/useCoinbaseOnrampOptions.js +2 -2
- package/dist/esm/anyspend/react/hooks/useGeoOnrampOptions.js +2 -2
- package/dist/esm/anyspend/react/hooks/useGetGeo.js +1 -1
- package/dist/esm/anyspend/react/hooks/usePermitData.js +19 -19
- package/dist/esm/anyspend/react/hooks/useStripeClientSecret.js +2 -2
- package/dist/esm/anyspend/react/hooks/useStripeSupport.js +2 -2
- package/dist/esm/anyspend/react/providers/AnyspendProvider.js +3 -3
- package/dist/esm/anyspend/services/anyspend.d.ts +6 -1
- package/dist/esm/anyspend/services/anyspend.js +14 -14
- package/dist/esm/anyspend/types/custom.js +2 -2
- package/dist/esm/anyspend/types/globalWallet.js +1 -1
- package/dist/esm/anyspend/types/nft.js +6 -6
- package/dist/esm/anyspend/types/onramp.d.ts +3 -0
- package/dist/esm/anyspend/types/onramp.js +2 -1
- package/dist/esm/anyspend/types/order.d.ts +30 -0
- package/dist/esm/anyspend/types/order.js +7 -7
- package/dist/esm/anyspend/types/permit.js +1 -1
- package/dist/esm/anyspend/types/req-res/createOrder.d.ts +70 -0
- package/dist/esm/anyspend/types/req-res/createOrder.js +9 -9
- package/dist/esm/anyspend/types/req-res/getCoinbaseOnrampOptions.js +5 -5
- package/dist/esm/anyspend/types/req-res/getOrderAndTransactions.d.ts +45 -0
- package/dist/esm/anyspend/types/req-res/getOrderAndTransactions.js +4 -4
- package/dist/esm/anyspend/types/req-res/getOrderByCreator.js +2 -2
- package/dist/esm/anyspend/types/req-res/getOrderHistory.d.ts +35 -0
- package/dist/esm/anyspend/types/req-res/getOrderHistory.js +1 -1
- package/dist/esm/anyspend/types/req-res/getQuote.d.ts +26 -0
- package/dist/esm/anyspend/types/req-res/getQuote.js +10 -8
- package/dist/esm/anyspend/types/req-res/getTokenList.js +3 -3
- package/dist/esm/anyspend/types/req-res/sendPermitData.js +2 -2
- package/dist/esm/anyspend/types/swap.js +2 -2
- package/dist/esm/anyspend/types/token.js +2 -2
- package/dist/esm/anyspend/types/tournament.js +4 -4
- package/dist/esm/anyspend/types/transaction.js +4 -4
- package/dist/esm/anyspend/utils/chain.js +18 -18
- package/dist/esm/anyspend/utils/format.js +2 -2
- package/dist/esm/anyspend/utils/orderPayload.js +6 -6
- package/dist/esm/anyspend/utils/token.js +10 -10
- package/dist/esm/global-account/app.js +4 -4
- package/dist/esm/global-account/app.native.js +4 -4
- package/dist/esm/global-account/bsmnt.js +4 -4
- package/dist/esm/global-account/bsmnt.native.js +4 -4
- package/dist/esm/global-account/react/components/B3DynamicModal.js +2 -2
- package/dist/esm/global-account/react/components/B3Provider/B3Provider.d.ts +2 -2
- package/dist/esm/global-account/react/components/B3Provider/B3Provider.js +5 -5
- package/dist/esm/global-account/react/components/B3Provider/B3Provider.native.d.ts +2 -2
- package/dist/esm/global-account/react/components/B3Provider/B3Provider.native.js +4 -4
- package/dist/esm/global-account/react/components/B3Provider/types.js +1 -1
- package/dist/esm/global-account/react/components/ManageAccount/ManageAccount.d.ts +1 -1
- package/dist/esm/global-account/react/components/ManageAccount/ManageAccount.js +6 -6
- package/dist/esm/global-account/react/components/MintButton/MintButton.d.ts +1 -1
- package/dist/esm/global-account/react/components/MintButton/MintButton.js +5 -5
- package/dist/esm/global-account/react/components/RelayKitProviderWrapper.js +2 -2
- package/dist/esm/global-account/react/components/RequestPermissions/RequestPermissions.d.ts +1 -1
- package/dist/esm/global-account/react/components/RequestPermissions/RequestPermissions.js +6 -6
- package/dist/esm/global-account/react/components/RequestPermissions/RequestPermissionsButton.d.ts +1 -1
- package/dist/esm/global-account/react/components/RequestPermissions/RequestPermissionsButton.js +2 -2
- package/dist/esm/global-account/react/components/SignInWithB3/SignIn.js +2 -2
- package/dist/esm/global-account/react/components/SignInWithB3/SignInWithB3.js +2 -2
- package/dist/esm/global-account/react/components/SignInWithB3/SignInWithB3Flow.d.ts +1 -1
- package/dist/esm/global-account/react/components/SignInWithB3/SignInWithB3Flow.js +13 -13
- package/dist/esm/global-account/react/components/SignInWithB3/SignInWithB3Privy.js +2 -2
- package/dist/esm/global-account/react/components/SignInWithB3/components/AuthButton.d.ts +1 -1
- package/dist/esm/global-account/react/components/SignInWithB3/components/AuthButton.js +1 -1
- package/dist/esm/global-account/react/components/SignInWithB3/components/WalletRow.d.ts +1 -1
- package/dist/esm/global-account/react/components/SignInWithB3/components/WalletRow.js +1 -1
- package/dist/esm/global-account/react/components/SignInWithB3/steps/LoginStep.js +9 -9
- package/dist/esm/global-account/react/components/SignInWithB3/steps/LoginStepCustom.d.ts +1 -1
- package/dist/esm/global-account/react/components/SignInWithB3/steps/LoginStepCustom.js +3 -3
- package/dist/esm/global-account/react/components/SignInWithB3/utils/signInUtils.js +2 -2
- package/dist/esm/global-account/react/components/Transak/TransakModal.js +4 -4
- package/dist/esm/global-account/react/components/custom/Button.js +5 -5
- package/dist/esm/global-account/react/components/custom/Icon.js +1 -1
- package/dist/esm/global-account/react/components/custom/ManageAccountButton.js +1 -1
- package/dist/esm/global-account/react/components/custom/StaggeredFadeLoader.js +3 -3
- package/dist/esm/global-account/react/components/custom/WalletConnectorIcon.js +1 -1
- package/dist/esm/global-account/react/components/index.d.ts +4 -4
- package/dist/esm/global-account/react/components/index.js +4 -4
- package/dist/esm/global-account/react/components/magicui/AnimatedLottie.js +1 -1
- package/dist/esm/global-account/react/components/ui/Loading.js +2 -2
- package/dist/esm/global-account/react/components/ui/ShinyButton.d.ts +1 -1
- package/dist/esm/global-account/react/components/ui/ShinyButton.js +3 -3
- package/dist/esm/global-account/react/components/ui/TabSystem.js +1 -1
- package/dist/esm/global-account/react/components/ui/Tabs.d.ts +1 -1
- package/dist/esm/global-account/react/components/ui/Tabs.js +1 -1
- package/dist/esm/global-account/react/components/ui/badge.js +4 -4
- package/dist/esm/global-account/react/components/ui/button.js +5 -5
- package/dist/esm/global-account/react/components/ui/command.d.ts +1 -1
- package/dist/esm/global-account/react/components/ui/command.js +1 -1
- package/dist/esm/global-account/react/components/ui/dialog.d.ts +1 -1
- package/dist/esm/global-account/react/components/ui/dialog.js +1 -1
- package/dist/esm/global-account/react/components/ui/drawer.d.ts +1 -1
- package/dist/esm/global-account/react/components/ui/drawer.js +1 -1
- package/dist/esm/global-account/react/components/ui/glare-card-rounded.js +12 -12
- package/dist/esm/global-account/react/components/ui/glare-card.js +11 -11
- package/dist/esm/global-account/react/components/ui/input.js +1 -1
- package/dist/esm/global-account/react/components/ui/text-loop.d.ts +1 -1
- package/dist/esm/global-account/react/components/ui/text-loop.js +2 -2
- package/dist/esm/global-account/react/components/ui/text-shimmer.js +2 -2
- package/dist/esm/global-account/react/hooks/useAccountAssets.js +4 -4
- package/dist/esm/global-account/react/hooks/useAccountWallet.js +4 -4
- package/dist/esm/global-account/react/hooks/useAddTWSessionKey.d.ts +2 -2
- package/dist/esm/global-account/react/hooks/useAddTWSessionKey.js +6 -6
- package/dist/esm/global-account/react/hooks/useAuthentication.js +3 -3
- package/dist/esm/global-account/react/hooks/useB3BalanceFromAddresses.js +7 -7
- package/dist/esm/global-account/react/hooks/useB3EnsName.js +5 -5
- package/dist/esm/global-account/react/hooks/useBestTransactionPath.d.ts +1 -1
- package/dist/esm/global-account/react/hooks/useBestTransactionPath.js +10 -10
- package/dist/esm/global-account/react/hooks/useBsmntProfile.js +1 -1
- package/dist/esm/global-account/react/hooks/useChainSwitchWithAction.js +3 -3
- package/dist/esm/global-account/react/hooks/useClaim.js +4 -4
- package/dist/esm/global-account/react/hooks/useConnect.js +3 -3
- package/dist/esm/global-account/react/hooks/useExchangeRate.js +3 -3
- package/dist/esm/global-account/react/hooks/useGetAllTWSigners.js +7 -7
- package/dist/esm/global-account/react/hooks/useGetGeo.js +1 -1
- package/dist/esm/global-account/react/hooks/useHandleConnectWithPrivy.js +2 -2
- package/dist/esm/global-account/react/hooks/useNativeBalance.js +6 -6
- package/dist/esm/global-account/react/hooks/useOnchainName.js +10 -10
- package/dist/esm/global-account/react/hooks/useOneBalance.js +2 -2
- package/dist/esm/global-account/react/hooks/useRemoveSessionKey.d.ts +1 -1
- package/dist/esm/global-account/react/hooks/useRemoveSessionKey.js +3 -3
- package/dist/esm/global-account/react/hooks/useRouter.js +6 -6
- package/dist/esm/global-account/react/hooks/useSiwe.js +4 -4
- package/dist/esm/global-account/react/hooks/useTokenBalance.js +6 -6
- package/dist/esm/global-account/react/hooks/useTokenBalancesByChain.d.ts +1 -1
- package/dist/esm/global-account/react/hooks/useTokenBalancesByChain.js +9 -9
- package/dist/esm/global-account/react/hooks/useTokenData.js +3 -3
- package/dist/esm/global-account/react/hooks/useTokenFromUrl.js +10 -10
- package/dist/esm/global-account/react/hooks/useTokenPrice.d.ts +1 -1
- package/dist/esm/global-account/react/hooks/useTokenPrice.js +6 -6
- package/dist/esm/global-account/react/hooks/useTokenPriceWithFallback.d.ts +1 -1
- package/dist/esm/global-account/react/hooks/useTokenPriceWithFallback.js +7 -7
- package/dist/esm/global-account/react/hooks/useTokensFromAddress.d.ts +1 -1
- package/dist/esm/global-account/react/hooks/useTokensFromAddress.js +2 -2
- package/dist/esm/global-account/react/hooks/useURLParams.js +1 -1
- package/dist/esm/global-account/react/stores/index.d.ts +1 -1
- package/dist/esm/global-account/react/stores/useAuthStore.js +3 -3
- package/dist/esm/global-account/react/stores/useModalStore.js +3 -3
- package/dist/esm/global-account/server.js +3 -3
- package/dist/esm/global-account/types/chain-networks.js +8 -8
- package/dist/esm/global-account/types/feature-flags.js +1 -1
- package/dist/esm/shared/constants/chains/b3Chain.js +35 -35
- package/dist/esm/shared/constants/chains/chainPlatformMap.js +1 -1
- package/dist/esm/shared/constants/chains/supported.js +1 -1
- package/dist/esm/shared/constants/index.js +1 -1
- package/dist/esm/shared/thirdweb/initiateClient.js +2 -2
- package/dist/esm/shared/thirdweb/openapi-ts.config.js +1 -1
- package/dist/esm/shared/utils/b3Ens.js +4 -4
- package/dist/esm/shared/utils/chain-transformers.js +9 -9
- package/dist/esm/shared/utils/fetchBalances.js +4 -4
- package/dist/esm/shared/utils/insights.js +28 -28
- package/dist/esm/shared/utils/ipfs.js +1 -1
- package/dist/esm/shared/utils/number.js +3 -3
- package/dist/esm/shared/utils/simplehash.js +23 -23
- package/dist/esm/shared/utils/thirdweb-insights.js +15 -15
- package/dist/types/anyspend/react/components/AnySpend.d.ts +1 -1
- package/dist/types/anyspend/react/components/AnySpendBuySpin.d.ts +1 -1
- package/dist/types/anyspend/react/components/AnySpendCustom.d.ts +2 -2
- package/dist/types/anyspend/react/components/AnySpendNFT.d.ts +1 -1
- package/dist/types/anyspend/react/components/AnySpendStakeB3.d.ts +1 -1
- package/dist/types/anyspend/react/components/common/ChainTokenIcon.d.ts +1 -1
- package/dist/types/anyspend/react/components/common/OrderToken.d.ts +1 -1
- package/dist/types/anyspend/react/components/common/OrderTokenAmount.d.ts +1 -1
- package/dist/types/anyspend/react/components/common/PanelOnramp.d.ts +1 -1
- package/dist/types/anyspend/react/components/common/PanelOnrampPayment.d.ts +1 -1
- package/dist/types/anyspend/react/components/common/TokenBalance.d.ts +1 -1
- package/dist/types/anyspend/react/components/index.d.ts +1 -0
- package/dist/types/anyspend/react/components/modals/EnterRecipientModal.d.ts +1 -1
- package/dist/types/anyspend/react/components/webview/WebviewOnrampPayment.d.ts +1 -1
- package/dist/types/anyspend/react/hooks/useAnyspendOrderAndTransactions.d.ts +10 -0
- package/dist/types/anyspend/react/hooks/useAnyspendOrderHistory.d.ts +10 -0
- package/dist/types/anyspend/services/anyspend.d.ts +6 -1
- package/dist/types/anyspend/types/onramp.d.ts +3 -0
- package/dist/types/anyspend/types/order.d.ts +30 -0
- package/dist/types/anyspend/types/req-res/createOrder.d.ts +70 -0
- package/dist/types/anyspend/types/req-res/getOrderAndTransactions.d.ts +45 -0
- package/dist/types/anyspend/types/req-res/getOrderHistory.d.ts +35 -0
- package/dist/types/anyspend/types/req-res/getQuote.d.ts +26 -0
- package/dist/types/global-account/react/components/B3Provider/B3Provider.d.ts +2 -2
- package/dist/types/global-account/react/components/B3Provider/B3Provider.native.d.ts +2 -2
- package/dist/types/global-account/react/components/ManageAccount/ManageAccount.d.ts +1 -1
- package/dist/types/global-account/react/components/MintButton/MintButton.d.ts +1 -1
- package/dist/types/global-account/react/components/RequestPermissions/RequestPermissions.d.ts +1 -1
- package/dist/types/global-account/react/components/RequestPermissions/RequestPermissionsButton.d.ts +1 -1
- package/dist/types/global-account/react/components/SignInWithB3/SignInWithB3Flow.d.ts +1 -1
- package/dist/types/global-account/react/components/SignInWithB3/components/AuthButton.d.ts +1 -1
- package/dist/types/global-account/react/components/SignInWithB3/components/WalletRow.d.ts +1 -1
- package/dist/types/global-account/react/components/SignInWithB3/steps/LoginStepCustom.d.ts +1 -1
- package/dist/types/global-account/react/components/index.d.ts +4 -4
- package/dist/types/global-account/react/components/ui/ShinyButton.d.ts +1 -1
- package/dist/types/global-account/react/components/ui/Tabs.d.ts +1 -1
- package/dist/types/global-account/react/components/ui/command.d.ts +1 -1
- package/dist/types/global-account/react/components/ui/dialog.d.ts +1 -1
- package/dist/types/global-account/react/components/ui/drawer.d.ts +1 -1
- package/dist/types/global-account/react/components/ui/text-loop.d.ts +1 -1
- package/dist/types/global-account/react/hooks/useAddTWSessionKey.d.ts +2 -2
- package/dist/types/global-account/react/hooks/useBestTransactionPath.d.ts +1 -1
- package/dist/types/global-account/react/hooks/useRemoveSessionKey.d.ts +1 -1
- package/dist/types/global-account/react/hooks/useTokenBalancesByChain.d.ts +1 -1
- package/dist/types/global-account/react/hooks/useTokenPrice.d.ts +1 -1
- package/dist/types/global-account/react/hooks/useTokenPriceWithFallback.d.ts +1 -1
- package/dist/types/global-account/react/hooks/useTokensFromAddress.d.ts +1 -1
- package/dist/types/global-account/react/stores/index.d.ts +1 -1
- package/package.json +1 -1
- package/src/anyspend/abis/abi-usdc-base.ts +97 -97
- package/src/anyspend/abis/erc20-staking.ts +51 -51
- package/src/anyspend/constants/index.ts +10 -10
- package/src/anyspend/react/components/AnySpend.tsx +33 -32
- package/src/anyspend/react/components/AnySpendBuySpin.tsx +34 -34
- package/src/anyspend/react/components/AnySpendCustom.tsx +39 -39
- package/src/anyspend/react/components/AnySpendNFT.tsx +4 -4
- package/src/anyspend/react/components/AnySpendNFTButton.tsx +1 -1
- package/src/anyspend/react/components/AnySpendStakeB3.tsx +18 -18
- package/src/anyspend/react/components/AnySpendTournament.tsx +4 -4
- package/src/anyspend/react/components/common/ChainTokenIcon.tsx +1 -1
- package/src/anyspend/react/components/common/OrderDetails.tsx +15 -15
- package/src/anyspend/react/components/common/OrderHistoryItem.tsx +3 -3
- package/src/anyspend/react/components/common/OrderToken.tsx +5 -5
- package/src/anyspend/react/components/common/OrderTokenAmount.tsx +4 -4
- package/src/anyspend/react/components/common/PanelOnramp.tsx +3 -3
- package/src/anyspend/react/components/common/PanelOnrampPayment.tsx +8 -8
- package/src/anyspend/react/components/common/PaymentMethodIcons.tsx +1 -1
- package/src/anyspend/react/components/common/PaymentOneClick.tsx +3 -3
- package/src/anyspend/react/components/common/PaymentStripeWeb2.tsx +14 -14
- package/src/anyspend/react/components/common/TokenBalance.tsx +2 -2
- package/src/anyspend/react/components/index.ts +1 -0
- package/src/anyspend/react/components/modals/EnterRecipientModal.tsx +1 -1
- package/src/anyspend/react/components/webview/WebviewOnrampPayment.tsx +18 -18
- package/src/anyspend/react/hooks/useAnyspendCreateOnrampOrder.ts +7 -7
- package/src/anyspend/react/hooks/useAnyspendCreateOrder.ts +7 -7
- package/src/anyspend/react/hooks/useAnyspendOrderAndTransactions.ts +3 -3
- package/src/anyspend/react/hooks/useAnyspendOrderHistory.ts +4 -4
- package/src/anyspend/react/hooks/useAnyspendQuote.ts +5 -5
- package/src/anyspend/react/hooks/useAnyspendSendPermitData.ts +3 -3
- package/src/anyspend/react/hooks/useAnyspendTokens.ts +4 -4
- package/src/anyspend/react/hooks/useCoinbaseOnrampOptions.ts +3 -3
- package/src/anyspend/react/hooks/useGeoOnrampOptions.ts +3 -3
- package/src/anyspend/react/hooks/useGetGeo.ts +1 -1
- package/src/anyspend/react/hooks/usePermitData.ts +19 -19
- package/src/anyspend/react/hooks/useStripeClientSecret.ts +3 -3
- package/src/anyspend/react/hooks/useStripeSupport.ts +3 -3
- package/src/anyspend/react/providers/AnyspendProvider.tsx +3 -3
- package/src/anyspend/services/anyspend.ts +23 -23
- package/src/anyspend/types/chain.ts +1 -1
- package/src/anyspend/types/custom.ts +2 -2
- package/src/anyspend/types/globalWallet.ts +1 -1
- package/src/anyspend/types/nft.ts +7 -7
- package/src/anyspend/types/onramp.ts +3 -2
- package/src/anyspend/types/order.ts +9 -9
- package/src/anyspend/types/permit.ts +1 -1
- package/src/anyspend/types/relay.ts +1 -1
- package/src/anyspend/types/req-res/createOrder.ts +9 -9
- package/src/anyspend/types/req-res/getCoinbaseOnrampOptions.ts +5 -5
- package/src/anyspend/types/req-res/getOrderAndTransactions.ts +4 -4
- package/src/anyspend/types/req-res/getOrderByCreator.ts +2 -2
- package/src/anyspend/types/req-res/getOrderHistory.ts +1 -1
- package/src/anyspend/types/req-res/getQuote.ts +10 -8
- package/src/anyspend/types/req-res/getTokenList.ts +4 -4
- package/src/anyspend/types/req-res/sendPermitData.ts +2 -2
- package/src/anyspend/types/swap.ts +2 -2
- package/src/anyspend/types/token.ts +2 -2
- package/src/anyspend/types/tournament.ts +4 -4
- package/src/anyspend/types/transaction.ts +4 -4
- package/src/anyspend/utils/chain.ts +25 -25
- package/src/anyspend/utils/format.ts +2 -2
- package/src/anyspend/utils/orderPayload.ts +6 -6
- package/src/anyspend/utils/token.ts +10 -10
- package/src/global-account/app.native.ts +5 -5
- package/src/global-account/app.ts +5 -5
- package/src/global-account/bsmnt.native.ts +5 -5
- package/src/global-account/bsmnt.ts +5 -5
- package/src/global-account/react/components/B3DynamicModal.tsx +3 -3
- package/src/global-account/react/components/B3Provider/B3Provider.native.tsx +4 -4
- package/src/global-account/react/components/B3Provider/B3Provider.tsx +5 -5
- package/src/global-account/react/components/B3Provider/types.ts +1 -1
- package/src/global-account/react/components/ManageAccount/ManageAccount.tsx +6 -6
- package/src/global-account/react/components/MintButton/MintButton.tsx +5 -5
- package/src/global-account/react/components/RelayKitProviderWrapper.tsx +2 -2
- package/src/global-account/react/components/RequestPermissions/RequestPermissions.tsx +7 -7
- package/src/global-account/react/components/RequestPermissions/RequestPermissionsButton.tsx +2 -2
- package/src/global-account/react/components/SignInWithB3/SignIn.tsx +4 -4
- package/src/global-account/react/components/SignInWithB3/SignInWithB3.tsx +2 -2
- package/src/global-account/react/components/SignInWithB3/SignInWithB3Flow.tsx +14 -14
- package/src/global-account/react/components/SignInWithB3/SignInWithB3Privy.tsx +2 -2
- package/src/global-account/react/components/SignInWithB3/components/AuthButton.tsx +1 -1
- package/src/global-account/react/components/SignInWithB3/components/WalletRow.tsx +1 -1
- package/src/global-account/react/components/SignInWithB3/steps/LoginStep.tsx +10 -10
- package/src/global-account/react/components/SignInWithB3/steps/LoginStepCustom.tsx +3 -3
- package/src/global-account/react/components/SignInWithB3/utils/signInUtils.ts +2 -2
- package/src/global-account/react/components/Transak/TransakModal.tsx +4 -4
- package/src/global-account/react/components/custom/Button.tsx +7 -7
- package/src/global-account/react/components/custom/Icon.tsx +1 -1
- package/src/global-account/react/components/custom/ManageAccountButton.tsx +1 -1
- package/src/global-account/react/components/custom/StaggeredFadeLoader.tsx +3 -3
- package/src/global-account/react/components/custom/WalletConnectorIcon.tsx +1 -1
- package/src/global-account/react/components/index.ts +4 -4
- package/src/global-account/react/components/magicui/AnimatedLottie.tsx +5 -5
- package/src/global-account/react/components/ui/Loading.tsx +2 -2
- package/src/global-account/react/components/ui/ShinyButton.tsx +5 -5
- package/src/global-account/react/components/ui/TabSystem.tsx +2 -2
- package/src/global-account/react/components/ui/Tabs.tsx +4 -4
- package/src/global-account/react/components/ui/badge.tsx +5 -5
- package/src/global-account/react/components/ui/button.tsx +7 -7
- package/src/global-account/react/components/ui/command.tsx +5 -5
- package/src/global-account/react/components/ui/dialog.tsx +5 -5
- package/src/global-account/react/components/ui/drawer.tsx +2 -2
- package/src/global-account/react/components/ui/glare-card-rounded.tsx +12 -12
- package/src/global-account/react/components/ui/glare-card.tsx +11 -11
- package/src/global-account/react/components/ui/input.tsx +2 -2
- package/src/global-account/react/components/ui/popover.tsx +1 -1
- package/src/global-account/react/components/ui/scroll-area.tsx +1 -1
- package/src/global-account/react/components/ui/text-loop.tsx +2 -2
- package/src/global-account/react/components/ui/text-shimmer.tsx +3 -3
- package/src/global-account/react/components/ui/tooltip.tsx +1 -1
- package/src/global-account/react/hooks/useAccountAssets.ts +4 -4
- package/src/global-account/react/hooks/useAccountWallet.tsx +5 -5
- package/src/global-account/react/hooks/useAddTWSessionKey.tsx +7 -7
- package/src/global-account/react/hooks/useAuthentication.ts +3 -3
- package/src/global-account/react/hooks/useB3BalanceFromAddresses.ts +9 -9
- package/src/global-account/react/hooks/useB3EnsName.ts +6 -6
- package/src/global-account/react/hooks/useBestTransactionPath.tsx +11 -11
- package/src/global-account/react/hooks/useBsmntProfile.ts +1 -1
- package/src/global-account/react/hooks/useChainSwitchWithAction.ts +4 -4
- package/src/global-account/react/hooks/useClaim.tsx +5 -5
- package/src/global-account/react/hooks/useConnect.tsx +4 -4
- package/src/global-account/react/hooks/useExchangeRate.tsx +3 -3
- package/src/global-account/react/hooks/useGetAllTWSigners.tsx +9 -9
- package/src/global-account/react/hooks/useGetGeo.tsx +1 -1
- package/src/global-account/react/hooks/useHandleConnectWithPrivy.tsx +2 -2
- package/src/global-account/react/hooks/useMediaQuery.tsx +1 -1
- package/src/global-account/react/hooks/useNativeBalance.tsx +7 -7
- package/src/global-account/react/hooks/useOnchainName.tsx +11 -11
- package/src/global-account/react/hooks/useOneBalance.tsx +2 -2
- package/src/global-account/react/hooks/useQueryB3.ts +2 -2
- package/src/global-account/react/hooks/useQueryBSMNT.ts +2 -2
- package/src/global-account/react/hooks/useRemoveSessionKey.tsx +5 -5
- package/src/global-account/react/hooks/useRouter.tsx +6 -6
- package/src/global-account/react/hooks/useSiwe.tsx +4 -4
- package/src/global-account/react/hooks/useTokenBalance.tsx +6 -6
- package/src/global-account/react/hooks/useTokenBalancesByChain.tsx +10 -10
- package/src/global-account/react/hooks/useTokenData.ts +3 -3
- package/src/global-account/react/hooks/useTokenFromUrl.tsx +11 -11
- package/src/global-account/react/hooks/useTokenPrice.tsx +7 -7
- package/src/global-account/react/hooks/useTokenPriceWithFallback.tsx +7 -7
- package/src/global-account/react/hooks/useTokensFromAddress.ts +2 -2
- package/src/global-account/react/hooks/useURLParams.ts +2 -2
- package/src/global-account/react/stores/index.ts +1 -1
- package/src/global-account/react/stores/useAuthStore.ts +3 -3
- package/src/global-account/react/stores/useModalStore.ts +3 -3
- package/src/global-account/server.ts +3 -3
- package/src/global-account/types/chain-networks.ts +10 -10
- package/src/global-account/types/feature-flags.ts +2 -2
- package/src/shared/constants/chains/b3Chain.ts +35 -35
- package/src/shared/constants/chains/chainPlatformMap.ts +1 -1
- package/src/shared/constants/chains/supported.ts +1 -1
- package/src/shared/constants/index.ts +1 -1
- package/src/shared/thirdweb/initiateClient.ts +2 -2
- package/src/shared/thirdweb/openapi-ts.config.ts +1 -1
- package/src/shared/utils/b3Ens.ts +4 -4
- package/src/shared/utils/chain-transformers.ts +9 -9
- package/src/shared/utils/fetchBalances.ts +5 -5
- package/src/shared/utils/fetchBsmntProfile.ts +1 -1
- package/src/shared/utils/insights.ts +31 -31
- package/src/shared/utils/ipfs.ts +1 -1
- package/src/shared/utils/number.ts +5 -5
- package/src/shared/utils/simplehash.ts +28 -28
- package/src/shared/utils/thirdweb-insights.ts +20 -20
|
@@ -7,7 +7,7 @@ export const useB3EnsName = () => {
|
|
|
7
7
|
const response = await fetch(ENS_GATEWAY_URL + "set", {
|
|
8
8
|
method: "POST",
|
|
9
9
|
headers: {
|
|
10
|
-
"Content-Type": "application/json"
|
|
10
|
+
"Content-Type": "application/json",
|
|
11
11
|
},
|
|
12
12
|
body: JSON.stringify({
|
|
13
13
|
name: name,
|
|
@@ -15,9 +15,9 @@ export const useB3EnsName = () => {
|
|
|
15
15
|
addresses: { "60": address.toLowerCase() },
|
|
16
16
|
signature: {
|
|
17
17
|
message: message,
|
|
18
|
-
hash: hash
|
|
19
|
-
}
|
|
20
|
-
})
|
|
18
|
+
hash: hash,
|
|
19
|
+
},
|
|
20
|
+
}),
|
|
21
21
|
});
|
|
22
22
|
return response;
|
|
23
23
|
};
|
|
@@ -36,8 +36,8 @@ export const useB3EnsName = () => {
|
|
|
36
36
|
return useMemo(
|
|
37
37
|
() => ({
|
|
38
38
|
registerEns,
|
|
39
|
-
getEns
|
|
39
|
+
getEns,
|
|
40
40
|
}),
|
|
41
|
-
[]
|
|
41
|
+
[],
|
|
42
42
|
);
|
|
43
43
|
};
|
|
@@ -54,13 +54,13 @@ export function useBestTransactionPath({
|
|
|
54
54
|
amount,
|
|
55
55
|
token,
|
|
56
56
|
address,
|
|
57
|
-
transactionType: _transactionType = "send"
|
|
57
|
+
transactionType: _transactionType = "send",
|
|
58
58
|
}: UseBestTransactionPathProps): TransactionPathResult {
|
|
59
59
|
const account = useAccountWallet();
|
|
60
60
|
const effectiveAddress = address || account?.address;
|
|
61
61
|
|
|
62
62
|
const isSupportedSprinterToken = supportedSprinterTokenSymbols.includes(
|
|
63
|
-
token.symbol.toUpperCase() as (typeof supportedSprinterTokenSymbols)[number]
|
|
63
|
+
token.symbol.toUpperCase() as (typeof supportedSprinterTokenSymbols)[number],
|
|
64
64
|
);
|
|
65
65
|
|
|
66
66
|
// Get balances across all chains
|
|
@@ -69,7 +69,7 @@ export function useBestTransactionPath({
|
|
|
69
69
|
// Get the token balance using our new hook
|
|
70
70
|
const { rawBalance, isLoading: tokenBalanceLoading } = useTokenBalance({
|
|
71
71
|
token,
|
|
72
|
-
address: effectiveAddress
|
|
72
|
+
address: effectiveAddress,
|
|
73
73
|
});
|
|
74
74
|
|
|
75
75
|
// Check if amount is available natively on destination chain
|
|
@@ -104,7 +104,7 @@ export function useBestTransactionPath({
|
|
|
104
104
|
isSupportedSprinterToken,
|
|
105
105
|
oneBalanceLoading,
|
|
106
106
|
aggregatedBalances,
|
|
107
|
-
rawBalance
|
|
107
|
+
rawBalance,
|
|
108
108
|
]);
|
|
109
109
|
|
|
110
110
|
const totalCrossChainBalance = useMemo(() => {
|
|
@@ -132,14 +132,14 @@ export function useBestTransactionPath({
|
|
|
132
132
|
options.push({
|
|
133
133
|
chainId: chainBalance.chainId,
|
|
134
134
|
balance: balanceBi,
|
|
135
|
-
formattedBalance: formatUnits(balanceBi, chainBalance.tokenDecimals)
|
|
135
|
+
formattedBalance: formatUnits(balanceBi, chainBalance.tokenDecimals),
|
|
136
136
|
});
|
|
137
137
|
}
|
|
138
138
|
}
|
|
139
139
|
|
|
140
140
|
return {
|
|
141
141
|
hasSprinterPath: options.length > 0,
|
|
142
|
-
sprinterOptions: options
|
|
142
|
+
sprinterOptions: options,
|
|
143
143
|
};
|
|
144
144
|
}, [isSupportedSprinterToken, oneBalanceLoading, aggregatedBalances, token.symbol, token.chainId, amount]);
|
|
145
145
|
|
|
@@ -155,7 +155,7 @@ export function useBestTransactionPath({
|
|
|
155
155
|
hasSprinterPath,
|
|
156
156
|
availableBalance,
|
|
157
157
|
totalCrossChainBalance,
|
|
158
|
-
sprinterOptions
|
|
158
|
+
sprinterOptions,
|
|
159
159
|
};
|
|
160
160
|
}
|
|
161
161
|
|
|
@@ -167,7 +167,7 @@ export function useBestTransactionPath({
|
|
|
167
167
|
hasSprinterPath: true,
|
|
168
168
|
availableBalance,
|
|
169
169
|
totalCrossChainBalance,
|
|
170
|
-
sprinterOptions
|
|
170
|
+
sprinterOptions,
|
|
171
171
|
};
|
|
172
172
|
}
|
|
173
173
|
|
|
@@ -178,7 +178,7 @@ export function useBestTransactionPath({
|
|
|
178
178
|
hasSprinterPath: false,
|
|
179
179
|
availableBalance,
|
|
180
180
|
totalCrossChainBalance,
|
|
181
|
-
sprinterOptions: []
|
|
181
|
+
sprinterOptions: [],
|
|
182
182
|
};
|
|
183
183
|
}, [
|
|
184
184
|
token.address,
|
|
@@ -187,7 +187,7 @@ export function useBestTransactionPath({
|
|
|
187
187
|
hasNativeBalance,
|
|
188
188
|
hasSprinterPath,
|
|
189
189
|
totalCrossChainBalance,
|
|
190
|
-
sprinterOptions
|
|
190
|
+
sprinterOptions,
|
|
191
191
|
]);
|
|
192
192
|
|
|
193
193
|
// Combine all loading states
|
|
@@ -195,6 +195,6 @@ export function useBestTransactionPath({
|
|
|
195
195
|
|
|
196
196
|
return {
|
|
197
197
|
...path,
|
|
198
|
-
loading
|
|
198
|
+
loading,
|
|
199
199
|
};
|
|
200
200
|
}
|
|
@@ -57,9 +57,9 @@ export function useChainSwitchWithAction() {
|
|
|
57
57
|
nativeCurrency: {
|
|
58
58
|
name: nativeCurrency.name,
|
|
59
59
|
symbol: nativeCurrency.symbol,
|
|
60
|
-
decimals: nativeCurrency.decimals
|
|
61
|
-
}
|
|
62
|
-
}
|
|
60
|
+
decimals: nativeCurrency.decimals,
|
|
61
|
+
},
|
|
62
|
+
},
|
|
63
63
|
});
|
|
64
64
|
await run(() => action(walletClient));
|
|
65
65
|
} catch (e: any) {
|
|
@@ -72,7 +72,7 @@ export function useChainSwitchWithAction() {
|
|
|
72
72
|
}
|
|
73
73
|
}
|
|
74
74
|
},
|
|
75
|
-
[walletClient, run, switchChainAsync]
|
|
75
|
+
[walletClient, run, switchChainAsync],
|
|
76
76
|
);
|
|
77
77
|
|
|
78
78
|
return { switchChainAndExecute, isSwitchingOrExecuting };
|
|
@@ -27,7 +27,7 @@ export function useClaim({ contractAddress, quantity = 1, chain, to, tokenId }:
|
|
|
27
27
|
const contract = getContract({
|
|
28
28
|
client,
|
|
29
29
|
chain,
|
|
30
|
-
address: contractAddress
|
|
30
|
+
address: contractAddress,
|
|
31
31
|
});
|
|
32
32
|
|
|
33
33
|
// If tokenId is provided, use ERC1155 claim
|
|
@@ -37,17 +37,17 @@ export function useClaim({ contractAddress, quantity = 1, chain, to, tokenId }:
|
|
|
37
37
|
contract,
|
|
38
38
|
to,
|
|
39
39
|
quantity: BigInt(quantity),
|
|
40
|
-
tokenId: BigInt(tokenId)
|
|
40
|
+
tokenId: BigInt(tokenId),
|
|
41
41
|
})
|
|
42
42
|
: claimTo721({
|
|
43
43
|
contract,
|
|
44
44
|
to,
|
|
45
|
-
quantity: BigInt(quantity)
|
|
45
|
+
quantity: BigInt(quantity),
|
|
46
46
|
});
|
|
47
47
|
|
|
48
48
|
const tx = await sendTransaction({
|
|
49
49
|
transaction,
|
|
50
|
-
account
|
|
50
|
+
account,
|
|
51
51
|
});
|
|
52
52
|
|
|
53
53
|
return tx.transactionHash;
|
|
@@ -55,7 +55,7 @@ export function useClaim({ contractAddress, quantity = 1, chain, to, tokenId }:
|
|
|
55
55
|
setIsMinting(false);
|
|
56
56
|
}
|
|
57
57
|
},
|
|
58
|
-
[contractAddress, quantity, chain, to, tokenId]
|
|
58
|
+
[contractAddress, quantity, chain, to, tokenId],
|
|
59
59
|
);
|
|
60
60
|
|
|
61
61
|
return { claim, isMinting };
|
|
@@ -31,19 +31,19 @@ export function useConnect(partnerId: string, chain?: Chain) {
|
|
|
31
31
|
debug("@@useConnect:strategyOptions", {
|
|
32
32
|
partnerId,
|
|
33
33
|
strategyOptions,
|
|
34
|
-
clientId: THIRDWEB_CLIENT_ID
|
|
34
|
+
clientId: THIRDWEB_CLIENT_ID,
|
|
35
35
|
});
|
|
36
36
|
|
|
37
37
|
// Create a wallet for "Allowlist" ecosystems restricted to partners
|
|
38
38
|
const wallet = ecosystemWallet(ecosystemWalletId, {
|
|
39
|
-
partnerId: partnerId
|
|
39
|
+
partnerId: partnerId,
|
|
40
40
|
});
|
|
41
41
|
|
|
42
42
|
const connect = await wallet.connect({
|
|
43
43
|
client,
|
|
44
44
|
chain,
|
|
45
45
|
// This is the payload that is sent to the auth endpoint
|
|
46
|
-
...strategyOptions
|
|
46
|
+
...strategyOptions,
|
|
47
47
|
});
|
|
48
48
|
|
|
49
49
|
debug("@@useConnect:connect:", connect);
|
|
@@ -53,7 +53,7 @@ export function useConnect(partnerId: string, chain?: Chain) {
|
|
|
53
53
|
return wallet;
|
|
54
54
|
});
|
|
55
55
|
},
|
|
56
|
-
[chain, connect, partnerId]
|
|
56
|
+
[chain, connect, partnerId],
|
|
57
57
|
);
|
|
58
58
|
|
|
59
59
|
return { connect: connectTw, isLoading };
|
|
@@ -22,21 +22,21 @@ export function useExchangeRate({ baseCurrency, quoteCurrency, refreshInterval =
|
|
|
22
22
|
data: rate = 0,
|
|
23
23
|
isLoading,
|
|
24
24
|
error,
|
|
25
|
-
refetch
|
|
25
|
+
refetch,
|
|
26
26
|
} = useQuery({
|
|
27
27
|
queryKey: ["exchangeRate", baseCurrency, quoteCurrency],
|
|
28
28
|
queryFn: () => fetchExchangeRate(baseCurrency, quoteCurrency),
|
|
29
29
|
refetchInterval: refreshInterval,
|
|
30
30
|
staleTime: refreshInterval / 2, // Consider data stale after half the refresh interval
|
|
31
31
|
retry: 3,
|
|
32
|
-
retryDelay: attemptIndex => Math.min(1000 * 2 ** attemptIndex, 30000)
|
|
32
|
+
retryDelay: attemptIndex => Math.min(1000 * 2 ** attemptIndex, 30000),
|
|
33
33
|
});
|
|
34
34
|
|
|
35
35
|
return {
|
|
36
36
|
rate,
|
|
37
37
|
isLoading,
|
|
38
38
|
error,
|
|
39
|
-
refetch
|
|
39
|
+
refetch,
|
|
40
40
|
};
|
|
41
41
|
}
|
|
42
42
|
|
|
@@ -74,8 +74,8 @@ export function useGetAllTWSigners({ chain, accountAddress, queryOptions }: UseG
|
|
|
74
74
|
contract: {
|
|
75
75
|
client,
|
|
76
76
|
chain,
|
|
77
|
-
address: accountAddress as `0x${string}
|
|
78
|
-
}
|
|
77
|
+
address: accountAddress as `0x${string}`,
|
|
78
|
+
},
|
|
79
79
|
});
|
|
80
80
|
|
|
81
81
|
// Wait half a second for the sync, this is a hack
|
|
@@ -89,9 +89,9 @@ export function useGetAllTWSigners({ chain, accountAddress, queryOptions }: UseG
|
|
|
89
89
|
{
|
|
90
90
|
method: "GET",
|
|
91
91
|
headers: {
|
|
92
|
-
"Content-Type": "application/json"
|
|
93
|
-
}
|
|
94
|
-
}
|
|
92
|
+
"Content-Type": "application/json",
|
|
93
|
+
},
|
|
94
|
+
},
|
|
95
95
|
);
|
|
96
96
|
|
|
97
97
|
if (response.ok) {
|
|
@@ -101,7 +101,7 @@ export function useGetAllTWSigners({ chain, accountAddress, queryOptions }: UseG
|
|
|
101
101
|
acc[key.sessionKey] = key;
|
|
102
102
|
return acc;
|
|
103
103
|
},
|
|
104
|
-
{} as Record<string, SessionKeyData
|
|
104
|
+
{} as Record<string, SessionKeyData>,
|
|
105
105
|
);
|
|
106
106
|
}
|
|
107
107
|
} catch (error) {
|
|
@@ -123,9 +123,9 @@ export function useGetAllTWSigners({ chain, accountAddress, queryOptions }: UseG
|
|
|
123
123
|
metadata,
|
|
124
124
|
partner: {
|
|
125
125
|
id: metadata?.partnerId || signer.signer,
|
|
126
|
-
name: metadata?.partnerInfo?.name || ""
|
|
126
|
+
name: metadata?.partnerInfo?.name || "",
|
|
127
127
|
},
|
|
128
|
-
createdAt: metadata ? new Date(metadata.timestamp).toISOString() : ""
|
|
128
|
+
createdAt: metadata ? new Date(metadata.timestamp).toISOString() : "",
|
|
129
129
|
};
|
|
130
130
|
});
|
|
131
131
|
return result;
|
|
@@ -134,6 +134,6 @@ export function useGetAllTWSigners({ chain, accountAddress, queryOptions }: UseG
|
|
|
134
134
|
refetchOnMount: true,
|
|
135
135
|
refetchOnWindowFocus: true,
|
|
136
136
|
refetchOnReconnect: true,
|
|
137
|
-
staleTime: 0 // Consider data stale immediately
|
|
137
|
+
staleTime: 0, // Consider data stale immediately
|
|
138
138
|
});
|
|
139
139
|
}
|
|
@@ -42,8 +42,8 @@ export function useHandleConnectWithPrivy(partnerId: string, chain?: Chain, onSu
|
|
|
42
42
|
strategy: "auth_endpoint",
|
|
43
43
|
payload: JSON.stringify({
|
|
44
44
|
strategy: "basement",
|
|
45
|
-
accessToken: fullToken
|
|
46
|
-
})
|
|
45
|
+
accessToken: fullToken,
|
|
46
|
+
}),
|
|
47
47
|
});
|
|
48
48
|
|
|
49
49
|
debug("@@useHandleConnectWithPrivy:connect:return", wallet);
|
|
@@ -13,7 +13,7 @@ const IS_SERVER = typeof window === "undefined";
|
|
|
13
13
|
|
|
14
14
|
export function useMediaQuery(
|
|
15
15
|
query: string,
|
|
16
|
-
{ defaultValue = false, initializeWithValue = true }: UseMediaQueryOptions = {}
|
|
16
|
+
{ defaultValue = false, initializeWithValue = true }: UseMediaQueryOptions = {},
|
|
17
17
|
): boolean {
|
|
18
18
|
const getMatches = (query: string): boolean => {
|
|
19
19
|
if (IS_SERVER) {
|
|
@@ -15,7 +15,7 @@ async function fetchNativeBalance(address: string, chainIds: string) {
|
|
|
15
15
|
if (!address) throw new Error("Address is required");
|
|
16
16
|
|
|
17
17
|
const response = await fetch(
|
|
18
|
-
`https://api.sprinter.buildwithsygma.com/accounts/${address}/assets/native?whitelistedChains=${chainIds}
|
|
18
|
+
`https://api.sprinter.buildwithsygma.com/accounts/${address}/assets/native?whitelistedChains=${chainIds}`,
|
|
19
19
|
);
|
|
20
20
|
|
|
21
21
|
if (!response.ok) {
|
|
@@ -36,8 +36,8 @@ async function fetchNativeBalance(address: string, chainIds: string) {
|
|
|
36
36
|
breakdown: data.data.map(item => ({
|
|
37
37
|
chainId: item.chainId,
|
|
38
38
|
balance: BigInt(item.balance),
|
|
39
|
-
formatted: formatNumber(Number(formatUnits(BigInt(item.balance), item.tokenDecimals)))
|
|
40
|
-
}))
|
|
39
|
+
formatted: formatNumber(Number(formatUnits(BigInt(item.balance), item.tokenDecimals))),
|
|
40
|
+
})),
|
|
41
41
|
};
|
|
42
42
|
}
|
|
43
43
|
|
|
@@ -47,7 +47,7 @@ export function useNativeBalance(address?: string, chainIds = "8333") {
|
|
|
47
47
|
queryFn: () => fetchNativeBalance(address!, chainIds),
|
|
48
48
|
enabled: Boolean(address),
|
|
49
49
|
staleTime: 30 * 1000, // Consider data fresh for 30 seconds
|
|
50
|
-
gcTime: 5 * 60 * 1000 // Keep unused data in cache for 5 minutes
|
|
50
|
+
gcTime: 5 * 60 * 1000, // Keep unused data in cache for 5 minutes
|
|
51
51
|
});
|
|
52
52
|
}
|
|
53
53
|
|
|
@@ -69,11 +69,11 @@ export function useNativeBalanceFromRPC(address: string, chainId: number) {
|
|
|
69
69
|
try {
|
|
70
70
|
const publicClient = createPublicClient({
|
|
71
71
|
chain: chainId === 8333 ? b3Mainnet : b3Testnet,
|
|
72
|
-
transport: http()
|
|
72
|
+
transport: http(),
|
|
73
73
|
});
|
|
74
74
|
|
|
75
75
|
const balance = await publicClient.getBalance({
|
|
76
|
-
address: address as `0x${string}
|
|
76
|
+
address: address as `0x${string}`,
|
|
77
77
|
});
|
|
78
78
|
|
|
79
79
|
return parseFloat(formatEther(balance));
|
|
@@ -83,7 +83,7 @@ export function useNativeBalanceFromRPC(address: string, chainId: number) {
|
|
|
83
83
|
return 0;
|
|
84
84
|
}
|
|
85
85
|
},
|
|
86
|
-
enabled: Boolean(address)
|
|
86
|
+
enabled: Boolean(address),
|
|
87
87
|
});
|
|
88
88
|
|
|
89
89
|
return { balance, isLoading };
|
|
@@ -16,7 +16,7 @@ export function useOnchainName(address: string | undefined) {
|
|
|
16
16
|
return null;
|
|
17
17
|
}
|
|
18
18
|
},
|
|
19
|
-
enabled: !!address
|
|
19
|
+
enabled: !!address,
|
|
20
20
|
});
|
|
21
21
|
|
|
22
22
|
const { data: b3Name, isLoading: isLoadingB3 } = useQuery({
|
|
@@ -30,7 +30,7 @@ export function useOnchainName(address: string | undefined) {
|
|
|
30
30
|
return null;
|
|
31
31
|
}
|
|
32
32
|
},
|
|
33
|
-
enabled: !!address
|
|
33
|
+
enabled: !!address,
|
|
34
34
|
});
|
|
35
35
|
|
|
36
36
|
const { data: ensName, isLoading: isLoadingEns } = useQuery({
|
|
@@ -48,14 +48,14 @@ export function useOnchainName(address: string | undefined) {
|
|
|
48
48
|
return null;
|
|
49
49
|
}
|
|
50
50
|
},
|
|
51
|
-
enabled: !!address
|
|
51
|
+
enabled: !!address,
|
|
52
52
|
});
|
|
53
53
|
|
|
54
54
|
return {
|
|
55
55
|
name: bsmntName || b3Name || ensName || null,
|
|
56
56
|
isLoading: isLoadingBsmnt || isLoadingB3 || isLoadingEns,
|
|
57
57
|
b3Name,
|
|
58
|
-
ensName
|
|
58
|
+
ensName,
|
|
59
59
|
};
|
|
60
60
|
}
|
|
61
61
|
|
|
@@ -81,14 +81,14 @@ export function useOnchainNames(addresses: string[]) {
|
|
|
81
81
|
return null;
|
|
82
82
|
}
|
|
83
83
|
},
|
|
84
|
-
enabled: !!address
|
|
84
|
+
enabled: !!address,
|
|
85
85
|
}));
|
|
86
86
|
|
|
87
87
|
const results = useQueries({ queries });
|
|
88
88
|
|
|
89
89
|
return {
|
|
90
90
|
names: results.map(result => result.data),
|
|
91
|
-
isLoading: results.some(result => result.isLoading)
|
|
91
|
+
isLoading: results.some(result => result.isLoading),
|
|
92
92
|
};
|
|
93
93
|
}
|
|
94
94
|
|
|
@@ -138,7 +138,7 @@ export function useResolveOnchainName(name: string | undefined) {
|
|
|
138
138
|
// Fall back to B3 name resolution
|
|
139
139
|
try {
|
|
140
140
|
const b3Response = await getEnsName(
|
|
141
|
-
name.replace("@", "").replace(".b3.fun", "").replace(".b3", "") + ".b3.fun"
|
|
141
|
+
name.replace("@", "").replace(".b3.fun", "").replace(".b3", "") + ".b3.fun",
|
|
142
142
|
);
|
|
143
143
|
const b3Data = await b3Response.json();
|
|
144
144
|
return b3Data?.addresses?.["60"] || null;
|
|
@@ -151,12 +151,12 @@ export function useResolveOnchainName(name: string | undefined) {
|
|
|
151
151
|
return null;
|
|
152
152
|
}
|
|
153
153
|
},
|
|
154
|
-
enabled: !!name
|
|
154
|
+
enabled: !!name,
|
|
155
155
|
});
|
|
156
156
|
|
|
157
157
|
return {
|
|
158
158
|
address,
|
|
159
|
-
isLoading
|
|
159
|
+
isLoading,
|
|
160
160
|
};
|
|
161
161
|
}
|
|
162
162
|
|
|
@@ -187,12 +187,12 @@ export function useOnchainPFP(name: string | undefined) {
|
|
|
187
187
|
return null;
|
|
188
188
|
}
|
|
189
189
|
},
|
|
190
|
-
enabled: !!name
|
|
190
|
+
enabled: !!name,
|
|
191
191
|
});
|
|
192
192
|
|
|
193
193
|
return {
|
|
194
194
|
pfp,
|
|
195
195
|
isLoading,
|
|
196
|
-
address
|
|
196
|
+
address,
|
|
197
197
|
};
|
|
198
198
|
}
|
|
@@ -33,7 +33,7 @@ export const useOneBalance = (bypassCache = false) => {
|
|
|
33
33
|
queryFn: () => fetchBalances(address!, sprinterTestnet),
|
|
34
34
|
enabled: !!address,
|
|
35
35
|
staleTime: 1000 * 60 * 1, // 1 minute
|
|
36
|
-
gcTime: 1000 * 60 * 5 // 5 minutes (renamed from cacheTime in v5)
|
|
36
|
+
gcTime: 1000 * 60 * 5, // 5 minutes (renamed from cacheTime in v5)
|
|
37
37
|
});
|
|
38
38
|
|
|
39
39
|
useEffect(() => {
|
|
@@ -90,6 +90,6 @@ export const useOneBalance = (bypassCache = false) => {
|
|
|
90
90
|
aggregatedBalances: data || [],
|
|
91
91
|
aggregatedTokenBalances,
|
|
92
92
|
loading: isLoading,
|
|
93
|
-
refetch
|
|
93
|
+
refetch,
|
|
94
94
|
};
|
|
95
95
|
};
|
|
@@ -35,12 +35,12 @@ export type DataType<T extends keyof ServiceTypes, M extends ServiceMethods<T>>
|
|
|
35
35
|
|
|
36
36
|
export function useQueryB3<
|
|
37
37
|
T extends keyof ServiceTypes, // Service name (key of ServiceTypes)
|
|
38
|
-
M extends ServiceMethods<T
|
|
38
|
+
M extends ServiceMethods<T>, // Method name within the service
|
|
39
39
|
>(
|
|
40
40
|
service: T, // Service as string
|
|
41
41
|
method: M, // Method as string
|
|
42
42
|
params: ParamsType<T, M>, // Params type inferred dynamically
|
|
43
|
-
fetchInitially = true
|
|
43
|
+
fetchInitially = true,
|
|
44
44
|
) {
|
|
45
45
|
// Use DataType to infer the type of data and unwrap the Promise
|
|
46
46
|
const [data, setData] = useState<DataType<T, M> | null>(null);
|
|
@@ -35,12 +35,12 @@ export type DataType<T extends keyof ServiceTypes, M extends ServiceMethods<T>>
|
|
|
35
35
|
|
|
36
36
|
export function useQueryBSMNT<
|
|
37
37
|
T extends keyof ServiceTypes, // Service name (key of ServiceTypes)
|
|
38
|
-
M extends ServiceMethods<T
|
|
38
|
+
M extends ServiceMethods<T>, // Method name within the service
|
|
39
39
|
>(
|
|
40
40
|
service: T, // Service as string
|
|
41
41
|
method: M, // Method as string
|
|
42
42
|
params: ParamsType<T, M>, // Params type inferred dynamically
|
|
43
|
-
fetchInitially = true
|
|
43
|
+
fetchInitially = true,
|
|
44
44
|
) {
|
|
45
45
|
// Use DataType to infer the type of data and unwrap the Promise
|
|
46
46
|
const [data, setData] = useState<DataType<T, M> | null>(null);
|
|
@@ -12,14 +12,14 @@ export function useRemoveSessionKey({
|
|
|
12
12
|
onSuccess,
|
|
13
13
|
onError,
|
|
14
14
|
refetchSigners,
|
|
15
|
-
chain
|
|
15
|
+
chain,
|
|
16
16
|
}: {
|
|
17
17
|
chain?: Chain;
|
|
18
18
|
onSuccess: (
|
|
19
19
|
transactionResult: { transactionHash: Hex } & {
|
|
20
20
|
client: ThirdwebClient;
|
|
21
21
|
chain: Chain;
|
|
22
|
-
}
|
|
22
|
+
},
|
|
23
23
|
) => void;
|
|
24
24
|
onError: (error: Error) => void;
|
|
25
25
|
refetchSigners: () => Promise<any>;
|
|
@@ -42,10 +42,10 @@ export function useRemoveSessionKey({
|
|
|
42
42
|
contract: {
|
|
43
43
|
client,
|
|
44
44
|
chain,
|
|
45
|
-
address: account.address as `0x${string}
|
|
45
|
+
address: account.address as `0x${string}`,
|
|
46
46
|
},
|
|
47
47
|
account,
|
|
48
|
-
sessionKeyAddress: signer.signer as `0x${string}
|
|
48
|
+
sessionKeyAddress: signer.signer as `0x${string}`,
|
|
49
49
|
});
|
|
50
50
|
|
|
51
51
|
debug("@@ecosystem:removeSessionKey:transaction:", transaction);
|
|
@@ -62,7 +62,7 @@ export function useRemoveSessionKey({
|
|
|
62
62
|
setIsRemovingSessionKey(false);
|
|
63
63
|
}
|
|
64
64
|
},
|
|
65
|
-
[account, chain, onSuccess, onError, refetchSigners]
|
|
65
|
+
[account, chain, onSuccess, onError, refetchSigners],
|
|
66
66
|
);
|
|
67
67
|
|
|
68
68
|
return { removeSessionKey: removeSessionKeyHandler, isRemovingSessionKey };
|
|
@@ -33,7 +33,7 @@ export function useRouter(): UseRouterReturn {
|
|
|
33
33
|
push: () => {},
|
|
34
34
|
replace: () => {},
|
|
35
35
|
back: () => {},
|
|
36
|
-
forward: () => {}
|
|
36
|
+
forward: () => {},
|
|
37
37
|
};
|
|
38
38
|
}
|
|
39
39
|
|
|
@@ -41,7 +41,7 @@ export function useRouter(): UseRouterReturn {
|
|
|
41
41
|
const [routerState, setRouterState] = useState<RouterState>(() => ({
|
|
42
42
|
pathname: window.location.pathname,
|
|
43
43
|
search: window.location.search,
|
|
44
|
-
hash: window.location.hash
|
|
44
|
+
hash: window.location.hash,
|
|
45
45
|
}));
|
|
46
46
|
|
|
47
47
|
// Update state when location changes
|
|
@@ -50,7 +50,7 @@ export function useRouter(): UseRouterReturn {
|
|
|
50
50
|
setRouterState({
|
|
51
51
|
pathname: window.location.pathname,
|
|
52
52
|
search: window.location.search,
|
|
53
|
-
hash: window.location.hash
|
|
53
|
+
hash: window.location.hash,
|
|
54
54
|
});
|
|
55
55
|
};
|
|
56
56
|
|
|
@@ -69,7 +69,7 @@ export function useRouter(): UseRouterReturn {
|
|
|
69
69
|
setRouterState({
|
|
70
70
|
pathname: window.location.pathname,
|
|
71
71
|
search: window.location.search,
|
|
72
|
-
hash: window.location.hash
|
|
72
|
+
hash: window.location.hash,
|
|
73
73
|
});
|
|
74
74
|
}, []);
|
|
75
75
|
|
|
@@ -79,7 +79,7 @@ export function useRouter(): UseRouterReturn {
|
|
|
79
79
|
setRouterState({
|
|
80
80
|
pathname: window.location.pathname,
|
|
81
81
|
search: window.location.search,
|
|
82
|
-
hash: window.location.hash
|
|
82
|
+
hash: window.location.hash,
|
|
83
83
|
});
|
|
84
84
|
}, []);
|
|
85
85
|
|
|
@@ -96,7 +96,7 @@ export function useRouter(): UseRouterReturn {
|
|
|
96
96
|
push,
|
|
97
97
|
replace,
|
|
98
98
|
back,
|
|
99
|
-
forward
|
|
99
|
+
forward,
|
|
100
100
|
};
|
|
101
101
|
}
|
|
102
102
|
|
|
@@ -9,13 +9,13 @@ export function useSiwe() {
|
|
|
9
9
|
|
|
10
10
|
// generate challenge
|
|
11
11
|
const challenge = await app.service("global-accounts-challenge").create({
|
|
12
|
-
address: account.address
|
|
12
|
+
address: account.address,
|
|
13
13
|
});
|
|
14
14
|
debug("@@useAuthenticate:challenge", challenge);
|
|
15
15
|
|
|
16
16
|
// sign challenge
|
|
17
17
|
const signature = await account.signMessage({
|
|
18
|
-
message: challenge.message
|
|
18
|
+
message: challenge.message,
|
|
19
19
|
});
|
|
20
20
|
|
|
21
21
|
debug("@@useAuthenticate:signature", signature);
|
|
@@ -26,7 +26,7 @@ export function useSiwe() {
|
|
|
26
26
|
message: challenge.message,
|
|
27
27
|
signature,
|
|
28
28
|
serverSignature: challenge.serverSignature,
|
|
29
|
-
nonce: challenge.nonce
|
|
29
|
+
nonce: challenge.nonce,
|
|
30
30
|
});
|
|
31
31
|
debug("@@useAuthenticate:response", response);
|
|
32
32
|
|
|
@@ -34,6 +34,6 @@ export function useSiwe() {
|
|
|
34
34
|
}, []);
|
|
35
35
|
|
|
36
36
|
return {
|
|
37
|
-
authenticate
|
|
37
|
+
authenticate,
|
|
38
38
|
};
|
|
39
39
|
}
|