Skip to content

Commit

Permalink
Merge pull request #12 from ChanX21/frontend
Browse files Browse the repository at this point in the history
Frontend
  • Loading branch information
ChanX21 authored Sep 8, 2024
2 parents b0a505d + 8c90615 commit 334c390
Show file tree
Hide file tree
Showing 19 changed files with 1,556 additions and 130 deletions.
177 changes: 176 additions & 1 deletion package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

33 changes: 33 additions & 0 deletions packages/nextjs/app/landing-page/page.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
"use client";

import Image from "next/image";
import type { NextPage } from "next";
import { useAccount } from "wagmi";
import { Address } from "~~/components/scaffold-eth";
import { FaucetButton, RainbowKitCustomConnectButton } from "~~/components/scaffold-eth";

const Home: NextPage = () => {
const { address: connectedAddress } = useAccount();

return (
<>
<div className="flex items-center flex-col flex-grow pt-10 relative min-h-screen w-full overflow-x-hidden ">
<div className="absolute top-0 left-0 w-full h-full -z-10">
<Image src="/Ninjabg.png" alt="Ninja Strike Background" layout="fill" objectFit="cover" />
</div>
<div className="flex flex-col sm:flex-row gap-4 sm:gap-10 items-center w-full px-4 sm:px-8 max-w-screen-xl">
<div className="flex justify-center items-center space-x-2 flex-col sm:flex-row">
<p className="my-2 font-medium">Connected Address:</p>
<Address address={connectedAddress} />
</div>
<div className="flex-grow flex justify-end">
<RainbowKitCustomConnectButton />
<FaucetButton />
</div>
</div>
</div>
</>
);
};

export default Home;
4 changes: 2 additions & 2 deletions packages/nextjs/app/layout.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@ import "~~/styles/globals.css";
import { getMetadata } from "~~/utils/scaffold-eth/getMetadata";

export const metadata = getMetadata({
title: "Scaffold-ETH 2 App",
description: "Built with 🏗 Scaffold-ETH 2",
title: "Ninja strike",
description: "Web3 Ninja Game",
});

const ScaffoldEthApp = ({ children }: { children: React.ReactNode }) => {
Expand Down
Loading

0 comments on commit 334c390

Please sign in to comment.