-
Notifications
You must be signed in to change notification settings - Fork 19
Expand file tree
/
Copy pathtypes.ts
More file actions
134 lines (111 loc) · 2.43 KB
/
types.ts
File metadata and controls
134 lines (111 loc) · 2.43 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
import { QuickPickItem } from "vscode";
import { JsonFragment } from "@ethersproject/abi";
export interface ISource {
content: string | undefined;
}
export interface ISources {
[key: string]: ISource;
}
export interface IAccount {
label: string;
value: string;
pubAddr?: string;
checksumAddr?: string;
}
export interface Account {
pubAddr: string;
checksumAddr: string;
}
export type LocalAddressType = {
pubAddress: string;
checksumAddress: string;
};
export type GanacheAddressType = string;
export interface TokenData {
appId?: string;
token?: string;
email?: string;
}
export interface ICompilationResult {
source: {
target: string;
sources: ISources;
};
data: any;
}
export interface INetworkQP extends QuickPickItem {
label: string;
}
export interface IEthereumNetworkQP extends QuickPickItem {
name: string;
rpc: string;
chainId?: number | string;
}
export interface IAccountQP extends QuickPickItem {
checksumAddr: string;
}
export interface ICombinedJSONContractsQP extends QuickPickItem {
contractKey: string;
}
export interface IStandardJSONContractsQP extends QuickPickItem {
contractKey: string;
}
export interface IFunctionQP extends QuickPickItem {
functionKey: string;
}
export interface ConstructorInputValue extends JsonFragment {
value: string;
}
export interface EstimateGas {
confidence: number;
price: number;
maxPriorityFeePerGas: number;
maxFeePerGas: number;
}
export interface TxReceipt {
transactionHash: string;
transactionIndex: number;
blockHash: string;
blockNumber: number;
from: string;
to?: null;
gasUsed: number;
cumulativeGasUsed: number;
contractAddress: string;
logs?: null[] | null;
status: number;
logsBloom: string;
}
interface NativeCurrencyType {
name: string;
symbol: string;
decimal: string;
}
export interface NetworkConfig {
rpc: string;
blockScanner: string;
chainID: string;
nativeCurrency: NativeCurrencyType;
}
export interface ERC4907ContractType {
interface: string;
contract: string;
ERC4907Contract: string;
}
export interface ERC4907ContractType {
interface: string;
contract: string;
ERC4907Contract: string;
}
export interface ERC4337TokenPaymaterType {
TokenPaymaster: string;
}
export interface ERC4337VerifyPaymaterType {
VerifyingPaymaster: string;
}
// Typeguard
export function isConstructorInputValue(
obj: any
): obj is ConstructorInputValue {
return obj.value !== undefined;
}