@web3auth/modal 10.14.1 → 11.0.0-beta.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/lib.cjs/node_modules/style-inject/dist/style-inject.es.js +1 -1
- package/dist/lib.cjs/packages/modal/src/config.js +1 -1
- package/dist/lib.cjs/packages/modal/src/modalManager.js +71 -35
- package/dist/lib.cjs/packages/modal/src/react/Web3AuthProvider.js +4 -2
- package/dist/lib.cjs/packages/modal/src/react/context/WalletServicesInnerContext.js +3 -56
- package/dist/lib.cjs/packages/modal/src/react/context/Web3AuthInnerContext.js +15 -152
- package/dist/lib.cjs/packages/modal/src/react/hooks/useWeb3Auth.js +1 -22
- package/dist/lib.cjs/packages/modal/src/react/hooks/useWeb3AuthConnect.js +30 -43
- package/dist/lib.cjs/packages/modal/src/react/hooks/useWeb3AuthInner.js +8 -4
- package/dist/lib.cjs/packages/modal/src/react/index.js +57 -28
- package/dist/lib.cjs/packages/modal/src/react/solana/index.js +21 -8
- package/dist/lib.cjs/packages/modal/src/react/wagmi/provider.js +13 -11
- package/dist/lib.cjs/packages/modal/src/ui/components/BottomSheet/BottomSheet.js +2 -5
- package/dist/lib.cjs/packages/modal/src/ui/components/Button/Button.js +4 -2
- package/dist/lib.cjs/packages/modal/src/ui/components/Button/ButtonWallet/ButtonWallet.js +1 -2
- package/dist/lib.cjs/packages/modal/src/ui/components/Image/Image.js +2 -2
- package/dist/lib.cjs/packages/modal/src/ui/components/Loader/Loader.js +117 -29
- package/dist/lib.cjs/packages/modal/src/ui/components/Modal/Modal.js +1 -0
- package/dist/lib.cjs/packages/modal/src/ui/components/SocialLoginList/SocialLoginList.js +1 -3
- package/dist/lib.cjs/packages/modal/src/ui/components/SpinnerLoader/SpinnerLoader.css.js +6 -0
- package/dist/lib.cjs/packages/modal/src/ui/components/SpinnerLoader/SpinnerLoader.js +30 -0
- package/dist/lib.cjs/packages/modal/src/ui/components/Toast/Toast.js +1 -1
- package/dist/lib.cjs/packages/modal/src/ui/constants.js +5 -2
- package/dist/lib.cjs/packages/modal/src/ui/{components → containers}/ConnectWallet/ConnectWallet.js +63 -26
- package/dist/lib.cjs/packages/modal/src/ui/{components → containers}/ConnectWallet/ConnectWalletChainFilter/ConnectWalletChainFilter.js +13 -4
- package/dist/lib.cjs/packages/modal/src/ui/{components → containers}/ConnectWallet/ConnectWalletChainNamespaceSelect/ConnectWalletChainNamespaceSelect.js +1 -1
- package/dist/lib.cjs/packages/modal/src/ui/{components → containers}/ConnectWallet/ConnectWalletList/ConnectWalletList.js +25 -17
- package/dist/lib.cjs/packages/modal/src/ui/{components → containers}/ConnectWallet/ConnectWalletQrCode/ConnectWalletQrCode.js +5 -3
- package/dist/lib.cjs/packages/modal/src/ui/{components → containers}/ConnectWallet/ConnectWalletSearch/ConnectWalletSearch.js +8 -2
- package/dist/lib.cjs/packages/modal/src/ui/{components → containers}/Embed/Embed.js +1 -0
- package/dist/lib.cjs/packages/modal/src/ui/{components → containers}/Login/Login.js +50 -39
- package/dist/lib.cjs/packages/modal/src/ui/{components → containers}/Login/LoginOtp/LoginOtp.js +1 -1
- package/dist/lib.cjs/packages/modal/src/ui/{components → containers}/Login/LoginPasswordLess/LoginPasswordLess.js +1 -1
- package/dist/lib.cjs/packages/modal/src/ui/containers/Root/Root.js +235 -0
- package/dist/lib.cjs/packages/modal/src/ui/containers/Root/RootBodySheets/RootBodySheets.js +185 -0
- package/dist/lib.cjs/packages/modal/src/ui/containers/Widget/Widget.js +106 -0
- package/dist/lib.cjs/packages/modal/src/ui/context/ModalStateContext.js +157 -0
- package/dist/lib.cjs/packages/modal/src/ui/context/RootContext.js +64 -21
- package/dist/lib.cjs/packages/modal/src/ui/context/WidgetContext.js +52 -0
- package/dist/lib.cjs/packages/modal/src/ui/css/index.css.js +1 -3
- package/dist/lib.cjs/packages/modal/src/ui/interfaces.js +2 -1
- package/dist/lib.cjs/packages/modal/src/ui/loginModal.js +76 -45
- package/dist/lib.cjs/packages/modal/src/vue/WalletServicesInnerProvider.js +2 -50
- package/dist/lib.cjs/packages/modal/src/vue/Web3AuthProvider.js +7 -170
- package/dist/lib.cjs/packages/modal/src/vue/composables/useWeb3AuthConnect.js +31 -33
- package/dist/lib.cjs/packages/modal/src/vue/composables/useWeb3AuthInner.js +2 -5
- package/dist/lib.cjs/packages/modal/src/vue/index.js +57 -28
- package/dist/lib.cjs/packages/modal/src/vue/solana/index.js +29 -8
- package/dist/lib.cjs/packages/modal/src/vue/wagmi/provider.js +15 -14
- package/dist/lib.cjs/packages/modal/src/x402/index.js +12 -0
- package/dist/lib.cjs/packages/modal/src/x402/react.js +26 -0
- package/dist/lib.cjs/packages/modal/src/x402/vue.js +18 -0
- package/dist/lib.cjs/types/interface.d.ts +2 -2
- package/dist/lib.cjs/types/modalManager.d.ts +7 -3
- package/dist/lib.cjs/types/react/context/WalletServicesInnerContext.d.ts +12 -5
- package/dist/lib.cjs/types/react/context/Web3AuthInnerContext.d.ts +4 -3
- package/dist/lib.cjs/types/react/hooks/index.d.ts +15 -14
- package/dist/lib.cjs/types/react/hooks/useWeb3Auth.d.ts +1 -2
- package/dist/lib.cjs/types/react/hooks/useWeb3AuthConnect.d.ts +3 -3
- package/dist/lib.cjs/types/react/interfaces.d.ts +3 -2
- package/dist/lib.cjs/types/react/solana/hooks/index.d.ts +5 -4
- package/dist/lib.cjs/types/react/solana/index.d.ts +1 -0
- package/dist/lib.cjs/types/react/solana/provider.d.ts +1 -0
- package/dist/lib.cjs/types/ui/components/BottomSheet/BottomSheet.d.ts +1 -1
- package/dist/lib.cjs/types/ui/components/BottomSheet/BottomSheet.type.d.ts +4 -3
- package/dist/lib.cjs/types/ui/components/Button/ButtonWallet/ButtonWallet.type.d.ts +1 -0
- package/dist/lib.cjs/types/ui/components/Loader/Loader.type.d.ts +7 -5
- package/dist/lib.cjs/types/ui/components/LoginHint/LoginHint.type.d.ts +2 -1
- package/dist/lib.cjs/types/ui/components/SpinnerLoader/SpinnerLoader.d.ts +4 -0
- package/dist/lib.cjs/types/ui/components/SpinnerLoader/SpinnerLoader.type.d.ts +9 -0
- package/dist/lib.cjs/types/ui/components/SpinnerLoader/index.d.ts +2 -0
- package/dist/lib.cjs/types/ui/constants.d.ts +7 -4
- package/dist/lib.cjs/types/ui/containers/ConnectWallet/ConnectWallet.type.d.ts +7 -0
- package/dist/lib.cjs/types/ui/{components → containers}/ConnectWallet/ConnectWalletChainFilter/ConnectWalletChainFilter.type.d.ts +0 -2
- package/dist/lib.cjs/types/ui/{components → containers}/ConnectWallet/ConnectWalletList/ConnectWalletList.type.d.ts +3 -9
- package/dist/lib.cjs/types/ui/{components → containers}/ConnectWallet/ConnectWalletSearch/ConnectWalletSearch.type.d.ts +0 -2
- package/dist/lib.cjs/types/ui/containers/Login/Login.type.d.ts +6 -0
- package/dist/lib.cjs/types/ui/containers/Root/Root.type.d.ts +3 -0
- package/dist/lib.cjs/types/ui/containers/Root/RootBodySheets/RootBodySheets.d.ts +1 -0
- package/dist/lib.cjs/types/ui/containers/Widget/Widget.type.d.ts +5 -0
- package/dist/lib.cjs/types/ui/context/ModalStateContext.d.ts +28 -0
- package/dist/lib.cjs/types/ui/context/RootContext.d.ts +19 -7
- package/dist/lib.cjs/types/ui/context/WidgetContext.d.ts +45 -0
- package/dist/lib.cjs/types/ui/interfaces.d.ts +18 -15
- package/dist/lib.cjs/types/ui/loginModal.d.ts +6 -4
- package/dist/lib.cjs/types/vue/composables/index.d.ts +2 -14
- package/dist/lib.cjs/types/vue/composables/useWeb3Auth.d.ts +1 -2
- package/dist/lib.cjs/types/vue/composables/useWeb3AuthConnect.d.ts +3 -3
- package/dist/lib.cjs/types/vue/interfaces.d.ts +3 -17
- package/dist/lib.cjs/types/vue/solana/composables/index.d.ts +3 -4
- package/dist/lib.cjs/types/vue/solana/composables/useSolanaClient.d.ts +1 -0
- package/dist/lib.cjs/types/vue/solana/constants.d.ts +1 -0
- package/dist/lib.cjs/types/vue/solana/index.d.ts +2 -0
- package/dist/lib.cjs/types/vue/solana/provider.d.ts +1 -0
- package/dist/lib.cjs/types/x402/index.d.ts +1 -0
- package/dist/lib.cjs/types/x402/react.d.ts +2 -0
- package/dist/lib.cjs/types/x402/vue.d.ts +2 -0
- package/dist/lib.esm/node_modules/style-inject/dist/style-inject.es.js +1 -1
- package/dist/lib.esm/packages/modal/src/config.js +1 -1
- package/dist/lib.esm/packages/modal/src/modalManager.js +72 -36
- package/dist/lib.esm/packages/modal/src/react/Web3AuthProvider.js +4 -2
- package/dist/lib.esm/packages/modal/src/react/context/WalletServicesInnerContext.js +4 -57
- package/dist/lib.esm/packages/modal/src/react/context/Web3AuthInnerContext.js +12 -151
- package/dist/lib.esm/packages/modal/src/react/hooks/useWeb3Auth.js +1 -22
- package/dist/lib.esm/packages/modal/src/react/hooks/useWeb3AuthConnect.js +28 -41
- package/dist/lib.esm/packages/modal/src/react/hooks/useWeb3AuthInner.js +7 -3
- package/dist/lib.esm/packages/modal/src/react/index.js +1 -14
- package/dist/lib.esm/packages/modal/src/react/solana/index.js +1 -4
- package/dist/lib.esm/packages/modal/src/react/wagmi/provider.js +12 -10
- package/dist/lib.esm/packages/modal/src/ui/components/BottomSheet/BottomSheet.js +2 -5
- package/dist/lib.esm/packages/modal/src/ui/components/Button/Button.js +4 -2
- package/dist/lib.esm/packages/modal/src/ui/components/Button/ButtonWallet/ButtonWallet.js +2 -3
- package/dist/lib.esm/packages/modal/src/ui/components/Image/Image.js +3 -3
- package/dist/lib.esm/packages/modal/src/ui/components/Loader/Loader.js +118 -30
- package/dist/lib.esm/packages/modal/src/ui/components/Modal/Modal.js +1 -0
- package/dist/lib.esm/packages/modal/src/ui/components/SocialLoginList/SocialLoginList.js +2 -4
- package/dist/lib.esm/packages/modal/src/ui/components/SpinnerLoader/SpinnerLoader.css.js +4 -0
- package/dist/lib.esm/packages/modal/src/ui/components/SpinnerLoader/SpinnerLoader.js +28 -0
- package/dist/lib.esm/packages/modal/src/ui/components/Toast/Toast.js +3 -3
- package/dist/lib.esm/packages/modal/src/ui/constants.js +5 -2
- package/dist/lib.esm/packages/modal/src/ui/{components → containers}/ConnectWallet/ConnectWallet.js +67 -29
- package/dist/lib.esm/packages/modal/src/ui/{components → containers}/ConnectWallet/ConnectWalletChainFilter/ConnectWalletChainFilter.js +14 -5
- package/dist/lib.esm/packages/modal/src/ui/{components → containers}/ConnectWallet/ConnectWalletChainNamespaceSelect/ConnectWalletChainNamespaceSelect.js +1 -1
- package/dist/lib.esm/packages/modal/src/ui/{components → containers}/ConnectWallet/ConnectWalletList/ConnectWalletList.js +25 -17
- package/dist/lib.esm/packages/modal/src/ui/{components → containers}/ConnectWallet/ConnectWalletQrCode/ConnectWalletQrCode.js +7 -5
- package/dist/lib.esm/packages/modal/src/ui/{components → containers}/ConnectWallet/ConnectWalletSearch/ConnectWalletSearch.js +8 -2
- package/dist/lib.esm/packages/modal/src/ui/{components → containers}/Embed/Embed.js +1 -0
- package/dist/lib.esm/packages/modal/src/ui/{components → containers}/Login/Login.js +53 -41
- package/dist/lib.esm/packages/modal/src/ui/{components → containers}/Login/LoginOtp/LoginOtp.js +1 -1
- package/dist/lib.esm/packages/modal/src/ui/{components → containers}/Login/LoginPasswordLess/LoginPasswordLess.js +2 -2
- package/dist/lib.esm/packages/modal/src/ui/containers/Root/Root.js +238 -0
- package/dist/lib.esm/packages/modal/src/ui/containers/Root/RootBodySheets/RootBodySheets.js +183 -0
- package/dist/lib.esm/packages/modal/src/ui/containers/Widget/Widget.js +104 -0
- package/dist/lib.esm/packages/modal/src/ui/context/ModalStateContext.js +160 -0
- package/dist/lib.esm/packages/modal/src/ui/context/RootContext.js +60 -22
- package/dist/lib.esm/packages/modal/src/ui/context/WidgetContext.js +49 -0
- package/dist/lib.esm/packages/modal/src/ui/css/index.css.js +1 -3
- package/dist/lib.esm/packages/modal/src/ui/interfaces.js +2 -1
- package/dist/lib.esm/packages/modal/src/ui/loginModal.js +76 -45
- package/dist/lib.esm/packages/modal/src/vue/WalletServicesInnerProvider.js +5 -54
- package/dist/lib.esm/packages/modal/src/vue/Web3AuthProvider.js +9 -176
- package/dist/lib.esm/packages/modal/src/vue/composables/useWeb3AuthConnect.js +28 -30
- package/dist/lib.esm/packages/modal/src/vue/composables/useWeb3AuthInner.js +2 -5
- package/dist/lib.esm/packages/modal/src/vue/index.js +1 -14
- package/dist/lib.esm/packages/modal/src/vue/solana/index.js +1 -4
- package/dist/lib.esm/packages/modal/src/vue/wagmi/provider.js +10 -9
- package/dist/lib.esm/packages/modal/src/x402/index.js +1 -0
- package/dist/lib.esm/packages/modal/src/x402/react.js +1 -0
- package/dist/lib.esm/packages/modal/src/x402/vue.js +1 -0
- package/package.json +68 -44
- package/dist/lib.cjs/packages/modal/src/providers/ethereum-mpc-provider/index.js +0 -12
- package/dist/lib.cjs/packages/modal/src/react/hooks/useChain.js +0 -16
- package/dist/lib.cjs/packages/modal/src/react/hooks/useCheckout.js +0 -34
- package/dist/lib.cjs/packages/modal/src/react/hooks/useEnableMFA.js +0 -30
- package/dist/lib.cjs/packages/modal/src/react/hooks/useFunding.js +0 -34
- package/dist/lib.cjs/packages/modal/src/react/hooks/useIdentityToken.js +0 -46
- package/dist/lib.cjs/packages/modal/src/react/hooks/useManageMFA.js +0 -30
- package/dist/lib.cjs/packages/modal/src/react/hooks/useReceive.js +0 -34
- package/dist/lib.cjs/packages/modal/src/react/hooks/useSwap.js +0 -34
- package/dist/lib.cjs/packages/modal/src/react/hooks/useSwitchChain.js +0 -32
- package/dist/lib.cjs/packages/modal/src/react/hooks/useWalletConnectScanner.js +0 -34
- package/dist/lib.cjs/packages/modal/src/react/hooks/useWalletServicesPlugin.js +0 -13
- package/dist/lib.cjs/packages/modal/src/react/hooks/useWalletUI.js +0 -34
- package/dist/lib.cjs/packages/modal/src/react/hooks/useWeb3AuthDisconnect.js +0 -30
- package/dist/lib.cjs/packages/modal/src/react/hooks/useWeb3AuthUser.js +0 -50
- package/dist/lib.cjs/packages/modal/src/react/solana/hooks/useSignAndSendTransaction.js +0 -36
- package/dist/lib.cjs/packages/modal/src/react/solana/hooks/useSignMessage.js +0 -37
- package/dist/lib.cjs/packages/modal/src/react/solana/hooks/useSignTransaction.js +0 -36
- package/dist/lib.cjs/packages/modal/src/react/solana/hooks/useSolanaWallet.js +0 -68
- package/dist/lib.cjs/packages/modal/src/ui/components/CircularLoader/CircularLoader.js +0 -88
- package/dist/lib.cjs/packages/modal/src/ui/components/Root/Root.js +0 -513
- package/dist/lib.cjs/packages/modal/src/ui/components/Widget/Widget.js +0 -251
- package/dist/lib.cjs/packages/modal/src/ui/context/ThemeContext.js +0 -9
- package/dist/lib.cjs/packages/modal/src/vue/composables/useChain.js +0 -13
- package/dist/lib.cjs/packages/modal/src/vue/composables/useCheckout.js +0 -35
- package/dist/lib.cjs/packages/modal/src/vue/composables/useEnableMFA.js +0 -33
- package/dist/lib.cjs/packages/modal/src/vue/composables/useFunding.js +0 -35
- package/dist/lib.cjs/packages/modal/src/vue/composables/useIdentityToken.js +0 -51
- package/dist/lib.cjs/packages/modal/src/vue/composables/useManageMFA.js +0 -33
- package/dist/lib.cjs/packages/modal/src/vue/composables/useReceive.js +0 -35
- package/dist/lib.cjs/packages/modal/src/vue/composables/useSwap.js +0 -35
- package/dist/lib.cjs/packages/modal/src/vue/composables/useSwitchChain.js +0 -33
- package/dist/lib.cjs/packages/modal/src/vue/composables/useWalletConnectScanner.js +0 -35
- package/dist/lib.cjs/packages/modal/src/vue/composables/useWalletServicesPlugin.js +0 -13
- package/dist/lib.cjs/packages/modal/src/vue/composables/useWalletUI.js +0 -35
- package/dist/lib.cjs/packages/modal/src/vue/composables/useWeb3AuthDisconnect.js +0 -33
- package/dist/lib.cjs/packages/modal/src/vue/composables/useWeb3AuthUser.js +0 -54
- package/dist/lib.cjs/packages/modal/src/vue/solana/composables/useSignAndSendTransaction.js +0 -37
- package/dist/lib.cjs/packages/modal/src/vue/solana/composables/useSignMessage.js +0 -39
- package/dist/lib.cjs/packages/modal/src/vue/solana/composables/useSignTransaction.js +0 -37
- package/dist/lib.cjs/packages/modal/src/vue/solana/composables/useSolanaWallet.js +0 -67
- package/dist/lib.cjs/types/providers/ethereum-mpc-provider/index.d.ts +0 -1
- package/dist/lib.cjs/types/react/hooks/useChain.d.ts +0 -6
- package/dist/lib.cjs/types/react/hooks/useCheckout.d.ts +0 -8
- package/dist/lib.cjs/types/react/hooks/useEnableMFA.d.ts +0 -7
- package/dist/lib.cjs/types/react/hooks/useFunding.d.ts +0 -8
- package/dist/lib.cjs/types/react/hooks/useIdentityToken.d.ts +0 -13
- package/dist/lib.cjs/types/react/hooks/useManageMFA.d.ts +0 -7
- package/dist/lib.cjs/types/react/hooks/useReceive.d.ts +0 -8
- package/dist/lib.cjs/types/react/hooks/useSwap.d.ts +0 -8
- package/dist/lib.cjs/types/react/hooks/useSwitchChain.d.ts +0 -7
- package/dist/lib.cjs/types/react/hooks/useWalletConnectScanner.d.ts +0 -8
- package/dist/lib.cjs/types/react/hooks/useWalletServicesPlugin.d.ts +0 -2
- package/dist/lib.cjs/types/react/hooks/useWalletUI.d.ts +0 -8
- package/dist/lib.cjs/types/react/hooks/useWeb3AuthDisconnect.d.ts +0 -9
- package/dist/lib.cjs/types/react/hooks/useWeb3AuthUser.d.ts +0 -9
- package/dist/lib.cjs/types/react/solana/hooks/useSignAndSendTransaction.d.ts +0 -8
- package/dist/lib.cjs/types/react/solana/hooks/useSignMessage.d.ts +0 -8
- package/dist/lib.cjs/types/react/solana/hooks/useSignTransaction.d.ts +0 -13
- package/dist/lib.cjs/types/react/solana/hooks/useSolanaWallet.d.ts +0 -8
- package/dist/lib.cjs/types/ui/components/CircularLoader/CircularLoader.d.ts +0 -3
- package/dist/lib.cjs/types/ui/components/CircularLoader/CircularLoader.type.d.ts +0 -19
- package/dist/lib.cjs/types/ui/components/CircularLoader/index.d.ts +0 -2
- package/dist/lib.cjs/types/ui/components/ConnectWallet/ConnectWallet.type.d.ts +0 -27
- package/dist/lib.cjs/types/ui/components/Login/Login.type.d.ts +0 -35
- package/dist/lib.cjs/types/ui/components/Root/Root.type.d.ts +0 -36
- package/dist/lib.cjs/types/ui/components/Widget/Widget.type.d.ts +0 -24
- package/dist/lib.cjs/types/ui/context/ThemeContext.d.ts +0 -3
- package/dist/lib.cjs/types/vue/composables/useChain.d.ts +0 -7
- package/dist/lib.cjs/types/vue/composables/useCheckout.d.ts +0 -9
- package/dist/lib.cjs/types/vue/composables/useEnableMFA.d.ts +0 -8
- package/dist/lib.cjs/types/vue/composables/useFunding.d.ts +0 -9
- package/dist/lib.cjs/types/vue/composables/useIdentityToken.d.ts +0 -9
- package/dist/lib.cjs/types/vue/composables/useManageMFA.d.ts +0 -8
- package/dist/lib.cjs/types/vue/composables/useReceive.d.ts +0 -9
- package/dist/lib.cjs/types/vue/composables/useSwap.d.ts +0 -9
- package/dist/lib.cjs/types/vue/composables/useSwitchChain.d.ts +0 -10
- package/dist/lib.cjs/types/vue/composables/useWalletConnectScanner.d.ts +0 -9
- package/dist/lib.cjs/types/vue/composables/useWalletServicesPlugin.d.ts +0 -2
- package/dist/lib.cjs/types/vue/composables/useWalletUI.d.ts +0 -9
- package/dist/lib.cjs/types/vue/composables/useWeb3AuthDisconnect.d.ts +0 -10
- package/dist/lib.cjs/types/vue/composables/useWeb3AuthUser.d.ts +0 -10
- package/dist/lib.cjs/types/vue/solana/composables/useSignAndSendTransaction.d.ts +0 -9
- package/dist/lib.cjs/types/vue/solana/composables/useSignMessage.d.ts +0 -9
- package/dist/lib.cjs/types/vue/solana/composables/useSignTransaction.d.ts +0 -9
- package/dist/lib.cjs/types/vue/solana/composables/useSolanaWallet.d.ts +0 -9
- package/dist/lib.esm/packages/modal/src/providers/ethereum-mpc-provider/index.js +0 -1
- package/dist/lib.esm/packages/modal/src/react/hooks/useChain.js +0 -14
- package/dist/lib.esm/packages/modal/src/react/hooks/useCheckout.js +0 -32
- package/dist/lib.esm/packages/modal/src/react/hooks/useEnableMFA.js +0 -28
- package/dist/lib.esm/packages/modal/src/react/hooks/useFunding.js +0 -32
- package/dist/lib.esm/packages/modal/src/react/hooks/useIdentityToken.js +0 -44
- package/dist/lib.esm/packages/modal/src/react/hooks/useManageMFA.js +0 -28
- package/dist/lib.esm/packages/modal/src/react/hooks/useReceive.js +0 -32
- package/dist/lib.esm/packages/modal/src/react/hooks/useSwap.js +0 -32
- package/dist/lib.esm/packages/modal/src/react/hooks/useSwitchChain.js +0 -30
- package/dist/lib.esm/packages/modal/src/react/hooks/useWalletConnectScanner.js +0 -32
- package/dist/lib.esm/packages/modal/src/react/hooks/useWalletServicesPlugin.js +0 -11
- package/dist/lib.esm/packages/modal/src/react/hooks/useWalletUI.js +0 -32
- package/dist/lib.esm/packages/modal/src/react/hooks/useWeb3AuthDisconnect.js +0 -28
- package/dist/lib.esm/packages/modal/src/react/hooks/useWeb3AuthUser.js +0 -48
- package/dist/lib.esm/packages/modal/src/react/solana/hooks/useSignAndSendTransaction.js +0 -34
- package/dist/lib.esm/packages/modal/src/react/solana/hooks/useSignMessage.js +0 -35
- package/dist/lib.esm/packages/modal/src/react/solana/hooks/useSignTransaction.js +0 -34
- package/dist/lib.esm/packages/modal/src/react/solana/hooks/useSolanaWallet.js +0 -64
- package/dist/lib.esm/packages/modal/src/ui/components/CircularLoader/CircularLoader.js +0 -86
- package/dist/lib.esm/packages/modal/src/ui/components/Root/Root.js +0 -524
- package/dist/lib.esm/packages/modal/src/ui/components/Widget/Widget.js +0 -253
- package/dist/lib.esm/packages/modal/src/ui/context/ThemeContext.js +0 -7
- package/dist/lib.esm/packages/modal/src/vue/composables/useChain.js +0 -11
- package/dist/lib.esm/packages/modal/src/vue/composables/useCheckout.js +0 -33
- package/dist/lib.esm/packages/modal/src/vue/composables/useEnableMFA.js +0 -31
- package/dist/lib.esm/packages/modal/src/vue/composables/useFunding.js +0 -33
- package/dist/lib.esm/packages/modal/src/vue/composables/useIdentityToken.js +0 -49
- package/dist/lib.esm/packages/modal/src/vue/composables/useManageMFA.js +0 -31
- package/dist/lib.esm/packages/modal/src/vue/composables/useReceive.js +0 -33
- package/dist/lib.esm/packages/modal/src/vue/composables/useSwap.js +0 -33
- package/dist/lib.esm/packages/modal/src/vue/composables/useSwitchChain.js +0 -31
- package/dist/lib.esm/packages/modal/src/vue/composables/useWalletConnectScanner.js +0 -33
- package/dist/lib.esm/packages/modal/src/vue/composables/useWalletServicesPlugin.js +0 -11
- package/dist/lib.esm/packages/modal/src/vue/composables/useWalletUI.js +0 -33
- package/dist/lib.esm/packages/modal/src/vue/composables/useWeb3AuthDisconnect.js +0 -31
- package/dist/lib.esm/packages/modal/src/vue/composables/useWeb3AuthUser.js +0 -52
- package/dist/lib.esm/packages/modal/src/vue/solana/composables/useSignAndSendTransaction.js +0 -35
- package/dist/lib.esm/packages/modal/src/vue/solana/composables/useSignMessage.js +0 -37
- package/dist/lib.esm/packages/modal/src/vue/solana/composables/useSignTransaction.js +0 -35
- package/dist/lib.esm/packages/modal/src/vue/solana/composables/useSolanaWallet.js +0 -65
- package/dist/modal.umd.min.js +0 -2
- package/dist/modal.umd.min.js.LICENSE.txt +0 -106
- /package/dist/lib.cjs/packages/modal/src/ui/{components → containers}/ConnectWallet/ConnectWalletHeader/ConnectWalletHeader.js +0 -0
- /package/dist/lib.cjs/types/ui/{components → containers}/ConnectWallet/ConnectWallet.d.ts +0 -0
- /package/dist/lib.cjs/types/ui/{components → containers}/ConnectWallet/ConnectWalletChainFilter/ConnectWalletChainFilter.d.ts +0 -0
- /package/dist/lib.cjs/types/ui/{components → containers}/ConnectWallet/ConnectWalletChainFilter/index.d.ts +0 -0
- /package/dist/lib.cjs/types/ui/{components → containers}/ConnectWallet/ConnectWalletChainNamespaceSelect/ConnectWalletChainNamespaceSelect.d.ts +0 -0
- /package/dist/lib.cjs/types/ui/{components → containers}/ConnectWallet/ConnectWalletChainNamespaceSelect/ConnectWalletChainNamespaceSelect.type.d.ts +0 -0
- /package/dist/lib.cjs/types/ui/{components → containers}/ConnectWallet/ConnectWalletChainNamespaceSelect/index.d.ts +0 -0
- /package/dist/lib.cjs/types/ui/{components → containers}/ConnectWallet/ConnectWalletHeader/ConnectWalletHeader.d.ts +0 -0
- /package/dist/lib.cjs/types/ui/{components → containers}/ConnectWallet/ConnectWalletHeader/ConnectWalletHeader.type.d.ts +0 -0
- /package/dist/lib.cjs/types/ui/{components → containers}/ConnectWallet/ConnectWalletHeader/index.d.ts +0 -0
- /package/dist/lib.cjs/types/ui/{components → containers}/ConnectWallet/ConnectWalletList/ConnectWalletList.d.ts +0 -0
- /package/dist/lib.cjs/types/ui/{components → containers}/ConnectWallet/ConnectWalletList/index.d.ts +0 -0
- /package/dist/lib.cjs/types/ui/{components → containers}/ConnectWallet/ConnectWalletQrCode/ConnectWalletQrCode.d.ts +0 -0
- /package/dist/lib.cjs/types/ui/{components → containers}/ConnectWallet/ConnectWalletQrCode/ConnectWalletQrCode.type.d.ts +0 -0
- /package/dist/lib.cjs/types/ui/{components → containers}/ConnectWallet/ConnectWalletQrCode/index.d.ts +0 -0
- /package/dist/lib.cjs/types/ui/{components → containers}/ConnectWallet/ConnectWalletSearch/ConnectWalletSearch.d.ts +0 -0
- /package/dist/lib.cjs/types/ui/{components → containers}/ConnectWallet/ConnectWalletSearch/index.d.ts +0 -0
- /package/dist/lib.cjs/types/ui/{components → containers}/ConnectWallet/index.d.ts +0 -0
- /package/dist/lib.cjs/types/ui/{components → containers}/Embed/Embed.d.ts +0 -0
- /package/dist/lib.cjs/types/ui/{components → containers}/Embed/Embed.type.d.ts +0 -0
- /package/dist/lib.cjs/types/ui/{components → containers}/Embed/index.d.ts +0 -0
- /package/dist/lib.cjs/types/ui/{components → containers}/Login/Login.d.ts +0 -0
- /package/dist/lib.cjs/types/ui/{components → containers}/Login/LoginOtp/LoginOtp.d.ts +0 -0
- /package/dist/lib.cjs/types/ui/{components → containers}/Login/LoginOtp/LoginOtp.type.d.ts +0 -0
- /package/dist/lib.cjs/types/ui/{components → containers}/Login/LoginOtp/index.d.ts +0 -0
- /package/dist/lib.cjs/types/ui/{components → containers}/Login/LoginPasswordLess/LoginPasswordLess.d.ts +0 -0
- /package/dist/lib.cjs/types/ui/{components → containers}/Login/LoginPasswordLess/LoginPasswordLess.type.d.ts +0 -0
- /package/dist/lib.cjs/types/ui/{components → containers}/Login/LoginPasswordLess/index.d.ts +0 -0
- /package/dist/lib.cjs/types/ui/{components → containers}/Login/index.d.ts +0 -0
- /package/dist/lib.cjs/types/ui/{components → containers}/Root/Root.d.ts +0 -0
- /package/dist/lib.cjs/types/ui/{components → containers}/Root/index.d.ts +0 -0
- /package/dist/lib.cjs/types/ui/{components → containers}/Widget/Widget.d.ts +0 -0
- /package/dist/lib.cjs/types/ui/{components → containers}/Widget/index.d.ts +0 -0
- /package/dist/lib.esm/packages/modal/src/ui/{components → containers}/ConnectWallet/ConnectWalletHeader/ConnectWalletHeader.js +0 -0
|
@@ -1,39 +1,68 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var useChain = require('./composables/useChain.js');
|
|
4
|
-
var useCheckout = require('./composables/useCheckout.js');
|
|
5
|
-
var useEnableMFA = require('./composables/useEnableMFA.js');
|
|
6
|
-
var useFunding = require('./composables/useFunding.js');
|
|
7
|
-
var useIdentityToken = require('./composables/useIdentityToken.js');
|
|
8
|
-
var useManageMFA = require('./composables/useManageMFA.js');
|
|
9
|
-
var useReceive = require('./composables/useReceive.js');
|
|
10
|
-
var useSwap = require('./composables/useSwap.js');
|
|
11
|
-
var useSwitchChain = require('./composables/useSwitchChain.js');
|
|
12
|
-
var useWalletConnectScanner = require('./composables/useWalletConnectScanner.js');
|
|
13
|
-
var useWalletServicesPlugin = require('./composables/useWalletServicesPlugin.js');
|
|
14
|
-
var useWalletUI = require('./composables/useWalletUI.js');
|
|
15
3
|
var useWeb3Auth = require('./composables/useWeb3Auth.js');
|
|
16
4
|
var useWeb3AuthConnect = require('./composables/useWeb3AuthConnect.js');
|
|
17
|
-
var
|
|
18
|
-
var useWeb3AuthUser = require('./composables/useWeb3AuthUser.js');
|
|
5
|
+
var vue = require('@web3auth/no-modal/vue');
|
|
19
6
|
var Web3AuthProvider = require('./Web3AuthProvider.js');
|
|
20
7
|
|
|
21
8
|
|
|
22
9
|
|
|
23
|
-
exports.useChain = useChain.useChain;
|
|
24
|
-
exports.useCheckout = useCheckout.useCheckout;
|
|
25
|
-
exports.useEnableMFA = useEnableMFA.useEnableMFA;
|
|
26
|
-
exports.useFunding = useFunding.useFunding;
|
|
27
|
-
exports.useIdentityToken = useIdentityToken.useIdentityToken;
|
|
28
|
-
exports.useManageMFA = useManageMFA.useManageMFA;
|
|
29
|
-
exports.useReceive = useReceive.useReceive;
|
|
30
|
-
exports.useSwap = useSwap.useSwap;
|
|
31
|
-
exports.useSwitchChain = useSwitchChain.useSwitchChain;
|
|
32
|
-
exports.useWalletConnectScanner = useWalletConnectScanner.useWalletConnectScanner;
|
|
33
|
-
exports.useWalletServicesPlugin = useWalletServicesPlugin.useWalletServicesPlugin;
|
|
34
|
-
exports.useWalletUI = useWalletUI.useWalletUI;
|
|
35
10
|
exports.useWeb3Auth = useWeb3Auth.useWeb3Auth;
|
|
36
11
|
exports.useWeb3AuthConnect = useWeb3AuthConnect.useWeb3AuthConnect;
|
|
37
|
-
exports
|
|
38
|
-
|
|
12
|
+
Object.defineProperty(exports, "useAuthTokenInfo", {
|
|
13
|
+
enumerable: true,
|
|
14
|
+
get: function () { return vue.useAuthTokenInfo; }
|
|
15
|
+
});
|
|
16
|
+
Object.defineProperty(exports, "useChain", {
|
|
17
|
+
enumerable: true,
|
|
18
|
+
get: function () { return vue.useChain; }
|
|
19
|
+
});
|
|
20
|
+
Object.defineProperty(exports, "useCheckout", {
|
|
21
|
+
enumerable: true,
|
|
22
|
+
get: function () { return vue.useCheckout; }
|
|
23
|
+
});
|
|
24
|
+
Object.defineProperty(exports, "useEnableMFA", {
|
|
25
|
+
enumerable: true,
|
|
26
|
+
get: function () { return vue.useEnableMFA; }
|
|
27
|
+
});
|
|
28
|
+
Object.defineProperty(exports, "useFunding", {
|
|
29
|
+
enumerable: true,
|
|
30
|
+
get: function () { return vue.useFunding; }
|
|
31
|
+
});
|
|
32
|
+
Object.defineProperty(exports, "useManageMFA", {
|
|
33
|
+
enumerable: true,
|
|
34
|
+
get: function () { return vue.useManageMFA; }
|
|
35
|
+
});
|
|
36
|
+
Object.defineProperty(exports, "useReceive", {
|
|
37
|
+
enumerable: true,
|
|
38
|
+
get: function () { return vue.useReceive; }
|
|
39
|
+
});
|
|
40
|
+
Object.defineProperty(exports, "useSwap", {
|
|
41
|
+
enumerable: true,
|
|
42
|
+
get: function () { return vue.useSwap; }
|
|
43
|
+
});
|
|
44
|
+
Object.defineProperty(exports, "useSwitchChain", {
|
|
45
|
+
enumerable: true,
|
|
46
|
+
get: function () { return vue.useSwitchChain; }
|
|
47
|
+
});
|
|
48
|
+
Object.defineProperty(exports, "useWalletConnectScanner", {
|
|
49
|
+
enumerable: true,
|
|
50
|
+
get: function () { return vue.useWalletConnectScanner; }
|
|
51
|
+
});
|
|
52
|
+
Object.defineProperty(exports, "useWalletServicesPlugin", {
|
|
53
|
+
enumerable: true,
|
|
54
|
+
get: function () { return vue.useWalletServicesPlugin; }
|
|
55
|
+
});
|
|
56
|
+
Object.defineProperty(exports, "useWalletUI", {
|
|
57
|
+
enumerable: true,
|
|
58
|
+
get: function () { return vue.useWalletUI; }
|
|
59
|
+
});
|
|
60
|
+
Object.defineProperty(exports, "useWeb3AuthDisconnect", {
|
|
61
|
+
enumerable: true,
|
|
62
|
+
get: function () { return vue.useWeb3AuthDisconnect; }
|
|
63
|
+
});
|
|
64
|
+
Object.defineProperty(exports, "useWeb3AuthUser", {
|
|
65
|
+
enumerable: true,
|
|
66
|
+
get: function () { return vue.useWeb3AuthUser; }
|
|
67
|
+
});
|
|
39
68
|
exports.Web3AuthProvider = Web3AuthProvider.Web3AuthProvider;
|
|
@@ -1,13 +1,34 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
4
|
-
var useSignMessage = require('./composables/useSignMessage.js');
|
|
5
|
-
var useSignTransaction = require('./composables/useSignTransaction.js');
|
|
6
|
-
var useSolanaWallet = require('./composables/useSolanaWallet.js');
|
|
3
|
+
var solana = require('@web3auth/no-modal/vue/solana');
|
|
7
4
|
|
|
8
5
|
|
|
9
6
|
|
|
10
|
-
exports
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
7
|
+
Object.defineProperty(exports, "SOLANA_CLIENT_KEY", {
|
|
8
|
+
enumerable: true,
|
|
9
|
+
get: function () { return solana.SOLANA_CLIENT_KEY; }
|
|
10
|
+
});
|
|
11
|
+
Object.defineProperty(exports, "SolanaProvider", {
|
|
12
|
+
enumerable: true,
|
|
13
|
+
get: function () { return solana.SolanaProvider; }
|
|
14
|
+
});
|
|
15
|
+
Object.defineProperty(exports, "useSignAndSendTransaction", {
|
|
16
|
+
enumerable: true,
|
|
17
|
+
get: function () { return solana.useSignAndSendTransaction; }
|
|
18
|
+
});
|
|
19
|
+
Object.defineProperty(exports, "useSignMessage", {
|
|
20
|
+
enumerable: true,
|
|
21
|
+
get: function () { return solana.useSignMessage; }
|
|
22
|
+
});
|
|
23
|
+
Object.defineProperty(exports, "useSignTransaction", {
|
|
24
|
+
enumerable: true,
|
|
25
|
+
get: function () { return solana.useSignTransaction; }
|
|
26
|
+
});
|
|
27
|
+
Object.defineProperty(exports, "useSolanaClient", {
|
|
28
|
+
enumerable: true,
|
|
29
|
+
get: function () { return solana.useSolanaClient; }
|
|
30
|
+
});
|
|
31
|
+
Object.defineProperty(exports, "useSolanaWallet", {
|
|
32
|
+
enumerable: true,
|
|
33
|
+
get: function () { return solana.useSolanaWallet; }
|
|
34
|
+
});
|
|
@@ -2,15 +2,14 @@
|
|
|
2
2
|
|
|
3
3
|
var _objectSpread = require('@babel/runtime/helpers/objectSpread2');
|
|
4
4
|
var core = require('@wagmi/core');
|
|
5
|
-
var vue$
|
|
5
|
+
var vue$2 = require('@wagmi/vue');
|
|
6
6
|
var connectors = require('@wagmi/vue/connectors');
|
|
7
7
|
var auth = require('@web3auth/auth');
|
|
8
8
|
var noModal = require('@web3auth/no-modal');
|
|
9
9
|
var viem = require('viem');
|
|
10
10
|
var vue = require('vue');
|
|
11
|
-
require('@web3auth/no-modal/vue');
|
|
12
11
|
var useWeb3Auth = require('../composables/useWeb3Auth.js');
|
|
13
|
-
var
|
|
12
|
+
var vue$1 = require('@web3auth/no-modal/vue');
|
|
14
13
|
var constants = require('./constants.js');
|
|
15
14
|
|
|
16
15
|
const WEB3AUTH_CONNECTOR_ID = "web3auth";
|
|
@@ -76,16 +75,16 @@ const Web3AuthWagmiProvider = vue.defineComponent({
|
|
|
76
75
|
setup() {
|
|
77
76
|
const {
|
|
78
77
|
isConnected,
|
|
79
|
-
|
|
78
|
+
connection
|
|
80
79
|
} = useWeb3Auth.useWeb3Auth();
|
|
81
80
|
const {
|
|
82
81
|
disconnect
|
|
83
|
-
} =
|
|
84
|
-
const wagmiConfig = vue$
|
|
82
|
+
} = vue$1.useWeb3AuthDisconnect();
|
|
83
|
+
const wagmiConfig = vue$2.useConfig();
|
|
85
84
|
const {
|
|
86
|
-
reconnect
|
|
87
|
-
} = vue$
|
|
88
|
-
vue$
|
|
85
|
+
mutate: reconnect
|
|
86
|
+
} = vue$2.useReconnect();
|
|
87
|
+
vue$2.useConnectionEffect({
|
|
89
88
|
onDisconnect: async () => {
|
|
90
89
|
noModal.log.info("Disconnected from wagmi");
|
|
91
90
|
if (isConnected.value) await disconnect();
|
|
@@ -97,9 +96,11 @@ const Web3AuthWagmiProvider = vue.defineComponent({
|
|
|
97
96
|
}
|
|
98
97
|
}
|
|
99
98
|
});
|
|
100
|
-
vue.watch(isConnected, async
|
|
101
|
-
|
|
102
|
-
|
|
99
|
+
vue.watch([isConnected, connection], async () => {
|
|
100
|
+
var _connection$value;
|
|
101
|
+
const newIsConnected = isConnected.value;
|
|
102
|
+
if (newIsConnected && (_connection$value = connection.value) !== null && _connection$value !== void 0 && _connection$value.ethereumProvider) {
|
|
103
|
+
const connector = await setupConnector(connection.value.ethereumProvider, wagmiConfig);
|
|
103
104
|
if (!connector) {
|
|
104
105
|
noModal.log.error("Failed to setup vue wagmi connector");
|
|
105
106
|
throw new Error("Failed to setup connector");
|
|
@@ -132,7 +133,7 @@ const Web3AuthWagmiInnerProvider = vue.defineComponent({
|
|
|
132
133
|
const {
|
|
133
134
|
config
|
|
134
135
|
} = props;
|
|
135
|
-
vue.provide(vue$
|
|
136
|
+
vue.provide(vue$2.configKey, config);
|
|
136
137
|
},
|
|
137
138
|
render() {
|
|
138
139
|
var _this$$slots$default2;
|
|
@@ -221,7 +222,7 @@ const WagmiProvider = vue.defineComponent({
|
|
|
221
222
|
});
|
|
222
223
|
configParams.chains = [wagmiChains[0], ...wagmiChains.slice(1)];
|
|
223
224
|
}
|
|
224
|
-
return vue$
|
|
225
|
+
return vue$2.createConfig(configParams);
|
|
225
226
|
};
|
|
226
227
|
const hydrateWagmiConfig = () => {
|
|
227
228
|
if (finalConfig.value) {
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
var x402 = require('@web3auth/no-modal/x402');
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
|
|
7
|
+
Object.keys(x402).forEach(function (k) {
|
|
8
|
+
if (k !== 'default' && !Object.prototype.hasOwnProperty.call(exports, k)) Object.defineProperty(exports, k, {
|
|
9
|
+
enumerable: true,
|
|
10
|
+
get: function () { return x402[k]; }
|
|
11
|
+
});
|
|
12
|
+
});
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
var react = require('@web3auth/no-modal/x402/react');
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
|
|
7
|
+
Object.defineProperty(exports, "createEvmX402Fetch", {
|
|
8
|
+
enumerable: true,
|
|
9
|
+
get: function () { return react.createEvmX402Fetch; }
|
|
10
|
+
});
|
|
11
|
+
Object.defineProperty(exports, "createProviderBackedEvmSigner", {
|
|
12
|
+
enumerable: true,
|
|
13
|
+
get: function () { return react.createProviderBackedEvmSigner; }
|
|
14
|
+
});
|
|
15
|
+
Object.defineProperty(exports, "createSolanaX402Fetch", {
|
|
16
|
+
enumerable: true,
|
|
17
|
+
get: function () { return react.createSolanaX402Fetch; }
|
|
18
|
+
});
|
|
19
|
+
Object.defineProperty(exports, "getEvmAddress", {
|
|
20
|
+
enumerable: true,
|
|
21
|
+
get: function () { return react.getEvmAddress; }
|
|
22
|
+
});
|
|
23
|
+
Object.defineProperty(exports, "useX402Fetch", {
|
|
24
|
+
enumerable: true,
|
|
25
|
+
get: function () { return react.useX402Fetch; }
|
|
26
|
+
});
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
var vue = require('@web3auth/no-modal/x402/vue');
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
|
|
7
|
+
Object.defineProperty(exports, "createEvmX402Fetch", {
|
|
8
|
+
enumerable: true,
|
|
9
|
+
get: function () { return vue.createEvmX402Fetch; }
|
|
10
|
+
});
|
|
11
|
+
Object.defineProperty(exports, "createSolanaX402Fetch", {
|
|
12
|
+
enumerable: true,
|
|
13
|
+
get: function () { return vue.createSolanaX402Fetch; }
|
|
14
|
+
});
|
|
15
|
+
Object.defineProperty(exports, "useX402Fetch", {
|
|
16
|
+
enumerable: true,
|
|
17
|
+
get: function () { return vue.useX402Fetch; }
|
|
18
|
+
});
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { BaseConnectorConfig,
|
|
1
|
+
import type { BaseConnectorConfig, Connection, IWeb3Auth, LoginMethodConfig, WALLET_CONNECTOR_TYPE } from "@web3auth/no-modal";
|
|
2
2
|
export interface ModalConfig extends Omit<BaseConnectorConfig, "isInjected" | "chainNamespaces"> {
|
|
3
3
|
loginMethods?: LoginMethodConfig;
|
|
4
4
|
}
|
|
@@ -7,5 +7,5 @@ export interface ConnectorsModalConfig {
|
|
|
7
7
|
hideWalletDiscovery?: boolean;
|
|
8
8
|
}
|
|
9
9
|
export interface IWeb3AuthModal extends IWeb3Auth {
|
|
10
|
-
connect(): Promise<
|
|
10
|
+
connect(): Promise<Connection | null>;
|
|
11
11
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { type
|
|
1
|
+
import { type Connection, type IWeb3AuthCoreOptions, IWeb3AuthState, LoginModeType, type ProjectConfig, Web3AuthNoModal } from "@web3auth/no-modal";
|
|
2
2
|
import { type ConnectorsModalConfig, type IWeb3AuthModal } from "./interface";
|
|
3
3
|
import { LoginModal, type UIConfig } from "./ui";
|
|
4
4
|
export interface Web3AuthOptions extends IWeb3AuthCoreOptions {
|
|
@@ -13,13 +13,15 @@ export interface Web3AuthOptions extends IWeb3AuthCoreOptions {
|
|
|
13
13
|
}
|
|
14
14
|
export declare class Web3Auth extends Web3AuthNoModal implements IWeb3AuthModal {
|
|
15
15
|
loginModal: LoginModal;
|
|
16
|
+
loginMode: LoginModeType;
|
|
16
17
|
readonly options: Web3AuthOptions;
|
|
17
18
|
private modalConfig;
|
|
18
|
-
constructor(options: Web3AuthOptions, initialState?: IWeb3AuthState);
|
|
19
|
+
constructor(options: Web3AuthOptions, initialState?: Partial<IWeb3AuthState>);
|
|
19
20
|
init(options?: {
|
|
20
21
|
signal?: AbortSignal;
|
|
21
22
|
}): Promise<void>;
|
|
22
|
-
connect(): Promise<
|
|
23
|
+
connect(): Promise<Connection | null>;
|
|
24
|
+
acceptConsent(): Promise<void>;
|
|
23
25
|
protected initUIConfig(projectConfig: ProjectConfig): void;
|
|
24
26
|
protected getInitializationTrackData(): Record<string, unknown>;
|
|
25
27
|
private filterWalletRegistry;
|
|
@@ -34,6 +36,8 @@ export declare class Web3Auth extends Web3AuthNoModal implements IWeb3AuthModal
|
|
|
34
36
|
private onExternalWalletLogin;
|
|
35
37
|
private onModalVisibility;
|
|
36
38
|
private onMobileVerifyConnect;
|
|
39
|
+
private onAcceptConsent;
|
|
40
|
+
private onDeclineConsent;
|
|
37
41
|
private getChainNamespaces;
|
|
38
42
|
private getCombinedConnectionId;
|
|
39
43
|
}
|
|
@@ -1,6 +1,13 @@
|
|
|
1
|
-
import { Context, PropsWithChildren } from "react";
|
|
2
|
-
import { IWalletServicesContext
|
|
1
|
+
import { type Context, PropsWithChildren } from "react";
|
|
2
|
+
import { type IWalletServicesContext } from "../interfaces";
|
|
3
|
+
type IWeb3AuthContextForWalletServices = {
|
|
4
|
+
getPlugin: (name: string) => unknown;
|
|
5
|
+
isInitialized: boolean;
|
|
6
|
+
isConnected: boolean;
|
|
7
|
+
};
|
|
8
|
+
type WalletServicesContextProviderProps<TWeb3AuthContext extends IWeb3AuthContextForWalletServices> = PropsWithChildren<{
|
|
9
|
+
context: Context<TWeb3AuthContext>;
|
|
10
|
+
}>;
|
|
3
11
|
export declare const WalletServicesContext: Context<IWalletServicesContext>;
|
|
4
|
-
export declare function WalletServicesContextProvider({ children, context }:
|
|
5
|
-
|
|
6
|
-
}>): import("react").FunctionComponentElement<import("react").ProviderProps<IWalletServicesContext>>;
|
|
12
|
+
export declare function WalletServicesContextProvider<TWeb3AuthContext extends IWeb3AuthContextForWalletServices>({ children, context, }: WalletServicesContextProviderProps<TWeb3AuthContext>): import("react").FunctionComponentElement<import("react").ProviderProps<IWalletServicesContext>>;
|
|
13
|
+
export {};
|
|
@@ -1,4 +1,5 @@
|
|
|
1
|
+
import { Web3AuthInnerContext as Web3AuthInnerContextNoModal } from "@web3auth/no-modal/react";
|
|
1
2
|
import { PropsWithChildren } from "react";
|
|
2
|
-
import {
|
|
3
|
-
export
|
|
4
|
-
export declare function Web3AuthInnerProvider(params: PropsWithChildren<Web3AuthProviderProps>): import("react").FunctionComponentElement<import("react").ProviderProps<IWeb3AuthInnerContext>>;
|
|
3
|
+
import { Web3AuthProviderProps } from "../interfaces";
|
|
4
|
+
export { Web3AuthInnerContextNoModal as Web3AuthInnerContext };
|
|
5
|
+
export declare function Web3AuthInnerProvider(params: PropsWithChildren<Web3AuthProviderProps>): import("react").FunctionComponentElement<import("react").ProviderProps<import("@web3auth/no-modal/react").IWeb3AuthInnerContext>>;
|
|
@@ -1,16 +1,17 @@
|
|
|
1
|
-
export * from "./useChain";
|
|
2
|
-
export * from "./useCheckout";
|
|
3
|
-
export * from "./useEnableMFA";
|
|
4
|
-
export * from "./useFunding";
|
|
5
|
-
export * from "./useIdentityToken";
|
|
6
|
-
export * from "./useManageMFA";
|
|
7
|
-
export * from "./useReceive";
|
|
8
|
-
export * from "./useSwap";
|
|
9
|
-
export * from "./useSwitchChain";
|
|
10
|
-
export * from "./useWalletConnectScanner";
|
|
11
|
-
export * from "./useWalletServicesPlugin";
|
|
12
|
-
export * from "./useWalletUI";
|
|
13
1
|
export * from "./useWeb3Auth";
|
|
14
2
|
export * from "./useWeb3AuthConnect";
|
|
15
|
-
export
|
|
16
|
-
export
|
|
3
|
+
export type { IUseAuthTokenInfo, IUseChain, IUseCheckout, IUseEnableMFA, IUseFunding, IUseManageMFA, IUseReceive, IUseSwap, IUseSwitchChain, IUseWalletConnectScanner, IUseWalletUI, IUseWeb3AuthDisconnect, IUseWeb3AuthUser, } from "@web3auth/no-modal/react";
|
|
4
|
+
export { useAuthTokenInfo } from "@web3auth/no-modal/react";
|
|
5
|
+
export { useChain } from "@web3auth/no-modal/react";
|
|
6
|
+
export { useCheckout } from "@web3auth/no-modal/react";
|
|
7
|
+
export { useEnableMFA } from "@web3auth/no-modal/react";
|
|
8
|
+
export { useFunding } from "@web3auth/no-modal/react";
|
|
9
|
+
export { useManageMFA } from "@web3auth/no-modal/react";
|
|
10
|
+
export { useReceive } from "@web3auth/no-modal/react";
|
|
11
|
+
export { useSwap } from "@web3auth/no-modal/react";
|
|
12
|
+
export { useSwitchChain } from "@web3auth/no-modal/react";
|
|
13
|
+
export { useWalletConnectScanner } from "@web3auth/no-modal/react";
|
|
14
|
+
export { useWalletServicesPlugin } from "@web3auth/no-modal/react";
|
|
15
|
+
export { useWalletUI } from "@web3auth/no-modal/react";
|
|
16
|
+
export { useWeb3AuthDisconnect } from "@web3auth/no-modal/react";
|
|
17
|
+
export { useWeb3AuthUser } from "@web3auth/no-modal/react";
|
|
@@ -1,3 +1,2 @@
|
|
|
1
1
|
import { IWeb3AuthInnerContext } from "../interfaces";
|
|
2
|
-
export
|
|
3
|
-
export declare const useWeb3Auth: () => IUseWeb3Auth;
|
|
2
|
+
export declare const useWeb3Auth: () => IWeb3AuthInnerContext;
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import type {
|
|
1
|
+
import type { Connection, LoginParamMap, WALLET_CONNECTOR_TYPE, Web3AuthError } from "@web3auth/no-modal";
|
|
2
2
|
export interface IUseWeb3AuthConnect {
|
|
3
3
|
isConnected: boolean;
|
|
4
4
|
loading: boolean;
|
|
5
5
|
error: Web3AuthError | null;
|
|
6
6
|
connectorName: WALLET_CONNECTOR_TYPE | null;
|
|
7
|
-
connect(): Promise<
|
|
8
|
-
connectTo<T extends WALLET_CONNECTOR_TYPE>(connector: T, params?: LoginParamMap[T]): Promise<
|
|
7
|
+
connect(): Promise<Connection | null>;
|
|
8
|
+
connectTo<T extends WALLET_CONNECTOR_TYPE>(connector: T, params?: LoginParamMap[T]): Promise<Connection | null>;
|
|
9
9
|
}
|
|
10
10
|
export declare const useWeb3AuthConnect: () => IUseWeb3AuthConnect;
|
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import type {
|
|
1
|
+
import type { IWeb3AuthState, WalletServicesPluginType } from "@web3auth/no-modal";
|
|
2
|
+
import type { IWeb3AuthInnerContext as INoModalWeb3AuthInnerContext } from "@web3auth/no-modal/react";
|
|
2
3
|
import type { Web3Auth, Web3AuthOptions } from "../modalManager";
|
|
3
4
|
export type Web3AuthContextConfig = {
|
|
4
5
|
web3AuthOptions: Web3AuthOptions;
|
|
@@ -7,7 +8,7 @@ export interface Web3AuthProviderProps {
|
|
|
7
8
|
config: Web3AuthContextConfig;
|
|
8
9
|
initialState?: IWeb3AuthState;
|
|
9
10
|
}
|
|
10
|
-
export interface IWeb3AuthInnerContext extends
|
|
11
|
+
export interface IWeb3AuthInnerContext extends Omit<INoModalWeb3AuthInnerContext, "web3Auth"> {
|
|
11
12
|
web3Auth: Web3Auth | null;
|
|
12
13
|
}
|
|
13
14
|
export interface IWalletServicesContext {
|
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
export
|
|
2
|
-
export
|
|
3
|
-
export
|
|
4
|
-
export
|
|
1
|
+
export type { IUseSignAndSendTransaction, IUseSignMessage, IUseSignTransaction, IUseSolanaWallet } from "@web3auth/no-modal/react/solana";
|
|
2
|
+
export { useSignAndSendTransaction } from "@web3auth/no-modal/react/solana";
|
|
3
|
+
export { useSignMessage } from "@web3auth/no-modal/react/solana";
|
|
4
|
+
export { useSignTransaction } from "@web3auth/no-modal/react/solana";
|
|
5
|
+
export { useSolanaWallet } from "@web3auth/no-modal/react/solana";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { SolanaProvider } from "@web3auth/no-modal/react/solana";
|
|
@@ -3,5 +3,5 @@ import { BottomSheetProps } from "./BottomSheet.type";
|
|
|
3
3
|
* BottomSheet component
|
|
4
4
|
* @returns BottomSheet component
|
|
5
5
|
*/
|
|
6
|
-
declare function BottomSheet({ isShown, onClose, children,
|
|
6
|
+
declare function BottomSheet({ isShown, onClose, children, sheetClassName, showCloseButton, borderRadiusType }: BottomSheetProps): import("react/jsx-runtime").JSX.Element;
|
|
7
7
|
export default BottomSheet;
|
|
@@ -1,9 +1,10 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { type ReactNode } from "react";
|
|
2
|
+
import { BorderRadiusType } from "../../interfaces";
|
|
2
3
|
export interface BottomSheetProps {
|
|
3
4
|
isShown: boolean;
|
|
4
|
-
uiConfig: UIConfig;
|
|
5
5
|
onClose: () => void;
|
|
6
|
-
children:
|
|
6
|
+
children: ReactNode;
|
|
7
7
|
sheetClassName?: string;
|
|
8
8
|
showCloseButton?: boolean;
|
|
9
|
+
borderRadiusType?: BorderRadiusType;
|
|
9
10
|
}
|
|
@@ -1,10 +1,8 @@
|
|
|
1
|
-
import { BaseConnectorConfig, WALLET_CONNECTOR_TYPE
|
|
1
|
+
import { BaseConnectorConfig, WALLET_CONNECTOR_TYPE } from "@web3auth/no-modal";
|
|
2
2
|
import type { ModalStatusType } from "../../interfaces";
|
|
3
3
|
export interface LoaderProps {
|
|
4
4
|
externalWalletsConfig: Record<string, BaseConnectorConfig>;
|
|
5
|
-
walletRegistry?: WalletRegistry;
|
|
6
5
|
message?: string;
|
|
7
|
-
appLogo?: string;
|
|
8
6
|
connector: string;
|
|
9
7
|
connectorName: string;
|
|
10
8
|
modalStatus: ModalStatusType;
|
|
@@ -14,8 +12,12 @@ export interface LoaderProps {
|
|
|
14
12
|
connector: WALLET_CONNECTOR_TYPE;
|
|
15
13
|
}) => void;
|
|
16
14
|
hideSuccessScreen?: boolean;
|
|
15
|
+
onAcceptConsent?: () => void | Promise<void>;
|
|
16
|
+
onDeclineConsent?: () => void | Promise<void>;
|
|
17
|
+
privacyPolicy?: string;
|
|
18
|
+
tncLink?: string;
|
|
17
19
|
}
|
|
18
|
-
export type ConnectingStatusType = Pick<LoaderProps, "connectorName" | "
|
|
20
|
+
export type ConnectingStatusType = Pick<LoaderProps, "connectorName" | "connector">;
|
|
19
21
|
export type ConnectedStatusType = Pick<LoaderProps, "message">;
|
|
20
22
|
export type ErroredStatusType = Pick<LoaderProps, "message">;
|
|
21
|
-
export type AuthorizingStatusType = Pick<LoaderProps, "connector" | "externalWalletsConfig" | "
|
|
23
|
+
export type AuthorizingStatusType = Pick<LoaderProps, "connector" | "externalWalletsConfig" | "handleMobileVerifyConnect">;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import type { ReactNode } from "react";
|
|
2
|
+
export type SpinnerLoaderClassesKey = "spinner";
|
|
3
|
+
export interface SpinnerLoaderProps {
|
|
4
|
+
children?: ReactNode;
|
|
5
|
+
classes?: Partial<Record<SpinnerLoaderClassesKey, string>>;
|
|
6
|
+
width?: number | string;
|
|
7
|
+
height?: number | string;
|
|
8
|
+
className?: string;
|
|
9
|
+
}
|
|
@@ -1,12 +1,15 @@
|
|
|
1
1
|
import { WalletRegistryItem } from "@web3auth/no-modal";
|
|
2
2
|
export declare const PAGES: {
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
3
|
+
/** Main login options: social logins and wallet button (e.g. MetaMask) */
|
|
4
|
+
LOGIN_OPTIONS: string;
|
|
5
|
+
/** List of all available wallets to connect */
|
|
6
|
+
WALLET_LIST: string;
|
|
7
|
+
/** QR code or instructions for connecting to the selected wallet */
|
|
8
|
+
WALLET_CONNECTION_DETAILS: string;
|
|
7
9
|
};
|
|
8
10
|
export declare const CONNECT_WALLET_PAGES: {
|
|
9
11
|
CONNECT_WALLET: string;
|
|
12
|
+
/** Sub-page title when showing QR/instructions for selected wallet */
|
|
10
13
|
SELECTED_WALLET: string;
|
|
11
14
|
};
|
|
12
15
|
export declare const DEFAULT_LOGO_LIGHT = "https://images.web3auth.io/web3auth-logo-w.svg";
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import type { ExternalButton } from "../../interfaces";
|
|
2
|
+
export interface ConnectWalletProps {
|
|
3
|
+
allRegistryButtons: ExternalButton[];
|
|
4
|
+
customConnectorButtons: ExternalButton[];
|
|
5
|
+
connectorVisibilityMap: Record<string, boolean>;
|
|
6
|
+
isExternalWalletModeOnly?: boolean;
|
|
7
|
+
}
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import type { ChainNamespaceType } from "@web3auth/no-modal";
|
|
2
1
|
export interface Chain {
|
|
3
2
|
id: string;
|
|
4
3
|
name: string;
|
|
@@ -8,6 +7,5 @@ export interface ConnectWalletChainFilterProps {
|
|
|
8
7
|
isDark: boolean;
|
|
9
8
|
isLoading: boolean;
|
|
10
9
|
selectedChain: string;
|
|
11
|
-
chainNamespace: ChainNamespaceType[];
|
|
12
10
|
setSelectedChain: (chain: string) => void;
|
|
13
11
|
}
|
|
@@ -1,20 +1,14 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { ExternalButton } from "../../../interfaces";
|
|
2
2
|
export interface ConnectWalletListProps {
|
|
3
3
|
externalButtons: ExternalButton[];
|
|
4
4
|
isLoading: boolean;
|
|
5
5
|
totalExternalWalletsCount: number;
|
|
6
6
|
initialWalletCount: number;
|
|
7
7
|
isDark: boolean;
|
|
8
|
-
deviceDetails: {
|
|
9
|
-
platform: platform;
|
|
10
|
-
browser: browser;
|
|
11
|
-
os: os;
|
|
12
|
-
};
|
|
13
8
|
walletConnectUri: string;
|
|
14
|
-
buttonRadius: ButtonRadiusType;
|
|
15
9
|
handleWalletClick: (button: ExternalButton) => void;
|
|
16
10
|
handleMoreWallets: () => void;
|
|
17
11
|
isShowAllWallets: boolean;
|
|
18
12
|
}
|
|
19
|
-
export type WalletsFoundProps = Pick<ConnectWalletListProps, "externalButtons" | "isLoading" | "handleWalletClick" | "
|
|
20
|
-
export type MoreWalletsButtonProps = Pick<ConnectWalletListProps, "totalExternalWalletsCount" | "initialWalletCount" | "handleMoreWallets" | "isLoading" | "isDark"
|
|
13
|
+
export type WalletsFoundProps = Pick<ConnectWalletListProps, "externalButtons" | "isLoading" | "handleWalletClick" | "walletConnectUri">;
|
|
14
|
+
export type MoreWalletsButtonProps = Pick<ConnectWalletListProps, "totalExternalWalletsCount" | "initialWalletCount" | "handleMoreWallets" | "isLoading" | "isDark">;
|
|
@@ -1,9 +1,7 @@
|
|
|
1
1
|
import type { FormEvent } from "react";
|
|
2
|
-
import type { ButtonRadiusType } from "../../../interfaces";
|
|
3
2
|
export interface ConnectWalletSearchProps {
|
|
4
3
|
totalExternalWalletCount: number;
|
|
5
4
|
isLoading: boolean;
|
|
6
5
|
walletSearch: string;
|
|
7
6
|
handleWalletSearch: (e: FormEvent<HTMLInputElement>) => void;
|
|
8
|
-
buttonRadius: ButtonRadiusType;
|
|
9
7
|
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export default function RootBodySheets(): import("react/jsx-runtime").JSX.Element;
|