timelock-sdk 0.0.162 → 0.0.164

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.
Files changed (42) hide show
  1. package/dist/abis.cjs +1059 -308
  2. package/dist/abis.cjs.map +1 -1
  3. package/dist/abis.d.cts +2967 -766
  4. package/dist/abis.d.ts +2967 -766
  5. package/dist/abis.js +1051 -303
  6. package/dist/abis.js.map +1 -1
  7. package/dist/{client-BVPR3obW.d.cts → client-Di1eoh5l.d.cts} +870 -1797
  8. package/dist/{client-BFhMekeP.d.ts → client-Dp-YTEVp.d.ts} +35 -962
  9. package/dist/client.cjs +113 -949
  10. package/dist/client.cjs.map +1 -1
  11. package/dist/client.d.cts +3 -3
  12. package/dist/client.d.ts +3 -3
  13. package/dist/client.js +79 -915
  14. package/dist/client.js.map +1 -1
  15. package/dist/factory-DitVXzjQ.cjs +1715 -0
  16. package/dist/factory-DitVXzjQ.cjs.map +1 -0
  17. package/dist/factory-y-iVl_er.js +1697 -0
  18. package/dist/factory-y-iVl_er.js.map +1 -0
  19. package/dist/{optionUtils-R9Y-jxoz.cjs → optionUtils-Cuuw6jXD.cjs} +6 -1048
  20. package/dist/optionUtils-Cuuw6jXD.cjs.map +1 -0
  21. package/dist/optionUtils-OyY8qOu0.js +381 -0
  22. package/dist/optionUtils-OyY8qOu0.js.map +1 -0
  23. package/dist/{uniswapMathLens-oe-gukfo.d.ts → optionsMarket-2HZ-p_dl.d.ts} +2 -625
  24. package/dist/{uniswapMathLens-B6gp2UGI.d.cts → optionsMarket-c4hgszY_.d.cts} +2 -625
  25. package/dist/package.cjs +2 -2
  26. package/dist/package.d.cts +3 -3
  27. package/dist/package.d.ts +3 -3
  28. package/dist/package.js +2 -2
  29. package/dist/{optionsMarket-CWigPja1.js → statelessStateView-CBkcP7CK.js} +1599 -1322
  30. package/dist/statelessStateView-CBkcP7CK.js.map +1 -0
  31. package/dist/{optionsMarket-CtlBxuj0.cjs → statelessStateView-XdTJQxsY.cjs} +1600 -1323
  32. package/dist/statelessStateView-XdTJQxsY.cjs.map +1 -0
  33. package/package.json +1 -1
  34. package/dist/optionUtils-R9Y-jxoz.cjs.map +0 -1
  35. package/dist/optionUtils-fCYueZl2.js +0 -1417
  36. package/dist/optionUtils-fCYueZl2.js.map +0 -1
  37. package/dist/optionsMarket-CWigPja1.js.map +0 -1
  38. package/dist/optionsMarket-CtlBxuj0.cjs.map +0 -1
  39. package/dist/singleOwnerVault-BJyEs_D_.js +0 -847
  40. package/dist/singleOwnerVault-BJyEs_D_.js.map +0 -1
  41. package/dist/singleOwnerVault-GCpQV7pN.cjs +0 -853
  42. package/dist/singleOwnerVault-GCpQV7pN.cjs.map +0 -1
package/dist/abis.cjs CHANGED
@@ -1,163 +1,181 @@
1
- const require_optionsMarket = require('./optionsMarket-CtlBxuj0.cjs');
2
- const require_singleOwnerVault = require('./singleOwnerVault-GCpQV7pN.cjs');
1
+ const require_statelessStateView = require('./statelessStateView-XdTJQxsY.cjs');
2
+ const require_factory = require('./factory-DitVXzjQ.cjs');
3
3
 
4
- //#region src/abis/uniswapV3Pool.ts
5
- const uniswapV3PoolAbi = [
4
+ //#region src/abis/poolManager.ts
5
+ const poolManagerAbi = [
6
6
  {
7
7
  type: "function",
8
- name: "burn",
8
+ name: "allowance",
9
9
  inputs: [
10
10
  {
11
- name: "tickLower",
12
- type: "int24",
13
- internalType: "int24"
11
+ name: "owner",
12
+ type: "address",
13
+ internalType: "address"
14
14
  },
15
15
  {
16
- name: "tickUpper",
17
- type: "int24",
18
- internalType: "int24"
16
+ name: "spender",
17
+ type: "address",
18
+ internalType: "address"
19
19
  },
20
20
  {
21
- name: "amount",
22
- type: "uint128",
23
- internalType: "uint128"
21
+ name: "id",
22
+ type: "uint256",
23
+ internalType: "uint256"
24
24
  }
25
25
  ],
26
26
  outputs: [{
27
- name: "amount0",
28
- type: "uint256",
29
- internalType: "uint256"
30
- }, {
31
- name: "amount1",
27
+ name: "amount",
32
28
  type: "uint256",
33
29
  internalType: "uint256"
34
30
  }],
35
- stateMutability: "nonpayable"
31
+ stateMutability: "view"
36
32
  },
37
33
  {
38
34
  type: "function",
39
- name: "collect",
35
+ name: "approve",
40
36
  inputs: [
41
37
  {
42
- name: "recipient",
38
+ name: "spender",
43
39
  type: "address",
44
40
  internalType: "address"
45
41
  },
46
42
  {
47
- name: "tickLower",
48
- type: "int24",
49
- internalType: "int24"
50
- },
51
- {
52
- name: "tickUpper",
53
- type: "int24",
54
- internalType: "int24"
55
- },
56
- {
57
- name: "amount0Requested",
58
- type: "uint128",
59
- internalType: "uint128"
43
+ name: "id",
44
+ type: "uint256",
45
+ internalType: "uint256"
60
46
  },
61
47
  {
62
- name: "amount1Requested",
63
- type: "uint128",
64
- internalType: "uint128"
48
+ name: "amount",
49
+ type: "uint256",
50
+ internalType: "uint256"
65
51
  }
66
52
  ],
67
53
  outputs: [{
68
- name: "amount0",
69
- type: "uint128",
70
- internalType: "uint128"
71
- }, {
72
- name: "amount1",
73
- type: "uint128",
74
- internalType: "uint128"
54
+ name: "",
55
+ type: "bool",
56
+ internalType: "bool"
75
57
  }],
76
58
  stateMutability: "nonpayable"
77
59
  },
78
60
  {
79
61
  type: "function",
80
- name: "collectProtocol",
62
+ name: "balanceOf",
63
+ inputs: [{
64
+ name: "owner",
65
+ type: "address",
66
+ internalType: "address"
67
+ }, {
68
+ name: "id",
69
+ type: "uint256",
70
+ internalType: "uint256"
71
+ }],
72
+ outputs: [{
73
+ name: "amount",
74
+ type: "uint256",
75
+ internalType: "uint256"
76
+ }],
77
+ stateMutability: "view"
78
+ },
79
+ {
80
+ type: "function",
81
+ name: "burn",
81
82
  inputs: [
82
83
  {
83
- name: "recipient",
84
+ name: "from",
84
85
  type: "address",
85
86
  internalType: "address"
86
87
  },
87
88
  {
88
- name: "amount0Requested",
89
- type: "uint128",
90
- internalType: "uint128"
89
+ name: "id",
90
+ type: "uint256",
91
+ internalType: "uint256"
91
92
  },
92
93
  {
93
- name: "amount1Requested",
94
- type: "uint128",
95
- internalType: "uint128"
94
+ name: "amount",
95
+ type: "uint256",
96
+ internalType: "uint256"
96
97
  }
97
98
  ],
98
- outputs: [{
99
- name: "amount0",
100
- type: "uint128",
101
- internalType: "uint128"
102
- }, {
103
- name: "amount1",
104
- type: "uint128",
105
- internalType: "uint128"
106
- }],
99
+ outputs: [],
107
100
  stateMutability: "nonpayable"
108
101
  },
109
102
  {
110
103
  type: "function",
111
- name: "factory",
112
- inputs: [],
113
- outputs: [{
114
- name: "",
104
+ name: "clear",
105
+ inputs: [{
106
+ name: "currency",
115
107
  type: "address",
116
- internalType: "address"
117
- }],
118
- stateMutability: "view"
119
- },
120
- {
121
- type: "function",
122
- name: "fee",
123
- inputs: [],
124
- outputs: [{
125
- name: "",
126
- type: "uint24",
127
- internalType: "uint24"
128
- }],
129
- stateMutability: "view"
130
- },
131
- {
132
- type: "function",
133
- name: "feeGrowthGlobal0X128",
134
- inputs: [],
135
- outputs: [{
136
- name: "",
108
+ internalType: "Currency"
109
+ }, {
110
+ name: "amount",
137
111
  type: "uint256",
138
112
  internalType: "uint256"
139
113
  }],
140
- stateMutability: "view"
114
+ outputs: [],
115
+ stateMutability: "nonpayable"
141
116
  },
142
117
  {
143
118
  type: "function",
144
- name: "feeGrowthGlobal1X128",
145
- inputs: [],
119
+ name: "collectProtocolFees",
120
+ inputs: [
121
+ {
122
+ name: "recipient",
123
+ type: "address",
124
+ internalType: "address"
125
+ },
126
+ {
127
+ name: "currency",
128
+ type: "address",
129
+ internalType: "Currency"
130
+ },
131
+ {
132
+ name: "amount",
133
+ type: "uint256",
134
+ internalType: "uint256"
135
+ }
136
+ ],
146
137
  outputs: [{
147
- name: "",
138
+ name: "amountCollected",
148
139
  type: "uint256",
149
140
  internalType: "uint256"
150
141
  }],
151
- stateMutability: "view"
142
+ stateMutability: "nonpayable"
152
143
  },
153
144
  {
154
145
  type: "function",
155
- name: "flash",
146
+ name: "donate",
156
147
  inputs: [
157
148
  {
158
- name: "recipient",
159
- type: "address",
160
- internalType: "address"
149
+ name: "key",
150
+ type: "tuple",
151
+ internalType: "struct PoolKey",
152
+ components: [
153
+ {
154
+ name: "currency0",
155
+ type: "address",
156
+ internalType: "Currency"
157
+ },
158
+ {
159
+ name: "currency1",
160
+ type: "address",
161
+ internalType: "Currency"
162
+ },
163
+ {
164
+ name: "fee",
165
+ type: "uint24",
166
+ internalType: "uint24"
167
+ },
168
+ {
169
+ name: "tickSpacing",
170
+ type: "int24",
171
+ internalType: "int24"
172
+ },
173
+ {
174
+ name: "hooks",
175
+ type: "address",
176
+ internalType: "contract IHooks"
177
+ }
178
+ ]
161
179
  },
162
180
  {
163
181
  name: "amount0",
@@ -170,55 +188,159 @@ const uniswapV3PoolAbi = [
170
188
  internalType: "uint256"
171
189
  },
172
190
  {
173
- name: "data",
191
+ name: "hookData",
174
192
  type: "bytes",
175
193
  internalType: "bytes"
176
194
  }
177
195
  ],
178
- outputs: [],
196
+ outputs: [{
197
+ name: "",
198
+ type: "int256",
199
+ internalType: "BalanceDelta"
200
+ }],
179
201
  stateMutability: "nonpayable"
180
202
  },
181
203
  {
182
204
  type: "function",
183
- name: "increaseObservationCardinalityNext",
205
+ name: "extsload",
184
206
  inputs: [{
185
- name: "observationCardinalityNext",
186
- type: "uint16",
187
- internalType: "uint16"
207
+ name: "slot",
208
+ type: "bytes32",
209
+ internalType: "bytes32"
188
210
  }],
189
- outputs: [],
190
- stateMutability: "nonpayable"
211
+ outputs: [{
212
+ name: "value",
213
+ type: "bytes32",
214
+ internalType: "bytes32"
215
+ }],
216
+ stateMutability: "view"
191
217
  },
192
218
  {
193
219
  type: "function",
194
- name: "initialize",
220
+ name: "extsload",
195
221
  inputs: [{
196
- name: "sqrtPriceX96",
197
- type: "uint160",
198
- internalType: "uint160"
222
+ name: "startSlot",
223
+ type: "bytes32",
224
+ internalType: "bytes32"
225
+ }, {
226
+ name: "nSlots",
227
+ type: "uint256",
228
+ internalType: "uint256"
199
229
  }],
200
- outputs: [],
201
- stateMutability: "nonpayable"
230
+ outputs: [{
231
+ name: "values",
232
+ type: "bytes32[]",
233
+ internalType: "bytes32[]"
234
+ }],
235
+ stateMutability: "view"
202
236
  },
203
237
  {
204
238
  type: "function",
205
- name: "liquidity",
206
- inputs: [],
239
+ name: "extsload",
240
+ inputs: [{
241
+ name: "slots",
242
+ type: "bytes32[]",
243
+ internalType: "bytes32[]"
244
+ }],
207
245
  outputs: [{
208
- name: "",
209
- type: "uint128",
210
- internalType: "uint128"
246
+ name: "values",
247
+ type: "bytes32[]",
248
+ internalType: "bytes32[]"
211
249
  }],
212
250
  stateMutability: "view"
213
251
  },
214
252
  {
215
253
  type: "function",
216
- name: "maxLiquidityPerTick",
217
- inputs: [],
254
+ name: "exttload",
255
+ inputs: [{
256
+ name: "slots",
257
+ type: "bytes32[]",
258
+ internalType: "bytes32[]"
259
+ }],
218
260
  outputs: [{
219
- name: "",
220
- type: "uint128",
221
- internalType: "uint128"
261
+ name: "values",
262
+ type: "bytes32[]",
263
+ internalType: "bytes32[]"
264
+ }],
265
+ stateMutability: "view"
266
+ },
267
+ {
268
+ type: "function",
269
+ name: "exttload",
270
+ inputs: [{
271
+ name: "slot",
272
+ type: "bytes32",
273
+ internalType: "bytes32"
274
+ }],
275
+ outputs: [{
276
+ name: "value",
277
+ type: "bytes32",
278
+ internalType: "bytes32"
279
+ }],
280
+ stateMutability: "view"
281
+ },
282
+ {
283
+ type: "function",
284
+ name: "initialize",
285
+ inputs: [{
286
+ name: "key",
287
+ type: "tuple",
288
+ internalType: "struct PoolKey",
289
+ components: [
290
+ {
291
+ name: "currency0",
292
+ type: "address",
293
+ internalType: "Currency"
294
+ },
295
+ {
296
+ name: "currency1",
297
+ type: "address",
298
+ internalType: "Currency"
299
+ },
300
+ {
301
+ name: "fee",
302
+ type: "uint24",
303
+ internalType: "uint24"
304
+ },
305
+ {
306
+ name: "tickSpacing",
307
+ type: "int24",
308
+ internalType: "int24"
309
+ },
310
+ {
311
+ name: "hooks",
312
+ type: "address",
313
+ internalType: "contract IHooks"
314
+ }
315
+ ]
316
+ }, {
317
+ name: "sqrtPriceX96",
318
+ type: "uint160",
319
+ internalType: "uint160"
320
+ }],
321
+ outputs: [{
322
+ name: "tick",
323
+ type: "int24",
324
+ internalType: "int24"
325
+ }],
326
+ stateMutability: "nonpayable"
327
+ },
328
+ {
329
+ type: "function",
330
+ name: "isOperator",
331
+ inputs: [{
332
+ name: "owner",
333
+ type: "address",
334
+ internalType: "address"
335
+ }, {
336
+ name: "spender",
337
+ type: "address",
338
+ internalType: "address"
339
+ }],
340
+ outputs: [{
341
+ name: "approved",
342
+ type: "bool",
343
+ internalType: "bool"
222
344
  }],
223
345
  stateMutability: "view"
224
346
  },
@@ -227,283 +349,883 @@ const uniswapV3PoolAbi = [
227
349
  name: "mint",
228
350
  inputs: [
229
351
  {
230
- name: "recipient",
352
+ name: "to",
231
353
  type: "address",
232
354
  internalType: "address"
233
355
  },
234
356
  {
235
- name: "tickLower",
236
- type: "int24",
237
- internalType: "int24"
357
+ name: "id",
358
+ type: "uint256",
359
+ internalType: "uint256"
238
360
  },
239
361
  {
240
- name: "tickUpper",
241
- type: "int24",
242
- internalType: "int24"
362
+ name: "amount",
363
+ type: "uint256",
364
+ internalType: "uint256"
365
+ }
366
+ ],
367
+ outputs: [],
368
+ stateMutability: "nonpayable"
369
+ },
370
+ {
371
+ type: "function",
372
+ name: "modifyLiquidity",
373
+ inputs: [
374
+ {
375
+ name: "key",
376
+ type: "tuple",
377
+ internalType: "struct PoolKey",
378
+ components: [
379
+ {
380
+ name: "currency0",
381
+ type: "address",
382
+ internalType: "Currency"
383
+ },
384
+ {
385
+ name: "currency1",
386
+ type: "address",
387
+ internalType: "Currency"
388
+ },
389
+ {
390
+ name: "fee",
391
+ type: "uint24",
392
+ internalType: "uint24"
393
+ },
394
+ {
395
+ name: "tickSpacing",
396
+ type: "int24",
397
+ internalType: "int24"
398
+ },
399
+ {
400
+ name: "hooks",
401
+ type: "address",
402
+ internalType: "contract IHooks"
403
+ }
404
+ ]
243
405
  },
244
406
  {
245
- name: "amount",
246
- type: "uint128",
247
- internalType: "uint128"
407
+ name: "params",
408
+ type: "tuple",
409
+ internalType: "struct IPoolManager.ModifyLiquidityParams",
410
+ components: [
411
+ {
412
+ name: "tickLower",
413
+ type: "int24",
414
+ internalType: "int24"
415
+ },
416
+ {
417
+ name: "tickUpper",
418
+ type: "int24",
419
+ internalType: "int24"
420
+ },
421
+ {
422
+ name: "liquidityDelta",
423
+ type: "int256",
424
+ internalType: "int256"
425
+ },
426
+ {
427
+ name: "salt",
428
+ type: "bytes32",
429
+ internalType: "bytes32"
430
+ }
431
+ ]
248
432
  },
249
433
  {
250
- name: "data",
434
+ name: "hookData",
251
435
  type: "bytes",
252
436
  internalType: "bytes"
253
437
  }
254
438
  ],
255
439
  outputs: [{
256
- name: "amount0",
257
- type: "uint256",
258
- internalType: "uint256"
440
+ name: "callerDelta",
441
+ type: "int256",
442
+ internalType: "BalanceDelta"
259
443
  }, {
260
- name: "amount1",
261
- type: "uint256",
262
- internalType: "uint256"
444
+ name: "feesAccrued",
445
+ type: "int256",
446
+ internalType: "BalanceDelta"
263
447
  }],
264
448
  stateMutability: "nonpayable"
265
449
  },
266
450
  {
267
451
  type: "function",
268
- name: "observations",
452
+ name: "protocolFeeController",
453
+ inputs: [],
454
+ outputs: [{
455
+ name: "",
456
+ type: "address",
457
+ internalType: "address"
458
+ }],
459
+ stateMutability: "view"
460
+ },
461
+ {
462
+ type: "function",
463
+ name: "protocolFeesAccrued",
269
464
  inputs: [{
270
- name: "index",
465
+ name: "currency",
466
+ type: "address",
467
+ internalType: "Currency"
468
+ }],
469
+ outputs: [{
470
+ name: "amount",
271
471
  type: "uint256",
272
472
  internalType: "uint256"
273
473
  }],
274
- outputs: [
275
- {
276
- name: "blockTimestamp",
277
- type: "uint32",
278
- internalType: "uint32"
279
- },
474
+ stateMutability: "view"
475
+ },
476
+ {
477
+ type: "function",
478
+ name: "setOperator",
479
+ inputs: [{
480
+ name: "operator",
481
+ type: "address",
482
+ internalType: "address"
483
+ }, {
484
+ name: "approved",
485
+ type: "bool",
486
+ internalType: "bool"
487
+ }],
488
+ outputs: [{
489
+ name: "",
490
+ type: "bool",
491
+ internalType: "bool"
492
+ }],
493
+ stateMutability: "nonpayable"
494
+ },
495
+ {
496
+ type: "function",
497
+ name: "setProtocolFee",
498
+ inputs: [{
499
+ name: "key",
500
+ type: "tuple",
501
+ internalType: "struct PoolKey",
502
+ components: [
503
+ {
504
+ name: "currency0",
505
+ type: "address",
506
+ internalType: "Currency"
507
+ },
508
+ {
509
+ name: "currency1",
510
+ type: "address",
511
+ internalType: "Currency"
512
+ },
513
+ {
514
+ name: "fee",
515
+ type: "uint24",
516
+ internalType: "uint24"
517
+ },
518
+ {
519
+ name: "tickSpacing",
520
+ type: "int24",
521
+ internalType: "int24"
522
+ },
523
+ {
524
+ name: "hooks",
525
+ type: "address",
526
+ internalType: "contract IHooks"
527
+ }
528
+ ]
529
+ }, {
530
+ name: "newProtocolFee",
531
+ type: "uint24",
532
+ internalType: "uint24"
533
+ }],
534
+ outputs: [],
535
+ stateMutability: "nonpayable"
536
+ },
537
+ {
538
+ type: "function",
539
+ name: "setProtocolFeeController",
540
+ inputs: [{
541
+ name: "controller",
542
+ type: "address",
543
+ internalType: "address"
544
+ }],
545
+ outputs: [],
546
+ stateMutability: "nonpayable"
547
+ },
548
+ {
549
+ type: "function",
550
+ name: "settle",
551
+ inputs: [],
552
+ outputs: [{
553
+ name: "paid",
554
+ type: "uint256",
555
+ internalType: "uint256"
556
+ }],
557
+ stateMutability: "payable"
558
+ },
559
+ {
560
+ type: "function",
561
+ name: "settleFor",
562
+ inputs: [{
563
+ name: "recipient",
564
+ type: "address",
565
+ internalType: "address"
566
+ }],
567
+ outputs: [{
568
+ name: "paid",
569
+ type: "uint256",
570
+ internalType: "uint256"
571
+ }],
572
+ stateMutability: "payable"
573
+ },
574
+ {
575
+ type: "function",
576
+ name: "swap",
577
+ inputs: [
280
578
  {
281
- name: "tickCumulative",
282
- type: "int56",
283
- internalType: "int56"
579
+ name: "key",
580
+ type: "tuple",
581
+ internalType: "struct PoolKey",
582
+ components: [
583
+ {
584
+ name: "currency0",
585
+ type: "address",
586
+ internalType: "Currency"
587
+ },
588
+ {
589
+ name: "currency1",
590
+ type: "address",
591
+ internalType: "Currency"
592
+ },
593
+ {
594
+ name: "fee",
595
+ type: "uint24",
596
+ internalType: "uint24"
597
+ },
598
+ {
599
+ name: "tickSpacing",
600
+ type: "int24",
601
+ internalType: "int24"
602
+ },
603
+ {
604
+ name: "hooks",
605
+ type: "address",
606
+ internalType: "contract IHooks"
607
+ }
608
+ ]
284
609
  },
285
610
  {
286
- name: "secondsPerLiquidityCumulativeX128",
287
- type: "uint160",
288
- internalType: "uint160"
611
+ name: "params",
612
+ type: "tuple",
613
+ internalType: "struct IPoolManager.SwapParams",
614
+ components: [
615
+ {
616
+ name: "zeroForOne",
617
+ type: "bool",
618
+ internalType: "bool"
619
+ },
620
+ {
621
+ name: "amountSpecified",
622
+ type: "int256",
623
+ internalType: "int256"
624
+ },
625
+ {
626
+ name: "sqrtPriceLimitX96",
627
+ type: "uint160",
628
+ internalType: "uint160"
629
+ }
630
+ ]
289
631
  },
290
632
  {
291
- name: "initialized",
292
- type: "bool",
293
- internalType: "bool"
633
+ name: "hookData",
634
+ type: "bytes",
635
+ internalType: "bytes"
294
636
  }
295
637
  ],
296
- stateMutability: "view"
638
+ outputs: [{
639
+ name: "swapDelta",
640
+ type: "int256",
641
+ internalType: "BalanceDelta"
642
+ }],
643
+ stateMutability: "nonpayable"
297
644
  },
298
645
  {
299
646
  type: "function",
300
- name: "observe",
647
+ name: "sync",
301
648
  inputs: [{
302
- name: "secondsAgos",
303
- type: "uint32[]",
304
- internalType: "uint32[]"
305
- }],
306
- outputs: [{
307
- name: "tickCumulatives",
308
- type: "int56[]",
309
- internalType: "int56[]"
310
- }, {
311
- name: "secondsPerLiquidityCumulativeX128s",
312
- type: "uint160[]",
313
- internalType: "uint160[]"
649
+ name: "currency",
650
+ type: "address",
651
+ internalType: "Currency"
314
652
  }],
315
- stateMutability: "view"
653
+ outputs: [],
654
+ stateMutability: "nonpayable"
316
655
  },
317
656
  {
318
657
  type: "function",
319
- name: "positions",
320
- inputs: [{
321
- name: "key",
322
- type: "bytes32",
323
- internalType: "bytes32"
324
- }],
325
- outputs: [
658
+ name: "take",
659
+ inputs: [
326
660
  {
327
- name: "liquidity",
328
- type: "uint128",
329
- internalType: "uint128"
661
+ name: "currency",
662
+ type: "address",
663
+ internalType: "Currency"
664
+ },
665
+ {
666
+ name: "to",
667
+ type: "address",
668
+ internalType: "address"
330
669
  },
331
670
  {
332
- name: "feeGrowthInside0LastX128",
671
+ name: "amount",
333
672
  type: "uint256",
334
673
  internalType: "uint256"
674
+ }
675
+ ],
676
+ outputs: [],
677
+ stateMutability: "nonpayable"
678
+ },
679
+ {
680
+ type: "function",
681
+ name: "transfer",
682
+ inputs: [
683
+ {
684
+ name: "receiver",
685
+ type: "address",
686
+ internalType: "address"
335
687
  },
336
688
  {
337
- name: "feeGrowthInside1LastX128",
689
+ name: "id",
338
690
  type: "uint256",
339
691
  internalType: "uint256"
340
692
  },
341
693
  {
342
- name: "tokensOwed0",
343
- type: "uint128",
344
- internalType: "uint128"
694
+ name: "amount",
695
+ type: "uint256",
696
+ internalType: "uint256"
697
+ }
698
+ ],
699
+ outputs: [{
700
+ name: "",
701
+ type: "bool",
702
+ internalType: "bool"
703
+ }],
704
+ stateMutability: "nonpayable"
705
+ },
706
+ {
707
+ type: "function",
708
+ name: "transferFrom",
709
+ inputs: [
710
+ {
711
+ name: "sender",
712
+ type: "address",
713
+ internalType: "address"
345
714
  },
346
715
  {
347
- name: "tokensOwed1",
348
- type: "uint128",
349
- internalType: "uint128"
716
+ name: "receiver",
717
+ type: "address",
718
+ internalType: "address"
719
+ },
720
+ {
721
+ name: "id",
722
+ type: "uint256",
723
+ internalType: "uint256"
724
+ },
725
+ {
726
+ name: "amount",
727
+ type: "uint256",
728
+ internalType: "uint256"
350
729
  }
351
730
  ],
352
- stateMutability: "view"
731
+ outputs: [{
732
+ name: "",
733
+ type: "bool",
734
+ internalType: "bool"
735
+ }],
736
+ stateMutability: "nonpayable"
353
737
  },
354
738
  {
355
739
  type: "function",
356
- name: "protocolFees",
357
- inputs: [],
740
+ name: "unlock",
741
+ inputs: [{
742
+ name: "data",
743
+ type: "bytes",
744
+ internalType: "bytes"
745
+ }],
358
746
  outputs: [{
359
- name: "token0",
360
- type: "uint128",
361
- internalType: "uint128"
362
- }, {
363
- name: "token1",
364
- type: "uint128",
365
- internalType: "uint128"
747
+ name: "",
748
+ type: "bytes",
749
+ internalType: "bytes"
366
750
  }],
367
- stateMutability: "view"
751
+ stateMutability: "nonpayable"
368
752
  },
369
753
  {
370
754
  type: "function",
371
- name: "setFeeProtocol",
755
+ name: "updateDynamicLPFee",
372
756
  inputs: [{
373
- name: "feeProtocol0",
374
- type: "uint8",
375
- internalType: "uint8"
757
+ name: "key",
758
+ type: "tuple",
759
+ internalType: "struct PoolKey",
760
+ components: [
761
+ {
762
+ name: "currency0",
763
+ type: "address",
764
+ internalType: "Currency"
765
+ },
766
+ {
767
+ name: "currency1",
768
+ type: "address",
769
+ internalType: "Currency"
770
+ },
771
+ {
772
+ name: "fee",
773
+ type: "uint24",
774
+ internalType: "uint24"
775
+ },
776
+ {
777
+ name: "tickSpacing",
778
+ type: "int24",
779
+ internalType: "int24"
780
+ },
781
+ {
782
+ name: "hooks",
783
+ type: "address",
784
+ internalType: "contract IHooks"
785
+ }
786
+ ]
376
787
  }, {
377
- name: "feeProtocol1",
378
- type: "uint8",
379
- internalType: "uint8"
788
+ name: "newDynamicLPFee",
789
+ type: "uint24",
790
+ internalType: "uint24"
380
791
  }],
381
792
  outputs: [],
382
793
  stateMutability: "nonpayable"
383
794
  },
384
795
  {
385
- type: "function",
386
- name: "slot0",
387
- inputs: [],
388
- outputs: [
796
+ type: "event",
797
+ name: "Approval",
798
+ inputs: [
799
+ {
800
+ name: "owner",
801
+ type: "address",
802
+ indexed: true,
803
+ internalType: "address"
804
+ },
805
+ {
806
+ name: "spender",
807
+ type: "address",
808
+ indexed: true,
809
+ internalType: "address"
810
+ },
811
+ {
812
+ name: "id",
813
+ type: "uint256",
814
+ indexed: true,
815
+ internalType: "uint256"
816
+ },
817
+ {
818
+ name: "amount",
819
+ type: "uint256",
820
+ indexed: false,
821
+ internalType: "uint256"
822
+ }
823
+ ],
824
+ anonymous: false
825
+ },
826
+ {
827
+ type: "event",
828
+ name: "Donate",
829
+ inputs: [
830
+ {
831
+ name: "id",
832
+ type: "bytes32",
833
+ indexed: true,
834
+ internalType: "PoolId"
835
+ },
836
+ {
837
+ name: "sender",
838
+ type: "address",
839
+ indexed: true,
840
+ internalType: "address"
841
+ },
842
+ {
843
+ name: "amount0",
844
+ type: "uint256",
845
+ indexed: false,
846
+ internalType: "uint256"
847
+ },
848
+ {
849
+ name: "amount1",
850
+ type: "uint256",
851
+ indexed: false,
852
+ internalType: "uint256"
853
+ }
854
+ ],
855
+ anonymous: false
856
+ },
857
+ {
858
+ type: "event",
859
+ name: "Initialize",
860
+ inputs: [
861
+ {
862
+ name: "id",
863
+ type: "bytes32",
864
+ indexed: true,
865
+ internalType: "PoolId"
866
+ },
867
+ {
868
+ name: "currency0",
869
+ type: "address",
870
+ indexed: true,
871
+ internalType: "Currency"
872
+ },
873
+ {
874
+ name: "currency1",
875
+ type: "address",
876
+ indexed: true,
877
+ internalType: "Currency"
878
+ },
879
+ {
880
+ name: "fee",
881
+ type: "uint24",
882
+ indexed: false,
883
+ internalType: "uint24"
884
+ },
885
+ {
886
+ name: "tickSpacing",
887
+ type: "int24",
888
+ indexed: false,
889
+ internalType: "int24"
890
+ },
891
+ {
892
+ name: "hooks",
893
+ type: "address",
894
+ indexed: false,
895
+ internalType: "contract IHooks"
896
+ },
389
897
  {
390
898
  name: "sqrtPriceX96",
391
899
  type: "uint160",
900
+ indexed: false,
392
901
  internalType: "uint160"
393
902
  },
394
903
  {
395
904
  name: "tick",
396
905
  type: "int24",
906
+ indexed: false,
907
+ internalType: "int24"
908
+ }
909
+ ],
910
+ anonymous: false
911
+ },
912
+ {
913
+ type: "event",
914
+ name: "ModifyLiquidity",
915
+ inputs: [
916
+ {
917
+ name: "id",
918
+ type: "bytes32",
919
+ indexed: true,
920
+ internalType: "PoolId"
921
+ },
922
+ {
923
+ name: "sender",
924
+ type: "address",
925
+ indexed: true,
926
+ internalType: "address"
927
+ },
928
+ {
929
+ name: "tickLower",
930
+ type: "int24",
931
+ indexed: false,
397
932
  internalType: "int24"
398
933
  },
399
934
  {
400
- name: "observationIndex",
401
- type: "uint16",
402
- internalType: "uint16"
935
+ name: "tickUpper",
936
+ type: "int24",
937
+ indexed: false,
938
+ internalType: "int24"
403
939
  },
404
940
  {
405
- name: "observationCardinality",
406
- type: "uint16",
407
- internalType: "uint16"
941
+ name: "liquidityDelta",
942
+ type: "int256",
943
+ indexed: false,
944
+ internalType: "int256"
408
945
  },
409
946
  {
410
- name: "observationCardinalityNext",
411
- type: "uint16",
412
- internalType: "uint16"
947
+ name: "salt",
948
+ type: "bytes32",
949
+ indexed: false,
950
+ internalType: "bytes32"
951
+ }
952
+ ],
953
+ anonymous: false
954
+ },
955
+ {
956
+ type: "event",
957
+ name: "OperatorSet",
958
+ inputs: [
959
+ {
960
+ name: "owner",
961
+ type: "address",
962
+ indexed: true,
963
+ internalType: "address"
413
964
  },
414
965
  {
415
- name: "feeProtocol",
416
- type: "uint8",
417
- internalType: "uint8"
966
+ name: "operator",
967
+ type: "address",
968
+ indexed: true,
969
+ internalType: "address"
418
970
  },
419
971
  {
420
- name: "unlocked",
972
+ name: "approved",
421
973
  type: "bool",
974
+ indexed: false,
422
975
  internalType: "bool"
423
976
  }
424
977
  ],
425
- stateMutability: "view"
978
+ anonymous: false
426
979
  },
427
980
  {
428
- type: "function",
429
- name: "snapshotCumulativesInside",
981
+ type: "event",
982
+ name: "ProtocolFeeControllerUpdated",
430
983
  inputs: [{
431
- name: "tickLower",
432
- type: "int24",
433
- internalType: "int24"
984
+ name: "protocolFeeController",
985
+ type: "address",
986
+ indexed: true,
987
+ internalType: "address"
988
+ }],
989
+ anonymous: false
990
+ },
991
+ {
992
+ type: "event",
993
+ name: "ProtocolFeeUpdated",
994
+ inputs: [{
995
+ name: "id",
996
+ type: "bytes32",
997
+ indexed: true,
998
+ internalType: "PoolId"
434
999
  }, {
435
- name: "tickUpper",
436
- type: "int24",
437
- internalType: "int24"
1000
+ name: "protocolFee",
1001
+ type: "uint24",
1002
+ indexed: false,
1003
+ internalType: "uint24"
438
1004
  }],
439
- outputs: [
1005
+ anonymous: false
1006
+ },
1007
+ {
1008
+ type: "event",
1009
+ name: "Swap",
1010
+ inputs: [
440
1011
  {
441
- name: "tickCumulativeInside",
442
- type: "int56",
443
- internalType: "int56"
1012
+ name: "id",
1013
+ type: "bytes32",
1014
+ indexed: true,
1015
+ internalType: "PoolId"
1016
+ },
1017
+ {
1018
+ name: "sender",
1019
+ type: "address",
1020
+ indexed: true,
1021
+ internalType: "address"
1022
+ },
1023
+ {
1024
+ name: "amount0",
1025
+ type: "int128",
1026
+ indexed: false,
1027
+ internalType: "int128"
1028
+ },
1029
+ {
1030
+ name: "amount1",
1031
+ type: "int128",
1032
+ indexed: false,
1033
+ internalType: "int128"
444
1034
  },
445
1035
  {
446
- name: "secondsPerLiquidityInsideX128",
1036
+ name: "sqrtPriceX96",
447
1037
  type: "uint160",
1038
+ indexed: false,
448
1039
  internalType: "uint160"
449
1040
  },
450
1041
  {
451
- name: "secondsInside",
452
- type: "uint32",
453
- internalType: "uint32"
1042
+ name: "liquidity",
1043
+ type: "uint128",
1044
+ indexed: false,
1045
+ internalType: "uint128"
1046
+ },
1047
+ {
1048
+ name: "tick",
1049
+ type: "int24",
1050
+ indexed: false,
1051
+ internalType: "int24"
1052
+ },
1053
+ {
1054
+ name: "fee",
1055
+ type: "uint24",
1056
+ indexed: false,
1057
+ internalType: "uint24"
454
1058
  }
455
1059
  ],
456
- stateMutability: "view"
1060
+ anonymous: false
457
1061
  },
458
1062
  {
459
- type: "function",
460
- name: "swap",
1063
+ type: "event",
1064
+ name: "Transfer",
461
1065
  inputs: [
462
1066
  {
463
- name: "recipient",
1067
+ name: "caller",
464
1068
  type: "address",
1069
+ indexed: false,
465
1070
  internalType: "address"
466
1071
  },
467
1072
  {
468
- name: "zeroForOne",
469
- type: "bool",
470
- internalType: "bool"
1073
+ name: "from",
1074
+ type: "address",
1075
+ indexed: true,
1076
+ internalType: "address"
471
1077
  },
472
1078
  {
473
- name: "amountSpecified",
474
- type: "int256",
475
- internalType: "int256"
1079
+ name: "to",
1080
+ type: "address",
1081
+ indexed: true,
1082
+ internalType: "address"
476
1083
  },
477
1084
  {
478
- name: "sqrtPriceLimitX96",
479
- type: "uint160",
480
- internalType: "uint160"
1085
+ name: "id",
1086
+ type: "uint256",
1087
+ indexed: true,
1088
+ internalType: "uint256"
481
1089
  },
482
1090
  {
483
- name: "data",
484
- type: "bytes",
485
- internalType: "bytes"
1091
+ name: "amount",
1092
+ type: "uint256",
1093
+ indexed: false,
1094
+ internalType: "uint256"
486
1095
  }
487
1096
  ],
488
- outputs: [{
489
- name: "amount0",
490
- type: "int256",
491
- internalType: "int256"
1097
+ anonymous: false
1098
+ },
1099
+ {
1100
+ type: "error",
1101
+ name: "AlreadyUnlocked",
1102
+ inputs: []
1103
+ },
1104
+ {
1105
+ type: "error",
1106
+ name: "CurrenciesOutOfOrderOrEqual",
1107
+ inputs: [{
1108
+ name: "currency0",
1109
+ type: "address",
1110
+ internalType: "address"
492
1111
  }, {
493
- name: "amount1",
494
- type: "int256",
495
- internalType: "int256"
496
- }],
1112
+ name: "currency1",
1113
+ type: "address",
1114
+ internalType: "address"
1115
+ }]
1116
+ },
1117
+ {
1118
+ type: "error",
1119
+ name: "CurrencyNotSettled",
1120
+ inputs: []
1121
+ },
1122
+ {
1123
+ type: "error",
1124
+ name: "InvalidCaller",
1125
+ inputs: []
1126
+ },
1127
+ {
1128
+ type: "error",
1129
+ name: "ManagerLocked",
1130
+ inputs: []
1131
+ },
1132
+ {
1133
+ type: "error",
1134
+ name: "MustClearExactPositiveDelta",
1135
+ inputs: []
1136
+ },
1137
+ {
1138
+ type: "error",
1139
+ name: "NonzeroNativeValue",
1140
+ inputs: []
1141
+ },
1142
+ {
1143
+ type: "error",
1144
+ name: "PoolNotInitialized",
1145
+ inputs: []
1146
+ },
1147
+ {
1148
+ type: "error",
1149
+ name: "ProtocolFeeCurrencySynced",
1150
+ inputs: []
1151
+ },
1152
+ {
1153
+ type: "error",
1154
+ name: "ProtocolFeeTooLarge",
1155
+ inputs: [{
1156
+ name: "fee",
1157
+ type: "uint24",
1158
+ internalType: "uint24"
1159
+ }]
1160
+ },
1161
+ {
1162
+ type: "error",
1163
+ name: "SwapAmountCannotBeZero",
1164
+ inputs: []
1165
+ },
1166
+ {
1167
+ type: "error",
1168
+ name: "TickSpacingTooLarge",
1169
+ inputs: [{
1170
+ name: "tickSpacing",
1171
+ type: "int24",
1172
+ internalType: "int24"
1173
+ }]
1174
+ },
1175
+ {
1176
+ type: "error",
1177
+ name: "TickSpacingTooSmall",
1178
+ inputs: [{
1179
+ name: "tickSpacing",
1180
+ type: "int24",
1181
+ internalType: "int24"
1182
+ }]
1183
+ },
1184
+ {
1185
+ type: "error",
1186
+ name: "UnauthorizedDynamicLPFeeUpdate",
1187
+ inputs: []
1188
+ }
1189
+ ];
1190
+
1191
+ //#endregion
1192
+ //#region src/abis/feeStrategy.ts
1193
+ const feeStrategyAbi = [
1194
+ {
1195
+ type: "constructor",
1196
+ inputs: [
1197
+ {
1198
+ name: "_openingFeeRate",
1199
+ type: "uint32",
1200
+ internalType: "uint32"
1201
+ },
1202
+ {
1203
+ name: "_baseFeeRate",
1204
+ type: "uint32",
1205
+ internalType: "uint32"
1206
+ },
1207
+ {
1208
+ name: "_minOpeningFee",
1209
+ type: "uint128",
1210
+ internalType: "uint128"
1211
+ },
1212
+ {
1213
+ name: "_minBaseFee",
1214
+ type: "uint128",
1215
+ internalType: "uint128"
1216
+ },
1217
+ {
1218
+ name: "_feeRecipient",
1219
+ type: "address",
1220
+ internalType: "address"
1221
+ }
1222
+ ],
497
1223
  stateMutability: "nonpayable"
498
1224
  },
499
1225
  {
500
1226
  type: "function",
501
- name: "tickBitmap",
502
- inputs: [{
503
- name: "wordPosition",
504
- type: "int16",
505
- internalType: "int16"
506
- }],
1227
+ name: "PRECISION",
1228
+ inputs: [],
507
1229
  outputs: [{
508
1230
  name: "",
509
1231
  type: "uint256",
@@ -513,96 +1235,125 @@ const uniswapV3PoolAbi = [
513
1235
  },
514
1236
  {
515
1237
  type: "function",
516
- name: "tickSpacing",
1238
+ name: "baseFeeRate",
517
1239
  inputs: [],
518
1240
  outputs: [{
519
1241
  name: "",
520
- type: "int24",
521
- internalType: "int24"
1242
+ type: "uint32",
1243
+ internalType: "uint32"
522
1244
  }],
523
1245
  stateMutability: "view"
524
1246
  },
525
1247
  {
526
1248
  type: "function",
527
- name: "ticks",
528
- inputs: [{
529
- name: "tick",
530
- type: "int24",
531
- internalType: "int24"
1249
+ name: "feeRecipient",
1250
+ inputs: [],
1251
+ outputs: [{
1252
+ name: "",
1253
+ type: "address",
1254
+ internalType: "address"
532
1255
  }],
533
- outputs: [
1256
+ stateMutability: "view"
1257
+ },
1258
+ {
1259
+ type: "function",
1260
+ name: "getProtocolFee",
1261
+ inputs: [
534
1262
  {
535
- name: "liquidityGross",
536
- type: "uint128",
537
- internalType: "uint128"
1263
+ name: "",
1264
+ type: "address",
1265
+ internalType: "address"
538
1266
  },
539
1267
  {
540
- name: "liquidityNet",
541
- type: "int128",
542
- internalType: "int128"
1268
+ name: "",
1269
+ type: "uint8",
1270
+ internalType: "uint8"
543
1271
  },
544
1272
  {
545
- name: "feeGrowthOutside0X128",
1273
+ name: "optionAmount",
546
1274
  type: "uint256",
547
1275
  internalType: "uint256"
548
1276
  },
549
1277
  {
550
- name: "feeGrowthOutside1X128",
1278
+ name: "currentPrice",
551
1279
  type: "uint256",
552
1280
  internalType: "uint256"
553
1281
  },
554
1282
  {
555
- name: "tickCumulativeOutside",
556
- type: "int56",
557
- internalType: "int56"
1283
+ name: "",
1284
+ type: "uint256",
1285
+ internalType: "uint256"
558
1286
  },
559
1287
  {
560
- name: "secondsPerLiquidityOutsideX128",
561
- type: "uint160",
562
- internalType: "uint160"
1288
+ name: "",
1289
+ type: "uint32",
1290
+ internalType: "uint32"
563
1291
  },
564
1292
  {
565
- name: "secondsOutside",
1293
+ name: "remainingDuration",
566
1294
  type: "uint32",
567
1295
  internalType: "uint32"
568
1296
  },
569
1297
  {
570
- name: "initialized",
571
- type: "bool",
572
- internalType: "bool"
1298
+ name: "premium",
1299
+ type: "uint256",
1300
+ internalType: "uint256"
573
1301
  }
574
1302
  ],
1303
+ outputs: [{
1304
+ name: "feeAmount",
1305
+ type: "uint256",
1306
+ internalType: "uint256"
1307
+ }, {
1308
+ name: "recipient",
1309
+ type: "address",
1310
+ internalType: "address"
1311
+ }],
575
1312
  stateMutability: "view"
576
1313
  },
577
1314
  {
578
1315
  type: "function",
579
- name: "token0",
1316
+ name: "minBaseFee",
580
1317
  inputs: [],
581
1318
  outputs: [{
582
1319
  name: "",
583
- type: "address",
584
- internalType: "address"
1320
+ type: "uint128",
1321
+ internalType: "uint128"
585
1322
  }],
586
1323
  stateMutability: "view"
587
1324
  },
588
1325
  {
589
1326
  type: "function",
590
- name: "token1",
1327
+ name: "minOpeningFee",
591
1328
  inputs: [],
592
1329
  outputs: [{
593
1330
  name: "",
594
- type: "address",
595
- internalType: "address"
1331
+ type: "uint128",
1332
+ internalType: "uint128"
1333
+ }],
1334
+ stateMutability: "view"
1335
+ },
1336
+ {
1337
+ type: "function",
1338
+ name: "openingFeeRate",
1339
+ inputs: [],
1340
+ outputs: [{
1341
+ name: "",
1342
+ type: "uint32",
1343
+ internalType: "uint32"
596
1344
  }],
597
1345
  stateMutability: "view"
598
1346
  }
599
1347
  ];
600
1348
 
601
1349
  //#endregion
602
- exports.erc20Abi = require_optionsMarket.erc20Abi;
603
- exports.lensAbi = require_optionsMarket.lensAbi;
604
- exports.optionsMarketAbi = require_optionsMarket.optionsMarketAbi;
605
- exports.singleOwnerVaultAbi = require_singleOwnerVault.singleOwnerVaultAbi;
606
- exports.uniswapMathLensAbi = require_optionsMarket.uniswapMathLensAbi;
607
- exports.uniswapV3PoolAbi = uniswapV3PoolAbi;
1350
+ exports.erc20Abi = require_statelessStateView.erc20Abi;
1351
+ exports.factoryAbi = require_factory.factoryAbi;
1352
+ exports.feeStrategyAbi = feeStrategyAbi;
1353
+ exports.guardianAbi = require_factory.guardianAbi;
1354
+ exports.lensAbi = require_statelessStateView.lensAbi;
1355
+ exports.optionsMarketAbi = require_statelessStateView.optionsMarketAbi;
1356
+ exports.poolManagerAbi = poolManagerAbi;
1357
+ exports.singleOwnerVaultAbi = require_factory.singleOwnerVaultAbi;
1358
+ exports.statelessStateViewAbi = require_statelessStateView.statelessStateViewAbi;
608
1359
  //# sourceMappingURL=abis.cjs.map