@b3dotfun/sdk 0.0.7-alpha.9 → 0.0.8-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.
- 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/abis/signature-minting.d.ts +79 -0
- package/dist/cjs/anyspend/abis/signature-minting.js +45 -0
- package/dist/cjs/anyspend/constants/index.js +10 -10
- package/dist/cjs/anyspend/index.d.ts +3 -2
- package/dist/cjs/anyspend/index.js +3 -4
- package/dist/cjs/anyspend/react/components/AnySpend.d.ts +1 -1
- package/dist/cjs/anyspend/react/components/AnySpend.js +69 -68
- package/dist/cjs/anyspend/react/components/AnySpendBuySpin.d.ts +1 -1
- package/dist/cjs/anyspend/react/components/AnySpendBuySpin.js +36 -34
- package/dist/cjs/anyspend/react/components/AnySpendCustom.d.ts +2 -2
- package/dist/cjs/anyspend/react/components/AnySpendCustom.js +122 -102
- 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/AnyspendSignatureMint.d.ts +8 -0
- package/dist/cjs/anyspend/react/components/AnyspendSignatureMint.js +77 -0
- 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 +50 -61
- package/dist/cjs/anyspend/react/components/common/OrderHistory.js +6 -6
- 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 +9 -9
- package/dist/cjs/anyspend/react/components/common/PanelOnrampPayment.d.ts +1 -1
- package/dist/cjs/anyspend/react/components/common/PanelOnrampPayment.js +15 -14
- 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 +26 -25
- 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/common/Warning.d.ts +3 -0
- package/dist/cjs/anyspend/react/components/common/Warning.js +7 -0
- package/dist/cjs/anyspend/react/components/index.d.ts +2 -0
- package/dist/cjs/anyspend/react/components/index.js +5 -1
- package/dist/cjs/anyspend/react/components/modals/EnterRecipientModal.d.ts +1 -1
- package/dist/cjs/anyspend/react/components/modals/EnterRecipientModal.js +6 -6
- package/dist/cjs/anyspend/react/components/webview/WebviewOnrampOrderStatus.js +0 -1
- package/dist/cjs/anyspend/react/components/webview/WebviewOnrampPayment.d.ts +1 -1
- package/dist/cjs/anyspend/react/components/webview/WebviewOnrampPayment.js +26 -25
- package/dist/cjs/anyspend/react/hooks/index.d.ts +1 -2
- package/dist/cjs/anyspend/react/hooks/index.js +1 -2
- package/dist/cjs/anyspend/react/hooks/useAnyspendCreateOnrampOrder.d.ts +3 -18
- package/dist/cjs/anyspend/react/hooks/useAnyspendCreateOnrampOrder.js +6 -6
- package/dist/cjs/anyspend/react/hooks/useAnyspendCreateOrder.d.ts +1 -0
- package/dist/cjs/anyspend/react/hooks/useAnyspendCreateOrder.js +6 -6
- package/dist/cjs/anyspend/react/hooks/useAnyspendOrderAndTransactions.d.ts +10 -70
- package/dist/cjs/anyspend/react/hooks/useAnyspendOrderAndTransactions.js +2 -2
- package/dist/cjs/anyspend/react/hooks/useAnyspendOrderHistory.d.ts +10 -70
- package/dist/cjs/anyspend/react/hooks/useAnyspendOrderHistory.js +3 -3
- package/dist/cjs/anyspend/react/hooks/useAnyspendQuote.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/useSigMint.d.ts +140 -0
- package/dist/cjs/anyspend/react/hooks/useSigMint.js +39 -0
- 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 +7 -6
- package/dist/cjs/anyspend/services/anyspend.d.ts +7 -40
- package/dist/cjs/anyspend/services/anyspend.js +10 -23
- package/dist/cjs/anyspend/types/custom.js +2 -2
- package/dist/cjs/anyspend/types/globalWallet.js +1 -1
- package/dist/cjs/anyspend/types/index.d.ts +0 -1
- package/dist/cjs/anyspend/types/index.js +0 -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 -200
- package/dist/cjs/anyspend/types/order.js +7 -12
- package/dist/cjs/anyspend/types/req-res/createOrder.d.ts +70 -235
- 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 -305
- 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 -235
- 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/index.d.ts +0 -1
- package/dist/cjs/anyspend/types/req-res/index.js +0 -1
- package/dist/cjs/anyspend/types/signature-mint.d.ts +69 -0
- package/dist/cjs/anyspend/types/signature-mint.js +2 -0
- 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 -6
- 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 +13 -3
- package/dist/cjs/global-account/react/components/B3Provider/B3Provider.d.ts +2 -2
- package/dist/cjs/global-account/react/components/B3Provider/B3Provider.js +16 -15
- 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/components/ui/tooltip.js +1 -1
- package/dist/cjs/global-account/react/hooks/useAccountAssets.js +4 -4
- package/dist/cjs/global-account/react/hooks/useAccountWallet.js +8 -8
- 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.d.ts +7 -0
- package/dist/cjs/global-account/react/hooks/useB3EnsName.js +15 -6
- 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 +14 -14
- 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.d.ts +17 -2
- 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/react/hooks/index.d.ts +1 -0
- package/dist/cjs/shared/react/hooks/index.js +17 -0
- package/dist/cjs/shared/react/hooks/useNavigation.d.ts +17 -0
- package/dist/cjs/shared/react/hooks/useNavigation.js +57 -0
- package/dist/cjs/shared/react/index.d.ts +1 -0
- package/dist/cjs/shared/react/index.js +17 -0
- package/dist/cjs/shared/thirdweb/generated/sdk.gen.d.ts +2 -2
- package/dist/cjs/shared/thirdweb/generated/sdk.gen.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/formatUsername.d.ts +1 -0
- package/dist/cjs/shared/utils/formatUsername.js +8 -0
- package/dist/cjs/shared/utils/index.d.ts +3 -10
- package/dist/cjs/shared/utils/index.js +4 -23
- 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/cjs/shared/utils/truncateAddress.d.ts +6 -0
- package/dist/cjs/shared/utils/truncateAddress.js +16 -0
- 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/abis/signature-minting.d.ts +79 -0
- package/dist/esm/anyspend/abis/signature-minting.js +42 -0
- package/dist/esm/anyspend/constants/index.js +10 -10
- package/dist/esm/anyspend/index.d.ts +3 -2
- package/dist/esm/anyspend/index.js +3 -4
- package/dist/esm/anyspend/react/components/AnySpend.d.ts +1 -1
- package/dist/esm/anyspend/react/components/AnySpend.js +23 -22
- package/dist/esm/anyspend/react/components/AnySpendBuySpin.d.ts +1 -1
- package/dist/esm/anyspend/react/components/AnySpendBuySpin.js +37 -35
- package/dist/esm/anyspend/react/components/AnySpendCustom.d.ts +2 -2
- package/dist/esm/anyspend/react/components/AnySpendCustom.js +94 -74
- 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/AnyspendSignatureMint.d.ts +8 -0
- package/dist/esm/anyspend/react/components/AnyspendSignatureMint.js +71 -0
- 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 +51 -62
- package/dist/esm/anyspend/react/components/common/OrderHistory.js +1 -1
- 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 +3 -3
- package/dist/esm/anyspend/react/components/common/PanelOnrampPayment.d.ts +1 -1
- package/dist/esm/anyspend/react/components/common/PanelOnrampPayment.js +9 -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 +14 -13
- 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/common/Warning.d.ts +3 -0
- package/dist/esm/anyspend/react/components/common/Warning.js +4 -0
- package/dist/esm/anyspend/react/components/index.d.ts +2 -0
- package/dist/esm/anyspend/react/components/index.js +2 -0
- package/dist/esm/anyspend/react/components/modals/EnterRecipientModal.d.ts +1 -1
- package/dist/esm/anyspend/react/components/modals/EnterRecipientModal.js +2 -2
- package/dist/esm/anyspend/react/components/webview/WebviewOnrampOrderStatus.js +0 -1
- package/dist/esm/anyspend/react/components/webview/WebviewOnrampPayment.d.ts +1 -1
- package/dist/esm/anyspend/react/components/webview/WebviewOnrampPayment.js +16 -15
- package/dist/esm/anyspend/react/hooks/index.d.ts +1 -2
- package/dist/esm/anyspend/react/hooks/index.js +1 -2
- package/dist/esm/anyspend/react/hooks/useAnyspendCreateOnrampOrder.d.ts +3 -18
- package/dist/esm/anyspend/react/hooks/useAnyspendCreateOnrampOrder.js +6 -6
- package/dist/esm/anyspend/react/hooks/useAnyspendCreateOrder.d.ts +1 -0
- package/dist/esm/anyspend/react/hooks/useAnyspendCreateOrder.js +7 -7
- package/dist/esm/anyspend/react/hooks/useAnyspendOrderAndTransactions.d.ts +10 -70
- package/dist/esm/anyspend/react/hooks/useAnyspendOrderAndTransactions.js +2 -2
- package/dist/esm/anyspend/react/hooks/useAnyspendOrderHistory.d.ts +10 -70
- package/dist/esm/anyspend/react/hooks/useAnyspendOrderHistory.js +3 -3
- package/dist/esm/anyspend/react/hooks/useAnyspendQuote.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/useSigMint.d.ts +140 -0
- package/dist/esm/anyspend/react/hooks/useSigMint.js +33 -0
- 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 +5 -4
- package/dist/esm/anyspend/services/anyspend.d.ts +7 -40
- package/dist/esm/anyspend/services/anyspend.js +11 -24
- package/dist/esm/anyspend/types/custom.js +2 -2
- package/dist/esm/anyspend/types/globalWallet.js +1 -1
- package/dist/esm/anyspend/types/index.d.ts +0 -1
- package/dist/esm/anyspend/types/index.js +0 -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 -200
- package/dist/esm/anyspend/types/order.js +7 -12
- package/dist/esm/anyspend/types/req-res/createOrder.d.ts +70 -235
- 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 -305
- 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 -235
- 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/index.d.ts +0 -1
- package/dist/esm/anyspend/types/req-res/index.js +0 -1
- package/dist/esm/anyspend/types/signature-mint.d.ts +69 -0
- package/dist/esm/anyspend/types/signature-mint.js +1 -0
- 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 -6
- 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 +14 -4
- package/dist/esm/global-account/react/components/B3Provider/B3Provider.d.ts +2 -2
- package/dist/esm/global-account/react/components/B3Provider/B3Provider.js +7 -6
- 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/components/ui/tooltip.js +1 -1
- package/dist/esm/global-account/react/hooks/useAccountAssets.js +4 -4
- package/dist/esm/global-account/react/hooks/useAccountWallet.js +8 -8
- 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.d.ts +7 -0
- package/dist/esm/global-account/react/hooks/useB3EnsName.js +15 -6
- 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 +13 -13
- 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.d.ts +17 -2
- 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/react/hooks/index.d.ts +1 -0
- package/dist/esm/shared/react/hooks/index.js +1 -0
- package/dist/esm/shared/react/hooks/useNavigation.d.ts +17 -0
- package/dist/esm/shared/react/hooks/useNavigation.js +52 -0
- package/dist/esm/shared/react/index.d.ts +1 -0
- package/dist/esm/shared/react/index.js +1 -0
- package/dist/esm/shared/thirdweb/generated/sdk.gen.d.ts +2 -2
- package/dist/esm/shared/thirdweb/generated/sdk.gen.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/formatUsername.d.ts +1 -0
- package/dist/esm/shared/utils/formatUsername.js +5 -0
- package/dist/esm/shared/utils/index.d.ts +3 -10
- package/dist/esm/shared/utils/index.js +4 -20
- 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/esm/shared/utils/truncateAddress.d.ts +6 -0
- package/dist/esm/shared/utils/truncateAddress.js +12 -0
- package/dist/styles/index.css +1 -1
- package/dist/types/anyspend/abis/signature-minting.d.ts +79 -0
- package/dist/types/anyspend/index.d.ts +3 -2
- 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/AnyspendSignatureMint.d.ts +8 -0
- 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/common/Warning.d.ts +3 -0
- package/dist/types/anyspend/react/components/index.d.ts +2 -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/index.d.ts +1 -2
- package/dist/types/anyspend/react/hooks/useAnyspendCreateOnrampOrder.d.ts +3 -18
- package/dist/types/anyspend/react/hooks/useAnyspendCreateOrder.d.ts +1 -0
- package/dist/types/anyspend/react/hooks/useAnyspendOrderAndTransactions.d.ts +10 -70
- package/dist/types/anyspend/react/hooks/useAnyspendOrderHistory.d.ts +10 -70
- package/dist/types/anyspend/react/hooks/useSigMint.d.ts +140 -0
- package/dist/types/anyspend/services/anyspend.d.ts +7 -40
- package/dist/types/anyspend/types/index.d.ts +0 -1
- package/dist/types/anyspend/types/onramp.d.ts +3 -0
- package/dist/types/anyspend/types/order.d.ts +30 -200
- package/dist/types/anyspend/types/req-res/createOrder.d.ts +70 -235
- package/dist/types/anyspend/types/req-res/getOrderAndTransactions.d.ts +45 -305
- package/dist/types/anyspend/types/req-res/getOrderHistory.d.ts +35 -235
- package/dist/types/anyspend/types/req-res/getQuote.d.ts +26 -0
- package/dist/types/anyspend/types/req-res/index.d.ts +0 -1
- package/dist/types/anyspend/types/signature-mint.d.ts +69 -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/useB3EnsName.d.ts +7 -0
- 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/dist/types/global-account/react/stores/useModalStore.d.ts +17 -2
- package/dist/types/shared/react/hooks/index.d.ts +1 -0
- package/dist/types/shared/react/hooks/useNavigation.d.ts +17 -0
- package/dist/types/shared/react/index.d.ts +1 -0
- package/dist/types/shared/thirdweb/generated/sdk.gen.d.ts +2 -2
- package/dist/types/shared/utils/formatUsername.d.ts +1 -0
- package/dist/types/shared/utils/index.d.ts +3 -10
- package/dist/types/shared/utils/truncateAddress.d.ts +6 -0
- package/package.json +3 -2
- package/src/anyspend/README.md +12 -0
- package/src/anyspend/abis/abi-usdc-base.ts +97 -97
- package/src/anyspend/abis/erc20-staking.ts +51 -51
- package/src/anyspend/abis/signature-minting.ts +43 -0
- package/src/anyspend/constants/index.ts +10 -10
- package/src/anyspend/index.ts +3 -6
- package/src/anyspend/react/components/AnySpend.tsx +44 -39
- package/src/anyspend/react/components/AnySpendBuySpin.tsx +40 -36
- package/src/anyspend/react/components/AnySpendCustom.tsx +158 -82
- 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/AnyspendSignatureMint.tsx +147 -0
- package/src/anyspend/react/components/common/ChainTokenIcon.tsx +1 -1
- package/src/anyspend/react/components/common/OrderDetails.tsx +71 -73
- package/src/anyspend/react/components/common/OrderHistory.tsx +1 -1
- 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 +4 -4
- package/src/anyspend/react/components/common/PanelOnrampPayment.tsx +9 -17
- 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 +16 -15
- package/src/anyspend/react/components/common/TokenBalance.tsx +2 -2
- package/src/anyspend/react/components/common/Warning.tsx +7 -0
- package/src/anyspend/react/components/index.ts +2 -0
- package/src/anyspend/react/components/modals/EnterRecipientModal.tsx +2 -2
- package/src/anyspend/react/components/webview/WebviewOnrampOrderStatus.tsx +0 -1
- package/src/anyspend/react/components/webview/WebviewOnrampPayment.tsx +18 -20
- package/src/anyspend/react/hooks/index.ts +1 -2
- package/src/anyspend/react/hooks/useAnyspendCreateOnrampOrder.ts +10 -20
- package/src/anyspend/react/hooks/useAnyspendCreateOrder.ts +9 -8
- 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 +6 -6
- 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/useSigMint.tsx +55 -0
- 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 +9 -4
- package/src/anyspend/services/anyspend.ts +19 -37
- 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/index.ts +0 -1
- package/src/anyspend/types/nft.ts +7 -7
- package/src/anyspend/types/onramp.ts +3 -2
- package/src/anyspend/types/order.ts +9 -16
- 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/index.ts +0 -1
- package/src/anyspend/types/signature-mint.ts +77 -0
- 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 -7
- 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 +15 -6
- package/src/global-account/react/components/B3Provider/B3Provider.native.tsx +4 -4
- package/src/global-account/react/components/B3Provider/B3Provider.tsx +21 -18
- 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 +2 -2
- package/src/global-account/react/hooks/useAccountAssets.ts +4 -4
- package/src/global-account/react/hooks/useAccountWallet.tsx +9 -9
- 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 +25 -7
- 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 +14 -14
- 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 +22 -5
- 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/react/hooks/index.ts +1 -0
- package/src/shared/react/hooks/useNavigation.ts +61 -0
- package/src/shared/react/index.ts +1 -0
- package/src/shared/thirdweb/generated/sdk.gen.ts +3 -3
- 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/formatUsername.ts +5 -0
- package/src/shared/utils/index.ts +4 -22
- 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
- package/src/shared/utils/truncateAddress.ts +11 -0
- package/src/styles/index.css +5 -2
- package/dist/cjs/anyspend/react/hooks/useAnyspendSendPermitData.d.ts +0 -16
- package/dist/cjs/anyspend/react/hooks/useAnyspendSendPermitData.js +0 -39
- package/dist/cjs/anyspend/react/hooks/usePermitData.d.ts +0 -92
- package/dist/cjs/anyspend/react/hooks/usePermitData.js +0 -158
- package/dist/cjs/anyspend/types/permit.d.ts +0 -21
- package/dist/cjs/anyspend/types/permit.js +0 -11
- package/dist/cjs/anyspend/types/req-res/sendPermitData.d.ts +0 -66
- package/dist/cjs/anyspend/types/req-res/sendPermitData.js +0 -11
- package/dist/esm/anyspend/react/hooks/useAnyspendSendPermitData.d.ts +0 -16
- package/dist/esm/anyspend/react/hooks/useAnyspendSendPermitData.js +0 -36
- package/dist/esm/anyspend/react/hooks/usePermitData.d.ts +0 -92
- package/dist/esm/anyspend/react/hooks/usePermitData.js +0 -154
- package/dist/esm/anyspend/types/permit.d.ts +0 -21
- package/dist/esm/anyspend/types/permit.js +0 -8
- package/dist/esm/anyspend/types/req-res/sendPermitData.d.ts +0 -66
- package/dist/esm/anyspend/types/req-res/sendPermitData.js +0 -8
- package/dist/types/anyspend/react/hooks/useAnyspendSendPermitData.d.ts +0 -16
- package/dist/types/anyspend/react/hooks/usePermitData.d.ts +0 -92
- package/dist/types/anyspend/types/permit.d.ts +0 -21
- package/dist/types/anyspend/types/req-res/sendPermitData.d.ts +0 -66
- package/src/anyspend/react/hooks/useAnyspendSendPermitData.ts +0 -38
- package/src/anyspend/react/hooks/usePermitData.ts +0 -183
- package/src/anyspend/types/permit.ts +0 -10
- package/src/anyspend/types/req-res/sendPermitData.ts +0 -10
|
@@ -8,7 +8,7 @@ import {
|
|
|
8
8
|
useChainSwitchWithAction,
|
|
9
9
|
useHasMounted,
|
|
10
10
|
useModalStore,
|
|
11
|
-
useTokenBalance
|
|
11
|
+
useTokenBalance,
|
|
12
12
|
} from "@b3dotfun/sdk/global-account/react";
|
|
13
13
|
import { formatTokenAmount } from "@b3dotfun/sdk/shared/utils/number";
|
|
14
14
|
import { motion } from "framer-motion";
|
|
@@ -26,7 +26,7 @@ import { UsdcIcon } from "./icons/USDCIcon";
|
|
|
26
26
|
|
|
27
27
|
const basePublicClient = createPublicClient({
|
|
28
28
|
chain: base,
|
|
29
|
-
transport: http()
|
|
29
|
+
transport: http(),
|
|
30
30
|
});
|
|
31
31
|
|
|
32
32
|
const ERC20Staking = "0xbf04200be3cbf371467a539706393c81c470f523";
|
|
@@ -36,7 +36,7 @@ function generateEncodedDataForStakingB3(amount: string, beneficiary: string): s
|
|
|
36
36
|
const encodedData = encodeFunctionData({
|
|
37
37
|
abi: ABI_ERC20_STAKING,
|
|
38
38
|
functionName: "stake",
|
|
39
|
-
args: [BigInt(amount), beneficiary]
|
|
39
|
+
args: [BigInt(amount), beneficiary],
|
|
40
40
|
});
|
|
41
41
|
return encodedData;
|
|
42
42
|
}
|
|
@@ -47,7 +47,7 @@ export function AnySpendStakeB3({
|
|
|
47
47
|
mode = "modal",
|
|
48
48
|
recipientAddress,
|
|
49
49
|
stakeAmount,
|
|
50
|
-
onSuccess
|
|
50
|
+
onSuccess,
|
|
51
51
|
}: {
|
|
52
52
|
isMainnet?: boolean;
|
|
53
53
|
loadOrder?: string;
|
|
@@ -63,9 +63,9 @@ export function AnySpendStakeB3({
|
|
|
63
63
|
const {
|
|
64
64
|
formattedBalance: b3Balance,
|
|
65
65
|
isLoading: isBalanceLoading,
|
|
66
|
-
rawBalance: b3RawBalance
|
|
66
|
+
rawBalance: b3RawBalance,
|
|
67
67
|
} = useTokenBalance({
|
|
68
|
-
token: B3_TOKEN
|
|
68
|
+
token: B3_TOKEN,
|
|
69
69
|
});
|
|
70
70
|
|
|
71
71
|
// Wagmi hooks for direct staking
|
|
@@ -82,8 +82,8 @@ export function AnySpendStakeB3({
|
|
|
82
82
|
const { isLoading: isTxPending, isSuccess: isTxSuccess } = useWaitForTransactionReceipt({
|
|
83
83
|
hash: stakingTxHash as `0x${string}`,
|
|
84
84
|
query: {
|
|
85
|
-
structuralSharing: false // Disable to avoid BigInt serialization issues
|
|
86
|
-
}
|
|
85
|
+
structuralSharing: false, // Disable to avoid BigInt serialization issues
|
|
86
|
+
},
|
|
87
87
|
});
|
|
88
88
|
|
|
89
89
|
// Show success modal when transaction is confirmed
|
|
@@ -197,7 +197,7 @@ export function AnySpendStakeB3({
|
|
|
197
197
|
address: B3_TOKEN.address as `0x${string}`,
|
|
198
198
|
abi: erc20Abi,
|
|
199
199
|
functionName: "allowance",
|
|
200
|
-
args: [address, ERC20Staking as `0x${string}`]
|
|
200
|
+
args: [address, ERC20Staking as `0x${string}`],
|
|
201
201
|
});
|
|
202
202
|
|
|
203
203
|
// If allowance is insufficient, request approval
|
|
@@ -208,7 +208,7 @@ export function AnySpendStakeB3({
|
|
|
208
208
|
address: B3_TOKEN.address as `0x${string}`,
|
|
209
209
|
abi: erc20Abi,
|
|
210
210
|
functionName: "approve",
|
|
211
|
-
args: [ERC20Staking as `0x${string}`, BigInt(userStakeAmount)]
|
|
211
|
+
args: [ERC20Staking as `0x${string}`, BigInt(userStakeAmount)],
|
|
212
212
|
});
|
|
213
213
|
|
|
214
214
|
toast.info("Approval confirmed. Proceeding with stake...");
|
|
@@ -220,7 +220,7 @@ export function AnySpendStakeB3({
|
|
|
220
220
|
address: ERC20Staking as `0x${string}`,
|
|
221
221
|
abi: ABI_ERC20_STAKING,
|
|
222
222
|
functionName: "stake",
|
|
223
|
-
args: [BigInt(userStakeAmount), recipientAddress as `0x${string}`]
|
|
223
|
+
args: [BigInt(userStakeAmount), recipientAddress as `0x${string}`],
|
|
224
224
|
});
|
|
225
225
|
|
|
226
226
|
setStakingTxHash(stakeHash);
|
|
@@ -285,7 +285,7 @@ export function AnySpendStakeB3({
|
|
|
285
285
|
animate={{
|
|
286
286
|
opacity: hasMounted ? 1 : 0,
|
|
287
287
|
y: hasMounted ? 0 : 20,
|
|
288
|
-
filter: hasMounted ? "blur(0px)" : "blur(10px)"
|
|
288
|
+
filter: hasMounted ? "blur(0px)" : "blur(10px)",
|
|
289
289
|
}}
|
|
290
290
|
transition={{ duration: 0.3, delay: 0, ease: "easeInOut" }}
|
|
291
291
|
className="relative mx-auto size-48"
|
|
@@ -297,7 +297,7 @@ export function AnySpendStakeB3({
|
|
|
297
297
|
animate={{
|
|
298
298
|
opacity: hasMounted ? 1 : 0,
|
|
299
299
|
y: hasMounted ? 0 : 20,
|
|
300
|
-
filter: hasMounted ? "blur(0px)" : "blur(10px)"
|
|
300
|
+
filter: hasMounted ? "blur(0px)" : "blur(10px)",
|
|
301
301
|
}}
|
|
302
302
|
transition={{ duration: 0.3, delay: 0.1, ease: "easeInOut" }}
|
|
303
303
|
>
|
|
@@ -315,7 +315,7 @@ export function AnySpendStakeB3({
|
|
|
315
315
|
animate={{
|
|
316
316
|
opacity: hasMounted ? 1 : 0,
|
|
317
317
|
y: hasMounted ? 0 : 20,
|
|
318
|
-
filter: hasMounted ? "blur(0px)" : "blur(10px)"
|
|
318
|
+
filter: hasMounted ? "blur(0px)" : "blur(10px)",
|
|
319
319
|
}}
|
|
320
320
|
transition={{ duration: 0.3, delay: 0.2, ease: "easeInOut" }}
|
|
321
321
|
className="bg-b3-react-background w-full p-6"
|
|
@@ -397,7 +397,7 @@ export function AnySpendStakeB3({
|
|
|
397
397
|
animate={{
|
|
398
398
|
opacity: hasMounted ? 1 : 0,
|
|
399
399
|
y: hasMounted ? 0 : 20,
|
|
400
|
-
filter: hasMounted ? "blur(0px)" : "blur(10px)"
|
|
400
|
+
filter: hasMounted ? "blur(0px)" : "blur(10px)",
|
|
401
401
|
}}
|
|
402
402
|
transition={{ duration: 0.3, delay: 0, ease: "easeInOut" }}
|
|
403
403
|
className="relative mx-auto mb-4 size-[120px]"
|
|
@@ -422,7 +422,7 @@ export function AnySpendStakeB3({
|
|
|
422
422
|
animate={{
|
|
423
423
|
opacity: hasMounted ? 1 : 0,
|
|
424
424
|
y: hasMounted ? 0 : 20,
|
|
425
|
-
filter: hasMounted ? "blur(0px)" : "blur(10px)"
|
|
425
|
+
filter: hasMounted ? "blur(0px)" : "blur(10px)",
|
|
426
426
|
}}
|
|
427
427
|
transition={{ duration: 0.3, delay: 0.1, ease: "easeInOut" }}
|
|
428
428
|
>
|
|
@@ -437,7 +437,7 @@ export function AnySpendStakeB3({
|
|
|
437
437
|
animate={{
|
|
438
438
|
opacity: hasMounted ? 1 : 0,
|
|
439
439
|
y: hasMounted ? 0 : 20,
|
|
440
|
-
filter: hasMounted ? "blur(0px)" : "blur(10px)"
|
|
440
|
+
filter: hasMounted ? "blur(0px)" : "blur(10px)",
|
|
441
441
|
}}
|
|
442
442
|
transition={{ duration: 0.3, delay: 0.2, ease: "easeInOut" }}
|
|
443
443
|
className="bg-b3-react-background w-full p-6"
|
|
@@ -484,7 +484,7 @@ export function AnySpendStakeB3({
|
|
|
484
484
|
encodedData={encodedData}
|
|
485
485
|
metadata={{
|
|
486
486
|
type: OrderType.Custom,
|
|
487
|
-
action: "stake B3"
|
|
487
|
+
action: "stake B3",
|
|
488
488
|
}}
|
|
489
489
|
header={header}
|
|
490
490
|
onSuccess={onSuccess}
|
|
@@ -40,7 +40,7 @@ export function AnySpendTournament(props: AnySpendTournamentProps) {
|
|
|
40
40
|
tournamentChainId,
|
|
41
41
|
tournamentContractAddress,
|
|
42
42
|
tournamentMetadata,
|
|
43
|
-
onSuccess
|
|
43
|
+
onSuccess,
|
|
44
44
|
} = props;
|
|
45
45
|
|
|
46
46
|
const dstToken = action === "join" ? props.tournamentEntryToken : props.tournamentFundToken;
|
|
@@ -48,7 +48,7 @@ export function AnySpendTournament(props: AnySpendTournamentProps) {
|
|
|
48
48
|
|
|
49
49
|
const header = ({
|
|
50
50
|
anyspendPrice,
|
|
51
|
-
isLoadingAnyspendPrice
|
|
51
|
+
isLoadingAnyspendPrice,
|
|
52
52
|
}: {
|
|
53
53
|
anyspendPrice: GetQuoteResponse | undefined;
|
|
54
54
|
isLoadingAnyspendPrice: boolean;
|
|
@@ -72,7 +72,7 @@ export function AnySpendTournament(props: AnySpendTournamentProps) {
|
|
|
72
72
|
<AnimatePresence mode="wait">
|
|
73
73
|
<div
|
|
74
74
|
className={cn("text-as-primary group flex items-center text-2xl font-semibold transition-all", {
|
|
75
|
-
"opacity-0": isLoadingAnyspendPrice
|
|
75
|
+
"opacity-0": isLoadingAnyspendPrice,
|
|
76
76
|
})}
|
|
77
77
|
>
|
|
78
78
|
{formatDisplayNumber(anyspendPrice?.data?.currencyIn?.amountUsd, { style: "currency" })} (
|
|
@@ -102,7 +102,7 @@ export function AnySpendTournament(props: AnySpendTournamentProps) {
|
|
|
102
102
|
encodedData="0x"
|
|
103
103
|
metadata={{
|
|
104
104
|
type: action === "join" ? OrderType.JoinTournament : OrderType.FundTournament,
|
|
105
|
-
tournament: tournamentMetadata
|
|
105
|
+
tournament: tournamentMetadata,
|
|
106
106
|
}}
|
|
107
107
|
header={header}
|
|
108
108
|
onSuccess={onSuccess}
|
|
@@ -0,0 +1,147 @@
|
|
|
1
|
+
import { OrderType } from "@b3dotfun/sdk/anyspend";
|
|
2
|
+
import { StyleRoot, useHasMounted, useTokenData } from "@b3dotfun/sdk/global-account/react";
|
|
3
|
+
import invariant from "@b3dotfun/sdk/shared/utils/debug";
|
|
4
|
+
import { useMemo } from "react";
|
|
5
|
+
import { encodeFunctionData, parseEther } from "viem";
|
|
6
|
+
import { ABI_SIGNATURE_MINTING } from "../../abis/signature-minting";
|
|
7
|
+
import { GenerateSigMintResponse } from "../../types/signature-mint";
|
|
8
|
+
import { AnySpendCustom } from "./AnySpendCustom";
|
|
9
|
+
|
|
10
|
+
// Helper function to determine if URL is a video
|
|
11
|
+
function isVideoURL(url: string): boolean {
|
|
12
|
+
const videoExtensions = [".mp4", ".webm", ".ogg"];
|
|
13
|
+
return videoExtensions.some(ext => url.toLowerCase().endsWith(ext));
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
function generateEncodedDataForSignatureMint(signatureData: GenerateSigMintResponse): string {
|
|
17
|
+
const { signature, payload } = signatureData;
|
|
18
|
+
invariant(signature, "Signature is required");
|
|
19
|
+
invariant(payload, "Payload is required");
|
|
20
|
+
|
|
21
|
+
const mintRequest = {
|
|
22
|
+
to: payload.to,
|
|
23
|
+
royaltyRecipient: payload.royaltyRecipient,
|
|
24
|
+
royaltyBps: BigInt(payload.royaltyBps || 0),
|
|
25
|
+
primarySaleRecipient: payload.primarySaleRecipient,
|
|
26
|
+
tokenId: BigInt(payload.tokenId || 0),
|
|
27
|
+
uri: payload.uri,
|
|
28
|
+
quantity: BigInt(payload.quantity || 1),
|
|
29
|
+
pricePerToken: parseEther(payload.price?.toString() || "0"),
|
|
30
|
+
currency: payload.currencyAddress,
|
|
31
|
+
validityStartTimestamp: BigInt(payload.mintStartTime || 0),
|
|
32
|
+
validityEndTimestamp: BigInt(payload.mintEndTime || 0),
|
|
33
|
+
uid: payload.uid as `0x${string}`,
|
|
34
|
+
};
|
|
35
|
+
|
|
36
|
+
const encodedData = encodeFunctionData({
|
|
37
|
+
abi: [ABI_SIGNATURE_MINTING[0]],
|
|
38
|
+
functionName: "mintWithSignature",
|
|
39
|
+
args: [mintRequest, signature as `0x${string}`],
|
|
40
|
+
});
|
|
41
|
+
|
|
42
|
+
return encodedData;
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
export function AnyspendSignatureMint({
|
|
46
|
+
loadOrder,
|
|
47
|
+
mode = "modal",
|
|
48
|
+
signatureData,
|
|
49
|
+
imageUrl,
|
|
50
|
+
onSuccess,
|
|
51
|
+
}: {
|
|
52
|
+
loadOrder?: string;
|
|
53
|
+
mode?: "modal" | "page";
|
|
54
|
+
signatureData: GenerateSigMintResponse;
|
|
55
|
+
imageUrl?: string;
|
|
56
|
+
onSuccess?: (txHash?: string) => void;
|
|
57
|
+
}) {
|
|
58
|
+
const hasMounted = useHasMounted();
|
|
59
|
+
|
|
60
|
+
// Get token data
|
|
61
|
+
const { data: tokenData, isError: isTokenError } = useTokenData(
|
|
62
|
+
signatureData.collection.chainId,
|
|
63
|
+
signatureData.collection.signatureRequestBody?.currency,
|
|
64
|
+
);
|
|
65
|
+
|
|
66
|
+
// Convert token data to AnySpend Token type
|
|
67
|
+
const dstToken = useMemo(() => {
|
|
68
|
+
if (!tokenData) return null;
|
|
69
|
+
|
|
70
|
+
return {
|
|
71
|
+
address: tokenData.address,
|
|
72
|
+
chainId: signatureData.collection.chainId,
|
|
73
|
+
name: tokenData.name,
|
|
74
|
+
symbol: tokenData.symbol,
|
|
75
|
+
decimals: tokenData.decimals,
|
|
76
|
+
metadata: {
|
|
77
|
+
logoURI: tokenData.logoURI,
|
|
78
|
+
},
|
|
79
|
+
};
|
|
80
|
+
}, [tokenData, signatureData.collection.chainId]);
|
|
81
|
+
|
|
82
|
+
const mediaUrl = imageUrl || signatureData.payload.metadata.image || "https://cdn.b3.fun/nft-placeholder.png";
|
|
83
|
+
const isVideo = isVideoURL(mediaUrl);
|
|
84
|
+
|
|
85
|
+
const header = () => (
|
|
86
|
+
<>
|
|
87
|
+
<div className="relative mx-auto size-32">
|
|
88
|
+
{isVideo ? (
|
|
89
|
+
<video autoPlay loop muted playsInline className="size-full rounded-lg object-cover">
|
|
90
|
+
<source src={mediaUrl} type={`video/${mediaUrl.split(".").pop()}`} />
|
|
91
|
+
Your browser does not support the video tag.
|
|
92
|
+
</video>
|
|
93
|
+
) : (
|
|
94
|
+
<img alt="nft preview" className="size-full rounded-lg object-cover" src={mediaUrl} />
|
|
95
|
+
)}
|
|
96
|
+
</div>
|
|
97
|
+
<div className="mt-[-60px] w-full rounded-t-lg bg-white">
|
|
98
|
+
<div className="h-[60px] w-full" />
|
|
99
|
+
<div className="mb-1 flex w-full flex-col items-center gap-2 p-5">
|
|
100
|
+
<span className="font-sf-rounded text-2xl font-semibold">
|
|
101
|
+
{signatureData.payload.metadata.name || "Mint NFT"}{" "}
|
|
102
|
+
{Number(signatureData.payload.quantity) > 1 ? `(${signatureData.payload.quantity}x)` : ""}
|
|
103
|
+
</span>
|
|
104
|
+
</div>
|
|
105
|
+
</div>
|
|
106
|
+
</>
|
|
107
|
+
);
|
|
108
|
+
|
|
109
|
+
// If we don't have token data, show error state
|
|
110
|
+
if (!dstToken || isTokenError) {
|
|
111
|
+
return (
|
|
112
|
+
<StyleRoot>
|
|
113
|
+
<div className="b3-root b3-modal bg-b3-react-background flex w-full flex-col items-center p-8">
|
|
114
|
+
<p className="text-as-red text-center text-sm">
|
|
115
|
+
Failed to fetch payment token information for {signatureData.collection.signatureRequestBody?.currency} on
|
|
116
|
+
chain {signatureData.collection.chainId}. Please try again.
|
|
117
|
+
</p>
|
|
118
|
+
</div>
|
|
119
|
+
</StyleRoot>
|
|
120
|
+
);
|
|
121
|
+
}
|
|
122
|
+
|
|
123
|
+
const encodedData = generateEncodedDataForSignatureMint(signatureData);
|
|
124
|
+
const price = parseEther(signatureData.payload.price?.toString() || "0");
|
|
125
|
+
|
|
126
|
+
return (
|
|
127
|
+
<AnySpendCustom
|
|
128
|
+
isMainnet={true}
|
|
129
|
+
loadOrder={loadOrder}
|
|
130
|
+
mode={mode}
|
|
131
|
+
recipientAddress={signatureData.payload.to}
|
|
132
|
+
orderType={OrderType.Custom}
|
|
133
|
+
dstChainId={signatureData.collection.chainId}
|
|
134
|
+
dstToken={dstToken}
|
|
135
|
+
dstAmount={price.toString()}
|
|
136
|
+
contractAddress={signatureData.collection.address!}
|
|
137
|
+
encodedData={encodedData}
|
|
138
|
+
metadata={{
|
|
139
|
+
type: OrderType.Custom,
|
|
140
|
+
action: "Signature Mint",
|
|
141
|
+
}}
|
|
142
|
+
header={header}
|
|
143
|
+
onSuccess={onSuccess}
|
|
144
|
+
showRecipient={true}
|
|
145
|
+
/>
|
|
146
|
+
);
|
|
147
|
+
}
|
|
@@ -12,6 +12,7 @@ import {
|
|
|
12
12
|
getPaymentUrl,
|
|
13
13
|
getStatusDisplay,
|
|
14
14
|
isNativeToken,
|
|
15
|
+
OnrampVendor,
|
|
15
16
|
Order,
|
|
16
17
|
OrderStatus,
|
|
17
18
|
OrderType,
|
|
@@ -20,7 +21,7 @@ import {
|
|
|
20
21
|
RelayTransaction,
|
|
21
22
|
zNft,
|
|
22
23
|
zToken,
|
|
23
|
-
zTournament
|
|
24
|
+
zTournament,
|
|
24
25
|
} from "@b3dotfun/sdk/anyspend";
|
|
25
26
|
import {
|
|
26
27
|
Badge,
|
|
@@ -33,8 +34,9 @@ import {
|
|
|
33
34
|
useAccountWallet,
|
|
34
35
|
useChainSwitchWithAction,
|
|
35
36
|
useModalStore,
|
|
36
|
-
useOnchainName
|
|
37
|
+
useOnchainName,
|
|
37
38
|
} from "@b3dotfun/sdk/global-account/react";
|
|
39
|
+
import { useRouter, useSearchParams } from "@b3dotfun/sdk/shared/react/hooks";
|
|
38
40
|
import { cn } from "@b3dotfun/sdk/shared/utils";
|
|
39
41
|
import centerTruncate from "@b3dotfun/sdk/shared/utils/centerTruncate";
|
|
40
42
|
import { formatTokenAmount } from "@b3dotfun/sdk/shared/utils/number";
|
|
@@ -50,9 +52,8 @@ import {
|
|
|
50
52
|
Home,
|
|
51
53
|
Loader2,
|
|
52
54
|
RefreshCcw,
|
|
53
|
-
SquareArrowOutUpRight
|
|
55
|
+
SquareArrowOutUpRight,
|
|
54
56
|
} from "lucide-react";
|
|
55
|
-
import { useRouter, useSearchParams } from "next/navigation";
|
|
56
57
|
import { QRCodeSVG } from "qrcode.react";
|
|
57
58
|
import { memo, useCallback, useEffect, useMemo, useState } from "react";
|
|
58
59
|
import TimeAgo from "react-timeago";
|
|
@@ -81,7 +82,7 @@ function getOrderSuccessText({
|
|
|
81
82
|
formattedActualDstAmount,
|
|
82
83
|
dstToken,
|
|
83
84
|
recipientName,
|
|
84
|
-
centerTruncate
|
|
85
|
+
centerTruncate,
|
|
85
86
|
}: {
|
|
86
87
|
order: Order;
|
|
87
88
|
tournament?: any;
|
|
@@ -207,7 +208,7 @@ export const OrderDetails = memo(function OrderDetails({
|
|
|
207
208
|
relayTx,
|
|
208
209
|
executeTx,
|
|
209
210
|
refundTxs,
|
|
210
|
-
onBack
|
|
211
|
+
onBack,
|
|
211
212
|
}: OrderDetailsProps) {
|
|
212
213
|
const router = useRouter();
|
|
213
214
|
const searchParams = useSearchParams();
|
|
@@ -232,23 +233,6 @@ export const OrderDetails = memo(function OrderDetails({
|
|
|
232
233
|
|
|
233
234
|
const { switchChainAndExecute, isSwitchingOrExecuting } = useChainSwitchWithAction();
|
|
234
235
|
|
|
235
|
-
// const { permitData, isCheckingPermit } = usePermitData({
|
|
236
|
-
// chainId: order.srcChain,
|
|
237
|
-
// tokenAddress: order.srcTokenAddress as Hex,
|
|
238
|
-
// ownerAddress: account?.address && isAddress(account.address) ? getAddress(account.address) : undefined,
|
|
239
|
-
// amount: BigInt(order.srcAmount)
|
|
240
|
-
// });
|
|
241
|
-
|
|
242
|
-
// const { sendPermitData } = useAnyspendSendPermitData({
|
|
243
|
-
// onSuccess: _data => {
|
|
244
|
-
// toast.info("Sent permit data successfully");
|
|
245
|
-
// },
|
|
246
|
-
// onError: error => {
|
|
247
|
-
// console.error(error);
|
|
248
|
-
// toast.error("Failed to send permit data: " + error.message);
|
|
249
|
-
// }
|
|
250
|
-
// });
|
|
251
|
-
|
|
252
236
|
const { colorMode } = useColorMode();
|
|
253
237
|
|
|
254
238
|
const roundedUpSrcAmount = useMemo(() => {
|
|
@@ -271,35 +255,6 @@ export const OrderDetails = memo(function OrderDetails({
|
|
|
271
255
|
|
|
272
256
|
console.log("Processing transaction on chain:", currentWalletClient.chain.id);
|
|
273
257
|
|
|
274
|
-
// Process transaction
|
|
275
|
-
// if (permitData?.data && account.address) {
|
|
276
|
-
// const signature = await currentWalletClient.signTypedData({
|
|
277
|
-
// domain: permitData.data.domain,
|
|
278
|
-
// types: permitData.data.types,
|
|
279
|
-
// primaryType: "Permit",
|
|
280
|
-
// message: permitData.data.messageToSign
|
|
281
|
-
// });
|
|
282
|
-
|
|
283
|
-
// // Split signature into v, r, s components
|
|
284
|
-
// const r = signature.slice(0, 66);
|
|
285
|
-
// const s = "0x" + signature.slice(66, 130);
|
|
286
|
-
// const v = parseInt(signature.slice(130, 132), 16);
|
|
287
|
-
|
|
288
|
-
// sendPermitData({
|
|
289
|
-
// isMainnet: true,
|
|
290
|
-
// orderId: order.id,
|
|
291
|
-
// permitData: {
|
|
292
|
-
// deadline: Number(permitData.data.messageToSign.deadline),
|
|
293
|
-
// ownerAddress: account.address,
|
|
294
|
-
// r,
|
|
295
|
-
// s,
|
|
296
|
-
// v
|
|
297
|
-
// }
|
|
298
|
-
// });
|
|
299
|
-
|
|
300
|
-
// return;
|
|
301
|
-
// }
|
|
302
|
-
|
|
303
258
|
const signer = currentWalletClient.account!;
|
|
304
259
|
|
|
305
260
|
// Send transaction
|
|
@@ -308,7 +263,7 @@ export const OrderDetails = memo(function OrderDetails({
|
|
|
308
263
|
account: signer,
|
|
309
264
|
chain: EVM_CHAINS[order.srcChain].viem,
|
|
310
265
|
to: order.globalAddress as `0x${string}`,
|
|
311
|
-
value: BigInt(order.srcAmount)
|
|
266
|
+
value: BigInt(order.srcAmount),
|
|
312
267
|
});
|
|
313
268
|
setTxHash(hash);
|
|
314
269
|
} else {
|
|
@@ -318,12 +273,12 @@ export const OrderDetails = memo(function OrderDetails({
|
|
|
318
273
|
address: order.srcTokenAddress as `0x${string}`,
|
|
319
274
|
abi: erc20Abi,
|
|
320
275
|
functionName: "transfer",
|
|
321
|
-
args: [order.globalAddress as Address, BigInt(order.srcAmount)]
|
|
276
|
+
args: [order.globalAddress as Address, BigInt(order.srcAmount)],
|
|
322
277
|
});
|
|
323
278
|
setTxHash(hash);
|
|
324
279
|
}
|
|
325
280
|
},
|
|
326
|
-
[order]
|
|
281
|
+
[order],
|
|
327
282
|
);
|
|
328
283
|
|
|
329
284
|
// Main payment handler that triggers chain switch and payment
|
|
@@ -339,6 +294,29 @@ export const OrderDetails = memo(function OrderDetails({
|
|
|
339
294
|
router.push(`?${params}`);
|
|
340
295
|
}, [router, searchParams]);
|
|
341
296
|
|
|
297
|
+
// Clean up URL parameters before closing modal or navigating back
|
|
298
|
+
const cleanupUrlParams = useCallback(() => {
|
|
299
|
+
const params = new URLSearchParams(searchParams.toString());
|
|
300
|
+
params.delete("waitingForDeposit");
|
|
301
|
+
params.delete("orderId");
|
|
302
|
+
|
|
303
|
+
// Only update URL if params were actually removed
|
|
304
|
+
if (params.toString() !== searchParams.toString()) {
|
|
305
|
+
router.push(`?${params}`);
|
|
306
|
+
}
|
|
307
|
+
}, [router, searchParams]);
|
|
308
|
+
|
|
309
|
+
// Helper functions that clean up URL params before executing actions
|
|
310
|
+
const handleCloseModal = useCallback(() => {
|
|
311
|
+
cleanupUrlParams();
|
|
312
|
+
setB3ModalOpen(false);
|
|
313
|
+
}, [cleanupUrlParams, setB3ModalOpen]);
|
|
314
|
+
|
|
315
|
+
const handleBack = useCallback(() => {
|
|
316
|
+
cleanupUrlParams();
|
|
317
|
+
onBack?.();
|
|
318
|
+
}, [cleanupUrlParams, onBack]);
|
|
319
|
+
|
|
342
320
|
useEffect(() => {
|
|
343
321
|
if (txSuccess) {
|
|
344
322
|
toast.success("Transaction successful! We are processing your order.", { duration: 10000 });
|
|
@@ -413,7 +391,11 @@ export const OrderDetails = memo(function OrderDetails({
|
|
|
413
391
|
? depositTxs.map(dTx => (
|
|
414
392
|
<TransactionDetails
|
|
415
393
|
key={dTx.txHash}
|
|
416
|
-
title={
|
|
394
|
+
title={
|
|
395
|
+
order.onrampMetadata?.vendor === OnrampVendor.StripeWeb2
|
|
396
|
+
? `Received payment`
|
|
397
|
+
: `Received ${formatTokenAmount(BigInt(dTx.amount), srcToken.decimals)} ${srcToken.symbol}`
|
|
398
|
+
}
|
|
417
399
|
chainId={order.srcChain}
|
|
418
400
|
tx={dTx}
|
|
419
401
|
isProcessing={false}
|
|
@@ -441,7 +423,7 @@ export const OrderDetails = memo(function OrderDetails({
|
|
|
441
423
|
)}
|
|
442
424
|
<button
|
|
443
425
|
className="bg-as-on-surface-2 text-as-secondary flex w-full items-center justify-center gap-2 rounded-lg p-2"
|
|
444
|
-
onClick={mode === "page" ?
|
|
426
|
+
onClick={mode === "page" ? handleBack : handleCloseModal}
|
|
445
427
|
>
|
|
446
428
|
{mode === "page" ? (
|
|
447
429
|
<>
|
|
@@ -471,7 +453,11 @@ export const OrderDetails = memo(function OrderDetails({
|
|
|
471
453
|
? depositTxs.map(dTxs => (
|
|
472
454
|
<TransactionDetails
|
|
473
455
|
key={dTxs.txHash}
|
|
474
|
-
title={
|
|
456
|
+
title={
|
|
457
|
+
order.onrampMetadata?.vendor === OnrampVendor.StripeWeb2
|
|
458
|
+
? `Received payment`
|
|
459
|
+
: `Received ${formatTokenAmount(BigInt(dTxs.amount), srcToken.decimals)} ${srcToken.symbol}`
|
|
460
|
+
}
|
|
475
461
|
chainId={order.srcChain}
|
|
476
462
|
tx={dTxs}
|
|
477
463
|
isProcessing={false}
|
|
@@ -517,7 +503,7 @@ export const OrderDetails = memo(function OrderDetails({
|
|
|
517
503
|
formattedActualDstAmount: formattedActualDstAmount,
|
|
518
504
|
dstToken,
|
|
519
505
|
recipientName,
|
|
520
|
-
centerTruncate
|
|
506
|
+
centerTruncate,
|
|
521
507
|
})}
|
|
522
508
|
<ExternalLink className="ml-2 h-4 w-4" />
|
|
523
509
|
</a>
|
|
@@ -530,7 +516,7 @@ export const OrderDetails = memo(function OrderDetails({
|
|
|
530
516
|
textColor="text-white"
|
|
531
517
|
className="flex w-full items-center gap-2"
|
|
532
518
|
disabled={txLoading || isSwitchingOrExecuting}
|
|
533
|
-
onClick={
|
|
519
|
+
onClick={handleCloseModal}
|
|
534
520
|
>
|
|
535
521
|
<span className="pl-4">Continue to Tournament</span>
|
|
536
522
|
<ChevronRight className="h-4 w-4" />
|
|
@@ -540,7 +526,7 @@ export const OrderDetails = memo(function OrderDetails({
|
|
|
540
526
|
{order.status === OrderStatus.Executed && (
|
|
541
527
|
<button
|
|
542
528
|
className="bg-as-on-surface-2 text-as-secondary flex w-full items-center justify-center gap-2 rounded-lg p-2"
|
|
543
|
-
onClick={mode === "page" ?
|
|
529
|
+
onClick={mode === "page" ? handleBack : handleCloseModal}
|
|
544
530
|
>
|
|
545
531
|
{mode === "page" ? (
|
|
546
532
|
<>
|
|
@@ -571,7 +557,11 @@ export const OrderDetails = memo(function OrderDetails({
|
|
|
571
557
|
? depositTxs.map(dTxs => (
|
|
572
558
|
<TransactionDetails
|
|
573
559
|
key={dTxs.txHash}
|
|
574
|
-
title={
|
|
560
|
+
title={
|
|
561
|
+
order.onrampMetadata?.vendor === OnrampVendor.StripeWeb2
|
|
562
|
+
? `Received payment`
|
|
563
|
+
: `Received ${formatTokenAmount(BigInt(dTxs.amount), srcToken.decimals)} ${srcToken.symbol}`
|
|
564
|
+
}
|
|
575
565
|
chainId={order.srcChain}
|
|
576
566
|
tx={dTxs}
|
|
577
567
|
isProcessing={false}
|
|
@@ -641,7 +631,7 @@ export const OrderDetails = memo(function OrderDetails({
|
|
|
641
631
|
formattedActualDstAmount,
|
|
642
632
|
dstToken,
|
|
643
633
|
recipientName,
|
|
644
|
-
centerTruncate
|
|
634
|
+
centerTruncate,
|
|
645
635
|
})}
|
|
646
636
|
<ExternalLink className="ml-2 h-4 w-4" />
|
|
647
637
|
</a>
|
|
@@ -654,7 +644,7 @@ export const OrderDetails = memo(function OrderDetails({
|
|
|
654
644
|
textColor="text-white"
|
|
655
645
|
className="flex w-full items-center gap-2"
|
|
656
646
|
disabled={txLoading || isSwitchingOrExecuting}
|
|
657
|
-
onClick={
|
|
647
|
+
onClick={handleCloseModal}
|
|
658
648
|
>
|
|
659
649
|
<span className="pl-4">Continue to Tournament</span>
|
|
660
650
|
<ChevronRight className="h-4 w-4" />
|
|
@@ -664,7 +654,7 @@ export const OrderDetails = memo(function OrderDetails({
|
|
|
664
654
|
{order.status === OrderStatus.Executed && (
|
|
665
655
|
<button
|
|
666
656
|
className="bg-as-on-surface-2 text-as-secondary flex w-full items-center justify-center gap-2 rounded-lg p-2"
|
|
667
|
-
onClick={mode === "page" ?
|
|
657
|
+
onClick={mode === "page" ? handleBack : handleCloseModal}
|
|
668
658
|
>
|
|
669
659
|
{mode === "page" ? (
|
|
670
660
|
<>
|
|
@@ -696,7 +686,11 @@ export const OrderDetails = memo(function OrderDetails({
|
|
|
696
686
|
{(depositTxs || []).map((dTxs, index) => (
|
|
697
687
|
<TransactionDetails
|
|
698
688
|
key={dTxs.txHash}
|
|
699
|
-
title={
|
|
689
|
+
title={
|
|
690
|
+
order.onrampMetadata?.vendor === OnrampVendor.StripeWeb2
|
|
691
|
+
? `Received payment`
|
|
692
|
+
: `Received ${formatTokenAmount(BigInt(dTxs.amount), srcToken.decimals)} ${srcToken.symbol}`
|
|
693
|
+
}
|
|
700
694
|
chainId={order.srcChain}
|
|
701
695
|
tx={dTxs}
|
|
702
696
|
isProcessing={index < (depositTxs || []).length - 1 ? false : !depositEnoughAmount}
|
|
@@ -730,7 +724,11 @@ export const OrderDetails = memo(function OrderDetails({
|
|
|
730
724
|
/>
|
|
731
725
|
) : (
|
|
732
726
|
<TransactionDetails
|
|
733
|
-
title={
|
|
727
|
+
title={
|
|
728
|
+
order.onrampMetadata?.vendor === OnrampVendor.StripeWeb2
|
|
729
|
+
? `Waiting for payment`
|
|
730
|
+
: `Waiting for deposit ${formattedDepositDeficit} ${srcToken.symbol}`
|
|
731
|
+
}
|
|
734
732
|
chainId={order.srcChain}
|
|
735
733
|
tx={null}
|
|
736
734
|
isProcessing={true}
|
|
@@ -863,7 +861,7 @@ export const OrderDetails = memo(function OrderDetails({
|
|
|
863
861
|
value={getPaymentUrl(
|
|
864
862
|
order.globalAddress,
|
|
865
863
|
BigInt(order.srcAmount),
|
|
866
|
-
order.srcTokenAddress === RELAY_ETH_ADDRESS ? "ETH" : order.srcTokenAddress
|
|
864
|
+
order.srcTokenAddress === RELAY_ETH_ADDRESS ? "ETH" : order.srcTokenAddress,
|
|
867
865
|
)}
|
|
868
866
|
className="max-w-[200px]"
|
|
869
867
|
/>
|
|
@@ -932,7 +930,7 @@ export const OrderDetails = memo(function OrderDetails({
|
|
|
932
930
|
.share({
|
|
933
931
|
title: "Complete Deposit",
|
|
934
932
|
text: "Complete your deposit on BSMNT.fun",
|
|
935
|
-
url: permalink
|
|
933
|
+
url: permalink,
|
|
936
934
|
})
|
|
937
935
|
.catch(error => console.log("Error sharing:", error));
|
|
938
936
|
} else {
|
|
@@ -1006,7 +1004,7 @@ export const OrderDetails = memo(function OrderDetails({
|
|
|
1006
1004
|
className={cn(
|
|
1007
1005
|
"h-3",
|
|
1008
1006
|
order.dstChain !== b3.id && "w-3 rounded-full",
|
|
1009
|
-
order.dstChain === b3.id && "h-4"
|
|
1007
|
+
order.dstChain === b3.id && "h-4",
|
|
1010
1008
|
)}
|
|
1011
1009
|
/>
|
|
1012
1010
|
</div>
|
|
@@ -1054,7 +1052,7 @@ export const OrderDetails = memo(function OrderDetails({
|
|
|
1054
1052
|
|
|
1055
1053
|
<button
|
|
1056
1054
|
className="bg-as-on-surface-2 text-as-secondary flex w-full items-center justify-center gap-2 rounded-lg p-2"
|
|
1057
|
-
onClick={
|
|
1055
|
+
onClick={handleBack}
|
|
1058
1056
|
>
|
|
1059
1057
|
Cancel and start over <RefreshCcw className="ml-2 h-4 w-4" />
|
|
1060
1058
|
</button>
|
|
@@ -1069,7 +1067,7 @@ function TransactionDetails({
|
|
|
1069
1067
|
chainId,
|
|
1070
1068
|
tx,
|
|
1071
1069
|
isProcessing,
|
|
1072
|
-
delay
|
|
1070
|
+
delay,
|
|
1073
1071
|
}: {
|
|
1074
1072
|
title: string;
|
|
1075
1073
|
chainId: number;
|
|
@@ -1097,7 +1095,7 @@ function TransactionDetails({
|
|
|
1097
1095
|
transition={{ duration: 0.5, ease: "easeOut", delay }}
|
|
1098
1096
|
className="bg-as-brand/70 absolute z-10 m-2 flex h-6 w-6 items-center justify-center rounded-full border border-white/30 shadow-lg shadow-purple-500/30 backdrop-blur-sm"
|
|
1099
1097
|
style={{
|
|
1100
|
-
boxShadow: "0 0 15px 5px rgba(138, 43, 226, 0.2)"
|
|
1098
|
+
boxShadow: "0 0 15px 5px rgba(138, 43, 226, 0.2)",
|
|
1101
1099
|
}}
|
|
1102
1100
|
>
|
|
1103
1101
|
<CheckIcon className="text-as-primary h-3 w-3" />
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
|
|
3
|
-
import { useAnyspendOrderHistory } from "@b3dotfun/sdk/anyspend";
|
|
3
|
+
import { useAnyspendOrderHistory } from "@b3dotfun/sdk/anyspend/react";
|
|
4
4
|
import { Button, Skeleton, useAccountWallet } from "@b3dotfun/sdk/global-account/react";
|
|
5
5
|
import { ArrowLeft, RefreshCcw } from "lucide-react";
|
|
6
6
|
import { OrderHistoryItem } from "./OrderHistoryItem";
|