Select Git revision
-
Tobias Reischmann authoredTobias Reischmann authored
backtotop.min.js 660 B
define ("theme_boost_campus/backtotop",["jquery","core/str","core/notification"],function(a,b,c){"use strict";function d(){var d=b.get_string("backtotop","theme_boost_campus");a.when(d).then(function(b){a("#page-footer").after("<i class=\"fa fa-chevron-up fa-2x d-print-none\"id=\"back-to-top\" aria-label=\""+b+"\"></i>");a(window).scroll(function(){if(220<a(document).scrollTop()){a("#back-to-top").fadeIn(300)}else{a("#back-to-top").fadeOut(100)}});a("#back-to-top").click(function(b){b.preventDefault();a("html, body").animate({scrollTop:0},500)});return!0}).fail(c.exception)}return{init:function init(){d()}}});
//# sourceMappingURL=backtotop.min.js.map