From 145f36f39bcd90a679e3dc60a0c6f162b8851d5a Mon Sep 17 00:00:00 2001 From: HorizonCode Date: Thu, 11 Jan 2024 15:56:02 +0100 Subject: [PATCH] add Settings page --- src/App.svelte | 12 ++++++++---- src/consts/pages.ts | 1 + src/pages/Settings.svelte | 32 ++++++++++++++++++++++++++++++++ 3 files changed, 41 insertions(+), 4 deletions(-) create mode 100644 src/pages/Settings.svelte diff --git a/src/App.svelte b/src/App.svelte index 8eec788..799a85c 100644 --- a/src/App.svelte +++ b/src/App.svelte @@ -23,6 +23,7 @@ import Launch from "./pages/Launch.svelte"; import { Toaster } from "svelte-french-toast"; import type { User } from "./types/user"; + import Settings from "./pages/Settings.svelte"; let user: User | undefined = undefined; let loggedIn = false; @@ -48,7 +49,7 @@ >EZPPLauncher - {#if $currentPage != Page.Login} + {#if $currentPage == Page.Launch}
--> {/if} - + + {#if loggedIn} +{:else if $currentPage == Page.Settings} + {:else} {/if} diff --git a/src/consts/pages.ts b/src/consts/pages.ts index 8fd68a6..ec7f47a 100644 --- a/src/consts/pages.ts +++ b/src/consts/pages.ts @@ -1,4 +1,5 @@ export enum Page { Login = 0, Launch = 1, + Settings = 2, } diff --git a/src/pages/Settings.svelte b/src/pages/Settings.svelte new file mode 100644 index 0000000..9fcc8f2 --- /dev/null +++ b/src/pages/Settings.svelte @@ -0,0 +1,32 @@ + + +
+
+ + + + +
+ + +
+
+