@wagmi/connectors 3.1.1-cjs → 4.0.0-alpha.0
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/esm/coinbaseWallet.js +141 -0
- package/dist/esm/coinbaseWallet.js.map +1 -0
- package/dist/esm/index.js +7 -0
- package/dist/esm/index.js.map +1 -0
- package/dist/esm/index.test-d.js +4 -0
- package/dist/esm/index.test-d.js.map +1 -0
- package/dist/esm/injected.js +372 -0
- package/dist/esm/injected.js.map +1 -0
- package/dist/esm/ledger.js +162 -0
- package/dist/esm/ledger.js.map +1 -0
- package/dist/esm/safe.js +88 -0
- package/dist/esm/safe.js.map +1 -0
- package/dist/esm/tsconfig.build.tsbuildinfo +1 -0
- package/dist/esm/version.js +2 -0
- package/dist/esm/version.js.map +1 -0
- package/dist/esm/walletConnect.js +280 -0
- package/dist/esm/walletConnect.js.map +1 -0
- package/dist/types/coinbaseWallet.d.ts +21 -0
- package/dist/types/coinbaseWallet.d.ts.map +1 -0
- package/dist/types/index.d.ts +7 -0
- package/dist/types/index.d.ts.map +1 -0
- package/dist/types/index.test-d.d.ts +2 -0
- package/dist/types/index.test-d.d.ts.map +1 -0
- package/dist/types/injected.d.ts +382 -0
- package/dist/types/injected.d.ts.map +1 -0
- package/dist/types/ledger.d.ts +18 -0
- package/dist/types/ledger.d.ts.map +1 -0
- package/dist/types/safe.d.ts +18 -0
- package/dist/types/safe.d.ts.map +1 -0
- package/dist/types/version.d.ts +2 -0
- package/dist/types/version.d.ts.map +1 -0
- package/dist/types/walletConnect.d.ts +63 -0
- package/dist/types/walletConnect.d.ts.map +1 -0
- package/package.json +44 -82
- package/src/coinbaseWallet.ts +207 -0
- package/src/index.ts +17 -0
- package/src/injected.ts +535 -0
- package/src/ledger.ts +210 -0
- package/src/safe.ts +114 -0
- package/src/version.ts +1 -0
- package/src/walletConnect.ts +394 -0
- package/README.md +0 -46
- package/coinbaseWallet/package.json +0 -4
- package/dist/base-70e3a8a9.d.ts +0 -142
- package/dist/chunk-2UFLHRLT.js +0 -391
- package/dist/chunk-OQILYQDO.js +0 -15
- package/dist/chunk-UGBGYVBH.js +0 -22
- package/dist/chunk-W65LBPLT.js +0 -58
- package/dist/coinbaseWallet.d.ts +0 -62
- package/dist/coinbaseWallet.js +0 -216
- package/dist/index.d.ts +0 -20
- package/dist/index.js +0 -16
- package/dist/injected.d.ts +0 -64
- package/dist/injected.js +0 -9
- package/dist/ledger.d.ts +0 -69
- package/dist/ledger.js +0 -261
- package/dist/metaMask.d.ts +0 -33
- package/dist/metaMask.js +0 -144
- package/dist/mock/index.d.ts +0 -80
- package/dist/mock/index.js +0 -200
- package/dist/safe.d.ts +0 -53
- package/dist/safe.js +0 -129
- package/dist/walletConnect.d.ts +0 -109
- package/dist/walletConnect.js +0 -325
- package/dist/walletConnectLegacy.d.ts +0 -38
- package/dist/walletConnectLegacy.js +0 -179
- package/injected/package.json +0 -4
- package/ledger/package.json +0 -4
- package/metaMask/package.json +0 -4
- package/mock/package.json +0 -4
- package/safe/package.json +0 -4
- package/walletConnect/package.json +0 -4
- package/walletConnectLegacy/package.json +0 -4
|
@@ -0,0 +1,382 @@
|
|
|
1
|
+
import type { Evaluate } from '@wagmi/core/internal';
|
|
2
|
+
import { type EIP1193Provider, type ProviderConnectInfo } from 'viem';
|
|
3
|
+
export type InjectedParameters = {
|
|
4
|
+
/**
|
|
5
|
+
* MetaMask and other injected providers do not support programmatic disconnect.
|
|
6
|
+
* This flag simulates the disconnect behavior by keeping track of connection status in storage. See [GitHub issue](https://github.com/MetaMask/metamask-extension/issues/10353) for more info.
|
|
7
|
+
* @default true
|
|
8
|
+
*/
|
|
9
|
+
shimDisconnect?: boolean | undefined;
|
|
10
|
+
unstable_shimAsyncInject?: boolean | number | undefined;
|
|
11
|
+
/**
|
|
12
|
+
* [EIP-1193](https://eips.ethereum.org/EIPS/eip-1193) Ethereum Provider to target
|
|
13
|
+
*/
|
|
14
|
+
target?: TargetId | (() => (TargetMap[TargetId] & {
|
|
15
|
+
id: string;
|
|
16
|
+
}) | undefined) | undefined;
|
|
17
|
+
};
|
|
18
|
+
export declare function injected(parameters?: InjectedParameters): import("@wagmi/core").CreateConnectorFn<{
|
|
19
|
+
on: <TEvent extends keyof import("viem").EIP1193EventMap>(event: TEvent, listener: import("viem").EIP1193EventMap[TEvent]) => void;
|
|
20
|
+
removeListener: <TEvent_1 extends keyof import("viem").EIP1193EventMap>(event: TEvent_1, listener: import("viem").EIP1193EventMap[TEvent_1]) => void;
|
|
21
|
+
request: import("viem").EIP1193RequestFn<[{
|
|
22
|
+
Method: "web3_clientVersion";
|
|
23
|
+
Parameters?: undefined;
|
|
24
|
+
ReturnType: string;
|
|
25
|
+
}, {
|
|
26
|
+
Method: "web3_sha3";
|
|
27
|
+
Parameters: [data: `0x${string}`];
|
|
28
|
+
ReturnType: string;
|
|
29
|
+
}, {
|
|
30
|
+
Method: "net_listening";
|
|
31
|
+
Parameters?: undefined;
|
|
32
|
+
ReturnType: boolean;
|
|
33
|
+
}, {
|
|
34
|
+
Method: "net_peerCount";
|
|
35
|
+
Parameters?: undefined;
|
|
36
|
+
ReturnType: `0x${string}`;
|
|
37
|
+
}, {
|
|
38
|
+
Method: "net_version";
|
|
39
|
+
Parameters?: undefined;
|
|
40
|
+
ReturnType: `0x${string}`;
|
|
41
|
+
}, {
|
|
42
|
+
Method: "eth_blockNumber";
|
|
43
|
+
Parameters?: undefined;
|
|
44
|
+
ReturnType: `0x${string}`;
|
|
45
|
+
}, {
|
|
46
|
+
Method: "eth_call";
|
|
47
|
+
Parameters: [transaction: Partial<import("viem").RpcTransactionRequest>] | [transaction: Partial<import("viem").RpcTransactionRequest>, block: `0x${string}` | import("viem").BlockTag | import("viem").RpcBlockIdentifier];
|
|
48
|
+
ReturnType: `0x${string}`;
|
|
49
|
+
}, {
|
|
50
|
+
Method: "eth_chainId";
|
|
51
|
+
Parameters?: undefined;
|
|
52
|
+
ReturnType: `0x${string}`;
|
|
53
|
+
}, {
|
|
54
|
+
Method: "eth_coinbase";
|
|
55
|
+
Parameters?: undefined;
|
|
56
|
+
ReturnType: `0x${string}`;
|
|
57
|
+
}, {
|
|
58
|
+
Method: "eth_estimateGas";
|
|
59
|
+
Parameters: [transaction: import("viem").RpcTransactionRequest] | [transaction: import("viem").RpcTransactionRequest, block: `0x${string}` | import("viem").BlockTag];
|
|
60
|
+
ReturnType: `0x${string}`;
|
|
61
|
+
}, {
|
|
62
|
+
Method: "eth_feeHistory";
|
|
63
|
+
Parameters: [blockCount: `0x${string}`, newestBlock: `0x${string}` | import("viem").BlockTag, rewardPercentiles: number[] | undefined];
|
|
64
|
+
ReturnType: import("viem").RpcFeeHistory;
|
|
65
|
+
}, {
|
|
66
|
+
Method: "eth_gasPrice";
|
|
67
|
+
Parameters?: undefined;
|
|
68
|
+
ReturnType: `0x${string}`;
|
|
69
|
+
}, {
|
|
70
|
+
Method: "eth_getBalance";
|
|
71
|
+
Parameters: [address: `0x${string}`, block: `0x${string}` | import("viem").BlockTag | import("viem").RpcBlockIdentifier];
|
|
72
|
+
ReturnType: `0x${string}`;
|
|
73
|
+
}, {
|
|
74
|
+
Method: "eth_getBlockByHash";
|
|
75
|
+
Parameters: [hash: `0x${string}`, includeTransactionObjects: boolean];
|
|
76
|
+
ReturnType: import("viem").RpcBlock | null;
|
|
77
|
+
}, {
|
|
78
|
+
Method: "eth_getBlockByNumber";
|
|
79
|
+
Parameters: [block: `0x${string}` | import("viem").BlockTag, includeTransactionObjects: boolean];
|
|
80
|
+
ReturnType: import("viem").RpcBlock | null;
|
|
81
|
+
}, {
|
|
82
|
+
Method: "eth_getBlockTransactionCountByHash";
|
|
83
|
+
Parameters: [hash: `0x${string}`];
|
|
84
|
+
ReturnType: `0x${string}`;
|
|
85
|
+
}, {
|
|
86
|
+
Method: "eth_getBlockTransactionCountByNumber";
|
|
87
|
+
Parameters: [block: `0x${string}` | import("viem").BlockTag];
|
|
88
|
+
ReturnType: `0x${string}`;
|
|
89
|
+
}, {
|
|
90
|
+
Method: "eth_getCode";
|
|
91
|
+
Parameters: [address: `0x${string}`, block: `0x${string}` | import("viem").BlockTag | import("viem").RpcBlockIdentifier];
|
|
92
|
+
ReturnType: `0x${string}`;
|
|
93
|
+
}, {
|
|
94
|
+
Method: "eth_getFilterChanges";
|
|
95
|
+
Parameters: [filterId: `0x${string}`];
|
|
96
|
+
ReturnType: `0x${string}`[] | import("viem").RpcLog[];
|
|
97
|
+
}, {
|
|
98
|
+
Method: "eth_getFilterLogs";
|
|
99
|
+
Parameters: [filterId: `0x${string}`];
|
|
100
|
+
ReturnType: import("viem").RpcLog[];
|
|
101
|
+
}, {
|
|
102
|
+
Method: "eth_getLogs";
|
|
103
|
+
Parameters: [{
|
|
104
|
+
address?: `0x${string}` | `0x${string}`[] | undefined;
|
|
105
|
+
topics?: import("viem").LogTopic[] | undefined;
|
|
106
|
+
} & ({
|
|
107
|
+
fromBlock?: `0x${string}` | import("viem").BlockTag | undefined;
|
|
108
|
+
toBlock?: `0x${string}` | import("viem").BlockTag | undefined;
|
|
109
|
+
blockHash?: undefined;
|
|
110
|
+
} | {
|
|
111
|
+
fromBlock?: undefined;
|
|
112
|
+
toBlock?: undefined;
|
|
113
|
+
blockHash?: `0x${string}` | undefined;
|
|
114
|
+
})];
|
|
115
|
+
ReturnType: import("viem").RpcLog[];
|
|
116
|
+
}, {
|
|
117
|
+
Method: "eth_getStorageAt";
|
|
118
|
+
Parameters: [address: `0x${string}`, index: `0x${string}`, block: `0x${string}` | import("viem").BlockTag | import("viem").RpcBlockIdentifier];
|
|
119
|
+
ReturnType: `0x${string}`;
|
|
120
|
+
}, {
|
|
121
|
+
Method: "eth_getTransactionByBlockHashAndIndex";
|
|
122
|
+
Parameters: [hash: `0x${string}`, index: `0x${string}`];
|
|
123
|
+
ReturnType: import("viem").RpcTransaction | null;
|
|
124
|
+
}, {
|
|
125
|
+
Method: "eth_getTransactionByBlockNumberAndIndex";
|
|
126
|
+
Parameters: [block: `0x${string}` | import("viem").BlockTag, index: `0x${string}`];
|
|
127
|
+
ReturnType: import("viem").RpcTransaction | null;
|
|
128
|
+
}, {
|
|
129
|
+
Method: "eth_getTransactionByHash";
|
|
130
|
+
Parameters: [hash: `0x${string}`];
|
|
131
|
+
ReturnType: import("viem").RpcTransaction | null;
|
|
132
|
+
}, {
|
|
133
|
+
Method: "eth_getTransactionCount";
|
|
134
|
+
Parameters: [address: `0x${string}`, block: `0x${string}` | import("viem").BlockTag | import("viem").RpcBlockIdentifier];
|
|
135
|
+
ReturnType: `0x${string}`;
|
|
136
|
+
}, {
|
|
137
|
+
Method: "eth_getTransactionReceipt";
|
|
138
|
+
Parameters: [hash: `0x${string}`];
|
|
139
|
+
ReturnType: import("viem").RpcTransactionReceipt | null;
|
|
140
|
+
}, {
|
|
141
|
+
Method: "eth_getUncleByBlockHashAndIndex";
|
|
142
|
+
Parameters: [hash: `0x${string}`, index: `0x${string}`];
|
|
143
|
+
ReturnType: import("viem").RpcUncle | null;
|
|
144
|
+
}, {
|
|
145
|
+
Method: "eth_getUncleByBlockNumberAndIndex";
|
|
146
|
+
Parameters: [block: `0x${string}` | import("viem").BlockTag, index: `0x${string}`];
|
|
147
|
+
ReturnType: import("viem").RpcUncle | null;
|
|
148
|
+
}, {
|
|
149
|
+
Method: "eth_getUncleCountByBlockHash";
|
|
150
|
+
Parameters: [hash: `0x${string}`];
|
|
151
|
+
ReturnType: `0x${string}`;
|
|
152
|
+
}, {
|
|
153
|
+
Method: "eth_getUncleCountByBlockNumber";
|
|
154
|
+
Parameters: [block: `0x${string}` | import("viem").BlockTag];
|
|
155
|
+
ReturnType: `0x${string}`;
|
|
156
|
+
}, {
|
|
157
|
+
Method: "eth_maxPriorityFeePerGas";
|
|
158
|
+
Parameters?: undefined;
|
|
159
|
+
ReturnType: `0x${string}`;
|
|
160
|
+
}, {
|
|
161
|
+
Method: "eth_newBlockFilter";
|
|
162
|
+
Parameters?: undefined;
|
|
163
|
+
ReturnType: `0x${string}`;
|
|
164
|
+
}, {
|
|
165
|
+
Method: "eth_newFilter";
|
|
166
|
+
Parameters: [filter: {
|
|
167
|
+
fromBlock?: `0x${string}` | import("viem").BlockTag | undefined;
|
|
168
|
+
toBlock?: `0x${string}` | import("viem").BlockTag | undefined;
|
|
169
|
+
address?: `0x${string}` | `0x${string}`[] | undefined;
|
|
170
|
+
topics?: import("viem").LogTopic[] | undefined;
|
|
171
|
+
}];
|
|
172
|
+
ReturnType: `0x${string}`;
|
|
173
|
+
}, {
|
|
174
|
+
Method: "eth_newPendingTransactionFilter";
|
|
175
|
+
Parameters?: undefined;
|
|
176
|
+
ReturnType: `0x${string}`;
|
|
177
|
+
}, {
|
|
178
|
+
Method: "eth_protocolVersion";
|
|
179
|
+
Parameters?: undefined;
|
|
180
|
+
ReturnType: string;
|
|
181
|
+
}, {
|
|
182
|
+
Method: "eth_sendRawTransaction";
|
|
183
|
+
Parameters: [signedTransaction: `0x${string}`];
|
|
184
|
+
ReturnType: `0x${string}`;
|
|
185
|
+
}, {
|
|
186
|
+
Method: "eth_uninstallFilter";
|
|
187
|
+
Parameters: [filterId: `0x${string}`];
|
|
188
|
+
ReturnType: boolean;
|
|
189
|
+
}, {
|
|
190
|
+
Method: "eth_accounts";
|
|
191
|
+
Parameters?: undefined;
|
|
192
|
+
ReturnType: `0x${string}`[];
|
|
193
|
+
}, {
|
|
194
|
+
Method: "eth_chainId";
|
|
195
|
+
Parameters?: undefined;
|
|
196
|
+
ReturnType: `0x${string}`;
|
|
197
|
+
}, {
|
|
198
|
+
Method: "eth_estimateGas";
|
|
199
|
+
Parameters: [transaction: import("viem").RpcTransactionRequest] | [transaction: import("viem").RpcTransactionRequest, block: `0x${string}` | import("viem").BlockTag];
|
|
200
|
+
ReturnType: `0x${string}`;
|
|
201
|
+
}, {
|
|
202
|
+
Method: "eth_requestAccounts";
|
|
203
|
+
Parameters?: undefined;
|
|
204
|
+
ReturnType: `0x${string}`[];
|
|
205
|
+
}, {
|
|
206
|
+
Method: "eth_sendTransaction";
|
|
207
|
+
Parameters: [transaction: import("viem").RpcTransactionRequest];
|
|
208
|
+
ReturnType: `0x${string}`;
|
|
209
|
+
}, {
|
|
210
|
+
Method: "eth_sendRawTransaction";
|
|
211
|
+
Parameters: [signedTransaction: `0x${string}`];
|
|
212
|
+
ReturnType: `0x${string}`;
|
|
213
|
+
}, {
|
|
214
|
+
Method: "eth_sign";
|
|
215
|
+
Parameters: [address: `0x${string}`, data: `0x${string}`];
|
|
216
|
+
ReturnType: `0x${string}`;
|
|
217
|
+
}, {
|
|
218
|
+
Method: "eth_signTransaction";
|
|
219
|
+
Parameters: [request: import("viem").RpcTransactionRequest];
|
|
220
|
+
ReturnType: `0x${string}`;
|
|
221
|
+
}, {
|
|
222
|
+
Method: "eth_signTypedData_v4";
|
|
223
|
+
Parameters: [address: `0x${string}`, message: string];
|
|
224
|
+
ReturnType: `0x${string}`;
|
|
225
|
+
}, {
|
|
226
|
+
Method: "eth_syncing";
|
|
227
|
+
Parameters?: undefined;
|
|
228
|
+
ReturnType: false | import("viem").NetworkSync;
|
|
229
|
+
}, {
|
|
230
|
+
Method: "personal_sign";
|
|
231
|
+
Parameters: [data: `0x${string}`, address: `0x${string}`];
|
|
232
|
+
ReturnType: `0x${string}`;
|
|
233
|
+
}, {
|
|
234
|
+
Method: "wallet_addEthereumChain";
|
|
235
|
+
Parameters: [chain: import("viem").AddEthereumChainParameter];
|
|
236
|
+
ReturnType: null;
|
|
237
|
+
}, {
|
|
238
|
+
Method: "wallet_getPermissions";
|
|
239
|
+
Parameters?: undefined;
|
|
240
|
+
ReturnType: import("viem").WalletPermission[];
|
|
241
|
+
}, {
|
|
242
|
+
Method: "wallet_requestPermissions";
|
|
243
|
+
Parameters: [permissions: {
|
|
244
|
+
eth_accounts: Record<string, any>;
|
|
245
|
+
}];
|
|
246
|
+
ReturnType: import("viem").WalletPermission[];
|
|
247
|
+
}, {
|
|
248
|
+
Method: "wallet_switchEthereumChain";
|
|
249
|
+
Parameters: [chain: {
|
|
250
|
+
chainId: string;
|
|
251
|
+
}];
|
|
252
|
+
ReturnType: null;
|
|
253
|
+
}, {
|
|
254
|
+
Method: "wallet_watchAsset";
|
|
255
|
+
Parameters: import("viem").WatchAssetParams;
|
|
256
|
+
ReturnType: boolean;
|
|
257
|
+
}]>;
|
|
258
|
+
isApexWallet?: true | undefined;
|
|
259
|
+
isAvalanche?: true | undefined;
|
|
260
|
+
isBackpack?: true | undefined;
|
|
261
|
+
isBifrost?: true | undefined;
|
|
262
|
+
isBitKeep?: true | undefined;
|
|
263
|
+
isBitski?: true | undefined;
|
|
264
|
+
isBlockWallet?: true | undefined;
|
|
265
|
+
isBraveWallet?: true | undefined;
|
|
266
|
+
isCoinbaseWallet?: true | undefined;
|
|
267
|
+
isDawn?: true | undefined;
|
|
268
|
+
isEnkrypt?: true | undefined;
|
|
269
|
+
isExodus?: true | undefined;
|
|
270
|
+
isFrame?: true | undefined;
|
|
271
|
+
isFrontier?: true | undefined;
|
|
272
|
+
isGamestop?: true | undefined;
|
|
273
|
+
isHyperPay?: true | undefined;
|
|
274
|
+
isImToken?: true | undefined;
|
|
275
|
+
isKuCoinWallet?: true | undefined;
|
|
276
|
+
isMathWallet?: true | undefined;
|
|
277
|
+
isMetaMask?: true | undefined;
|
|
278
|
+
isOkxWallet?: true | undefined;
|
|
279
|
+
isOKExWallet?: true | undefined;
|
|
280
|
+
isOneInchAndroidWallet?: true | undefined;
|
|
281
|
+
isOneInchIOSWallet?: true | undefined;
|
|
282
|
+
isOpera?: true | undefined;
|
|
283
|
+
isPhantom?: true | undefined;
|
|
284
|
+
isPortal?: true | undefined;
|
|
285
|
+
isRabby?: true | undefined;
|
|
286
|
+
isRainbow?: true | undefined;
|
|
287
|
+
isStatus?: true | undefined;
|
|
288
|
+
isTally?: true | undefined;
|
|
289
|
+
isTokenPocket?: true | undefined;
|
|
290
|
+
isTokenary?: true | undefined;
|
|
291
|
+
isTrust?: true | undefined;
|
|
292
|
+
isTrustWallet?: true | undefined;
|
|
293
|
+
isXDEFI?: true | undefined;
|
|
294
|
+
isZerion?: true | undefined;
|
|
295
|
+
providers?: any[] | undefined;
|
|
296
|
+
_events?: {
|
|
297
|
+
connect?: (() => void) | undefined;
|
|
298
|
+
} | undefined;
|
|
299
|
+
_state?: {
|
|
300
|
+
accounts?: string[] | undefined;
|
|
301
|
+
initialized?: boolean | undefined;
|
|
302
|
+
isConnected?: boolean | undefined;
|
|
303
|
+
isPermanentlyDisconnected?: boolean | undefined;
|
|
304
|
+
isUnlocked?: boolean | undefined;
|
|
305
|
+
} | undefined;
|
|
306
|
+
} | undefined, {
|
|
307
|
+
onConnect(connectInfo: ProviderConnectInfo): void;
|
|
308
|
+
}, {
|
|
309
|
+
[x: `${string}.connected`]: true;
|
|
310
|
+
}>;
|
|
311
|
+
export type TargetId = Evaluate<keyof WindowProviderFlags> extends `is${infer name}` ? name extends `${infer char}${infer rest}` ? `${Lowercase<char>}${rest}` : never : never;
|
|
312
|
+
type Target = {
|
|
313
|
+
name: string;
|
|
314
|
+
provider: keyof WindowProviderFlags | ((window?: Window | undefined) => WindowProvider | undefined);
|
|
315
|
+
features?: readonly 'wallet_requestPermissions'[] | undefined;
|
|
316
|
+
};
|
|
317
|
+
type TargetMap = {
|
|
318
|
+
[_ in TargetId]?: Target | undefined;
|
|
319
|
+
};
|
|
320
|
+
type WindowProviderFlags = {
|
|
321
|
+
isApexWallet?: true | undefined;
|
|
322
|
+
isAvalanche?: true | undefined;
|
|
323
|
+
isBackpack?: true | undefined;
|
|
324
|
+
isBifrost?: true | undefined;
|
|
325
|
+
isBitKeep?: true | undefined;
|
|
326
|
+
isBitski?: true | undefined;
|
|
327
|
+
isBlockWallet?: true | undefined;
|
|
328
|
+
isBraveWallet?: true | undefined;
|
|
329
|
+
isCoinbaseWallet?: true | undefined;
|
|
330
|
+
isDawn?: true | undefined;
|
|
331
|
+
isEnkrypt?: true | undefined;
|
|
332
|
+
isExodus?: true | undefined;
|
|
333
|
+
isFrame?: true | undefined;
|
|
334
|
+
isFrontier?: true | undefined;
|
|
335
|
+
isGamestop?: true | undefined;
|
|
336
|
+
isHyperPay?: true | undefined;
|
|
337
|
+
isImToken?: true | undefined;
|
|
338
|
+
isKuCoinWallet?: true | undefined;
|
|
339
|
+
isMathWallet?: true | undefined;
|
|
340
|
+
isMetaMask?: true | undefined;
|
|
341
|
+
isOkxWallet?: true | undefined;
|
|
342
|
+
isOKExWallet?: true | undefined;
|
|
343
|
+
isOneInchAndroidWallet?: true | undefined;
|
|
344
|
+
isOneInchIOSWallet?: true | undefined;
|
|
345
|
+
isOpera?: true | undefined;
|
|
346
|
+
isPhantom?: true | undefined;
|
|
347
|
+
isPortal?: true | undefined;
|
|
348
|
+
isRabby?: true | undefined;
|
|
349
|
+
isRainbow?: true | undefined;
|
|
350
|
+
isStatus?: true | undefined;
|
|
351
|
+
isTally?: true | undefined;
|
|
352
|
+
isTokenPocket?: true | undefined;
|
|
353
|
+
isTokenary?: true | undefined;
|
|
354
|
+
isTrust?: true | undefined;
|
|
355
|
+
isTrustWallet?: true | undefined;
|
|
356
|
+
isXDEFI?: true | undefined;
|
|
357
|
+
isZerion?: true | undefined;
|
|
358
|
+
};
|
|
359
|
+
type WindowProvider = Evaluate<EIP1193Provider & WindowProviderFlags & {
|
|
360
|
+
providers?: WindowProvider[] | undefined;
|
|
361
|
+
/** Only exists in MetaMask as of 2022/04/03 */
|
|
362
|
+
_events?: {
|
|
363
|
+
connect?: (() => void) | undefined;
|
|
364
|
+
} | undefined;
|
|
365
|
+
/** Only exists in MetaMask as of 2022/04/03 */
|
|
366
|
+
_state?: {
|
|
367
|
+
accounts?: string[];
|
|
368
|
+
initialized?: boolean;
|
|
369
|
+
isConnected?: boolean;
|
|
370
|
+
isPermanentlyDisconnected?: boolean;
|
|
371
|
+
isUnlocked?: boolean;
|
|
372
|
+
} | undefined;
|
|
373
|
+
}>;
|
|
374
|
+
type Window = {
|
|
375
|
+
coinbaseWalletExtension?: WindowProvider | undefined;
|
|
376
|
+
ethereum?: WindowProvider | undefined;
|
|
377
|
+
phantom?: {
|
|
378
|
+
ethereum: WindowProvider;
|
|
379
|
+
} | undefined;
|
|
380
|
+
};
|
|
381
|
+
export {};
|
|
382
|
+
//# sourceMappingURL=injected.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"injected.d.ts","sourceRoot":"","sources":["../../src/injected.ts"],"names":[],"mappings":"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"}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { type EthereumProvider } from '@ledgerhq/connect-kit-loader';
|
|
2
|
+
import { type ProviderConnectInfo } from 'viem';
|
|
3
|
+
export type LedgerParameters = {
|
|
4
|
+
enableDebugLogs?: boolean | undefined;
|
|
5
|
+
optionalEvents?: string[] | undefined;
|
|
6
|
+
optionalMethods?: string[] | undefined;
|
|
7
|
+
projectId?: string | undefined;
|
|
8
|
+
requiredChains?: number[] | undefined;
|
|
9
|
+
requiredEvents?: string[] | undefined;
|
|
10
|
+
requiredMethods?: string[] | undefined;
|
|
11
|
+
};
|
|
12
|
+
export declare function ledger(parameters?: LedgerParameters): import("@wagmi/core").CreateConnectorFn<EthereumProvider, {
|
|
13
|
+
onConnect(connectInfo: ProviderConnectInfo): void;
|
|
14
|
+
onSessionDelete(data: {
|
|
15
|
+
topic: string;
|
|
16
|
+
}): void;
|
|
17
|
+
}, {}>;
|
|
18
|
+
//# sourceMappingURL=ledger.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ledger.d.ts","sourceRoot":"","sources":["../../src/ledger.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,gBAAgB,EAGtB,MAAM,8BAA8B,CAAA;AAMrC,OAAO,EACL,KAAK,mBAAmB,EAMzB,MAAM,MAAM,CAAA;AAEb,MAAM,MAAM,gBAAgB,GAAG;IAC7B,eAAe,CAAC,EAAE,OAAO,GAAG,SAAS,CAAA;IACrC,cAAc,CAAC,EAAE,MAAM,EAAE,GAAG,SAAS,CAAA;IACrC,eAAe,CAAC,EAAE,MAAM,EAAE,GAAG,SAAS,CAAA;IACtC,SAAS,CAAC,EAAE,MAAM,GAAG,SAAS,CAAA;IAC9B,cAAc,CAAC,EAAE,MAAM,EAAE,GAAG,SAAS,CAAA;IACrC,cAAc,CAAC,EAAE,MAAM,EAAE,GAAG,SAAS,CAAA;IACrC,eAAe,CAAC,EAAE,MAAM,EAAE,GAAG,SAAS,CAAA;CACvC,CAAA;AAED,wBAAgB,MAAM,CAAC,UAAU,GAAE,gBAAqB;2BAG7B,mBAAmB,GAAG,IAAI;0BAC3B;QAAE,KAAK,EAAE,MAAM,CAAA;KAAE,GAAG,IAAI;OAgLjD"}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { SafeAppProvider } from '@safe-global/safe-apps-provider';
|
|
2
|
+
import { type Opts } from '@safe-global/safe-apps-sdk';
|
|
3
|
+
import type { Evaluate } from '@wagmi/core/internal';
|
|
4
|
+
export type SafeParameters = Evaluate<Opts & {
|
|
5
|
+
/**
|
|
6
|
+
* Connector automatically connects when used as Safe App.
|
|
7
|
+
*
|
|
8
|
+
* This flag simulates the disconnect behavior by keeping track of connection status in storage
|
|
9
|
+
* and only autoconnecting when previously connected by user action (e.g. explicitly choosing to connect).
|
|
10
|
+
*
|
|
11
|
+
* @default false
|
|
12
|
+
*/
|
|
13
|
+
shimDisconnect?: boolean | undefined;
|
|
14
|
+
}>;
|
|
15
|
+
export declare function safe(parameters?: SafeParameters): import("@wagmi/core").CreateConnectorFn<SafeAppProvider, {}, {
|
|
16
|
+
'safe.shimDisconnect': true;
|
|
17
|
+
}>;
|
|
18
|
+
//# sourceMappingURL=safe.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"safe.d.ts","sourceRoot":"","sources":["../../src/safe.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAE,MAAM,iCAAiC,CAAA;AACjE,OAAO,EAAE,KAAK,IAAI,EAA0B,MAAM,4BAA4B,CAAA;AAG9E,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,sBAAsB,CAAA;AAGpD,MAAM,MAAM,cAAc,GAAG,QAAQ,CACnC,IAAI,GAAG;IACL;;;;;;;OAOG;IACH,cAAc,CAAC,EAAE,OAAO,GAAG,SAAS,CAAA;CACrC,CACF,CAAA;AAED,wBAAgB,IAAI,CAAC,UAAU,GAAE,cAAmB;2BAGN,IAAI;GAyFjD"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"version.d.ts","sourceRoot":"","sources":["../../src/version.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,OAAO,kBAAkB,CAAA"}
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
import type { Evaluate, ExactPartial, Omit } from '@wagmi/core/internal';
|
|
2
|
+
import { EthereumProvider } from '@walletconnect/ethereum-provider';
|
|
3
|
+
import { type Address, type ProviderConnectInfo } from 'viem';
|
|
4
|
+
type EthereumProviderOptions = Parameters<typeof EthereumProvider['init']>[0];
|
|
5
|
+
export type WalletConnectParameters = Evaluate<{
|
|
6
|
+
/**
|
|
7
|
+
* If a new chain is added to a previously existing configured connector `chains`, this flag
|
|
8
|
+
* will determine if that chain should be considered as stale. A stale chain is a chain that
|
|
9
|
+
* WalletConnect has yet to establish a relationship with (ie. the user has not approved or
|
|
10
|
+
* rejected the chain).
|
|
11
|
+
*
|
|
12
|
+
* Preface: Whereas WalletConnect v1 supported dynamic chain switching, WalletConnect v2 requires
|
|
13
|
+
* the user to pre-approve a set of chains up-front. This comes with consequent UX nuances (see below) when
|
|
14
|
+
* a user tries to switch to a chain that they have not approved.
|
|
15
|
+
*
|
|
16
|
+
* This flag mainly affects the behavior when a wallet does not support dynamic chain authorization
|
|
17
|
+
* with WalletConnect v2.
|
|
18
|
+
*
|
|
19
|
+
* If `true` (default), the new chain will be treated as a stale chain. If the user
|
|
20
|
+
* has yet to establish a relationship (approved/rejected) with this chain in their WalletConnect
|
|
21
|
+
* session, the connector will disconnect upon the dapp auto-connecting, and the user will have to
|
|
22
|
+
* reconnect to the dapp (revalidate the chain) in order to approve the newly added chain.
|
|
23
|
+
* This is the default behavior to avoid an unexpected error upon switching chains which may
|
|
24
|
+
* be a confusing user experience (ie. the user will not know they have to reconnect
|
|
25
|
+
* unless the dapp handles these types of errors).
|
|
26
|
+
*
|
|
27
|
+
* If `false`, the new chain will be treated as a validated chain. This means that if the user
|
|
28
|
+
* has yet to establish a relationship with the chain in their WalletConnect session, wagmi will successfully
|
|
29
|
+
* auto-connect the user. This comes with the trade-off that the connector will throw an error
|
|
30
|
+
* when attempting to switch to the unapproved chain. This may be useful in cases where a dapp constantly
|
|
31
|
+
* modifies their configured chains, and they do not want to disconnect the user upon
|
|
32
|
+
* auto-connecting. If the user decides to switch to the unapproved chain, it is important that the
|
|
33
|
+
* dapp handles this error and prompts the user to reconnect to the dapp in order to approve
|
|
34
|
+
* the newly added chain.
|
|
35
|
+
*
|
|
36
|
+
* @default true
|
|
37
|
+
*/
|
|
38
|
+
isNewChainsStale?: boolean;
|
|
39
|
+
} & Omit<EthereumProviderOptions, 'chains' | 'events' | 'optionalChains' | 'optionalEvents' | 'optionalMethods' | 'methods' | 'rpcMap' | 'showQrModal'> & ExactPartial<Pick<EthereumProviderOptions, 'showQrModal'>>>;
|
|
40
|
+
export declare function walletConnect(parameters: WalletConnectParameters): import("@wagmi/core").CreateConnectorFn<import("@walletconnect/ethereum-provider").default, {
|
|
41
|
+
connect(parameters?: {
|
|
42
|
+
chainId?: number;
|
|
43
|
+
pairingTopic?: string;
|
|
44
|
+
}): Promise<{
|
|
45
|
+
accounts: readonly Address[];
|
|
46
|
+
chainId: number;
|
|
47
|
+
}>;
|
|
48
|
+
getNamespaceChainsIds(): number[];
|
|
49
|
+
getNamespaceMethods(): ("wallet_switchEthereumChain" | "wallet_addEthereumChain")[];
|
|
50
|
+
getRequestedChainsIds(): Promise<number[]>;
|
|
51
|
+
isChainsStale(): Promise<boolean>;
|
|
52
|
+
onConnect(connectInfo: ProviderConnectInfo): void;
|
|
53
|
+
onDisplayUri(uri: string): void;
|
|
54
|
+
onSessionDelete(data: {
|
|
55
|
+
topic: string;
|
|
56
|
+
}): void;
|
|
57
|
+
setRequestedChainsIds(chains: number[]): void;
|
|
58
|
+
requestedChainsStorageKey: `${string}.requestedChains`;
|
|
59
|
+
}, {
|
|
60
|
+
[x: `${string}.requestedChains`]: number[];
|
|
61
|
+
}>;
|
|
62
|
+
export {};
|
|
63
|
+
//# sourceMappingURL=walletConnect.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"walletConnect.d.ts","sourceRoot":"","sources":["../../src/walletConnect.ts"],"names":[],"mappings":"AAMA,OAAO,KAAK,EAAE,QAAQ,EAAE,YAAY,EAAE,IAAI,EAAE,MAAM,sBAAsB,CAAA;AACxE,OAAO,EACL,gBAAgB,EAGjB,MAAM,kCAAkC,CAAA;AACzC,OAAO,EACL,KAAK,OAAO,EACZ,KAAK,mBAAmB,EAMzB,MAAM,MAAM,CAAA;AAEb,KAAK,uBAAuB,GAAG,UAAU,CAAC,OAAO,gBAAgB,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,CAAC,CAAA;AAE7E,MAAM,MAAM,uBAAuB,GAAG,QAAQ,CAC5C;IACE;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;OA+BG;IACH,gBAAgB,CAAC,EAAE,OAAO,CAAA;CAC3B,GAAG,IAAI,CACN,uBAAuB,EACrB,QAAQ,GACR,QAAQ,GACR,gBAAgB,GAChB,gBAAgB,GAChB,iBAAiB,GACjB,SAAS,GACT,QAAQ,GACR,aAAa,CAChB,GACC,YAAY,CAAC,IAAI,CAAC,uBAAuB,EAAE,aAAa,CAAC,CAAC,CAC7D,CAAA;AAED,wBAAgB,aAAa,CAAC,UAAU,EAAE,uBAAuB;yBAQxC;QAAE,OAAO,CAAC,EAAE,MAAM,CAAC;QAAC,YAAY,CAAC,EAAE,MAAM,CAAA;KAAE,GAAG,QAAQ;QACzE,QAAQ,EAAE,SAAS,OAAO,EAAE,CAAA;QAC5B,OAAO,EAAE,MAAM,CAAA;KAChB,CAAC;6BACuB,MAAM,EAAE;;6BAER,QAAQ,MAAM,EAAE,CAAC;qBACzB,QAAQ,OAAO,CAAC;2BACV,mBAAmB,GAAG,IAAI;sBAC/B,MAAM,GAAG,IAAI;0BACT;QAAE,KAAK,EAAE,MAAM,CAAA;KAAE,GAAG,IAAI;kCAChB,MAAM,EAAE,GAAG,IAAI;+BAClB,GAAG,MAAM,kBAAkB;;;GA4SzD"}
|
package/package.json
CHANGED
|
@@ -1,11 +1,36 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@wagmi/connectors",
|
|
3
3
|
"description": "A collection of connectors for wagmi",
|
|
4
|
+
"version": "4.0.0-alpha.0",
|
|
4
5
|
"license": "MIT",
|
|
5
|
-
"
|
|
6
|
+
"repository": {
|
|
7
|
+
"type": "git",
|
|
8
|
+
"url": "https://github.com/wagmi-dev/wagmi.git",
|
|
9
|
+
"directory": "packages/connectors"
|
|
10
|
+
},
|
|
11
|
+
"files": [
|
|
12
|
+
"dist/**",
|
|
13
|
+
"!dist/**/*.tsbuildinfo",
|
|
14
|
+
"src/**/*.ts",
|
|
15
|
+
"!src/**/*.test.ts",
|
|
16
|
+
"!src/**/*.test-d.ts"
|
|
17
|
+
],
|
|
18
|
+
"sideEffects": false,
|
|
19
|
+
"type": "module",
|
|
20
|
+
"main": "./dist/esm/index.js",
|
|
21
|
+
"types": "./dist/types/index.d.ts",
|
|
22
|
+
"typings": "./dist/types/index.d.ts",
|
|
23
|
+
"exports": {
|
|
24
|
+
".": {
|
|
25
|
+
"types": "./dist/types/index.d.ts",
|
|
26
|
+
"default": "./dist/esm/index.js"
|
|
27
|
+
},
|
|
28
|
+
"./package.json": "./package.json"
|
|
29
|
+
},
|
|
6
30
|
"peerDependencies": {
|
|
7
|
-
"typescript": ">=5
|
|
8
|
-
"viem": "
|
|
31
|
+
"typescript": ">=5",
|
|
32
|
+
"viem": ">2.0.0-alpha.0",
|
|
33
|
+
"@wagmi/core": "2.0.0-alpha.0"
|
|
9
34
|
},
|
|
10
35
|
"peerDependenciesMeta": {
|
|
11
36
|
"typescript": {
|
|
@@ -13,94 +38,28 @@
|
|
|
13
38
|
}
|
|
14
39
|
},
|
|
15
40
|
"dependencies": {
|
|
16
|
-
"@coinbase/wallet-sdk": "
|
|
17
|
-
"@ledgerhq/connect-kit-loader": "^1.1.
|
|
18
|
-
"@safe-global/safe-apps-provider": "^0.
|
|
19
|
-
"@safe-global/safe-apps-sdk": "^8.
|
|
20
|
-
"@walletconnect/ethereum-provider": "2.10.0",
|
|
21
|
-
"@walletconnect/
|
|
22
|
-
"@walletconnect/legacy-provider": "^2.0.0",
|
|
23
|
-
"@walletconnect/modal": "2.6.1",
|
|
24
|
-
"abitype": "0.8.7",
|
|
25
|
-
"eventemitter3": "^4.0.7"
|
|
41
|
+
"@coinbase/wallet-sdk": "3.8.0-beta.2",
|
|
42
|
+
"@ledgerhq/connect-kit-loader": "^1.1.2",
|
|
43
|
+
"@safe-global/safe-apps-provider": "^0.18.0",
|
|
44
|
+
"@safe-global/safe-apps-sdk": "^8.1.0",
|
|
45
|
+
"@walletconnect/ethereum-provider": "^2.10.0",
|
|
46
|
+
"@walletconnect/modal": "^2.6.2"
|
|
26
47
|
},
|
|
27
48
|
"devDependencies": {
|
|
28
|
-
"
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
"types": "dist/index.d.ts",
|
|
32
|
-
"exports": {
|
|
33
|
-
".": {
|
|
34
|
-
"types": "./dist/index.d.ts",
|
|
35
|
-
"default": "./dist/index.js"
|
|
36
|
-
},
|
|
37
|
-
"./coinbaseWallet": {
|
|
38
|
-
"types": "./dist/coinbaseWallet.d.ts",
|
|
39
|
-
"default": "./dist/coinbaseWallet.js"
|
|
40
|
-
},
|
|
41
|
-
"./injected": {
|
|
42
|
-
"types": "./dist/injected.d.ts",
|
|
43
|
-
"default": "./dist/injected.js"
|
|
44
|
-
},
|
|
45
|
-
"./ledger": {
|
|
46
|
-
"types": "./dist/ledger.d.ts",
|
|
47
|
-
"default": "./dist/ledger.js"
|
|
48
|
-
},
|
|
49
|
-
"./metaMask": {
|
|
50
|
-
"types": "./dist/metaMask.d.ts",
|
|
51
|
-
"default": "./dist/metaMask.js"
|
|
52
|
-
},
|
|
53
|
-
"./mock": {
|
|
54
|
-
"types": "./dist/mock/index.d.ts",
|
|
55
|
-
"default": "./dist/mock/index.js"
|
|
56
|
-
},
|
|
57
|
-
"./safe": {
|
|
58
|
-
"types": "./dist/safe.d.ts",
|
|
59
|
-
"default": "./dist/safe.js"
|
|
60
|
-
},
|
|
61
|
-
"./walletConnect": {
|
|
62
|
-
"types": "./dist/walletConnect.d.ts",
|
|
63
|
-
"default": "./dist/walletConnect.js"
|
|
64
|
-
},
|
|
65
|
-
"./walletConnectLegacy": {
|
|
66
|
-
"types": "./dist/walletConnectLegacy.d.ts",
|
|
67
|
-
"default": "./dist/walletConnectLegacy.js"
|
|
68
|
-
},
|
|
69
|
-
"./package.json": "./package.json"
|
|
49
|
+
"lokijs": "^1.5.12",
|
|
50
|
+
"msw": "^1.3.0",
|
|
51
|
+
"@wagmi/core": "2.0.0-alpha.0"
|
|
70
52
|
},
|
|
71
|
-
"files": [
|
|
72
|
-
"/coinbaseWallet",
|
|
73
|
-
"/injected",
|
|
74
|
-
"/ledger",
|
|
75
|
-
"/metaMask",
|
|
76
|
-
"/mock",
|
|
77
|
-
"/safe",
|
|
78
|
-
"/walletConnect",
|
|
79
|
-
"/walletConnectLegacy",
|
|
80
|
-
"/dist"
|
|
81
|
-
],
|
|
82
|
-
"sideEffects": false,
|
|
83
53
|
"contributors": [
|
|
84
|
-
"
|
|
85
|
-
"
|
|
54
|
+
"jxom.eth <j@wagmi.sh>",
|
|
55
|
+
"awkweb.eth <t@wagmi.sh>"
|
|
86
56
|
],
|
|
87
|
-
"homepage": "https://wagmi.sh",
|
|
88
|
-
"ethereum": "wagmi-dev.eth",
|
|
89
57
|
"funding": [
|
|
90
|
-
{
|
|
91
|
-
"type": "gitcoin",
|
|
92
|
-
"url": "https://wagmi.sh/gitcoin"
|
|
93
|
-
},
|
|
94
58
|
{
|
|
95
59
|
"type": "github",
|
|
96
60
|
"url": "https://github.com/sponsors/wagmi-dev"
|
|
97
61
|
}
|
|
98
62
|
],
|
|
99
|
-
"repository": {
|
|
100
|
-
"type": "git",
|
|
101
|
-
"url": "https://github.com/wagmi-dev/references.git",
|
|
102
|
-
"directory": "packages/connectors"
|
|
103
|
-
},
|
|
104
63
|
"keywords": [
|
|
105
64
|
"react",
|
|
106
65
|
"hooks",
|
|
@@ -112,7 +71,10 @@
|
|
|
112
71
|
"abi"
|
|
113
72
|
],
|
|
114
73
|
"scripts": {
|
|
115
|
-
"
|
|
116
|
-
"
|
|
74
|
+
"clean": "rm -rf dist tsconfig.tsbuildinfo",
|
|
75
|
+
"build": "pnpm run clean && pnpm run build:esm+types",
|
|
76
|
+
"build:esm+types": "tsc --project tsconfig.build.json --module es2020 --outDir ./dist/esm --declaration --declarationMap --declarationDir ./dist/types",
|
|
77
|
+
"test:build": "publint --strict",
|
|
78
|
+
"typecheck": "tsc --noEmit"
|
|
117
79
|
}
|
|
118
80
|
}
|