Refactor wallet storage and subscription handling

- Updated WalletStore to manage localStorage and handle storage events more effectively.
- Introduced mockAccountsSubscribe in constants for better account subscription handling.
- Removed unnecessary storage subscription from InjectionConfig.
- Enhanced Wallet class to utilize new account and metadata management methods.
This commit is contained in:
odiinnn committed 2025-09-01 10:42:55 +03:00
1 parent 1966988769
commit 38574daace
6 files changed
+78 -44

No files matched your search

+1 -4
View File
@@ -5,15 +5,12 @@ declare global {
interface Window extends InjectedWindow {}
}
export type WalletStorage = Storage & {
subscribe: (cb: (ev: StorageEvent) => void) => void;
}
export type WalletStorage = Storage;
export type InjectionConfig = {
callbackUrl: string;
isDev?: boolean;
connectTimeout?: number;
storage?: WalletStorage;
}
export type WebApp = typeof WebAppConst;