From aed2cdfa0c5cedc8a4d3b9783b32c7b0fb53b4bf Mon Sep 17 00:00:00 2001 From: Daniel Flanagan Date: Fri, 30 Sep 2022 15:14:57 -0500 Subject: [PATCH] Super lazy registration --- components/Page.tsx | 33 +++++++---------- db-migrations.ts | 42 +++++++++++++++++---- db.ts | 22 ++++++++--- fresh.gen.ts | 22 +++++++---- routes/login.tsx | 15 ++++++++ routes/note.tsx | 35 +++++++++++------- routes/note/[id].tsx | 37 +++++++++++++++++++ routes/note/create.tsx | 29 +++++++++++++++ routes/register.tsx | 84 ++++++++++++++++++++++++++++++++++++++---- twind.config.ts | 2 +- 10 files changed, 256 insertions(+), 65 deletions(-) create mode 100644 routes/login.tsx create mode 100644 routes/note/[id].tsx create mode 100644 routes/note/create.tsx diff --git a/components/Page.tsx b/components/Page.tsx index c41d713..2db69fc 100644 --- a/components/Page.tsx +++ b/components/Page.tsx @@ -1,32 +1,25 @@ import { JSX } from "preact"; -const NAV_ITEMS = { - "/note": "Notes", - "/register": "Register", - "/login": "Login", -}; - -const navItem = ([url, text]: [string, string]) => { - return ( - {text} - ); -}; +const NAV_ITEM_CLASSES = + "flex justify-center items-center px-4 py-2 text-blue-500 hover:bg-purple-700"; export function Page(props: JSX.HTMLAttributes) { return ( -
-
-

- LyricScreen -

-