From 4e0508cdaad1347d22dc8102448b951681ee386a Mon Sep 17 00:00:00 2001 From: npmrun <1549469775@qq.com> Date: Tue, 19 Nov 2024 23:15:06 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20=E5=BC=80=E5=8F=91=E4=B8=AD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/base/withPage.tsx | 2 +- src/effect/index.tsx | 2 +- src/layout/base.tsx | 46 ++++++++++++++++++++++++++++------------- src/router/AppRouter.tsx | 2 +- src/router/Loading.tsx | 6 ++---- src/router/index.ts | 4 ++-- src/ui/Hero/index.tsx | 52 +++++++++++++++++++++++++++++++++++++++++++++++ src/ui/Markdown/index.tsx | 22 ++++++++++++++++++++ src/ui/Notice/index.tsx | 11 ++++++++++ src/views/Child.tsx | 3 +-- src/views/Home/index.tsx | 41 +++++++++---------------------------- vite.config.ts | 1 + 12 files changed, 136 insertions(+), 56 deletions(-) create mode 100644 src/ui/Hero/index.tsx create mode 100644 src/ui/Markdown/index.tsx create mode 100644 src/ui/Notice/index.tsx diff --git a/src/base/withPage.tsx b/src/base/withPage.tsx index a97f6c0..5e9f76d 100644 --- a/src/base/withPage.tsx +++ b/src/base/withPage.tsx @@ -1,5 +1,5 @@ import { FC, ReactNode } from "react" -import { LeftIn, OpacityIn } from "@/effect" +import { OpacityIn } from "@/effect" import styled from "styled-components" interface PageProps { diff --git a/src/effect/index.tsx b/src/effect/index.tsx index 3974e40..59c85af 100644 --- a/src/effect/index.tsx +++ b/src/effect/index.tsx @@ -1,5 +1,5 @@ import { motion } from "framer-motion" -import styled from "styled-components" + export function OpacityIn({ children, className }: any) { return ( diff --git a/src/layout/base.tsx b/src/layout/base.tsx index 0a9b4c3..664d88b 100644 --- a/src/layout/base.tsx +++ b/src/layout/base.tsx @@ -3,6 +3,8 @@ import { ReactNode, useState } from "react" import { NavLink, useHistory } from "react-router-dom" import styled from "styled-components" import { GlobalStyles } from "./GlobalStyles" +import { Notice } from "@/ui/Notice" +import { Markdown } from "@/ui/Markdown" interface PageProps { children: ReactNode @@ -27,15 +29,25 @@ function BaseLayout(props: PageProps) { const router = useHistory() + const about = ` +> 人生如逆水行舟,不进则退。 + + 我来自一南方小镇,不善言辞,今作此小站,聊慰平生。 + + 如有意愿,欢迎联系。 + +[Github](https://github.com/npmrun) + ` + return ( - 东风天堂 + 天涯行宫 -