From 66255e187984f754f9220c5a275346082ca93438 Mon Sep 17 00:00:00 2001 From: LittleSheep Date: Wed, 1 Jan 2025 20:29:57 +0800 Subject: [PATCH] :sparkles: Basic layout --- src/components/CapAppBar.tsx | 35 +++++++++++++++++++++++++++++++++++ src/pages/_app.tsx | 22 +++++++++++++++++++++- src/pages/api/hello.ts | 13 ------------- src/pages/index.tsx | 13 +++++++++---- 4 files changed, 65 insertions(+), 18 deletions(-) create mode 100644 src/components/CapAppBar.tsx delete mode 100644 src/pages/api/hello.ts diff --git a/src/components/CapAppBar.tsx b/src/components/CapAppBar.tsx new file mode 100644 index 0000000..7fc58f8 --- /dev/null +++ b/src/components/CapAppBar.tsx @@ -0,0 +1,35 @@ +import { AppBar, Box, IconButton, Toolbar, Typography } from "@mui/material"; +import MenuIcon from "@mui/icons-material/Menu"; +import AccountCircle from "@mui/icons-material/AccountCircle"; + +export function CapAppBar() { + return ( + + + + + + + + Capital + + + + + + + + ); +} diff --git a/src/pages/_app.tsx b/src/pages/_app.tsx index d59b587..ff5c974 100644 --- a/src/pages/_app.tsx +++ b/src/pages/_app.tsx @@ -1,6 +1,8 @@ import "@/styles/globals.css"; import type { AppProps } from "next/app"; +import { createTheme, CssBaseline, ThemeProvider } from "@mui/material"; import { Roboto } from "next/font/google"; +import { CapAppBar } from "@/components/CapAppBar"; const fontRoboto = Roboto({ subsets: ["latin"], @@ -8,6 +10,18 @@ const fontRoboto = Roboto({ display: "swap", }); +const siteTheme = createTheme({ + palette: { + mode: "light", + primary: { + main: "#3949ab", + }, + secondary: { + main: "#1e88e5", + }, + }, +}); + export default function App({ Component, pageProps }: AppProps) { return ( <> @@ -16,7 +30,13 @@ export default function App({ Component, pageProps }: AppProps) { font-family: ${fontRoboto.style.fontFamily}; } `} - + + + + + + + ); } diff --git a/src/pages/api/hello.ts b/src/pages/api/hello.ts deleted file mode 100644 index ea77e8f..0000000 --- a/src/pages/api/hello.ts +++ /dev/null @@ -1,13 +0,0 @@ -// Next.js API route support: https://nextjs.org/docs/api-routes/introduction -import type { NextApiRequest, NextApiResponse } from "next"; - -type Data = { - name: string; -}; - -export default function handler( - req: NextApiRequest, - res: NextApiResponse, -) { - res.status(200).json({ name: "John Doe" }); -} diff --git a/src/pages/index.tsx b/src/pages/index.tsx index 5858d31..fe0a7c3 100644 --- a/src/pages/index.tsx +++ b/src/pages/index.tsx @@ -1,9 +1,14 @@ -import { Button } from "@mui/material"; +import { Container, Typography } from "@mui/material"; export default function Home() { return ( -
- -
+
+ + + Welcome to
+ the Solsynth Capital. +
+
+
); }