chore: initial commit — monorepo ReadaBook (API NestJS, web PWA, Docker)

This commit is contained in:
Git Agent
2026-08-23 09:56:53 +02:00
commit 8f1140127f
79 changed files with 6456 additions and 0 deletions

View File

@ -0,0 +1,37 @@
import { Archive, Home, Search, Settings, UserRound } from "lucide-react";
import type { ReactNode } from "react";
import type { Session } from "../api/types";
import { navigate } from "../router";
const navItems = [
{ href: "/home", label: "Accueil", icon: Home },
{ href: "/search", label: "Recherche", icon: Search },
{ href: "/admin/libraries", label: "Admin", icon: Settings },
{ href: "/me", label: "Profil", icon: UserRound }
];
export function AppShell({ children, session }: { children: ReactNode; session: Session }) {
return (
<div className="app-shell">
<aside className="side-rail">
<button className="brand-button" onClick={() => navigate("/home")} aria-label="ReadaBook">
<Archive size={22} />
<span>ReadaBook</span>
</button>
<nav>
{navItems.map((item) => {
const Icon = item.icon;
return (
<button key={item.href} onClick={() => navigate(item.href)} title={item.label}>
<Icon size={19} />
<span>{item.label}</span>
</button>
);
})}
</nav>
<div className="session-chip">{session.user ? session.user.email : "Mode vitrine"}</div>
</aside>
<main>{children}</main>
</div>
);
}