superstack-wallet-sdk 0.4.13 → 0.5.1
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/esm/src/client.js +1 -1
- package/dist/esm/src/client.js.map +1 -1
- package/dist/esm/src/index.js +1 -1
- package/dist/esm/src/index.js.map +1 -1
- package/dist/esm/src/storage.js +1 -1
- package/dist/esm/src/storage.js.map +1 -1
- package/dist/esm/types/client.d.ts +2 -2
- package/dist/esm/types/storage.d.ts +3 -0
- package/dist/index.cjs +123 -123
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.ts +6 -3
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -292,11 +292,11 @@ declare class WalletClient {
|
|
|
292
292
|
sendEthereumTransaction(signedTransaction: string): Promise<string>;
|
|
293
293
|
sendEmailVerificationCode(email: string): Promise<void>;
|
|
294
294
|
sendPhoneVerificationCode(phone: string): Promise<void>;
|
|
295
|
-
verifyEmailVerificationCode({ email, code
|
|
295
|
+
verifyEmailVerificationCode({ email, code }: {
|
|
296
296
|
email: string;
|
|
297
297
|
code: string;
|
|
298
298
|
}): Promise<WalletInfo | null>;
|
|
299
|
-
verifyPhoneVerificationCode({ phone, code
|
|
299
|
+
verifyPhoneVerificationCode({ phone, code }: {
|
|
300
300
|
phone: string;
|
|
301
301
|
code: string;
|
|
302
302
|
}): Promise<WalletInfo | null>;
|
|
@@ -487,6 +487,7 @@ declare function useLoginModal({ client, isOpen, onClose, onLogin, isLoading, }:
|
|
|
487
487
|
declare const STORAGE_STATE_KEY = "embedded_wallet_state";
|
|
488
488
|
declare const WALLET_TYPE_KEY = "superstack_wallet_type";
|
|
489
489
|
declare const ACCESS_TOKEN_KEY = "embedded_wallet_access_token";
|
|
490
|
+
declare const SWITCHED_ACCOUNT_ADDRESS = "switched_account_address";
|
|
490
491
|
interface StorageState {
|
|
491
492
|
accessToken: string;
|
|
492
493
|
socials: Social[];
|
|
@@ -496,10 +497,12 @@ declare class Storage {
|
|
|
496
497
|
static saveState(token: string, socials: Social[]): void;
|
|
497
498
|
static saveAccessToken(token: string): void;
|
|
498
499
|
static saveWalletType(type: "phantom" | "embedded"): void;
|
|
500
|
+
static saveSwitchedAccountAddress(address: string): void;
|
|
499
501
|
static getWalletType(): "phantom" | "embedded" | null;
|
|
500
502
|
static getState(): StorageState | null;
|
|
501
503
|
static getSocials(): Social[] | null;
|
|
502
504
|
static getAccessToken(): string | null;
|
|
505
|
+
static getSwitchedAccountAddress(): string | null;
|
|
503
506
|
static clear(): void;
|
|
504
507
|
}
|
|
505
508
|
|
|
@@ -612,5 +615,5 @@ declare function useCoinbaseOnramp(): {
|
|
|
612
615
|
getCoinbaseOnrampUrl: (amount: number, blockchain?: "solana" | "ethereum", redirectUrl?: string) => Promise<string>;
|
|
613
616
|
};
|
|
614
617
|
|
|
615
|
-
export { ACCESS_TOKEN_KEY, Network, STORAGE_STATE_KEY, SocialType, Storage, VaultId, WALLET_TYPE_KEY, WalletClient, WalletProvider, WalletType, injectStyles, isVersionedTransaction, theme, useActiveWallet, useCoinbaseOnramp, useConnect, useLoginModal, useWallet, useWalletStatus };
|
|
618
|
+
export { ACCESS_TOKEN_KEY, Network, STORAGE_STATE_KEY, SWITCHED_ACCOUNT_ADDRESS, SocialType, Storage, VaultId, WALLET_TYPE_KEY, WalletClient, WalletProvider, WalletType, injectStyles, isVersionedTransaction, theme, useActiveWallet, useCoinbaseOnramp, useConnect, useLoginModal, useWallet, useWalletStatus };
|
|
616
619
|
export type { AccountInfo, ApiResponse, BuildTransactionRequest, BuildTransactionResponse, CoinbaseOnrampRequest, IModalManager, LoginModalProps, LoginType, MiddleAccount, MiddleAccountRequest, OrderState, SignMessageResponse, SignRequestV1, SignRequestV2, SignTransactionResponse, SignTransactionReturnType, Social, SocialInfo, SupportedTransactionVersions, TransactionOrVersionedTransaction, TransferRequest, UnsignedTx, UserSession, Wallet, WalletInfo, WalletProviderConfig };
|