diff --git a/ecrire/public/debusquer.php b/ecrire/public/debusquer.php index c2f38a38f77d7680505d787c8912f629045f3662..2a4b5616e2ca9c4d28afcf7be8be9dcb68ac1934 100644 --- a/ecrire/public/debusquer.php +++ b/ecrire/public/debusquer.php @@ -239,7 +239,7 @@ function debusquer_contexte($env) { . "</td></tr>\n"; } - return "<div class='spip-env'><fieldset><legend onclick=\"this.nextElementSibling.classList.toggle('expanded');\">#ENV</legend>\n<div><table>$res</table></div></fieldset></div>\n"; + return "<div class='spip-env'><fieldset><legend onclick=\"this.parentElement.classList.toggle('expanded');\">#ENV</legend>\n<div><table>$res</table></div></fieldset></div>\n"; } // Affichage du tableau des erreurs ou des temps de calcul diff --git a/prive/spip_admin.css b/prive/spip_admin.css index c47f9a660eb28eef92c86389bf7bc5568ab6ab10..5520db2142c646140e5f70bbf643752785ee077a 100644 --- a/prive/spip_admin.css +++ b/prive/spip_admin.css @@ -210,6 +210,22 @@ html #spip-boucles fieldset .spip-env fieldset legend { margin-top: -1.5rem; cursor: pointer; } +html #spip-boucles fieldset .spip-env fieldset legend:after { + content:' +'; + display: inline-block; + width: 1.5em; + height: 1.5em; + line-height: 1.5em; + text-align: center; + vertical-align: bottom; + margin-left: 0.5em; + background: #eee; + border-radius: 50%; +} +html #spip-boucles fieldset .spip-env fieldset.expanded legend:after { + content:' -'; +} + html #spip-boucles fieldset .spip-env fieldset table { font-family: inherit; display: block; @@ -221,15 +237,16 @@ html #spip-boucles fieldset .spip-env fieldset table tbody, html #spip-boucles f font-size: inherit; display: flex; } -html #spip-boucles fieldset .spip-env fieldset .expanded table tr { +html #spip-boucles fieldset .spip-env fieldset.expanded table tr { flex-basis: 100% !important; max-width: 100% !important; max-height: none !important; + overflow: auto !important; } html #spip-boucles fieldset .spip-env fieldset table tr { flex-basis: 100%; max-width: 100%; - overflow: auto; + overflow: hidden; max-height: 1.5rem; } @media (min-width: 640px) {