```
✨ feat(templates/base.twig): Ajoute la logique et le style de Noël.
```
This commit is contained in:
@@ -4,6 +4,10 @@
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
|
||||
{# --- LOGIQUE DE NOËL (15 Déc au 05 Jan) --- #}
|
||||
{% set current_date = "now"|date("m-d") %}
|
||||
{% set is_christmas = (current_date >= "12-15" or current_date <= "01-05") %}
|
||||
|
||||
<title>E-Cosplay | {% block title %}Accueil{% endblock %}</title>
|
||||
<meta name="description" content="{% block meta_description '' %}">
|
||||
|
||||
@@ -43,6 +47,15 @@
|
||||
<meta name="env" content="{{ app.environment }}">
|
||||
{% block canonical_url %}{% endblock %}
|
||||
|
||||
{# STYLES SPÉCIFIQUES NOËL #}
|
||||
{% if is_christmas %}
|
||||
<style>
|
||||
.christmas-border { border-bottom: 4px solid #c41e3a !important; }
|
||||
.christmas-footer { border-top: 4px dashed #c41e3a !important; }
|
||||
.christmas-active-link { color: #c41e3a !important; font-weight: bold; }
|
||||
</style>
|
||||
{% endif %}
|
||||
|
||||
{# SCHÉMAS JSON-LD #}
|
||||
<script type="application/ld+json">
|
||||
{
|
||||
@@ -114,23 +127,22 @@
|
||||
{{ vite_asset('app.js', []) }}
|
||||
{% if app.environment == "prod" %}
|
||||
<script defer src="https://datas.e-cosplay.fr/vs.js"
|
||||
data-website-id="b929d372-fbea-403e-9ae2-781433828787"></script> {% endif %}
|
||||
data-website-id="b929d372-fbea-403e-9ae2-781433828787"></script>
|
||||
<script src="/sc.js" crossorigin="anonymous"></script>
|
||||
<script>
|
||||
Sentry.onLoad(function() {
|
||||
Sentry.init({
|
||||
tunnel:'/tunnel',
|
||||
// Tracing
|
||||
tracesSampleRate: 1.0, // Capture 100% of the transactions
|
||||
// Session Replay
|
||||
replaysSessionSampleRate: 0.1, // This sets the sample rate at 10%. You may want to change it to 100% while in development and then sample at a lower rate in production.
|
||||
replaysOnErrorSampleRate: 1.0, // If you're not already sampling the entire session, change the sample rate to 100% when sampling sessions where errors occur.
|
||||
tracesSampleRate: 1.0,
|
||||
replaysSessionSampleRate: 0.1,
|
||||
replaysOnErrorSampleRate: 1.0,
|
||||
});
|
||||
});
|
||||
</script>
|
||||
{% endif %}
|
||||
</head>
|
||||
{# Le corps aura un fond gris clair pour correspondre au fond du logo #}
|
||||
<body class="flex flex-col min-h-screen bg-gray-100">
|
||||
|
||||
{% set menu_links = [
|
||||
{ 'name': 'Accueil'|trans, 'route': 'app_home' },
|
||||
{ 'name': 'Qui sommes-nous'|trans, 'route': 'app_about' },
|
||||
@@ -143,212 +155,105 @@
|
||||
{ 'name': 'Nous rejoindre'|trans, 'route': 'app_recruit' },
|
||||
{ 'name': 'Contact'|trans, 'route': 'app_contact' }
|
||||
] %}
|
||||
<header class="bg-white shadow-md sticky top-0 z-40">
|
||||
|
||||
<header class="bg-white shadow-md sticky top-0 z-40 {% if is_christmas %}christmas-border{% endif %}">
|
||||
<nav class="mx-auto px-4 sm:px-6 lg:px-8">
|
||||
<div class="flex justify-between items-center h-16">
|
||||
{# LOGO / NOM DU SITE #}
|
||||
|
||||
{# LOGO AVEC BONNET DE NOËL #}
|
||||
<div class="flex-shrink-0 flex items-center">
|
||||
|
||||
<a href="{{ path('app_home') }}" class="flex items-center space-x-2 text-xl font-bold text-gray-900">
|
||||
<a href="{{ path('app_home') }}" class="flex items-center space-x-2 text-xl font-bold text-gray-900 relative">
|
||||
{% if is_christmas %}
|
||||
<span class="absolute -top-3 -left-3 text-xl z-10 select-none transform -rotate-12">🎅</span>
|
||||
{% endif %}
|
||||
<img class="h-8 w-auto" width="57px" height="32px" src="{{ asset('assets/images/logo.jpg') | imagine_filter('logo') }}"
|
||||
alt="E-Cosplay Logo">
|
||||
{# Le texte du nom du site peut rester en noir pour la lisibilité #}
|
||||
<span class="text-gray-900">E-Cosplay</span>
|
||||
</a>
|
||||
</div>
|
||||
|
||||
{# LIENS DE NAVIGATION (Desktop) #}
|
||||
{# NAVIGATION DESKTOP #}
|
||||
<div class="hidden md:flex md:space-x-4 items-center">
|
||||
{# Liens de navigation #}
|
||||
<div class="hidden md:flex md:space-x-1">
|
||||
{% for link in menu_links %}
|
||||
{% set is_active = (app.request.get('_route') == link.route) %}
|
||||
|
||||
<a href="{{ path(link.route) }}"
|
||||
class="{% if is_active %}bg-gray-100 text-red-800{% else %}text-gray-700 hover:bg-gray-100 hover:text-red-800{% endif %} px-3 py-2 rounded-md text-sm font-medium">
|
||||
class="{% if is_active %}bg-gray-100 {% if is_christmas %}christmas-active-link{% else %}text-red-800{% endif %}{% else %}text-gray-700 hover:bg-gray-100 hover:text-red-800{% endif %} px-3 py-2 rounded-md text-sm font-medium transition duration-150">
|
||||
{{ link.name }}
|
||||
</a>
|
||||
{% endfor %}
|
||||
</div>
|
||||
|
||||
{# SÉLECTEUR DE LANGUE (Desktop) #}
|
||||
{# SÉLECTEUR DE LANGUE #}
|
||||
<div class="flex items-center space-x-2 border-l border-gray-200 pl-4">
|
||||
{% set current_route = app.request.attributes.get('_route','app_home') %}
|
||||
{% set current_params = app.request.attributes.get('_route_params',[]) %}
|
||||
|
||||
{# Fonction pour générer le chemin avec le paramètre 'lang' (doit être définie dans une extension Twig) #}
|
||||
{# En attendant, nous générons l'URL manuellement #}
|
||||
{% set current_query = app.request.query.all %}
|
||||
|
||||
{% for lang in ['fr', 'en','cn'] %}
|
||||
{% set is_active_lang = (app.request.locale == lang) %}
|
||||
{% set lang_params = current_params|merge(current_query)|merge({'lang': lang}) %}
|
||||
{# Générer l'URL en conservant les paramètres existants + le paramètre 'lang' #}
|
||||
{% set lang_url = path(current_route, lang_params) %}
|
||||
|
||||
<a href="{{ lang_url }}"
|
||||
class="text-xs font-bold uppercase transition duration-150 ease-in-out {% if is_active_lang %}text-red-600 border-b-2 border-red-600{% else %}text-gray-500 hover:text-red-600{% endif %}">
|
||||
{% set lang_url = path(current_route, current_params|merge(current_query)|merge({'lang': lang})) %}
|
||||
<a href="{{ lang_url }}" class="text-xs font-bold uppercase transition duration-150 {% if is_active_lang %}text-red-600 border-b-2 border-red-600{% else %}text-gray-500 hover:text-red-600{% endif %}">
|
||||
{{ lang }}
|
||||
</a>
|
||||
{% endfor %}
|
||||
</div>
|
||||
|
||||
{# BOUTON PANIER (Desktop) #}
|
||||
<button id="openCartDesktop" type="button"
|
||||
class="relative p-2 text-gray-700 hover:text-red-600 rounded-full transition duration-150 ease-in-out">
|
||||
<span class="sr-only">{{ 'open_cart_sr'|trans }}</span>
|
||||
{# PANIER #}
|
||||
<button id="openCartDesktop" type="button" class="relative p-2 text-gray-700 hover:text-red-600 rounded-full">
|
||||
<svg class="h-6 w-6" fill="none" viewBox="0 0 24 24" stroke="currentColor">
|
||||
<path stroke-linecap="round" stroke-linejoin="round" stroke-width="2"
|
||||
d="M3 3h2l.4 2M7 13h10l4-8H5.4M7 13L5.4 5M7 13l-2.293 2.293c-.63.63-.184 1.707.707 1.707H17m0 0a2 2 0 100 4 2 2 0 000-4zm-8 2a2 2 0 11-4 0 2 2 0 014 0z"/>
|
||||
<path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M3 3h2l.4 2M7 13h10l4-8H5.4M7 13L5.4 5M7 13l-2.293 2.293c-.63.63-.184 1.707.707 1.707H17m0 0a2 2 0 100 4 2 2 0 000-4zm-8 2a2 2 0 11-4 0 2 2 0 014 0z"/>
|
||||
</svg>
|
||||
{# Compteur Panier - Initialisé à 0 #}
|
||||
<span id="cartCountDesktop"
|
||||
class="absolute top-0 right-0 inline-flex items-center justify-center px-2 py-1 text-xs font-bold leading-none text-white transform translate-x-1/2 -translate-y-1/2 bg-red-600 rounded-full">
|
||||
0
|
||||
</span>
|
||||
<span id="cartCountDesktop" class="absolute top-0 right-0 inline-flex items-center justify-center px-2 py-1 text-xs font-bold leading-none text-white transform translate-x-1/2 -translate-y-1/2 bg-red-600 rounded-full">0</span>
|
||||
</button>
|
||||
|
||||
{# NOUVEAU: COMPTE / MENU DÉROULANT (Desktop) #}
|
||||
{# COMPTE #}
|
||||
<div class="relative">
|
||||
<button id="userMenuButtonDesktop" type="button"
|
||||
class="p-2 text-gray-700 hover:text-red-600 rounded-full transition duration-150 ease-in-out"
|
||||
aria-expanded="false" aria-haspopup="true">
|
||||
<span class="sr-only">{{ 'open_user_menu_sr'|trans }}</span>
|
||||
{# Icône de l'utilisateur (Heroicons 'User') #}
|
||||
<button id="userMenuButtonDesktop" type="button" class="p-2 text-gray-700 hover:text-red-600 rounded-full">
|
||||
<svg class="h-6 w-6" fill="none" viewBox="0 0 24 24" stroke="currentColor">
|
||||
<path stroke-linecap="round" stroke-linejoin="round" stroke-width="2"
|
||||
d="M16 7a4 4 0 11-8 0 4 4 0 018 0zM12 14a7 7 0 00-7 7h14a7 7 0 00-7-7z"/>
|
||||
<path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M16 7a4 4 0 11-8 0 4 4 0 018 0zM12 14a7 7 0 00-7 7h14a7 7 0 00-7-7z"/>
|
||||
</svg>
|
||||
</button>
|
||||
|
||||
{# Menu déroulant (Masqué par défaut avec 'hidden') #}
|
||||
<div id="userMenuDesktop"
|
||||
class="origin-top-right absolute right-0 mt-2 w-48 rounded-md shadow-lg bg-white ring-1 ring-black ring-opacity-5 hidden"
|
||||
role="menu" aria-orientation="vertical" aria-labelledby="user-menu-button">
|
||||
<div class="py-1" role="none">
|
||||
<div id="userMenuDesktop" class="origin-top-right absolute right-0 mt-2 w-48 rounded-md shadow-lg bg-white ring-1 ring-black ring-opacity-5 hidden z-50">
|
||||
<div class="py-1">
|
||||
{% if is_granted('ROLE_USER') %}
|
||||
{# Afficher le nom de l'utilisateur et la déconnexion si connecté #}
|
||||
<div
|
||||
class="block px-4 py-2 text-sm text-gray-900 font-semibold border-b border-gray-100">
|
||||
{{ 'logged_in_as'|trans }} {{ app.user.username|default('Compte') }}
|
||||
</div>
|
||||
<a href="{{ path('admin_dashboard') }}"
|
||||
class="block px-4 py-2 text-sm text-cyan-600 hover:bg-gray-100" role="menuitem"
|
||||
tabindex="-1">
|
||||
{{ 'logged_admin'|trans }}
|
||||
</a>
|
||||
<a href="{{ path('app_logout') }}"
|
||||
class="block px-4 py-2 text-sm text-red-600 hover:bg-gray-100" role="menuitem"
|
||||
tabindex="-1">
|
||||
{{ 'logout_link'|trans }}
|
||||
</a>
|
||||
<div class="block px-4 py-2 text-sm text-gray-900 font-semibold border-b border-gray-100">{{ app.user.username|default('Compte') }}</div>
|
||||
<a href="{{ path('admin_dashboard') }}" class="block px-4 py-2 text-sm text-cyan-600 hover:bg-gray-100">{{ 'logged_admin'|trans }}</a>
|
||||
<a href="{{ path('app_logout') }}" class="block px-4 py-2 text-sm text-red-600 hover:bg-gray-100">{{ 'logout_link'|trans }}</a>
|
||||
{% else %}
|
||||
{# Afficher la connexion si non connecté #}
|
||||
<a href="{{ path('app_login') }}"
|
||||
class="block px-4 py-2 text-sm text-gray-700 hover:bg-gray-100" role="menuitem"
|
||||
tabindex="-1" id="user-menu-item-0">
|
||||
{{ 'login_link'|trans }}
|
||||
</a>
|
||||
<a href="{{ path('app_login') }}" class="block px-4 py-2 text-sm text-gray-700 hover:bg-gray-100">{{ 'login_link'|trans }}</a>
|
||||
{% endif %}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{# BOUTONS MOBILE (Burger Icon, Panier, Langue, et Compte) #}
|
||||
{# MOBILE ICONS #}
|
||||
<div class="md:hidden flex items-center space-x-2">
|
||||
{# NOUVEAU: COMPTE / MENU DÉROULANT (Mobile) #}
|
||||
<div class="relative">
|
||||
<button id="userMenuButtonMobile" type="button"
|
||||
class="p-2 text-gray-700 hover:text-red-600 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-red-500 rounded-md"
|
||||
aria-expanded="false" aria-haspopup="true">
|
||||
<span class="sr-only">{{ 'open_user_menu_sr'|trans }}</span>
|
||||
{# Icône de l'utilisateur (Heroicons 'User') #}
|
||||
<svg class="h-6 w-6" fill="none" viewBox="0 0 24 24" stroke="currentColor">
|
||||
<path stroke-linecap="round" stroke-linejoin="round" stroke-width="2"
|
||||
d="M16 7a4 4 0 11-8 0 4 4 0 018 0zM12 14a7 7 0 00-7 7h14a7 7 0 00-7-7z"/>
|
||||
</svg>
|
||||
</button>
|
||||
{# Le menu déroulant Mobile peut être affiché via le JS global si l'espace le permet #}
|
||||
<div id="userMenuMobile"
|
||||
class="origin-top-right absolute right-0 mt-2 w-48 rounded-md shadow-lg bg-white ring-1 ring-black ring-opacity-5 hidden"
|
||||
role="menu" aria-orientation="vertical" aria-labelledby="user-menu-button-mobile">
|
||||
<div class="py-1" role="none">
|
||||
{% if is_granted('ROLE_USER') %}
|
||||
<div
|
||||
class="block px-4 py-2 text-sm text-gray-900 font-semibold border-b border-gray-100">
|
||||
{{ 'logged_in_as'|trans }} {{ app.user.username|default('Compte') }}
|
||||
</div>
|
||||
|
||||
{% else %}
|
||||
<a href="{{ path('app_login') }}"
|
||||
class="block px-4 py-2 text-sm text-gray-700 hover:bg-gray-100" role="menuitem"
|
||||
tabindex="-1">
|
||||
{{ 'login_link'|trans }}
|
||||
</a>
|
||||
{% endif %}
|
||||
</div>
|
||||
<button id="userMenuButtonMobile" type="button" class="p-2 text-gray-700 hover:text-red-600"><svg class="h-6 w-6" fill="none" viewBox="0 0 24 24" stroke="currentColor"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M16 7a4 4 0 11-8 0 4 4 0 018 0zM12 14a7 7 0 00-7 7h14a7 7 0 00-7-7z"/></svg></button>
|
||||
<div id="userMenuMobile" class="origin-top-right absolute right-0 mt-12 w-48 rounded-md shadow-lg bg-white ring-1 ring-black ring-opacity-5 hidden z-50">
|
||||
<div class="py-1">
|
||||
{% if is_granted('ROLE_USER') %}<div class="block px-4 py-2 text-sm text-gray-900 font-semibold border-b border-gray-100">{{ app.user.username }}</div>{% else %}<a href="{{ path('app_login') }}" class="block px-4 py-2 text-sm text-gray-700 hover:bg-gray-100">{{ 'login_link'|trans }}</a>{% endif %}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{# SÉLECTEUR DE LANGUE (Mobile - Compact) #}
|
||||
<div class="flex items-center space-x-2">
|
||||
{% set current_route = app.request.attributes.get('_route','app_home') %}
|
||||
{% set current_params = app.request.attributes.get('_route_params',[]) %}
|
||||
{% set current_query = app.request.query.all %}
|
||||
|
||||
{% for lang in ['fr', 'en', 'cn'] %}
|
||||
{% set is_active_lang = (app.request.locale == lang) %}
|
||||
{% set lang_params = current_params|merge(current_query)|merge({'lang': lang}) %}
|
||||
{% set lang_url = path(current_route, lang_params) %}
|
||||
|
||||
<a href="{{ lang_url }}"
|
||||
class="text-xs font-bold uppercase transition duration-150 ease-in-out {% if is_active_lang %}text-red-600 border-b-2 border-red-600{% else %}text-gray-500 hover:text-red-600{% endif %}">
|
||||
{{ lang }}
|
||||
</a>
|
||||
{% endfor %}
|
||||
</div>
|
||||
|
||||
{# BOUTON PANIER (Mobile) #}
|
||||
<button id="openCartMobile" type="button"
|
||||
class="relative p-2 text-gray-700 hover:text-red-600 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-red-500 rounded-md">
|
||||
<span class="sr-only">{{ 'open_cart_sr'|trans }}</span>
|
||||
<svg class="h-6 w-6" fill="none" viewBox="0 0 24 24" stroke="currentColor">
|
||||
<path stroke-linecap="round" stroke-linejoin="round" stroke-width="2"
|
||||
d="M3 3h2l.4 2M7 13h10l4-8H5.4M7 13L5.4 5M7 13l-2.293 2.293c-.63.63-.184 1.707.707 1.707H17m0 0a2 2 0 100 4 2 2 0 000-4zm-8 2a2 2 0 11-4 0 2 2 0 014 0z"/>
|
||||
</svg>
|
||||
{# Compteur Panier - Initialisé à 0 #}
|
||||
<span id="cartCountMobile"
|
||||
class="absolute top-0 right-0 inline-flex items-center justify-center px-2 py-1 text-xs font-bold leading-none text-white transform translate-x-1/2 -translate-y-1/2 bg-red-600 rounded-full">
|
||||
0
|
||||
</span>
|
||||
</button>
|
||||
|
||||
{# BOUTON MOBILE (Burger Icon) #}
|
||||
<button id="mobileMenuButton" type="button"
|
||||
class="text-red-500 hover:text-red-700 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-red-500 p-2 rounded-md"
|
||||
aria-controls="mobile-menu" aria-expanded="false">
|
||||
<span class="sr-only">{{ 'open_main_menu_sr'|trans }}</span>
|
||||
<svg class="h-6 w-6" xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24"
|
||||
stroke="currentColor">
|
||||
<path stroke-linecap="round" stroke-linejoin="round" stroke-width="2"
|
||||
d="M4 6h16M4 12h16M4 18h16"/>
|
||||
</svg>
|
||||
</button>
|
||||
<button id="openCartMobile" type="button" class="relative p-2 text-gray-700"><svg class="h-6 w-6" fill="none" viewBox="0 0 24 24" stroke="currentColor"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M3 3h2l.4 2M7 13h10l4-8H5.4M7 13L5.4 5M7 13l-2.293 2.293c-.63.63-.184 1.707.707 1.707H17m0 0a2 2 0 100 4 2 2 0 000-4zm-8 2a2 2 0 11-4 0 2 2 0 014 0z"/></svg><span id="cartCountMobile" class="absolute top-0 right-0 inline-flex items-center justify-center px-2 py-1 text-xs font-bold text-white bg-red-600 rounded-full">0</span></button>
|
||||
<button id="mobileMenuButton" type="button" class="text-red-500 p-2"><svg class="h-6 w-6" fill="none" viewBox="0 0 24 24" stroke="currentColor"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M4 6h16M4 12h16M4 18h16"/></svg></button>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</nav>
|
||||
|
||||
{# MENU MOBILE (Contenu caché) #}
|
||||
{# MOBILE MENU #}
|
||||
<div class="md:hidden hidden" id="mobile-menu">
|
||||
<div class="px-2 pt-2 pb-3 space-y-1 sm:px-3">
|
||||
{% if is_christmas %}
|
||||
<div class="px-3 py-2 text-sm font-bold text-red-600 border-b border-red-100 flex items-center justify-between">
|
||||
<span>🎄 Joyeuses Fêtes !</span>
|
||||
<span class="text-xs font-normal opacity-70">15 déc. - 05 janv.</span>
|
||||
</div>
|
||||
{% endif %}
|
||||
{% for link in menu_links %}
|
||||
{% set is_active = (app.request.get('_route') == link.route) %}
|
||||
|
||||
<a href="{{ path(link.route) }}"
|
||||
class="block {% if is_active %}bg-gray-100 text-red-600{% else %}text-gray-700 hover:bg-gray-100 hover:text-red-600{% endif %} px-3 py-2 rounded-md text-base font-medium">
|
||||
class="block {% if is_active %}bg-gray-100 text-red-600{% else %}text-gray-700 hover:bg-gray-100 hover:text-red-600{% endif %} px-3 py-2 rounded-md text-base font-medium transition duration-150">
|
||||
{{ link.name }}
|
||||
</a>
|
||||
{% endfor %}
|
||||
@@ -357,174 +262,71 @@
|
||||
</header>
|
||||
|
||||
<main role="main" class="flex-grow">
|
||||
|
||||
{% block body %}{% endblock %}
|
||||
</main>
|
||||
|
||||
{# ========================================================== #}
|
||||
{# PANIER LATÉRAL (OFF-CANVAS CART) #}
|
||||
{# Utilise Tailwind pour les transitions et l'accessibilité #}
|
||||
{# Le panier sera masqué par défaut (translate-x-full) #}
|
||||
<div id="cartSidebar"
|
||||
class="fixed top-0 right-0 w-full md:w-96 h-full bg-white shadow-xl transform translate-x-full transition-transform duration-300 ease-in-out z-50 flex flex-col">
|
||||
|
||||
{# Entête du panier #}
|
||||
{# OFF-CANVAS CART #}
|
||||
<div id="cartSidebar" class="fixed top-0 right-0 w-full md:w-96 h-full bg-white shadow-xl transform translate-x-full transition-transform duration-300 ease-in-out z-50 flex flex-col">
|
||||
<div class="p-4 border-b border-gray-200 flex justify-between items-center">
|
||||
<h2 class="text-xl font-bold text-gray-900">{{ 'your_cart'|trans }}</h2>
|
||||
<button id="closeCartButton" type="button"
|
||||
class="text-gray-400 hover:text-gray-600 p-2 rounded-full transition duration-150 ease-in-out">
|
||||
<span class="sr-only">{{ 'close_cart_sr'|trans }}</span>
|
||||
<svg class="h-6 w-6" fill="none" viewBox="0 0 24 24" stroke="currentColor">
|
||||
<path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M6 18L18 6M6 6l12 12"/>
|
||||
</svg>
|
||||
<button id="closeCartButton" type="button" class="text-gray-400 hover:text-gray-600 p-2 rounded-full transition duration-150">
|
||||
<svg class="h-6 w-6" fill="none" viewBox="0 0 24 24" stroke="currentColor"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M6 18L18 6M6 6l12 12"/></svg>
|
||||
</button>
|
||||
</div>
|
||||
|
||||
{# Contenu du Panier (Défilement) #}
|
||||
<div id="cartItemsContainer" class="flex-grow overflow-y-auto p-4 space-y-4">
|
||||
{# Espace pour les articles du panier - Contenu mocké pour l'exemple #}
|
||||
<div class="text-center text-gray-500 py-12">
|
||||
<svg class="mx-auto h-12 w-12 text-gray-400" fill="none" viewBox="0 0 24 24" stroke="currentColor">
|
||||
<path stroke-linecap="round" stroke-linejoin="round" stroke-width="2"
|
||||
d="M3 3h2l.4 2M7 13h10l4-8H5.4M7 13L5.4 5M7 13l-2.293 2.293c-.63.63-.184 1.707.707 1.707H17m0 0a2 2 0 100 4 2 2 0 000-4zm-8 2a2 2 0 11-4 0 2 2 0 014 0z"/>
|
||||
</svg>
|
||||
<svg class="mx-auto h-12 w-12 text-gray-400" fill="none" viewBox="0 0 24 24" stroke="currentColor"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M3 3h2l.4 2M7 13h10l4-8H5.4M7 13L5.4 5M7 13l-2.293 2.293c-.63.63-.184 1.707.707 1.707H17m0 0a2 2 0 100 4 2 2 0 000-4zm-8 2a2 2 0 11-4 0 2 2 0 014 0z"/></svg>
|
||||
<p class="mt-1">{{ 'cart_empty'|trans }}</p>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{# Pied de page du panier (Total et Paiement) #}
|
||||
<div class="p-4 border-t border-gray-200">
|
||||
<div class="flex justify-between font-bold text-lg mb-4">
|
||||
<span>{{ 'subtotal_label'|trans }}:</span>
|
||||
<span id="cartSubtotal">0.00 €</span>
|
||||
</div>
|
||||
<a href=""
|
||||
class="w-full block text-center bg-red-600 text-white py-3 rounded-md hover:bg-red-700 transition duration-150 ease-in-out font-semibold">
|
||||
{{ 'checkout_button'|trans }}
|
||||
</a>
|
||||
<p class="text-xs text-gray-500 text-center mt-2">{{ 'shipping_disclaimer'|trans }}</p>
|
||||
<a href="" class="w-full block text-center bg-red-600 text-white py-3 rounded-md hover:bg-red-700 transition duration-150 font-semibold">{{ 'checkout_button'|trans }}</a>
|
||||
</div>
|
||||
</div>
|
||||
<div id="cartBackdrop" class="fixed inset-0 bg-black opacity-50 z-40 hidden transition-opacity duration-300" aria-hidden="true"></div>
|
||||
|
||||
{# FONDU NOIR (Backdrop) - S'affiche lorsque le panier est ouvert #}
|
||||
<div id="cartBackdrop" class="fixed inset-0 bg-op z-40 hidden transition-opacity duration-300 ease-in-out"
|
||||
aria-hidden="true"></div>
|
||||
{# ========================================================== #}
|
||||
|
||||
|
||||
<footer class="bg-[#FABF04] text-gray-900 border-t border-red-600">
|
||||
<footer class="bg-[#FABF04] text-gray-900 border-t {% if is_christmas %}christmas-footer{% else %}border-red-600{% endif %}">
|
||||
<div class="max-w-7xl mx-auto py-8 px-4 sm:px-6 lg:px-8">
|
||||
|
||||
{# BLOC DE CONTACT ET RÉSEAUX (Utilise le block footer pour l'emplacement) #}
|
||||
{% block footer %}
|
||||
<div class="grid grid-cols-1 md:grid-cols-3 gap-8 pb-6 mb-4 border-b border-gray-600">
|
||||
|
||||
{# 1. Coordonnées #}
|
||||
<div>
|
||||
<h3 class="text-lg font-semibold mb-3 text-gray-900">{{ 'footer_contact_title'|trans }}</h3>
|
||||
<p class="text-sm text-gray-700">
|
||||
42 rue de Saint-Quentin<br>
|
||||
02800 Beautor, FRANCE
|
||||
</p>
|
||||
<p class="text-sm text-gray-700 mt-2">
|
||||
<a href="mailto:contact@e-cosplay.fr"
|
||||
class="hover:text-red-600 transition duration-150 ease-in-out">contact@e-cosplay.fr</a>
|
||||
</p>
|
||||
<p class="text-sm text-gray-700">42 rue de Saint-Quentin<br>02800 Beautor, FRANCE</p>
|
||||
<p class="text-sm text-gray-700 mt-2"><a href="mailto:contact@e-cosplay.fr" class="hover:text-red-600">contact@e-cosplay.fr</a></p>
|
||||
</div>
|
||||
|
||||
{# 2. Réseaux Sociaux #}
|
||||
<div style="height: 210px">
|
||||
<div>
|
||||
<h3 class="text-lg font-semibold mb-3 text-gray-900">{{ 'footer_follow_us_title'|trans }}</h3>
|
||||
<div class="flex space-x-4">
|
||||
<a href="https://www.facebook.com/assocationecosplay" target="_blank" rel="noopener noreferrer"
|
||||
class="text-gray-700 hover:text-red-600 transition duration-150 ease-in-out"
|
||||
aria-label="Facebook">
|
||||
<img src="{{ asset('assets/social/facebook.svg') }}" alt="logo instagram" width="30" height="30">
|
||||
</a>
|
||||
<a href="https://www.instagram.com/asso_ecosplay/" target="_blank" rel="noopener noreferrer"
|
||||
class="text-gray-700 hover:text-red-600 transition duration-150 ease-in-out"
|
||||
aria-label="Instagram">
|
||||
<img src="{{ asset('assets/social/instagram.svg') }}" alt="logo instagram" width="30" height="30">
|
||||
|
||||
</a>
|
||||
<div class="flex space-x-4 mb-4">
|
||||
<a href="https://www.facebook.com/assocationecosplay" target="_blank" class="text-gray-700 hover:text-red-600 transition"><img src="{{ asset('assets/social/facebook.svg') }}" width="30" height="30" alt="FB"></a>
|
||||
<a href="https://www.instagram.com/asso_ecosplay/" target="_blank" class="text-gray-700 hover:text-red-600 transition"><img src="{{ asset('assets/social/instagram.svg') }}" width="30" height="30" alt="IG"></a>
|
||||
</div>
|
||||
<h3 class="text-lg font-semibold mb-3 text-gray-900 py-1">{{ 'footer_action_title'|trans }}</h3>
|
||||
{% if isMobile() %}
|
||||
{% set stripeWidth ="100%" %}
|
||||
{% set stripeHeight ="60" %}
|
||||
{% else %}
|
||||
{% set stripeWidth ="400" %}
|
||||
{% set stripeHeight ="40" %}
|
||||
{% endif %}
|
||||
<iframe width="{{ stripeWidth }}" height="{{ stripeHeight }}" style="border:0;" src="https://climate.stripe.com/badge/qrsnOf?theme=light&size=small&locale={{ app.request.locale }}-{{ app.request.locale|upper }}"></iframe>
|
||||
<iframe width="{{ stripeWidth }}" height="{{ stripeHeight }}" style="border:0;margin-top: 0.5rem" src="https://climate.stripe.com/badge/7oAh3V?theme=light&size=small&locale={{ app.request.locale }}-{{ app.request.locale|upper }}"></iframe>
|
||||
{% set stripeWidth = isMobile() ? "100%" : "400" %}
|
||||
<iframe width="{{ stripeWidth }}" height="40" style="border:0;" src="https://climate.stripe.com/badge/qrsnOf?theme=light&size=small&locale={{ app.request.locale }}-{{ app.request.locale|upper }}"></iframe>
|
||||
</div>
|
||||
|
||||
{# 3. Bloc Personnalisable (E-Cosplay mission) #}
|
||||
<div>
|
||||
<h3 class="text-lg font-semibold mb-3 text-gray-900">E-Cosplay</h3>
|
||||
{{ 'footer_mission_description'|trans|raw }}
|
||||
<div class="trustpilot-widget" data-locale="fr-FR" data-template-id="56278e9abfbbba0bdcd568bc"
|
||||
data-businessunit-id="687e8cb6a48c5eab447ca0f8" data-style-height="52px"
|
||||
data-style-width="100%" data-token="797aa44d-2b0e-46f8-bfe9-fe0a75cbe557">
|
||||
<a href="https://fr.trustpilot.com/review/e-cosplay.fr" target="_blank" rel="noopener">Trustpilot</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
{% endblock %}
|
||||
|
||||
{# LIGNE DE COPYRIGHT ET MENTIONS LÉGALES (Bas du footer) #}
|
||||
<div class="md:flex md:justify-between md:items-center">
|
||||
|
||||
{# Copyright et Mention Légale Association #}
|
||||
<div class="md:flex md:justify-between md:items-center text-sm">
|
||||
<div class="text-center md:text-left mb-4 md:mb-0">
|
||||
<p class="text-sm text-gray-700">
|
||||
© {{ "now"|date("Y") }} E-Cosplay. {{ 'all_rights_reserved'|trans }}.
|
||||
</p>
|
||||
<p class="text-xs text-gray-600 mt-1">
|
||||
{{ 'association_status'|trans }} - RNA N°W022006988
|
||||
</p>
|
||||
<p class="text-xs text-gray-600 mt-1">
|
||||
{{ 'footer_realise'|trans }} <a target="_blank" href="https://www.siteconsei.fr">SARL SITECONSEIL</a>
|
||||
</p>
|
||||
<p>© {{ "now"|date("Y") }} E-Cosplay. {{ 'all_rights_reserved'|trans }}.</p>
|
||||
<p class="text-xs text-gray-600 mt-1">RNA N°W022006988 - {{ 'footer_realise'|trans }} <a href="https://www.siteconsei.fr" target="_blank">SITECONSEIL</a></p>
|
||||
</div>
|
||||
|
||||
{# Liens Légaux #}
|
||||
{# Liens Légaux - Fixé pour l'accessibilité tactile (Touch Target) #}
|
||||
<div class="flex flex-wrap justify-center md:justify-end gap-x-6 gap-y-2 text-sm font-medium">
|
||||
<a href="{{ path('app_legal') }}"
|
||||
class="text-gray-800 hover:text-red-600 transition duration-150 ease-in-out p-3 rounded-lg hover:bg-gray-100">
|
||||
{{ 'legal_notice_link'|trans }}
|
||||
</a>
|
||||
<a href="{{ path('app_cookies') }}"
|
||||
class="text-gray-800 hover:text-red-600 transition duration-150 ease-in-out p-3 rounded-lg hover:bg-gray-100">
|
||||
{{ 'cookie_policy_link'|trans }}
|
||||
</a>
|
||||
<a href="{{ path('app_hosting') }}"
|
||||
class="text-gray-800 hover:text-red-600 transition duration-150 ease-in-out p-3 rounded-lg hover:bg-gray-100">
|
||||
{{ 'hosting_link'|trans }}
|
||||
</a>
|
||||
<a href="{{ path('app_rgpd') }}"
|
||||
class="text-gray-800 hover:text-red-600 transition duration-150 ease-in-out p-3 rounded-lg hover:bg-gray-100">
|
||||
{{ 'rgpd_policy_link'|trans }}
|
||||
</a>
|
||||
<a href="{{ path('app_cgu') }}"
|
||||
class="text-gray-800 hover:text-red-600 transition duration-150 ease-in-out p-3 rounded-lg hover:bg-gray-100">
|
||||
{{ 'cgu_link'|trans }}
|
||||
</a>
|
||||
<a href="{{ path('app_cgv') }}"
|
||||
class="text-gray-800 hover:text-red-600 transition duration-150 ease-in-out p-3 rounded-lg hover:bg-gray-100">
|
||||
{{ 'cgv_link'|trans }}
|
||||
</a>
|
||||
<div class="flex flex-wrap justify-center md:justify-end gap-2">
|
||||
<a href="{{ path('app_legal') }}" class="px-2 hover:text-red-600">{{ 'legal_notice_link'|trans }}</a>
|
||||
<a href="{{ path('app_cookies') }}" class="px-2 hover:text-red-600">{{ 'cookie_policy_link'|trans }}</a>
|
||||
<a href="{{ path('app_cgu') }}" class="px-2 hover:text-red-600">{{ 'cgu_link'|trans }}</a>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</footer>
|
||||
|
||||
|
||||
|
||||
</body>
|
||||
</html>
|
||||
|
||||
Reference in New Issue
Block a user