From 420a543f8af3075502b0a7530a0fa06af264eb8b Mon Sep 17 00:00:00 2001 From: polwex Date: Tue, 18 Nov 2025 16:59:24 +0700 Subject: refactoring gui too, improvements to Nostr user logic --- gui/src/Router.tsx | 27 ++++++++++----------------- 1 file changed, 10 insertions(+), 17 deletions(-) (limited to 'gui/src/Router.tsx') diff --git a/gui/src/Router.tsx b/gui/src/Router.tsx index ee3aa0d..5026ef0 100644 --- a/gui/src/Router.tsx +++ b/gui/src/Router.tsx @@ -1,12 +1,14 @@ import Sidebar from "@/components/layout/Sidebar"; - -// new +import useLocalState from "@/state/state"; import Feed from "@/pages/Feed"; +import User from "@/pages/User"; import Settings from "@/pages/Settings"; import Thread from "@/pages/Thread"; import { Switch, Router, Redirect, Route } from "wouter"; +import { P404 } from "./pages/Error"; export default function r() { + const modal = useLocalState((s) => s.modal); return ( @@ -14,26 +16,17 @@ export default function r() {
- - + + + +
+ {modal && modal}
); } function toGlobal() { - return ; -} - -export function P404() { - return

404

; -} -export function ErrorPage({ msg }: { msg: string }) { - return ( -
- -

{msg}

-
- ); + return ; } -- cgit v1.2.3