This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| "use client"; | |
| import { | |
| useReadContract, | |
| useWriteContract, | |
| useSwitchChain, | |
| usePublicClient, | |
| useChainId, | |
| } from "wagmi"; | |
| import { baseSepolia } from "wagmi/chains"; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| "use client"; | |
| import { useState, useEffect } from "react"; | |
| import { useParams } from "next/navigation"; | |
| import { DynamicWidget, useDynamicContext } from "@dynamic-labs/sdk-react-core"; | |
| import { escrowAbi, ESCROW_ADDRESS } from "../../lib/constants"; | |
| import { useTransaction, formatBalance, formatAddress } from "../../lib/hooks"; | |
| import Link from "next/link"; | |
| export default function ClaimPage() { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| "use client"; | |
| import { useState, useMemo } from "react"; | |
| import { DynamicWidget, useDynamicContext } from "@dynamic-labs/sdk-react-core"; | |
| import { keccak256, toBytes } from "viem"; | |
| import Link from "next/link"; | |
| import { | |
| escrowAbi, | |
| ESCROW_ADDRESS, | |
| USDC_ADDRESS, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| "use client"; | |
| import { useState } from "react"; | |
| import { DynamicWidget, useDynamicContext } from "@dynamic-labs/sdk-react-core"; | |
| import Link from "next/link"; | |
| import { USDC_ADDRESS, usdcAbi } from "./lib/constants"; | |
| import { useTokenBalance, useTransaction } from "./lib/hooks"; | |
| export default function Home() { | |
| const { user, primaryWallet } = useDynamicContext(); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| export const ESCROW_ADDRESS = | |
| "0x7f66b65b54267f837cf139054552e0ab3ce23e33" as const; | |
| export const USDC_ADDRESS = | |
| "0xa2ad4ca7752f93d823c6397f6e0a15ac51a63deb" as const; | |
| export const usdcAbi = [ | |
| { type: "constructor", inputs: [], stateMutability: "nonpayable" }, | |
| { | |
| type: "function", | |
| name: "allowance", |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| "use client"; | |
| import { useState } from "react"; | |
| export default function Login() { | |
| const [email, setEmail] = useState(""); | |
| const [password, setPassword] = useState(""); | |
| const [loading, setLoading] = useState(false); | |
| const [mode, setMode] = useState("signin"); // 'signin' or 'signup' | |
| const [message, setMessage] = useState(""); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| "use client"; | |
| import { useState } from "react"; | |
| export default function Home() { | |
| const [imageUrl, setImageUrl] = useState(""); | |
| const [uploading, setUploading] = useState(false); | |
| const [images, setImages] = useState([]); | |
| const [copySuccess, setCopySuccess] = useState(""); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // SPDX-License-Identifier: MIT | |
| pragma solidity ^0.8.22; | |
| import {ERC721} from "@openzeppelin/contracts/token/ERC721/ERC721.sol"; | |
| contract MyToken is ERC721 { | |
| constructor() ERC721("MyToken", "MTK") {} | |
| } |
NewerOlder