first commit

This commit is contained in:
2026-06-11 09:04:28 +03:30
commit e4dce4491c
27 changed files with 4422 additions and 0 deletions
+68
View File
@@ -0,0 +1,68 @@
'use client';
import Header from '@/components/Header';
import Link from 'next/link';
import { motion } from 'framer-motion';
import { History, ScanLine, ListChecks } from 'lucide-react';
export default function Dashboard() {
const container = {
hidden: { opacity: 0 },
show: {
opacity: 1,
transition: { staggerChildren: 0.1 }
}
};
const item = {
hidden: { opacity: 0, y: 20 },
show: { opacity: 1, y: 0, transition: { type: 'spring', stiffness: 300, damping: 24 } }
};
return (
<div className="w-full min-h-screen bg-gray-50 flex flex-col">
<Header title="داشبورد" />
<motion.div
variants={container}
initial="hidden"
animate="show"
className="p-5 flex flex-col gap-4"
>
<div className="grid grid-cols-2 gap-4">
<motion.div variants={item}>
<Link href="/history" className="bg-white/80 backdrop-blur-sm border border-gray-100 rounded-3xl shadow-[0_4px_20px_rgb(0,0,0,0.03)] p-6 flex flex-col items-center justify-center aspect-square gap-3 hover:bg-white hover:scale-[1.02] active:scale-95 transition-all">
<div className="w-12 h-12 bg-blue-50 text-blue-500 rounded-2xl flex items-center justify-center mb-1">
<History strokeWidth={1.5} size={24} />
</div>
<span className="font-extrabold text-xs text-gray-700">تاریخچه شمارش</span>
</Link>
</motion.div>
<motion.div variants={item}>
<Link href="/scan" className="bg-white/80 backdrop-blur-sm border border-gray-100 rounded-3xl shadow-[0_4px_20px_rgb(0,0,0,0.03)] p-6 flex flex-col items-center justify-center aspect-square gap-3 hover:bg-white hover:scale-[1.02] active:scale-95 transition-all">
<div className="w-12 h-12 bg-purple-50 text-purple-600 rounded-2xl flex items-center justify-center mb-1">
<ScanLine strokeWidth={1.5} size={24} />
</div>
<span className="font-extrabold text-xs text-gray-700">اسکن کالا</span>
</Link>
</motion.div>
</div>
<motion.div variants={item}>
<Link href="/my-counts" className="bg-white/80 backdrop-blur-sm border border-gray-100 rounded-3xl shadow-[0_4px_20px_rgb(0,0,0,0.03)] p-5 flex items-center justify-between hover:bg-white hover:scale-[1.01] active:scale-[0.99] transition-all">
<div className="flex items-center gap-4">
<div className="w-10 h-10 bg-green-50 text-green-600 rounded-xl flex items-center justify-center">
<ListChecks strokeWidth={1.5} size={20} />
</div>
<span className="font-extrabold text-sm text-gray-700">شمارشهای من</span>
</div>
<div className="w-8 h-8 bg-gray-50 rounded-full flex items-center justify-center">
<svg className="w-4 h-4 text-gray-400 rotate-180" fill="none" stroke="currentColor" viewBox="0 0 24 24"><path strokeLinecap="round" strokeLinejoin="round" strokeWidth="2" d="M9 5l7 7-7 7" /></svg>
</div>
</Link>
</motion.div>
</motion.div>
</div>
);
}