Template:Team:Waterloo/JS/baseWiki

From 2014.igem.org

(Difference between revisions)
(Undo revision 263921 by L42wong (talk))
 
Line 6: Line 6:
function alignHeadings(){
function alignHeadings(){
   var remainingWidth = $("div#topbar").width();
   var remainingWidth = $("div#topbar").width();
-
  if (remainingWidth <= "1000"){
 
-
    $("ul#headings >li").css("display", "none");
 
-
    $("ul#shortheadings >li").css("display", "block");
 
-
  }
 
-
  else {
 
     var allheadings = $("ul#headings >li");
     var allheadings = $("ul#headings >li");
     allheadings.css("display", "block");
     allheadings.css("display", "block");
Line 16: Line 11:
     allheadings.width(remainingWidth / (allheadings.length + 0.5))
     allheadings.width(remainingWidth / (allheadings.length + 0.5))
       .css({"text-align":"center","line-height":"150%"});
       .css({"text-align":"center","line-height":"150%"});
-
  }
 
}
}
-
/*function toggleNavPanel(x){
+
function toggleNavPanel(x){
   var panel = document.getElementById(x),
   var panel = document.getElementById(x),
   navarrow = document.getElementsByClassName("navarrow"),
   navarrow = document.getElementsByClassName("navarrow"),
Line 33: Line 27:
     navarrow[1].innerHTML = "&#9652;";
     navarrow[1].innerHTML = "&#9652;";
   }
   }
-
}*/
+
}
function onHover(id, image){
function onHover(id, image){

Latest revision as of 05:06, 16 October 2014