From e0bfd0cdd04834dec4f54a41fdb26ea38204d7ab Mon Sep 17 00:00:00 2001 From: keannu125 Date: Sat, 25 Feb 2023 22:30:38 +0800 Subject: [PATCH] Added design and login to header --- src/Components/AppIcon/AppIcon.tsx | 30 ++++++++++++++++++++++ src/Components/Header/Header.tsx | 31 ++++++++++++++++++++++- src/Components/Login/Login.tsx | 40 ++++++++++++++++++++++++++++++ src/Components/Note/Note.tsx | 2 +- src/Components/Notes/Notes.tsx | 4 +-- src/Routes/NewNote/NewNote.tsx | 4 +-- src/styles.tsx | 10 ++++++-- 7 files changed, 113 insertions(+), 8 deletions(-) create mode 100644 src/Components/AppIcon/AppIcon.tsx create mode 100644 src/Components/Login/Login.tsx diff --git a/src/Components/AppIcon/AppIcon.tsx b/src/Components/AppIcon/AppIcon.tsx new file mode 100644 index 0000000..aef58b9 --- /dev/null +++ b/src/Components/AppIcon/AppIcon.tsx @@ -0,0 +1,30 @@ +import * as React from "react"; + +export interface props { + size: string; + color: string; +} + +export default function AppIcon(props: props) { + return ( + <> + + + + + + + + + ); +} diff --git a/src/Components/Header/Header.tsx b/src/Components/Header/Header.tsx index 3e86d14..a895f1e 100644 --- a/src/Components/Header/Header.tsx +++ b/src/Components/Header/Header.tsx @@ -1,11 +1,40 @@ import * as React from "react"; import styles from "../../styles"; +import AppIcon from "../AppIcon/AppIcon"; +import Login from "../Login/Login"; export default function Header() { return (
-

React - A Notes Demo

+
+
+ +
+
+

Clip Notes

+
+
+
+ +
+
+
); } diff --git a/src/Components/Login/Login.tsx b/src/Components/Login/Login.tsx new file mode 100644 index 0000000..ca07cc3 --- /dev/null +++ b/src/Components/Login/Login.tsx @@ -0,0 +1,40 @@ +import * as React from "react"; +import { useState } from "react"; +import { Button } from "@mui/material"; +import styles from "../../styles"; + +export default function Login() { + const [logged_in, setLoggedIn] = useState(false); + if (!logged_in) { + return ( +
+

Not Logged in

+
+ +
+ ); + } + return ( +
+

Logged in as

+
+ +
+ ); +} diff --git a/src/Components/Note/Note.tsx b/src/Components/Note/Note.tsx index 346a5d5..153e424 100644 --- a/src/Components/Note/Note.tsx +++ b/src/Components/Note/Note.tsx @@ -27,7 +27,7 @@ export default function Note(props: props) {

Timestamp: {props.date_created}