!function(n,t){"use strict";function e(n,t,e){if(!n)throw ln("areq","Argument '{0}' is {1}",t||"?",e||"required");return n}function a(n,t){return n||t?n?t?(J(n)&&(n=n.join(" ")),J(t)&&(t=t.join(" ")),n+" "+t):n:t:""}function r(n){var t={};return n&&(n.to||n.from)&&(t.to=n.to,t.from=n.from),t}function i(n,t,e){var a="";return n=J(n)?n:n&&K(n)&&n.length?n.split(/\s+/):[],B(n,function(n,r){n&&n.length>0&&(a+=r>0?" ":"",a+=e?t+n:n+t)}),a}function o(n,t){var e=n.indexOf(t);t>=0&&n.splice(e,1)}function s(n){if(n instanceof H)switch(n.length){case 0:return n;case 1:if(n[0].nodeType===G)return n;break;default:return H(u(n))}if(n.nodeType===G)return H(n)}function u(n){if(!n[0])return n;for(var t=0;t=0)&&(e=j(e)),0===e&&(e=null),a[t]=e}}),a}function j(n){var t=0,e=n.split(/\s*,\s*/);return B(e,function(n){"s"==n.charAt(n.length-1)&&(n=n.substring(0,n.length-1)),n=parseFloat(n)||0,t=t?Math.max(n,t):n}),t}function x(n){return 0===n||null!=n}function O(n,t){var e=F,a=n+"s";return t?e+=tn:a+=" linear all",[e,a]}function P(){var n=Object.create(null);return{flush:function(){n=Object.create(null)},count:function(t){var e=n[t];return e?e.total:0},get:function(t){var e=n[t];return e&&e.value},put:function(t,e){n[t]?n[t].total++:n[t]={total:1,value:e}}}}function N(n,t,e){B(e,function(e){n[e]=W(n[e])?n[e]:t.style.getPropertyValue(e)})}var F,M,E,I,R=t.noop,q=t.copy,L=t.extend,H=t.element,B=t.forEach,J=t.isArray,K=t.isString,Q=t.isObject,U=t.isUndefined,W=t.isDefined,V=t.isFunction,z=t.isElement,G=1,X="-add",Y="-remove",Z="ng-",_="ng-animate",nn="$$ngAnimateChildren";U(n.ontransitionend)&&W(n.onwebkittransitionend)?("-webkit-",F="WebkitTransition",M="webkitTransitionEnd transitionend"):(F="transition",M="transitionend"),U(n.onanimationend)&&W(n.onwebkitanimationend)?("-webkit-",E="WebkitAnimation",I="webkitAnimationEnd animationend"):(E="animation",I="animationend");var tn="Duration",en="TimingFunction",an="PlayState",rn=E+"Delay",on=E+tn,sn=F+"Delay",un=F+tn,ln=t.$$minErr("ng"),cn=["$$rAF",function(n){function t(n){a=a.concat(n),e()}function e(){if(a.length){for(var t=a.shift(),i=0;i0&&!(l=e.get(s))){var c=i(o,"-stagger");a.addClass(r,c),(l=T(n,r,u)).animationDuration=Math.max(l.animationDuration,0),l.transitionDuration=Math.max(l.transitionDuration,0),a.removeClass(r,c),e.put(s,l)}return l||{}}function j(n){K.push(n),h.waitUntilQuiet(function(){t.flush(),e.flush();for(var n=l(),a=0;a=an&&a>=rn&&(G=!0,h())}function K(){function t(){if(!V){if(y(!1),B(un,function(n){var t=n[0],e=n[1];W.style[t]=e}),L(n,Q),a.addClass(n,bn),En.recalculateTimingStyles){if(Dn=W.className+" "+yn,kn=C(W,Dn),Fn=P(W,Dn,kn),Mn=Fn.maxDelay,tn=Math.max(Mn,0),0===(rn=Fn.maxDuration))return void h();En.hasTransitions=Fn.transitionDuration>0,En.hasAnimations=Fn.animationDuration>0}if(En.applyAnimationDelay&&(Mn="boolean"!=typeof Q.delay&&x(Q.delay)?parseFloat(Q.delay):Mn,tn=Math.max(Mn,0),Fn.animationDelay=Mn,In=S(Mn,!0),un.push(In),W.style[In[0]]=In[1]),an=tn*dn,on=rn*dn,Q.easing){var t,r=Q.easing;En.hasTransitions&&(t=F+en,un.push([t,r]),W.style[t]=r),En.hasAnimations&&(t=E+en,un.push([t,r]),W.style[t]=r)}Fn.transitionDuration&&fn.push(M),Fn.animationDuration&&fn.push(I),sn=Date.now();var i=an+pn*on,o=sn+i,s=n.data(mn)||[],l=!0;if(s.length){var c=s[0];(l=o>c.expectedEndTime)?u.cancel(c.timer):s.push(h)}if(l){var f=u(e,i,!1);s[0]={timer:f,expectedEndTime:o},s.push(h),n.data(mn,s)}fn.length&&n.on(fn.join(" "),H),Q.to&&(Q.cleanupStyles&&N(U,W,Object.keys(Q.to)),p(n,Q))}}function e(){var t=n.data(mn);if(t){for(var e=1;e0&&(Fn.transitionDuration&&0===wn.transitionDuration||Fn.animationDuration&&0===wn.animationDuration)&&Math.max(wn.animationDelay,wn.transitionDelay);i?u(t,Math.floor(i*Pn*dn),!1):t(),nn.resume=function(){r(!0)},nn.pause=function(){r(!1)}}else h()}var Q=e||{};Q.$$prepared||(Q=m(q(Q)));var U={},W=$(n);if(!W||!W.parentNode||!g.enabled())return T();var V,z,G,_,nn,tn,an,rn,on,sn,un=[],ln=n.attr("class"),cn=r(Q),fn=[];if(0===Q.duration||!c.animations&&!c.transitions)return T();var hn=Q.event&&J(Q.event)?Q.event.join(" "):Q.event,$n="",Cn="";hn&&Q.structural?$n=i(hn,Z,!0):hn&&($n=hn),Q.addClass&&(Cn+=i(Q.addClass,X)),Q.removeClass&&(Cn.length&&(Cn+=" "),Cn+=i(Q.removeClass,Y)),Q.applyClassesEarly&&Cn.length&&L(n,Q);var yn=[$n,Cn].join(" ").trim(),Dn=ln+" "+yn,bn=i(yn,"-active"),An=cn.to&&Object.keys(cn.to).length>0;if(!((Q.keyframeStyle||"").length>0)&&!An&&!yn)return T();var kn,wn;if(Q.stagger>0){var Sn=parseFloat(Q.stagger);wn={transitionDelay:Sn,animationDelay:Sn,transitionDuration:0,animationDuration:0}}else kn=C(W,Dn),wn=k(W,yn,kn,gn);Q.$$skipPreparationClasses||a.addClass(n,yn);var Tn;if(Q.transitionStyle){var jn=[F,Q.transitionStyle];A(W,jn),un.push(jn)}if(Q.duration>=0){Tn=W.style[F].length>0;var xn=O(Q.duration,Tn);A(W,xn),un.push(xn)}if(Q.keyframeStyle){var On=[E,Q.keyframeStyle];A(W,On),un.push(On)}var Pn=wn?Q.staggerIndex>=0?Q.staggerIndex:t.count(kn):0,Nn=0===Pn;Nn&&!Q.skipBlocking&&D(W,9999);var Fn=P(W,Dn,kn),Mn=Fn.maxDelay;tn=Math.max(Mn,0),rn=Fn.maxDuration;var En={};if(En.hasTransitions=Fn.transitionDuration>0,En.hasAnimations=Fn.animationDuration>0,En.hasTransitionAll=En.hasTransitions&&"all"==Fn.transitionProperty,En.applyTransitionDuration=An&&(En.hasTransitions&&!En.hasTransitionAll||En.hasAnimations&&!En.hasTransitions),En.applyAnimationDuration=Q.duration&&En.hasAnimations,En.applyTransitionDelay=x(Q.delay)&&(En.applyTransitionDuration||En.hasTransitions),En.applyAnimationDelay=x(Q.delay)&&En.hasAnimations,En.recalculateTimingStyles=Cn.length>0,(En.applyTransitionDuration||En.applyAnimationDuration)&&(rn=Q.duration?parseFloat(Q.duration):rn,En.applyTransitionDuration&&(En.hasTransitions=!0,Fn.transitionDuration=rn,Tn=W.style[F+"Property"].length>0,un.push(O(rn,Tn))),En.applyAnimationDuration&&(En.hasAnimations=!0,Fn.animationDuration=rn,un.push(w(rn)))),0===rn&&!En.recalculateTimingStyles)return T();if(null!=Q.delay){var In;"boolean"!=typeof Q.delay&&(In=parseFloat(Q.delay),tn=Math.max(In,0)),En.applyTransitionDelay&&un.push(S(In)),En.applyAnimationDelay&&un.push(S(In,!0))}return null==Q.duration&&Fn.transitionDuration>0&&(En.recalculateTimingStyles=En.recalculateTimingStyles||Nn),an=tn*dn,on=rn*dn,Q.skipBlocking||(En.blockTransition=Fn.transitionDuration>0,En.blockKeyframeAnimation=Fn.animationDuration>0&&wn.animationDelay>0&&0===wn.animationDuration),Q.from&&(Q.cleanupStyles&&N(U,W,Object.keys(Q.from)),v(n,Q)),En.blockTransition||En.blockKeyframeAnimation?y(rn):Q.skipBlocking||D(W,!1),{$$willAnimate:!0,end:l,start:function(){if(!V)return nn={end:l,cancel:f,resume:null,pause:null},_=new s(nn),j(K),_}}}}]}],Cn=["$$animationProvider",function(n){function t(n){return n.parentNode&&11===n.parentNode.nodeType}n.drivers.push("$$animateCssDriver");var e="ng-animate-shim",a="ng-anchor",r="ng-anchor-out",i="ng-anchor-in";this.$get=["$animateCss","$rootScope","$$AnimateRunner","$rootElement","$sniffer","$$jqLite","$document",function(n,o,s,u,l,c,m){function d(n){return n.replace(/\bng-\S+\b/g,"")}function v(n,t){return K(n)&&(n=n.split(" ")),K(t)&&(t=t.split(" ")),n.filter(function(n){return-1===t.indexOf(n)}).join(" ")}function p(t,o,u){function l(n){var t={},e=$(n).getBoundingClientRect();return B(["width","height","top","left"],function(n){var a=e[n];switch(n){case"top":a+=C.scrollTop;break;case"left":a+=C.scrollLeft}t[n]=Math.floor(a)+"px"}),t}function c(n){return n.attr("class")||""}function f(){var t=d(c(u)),e=v(t,h),a=v(h,t),o=n(p,{to:l(u),addClass:i+" "+e,removeClass:r+" "+a,delay:!0});return o.$$willAnimate?o:null}function m(){p.remove(),o.removeClass(e),u.removeClass(e)}var p=H($(o).cloneNode(!0)),h=d(c(p));o.addClass(e),u.addClass(e),p.addClass(a),D.append(p);var g,y=function(){var t=n(p,{addClass:r,delay:!0,from:l(o)});return t.$$willAnimate?t:null}();if(!y&&!(g=f()))return m();var b=y||g;return{start:function(){function n(){e&&e.end()}var t,e=b.start();return e.done(function(){if(e=null,!g&&(g=f()))return(e=g.start()).done(function(){e=null,m(),t.complete()}),e;m(),t.complete()}),t=new s({end:n,cancel:n})}}}function h(n,t,e,a){var r=g(n),i=g(t),o=[];if(B(a,function(n){var t=n.out,a=n.in,r=p(e,t,a);r&&o.push(r)}),r||i||0!==o.length)return{start:function(){function n(){B(t,function(n){n.end()})}var t=[];r&&t.push(r.start()),i&&t.push(i.start()),B(o,function(n){t.push(n.start())});var e=new s({end:n,cancel:n});return s.all(t,function(n){e.complete(n)}),e}}}function g(t){var e=t.element,a=t.options||{};t.structural&&(a.event=t.event,a.structural=!0,a.applyClassesEarly=!0,"leave"===t.event&&(a.onDone=a.domOperation)),a.preparationClasses&&(a.event=k(a.event,a.preparationClasses));var r=n(e,a);return r.$$willAnimate?r:null}if(!l.animations&&!l.transitions)return R;var C=m[0].body,y=$(u),D=H(t(y)||C.contains(y)?y:C);f(c);return function(n){return n.from&&n.to?h(n.from,n.to,n.classes,n.anchors):g(n)}}]}],yn=["$animateProvider",function(n){this.$get=["$injector","$$AnimateRunner","$$jqLite",function(t,e,a){function r(e){e=J(e)?e:e.split(" ");for(var a=[],r={},i=0;i0,a=(n.removeClass||"").length>0;return t?e&&a:e||a}var c=1,v=2,p=" ",g=this.rules={skip:[],cancel:[],join:[]};g.join.push(function(n,t,e){return!t.structural&&l(t)}),g.skip.push(function(n,t,e){return!t.structural&&!l(t)}),g.skip.push(function(n,t,e){return"leave"==e.event&&t.structural}),g.skip.push(function(n,t,e){return e.structural&&e.state===v&&!t.structural}),g.cancel.push(function(n,t,e){return e.structural&&t.structural}),g.cancel.push(function(n,t,e){return e.state===v&&t.structural}),g.cancel.push(function(n,t,e){if(e.structural)return!1;var a=t.addClass,r=t.removeClass,o=e.addClass,s=e.removeClass;return!(U(a)&&U(r)||U(o)&&U(s))&&(i(a,s)||i(r,o))}),this.$get=["$$rAF","$rootScope","$rootElement","$document","$$HashMap","$$animation","$$AnimateRunner","$templateRequest","$$jqLite","$$forceReflow",function(r,i,p,g,D,b,A,k,w,S){function T(){var n=!1;return function(t){n?t():i.$$postDigest(function(){n=!0,t()})}}function j(n,t){return h(n,t,{})}function x(n,t,e){var a=$(t),r=$(n),i=[],o=_[e];return o&&B(o,function(n){rn.call(n.node,a)?i.push(n.callback):"leave"===e&&rn.call(n.node,r)&&i.push(n.callback)}),i}function O(n,t,e){var a=u(t);return n.filter(function(n){return!(n.node===a&&(!e||n.callback===e))})}function P(n,t){"close"!==n||t[0].parentNode||on.off(t)}function N(n,t,e){function a(t,e,a,i){w(function(){var t=x(p,n,e);t.length?r(function(){B(t,function(t){t(n,a,i)}),P(a,n)}):P(a,n)}),t.progress(e,a,i)}function u(t){y(n,D),an(n,D),d(n,D),D.domOperation(),k.complete(!t)}var f,p,D=q(e);(n=s(n))&&(f=$(n),p=n.parent()),D=m(D);var k=new A,w=T();if(J(D.addClass)&&(D.addClass=D.addClass.join(" ")),D.addClass&&!K(D.addClass)&&(D.addClass=null),J(D.removeClass)&&(D.removeClass=D.removeClass.join(" ")),D.removeClass&&!K(D.removeClass)&&(D.removeClass=null),D.from&&!Q(D.from)&&(D.from=null),D.to&&!Q(D.to)&&(D.to=null),!f)return u(),k;var S=[f.className,D.addClass,D.removeClass].join(" ");if(!en(S))return u(),k;var O=["enter","move","leave"].indexOf(t)>=0,N=g[0].hidden,E=!Y||N||X.get(f),L=!E&&V.get(f)||{},H=!!L.state;if(E||H&&L.state==c||(E=!I(n,p,t)),E)return N&&a(k,t,"start"),u(),N&&a(k,t,"close"),k;O&&F(n);var U={structural:O,element:n,event:t,addClass:D.addClass,removeClass:D.removeClass,close:u,options:D,runner:k};if(H){if(o("skip",n,U,L))return L.state===v?(u(),k):(h(n,L,U),L.runner);if(o("cancel",n,U,L))if(L.state===v)L.runner.end();else{if(!L.structural)return h(n,L,U),L.runner;L.close()}else if(o("join",n,U,L)){if(L.state!==v)return C(n,O?t:null,D),t=U.event=L.event,D=h(n,L,U),L.runner;j(n,U)}}else j(n,U);var W=U.structural;if(W||(W="animate"===U.event&&Object.keys(U.options.to||{}).length>0||l(U)),!W)return u(),M(n),k;var z=(L.counter||0)+1;return U.counter=z,R(n,c,U),i.$$postDigest(function(){var e=V.get(f),r=!e;e=e||{};var i=(n.parent()||[]).length>0&&("animate"===e.event||e.structural||l(e));if(r||e.counter!==z||!i)return r&&(an(n,D),d(n,D)),(r||O&&e.event!==t)&&(D.domOperation(),k.end()),void(i||M(n));t=!e.structural&&l(e,!0)?"setClass":e.event,R(n,v);var o=b(n,t,e.options);k.setHost(o),a(k,t,"start",{}),o.done(function(e){u(!e);var r=V.get(f);r&&r.counter===z&&M($(n)),a(k,t,"close",{})})}),k}function F(n){var t=$(n).querySelectorAll("["+bn+"]");B(t,function(n){var t=parseInt(n.getAttribute(bn)),e=V.get(n);if(e)switch(t){case v:e.runner.end();case c:V.remove(n)}})}function M(n){var t=$(n);t.removeAttribute(bn),V.remove(t)}function E(n,t){return $(n)===$(t)}function I(n,t,e){var a,r=H(g[0].body),i=E(n,r)||"HTML"===n[0].nodeName,o=E(n,p),s=!1,u=X.get($(n)),l=H.data(n[0],An);for(l&&(t=l),t=$(t);t&&(o||(o=E(t,p)),t.nodeType===G);){var c=V.get(t)||{};if(!s){var f=X.get(t);if(!0===f&&!1!==u){u=!0;break}!1===f&&(u=!1),s=c.structural}if(U(a)||!0===a){var m=H.data(t,nn);W(m)&&(a=m)}if(s&&!1===a)break;if(i||(i=E(t,r)),i&&o)break;t=o||!(l=H.data(t,An))?t.parentNode:$(l)}return(!s||a)&&!0!==u&&o&&i}function R(n,t,e){(e=e||{}).state=t;var a=$(n);a.setAttribute(bn,t);var r=V.get(a),i=r?L(r,e):e;V.put(a,i)}var V=new D,X=new D,Y=null,Z=i.$watch(function(){return 0===k.totalPendingRequests},function(n){n&&(Z(),i.$$postDigest(function(){i.$$postDigest(function(){null===Y&&(Y=!0)})}))}),_={},tn=a.classNameFilter(),en=tn?function(n){return tn.test(n)}:function(){return!0},an=f(w),rn=n.Node.prototype.contains||function(n){return this===n||!!(16&this.compareDocumentPosition(n))},on={on:function(n,t,e){var a=u(t);_[n]=_[n]||[],_[n].push({node:a,callback:e}),H(t).on("$destroy",function(){V.get(a)||on.off(n,t,e)})},off:function(n,e,a){if(1!==arguments.length||t.isString(arguments[0])){var r=_[n];r&&(_[n]=1===arguments.length?null:O(r,e,a))}else{e=arguments[0];for(var i in _)_[i]=O(_[i],e)}},pin:function(n,t){e(z(n),"element","not an element"),e(z(t),"parentElement","not an element"),n.data(An,t)},push:function(n,t,e,a){return e=e||{},e.domOperation=a,N(n,t,e)},enabled:function(n,t){var e=arguments.length;if(0===e)t=!!Y;else if(z(n)){var a=$(n),r=X.get(a);1===e?t=!r:X.put(a,!t)}else t=Y=!!n;return t}};return on}]}],wn=["$animateProvider",function(n){function t(n,t){n.data(s,t)}function e(n){n.removeData(s)}function r(n){return n.data(s)}var i="ng-animate-ref",o=this.drivers=[],s="$$animationRunner";this.$get=["$$jqLite","$rootScope","$injector","$$AnimateRunner","$$HashMap","$$rAFScheduler",function(n,s,u,l,c,v){function p(n){function t(n){if(n.processed)return n;n.processed=!0;var e=n.domNode,i=e.parentNode;r.put(e,n);for(var o;i;){if(o=r.get(i)){o.processed||(o=t(o));break}i=i.parentNode}return(o||a).children.push(n),n}var e,a={children:[]},r=new c;for(e=0;e=0,u=n.structural?y(r):[];if(u.length){var l=s?"to":"from";B(u,function(n){var t=n.getAttribute(i);e[t]=e[t]||{},e[t][l]={animationID:a,element:H(n)}})}else t.push(n)});var a={},r={};return B(e,function(e,i){var o=e.from,s=e.to;if(o&&s){var u=n[o.animationID],l=n[s.animationID],c=o.animationID.toString();if(!r[c]){var f=r[c]={structural:!0,beforeStart:function(){u.beforeStart(),l.beforeStart()},close:function(){u.close(),l.close()},classes:b(u.classes,l.classes),from:u,to:l,anchors:[]};f.classes.length?t.push(f):(t.push(u),t.push(l))}r[c].anchors.push({out:o.element,in:s.element})}else{var m=o?o.animationID:s.animationID,d=m.toString();a[d]||(a[d]=!0,t.push(n[m]))}}),t}function b(n,t){n=n.split(" "),t=t.split(" ");for(var e=[],a=0;a=0;t--){var e=o[t];if(u.has(e)){var a=u.get(e)(n);if(a)return a}}}function k(n,t){function e(n){var e=r(n);e&&e.setHost(t)}n.from&&n.to?(e(n.from.element),e(n.to.element)):e(n.element)}function w(){var n=r(c);!n||"leave"===f&&C.$$domOperationFired||n.end()}function S(t){c.off("$destroy",w),e(c),g(c,C),d(c,C),C.domOperation(),O&&n.removeClass(c,O),c.removeClass(_),j.complete(!t)}C=m(C);var T=["enter","move","leave"].indexOf(f)>=0,j=new l({end:function(){S()},cancel:function(){S(!0)}});if(!o.length)return S(),j;t(c,j);var x=a(c.attr("class"),a(C.addClass,C.removeClass)),O=C.tempClasses;O&&(x+=" "+O,C.tempClasses=null);var P;return T&&(P="ng-"+f+"-prepare",n.addClass(c,P)),h.push({element:c,classes:x,event:f,structural:T,options:C,beforeStart:function(){c.addClass(_),O&&n.addClass(c,O),P&&(n.removeClass(c,P),P=null)},close:S}),c.on("$destroy",w),h.length>1?j:(s.$$postDigest(function(){var n=[];B(h,function(t){r(t.element)?n.push(t):t.close()}),h.length=0;var t=D(n),e=[];B(t,function(n){e.push({domNode:$(n.from?n.from.element:n.element),fn:function(){n.beforeStart();var t,e=n.close;if(r(n.anchors?n.from.element||n.to.element:n.element)){var a=A(n);a&&(t=a.start)}if(t){var i=t();i.done(function(n){e(!n)}),k(n,i)}else e()}})}),v(p(e))}),j)}}]}],Sn=["$animate","$rootScope",function(n,t){return{restrict:"A",transclude:"element",terminal:!0,priority:600,link:function(t,e,a,r,i){var o,s;t.$watchCollection(a.ngAnimateSwap||a.for,function(a){o&&n.leave(o),s&&(s.$destroy(),s=null),(a||0===a)&&(s=t.$new(),i(s,function(t){o=t,n.enter(t,null,e)}))})}}}];t.module("ngAnimate",[]).directive("ngAnimateSwap",Sn).directive("ngAnimateChildren",fn).factory("$$rAFScheduler",cn).provider("$$animateQueue",kn).provider("$$animation",wn).provider("$animateCss",$n).provider("$$animateCssDriver",Cn).provider("$$animateJs",yn).provider("$$animateJsDriver",Dn)}(window,window.angular);