@web3auth/base
Advanced tools
Comparing version 8.5.0 to 8.6.0-alpha.0
@@ -619,3 +619,4 @@ /******/ (() => { // webpackBootstrap | ||
OPENLOGIN: "openlogin", | ||
WALLET_CONNECT_V2: "wallet-connect-v2" | ||
WALLET_CONNECT_V2: "wallet-connect-v2", | ||
SFA: "sfa" | ||
}; | ||
@@ -637,2 +638,3 @@ const SOLANA_ADAPTERS = objectSpread2_default()({ | ||
[MULTI_CHAIN_ADAPTERS.WALLET_CONNECT_V2]: "Wallet Connect v2", | ||
[MULTI_CHAIN_ADAPTERS.SFA]: "SFA", | ||
[SOLANA_ADAPTERS.TORUS_SOLANA]: "Torus", | ||
@@ -639,0 +641,0 @@ [SOLANA_ADAPTERS.PHANTOM]: "Phantom", |
@@ -517,3 +517,4 @@ import _defineProperty from '@babel/runtime/helpers/defineProperty'; | ||
OPENLOGIN: "openlogin", | ||
WALLET_CONNECT_V2: "wallet-connect-v2" | ||
WALLET_CONNECT_V2: "wallet-connect-v2", | ||
SFA: "sfa" | ||
}; | ||
@@ -535,2 +536,3 @@ const SOLANA_ADAPTERS = _objectSpread({ | ||
[MULTI_CHAIN_ADAPTERS.WALLET_CONNECT_V2]: "Wallet Connect v2", | ||
[MULTI_CHAIN_ADAPTERS.SFA]: "SFA", | ||
[SOLANA_ADAPTERS.TORUS_SOLANA]: "Torus", | ||
@@ -537,0 +539,0 @@ [SOLANA_ADAPTERS.PHANTOM]: "Phantom", |
@@ -58,18 +58,8 @@ import { SafeEventEmitter } from "@toruslabs/openlogin-jrpc"; | ||
} | ||
export interface IWeb3Auth extends SafeEventEmitter { | ||
export interface IWeb3AuthCore extends SafeEventEmitter { | ||
readonly coreOptions: IWeb3AuthCoreOptions; | ||
connected: boolean; | ||
connectedAdapterName: string | null; | ||
status: ADAPTER_STATUS_TYPE; | ||
cachedAdapter: string | null; | ||
provider: IProvider | null; | ||
walletAdapters: Record<string, IAdapter<unknown>>; | ||
init(): Promise<void>; | ||
getAdapter(adapterName: WALLET_ADAPTER_TYPE): IAdapter<unknown> | null; | ||
configureAdapter(adapter: IAdapter<unknown>): IWeb3Auth; | ||
/** | ||
* Connect to a specific wallet adapter | ||
* @param walletName - Key of the walletAdapter to use. | ||
*/ | ||
connectTo<T>(walletName: WALLET_ADAPTER_TYPE, loginParams?: T): Promise<IProvider | null>; | ||
logout(options?: { | ||
@@ -84,6 +74,18 @@ cleanup: boolean; | ||
}): Promise<void>; | ||
enableMFA<T>(params: T): Promise<void>; | ||
addPlugin(plugin: IPlugin): void; | ||
getPlugin(pluginName: string): IPlugin | null; | ||
} | ||
export interface IWeb3Auth extends IWeb3AuthCore { | ||
connected: boolean; | ||
cachedAdapter: string | null; | ||
walletAdapters: Record<string, IAdapter<unknown>>; | ||
getAdapter(adapterName: WALLET_ADAPTER_TYPE): IAdapter<unknown> | null; | ||
configureAdapter(adapter: IAdapter<unknown>): IWeb3Auth; | ||
/** | ||
* Connect to a specific wallet adapter | ||
* @param walletName - Key of the walletAdapter to use. | ||
*/ | ||
connectTo<T>(walletName: WALLET_ADAPTER_TYPE, loginParams?: T): Promise<IProvider | null>; | ||
enableMFA<T>(params: T): Promise<void>; | ||
} | ||
export type Web3AuthNoModalOptions = IWeb3AuthCoreOptions; |
import { type SafeEventEmitter } from "@toruslabs/openlogin-jrpc"; | ||
import { IProvider, UserInfo } from "../adapter"; | ||
import { type IWeb3Auth } from "../core/IWeb3Auth"; | ||
import { WhiteLabelData } from "@toruslabs/openlogin-utils"; | ||
import { type IWeb3AuthCore } from "../core/IWeb3Auth"; | ||
import { WALLET_ADAPTER_TYPE } from "../wallet"; | ||
@@ -39,2 +39,6 @@ export declare const PLUGIN_NAMESPACES: { | ||
}; | ||
export interface PluginConnectParams { | ||
sessionId: string; | ||
sessionNamespace?: string; | ||
} | ||
export interface IPlugin extends SafeEventEmitter { | ||
@@ -45,6 +49,5 @@ name: string; | ||
pluginNamespace: PluginNamespace; | ||
initWithProvider(provider: IProvider, userInfo: UserInfo): Promise<void>; | ||
initWithWeb3Auth(web3auth: IWeb3Auth): Promise<void>; | ||
connect(): Promise<void>; | ||
initWithWeb3Auth(web3auth: IWeb3AuthCore, whiteLabel?: WhiteLabelData): Promise<void>; | ||
connect(params: PluginConnectParams): Promise<void>; | ||
disconnect(): Promise<void>; | ||
} |
export declare const MULTI_CHAIN_ADAPTERS: { | ||
OPENLOGIN: string; | ||
WALLET_CONNECT_V2: string; | ||
SFA: string; | ||
}; | ||
@@ -8,2 +9,3 @@ export declare const SOLANA_ADAPTERS: { | ||
WALLET_CONNECT_V2: string; | ||
SFA: string; | ||
TORUS_SOLANA: string; | ||
@@ -17,2 +19,3 @@ PHANTOM: string; | ||
WALLET_CONNECT_V2: string; | ||
SFA: string; | ||
TORUS_EVM: string; | ||
@@ -25,2 +28,3 @@ METAMASK: string; | ||
WALLET_CONNECT_V2: string; | ||
SFA: string; | ||
TORUS_SOLANA: string; | ||
@@ -27,0 +31,0 @@ PHANTOM: string; |
{ | ||
"name": "@web3auth/base", | ||
"version": "8.5.0", | ||
"version": "8.6.0-alpha.0", | ||
"homepage": "https://github.com/Web3Auth/Web3Auth#readme", | ||
@@ -24,5 +24,5 @@ "license": "ISC", | ||
"@toruslabs/http-helpers": "^6.1.1", | ||
"@toruslabs/openlogin": "^8.1.0", | ||
"@toruslabs/openlogin": "^8.1.2", | ||
"@toruslabs/openlogin-jrpc": "^8.1.1", | ||
"@toruslabs/openlogin-utils": "^8.1.0", | ||
"@toruslabs/openlogin-utils": "^8.1.2", | ||
"jwt-decode": "^4.0.0", | ||
@@ -59,3 +59,3 @@ "loglevel": "^1.9.1", | ||
}, | ||
"gitHead": "77ffe49908153bf2f4dbcb24ed729ef1482b9d06" | ||
"gitHead": "c101f5f4c81f5f2f3fff75152c4b9821582824db" | ||
} |
Sorry, the diff of this file is too big to display
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
No v1
QualityPackage is not semver >=1. This means it is not stable and does not support ^ ranges.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
267653
2353
1