From 63304bd2814ce046f02779a8f36c8fa77b384d7c Mon Sep 17 00:00:00 2001 From: metacryst Date: Mon, 12 Jan 2026 14:27:19 -0600 Subject: [PATCH] temporary signout fix, small aesthetics --- notes.js | 5 ++++- server/index.js | 4 ++-- ui/_/code/shared.css | 2 +- ui/desktop/Home.js | 1 - ui/desktop/components/Sidebar.js | 4 ++++ ui/public/pages/Home.js | 2 ++ 6 files changed, 13 insertions(+), 5 deletions(-) diff --git a/notes.js b/notes.js index dcc75ef..dd314e3 100644 --- a/notes.js +++ b/notes.js @@ -20,7 +20,10 @@ img(`db/images/${networks[i].logo}`, "2.25em", "2.25em") quill gotchas - image width / height + img element: width, height, x, and y do not work as usual. You have to put width and height in the constructor, and x and y should be "left" and "top" (or "bottom" and "right") + + img(`db/images/${networks[i].logo}`, "2.25em", "2.25em") + forgetting to put a "/" at the beginning of the url for window.navigateTo (if you don't want to add to the existing url) forgetting to define the event callback with or without the word "function", like so: diff --git a/server/index.js b/server/index.js index 0f6021a..0fc4cd3 100644 --- a/server/index.js +++ b/server/index.js @@ -33,13 +33,13 @@ class Server { router.get('/signout', this.auth.logout) /* Site */ - router.post('/signup', this.verifyToken, this.newUserSubmission) + router.post('/signup', this.verifySignupToken, this.newUserSubmission) router.get('/db/images/*', this.getUserImage) router.get('/*', this.get) return router } - verifyToken = (req, res, next) => { + verifySignupToken = (req, res, next) => { const { token } = req.query; if (!token) { return res.status(400).json({ error: 'Token is required' }); diff --git a/ui/_/code/shared.css b/ui/_/code/shared.css index 1816c45..7c8f750 100644 --- a/ui/_/code/shared.css +++ b/ui/_/code/shared.css @@ -4,7 +4,7 @@ --accent: black; --accent2: black; - --parchment: #FFEBCC; + --parchment: #FEBA7D; --gold: #FEBA7D; --divider: #bb7c36; --green: #0857265c; diff --git a/ui/desktop/Home.js b/ui/desktop/Home.js index a2eee4c..3f2bd91 100644 --- a/ui/desktop/Home.js +++ b/ui/desktop/Home.js @@ -32,7 +32,6 @@ class Home extends Shadow { .border("1px solid var(--accent)") .attr({value: "dark"}) .onChange((e) => { - console.log("onchange") document.documentElement.className = e.target.value localStorage.setItem("theme", e.target.value); const event = new CustomEvent('themechange', { diff --git a/ui/desktop/components/Sidebar.js b/ui/desktop/components/Sidebar.js index 15c8f68..a68f62b 100644 --- a/ui/desktop/components/Sidebar.js +++ b/ui/desktop/components/Sidebar.js @@ -40,6 +40,10 @@ class Sidebar extends Shadow { .height(100, vh) .borderRight("1px solid var(--accent)") .zIndex(3) + .onEvent("themechange", () => { + console.log("change") + this.rerender() + }) } } diff --git a/ui/public/pages/Home.js b/ui/public/pages/Home.js index b6eda06..3969197 100644 --- a/ui/public/pages/Home.js +++ b/ui/public/pages/Home.js @@ -127,6 +127,8 @@ class Home extends Shadow { SignupForm() } else if(window.location.pathname.startsWith("/login")) { SignIn() + } else { + SignIn() } } })