/* https://raw.github.com/jashkenas/underscore/master/LICENSE @type {function} @return {number} https://raw.github.com/jashkenas/underscore/master/LICENSE @param {function} func @param {number} wait @param {Object=} options @returns {Function} */ var _get=function get(g,h,k){null===g&&(g=Function.prototype);var f=Object.getOwnPropertyDescriptor(g,h);if(void 0===f)return g=Object.getPrototypeOf(g),null===g?void 0:get(g,h,k);if("value"in f)return f.value;h=f.get;return void 0===h?void 0:h.call(k)},_createClass=function(){function d(d,h){for(var k=0;k/,X=/^\w+$/,P,D=f.fn=f.prototype=k.prototype={cash:!0,length:0, push:Q,splice:J.splice,map:J.map,init:k};Object.defineProperty(D,"constructor",{value:f});f.parseHTML=g;f.noop=N;f.isFunction=L;f.isString=A;f.extend=D.extend=function(a){a=a||{};var c=G.call(arguments),b=c.length,e=1;1===c.length&&(a=this,e=0);for(;ea?this[a+this.length]:this[a]},index:function(a){var c=a?f(a)[0]:this[0];a=a?this:f(c).parent().children();return G.call(a).indexOf(c)},last:function(){return this.eq(-1)}});var V=function(){var a=/(?:^\w|[A-Z]|\b\w)/g,c=/[\s-_]+/g; return function(b){return b.replace(a,function(a,c){return a[0===c?"toLowerCase":"toUpperCase"]()}).replace(c,"")}}(),Y=function(){var c={},b=document.createElement("div").style;return function(e){e=V(e);if(c[e])return c[e];var d=e.charAt(0).toUpperCase()+e.slice(1),d=(e+" "+["webkit","moz","ms","o"].join(d+" ")+d).split(" ");a(d,function(a){if(a in b)return c[a]=e=c[e]=a,!1});return c[e]}}();f.prefixedProp=Y;f.camelCase=V;D.extend({css:function(a,c){if(A(a))return a=Y(a),1this.length?f():this.is(a)?this.filter(a):this.parent().closest(a)},is:function(a){if(!a)return!1;var c=!1,e=b(a);this.each(function(b){c=e(b,a);return!c});return c},find:function(a){if(!a||a.nodeType)return f(a&&this.has(a).length?a:null);var c=[];this.each(function(b){Q.apply(c,d(a,b))});return e(c)},has:function(a){var c=A(a)?function(c){return 0!==d(a,c).length}:function(c){return c.contains(a)};return this.filter(c)},next:function(){return f(this[0].nextElementSibling)}, not:function(a){if(!a)return this;var c=b(a);return this.filter(function(b){return!c(b,a)})},parent:function(){var a=[];this.each(function(c){c&&c.parentNode&&a.push(c.parentNode)});return e(a)},parents:function(a){var b,d=[];this.each(function(e){for(b=e;b&&b.parentNode&&b!==y.body.parentNode;)b=b.parentNode,(!a||a&&c(b,a))&&d.push(b)});return e(d)},prev:function(){return f(this[0].previousElementSibling)},siblings:function(a){a=this.parent().children(a);var c=this[0];return a.filter(function(a){return a!== c})}});return f});var Component=function(){function d(g,h,k){_classCallCheck(this,d);h instanceof Element||console.error(Error(h+" is not an HTML Element"));(g=g.getInstance(h))&&g.destroy();this.el=h;this.$el=cash(h)}_createClass(d,null,[{key:"init",value:function(d,h,k){var f=null;if(h instanceof Element)f=new d(h,k);else if(h&&(h.jquery||h.cash||h instanceof NodeList))for(var f=[],a=0;af.right-h||c+g.width>window.innerWidth-h)k.right=!0;if(da-h||d+g.height>window.innerHeight-h)k.bottom=!0;return k}; M.checkPossibleAlignments=function(d,g,h,k){var f={top:!0,right:!0,bottom:!0,left:!0,spaceOnTop:null,spaceOnRight:null,spaceOnBottom:null,spaceOnLeft:null},a="visible"===getComputedStyle(g).overflow,c=g.getBoundingClientRect(),b=Math.min(c.height,window.innerHeight),c=Math.min(c.width,window.innerWidth);d=d.getBoundingClientRect();var e=g.scrollTop;g=h.left-g.scrollLeft;var q=h.top-e,e=h.top+d.height-e;f.spaceOnRight=a?window.innerWidth-(d.left+h.width):c-(g+h.width);0>f.spaceOnRight&&(f.left=!1); f.spaceOnLeft=a?d.right-h.width:g-h.width+d.width;0>f.spaceOnLeft&&(f.right=!1);f.spaceOnBottom=a?window.innerHeight-(d.top+h.height+k):b-(q+h.height+k);0>f.spaceOnBottom&&(f.top=!1);f.spaceOnTop=a?d.bottom-(h.height+k):e-(h.height-k);0>f.spaceOnTop&&(f.bottom=!1);return f};M.getOverflowParent=function(d){return null==d?null:d===document.body||"visible"!==getComputedStyle(d).overflow?d:M.getOverflowParent(d.parentElement)}; M.getIdFromTrigger=function(d){var g=d.getAttribute("data-target");g||(g=(g=d.getAttribute("href"))?g.slice(1):"");return g};M.getDocumentScrollTop=function(){return window.pageYOffset||document.documentElement.scrollTop||document.body.scrollTop||0};M.getDocumentScrollLeft=function(){return window.pageXOffset||document.documentElement.scrollLeft||document.body.scrollLeft||0};var getTime=Date.now||function(){return(new Date).getTime()}; M.throttle=function(d,g,h){var k=void 0,f=void 0,a=void 0,c=null,b=0;h||(h={});var e=function(){b=!1===h.leading?0:getTime();c=null;a=d.apply(k,f);k=f=null};return function(){var q=getTime();b||!1!==h.leading||(b=q);var u=g-(q-b);k=this;f=arguments;0>=u?(clearTimeout(c),c=null,b=q,a=d.apply(k,f),k=f=null):c||!1===h.trailing||(c=setTimeout(e,u));return a}};var $jscomp={scope:{}}; $jscomp.defineProperty="function"==typeof Object.defineProperties?Object.defineProperty:function(d,g,h){if(h.get||h.set)throw new TypeError("ES3 does not support getters and setters.");d!=Array.prototype&&d!=Object.prototype&&(d[g]=h.value)};$jscomp.getGlobal=function(d){return"undefined"!=typeof window&&window===d?d:"undefined"!=typeof global&&null!=global?global:d};$jscomp.global=$jscomp.getGlobal(this);$jscomp.SYMBOL_PREFIX="jscomp_symbol_"; $jscomp.initSymbol=function(){$jscomp.initSymbol=function(){};$jscomp.global.Symbol||($jscomp.global.Symbol=$jscomp.Symbol)};$jscomp.symbolCounter_=0;$jscomp.Symbol=function(d){return $jscomp.SYMBOL_PREFIX+(d||"")+$jscomp.symbolCounter_++}; $jscomp.initSymbolIterator=function(){$jscomp.initSymbol();var d=$jscomp.global.Symbol.iterator;d||(d=$jscomp.global.Symbol.iterator=$jscomp.global.Symbol("iterator"));"function"!=typeof Array.prototype[d]&&$jscomp.defineProperty(Array.prototype,d,{configurable:!0,writable:!0,value:function(){return $jscomp.arrayIterator(this)}});$jscomp.initSymbolIterator=function(){}};$jscomp.arrayIterator=function(d){var g=0;return $jscomp.iteratorPrototype(function(){return ge&&(e+=1);1e?b:e<2/3?a+(b-a)*(2/3-e)*6:a}var b=/hsl\((\d+),\s*([\d.]+)%,\s*([\d.]+)%\)/g.exec(a)||/hsla\((\d+),\s*([\d.]+)%,\s*([\d.]+)%,\s*([\d.]+)\)/g.exec(a);a=parseInt(b[1])/360;var e=parseInt(b[2])/100,d=parseInt(b[3])/100,b=b[4]||1;if(0==e)d=e=a=d;else{var f=.5>d?d*(1+e):d+e-d*e,g=2*d-f,d=c(g,f,a+1/3),e=c(g,f,a);a=c(g,f,a-1/3)}return"rgba("+255*d+","+255*e+","+255*a+","+b+")"}function u(a){if(a=/([\+\-]?[0-9#\.]+)(%|px|pt|em|rem|in|cm|mm|ex|ch|pc|vw|vh|vmin|vmax|deg|rad|turn)?$/.exec(a))return a[2]} function v(a){if(-1=m.currentTime)for(var y=0;y=n||!g)m.began||(m.began=!0,d("begin")),d("run");if(t>K&&t=g&&l!==g||!g)e(g),p||f();d("update");a>=g&&(m.remaining?(k=h,"alternate"===m.direction&&(m.reversed=!m.reversed)):(m.pause(),m.completed||(m.completed=!0,d("complete"),"Promise"in window&&(v(),r=c()))),u=0)}a=void 0===a?{}:a;var h,k,u=0,v=null,r=c(),m=S(a);m.reset=function(){var a=m.direction,c=m.loop;m.currentTime=0;m.progress=0;m.paused=!0;m.began=!1;m.completed=!1;m.reversed="reverse"===a;m.remaining="alternate"===a&&1===c?2:c;e(0);for(a=m.children.length;a--;)m.children[a].reset()};m.tick= function(a){h=a;k||(k=h);q((u+h-k)*z.speed)};m.seek=function(a){q(b(a))};m.pause=function(){var a=H.indexOf(m);-1=c&&0<=e&&1>=e){var f=new Float32Array(11);if(c!==b||e!==d)for(var g=0;11>g;++g)f[g]=a(.1*g,c, e);return function(g){if(c===b&&e===d)return g;if(0===g)return 0;if(1===g)return 1;for(var q=0,h=1;10!==h&&f[h]<=g;++h)q+=.1;--h;var h=q+(g-f[h])/(f[h+1]-f[h])*.1,k=3*(1-3*e+3*c)*h*h+2*(3*e-6*c)*h+3*c;if(.001<=k){for(q=0;4>q;++q){k=3*(1-3*e+3*c)*h*h+2*(3*e-6*c)*h+3*c;if(0===k)break;var u=a(h,c,e)-g,h=h-u/k}g=h}else if(0===k)g=h;else{var h=q,q=q+.1,v=0;do u=h+(q-h)/2,k=a(u,c,e)-g,0++v);g=u}return a(g,b,d)}}}}(),V=function(){function a(c,b){return 0===c||1===c? c:-Math.pow(2,10*(c-1))*Math.sin(2*(c-1-b/(2*Math.PI)*Math.asin(1))*Math.PI/b)}var c="Quad Cubic Quart Quint Sine Expo Circ Back Elastic".split(" "),b={In:[[.55,.085,.68,.53],[.55,.055,.675,.19],[.895,.03,.685,.22],[.755,.05,.855,.06],[.47,0,.745,.715],[.95,.05,.795,.035],[.6,.04,.98,.335],[.6,-.28,.735,.045],a],Out:[[.25,.46,.45,.94],[.215,.61,.355,1],[.165,.84,.44,1],[.23,1,.32,1],[.39,.575,.565,1],[.19,1,.22,1],[.075,.82,.165,1],[.175,.885,.32,1.275],function(c,b){return 1-a(1-c,b)}],InOut:[[.455, .03,.515,.955],[.645,.045,.355,1],[.77,0,.175,1],[.86,0,.07,1],[.445,.05,.55,.95],[1,0,0,1],[.785,.135,.15,.86],[.68,-.55,.265,1.55],function(c,b){return.5>c?a(2*c,b)/2:1-a(-2*c+2,b)/2}]},e={linear:R(.25,.25,.75,.75)},d={},f;for(f in b)d.type=f,b[d.type].forEach(function(a){return function(b,d){e["ease"+a.type+c[d]]=p.fnc(b)?b:R.apply($jscomp$this,b)}}(d)),d={type:d.type};return e}(),Y={css:function(a,c,b){return a.style[c]=b},attribute:function(a,c,b){return a.setAttribute(c,b)},object:function(a, c,b){return a[c]=b},transform:function(a,c,b,e,d){e[d]||(e[d]=[]);e[d].push(c+"("+b+")")}},H=[],W=0,aa=function(){function a(){W=requestAnimationFrame(c)}function c(b){var e=H.length;if(e){for(var d=0;dd&&(e.duration=f.duration);e.children.push(f)});e.seek(0);e.reset();e.autoplay&&e.restart();return e};return e};z.random=function(a,c){return Math.floor(Math.random()*(c-a+1))+a};return z}); (function(d,g){var h={accordion:!0,onOpenStart:void 0,onOpenEnd:void 0,onCloseStart:void 0,onCloseEnd:void 0,inDuration:300,outDuration:300},k=function(f){function a(c,b){_classCallCheck(this,a);var e=_possibleConstructorReturn(this,(a.__proto__||Object.getPrototypeOf(a)).call(this,a,c,b));e.el.M_Collapsible=e;e.options=d.extend({},a.defaults,b);e.$headers=e.$el.children("li").children(".collapsible-header");e.$headers.attr("tabindex",0);e._setupEventHandlers();var f=e.$el.children("li.active").children(".collapsible-body"); e.options.accordion?f.first().css("display","block"):f.css("display","block");return e}_inherits(a,f);_createClass(a,[{key:"destroy",value:function(){this._removeEventHandlers();this.el.M_Collapsible=void 0}},{key:"_setupEventHandlers",value:function(){var a=this;this._handleCollapsibleClickBound=this._handleCollapsibleClick.bind(this);this._handleCollapsibleKeydownBound=this._handleCollapsibleKeydown.bind(this);this.el.addEventListener("click",this._handleCollapsibleClickBound);this.$headers.each(function(b){b.addEventListener("keydown", a._handleCollapsibleKeydownBound)})}},{key:"_removeEventHandlers",value:function(){var a=this;this.el.removeEventListener("click",this._handleCollapsibleClickBound);this.$headers.each(function(b){b.removeEventListener("keydown",a._handleCollapsibleKeydownBound)})}},{key:"_handleCollapsibleClick",value:function(a){var b=d(a.target).closest(".collapsible-header");if(a.target&&b.length&&(a=b.closest(".collapsible"),a[0]===this.el)){var b=b.closest("li"),e=a.children("li");a=b[0].classList.contains("active"); b=e.index(b);a?this.close(b):this.open(b)}}},{key:"_handleCollapsibleKeydown",value:function(a){13===a.keyCode&&this._handleCollapsibleClickBound(a)}},{key:"_animateIn",value:function(a){var b=this,e=this.$el.children("li").eq(a);if(e.length){var d=e.children(".collapsible-body");g.remove(d[0]);d.css({display:"block",overflow:"hidden",height:0,paddingTop:"",paddingBottom:""});a=d.css("padding-top");var f=d.css("padding-bottom"),h=d[0].scrollHeight;d.css({paddingTop:0,paddingBottom:0});g({targets:d[0], height:h,paddingTop:a,paddingBottom:f,duration:this.options.inDuration,easing:"easeInOutCubic",complete:function(a){d.css({overflow:"",paddingTop:"",paddingBottom:"",height:""});"function"===typeof b.options.onOpenEnd&&b.options.onOpenEnd.call(b,e[0])}})}}},{key:"_animateOut",value:function(a){var b=this,e=this.$el.children("li").eq(a);if(e.length){var d=e.children(".collapsible-body");g.remove(d[0]);d.css("overflow","hidden");g({targets:d[0],height:0,paddingTop:0,paddingBottom:0,duration:this.options.outDuration, easing:"easeInOutCubic",complete:function(){d.css({height:"",overflow:"",padding:"",display:""});"function"===typeof b.options.onCloseEnd&&b.options.onCloseEnd.call(b,e[0])}})}}},{key:"open",value:function(a){var b=this,e=this.$el.children("li").eq(a);if(e.length&&!e[0].classList.contains("active")){"function"===typeof this.options.onOpenStart&&this.options.onOpenStart.call(this,e[0]);if(this.options.accordion){var f=this.$el.children("li");this.$el.children("li.active").each(function(a){a=f.index(d(a)); b.close(a)})}e[0].classList.add("active");this._animateIn(a)}}},{key:"close",value:function(a){var b=this.$el.children("li").eq(a);b.length&&b[0].classList.contains("active")&&("function"===typeof this.options.onCloseStart&&this.options.onCloseStart.call(this,b[0]),b[0].classList.remove("active"),this._animateOut(a))}}],[{key:"init",value:function(c,b){return _get(a.__proto__||Object.getPrototypeOf(a),"init",this).call(this,this,c,b)}},{key:"getInstance",value:function(a){return(a.jquery?a[0]:a).M_Collapsible}}, {key:"defaults",get:function(){return h}}]);return a}(Component);M.Collapsible=k;M.jQueryLoaded&&M.initializeJqueryWrapper(k,"collapsible","M_Collapsible")})(cash,M.anime); (function(d,g){var h={alignment:"left",autoFocus:!0,constrainWidth:!0,container:null,coverTrigger:!0,closeOnClick:!0,hover:!1,inDuration:150,outDuration:250,onOpenStart:null,onOpenEnd:null,onCloseStart:null,onCloseEnd:null,onItemClick:null},k=function(f){function a(c,b){_classCallCheck(this,a);var e=_possibleConstructorReturn(this,(a.__proto__||Object.getPrototypeOf(a)).call(this,a,c,b));e.el.M_Dropdown=e;a._dropdowns.push(e);e.id=M.getIdFromTrigger(c);e.dropdownEl=document.getElementById(e.id);e.$dropdownEl= d(e.dropdownEl);e.options=d.extend({},a.defaults,b);e.isOpen=!1;e.isScrollable=!1;e.isTouchMoving=!1;e.focusedIndex=-1;e.filterQuery=[];e.options.container?d(e.options.container).append(e.dropdownEl):e.$el.after(e.dropdownEl);e._makeDropdownFocusable();e._resetFilterQueryBound=e._resetFilterQuery.bind(e);e._handleDocumentClickBound=e._handleDocumentClick.bind(e);e._handleDocumentTouchmoveBound=e._handleDocumentTouchmove.bind(e);e._handleDropdownClickBound=e._handleDropdownClick.bind(e);e._handleDropdownKeydownBound= e._handleDropdownKeydown.bind(e);e._handleTriggerKeydownBound=e._handleTriggerKeydown.bind(e);e._setupEventHandlers();return e}_inherits(a,f);_createClass(a,[{key:"destroy",value:function(){this._resetDropdownStyles();this._removeEventHandlers();a._dropdowns.splice(a._dropdowns.indexOf(this),1);this.el.M_Dropdown=void 0}},{key:"_setupEventHandlers",value:function(){this.el.addEventListener("keydown",this._handleTriggerKeydownBound);this.dropdownEl.addEventListener("click",this._handleDropdownClickBound); this.options.hover?(this._handleMouseEnterBound=this._handleMouseEnter.bind(this),this.el.addEventListener("mouseenter",this._handleMouseEnterBound),this._handleMouseLeaveBound=this._handleMouseLeave.bind(this),this.el.addEventListener("mouseleave",this._handleMouseLeaveBound),this.dropdownEl.addEventListener("mouseleave",this._handleMouseLeaveBound)):(this._handleClickBound=this._handleClick.bind(this),this.el.addEventListener("click",this._handleClickBound))}},{key:"_removeEventHandlers",value:function(){this.el.removeEventListener("keydown", this._handleTriggerKeydownBound);this.dropdownEl.removeEventListener("click",this._handleDropdownClickBound);this.options.hover?(this.el.removeEventListener("mouseenter",this._handleMouseEnterBound),this.el.removeEventListener("mouseleave",this._handleMouseLeaveBound),this.dropdownEl.removeEventListener("mouseleave",this._handleMouseLeaveBound)):this.el.removeEventListener("click",this._handleClickBound)}},{key:"_setupTemporaryEventHandlers",value:function(){document.body.addEventListener("click", this._handleDocumentClickBound,!0);document.body.addEventListener("touchend",this._handleDocumentClickBound);document.body.addEventListener("touchmove",this._handleDocumentTouchmoveBound);this.dropdownEl.addEventListener("keydown",this._handleDropdownKeydownBound)}},{key:"_removeTemporaryEventHandlers",value:function(){document.body.removeEventListener("click",this._handleDocumentClickBound,!0);document.body.removeEventListener("touchend",this._handleDocumentClickBound);document.body.removeEventListener("touchmove", this._handleDocumentTouchmoveBound);this.dropdownEl.removeEventListener("keydown",this._handleDropdownKeydownBound)}},{key:"_handleClick",value:function(a){a.preventDefault();this.open()}},{key:"_handleMouseEnter",value:function(){this.open()}},{key:"_handleMouseLeave",value:function(a){var b=a.toElement||a.relatedTarget;a=!!d(b).closest(".dropdown-content").length;var e=!1,b=d(b).closest(".dropdown-trigger");b.length&&b[0].M_Dropdown&&b[0].M_Dropdown.isOpen&&(e=!0);e||a||this.close()}},{key:"_handleDocumentClick", value:function(a){var b=this;a=d(a.target);this.options.closeOnClick&&a.closest(".dropdown-content").length&&!this.isTouchMoving?setTimeout(function(){b.close()},0):!a.closest(".dropdown-trigger").length&&a.closest(".dropdown-content").length||setTimeout(function(){b.close()},0);this.isTouchMoving=!1}},{key:"_handleTriggerKeydown",value:function(a){a.which!==M.keys.ARROW_DOWN&&a.which!==M.keys.ENTER||this.isOpen||(a.preventDefault(),this.open())}},{key:"_handleDocumentTouchmove",value:function(a){d(a.target).closest(".dropdown-content").length&& (this.isTouchMoving=!0)}},{key:"_handleDropdownClick",value:function(a){"function"===typeof this.options.onItemClick&&(a=d(a.target).closest("li")[0],this.options.onItemClick.call(this,a))}},{key:"_handleDropdownKeydown",value:function(a){if(a.which===M.keys.TAB)a.preventDefault(),this.close();else if(a.which!==M.keys.ARROW_DOWN&&a.which!==M.keys.ARROW_UP||!this.isOpen)a.which===M.keys.ENTER&&this.isOpen?(b=this.dropdownEl.children[this.focusedIndex],e=d(b).find("a, button").first(),e.length?e[0].click(): b&&b.click()):a.which===M.keys.ESC&&this.isOpen&&(a.preventDefault(),this.close());else{a.preventDefault();var b=a.which===M.keys.ARROW_DOWN?1:-1,e=this.focusedIndex,f=!1;do if(e+=b,this.dropdownEl.children[e]&&-1!==this.dropdownEl.children[e].tabIndex){f=!0;break}while(eh.spaceOnBottom?(k="bottom",e+=h.spaceOnTop,g-=h.spaceOnTop):e+=h.spaceOnBottom));h[l]||(l="left"===l?"right":"left",h[l]||(h.spaceOnLeft> h.spaceOnRight?(l="right",d+=h.spaceOnLeft,f-=h.spaceOnLeft):(l="left",d+=h.spaceOnRight)));"bottom"===k&&(g=g-b.height+(this.options.coverTrigger?a.height:0));"right"===l&&(f=f-b.width+a.width);return{x:f,y:g,verticalAlignment:k,horizontalAlignment:l,height:e,width:d}}},{key:"_animateIn",value:function(){var a=this;g.remove(this.dropdownEl);g({targets:this.dropdownEl,opacity:{value:[0,1],easing:"easeOutQuad"},scaleX:[.3,1],scaleY:[.3,1],duration:this.options.inDuration,easing:"easeOutQuint",complete:function(b){a.options.autoFocus&& a.dropdownEl.focus();"function"===typeof a.options.onOpenEnd&&a.options.onOpenEnd.call(a,a.el)}})}},{key:"_animateOut",value:function(){var a=this;g.remove(this.dropdownEl);g({targets:this.dropdownEl,opacity:{value:0,easing:"easeOutQuint"},scaleX:.3,scaleY:.3,duration:this.options.outDuration,easing:"easeOutQuint",complete:function(b){a._resetDropdownStyles();"function"===typeof a.options.onCloseEnd&&a.options.onCloseEnd.call(a,a.el)}})}},{key:"_placeDropdown",value:function(){var a=this.options.constrainWidth? this.el.getBoundingClientRect().width:this.dropdownEl.getBoundingClientRect().width;this.dropdownEl.style.width=a+"px";a=this._getDropdownPosition();this.dropdownEl.style.left=a.x+"px";this.dropdownEl.style.top=a.y+"px";this.dropdownEl.style.height=a.height+"px";this.dropdownEl.style.width=a.width+"px";this.dropdownEl.style.transformOrigin=("left"===a.horizontalAlignment?"0":"100%")+" "+("top"===a.verticalAlignment?"0":"100%")}},{key:"open",value:function(){this.isOpen||(this.isOpen=!0,"function"=== typeof this.options.onOpenStart&&this.options.onOpenStart.call(this,this.el),this._resetDropdownStyles(),this.dropdownEl.style.display="block",this._placeDropdown(),this._animateIn(),this._setupTemporaryEventHandlers())}},{key:"close",value:function(){this.isOpen&&(this.isOpen=!1,this.focusedIndex=-1,"function"===typeof this.options.onCloseStart&&this.options.onCloseStart.call(this,this.el),this._animateOut(),this._removeTemporaryEventHandlers(),this.options.autoFocus&&this.el.focus())}},{key:"recalculateDimensions", value:function(){this.isOpen&&(this.$dropdownEl.css({width:"",height:"",left:"",top:"","transform-origin":""}),this._placeDropdown())}}],[{key:"init",value:function(c,b){return _get(a.__proto__||Object.getPrototypeOf(a),"init",this).call(this,this,c,b)}},{key:"getInstance",value:function(a){return(a.jquery?a[0]:a).M_Dropdown}},{key:"defaults",get:function(){return h}}]);return a}(Component);k._dropdowns=[];M.Dropdown=k;M.jQueryLoaded&&M.initializeJqueryWrapper(k,"dropdown","M_Dropdown")})(cash,M.anime); (function(d,g){var h={opacity:.5,inDuration:250,outDuration:250,onOpenStart:null,onOpenEnd:null,onCloseStart:null,onCloseEnd:null,preventScrolling:!0,dismissible:!0,startingTop:"4%",endingTop:"10%"},k=function(f){function a(c,b){_classCallCheck(this,a);var e=_possibleConstructorReturn(this,(a.__proto__||Object.getPrototypeOf(a)).call(this,a,c,b));e.el.M_Modal=e;e.options=d.extend({},a.defaults,b);e.isOpen=!1;e.id=e.$el.attr("id");e._openingTrigger=void 0;e.$overlay=d(''); e.el.tabIndex=0;e._nthModalOpened=0;a._count++;e._setupEventHandlers();return e}_inherits(a,f);_createClass(a,[{key:"destroy",value:function(){a._count--;this._removeEventHandlers();this.el.removeAttribute("style");this.$overlay.remove();this.el.M_Modal=void 0}},{key:"_setupEventHandlers",value:function(){this._handleOverlayClickBound=this._handleOverlayClick.bind(this);this._handleModalCloseClickBound=this._handleModalCloseClick.bind(this);1===a._count&&document.body.addEventListener("click",this._handleTriggerClick); this.$overlay[0].addEventListener("click",this._handleOverlayClickBound);this.el.addEventListener("click",this._handleModalCloseClickBound)}},{key:"_removeEventHandlers",value:function(){0===a._count&&document.body.removeEventListener("click",this._handleTriggerClick);this.$overlay[0].removeEventListener("click",this._handleOverlayClickBound);this.el.removeEventListener("click",this._handleModalCloseClickBound)}},{key:"_handleTriggerClick",value:function(a){var b=d(a.target).closest(".modal-trigger"); if(b.length){var e=M.getIdFromTrigger(b[0]);(e=document.getElementById(e).M_Modal)&&e.open(b);a.preventDefault()}}},{key:"_handleOverlayClick",value:function(){this.options.dismissible&&this.close()}},{key:"_handleModalCloseClick",value:function(a){d(a.target).closest(".modal-close").length&&this.close()}},{key:"_handleKeydown",value:function(a){27===a.keyCode&&this.options.dismissible&&this.close()}},{key:"_handleFocus",value:function(c){this.el.contains(c.target)||this._nthModalOpened!==a._modalsOpen|| this.el.focus()}},{key:"_animateIn",value:function(){var a=this;d.extend(this.el.style,{display:"block",opacity:0});d.extend(this.$overlay[0].style,{display:"block",opacity:0});g({targets:this.$overlay[0],opacity:this.options.opacity,duration:this.options.inDuration,easing:"easeOutQuad"});var b={targets:this.el,duration:this.options.inDuration,easing:"easeOutCubic",complete:function(){"function"===typeof a.options.onOpenEnd&&a.options.onOpenEnd.call(a,a.el,a._openingTrigger)}};this.el.classList.contains("bottom-sheet")? d.extend(b,{bottom:0,opacity:1}):d.extend(b,{top:[this.options.startingTop,this.options.endingTop],opacity:1,scaleX:[.8,1],scaleY:[.8,1]});g(b)}},{key:"_animateOut",value:function(){var a=this;g({targets:this.$overlay[0],opacity:0,duration:this.options.outDuration,easing:"easeOutQuart"});var b={targets:this.el,duration:this.options.outDuration,easing:"easeOutCubic",complete:function(){a.el.style.display="none";a.$overlay.remove();"function"===typeof a.options.onCloseEnd&&a.options.onCloseEnd.call(a, a.el)}};this.el.classList.contains("bottom-sheet")?d.extend(b,{bottom:"-100%",opacity:0}):d.extend(b,{top:[this.options.endingTop,this.options.startingTop],opacity:0,scaleX:.8,scaleY:.8});g(b)}},{key:"open",value:function(c){if(!this.isOpen)return this.isOpen=!0,a._modalsOpen++,this._nthModalOpened=a._modalsOpen,this.$overlay[0].style.zIndex=1E3+2*a._modalsOpen,this.el.style.zIndex=2*a._modalsOpen+1001,this._openingTrigger=c?c[0]:void 0,"function"===typeof this.options.onOpenStart&&this.options.onOpenStart.call(this, this.el,this._openingTrigger),this.options.preventScrolling&&(document.body.style.overflow="hidden"),this.el.classList.add("open"),this.el.insertAdjacentElement("afterend",this.$overlay[0]),this.options.dismissible&&(this._handleKeydownBound=this._handleKeydown.bind(this),this._handleFocusBound=this._handleFocus.bind(this),document.addEventListener("keydown",this._handleKeydownBound),document.addEventListener("focus",this._handleFocusBound,!0)),g.remove(this.el),g.remove(this.$overlay[0]),this._animateIn(), this.el.focus(),this}},{key:"close",value:function(){if(this.isOpen)return this.isOpen=!1,a._modalsOpen--,this._nthModalOpened=0,"function"===typeof this.options.onCloseStart&&this.options.onCloseStart.call(this,this.el),this.el.classList.remove("open"),0===a._modalsOpen&&(document.body.style.overflow=""),this.options.dismissible&&(document.removeEventListener("keydown",this._handleKeydownBound),document.removeEventListener("focus",this._handleFocusBound,!0)),g.remove(this.el),g.remove(this.$overlay[0]), this._animateOut(),this}}],[{key:"init",value:function(c,b){return _get(a.__proto__||Object.getPrototypeOf(a),"init",this).call(this,this,c,b)}},{key:"getInstance",value:function(a){return(a.jquery?a[0]:a).M_Modal}},{key:"defaults",get:function(){return h}}]);return a}(Component);k._modalsOpen=0;k._count=0;M.Modal=k;M.jQueryLoaded&&M.initializeJqueryWrapper(k,"modal","M_Modal")})(cash,M.anime); (function(d,g){var h={inDuration:275,outDuration:200,onOpenStart:null,onOpenEnd:null,onCloseStart:null,onCloseEnd:null},k=function(f){function a(c,b){_classCallCheck(this,a);var e=_possibleConstructorReturn(this,(a.__proto__||Object.getPrototypeOf(a)).call(this,a,c,b));e.el.M_Materialbox=e;e.options=d.extend({},a.defaults,b);e.overlayActive=!1;e.doneAnimating=!0;e.placeholder=d("
").addClass("material-placeholder");e.originalWidth=0;e.originalHeight=0;e.originInlineStyles=e.$el.attr("style"); e.caption=e.el.getAttribute("data-caption")||"";e.$el.before(e.placeholder);e.placeholder.append(e.$el);e._setupEventHandlers();return e}_inherits(a,f);_createClass(a,[{key:"destroy",value:function(){this._removeEventHandlers();this.el.M_Materialbox=void 0;d(this.placeholder).after(this.el).remove();this.$el.removeAttr("style")}},{key:"_setupEventHandlers",value:function(){this._handleMaterialboxClickBound=this._handleMaterialboxClick.bind(this);this.el.addEventListener("click",this._handleMaterialboxClickBound)}}, {key:"_removeEventHandlers",value:function(){this.el.removeEventListener("click",this._handleMaterialboxClickBound)}},{key:"_handleMaterialboxClick",value:function(a){!1===this.doneAnimating||this.overlayActive&&this.doneAnimating?this.close():this.open()}},{key:"_handleWindowScroll",value:function(){this.overlayActive&&this.close()}},{key:"_handleWindowResize",value:function(){this.overlayActive&&this.close()}},{key:"_handleWindowEscape",value:function(a){27===a.keyCode&&this.doneAnimating&&this.overlayActive&& this.close()}},{key:"_makeAncestorsOverflowVisible",value:function(){this.ancestorsChanged=d();for(var a=this.placeholder[0].parentNode;null!==a&&!d(a).is(document);){var b=d(a);"visible"!==b.css("overflow")&&(b.css("overflow","visible"),this.ancestorsChanged=void 0===this.ancestorsChanged?b:this.ancestorsChanged.add(b));a=a.parentNode}}},{key:"_animateImageIn",value:function(){var a=this,b={targets:this.el,height:[this.originalHeight,this.newHeight],width:[this.originalWidth,this.newWidth],left:M.getDocumentScrollLeft()+ this.windowWidth/2-this.placeholder.offset().left-this.newWidth/2,top:M.getDocumentScrollTop()+this.windowHeight/2-this.placeholder.offset().top-this.newHeight/2,duration:this.options.inDuration,easing:"easeOutQuad",complete:function(){a.doneAnimating=!0;"function"===typeof a.options.onOpenEnd&&a.options.onOpenEnd.call(a,a.el)}};this.maxWidth=this.$el.css("max-width");this.maxHeight=this.$el.css("max-height");"none"!==this.maxWidth&&(b.maxWidth=this.newWidth);"none"!==this.maxHeight&&(b.maxHeight= this.newHeight);g(b)}},{key:"_animateImageOut",value:function(){var a=this;g({targets:this.el,width:this.originalWidth,height:this.originalHeight,left:0,top:0,duration:this.options.outDuration,easing:"easeOutQuad",complete:function(){a.placeholder.css({height:"",width:"",position:"",top:"",left:""});a.attrWidth&&a.$el.attr("width",a.attrWidth);a.attrHeight&&a.$el.attr("height",a.attrHeight);a.$el.removeAttr("style");a.originInlineStyles&&a.$el.attr("style",a.originInlineStyles);a.$el.removeClass("active"); a.doneAnimating=!0;a.ancestorsChanged.length&&a.ancestorsChanged.css("overflow","");"function"===typeof a.options.onCloseEnd&&a.options.onCloseEnd.call(a,a.el)}})}},{key:"_updateVars",value:function(){this.windowWidth=window.innerWidth;this.windowHeight=window.innerHeight;this.caption=this.el.getAttribute("data-caption")||""}},{key:"open",value:function(){var a=this;this._updateVars();this.originalWidth=this.el.getBoundingClientRect().width;this.originalHeight=this.el.getBoundingClientRect().height; this.doneAnimating=!1;this.$el.addClass("active");this.overlayActive=!0;"function"===typeof this.options.onOpenStart&&this.options.onOpenStart.call(this,this.el);this.placeholder.css({width:this.placeholder[0].getBoundingClientRect().width+"px",height:this.placeholder[0].getBoundingClientRect().height+"px",position:"relative",top:0,left:0});this._makeAncestorsOverflowVisible();this.$el.css({position:"absolute","z-index":1E3,"will-change":"left, top, width, height"});this.attrWidth=this.$el.attr("width"); this.attrHeight=this.$el.attr("height");this.attrWidth&&(this.$el.css("width",this.attrWidth+"px"),this.$el.removeAttr("width"));this.attrHeight&&(this.$el.css("width",this.attrHeight+"px"),this.$el.removeAttr("height"));this.$overlay=d('
').css({opacity:0}).one("click",function(){a.doneAnimating&&a.close()});this.$el.before(this.$overlay);var b=this.$overlay[0].getBoundingClientRect();this.$overlay.css({width:this.windowWidth+"px",height:this.windowHeight+"px", left:-1*b.left+"px",top:-1*b.top+"px"});g.remove(this.el);g.remove(this.$overlay[0]);g({targets:this.$overlay[0],opacity:1,duration:this.options.inDuration,easing:"easeOutQuad"});""!==this.caption&&(this.$photocaption&&g.remove(this.$photoCaption[0]),this.$photoCaption=d('
'),this.$photoCaption.text(this.caption),d("body").append(this.$photoCaption),this.$photoCaption.css({display:"inline"}),g({targets:this.$photoCaption[0],opacity:1,duration:this.options.inDuration, easing:"easeOutQuad"}));var b=0,b=this.originalWidth/this.windowWidth,e=this.originalHeight/this.windowHeight;this.newHeight=this.newWidth=0;b>e?(b=this.originalHeight/this.originalWidth,this.newWidth=.9*this.windowWidth,this.newHeight=.9*this.windowWidth*b):(b=this.originalWidth/this.originalHeight,this.newWidth=.9*this.windowHeight*b,this.newHeight=.9*this.windowHeight);this._animateImageIn();this._handleWindowScrollBound=this._handleWindowScroll.bind(this);this._handleWindowResizeBound=this._handleWindowResize.bind(this); this._handleWindowEscapeBound=this._handleWindowEscape.bind(this);window.addEventListener("scroll",this._handleWindowScrollBound);window.addEventListener("resize",this._handleWindowResizeBound);window.addEventListener("keyup",this._handleWindowEscapeBound)}},{key:"close",value:function(){var a=this;this._updateVars();this.doneAnimating=!1;"function"===typeof this.options.onCloseStart&&this.options.onCloseStart.call(this,this.el);g.remove(this.el);g.remove(this.$overlay[0]);""!==this.caption&&g.remove(this.$photoCaption[0]); window.removeEventListener("scroll",this._handleWindowScrollBound);window.removeEventListener("resize",this._handleWindowResizeBound);window.removeEventListener("keyup",this._handleWindowEscapeBound);g({targets:this.$overlay[0],opacity:0,duration:this.options.outDuration,easing:"easeOutQuad",complete:function(){a.overlayActive=!1;a.$overlay.remove()}});this._animateImageOut();""!==this.caption&&g({targets:this.$photoCaption[0],opacity:0,duration:this.options.outDuration,easing:"easeOutQuad",complete:function(){a.$photoCaption.remove()}})}}], [{key:"init",value:function(c,b){return _get(a.__proto__||Object.getPrototypeOf(a),"init",this).call(this,this,c,b)}},{key:"getInstance",value:function(a){return(a.jquery?a[0]:a).M_Materialbox}},{key:"defaults",get:function(){return h}}]);return a}(Component);M.Materialbox=k;M.jQueryLoaded&&M.initializeJqueryWrapper(k,"materialbox","M_Materialbox")})(cash,M.anime); (function(d){var g={responsiveThreshold:0},h=function(h){function f(a,c){_classCallCheck(this,f);var b=_possibleConstructorReturn(this,(f.__proto__||Object.getPrototypeOf(f)).call(this,f,a,c));b.el.M_Parallax=b;b.options=d.extend({},f.defaults,c);b._enabled=window.innerWidth>b.options.responsiveThreshold;b.$img=b.$el.find("img").first();b.$img.each(function(){this.complete&&d(this).trigger("load")});b._updateParallax();b._setupEventHandlers();b._setupStyles();f._parallaxes.push(b);return b}_inherits(f, h);_createClass(f,[{key:"destroy",value:function(){f._parallaxes.splice(f._parallaxes.indexOf(this),1);this.$img[0].style.transform="";this._removeEventHandlers();this.$el[0].M_Parallax=void 0}},{key:"_setupEventHandlers",value:function(){this._handleImageLoadBound=this._handleImageLoad.bind(this);this.$img[0].addEventListener("load",this._handleImageLoadBound);0===f._parallaxes.length&&(f._handleScrollThrottled=M.throttle(f._handleScroll,5),window.addEventListener("scroll",f._handleScrollThrottled), f._handleWindowResizeThrottled=M.throttle(f._handleWindowResize,5),window.addEventListener("resize",f._handleWindowResizeThrottled))}},{key:"_removeEventHandlers",value:function(){this.$img[0].removeEventListener("load",this._handleImageLoadBound);0===f._parallaxes.length&&(window.removeEventListener("scroll",f._handleScrollThrottled),window.removeEventListener("resize",f._handleWindowResizeThrottled))}},{key:"_setupStyles",value:function(){this.$img[0].style.opacity=1}},{key:"_handleImageLoad",value:function(){this._updateParallax()}}, {key:"_updateParallax",value:function(){var a=0d&&ec.options.responsiveThreshold}}},{key:"defaults",get:function(){return g}}]);return f}(Component);h._parallaxes=[];M.Parallax=h;M.jQueryLoaded&&M.initializeJqueryWrapper(h,"parallax", "M_Parallax")})(cash); (function(d,g){var h={duration:300,onShow:null,swipeable:!1,responsiveThreshold:Infinity},k=function(f){function a(c,b){_classCallCheck(this,a);var e=_possibleConstructorReturn(this,(a.__proto__||Object.getPrototypeOf(a)).call(this,a,c,b));e.el.M_Tabs=e;e.options=d.extend({},a.defaults,b);e.$tabLinks=e.$el.children("li.tab").children("a");e.index=0;e._setupActiveTabLink();e.options.swipeable?e._setupSwipeableTabs():e._setupNormalTabs();e._setTabsAndTabWidth();e._createIndicator();e._setupEventHandlers(); return e}_inherits(a,f);_createClass(a,[{key:"destroy",value:function(){this._removeEventHandlers();this._indicator.parentNode.removeChild(this._indicator);this.options.swipeable?this._teardownSwipeableTabs():this._teardownNormalTabs();this.$el[0].M_Tabs=void 0}},{key:"_setupEventHandlers",value:function(){this._handleWindowResizeBound=this._handleWindowResize.bind(this);window.addEventListener("resize",this._handleWindowResizeBound);this._handleTabClickBound=this._handleTabClick.bind(this);this.el.addEventListener("click", this._handleTabClickBound)}},{key:"_removeEventHandlers",value:function(){window.removeEventListener("resize",this._handleWindowResizeBound);this.el.removeEventListener("click",this._handleTabClickBound)}},{key:"_handleWindowResize",value:function(){this._setTabsAndTabWidth();0!==this.tabWidth&&0!==this.tabsWidth&&(this._indicator.style.left=this._calcLeftPos(this.$activeTabLink)+"px",this._indicator.style.right=this._calcRightPos(this.$activeTabLink)+"px")}},{key:"_handleTabClick",value:function(a){var b= this,e=d(a.target).closest("li.tab"),f=d(a.target).closest("a");if(f.length&&f.parent().hasClass("tab"))if(e.hasClass("disabled"))a.preventDefault();else if(!f.attr("target")){this.$activeTabLink.removeClass("active");e=this.$content;this.$activeTabLink=f;this.$content=d(M.escapeHash(f[0].hash));this.$tabLinks=this.$el.children("li.tab").children("a");this.$activeTabLink.addClass("active");var g=this.index;this.index=Math.max(this.$tabLinks.index(f),0);this.options.swipeable?this._tabsCarousel&&this._tabsCarousel.set(this.index, function(){"function"===typeof b.options.onShow&&b.options.onShow.call(b,b.$content[0])}):this.$content.length&&(this.$content[0].style.display="block",this.$content.addClass("active"),"function"===typeof this.options.onShow&&this.options.onShow.call(this,this.$content[0]),e.length&&!e.is(this.$content)&&(e[0].style.display="none",e.removeClass("active")));this._setTabsAndTabWidth();this._animateIndicator(g);a.preventDefault()}}},{key:"_createIndicator",value:function(){var a=this,b=document.createElement("li"); b.classList.add("indicator");this.el.appendChild(b);this._indicator=b;setTimeout(function(){a._indicator.style.left=a._calcLeftPos(a.$activeTabLink)+"px";a._indicator.style.right=a._calcRightPos(a.$activeTabLink)+"px"},0)}},{key:"_setupActiveTabLink",value:function(){this.$activeTabLink=d(this.$tabLinks.filter('[href="'+location.hash+'"]'));0===this.$activeTabLink.length&&(this.$activeTabLink=this.$el.children("li.tab").children("a.active").first());0===this.$activeTabLink.length&&(this.$activeTabLink= this.$el.children("li.tab").children("a").first());this.$tabLinks.removeClass("active");this.$activeTabLink[0].classList.add("active");this.index=Math.max(this.$tabLinks.index(this.$activeTabLink),0);this.$activeTabLink.length&&(this.$content=d(M.escapeHash(this.$activeTabLink[0].hash)),this.$content.addClass("active"))}},{key:"_setupSwipeableTabs",value:function(){var a=this;window.innerWidth>this.options.responsiveThreshold&&(this.options.swipeable=!1);var b=d();this.$tabLinks.each(function(a){a= d(M.escapeHash(a.hash));a.addClass("carousel-item");b=b.add(a)});var e=d('');b.first().before(e);e.append(b);b[0].style.display="";var f=this.$activeTabLink.closest(".tab").index();this._tabsCarousel=M.Carousel.init(e[0],{fullWidth:!0,noWrap:!0,onCycleTo:function(b){var e=a.index;a.index=d(b).index();a.$activeTabLink.removeClass("active");a.$activeTabLink=a.$tabLinks.eq(a.index);a.$activeTabLink.addClass("active");a._animateIndicator(e);"function"=== typeof a.options.onShow&&a.options.onShow.call(a,a.$content[0])}});this._tabsCarousel.set(f)}},{key:"_teardownSwipeableTabs",value:function(){var a=this._tabsCarousel.$el;this._tabsCarousel.destroy();a.after(a.children());a.remove()}},{key:"_setupNormalTabs",value:function(){this.$tabLinks.not(this.$activeTabLink).each(function(a){a.hash&&(a=d(M.escapeHash(a.hash)),a.length&&(a[0].style.display="none"))})}},{key:"_teardownNormalTabs",value:function(){this.$tabLinks.each(function(a){a.hash&&(a=d(M.escapeHash(a.hash)), a.length&&(a[0].style.display=""))})}},{key:"_setTabsAndTabWidth",value:function(){this.tabsWidth=this.$el.width();this.tabWidth=Math.max(this.tabsWidth,this.el.scrollWidth)/this.$tabLinks.length}},{key:"_calcRightPos",value:function(a){return Math.ceil(this.tabsWidth-a.position().left-a[0].getBoundingClientRect().width)}},{key:"_calcLeftPos",value:function(a){return Math.floor(a.position().left)}},{key:"updateTabIndicator",value:function(){this._setTabsAndTabWidth();this._animateIndicator(this.index)}}, {key:"_animateIndicator",value:function(a){var b=0,e=0;0<=this.index-a?b=90:e=90;a={targets:this._indicator,left:{value:this._calcLeftPos(this.$activeTabLink),delay:b},right:{value:this._calcRightPos(this.$activeTabLink),delay:e},duration:this.options.duration,easing:"easeOutQuad"};g.remove(this._indicator);g(a)}},{key:"select",value:function(a){a=this.$tabLinks.filter('[href="#'+a+'"]');a.length&&a.trigger("click")}}],[{key:"init",value:function(c,b){return _get(a.__proto__||Object.getPrototypeOf(a), "init",this).call(this,this,c,b)}},{key:"getInstance",value:function(a){return(a.jquery?a[0]:a).M_Tabs}},{key:"defaults",get:function(){return h}}]);return a}(Component);M.Tabs=k;M.jQueryLoaded&&M.initializeJqueryWrapper(k,"tabs","M_Tabs")})(cash,M.anime); (function(d,g){var h={exitDelay:200,enterDelay:0,html:null,margin:5,inDuration:250,outDuration:200,position:"bottom",transitionMovement:10},k=function(f){function a(c,b){_classCallCheck(this,a);var e=_possibleConstructorReturn(this,(a.__proto__||Object.getPrototypeOf(a)).call(this,a,c,b));e.el.M_Tooltip=e;e.options=d.extend({},a.defaults,b);e.isOpen=!1;e.isHovered=!1;e.isFocused=!1;e._appendTooltipEl();e._setupEventHandlers();return e}_inherits(a,f);_createClass(a,[{key:"destroy",value:function(){d(this.tooltipEl).remove(); this._removeEventHandlers();this.el.M_Tooltip=void 0}},{key:"_appendTooltipEl",value:function(){var a=document.createElement("div");a.classList.add("material-tooltip");this.tooltipEl=a;var b=document.createElement("div");b.classList.add("tooltip-content");b.innerHTML=this.options.html;a.appendChild(b);document.body.appendChild(a)}},{key:"_updateTooltipContent",value:function(){this.tooltipEl.querySelector(".tooltip-content").innerHTML=this.options.html}},{key:"_setupEventHandlers",value:function(){this._handleMouseEnterBound= this._handleMouseEnter.bind(this);this._handleMouseLeaveBound=this._handleMouseLeave.bind(this);this._handleFocusBound=this._handleFocus.bind(this);this._handleBlurBound=this._handleBlur.bind(this);this.el.addEventListener("mouseenter",this._handleMouseEnterBound);this.el.addEventListener("mouseleave",this._handleMouseLeaveBound);this.el.addEventListener("focus",this._handleFocusBound,!0);this.el.addEventListener("blur",this._handleBlurBound,!0)}},{key:"_removeEventHandlers",value:function(){this.el.removeEventListener("mouseenter", this._handleMouseEnterBound);this.el.removeEventListener("mouseleave",this._handleMouseLeaveBound);this.el.removeEventListener("focus",this._handleFocusBound,!0);this.el.removeEventListener("blur",this._handleBlurBound,!0)}},{key:"open",value:function(a){this.isOpen||(a=void 0===a?!0:void 0,this.isOpen=!0,this.options=d.extend({},this.options,this._getAttributeOptions()),this._updateTooltipContent(),this._setEnterDelayTimeout(a))}},{key:"close",value:function(){this.isOpen&&(this.isOpen=this.isFocused= this.isHovered=!1,this._setExitDelayTimeout())}},{key:"_setExitDelayTimeout",value:function(){var a=this;clearTimeout(this._exitDelayTimeout);this._exitDelayTimeout=setTimeout(function(){a.isHovered||a.isFocused||a._animateOut()},this.options.exitDelay)}},{key:"_setEnterDelayTimeout",value:function(a){var b=this;clearTimeout(this._enterDelayTimeout);this._enterDelayTimeout=setTimeout(function(){(b.isHovered||b.isFocused||a)&&b._animateIn()},this.options.enterDelay)}},{key:"_positionTooltip",value:function(){var a= this.el,b=this.tooltipEl,e=a.offsetHeight,f=a.offsetWidth,g=b.offsetHeight,h=b.offsetWidth,k=void 0,k=this.options.margin,n=void 0,l=void 0;this.yMovement=this.xMovement=0;n=a.getBoundingClientRect().top+M.getDocumentScrollTop();l=a.getBoundingClientRect().left+M.getDocumentScrollLeft();"top"===this.options.position?(n+=-g-k,l+=f/2-h/2,this.yMovement=-this.options.transitionMovement):"right"===this.options.position?(n+=e/2-g/2,l+=f+k,this.xMovement=this.options.transitionMovement):"left"===this.options.position? (n+=e/2-g/2,l+=-h-k,this.xMovement=-this.options.transitionMovement):(n+=e+k,l+=f/2-h/2,this.yMovement=this.options.transitionMovement);k=this._repositionWithinScreen(l,n,h,g);d(b).css({top:k.y+"px",left:k.x+"px"})}},{key:"_repositionWithinScreen",value:function(a,b,e,d){var f=M.getDocumentScrollLeft(),g=M.getDocumentScrollTop();a-=f;b-=g;var h=this.options.margin+this.options.transitionMovement,k=M.checkWithinContainer(document.body,{left:a,top:b,width:e,height:d},h);k.left?a=h:k.right&&(a-=a+e- window.innerWidth);k.top?b=h:k.bottom&&(b-=b+d-window.innerHeight);return{x:a+f,y:b+g}}},{key:"_animateIn",value:function(){this._positionTooltip();this.tooltipEl.style.visibility="visible";g.remove(this.tooltipEl);g({targets:this.tooltipEl,opacity:1,translateX:this.xMovement,translateY:this.yMovement,duration:this.options.inDuration,easing:"easeOutCubic"})}},{key:"_animateOut",value:function(){g.remove(this.tooltipEl);g({targets:this.tooltipEl,opacity:0,translateX:0,translateY:0,duration:this.options.outDuration, easing:"easeOutCubic"})}},{key:"_handleMouseEnter",value:function(){this.isHovered=!0;this.isFocused=!1;this.open(!1)}},{key:"_handleMouseLeave",value:function(){this.isFocused=this.isHovered=!1;this.close()}},{key:"_handleFocus",value:function(){M.tabPressed&&(this.isFocused=!0,this.open(!1))}},{key:"_handleBlur",value:function(){this.isFocused=!1;this.close()}},{key:"_getAttributeOptions",value:function(){var a={},b=this.el.getAttribute("data-tooltip"),e=this.el.getAttribute("data-position");b&& (a.html=b);e&&(a.position=e);return a}}],[{key:"init",value:function(c,b){return _get(a.__proto__||Object.getPrototypeOf(a),"init",this).call(this,this,c,b)}},{key:"getInstance",value:function(a){return(a.jquery?a[0]:a).M_Tooltip}},{key:"defaults",get:function(){return h}}]);return a}(Component);M.Tooltip=k;M.jQueryLoaded&&M.initializeJqueryWrapper(k,"tooltip","M_Tooltip")})(cash,M.anime); (function(d){function g(a){var c="",d;for(d in a)a.hasOwnProperty(d)&&(c+=d+":"+a[d]+";");return c}function h(b){var e;if(!1===c.allowEvent(b))e=null;else{e=null;for(var f=b.target||b.srcElement;null!==f.parentNode;){if(!(f instanceof SVGElement)&&-1!==f.className.indexOf("waves-effect")){e=f;break}f=f.parentNode}}null!==e&&(a.show(b,e),"ontouchstart"in d&&(e.addEventListener("touchend",a.hide,!1),e.addEventListener("touchcancel",a.hide,!1)),e.addEventListener("mouseup",a.hide,!1),e.addEventListener("mouseleave", a.hide,!1),e.addEventListener("dragend",a.hide,!1))}var k=k||{},f=document.querySelectorAll.bind(document),a={duration:750,show:function(c,e){var d,f;if(2===c.button)return!1;var h=e||this,k=document.createElement("div");k.className="waves-ripple";h.appendChild(k);var n,l={top:0,left:0};d=h&&h.ownerDocument;f=d.documentElement;"undefined"!==typeof h.getBoundingClientRect&&(l=h.getBoundingClientRect());n=null!==d&&d===d.window?d:9===d.nodeType&&d.defaultView;d=l.top+n.pageYOffset-f.clientTop;f=l.left+ n.pageXOffset-f.clientLeft;l=c.pageY-d;n=c.pageX-f;h="scale("+h.clientWidth/100*10+")";"touches"in c&&(l=c.touches[0].pageY-d,n=c.touches[0].pageX-f);k.setAttribute("data-hold",Date.now());k.setAttribute("data-scale",h);k.setAttribute("data-x",n);k.setAttribute("data-y",l);d={top:l+"px",left:n+"px"};k.className+=" waves-notransition";k.setAttribute("style",g(d));k.className=k.className.replace("waves-notransition","");d["-webkit-transform"]=h;d["-moz-transform"]=h;d["-ms-transform"]=h;d["-o-transform"]= h;d.transform=h;d.opacity="1";d["-webkit-transition-duration"]=a.duration+"ms";d["-moz-transition-duration"]=a.duration+"ms";d["-o-transition-duration"]=a.duration+"ms";d["transition-duration"]=a.duration+"ms";d["-webkit-transition-timing-function"]="cubic-bezier(0.250, 0.460, 0.450, 0.940)";d["-moz-transition-timing-function"]="cubic-bezier(0.250, 0.460, 0.450, 0.940)";d["-o-transition-timing-function"]="cubic-bezier(0.250, 0.460, 0.450, 0.940)";d["transition-timing-function"]="cubic-bezier(0.250, 0.460, 0.450, 0.940)"; k.setAttribute("style",g(d))},hide:function(b){c.touchup(b);var e=this,d=null;b=e.getElementsByClassName("waves-ripple");if(0b&&(b=0);setTimeout(function(){d.setAttribute("style",g({top:h+"px",left:f+"px",opacity:"0","-webkit-transition-duration":a.duration+"ms","-moz-transition-duration":a.duration+"ms","-o-transition-duration":a.duration+ "ms","transition-duration":a.duration+"ms","-webkit-transform":k,"-moz-transform":k,"-ms-transform":k,"-o-transform":k,transform:k}));setTimeout(function(){try{e.removeChild(d)}catch(a){return!1}},a.duration)},b)},wrapInput:function(a){for(var c=0;c=a.timeRemaining&&a.dismiss()},20))}},{key:"dismiss",value:function(){var a=this;window.clearInterval(this.counterInterval);var c=this.el.offsetWidth*this.options.activationPercent;this.wasSwiped&&(this.el.style.transition="transform .05s, opacity .05s", this.el.style.transform="translateX("+c+"px)",this.el.style.opacity=0);g({targets:this.el,opacity:0,marginTop:-40,duration:this.options.outDuration,easing:"easeOutExpo",complete:function(){"function"===typeof a.options.completeCallback&&a.options.completeCallback();a.$el.remove();f._toasts.splice(f._toasts.indexOf(a),1);0===f._toasts.length&&f._removeContainer()}})}}],[{key:"getInstance",value:function(a){return(a.jquery?a[0]:a).M_Toast}},{key:"_createContainer",value:function(){var a=document.createElement("div"); a.setAttribute("id","toast-container");a.addEventListener("touchstart",f._onDragStart);a.addEventListener("touchmove",f._onDragMove);a.addEventListener("touchend",f._onDragEnd);a.addEventListener("mousedown",f._onDragStart);document.addEventListener("mousemove",f._onDragMove);document.addEventListener("mouseup",f._onDragEnd);document.body.appendChild(a);f._container=a}},{key:"_removeContainer",value:function(){document.removeEventListener("mousemove",f._onDragMove);document.removeEventListener("mouseup", f._onDragEnd);d(f._container).remove();f._container=null}},{key:"_onDragStart",value:function(a){if(a.target&&d(a.target).closest(".toast").length){var c=d(a.target).closest(".toast")[0].M_Toast;c.panning=!0;f._draggedToast=c;c.el.classList.add("panning");c.el.style.transition="";c.startingXPos=f._xPos(a);c.time=Date.now();c.xPos=f._xPos(a)}}},{key:"_onDragMove",value:function(a){if(f._draggedToast){a.preventDefault();var c=f._draggedToast;c.deltaX=Math.abs(c.xPos-f._xPos(a));c.xPos=f._xPos(a);c.velocityX= c.deltaX/(Date.now()-c.time);c.time=Date.now();a=c.xPos-c.startingXPos;var b=c.el.offsetWidth*c.options.activationPercent;c.el.style.transform="translateX("+a+"px)";c.el.style.opacity=1-Math.abs(a/b)}}},{key:"_onDragEnd",value:function(){if(f._draggedToast){var a=f._draggedToast;a.panning=!1;a.el.classList.remove("panning");Math.abs(a.xPos-a.startingXPos)>a.el.offsetWidth*a.options.activationPercent||1e.tickId&&e._enter();e.tickId=a._ticks}for(b=0;bb||xe||B"+g+""+d+""+f+"");b.length&&c.prepend(b)}},{key:"_resetCurrentElement",value:function(){this.activeIndex=-1;this.$active.removeClass("active")}},{key:"_resetAutocomplete",value:function(){d(this.container).empty();this._resetCurrentElement();this.oldVal=null;this._mousedown=this.isOpen=!1}},{key:"selectOption", value:function(a){a=a.text().trim();this.el.value=a;this.$el.trigger("change");this._resetAutocomplete();this.close();"function"===typeof this.options.onAutocomplete&&this.options.onAutocomplete.call(this,a)}},{key:"_renderDropdown",value:function(a,c){var b=this;this._resetAutocomplete();var e=[],f;for(f in a)if(a.hasOwnProperty(f)&&-1!==f.toLowerCase().indexOf(c)){if(this.count>=this.options.limit)break;e.push({data:a[f],key:f});this.count++}this.options.sortFunction&&e.sort(function(a,d){return b.options.sortFunction(a.key.toLowerCase(), d.key.toLowerCase(),c.toLowerCase())});for(f=0;f");g.data?h.append(''+g.key+""):h.append(""+g.key+"");d(this.container).append(h);this._highlight(c,h)}}},{key:"open",value:function(){var a=this.el.value.toLowerCase();this._resetAutocomplete();a.length>=this.options.minLength&&(this.isOpen=!0,this._renderDropdown(this.options.data,a));this.dropdown.isOpen?this.dropdown.recalculateDimensions(): this.dropdown.open()}},{key:"close",value:function(){this.dropdown.close()}},{key:"updateData",value:function(a){var c=this.el.value.toLowerCase();this.options.data=a;this.isOpen&&this._renderDropdown(a,c)}}],[{key:"init",value:function(a,c){return _get(f.__proto__||Object.getPrototypeOf(f),"init",this).call(this,this,a,c)}},{key:"getInstance",value:function(a){return(a.jquery?a[0]:a).M_Autocomplete}},{key:"defaults",get:function(){return g}}]);return f}(Component);h._keydown=!1;M.Autocomplete=h; M.jQueryLoaded&&M.initializeJqueryWrapper(h,"autocomplete","M_Autocomplete")})(cash); (function(d){M.updateTextFields=function(){d("input[type=text], input[type=password], input[type=email], input[type=url], input[type=tel], input[type=number], input[type=search], input[type=date], input[type=time], textarea").each(function(g,h){var k=d(this);0'),d("body").append(h));var k=g.css("font-family"),f=g.css("font-size"),a=g.css("line-height"),c=g.css("padding-top"),b=g.css("padding-right"),e=g.css("padding-bottom"),q=g.css("padding-left");f&&h.css("font-size",f);k&&h.css("font-family",k);a&&h.css("line-height",a);c&&h.css("padding-top",c);b&&h.css("padding-right",b);e&&h.css("padding-bottom",e);q&&h.css("padding-left",q);g.data("original-height")||g.data("original-height",g.height());"off"=== g.attr("wrap")&&h.css("overflow-wrap","normal").css("white-space","pre");h.text(g[0].value+"\n");k=h.html().replace(/\n/g,"
");h.html(k);0'),this.$slides.each(function(b,e){var f=d('
  • ');a.$indicators.append(f[0])}),this.$el.append(this.$indicators[0]), this.$indicators=this.$indicators.children("li.indicator-item"))}},{key:"_removeIndicators",value:function(){this.$el.find("ul.indicators").remove()}},{key:"set",value:function(a){var b=this;a>=this.$slides.length?a=0:0>a&&(a=this.$slides.length-1);if(this.activeIndex!=a){this.$active=this.$slides.eq(this.activeIndex);var d=this.$active.find(".caption");this.$active.removeClass("active");g({targets:this.$active[0],opacity:0,duration:this.options.duration,easing:"easeOutQuad",complete:function(){b.$slides.not(".active").each(function(a){g({targets:a, opacity:0,translateX:0,translateY:0,duration:0,easing:"easeOutQuad"})})}});this._animateCaptionIn(d[0],this.options.duration);this.options.indicators&&(this.$indicators.eq(this.activeIndex).removeClass("active"),this.$indicators.eq(a).addClass("active"));g({targets:this.$slides.eq(a)[0],opacity:1,duration:this.options.duration,easing:"easeOutQuad"});g({targets:this.$slides.eq(a).find(".caption")[0],opacity:1,translateX:0,translateY:0,duration:this.options.duration,delay:this.options.duration,easing:"easeOutQuad"}); this.$slides.eq(a).addClass("active");this.activeIndex=a;this.start()}}},{key:"pause",value:function(){clearInterval(this.interval)}},{key:"start",value:function(){clearInterval(this.interval);this.interval=setInterval(this._handleIntervalBound,this.options.duration+this.options.interval)}},{key:"next",value:function(){var a=this.activeIndex+1;a>=this.$slides.length?a=0:0>a&&(a=this.$slides.length-1);this.set(a)}},{key:"prev",value:function(){var a=this.activeIndex-1;a>=this.$slides.length?a=0:0> a&&(a=this.$slides.length-1);this.set(a)}}],[{key:"init",value:function(c,b){return _get(a.__proto__||Object.getPrototypeOf(a),"init",this).call(this,this,c,b)}},{key:"getInstance",value:function(a){return(a.jquery?a[0]:a).M_Slider}},{key:"defaults",get:function(){return h}}]);return a}(Component);M.Slider=k;M.jQueryLoaded&&M.initializeJqueryWrapper(k,"slider","M_Slider")})(cash,M.anime); (function(d,g){d(document).on("click",".card",function(h){if(d(this).children(".card-reveal").length){var k=d(h.target).closest(".card");void 0===k.data("initialOverflow")&&k.data("initialOverflow",void 0===k.css("overflow")?"":k.css("overflow"));var f=d(this).find(".card-reveal");if(d(h.target).is(d(".card-reveal .card-title"))||d(h.target).is(d(".card-reveal .card-title i")))g({targets:f[0],translateY:0,duration:225,easing:"easeInOutQuad",complete:function(a){d(a.animatables[0].target).css({display:"none"}); k.css("overflow",k.data("initialOverflow"))}});else if(d(h.target).is(d(".card .activator"))||d(h.target).is(d(".card .activator i")))k.css("overflow","hidden"),f.css({display:"block"}),g({targets:f[0],translateY:"-100%",duration:300,easing:"easeInOutQuad"})}})})(cash,M.anime); (function(d){var g={data:[],placeholder:"",secondaryPlaceholder:"",autocompleteOptions:{},limit:Infinity,onChipAdd:null,onChipSelect:null,onChipDelete:null},h=function(h){function f(a,c){_classCallCheck(this,f);var b=_possibleConstructorReturn(this,(f.__proto__||Object.getPrototypeOf(f)).call(this,f,a,c));b.el.M_Chips=b;b.options=d.extend({},f.defaults,c);b.$el.addClass("chips input-field");b.chipsData=[];b.$chips=d();b._setupInput();b.hasAutocomplete=0"),this.$el.append(this.$input));this.$input.addClass("input")}},{key:"_setupLabel",value:function(){this.$label=this.$el.find("label");this.$label.length&&this.$label.setAttribute("for", this.$input.attr("id"))}},{key:"_setPlaceholder",value:function(){void 0!==this.chipsData&&!this.chipsData.length&&this.options.placeholder?d(this.$input).prop("placeholder",this.options.placeholder):(void 0===this.chipsData||this.chipsData.length)&&this.options.secondaryPlaceholder&&d(this.$input).prop("placeholder",this.options.secondaryPlaceholder)}},{key:"_isValid",value:function(a){if(a.hasOwnProperty("tag")&&""!==a.tag){for(var c=!1,b=0;b=this.options.limit)){var c=this._renderChip(a);this.$chips.add(c);this.chipsData.push(a);d(this.$input).before(c);this._setPlaceholder();"function"===typeof this.options.onChipAdd&&this.options.onChipAdd.call(this,this.$el,c)}}},{key:"deleteChip",value:function(a){var c=this.$chips.eq(a);this.$chips.eq(a).remove();this.$chips=this.$chips.filter(function(a){return 0<=d(a).index()}); this.chipsData.splice(a,1);this._setPlaceholder();"function"===typeof this.options.onChipDelete&&this.options.onChipDelete.call(this,this.$el,c[0])}},{key:"selectChip",value:function(a){this._selectedChip=a=this.$chips.eq(a);a[0].focus();"function"===typeof this.options.onChipSelect&&this.options.onChipSelect.call(this,this.$el,a[0])}}],[{key:"init",value:function(a,c){return _get(f.__proto__||Object.getPrototypeOf(f),"init",this).call(this,this,a,c)}},{key:"getInstance",value:function(a){return(a.jquery? a[0]:a).M_Chips}},{key:"_handleChipsKeydown",value:function(a){f._keydown=!0;var c=d(a.target).closest(".chips"),b=a.target&&c.length;!d(a.target).is("input, textarea")&&b&&(c=c[0].M_Chips,8===a.keyCode||46===a.keyCode?(a.preventDefault(),a=c.chipsData.length,c._selectedChip&&(a=c._selectedChip.index(),c.deleteChip(a),c._selectedChip=null,a=Math.max(a-1,0)),c.chipsData.length&&c.selectChip(a)):37===a.keyCode?c._selectedChip&&(a=c._selectedChip.index()-1,0>a||c.selectChip(a)):39===a.keyCode&&c._selectedChip&& (a=c._selectedChip.index()+1,a>=c.chipsData.length?c.$input[0].focus():c.selectChip(a)))}},{key:"_handleChipsKeyup",value:function(a){f._keydown=!1}},{key:"_handleChipsBlur",value:function(a){f._keydown||(d(a.target).closest(".chips")[0].M_Chips._selectedChip=null)}},{key:"defaults",get:function(){return g}}]);return f}(Component);h._keydown=!1;M.Chips=h;M.jQueryLoaded&&M.initializeJqueryWrapper(h,"chips","M_Chips");d(document).ready(function(){d(document.body).on("click",".chip .close",function(){var g= d(this).closest(".chips");g.length&&g[0].M_Chips||d(this).closest(".chip").remove()})})})(cash); (function(d){var g={top:0,bottom:Infinity,offset:0,onPositionChange:null},h=function(h){function f(a,c){_classCallCheck(this,f);var b=_possibleConstructorReturn(this,(f.__proto__||Object.getPrototypeOf(f)).call(this,f,a,c));b.el.M_Pushpin=b;b.options=d.extend({},f.defaults,c);b.originalOffset=b.el.offsetTop;f._pushpins.push(b);b._setupEventHandlers();b._updatePosition();return b}_inherits(f,h);_createClass(f,[{key:"destroy",value:function(){this.el.style.top=null;this._removePinClasses();this._removeEventHandlers(); var a=f._pushpins.indexOf(this);f._pushpins.splice(a,1)}},{key:"_setupEventHandlers",value:function(){document.addEventListener("scroll",f._updateElements)}},{key:"_removeEventHandlers",value:function(){document.removeEventListener("scroll",f._updateElements)}},{key:"_updatePosition",value:function(){var a=M.getDocumentScrollTop()+this.options.offset;this.options.top<=a&&this.options.bottom>=a&&!this.el.classList.contains("pinned")&&(this._removePinClasses(),this.el.style.top=this.options.offset+ "px",this.el.classList.add("pinned"),"function"===typeof this.options.onPositionChange&&this.options.onPositionChange.call(this,"pinned"));athis.options.bottom&&!this.el.classList.contains("pin-bottom")&&(this._removePinClasses(),this.el.classList.add("pin-bottom"), this.el.style.top=this.options.bottom-this.originalOffset+"px","function"===typeof this.options.onPositionChange&&this.options.onPositionChange.call(this,"pin-bottom"))}},{key:"_removePinClasses",value:function(){this.el.classList.remove("pin-top");this.el.classList.remove("pinned");this.el.classList.remove("pin-bottom")}}],[{key:"init",value:function(a,c){return _get(f.__proto__||Object.getPrototypeOf(f),"init",this).call(this,this,a,c)}},{key:"getInstance",value:function(a){return(a.jquery?a[0]: a).M_Pushpin}},{key:"_updateElements",value:function(){for(var a in f._pushpins)f._pushpins[a]._updatePosition()}},{key:"defaults",get:function(){return g}}]);return f}(Component);h._pushpins=[];M.Pushpin=h;M.jQueryLoaded&&M.initializeJqueryWrapper(h,"pushpin","M_Pushpin")})(cash); (function(d,g){var h={direction:"top",hoverEnabled:!0,toolbarEnabled:!1};d.fn.reverse=[].reverse;var k=function(f){function a(c,b){_classCallCheck(this,a);var e=_possibleConstructorReturn(this,(a.__proto__||Object.getPrototypeOf(a)).call(this,a,c,b));e.el.M_FloatingActionButton=e;e.options=d.extend({},a.defaults,b);e.isOpen=!1;e.$anchor=e.$el.children("a").first();e.$menu=e.$el.children("ul").first();e.$floatingBtns=e.$el.find("ul .btn-floating");e.$floatingBtnsReverse=e.$el.find("ul .btn-floating").reverse(); e.offsetY=0;e.offsetX=0;e.$el.addClass("direction-"+e.options.direction);"top"===e.options.direction?e.offsetY=40:"right"===e.options.direction?e.offsetX=-40:"bottom"===e.options.direction?e.offsetY=-40:e.offsetX=40;e._setupEventHandlers();return e}_inherits(a,f);_createClass(a,[{key:"destroy",value:function(){this._removeEventHandlers();this.el.M_FloatingActionButton=void 0}},{key:"_setupEventHandlers",value:function(){this._handleFABClickBound=this._handleFABClick.bind(this);this._handleOpenBound= this.open.bind(this);this._handleCloseBound=this.close.bind(this);this.options.hoverEnabled&&!this.options.toolbarEnabled?(this.el.addEventListener("mouseenter",this._handleOpenBound),this.el.addEventListener("mouseleave",this._handleCloseBound)):this.el.addEventListener("click",this._handleFABClickBound)}},{key:"_removeEventHandlers",value:function(){this.options.hoverEnabled&&!this.options.toolbarEnabled?(this.el.removeEventListener("mouseenter",this._handleOpenBound),this.el.removeEventListener("mouseleave", this._handleCloseBound)):this.el.removeEventListener("click",this._handleFABClickBound)}},{key:"_handleFABClick",value:function(){this.isOpen?this.close():this.open()}},{key:"_handleDocumentClick",value:function(a){d(a.target).closest(this.$menu).length||this.close()}},{key:"open",value:function(){this.isOpen||(this.options.toolbarEnabled?this._animateInToolbar():this._animateInFAB(),this.isOpen=!0)}},{key:"close",value:function(){this.isOpen&&(this.options.toolbarEnabled?(window.removeEventListener("scroll", this._handleCloseBound,!0),document.body.removeEventListener("click",this._handleDocumentClickBound,!0),this._animateOutToolbar()):this._animateOutFAB(),this.isOpen=!1)}},{key:"_animateInFAB",value:function(){var a=this;this.$el.addClass("active");var b=0;this.$floatingBtnsReverse.each(function(d){g({targets:d,opacity:1,scale:[.4,1],translateY:[a.offsetY,0],translateX:[a.offsetX,0],duration:275,delay:b,easing:"easeInOutQuad"});b+=40})}},{key:"_animateOutFAB",value:function(){var a=this;this.$floatingBtnsReverse.each(function(b){g.remove(b); g({targets:b,opacity:0,scale:.4,translateY:a.offsetY,translateX:a.offsetX,duration:175,easing:"easeOutQuad",complete:function(){a.$el.removeClass("active")}})})}},{key:"_animateInToolbar",value:function(){var a=this,b=void 0,e=window.innerWidth,f=window.innerHeight,g=this.el.getBoundingClientRect(),h=d('
    '),k=this.$anchor.css("background-color");this.$anchor.append(h);this.offsetX=g.left-e/2+g.width/2;this.offsetY=f-g.bottom;b=e/h[0].clientWidth;this.btnBottom=g.bottom; this.btnLeft=g.left;this.btnWidth=g.width;this.$el.addClass("active");this.$el.css({"text-align":"center",width:"100%",bottom:0,left:0,transform:"translateX("+this.offsetX+"px)",transition:"none"});this.$anchor.css({transform:"translateY("+-this.offsetY+"px)",transition:"none"});h.css({"background-color":k});setTimeout(function(){a.$el.css({transform:"",transition:"transform .2s cubic-bezier(0.550, 0.085, 0.680, 0.530), background-color 0s linear .2s"});a.$anchor.css({overflow:"visible",transform:"", transition:"transform .2s"});setTimeout(function(){a.$el.css({overflow:"hidden","background-color":k});h.css({transform:"scale("+b+")",transition:"transform .2s cubic-bezier(0.550, 0.055, 0.675, 0.190)"});a.$menu.children("li").children("a").css({opacity:1});a._handleDocumentClickBound=a._handleDocumentClick.bind(a);window.addEventListener("scroll",a._handleCloseBound,!0);document.body.addEventListener("click",a._handleDocumentClickBound,!0)},100)},0)}},{key:"_animateOutToolbar",value:function(){var a= this,b=window.innerWidth,d=window.innerHeight,f=this.$el.find(".fab-backdrop"),g=this.$anchor.css("background-color");this.offsetX=this.btnLeft-b/2+this.btnWidth/2;this.offsetY=d-this.btnBottom;this.$el.removeClass("active");this.$el.css({"background-color":"transparent",transition:"none"});this.$anchor.css({transition:"none"});f.css({transform:"scale(0)","background-color":g});this.$menu.children("li").children("a").css({opacity:""});setTimeout(function(){f.remove();a.$el.css({"text-align":"",width:"", bottom:"",left:"",overflow:"","background-color":"",transform:"translate3d("+-a.offsetX+"px,0,0)"});a.$anchor.css({overflow:"",transform:"translate3d(0,"+a.offsetY+"px,0)"});setTimeout(function(){a.$el.css({transform:"translate3d(0,0,0)",transition:"transform .2s"});a.$anchor.css({transform:"translate3d(0,0,0)",transition:"transform .2s cubic-bezier(0.550, 0.055, 0.675, 0.190)"})},20)},200)}}],[{key:"init",value:function(c,b){return _get(a.__proto__||Object.getPrototypeOf(a),"init",this).call(this, this,c,b)}},{key:"getInstance",value:function(a){return(a.jquery?a[0]:a).M_FloatingActionButton}},{key:"defaults",get:function(){return h}}]);return a}(Component);M.FloatingActionButton=k;M.jQueryLoaded&&M.initializeJqueryWrapper(k,"floatingActionButton","M_FloatingActionButton")})(cash,M.anime); (function(d){var g={autoClose:!1,format:"mmm dd, yyyy",parse:null,defaultDate:null,setDefaultDate:!1,disableWeekends:!1,disableDayFn:null,firstDay:0,minDate:null,maxDate:null,yearRange:10,minYear:0,maxYear:9999,minMonth:void 0,maxMonth:void 0,startRange:null,endRange:null,isRTL:!1,showMonthAfterYear:!1,showDaysInNextAndPreviousMonths:!1,container:null,showClearBtn:!1,i18n:{cancel:"Cancel",clear:"Clear",done:"Ok",previousMonth:"\u2039",nextMonth:"\u203a",months:"January February March April May June July August September October November December".split(" "), monthsShort:"Jan Feb Mar Apr May Jun Jul Aug Sep Oct Nov Dec".split(" "),weekdays:"Sunday Monday Tuesday Wednesday Thursday Friday Saturday".split(" "),weekdaysShort:"Sun Mon Tue Wed Thu Fri Sat".split(" "),weekdaysAbbrev:"SMTWTFS".split("")},events:[],onSelect:null,onOpen:null,onClose:null,onDraw:null},h=function(h){function f(a,c){_classCallCheck(this,f);var b=_possibleConstructorReturn(this,(f.__proto__||Object.getPrototypeOf(f)).call(this,f,a,c));b.el.M_Datepicker=b;b.options=d.extend({},f.defaults, c);c&&c.hasOwnProperty("i18n")&&"object"===typeof c.i18n&&(b.options.i18n=d.extend({},f.defaults.i18n,c.i18n));b.options.minDate&&b.options.minDate.setHours(0,0,0,0);b.options.maxDate&&b.options.maxDate.setHours(0,0,0,0);b.id=M.guid();b._setupVariables();b._insertHTMLIntoDOM();b._setupModal();b._setupEventHandlers();b.options.defaultDate||(b.options.defaultDate=new Date(Date.parse(b.el.value)));var e=b.options.defaultDate;f._isDate(e)?b.options.setDefaultDate?(b.setDate(e,!0),b.setInputValue()):b.gotoDate(e): b.gotoDate(new Date);b.isOpen=!1;return b}_inherits(f,h);_createClass(f,[{key:"destroy",value:function(){this._removeEventHandlers();this.modal.destroy();d(this.modalEl).remove();this.destroySelects();this.el.M_Datepicker=void 0}},{key:"destroySelects",value:function(){var a=this.calendarEl.querySelector(".orig-select-year");a&&M.FormSelect.getInstance(a).destroy();(a=this.calendarEl.querySelector(".orig-select-month"))&&M.FormSelect.getInstance(a).destroy()}},{key:"_insertHTMLIntoDOM",value:function(){this.options.showClearBtn&& (d(this.clearBtn).css({visibility:""}),this.clearBtn.innerHTML=this.options.i18n.clear);this.doneBtn.innerHTML=this.options.i18n.done;this.cancelBtn.innerHTML=this.options.i18n.cancel;this.options.container?this.$modalEl.appendTo(this.options.container):this.$modalEl.insertBefore(this.el)}},{key:"_setupModal",value:function(){var a=this;this.modalEl.id="modal-"+this.id;this.modal=M.Modal.init(this.modalEl,{onCloseEnd:function(){a.isOpen=!1}})}},{key:"toString",value:function(a){var c=this;a=a||this.options.format; return f._isDate(this.date)?a.split(/(d{1,4}|m{1,4}|y{4}|yy|!.)/g).map(function(a){return c.formats[a]?c.formats[a]():a}).join(""):""}},{key:"setDate",value:function(a,c){if(!a)return this.date=null,this._renderDateDisplay(),this.draw();"string"===typeof a&&(a=new Date(Date.parse(a)));if(f._isDate(a)){var b=this.options.minDate,d=this.options.maxDate;f._isDate(b)&&ad&&(a=d);this.date=new Date(a.getTime());this._renderDateDisplay();f._setToStartOfDay(this.date);this.gotoDate(this.date); c||"function"!==typeof this.options.onSelect||this.options.onSelect.call(this,this.date)}}},{key:"setInputValue",value:function(){this.el.value=this.toString();this.$el.trigger("change",{firedBy:this})}},{key:"_renderDateDisplay",value:function(){var a=f._isDate(this.date)?this.date:new Date,c=this.options.i18n,b=c.weekdaysShort[a.getDay()],c=c.monthsShort[a.getMonth()],d=a.getDate();this.yearTextEl.innerHTML=a.getFullYear();this.dateTextEl.innerHTML=b+", "+c+" "+d}},{key:"gotoDate",value:function(a){var c= !0;if(f._isDate(a)){if(this.calendars){var c=new Date(this.calendars[0].year,this.calendars[0].month,1),b=new Date(this.calendars[this.calendars.length-1].year,this.calendars[this.calendars.length-1].month,1),d=a.getTime();b.setMonth(b.getMonth()+1);b.setDate(b.getDate()-1);c=da.month&&(a.year-=Math.ceil(Math.abs(a.month)/12),a.month+=12);11k&&(k+=7));for(var l=0===c?11:c-1,w=11===c?0:c+1,x=0===c?a-1:a,B=11===c?a+1:a,C=f._getDaysInMonth(x,l),I=h+k,F=I;7=h+k,N=1+(E-k),L=c,A=a,S=d.startRange&&f._compareDates(d.startRange,t),z=d.endRange&&f._compareDates(d.endRange,t),T=d.startRange&&d.endRange&&d.startRange< t&&td.maxDate||d.disableWeekends&&f._isWeekend(t)||d.disableDayFn&&d.disableDayFn(t);Q&&(E';a.isDisabled&&c.push("is-disabled");a.isToday&&c.push("is-today");a.isSelected&&(c.push("is-selected"),b="true");a.hasEvent&&c.push("has-event");a.isInRange&&c.push("is-inrange");a.isStartRange&&c.push("is-startrange");a.isEndRange&&c.push("is-endrange");return''+ ('")+""}},{key:"renderRow",value:function(a,c,b){return''+(c?a.reverse():a).join("")+""}},{key:"renderTable",value:function(a,c,b){return'
    '+this.renderHead(a)+this.renderBody(c)+ "
    "}},{key:"renderHead",value:function(a){for(var c=void 0,b=[],c=0;7>c;c++)b.push(''+this.renderDayName(a,c,!0)+"");return""+(a.isRTL?b.reverse():b).join("")+""}},{key:"renderBody",value:function(a){return""+a.join("")+""}},{key:"renderTitle",value:function(a,c,b,e,f,g){var h=void 0,k=void 0,n=void 0;a=this.options;var k=b===a.minYear,l=b===a.maxYear;g='
    '; for(var w=void 0,h=void 0,x=!0,n=[],h=0;12>h;h++)n.push('");w='";d.isArray(a.yearRange)?(h=a.yearRange[0],k=a.yearRange[1]+1):(h=b-a.yearRange,k=1+b+a.yearRange);for(n=[];h=a.minYear&&n.push('");h='";g+='
    ';g=a.showMonthAfterYear?g+(h+w):g+(w+h);g+="
    ";l&&(11===e||a.maxMonth<=e)&&(x=!1);g+='';return g+"
    "}},{key:"draw",value:function(a){if(this.isOpen||a){var c=this.options;a=c.minYear;var b=c.maxYear,d=c.minMonth,f=c.maxMonth,c="",g=void 0;this._y<=a&&(this._y=a,!isNaN(d)&&this._m=b&&(this._y=b,!isNaN(f)&& this._m>f&&(this._m=f));g="datepicker-title-"+Math.random().toString(36).replace(/[^a-z]+/g,"").substr(0,2);for(a=0;1>a;a++)this._renderDateDisplay(),c+=this.renderTitle(this,a,this.calendars[a].year,this.calendars[a].month,this.calendars[0].year,g)+this.render(this.calendars[a].year,this.calendars[a].month,g);this.destroySelects();this.calendarEl.innerHTML=c;a=this.calendarEl.querySelector(".orig-select-year");b=this.calendarEl.querySelector(".orig-select-month");M.FormSelect.init(a,{classes:"select-year", dropdownOptions:{container:document.body,constrainWidth:!1}});M.FormSelect.init(b,{classes:"select-month",dropdownOptions:{container:document.body,constrainWidth:!1}});a.addEventListener("change",this._handleYearChange.bind(this));b.addEventListener("change",this._handleMonthChange.bind(this));if("function"===typeof this.options.onDraw)this.options.onDraw(this)}}},{key:"_setupEventHandlers",value:function(){this._handleInputKeydownBound=this._handleInputKeydown.bind(this);this._handleInputClickBound= this._handleInputClick.bind(this);this._handleInputChangeBound=this._handleInputChange.bind(this);this._handleCalendarClickBound=this._handleCalendarClick.bind(this);this._finishSelectionBound=this._finishSelection.bind(this);this._handleMonthChange=this._handleMonthChange.bind(this);this._closeBound=this.close.bind(this);this.el.addEventListener("click",this._handleInputClickBound);this.el.addEventListener("keydown",this._handleInputKeydownBound);this.el.addEventListener("change",this._handleInputChangeBound); this.calendarEl.addEventListener("click",this._handleCalendarClickBound);this.doneBtn.addEventListener("click",this._finishSelectionBound);this.cancelBtn.addEventListener("click",this._closeBound);this.options.showClearBtn&&(this._handleClearClickBound=this._handleClearClick.bind(this),this.clearBtn.addEventListener("click",this._handleClearClickBound))}},{key:"_setupVariables",value:function(){var a=this;this.$modalEl=d(f._template);this.modalEl=this.$modalEl[0];this.calendarEl=this.modalEl.querySelector(".datepicker-calendar"); this.yearTextEl=this.modalEl.querySelector(".year-text");this.dateTextEl=this.modalEl.querySelector(".date-text");this.options.showClearBtn&&(this.clearBtn=this.modalEl.querySelector(".datepicker-clear"));this.doneBtn=this.modalEl.querySelector(".datepicker-done");this.cancelBtn=this.modalEl.querySelector(".datepicker-cancel");this.formats={d:function(){return a.date.getDate()},dd:function(){var c=a.date.getDate();return(10>c?"0":"")+c},ddd:function(){return a.options.i18n.weekdaysShort[a.date.getDay()]}, dddd:function(){return a.options.i18n.weekdays[a.date.getDay()]},m:function(){return a.date.getMonth()+1},mm:function(){var c=a.date.getMonth()+1;return(10>c?"0":"")+c},mmm:function(){return a.options.i18n.monthsShort[a.date.getMonth()]},mmmm:function(){return a.options.i18n.months[a.date.getMonth()]},yy:function(){return(""+a.date.getFullYear()).slice(2)},yyyy:function(){return a.date.getFullYear()}}}},{key:"_removeEventHandlers",value:function(){this.el.removeEventListener("click",this._handleInputClickBound); this.el.removeEventListener("keydown",this._handleInputKeydownBound);this.el.removeEventListener("change",this._handleInputChangeBound);this.calendarEl.removeEventListener("click",this._handleCalendarClickBound)}},{key:"_handleInputClick",value:function(){this.open()}},{key:"_handleInputKeydown",value:function(a){a.which===M.keys.ENTER&&(a.preventDefault(),this.open())}},{key:"_handleCalendarClick",value:function(a){if(this.isOpen){var c=d(a.target);c.hasClass("is-disabled")||(!c.hasClass("datepicker-day-button")|| c.hasClass("is-empty")||c.parent().hasClass("is-disabled")?c.closest(".month-prev").length?this.prevMonth():c.closest(".month-next").length&&this.nextMonth():(this.setDate(new Date(a.target.getAttribute("data-year"),a.target.getAttribute("data-month"),a.target.getAttribute("data-day"))),this.options.autoClose&&this._finishSelection()))}}},{key:"_handleClearClick",value:function(){this.date=null;this.setInputValue();this.close()}},{key:"_handleMonthChange",value:function(a){this.gotoMonth(a.target.value)}}, {key:"_handleYearChange",value:function(a){this.gotoYear(a.target.value)}},{key:"gotoMonth",value:function(a){isNaN(a)||(this.calendars[0].month=parseInt(a,10),this.adjustCalendars())}},{key:"gotoYear",value:function(a){isNaN(a)||(this.calendars[0].year=parseInt(a,10),this.adjustCalendars())}},{key:"_handleInputChange",value:function(a){var c=void 0;a.firedBy!==this&&(c=this.options.parse?this.options.parse(this.el.value,this.options.format):new Date(Date.parse(this.el.value)),f._isDate(c)&&this.setDate(c))}}, {key:"renderDayName",value:function(a,c,b){for(c+=a.firstDay;7<=c;)c-=7;return b?a.i18n.weekdaysAbbrev[c]:a.i18n.weekdays[c]}},{key:"_finishSelection",value:function(){this.setInputValue();this.close()}},{key:"open",value:function(){if(!this.isOpen)return this.isOpen=!0,"function"===typeof this.options.onOpen&&this.options.onOpen.call(this),this.draw(),this.modal.open(),this}},{key:"close",value:function(){if(this.isOpen)return this.isOpen=!1,"function"===typeof this.options.onClose&&this.options.onClose.call(this), this.modal.close(),this}}],[{key:"init",value:function(a,c){return _get(f.__proto__||Object.getPrototypeOf(f),"init",this).call(this,this,a,c)}},{key:"_isDate",value:function(a){return/Date/.test(Object.prototype.toString.call(a))&&!isNaN(a.getTime())}},{key:"_isWeekend",value:function(a){a=a.getDay();return 0===a||6===a}},{key:"_setToStartOfDay",value:function(a){f._isDate(a)&&a.setHours(0,0,0,0)}},{key:"_getDaysInMonth",value:function(a,c){return[31,f._isLeapYear(a)?29:28,31,30,31,30,31,31,30,31, 30,31][c]}},{key:"_isLeapYear",value:function(a){return 0===a%4&&0!==a%100||0===a%400}},{key:"_compareDates",value:function(a,c){return a.getTime()===c.getTime()}},{key:"_setToStartOfDay",value:function(a){f._isDate(a)&&a.setHours(0,0,0,0)}},{key:"getInstance",value:function(a){return(a.jquery?a[0]:a).M_Datepicker}},{key:"defaults",get:function(){return g}}]);return f}(Component);h._template=''; M.Datepicker=h;M.jQueryLoaded&&M.initializeJqueryWrapper(h,"datepicker","M_Datepicker")})(cash); (function(d){var g={dialRadius:135,outerRadius:105,innerRadius:70,tickRadius:20,duration:350,container:null,defaultTime:"now",fromNow:0,showClearBtn:!1,i18n:{cancel:"Cancel",clear:"Clear",done:"Ok"},autoClose:!1,twelveHour:!0,vibrate:!0,onOpenStart:null,onOpenEnd:null,onCloseStart:null,onCloseEnd:null,onSelect:null},h=function(h){function f(a,c){_classCallCheck(this,f);var b=_possibleConstructorReturn(this,(f.__proto__||Object.getPrototypeOf(f)).call(this,f,a,c));b.el.M_Timepicker=b;b.options=d.extend({}, f.defaults,c);b.id=M.guid();b._insertHTMLIntoDOM();b._setupModal();b._setupVariables();b._setupEventHandlers();b._clockSetup();b._pickerSetup();return b}_inherits(f,h);_createClass(f,[{key:"destroy",value:function(){this._removeEventHandlers();this.modal.destroy();d(this.modalEl).remove();this.el.M_Timepicker=void 0}},{key:"_setupEventHandlers",value:function(){this._handleInputKeydownBound=this._handleInputKeydown.bind(this);this._handleInputClickBound=this._handleInputClick.bind(this);this._handleClockClickStartBound= this._handleClockClickStart.bind(this);this._handleDocumentClickMoveBound=this._handleDocumentClickMove.bind(this);this._handleDocumentClickEndBound=this._handleDocumentClickEnd.bind(this);this.el.addEventListener("click",this._handleInputClickBound);this.el.addEventListener("keydown",this._handleInputKeydownBound);this.plate.addEventListener("mousedown",this._handleClockClickStartBound);this.plate.addEventListener("touchstart",this._handleClockClickStartBound);d(this.spanHours).on("click",this.showView.bind(this, "hours"));d(this.spanMinutes).on("click",this.showView.bind(this,"minutes"))}},{key:"_removeEventHandlers",value:function(){this.el.removeEventListener("click",this._handleInputClickBound);this.el.removeEventListener("keydown",this._handleInputKeydownBound)}},{key:"_handleInputClick",value:function(){this.open()}},{key:"_handleInputKeydown",value:function(a){a.which===M.keys.ENTER&&(a.preventDefault(),this.open())}},{key:"_handleClockClickStart",value:function(a){a.preventDefault();var c=this.plate.getBoundingClientRect(), b=c.top;this.x0=c.left+this.options.dialRadius;this.y0=b+this.options.dialRadius;this.moved=!1;a=f._Pos(a);this.dx=a.x-this.x0;this.dy=a.y-this.y0;this.setHand(this.dx,this.dy,!1);document.addEventListener("mousemove",this._handleDocumentClickMoveBound);document.addEventListener("touchmove",this._handleDocumentClickMoveBound);document.addEventListener("mouseup",this._handleDocumentClickEndBound);document.addEventListener("touchend",this._handleDocumentClickEndBound)}},{key:"_handleDocumentClickMove", value:function(a){a.preventDefault();var c=f._Pos(a);a=c.x-this.x0;c=c.y-this.y0;this.moved=!0;this.setHand(a,c,!1,!0)}},{key:"_handleDocumentClickEnd",value:function(a){var c=this;a.preventDefault();document.removeEventListener("mouseup",this._handleDocumentClickEndBound);document.removeEventListener("touchend",this._handleDocumentClickEndBound);var b=f._Pos(a);a=b.x-this.x0;b=b.y-this.y0;this.moved&&a===this.dx&&b===this.dy&&this.setHand(a,b);"hours"===this.currentView?this.showView("minutes",this.options.duration/ 2):this.options.autoClose&&(d(this.minutesView).addClass("timepicker-dial-out"),setTimeout(function(){c.done()},this.options.duration/2));"function"===typeof this.options.onSelect&&this.options.onSelect.call(this,this.hours,this.minutes);document.removeEventListener("mousemove",this._handleDocumentClickMoveBound);document.removeEventListener("touchmove",this._handleDocumentClickMoveBound)}},{key:"_insertHTMLIntoDOM",value:function(){this.$modalEl=d(f._template);this.modalEl=this.$modalEl[0];this.modalEl.id= "modal-"+this.id;var a=document.querySelector(this.options.container);this.options.container&&a?this.$modalEl.appendTo(a):this.$modalEl.insertBefore(this.el)}},{key:"_setupModal",value:function(){var a=this;this.modal=M.Modal.init(this.modalEl,{onOpenStart:this.options.onOpenStart,onOpenEnd:this.options.onOpenEnd,onCloseStart:this.options.onCloseStart,onCloseEnd:function(){"function"===typeof a.options.onCloseEnd&&a.options.onCloseEnd.call(a);a.isOpen=!1}})}},{key:"_setupVariables",value:function(){this.currentView= "hours";this.vibrate=navigator.vibrate?"vibrate":navigator.webkitVibrate?"webkitVibrate":null;this._canvas=this.modalEl.querySelector(".timepicker-canvas");this.plate=this.modalEl.querySelector(".timepicker-plate");this.hoursView=this.modalEl.querySelector(".timepicker-hours");this.minutesView=this.modalEl.querySelector(".timepicker-minutes");this.spanHours=this.modalEl.querySelector(".timepicker-span-hours");this.spanMinutes=this.modalEl.querySelector(".timepicker-span-minutes");this.spanAmPm=this.modalEl.querySelector(".timepicker-span-am-pm"); this.footer=this.modalEl.querySelector(".timepicker-footer");this.amOrPm="PM"}},{key:"_pickerSetup",value:function(){var a=d('").appendTo(this.footer).on("click",this.clear.bind(this));this.options.showClearBtn&&a.css({visibility:""});a=d('
    ');d('").appendTo(a).on("click",this.close.bind(this));d('").appendTo(a).on("click",this.done.bind(this));a.appendTo(this.footer)}},{key:"_clockSetup",value:function(){this.options.twelveHour&&(this.$amBtn=d('
    AM
    '),this.$pmBtn=d('
    PM
    '), this.$amBtn.on("click",this._handleAmPmClick.bind(this)).appendTo(this.spanAmPm),this.$pmBtn.on("click",this._handleAmPmClick.bind(this)).appendTo(this.spanAmPm));this._buildHoursView();this._buildMinutesView();this._buildSVGClock()}},{key:"_buildSVGClock",value:function(){var a=this.options.dialRadius,c=this.options.tickRadius,b=2*a,d=f._createSVGEl("svg");d.setAttribute("class","timepicker-svg");d.setAttribute("width",b);d.setAttribute("height",b);b=f._createSVGEl("g");b.setAttribute("transform", "translate("+a+","+a+")");a=f._createSVGEl("circle");a.setAttribute("class","timepicker-canvas-bearing");a.setAttribute("cx",0);a.setAttribute("cy",0);a.setAttribute("r",4);var g=f._createSVGEl("line");g.setAttribute("x1",0);g.setAttribute("y1",0);var h=f._createSVGEl("circle");h.setAttribute("class","timepicker-canvas-bg");h.setAttribute("r",c);b.appendChild(g);b.appendChild(h);b.appendChild(a);d.appendChild(b);this._canvas.appendChild(d);this.hand=g;this.bg=h;this.bearing=a;this.g=b}},{key:"_buildHoursView", value:function(){var a=d('
    ');if(this.options.twelveHour)for(var c=1;13>c;c+=1){var b=a.clone(),e=c/6*Math.PI,f=this.options.outerRadius;b.css({left:this.options.dialRadius+Math.sin(e)*f-this.options.tickRadius+"px",top:this.options.dialRadius-Math.cos(e)*f-this.options.tickRadius+"px"});b.html(0===c?"00":c);this.hoursView.appendChild(b[0])}else for(c=0;24>c;c+=1)b=a.clone(),e=c/6*Math.PI,f=0c?this.options.innerRadius:this.options.outerRadius,b.css({left:this.options.dialRadius+ Math.sin(e)*f-this.options.tickRadius+"px",top:this.options.dialRadius-Math.cos(e)*f-this.options.tickRadius+"px"}),b.html(0===c?"00":c),this.hoursView.appendChild(b[0])}},{key:"_buildMinutesView",value:function(){for(var a=d('
    '),c=0;60>c;c+=5){var b=a.clone(),e=c/30*Math.PI;b.css({left:this.options.dialRadius+Math.sin(e)*this.options.outerRadius-this.options.tickRadius+"px",top:this.options.dialRadius-Math.cos(e)*this.options.outerRadius-this.options.tickRadius+ "px"});b.html(f._addLeadingZero(c));this.minutesView.appendChild(b[0])}}},{key:"_handleAmPmClick",value:function(a){this.amOrPm=d(a.target).hasClass("am-btn")?"AM":"PM";this._updateAmPmView()}},{key:"_updateAmPmView",value:function(){this.options.twelveHour&&(this.$amBtn.toggleClass("text-primary","AM"===this.amOrPm),this.$pmBtn.toggleClass("text-primary","PM"===this.amOrPm))}},{key:"_updateTimeFromInput",value:function(){var a=((this.el.value||this.options.defaultTime||"")+"").split(":");this.options.twelveHour&& "undefined"!==typeof a[1]&&(0a[0]?"PM":"AM"));this.hours=+a[0]||0;this.minutes=+a[1]||0;this.spanHours.innerHTML=this.hours;this.spanMinutes.innerHTML=f._addLeadingZero(this.minutes);this._updateAmPmView()}},{key:"showView",value:function(a,c){"minutes"=== a&&d(this.hoursView).css("visibility");var b="hours"===a,e=b?this.hoursView:this.minutesView,f=b?this.minutesView:this.hoursView;this.currentView=a;d(this.spanHours).toggleClass("text-primary",b);d(this.spanMinutes).toggleClass("text-primary",!b);f.classList.add("timepicker-dial-out");d(e).css("visibility","visible").removeClass("timepicker-dial-out");this.resetClock(c);clearTimeout(this.toggleViewTimer);this.toggleViewTimer=setTimeout(function(){d(f).css("visibility","hidden")},this.options.duration)}}, {key:"resetClock",value:function(a){var c=this.currentView,b=this[c],e="hours"===c,c=Math.PI/(e?6:30)*b,b=e&&0b?this.options.innerRadius:this.options.outerRadius,f=Math.sin(c)*b,g=-Math.cos(c)*b,h=this;a?(d(this.canvas).addClass("timepicker-canvas-out"),setTimeout(function(){d(h.canvas).removeClass("timepicker-canvas-out");h.setHand(f,g)},a)):this.setHand(f,g)}},{key:"setHand",value:function(a,c,b){var d=this,g=Math.atan2(a,-c),h="hours"===this.currentView,k=Math.PI/(h||b?6:30);a=Math.sqrt(a* a+c*c);a=(c=h&&a<(this.options.outerRadius+this.options.innerRadius)/2)?this.options.innerRadius:this.options.outerRadius;this.options.twelveHour&&(a=this.options.outerRadius);0>g&&(g=2*Math.PI+g);var r=Math.round(g/k),g=r*k;this.options.twelveHour?h?0===r&&(r=12):(b&&(r*=5),60===r&&(r=0)):h?(12===r&&(r=0),r=c?0===r?12:r:0===r?0:r+12):(b&&(r*=5),60===r&&(r=0));this[this.currentView]!==r&&this.vibrate&&this.options.vibrate&&!this.vibrateTimer&&(navigator[this.vibrate](10),this.vibrateTimer=setTimeout(function(){d.vibrateTimer= null},100));this[this.currentView]=r;h?this.spanHours.innerHTML=r:this.spanMinutes.innerHTML=f._addLeadingZero(r);b=-Math.cos(g)*(a-this.options.tickRadius);h=Math.sin(g)*a;k=-Math.cos(g)*a;this.hand.setAttribute("x2",Math.sin(g)*(a-this.options.tickRadius));this.hand.setAttribute("y2",b);this.bg.setAttribute("cx",h);this.bg.setAttribute("cy",k)}},{key:"open",value:function(){this.isOpen||(this.isOpen=!0,this._updateTimeFromInput(),this.showView("hours"),this.modal.open())}},{key:"close",value:function(){this.isOpen&& (this.isOpen=!1,this.modal.close())}},{key:"done",value:function(a,c){var b=this.el.value,d=c?"":f._addLeadingZero(this.hours)+":"+f._addLeadingZero(this.minutes);this.time=d;!c&&this.options.twelveHour&&(d=d+" "+this.amOrPm);this.el.value=d;d!==b&&this.$el.trigger("change");this.close();this.el.focus()}},{key:"clear",value:function(){this.done(null,!0)}}],[{key:"init",value:function(a,c){return _get(f.__proto__||Object.getPrototypeOf(f),"init",this).call(this,this,a,c)}},{key:"_addLeadingZero",value:function(a){return(10> a?"0":"")+a}},{key:"_createSVGEl",value:function(a){return document.createElementNS("http://www.w3.org/2000/svg",a)}},{key:"_Pos",value:function(a){return a.targetTouches&&1<=a.targetTouches.length?{x:a.targetTouches[0].clientX,y:a.targetTouches[0].clientY}:{x:a.clientX,y:a.clientY}}},{key:"getInstance",value:function(a){return(a.jquery?a[0]:a).M_Timepicker}},{key:"defaults",get:function(){return g}}]);return f}(Component);h._template=''; M.Timepicker=h;M.jQueryLoaded&&M.initializeJqueryWrapper(h,"timepicker","M_Timepicker")})(cash); (function(d){var g={},h=function(h){function f(a,c){_classCallCheck(this,f);var b=_possibleConstructorReturn(this,(f.__proto__||Object.getPrototypeOf(f)).call(this,f,a,c));b.el.M_CharacterCounter=b;b.options=d.extend({},f.defaults,c);b.isInvalid=!1;b.isValidLength=!1;b._setupCounter();b._setupEventHandlers();return b}_inherits(f,h);_createClass(f,[{key:"destroy",value:function(){this._removeEventHandlers();this.el.CharacterCounter=void 0;this._removeCounter()}},{key:"_setupEventHandlers",value:function(){this._handleUpdateCounterBound= this.updateCounter.bind(this);this.el.addEventListener("focus",this._handleUpdateCounterBound,!0);this.el.addEventListener("input",this._handleUpdateCounterBound,!0)}},{key:"_removeEventHandlers",value:function(){this.el.removeEventListener("focus",this._handleUpdateCounterBound,!0);this.el.removeEventListener("input",this._handleUpdateCounterBound,!0)}},{key:"_setupCounter",value:function(){this.counterEl=document.createElement("span");d(this.counterEl).addClass("character-counter").css({"float":"right", "font-size":"12px",height:1});this.$el.parent().append(this.counterEl)}},{key:"_removeCounter",value:function(){d(this.counterEl).remove()}},{key:"updateCounter",value:function(){var a=+this.$el.attr("data-length"),c=this.el.value.length;this.isValidLength=c<=a;a&&(c+="/"+a,this._validateInput());d(this.counterEl).html(c)}},{key:"_validateInput",value:function(){this.isValidLength&&this.isInvalid?(this.isInvalid=!1,this.$el.removeClass("invalid")):this.isValidLength||this.isInvalid||(this.isInvalid= !0,this.$el.removeClass("valid"),this.$el.addClass("invalid"))}}],[{key:"init",value:function(a,c){return _get(f.__proto__||Object.getPrototypeOf(f),"init",this).call(this,this,a,c)}},{key:"getInstance",value:function(a){return(a.jquery?a[0]:a).M_CharacterCounter}},{key:"defaults",get:function(){return g}}]);return f}(Component);M.CharacterCounter=h;M.jQueryLoaded&&M.initializeJqueryWrapper(h,"characterCounter","M_CharacterCounter")})(cash); (function(d){var g={duration:200,dist:-100,shift:0,padding:0,numVisible:5,fullWidth:!1,indicators:!1,noWrap:!1,onCycleTo:null},h=function(h){function f(a,c){_classCallCheck(this,f);var b=_possibleConstructorReturn(this,(f.__proto__||Object.getPrototypeOf(f)).call(this,f,a,c));b.el.M_Carousel=b;b.options=d.extend({},f.defaults,c);b.hasMultipleSlides=1');b.$el.find(".carousel-item").each(function(a, c){b.images.push(a);if(b.showIndicators){var f=d('
  • ');0===c&&f[0].classList.add("active");b.$indicators.append(f)}});b.showIndicators&&b.$el.append(b.$indicators);b.count=b.images.length;b.options.numVisible=Math.min(b.count,b.options.numVisible);b.xform="transform";["webkit","Moz","O","ms"].every(function(a){a+="Transform";return"undefined"!==typeof document.body.style[a]?(b.xform=a,!1):!0});b._setupEventHandlers();b._scroll(b.offset);return b}_inherits(f,h);_createClass(f, [{key:"destroy",value:function(){this._removeEventHandlers();this.el.M_Carousel=void 0}},{key:"_setupEventHandlers",value:function(){var a=this;this._handleCarouselTapBound=this._handleCarouselTap.bind(this);this._handleCarouselDragBound=this._handleCarouselDrag.bind(this);this._handleCarouselReleaseBound=this._handleCarouselRelease.bind(this);this._handleCarouselClickBound=this._handleCarouselClick.bind(this);"undefined"!==typeof window.ontouchstart&&(this.el.addEventListener("touchstart",this._handleCarouselTapBound), this.el.addEventListener("touchmove",this._handleCarouselDragBound),this.el.addEventListener("touchend",this._handleCarouselReleaseBound));this.el.addEventListener("mousedown",this._handleCarouselTapBound);this.el.addEventListener("mousemove",this._handleCarouselDragBound);this.el.addEventListener("mouseup",this._handleCarouselReleaseBound);this.el.addEventListener("mouseleave",this._handleCarouselReleaseBound);this.el.addEventListener("click",this._handleCarouselClickBound);this.showIndicators&& this.$indicators&&(this._handleIndicatorClickBound=this._handleIndicatorClick.bind(this),this.$indicators.find(".indicator-item").each(function(c,b){c.addEventListener("click",a._handleIndicatorClickBound)}));this._handleThrottledResizeBound=M.throttle(this._handleResize,200).bind(this);window.addEventListener("resize",this._handleThrottledResizeBound)}},{key:"_removeEventHandlers",value:function(){var a=this;"undefined"!==typeof window.ontouchstart&&(this.el.removeEventListener("touchstart",this._handleCarouselTapBound), this.el.removeEventListener("touchmove",this._handleCarouselDragBound),this.el.removeEventListener("touchend",this._handleCarouselReleaseBound));this.el.removeEventListener("mousedown",this._handleCarouselTapBound);this.el.removeEventListener("mousemove",this._handleCarouselDragBound);this.el.removeEventListener("mouseup",this._handleCarouselReleaseBound);this.el.removeEventListener("mouseleave",this._handleCarouselReleaseBound);this.el.removeEventListener("click",this._handleCarouselClickBound); this.showIndicators&&this.$indicators&&this.$indicators.find(".indicator-item").each(function(c,b){c.removeEventListener("click",a._handleIndicatorClickBound)});window.removeEventListener("resize",this._handleThrottledResizeBound)}},{key:"_handleCarouselTap",value:function(a){"mousedown"===a.type&&d(a.target).is("img")&&a.preventDefault();this.pressed=!0;this.verticalDragged=this.dragged=!1;this.reference=this._xpos(a);this.referenceY=this._ypos(a);this.velocity=this.amplitude=0;this.frame=this.offset; this.timestamp=Date.now();clearInterval(this.ticker);this.ticker=setInterval(this._trackBound,100)}},{key:"_handleCarouselDrag",value:function(a){if(this.dragged)return a.preventDefault(),a.stopPropagation(),!1}},{key:"_handleCarouselRelease",value:function(a){if(this.pressed){this.pressed=!1;clearInterval(this.ticker);this.target=this.offset;if(10this.velocity)this.amplitude=.9*this.velocity,this.target=this.offset+this.amplitude;this.target=Math.round(this.target/this.dim)*this.dim; this.noWrap&&(this.target>=this.dim*(this.count-1)?this.target=this.dim*(this.count-1):0>this.target&&(this.target=0));this.amplitude=this.target-this.offset;this.timestamp=Date.now();requestAnimationFrame(this._autoScrollBound);this.dragged&&(a.preventDefault(),a.stopPropagation());return!1}}},{key:"_handleCarouselClick",value:function(a){if(this.dragged)return a.preventDefault(),a.stopPropagation(),!1;if(!this.options.fullWidth){var c=d(a.target).closest(".carousel-item").index();0!==this._wrap(this.center)- c&&(a.preventDefault(),a.stopPropagation());this._cycleTo(c)}}},{key:"_handleIndicatorClick",value:function(a){a.stopPropagation();a=d(a.target).closest(".indicator-item");a.length&&this._cycleTo(a.index())}},{key:"_handleResize",value:function(a){this.options.fullWidth?(this.itemWidth=this.$el.find(".carousel-item").first().innerWidth(),this.imageHeight=this.$el.find(".carousel-item.active").height(),this.dim=2*this.itemWidth+this.options.padding,this.target=this.offset=2*this.center*this.itemWidth, this._setCarouselHeight(!0)):this._scroll()}},{key:"_setCarouselHeight",value:function(a){var c=this,b=this.$el.find(".carousel-item.active").length?this.$el.find(".carousel-item.active").first():this.$el.find(".carousel-item").first(),d=b.find("img").first();if(d.length)if(d[0].complete)a=d.height(),0=this.count?a%this.count:0>a?this._wrap(this.count+a%this.count):a}},{key:"_track",value:function(){var a=void 0,c=void 0,a=void 0,a=Date.now(),c=a-this.timestamp;this.timestamp= a;a=this.offset-this.frame;this.frame=this.offset;this.velocity=1E3*a/(1+c)*.8+.2*this.velocity}},{key:"_autoScroll",value:function(){var a=void 0,a=void 0;this.amplitude&&(a=Date.now()-this.timestamp,a=this.amplitude*Math.exp(-a/this.options.duration),2a?(this._scroll(this.target-a),requestAnimationFrame(this._autoScrollBound)):this._scroll(this.target))}},{key:"_scroll",value:function(a){var c=this;this.$el.hasClass("scrolling")||this.el.classList.add("scrolling");null!=this.scrollingTimeout&& window.clearTimeout(this.scrollingTimeout);this.scrollingTimeout=window.setTimeout(function(){c.$el.removeClass("scrolling")},this.options.duration);var b=void 0,e=void 0,f=void 0,g=void 0,h=void 0,k=void 0,n=void 0,l=void 0,w=void 0,x=void 0,B=this.center,C=1/this.options.numVisible;this.offset="number"===typeof a?a:this.offset;this.center=Math.floor((this.offset+this.dim/2)/this.dim);f=this.offset-this.center*this.dim;g=0>f?1:-1;h=-g*f*2/this.dim;e=this.count>>1;this.options.fullWidth?(n="translateX(0)", x=1):(n="translateX("+(this.el.clientWidth-this.itemWidth)/2+"px) ",n+="translateY("+(this.el.clientHeight-this.itemHeight)/2+"px)",x=1-C*h);this.showIndicators&&(a=this.center%this.count,k=this.$indicators.find(".indicator-item.active"),k.index()!==a&&(k.removeClass("active"),this.$indicators.find(".indicator-item").eq(a)[0].classList.add("active")));if(!this.noWrap||0<=this.center&&this.centerf?1-h:1):(l=this.options.dist*(2*b+h*g),w=1-C*(2*b+h*g));if(!this.noWrap||this.center+bb?Math.abs(b+this.count)b?this.target+=this.dim*Math.abs(b):0=this.count||0>a){if(this.noWrap)return;a=this._wrap(a)}this._cycleTo(a)}},{key:"prev",value:function(a){if(void 0===a||isNaN(a))a=1;a=this.center-a;if(a>=this.count||0>a){if(this.noWrap)return;a=this._wrap(a)}this._cycleTo(a)}},{key:"set",value:function(a,c){if(void 0===a||isNaN(a))a=0;if(a>this.count||0>a){if(this.noWrap)return;a=this._wrap(a)}this._cycleTo(a,c)}}],[{key:"init",value:function(a,c){return _get(f.__proto__||Object.getPrototypeOf(f),"init",this).call(this,this,a,c)}},{key:"getInstance", value:function(a){return(a.jquery?a[0]:a).M_Carousel}},{key:"defaults",get:function(){return g}}]);return f}(Component);M.Carousel=h;M.jQueryLoaded&&M.initializeJqueryWrapper(h,"carousel","M_Carousel")})(cash); (function(d){var g={onOpen:void 0,onClose:void 0},h=function(h){function f(a,c){_classCallCheck(this,f);var b=_possibleConstructorReturn(this,(f.__proto__||Object.getPrototypeOf(f)).call(this,f,a,c));b.el.M_TapTarget=b;b.options=d.extend({},f.defaults,c);b.isOpen=!1;b.$origin=d("#"+b.$el.attr("data-target"));b._setup();b._calculatePositioning();b._setupEventHandlers();return b}_inherits(f,h);_createClass(f,[{key:"destroy",value:function(){this._removeEventHandlers();this.el.TapTarget=void 0}},{key:"_setupEventHandlers", value:function(){this._handleDocumentClickBound=this._handleDocumentClick.bind(this);this._handleTargetClickBound=this._handleTargetClick.bind(this);this._handleOriginClickBound=this._handleOriginClick.bind(this);this.el.addEventListener("click",this._handleTargetClickBound);this.originEl.addEventListener("click",this._handleOriginClickBound);this._handleThrottledResizeBound=M.throttle(this._handleResize,200).bind(this);window.addEventListener("resize",this._handleThrottledResizeBound)}},{key:"_removeEventHandlers", value:function(){this.el.removeEventListener("click",this._handleTargetClickBound);this.originEl.removeEventListener("click",this._handleOriginClickBound);window.removeEventListener("resize",this._handleThrottledResizeBound)}},{key:"_handleTargetClick",value:function(a){this.open()}},{key:"_handleOriginClick",value:function(a){this.close()}},{key:"_handleResize",value:function(a){this._calculatePositioning()}},{key:"_handleDocumentClick",value:function(a){d(a.target).closest(".tap-target-wrapper").length|| (this.close(),a.preventDefault(),a.stopPropagation())}},{key:"_setup",value:function(){this.wrapper=this.$el.parent()[0];this.waveEl=d(this.wrapper).find(".tap-target-wave")[0];this.originEl=d(this.wrapper).find(".tap-target-origin")[0];this.contentEl=this.$el.find(".tap-target-content")[0];d(this.wrapper).hasClass(".tap-target-wrapper")||(this.wrapper=document.createElement("div"),this.wrapper.classList.add("tap-target-wrapper"),this.$el.before(d(this.wrapper)),this.wrapper.append(this.el));this.contentEl|| (this.contentEl=document.createElement("div"),this.contentEl.classList.add("tap-target-content"),this.$el.append(this.contentEl));this.waveEl||(this.waveEl=document.createElement("div"),this.waveEl.classList.add("tap-target-wave"),this.originEl||(this.originEl=this.$origin.clone(!0,!0),this.originEl.addClass("tap-target-origin"),this.originEl.removeAttr("id"),this.originEl.removeAttr("style"),this.originEl=this.originEl[0],this.waveEl.append(this.originEl)),this.wrapper.append(this.waveEl))}},{key:"_calculatePositioning", value:function(){var a="fixed"===this.$origin.css("position");if(!a)for(var c=this.$origin.parents(),b=0;bk,w=f<=n,n=f>n,x=g>=.25*b&&g<=.75*b,B=this.$el.outerWidth(), C=this.$el.outerHeight(),e=f+e/2-C/2,g=g+c/2-B/2,f=x?B:B/2+c,I=C/2,F=w?C/2:0,x=l&&!x?B/2-c:0,E=n?"bottom":"top",y=2*c,t=C/2-y/2,J=B/2-y/2,G={};G.top=w?e+"px":"";G.right=k?b-g-B+"px":"";G.bottom=n?h-e-C+"px":"";G.left=l?g+"px":"";G.position=a?"fixed":"absolute";d(this.wrapper).css(G);d(this.contentEl).css({width:f+"px",height:I+"px",top:F+"px",right:"0px",bottom:"0px",left:x+"px",padding:c+"px",verticalAlign:E});d(this.waveEl).css({top:t+"px",left:J+"px",width:y+"px",height:y+"px"})}},{key:"open", value:function(){this.isOpen||("function"===typeof this.options.onOpen&&this.options.onOpen.call(this,this.$origin[0]),this.isOpen=!0,this.wrapper.classList.add("open"),document.body.addEventListener("click",this._handleDocumentClickBound,!0),document.body.addEventListener("touchend",this._handleDocumentClickBound))}},{key:"close",value:function(){this.isOpen&&("function"===typeof this.options.onClose&&this.options.onClose.call(this,this.$origin[0]),this.isOpen=!1,this.wrapper.classList.remove("open"), document.body.removeEventListener("click",this._handleDocumentClickBound,!0),document.body.removeEventListener("touchend",this._handleDocumentClickBound))}}],[{key:"init",value:function(a,c){return _get(f.__proto__||Object.getPrototypeOf(f),"init",this).call(this,this,a,c)}},{key:"getInstance",value:function(a){return(a.jquery?a[0]:a).M_TapTarget}},{key:"defaults",get:function(){return g}}]);return f}(Component);M.TapTarget=h;M.jQueryLoaded&&M.initializeJqueryWrapper(h,"tapTarget","M_TapTarget")})(cash); (function(d){var g={classes:"",dropdownOptions:{}},h=function(h){function f(a,c){_classCallCheck(this,f);var b=_possibleConstructorReturn(this,(f.__proto__||Object.getPrototypeOf(f)).call(this,f,a,c));if(b.$el.hasClass("browser-default"))return _possibleConstructorReturn(b);b.el.M_FormSelect=b;b.options=d.extend({},f.defaults,c);b.isMultiple=b.$el.prop("multiple");b.el.tabIndex=-1;b._keysSelected={};b._valueDict={};b._setupDropdown();b._setupEventHandlers();return b}_inherits(f,h);_createClass(f, [{key:"destroy",value:function(){this._removeEventHandlers();this._removeDropdown();this.el.M_FormSelect=void 0}},{key:"_setupEventHandlers",value:function(){var a=this;this._handleSelectChangeBound=this._handleSelectChange.bind(this);this._handleOptionClickBound=this._handleOptionClick.bind(this);this._handleInputClickBound=this._handleInputClick.bind(this);d(this.dropdownOptions).find("li:not(.optgroup)").each(function(c){c.addEventListener("click",a._handleOptionClickBound)});this.el.addEventListener("change", this._handleSelectChangeBound);this.input.addEventListener("click",this._handleInputClickBound)}},{key:"_removeEventHandlers",value:function(){var a=this;d(this.dropdownOptions).find("li:not(.optgroup)").each(function(c){c.removeEventListener("click",a._handleOptionClickBound)});this.el.removeEventListener("change",this._handleSelectChangeBound);this.input.removeEventListener("click",this._handleInputClickBound)}},{key:"_handleSelectChange",value:function(a){this._setValueToInput()}},{key:"_handleOptionClick", value:function(a){a.preventDefault();var c=d(a.target).closest("li")[0],b=c.id;if(!d(c).hasClass("disabled")&&!d(c).hasClass("optgroup")&&b.length){var e=!0;this.isMultiple?(c=d(this.dropdownOptions).find("li.disabled.selected"),c.length&&(c.removeClass("selected"),c.find('input[type="checkbox"]').prop("checked",!1),this._toggleEntryFromArray(c[0].id)),e=this._toggleEntryFromArray(b)):(d(this.dropdownOptions).find("li").removeClass("selected"),d(c).toggleClass("selected",e));d(this._valueDict[b].el).prop("selected")!== e&&(d(this._valueDict[b].el).prop("selected",e),this.$el.trigger("change"))}a.stopPropagation()}},{key:"_handleInputClick",value:function(){this.dropdown&&this.dropdown.isOpen&&(this._setValueToInput(),this._setSelectedStates())}},{key:"_setupDropdown",value:function(){var a=this;this.wrapper=document.createElement("div");d(this.wrapper).addClass("select-wrapper "+this.options.classes);this.$el.before(d(this.wrapper));this.wrapper.appendChild(this.el);this.el.disabled&&this.wrapper.classList.add("disabled"); this.$selectOptions=this.$el.children("option, optgroup");this.dropdownOptions=document.createElement("ul");this.dropdownOptions.id="select-options-"+M.guid();d(this.dropdownOptions).addClass("dropdown-content select-dropdown "+(this.isMultiple?"multiple-select-dropdown":""));this.$selectOptions.length&&this.$selectOptions.each(function(b){if(d(b).is("option")){var c=void 0,c=a.isMultiple?a._appendOptionWithIcon(a.$el,b,"multiple"):a._appendOptionWithIcon(a.$el,b);a._addOptionToValueDict(b,c)}else d(b).is("optgroup")&& (c=d(b).children("option"),d(a.dropdownOptions).append(d('
  • '+b.getAttribute("label")+"
  • ")[0]),c.each(function(b){var c=a._appendOptionWithIcon(a.$el,b,"optgroup-option");a._addOptionToValueDict(b,c)}))});this.$el.after(this.dropdownOptions);this.input=document.createElement("input");d(this.input).addClass("select-dropdown dropdown-trigger");this.input.setAttribute("type","text");this.input.setAttribute("readonly","true");this.input.setAttribute("data-target",this.dropdownOptions.id); this.el.disabled&&d(this.input).prop("disabled","true");this.$el.before(this.input);this._setValueToInput();var c=d('');this.$el.before(c[0]);this.el.disabled||(c=d.extend({},this.options.dropdownOptions),c.onOpenEnd=function(b){b=d(a.dropdownOptions).find(".selected").first();b.length&&(M.keyDown=!0,a.dropdown.focusedIndex=b.index(), a.dropdown._focusFocusedItem(),M.keyDown=!1,a.dropdown.isScrollable&&(b=b[0].getBoundingClientRect().top-a.dropdownOptions.getBoundingClientRect().top,b-=a.dropdownOptions.clientHeight/2,a.dropdownOptions.scrollTop=b))},this.isMultiple&&(c.closeOnClick=!1),this.dropdown=M.Dropdown.init(this.input,c));this._setSelectedStates()}},{key:"_addOptionToValueDict",value:function(a,c){var b=Object.keys(this._valueDict).length,b=this.dropdownOptions.id+b,d={};c.id=b;d.el=a;d.optionEl=c;this._valueDict[b]=d}}, {key:"_removeDropdown",value:function(){d(this.wrapper).find(".caret").remove();d(this.input).remove();d(this.dropdownOptions).remove();d(this.wrapper).before(this.$el);d(this.wrapper).remove()}},{key:"_appendOptionWithIcon",value:function(a,c,b){a=c.disabled?"disabled ":"";var e="optgroup-option"===b?"optgroup-option ":"",f=this.isMultiple?'":c.innerHTML;b=d("
  • ");var g=d("");g.html(f);b.addClass(a+" "+e); b.append(g);if(c=c.getAttribute("data-icon"))c=d(''),b.prepend(c);d(this.dropdownOptions).append(b[0]);return b[0]}},{key:"_toggleEntryFromArray",value:function(a){var c=!this._keysSelected.hasOwnProperty(a),b=d(this._valueDict[a].optionEl);c?this._keysSelected[a]=!0:delete this._keysSelected[a];b.toggleClass("selected",c);b.find('input[type="checkbox"]').prop("checked",c);b.prop("selected",c);return c}},{key:"_setValueToInput",value:function(){var a=[];this.$el.find("option").each(function(b){d(b).prop("selected")&& (b=d(b).text(),a.push(b))});if(!a.length){var c=this.$el.find("option:disabled").eq(0);c.length&&""===c[0].value&&a.push(c.text())}this.input.value=a.join(", ")}},{key:"_setSelectedStates",value:function(){this._keysSelected={};for(var a in this._valueDict){var c=this._valueDict[a],b=d(c.el).prop("selected");d(c.optionEl).find('input[type="checkbox"]').prop("checked",b);b?(this._activateOption(d(this.dropdownOptions),d(c.optionEl)),this._keysSelected[a]=!0):d(c.optionEl).removeClass("selected")}}}, {key:"_activateOption",value:function(a,c){c&&(this.isMultiple||a.find("li.selected").removeClass("selected"),d(c).addClass("selected"))}},{key:"getSelectedValues",value:function(){var a=[],c;for(c in this._keysSelected)a.push(this._valueDict[c].el.value);return a}}],[{key:"init",value:function(a,c){return _get(f.__proto__||Object.getPrototypeOf(f),"init",this).call(this,this,a,c)}},{key:"getInstance",value:function(a){return(a.jquery?a[0]:a).M_FormSelect}},{key:"defaults",get:function(){return g}}]); return f}(Component);M.FormSelect=h;M.jQueryLoaded&&M.initializeJqueryWrapper(h,"formSelect","M_FormSelect")})(cash); (function(d,g){var h={},k=function(f){function a(c,b){_classCallCheck(this,a);var e=_possibleConstructorReturn(this,(a.__proto__||Object.getPrototypeOf(a)).call(this,a,c,b));e.el.M_Range=e;e.options=d.extend({},a.defaults,b);e._mousedown=!1;e._setupThumb();e._setupEventHandlers();return e}_inherits(a,f);_createClass(a,[{key:"destroy",value:function(){this._removeEventHandlers();this._removeThumb();this.el.M_Range=void 0}},{key:"_setupEventHandlers",value:function(){this._handleRangeChangeBound=this._handleRangeChange.bind(this); this._handleRangeMousedownTouchstartBound=this._handleRangeMousedownTouchstart.bind(this);this._handleRangeInputMousemoveTouchmoveBound=this._handleRangeInputMousemoveTouchmove.bind(this);this._handleRangeMouseupTouchendBound=this._handleRangeMouseupTouchend.bind(this);this._handleRangeBlurMouseoutTouchleaveBound=this._handleRangeBlurMouseoutTouchleave.bind(this);this.el.addEventListener("change",this._handleRangeChangeBound);this.el.addEventListener("mousedown",this._handleRangeMousedownTouchstartBound); this.el.addEventListener("touchstart",this._handleRangeMousedownTouchstartBound);this.el.addEventListener("input",this._handleRangeInputMousemoveTouchmoveBound);this.el.addEventListener("mousemove",this._handleRangeInputMousemoveTouchmoveBound);this.el.addEventListener("touchmove",this._handleRangeInputMousemoveTouchmoveBound);this.el.addEventListener("mouseup",this._handleRangeMouseupTouchendBound);this.el.addEventListener("touchend",this._handleRangeMouseupTouchendBound);this.el.addEventListener("blur", this._handleRangeBlurMouseoutTouchleaveBound);this.el.addEventListener("mouseout",this._handleRangeBlurMouseoutTouchleaveBound);this.el.addEventListener("touchleave",this._handleRangeBlurMouseoutTouchleaveBound)}},{key:"_removeEventHandlers",value:function(){this.el.removeEventListener("change",this._handleRangeChangeBound);this.el.removeEventListener("mousedown",this._handleRangeMousedownTouchstartBound);this.el.removeEventListener("touchstart",this._handleRangeMousedownTouchstartBound);this.el.removeEventListener("input", this._handleRangeInputMousemoveTouchmoveBound);this.el.removeEventListener("mousemove",this._handleRangeInputMousemoveTouchmoveBound);this.el.removeEventListener("touchmove",this._handleRangeInputMousemoveTouchmoveBound);this.el.removeEventListener("mouseup",this._handleRangeMouseupTouchendBound);this.el.removeEventListener("touchend",this._handleRangeMouseupTouchendBound);this.el.removeEventListener("blur",this._handleRangeBlurMouseoutTouchleaveBound);this.el.removeEventListener("mouseout",this._handleRangeBlurMouseoutTouchleaveBound); this.el.removeEventListener("touchleave",this._handleRangeBlurMouseoutTouchleaveBound)}},{key:"_handleRangeChange",value:function(){d(this.value).html(this.$el.val());d(this.thumb).hasClass("active")||this._showRangeBubble();var a=this._calcRangeOffset();d(this.thumb).addClass("active").css("left",a+"px")}},{key:"_handleRangeMousedownTouchstart",value:function(a){d(this.value).html(this.$el.val());this._mousedown=!0;this.$el.addClass("active");d(this.thumb).hasClass("active")||this._showRangeBubble(); "input"!==a.type&&(a=this._calcRangeOffset(),d(this.thumb).addClass("active").css("left",a+"px"))}},{key:"_handleRangeInputMousemoveTouchmove",value:function(){if(this._mousedown){d(this.thumb).hasClass("active")||this._showRangeBubble();var a=this._calcRangeOffset();d(this.thumb).addClass("active").css("left",a+"px");d(this.value).html(this.$el.val())}}},{key:"_handleRangeMouseupTouchend",value:function(){this._mousedown=!1;this.$el.removeClass("active")}},{key:"_handleRangeBlurMouseoutTouchleave", value:function(){if(!this._mousedown){var a=7+parseInt(this.$el.css("padding-left"))+"px";d(this.thumb).hasClass("active")&&(g.remove(this.thumb),g({targets:this.thumb,height:0,width:0,top:10,easing:"easeOutQuad",marginLeft:a,duration:100}));d(this.thumb).removeClass("active")}}},{key:"_setupThumb",value:function(){this.thumb=document.createElement("span");this.value=document.createElement("span");d(this.thumb).addClass("thumb");d(this.value).addClass("value");d(this.thumb).append(this.value);this.$el.after(this.thumb)}}, {key:"_removeThumb",value:function(){d(this.thumb).remove()}},{key:"_showRangeBubble",value:function(){var a=-7+parseInt(d(this.thumb).parent().css("padding-left"))+"px";g.remove(this.thumb);g({targets:this.thumb,height:30,width:30,top:-30,marginLeft:a,duration:300,easing:"easeOutQuint"})}},{key:"_calcRangeOffset",value:function(){var a=this.$el.width()-15,b=parseFloat(this.$el.attr("max"))||100,d=parseFloat(this.$el.attr("min"))||0;return(parseFloat(this.$el.val())-d)/(b-d)*a}}],[{key:"init",value:function(c, b){return _get(a.__proto__||Object.getPrototypeOf(a),"init",this).call(this,this,c,b)}},{key:"getInstance",value:function(a){return(a.jquery?a[0]:a).M_Range}},{key:"defaults",get:function(){return h}}]);return a}(Component);M.Range=k;M.jQueryLoaded&&M.initializeJqueryWrapper(k,"range","M_Range");k.init(d("input[type=range]"))})(cash,M.anime);