MediaWiki:Minerva.js: Difference between revisions

no edit summary
No edit summary
No edit summary
Line 5: Line 5:
function TLPExpand(x) {
function TLPExpand(x) {
   var y = document.getElementById(x);
   var y = document.getElementById(x);
  var z = document.getElementById("tlp-button-text-"+x);
   if (y.style.display === "block") {
   if (y.style.display === "block") {
     y.style.display = "none";
     y.style.display = "none";
     document.getElementById("tlp-button-text").innerHTML = "Expand";
     z.innerHTML = "Expand";
   } else {
   } else {
     y.style.display = "block";
     y.style.display = "block";
     document.getElementById("tlp-button-text").innerHTML = "Collapse";
     z.innerHTML = "Collapse";
   }
   }
}
}