summaryrefslogtreecommitdiff
path: root/js/core/smooth-scroll.min.js
diff options
context:
space:
mode:
Diffstat (limited to 'js/core/smooth-scroll.min.js')
-rwxr-xr-xjs/core/smooth-scroll.min.js2
1 files changed, 2 insertions, 0 deletions
diff --git a/js/core/smooth-scroll.min.js b/js/core/smooth-scroll.min.js
new file mode 100755
index 0000000..5968d4e
--- /dev/null
+++ b/js/core/smooth-scroll.min.js
@@ -0,0 +1,2 @@
1/*! UIkit 2.26.4 | http://www.getuikit.com | (c) 2014 YOOtheme | MIT License */
2!function(t){"use strict";function o(o,i){i=t.$.extend({duration:1e3,transition:"easeOutExpo",offset:0,complete:function(){}},i);var n=o.offset().top-i.offset,s=t.$doc.height(),e=window.innerHeight;n+e>s&&(n=s-e),t.$("html,body").stop().animate({scrollTop:n},i.duration,i.transition).promise().done(i.complete)}t.component("smoothScroll",{boot:function(){t.$html.on("click.smooth-scroll.uikit","[data-uk-smooth-scroll]",function(){var o=t.$(this);if(!o.data("smoothScroll")){{t.smoothScroll(o,t.Utils.options(o.attr("data-uk-smooth-scroll")))}o.trigger("click")}return!1})},init:function(){var i=this;this.on("click",function(n){n.preventDefault(),o(t.$(this.hash).length?t.$(this.hash):t.$("body"),i.options)})}}),t.Utils.scrollToElement=o,t.$.easing.easeOutExpo||(t.$.easing.easeOutExpo=function(t,o,i,n,s){return o==s?i+n:n*(-Math.pow(2,-10*o/s)+1)+i})}(UIkit); \ No newline at end of file