'use client'; import { useRef } from 'react'; import { motion, useInView } from 'framer-motion'; import { useTranslations } from 'next-intl'; import { Cookie, Settings, BarChart3, Target, Shield, ToggleLeft, Mail, type LucideIcon, } from 'lucide-react'; import { LandingHeader, LandingFooter } from '@/components/layout'; import { ESSENTIAL_STORAGE, FUNCTIONAL_STORAGE, type StoredItem } from '@/lib/legal/processing'; type CookieTypeKey = 'essential' | 'analytics' | 'marketing' | 'functional'; interface CookieTypeConfig { key: CookieTypeKey; icon: LucideIcon; required: boolean; items: readonly StoredItem[]; } /** * Inventaire reel de ce que le site depose. * * La version precedente listait Google Analytics (`_ga`, `_gid`, `_gat`), * Facebook Pixel (`_fbp`), LinkedIn (`li_fat_id`) et HubSpot (`hubspotutk`). * Aucun de ces scripts n'est charge par l'application : annoncer des traceurs * qui n'existent pas est aussi inexact que d'en dissimuler, et rendait le * consentement demande sans objet. Les categories analytiques et marketing * restent affichees, vides, pour que leur absence soit une information. */ const COOKIE_TYPES: CookieTypeConfig[] = [ { key: 'essential', icon: Shield, required: true, items: ESSENTIAL_STORAGE }, { key: 'functional', icon: Settings, required: false, items: FUNCTIONAL_STORAGE }, { key: 'analytics', icon: BarChart3, required: false, items: [] }, { key: 'marketing', icon: Target, required: false, items: [] }, ]; export default function CookiesPage() { const t = useTranslations('marketing.cookies'); const tCommon = useTranslations('marketing.common'); const heroRef = useRef(null); const contentRef = useRef(null); const isHeroInView = useInView(heroRef, { once: true }); const isContentInView = useInView(contentRef, { once: true }); const containerVariants = { hidden: { opacity: 0, y: 50 }, visible: { opacity: 1, y: 0, transition: { duration: 0.6, staggerChildren: 0.1, }, }, }; const itemVariants = { hidden: { opacity: 0, y: 20 }, visible: { opacity: 1, y: 0, transition: { duration: 0.5 }, }, }; return (
{t('intro')}
{tCommon('lastUpdated')}
{t('introBoxBody1')}
{t('introBoxBody2')}
{t('typesSubtitle')}
{t(`types.${type.key}.description`)}
{t('noneInUse')}
) : (| {t('tableHeaders.name')} | {t('tableHeaders.storage')} | {t('tableHeaders.purpose')} | {t('tableHeaders.duration')} |
|---|---|---|---|
| {item.name} | {t(`storageKinds.${item.kind}`)} | {t(`storage.${item.name}.purpose`)} | {t(`storage.${item.name}.duration`)} |
{t('manageIntro')}
{t('manageNote')}
{t('contact.body')}