From 0a1962194948b944017f1e939638487e9494f1d7 Mon Sep 17 00:00:00 2001 From: stephan Date: Wed, 22 Jul 2026 14:45:33 -0400 Subject: [PATCH] =?UTF-8?q?MSIN-4475=20=E2=80=94=20Refactor=20CSS=20for=20?= =?UTF-8?q?improved=20layout=20and=20responsiveness=20in=20assignment=20mo?= =?UTF-8?q?des.=20Update=20JavaScript=20to=20enable=20immediate=20tool=20d?= =?UTF-8?q?isplay=20without=20tile=20clicks,=20and=20adjust=20PHP=20for=20?= =?UTF-8?q?seamless=20workspace=20transitions.=20Increment=20version=20cod?= =?UTF-8?q?e=20to=204.72.867.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- css/style.css | 65 ++++++++++++++++++++-------------------- js/v2/bib-assignments.js | 34 ++++++++++++++++++--- php/inc_fx_promoteur.php | 19 +++++++----- php/inc_settings.php | 2 +- 4 files changed, 76 insertions(+), 44 deletions(-) diff --git a/css/style.css b/css/style.css index aa79046..0a0f002 100644 --- a/css/style.css +++ b/css/style.css @@ -2605,15 +2605,11 @@ ul.ms1-menu-compte li a:hover, ul.ms1-menu-compte li a:active { .epr-block-assign .bib-container{ width:100%; min-width:0; + /* MSIN-4475 — filet mobile étroit seulement ; plus de min-width 1100px (slider inutile). */ overflow-x:auto; -webkit-overflow-scrolling:touch; } -.epr-block-assign .bib-container .epr-line{ - /* MSIN-4475 — place pour le badge auto en fin de ligne. */ - min-width:1100px; -} - .epr-line-header{ background:#fff3cd; font-weight:700; @@ -2869,11 +2865,16 @@ ul.ms1-menu-compte li a:hover, ul.ms1-menu-compte li a:active { font-weight:600; line-height:1.2; padding:0.35em 0.5em; - white-space:nowrap; + /* MSIN-4475 — peut passer sur 2 lignes si la colonne restante est étroite. */ + white-space:normal; } .bib-auto-badge--row{ - display:inline-block; + display:inline-flex; + align-items:center; + flex-wrap:wrap; + gap:2px; + max-width:100%; } .bib-container.batch-mode .bib-auto-badge--row{ @@ -3215,22 +3216,22 @@ a.ms1-trad-link.btn-aide-trad{ /* MSIN-4379 / MSIN-4469 — cadenas utilisateur + impression + view/OK/stats. */ /* MSIN-4429 — colonnes Début | Qté | ou | Fin (alignées sur l'en-tête). */ -/* MSIN-4475 — dernière colonne assez large pour le badge « Assignation automatique ». */ +/* MSIN-4475 — grille compacte (~640px min) pour tenir dans le wrapper page sans slider. */ .epr-line{ display:grid; grid-template-columns: - 86px - 86px 42px - minmax(72px, 88px) - minmax(72px, 88px) - 24px - minmax(72px, 88px) - minmax(72px, 88px) - 48px - minmax(164px, 180px) - minmax(150px, 170px); - gap:8px; + minmax(70px, 78px) + 36px + minmax(60px, 72px) + minmax(60px, 72px) + 20px + minmax(60px, 72px) + minmax(48px, 56px) + 36px + minmax(140px, 152px) + minmax(0, 1fr); + gap:6px; align-items:center; width:100%; min-width:0; @@ -3238,17 +3239,17 @@ a.ms1-trad-link.btn-aide-trad{ .bib-container.batch-mode .epr-line{ grid-template-columns: - 86px - 86px 42px - minmax(72px, 88px) - minmax(72px, 88px) - 24px - minmax(72px, 88px) - minmax(72px, 88px) - 48px - minmax(164px, 180px) - 32px; + minmax(70px, 78px) + 36px + minmax(60px, 72px) + minmax(60px, 72px) + 20px + minmax(60px, 72px) + minmax(48px, 56px) + 36px + minmax(140px, 152px) + 28px; } .epr-col-lock{ @@ -3414,7 +3415,7 @@ a.ms1-trad-link.btn-aide-trad{ .epr-col-stats{ display:grid; - grid-template-columns:56px 48px 48px; + grid-template-columns:minmax(44px, 52px) minmax(40px, 48px) minmax(40px, 48px); gap:4px; align-items:center; justify-content:start; @@ -3441,8 +3442,8 @@ a.ms1-trad-link.btn-aide-trad{ } .epr-col-batch{ - /* MSIN-4475 — ne plus couper le badge auto (flex-end + overflow masquait « Assignation »). */ - overflow:visible; + /* MSIN-4475 — badge auto dans la colonne fluide restante (pas de min-width forcé). */ + overflow:hidden; min-width:0; display:flex; align-items:center; diff --git a/js/v2/bib-assignments.js b/js/v2/bib-assignments.js index fa5b7ac..82d6cf9 100644 --- a/js/v2/bib-assignments.js +++ b/js/v2/bib-assignments.js @@ -534,6 +534,14 @@ if (races) { races.classList.toggle('bib-ui-hidden', workspaceId !== 'preparation'); } + + // MSIN-4475 — Modes d'assignation : afficher les choix tout de suite (sans clic tuile). + if (workspaceId === 'operations' && options.keepTool !== true) { + var autoTool = panel.getAttribute('data-bib-auto-tool'); + if (autoTool) { + bibOpenTool(autoTool); + } + } } function bibWorkspaceForTool(toolId) { @@ -630,8 +638,17 @@ } var btn = moduleBib.querySelector('.bib-tool-btn[data-bib-tool="' + toolId + '"]'); - titleEl.textContent = btn - ? (btn.getAttribute('data-bib-tool-label') || '') + if (btn) { + titleEl.textContent = btn.getAttribute('data-bib-tool-label') || ''; + return; + } + + // MSIN-4475 — Titre depuis le panneau (outil ouvert auto, sans tuile). + var autoPanel = moduleBib.querySelector( + '[data-bib-workspace-panel][data-bib-auto-tool="' + toolId + '"]' + ); + titleEl.textContent = autoPanel + ? (autoPanel.getAttribute('data-bib-auto-tool-label') || '') : ''; } @@ -654,11 +671,13 @@ defaultSlot.parentNode.insertBefore(detail, defaultSlot.nextSibling); } - function bibCloseTool() { + function bibCloseTool(options) { + options = options || {}; if (!bibActiveTool) { return; } + var closedTool = bibActiveTool; bibRestoreToolContent(bibActiveTool); bibInvalidateToolSlot(bibActiveTool); bibActiveTool = null; @@ -675,6 +694,13 @@ detail.classList.add('bib-ui-hidden'); } bibPositionToolDetail(null); + + // MSIN-4475 — Fermer les modes (plus de tuile) ramène à la préparation. + if (options.returnToPreparation === true + && closedTool === 'global_batch' + && bibActiveWorkspace === 'operations') { + bibSetWorkspace('preparation', { keepTool: true }); + } } function bibSyncToolNavBadges(toolId) { @@ -2037,7 +2063,7 @@ if (e.target.closest('.bib-tool-detail__close')) { e.preventDefault(); - bibCloseTool(); + bibCloseTool({ returnToPreparation: true }); return; } diff --git a/php/inc_fx_promoteur.php b/php/inc_fx_promoteur.php index 5fff29e..5a15150 100644 --- a/php/inc_fx_promoteur.php +++ b/php/inc_fx_promoteur.php @@ -5165,7 +5165,7 @@ function renderBibProductionPreview(array $tabEpreuves, $strLangue = 'fr') { } /** - * MSIN-4440 / MSIN-4467 / MSIN-4470 — Espaces principaux + outils et panneau de détail unique. + * MSIN-4440 / MSIN-4467 / MSIN-4470 / MSIN-4475 — Espaces principaux + outils et panneau de détail unique. */ function renderBibToolNav($int_eve_id, $tabEpreuves, $strLangue = 'fr') { $int_eve_id = (int)$int_eve_id; @@ -5206,15 +5206,20 @@ function renderBibToolNav($int_eve_id, $tabEpreuves, $strLangue = 'fr') { -
+ +
+ data-bib-auto-tool="global_batch" + data-bib-auto-tool-label="" + >

-
diff --git a/php/inc_settings.php b/php/inc_settings.php index 01f8a7e..a2b288f 100644 --- a/php/inc_settings.php +++ b/php/inc_settings.php @@ -7,7 +7,7 @@ * Constantes * * **************/ -define('_VERSION_CODE', '4.72.865'); // MSIN-4419 — crayon Info hint refund cancel +define('_VERSION_CODE', '4.72.867'); // MSIN-4475 — modes assignation sans clic tuile define('_DATE_CODE', '2026-07-22'); //MSIN-4290 define('QR_SECRET_KEY', 'ms1_qr_2026_cle_secrete_longue_et_fixe');