From 052cc1a5a4668d7cb17fb273a022aa5b820d1faa Mon Sep 17 00:00:00 2001
From: Sam Nystrom <sam@samnystrom.dev>
Date: Wed, 13 Mar 2024 05:03:22 +0000
Subject: refactor: move styles into separate components

---
 src/index.tsx | 18 ++++++++----------
 1 file changed, 8 insertions(+), 10 deletions(-)

(limited to 'src/index.tsx')

diff --git a/src/index.tsx b/src/index.tsx
index bed8b66..9bcdfe9 100644
--- a/src/index.tsx
+++ b/src/index.tsx
@@ -2,23 +2,21 @@ import { render } from 'preact';
 import { useEffect, useMemo } from 'preact/hooks';
 import { Router } from 'preact-router';
 import PocketBase from 'pocketbase';
-import { Pb } from './pb.ts';
+import { Pb } from './context.ts';
 import { Home, SignUp, LogIn, ProjectsList } from './pages';
-import { NodeEditor } from './NodeEditor.tsx';
+import NodeEditor from './NodeEditor.tsx';
+import { Header, Button } from './components';
 import './index.css';
 
 export const App = () => {
 	const pb = useMemo(() => new PocketBase(`/`));
 	return (
 		<Pb.Provider value={pb}>
-			<header>
-				<a class="title action" href="/">DataNodes</a>
-				<nav>
-					< a class="action" href="/play">Try Now</a>
-					<a class="action" href="/login">Log In</a>
-					<a class="action" href="/signup">Sign Up</a>
-				</nav>
-			</header>
+			<Header>
+				<Button kind="ghost" href="/play">Try Now</Button>
+				<Button kind="ghost" href="/login">Log In</Button>
+				<Button kind="ghost" href="/signup">Sign Up</Button>
+			</Header>
 			<Router>
 				<Home path="/" />
 				<SignUp path="/signup" />
-- 
cgit v1.2.3

