wagmi 3.3.1 → 3.3.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/esm/hooks/codegen/createUseReadContract.js.map +1 -1
- package/dist/esm/hooks/codegen/createUseSimulateContract.js.map +1 -1
- package/dist/esm/hooks/useBalance.js +2 -3
- package/dist/esm/hooks/useBalance.js.map +1 -1
- package/dist/esm/hooks/useBlock.js +10 -13
- package/dist/esm/hooks/useBlock.js.map +1 -1
- package/dist/esm/hooks/useBlockNumber.js +10 -9
- package/dist/esm/hooks/useBlockNumber.js.map +1 -1
- package/dist/esm/hooks/useBlockTransactionCount.js +4 -5
- package/dist/esm/hooks/useBlockTransactionCount.js.map +1 -1
- package/dist/esm/hooks/useBytecode.js +2 -3
- package/dist/esm/hooks/useBytecode.js.map +1 -1
- package/dist/esm/hooks/useCall.js +2 -2
- package/dist/esm/hooks/useCall.js.map +1 -1
- package/dist/esm/hooks/useCallsStatus.js +8 -3
- package/dist/esm/hooks/useCallsStatus.js.map +1 -1
- package/dist/esm/hooks/useCapabilities.js +5 -7
- package/dist/esm/hooks/useCapabilities.js.map +1 -1
- package/dist/esm/hooks/useConnectorClient.js +10 -20
- package/dist/esm/hooks/useConnectorClient.js.map +1 -1
- package/dist/esm/hooks/useEnsAddress.js +2 -3
- package/dist/esm/hooks/useEnsAddress.js.map +1 -1
- package/dist/esm/hooks/useEnsAvatar.js +2 -3
- package/dist/esm/hooks/useEnsAvatar.js.map +1 -1
- package/dist/esm/hooks/useEnsName.js +2 -3
- package/dist/esm/hooks/useEnsName.js.map +1 -1
- package/dist/esm/hooks/useEnsResolver.js +2 -3
- package/dist/esm/hooks/useEnsResolver.js.map +1 -1
- package/dist/esm/hooks/useEnsText.js +2 -3
- package/dist/esm/hooks/useEnsText.js.map +1 -1
- package/dist/esm/hooks/useEstimateFeesPerGas.js +2 -2
- package/dist/esm/hooks/useEstimateFeesPerGas.js.map +1 -1
- package/dist/esm/hooks/useEstimateGas.js +6 -12
- package/dist/esm/hooks/useEstimateGas.js.map +1 -1
- package/dist/esm/hooks/useEstimateMaxPriorityFeePerGas.js +2 -2
- package/dist/esm/hooks/useEstimateMaxPriorityFeePerGas.js.map +1 -1
- package/dist/esm/hooks/useFeeHistory.js +2 -3
- package/dist/esm/hooks/useFeeHistory.js.map +1 -1
- package/dist/esm/hooks/useGasPrice.js +4 -5
- package/dist/esm/hooks/useGasPrice.js.map +1 -1
- package/dist/esm/hooks/usePrepareTransactionRequest.js +2 -7
- package/dist/esm/hooks/usePrepareTransactionRequest.js.map +1 -1
- package/dist/esm/hooks/useProof.js +2 -3
- package/dist/esm/hooks/useProof.js.map +1 -1
- package/dist/esm/hooks/useReadContract.js +6 -11
- package/dist/esm/hooks/useReadContract.js.map +1 -1
- package/dist/esm/hooks/useReadContracts.js +9 -24
- package/dist/esm/hooks/useReadContracts.js.map +1 -1
- package/dist/esm/hooks/useSimulateContract.js +6 -10
- package/dist/esm/hooks/useSimulateContract.js.map +1 -1
- package/dist/esm/hooks/useStorageAt.js +2 -3
- package/dist/esm/hooks/useStorageAt.js.map +1 -1
- package/dist/esm/hooks/useTransaction.js +2 -7
- package/dist/esm/hooks/useTransaction.js.map +1 -1
- package/dist/esm/hooks/useTransactionConfirmations.js +2 -5
- package/dist/esm/hooks/useTransactionConfirmations.js.map +1 -1
- package/dist/esm/hooks/useTransactionCount.js +2 -3
- package/dist/esm/hooks/useTransactionCount.js.map +1 -1
- package/dist/esm/hooks/useTransactionReceipt.js +2 -7
- package/dist/esm/hooks/useTransactionReceipt.js.map +1 -1
- package/dist/esm/hooks/useVerifyMessage.js +2 -3
- package/dist/esm/hooks/useVerifyMessage.js.map +1 -1
- package/dist/esm/hooks/useVerifyTypedData.js +2 -8
- package/dist/esm/hooks/useVerifyTypedData.js.map +1 -1
- package/dist/esm/hooks/useWaitForCallsStatus.js +8 -4
- package/dist/esm/hooks/useWaitForCallsStatus.js.map +1 -1
- package/dist/esm/hooks/useWaitForTransactionReceipt.js +2 -7
- package/dist/esm/hooks/useWaitForTransactionReceipt.js.map +1 -1
- package/dist/esm/hooks/useWalletClient.js +9 -19
- package/dist/esm/hooks/useWalletClient.js.map +1 -1
- package/dist/esm/tempo/hooks/amm.js.map +1 -1
- package/dist/esm/tempo/hooks/dex.js.map +1 -1
- package/dist/esm/tempo/hooks/fee.js.map +1 -1
- package/dist/esm/tempo/hooks/nonce.js.map +1 -1
- package/dist/esm/tempo/hooks/policy.js.map +1 -1
- package/dist/esm/tempo/hooks/reward.js.map +1 -1
- package/dist/esm/tempo/hooks/token.js.map +1 -1
- package/dist/esm/tempo/utils.js +2 -0
- package/dist/esm/tempo/utils.js.map +1 -0
- package/dist/esm/tsconfig.build.tsbuildinfo +1 -1
- package/dist/esm/version.js +1 -1
- package/dist/types/exports/internal.d.ts +1 -1
- package/dist/types/exports/internal.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/useBalance.d.ts +3 -4
- package/dist/types/hooks/useBalance.d.ts.map +1 -1
- package/dist/types/hooks/useBlock.d.ts +3 -3
- package/dist/types/hooks/useBlock.d.ts.map +1 -1
- package/dist/types/hooks/useBlockNumber.d.ts +3 -3
- package/dist/types/hooks/useBlockNumber.d.ts.map +1 -1
- package/dist/types/hooks/useBlockTransactionCount.d.ts +3 -3
- package/dist/types/hooks/useBlockTransactionCount.d.ts.map +1 -1
- package/dist/types/hooks/useBytecode.d.ts +3 -4
- package/dist/types/hooks/useBytecode.d.ts.map +1 -1
- package/dist/types/hooks/useCall.d.ts +3 -4
- package/dist/types/hooks/useCall.d.ts.map +1 -1
- package/dist/types/hooks/useCallsStatus.d.ts +3 -3
- package/dist/types/hooks/useCallsStatus.d.ts.map +1 -1
- package/dist/types/hooks/useCapabilities.d.ts +3 -3
- package/dist/types/hooks/useCapabilities.d.ts.map +1 -1
- package/dist/types/hooks/useConnectorClient.d.ts +4 -6
- package/dist/types/hooks/useConnectorClient.d.ts.map +1 -1
- package/dist/types/hooks/useEnsAddress.d.ts +3 -3
- package/dist/types/hooks/useEnsAddress.d.ts.map +1 -1
- package/dist/types/hooks/useEnsAvatar.d.ts +3 -3
- package/dist/types/hooks/useEnsAvatar.d.ts.map +1 -1
- package/dist/types/hooks/useEnsName.d.ts +3 -3
- package/dist/types/hooks/useEnsName.d.ts.map +1 -1
- package/dist/types/hooks/useEnsResolver.d.ts +3 -3
- package/dist/types/hooks/useEnsResolver.d.ts.map +1 -1
- package/dist/types/hooks/useEnsText.d.ts +3 -3
- package/dist/types/hooks/useEnsText.d.ts.map +1 -1
- package/dist/types/hooks/useEstimateFeesPerGas.d.ts +3 -3
- package/dist/types/hooks/useEstimateFeesPerGas.d.ts.map +1 -1
- package/dist/types/hooks/useEstimateGas.d.ts +3 -3
- package/dist/types/hooks/useEstimateGas.d.ts.map +1 -1
- package/dist/types/hooks/useEstimateMaxPriorityFeePerGas.d.ts +3 -3
- package/dist/types/hooks/useEstimateMaxPriorityFeePerGas.d.ts.map +1 -1
- package/dist/types/hooks/useFeeHistory.d.ts +3 -3
- package/dist/types/hooks/useFeeHistory.d.ts.map +1 -1
- package/dist/types/hooks/useGasPrice.d.ts +3 -3
- package/dist/types/hooks/useGasPrice.d.ts.map +1 -1
- package/dist/types/hooks/usePrepareTransactionRequest.d.ts +3 -4
- package/dist/types/hooks/usePrepareTransactionRequest.d.ts.map +1 -1
- package/dist/types/hooks/useProof.d.ts +3 -4
- 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 +3 -3
- package/dist/types/hooks/useReadContracts.d.ts.map +1 -1
- package/dist/types/hooks/useSimulateContract.d.ts +4 -4
- package/dist/types/hooks/useSimulateContract.d.ts.map +1 -1
- package/dist/types/hooks/useStorageAt.d.ts +3 -4
- package/dist/types/hooks/useStorageAt.d.ts.map +1 -1
- package/dist/types/hooks/useTransaction.d.ts +3 -3
- package/dist/types/hooks/useTransaction.d.ts.map +1 -1
- package/dist/types/hooks/useTransactionConfirmations.d.ts +3 -3
- package/dist/types/hooks/useTransactionConfirmations.d.ts.map +1 -1
- package/dist/types/hooks/useTransactionCount.d.ts +3 -4
- package/dist/types/hooks/useTransactionCount.d.ts.map +1 -1
- package/dist/types/hooks/useTransactionReceipt.d.ts +3 -4
- package/dist/types/hooks/useTransactionReceipt.d.ts.map +1 -1
- package/dist/types/hooks/useVerifyMessage.d.ts +3 -4
- package/dist/types/hooks/useVerifyMessage.d.ts.map +1 -1
- package/dist/types/hooks/useVerifyTypedData.d.ts +3 -4
- package/dist/types/hooks/useVerifyTypedData.d.ts.map +1 -1
- package/dist/types/hooks/useWaitForCallsStatus.d.ts +3 -3
- package/dist/types/hooks/useWaitForCallsStatus.d.ts.map +1 -1
- package/dist/types/hooks/useWaitForTransactionReceipt.d.ts +3 -3
- package/dist/types/hooks/useWaitForTransactionReceipt.d.ts.map +1 -1
- package/dist/types/hooks/useWalletClient.d.ts +4 -6
- package/dist/types/hooks/useWalletClient.d.ts.map +1 -1
- package/dist/types/tempo/hooks/amm.d.ts +4 -3
- package/dist/types/tempo/hooks/amm.d.ts.map +1 -1
- package/dist/types/tempo/hooks/dex.d.ts +8 -7
- package/dist/types/tempo/hooks/dex.d.ts.map +1 -1
- package/dist/types/tempo/hooks/fee.d.ts +3 -2
- package/dist/types/tempo/hooks/fee.d.ts.map +1 -1
- package/dist/types/tempo/hooks/nonce.d.ts +3 -2
- package/dist/types/tempo/hooks/nonce.d.ts.map +1 -1
- package/dist/types/tempo/hooks/policy.d.ts +4 -3
- package/dist/types/tempo/hooks/policy.d.ts.map +1 -1
- package/dist/types/tempo/hooks/reward.d.ts +4 -3
- package/dist/types/tempo/hooks/reward.d.ts.map +1 -1
- package/dist/types/tempo/hooks/token.d.ts +7 -6
- package/dist/types/tempo/hooks/token.d.ts.map +1 -1
- package/dist/types/tempo/utils.d.ts +6 -0
- package/dist/types/tempo/utils.d.ts.map +1 -0
- package/dist/types/types/properties.d.ts +1 -4
- package/dist/types/types/properties.d.ts.map +1 -1
- package/dist/types/version.d.ts +1 -1
- package/package.json +3 -3
- package/src/exports/internal.ts +1 -4
- package/src/hooks/codegen/createUseReadContract.ts +9 -10
- package/src/hooks/codegen/createUseSimulateContract.ts +9 -6
- package/src/hooks/useBalance.ts +4 -21
- package/src/hooks/useBlock.ts +13 -36
- package/src/hooks/useBlockNumber.ts +13 -26
- package/src/hooks/useBlockTransactionCount.ts +7 -21
- package/src/hooks/useBytecode.ts +4 -20
- package/src/hooks/useCall.ts +4 -20
- package/src/hooks/useCallsStatus.ts +10 -21
- package/src/hooks/useCapabilities.ts +7 -23
- package/src/hooks/useConnectorClient.ts +13 -50
- package/src/hooks/useEnsAddress.ts +4 -21
- package/src/hooks/useEnsAvatar.ts +4 -21
- package/src/hooks/useEnsName.ts +4 -21
- package/src/hooks/useEnsResolver.ts +4 -21
- package/src/hooks/useEnsText.ts +4 -21
- package/src/hooks/useEstimateFeesPerGas.ts +4 -18
- package/src/hooks/useEstimateGas.ts +8 -28
- package/src/hooks/useEstimateMaxPriorityFeePerGas.ts +5 -18
- package/src/hooks/useFeeHistory.ts +4 -21
- package/src/hooks/useGasPrice.ts +6 -21
- package/src/hooks/usePrepareTransactionRequest.ts +5 -28
- package/src/hooks/useProof.ts +4 -21
- package/src/hooks/useReadContract.ts +9 -33
- package/src/hooks/useReadContracts.ts +13 -45
- package/src/hooks/useSimulateContract.ts +19 -37
- package/src/hooks/useStorageAt.ts +4 -20
- package/src/hooks/useTransaction.ts +4 -25
- package/src/hooks/useTransactionConfirmations.ts +5 -23
- package/src/hooks/useTransactionCount.ts +4 -19
- package/src/hooks/useTransactionReceipt.ts +5 -22
- package/src/hooks/useVerifyMessage.ts +4 -22
- package/src/hooks/useVerifyTypedData.ts +9 -39
- package/src/hooks/useWaitForCallsStatus.ts +10 -22
- package/src/hooks/useWaitForTransactionReceipt.ts +5 -23
- package/src/hooks/useWalletClient.ts +15 -56
- package/src/tempo/hooks/amm.ts +4 -16
- package/src/tempo/hooks/dex.ts +8 -25
- package/src/tempo/hooks/fee.ts +3 -5
- package/src/tempo/hooks/nonce.ts +3 -7
- package/src/tempo/hooks/policy.ts +4 -13
- package/src/tempo/hooks/reward.ts +4 -19
- package/src/tempo/hooks/token.ts +7 -31
- package/src/tempo/utils.ts +16 -0
- package/src/types/properties.ts +1 -18
- package/src/version.ts +1 -1
package/src/tempo/hooks/dex.ts
CHANGED
|
@@ -6,13 +6,14 @@ import { useEffect } from 'react'
|
|
|
6
6
|
|
|
7
7
|
import { useChainId } from '../../hooks/useChainId.js'
|
|
8
8
|
import { useConfig } from '../../hooks/useConfig.js'
|
|
9
|
-
import type { ConfigParameter
|
|
9
|
+
import type { ConfigParameter } from '../../types/properties.js'
|
|
10
10
|
import {
|
|
11
11
|
type UseMutationParameters,
|
|
12
12
|
type UseQueryReturnType,
|
|
13
13
|
useMutation,
|
|
14
14
|
useQuery,
|
|
15
15
|
} from '../../utils/query.js'
|
|
16
|
+
import type { QueryParameter } from '../utils.js'
|
|
16
17
|
|
|
17
18
|
/**
|
|
18
19
|
* Hook for buying a specific amount of tokens.
|
|
@@ -622,10 +623,7 @@ export declare namespace useBalance {
|
|
|
622
623
|
selectData,
|
|
623
624
|
Actions.dex.getBalance.QueryKey<config>
|
|
624
625
|
> &
|
|
625
|
-
|
|
626
|
-
Actions.dex.getBalance.queryOptions.Parameters<config, selectData>,
|
|
627
|
-
'query'
|
|
628
|
-
>
|
|
626
|
+
ExactPartial<Actions.dex.getBalance.Parameters<config>>
|
|
629
627
|
|
|
630
628
|
export type ReturnValue<selectData = Actions.dex.getBalance.ReturnValue> =
|
|
631
629
|
UseQueryReturnType<selectData, Error>
|
|
@@ -679,10 +677,7 @@ export declare namespace useBuyQuote {
|
|
|
679
677
|
selectData,
|
|
680
678
|
Actions.dex.getBuyQuote.QueryKey<config>
|
|
681
679
|
> &
|
|
682
|
-
|
|
683
|
-
Actions.dex.getBuyQuote.queryOptions.Parameters<config, selectData>,
|
|
684
|
-
'query'
|
|
685
|
-
>
|
|
680
|
+
ExactPartial<Actions.dex.getBuyQuote.Parameters<config>>
|
|
686
681
|
|
|
687
682
|
export type ReturnValue<selectData = Actions.dex.getBuyQuote.ReturnValue> =
|
|
688
683
|
UseQueryReturnType<selectData, Error>
|
|
@@ -734,10 +729,7 @@ export declare namespace useOrder {
|
|
|
734
729
|
selectData,
|
|
735
730
|
Actions.dex.getOrder.QueryKey<config>
|
|
736
731
|
> &
|
|
737
|
-
|
|
738
|
-
Actions.dex.getOrder.queryOptions.Parameters<config, selectData>,
|
|
739
|
-
'query'
|
|
740
|
-
>
|
|
732
|
+
ExactPartial<Actions.dex.getOrder.Parameters<config>>
|
|
741
733
|
|
|
742
734
|
export type ReturnValue<selectData = Actions.dex.getOrder.ReturnValue> =
|
|
743
735
|
UseQueryReturnType<selectData, Error>
|
|
@@ -790,10 +782,7 @@ export declare namespace useOrderbook {
|
|
|
790
782
|
selectData,
|
|
791
783
|
Actions.dex.getOrderbook.QueryKey<config>
|
|
792
784
|
> &
|
|
793
|
-
|
|
794
|
-
Actions.dex.getOrderbook.queryOptions.Parameters<config, selectData>,
|
|
795
|
-
'query'
|
|
796
|
-
>
|
|
785
|
+
ExactPartial<Actions.dex.getOrderbook.Parameters<config>>
|
|
797
786
|
|
|
798
787
|
export type ReturnValue<selectData = Actions.dex.getOrderbook.ReturnValue> =
|
|
799
788
|
UseQueryReturnType<selectData, Error>
|
|
@@ -848,10 +837,7 @@ export declare namespace useTickLevel {
|
|
|
848
837
|
selectData,
|
|
849
838
|
Actions.dex.getTickLevel.QueryKey<config>
|
|
850
839
|
> &
|
|
851
|
-
|
|
852
|
-
Actions.dex.getTickLevel.queryOptions.Parameters<config, selectData>,
|
|
853
|
-
'query'
|
|
854
|
-
>
|
|
840
|
+
ExactPartial<Actions.dex.getTickLevel.Parameters<config>>
|
|
855
841
|
|
|
856
842
|
export type ReturnValue<selectData = Actions.dex.getTickLevel.ReturnValue> =
|
|
857
843
|
UseQueryReturnType<selectData, Error>
|
|
@@ -905,10 +891,7 @@ export declare namespace useSellQuote {
|
|
|
905
891
|
selectData,
|
|
906
892
|
Actions.dex.getSellQuote.QueryKey<config>
|
|
907
893
|
> &
|
|
908
|
-
|
|
909
|
-
Actions.dex.getSellQuote.queryOptions.Parameters<config, selectData>,
|
|
910
|
-
'query'
|
|
911
|
-
>
|
|
894
|
+
ExactPartial<Actions.dex.getSellQuote.Parameters<config>>
|
|
912
895
|
|
|
913
896
|
export type ReturnValue<selectData = Actions.dex.getSellQuote.ReturnValue> =
|
|
914
897
|
UseQueryReturnType<selectData, Error>
|
package/src/tempo/hooks/fee.ts
CHANGED
|
@@ -6,13 +6,14 @@ import { useEffect } from 'react'
|
|
|
6
6
|
|
|
7
7
|
import { useChainId } from '../../hooks/useChainId.js'
|
|
8
8
|
import { useConfig } from '../../hooks/useConfig.js'
|
|
9
|
-
import type { ConfigParameter
|
|
9
|
+
import type { ConfigParameter } from '../../types/properties.js'
|
|
10
10
|
import {
|
|
11
11
|
type UseMutationParameters,
|
|
12
12
|
type UseQueryReturnType,
|
|
13
13
|
useMutation,
|
|
14
14
|
useQuery,
|
|
15
15
|
} from '../../utils/query.js'
|
|
16
|
+
import type { QueryParameter } from '../utils.js'
|
|
16
17
|
|
|
17
18
|
/**
|
|
18
19
|
* Hook for getting the user's default fee token.
|
|
@@ -60,10 +61,7 @@ export declare namespace useUserToken {
|
|
|
60
61
|
selectData,
|
|
61
62
|
Actions.fee.getUserToken.QueryKey<config>
|
|
62
63
|
> &
|
|
63
|
-
|
|
64
|
-
Actions.fee.getUserToken.queryOptions.Parameters<config, selectData>,
|
|
65
|
-
'query'
|
|
66
|
-
>
|
|
64
|
+
ExactPartial<Actions.fee.getUserToken.Parameters<config>>
|
|
67
65
|
|
|
68
66
|
export type ReturnValue<selectData = Actions.fee.getUserToken.ReturnValue> =
|
|
69
67
|
UseQueryReturnType<selectData, Error>
|
package/src/tempo/hooks/nonce.ts
CHANGED
|
@@ -5,8 +5,9 @@ import { useEffect } from 'react'
|
|
|
5
5
|
|
|
6
6
|
import { useChainId } from '../../hooks/useChainId.js'
|
|
7
7
|
import { useConfig } from '../../hooks/useConfig.js'
|
|
8
|
-
import type { ConfigParameter
|
|
8
|
+
import type { ConfigParameter } from '../../types/properties.js'
|
|
9
9
|
import { type UseQueryReturnType, useQuery } from '../../utils/query.js'
|
|
10
|
+
import type { QueryParameter } from '../utils.js'
|
|
10
11
|
|
|
11
12
|
/**
|
|
12
13
|
* Hook for getting the nonce for an account and nonce key.
|
|
@@ -55,12 +56,7 @@ export declare namespace useNonce {
|
|
|
55
56
|
selectData,
|
|
56
57
|
Actions.nonce.getNonce.QueryKey<config>
|
|
57
58
|
> &
|
|
58
|
-
ExactPartial<
|
|
59
|
-
Omit<
|
|
60
|
-
Actions.nonce.getNonce.queryOptions.Parameters<config, selectData>,
|
|
61
|
-
'query'
|
|
62
|
-
>
|
|
63
|
-
>
|
|
59
|
+
ExactPartial<Actions.nonce.getNonce.Parameters<config>>
|
|
64
60
|
|
|
65
61
|
export type ReturnValue<selectData = Actions.nonce.getNonce.ReturnValue> =
|
|
66
62
|
UseQueryReturnType<selectData, Error>
|
|
@@ -6,13 +6,14 @@ import { useEffect } from 'react'
|
|
|
6
6
|
|
|
7
7
|
import { useChainId } from '../../hooks/useChainId.js'
|
|
8
8
|
import { useConfig } from '../../hooks/useConfig.js'
|
|
9
|
-
import type { ConfigParameter
|
|
9
|
+
import type { ConfigParameter } from '../../types/properties.js'
|
|
10
10
|
import {
|
|
11
11
|
type UseMutationParameters,
|
|
12
12
|
type UseQueryReturnType,
|
|
13
13
|
useMutation,
|
|
14
14
|
useQuery,
|
|
15
15
|
} from '../../utils/query.js'
|
|
16
|
+
import type { QueryParameter } from '../utils.js'
|
|
16
17
|
|
|
17
18
|
/**
|
|
18
19
|
* Hook for creating a new policy.
|
|
@@ -608,12 +609,7 @@ export declare namespace useData {
|
|
|
608
609
|
selectData,
|
|
609
610
|
Actions.policy.getData.QueryKey<config>
|
|
610
611
|
> &
|
|
611
|
-
ExactPartial<
|
|
612
|
-
Omit<
|
|
613
|
-
Actions.policy.getData.queryOptions.Parameters<config, selectData>,
|
|
614
|
-
'query'
|
|
615
|
-
>
|
|
616
|
-
>
|
|
612
|
+
ExactPartial<Actions.policy.getData.Parameters<config>>
|
|
617
613
|
|
|
618
614
|
export type ReturnValue<selectData = Actions.policy.getData.ReturnValue> =
|
|
619
615
|
UseQueryReturnType<selectData, Error>
|
|
@@ -666,12 +662,7 @@ export declare namespace useIsAuthorized {
|
|
|
666
662
|
selectData,
|
|
667
663
|
Actions.policy.isAuthorized.QueryKey<config>
|
|
668
664
|
> &
|
|
669
|
-
ExactPartial<
|
|
670
|
-
Omit<
|
|
671
|
-
Actions.policy.isAuthorized.queryOptions.Parameters<config, selectData>,
|
|
672
|
-
'query'
|
|
673
|
-
>
|
|
674
|
-
>
|
|
665
|
+
ExactPartial<Actions.policy.isAuthorized.Parameters<config>>
|
|
675
666
|
|
|
676
667
|
export type ReturnValue<
|
|
677
668
|
selectData = Actions.policy.isAuthorized.ReturnValue,
|
|
@@ -6,13 +6,14 @@ import { useEffect } from 'react'
|
|
|
6
6
|
|
|
7
7
|
import { useChainId } from '../../hooks/useChainId.js'
|
|
8
8
|
import { useConfig } from '../../hooks/useConfig.js'
|
|
9
|
-
import type { ConfigParameter
|
|
9
|
+
import type { ConfigParameter } from '../../types/properties.js'
|
|
10
10
|
import {
|
|
11
11
|
type UseMutationParameters,
|
|
12
12
|
type UseQueryReturnType,
|
|
13
13
|
useMutation,
|
|
14
14
|
useQuery,
|
|
15
15
|
} from '../../utils/query.js'
|
|
16
|
+
import type { QueryParameter } from '../utils.js'
|
|
16
17
|
|
|
17
18
|
/**
|
|
18
19
|
* Hook for claiming accumulated rewards.
|
|
@@ -192,15 +193,7 @@ export declare namespace useGetGlobalRewardPerToken {
|
|
|
192
193
|
selectData,
|
|
193
194
|
Actions.reward.getGlobalRewardPerToken.QueryKey<config>
|
|
194
195
|
> &
|
|
195
|
-
ExactPartial<
|
|
196
|
-
Omit<
|
|
197
|
-
Actions.reward.getGlobalRewardPerToken.queryOptions.Parameters<
|
|
198
|
-
config,
|
|
199
|
-
selectData
|
|
200
|
-
>,
|
|
201
|
-
'query'
|
|
202
|
-
>
|
|
203
|
-
>
|
|
196
|
+
ExactPartial<Actions.reward.getGlobalRewardPerToken.Parameters<config>>
|
|
204
197
|
|
|
205
198
|
export type ReturnValue<
|
|
206
199
|
selectData = Actions.reward.getGlobalRewardPerToken.ReturnValue,
|
|
@@ -260,15 +253,7 @@ export declare namespace useUserRewardInfo {
|
|
|
260
253
|
selectData,
|
|
261
254
|
Actions.reward.getUserRewardInfo.QueryKey<config>
|
|
262
255
|
> &
|
|
263
|
-
ExactPartial<
|
|
264
|
-
Omit<
|
|
265
|
-
Actions.reward.getUserRewardInfo.queryOptions.Parameters<
|
|
266
|
-
config,
|
|
267
|
-
selectData
|
|
268
|
-
>,
|
|
269
|
-
'query'
|
|
270
|
-
>
|
|
271
|
-
>
|
|
256
|
+
ExactPartial<Actions.reward.getUserRewardInfo.Parameters<config>>
|
|
272
257
|
|
|
273
258
|
export type ReturnValue<
|
|
274
259
|
selectData = Actions.reward.getUserRewardInfo.ReturnValue,
|
package/src/tempo/hooks/token.ts
CHANGED
|
@@ -6,13 +6,14 @@ import { useEffect } from 'react'
|
|
|
6
6
|
|
|
7
7
|
import { useChainId } from '../../hooks/useChainId.js'
|
|
8
8
|
import { useConfig } from '../../hooks/useConfig.js'
|
|
9
|
-
import type { ConfigParameter
|
|
9
|
+
import type { ConfigParameter } from '../../types/properties.js'
|
|
10
10
|
import {
|
|
11
11
|
type UseMutationParameters,
|
|
12
12
|
type UseQueryReturnType,
|
|
13
13
|
useMutation,
|
|
14
14
|
useQuery,
|
|
15
15
|
} from '../../utils/query.js'
|
|
16
|
+
import type { QueryParameter } from '../utils.js'
|
|
16
17
|
|
|
17
18
|
/**
|
|
18
19
|
* Hook for approving a spender to transfer TIP20 tokens.
|
|
@@ -883,12 +884,7 @@ export declare namespace useGetAllowance {
|
|
|
883
884
|
selectData,
|
|
884
885
|
Actions.token.getAllowance.QueryKey<config>
|
|
885
886
|
> &
|
|
886
|
-
ExactPartial<
|
|
887
|
-
Omit<
|
|
888
|
-
Actions.token.getAllowance.queryOptions.Parameters<config, selectData>,
|
|
889
|
-
'query'
|
|
890
|
-
>
|
|
891
|
-
>
|
|
887
|
+
ExactPartial<Actions.token.getAllowance.Parameters<config>>
|
|
892
888
|
|
|
893
889
|
export type ReturnValue<selectData = Actions.token.getAllowance.ReturnValue> =
|
|
894
890
|
UseQueryReturnType<selectData, Error>
|
|
@@ -940,12 +936,7 @@ export declare namespace useGetBalance {
|
|
|
940
936
|
selectData,
|
|
941
937
|
Actions.token.getBalance.QueryKey<config>
|
|
942
938
|
> &
|
|
943
|
-
ExactPartial<
|
|
944
|
-
Omit<
|
|
945
|
-
Actions.token.getBalance.queryOptions.Parameters<config, selectData>,
|
|
946
|
-
'query'
|
|
947
|
-
>
|
|
948
|
-
>
|
|
939
|
+
ExactPartial<Actions.token.getBalance.Parameters<config>>
|
|
949
940
|
|
|
950
941
|
export type ReturnValue<selectData = Actions.token.getBalance.ReturnValue> =
|
|
951
942
|
UseQueryReturnType<selectData, Error>
|
|
@@ -997,12 +988,7 @@ export declare namespace useGetMetadata {
|
|
|
997
988
|
selectData,
|
|
998
989
|
Actions.token.getMetadata.QueryKey<config>
|
|
999
990
|
> &
|
|
1000
|
-
ExactPartial<
|
|
1001
|
-
Omit<
|
|
1002
|
-
Actions.token.getMetadata.queryOptions.Parameters<config, selectData>,
|
|
1003
|
-
'query'
|
|
1004
|
-
>
|
|
1005
|
-
>
|
|
991
|
+
ExactPartial<Actions.token.getMetadata.Parameters<config>>
|
|
1006
992
|
|
|
1007
993
|
export type ReturnValue<selectData = Actions.token.getMetadata.ReturnValue> =
|
|
1008
994
|
UseQueryReturnType<selectData, Error>
|
|
@@ -1055,12 +1041,7 @@ export declare namespace useGetRoleAdmin {
|
|
|
1055
1041
|
selectData,
|
|
1056
1042
|
Actions.token.getRoleAdmin.QueryKey<config>
|
|
1057
1043
|
> &
|
|
1058
|
-
ExactPartial<
|
|
1059
|
-
Omit<
|
|
1060
|
-
Actions.token.getRoleAdmin.queryOptions.Parameters<config, selectData>,
|
|
1061
|
-
'query'
|
|
1062
|
-
>
|
|
1063
|
-
>
|
|
1044
|
+
ExactPartial<Actions.token.getRoleAdmin.Parameters<config>>
|
|
1064
1045
|
|
|
1065
1046
|
export type ReturnValue<selectData = Actions.token.getRoleAdmin.ReturnValue> =
|
|
1066
1047
|
UseQueryReturnType<selectData, Error>
|
|
@@ -1251,12 +1232,7 @@ export declare namespace useHasRole {
|
|
|
1251
1232
|
selectData,
|
|
1252
1233
|
Actions.token.hasRole.QueryKey<config>
|
|
1253
1234
|
> &
|
|
1254
|
-
ExactPartial<
|
|
1255
|
-
Omit<
|
|
1256
|
-
Actions.token.hasRole.queryOptions.Parameters<config, selectData>,
|
|
1257
|
-
'query'
|
|
1258
|
-
>
|
|
1259
|
-
>
|
|
1235
|
+
ExactPartial<Actions.token.hasRole.Parameters<config>>
|
|
1260
1236
|
|
|
1261
1237
|
export type ReturnValue<selectData = Actions.token.hasRole.ReturnValue> =
|
|
1262
1238
|
UseQueryReturnType<selectData, Error>
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import type * as Query from '@tanstack/react-query'
|
|
2
|
+
import type { UnionLooseOmit } from '@wagmi/core/internal'
|
|
3
|
+
|
|
4
|
+
export type QueryParameter<
|
|
5
|
+
queryFnData = unknown,
|
|
6
|
+
error = Query.DefaultError,
|
|
7
|
+
data = queryFnData,
|
|
8
|
+
queryKey extends Query.QueryKey = Query.QueryKey,
|
|
9
|
+
> = {
|
|
10
|
+
query?:
|
|
11
|
+
| UnionLooseOmit<
|
|
12
|
+
Query.UseQueryOptions<queryFnData, error, data, queryKey>,
|
|
13
|
+
'queryKey' | 'queryFn'
|
|
14
|
+
>
|
|
15
|
+
| undefined
|
|
16
|
+
}
|
package/src/types/properties.ts
CHANGED
|
@@ -2,10 +2,7 @@ import type { DefaultError, QueryKey } from '@tanstack/react-query'
|
|
|
2
2
|
import type { Config } from '@wagmi/core'
|
|
3
3
|
import type { Omit } from '@wagmi/core/internal'
|
|
4
4
|
|
|
5
|
-
import type {
|
|
6
|
-
UseInfiniteQueryParameters,
|
|
7
|
-
UseQueryParameters,
|
|
8
|
-
} from '../utils/query.js'
|
|
5
|
+
import type { UseInfiniteQueryParameters } from '../utils/query.js'
|
|
9
6
|
|
|
10
7
|
export type EnabledParameter = {
|
|
11
8
|
enabled?: boolean | undefined
|
|
@@ -15,20 +12,6 @@ export type ConfigParameter<config extends Config = Config> = {
|
|
|
15
12
|
config?: Config | config | undefined
|
|
16
13
|
}
|
|
17
14
|
|
|
18
|
-
export type QueryParameter<
|
|
19
|
-
queryFnData = unknown,
|
|
20
|
-
error = DefaultError,
|
|
21
|
-
data = queryFnData,
|
|
22
|
-
queryKey extends QueryKey = QueryKey,
|
|
23
|
-
> = {
|
|
24
|
-
query?:
|
|
25
|
-
| Omit<
|
|
26
|
-
UseQueryParameters<queryFnData, error, data, queryKey>,
|
|
27
|
-
'queryFn' | 'queryHash' | 'queryKey' | 'queryKeyHashFn' | 'throwOnError'
|
|
28
|
-
>
|
|
29
|
-
| undefined
|
|
30
|
-
}
|
|
31
|
-
|
|
32
15
|
export type InfiniteQueryParameter<
|
|
33
16
|
queryFnData = unknown,
|
|
34
17
|
error = DefaultError,
|
package/src/version.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export const version = '3.3.
|
|
1
|
+
export const version = '3.3.4'
|