wagmi 2.9.6 → 2.9.8
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/context.js +0 -1
- package/dist/esm/context.js.map +1 -1
- package/dist/esm/experimental/hooks/useCallsStatus.js +0 -2
- package/dist/esm/experimental/hooks/useCallsStatus.js.map +1 -1
- package/dist/esm/experimental/hooks/useCapabilities.js +0 -2
- package/dist/esm/experimental/hooks/useCapabilities.js.map +1 -1
- package/dist/esm/experimental/hooks/useWriteContracts.js.map +1 -1
- package/dist/esm/exports/actions.js +2 -0
- package/dist/esm/exports/actions.js.map +1 -1
- package/dist/esm/exports/chains.js +2 -0
- package/dist/esm/exports/chains.js.map +1 -1
- package/dist/esm/exports/codegen.js +2 -0
- package/dist/esm/exports/codegen.js.map +1 -1
- package/dist/esm/exports/connectors.js +2 -0
- package/dist/esm/exports/connectors.js.map +1 -1
- package/dist/esm/exports/experimental.js +1 -0
- package/dist/esm/exports/experimental.js.map +1 -1
- package/dist/esm/exports/index.js +1 -0
- package/dist/esm/exports/index.js.map +1 -1
- package/dist/esm/exports/query.js +2 -0
- package/dist/esm/exports/query.js.map +1 -1
- package/dist/esm/hooks/codegen/createUseReadContract.js +0 -5
- package/dist/esm/hooks/codegen/createUseReadContract.js.map +1 -1
- package/dist/esm/hooks/codegen/createUseSimulateContract.js +0 -5
- package/dist/esm/hooks/codegen/createUseSimulateContract.js.map +1 -1
- package/dist/esm/hooks/codegen/createUseWatchContractEvent.js +0 -4
- package/dist/esm/hooks/codegen/createUseWatchContractEvent.js.map +1 -1
- package/dist/esm/hooks/codegen/createUseWriteContract.js +0 -5
- package/dist/esm/hooks/codegen/createUseWriteContract.js.map +1 -1
- package/dist/esm/hooks/useAccount.js +0 -1
- package/dist/esm/hooks/useAccount.js.map +1 -1
- package/dist/esm/hooks/useBalance.js +0 -1
- package/dist/esm/hooks/useBalance.js.map +1 -1
- package/dist/esm/hooks/useBlock.js +0 -2
- package/dist/esm/hooks/useBlock.js.map +1 -1
- package/dist/esm/hooks/useBlockNumber.js +0 -2
- package/dist/esm/hooks/useBlockNumber.js.map +1 -1
- package/dist/esm/hooks/useBlockTransactionCount.js +0 -2
- package/dist/esm/hooks/useBlockTransactionCount.js.map +1 -1
- package/dist/esm/hooks/useBytecode.js +0 -3
- package/dist/esm/hooks/useBytecode.js.map +1 -1
- package/dist/esm/hooks/useCall.js +0 -1
- package/dist/esm/hooks/useCall.js.map +1 -1
- package/dist/esm/hooks/useConfig.js +0 -1
- package/dist/esm/hooks/useConfig.js.map +1 -1
- package/dist/esm/hooks/useConnect.js +0 -1
- package/dist/esm/hooks/useConnect.js.map +1 -1
- package/dist/esm/hooks/useConnectorClient.js +2 -3
- package/dist/esm/hooks/useConnectorClient.js.map +1 -1
- package/dist/esm/hooks/useDisconnect.js +0 -1
- package/dist/esm/hooks/useDisconnect.js.map +1 -1
- package/dist/esm/hooks/useEnsAddress.js +0 -1
- package/dist/esm/hooks/useEnsAddress.js.map +1 -1
- package/dist/esm/hooks/useEnsAvatar.js +0 -1
- package/dist/esm/hooks/useEnsAvatar.js.map +1 -1
- package/dist/esm/hooks/useEnsName.js +0 -1
- package/dist/esm/hooks/useEnsName.js.map +1 -1
- package/dist/esm/hooks/useEnsResolver.js +0 -1
- package/dist/esm/hooks/useEnsResolver.js.map +1 -1
- package/dist/esm/hooks/useEnsText.js +0 -1
- package/dist/esm/hooks/useEnsText.js.map +1 -1
- package/dist/esm/hooks/useEstimateFeesPerGas.js +0 -2
- package/dist/esm/hooks/useEstimateFeesPerGas.js.map +1 -1
- package/dist/esm/hooks/useEstimateMaxPriorityFeePerGas.js +0 -2
- package/dist/esm/hooks/useEstimateMaxPriorityFeePerGas.js.map +1 -1
- package/dist/esm/hooks/useFeeHistory.js +0 -2
- package/dist/esm/hooks/useFeeHistory.js.map +1 -1
- package/dist/esm/hooks/useGasPrice.js +0 -2
- package/dist/esm/hooks/useGasPrice.js.map +1 -1
- package/dist/esm/hooks/usePrepareTransactionRequest.js +0 -3
- package/dist/esm/hooks/usePrepareTransactionRequest.js.map +1 -1
- package/dist/esm/hooks/useProof.js +0 -3
- package/dist/esm/hooks/useProof.js.map +1 -1
- package/dist/esm/hooks/useReadContract.js +0 -3
- package/dist/esm/hooks/useReadContract.js.map +1 -1
- package/dist/esm/hooks/useReadContracts.js +0 -4
- package/dist/esm/hooks/useReadContracts.js.map +1 -1
- package/dist/esm/hooks/useReconnect.js +0 -1
- package/dist/esm/hooks/useReconnect.js.map +1 -1
- package/dist/esm/hooks/useSignMessage.js +0 -1
- package/dist/esm/hooks/useSignMessage.js.map +1 -1
- package/dist/esm/hooks/useSimulateContract.js +0 -1
- package/dist/esm/hooks/useSimulateContract.js.map +1 -1
- package/dist/esm/hooks/useStorageAt.js +0 -3
- package/dist/esm/hooks/useStorageAt.js.map +1 -1
- package/dist/esm/hooks/useSwitchChain.js +0 -4
- package/dist/esm/hooks/useSwitchChain.js.map +1 -1
- package/dist/esm/hooks/useSyncExternalStoreWithTracked.js +6 -4
- package/dist/esm/hooks/useSyncExternalStoreWithTracked.js.map +1 -1
- package/dist/esm/hooks/useToken.js +0 -1
- package/dist/esm/hooks/useToken.js.map +1 -1
- package/dist/esm/hooks/useTransaction.js +0 -1
- package/dist/esm/hooks/useTransaction.js.map +1 -1
- package/dist/esm/hooks/useTransactionConfirmations.js +0 -2
- package/dist/esm/hooks/useTransactionConfirmations.js.map +1 -1
- package/dist/esm/hooks/useTransactionCount.js +0 -1
- package/dist/esm/hooks/useTransactionCount.js.map +1 -1
- package/dist/esm/hooks/useTransactionReceipt.js +0 -4
- package/dist/esm/hooks/useTransactionReceipt.js.map +1 -1
- package/dist/esm/hooks/useVerifyMessage.js +0 -1
- package/dist/esm/hooks/useVerifyMessage.js.map +1 -1
- package/dist/esm/hooks/useVerifyTypedData.js +0 -2
- package/dist/esm/hooks/useVerifyTypedData.js.map +1 -1
- package/dist/esm/hooks/useWaitForTransactionReceipt.js +0 -1
- package/dist/esm/hooks/useWaitForTransactionReceipt.js.map +1 -1
- package/dist/esm/hooks/useWalletClient.js +2 -3
- package/dist/esm/hooks/useWalletClient.js.map +1 -1
- package/dist/esm/hooks/useWatchBlockNumber.js +0 -1
- package/dist/esm/hooks/useWatchBlockNumber.js.map +1 -1
- package/dist/esm/hooks/useWatchBlocks.js +0 -1
- package/dist/esm/hooks/useWatchBlocks.js.map +1 -1
- package/dist/esm/hooks/useWatchContractEvent.js +0 -1
- package/dist/esm/hooks/useWatchContractEvent.js.map +1 -1
- package/dist/esm/hooks/useWatchPendingTransactions.js +0 -1
- package/dist/esm/hooks/useWatchPendingTransactions.js.map +1 -1
- package/dist/esm/hydrate.js +1 -1
- package/dist/esm/hydrate.js.map +1 -1
- package/dist/esm/tsconfig.build.tsbuildinfo +1 -1
- package/dist/esm/types/properties.js +1 -3
- package/dist/esm/types/properties.js.map +1 -1
- package/dist/esm/utils/query.js +1 -2
- package/dist/esm/utils/query.js.map +1 -1
- package/dist/esm/version.js +1 -1
- package/dist/types/context.d.ts +1 -1
- package/dist/types/context.d.ts.map +1 -1
- package/dist/types/experimental/hooks/useCallsStatus.d.ts +2 -2
- package/dist/types/experimental/hooks/useCallsStatus.d.ts.map +1 -1
- package/dist/types/experimental/hooks/useCapabilities.d.ts +2 -2
- package/dist/types/experimental/hooks/useCapabilities.d.ts.map +1 -1
- package/dist/types/experimental/hooks/useShowCallsStatus.d.ts.map +1 -1
- package/dist/types/experimental/hooks/useWriteContracts.d.ts.map +1 -1
- package/dist/types/exports/actions.d.ts.map +1 -1
- package/dist/types/exports/chains.d.ts.map +1 -1
- package/dist/types/exports/codegen.d.ts.map +1 -1
- package/dist/types/exports/connectors.d.ts.map +1 -1
- package/dist/types/exports/experimental.d.ts.map +1 -1
- package/dist/types/exports/index.d.ts.map +1 -1
- package/dist/types/exports/query.d.ts.map +1 -1
- package/dist/types/hooks/codegen/createUseReadContract.d.ts +5 -5
- package/dist/types/hooks/codegen/createUseReadContract.d.ts.map +1 -1
- package/dist/types/hooks/codegen/createUseSimulateContract.d.ts +5 -5
- package/dist/types/hooks/codegen/createUseSimulateContract.d.ts.map +1 -1
- package/dist/types/hooks/codegen/createUseWatchContractEvent.d.ts +4 -4
- package/dist/types/hooks/codegen/createUseWatchContractEvent.d.ts.map +1 -1
- package/dist/types/hooks/codegen/createUseWriteContract.d.ts +5 -5
- package/dist/types/hooks/codegen/createUseWriteContract.d.ts.map +1 -1
- package/dist/types/hooks/useAccount.d.ts +1 -1
- package/dist/types/hooks/useAccount.d.ts.map +1 -1
- package/dist/types/hooks/useBalance.d.ts +1 -1
- package/dist/types/hooks/useBalance.d.ts.map +1 -1
- package/dist/types/hooks/useBlock.d.ts +2 -2
- package/dist/types/hooks/useBlock.d.ts.map +1 -1
- package/dist/types/hooks/useBlockNumber.d.ts +2 -2
- package/dist/types/hooks/useBlockNumber.d.ts.map +1 -1
- package/dist/types/hooks/useBlockTransactionCount.d.ts +2 -2
- package/dist/types/hooks/useBlockTransactionCount.d.ts.map +1 -1
- package/dist/types/hooks/useBytecode.d.ts +3 -3
- package/dist/types/hooks/useBytecode.d.ts.map +1 -1
- package/dist/types/hooks/useCall.d.ts +1 -1
- package/dist/types/hooks/useCall.d.ts.map +1 -1
- package/dist/types/hooks/useConfig.d.ts +1 -1
- package/dist/types/hooks/useConfig.d.ts.map +1 -1
- package/dist/types/hooks/useConnect.d.ts +1 -1
- package/dist/types/hooks/useConnect.d.ts.map +1 -1
- package/dist/types/hooks/useConnectorClient.d.ts +1 -1
- package/dist/types/hooks/useConnectorClient.d.ts.map +1 -1
- package/dist/types/hooks/useDisconnect.d.ts +1 -1
- package/dist/types/hooks/useDisconnect.d.ts.map +1 -1
- package/dist/types/hooks/useEnsAddress.d.ts +1 -1
- package/dist/types/hooks/useEnsAddress.d.ts.map +1 -1
- package/dist/types/hooks/useEnsAvatar.d.ts +1 -1
- package/dist/types/hooks/useEnsAvatar.d.ts.map +1 -1
- package/dist/types/hooks/useEnsName.d.ts +1 -1
- package/dist/types/hooks/useEnsName.d.ts.map +1 -1
- package/dist/types/hooks/useEnsResolver.d.ts +1 -1
- package/dist/types/hooks/useEnsResolver.d.ts.map +1 -1
- package/dist/types/hooks/useEnsText.d.ts +1 -1
- package/dist/types/hooks/useEnsText.d.ts.map +1 -1
- package/dist/types/hooks/useEstimateFeesPerGas.d.ts +2 -2
- package/dist/types/hooks/useEstimateFeesPerGas.d.ts.map +1 -1
- package/dist/types/hooks/useEstimateMaxPriorityFeePerGas.d.ts +2 -2
- package/dist/types/hooks/useEstimateMaxPriorityFeePerGas.d.ts.map +1 -1
- package/dist/types/hooks/useFeeHistory.d.ts +2 -2
- package/dist/types/hooks/useFeeHistory.d.ts.map +1 -1
- package/dist/types/hooks/useGasPrice.d.ts +2 -2
- package/dist/types/hooks/useGasPrice.d.ts.map +1 -1
- package/dist/types/hooks/usePrepareTransactionRequest.d.ts +3 -3
- package/dist/types/hooks/usePrepareTransactionRequest.d.ts.map +1 -1
- package/dist/types/hooks/useProof.d.ts +3 -3
- package/dist/types/hooks/useProof.d.ts.map +1 -1
- package/dist/types/hooks/useReadContract.d.ts +3 -3
- package/dist/types/hooks/useReadContract.d.ts.map +1 -1
- package/dist/types/hooks/useReadContracts.d.ts +4 -4
- package/dist/types/hooks/useReadContracts.d.ts.map +1 -1
- package/dist/types/hooks/useReconnect.d.ts +1 -1
- package/dist/types/hooks/useReconnect.d.ts.map +1 -1
- package/dist/types/hooks/useSignMessage.d.ts +1 -1
- package/dist/types/hooks/useSignMessage.d.ts.map +1 -1
- package/dist/types/hooks/useSimulateContract.d.ts +1 -1
- package/dist/types/hooks/useSimulateContract.d.ts.map +1 -1
- package/dist/types/hooks/useStorageAt.d.ts +3 -3
- package/dist/types/hooks/useStorageAt.d.ts.map +1 -1
- package/dist/types/hooks/useSwitchChain.d.ts +4 -4
- package/dist/types/hooks/useSwitchChain.d.ts.map +1 -1
- package/dist/types/hooks/useSyncExternalStoreWithTracked.d.ts.map +1 -1
- package/dist/types/hooks/useToken.d.ts +1 -1
- package/dist/types/hooks/useToken.d.ts.map +1 -1
- package/dist/types/hooks/useTransaction.d.ts +1 -1
- package/dist/types/hooks/useTransaction.d.ts.map +1 -1
- package/dist/types/hooks/useTransactionConfirmations.d.ts +2 -2
- package/dist/types/hooks/useTransactionConfirmations.d.ts.map +1 -1
- package/dist/types/hooks/useTransactionCount.d.ts +1 -1
- package/dist/types/hooks/useTransactionCount.d.ts.map +1 -1
- package/dist/types/hooks/useTransactionReceipt.d.ts +4 -4
- package/dist/types/hooks/useTransactionReceipt.d.ts.map +1 -1
- package/dist/types/hooks/useVerifyMessage.d.ts +1 -1
- package/dist/types/hooks/useVerifyMessage.d.ts.map +1 -1
- package/dist/types/hooks/useVerifyTypedData.d.ts +2 -2
- package/dist/types/hooks/useVerifyTypedData.d.ts.map +1 -1
- package/dist/types/hooks/useWaitForTransactionReceipt.d.ts +1 -1
- package/dist/types/hooks/useWaitForTransactionReceipt.d.ts.map +1 -1
- package/dist/types/hooks/useWalletClient.d.ts +1 -1
- package/dist/types/hooks/useWalletClient.d.ts.map +1 -1
- package/dist/types/hooks/useWatchBlockNumber.d.ts +1 -1
- package/dist/types/hooks/useWatchBlockNumber.d.ts.map +1 -1
- package/dist/types/hooks/useWatchBlocks.d.ts +1 -1
- package/dist/types/hooks/useWatchBlocks.d.ts.map +1 -1
- package/dist/types/hooks/useWatchContractEvent.d.ts +1 -1
- package/dist/types/hooks/useWatchContractEvent.d.ts.map +1 -1
- package/dist/types/hooks/useWatchPendingTransactions.d.ts +1 -1
- package/dist/types/hooks/useWatchPendingTransactions.d.ts.map +1 -1
- package/dist/types/types/properties.d.ts +3 -3
- package/dist/types/types/properties.d.ts.map +1 -1
- package/dist/types/utils/query.d.ts +1 -1
- package/dist/types/utils/query.d.ts.map +1 -1
- package/dist/types/version.d.ts +1 -1
- package/package.json +3 -3
- package/src/context.ts +1 -1
- package/src/experimental/hooks/useCallsStatus.ts +2 -2
- package/src/experimental/hooks/useCapabilities.ts +2 -2
- package/src/experimental/hooks/useShowCallsStatus.ts +1 -1
- package/src/experimental/hooks/useWriteContracts.ts +2 -1
- package/src/exports/actions.ts +2 -0
- package/src/exports/chains.ts +2 -0
- package/src/exports/codegen.ts +2 -0
- package/src/exports/connectors.ts +2 -0
- package/src/exports/experimental.ts +1 -0
- package/src/exports/index.ts +1 -0
- package/src/exports/query.ts +2 -0
- package/src/hooks/codegen/createUseReadContract.ts +20 -23
- package/src/hooks/codegen/createUseSimulateContract.ts +16 -19
- package/src/hooks/codegen/createUseWatchContractEvent.ts +14 -13
- package/src/hooks/codegen/createUseWriteContract.ts +19 -19
- package/src/hooks/useAccount.ts +1 -1
- package/src/hooks/useBalance.ts +1 -5
- package/src/hooks/useBlock.ts +8 -13
- package/src/hooks/useBlockNumber.ts +9 -11
- package/src/hooks/useBlockTransactionCount.ts +9 -7
- package/src/hooks/useBytecode.ts +6 -9
- package/src/hooks/useCall.ts +1 -5
- package/src/hooks/useConfig.ts +1 -1
- package/src/hooks/useConnect.ts +1 -5
- package/src/hooks/useConnectorClient.ts +9 -6
- package/src/hooks/useDisconnect.ts +1 -1
- package/src/hooks/useEnsAddress.ts +1 -1
- package/src/hooks/useEnsAvatar.ts +1 -1
- package/src/hooks/useEnsName.ts +1 -1
- package/src/hooks/useEnsResolver.ts +1 -1
- package/src/hooks/useEnsText.ts +1 -1
- package/src/hooks/useEstimateFeesPerGas.ts +5 -5
- package/src/hooks/useEstimateMaxPriorityFeePerGas.ts +5 -5
- package/src/hooks/useFeeHistory.ts +9 -7
- package/src/hooks/useGasPrice.ts +9 -7
- package/src/hooks/usePrepareTransactionRequest.ts +7 -10
- package/src/hooks/useProof.ts +3 -10
- package/src/hooks/useReadContract.ts +6 -10
- package/src/hooks/useReadContracts.ts +7 -10
- package/src/hooks/useReconnect.ts +1 -1
- package/src/hooks/useSignMessage.ts +1 -1
- package/src/hooks/useSimulateContract.ts +1 -4
- package/src/hooks/useStorageAt.ts +6 -9
- package/src/hooks/useSwitchChain.ts +9 -9
- package/src/hooks/useSyncExternalStoreWithTracked.ts +18 -20
- package/src/hooks/useToken.ts +1 -1
- package/src/hooks/useTransaction.ts +7 -4
- package/src/hooks/useTransactionConfirmations.ts +5 -8
- package/src/hooks/useTransactionCount.ts +4 -4
- package/src/hooks/useTransactionReceipt.ts +13 -13
- package/src/hooks/useVerifyMessage.ts +4 -4
- package/src/hooks/useVerifyTypedData.ts +5 -5
- package/src/hooks/useWaitForTransactionReceipt.ts +7 -4
- package/src/hooks/useWalletClient.ts +9 -6
- package/src/hooks/useWatchBlockNumber.ts +5 -3
- package/src/hooks/useWatchBlocks.ts +5 -3
- package/src/hooks/useWatchContractEvent.ts +5 -3
- package/src/hooks/useWatchPendingTransactions.ts +5 -3
- package/src/hydrate.ts +1 -1
- package/src/types/properties.ts +3 -3
- package/src/utils/query.ts +6 -6
- package/src/version.ts +1 -1
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { type Config, type ResolvedRegister, type WatchContractEventParameters } from '@wagmi/core';
|
|
2
|
-
import {
|
|
2
|
+
import type { UnionEvaluate, UnionPartial } from '@wagmi/core/internal';
|
|
3
3
|
import type { Abi, ContractEventName } from 'viem';
|
|
4
4
|
import type { ConfigParameter, EnabledParameter } from '../types/properties.js';
|
|
5
5
|
export type UseWatchContractEventParameters<abi extends Abi | readonly unknown[] = Abi, eventName extends ContractEventName<abi> = ContractEventName<abi>, strict extends boolean | undefined = undefined, config extends Config = Config, chainId extends config['chains'][number]['id'] = config['chains'][number]['id']> = UnionEvaluate<UnionPartial<WatchContractEventParameters<abi, eventName, strict, config, chainId>> & ConfigParameter<config> & EnabledParameter>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useWatchContractEvent.d.ts","sourceRoot":"","sources":["../../../src/hooks/useWatchContractEvent.ts"],"names":[],"mappings":"AAEA,OAAO,EACL,KAAK,MAAM,EACX,KAAK,gBAAgB,EACrB,KAAK,4BAA4B,EAElC,MAAM,aAAa,CAAA;A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AAS,MAAM,GAAG,gBAAgB,CAAC,QAAQ,CAAC,EAClD,OAAO,SACL,MAAM,CAAC,QAAQ,CAAC,CAAC,MAAM,CAAC,CAAC,IAAI,CAAC,GAAG,MAAM,CAAC,QAAQ,CAAC,CAAC,MAAM,CAAC,CAAC,IAAI,CAAC,EAEjE,UAAU,GAAE,+BAA+B,CACzC,GAAG,EACH,SAAS,EACT,MAAM,EACN,MAAM,EACN,OAAO,CACI,GACZ,+BAA+B,CAgBjC"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { type Config, type ResolvedRegister, type WatchPendingTransactionsParameters } from '@wagmi/core';
|
|
2
|
-
import {
|
|
2
|
+
import type { UnionEvaluate, UnionPartial } from '@wagmi/core/internal';
|
|
3
3
|
import type { ConfigParameter, EnabledParameter } from '../types/properties.js';
|
|
4
4
|
export type UseWatchPendingTransactionsParameters<config extends Config = Config, chainId extends config['chains'][number]['id'] = config['chains'][number]['id']> = UnionEvaluate<UnionPartial<WatchPendingTransactionsParameters<config, chainId>> & ConfigParameter<config> & EnabledParameter>;
|
|
5
5
|
export type UseWatchPendingTransactionsReturnType = void;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useWatchPendingTransactions.d.ts","sourceRoot":"","sources":["../../../src/hooks/useWatchPendingTransactions.ts"],"names":[],"mappings":"AAEA,OAAO,EACL,KAAK,MAAM,EACX,KAAK,gBAAgB,EACrB,KAAK,kCAAkC,EAExC,MAAM,aAAa,CAAA;AACpB,OAAO,EAAE,
|
|
1
|
+
{"version":3,"file":"useWatchPendingTransactions.d.ts","sourceRoot":"","sources":["../../../src/hooks/useWatchPendingTransactions.ts"],"names":[],"mappings":"AAEA,OAAO,EACL,KAAK,MAAM,EACX,KAAK,gBAAgB,EACrB,KAAK,kCAAkC,EAExC,MAAM,aAAa,CAAA;AACpB,OAAO,KAAK,EAAE,aAAa,EAAE,YAAY,EAAE,MAAM,sBAAsB,CAAA;AAGvE,OAAO,KAAK,EAAE,eAAe,EAAE,gBAAgB,EAAE,MAAM,wBAAwB,CAAA;AAI/E,MAAM,MAAM,qCAAqC,CAC/C,MAAM,SAAS,MAAM,GAAG,MAAM,EAC9B,OAAO,SACL,MAAM,CAAC,QAAQ,CAAC,CAAC,MAAM,CAAC,CAAC,IAAI,CAAC,GAAG,MAAM,CAAC,QAAQ,CAAC,CAAC,MAAM,CAAC,CAAC,IAAI,CAAC,IAC/D,aAAa,CACf,YAAY,CAAC,kCAAkC,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC,GAC/D,eAAe,CAAC,MAAM,CAAC,GACvB,gBAAgB,CACnB,CAAA;AAED,MAAM,MAAM,qCAAqC,GAAG,IAAI,CAAA;AAExD,mEAAmE;AACnE,wBAAgB,2BAA2B,CACzC,MAAM,SAAS,MAAM,GAAG,gBAAgB,CAAC,QAAQ,CAAC,EAClD,OAAO,SACL,MAAM,CAAC,QAAQ,CAAC,CAAC,MAAM,CAAC,CAAC,IAAI,CAAC,GAAG,MAAM,CAAC,QAAQ,CAAC,CAAC,MAAM,CAAC,CAAC,IAAI,CAAC,EAEjE,UAAU,GAAE,qCAAqC,CAC/C,MAAM,EACN,OAAO,CACI,GACZ,qCAAqC,CAgBvC"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
1
|
+
import type { DefaultError, QueryKey } from '@tanstack/react-query';
|
|
2
|
+
import type { Config } from '@wagmi/core';
|
|
3
|
+
import type { Omit } from '@wagmi/core/internal';
|
|
4
4
|
import type { UseInfiniteQueryParameters, UseQueryParameters } from '../utils/query.js';
|
|
5
5
|
export type EnabledParameter = {
|
|
6
6
|
enabled?: boolean | undefined;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"properties.d.ts","sourceRoot":"","sources":["../../../src/types/properties.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,
|
|
1
|
+
{"version":3,"file":"properties.d.ts","sourceRoot":"","sources":["../../../src/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}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { type DefaultError, type QueryKey, type UseInfiniteQueryOptions, type UseInfiniteQueryResult, type UseMutationOptions, type UseMutationResult, type UseQueryOptions, type UseQueryResult, useMutation } from '@tanstack/react-query';
|
|
2
|
-
import {
|
|
2
|
+
import type { Evaluate, ExactPartial, Omit, UnionOmit } from '@wagmi/core/internal';
|
|
3
3
|
export type UseMutationParameters<data = unknown, error = Error, variables = void, context = unknown> = Evaluate<Omit<UseMutationOptions<data, error, Evaluate<variables>, context>, 'mutationFn' | 'mutationKey' | 'throwOnError'>>;
|
|
4
4
|
export type UseMutationReturnType<data = unknown, error = Error, variables = void, context = unknown> = Evaluate<UnionOmit<UseMutationResult<data, error, variables, context>, 'mutate' | 'mutateAsync'>>;
|
|
5
5
|
export { useMutation };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"query.d.ts","sourceRoot":"","sources":["../../../src/utils/query.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,YAAY,EACjB,KAAK,QAAQ,EACb,KAAK,uBAAuB,EAC5B,KAAK,sBAAsB,EAC3B,KAAK,kBAAkB,EACvB,KAAK,iBAAiB,EACtB,KAAK,eAAe,EACpB,KAAK,cAAc,
|
|
1
|
+
{"version":3,"file":"query.d.ts","sourceRoot":"","sources":["../../../src/utils/query.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,YAAY,EACjB,KAAK,QAAQ,EACb,KAAK,uBAAuB,EAC5B,KAAK,sBAAsB,EAC3B,KAAK,kBAAkB,EACvB,KAAK,iBAAiB,EACtB,KAAK,eAAe,EACpB,KAAK,cAAc,EAGnB,WAAW,EACZ,MAAM,uBAAuB,CAAA;AAC9B,OAAO,KAAK,EACV,QAAQ,EACR,YAAY,EACZ,IAAI,EACJ,SAAS,EACV,MAAM,sBAAsB,CAAA;AAG7B,MAAM,MAAM,qBAAqB,CAC/B,IAAI,GAAG,OAAO,EACd,KAAK,GAAG,KAAK,EAC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,IAAI,EAAE,QAAQ,CAAC,GAAG;IACnE,QAAQ,EAAE,QAAQ,CAAA;CACnB,GACA,kBAAkB,CAAC,IAAI,EAAE,KAAK,CAAC,CAOjC;AAID,MAAM,MAAM,0BAA0B,CACpC,WAAW,GAAG,OAAO,EACrB,KAAK,GAAG,YAAY,EACpB,IAAI,GAAG,WAAW,EAClB,SAAS,GAAG,WAAW,EACvB,QAAQ,SAAS,QAAQ,GAAG,QAAQ,EACpC,SAAS,GAAG,OAAO,IACjB,QAAQ,CACV,IAAI,CACF,uBAAuB,CACrB,WAAW,EACX,KAAK,EACL,IAAI,EACJ,SAAS,EACT,QAAQ,EACR,SAAS,CACV,EACD,aAAa,CACd,GAAG;IAEF,WAAW,CAAC,EACR,uBAAuB,CACrB,WAAW,EACX,KAAK,EACL,IAAI,EACJ,QAAQ,CACT,CAAC,aAAa,CAAC,GAChB,SAAS,CAAA;CACd,CACF,CAAA;AAED,MAAM,MAAM,0BAA0B,CACpC,IAAI,GAAG,OAAO,EACd,KAAK,GAAG,YAAY,IAClB,sBAAsB,CAAC,IAAI,EAAE,KAAK,CAAC,GAAG;IACxC,QAAQ,EAAE,QAAQ,CAAA;CACnB,CAAA;AAGD,wBAAgB,gBAAgB,CAC9B,WAAW,EACX,KAAK,EACL,IAAI,EACJ,QAAQ,SAAS,QAAQ,EAEzB,UAAU,EAAE,0BAA0B,CAAC,WAAW,EAAE,KAAK,EAAE,IAAI,EAAE,QAAQ,CAAC,GAAG;IAC3E,QAAQ,EAAE,QAAQ,CAAA;CACnB,GACA,0BAA0B,CAAC,IAAI,EAAE,KAAK,CAAC,CAOzC"}
|
package/dist/types/version.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare const version = "2.9.
|
|
1
|
+
export declare const version = "2.9.8";
|
|
2
2
|
//# sourceMappingURL=version.d.ts.map
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "wagmi",
|
|
3
3
|
"description": "React Hooks for Ethereum",
|
|
4
|
-
"version": "2.9.
|
|
4
|
+
"version": "2.9.8",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"repository": {
|
|
7
7
|
"type": "git",
|
|
@@ -92,8 +92,8 @@
|
|
|
92
92
|
},
|
|
93
93
|
"dependencies": {
|
|
94
94
|
"use-sync-external-store": "1.2.0",
|
|
95
|
-
"@wagmi/connectors": "5.0.
|
|
96
|
-
"@wagmi/core": "2.10.
|
|
95
|
+
"@wagmi/connectors": "5.0.7",
|
|
96
|
+
"@wagmi/core": "2.10.5"
|
|
97
97
|
},
|
|
98
98
|
"contributors": [
|
|
99
99
|
"awkweb.eth <t@wevm.dev>",
|
package/src/context.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
'use client'
|
|
2
2
|
|
|
3
|
-
import {
|
|
3
|
+
import type { Config, ResolvedRegister } from '@wagmi/core'
|
|
4
4
|
import {
|
|
5
5
|
type GetCallsStatusData,
|
|
6
6
|
type GetCallsStatusErrorType,
|
|
@@ -9,7 +9,7 @@ import {
|
|
|
9
9
|
type GetCallsStatusQueryKey,
|
|
10
10
|
getCallsStatusQueryOptions,
|
|
11
11
|
} from '@wagmi/core/experimental'
|
|
12
|
-
import {
|
|
12
|
+
import type { Evaluate } from '@wagmi/core/internal'
|
|
13
13
|
|
|
14
14
|
import { useConfig } from '../../hooks/useConfig.js'
|
|
15
15
|
import type { ConfigParameter, QueryParameter } from '../../types/properties.js'
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
'use client'
|
|
2
2
|
|
|
3
|
-
import {
|
|
3
|
+
import type { Config, ResolvedRegister } from '@wagmi/core'
|
|
4
4
|
import {
|
|
5
5
|
type GetCapabilitiesData,
|
|
6
6
|
type GetCapabilitiesErrorType,
|
|
@@ -9,7 +9,7 @@ import {
|
|
|
9
9
|
type GetCapabilitiesQueryKey,
|
|
10
10
|
getCapabilitiesQueryOptions,
|
|
11
11
|
} from '@wagmi/core/experimental'
|
|
12
|
-
import {
|
|
12
|
+
import type { Evaluate } from '@wagmi/core/internal'
|
|
13
13
|
|
|
14
14
|
import { useAccount } from '../../hooks/useAccount.js'
|
|
15
15
|
import { useConfig } from '../../hooks/useConfig.js'
|
|
@@ -35,7 +35,7 @@ export type UseShowCallsStatusParameters<
|
|
|
35
35
|
}
|
|
36
36
|
>
|
|
37
37
|
|
|
38
|
-
export type UseShowCallsStatusReturnType<context = unknown
|
|
38
|
+
export type UseShowCallsStatusReturnType<context = unknown> = Evaluate<
|
|
39
39
|
UseMutationReturnType<
|
|
40
40
|
ShowCallsStatusData,
|
|
41
41
|
ShowCallsStatusErrorType,
|
|
@@ -59,7 +59,8 @@ export type UseWriteContractsReturnType<
|
|
|
59
59
|
|
|
60
60
|
/** https://wagmi.sh/react/api/hooks/useWriteContracts */
|
|
61
61
|
export function useWriteContracts<
|
|
62
|
-
const contracts extends
|
|
62
|
+
const contracts extends
|
|
63
|
+
readonly unknown[] = readonly ContractFunctionParameters[],
|
|
63
64
|
config extends Config = ResolvedRegister['config'],
|
|
64
65
|
context = unknown,
|
|
65
66
|
>(
|
package/src/exports/actions.ts
CHANGED
|
@@ -2,4 +2,6 @@
|
|
|
2
2
|
// @wagmi/core/actions
|
|
3
3
|
////////////////////////////////////////////////////////////////////////////////
|
|
4
4
|
|
|
5
|
+
// biome-ignore lint/performance/noBarrelFile: entrypoint module
|
|
6
|
+
// biome-ignore lint/performance/noReExportAll: entrypoint module
|
|
5
7
|
export * from '@wagmi/core/actions'
|
package/src/exports/chains.ts
CHANGED
package/src/exports/codegen.ts
CHANGED
|
@@ -2,6 +2,8 @@
|
|
|
2
2
|
// @wagmi/core/codegen
|
|
3
3
|
////////////////////////////////////////////////////////////////////////////////
|
|
4
4
|
|
|
5
|
+
// biome-ignore lint/performance/noBarrelFile: entrypoint module
|
|
6
|
+
// biome-ignore lint/performance/noReExportAll: entrypoint module
|
|
5
7
|
export * from '@wagmi/core/codegen'
|
|
6
8
|
|
|
7
9
|
////////////////////////////////////////////////////////////////////////////////
|
|
@@ -2,4 +2,6 @@
|
|
|
2
2
|
// @wagmi/connectors
|
|
3
3
|
////////////////////////////////////////////////////////////////////////////////
|
|
4
4
|
|
|
5
|
+
// biome-ignore lint/performance/noBarrelFile: entrypoint module
|
|
6
|
+
// biome-ignore lint/performance/noReExportAll: entrypoint module
|
|
5
7
|
export * from '@wagmi/connectors'
|
package/src/exports/index.ts
CHANGED
package/src/exports/query.ts
CHANGED
|
@@ -2,6 +2,8 @@
|
|
|
2
2
|
// @wagmi/core/query
|
|
3
3
|
////////////////////////////////////////////////////////////////////////////////
|
|
4
4
|
|
|
5
|
+
// biome-ignore lint/performance/noBarrelFile: entrypoint module
|
|
6
|
+
// biome-ignore lint/performance/noReExportAll: entrypoint module
|
|
5
7
|
export * from '@wagmi/core/query'
|
|
6
8
|
|
|
7
9
|
export {
|
|
@@ -1,31 +1,28 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
1
|
+
import type {
|
|
2
|
+
Config,
|
|
3
|
+
ReadContractErrorType,
|
|
4
|
+
ReadContractParameters,
|
|
5
|
+
ResolvedRegister,
|
|
6
6
|
} from '@wagmi/core'
|
|
7
|
-
import {
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
7
|
+
import type {
|
|
8
|
+
ScopeKeyParameter,
|
|
9
|
+
UnionEvaluate,
|
|
10
|
+
UnionOmit,
|
|
11
|
+
UnionPartial,
|
|
12
12
|
} from '@wagmi/core/internal'
|
|
13
|
-
import {
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
13
|
+
import type {
|
|
14
|
+
ReadContractData,
|
|
15
|
+
ReadContractQueryFnData,
|
|
16
|
+
ReadContractQueryKey,
|
|
17
17
|
} from '@wagmi/core/query'
|
|
18
|
-
import {
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
18
|
+
import type {
|
|
19
|
+
Abi,
|
|
20
|
+
Address,
|
|
21
|
+
ContractFunctionArgs,
|
|
22
|
+
ContractFunctionName,
|
|
23
23
|
} from 'viem'
|
|
24
24
|
|
|
25
|
-
import {
|
|
26
|
-
type ConfigParameter,
|
|
27
|
-
type QueryParameter,
|
|
28
|
-
} from '../../types/properties.js'
|
|
25
|
+
import type { ConfigParameter, QueryParameter } from '../../types/properties.js'
|
|
29
26
|
import { useAccount } from '../useAccount.js'
|
|
30
27
|
import { useChainId } from '../useChainId.js'
|
|
31
28
|
import { useConfig } from '../useConfig.js'
|
|
@@ -1,26 +1,23 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
1
|
+
import type {
|
|
2
|
+
Config,
|
|
3
|
+
ResolvedRegister,
|
|
4
|
+
SimulateContractErrorType,
|
|
5
|
+
SimulateContractParameters,
|
|
6
6
|
} from '@wagmi/core'
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
7
|
+
import type { ScopeKeyParameter, UnionPartial } from '@wagmi/core/internal'
|
|
8
|
+
import type {
|
|
9
|
+
SimulateContractData,
|
|
10
|
+
SimulateContractQueryFnData,
|
|
11
|
+
SimulateContractQueryKey,
|
|
12
12
|
} from '@wagmi/core/query'
|
|
13
|
-
import {
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
13
|
+
import type {
|
|
14
|
+
Abi,
|
|
15
|
+
Address,
|
|
16
|
+
ContractFunctionArgs,
|
|
17
|
+
ContractFunctionName,
|
|
18
18
|
} from 'viem'
|
|
19
19
|
|
|
20
|
-
import {
|
|
21
|
-
type ConfigParameter,
|
|
22
|
-
type QueryParameter,
|
|
23
|
-
} from '../../types/properties.js'
|
|
20
|
+
import type { ConfigParameter, QueryParameter } from '../../types/properties.js'
|
|
24
21
|
import { useAccount } from '../useAccount.js'
|
|
25
22
|
import { useChainId } from '../useChainId.js'
|
|
26
23
|
import { useConfig } from '../useConfig.js'
|
|
@@ -1,18 +1,18 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
1
|
+
import type {
|
|
2
|
+
Config,
|
|
3
|
+
ResolvedRegister,
|
|
4
|
+
WatchContractEventParameters,
|
|
5
5
|
} from '@wagmi/core'
|
|
6
|
-
import {
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
6
|
+
import type {
|
|
7
|
+
UnionEvaluate,
|
|
8
|
+
UnionOmit,
|
|
9
|
+
UnionPartial,
|
|
10
10
|
} from '@wagmi/core/internal'
|
|
11
|
-
import {
|
|
11
|
+
import type { Abi, Address, ContractEventName } from 'viem'
|
|
12
12
|
|
|
13
|
-
import {
|
|
14
|
-
|
|
15
|
-
|
|
13
|
+
import type {
|
|
14
|
+
ConfigParameter,
|
|
15
|
+
EnabledParameter,
|
|
16
16
|
} from '../../types/properties.js'
|
|
17
17
|
import { useAccount } from '../useAccount.js'
|
|
18
18
|
import { useChainId } from '../useChainId.js'
|
|
@@ -45,7 +45,8 @@ export type CreateUseWatchContractEventReturnType<
|
|
|
45
45
|
: ContractEventName<abi>,
|
|
46
46
|
strict extends boolean | undefined = undefined,
|
|
47
47
|
config extends Config = ResolvedRegister['config'],
|
|
48
|
-
chainId extends
|
|
48
|
+
chainId extends
|
|
49
|
+
config['chains'][number]['id'] = config['chains'][number]['id'],
|
|
49
50
|
>(
|
|
50
51
|
parameters?: UnionEvaluate<
|
|
51
52
|
UnionPartial<
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
1
|
+
import type { MutateOptions } from '@tanstack/react-query'
|
|
2
|
+
import type {
|
|
3
|
+
Config,
|
|
4
|
+
ResolvedRegister,
|
|
5
|
+
WriteContractErrorType,
|
|
6
6
|
} from '@wagmi/core'
|
|
7
7
|
import type {
|
|
8
8
|
ChainIdParameter,
|
|
@@ -12,28 +12,28 @@ import type {
|
|
|
12
12
|
UnionEvaluate,
|
|
13
13
|
UnionOmit,
|
|
14
14
|
} from '@wagmi/core/internal'
|
|
15
|
-
import {
|
|
16
|
-
|
|
17
|
-
|
|
15
|
+
import type {
|
|
16
|
+
WriteContractData,
|
|
17
|
+
WriteContractVariables,
|
|
18
18
|
} from '@wagmi/core/query'
|
|
19
19
|
import { useCallback } from 'react'
|
|
20
|
-
import {
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
20
|
+
import type {
|
|
21
|
+
Abi,
|
|
22
|
+
Account,
|
|
23
|
+
Address,
|
|
24
|
+
Chain,
|
|
25
|
+
ContractFunctionArgs,
|
|
26
|
+
ContractFunctionName,
|
|
27
27
|
} from 'viem'
|
|
28
|
-
import {
|
|
28
|
+
import type { WriteContractParameters as viem_WriteContractParameters } from 'viem/actions'
|
|
29
29
|
|
|
30
30
|
import { useAccount } from '../useAccount.js'
|
|
31
31
|
import { useChainId } from '../useChainId.js'
|
|
32
32
|
import { useConfig } from '../useConfig.js'
|
|
33
33
|
import {
|
|
34
34
|
type UseWriteContractParameters,
|
|
35
|
-
type UseWriteContractReturnType as wagmi_UseWriteContractReturnType,
|
|
36
35
|
useWriteContract,
|
|
36
|
+
type UseWriteContractReturnType as wagmi_UseWriteContractReturnType,
|
|
37
37
|
} from '../useWriteContract.js'
|
|
38
38
|
|
|
39
39
|
type stateMutability = 'nonpayable' | 'payable'
|
|
@@ -164,7 +164,7 @@ export function createUseWriteContract<
|
|
|
164
164
|
...(result as any),
|
|
165
165
|
writeContract: useCallback(
|
|
166
166
|
(...args: Args) => {
|
|
167
|
-
let chainId
|
|
167
|
+
let chainId: number | undefined
|
|
168
168
|
if (args[0].chainId) chainId = args[0].chainId
|
|
169
169
|
else if (args[0].account && args[0].account === account.address)
|
|
170
170
|
chainId = account.chainId
|
|
@@ -191,7 +191,7 @@ export function createUseWriteContract<
|
|
|
191
191
|
),
|
|
192
192
|
writeContractAsync: useCallback(
|
|
193
193
|
(...args: Args) => {
|
|
194
|
-
let chainId
|
|
194
|
+
let chainId: number | undefined
|
|
195
195
|
if (args[0].chainId) chainId = args[0].chainId
|
|
196
196
|
else if (args[0].account && args[0].account === account.address)
|
|
197
197
|
chainId = account.chainId
|
package/src/hooks/useAccount.ts
CHANGED
|
@@ -8,7 +8,7 @@ import {
|
|
|
8
8
|
watchAccount,
|
|
9
9
|
} from '@wagmi/core'
|
|
10
10
|
|
|
11
|
-
import {
|
|
11
|
+
import type { ConfigParameter } from '../types/properties.js'
|
|
12
12
|
import { useConfig } from './useConfig.js'
|
|
13
13
|
import { useSyncExternalStoreWithTracked } from './useSyncExternalStoreWithTracked.js'
|
|
14
14
|
|
package/src/hooks/useBalance.ts
CHANGED
|
@@ -1,10 +1,6 @@
|
|
|
1
1
|
'use client'
|
|
2
2
|
|
|
3
|
-
import {
|
|
4
|
-
type Config,
|
|
5
|
-
type GetBalanceErrorType,
|
|
6
|
-
type ResolvedRegister,
|
|
7
|
-
} from '@wagmi/core'
|
|
3
|
+
import type { Config, GetBalanceErrorType, ResolvedRegister } from '@wagmi/core'
|
|
8
4
|
import type { Evaluate } from '@wagmi/core/internal'
|
|
9
5
|
import {
|
|
10
6
|
type GetBalanceData,
|
package/src/hooks/useBlock.ts
CHANGED
|
@@ -1,16 +1,8 @@
|
|
|
1
1
|
'use client'
|
|
2
2
|
|
|
3
3
|
import { useQueryClient } from '@tanstack/react-query'
|
|
4
|
-
import {
|
|
5
|
-
|
|
6
|
-
type GetBlockErrorType,
|
|
7
|
-
type ResolvedRegister,
|
|
8
|
-
} from '@wagmi/core'
|
|
9
|
-
import {
|
|
10
|
-
type Evaluate,
|
|
11
|
-
type UnionEvaluate,
|
|
12
|
-
type UnionOmit,
|
|
13
|
-
} from '@wagmi/core/internal'
|
|
4
|
+
import type { Config, GetBlockErrorType, ResolvedRegister } from '@wagmi/core'
|
|
5
|
+
import type { Evaluate, UnionEvaluate, UnionOmit } from '@wagmi/core/internal'
|
|
14
6
|
import {
|
|
15
7
|
type GetBlockData,
|
|
16
8
|
type GetBlockOptions,
|
|
@@ -33,7 +25,8 @@ export type UseBlockParameters<
|
|
|
33
25
|
includeTransactions extends boolean = false,
|
|
34
26
|
blockTag extends BlockTag = 'latest',
|
|
35
27
|
config extends Config = Config,
|
|
36
|
-
chainId extends
|
|
28
|
+
chainId extends
|
|
29
|
+
config['chains'][number]['id'] = config['chains'][number]['id'],
|
|
37
30
|
selectData = GetBlockData<includeTransactions, blockTag, config, chainId>,
|
|
38
31
|
> = Evaluate<
|
|
39
32
|
GetBlockOptions<includeTransactions, blockTag, config, chainId> &
|
|
@@ -65,7 +58,8 @@ export type UseBlockReturnType<
|
|
|
65
58
|
includeTransactions extends boolean = false,
|
|
66
59
|
blockTag extends BlockTag = 'latest',
|
|
67
60
|
config extends Config = Config,
|
|
68
|
-
chainId extends
|
|
61
|
+
chainId extends
|
|
62
|
+
config['chains'][number]['id'] = config['chains'][number]['id'],
|
|
69
63
|
selectData = GetBlockData<includeTransactions, blockTag, config, chainId>,
|
|
70
64
|
> = UseQueryReturnType<selectData, GetBlockErrorType>
|
|
71
65
|
|
|
@@ -74,7 +68,8 @@ export function useBlock<
|
|
|
74
68
|
includeTransactions extends boolean = false,
|
|
75
69
|
blockTag extends BlockTag = 'latest',
|
|
76
70
|
config extends Config = ResolvedRegister['config'],
|
|
77
|
-
chainId extends
|
|
71
|
+
chainId extends
|
|
72
|
+
config['chains'][number]['id'] = config['chains'][number]['id'],
|
|
78
73
|
selectData = GetBlockData<includeTransactions, blockTag, config, chainId>,
|
|
79
74
|
>(
|
|
80
75
|
parameters: UseBlockParameters<
|
|
@@ -1,16 +1,12 @@
|
|
|
1
1
|
'use client'
|
|
2
2
|
|
|
3
3
|
import { useQueryClient } from '@tanstack/react-query'
|
|
4
|
-
import {
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
4
|
+
import type {
|
|
5
|
+
Config,
|
|
6
|
+
GetBlockNumberErrorType,
|
|
7
|
+
ResolvedRegister,
|
|
8
8
|
} from '@wagmi/core'
|
|
9
|
-
import {
|
|
10
|
-
type Evaluate,
|
|
11
|
-
type UnionEvaluate,
|
|
12
|
-
type UnionOmit,
|
|
13
|
-
} from '@wagmi/core/internal'
|
|
9
|
+
import type { Evaluate, UnionEvaluate, UnionOmit } from '@wagmi/core/internal'
|
|
14
10
|
import {
|
|
15
11
|
type GetBlockNumberData,
|
|
16
12
|
type GetBlockNumberOptions,
|
|
@@ -30,7 +26,8 @@ import {
|
|
|
30
26
|
|
|
31
27
|
export type UseBlockNumberParameters<
|
|
32
28
|
config extends Config = Config,
|
|
33
|
-
chainId extends
|
|
29
|
+
chainId extends
|
|
30
|
+
config['chains'][number]['id'] = config['chains'][number]['id'],
|
|
34
31
|
selectData = GetBlockNumberData,
|
|
35
32
|
> = Evaluate<
|
|
36
33
|
GetBlockNumberOptions<config, chainId> &
|
|
@@ -59,7 +56,8 @@ export type UseBlockNumberReturnType<selectData = GetBlockNumberData> =
|
|
|
59
56
|
/** https://wagmi.sh/react/api/hooks/useBlockNumber */
|
|
60
57
|
export function useBlockNumber<
|
|
61
58
|
config extends Config = ResolvedRegister['config'],
|
|
62
|
-
chainId extends
|
|
59
|
+
chainId extends
|
|
60
|
+
config['chains'][number]['id'] = config['chains'][number]['id'],
|
|
63
61
|
selectData = GetBlockNumberData,
|
|
64
62
|
>(
|
|
65
63
|
parameters: UseBlockNumberParameters<config, chainId, selectData> = {},
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
'use client'
|
|
2
2
|
|
|
3
|
-
import {
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
3
|
+
import type {
|
|
4
|
+
Config,
|
|
5
|
+
GetBlockTransactionCountErrorType,
|
|
6
|
+
ResolvedRegister,
|
|
7
7
|
} from '@wagmi/core'
|
|
8
|
-
import {
|
|
8
|
+
import type { UnionEvaluate } from '@wagmi/core/internal'
|
|
9
9
|
import {
|
|
10
10
|
type GetBlockTransactionCountData,
|
|
11
11
|
type GetBlockTransactionCountOptions,
|
|
@@ -21,7 +21,8 @@ import { useConfig } from './useConfig.js'
|
|
|
21
21
|
|
|
22
22
|
export type UseBlockTransactionCountParameters<
|
|
23
23
|
config extends Config = Config,
|
|
24
|
-
chainId extends
|
|
24
|
+
chainId extends
|
|
25
|
+
config['chains'][number]['id'] = config['chains'][number]['id'],
|
|
25
26
|
selectData = GetBlockTransactionCountData,
|
|
26
27
|
> = UnionEvaluate<
|
|
27
28
|
GetBlockTransactionCountOptions<config, chainId> &
|
|
@@ -41,7 +42,8 @@ export type UseBlockTransactionCountReturnType<
|
|
|
41
42
|
/** https://wagmi.sh/react/api/hooks/useBlockTransactionCount */
|
|
42
43
|
export function useBlockTransactionCount<
|
|
43
44
|
config extends Config = ResolvedRegister['config'],
|
|
44
|
-
chainId extends
|
|
45
|
+
chainId extends
|
|
46
|
+
config['chains'][number]['id'] = config['chains'][number]['id'],
|
|
45
47
|
selectData = GetBlockTransactionCountData,
|
|
46
48
|
>(
|
|
47
49
|
parameters: UseBlockTransactionCountParameters<
|
package/src/hooks/useBytecode.ts
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
'use client'
|
|
2
2
|
|
|
3
|
-
import {
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
3
|
+
import type {
|
|
4
|
+
Config,
|
|
5
|
+
GetBytecodeErrorType,
|
|
6
|
+
ResolvedRegister,
|
|
7
7
|
} from '@wagmi/core'
|
|
8
8
|
import type { Evaluate } from '@wagmi/core/internal'
|
|
9
9
|
import {
|
|
@@ -12,11 +12,8 @@ import {
|
|
|
12
12
|
type GetBytecodeQueryKey,
|
|
13
13
|
getBytecodeQueryOptions,
|
|
14
14
|
} from '@wagmi/core/query'
|
|
15
|
-
import {
|
|
16
|
-
import {
|
|
17
|
-
type ConfigParameter,
|
|
18
|
-
type QueryParameter,
|
|
19
|
-
} from '../types/properties.js'
|
|
15
|
+
import type { GetBytecodeQueryFnData } from '@wagmi/core/query'
|
|
16
|
+
import type { ConfigParameter, QueryParameter } from '../types/properties.js'
|
|
20
17
|
import { type UseQueryReturnType, useQuery } from '../utils/query.js'
|
|
21
18
|
import { useChainId } from './useChainId.js'
|
|
22
19
|
import { useConfig } from './useConfig.js'
|