@zoralabs/coins 1.1.2 → 2.1.0
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/.turbo/turbo-build.log +107 -110
- package/CHANGELOG.md +50 -0
- package/README.md +48 -1
- package/abis/BaseCoin.json +442 -0
- package/abis/BaseZoraV4CoinHook.json +6 -2
- package/abis/CoinTest.json +3 -246
- package/abis/CoinUniV4Test.json +20 -0
- package/abis/ContentCoinHook.json +6 -2
- package/abis/CreatorCoinHook.json +6 -2
- package/abis/FactoryTest.json +8 -133
- package/abis/FeeEstimatorHook.json +6 -2
- package/abis/HooksTest.json +0 -26
- package/abis/ICoin.json +378 -0
- package/abis/ICoinV3.json +378 -0
- package/abis/IZoraFactory.json +0 -18
- package/abis/IZoraV4CoinHook.json +2 -2
- package/abis/LiquidityMigrationTest.json +101 -0
- package/abis/MockBadFactory.json +15 -0
- package/abis/Ownable2StepUpgradeable.json +138 -0
- package/abis/ZoraFactoryImpl.json +38 -65
- package/addresses/8453.json +5 -5
- package/dist/index.cjs +272 -268
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +270 -266
- package/dist/index.js.map +1 -1
- package/dist/wagmiGenerated.d.ts +397 -470
- package/dist/wagmiGenerated.d.ts.map +1 -1
- package/package/wagmiGenerated.ts +275 -271
- package/package.json +3 -3
- package/script/DeployPostDeploymentHooks.s.sol +2 -2
- package/script/TestBackingCoinSwap.s.sol +9 -9
- package/script/TestV4Swap.s.sol +9 -9
- package/script/UpgradeFactoryImpl.s.sol +0 -1
- package/src/BaseCoin.sol +109 -6
- package/src/ContentCoin.sol +45 -0
- package/src/CreatorCoin.sol +7 -5
- package/src/ZoraFactoryImpl.sol +12 -95
- package/src/deployment/CoinsDeployerBase.sol +13 -30
- package/src/hooks/BaseZoraV4CoinHook.sol +8 -6
- package/src/hooks/deployment/BuySupplyWithSwapRouterHook.sol +4 -5
- package/src/interfaces/ICoin.sol +67 -1
- package/src/interfaces/ICreatorCoin.sol +2 -2
- package/src/interfaces/IZoraFactory.sol +0 -5
- package/src/interfaces/IZoraV4CoinHook.sol +1 -1
- package/src/libs/CoinConfigurationVersions.sol +1 -39
- package/src/libs/CoinRewardsV4.sol +2 -2
- package/src/libs/CoinSetup.sol +1 -4
- package/src/libs/UniV4SwapHelper.sol +1 -1
- package/src/libs/UniV4SwapToCurrency.sol +2 -2
- package/src/libs/V4Liquidity.sol +1 -1
- package/src/version/ContractVersionBase.sol +1 -1
- package/test/Coin.t.sol +112 -535
- package/test/CoinUniV4.t.sol +66 -10
- package/test/DeploymentHooks.t.sol +5 -102
- package/test/Factory.t.sol +49 -291
- package/test/LiquidityMigration.t.sol +160 -2
- package/test/MultiOwnable.t.sol +36 -36
- package/test/Upgrades.t.sol +23 -42
- package/test/utils/BaseTest.sol +39 -84
- package/test/utils/FeeEstimatorHook.sol +3 -3
- package/wagmi.config.ts +2 -2
- package/abis/Coin.json +0 -1912
- package/abis/DopplerUniswapV3Test.json +0 -800
- package/abis/ICoinV4.json +0 -1048
- package/abis/Simulate.json +0 -29
- package/abis/UniV3BuySell.json +0 -12
- package/abis/UniV3Errors.json +0 -32
- package/script/Simulate.s.sol +0 -59
- package/src/Coin.sol +0 -236
- package/src/CoinV4.sol +0 -151
- package/src/interfaces/ICoinV4.sol +0 -74
- package/src/libs/CoinDopplerUniV3.sol +0 -50
- package/src/libs/CoinRewards.sol +0 -201
- package/src/libs/CoinSetupV3.sol +0 -50
- package/src/libs/UniV3BuySell.sol +0 -231
- package/src/libs/UniV3Errors.sol +0 -11
- package/test/CoinDopplerUniV3.t.sol +0 -310
- /package/abis/{CoinV4.json → ContentCoin.json} +0 -0
package/dist/index.js
CHANGED
|
@@ -91,110 +91,7 @@ var autoSwapperABI = [
|
|
|
91
91
|
{ type: "error", inputs: [], name: "InvalidSelector" },
|
|
92
92
|
{ type: "error", inputs: [], name: "NotSwapper" }
|
|
93
93
|
];
|
|
94
|
-
var
|
|
95
|
-
{
|
|
96
|
-
type: "constructor",
|
|
97
|
-
inputs: [
|
|
98
|
-
{
|
|
99
|
-
name: "_factory",
|
|
100
|
-
internalType: "contract IZoraFactory",
|
|
101
|
-
type: "address"
|
|
102
|
-
},
|
|
103
|
-
{ name: "_swapRouter", internalType: "address", type: "address" },
|
|
104
|
-
{ name: "_poolManager", internalType: "address", type: "address" }
|
|
105
|
-
],
|
|
106
|
-
stateMutability: "nonpayable"
|
|
107
|
-
},
|
|
108
|
-
{
|
|
109
|
-
type: "function",
|
|
110
|
-
inputs: [
|
|
111
|
-
{ name: "sender", internalType: "address", type: "address" },
|
|
112
|
-
{ name: "coin", internalType: "contract ICoin", type: "address" },
|
|
113
|
-
{ name: "hookData", internalType: "bytes", type: "bytes" }
|
|
114
|
-
],
|
|
115
|
-
name: "afterCoinDeploy",
|
|
116
|
-
outputs: [{ name: "", internalType: "bytes", type: "bytes" }],
|
|
117
|
-
stateMutability: "payable"
|
|
118
|
-
},
|
|
119
|
-
{
|
|
120
|
-
type: "function",
|
|
121
|
-
inputs: [],
|
|
122
|
-
name: "factory",
|
|
123
|
-
outputs: [
|
|
124
|
-
{ name: "", internalType: "contract IZoraFactory", type: "address" }
|
|
125
|
-
],
|
|
126
|
-
stateMutability: "view"
|
|
127
|
-
},
|
|
128
|
-
{
|
|
129
|
-
type: "function",
|
|
130
|
-
inputs: [{ name: "interfaceId", internalType: "bytes4", type: "bytes4" }],
|
|
131
|
-
name: "supportsInterface",
|
|
132
|
-
outputs: [{ name: "", internalType: "bool", type: "bool" }],
|
|
133
|
-
stateMutability: "pure"
|
|
134
|
-
},
|
|
135
|
-
{
|
|
136
|
-
type: "function",
|
|
137
|
-
inputs: [{ name: "data", internalType: "bytes", type: "bytes" }],
|
|
138
|
-
name: "unlockCallback",
|
|
139
|
-
outputs: [{ name: "", internalType: "bytes", type: "bytes" }],
|
|
140
|
-
stateMutability: "nonpayable"
|
|
141
|
-
},
|
|
142
|
-
{
|
|
143
|
-
type: "error",
|
|
144
|
-
inputs: [{ name: "target", internalType: "address", type: "address" }],
|
|
145
|
-
name: "AddressEmptyCode"
|
|
146
|
-
},
|
|
147
|
-
{
|
|
148
|
-
type: "error",
|
|
149
|
-
inputs: [{ name: "account", internalType: "address", type: "address" }],
|
|
150
|
-
name: "AddressInsufficientBalance"
|
|
151
|
-
},
|
|
152
|
-
{ type: "error", inputs: [], name: "AddressZero" },
|
|
153
|
-
{
|
|
154
|
-
type: "error",
|
|
155
|
-
inputs: [{ name: "balance", internalType: "uint256", type: "uint256" }],
|
|
156
|
-
name: "CoinBalanceNot0"
|
|
157
|
-
},
|
|
158
|
-
{
|
|
159
|
-
type: "error",
|
|
160
|
-
inputs: [{ name: "balance", internalType: "uint256", type: "uint256" }],
|
|
161
|
-
name: "CurrencyBalanceNot0"
|
|
162
|
-
},
|
|
163
|
-
{ type: "error", inputs: [], name: "Erc20NotReceived" },
|
|
164
|
-
{ type: "error", inputs: [], name: "FailedInnerCall" },
|
|
165
|
-
{ type: "error", inputs: [], name: "HookNotImplemented" },
|
|
166
|
-
{ type: "error", inputs: [], name: "InvalidSwapRouterCall" },
|
|
167
|
-
{ type: "error", inputs: [], name: "NotFactory" },
|
|
168
|
-
{ type: "error", inputs: [], name: "OnlyPoolManager" },
|
|
169
|
-
{
|
|
170
|
-
type: "error",
|
|
171
|
-
inputs: [{ name: "token", internalType: "address", type: "address" }],
|
|
172
|
-
name: "SafeERC20FailedOperation"
|
|
173
|
-
},
|
|
174
|
-
{
|
|
175
|
-
type: "error",
|
|
176
|
-
inputs: [{ name: "error", internalType: "bytes", type: "bytes" }],
|
|
177
|
-
name: "SwapReverted"
|
|
178
|
-
}
|
|
179
|
-
];
|
|
180
|
-
var coinABI = [
|
|
181
|
-
{
|
|
182
|
-
type: "constructor",
|
|
183
|
-
inputs: [
|
|
184
|
-
{
|
|
185
|
-
name: "protocolRewardRecipient_",
|
|
186
|
-
internalType: "address",
|
|
187
|
-
type: "address"
|
|
188
|
-
},
|
|
189
|
-
{ name: "protocolRewards_", internalType: "address", type: "address" },
|
|
190
|
-
{ name: "weth_", internalType: "address", type: "address" },
|
|
191
|
-
{ name: "v3Factory_", internalType: "address", type: "address" },
|
|
192
|
-
{ name: "swapRouter_", internalType: "address", type: "address" },
|
|
193
|
-
{ name: "airlock_", internalType: "address", type: "address" }
|
|
194
|
-
],
|
|
195
|
-
stateMutability: "nonpayable"
|
|
196
|
-
},
|
|
197
|
-
{ type: "receive", stateMutability: "payable" },
|
|
94
|
+
var baseCoinABI = [
|
|
198
95
|
{
|
|
199
96
|
type: "function",
|
|
200
97
|
inputs: [],
|
|
@@ -202,13 +99,6 @@ var coinABI = [
|
|
|
202
99
|
outputs: [{ name: "", internalType: "bytes32", type: "bytes32" }],
|
|
203
100
|
stateMutability: "view"
|
|
204
101
|
},
|
|
205
|
-
{
|
|
206
|
-
type: "function",
|
|
207
|
-
inputs: [],
|
|
208
|
-
name: "WETH",
|
|
209
|
-
outputs: [{ name: "", internalType: "address", type: "address" }],
|
|
210
|
-
stateMutability: "view"
|
|
211
|
-
},
|
|
212
102
|
{
|
|
213
103
|
type: "function",
|
|
214
104
|
inputs: [{ name: "account", internalType: "address", type: "address" }],
|
|
@@ -266,29 +156,6 @@ var coinABI = [
|
|
|
266
156
|
outputs: [],
|
|
267
157
|
stateMutability: "nonpayable"
|
|
268
158
|
},
|
|
269
|
-
{
|
|
270
|
-
type: "function",
|
|
271
|
-
inputs: [
|
|
272
|
-
{ name: "recipient", internalType: "address", type: "address" },
|
|
273
|
-
{ name: "orderSize", internalType: "uint256", type: "uint256" },
|
|
274
|
-
{ name: "minAmountOut", internalType: "uint256", type: "uint256" },
|
|
275
|
-
{ name: "sqrtPriceLimitX96", internalType: "uint160", type: "uint160" },
|
|
276
|
-
{ name: "tradeReferrer", internalType: "address", type: "address" }
|
|
277
|
-
],
|
|
278
|
-
name: "buy",
|
|
279
|
-
outputs: [
|
|
280
|
-
{ name: "", internalType: "uint256", type: "uint256" },
|
|
281
|
-
{ name: "", internalType: "uint256", type: "uint256" }
|
|
282
|
-
],
|
|
283
|
-
stateMutability: "payable"
|
|
284
|
-
},
|
|
285
|
-
{
|
|
286
|
-
type: "function",
|
|
287
|
-
inputs: [{ name: "pushEthRewards", internalType: "bool", type: "bool" }],
|
|
288
|
-
name: "claimSecondaryRewards",
|
|
289
|
-
outputs: [],
|
|
290
|
-
stateMutability: "nonpayable"
|
|
291
|
-
},
|
|
292
159
|
{
|
|
293
160
|
type: "function",
|
|
294
161
|
inputs: [],
|
|
@@ -339,6 +206,48 @@ var coinABI = [
|
|
|
339
206
|
],
|
|
340
207
|
stateMutability: "view"
|
|
341
208
|
},
|
|
209
|
+
{
|
|
210
|
+
type: "function",
|
|
211
|
+
inputs: [
|
|
212
|
+
{
|
|
213
|
+
name: "coinVersionLookup",
|
|
214
|
+
internalType: "contract IDeployedCoinVersionLookup",
|
|
215
|
+
type: "address"
|
|
216
|
+
}
|
|
217
|
+
],
|
|
218
|
+
name: "getPayoutSwapPath",
|
|
219
|
+
outputs: [
|
|
220
|
+
{
|
|
221
|
+
name: "payoutSwapPath",
|
|
222
|
+
internalType: "struct IHasSwapPath.PayoutSwapPath",
|
|
223
|
+
type: "tuple",
|
|
224
|
+
components: [
|
|
225
|
+
{
|
|
226
|
+
name: "path",
|
|
227
|
+
internalType: "struct PathKey[]",
|
|
228
|
+
type: "tuple[]",
|
|
229
|
+
components: [
|
|
230
|
+
{
|
|
231
|
+
name: "intermediateCurrency",
|
|
232
|
+
internalType: "Currency",
|
|
233
|
+
type: "address"
|
|
234
|
+
},
|
|
235
|
+
{ name: "fee", internalType: "uint24", type: "uint24" },
|
|
236
|
+
{ name: "tickSpacing", internalType: "int24", type: "int24" },
|
|
237
|
+
{
|
|
238
|
+
name: "hooks",
|
|
239
|
+
internalType: "contract IHooks",
|
|
240
|
+
type: "address"
|
|
241
|
+
},
|
|
242
|
+
{ name: "hookData", internalType: "bytes", type: "bytes" }
|
|
243
|
+
]
|
|
244
|
+
},
|
|
245
|
+
{ name: "currencyIn", internalType: "Currency", type: "address" }
|
|
246
|
+
]
|
|
247
|
+
}
|
|
248
|
+
],
|
|
249
|
+
stateMutability: "view"
|
|
250
|
+
},
|
|
342
251
|
{
|
|
343
252
|
type: "function",
|
|
344
253
|
inputs: [],
|
|
@@ -370,6 +279,33 @@ var coinABI = [
|
|
|
370
279
|
],
|
|
371
280
|
stateMutability: "view"
|
|
372
281
|
},
|
|
282
|
+
{
|
|
283
|
+
type: "function",
|
|
284
|
+
inputs: [],
|
|
285
|
+
name: "getPoolKey",
|
|
286
|
+
outputs: [
|
|
287
|
+
{
|
|
288
|
+
name: "",
|
|
289
|
+
internalType: "struct PoolKey",
|
|
290
|
+
type: "tuple",
|
|
291
|
+
components: [
|
|
292
|
+
{ name: "currency0", internalType: "Currency", type: "address" },
|
|
293
|
+
{ name: "currency1", internalType: "Currency", type: "address" },
|
|
294
|
+
{ name: "fee", internalType: "uint24", type: "uint24" },
|
|
295
|
+
{ name: "tickSpacing", internalType: "int24", type: "int24" },
|
|
296
|
+
{ name: "hooks", internalType: "contract IHooks", type: "address" }
|
|
297
|
+
]
|
|
298
|
+
}
|
|
299
|
+
],
|
|
300
|
+
stateMutability: "view"
|
|
301
|
+
},
|
|
302
|
+
{
|
|
303
|
+
type: "function",
|
|
304
|
+
inputs: [],
|
|
305
|
+
name: "hooks",
|
|
306
|
+
outputs: [{ name: "", internalType: "contract IHooks", type: "address" }],
|
|
307
|
+
stateMutability: "view"
|
|
308
|
+
},
|
|
373
309
|
{
|
|
374
310
|
type: "function",
|
|
375
311
|
inputs: [
|
|
@@ -380,7 +316,19 @@ var coinABI = [
|
|
|
380
316
|
{ name: "symbol_", internalType: "string", type: "string" },
|
|
381
317
|
{ name: "platformReferrer_", internalType: "address", type: "address" },
|
|
382
318
|
{ name: "currency_", internalType: "address", type: "address" },
|
|
383
|
-
{
|
|
319
|
+
{
|
|
320
|
+
name: "poolKey_",
|
|
321
|
+
internalType: "struct PoolKey",
|
|
322
|
+
type: "tuple",
|
|
323
|
+
components: [
|
|
324
|
+
{ name: "currency0", internalType: "Currency", type: "address" },
|
|
325
|
+
{ name: "currency1", internalType: "Currency", type: "address" },
|
|
326
|
+
{ name: "fee", internalType: "uint24", type: "uint24" },
|
|
327
|
+
{ name: "tickSpacing", internalType: "int24", type: "int24" },
|
|
328
|
+
{ name: "hooks", internalType: "contract IHooks", type: "address" }
|
|
329
|
+
]
|
|
330
|
+
},
|
|
331
|
+
{ name: "sqrtPriceX96", internalType: "uint160", type: "uint160" },
|
|
384
332
|
{
|
|
385
333
|
name: "poolConfiguration_",
|
|
386
334
|
internalType: "struct PoolConfiguration",
|
|
@@ -403,16 +351,6 @@ var coinABI = [
|
|
|
403
351
|
type: "uint256[]"
|
|
404
352
|
}
|
|
405
353
|
]
|
|
406
|
-
},
|
|
407
|
-
{
|
|
408
|
-
name: "positions_",
|
|
409
|
-
internalType: "struct LpPosition[]",
|
|
410
|
-
type: "tuple[]",
|
|
411
|
-
components: [
|
|
412
|
-
{ name: "tickLower", internalType: "int24", type: "int24" },
|
|
413
|
-
{ name: "tickUpper", internalType: "int24", type: "int24" },
|
|
414
|
-
{ name: "liquidity", internalType: "uint128", type: "uint128" }
|
|
415
|
-
]
|
|
416
354
|
}
|
|
417
355
|
],
|
|
418
356
|
name: "initialize",
|
|
@@ -428,17 +366,26 @@ var coinABI = [
|
|
|
428
366
|
},
|
|
429
367
|
{
|
|
430
368
|
type: "function",
|
|
431
|
-
inputs: [
|
|
432
|
-
|
|
433
|
-
|
|
434
|
-
|
|
435
|
-
|
|
436
|
-
|
|
437
|
-
|
|
438
|
-
|
|
439
|
-
|
|
440
|
-
|
|
441
|
-
|
|
369
|
+
inputs: [
|
|
370
|
+
{ name: "newHook", internalType: "address", type: "address" },
|
|
371
|
+
{ name: "additionalData", internalType: "bytes", type: "bytes" }
|
|
372
|
+
],
|
|
373
|
+
name: "migrateLiquidity",
|
|
374
|
+
outputs: [
|
|
375
|
+
{
|
|
376
|
+
name: "newPoolKey",
|
|
377
|
+
internalType: "struct PoolKey",
|
|
378
|
+
type: "tuple",
|
|
379
|
+
components: [
|
|
380
|
+
{ name: "currency0", internalType: "Currency", type: "address" },
|
|
381
|
+
{ name: "currency1", internalType: "Currency", type: "address" },
|
|
382
|
+
{ name: "fee", internalType: "uint24", type: "uint24" },
|
|
383
|
+
{ name: "tickSpacing", internalType: "int24", type: "int24" },
|
|
384
|
+
{ name: "hooks", internalType: "contract IHooks", type: "address" }
|
|
385
|
+
]
|
|
386
|
+
}
|
|
387
|
+
],
|
|
388
|
+
stateMutability: "nonpayable"
|
|
442
389
|
},
|
|
443
390
|
{
|
|
444
391
|
type: "function",
|
|
@@ -493,30 +440,9 @@ var coinABI = [
|
|
|
493
440
|
{
|
|
494
441
|
type: "function",
|
|
495
442
|
inputs: [],
|
|
496
|
-
name: "
|
|
497
|
-
outputs: [{ name: "", internalType: "address", type: "address" }],
|
|
498
|
-
stateMutability: "view"
|
|
499
|
-
},
|
|
500
|
-
{
|
|
501
|
-
type: "function",
|
|
502
|
-
inputs: [],
|
|
503
|
-
name: "poolConfiguration",
|
|
504
|
-
outputs: [
|
|
505
|
-
{ name: "version", internalType: "uint8", type: "uint8" },
|
|
506
|
-
{ name: "numPositions", internalType: "uint16", type: "uint16" },
|
|
507
|
-
{ name: "fee", internalType: "uint24", type: "uint24" },
|
|
508
|
-
{ name: "tickSpacing", internalType: "int24", type: "int24" }
|
|
509
|
-
],
|
|
510
|
-
stateMutability: "view"
|
|
511
|
-
},
|
|
512
|
-
{
|
|
513
|
-
type: "function",
|
|
514
|
-
inputs: [{ name: "", internalType: "uint256", type: "uint256" }],
|
|
515
|
-
name: "positions",
|
|
443
|
+
name: "poolManager",
|
|
516
444
|
outputs: [
|
|
517
|
-
{ name: "
|
|
518
|
-
{ name: "tickUpper", internalType: "int24", type: "int24" },
|
|
519
|
-
{ name: "liquidity", internalType: "uint128", type: "uint128" }
|
|
445
|
+
{ name: "", internalType: "contract IPoolManager", type: "address" }
|
|
520
446
|
],
|
|
521
447
|
stateMutability: "view"
|
|
522
448
|
},
|
|
@@ -557,22 +483,6 @@ var coinABI = [
|
|
|
557
483
|
outputs: [],
|
|
558
484
|
stateMutability: "nonpayable"
|
|
559
485
|
},
|
|
560
|
-
{
|
|
561
|
-
type: "function",
|
|
562
|
-
inputs: [
|
|
563
|
-
{ name: "recipient", internalType: "address", type: "address" },
|
|
564
|
-
{ name: "orderSize", internalType: "uint256", type: "uint256" },
|
|
565
|
-
{ name: "minAmountOut", internalType: "uint256", type: "uint256" },
|
|
566
|
-
{ name: "sqrtPriceLimitX96", internalType: "uint160", type: "uint160" },
|
|
567
|
-
{ name: "tradeReferrer", internalType: "address", type: "address" }
|
|
568
|
-
],
|
|
569
|
-
name: "sell",
|
|
570
|
-
outputs: [
|
|
571
|
-
{ name: "", internalType: "uint256", type: "uint256" },
|
|
572
|
-
{ name: "", internalType: "uint256", type: "uint256" }
|
|
573
|
-
],
|
|
574
|
-
stateMutability: "nonpayable"
|
|
575
|
-
},
|
|
576
486
|
{
|
|
577
487
|
type: "function",
|
|
578
488
|
inputs: [{ name: "newURI", internalType: "string", type: "string" }],
|
|
@@ -606,13 +516,6 @@ var coinABI = [
|
|
|
606
516
|
outputs: [{ name: "", internalType: "bool", type: "bool" }],
|
|
607
517
|
stateMutability: "view"
|
|
608
518
|
},
|
|
609
|
-
{
|
|
610
|
-
type: "function",
|
|
611
|
-
inputs: [],
|
|
612
|
-
name: "swapRouter",
|
|
613
|
-
outputs: [{ name: "", internalType: "address", type: "address" }],
|
|
614
|
-
stateMutability: "view"
|
|
615
|
-
},
|
|
616
519
|
{
|
|
617
520
|
type: "function",
|
|
618
521
|
inputs: [],
|
|
@@ -655,24 +558,6 @@ var coinABI = [
|
|
|
655
558
|
outputs: [{ name: "", internalType: "bool", type: "bool" }],
|
|
656
559
|
stateMutability: "nonpayable"
|
|
657
560
|
},
|
|
658
|
-
{
|
|
659
|
-
type: "function",
|
|
660
|
-
inputs: [
|
|
661
|
-
{ name: "amount0Owed", internalType: "uint256", type: "uint256" },
|
|
662
|
-
{ name: "amount1Owed", internalType: "uint256", type: "uint256" },
|
|
663
|
-
{ name: "", internalType: "bytes", type: "bytes" }
|
|
664
|
-
],
|
|
665
|
-
name: "uniswapV3MintCallback",
|
|
666
|
-
outputs: [],
|
|
667
|
-
stateMutability: "nonpayable"
|
|
668
|
-
},
|
|
669
|
-
{
|
|
670
|
-
type: "function",
|
|
671
|
-
inputs: [],
|
|
672
|
-
name: "v3Factory",
|
|
673
|
-
outputs: [{ name: "", internalType: "address", type: "address" }],
|
|
674
|
-
stateMutability: "view"
|
|
675
|
-
},
|
|
676
561
|
{
|
|
677
562
|
type: "event",
|
|
678
563
|
anonymous: false,
|
|
@@ -1029,6 +914,51 @@ var coinABI = [
|
|
|
1029
914
|
],
|
|
1030
915
|
name: "Initialized"
|
|
1031
916
|
},
|
|
917
|
+
{
|
|
918
|
+
type: "event",
|
|
919
|
+
anonymous: false,
|
|
920
|
+
inputs: [
|
|
921
|
+
{
|
|
922
|
+
name: "fromPoolKey",
|
|
923
|
+
internalType: "struct PoolKey",
|
|
924
|
+
type: "tuple",
|
|
925
|
+
components: [
|
|
926
|
+
{ name: "currency0", internalType: "Currency", type: "address" },
|
|
927
|
+
{ name: "currency1", internalType: "Currency", type: "address" },
|
|
928
|
+
{ name: "fee", internalType: "uint24", type: "uint24" },
|
|
929
|
+
{ name: "tickSpacing", internalType: "int24", type: "int24" },
|
|
930
|
+
{ name: "hooks", internalType: "contract IHooks", type: "address" }
|
|
931
|
+
],
|
|
932
|
+
indexed: false
|
|
933
|
+
},
|
|
934
|
+
{
|
|
935
|
+
name: "fromPoolKeyHash",
|
|
936
|
+
internalType: "bytes32",
|
|
937
|
+
type: "bytes32",
|
|
938
|
+
indexed: false
|
|
939
|
+
},
|
|
940
|
+
{
|
|
941
|
+
name: "toPoolKey",
|
|
942
|
+
internalType: "struct PoolKey",
|
|
943
|
+
type: "tuple",
|
|
944
|
+
components: [
|
|
945
|
+
{ name: "currency0", internalType: "Currency", type: "address" },
|
|
946
|
+
{ name: "currency1", internalType: "Currency", type: "address" },
|
|
947
|
+
{ name: "fee", internalType: "uint24", type: "uint24" },
|
|
948
|
+
{ name: "tickSpacing", internalType: "int24", type: "int24" },
|
|
949
|
+
{ name: "hooks", internalType: "contract IHooks", type: "address" }
|
|
950
|
+
],
|
|
951
|
+
indexed: false
|
|
952
|
+
},
|
|
953
|
+
{
|
|
954
|
+
name: "toPoolKeyHash",
|
|
955
|
+
internalType: "bytes32",
|
|
956
|
+
type: "bytes32",
|
|
957
|
+
indexed: false
|
|
958
|
+
}
|
|
959
|
+
],
|
|
960
|
+
name: "LiquidityMigrated"
|
|
961
|
+
},
|
|
1032
962
|
{
|
|
1033
963
|
type: "event",
|
|
1034
964
|
anonymous: false,
|
|
@@ -1094,17 +1024,6 @@ var coinABI = [
|
|
|
1094
1024
|
],
|
|
1095
1025
|
name: "Transfer"
|
|
1096
1026
|
},
|
|
1097
|
-
{
|
|
1098
|
-
type: "error",
|
|
1099
|
-
inputs: [{ name: "target", internalType: "address", type: "address" }],
|
|
1100
|
-
name: "AddressEmptyCode"
|
|
1101
|
-
},
|
|
1102
|
-
{
|
|
1103
|
-
type: "error",
|
|
1104
|
-
inputs: [{ name: "account", internalType: "address", type: "address" }],
|
|
1105
|
-
name: "AddressInsufficientBalance"
|
|
1106
|
-
},
|
|
1107
|
-
{ type: "error", inputs: [], name: "AddressZero" },
|
|
1108
1027
|
{ type: "error", inputs: [], name: "AddressZero" },
|
|
1109
1028
|
{ type: "error", inputs: [], name: "AlreadyOwner" },
|
|
1110
1029
|
{ type: "error", inputs: [], name: "CannotMintZeroLiquidity" },
|
|
@@ -1180,7 +1099,6 @@ var coinABI = [
|
|
|
1180
1099
|
{ type: "error", inputs: [], name: "EthAmountTooSmall" },
|
|
1181
1100
|
{ type: "error", inputs: [], name: "EthTransferFailed" },
|
|
1182
1101
|
{ type: "error", inputs: [], name: "EthTransferInvalid" },
|
|
1183
|
-
{ type: "error", inputs: [], name: "FailedInnerCall" },
|
|
1184
1102
|
{ type: "error", inputs: [], name: "InitialOrderSizeTooLarge" },
|
|
1185
1103
|
{ type: "error", inputs: [], name: "InsufficientFunds" },
|
|
1186
1104
|
{ type: "error", inputs: [], name: "InsufficientLiquidity" },
|
|
@@ -1233,15 +1151,96 @@ var coinABI = [
|
|
|
1233
1151
|
{ type: "error", inputs: [], name: "OnlyWeth" },
|
|
1234
1152
|
{ type: "error", inputs: [], name: "OwnerCannotBeAddressZero" },
|
|
1235
1153
|
{ type: "error", inputs: [], name: "ReentrancyGuardReentrantCall" },
|
|
1154
|
+
{ type: "error", inputs: [], name: "SlippageBoundsExceeded" },
|
|
1155
|
+
{ type: "error", inputs: [], name: "UseRevokeOwnershipToRemoveSelf" }
|
|
1156
|
+
];
|
|
1157
|
+
var buySupplyWithSwapRouterHookABI = [
|
|
1158
|
+
{
|
|
1159
|
+
type: "constructor",
|
|
1160
|
+
inputs: [
|
|
1161
|
+
{
|
|
1162
|
+
name: "_factory",
|
|
1163
|
+
internalType: "contract IZoraFactory",
|
|
1164
|
+
type: "address"
|
|
1165
|
+
},
|
|
1166
|
+
{ name: "_swapRouter", internalType: "address", type: "address" },
|
|
1167
|
+
{ name: "_poolManager", internalType: "address", type: "address" }
|
|
1168
|
+
],
|
|
1169
|
+
stateMutability: "nonpayable"
|
|
1170
|
+
},
|
|
1171
|
+
{
|
|
1172
|
+
type: "function",
|
|
1173
|
+
inputs: [
|
|
1174
|
+
{ name: "sender", internalType: "address", type: "address" },
|
|
1175
|
+
{ name: "coin", internalType: "contract ICoin", type: "address" },
|
|
1176
|
+
{ name: "hookData", internalType: "bytes", type: "bytes" }
|
|
1177
|
+
],
|
|
1178
|
+
name: "afterCoinDeploy",
|
|
1179
|
+
outputs: [{ name: "", internalType: "bytes", type: "bytes" }],
|
|
1180
|
+
stateMutability: "payable"
|
|
1181
|
+
},
|
|
1182
|
+
{
|
|
1183
|
+
type: "function",
|
|
1184
|
+
inputs: [],
|
|
1185
|
+
name: "factory",
|
|
1186
|
+
outputs: [
|
|
1187
|
+
{ name: "", internalType: "contract IZoraFactory", type: "address" }
|
|
1188
|
+
],
|
|
1189
|
+
stateMutability: "view"
|
|
1190
|
+
},
|
|
1191
|
+
{
|
|
1192
|
+
type: "function",
|
|
1193
|
+
inputs: [{ name: "interfaceId", internalType: "bytes4", type: "bytes4" }],
|
|
1194
|
+
name: "supportsInterface",
|
|
1195
|
+
outputs: [{ name: "", internalType: "bool", type: "bool" }],
|
|
1196
|
+
stateMutability: "pure"
|
|
1197
|
+
},
|
|
1198
|
+
{
|
|
1199
|
+
type: "function",
|
|
1200
|
+
inputs: [{ name: "data", internalType: "bytes", type: "bytes" }],
|
|
1201
|
+
name: "unlockCallback",
|
|
1202
|
+
outputs: [{ name: "", internalType: "bytes", type: "bytes" }],
|
|
1203
|
+
stateMutability: "nonpayable"
|
|
1204
|
+
},
|
|
1205
|
+
{
|
|
1206
|
+
type: "error",
|
|
1207
|
+
inputs: [{ name: "target", internalType: "address", type: "address" }],
|
|
1208
|
+
name: "AddressEmptyCode"
|
|
1209
|
+
},
|
|
1210
|
+
{
|
|
1211
|
+
type: "error",
|
|
1212
|
+
inputs: [{ name: "account", internalType: "address", type: "address" }],
|
|
1213
|
+
name: "AddressInsufficientBalance"
|
|
1214
|
+
},
|
|
1215
|
+
{ type: "error", inputs: [], name: "AddressZero" },
|
|
1216
|
+
{
|
|
1217
|
+
type: "error",
|
|
1218
|
+
inputs: [{ name: "balance", internalType: "uint256", type: "uint256" }],
|
|
1219
|
+
name: "CoinBalanceNot0"
|
|
1220
|
+
},
|
|
1221
|
+
{
|
|
1222
|
+
type: "error",
|
|
1223
|
+
inputs: [{ name: "balance", internalType: "uint256", type: "uint256" }],
|
|
1224
|
+
name: "CurrencyBalanceNot0"
|
|
1225
|
+
},
|
|
1226
|
+
{ type: "error", inputs: [], name: "Erc20NotReceived" },
|
|
1227
|
+
{ type: "error", inputs: [], name: "FailedInnerCall" },
|
|
1228
|
+
{ type: "error", inputs: [], name: "HookNotImplemented" },
|
|
1229
|
+
{ type: "error", inputs: [], name: "InvalidSwapRouterCall" },
|
|
1230
|
+
{ type: "error", inputs: [], name: "NotFactory" },
|
|
1231
|
+
{ type: "error", inputs: [], name: "OnlyPoolManager" },
|
|
1236
1232
|
{
|
|
1237
1233
|
type: "error",
|
|
1238
1234
|
inputs: [{ name: "token", internalType: "address", type: "address" }],
|
|
1239
1235
|
name: "SafeERC20FailedOperation"
|
|
1240
1236
|
},
|
|
1241
|
-
{
|
|
1242
|
-
|
|
1237
|
+
{
|
|
1238
|
+
type: "error",
|
|
1239
|
+
inputs: [{ name: "error", internalType: "bytes", type: "bytes" }],
|
|
1240
|
+
name: "SwapReverted"
|
|
1241
|
+
}
|
|
1243
1242
|
];
|
|
1244
|
-
var
|
|
1243
|
+
var contentCoinABI = [
|
|
1245
1244
|
{
|
|
1246
1245
|
type: "constructor",
|
|
1247
1246
|
inputs: [
|
|
@@ -4166,7 +4165,6 @@ var zoraFactoryImplABI = [
|
|
|
4166
4165
|
{
|
|
4167
4166
|
type: "constructor",
|
|
4168
4167
|
inputs: [
|
|
4169
|
-
{ name: "_coinImpl", internalType: "address", type: "address" },
|
|
4170
4168
|
{ name: "_coinV4Impl", internalType: "address", type: "address" },
|
|
4171
4169
|
{ name: "_creatorCoinImpl", internalType: "address", type: "address" },
|
|
4172
4170
|
{ name: "_contentCoinHook", internalType: "address", type: "address" },
|
|
@@ -4181,6 +4179,13 @@ var zoraFactoryImplABI = [
|
|
|
4181
4179
|
outputs: [{ name: "", internalType: "string", type: "string" }],
|
|
4182
4180
|
stateMutability: "view"
|
|
4183
4181
|
},
|
|
4182
|
+
{
|
|
4183
|
+
type: "function",
|
|
4184
|
+
inputs: [],
|
|
4185
|
+
name: "acceptOwnership",
|
|
4186
|
+
outputs: [],
|
|
4187
|
+
stateMutability: "nonpayable"
|
|
4188
|
+
},
|
|
4184
4189
|
{
|
|
4185
4190
|
type: "function",
|
|
4186
4191
|
inputs: [
|
|
@@ -4195,13 +4200,6 @@ var zoraFactoryImplABI = [
|
|
|
4195
4200
|
outputs: [{ name: "", internalType: "address", type: "address" }],
|
|
4196
4201
|
stateMutability: "view"
|
|
4197
4202
|
},
|
|
4198
|
-
{
|
|
4199
|
-
type: "function",
|
|
4200
|
-
inputs: [],
|
|
4201
|
-
name: "coinImpl",
|
|
4202
|
-
outputs: [{ name: "", internalType: "address", type: "address" }],
|
|
4203
|
-
stateMutability: "view"
|
|
4204
|
-
},
|
|
4205
4203
|
{
|
|
4206
4204
|
type: "function",
|
|
4207
4205
|
inputs: [],
|
|
@@ -4295,7 +4293,7 @@ var zoraFactoryImplABI = [
|
|
|
4295
4293
|
{ name: "symbol", internalType: "string", type: "string" },
|
|
4296
4294
|
{ name: "poolConfig", internalType: "bytes", type: "bytes" },
|
|
4297
4295
|
{ name: "platformReferrer", internalType: "address", type: "address" },
|
|
4298
|
-
{ name: "
|
|
4296
|
+
{ name: "", internalType: "uint256", type: "uint256" }
|
|
4299
4297
|
],
|
|
4300
4298
|
name: "deploy",
|
|
4301
4299
|
outputs: [
|
|
@@ -4370,6 +4368,13 @@ var zoraFactoryImplABI = [
|
|
|
4370
4368
|
outputs: [{ name: "", internalType: "address", type: "address" }],
|
|
4371
4369
|
stateMutability: "view"
|
|
4372
4370
|
},
|
|
4371
|
+
{
|
|
4372
|
+
type: "function",
|
|
4373
|
+
inputs: [],
|
|
4374
|
+
name: "pendingOwner",
|
|
4375
|
+
outputs: [{ name: "", internalType: "address", type: "address" }],
|
|
4376
|
+
stateMutability: "view"
|
|
4377
|
+
},
|
|
4373
4378
|
{
|
|
4374
4379
|
type: "function",
|
|
4375
4380
|
inputs: [],
|
|
@@ -4611,6 +4616,25 @@ var zoraFactoryImplABI = [
|
|
|
4611
4616
|
],
|
|
4612
4617
|
name: "Initialized"
|
|
4613
4618
|
},
|
|
4619
|
+
{
|
|
4620
|
+
type: "event",
|
|
4621
|
+
anonymous: false,
|
|
4622
|
+
inputs: [
|
|
4623
|
+
{
|
|
4624
|
+
name: "previousOwner",
|
|
4625
|
+
internalType: "address",
|
|
4626
|
+
type: "address",
|
|
4627
|
+
indexed: true
|
|
4628
|
+
},
|
|
4629
|
+
{
|
|
4630
|
+
name: "newOwner",
|
|
4631
|
+
internalType: "address",
|
|
4632
|
+
type: "address",
|
|
4633
|
+
indexed: true
|
|
4634
|
+
}
|
|
4635
|
+
],
|
|
4636
|
+
name: "OwnershipTransferStarted"
|
|
4637
|
+
},
|
|
4614
4638
|
{
|
|
4615
4639
|
type: "event",
|
|
4616
4640
|
anonymous: false,
|
|
@@ -4648,13 +4672,7 @@ var zoraFactoryImplABI = [
|
|
|
4648
4672
|
inputs: [{ name: "target", internalType: "address", type: "address" }],
|
|
4649
4673
|
name: "AddressEmptyCode"
|
|
4650
4674
|
},
|
|
4651
|
-
{
|
|
4652
|
-
type: "error",
|
|
4653
|
-
inputs: [{ name: "account", internalType: "address", type: "address" }],
|
|
4654
|
-
name: "AddressInsufficientBalance"
|
|
4655
|
-
},
|
|
4656
4675
|
{ type: "error", inputs: [], name: "ArrayLengthMismatch" },
|
|
4657
|
-
{ type: "error", inputs: [], name: "CannotMintZeroLiquidity" },
|
|
4658
4676
|
{ type: "error", inputs: [], name: "ConfigTickLowerMustBeLessThanTickUpper" },
|
|
4659
4677
|
{ type: "error", inputs: [], name: "Deprecated" },
|
|
4660
4678
|
{ type: "error", inputs: [], name: "ERC1167FailedCreateClone" },
|
|
@@ -4666,7 +4684,6 @@ var zoraFactoryImplABI = [
|
|
|
4666
4684
|
name: "ERC1967InvalidImplementation"
|
|
4667
4685
|
},
|
|
4668
4686
|
{ type: "error", inputs: [], name: "ERC1967NonPayable" },
|
|
4669
|
-
{ type: "error", inputs: [], name: "ERC20TransferAmountMismatch" },
|
|
4670
4687
|
{ type: "error", inputs: [], name: "EthTransferInvalid" },
|
|
4671
4688
|
{ type: "error", inputs: [], name: "FailedInnerCall" },
|
|
4672
4689
|
{ type: "error", inputs: [], name: "InvalidConfig" },
|
|
@@ -4681,14 +4698,6 @@ var zoraFactoryImplABI = [
|
|
|
4681
4698
|
],
|
|
4682
4699
|
name: "InvalidTickRangeMisordered"
|
|
4683
4700
|
},
|
|
4684
|
-
{
|
|
4685
|
-
type: "error",
|
|
4686
|
-
inputs: [
|
|
4687
|
-
{ name: "tickLower", internalType: "int24", type: "int24" },
|
|
4688
|
-
{ name: "tickUpper", internalType: "int24", type: "int24" }
|
|
4689
|
-
],
|
|
4690
|
-
name: "InvalidTickRangeMisordered"
|
|
4691
|
-
},
|
|
4692
4701
|
{
|
|
4693
4702
|
type: "error",
|
|
4694
4703
|
inputs: [
|
|
@@ -4710,11 +4719,6 @@ var zoraFactoryImplABI = [
|
|
|
4710
4719
|
name: "OwnableUnauthorizedAccount"
|
|
4711
4720
|
},
|
|
4712
4721
|
{ type: "error", inputs: [], name: "ReentrancyGuardReentrantCall" },
|
|
4713
|
-
{
|
|
4714
|
-
type: "error",
|
|
4715
|
-
inputs: [{ name: "token", internalType: "address", type: "address" }],
|
|
4716
|
-
name: "SafeERC20FailedOperation"
|
|
4717
|
-
},
|
|
4718
4722
|
{ type: "error", inputs: [], name: "UUPSUnauthorizedCallContext" },
|
|
4719
4723
|
{
|
|
4720
4724
|
type: "error",
|
|
@@ -4734,9 +4738,9 @@ var zoraFactoryImplABI = [
|
|
|
4734
4738
|
];
|
|
4735
4739
|
export {
|
|
4736
4740
|
autoSwapperABI,
|
|
4741
|
+
baseCoinABI,
|
|
4737
4742
|
buySupplyWithSwapRouterHookABI,
|
|
4738
|
-
|
|
4739
|
-
coinV4ABI,
|
|
4743
|
+
contentCoinABI,
|
|
4740
4744
|
creatorCoinABI,
|
|
4741
4745
|
iPermit2ABI,
|
|
4742
4746
|
iPoolConfigEncodingABI,
|