From 0a9c4eac601db7acd693f6d3f73646cc4f64817f Mon Sep 17 00:00:00 2001 From: Jacob Homanics Date: Fri, 24 May 2024 03:40:54 -0500 Subject: [PATCH] latest --- packages/foundry/lib/reputation | 2 +- packages/foundry/script/Deploy.s.sol | 4 + packages/foundry/script/DeployFactory.s.sol | 36 + .../app/factory/_components/Factory.tsx | 15 + packages/nextjs/app/factory/page.tsx | 18 + packages/nextjs/components/Header.tsx | 26 +- .../cards/token-properties/TokenTypeCard.tsx | 2 - .../components/rep-tokens/hooks/Hooks.tsx | 2 - .../nextjs/contracts/deployedContracts.ts | 2182 +++++++++++++++-- packages/nextjs/scaffold.config.ts | 2 +- 10 files changed, 2124 insertions(+), 165 deletions(-) create mode 100644 packages/foundry/script/DeployFactory.s.sol create mode 100644 packages/nextjs/app/factory/_components/Factory.tsx create mode 100644 packages/nextjs/app/factory/page.tsx diff --git a/packages/foundry/lib/reputation b/packages/foundry/lib/reputation index 03f46b3..f6652a3 160000 --- a/packages/foundry/lib/reputation +++ b/packages/foundry/lib/reputation @@ -1 +1 @@ -Subproject commit 03f46b308ea123fcd518a16328185f7293abb50f +Subproject commit f6652a3cdf468b83bf996c2f2f476247eae314d7 diff --git a/packages/foundry/script/Deploy.s.sol b/packages/foundry/script/Deploy.s.sol index cb99a2e..d7423f1 100644 --- a/packages/foundry/script/Deploy.s.sol +++ b/packages/foundry/script/Deploy.s.sol @@ -7,6 +7,7 @@ import {ScaffoldETHDeploy} from "./DeployHelpers.s.sol"; import {Hats} from "../contracts/Hats/Hats.sol"; import {DeployDemoScript} from "./DeployDemo.s.sol"; +import {DeployFactoryScript} from "./DeployFactory.s.sol"; contract DeployScript is ScaffoldETHDeploy { error InvalidPrivateKey(string); @@ -15,6 +16,9 @@ contract DeployScript is ScaffoldETHDeploy { DeployDemoScript deployer = new DeployDemoScript(); deployer.run(); + DeployFactoryScript factoryDeployer = new DeployFactoryScript(); + + factoryDeployer.run(); exportDeployments(); } diff --git a/packages/foundry/script/DeployFactory.s.sol b/packages/foundry/script/DeployFactory.s.sol new file mode 100644 index 0000000..699f09b --- /dev/null +++ b/packages/foundry/script/DeployFactory.s.sol @@ -0,0 +1,36 @@ +//SPDX-License-Identifier: MIT +pragma solidity ^0.8.19; + +import {console} from "forge-std/console.sol"; + +import {ScaffoldETHDeploy} from "./DeployHelpers.s.sol"; +import {ReputationTokensFactory} from + "@atxdao/contracts/reputation/ReputationTokensFactory.sol"; +import {ReputationTokensUpgradeable} from + "@atxdao/contracts/reputation/ReputationTokensUpgradeable.sol"; + +contract DeployFactoryScript is ScaffoldETHDeploy { + error InvalidPrivateKey(string); + + address controller = 0x2F15D4A66D22ecC6967928b6A76Ab06897b05676; //replace with burner or other address from wallet! + + function run() external { + uint256 deployerPrivateKey = setupLocalhostEnv(); + if (deployerPrivateKey == 0) { + revert InvalidPrivateKey( + "You don't have a deployer account. Make sure you have set DEPLOYER_PRIVATE_KEY in .env or use `yarn generate` to generate a new random account" + ); + } + address deployerPubKey = vm.createWallet(deployerPrivateKey).addr; + + vm.startBroadcast(deployerPrivateKey); + address[] memory admins = new address[](2); + admins[0] = deployerPubKey; + admins[1] = controller; + + ReputationTokensUpgradeable implementation = + new ReputationTokensUpgradeable(); + ReputationTokensFactory factory = + new ReputationTokensFactory(admins, admins, address(implementation)); + } +} diff --git a/packages/nextjs/app/factory/_components/Factory.tsx b/packages/nextjs/app/factory/_components/Factory.tsx new file mode 100644 index 0000000..e88e9bf --- /dev/null +++ b/packages/nextjs/app/factory/_components/Factory.tsx @@ -0,0 +1,15 @@ +"use client"; + +export function Factory() { + return ( + <> +
+
+
+

{"hello"}

+
+
+
+ + ); +} diff --git a/packages/nextjs/app/factory/page.tsx b/packages/nextjs/app/factory/page.tsx new file mode 100644 index 0000000..cd69165 --- /dev/null +++ b/packages/nextjs/app/factory/page.tsx @@ -0,0 +1,18 @@ +import { Factory } from "./_components/Factory"; +import type { NextPage } from "next"; +import { getMetadata } from "~~/utils/scaffold-eth/getMetadata"; + +export const metadata = getMetadata({ + title: "Factory", + description: "Factory", +}); + +const FactoryPage: NextPage = () => { + return ( + <> + + + ); +}; + +export default FactoryPage; diff --git a/packages/nextjs/components/Header.tsx b/packages/nextjs/components/Header.tsx index 74fbd3d..cffcc18 100644 --- a/packages/nextjs/components/Header.tsx +++ b/packages/nextjs/components/Header.tsx @@ -20,9 +20,15 @@ type HeaderMenuLink = { export const menuLinks: HeaderMenuLink[] = []; -export const HeaderMenuLinks = () => { +type Props = { + menuLinks: HeaderMenuLink[]; +}; + +export const HeaderMenuLinks = ({ menuLinks }: Props) => { const pathname = usePathname(); + console.log(menuLinks); + return ( <> {menuLinks.map(({ label, href, icon }) => { @@ -96,6 +102,11 @@ export const Header = () => { href: "/hats", }); + linksToAdd.push({ + label: "Factory", + href: "/factory", + }); + linksToAdd.push({ label: "Debug Contracts", href: "/debug", @@ -131,11 +142,14 @@ export const Header = () => { href: "/stewards-hideout", }, ]); - - setInstancedHeaderLinks([...instancedHeaderLinks, linksToAdd]); } + + console.log(linksToAdd); + + if (linksToAdd.length > 0) setInstancedHeaderLinks([...instancedHeaderLinks, ...linksToAdd]); + // eslint-disable-next-line react-hooks/exhaustive-deps - }, [balanceOfClaimableHat2]); + }, []); const [output, setOutput] = useState(); @@ -160,7 +174,7 @@ export const Header = () => { setIsDrawerOpen(false); }} > - + )} @@ -174,7 +188,7 @@ export const Header = () => {
    - +
diff --git a/packages/nextjs/components/rep-tokens/cards/token-properties/TokenTypeCard.tsx b/packages/nextjs/components/rep-tokens/cards/token-properties/TokenTypeCard.tsx index 4d11c1a..6564e93 100644 --- a/packages/nextjs/components/rep-tokens/cards/token-properties/TokenTypeCard.tsx +++ b/packages/nextjs/components/rep-tokens/cards/token-properties/TokenTypeCard.tsx @@ -10,8 +10,6 @@ type Props = { export const TokenTypeCard = ({ token, tokenType, type = "default" }: Props) => { let i = "Token Type: "; - console.log(token); - if (token) { if (token?.tokenType === 0) { i += "Transferable"; diff --git a/packages/nextjs/components/rep-tokens/hooks/Hooks.tsx b/packages/nextjs/components/rep-tokens/hooks/Hooks.tsx index 5aa90b6..0ba83b3 100644 --- a/packages/nextjs/components/rep-tokens/hooks/Hooks.tsx +++ b/packages/nextjs/components/rep-tokens/hooks/Hooks.tsx @@ -190,8 +190,6 @@ export const useRepTokens = (tokenIds: bigint[], address?: string, replacementTy } } - console.log(addresses); - // const { addresses } = useMemo(() => { // const addresses: string[] = []; diff --git a/packages/nextjs/contracts/deployedContracts.ts b/packages/nextjs/contracts/deployedContracts.ts index 70fa9bf..e5c9e4a 100644 --- a/packages/nextjs/contracts/deployedContracts.ts +++ b/packages/nextjs/contracts/deployedContracts.ts @@ -27,7 +27,7 @@ const deployedContracts = { }, { type: "function", - name: "DEFAULT_ADMIN_ROLE", + name: "MINTER_ROLE", inputs: [], outputs: [ { @@ -40,7 +40,7 @@ const deployedContracts = { }, { type: "function", - name: "MINTER_ROLE", + name: "TOKEN_MIGRATOR_ROLE", inputs: [], outputs: [ { @@ -53,7 +53,7 @@ const deployedContracts = { }, { type: "function", - name: "TOKEN_MIGRATOR_ROLE", + name: "TOKEN_UPDATER_ROLE", inputs: [], outputs: [ { @@ -66,7 +66,7 @@ const deployedContracts = { }, { type: "function", - name: "TOKEN_UPDATER_ROLE", + name: "TOKEN_URI_SETTER_ROLE", inputs: [], outputs: [ { @@ -79,13 +79,19 @@ const deployedContracts = { }, { type: "function", - name: "TOKEN_URI_SETTER_ROLE", - inputs: [], + name: "accountsByToken", + inputs: [ + { + name: "id", + type: "uint256", + internalType: "uint256", + }, + ], outputs: [ { name: "", - type: "bytes32", - internalType: "bytes32", + type: "address[]", + internalType: "address[]", }, ], stateMutability: "view", @@ -271,6 +277,49 @@ const deployedContracts = { ], stateMutability: "view", }, + { + type: "function", + name: "getRoleMember", + inputs: [ + { + name: "role", + type: "bytes32", + internalType: "bytes32", + }, + { + name: "index", + type: "uint256", + internalType: "uint256", + }, + ], + outputs: [ + { + name: "", + type: "address", + internalType: "address", + }, + ], + stateMutability: "view", + }, + { + type: "function", + name: "getRoleMemberCount", + inputs: [ + { + name: "role", + type: "bytes32", + internalType: "bytes32", + }, + ], + outputs: [ + { + name: "", + type: "uint256", + internalType: "uint256", + }, + ], + stateMutability: "view", + }, { type: "function", name: "getTokenType", @@ -515,13 +564,6 @@ const deployedContracts = { ], stateMutability: "view", }, - { - type: "function", - name: "renounceOwnership", - inputs: [], - outputs: [], - stateMutability: "nonpayable", - }, { type: "function", name: "renounceRole", @@ -531,11 +573,6 @@ const deployedContracts = { type: "bytes32", internalType: "bytes32", }, - { - name: "callerConfirmation", - type: "address", - internalType: "address", - }, ], outputs: [], stateMutability: "nonpayable", @@ -634,7 +671,7 @@ const deployedContracts = { internalType: "address", }, { - name: "approved", + name: "status", type: "bool", internalType: "bool", }, @@ -697,12 +734,69 @@ const deployedContracts = { ], stateMutability: "view", }, + { + type: "function", + name: "tokensByAccount", + inputs: [ + { + name: "account", + type: "address", + internalType: "address", + }, + ], + outputs: [ + { + name: "", + type: "uint256[]", + internalType: "uint256[]", + }, + ], + stateMutability: "view", + }, + { + type: "function", + name: "totalHolders", + inputs: [ + { + name: "id", + type: "uint256", + internalType: "uint256", + }, + ], + outputs: [ + { + name: "", + type: "uint256", + internalType: "uint256", + }, + ], + stateMutability: "view", + }, + { + type: "function", + name: "totalSupply", + inputs: [ + { + name: "id", + type: "uint256", + internalType: "uint256", + }, + ], + outputs: [ + { + name: "", + type: "uint256", + internalType: "uint256", + }, + ], + stateMutability: "view", + }, { type: "function", name: "transferOwnership", inputs: [ { - name: "newOwner", + name: "account", type: "address", internalType: "address", }, @@ -1168,7 +1262,7 @@ const deployedContracts = { internalType: "string", }, { - name: "id", + name: "tokenId", type: "uint256", indexed: true, internalType: "uint256", @@ -1216,148 +1310,78 @@ const deployedContracts = { }, { type: "error", - name: "AccessControlBadConfirmation", + name: "ERC1155Base__ArrayLengthMismatch", inputs: [], }, { type: "error", - name: "AccessControlUnauthorizedAccount", - inputs: [ - { - name: "account", - type: "address", - internalType: "address", - }, - { - name: "neededRole", - type: "bytes32", - internalType: "bytes32", - }, - ], + name: "ERC1155Base__BalanceQueryZeroAddress", + inputs: [], }, { type: "error", - name: "ERC1155InsufficientBalance", - inputs: [ - { - name: "sender", - type: "address", - internalType: "address", - }, - { - name: "balance", - type: "uint256", - internalType: "uint256", - }, - { - name: "needed", - type: "uint256", - internalType: "uint256", - }, - { - name: "tokenId", - type: "uint256", - internalType: "uint256", - }, - ], + name: "ERC1155Base__BurnExceedsBalance", + inputs: [], }, { type: "error", - name: "ERC1155InvalidApprover", - inputs: [ - { - name: "approver", - type: "address", - internalType: "address", - }, - ], + name: "ERC1155Base__BurnFromZeroAddress", + inputs: [], }, { type: "error", - name: "ERC1155InvalidArrayLength", - inputs: [ - { - name: "idsLength", - type: "uint256", - internalType: "uint256", - }, - { - name: "valuesLength", - type: "uint256", - internalType: "uint256", - }, - ], + name: "ERC1155Base__ERC1155ReceiverNotImplemented", + inputs: [], }, { type: "error", - name: "ERC1155InvalidOperator", - inputs: [ - { - name: "operator", - type: "address", - internalType: "address", - }, - ], + name: "ERC1155Base__ERC1155ReceiverRejected", + inputs: [], }, { type: "error", - name: "ERC1155InvalidReceiver", - inputs: [ - { - name: "receiver", - type: "address", - internalType: "address", - }, - ], + name: "ERC1155Base__MintToZeroAddress", + inputs: [], }, { type: "error", - name: "ERC1155InvalidSender", - inputs: [ - { - name: "sender", - type: "address", - internalType: "address", - }, - ], + name: "ERC1155Base__NotOwnerOrApproved", + inputs: [], }, { type: "error", - name: "ERC1155MissingApprovalForAll", - inputs: [ - { - name: "operator", - type: "address", - internalType: "address", - }, - { - name: "owner", - type: "address", - internalType: "address", - }, - ], + name: "ERC1155Base__SelfApproval", + inputs: [], }, { type: "error", - name: "OwnableInvalidOwner", - inputs: [ - { - name: "owner", - type: "address", - internalType: "address", - }, - ], + name: "ERC1155Base__TransferExceedsBalance", + inputs: [], }, { type: "error", - name: "OwnableUnauthorizedAccount", - inputs: [ - { - name: "account", - type: "address", - internalType: "address", - }, - ], + name: "ERC1155Base__TransferToZeroAddress", + inputs: [], + }, + { + type: "error", + name: "ERC165Base__InvalidInterfaceId", + inputs: [], + }, + { + type: "error", + name: "EnumerableSet__IndexOutOfBounds", + inputs: [], + }, + { + type: "error", + name: "Ownable__NotOwner", + inputs: [], + }, + { + type: "error", + name: "Ownable__NotTransitiveOwner", + inputs: [], }, { type: "error", @@ -1369,25 +1393,57 @@ const deployedContracts = { name: "ReputationTokens__InsufficientBalance", inputs: [], }, - ], - inheritedFunctions: { - balanceOf: "lib/openzeppelin-contracts/contracts/token/ERC1155/extensions/ERC1155URIStorage.sol", - balanceOfBatch: "lib/openzeppelin-contracts/contracts/token/ERC1155/extensions/ERC1155URIStorage.sol", - isApprovedForAll: "lib/openzeppelin-contracts/contracts/token/ERC1155/extensions/ERC1155URIStorage.sol", - safeBatchTransferFrom: "lib/openzeppelin-contracts/contracts/token/ERC1155/extensions/ERC1155URIStorage.sol", - safeTransferFrom: "lib/openzeppelin-contracts/contracts/token/ERC1155/extensions/ERC1155URIStorage.sol", - setApprovalForAll: "lib/openzeppelin-contracts/contracts/token/ERC1155/extensions/ERC1155URIStorage.sol", - supportsInterface: "lib/openzeppelin-contracts/contracts/access/AccessControl.sol", - uri: "lib/openzeppelin-contracts/contracts/token/ERC1155/extensions/ERC1155URIStorage.sol", - DEFAULT_ADMIN_ROLE: "lib/openzeppelin-contracts/contracts/access/AccessControl.sol", - getRoleAdmin: "lib/openzeppelin-contracts/contracts/access/AccessControl.sol", - grantRole: "lib/openzeppelin-contracts/contracts/access/AccessControl.sol", - hasRole: "lib/openzeppelin-contracts/contracts/access/AccessControl.sol", - renounceRole: "lib/openzeppelin-contracts/contracts/access/AccessControl.sol", - revokeRole: "lib/openzeppelin-contracts/contracts/access/AccessControl.sol", - owner: "lib/openzeppelin-contracts/contracts/access/Ownable.sol", - renounceOwnership: "lib/openzeppelin-contracts/contracts/access/Ownable.sol", - transferOwnership: "lib/openzeppelin-contracts/contracts/access/Ownable.sol", + { + type: "error", + name: "UintUtils__InsufficientPadding", + inputs: [], + }, + { + type: "error", + name: "UintUtils__InvalidBase", + inputs: [], + }, + ], + inheritedFunctions: { + owner: "lib/reputation/lib/solidstate-solidity/contracts/access/ownable/Ownable.sol", + transferOwnership: "lib/reputation/lib/solidstate-solidity/contracts/access/ownable/Ownable.sol", + MINTER_ROLE: "lib/reputation/contracts/ReputationTokensBase.sol", + TOKEN_MIGRATOR_ROLE: "lib/reputation/contracts/ReputationTokensBase.sol", + TOKEN_UPDATER_ROLE: "lib/reputation/contracts/ReputationTokensBase.sol", + TOKEN_URI_SETTER_ROLE: "lib/reputation/contracts/ReputationTokensBase.sol", + accountsByToken: "lib/reputation/contracts/ReputationTokensBase.sol", + balanceOf: "lib/reputation/contracts/ReputationTokensBase.sol", + balanceOfBatch: "lib/reputation/contracts/ReputationTokensBase.sol", + burnedBalanceOf: "lib/reputation/contracts/ReputationTokensBase.sol", + distributableBalanceOf: "lib/reputation/contracts/ReputationTokensBase.sol", + distribute: "lib/reputation/contracts/ReputationTokensBase.sol", + distributeBatch: "lib/reputation/contracts/ReputationTokensBase.sol", + getRoleAdmin: "lib/reputation/contracts/ReputationTokensBase.sol", + getRoleMember: "lib/reputation/contracts/ReputationTokensBase.sol", + getRoleMemberCount: "lib/reputation/contracts/ReputationTokensBase.sol", + getTokenType: "lib/reputation/contracts/ReputationTokensBase.sol", + grantRole: "lib/reputation/contracts/ReputationTokensBase.sol", + hasRole: "lib/reputation/contracts/ReputationTokensBase.sol", + honestBalanceOf: "lib/reputation/contracts/ReputationTokensBase.sol", + isApprovedForAll: "lib/reputation/contracts/ReputationTokensBase.sol", + migrate: "lib/reputation/contracts/ReputationTokensBase.sol", + migrateBatch: "lib/reputation/contracts/ReputationTokensBase.sol", + mint: "lib/reputation/contracts/ReputationTokensBase.sol", + mintBatch: "lib/reputation/contracts/ReputationTokensBase.sol", + renounceRole: "lib/reputation/contracts/ReputationTokensBase.sol", + revokeRole: "lib/reputation/contracts/ReputationTokensBase.sol", + safeBatchTransferFrom: "lib/reputation/contracts/ReputationTokensBase.sol", + safeTransferFrom: "lib/reputation/contracts/ReputationTokensBase.sol", + setApprovalForAll: "lib/reputation/contracts/ReputationTokensBase.sol", + setBatchTokenURI: "lib/reputation/contracts/ReputationTokensBase.sol", + setTokenURI: "lib/reputation/contracts/ReputationTokensBase.sol", + supportsInterface: "lib/reputation/contracts/ReputationTokensBase.sol", + tokensByAccount: "lib/reputation/contracts/ReputationTokensBase.sol", + totalHolders: "lib/reputation/contracts/ReputationTokensBase.sol", + totalSupply: "lib/reputation/contracts/ReputationTokensBase.sol", + updateToken: "lib/reputation/contracts/ReputationTokensBase.sol", + updateTokenBatch: "lib/reputation/contracts/ReputationTokensBase.sol", + uri: "lib/reputation/contracts/ReputationTokensBase.sol", }, }, ReputationFaucet: { @@ -3883,6 +3939,1826 @@ const deployedContracts = { ], inheritedFunctions: {}, }, + ReputationTokensUpgradeable: { + address: "0xc3e53F4d16Ae77Db1c982e75a937B9f60FE63690", + abi: [ + { + type: "function", + name: "MINTER_ROLE", + inputs: [], + outputs: [ + { + name: "", + type: "bytes32", + internalType: "bytes32", + }, + ], + stateMutability: "view", + }, + { + type: "function", + name: "TOKEN_MIGRATOR_ROLE", + inputs: [], + outputs: [ + { + name: "", + type: "bytes32", + internalType: "bytes32", + }, + ], + stateMutability: "view", + }, + { + type: "function", + name: "TOKEN_UPDATER_ROLE", + inputs: [], + outputs: [ + { + name: "", + type: "bytes32", + internalType: "bytes32", + }, + ], + stateMutability: "view", + }, + { + type: "function", + name: "TOKEN_URI_SETTER_ROLE", + inputs: [], + outputs: [ + { + name: "", + type: "bytes32", + internalType: "bytes32", + }, + ], + stateMutability: "view", + }, + { + type: "function", + name: "accountsByToken", + inputs: [ + { + name: "id", + type: "uint256", + internalType: "uint256", + }, + ], + outputs: [ + { + name: "", + type: "address[]", + internalType: "address[]", + }, + ], + stateMutability: "view", + }, + { + type: "function", + name: "balanceOf", + inputs: [ + { + name: "account", + type: "address", + internalType: "address", + }, + { + name: "id", + type: "uint256", + internalType: "uint256", + }, + ], + outputs: [ + { + name: "", + type: "uint256", + internalType: "uint256", + }, + ], + stateMutability: "view", + }, + { + type: "function", + name: "balanceOfBatch", + inputs: [ + { + name: "accounts", + type: "address[]", + internalType: "address[]", + }, + { + name: "ids", + type: "uint256[]", + internalType: "uint256[]", + }, + ], + outputs: [ + { + name: "", + type: "uint256[]", + internalType: "uint256[]", + }, + ], + stateMutability: "view", + }, + { + type: "function", + name: "burnedBalanceOf", + inputs: [ + { + name: "addr", + type: "address", + internalType: "address", + }, + { + name: "tokenId", + type: "uint256", + internalType: "uint256", + }, + ], + outputs: [ + { + name: "burnedBalance", + type: "uint256", + internalType: "uint256", + }, + ], + stateMutability: "view", + }, + { + type: "function", + name: "distributableBalanceOf", + inputs: [ + { + name: "addr", + type: "address", + internalType: "address", + }, + { + name: "tokenId", + type: "uint256", + internalType: "uint256", + }, + ], + outputs: [ + { + name: "distributableBalance", + type: "uint256", + internalType: "uint256", + }, + ], + stateMutability: "view", + }, + { + type: "function", + name: "distribute", + inputs: [ + { + name: "from", + type: "address", + internalType: "address", + }, + { + name: "to", + type: "address", + internalType: "address", + }, + { + name: "id", + type: "uint256", + internalType: "uint256", + }, + { + name: "value", + type: "uint256", + internalType: "uint256", + }, + { + name: "data", + type: "bytes", + internalType: "bytes", + }, + ], + outputs: [], + stateMutability: "nonpayable", + }, + { + type: "function", + name: "distributeBatch", + inputs: [ + { + name: "from", + type: "address", + internalType: "address", + }, + { + name: "to", + type: "address", + internalType: "address", + }, + { + name: "ids", + type: "uint256[]", + internalType: "uint256[]", + }, + { + name: "values", + type: "uint256[]", + internalType: "uint256[]", + }, + { + name: "data", + type: "bytes", + internalType: "bytes", + }, + ], + outputs: [], + stateMutability: "nonpayable", + }, + { + type: "function", + name: "getRoleAdmin", + inputs: [ + { + name: "role", + type: "bytes32", + internalType: "bytes32", + }, + ], + outputs: [ + { + name: "", + type: "bytes32", + internalType: "bytes32", + }, + ], + stateMutability: "view", + }, + { + type: "function", + name: "getRoleMember", + inputs: [ + { + name: "role", + type: "bytes32", + internalType: "bytes32", + }, + { + name: "index", + type: "uint256", + internalType: "uint256", + }, + ], + outputs: [ + { + name: "", + type: "address", + internalType: "address", + }, + ], + stateMutability: "view", + }, + { + type: "function", + name: "getRoleMemberCount", + inputs: [ + { + name: "role", + type: "bytes32", + internalType: "bytes32", + }, + ], + outputs: [ + { + name: "", + type: "uint256", + internalType: "uint256", + }, + ], + stateMutability: "view", + }, + { + type: "function", + name: "getTokenType", + inputs: [ + { + name: "id", + type: "uint256", + internalType: "uint256", + }, + ], + outputs: [ + { + name: "", + type: "uint8", + internalType: "enum IReputationTokensTypes.TokenType", + }, + ], + stateMutability: "view", + }, + { + type: "function", + name: "grantRole", + inputs: [ + { + name: "role", + type: "bytes32", + internalType: "bytes32", + }, + { + name: "account", + type: "address", + internalType: "address", + }, + ], + outputs: [], + stateMutability: "nonpayable", + }, + { + type: "function", + name: "hasRole", + inputs: [ + { + name: "role", + type: "bytes32", + internalType: "bytes32", + }, + { + name: "account", + type: "address", + internalType: "address", + }, + ], + outputs: [ + { + name: "", + type: "bool", + internalType: "bool", + }, + ], + stateMutability: "view", + }, + { + type: "function", + name: "honestBalanceOf", + inputs: [ + { + name: "addr", + type: "address", + internalType: "address", + }, + { + name: "tokenId", + type: "uint256", + internalType: "uint256", + }, + ], + outputs: [ + { + name: "transferrableBalance", + type: "uint256", + internalType: "uint256", + }, + ], + stateMutability: "view", + }, + { + type: "function", + name: "initialize", + inputs: [ + { + name: "newOwner", + type: "address", + internalType: "address", + }, + { + name: "admins", + type: "address[]", + internalType: "address[]", + }, + ], + outputs: [], + stateMutability: "nonpayable", + }, + { + type: "function", + name: "isApprovedForAll", + inputs: [ + { + name: "account", + type: "address", + internalType: "address", + }, + { + name: "operator", + type: "address", + internalType: "address", + }, + ], + outputs: [ + { + name: "", + type: "bool", + internalType: "bool", + }, + ], + stateMutability: "view", + }, + { + type: "function", + name: "migrate", + inputs: [ + { + name: "from", + type: "address", + internalType: "address", + }, + { + name: "to", + type: "address", + internalType: "address", + }, + { + name: "id", + type: "uint256", + internalType: "uint256", + }, + { + name: "value", + type: "uint256", + internalType: "uint256", + }, + { + name: "data", + type: "bytes", + internalType: "bytes", + }, + ], + outputs: [], + stateMutability: "nonpayable", + }, + { + type: "function", + name: "migrateBatch", + inputs: [ + { + name: "from", + type: "address", + internalType: "address", + }, + { + name: "to", + type: "address", + internalType: "address", + }, + { + name: "ids", + type: "uint256[]", + internalType: "uint256[]", + }, + { + name: "values", + type: "uint256[]", + internalType: "uint256[]", + }, + { + name: "data", + type: "bytes", + internalType: "bytes", + }, + ], + outputs: [], + stateMutability: "nonpayable", + }, + { + type: "function", + name: "mint", + inputs: [ + { + name: "to", + type: "address", + internalType: "address", + }, + { + name: "id", + type: "uint256", + internalType: "uint256", + }, + { + name: "value", + type: "uint256", + internalType: "uint256", + }, + { + name: "data", + type: "bytes", + internalType: "bytes", + }, + ], + outputs: [], + stateMutability: "nonpayable", + }, + { + type: "function", + name: "mintBatch", + inputs: [ + { + name: "to", + type: "address", + internalType: "address", + }, + { + name: "ids", + type: "uint256[]", + internalType: "uint256[]", + }, + { + name: "values", + type: "uint256[]", + internalType: "uint256[]", + }, + { + name: "data", + type: "bytes", + internalType: "bytes", + }, + ], + outputs: [], + stateMutability: "nonpayable", + }, + { + type: "function", + name: "owner", + inputs: [], + outputs: [ + { + name: "", + type: "address", + internalType: "address", + }, + ], + stateMutability: "view", + }, + { + type: "function", + name: "renounceRole", + inputs: [ + { + name: "role", + type: "bytes32", + internalType: "bytes32", + }, + ], + outputs: [], + stateMutability: "nonpayable", + }, + { + type: "function", + name: "revokeRole", + inputs: [ + { + name: "role", + type: "bytes32", + internalType: "bytes32", + }, + { + name: "account", + type: "address", + internalType: "address", + }, + ], + outputs: [], + stateMutability: "nonpayable", + }, + { + type: "function", + name: "safeBatchTransferFrom", + inputs: [ + { + name: "from", + type: "address", + internalType: "address", + }, + { + name: "to", + type: "address", + internalType: "address", + }, + { + name: "ids", + type: "uint256[]", + internalType: "uint256[]", + }, + { + name: "values", + type: "uint256[]", + internalType: "uint256[]", + }, + { + name: "data", + type: "bytes", + internalType: "bytes", + }, + ], + outputs: [], + stateMutability: "nonpayable", + }, + { + type: "function", + name: "safeTransferFrom", + inputs: [ + { + name: "from", + type: "address", + internalType: "address", + }, + { + name: "to", + type: "address", + internalType: "address", + }, + { + name: "id", + type: "uint256", + internalType: "uint256", + }, + { + name: "value", + type: "uint256", + internalType: "uint256", + }, + { + name: "data", + type: "bytes", + internalType: "bytes", + }, + ], + outputs: [], + stateMutability: "nonpayable", + }, + { + type: "function", + name: "setApprovalForAll", + inputs: [ + { + name: "operator", + type: "address", + internalType: "address", + }, + { + name: "status", + type: "bool", + internalType: "bool", + }, + ], + outputs: [], + stateMutability: "nonpayable", + }, + { + type: "function", + name: "setBatchTokenURI", + inputs: [ + { + name: "tokenIds", + type: "uint256[]", + internalType: "uint256[]", + }, + { + name: "tokenURIs", + type: "string[]", + internalType: "string[]", + }, + ], + outputs: [], + stateMutability: "nonpayable", + }, + { + type: "function", + name: "setTokenURI", + inputs: [ + { + name: "tokenId", + type: "uint256", + internalType: "uint256", + }, + { + name: "tokenURI", + type: "string", + internalType: "string", + }, + ], + outputs: [], + stateMutability: "nonpayable", + }, + { + type: "function", + name: "supportsInterface", + inputs: [ + { + name: "interfaceId", + type: "bytes4", + internalType: "bytes4", + }, + ], + outputs: [ + { + name: "", + type: "bool", + internalType: "bool", + }, + ], + stateMutability: "view", + }, + { + type: "function", + name: "tokensByAccount", + inputs: [ + { + name: "account", + type: "address", + internalType: "address", + }, + ], + outputs: [ + { + name: "", + type: "uint256[]", + internalType: "uint256[]", + }, + ], + stateMutability: "view", + }, + { + type: "function", + name: "totalHolders", + inputs: [ + { + name: "id", + type: "uint256", + internalType: "uint256", + }, + ], + outputs: [ + { + name: "", + type: "uint256", + internalType: "uint256", + }, + ], + stateMutability: "view", + }, + { + type: "function", + name: "totalSupply", + inputs: [ + { + name: "id", + type: "uint256", + internalType: "uint256", + }, + ], + outputs: [ + { + name: "", + type: "uint256", + internalType: "uint256", + }, + ], + stateMutability: "view", + }, + { + type: "function", + name: "transferOwnership", + inputs: [ + { + name: "account", + type: "address", + internalType: "address", + }, + ], + outputs: [], + stateMutability: "nonpayable", + }, + { + type: "function", + name: "updateToken", + inputs: [ + { + name: "id", + type: "uint256", + internalType: "uint256", + }, + { + name: "tokenType", + type: "uint8", + internalType: "enum IReputationTokensTypes.TokenType", + }, + ], + outputs: [], + stateMutability: "nonpayable", + }, + { + type: "function", + name: "updateTokenBatch", + inputs: [ + { + name: "ids", + type: "uint256[]", + internalType: "uint256[]", + }, + { + name: "tokenTypes", + type: "uint8[]", + internalType: "enum IReputationTokensTypes.TokenType[]", + }, + ], + outputs: [], + stateMutability: "nonpayable", + }, + { + type: "function", + name: "uri", + inputs: [ + { + name: "tokenId", + type: "uint256", + internalType: "uint256", + }, + ], + outputs: [ + { + name: "", + type: "string", + internalType: "string", + }, + ], + stateMutability: "view", + }, + { + type: "event", + name: "ApprovalForAll", + inputs: [ + { + name: "account", + type: "address", + indexed: true, + internalType: "address", + }, + { + name: "operator", + type: "address", + indexed: true, + internalType: "address", + }, + { + name: "approved", + type: "bool", + indexed: false, + internalType: "bool", + }, + ], + anonymous: false, + }, + { + type: "event", + name: "Create", + inputs: [ + { + name: "tokenId", + type: "uint256", + indexed: true, + internalType: "uint256", + }, + ], + anonymous: false, + }, + { + type: "event", + name: "Distribute", + inputs: [ + { + name: "from", + type: "address", + indexed: true, + internalType: "address", + }, + { + name: "to", + type: "address", + indexed: true, + internalType: "address", + }, + { + name: "tokenId", + type: "uint256", + indexed: false, + internalType: "uint256", + }, + { + name: "value", + type: "uint256", + indexed: false, + internalType: "uint256", + }, + ], + anonymous: false, + }, + { + type: "event", + name: "DistributeBatch", + inputs: [ + { + name: "from", + type: "address", + indexed: true, + internalType: "address", + }, + { + name: "to", + type: "address", + indexed: true, + internalType: "address", + }, + { + name: "tokenId", + type: "uint256[]", + indexed: false, + internalType: "uint256[]", + }, + { + name: "value", + type: "uint256[]", + indexed: false, + internalType: "uint256[]", + }, + ], + anonymous: false, + }, + { + type: "event", + name: "Initialized", + inputs: [ + { + name: "version", + type: "uint8", + indexed: false, + internalType: "uint8", + }, + ], + anonymous: false, + }, + { + type: "event", + name: "Migrate", + inputs: [ + { + name: "from", + type: "address", + indexed: true, + internalType: "address", + }, + { + name: "to", + type: "address", + indexed: true, + internalType: "address", + }, + { + name: "id", + type: "uint256", + indexed: false, + internalType: "uint256", + }, + { + name: "value", + type: "uint256", + indexed: false, + internalType: "uint256", + }, + ], + anonymous: false, + }, + { + type: "event", + name: "MigrateBatch", + inputs: [ + { + name: "from", + type: "address", + indexed: true, + internalType: "address", + }, + { + name: "to", + type: "address", + indexed: true, + internalType: "address", + }, + { + name: "ids", + type: "uint256[]", + indexed: false, + internalType: "uint256[]", + }, + { + name: "values", + type: "uint256[]", + indexed: false, + internalType: "uint256[]", + }, + ], + anonymous: false, + }, + { + type: "event", + name: "Mint", + inputs: [ + { + name: "from", + type: "address", + indexed: true, + internalType: "address", + }, + { + name: "to", + type: "address", + indexed: true, + internalType: "address", + }, + { + name: "tokenId", + type: "uint256", + indexed: false, + internalType: "uint256", + }, + { + name: "value", + type: "uint256", + indexed: false, + internalType: "uint256", + }, + ], + anonymous: false, + }, + { + type: "event", + name: "MintBatch", + inputs: [ + { + name: "from", + type: "address", + indexed: true, + internalType: "address", + }, + { + name: "to", + type: "address", + indexed: true, + internalType: "address", + }, + { + name: "tokenIds", + type: "uint256[]", + indexed: false, + internalType: "uint256[]", + }, + { + name: "values", + type: "uint256[]", + indexed: false, + internalType: "uint256[]", + }, + ], + anonymous: false, + }, + { + type: "event", + name: "OwnershipTransferred", + inputs: [ + { + name: "previousOwner", + type: "address", + indexed: true, + internalType: "address", + }, + { + name: "newOwner", + type: "address", + indexed: true, + internalType: "address", + }, + ], + anonymous: false, + }, + { + type: "event", + name: "RoleAdminChanged", + inputs: [ + { + name: "role", + type: "bytes32", + indexed: true, + internalType: "bytes32", + }, + { + name: "previousAdminRole", + type: "bytes32", + indexed: true, + internalType: "bytes32", + }, + { + name: "newAdminRole", + type: "bytes32", + indexed: true, + internalType: "bytes32", + }, + ], + anonymous: false, + }, + { + type: "event", + name: "RoleGranted", + inputs: [ + { + name: "role", + type: "bytes32", + indexed: true, + internalType: "bytes32", + }, + { + name: "account", + type: "address", + indexed: true, + internalType: "address", + }, + { + name: "sender", + type: "address", + indexed: true, + internalType: "address", + }, + ], + anonymous: false, + }, + { + type: "event", + name: "RoleRevoked", + inputs: [ + { + name: "role", + type: "bytes32", + indexed: true, + internalType: "bytes32", + }, + { + name: "account", + type: "address", + indexed: true, + internalType: "address", + }, + { + name: "sender", + type: "address", + indexed: true, + internalType: "address", + }, + ], + anonymous: false, + }, + { + type: "event", + name: "TransferBatch", + inputs: [ + { + name: "operator", + type: "address", + indexed: true, + internalType: "address", + }, + { + name: "from", + type: "address", + indexed: true, + internalType: "address", + }, + { + name: "to", + type: "address", + indexed: true, + internalType: "address", + }, + { + name: "ids", + type: "uint256[]", + indexed: false, + internalType: "uint256[]", + }, + { + name: "values", + type: "uint256[]", + indexed: false, + internalType: "uint256[]", + }, + ], + anonymous: false, + }, + { + type: "event", + name: "TransferSingle", + inputs: [ + { + name: "operator", + type: "address", + indexed: true, + internalType: "address", + }, + { + name: "from", + type: "address", + indexed: true, + internalType: "address", + }, + { + name: "to", + type: "address", + indexed: true, + internalType: "address", + }, + { + name: "id", + type: "uint256", + indexed: false, + internalType: "uint256", + }, + { + name: "value", + type: "uint256", + indexed: false, + internalType: "uint256", + }, + ], + anonymous: false, + }, + { + type: "event", + name: "URI", + inputs: [ + { + name: "value", + type: "string", + indexed: false, + internalType: "string", + }, + { + name: "tokenId", + type: "uint256", + indexed: true, + internalType: "uint256", + }, + ], + anonymous: false, + }, + { + type: "event", + name: "Update", + inputs: [ + { + name: "tokenId", + type: "uint256", + indexed: true, + internalType: "uint256", + }, + { + name: "tokenType", + type: "uint8", + indexed: true, + internalType: "enum IReputationTokensTypes.TokenType", + }, + ], + anonymous: false, + }, + { + type: "event", + name: "UpdateBatch", + inputs: [ + { + name: "tokenId", + type: "uint256[]", + indexed: true, + internalType: "uint256[]", + }, + { + name: "tokenType", + type: "uint8[]", + indexed: true, + internalType: "enum IReputationTokensTypes.TokenType[]", + }, + ], + anonymous: false, + }, + { + type: "error", + name: "ERC1155Base__ArrayLengthMismatch", + inputs: [], + }, + { + type: "error", + name: "ERC1155Base__BalanceQueryZeroAddress", + inputs: [], + }, + { + type: "error", + name: "ERC1155Base__BurnExceedsBalance", + inputs: [], + }, + { + type: "error", + name: "ERC1155Base__BurnFromZeroAddress", + inputs: [], + }, + { + type: "error", + name: "ERC1155Base__ERC1155ReceiverNotImplemented", + inputs: [], + }, + { + type: "error", + name: "ERC1155Base__ERC1155ReceiverRejected", + inputs: [], + }, + { + type: "error", + name: "ERC1155Base__MintToZeroAddress", + inputs: [], + }, + { + type: "error", + name: "ERC1155Base__NotOwnerOrApproved", + inputs: [], + }, + { + type: "error", + name: "ERC1155Base__SelfApproval", + inputs: [], + }, + { + type: "error", + name: "ERC1155Base__TransferExceedsBalance", + inputs: [], + }, + { + type: "error", + name: "ERC1155Base__TransferToZeroAddress", + inputs: [], + }, + { + type: "error", + name: "ERC165Base__InvalidInterfaceId", + inputs: [], + }, + { + type: "error", + name: "EnumerableSet__IndexOutOfBounds", + inputs: [], + }, + { + type: "error", + name: "Initializable__AlreadyInitialized", + inputs: [], + }, + { + type: "error", + name: "Ownable__NotOwner", + inputs: [], + }, + { + type: "error", + name: "Ownable__NotTransitiveOwner", + inputs: [], + }, + { + type: "error", + name: "ReputationTokens__CannotTransferSoulboundToken", + inputs: [], + }, + { + type: "error", + name: "ReputationTokens__InsufficientBalance", + inputs: [], + }, + { + type: "error", + name: "UintUtils__InsufficientPadding", + inputs: [], + }, + { + type: "error", + name: "UintUtils__InvalidBase", + inputs: [], + }, + ], + inheritedFunctions: { + owner: "lib/reputation/lib/solidstate-solidity/contracts/access/ownable/Ownable.sol", + transferOwnership: "lib/reputation/lib/solidstate-solidity/contracts/access/ownable/Ownable.sol", + MINTER_ROLE: "lib/reputation/contracts/ReputationTokensBase.sol", + TOKEN_MIGRATOR_ROLE: "lib/reputation/contracts/ReputationTokensBase.sol", + TOKEN_UPDATER_ROLE: "lib/reputation/contracts/ReputationTokensBase.sol", + TOKEN_URI_SETTER_ROLE: "lib/reputation/contracts/ReputationTokensBase.sol", + accountsByToken: "lib/reputation/contracts/ReputationTokensBase.sol", + balanceOf: "lib/reputation/contracts/ReputationTokensBase.sol", + balanceOfBatch: "lib/reputation/contracts/ReputationTokensBase.sol", + burnedBalanceOf: "lib/reputation/contracts/ReputationTokensBase.sol", + distributableBalanceOf: "lib/reputation/contracts/ReputationTokensBase.sol", + distribute: "lib/reputation/contracts/ReputationTokensBase.sol", + distributeBatch: "lib/reputation/contracts/ReputationTokensBase.sol", + getRoleAdmin: "lib/reputation/contracts/ReputationTokensBase.sol", + getRoleMember: "lib/reputation/contracts/ReputationTokensBase.sol", + getRoleMemberCount: "lib/reputation/contracts/ReputationTokensBase.sol", + getTokenType: "lib/reputation/contracts/ReputationTokensBase.sol", + grantRole: "lib/reputation/contracts/ReputationTokensBase.sol", + hasRole: "lib/reputation/contracts/ReputationTokensBase.sol", + honestBalanceOf: "lib/reputation/contracts/ReputationTokensBase.sol", + isApprovedForAll: "lib/reputation/contracts/ReputationTokensBase.sol", + migrate: "lib/reputation/contracts/ReputationTokensBase.sol", + migrateBatch: "lib/reputation/contracts/ReputationTokensBase.sol", + mint: "lib/reputation/contracts/ReputationTokensBase.sol", + mintBatch: "lib/reputation/contracts/ReputationTokensBase.sol", + renounceRole: "lib/reputation/contracts/ReputationTokensBase.sol", + revokeRole: "lib/reputation/contracts/ReputationTokensBase.sol", + safeBatchTransferFrom: "lib/reputation/contracts/ReputationTokensBase.sol", + safeTransferFrom: "lib/reputation/contracts/ReputationTokensBase.sol", + setApprovalForAll: "lib/reputation/contracts/ReputationTokensBase.sol", + setBatchTokenURI: "lib/reputation/contracts/ReputationTokensBase.sol", + setTokenURI: "lib/reputation/contracts/ReputationTokensBase.sol", + supportsInterface: "lib/reputation/contracts/ReputationTokensBase.sol", + tokensByAccount: "lib/reputation/contracts/ReputationTokensBase.sol", + totalHolders: "lib/reputation/contracts/ReputationTokensBase.sol", + totalSupply: "lib/reputation/contracts/ReputationTokensBase.sol", + updateToken: "lib/reputation/contracts/ReputationTokensBase.sol", + updateTokenBatch: "lib/reputation/contracts/ReputationTokensBase.sol", + uri: "lib/reputation/contracts/ReputationTokensBase.sol", + }, + }, + ReputationTokensFactory: { + address: "0x84eA74d481Ee0A5332c457a4d796187F6Ba67fEB", + abi: [ + { + type: "constructor", + inputs: [ + { + name: "_admins", + type: "address[]", + internalType: "address[]", + }, + { + name: "_controllers", + type: "address[]", + internalType: "address[]", + }, + { + name: "_implementation", + type: "address", + internalType: "address", + }, + ], + stateMutability: "nonpayable", + }, + { + type: "function", + name: "DEFAULT_ADMIN_ROLE", + inputs: [], + outputs: [ + { + name: "", + type: "bytes32", + internalType: "bytes32", + }, + ], + stateMutability: "view", + }, + { + type: "function", + name: "DEPLOYER_ROLE", + inputs: [], + outputs: [ + { + name: "", + type: "bytes32", + internalType: "bytes32", + }, + ], + stateMutability: "view", + }, + { + type: "function", + name: "contractInstanceCount", + inputs: [], + outputs: [ + { + name: "", + type: "uint256", + internalType: "uint256", + }, + ], + stateMutability: "view", + }, + { + type: "function", + name: "createNewInstance", + inputs: [ + { + name: "owner", + type: "address", + internalType: "address", + }, + { + name: "admins", + type: "address[]", + internalType: "address[]", + }, + ], + outputs: [ + { + name: "instanceAddress", + type: "address", + internalType: "address", + }, + ], + stateMutability: "nonpayable", + }, + { + type: "function", + name: "getRoleAdmin", + inputs: [ + { + name: "role", + type: "bytes32", + internalType: "bytes32", + }, + ], + outputs: [ + { + name: "", + type: "bytes32", + internalType: "bytes32", + }, + ], + stateMutability: "view", + }, + { + type: "function", + name: "grantRole", + inputs: [ + { + name: "role", + type: "bytes32", + internalType: "bytes32", + }, + { + name: "account", + type: "address", + internalType: "address", + }, + ], + outputs: [], + stateMutability: "nonpayable", + }, + { + type: "function", + name: "hasRole", + inputs: [ + { + name: "role", + type: "bytes32", + internalType: "bytes32", + }, + { + name: "account", + type: "address", + internalType: "address", + }, + ], + outputs: [ + { + name: "", + type: "bool", + internalType: "bool", + }, + ], + stateMutability: "view", + }, + { + type: "function", + name: "implementation", + inputs: [], + outputs: [ + { + name: "", + type: "address", + internalType: "address", + }, + ], + stateMutability: "view", + }, + { + type: "function", + name: "instances", + inputs: [ + { + name: "", + type: "uint256", + internalType: "uint256", + }, + ], + outputs: [ + { + name: "", + type: "address", + internalType: "contract ReputationTokensUpgradeable", + }, + ], + stateMutability: "view", + }, + { + type: "function", + name: "renounceRole", + inputs: [ + { + name: "role", + type: "bytes32", + internalType: "bytes32", + }, + { + name: "callerConfirmation", + type: "address", + internalType: "address", + }, + ], + outputs: [], + stateMutability: "nonpayable", + }, + { + type: "function", + name: "revokeRole", + inputs: [ + { + name: "role", + type: "bytes32", + internalType: "bytes32", + }, + { + name: "account", + type: "address", + internalType: "address", + }, + ], + outputs: [], + stateMutability: "nonpayable", + }, + { + type: "function", + name: "supportsInterface", + inputs: [ + { + name: "interfaceId", + type: "bytes4", + internalType: "bytes4", + }, + ], + outputs: [ + { + name: "", + type: "bool", + internalType: "bool", + }, + ], + stateMutability: "view", + }, + { + type: "event", + name: "CreatedNewInstance", + inputs: [ + { + name: "", + type: "address", + indexed: false, + internalType: "address", + }, + ], + anonymous: false, + }, + { + type: "event", + name: "RoleAdminChanged", + inputs: [ + { + name: "role", + type: "bytes32", + indexed: true, + internalType: "bytes32", + }, + { + name: "previousAdminRole", + type: "bytes32", + indexed: true, + internalType: "bytes32", + }, + { + name: "newAdminRole", + type: "bytes32", + indexed: true, + internalType: "bytes32", + }, + ], + anonymous: false, + }, + { + type: "event", + name: "RoleGranted", + inputs: [ + { + name: "role", + type: "bytes32", + indexed: true, + internalType: "bytes32", + }, + { + name: "account", + type: "address", + indexed: true, + internalType: "address", + }, + { + name: "sender", + type: "address", + indexed: true, + internalType: "address", + }, + ], + anonymous: false, + }, + { + type: "event", + name: "RoleRevoked", + inputs: [ + { + name: "role", + type: "bytes32", + indexed: true, + internalType: "bytes32", + }, + { + name: "account", + type: "address", + indexed: true, + internalType: "address", + }, + { + name: "sender", + type: "address", + indexed: true, + internalType: "address", + }, + ], + anonymous: false, + }, + { + type: "error", + name: "AccessControlBadConfirmation", + inputs: [], + }, + { + type: "error", + name: "AccessControlUnauthorizedAccount", + inputs: [ + { + name: "account", + type: "address", + internalType: "address", + }, + { + name: "neededRole", + type: "bytes32", + internalType: "bytes32", + }, + ], + }, + { + type: "error", + name: "ERC1167FailedCreateClone", + inputs: [], + }, + ], + inheritedFunctions: { + DEFAULT_ADMIN_ROLE: "lib/openzeppelin-contracts/contracts/access/AccessControl.sol", + getRoleAdmin: "lib/openzeppelin-contracts/contracts/access/AccessControl.sol", + grantRole: "lib/openzeppelin-contracts/contracts/access/AccessControl.sol", + hasRole: "lib/openzeppelin-contracts/contracts/access/AccessControl.sol", + renounceRole: "lib/openzeppelin-contracts/contracts/access/AccessControl.sol", + revokeRole: "lib/openzeppelin-contracts/contracts/access/AccessControl.sol", + supportsInterface: "lib/openzeppelin-contracts/contracts/access/AccessControl.sol", + }, + }, }, } as const; diff --git a/packages/nextjs/scaffold.config.ts b/packages/nextjs/scaffold.config.ts index c0c07cb..7870ecc 100644 --- a/packages/nextjs/scaffold.config.ts +++ b/packages/nextjs/scaffold.config.ts @@ -10,7 +10,7 @@ export type ScaffoldConfig = { const scaffoldConfig = { // The networks on which your DApp is live - targetNetworks: [chains.optimism], + targetNetworks: [chains.foundry], // The interval at which your front-end polls the RPC servers for new data // it has no effect if you only target the local network (default is 4000)