viem 0.2.0-0-2-0.20230329T025357 → 0.2.0-0-2-0.20230330T023229
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/abi.d.ts +3 -3
- package/dist/abi.js +2 -2
- package/dist/abi.mjs +1 -1
- package/dist/accounts/index.d.ts +5 -14
- package/dist/accounts/index.js +20 -30
- package/dist/accounts/index.js.map +1 -1
- package/dist/accounts/index.mjs +14 -24
- package/dist/accounts/index.mjs.map +1 -1
- package/dist/{chain-5b28fc53.d.ts → chain-9da1e6b6.d.ts} +132 -120
- package/dist/{chain-e9b996ff.d.ts → chain-b53ed5d9.d.ts} +1 -1
- package/dist/chains.d.ts +867 -99
- package/dist/chains.js +115 -63
- package/dist/chains.js.map +1 -1
- package/dist/chains.mjs +58 -6
- package/dist/chains.mjs.map +1 -1
- package/dist/{chunk-564BCC7H.js → chunk-2ESQNALV.js} +18 -16
- package/dist/chunk-2ESQNALV.js.map +1 -0
- package/dist/{chunk-CXE4XSMF.js → chunk-ASAFFZMD.js} +19 -19
- package/dist/{chunk-UCZWRYV5.mjs → chunk-B7WOV4RY.mjs} +18 -16
- package/dist/chunk-B7WOV4RY.mjs.map +1 -0
- package/dist/{chunk-D3ALNUWN.js → chunk-GNHXOZCH.js} +6 -6
- package/dist/{chunk-BJ5KRDTG.mjs → chunk-RFOQRRYW.mjs} +2 -2
- package/dist/{chunk-7QEOFHC7.mjs → chunk-S4GWZ3LJ.mjs} +2 -2
- package/dist/contract.d.ts +8 -8
- package/dist/contract.js +2 -2
- package/dist/contract.mjs +1 -1
- package/dist/{createClient-e52de308.d.ts → createTransport-e031366b.d.ts} +36 -34
- package/dist/{eip1193-9080db42.d.ts → eip1193-e79469af.d.ts} +1 -1
- package/dist/{encodeFunctionResult-47ad60ed.d.ts → encodeFunctionResult-d206ceb9.d.ts} +15 -15
- package/dist/{encodePacked-35c796fb.d.ts → encodePacked-b36ce88a.d.ts} +1 -1
- package/dist/ens.d.ts +5 -5
- package/dist/ens.js +3 -3
- package/dist/ens.mjs +2 -2
- package/dist/ethers.d.ts +2 -2
- package/dist/ethers.js +4 -4
- package/dist/ethers.mjs +2 -2
- package/dist/{formatAbiItem-d9e801dd.d.ts → formatAbiItem-a7a3fb0f.d.ts} +1 -1
- package/dist/{getAbiItem-1d94ae0e.d.ts → getAbiItem-5e8b01de.d.ts} +3 -3
- package/dist/index.d.ts +49 -15
- package/dist/index.js +214 -138
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +123 -47
- package/dist/index.mjs.map +1 -1
- package/dist/{parseGwei-f14525ab.d.ts → parseGwei-7678c2fa.d.ts} +5 -5
- package/dist/public.d.ts +5 -5
- package/dist/public.js +2 -2
- package/dist/public.mjs +1 -1
- package/dist/publicKeyToAddress-87b9856c.d.ts +16 -0
- package/dist/{test-f3d06763.d.ts → test-68dbda5b.d.ts} +3 -3
- package/dist/test.d.ts +5 -5
- package/dist/test.js +2 -2
- package/dist/test.mjs +1 -1
- package/dist/{typedData-42b43450.d.ts → typedData-8b24374d.d.ts} +1 -1
- package/dist/utils/index.d.ts +15 -15
- package/dist/utils/index.js +4 -2
- package/dist/utils/index.mjs +3 -1
- package/dist/wallet.d.ts +5 -5
- package/dist/wallet.js +2 -2
- package/dist/wallet.mjs +1 -1
- package/dist/{watchPendingTransactions-468f53f2.d.ts → watchPendingTransactions-53449c4e.d.ts} +34 -31
- package/dist/window.d.ts +2 -2
- package/package.json +3 -3
- package/dist/chunk-564BCC7H.js.map +0 -1
- package/dist/chunk-UCZWRYV5.mjs.map +0 -1
- package/dist/parseAccount-4209fa24.d.ts +0 -6
- /package/dist/{chunk-CXE4XSMF.js.map → chunk-ASAFFZMD.js.map} +0 -0
- /package/dist/{chunk-D3ALNUWN.js.map → chunk-GNHXOZCH.js.map} +0 -0
- /package/dist/{chunk-BJ5KRDTG.mjs.map → chunk-RFOQRRYW.mjs.map} +0 -0
- /package/dist/{chunk-7QEOFHC7.mjs.map → chunk-S4GWZ3LJ.mjs.map} +0 -0
@@ -1,20 +1,20 @@
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true});
|
2
2
|
|
3
3
|
|
4
|
-
var
|
4
|
+
var _chunk2ESQNALVjs = require('./chunk-2ESQNALV.js');
|
5
5
|
|
6
6
|
// src/accounts/toAccount.ts
|
7
7
|
function toAccount(source) {
|
8
8
|
if (typeof source === "string") {
|
9
|
-
if (!
|
10
|
-
throw new (0,
|
9
|
+
if (!_chunk2ESQNALVjs.isAddress.call(void 0, source))
|
10
|
+
throw new (0, _chunk2ESQNALVjs.InvalidAddressError)({ address: source });
|
11
11
|
return {
|
12
12
|
address: source,
|
13
13
|
type: "json-rpc"
|
14
14
|
};
|
15
15
|
}
|
16
|
-
if (!
|
17
|
-
throw new (0,
|
16
|
+
if (!_chunk2ESQNALVjs.isAddress.call(void 0, source.address))
|
17
|
+
throw new (0, _chunk2ESQNALVjs.InvalidAddressError)({ address: source.address });
|
18
18
|
return {
|
19
19
|
address: source.address,
|
20
20
|
signMessage: source.signMessage,
|
@@ -28,4 +28,4 @@ function toAccount(source) {
|
|
28
28
|
|
29
29
|
|
30
30
|
exports.toAccount = toAccount;
|
31
|
-
//# sourceMappingURL=chunk-
|
31
|
+
//# sourceMappingURL=chunk-GNHXOZCH.js.map
|
@@ -11,7 +11,7 @@ import {
|
|
11
11
|
stringToBytes,
|
12
12
|
toBytes,
|
13
13
|
toHex
|
14
|
-
} from "./chunk-
|
14
|
+
} from "./chunk-B7WOV4RY.mjs";
|
15
15
|
|
16
16
|
// src/utils/ens/labelhash.ts
|
17
17
|
function labelhash(label) {
|
@@ -183,4 +183,4 @@ export {
|
|
183
183
|
getEnsAddress,
|
184
184
|
getEnsName
|
185
185
|
};
|
186
|
-
//# sourceMappingURL=chunk-
|
186
|
+
//# sourceMappingURL=chunk-RFOQRRYW.mjs.map
|
@@ -1,7 +1,7 @@
|
|
1
1
|
import {
|
2
2
|
InvalidAddressError,
|
3
3
|
isAddress
|
4
|
-
} from "./chunk-
|
4
|
+
} from "./chunk-B7WOV4RY.mjs";
|
5
5
|
|
6
6
|
// src/accounts/toAccount.ts
|
7
7
|
function toAccount(source) {
|
@@ -28,4 +28,4 @@ function toAccount(source) {
|
|
28
28
|
export {
|
29
29
|
toAccount
|
30
30
|
};
|
31
|
-
//# sourceMappingURL=chunk-
|
31
|
+
//# sourceMappingURL=chunk-S4GWZ3LJ.mjs.map
|
package/dist/contract.d.ts
CHANGED
@@ -1,11 +1,11 @@
|
|
1
|
-
export { D as DecodeAbiParametersReturnType, E as EncodeAbiParametersReturnType, G as GetAbiItemParameters, d as decodeAbiParameters, e as encodeAbiParameters, g as getAbiItem } from './getAbiItem-
|
2
|
-
export { D as DecodeErrorResultParameters, a as DecodeErrorResultReturnType, b as DecodeEventLogParameters, c as DecodeEventLogReturnType, d as DecodeFunctionDataParameters, e as DecodeFunctionResultParameters, f as DecodeFunctionResultReturnType, E as EncodeDeployDataParameters, g as EncodeErrorResultParameters, h as EncodeEventTopicsParameters, i as EncodeFunctionDataParameters, j as EncodeFunctionResultParameters, k as decodeErrorResult, l as decodeEventLog, m as decodeFunctionData, n as decodeFunctionResult, o as encodeDeployData, p as encodeErrorResult, q as encodeEventTopics, r as encodeFunctionData, s as encodeFunctionResult } from './encodeFunctionResult-
|
3
|
-
export { a as formatAbiItem, f as formatAbiItemWithArgs } from './formatAbiItem-
|
4
|
-
export { c as CreateContractEventFilterParameters, d as CreateContractEventFilterReturnType, D as DeployContractParameters, h as DeployContractReturnType, aW as EstimateContractGasParameters, aX as EstimateContractGasReturnType, r as GetBytecodeParameters, s as GetBytecodeReturnType, J as GetStorageAtParameters, K as GetStorageAtReturnType, T as MulticallParameters, U as MulticallReturnType, Z as OnLogsFn, _ as OnLogsParameter, a1 as ReadContractParameters, a2 as ReadContractReturnType, ae as SimulateContractParameters, af as SimulateContractReturnType, ar as WatchContractEventParameters, ax as WriteContractParameters, ay as WriteContractReturnType, aY as createContractEventFilter, b4 as deployContract, aZ as estimateContractGas, a_ as getBytecode, a$ as getStorageAt, b0 as multicall, b1 as readContract, b2 as simulateContract, b3 as watchContractEvent, b5 as writeContract } from './watchPendingTransactions-
|
1
|
+
export { D as DecodeAbiParametersReturnType, E as EncodeAbiParametersReturnType, G as GetAbiItemParameters, d as decodeAbiParameters, e as encodeAbiParameters, g as getAbiItem } from './getAbiItem-5e8b01de.js';
|
2
|
+
export { D as DecodeErrorResultParameters, a as DecodeErrorResultReturnType, b as DecodeEventLogParameters, c as DecodeEventLogReturnType, d as DecodeFunctionDataParameters, e as DecodeFunctionResultParameters, f as DecodeFunctionResultReturnType, E as EncodeDeployDataParameters, g as EncodeErrorResultParameters, h as EncodeEventTopicsParameters, i as EncodeFunctionDataParameters, j as EncodeFunctionResultParameters, k as decodeErrorResult, l as decodeEventLog, m as decodeFunctionData, n as decodeFunctionResult, o as encodeDeployData, p as encodeErrorResult, q as encodeEventTopics, r as encodeFunctionData, s as encodeFunctionResult } from './encodeFunctionResult-d206ceb9.js';
|
3
|
+
export { a as formatAbiItem, f as formatAbiItemWithArgs } from './formatAbiItem-a7a3fb0f.js';
|
4
|
+
export { c as CreateContractEventFilterParameters, d as CreateContractEventFilterReturnType, D as DeployContractParameters, h as DeployContractReturnType, aW as EstimateContractGasParameters, aX as EstimateContractGasReturnType, r as GetBytecodeParameters, s as GetBytecodeReturnType, J as GetStorageAtParameters, K as GetStorageAtReturnType, T as MulticallParameters, U as MulticallReturnType, Z as OnLogsFn, _ as OnLogsParameter, a1 as ReadContractParameters, a2 as ReadContractReturnType, ae as SimulateContractParameters, af as SimulateContractReturnType, ar as WatchContractEventParameters, ax as WriteContractParameters, ay as WriteContractReturnType, aY as createContractEventFilter, b4 as deployContract, aZ as estimateContractGas, a_ as getBytecode, a$ as getStorageAt, b0 as multicall, b1 as readContract, b2 as simulateContract, b3 as watchContractEvent, b5 as writeContract } from './watchPendingTransactions-53449c4e.js';
|
5
5
|
import 'abitype';
|
6
|
-
import './chain-
|
6
|
+
import './chain-9da1e6b6.js';
|
7
7
|
import '@wagmi/chains';
|
8
|
-
import './
|
9
|
-
import './eip1193-
|
10
|
-
import './typedData-
|
8
|
+
import './createTransport-e031366b.js';
|
9
|
+
import './eip1193-e79469af.js';
|
10
|
+
import './typedData-8b24374d.js';
|
11
11
|
import '@scure/bip32';
|
package/dist/contract.js
CHANGED
@@ -23,7 +23,7 @@
|
|
23
23
|
|
24
24
|
|
25
25
|
|
26
|
-
var
|
26
|
+
var _chunk2ESQNALVjs = require('./chunk-2ESQNALV.js');
|
27
27
|
|
28
28
|
|
29
29
|
|
@@ -49,5 +49,5 @@ var _chunk564BCC7Hjs = require('./chunk-564BCC7H.js');
|
|
49
49
|
|
50
50
|
|
51
51
|
|
52
|
-
exports.createContractEventFilter =
|
52
|
+
exports.createContractEventFilter = _chunk2ESQNALVjs.createContractEventFilter; exports.decodeAbiParameters = _chunk2ESQNALVjs.decodeAbiParameters; exports.decodeErrorResult = _chunk2ESQNALVjs.decodeErrorResult; exports.decodeEventLog = _chunk2ESQNALVjs.decodeEventLog; exports.decodeFunctionData = _chunk2ESQNALVjs.decodeFunctionData; exports.decodeFunctionResult = _chunk2ESQNALVjs.decodeFunctionResult; exports.deployContract = _chunk2ESQNALVjs.deployContract; exports.encodeAbiParameters = _chunk2ESQNALVjs.encodeAbiParameters; exports.encodeDeployData = _chunk2ESQNALVjs.encodeDeployData; exports.encodeErrorResult = _chunk2ESQNALVjs.encodeErrorResult; exports.encodeEventTopics = _chunk2ESQNALVjs.encodeEventTopics; exports.encodeFunctionData = _chunk2ESQNALVjs.encodeFunctionData; exports.encodeFunctionResult = _chunk2ESQNALVjs.encodeFunctionResult; exports.estimateContractGas = _chunk2ESQNALVjs.estimateContractGas; exports.formatAbiItem = _chunk2ESQNALVjs.formatAbiItem; exports.formatAbiItemWithArgs = _chunk2ESQNALVjs.formatAbiItemWithArgs; exports.getAbiItem = _chunk2ESQNALVjs.getAbiItem; exports.getBytecode = _chunk2ESQNALVjs.getBytecode; exports.getStorageAt = _chunk2ESQNALVjs.getStorageAt; exports.multicall = _chunk2ESQNALVjs.multicall; exports.readContract = _chunk2ESQNALVjs.readContract; exports.simulateContract = _chunk2ESQNALVjs.simulateContract; exports.watchContractEvent = _chunk2ESQNALVjs.watchContractEvent; exports.writeContract = _chunk2ESQNALVjs.writeContract;
|
53
53
|
//# sourceMappingURL=contract.js.map
|
package/dist/contract.mjs
CHANGED
@@ -1,37 +1,5 @@
|
|
1
|
-
import { R as Requests } from './eip1193-
|
2
|
-
import { C as Chain } from './chain-
|
3
|
-
|
4
|
-
type BaseRpcRequests = {
|
5
|
-
request(...args: any): Promise<any>;
|
6
|
-
};
|
7
|
-
type TransportConfig<TType extends string = string, TRequests extends BaseRpcRequests['request'] = Requests['request']> = {
|
8
|
-
/** The name of the transport. */
|
9
|
-
name: string;
|
10
|
-
/** The key of the transport. */
|
11
|
-
key: string;
|
12
|
-
/** The JSON-RPC request function that matches the EIP-1193 request spec. */
|
13
|
-
request: TRequests;
|
14
|
-
/** The base delay (in ms) between retries. */
|
15
|
-
retryDelay?: number;
|
16
|
-
/** The max number of times to retry. */
|
17
|
-
retryCount?: number;
|
18
|
-
/** The timeout (in ms) for requests. */
|
19
|
-
timeout?: number;
|
20
|
-
/** The type of the transport. */
|
21
|
-
type: TType;
|
22
|
-
};
|
23
|
-
type Transport<TType extends string = string, TRpcAttributes = Record<string, any>, TRequests extends BaseRpcRequests['request'] = Requests['request']> = <TChain extends Chain | undefined = Chain>({ chain, }: {
|
24
|
-
chain?: TChain;
|
25
|
-
retryCount?: TransportConfig['retryCount'];
|
26
|
-
}) => {
|
27
|
-
config: TransportConfig<TType>;
|
28
|
-
request: TRequests;
|
29
|
-
value?: TRpcAttributes;
|
30
|
-
};
|
31
|
-
/**
|
32
|
-
* @description Creates an transport intended to be used with a client.
|
33
|
-
*/
|
34
|
-
declare function createTransport<TType extends string, TRpcAttributes extends Record<string, any>>({ key, name, request, retryCount, retryDelay, timeout, type, }: TransportConfig<TType>, value?: TRpcAttributes): ReturnType<Transport<TType, TRpcAttributes>>;
|
1
|
+
import { R as Requests } from './eip1193-e79469af.js';
|
2
|
+
import { C as Chain } from './chain-9da1e6b6.js';
|
35
3
|
|
36
4
|
type ClientConfig<TTransport extends Transport = Transport, TChain extends Chain | undefined = Chain | undefined> = {
|
37
5
|
/** Chain for the client. */
|
@@ -73,4 +41,38 @@ type Client<TTransport extends Transport = Transport, TRequests extends BaseRpcR
|
|
73
41
|
*/
|
74
42
|
declare function createClient<TTransport extends Transport, TRequests extends BaseRpcRequests, TChain extends Chain | undefined = undefined>({ chain, key, name, pollingInterval, transport, type, }: ClientConfig<TTransport, TChain>): Client<TTransport, TRequests, TChain>;
|
75
43
|
|
44
|
+
type BaseRpcRequests = {
|
45
|
+
request(...args: any): Promise<any>;
|
46
|
+
};
|
47
|
+
type TransportConfig<TType extends string = string, TRequests extends BaseRpcRequests['request'] = Requests['request']> = {
|
48
|
+
/** The name of the transport. */
|
49
|
+
name: string;
|
50
|
+
/** The key of the transport. */
|
51
|
+
key: string;
|
52
|
+
/** The JSON-RPC request function that matches the EIP-1193 request spec. */
|
53
|
+
request: TRequests;
|
54
|
+
/** The base delay (in ms) between retries. */
|
55
|
+
retryDelay?: number;
|
56
|
+
/** The max number of times to retry. */
|
57
|
+
retryCount?: number;
|
58
|
+
/** The timeout (in ms) for requests. */
|
59
|
+
timeout?: number;
|
60
|
+
/** The type of the transport. */
|
61
|
+
type: TType;
|
62
|
+
};
|
63
|
+
type Transport<TType extends string = string, TRpcAttributes = Record<string, any>, TRequests extends BaseRpcRequests['request'] = Requests['request']> = <TChain extends Chain | undefined = Chain>({ chain, }: {
|
64
|
+
chain?: TChain;
|
65
|
+
pollingInterval?: ClientConfig['pollingInterval'];
|
66
|
+
retryCount?: TransportConfig['retryCount'];
|
67
|
+
timeout?: TransportConfig['timeout'];
|
68
|
+
}) => {
|
69
|
+
config: TransportConfig<TType>;
|
70
|
+
request: TRequests;
|
71
|
+
value?: TRpcAttributes;
|
72
|
+
};
|
73
|
+
/**
|
74
|
+
* @description Creates an transport intended to be used with a client.
|
75
|
+
*/
|
76
|
+
declare function createTransport<TType extends string, TRpcAttributes extends Record<string, any>>({ key, name, request, retryCount, retryDelay, timeout, type, }: TransportConfig<TType>, value?: TRpcAttributes): ReturnType<Transport<TType, TRpcAttributes>>;
|
77
|
+
|
76
78
|
export { BaseRpcRequests as B, Client as C, TransportConfig as T, Transport as a, ClientConfig as b, createClient as c, createTransport as d };
|
@@ -1,5 +1,5 @@
|
|
1
1
|
import { Address } from 'abitype';
|
2
|
-
import { a as Hash, ak as Quantity,
|
2
|
+
import { a as Hash, ak as Quantity, z as RpcTransactionRequest, t as RpcBlockNumber, f as BlockTag, s as RpcBlockIdentifier, H as Hex, u as RpcFeeHistory, R as RpcBlock, w as RpcLog, an as LogTopic, x as RpcTransaction, y as RpcTransactionReceipt, D as RpcUncle } from './chain-9da1e6b6.js';
|
3
3
|
|
4
4
|
declare class RpcError extends Error {
|
5
5
|
code: number;
|
@@ -1,5 +1,5 @@
|
|
1
1
|
import { Abi, Narrow } from 'abitype';
|
2
|
-
import { H as Hex, A as AbiItem,
|
2
|
+
import { H as Hex, A as AbiItem, p as InferEventName, n as GetEventArgsFromTopics, q as InferFunctionName, o as GetFunctionArgs, h as ContractFunctionResult, G as GetConstructorArgs, I as InferErrorName, l as GetErrorArgs, m as GetEventArgs } from './chain-9da1e6b6.js';
|
3
3
|
|
4
4
|
type DecodeErrorResultParameters = {
|
5
5
|
abi?: Abi;
|
@@ -15,12 +15,12 @@ declare function decodeErrorResult({ abi, data, }: DecodeErrorResultParameters):
|
|
15
15
|
type DecodeEventLogParameters<TAbi extends Abi | readonly unknown[] = Abi, TEventName extends string = string, TTopics extends Hex[] = Hex[], TData extends Hex | undefined = undefined> = {
|
16
16
|
abi: Narrow<TAbi>;
|
17
17
|
data?: TData;
|
18
|
-
eventName?:
|
18
|
+
eventName?: InferEventName<TAbi, TEventName>;
|
19
19
|
topics: [signature: Hex, ...args: TTopics] | [];
|
20
20
|
};
|
21
21
|
type DecodeEventLogReturnType<TAbi extends Abi | readonly unknown[] = Abi, TEventName extends string = string, TTopics extends Hex[] = Hex[], TData extends Hex | undefined = undefined> = {
|
22
22
|
eventName: TEventName;
|
23
|
-
} &
|
23
|
+
} & GetEventArgsFromTopics<TAbi, TEventName, TTopics, TData>;
|
24
24
|
declare function decodeEventLog<TAbi extends Abi | readonly unknown[], TEventName extends string, TTopics extends Hex[], TData extends Hex | undefined = undefined>({ abi, data, topics, }: DecodeEventLogParameters<TAbi, TEventName, TTopics, TData>): DecodeEventLogReturnType<TAbi, TEventName, TTopics, TData>;
|
25
25
|
|
26
26
|
type DecodeFunctionDataParameters = {
|
@@ -34,41 +34,41 @@ declare function decodeFunctionData({ abi, data, }: DecodeFunctionDataParameters
|
|
34
34
|
|
35
35
|
type DecodeFunctionResultParameters<TAbi extends Abi | readonly unknown[] = Abi, TFunctionName extends string = string> = {
|
36
36
|
abi: Narrow<TAbi>;
|
37
|
-
functionName:
|
37
|
+
functionName: InferFunctionName<TAbi, TFunctionName>;
|
38
38
|
data: Hex;
|
39
|
-
} & Partial<
|
40
|
-
type DecodeFunctionResultReturnType<TAbi extends Abi | readonly unknown[] = Abi, TFunctionName extends string = string> =
|
39
|
+
} & Partial<GetFunctionArgs<TAbi, TFunctionName>>;
|
40
|
+
type DecodeFunctionResultReturnType<TAbi extends Abi | readonly unknown[] = Abi, TFunctionName extends string = string> = ContractFunctionResult<TAbi, TFunctionName>;
|
41
41
|
declare function decodeFunctionResult<TAbi extends Abi | readonly unknown[], TFunctionName extends string>({ abi, args, functionName, data, }: DecodeFunctionResultParameters<TAbi, TFunctionName>): DecodeFunctionResultReturnType<TAbi, TFunctionName>;
|
42
42
|
|
43
43
|
type EncodeDeployDataParameters<TAbi extends Abi | readonly unknown[] = Abi> = {
|
44
44
|
abi: Narrow<TAbi>;
|
45
45
|
bytecode: Hex;
|
46
|
-
} &
|
46
|
+
} & GetConstructorArgs<TAbi>;
|
47
47
|
declare function encodeDeployData<TAbi extends Abi | readonly unknown[]>({ abi, args, bytecode, }: EncodeDeployDataParameters<TAbi>): `0x${string}`;
|
48
48
|
|
49
49
|
type EncodeErrorResultParameters<TAbi extends Abi | readonly unknown[] = Abi, TErrorName extends string = string> = {
|
50
50
|
abi: Narrow<TAbi>;
|
51
|
-
errorName:
|
52
|
-
} &
|
51
|
+
errorName: InferErrorName<TAbi, TErrorName>;
|
52
|
+
} & GetErrorArgs<TAbi, TErrorName>;
|
53
53
|
declare function encodeErrorResult<TAbi extends Abi | readonly unknown[], TErrorName extends string>({ abi, errorName, args }: EncodeErrorResultParameters<TAbi, TErrorName>): `0x${string}`;
|
54
54
|
|
55
55
|
type EncodeEventTopicsParameters<TAbi extends Abi | readonly unknown[] = Abi, TEventName extends string = string> = {
|
56
56
|
abi: Narrow<TAbi>;
|
57
|
-
args?:
|
58
|
-
eventName:
|
57
|
+
args?: GetEventArgs<TAbi, TEventName>;
|
58
|
+
eventName: InferEventName<TAbi, TEventName>;
|
59
59
|
};
|
60
60
|
declare function encodeEventTopics<TAbi extends Abi | readonly unknown[], TEventName extends string>({ abi, eventName, args }: EncodeEventTopicsParameters<TAbi, TEventName>): `0x${string}`[];
|
61
61
|
|
62
62
|
type EncodeFunctionDataParameters<TAbi extends Abi | readonly unknown[] = Abi, TFunctionName extends string = string> = {
|
63
63
|
abi: Narrow<TAbi>;
|
64
|
-
functionName:
|
65
|
-
} &
|
64
|
+
functionName: InferFunctionName<TAbi, TFunctionName>;
|
65
|
+
} & GetFunctionArgs<TAbi, TFunctionName>;
|
66
66
|
declare function encodeFunctionData<TAbi extends Abi | readonly unknown[], TFunctionName extends string>({ abi, args, functionName, }: EncodeFunctionDataParameters<TAbi, TFunctionName>): `0x${string}`;
|
67
67
|
|
68
68
|
type EncodeFunctionResultParameters<TAbi extends Abi | readonly unknown[] = Abi, TFunctionName extends string = string> = {
|
69
69
|
abi: Narrow<TAbi>;
|
70
|
-
functionName:
|
71
|
-
result?:
|
70
|
+
functionName: InferFunctionName<TAbi, TFunctionName>;
|
71
|
+
result?: ContractFunctionResult<TAbi, TFunctionName>;
|
72
72
|
};
|
73
73
|
declare function encodeFunctionResult<TAbi extends Abi | readonly unknown[], TFunctionName extends string>({ abi, functionName, result, }: EncodeFunctionResultParameters<TAbi, TFunctionName>): `0x${string}`;
|
74
74
|
|
@@ -1,5 +1,5 @@
|
|
1
1
|
import { Narrow, SolidityAddress, SolidityBool, SolidityBytes, SolidityInt, SolidityString, SolidityArrayWithoutTuple, AbiType, AbiParameterToPrimitiveType } from 'abitype';
|
2
|
-
import { H as Hex } from './chain-
|
2
|
+
import { H as Hex } from './chain-9da1e6b6.js';
|
3
3
|
|
4
4
|
type PackedAbiType = SolidityAddress | SolidityBool | SolidityBytes | SolidityInt | SolidityString | SolidityArrayWithoutTuple;
|
5
5
|
type EncodePackedValues<TPackedAbiTypes extends PackedAbiType[] | unknown[]> = {
|
package/dist/ens.d.ts
CHANGED
@@ -1,11 +1,11 @@
|
|
1
|
-
export { b6 as GetEnsAddressParameters, b7 as GetEnsNameParameters, b8 as getEnsAddress, b9 as getEnsName } from './watchPendingTransactions-
|
1
|
+
export { b6 as GetEnsAddressParameters, b7 as GetEnsNameParameters, b8 as getEnsAddress, b9 as getEnsName } from './watchPendingTransactions-53449c4e.js';
|
2
2
|
export { l as labelhash, n as namehash } from './namehash-afff0feb.js';
|
3
|
-
import './
|
4
|
-
import './eip1193-
|
3
|
+
import './createTransport-e031366b.js';
|
4
|
+
import './eip1193-e79469af.js';
|
5
5
|
import 'abitype';
|
6
|
-
import './chain-
|
6
|
+
import './chain-9da1e6b6.js';
|
7
7
|
import '@wagmi/chains';
|
8
|
-
import './typedData-
|
8
|
+
import './typedData-8b24374d.js';
|
9
9
|
import '@scure/bip32';
|
10
10
|
|
11
11
|
/**
|
package/dist/ens.js
CHANGED
@@ -3,8 +3,8 @@
|
|
3
3
|
|
4
4
|
|
5
5
|
|
6
|
-
var
|
7
|
-
require('./chunk-
|
6
|
+
var _chunkASAFFZMDjs = require('./chunk-ASAFFZMD.js');
|
7
|
+
require('./chunk-2ESQNALV.js');
|
8
8
|
|
9
9
|
// src/utils/ens/normalize.ts
|
10
10
|
var _idnauts46hx = require('idna-uts46-hx');
|
@@ -17,5 +17,5 @@ function normalize(name) {
|
|
17
17
|
|
18
18
|
|
19
19
|
|
20
|
-
exports.getEnsAddress =
|
20
|
+
exports.getEnsAddress = _chunkASAFFZMDjs.getEnsAddress; exports.getEnsName = _chunkASAFFZMDjs.getEnsName; exports.labelhash = _chunkASAFFZMDjs.labelhash; exports.namehash = _chunkASAFFZMDjs.namehash; exports.normalize = normalize;
|
21
21
|
//# sourceMappingURL=ens.js.map
|
package/dist/ens.mjs
CHANGED
package/dist/ethers.d.ts
CHANGED
@@ -1,7 +1,7 @@
|
|
1
|
-
import { L as LocalAccount } from './typedData-
|
1
|
+
import { L as LocalAccount } from './typedData-8b24374d.js';
|
2
2
|
import '@scure/bip32';
|
3
3
|
import 'abitype';
|
4
|
-
import './chain-
|
4
|
+
import './chain-9da1e6b6.js';
|
5
5
|
import '@wagmi/chains';
|
6
6
|
|
7
7
|
type BigNumberish = string | number | bigint;
|
package/dist/ethers.js
CHANGED
@@ -1,15 +1,15 @@
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _nullishCoalesce(lhs, rhsFn) { if (lhs != null) { return lhs; } else { return rhsFn(); } }
|
2
2
|
|
3
|
-
var
|
3
|
+
var _chunkGNHXOZCHjs = require('./chunk-GNHXOZCH.js');
|
4
4
|
|
5
5
|
|
6
|
-
var
|
6
|
+
var _chunk2ESQNALVjs = require('./chunk-2ESQNALV.js');
|
7
7
|
|
8
8
|
// src/adapters/ethers.ts
|
9
|
-
var ethersWalletToAccount = (wallet) =>
|
9
|
+
var ethersWalletToAccount = (wallet) => _chunkGNHXOZCHjs.toAccount.call(void 0, {
|
10
10
|
address: wallet.address,
|
11
11
|
async signMessage({ message }) {
|
12
|
-
return await wallet.signMessage(
|
12
|
+
return await wallet.signMessage(_chunk2ESQNALVjs.toBytes.call(void 0, message));
|
13
13
|
},
|
14
14
|
async signTransaction(txn) {
|
15
15
|
return await wallet.signTransaction({
|
package/dist/ethers.mjs
CHANGED
@@ -1,5 +1,5 @@
|
|
1
1
|
import { AbiParameter, AbiParametersToPrimitiveTypes, Narrow, Abi } from 'abitype';
|
2
|
-
import { H as Hex,
|
2
|
+
import { H as Hex, r as InferItemName, o as GetFunctionArgs } from './chain-9da1e6b6.js';
|
3
3
|
|
4
4
|
type DecodeAbiParametersReturnType<TParams extends readonly AbiParameter[] | readonly unknown[] = readonly AbiParameter[]> = AbiParametersToPrimitiveTypes<TParams extends readonly AbiParameter[] ? TParams : AbiParameter[]>;
|
5
5
|
declare function decodeAbiParameters<TParams extends readonly AbiParameter[] | readonly unknown[]>(params: Narrow<TParams>, data: Hex): DecodeAbiParametersReturnType<TParams>;
|
@@ -12,8 +12,8 @@ declare function encodeAbiParameters<TParams extends readonly AbiParameter[] | r
|
|
12
12
|
|
13
13
|
type GetAbiItemParameters<TAbi extends Abi | readonly unknown[] = Abi, TItemName extends string = string> = {
|
14
14
|
abi: Narrow<TAbi>;
|
15
|
-
name:
|
16
|
-
} & Partial<
|
15
|
+
name: InferItemName<TAbi, TItemName>;
|
16
|
+
} & Partial<GetFunctionArgs<TAbi, TItemName>>;
|
17
17
|
type GetAbiItemReturnType<TAbi extends Abi | readonly unknown[] = Abi, TItemName extends string = string> = Extract<TAbi[number], {
|
18
18
|
name: TItemName;
|
19
19
|
}>;
|
package/dist/index.d.ts
CHANGED
@@ -1,22 +1,22 @@
|
|
1
|
-
export { A as AddChainParameters, aK as BlockFormatter, C as CallParameters, a as CallReturnType, b as CreateBlockFilterReturnType, c as CreateContractEventFilterParameters, d as CreateContractEventFilterReturnType, e as CreateEventFilterParameters, f as CreateEventFilterReturnType, g as CreatePendingTransactionFilterReturnType, D as DeployContractParameters, h as DeployContractReturnType, E as EstimateGasParameters, i as EstimateGasReturnType, aL as FormattedBlock, aM as FormattedTransactionReceipt, aN as FormattedTransactionRequest, G as GetAddressesReturnType, j as GetBalanceParameters, k as GetBalanceReturnType, l as GetBlockNumberParameters, m as GetBlockNumberReturnType, n as GetBlockParameters, o as GetBlockReturnType, p as GetBlockTransactionCountParameters, q as GetBlockTransactionCountReturnType, r as GetBytecodeParameters, s as GetBytecodeReturnType, t as GetChainIdReturnType, u as GetFeeHistoryParameters, v as GetFeeHistoryReturnType, w as GetFilterChangesParameters, x as GetFilterChangesReturnType, y as GetFilterLogsParameters, z as GetFilterLogsReturnType, B as GetGasPriceReturnType, F as GetLogsParameters, H as GetLogsReturnType, I as GetPermissionsReturnType, J as GetStorageAtParameters, K as GetStorageAtReturnType, L as GetTransactionConfirmationsParameters, N as GetTransactionConfirmationsReturnType, M as GetTransactionCountParameters, O as GetTransactionCountReturnType, P as GetTransactionParameters, Q as GetTransactionReceiptParameters, R as GetTransactionReceiptReturnType, S as GetTransactionReturnType, aF as GetTransportConfig, aG as MulticallContracts, T as MulticallParameters, aH as MulticallResult, aI as MulticallResults, U as MulticallReturnType, V as OnBlock, W as OnBlockNumberFn, X as OnBlockNumberParameter, Y as OnBlockParameter, Z as OnLogsFn, _ as OnLogsParameter, $ as OnTransactionsFn, a0 as OnTransactionsParameter, aJ as ParseAccount, az as PublicClient, aA as PublicClientConfig, a1 as ReadContractParameters, a2 as ReadContractReturnType, a3 as ReplacementReason, a4 as ReplacementReturnType, a5 as RequestAddressesReturnType, a7 as RequestPermissionsParameters, a6 as RequestPermissionsReturnType, a8 as SendTransactionParameters, a9 as SendTransactionReturnType, aa as SignMessageParameters, ab as SignMessageReturnType, ac as SignTypedDataParameters, ad as SignTypedDataReturnType, ae as SimulateContractParameters, af as SimulateContractReturnType, ag as SwitchChainParameters, aO as TransactionReceiptFormatter, aP as TransactionRequestFormatter, ah as UninstallFilterParameters, ai as UninstallFilterReturnType, aj as WaitForTransactionReceiptParameters, ak as WaitForTransactionReceiptReturnType, aB as WalletClient, aC as WalletClientConfig, al as WatchAssetParameters, am as WatchAssetReturnType, an as WatchBlockNumberParameters, ao as WatchBlockNumberReturnType, ap as WatchBlocksParameters, aq as WatchBlocksReturnType, ar as WatchContractEventParameters, as as WatchContractEventReturnType, at as WatchEventParameters, au as WatchEventReturnType, av as WatchPendingTransactionsParameters, aw as WatchPendingTransactionsReturnType, ax as WriteContractParameters, ay as WriteContractReturnType, aD as createPublicClient, aE as createWalletClient, aQ as defineBlock, aR as defineTransactionReceipt, aS as defineTransactionRequest, aT as formatBlock, aU as formatTransactionRequest } from './watchPendingTransactions-
|
1
|
+
export { A as AddChainParameters, aK as BlockFormatter, C as CallParameters, a as CallReturnType, b as CreateBlockFilterReturnType, c as CreateContractEventFilterParameters, d as CreateContractEventFilterReturnType, e as CreateEventFilterParameters, f as CreateEventFilterReturnType, g as CreatePendingTransactionFilterReturnType, D as DeployContractParameters, h as DeployContractReturnType, E as EstimateGasParameters, i as EstimateGasReturnType, aL as FormattedBlock, aM as FormattedTransactionReceipt, aN as FormattedTransactionRequest, G as GetAddressesReturnType, j as GetBalanceParameters, k as GetBalanceReturnType, l as GetBlockNumberParameters, m as GetBlockNumberReturnType, n as GetBlockParameters, o as GetBlockReturnType, p as GetBlockTransactionCountParameters, q as GetBlockTransactionCountReturnType, r as GetBytecodeParameters, s as GetBytecodeReturnType, t as GetChainIdReturnType, u as GetFeeHistoryParameters, v as GetFeeHistoryReturnType, w as GetFilterChangesParameters, x as GetFilterChangesReturnType, y as GetFilterLogsParameters, z as GetFilterLogsReturnType, B as GetGasPriceReturnType, F as GetLogsParameters, H as GetLogsReturnType, I as GetPermissionsReturnType, J as GetStorageAtParameters, K as GetStorageAtReturnType, L as GetTransactionConfirmationsParameters, N as GetTransactionConfirmationsReturnType, M as GetTransactionCountParameters, O as GetTransactionCountReturnType, P as GetTransactionParameters, Q as GetTransactionReceiptParameters, R as GetTransactionReceiptReturnType, S as GetTransactionReturnType, aF as GetTransportConfig, aG as MulticallContracts, T as MulticallParameters, aH as MulticallResult, aI as MulticallResults, U as MulticallReturnType, V as OnBlock, W as OnBlockNumberFn, X as OnBlockNumberParameter, Y as OnBlockParameter, Z as OnLogsFn, _ as OnLogsParameter, $ as OnTransactionsFn, a0 as OnTransactionsParameter, aJ as ParseAccount, az as PublicClient, aA as PublicClientConfig, a1 as ReadContractParameters, a2 as ReadContractReturnType, a3 as ReplacementReason, a4 as ReplacementReturnType, a5 as RequestAddressesReturnType, a7 as RequestPermissionsParameters, a6 as RequestPermissionsReturnType, a8 as SendTransactionParameters, a9 as SendTransactionReturnType, aa as SignMessageParameters, ab as SignMessageReturnType, ac as SignTypedDataParameters, ad as SignTypedDataReturnType, ae as SimulateContractParameters, af as SimulateContractReturnType, ag as SwitchChainParameters, aO as TransactionReceiptFormatter, aP as TransactionRequestFormatter, ah as UninstallFilterParameters, ai as UninstallFilterReturnType, aj as WaitForTransactionReceiptParameters, ak as WaitForTransactionReceiptReturnType, aB as WalletClient, aC as WalletClientConfig, al as WatchAssetParameters, am as WatchAssetReturnType, an as WatchBlockNumberParameters, ao as WatchBlockNumberReturnType, ap as WatchBlocksParameters, aq as WatchBlocksReturnType, ar as WatchContractEventParameters, as as WatchContractEventReturnType, at as WatchEventParameters, au as WatchEventReturnType, av as WatchPendingTransactionsParameters, aw as WatchPendingTransactionsReturnType, ax as WriteContractParameters, ay as WriteContractReturnType, aD as createPublicClient, aE as createWalletClient, aQ as defineBlock, aR as defineTransactionReceipt, aS as defineTransactionRequest, aT as formatBlock, aU as formatTransactionRequest } from './watchPendingTransactions-53449c4e.js';
|
2
2
|
import { AbiParameter } from 'abitype';
|
3
3
|
export { Address, ParseAbi, ParseAbiItem, ParseAbiParameter, ParseAbiParameters, parseAbi, parseAbiItem, parseAbiParameter, parseAbiParameters } from 'abitype';
|
4
|
-
import { T as TransportConfig, a as Transport, B as BaseRpcRequests } from './
|
5
|
-
export { C as Client, b as ClientConfig, a as Transport, T as TransportConfig, c as createClient, d as createTransport } from './
|
6
|
-
import { B as BaseError, H as HttpOptions, R as RpcResponse } from './parseGwei-
|
7
|
-
export { B as BaseError, C as CallExecutionError, a as ContractFunctionExecutionError, b as ContractFunctionRevertedError, c as ContractFunctionZeroDataError, E as EstimateGasExecutionError, d as ExecutionRevertedError, F as FeeCapTooHighError, e as FeeCapTooLowError, G as GetContractAddressOptions, p as GetCreate2AddressOptions, q as GetCreateAddressOptions, r as GetSerializedTransactionType, s as GetTransactionType, t as HashTypedDataParameters, u as HashTypedDataReturnType, I as InsufficientFundsError, f as IntrinsicGasTooHighError, g as IntrinsicGasTooLowError, h as InvalidLegacyVError, N as NonceMaxValueError, i as NonceTooHighError, j as NonceTooLowError, k as RawContractError, v as RecoverAddressParameters, w as RecoverAddressReturnType, x as RecoverMessageAddressParameters, y as RecoverMessageAddressReturnType, z as RecoverTypedDataAddressParameters, A as RecoverTypedDataAddressReturnType, T as TipAboveFeeCapError, D as ToRlpReturnType, l as TransactionExecutionError, n as TransactionNotFoundError, o as TransactionReceiptNotFoundError, m as TransactionTypeNotSupportedError, U as UnknownNodeError, V as VerifyMessageParameters, J as VerifyMessageReturnType, K as VerifyTypedDataParameters, L as VerifyTypedDataReturnType, W as WaitForTransactionReceiptTimeoutError, M as assertRequest, O as assertTransactionEIP1559, P as assertTransactionEIP2930, Q as assertTransactionLegacy, S as boolToBytes, X as boolToHex, Y as bytesToBigint, Z as bytesToBool, _ as bytesToHex, $ as bytesToNumber, a0 as bytesToString, a1 as concat, a2 as concatBytes, a3 as concatHex, a4 as formatEther, a5 as formatGwei, a6 as formatUnits, a7 as fromBytes, a8 as fromHex, a9 as fromRlp, aa as getAddress, ab as getContractAddress, ac as getContractError, ad as getCreate2Address, ae as getCreateAddress, af as getEventSelector, ag as getFunctionSelector, ah as getSerializedTransactionType, ai as getTransactionType, aj as hashMessage, ak as hashTypedData, al as hexToBigInt, am as hexToBool, an as hexToBytes, ao as hexToNumber, ap as hexToString, aq as isAddress, ar as isAddressEqual, as as isBytes, at as isHash, au as isHex, av as keccak256, aw as numberToBytes, ax as numberToHex, ay as pad, az as padBytes, aA as padHex, aB as parseEther, aC as parseGwei, aD as parseTransaction, aE as parseUnits, aF as prepareRequest, aG as recoverAddress, aH as recoverMessageAddress, aI as recoverTypedDataAddress, aJ as serializeTransaction, aK as size, aL as slice, aM as sliceBytes, aN as sliceHex, aO as stringToBytes, aP as stringToHex, aQ as stringify, aR as toBytes, aS as toHex, aT as toRlp, aU as trim, aV as validateTypedData, aW as verifyMessage, aX as verifyTypedData } from './parseGwei-
|
4
|
+
import { T as TransportConfig, a as Transport, B as BaseRpcRequests } from './createTransport-e031366b.js';
|
5
|
+
export { C as Client, b as ClientConfig, a as Transport, T as TransportConfig, c as createClient, d as createTransport } from './createTransport-e031366b.js';
|
6
|
+
import { B as BaseError, H as HttpOptions, R as RpcResponse } from './parseGwei-7678c2fa.js';
|
7
|
+
export { B as BaseError, C as CallExecutionError, a as ContractFunctionExecutionError, b as ContractFunctionRevertedError, c as ContractFunctionZeroDataError, E as EstimateGasExecutionError, d as ExecutionRevertedError, F as FeeCapTooHighError, e as FeeCapTooLowError, G as GetContractAddressOptions, p as GetCreate2AddressOptions, q as GetCreateAddressOptions, r as GetSerializedTransactionType, s as GetTransactionType, t as HashTypedDataParameters, u as HashTypedDataReturnType, I as InsufficientFundsError, f as IntrinsicGasTooHighError, g as IntrinsicGasTooLowError, h as InvalidLegacyVError, N as NonceMaxValueError, i as NonceTooHighError, j as NonceTooLowError, k as RawContractError, v as RecoverAddressParameters, w as RecoverAddressReturnType, x as RecoverMessageAddressParameters, y as RecoverMessageAddressReturnType, z as RecoverTypedDataAddressParameters, A as RecoverTypedDataAddressReturnType, T as TipAboveFeeCapError, D as ToRlpReturnType, l as TransactionExecutionError, n as TransactionNotFoundError, o as TransactionReceiptNotFoundError, m as TransactionTypeNotSupportedError, U as UnknownNodeError, V as VerifyMessageParameters, J as VerifyMessageReturnType, K as VerifyTypedDataParameters, L as VerifyTypedDataReturnType, W as WaitForTransactionReceiptTimeoutError, M as assertRequest, O as assertTransactionEIP1559, P as assertTransactionEIP2930, Q as assertTransactionLegacy, S as boolToBytes, X as boolToHex, Y as bytesToBigint, Z as bytesToBool, _ as bytesToHex, $ as bytesToNumber, a0 as bytesToString, a1 as concat, a2 as concatBytes, a3 as concatHex, a4 as formatEther, a5 as formatGwei, a6 as formatUnits, a7 as fromBytes, a8 as fromHex, a9 as fromRlp, aa as getAddress, ab as getContractAddress, ac as getContractError, ad as getCreate2Address, ae as getCreateAddress, af as getEventSelector, ag as getFunctionSelector, ah as getSerializedTransactionType, ai as getTransactionType, aj as hashMessage, ak as hashTypedData, al as hexToBigInt, am as hexToBool, an as hexToBytes, ao as hexToNumber, ap as hexToString, aq as isAddress, ar as isAddressEqual, as as isBytes, at as isHash, au as isHex, av as keccak256, aw as numberToBytes, ax as numberToHex, ay as pad, az as padBytes, aA as padHex, aB as parseEther, aC as parseGwei, aD as parseTransaction, aE as parseUnits, aF as prepareRequest, aG as recoverAddress, aH as recoverMessageAddress, aI as recoverTypedDataAddress, aJ as serializeTransaction, aK as size, aL as slice, aM as sliceBytes, aN as sliceHex, aO as stringToBytes, aP as stringToHex, aQ as stringify, aR as toBytes, aS as toHex, aT as toRlp, aU as trim, aV as validateTypedData, aW as verifyMessage, aX as verifyTypedData } from './parseGwei-7678c2fa.js';
|
8
8
|
import WebSocket from 'isomorphic-ws';
|
9
|
-
import { H as Hex, A as AbiItem, a as Hash, C as Chain, B as ByteArray } from './chain-
|
10
|
-
export { A as AbiItem, b as AccessList, c as Block, d as BlockIdentifier, e as BlockNumber, f as BlockTag, B as ByteArray, C as Chain, g as
|
11
|
-
export { D as DropTransactionParameters, I as ImpersonateAccountParameters, a as IncreaseTimeParameters, M as MineParameters, R as ResetParameters, b as RevertParameters, S as SendUnsignedTransactionParameters, c as SendUnsignedTransactionReturnType, d as SetBalanceParameters, e as SetBlockGasLimitParameters, f as SetBlockTimestampIntervalParameters, g as SetCodeParameters, h as SetCoinbaseParameters, i as SetIntervalMiningParameters, j as SetMinGasPriceParameters, k as SetNextBlockBaseFeePerGasParameters, l as SetNextBlockTimestampParameters, m as SetNonceParameters, n as SetStorageAtParameters, o as StopImpersonatingAccountParameters, T as TestClient, p as TestClientConfig, q as createTestClient } from './test-
|
9
|
+
import { H as Hex, A as AbiItem, a as Hash, C as Chain, B as ByteArray } from './chain-9da1e6b6.js';
|
10
|
+
export { A as AbiItem, b as AccessList, c as Block, d as BlockIdentifier, e as BlockNumber, f as BlockTag, B as ByteArray, C as Chain, g as ContractFunctionConfig, h as ContractFunctionResult, a4 as ExtractFormatter, F as FeeHistory, i as FeeValues, j as FeeValuesEIP1559, k as FeeValuesLegacy, a5 as Formatted, a6 as FormattedTransaction, G as GetConstructorArgs, l as GetErrorArgs, m as GetEventArgs, n as GetEventArgsFromTopics, o as GetFunctionArgs, a as Hash, H as Hex, I as InferErrorName, p as InferEventName, q as InferFunctionName, r as InferItemName, L as Log, R as RpcBlock, s as RpcBlockIdentifier, t as RpcBlockNumber, u as RpcFeeHistory, v as RpcFeeValues, w as RpcLog, x as RpcTransaction, y as RpcTransactionReceipt, z as RpcTransactionRequest, D as RpcUncle, T as Transaction, E as TransactionBase, J as TransactionEIP1559, K as TransactionEIP2930, a7 as TransactionFormatter, M as TransactionLegacy, N as TransactionReceipt, O as TransactionRequest, P as TransactionRequestBase, Q as TransactionRequestEIP1559, S as TransactionRequestEIP2930, U as TransactionRequestLegacy, V as TransactionSerializable, W as TransactionSerializableBase, X as TransactionSerializableEIP1559, Y as TransactionSerializableEIP2930, Z as TransactionSerializableLegacy, _ as TransactionSerialized, $ as TransactionSerializedEIP1559, a0 as TransactionSerializedEIP2930, a1 as TransactionSerializedLegacy, a2 as TransactionType, a3 as Uncle, a8 as defineTransaction, a9 as formatTransaction, aa as transactionType } from './chain-9da1e6b6.js';
|
11
|
+
export { D as DropTransactionParameters, I as ImpersonateAccountParameters, a as IncreaseTimeParameters, M as MineParameters, R as ResetParameters, b as RevertParameters, S as SendUnsignedTransactionParameters, c as SendUnsignedTransactionReturnType, d as SetBalanceParameters, e as SetBlockGasLimitParameters, f as SetBlockTimestampIntervalParameters, g as SetCodeParameters, h as SetCoinbaseParameters, i as SetIntervalMiningParameters, j as SetMinGasPriceParameters, k as SetNextBlockBaseFeePerGasParameters, l as SetNextBlockTimestampParameters, m as SetNonceParameters, n as SetStorageAtParameters, o as StopImpersonatingAccountParameters, T as TestClient, p as TestClientConfig, q as createTestClient } from './test-68dbda5b.js';
|
12
12
|
export { l as labelhash, n as namehash } from './namehash-afff0feb.js';
|
13
|
-
export { D as DecodeAbiParametersReturnType, E as EncodeAbiParametersReturnType, G as GetAbiItemParameters, d as decodeAbiParameters, e as encodeAbiParameters, g as getAbiItem } from './getAbiItem-
|
14
|
-
export { D as DecodeErrorResultParameters, a as DecodeErrorResultReturnType, b as DecodeEventLogParameters, c as DecodeEventLogReturnType, d as DecodeFunctionDataParameters, e as DecodeFunctionResultParameters, f as DecodeFunctionResultReturnType, E as EncodeDeployDataParameters, g as EncodeErrorResultParameters, h as EncodeEventTopicsParameters, i as EncodeFunctionDataParameters, j as EncodeFunctionResultParameters, k as decodeErrorResult, l as decodeEventLog, m as decodeFunctionData, n as decodeFunctionResult, o as encodeDeployData, p as encodeErrorResult, q as encodeEventTopics, r as encodeFunctionData, s as encodeFunctionResult } from './encodeFunctionResult-
|
15
|
-
export { e as encodePacked } from './encodePacked-
|
16
|
-
export { A as Account, a as AccountSource, C as CustomSource, H as HDAccount, b as HDOptions, J as JsonRpcAccount, L as LocalAccount } from './typedData-
|
17
|
-
export { d as defineChain } from './chain-
|
13
|
+
export { D as DecodeAbiParametersReturnType, E as EncodeAbiParametersReturnType, G as GetAbiItemParameters, d as decodeAbiParameters, e as encodeAbiParameters, g as getAbiItem } from './getAbiItem-5e8b01de.js';
|
14
|
+
export { D as DecodeErrorResultParameters, a as DecodeErrorResultReturnType, b as DecodeEventLogParameters, c as DecodeEventLogReturnType, d as DecodeFunctionDataParameters, e as DecodeFunctionResultParameters, f as DecodeFunctionResultReturnType, E as EncodeDeployDataParameters, g as EncodeErrorResultParameters, h as EncodeEventTopicsParameters, i as EncodeFunctionDataParameters, j as EncodeFunctionResultParameters, k as decodeErrorResult, l as decodeEventLog, m as decodeFunctionData, n as decodeFunctionResult, o as encodeDeployData, p as encodeErrorResult, q as encodeEventTopics, r as encodeFunctionData, s as encodeFunctionResult } from './encodeFunctionResult-d206ceb9.js';
|
15
|
+
export { e as encodePacked } from './encodePacked-b36ce88a.js';
|
16
|
+
export { A as Account, a as AccountSource, C as CustomSource, H as HDAccount, b as HDOptions, J as JsonRpcAccount, L as LocalAccount } from './typedData-8b24374d.js';
|
17
|
+
export { d as defineChain } from './chain-b53ed5d9.js';
|
18
18
|
export { HDKey } from '@scure/bip32';
|
19
|
-
import './eip1193-
|
19
|
+
import './eip1193-e79469af.js';
|
20
20
|
import '@wagmi/chains';
|
21
21
|
|
22
22
|
declare class AbiConstructorNotFoundError extends BaseError {
|
@@ -383,11 +383,45 @@ type CustomTransport = Transport<'custom', EthereumProvider['request']>;
|
|
383
383
|
*/
|
384
384
|
declare function custom<TProvider extends EthereumProvider>(provider: TProvider, config?: CustomTransportConfig): CustomTransport;
|
385
385
|
|
386
|
+
type RankOptions = {
|
387
|
+
/**
|
388
|
+
* The polling interval (in ms) at which the ranker should ping the RPC URL.
|
389
|
+
* @default client.pollingInterval
|
390
|
+
*/
|
391
|
+
interval?: number;
|
392
|
+
/**
|
393
|
+
* The number of previous samples to perform ranking on.
|
394
|
+
* @default 10
|
395
|
+
*/
|
396
|
+
sampleCount?: number;
|
397
|
+
/**
|
398
|
+
* Timeout when sampling transports.
|
399
|
+
* @default 1_000
|
400
|
+
*/
|
401
|
+
timeout?: number;
|
402
|
+
/**
|
403
|
+
* Weights to apply to the scores. Weight values are proportional.
|
404
|
+
*/
|
405
|
+
weights?: {
|
406
|
+
/**
|
407
|
+
* The weight to apply to the latency score.
|
408
|
+
* @default 0.3
|
409
|
+
*/
|
410
|
+
latency?: number;
|
411
|
+
/**
|
412
|
+
* The weight to apply to the stability score.
|
413
|
+
* @default 0.7
|
414
|
+
*/
|
415
|
+
stability?: number;
|
416
|
+
};
|
417
|
+
};
|
386
418
|
type FallbackTransportConfig = {
|
387
419
|
/** The key of the Fallback transport. */
|
388
420
|
key?: TransportConfig['key'];
|
389
421
|
/** The name of the Fallback transport. */
|
390
422
|
name?: TransportConfig['name'];
|
423
|
+
/** Toggle to enable ranking, or rank options. */
|
424
|
+
rank?: boolean | RankOptions;
|
391
425
|
/** The max number of times to retry. */
|
392
426
|
retryCount?: TransportConfig['retryCount'];
|
393
427
|
/** The base delay (in ms) between retries. */
|
@@ -396,7 +430,7 @@ type FallbackTransportConfig = {
|
|
396
430
|
type FallbackTransport = Transport<'fallback', {
|
397
431
|
transports: Transport[];
|
398
432
|
}>;
|
399
|
-
declare function fallback(
|
433
|
+
declare function fallback(transports_: Transport[], config?: FallbackTransportConfig): FallbackTransport;
|
400
434
|
|
401
435
|
type HttpTransportConfig = {
|
402
436
|
/**
|