diff --git a/static/document/document-editor.css b/static/document/document-editor.css index d1275d0e..352a2587 100644 --- a/static/document/document-editor.css +++ b/static/document/document-editor.css @@ -34,7 +34,8 @@ body.objectEditBody > main.content { forgeDocApplyTheme (static/document/js/document-editor.js), qui pose le même data-theme sur les deux éléments. */ .docEditor3, -#docScenarioTreeModal { +#docScenarioTreeModal, +#docTemplateModal { --doc-bg: var(--forge-bg); --doc-bg-2: var(--forge-bg-secondary); --doc-card: var(--forge-card); @@ -72,7 +73,8 @@ body.objectEditBody > main.content { } .docEditor3[data-theme="light"], -#docScenarioTreeModal[data-theme="light"] { +#docScenarioTreeModal[data-theme="light"], +#docTemplateModal[data-theme="light"] { --doc-bg: #f6f5f2; --doc-bg-2: #fff; --doc-card: #fff; @@ -89,7 +91,8 @@ body.objectEditBody > main.content { } .docEditor3 *, -#docScenarioTreeModal * { +#docScenarioTreeModal *, +#docTemplateModal * { box-sizing: border-box; } @@ -2286,6 +2289,15 @@ img.docImage { la place à l'aperçu. ---- */ .docModalDialog--wide { width: min(980px, 95vw); + + /* height explicite, pas seulement max-height (comme la base + .docModalDialog) : sans elle, le dialogue flex se limite à la + hauteur naturelle de son contenu et l'iframe d'aperçu (flex:1 dans + .docTemplatePreviewPane) n'a plus aucune hauteur de référence pour + se déployer — elle retombe à sa hauteur intrinsèque minuscule (bug + réel constaté le 24/09/2026, capture à l'appui : "container trop + petit"). */ + height: min(85vh, 760px); max-height: min(85vh, 760px); } diff --git a/static/document/js/document-editor.js b/static/document/js/document-editor.js index 439fbd60..ea4f9b90 100644 --- a/static/document/js/document-editor.js +++ b/static/document/js/document-editor.js @@ -3045,6 +3045,8 @@ function forgeDocApplyTheme(theme) { // posé ici explicitement pour que la modale suive le même thème. const scenarioModal = document.getElementById('docScenarioTreeModal'); if (scenarioModal) scenarioModal.dataset.theme = theme; + const templateModal = document.getElementById('docTemplateModal'); + if (templateModal) templateModal.dataset.theme = theme; const toggle = document.getElementById('docThemeToggle'); toggle.innerHTML = theme === 'light' ? ''