thirdweb 5.29.3-nightly-476b6cc271b0891fa01fb09ca509c564b850ccfa-20240614185219 → 5.29.3-nightly-b051d844d0bb2d08b0d885d8c23e75ee97209976-20240614190954
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/exports/react.js +45 -34
- package/dist/cjs/exports/react.js.map +1 -1
- package/dist/cjs/exports/{react-native.js → react.native.js} +47 -42
- package/dist/cjs/exports/react.native.js.map +1 -0
- package/dist/cjs/exports/wallets/eip5792.js +1 -7
- package/dist/cjs/exports/wallets/eip5792.js.map +1 -1
- package/dist/cjs/exports/wallets/in-app.js +1 -1
- package/dist/cjs/exports/wallets/in-app.js.map +1 -1
- package/dist/cjs/exports/{react-native/wallets/in-app.js → wallets/in-app.native.js} +3 -3
- package/dist/cjs/exports/wallets/in-app.native.js.map +1 -0
- package/dist/cjs/exports/wallets.js +6 -5
- package/dist/cjs/exports/wallets.js.map +1 -1
- package/dist/cjs/exports/{react-native/wallets.js → wallets.native.js} +10 -10
- package/dist/cjs/exports/wallets.native.js.map +1 -0
- package/dist/cjs/react/core/connectionManager.js +9 -4
- package/dist/cjs/react/core/connectionManager.js.map +1 -1
- package/dist/cjs/react/core/hooks/auth/useSiweAuth.js +1 -3
- package/dist/cjs/react/core/hooks/auth/useSiweAuth.js.map +1 -1
- package/dist/cjs/react/core/hooks/connection/types.js +3 -0
- package/dist/cjs/react/core/hooks/connection/types.js.map +1 -0
- package/dist/cjs/react/core/hooks/transaction/transaction-button-utils.js +39 -0
- package/dist/cjs/react/core/hooks/transaction/transaction-button-utils.js.map +1 -0
- package/dist/cjs/react/core/hooks/transaction/useEstimateGas.js +12 -0
- package/dist/cjs/react/core/hooks/transaction/useEstimateGas.js.map +1 -0
- package/dist/cjs/react/core/hooks/transaction/useEstimateGasCost.js +12 -0
- package/dist/cjs/react/core/hooks/transaction/useEstimateGasCost.js.map +1 -0
- package/dist/cjs/react/core/hooks/transaction/useSendAndConfirmTransaction.js +20 -0
- package/dist/cjs/react/core/hooks/transaction/useSendAndConfirmTransaction.js.map +1 -0
- package/dist/cjs/react/core/hooks/transaction/useSendBatchTransaction.js +20 -0
- package/dist/cjs/react/core/hooks/transaction/useSendBatchTransaction.js.map +1 -0
- package/dist/cjs/react/core/hooks/{contract → transaction}/useSendTransaction.js +3 -5
- package/dist/cjs/react/core/hooks/transaction/useSendTransaction.js.map +1 -0
- package/dist/cjs/react/core/hooks/transaction/useSimulateTransaction.js +12 -0
- package/dist/cjs/react/core/hooks/transaction/useSimulateTransaction.js.map +1 -0
- package/dist/cjs/react/core/hooks/wallets/useActiveAccount.js +10 -0
- package/dist/cjs/react/core/hooks/wallets/useActiveAccount.js.map +1 -0
- package/dist/cjs/react/core/hooks/wallets/useActiveWallet.js +10 -0
- package/dist/cjs/react/core/hooks/wallets/useActiveWallet.js.map +1 -0
- package/dist/cjs/react/core/hooks/wallets/useActiveWalletChain.js +10 -0
- package/dist/cjs/react/core/hooks/wallets/useActiveWalletChain.js.map +1 -0
- package/dist/cjs/react/core/hooks/wallets/useActiveWalletConnectionStatus.js +10 -0
- package/dist/cjs/react/core/hooks/wallets/useActiveWalletConnectionStatus.js.map +1 -0
- package/dist/cjs/react/core/hooks/{connection → wallets}/useAutoConnect.js +13 -39
- package/dist/cjs/react/core/hooks/wallets/useAutoConnect.js.map +1 -0
- package/dist/cjs/react/core/hooks/wallets/useCallsStatus.js +3 -19
- package/dist/cjs/react/core/hooks/wallets/useCallsStatus.js.map +1 -1
- package/dist/cjs/react/core/hooks/wallets/useCapabilities.js +3 -20
- package/dist/cjs/react/core/hooks/wallets/useCapabilities.js.map +1 -1
- package/dist/cjs/react/core/hooks/wallets/useConnect.js +32 -0
- package/dist/cjs/react/core/hooks/wallets/useConnect.js.map +1 -0
- package/dist/cjs/react/core/hooks/wallets/useConnectedWallets.js +10 -0
- package/dist/cjs/react/core/hooks/wallets/useConnectedWallets.js.map +1 -0
- package/dist/cjs/react/core/hooks/wallets/useDisconnect.js +9 -0
- package/dist/cjs/react/core/hooks/wallets/useDisconnect.js.map +1 -0
- package/dist/cjs/react/core/hooks/wallets/useIsAutoConnecting.js +10 -0
- package/dist/cjs/react/core/hooks/wallets/useIsAutoConnecting.js.map +1 -0
- package/dist/cjs/react/core/hooks/wallets/useSendCalls.js +4 -66
- package/dist/cjs/react/core/hooks/wallets/useSendCalls.js.map +1 -1
- package/dist/cjs/react/core/hooks/wallets/useSetActiveWallet.js +8 -0
- package/dist/cjs/react/core/hooks/wallets/useSetActiveWallet.js.map +1 -0
- package/dist/cjs/react/core/hooks/wallets/useSetActiveWalletConnectionStatus.js +8 -0
- package/dist/cjs/react/core/hooks/wallets/useSetActiveWalletConnectionStatus.js.map +1 -0
- package/dist/cjs/react/core/hooks/wallets/useSwitchActiveWalletChain.js +8 -0
- package/dist/cjs/react/core/hooks/wallets/useSwitchActiveWalletChain.js.map +1 -0
- package/dist/cjs/react/{core/hooks/contract/useEstimate.js → native/hooks/transaction/useEstimateGas.js} +5 -8
- package/dist/cjs/react/native/hooks/transaction/useEstimateGas.js.map +1 -0
- package/dist/cjs/react/{core/hooks/contract → native/hooks/transaction}/useEstimateGasCost.js +2 -2
- package/dist/cjs/react/native/hooks/transaction/useEstimateGasCost.js.map +1 -0
- package/dist/cjs/react/native/hooks/transaction/useSendAndConfirmTransaction.js +24 -0
- package/dist/cjs/react/native/hooks/transaction/useSendAndConfirmTransaction.js.map +1 -0
- package/dist/cjs/react/native/hooks/transaction/useSendBatchTransaction.js +24 -0
- package/dist/cjs/react/native/hooks/transaction/useSendBatchTransaction.js.map +1 -0
- package/dist/cjs/react/native/hooks/transaction/useSendTransaction.js +33 -0
- package/dist/cjs/react/native/hooks/transaction/useSendTransaction.js.map +1 -0
- package/dist/cjs/react/native/hooks/wallets/useActiveAccount.js +21 -0
- package/dist/cjs/react/native/hooks/wallets/useActiveAccount.js.map +1 -0
- package/dist/cjs/react/native/hooks/wallets/useActiveWallet.js +21 -0
- package/dist/cjs/react/native/hooks/wallets/useActiveWallet.js.map +1 -0
- package/dist/cjs/react/native/hooks/wallets/useActiveWalletChain.js +21 -0
- package/dist/cjs/react/native/hooks/wallets/useActiveWalletChain.js.map +1 -0
- package/dist/cjs/react/native/hooks/wallets/useActiveWalletConnectionStatus.js +25 -0
- package/dist/cjs/react/native/hooks/wallets/useActiveWalletConnectionStatus.js.map +1 -0
- package/dist/cjs/react/native/hooks/wallets/useAutoConnect.js +30 -0
- package/dist/cjs/react/native/hooks/wallets/useAutoConnect.js.map +1 -0
- package/dist/cjs/react/native/hooks/wallets/useCallsStatus.js +25 -0
- package/dist/cjs/react/native/hooks/wallets/useCallsStatus.js.map +1 -0
- package/dist/cjs/react/native/hooks/wallets/useCapabilities.js +26 -0
- package/dist/cjs/react/native/hooks/wallets/useCapabilities.js.map +1 -0
- package/dist/cjs/react/native/hooks/wallets/useConnect.js +40 -0
- package/dist/cjs/react/native/hooks/wallets/useConnect.js.map +1 -0
- package/dist/cjs/react/native/hooks/wallets/useConnectedWallets.js +21 -0
- package/dist/cjs/react/native/hooks/wallets/useConnectedWallets.js.map +1 -0
- package/dist/cjs/react/native/hooks/wallets/useDisconnect.js +30 -0
- package/dist/cjs/react/native/hooks/wallets/useDisconnect.js.map +1 -0
- package/dist/cjs/react/native/hooks/wallets/useIsAutoConnecting.js +23 -0
- package/dist/cjs/react/native/hooks/wallets/useIsAutoConnecting.js.map +1 -0
- package/dist/cjs/react/native/hooks/wallets/useSendCalls.js +72 -0
- package/dist/cjs/react/native/hooks/wallets/useSendCalls.js.map +1 -0
- package/dist/cjs/react/native/hooks/wallets/useSetActiveWallet.js +24 -0
- package/dist/cjs/react/native/hooks/wallets/useSetActiveWallet.js.map +1 -0
- package/dist/cjs/react/native/hooks/wallets/useSetActiveWalletConnectionStatus.js +24 -0
- package/dist/cjs/react/native/hooks/wallets/useSetActiveWalletConnectionStatus.js.map +1 -0
- package/dist/cjs/react/native/hooks/wallets/useSwitchActiveWalletChain.js +25 -0
- package/dist/cjs/react/native/hooks/wallets/useSwitchActiveWalletChain.js.map +1 -0
- package/dist/cjs/react/native/index.js +7 -0
- package/dist/cjs/react/native/index.js.map +1 -0
- package/dist/cjs/react/{core/hooks/connection → native/ui/AutoConnect}/AutoConnect.js +3 -3
- package/dist/cjs/react/native/ui/AutoConnect/AutoConnect.js.map +1 -0
- package/dist/cjs/react/native/ui/TransactionButton/TrabsactionButton.js +7 -3
- package/dist/cjs/react/native/ui/TransactionButton/TrabsactionButton.js.map +1 -1
- package/dist/cjs/react/web/hooks/transaction/useEstimateGas.js +23 -0
- package/dist/cjs/react/web/hooks/transaction/useEstimateGas.js.map +1 -0
- package/dist/cjs/react/web/hooks/transaction/useEstimateGasCost.js +28 -0
- package/dist/cjs/react/web/hooks/transaction/useEstimateGasCost.js.map +1 -0
- package/dist/cjs/react/web/hooks/transaction/useSendAndConfirmTransaction.js +24 -0
- package/dist/cjs/react/web/hooks/transaction/useSendAndConfirmTransaction.js.map +1 -0
- package/dist/cjs/react/web/hooks/transaction/useSendBatchTransaction.js +24 -0
- package/dist/cjs/react/web/hooks/transaction/useSendBatchTransaction.js.map +1 -0
- package/dist/cjs/react/web/hooks/{useSendTransaction.js → transaction/useSendTransaction.js} +40 -30
- package/dist/cjs/react/web/hooks/transaction/useSendTransaction.js.map +1 -0
- package/dist/cjs/react/web/hooks/wallets/useActiveAccount.js +21 -0
- package/dist/cjs/react/web/hooks/wallets/useActiveAccount.js.map +1 -0
- package/dist/cjs/react/web/hooks/wallets/useActiveWallet.js +21 -0
- package/dist/cjs/react/web/hooks/wallets/useActiveWallet.js.map +1 -0
- package/dist/cjs/react/web/hooks/wallets/useActiveWalletChain.js +21 -0
- package/dist/cjs/react/web/hooks/wallets/useActiveWalletChain.js.map +1 -0
- package/dist/cjs/react/web/hooks/wallets/useActiveWalletConnectionStatus.js +25 -0
- package/dist/cjs/react/web/hooks/wallets/useActiveWalletConnectionStatus.js.map +1 -0
- package/dist/cjs/react/web/hooks/wallets/useAutoConnect.js +30 -0
- package/dist/cjs/react/web/hooks/wallets/useAutoConnect.js.map +1 -0
- package/dist/cjs/react/web/hooks/wallets/useCallsStatus.js +25 -0
- package/dist/cjs/react/web/hooks/wallets/useCallsStatus.js.map +1 -0
- package/dist/cjs/react/web/hooks/wallets/useCapabilities.js +26 -0
- package/dist/cjs/react/web/hooks/wallets/useCapabilities.js.map +1 -0
- package/dist/cjs/react/web/hooks/wallets/useConnect.js +40 -0
- package/dist/cjs/react/web/hooks/wallets/useConnect.js.map +1 -0
- package/dist/cjs/react/web/hooks/wallets/useConnectedWallets.js +21 -0
- package/dist/cjs/react/web/hooks/wallets/useConnectedWallets.js.map +1 -0
- package/dist/cjs/react/web/hooks/wallets/useDisconnect.js +30 -0
- package/dist/cjs/react/web/hooks/wallets/useDisconnect.js.map +1 -0
- package/dist/cjs/react/web/hooks/wallets/useIsAutoConnecting.js +23 -0
- package/dist/cjs/react/web/hooks/wallets/useIsAutoConnecting.js.map +1 -0
- package/dist/cjs/react/web/hooks/wallets/useSendCalls.js +72 -0
- package/dist/cjs/react/web/hooks/wallets/useSendCalls.js.map +1 -0
- package/dist/cjs/react/web/hooks/wallets/useSetActiveWallet.js +24 -0
- package/dist/cjs/react/web/hooks/wallets/useSetActiveWallet.js.map +1 -0
- package/dist/cjs/react/web/hooks/wallets/useSetActiveWalletConnectionStatus.js +24 -0
- package/dist/cjs/react/web/hooks/wallets/useSetActiveWalletConnectionStatus.js.map +1 -0
- package/dist/cjs/react/web/hooks/wallets/useSwitchActiveWalletChain.js +25 -0
- package/dist/cjs/react/web/hooks/wallets/useSwitchActiveWalletChain.js.map +1 -0
- package/dist/cjs/react/web/index.js +7 -0
- package/dist/cjs/react/web/index.js.map +1 -0
- package/dist/cjs/react/web/ui/AutoConnect/AutoConnect.js +61 -0
- package/dist/cjs/react/web/ui/AutoConnect/AutoConnect.js.map +1 -0
- package/dist/cjs/react/web/ui/ConnectWallet/ConnectButton.js +8 -5
- package/dist/cjs/react/web/ui/ConnectWallet/ConnectButton.js.map +1 -1
- package/dist/cjs/react/web/ui/ConnectWallet/Details.js +20 -16
- package/dist/cjs/react/web/ui/ConnectWallet/Details.js.map +1 -1
- package/dist/cjs/react/web/ui/ConnectWallet/Modal/ConnectEmbed.js +11 -7
- package/dist/cjs/react/web/ui/ConnectWallet/Modal/ConnectEmbed.js.map +1 -1
- package/dist/cjs/react/web/ui/ConnectWallet/Modal/ConnectModal.js +2 -2
- package/dist/cjs/react/web/ui/ConnectWallet/Modal/ConnectModal.js.map +1 -1
- package/dist/cjs/react/web/ui/ConnectWallet/Modal/ConnectModalContent.js +5 -3
- package/dist/cjs/react/web/ui/ConnectWallet/Modal/ConnectModalContent.js.map +1 -1
- package/dist/cjs/react/web/ui/ConnectWallet/Modal/SmartWalletConnectUI.js +2 -1
- package/dist/cjs/react/web/ui/ConnectWallet/Modal/SmartWalletConnectUI.js.map +1 -1
- package/dist/cjs/react/web/ui/ConnectWallet/Modal/screen.js +2 -2
- package/dist/cjs/react/web/ui/ConnectWallet/Modal/screen.js.map +1 -1
- package/dist/cjs/react/web/ui/ConnectWallet/NetworkSelector.js +5 -4
- package/dist/cjs/react/web/ui/ConnectWallet/NetworkSelector.js.map +1 -1
- package/dist/cjs/react/web/ui/ConnectWallet/screens/Buy/BuyScreen.js +4 -3
- package/dist/cjs/react/web/ui/ConnectWallet/screens/Buy/BuyScreen.js.map +1 -1
- package/dist/cjs/react/web/ui/ConnectWallet/screens/Buy/fiat/PostOnRampSwap.js +2 -2
- package/dist/cjs/react/web/ui/ConnectWallet/screens/Buy/fiat/PostOnRampSwap.js.map +1 -1
- package/dist/cjs/react/web/ui/ConnectWallet/screens/Buy/main/useBuyTxStates.js +1 -1
- package/dist/cjs/react/web/ui/ConnectWallet/screens/Buy/main/useBuyTxStates.js.map +1 -1
- package/dist/cjs/react/web/ui/ConnectWallet/screens/Buy/main/useUISelectionStates.js +2 -2
- package/dist/cjs/react/web/ui/ConnectWallet/screens/Buy/main/useUISelectionStates.js.map +1 -1
- package/dist/cjs/react/web/ui/ConnectWallet/screens/Buy/swap/ConfirmationScreen.js +11 -5
- package/dist/cjs/react/web/ui/ConnectWallet/screens/Buy/swap/ConfirmationScreen.js.map +1 -1
- package/dist/cjs/react/web/ui/ConnectWallet/screens/Buy/swap/PayWithCrypto.js +2 -2
- package/dist/cjs/react/web/ui/ConnectWallet/screens/Buy/swap/PayWithCrypto.js.map +1 -1
- package/dist/cjs/react/web/ui/ConnectWallet/screens/Buy/tx-history/BuyTxHistory.js +4 -3
- package/dist/cjs/react/web/ui/ConnectWallet/screens/Buy/tx-history/BuyTxHistory.js.map +1 -1
- package/dist/cjs/react/web/ui/ConnectWallet/screens/Buy/tx-history/useBuyTransactionsToShow.js +2 -2
- package/dist/cjs/react/web/ui/ConnectWallet/screens/Buy/tx-history/useBuyTransactionsToShow.js.map +1 -1
- package/dist/cjs/react/web/ui/ConnectWallet/screens/ReceiveFunds.js +2 -2
- package/dist/cjs/react/web/ui/ConnectWallet/screens/ReceiveFunds.js.map +1 -1
- package/dist/cjs/react/web/ui/ConnectWallet/screens/SendFunds.js +7 -6
- package/dist/cjs/react/web/ui/ConnectWallet/screens/SendFunds.js.map +1 -1
- package/dist/cjs/react/web/ui/ConnectWallet/screens/SignatureScreen.js +7 -5
- package/dist/cjs/react/web/ui/ConnectWallet/screens/SignatureScreen.js.map +1 -1
- package/dist/cjs/react/web/ui/ConnectWallet/screens/TokenSelector.js +2 -2
- package/dist/cjs/react/web/ui/ConnectWallet/screens/TokenSelector.js.map +1 -1
- package/dist/cjs/react/web/ui/ConnectWallet/screens/ViewFunds.js +4 -3
- package/dist/cjs/react/web/ui/ConnectWallet/screens/ViewFunds.js.map +1 -1
- package/dist/cjs/react/web/ui/TransactionButton/index.js +7 -3
- package/dist/cjs/react/web/ui/TransactionButton/index.js.map +1 -1
- package/dist/cjs/react/web/ui/components/SwitchNetwork.js +2 -2
- package/dist/cjs/react/web/ui/components/SwitchNetwork.js.map +1 -1
- package/dist/cjs/react/web/ui/components/WalletImage.js +6 -6
- package/dist/cjs/react/web/ui/components/WalletImage.js.map +1 -1
- package/dist/cjs/react/web/ui/hooks/useSendToken.js +6 -4
- package/dist/cjs/react/web/ui/hooks/useSendToken.js.map +1 -1
- package/dist/cjs/react/web/wallets/in-app/InAppWalletFormUI.js +2 -1
- package/dist/cjs/react/web/wallets/in-app/InAppWalletFormUI.js.map +1 -1
- package/dist/cjs/react/web/wallets/in-app/InAppWalletOTPLoginUI.js +3 -2
- package/dist/cjs/react/web/wallets/in-app/InAppWalletOTPLoginUI.js.map +1 -1
- package/dist/cjs/react/web/wallets/in-app/InAppWalletPassKeyLogin.js +3 -2
- package/dist/cjs/react/web/wallets/in-app/InAppWalletPassKeyLogin.js.map +1 -1
- package/dist/cjs/react/web/wallets/in-app/InAppWalletSocialLogin.js +2 -1
- package/dist/cjs/react/web/wallets/in-app/InAppWalletSocialLogin.js.map +1 -1
- package/dist/cjs/react/web/wallets/in-app/storage.js +2 -3
- package/dist/cjs/react/web/wallets/in-app/storage.js.map +1 -1
- package/dist/cjs/utils/storage/AsyncStorage.js.map +1 -0
- package/dist/cjs/utils/storage/nativeStorage.js.map +1 -0
- package/dist/cjs/utils/storage/walletStorage.js.map +1 -0
- package/dist/cjs/{wallets/storage/asyncLocalStorage.js → utils/storage/webStorage.js} +3 -3
- package/dist/cjs/utils/storage/webStorage.js.map +1 -0
- package/dist/cjs/version.js +1 -1
- package/dist/cjs/wallets/manager/index.js +1 -1
- package/dist/cjs/wallets/manager/index.js.map +1 -1
- package/dist/cjs/wallets/wallet-connect/controller.js +4 -3
- package/dist/cjs/wallets/wallet-connect/controller.js.map +1 -1
- package/dist/esm/exports/react.js +26 -14
- package/dist/esm/exports/react.js.map +1 -1
- package/dist/esm/exports/react.native.js +50 -0
- package/dist/esm/exports/react.native.js.map +1 -0
- package/dist/esm/exports/wallets/eip5792.js +0 -3
- package/dist/esm/exports/wallets/eip5792.js.map +1 -1
- package/dist/esm/exports/wallets/in-app.js +1 -1
- package/dist/esm/exports/wallets/in-app.js.map +1 -1
- package/dist/esm/exports/wallets/in-app.native.js +9 -0
- package/dist/esm/exports/wallets/in-app.native.js.map +1 -0
- package/dist/esm/exports/wallets.js +4 -3
- package/dist/esm/exports/wallets.js.map +1 -1
- package/dist/esm/exports/wallets.native.js +23 -0
- package/dist/esm/exports/wallets.native.js.map +1 -0
- package/dist/esm/react/core/connectionManager.js +8 -4
- package/dist/esm/react/core/connectionManager.js.map +1 -1
- package/dist/esm/react/core/hooks/auth/useSiweAuth.js +1 -3
- package/dist/esm/react/core/hooks/auth/useSiweAuth.js.map +1 -1
- package/dist/esm/react/core/hooks/connection/types.js +2 -0
- package/dist/esm/react/core/hooks/connection/types.js.map +1 -0
- package/dist/esm/react/core/hooks/transaction/transaction-button-utils.js +35 -0
- package/dist/esm/react/core/hooks/transaction/transaction-button-utils.js.map +1 -0
- package/dist/esm/react/core/hooks/transaction/useEstimateGas.js +8 -0
- package/dist/esm/react/core/hooks/transaction/useEstimateGas.js.map +1 -0
- package/dist/esm/react/core/hooks/transaction/useEstimateGasCost.js +8 -0
- package/dist/esm/react/core/hooks/transaction/useEstimateGasCost.js.map +1 -0
- package/dist/esm/react/core/hooks/transaction/useSendAndConfirmTransaction.js +16 -0
- package/dist/esm/react/core/hooks/transaction/useSendAndConfirmTransaction.js.map +1 -0
- package/dist/esm/react/core/hooks/transaction/useSendBatchTransaction.js +16 -0
- package/dist/esm/react/core/hooks/transaction/useSendBatchTransaction.js.map +1 -0
- package/dist/esm/react/core/hooks/{contract → transaction}/useSendTransaction.js +3 -5
- package/dist/esm/react/core/hooks/transaction/useSendTransaction.js.map +1 -0
- package/dist/esm/react/core/hooks/transaction/useSimulateTransaction.js +8 -0
- package/dist/esm/react/core/hooks/transaction/useSimulateTransaction.js.map +1 -0
- package/dist/esm/react/core/hooks/wallets/useActiveAccount.js +6 -0
- package/dist/esm/react/core/hooks/wallets/useActiveAccount.js.map +1 -0
- package/dist/esm/react/core/hooks/wallets/useActiveWallet.js +6 -0
- package/dist/esm/react/core/hooks/wallets/useActiveWallet.js.map +1 -0
- package/dist/esm/react/core/hooks/wallets/useActiveWalletChain.js +6 -0
- package/dist/esm/react/core/hooks/wallets/useActiveWalletChain.js.map +1 -0
- package/dist/esm/react/core/hooks/wallets/useActiveWalletConnectionStatus.js +6 -0
- package/dist/esm/react/core/hooks/wallets/useActiveWalletConnectionStatus.js.map +1 -0
- package/dist/esm/react/core/hooks/{connection → wallets}/useAutoConnect.js +11 -37
- package/dist/esm/react/core/hooks/wallets/useAutoConnect.js.map +1 -0
- package/dist/esm/react/core/hooks/wallets/useCallsStatus.js +1 -17
- package/dist/esm/react/core/hooks/wallets/useCallsStatus.js.map +1 -1
- package/dist/esm/react/core/hooks/wallets/useCapabilities.js +1 -18
- package/dist/esm/react/core/hooks/wallets/useCapabilities.js.map +1 -1
- package/dist/esm/react/core/hooks/wallets/useConnect.js +28 -0
- package/dist/esm/react/core/hooks/wallets/useConnect.js.map +1 -0
- package/dist/esm/react/core/hooks/wallets/useConnectedWallets.js +6 -0
- package/dist/esm/react/core/hooks/wallets/useConnectedWallets.js.map +1 -0
- package/dist/esm/react/core/hooks/wallets/useDisconnect.js +5 -0
- package/dist/esm/react/core/hooks/wallets/useDisconnect.js.map +1 -0
- package/dist/esm/react/core/hooks/wallets/useIsAutoConnecting.js +6 -0
- package/dist/esm/react/core/hooks/wallets/useIsAutoConnecting.js.map +1 -0
- package/dist/esm/react/core/hooks/wallets/useSendCalls.js +2 -64
- package/dist/esm/react/core/hooks/wallets/useSendCalls.js.map +1 -1
- package/dist/esm/react/core/hooks/wallets/useSetActiveWallet.js +4 -0
- package/dist/esm/react/core/hooks/wallets/useSetActiveWallet.js.map +1 -0
- package/dist/esm/react/core/hooks/wallets/useSetActiveWalletConnectionStatus.js +4 -0
- package/dist/esm/react/core/hooks/wallets/useSetActiveWalletConnectionStatus.js.map +1 -0
- package/dist/esm/react/core/hooks/wallets/useSwitchActiveWalletChain.js +4 -0
- package/dist/esm/react/core/hooks/wallets/useSwitchActiveWalletChain.js.map +1 -0
- package/dist/esm/react/{core/hooks/contract/useEstimate.js → native/hooks/transaction/useEstimateGas.js} +4 -7
- package/dist/esm/react/native/hooks/transaction/useEstimateGas.js.map +1 -0
- package/dist/esm/react/{core/hooks/contract → native/hooks/transaction}/useEstimateGasCost.js +1 -1
- package/dist/esm/react/native/hooks/transaction/useEstimateGasCost.js.map +1 -0
- package/dist/esm/react/native/hooks/transaction/useSendAndConfirmTransaction.js +20 -0
- package/dist/esm/react/native/hooks/transaction/useSendAndConfirmTransaction.js.map +1 -0
- package/dist/esm/react/native/hooks/transaction/useSendBatchTransaction.js +20 -0
- package/dist/esm/react/native/hooks/transaction/useSendBatchTransaction.js.map +1 -0
- package/dist/esm/react/native/hooks/transaction/useSendTransaction.js +29 -0
- package/dist/esm/react/native/hooks/transaction/useSendTransaction.js.map +1 -0
- package/dist/esm/react/native/hooks/wallets/useActiveAccount.js +17 -0
- package/dist/esm/react/native/hooks/wallets/useActiveAccount.js.map +1 -0
- package/dist/esm/react/native/hooks/wallets/useActiveWallet.js +17 -0
- package/dist/esm/react/native/hooks/wallets/useActiveWallet.js.map +1 -0
- package/dist/esm/react/native/hooks/wallets/useActiveWalletChain.js +17 -0
- package/dist/esm/react/native/hooks/wallets/useActiveWalletChain.js.map +1 -0
- package/dist/esm/react/native/hooks/wallets/useActiveWalletConnectionStatus.js +21 -0
- package/dist/esm/react/native/hooks/wallets/useActiveWalletConnectionStatus.js.map +1 -0
- package/dist/esm/react/native/hooks/wallets/useAutoConnect.js +26 -0
- package/dist/esm/react/native/hooks/wallets/useAutoConnect.js.map +1 -0
- package/dist/esm/react/native/hooks/wallets/useCallsStatus.js +21 -0
- package/dist/esm/react/native/hooks/wallets/useCallsStatus.js.map +1 -0
- package/dist/esm/react/native/hooks/wallets/useCapabilities.js +22 -0
- package/dist/esm/react/native/hooks/wallets/useCapabilities.js.map +1 -0
- package/dist/esm/react/native/hooks/wallets/useConnect.js +36 -0
- package/dist/esm/react/native/hooks/wallets/useConnect.js.map +1 -0
- package/dist/esm/react/native/hooks/wallets/useConnectedWallets.js +17 -0
- package/dist/esm/react/native/hooks/wallets/useConnectedWallets.js.map +1 -0
- package/dist/esm/react/native/hooks/wallets/useDisconnect.js +26 -0
- package/dist/esm/react/native/hooks/wallets/useDisconnect.js.map +1 -0
- package/dist/esm/react/native/hooks/wallets/useIsAutoConnecting.js +19 -0
- package/dist/esm/react/native/hooks/wallets/useIsAutoConnecting.js.map +1 -0
- package/dist/esm/react/native/hooks/wallets/useSendCalls.js +69 -0
- package/dist/esm/react/native/hooks/wallets/useSendCalls.js.map +1 -0
- package/dist/esm/react/native/hooks/wallets/useSetActiveWallet.js +20 -0
- package/dist/esm/react/native/hooks/wallets/useSetActiveWallet.js.map +1 -0
- package/dist/esm/react/native/hooks/wallets/useSetActiveWalletConnectionStatus.js +20 -0
- package/dist/esm/react/native/hooks/wallets/useSetActiveWalletConnectionStatus.js.map +1 -0
- package/dist/esm/react/native/hooks/wallets/useSwitchActiveWalletChain.js +21 -0
- package/dist/esm/react/native/hooks/wallets/useSwitchActiveWalletChain.js.map +1 -0
- package/dist/esm/react/native/index.js +4 -0
- package/dist/esm/react/native/index.js.map +1 -0
- package/dist/esm/react/{core/hooks/connection → native/ui/AutoConnect}/AutoConnect.js +2 -2
- package/dist/esm/react/native/ui/AutoConnect/AutoConnect.js.map +1 -0
- package/dist/esm/react/native/ui/TransactionButton/TrabsactionButton.js +7 -3
- package/dist/esm/react/native/ui/TransactionButton/TrabsactionButton.js.map +1 -1
- package/dist/esm/react/web/hooks/transaction/useEstimateGas.js +19 -0
- package/dist/esm/react/web/hooks/transaction/useEstimateGas.js.map +1 -0
- package/dist/esm/react/web/hooks/transaction/useEstimateGasCost.js +24 -0
- package/dist/esm/react/web/hooks/transaction/useEstimateGasCost.js.map +1 -0
- package/dist/esm/react/web/hooks/transaction/useSendAndConfirmTransaction.js +20 -0
- package/dist/esm/react/web/hooks/transaction/useSendAndConfirmTransaction.js.map +1 -0
- package/dist/esm/react/web/hooks/transaction/useSendBatchTransaction.js +20 -0
- package/dist/esm/react/web/hooks/transaction/useSendBatchTransaction.js.map +1 -0
- package/dist/esm/react/web/hooks/{useSendTransaction.js → transaction/useSendTransaction.js} +39 -29
- package/dist/esm/react/web/hooks/transaction/useSendTransaction.js.map +1 -0
- package/dist/esm/react/web/hooks/wallets/useActiveAccount.js +17 -0
- package/dist/esm/react/web/hooks/wallets/useActiveAccount.js.map +1 -0
- package/dist/esm/react/web/hooks/wallets/useActiveWallet.js +17 -0
- package/dist/esm/react/web/hooks/wallets/useActiveWallet.js.map +1 -0
- package/dist/esm/react/web/hooks/wallets/useActiveWalletChain.js +17 -0
- package/dist/esm/react/web/hooks/wallets/useActiveWalletChain.js.map +1 -0
- package/dist/esm/react/web/hooks/wallets/useActiveWalletConnectionStatus.js +21 -0
- package/dist/esm/react/web/hooks/wallets/useActiveWalletConnectionStatus.js.map +1 -0
- package/dist/esm/react/web/hooks/wallets/useAutoConnect.js +26 -0
- package/dist/esm/react/web/hooks/wallets/useAutoConnect.js.map +1 -0
- package/dist/esm/react/web/hooks/wallets/useCallsStatus.js +21 -0
- package/dist/esm/react/web/hooks/wallets/useCallsStatus.js.map +1 -0
- package/dist/esm/react/web/hooks/wallets/useCapabilities.js +22 -0
- package/dist/esm/react/web/hooks/wallets/useCapabilities.js.map +1 -0
- package/dist/esm/react/web/hooks/wallets/useConnect.js +36 -0
- package/dist/esm/react/web/hooks/wallets/useConnect.js.map +1 -0
- package/dist/esm/react/web/hooks/wallets/useConnectedWallets.js +17 -0
- package/dist/esm/react/web/hooks/wallets/useConnectedWallets.js.map +1 -0
- package/dist/esm/react/web/hooks/wallets/useDisconnect.js +26 -0
- package/dist/esm/react/web/hooks/wallets/useDisconnect.js.map +1 -0
- package/dist/esm/react/web/hooks/wallets/useIsAutoConnecting.js +19 -0
- package/dist/esm/react/web/hooks/wallets/useIsAutoConnecting.js.map +1 -0
- package/dist/esm/react/web/hooks/wallets/useSendCalls.js +69 -0
- package/dist/esm/react/web/hooks/wallets/useSendCalls.js.map +1 -0
- package/dist/esm/react/web/hooks/wallets/useSetActiveWallet.js +20 -0
- package/dist/esm/react/web/hooks/wallets/useSetActiveWallet.js.map +1 -0
- package/dist/esm/react/web/hooks/wallets/useSetActiveWalletConnectionStatus.js +20 -0
- package/dist/esm/react/web/hooks/wallets/useSetActiveWalletConnectionStatus.js.map +1 -0
- package/dist/esm/react/web/hooks/wallets/useSwitchActiveWalletChain.js +21 -0
- package/dist/esm/react/web/hooks/wallets/useSwitchActiveWalletChain.js.map +1 -0
- package/dist/esm/react/web/index.js +4 -0
- package/dist/esm/react/web/index.js.map +1 -0
- package/dist/esm/react/web/ui/AutoConnect/AutoConnect.js +56 -0
- package/dist/esm/react/web/ui/AutoConnect/AutoConnect.js.map +1 -0
- package/dist/esm/react/web/ui/ConnectWallet/ConnectButton.js +6 -3
- package/dist/esm/react/web/ui/ConnectWallet/ConnectButton.js.map +1 -1
- package/dist/esm/react/web/ui/ConnectWallet/Details.js +5 -1
- package/dist/esm/react/web/ui/ConnectWallet/Details.js.map +1 -1
- package/dist/esm/react/web/ui/ConnectWallet/Modal/ConnectEmbed.js +8 -4
- package/dist/esm/react/web/ui/ConnectWallet/Modal/ConnectEmbed.js.map +1 -1
- package/dist/esm/react/web/ui/ConnectWallet/Modal/ConnectModal.js +1 -1
- package/dist/esm/react/web/ui/ConnectWallet/Modal/ConnectModal.js.map +1 -1
- package/dist/esm/react/web/ui/ConnectWallet/Modal/ConnectModalContent.js +4 -2
- package/dist/esm/react/web/ui/ConnectWallet/Modal/ConnectModalContent.js.map +1 -1
- package/dist/esm/react/web/ui/ConnectWallet/Modal/SmartWalletConnectUI.js +3 -2
- package/dist/esm/react/web/ui/ConnectWallet/Modal/SmartWalletConnectUI.js.map +1 -1
- package/dist/esm/react/web/ui/ConnectWallet/Modal/screen.js +1 -1
- package/dist/esm/react/web/ui/ConnectWallet/Modal/screen.js.map +1 -1
- package/dist/esm/react/web/ui/ConnectWallet/NetworkSelector.js +2 -1
- package/dist/esm/react/web/ui/ConnectWallet/NetworkSelector.js.map +1 -1
- package/dist/esm/react/web/ui/ConnectWallet/screens/Buy/BuyScreen.js +2 -1
- package/dist/esm/react/web/ui/ConnectWallet/screens/Buy/BuyScreen.js.map +1 -1
- package/dist/esm/react/web/ui/ConnectWallet/screens/Buy/fiat/PostOnRampSwap.js +1 -1
- package/dist/esm/react/web/ui/ConnectWallet/screens/Buy/fiat/PostOnRampSwap.js.map +1 -1
- package/dist/esm/react/web/ui/ConnectWallet/screens/Buy/main/useBuyTxStates.js +1 -1
- package/dist/esm/react/web/ui/ConnectWallet/screens/Buy/main/useBuyTxStates.js.map +1 -1
- package/dist/esm/react/web/ui/ConnectWallet/screens/Buy/main/useUISelectionStates.js +1 -1
- package/dist/esm/react/web/ui/ConnectWallet/screens/Buy/swap/ConfirmationScreen.js +9 -3
- package/dist/esm/react/web/ui/ConnectWallet/screens/Buy/swap/ConfirmationScreen.js.map +1 -1
- package/dist/esm/react/web/ui/ConnectWallet/screens/Buy/swap/PayWithCrypto.js +1 -1
- package/dist/esm/react/web/ui/ConnectWallet/screens/Buy/swap/PayWithCrypto.js.map +1 -1
- package/dist/esm/react/web/ui/ConnectWallet/screens/Buy/tx-history/BuyTxHistory.js +2 -1
- package/dist/esm/react/web/ui/ConnectWallet/screens/Buy/tx-history/BuyTxHistory.js.map +1 -1
- package/dist/esm/react/web/ui/ConnectWallet/screens/Buy/tx-history/useBuyTransactionsToShow.js +1 -1
- package/dist/esm/react/web/ui/ConnectWallet/screens/Buy/tx-history/useBuyTransactionsToShow.js.map +1 -1
- package/dist/esm/react/web/ui/ConnectWallet/screens/ReceiveFunds.js +1 -1
- package/dist/esm/react/web/ui/ConnectWallet/screens/ReceiveFunds.js.map +1 -1
- package/dist/esm/react/web/ui/ConnectWallet/screens/SendFunds.js +2 -1
- package/dist/esm/react/web/ui/ConnectWallet/screens/SendFunds.js.map +1 -1
- package/dist/esm/react/web/ui/ConnectWallet/screens/SignatureScreen.js +4 -2
- package/dist/esm/react/web/ui/ConnectWallet/screens/SignatureScreen.js.map +1 -1
- package/dist/esm/react/web/ui/ConnectWallet/screens/TokenSelector.js +1 -1
- package/dist/esm/react/web/ui/ConnectWallet/screens/TokenSelector.js.map +1 -1
- package/dist/esm/react/web/ui/ConnectWallet/screens/ViewFunds.js +2 -1
- package/dist/esm/react/web/ui/ConnectWallet/screens/ViewFunds.js.map +1 -1
- package/dist/esm/react/web/ui/TransactionButton/index.js +7 -3
- package/dist/esm/react/web/ui/TransactionButton/index.js.map +1 -1
- package/dist/esm/react/web/ui/components/SwitchNetwork.js +1 -1
- package/dist/esm/react/web/ui/components/SwitchNetwork.js.map +1 -1
- package/dist/esm/react/web/ui/components/WalletImage.js +3 -3
- package/dist/esm/react/web/ui/components/WalletImage.js.map +1 -1
- package/dist/esm/react/web/ui/hooks/useSendToken.js +5 -3
- package/dist/esm/react/web/ui/hooks/useSendToken.js.map +1 -1
- package/dist/esm/react/web/wallets/in-app/InAppWalletFormUI.js +2 -1
- package/dist/esm/react/web/wallets/in-app/InAppWalletFormUI.js.map +1 -1
- package/dist/esm/react/web/wallets/in-app/InAppWalletOTPLoginUI.js +3 -2
- package/dist/esm/react/web/wallets/in-app/InAppWalletOTPLoginUI.js.map +1 -1
- package/dist/esm/react/web/wallets/in-app/InAppWalletPassKeyLogin.js +3 -2
- package/dist/esm/react/web/wallets/in-app/InAppWalletPassKeyLogin.js.map +1 -1
- package/dist/esm/react/web/wallets/in-app/InAppWalletSocialLogin.js +2 -1
- package/dist/esm/react/web/wallets/in-app/InAppWalletSocialLogin.js.map +1 -1
- package/dist/esm/react/web/wallets/in-app/storage.js +2 -3
- package/dist/esm/react/web/wallets/in-app/storage.js.map +1 -1
- package/dist/esm/utils/storage/AsyncStorage.js.map +1 -0
- package/dist/esm/utils/storage/nativeStorage.js.map +1 -0
- package/dist/esm/utils/storage/walletStorage.js.map +1 -0
- package/dist/esm/{wallets/storage/asyncLocalStorage.js → utils/storage/webStorage.js} +2 -2
- package/dist/esm/utils/storage/webStorage.js.map +1 -0
- package/dist/esm/version.js +1 -1
- package/dist/esm/wallets/manager/index.js +1 -1
- package/dist/esm/wallets/manager/index.js.map +1 -1
- package/dist/esm/wallets/wallet-connect/controller.js +4 -3
- package/dist/esm/wallets/wallet-connect/controller.js.map +1 -1
- package/dist/types/exports/react.d.ts +25 -12
- package/dist/types/exports/react.d.ts.map +1 -1
- package/dist/types/exports/react.native.d.ts +44 -0
- package/dist/types/exports/react.native.d.ts.map +1 -0
- package/dist/types/exports/wallets/eip5792.d.ts +0 -3
- package/dist/types/exports/wallets/eip5792.d.ts.map +1 -1
- package/dist/types/exports/wallets/in-app.native.d.ts +5 -0
- package/dist/types/exports/wallets/in-app.native.d.ts.map +1 -0
- package/dist/types/exports/wallets.d.ts +1 -1
- package/dist/types/exports/wallets.d.ts.map +1 -1
- package/dist/types/exports/{react-native/wallets.d.ts → wallets.native.d.ts} +20 -20
- package/dist/types/exports/wallets.native.d.ts.map +1 -0
- package/dist/types/react/core/connectionManager.d.ts +2 -1
- package/dist/types/react/core/connectionManager.d.ts.map +1 -1
- package/dist/types/react/core/hooks/auth/useSiweAuth.d.ts +2 -1
- package/dist/types/react/core/hooks/auth/useSiweAuth.d.ts.map +1 -1
- package/dist/types/react/core/hooks/connection/{AutoConnect.d.ts → types.d.ts} +1 -37
- package/dist/types/react/core/hooks/connection/types.d.ts.map +1 -0
- package/dist/types/react/core/hooks/transaction/{button-core.d.ts → transaction-button-utils.d.ts} +3 -7
- package/dist/types/react/core/hooks/transaction/transaction-button-utils.d.ts.map +1 -0
- package/dist/types/react/core/hooks/transaction/useEstimateGas.d.ts +6 -0
- package/dist/types/react/core/hooks/transaction/useEstimateGas.d.ts.map +1 -0
- package/dist/types/react/core/hooks/transaction/useEstimateGasCost.d.ts +6 -0
- package/dist/types/react/core/hooks/transaction/useEstimateGasCost.d.ts.map +1 -0
- package/dist/types/react/core/hooks/transaction/useSendAndConfirmTransaction.d.ts +6 -0
- package/dist/types/react/core/hooks/transaction/useSendAndConfirmTransaction.d.ts.map +1 -0
- package/dist/types/react/core/hooks/transaction/useSendBatchTransaction.d.ts +6 -0
- package/dist/types/react/core/hooks/transaction/useSendBatchTransaction.d.ts.map +1 -0
- package/dist/types/react/{web/hooks → core/hooks/transaction}/useSendTransaction.d.ts +27 -41
- package/dist/types/react/core/hooks/transaction/useSendTransaction.d.ts.map +1 -0
- package/dist/types/react/core/hooks/transaction/useSimulateTransaction.d.ts +5 -0
- package/dist/types/react/core/hooks/transaction/useSimulateTransaction.d.ts.map +1 -0
- package/dist/types/react/core/hooks/wallets/useActiveAccount.d.ts +3 -0
- package/dist/types/react/core/hooks/wallets/useActiveAccount.d.ts.map +1 -0
- package/dist/types/react/core/hooks/wallets/useActiveWallet.d.ts +3 -0
- package/dist/types/react/core/hooks/wallets/useActiveWallet.d.ts.map +1 -0
- package/dist/types/react/core/hooks/wallets/useActiveWalletChain.d.ts +27 -0
- package/dist/types/react/core/hooks/wallets/useActiveWalletChain.d.ts.map +1 -0
- package/dist/types/react/core/hooks/wallets/useActiveWalletConnectionStatus.d.ts +3 -0
- package/dist/types/react/core/hooks/wallets/useActiveWalletConnectionStatus.d.ts.map +1 -0
- package/dist/types/react/core/hooks/wallets/useAutoConnect.d.ts +6 -0
- package/dist/types/react/core/hooks/wallets/useAutoConnect.d.ts.map +1 -0
- package/dist/types/react/core/hooks/wallets/useCallsStatus.d.ts +3 -16
- package/dist/types/react/core/hooks/wallets/useCallsStatus.d.ts.map +1 -1
- package/dist/types/react/core/hooks/wallets/useCapabilities.d.ts +3 -17
- package/dist/types/react/core/hooks/wallets/useCapabilities.d.ts.map +1 -1
- package/dist/types/react/core/hooks/wallets/useConnect.d.ts +8 -0
- package/dist/types/react/core/hooks/wallets/useConnect.d.ts.map +1 -0
- package/dist/types/react/core/hooks/wallets/useConnectedWallets.d.ts +3 -0
- package/dist/types/react/core/hooks/wallets/useConnectedWallets.d.ts.map +1 -0
- package/dist/types/react/core/hooks/wallets/useDisconnect.d.ts +5 -0
- package/dist/types/react/core/hooks/wallets/useDisconnect.d.ts.map +1 -0
- package/dist/types/react/core/hooks/wallets/useIsAutoConnecting.d.ts +3 -0
- package/dist/types/react/core/hooks/wallets/useIsAutoConnecting.d.ts.map +1 -0
- package/dist/types/react/core/hooks/wallets/useSendCalls.d.ts +2 -63
- package/dist/types/react/core/hooks/wallets/useSendCalls.d.ts.map +1 -1
- package/dist/types/react/core/hooks/wallets/useSetActiveWallet.d.ts +3 -0
- package/dist/types/react/core/hooks/wallets/useSetActiveWallet.d.ts.map +1 -0
- package/dist/types/react/core/hooks/wallets/useSetActiveWalletConnectionStatus.d.ts +3 -0
- package/dist/types/react/core/hooks/wallets/useSetActiveWalletConnectionStatus.d.ts.map +1 -0
- package/dist/types/react/core/hooks/wallets/useSwitchActiveWalletChain.d.ts +27 -0
- package/dist/types/react/core/hooks/wallets/useSwitchActiveWalletChain.d.ts.map +1 -0
- package/dist/types/react/{core/hooks/contract/useEstimate.d.ts → native/hooks/transaction/useEstimateGas.d.ts} +3 -3
- package/dist/types/react/native/hooks/transaction/useEstimateGas.d.ts.map +1 -0
- package/dist/types/react/native/hooks/transaction/useEstimateGasCost.d.ts.map +1 -0
- package/dist/types/react/{core/hooks/contract → native/hooks/transaction}/useSendAndConfirmTransaction.d.ts +1 -1
- package/dist/types/react/native/hooks/transaction/useSendAndConfirmTransaction.d.ts.map +1 -0
- package/dist/types/react/{core/hooks/contract → native/hooks/transaction}/useSendBatchTransaction.d.ts +1 -1
- package/dist/types/react/native/hooks/transaction/useSendBatchTransaction.d.ts.map +1 -0
- package/dist/types/react/native/hooks/transaction/useSendTransaction.d.ts +64 -0
- package/dist/types/react/native/hooks/transaction/useSendTransaction.d.ts.map +1 -0
- package/dist/types/react/native/hooks/wallets/useActiveAccount.d.ts +13 -0
- package/dist/types/react/native/hooks/wallets/useActiveAccount.d.ts.map +1 -0
- package/dist/types/react/native/hooks/wallets/useActiveWallet.d.ts +13 -0
- package/dist/types/react/native/hooks/wallets/useActiveWallet.d.ts.map +1 -0
- package/dist/types/react/native/hooks/wallets/useActiveWalletChain.d.ts +37 -0
- package/dist/types/react/native/hooks/wallets/useActiveWalletChain.d.ts.map +1 -0
- package/dist/types/react/native/hooks/wallets/useActiveWalletConnectionStatus.d.ts +17 -0
- package/dist/types/react/native/hooks/wallets/useActiveWalletConnectionStatus.d.ts.map +1 -0
- package/dist/types/react/{core/hooks/connection → native/hooks/wallets}/useAutoConnect.d.ts +1 -1
- package/dist/types/react/native/hooks/wallets/useAutoConnect.d.ts.map +1 -0
- package/dist/types/react/native/hooks/wallets/useCallsStatus.d.ts +23 -0
- package/dist/types/react/native/hooks/wallets/useCallsStatus.d.ts.map +1 -0
- package/dist/types/react/native/hooks/wallets/useCapabilities.d.ts +21 -0
- package/dist/types/react/native/hooks/wallets/useCapabilities.d.ts.map +1 -0
- package/dist/types/react/native/hooks/wallets/useConnect.d.ts +37 -0
- package/dist/types/react/native/hooks/wallets/useConnect.d.ts.map +1 -0
- package/dist/types/react/native/hooks/wallets/useConnectedWallets.d.ts +13 -0
- package/dist/types/react/native/hooks/wallets/useConnectedWallets.d.ts.map +1 -0
- package/dist/types/react/native/hooks/wallets/useDisconnect.d.ts +24 -0
- package/dist/types/react/native/hooks/wallets/useDisconnect.d.ts.map +1 -0
- package/dist/types/react/native/hooks/wallets/useIsAutoConnecting.d.ts +15 -0
- package/dist/types/react/native/hooks/wallets/useIsAutoConnecting.d.ts.map +1 -0
- package/dist/types/react/native/hooks/wallets/useSendCalls.d.ts +73 -0
- package/dist/types/react/native/hooks/wallets/useSendCalls.d.ts.map +1 -0
- package/dist/types/react/native/hooks/wallets/useSetActiveWallet.d.ts +16 -0
- package/dist/types/react/native/hooks/wallets/useSetActiveWallet.d.ts.map +1 -0
- package/dist/types/react/native/hooks/wallets/useSetActiveWalletConnectionStatus.d.ts +16 -0
- package/dist/types/react/native/hooks/wallets/useSetActiveWalletConnectionStatus.d.ts.map +1 -0
- package/dist/types/react/native/hooks/wallets/useSwitchActiveWalletChain.d.ts +41 -0
- package/dist/types/react/native/hooks/wallets/useSwitchActiveWalletChain.d.ts.map +1 -0
- package/dist/types/react/native/index.d.ts +64 -0
- package/dist/types/react/native/index.d.ts.map +1 -0
- package/dist/types/react/native/ui/AutoConnect/AutoConnect.d.ts +38 -0
- package/dist/types/react/native/ui/AutoConnect/AutoConnect.d.ts.map +1 -0
- package/dist/types/react/native/ui/TransactionButton/TrabsactionButton.d.ts +1 -1
- package/dist/types/react/native/ui/TransactionButton/TrabsactionButton.d.ts.map +1 -1
- package/dist/types/react/{core/hooks/contract → web/hooks/transaction}/useEstimateGas.d.ts +3 -4
- package/dist/types/react/web/hooks/transaction/useEstimateGas.d.ts.map +1 -0
- package/dist/types/react/web/hooks/transaction/useEstimateGasCost.d.ts +19 -0
- package/dist/types/react/web/hooks/transaction/useEstimateGasCost.d.ts.map +1 -0
- package/dist/types/react/web/hooks/transaction/useSendAndConfirmTransaction.d.ts +18 -0
- package/dist/types/react/web/hooks/transaction/useSendAndConfirmTransaction.d.ts.map +1 -0
- package/dist/types/react/web/hooks/transaction/useSendBatchTransaction.d.ts +18 -0
- package/dist/types/react/web/hooks/transaction/useSendBatchTransaction.d.ts.map +1 -0
- package/dist/types/react/web/hooks/transaction/useSendTransaction.d.ts +50 -0
- package/dist/types/react/web/hooks/transaction/useSendTransaction.d.ts.map +1 -0
- package/dist/types/react/web/hooks/wallets/useActiveAccount.d.ts +13 -0
- package/dist/types/react/web/hooks/wallets/useActiveAccount.d.ts.map +1 -0
- package/dist/types/react/web/hooks/wallets/useActiveWallet.d.ts +13 -0
- package/dist/types/react/web/hooks/wallets/useActiveWallet.d.ts.map +1 -0
- package/dist/types/react/web/hooks/wallets/useActiveWalletChain.d.ts +37 -0
- package/dist/types/react/web/hooks/wallets/useActiveWalletChain.d.ts.map +1 -0
- package/dist/types/react/web/hooks/wallets/useActiveWalletConnectionStatus.d.ts +17 -0
- package/dist/types/react/web/hooks/wallets/useActiveWalletConnectionStatus.d.ts.map +1 -0
- package/dist/types/react/web/hooks/wallets/useAutoConnect.d.ts +22 -0
- package/dist/types/react/web/hooks/wallets/useAutoConnect.d.ts.map +1 -0
- package/dist/types/react/web/hooks/wallets/useCallsStatus.d.ts +23 -0
- package/dist/types/react/web/hooks/wallets/useCallsStatus.d.ts.map +1 -0
- package/dist/types/react/web/hooks/wallets/useCapabilities.d.ts +21 -0
- package/dist/types/react/web/hooks/wallets/useCapabilities.d.ts.map +1 -0
- package/dist/types/react/web/hooks/wallets/useConnect.d.ts +37 -0
- package/dist/types/react/web/hooks/wallets/useConnect.d.ts.map +1 -0
- package/dist/types/react/web/hooks/wallets/useConnectedWallets.d.ts +13 -0
- package/dist/types/react/web/hooks/wallets/useConnectedWallets.d.ts.map +1 -0
- package/dist/types/react/web/hooks/wallets/useDisconnect.d.ts +24 -0
- package/dist/types/react/web/hooks/wallets/useDisconnect.d.ts.map +1 -0
- package/dist/types/react/web/hooks/wallets/useIsAutoConnecting.d.ts +15 -0
- package/dist/types/react/web/hooks/wallets/useIsAutoConnecting.d.ts.map +1 -0
- package/dist/types/react/web/hooks/wallets/useSendCalls.d.ts +73 -0
- package/dist/types/react/web/hooks/wallets/useSendCalls.d.ts.map +1 -0
- package/dist/types/react/web/hooks/wallets/useSetActiveWallet.d.ts +16 -0
- package/dist/types/react/web/hooks/wallets/useSetActiveWallet.d.ts.map +1 -0
- package/dist/types/react/web/hooks/wallets/useSetActiveWalletConnectionStatus.d.ts +16 -0
- package/dist/types/react/web/hooks/wallets/useSetActiveWalletConnectionStatus.d.ts.map +1 -0
- package/dist/types/react/web/hooks/wallets/useSwitchActiveWalletChain.d.ts +41 -0
- package/dist/types/react/web/hooks/wallets/useSwitchActiveWalletChain.d.ts.map +1 -0
- package/dist/types/react/web/index.d.ts +64 -0
- package/dist/types/react/web/index.d.ts.map +1 -0
- package/dist/types/react/web/ui/AutoConnect/AutoConnect.d.ts +38 -0
- package/dist/types/react/web/ui/AutoConnect/AutoConnect.d.ts.map +1 -0
- package/dist/types/react/web/ui/ConnectWallet/ConnectButton.d.ts.map +1 -1
- package/dist/types/react/web/ui/ConnectWallet/Details.d.ts.map +1 -1
- package/dist/types/react/web/ui/ConnectWallet/Modal/ConnectEmbed.d.ts.map +1 -1
- package/dist/types/react/web/ui/ConnectWallet/Modal/ConnectModalContent.d.ts.map +1 -1
- package/dist/types/react/web/ui/ConnectWallet/Modal/SmartWalletConnectUI.d.ts.map +1 -1
- package/dist/types/react/web/ui/ConnectWallet/NetworkSelector.d.ts.map +1 -1
- package/dist/types/react/web/ui/ConnectWallet/screens/Buy/BuyScreen.d.ts.map +1 -1
- package/dist/types/react/web/ui/ConnectWallet/screens/Buy/swap/ConfirmationScreen.d.ts.map +1 -1
- package/dist/types/react/web/ui/ConnectWallet/screens/Buy/tx-history/BuyTxHistory.d.ts.map +1 -1
- package/dist/types/react/web/ui/ConnectWallet/screens/SendFunds.d.ts.map +1 -1
- package/dist/types/react/web/ui/ConnectWallet/screens/SignatureScreen.d.ts.map +1 -1
- package/dist/types/react/web/ui/ConnectWallet/screens/ViewFunds.d.ts.map +1 -1
- package/dist/types/react/web/ui/TransactionButton/index.d.ts +1 -1
- package/dist/types/react/web/ui/TransactionButton/index.d.ts.map +1 -1
- package/dist/types/react/web/ui/components/WalletImage.d.ts.map +1 -1
- package/dist/types/react/web/ui/hooks/useSendToken.d.ts.map +1 -1
- package/dist/types/react/web/wallets/in-app/InAppWalletFormUI.d.ts.map +1 -1
- package/dist/types/react/web/wallets/in-app/InAppWalletOTPLoginUI.d.ts.map +1 -1
- package/dist/types/react/web/wallets/in-app/InAppWalletPassKeyLogin.d.ts.map +1 -1
- package/dist/types/react/web/wallets/in-app/InAppWalletSocialLogin.d.ts.map +1 -1
- package/dist/types/react/web/wallets/in-app/storage.d.ts +2 -2
- package/dist/types/react/web/wallets/in-app/storage.d.ts.map +1 -1
- package/dist/types/utils/storage/AsyncStorage.d.ts.map +1 -0
- package/dist/types/utils/storage/nativeStorage.d.ts.map +1 -0
- package/dist/types/utils/storage/walletStorage.d.ts.map +1 -0
- package/dist/types/utils/storage/webStorage.d.ts +3 -0
- package/dist/types/utils/storage/webStorage.d.ts.map +1 -0
- package/dist/types/version.d.ts +1 -1
- package/dist/types/wallets/interfaces/wallet-data.d.ts +1 -1
- package/dist/types/wallets/interfaces/wallet-data.d.ts.map +1 -1
- package/dist/types/wallets/manager/index.d.ts +1 -1
- package/dist/types/wallets/manager/index.d.ts.map +1 -1
- package/dist/types/wallets/wallet-connect/controller.d.ts.map +1 -1
- package/package.json +9 -4
- package/src/exports/react.native.ts +87 -0
- package/src/exports/react.ts +31 -34
- package/src/exports/wallets/eip5792.ts +0 -3
- package/src/exports/{react-native/wallets/in-app.ts → wallets/in-app.native.ts} +3 -3
- package/src/exports/wallets/in-app.ts +1 -1
- package/src/exports/{react-native/wallets.ts → wallets.native.ts} +19 -19
- package/src/exports/wallets.ts +6 -4
- package/src/react/core/connectionManager.ts +13 -5
- package/src/react/core/hooks/auth/useSiweAuth.ts +5 -3
- package/src/react/core/hooks/connection/{AutoConnect.tsx → types.ts} +0 -58
- package/src/react/core/hooks/transaction/{button-core.ts → transaction-button-utils.ts} +36 -48
- package/src/react/core/hooks/transaction/useEstimateGas.ts +15 -0
- package/src/react/core/hooks/transaction/useEstimateGasCost.ts +15 -0
- package/src/react/core/hooks/transaction/useSendAndConfirmTransaction.ts +21 -0
- package/src/react/core/hooks/transaction/useSendBatchTransaction.ts +21 -0
- package/src/react/core/hooks/{contract → transaction}/useSendTransaction.ts +63 -12
- package/src/react/core/hooks/transaction/useSimulateTransaction.ts +19 -0
- package/src/react/core/hooks/wallets/useActiveAccount.ts +7 -0
- package/src/react/core/hooks/wallets/useActiveWallet.ts +7 -0
- package/src/react/core/hooks/wallets/useActiveWalletChain.ts +7 -0
- package/src/react/core/hooks/wallets/useActiveWalletConnectionStatus.ts +9 -0
- package/src/react/core/hooks/{connection → wallets}/useAutoConnect.ts +19 -41
- package/src/react/core/hooks/wallets/useCallsStatus.ts +9 -21
- package/src/react/core/hooks/wallets/useCapabilities.ts +7 -21
- package/src/react/core/hooks/wallets/useConnect.ts +40 -0
- package/src/react/core/hooks/wallets/useConnectedWallets.ts +7 -0
- package/src/react/core/hooks/wallets/useDisconnect.ts +6 -0
- package/src/react/core/hooks/wallets/useIsAutoConnecting.ts +7 -0
- package/src/react/core/hooks/wallets/useSendCalls.ts +8 -67
- package/src/react/core/hooks/wallets/useSetActiveWallet.ts +5 -0
- package/src/react/core/hooks/wallets/useSetActiveWalletConnectionStatus.ts +7 -0
- package/src/react/core/hooks/wallets/useSwitchActiveWalletChain.ts +5 -0
- package/src/react/{core/hooks/contract/useEstimate.ts → native/hooks/transaction/useEstimateGas.ts} +5 -10
- package/src/react/{core/hooks/contract → native/hooks/transaction}/useEstimateGasCost.ts +1 -1
- package/src/react/{core/hooks/contract → native/hooks/transaction}/useSendAndConfirmTransaction.ts +4 -15
- package/src/react/{core/hooks/contract → native/hooks/transaction}/useSendBatchTransaction.ts +4 -15
- package/src/react/native/hooks/transaction/useSendTransaction.tsx +32 -0
- package/src/react/native/hooks/wallets/useActiveAccount.ts +17 -0
- package/src/react/native/hooks/wallets/useActiveWallet.ts +17 -0
- package/src/react/native/hooks/wallets/useActiveWalletChain.ts +17 -0
- package/src/react/native/hooks/wallets/useActiveWalletConnectionStatus.ts +21 -0
- package/src/react/native/hooks/wallets/useAutoConnect.ts +27 -0
- package/src/react/native/hooks/wallets/useCallsStatus.ts +29 -0
- package/src/react/native/hooks/wallets/useCapabilities.ts +26 -0
- package/src/react/native/hooks/wallets/useConnect.ts +37 -0
- package/src/react/native/hooks/wallets/useConnectedWallets.ts +17 -0
- package/src/react/native/hooks/wallets/useDisconnect.ts +26 -0
- package/src/react/native/hooks/wallets/useIsAutoConnecting.ts +19 -0
- package/src/react/native/hooks/wallets/useSendCalls.ts +86 -0
- package/src/react/native/hooks/wallets/useSetActiveWallet.ts +20 -0
- package/src/react/native/hooks/wallets/useSetActiveWalletConnectionStatus.ts +20 -0
- package/src/react/native/hooks/wallets/useSwitchActiveWalletChain.ts +21 -0
- package/src/react/native/index.ts +4 -0
- package/src/react/native/ui/AutoConnect/AutoConnect.tsx +59 -0
- package/src/react/native/ui/TransactionButton/TrabsactionButton.tsx +11 -4
- package/src/react/{core/hooks/contract → web/hooks/transaction}/useEstimateGas.ts +6 -12
- package/src/react/web/hooks/transaction/useEstimateGasCost.ts +33 -0
- package/src/react/web/hooks/transaction/useSendAndConfirmTransaction.ts +27 -0
- package/src/react/web/hooks/transaction/useSendBatchTransaction.ts +27 -0
- package/src/react/web/hooks/transaction/useSendTransaction.tsx +255 -0
- package/src/react/web/hooks/wallets/useActiveAccount.ts +17 -0
- package/src/react/web/hooks/wallets/useActiveWallet.ts +17 -0
- package/src/react/web/hooks/wallets/useActiveWalletChain.ts +17 -0
- package/src/react/web/hooks/wallets/useActiveWalletConnectionStatus.ts +21 -0
- package/src/react/web/hooks/wallets/useAutoConnect.ts +27 -0
- package/src/react/web/hooks/wallets/useCallsStatus.ts +29 -0
- package/src/react/web/hooks/wallets/useCapabilities.ts +26 -0
- package/src/react/web/hooks/wallets/useConnect.ts +37 -0
- package/src/react/web/hooks/wallets/useConnectedWallets.ts +17 -0
- package/src/react/web/hooks/wallets/useDisconnect.ts +26 -0
- package/src/react/web/hooks/wallets/useIsAutoConnecting.ts +19 -0
- package/src/react/web/hooks/wallets/useSendCalls.ts +86 -0
- package/src/react/web/hooks/wallets/useSetActiveWallet.ts +20 -0
- package/src/react/web/hooks/wallets/useSetActiveWalletConnectionStatus.ts +20 -0
- package/src/react/web/hooks/wallets/useSwitchActiveWalletChain.ts +21 -0
- package/src/react/web/index.ts +4 -0
- package/src/react/web/ui/AutoConnect/AutoConnect.tsx +59 -0
- package/src/react/web/ui/ConnectWallet/ConnectButton.tsx +6 -6
- package/src/react/web/ui/ConnectWallet/Details.tsx +5 -7
- package/src/react/web/ui/ConnectWallet/Modal/ConnectEmbed.tsx +8 -7
- package/src/react/web/ui/ConnectWallet/Modal/ConnectModal.tsx +1 -1
- package/src/react/web/ui/ConnectWallet/Modal/ConnectModalContent.tsx +4 -2
- package/src/react/web/ui/ConnectWallet/Modal/SmartWalletConnectUI.tsx +8 -8
- package/src/react/web/ui/ConnectWallet/Modal/screen.tsx +1 -1
- package/src/react/web/ui/ConnectWallet/NetworkSelector.tsx +2 -4
- package/src/react/web/ui/ConnectWallet/screens/Buy/BuyScreen.tsx +2 -4
- package/src/react/web/ui/ConnectWallet/screens/Buy/fiat/PostOnRampSwap.tsx +1 -1
- package/src/react/web/ui/ConnectWallet/screens/Buy/main/useBuyTxStates.ts +1 -1
- package/src/react/web/ui/ConnectWallet/screens/Buy/main/useUISelectionStates.ts +1 -1
- package/src/react/web/ui/ConnectWallet/screens/Buy/swap/ConfirmationScreen.tsx +9 -6
- package/src/react/web/ui/ConnectWallet/screens/Buy/swap/PayWithCrypto.tsx +1 -1
- package/src/react/web/ui/ConnectWallet/screens/Buy/tx-history/BuyTxHistory.tsx +2 -4
- package/src/react/web/ui/ConnectWallet/screens/Buy/tx-history/useBuyTransactionsToShow.ts +1 -1
- package/src/react/web/ui/ConnectWallet/screens/ReceiveFunds.tsx +1 -1
- package/src/react/web/ui/ConnectWallet/screens/SendFunds.tsx +2 -4
- package/src/react/web/ui/ConnectWallet/screens/SignatureScreen.tsx +4 -5
- package/src/react/web/ui/ConnectWallet/screens/TokenSelector.tsx +1 -1
- package/src/react/web/ui/ConnectWallet/screens/ViewFunds.tsx +2 -4
- package/src/react/web/ui/TransactionButton/TransactionButton.test.tsx +5 -1
- package/src/react/web/ui/TransactionButton/index.tsx +11 -4
- package/src/react/web/ui/components/SwitchNetwork.tsx +1 -1
- package/src/react/web/ui/components/WalletImage.tsx +3 -3
- package/src/react/web/ui/hooks/useSendToken.ts +5 -3
- package/src/react/web/wallets/in-app/InAppWalletFormUI.tsx +2 -1
- package/src/react/web/wallets/in-app/InAppWalletOTPLoginUI.tsx +3 -2
- package/src/react/web/wallets/in-app/InAppWalletPassKeyLogin.tsx +3 -2
- package/src/react/web/wallets/in-app/InAppWalletSocialLogin.tsx +2 -1
- package/src/react/web/wallets/in-app/storage.ts +3 -3
- package/src/{wallets/storage/asyncLocalStorage.ts → utils/storage/webStorage.ts} +1 -1
- package/src/version.ts +1 -1
- package/src/wallets/interfaces/wallet-data.ts +1 -1
- package/src/wallets/manager/index.ts +2 -2
- package/src/wallets/wallet-connect/controller.ts +5 -4
- package/dist/cjs/exports/react-native/wallets/in-app.js.map +0 -1
- package/dist/cjs/exports/react-native/wallets.js.map +0 -1
- package/dist/cjs/exports/react-native.js.map +0 -1
- package/dist/cjs/react/core/hooks/connection/AutoConnect.js.map +0 -1
- package/dist/cjs/react/core/hooks/connection/useAutoConnect.js.map +0 -1
- package/dist/cjs/react/core/hooks/contract/useEstimate.js.map +0 -1
- package/dist/cjs/react/core/hooks/contract/useEstimateGas.js +0 -27
- package/dist/cjs/react/core/hooks/contract/useEstimateGas.js.map +0 -1
- package/dist/cjs/react/core/hooks/contract/useEstimateGasCost.js.map +0 -1
- package/dist/cjs/react/core/hooks/contract/useSendAndConfirmTransaction.js +0 -35
- package/dist/cjs/react/core/hooks/contract/useSendAndConfirmTransaction.js.map +0 -1
- package/dist/cjs/react/core/hooks/contract/useSendBatchTransaction.js +0 -35
- package/dist/cjs/react/core/hooks/contract/useSendBatchTransaction.js.map +0 -1
- package/dist/cjs/react/core/hooks/contract/useSendTransaction.js.map +0 -1
- package/dist/cjs/react/core/hooks/transaction/button-core.js +0 -52
- package/dist/cjs/react/core/hooks/transaction/button-core.js.map +0 -1
- package/dist/cjs/react/core/hooks/wallets/wallet-hooks.js +0 -246
- package/dist/cjs/react/core/hooks/wallets/wallet-hooks.js.map +0 -1
- package/dist/cjs/react/core/storage.js +0 -39
- package/dist/cjs/react/core/storage.js.map +0 -1
- package/dist/cjs/react/web/hooks/useSendTransaction.js.map +0 -1
- package/dist/cjs/wallets/storage/AsyncStorage.js.map +0 -1
- package/dist/cjs/wallets/storage/asyncLocalStorage.js.map +0 -1
- package/dist/cjs/wallets/storage/nativeStorage.js.map +0 -1
- package/dist/cjs/wallets/storage/walletStorage.js.map +0 -1
- package/dist/esm/exports/react-native/wallets/in-app.js +0 -9
- package/dist/esm/exports/react-native/wallets/in-app.js.map +0 -1
- package/dist/esm/exports/react-native/wallets.js +0 -23
- package/dist/esm/exports/react-native/wallets.js.map +0 -1
- package/dist/esm/exports/react-native.js +0 -48
- package/dist/esm/exports/react-native.js.map +0 -1
- package/dist/esm/react/core/hooks/connection/AutoConnect.js.map +0 -1
- package/dist/esm/react/core/hooks/connection/useAutoConnect.js.map +0 -1
- package/dist/esm/react/core/hooks/contract/useEstimate.js.map +0 -1
- package/dist/esm/react/core/hooks/contract/useEstimateGas.js +0 -23
- package/dist/esm/react/core/hooks/contract/useEstimateGas.js.map +0 -1
- package/dist/esm/react/core/hooks/contract/useEstimateGasCost.js.map +0 -1
- package/dist/esm/react/core/hooks/contract/useSendAndConfirmTransaction.js +0 -31
- package/dist/esm/react/core/hooks/contract/useSendAndConfirmTransaction.js.map +0 -1
- package/dist/esm/react/core/hooks/contract/useSendBatchTransaction.js +0 -31
- package/dist/esm/react/core/hooks/contract/useSendBatchTransaction.js.map +0 -1
- package/dist/esm/react/core/hooks/contract/useSendTransaction.js.map +0 -1
- package/dist/esm/react/core/hooks/transaction/button-core.js +0 -48
- package/dist/esm/react/core/hooks/transaction/button-core.js.map +0 -1
- package/dist/esm/react/core/hooks/wallets/wallet-hooks.js +0 -232
- package/dist/esm/react/core/hooks/wallets/wallet-hooks.js.map +0 -1
- package/dist/esm/react/core/storage.js +0 -34
- package/dist/esm/react/core/storage.js.map +0 -1
- package/dist/esm/react/web/hooks/useSendTransaction.js.map +0 -1
- package/dist/esm/wallets/storage/AsyncStorage.js.map +0 -1
- package/dist/esm/wallets/storage/asyncLocalStorage.js.map +0 -1
- package/dist/esm/wallets/storage/nativeStorage.js.map +0 -1
- package/dist/esm/wallets/storage/walletStorage.js.map +0 -1
- package/dist/types/exports/react-native/wallets/in-app.d.ts +0 -5
- package/dist/types/exports/react-native/wallets/in-app.d.ts.map +0 -1
- package/dist/types/exports/react-native/wallets.d.ts.map +0 -1
- package/dist/types/exports/react-native.d.ts +0 -42
- package/dist/types/exports/react-native.d.ts.map +0 -1
- package/dist/types/react/core/hooks/connection/AutoConnect.d.ts.map +0 -1
- package/dist/types/react/core/hooks/connection/useAutoConnect.d.ts.map +0 -1
- package/dist/types/react/core/hooks/contract/useEstimate.d.ts.map +0 -1
- package/dist/types/react/core/hooks/contract/useEstimateGas.d.ts.map +0 -1
- package/dist/types/react/core/hooks/contract/useEstimateGasCost.d.ts.map +0 -1
- package/dist/types/react/core/hooks/contract/useSendAndConfirmTransaction.d.ts.map +0 -1
- package/dist/types/react/core/hooks/contract/useSendBatchTransaction.d.ts.map +0 -1
- package/dist/types/react/core/hooks/contract/useSendTransaction.d.ts +0 -29
- package/dist/types/react/core/hooks/contract/useSendTransaction.d.ts.map +0 -1
- package/dist/types/react/core/hooks/transaction/button-core.d.ts.map +0 -1
- package/dist/types/react/core/hooks/wallets/wallet-hooks.d.ts +0 -233
- package/dist/types/react/core/hooks/wallets/wallet-hooks.d.ts.map +0 -1
- package/dist/types/react/core/storage.d.ts +0 -20
- package/dist/types/react/core/storage.d.ts.map +0 -1
- package/dist/types/react/web/hooks/useSendTransaction.d.ts.map +0 -1
- package/dist/types/wallets/storage/AsyncStorage.d.ts.map +0 -1
- package/dist/types/wallets/storage/asyncLocalStorage.d.ts +0 -3
- package/dist/types/wallets/storage/asyncLocalStorage.d.ts.map +0 -1
- package/dist/types/wallets/storage/nativeStorage.d.ts.map +0 -1
- package/dist/types/wallets/storage/walletStorage.d.ts.map +0 -1
- package/src/exports/react-native.ts +0 -98
- package/src/react/core/hooks/wallets/wallet-hooks.tsx +0 -248
- package/src/react/core/storage.ts +0 -39
- package/src/react/web/hooks/useSendTransaction.tsx +0 -306
- /package/dist/cjs/{wallets → utils}/storage/AsyncStorage.js +0 -0
- /package/dist/cjs/{wallets → utils}/storage/nativeStorage.js +0 -0
- /package/dist/cjs/{wallets → utils}/storage/walletStorage.js +0 -0
- /package/dist/esm/{wallets → utils}/storage/AsyncStorage.js +0 -0
- /package/dist/esm/{wallets → utils}/storage/nativeStorage.js +0 -0
- /package/dist/esm/{wallets → utils}/storage/walletStorage.js +0 -0
- /package/dist/types/react/{core/hooks/contract → native/hooks/transaction}/useEstimateGasCost.d.ts +0 -0
- /package/dist/types/{wallets → utils}/storage/AsyncStorage.d.ts +0 -0
- /package/dist/types/{wallets → utils}/storage/nativeStorage.d.ts +0 -0
- /package/dist/types/{wallets → utils}/storage/walletStorage.d.ts +0 -0
- /package/src/react/{core/hooks/connection → web/ui/AutoConnect}/AutoConnect.test.tsx +0 -0
- /package/src/{wallets → utils}/storage/AsyncStorage.ts +0 -0
- /package/src/{wallets → utils}/storage/nativeStorage.ts +0 -0
- /package/src/{wallets → utils}/storage/walletStorage.ts +0 -0
@@ -4,8 +4,8 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
4
|
exports.NoAutoConnect = exports.AutoConnect = void 0;
|
5
5
|
const jsx_runtime_1 = require("react/jsx-runtime");
|
6
6
|
const react_1 = require("react");
|
7
|
-
const
|
8
|
-
const
|
7
|
+
const useAutoConnect_js_1 = require("../../hooks/wallets/useAutoConnect.js");
|
8
|
+
const useSetActiveWalletConnectionStatus_js_1 = require("../../hooks/wallets/useSetActiveWalletConnectionStatus.js");
|
9
9
|
/**
|
10
10
|
* AutoConnect last connected wallet on page reload or revisit.
|
11
11
|
* Note: If you are using `ConnectButton` or `ConnectEmbed` components, You don't need to use this component as it is already included.
|
@@ -47,7 +47,7 @@ let noAutoConnectDone = false;
|
|
47
47
|
* @internal
|
48
48
|
*/
|
49
49
|
function NoAutoConnect() {
|
50
|
-
const setConnectionStatus = (0,
|
50
|
+
const setConnectionStatus = (0, useSetActiveWalletConnectionStatus_js_1.useSetActiveWalletConnectionStatus)();
|
51
51
|
(0, react_1.useEffect)(() => {
|
52
52
|
if (noAutoConnectDone) {
|
53
53
|
return;
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"AutoConnect.js","sourceRoot":"","sources":["../../../../../../src/react/native/ui/AutoConnect/AutoConnect.tsx"],"names":[],"mappings":";AAAA,YAAY,CAAC;;;;AACb,iCAAkC;AAElC,6EAAuE;AACvE,qHAA+G;AAE/G;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA8BG;AACH,SAAgB,WAAW,CAAC,KAAuB;IACjD,IAAA,kCAAc,EAAC,KAAK,CAAC,CAAC;IACtB,OAAO,kDAAK,CAAC;AACf,CAAC;AAHD,kCAGC;AAED,IAAI,iBAAiB,GAAG,KAAK,CAAC;AAE9B;;GAEG;AACH,SAAgB,aAAa;IAC3B,MAAM,mBAAmB,GAAG,IAAA,0EAAkC,GAAE,CAAC;IACjE,IAAA,iBAAS,EAAC,GAAG,EAAE;QACb,IAAI,iBAAiB,EAAE,CAAC;YACtB,OAAO;QACT,CAAC;QACD,iBAAiB,GAAG,IAAI,CAAC;QACzB,mBAAmB,CAAC,cAAc,CAAC,CAAC;IACtC,CAAC,CAAC,CAAC;IAEH,OAAO,IAAI,CAAC;AACd,CAAC;AAXD,sCAWC"}
|
@@ -4,7 +4,9 @@ exports.TransactionButton = void 0;
|
|
4
4
|
const jsx_runtime_1 = require("react/jsx-runtime");
|
5
5
|
const react_native_1 = require("react-native");
|
6
6
|
const CustomThemeProvider_js_1 = require("../../../core/design-system/CustomThemeProvider.js");
|
7
|
-
const
|
7
|
+
const transaction_button_utils_js_1 = require("../../../core/hooks/transaction/transaction-button-utils.js");
|
8
|
+
const useSendTransaction_js_1 = require("../../hooks/transaction/useSendTransaction.js");
|
9
|
+
const useActiveAccount_js_1 = require("../../hooks/wallets/useActiveAccount.js");
|
8
10
|
const button_js_1 = require("../components/button.js");
|
9
11
|
const spinner_js_1 = require("../components/spinner.js");
|
10
12
|
/**
|
@@ -26,9 +28,11 @@ const spinner_js_1 = require("../components/spinner.js");
|
|
26
28
|
*/
|
27
29
|
function TransactionButton(props) {
|
28
30
|
const { children, transaction, onTransactionSent, onTransactionConfirmed, onError, onClick, gasless, payModal, disabled, unstyled, ...buttonProps } = props;
|
29
|
-
const
|
31
|
+
const account = (0, useActiveAccount_js_1.useActiveAccount)();
|
32
|
+
const sendTransaction = (0, useSendTransaction_js_1.useSendTransaction)({ gasless, payModal });
|
33
|
+
const { mutate: handleClick, isPending } = (0, transaction_button_utils_js_1.useTransactionButtonMutation)(props, sendTransaction.mutateAsync);
|
30
34
|
const theme = (0, CustomThemeProvider_js_1.parseTheme)(buttonProps.theme);
|
31
|
-
return ((0, jsx_runtime_1.jsxs)(button_js_1.ThemedButton, { disabled: !account || disabled || isPending, variant: "primary", onPress: handleClick, style: buttonProps.style, theme: theme, children: [(0, jsx_runtime_1.jsx)(react_native_1.View, { style: { opacity: isPending ? 0 : 1 }, children: children }), isPending && ((0, jsx_runtime_1.jsx)(react_native_1.View, { style: {
|
35
|
+
return ((0, jsx_runtime_1.jsxs)(button_js_1.ThemedButton, { disabled: !account || disabled || isPending, variant: "primary", onPress: () => handleClick(), style: buttonProps.style, theme: theme, children: [(0, jsx_runtime_1.jsx)(react_native_1.View, { style: { opacity: isPending ? 0 : 1 }, children: children }), isPending && ((0, jsx_runtime_1.jsx)(react_native_1.View, { style: {
|
32
36
|
position: "absolute",
|
33
37
|
flex: 1,
|
34
38
|
justifyContent: "center",
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"TrabsactionButton.js","sourceRoot":"","sources":["../../../../../../src/react/native/ui/TransactionButton/TrabsactionButton.tsx"],"names":[],"mappings":";;;;AAAA,+CAAoE;AACpE,+FAAgF;AAChF,
|
1
|
+
{"version":3,"file":"TrabsactionButton.js","sourceRoot":"","sources":["../../../../../../src/react/native/ui/TransactionButton/TrabsactionButton.tsx"],"names":[],"mappings":";;;;AAAA,+CAAoE;AACpE,+FAAgF;AAChF,6GAGqE;AACrE,yFAAmF;AACnF,iFAA2E;AAC3E,uDAAuD;AACvD,yDAAyD;AAEzD;;;;;;;;;;;;;;;;GAgBG;AACH,SAAgB,iBAAiB,CAAC,KAA6B;IAC7D,MAAM,EACJ,QAAQ,EACR,WAAW,EACX,iBAAiB,EACjB,sBAAsB,EACtB,OAAO,EACP,OAAO,EACP,OAAO,EACP,QAAQ,EACR,QAAQ,EACR,QAAQ,EACR,GAAG,WAAW,EACf,GAAG,KAAK,CAAC;IACV,MAAM,OAAO,GAAG,IAAA,sCAAgB,GAAE,CAAC;IACnC,MAAM,eAAe,GAAG,IAAA,0CAAkB,EAAC,EAAE,OAAO,EAAE,QAAQ,EAAE,CAAC,CAAC;IAClE,MAAM,EAAE,MAAM,EAAE,WAAW,EAAE,SAAS,EAAE,GAAG,IAAA,0DAA4B,EACrE,KAAK,EACL,eAAe,CAAC,WAAW,CAC5B,CAAC;IACF,MAAM,KAAK,GAAG,IAAA,mCAAU,EAAC,WAAW,CAAC,KAAK,CAAC,CAAC;IAE5C,OAAO,CACL,wBAAC,wBAAY,IACX,QAAQ,EAAE,CAAC,OAAO,IAAI,QAAQ,IAAI,SAAS,EAC3C,OAAO,EAAE,SAAS,EAClB,OAAO,EAAE,GAAG,EAAE,CAAC,WAAW,EAAE,EAC5B,KAAK,EAAE,WAAW,CAAC,KAA6B,EAChD,KAAK,EAAE,KAAK,aAEZ,uBAAC,mBAAI,IAAC,KAAK,EAAE,EAAE,OAAO,EAAE,SAAS,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,EAAE,YAAG,QAAQ,GAAQ,EAC7D,SAAS,IAAI,CACZ,uBAAC,mBAAI,IACH,KAAK,EAAE;oBACL,QAAQ,EAAE,UAAU;oBACpB,IAAI,EAAE,CAAC;oBACP,cAAc,EAAE,QAAQ;oBACxB,UAAU,EAAE,QAAQ;oBACpB,GAAG,EAAE,CAAC;oBACN,MAAM,EAAE,CAAC;oBACT,MAAM,EAAE,MAAM;iBACf,YAED,uBAAC,0BAAa,IAAC,KAAK,EAAE,KAAK,CAAC,MAAM,CAAC,iBAAiB,GAAI,GACnD,CACR,IACY,CAChB,CAAC;AACJ,CAAC;AAhDD,8CAgDC"}
|
@@ -0,0 +1,23 @@
|
|
1
|
+
"use strict";
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
+
exports.useEstimateGas = void 0;
|
4
|
+
const useEstimateGas_js_1 = require("../../../core/hooks/transaction/useEstimateGas.js");
|
5
|
+
const useActiveAccount_js_1 = require("../wallets/useActiveAccount.js");
|
6
|
+
/**
|
7
|
+
* A hook to estimate the gas for a given transaction.
|
8
|
+
* @returns A mutation object to estimate gas.
|
9
|
+
* @example
|
10
|
+
* ```jsx
|
11
|
+
* import { useEstimateGas } from "thirdweb/react";
|
12
|
+
* const { mutate: estimateGas, data: gasEstimate } = useEstimateGas();
|
13
|
+
*
|
14
|
+
* // later
|
15
|
+
* const estimatedGas = await estimateGas(tx);
|
16
|
+
* ```
|
17
|
+
*/
|
18
|
+
function useEstimateGas() {
|
19
|
+
const account = (0, useActiveAccount_js_1.useActiveAccount)();
|
20
|
+
return (0, useEstimateGas_js_1.useEstimateGasCore)(account);
|
21
|
+
}
|
22
|
+
exports.useEstimateGas = useEstimateGas;
|
23
|
+
//# sourceMappingURL=useEstimateGas.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"useEstimateGas.js","sourceRoot":"","sources":["../../../../../../src/react/web/hooks/transaction/useEstimateGas.ts"],"names":[],"mappings":";;;AAGA,yFAAuF;AACvF,wEAAkE;AAElE;;;;;;;;;;;GAWG;AACH,SAAgB,cAAc;IAK5B,MAAM,OAAO,GAAG,IAAA,sCAAgB,GAAE,CAAC;IACnC,OAAO,IAAA,sCAAkB,EAAC,OAAO,CAAC,CAAC;AACrC,CAAC;AAPD,wCAOC"}
|
@@ -0,0 +1,28 @@
|
|
1
|
+
"use strict";
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
+
exports.useEstimateGasCost = void 0;
|
4
|
+
const react_query_1 = require("@tanstack/react-query");
|
5
|
+
const estimate_gas_cost_js_1 = require("../../../../transaction/actions/estimate-gas-cost.js");
|
6
|
+
const useActiveAccount_js_1 = require("../wallets/useActiveAccount.js");
|
7
|
+
/**
|
8
|
+
* A hook to estimate the gas cost in ether and wei for a given transaction.
|
9
|
+
* @returns A mutation object to estimate gas cost.
|
10
|
+
* @example
|
11
|
+
* ```jsx
|
12
|
+
* import { useEstimateGasCost } from "thirdweb/react";
|
13
|
+
* const { mutate: estimateGasCost, data: gasEstimate } = useEstimateGas();
|
14
|
+
*
|
15
|
+
* // later
|
16
|
+
* const estimatedGas = await estimateGasCost(tx);
|
17
|
+
* console.log("gas cost in ether", estimatedGas.ether);
|
18
|
+
* ```
|
19
|
+
* @transaction
|
20
|
+
*/
|
21
|
+
function useEstimateGasCost() {
|
22
|
+
const account = (0, useActiveAccount_js_1.useActiveAccount)();
|
23
|
+
return (0, react_query_1.useMutation)({
|
24
|
+
mutationFn: (transaction) => (0, estimate_gas_cost_js_1.estimateGasCost)({ transaction, account }),
|
25
|
+
});
|
26
|
+
}
|
27
|
+
exports.useEstimateGasCost = useEstimateGasCost;
|
28
|
+
//# sourceMappingURL=useEstimateGasCost.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"useEstimateGasCost.js","sourceRoot":"","sources":["../../../../../../src/react/web/hooks/transaction/useEstimateGasCost.ts"],"names":[],"mappings":";;;AAAA,uDAA4E;AAC5E,+FAG8D;AAE9D,wEAAkE;AAElE;;;;;;;;;;;;;GAaG;AACH,SAAgB,kBAAkB;IAKhC,MAAM,OAAO,GAAG,IAAA,sCAAgB,GAAE,CAAC;IAEnC,OAAO,IAAA,yBAAW,EAAC;QACjB,UAAU,EAAE,CAAC,WAAW,EAAE,EAAE,CAAC,IAAA,sCAAe,EAAC,EAAE,WAAW,EAAE,OAAO,EAAE,CAAC;KACvE,CAAC,CAAC;AACL,CAAC;AAVD,gDAUC"}
|
@@ -0,0 +1,24 @@
|
|
1
|
+
"use strict";
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
+
exports.useSendAndConfirmTransaction = void 0;
|
4
|
+
const useSendAndConfirmTransaction_js_1 = require("../../../core/hooks/transaction/useSendAndConfirmTransaction.js");
|
5
|
+
const useActiveAccount_js_1 = require("../wallets/useActiveAccount.js");
|
6
|
+
/**
|
7
|
+
* A hook to send a transaction.
|
8
|
+
* @returns A mutation object to send a transaction.
|
9
|
+
* @example
|
10
|
+
* ```jsx
|
11
|
+
* import { useSendAndConfirmTransaction } from "thirdweb/react";
|
12
|
+
* const { mutate: sendAndConfirmTx, data: transactionReceipt } = useSendAndConfirmTransaction();
|
13
|
+
*
|
14
|
+
* // later
|
15
|
+
* sendAndConfirmTx(tx);
|
16
|
+
* ```
|
17
|
+
* @transaction
|
18
|
+
*/
|
19
|
+
function useSendAndConfirmTransaction() {
|
20
|
+
const account = (0, useActiveAccount_js_1.useActiveAccount)();
|
21
|
+
return (0, useSendAndConfirmTransaction_js_1.useSendAndConfirmTransactionCore)(account);
|
22
|
+
}
|
23
|
+
exports.useSendAndConfirmTransaction = useSendAndConfirmTransaction;
|
24
|
+
//# sourceMappingURL=useSendAndConfirmTransaction.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"useSendAndConfirmTransaction.js","sourceRoot":"","sources":["../../../../../../src/react/web/hooks/transaction/useSendAndConfirmTransaction.ts"],"names":[],"mappings":";;;AAGA,qHAAmH;AACnH,wEAAkE;AAElE;;;;;;;;;;;;GAYG;AACH,SAAgB,4BAA4B;IAK1C,MAAM,OAAO,GAAG,IAAA,sCAAgB,GAAE,CAAC;IACnC,OAAO,IAAA,kEAAgC,EAAC,OAAO,CAAC,CAAC;AACnD,CAAC;AAPD,oEAOC"}
|
@@ -0,0 +1,24 @@
|
|
1
|
+
"use strict";
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
+
exports.useSendBatchTransaction = void 0;
|
4
|
+
const useSendBatchTransaction_js_1 = require("../../../core/hooks/transaction/useSendBatchTransaction.js");
|
5
|
+
const useActiveAccount_js_1 = require("../wallets/useActiveAccount.js");
|
6
|
+
/**
|
7
|
+
* A hook to send a transaction.
|
8
|
+
* @returns A mutation object to send a transaction.
|
9
|
+
* @example
|
10
|
+
* ```jsx
|
11
|
+
* import { useSendBatchTransaction } from "thirdweb/react";
|
12
|
+
* const { mutate: sendBatch, data: transactionResult } = useSendBatchTransaction();
|
13
|
+
*
|
14
|
+
* // later
|
15
|
+
* sendBatch([tx1, tx2]);
|
16
|
+
* ```
|
17
|
+
* @transaction
|
18
|
+
*/
|
19
|
+
function useSendBatchTransaction() {
|
20
|
+
const account = (0, useActiveAccount_js_1.useActiveAccount)();
|
21
|
+
return (0, useSendBatchTransaction_js_1.useSendBatchTransactionCore)(account);
|
22
|
+
}
|
23
|
+
exports.useSendBatchTransaction = useSendBatchTransaction;
|
24
|
+
//# sourceMappingURL=useSendBatchTransaction.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"useSendBatchTransaction.js","sourceRoot":"","sources":["../../../../../../src/react/web/hooks/transaction/useSendBatchTransaction.ts"],"names":[],"mappings":";;;AAGA,2GAAyG;AACzG,wEAAkE;AAElE;;;;;;;;;;;;GAYG;AACH,SAAgB,uBAAuB;IAKrC,MAAM,OAAO,GAAG,IAAA,sCAAgB,GAAE,CAAC;IACnC,OAAO,IAAA,wDAA2B,EAAC,OAAO,CAAC,CAAC;AAC9C,CAAC;AAPD,0DAOC"}
|
package/dist/cjs/react/web/hooks/{useSendTransaction.js → transaction/useSendTransaction.js}
RENAMED
@@ -4,22 +4,23 @@ exports.useSendTransaction = void 0;
|
|
4
4
|
const jsx_runtime_1 = require("react/jsx-runtime");
|
5
5
|
const react_icons_1 = require("@radix-ui/react-icons");
|
6
6
|
const react_1 = require("react");
|
7
|
-
const CustomThemeProvider_js_1 = require("
|
8
|
-
const index_js_1 = require("
|
9
|
-
const useSendTransaction_js_1 = require("
|
10
|
-
const
|
11
|
-
const
|
12
|
-
const
|
13
|
-
const
|
14
|
-
const
|
15
|
-
const
|
16
|
-
const
|
17
|
-
const
|
18
|
-
const
|
19
|
-
const
|
20
|
-
const
|
21
|
-
const
|
22
|
-
const
|
7
|
+
const CustomThemeProvider_js_1 = require("../../../core/design-system/CustomThemeProvider.js");
|
8
|
+
const index_js_1 = require("../../../core/design-system/index.js");
|
9
|
+
const useSendTransaction_js_1 = require("../../../core/hooks/transaction/useSendTransaction.js");
|
10
|
+
const RootElementContext_js_1 = require("../../../core/providers/RootElementContext.js");
|
11
|
+
const AccentFailIcon_js_1 = require("../../ui/ConnectWallet/icons/AccentFailIcon.js");
|
12
|
+
const getConnectLocale_js_1 = require("../../ui/ConnectWallet/locale/getConnectLocale.js");
|
13
|
+
const LazyBuyScreen_js_1 = require("../../ui/ConnectWallet/screens/Buy/LazyBuyScreen.js");
|
14
|
+
const BuyTxHistory_js_1 = require("../../ui/ConnectWallet/screens/Buy/tx-history/BuyTxHistory.js");
|
15
|
+
const Modal_js_1 = require("../../ui/components/Modal.js");
|
16
|
+
const Spacer_js_1 = require("../../ui/components/Spacer.js");
|
17
|
+
const Spinner_js_1 = require("../../ui/components/Spinner.js");
|
18
|
+
const basic_js_1 = require("../../ui/components/basic.js");
|
19
|
+
const buttons_js_1 = require("../../ui/components/buttons.js");
|
20
|
+
const text_js_1 = require("../../ui/components/text.js");
|
21
|
+
const LoadingScreen_js_1 = require("../../wallets/shared/LoadingScreen.js");
|
22
|
+
const useActiveWallet_js_1 = require("../wallets/useActiveWallet.js");
|
23
|
+
const useSwitchActiveWalletChain_js_1 = require("../wallets/useSwitchActiveWalletChain.js");
|
23
24
|
/**
|
24
25
|
* A hook to send a transaction.
|
25
26
|
* @returns A mutation object to send a transaction.
|
@@ -37,7 +38,9 @@ const LoadingScreen_js_1 = require("../wallets/shared/LoadingScreen.js");
|
|
37
38
|
* @transaction
|
38
39
|
*/
|
39
40
|
function useSendTransaction(config = {}) {
|
40
|
-
const activeWallet = (0,
|
41
|
+
const activeWallet = (0, useActiveWallet_js_1.useActiveWallet)();
|
42
|
+
const switchChain = (0, useSwitchActiveWalletChain_js_1.useSwitchActiveWalletChain)();
|
43
|
+
const wallet = (0, useActiveWallet_js_1.useActiveWallet)();
|
41
44
|
const payModal = config.payModal;
|
42
45
|
let payModalEnabled = true;
|
43
46
|
if (payModal === false || config.gasless) {
|
@@ -54,17 +57,22 @@ function useSendTransaction(config = {}) {
|
|
54
57
|
}
|
55
58
|
}
|
56
59
|
const setRootEl = (0, react_1.useContext)(RootElementContext_js_1.SetRootElementContext);
|
57
|
-
return (0, useSendTransaction_js_1.useSendTransactionCore)(
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
|
66
|
-
|
67
|
-
|
60
|
+
return (0, useSendTransaction_js_1.useSendTransactionCore)({
|
61
|
+
showPayModal: !payModalEnabled || payModal === false
|
62
|
+
? undefined
|
63
|
+
: (data) => {
|
64
|
+
setRootEl((0, jsx_runtime_1.jsx)(TxModal, { tx: data.tx, onComplete: data.sendTx, onClose: () => {
|
65
|
+
setRootEl(null);
|
66
|
+
data.rejectTx();
|
67
|
+
}, client: data.tx.client, localeId: payModal?.locale || "en_US", supportedTokens: payModal?.supportedTokens, theme: payModal?.theme || "dark", txCostWei: data.totalCostWei, walletBalanceWei: data.walletBalance.value, nativeTokenSymbol: data.walletBalance.symbol, payOptions: {
|
68
|
+
buyWithCrypto: payModal?.buyWithCrypto,
|
69
|
+
buyWithFiat: payModal?.buyWithFiat,
|
70
|
+
} }));
|
71
|
+
},
|
72
|
+
gasless: config.gasless,
|
73
|
+
switchChain,
|
74
|
+
wallet,
|
75
|
+
});
|
68
76
|
}
|
69
77
|
exports.useSendTransaction = useSendTransaction;
|
70
78
|
function TxModal(props) {
|
@@ -102,7 +110,9 @@ function ModalContent(props) {
|
|
102
110
|
} }));
|
103
111
|
}
|
104
112
|
function ExecutingTxScreen(props) {
|
105
|
-
const sendTxCore = (
|
113
|
+
const sendTxCore = useSendTransaction({
|
114
|
+
payModal: false,
|
115
|
+
});
|
106
116
|
const [status, setStatus] = (0, react_1.useState)("loading");
|
107
117
|
const sendTx = (0, react_1.useCallback)(async () => {
|
108
118
|
setStatus("loading");
|
@@ -123,6 +133,6 @@ function ExecutingTxScreen(props) {
|
|
123
133
|
done.current = true;
|
124
134
|
sendTx();
|
125
135
|
}, [sendTx]);
|
126
|
-
return ((0, jsx_runtime_1.jsxs)(basic_js_1.Container, { p: "lg", children: [(0, jsx_runtime_1.jsx)(basic_js_1.ModalHeader, { title: "Transaction" }), (0, jsx_runtime_1.jsx)(Spacer_js_1.Spacer, { y: "xxl" }), (0, jsx_runtime_1.jsx)(Spacer_js_1.Spacer, { y: "xxl" }), (0, jsx_runtime_1.jsxs)(basic_js_1.Container, { flex: "row", center: "x", children: [status === "loading" && (0, jsx_runtime_1.jsx)(Spinner_js_1.Spinner, { size: "3xl", color: "accentText" }), status === "failed" && (0, jsx_runtime_1.jsx)(AccentFailIcon_js_1.AccentFailIcon, { size: index_js_1.iconSize["3xl"] }), status === "sent" && ((0, jsx_runtime_1.jsx)(basic_js_1.Container, { color: "success", flex: "row", center: "both", children: (0, jsx_runtime_1.jsx)(react_icons_1.CheckCircledIcon, { width: index_js_1.iconSize["3xl"], height: index_js_1.iconSize["3xl"] }) }))] }), (0, jsx_runtime_1.jsx)(Spacer_js_1.Spacer, { y: "lg" }), (0, jsx_runtime_1.
|
136
|
+
return ((0, jsx_runtime_1.jsxs)(basic_js_1.Container, { p: "lg", children: [(0, jsx_runtime_1.jsx)(basic_js_1.ModalHeader, { title: "Transaction" }), (0, jsx_runtime_1.jsx)(Spacer_js_1.Spacer, { y: "xxl" }), (0, jsx_runtime_1.jsx)(Spacer_js_1.Spacer, { y: "xxl" }), (0, jsx_runtime_1.jsxs)(basic_js_1.Container, { flex: "row", center: "x", children: [status === "loading" && (0, jsx_runtime_1.jsx)(Spinner_js_1.Spinner, { size: "3xl", color: "accentText" }), "status === \"failed\" && ", (0, jsx_runtime_1.jsx)(AccentFailIcon_js_1.AccentFailIcon, { size: index_js_1.iconSize["3xl"] }), "status === \"sent\" && (", (0, jsx_runtime_1.jsx)(basic_js_1.Container, { color: "success", flex: "row", center: "both", children: (0, jsx_runtime_1.jsx)(react_icons_1.CheckCircledIcon, { width: index_js_1.iconSize["3xl"], height: index_js_1.iconSize["3xl"] }) }), ")"] }), (0, jsx_runtime_1.jsx)(Spacer_js_1.Spacer, { y: "lg" }), (0, jsx_runtime_1.jsx)(text_js_1.Text, { color: "primaryText", center: true, size: "lg", children: "status === \"loading\" && \"Sending transaction\"status === \"failed\" && \"Transaction failed\"status === \"sent\" && \"Transaction sent\"" }), (0, jsx_runtime_1.jsx)(Spacer_js_1.Spacer, { y: "xxl" }), (0, jsx_runtime_1.jsx)(Spacer_js_1.Spacer, { y: "xxl" }), "status === \"failed\" && (", (0, jsx_runtime_1.jsx)(buttons_js_1.Button, { variant: "accent", fullWidth: true, onClick: sendTx, children: "Try Again" }), ")status === \"sent\" && (", (0, jsx_runtime_1.jsx)(buttons_js_1.Button, { variant: "accent", fullWidth: true, onClick: props.closeModal, children: "Done" }), ")"] }));
|
127
137
|
}
|
128
138
|
//# sourceMappingURL=useSendTransaction.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"useSendTransaction.js","sourceRoot":"","sources":["../../../../../../src/react/web/hooks/transaction/useSendTransaction.tsx"],"names":[],"mappings":"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"}
|
@@ -0,0 +1,21 @@
|
|
1
|
+
"use strict";
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
+
exports.useActiveAccount = void 0;
|
4
|
+
const useActiveAccount_js_1 = require("../../../core/hooks/wallets/useActiveAccount.js");
|
5
|
+
const index_js_1 = require("../../index.js");
|
6
|
+
/**
|
7
|
+
* A hook that returns the active account
|
8
|
+
* @returns The active `Account` or `undefined` if no active account is set.
|
9
|
+
* @example
|
10
|
+
* ```jsx
|
11
|
+
* import { useActiveAccount } from "thirdweb/react";
|
12
|
+
*
|
13
|
+
* const activeAccount = useActiveAccount();
|
14
|
+
* ```
|
15
|
+
* @walletConnection
|
16
|
+
*/
|
17
|
+
function useActiveAccount() {
|
18
|
+
return (0, useActiveAccount_js_1.useActiveAccountCore)(index_js_1.connectionManager);
|
19
|
+
}
|
20
|
+
exports.useActiveAccount = useActiveAccount;
|
21
|
+
//# sourceMappingURL=useActiveAccount.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"useActiveAccount.js","sourceRoot":"","sources":["../../../../../../src/react/web/hooks/wallets/useActiveAccount.ts"],"names":[],"mappings":";;;AAAA,yFAAuF;AACvF,6CAAmD;AAEnD;;;;;;;;;;GAUG;AACH,SAAgB,gBAAgB;IAC9B,OAAO,IAAA,0CAAoB,EAAC,4BAAiB,CAAC,CAAC;AACjD,CAAC;AAFD,4CAEC"}
|
@@ -0,0 +1,21 @@
|
|
1
|
+
"use strict";
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
+
exports.useActiveWallet = void 0;
|
4
|
+
const useActiveWallet_js_1 = require("../../../core/hooks/wallets/useActiveWallet.js");
|
5
|
+
const index_js_1 = require("../../index.js");
|
6
|
+
/**
|
7
|
+
* A hook that returns the active wallet
|
8
|
+
* @returns The active `Wallet` or `undefined` if no active wallet is set.
|
9
|
+
* @example
|
10
|
+
* ```jsx
|
11
|
+
* import { useActiveWallet } from "thirdweb/react";
|
12
|
+
*
|
13
|
+
* const wallet = useActiveWallet();
|
14
|
+
* ```
|
15
|
+
* @walletConnection
|
16
|
+
*/
|
17
|
+
function useActiveWallet() {
|
18
|
+
return (0, useActiveWallet_js_1.useActiveWalletCore)(index_js_1.connectionManager);
|
19
|
+
}
|
20
|
+
exports.useActiveWallet = useActiveWallet;
|
21
|
+
//# sourceMappingURL=useActiveWallet.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"useActiveWallet.js","sourceRoot":"","sources":["../../../../../../src/react/web/hooks/wallets/useActiveWallet.ts"],"names":[],"mappings":";;;AAAA,uFAAqF;AACrF,6CAAmD;AAEnD;;;;;;;;;;GAUG;AACH,SAAgB,eAAe;IAC7B,OAAO,IAAA,wCAAmB,EAAC,4BAAiB,CAAC,CAAC;AAChD,CAAC;AAFD,0CAEC"}
|
@@ -0,0 +1,21 @@
|
|
1
|
+
"use strict";
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
+
exports.useActiveWalletChain = void 0;
|
4
|
+
const useActiveWalletChain_js_1 = require("../../../core/hooks/wallets/useActiveWalletChain.js");
|
5
|
+
const index_js_1 = require("../../index.js");
|
6
|
+
/**
|
7
|
+
* A hook that returns the chain the active wallet is connected to
|
8
|
+
* @returns The chain the active wallet is connected to or null if no active wallet.
|
9
|
+
* @example
|
10
|
+
* ```jsx
|
11
|
+
* import { useActiveWalletChain } from "thirdweb/react";
|
12
|
+
*
|
13
|
+
* const chainId = useActiveWalletChain();
|
14
|
+
* ```
|
15
|
+
* @walletConnection
|
16
|
+
*/
|
17
|
+
function useActiveWalletChain() {
|
18
|
+
return (0, useActiveWalletChain_js_1.useActiveWalletChainCore)(index_js_1.connectionManager);
|
19
|
+
}
|
20
|
+
exports.useActiveWalletChain = useActiveWalletChain;
|
21
|
+
//# sourceMappingURL=useActiveWalletChain.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"useActiveWalletChain.js","sourceRoot":"","sources":["../../../../../../src/react/web/hooks/wallets/useActiveWalletChain.ts"],"names":[],"mappings":";;;AAAA,iGAA+F;AAC/F,6CAAmD;AAEnD;;;;;;;;;;GAUG;AACH,SAAgB,oBAAoB;IAClC,OAAO,IAAA,kDAAwB,EAAC,4BAAiB,CAAC,CAAC;AACrD,CAAC;AAFD,oDAEC"}
|
@@ -0,0 +1,25 @@
|
|
1
|
+
"use strict";
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
+
exports.useActiveWalletConnectionStatus = void 0;
|
4
|
+
const useActiveWalletConnectionStatus_js_1 = require("../../../core/hooks/wallets/useActiveWalletConnectionStatus.js");
|
5
|
+
const index_js_1 = require("../../index.js");
|
6
|
+
/**
|
7
|
+
* A hook that returns the active account's connection status.
|
8
|
+
* @example
|
9
|
+
* ```jsx
|
10
|
+
* import { useActiveWalletConnectionStatus } from "thirdweb/react";
|
11
|
+
*
|
12
|
+
* function Example() {
|
13
|
+
* const status = useActiveWalletConnectionStatus();
|
14
|
+
* console.log(status);
|
15
|
+
* return <div> ... </div>;
|
16
|
+
* }
|
17
|
+
* ```
|
18
|
+
* @returns The active wallet's connection status.
|
19
|
+
* @walletConnection
|
20
|
+
*/
|
21
|
+
function useActiveWalletConnectionStatus() {
|
22
|
+
return (0, useActiveWalletConnectionStatus_js_1.useActiveWalletConnectionStatusCore)(index_js_1.connectionManager);
|
23
|
+
}
|
24
|
+
exports.useActiveWalletConnectionStatus = useActiveWalletConnectionStatus;
|
25
|
+
//# sourceMappingURL=useActiveWalletConnectionStatus.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"useActiveWalletConnectionStatus.js","sourceRoot":"","sources":["../../../../../../src/react/web/hooks/wallets/useActiveWalletConnectionStatus.ts"],"names":[],"mappings":";;;AAAA,uHAAqH;AACrH,6CAAmD;AAEnD;;;;;;;;;;;;;;GAcG;AACH,SAAgB,+BAA+B;IAC7C,OAAO,IAAA,wEAAmC,EAAC,4BAAiB,CAAC,CAAC;AAChE,CAAC;AAFD,0EAEC"}
|
@@ -0,0 +1,30 @@
|
|
1
|
+
"use strict";
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
+
exports.useAutoConnect = void 0;
|
4
|
+
const nativeStorage_js_1 = require("../../../../utils/storage/nativeStorage.js");
|
5
|
+
const useAutoConnect_js_1 = require("../../../core/hooks/wallets/useAutoConnect.js");
|
6
|
+
const index_js_1 = require("../../index.js");
|
7
|
+
/**
|
8
|
+
* Autoconnect the last previously connected wallet.
|
9
|
+
*
|
10
|
+
* @example
|
11
|
+
* ```tsx
|
12
|
+
* import { useAutoConnect } from "thirdweb/react";
|
13
|
+
*
|
14
|
+
* const { data: autoConnected, isLoading } = useAutoConnect({
|
15
|
+
* client,
|
16
|
+
* accountAbstraction,
|
17
|
+
* wallets,
|
18
|
+
* onConnect,
|
19
|
+
* timeout,
|
20
|
+
* });
|
21
|
+
* ```
|
22
|
+
* @walletConnection
|
23
|
+
* @param props - The props for auto connect.
|
24
|
+
* @returns whether the auto connect was successful.
|
25
|
+
*/
|
26
|
+
function useAutoConnect(props) {
|
27
|
+
return (0, useAutoConnect_js_1.useAutoConnectCore)(index_js_1.connectionManager, nativeStorage_js_1.nativeLocalStorage, props);
|
28
|
+
}
|
29
|
+
exports.useAutoConnect = useAutoConnect;
|
30
|
+
//# sourceMappingURL=useAutoConnect.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"useAutoConnect.js","sourceRoot":"","sources":["../../../../../../src/react/web/hooks/wallets/useAutoConnect.ts"],"names":[],"mappings":";;;AAAA,iFAAgF;AAEhF,qFAAmF;AACnF,6CAAmD;AAEnD;;;;;;;;;;;;;;;;;;GAkBG;AACH,SAAgB,cAAc,CAAC,KAAuB;IACpD,OAAO,IAAA,sCAAkB,EAAC,4BAAiB,EAAE,qCAAkB,EAAE,KAAK,CAAC,CAAC;AAC1E,CAAC;AAFD,wCAEC"}
|
@@ -0,0 +1,25 @@
|
|
1
|
+
"use strict";
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
+
exports.useCallsStatus = void 0;
|
4
|
+
const useCallsStatus_js_1 = require("../../../core/hooks/wallets/useCallsStatus.js");
|
5
|
+
const useActiveWallet_js_1 = require("./useActiveWallet.js");
|
6
|
+
/**
|
7
|
+
* A hook to get a call bundle's current status according to [EIP-5792](https://eips.ethereum.org/EIPS/eip-5792).
|
8
|
+
*
|
9
|
+
* @note This function is dependent on the wallet's support for EIP-5792 and could throw an error if it's not supported.
|
10
|
+
*
|
11
|
+
* @returns a React Query object.
|
12
|
+
* @beta
|
13
|
+
* @example
|
14
|
+
* ```tsx
|
15
|
+
* import { useCallsStatus } from "thirdweb/react";
|
16
|
+
* const { data: status, isLoading } = useCallsStatus({ bundleId, client });
|
17
|
+
* ```
|
18
|
+
* @extension EIP5792
|
19
|
+
*/
|
20
|
+
function useCallsStatus(options) {
|
21
|
+
const wallet = (0, useActiveWallet_js_1.useActiveWallet)();
|
22
|
+
return (0, useCallsStatus_js_1.useCallsStatusCore)(options, wallet);
|
23
|
+
}
|
24
|
+
exports.useCallsStatus = useCallsStatus;
|
25
|
+
//# sourceMappingURL=useCallsStatus.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"useCallsStatus.js","sourceRoot":"","sources":["../../../../../../src/react/web/hooks/wallets/useCallsStatus.ts"],"names":[],"mappings":";;;AAGA,qFAAmF;AACnF,6DAAuD;AAEvD;;;;;;;;;;;;;GAaG;AACH,SAAgB,cAAc,CAAC,OAI9B;IACC,MAAM,MAAM,GAAG,IAAA,oCAAe,GAAE,CAAC;IAEjC,OAAO,IAAA,sCAAkB,EAAC,OAAO,EAAE,MAAM,CAAC,CAAC;AAC7C,CAAC;AARD,wCAQC"}
|
@@ -0,0 +1,26 @@
|
|
1
|
+
"use strict";
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
+
exports.useCapabilities = void 0;
|
4
|
+
const useCapabilities_js_1 = require("../../../core/hooks/wallets/useCapabilities.js");
|
5
|
+
const useActiveWallet_js_1 = require("./useActiveWallet.js");
|
6
|
+
/**
|
7
|
+
* A hook to get the current wallet's capabilities according to [EIP-5792](https://eips.ethereum.org/EIPS/eip-5792).
|
8
|
+
*
|
9
|
+
* @note This function is dependent on the wallet's support for EIP-5792, but will not throw.
|
10
|
+
* **The returned object contains a `message` field detailing any issues with the wallet's support for EIP-5792.**
|
11
|
+
*
|
12
|
+
* @returns a React Query object.
|
13
|
+
* @beta
|
14
|
+
* @example
|
15
|
+
* ```tsx
|
16
|
+
* import { useCapabilities } from "thirdweb/react";
|
17
|
+
* const { data: capabilities, isLoading } = useCapabilities();
|
18
|
+
* ```
|
19
|
+
* @extension EIP5792
|
20
|
+
*/
|
21
|
+
function useCapabilities(options) {
|
22
|
+
const wallet = (0, useActiveWallet_js_1.useActiveWallet)();
|
23
|
+
return (0, useCapabilities_js_1.useCapabilitiesCore)(options, wallet);
|
24
|
+
}
|
25
|
+
exports.useCapabilities = useCapabilities;
|
26
|
+
//# sourceMappingURL=useCapabilities.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"useCapabilities.js","sourceRoot":"","sources":["../../../../../../src/react/web/hooks/wallets/useCapabilities.ts"],"names":[],"mappings":";;;AAEA,uFAAqF;AACrF,6DAAuD;AAEvD;;;;;;;;;;;;;;GAcG;AACH,SAAgB,eAAe,CAAC,OAE/B;IACC,MAAM,MAAM,GAAG,IAAA,oCAAe,GAAE,CAAC;IACjC,OAAO,IAAA,wCAAmB,EAAC,OAAO,EAAE,MAAM,CAAC,CAAC;AAC9C,CAAC;AALD,0CAKC"}
|
@@ -0,0 +1,40 @@
|
|
1
|
+
"use strict";
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
+
exports.useConnect = void 0;
|
4
|
+
const useConnect_js_1 = require("../../../core/hooks/wallets/useConnect.js");
|
5
|
+
const index_js_1 = require("../../index.js");
|
6
|
+
/**
|
7
|
+
* A hook to set a wallet as active wallet
|
8
|
+
* @returns A function that lets you connect a wallet.
|
9
|
+
* @example
|
10
|
+
* ```jsx
|
11
|
+
* import { useConnect } from "thirdweb/react";
|
12
|
+
* import { createWallet } from "thirdweb/wallets";
|
13
|
+
*
|
14
|
+
* function Example() {
|
15
|
+
* const { connect, isConnecting, error } = useConnect();
|
16
|
+
* return (
|
17
|
+
* <button
|
18
|
+
* onClick={() =>
|
19
|
+
* connect(async () => {
|
20
|
+
* // instantiate wallet
|
21
|
+
* const wallet = createWallet("io.metamask");
|
22
|
+
* // connect wallet
|
23
|
+
* await wallet.connect();
|
24
|
+
* // return the wallet
|
25
|
+
* return wallet;
|
26
|
+
* })
|
27
|
+
* }
|
28
|
+
* >
|
29
|
+
* Connect
|
30
|
+
* </button>
|
31
|
+
* );
|
32
|
+
* }
|
33
|
+
* ```
|
34
|
+
* @walletConnection
|
35
|
+
*/
|
36
|
+
function useConnect(options) {
|
37
|
+
return (0, useConnect_js_1.useConnectCore)(index_js_1.connectionManager, options);
|
38
|
+
}
|
39
|
+
exports.useConnect = useConnect;
|
40
|
+
//# sourceMappingURL=useConnect.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"useConnect.js","sourceRoot":"","sources":["../../../../../../src/react/web/hooks/wallets/useConnect.ts"],"names":[],"mappings":";;;AACA,6EAA2E;AAC3E,6CAAmD;AAEnD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA6BG;AACH,SAAgB,UAAU,CAAC,OAA+B;IACxD,OAAO,IAAA,8BAAc,EAAC,4BAAiB,EAAE,OAAO,CAAC,CAAC;AACpD,CAAC;AAFD,gCAEC"}
|
@@ -0,0 +1,21 @@
|
|
1
|
+
"use strict";
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
+
exports.useConnectedWallets = void 0;
|
4
|
+
const useConnectedWallets_js_1 = require("../../../core/hooks/wallets/useConnectedWallets.js");
|
5
|
+
const index_js_1 = require("../../index.js");
|
6
|
+
/**
|
7
|
+
* A hook that returns all connected wallets
|
8
|
+
* @returns An array of all connected wallets
|
9
|
+
* @example
|
10
|
+
* ```jsx
|
11
|
+
* import { useConnectedWallets } from "thirdweb/react";
|
12
|
+
*
|
13
|
+
* const wallets = useConnectedWallets();
|
14
|
+
* ```
|
15
|
+
* @walletConnection
|
16
|
+
*/
|
17
|
+
function useConnectedWallets() {
|
18
|
+
return (0, useConnectedWallets_js_1.useConnectedWalletsCore)(index_js_1.connectionManager);
|
19
|
+
}
|
20
|
+
exports.useConnectedWallets = useConnectedWallets;
|
21
|
+
//# sourceMappingURL=useConnectedWallets.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"useConnectedWallets.js","sourceRoot":"","sources":["../../../../../../src/react/web/hooks/wallets/useConnectedWallets.ts"],"names":[],"mappings":";;;AAAA,+FAA6F;AAC7F,6CAAmD;AAEnD;;;;;;;;;;GAUG;AACH,SAAgB,mBAAmB;IACjC,OAAO,IAAA,gDAAuB,EAAC,4BAAiB,CAAC,CAAC;AACpD,CAAC;AAFD,kDAEC"}
|
@@ -0,0 +1,30 @@
|
|
1
|
+
"use strict";
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
+
exports.useDisconnect = void 0;
|
4
|
+
const useDisconnect_js_1 = require("../../../core/hooks/wallets/useDisconnect.js");
|
5
|
+
const index_js_1 = require("../../index.js");
|
6
|
+
/**
|
7
|
+
* Disconnect from given account
|
8
|
+
* @example
|
9
|
+
* ```jsx
|
10
|
+
* import { useDisconnect, useActiveWallet } from "thirdweb/react";
|
11
|
+
*
|
12
|
+
* function Example() {
|
13
|
+
* const { disconnect } = useDisconnect();
|
14
|
+
* const wallet = useActiveWallet();
|
15
|
+
*
|
16
|
+
* return (
|
17
|
+
* <button onClick={() => disconnect(wallet)}>
|
18
|
+
* Disconnect
|
19
|
+
* </button>
|
20
|
+
* );
|
21
|
+
* }
|
22
|
+
* ```
|
23
|
+
* @walletConnection
|
24
|
+
* @returns An object with a function to disconnect an account
|
25
|
+
*/
|
26
|
+
function useDisconnect() {
|
27
|
+
return (0, useDisconnect_js_1.useDisconnectCore)(index_js_1.connectionManager);
|
28
|
+
}
|
29
|
+
exports.useDisconnect = useDisconnect;
|
30
|
+
//# sourceMappingURL=useDisconnect.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"useDisconnect.js","sourceRoot":"","sources":["../../../../../../src/react/web/hooks/wallets/useDisconnect.ts"],"names":[],"mappings":";;;AAAA,mFAAiF;AACjF,6CAAmD;AAEnD;;;;;;;;;;;;;;;;;;;GAmBG;AACH,SAAgB,aAAa;IAC3B,OAAO,IAAA,oCAAiB,EAAC,4BAAiB,CAAC,CAAC;AAC9C,CAAC;AAFD,sCAEC"}
|