@wagmi/connectors 1.0.1 → 1.0.2
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/LICENSE +1 -1
- package/dist/{chunk-HIOOQYJ7.js → chunk-VPDCYC2X.js} +1 -1
- package/dist/coinbaseWallet.d.ts +6 -6
- package/dist/coinbaseWallet.js +1 -1
- package/dist/injected.d.ts +6 -6
- package/dist/injected.js +1 -1
- package/dist/ledger.d.ts +6 -6
- package/dist/ledger.js +1 -1
- package/dist/metaMask.js +1 -1
- package/dist/mock/index.d.ts +8 -8
- package/dist/safe.d.ts +10 -10
- package/dist/safe.js +1 -1
- package/dist/walletConnect.d.ts +10 -54
- package/dist/walletConnect.js +1 -1
- package/dist/walletConnectLegacy.d.ts +10 -10
- package/dist/walletConnectLegacy.js +1 -1
- package/package.json +1 -1
package/LICENSE
CHANGED
|
@@ -256,7 +256,7 @@ var InjectedConnector = class extends Connector {
|
|
|
256
256
|
this.getProvider(),
|
|
257
257
|
this.getAccount()
|
|
258
258
|
]);
|
|
259
|
-
const chain = this.chains.find((x) => x.id === chainId)
|
|
259
|
+
const chain = this.chains.find((x) => x.id === chainId);
|
|
260
260
|
if (!provider)
|
|
261
261
|
throw new Error("provider is required.");
|
|
262
262
|
return createWalletClient({
|
package/dist/coinbaseWallet.d.ts
CHANGED
|
@@ -541,13 +541,14 @@ declare class CoinbaseWalletConnector extends Connector<CoinbaseWalletProvider,
|
|
|
541
541
|
[x: `address[${string}]`]: undefined;
|
|
542
542
|
[x: `bool[${string}]`]: undefined;
|
|
543
543
|
[x: `bytes[${string}]`]: undefined;
|
|
544
|
+
[x: `bytes5[${string}]`]: undefined;
|
|
545
|
+
[x: `bytes1[${string}]`]: undefined;
|
|
546
|
+
[x: `bytes18[${string}]`]: undefined;
|
|
544
547
|
[x: `bytes2[${string}]`]: undefined;
|
|
545
548
|
[x: `bytes16[${string}]`]: undefined;
|
|
546
549
|
[x: `bytes10[${string}]`]: undefined;
|
|
547
|
-
[x: `bytes1[${string}]`]: undefined;
|
|
548
550
|
[x: `bytes3[${string}]`]: undefined;
|
|
549
551
|
[x: `bytes4[${string}]`]: undefined;
|
|
550
|
-
[x: `bytes5[${string}]`]: undefined;
|
|
551
552
|
[x: `bytes6[${string}]`]: undefined;
|
|
552
553
|
[x: `bytes7[${string}]`]: undefined;
|
|
553
554
|
[x: `bytes8[${string}]`]: undefined;
|
|
@@ -558,7 +559,6 @@ declare class CoinbaseWalletConnector extends Connector<CoinbaseWalletProvider,
|
|
|
558
559
|
[x: `bytes14[${string}]`]: undefined;
|
|
559
560
|
[x: `bytes15[${string}]`]: undefined;
|
|
560
561
|
[x: `bytes17[${string}]`]: undefined;
|
|
561
|
-
[x: `bytes18[${string}]`]: undefined;
|
|
562
562
|
[x: `bytes19[${string}]`]: undefined;
|
|
563
563
|
[x: `bytes20[${string}]`]: undefined;
|
|
564
564
|
[x: `bytes21[${string}]`]: undefined;
|
|
@@ -643,13 +643,14 @@ declare class CoinbaseWalletConnector extends Connector<CoinbaseWalletProvider,
|
|
|
643
643
|
address?: undefined;
|
|
644
644
|
bool?: undefined;
|
|
645
645
|
bytes?: undefined;
|
|
646
|
+
bytes5?: undefined;
|
|
647
|
+
bytes1?: undefined;
|
|
648
|
+
bytes18?: undefined;
|
|
646
649
|
bytes2?: undefined;
|
|
647
650
|
bytes16?: undefined;
|
|
648
651
|
bytes10?: undefined;
|
|
649
|
-
bytes1?: undefined;
|
|
650
652
|
bytes3?: undefined;
|
|
651
653
|
bytes4?: undefined;
|
|
652
|
-
bytes5?: undefined;
|
|
653
654
|
bytes6?: undefined;
|
|
654
655
|
bytes7?: undefined;
|
|
655
656
|
bytes8?: undefined;
|
|
@@ -660,7 +661,6 @@ declare class CoinbaseWalletConnector extends Connector<CoinbaseWalletProvider,
|
|
|
660
661
|
bytes14?: undefined;
|
|
661
662
|
bytes15?: undefined;
|
|
662
663
|
bytes17?: undefined;
|
|
663
|
-
bytes18?: undefined;
|
|
664
664
|
bytes19?: undefined;
|
|
665
665
|
bytes20?: undefined;
|
|
666
666
|
bytes21?: undefined;
|
package/dist/coinbaseWallet.js
CHANGED
|
@@ -126,7 +126,7 @@ var CoinbaseWalletConnector = class extends Connector {
|
|
|
126
126
|
this.getProvider(),
|
|
127
127
|
this.getAccount()
|
|
128
128
|
]);
|
|
129
|
-
const chain = this.chains.find((x) => x.id === chainId)
|
|
129
|
+
const chain = this.chains.find((x) => x.id === chainId);
|
|
130
130
|
if (!provider)
|
|
131
131
|
throw new Error("provider is required.");
|
|
132
132
|
return createWalletClient({
|
package/dist/injected.d.ts
CHANGED
|
@@ -542,13 +542,14 @@ declare class InjectedConnector extends Connector<WindowProvider | undefined, Co
|
|
|
542
542
|
[x: `address[${string}]`]: undefined;
|
|
543
543
|
[x: `bool[${string}]`]: undefined;
|
|
544
544
|
[x: `bytes[${string}]`]: undefined;
|
|
545
|
+
[x: `bytes5[${string}]`]: undefined;
|
|
546
|
+
[x: `bytes1[${string}]`]: undefined;
|
|
547
|
+
[x: `bytes18[${string}]`]: undefined;
|
|
545
548
|
[x: `bytes2[${string}]`]: undefined;
|
|
546
549
|
[x: `bytes16[${string}]`]: undefined;
|
|
547
550
|
[x: `bytes10[${string}]`]: undefined;
|
|
548
|
-
[x: `bytes1[${string}]`]: undefined;
|
|
549
551
|
[x: `bytes3[${string}]`]: undefined;
|
|
550
552
|
[x: `bytes4[${string}]`]: undefined;
|
|
551
|
-
[x: `bytes5[${string}]`]: undefined;
|
|
552
553
|
[x: `bytes6[${string}]`]: undefined;
|
|
553
554
|
[x: `bytes7[${string}]`]: undefined;
|
|
554
555
|
[x: `bytes8[${string}]`]: undefined;
|
|
@@ -559,7 +560,6 @@ declare class InjectedConnector extends Connector<WindowProvider | undefined, Co
|
|
|
559
560
|
[x: `bytes14[${string}]`]: undefined;
|
|
560
561
|
[x: `bytes15[${string}]`]: undefined;
|
|
561
562
|
[x: `bytes17[${string}]`]: undefined;
|
|
562
|
-
[x: `bytes18[${string}]`]: undefined;
|
|
563
563
|
[x: `bytes19[${string}]`]: undefined;
|
|
564
564
|
[x: `bytes20[${string}]`]: undefined;
|
|
565
565
|
[x: `bytes21[${string}]`]: undefined;
|
|
@@ -644,13 +644,14 @@ declare class InjectedConnector extends Connector<WindowProvider | undefined, Co
|
|
|
644
644
|
address?: undefined;
|
|
645
645
|
bool?: undefined;
|
|
646
646
|
bytes?: undefined;
|
|
647
|
+
bytes5?: undefined;
|
|
648
|
+
bytes1?: undefined;
|
|
649
|
+
bytes18?: undefined;
|
|
647
650
|
bytes2?: undefined;
|
|
648
651
|
bytes16?: undefined;
|
|
649
652
|
bytes10?: undefined;
|
|
650
|
-
bytes1?: undefined;
|
|
651
653
|
bytes3?: undefined;
|
|
652
654
|
bytes4?: undefined;
|
|
653
|
-
bytes5?: undefined;
|
|
654
655
|
bytes6?: undefined;
|
|
655
656
|
bytes7?: undefined;
|
|
656
657
|
bytes8?: undefined;
|
|
@@ -661,7 +662,6 @@ declare class InjectedConnector extends Connector<WindowProvider | undefined, Co
|
|
|
661
662
|
bytes14?: undefined;
|
|
662
663
|
bytes15?: undefined;
|
|
663
664
|
bytes17?: undefined;
|
|
664
|
-
bytes18?: undefined;
|
|
665
665
|
bytes19?: undefined;
|
|
666
666
|
bytes20?: undefined;
|
|
667
667
|
bytes21?: undefined;
|
package/dist/injected.js
CHANGED
package/dist/ledger.d.ts
CHANGED
|
@@ -527,13 +527,14 @@ declare class LedgerConnector extends Connector<EthereumProvider, LedgerConnecto
|
|
|
527
527
|
[x: `address[${string}]`]: undefined;
|
|
528
528
|
[x: `bool[${string}]`]: undefined;
|
|
529
529
|
[x: `bytes[${string}]`]: undefined;
|
|
530
|
+
[x: `bytes5[${string}]`]: undefined;
|
|
531
|
+
[x: `bytes1[${string}]`]: undefined;
|
|
532
|
+
[x: `bytes18[${string}]`]: undefined;
|
|
530
533
|
[x: `bytes2[${string}]`]: undefined;
|
|
531
534
|
[x: `bytes16[${string}]`]: undefined;
|
|
532
535
|
[x: `bytes10[${string}]`]: undefined;
|
|
533
|
-
[x: `bytes1[${string}]`]: undefined;
|
|
534
536
|
[x: `bytes3[${string}]`]: undefined;
|
|
535
537
|
[x: `bytes4[${string}]`]: undefined;
|
|
536
|
-
[x: `bytes5[${string}]`]: undefined;
|
|
537
538
|
[x: `bytes6[${string}]`]: undefined;
|
|
538
539
|
[x: `bytes7[${string}]`]: undefined;
|
|
539
540
|
[x: `bytes8[${string}]`]: undefined;
|
|
@@ -544,7 +545,6 @@ declare class LedgerConnector extends Connector<EthereumProvider, LedgerConnecto
|
|
|
544
545
|
[x: `bytes14[${string}]`]: undefined;
|
|
545
546
|
[x: `bytes15[${string}]`]: undefined;
|
|
546
547
|
[x: `bytes17[${string}]`]: undefined;
|
|
547
|
-
[x: `bytes18[${string}]`]: undefined;
|
|
548
548
|
[x: `bytes19[${string}]`]: undefined;
|
|
549
549
|
[x: `bytes20[${string}]`]: undefined;
|
|
550
550
|
[x: `bytes21[${string}]`]: undefined;
|
|
@@ -629,13 +629,14 @@ declare class LedgerConnector extends Connector<EthereumProvider, LedgerConnecto
|
|
|
629
629
|
address?: undefined;
|
|
630
630
|
bool?: undefined;
|
|
631
631
|
bytes?: undefined;
|
|
632
|
+
bytes5?: undefined;
|
|
633
|
+
bytes1?: undefined;
|
|
634
|
+
bytes18?: undefined;
|
|
632
635
|
bytes2?: undefined;
|
|
633
636
|
bytes16?: undefined;
|
|
634
637
|
bytes10?: undefined;
|
|
635
|
-
bytes1?: undefined;
|
|
636
638
|
bytes3?: undefined;
|
|
637
639
|
bytes4?: undefined;
|
|
638
|
-
bytes5?: undefined;
|
|
639
640
|
bytes6?: undefined;
|
|
640
641
|
bytes7?: undefined;
|
|
641
642
|
bytes8?: undefined;
|
|
@@ -646,7 +647,6 @@ declare class LedgerConnector extends Connector<EthereumProvider, LedgerConnecto
|
|
|
646
647
|
bytes14?: undefined;
|
|
647
648
|
bytes15?: undefined;
|
|
648
649
|
bytes17?: undefined;
|
|
649
|
-
bytes18?: undefined;
|
|
650
650
|
bytes19?: undefined;
|
|
651
651
|
bytes20?: undefined;
|
|
652
652
|
bytes21?: undefined;
|
package/dist/ledger.js
CHANGED
|
@@ -137,7 +137,7 @@ var LedgerConnector = class extends Connector {
|
|
|
137
137
|
this.getProvider({ chainId }),
|
|
138
138
|
this.getAccount()
|
|
139
139
|
]);
|
|
140
|
-
const chain = this.chains.find((x) => x.id === chainId)
|
|
140
|
+
const chain = this.chains.find((x) => x.id === chainId);
|
|
141
141
|
if (!provider)
|
|
142
142
|
throw new Error("provider is required.");
|
|
143
143
|
return createWalletClient({
|
package/dist/metaMask.js
CHANGED
package/dist/mock/index.d.ts
CHANGED
|
@@ -496,7 +496,7 @@ declare class MockProvider {
|
|
|
496
496
|
type: string;
|
|
497
497
|
uid: string;
|
|
498
498
|
addChain: (args: viem.AddChainParameters) => Promise<void>;
|
|
499
|
-
deployContract: <TAbi extends
|
|
499
|
+
deployContract: <TAbi extends readonly unknown[] | abitype_dist_abi_3a9c20c7.l, TChainOverride extends viem.Chain<viem_dist_types_types_formatter.Formatters> | undefined>(args: viem.DeployContractParameters<TAbi, viem.Chain<viem_dist_types_types_formatter.Formatters>, viem.Account<`0x${string}`>, TChainOverride>) => Promise<`0x${string}`>;
|
|
500
500
|
getAddresses: () => Promise<viem.GetAddressesReturnType>;
|
|
501
501
|
getChainId: () => Promise<number>;
|
|
502
502
|
getPermissions: () => Promise<viem.GetPermissionsReturnType>;
|
|
@@ -508,8 +508,6 @@ declare class MockProvider {
|
|
|
508
508
|
sendTransaction: <TChainOverride_1 extends viem.Chain<viem_dist_types_types_formatter.Formatters> | undefined>(args: viem.SendTransactionParameters<viem.Chain<viem_dist_types_types_formatter.Formatters>, viem.Account<`0x${string}`>, TChainOverride_1>) => Promise<`0x${string}`>;
|
|
509
509
|
signMessage: (args: viem.SignMessageParameters<viem.Account<`0x${string}`>>) => Promise<`0x${string}`>;
|
|
510
510
|
signTypedData: <TTypedData extends {
|
|
511
|
-
[key: string]: unknown;
|
|
512
|
-
} | {
|
|
513
511
|
[x: string]: readonly abitype_dist_abi_3a9c20c7.o[];
|
|
514
512
|
[x: `string[${string}]`]: undefined;
|
|
515
513
|
[x: `function[${string}]`]: undefined;
|
|
@@ -714,10 +712,12 @@ declare class MockProvider {
|
|
|
714
712
|
uint240?: undefined;
|
|
715
713
|
uint248?: undefined;
|
|
716
714
|
uint256?: undefined;
|
|
715
|
+
} | {
|
|
716
|
+
[key: string]: unknown;
|
|
717
717
|
}, TPrimaryType extends string>(args: viem.SignTypedDataParameters<TTypedData, TPrimaryType, viem.Account<`0x${string}`>>) => Promise<`0x${string}`>;
|
|
718
718
|
switchChain: (args: viem.SwitchChainParameters) => Promise<void>;
|
|
719
719
|
watchAsset: (args: viem_dist_types_types_eip1193.WatchAssetParams) => Promise<boolean>;
|
|
720
|
-
writeContract: <TAbi_1 extends
|
|
720
|
+
writeContract: <TAbi_1 extends readonly unknown[] | abitype_dist_abi_3a9c20c7.l, TFunctionName extends string, TChainOverride_2 extends viem.Chain<viem_dist_types_types_formatter.Formatters> | undefined>(args: viem.WriteContractParameters<TAbi_1, TFunctionName, viem.Chain<viem_dist_types_types_formatter.Formatters>, viem.Account<`0x${string}`>, TChainOverride_2>) => Promise<`0x${string}`>;
|
|
721
721
|
account: viem.Account<`0x${string}`>;
|
|
722
722
|
};
|
|
723
723
|
switchChain(chainId: number): Promise<void>;
|
|
@@ -1219,7 +1219,7 @@ declare class MockConnector extends Connector<MockProvider, MockConnectorOptions
|
|
|
1219
1219
|
type: string;
|
|
1220
1220
|
uid: string;
|
|
1221
1221
|
addChain: (args: viem.AddChainParameters) => Promise<void>;
|
|
1222
|
-
deployContract: <TAbi extends
|
|
1222
|
+
deployContract: <TAbi extends readonly unknown[] | abitype_dist_abi_3a9c20c7.l, TChainOverride extends viem.Chain<viem_dist_types_types_formatter.Formatters> | undefined>(args: viem.DeployContractParameters<TAbi, viem.Chain<viem_dist_types_types_formatter.Formatters>, viem.Account<`0x${string}`>, TChainOverride>) => Promise<`0x${string}`>;
|
|
1223
1223
|
getAddresses: () => Promise<viem.GetAddressesReturnType>;
|
|
1224
1224
|
getChainId: () => Promise<number>;
|
|
1225
1225
|
getPermissions: () => Promise<viem.GetPermissionsReturnType>;
|
|
@@ -1231,8 +1231,6 @@ declare class MockConnector extends Connector<MockProvider, MockConnectorOptions
|
|
|
1231
1231
|
sendTransaction: <TChainOverride_1 extends viem.Chain<viem_dist_types_types_formatter.Formatters> | undefined>(args: viem.SendTransactionParameters<viem.Chain<viem_dist_types_types_formatter.Formatters>, viem.Account<`0x${string}`>, TChainOverride_1>) => Promise<`0x${string}`>;
|
|
1232
1232
|
signMessage: (args: viem.SignMessageParameters<viem.Account<`0x${string}`>>) => Promise<`0x${string}`>;
|
|
1233
1233
|
signTypedData: <TTypedData extends {
|
|
1234
|
-
[key: string]: unknown;
|
|
1235
|
-
} | {
|
|
1236
1234
|
[x: string]: readonly abitype_dist_abi_3a9c20c7.o[];
|
|
1237
1235
|
[x: `string[${string}]`]: undefined;
|
|
1238
1236
|
[x: `function[${string}]`]: undefined;
|
|
@@ -1437,10 +1435,12 @@ declare class MockConnector extends Connector<MockProvider, MockConnectorOptions
|
|
|
1437
1435
|
uint240?: undefined;
|
|
1438
1436
|
uint248?: undefined;
|
|
1439
1437
|
uint256?: undefined;
|
|
1438
|
+
} | {
|
|
1439
|
+
[key: string]: unknown;
|
|
1440
1440
|
}, TPrimaryType extends string>(args: viem.SignTypedDataParameters<TTypedData, TPrimaryType, viem.Account<`0x${string}`>>) => Promise<`0x${string}`>;
|
|
1441
1441
|
switchChain: (args: viem.SwitchChainParameters) => Promise<void>;
|
|
1442
1442
|
watchAsset: (args: viem_dist_types_types_eip1193.WatchAssetParams) => Promise<boolean>;
|
|
1443
|
-
writeContract: <TAbi_1 extends
|
|
1443
|
+
writeContract: <TAbi_1 extends readonly unknown[] | abitype_dist_abi_3a9c20c7.l, TFunctionName extends string, TChainOverride_2 extends viem.Chain<viem_dist_types_types_formatter.Formatters> | undefined>(args: viem.WriteContractParameters<TAbi_1, TFunctionName, viem.Chain<viem_dist_types_types_formatter.Formatters>, viem.Account<`0x${string}`>, TChainOverride_2>) => Promise<`0x${string}`>;
|
|
1444
1444
|
account: viem.Account<`0x${string}`>;
|
|
1445
1445
|
}>;
|
|
1446
1446
|
isAuthorized(): Promise<boolean>;
|
package/dist/safe.d.ts
CHANGED
|
@@ -129,7 +129,7 @@ declare class SafeConnector extends Connector<SafeConnectorProvider, SafeConnect
|
|
|
129
129
|
(args: {
|
|
130
130
|
method: "eth_getFilterChanges";
|
|
131
131
|
params: [filterId: `0x${string}`];
|
|
132
|
-
}): Promise
|
|
132
|
+
}): Promise<`0x${string}`[] | viem.RpcLog[]>;
|
|
133
133
|
(args: {
|
|
134
134
|
method: "eth_getFilterLogs";
|
|
135
135
|
params: [filterId: `0x${string}`];
|
|
@@ -357,7 +357,7 @@ declare class SafeConnector extends Connector<SafeConnectorProvider, SafeConnect
|
|
|
357
357
|
(args: {
|
|
358
358
|
method: "eth_getFilterChanges";
|
|
359
359
|
params: [filterId: `0x${string}`];
|
|
360
|
-
}): Promise
|
|
360
|
+
}): Promise<`0x${string}`[] | viem.RpcLog[]>;
|
|
361
361
|
(args: {
|
|
362
362
|
method: "eth_getFilterLogs";
|
|
363
363
|
params: [filterId: `0x${string}`];
|
|
@@ -512,7 +512,7 @@ declare class SafeConnector extends Connector<SafeConnectorProvider, SafeConnect
|
|
|
512
512
|
type: string;
|
|
513
513
|
uid: string;
|
|
514
514
|
addChain: (args: viem.AddChainParameters) => Promise<void>;
|
|
515
|
-
deployContract: <TAbi extends
|
|
515
|
+
deployContract: <TAbi extends readonly unknown[] | abitype_dist_abi_3a9c20c7.l, TChainOverride extends viem.Chain<viem_dist_types_types_formatter.Formatters> | undefined>(args: viem.DeployContractParameters<TAbi, Chain, {
|
|
516
516
|
address: `0x${string}`;
|
|
517
517
|
type: "json-rpc";
|
|
518
518
|
}, TChainOverride>) => Promise<`0x${string}`>;
|
|
@@ -539,13 +539,14 @@ declare class SafeConnector extends Connector<SafeConnectorProvider, SafeConnect
|
|
|
539
539
|
[x: `address[${string}]`]: undefined;
|
|
540
540
|
[x: `bool[${string}]`]: undefined;
|
|
541
541
|
[x: `bytes[${string}]`]: undefined;
|
|
542
|
+
[x: `bytes5[${string}]`]: undefined;
|
|
543
|
+
[x: `bytes1[${string}]`]: undefined;
|
|
544
|
+
[x: `bytes18[${string}]`]: undefined;
|
|
542
545
|
[x: `bytes2[${string}]`]: undefined;
|
|
543
546
|
[x: `bytes16[${string}]`]: undefined;
|
|
544
547
|
[x: `bytes10[${string}]`]: undefined;
|
|
545
|
-
[x: `bytes1[${string}]`]: undefined;
|
|
546
548
|
[x: `bytes3[${string}]`]: undefined;
|
|
547
549
|
[x: `bytes4[${string}]`]: undefined;
|
|
548
|
-
[x: `bytes5[${string}]`]: undefined;
|
|
549
550
|
[x: `bytes6[${string}]`]: undefined;
|
|
550
551
|
[x: `bytes7[${string}]`]: undefined;
|
|
551
552
|
[x: `bytes8[${string}]`]: undefined;
|
|
@@ -556,7 +557,6 @@ declare class SafeConnector extends Connector<SafeConnectorProvider, SafeConnect
|
|
|
556
557
|
[x: `bytes14[${string}]`]: undefined;
|
|
557
558
|
[x: `bytes15[${string}]`]: undefined;
|
|
558
559
|
[x: `bytes17[${string}]`]: undefined;
|
|
559
|
-
[x: `bytes18[${string}]`]: undefined;
|
|
560
560
|
[x: `bytes19[${string}]`]: undefined;
|
|
561
561
|
[x: `bytes20[${string}]`]: undefined;
|
|
562
562
|
[x: `bytes21[${string}]`]: undefined;
|
|
@@ -641,13 +641,14 @@ declare class SafeConnector extends Connector<SafeConnectorProvider, SafeConnect
|
|
|
641
641
|
address?: undefined;
|
|
642
642
|
bool?: undefined;
|
|
643
643
|
bytes?: undefined;
|
|
644
|
+
bytes5?: undefined;
|
|
645
|
+
bytes1?: undefined;
|
|
646
|
+
bytes18?: undefined;
|
|
644
647
|
bytes2?: undefined;
|
|
645
648
|
bytes16?: undefined;
|
|
646
649
|
bytes10?: undefined;
|
|
647
|
-
bytes1?: undefined;
|
|
648
650
|
bytes3?: undefined;
|
|
649
651
|
bytes4?: undefined;
|
|
650
|
-
bytes5?: undefined;
|
|
651
652
|
bytes6?: undefined;
|
|
652
653
|
bytes7?: undefined;
|
|
653
654
|
bytes8?: undefined;
|
|
@@ -658,7 +659,6 @@ declare class SafeConnector extends Connector<SafeConnectorProvider, SafeConnect
|
|
|
658
659
|
bytes14?: undefined;
|
|
659
660
|
bytes15?: undefined;
|
|
660
661
|
bytes17?: undefined;
|
|
661
|
-
bytes18?: undefined;
|
|
662
662
|
bytes19?: undefined;
|
|
663
663
|
bytes20?: undefined;
|
|
664
664
|
bytes21?: undefined;
|
|
@@ -745,7 +745,7 @@ declare class SafeConnector extends Connector<SafeConnectorProvider, SafeConnect
|
|
|
745
745
|
}>) => Promise<`0x${string}`>;
|
|
746
746
|
switchChain: (args: viem.SwitchChainParameters) => Promise<void>;
|
|
747
747
|
watchAsset: (args: viem_dist_types_types_eip1193.WatchAssetParams) => Promise<boolean>;
|
|
748
|
-
writeContract: <TAbi_1 extends
|
|
748
|
+
writeContract: <TAbi_1 extends readonly unknown[] | abitype_dist_abi_3a9c20c7.l, TFunctionName extends string, TChainOverride_2 extends viem.Chain<viem_dist_types_types_formatter.Formatters> | undefined>(args: viem.WriteContractParameters<TAbi_1, TFunctionName, Chain, {
|
|
749
749
|
address: `0x${string}`;
|
|
750
750
|
type: "json-rpc";
|
|
751
751
|
}, TChainOverride_2>) => Promise<`0x${string}`>;
|
package/dist/safe.js
CHANGED
|
@@ -94,7 +94,7 @@ var SafeConnector = class extends Connector {
|
|
|
94
94
|
async getWalletClient({ chainId } = {}) {
|
|
95
95
|
const provider = await this.getProvider();
|
|
96
96
|
const account = await this.getAccount();
|
|
97
|
-
const chain = this.chains.find((x) => x.id === chainId)
|
|
97
|
+
const chain = this.chains.find((x) => x.id === chainId);
|
|
98
98
|
if (!provider)
|
|
99
99
|
throw new Error("provider is required.");
|
|
100
100
|
return createWalletClient({
|
package/dist/walletConnect.d.ts
CHANGED
|
@@ -163,28 +163,6 @@ declare class WalletConnectConnector extends Connector<WalletConnectProvider, Wa
|
|
|
163
163
|
params: [block: `0x${string}` | viem.BlockTag, includeTransactionObjects: boolean];
|
|
164
164
|
}): Promise<viem.RpcBlock | null>;
|
|
165
165
|
(args: {
|
|
166
|
-
/**
|
|
167
|
-
* Checks if the target chains match the chains that were
|
|
168
|
-
* initially requested by the connector for the WalletConnect session.
|
|
169
|
-
* If there is a mismatch, this means that the chains on the connector
|
|
170
|
-
* are considered stale, and need to be revalidated at a later point (via
|
|
171
|
-
* connection).
|
|
172
|
-
*
|
|
173
|
-
* There may be a scenario where a dapp adds a chain to the
|
|
174
|
-
* connector later on, however, this chain will not have been approved or rejected
|
|
175
|
-
* by the wallet. In this case, the chain is considered stale.
|
|
176
|
-
*
|
|
177
|
-
* There are exceptions however:
|
|
178
|
-
* - If the wallet supports dynamic chain addition via `eth_addEthereumChain`,
|
|
179
|
-
* then the chain is not considered stale.
|
|
180
|
-
* - If the `isNewChainsStale` flag is falsy on the connector, then the chain is
|
|
181
|
-
* not considered stale.
|
|
182
|
-
*
|
|
183
|
-
* For the above cases, chain validation occurs dynamically when the user
|
|
184
|
-
* attempts to switch chain.
|
|
185
|
-
*
|
|
186
|
-
* Also check that dapp supports at least 1 chain from previously approved session.
|
|
187
|
-
*/
|
|
188
166
|
method: "eth_getBlockTransactionCountByHash";
|
|
189
167
|
params: [hash: `0x${string}`];
|
|
190
168
|
}): Promise<`0x${string}`>;
|
|
@@ -199,7 +177,7 @@ declare class WalletConnectConnector extends Connector<WalletConnectProvider, Wa
|
|
|
199
177
|
(args: {
|
|
200
178
|
method: "eth_getFilterChanges";
|
|
201
179
|
params: [filterId: `0x${string}`];
|
|
202
|
-
}): Promise
|
|
180
|
+
}): Promise<`0x${string}`[] | viem.RpcLog[]>;
|
|
203
181
|
(args: {
|
|
204
182
|
method: "eth_getFilterLogs";
|
|
205
183
|
params: [filterId: `0x${string}`];
|
|
@@ -413,28 +391,6 @@ declare class WalletConnectConnector extends Connector<WalletConnectProvider, Wa
|
|
|
413
391
|
params: [block: `0x${string}` | viem.BlockTag, includeTransactionObjects: boolean];
|
|
414
392
|
}): Promise<viem.RpcBlock | null>;
|
|
415
393
|
(args: {
|
|
416
|
-
/**
|
|
417
|
-
* Checks if the target chains match the chains that were
|
|
418
|
-
* initially requested by the connector for the WalletConnect session.
|
|
419
|
-
* If there is a mismatch, this means that the chains on the connector
|
|
420
|
-
* are considered stale, and need to be revalidated at a later point (via
|
|
421
|
-
* connection).
|
|
422
|
-
*
|
|
423
|
-
* There may be a scenario where a dapp adds a chain to the
|
|
424
|
-
* connector later on, however, this chain will not have been approved or rejected
|
|
425
|
-
* by the wallet. In this case, the chain is considered stale.
|
|
426
|
-
*
|
|
427
|
-
* There are exceptions however:
|
|
428
|
-
* - If the wallet supports dynamic chain addition via `eth_addEthereumChain`,
|
|
429
|
-
* then the chain is not considered stale.
|
|
430
|
-
* - If the `isNewChainsStale` flag is falsy on the connector, then the chain is
|
|
431
|
-
* not considered stale.
|
|
432
|
-
*
|
|
433
|
-
* For the above cases, chain validation occurs dynamically when the user
|
|
434
|
-
* attempts to switch chain.
|
|
435
|
-
*
|
|
436
|
-
* Also check that dapp supports at least 1 chain from previously approved session.
|
|
437
|
-
*/
|
|
438
394
|
method: "eth_getBlockTransactionCountByHash";
|
|
439
395
|
params: [hash: `0x${string}`];
|
|
440
396
|
}): Promise<`0x${string}`>;
|
|
@@ -449,7 +405,7 @@ declare class WalletConnectConnector extends Connector<WalletConnectProvider, Wa
|
|
|
449
405
|
(args: {
|
|
450
406
|
method: "eth_getFilterChanges";
|
|
451
407
|
params: [filterId: `0x${string}`];
|
|
452
|
-
}): Promise
|
|
408
|
+
}): Promise<`0x${string}`[] | viem.RpcLog[]>;
|
|
453
409
|
(args: {
|
|
454
410
|
method: "eth_getFilterLogs";
|
|
455
411
|
params: [filterId: `0x${string}`];
|
|
@@ -604,7 +560,7 @@ declare class WalletConnectConnector extends Connector<WalletConnectProvider, Wa
|
|
|
604
560
|
type: string;
|
|
605
561
|
uid: string;
|
|
606
562
|
addChain: (args: viem.AddChainParameters) => Promise<void>;
|
|
607
|
-
deployContract: <TAbi extends
|
|
563
|
+
deployContract: <TAbi extends readonly unknown[] | abitype_dist_abi_3a9c20c7.l, TChainOverride extends viem.Chain<viem_dist_types_types_formatter.Formatters> | undefined>(args: viem.DeployContractParameters<TAbi, Chain, {
|
|
608
564
|
address: `0x${string}`;
|
|
609
565
|
type: "json-rpc";
|
|
610
566
|
}, TChainOverride>) => Promise<`0x${string}`>;
|
|
@@ -631,13 +587,14 @@ declare class WalletConnectConnector extends Connector<WalletConnectProvider, Wa
|
|
|
631
587
|
[x: `address[${string}]`]: undefined;
|
|
632
588
|
[x: `bool[${string}]`]: undefined;
|
|
633
589
|
[x: `bytes[${string}]`]: undefined;
|
|
590
|
+
[x: `bytes5[${string}]`]: undefined;
|
|
591
|
+
[x: `bytes1[${string}]`]: undefined;
|
|
592
|
+
[x: `bytes18[${string}]`]: undefined;
|
|
634
593
|
[x: `bytes2[${string}]`]: undefined;
|
|
635
594
|
[x: `bytes16[${string}]`]: undefined;
|
|
636
595
|
[x: `bytes10[${string}]`]: undefined;
|
|
637
|
-
[x: `bytes1[${string}]`]: undefined;
|
|
638
596
|
[x: `bytes3[${string}]`]: undefined;
|
|
639
597
|
[x: `bytes4[${string}]`]: undefined;
|
|
640
|
-
[x: `bytes5[${string}]`]: undefined;
|
|
641
598
|
[x: `bytes6[${string}]`]: undefined;
|
|
642
599
|
[x: `bytes7[${string}]`]: undefined;
|
|
643
600
|
[x: `bytes8[${string}]`]: undefined;
|
|
@@ -648,7 +605,6 @@ declare class WalletConnectConnector extends Connector<WalletConnectProvider, Wa
|
|
|
648
605
|
[x: `bytes14[${string}]`]: undefined;
|
|
649
606
|
[x: `bytes15[${string}]`]: undefined;
|
|
650
607
|
[x: `bytes17[${string}]`]: undefined;
|
|
651
|
-
[x: `bytes18[${string}]`]: undefined;
|
|
652
608
|
[x: `bytes19[${string}]`]: undefined;
|
|
653
609
|
[x: `bytes20[${string}]`]: undefined;
|
|
654
610
|
[x: `bytes21[${string}]`]: undefined;
|
|
@@ -733,13 +689,14 @@ declare class WalletConnectConnector extends Connector<WalletConnectProvider, Wa
|
|
|
733
689
|
address?: undefined;
|
|
734
690
|
bool?: undefined;
|
|
735
691
|
bytes?: undefined;
|
|
692
|
+
bytes5?: undefined;
|
|
693
|
+
bytes1?: undefined;
|
|
694
|
+
bytes18?: undefined;
|
|
736
695
|
bytes2?: undefined;
|
|
737
696
|
bytes16?: undefined;
|
|
738
697
|
bytes10?: undefined;
|
|
739
|
-
bytes1?: undefined;
|
|
740
698
|
bytes3?: undefined;
|
|
741
699
|
bytes4?: undefined;
|
|
742
|
-
bytes5?: undefined;
|
|
743
700
|
bytes6?: undefined;
|
|
744
701
|
bytes7?: undefined;
|
|
745
702
|
bytes8?: undefined;
|
|
@@ -750,7 +707,6 @@ declare class WalletConnectConnector extends Connector<WalletConnectProvider, Wa
|
|
|
750
707
|
bytes14?: undefined;
|
|
751
708
|
bytes15?: undefined;
|
|
752
709
|
bytes17?: undefined;
|
|
753
|
-
bytes18?: undefined;
|
|
754
710
|
bytes19?: undefined;
|
|
755
711
|
bytes20?: undefined;
|
|
756
712
|
bytes21?: undefined;
|
|
@@ -837,7 +793,7 @@ declare class WalletConnectConnector extends Connector<WalletConnectProvider, Wa
|
|
|
837
793
|
}>) => Promise<`0x${string}`>;
|
|
838
794
|
switchChain: (args: viem.SwitchChainParameters) => Promise<void>;
|
|
839
795
|
watchAsset: (args: viem_dist_types_types_eip1193.WatchAssetParams) => Promise<boolean>;
|
|
840
|
-
writeContract: <TAbi_1 extends
|
|
796
|
+
writeContract: <TAbi_1 extends readonly unknown[] | abitype_dist_abi_3a9c20c7.l, TFunctionName extends string, TChainOverride_2 extends viem.Chain<viem_dist_types_types_formatter.Formatters> | undefined>(args: viem.WriteContractParameters<TAbi_1, TFunctionName, Chain, {
|
|
841
797
|
address: `0x${string}`;
|
|
842
798
|
type: "json-rpc";
|
|
843
799
|
}, TChainOverride_2>) => Promise<`0x${string}`>;
|
package/dist/walletConnect.js
CHANGED
|
@@ -139,7 +139,7 @@ var WalletConnectConnector = class extends Connector {
|
|
|
139
139
|
this.getProvider({ chainId }),
|
|
140
140
|
this.getAccount()
|
|
141
141
|
]);
|
|
142
|
-
const chain = this.chains.find((x) => x.id === chainId)
|
|
142
|
+
const chain = this.chains.find((x) => x.id === chainId);
|
|
143
143
|
if (!provider)
|
|
144
144
|
throw new Error("provider is required.");
|
|
145
145
|
return createWalletClient({
|
|
@@ -118,7 +118,7 @@ declare class WalletConnectLegacyConnector extends Connector<WalletConnectProvid
|
|
|
118
118
|
(args: {
|
|
119
119
|
method: "eth_getFilterChanges";
|
|
120
120
|
params: [filterId: `0x${string}`];
|
|
121
|
-
}): Promise
|
|
121
|
+
}): Promise<`0x${string}`[] | viem.RpcLog[]>;
|
|
122
122
|
(args: {
|
|
123
123
|
method: "eth_getFilterLogs";
|
|
124
124
|
params: [filterId: `0x${string}`];
|
|
@@ -346,7 +346,7 @@ declare class WalletConnectLegacyConnector extends Connector<WalletConnectProvid
|
|
|
346
346
|
(args: {
|
|
347
347
|
method: "eth_getFilterChanges";
|
|
348
348
|
params: [filterId: `0x${string}`];
|
|
349
|
-
}): Promise
|
|
349
|
+
}): Promise<`0x${string}`[] | viem.RpcLog[]>;
|
|
350
350
|
(args: {
|
|
351
351
|
method: "eth_getFilterLogs";
|
|
352
352
|
params: [filterId: `0x${string}`];
|
|
@@ -501,7 +501,7 @@ declare class WalletConnectLegacyConnector extends Connector<WalletConnectProvid
|
|
|
501
501
|
type: string;
|
|
502
502
|
uid: string;
|
|
503
503
|
addChain: (args: viem.AddChainParameters) => Promise<void>;
|
|
504
|
-
deployContract: <TAbi extends
|
|
504
|
+
deployContract: <TAbi extends readonly unknown[] | abitype_dist_abi_3a9c20c7.l, TChainOverride extends viem.Chain<viem_dist_types_types_formatter.Formatters> | undefined>(args: viem.DeployContractParameters<TAbi, Chain, {
|
|
505
505
|
address: `0x${string}`;
|
|
506
506
|
type: "json-rpc";
|
|
507
507
|
}, TChainOverride>) => Promise<`0x${string}`>;
|
|
@@ -528,13 +528,14 @@ declare class WalletConnectLegacyConnector extends Connector<WalletConnectProvid
|
|
|
528
528
|
[x: `address[${string}]`]: undefined;
|
|
529
529
|
[x: `bool[${string}]`]: undefined;
|
|
530
530
|
[x: `bytes[${string}]`]: undefined;
|
|
531
|
+
[x: `bytes5[${string}]`]: undefined;
|
|
532
|
+
[x: `bytes1[${string}]`]: undefined;
|
|
533
|
+
[x: `bytes18[${string}]`]: undefined;
|
|
531
534
|
[x: `bytes2[${string}]`]: undefined;
|
|
532
535
|
[x: `bytes16[${string}]`]: undefined;
|
|
533
536
|
[x: `bytes10[${string}]`]: undefined;
|
|
534
|
-
[x: `bytes1[${string}]`]: undefined;
|
|
535
537
|
[x: `bytes3[${string}]`]: undefined;
|
|
536
538
|
[x: `bytes4[${string}]`]: undefined;
|
|
537
|
-
[x: `bytes5[${string}]`]: undefined;
|
|
538
539
|
[x: `bytes6[${string}]`]: undefined;
|
|
539
540
|
[x: `bytes7[${string}]`]: undefined;
|
|
540
541
|
[x: `bytes8[${string}]`]: undefined;
|
|
@@ -545,7 +546,6 @@ declare class WalletConnectLegacyConnector extends Connector<WalletConnectProvid
|
|
|
545
546
|
[x: `bytes14[${string}]`]: undefined;
|
|
546
547
|
[x: `bytes15[${string}]`]: undefined;
|
|
547
548
|
[x: `bytes17[${string}]`]: undefined;
|
|
548
|
-
[x: `bytes18[${string}]`]: undefined;
|
|
549
549
|
[x: `bytes19[${string}]`]: undefined;
|
|
550
550
|
[x: `bytes20[${string}]`]: undefined;
|
|
551
551
|
[x: `bytes21[${string}]`]: undefined;
|
|
@@ -630,13 +630,14 @@ declare class WalletConnectLegacyConnector extends Connector<WalletConnectProvid
|
|
|
630
630
|
address?: undefined;
|
|
631
631
|
bool?: undefined;
|
|
632
632
|
bytes?: undefined;
|
|
633
|
+
bytes5?: undefined;
|
|
634
|
+
bytes1?: undefined;
|
|
635
|
+
bytes18?: undefined;
|
|
633
636
|
bytes2?: undefined;
|
|
634
637
|
bytes16?: undefined;
|
|
635
638
|
bytes10?: undefined;
|
|
636
|
-
bytes1?: undefined;
|
|
637
639
|
bytes3?: undefined;
|
|
638
640
|
bytes4?: undefined;
|
|
639
|
-
bytes5?: undefined;
|
|
640
641
|
bytes6?: undefined;
|
|
641
642
|
bytes7?: undefined;
|
|
642
643
|
bytes8?: undefined;
|
|
@@ -647,7 +648,6 @@ declare class WalletConnectLegacyConnector extends Connector<WalletConnectProvid
|
|
|
647
648
|
bytes14?: undefined;
|
|
648
649
|
bytes15?: undefined;
|
|
649
650
|
bytes17?: undefined;
|
|
650
|
-
bytes18?: undefined;
|
|
651
651
|
bytes19?: undefined;
|
|
652
652
|
bytes20?: undefined;
|
|
653
653
|
bytes21?: undefined;
|
|
@@ -734,7 +734,7 @@ declare class WalletConnectLegacyConnector extends Connector<WalletConnectProvid
|
|
|
734
734
|
}>) => Promise<`0x${string}`>;
|
|
735
735
|
switchChain: (args: viem.SwitchChainParameters) => Promise<void>;
|
|
736
736
|
watchAsset: (args: viem_dist_types_types_eip1193.WatchAssetParams) => Promise<boolean>;
|
|
737
|
-
writeContract: <TAbi_1 extends
|
|
737
|
+
writeContract: <TAbi_1 extends readonly unknown[] | abitype_dist_abi_3a9c20c7.l, TFunctionName extends string, TChainOverride_2 extends viem.Chain<viem_dist_types_types_formatter.Formatters> | undefined>(args: viem.WriteContractParameters<TAbi_1, TFunctionName, Chain, {
|
|
738
738
|
address: `0x${string}`;
|
|
739
739
|
type: "json-rpc";
|
|
740
740
|
}, TChainOverride_2>) => Promise<`0x${string}`>;
|
|
@@ -123,7 +123,7 @@ var WalletConnectLegacyConnector = class extends Connector {
|
|
|
123
123
|
this.getProvider({ chainId }),
|
|
124
124
|
this.getAccount()
|
|
125
125
|
]);
|
|
126
|
-
const chain = this.chains.find((x) => x.id === chainId)
|
|
126
|
+
const chain = this.chains.find((x) => x.id === chainId);
|
|
127
127
|
if (!provider)
|
|
128
128
|
throw new Error("provider is required.");
|
|
129
129
|
return createWalletClient({
|