tempo.ts 0.11.1 → 0.12.1
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/CHANGELOG.md +67 -4
- package/README.md +3 -34
- package/dist/server/Handler.d.ts +14 -14
- package/dist/server/Handler.d.ts.map +1 -1
- package/dist/server/Handler.js +16 -17
- package/dist/server/Handler.js.map +1 -1
- package/dist/wagmi/Actions/amm.d.ts +51 -51
- package/dist/wagmi/Actions/amm.d.ts.map +1 -1
- package/dist/wagmi/Actions/amm.js +37 -37
- package/dist/wagmi/Actions/amm.js.map +1 -1
- package/dist/wagmi/Actions/dex.d.ts +129 -129
- package/dist/wagmi/Actions/dex.d.ts.map +1 -1
- package/dist/wagmi/Actions/dex.js +73 -73
- package/dist/wagmi/Actions/dex.js.map +1 -1
- package/dist/wagmi/Actions/faucet.d.ts +9 -9
- package/dist/wagmi/Actions/faucet.d.ts.map +1 -1
- package/dist/wagmi/Actions/faucet.js +7 -7
- package/dist/wagmi/Actions/faucet.js.map +1 -1
- package/dist/wagmi/Actions/fee.d.ts +17 -17
- package/dist/wagmi/Actions/fee.d.ts.map +1 -1
- package/dist/wagmi/Actions/fee.js +10 -10
- package/dist/wagmi/Actions/fee.js.map +1 -1
- package/dist/wagmi/Actions/nonce.d.ts +9 -79
- package/dist/wagmi/Actions/nonce.d.ts.map +1 -1
- package/dist/wagmi/Actions/nonce.js +7 -89
- package/dist/wagmi/Actions/nonce.js.map +1 -1
- package/dist/wagmi/Actions/policy.d.ts +69 -70
- package/dist/wagmi/Actions/policy.d.ts.map +1 -1
- package/dist/wagmi/Actions/policy.js +43 -43
- package/dist/wagmi/Actions/policy.js.map +1 -1
- package/dist/wagmi/Actions/reward.d.ts +51 -51
- package/dist/wagmi/Actions/reward.d.ts.map +1 -1
- package/dist/wagmi/Actions/reward.js +31 -31
- package/dist/wagmi/Actions/reward.js.map +1 -1
- package/dist/wagmi/Actions/token.d.ts +238 -238
- package/dist/wagmi/Actions/token.d.ts.map +1 -1
- package/dist/wagmi/Actions/token.js +136 -136
- package/dist/wagmi/Actions/token.js.map +1 -1
- package/dist/wagmi/Connector.d.ts +2 -1
- package/dist/wagmi/Connector.d.ts.map +1 -1
- package/dist/wagmi/Connector.js +83 -22
- package/dist/wagmi/Connector.js.map +1 -1
- package/dist/wagmi/Hooks/nonce.d.ts +1 -52
- package/dist/wagmi/Hooks/nonce.d.ts.map +1 -1
- package/dist/wagmi/Hooks/nonce.js +1 -70
- package/dist/wagmi/Hooks/nonce.js.map +1 -1
- package/dist/wagmi/Hooks/policy.d.ts +0 -1
- package/dist/wagmi/Hooks/policy.d.ts.map +1 -1
- package/dist/wagmi/Hooks/policy.js.map +1 -1
- package/dist/wagmi/KeyManager.d.ts +6 -3
- package/dist/wagmi/KeyManager.d.ts.map +1 -1
- package/dist/wagmi/KeyManager.js +9 -4
- package/dist/wagmi/KeyManager.js.map +1 -1
- package/package.json +3 -13
- package/src/server/Handler.test.ts +2 -2
- package/src/server/Handler.ts +16 -17
- package/src/wagmi/Actions/amm.ts +63 -63
- package/src/wagmi/Actions/dex.test.ts +1 -1
- package/src/wagmi/Actions/dex.ts +153 -153
- package/src/wagmi/Actions/faucet.ts +11 -11
- package/src/wagmi/Actions/fee.ts +20 -20
- package/src/wagmi/Actions/nonce.test.ts +1 -64
- package/src/wagmi/Actions/nonce.ts +10 -142
- package/src/wagmi/Actions/policy.ts +83 -85
- package/src/wagmi/Actions/reward.ts +64 -61
- package/src/wagmi/Actions/token.ts +287 -283
- package/src/wagmi/Connector.ts +105 -31
- package/src/wagmi/Hooks/dex.test.ts +1 -1
- package/src/wagmi/Hooks/fee.test.ts +0 -6
- package/src/wagmi/Hooks/nonce.test.ts +1 -66
- package/src/wagmi/Hooks/nonce.ts +1 -114
- package/src/wagmi/Hooks/policy.ts +0 -2
- package/src/wagmi/KeyManager.ts +18 -5
- package/dist/chains.d.ts +0 -73
- package/dist/chains.d.ts.map +0 -1
- package/dist/chains.js +0 -51
- package/dist/chains.js.map +0 -1
- package/dist/viem/Abis.d.ts +0 -2649
- package/dist/viem/Abis.d.ts.map +0 -1
- package/dist/viem/Abis.js +0 -1677
- package/dist/viem/Abis.js.map +0 -1
- package/dist/viem/Account.d.ts +0 -244
- package/dist/viem/Account.d.ts.map +0 -1
- package/dist/viem/Account.js +0 -382
- package/dist/viem/Account.js.map +0 -1
- package/dist/viem/Actions/account.d.ts +0 -40
- package/dist/viem/Actions/account.d.ts.map +0 -1
- package/dist/viem/Actions/account.js +0 -86
- package/dist/viem/Actions/account.js.map +0 -1
- package/dist/viem/Actions/amm.d.ts +0 -1991
- package/dist/viem/Actions/amm.d.ts.map +0 -1
- package/dist/viem/Actions/amm.js +0 -814
- package/dist/viem/Actions/amm.js.map +0 -1
- package/dist/viem/Actions/dex.d.ts +0 -3900
- package/dist/viem/Actions/dex.d.ts.map +0 -1
- package/dist/viem/Actions/dex.js +0 -1414
- package/dist/viem/Actions/dex.js.map +0 -1
- package/dist/viem/Actions/faucet.d.ts +0 -69
- package/dist/viem/Actions/faucet.d.ts.map +0 -1
- package/dist/viem/Actions/faucet.js +0 -73
- package/dist/viem/Actions/faucet.js.map +0 -1
- package/dist/viem/Actions/fee.d.ts +0 -360
- package/dist/viem/Actions/fee.d.ts.map +0 -1
- package/dist/viem/Actions/fee.js +0 -237
- package/dist/viem/Actions/fee.js.map +0 -1
- package/dist/viem/Actions/index.d.ts +0 -10
- package/dist/viem/Actions/index.d.ts.map +0 -1
- package/dist/viem/Actions/index.js +0 -10
- package/dist/viem/Actions/index.js.map +0 -1
- package/dist/viem/Actions/nonce.d.ts +0 -257
- package/dist/viem/Actions/nonce.d.ts.map +0 -1
- package/dist/viem/Actions/nonce.js +0 -228
- package/dist/viem/Actions/nonce.js.map +0 -1
- package/dist/viem/Actions/policy.d.ts +0 -1680
- package/dist/viem/Actions/policy.d.ts.map +0 -1
- package/dist/viem/Actions/policy.js +0 -875
- package/dist/viem/Actions/policy.js.map +0 -1
- package/dist/viem/Actions/reward.d.ts +0 -2422
- package/dist/viem/Actions/reward.d.ts.map +0 -1
- package/dist/viem/Actions/reward.js +0 -651
- package/dist/viem/Actions/reward.js.map +0 -1
- package/dist/viem/Actions/token.d.ts +0 -16007
- package/dist/viem/Actions/token.d.ts.map +0 -1
- package/dist/viem/Actions/token.js +0 -2936
- package/dist/viem/Actions/token.js.map +0 -1
- package/dist/viem/Addresses.d.ts +0 -9
- package/dist/viem/Addresses.d.ts.map +0 -1
- package/dist/viem/Addresses.js +0 -9
- package/dist/viem/Addresses.js.map +0 -1
- package/dist/viem/Chain.d.ts +0 -451
- package/dist/viem/Chain.d.ts.map +0 -1
- package/dist/viem/Chain.js +0 -96
- package/dist/viem/Chain.js.map +0 -1
- package/dist/viem/Decorator.d.ts +0 -2783
- package/dist/viem/Decorator.d.ts.map +0 -1
- package/dist/viem/Decorator.js +0 -137
- package/dist/viem/Decorator.js.map +0 -1
- package/dist/viem/Formatters.d.ts +0 -10
- package/dist/viem/Formatters.d.ts.map +0 -1
- package/dist/viem/Formatters.js +0 -104
- package/dist/viem/Formatters.js.map +0 -1
- package/dist/viem/P256.d.ts +0 -2
- package/dist/viem/P256.d.ts.map +0 -1
- package/dist/viem/P256.js +0 -2
- package/dist/viem/P256.js.map +0 -1
- package/dist/viem/Secp256k1.d.ts +0 -2
- package/dist/viem/Secp256k1.d.ts.map +0 -1
- package/dist/viem/Secp256k1.js +0 -2
- package/dist/viem/Secp256k1.js.map +0 -1
- package/dist/viem/Storage.d.ts +0 -24
- package/dist/viem/Storage.d.ts.map +0 -1
- package/dist/viem/Storage.js +0 -68
- package/dist/viem/Storage.js.map +0 -1
- package/dist/viem/TokenIds.d.ts +0 -2
- package/dist/viem/TokenIds.d.ts.map +0 -1
- package/dist/viem/TokenIds.js +0 -2
- package/dist/viem/TokenIds.js.map +0 -1
- package/dist/viem/Transaction.d.ts +0 -76
- package/dist/viem/Transaction.d.ts.map +0 -1
- package/dist/viem/Transaction.js +0 -176
- package/dist/viem/Transaction.js.map +0 -1
- package/dist/viem/Transport.d.ts +0 -33
- package/dist/viem/Transport.d.ts.map +0 -1
- package/dist/viem/Transport.js +0 -138
- package/dist/viem/Transport.js.map +0 -1
- package/dist/viem/WebAuthnP256.d.ts +0 -82
- package/dist/viem/WebAuthnP256.d.ts.map +0 -1
- package/dist/viem/WebAuthnP256.js +0 -97
- package/dist/viem/WebAuthnP256.js.map +0 -1
- package/dist/viem/WebCryptoP256.d.ts +0 -2
- package/dist/viem/WebCryptoP256.d.ts.map +0 -1
- package/dist/viem/WebCryptoP256.js +0 -2
- package/dist/viem/WebCryptoP256.js.map +0 -1
- package/dist/viem/index.d.ts +0 -26
- package/dist/viem/index.d.ts.map +0 -1
- package/dist/viem/index.js +0 -17
- package/dist/viem/index.js.map +0 -1
- package/dist/viem/internal/types.d.ts +0 -20
- package/dist/viem/internal/types.d.ts.map +0 -1
- package/dist/viem/internal/types.js +0 -2
- package/dist/viem/internal/types.js.map +0 -1
- package/dist/viem/internal/utils.d.ts +0 -14
- package/dist/viem/internal/utils.d.ts.map +0 -1
- package/dist/viem/internal/utils.js +0 -33
- package/dist/viem/internal/utils.js.map +0 -1
- package/src/chains.ts +0 -54
- package/src/viem/Abis.ts +0 -1688
- package/src/viem/Account.test.ts +0 -444
- package/src/viem/Account.ts +0 -601
- package/src/viem/Actions/account.test.ts +0 -414
- package/src/viem/Actions/account.ts +0 -106
- package/src/viem/Actions/amm.test.ts +0 -381
- package/src/viem/Actions/amm.ts +0 -1227
- package/src/viem/Actions/dex.test.ts +0 -1549
- package/src/viem/Actions/dex.ts +0 -2150
- package/src/viem/Actions/faucet.ts +0 -121
- package/src/viem/Actions/fee.test.ts +0 -259
- package/src/viem/Actions/fee.ts +0 -372
- package/src/viem/Actions/index.ts +0 -9
- package/src/viem/Actions/nonce.test.ts +0 -206
- package/src/viem/Actions/nonce.ts +0 -347
- package/src/viem/Actions/policy.test.ts +0 -534
- package/src/viem/Actions/policy.ts +0 -1335
- package/src/viem/Actions/reward.test.ts +0 -434
- package/src/viem/Actions/reward.ts +0 -944
- package/src/viem/Actions/token.test.ts +0 -3029
- package/src/viem/Actions/token.ts +0 -4458
- package/src/viem/Addresses.ts +0 -9
- package/src/viem/Chain.bench-d.ts +0 -12
- package/src/viem/Chain.test.ts +0 -168
- package/src/viem/Chain.ts +0 -157
- package/src/viem/Decorator.bench-d.ts +0 -11
- package/src/viem/Decorator.test.ts +0 -39
- package/src/viem/Decorator.ts +0 -3179
- package/src/viem/Formatters.ts +0 -164
- package/src/viem/P256.ts +0 -1
- package/src/viem/Secp256k1.ts +0 -1
- package/src/viem/Storage.ts +0 -110
- package/src/viem/TokenIds.ts +0 -1
- package/src/viem/Transaction.ts +0 -382
- package/src/viem/Transport.ts +0 -191
- package/src/viem/WebAuthnP256.ts +0 -146
- package/src/viem/WebCryptoP256.ts +0 -1
- package/src/viem/e2e.test.ts +0 -1602
- package/src/viem/index.ts +0 -30
- package/src/viem/internal/types.ts +0 -69
- package/src/viem/internal/utils.ts +0 -58
- package/src/wagmi/internal/types.ts +0 -16
|
@@ -1,228 +0,0 @@
|
|
|
1
|
-
import { readContract, watchContractEvent } from 'viem/actions';
|
|
2
|
-
import * as Abis from '../Abis.js';
|
|
3
|
-
import * as Addresses from '../Addresses.js';
|
|
4
|
-
import { defineCall } from '../internal/utils.js';
|
|
5
|
-
/**
|
|
6
|
-
* Gets the nonce for an account and nonce key.
|
|
7
|
-
*
|
|
8
|
-
* @example
|
|
9
|
-
* ```ts
|
|
10
|
-
* import { createClient, http } from 'viem'
|
|
11
|
-
* import { tempo } from 'tempo.ts/chains'
|
|
12
|
-
* import { Actions } from 'tempo.ts/viem'
|
|
13
|
-
*
|
|
14
|
-
* const client = createClient({
|
|
15
|
-
* chain: tempo({ feeToken: '0x20c0000000000000000000000000000000000001' }),
|
|
16
|
-
* transport: http(),
|
|
17
|
-
* })
|
|
18
|
-
*
|
|
19
|
-
* const nonce = await Actions.nonce.getNonce(client, {
|
|
20
|
-
* account: '0x...',
|
|
21
|
-
* nonceKey: 1n,
|
|
22
|
-
* })
|
|
23
|
-
* ```
|
|
24
|
-
*
|
|
25
|
-
* @param client - Client.
|
|
26
|
-
* @param parameters - Parameters.
|
|
27
|
-
* @returns The nonce value.
|
|
28
|
-
*/
|
|
29
|
-
export async function getNonce(client, parameters) {
|
|
30
|
-
const { account, nonceKey, ...rest } = parameters;
|
|
31
|
-
return readContract(client, {
|
|
32
|
-
...rest,
|
|
33
|
-
...getNonce.call({ account, nonceKey }),
|
|
34
|
-
});
|
|
35
|
-
}
|
|
36
|
-
(function (getNonce) {
|
|
37
|
-
/**
|
|
38
|
-
* Defines a call to the `getNonce` function.
|
|
39
|
-
*
|
|
40
|
-
* Can be passed as a parameter to:
|
|
41
|
-
* - [`estimateContractGas`](https://viem.sh/docs/contract/estimateContractGas): estimate the gas cost of the call
|
|
42
|
-
* - [`simulateContract`](https://viem.sh/docs/contract/simulateContract): simulate the call
|
|
43
|
-
* - [`multicall`](https://viem.sh/docs/contract/multicall): execute multiple calls in parallel
|
|
44
|
-
*
|
|
45
|
-
* @example
|
|
46
|
-
* ```ts
|
|
47
|
-
* import { createClient, http } from 'viem'
|
|
48
|
-
* import { tempo } from 'tempo.ts/chains'
|
|
49
|
-
* import { Actions } from 'tempo.ts/viem'
|
|
50
|
-
*
|
|
51
|
-
* const client = createClient({
|
|
52
|
-
* chain: tempo({ feeToken: '0x20c0000000000000000000000000000000000001' }),
|
|
53
|
-
* transport: http(),
|
|
54
|
-
* })
|
|
55
|
-
*
|
|
56
|
-
* const result = await client.multicall({
|
|
57
|
-
* contracts: [
|
|
58
|
-
* Actions.nonce.getNonce.call({ account: '0x...', nonceKey: 1n }),
|
|
59
|
-
* Actions.nonce.getNonce.call({ account: '0x...', nonceKey: 2n }),
|
|
60
|
-
* ],
|
|
61
|
-
* })
|
|
62
|
-
* ```
|
|
63
|
-
*
|
|
64
|
-
* @param args - Arguments.
|
|
65
|
-
* @returns The call.
|
|
66
|
-
*/
|
|
67
|
-
function call(args) {
|
|
68
|
-
const { account, nonceKey } = args;
|
|
69
|
-
return defineCall({
|
|
70
|
-
address: Addresses.nonceManager,
|
|
71
|
-
abi: Abis.nonce,
|
|
72
|
-
args: [account, nonceKey],
|
|
73
|
-
functionName: 'getNonce',
|
|
74
|
-
});
|
|
75
|
-
}
|
|
76
|
-
getNonce.call = call;
|
|
77
|
-
})(getNonce || (getNonce = {}));
|
|
78
|
-
/**
|
|
79
|
-
* Gets the number of active nonce keys for an account.
|
|
80
|
-
*
|
|
81
|
-
* @example
|
|
82
|
-
* ```ts
|
|
83
|
-
* import { createClient, http } from 'viem'
|
|
84
|
-
* import { tempo } from 'tempo.ts/chains'
|
|
85
|
-
* import { Actions } from 'tempo.ts/viem'
|
|
86
|
-
*
|
|
87
|
-
* const client = createClient({
|
|
88
|
-
* chain: tempo({ feeToken: '0x20c0000000000000000000000000000000000001' }),
|
|
89
|
-
* transport: http(),
|
|
90
|
-
* })
|
|
91
|
-
*
|
|
92
|
-
* const count = await Actions.nonce.getNonceKeyCount(client, {
|
|
93
|
-
* account: '0x...',
|
|
94
|
-
* })
|
|
95
|
-
* ```
|
|
96
|
-
*
|
|
97
|
-
* @param client - Client.
|
|
98
|
-
* @param parameters - Parameters.
|
|
99
|
-
* @returns The number of active nonce keys.
|
|
100
|
-
*/
|
|
101
|
-
export async function getNonceKeyCount(client, parameters) {
|
|
102
|
-
const { account, ...rest } = parameters;
|
|
103
|
-
return readContract(client, {
|
|
104
|
-
...rest,
|
|
105
|
-
...getNonceKeyCount.call({ account }),
|
|
106
|
-
});
|
|
107
|
-
}
|
|
108
|
-
(function (getNonceKeyCount) {
|
|
109
|
-
/**
|
|
110
|
-
* Defines a call to the `getNonceKeyCount` function.
|
|
111
|
-
*
|
|
112
|
-
* Can be passed as a parameter to:
|
|
113
|
-
* - [`estimateContractGas`](https://viem.sh/docs/contract/estimateContractGas): estimate the gas cost of the call
|
|
114
|
-
* - [`simulateContract`](https://viem.sh/docs/contract/simulateContract): simulate the call
|
|
115
|
-
* - [`multicall`](https://viem.sh/docs/contract/multicall): execute multiple calls in parallel
|
|
116
|
-
*
|
|
117
|
-
* @example
|
|
118
|
-
* ```ts
|
|
119
|
-
* import { createClient, http } from 'viem'
|
|
120
|
-
* import { tempo } from 'tempo.ts/chains'
|
|
121
|
-
* import { Actions } from 'tempo.ts/viem'
|
|
122
|
-
*
|
|
123
|
-
* const client = createClient({
|
|
124
|
-
* chain: tempo({ feeToken: '0x20c0000000000000000000000000000000000001' }),
|
|
125
|
-
* transport: http(),
|
|
126
|
-
* })
|
|
127
|
-
*
|
|
128
|
-
* const result = await client.multicall({
|
|
129
|
-
* contracts: [
|
|
130
|
-
* Actions.nonce.getNonceKeyCount.call({ account: '0x...' }),
|
|
131
|
-
* Actions.nonce.getNonceKeyCount.call({ account: '0x...' }),
|
|
132
|
-
* ],
|
|
133
|
-
* })
|
|
134
|
-
* ```
|
|
135
|
-
*
|
|
136
|
-
* @param args - Arguments.
|
|
137
|
-
* @returns The call.
|
|
138
|
-
*/
|
|
139
|
-
function call(args) {
|
|
140
|
-
const { account } = args;
|
|
141
|
-
return defineCall({
|
|
142
|
-
address: Addresses.nonceManager,
|
|
143
|
-
abi: Abis.nonce,
|
|
144
|
-
args: [account],
|
|
145
|
-
functionName: 'getActiveNonceKeyCount',
|
|
146
|
-
});
|
|
147
|
-
}
|
|
148
|
-
getNonceKeyCount.call = call;
|
|
149
|
-
})(getNonceKeyCount || (getNonceKeyCount = {}));
|
|
150
|
-
/**
|
|
151
|
-
* Watches for nonce incremented events.
|
|
152
|
-
*
|
|
153
|
-
* @example
|
|
154
|
-
* ```ts
|
|
155
|
-
* import { createClient, http } from 'viem'
|
|
156
|
-
* import { tempo } from 'tempo.ts/chains'
|
|
157
|
-
* import { Actions } from 'tempo.ts/viem'
|
|
158
|
-
*
|
|
159
|
-
* const client = createClient({
|
|
160
|
-
* chain: tempo({ feeToken: '0x20c0000000000000000000000000000000000001' }),
|
|
161
|
-
* transport: http(),
|
|
162
|
-
* })
|
|
163
|
-
*
|
|
164
|
-
* const unwatch = Actions.nonce.watchNonceIncremented(client, {
|
|
165
|
-
* onNonceIncremented: (args, log) => {
|
|
166
|
-
* console.log('Nonce incremented:', args)
|
|
167
|
-
* },
|
|
168
|
-
* })
|
|
169
|
-
* ```
|
|
170
|
-
*
|
|
171
|
-
* @param client - Client.
|
|
172
|
-
* @param parameters - Parameters.
|
|
173
|
-
* @returns A function to unsubscribe from the event.
|
|
174
|
-
*/
|
|
175
|
-
export function watchNonceIncremented(client, parameters) {
|
|
176
|
-
const { onNonceIncremented, ...rest } = parameters;
|
|
177
|
-
return watchContractEvent(client, {
|
|
178
|
-
...rest,
|
|
179
|
-
address: Addresses.nonceManager,
|
|
180
|
-
abi: Abis.nonce,
|
|
181
|
-
eventName: 'NonceIncremented',
|
|
182
|
-
onLogs: (logs) => {
|
|
183
|
-
for (const log of logs)
|
|
184
|
-
onNonceIncremented(log.args, log);
|
|
185
|
-
},
|
|
186
|
-
strict: true,
|
|
187
|
-
});
|
|
188
|
-
}
|
|
189
|
-
/**
|
|
190
|
-
* Watches for active key count changed events.
|
|
191
|
-
*
|
|
192
|
-
* @example
|
|
193
|
-
* ```ts
|
|
194
|
-
* import { createClient, http } from 'viem'
|
|
195
|
-
* import { tempo } from 'tempo.ts/chains'
|
|
196
|
-
* import { Actions } from 'tempo.ts/viem'
|
|
197
|
-
*
|
|
198
|
-
* const client = createClient({
|
|
199
|
-
* chain: tempo({ feeToken: '0x20c0000000000000000000000000000000000001' }),
|
|
200
|
-
* transport: http(),
|
|
201
|
-
* })
|
|
202
|
-
*
|
|
203
|
-
* const unwatch = Actions.nonce.watchActiveKeyCountChanged(client, {
|
|
204
|
-
* onActiveKeyCountChanged: (args, log) => {
|
|
205
|
-
* console.log('Active key count changed:', args)
|
|
206
|
-
* },
|
|
207
|
-
* })
|
|
208
|
-
* ```
|
|
209
|
-
*
|
|
210
|
-
* @param client - Client.
|
|
211
|
-
* @param parameters - Parameters.
|
|
212
|
-
* @returns A function to unsubscribe from the event.
|
|
213
|
-
*/
|
|
214
|
-
export function watchActiveKeyCountChanged(client, parameters) {
|
|
215
|
-
const { onActiveKeyCountChanged, ...rest } = parameters;
|
|
216
|
-
return watchContractEvent(client, {
|
|
217
|
-
...rest,
|
|
218
|
-
address: Addresses.nonceManager,
|
|
219
|
-
abi: Abis.nonce,
|
|
220
|
-
eventName: 'ActiveKeyCountChanged',
|
|
221
|
-
onLogs: (logs) => {
|
|
222
|
-
for (const log of logs)
|
|
223
|
-
onActiveKeyCountChanged(log.args, log);
|
|
224
|
-
},
|
|
225
|
-
strict: true,
|
|
226
|
-
});
|
|
227
|
-
}
|
|
228
|
-
//# sourceMappingURL=nonce.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"nonce.js","sourceRoot":"","sources":["../../../src/viem/Actions/nonce.ts"],"names":[],"mappings":"AAYA,OAAO,EAAE,YAAY,EAAE,kBAAkB,EAAE,MAAM,cAAc,CAAA;AAE/D,OAAO,KAAK,IAAI,MAAM,YAAY,CAAA;AAClC,OAAO,KAAK,SAAS,MAAM,iBAAiB,CAAA;AAE5C,OAAO,EAAE,UAAU,EAAE,MAAM,sBAAsB,CAAA;AAEjD;;;;;;;;;;;;;;;;;;;;;;;GAuBG;AACH,MAAM,CAAC,KAAK,UAAU,QAAQ,CAI5B,MAAyC,EACzC,UAA+B;IAE/B,MAAM,EAAE,OAAO,EAAE,QAAQ,EAAE,GAAG,IAAI,EAAE,GAAG,UAAU,CAAA;IACjD,OAAO,YAAY,CAAC,MAAM,EAAE;QAC1B,GAAG,IAAI;QACP,GAAG,QAAQ,CAAC,IAAI,CAAC,EAAE,OAAO,EAAE,QAAQ,EAAE,CAAC;KACxC,CAAC,CAAA;AACJ,CAAC;AAED,WAAiB,QAAQ;IAgBvB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;OA6BG;IACH,SAAgB,IAAI,CAAC,IAAU;QAC7B,MAAM,EAAE,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