essential-eth 0.9.2-beta.2 → 0.9.2-beta.4
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/cjs/classes/Contract.d.ts +81 -11
- package/dist/cjs/classes/test/Contract/crv-abi.d.ts +2 -2
- package/dist/cjs/classes/test/Contract/ens-abi.d.ts +2 -2
- package/dist/cjs/classes/test/Contract/fei-abi.d.ts +2 -2
- package/dist/cjs/classes/test/Contract/foo-abi.d.ts +2 -2
- package/dist/cjs/classes/test/Contract/uniswap-abi.d.ts +2 -2
- package/dist/cjs/classes/utils/clean-block.d.ts +120 -2
- package/dist/cjs/classes/utils/clean-log.d.ts +9 -2
- package/dist/cjs/classes/utils/clean-transaction-receipt.d.ts +14 -2
- package/dist/cjs/classes/utils/clean-transaction.d.ts +14 -2
- package/dist/cjs/classes/utils/encode-decode-transaction.d.ts +16 -4
- package/dist/cjs/classes/utils/fetchers.d.ts +53 -15
- package/dist/cjs/classes/utils/hex-to-decimal.d.ts +18 -1
- package/dist/cjs/classes/utils/prepare-transaction.d.ts +6 -2
- package/dist/cjs/index.d.ts +24 -25
- package/dist/cjs/index.js +21 -19
- package/dist/cjs/logger/logger.d.ts +11 -11
- package/dist/cjs/logger/package-version.d.ts +1 -1
- package/dist/cjs/logger/package-version.js +1 -1
- package/dist/cjs/providers/AlchemyProvider.d.ts +4 -4
- package/dist/cjs/providers/BaseProvider.d.ts +374 -26
- package/dist/cjs/providers/FallthroughProvider.d.ts +24 -11
- package/dist/cjs/providers/JsonRpcProvider.d.ts +33 -7
- package/dist/cjs/providers/test/json-rpc-provider/get-logs/mocks.d.ts +14 -14
- package/dist/cjs/providers/test/mock-of.d.ts +9 -2
- package/dist/cjs/providers/test/rpc-urls.d.ts +12 -12
- package/dist/cjs/providers/utils/chains-info.d.ts +24 -24
- package/dist/cjs/shared/tiny-big/helpers.d.ts +17 -1
- package/dist/cjs/shared/tiny-big/tiny-big.d.ts +58 -10
- package/dist/cjs/shared/validate-type.d.ts +3 -3
- package/dist/cjs/types/Block.types.d.ts +41 -40
- package/dist/cjs/types/Contract.types.d.ts +24 -24
- package/dist/cjs/types/FeeData.types.d.ts +7 -7
- package/dist/cjs/types/Filter.types.d.ts +16 -12
- package/dist/cjs/types/Network.types.d.ts +8 -5
- package/dist/cjs/types/Transaction.types.d.ts +123 -113
- package/dist/cjs/utils/bytes.d.ts +289 -40
- package/dist/cjs/utils/compute-address.d.ts +17 -1
- package/dist/cjs/utils/compute-public-key.d.ts +18 -2
- package/dist/cjs/utils/ether-to-gwei.d.ts +27 -3
- package/dist/cjs/utils/ether-to-wei.d.ts +27 -3
- package/dist/cjs/utils/gwei-to-ether.d.ts +27 -3
- package/dist/cjs/utils/hash-message.d.ts +14 -2
- package/dist/cjs/utils/is-address.d.ts +24 -1
- package/dist/cjs/utils/keccak256.d.ts +16 -2
- package/dist/cjs/utils/solidity-keccak256.d.ts +39 -2
- package/dist/cjs/utils/split-signature.d.ts +24 -2
- package/dist/cjs/utils/to-checksum-address.d.ts +17 -1
- package/dist/cjs/utils/to-utf8-bytes.d.ts +15 -1
- package/dist/cjs/utils/wei-to-ether.d.ts +27 -3
- package/dist/esm/classes/Contract.d.ts +11 -11
- package/dist/esm/classes/test/Contract/crv-abi.d.ts +2 -2
- package/dist/esm/classes/test/Contract/ens-abi.d.ts +2 -2
- package/dist/esm/classes/test/Contract/fei-abi.d.ts +2 -2
- package/dist/esm/classes/test/Contract/foo-abi.d.ts +2 -2
- package/dist/esm/classes/test/Contract/uniswap-abi.d.ts +2 -2
- package/dist/esm/classes/utils/clean-block.d.ts +2 -2
- package/dist/esm/classes/utils/clean-log.d.ts +2 -2
- package/dist/esm/classes/utils/clean-transaction-receipt.d.ts +2 -2
- package/dist/esm/classes/utils/clean-transaction.d.ts +2 -2
- package/dist/esm/classes/utils/encode-decode-transaction.d.ts +4 -4
- package/dist/esm/classes/utils/fetchers.d.ts +15 -15
- package/dist/esm/classes/utils/hex-to-decimal.d.ts +1 -1
- package/dist/esm/classes/utils/prepare-transaction.d.ts +2 -2
- package/dist/esm/index.d.ts +24 -25
- package/dist/esm/index.js +3 -4
- package/dist/esm/logger/logger.d.ts +11 -11
- package/dist/esm/logger/package-version.d.ts +1 -1
- package/dist/esm/logger/package-version.js +1 -1
- package/dist/esm/providers/AlchemyProvider.d.ts +4 -4
- package/dist/esm/providers/BaseProvider.d.ts +26 -26
- package/dist/esm/providers/FallthroughProvider.d.ts +11 -11
- package/dist/esm/providers/JsonRpcProvider.d.ts +7 -7
- package/dist/esm/providers/test/json-rpc-provider/get-logs/mocks.d.ts +14 -14
- package/dist/esm/providers/test/mock-of.d.ts +2 -2
- package/dist/esm/providers/test/rpc-urls.d.ts +12 -12
- package/dist/esm/providers/utils/chains-info.d.ts +24 -24
- package/dist/esm/shared/tiny-big/helpers.d.ts +1 -1
- package/dist/esm/shared/tiny-big/tiny-big.d.ts +10 -10
- package/dist/esm/shared/validate-type.d.ts +3 -3
- package/dist/esm/types/Block.types.d.ts +40 -40
- package/dist/esm/types/Contract.types.d.ts +24 -24
- package/dist/esm/types/FeeData.types.d.ts +7 -7
- package/dist/esm/types/Filter.types.d.ts +12 -12
- package/dist/esm/types/Network.types.d.ts +5 -5
- package/dist/esm/types/Transaction.types.d.ts +113 -113
- package/dist/esm/utils/bytes.d.ts +40 -40
- package/dist/esm/utils/compute-address.d.ts +1 -1
- package/dist/esm/utils/compute-public-key.d.ts +2 -2
- package/dist/esm/utils/ether-to-gwei.d.ts +3 -3
- package/dist/esm/utils/ether-to-wei.d.ts +3 -3
- package/dist/esm/utils/gwei-to-ether.d.ts +3 -3
- package/dist/esm/utils/hash-message.d.ts +2 -2
- package/dist/esm/utils/is-address.d.ts +1 -1
- package/dist/esm/utils/keccak256.d.ts +2 -2
- package/dist/esm/utils/solidity-keccak256.d.ts +2 -2
- package/dist/esm/utils/split-signature.d.ts +2 -2
- package/dist/esm/utils/to-checksum-address.d.ts +1 -1
- package/dist/esm/utils/to-utf8-bytes.d.ts +1 -1
- package/dist/esm/utils/wei-to-ether.d.ts +3 -3
- package/dist/{cjs/index.umd.js → essential-eth.umd.js} +2 -2
- package/dist/essential-eth.umd.js.map +1 -0
- package/package.json +8 -9
- package/readme.md +1 -1
- package/dist/cjs/index.umd.js.map +0 -1
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import type { TinyBig } from '../shared/tiny-big/tiny-big';
|
|
2
|
-
export interface FeeData {
|
|
3
|
-
gasPrice: TinyBig;
|
|
4
|
-
lastBaseFeePerGas: TinyBig | null;
|
|
5
|
-
maxFeePerGas: TinyBig | null;
|
|
6
|
-
maxPriorityFeePerGas: TinyBig | null;
|
|
7
|
-
}
|
|
1
|
+
import type { TinyBig } from '../shared/tiny-big/tiny-big';
|
|
2
|
+
export interface FeeData {
|
|
3
|
+
gasPrice: TinyBig;
|
|
4
|
+
lastBaseFeePerGas: TinyBig | null;
|
|
5
|
+
maxFeePerGas: TinyBig | null;
|
|
6
|
+
maxPriorityFeePerGas: TinyBig | null;
|
|
7
|
+
}
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import type { BlockTag } from './Block.types';
|
|
2
|
-
export interface EventFilter {
|
|
3
|
-
address?: string;
|
|
4
|
-
topics?: Array<string | Array<string> | null>;
|
|
5
|
-
}
|
|
6
|
-
export interface Filter extends EventFilter {
|
|
7
|
-
fromBlock?: BlockTag;
|
|
8
|
-
toBlock?: BlockTag;
|
|
9
|
-
}
|
|
10
|
-
export interface FilterByBlockHash extends EventFilter {
|
|
11
|
-
blockHash?: string;
|
|
12
|
-
}
|
|
1
|
+
import type { BlockTag } from './Block.types';
|
|
2
|
+
export interface EventFilter {
|
|
3
|
+
address?: string;
|
|
4
|
+
topics?: Array<string | Array<string> | null>;
|
|
5
|
+
}
|
|
6
|
+
export interface Filter extends EventFilter {
|
|
7
|
+
fromBlock?: BlockTag;
|
|
8
|
+
toBlock?: BlockTag;
|
|
9
|
+
}
|
|
10
|
+
export interface FilterByBlockHash extends EventFilter {
|
|
11
|
+
blockHash?: string;
|
|
12
|
+
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
export interface Network {
|
|
2
|
-
chainId: number;
|
|
3
|
-
ensAddress: string | null;
|
|
4
|
-
name: string;
|
|
5
|
-
}
|
|
1
|
+
export interface Network {
|
|
2
|
+
chainId: number;
|
|
3
|
+
ensAddress: string | null;
|
|
4
|
+
name: string;
|
|
5
|
+
}
|
|
@@ -1,113 +1,113 @@
|
|
|
1
|
-
import type Big from 'big.js';
|
|
2
|
-
import type { TinyBig } from '../shared/tiny-big/tiny-big';
|
|
3
|
-
import type { BytesLike } from './../utils/bytes';
|
|
4
|
-
type Modify<T, R> = Omit<T, keyof R> & R;
|
|
5
|
-
export interface RPCTransaction extends RPCBlockTransaction {
|
|
6
|
-
maxFeePerGas: string;
|
|
7
|
-
maxPriorityFeePerGas: string;
|
|
8
|
-
}
|
|
9
|
-
export type TransactionResponse = Modify<RPCTransaction, {
|
|
10
|
-
blockNumber: number;
|
|
11
|
-
chainId: number;
|
|
12
|
-
gas: TinyBig;
|
|
13
|
-
gasLimit: TinyBig;
|
|
14
|
-
gasPrice: TinyBig;
|
|
15
|
-
nonce: TinyBig;
|
|
16
|
-
transactionIndex: number;
|
|
17
|
-
type: number;
|
|
18
|
-
v: number;
|
|
19
|
-
value: TinyBig;
|
|
20
|
-
} & {
|
|
21
|
-
maxFeePerGas: TinyBig;
|
|
22
|
-
maxPriorityFeePerGas: TinyBig;
|
|
23
|
-
confirmations: number;
|
|
24
|
-
}>;
|
|
25
|
-
export type TransactionReceipt = Modify<RPCTransactionReceipt, {
|
|
26
|
-
blockNumber: number;
|
|
27
|
-
cumulativeGasUsed: TinyBig;
|
|
28
|
-
effectiveGasPrice: TinyBig;
|
|
29
|
-
gasUsed: TinyBig;
|
|
30
|
-
logs: Array<Log>;
|
|
31
|
-
status: number;
|
|
32
|
-
transactionIndex: number;
|
|
33
|
-
type: number;
|
|
34
|
-
} & {
|
|
35
|
-
byzantium: boolean;
|
|
36
|
-
confirmations: number;
|
|
37
|
-
}>;
|
|
38
|
-
export interface RPCTransactionRequest {
|
|
39
|
-
from?: string;
|
|
40
|
-
to: string;
|
|
41
|
-
gas?: string;
|
|
42
|
-
gasPrice?: string;
|
|
43
|
-
value?: string;
|
|
44
|
-
data?: BytesLike;
|
|
45
|
-
nonce?: string;
|
|
46
|
-
maxPriorityFeePerGas?: string;
|
|
47
|
-
maxFeePerGas?: string;
|
|
48
|
-
}
|
|
49
|
-
export interface TransactionRequest {
|
|
50
|
-
to?: string;
|
|
51
|
-
from?: string;
|
|
52
|
-
nonce?: TinyBig | string | Big | number;
|
|
53
|
-
gas?: TinyBig | number | Big | string;
|
|
54
|
-
gasPrice?: TinyBig | Big | string | number;
|
|
55
|
-
data?: BytesLike;
|
|
56
|
-
value?: TinyBig | string | Big | number;
|
|
57
|
-
chainId?: number;
|
|
58
|
-
type?: number;
|
|
59
|
-
maxPriorityFeePerGas?: TinyBig | string | Big | number;
|
|
60
|
-
maxFeePerGas?: TinyBig | string | Big | number;
|
|
61
|
-
}
|
|
62
|
-
export type Log = Modify<RPCLog, {
|
|
63
|
-
blockNumber: number;
|
|
64
|
-
logIndex: number;
|
|
65
|
-
transactionIndex: number;
|
|
66
|
-
}>;
|
|
67
|
-
export type BlockTransactionResponse = Omit<TransactionResponse, 'maxFeePerGas' | 'maxPriorityFeePerGas'>;
|
|
68
|
-
export interface RPCBlockTransaction {
|
|
69
|
-
blockHash: string;
|
|
70
|
-
blockNumber: string;
|
|
71
|
-
chainId: string;
|
|
72
|
-
from: string;
|
|
73
|
-
gas: string;
|
|
74
|
-
gasPrice: string;
|
|
75
|
-
hash: string;
|
|
76
|
-
input: string;
|
|
77
|
-
nonce: string;
|
|
78
|
-
r: string;
|
|
79
|
-
s: string;
|
|
80
|
-
to: string;
|
|
81
|
-
transactionIndex: string;
|
|
82
|
-
type: string;
|
|
83
|
-
v: string;
|
|
84
|
-
value: string;
|
|
85
|
-
}
|
|
86
|
-
export interface RPCTransactionReceipt {
|
|
87
|
-
blockHash: string;
|
|
88
|
-
blockNumber: string;
|
|
89
|
-
contractAddress: string;
|
|
90
|
-
cumulativeGasUsed: string;
|
|
91
|
-
effectiveGasPrice: string;
|
|
92
|
-
from: string;
|
|
93
|
-
gasUsed: string;
|
|
94
|
-
logs: Array<RPCLog>;
|
|
95
|
-
logsBloom: string;
|
|
96
|
-
status: string;
|
|
97
|
-
to: string;
|
|
98
|
-
transactionHash: string;
|
|
99
|
-
transactionIndex: string;
|
|
100
|
-
type: string;
|
|
101
|
-
}
|
|
102
|
-
export interface RPCLog {
|
|
103
|
-
address: string;
|
|
104
|
-
blockHash: string;
|
|
105
|
-
blockNumber: string;
|
|
106
|
-
data: string;
|
|
107
|
-
logIndex: string;
|
|
108
|
-
removed?: boolean;
|
|
109
|
-
topics: Array<string>;
|
|
110
|
-
transactionHash: string;
|
|
111
|
-
transactionIndex: string;
|
|
112
|
-
}
|
|
113
|
-
export {};
|
|
1
|
+
import type Big from 'big.js';
|
|
2
|
+
import type { TinyBig } from '../shared/tiny-big/tiny-big';
|
|
3
|
+
import type { BytesLike } from './../utils/bytes';
|
|
4
|
+
type Modify<T, R> = Omit<T, keyof R> & R;
|
|
5
|
+
export interface RPCTransaction extends RPCBlockTransaction {
|
|
6
|
+
maxFeePerGas: string;
|
|
7
|
+
maxPriorityFeePerGas: string;
|
|
8
|
+
}
|
|
9
|
+
export type TransactionResponse = Modify<RPCTransaction, {
|
|
10
|
+
blockNumber: number;
|
|
11
|
+
chainId: number;
|
|
12
|
+
gas: TinyBig;
|
|
13
|
+
gasLimit: TinyBig;
|
|
14
|
+
gasPrice: TinyBig;
|
|
15
|
+
nonce: TinyBig;
|
|
16
|
+
transactionIndex: number;
|
|
17
|
+
type: number;
|
|
18
|
+
v: number;
|
|
19
|
+
value: TinyBig;
|
|
20
|
+
} & {
|
|
21
|
+
maxFeePerGas: TinyBig;
|
|
22
|
+
maxPriorityFeePerGas: TinyBig;
|
|
23
|
+
confirmations: number;
|
|
24
|
+
}>;
|
|
25
|
+
export type TransactionReceipt = Modify<RPCTransactionReceipt, {
|
|
26
|
+
blockNumber: number;
|
|
27
|
+
cumulativeGasUsed: TinyBig;
|
|
28
|
+
effectiveGasPrice: TinyBig;
|
|
29
|
+
gasUsed: TinyBig;
|
|
30
|
+
logs: Array<Log>;
|
|
31
|
+
status: number;
|
|
32
|
+
transactionIndex: number;
|
|
33
|
+
type: number;
|
|
34
|
+
} & {
|
|
35
|
+
byzantium: boolean;
|
|
36
|
+
confirmations: number;
|
|
37
|
+
}>;
|
|
38
|
+
export interface RPCTransactionRequest {
|
|
39
|
+
from?: string;
|
|
40
|
+
to: string;
|
|
41
|
+
gas?: string;
|
|
42
|
+
gasPrice?: string;
|
|
43
|
+
value?: string;
|
|
44
|
+
data?: BytesLike;
|
|
45
|
+
nonce?: string;
|
|
46
|
+
maxPriorityFeePerGas?: string;
|
|
47
|
+
maxFeePerGas?: string;
|
|
48
|
+
}
|
|
49
|
+
export interface TransactionRequest {
|
|
50
|
+
to?: string;
|
|
51
|
+
from?: string;
|
|
52
|
+
nonce?: TinyBig | string | Big | number;
|
|
53
|
+
gas?: TinyBig | number | Big | string;
|
|
54
|
+
gasPrice?: TinyBig | Big | string | number;
|
|
55
|
+
data?: BytesLike;
|
|
56
|
+
value?: TinyBig | string | Big | number;
|
|
57
|
+
chainId?: number;
|
|
58
|
+
type?: number;
|
|
59
|
+
maxPriorityFeePerGas?: TinyBig | string | Big | number;
|
|
60
|
+
maxFeePerGas?: TinyBig | string | Big | number;
|
|
61
|
+
}
|
|
62
|
+
export type Log = Modify<RPCLog, {
|
|
63
|
+
blockNumber: number;
|
|
64
|
+
logIndex: number;
|
|
65
|
+
transactionIndex: number;
|
|
66
|
+
}>;
|
|
67
|
+
export type BlockTransactionResponse = Omit<TransactionResponse, 'maxFeePerGas' | 'maxPriorityFeePerGas'>;
|
|
68
|
+
export interface RPCBlockTransaction {
|
|
69
|
+
blockHash: string;
|
|
70
|
+
blockNumber: string;
|
|
71
|
+
chainId: string;
|
|
72
|
+
from: string;
|
|
73
|
+
gas: string;
|
|
74
|
+
gasPrice: string;
|
|
75
|
+
hash: string;
|
|
76
|
+
input: string;
|
|
77
|
+
nonce: string;
|
|
78
|
+
r: string;
|
|
79
|
+
s: string;
|
|
80
|
+
to: string;
|
|
81
|
+
transactionIndex: string;
|
|
82
|
+
type: string;
|
|
83
|
+
v: string;
|
|
84
|
+
value: string;
|
|
85
|
+
}
|
|
86
|
+
export interface RPCTransactionReceipt {
|
|
87
|
+
blockHash: string;
|
|
88
|
+
blockNumber: string;
|
|
89
|
+
contractAddress: string;
|
|
90
|
+
cumulativeGasUsed: string;
|
|
91
|
+
effectiveGasPrice: string;
|
|
92
|
+
from: string;
|
|
93
|
+
gasUsed: string;
|
|
94
|
+
logs: Array<RPCLog>;
|
|
95
|
+
logsBloom: string;
|
|
96
|
+
status: string;
|
|
97
|
+
to: string;
|
|
98
|
+
transactionHash: string;
|
|
99
|
+
transactionIndex: string;
|
|
100
|
+
type: string;
|
|
101
|
+
}
|
|
102
|
+
export interface RPCLog {
|
|
103
|
+
address: string;
|
|
104
|
+
blockHash: string;
|
|
105
|
+
blockNumber: string;
|
|
106
|
+
data: string;
|
|
107
|
+
logIndex: string;
|
|
108
|
+
removed?: boolean;
|
|
109
|
+
topics: Array<string>;
|
|
110
|
+
transactionHash: string;
|
|
111
|
+
transactionIndex: string;
|
|
112
|
+
}
|
|
113
|
+
export {};
|
|
@@ -1,40 +1,40 @@
|
|
|
1
|
-
export type Bytes = ArrayLike<number>;
|
|
2
|
-
export type BytesLike = Bytes | string;
|
|
3
|
-
export type BytesLikeWithNumber = BytesLike | number;
|
|
4
|
-
export interface DataOptions {
|
|
5
|
-
allowMissingPrefix?: boolean;
|
|
6
|
-
hexPad?: 'left' | 'right' | null;
|
|
7
|
-
}
|
|
8
|
-
export interface Hexable {
|
|
9
|
-
toHexString(): string;
|
|
10
|
-
}
|
|
11
|
-
export type SignatureLike = {
|
|
12
|
-
r: string;
|
|
13
|
-
s?: string;
|
|
14
|
-
_vs?: string;
|
|
15
|
-
recoveryParam?: number;
|
|
16
|
-
v?: number;
|
|
17
|
-
} | BytesLike;
|
|
18
|
-
export interface Signature {
|
|
19
|
-
r: string;
|
|
20
|
-
s: string;
|
|
21
|
-
_vs: string;
|
|
22
|
-
recoveryParam: number;
|
|
23
|
-
v: number;
|
|
24
|
-
yParityAndS: string;
|
|
25
|
-
compact: string;
|
|
26
|
-
}
|
|
27
|
-
export declare function isBytesLike(value: any): value is BytesLike;
|
|
28
|
-
export declare function isBytes(value: any): value is Bytes;
|
|
29
|
-
export declare function arrayify(value: BytesLike | Hexable | number, options?: DataOptions): Uint8Array;
|
|
30
|
-
export declare function concat(arrayOfBytesLike: ReadonlyArray<BytesLikeWithNumber>): Uint8Array;
|
|
31
|
-
export declare function stripZeros(value: BytesLike): Uint8Array;
|
|
32
|
-
export declare function zeroPad(value: BytesLike, length: number): Uint8Array;
|
|
33
|
-
export declare function isHexString(value: any, length?: number): boolean;
|
|
34
|
-
export declare function hexlify(value: BytesLike | Hexable | number | bigint, options?: DataOptions): string;
|
|
35
|
-
export declare function hexDataLength(data: BytesLike): number | null;
|
|
36
|
-
export declare function hexDataSlice(data: BytesLikeWithNumber, offset: number, endOffset?: number): string;
|
|
37
|
-
export declare function hexConcat(items: ReadonlyArray<BytesLike>): string;
|
|
38
|
-
export declare function hexValue(value: BytesLike | Hexable | number | bigint): string;
|
|
39
|
-
export declare function hexStripZeros(value: BytesLike): string;
|
|
40
|
-
export declare function hexZeroPad(value: BytesLikeWithNumber, length: number): string;
|
|
1
|
+
export type Bytes = ArrayLike<number>;
|
|
2
|
+
export type BytesLike = Bytes | string;
|
|
3
|
+
export type BytesLikeWithNumber = BytesLike | number;
|
|
4
|
+
export interface DataOptions {
|
|
5
|
+
allowMissingPrefix?: boolean;
|
|
6
|
+
hexPad?: 'left' | 'right' | null;
|
|
7
|
+
}
|
|
8
|
+
export interface Hexable {
|
|
9
|
+
toHexString(): string;
|
|
10
|
+
}
|
|
11
|
+
export type SignatureLike = {
|
|
12
|
+
r: string;
|
|
13
|
+
s?: string;
|
|
14
|
+
_vs?: string;
|
|
15
|
+
recoveryParam?: number;
|
|
16
|
+
v?: number;
|
|
17
|
+
} | BytesLike;
|
|
18
|
+
export interface Signature {
|
|
19
|
+
r: string;
|
|
20
|
+
s: string;
|
|
21
|
+
_vs: string;
|
|
22
|
+
recoveryParam: number;
|
|
23
|
+
v: number;
|
|
24
|
+
yParityAndS: string;
|
|
25
|
+
compact: string;
|
|
26
|
+
}
|
|
27
|
+
export declare function isBytesLike(value: any): value is BytesLike;
|
|
28
|
+
export declare function isBytes(value: any): value is Bytes;
|
|
29
|
+
export declare function arrayify(value: BytesLike | Hexable | number, options?: DataOptions): Uint8Array;
|
|
30
|
+
export declare function concat(arrayOfBytesLike: ReadonlyArray<BytesLikeWithNumber>): Uint8Array;
|
|
31
|
+
export declare function stripZeros(value: BytesLike): Uint8Array;
|
|
32
|
+
export declare function zeroPad(value: BytesLike, length: number): Uint8Array;
|
|
33
|
+
export declare function isHexString(value: any, length?: number): boolean;
|
|
34
|
+
export declare function hexlify(value: BytesLike | Hexable | number | bigint, options?: DataOptions): string;
|
|
35
|
+
export declare function hexDataLength(data: BytesLike): number | null;
|
|
36
|
+
export declare function hexDataSlice(data: BytesLikeWithNumber, offset: number, endOffset?: number): string;
|
|
37
|
+
export declare function hexConcat(items: ReadonlyArray<BytesLike>): string;
|
|
38
|
+
export declare function hexValue(value: BytesLike | Hexable | number | bigint): string;
|
|
39
|
+
export declare function hexStripZeros(value: BytesLike): string;
|
|
40
|
+
export declare function hexZeroPad(value: BytesLikeWithNumber, length: number): string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare function computeAddress(key: string): string;
|
|
1
|
+
export declare function computeAddress(key: string): string;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import type { BytesLike } from './bytes';
|
|
2
|
-
export declare function computePublicKey(privKey: BytesLike): string;
|
|
1
|
+
import type { BytesLike } from './bytes';
|
|
2
|
+
export declare function computePublicKey(privKey: BytesLike): string;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import type Big from 'big.js';
|
|
2
|
-
import type { TinyBig } from '../shared/tiny-big/tiny-big';
|
|
3
|
-
export declare function etherToGwei(etherQuantity: string | number | TinyBig | Big): TinyBig;
|
|
1
|
+
import type Big from 'big.js';
|
|
2
|
+
import type { TinyBig } from '../shared/tiny-big/tiny-big';
|
|
3
|
+
export declare function etherToGwei(etherQuantity: string | number | TinyBig | Big): TinyBig;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import type Big from 'big.js';
|
|
2
|
-
import type { TinyBig } from '../shared/tiny-big/tiny-big';
|
|
3
|
-
export declare function etherToWei(etherQuantity: string | number | TinyBig | Big): TinyBig;
|
|
1
|
+
import type Big from 'big.js';
|
|
2
|
+
import type { TinyBig } from '../shared/tiny-big/tiny-big';
|
|
3
|
+
export declare function etherToWei(etherQuantity: string | number | TinyBig | Big): TinyBig;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import type Big from 'big.js';
|
|
2
|
-
import type { TinyBig } from './../shared/tiny-big/tiny-big';
|
|
3
|
-
export declare function gweiToEther(gweiQuantity: string | number | TinyBig | Big): TinyBig;
|
|
1
|
+
import type Big from 'big.js';
|
|
2
|
+
import type { TinyBig } from './../shared/tiny-big/tiny-big';
|
|
3
|
+
export declare function gweiToEther(gweiQuantity: string | number | TinyBig | Big): TinyBig;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import type { Bytes } from './bytes';
|
|
2
|
-
export declare function hashMessage(message: Bytes | string): string;
|
|
1
|
+
import type { Bytes } from './bytes';
|
|
2
|
+
export declare function hashMessage(message: Bytes | string): string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare function isAddress(address: string): boolean;
|
|
1
|
+
export declare function isAddress(address: string): boolean;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import type { BytesLike } from './bytes';
|
|
2
|
-
export declare function keccak256(data: BytesLike): string;
|
|
1
|
+
import type { BytesLike } from './bytes';
|
|
2
|
+
export declare function keccak256(data: BytesLike): string;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare function pack(types: ReadonlyArray<string>, values: ReadonlyArray<any>): string;
|
|
2
|
-
export declare function solidityKeccak256(types: ReadonlyArray<string>, values: ReadonlyArray<any>): string;
|
|
1
|
+
export declare function pack(types: ReadonlyArray<string>, values: ReadonlyArray<any>): string;
|
|
2
|
+
export declare function solidityKeccak256(types: ReadonlyArray<string>, values: ReadonlyArray<any>): string;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import type { Signature, SignatureLike } from './bytes';
|
|
2
|
-
export declare function splitSignature(signature: SignatureLike): Signature;
|
|
1
|
+
import type { Signature, SignatureLike } from './bytes';
|
|
2
|
+
export declare function splitSignature(signature: SignatureLike): Signature;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare function toChecksumAddress(address: string): string;
|
|
1
|
+
export declare function toChecksumAddress(address: string): string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare function toUtf8Bytes(data: string): Uint8Array;
|
|
1
|
+
export declare function toUtf8Bytes(data: string): Uint8Array;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import type Big from 'big.js';
|
|
2
|
-
import type { TinyBig } from '../shared/tiny-big/tiny-big';
|
|
3
|
-
export declare function weiToEther(weiQuantity: string | number | TinyBig | Big): TinyBig;
|
|
1
|
+
import type Big from 'big.js';
|
|
2
|
+
import type { TinyBig } from '../shared/tiny-big/tiny-big';
|
|
3
|
+
export declare function weiToEther(weiQuantity: string | number | TinyBig | Big): TinyBig;
|