@zoralabs/coins 1.1.2 → 2.0.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 +96 -95
- package/CHANGELOG.md +22 -0
- package/README.md +126 -0
- package/abis/BaseCoinV4.json +1840 -0
- package/abis/BaseZoraV4CoinHook.json +6 -2
- package/abis/CoinUniV4Test.json +20 -0
- package/abis/ContentCoinHook.json +6 -2
- package/abis/CreatorCoinHook.json +6 -2
- package/abis/FactoryTest.json +7 -0
- package/abis/FeeEstimatorHook.json +6 -2
- package/abis/IZoraV4CoinHook.json +2 -2
- package/abis/Ownable2StepUpgradeable.json +138 -0
- package/abis/ZoraFactoryImpl.json +39 -0
- package/addresses/8453.json +5 -5
- package/dist/index.cjs +36 -3
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +35 -2
- package/dist/index.js.map +1 -1
- package/dist/wagmiGenerated.d.ts +32 -1
- package/dist/wagmiGenerated.d.ts.map +1 -1
- package/package/wagmiGenerated.ts +35 -2
- package/package.json +1 -1
- package/script/TestBackingCoinSwap.s.sol +1 -1
- package/script/TestV4Swap.s.sol +1 -1
- package/src/{CoinV4.sol → BaseCoinV4.sol} +8 -16
- package/src/ContentCoin.sol +45 -0
- package/src/CreatorCoin.sol +7 -5
- package/src/ZoraFactoryImpl.sol +3 -3
- package/src/deployment/CoinsDeployerBase.sol +3 -3
- package/src/hooks/BaseZoraV4CoinHook.sol +3 -1
- package/src/interfaces/IZoraV4CoinHook.sol +1 -1
- package/src/version/ContractVersionBase.sol +1 -1
- package/test/CoinUniV4.t.sol +61 -5
- package/test/Factory.t.sol +41 -0
- package/test/Upgrades.t.sol +8 -8
- package/test/utils/BaseTest.sol +23 -15
- package/wagmi.config.ts +1 -1
- /package/abis/{CoinV4.json → ContentCoin.json} +0 -0
|
@@ -1,4 +1,8 @@
|
|
|
1
1
|
[
|
|
2
|
+
{
|
|
3
|
+
"type": "receive",
|
|
4
|
+
"stateMutability": "payable"
|
|
5
|
+
},
|
|
2
6
|
{
|
|
3
7
|
"type": "function",
|
|
4
8
|
"name": "afterAddLiquidity",
|
|
@@ -965,8 +969,8 @@
|
|
|
965
969
|
"inputs": [
|
|
966
970
|
{
|
|
967
971
|
"name": "poolKeyHash",
|
|
968
|
-
"type": "
|
|
969
|
-
"internalType": "
|
|
972
|
+
"type": "bytes32",
|
|
973
|
+
"internalType": "bytes32"
|
|
970
974
|
}
|
|
971
975
|
],
|
|
972
976
|
"outputs": [
|
package/abis/CoinUniV4Test.json
CHANGED
|
@@ -393,6 +393,19 @@
|
|
|
393
393
|
"outputs": [],
|
|
394
394
|
"stateMutability": "nonpayable"
|
|
395
395
|
},
|
|
396
|
+
{
|
|
397
|
+
"type": "function",
|
|
398
|
+
"name": "test_canSwapEthForCoin",
|
|
399
|
+
"inputs": [
|
|
400
|
+
{
|
|
401
|
+
"name": "amountIn",
|
|
402
|
+
"type": "uint128",
|
|
403
|
+
"internalType": "uint128"
|
|
404
|
+
}
|
|
405
|
+
],
|
|
406
|
+
"outputs": [],
|
|
407
|
+
"stateMutability": "nonpayable"
|
|
408
|
+
},
|
|
396
409
|
{
|
|
397
410
|
"type": "function",
|
|
398
411
|
"name": "test_distributesMarketRewards",
|
|
@@ -416,6 +429,13 @@
|
|
|
416
429
|
"outputs": [],
|
|
417
430
|
"stateMutability": "nonpayable"
|
|
418
431
|
},
|
|
432
|
+
{
|
|
433
|
+
"type": "function",
|
|
434
|
+
"name": "test_distributesMarketRewardsInEth",
|
|
435
|
+
"inputs": [],
|
|
436
|
+
"outputs": [],
|
|
437
|
+
"stateMutability": "nonpayable"
|
|
438
|
+
},
|
|
419
439
|
{
|
|
420
440
|
"type": "function",
|
|
421
441
|
"name": "test_estimateLpFees",
|
|
@@ -25,6 +25,10 @@
|
|
|
25
25
|
],
|
|
26
26
|
"stateMutability": "nonpayable"
|
|
27
27
|
},
|
|
28
|
+
{
|
|
29
|
+
"type": "receive",
|
|
30
|
+
"stateMutability": "payable"
|
|
31
|
+
},
|
|
28
32
|
{
|
|
29
33
|
"type": "function",
|
|
30
34
|
"name": "afterAddLiquidity",
|
|
@@ -991,8 +995,8 @@
|
|
|
991
995
|
"inputs": [
|
|
992
996
|
{
|
|
993
997
|
"name": "poolKeyHash",
|
|
994
|
-
"type": "
|
|
995
|
-
"internalType": "
|
|
998
|
+
"type": "bytes32",
|
|
999
|
+
"internalType": "bytes32"
|
|
996
1000
|
}
|
|
997
1001
|
],
|
|
998
1002
|
"outputs": [
|
|
@@ -25,6 +25,10 @@
|
|
|
25
25
|
],
|
|
26
26
|
"stateMutability": "nonpayable"
|
|
27
27
|
},
|
|
28
|
+
{
|
|
29
|
+
"type": "receive",
|
|
30
|
+
"stateMutability": "payable"
|
|
31
|
+
},
|
|
28
32
|
{
|
|
29
33
|
"type": "function",
|
|
30
34
|
"name": "afterAddLiquidity",
|
|
@@ -991,8 +995,8 @@
|
|
|
991
995
|
"inputs": [
|
|
992
996
|
{
|
|
993
997
|
"name": "poolKeyHash",
|
|
994
|
-
"type": "
|
|
995
|
-
"internalType": "
|
|
998
|
+
"type": "bytes32",
|
|
999
|
+
"internalType": "bytes32"
|
|
996
1000
|
}
|
|
997
1001
|
],
|
|
998
1002
|
"outputs": [
|
package/abis/FactoryTest.json
CHANGED
|
@@ -388,6 +388,13 @@
|
|
|
388
388
|
"outputs": [],
|
|
389
389
|
"stateMutability": "view"
|
|
390
390
|
},
|
|
391
|
+
{
|
|
392
|
+
"type": "function",
|
|
393
|
+
"name": "test_ownable2Step",
|
|
394
|
+
"inputs": [],
|
|
395
|
+
"outputs": [],
|
|
396
|
+
"stateMutability": "nonpayable"
|
|
397
|
+
},
|
|
391
398
|
{
|
|
392
399
|
"type": "function",
|
|
393
400
|
"name": "test_revert_invalid_owner",
|
|
@@ -25,6 +25,10 @@
|
|
|
25
25
|
],
|
|
26
26
|
"stateMutability": "nonpayable"
|
|
27
27
|
},
|
|
28
|
+
{
|
|
29
|
+
"type": "receive",
|
|
30
|
+
"stateMutability": "payable"
|
|
31
|
+
},
|
|
28
32
|
{
|
|
29
33
|
"type": "function",
|
|
30
34
|
"name": "afterAddLiquidity",
|
|
@@ -1128,8 +1132,8 @@
|
|
|
1128
1132
|
"inputs": [
|
|
1129
1133
|
{
|
|
1130
1134
|
"name": "poolKeyHash",
|
|
1131
|
-
"type": "
|
|
1132
|
-
"internalType": "
|
|
1135
|
+
"type": "bytes32",
|
|
1136
|
+
"internalType": "bytes32"
|
|
1133
1137
|
}
|
|
1134
1138
|
],
|
|
1135
1139
|
"outputs": [
|
|
@@ -0,0 +1,138 @@
|
|
|
1
|
+
[
|
|
2
|
+
{
|
|
3
|
+
"type": "function",
|
|
4
|
+
"name": "acceptOwnership",
|
|
5
|
+
"inputs": [],
|
|
6
|
+
"outputs": [],
|
|
7
|
+
"stateMutability": "nonpayable"
|
|
8
|
+
},
|
|
9
|
+
{
|
|
10
|
+
"type": "function",
|
|
11
|
+
"name": "owner",
|
|
12
|
+
"inputs": [],
|
|
13
|
+
"outputs": [
|
|
14
|
+
{
|
|
15
|
+
"name": "",
|
|
16
|
+
"type": "address",
|
|
17
|
+
"internalType": "address"
|
|
18
|
+
}
|
|
19
|
+
],
|
|
20
|
+
"stateMutability": "view"
|
|
21
|
+
},
|
|
22
|
+
{
|
|
23
|
+
"type": "function",
|
|
24
|
+
"name": "pendingOwner",
|
|
25
|
+
"inputs": [],
|
|
26
|
+
"outputs": [
|
|
27
|
+
{
|
|
28
|
+
"name": "",
|
|
29
|
+
"type": "address",
|
|
30
|
+
"internalType": "address"
|
|
31
|
+
}
|
|
32
|
+
],
|
|
33
|
+
"stateMutability": "view"
|
|
34
|
+
},
|
|
35
|
+
{
|
|
36
|
+
"type": "function",
|
|
37
|
+
"name": "renounceOwnership",
|
|
38
|
+
"inputs": [],
|
|
39
|
+
"outputs": [],
|
|
40
|
+
"stateMutability": "nonpayable"
|
|
41
|
+
},
|
|
42
|
+
{
|
|
43
|
+
"type": "function",
|
|
44
|
+
"name": "transferOwnership",
|
|
45
|
+
"inputs": [
|
|
46
|
+
{
|
|
47
|
+
"name": "newOwner",
|
|
48
|
+
"type": "address",
|
|
49
|
+
"internalType": "address"
|
|
50
|
+
}
|
|
51
|
+
],
|
|
52
|
+
"outputs": [],
|
|
53
|
+
"stateMutability": "nonpayable"
|
|
54
|
+
},
|
|
55
|
+
{
|
|
56
|
+
"type": "event",
|
|
57
|
+
"name": "Initialized",
|
|
58
|
+
"inputs": [
|
|
59
|
+
{
|
|
60
|
+
"name": "version",
|
|
61
|
+
"type": "uint64",
|
|
62
|
+
"indexed": false,
|
|
63
|
+
"internalType": "uint64"
|
|
64
|
+
}
|
|
65
|
+
],
|
|
66
|
+
"anonymous": false
|
|
67
|
+
},
|
|
68
|
+
{
|
|
69
|
+
"type": "event",
|
|
70
|
+
"name": "OwnershipTransferStarted",
|
|
71
|
+
"inputs": [
|
|
72
|
+
{
|
|
73
|
+
"name": "previousOwner",
|
|
74
|
+
"type": "address",
|
|
75
|
+
"indexed": true,
|
|
76
|
+
"internalType": "address"
|
|
77
|
+
},
|
|
78
|
+
{
|
|
79
|
+
"name": "newOwner",
|
|
80
|
+
"type": "address",
|
|
81
|
+
"indexed": true,
|
|
82
|
+
"internalType": "address"
|
|
83
|
+
}
|
|
84
|
+
],
|
|
85
|
+
"anonymous": false
|
|
86
|
+
},
|
|
87
|
+
{
|
|
88
|
+
"type": "event",
|
|
89
|
+
"name": "OwnershipTransferred",
|
|
90
|
+
"inputs": [
|
|
91
|
+
{
|
|
92
|
+
"name": "previousOwner",
|
|
93
|
+
"type": "address",
|
|
94
|
+
"indexed": true,
|
|
95
|
+
"internalType": "address"
|
|
96
|
+
},
|
|
97
|
+
{
|
|
98
|
+
"name": "newOwner",
|
|
99
|
+
"type": "address",
|
|
100
|
+
"indexed": true,
|
|
101
|
+
"internalType": "address"
|
|
102
|
+
}
|
|
103
|
+
],
|
|
104
|
+
"anonymous": false
|
|
105
|
+
},
|
|
106
|
+
{
|
|
107
|
+
"type": "error",
|
|
108
|
+
"name": "InvalidInitialization",
|
|
109
|
+
"inputs": []
|
|
110
|
+
},
|
|
111
|
+
{
|
|
112
|
+
"type": "error",
|
|
113
|
+
"name": "NotInitializing",
|
|
114
|
+
"inputs": []
|
|
115
|
+
},
|
|
116
|
+
{
|
|
117
|
+
"type": "error",
|
|
118
|
+
"name": "OwnableInvalidOwner",
|
|
119
|
+
"inputs": [
|
|
120
|
+
{
|
|
121
|
+
"name": "owner",
|
|
122
|
+
"type": "address",
|
|
123
|
+
"internalType": "address"
|
|
124
|
+
}
|
|
125
|
+
]
|
|
126
|
+
},
|
|
127
|
+
{
|
|
128
|
+
"type": "error",
|
|
129
|
+
"name": "OwnableUnauthorizedAccount",
|
|
130
|
+
"inputs": [
|
|
131
|
+
{
|
|
132
|
+
"name": "account",
|
|
133
|
+
"type": "address",
|
|
134
|
+
"internalType": "address"
|
|
135
|
+
}
|
|
136
|
+
]
|
|
137
|
+
}
|
|
138
|
+
]
|
|
@@ -43,6 +43,13 @@
|
|
|
43
43
|
],
|
|
44
44
|
"stateMutability": "view"
|
|
45
45
|
},
|
|
46
|
+
{
|
|
47
|
+
"type": "function",
|
|
48
|
+
"name": "acceptOwnership",
|
|
49
|
+
"inputs": [],
|
|
50
|
+
"outputs": [],
|
|
51
|
+
"stateMutability": "nonpayable"
|
|
52
|
+
},
|
|
46
53
|
{
|
|
47
54
|
"type": "function",
|
|
48
55
|
"name": "coinAddress",
|
|
@@ -546,6 +553,19 @@
|
|
|
546
553
|
],
|
|
547
554
|
"stateMutability": "view"
|
|
548
555
|
},
|
|
556
|
+
{
|
|
557
|
+
"type": "function",
|
|
558
|
+
"name": "pendingOwner",
|
|
559
|
+
"inputs": [],
|
|
560
|
+
"outputs": [
|
|
561
|
+
{
|
|
562
|
+
"name": "",
|
|
563
|
+
"type": "address",
|
|
564
|
+
"internalType": "address"
|
|
565
|
+
}
|
|
566
|
+
],
|
|
567
|
+
"stateMutability": "view"
|
|
568
|
+
},
|
|
549
569
|
{
|
|
550
570
|
"type": "function",
|
|
551
571
|
"name": "proxiableUUID",
|
|
@@ -877,6 +897,25 @@
|
|
|
877
897
|
],
|
|
878
898
|
"anonymous": false
|
|
879
899
|
},
|
|
900
|
+
{
|
|
901
|
+
"type": "event",
|
|
902
|
+
"name": "OwnershipTransferStarted",
|
|
903
|
+
"inputs": [
|
|
904
|
+
{
|
|
905
|
+
"name": "previousOwner",
|
|
906
|
+
"type": "address",
|
|
907
|
+
"indexed": true,
|
|
908
|
+
"internalType": "address"
|
|
909
|
+
},
|
|
910
|
+
{
|
|
911
|
+
"name": "newOwner",
|
|
912
|
+
"type": "address",
|
|
913
|
+
"indexed": true,
|
|
914
|
+
"internalType": "address"
|
|
915
|
+
}
|
|
916
|
+
],
|
|
917
|
+
"anonymous": false
|
|
918
|
+
},
|
|
880
919
|
{
|
|
881
920
|
"type": "event",
|
|
882
921
|
"name": "OwnershipTransferred",
|
package/addresses/8453.json
CHANGED
|
@@ -3,12 +3,12 @@
|
|
|
3
3
|
"COIN_V3_IMPL": "0x45Bf86430af7CD071Ea23aE52325A78C8d12aD5a",
|
|
4
4
|
"COIN_V4_IMPL": "0xca72309AaF706d290E08608b1Af47943902f69b2",
|
|
5
5
|
"COIN_VERSION": "1.1.0",
|
|
6
|
-
"CREATOR_COIN_HOOK": "
|
|
7
|
-
"CREATOR_COIN_HOOK_SALT": "
|
|
6
|
+
"CREATOR_COIN_HOOK": "0xd61A675F8a0c67A73DC3B54FB7318B4D91409040",
|
|
7
|
+
"CREATOR_COIN_HOOK_SALT": "0x0000000000000000000000000000000000000000000000000000000000000ae8",
|
|
8
8
|
"CREATOR_COIN_IMPL": "0x88CC4E08C7608723f3E44e17aC669Fb43b6A8313",
|
|
9
9
|
"HOOK_UPGRADE_GATE": "0xD88f6BdD765313CaFA5888C177c325E2C3AbF2D2",
|
|
10
10
|
"ZORA_FACTORY": "0x777777751622c0d3258f214F9DF38E35BF45baF3",
|
|
11
|
-
"ZORA_FACTORY_IMPL": "
|
|
12
|
-
"ZORA_V4_COIN_HOOK": "
|
|
13
|
-
"ZORA_V4_COIN_HOOK_SALT": "
|
|
11
|
+
"ZORA_FACTORY_IMPL": "0x0e2ea62E5377D46FeF114A60AfBE3d5eA7490577",
|
|
12
|
+
"ZORA_V4_COIN_HOOK": "0x9ea932730A7787000042e34390B8E435dD839040",
|
|
13
|
+
"ZORA_V4_COIN_HOOK_SALT": "0x0000000000000000000000000000000000000000000000000000000000002fa2"
|
|
14
14
|
}
|
package/dist/index.cjs
CHANGED
|
@@ -23,7 +23,7 @@ __export(index_exports, {
|
|
|
23
23
|
autoSwapperABI: () => autoSwapperABI,
|
|
24
24
|
buySupplyWithSwapRouterHookABI: () => buySupplyWithSwapRouterHookABI,
|
|
25
25
|
coinABI: () => coinABI,
|
|
26
|
-
|
|
26
|
+
contentCoinABI: () => contentCoinABI,
|
|
27
27
|
creatorCoinABI: () => creatorCoinABI,
|
|
28
28
|
iPermit2ABI: () => iPermit2ABI,
|
|
29
29
|
iPoolConfigEncodingABI: () => iPoolConfigEncodingABI,
|
|
@@ -1276,7 +1276,7 @@ var coinABI = [
|
|
|
1276
1276
|
{ type: "error", inputs: [], name: "SlippageBoundsExceeded" },
|
|
1277
1277
|
{ type: "error", inputs: [], name: "UseRevokeOwnershipToRemoveSelf" }
|
|
1278
1278
|
];
|
|
1279
|
-
var
|
|
1279
|
+
var contentCoinABI = [
|
|
1280
1280
|
{
|
|
1281
1281
|
type: "constructor",
|
|
1282
1282
|
inputs: [
|
|
@@ -4216,6 +4216,13 @@ var zoraFactoryImplABI = [
|
|
|
4216
4216
|
outputs: [{ name: "", internalType: "string", type: "string" }],
|
|
4217
4217
|
stateMutability: "view"
|
|
4218
4218
|
},
|
|
4219
|
+
{
|
|
4220
|
+
type: "function",
|
|
4221
|
+
inputs: [],
|
|
4222
|
+
name: "acceptOwnership",
|
|
4223
|
+
outputs: [],
|
|
4224
|
+
stateMutability: "nonpayable"
|
|
4225
|
+
},
|
|
4219
4226
|
{
|
|
4220
4227
|
type: "function",
|
|
4221
4228
|
inputs: [
|
|
@@ -4405,6 +4412,13 @@ var zoraFactoryImplABI = [
|
|
|
4405
4412
|
outputs: [{ name: "", internalType: "address", type: "address" }],
|
|
4406
4413
|
stateMutability: "view"
|
|
4407
4414
|
},
|
|
4415
|
+
{
|
|
4416
|
+
type: "function",
|
|
4417
|
+
inputs: [],
|
|
4418
|
+
name: "pendingOwner",
|
|
4419
|
+
outputs: [{ name: "", internalType: "address", type: "address" }],
|
|
4420
|
+
stateMutability: "view"
|
|
4421
|
+
},
|
|
4408
4422
|
{
|
|
4409
4423
|
type: "function",
|
|
4410
4424
|
inputs: [],
|
|
@@ -4646,6 +4660,25 @@ var zoraFactoryImplABI = [
|
|
|
4646
4660
|
],
|
|
4647
4661
|
name: "Initialized"
|
|
4648
4662
|
},
|
|
4663
|
+
{
|
|
4664
|
+
type: "event",
|
|
4665
|
+
anonymous: false,
|
|
4666
|
+
inputs: [
|
|
4667
|
+
{
|
|
4668
|
+
name: "previousOwner",
|
|
4669
|
+
internalType: "address",
|
|
4670
|
+
type: "address",
|
|
4671
|
+
indexed: true
|
|
4672
|
+
},
|
|
4673
|
+
{
|
|
4674
|
+
name: "newOwner",
|
|
4675
|
+
internalType: "address",
|
|
4676
|
+
type: "address",
|
|
4677
|
+
indexed: true
|
|
4678
|
+
}
|
|
4679
|
+
],
|
|
4680
|
+
name: "OwnershipTransferStarted"
|
|
4681
|
+
},
|
|
4649
4682
|
{
|
|
4650
4683
|
type: "event",
|
|
4651
4684
|
anonymous: false,
|
|
@@ -4772,7 +4805,7 @@ var zoraFactoryImplABI = [
|
|
|
4772
4805
|
autoSwapperABI,
|
|
4773
4806
|
buySupplyWithSwapRouterHookABI,
|
|
4774
4807
|
coinABI,
|
|
4775
|
-
|
|
4808
|
+
contentCoinABI,
|
|
4776
4809
|
creatorCoinABI,
|
|
4777
4810
|
iPermit2ABI,
|
|
4778
4811
|
iPoolConfigEncodingABI,
|