@zoralabs/protocol-deployments 0.1.7 → 0.1.9
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 +11 -21
- package/CHANGELOG.md +12 -0
- package/dist/generated/wagmi.d.ts +10 -18
- package/dist/generated/wagmi.d.ts.map +1 -1
- package/dist/index.cjs +4 -5
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +4 -5
- package/dist/index.js.map +1 -1
- package/package.json +5 -11
- package/src/generated/mints.ts +2 -2
- package/src/generated/wagmi.ts +8 -9
- package/wagmi.config.ts +0 -189
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@zoralabs/protocol-deployments",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.9",
|
|
4
4
|
"repository": "https://github.com/ourzora/zora-protocol",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"type": "module",
|
|
@@ -16,11 +16,10 @@
|
|
|
16
16
|
}
|
|
17
17
|
},
|
|
18
18
|
"scripts": {
|
|
19
|
-
"build": "yarn
|
|
19
|
+
"build": "yarn bundle-configs && tsup",
|
|
20
20
|
"bundle-configs": "tsx scripts/bundle-configs.ts && yarn prettier",
|
|
21
|
-
"prettier": "prettier --write 'src/**/*.ts' 'scripts/*'
|
|
22
|
-
"lint": "prettier --check 'src/**/*.ts' 'scripts/*'
|
|
23
|
-
"wagmi": "wagmi generate"
|
|
21
|
+
"prettier": "prettier --write 'src/**/*.ts' 'scripts/*'",
|
|
22
|
+
"lint": "prettier --check 'src/**/*.ts' 'scripts/*'"
|
|
24
23
|
},
|
|
25
24
|
"dependencies": {},
|
|
26
25
|
"devDependencies": {
|
|
@@ -30,12 +29,7 @@
|
|
|
30
29
|
"tsup": "^7.2.0",
|
|
31
30
|
"glob": "^10.2.2",
|
|
32
31
|
"es-main": "^1.2.0",
|
|
33
|
-
"@wagmi/cli": "^1.0.1",
|
|
34
32
|
"@types/node": "^20.1.2",
|
|
35
|
-
"@lavamoat/preinstall-always-fail": "2.0.0"
|
|
36
|
-
"@zoralabs/1155-deployments": "*",
|
|
37
|
-
"@zoralabs/zora-1155-contracts": "*",
|
|
38
|
-
"@zoralabs/mints-contracts": "*",
|
|
39
|
-
"@zoralabs/mints-deployments": "*"
|
|
33
|
+
"@lavamoat/preinstall-always-fail": "2.0.0"
|
|
40
34
|
}
|
|
41
35
|
}
|
package/src/generated/mints.ts
CHANGED
|
@@ -39,13 +39,13 @@ export const chainConfigs = {
|
|
|
39
39
|
export const addresses = {
|
|
40
40
|
7777777: {
|
|
41
41
|
MINTS_ETH_UNWRAPPER_AND_CALLER:
|
|
42
|
-
"
|
|
42
|
+
"0xb0994EB9520C98C97e1F3953a5964535C2bd271A",
|
|
43
43
|
MINTS_MANAGER_IMPL: "0x978685ad10B829F17e6c2C6E8EeABd7dFDdC1678",
|
|
44
44
|
MINTS_MANAGER_IMPL_VERSION: "0.1.2",
|
|
45
45
|
},
|
|
46
46
|
999999999: {
|
|
47
47
|
MINTS_ETH_UNWRAPPER_AND_CALLER:
|
|
48
|
-
"
|
|
48
|
+
"0xb0994EB9520C98C97e1F3953a5964535C2bd271A",
|
|
49
49
|
MINTS_MANAGER_IMPL: "0x978685ad10B829F17e6c2C6E8EeABd7dFDdC1678",
|
|
50
50
|
MINTS_MANAGER_IMPL_VERSION: "0.1.2",
|
|
51
51
|
},
|
package/src/generated/wagmi.ts
CHANGED
|
@@ -534,8 +534,8 @@ export const iUnwrapAndForwardActionABI = [
|
|
|
534
534
|
//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
|
535
535
|
|
|
536
536
|
/**
|
|
537
|
-
* - [__View Contract on Zora Explorer__](https://explorer.zora.energy/address/
|
|
538
|
-
* - [__View Contract on Zora Sepolia Zora Sepolia Explorer__](https://sepolia.explorer.zora.energy//address/
|
|
537
|
+
* - [__View Contract on Zora Explorer__](https://explorer.zora.energy/address/0xb0994EB9520C98C97e1F3953a5964535C2bd271A)
|
|
538
|
+
* - [__View Contract on Zora Sepolia Zora Sepolia Explorer__](https://sepolia.explorer.zora.energy//address/0xb0994EB9520C98C97e1F3953a5964535C2bd271A)
|
|
539
539
|
*/
|
|
540
540
|
export const mintsEthUnwrapperAndCallerABI = [
|
|
541
541
|
{
|
|
@@ -617,7 +617,6 @@ export const mintsEthUnwrapperAndCallerABI = [
|
|
|
617
617
|
{ type: 'error', inputs: [], name: 'FailedInnerCall' },
|
|
618
618
|
{ type: 'error', inputs: [], name: 'NotExpectingReceive' },
|
|
619
619
|
{ type: 'error', inputs: [], name: 'NotZoraMints1155' },
|
|
620
|
-
{ type: 'error', inputs: [], name: 'ReentrancyGuardReentrantCall' },
|
|
621
620
|
{
|
|
622
621
|
type: 'error',
|
|
623
622
|
inputs: [{ name: 'data', internalType: 'bytes', type: 'bytes' }],
|
|
@@ -627,17 +626,17 @@ export const mintsEthUnwrapperAndCallerABI = [
|
|
|
627
626
|
] as const
|
|
628
627
|
|
|
629
628
|
/**
|
|
630
|
-
* - [__View Contract on Zora Explorer__](https://explorer.zora.energy/address/
|
|
631
|
-
* - [__View Contract on Zora Sepolia Zora Sepolia Explorer__](https://sepolia.explorer.zora.energy//address/
|
|
629
|
+
* - [__View Contract on Zora Explorer__](https://explorer.zora.energy/address/0xb0994EB9520C98C97e1F3953a5964535C2bd271A)
|
|
630
|
+
* - [__View Contract on Zora Sepolia Zora Sepolia Explorer__](https://sepolia.explorer.zora.energy//address/0xb0994EB9520C98C97e1F3953a5964535C2bd271A)
|
|
632
631
|
*/
|
|
633
632
|
export const mintsEthUnwrapperAndCallerAddress = {
|
|
634
|
-
7777777: '
|
|
635
|
-
999999999: '
|
|
633
|
+
7777777: '0xb0994EB9520C98C97e1F3953a5964535C2bd271A',
|
|
634
|
+
999999999: '0xb0994EB9520C98C97e1F3953a5964535C2bd271A',
|
|
636
635
|
} as const
|
|
637
636
|
|
|
638
637
|
/**
|
|
639
|
-
* - [__View Contract on Zora Explorer__](https://explorer.zora.energy/address/
|
|
640
|
-
* - [__View Contract on Zora Sepolia Zora Sepolia Explorer__](https://sepolia.explorer.zora.energy//address/
|
|
638
|
+
* - [__View Contract on Zora Explorer__](https://explorer.zora.energy/address/0xb0994EB9520C98C97e1F3953a5964535C2bd271A)
|
|
639
|
+
* - [__View Contract on Zora Sepolia Zora Sepolia Explorer__](https://sepolia.explorer.zora.energy//address/0xb0994EB9520C98C97e1F3953a5964535C2bd271A)
|
|
641
640
|
*/
|
|
642
641
|
export const mintsEthUnwrapperAndCallerConfig = {
|
|
643
642
|
address: mintsEthUnwrapperAndCallerAddress,
|
package/wagmi.config.ts
DELETED
|
@@ -1,189 +0,0 @@
|
|
|
1
|
-
import { defineConfig } from "@wagmi/cli";
|
|
2
|
-
import { Abi, zeroAddress } from "viem";
|
|
3
|
-
import { readdirSync, readFileSync } from "fs";
|
|
4
|
-
import * as abis from "@zoralabs/zora-1155-contracts";
|
|
5
|
-
import {
|
|
6
|
-
zoraMints1155ABI,
|
|
7
|
-
zoraMintsManagerImplABI,
|
|
8
|
-
mintsEthUnwrapperAndCallerABI,
|
|
9
|
-
iUnwrapAndForwardActionABI,
|
|
10
|
-
} from "@zoralabs/mints-contracts";
|
|
11
|
-
|
|
12
|
-
type Address = `0x${string}`;
|
|
13
|
-
|
|
14
|
-
type Addresses = {
|
|
15
|
-
[contractName: string]: {
|
|
16
|
-
address: {
|
|
17
|
-
[chainId: number]: Address;
|
|
18
|
-
};
|
|
19
|
-
abi: Abi;
|
|
20
|
-
};
|
|
21
|
-
};
|
|
22
|
-
|
|
23
|
-
const get1155Addresses = () => {
|
|
24
|
-
const addresses: Addresses = {};
|
|
25
|
-
|
|
26
|
-
const addressesFiles = readdirSync("../1155-deployments/addresses");
|
|
27
|
-
|
|
28
|
-
const addAddress = ({
|
|
29
|
-
contractName,
|
|
30
|
-
chainId,
|
|
31
|
-
address,
|
|
32
|
-
abi,
|
|
33
|
-
}: {
|
|
34
|
-
contractName: string;
|
|
35
|
-
chainId: number;
|
|
36
|
-
address?: Address;
|
|
37
|
-
abi: Abi;
|
|
38
|
-
}) => {
|
|
39
|
-
if (!address || address === zeroAddress) return;
|
|
40
|
-
if (!addresses[contractName]) {
|
|
41
|
-
addresses[contractName] = {
|
|
42
|
-
address: {},
|
|
43
|
-
abi,
|
|
44
|
-
};
|
|
45
|
-
}
|
|
46
|
-
|
|
47
|
-
addresses[contractName]!.address[chainId] = address;
|
|
48
|
-
};
|
|
49
|
-
|
|
50
|
-
const protocolRewardsConfig = JSON.parse(
|
|
51
|
-
readFileSync("../protocol-rewards/deterministicConfig.json", "utf-8"),
|
|
52
|
-
) as {
|
|
53
|
-
expectedAddress: Address;
|
|
54
|
-
};
|
|
55
|
-
|
|
56
|
-
for (const addressesFile of addressesFiles) {
|
|
57
|
-
const jsonAddress = JSON.parse(
|
|
58
|
-
readFileSync(`../1155-deployments/addresses/${addressesFile}`, "utf-8"),
|
|
59
|
-
) as {
|
|
60
|
-
FIXED_PRICE_SALE_STRATEGY: Address;
|
|
61
|
-
MERKLE_MINT_SALE_STRATEGY: Address;
|
|
62
|
-
REDEEM_MINTER_FACTORY: Address;
|
|
63
|
-
"1155_IMPL": Address;
|
|
64
|
-
FACTORY_IMPL: Address;
|
|
65
|
-
FACTORY_PROXY: Address;
|
|
66
|
-
PREMINTER_PROXY?: Address;
|
|
67
|
-
ERC20_MINTER?: Address;
|
|
68
|
-
};
|
|
69
|
-
|
|
70
|
-
const chainId = parseInt(addressesFile.split(".")[0]);
|
|
71
|
-
|
|
72
|
-
addAddress({
|
|
73
|
-
contractName: "ZoraCreatorFixedPriceSaleStrategy",
|
|
74
|
-
chainId,
|
|
75
|
-
address: jsonAddress.FIXED_PRICE_SALE_STRATEGY,
|
|
76
|
-
abi: abis.zoraCreatorFixedPriceSaleStrategyABI,
|
|
77
|
-
});
|
|
78
|
-
addAddress({
|
|
79
|
-
contractName: "ZoraCreatorMerkleMinterStrategy",
|
|
80
|
-
chainId,
|
|
81
|
-
address: jsonAddress.MERKLE_MINT_SALE_STRATEGY,
|
|
82
|
-
abi: abis.zoraCreatorMerkleMinterStrategyABI,
|
|
83
|
-
});
|
|
84
|
-
addAddress({
|
|
85
|
-
contractName: "ZoraCreator1155FactoryImpl",
|
|
86
|
-
chainId,
|
|
87
|
-
address: jsonAddress.FACTORY_PROXY,
|
|
88
|
-
abi: abis.zoraCreator1155FactoryImplABI,
|
|
89
|
-
});
|
|
90
|
-
addAddress({
|
|
91
|
-
contractName: "ZoraCreatorRedeemMinterFactory",
|
|
92
|
-
chainId,
|
|
93
|
-
address: jsonAddress.REDEEM_MINTER_FACTORY,
|
|
94
|
-
abi: abis.zoraCreatorRedeemMinterFactoryABI,
|
|
95
|
-
});
|
|
96
|
-
addAddress({
|
|
97
|
-
contractName: "ZoraCreator1155PremintExecutorImpl",
|
|
98
|
-
chainId,
|
|
99
|
-
address: jsonAddress.PREMINTER_PROXY,
|
|
100
|
-
abi: abis.zoraCreator1155PremintExecutorImplABI,
|
|
101
|
-
});
|
|
102
|
-
addAddress({
|
|
103
|
-
contractName: "ProtocolRewards",
|
|
104
|
-
chainId,
|
|
105
|
-
address: protocolRewardsConfig.expectedAddress,
|
|
106
|
-
abi: abis.protocolRewardsABI,
|
|
107
|
-
});
|
|
108
|
-
addAddress({
|
|
109
|
-
contractName: "ERC20Minter",
|
|
110
|
-
chainId,
|
|
111
|
-
abi: abis.erc20MinterABI,
|
|
112
|
-
address: jsonAddress.ERC20_MINTER,
|
|
113
|
-
});
|
|
114
|
-
}
|
|
115
|
-
|
|
116
|
-
return addresses;
|
|
117
|
-
};
|
|
118
|
-
|
|
119
|
-
const getMintsAddresses = () => {
|
|
120
|
-
const addressesFiles = readdirSync("../mints-deployments/addresses");
|
|
121
|
-
|
|
122
|
-
const chainIds = addressesFiles.map((x) => Number(x.split(".")[0]));
|
|
123
|
-
|
|
124
|
-
const mintsProxyConfig = JSON.parse(
|
|
125
|
-
readFileSync(
|
|
126
|
-
"../mints-deployments/deterministicConfig/mintsProxy/params.json",
|
|
127
|
-
"utf-8",
|
|
128
|
-
),
|
|
129
|
-
);
|
|
130
|
-
|
|
131
|
-
const mintsEthUnwrapperAndCallerAddress = JSON.parse(
|
|
132
|
-
readFileSync("../mints-deployments/addresses/999999999.json", "utf-8"),
|
|
133
|
-
).MINTS_ETH_UNWRAPPER_AND_CALLER as Address;
|
|
134
|
-
|
|
135
|
-
const mintsManagerAddress = mintsProxyConfig.manager
|
|
136
|
-
.deployedAddress as Address;
|
|
137
|
-
const zoraMints1155Address = mintsProxyConfig.mints1155
|
|
138
|
-
.deployedAddress as Address;
|
|
139
|
-
|
|
140
|
-
return {
|
|
141
|
-
mintsManager: Object.fromEntries(
|
|
142
|
-
chainIds.map((chainId) => [chainId, mintsManagerAddress]),
|
|
143
|
-
),
|
|
144
|
-
mints1155: Object.fromEntries(
|
|
145
|
-
chainIds.map((chainId) => [chainId, zoraMints1155Address as Address]),
|
|
146
|
-
),
|
|
147
|
-
mintsEthUnwrapperAndCaller: Object.fromEntries(
|
|
148
|
-
chainIds.map((chainId) => [chainId, mintsEthUnwrapperAndCallerAddress]),
|
|
149
|
-
),
|
|
150
|
-
};
|
|
151
|
-
};
|
|
152
|
-
|
|
153
|
-
const mintsAddresses = getMintsAddresses();
|
|
154
|
-
|
|
155
|
-
export default defineConfig({
|
|
156
|
-
out: "src/generated/wagmi.ts",
|
|
157
|
-
contracts: [
|
|
158
|
-
...Object.entries(get1155Addresses()).map(
|
|
159
|
-
([contractName, addressConfig]) => ({
|
|
160
|
-
abi: addressConfig.abi,
|
|
161
|
-
address: addressConfig.address,
|
|
162
|
-
name: contractName,
|
|
163
|
-
}),
|
|
164
|
-
),
|
|
165
|
-
{
|
|
166
|
-
abi: abis.zoraCreator1155ImplABI,
|
|
167
|
-
name: "ZoraCreator1155Impl",
|
|
168
|
-
},
|
|
169
|
-
{
|
|
170
|
-
abi: zoraMintsManagerImplABI,
|
|
171
|
-
name: "ZoraMintsManagerImpl",
|
|
172
|
-
address: mintsAddresses.mintsManager,
|
|
173
|
-
},
|
|
174
|
-
{
|
|
175
|
-
abi: zoraMints1155ABI,
|
|
176
|
-
name: "ZoraMints1155",
|
|
177
|
-
address: mintsAddresses.mints1155,
|
|
178
|
-
},
|
|
179
|
-
{
|
|
180
|
-
abi: mintsEthUnwrapperAndCallerABI,
|
|
181
|
-
name: "MintsEthUnwrapperAndCaller",
|
|
182
|
-
address: mintsAddresses.mintsEthUnwrapperAndCaller,
|
|
183
|
-
},
|
|
184
|
-
{
|
|
185
|
-
abi: iUnwrapAndForwardActionABI,
|
|
186
|
-
name: "IUnwrapAndForwardAction",
|
|
187
|
-
},
|
|
188
|
-
],
|
|
189
|
-
});
|