/**
 * Minified by jsDelivr using Terser v5.39.0.
 * Original file: /npm/ng-smooth-scroll@1.7.3/lib/angular-smooth-scroll.js
 *
 * Do NOT use SRI with dynamically generated files! More information: https://www.jsdelivr.com/using-sri-with-dynamic-files
 */
/*!
 *	 Angular Smooth Scroll (ngSmoothScroll)
 *	 Animates scrolling to elements, by David Oliveros.
 * 
 *   Callback hooks contributed by Ben Armston https://github.com/benarmston
 *	 Easing support contributed by Willem Liu. https://github.com/willemliu
 *	 Easing functions forked from Gaëtan Renaudeau. https://gist.github.com/gre/1650294
 *	 Infinite loop bugs in iOS and Chrome (when zoomed) by Alex Guzman. https://github.com/alexguzman
 *	 Support for scrolling in custom containers by Joseph Matthias Goh. https://github.com/zephinzer
 *	 Influenced by Chris Ferdinandi
 *	 https://github.com/cferdinandi
 *
 *	 Version: 1.7.3
 * 	 License: MIT
 */
!function(){"use strict";var e=angular.module("smoothScroll",[]),t=function(e,t){var n=(t=t||{}).duration||800,c=t.offset||0,r=t.easing||"easeInOutQuart",a=t.callbackBefore||function(){},o=t.callbackAfter||function(){},l=document.getElementById(t.containerId)||null,u=null!=l&&null!=l,f=function(){return u?l.scrollTop:window.pageYOffset?window.pageYOffset:document.documentElement.scrollTop};setTimeout((function(){var t,i,s,d,b=null,k=f(),m=function(e){var t=0;if(e.offsetParent)do{t+=e.offsetTop,e=e.offsetParent}while(e);return Math.max(t-c,0)}(e),I=0,v=m-k;a(e);var g=setInterval((function(){i=k+v*function(e,t){switch(e){case"easeInQuad":return t*t;case"easeOutQuad":return t*(2-t);case"easeInOutQuad":return t<.5?2*t*t:(4-2*t)*t-1;case"easeInCubic":return t*t*t;case"easeOutCubic":return--t*t*t+1;case"easeInOutCubic":return t<.5?4*t*t*t:(t-1)*(2*t-2)*(2*t-2)+1;case"easeInQuart":return t*t*t*t;case"easeOutQuart":return 1- --t*t*t*t;case"easeInOutQuart":return t<.5?8*t*t*t*t:1-8*--t*t*t*t;case"easeInQuint":return t*t*t*t*t;case"easeOutQuint":return 1+--t*t*t*t*t;case"easeInOutQuint":return t<.5?16*t*t*t*t*t:1+16*--t*t*t*t*t;default:return t}}(r,t=(t=(I+=16)/n)>1?1:t),u?l.scrollTop=i:window.scrollTo(0,i),b=f(),d=window.innerHeight+b,s=u?l.scrollHeight:document.body.scrollheight,(i==m||b==m||d>=s)&&(clearInterval(g),o(e))}),16)}),0)};e.factory("smoothScroll",(function(){return t})),e.directive("smoothScroll",["smoothScroll",function(e){return{restrict:"A",scope:{callbackBefore:"&",callbackAfter:"&"},link:function(t,n,c){void 0!==c.scrollIf&&"true"!==c.scrollIf||setTimeout((function(){e(n[0],{duration:c.duration,offset:c.offset,easing:c.easing,callbackBefore:function(e){if(c.callbackBefore){var n=t.callbackBefore({element:e});"function"==typeof n&&n(e)}},callbackAfter:function(e){if(c.callbackAfter){var n=t.callbackAfter({element:e});"function"==typeof n&&n(e)}},containerId:c.containerId})}),0)}}}]),e.directive("scrollTo",["smoothScroll",function(e){return{restrict:"A",scope:{callbackBefore:"&",callbackAfter:"&"},link:function(t,n,c){var r;n.on("click",(function(n){if(n.preventDefault(),r=document.getElementById(c.scrollTo)){return e(r,{duration:c.duration,offset:c.offset,easing:c.easing,callbackBefore:function(e){if(c.callbackBefore){var n=t.callbackBefore({element:e});"function"==typeof n&&n(e)}},callbackAfter:function(e){if(c.callbackAfter){var n=t.callbackAfter({element:e});"function"==typeof n&&n(e)}},containerId:c.containerId}),!1}}))}}}])}();
//# sourceMappingURL=/sm/c952e9257400c50c5161dce50d728c1132639fe278f58753c6ebf0005c2fdf45.map