@privy-io/react-auth 1.87.0-beta-20240920184838 → 1.87.0-beta-20240924131550
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/getEmbeddedConnectedWallet.js +1 -0
- package/dist/cjs/index.js +3113 -0
- package/dist/cjs/internal-context.js +1 -0
- package/dist/cjs/smart-wallets.js +1 -0
- package/dist/cjs/solana.js +1 -0
- package/dist/cjs/ui.js +132 -0
- package/dist/cjs/useFundWallet.js +118 -0
- package/dist/cjs/useSolanaWallets.js +1 -0
- package/dist/cjs/useWallets.js +1 -0
- package/dist/dts/index.d.mts +2448 -0
- package/dist/{index.d.ts → dts/index.d.ts} +21 -8
- package/dist/dts/smart-wallets.d.mts +728 -0
- package/dist/{smart-wallets.d.ts → dts/smart-wallets.d.ts} +1 -1
- package/dist/dts/solana.d.mts +65 -0
- package/dist/{solana.d.ts → dts/solana.d.ts} +3 -3
- package/dist/{types-eaea6708.d.ts → dts/types.d.mts} +44 -1
- package/dist/dts/types.d.ts +2251 -0
- package/dist/dts/ui.d.mts +29 -0
- package/dist/{ui.d.ts → dts/ui.d.ts} +1 -1
- package/dist/esm/getEmbeddedConnectedWallet.mjs +1 -0
- package/dist/esm/index.mjs +3113 -0
- package/dist/esm/internal-context.mjs +1 -0
- package/dist/esm/smart-wallets.mjs +1 -0
- package/dist/esm/solana.mjs +1 -0
- package/dist/esm/ui.mjs +132 -0
- package/dist/esm/useFundWallet.mjs +118 -0
- package/dist/esm/useSolanaWallets.mjs +1 -0
- package/dist/esm/useWallets.mjs +1 -0
- package/package.json +58 -29
- package/dist/chunk-4ODVFLKF.js +0 -1
- package/dist/chunk-4RGQ4R3M.js +0 -118
- package/dist/chunk-E7B7OFUX.js +0 -3376
- package/dist/chunk-VGM5FGSZ.js +0 -1
- package/dist/esm/chunk-4ODVFLKF.js +0 -1
- package/dist/esm/chunk-4RGQ4R3M.js +0 -118
- package/dist/esm/chunk-E7B7OFUX.js +0 -3376
- package/dist/esm/chunk-VGM5FGSZ.js +0 -1
- package/dist/esm/index.js +0 -1
- package/dist/esm/smart-wallets.js +0 -1
- package/dist/esm/solana.js +0 -1
- package/dist/esm/ui.js +0 -142
- package/dist/index.js +0 -1
- package/dist/smart-wallets.js +0 -1
- package/dist/solana.js +0 -1
- package/dist/ui.js +0 -142
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import * as react from 'react';
|
|
2
2
|
import react__default, { MouseEvent } from 'react';
|
|
3
|
-
import { C as Chain, W as WalletConnector, B as BaseConnectedEthereumWallet, a as RpcConfig, P as PrivyProxyProvider, E as Embedded1193Provider, b as WalletClientType, c as ConnectedWalletMetadata, d as ConnectorType, e as WalletListEntry, f as ExternalWalletsConfig, g as BaseConnectedWallet, S as SolanaWalletConnector, h as EIP1193Provider, U as User, O as OAuthTokens, i as OAuthProviderType, M as MoonpaySignRequest, j as MoonpaySignResponse, k as SmartWalletConfig, l as PrivyServerConfig, m as PrivyFarcasterSignerInitResponse, L as LoginMethod, T as TelegramAuthResult,
|
|
4
|
-
export {
|
|
3
|
+
import { C as Chain, W as WalletConnector, B as BaseConnectedEthereumWallet, a as RpcConfig, P as PrivyProxyProvider, E as Embedded1193Provider, b as WalletClientType, c as ConnectedWalletMetadata, d as ConnectorType, e as WalletListEntry, f as ExternalWalletsConfig, g as BaseConnectedWallet, S as SolanaWalletConnector, h as EIP1193Provider, U as User, O as OAuthTokens, i as OAuthProviderType, M as MoonpaySignRequest, j as MoonpaySignResponse, k as SmartWalletConfig, l as PrivyServerConfig, m as PrivyFarcasterSignerInitResponse, L as LoginMethod, n as SiweWalletMetadata, T as TelegramAuthResult, o as OAuthUserInfo, p as PrivyClientConfig, q as ConnectWalletModalOptions, r as LoginModalOptions, s as CreateWalletOptions, t as Wallet, u as SetWalletRecoveryOptions, v as SignMessageModalUIOptions, w as SignTypedDataParams, x as MfaMethod, y as UnsignedTransactionRequest, z as SendTransactionModalUIOptions, F as FundWalletConfig, A as TransactionReceipt, D as ConnectedWallet, G as PrivyIframeErrorTypesType, H as PrivyErrorCode, I as LinkedAccountWithMetadata, J as UserRecoveryMethod, K as FundingMethod, N as OAuthFlowState, Q as LoginWithCode, V as OtpFlowState, X as PasskeyFlowState, Y as SiweFlowState, Z as UnsignedTransactionRequestWithChainId, _ as CustomAuthFlowState } from './types.js';
|
|
4
|
+
export { ag as Apple, aq as AppleOAuthWithMetadata, $ as AsExternalProvider, aF as ConnectedSolanaWallet, ay as ContractUIOptions, aj as CrossAppAccount, at as CrossAppAccountWithMetadata, ad as Discord, am as DiscordOAuthWithMetadata, av as Email, a8 as EmailWithMetadata, aC as Farcaster, ar as FarcasterWithMetadata, ae as Github, an as GithubOAuthWithMetadata, ab as Google, ak as GoogleOAuthWithMetadata, af as LinkedIn, ap as LinkedInOAuthWithMetadata, aE as LoginMethodOrderOption, a1 as MessageTypes, a2 as MoonpayConfig, a3 as MoonpayCurrencyCode, aA as MoonpayFundingConfig, a4 as MoonpayPaymentMethod, az as NativeFundingConfig, a7 as NonEmptyArray, aD as Passkey, au as PasskeyWithMetadata, aw as Phone, a9 as PhoneWithMetadata, aB as PriceDisplayOptions, a5 as Quantity, ai as Telegram, as as TelegramWithMetadata, ah as Tiktok, ao as TiktokOAuthWithMetadata, a6 as TransactionLog, ax as TransactionUIOptions, ac as Twitter, al as TwitterOAuthWithMetadata, a0 as TypedMessage, aa as WalletWithMetadata } from './types.js';
|
|
5
5
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
6
6
|
import { TurnstileProps } from '@marsidev/react-turnstile';
|
|
7
7
|
import EventEmitter from 'eventemitter3';
|
|
@@ -654,15 +654,14 @@ declare class PrivyClient {
|
|
|
654
654
|
/**
|
|
655
655
|
*
|
|
656
656
|
*/
|
|
657
|
-
sendAccountTransferRequest({ nonce, account, accountType,
|
|
657
|
+
sendAccountTransferRequest({ nonce, account, accountType, externalWalletMetadata, telegramAuthResult, farcasterEmbeddedAddress, oAuthUserInfo, }: {
|
|
658
658
|
nonce: string;
|
|
659
659
|
account: string;
|
|
660
660
|
accountType: LoginMethod;
|
|
661
|
-
|
|
662
|
-
walletClientType?: string;
|
|
663
|
-
connectorType?: string;
|
|
661
|
+
externalWalletMetadata?: SiweWalletMetadata;
|
|
664
662
|
telegramAuthResult?: TelegramAuthResult;
|
|
665
663
|
farcasterEmbeddedAddress?: string;
|
|
664
|
+
oAuthUserInfo?: OAuthUserInfo;
|
|
666
665
|
}): Promise<User>;
|
|
667
666
|
/**
|
|
668
667
|
* Headless method to link a new wallet via the Sign-In with Solana spec.
|
|
@@ -1465,7 +1464,7 @@ declare function errorIndicatesMfaTimeout(error: unknown): error is PrivyIframeE
|
|
|
1465
1464
|
declare function errorIndicatesMfaVerificationFailed(error: unknown): error is PrivyIframeError;
|
|
1466
1465
|
declare function errorIndicatesMaxMfaRetries(error: unknown): error is PrivyIframeError;
|
|
1467
1466
|
|
|
1468
|
-
declare const VERSION
|
|
1467
|
+
declare const VERSION = "__VERSION__";
|
|
1469
1468
|
|
|
1470
1469
|
/**
|
|
1471
1470
|
* `CallbackError` optionally includes a second parameter with further error details.
|
|
@@ -1774,6 +1773,10 @@ type UseLoginWithOAuth = {
|
|
|
1774
1773
|
* Indicates a headless OAuth flow is in progress
|
|
1775
1774
|
*/
|
|
1776
1775
|
loading: boolean;
|
|
1776
|
+
/**
|
|
1777
|
+
* The current state of the login with OAuth flow.
|
|
1778
|
+
*/
|
|
1779
|
+
state: OAuthFlowState;
|
|
1777
1780
|
};
|
|
1778
1781
|
/**
|
|
1779
1782
|
* @experimental
|
|
@@ -1812,6 +1815,10 @@ type UseLoginWithEmail = {
|
|
|
1812
1815
|
* @returns a Promise that resolves if the inputted OTP was valid, or rejects if there was an error.
|
|
1813
1816
|
*/
|
|
1814
1817
|
loginWithCode: ({ code }: LoginWithCode) => Promise<void>;
|
|
1818
|
+
/**
|
|
1819
|
+
* The current state of the login with Email flow.
|
|
1820
|
+
*/
|
|
1821
|
+
state: OtpFlowState;
|
|
1815
1822
|
};
|
|
1816
1823
|
/**
|
|
1817
1824
|
* @experimental
|
|
@@ -1820,6 +1827,7 @@ type UseLoginWithEmail = {
|
|
|
1820
1827
|
*
|
|
1821
1828
|
* @returns sendCode - {@link sendCode} sends a one-time-code to the user's email address.
|
|
1822
1829
|
* @returns loginWithCode - {@link loginWithCode} - logs a user in with a one-time-code, maximum 5 attempts.
|
|
1830
|
+
* @returns state - {@link OtpFlowState} - the current state of the login with Email flow.
|
|
1823
1831
|
*/
|
|
1824
1832
|
declare const useLoginWithEmail: () => UseLoginWithEmail;
|
|
1825
1833
|
|
|
@@ -1891,6 +1899,7 @@ type UseLoginWithSms = {
|
|
|
1891
1899
|
*
|
|
1892
1900
|
* @returns sendCode - {@link sendCode} sends a one-time-code to the user's phone number.
|
|
1893
1901
|
* @returns loginWithCode - {@link loginWithCode} - logs a user in with a one-time-code, maximum 5 attempts.
|
|
1902
|
+
* @returns state - {@link OtpFlowState} - the current state of the login with Email flow.
|
|
1894
1903
|
*/
|
|
1895
1904
|
declare const useLoginWithSms: () => UseLoginWithSms;
|
|
1896
1905
|
|
|
@@ -1926,6 +1935,10 @@ type UseLinkWithSiwe = {
|
|
|
1926
1935
|
walletClientType?: string;
|
|
1927
1936
|
connectorType?: string;
|
|
1928
1937
|
}) => Promise<void>;
|
|
1938
|
+
/**
|
|
1939
|
+
* The current state of the SIWE link operation
|
|
1940
|
+
*/
|
|
1941
|
+
state: SiweFlowState;
|
|
1929
1942
|
};
|
|
1930
1943
|
/**
|
|
1931
1944
|
* @experimental
|
|
@@ -2432,4 +2445,4 @@ declare const LoginModal: ({ open }: {
|
|
|
2432
2445
|
open: boolean;
|
|
2433
2446
|
}) => react_jsx_runtime.JSX.Element;
|
|
2434
2447
|
|
|
2435
|
-
export { CallbackError, Captcha, ConnectWalletModalOptions, ConnectedWallet, ConnectorManager, CustomAuthFlowState, EIP1193Provider, EthereumWalletConnector, FundWalletConfig, LoginModal, LoginModalOptions, LoginWithCode, MfaMethod, OAuthProviderType, OAuthTokens, PasskeyFlowState, PrivyClient, PrivyClientConfig, PrivyEvents, PrivyInterface, PrivyProvider, PrivyProviderProps, PrivyProxyProvider, DEFAULT_SUPPORTED_CHAINS as SUPPORTED_CHAINS, SendCodeToEmail, SendCodeToSms, SendTransactionModalUIOptions, SignMessageModalUIOptions, SignTypedDataParams, SolanaTransactionReceipt, SupportedSolanaTransaction, TransactionReceipt, UnsignedTransactionRequest, UseConnectCoinbaseSmartWalletInterface, UseCustomAuth, UseFundWalletInterface, UseLoginWithEmail, UseLoginWithPasskey, UseLoginWithSms, UseOAuthTokens, UseWalletsInterface, User, VERSION, Wallet, WalletConnector, WalletListEntry, addRpcUrlOverrideToChain, errorIndicatesMaxMfaRetries, errorIndicatesMfaTimeout, errorIndicatesMfaVerificationFailed, getAccessToken, getEmbeddedConnectedWallet, useConnectCoinbaseSmartWallet, useConnectWallet, useCreateWallet, useCrossAppAccounts, useCustomAuth, useExperimentalFarcasterSigner, useFarcasterSigner, useFundWallet, useGuestAccounts, useLinkAccount, useLinkWithSiwe, useLogin, useLoginWithEmail, useLoginWithOAuth, useLoginWithPasskey, useLoginWithSms, useLogout, useMfa, useMfaEnrollment, useModalStatus, useOAuthTokens, usePrivy, useRegisterMfaListener, useSendSolanaTransaction, useSendTransaction, useSetWalletPassword, useSetWalletRecovery, useSignMessage, useSignTypedData, useToken, useWallets };
|
|
2448
|
+
export { type CallbackError, Captcha, ConnectWalletModalOptions, ConnectedWallet, ConnectorManager, CustomAuthFlowState, EIP1193Provider, EthereumWalletConnector, FundWalletConfig, LoginModal, LoginModalOptions, LoginWithCode, MfaMethod, OAuthFlowState, OAuthProviderType, OAuthTokens, OtpFlowState, PasskeyFlowState, PrivyClient, PrivyClientConfig, type PrivyEvents, type PrivyInterface, PrivyProvider, type PrivyProviderProps, PrivyProxyProvider, DEFAULT_SUPPORTED_CHAINS as SUPPORTED_CHAINS, type SendCodeToEmail, type SendCodeToSms, SendTransactionModalUIOptions, SignMessageModalUIOptions, SignTypedDataParams, SiweFlowState, SolanaTransactionReceipt, SupportedSolanaTransaction, TransactionReceipt, UnsignedTransactionRequest, type UseConnectCoinbaseSmartWalletInterface, type UseCustomAuth, type UseFundWalletInterface, type UseLoginWithEmail, type UseLoginWithPasskey, type UseLoginWithSms, type UseOAuthTokens, type UseWalletsInterface, User, VERSION, Wallet, WalletConnector, WalletListEntry, addRpcUrlOverrideToChain, errorIndicatesMaxMfaRetries, errorIndicatesMfaTimeout, errorIndicatesMfaVerificationFailed, getAccessToken, getEmbeddedConnectedWallet, useConnectCoinbaseSmartWallet, useConnectWallet, useCreateWallet, useCrossAppAccounts, useCustomAuth, useExperimentalFarcasterSigner, useFarcasterSigner, useFundWallet, useGuestAccounts, useLinkAccount, useLinkWithSiwe, useLogin, useLoginWithEmail, useLoginWithOAuth, useLoginWithPasskey, useLoginWithSms, useLogout, useMfa, useMfaEnrollment, useModalStatus, useOAuthTokens, usePrivy, useRegisterMfaListener, useSendSolanaTransaction, useSendTransaction, useSetWalletPassword, useSetWalletRecovery, useSignMessage, useSignTypedData, useToken, useWallets };
|