import product catalogue

This commit is contained in:
2026-07-16 17:05:06 +05:30
parent 8a1527cef8
commit 11baf732b7
35 changed files with 2722 additions and 1513 deletions

View File

@@ -12,7 +12,8 @@ import {
TrendingUp,
ShieldAlert,
Users,
Truck
Truck,
Box
} from 'lucide-react';
import { NavLink, useLocation } from 'react-router-dom';
import { MainSection } from '../types';
@@ -37,6 +38,7 @@ export default function Sidebar({
const navItems = [
{ id: 'dashboard' as MainSection, label: 'Dashboard', icon: LayoutDashboard },
{ id: 'inventory' as MainSection, label: 'Products', icon: Layers },
{ id: 'catalogue' as MainSection, label: 'Global Catalogue', icon: Box },
{ id: 'reports' as MainSection, label: 'Reports', icon: TrendingUp },
{ id: 'dispatch' as MainSection, label: 'Console', icon: Truck },
{ id: 'settings' as MainSection, label: 'Settings', icon: Settings }
@@ -53,7 +55,7 @@ export default function Sidebar({
)}
<aside
className={`fixed left-0 top-0 h-screen bg-[#662582] border-r border-[#662582] text-white flex flex-col py-xl pt-16 z-40 transition-all duration-300 ${
className={`fixed left-0 top-0 h-screen bg-[#662582] text-white flex flex-col py-xl pt-16 z-40 transition-all duration-300 ${
isOpen ? 'translate-x-0 w-64' : '-translate-x-full md:translate-x-0 md:w-16'
}`}
>
@@ -67,11 +69,11 @@ export default function Sidebar({
to={`/admin/${item.id}`}
title={item.label}
className={({ isActive }) => `w-full flex items-center py-3 rounded-lg text-left transition-all duration-200 cursor-pointer ${
isOpen ? 'gap-md px-md' : 'justify-center px-0'
isOpen ? 'gap-md px-md border-l-4' : 'justify-center px-0'
} ${
isActive
? 'bg-black/20 text-white font-semibold' + (isOpen ? ' border-l-4 border-white' : '')
: 'text-purple-200 hover:bg-white/10 hover:text-white'
? 'bg-black/20 text-white font-semibold' + (isOpen ? ' border-white' : '')
: 'text-purple-200 hover:bg-white/10 hover:text-white' + (isOpen ? ' border-transparent' : '')
}`}
>
{({ isActive }) => (