summaryrefslogtreecommitdiffstats
path: root/gui/static/script.js
diff options
context:
space:
mode:
authorMatthias P. Braendli <matthias.braendli@mpb.li>2015-03-15 11:04:25 +0100
committerMatthias P. Braendli <matthias.braendli@mpb.li>2015-03-15 11:04:25 +0100
commitabcb1a86381195ffb382297233158da2fa4aacc7 (patch)
tree5f429d5ca7fd1aace4335684d1b24ebb1f4a8590 /gui/static/script.js
parenta36150d2305e93de9d0f58cb48273ed9909cab05 (diff)
downloaddabmux-abcb1a86381195ffb382297233158da2fa4aacc7.tar.gz
dabmux-abcb1a86381195ffb382297233158da2fa4aacc7.tar.bz2
dabmux-abcb1a86381195ffb382297233158da2fa4aacc7.zip
Add tabbed interface to gui
Diffstat (limited to 'gui/static/script.js')
-rw-r--r--gui/static/script.js16
1 files changed, 16 insertions, 0 deletions
diff --git a/gui/static/script.js b/gui/static/script.js
new file mode 100644
index 0000000..231aa03
--- /dev/null
+++ b/gui/static/script.js
@@ -0,0 +1,16 @@
+$(document).ready(function() {
+ // Only show first tab
+ $('#info div:not(:first)').hide();
+
+ // Handle clicks on tabs to change visiblity of panes
+ $('#info-nav li').click(function(event) {
+ event.preventDefault();
+ $('#info div').hide();
+ $('#info-nav .current').removeClass("current");
+ $(this).addClass('current');
+ var clicked = $(this).find('a:first').attr('href');
+ $('#info ' + clicked).fadeIn('fast');
+ }).eq(0).addClass('current');
+
+});
+