Prima vers. dashboard

This commit is contained in:
2026-06-24 17:18:51 +02:00
parent a9000ca029
commit 1e72712eaf
@@ -0,0 +1,56 @@
import { useAuthStore } from "@/store/authStore";
const roleLabels: Record<string, string> = {
venditore: "Venditore",
valutatore: "Valutatore",
backoffice: "Backoffice",
operatore_perizie: "Operatore Perizie",
approvatore_perizie: "Approvatore Perizie",
admin: "Amministratore",
};
export function DashboardPage() {
const { user } = useAuthStore();
return (
<div className="space-y-6">
<div>
<h1 className="text-2xl font-bold text-gray-900">Dashboard</h1>
<p className="text-sm text-gray-500 mt-1">
Benvenuto, {user?.full_name}
</p>
</div>
<div className="grid grid-cols-1 md:grid-cols-3 gap-4">
<div className="bg-white rounded-xl border border-gray-200 p-5">
<div className="text-sm font-medium text-gray-500 mb-1">Ruolo</div>
<div className="text-xl font-semibold text-gray-900">
{roleLabels[user?.role || ""] || user?.role}
</div>
</div>
<div className="bg-white rounded-xl border border-gray-200 p-5">
<div className="text-sm font-medium text-gray-500 mb-1">Email</div>
<div className="text-xl font-semibold text-gray-900 truncate">
{user?.email}
</div>
</div>
<div className="bg-white rounded-xl border border-gray-200 p-5">
<div className="text-sm font-medium text-gray-500 mb-1">Stato</div>
<div className="flex items-center gap-2">
<div className="w-2 h-2 rounded-full bg-green-500"></div>
<span className="text-xl font-semibold text-gray-900">Attivo</span>
</div>
</div>
</div>
<div className="bg-blue-50 border border-blue-200 rounded-xl p-6">
<h2 className="font-semibold text-blue-900 mb-2">🚀 Sistema in sviluppo</h2>
<p className="text-sm text-blue-700">
GMG Smart Quote è in fase di sviluppo. Le funzionalità verranno abilitate progressivamente nelle milestone successive.
</p>
</div>
</div>
);
}