From 9ec9a278b7f56591974ccb3889882efa403dcd5b Mon Sep 17 00:00:00 2001 From: Alessandro Giuseppe Gioia Date: Fri, 28 Aug 2026 22:22:30 +0200 Subject: [PATCH 1/6] Footer (#25) * feat: init footer. Missing buttons, font and icons * chore: biome check * feat: init footer. Missing buttons, font and icons * chore: biome check * First footer layout * chore: biome * fix: typography and responsive design * feat: incorporate CardMultipleIcons into footer.tsx; fix: spacings; feat: add FooterAccordion and FooterLink components * feat: invert order of CardSplit and sitemap in mobile * responsiveness * chore: biome * chore:biome * fix: coniglio * chore: biome * tweak: set max width to footer elements and aligned copyright paragraph tag * forgot to save * chore: biome * tweak: center 'talk with us' in mobile view * fix: coniglio * feat: dynamic copyright deadline * feat: footer redesign * feat: change anchors to next/links * feat: change requested by Bianca * chore: biome * feat: remove className from ButtonIcon as requested by Bianca * refactor: temporarily restored ButtonIcon sizes * refactor: move footer.tsx in namesake folder * feat: align footer items to baseline --- src/app/layout.tsx | 2 + src/app/page.tsx | 29 ----------- src/components/button-icon.tsx | 13 +++-- src/components/card-split/index.tsx | 2 +- src/components/card-split/primary-content.tsx | 2 +- .../card-split/secondary-content.tsx | 6 ++- src/components/footer/index.tsx | 48 +++++++++++++++++++ src/components/ui/button.tsx | 21 ++++---- 8 files changed, 77 insertions(+), 46 deletions(-) create mode 100644 src/components/footer/index.tsx diff --git a/src/app/layout.tsx b/src/app/layout.tsx index f54fb2d..807d4aa 100644 --- a/src/app/layout.tsx +++ b/src/app/layout.tsx @@ -1,3 +1,4 @@ +import { Footer } from "@/components/footer" import { Header } from "@/components/header/header" import { Shape } from "@/components/shapes" import { ThemeProvider } from "@/components/theme-provider" @@ -83,6 +84,7 @@ export default function RootLayout({ children }: Readonly<{ children: React.Reac
{children} +
diff --git a/src/app/page.tsx b/src/app/page.tsx index 861fa4b..0296908 100644 --- a/src/app/page.tsx +++ b/src/app/page.tsx @@ -1,15 +1,7 @@ -import Image from "next/image" -import { FiFacebook, FiGithub, FiInstagram, FiLinkedin } from "react-icons/fi" -import discord from "@/assets/icons/discord.svg" -import telegram from "@/assets/icons/telegram.svg" -import { DropdownButton } from "@/components/button-dropdown" -import { CardMultipleIcons } from "@/components/card-multiple-icons" -import { CardSplit } from "@/components/card-split" import { AboutUs } from "@/components/home/about-us" import { Hero } from "@/components/home/hero" import { Materials } from "@/components/home/materials" import { Projects } from "@/components/home/projects" -import { CallToAction } from "@/components/ui/call-to-action" export default function Home() { return ( @@ -18,27 +10,6 @@ export default function Home() { - -
- - , - , - , - , - Discord, - , - ]} - /> - -
) } diff --git a/src/components/button-icon.tsx b/src/components/button-icon.tsx index f2d3325..62ef264 100644 --- a/src/components/button-icon.tsx +++ b/src/components/button-icon.tsx @@ -1,21 +1,24 @@ +import type { ReactNode } from "react" import type { IconType } from "react-icons" -import { Button } from "./ui/button" +import { Button, type ButtonSizes } from "./ui/button" export function ButtonIcon({ variant = "primary", icon: Icon, - text, + children, iconPosition = "left", + size, }: { variant?: "primary" | "tertiary" | "tertiaryBlur" icon: IconType - text: string + children: ReactNode iconPosition?: "left" | "right" + size: ButtonSizes }) { return ( - ) diff --git a/src/components/card-split/index.tsx b/src/components/card-split/index.tsx index 7607428..583a2d4 100644 --- a/src/components/card-split/index.tsx +++ b/src/components/card-split/index.tsx @@ -11,7 +11,7 @@ export function CardSplit({ textPrimary, textSecondary, textSecondarySmall, acti return ( diff --git a/src/components/card-split/primary-content.tsx b/src/components/card-split/primary-content.tsx index 22079f6..e2c7383 100644 --- a/src/components/card-split/primary-content.tsx +++ b/src/components/card-split/primary-content.tsx @@ -1,6 +1,6 @@ export function CardSplitPrimaryContent({ text }: { text: string }) { return ( -

+

{text}

) diff --git a/src/components/card-split/secondary-content.tsx b/src/components/card-split/secondary-content.tsx index f1b44a4..785deaf 100644 --- a/src/components/card-split/secondary-content.tsx +++ b/src/components/card-split/secondary-content.tsx @@ -13,8 +13,10 @@ export function CardSplitSecondaryContent({ }: CardSplitSecondaryContentProps) { return (
- {textSecondary &&

{textSecondary}

} - {textSecondarySmall &&

{textSecondarySmall}

} + {textSecondary &&

{textSecondary}

} + {textSecondarySmall && ( +

{textSecondarySmall}

+ )}
) } diff --git a/src/components/footer/index.tsx b/src/components/footer/index.tsx new file mode 100644 index 0000000..f403e40 --- /dev/null +++ b/src/components/footer/index.tsx @@ -0,0 +1,48 @@ +import Image from "next/image" +import Link from "next/link" +import { FiFacebook, FiGithub, FiInstagram, FiLinkedin } from "react-icons/fi" +import discord from "@/assets/icons/discord.svg" +import telegram from "@/assets/icons/telegram.svg" +import { CardMultipleIcons } from "../card-multiple-icons" + +export function Footer() { + return ( +
+

+ Keep in touch! +

+ +
+ , + , + , + , + Discord, + , + ]} + /> +
+ +
+
+ Unisciti a noi! + Contattaci + + Qualche problema?
Segnalalo! + +
+
+ Terms & conditions + Privacy policy + Cookie policy +
+
+ +
+ +
+
+ ) +} diff --git a/src/components/ui/button.tsx b/src/components/ui/button.tsx index 644312d..c6cdca9 100644 --- a/src/components/ui/button.tsx +++ b/src/components/ui/button.tsx @@ -4,6 +4,18 @@ import type * as React from "react" import { cn } from "@/lib/utils" +const buttonSizes = { + default: "h-9 px-4 py-2 has-[>svg]:px-3", + sm: "h-8 gap-1.5 px-3 has-[>svg]:px-2.5 text-xs", + lg: "h-10 px-6 has-[>svg]:px-4", + "lg-wide": "h-10 px-10 has-[>svg]:px-7.5", + icon: "size-9", + "icon-sm": "size-8", + "icon-lg": "size-10", +} + +export type ButtonSizes = keyof typeof buttonSizes + //TODO: Varianti const buttonVariants = cva( "inline-flex items-center justify-center gap-2 whitespace-nowrap text-sm font-medium transition-all disabled:pointer-events-none disabled:opacity-50 [&_svg]:pointer-events-none [&_svg:not([class*='size-'])]:size-4 shrink-0 [&_svg]:shrink-0 outline-none focus-visible:border-slate-950 focus-visible:ring-slate-950/50 focus-visible:ring-[3px] aria-invalid:ring-red-500/20 dark:aria-invalid:ring-red-500/40 aria-invalid:border-red-500 dark:focus-visible:border-slate-300 dark:focus-visible:ring-slate-300/50 dark:aria-invalid:ring-red-900/20 dark:dark:aria-invalid:ring-red-900/40 dark:aria-invalid:border-red-900", @@ -20,14 +32,7 @@ const buttonVariants = cva( "border bg-white shadow-xs hover:bg-slate-100 hover:text-slate-900 dark:bg-slate-200/30 dark:border-slate-200 dark:hover:bg-slate-200/50 dark:bg-slate-950 dark:hover:bg-slate-800 dark:hover:text-slate-50 dark:dark:bg-slate-800/30 dark:dark:border-slate-800 dark:dark:hover:bg-slate-800/50", link: "text-slate-900 underline-offset-4 underline dark:text-slate-50", }, - size: { - default: "h-9 px-4 py-2 has-[>svg]:px-3", - sm: "h-8 gap-1.5 px-3 has-[>svg]:px-2.5 text-xs", - lg: "h-10 px-6 has-[>svg]:px-4", - icon: "size-9", - "icon-sm": "size-8", - "icon-lg": "size-10", - }, + size: buttonSizes, }, defaultVariants: { variant: "primary", From a6356422e5be089889dd20133c96175675efa476 Mon Sep 17 00:00:00 2001 From: Bianca Roberta Ianosel Date: Fri, 28 Aug 2026 22:31:38 +0200 Subject: [PATCH 2/6] fix: update header menu items and improve mobile layout navigation (#147) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: Gabriele Viganò --- src/components/header/constants.ts | 33 ++++++++++++++----------- src/components/header/icon-buttons.tsx | 3 +-- src/components/header/mobile-layout.tsx | 2 +- 3 files changed, 21 insertions(+), 17 deletions(-) diff --git a/src/components/header/constants.ts b/src/components/header/constants.ts index a785ca5..1becf41 100644 --- a/src/components/header/constants.ts +++ b/src/components/header/constants.ts @@ -1,33 +1,38 @@ -import { FiArrowUpRight, FiChevronRight } from "react-icons/fi" +import { FiChevronRight } from "react-icons/fi" import type { HeaderMenuItem } from "./types" export const headerMenuItems: HeaderMenuItem[] = [ { title: "Resources", menu: [ - { title: "Materials", href: "/materials", icon: FiChevronRight }, - { title: "Guides", href: "/guides", icon: FiChevronRight }, - { title: "Computer Recs", href: "/computer-recs", icon: FiChevronRight }, + { title: "Progetti", href: "/projects", icon: FiChevronRight }, + { title: "Appunti", href: "/materials", icon: FiChevronRight }, + { title: "Guide", href: "/guides", 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 }, ], }, { title: "Community", menu: [ - { title: "Groups", href: "/groups", icon: FiChevronRight }, - { title: "Projects", href: "/projects", icon: FiChevronRight }, - { title: "Freshman", href: "/matricole", icon: FiChevronRight }, - { title: "Associations", href: "/associations", icon: FiChevronRight }, + { title: "Gruppi", href: "/groups", icon: FiChevronRight }, + { title: "Matricole", href: "/matricole", icon: FiChevronRight }, + { title: "Associazioni", href: "/associations", icon: FiChevronRight }, ], }, { - title: "About", + title: "Chi siamo", menu: [ - { title: "About us", href: "/about", icon: FiChevronRight }, - { title: "Join us", href: "/join", icon: FiChevronRight }, - { title: "Contact us", href: "/contact", icon: FiChevronRight }, + { title: "Su di noi", href: "/chi-siamo", icon: FiChevronRight }, + { title: "La nostra storia", href: "/storia", icon: FiChevronRight }, + ], + }, + { + title: "Collabora", + menu: [ + { title: "Struttura", href: "/about", icon: FiChevronRight }, + { title: "I team", href: "/team", icon: FiChevronRight }, + { title: "Unisciti", href: "/join", icon: FiChevronRight }, + { title: "Collabora", href: "/collabora", icon: FiChevronRight }, ], }, ] diff --git a/src/components/header/icon-buttons.tsx b/src/components/header/icon-buttons.tsx index 4cfb0fb..ed28131 100644 --- a/src/components/header/icon-buttons.tsx +++ b/src/components/header/icon-buttons.tsx @@ -1,9 +1,8 @@ -import { FiGlobe, FiMoon, FiUser } from "react-icons/fi" +import { FiGlobe, FiMoon } from "react-icons/fi" import { NavigationMenuLink } from "@/components/ui/navigation-menu" import { cn } from "@/lib/utils" const iconConfigs = [ - { key: "user", label: "User profile", Icon: FiUser, onClick: () => console.log("User icon clicked") }, { key: "globe", label: "Language", Icon: FiGlobe, onClick: () => console.log("Globe icon clicked") }, { key: "moon", label: "Theme", Icon: FiMoon, onClick: () => console.log("Moon icon clicked") }, ] diff --git a/src/components/header/mobile-layout.tsx b/src/components/header/mobile-layout.tsx index 91b13ea..1fb3d76 100644 --- a/src/components/header/mobile-layout.tsx +++ b/src/components/header/mobile-layout.tsx @@ -26,7 +26,7 @@ export const MobileLayout = () => { {mobileMenuOpen && ( -