@initia/interwovenkit-react 2.11.1 → 2.12.0
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/index.cjs +2 -2
- package/dist/index.d.ts +19 -2
- package/dist/index.js +3867 -3861
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -164,12 +164,14 @@ export declare interface CreateTestCosmosWalletConfig {
|
|
|
164
164
|
export declare type CreateTestWalletConfig = CreateTestWalletOptions & {
|
|
165
165
|
/**
|
|
166
166
|
* Wagmi connector id. Useful when running multiple test wallets.
|
|
167
|
-
*
|
|
167
|
+
* Defaults to `"testWallet"` when `addressIndex` is omitted, or
|
|
168
|
+
* `"testWallet-${addressIndex}"` when it is provided.
|
|
168
169
|
*/
|
|
169
170
|
id?: string;
|
|
170
171
|
/**
|
|
171
172
|
* Display name shown in wallet selection UI.
|
|
172
|
-
*
|
|
173
|
+
* Defaults to `"Test Wallet"` when `addressIndex` is omitted, or
|
|
174
|
+
* `"Test Wallet ${addressIndex}"` when it is provided.
|
|
173
175
|
*/
|
|
174
176
|
name?: string;
|
|
175
177
|
/**
|
|
@@ -214,6 +216,15 @@ export declare type CreateTestWalletConfig = CreateTestWalletOptions & {
|
|
|
214
216
|
* mnemonic: process.env.TEST_MNEMONIC!,
|
|
215
217
|
* })
|
|
216
218
|
*
|
|
219
|
+
* // Derive multiple connectors from one mnemonic. Explicit indexes also
|
|
220
|
+
* // produce unique default ids and names for wagmi and wallet selection UIs.
|
|
221
|
+
* const testConnectors = Array.from({ length: 40 }, (_, addressIndex) =>
|
|
222
|
+
* createTestWalletConnector({
|
|
223
|
+
* mnemonic: process.env.TEST_MNEMONIC!,
|
|
224
|
+
* addressIndex,
|
|
225
|
+
* }),
|
|
226
|
+
* )
|
|
227
|
+
*
|
|
217
228
|
* // Or from private key
|
|
218
229
|
* const connector = createTestWalletConnector({
|
|
219
230
|
* privateKey: process.env.TEST_PRIVATE_KEY as `0x${string}`,
|
|
@@ -356,9 +367,15 @@ export declare type CreateTestWalletOptions = {
|
|
|
356
367
|
* BIP-39 mnemonic phrase. Provide either `mnemonic` or `privateKey`.
|
|
357
368
|
*/
|
|
358
369
|
mnemonic: string;
|
|
370
|
+
/**
|
|
371
|
+
* Address index in the HD path (`m/44'/60'/0'/0/${addressIndex}`).
|
|
372
|
+
* @default 0
|
|
373
|
+
*/
|
|
374
|
+
addressIndex?: number;
|
|
359
375
|
privateKey?: never;
|
|
360
376
|
} | {
|
|
361
377
|
mnemonic?: never;
|
|
378
|
+
addressIndex?: never;
|
|
362
379
|
/**
|
|
363
380
|
* Hex-encoded private key (with `0x` prefix).
|
|
364
381
|
* Provide either `mnemonic` or `privateKey`.
|