]> git.ipfire.org Git - people/shoehn/ipfire.org.git/blobdiff - static/js/site.js
edit font weight in buttons
[people/shoehn/ipfire.org.git] / static / js / site.js
index 6c47de90333718552477bf0a3951e8150da56342..1b9b8f7835c89888392cfdbbd061d126bf11f7c0 100644 (file)
@@ -1,33 +1,21 @@
+$("#scrollto").click(function() {
+    $('html, body').animate({
+        scrollTop: $("#features").offset().top -72
+    }, 1500, 'easeInOutExpo');
+});
+
 $(document).ready(function () {
     $(window).scroll(function () {
         if ($(document).scrollTop() > 100) {
             $(".fixed-top").addClass("scrolled");
+            $(".menu-text").addClass("hidden");
         } else {
             $(".fixed-top").removeClass("scrolled");
+            $(".menu-text").removeClass("hidden");
         }
     });
 });
 
-//jQuery to collapse the navbar on scroll
-$(window).scroll(function() {
-       if ($(".navbar").offset().top > 50) {
-               $(".navbar-fixed-top").addClass("top-nav-collapse");
-       } else {
-               $(".navbar-fixed-top").removeClass("top-nav-collapse");
-       }
-});
-
-//jQuery for page scrolling feature - requires jQuery Easing plugin
-$(function() {
-       $('.page-scroll a, a.page-scroll').bind('click', function(event) {
-               var $anchor = $(this);
-               $('html, body').stop().animate({
-                       scrollTop: $($anchor.attr('href')).offset().top
-               }, 1500, 'easeInOutExpo');
-               event.preventDefault();
-       });
-});
-
 $.query = function(name){
        var results = new RegExp('[\\?&]' + name + '=([^&#]*)').exec(window.location.href);
        return results[1] || 0;
@@ -40,15 +28,6 @@ $("a.download-splash").click(function(event) {
        window.location = "http://downloads.ipfire.org/download-splash?file="+linkLocation;
 });
 
-var $window = $(window);
-
-$(".sidenav").affix({
-       offset: {
-               top: function () { return $window.width() <= 980 ? 290 : 240 }
-               , bottom: 270
-       }
-});
-
 if (/.*download-splash.*/i.test(window.location.href)) {
        $("p.download-path").ready(function(){
                var valid = false;
@@ -98,4 +77,4 @@ jQuery.postJSON = function(url, args, callback) {
                        callback(eval("(" + response + ")"));
                }
        });
-};
+};
\ No newline at end of file