@sidhujag/sysweb3-keyring 1.0.590 → 1.0.591

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sidhujag/sysweb3-keyring",
3
- "version": "1.0.590",
3
+ "version": "1.0.591",
4
4
  "description": "Keyring Manager for UTXO and Web3 Wallets",
5
5
  "main": "cjs/index.js",
6
6
  "types": "types/index.d.ts",
@@ -87,8 +87,8 @@ export declare class KeyringManager implements IKeyringManager {
87
87
  isSeedValid: (seedPhrase: string) => any;
88
88
  createNewSeed: (wordCount?: number) => any;
89
89
  getUTXOState: () => any;
90
- importTrezorAccount(label?: string): Promise<IKeyringAccountState>;
91
- importLedgerAccount(label?: string): Promise<IKeyringAccountState>;
90
+ importTrezorAccount(label?: string): Promise<IKeyringAccountState<any>>;
91
+ importLedgerAccount(label?: string): Promise<IKeyringAccountState<any>>;
92
92
  getActiveUTXOAccountState: () => any;
93
93
  getNetwork: () => any;
94
94
  createEthAccount: (privateKey: string) => Wallet;
@@ -101,8 +101,8 @@ export declare class KeyringManager implements IKeyringManager {
101
101
  logout: () => void;
102
102
  importAccount(privKey: string, label?: string, options?: {
103
103
  utxoAddressType?: 'p2wpkh' | 'p2pkh' | 'p2tr';
104
- }): Promise<IKeyringAccountState>;
105
- importWatchOnly(identifier: string, label?: string): Promise<IKeyringAccountState>;
104
+ }): Promise<IKeyringAccountState<any>>;
105
+ importWatchOnly(identifier: string, label?: string): Promise<IKeyringAccountState<any>>;
106
106
  validateZprv(zprv: string, targetNetwork?: INetwork): {
107
107
  isValid: boolean;
108
108
  node: any;
package/types/types.d.ts CHANGED
@@ -178,14 +178,14 @@ export interface IPasskeyCredentialProfile {
178
178
  y: string;
179
179
  };
180
180
  }
181
- export interface ICreateSmartAccountParams {
181
+ export interface ICreateSmartAccountParams<TSmartAccountMetadata = any> {
182
182
  address?: string;
183
183
  deriveAccount?: (accountIndex: number) => Promise<{
184
184
  address: string;
185
- metadata: unknown;
185
+ metadata: TSmartAccountMetadata;
186
186
  }>;
187
187
  label?: string;
188
- metadata?: unknown;
188
+ metadata?: TSmartAccountMetadata;
189
189
  }
190
190
  export type IKeyringDApp = {
191
191
  active: boolean;
@@ -217,7 +217,7 @@ interface IValidateZprvResponse {
217
217
  network?: INetworkParams | null;
218
218
  node?: any;
219
219
  }
220
- export interface IKeyringAccountState {
220
+ export interface IKeyringAccountState<TSmartAccountMetadata = any> {
221
221
  address: string;
222
222
  balances: IKeyringBalances;
223
223
  id: number;
@@ -226,7 +226,7 @@ export interface IKeyringAccountState {
226
226
  isSmartAccount?: boolean;
227
227
  isTrezorWallet: boolean;
228
228
  label: string;
229
- smartAccount?: unknown;
229
+ smartAccount?: TSmartAccountMetadata;
230
230
  xprv: string;
231
231
  xpub: string;
232
232
  }