@zoralabs/coins 2.1.2 → 2.3.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$colon$js.log +152 -0
- package/CHANGELOG.md +93 -0
- package/README.md +4 -0
- package/abis/BaseCoin.json +26 -5
- package/abis/BaseTest.json +2 -7
- package/abis/ContentCoin.json +26 -5
- package/abis/CreatorCoin.json +30 -9
- package/abis/FeeEstimatorHook.json +94 -6
- package/abis/ICoin.json +26 -0
- package/abis/ICoinV3.json +26 -0
- package/abis/ICreatorCoin.json +39 -0
- package/abis/IERC721.json +36 -36
- package/abis/IHasCoinType.json +15 -0
- package/abis/IHasTotalSupplyForPositions.json +15 -0
- package/abis/{LiquidityMigrationReceiver.json → IUpgradeableDestinationV4HookWithUpdateableFee.json} +10 -18
- package/abis/IZoraFactory.json +121 -0
- package/abis/IZoraHookRegistry.json +188 -0
- package/abis/VmContractHelper226.json +233 -0
- package/abis/ZoraFactoryImpl.json +101 -6
- package/abis/ZoraHookRegistry.json +375 -0
- package/abis/{CreatorCoinHook.json → ZoraV4CoinHook.json} +95 -2
- package/addresses/8453.json +6 -5
- package/audits/report-cantinacode-zora-0827.pdf +3498 -4
- package/dist/index.cjs +93 -13
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +93 -13
- package/dist/index.js.map +1 -1
- package/dist/wagmiGenerated.d.ts +144 -22
- package/dist/wagmiGenerated.d.ts.map +1 -1
- package/foundry.toml +4 -1
- package/package/wagmiGenerated.ts +93 -13
- package/package.json +6 -4
- package/script/PrintRegisterUpgradePath.s.sol +0 -7
- package/script/TestBackingCoinSwap.s.sol +0 -3
- package/script/TestV4Swap.s.sol +0 -3
- package/script/UpgradeFactoryImpl.s.sol +1 -1
- package/src/BaseCoin.sol +19 -24
- package/src/ContentCoin.sol +11 -2
- package/src/CreatorCoin.sol +34 -15
- package/src/ZoraFactoryImpl.sol +163 -92
- package/src/deployment/CoinsDeployerBase.sol +24 -58
- package/src/hook-registry/ZoraHookRegistry.sol +97 -0
- package/src/hooks/{BaseZoraV4CoinHook.sol → ZoraV4CoinHook.sol} +77 -15
- package/src/interfaces/ICoin.sol +19 -1
- package/src/interfaces/ICreatorCoin.sol +4 -0
- package/src/interfaces/IUpgradeableV4Hook.sol +18 -0
- package/src/interfaces/IZoraFactory.sol +51 -10
- package/src/interfaces/IZoraHookRegistry.sol +47 -0
- package/src/libs/CoinConstants.sol +43 -32
- package/src/libs/CoinDopplerMultiCurve.sol +11 -11
- package/src/libs/CoinRewardsV4.sol +68 -37
- package/src/libs/CoinSetup.sol +2 -9
- package/src/libs/DopplerMath.sol +2 -2
- package/src/libs/HooksDeployment.sol +13 -65
- package/src/libs/V4Liquidity.sol +109 -15
- package/src/version/ContractVersionBase.sol +1 -1
- package/test/Coin.t.sol +5 -5
- package/test/CoinRewardsV4.t.sol +33 -0
- package/test/CoinUniV4.t.sol +32 -30
- package/test/ContentCoinRewards.t.sol +363 -0
- package/test/CreatorCoin.t.sol +53 -29
- package/test/CreatorCoinRewards.t.sol +375 -0
- package/test/DeploymentHooks.t.sol +64 -12
- package/test/Factory.t.sol +24 -7
- package/test/HooksDeployment.t.sol +4 -4
- package/test/LiquidityMigration.t.sol +149 -16
- package/test/Upgrades.t.sol +44 -48
- package/test/V4Liquidity.t.sol +178 -0
- package/test/ZoraHookRegistry.t.sol +266 -0
- package/test/utils/BaseTest.sol +25 -43
- package/test/utils/FeeEstimatorHook.sol +4 -6
- package/test/utils/RewardTestHelpers.sol +106 -0
- package/.turbo/turbo-build.log +0 -199
- package/abis/AutoSwapperTest.json +0 -618
- package/abis/BadImpl.json +0 -15
- package/abis/BaseZoraV4CoinHook.json +0 -1664
- package/abis/CoinConstants.json +0 -158
- package/abis/CoinRewardsV4.json +0 -67
- package/abis/CoinTest.json +0 -819
- package/abis/CoinUniV4Test.json +0 -1128
- package/abis/ContentCoinHook.json +0 -1733
- package/abis/CreatorCoinTest.json +0 -887
- package/abis/Deploy.json +0 -9
- package/abis/DeployHooks.json +0 -9
- package/abis/DeployScript.json +0 -35
- package/abis/DeployedCoinVersionLookupTest.json +0 -740
- package/abis/DifferentNamespaceVersionLookup.json +0 -39
- package/abis/FactoryTest.json +0 -748
- package/abis/FakeHookNoInterface.json +0 -21
- package/abis/GenerateDeterministicParams.json +0 -9
- package/abis/HooksDeploymentTest.json +0 -645
- package/abis/HooksTest.json +0 -709
- package/abis/InvalidLiquidityMigrationReceiver.json +0 -21
- package/abis/LiquidityMigrationTest.json +0 -889
- package/abis/MockBadFactory.json +0 -15
- package/abis/MultiOwnableTest.json +0 -766
- package/abis/PrintUpgradeCommand.json +0 -9
- package/abis/TestDeployedCoinVersionLookupImplementation.json +0 -39
- package/abis/TestV4Swap.json +0 -9
- package/abis/UpgradeFactoryImpl.json +0 -9
- package/abis/UpgradeHooks.json +0 -35
- package/abis/UpgradesTest.json +0 -723
- package/src/hooks/ContentCoinHook.sol +0 -27
- package/src/hooks/CreatorCoinHook.sol +0 -27
- package/src/libs/CreatorCoinConstants.sol +0 -16
- package/src/libs/CreatorCoinRewards.sol +0 -34
- package/src/libs/MarketConstants.sol +0 -15
package/dist/wagmiGenerated.d.ts
CHANGED
|
@@ -223,6 +223,16 @@ export declare const baseCoinABI: readonly [{
|
|
|
223
223
|
readonly name: "burn";
|
|
224
224
|
readonly outputs: readonly [];
|
|
225
225
|
readonly stateMutability: "nonpayable";
|
|
226
|
+
}, {
|
|
227
|
+
readonly type: "function";
|
|
228
|
+
readonly inputs: readonly [];
|
|
229
|
+
readonly name: "coinType";
|
|
230
|
+
readonly outputs: readonly [{
|
|
231
|
+
readonly name: "";
|
|
232
|
+
readonly internalType: "enum IHasCoinType.CoinType";
|
|
233
|
+
readonly type: "uint8";
|
|
234
|
+
}];
|
|
235
|
+
readonly stateMutability: "view";
|
|
226
236
|
}, {
|
|
227
237
|
readonly type: "function";
|
|
228
238
|
readonly inputs: readonly [];
|
|
@@ -810,6 +820,16 @@ export declare const baseCoinABI: readonly [{
|
|
|
810
820
|
readonly type: "uint256";
|
|
811
821
|
}];
|
|
812
822
|
readonly stateMutability: "view";
|
|
823
|
+
}, {
|
|
824
|
+
readonly type: "function";
|
|
825
|
+
readonly inputs: readonly [];
|
|
826
|
+
readonly name: "totalSupplyForPositions";
|
|
827
|
+
readonly outputs: readonly [{
|
|
828
|
+
readonly name: "";
|
|
829
|
+
readonly internalType: "uint256";
|
|
830
|
+
readonly type: "uint256";
|
|
831
|
+
}];
|
|
832
|
+
readonly stateMutability: "view";
|
|
813
833
|
}, {
|
|
814
834
|
readonly type: "function";
|
|
815
835
|
readonly inputs: readonly [{
|
|
@@ -1544,10 +1564,6 @@ export declare const baseCoinABI: readonly [{
|
|
|
1544
1564
|
readonly type: "error";
|
|
1545
1565
|
readonly inputs: readonly [];
|
|
1546
1566
|
readonly name: "OwnerCannotBeAddressZero";
|
|
1547
|
-
}, {
|
|
1548
|
-
readonly type: "error";
|
|
1549
|
-
readonly inputs: readonly [];
|
|
1550
|
-
readonly name: "ReentrancyGuardReentrantCall";
|
|
1551
1567
|
}, {
|
|
1552
1568
|
readonly type: "error";
|
|
1553
1569
|
readonly inputs: readonly [];
|
|
@@ -1830,6 +1846,16 @@ export declare const contentCoinABI: readonly [{
|
|
|
1830
1846
|
readonly name: "burn";
|
|
1831
1847
|
readonly outputs: readonly [];
|
|
1832
1848
|
readonly stateMutability: "nonpayable";
|
|
1849
|
+
}, {
|
|
1850
|
+
readonly type: "function";
|
|
1851
|
+
readonly inputs: readonly [];
|
|
1852
|
+
readonly name: "coinType";
|
|
1853
|
+
readonly outputs: readonly [{
|
|
1854
|
+
readonly name: "";
|
|
1855
|
+
readonly internalType: "enum IHasCoinType.CoinType";
|
|
1856
|
+
readonly type: "uint8";
|
|
1857
|
+
}];
|
|
1858
|
+
readonly stateMutability: "pure";
|
|
1833
1859
|
}, {
|
|
1834
1860
|
readonly type: "function";
|
|
1835
1861
|
readonly inputs: readonly [];
|
|
@@ -2417,6 +2443,16 @@ export declare const contentCoinABI: readonly [{
|
|
|
2417
2443
|
readonly type: "uint256";
|
|
2418
2444
|
}];
|
|
2419
2445
|
readonly stateMutability: "view";
|
|
2446
|
+
}, {
|
|
2447
|
+
readonly type: "function";
|
|
2448
|
+
readonly inputs: readonly [];
|
|
2449
|
+
readonly name: "totalSupplyForPositions";
|
|
2450
|
+
readonly outputs: readonly [{
|
|
2451
|
+
readonly name: "";
|
|
2452
|
+
readonly internalType: "uint256";
|
|
2453
|
+
readonly type: "uint256";
|
|
2454
|
+
}];
|
|
2455
|
+
readonly stateMutability: "pure";
|
|
2420
2456
|
}, {
|
|
2421
2457
|
readonly type: "function";
|
|
2422
2458
|
readonly inputs: readonly [{
|
|
@@ -3151,10 +3187,6 @@ export declare const contentCoinABI: readonly [{
|
|
|
3151
3187
|
readonly type: "error";
|
|
3152
3188
|
readonly inputs: readonly [];
|
|
3153
3189
|
readonly name: "OwnerCannotBeAddressZero";
|
|
3154
|
-
}, {
|
|
3155
|
-
readonly type: "error";
|
|
3156
|
-
readonly inputs: readonly [];
|
|
3157
|
-
readonly name: "ReentrancyGuardReentrantCall";
|
|
3158
3190
|
}, {
|
|
3159
3191
|
readonly type: "error";
|
|
3160
3192
|
readonly inputs: readonly [];
|
|
@@ -3167,19 +3199,19 @@ export declare const contentCoinABI: readonly [{
|
|
|
3167
3199
|
export declare const creatorCoinABI: readonly [{
|
|
3168
3200
|
readonly type: "constructor";
|
|
3169
3201
|
readonly inputs: readonly [{
|
|
3170
|
-
readonly name: "
|
|
3202
|
+
readonly name: "protocolRewardRecipient_";
|
|
3171
3203
|
readonly internalType: "address";
|
|
3172
3204
|
readonly type: "address";
|
|
3173
3205
|
}, {
|
|
3174
|
-
readonly name: "
|
|
3206
|
+
readonly name: "protocolRewards_";
|
|
3175
3207
|
readonly internalType: "address";
|
|
3176
3208
|
readonly type: "address";
|
|
3177
3209
|
}, {
|
|
3178
|
-
readonly name: "
|
|
3210
|
+
readonly name: "poolManager_";
|
|
3179
3211
|
readonly internalType: "contract IPoolManager";
|
|
3180
3212
|
readonly type: "address";
|
|
3181
3213
|
}, {
|
|
3182
|
-
readonly name: "
|
|
3214
|
+
readonly name: "airlock_";
|
|
3183
3215
|
readonly internalType: "address";
|
|
3184
3216
|
readonly type: "address";
|
|
3185
3217
|
}];
|
|
@@ -3294,6 +3326,16 @@ export declare const creatorCoinABI: readonly [{
|
|
|
3294
3326
|
readonly type: "uint256";
|
|
3295
3327
|
}];
|
|
3296
3328
|
readonly stateMutability: "nonpayable";
|
|
3329
|
+
}, {
|
|
3330
|
+
readonly type: "function";
|
|
3331
|
+
readonly inputs: readonly [];
|
|
3332
|
+
readonly name: "coinType";
|
|
3333
|
+
readonly outputs: readonly [{
|
|
3334
|
+
readonly name: "";
|
|
3335
|
+
readonly internalType: "enum IHasCoinType.CoinType";
|
|
3336
|
+
readonly type: "uint8";
|
|
3337
|
+
}];
|
|
3338
|
+
readonly stateMutability: "pure";
|
|
3297
3339
|
}, {
|
|
3298
3340
|
readonly type: "function";
|
|
3299
3341
|
readonly inputs: readonly [];
|
|
@@ -3901,6 +3943,16 @@ export declare const creatorCoinABI: readonly [{
|
|
|
3901
3943
|
readonly type: "uint256";
|
|
3902
3944
|
}];
|
|
3903
3945
|
readonly stateMutability: "view";
|
|
3946
|
+
}, {
|
|
3947
|
+
readonly type: "function";
|
|
3948
|
+
readonly inputs: readonly [];
|
|
3949
|
+
readonly name: "totalSupplyForPositions";
|
|
3950
|
+
readonly outputs: readonly [{
|
|
3951
|
+
readonly name: "";
|
|
3952
|
+
readonly internalType: "uint256";
|
|
3953
|
+
readonly type: "uint256";
|
|
3954
|
+
}];
|
|
3955
|
+
readonly stateMutability: "pure";
|
|
3904
3956
|
}, {
|
|
3905
3957
|
readonly type: "function";
|
|
3906
3958
|
readonly inputs: readonly [{
|
|
@@ -4689,10 +4741,6 @@ export declare const creatorCoinABI: readonly [{
|
|
|
4689
4741
|
readonly type: "error";
|
|
4690
4742
|
readonly inputs: readonly [];
|
|
4691
4743
|
readonly name: "OwnerCannotBeAddressZero";
|
|
4692
|
-
}, {
|
|
4693
|
-
readonly type: "error";
|
|
4694
|
-
readonly inputs: readonly [];
|
|
4695
|
-
readonly name: "ReentrancyGuardReentrantCall";
|
|
4696
4744
|
}, {
|
|
4697
4745
|
readonly type: "error";
|
|
4698
4746
|
readonly inputs: readonly [];
|
|
@@ -5677,19 +5725,19 @@ export declare const iUniversalRouterABI: readonly [{
|
|
|
5677
5725
|
export declare const zoraFactoryImplABI: readonly [{
|
|
5678
5726
|
readonly type: "constructor";
|
|
5679
5727
|
readonly inputs: readonly [{
|
|
5680
|
-
readonly name: "
|
|
5728
|
+
readonly name: "coinV4Impl_";
|
|
5681
5729
|
readonly internalType: "address";
|
|
5682
5730
|
readonly type: "address";
|
|
5683
5731
|
}, {
|
|
5684
|
-
readonly name: "
|
|
5732
|
+
readonly name: "creatorCoinImpl_";
|
|
5685
5733
|
readonly internalType: "address";
|
|
5686
5734
|
readonly type: "address";
|
|
5687
5735
|
}, {
|
|
5688
|
-
readonly name: "
|
|
5736
|
+
readonly name: "hook_";
|
|
5689
5737
|
readonly internalType: "address";
|
|
5690
5738
|
readonly type: "address";
|
|
5691
5739
|
}, {
|
|
5692
|
-
readonly name: "
|
|
5740
|
+
readonly name: "zoraHookRegistry_";
|
|
5693
5741
|
readonly internalType: "address";
|
|
5694
5742
|
readonly type: "address";
|
|
5695
5743
|
}];
|
|
@@ -5839,7 +5887,7 @@ export declare const zoraFactoryImplABI: readonly [{
|
|
|
5839
5887
|
readonly internalType: "int24";
|
|
5840
5888
|
readonly type: "int24";
|
|
5841
5889
|
}, {
|
|
5842
|
-
readonly name: "
|
|
5890
|
+
readonly name: "";
|
|
5843
5891
|
readonly internalType: "uint256";
|
|
5844
5892
|
readonly type: "uint256";
|
|
5845
5893
|
}];
|
|
@@ -6027,7 +6075,61 @@ export declare const zoraFactoryImplABI: readonly [{
|
|
|
6027
6075
|
readonly internalType: "address";
|
|
6028
6076
|
readonly type: "address";
|
|
6029
6077
|
}, {
|
|
6030
|
-
readonly name: "
|
|
6078
|
+
readonly name: "postDeployHook";
|
|
6079
|
+
readonly internalType: "address";
|
|
6080
|
+
readonly type: "address";
|
|
6081
|
+
}, {
|
|
6082
|
+
readonly name: "postDeployHookData";
|
|
6083
|
+
readonly internalType: "bytes";
|
|
6084
|
+
readonly type: "bytes";
|
|
6085
|
+
}, {
|
|
6086
|
+
readonly name: "coinSalt";
|
|
6087
|
+
readonly internalType: "bytes32";
|
|
6088
|
+
readonly type: "bytes32";
|
|
6089
|
+
}];
|
|
6090
|
+
readonly name: "deployCreatorCoin";
|
|
6091
|
+
readonly outputs: readonly [{
|
|
6092
|
+
readonly name: "coin";
|
|
6093
|
+
readonly internalType: "address";
|
|
6094
|
+
readonly type: "address";
|
|
6095
|
+
}, {
|
|
6096
|
+
readonly name: "postDeployHookDataOut";
|
|
6097
|
+
readonly internalType: "bytes";
|
|
6098
|
+
readonly type: "bytes";
|
|
6099
|
+
}];
|
|
6100
|
+
readonly stateMutability: "payable";
|
|
6101
|
+
}, {
|
|
6102
|
+
readonly type: "function";
|
|
6103
|
+
readonly inputs: readonly [{
|
|
6104
|
+
readonly name: "payoutRecipient";
|
|
6105
|
+
readonly internalType: "address";
|
|
6106
|
+
readonly type: "address";
|
|
6107
|
+
}, {
|
|
6108
|
+
readonly name: "owners";
|
|
6109
|
+
readonly internalType: "address[]";
|
|
6110
|
+
readonly type: "address[]";
|
|
6111
|
+
}, {
|
|
6112
|
+
readonly name: "uri";
|
|
6113
|
+
readonly internalType: "string";
|
|
6114
|
+
readonly type: "string";
|
|
6115
|
+
}, {
|
|
6116
|
+
readonly name: "name";
|
|
6117
|
+
readonly internalType: "string";
|
|
6118
|
+
readonly type: "string";
|
|
6119
|
+
}, {
|
|
6120
|
+
readonly name: "symbol";
|
|
6121
|
+
readonly internalType: "string";
|
|
6122
|
+
readonly type: "string";
|
|
6123
|
+
}, {
|
|
6124
|
+
readonly name: "poolConfig";
|
|
6125
|
+
readonly internalType: "bytes";
|
|
6126
|
+
readonly type: "bytes";
|
|
6127
|
+
}, {
|
|
6128
|
+
readonly name: "platformReferrer";
|
|
6129
|
+
readonly internalType: "address";
|
|
6130
|
+
readonly type: "address";
|
|
6131
|
+
}, {
|
|
6132
|
+
readonly name: "deployHook";
|
|
6031
6133
|
readonly internalType: "address";
|
|
6032
6134
|
readonly type: "address";
|
|
6033
6135
|
}, {
|
|
@@ -6060,6 +6162,16 @@ export declare const zoraFactoryImplABI: readonly [{
|
|
|
6060
6162
|
readonly type: "uint8";
|
|
6061
6163
|
}];
|
|
6062
6164
|
readonly stateMutability: "view";
|
|
6165
|
+
}, {
|
|
6166
|
+
readonly type: "function";
|
|
6167
|
+
readonly inputs: readonly [];
|
|
6168
|
+
readonly name: "hook";
|
|
6169
|
+
readonly outputs: readonly [{
|
|
6170
|
+
readonly name: "";
|
|
6171
|
+
readonly internalType: "address";
|
|
6172
|
+
readonly type: "address";
|
|
6173
|
+
}];
|
|
6174
|
+
readonly stateMutability: "view";
|
|
6063
6175
|
}, {
|
|
6064
6176
|
readonly type: "function";
|
|
6065
6177
|
readonly inputs: readonly [];
|
|
@@ -6140,6 +6252,16 @@ export declare const zoraFactoryImplABI: readonly [{
|
|
|
6140
6252
|
readonly name: "upgradeToAndCall";
|
|
6141
6253
|
readonly outputs: readonly [];
|
|
6142
6254
|
readonly stateMutability: "payable";
|
|
6255
|
+
}, {
|
|
6256
|
+
readonly type: "function";
|
|
6257
|
+
readonly inputs: readonly [];
|
|
6258
|
+
readonly name: "zoraHookRegistry";
|
|
6259
|
+
readonly outputs: readonly [{
|
|
6260
|
+
readonly name: "";
|
|
6261
|
+
readonly internalType: "address";
|
|
6262
|
+
readonly type: "address";
|
|
6263
|
+
}];
|
|
6264
|
+
readonly stateMutability: "view";
|
|
6143
6265
|
}, {
|
|
6144
6266
|
readonly type: "event";
|
|
6145
6267
|
readonly anonymous: false;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"wagmiGenerated.d.ts","sourceRoot":"","sources":["../package/wagmiGenerated.ts"],"names":[],"mappings":"AAIA,eAAO,MAAM,cAAc;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EA2FjB,CAAA;AAMV,eAAO,MAAM,WAAW
|
|
1
|
+
{"version":3,"file":"wagmiGenerated.d.ts","sourceRoot":"","sources":["../package/wagmiGenerated.ts"],"names":[],"mappings":"AAIA,eAAO,MAAM,cAAc;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EA2FjB,CAAA;AAMV,eAAO,MAAM,WAAW;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAimBrB,CAAA"}
|
package/foundry.toml
CHANGED
|
@@ -6,6 +6,7 @@ via_ir = true
|
|
|
6
6
|
optimizer = true
|
|
7
7
|
solc_version = '0.8.28'
|
|
8
8
|
optimizer_runs = 200
|
|
9
|
+
dynamic_test_linking = true
|
|
9
10
|
fs_permissions = [
|
|
10
11
|
{ access = "readwrite", path = "./addresses" },
|
|
11
12
|
{ access = "readwrite", path = "./addresses/dev" },
|
|
@@ -19,4 +20,6 @@ fs_permissions = [
|
|
|
19
20
|
runs = 100
|
|
20
21
|
|
|
21
22
|
[rpc_endpoints]
|
|
22
|
-
base = "https://base.gateway.tenderly.co/${TENDERLY_KEY}"
|
|
23
|
+
base = "https://base.gateway.tenderly.co/${TENDERLY_KEY}"
|
|
24
|
+
mainnet = "https://mainnet.gateway.tenderly.co/${TENDERLY_KEY}"
|
|
25
|
+
zora = "https://rpc.zora.energy/${CONDUIT_KEY}"
|
|
@@ -164,6 +164,15 @@ export const baseCoinABI = [
|
|
|
164
164
|
outputs: [],
|
|
165
165
|
stateMutability: 'nonpayable',
|
|
166
166
|
},
|
|
167
|
+
{
|
|
168
|
+
type: 'function',
|
|
169
|
+
inputs: [],
|
|
170
|
+
name: 'coinType',
|
|
171
|
+
outputs: [
|
|
172
|
+
{ name: '', internalType: 'enum IHasCoinType.CoinType', type: 'uint8' },
|
|
173
|
+
],
|
|
174
|
+
stateMutability: 'view',
|
|
175
|
+
},
|
|
167
176
|
{
|
|
168
177
|
type: 'function',
|
|
169
178
|
inputs: [],
|
|
@@ -545,6 +554,13 @@ export const baseCoinABI = [
|
|
|
545
554
|
outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }],
|
|
546
555
|
stateMutability: 'view',
|
|
547
556
|
},
|
|
557
|
+
{
|
|
558
|
+
type: 'function',
|
|
559
|
+
inputs: [],
|
|
560
|
+
name: 'totalSupplyForPositions',
|
|
561
|
+
outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }],
|
|
562
|
+
stateMutability: 'view',
|
|
563
|
+
},
|
|
548
564
|
{
|
|
549
565
|
type: 'function',
|
|
550
566
|
inputs: [
|
|
@@ -1158,7 +1174,6 @@ export const baseCoinABI = [
|
|
|
1158
1174
|
},
|
|
1159
1175
|
{ type: 'error', inputs: [], name: 'OnlyWeth' },
|
|
1160
1176
|
{ type: 'error', inputs: [], name: 'OwnerCannotBeAddressZero' },
|
|
1161
|
-
{ type: 'error', inputs: [], name: 'ReentrancyGuardReentrantCall' },
|
|
1162
1177
|
{ type: 'error', inputs: [], name: 'SlippageBoundsExceeded' },
|
|
1163
1178
|
{ type: 'error', inputs: [], name: 'UseRevokeOwnershipToRemoveSelf' },
|
|
1164
1179
|
] as const
|
|
@@ -1341,6 +1356,15 @@ export const contentCoinABI = [
|
|
|
1341
1356
|
outputs: [],
|
|
1342
1357
|
stateMutability: 'nonpayable',
|
|
1343
1358
|
},
|
|
1359
|
+
{
|
|
1360
|
+
type: 'function',
|
|
1361
|
+
inputs: [],
|
|
1362
|
+
name: 'coinType',
|
|
1363
|
+
outputs: [
|
|
1364
|
+
{ name: '', internalType: 'enum IHasCoinType.CoinType', type: 'uint8' },
|
|
1365
|
+
],
|
|
1366
|
+
stateMutability: 'pure',
|
|
1367
|
+
},
|
|
1344
1368
|
{
|
|
1345
1369
|
type: 'function',
|
|
1346
1370
|
inputs: [],
|
|
@@ -1722,6 +1746,13 @@ export const contentCoinABI = [
|
|
|
1722
1746
|
outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }],
|
|
1723
1747
|
stateMutability: 'view',
|
|
1724
1748
|
},
|
|
1749
|
+
{
|
|
1750
|
+
type: 'function',
|
|
1751
|
+
inputs: [],
|
|
1752
|
+
name: 'totalSupplyForPositions',
|
|
1753
|
+
outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }],
|
|
1754
|
+
stateMutability: 'pure',
|
|
1755
|
+
},
|
|
1725
1756
|
{
|
|
1726
1757
|
type: 'function',
|
|
1727
1758
|
inputs: [
|
|
@@ -2335,7 +2366,6 @@ export const contentCoinABI = [
|
|
|
2335
2366
|
},
|
|
2336
2367
|
{ type: 'error', inputs: [], name: 'OnlyWeth' },
|
|
2337
2368
|
{ type: 'error', inputs: [], name: 'OwnerCannotBeAddressZero' },
|
|
2338
|
-
{ type: 'error', inputs: [], name: 'ReentrancyGuardReentrantCall' },
|
|
2339
2369
|
{ type: 'error', inputs: [], name: 'SlippageBoundsExceeded' },
|
|
2340
2370
|
{ type: 'error', inputs: [], name: 'UseRevokeOwnershipToRemoveSelf' },
|
|
2341
2371
|
] as const
|
|
@@ -2349,17 +2379,17 @@ export const creatorCoinABI = [
|
|
|
2349
2379
|
type: 'constructor',
|
|
2350
2380
|
inputs: [
|
|
2351
2381
|
{
|
|
2352
|
-
name: '
|
|
2382
|
+
name: 'protocolRewardRecipient_',
|
|
2353
2383
|
internalType: 'address',
|
|
2354
2384
|
type: 'address',
|
|
2355
2385
|
},
|
|
2356
|
-
{ name: '
|
|
2386
|
+
{ name: 'protocolRewards_', internalType: 'address', type: 'address' },
|
|
2357
2387
|
{
|
|
2358
|
-
name: '
|
|
2388
|
+
name: 'poolManager_',
|
|
2359
2389
|
internalType: 'contract IPoolManager',
|
|
2360
2390
|
type: 'address',
|
|
2361
2391
|
},
|
|
2362
|
-
{ name: '
|
|
2392
|
+
{ name: 'airlock_', internalType: 'address', type: 'address' },
|
|
2363
2393
|
],
|
|
2364
2394
|
stateMutability: 'nonpayable',
|
|
2365
2395
|
},
|
|
@@ -2434,6 +2464,15 @@ export const creatorCoinABI = [
|
|
|
2434
2464
|
outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }],
|
|
2435
2465
|
stateMutability: 'nonpayable',
|
|
2436
2466
|
},
|
|
2467
|
+
{
|
|
2468
|
+
type: 'function',
|
|
2469
|
+
inputs: [],
|
|
2470
|
+
name: 'coinType',
|
|
2471
|
+
outputs: [
|
|
2472
|
+
{ name: '', internalType: 'enum IHasCoinType.CoinType', type: 'uint8' },
|
|
2473
|
+
],
|
|
2474
|
+
stateMutability: 'pure',
|
|
2475
|
+
},
|
|
2437
2476
|
{
|
|
2438
2477
|
type: 'function',
|
|
2439
2478
|
inputs: [],
|
|
@@ -2829,6 +2868,13 @@ export const creatorCoinABI = [
|
|
|
2829
2868
|
outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }],
|
|
2830
2869
|
stateMutability: 'view',
|
|
2831
2870
|
},
|
|
2871
|
+
{
|
|
2872
|
+
type: 'function',
|
|
2873
|
+
inputs: [],
|
|
2874
|
+
name: 'totalSupplyForPositions',
|
|
2875
|
+
outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }],
|
|
2876
|
+
stateMutability: 'pure',
|
|
2877
|
+
},
|
|
2832
2878
|
{
|
|
2833
2879
|
type: 'function',
|
|
2834
2880
|
inputs: [
|
|
@@ -3494,7 +3540,6 @@ export const creatorCoinABI = [
|
|
|
3494
3540
|
},
|
|
3495
3541
|
{ type: 'error', inputs: [], name: 'OnlyWeth' },
|
|
3496
3542
|
{ type: 'error', inputs: [], name: 'OwnerCannotBeAddressZero' },
|
|
3497
|
-
{ type: 'error', inputs: [], name: 'ReentrancyGuardReentrantCall' },
|
|
3498
3543
|
{ type: 'error', inputs: [], name: 'SlippageBoundsExceeded' },
|
|
3499
3544
|
{ type: 'error', inputs: [], name: 'UseRevokeOwnershipToRemoveSelf' },
|
|
3500
3545
|
] as const
|
|
@@ -4213,10 +4258,10 @@ export const zoraFactoryImplABI = [
|
|
|
4213
4258
|
{
|
|
4214
4259
|
type: 'constructor',
|
|
4215
4260
|
inputs: [
|
|
4216
|
-
{ name: '
|
|
4217
|
-
{ name: '
|
|
4218
|
-
{ name: '
|
|
4219
|
-
{ name: '
|
|
4261
|
+
{ name: 'coinV4Impl_', internalType: 'address', type: 'address' },
|
|
4262
|
+
{ name: 'creatorCoinImpl_', internalType: 'address', type: 'address' },
|
|
4263
|
+
{ name: 'hook_', internalType: 'address', type: 'address' },
|
|
4264
|
+
{ name: 'zoraHookRegistry_', internalType: 'address', type: 'address' },
|
|
4220
4265
|
],
|
|
4221
4266
|
stateMutability: 'nonpayable',
|
|
4222
4267
|
},
|
|
@@ -4301,7 +4346,7 @@ export const zoraFactoryImplABI = [
|
|
|
4301
4346
|
{ name: 'platformReferrer', internalType: 'address', type: 'address' },
|
|
4302
4347
|
{ name: 'currency', internalType: 'address', type: 'address' },
|
|
4303
4348
|
{ name: '', internalType: 'int24', type: 'int24' },
|
|
4304
|
-
{ name: '
|
|
4349
|
+
{ name: '', internalType: 'uint256', type: 'uint256' },
|
|
4305
4350
|
],
|
|
4306
4351
|
name: 'deploy',
|
|
4307
4352
|
outputs: [
|
|
@@ -4376,7 +4421,28 @@ export const zoraFactoryImplABI = [
|
|
|
4376
4421
|
{ name: 'symbol', internalType: 'string', type: 'string' },
|
|
4377
4422
|
{ name: 'poolConfig', internalType: 'bytes', type: 'bytes' },
|
|
4378
4423
|
{ name: 'platformReferrer', internalType: 'address', type: 'address' },
|
|
4379
|
-
{ name: '
|
|
4424
|
+
{ name: 'postDeployHook', internalType: 'address', type: 'address' },
|
|
4425
|
+
{ name: 'postDeployHookData', internalType: 'bytes', type: 'bytes' },
|
|
4426
|
+
{ name: 'coinSalt', internalType: 'bytes32', type: 'bytes32' },
|
|
4427
|
+
],
|
|
4428
|
+
name: 'deployCreatorCoin',
|
|
4429
|
+
outputs: [
|
|
4430
|
+
{ name: 'coin', internalType: 'address', type: 'address' },
|
|
4431
|
+
{ name: 'postDeployHookDataOut', internalType: 'bytes', type: 'bytes' },
|
|
4432
|
+
],
|
|
4433
|
+
stateMutability: 'payable',
|
|
4434
|
+
},
|
|
4435
|
+
{
|
|
4436
|
+
type: 'function',
|
|
4437
|
+
inputs: [
|
|
4438
|
+
{ name: 'payoutRecipient', internalType: 'address', type: 'address' },
|
|
4439
|
+
{ name: 'owners', internalType: 'address[]', type: 'address[]' },
|
|
4440
|
+
{ name: 'uri', internalType: 'string', type: 'string' },
|
|
4441
|
+
{ name: 'name', internalType: 'string', type: 'string' },
|
|
4442
|
+
{ name: 'symbol', internalType: 'string', type: 'string' },
|
|
4443
|
+
{ name: 'poolConfig', internalType: 'bytes', type: 'bytes' },
|
|
4444
|
+
{ name: 'platformReferrer', internalType: 'address', type: 'address' },
|
|
4445
|
+
{ name: 'deployHook', internalType: 'address', type: 'address' },
|
|
4380
4446
|
{ name: 'hookData', internalType: 'bytes', type: 'bytes' },
|
|
4381
4447
|
],
|
|
4382
4448
|
name: 'deployWithHook',
|
|
@@ -4393,6 +4459,13 @@ export const zoraFactoryImplABI = [
|
|
|
4393
4459
|
outputs: [{ name: '', internalType: 'uint8', type: 'uint8' }],
|
|
4394
4460
|
stateMutability: 'view',
|
|
4395
4461
|
},
|
|
4462
|
+
{
|
|
4463
|
+
type: 'function',
|
|
4464
|
+
inputs: [],
|
|
4465
|
+
name: 'hook',
|
|
4466
|
+
outputs: [{ name: '', internalType: 'address', type: 'address' }],
|
|
4467
|
+
stateMutability: 'view',
|
|
4468
|
+
},
|
|
4396
4469
|
{
|
|
4397
4470
|
type: 'function',
|
|
4398
4471
|
inputs: [],
|
|
@@ -4454,6 +4527,13 @@ export const zoraFactoryImplABI = [
|
|
|
4454
4527
|
outputs: [],
|
|
4455
4528
|
stateMutability: 'payable',
|
|
4456
4529
|
},
|
|
4530
|
+
{
|
|
4531
|
+
type: 'function',
|
|
4532
|
+
inputs: [],
|
|
4533
|
+
name: 'zoraHookRegistry',
|
|
4534
|
+
outputs: [{ name: '', internalType: 'address', type: 'address' }],
|
|
4535
|
+
stateMutability: 'view',
|
|
4536
|
+
},
|
|
4457
4537
|
{
|
|
4458
4538
|
type: 'event',
|
|
4459
4539
|
anonymous: false,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@zoralabs/coins",
|
|
3
|
-
"version": "2.
|
|
3
|
+
"version": "2.3.0",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"main": "./dist/index.cjs",
|
|
6
6
|
"module": "./dist/index.js",
|
|
@@ -35,12 +35,14 @@
|
|
|
35
35
|
"tsx": "^3.13.0",
|
|
36
36
|
"typescript": "^5.2.2",
|
|
37
37
|
"viem": "^2.21.18",
|
|
38
|
-
"@zoralabs/shared-scripts": "^0.0.0",
|
|
39
38
|
"@zoralabs/shared-contracts": "^0.0.5",
|
|
39
|
+
"@zoralabs/shared-scripts": "^0.0.0",
|
|
40
40
|
"@zoralabs/tsconfig": "^0.0.1"
|
|
41
41
|
},
|
|
42
42
|
"scripts": {
|
|
43
|
-
"build": "
|
|
43
|
+
"build": "forge build",
|
|
44
|
+
"build:contracts:minimal": "forge build --skip test --skip script --no-metadata",
|
|
45
|
+
"build:js": "pnpm run wagmi:generate && pnpm run copy-abis && pnpm run prettier:write && tsup",
|
|
44
46
|
"build:sizes": "forge build src/ --sizes",
|
|
45
47
|
"copy-abis": "pnpm exec bundle-abis",
|
|
46
48
|
"coverage": "forge coverage --report lcov --ir-minimum --no-match-coverage '(test/|src/utils/uniswap/|script/)'",
|
|
@@ -49,6 +51,6 @@
|
|
|
49
51
|
"test": "forge test -vv",
|
|
50
52
|
"test-gas": "forge test --gas-report",
|
|
51
53
|
"update-contract-version": "pnpm exec update-contract-version",
|
|
52
|
-
"wagmi:generate": "
|
|
54
|
+
"wagmi:generate": "pnpm run build:contracts:minimal && wagmi generate && pnpm exec rename-generated-abi-casing ./package/wagmiGenerated.ts"
|
|
53
55
|
}
|
|
54
56
|
}
|
|
@@ -12,24 +12,17 @@ contract DeployScript is CoinsDeployerBase {
|
|
|
12
12
|
CoinsDeployment memory deployment = readDeployment(false);
|
|
13
13
|
|
|
14
14
|
address existingContentCoinHook = 0xd3D133469ADC85e01A4887404D8AC12d630e9040;
|
|
15
|
-
address existingCreatorCoinHook = 0xffF800B76768dA8AB6aab527021e4a6A91219040;
|
|
16
15
|
|
|
17
16
|
address[] memory baseImpls = new address[](1);
|
|
18
17
|
baseImpls[0] = existingContentCoinHook;
|
|
19
18
|
|
|
20
19
|
bytes memory contentCoinUpgradeCall = abi.encodeWithSelector(IHooksUpgradeGate.registerUpgradePath.selector, baseImpls, deployment.zoraV4CoinHook);
|
|
21
20
|
|
|
22
|
-
baseImpls[0] = existingCreatorCoinHook;
|
|
23
|
-
|
|
24
|
-
bytes memory creatorCoinUpgradeCall = abi.encodeWithSelector(IHooksUpgradeGate.registerUpgradePath.selector, baseImpls, deployment.creatorCoinHook);
|
|
25
|
-
|
|
26
21
|
printUpgradeFactoryCommand(deployment);
|
|
27
22
|
|
|
28
23
|
console.log("register upgrade gate target", deployment.hookUpgradeGate);
|
|
29
24
|
|
|
30
25
|
console.log("contentCoinUpgradeCall");
|
|
31
26
|
console.logBytes(contentCoinUpgradeCall);
|
|
32
|
-
console.log("creatorCoinUpgradeCall");
|
|
33
|
-
console.logBytes(creatorCoinUpgradeCall);
|
|
34
27
|
}
|
|
35
28
|
}
|
|
@@ -6,14 +6,12 @@ import {CoinsDeployerBase} from "../src/deployment/CoinsDeployerBase.sol";
|
|
|
6
6
|
|
|
7
7
|
import {IZoraFactory} from "../src/interfaces/IZoraFactory.sol";
|
|
8
8
|
import {CoinConfigurationVersions} from "../src/libs/CoinConfigurationVersions.sol";
|
|
9
|
-
import {MarketConstants} from "../src/libs/MarketConstants.sol";
|
|
10
9
|
import {UniV4SwapHelper} from "../src/libs/UniV4SwapHelper.sol";
|
|
11
10
|
import {ContentCoin} from "../src/ContentCoin.sol";
|
|
12
11
|
import {PoolKey} from "@uniswap/v4-core/src/types/PoolKey.sol";
|
|
13
12
|
import {IUniversalRouter} from "@uniswap/universal-router/contracts/interfaces/IUniversalRouter.sol";
|
|
14
13
|
import {IPermit2} from "permit2/src/interfaces/IPermit2.sol";
|
|
15
14
|
import {MockERC20} from "../test/mocks/MockERC20.sol";
|
|
16
|
-
import {MarketConstants} from "../src/libs/MarketConstants.sol";
|
|
17
15
|
import {Currency} from "@uniswap/v4-core/src/types/Currency.sol";
|
|
18
16
|
import {IERC20} from "@openzeppelin/contracts/token/ERC20/IERC20.sol";
|
|
19
17
|
import {ICoin} from "../src/interfaces/ICoin.sol";
|
|
@@ -104,7 +102,6 @@ contract TestV4Swap is CoinsDeployerBase {
|
|
|
104
102
|
vm.startBroadcast(trader);
|
|
105
103
|
|
|
106
104
|
address createReferral = 0xC077e4cC02fa01A5b7fAca1acE9BBe9f5ac5Af9F;
|
|
107
|
-
address tradeReferral = 0xC077e4cC02fa01A5b7fAca1acE9BBe9f5ac5Af9F;
|
|
108
105
|
|
|
109
106
|
ICoin backingCoin = _deployCoin(zora, trader, "Backing Coin", "BACK", "https://testc.com", createReferral, bytes32("creator"));
|
|
110
107
|
ICoin contentCoin = _deployCoin(
|
package/script/TestV4Swap.s.sol
CHANGED
|
@@ -6,14 +6,12 @@ import {CoinsDeployerBase} from "../src/deployment/CoinsDeployerBase.sol";
|
|
|
6
6
|
|
|
7
7
|
import {IZoraFactory} from "../src/interfaces/IZoraFactory.sol";
|
|
8
8
|
import {CoinConfigurationVersions} from "../src/libs/CoinConfigurationVersions.sol";
|
|
9
|
-
import {MarketConstants} from "../src/libs/MarketConstants.sol";
|
|
10
9
|
import {UniV4SwapHelper} from "../src/libs/UniV4SwapHelper.sol";
|
|
11
10
|
import {ContentCoin} from "../src/ContentCoin.sol";
|
|
12
11
|
import {PoolKey} from "@uniswap/v4-core/src/types/PoolKey.sol";
|
|
13
12
|
import {IUniversalRouter} from "@uniswap/universal-router/contracts/interfaces/IUniversalRouter.sol";
|
|
14
13
|
import {IPermit2} from "permit2/src/interfaces/IPermit2.sol";
|
|
15
14
|
import {MockERC20} from "../test/mocks/MockERC20.sol";
|
|
16
|
-
import {MarketConstants} from "../src/libs/MarketConstants.sol";
|
|
17
15
|
import {Currency} from "@uniswap/v4-core/src/types/Currency.sol";
|
|
18
16
|
import {IERC20} from "@openzeppelin/contracts/token/ERC20/IERC20.sol";
|
|
19
17
|
import {ICoin} from "../src/interfaces/ICoin.sol";
|
|
@@ -96,7 +94,6 @@ contract TestV4Swap is CoinsDeployerBase {
|
|
|
96
94
|
|
|
97
95
|
vm.startBroadcast(trader);
|
|
98
96
|
|
|
99
|
-
address createReferral = 0xC077e4cC02fa01A5b7fAca1acE9BBe9f5ac5Af9F;
|
|
100
97
|
address tradeReferral = 0xC077e4cC02fa01A5b7fAca1acE9BBe9f5ac5Af9F;
|
|
101
98
|
|
|
102
99
|
// MockERC20 currency = _deployMockCurrency();
|
|
@@ -14,7 +14,7 @@ contract UpgradeFactoryImpl is CoinsDeployerBase {
|
|
|
14
14
|
deployment.coinV4Impl,
|
|
15
15
|
deployment.creatorCoinImpl,
|
|
16
16
|
deployment.zoraV4CoinHook,
|
|
17
|
-
deployment.
|
|
17
|
+
deployment.zoraHookRegistry
|
|
18
18
|
);
|
|
19
19
|
|
|
20
20
|
deployment.zoraFactoryImpl = address(zoraFactoryImpl);
|