des trucs
This commit is contained in:
@@ -14,13 +14,11 @@
|
||||
</head>
|
||||
<body class="bg-gray-100">
|
||||
<nav class="flex justify-between items-center py-4 px-6 shadow-md bg-gradient-to-r from-[#2A8D57] via-[#008167] to-[#1B5667]">
|
||||
<!-- Logo et Titre -->
|
||||
<a href="/" class="flex items-center space-x-3">
|
||||
<img src="{{ asset('img/logo.svg') }}" alt="Logo" class="h-10">
|
||||
<h3 class="text-3xl text-white font-bold">Sortie</h3>
|
||||
</a>
|
||||
|
||||
<!-- Navigation principale -->
|
||||
<ul class="hidden md:flex space-x-6 text-white font-medium">
|
||||
<li>
|
||||
<a href="{{ path('home') }}"
|
||||
@@ -42,7 +40,6 @@
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
<!-- Profil utilisateur -->
|
||||
<div class="relative">
|
||||
{% if app.user %}
|
||||
<button id="profile-menu" class="flex items-center space-x-2 focus:outline-none">
|
||||
@@ -69,7 +66,6 @@
|
||||
{% endif %}
|
||||
</div>
|
||||
|
||||
<!-- Menu mobile -->
|
||||
<button id="mobile-menu-button" class="md:hidden text-white focus:outline-none">
|
||||
<svg xmlns="http://www.w3.org/2000/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" />
|
||||
@@ -77,7 +73,6 @@
|
||||
</button>
|
||||
</nav>
|
||||
|
||||
<!-- Menu mobile (hidden par défaut) -->
|
||||
<div id="mobile-menu" class="hidden bg-gradient-to-r from-[#2A8D57] via-[#008167] to-[#1B5667] text-white py-4 md:hidden">
|
||||
<ul class="space-y-4 px-6">
|
||||
<li><a href="{{ path('home') }}" class="block hover:text-gray-200">Accueil</a></li>
|
||||
@@ -89,9 +84,7 @@
|
||||
{% block content %}
|
||||
{% endblock %}
|
||||
|
||||
<!-- Scripts -->
|
||||
<script>
|
||||
// Toggle menu pour mobile
|
||||
const mobileMenuButton = document.getElementById('mobile-menu-button');
|
||||
const mobileMenu = document.getElementById('mobile-menu');
|
||||
|
||||
@@ -99,7 +92,6 @@
|
||||
mobileMenu.classList.toggle('hidden');
|
||||
});
|
||||
|
||||
// Toggle menu déroulant pour le profil
|
||||
const profileMenuButton = document.getElementById('profile-menu');
|
||||
const dropdown = document.getElementById('dropdown');
|
||||
|
||||
@@ -109,7 +101,6 @@
|
||||
dropdown.classList.toggle('hidden');
|
||||
});
|
||||
|
||||
// Fermer le menu lorsqu'on clique ailleurs
|
||||
document.addEventListener('click', (event) => {
|
||||
if (!dropdown.classList.contains('hidden')) {
|
||||
const isClickInsideMenu = dropdown.contains(event.target) || profileMenuButton.contains(event.target);
|
||||
|
||||
Reference in New Issue
Block a user