Front utilisable sur téléphone et tablette + suite e2e réparée

- Sous 1024 px : barre haute (menu, arborescence titrée par la campagne ou
  le lore, recherche), menu principal et arborescence en tiroirs (fermeture
  au changement de page, au tap extérieur et avec Échap ; focus gardé dans le
  tiroir puis rendu au bouton). Desktop inchangé, le repli de l'arborescence
  à 44 px fonctionne toujours.
- Règles globales (styles/_responsive.scss) : formulaires sur une colonne
  sous 600 px, boutons d'en-tête qui passent à la ligne, marges de page
  réduites sur téléphone, cibles tactiles agrandies, actions révélées au
  survol visibles en permanence sur écran tactile.
- Écrans corrigés : hub campagne, Lore, dossiers et séance (titres lisibles,
  horloges en 2 colonnes), assistant IA plein écran sur téléphone, listes de
  campagnes et de lores sur une colonne.
- e2e : projet Playwright « mobile » (375 px, tactile) avec 3 tests de
  navigation ; 3 tests desktop périmés corrigés (suite complète 80/80).

Vérifié : aucun scroll horizontal sur 18 écrans à 375/768/1024 px, build web,
vitest, lint sans nouvelle erreur.
À redéployer : web.
This commit is contained in:
2026-10-17 14:00:19 +02:00
parent ad3ea0e9e6
commit 67ac4cc68f
33 changed files with 859 additions and 42 deletions
+47 -3
View File
@@ -1,10 +1,50 @@
<app-update-banner></app-update-banner>
<div class="app-container">
<app-sidebar></app-sidebar>
<!-- Barre haute (< 1024 px) : ouvre les tiroirs menu / arborescence. Masquée en CSS sur desktop. -->
<header class="mobile-topbar">
<button #mainToggle type="button" class="topbar-btn"
aria-controls="app-main-nav"
[attr.aria-expanded]="openDrawer() === 'main'"
[attr.aria-label]="(openDrawer() === 'main' ? 'mobileShell.closeMenu' : 'mobileShell.openMenu') | translate"
(click)="toggleDrawer('main')">
<lucide-icon [img]="openDrawer() === 'main' ? X : Menu" [size]="20"></lucide-icon>
</button>
@if (sidebarConfig$ | async; as config) {
<button #treeToggle type="button" class="topbar-btn topbar-tree"
aria-controls="app-tree-nav"
[attr.aria-expanded]="openDrawer() === 'tree'"
[attr.aria-label]="(openDrawer() === 'tree' ? 'mobileShell.closeTree' : 'mobileShell.openTree') | translate"
(click)="toggleDrawer('tree')">
<lucide-icon [img]="PanelLeft" [size]="18"></lucide-icon>
<span class="topbar-title">{{ config.title }}</span>
</button>
} @else {
<span class="topbar-brand">
<img src="assets/logo.png" alt="" />
<span>DM Loremind</span>
</span>
}
<button type="button" class="topbar-btn topbar-search"
[attr.aria-label]="'mobileShell.search' | translate"
(click)="openSearch()">
<lucide-icon [img]="Search" [size]="18"></lucide-icon>
</button>
</header>
<app-sidebar id="app-main-nav"
[class.drawer-open]="openDrawer() === 'main'"
[attr.role]="isCompact() ? 'dialog' : null"
[attr.aria-modal]="isCompact() && openDrawer() === 'main' ? 'true' : null"
[attr.aria-label]="'mobileShell.mainNav' | translate"></app-sidebar>
@if (sidebarConfig$ | async; as config) {
<app-secondary-sidebar
<app-secondary-sidebar id="app-tree-nav"
[class.drawer-open]="openDrawer() === 'tree'"
[attr.role]="isCompact() ? 'dialog' : null"
[attr.aria-modal]="isCompact() && openDrawer() === 'tree' ? 'true' : null"
[attr.aria-label]="'mobileShell.treeNav' | translate"
[drawerMode]="isCompact()"
[title]="config.title"
[titleRoute]="config.titleRoute || null"
[items]="config.items"
@@ -16,7 +56,11 @@
</app-secondary-sidebar>
}
<main class="main-content">
@if (openDrawer()) {
<div class="drawer-backdrop" aria-hidden="true" (click)="closeDrawer()"></div>
}
<main #mainContent class="main-content" tabindex="-1">
<router-outlet></router-outlet>
</main>
</div>