From d15862d9afe4eaaedca55865fac40dce04f5c1c0 Mon Sep 17 00:00:00 2001 From: ellielle <40385743+ellielle@users.noreply.github.com> Date: Fri, 31 May 2024 15:12:31 -0400 Subject: [PATCH] add basic styling, preliminary layout with data --- bootdevtheme.js => frontend/bootdevtheme.js | 0 frontend/src/App.svelte | 62 ++--------------- frontend/src/components/Login.svelte | 54 +++++++-------- frontend/src/components/UI/Tabs.svelte | 15 +++-- .../src/components/content/General.svelte | 31 +-------- frontend/src/components/content/Stats.svelte | 67 +++++++++++++++++++ frontend/tailwind.config.js | 2 +- main.go | 2 +- 8 files changed, 114 insertions(+), 119 deletions(-) rename bootdevtheme.js => frontend/bootdevtheme.js (100%) create mode 100644 frontend/src/components/content/Stats.svelte diff --git a/bootdevtheme.js b/frontend/bootdevtheme.js similarity index 100% rename from bootdevtheme.js rename to frontend/bootdevtheme.js diff --git a/frontend/src/App.svelte b/frontend/src/App.svelte index c71b42d..c295ec8 100644 --- a/frontend/src/App.svelte +++ b/frontend/src/App.svelte @@ -1,19 +1,12 @@ @@ -53,38 +34,9 @@
diff --git a/frontend/src/components/Login.svelte b/frontend/src/components/Login.svelte index 790f6d5..48ca5b1 100644 --- a/frontend/src/components/Login.svelte +++ b/frontend/src/components/Login.svelte @@ -13,36 +13,34 @@
- {#if !loggedIn || typeof loggedIn != "boolean"} -
diff --git a/frontend/src/components/UI/Tabs.svelte b/frontend/src/components/UI/Tabs.svelte index aa5e408..8b7bf79 100644 --- a/frontend/src/components/UI/Tabs.svelte +++ b/frontend/src/components/UI/Tabs.svelte @@ -2,6 +2,7 @@ import Archmages from "../content/Archmages.svelte"; import General from "../content/General.svelte"; import { Tab, TabGroup, TabAnchor } from "@skeletonlabs/skeleton"; + import Stats from "../content/Stats.svelte"; /** @type number */ let tabSet = 0; @@ -16,7 +17,13 @@
{#each tabs as option, index} - + {option} {/each} @@ -27,13 +34,13 @@ {/if} {#if tabSet === 1} - + {/if} {#if tabSet === 2} - + {/if} {#if tabSet === 3} - + {/if} {#if tabSet === 4} diff --git a/frontend/src/components/content/General.svelte b/frontend/src/components/content/General.svelte index 65e1736..e36edd0 100644 --- a/frontend/src/components/content/General.svelte +++ b/frontend/src/components/content/General.svelte @@ -1,33 +1,4 @@ -
- {#each Object.entries(stats) as stat} -
- {generalStats[stat[0]] + ": " + stat[1]} -
- {/each} -
+
Welcome to Boot.dev Buddy!
diff --git a/frontend/src/components/content/Stats.svelte b/frontend/src/components/content/Stats.svelte new file mode 100644 index 0000000..65d505f --- /dev/null +++ b/frontend/src/components/content/Stats.svelte @@ -0,0 +1,67 @@ + + +
+ {#each Object.entries(stats) as stat} +
+ {generalStats[stat[0]] + ": " + stat[1]} +
+ {/each} + {#each archons as sage} +
+ {sage?.Handle} +
+ {/each} + {#each leaders as lead} +
+ {lead?.Handle} +
+ {/each} +
diff --git a/frontend/tailwind.config.js b/frontend/tailwind.config.js index e09545a..3796d33 100644 --- a/frontend/tailwind.config.js +++ b/frontend/tailwind.config.js @@ -3,7 +3,7 @@ import { join } from "path"; import { skeleton } from "@skeletonlabs/tw-plugin"; -import { bootDevTheme } from "../bootdevtheme.js"; +import { bootDevTheme } from "./bootdevtheme.js"; /** @type {import('tailwindcss').Config} */ export default { diff --git a/main.go b/main.go index 1e3091c..a6d5226 100644 --- a/main.go +++ b/main.go @@ -21,7 +21,7 @@ func main() { Title: "Boot.dev Buddy", Width: 1024, Height: 768, - StartHidden: false, + StartHidden: true, // Set to true to remove border Frameless: true, AssetServer: &assetserver.Options{