Add sidebar TOC, simplify Données Secondaires section

- Rename 'Éditer Données Secondaires' → 'Données Secondaires', remove fieldset wrapper on Mots-clés link
- Create admin-toc.php partial: IntersectionObserver-based sidebar nav
- Include TOC on contenus.php, acces.php, parametres.php
- Add .admin-with-toc flex layout (sidebar + main) and .admin-toc CSS
- Fonts (Ductus, BBB DM Sans): verified loaded via variables.css → common.css import chain
- TOC: move inside <main> as <aside>, content in <article>, fix scrolling
- Lazy load: hx-trigger='load delay:100ms' with spinner (htmx-indicator) for tags/langues
- Inline rename: edit button in Nom cell, HTMX post for rename, validate+ cancel buttons
- Checkbox column: width:1% / fit-content
- Remove per-row merge forms/selects, only bulk merge when ≥2 checkboxes selected
- Remove per-row merge dialogs, keep only bulk merge and delete dialogs
- Add htmx-settling CSS transition for lazy-load fade-in
- Update acces.php/parametres.php: article layout, TOC inside main
- TOC: DOMContentLoaded guard, use <nav>+<a> directly instead of <ul>/<li>
- Section spacing: margin-bottom on sections and fieldsets in admin-main--toc
- Language dedup: GROUP BY LOWER(name) in getAllLanguagesWithCount and searchLanguages
- deduplicateLanguages() merges duplicate names and reassigns thesis_languages
- Sticky bulk-actions: position:sticky;top:0;z-index:10
- Tags toolbar: title left, stat count right (margin-left:auto), search bar under
- Tags count stat updated via hx-swap-oob from fragment
- Remove margin/max-width from .admin-main--toc
- Gap between TOC and article: --space-xs, sticky top: --space-xs
- Main padding: --space-s / --space-m / --space-xl (was --space-l/--space-l/--space-2xl)
- Article padding-top: --space-m
This commit is contained in:
Pontoporeia
2026-05-10 12:52:10 +02:00
parent 396cf19e9f
commit a3ded16915
12 changed files with 492 additions and 473 deletions

View File

@@ -48,7 +48,7 @@
flex: 1;
min-height: 0;
overflow-y: auto;
padding: var(--space-l) var(--space-l) var(--space-2xl);
padding: var(--space-s) var(--space-m) var(--space-xl);
width: 100%;
background: linear-gradient(
180deg,
@@ -331,6 +331,9 @@
border-radius: var(--radius);
margin-bottom: var(--space-s);
font-size: var(--step--1);
position: sticky;
top: 0;
z-index: 10;
}
.admin-bulk-btns {
@@ -338,6 +341,14 @@
gap: var(--space-2xs);
}
.admin-stat--inline {
font-size: var(--step--1);
color: var(--text-secondary);
font-weight: 500;
white-space: nowrap;
}
}
/* ── Table ──────────────────────────────────────────────────────────────── */
/* Base table/th/td styles live in common.css */
.admin-body main > table {
@@ -1992,26 +2003,32 @@ th.admin-ap-col {
/* ── Sidebar TOC ───────────────────────────────────────────────────────────── */
.admin-with-toc {
.admin-main--toc {
display: flex;
gap: var(--space-m);
gap: var(--space-xs);
align-items: flex-start;
max-width: var(--content-max-width, 1200px);
margin: 0 auto;
padding: 0 var(--space-s);
}
.admin-with-toc > main {
.admin-main--toc > article {
flex: 1;
min-width: 0;
padding-top: var(--space-m);
}
.admin-main--toc > article > section {
margin-bottom: var(--space-xl);
}
.admin-main--toc > article > section > fieldset {
margin-bottom: var(--space-m);
}
.admin-toc {
position: sticky;
top: var(--space-m);
top: var(--space-xs);
width: 160px;
flex-shrink: 0;
padding-top: var(--space-s);
padding-top: var(--space-m);
}
.admin-toc-list {
@@ -2042,3 +2059,11 @@ th.admin-ap-col {
font-weight: 600;
border-left-color: var(--accent, var(--color-primary));
}
/* ── Lazy-load transition ─────────────────────────────────────────────────── */
.htmx-settling img {
opacity: 0;
}
.htmx-indicator img {
transition: opacity 300ms ease-in;
}