From: Thiago Silva Ferreira Date: Sun, 23 Nov 2014 21:09:45 +0000 (-0200) Subject: Settings duration and easing for magellan X-Git-Tag: v5.5.0~28^2 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=refs%2Fpull%2F6057%2Fhead;p=thirdparty%2Ffoundation%2Ffoundation-sites.git Settings duration and easing for magellan --- diff --git a/js/foundation/foundation.magellan.js b/js/foundation/foundation.magellan.js index f6687583a..4bde19ea7 100644 --- a/js/foundation/foundation.magellan.js +++ b/js/foundation/foundation.magellan.js @@ -12,7 +12,9 @@ destination_threshold: 20, // pixels from the top of destination for it to be considered active throttle_delay: 30, // calculation throttling to increase framerate fixed_top: 0, // top distance in pixels assigend to the fixed element on scroll - offset_by_height: true // whether to offset the destination by the expedition height. Usually you want this to be true, unless your expedition is on the side. + offset_by_height: true, // whether to offset the destination by the expedition height. Usually you want this to be true, unless your expedition is on the side. + duration: 700, // animation duration time + easing: 'swing' // animation easing }, init : function (scope, method, options) { @@ -51,7 +53,7 @@ $('html, body').stop().animate({ 'scrollTop': scroll_top - }, 700, 'swing', function () { + }, settings.duration, settings.easing, function () { if(history.pushState) { history.pushState(null, null, '#'+hash); }