feat: Gestion des secteurs et migration v3.0.4+304

- Ajout système complet de gestion des secteurs avec contours géographiques
- Import des contours départementaux depuis GeoJSON
- API REST pour la gestion des secteurs (/api/sectors)
- Service de géolocalisation pour déterminer les secteurs
- Migration base de données avec tables x_departements_contours et sectors_adresses
- Interface Flutter pour visualisation et gestion des secteurs
- Ajout thème sombre dans l'application
- Corrections diverses et optimisations

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
pierre
2025-08-07 11:01:45 +02:00
parent 6a609fb467
commit 599b9fcda0
662 changed files with 213221 additions and 174243 deletions

0
web/src/App.svelte Normal file → Executable file
View File

0
web/src/app.css Normal file → Executable file
View File

0
web/src/assets/svelte.svg Normal file → Executable file
View File

Before

Width:  |  Height:  |  Size: 1.9 KiB

After

Width:  |  Height:  |  Size: 1.9 KiB

0
web/src/components/CookieConsent.svelte Normal file → Executable file
View File

0
web/src/components/Footer.svelte Normal file → Executable file
View File

36
web/src/components/Header.svelte Normal file → Executable file
View File

@@ -36,11 +36,14 @@
function changePage(page) {
activePage = page;
window.history.pushState({}, '', `/${page}`);
// Déclencher un événement popstate pour que App.svelte mette à jour la page
window.dispatchEvent(new PopStateEvent('popstate'));
closeMobileMenu();
}
// Fonctions pour le menu mobile
function toggleMobileMenu() {
function toggleMobileMenu(event) {
event.stopPropagation();
mobileMenuOpen = !mobileMenuOpen;
}
@@ -69,7 +72,10 @@
}
};
document.addEventListener('click', handleClickOutside);
// Ajouter un petit délai pour éviter les conflits avec le clic du bouton
setTimeout(() => {
document.addEventListener('click', handleClickOutside);
}, 100);
return () => {
document.removeEventListener('click', handleClickOutside);
@@ -89,7 +95,7 @@
</div>
<!-- Burger menu pour mobile -->
<button id="burger-button" class="xl:hidden z-50" on:click={toggleMobileMenu}>
<button id="burger-button" class="xl:hidden z-50" on:click|stopPropagation={toggleMobileMenu}>
<svg xmlns="http://www.w3.org/2000/svg" class="h-6 w-6 text-[#002C66]" fill="none" viewBox="0 0 24 24" stroke="currentColor">
{#if mobileMenuOpen}
<path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M6 18L18 6M6 6l12 12" />
@@ -117,7 +123,7 @@
<div class="flex gap-3 items-center">
<a
href="{baseAppUrl}/login/user"
href="{baseAppUrl}/?action=login&type=user"
class="border-2 border-[#4CAF50] text-[#4CAF50] hover:bg-[#4CAF50] hover:text-white font-medium py-1.5 px-3 rounded-full transition-colors"
on:click={() => {
sessionStorage.setItem('loginType', 'user');
@@ -126,7 +132,7 @@
Connexion Utilisateur
</a>
<a
href="{baseAppUrl}/login/admin"
href="{baseAppUrl}/?action=login&type=admin"
class="border-2 border-red-600 text-red-600 hover:bg-red-600 hover:text-white font-medium py-1.5 px-3 rounded-full transition-colors"
on:click={() => {
sessionStorage.setItem('loginType', 'admin');
@@ -134,23 +140,15 @@
>
Connexion Administrateur
</a>
<a href="{baseAppUrl}/register" class="bg-[#E3170A] hover:bg-red-700 text-white font-medium py-2 px-4 rounded-full transition-colors"> S'inscrire </a>
<a href="{baseAppUrl}/?action=register" class="bg-[#E3170A] hover:bg-red-700 text-white font-medium py-2 px-4 rounded-full transition-colors"> S'inscrire </a>
</div>
</div>
</div>
</div>
<!-- Menu mobile -->
<div id="mobile-menu" class={`fixed top-0 right-0 h-screen w-4/5 max-w-xs bg-white shadow-lg transform transition-transform duration-300 ease-in-out z-40 ${mobileMenuOpen ? 'translate-x-0' : 'translate-x-full'}`}>
<div class="p-6">
<div class="flex justify-end mb-8">
<button on:click={closeMobileMenu} class="text-gray-600" aria-label="Fermer le menu">
<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="M6 18L18 6M6 6l12 12" />
</svg>
</button>
</div>
<div id="mobile-menu" class={`xl:hidden fixed top-0 right-0 h-screen w-4/5 max-w-xs bg-white shadow-lg transform transition-transform duration-300 ease-in-out z-40 ${mobileMenuOpen ? 'translate-x-0' : 'translate-x-full'}`}>
<div class="p-6 pt-20">
<nav class="mb-8">
<ul class="space-y-4">
<li>
@@ -167,7 +165,7 @@
<div class="space-y-4">
<a
href="{baseAppUrl}/login/user"
href="{baseAppUrl}/?action=login&type=user"
class="block w-full border-2 border-[#4CAF50] text-[#4CAF50] hover:bg-[#4CAF50] hover:text-white font-medium py-2 px-4 rounded-full transition-colors text-center mb-3"
on:click={() => {
sessionStorage.setItem('loginType', 'user');
@@ -176,7 +174,7 @@
Connexion Utilisateur
</a>
<a
href="{baseAppUrl}/login/admin"
href="{baseAppUrl}/?action=login&type=admin"
class="block w-full border-2 border-red-600 text-red-600 hover:bg-red-600 hover:text-white font-medium py-2 px-4 rounded-full transition-colors text-center mb-3"
on:click={() => {
sessionStorage.setItem('loginType', 'admin');
@@ -184,7 +182,7 @@
>
Connexion Administrateur
</a>
<a href="{baseAppUrl}/register" class="block w-full bg-[#E3170A] hover:bg-red-700 text-white font-medium py-2 px-4 rounded-full transition-colors text-center"> S'inscrire </a>
<a href="{baseAppUrl}/?action=register" class="block w-full bg-[#E3170A] hover:bg-red-700 text-white font-medium py-2 px-4 rounded-full transition-colors text-center"> S'inscrire </a>
</div>
</div>
</div>

0
web/src/lib/Counter.svelte Normal file → Executable file
View File

0
web/src/lib/analyticsService.js Normal file → Executable file
View File

0
web/src/lib/cookieService.js Normal file → Executable file
View File

0
web/src/main.js Normal file → Executable file
View File

0
web/src/pages/Accueil.svelte Normal file → Executable file
View File

0
web/src/pages/ConditionsUtilisation.svelte Normal file → Executable file
View File

0
web/src/pages/Contact.svelte Normal file → Executable file
View File

0
web/src/pages/Fonctionnalites.svelte Normal file → Executable file
View File

0
web/src/pages/MentionsLegales.svelte Normal file → Executable file
View File

0
web/src/pages/PolitiqueConfidentialite.svelte Normal file → Executable file
View File

0
web/src/vite-env.d.ts vendored Normal file → Executable file
View File