From 6fdc97b98bf6d25ca6cc7fe603a65fb20c2ec3f2 Mon Sep 17 00:00:00 2001 From: TheClashFruit Date: Sun, 21 Apr 2024 16:48:51 +0200 Subject: [PATCH] feat: navbar, homepage header --- components/Button.tsx | 28 ++++++++ components/MarkdownPage.tsx | 2 +- components/Navbar.tsx | 65 +++++++++++++++--- components/ThemeChanger.tsx | 23 +++++++ package.json | 1 + pages/_app.tsx | 9 ++- pages/index.tsx | 61 +++++++++++++++-- pnpm-lock.yaml | 13 ++++ styles/Button.module.scss | 59 ++++++++++++++++ styles/Home.module.scss | 90 ++++++++++++++++++++++++ styles/Navbar.module.scss | 132 +++++++++++++++++++++++++++++++++++- styles/globals.scss | 16 +++++ 12 files changed, 480 insertions(+), 19 deletions(-) create mode 100644 components/Button.tsx create mode 100644 components/ThemeChanger.tsx create mode 100644 styles/Button.module.scss create mode 100644 styles/Home.module.scss diff --git a/components/Button.tsx b/components/Button.tsx new file mode 100644 index 0000000..6af0151 --- /dev/null +++ b/components/Button.tsx @@ -0,0 +1,28 @@ +import styles from '@/styles/Button.module.scss'; + +import Link from 'next/link'; + +type Props = { + href?: string; + children: React.ReactNode; + className?: string; + disabled?: boolean; + type: 'primary' | 'outlined'; + [key: string]: any; +}; + +export default function Button({ href, children, className, disabled, type, ...props }: Props) { + return ( + <> + {href ? ( + + {children} + + ) : ( + + )} + + ); +} \ No newline at end of file diff --git a/components/MarkdownPage.tsx b/components/MarkdownPage.tsx index 77e6b68..ebd6235 100644 --- a/components/MarkdownPage.tsx +++ b/components/MarkdownPage.tsx @@ -21,7 +21,7 @@ export default function MarkdownPage({ metadata, children }: Props) { - +