From 13fed4c2cce26f9682a93b97433fddf79875c38e Mon Sep 17 00:00:00 2001 From: Bianca Date: Thu, 28 May 2026 16:49:41 +0200 Subject: [PATCH 1/5] feat: refactor AssociationsPage and add AssociationsList component --- src/app/associations/page.tsx | 166 +----------------- .../associations/associations-list.tsx | 84 +++++++++ src/components/header/constants.ts | 2 +- 3 files changed, 92 insertions(+), 160 deletions(-) create mode 100644 src/components/associations/associations-list.tsx diff --git a/src/app/associations/page.tsx b/src/app/associations/page.tsx index e0553bb..74d3ae8 100644 --- a/src/app/associations/page.tsx +++ b/src/app/associations/page.tsx @@ -1,160 +1,10 @@ -"use client" +import type { Metadata } from "next" +import { AssociationsList } from "@/components/associations/associations-list" -import { - FiFacebook, - FiGithub, - FiGlobe, - FiInstagram, - FiLinkedin, - FiMail, - FiTwitch, - FiX, - FiYoutube, -} from "react-icons/fi" -import AccordionAssociation from "@/components/accordion-association" -import esnLogo from "../../../public/logos/esn.svg" - -const accordionItems = [ - { - value: "ESN", - name: "ESN", - logo: esnLogo, - content: - "Lorem ipsum dolor sit amet consectetur. Velit integer diam in id proin blandit fames id. Volutpat at vel risus non amet tortor. Potenti sit gravida donec lacinia et posuere faucibus. Elementum libero diam nullam ultricies mauris mauris erat porttitor. At morbi commodo nunc vulputate id odio pellentesque ipsum. Adipiscing at dictumst pulvinar mattis faucibus quisque donec convallis commodo. ", - links: [ - { - key: "Facebook", - href: "https://www.google.com", - icon: FiFacebook, - }, - { - key: "Instagram", - href: "https://www.google.com", - icon: FiInstagram, - }, - { - key: "Youtube", - href: "https://www.google.com", - icon: FiYoutube, - }, - // { - // key: "Discord", - // href: "https://www.google.com", - // icon: FiDiscord - // }, - { - key: "GitHub", - href: "https://www.google.com", - icon: FiGithub, - }, - // { - // key: "Telegram", - // href: "https://www.google.com", - // icon: FiTelegram - // }, - { - key: "Email", - href: "mailto:example@email.com", - icon: FiMail, - }, - { - key: "LinkedIn", - href: "https://www.google.com", - icon: FiLinkedin, - }, - { - key: "Twitch", - href: "https://www.google.com", - icon: FiTwitch, - }, - // { - // key: "Spotify", - // href: "https://www.google.com", - // icon: FiSpotify - // }, - { - key: "X", - href: "https://www.google.com", - icon: FiX, - }, - { - key: "Web", - href: "https://www.google.com", - icon: FiGlobe, - }, - ], - }, - { - value: "Lista Aperta", - name: "Lista Aperta", - logo: esnLogo, - content: - "Lorem ipsum dolor sit amet consectetur. Velit integer diam in id proin blandit fames id. Volutpat at vel risus non amet tortor. Potenti sit gravida donec lacinia et posuere faucibus. Elementum libero diam nullam ultricies mauris mauris erat porttitor. At morbi commodo nunc vulputate id odio pellentesque ipsum. Adipiscing at dictumst pulvinar mattis faucibus quisque donec convallis commodo. ", - links: [ - { - key: "Facebook", - href: "https://www.google.com", - icon: FiFacebook, - }, - ], - }, - { - value: "MESA", - name: "MESA", - logo: esnLogo, - content: - "Lorem ipsum dolor sit amet consectetur. Velit integer diam in id proin blandit fames id. Volutpat at vel risus non amet tortor. Potenti sit gravida donec lacinia et posuere faucibus. Elementum libero diam nullam ultricies mauris mauris erat porttitor. At morbi commodo nunc vulputate id odio pellentesque ipsum. Adipiscing at dictumst pulvinar mattis faucibus quisque donec convallis commodo. ", - links: [ - { - key: "Facebook", - href: "https://www.google.com", - icon: FiFacebook, - }, - ], - }, - { - value: "Polifonia", - name: "Polifonia", - logo: esnLogo, - content: - "Lorem ipsum dolor sit amet consectetur. Velit integer diam in id proin blandit fames id. Volutpat at vel risus non amet tortor. Potenti sit gravida donec lacinia et posuere faucibus. Elementum libero diam nullam ultricies mauris mauris erat porttitor. At morbi commodo nunc vulputate id odio pellentesque ipsum. Adipiscing at dictumst pulvinar mattis faucibus quisque donec convallis commodo. ", - links: [ - { - key: "Facebook", - href: "https://www.google.com", - icon: FiFacebook, - }, - ], - }, - { - value: "POLI.RADIO", - name: "POLI.RADIO", - logo: esnLogo, - content: - "Lorem ipsum dolor sit amet consectetur. Velit integer diam in id proin blandit fames id. Volutpat at vel risus non amet tortor. Potenti sit gravida donec lacinia et posuere faucibus. Elementum libero diam nullam ultricies mauris mauris erat porttitor. At morbi commodo nunc vulputate id odio pellentesque ipsum. Adipiscing at dictumst pulvinar mattis faucibus quisque donec convallis commodo. ", - links: [ - { - key: "Facebook", - href: "https://www.google.com", - icon: FiFacebook, - }, - ], - }, - { - value: "Studenti Indipendenti", - name: "Studenti Indipendenti", - logo: esnLogo, - content: - "Lorem ipsum dolor sit amet consectetur. Velit integer diam in id proin blandit fames id. Volutpat at vel risus non amet tortor. Potenti sit gravida donec lacinia et posuere faucibus. Elementum libero diam nullam ultricies mauris mauris erat porttitor. At morbi commodo nunc vulputate id odio pellentesque ipsum. Adipiscing at dictumst pulvinar mattis faucibus quisque donec convallis commodo. ", - links: [ - { - key: "Facebook", - href: "https://www.google.com", - icon: FiFacebook, - }, - ], - }, -] +export const metadata: Metadata = { + title: "Associazioni", + description: "Scopri le associazioni studentesche del Politecnico", +} export default function AssociationsPage() { return ( @@ -168,9 +18,7 @@ export default function AssociationsPage() { Scopri le associazioni studentesche del Politecnico

-
- -
+ ) diff --git a/src/components/associations/associations-list.tsx b/src/components/associations/associations-list.tsx new file mode 100644 index 0000000..e0f51ae --- /dev/null +++ b/src/components/associations/associations-list.tsx @@ -0,0 +1,84 @@ +"use client" + +import { + FiFacebook, + FiGithub, + FiGlobe, + FiInstagram, + FiLinkedin, + FiMail, + FiTwitch, + FiX, + FiYoutube, +} from "react-icons/fi" +import AccordionAssociation from "@/components/accordion-association" +import esnLogo from "../../../public/logos/esn.svg" + +const accordionItems = [ + { + value: "ESN", + name: "ESN", + logo: esnLogo, + content: + "Lorem ipsum dolor sit amet consectetur. Velit integer diam in id proin blandit fames id. Volutpat at vel risus non amet tortor. Potenti sit gravida donec lacinia et posuere faucibus. Elementum libero diam nullam ultricies mauris mauris erat porttitor. At morbi commodo nunc vulputate id odio pellentesque ipsum. Adipiscing at dictumst pulvinar mattis faucibus quisque donec convallis commodo. ", + links: [ + { key: "Facebook", href: "https://www.google.com", icon: FiFacebook }, + { key: "Instagram", href: "https://www.google.com", icon: FiInstagram }, + { key: "Youtube", href: "https://www.google.com", icon: FiYoutube }, + { key: "GitHub", href: "https://www.google.com", icon: FiGithub }, + { key: "Email", href: "mailto:example@email.com", icon: FiMail }, + { key: "LinkedIn", href: "https://www.google.com", icon: FiLinkedin }, + { key: "Twitch", href: "https://www.google.com", icon: FiTwitch }, + { key: "X", href: "https://www.google.com", icon: FiX }, + { key: "Web", href: "https://www.google.com", icon: FiGlobe }, + ], + }, + { + value: "Lista Aperta", + name: "Lista Aperta", + logo: esnLogo, + content: + "Lorem ipsum dolor sit amet consectetur. Velit integer diam in id proin blandit fames id. Volutpat at vel risus non amet tortor. Potenti sit gravida donec lacinia et posuere faucibus. Elementum libero diam nullam ultricies mauris mauris erat porttitor. At morbi commodo nunc vulputate id odio pellentesque ipsum. Adipiscing at dictumst pulvinar mattis faucibus quisque donec convallis commodo. ", + links: [{ key: "Facebook", href: "https://www.google.com", icon: FiFacebook }], + }, + { + value: "MESA", + name: "MESA", + logo: esnLogo, + content: + "Lorem ipsum dolor sit amet consectetur. Velit integer diam in id proin blandit fames id. Volutpat at vel risus non amet tortor. Potenti sit gravida donec lacinia et posuere faucibus. Elementum libero diam nullam ultricies mauris mauris erat porttitor. At morbi commodo nunc vulputate id odio pellentesque ipsum. Adipiscing at dictumst pulvinar mattis faucibus quisque donec convallis commodo. ", + links: [{ key: "Facebook", href: "https://www.google.com", icon: FiFacebook }], + }, + { + value: "Polifonia", + name: "Polifonia", + logo: esnLogo, + content: + "Lorem ipsum dolor sit amet consectetur. Velit integer diam in id proin blandit fames id. Volutpat at vel risus non amet tortor. Potenti sit gravida donec lacinia et posuere faucibus. Elementum libero diam nullam ultricies mauris mauris erat porttitor. At morbi commodo nunc vulputate id odio pellentesque ipsum. Adipiscing at dictumst pulvinar mattis faucibus quisque donec convallis commodo. ", + links: [{ key: "Facebook", href: "https://www.google.com", icon: FiFacebook }], + }, + { + value: "POLI.RADIO", + name: "POLI.RADIO", + logo: esnLogo, + content: + "Lorem ipsum dolor sit amet consectetur. Velit integer diam in id proin blandit fames id. Volutpat at vel risus non amet tortor. Potenti sit gravida donec lacinia et posuere faucibus. Elementum libero diam nullam ultricies mauris mauris erat porttitor. At morbi commodo nunc vulputate id odio pellentesque ipsum. Adipiscing at dictumst pulvinar mattis faucibus quisque donec convallis commodo. ", + links: [{ key: "Facebook", href: "https://www.google.com", icon: FiFacebook }], + }, + { + value: "Studenti Indipendenti", + name: "Studenti Indipendenti", + logo: esnLogo, + content: + "Lorem ipsum dolor sit amet consectetur. Velit integer diam in id proin blandit fames id. Volutpat at vel risus non amet tortor. Potenti sit gravida donec lacinia et posuere faucibus. Elementum libero diam nullam ultricies mauris mauris erat porttitor. At morbi commodo nunc vulputate id odio pellentesque ipsum. Adipiscing at dictumst pulvinar mattis faucibus quisque donec convallis commodo. ", + links: [{ key: "Facebook", href: "https://www.google.com", icon: FiFacebook }], + }, +] + +export function AssociationsList() { + return ( +
+ +
+ ) +} diff --git a/src/components/header/constants.ts b/src/components/header/constants.ts index 38a1e4f..8c40b36 100644 --- a/src/components/header/constants.ts +++ b/src/components/header/constants.ts @@ -19,7 +19,7 @@ export const headerMenuItems: HeaderMenuItem[] = [ { title: "Groups", href: "#", icon: FiChevronRight }, { title: "Projects", href: "#", icon: FiChevronRight }, { title: "Freshman", href: "/matricole", icon: FiChevronRight }, - { title: "Associations", href: "#", icon: FiChevronRight }, + { title: "Associations", href: "/associations", icon: FiChevronRight }, ], }, { From 895ea56afb7c038fd2f445b5274376135ea34ea4 Mon Sep 17 00:00:00 2001 From: Bianca Date: Thu, 28 May 2026 16:51:46 +0200 Subject: [PATCH 2/5] feat: add metadata to projects page and update Projects link in header --- src/app/projects/page.tsx | 5 +++++ src/components/header/constants.ts | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/src/app/projects/page.tsx b/src/app/projects/page.tsx index c0a666f..f97afe0 100644 --- a/src/app/projects/page.tsx +++ b/src/app/projects/page.tsx @@ -3,6 +3,11 @@ import { CommunityNews } from "@/components/projects/community-news" import { Deprecated } from "@/components/projects/deprecated" import { Upload } from "@/components/projects/upload" +export const metadata = { + title: "Progetti", + description: "Esplora e contribuisci ai progetti degli studenti", +} + export default function Home() { return (
diff --git a/src/components/header/constants.ts b/src/components/header/constants.ts index 8c40b36..115b823 100644 --- a/src/components/header/constants.ts +++ b/src/components/header/constants.ts @@ -17,7 +17,7 @@ export const headerMenuItems: HeaderMenuItem[] = [ title: "Community", menu: [ { title: "Groups", href: "#", icon: FiChevronRight }, - { title: "Projects", href: "#", icon: FiChevronRight }, + { title: "Projects", href: "/projects", icon: FiChevronRight }, { title: "Freshman", href: "/matricole", icon: FiChevronRight }, { title: "Associations", href: "/associations", icon: FiChevronRight }, ], From 5e981b7694adfa4357b69567c0a8982f6cd8ff5d Mon Sep 17 00:00:00 2001 From: Bianca Date: Thu, 28 May 2026 17:14:03 +0200 Subject: [PATCH 3/5] feat: add href property to CardCaption and update featuredCards with project links --- src/components/card-caption.tsx | 4 ++++ src/components/home/projects.tsx | 13 ++++++++++--- 2 files changed, 14 insertions(+), 3 deletions(-) diff --git a/src/components/card-caption.tsx b/src/components/card-caption.tsx index 60be7a1..0f04b10 100644 --- a/src/components/card-caption.tsx +++ b/src/components/card-caption.tsx @@ -1,3 +1,4 @@ +import Link from "next/link" import type { ReactNode } from "react" import type { IconType } from "react-icons" import { Card, CardAction, CardContent, CardHeader, CardTitle } from "./ui/card" @@ -7,16 +8,19 @@ export function CardCaption({ caption, icon, iconPosition = "right", + href, className, }: { title: string caption: ReactNode icon?: IconType iconPosition?: "top" | "right" + href?: string className?: string }) { return ( + {href && } diff --git a/src/components/home/projects.tsx b/src/components/home/projects.tsx index 210d37b..b66fafc 100644 --- a/src/components/home/projects.tsx +++ b/src/components/home/projects.tsx @@ -1,3 +1,4 @@ +import Link from "next/link" import { FiArrowUpRight } from "react-icons/fi" import { CardCaption } from "@/components/card-caption" import { Button } from "@/components/ui/button" @@ -8,19 +9,23 @@ const featuredCards = [ title: "WeBeepSync", caption: "WeBeep Sync è una semplice app, user-friendly e senza compromessi che serve per tenere sincronizzati tutti i tuoi file di WeBeep.", + href: "https://github.com/toto04/webeep-sync", }, { title: "PolimiSchedule", caption: "Genera un file iCalendar (.ics) a partire dal formato testuale dell’Orario delle lezioni. Possibilità di importare su Google Calendar.", + href: "https://github.com/jacopo-j/polimi-schedule", }, { title: "WiFiLinux", caption: "Scarica ed esegui lo script Python per attivare la connessione permanente al WiFi Polimi", + href: "https://github.com/PoliNetworkOrg/WiFiLinux", }, { title: "The TOL Project", caption: "Un simulatore gratuito del test di ammissione per le aspiranti matricole di Ingegneria del PoliMi.", + href: "https://tol.polinetwork.org/", }, ] as const @@ -40,9 +45,11 @@ export function Projects() { Progetti e strumenti nati dalla community del Politecnico per semplificare la vita universitaria e promuovere l’innovazione. Hai un’idea? Proponila, trova collaboratori e realizza la tua soluzione.

- From a1f0230a101ff422e124aaf135c6c516f74d0100 Mon Sep 17 00:00:00 2001 From: Bianca Date: Thu, 28 May 2026 17:54:33 +0200 Subject: [PATCH 4/5] feat: update buttons in AboutUs, Hero, and Materials components to use Link for navigation --- src/components/header/constants.ts | 4 ++-- src/components/home/about-us.tsx | 9 +++++++-- src/components/home/hero.tsx | 8 +++++--- src/components/home/materials.tsx | 9 ++++++--- 4 files changed, 20 insertions(+), 10 deletions(-) diff --git a/src/components/header/constants.ts b/src/components/header/constants.ts index 115b823..378af0f 100644 --- a/src/components/header/constants.ts +++ b/src/components/header/constants.ts @@ -9,8 +9,8 @@ export const headerMenuItems: HeaderMenuItem[] = [ { title: "Guides", href: "#", icon: FiChevronRight }, { title: "Computer Recs", href: "#", icon: FiChevronRight }, { title: "FAQs", href: "#", icon: FiChevronRight }, - { title: "Rankings", href: "#", icon: FiArrowUpRight }, - { title: "Tol Project", href: "#", icon: FiArrowUpRight }, + { title: "Rankings", href: "https://rankings.polinetwork.org/", icon: FiArrowUpRight }, + { title: "Tol Project", href: "https://tol.polinetwork.org/", icon: FiArrowUpRight }, ], }, { diff --git a/src/components/home/about-us.tsx b/src/components/home/about-us.tsx index 8d9ab54..f879f91 100644 --- a/src/components/home/about-us.tsx +++ b/src/components/home/about-us.tsx @@ -1,3 +1,5 @@ +import Link from "next/link" +import { FiArrowUpRight } from "react-icons/fi" import { Button } from "@/components/ui/button" export function AboutUs() { @@ -7,8 +9,11 @@ export function AboutUs() { PoliNetwork unisce gli studenti del Poli: gruppi, risorse e supporto, tutti in un'unica community. - ) diff --git a/src/components/home/hero.tsx b/src/components/home/hero.tsx index 02d7444..35518c1 100644 --- a/src/components/home/hero.tsx +++ b/src/components/home/hero.tsx @@ -20,9 +20,11 @@ export function Hero() { className="typo-body-medium" /> - diff --git a/src/components/home/materials.tsx b/src/components/home/materials.tsx index 45a9f5e..ca54b18 100644 --- a/src/components/home/materials.tsx +++ b/src/components/home/materials.tsx @@ -1,3 +1,4 @@ +import Link from "next/link" import { FiArrowUpRight, FiBook, FiBookOpen, FiClipboard, FiFileText, FiUploadCloud } from "react-icons/fi" import { CardIcon } from "@/components/card-icon" import { Button } from "@/components/ui/button" @@ -58,9 +59,11 @@ export function Materials() { Il più grande archivio didattico degli studenti del Politecnico. Trova appunti, dispense ed esami, oppure carica i tuoi file per far crescere la community.

- From 0e33972e96c036b1d478664a2c4b4f31b7f9d0b0 Mon Sep 17 00:00:00 2001 From: Bianca Date: Thu, 28 May 2026 17:59:48 +0200 Subject: [PATCH 5/5] feat: update header menu item hrefs for navigation consistency --- src/components/header/constants.ts | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/src/components/header/constants.ts b/src/components/header/constants.ts index 378af0f..a785ca5 100644 --- a/src/components/header/constants.ts +++ b/src/components/header/constants.ts @@ -5,10 +5,10 @@ export const headerMenuItems: HeaderMenuItem[] = [ { title: "Resources", menu: [ - { title: "Materials", href: "#", icon: FiChevronRight }, - { title: "Guides", href: "#", icon: FiChevronRight }, - { title: "Computer Recs", href: "#", icon: FiChevronRight }, - { title: "FAQs", href: "#", icon: FiChevronRight }, + { title: "Materials", href: "/materials", icon: FiChevronRight }, + { title: "Guides", href: "/guides", icon: FiChevronRight }, + { title: "Computer Recs", href: "/computer-recs", icon: FiChevronRight }, + { title: "FAQs", href: "/faqs", icon: FiChevronRight }, { title: "Rankings", href: "https://rankings.polinetwork.org/", icon: FiArrowUpRight }, { title: "Tol Project", href: "https://tol.polinetwork.org/", icon: FiArrowUpRight }, ], @@ -16,7 +16,7 @@ export const headerMenuItems: HeaderMenuItem[] = [ { title: "Community", menu: [ - { title: "Groups", href: "#", icon: FiChevronRight }, + { title: "Groups", href: "/groups", icon: FiChevronRight }, { title: "Projects", href: "/projects", icon: FiChevronRight }, { title: "Freshman", href: "/matricole", icon: FiChevronRight }, { title: "Associations", href: "/associations", icon: FiChevronRight }, @@ -25,9 +25,9 @@ export const headerMenuItems: HeaderMenuItem[] = [ { title: "About", menu: [ - { title: "About us", href: "#", icon: FiChevronRight }, - { title: "Join us", href: "#", icon: FiChevronRight }, - { title: "Contact us", href: "#", icon: FiChevronRight }, + { title: "About us", href: "/about", icon: FiChevronRight }, + { title: "Join us", href: "/join", icon: FiChevronRight }, + { title: "Contact us", href: "/contact", icon: FiChevronRight }, ], }, ]