From 956ffe80e74ca1dbeb7ae420e7001bc2ae38507d Mon Sep 17 00:00:00 2001 From: phipsae Date: Fri, 20 Dec 2024 07:13:47 +0100 Subject: [PATCH 1/2] update ABI, update address PixelCanvas to external contract --- .../nextjs/contracts/externalContracts.ts | 32 ++++++++++++++++++- 1 file changed, 31 insertions(+), 1 deletion(-) diff --git a/packages/nextjs/contracts/externalContracts.ts b/packages/nextjs/contracts/externalContracts.ts index edf87fd..3df8164 100644 --- a/packages/nextjs/contracts/externalContracts.ts +++ b/packages/nextjs/contracts/externalContracts.ts @@ -806,7 +806,7 @@ const externalContracts = { ], }, PixelCanvas: { - address: "0x54c92BB9f6c3d3416c22070bcD5678cfF57784B4", + address: "0x12961542E5Aa59541F2a7bFeF3F504A406AfC946", abi: [ { inputs: [], @@ -968,6 +968,36 @@ const externalContracts = { stateMutability: "view", type: "function", }, + { + inputs: [], + name: "getFullCanvas", + outputs: [ + { + components: [ + { + internalType: "address", + name: "author", + type: "address", + }, + { + internalType: "enum PixelCanvas.Color", + name: "color", + type: "uint8", + }, + { + internalType: "uint256", + name: "timestamp", + type: "uint256", + }, + ], + internalType: "struct PixelCanvas.Pixel[][]", + name: "", + type: "tuple[][]", + }, + ], + stateMutability: "view", + type: "function", + }, { inputs: [ { From e322b0be0017282bcea6ae1ebda5bdad348f79f7 Mon Sep 17 00:00:00 2001 From: phipsae Date: Fri, 20 Dec 2024 07:37:10 +0100 Subject: [PATCH 2/2] reset deployedContract.ts --- .../nextjs/contracts/deployedContracts.ts | 911 +----------------- 1 file changed, 1 insertion(+), 910 deletions(-) diff --git a/packages/nextjs/contracts/deployedContracts.ts b/packages/nextjs/contracts/deployedContracts.ts index 3c0b676..008d4eb 100644 --- a/packages/nextjs/contracts/deployedContracts.ts +++ b/packages/nextjs/contracts/deployedContracts.ts @@ -4,915 +4,6 @@ */ import { GenericContractsDeclaration } from "~~/utils/scaffold-eth/contract"; -const deployedContracts = { - 10: { - GilCheckin: { - address: "0xF96b0CbbD51513A7FB95960D0ac32e7A07990849", - abi: [ - { - inputs: [ - { - internalType: "address payable", - name: "_batchRegistry", - type: "address", - }, - ], - stateMutability: "nonpayable", - type: "constructor", - }, - { - inputs: [ - { - internalType: "address", - name: "owner", - type: "address", - }, - ], - name: "OwnableInvalidOwner", - type: "error", - }, - { - inputs: [ - { - internalType: "address", - name: "account", - type: "address", - }, - ], - name: "OwnableUnauthorizedAccount", - type: "error", - }, - { - anonymous: false, - inputs: [ - { - indexed: true, - internalType: "address", - name: "previousOwner", - type: "address", - }, - { - indexed: true, - internalType: "address", - name: "newOwner", - type: "address", - }, - ], - name: "OwnershipTransferred", - type: "event", - }, - { - stateMutability: "payable", - type: "fallback", - }, - { - inputs: [], - name: "batchRegistry", - outputs: [ - { - internalType: "contract BatchRegistry", - name: "", - type: "address", - }, - ], - stateMutability: "view", - type: "function", - }, - { - inputs: [], - name: "checkIn", - outputs: [], - stateMutability: "nonpayable", - type: "function", - }, - { - inputs: [], - name: "owner", - outputs: [ - { - internalType: "address", - name: "", - type: "address", - }, - ], - stateMutability: "view", - type: "function", - }, - { - inputs: [], - name: "renounceOwnership", - outputs: [], - stateMutability: "nonpayable", - type: "function", - }, - { - inputs: [ - { - internalType: "address", - name: "newOwner", - type: "address", - }, - ], - name: "transferOwnership", - outputs: [], - stateMutability: "nonpayable", - type: "function", - }, - { - inputs: [], - name: "withdraw", - outputs: [], - stateMutability: "nonpayable", - type: "function", - }, - { - stateMutability: "payable", - type: "receive", - }, - ], - inheritedFunctions: { - owner: "@openzeppelin/contracts/access/Ownable.sol", - renounceOwnership: "@openzeppelin/contracts/access/Ownable.sol", - transferOwnership: "@openzeppelin/contracts/access/Ownable.sol", - }, - }, - }, - 31337: { - BatchRegistry: { - address: "0x5FbDB2315678afecb367f032d93F642f64180aa3", - abi: [ - { - inputs: [ - { - internalType: "address", - name: "initialOwner", - type: "address", - }, - { - internalType: "uint16", - name: "batchNumber", - type: "uint16", - }, - ], - stateMutability: "nonpayable", - type: "constructor", - }, - { - inputs: [], - name: "AlreadyGraduated", - type: "error", - }, - { - inputs: [], - name: "BatchNotOpen", - type: "error", - }, - { - inputs: [], - name: "GraduationClosed", - type: "error", - }, - { - inputs: [], - name: "NotAContract", - type: "error", - }, - { - inputs: [], - name: "NotCheckedIn", - type: "error", - }, - { - inputs: [], - name: "NotInAllowList", - type: "error", - }, - { - inputs: [ - { - internalType: "address", - name: "owner", - type: "address", - }, - ], - name: "OwnableInvalidOwner", - type: "error", - }, - { - inputs: [ - { - internalType: "address", - name: "account", - type: "address", - }, - ], - name: "OwnableUnauthorizedAccount", - type: "error", - }, - { - anonymous: false, - inputs: [ - { - indexed: false, - internalType: "bool", - name: "first", - type: "bool", - }, - { - indexed: false, - internalType: "address", - name: "builder", - type: "address", - }, - { - indexed: false, - internalType: "address", - name: "checkInContract", - type: "address", - }, - ], - name: "CheckedIn", - type: "event", - }, - { - anonymous: false, - inputs: [ - { - indexed: true, - internalType: "address", - name: "previousOwner", - type: "address", - }, - { - indexed: true, - internalType: "address", - name: "newOwner", - type: "address", - }, - ], - name: "OwnershipTransferred", - type: "event", - }, - { - inputs: [], - name: "BATCH_NUMBER", - outputs: [ - { - internalType: "uint16", - name: "", - type: "uint16", - }, - ], - stateMutability: "view", - type: "function", - }, - { - inputs: [ - { - internalType: "address", - name: "", - type: "address", - }, - ], - name: "allowList", - outputs: [ - { - internalType: "bool", - name: "", - type: "bool", - }, - ], - stateMutability: "view", - type: "function", - }, - { - inputs: [], - name: "batchGraduationNFT", - outputs: [ - { - internalType: "contract BatchGraduationNFT", - name: "", - type: "address", - }, - ], - stateMutability: "view", - type: "function", - }, - { - inputs: [], - name: "checkIn", - outputs: [], - stateMutability: "nonpayable", - type: "function", - }, - { - inputs: [], - name: "checkedInCounter", - outputs: [ - { - internalType: "uint256", - name: "", - type: "uint256", - }, - ], - stateMutability: "view", - type: "function", - }, - { - inputs: [], - name: "graduate", - outputs: [], - stateMutability: "nonpayable", - type: "function", - }, - { - inputs: [ - { - internalType: "address", - name: "", - type: "address", - }, - ], - name: "graduatedTokenId", - outputs: [ - { - internalType: "uint256", - name: "", - type: "uint256", - }, - ], - stateMutability: "view", - type: "function", - }, - { - inputs: [], - name: "graduationOpen", - outputs: [ - { - internalType: "bool", - name: "", - type: "bool", - }, - ], - stateMutability: "view", - type: "function", - }, - { - inputs: [], - name: "isOpen", - outputs: [ - { - internalType: "bool", - name: "", - type: "bool", - }, - ], - stateMutability: "view", - type: "function", - }, - { - inputs: [], - name: "owner", - outputs: [ - { - internalType: "address", - name: "", - type: "address", - }, - ], - stateMutability: "view", - type: "function", - }, - { - inputs: [], - name: "renounceOwnership", - outputs: [], - stateMutability: "nonpayable", - type: "function", - }, - { - inputs: [], - name: "toggleBatchOpenStatus", - outputs: [], - stateMutability: "nonpayable", - type: "function", - }, - { - inputs: [], - name: "toggleGraduationOpenStatus", - outputs: [], - stateMutability: "nonpayable", - type: "function", - }, - { - inputs: [ - { - internalType: "address", - name: "newOwner", - type: "address", - }, - ], - name: "transferOwnership", - outputs: [], - stateMutability: "nonpayable", - type: "function", - }, - { - inputs: [ - { - internalType: "address[]", - name: "builders", - type: "address[]", - }, - { - internalType: "bool[]", - name: "statuses", - type: "bool[]", - }, - ], - name: "updateAllowList", - outputs: [], - stateMutability: "nonpayable", - type: "function", - }, - { - inputs: [], - name: "withdraw", - outputs: [], - stateMutability: "nonpayable", - type: "function", - }, - { - inputs: [ - { - internalType: "address", - name: "", - type: "address", - }, - ], - name: "yourContractAddress", - outputs: [ - { - internalType: "address", - name: "", - type: "address", - }, - ], - stateMutability: "view", - type: "function", - }, - { - stateMutability: "payable", - type: "receive", - }, - ], - inheritedFunctions: { - owner: "@openzeppelin/contracts/access/Ownable.sol", - renounceOwnership: "@openzeppelin/contracts/access/Ownable.sol", - transferOwnership: "@openzeppelin/contracts/access/Ownable.sol", - }, - }, - PixelCanvas: { - address: "0xe7f1725E7734CE288F8367e1Bb143E90bb3F0512", - abi: [ - { - inputs: [], - stateMutability: "nonpayable", - type: "constructor", - }, - { - inputs: [ - { - internalType: "address", - name: "owner", - type: "address", - }, - ], - name: "OwnableInvalidOwner", - type: "error", - }, - { - inputs: [ - { - internalType: "address", - name: "account", - type: "address", - }, - ], - name: "OwnableUnauthorizedAccount", - type: "error", - }, - { - anonymous: false, - inputs: [ - { - indexed: true, - internalType: "address", - name: "previousOwner", - type: "address", - }, - { - indexed: true, - internalType: "address", - name: "newOwner", - type: "address", - }, - ], - name: "OwnershipTransferred", - type: "event", - }, - { - anonymous: false, - inputs: [ - { - indexed: true, - internalType: "address", - name: "author", - type: "address", - }, - { - indexed: false, - internalType: "uint256", - name: "x", - type: "uint256", - }, - { - indexed: false, - internalType: "uint256", - name: "y", - type: "uint256", - }, - { - indexed: false, - internalType: "enum PixelCanvas.Color", - name: "color", - type: "uint8", - }, - ], - name: "PixelPlaced", - type: "event", - }, - { - anonymous: false, - inputs: [ - { - indexed: true, - internalType: "address", - name: "owner", - type: "address", - }, - { - indexed: false, - internalType: "uint256", - name: "amount", - type: "uint256", - }, - ], - name: "Withdrawal", - type: "event", - }, - { - stateMutability: "payable", - type: "fallback", - }, - { - inputs: [], - name: "CANVAS_HEIGHT", - outputs: [ - { - internalType: "uint256", - name: "", - type: "uint256", - }, - ], - stateMutability: "view", - type: "function", - }, - { - inputs: [], - name: "CANVAS_WIDTH", - outputs: [ - { - internalType: "uint256", - name: "", - type: "uint256", - }, - ], - stateMutability: "view", - type: "function", - }, - { - inputs: [ - { - internalType: "uint256", - name: "", - type: "uint256", - }, - { - internalType: "uint256", - name: "", - type: "uint256", - }, - ], - name: "canvas", - outputs: [ - { - internalType: "address", - name: "author", - type: "address", - }, - { - internalType: "enum PixelCanvas.Color", - name: "color", - type: "uint8", - }, - { - internalType: "uint256", - name: "timestamp", - type: "uint256", - }, - ], - stateMutability: "view", - type: "function", - }, - { - inputs: [], - name: "getFullCanvas", - outputs: [ - { - components: [ - { - internalType: "address", - name: "author", - type: "address", - }, - { - internalType: "enum PixelCanvas.Color", - name: "color", - type: "uint8", - }, - { - internalType: "uint256", - name: "timestamp", - type: "uint256", - }, - ], - internalType: "struct PixelCanvas.Pixel[][]", - name: "", - type: "tuple[][]", - }, - ], - stateMutability: "view", - type: "function", - }, - { - inputs: [ - { - internalType: "uint256", - name: "x", - type: "uint256", - }, - { - internalType: "uint256", - name: "y", - type: "uint256", - }, - ], - name: "getPixel", - outputs: [ - { - components: [ - { - internalType: "address", - name: "author", - type: "address", - }, - { - internalType: "enum PixelCanvas.Color", - name: "color", - type: "uint8", - }, - { - internalType: "uint256", - name: "timestamp", - type: "uint256", - }, - ], - internalType: "struct PixelCanvas.Pixel", - name: "", - type: "tuple", - }, - ], - stateMutability: "view", - type: "function", - }, - { - inputs: [], - name: "owner", - outputs: [ - { - internalType: "address", - name: "", - type: "address", - }, - ], - stateMutability: "view", - type: "function", - }, - { - inputs: [ - { - internalType: "uint256", - name: "x", - type: "uint256", - }, - { - internalType: "uint256", - name: "y", - type: "uint256", - }, - { - internalType: "enum PixelCanvas.Color", - name: "color", - type: "uint8", - }, - ], - name: "placePixel", - outputs: [], - stateMutability: "nonpayable", - type: "function", - }, - { - inputs: [], - name: "renounceOwnership", - outputs: [], - stateMutability: "nonpayable", - type: "function", - }, - { - inputs: [ - { - internalType: "address", - name: "newOwner", - type: "address", - }, - ], - name: "transferOwnership", - outputs: [], - stateMutability: "nonpayable", - type: "function", - }, - { - inputs: [], - name: "withdraw", - outputs: [], - stateMutability: "nonpayable", - type: "function", - }, - { - stateMutability: "payable", - type: "receive", - }, - ], - inheritedFunctions: { - owner: "@openzeppelin/contracts/access/Ownable.sol", - renounceOwnership: "@openzeppelin/contracts/access/Ownable.sol", - transferOwnership: "@openzeppelin/contracts/access/Ownable.sol", - }, - }, - }, - 11155420: { - GilCheckin: { - address: "0xdeBc123Fa83E91B15C27f54A2e7eaeEdAd676f85", - abi: [ - { - inputs: [ - { - internalType: "address payable", - name: "_batchRegistry", - type: "address", - }, - ], - stateMutability: "nonpayable", - type: "constructor", - }, - { - inputs: [ - { - internalType: "address", - name: "owner", - type: "address", - }, - ], - name: "OwnableInvalidOwner", - type: "error", - }, - { - inputs: [ - { - internalType: "address", - name: "account", - type: "address", - }, - ], - name: "OwnableUnauthorizedAccount", - type: "error", - }, - { - anonymous: false, - inputs: [ - { - indexed: true, - internalType: "address", - name: "previousOwner", - type: "address", - }, - { - indexed: true, - internalType: "address", - name: "newOwner", - type: "address", - }, - ], - name: "OwnershipTransferred", - type: "event", - }, - { - stateMutability: "payable", - type: "fallback", - }, - { - inputs: [], - name: "batchRegistry", - outputs: [ - { - internalType: "contract BatchRegistry", - name: "", - type: "address", - }, - ], - stateMutability: "view", - type: "function", - }, - { - inputs: [], - name: "checkIn", - outputs: [], - stateMutability: "nonpayable", - type: "function", - }, - { - inputs: [], - name: "owner", - outputs: [ - { - internalType: "address", - name: "", - type: "address", - }, - ], - stateMutability: "view", - type: "function", - }, - { - inputs: [], - name: "renounceOwnership", - outputs: [], - stateMutability: "nonpayable", - type: "function", - }, - { - inputs: [ - { - internalType: "address", - name: "newOwner", - type: "address", - }, - ], - name: "transferOwnership", - outputs: [], - stateMutability: "nonpayable", - type: "function", - }, - { - inputs: [], - name: "withdraw", - outputs: [], - stateMutability: "nonpayable", - type: "function", - }, - { - stateMutability: "payable", - type: "receive", - }, - ], - inheritedFunctions: { - owner: "@openzeppelin/contracts/access/Ownable.sol", - renounceOwnership: "@openzeppelin/contracts/access/Ownable.sol", - transferOwnership: "@openzeppelin/contracts/access/Ownable.sol", - }, - }, - }, -} as const; +const deployedContracts = {} as const; export default deployedContracts satisfies GenericContractsDeclaration;