From aaf7d4629be0671d2da76710d0b4fc20437fd878 Mon Sep 17 00:00:00 2001 From: Jan Michel Date: Sun, 4 Aug 2013 16:38:31 +0200 Subject: [PATCH] alternate stylesheet for jtageditor --- layout/jtageditor_blue.css | 3 ++- tools/jtageditor.pl | 5 +++++ 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/layout/jtageditor_blue.css b/layout/jtageditor_blue.css index 08f28c0..371ebb4 100644 --- a/layout/jtageditor_blue.css +++ b/layout/jtageditor_blue.css @@ -112,7 +112,8 @@ table.fields { border-collapse:collapse; border:hidden; cursor:default; - + max-height:none; + transition: max-height .4s; } table.fields td { diff --git a/tools/jtageditor.pl b/tools/jtageditor.pl index 43d7ffe..21827b2 100755 --- a/tools/jtageditor.pl +++ b/tools/jtageditor.pl @@ -740,10 +740,12 @@ function toggleVis(elementId,t) { if(document.getElementById(elementId)){ if( document.getElementById(elementId).style.visibility == "visible") { document.getElementById(elementId).style.visibility = "collapse"; + document.getElementById(elementId).style.maxHeight = "0px"; visHash[elementId]=false; t.innerHTML = " + "; } else { document.getElementById(elementId).style.visibility = "visible" ; + document.getElementById(elementId).style.maxHeight = "none"; visHash[elementId]=true; t.innerHTML = " − "; } @@ -752,18 +754,21 @@ if( document.getElementById(elementId).style.visibility == "visible") { function showElement(elementId) { if(document.getElementById(elementId)){ document.getElementById(elementId).style.visibility = "visible" ; + document.getElementById(elementId).style.maxHeight = "none"; visHash[elementId]=true; } } function hideElement(elementId) { if(document.getElementById(elementId)){ document.getElementById(elementId).style.visibility = "hidden" ; + document.getElementById(elementId).style.maxHeight = "0px"; visHash[elementId]=false; } } function collapseElement(elementId) { if(document.getElementById(elementId)){ document.getElementById(elementId).style.visibility = "collapse" ; + document.getElementById(elementId).style.maxHeight = "0px"; visHash[elementId]=false; } } -- 2.43.0