viem 0.2.0-0-2-0.20230320T235312 → 0.2.0-0-2-0.20230328T054201
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/accounts/package.json +4 -0
- 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 +90 -0
- package/dist/accounts/index.js +152 -0
- package/dist/accounts/index.js.map +1 -0
- package/dist/accounts/index.mjs +152 -0
- package/dist/accounts/index.mjs.map +1 -0
- package/dist/{chain-c4f924cf.d.ts → chain-40443542.d.ts} +1 -1
- package/dist/{chain-b2e88e30.d.ts → chain-4af995bf.d.ts} +121 -85
- package/dist/chains.d.ts +3 -3
- package/dist/chains.js +63 -63
- package/dist/chains.mjs +1 -1
- package/dist/chunk-43HQD3IL.js +31 -0
- package/dist/chunk-43HQD3IL.js.map +1 -0
- package/dist/{chunk-4DIN6KDM.mjs → chunk-DFMQLPHS.mjs} +2 -2
- package/dist/chunk-DFMQLPHS.mjs.map +1 -0
- package/dist/{chunk-BLB7NERO.js → chunk-FZPFAAOJ.js} +19 -19
- package/dist/chunk-FZPFAAOJ.js.map +1 -0
- package/dist/{chunk-KOAJUBTN.mjs → chunk-HYEOQX7O.mjs} +802 -193
- package/dist/chunk-HYEOQX7O.mjs.map +1 -0
- package/dist/{chunk-T4AH4Y6Y.js → chunk-OW7TKT7L.js} +812 -203
- package/dist/chunk-OW7TKT7L.js.map +1 -0
- package/dist/chunk-UK6FAD4V.mjs +31 -0
- package/dist/chunk-UK6FAD4V.mjs.map +1 -0
- package/dist/contract.d.ts +9 -8
- package/dist/contract.js +2 -2
- package/dist/contract.mjs +1 -1
- package/dist/{createClient-d4f1dea1.d.ts → createClient-1f19be8d.d.ts} +23 -9
- package/dist/{createPublicClient-3a714a8d.d.ts → createPublicClient-fd8b1349.d.ts} +166 -126
- package/dist/{eip1193-cd3e872a.d.ts → eip1193-210ab776.d.ts} +1 -1
- package/dist/{encodeFunctionResult-750c9055.d.ts → encodeFunctionResult-a252fba1.d.ts} +1 -1
- package/dist/{encodePacked-de74201f.d.ts → encodePacked-a9464e97.d.ts} +1 -1
- package/dist/ens.d.ts +6 -5
- package/dist/ens.js +3 -3
- package/dist/ens.mjs +2 -2
- package/dist/ethers.d.ts +5 -4
- package/dist/ethers.js +7 -5
- package/dist/ethers.js.map +1 -1
- package/dist/ethers.mjs +7 -5
- package/dist/ethers.mjs.map +1 -1
- package/dist/{formatAbiItem-fdbdda39.d.ts → formatAbiItem-6ed70dbd.d.ts} +1 -1
- package/dist/{getAbiItem-9d709e3b.d.ts → getAbiItem-1ff0f41a.d.ts} +1 -1
- package/dist/index.d.ts +22 -15
- package/dist/index.js +130 -103
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +72 -45
- package/dist/index.mjs.map +1 -1
- package/dist/parseAccount-8e131c73.d.ts +6 -0
- package/dist/{parseGwei-f930d155.d.ts → parseGwei-5e2a8e87.d.ts} +61 -18
- package/dist/public.d.ts +6 -5
- package/dist/public.js +2 -2
- package/dist/public.mjs +1 -1
- package/dist/test-e28db435.d.ts +198 -0
- package/dist/test.d.ts +11 -11
- package/dist/test.js +2 -2
- package/dist/test.mjs +1 -1
- package/dist/{account-07d04222.d.ts → typedData-848139b1.d.ts} +46 -27
- package/dist/utils/index.d.ts +17 -35
- package/dist/utils/index.js +18 -2
- package/dist/utils/index.mjs +19 -3
- package/dist/wallet.d.ts +6 -5
- package/dist/wallet.js +2 -2
- package/dist/wallet.mjs +1 -1
- package/dist/window.d.ts +2 -2
- package/package.json +9 -1
- package/dist/chunk-4DIN6KDM.mjs.map +0 -1
- package/dist/chunk-BLB7NERO.js.map +0 -1
- package/dist/chunk-KOAJUBTN.mjs.map +0 -1
- package/dist/chunk-T4AH4Y6Y.js.map +0 -1
- package/dist/test-c70126a6.d.ts +0 -206
@@ -0,0 +1,198 @@
|
|
1
|
+
import { a as Transport, b as ClientConfig, C as Client } from './createClient-1f19be8d.js';
|
2
|
+
import { a as Hash, C as Chain, y as RpcTransaction, ak as Quantity, P as TransactionRequest, H as Hex } from './chain-4af995bf.js';
|
3
|
+
import { T as TestRequests } from './eip1193-210ab776.js';
|
4
|
+
import { Address } from 'abitype';
|
5
|
+
import { Chain as Chain$1 } from '@wagmi/chains';
|
6
|
+
|
7
|
+
type DropTransactionParameters = {
|
8
|
+
/** The hash of the transaction to drop. */
|
9
|
+
hash: Hash;
|
10
|
+
};
|
11
|
+
declare function dropTransaction<TChain extends Chain | undefined>(client: TestClient<TestClientMode, Transport, TChain>, { hash }: DropTransactionParameters): Promise<void>;
|
12
|
+
|
13
|
+
type GetAutomineReturnType = boolean;
|
14
|
+
declare function getAutomine<TChain extends Chain | undefined>(client: TestClient<TestClientMode, Transport, TChain>): Promise<GetAutomineReturnType>;
|
15
|
+
|
16
|
+
type GetTxpoolContentReturnType = {
|
17
|
+
pending: Record<Address, Record<string, RpcTransaction>>;
|
18
|
+
queued: Record<Address, Record<string, RpcTransaction>>;
|
19
|
+
};
|
20
|
+
declare function getTxpoolContent<TChain extends Chain | undefined>(client: TestClient<TestClientMode, Transport, TChain>): Promise<GetTxpoolContentReturnType>;
|
21
|
+
|
22
|
+
type GetTxpoolStatusReturnType = {
|
23
|
+
pending: number;
|
24
|
+
queued: number;
|
25
|
+
};
|
26
|
+
declare function getTxpoolStatus<TChain extends Chain$1 | undefined>(client: TestClient<TestClientMode, Transport, TChain>): Promise<GetTxpoolStatusReturnType>;
|
27
|
+
|
28
|
+
type ImpersonateAccountParameters = {
|
29
|
+
/** The account to impersonate. */
|
30
|
+
address: Address;
|
31
|
+
};
|
32
|
+
declare function impersonateAccount<TChain extends Chain | undefined>(client: TestClient<TestClientMode, Transport, TChain>, { address }: ImpersonateAccountParameters): Promise<void>;
|
33
|
+
|
34
|
+
type IncreaseTimeParameters = {
|
35
|
+
/** The amount of seconds to jump forward in time. */
|
36
|
+
seconds: number;
|
37
|
+
};
|
38
|
+
declare function increaseTime<TChain extends Chain$1 | undefined>(client: TestClient<TestClientMode, Transport, TChain>, { seconds }: IncreaseTimeParameters): Promise<`0x${string}`>;
|
39
|
+
|
40
|
+
type InspectTxpoolReturnType = {
|
41
|
+
pending: Record<Address, Record<string, string>>;
|
42
|
+
queued: Record<Address, Record<string, string>>;
|
43
|
+
};
|
44
|
+
declare function inspectTxpool<TChain extends Chain | undefined>(client: TestClient<TestClientMode, Transport, TChain>): Promise<InspectTxpoolReturnType>;
|
45
|
+
|
46
|
+
type MineParameters = {
|
47
|
+
/** Number of blocks to mine. */
|
48
|
+
blocks: number;
|
49
|
+
/** Interval between each block in seconds. */
|
50
|
+
interval?: number;
|
51
|
+
};
|
52
|
+
declare function mine<TChain extends Chain | undefined>(client: TestClient<TestClientMode, Transport, TChain>, { blocks, interval }: MineParameters): Promise<void>;
|
53
|
+
|
54
|
+
type ResetParameters = {
|
55
|
+
/** The block number to reset from. */
|
56
|
+
blockNumber?: bigint;
|
57
|
+
/** The JSON RPC URL. */
|
58
|
+
jsonRpcUrl?: string;
|
59
|
+
};
|
60
|
+
declare function reset<TChain extends Chain | undefined>(client: TestClient<TestClientMode, Transport, TChain>, { blockNumber, jsonRpcUrl }?: ResetParameters): Promise<void>;
|
61
|
+
|
62
|
+
type RevertParameters = {
|
63
|
+
/** The snapshot ID to revert to. */
|
64
|
+
id: Quantity;
|
65
|
+
};
|
66
|
+
declare function revert<TChain extends Chain | undefined>(client: TestClient<TestClientMode, Transport, TChain>, { id }: RevertParameters): Promise<void>;
|
67
|
+
|
68
|
+
type SendUnsignedTransactionParameters = TransactionRequest;
|
69
|
+
type SendUnsignedTransactionReturnType = Hash;
|
70
|
+
declare function sendUnsignedTransaction<TChain extends Chain | undefined>(client: TestClient<TestClientMode, Transport, TChain>, request: SendUnsignedTransactionParameters): Promise<SendUnsignedTransactionReturnType>;
|
71
|
+
|
72
|
+
type SetBalanceParameters = {
|
73
|
+
/** The account address. */
|
74
|
+
address: Address;
|
75
|
+
/** Amount (in wei) to set */
|
76
|
+
value: bigint;
|
77
|
+
};
|
78
|
+
declare function setBalance<TChain extends Chain | undefined>(client: TestClient<TestClientMode, Transport, TChain>, { address, value }: SetBalanceParameters): Promise<void>;
|
79
|
+
|
80
|
+
type SetBlockGasLimitParameters = {
|
81
|
+
/** Gas limit (in wei). */
|
82
|
+
gasLimit: bigint;
|
83
|
+
};
|
84
|
+
declare function setBlockGasLimit<TChain extends Chain | undefined>(client: TestClient<TestClientMode, Transport, TChain>, { gasLimit }: SetBlockGasLimitParameters): Promise<void>;
|
85
|
+
|
86
|
+
type SetBlockTimestampIntervalParameters = {
|
87
|
+
/** The interval (in seconds). */
|
88
|
+
interval: number;
|
89
|
+
};
|
90
|
+
declare function setBlockTimestampInterval<TChain extends Chain$1 | undefined>(client: TestClient<TestClientMode, Transport, TChain>, { interval }: SetBlockTimestampIntervalParameters): Promise<void>;
|
91
|
+
|
92
|
+
type SetCodeParameters = {
|
93
|
+
/** The account address. */
|
94
|
+
address: Address;
|
95
|
+
/** The bytecode to set */
|
96
|
+
bytecode: Hex;
|
97
|
+
};
|
98
|
+
declare function setCode<TChain extends Chain | undefined>(client: TestClient<TestClientMode, Transport, TChain>, { address, bytecode }: SetCodeParameters): Promise<void>;
|
99
|
+
|
100
|
+
type SetCoinbaseParameters = {
|
101
|
+
/** The coinbase address. */
|
102
|
+
address: Address;
|
103
|
+
};
|
104
|
+
declare function setCoinbase<TChain extends Chain | undefined>(client: TestClient<TestClientMode, Transport, TChain>, { address }: SetCoinbaseParameters): Promise<void>;
|
105
|
+
|
106
|
+
type SetIntervalMiningParameters = {
|
107
|
+
/** The mining interval. */
|
108
|
+
interval: number;
|
109
|
+
};
|
110
|
+
declare function setIntervalMining<TChain extends Chain | undefined>(client: TestClient<TestClientMode, Transport, TChain>, { interval }: SetIntervalMiningParameters): Promise<void>;
|
111
|
+
|
112
|
+
type SetMinGasPriceParameters = {
|
113
|
+
/** The gas price. */
|
114
|
+
gasPrice: bigint;
|
115
|
+
};
|
116
|
+
declare function setMinGasPrice<TChain extends Chain | undefined>(client: TestClient<TestClientMode, Transport, TChain>, { gasPrice }: SetMinGasPriceParameters): Promise<void>;
|
117
|
+
|
118
|
+
type SetNextBlockBaseFeePerGasParameters = {
|
119
|
+
/** Base fee per gas (in wei). */
|
120
|
+
baseFeePerGas: bigint;
|
121
|
+
};
|
122
|
+
declare function setNextBlockBaseFeePerGas<TChain extends Chain | undefined>(client: TestClient<TestClientMode, Transport, TChain>, { baseFeePerGas }: SetNextBlockBaseFeePerGasParameters): Promise<void>;
|
123
|
+
|
124
|
+
type SetNextBlockTimestampParameters = {
|
125
|
+
/** The timestamp (in seconds). */
|
126
|
+
timestamp: bigint;
|
127
|
+
};
|
128
|
+
declare function setNextBlockTimestamp<TChain extends Chain | undefined>(client: TestClient<TestClientMode, Transport, TChain>, { timestamp }: SetNextBlockTimestampParameters): Promise<void>;
|
129
|
+
|
130
|
+
type SetNonceParameters = {
|
131
|
+
/** The account address. */
|
132
|
+
address: Address;
|
133
|
+
/** The nonce to set. */
|
134
|
+
nonce: number;
|
135
|
+
};
|
136
|
+
declare function setNonce<TChain extends Chain | undefined>(client: TestClient<TestClientMode, Transport, TChain>, { address, nonce }: SetNonceParameters): Promise<void>;
|
137
|
+
|
138
|
+
type SetStorageAtParameters = {
|
139
|
+
/** The account address. */
|
140
|
+
address: Address;
|
141
|
+
/** The storage slot (index). Can either be a number or hash value. */
|
142
|
+
index: number | Hash;
|
143
|
+
/** The value to store as a 32 byte hex string. */
|
144
|
+
value: Hex;
|
145
|
+
};
|
146
|
+
declare function setStorageAt<TChain extends Chain | undefined>(client: TestClient<TestClientMode, Transport, TChain>, { address, index, value }: SetStorageAtParameters): Promise<void>;
|
147
|
+
|
148
|
+
type StopImpersonatingAccountParameters = {
|
149
|
+
/** The account to impersonate. */
|
150
|
+
address: Address;
|
151
|
+
};
|
152
|
+
declare function stopImpersonatingAccount<TChain extends Chain | undefined>(client: TestClient<TestClientMode, Transport, TChain>, { address }: StopImpersonatingAccountParameters): Promise<void>;
|
153
|
+
|
154
|
+
type TestClientMode = 'anvil' | 'hardhat';
|
155
|
+
type TestClientConfig<TMode extends TestClientMode = TestClientMode, TTransport extends Transport = Transport, TChain extends Chain | undefined = Chain | undefined> = Pick<ClientConfig<TTransport, TChain>, 'chain' | 'key' | 'name' | 'pollingInterval' | 'transport'> & {
|
156
|
+
/** Mode of the test client. Available: "anvil" | "hardhat" */
|
157
|
+
mode: TMode;
|
158
|
+
};
|
159
|
+
type TestClient<TMode extends TestClientMode = TestClientMode, TTransport extends Transport = Transport, TChain extends Chain | undefined = Chain | undefined, TIncludeActions extends boolean = true> = Client<TTransport, TestRequests<TMode>, TChain> & (TIncludeActions extends true ? TestActions : unknown) & {
|
160
|
+
mode: TMode;
|
161
|
+
};
|
162
|
+
/**
|
163
|
+
* @description Creates a test client with a given transport.
|
164
|
+
*/
|
165
|
+
declare function createTestClient<TMode extends TestClientMode, TTransport extends Transport, TChain extends Chain | undefined = undefined>({ chain, key, name, mode, pollingInterval, transport, }: TestClientConfig<TMode, TTransport, TChain>): TestClient<TMode, TTransport, TChain, true>;
|
166
|
+
|
167
|
+
type TestActions = {
|
168
|
+
dropTransaction: (args: DropTransactionParameters) => Promise<void>;
|
169
|
+
getAutomine: () => Promise<GetAutomineReturnType>;
|
170
|
+
getTxpoolContent: () => Promise<GetTxpoolContentReturnType>;
|
171
|
+
getTxpoolStatus: () => Promise<GetTxpoolStatusReturnType>;
|
172
|
+
impersonateAccount: (args: ImpersonateAccountParameters) => Promise<void>;
|
173
|
+
increaseTime: (args: IncreaseTimeParameters) => Promise<Quantity>;
|
174
|
+
inspectTxpool: () => Promise<InspectTxpoolReturnType>;
|
175
|
+
mine: (args: MineParameters) => Promise<void>;
|
176
|
+
removeBlockTimestampInterval: () => Promise<void>;
|
177
|
+
reset: (args?: ResetParameters) => Promise<void>;
|
178
|
+
revert: (args: RevertParameters) => Promise<void>;
|
179
|
+
sendUnsignedTransaction: (args: SendUnsignedTransactionParameters) => Promise<SendUnsignedTransactionReturnType>;
|
180
|
+
setAutomine: (args: boolean) => Promise<void>;
|
181
|
+
setBalance: (args: SetBalanceParameters) => Promise<void>;
|
182
|
+
setBlockGasLimit: (args: SetBlockGasLimitParameters) => Promise<void>;
|
183
|
+
setBlockTimestampInterval: (args: SetBlockTimestampIntervalParameters) => Promise<void>;
|
184
|
+
setCode: (args: SetCodeParameters) => Promise<void>;
|
185
|
+
setCoinbase: (args: SetCoinbaseParameters) => Promise<void>;
|
186
|
+
setIntervalMining: (args: SetIntervalMiningParameters) => Promise<void>;
|
187
|
+
setLoggingEnabled: (args: boolean) => Promise<void>;
|
188
|
+
setMinGasPrice: (args: SetMinGasPriceParameters) => Promise<void>;
|
189
|
+
setNextBlockBaseFeePerGas: (args: SetNextBlockBaseFeePerGasParameters) => Promise<void>;
|
190
|
+
setNextBlockTimestamp: (args: SetNextBlockTimestampParameters) => Promise<void>;
|
191
|
+
setNonce: (args: SetNonceParameters) => Promise<void>;
|
192
|
+
setRpcUrl: (args: string) => Promise<void>;
|
193
|
+
setStorageAt: (args: SetStorageAtParameters) => Promise<void>;
|
194
|
+
snapshot: () => Promise<Quantity>;
|
195
|
+
stopImpersonatingAccount: (args: StopImpersonatingAccountParameters) => Promise<void>;
|
196
|
+
};
|
197
|
+
|
198
|
+
export { IncreaseTimeParameters as A, RevertParameters as B, SendUnsignedTransactionReturnType as C, DropTransactionParameters as D, SetBalanceParameters as E, SetBlockGasLimitParameters as F, SetBlockTimestampIntervalParameters as G, SetCodeParameters as H, ImpersonateAccountParameters as I, SetCoinbaseParameters as J, SetIntervalMiningParameters as K, SetMinGasPriceParameters as L, MineParameters as M, SetNextBlockBaseFeePerGasParameters as N, SetNextBlockTimestampParameters as O, SetNonceParameters as P, SetStorageAtParameters as Q, ResetParameters as R, SendUnsignedTransactionParameters as S, TestClient as T, StopImpersonatingAccountParameters as U, TestClientConfig as a, TestClientMode as b, createTestClient as c, dropTransaction as d, getTxpoolContent as e, getTxpoolStatus as f, getAutomine as g, increaseTime as h, impersonateAccount as i, inspectTxpool as j, revert as k, setBalance as l, mine as m, setBlockGasLimit as n, setBlockTimestampInterval as o, setCode as p, setCoinbase as q, reset as r, sendUnsignedTransaction as s, setIntervalMining as t, setMinGasPrice as u, setNextBlockBaseFeePerGas as v, setNextBlockTimestamp as w, setNonce as x, setStorageAt as y, stopImpersonatingAccount as z };
|
package/dist/test.d.ts
CHANGED
@@ -1,19 +1,19 @@
|
|
1
|
-
import { b as
|
2
|
-
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, E as SetBalanceParameters, F as SetBlockGasLimitParameters, G as SetBlockTimestampIntervalParameters, H as SetCodeParameters, J as SetCoinbaseParameters, K as SetIntervalMiningParameters, L as SetMinGasPriceParameters, N as SetNextBlockBaseFeePerGasParameters, O as SetNextBlockTimestampParameters, P as SetNonceParameters, Q as SetStorageAtParameters, U as StopImpersonatingAccountParameters, d as dropTransaction, g as getAutomine, e as getTxpoolContent, f as getTxpoolStatus, i as impersonateAccount, h as increaseTime, j as inspectTxpool, m as mine, r as reset, k as revert, s as sendUnsignedTransaction, l as setBalance, n as setBlockGasLimit, o as setBlockTimestampInterval, p as setCode, q as setCoinbase, t as setIntervalMining, u as setMinGasPrice, v as setNextBlockBaseFeePerGas, w as setNextBlockTimestamp, x as setNonce, y as setStorageAt, z as stopImpersonatingAccount } from './test-
|
3
|
-
import '
|
4
|
-
import '
|
1
|
+
import { T as TestClient, b as TestClientMode } from './test-e28db435.js';
|
2
|
+
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, E as SetBalanceParameters, F as SetBlockGasLimitParameters, G as SetBlockTimestampIntervalParameters, H as SetCodeParameters, J as SetCoinbaseParameters, K as SetIntervalMiningParameters, L as SetMinGasPriceParameters, N as SetNextBlockBaseFeePerGasParameters, O as SetNextBlockTimestampParameters, P as SetNonceParameters, Q as SetStorageAtParameters, U as StopImpersonatingAccountParameters, d as dropTransaction, g as getAutomine, e as getTxpoolContent, f as getTxpoolStatus, i as impersonateAccount, h as increaseTime, j as inspectTxpool, m as mine, r as reset, k as revert, s as sendUnsignedTransaction, l as setBalance, n as setBlockGasLimit, o as setBlockTimestampInterval, p as setCode, q as setCoinbase, t as setIntervalMining, u as setMinGasPrice, v as setNextBlockBaseFeePerGas, w as setNextBlockTimestamp, x as setNonce, y as setStorageAt, z as stopImpersonatingAccount } from './test-e28db435.js';
|
3
|
+
import { Chain } from '@wagmi/chains';
|
4
|
+
import { a as Transport } from './createClient-1f19be8d.js';
|
5
|
+
import { C as Chain$1 } from './chain-4af995bf.js';
|
6
|
+
import './eip1193-210ab776.js';
|
5
7
|
import 'abitype';
|
6
|
-
import './createClient-d4f1dea1.js';
|
7
|
-
import './eip1193-cd3e872a.js';
|
8
8
|
|
9
|
-
declare function removeBlockTimestampInterval(client:
|
9
|
+
declare function removeBlockTimestampInterval<TChain extends Chain | undefined>(client: TestClient<TestClientMode, Transport, TChain>): Promise<void>;
|
10
10
|
|
11
|
-
declare function setAutomine(client:
|
11
|
+
declare function setAutomine<TChain extends Chain$1 | undefined>(client: TestClient<TestClientMode, Transport, TChain>, enabled: boolean): Promise<void>;
|
12
12
|
|
13
|
-
declare function setLoggingEnabled(client:
|
13
|
+
declare function setLoggingEnabled<TChain extends Chain$1 | undefined>(client: TestClient<TestClientMode, Transport, TChain>, enabled: boolean): Promise<void>;
|
14
14
|
|
15
|
-
declare function setRpcUrl(client:
|
15
|
+
declare function setRpcUrl<TChain extends Chain$1 | undefined>(client: TestClient<TestClientMode, Transport, TChain>, jsonRpcUrl: string): Promise<void>;
|
16
16
|
|
17
|
-
declare function snapshot(client:
|
17
|
+
declare function snapshot<TChain extends Chain$1 | undefined>(client: TestClient<TestClientMode, Transport, TChain>): Promise<`0x${string}`>;
|
18
18
|
|
19
19
|
export { removeBlockTimestampInterval, setAutomine, setLoggingEnabled, setRpcUrl, snapshot };
|
package/dist/test.js
CHANGED
@@ -27,7 +27,7 @@
|
|
27
27
|
|
28
28
|
|
29
29
|
|
30
|
-
var
|
30
|
+
var _chunkOW7TKT7Ljs = require('./chunk-OW7TKT7L.js');
|
31
31
|
|
32
32
|
|
33
33
|
|
@@ -57,5 +57,5 @@ var _chunkT4AH4Y6Yjs = require('./chunk-T4AH4Y6Y.js');
|
|
57
57
|
|
58
58
|
|
59
59
|
|
60
|
-
exports.dropTransaction =
|
60
|
+
exports.dropTransaction = _chunkOW7TKT7Ljs.dropTransaction; exports.getAutomine = _chunkOW7TKT7Ljs.getAutomine; exports.getTxpoolContent = _chunkOW7TKT7Ljs.getTxpoolContent; exports.getTxpoolStatus = _chunkOW7TKT7Ljs.getTxpoolStatus; exports.impersonateAccount = _chunkOW7TKT7Ljs.impersonateAccount; exports.increaseTime = _chunkOW7TKT7Ljs.increaseTime; exports.inspectTxpool = _chunkOW7TKT7Ljs.inspectTxpool; exports.mine = _chunkOW7TKT7Ljs.mine; exports.removeBlockTimestampInterval = _chunkOW7TKT7Ljs.removeBlockTimestampInterval; exports.reset = _chunkOW7TKT7Ljs.reset; exports.revert = _chunkOW7TKT7Ljs.revert; exports.sendUnsignedTransaction = _chunkOW7TKT7Ljs.sendUnsignedTransaction; exports.setAutomine = _chunkOW7TKT7Ljs.setAutomine; exports.setBalance = _chunkOW7TKT7Ljs.setBalance; exports.setBlockGasLimit = _chunkOW7TKT7Ljs.setBlockGasLimit; exports.setBlockTimestampInterval = _chunkOW7TKT7Ljs.setBlockTimestampInterval; exports.setCode = _chunkOW7TKT7Ljs.setCode; exports.setCoinbase = _chunkOW7TKT7Ljs.setCoinbase; exports.setIntervalMining = _chunkOW7TKT7Ljs.setIntervalMining; exports.setLoggingEnabled = _chunkOW7TKT7Ljs.setLoggingEnabled; exports.setMinGasPrice = _chunkOW7TKT7Ljs.setMinGasPrice; exports.setNextBlockBaseFeePerGas = _chunkOW7TKT7Ljs.setNextBlockBaseFeePerGas; exports.setNextBlockTimestamp = _chunkOW7TKT7Ljs.setNextBlockTimestamp; exports.setNonce = _chunkOW7TKT7Ljs.setNonce; exports.setRpcUrl = _chunkOW7TKT7Ljs.setRpcUrl; exports.setStorageAt = _chunkOW7TKT7Ljs.setStorageAt; exports.snapshot = _chunkOW7TKT7Ljs.snapshot; exports.stopImpersonatingAccount = _chunkOW7TKT7Ljs.stopImpersonatingAccount;
|
61
61
|
//# sourceMappingURL=test.js.map
|
package/dist/test.mjs
CHANGED
@@ -1,5 +1,48 @@
|
|
1
|
-
import {
|
2
|
-
import {
|
1
|
+
import { HDKey } from '@scure/bip32';
|
2
|
+
import { Address, TypedData, TypedDataToPrimitiveTypes, TypedDataDomain, Narrow } from 'abitype';
|
3
|
+
import { a as Hash, W as TransactionSerializable, H as Hex } from './chain-4af995bf.js';
|
4
|
+
|
5
|
+
type Account<TAddress extends Address = Address> = JsonRpcAccount<TAddress> | LocalAccount<string, TAddress>;
|
6
|
+
type AccountSource = Address | CustomSource;
|
7
|
+
type CustomSource = {
|
8
|
+
address: Address;
|
9
|
+
signMessage: ({ message }: {
|
10
|
+
message: string;
|
11
|
+
}) => Promise<Hash>;
|
12
|
+
signTransaction: (transaction: TransactionSerializable) => Promise<Hash>;
|
13
|
+
signTypedData: <TTypedData extends TypedData | {
|
14
|
+
[key: string]: unknown;
|
15
|
+
}, TPrimaryType extends string = string>(typedData: TypedDataDefinition<TTypedData, TPrimaryType>) => Promise<Hash>;
|
16
|
+
};
|
17
|
+
type JsonRpcAccount<TAddress extends Address = Address> = {
|
18
|
+
address: TAddress;
|
19
|
+
type: 'json-rpc';
|
20
|
+
};
|
21
|
+
type LocalAccount<TSource extends string = 'custom', TAddress extends Address = Address> = CustomSource & {
|
22
|
+
address: TAddress;
|
23
|
+
publicKey: Hex;
|
24
|
+
source: TSource;
|
25
|
+
type: 'local';
|
26
|
+
};
|
27
|
+
type HDAccount = LocalAccount<'hd'> & {
|
28
|
+
getHdKey(): HDKey;
|
29
|
+
};
|
30
|
+
type HDOptions = {
|
31
|
+
/** The account index to use in the path (`"m/44'/60'/${accountIndex}'/0/0"`). */
|
32
|
+
accountIndex?: number;
|
33
|
+
/** The address index to use in the path (`"m/44'/60'/0'/0/${addressIndex}"`). */
|
34
|
+
addressIndex?: number;
|
35
|
+
/** The change index to use in the path (`"m/44'/60'/0'/${changeIndex}/0"`). */
|
36
|
+
changeIndex?: number;
|
37
|
+
path?: never;
|
38
|
+
} | {
|
39
|
+
accountIndex?: never;
|
40
|
+
addressIndex?: never;
|
41
|
+
changeIndex?: never;
|
42
|
+
/** The HD path. */
|
43
|
+
path: `m/44'/60'/${string}`;
|
44
|
+
};
|
45
|
+
type PrivateKeyAccount = LocalAccount<'privateKey'>;
|
3
46
|
|
4
47
|
type TypedDataDefinition<TTypedData extends TypedData | {
|
5
48
|
[key: string]: unknown;
|
@@ -47,28 +90,4 @@ type GetTypedDataTypes<TTypedData extends TypedData | {
|
|
47
90
|
types: Narrow<TTypedData>;
|
48
91
|
};
|
49
92
|
|
50
|
-
|
51
|
-
type GetAccountParameter<TAccount extends Account | undefined = undefined> = TAccount extends undefined ? {
|
52
|
-
account: Account | Address;
|
53
|
-
} : {
|
54
|
-
account?: Account | Address;
|
55
|
-
};
|
56
|
-
type JsonRpcAccount = {
|
57
|
-
address: Address;
|
58
|
-
type: 'json-rpc';
|
59
|
-
};
|
60
|
-
type LocalAccount = {
|
61
|
-
address: Address;
|
62
|
-
signMessage: (message: string) => Promise<Hash>;
|
63
|
-
signTransaction: (transaction: Omit<TransactionRequest, 'from'> & {
|
64
|
-
chainId: number;
|
65
|
-
from: Address;
|
66
|
-
}) => Promise<Hash>;
|
67
|
-
signTypedData: <TTypedData extends TypedData | {
|
68
|
-
[key: string]: unknown;
|
69
|
-
}, TPrimaryType extends string = string>(typedData: TypedDataDefinition<TTypedData, TPrimaryType>) => Promise<Hash>;
|
70
|
-
type: 'local';
|
71
|
-
};
|
72
|
-
type ParseAccount<TAccount extends Account | Address | undefined> = (TAccount extends Account ? TAccount : never) | (TAccount extends Address ? JsonRpcAccount : never) | (TAccount extends undefined ? undefined : never);
|
73
|
-
|
74
|
-
export { Account as A, GetAccountParameter as G, JsonRpcAccount as J, LocalAccount as L, ParseAccount as P, TypedDataDefinition as T };
|
93
|
+
export { Account as A, CustomSource as C, HDAccount as H, JsonRpcAccount as J, LocalAccount as L, PrivateKeyAccount as P, TypedDataDefinition as T, AccountSource as a, HDOptions as b };
|
package/dist/utils/index.d.ts
CHANGED
@@ -1,21 +1,22 @@
|
|
1
|
-
import { Address } from 'abitype';
|
2
1
|
export { ParseAbi, ParseAbiItem, ParseAbiParameter, ParseAbiParameters, parseAbi, parseAbiItem, parseAbiParameter, parseAbiParameters } from 'abitype';
|
3
|
-
export { D as DecodeAbiParametersReturnType, E as EncodeAbiParametersReturnType, G as GetAbiItemParameters, d as decodeAbiParameters, e as encodeAbiParameters, g as getAbiItem } from '../getAbiItem-
|
4
|
-
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-
|
5
|
-
export { e as encodePacked } from '../encodePacked-
|
6
|
-
export { a as formatAbiItem, f as formatAbiItemWithArgs } from '../formatAbiItem-
|
7
|
-
|
8
|
-
|
9
|
-
export {
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
import {
|
2
|
+
export { D as DecodeAbiParametersReturnType, E as EncodeAbiParametersReturnType, G as GetAbiItemParameters, d as decodeAbiParameters, e as encodeAbiParameters, g as getAbiItem } from '../getAbiItem-1ff0f41a.js';
|
3
|
+
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-a252fba1.js';
|
4
|
+
export { e as encodePacked } from '../encodePacked-a9464e97.js';
|
5
|
+
export { a as formatAbiItem, f as formatAbiItemWithArgs } from '../formatAbiItem-6ed70dbd.js';
|
6
|
+
export { p as parseAccount } from '../parseAccount-8e131c73.js';
|
7
|
+
import { B as BaseError, C as CallExecutionError, E as EstimateGasExecutionError, d as ExecutionRevertedError, F as FeeCapTooHighError, e as FeeCapTooLowError, i as NonceTooHighError, j as NonceTooLowError, N as NonceMaxValueError, I as InsufficientFundsError, f as IntrinsicGasTooHighError, g as IntrinsicGasTooLowError, m as TransactionTypeNotSupportedError, T as TipAboveFeeCapError, U as UnknownNodeError, l as TransactionExecutionError } from '../parseGwei-5e2a8e87.js';
|
8
|
+
export { G as GetContractAddressOptions, p as GetCreate2AddressOptions, q as GetCreateAddressOptions, r as GetSerializedTransactionType, s as GetTransactionType, t as HashTypedDataParameters, u as HashTypedDataReturnType, H as HttpOptions, v as RecoverAddressParameters, w as RecoverAddressReturnType, x as RecoverMessageAddressParameters, y as RecoverMessageAddressReturnType, z as RecoverTypedDataAddressParameters, A as RecoverTypedDataAddressReturnType, R as RpcResponse, aW as Socket, D as ToRlpReturnType, V as VerifyMessageParameters, J as VerifyMessageReturnType, K as VerifyTypedDataParameters, L as VerifyTypedDataReturnType, 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, aX as getSocket, 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, aZ as recoverTypedDataAddress, aY as rpc, aI as serializeTransaction, aJ as size, aK as slice, aL as sliceBytes, aM as sliceHex, aN as stringToBytes, aO as stringToHex, aP as stringify, aQ as toBytes, aR as toHex, aS as toRlp, aT as trim, aU as validateTypedData, aV as verifyMessage, a_ as verifyTypedData } from '../parseGwei-5e2a8e87.js';
|
9
|
+
export { d as defineChain, g as getChainContractAddress } from '../chain-40443542.js';
|
10
|
+
import { C as CallParameters, E as EstimateGasParameters, S as SendTransactionParameters } from '../createPublicClient-fd8b1349.js';
|
11
|
+
export { B as BlockFormatter, F as FormattedBlock, f as FormattedTransactionReceipt, g as FormattedTransactionRequest, T as TransactionReceiptFormatter, h as TransactionRequestFormatter, i as defineBlock, j as defineTransactionReceipt, k as defineTransactionRequest, l as formatBlock, m as formatTransactionRequest } from '../createPublicClient-fd8b1349.js';
|
12
|
+
import { ac as Formatter, C as Chain } from '../chain-4af995bf.js';
|
13
|
+
export { a4 as ExtractFormatter, a5 as Formatted, a6 as FormattedTransaction, a7 as TransactionFormatter, ao as defineFormatter, a8 as defineTransaction, ap as format, a9 as formatTransaction, aa as transactionType } from '../chain-4af995bf.js';
|
14
|
+
import { A as Account } from '../typedData-848139b1.js';
|
16
15
|
import 'isomorphic-ws';
|
17
|
-
import '../
|
16
|
+
import '../createClient-1f19be8d.js';
|
17
|
+
import '../eip1193-210ab776.js';
|
18
18
|
import '@wagmi/chains';
|
19
|
+
import '@scure/bip32';
|
19
20
|
|
20
21
|
declare function buildRequest<TRequest extends (args: any) => Promise<any>>(request: TRequest, { retryDelay, retryCount, }?: {
|
21
22
|
retryDelay?: number;
|
@@ -66,23 +67,4 @@ declare const arrayRegex: RegExp;
|
|
66
67
|
declare const bytesRegex: RegExp;
|
67
68
|
declare const integerRegex: RegExp;
|
68
69
|
|
69
|
-
|
70
|
-
|
71
|
-
type PrepareRequestParameters<TAccount extends Account | undefined = undefined> = GetAccountParameter<TAccount> & {
|
72
|
-
gas?: SendTransactionParameters['gas'];
|
73
|
-
gasPrice?: SendTransactionParameters['gasPrice'];
|
74
|
-
maxFeePerGas?: SendTransactionParameters['maxFeePerGas'];
|
75
|
-
maxPriorityFeePerGas?: SendTransactionParameters['maxPriorityFeePerGas'];
|
76
|
-
nonce?: SendTransactionParameters['nonce'];
|
77
|
-
};
|
78
|
-
type PrepareRequestReturnType<TAccount extends Account | undefined = undefined, TParameters extends PrepareRequestParameters<TAccount> = PrepareRequestParameters<TAccount>> = TParameters & {
|
79
|
-
from: Address;
|
80
|
-
gas: SendTransactionParameters['gas'];
|
81
|
-
gasPrice?: SendTransactionParameters['gasPrice'];
|
82
|
-
maxFeePerGas?: SendTransactionParameters['maxFeePerGas'];
|
83
|
-
maxPriorityFeePerGas?: SendTransactionParameters['maxPriorityFeePerGas'];
|
84
|
-
nonce: SendTransactionParameters['nonce'];
|
85
|
-
};
|
86
|
-
declare function prepareRequest<TAccount extends Account | undefined, TParameters extends PrepareRequestParameters<TAccount>, TChain extends Chain | undefined>(client: WalletClientArg<Transport, TChain, TAccount> | PublicClientArg<Transport, TChain>, args: TParameters): Promise<PrepareRequestReturnType<TAccount, TParameters>>;
|
87
|
-
|
88
|
-
export { arrayRegex, assertRequest, buildRequest, bytesRegex, containsNodeError, extract, extractFunctionName, extractFunctionParams, extractFunctionParts, extractFunctionType, getCallError, getEstimateGasError, getNodeError, getTransactionError, integerRegex, prepareRequest };
|
70
|
+
export { arrayRegex, buildRequest, bytesRegex, containsNodeError, extract, extractFunctionName, extractFunctionParams, extractFunctionParts, extractFunctionType, getCallError, getEstimateGasError, getNodeError, getTransactionError, integerRegex };
|
package/dist/utils/index.js
CHANGED
@@ -109,7 +109,6 @@
|
|
109
109
|
|
110
110
|
|
111
111
|
|
112
|
-
var _chunkT4AH4Y6Yjs = require('../chunk-T4AH4Y6Y.js');
|
113
112
|
|
114
113
|
|
115
114
|
|
@@ -118,6 +117,7 @@ var _chunkT4AH4Y6Yjs = require('../chunk-T4AH4Y6Y.js');
|
|
118
117
|
|
119
118
|
|
120
119
|
|
120
|
+
var _chunkOW7TKT7Ljs = require('../chunk-OW7TKT7L.js');
|
121
121
|
|
122
122
|
|
123
123
|
|
@@ -221,5 +221,21 @@ var _chunkT4AH4Y6Yjs = require('../chunk-T4AH4Y6Y.js');
|
|
221
221
|
|
222
222
|
|
223
223
|
|
224
|
-
|
224
|
+
|
225
|
+
|
226
|
+
|
227
|
+
|
228
|
+
|
229
|
+
|
230
|
+
|
231
|
+
|
232
|
+
|
233
|
+
|
234
|
+
|
235
|
+
|
236
|
+
|
237
|
+
|
238
|
+
|
239
|
+
|
240
|
+
exports.arrayRegex = _chunkOW7TKT7Ljs.arrayRegex; exports.assertRequest = _chunkOW7TKT7Ljs.assertRequest; exports.assertTransactionEIP1559 = _chunkOW7TKT7Ljs.assertTransactionEIP1559; exports.assertTransactionEIP2930 = _chunkOW7TKT7Ljs.assertTransactionEIP2930; exports.assertTransactionLegacy = _chunkOW7TKT7Ljs.assertTransactionLegacy; exports.boolToBytes = _chunkOW7TKT7Ljs.boolToBytes; exports.boolToHex = _chunkOW7TKT7Ljs.boolToHex; exports.buildRequest = _chunkOW7TKT7Ljs.buildRequest; exports.bytesRegex = _chunkOW7TKT7Ljs.bytesRegex; exports.bytesToBigint = _chunkOW7TKT7Ljs.bytesToBigint; exports.bytesToBool = _chunkOW7TKT7Ljs.bytesToBool; exports.bytesToHex = _chunkOW7TKT7Ljs.bytesToHex; exports.bytesToNumber = _chunkOW7TKT7Ljs.bytesToNumber; exports.bytesToString = _chunkOW7TKT7Ljs.bytesToString; exports.concat = _chunkOW7TKT7Ljs.concat; exports.concatBytes = _chunkOW7TKT7Ljs.concatBytes; exports.concatHex = _chunkOW7TKT7Ljs.concatHex; exports.containsNodeError = _chunkOW7TKT7Ljs.containsNodeError; exports.decodeAbiParameters = _chunkOW7TKT7Ljs.decodeAbiParameters; exports.decodeErrorResult = _chunkOW7TKT7Ljs.decodeErrorResult; exports.decodeEventLog = _chunkOW7TKT7Ljs.decodeEventLog; exports.decodeFunctionData = _chunkOW7TKT7Ljs.decodeFunctionData; exports.decodeFunctionResult = _chunkOW7TKT7Ljs.decodeFunctionResult; exports.defineBlock = _chunkOW7TKT7Ljs.defineBlock; exports.defineChain = _chunkOW7TKT7Ljs.defineChain; exports.defineFormatter = _chunkOW7TKT7Ljs.defineFormatter; exports.defineTransaction = _chunkOW7TKT7Ljs.defineTransaction; exports.defineTransactionReceipt = _chunkOW7TKT7Ljs.defineTransactionReceipt; exports.defineTransactionRequest = _chunkOW7TKT7Ljs.defineTransactionRequest; exports.encodeAbiParameters = _chunkOW7TKT7Ljs.encodeAbiParameters; exports.encodeDeployData = _chunkOW7TKT7Ljs.encodeDeployData; exports.encodeErrorResult = _chunkOW7TKT7Ljs.encodeErrorResult; exports.encodeEventTopics = _chunkOW7TKT7Ljs.encodeEventTopics; exports.encodeFunctionData = _chunkOW7TKT7Ljs.encodeFunctionData; exports.encodeFunctionResult = _chunkOW7TKT7Ljs.encodeFunctionResult; exports.encodePacked = _chunkOW7TKT7Ljs.encodePacked; exports.extract = _chunkOW7TKT7Ljs.extract; exports.extractFunctionName = _chunkOW7TKT7Ljs.extractFunctionName; exports.extractFunctionParams = _chunkOW7TKT7Ljs.extractFunctionParams; exports.extractFunctionParts = _chunkOW7TKT7Ljs.extractFunctionParts; exports.extractFunctionType = _chunkOW7TKT7Ljs.extractFunctionType; exports.format = _chunkOW7TKT7Ljs.format; exports.formatAbiItem = _chunkOW7TKT7Ljs.formatAbiItem; exports.formatAbiItemWithArgs = _chunkOW7TKT7Ljs.formatAbiItemWithArgs; exports.formatBlock = _chunkOW7TKT7Ljs.formatBlock; exports.formatEther = _chunkOW7TKT7Ljs.formatEther; exports.formatGwei = _chunkOW7TKT7Ljs.formatGwei; exports.formatTransaction = _chunkOW7TKT7Ljs.formatTransaction; exports.formatTransactionRequest = _chunkOW7TKT7Ljs.formatTransactionRequest; exports.formatUnits = _chunkOW7TKT7Ljs.formatUnits; exports.fromBytes = _chunkOW7TKT7Ljs.fromBytes; exports.fromHex = _chunkOW7TKT7Ljs.fromHex; exports.fromRlp = _chunkOW7TKT7Ljs.fromRlp; exports.getAbiItem = _chunkOW7TKT7Ljs.getAbiItem; exports.getAddress = _chunkOW7TKT7Ljs.getAddress; exports.getCallError = _chunkOW7TKT7Ljs.getCallError; exports.getChainContractAddress = _chunkOW7TKT7Ljs.getChainContractAddress; exports.getContractAddress = _chunkOW7TKT7Ljs.getContractAddress; exports.getContractError = _chunkOW7TKT7Ljs.getContractError; exports.getCreate2Address = _chunkOW7TKT7Ljs.getCreate2Address; exports.getCreateAddress = _chunkOW7TKT7Ljs.getCreateAddress; exports.getEstimateGasError = _chunkOW7TKT7Ljs.getEstimateGasError; exports.getEventSelector = _chunkOW7TKT7Ljs.getEventSelector; exports.getFunctionSelector = _chunkOW7TKT7Ljs.getFunctionSelector; exports.getNodeError = _chunkOW7TKT7Ljs.getNodeError; exports.getSerializedTransactionType = _chunkOW7TKT7Ljs.getSerializedTransactionType; exports.getSocket = _chunkOW7TKT7Ljs.getSocket; exports.getTransactionError = _chunkOW7TKT7Ljs.getTransactionError; exports.getTransactionType = _chunkOW7TKT7Ljs.getTransactionType; exports.hashMessage = _chunkOW7TKT7Ljs.hashMessage; exports.hashTypedData = _chunkOW7TKT7Ljs.hashTypedData; exports.hexToBigInt = _chunkOW7TKT7Ljs.hexToBigInt; exports.hexToBool = _chunkOW7TKT7Ljs.hexToBool; exports.hexToBytes = _chunkOW7TKT7Ljs.hexToBytes; exports.hexToNumber = _chunkOW7TKT7Ljs.hexToNumber; exports.hexToString = _chunkOW7TKT7Ljs.hexToString; exports.integerRegex = _chunkOW7TKT7Ljs.integerRegex; exports.isAddress = _chunkOW7TKT7Ljs.isAddress; exports.isAddressEqual = _chunkOW7TKT7Ljs.isAddressEqual; exports.isBytes = _chunkOW7TKT7Ljs.isBytes; exports.isHash = _chunkOW7TKT7Ljs.isHash; exports.isHex = _chunkOW7TKT7Ljs.isHex; exports.keccak256 = _chunkOW7TKT7Ljs.keccak256; exports.numberToBytes = _chunkOW7TKT7Ljs.numberToBytes; exports.numberToHex = _chunkOW7TKT7Ljs.numberToHex; exports.pad = _chunkOW7TKT7Ljs.pad; exports.padBytes = _chunkOW7TKT7Ljs.padBytes; exports.padHex = _chunkOW7TKT7Ljs.padHex; exports.parseAbi = _chunkOW7TKT7Ljs.parseAbi; exports.parseAbiItem = _chunkOW7TKT7Ljs.parseAbiItem; exports.parseAbiParameter = _chunkOW7TKT7Ljs.parseAbiParameter; exports.parseAbiParameters = _chunkOW7TKT7Ljs.parseAbiParameters; exports.parseAccount = _chunkOW7TKT7Ljs.parseAccount; exports.parseEther = _chunkOW7TKT7Ljs.parseEther; exports.parseGwei = _chunkOW7TKT7Ljs.parseGwei; exports.parseTransaction = _chunkOW7TKT7Ljs.parseTransaction; exports.parseUnits = _chunkOW7TKT7Ljs.parseUnits; exports.prepareRequest = _chunkOW7TKT7Ljs.prepareRequest; exports.recoverAddress = _chunkOW7TKT7Ljs.recoverAddress; exports.recoverMessageAddress = _chunkOW7TKT7Ljs.recoverMessageAddress; exports.recoverTypedDataAddress = _chunkOW7TKT7Ljs.recoverTypedDataAddress; exports.rpc = _chunkOW7TKT7Ljs.rpc; exports.serializeTransaction = _chunkOW7TKT7Ljs.serializeTransaction; exports.size = _chunkOW7TKT7Ljs.size; exports.slice = _chunkOW7TKT7Ljs.slice; exports.sliceBytes = _chunkOW7TKT7Ljs.sliceBytes; exports.sliceHex = _chunkOW7TKT7Ljs.sliceHex; exports.stringToBytes = _chunkOW7TKT7Ljs.stringToBytes; exports.stringToHex = _chunkOW7TKT7Ljs.stringToHex; exports.stringify = _chunkOW7TKT7Ljs.stringify; exports.toBytes = _chunkOW7TKT7Ljs.toBytes; exports.toHex = _chunkOW7TKT7Ljs.toHex; exports.toRlp = _chunkOW7TKT7Ljs.toRlp; exports.transactionType = _chunkOW7TKT7Ljs.transactionType; exports.trim = _chunkOW7TKT7Ljs.trim; exports.validateTypedData = _chunkOW7TKT7Ljs.validateTypedData; exports.verifyMessage = _chunkOW7TKT7Ljs.verifyMessage; exports.verifyTypedData = _chunkOW7TKT7Ljs.verifyTypedData;
|
225
241
|
//# sourceMappingURL=index.js.map
|
package/dist/utils/index.mjs
CHANGED
@@ -1,6 +1,9 @@
|
|
1
1
|
import {
|
2
2
|
arrayRegex,
|
3
3
|
assertRequest,
|
4
|
+
assertTransactionEIP1559,
|
5
|
+
assertTransactionEIP2930,
|
6
|
+
assertTransactionLegacy,
|
4
7
|
boolToBytes,
|
5
8
|
boolToHex,
|
6
9
|
buildRequest,
|
@@ -50,7 +53,6 @@ import {
|
|
50
53
|
fromHex,
|
51
54
|
fromRlp,
|
52
55
|
getAbiItem,
|
53
|
-
getAccount,
|
54
56
|
getAddress,
|
55
57
|
getCallError,
|
56
58
|
getChainContractAddress,
|
@@ -62,8 +64,10 @@ import {
|
|
62
64
|
getEventSelector,
|
63
65
|
getFunctionSelector,
|
64
66
|
getNodeError,
|
67
|
+
getSerializedTransactionType,
|
65
68
|
getSocket,
|
66
69
|
getTransactionError,
|
70
|
+
getTransactionType,
|
67
71
|
hashMessage,
|
68
72
|
hashTypedData,
|
69
73
|
hexToBigInt,
|
@@ -75,6 +79,7 @@ import {
|
|
75
79
|
isAddress,
|
76
80
|
isAddressEqual,
|
77
81
|
isBytes,
|
82
|
+
isHash,
|
78
83
|
isHex,
|
79
84
|
keccak256,
|
80
85
|
numberToBytes,
|
@@ -89,12 +94,14 @@ import {
|
|
89
94
|
parseAccount,
|
90
95
|
parseEther,
|
91
96
|
parseGwei,
|
97
|
+
parseTransaction,
|
92
98
|
parseUnits,
|
93
99
|
prepareRequest,
|
94
100
|
recoverAddress,
|
95
101
|
recoverMessageAddress,
|
96
102
|
recoverTypedDataAddress,
|
97
103
|
rpc,
|
104
|
+
serializeTransaction,
|
98
105
|
size,
|
99
106
|
slice,
|
100
107
|
sliceBytes,
|
@@ -107,12 +114,16 @@ import {
|
|
107
114
|
toRlp,
|
108
115
|
transactionType,
|
109
116
|
trim,
|
117
|
+
validateTypedData,
|
110
118
|
verifyMessage,
|
111
119
|
verifyTypedData
|
112
|
-
} from "../chunk-
|
120
|
+
} from "../chunk-HYEOQX7O.mjs";
|
113
121
|
export {
|
114
122
|
arrayRegex,
|
115
123
|
assertRequest,
|
124
|
+
assertTransactionEIP1559,
|
125
|
+
assertTransactionEIP2930,
|
126
|
+
assertTransactionLegacy,
|
116
127
|
boolToBytes,
|
117
128
|
boolToHex,
|
118
129
|
buildRequest,
|
@@ -162,7 +173,6 @@ export {
|
|
162
173
|
fromHex,
|
163
174
|
fromRlp,
|
164
175
|
getAbiItem,
|
165
|
-
getAccount,
|
166
176
|
getAddress,
|
167
177
|
getCallError,
|
168
178
|
getChainContractAddress,
|
@@ -174,8 +184,10 @@ export {
|
|
174
184
|
getEventSelector,
|
175
185
|
getFunctionSelector,
|
176
186
|
getNodeError,
|
187
|
+
getSerializedTransactionType,
|
177
188
|
getSocket,
|
178
189
|
getTransactionError,
|
190
|
+
getTransactionType,
|
179
191
|
hashMessage,
|
180
192
|
hashTypedData,
|
181
193
|
hexToBigInt,
|
@@ -187,6 +199,7 @@ export {
|
|
187
199
|
isAddress,
|
188
200
|
isAddressEqual,
|
189
201
|
isBytes,
|
202
|
+
isHash,
|
190
203
|
isHex,
|
191
204
|
keccak256,
|
192
205
|
numberToBytes,
|
@@ -201,12 +214,14 @@ export {
|
|
201
214
|
parseAccount,
|
202
215
|
parseEther,
|
203
216
|
parseGwei,
|
217
|
+
parseTransaction,
|
204
218
|
parseUnits,
|
205
219
|
prepareRequest,
|
206
220
|
recoverAddress,
|
207
221
|
recoverMessageAddress,
|
208
222
|
recoverTypedDataAddress,
|
209
223
|
rpc,
|
224
|
+
serializeTransaction,
|
210
225
|
size,
|
211
226
|
slice,
|
212
227
|
sliceBytes,
|
@@ -219,6 +234,7 @@ export {
|
|
219
234
|
toRlp,
|
220
235
|
transactionType,
|
221
236
|
trim,
|
237
|
+
validateTypedData,
|
222
238
|
verifyMessage,
|
223
239
|
verifyTypedData
|
224
240
|
};
|
package/dist/wallet.d.ts
CHANGED
@@ -1,7 +1,8 @@
|
|
1
|
-
export {
|
2
|
-
import './eip1193-
|
1
|
+
export { bk as AddChainParameters, bl as FormattedTransactionRequest, bn as GetAddressesReturnType, bm as GetPermissionsReturnType, bo as RequestAddressesReturnType, bp as RequestPermissionsReturnType, S as SendTransactionParameters, bq as SendTransactionReturnType, br as SignMessageParameters, bs as SignMessageReturnType, bt as SignTypedDataParameters, bu as SignTypedDataReturnType, bv as SwitchChainParameters, bw as WatchAssetParameters, bx as WatchAssetReturnType, ba as addChain, bb as getAddresses, bc as getPermissions, bd as requestAddresses, be as requestPermissions, bf as sendTransaction, bg as signMessage, bh as signTypedData, bi as switchChain, bj as watchAsset } from './createPublicClient-fd8b1349.js';
|
2
|
+
import './eip1193-210ab776.js';
|
3
3
|
import 'abitype';
|
4
|
-
import './chain-
|
4
|
+
import './chain-4af995bf.js';
|
5
5
|
import '@wagmi/chains';
|
6
|
-
import './createClient-
|
7
|
-
import './
|
6
|
+
import './createClient-1f19be8d.js';
|
7
|
+
import './typedData-848139b1.js';
|
8
|
+
import '@scure/bip32';
|
package/dist/wallet.js
CHANGED
@@ -9,7 +9,7 @@
|
|
9
9
|
|
10
10
|
|
11
11
|
|
12
|
-
var
|
12
|
+
var _chunkOW7TKT7Ljs = require('./chunk-OW7TKT7L.js');
|
13
13
|
|
14
14
|
|
15
15
|
|
@@ -21,5 +21,5 @@ var _chunkT4AH4Y6Yjs = require('./chunk-T4AH4Y6Y.js');
|
|
21
21
|
|
22
22
|
|
23
23
|
|
24
|
-
exports.addChain =
|
24
|
+
exports.addChain = _chunkOW7TKT7Ljs.addChain; exports.getAddresses = _chunkOW7TKT7Ljs.getAddresses; exports.getPermissions = _chunkOW7TKT7Ljs.getPermissions; exports.requestAddresses = _chunkOW7TKT7Ljs.requestAddresses; exports.requestPermissions = _chunkOW7TKT7Ljs.requestPermissions; exports.sendTransaction = _chunkOW7TKT7Ljs.sendTransaction; exports.signMessage = _chunkOW7TKT7Ljs.signMessage; exports.signTypedData = _chunkOW7TKT7Ljs.signTypedData; exports.switchChain = _chunkOW7TKT7Ljs.switchChain; exports.watchAsset = _chunkOW7TKT7Ljs.watchAsset;
|
25
25
|
//# sourceMappingURL=wallet.js.map
|