Skip to content

Commit a34486e

Browse files
committed
feat: Implement scroll-to-top on header logo click and ignore Vite build artifacts in .gitignore.
1 parent 619d47c commit a34486e

File tree

2 files changed

+5
-1
lines changed

2 files changed

+5
-1
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ lerna-debug.log*
99

1010
node_modules
1111
dist
12+
.vite/
1213
dist-ssr
1314
*.local
1415

src/App.tsx

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,10 @@ function App() {
4242
{/* Header */}
4343
<header className="border-b bg-background/80 backdrop-blur-sm sticky top-0 z-50">
4444
<div className="container mx-auto px-4 py-4 flex items-center justify-between">
45-
<div className="flex items-center gap-2">
45+
<div
46+
className="flex items-center gap-2 cursor-pointer"
47+
onClick={() => window.scrollTo({ top: 0, behavior: "smooth" })}
48+
>
4649
<img src={logoSvg} alt="shepai logo" className="w-8 h-8" />
4750
<span className="font-bold text-xl">shepai</span>
4851
</div>

0 commit comments

Comments
 (0)