Init mdx
This commit is contained in:
@@ -1,29 +1,86 @@
|
||||
import Link from "next/link";
|
||||
import Head from "next/head";
|
||||
import "../styles/globals.css";
|
||||
import styles from "../styles/Home.module.css";
|
||||
|
||||
import {
|
||||
Box,
|
||||
Container,
|
||||
Typography,
|
||||
AppBar,
|
||||
Toolbar,
|
||||
ThemeProvider,
|
||||
createTheme,
|
||||
CssBaseline,
|
||||
} from "@mui/material";
|
||||
|
||||
const theme = createTheme({
|
||||
palette: {
|
||||
primary: {
|
||||
main: "#39ceff",
|
||||
},
|
||||
secondary: {
|
||||
main: "#f50057",
|
||||
},
|
||||
},
|
||||
});
|
||||
|
||||
function MyApp({ Component, pageProps }) {
|
||||
return (
|
||||
<>
|
||||
<Head>
|
||||
<title>前端技术分享</title>
|
||||
<meta name="description" content="乐" />
|
||||
<link rel="icon" href="/favicon.ico" />
|
||||
</Head>
|
||||
<ThemeProvider theme={theme}>
|
||||
<Container
|
||||
sx={{
|
||||
p: 3,
|
||||
}}
|
||||
>
|
||||
<Head>
|
||||
<title>前端技术分享</title>
|
||||
<meta name="description" content="乐" />
|
||||
<link rel="icon" href="/favicon.ico" />
|
||||
<CssBaseline />
|
||||
</Head>
|
||||
|
||||
<Component {...pageProps} />
|
||||
<AppBar position="relative">
|
||||
<Toolbar>
|
||||
<Link
|
||||
passHref
|
||||
href="/"
|
||||
style={{
|
||||
textDecoration: "none",
|
||||
}}
|
||||
>
|
||||
<Typography variant="h6">前端技术分享</Typography>
|
||||
</Link>
|
||||
</Toolbar>
|
||||
</AppBar>
|
||||
|
||||
<footer className={styles.footer}>
|
||||
<Link
|
||||
href="https://beian.miit.gov.cn/"
|
||||
target="_blank"
|
||||
rel="noopener noreferrer"
|
||||
<main
|
||||
style={{
|
||||
minHeight: "100vh",
|
||||
paddingTop: "2rem",
|
||||
}}
|
||||
>
|
||||
粤ICP备2022033906号-1
|
||||
</Link>
|
||||
</footer>
|
||||
</>
|
||||
<Component {...pageProps} />
|
||||
</main>
|
||||
|
||||
<hr />
|
||||
<footer
|
||||
style={{
|
||||
display: "flex",
|
||||
justifyContent: "space-evenly",
|
||||
}}
|
||||
>
|
||||
<Link
|
||||
href="https://beian.miit.gov.cn/"
|
||||
target="_blank"
|
||||
rel="noopener noreferrer"
|
||||
passHref
|
||||
>
|
||||
<Typography variant="body1">粤ICP备2022033906号-1</Typography>
|
||||
</Link>
|
||||
<Typography variant="body1">使用 Next.js 构建</Typography>
|
||||
</footer>
|
||||
</Container>
|
||||
</ThemeProvider>
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user