feat: download button and page

This commit is contained in:
Julien Froidefond
2025-02-21 13:08:52 +01:00
parent dd49d80744
commit ade8b372b6
13 changed files with 8794 additions and 697 deletions

View File

@@ -1,6 +1,6 @@
"use client";
import { Home, Library, Settings, LogOut, RefreshCw, Star } from "lucide-react";
import { Home, Library, Settings, LogOut, RefreshCw, Star, Download } from "lucide-react";
import { usePathname, useRouter } from "next/navigation";
import { cn } from "@/lib/utils";
import { authService } from "@/lib/services/auth.service";
@@ -117,12 +117,17 @@ export function Sidebar({ isOpen, onClose }: SidebarProps) {
[pathname, router, onClose]
);
const navigation = [
const mainNavItems = [
{
name: "Accueil",
title: "Accueil",
href: "/",
icon: Home,
},
{
title: "Téléchargements",
href: "/downloads",
icon: Download,
},
];
return (
@@ -140,7 +145,7 @@ export function Sidebar({ isOpen, onClose }: SidebarProps) {
<div className="px-3 py-2">
<div className="space-y-1">
<h2 className="mb-2 px-4 text-lg font-semibold tracking-tight">Navigation</h2>
{navigation.map((item) => (
{mainNavItems.map((item) => (
<button
key={item.href}
onClick={() => handleLinkClick(item.href)}
@@ -150,7 +155,7 @@ export function Sidebar({ isOpen, onClose }: SidebarProps) {
)}
>
<item.icon className="mr-2 h-4 w-4" />
{item.name}
{item.title}
</button>
))}
</div>