Skip to content

Commit ac1698c

Browse files
authored
feat: added questions button in nav (#71)
1 parent 42873dd commit ac1698c

File tree

3 files changed

+11
-77
lines changed

3 files changed

+11
-77
lines changed

frontend/src/App.tsx

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
import { ThemeProvider } from '@/components/ThemeProvider'
21
import { COLLECTION_ID, DATABASE_ID, getDatabase } from '@/lib/Auth'
32
import { getUser } from '@/lib/Auth.ts'
43
import type { CollectionRow } from '@/types'
@@ -41,7 +40,7 @@ function App() {
4140
}
4241

4342
return (
44-
<ThemeProvider defaultTheme="dark" storageKey="tcgpct-ui-theme">
43+
<>
4544
<Toaster />
4645
<Header user={user} setUser={setUser} />
4746
<Routes>
@@ -50,7 +49,7 @@ function App() {
5049
<Route path="/collection" element={<Collection user={user} ownedCards={ownedCards} setOwnedCards={setOwnedCards} />} />
5150
<Route path="/trade" element={<Trade user={user} ownedCards={ownedCards} />} />
5251
</Routes>
53-
</ThemeProvider>
52+
</>
5453
)
5554
}
5655

frontend/src/components/ThemeProvider.tsx

Lines changed: 0 additions & 62 deletions
This file was deleted.

frontend/src/components/ui/Header.tsx

Lines changed: 9 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ import { Login } from '@/components/Login.tsx'
55
import { Dialog, DialogContent, DialogHeader, DialogTitle, DialogTrigger } from '@/components/ui/dialog.tsx'
66
import { logout } from '@/lib/Auth.ts'
77
import type { Models } from 'appwrite'
8+
import { ChevronRight } from 'lucide-react'
89
import type { FC } from 'react'
910
import { Link } from 'react-router-dom'
1011

@@ -15,33 +16,31 @@ interface Props {
1516

1617
export const Header: FC<Props> = ({ user, setUser }) => (
1718
<>
18-
<header className="flex h-20 w-full justify-between shrink-0 items-center px-4 md:px-6">
19+
<header className="flex h-20 w-full justify-between shrink-0 items-center px-4 md:px-6 flex-wrap">
1920
<NavigationMenu>
2021
<NavigationMenuList>
2122
<NavigationMenuLink asChild>
2223
<Link to="/">
23-
<Button className="cursor-pointer" variant="ghost">
24-
Overview
25-
</Button>
24+
<Button variant="ghost">Overview</Button>
2625
</Link>
2726
</NavigationMenuLink>
2827
<NavigationMenuLink asChild>
2928
<Link to="/collection">
30-
<Button className="cursor-pointer" variant="ghost">
31-
Collection
32-
</Button>
29+
<Button variant="ghost">Collection</Button>
3330
</Link>
3431
</NavigationMenuLink>
3532
<NavigationMenuLink asChild>
3633
<Link to="/trade">
37-
<Button className="cursor-pointer" variant="ghost">
38-
Trade
39-
</Button>
34+
<Button variant="ghost">Trade</Button>
4035
</Link>
4136
</NavigationMenuLink>
4237
</NavigationMenuList>
4338
</NavigationMenu>
4439
<div className="flex items-center gap-2">
40+
<Button variant="ghost" onClick={() => window.open('https://github.com/marcelpanse/tcg-pocket-collection-tracker/discussions', '_blank')}>
41+
Questions <ChevronRight />
42+
</Button>
43+
4544
{user ? (
4645
<Button
4746
variant="outline"
@@ -65,8 +64,6 @@ export const Header: FC<Props> = ({ user, setUser }) => (
6564
</DialogContent>
6665
</Dialog>
6766
)}
68-
69-
{/* <ModeToggle /> */}
7067
</div>
7168
</header>
7269
</>

0 commit comments

Comments
 (0)