Skip to content

Commit

Permalink
Revert "removed factory and reputation.vision implementation"
Browse files Browse the repository at this point in the history
This reverts commit 46da1f0.
  • Loading branch information
JacobHomanics committed Jun 25, 2024
1 parent 3b52beb commit 1617c80
Show file tree
Hide file tree
Showing 6 changed files with 2,110 additions and 310 deletions.
5 changes: 3 additions & 2 deletions packages/foundry/script/Deploy.s.sol
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,9 @@ contract DeployScript is ScaffoldETHDeploy {
DeployDemoScript deployer = new DeployDemoScript();
deployer.run();

// DeployFactoryScript factoryDeployer = new DeployFactoryScript();
// factoryDeployer.run();
DeployFactoryScript factoryDeployer = new DeployFactoryScript();

factoryDeployer.run();
exportDeployments();
}

Expand Down
116 changes: 58 additions & 58 deletions packages/nextjs/app/collections/[network]/[address]/page.tsx
Original file line number Diff line number Diff line change
@@ -1,58 +1,58 @@
// "use client";

// import React from "react";
// //, { useEffect }
// import { useState } from "react";
// import { useAccount } from "wagmi";
// // import "react-dropdown/style.css";
// import { Collection } from "~~/components/scaffold-nft/collection/Collection";
// // import useAdvancedFiltering from "~~/hooks/scaffold-nft/useAdvancedFiltering";
// // import useCheckboxes from "~~/hooks/scaffold-nft/useCheckboxes";
// // import useTokenIds from "~~/hooks/scaffold-nft/useTokenIds";
// import { useTokens } from "~~/hooks/scaffold-nft/useTokens";

// // import { renderInputOptions } from "~~/scaffold-nft-config";

// export default function CollectionPage({ params }: { params: { network: string; address: string } }) {
// // const { inputComponents, componentsToRender } = useCheckboxes(renderInputOptions);

// const userAccount = useAccount();

// // const { tokenIds, setTokenIds } = useTokenIds(2);
// // async function onSubmit(newIds: bigint[]) {
// // setTokenIds([...newIds]);
// // }

// // const tokenIds = [BigInt(0), BigInt(1)];

// const [tokenIds] = useState<bigint[]>([BigInt(0), BigInt(1)]);

// // const {
// // chosenOption,
// // // chosenOption2,
// // output: advancedOutput,
// // } = useAdvancedFiltering(inputComponents, onSubmit);

// const { collection, isLoading, isError } = useTokens(
// params["network"],
// params["address"],
// userAccount.address,
// tokenIds,
// "nftstorage",
// //chosenOption2,
// );

// console.log(collection);

// return (
// <div className="flex flex-col items-center justify-center">
// {/* {advancedOutput} */}
// <Collection
// collection={collection}
// isLoading={isLoading}
// isError={isError}
// renderOrder={["Balance", "Image", "Token Id", "Name", "Description", "Type", "Attributes"]}
// />
// </div>
// );
// }
"use client";

import React from "react";
//, { useEffect }
import { useState } from "react";
import { useAccount } from "wagmi";
// import "react-dropdown/style.css";
import { Collection } from "~~/components/scaffold-nft/collection/Collection";
// import useAdvancedFiltering from "~~/hooks/scaffold-nft/useAdvancedFiltering";
// import useCheckboxes from "~~/hooks/scaffold-nft/useCheckboxes";
// import useTokenIds from "~~/hooks/scaffold-nft/useTokenIds";
import { useTokens } from "~~/hooks/scaffold-nft/useTokens";

// import { renderInputOptions } from "~~/scaffold-nft-config";

export default function CollectionPage({ params }: { params: { network: string; address: string } }) {
// const { inputComponents, componentsToRender } = useCheckboxes(renderInputOptions);

const userAccount = useAccount();

// const { tokenIds, setTokenIds } = useTokenIds(2);
// async function onSubmit(newIds: bigint[]) {
// setTokenIds([...newIds]);
// }

// const tokenIds = [BigInt(0), BigInt(1)];

const [tokenIds] = useState<bigint[]>([BigInt(0), BigInt(1)]);

// const {
// chosenOption,
// // chosenOption2,
// output: advancedOutput,
// } = useAdvancedFiltering(inputComponents, onSubmit);

const { collection, isLoading, isError } = useTokens(
params["network"],
params["address"],
userAccount.address,
tokenIds,
"nftstorage",
//chosenOption2,
);

console.log(collection);

return (
<div className="flex flex-col items-center justify-center">
{/* {advancedOutput} */}
<Collection
collection={collection}
isLoading={isLoading}
isError={isError}
renderOrder={["Balance", "Image", "Token Id", "Name", "Description", "Type", "Attributes"]}
/>
</div>
);
}
Loading

0 comments on commit 1617c80

Please sign in to comment.