Compare commits

...

2 Commits

Author SHA1 Message Date
895df3f7d9 feat: grille dashboard fluide, conteneur élargi et theme toggle plus visible
All checks were successful
Deploy with Docker Compose / deploy (push) Successful in 4m0s
- max-w-5xl → max-w-7xl sur le layout global
- grille auto-fill minmax(300px,1fr) pour grands écrans
- ThemeToggle : bordure + fond permanents, emoji text-lg

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-02-23 13:55:26 +01:00
92c819d339 feat: afficher badge privé (violet) dans les cards du dashboard
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-02-23 13:49:03 +01:00
3 changed files with 19 additions and 11 deletions

View File

@@ -31,7 +31,7 @@ export default function RootLayout({
<SessionProvider> <SessionProvider>
<ThemeProvider> <ThemeProvider>
<Header /> <Header />
<main className="mx-auto max-w-5xl px-4 py-6">{children}</main> <main className="mx-auto max-w-7xl px-4 py-6">{children}</main>
</ThemeProvider> </ThemeProvider>
</SessionProvider> </SessionProvider>
</body> </body>

View File

@@ -21,6 +21,7 @@ interface EvalRow {
evaluationDate: string; evaluationDate: string;
template?: { name: string; dimensions?: Dimension[] }; template?: { name: string; dimensions?: Dimension[] };
status: string; status: string;
isPublic?: boolean;
dimensionScores?: { dimensionId: string; score: number | null; dimension?: { title: string } }[]; dimensionScores?: { dimensionId: string; score: number | null; dimension?: { title: string } }[];
} }
@@ -86,14 +87,21 @@ function EvalCard({
{e.candidateTeam && ` · ${e.candidateTeam}`} {e.candidateTeam && ` · ${e.candidateTeam}`}
</p> </p>
</div> </div>
<div className="flex shrink-0 items-center gap-1">
{!e.isPublic && (
<span className="font-mono text-xs px-1.5 py-0.5 rounded bg-purple-500/20 text-purple-600 dark:text-purple-400">
privé
</span>
)}
<span <span
className={`shrink-0 font-mono text-xs px-1.5 py-0.5 rounded ${ className={`font-mono text-xs px-1.5 py-0.5 rounded ${
e.status === "submitted" ? "bg-emerald-500/20 text-emerald-600 dark:text-emerald-400" : "bg-amber-500/20 text-amber-600 dark:text-amber-400" e.status === "submitted" ? "bg-emerald-500/20 text-emerald-600 dark:text-emerald-400" : "bg-amber-500/20 text-amber-600 dark:text-amber-400"
}`} }`}
> >
{e.status === "submitted" ? "ok" : "draft"} {e.status === "submitted" ? "ok" : "draft"}
</span> </span>
</div> </div>
</div>
<div className="mb-3 flex flex-wrap gap-x-3 gap-y-0.5 font-mono text-xs text-zinc-500 dark:text-zinc-400"> <div className="mb-3 flex flex-wrap gap-x-3 gap-y-0.5 font-mono text-xs text-zinc-500 dark:text-zinc-400">
<span>{e.evaluatorName}</span> <span>{e.evaluatorName}</span>
<span>{format(new Date(e.evaluationDate), "yyyy-MM-dd")}</span> <span>{format(new Date(e.evaluationDate), "yyyy-MM-dd")}</span>
@@ -297,7 +305,7 @@ export function DashboardClient({ evaluations }: DashboardClientProps) {
<h2 className="mb-3 font-mono text-sm font-medium text-zinc-600 dark:text-zinc-400"> <h2 className="mb-3 font-mono text-sm font-medium text-zinc-600 dark:text-zinc-400">
{team ?? "Sans équipe"} {team ?? "Sans équipe"}
</h2> </h2>
<div className="grid gap-4 sm:grid-cols-2 lg:grid-cols-3"> <div className="grid gap-4 [grid-template-columns:repeat(auto-fill,minmax(300px,1fr))]">
{evals.map((e) => ( {evals.map((e) => (
<EvalCard <EvalCard
key={e.id} key={e.id}
@@ -314,7 +322,7 @@ export function DashboardClient({ evaluations }: DashboardClientProps) {
))} ))}
</div> </div>
) : ( ) : (
<div className="grid gap-4 sm:grid-cols-2 lg:grid-cols-3"> <div className="grid gap-4 [grid-template-columns:repeat(auto-fill,minmax(300px,1fr))]">
{list.map((e) => ( {list.map((e) => (
<EvalCard <EvalCard
key={e.id} key={e.id}

View File

@@ -9,7 +9,7 @@ export function ThemeToggle() {
<button <button
type="button" type="button"
onClick={() => setTheme(theme === "dark" ? "light" : "dark")} onClick={() => setTheme(theme === "dark" ? "light" : "dark")}
className="font-mono text-xs text-zinc-600 dark:text-zinc-500 hover:text-zinc-800 dark:hover:text-zinc-300 transition-colors" className="flex items-center justify-center w-8 h-8 rounded border border-zinc-200 dark:border-zinc-600 bg-zinc-50 dark:bg-zinc-800 text-lg text-zinc-600 dark:text-zinc-300 hover:border-zinc-300 dark:hover:border-zinc-500 hover:bg-zinc-100 dark:hover:bg-zinc-700 transition-colors"
title={theme === "dark" ? "Passer au thème clair" : "Passer au thème sombre"} title={theme === "dark" ? "Passer au thème clair" : "Passer au thème sombre"}
> >
{theme === "dark" ? "☀" : "☽"} {theme === "dark" ? "☀" : "☽"}