diff --git a/README.md b/README.md index 750918a..b5a6fa9 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,8 @@ ## Todo List - - [ ] Add loading feedback with ViewTransition API - - [ ] Revamp Design and Layout + - [x] Add loading feedback with ViewTransition API + - [x] Revamp Design and Layout + - [ ] Stay on same page when making API request + - [ ] Speed up loading time (why so slow? idk) ## Setting Up Supabase ### Selfhosting diff --git a/src/pages/account/old.astro b/src/pages/account/old.astro deleted file mode 100644 index fe1adb2..0000000 --- a/src/pages/account/old.astro +++ /dev/null @@ -1,146 +0,0 @@ ---- -import Base from "@layouts/Base.astro" - -// Messages -if (Astro.url.href.endsWith('CheckEmail')) {var MessageCheckEmail = true} -else {var MessageCheckEmail = false} - -if (Astro.url.href.endsWith('AvatarUpdated')) {var MessageAvatarUpdated = true} -else {var MessageAvatarUpdated = false} - -if (Astro.url.href.endsWith('NameUpdated')) {var MessageNameUpdated = true} -else {var MessageNameUpdated = false} - -if (Astro.url.href.endsWith('EmailConfirmed')) {var MessageEmailConfirmed = true} -else {var MessageEmailConfirmed = false} - -if (Astro.url.href.endsWith('PasswordReset')) {var MessagePasswordReset = true} -else {var MessagePasswordReset = false} - -// Supabase Data -import { supabase } from "@library/supabase" -const { data: { user } } = await supabase.auth.getUser() -const avatarUrl = user?.user_metadata.avatar_url -const displayName = user?.user_metadata.full_name -const email = user?.email -const id = user?.id - -// Get User Preferences -const user_plan = user?.user_metadata.plan -const user_theme = user?.user_metadata.theme -const user_color_scheme = user?.user_metadata.color_scheme -const user_beta = user?.user_metadata.beta - -// Date - Readable Format (MONTH DAY, YEAR at #:##:## AM/PM / December 9, 2023 at 5:12:43 PM) -const dateFormat = { year: 'numeric', month: 'long', day: 'numeric', hour: 'numeric', minute: 'numeric', second: 'numeric' } - -/// Created Date -const createdDate = new Date(user?.created_at) -const createDate = createdDate.toLocaleDateString('en-US', dateFormat) - -/// Last Logged In -const lastSignIn = new Date(user?.last_sign_in_at) -const lastSignInDate = lastSignIn.toLocaleDateString('en-US', dateFormat) ---- - - - -
- - - - -
-
-
- -
- - -
- - {MessageCheckEmail ?

Check your email

: null} - {MessageAvatarUpdated ?

Your avatar has been updated

: null} - {MessageNameUpdated ?

Your display name has been updated

: null} - {MessageEmailConfirmed ?

Email confirmed

: null} - {MessagePasswordReset ?

Your new password has been updated

: null} - -

Your Account

-

Plan: {user_plan}

-

Display Name: {displayName}

-

Email: {email}

-
-

ID: {id}

-

Created at: {createDate}

-

Lasted login: {lastSignInDate}

-
- -

Preferences

-

Theme: {user_theme}

-

Color Scheme: {user_color_scheme}

- {user_beta ? -
- : -
- } -

-
- -
-

Change Avatar

-
- - -
- -
-
-

Update Display Name

-
- - -
- -
-
-

Change Email

-
- - -
- -
-
-

Change Password

-
- - -
-
- - -
- -
-

Do you want to delete your accout?

-
- - - - - \ No newline at end of file