Skip to content
Merged
Show file tree
Hide file tree
Changes from 8 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ export const ContractTabs = ({ address, contractData }: PageProps) => {

useEffect(() => {
const checkIsContract = async () => {
const contractCode = await publicClient.getBytecode({ address: address });
const contractCode = await publicClient.getCode({ address: address });
setIsContract(contractCode !== undefined && contractCode !== "0x");
};

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ export const SearchBar = () => {

const client = usePublicClient({ chainId: hardhat.id });

const handleSearch = async (event: React.FormEvent) => {
const handleSearch = async (event: React.SubmitEvent) => {
event.preventDefault();
if (isHex(searchInput)) {
try {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import { getAddress } from "viem";
import { Address } from "viem";
import { useAccount, useDisconnect } from "wagmi";
import {
ArrowLeftOnRectangleIcon,
ArrowLeftEndOnRectangleIcon,
ArrowTopRightOnSquareIcon,
ArrowsRightLeftIcon,
CheckCircleIcon,
Expand Down Expand Up @@ -127,7 +127,7 @@ export const AddressInfoDropdown = ({
type="button"
onClick={() => disconnect()}
>
<ArrowLeftOnRectangleIcon className="h-6 w-4 ml-2 sm:ml-0" /> <span>Disconnect</span>
<ArrowLeftEndOnRectangleIcon className="h-6 w-4 ml-2 sm:ml-0" /> <span>Disconnect</span>
</button>
</li>
</ul>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { NetworkOptions } from "./NetworkOptions";
import { useDisconnect } from "wagmi";
import { ArrowLeftOnRectangleIcon, ChevronDownIcon } from "@heroicons/react/24/outline";
import { ArrowLeftEndOnRectangleIcon, ChevronDownIcon } from "@heroicons/react/24/outline";

export const WrongNetworkDropdown = () => {
const { disconnect } = useDisconnect();
Expand All @@ -15,7 +15,7 @@ export const WrongNetworkDropdown = () => {
<NetworkOptions />
<li>
<button className="menu-item text-error btn-sm flex gap-3 py-3" type="button" onClick={() => disconnect()}>
<ArrowLeftOnRectangleIcon className="h-6 w-4 ml-2 sm:ml-0" />
<ArrowLeftEndOnRectangleIcon className="h-6 w-4 ml-2 sm:ml-0" />
<span>Disconnect</span>
</button>
</li>
Expand Down
12 changes: 12 additions & 0 deletions packages/nextjs/eslint.config.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -25,4 +25,16 @@ export default defineConfig([
},
ignores: [".next", "next-env.d.ts"],
},
{
files: ["**/*.ts", "**/*.tsx"],
languageOptions: {
parserOptions: {
projectService: true,
tsconfigRootDir: import.meta.dirname,
},
},
rules: {
"@typescript-eslint/no-deprecated": "warn",
},
},
]);
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ export function useDeployedContractInfo<TContractName extends ContractName>(
return;
}

const code = await publicClient.getBytecode({
const code = await publicClient.getCode({
address: deployedContract.address,
});

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ import {
} from "~~/utils/scaffold-eth/contract";

/**
* Wrapper around wagmi's useContractRead hook which automatically loads (by name) the contract ABI and address from
* Wrapper around wagmi's useReadContract hook which automatically loads (by name) the contract ABI and address from
* the contracts present in deployedContracts.ts & externalContracts.ts corresponding to targetNetworks configured in scaffold.config.ts
* @param config - The config settings, including extra wagmi configuration
* @param config.contractName - deployed contract name
Expand Down
10 changes: 5 additions & 5 deletions packages/nextjs/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,14 +17,14 @@
},
"dependencies": {
"@heroicons/react": "^2.2.0",
"@rainbow-me/rainbowkit": "2.2.9",
"@rainbow-me/rainbowkit": "2.2.11",
"@react-native-async-storage/async-storage": "^2.2.0",
"@scaffold-ui/components": "^0.1.12",
"@scaffold-ui/debug-contracts": "^0.1.11",
"@scaffold-ui/hooks": "^0.1.8",
"@tanstack/react-query": "^5.59.15",
"@tanstack/react-query": "^5.100.5",
"blo": "^2.0.0",
"burner-connector": "0.0.20",
"burner-connector": "0.0.21",
"daisyui": "^5.5.19",
"kubo-rpc-client": "^6.1.0",
"next": "^16.2.4",
Expand All @@ -35,7 +35,7 @@
"react-dom": "^19.2.5",
"react-hot-toast": "^2.6.0",
"usehooks-ts": "^3.1.1",
"viem": "2.39.0",
"viem": "2.53.1",
"wagmi": "2.19.5",
"zustand": "^5.0.12"
},
Expand All @@ -44,7 +44,7 @@
"@trivago/prettier-plugin-sort-imports": "^6.0.2",
"@types/node": "^18.19.130",
"@types/react": "^19.2.14",
"abitype": "1.0.6",
"abitype": "1.2.4",
"bgipfs": "^0.0.18",
"eslint": "^9.39.0",
"eslint-config-next": "^16.2.4",
Expand Down
4 changes: 2 additions & 2 deletions packages/nextjs/services/web3/wagmiConnectors.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { connectorsForWallets } from "@rainbow-me/rainbowkit";
import {
baseAccount,
base,
ledgerWallet,
metaMaskWallet,
rainbowWallet,
Expand All @@ -21,7 +21,7 @@ const wallets = [
metaMaskWallet,
walletConnectWallet,
ledgerWallet,
baseAccount,
base,
rainbowWallet,
safeWallet,
...(showBurnerWallet ? [rainbowkitBurnerWallet] : []),
Expand Down
Loading
Loading