aboutsummaryrefslogtreecommitdiff
path: root/_layouts/default.html
diff options
context:
space:
mode:
authorHeather Miller <heather.miller@epfl.ch>2017-01-03 13:59:43 +0100
committerHeather Miller <heather.miller@epfl.ch>2017-01-03 13:59:43 +0100
commit29ef063fdcfffd887313c7bc0e1e51d515d40e64 (patch)
tree89515fb12f2127a99e224e34c1c0b3e13a012f3b /_layouts/default.html
parent7aa3508c5893848b64b21676356a0fd0105a1f23 (diff)
Facelift, step 1
Diffstat (limited to '_layouts/default.html')
-rw-r--r--_layouts/default.html33
1 files changed, 33 insertions, 0 deletions
diff --git a/_layouts/default.html b/_layouts/default.html
index d8a0846..c4152a6 100644
--- a/_layouts/default.html
+++ b/_layouts/default.html
@@ -32,4 +32,37 @@
</div>
</body>
+<script>
+
+ $( ".toc-hide" ).click(function() {
+ // $( this ).toggleClass( "gray-bg" );
+ $(".toc-contents").toggleClass( "lighter" );
+
+ if ($(this).text() == 'Hide') {
+ $(this).text("Show");
+ } else {
+ $(this).text("Hide");
+ }
+ // toggle visibility of contents, and expand button
+ $(".nav").toggle();
+ $(".toc-expand").toggle();
+ });
+
+ $( ".toc-expand" ).click(function() {
+ // $( this ).toggleClass( "gray-bg" );
+
+ if ($(this).text() == 'Expand') {
+ $(this).text("Compact");
+ $(".nav").css('display', 'block');
+ } else {
+ $(this).text("Expand");
+ $(".nav .nav").css('display', 'none');
+ }
+ });
+
+ // get current year and put it in span
+ var currYear = new Date().getFullYear()
+ $(".current-year").text(currYear);
+</script>
+
</html>