viem 0.2.0-0-2-0.20230329T025357 → 0.2.0-0-2-0.20230403T055238
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-5507c6f0.d.ts} +143 -120
- package/dist/{chain-e9b996ff.d.ts → chain-fe47467d.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-7QEOFHC7.mjs → chunk-EMXJKA5P.mjs} +2 -2
- package/dist/{chunk-UCZWRYV5.mjs → chunk-KILBOPDD.mjs} +754 -33
- package/dist/chunk-KILBOPDD.mjs.map +1 -0
- package/dist/{chunk-D3ALNUWN.js → chunk-KQOOAYBY.js} +6 -6
- package/dist/{chunk-564BCC7H.js → chunk-PWUNCH5G.js} +777 -56
- package/dist/chunk-PWUNCH5G.js.map +1 -0
- 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-21a0d2b3.d.ts} +36 -34
- package/dist/{eip1193-9080db42.d.ts → eip1193-2f3a9cd2.d.ts} +1 -1
- package/dist/{encodeFunctionResult-47ad60ed.d.ts → encodeFunctionResult-c5185b98.d.ts} +15 -15
- package/dist/{encodePacked-35c796fb.d.ts → encodePacked-98f67d09.d.ts} +1 -1
- package/dist/ens.d.ts +5 -5
- package/dist/ens.js +8 -3
- package/dist/ens.js.map +1 -1
- package/dist/ens.mjs +7 -2
- package/dist/ens.mjs.map +1 -1
- 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-56dff508.d.ts} +1 -1
- package/dist/{getAbiItem-1d94ae0e.d.ts → getAbiItem-bfba73d1.d.ts} +3 -3
- package/dist/{watchPendingTransactions-468f53f2.d.ts → getEnsResolver-9e26c596.d.ts} +203 -150
- package/dist/index.d.ts +161 -18
- package/dist/index.js +222 -138
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +136 -52
- package/dist/index.mjs.map +1 -1
- package/dist/{parseGwei-f14525ab.d.ts → parseGwei-d2147f8b.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-623eb398.d.ts +16 -0
- package/dist/{test-f3d06763.d.ts → test-b67569fe.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-46b4d81f.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/window.d.ts +2 -2
- package/package.json +4 -3
- package/dist/chunk-564BCC7H.js.map +0 -1
- package/dist/chunk-BJ5KRDTG.mjs +0 -186
- package/dist/chunk-BJ5KRDTG.mjs.map +0 -1
- package/dist/chunk-CXE4XSMF.js +0 -186
- package/dist/chunk-CXE4XSMF.js.map +0 -1
- package/dist/chunk-UCZWRYV5.mjs.map +0 -1
- package/dist/parseAccount-4209fa24.d.ts +0 -6
- /package/dist/{chunk-7QEOFHC7.mjs.map → chunk-EMXJKA5P.mjs.map} +0 -0
- /package/dist/{chunk-D3ALNUWN.js.map → chunk-KQOOAYBY.js.map} +0 -0
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 {
|
1
|
+
export { D as DecodeAbiParametersReturnType, E as EncodeAbiParametersReturnType, G as GetAbiItemParameters, d as decodeAbiParameters, e as encodeAbiParameters, g as getAbiItem } from './getAbiItem-bfba73d1.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-c5185b98.js';
|
3
|
+
export { a as formatAbiItem, f as formatAbiItemWithArgs } from './formatAbiItem-56dff508.js';
|
4
|
+
export { C as CreateContractEventFilterParameters, f as CreateContractEventFilterReturnType, D as DeployContractParameters, o as DeployContractReturnType, E as EstimateContractGasParameters, b as EstimateContractGasReturnType, z as GetBytecodeParameters, B as GetBytecodeReturnType, $ as GetStorageAtParameters, a0 as GetStorageAtReturnType, a9 as MulticallParameters, aa as MulticallReturnType, af as OnLogsFn, ag as OnLogsParameter, R as ReadContractParameters, a as ReadContractReturnType, S as SimulateContractParameters, c as SimulateContractReturnType, g as WatchContractEventParameters, d as WriteContractParameters, e as WriteContractReturnType, b4 as createContractEventFilter, bc as deployContract, b5 as estimateContractGas, b6 as getBytecode, b7 as getStorageAt, b8 as multicall, b9 as readContract, ba as simulateContract, bb as watchContractEvent, bd as writeContract } from './getEnsResolver-9e26c596.js';
|
5
5
|
import 'abitype';
|
6
|
-
import './chain-
|
6
|
+
import './chain-5507c6f0.js';
|
7
7
|
import '@wagmi/chains';
|
8
|
-
import './
|
9
|
-
import './eip1193-
|
10
|
-
import './typedData-
|
8
|
+
import './createTransport-21a0d2b3.js';
|
9
|
+
import './eip1193-2f3a9cd2.js';
|
10
|
+
import './typedData-46b4d81f.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 _chunkPWUNCH5Gjs = require('./chunk-PWUNCH5G.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 = _chunkPWUNCH5Gjs.createContractEventFilter; exports.decodeAbiParameters = _chunkPWUNCH5Gjs.decodeAbiParameters; exports.decodeErrorResult = _chunkPWUNCH5Gjs.decodeErrorResult; exports.decodeEventLog = _chunkPWUNCH5Gjs.decodeEventLog; exports.decodeFunctionData = _chunkPWUNCH5Gjs.decodeFunctionData; exports.decodeFunctionResult = _chunkPWUNCH5Gjs.decodeFunctionResult; exports.deployContract = _chunkPWUNCH5Gjs.deployContract; exports.encodeAbiParameters = _chunkPWUNCH5Gjs.encodeAbiParameters; exports.encodeDeployData = _chunkPWUNCH5Gjs.encodeDeployData; exports.encodeErrorResult = _chunkPWUNCH5Gjs.encodeErrorResult; exports.encodeEventTopics = _chunkPWUNCH5Gjs.encodeEventTopics; exports.encodeFunctionData = _chunkPWUNCH5Gjs.encodeFunctionData; exports.encodeFunctionResult = _chunkPWUNCH5Gjs.encodeFunctionResult; exports.estimateContractGas = _chunkPWUNCH5Gjs.estimateContractGas; exports.formatAbiItem = _chunkPWUNCH5Gjs.formatAbiItem; exports.formatAbiItemWithArgs = _chunkPWUNCH5Gjs.formatAbiItemWithArgs; exports.getAbiItem = _chunkPWUNCH5Gjs.getAbiItem; exports.getBytecode = _chunkPWUNCH5Gjs.getBytecode; exports.getStorageAt = _chunkPWUNCH5Gjs.getStorageAt; exports.multicall = _chunkPWUNCH5Gjs.multicall; exports.readContract = _chunkPWUNCH5Gjs.readContract; exports.simulateContract = _chunkPWUNCH5Gjs.simulateContract; exports.watchContractEvent = _chunkPWUNCH5Gjs.watchContractEvent; exports.writeContract = _chunkPWUNCH5Gjs.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-2f3a9cd2.js';
|
2
|
+
import { C as Chain } from './chain-5507c6f0.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,
|
2
|
+
import { a as Hash, an as Quantity, K as RpcTransactionRequest, x as RpcBlockNumber, i as BlockTag, w as RpcBlockIdentifier, H as Hex, y as RpcFeeHistory, R as RpcBlock, D as RpcLog, aq as LogTopic, E as RpcTransaction, J as RpcTransactionReceipt, N as RpcUncle } from './chain-5507c6f0.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, t as InferEventName, q as GetEventArgsFromTopics, u as InferFunctionName, r as GetFunctionArgs, k as ContractFunctionResult, G as GetConstructorArgs, s as InferErrorName, o as GetErrorArgs, p as GetEventArgs } from './chain-5507c6f0.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-5507c6f0.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 {
|
1
|
+
export { H as GetEnsAddressParameters, I as GetEnsAddressReturnType, be as GetEnsAvatarParameters, bf as GetEnsAvatarReturnType, J as GetEnsNameParameters, K as GetEnsNameReturnType, L as GetEnsResolverParameters, M as GetEnsResolverReturnType, bg as GetEnsTextParameters, bh as GetEnsTextReturnType, bi as getEnsAddress, bj as getEnsAvatar, bk as getEnsName, bl as getEnsResolver, bm as getEnsText } from './getEnsResolver-9e26c596.js';
|
2
2
|
export { l as labelhash, n as namehash } from './namehash-afff0feb.js';
|
3
|
-
import './
|
4
|
-
import './eip1193-
|
3
|
+
import './createTransport-21a0d2b3.js';
|
4
|
+
import './eip1193-2f3a9cd2.js';
|
5
5
|
import 'abitype';
|
6
|
-
import './chain-
|
6
|
+
import './chain-5507c6f0.js';
|
7
7
|
import '@wagmi/chains';
|
8
|
-
import './typedData-
|
8
|
+
import './typedData-46b4d81f.js';
|
9
9
|
import '@scure/bip32';
|
10
10
|
|
11
11
|
/**
|
package/dist/ens.js
CHANGED
@@ -3,8 +3,10 @@
|
|
3
3
|
|
4
4
|
|
5
5
|
|
6
|
-
|
7
|
-
|
6
|
+
|
7
|
+
|
8
|
+
|
9
|
+
var _chunkPWUNCH5Gjs = require('./chunk-PWUNCH5G.js');
|
8
10
|
|
9
11
|
// src/utils/ens/normalize.ts
|
10
12
|
var _idnauts46hx = require('idna-uts46-hx');
|
@@ -17,5 +19,8 @@ function normalize(name) {
|
|
17
19
|
|
18
20
|
|
19
21
|
|
20
|
-
|
22
|
+
|
23
|
+
|
24
|
+
|
25
|
+
exports.getEnsAddress = _chunkPWUNCH5Gjs.getEnsAddress; exports.getEnsAvatar = _chunkPWUNCH5Gjs.getEnsAvatar; exports.getEnsName = _chunkPWUNCH5Gjs.getEnsName; exports.getEnsResolver = _chunkPWUNCH5Gjs.getEnsResolver; exports.getEnsText = _chunkPWUNCH5Gjs.getEnsText; exports.labelhash = _chunkPWUNCH5Gjs.labelhash; exports.namehash = _chunkPWUNCH5Gjs.namehash; exports.normalize = normalize;
|
21
26
|
//# sourceMappingURL=ens.js.map
|
package/dist/ens.js.map
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"sources":["../src/utils/ens/normalize.ts"],"names":[],"mappings":"
|
1
|
+
{"version":3,"sources":["../src/utils/ens/normalize.ts"],"names":[],"mappings":";;;;;;;;;;;AAAA,SAAS,iBAAiB;AAWnB,SAAS,UAAU,MAAc;AACtC,SAAO,UAAU,MAAM,EAAE,cAAc,KAAK,CAAC;AAC/C","sourcesContent":["import { toUnicode } from 'idna-uts46-hx'\n\n/**\n * @description Normalizes ENS name\n *\n * @example\n * normalize('wagmi-dev.eth')\n * 'wagmi-dev.eth'\n *\n * @see https://docs.ens.domains/contract-api-reference/name-processing#normalising-names\n */\nexport function normalize(name: string) {\n return toUnicode(name, { useStd3ASCII: true })\n}\n"]}
|
package/dist/ens.mjs
CHANGED
@@ -1,10 +1,12 @@
|
|
1
1
|
import {
|
2
2
|
getEnsAddress,
|
3
|
+
getEnsAvatar,
|
3
4
|
getEnsName,
|
5
|
+
getEnsResolver,
|
6
|
+
getEnsText,
|
4
7
|
labelhash,
|
5
8
|
namehash
|
6
|
-
} from "./chunk-
|
7
|
-
import "./chunk-UCZWRYV5.mjs";
|
9
|
+
} from "./chunk-KILBOPDD.mjs";
|
8
10
|
|
9
11
|
// src/utils/ens/normalize.ts
|
10
12
|
import { toUnicode } from "idna-uts46-hx";
|
@@ -13,7 +15,10 @@ function normalize(name) {
|
|
13
15
|
}
|
14
16
|
export {
|
15
17
|
getEnsAddress,
|
18
|
+
getEnsAvatar,
|
16
19
|
getEnsName,
|
20
|
+
getEnsResolver,
|
21
|
+
getEnsText,
|
17
22
|
labelhash,
|
18
23
|
namehash,
|
19
24
|
normalize
|
package/dist/ens.mjs.map
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"sources":["../src/utils/ens/normalize.ts"],"sourcesContent":["import { toUnicode } from 'idna-uts46-hx'\n\n/**\n * @description Normalizes ENS name\n *\n * @example\n * normalize('wagmi-dev.eth')\n * 'wagmi-dev.eth'\n *\n * @see https://docs.ens.domains/contract-api-reference/name-processing#normalising-names\n */\nexport function normalize(name: string) {\n return toUnicode(name, { useStd3ASCII: true })\n}\n"],"mappings":"
|
1
|
+
{"version":3,"sources":["../src/utils/ens/normalize.ts"],"sourcesContent":["import { toUnicode } from 'idna-uts46-hx'\n\n/**\n * @description Normalizes ENS name\n *\n * @example\n * normalize('wagmi-dev.eth')\n * 'wagmi-dev.eth'\n *\n * @see https://docs.ens.domains/contract-api-reference/name-processing#normalising-names\n */\nexport function normalize(name: string) {\n return toUnicode(name, { useStd3ASCII: true })\n}\n"],"mappings":";;;;;;;;;;;AAAA,SAAS,iBAAiB;AAWnB,SAAS,UAAU,MAAc;AACtC,SAAO,UAAU,MAAM,EAAE,cAAc,KAAK,CAAC;AAC/C;","names":[]}
|
package/dist/ethers.d.ts
CHANGED
@@ -1,7 +1,7 @@
|
|
1
|
-
import { L as LocalAccount } from './typedData-
|
1
|
+
import { L as LocalAccount } from './typedData-46b4d81f.js';
|
2
2
|
import '@scure/bip32';
|
3
3
|
import 'abitype';
|
4
|
-
import './chain-
|
4
|
+
import './chain-5507c6f0.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 _chunkKQOOAYBYjs = require('./chunk-KQOOAYBY.js');
|
4
4
|
|
5
5
|
|
6
|
-
var
|
6
|
+
var _chunkPWUNCH5Gjs = require('./chunk-PWUNCH5G.js');
|
7
7
|
|
8
8
|
// src/adapters/ethers.ts
|
9
|
-
var ethersWalletToAccount = (wallet) =>
|
9
|
+
var ethersWalletToAccount = (wallet) => _chunkKQOOAYBYjs.toAccount.call(void 0, {
|
10
10
|
address: wallet.address,
|
11
11
|
async signMessage({ message }) {
|
12
|
-
return await wallet.signMessage(
|
12
|
+
return await wallet.signMessage(_chunkPWUNCH5Gjs.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, v as InferItemName, r as GetFunctionArgs } from './chain-5507c6f0.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
|
}>;
|