Document Prisma ERD generation
This commit is contained in:
parent
b5e967d8d3
commit
4ec0683f88
9 changed files with 3997 additions and 25 deletions
75
app/page.tsx
75
app/page.tsx
|
|
@ -1,7 +1,26 @@
|
|||
import Link from 'next/link'
|
||||
import { cookies } from 'next/headers'
|
||||
import { getIronSession } from 'iron-session'
|
||||
import { AppIcon } from '@/components/shared/app-icon'
|
||||
import { SessionData, sessionOptions } from '@/lib/session'
|
||||
import packageJson from '@/package.json'
|
||||
|
||||
const buildDate = process.env.NEXT_PUBLIC_BUILD_DATE
|
||||
? new Date(process.env.NEXT_PUBLIC_BUILD_DATE).toLocaleDateString('nl-NL', {
|
||||
day: 'numeric',
|
||||
month: 'short',
|
||||
year: 'numeric',
|
||||
})
|
||||
: '—'
|
||||
|
||||
const version = process.env.NEXT_PUBLIC_APP_VERSION ?? packageJson.version
|
||||
|
||||
export default async function LandingPage() {
|
||||
const session = process.env.SESSION_SECRET
|
||||
? await getIronSession<SessionData>(await cookies(), sessionOptions)
|
||||
: null
|
||||
const isLoggedIn = Boolean(session?.userId)
|
||||
|
||||
export default function LandingPage() {
|
||||
return (
|
||||
<div className="h-screen bg-background text-foreground flex flex-col overflow-hidden">
|
||||
|
||||
|
|
@ -12,18 +31,43 @@ export default function LandingPage() {
|
|||
Scrum4Me
|
||||
</Link>
|
||||
<nav className="ml-auto flex items-center gap-2">
|
||||
<Link
|
||||
href="/login"
|
||||
className="px-3 py-1.5 rounded-md text-sm text-muted-foreground hover:text-foreground hover:bg-surface-container transition-colors"
|
||||
>
|
||||
Inloggen
|
||||
</Link>
|
||||
<Link
|
||||
href="/register"
|
||||
className="px-4 py-1.5 rounded-md text-sm bg-primary text-primary-foreground hover:opacity-90 transition-opacity font-medium"
|
||||
>
|
||||
Registreren
|
||||
</Link>
|
||||
{isLoggedIn ? (
|
||||
<>
|
||||
<Link
|
||||
href="/dashboard"
|
||||
className="px-3 py-1.5 rounded-md text-sm text-muted-foreground hover:text-foreground hover:bg-surface-container transition-colors"
|
||||
>
|
||||
Producten
|
||||
</Link>
|
||||
<Link
|
||||
href="/todos"
|
||||
className="px-3 py-1.5 rounded-md text-sm text-muted-foreground hover:text-foreground hover:bg-surface-container transition-colors"
|
||||
>
|
||||
Todo's
|
||||
</Link>
|
||||
<Link
|
||||
href="/settings"
|
||||
className="px-3 py-1.5 rounded-md text-sm text-muted-foreground hover:text-foreground hover:bg-surface-container transition-colors"
|
||||
>
|
||||
Instellingen
|
||||
</Link>
|
||||
</>
|
||||
) : (
|
||||
<>
|
||||
<Link
|
||||
href="/login"
|
||||
className="px-3 py-1.5 rounded-md text-sm text-muted-foreground hover:text-foreground hover:bg-surface-container transition-colors"
|
||||
>
|
||||
Inloggen
|
||||
</Link>
|
||||
<Link
|
||||
href="/register"
|
||||
className="px-4 py-1.5 rounded-md text-sm bg-primary text-primary-foreground hover:opacity-90 transition-opacity font-medium"
|
||||
>
|
||||
Registreren
|
||||
</Link>
|
||||
</>
|
||||
)}
|
||||
</nav>
|
||||
</header>
|
||||
|
||||
|
|
@ -279,10 +323,7 @@ export default function LandingPage() {
|
|||
{/* ── Footer ─────────────────────────────────────────────────── */}
|
||||
<footer className="shrink-0 border-t border-border bg-surface-container-low px-6 py-4 flex items-center justify-between text-xs text-muted-foreground">
|
||||
<span>© {new Date().getFullYear()} Scrum4Me</span>
|
||||
<div className="flex gap-4">
|
||||
<Link href="/login" className="hover:text-foreground transition-colors">Inloggen</Link>
|
||||
<Link href="/register" className="hover:text-foreground transition-colors">Registreren</Link>
|
||||
</div>
|
||||
<span>v{version} · gebouwd op {buildDate}</span>
|
||||
</footer>
|
||||
|
||||
</div>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue