From b9a5d7f36f5c33b9bb4f42a8f604aa7a7622cbe4 Mon Sep 17 00:00:00 2001 From: allebonvi Date: Mon, 20 Apr 2026 15:13:43 +0200 Subject: [PATCH] Aggiorna menu della clinica --- clinica-app/client/src/components/Navbar.tsx | 118 +++++++++++++++---- 1 file changed, 97 insertions(+), 21 deletions(-) diff --git a/clinica-app/client/src/components/Navbar.tsx b/clinica-app/client/src/components/Navbar.tsx index aeb0a93..c670bde 100644 --- a/clinica-app/client/src/components/Navbar.tsx +++ b/clinica-app/client/src/components/Navbar.tsx @@ -5,11 +5,47 @@ */ import { useState, useEffect } from "react"; import { Button } from "@/components/ui/button"; -import { Menu, X, Phone, MapPin } from "lucide-react"; +import { ChevronDown, Menu, X, Phone, MapPin } from "lucide-react"; -const navLinks = [ +type NavLink = { + label: string; + href: string; + children?: Array<{ + label: string; + href: string; + }>; +}; + +const navLinks: NavLink[] = [ { label: "Chi Siamo", href: "#chi-siamo" }, - { label: "Servizi", href: "#servizi" }, + { + label: "Servizi", + href: "#servizi", + children: [ + { label: "Visite cliniche e medicina preventiva", href: "#servizi" }, + { label: "Ecografia", href: "#servizi" }, + { label: "Radiologia", href: "#servizi" }, + { label: "Laboratorio", href: "#servizi" }, + { label: "Ematologia", href: "#servizi" }, + { label: "Biochimica", href: "#servizi" }, + { label: "Urine", href: "#servizi" }, + { label: "Citologia", href: "#servizi" }, + { label: "Coagulazione", href: "#servizi" }, + { label: "Endoscopia", href: "#servizi" }, + { label: "Laparoscopia", href: "#servizi" }, + ], + }, + { + label: "Visite Specialistiche", + href: "#servizi", + children: [ + { label: "Oncologia", href: "#servizi" }, + { label: "Dermatologia", href: "#servizi" }, + { label: "Oculistica", href: "#servizi" }, + { label: "Nutrizione", href: "#servizi" }, + { label: "Ortopedia", href: "#servizi" }, + ], + }, { label: "Il Team", href: "#team" }, { label: "News", href: "#news" }, { label: "Contatti", href: "#contatti" }, @@ -84,17 +120,41 @@ export default function Navbar() { {/* Desktop menu */} -
+
{navLinks.map((link) => ( - - {link.label} - - +
+ + {link.label} + {link.children && ( + + )} + + + + {link.children && ( +
+
+ {link.children.map((child) => ( + + {child.label} + + ))} +
+
+ )} +
))}
@@ -131,14 +191,30 @@ export default function Navbar() { {mobileOpen && (
{navLinks.map((link) => ( - setMobileOpen(false)} - > - {link.label} - +
+ setMobileOpen(false)} + > + {link.label} + {link.children && } + + {link.children && ( +
+ {link.children.map((child) => ( + setMobileOpen(false)} + > + {child.label} + + ))} +
+ )} +
))}