define(["require","exports","css:/base.css","css:/style-web.css","css:/header-web.css","./edu-vendor","inline-views:/header-tpl","systemjs","npm:tablesort/dist/tablesort.min.js","css:/icons-social.css","npm:zenscroll/zenscroll.js","npm:dompurify/dist/purify.js"],function(o,e,t,n,i,u,r,s,a,l,c,h){"use strict";function d(n){if(n&&n.__esModule)return n;var i=Object.create(null);return n&&Object.keys(n).forEach(function(e){var t;"default"!==e&&(t=Object.getOwnPropertyDescriptor(n,e),Object.defineProperty(i,e,t.get?t:{enumerable:!0,get:function(){return n[e]}}))}),i.default=n,Object.freeze(i)}function m(){var e=!1;try{e="undefined"!=typeof document&&"undefined"!=typeof window}catch(e){}return e&&!g()}function p(){return"DEV"==W.getEnv()&&((m()||g())&&window.isLocalEv||V()&&global.isLOCAL)}function g(){var e=!1;try{e=window.cordova&&window.cordova.platformId}catch(e){}return e}function V(){var e=!1;try{e="undefined"!=typeof document&&"undefined"!=typeof window}catch(e){}return!e}m()&&(window.matchMedia("(display-mode: standalone)").matches||window.navigator.standalone||window.Windows&&window.Windows.Devices);var f=function(){var e=!1;try{e=(e="undefined"!=typeof document&&"undefined"!=typeof window)&&(window&&window.JSTESTING)}catch(e){}return e}();function v(){return"DEV"==W.getEnv()}function y(e){return String.prototype.trim?String.prototype.trim.call(e):e.replace(/^\s+|\s+$/gm,"")}function b(e,n){return e.replace(/\{(\d+)\}/g,function(e,t){return void 0!==n[t]?n[t]:e})}function _(e){return"string"==typeof e}function S(e){if(!_(e))throw new TypeError("stringGetDigits called on a non-string. The given value is "+typeof e);return y(e).replace(/[^0-9]/g,"")}function w(e,t){return"number"==typeof e&&(t&&isNaN(e)||isFinite(e))}function E(e){if(_(e)){var t=e.trim(),n=t.replace(/[^0-9.]/g,"");0==t.indexOf("-")&&(n="-"+n);n=parseFloat(n);return w(n)?n:null}return w(e)?e:null}function k(e,t,n,i,r){void 0===t&&(t=1),void 0===n&&(n="$"),void 0===i&&(i=","),void 0===r&&(r="."),t=!isNaN(t=Math.abs(t))&&0<t?Math.pow(10,t):1,n=void 0!==n?n:"$",i=i||",",r=r||".";var o=e<0?"-":"",s=parseInt(e=Math.round(Math.abs(+e||0)*t)/t,10)+"",a=3<(a=s.length)?a%3:0,i=n+o+(a?s.substr(0,a)+i:"")+s.substr(a).replace(/(\d{3})(?=\d)/g,"$1"+i);return 1<t&&0<Math.abs(e-s)&&(i+=r+(Math.round(Math.abs(e-s)*t)/t).toString().substring(2)),i}function x(e){return Array.isArray?Array.isArray(e):e&&"[object Array]"===Object.prototype.toString.call(e)}function P(e,t,n){if(void 0===n&&(n=e),!x(e))throw new TypeError("forEach called on a non-array type value. The given value is "+typeof e);var i;n=n||e;for(var r=0,o=e.length;r<o&&("boolean"!=typeof(i=t.call(n,e[r],r,e))||i);)r++}function O(e){return"function"==typeof e}function C(e){return null!==e&&"object"==typeof e&&!x(e)}function N(t,n,i){void 0===n&&(n=!0),void 0===i&&(i=!1);var e=Object.keys(t),r=[];return P(e,function(e){i&&null===t[e]||r.push(encodeURIComponent(e)+"="+(n?encodeURIComponent(t[e]):t[e]))}),r.join("&")}function T(e,t,n){var i,r,o=(n=void 0===n?e:n)||e;if(!C(e))throw new TypeError("Object.forEach called on non-object. The given value is "+typeof e);if(!O(t))throw new TypeError("The given iterator is not a function");for(r in e)if(e.hasOwnProperty(r)&&"boolean"==typeof(i=t.apply(o,[e[r],r]))&&!i)break}function I(e){if(!C(e)&&!x(e))return e;var t=!x(e),n=t?{}:[],i=0,r=0;if(t)for(var o=Object.keys(e),i=0,r=o.length;i<r;i++){var s=o[i];n[s]=I(e[s])}else for(i=0,r=e.length;i<r;i++)n[i]=I(e[i]);return n}function F(e,t,n){if(void 0===n&&(n=!1),!C(e)||!C(t))throw new TypeError("First or second argument is not an json object");return function e(t,n,i){if(void 0===i&&(i=!1),!C(n)&&!x(n))return n;var r=!x(n),o=0,s=0,a=i?I(t):t;if(!r){for(x(a)||(a=[]),o=0,s=n.length;o<s;o++)a[l=n[o]]=e(a[l],n[l]);return n}for(var l,c=Object.keys(n),o=0,s=c.length;o<s;o++)a[l=c[o]]=e(a[l]||{},n[l]);return a}(e,t,n)}function L(e){if(!C(e))throw new TypeError("Object.copy called on non-object. The given value is "+typeof e);return I(e)}function A(t,e){var n=!1;return P(e,function(e){if(t===e)return!(n=!0)}),n}function M(e){return null==e||void 0===e}var z={};function R(e,t){void 0===e&&(e="");function n(e,t){return t<(e=parseInt(e,10).toString(16)).length?e.slice(e.length-t):t>e.length?Array(t-e.length+1).join("0")+e:e}return(z=z||{}).uniqidSeed||(z.uniqidSeed=Math.floor(123456789*Math.random())),z.uniqidSeed++,e=e,e+=n(parseInt(((new Date).getTime()/1e3).toString(),10),8),e+=n(z.uniqidSeed,5),t&&(e+=(10*Math.random()).toFixed(8).toString()),e}var D,B,j=function(){if("undefined"!=typeof window){if(window.requestAnimationFrame)return function(e,t){return window.requestAnimationFrame.apply(window,[e,t])};var r=0,e=function(e){var t=(new Date).getTime(),n=Math.max(0,16-(t-r)),i=window.setTimeout(function(){e(t+n)},n);return r=t+n,i}}else e=function(e){e()};return e}(),U=(D=null,function(){if(V())return!1;if(null!==D)return D;D=!1;try{var e=function(){window.removeEventListener("test",e)},t=Object.defineProperty({},"passive",{get:function(){D=!0}});window.addEventListener("test",e,t)}catch(e){}return D}),W={getEnv:function(){return B},setEnv:function(e){B=e}},H=(G.prototype.CloseMobKeyboard=function(e){e.target!=document.activeElement&&(document.activeElement instanceof HTMLInputElement||document.activeElement instanceof HTMLTextAreaElement)&&document.activeElement.blur()},G.prototype.ngOnInit=function(){this.CloseMobKeyboard=this.CloseMobKeyboard.bind(this),V()||f||document.addEventListener("click",this.CloseMobKeyboard)},G.prototype.ngAfterViewInit=function(){this.ripple=!1},G.prototype.ngOnDestroy=function(){V()||f||document.removeEventListener("click",this.CloseMobKeyboard)},G.ɵfac=function(e){return new(e||G)(u.ɵɵdirectiveInject(u.ElementRef),u.ɵɵdirectiveInject(u.NgZone))},G.ɵdir=u.ɵɵdefineDirective({type:G,selectors:[["","zing-region",""]],inputs:{ripple:["zing-ripple","ripple"]}}),G);function G(e,t){this.el=e,this._zone=t,this.ripple=!1}u.setClassMetadata(H,[{type:u.Directive,args:[{selector:"[zing-region]"}]}],function(){return[{type:u.ElementRef},{type:u.NgZone}]},{ripple:[{type:u.Input,args:["zing-ripple"]}]});var K=(q.prototype._eventsDestroyCallbacksTrigger=function(){this._eventsDestroyCallbacks.forEach(function(e){e()}),this._eventsDestroyCallbacks=[]},q.prototype.specialEventsDestroy=function(e){this._eventsDestroyCallbacks.indexOf(e)<0&&this._eventsDestroyCallbacks.push(e)},q.prototype.ngAfterViewInit=function(){var t,n,e,i,r,o,s=this;function a(e){s._zone.run(function(){s.onTap.emit(e)}),e.stopPropagation(),document.removeEventListener("click",t),setTimeout(function(){document.addEventListener("click",t)})}function l(e){n=!0,s._zone.run(function(){s.onTapHover.emit(e)}),e.stopPropagation(),document.removeEventListener("click",o),setTimeout(function(){document.addEventListener("click",o)})}function c(e){r?r=!1:(s.onTapHoverOutside.emit(e),document.removeEventListener("click",o))}V()||f||(this.hmEl=this.el.nativeElement,0<this.onTap.observers.length&&((e=0<this.onTapOutside.observers.length)||this._zone.runOutsideAngular(function(){s.hmEl.addEventListener("click",function(e){function t(){s._zone.run(function(){s.onTap.emit(e)})}s.zingTapDelay?setTimeout(t,s.zingTapDelay):t()})}),e&&(t=function(e){setTimeout(function(){s._zone.run(function(){s.onTapOutside.emit(e)})}),document.removeEventListener("click",t)},s._zone.runOutsideAngular(function(){s.hmEl.addEventListener("click",a),setTimeout(function(){document.addEventListener("click",t)})}),s.specialEventsDestroy(function(){s.hmEl&&s.hmEl.removeEventListener("click",a),document.removeEventListener("click",t)}))),0<this.onTapHover.observers.length&&(n=!1,(e=0<this.onTapHoverOutside.observers.length)||this._zone.runOutsideAngular(function(){s.hmEl.addEventListener("click",function(e){n=!0,s._zone.run(function(){s.onTapHover.emit(e)})})}),i=function(e){n?n=!1:s._zone.run(function(){s.onTapHover.emit(e)})},this._zone.runOutsideAngular(function(){s.hmEl.addEventListener("mouseenter",i)}),e&&(r=!1,o=function(e){r=!0,s._zone.run(function(){s.onTapHoverOutside.emit(e)}),document.removeEventListener("click",o)},s._zone.runOutsideAngular(function(){s.hmEl.addEventListener("mouseleave",c),s.hmEl.addEventListener("click",l)}),s.specialEventsDestroy(function(){s.hmEl&&s.hmEl.removeEventListener("click",l),document.removeEventListener("click",o),s.el&&s.el.nativeElement&&(s.hmEl.removeEventListener("mouseleave",c),s.hmEl.removeEventListener("mouseenter",i))}))),0<this.onTapDoc.observers.length&&this.onTapHoverOutside.observers.length<1&&this.onTapOutside.observers.length<1&&this._zone.runOutsideAngular(function(){function e(e){e.stopPropagation()}s.hmEl.addEventListener("click",e);function t(e){setTimeout(function(){s._zone.run(function(){s.onTapDoc.emit(e)})})}document.addEventListener("click",t),s.specialEventsDestroy(function(){s.hmEl&&s.hmEl.removeEventListener("click",e),document.removeEventListener("click",t)})}))},q.prototype.ngOnDestroy=function(){this.the_slider&&(this.the_slider=null),this._eventsDestroyCallbacksTrigger(),this.hmEl=!1},q.ɵfac=function(e){return new(e||q)(u.ɵɵdirectiveInject(u.ElementRef),u.ɵɵdirectiveInject(u.NgZone))},q.ɵdir=u.ɵɵdefineDirective({type:q,selectors:[["","zing-touch",""]],inputs:{zingToggle:"zingToggle",zingFocus:"zingFocus",zingSlider:"zingSlider",zingUrl:["zing-url","zingUrl"],zingUrlContainer:["zing-url-container","zingUrlContainer"],zingUrlFeedback:["zing-url-feedback","zingUrlFeedback"],zingNoTouch:["zing-no-touch","zingNoTouch"],zingAllow:["zing-allow-action","zingAllow"],zingTapDelay:["zing-tap-delay","zingTapDelay"]},outputs:{onTap:"onTap",onTapHover:"onTapHover",onTapOutside:"onTapOutside",onTapHoverOutside:"onTapHoverOutside",onTapDoc:"onTapDoc",onSwipeLeft:"onSwipeLeft"}}),q);function q(e,t){this.el=e,this._zone=t,this.onTap=new u.EventEmitter,this.onTapHover=new u.EventEmitter,this.onTapOutside=new u.EventEmitter,this.onTapHoverOutside=new u.EventEmitter,this.onTapDoc=new u.EventEmitter,this.onSwipeLeft=new u.EventEmitter,this.zingToggle=!1,this.zingFocus=!1,this.zingSlider=!1,this.zingUrl=!1,this.zingUrlContainer=!1,this.zingUrlFeedback=!1,this.zingNoTouch=!1,this.zingTapDelay=0,this._eventsDestroyCallbacks=[]}u.setClassMetadata(K,[{type:u.Directive,args:[{selector:"[zing-touch]"}]}],function(){return[{type:u.ElementRef},{type:u.NgZone}]},{onTap:[{type:u.Output}],onTapHover:[{type:u.Output}],onTapOutside:[{type:u.Output}],onTapHoverOutside:[{type:u.Output}],onTapDoc:[{type:u.Output}],onSwipeLeft:[{type:u.Output}],zingToggle:[{type:u.Input}],zingFocus:[{type:u.Input}],zingSlider:[{type:u.Input}],zingUrl:[{type:u.Input,args:["zing-url"]}],zingUrlContainer:[{type:u.Input,args:["zing-url-container"]}],zingUrlFeedback:[{type:u.Input,args:["zing-url-feedback"]}],zingNoTouch:[{type:u.Input,args:["zing-no-touch"]}],zingAllow:[{type:u.Input,args:["zing-allow-action"]}],zingTapDelay:[{type:u.Input,args:["zing-tap-delay"]}]});var Z=(Object.defineProperty($,"TouchGestures",{get:function(){return K},enumerable:!1,configurable:!0}),$.ɵmod=u.ɵɵdefineNgModule({type:$}),$.ɵinj=u.ɵɵdefineInjector({factory:function(e){return new(e||$)}}),$);function $(){}u.setClassMetadata(Z,[{type:u.NgModule,args:[{declarations:[K,H],exports:[K,H]}]}],null,null);var Q,J,Y=["pageScrollEl"],X=o("npm:zenscroll/zenscroll.js"),ee={_isScrollable:new u.BehaviorSubject(!0),_scrollTo:new u.Subject,_onScroll:new u.ReplaySubject(1),_zenScrollRegionResolve:null,_zenScrollRegionReject:null,_zenScrollRegionGet:null};ee._zenScrollRegionGet=new Promise(function(e,t){ee._zenScrollRegionResolve=e,ee._zenScrollRegionReject=t});var te=(ne.prototype.scrollTo=function(e){var t={timing:300,offset:0};return Object.assign(t,e),new Promise(function(e){t.onDone=e,ee._scrollTo.next(t)})},ne.prototype.canScroll=function(e){ee._isScrollable.next(e)},ne.prototype.UseBodyScroll=function(){this._use_body=!0},Object.defineProperty(ne.prototype,"element",{get:function(){return Q},enumerable:!1,configurable:!0}),Object.defineProperty(ne.prototype,"overwrite_to_body",{get:function(){return this._use_body},enumerable:!1,configurable:!0}),Object.defineProperty(ne.prototype,"scrollable",{get:function(){return ee._isScrollable.getValue()},enumerable:!1,configurable:!0}),ne.prototype.ngOnDestroy=function(){ee._isScrollable.complete(),ee._onScroll.complete(),ee._scrollTo.complete()},ne.ɵfac=function(e){return new(e||ne)},ne.ɵprov=u.ɵɵdefineInjectable({token:ne,factory:ne.ɵfac}),ne);function ne(){this.onScroll=ee._onScroll}u.setClassMetadata(te,[{type:u.Injectable}],function(){return[]},null);var ie=(Object.defineProperty(re.prototype,"noScroll",{get:function(){return this._noscroll},set:function(e){this._noscroll=e,this._service.element&&(e?(this._render.addClass(this._service.element,"no-scroll"),this.use_body||this._render.setStyle(this._service.element,"overflow","hidden")):(this._render.removeClass(this._service.element,"no-scroll"),this.use_body||this._render.setStyle(this._service.element,"overflow","")))},enumerable:!1,configurable:!0}),Object.defineProperty(re.prototype,"selfoffset",{set:function(e){this._selfoffset=e},enumerable:!1,configurable:!0}),Object.defineProperty(re.prototype,"sefoffset",{get:function(){return this._selfoffset},enumerable:!1,configurable:!0}),re.prototype._bodyFallbackTarget=function(e,t){void 0===t&&(t=0);var n=e.getBoundingClientRect().top,i=Q.scrollTop,e=0,e=t<=n?n-t:-1*(t-n);Q.scrollTop=i+e},re.prototype._bodyFallbackPosition=function(e){Q.scrollTop=e},re.prototype._onScroll=function(e){var n=this;this._zone.run(function(){var e=Q.scrollTop,t=n.use_body?1/0:Q.scrollHeight-Q.clientHeight;e<0?e=0:t<e&&(e=t),ee._onScroll.next(e)})},re.prototype.ngOnInit=function(){var t,e,h=this;V()?this._render.removeAttribute(this.el.nativeElement,"scroll-region"):(Q=this.el.nativeElement,this.use_body&&this._service.UseBodyScroll(),t=0,this._subscriptions.push(ee._isScrollable.subscribe(function(e){e?t--:t++,t<0&&(t=0),h._zone.run(function(){h.noScroll=!(0===t)})})),this.use_body?(Q=document.scrollingElement||document.documentElement,"scrollRestoration"in history&&(history.scrollRestoration="manual")):document.querySelector("html").removeAttribute("scroll-region"),(this.use_body?document.querySelector("html"):Q).setAttribute("scroll-region","active"),this._subscriptions.push(ee._scrollTo.subscribe(function(u){!u.nozen&&J?ee._zenScrollRegionGet.then(function(e){function t(e){return h._sticky_header&&25<J.getY()-e&&(e-=h._sticky_header.offsetHeight),e}function n(){O(u.onDone)&&u.onDone()}var i,r=Q.getBoundingClientRect();if(i=h._selfoffset?r.top:0,e.setup(null,i),u.target){for(var o=u.target.offsetTop,s=u.target.offsetParent;s&&s!=Q;)o+=s.offsetTop,s=s.offsetParent;if(u.inview){var a=u.target.offsetHeight,l=window.innerHeight,c=a+o-l,a=Q.scrollTop;if(a<c){c=10+c;u.timing=300*Math.min(100,c-100*a/500)/100,o=c}else if(o<=a+l)return}o=t(o),o+=u.offset||0,J.toY(o,u.timing,n)}else u.position+=u.offset||0,u.position=t(u.position),J.toY(u.position,u.timing,n)}):(u.target?h._bodyFallbackTarget(u.target,u.offset||0):h._bodyFallbackPosition(u.position),O(u.onDone)&&u.onDone())}))),ee._zenScrollRegionGet.catch(function(){}),this.useZen&&!V()?(this._zone.runOutsideAngular(function(){J=X.createScroller(Q,300,0),ee._zenScrollRegionResolve(X)}),e=!!U()&&{passive:!0},(this.use_body?window:Q).addEventListener("scroll",this._onScroll,e),this._onScroll(Q.scrollTop)):ee._zenScrollRegionReject()},re.prototype.ngOnDestroy=function(){var e=this;try{(this.use_body?window:Q).removeEventListener("scroll",this._onScroll)}catch(e){}V()||((this.use_body?document.querySelector("html"):Q).removeAttribute("scroll-region"),this._zone.run(function(){e.noScroll=!1})),J=Q=null,this._subscriptions.forEach(function(e){try{e.unsubscribe()}catch(e){}}),J=Q=null,this._subscriptions.forEach(function(e){try{e.unsubscribe()}catch(e){}})},re.prototype.ngAfterViewInit=function(){if(this.main_header_offset&&!V())try{this._sticky_header=document.querySelector(this.main_header_offset)}catch(e){}},re.ɵfac=function(e){return new(e||re)(u.ɵɵdirectiveInject(u.ElementRef),u.ɵɵdirectiveInject(u.NgZone),u.ɵɵdirectiveInject(u.Renderer2),u.ɵɵdirectiveInject(te))},re.ɵdir=u.ɵɵdefineDirective({type:re,selectors:[["","scroll-region",""]],inputs:{useZen:["usezen","useZen"],use_body:["scroll-region-viewport","use_body"],main_header_offset:["scroll-region-viewport-sticky-header","main_header_offset"],selfoffset:["scroll-region-offset","selfoffset"]}}),re);function re(e,t,n,i){this.el=e,this._zone=t,this._render=n,this._service=i,this.useZen=!1,this.use_body=!1,this.main_header_offset="",this._selfoffset=!1,this._subscriptions=[],this._onScroll=this._onScroll.bind(this),this._service.overwrite_to_body&&(this.use_body=!0)}u.setClassMetadata(ie,[{type:u.Directive,args:[{selector:"[scroll-region]"}]}],function(){return[{type:u.ElementRef},{type:u.NgZone},{type:u.Renderer2},{type:te}]},{useZen:[{type:u.Input,args:["usezen"]}],use_body:[{type:u.Input,args:["scroll-region-viewport"]}],main_header_offset:[{type:u.Input,args:["scroll-region-viewport-sticky-header"]}],selfoffset:[{type:u.Input,args:["scroll-region-offset"]}]});var oe=(se.prototype._scrollNotify=function(){var e=this;this._zone.run(function(){e.scrolled.emit(e._target.offsetTop-e.offset)})},Object.defineProperty(se.prototype,"scrollToMe",{get:function(){return this._to_me},set:function(e){V()||f||this._to_me===e||!e||this._scrollExecute(),this._to_me=e},enumerable:!1,configurable:!0}),se.prototype._scrollExecute=function(){var e=this;this._zone.runOutsideAngular(function(){e._scrollArea?e._target.scrollIntoView(!0):e._service.scrollTo({target:e._target,timing:e.zenSpeed,nozen:!e.useZen,offset:e.offset}).then(function(){e._scrollNotify()})})},se.prototype.ngAfterViewInit=function(){!V()&&_(this._scrollParent)&&(this._scrollArea=document.querySelector(this._scrollParent),this._scrollArea&&(this._scrollArea.style.scrollBehavior="smooth"))},se.ɵfac=function(e){return new(e||se)(u.ɵɵdirectiveInject(u.ElementRef),u.ɵɵdirectiveInject(u.NgZone),u.ɵɵdirectiveInject(te))},se.ɵdir=u.ɵɵdefineDirective({type:se,selectors:[["","scroll-to",""]],inputs:{useZen:["usezen","useZen"],zenSpeed:["zenspeed","zenSpeed"],offset:["scrolloffset","offset"],_scrollParent:["scroll-parent","_scrollParent"],scrollToMe:["scroll-to","scrollToMe"]},outputs:{scrolled:"scrolled"}}),se);function se(e,t,n){this._zone=t,this._service=n,this.useZen=!0,this.zenSpeed=350,this.offset=0,this.scrolled=new u.EventEmitter,this._to_me=!1,this._target=e.nativeElement}u.setClassMetadata(oe,[{type:u.Directive,args:[{selector:"[scroll-to]"}]}],function(){return[{type:u.ElementRef},{type:u.NgZone},{type:te}]},{useZen:[{type:u.Input,args:["usezen"]}],zenSpeed:[{type:u.Input,args:["zenspeed"]}],offset:[{type:u.Input,args:["scrolloffset"]}],_scrollParent:[{type:u.Input,args:["scroll-parent"]}],scrolled:[{type:u.Output}],scrollToMe:[{type:u.Input,args:["scroll-to"]}]});var ae=(le.prototype._lockScroll=function(e){e.preventDefault()},le.prototype.ngOnInit=function(){V()||(this._el.nativeElement.addEventListener("touchstart",this._lockScroll),this._el.nativeElement.addEventListener("touchmove",this._lockScroll))},le.prototype.ngOnDestroy=function(){var e;V()||this._el&&this._el.nativeElement&&((e=this._el.nativeElement).removeEventListener("touchstart",this._lockScroll),e.removeEventListener("touchmove",this._lockScroll))},le.ɵfac=function(e){return new(e||le)(u.ɵɵdirectiveInject(u.ElementRef))},le.ɵdir=u.ɵɵdefineDirective({type:le,selectors:[["","prevent-body-scroll",""]]}),le);function le(e){this._el=e}u.setClassMetadata(ae,[{type:u.Directive,args:[{selector:"[prevent-body-scroll]"}]}],function(){return[{type:u.ElementRef}]},null);var ce=(ue.prototype.ngOnInit=function(){var o,s,a=this;V()||f||(o=0,s={idx:null,pos:null},this._watchers.push(this._service.onScroll.subscribe(function(r){a.disabled||j(function(){var i=window.innerHeight;a.pages.forEach(function(e,t){var n=e.nativeElement.getBoundingClientRect(),e=n.top+(a.offset||0),n=n.bottom+(a.offset||0)-(a.btthr||0);if(o<=r)s=null,e<=0&&0<n&&a.onView.emit(t);else if(0<n&&n<=i){if(null==s)s={idx:t,pos:e};else{if(t!==s.idx&&e>=s.pos)return;s={idx:t,pos:e}}a.onView.emit(t)}else s&&s.idx==t&&(s={idx:t,pos:e})}),o=r})})))},ue.prototype.ngOnDestroy=function(){V()||f||0<this._watchers.length&&this._watchers.forEach(function(e){e.unsubscribe()})},ue.ɵfac=function(e){return new(e||ue)(u.ɵɵdirectiveInject(te))},ue.ɵdir=u.ɵɵdefineDirective({type:ue,selectors:[["","page-scrolling-container",""]],contentQueries:function(e,t,n){var i;1&e&&u.ɵɵcontentQuery(n,Y,!0),2&e&&u.ɵɵqueryRefresh(i=u.ɵɵloadQuery())&&(t.pages=i)},inputs:{offset:["scrolloffset","offset"],btthr:["bottom-threshold","btthr"],disabled:["pg-sc-container-disabled","disabled"]},outputs:{onView:"onView"}}),ue);function ue(e){this._service=e,this.offset=0,this.btthr=50,this.disabled=!1,this._watchers=[],this.onView=new u.EventEmitter}u.setClassMetadata(ce,[{type:u.Directive,args:[{selector:"[page-scrolling-container]"}]}],function(){return[{type:te}]},{offset:[{type:u.Input,args:["scrolloffset"]}],btthr:[{type:u.Input,args:["bottom-threshold"]}],disabled:[{type:u.Input,args:["pg-sc-container-disabled"]}],onView:[{type:u.Output}],pages:[{type:u.ContentChildren,args:["pageScrollEl",{descendants:!0}]}]});var he=(de.ɵmod=u.ɵɵdefineNgModule({type:de}),de.ɵinj=u.ɵɵdefineInjector({factory:function(e){return new(e||de)},imports:[[u.CommonModule]]}),de);function de(){}u.setClassMetadata(he,[{type:u.NgModule,args:[{imports:[u.CommonModule],declarations:[ce],exports:[ce]}]}],null,null);var me=o("npm:dompurify/dist/purify.js"),pe={RETURN_DOM_FRAGMENT:!1,RETURN_DOM:!1,USE_PROFILES:{html:!0,svg:!0,svgFilters:!0},ALLOW_UNKNOWN_PROTOCOLS:!0,KEEP_CONTENT:!0,ADD_TAGS:["meta","noscript"],ADD_ATTR:["content","itemprop","itemtype","itemscope","id","name","target"]};function ge(e,t){void 0===t&&(t=pe);t=Object.assign(L(pe),t);return V()?e:me.sanitize(e,t)}var fe=(Object.defineProperty(ve.prototype,"hidden",{get:function(){return this._hidden},set:function(e){var t=this;this.el.nativeElement,e?this.renderer.setAttribute(this.el.nativeElement,"hidden","true"):this.renderer.removeAttribute(this.el.nativeElement,"hidden"),this._hidden=e,V()||j(function(){t.onHide.emit(e)})},enumerable:!1,configurable:!0}),ve.ɵfac=function(e){return new(e||ve)(u.ɵɵdirectiveInject(u.ElementRef),u.ɵɵdirectiveInject(u.Renderer2))},ve.ɵdir=u.ɵɵdefineDirective({type:ve,selectors:[["","ng-hidden",""]],inputs:{hidden:["ng-hidden","hidden"]},outputs:{onHide:"onHide"}}),ve);function ve(e,t){this.el=e,this.renderer=t,this._hidden=!1,this.onHide=new u.EventEmitter}u.setClassMetadata(fe,[{type:u.Directive,args:[{selector:"[ng-hidden]"}]}],function(){return[{type:u.ElementRef},{type:u.Renderer2}]},{onHide:[{type:u.Output}],hidden:[{type:u.Input,args:["ng-hidden"]}]});var ye=(Object.defineProperty(be.prototype,"cond",{get:function(){return this._cond},set:function(e){this._cond=e,this._ready&&this._SetAttr()},enumerable:!1,configurable:!0}),be.prototype._SetAttr=function(){var t=this;x(this.attributes)&&(this._cond?this.attributes.forEach(function(e){t._renderer.setAttribute(t._el.nativeElement,e.attribute,e.value)}):this.attributes.forEach(function(e){t._renderer.removeAttribute(t._el.nativeElement,e.attribute)}))},be.prototype.ngOnInit=function(){this._SetAttr(),this._ready=!0},be.ɵfac=function(e){return new(e||be)(u.ɵɵdirectiveInject(u.ElementRef),u.ɵɵdirectiveInject(u.Renderer2))},be.ɵdir=u.ɵɵdefineDirective({type:be,selectors:[["","ng-attribute",""]],inputs:{attributes:["ng-attribute","attributes"],cond:["ng-attribute-when","cond"]}}),be);function be(e,t){this._el=e,this._renderer=t,this._ready=!1}u.setClassMetadata(ye,[{type:u.Directive,args:[{selector:"[ng-attribute]"}]}],function(){return[{type:u.ElementRef},{type:u.Renderer2}]},{attributes:[{type:u.Input,args:["ng-attribute"]}],cond:[{type:u.Input,args:["ng-attribute-when"]}]});var _e=(Se.prototype.transform=function(e,t,n){void 0===t&&(t=""),void 0===n&&(n=0);e=E(e);return w(e)?k(e,n,t):""},Se.ɵfac=function(e){return new(e||Se)},Se.ɵpipe=u.ɵɵdefinePipe({name:"moneyformat",type:Se,pure:!0}),Se);function Se(){}u.setClassMetadata(_e,[{type:u.Pipe,args:[{name:"moneyformat"}]}],null,null);var we=(Ee.prototype.transform=function(e){return((e=e)?S(e.toString()):"").replace(/(\d{3})(\d{3})(\d{4})/,"($1) $2-$3")},Ee.ɵfac=function(e){return new(e||Ee)},Ee.ɵpipe=u.ɵɵdefinePipe({name:"phoneformat",type:Ee,pure:!0}),Ee);function Ee(){}u.setClassMetadata(we,[{type:u.Pipe,args:[{name:"phoneformat"}]}],null,null);var ke=(xe.prototype._bindHTML=function(e){this._html=ge(e,this.settings),this._renderer.setProperty(this._el.nativeElement,"innerHTML",this._html)},Object.defineProperty(xe.prototype,"cleanHTML",{get:function(){return this._html},set:function(e){this._initiated?this._bindHTML(e):this._html=e},enumerable:!1,configurable:!0}),xe.prototype.ngOnInit=function(){this._html&&this._bindHTML(this._html),this._initiated=!0},xe.ɵfac=function(e){return new(e||xe)(u.ɵɵdirectiveInject(u.ElementRef),u.ɵɵdirectiveInject(u.Renderer2))},xe.ɵdir=u.ɵɵdefineDirective({type:xe,selectors:[["","cleanHTML",""]],inputs:{settings:["cleanHTML-sett","settings"],cleanHTML:"cleanHTML"}}),xe);function xe(e,t){this._el=e,this._renderer=t,this.settings=pe,this._initiated=!1}u.setClassMetadata(ke,[{type:u.Directive,args:[{selector:"[cleanHTML]"}]}],function(){return[{type:u.ElementRef},{type:u.Renderer2}]},{settings:[{type:u.Input,args:["cleanHTML-sett"]}],cleanHTML:[{type:u.Input,args:["cleanHTML"]}]});var Pe=(Object.defineProperty(Oe.prototype,"ngcontext",{set:function(e){V()?this._renderer.setProperty(this._el.nativeElement,"innerHTML",ge(e)):(e=this._sanitizer.sanitize(u.SecurityContext.HTML,(e||"").toString()),this._el.nativeElement.innerHTML=e,this._el.nativeElement.innerHTML=this._el.nativeElement.textContent)},enumerable:!1,configurable:!0}),Oe.ɵfac=function(e){return new(e||Oe)(u.ɵɵdirectiveInject(u.DomSanitizer),u.ɵɵdirectiveInject(u.ElementRef),u.ɵɵdirectiveInject(u.Renderer2))},Oe.ɵdir=u.ɵɵdefineDirective({type:Oe,selectors:[["","ng-context",""]],inputs:{ngcontext:["ng-context","ngcontext"]}}),Oe);function Oe(e,t,n){this._sanitizer=e,this._el=t,this._renderer=n}u.setClassMetadata(Pe,[{type:u.Directive,args:[{selector:"[ng-context]"}]}],function(){return[{type:u.DomSanitizer},{type:u.ElementRef},{type:u.Renderer2}]},{ngcontext:[{type:u.Input,args:["ng-context"]}]});var Ce=(Object.defineProperty(Ne.prototype,"ng_svg",{get:function(){return this._svg_attrs},set:function(e){var n,i=this;this._svg_attrs=e,this._el&&this._el.nativeElement&&(n=this._el.nativeElement,T(e,function(e,t){e?i._renderer.setAttribute(n,t,e):i._renderer.removeAttribute(n,t)}))},enumerable:!1,configurable:!0}),Ne.ɵfac=function(e){return new(e||Ne)(u.ɵɵdirectiveInject(u.ElementRef),u.ɵɵdirectiveInject(u.Renderer2))},Ne.ɵdir=u.ɵɵdefineDirective({type:Ne,selectors:[["","ng-svg-attr",""]],inputs:{ng_svg:["ng-svg-attr","ng_svg"]}}),Ne);function Ne(e,t){this._el=e,this._renderer=t}u.setClassMetadata(Ce,[{type:u.Directive,args:[{selector:"[ng-svg-attr]"}]}],function(){return[{type:u.ElementRef},{type:u.Renderer2}]},{ng_svg:[{type:u.Input,args:["ng-svg-attr"]}]});var Te=(Ie.prototype.transform=function(e,t,n){return function(e,t,n){void 0===t&&(t=1),void 0===n&&(n=!1);var i=!1,r="";return e<0&&(i=!0),r=1e9<=(e=Math.abs(e))?n?(Math.floor(e/1e8)/10).toString().replace(/\.0$/,"")+"g":(e/1e9).toFixed(t).replace(/\.0$/,"")+"g":1e6<=e?n?(Math.floor(e/1e5)/10).toString().replace(/\.0$/,"")+"m":(e/1e6).toFixed(t).replace(/\.0$/,"")+"m":1e3<=e?n?(Math.floor(e/100)/10).toString().replace(/\.0$/,"")+"k":(e/1e3).toFixed(t).replace(/\.0$/,"")+"k":e.toString(),r=i?"-"+r:r}(e,t=void 0===t?1:t,n=void 0===n?!1:n)},Ie.ɵfac=function(e){return new(e||Ie)},Ie.ɵpipe=u.ɵɵdefinePipe({name:"formatnr",type:Ie,pure:!0}),Ie);function Ie(){}u.setClassMetadata(Te,[{type:u.Pipe,args:[{name:"formatnr"}]}],null,null);var Fe=(Le.forRoot=function(){return{ngModule:Le,providers:[te]}},Le.ɵmod=u.ɵɵdefineNgModule({type:Le}),Le.ɵinj=u.ɵɵdefineInjector({factory:function(e){return new(e||Le)(u.ɵɵinject(u.Injector))},imports:[[u.CommonModule,Z],Z]}),Le);function Le(e){this._injector=e,this._injector}u.setClassMetadata(Fe,[{type:u.NgModule,args:[{declarations:[fe,ye,ie,oe,_e,we,ae,ke,Pe,Ce,Te],exports:[fe,ye,ie,oe,_e,we,ae,ke,Pe,Z,Ce,Te],imports:[u.CommonModule,Z]}]}],function(){return[{type:u.Injector}]},null);var Ve,Ae={method:"POST",url:null,retry:0,needs_session:!1,expectedType:"json",data:{},query:{},headers:{"Content-Type":"application/json;charset=UTF-8"},events:!0,id:null,xsrf:!0,silent:!1},Me={dev:"efdevhub.info",prod:"wallethub.com",web:"/",local:"wallethub.local",get internet_base(){return"https://cdnjs.cloudflare.com/ajax/libs/10up-sanitize.css/6.0.0/sanitize.min.css"},get internet(){return Me.internet_base+"?stamp="+R()},sentry:{dev:"https://eeb775119fdf4577a985f96e2f32e179@sentry.io/102345",prod:"https://0f1e5e9c3adc406e90a1e140f0702d09@sentry.io/102350"},updates:{dev:"https://cfdevcdn.s3.amazonaws.com/wallethub-ng2/updates.json?stamp="+R(),prod:"https://efstatic.s3.amazonaws.com/wallethub-ng2/updates.json?stamp="+R(),get backup(){return Re()+"wp-content/uploads/app-ng2/updates.json?stamp="+R()}}},ze=new RegExp("^(?:[a-z]+:)?//","i");function Re(e){return e&&(Ve=e,ze.test(Ve)||Ve===Me.web||(Ve="https://"+Ve)),Ve}var De="home/rpc";function Be(e){return e&&(De=e),Re()+"/"+De}var je="ajax.php";function Ue(e){return e&&(je=e),Re()+"/"+je}function We(){this.events={},this.replayevents={}}var He,Ge,Ke=new(We.prototype.eventGetorCreate=function(e){return this.events[e]||(this.replayevents[e]?this.events[e]=new u.ReplaySubject(1,w(this.replayevents[e])?this.replayevents[e]:999999999):this.events[e]=new u.Subject),this.events[e]},We.prototype.keepValueFor=function(e,t){this.replayevents[e]=t||!0},We.prototype.subscribe=function(e,t,n,i,r){void 0===r&&(r=[]);var e=this.eventGetorCreate(e),o=e.pipe.apply(e,r).subscribe(t,n,function(){i&&i(),o&&o.unsubscribe()});return o},We.prototype.emit=function(e,t,n){n&&!this.events[e]||this.eventGetorCreate(e).next(t)},We.prototype.terminate=function(e){if(!this.events[e])throw Error(e+" event was not yet created");this.events[e].complete(),delete this.events[e],this.replayevents[e]&&delete this.replayevents[e]},We.prototype.clear=function(){T(this.events,function(e){e.complete()}),this.events={},this.replayevents={}},We),qe=u.ajax;function Ze(e){e.progressSubscriber&&(r=e.progressSubscriber,delete e.progressSubscriber);var s=F(Ae,e,!0);r&&(s.progressSubscriber=r);var i,a,t,n=qe,l=new Promise(function(e,t){i=e,a=t}),c={crossDomain:!0,responseType:"text",method:s.method||"POST",url:s.url||Be(),headers:s.headers,timeout:3e4};"blob"==s.expectedType&&(c.responseType="blob"),s.timeout&&(c.timeout=s.timeout),s.progressSubscriber&&(c.progressSubscriber=s.progressSubscriber);var r=s.query;"POST"==s.method?c.body=s.data:r=Object.assign({},r,s.data),0<Object.keys(r).length&&(r=N(r),c.url+="?"+r);var u=function(r){var o=n(c).subscribe(function(t){if(setTimeout(function(){o&&o.unsubscribe()}),i){var n={};if("json"==s.expectedType)try{n=JSON.parse(t.response)}catch(e){n={error:!0,message:"malformated json",raw:t.response}}else n=t.response;var e={};try{e=t.xhr.getAllResponseHeaders().split("\r\n").reduce(function(e,t){t=t.split(":");return e[t[0]]=t[1],e},{})}catch(e){}n&&"malformated json"==n.message&&"json"==s.expectedType?a({status:200,type:n.message,data:n.raw,headers:e}):i({data:n,status:t.status,headers:e})}},function(e){if(setTimeout(function(){o&&o.unsubscribe()}),a){var i,t=e.xhr&&e.xhr.response||"",n={};try{n=e.xhr.getAllResponseHeaders().split("\r\n").reduce(function(e,t){t=t.split(":");return e[t[0]]=t[1],e},{})}catch(e){}403==e.status?a({status:e.status,type:e.type,data:t,headers:n}):e.status&&500<=e.status&&e.status<512?r?a({status:e.status,type:e.type,data:"internal error",headers:n}):u(!0):a&&(r||399<e.status&&e.status<512?a({status:e.status,type:e.type,data:t,headers:n}):(i=qe,new Promise(function(e,t){var n=i({crossDomain:!0,method:"GET",url:Me.internet,timeout:15e3}).subscribe(function(){e(),n&&n.unsubscribe()},function(){t(),n&&n.unsubscribe()})}).then(function(){a&&(r?a({status:e.status,type:e.type,data:t,headers:n}):u(!0))},function(){a&&(s.events&&Ke.emit("$device:no-internet"),a({status:s.events?-1:-10,type:e.type,data:t,headers:n}))})))}});Ge=t=function(){l=i=a=null,o&&(o.unsubscribe(),o=null),Ge===t&&(Ge=null)}};return u(),l.then(function(){Ge===t&&(Ge=null)},function(){Ge===t&&(Ge=null)}),l}function $e(n){return new Promise(function(t,e){qe({crossDomain:!0,responseType:"json",method:"GET",url:n}).subscribe(function(e){t(C(e.response)?e.response:null)},function(e){t({status:e.status,type:e.type,data:e.xhr&&e.xhr.response||""})})})}function Qe(){this._memstorage={},this.enabled||this.useMemory(!0)}Ke.subscribe("$server:captcha-block",function(e){return!He&&void(He=!0)});var Je,Ye,Xe,et,tt=new(Object.defineProperty(Qe.prototype,"_storage",{get:function(){return document.cookie},set:function(e){document.cookie=e},enumerable:!1,configurable:!0}),Qe.prototype.useMemory=function(e){(this._usememstorage=e)||(this._memstorage={})},Qe.prototype.clearMemory=function(){this._memstorage={}},Qe.prototype.get=function(e){if(this._usememstorage||document.cookie){if(this._usememstorage)return this._memstorage[e];for(var t=this._storage.split(";"),n=e+"=",i=0;i<t.length;i++){for(var r=t[i];" "==r.charAt(0);)r=r.substring(1);if(0==r.indexOf(n))return decodeURIComponent(r.substring(n.length,r.length))}}},Qe.prototype.asyncget=function(e){return g()?Promise.resolve(null):Promise.resolve(this.get(e))},Qe.prototype.set=function(e,t,n){if(g()&&console.warn("Cannot set cookies in a cordova app, memory will be used instead"),this._usememstorage&&-1==n)delete this._memstorage[e];else if(this._usememstorage){var i=void 0;if(C(t)||x(t))try{i=JSON.stringify(t)}catch(e){}else i=O(t)?"":t;this._memstorage[e]=i}else{var r=new Date,o=void 0,o=0===n?'expires=""':(n=n||0,r.setTime(r.getTime()+24*n*60*60*1e3),"expires="+r.toUTCString());this._storage=e+"="+t+"; "+(this._usememstorage?"":o+"; path=/; secure; domain=."+window.location.hostname||window.location.host)}},Object.defineProperty(Qe.prototype,"enabled",{get:function(){return!V()&&!1!==navigator.cookieEnabled&&(document.cookie="testcookie=1",-1!=document.cookie.indexOf("testcookie"))},enumerable:!1,configurable:!0}),Qe.prototype.remove=function(e){this.set(e,"",-1)},Qe),nt={};function it(e){var u=e;u.xsrf=("xsrf"in u?u:Ae).xsrf,u.method=("method"in u?u:Ae).method,u.headers=("headers"in u?u:Ae).headers,u.data=u.data||{},u.events=("events"in u?u:Ae).events,u.silent&&(u.events=!1);var h=u.id||R(),a=u.retry||0;return null!==h&&nt[h]&&(nt[h](),delete nt[h],h==Je&&(Je=null)),new Promise(function(t,n){var i=!1,e=!0;if(!(e=O(u.before)&&M(e=u.before())?!0:e))return null;function r(){O(u.after)&&u.after()}function o(e){t(e),r()}function l(e){n(e),r()}function s(){var s,a,t;s=h,t=i,(!(a=u)||"GET"!=a.method&&a.xsrf?tt.asyncget("XSRF-TOKEN").then(function(e){return t||!e?new Promise(function(r,o){(function(o,e){Ye||(Xe=!0,Ye=new Promise(function(n,i){var r=function(t){Ze({url:Re()+"/sid.php",data:{a:"1",buster:R()},method:"GET",events:!e||void 0===e.events||e.events}).then(function(e){Xe=!1,!o||nt[o]?!(e=e.data).error&&e&&C(e)&&e.__whid?n(e.__whid):t?i({status:-1,type:"whiderror",data:e}):r(!0):Ye=!1},function(e){Xe=Ye=!1,o&&!nt[o]||(A(e.status,[-1,-10,999])?i(e):i({status:-1,type:"whiderror",data:e}))})};r(),o&&(nt[o]=Ge)}));return Ye})(s,a).then(function(n){var i=function(t){Ze({data:{action:"get-csrf-token",buster:R()},headers:{"X-XSRF-WHID":n,"Content-Type":"text/html; charset=utf-8"},method:"GET",expectedType:"text",events:!a||void 0===a.events||a.events}).then(function(e){s&&!nt[s]||(_(e=e.data)?r({token:e,whid:n}):t?o({status:400,type:"csrferror",data:e}):i(!0))},function(e){s&&!nt[s]||(A(e.status,[-1,-10,999])?o(e):o({status:400,type:"csrferror",data:e}))})};i(),s&&(nt[s]=Ge)},function(e){o(e)}),s&&(nt[s]=Ge)}):Promise.resolve({token:e})}):new Promise(function(e){e({})})).then(function(e){e.token&&(u.headers["X-XSRF-TOKEN"]=e.token),e.whid&&(u.headers["X-XSRF-WHID"]=e.whid),Ze(u).then(function(e){var t;nt[h]&&(t={data:null,headers:e.headers||{}},e.data&&e.data.maintainance?(u.events&&Ke.emit("$server:maintainance"),u.silent?o({error:!0}):(t.data={status:-1,type:"maintainance",data:null},l(u.readheaders?t:t.data))):e.data&&e.data.apiblocked?(u.events&&Ke.emit("$api:banned"),u.silent?o({error:!0}):(t.data={status:-1,type:"banned",data:null},l(u.readheaders?t:t.data))):(t.data=e.data,o(u.readheaders?t:t.data)),delete nt[h],h==Je&&(Je=null))},c),nt[h]=Ge},function(e){nt[h]&&c(e)}),"POST"===u.method&&u.xsrf||(nt[h]=Ge),Je=h}var c=function(e){if(nt[h]){if(-999==e.status||-10==e.status)return e.status=-10,u.silent?o({error:!0}):l(e),delete nt[h],h==Je&&(Je=null),!1;var t={status:e.status,options:u};if(403==e.status&&"captcha block"!==e.type&&u.events)Ke.emit("$server:banned"),e.type="banned",e.status=-1;else{if(400!==e.status&&0<a)return a--,s(),!1;if(e.status&&(404<=e.status&&e.status<409||500<=e.status&&e.status<512)&&u.events)Ke.emit("$server:error",t),e.type="failed request",e.status=-1;else{if(400==e.status&&u.xsrf&&!i)return i=!0,s(),!1;!u.silent&&u.events&&("csrferror"==e.type?(Ke.emit("$server:csrferror",t),e.status=-1,e.type="failed request"):"whiderror"==e.type&&(Ke.emit("$server:whiderror",t),e.status=-1,e.type="failed request"))}}u.silent||l(e),delete nt[h],h==Je&&(Je=null),u.silent&&o({error:!0})}};s()})}function rt(e){void 0!==e?nt[e]&&(nt[e](),delete nt[e],Je==e&&(Je=null),Xe&&ot()):Je&&nt[Je]&&(nt[Je](),delete nt[Je],Je=null,Xe&&ot())}function ot(){Xe=Ye=!1}function st(){return document.querySelector("web-app #web-app")||document.querySelector("#web-app")}function at(){var e,r=this;this._storage=null,this._types=[".json",".string",".number",".boolean"],this._group="";try{this._storage=!V()&&"localStorage"in window?window.localStorage:null,e=!0}catch(e){this.useMemory(!0)}if(!V()){try{window.localStorage.setItem("test","test"),window.localStorage.removeItem("test")}catch(e){this.useCookieStorage()}if(e&&this._storage==window.localStorage){var o,t=this._storage.getItem("_expirations.json")||null,s=new Date;if(t)try{T(o=JSON.parse(t),function(e,t){if(!e)return!0;for(var n,i=0;i<r._types.length;i++){if(r._storage.getItem(t+r._types[i])){n=!1,s.getTime()-e.since>=e.in&&(r._storage.removeItem(t+r._types[i]),delete o[t]);break}n=!0}n&&delete o[t]});this._storage.setItem("_expirations.json",JSON.stringify(o))}catch(e){}}}}m()?Re(window.location.host):v()?Re(Me.dev):Re(Me.prod);var lt=new(at.prototype.useCookieStorage=function(){var i=this;tt&&tt.enabled?(this._storage={setItem:function(e,t,n){tt.set(e,t,n)},removeItem:function(e){document.cookie=e+"=;expires=Thu, 01 Jan 1970 00:00:01 GMT;"},getItem:function(e){return tt.get(e)}},this.isExpired=function(){return console.warn("not available for cookies"),0},this.removeGroup=function(n){P(function(){for(var e=document.cookie.split(";"),t=[],n=1,i=e.length;n<=i;n++)t[n-1]=y(e[n-1]);return t}(),function(e,t){0==e.indexOf(n+"_")&&i._storage.removeItem(e.split("=")[0])})}):this.useMemory(!0)},at.prototype.useSession=function(e){e&&(this._storage=window.sessionStorage)},at.prototype.useMemory=function(e){var n=this;e&&!et?(et=this._storage,e={_data:{},setItem:function(e,t){return n._storage._data[e]=String(t)},getItem:function(e){return n._storage._data[e]},removeItem:function(e){return delete n._storage._data[e]},clear:function(){return n._storage._data={}}},this._storage=e):(this._storage=et,et=!1)},at.prototype.clearMemory=function(){this._storage&&this._storage.clear&&this._storage.clear()},at.prototype.get=function(e){var t,n,i=e;e=this._group+e;for(var r=0;r<this._types.length;r++){var o=this._types[r];if(this._storage.getItem(e+o)){if(this.isExpired(i))return void this._storage.removeItem(e+o);switch(o){case this._types[0]:case this._types[3]:t=JSON.parse(this._storage.getItem(e+o)),n=!0;break;case this._types[1]:t=this._storage.getItem(e+o),n=!0;break;case this._types[2]:t=parseFloat(this._storage.getItem(e+o)),n=!0}break}}return t="undefined"==(t=!n&&_(this._storage.getItem(e))?this._storage.getItem(e):t)||null==t?void 0:"true"==t||"false"!=t&&t},at.prototype.set=function(e,t,n){var i=e,r="";if("expirations"==e)return!1;e=this._group+e,r=C(t)?(t=JSON.stringify(t),this._types[0]):w(t)?(t=t.toString(),this._types[2]):"boolean"==typeof t?(t=t.toString(),this._types[3]):this._types[1];for(var o=0,s=this._types.length;o<s;o++)if(this._storage.getItem(e+this._types[o])){this._storage.removeItem(e+this._types[o]);break}try{this._storage.setItem(e+r,t)}catch(e){console.warn(e)}n&&this.expire(i,n)},at.prototype.remove=function(e){e=this._group+e;for(var t=0,n=this._types.length;t<n;t++)this._storage.getItem(e+this._types[t])&&this._storage.removeItem(e+this._types[t])},at.prototype.expire=function(e,t){var n,i=this._storage.getItem("_expirations.json")||null;try{n=(n=JSON.parse(i))||{}}catch(e){n={}}n[this._group+e]={in:t,since:(new Date).getTime()},this._storage.setItem("_expirations.json",JSON.stringify(n))},at.prototype.getExpiration=function(e){var t=this._storage.getItem("_expirations.json")||!1;if(!t)return null;try{if(!(t=JSON.parse(t)))return null}catch(e){return null}return t[this._group+e]||null},at.prototype.isExpired=function(e,t){var n=this.getExpiration(e);if(null===n)return 0;e=(new Date).getTime()-n.since;return e>=n.in?1:t?n.in-e:0},at.prototype.group=function(e){if(null==e)return this._group;!1===e&&(this._group=""),this._group=e+"_"},at.prototype.removeGroup=function(t){var n=this;P(Object.keys(this._storage)||[],function(e){0===e.indexOf(t)&&n._storage.removeItem(e)})},at);function ct(e){if(V())return e;var t=document.createTextNode(e.toString()),e=document.createElement("p");return e.appendChild(t),e=e.innerHTML}function ut(){this.store={},this.groups={}}var ht=new(ut.prototype.getKey=function(e){return this.store[e]},ut.prototype.setKey=function(e,t){this.store[e]=t},ut.prototype.group=function(e,t,n){if(t&&!C(t)&&!x(t))throw new TypeError("Data provided is not a plain object or array");return t&&(this.groups[e]=n?JSON.parse(JSON.stringify(t)):t),this.groups[e]||(this.groups[e]={}),this.groups[e]},ut.prototype.hasGroup=function(e){return this.groups.hasOwnProperty(e)},ut.prototype.clearKey=function(e){this.store.hasOwnProperty(e)&&delete this.store[e]},ut.prototype.clearGroup=function(e){"all"==e?this.groups={}:this.groups.hasOwnProperty(e)&&delete this.groups[e]},ut.prototype.clearAll=function(){this.store={},this.groups={}},ut.prototype.pageLoadPopulate=function(){if(m())try{var e=document.querySelectorAll('script[type="application/json"][id*="jsondata-"]');if(0<e.length)for(var t=0,n=e.length;t<n;t++){var i=e[t],r=i.id.replace("jsondata-",""),o=void 0;if(r){try{o=JSON.parse(i.innerHTML)}catch(e){console.warn("could not parse data for "+r)}o&&(this.groups[r]=o)}i.parentNode.removeChild(i)}}catch(e){console.error(e)}},ut),dt=["searchInput"],mt=["mobilebg"],pt=["mobilemenu"],gt=["loansList"],ft=["bankList"],vt=["compList"],yt=["toolsList"],bt=["userList"],_t=["moreList"],St=["cardsList"],wt=["main-header",""];function Et(e,t){var n;1&e&&(n=u.ɵɵgetCurrentView(),u.ɵɵelementStart(0,"i",31),u.ɵɵlistener("onTap",function(e){return u.ɵɵrestoreView(n),u.ɵɵnextContext().disableSearch(e)}),u.ɵɵelementEnd())}function kt(e,t){1&e&&(u.ɵɵelementStart(0,"div",32),u.ɵɵelement(1,"i"),u.ɵɵelementEnd())}function xt(e,t){1&e&&(u.ɵɵelementStart(0,"button",33),u.ɵɵtext(1,"Search"),u.ɵɵelementEnd())}function Pt(e,t){var n;1&e&&(n=u.ɵɵgetCurrentView(),u.ɵɵelementStart(0,"button",34),u.ɵɵlistener("onTap",function(){return u.ɵɵrestoreView(n),u.ɵɵnextContext().disableMobSearch()}),u.ɵɵtext(1,"Cancel"),u.ɵɵelementEnd())}function Ot(e,t){1&e&&u.ɵɵelement(0,"span",52)}function Ct(e,t){1&e&&u.ɵɵelement(0,"span",53)}function Nt(e,t){1&e&&u.ɵɵelement(0,"span",54)}function Tt(e,t){1&e&&(u.ɵɵelementStart(0,"div",48),u.ɵɵtemplate(1,Ot,1,0,"span",49),u.ɵɵtemplate(2,Ct,1,0,"span",50),u.ɵɵtemplate(3,Nt,1,0,"span",51),u.ɵɵelementEnd()),2&e&&(e=u.ɵɵnextContext(2).$implicit,u.ɵɵproperty("ngSwitch",e.label),u.ɵɵadvance(1),u.ɵɵproperty("ngSwitchCase","Answer"),u.ɵɵadvance(1),u.ɵɵproperty("ngSwitchCase","Glossary"),u.ɵɵadvance(1),u.ɵɵproperty("ngSwitchCase","Article"))}function It(e,t){1&e&&u.ɵɵelement(0,"div",55),2&e&&(e=u.ɵɵnextContext(2).$implicit,u.ɵɵproperty("ngClass",e.icon))}function Ft(e,t){1&e&&(u.ɵɵelementStart(0,"div",56),u.ɵɵtext(1),u.ɵɵelementEnd()),2&e&&(e=u.ɵɵnextContext(2).$implicit,u.ɵɵadvance(1),u.ɵɵtextInterpolate(e.symbol))}function Lt(e,t){1&e&&(u.ɵɵelementStart(0,"div",57),u.ɵɵelement(1,"img",58),u.ɵɵelementEnd()),2&e&&(e=u.ɵɵnextContext(2).$implicit,u.ɵɵadvance(1),u.ɵɵproperty("src",e.image,u.ɵɵsanitizeUrl))}function Vt(e,t){1&e&&u.ɵɵelement(0,"span",59),2&e&&(e=u.ɵɵnextContext(2).$implicit,u.ɵɵproperty("innerHtml",e.username,u.ɵɵsanitizeHtml))}function At(e,t){1&e&&u.ɵɵelement(0,"div",59),2&e&&(e=u.ɵɵnextContext(2).$implicit,u.ɵɵproperty("innerHtml",e.label,u.ɵɵsanitizeHtml))}function Mt(e,t){1&e&&(u.ɵɵelementStart(0,"div",41),u.ɵɵtemplate(1,Tt,4,4,"div",42),u.ɵɵtemplate(2,It,1,1,"div",43),u.ɵɵtemplate(3,Ft,2,1,"div",44),u.ɵɵtemplate(4,Lt,2,1,"div",45),u.ɵɵelementStart(5,"div"),u.ɵɵelement(6,"span",46),u.ɵɵtemplate(7,Vt,1,1,"span",47),u.ɵɵelementEnd(),u.ɵɵtemplate(8,At,1,1,"div",47),u.ɵɵelementEnd()),2&e&&(e=u.ɵɵnextContext().$implicit,u.ɵɵadvance(1),u.ɵɵproperty("ngIf","Other"==e.category),u.ɵɵadvance(1),u.ɵɵproperty("ngIf",e.icon),u.ɵɵadvance(1),u.ɵɵproperty("ngIf",e.symbol),u.ɵɵadvance(1),u.ɵɵproperty("ngIf",e.image&&!e.icon),u.ɵɵadvance(2),u.ɵɵproperty("innerHtml",e.name,u.ɵɵsanitizeHtml),u.ɵɵadvance(1),u.ɵɵproperty("ngIf",e.username),u.ɵɵadvance(1),u.ɵɵproperty("ngIf",e.label))}function zt(e,t){1&e&&(u.ɵɵelementStart(0,"span",41),u.ɵɵtext(1),u.ɵɵelementEnd()),2&e&&(e=u.ɵɵnextContext().$implicit,u.ɵɵadvance(1),u.ɵɵtextInterpolate(e.cat))}var Rt=function(e,t){return{"m-ac-li-cat bold-font":e,"m-ac-li-small":t}};function Dt(e,t){var n;1&e&&(n=u.ɵɵgetCurrentView(),u.ɵɵelementStart(0,"li",39),u.ɵɵlistener("onTap",function(){u.ɵɵrestoreView(n);var e=t.$implicit;return u.ɵɵnextContext(2).goToUrl(e.url)})("mouseenter",function(){u.ɵɵrestoreView(n);var e=t.$implicit;return u.ɵɵnextContext(2).changeSearchVal(e)}),u.ɵɵtemplate(1,Mt,9,7,"div",40),u.ɵɵtemplate(2,zt,2,1,"span",40),u.ɵɵelementEnd()),2&e&&(e=t.$implicit,u.ɵɵproperty("ngClass",u.ɵɵpureFunction2(3,Rt,e.cat,e.symbol&&4<e.symbol.length)),u.ɵɵadvance(1),u.ɵɵproperty("ngIf",!e.cat),u.ɵɵadvance(1),u.ɵɵproperty("ngIf",e.cat))}function Bt(e,t){1&e&&(u.ɵɵelementStart(0,"a",60),u.ɵɵtext(1,"Show More Results"),u.ɵɵelementEnd()),2&e&&(e=u.ɵɵnextContext(2),u.ɵɵproperty("zing-url",!0)("href",e.searchUri,u.ɵɵsanitizeUrl))}function jt(e,t){var n;1&e&&(n=u.ɵɵgetCurrentView(),u.ɵɵelementStart(0,"div",35),u.ɵɵlistener("onTap",function(e){return u.ɵɵrestoreView(n),u.ɵɵnextContext().preserveMobSearch(e)})("scroll",function(){return u.ɵɵrestoreView(n),u.ɵɵnextContext().BlurInput()}),u.ɵɵelementStart(1,"ul",36),u.ɵɵtemplate(2,Dt,3,6,"li",37),u.ɵɵelementEnd(),u.ɵɵtemplate(3,Bt,2,2,"a",38),u.ɵɵelementEnd()),2&e&&(e=u.ɵɵnextContext(),u.ɵɵproperty("ngStyle",e.searchResultBoxStyles),u.ɵɵadvance(1),u.ɵɵproperty("ngStyle",e.searchResultStyles),u.ɵɵadvance(1),u.ɵɵproperty("ngForOf",e.resultData)("ngForTrackBy",e.trackByFn),u.ɵɵadvance(1),u.ɵɵproperty("ngIf",e.moreLink))}function Ut(e,t){1&e&&(u.ɵɵelementStart(0,"a",61),u.ɵɵtext(1,"My Wallet"),u.ɵɵelementEnd()),2&e&&u.ɵɵproperty("zing-url",!0)("zing-url-feedback",!0)}function Wt(e,t){1&e&&(u.ɵɵelementStart(0,"a",67),u.ɵɵtext(1),u.ɵɵelementEnd()),2&e&&(t=t.$implicit,u.ɵɵproperty("href",t.url,u.ɵɵsanitizeUrl)("zing-url",!0)("zing-url-feedback",!0),u.ɵɵadvance(1),u.ɵɵtextInterpolate(t.name))}function Ht(e,t){1&e&&(u.ɵɵelementStart(0,"div",64,65),u.ɵɵtemplate(2,Wt,2,4,"a",66),u.ɵɵelementEnd()),2&e&&(e=u.ɵɵnextContext(2),u.ɵɵadvance(2),u.ɵɵproperty("ngForOf",e.menuOptions.Cards)("ngForTrackBy",e.trackByFn))}function Gt(e,t){var n;1&e&&(n=u.ɵɵgetCurrentView(),u.ɵɵelementStart(0,"div",62),u.ɵɵlistener("mouseleave",function(){return u.ɵɵrestoreView(n),u.ɵɵnextContext().ListShow(!1,"cards_list")}),u.ɵɵelementStart(1,"a",63),u.ɵɵlistener("mouseenter",function(){return u.ɵɵrestoreView(n),u.ɵɵnextContext().ListShow(!0,"cards_list")}),u.ɵɵtext(2,"Credit Cards"),u.ɵɵelementEnd(),u.ɵɵtemplate(3,Ht,3,2,"div",22),u.ɵɵelementEnd()),2&e&&(e=u.ɵɵnextContext(),u.ɵɵadvance(1),u.ɵɵclassProp("active",e.cards_list),u.ɵɵproperty("href",e.cc_link,u.ɵɵsanitizeUrl)("zing-url",!0)("zing-url-feedback",!0),u.ɵɵadvance(2),u.ɵɵproperty("ngIf",e.cards_list))}function Kt(e,t){1&e&&(u.ɵɵelementStart(0,"a",68),u.ɵɵtext(1,"Credit Cards"),u.ɵɵelementEnd()),2&e&&(e=u.ɵɵnextContext(),u.ɵɵproperty("href",e.cc_link,u.ɵɵsanitizeUrl)("zing-url",!0)("zing-url-feedback",!0))}function qt(e,t){1&e&&(u.ɵɵelementStart(0,"a",67),u.ɵɵtext(1),u.ɵɵelementEnd()),2&e&&(t=t.$implicit,u.ɵɵproperty("href",t.url,u.ɵɵsanitizeUrl)("zing-url",!0)("zing-url-feedback",!0),u.ɵɵadvance(1),u.ɵɵtextInterpolate(t.name))}function Zt(e,t){1&e&&(u.ɵɵelementStart(0,"div",64,69),u.ɵɵtemplate(2,qt,2,4,"a",66),u.ɵɵelementEnd()),2&e&&(e=u.ɵɵnextContext(),u.ɵɵadvance(2),u.ɵɵproperty("ngForOf",e.menuOptions.Loans)("ngForTrackBy",e.trackByFn))}function $t(e,t){1&e&&(u.ɵɵelementStart(0,"a",67),u.ɵɵtext(1),u.ɵɵelementEnd()),2&e&&(t=t.$implicit,u.ɵɵproperty("href",t.url,u.ɵɵsanitizeUrl)("zing-url",!0)("zing-url-feedback",!0),u.ɵɵadvance(1),u.ɵɵtextInterpolate(t.name))}function Qt(e,t){1&e&&(u.ɵɵelementStart(0,"div",64,70),u.ɵɵtemplate(2,$t,2,4,"a",66),u.ɵɵelementEnd()),2&e&&(e=u.ɵɵnextContext(),u.ɵɵadvance(2),u.ɵɵproperty("ngForOf",e.menuOptions.Banking)("ngForTrackBy",e.trackByFn))}function Jt(e,t){1&e&&(u.ɵɵelementStart(0,"a",67),u.ɵɵtext(1),u.ɵɵelementEnd()),2&e&&(t=t.$implicit,u.ɵɵproperty("href",t.url,u.ɵɵsanitizeUrl)("zing-url",!0)("zing-url-feedback",!0),u.ɵɵadvance(1),u.ɵɵtextInterpolate(t.name))}function Yt(e,t){1&e&&(u.ɵɵelementStart(0,"div",78),u.ɵɵtemplate(1,Jt,2,4,"a",66),u.ɵɵelementEnd()),2&e&&(e=u.ɵɵnextContext(2),u.ɵɵadvance(1),u.ɵɵproperty("ngForOf",e.menuOptions.Banking)("ngForTrackBy",e.trackByFn))}function Xt(e,t){1&e&&(u.ɵɵelementStart(0,"a",67),u.ɵɵtext(1),u.ɵɵelementEnd()),2&e&&(t=t.$implicit,u.ɵɵproperty("href",t.url,u.ɵɵsanitizeUrl)("zing-url",!0)("zing-url-feedback",!0),u.ɵɵadvance(1),u.ɵɵtextInterpolate(t.name))}function en(e,t){1&e&&(u.ɵɵelementStart(0,"div",64,81),u.ɵɵtemplate(2,Xt,2,4,"a",66),u.ɵɵelementEnd()),2&e&&(e=u.ɵɵnextContext(3),u.ɵɵclassProp("ng-enter-element",!e.more_list),u.ɵɵadvance(2),u.ɵɵproperty("ngForOf",e.menuOptions.Companies)("ngForTrackBy",e.trackByFn))}function tn(e,t){1&e&&(u.ɵɵelementContainerStart(0),u.ɵɵelementStart(1,"span",79),u.ɵɵtext(2,"Companies"),u.ɵɵelementEnd(),u.ɵɵtemplate(3,en,3,4,"div",80),u.ɵɵelementContainerEnd()),2&e&&(e=u.ɵɵnextContext(2),u.ɵɵadvance(3),u.ɵɵproperty("ngIf",e.comp_list))}function nn(e,t){1&e&&(u.ɵɵelementStart(0,"a",67),u.ɵɵtext(1),u.ɵɵelementEnd()),2&e&&(t=t.$implicit,u.ɵɵproperty("href",t.url,u.ɵɵsanitizeUrl)("zing-url",!0)("zing-url-feedback",!0),u.ɵɵadvance(1),u.ɵɵtextInterpolate(t.name))}function rn(e,t){1&e&&(u.ɵɵelementStart(0,"div",82),u.ɵɵtemplate(1,nn,2,4,"a",66),u.ɵɵelementEnd()),2&e&&(e=u.ɵɵnextContext(2),u.ɵɵadvance(1),u.ɵɵproperty("ngForOf",e.menuOptions.Loans)("ngForTrackBy",e.trackByFn))}function on(e,t){1&e&&(u.ɵɵelementStart(0,"a",67),u.ɵɵtext(1),u.ɵɵelementEnd()),2&e&&(t=t.$implicit,u.ɵɵproperty("href",t.url,u.ɵɵsanitizeUrl)("zing-url",!0)("zing-url-feedback",!0),u.ɵɵadvance(1),u.ɵɵtextInterpolate(t.name))}function sn(e,t){1&e&&(u.ɵɵelementStart(0,"div",84,85),u.ɵɵtemplate(2,on,2,4,"a",66),u.ɵɵelementEnd()),2&e&&(e=u.ɵɵnextContext(3),u.ɵɵclassProp("ng-enter-element",!e.more_list),u.ɵɵadvance(2),u.ɵɵproperty("ngForOf",e.menuOptions.Tools)("ngForTrackBy",e.trackByFn))}function an(e,t){1&e&&(u.ɵɵelementContainerStart(0),u.ɵɵelementStart(1,"span",79),u.ɵɵtext(2,"Tools"),u.ɵɵelementEnd(),u.ɵɵtemplate(3,sn,3,4,"div",83),u.ɵɵelementContainerEnd()),2&e&&(e=u.ɵɵnextContext(2),u.ɵɵadvance(3),u.ɵɵproperty("ngIf",e.tools_list))}function ln(e,t){var n;1&e&&(n=u.ɵɵgetCurrentView(),u.ɵɵelementStart(0,"div",71,72),u.ɵɵlistener("onTapHover",function(){return u.ɵɵrestoreView(n),u.ɵɵnextContext().DelayListShow(!0,"more_list")})("mouseleave",function(){return u.ɵɵrestoreView(n),u.ɵɵnextContext().DelayListShow(!1,"more_list")}),u.ɵɵelementStart(2,"div",62),u.ɵɵlistener("mouseleave",function(){return u.ɵɵrestoreView(n),u.ɵɵnextContext().CompListShow(!1,"comp_list")}),u.ɵɵelementStart(3,"span",73),u.ɵɵtext(4,"Banking"),u.ɵɵelementEnd(),u.ɵɵtemplate(5,Yt,2,2,"div",74),u.ɵɵelementStart(6,"span",21),u.ɵɵlistener("onTapHover",function(e){return u.ɵɵrestoreView(n),u.ɵɵnextContext().CompListShow("mobiletoggle","comp_list",e)}),u.ɵɵtext(7,"Companies"),u.ɵɵelementEnd(),u.ɵɵtemplate(8,tn,4,1,"ng-container",75),u.ɵɵelementEnd(),u.ɵɵelementStart(9,"div",62),u.ɵɵlistener("mouseleave",function(){return u.ɵɵrestoreView(n),u.ɵɵnextContext().CompListShow(!1,"tools_list")}),u.ɵɵelementStart(10,"span",76),u.ɵɵtext(11,"Loans"),u.ɵɵelementEnd(),u.ɵɵtemplate(12,rn,2,2,"div",77),u.ɵɵelementStart(13,"span",21),u.ɵɵlistener("onTapHover",function(e){return u.ɵɵrestoreView(n),u.ɵɵnextContext().CompListShow("mobiletoggle","tools_list",e)}),u.ɵɵtext(14,"Tools"),u.ɵɵelementEnd(),u.ɵɵtemplate(15,an,4,1,"ng-container",75),u.ɵɵelementEnd(),u.ɵɵelementEnd()),2&e&&(e=u.ɵɵnextContext(),u.ɵɵclassProp("ng-enter-element",!e.desktop_more_list),u.ɵɵadvance(5),u.ɵɵproperty("ngIf",!e.simple_version),u.ɵɵadvance(1),u.ɵɵclassProp("active",e.comp_list),u.ɵɵadvance(2),u.ɵɵproperty("ngIf",!e.simple_version),u.ɵɵadvance(4),u.ɵɵproperty("ngIf",!e.simple_version),u.ɵɵadvance(1),u.ɵɵclassProp("active",e.comp_list),u.ɵɵadvance(2),u.ɵɵproperty("ngIf",!e.simple_version))}function cn(e,t){1&e&&(u.ɵɵelementStart(0,"a",67),u.ɵɵtext(1,"Profile"),u.ɵɵelementEnd()),2&e&&(e=u.ɵɵnextContext(3),u.ɵɵproperty("href",e.userLoggedInData.url,u.ɵɵsanitizeUrl)("zing-url",!0)("zing-url-feedback",!0))}function un(e,t){var n;1&e&&(n=u.ɵɵgetCurrentView(),u.ɵɵelementStart(0,"div",88,89),u.ɵɵtemplate(2,cn,2,3,"a",90),u.ɵɵelementStart(3,"a",91),u.ɵɵtext(4,"Settings"),u.ɵɵelementEnd(),u.ɵɵelementStart(5,"span",92),u.ɵɵlistener("onTap",function(e){return u.ɵɵrestoreView(n),u.ɵɵnextContext(2).logOut(e)}),u.ɵɵtext(6,"Logout"),u.ɵɵelementEnd(),u.ɵɵelementEnd()),2&e&&(e=u.ɵɵnextContext(2),u.ɵɵadvance(2),u.ɵɵproperty("ngIf",e.userLoggedInData.upr),u.ɵɵadvance(1),u.ɵɵproperty("zing-url",!0)("zing-url-feedback",!0))}function hn(e,t){var n;1&e&&(n=u.ɵɵgetCurrentView(),u.ɵɵelementStart(0,"div",86),u.ɵɵlistener("mouseleave",function(){return u.ɵɵrestoreView(n),u.ɵɵnextContext().ListShow(!1,"user_list")}),u.ɵɵelementStart(1,"span",21),u.ɵɵlistener("onTapHover",function(e){return u.ɵɵrestoreView(n),u.ɵɵnextContext().ListShow("mobiletoggle","user_list",e)}),u.ɵɵtext(2),u.ɵɵelementEnd(),u.ɵɵtemplate(3,un,7,3,"div",87),u.ɵɵelementEnd()),2&e&&(e=u.ɵɵnextContext(),u.ɵɵadvance(1),u.ɵɵclassProp("active",e.user_list),u.ɵɵadvance(1),u.ɵɵtextInterpolate(e.userLoggedInData.name),u.ɵɵadvance(1),u.ɵɵproperty("ngIf",e.user_list))}function dn(e,t){var n;1&e&&(n=u.ɵɵgetCurrentView(),u.ɵɵelementStart(0,"span",93),u.ɵɵlistener("onTap",function(){return u.ɵɵrestoreView(n),u.ɵɵnextContext().goToLogin()}),u.ɵɵtext(1,"Login"),u.ɵɵelementEnd()),2&e&&u.ɵɵproperty("zing-url-feedback",!0)}function mn(e,t){1&e&&(u.ɵɵelementStart(0,"a",94),u.ɵɵtext(1,"Sign Up"),u.ɵɵelementEnd()),2&e&&u.ɵɵproperty("zing-url",!0)("zing-url-feedback",!0)}function pn(e,t){1&e&&(u.ɵɵelementStart(0,"div",101),u.ɵɵelementStart(1,"a",102),u.ɵɵtext(2,"My Wallet"),u.ɵɵelementEnd(),u.ɵɵelementStart(3,"a",103),u.ɵɵtext(4,"Credit Cards"),u.ɵɵelementEnd(),u.ɵɵelementStart(5,"span",104),u.ɵɵtext(6,"Loans"),u.ɵɵelementEnd(),u.ɵɵelementEnd()),2&e&&(e=u.ɵɵnextContext(2),u.ɵɵadvance(1),u.ɵɵproperty("zing-url",!0)("zing-url-feedback",!0),u.ɵɵadvance(2),u.ɵɵproperty("href",e.cc_link,u.ɵɵsanitizeUrl)("zing-url",!0)("zing-url-feedback",!0))}function gn(e,t){var n;1&e&&(n=u.ɵɵgetCurrentView(),u.ɵɵelementStart(0,"div",105,106),u.ɵɵlistener("onTap",function(){return u.ɵɵrestoreView(n),u.ɵɵnextContext(2).ToggleMobileMenu(!1)}),u.ɵɵelementEnd()),2&e&&(e=u.ɵɵnextContext(2),u.ɵɵproperty("ng-hidden",!e.open_mobile_menu)("zing-tap-delay",10))}function fn(e,t){1&e&&(u.ɵɵelementStart(0,"a",121),u.ɵɵtext(1,"My Wallet"),u.ɵɵelementEnd()),2&e&&u.ɵɵproperty("zing-url",!0)("zing-url-feedback",!0)}function vn(e,t){var n;1&e&&(n=u.ɵɵgetCurrentView(),u.ɵɵelementStart(0,"span",113),u.ɵɵlistener("onTap",function(){return u.ɵɵrestoreView(n),u.ɵɵnextContext(3).MobileMenuExtra("sett")}),u.ɵɵtext(1,"Settings"),u.ɵɵelementEnd())}function yn(e,t){1&e&&(u.ɵɵelementStart(0,"a",129),u.ɵɵtext(1,"Profile"),u.ɵɵelementEnd()),2&e&&(e=u.ɵɵnextContext(4),u.ɵɵproperty("href",e.userLoggedInData.url,u.ɵɵsanitizeUrl)("zing-url",!0)("zing-url-feedback",!0))}function bn(e,t){1&e&&(u.ɵɵelementStart(0,"span"),u.ɵɵtext(1,"|"),u.ɵɵelementEnd())}function _n(e,t){var n;1&e&&(n=u.ɵɵgetCurrentView(),u.ɵɵelementStart(0,"div",122),u.ɵɵelement(1,"img",123),u.ɵɵelementStart(2,"div",124),u.ɵɵelementStart(3,"div",125),u.ɵɵtext(4),u.ɵɵelementEnd(),u.ɵɵelementStart(5,"div",126),u.ɵɵtemplate(6,yn,2,3,"a",127),u.ɵɵtemplate(7,bn,2,0,"span",75),u.ɵɵelementStart(8,"span",128),u.ɵɵlistener("onTap",function(e){return u.ɵɵrestoreView(n),u.ɵɵnextContext(3).logOut(e)}),u.ɵɵtext(9,"Logout"),u.ɵɵelementEnd(),u.ɵɵelementEnd(),u.ɵɵelementEnd(),u.ɵɵelementEnd()),2&e&&(e=u.ɵɵnextContext(3),u.ɵɵadvance(1),u.ɵɵproperty("src",e.userLoggedInData.avatar,u.ɵɵsanitizeUrl),u.ɵɵattribute("alt",e.userLoggedInData.name),u.ɵɵadvance(3),u.ɵɵtextInterpolate(e.userLoggedInData.name),u.ɵɵadvance(2),u.ɵɵproperty("ngIf",e.userLoggedInData.upr),u.ɵɵadvance(1),u.ɵɵproperty("ngIf",e.userLoggedInData.upr),u.ɵɵadvance(1),u.ɵɵclassProp("no-first",!e.userLoggedInData.upr))}function Sn(e,t){1&e&&(u.ɵɵelementStart(0,"div",130),u.ɵɵelementStart(1,"a",131),u.ɵɵtext(2,"Login"),u.ɵɵelementEnd(),u.ɵɵelementStart(3,"a",132),u.ɵɵtext(4,"Sign Up for Free"),u.ɵɵelementEnd(),u.ɵɵelementEnd()),2&e&&(u.ɵɵadvance(1),u.ɵɵproperty("zing-url",!0)("zing-url-feedback",!0),u.ɵɵadvance(2),u.ɵɵproperty("zing-url",!0)("zing-url-feedback",!0))}function wn(e,t){1&e&&(u.ɵɵelementStart(0,"a",112),u.ɵɵtext(1),u.ɵɵelementEnd()),2&e&&(t=t.$implicit,u.ɵɵproperty("href",t.url,u.ɵɵsanitizeUrl)("zing-url",!0)("zing-url-feedback",!0),u.ɵɵadvance(1),u.ɵɵtextInterpolate(t.name))}function En(e,t){1&e&&(u.ɵɵelementStart(0,"a",112),u.ɵɵtext(1),u.ɵɵelementEnd()),2&e&&(t=t.$implicit,u.ɵɵproperty("href",t.url,u.ɵɵsanitizeUrl)("zing-url",!0)("zing-url-feedback",!0),u.ɵɵadvance(1),u.ɵɵtextInterpolate(t.name))}function kn(e,t){1&e&&(u.ɵɵelementStart(0,"a",112),u.ɵɵtext(1),u.ɵɵelementEnd()),2&e&&(t=t.$implicit,u.ɵɵproperty("href",t.url,u.ɵɵsanitizeUrl)("zing-url",!0)("zing-url-feedback",!0),u.ɵɵadvance(1),u.ɵɵtextInterpolate(t.name))}function xn(e,t){1&e&&(u.ɵɵelementStart(0,"a",112),u.ɵɵtext(1),u.ɵɵelementEnd()),2&e&&(t=t.$implicit,u.ɵɵproperty("href",t.url,u.ɵɵsanitizeUrl)("zing-url",!0)("zing-url-feedback",!0),u.ɵɵadvance(1),u.ɵɵtextInterpolate(t.name))}function Pn(e,t){1&e&&(u.ɵɵelementStart(0,"a",112),u.ɵɵtext(1),u.ɵɵelementEnd()),2&e&&(t=t.$implicit,u.ɵɵproperty("href",t.url,u.ɵɵsanitizeUrl)("zing-url",!0)("zing-url-feedback",!0),u.ɵɵadvance(1),u.ɵɵtextInterpolate(t.name))}function On(e,t){var n;1&e&&(n=u.ɵɵgetCurrentView(),u.ɵɵelementStart(0,"div",117),u.ɵɵelementStart(1,"div",118),u.ɵɵlistener("onTap",function(){return u.ɵɵrestoreView(n),u.ɵɵnextContext(3).MobileMenuExtra("sett")}),u.ɵɵtext(2,"Settings"),u.ɵɵelementEnd(),u.ɵɵtemplate(3,Pn,2,4,"a",119),u.ɵɵelementEnd()),2&e&&(e=u.ɵɵnextContext(3),u.ɵɵclassProp("brgmm-display",e.open_mobile_menu_sett),u.ɵɵadvance(3),u.ɵɵproperty("ngForOf",e.menuOptions.Settings)("ngForTrackBy",e.trackByFn))}function Cn(e,t){var n;1&e&&(n=u.ɵɵgetCurrentView(),u.ɵɵelementStart(0,"div",107,108),u.ɵɵelementStart(2,"div",109),u.ɵɵlistener("onTap",function(){return u.ɵɵrestoreView(n),u.ɵɵnextContext(2).ToggleMobileMenu(!1)}),u.ɵɵelementEnd(),u.ɵɵelementStart(3,"span",110),u.ɵɵlistener("onTap",function(e){return u.ɵɵrestoreView(n),u.ɵɵnextContext(2).MobileSearch(e)}),u.ɵɵtext(4,"Search"),u.ɵɵelementEnd(),u.ɵɵtemplate(5,fn,2,2,"a",111),u.ɵɵelementStart(6,"a",112),u.ɵɵtext(7,"Credit Cards"),u.ɵɵelementEnd(),u.ɵɵelementStart(8,"span",113),u.ɵɵlistener("onTap",function(){return u.ɵɵrestoreView(n),u.ɵɵnextContext(2).MobileMenuExtra("loans")}),u.ɵɵtext(9,"Loans"),u.ɵɵelementEnd(),u.ɵɵelementStart(10,"span",113),u.ɵɵlistener("onTap",function(){return u.ɵɵrestoreView(n),u.ɵɵnextContext(2).MobileMenuExtra("bank")}),u.ɵɵtext(11,"Banking"),u.ɵɵelementEnd(),u.ɵɵelementStart(12,"span",113),u.ɵɵlistener("onTap",function(){return u.ɵɵrestoreView(n),u.ɵɵnextContext(2).MobileMenuExtra("comp")}),u.ɵɵtext(13,"Companies"),u.ɵɵelementEnd(),u.ɵɵelementStart(14,"span",113),u.ɵɵlistener("onTap",function(){return u.ɵɵrestoreView(n),u.ɵɵnextContext(2).MobileMenuExtra("tools")}),u.ɵɵtext(15,"Tools"),u.ɵɵelementEnd(),u.ɵɵtemplate(16,vn,2,0,"span",114),u.ɵɵtemplate(17,_n,10,7,"div",115),u.ɵɵtemplate(18,Sn,5,4,"div",116),u.ɵɵelementStart(19,"div",117),u.ɵɵelementStart(20,"div",118),u.ɵɵlistener("onTap",function(){return u.ɵɵrestoreView(n),u.ɵɵnextContext(2).MobileMenuExtra("loans")}),u.ɵɵtext(21,"Loans"),u.ɵɵelementEnd(),u.ɵɵtemplate(22,wn,2,4,"a",119),u.ɵɵelementEnd(),u.ɵɵelementStart(23,"div",117),u.ɵɵelementStart(24,"div",118),u.ɵɵlistener("onTap",function(){return u.ɵɵrestoreView(n),u.ɵɵnextContext(2).MobileMenuExtra("bank")}),u.ɵɵtext(25,"Banking"),u.ɵɵelementEnd(),u.ɵɵtemplate(26,En,2,4,"a",119),u.ɵɵelementEnd(),u.ɵɵelementStart(27,"div",117),u.ɵɵelementStart(28,"div",118),u.ɵɵlistener("onTap",function(){return u.ɵɵrestoreView(n),u.ɵɵnextContext(2).MobileMenuExtra("comp")}),u.ɵɵtext(29,"Companies"),u.ɵɵelementEnd(),u.ɵɵtemplate(30,kn,2,4,"a",119),u.ɵɵelementEnd(),u.ɵɵelementStart(31,"div",117),u.ɵɵelementStart(32,"div",118),u.ɵɵlistener("onTap",function(){return u.ɵɵrestoreView(n),u.ɵɵnextContext(2).MobileMenuExtra("tools")}),u.ɵɵtext(33,"Tools"),u.ɵɵelementEnd(),u.ɵɵtemplate(34,xn,2,4,"a",119),u.ɵɵelementEnd(),u.ɵɵtemplate(35,On,4,4,"div",120),u.ɵɵelementEnd()),2&e&&(e=u.ɵɵnextContext(2),u.ɵɵclassProp("brgmm-display",e.open_mobile_menu),u.ɵɵadvance(5),u.ɵɵproperty("ngIf",e.isLoggedIn),u.ɵɵadvance(1),u.ɵɵproperty("href",e.cc_link,u.ɵɵsanitizeUrl)("zing-url",!0)("zing-url-feedback",!0),u.ɵɵadvance(10),u.ɵɵproperty("ngIf",e.isLoggedIn),u.ɵɵadvance(1),u.ɵɵproperty("ngIf",e.isLoggedIn),u.ɵɵadvance(1),u.ɵɵproperty("ngIf",!e.isLoggedIn),u.ɵɵadvance(1),u.ɵɵclassProp("brgmm-display",e.open_mobile_menu_loans),u.ɵɵadvance(3),u.ɵɵproperty("ngForOf",e.menuOptions.Loans)("ngForTrackBy",e.trackByFn),u.ɵɵadvance(1),u.ɵɵclassProp("brgmm-display",e.open_mobile_menu_bank),u.ɵɵadvance(3),u.ɵɵproperty("ngForOf",e.menuOptions.Banking)("ngForTrackBy",e.trackByFn),u.ɵɵadvance(1),u.ɵɵclassProp("brgmm-display",e.open_mobile_menu_comp),u.ɵɵadvance(3),u.ɵɵproperty("ngForOf",e.menuOptions.Companies)("ngForTrackBy",e.trackByFn),u.ɵɵadvance(1),u.ɵɵclassProp("brgmm-display",e.open_mobile_menu_tools),u.ɵɵadvance(3),u.ɵɵproperty("ngForOf",e.menuOptions.Tools)("ngForTrackBy",e.trackByFn),u.ɵɵadvance(1),u.ɵɵproperty("ngIf",e.isLoggedIn))}function Nn(e,t){var n;1&e&&(n=u.ɵɵgetCurrentView(),u.ɵɵelementStart(0,"nav",95),u.ɵɵtemplate(1,pn,7,5,"div",96),u.ɵɵelementStart(2,"span",97),u.ɵɵlistener("onTap",function(){return u.ɵɵrestoreView(n),u.ɵɵnextContext().ToggleMobileMenu()}),u.ɵɵelement(3,"i",98),u.ɵɵelementEnd(),u.ɵɵtemplate(4,gn,2,2,"div",99),u.ɵɵtemplate(5,Cn,36,26,"div",100),u.ɵɵelementEnd()),2&e&&(e=u.ɵɵnextContext(),u.ɵɵclassProp("brgmm-guest-user",!e.isLoggedIn)("brgmrm-display",e.open_mobile_menu),u.ɵɵadvance(1),u.ɵɵproperty("ngIf",e.isLoggedIn),u.ɵɵadvance(3),u.ɵɵproperty("ngIf",e.mobile_menu_on),u.ɵɵadvance(1),u.ɵɵproperty("ngIf",e.mobile_menu_on))}function Tn(e,t){1&e&&(u.ɵɵelementStart(0,"form",133),u.ɵɵelement(1,"input",134),u.ɵɵelement(2,"input",135),u.ɵɵelement(3,"input",136),u.ɵɵelementEnd()),2&e&&(e=u.ɵɵnextContext(),u.ɵɵadvance(1),u.ɵɵproperty("value",e.logout_redirect),u.ɵɵadvance(1),u.ɵɵproperty("value",e.csrf_token))}function In(e,t,n){return{"tp-hd-sc-enable":e,"tp-hd-sc-logged-in":t,"tp-hd-sc-mob-enable":n}}var Fn=(Ln.prototype._windowResize=function(){var t=this;j(function(){t.setSearchResultStyles(),t._MobileTrackWindow();var e=window.innerWidth;if(t._lastwsize){if(t._lastwsize==e)return null;t._lastwsize=e}else t._lastwsize=e;t.searchMobEnabled&&(t.searchMobEnabled=!1),t.isDesktopSize()&&(t.searchVal=""),t.desktop_more_list=950<=e})},Ln.prototype._ScrollWatch=function(){var n,i,r=this,o=this._headerSect.nativeElement,s=o.clientHeight,e=0,a=0,l=0,t=this._AppContainer,c=o.parentElement.querySelector("[data-ng-sub-nav]");!t||this._dservice.overwrite_to_body||c&&(c.clientHeight,c.clientHeight),this._scrollSubscriber=this._dservice.onScroll.pipe(u.delay(50)).subscribe(function(t){r._dservice.scrollable&&(n=e<t?"down":"up",c||(c=o.parentElement.querySelector("[data-ng-sub-nav]"))&&!r._dservice.overwrite_to_body&&(c.clientHeight,c.clientHeight),e=t,j(function(){var e=null;"down"==n?(e=Math.max(-1*(t-l),-1*s),a=t,i=e,r.more_list=!1,r.comp_list=!1,r.bank_list=!1,r.loan_list=!1,r.tools_list=!1,r.user_list=!1,r.cards_list=!1):"up"==n&&(e=(l=t)?Math.min(0,i+Math.min(s,a-t)):0),null!==e&&(o.style.transform="translate3d(0,"+e+"px,0 )",o.style.webkitTransform="translate3d(0,"+e+"px,0 )",c&&(c.style.transform="translate3d(0,"+e+"px,0 )",c.style.webkitTransform="translate3d(0,"+e+"px,0 )"),r._dservice.overwrite_to_body),!r._dservice.overwrite_to_body||r._dservice.overwrite_to_body&&null!==e?(e=s- -1*e,Ke.emit("header:position-change",e)):Ke.emit("header:position-change",s)}))})},Ln.prototype.ngOnInit=function(){var e,n=this;ht.getKey("simple-render")&&(this.simple_version=!0),V()?this.desktop_more_list=!0:(Ke.subscribe("header:visibility",function(e){n._headerSect.nativeElement.style.zIndex=e?"":-1}),Ke.subscribe("header:reset-position",function(){var e=n._headerSect.nativeElement,t=e.parentElement.querySelector("[data-ng-sub-nav]");e.style.transform="translate3d(0,0px,0 )",e.style.webkitTransform="translate3d(0,0px,0 )",t&&(t.style.transform="translate3d(0,0px,0 )",t.style.webkitTransform="translate3d(0,0px,0 )")}),1==tt.get("mw_prequal_offers")&&(this.menuOptions.Loans[3].url="/home/loans-for-me"),Ke.keepValueFor("header:position-change"),e=this._searchValue.pipe(u.debounceTime(500),u.map(ct)).subscribe(function(e){n.getSearchResults(e),n.searchUri="/search/?s="+e},function(){},function(){e&&e.unsubscribe()}),this.setSearchResultStyles(),this.desktop_more_list=950<=window.innerWidth)},Ln.prototype.ngAfterViewInit=function(){var e;V()||(e=null,U()&&(e={passive:!0}),window.addEventListener("resize",this._windowResize,e),this._AppContainer=st(),this._ScrollWatch(),this._lastwsize=window.innerWidth)},Ln.prototype.ngOnDestroy=function(){V()||(this._windowResize&&window.removeEventListener("resize",this._windowResize),rt("header-web-search"),Ke.terminate("header:position-change"),Ke.terminate("header:position-behind"),Ke.terminate("header:visibility"),Ke.terminate("header:reset-position")),this._searchValue.complete();try{this._scrollSubscriber&&this._scrollSubscriber.unsubscribe()}catch(e){}},Ln.prototype.setSearchResultStyles=function(e){var t=window.innerHeight-150-37+"px";this.searchResultBoxStyles={},this.isDesktopSize()||(t="",this.searchResultBoxStyles["max-height"]=window.innerHeight-this._headerSect.nativeElement.offsetHeight+"px"),this.searchResultStyles={"max-height":t}},Ln.prototype.goToUrl=function(e){null!=(e=void 0===e?null:e)&&(window.location.href=e)},Ln.prototype.logIn=function(e){this.isLoggedIn=!0,this.homeUrl="/home/dashboard/"},Ln.prototype.logOut=function(e){this.logout_redirect=window.location.href,this.csrf_token=tt.get("XSRF-TOKEN"),lt.remove("has-sess"),lt.remove("crd"),lt.remove("vs"),setTimeout(function(){document.querySelector("form#logout-form").submit()}),this.homeUrl="/"},Ln.prototype.goToLogin=function(){window.open(this._loginurl,"_self")},Ln.prototype.Input=function(e){e=e.target.value;(this.searchVal=e).length<3?(this.resultData=[],this.autoCompleteStart=!1,this.showResult=!1):(this.showResult=!0,this._searchValue.next(e),this.autoCompleteStart=!0)},Ln.prototype.changeSearchVal=function(e){e=(e.username||e.name||"").replace(/<\/?[^>]+(>|$)/g,"");e&&(this.searchVal=e)},Ln.prototype._parseData=function(e){this.autoCompleteStart=!1;var t=[],n="";if(C(e)&&w(e.total)&&x(e.terms)){e.total>e.terms.length?this.moreLink=!0:this.moreLink=!1;for(var i=e.terms,r=0;r<i.length;r++)i[r].category!=n&&(t.push({cat:i[r].category}),n=i[r].category),i[r].st&&(i[r].icon="wh-icon black icon-"+i[r].st),i[r].username&&(i[r].username="@"+i[r].username),t.push(i[r])}else this.moreLink=!1;this.resultData=t},Ln.prototype.getSearchResults=function(e){var t=this;void 0===e&&(e=null),rt("header-web-search"),it({method:"GET",url:"/ac/",id:"header-web-search",data:{v2:!0,term:e},events:!1,needs_session:!1}).then(function(e){t._parseData(e)},function(e){t.autoCompleteStart=!1})},Ln.prototype.enableSearch=function(e){this.searchEnabled=!0},Ln.prototype.disableSearch=function(e){var t=this;this.searchEnabled=!1,this.searchVal="",setTimeout(function(){t.resultData=[]},300)},Ln.prototype.disableMobSearch=function(){this.disableSearch(),this.searchMobEnabled=!1},Ln.prototype.preserveMobSearch=function(e){e.type.indexOf("mouse")<0&&e.stopPropagation()},Ln.prototype.BlurInput=function(){var e=document.activeElement;e&&e.tagName&&"input"==e.tagName.toLowerCase()&&e.blur()},Ln.prototype.isDesktopSize=function(){return!!(this.isLoggedIn&&691<window.innerWidth||!this.isLoggedIn&&688<window.innerWidth)},Ln.prototype.ListShow=function(e,s,t){var a,n,l=this;"mobiletoggle"==e&&t&&(e="mouseenter"==t.type||!this[s]),(this[s]=e)?(e=void 0,"loan_list"==s?e=this.loansList:"bank_list"==s?e=this.bankList:"comp_list"==s?e=this.compList:"tools_list"==s?e=this.toolsList:"user_list"==s?e=this.userList:"more_list"==s?e=this.moreList:"cards_list"==s&&(e=this.cardsList),"more_list"==s&&((n=window.innerWidth)<950&&(this.ListShow(!0,"comp_list"),this.ListShow(!0,"tools_list")),n<740&&this.ListShow(!0,"loan_list")),a=e.changes.subscribe(function(e){var o;e&&e.first&&(o=e.first,j(function(){var e,t,n,i,r;a.unsubscribe(),l[s]&&(t=(e=o.nativeElement).getBoundingClientRect(),r=document.body,n=e.offsetLeft,i=r.clientWidth||window.innerWidth,r=r.clientHeight||window.innerHeight,t.right>i&&(e.style.left=-1*(t.right-n-i)+"px"),t.bottom>r?e.style.maxHeight=e.offsetHeight-(t.bottom-r)+"px":e.style.maxHeight=e.offsetHeight+(r-t.bottom)+"px")}))})):"more_list"==s&&((n=window.innerWidth)<950&&(this.ListShow(!1,"comp_list"),this.ListShow(!1,"tools_list")),n<740&&this.ListShow(!0,"loan_list"))},Ln.prototype.CompListShow=function(e,t,n){var i=window.innerWidth;(1019<i&&this.isLoggedIn||949<i&&!this.isLoggedIn||"more_list"==t)&&this.ListShow(e,t)},Ln.prototype.DelayListShow=function(e,t,n){var i=this;clearTimeout(this.delayedStates[t]),this.delayedStates[t]=setTimeout(function(){i.ListShow(e,t,n)},50)},Ln.prototype.ToggleMobileMenu=function(e){var t=this;this.mobile_menu_on=!0,setTimeout(function(){j(function(){t.open_mobile_menu=!t.open_mobile_menu,"boolean"==typeof e&&(t.open_mobile_menu=e),t._MobileTrackWindow(),t._dservice.canScroll(!t.open_mobile_menu),!1===e&&(t.open_mobile_menu_loans=!1,t.open_mobile_menu_bank=!1,t.open_mobile_menu_comp=!1,t.open_mobile_menu_tools=!1,t.open_mobile_menu_sett=!1)})},!1===e?50:1)},Ln.prototype._MobileTrackWindow=function(){var e,t;this.open_mobile_menu&&(e=this.mobileBg.nativeElement,t=this.mobileMenu.nativeElement,e.style.height=window.innerHeight-this._headerSect.nativeElement.offsetHeight+"px",t.style.height=window.innerHeight+"px")},Ln.prototype.MobileMenuExtra=function(e,t){this["open_mobile_menu_"+e]="boolean"==typeof t?t:!this["open_mobile_menu_"+e]},Ln.prototype.MobileSearch=function(e){var t=this;this.enableSearch(),this.searchMobEnabled=!0,this.ToggleMobileMenu(!1),this.searchInput.nativeElement.focus(),j(function(){t.searchInput.nativeElement.focus()}),e.stopPropagation()},Ln.prototype.trackByFn=function(e){return e},Ln.ɵfac=function(e){return new(e||Ln)(u.ɵɵdirectiveInject(u.ElementRef),u.ɵɵdirectiveInject(te))},Ln.ɵcmp=u.ɵɵdefineComponent({type:Ln,selectors:[["header","main-header",""]],viewQuery:function(e,t){1&e&&(u.ɵɵviewQuery(dt,!0),u.ɵɵviewQuery(mt,!0),u.ɵɵviewQuery(pt,!0),u.ɵɵviewQuery(gt,!0,u.ElementRef),u.ɵɵviewQuery(ft,!0,u.ElementRef),u.ɵɵviewQuery(vt,!0,u.ElementRef),u.ɵɵviewQuery(yt,!0,u.ElementRef),u.ɵɵviewQuery(bt,!0,u.ElementRef),u.ɵɵviewQuery(_t,!0,u.ElementRef),u.ɵɵviewQuery(St,!0,u.ElementRef)),2&e&&(u.ɵɵqueryRefresh(e=u.ɵɵloadQuery())&&(t.searchInput=e.first),u.ɵɵqueryRefresh(e=u.ɵɵloadQuery())&&(t.mobileBg=e.first),u.ɵɵqueryRefresh(e=u.ɵɵloadQuery())&&(t.mobileMenu=e.first),u.ɵɵqueryRefresh(e=u.ɵɵloadQuery())&&(t.loansList=e),u.ɵɵqueryRefresh(e=u.ɵɵloadQuery())&&(t.bankList=e),u.ɵɵqueryRefresh(e=u.ɵɵloadQuery())&&(t.compList=e),u.ɵɵqueryRefresh(e=u.ɵɵloadQuery())&&(t.toolsList=e),u.ɵɵqueryRefresh(e=u.ɵɵloadQuery())&&(t.userList=e),u.ɵɵqueryRefresh(e=u.ɵɵloadQuery())&&(t.moreList=e),u.ɵɵqueryRefresh(e=u.ɵɵloadQuery())&&(t.cardsList=e))},attrs:wt,decls:37,vars:38,consts:[[1,"top-header-nav"],[1,"top-header-logo"],["zing-touch","",1,"top-header-logo-link",3,"zing-url","href"],[1,"w-icon-wallet"],[1,"w-icon-txt"],[1,"logo-anchor-text"],[1,"top-header-search",3,"ngClass"],["method","GET","action","/search/",1,"label-input","input-icon","full","blend","tall-lbl-input"],[1,"tp-hd-sc-ic","af-icon-search","lbl"],["type","text","placeholder","Search","name","s","autocomplete","off","zing-touch","","aria-label","Site Search",1,"tp-hd-sc-input","textfield",3,"value","input","focus","onTapDoc"],["searchInput",""],["class","tp-hd-sc-cross lbl-b","zing-touch","",3,"onTap",4,"ngIf"],["class","progress-indicator visible",4,"ngIf"],["type","submit","class","btn tp-hd-sc-btn basic-trans bold-font",4,"ngIf"],["type","button","class","btn tp-hd-sc-cancel regular-font","zing-touch","",3,"onTap",4,"ngIf"],["class","dda","id","m-ac","zing-touch","",3,"ngStyle","onTap","scroll",4,"ngIf"],[1,"burger-menu-right-menu"],["class","brgm-button","href","/home/dashboard","zing-touch","",3,"zing-url","zing-url-feedback",4,"ngIf"],["class","brgm-button brgm-list-box",3,"mouseleave",4,"ngIf"],["class","brgm-button","zing-touch","",3,"href","zing-url","zing-url-feedback",4,"ngIf"],[1,"brgm-button","brgm-list-box","brgm-cl-third-hide",3,"mouseleave"],["zing-touch","",1,"brgm-list-title",3,"onTapHover"],["class","brgm-list ng-enter-element",4,"ngIf"],[1,"brgm-button","brgm-list-box","brgm-cl-second-hide",3,"mouseleave"],["zing-touch","",1,"brgm-button","brgm-cl-button",3,"onTapHover","mouseleave"],["class","brgm-compact-lists","zing-touch","",3,"ng-enter-element","onTapHover","mouseleave",4,"ngIf"],["class","brgm-button brgm-user brgm-list-box",3,"mouseleave",4,"ngIf"],["class","brgm-button brgm-signup","zing-touch","",3,"zing-url-feedback","onTap",4,"ngIf"],["class","brgm-button brgm-signup","zing-touch","","href","/join/",3,"zing-url","zing-url-feedback",4,"ngIf"],["class","burger-menu-right-mobile",3,"brgmm-guest-user","brgmrm-display",4,"ngIf"],["action","/logout/","method","post","id","logout-form",4,"ngIf"],["zing-touch","",1,"tp-hd-sc-cross","lbl-b",3,"onTap"],[1,"progress-indicator","visible"],["type","submit",1,"btn","tp-hd-sc-btn","basic-trans","bold-font"],["type","button","zing-touch","",1,"btn","tp-hd-sc-cancel","regular-font",3,"onTap"],["id","m-ac","zing-touch","",1,"dda",3,"ngStyle","onTap","scroll"],[1,"m-ac-ul",3,"ngStyle"],["class","m-ac-li","zing-touch","",3,"ngClass","onTap","mouseenter",4,"ngFor","ngForOf","ngForTrackBy"],["class","m-ac-more","zing-touch","",3,"zing-url","zing-url-feedback","href",4,"ngIf"],["zing-touch","",1,"m-ac-li",3,"ngClass","onTap","mouseenter"],["class","",4,"ngIf"],[1,""],["class","m-ac-symbol",3,"ngSwitch",4,"ngIf"],["class","m-ac-symbol",3,"ngClass",4,"ngIf"],["class","m-ac-symbol",4,"ngIf"],["class","img",4,"ngIf"],[3,"innerHtml"],["class","m-ac-label",3,"innerHtml",4,"ngIf"],[1,"m-ac-symbol",3,"ngSwitch"],["class","wh-icon thumb-answer",4,"ngSwitchCase"],["class","wh-icon thumb-glossary",4,"ngSwitchCase"],["class","wh-icon thumb-article",4,"ngSwitchCase"],[1,"wh-icon","thumb-answer"],[1,"wh-icon","thumb-glossary"],[1,"wh-icon","thumb-article"],[1,"m-ac-symbol",3,"ngClass"],[1,"m-ac-symbol"],[1,"img"],[3,"src"],[1,"m-ac-label",3,"innerHtml"],["zing-touch","",1,"m-ac-more",3,"zing-url","zing-url-feedback","href"],["href","/home/dashboard","zing-touch","",1,"brgm-button",3,"zing-url","zing-url-feedback"],[1,"brgm-button","brgm-list-box",3,"mouseleave"],["zing-touch","",1,"brgm-list-title",3,"href","zing-url","zing-url-feedback","mouseenter"],[1,"brgm-list","ng-enter-element"],["cardsList",""],["class","brgm-list-it","zing-touch","",3,"href","zing-url","zing-url-feedback",4,"ngFor","ngForOf","ngForTrackBy"],["zing-touch","",1,"brgm-list-it",3,"href","zing-url","zing-url-feedback"],["zing-touch","",1,"brgm-button",3,"href","zing-url","zing-url-feedback"],["loansList",""],["bankList",""],["zing-touch","",1,"brgm-compact-lists",3,"onTapHover","mouseleave"],["moreList",""],[1,"brgm-cl-title","brgm-cl-second-show"],["class","brgm-list brgm-cl-second-show",4,"ngIf"],[4,"ngIf"],[1,"brgm-cl-title","brgm-cl-third-show"],["class","brgm-list brgm-cl-third-show",4,"ngIf"],[1,"brgm-list","brgm-cl-second-show"],[1,"brgm-cl-title"],["class","brgm-list ng-enter-element",3,"ng-enter-element",4,"ngIf"],["compList",""],[1,"brgm-list","brgm-cl-third-show"],["class","brgm-list","style","left: 7px",3,"ng-enter-element",4,"ngIf"],[1,"brgm-list",2,"left","7px"],["toolsList",""],[1,"brgm-button","brgm-user","brgm-list-box",3,"mouseleave"],["class","brgm-list brgm-user-list ng-enter-element",4,"ngIf"],[1,"brgm-list","brgm-user-list","ng-enter-element"],["userList",""],["class","brgm-list-it","zing-touch","",3,"href","zing-url","zing-url-feedback",4,"ngIf"],["href","/home/settings","zing-touch","",1,"brgm-list-it",3,"zing-url","zing-url-feedback"],["zing-touch","",1,"brgm-list-it",3,"onTap"],["zing-touch","",1,"brgm-button","brgm-signup",3,"zing-url-feedback","onTap"],["zing-touch","","href","/join/",1,"brgm-button","brgm-signup",3,"zing-url","zing-url-feedback"],[1,"burger-menu-right-mobile"],["class","brgmm-imp-links",4,"ngIf"],["zing-touch","",1,"brgmm-toggle",3,"onTap"],[1,"brgmm-line"],["class","brgmm-backside","zing-touch","",3,"ng-hidden","zing-tap-delay","onTap",4,"ngIf"],["class","brgmm-content",3,"brgmm-display",4,"ngIf"],[1,"brgmm-imp-links"],["href","/home/dashboard","zing-touch","",1,"brgm-button","brgmm-bt",3,"zing-url","zing-url-feedback"],["zing-touch","",1,"brgm-button","brgmm-bt",3,"href","zing-url","zing-url-feedback"],[1,"brgm-button","brgmm-bt","brgmm-bt-last"],["zing-touch","",1,"brgmm-backside",3,"ng-hidden","zing-tap-delay","onTap"],["mobilebg",""],[1,"brgmm-content"],["mobilemenu",""],["zing-touch","",1,"brgmm-close","bf-icon-cross-slim",3,"onTap"],["zing-touch","",1,"brgms-button","bf-icon-search","brgms-src-ic",3,"onTap"],["class","brgms-button","href","/home/dashboard","zing-touch","",3,"zing-url","zing-url-feedback",4,"ngIf"],["zing-touch","",1,"brgms-button",3,"href","zing-url","zing-url-feedback"],["zing-touch","",1,"brgms-button","brgms-list-bt","af-icon-right-open-big",3,"onTap"],["class","brgms-button brgms-list-bt af-icon-right-open-big","zing-touch","",3,"onTap",4,"ngIf"],["class","brgm-user-info",4,"ngIf"],["class","brgm-guest-info",4,"ngIf"],[1,"brgm-content-extra"],["zing-touch","",1,"brgms-button","brgm-ctex-title","semi-bold-font","bf-icon-left-open-big",3,"onTap"],["class","brgms-button","zing-touch","",3,"href","zing-url","zing-url-feedback",4,"ngFor","ngForOf","ngForTrackBy"],["class","brgm-content-extra",3,"brgmm-display",4,"ngIf"],["href","/home/dashboard","zing-touch","",1,"brgms-button",3,"zing-url","zing-url-feedback"],[1,"brgm-user-info"],[1,"brgm-user-img",3,"src"],[1,"brgm-user-act"],[1,"brgm-user-nm"],[1,"brgm-user-bts"],["class","link brgmu-lnk","zing-touch","",3,"href","zing-url","zing-url-feedback",4,"ngIf"],["zing-touch","",1,"link","brgmu-lnk-2",3,"onTap"],["zing-touch","",1,"link","brgmu-lnk",3,"href","zing-url","zing-url-feedback"],[1,"brgm-guest-info"],["href","/join/login","zing-touch","",1,"btn","blue","no-decoration","btn-guest-inf","bold-font",3,"zing-url","zing-url-feedback"],["href","/join/","zing-touch","",1,"btn","blue","no-decoration","btn-guest-inf","bold-font",3,"zing-url","zing-url-feedback"],["action","/logout/","method","post","id","logout-form"],["type","hidden","name","redirect_to",3,"value"],["type","hidden","name","XSRF-TOKEN",3,"value"],["type","submit","id","logout-button","value","submit"]],template:function(e,t){1&e&&(u.ɵɵelementStart(0,"div",0),u.ɵɵelementStart(1,"div",1),u.ɵɵelementStart(2,"a",2),u.ɵɵelement(3,"span",3),u.ɵɵelement(4,"span",4),u.ɵɵelementStart(5,"span",5),u.ɵɵtext(6,"WalletHub"),u.ɵɵelementEnd(),u.ɵɵelementEnd(),u.ɵɵelementEnd(),u.ɵɵelementStart(7,"div",6),u.ɵɵelementStart(8,"form",7),u.ɵɵelement(9,"i",8),u.ɵɵelementStart(10,"input",9,10),u.ɵɵlistener("input",function(e){return t.Input(e)})("focus",function(e){return t.enableSearch(e)})("onTapDoc",function(e){return t.disableSearch(e)}),u.ɵɵelementEnd(),u.ɵɵtemplate(12,Et,1,0,"i",11),u.ɵɵtemplate(13,kt,2,0,"div",12),u.ɵɵtemplate(14,xt,2,0,"button",13),u.ɵɵtemplate(15,Pt,2,0,"button",14),u.ɵɵelementEnd(),u.ɵɵelementEnd(),u.ɵɵtemplate(16,jt,4,5,"div",15),u.ɵɵelementStart(17,"nav",16),u.ɵɵtemplate(18,Ut,2,2,"a",17),u.ɵɵtemplate(19,Gt,4,6,"div",18),u.ɵɵtemplate(20,Kt,2,3,"a",19),u.ɵɵelementStart(21,"div",20),u.ɵɵlistener("mouseleave",function(){return t.ListShow(!1,"loan_list")}),u.ɵɵelementStart(22,"span",21),u.ɵɵlistener("onTapHover",function(e){return t.ListShow("mobiletoggle","loan_list",e)}),u.ɵɵtext(23,"Loans"),u.ɵɵelementEnd(),u.ɵɵtemplate(24,Zt,3,2,"div",22),u.ɵɵelementEnd(),u.ɵɵelementStart(25,"div",23),u.ɵɵlistener("mouseleave",function(){return t.ListShow(!1,"bank_list")}),u.ɵɵelementStart(26,"span",21),u.ɵɵlistener("onTapHover",function(e){return t.ListShow("mobiletoggle","bank_list",e)}),u.ɵɵtext(27,"Banking"),u.ɵɵelementEnd(),u.ɵɵtemplate(28,Qt,3,2,"div",22),u.ɵɵelementEnd(),u.ɵɵelementStart(29,"div",24),u.ɵɵlistener("onTapHover",function(e){return t.DelayListShow("mobiletoggle","more_list",e)})("mouseleave",function(){return t.DelayListShow(!1,"more_list")}),u.ɵɵtext(30,"More"),u.ɵɵelementEnd(),u.ɵɵtemplate(31,ln,16,10,"div",25),u.ɵɵtemplate(32,hn,4,4,"div",26),u.ɵɵtemplate(33,dn,2,1,"span",27),u.ɵɵtemplate(34,mn,2,2,"a",28),u.ɵɵelementEnd(),u.ɵɵtemplate(35,Nn,6,7,"nav",29),u.ɵɵelementEnd(),u.ɵɵtemplate(36,Tn,4,2,"form",30)),2&e&&(u.ɵɵclassProp("thn-guest-user",!t.isLoggedIn),u.ɵɵadvance(2),u.ɵɵproperty("zing-url",!0)("href",t.homeUrl,u.ɵɵsanitizeUrl),u.ɵɵadvance(5),u.ɵɵproperty("ngClass",u.ɵɵpureFunction3(34,In,t.searchEnabled,t.isLoggedIn,t.searchMobEnabled)),u.ɵɵadvance(1),u.ɵɵclassProp("both",t.searchEnabled)("front",!t.searchEnabled),u.ɵɵadvance(2),u.ɵɵproperty("value",t.searchVal),u.ɵɵadvance(2),u.ɵɵproperty("ngIf",!(t.autoCompleteStart||!t.searchEnabled)),u.ɵɵadvance(1),u.ɵɵproperty("ngIf",t.autoCompleteStart),u.ɵɵadvance(1),u.ɵɵproperty("ngIf",t.searchEnabled),u.ɵɵadvance(1),u.ɵɵproperty("ngIf",t.searchMobEnabled),u.ɵɵadvance(1),u.ɵɵproperty("ngIf",(t.searchEnabled||t.searchMobEnabled)&&0<t.resultData.length&&t.showResult),u.ɵɵadvance(1),u.ɵɵclassProp("brgm-guest-user",!t.isLoggedIn),u.ɵɵadvance(1),u.ɵɵproperty("ngIf",t.isLoggedIn),u.ɵɵadvance(1),u.ɵɵproperty("ngIf",!t.isLoggedIn),u.ɵɵadvance(1),u.ɵɵproperty("ngIf",t.isLoggedIn),u.ɵɵadvance(2),u.ɵɵclassProp("active",t.loan_list),u.ɵɵadvance(2),u.ɵɵproperty("ngIf",t.loan_list),u.ɵɵadvance(2),u.ɵɵclassProp("active",t.bank_list),u.ɵɵadvance(2),u.ɵɵproperty("ngIf",t.bank_list),u.ɵɵadvance(1),u.ɵɵclassProp("active",t.comp_list),u.ɵɵadvance(2),u.ɵɵproperty("ngIf",t.more_list||t.desktop_more_list),u.ɵɵadvance(1),u.ɵɵproperty("ngIf",t.isLoggedIn),u.ɵɵadvance(1),u.ɵɵproperty("ngIf",!t.isLoggedIn&&t.is_web),u.ɵɵadvance(1),u.ɵɵproperty("ngIf",!t.isLoggedIn&&t.is_web),u.ɵɵadvance(1),u.ɵɵproperty("ngIf",!t.simple_version),u.ɵɵadvance(1),u.ɵɵproperty("ngIf",t.is_web))},directives:[K,u.NgClass,u.NgIf,u.NgStyle,u.NgForOf,u.NgSwitch,u.NgSwitchCase,fe],encapsulation:2}),Ln);function Ln(e,t){this._headerSect=e,this._dservice=t,this.searchVal="",this.homeUrl="/",this.isLoggedIn=!1,this.userLoggedInData={name:"",url:"",avatar:"",alerts:10},this.searchUri="/search/?s=",this.autoCompleteStart=!1,this.showResult=!1,this._searchValue=new u.Subject,this.searchEnabled=!1,this.searchMobEnabled=!1,this.resultData=[],this.moreLink=!1,this.is_full_user=!1,this.cc_link="/credit-cards/",this.menuOptions={Loans:[{name:"Car Loans",url:"/car-loans/rates"},{name:"Home Equity Loans",url:"/home-equity-loans"},{name:"Mortgages",url:"/mortgage-rates"},{name:"Personal Loans",url:"/personal-loans"}],Banking:[{name:"CDs / Savings",url:"/savings-accounts"},{name:"Checking",url:"/checking-accounts"},{name:"Prepaid Cards",url:"/prepaid-debit-cards"}],Tools:[{name:"Answers",url:"/answers/"},{name:"Calculators",url:"/calculators"},{name:"WalletLiteracy",url:"/wallet-literacy-score/"},{name:"Articles & Studies",url:"/edu"},{url:"/free-credit-score",name:"Free Credit Score"},{url:"/free-credit-report",name:"Free Credit Report"},{url:"/free-credit-monitoring",name:"Free Credit Monitoring"}],Companies:[{name:"Attorneys",url:"/attorneys"},{name:"Banks",url:"/banks"},{name:"Credit Unions",url:"/credit-unions"},{name:"Financial Advisors",url:"/financial-advisors"},{name:"Car Insurance",url:"/car-insurance"},{name:"Insurance Agents",url:"/insurance-agents"},{name:"Mortgage Providers",url:"/mortgage-lenders"},{name:"Real Estate Agents",url:"/real-estate-agents"}],Settings:[{name:"Public Info",url:"/home/settings/public-info"},{name:"Private Into",url:"/home/settings/private-info"},{name:"Login Settings",url:"/home/settings/login"},{name:"Notifications",url:"/home/settings/notifications"},{name:"Invite Your Friends",url:"/home/settings/invite"}],Cards:[{name:"Compare Cards",url:"/credit-cards/compare/"},{name:"Editors' Best",url:"/best-credit-cards"},{name:"CardAdvisor™",url:"/cardadvisor/"},{name:"Payoff Calculator",url:"/credit-card-calculator"}]},this.is_web=m(),this.simple_version=!1,this._lastwsize=0,this.loan_list=!1,this.bank_list=!1,this.comp_list=!1,this.tools_list=!1,this.user_list=!1,this.more_list=!1,this.desktop_more_list=!1,this.cards_list=!1,this.delayedStates={},this.open_mobile_menu=!1,this.open_mobile_menu_loans=!1,this.open_mobile_menu_bank=!1,this.open_mobile_menu_comp=!1,this.open_mobile_menu_tools=!1,this.open_mobile_menu_sett=!1,this.mobile_menu_on=!1,!V()&&tt.get("mw_signon")&&(this.isLoggedIn=!0,this.cc_link+="/compare/",t=JSON.parse(tt.get("mw_signon")),this.userLoggedInData={name:t.ucrn,avatar:t.pp,url:"/profile/"+t.id+"i",upr:t.upr},this.is_full_user=lt.get("full"),this.userLoggedInData.url||this.menuOptions.Settings.splice(0,1),this.is_full_user||this.menuOptions.Settings.splice(0,1)),V()||(this.logout_redirect=window.location.href,this._loginurl="/join/login?redirect_to="+window.location.href,this._windowResize=this._windowResize.bind(this))}u.setClassMetadata(Fn,[{type:u.Component,args:[{selector:"header[main-header]",template:r.headerTpl}]}],function(){return[{type:u.ElementRef},{type:te}]},{searchInput:[{type:u.ViewChild,args:["searchInput",{static:!1}]}],loansList:[{type:u.ViewChildren,args:["loansList",{read:u.ElementRef}]}],bankList:[{type:u.ViewChildren,args:["bankList",{read:u.ElementRef}]}],compList:[{type:u.ViewChildren,args:["compList",{read:u.ElementRef}]}],toolsList:[{type:u.ViewChildren,args:["toolsList",{read:u.ElementRef}]}],userList:[{type:u.ViewChildren,args:["userList",{read:u.ElementRef}]}],moreList:[{type:u.ViewChildren,args:["moreList",{read:u.ElementRef}]}],cardsList:[{type:u.ViewChildren,args:["cardsList",{read:u.ElementRef}]}],mobileBg:[{type:u.ViewChild,args:["mobilebg",{static:!1}]}],mobileMenu:[{type:u.ViewChild,args:["mobilemenu",{static:!1}]}]});var Vn=(An.ɵmod=u.ɵɵdefineNgModule({type:An}),An.ɵinj=u.ɵɵdefineInjector({factory:function(e){return new(e||An)},imports:[[Fe,u.CommonModule]]}),An);function An(){}u.setClassMetadata(Vn,[{type:u.NgModule,args:[{declarations:[Fn],exports:[Fn],imports:[Fe,u.CommonModule]}]}],null,null);var Mn=o("systemjs");function zn(){var i=p(),r={captureException:function(e){console.error(e)},captureMessage:function(e,t){console.info(e)},withScope:function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t]},Severity:{},addBreadcrumb:function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t]}};return new Promise(function(n,e){i?n(r):Mn.import("package:/system/raven-lib").then(function(e){var t,e=e.Raven;i?n(r):(V()||("--"==(t={id:lt.get("support_id")||"--",username:lt.get("pub_id")||"--"}).id&&"--"!==t.username&&(t.id=t.username,delete t.username),"--"!==t.username&&(e.configureScope?e.configureScope(function(e){e.setExtra("id",t.id),e.setExtra("username",t.username)}):e.setUserContext(t))),n(e))},function(e){console.warn("Cannot load raven js library"),console.error(e),n(r)})})}var Rn=(Dn.prototype.handleError=function(n){zn().then(function(e){var t=n.originalError||n;t&&(e.captureException(t),console.error(t))})},Dn);function Dn(){}var Bn,jn,Un,Wn=function(a){function n(){}var e={},t=e.lib={},i=t.Base={extend:function(e){n.prototype=this;var t=new n;return e&&t.mixIn(e),t.hasOwnProperty("init")||(t.init=function(){t.$super.init.apply(this,arguments)}),(t.init.prototype=t).$super=this,t},create:function(){var e=this.extend();return e.init.apply(e,arguments),e},init:function(){},mixIn:function(e){for(var t in e)e.hasOwnProperty(t)&&(this[t]=e[t]);e.hasOwnProperty("toString")&&(this.toString=e.toString)},clone:function(){return this.init.prototype.extend(this)}},l=t.WordArray=i.extend({init:function(e,t){e=this.words=e||[],this.sigBytes=null!=t?t:4*e.length},toString:function(e){return(e||o).stringify(this)},concat:function(e){var t=this.words,n=e.words,i=this.sigBytes;if(e=e.sigBytes,this.clamp(),i%4)for(var r=0;r<e;r++)t[i+r>>>2]|=(n[r>>>2]>>>24-r%4*8&255)<<24-(i+r)%4*8;else if(65535<n.length)for(r=0;r<e;r+=4)t[i+r>>>2]=n[r>>>2];else t.push.apply(t,n);return this.sigBytes+=e,this},clamp:function(){var e=this.words,t=this.sigBytes;e[t>>>2]&=4294967295<<32-t%4*8,e.length=a.ceil(t/4)},clone:function(){var e=i.clone.call(this);return e.words=this.words.slice(0),e},random:function(e){for(var t=[],n=0;n<e;n+=4)t.push(4294967296*a.random()|0);return new l.init(t,e)}}),r=e.enc={},o=r.Hex={stringify:function(e){var t=e.words;e=e.sigBytes;for(var n=[],i=0;i<e;i++){var r=t[i>>>2]>>>24-i%4*8&255;n.push((r>>>4).toString(16)),n.push((15&r).toString(16))}return n.join("")},parse:function(e){for(var t=e.length,n=[],i=0;i<t;i+=2)n[i>>>3]|=parseInt(e.substr(i,2),16)<<24-i%8*4;return new l.init(n,t/2)}},s=r.Latin1={stringify:function(e){var t=e.words;e=e.sigBytes;for(var n=[],i=0;i<e;i++)n.push(String.fromCharCode(t[i>>>2]>>>24-i%4*8&255));return n.join("")},parse:function(e){for(var t=e.length,n=[],i=0;i<t;i++)n[i>>>2]|=(255&e.charCodeAt(i))<<24-i%4*8;return new l.init(n,t)}},c=r.Utf8={stringify:function(e){try{return decodeURIComponent(escape(s.stringify(e)))}catch(e){throw Error("Malformed UTF-8 data")}},parse:function(e){return s.parse(unescape(encodeURIComponent(e)))}},u=t.BufferedBlockAlgorithm=i.extend({reset:function(){this._data=new l.init,this._nDataBytes=0},_append:function(e){"string"==typeof e&&(e=c.parse(e)),this._data.concat(e),this._nDataBytes+=e.sigBytes},_process:function(e){var t=this._data,n=t.words,i=t.sigBytes,r=this.blockSize,o=i/(4*r);if(e=(o=e?a.ceil(o):a.max((0|o)-this._minBufferSize,0))*r,i=a.min(4*e,i),e){for(var s=0;s<e;s+=r)this._doProcessBlock(n,s);s=n.splice(0,e),t.sigBytes-=i}return new l.init(s,i)},clone:function(){var e=i.clone.call(this);return e._data=this._data.clone(),e},_minBufferSize:0});t.Hasher=u.extend({cfg:i.extend(),init:function(e){this.cfg=this.cfg.extend(e),this.reset()},reset:function(){u.reset.call(this),this._doReset()},update:function(e){return this._append(e),this._process(),this},finalize:function(e){return e&&this._append(e),this._doFinalize()},blockSize:16,_createHelper:function(n){return function(e,t){return new n.init(t).finalize(e)}},_createHmacHelper:function(n){return function(e,t){return new h.HMAC.init(n,t).finalize(e)}}});var h=e.algo={};return e}(Math);Bn=Wn.lib.WordArray,Wn.enc.Base64={stringify:function(e){var t=e.words,n=e.sigBytes,i=this._map;e.clamp(),e=[];for(var r=0;r<n;r+=3)for(var o=(t[r>>>2]>>>24-r%4*8&255)<<16|(t[r+1>>>2]>>>24-(r+1)%4*8&255)<<8|t[r+2>>>2]>>>24-(r+2)%4*8&255,s=0;s<4&&r+.75*s<n;s++)e.push(i.charAt(o>>>6*(3-s)&63));if(t=i.charAt(64))for(;e.length%4;)e.push(t);return e.join("")},parse:function(e){var t=e.length,n=this._map;!(o=n.charAt(64))||-1!=(o=e.indexOf(o))&&(t=o);for(var i,r,o=[],s=0,a=0;a<t;a++)a%4&&(i=n.indexOf(e.charAt(a-1))<<a%4*2,r=n.indexOf(e.charAt(a))>>>6-a%4*2,o[s>>>2]|=(i|r)<<24-s%4*8,s++);return Bn.create(o,s)},_map:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/="},function(o){function E(e,t,n,i,r,o,s){return((e=e+(t&n|~t&i)+r+s)<<o|e>>>32-o)+t}function k(e,t,n,i,r,o,s){return((e=e+(t&i|n&~i)+r+s)<<o|e>>>32-o)+t}function x(e,t,n,i,r,o,s){return((e=e+(t^n^i)+r+s)<<o|e>>>32-o)+t}function P(e,t,n,i,r,o,s){return((e=e+(n^(t|~i))+r+s)<<o|e>>>32-o)+t}for(var e=Wn,t=(i=e.lib).WordArray,n=i.Hasher,i=e.algo,O=[],r=0;r<64;r++)O[r]=4294967296*o.abs(o.sin(r+1))|0;i=i.MD5=n.extend({_doReset:function(){this._hash=new t.init([1732584193,4023233417,2562383102,271733878])},_doProcessBlock:function(e,t){for(var n=0;n<16;n++){var i=e[r=t+n];e[r]=16711935&(i<<8|i>>>24)|4278255360&(i<<24|i>>>8)}var n=this._hash.words,r=e[t+0],i=e[t+1],o=e[t+2],s=e[t+3],a=e[t+4],l=e[t+5],c=e[t+6],u=e[t+7],h=e[t+8],d=e[t+9],m=e[t+10],p=e[t+11],g=e[t+12],f=e[t+13],v=e[t+14],y=e[t+15],b=E(b=n[0],w=n[1],S=n[2],_=n[3],r,7,O[0]),_=E(_,b,w,S,i,12,O[1]),S=E(S,_,b,w,o,17,O[2]),w=E(w,S,_,b,s,22,O[3]),b=E(b,w,S,_,a,7,O[4]),_=E(_,b,w,S,l,12,O[5]),S=E(S,_,b,w,c,17,O[6]),w=E(w,S,_,b,u,22,O[7]),b=E(b,w,S,_,h,7,O[8]),_=E(_,b,w,S,d,12,O[9]),S=E(S,_,b,w,m,17,O[10]),w=E(w,S,_,b,p,22,O[11]),b=E(b,w,S,_,g,7,O[12]),_=E(_,b,w,S,f,12,O[13]),S=E(S,_,b,w,v,17,O[14]),b=k(b,w=E(w,S,_,b,y,22,O[15]),S,_,i,5,O[16]),_=k(_,b,w,S,c,9,O[17]),S=k(S,_,b,w,p,14,O[18]),w=k(w,S,_,b,r,20,O[19]),b=k(b,w,S,_,l,5,O[20]),_=k(_,b,w,S,m,9,O[21]),S=k(S,_,b,w,y,14,O[22]),w=k(w,S,_,b,a,20,O[23]),b=k(b,w,S,_,d,5,O[24]),_=k(_,b,w,S,v,9,O[25]),S=k(S,_,b,w,s,14,O[26]),w=k(w,S,_,b,h,20,O[27]),b=k(b,w,S,_,f,5,O[28]),_=k(_,b,w,S,o,9,O[29]),S=k(S,_,b,w,u,14,O[30]),b=x(b,w=k(w,S,_,b,g,20,O[31]),S,_,l,4,O[32]),_=x(_,b,w,S,h,11,O[33]),S=x(S,_,b,w,p,16,O[34]),w=x(w,S,_,b,v,23,O[35]),b=x(b,w,S,_,i,4,O[36]),_=x(_,b,w,S,a,11,O[37]),S=x(S,_,b,w,u,16,O[38]),w=x(w,S,_,b,m,23,O[39]),b=x(b,w,S,_,f,4,O[40]),_=x(_,b,w,S,r,11,O[41]),S=x(S,_,b,w,s,16,O[42]),w=x(w,S,_,b,c,23,O[43]),b=x(b,w,S,_,d,4,O[44]),_=x(_,b,w,S,g,11,O[45]),S=x(S,_,b,w,y,16,O[46]),b=P(b,w=x(w,S,_,b,o,23,O[47]),S,_,r,6,O[48]),_=P(_,b,w,S,u,10,O[49]),S=P(S,_,b,w,v,15,O[50]),w=P(w,S,_,b,l,21,O[51]),b=P(b,w,S,_,g,6,O[52]),_=P(_,b,w,S,s,10,O[53]),S=P(S,_,b,w,m,15,O[54]),w=P(w,S,_,b,i,21,O[55]),b=P(b,w,S,_,h,6,O[56]),_=P(_,b,w,S,y,10,O[57]),S=P(S,_,b,w,c,15,O[58]),w=P(w,S,_,b,f,21,O[59]),b=P(b,w,S,_,a,6,O[60]),_=P(_,b,w,S,p,10,O[61]),S=P(S,_,b,w,o,15,O[62]),w=P(w,S,_,b,d,21,O[63]);n[0]=n[0]+b|0,n[1]=n[1]+w|0,n[2]=n[2]+S|0,n[3]=n[3]+_|0},_doFinalize:function(){var e=this._data,t=e.words,n=8*this._nDataBytes,i=8*e.sigBytes;t[i>>>5]|=128<<24-i%32;var r=o.floor(n/4294967296);for(t[15+(64+i>>>9<<4)]=16711935&(r<<8|r>>>24)|4278255360&(r<<24|r>>>8),t[14+(64+i>>>9<<4)]=16711935&(n<<8|n>>>24)|4278255360&(n<<24|n>>>8),e.sigBytes=4*(t.length+1),this._process(),t=(e=this._hash).words,n=0;n<4;n++)i=t[n],t[n]=16711935&(i<<8|i>>>24)|4278255360&(i<<24|i>>>8);return e},clone:function(){var e=n.clone.call(this);return e._hash=this._hash.clone(),e}}),e.MD5=n._createHelper(i),e.HmacMD5=n._createHmacHelper(i)}(Math),Kr=(qr=Wn).lib,Gr=Kr.Base,jn=Kr.WordArray,Un=(Kr=qr.algo).EvpKDF=Gr.extend({cfg:Gr.extend({keySize:4,hasher:Kr.MD5,iterations:1}),init:function(e){this.cfg=this.cfg.extend(e)},compute:function(e,t){for(var n=(s=this.cfg).hasher.create(),i=jn.create(),r=i.words,o=s.keySize,s=s.iterations;r.length<o;){a&&n.update(a);var a=n.update(e).finalize(t);n.reset();for(var l=1;l<s;l++)a=n.finalize(a),n.reset();i.concat(a)}return i.sigBytes=4*o,i}}),qr.EvpKDF=function(e,t,n){return Un.create(n).compute(e,t)},Wn.lib.Cipher||function(){var e=(d=Wn).lib,t=e.Base,s=e.WordArray,n=e.BufferedBlockAlgorithm,i=d.enc.Base64,r=d.algo.EvpKDF,o=e.Cipher=n.extend({cfg:t.extend(),createEncryptor:function(e,t){return this.create(this._ENC_XFORM_MODE,e,t)},createDecryptor:function(e,t){return this.create(this._DEC_XFORM_MODE,e,t)},init:function(e,t,n){this.cfg=this.cfg.extend(n),this._xformMode=e,this._key=t,this.reset()},reset:function(){n.reset.call(this),this._doReset()},process:function(e){return this._append(e),this._process()},finalize:function(e){return e&&this._append(e),this._doFinalize()},keySize:4,ivSize:4,_ENC_XFORM_MODE:1,_DEC_XFORM_MODE:2,_createHelper:function(i){return{encrypt:function(e,t,n){return("string"==typeof t?m:h).encrypt(i,e,t,n)},decrypt:function(e,t,n){return("string"==typeof t?m:h).decrypt(i,e,t,n)}}}});function a(e,t,n){var i=this._iv;i?this._iv=void 0:i=this._prevBlock;for(var r=0;r<n;r++)e[t+r]^=i[r]}e.StreamCipher=o.extend({_doFinalize:function(){return this._process(!0)},blockSize:1});var l=d.mode={},c=(e.BlockCipherMode=t.extend({createEncryptor:function(e,t){return this.Encryptor.create(e,t)},createDecryptor:function(e,t){return this.Decryptor.create(e,t)},init:function(e,t){this._cipher=e,this._iv=t}})).extend();c.Encryptor=c.extend({processBlock:function(e,t){var n=this._cipher,i=n.blockSize;a.call(this,e,t,i),n.encryptBlock(e,t),this._prevBlock=e.slice(t,t+i)}}),c.Decryptor=c.extend({processBlock:function(e,t){var n=this._cipher,i=n.blockSize,r=e.slice(t,t+i);n.decryptBlock(e,t),a.call(this,e,t,i),this._prevBlock=r}}),l=l.CBC=c,c=(d.pad={}).Pkcs7={pad:function(e,t){for(var n=4*t,i=(n=n-e.sigBytes%n)<<24|n<<16|n<<8|n,r=[],o=0;o<n;o+=4)r.push(i);n=s.create(r,n),e.concat(n)},unpad:function(e){e.sigBytes-=255&e.words[e.sigBytes-1>>>2]}},e.BlockCipher=o.extend({cfg:o.cfg.extend({mode:l,padding:c}),reset:function(){o.reset.call(this);var e,t=(n=this.cfg).iv,n=n.mode;this._xformMode==this._ENC_XFORM_MODE?e=n.createEncryptor:(e=n.createDecryptor,this._minBufferSize=1),this._mode=e.call(n,this,t&&t.words)},_doProcessBlock:function(e,t){this._mode.processBlock(e,t)},_doFinalize:function(){var e,t=this.cfg.padding;return this._xformMode==this._ENC_XFORM_MODE?(t.pad(this._data,this.blockSize),e=this._process(!0)):(e=this._process(!0),t.unpad(e)),e},blockSize:4});var u=e.CipherParams=t.extend({init:function(e){this.mixIn(e)},toString:function(e){return(e||this.formatter).stringify(this)}}),l=(d.format={}).OpenSSL={stringify:function(e){var t=e.ciphertext;return((e=e.salt)?s.create([1398893684,1701076831]).concat(e).concat(t):t).toString(i)},parse:function(e){var t,n=(e=i.parse(e)).words;return 1398893684==n[0]&&1701076831==n[1]&&(t=s.create(n.slice(2,4)),n.splice(0,4),e.sigBytes-=16),u.create({ciphertext:e,salt:t})}},h=e.SerializableCipher=t.extend({cfg:t.extend({format:l}),encrypt:function(e,t,n,i){i=this.cfg.extend(i);var r=e.createEncryptor(n,i);return t=r.finalize(t),r=r.cfg,u.create({ciphertext:t,key:n,iv:r.iv,algorithm:e,mode:r.mode,padding:r.padding,blockSize:e.blockSize,formatter:i.format})},decrypt:function(e,t,n,i){return i=this.cfg.extend(i),t=this._parse(t,i.format),e.createDecryptor(n,i).finalize(t.ciphertext)},_parse:function(e,t){return"string"==typeof e?t.parse(e,this):e}}),d=(d.kdf={}).OpenSSL={execute:function(e,t,n,i){return i=i||s.random(8),e=r.create({keySize:t+n}).compute(e,i),n=s.create(e.words.slice(t),4*n),e.sigBytes=4*t,u.create({key:e,iv:n,salt:i})}},m=e.PasswordBasedCipher=h.extend({cfg:h.cfg.extend({kdf:d}),encrypt:function(e,t,n,i){return n=(i=this.cfg.extend(i)).kdf.execute(n,e.keySize,e.ivSize),i.iv=n.iv,(e=h.encrypt.call(this,e,t,n.key,i)).mixIn(n),e},decrypt:function(e,t,n,i){return i=this.cfg.extend(i),t=this._parse(t,i.format),n=i.kdf.execute(n,e.keySize,e.ivSize,t.salt),i.iv=n.iv,h.decrypt.call(this,e,t,n.key,i)}})}(),function(){for(var e=Wn,t=e.lib.BlockCipher,n=e.algo,s=[],i=[],r=[],o=[],a=[],l=[],c=[],u=[],h=[],d=[],m=[],p=0;p<256;p++)m[p]=p<128?p<<1:p<<1^283;for(var g=0,f=0,p=0;p<256;p++){var v=(v=f^f<<1^f<<2^f<<3^f<<4)>>>8^255&v^99;s[g]=v;var y=m[i[v]=g],b=m[y],_=m[b],S=257*m[v]^16843008*v;r[g]=S<<24|S>>>8,o[g]=S<<16|S>>>16,a[g]=S<<8|S>>>24,l[g]=S,S=16843009*_^65537*b^257*y^16843008*g,c[v]=S<<24|S>>>8,u[v]=S<<16|S>>>16,h[v]=S<<8|S>>>24,d[v]=S,g?(g=y^m[m[m[_^y]]],f^=m[m[f]]):g=f=1}var w=[0,1,2,4,8,16,32,64,128,27,54],n=n.AES=t.extend({_doReset:function(){for(var e,t=(i=this._key).words,n=i.sigBytes/4,i=4*((this._nRounds=n+6)+1),r=this._keySchedule=[],o=0;o<i;o++)o<n?r[o]=t[o]:(e=r[o-1],o%n?6<n&&4==o%n&&(e=s[e>>>24]<<24|s[e>>>16&255]<<16|s[e>>>8&255]<<8|s[255&e]):(e=s[(e=e<<8|e>>>24)>>>24]<<24|s[e>>>16&255]<<16|s[e>>>8&255]<<8|s[255&e],e^=w[o/n|0]<<24),r[o]=r[o-n]^e);for(t=this._invKeySchedule=[],n=0;n<i;n++)o=i-n,e=n%4?r[o]:r[o-4],t[n]=n<4||o<=4?e:c[s[e>>>24]]^u[s[e>>>16&255]]^h[s[e>>>8&255]]^d[s[255&e]]},encryptBlock:function(e,t){this._doCryptBlock(e,t,this._keySchedule,r,o,a,l,s)},decryptBlock:function(e,t){var n=e[t+1];e[t+1]=e[t+3],e[t+3]=n,this._doCryptBlock(e,t,this._invKeySchedule,c,u,h,d,i),n=e[t+1],e[t+1]=e[t+3],e[t+3]=n},_doCryptBlock:function(e,t,n,i,r,o,s,a){for(var l=this._nRounds,c=e[t]^n[0],u=e[t+1]^n[1],h=e[t+2]^n[2],d=e[t+3]^n[3],m=4,p=1;p<l;p++)var g=i[c>>>24]^r[u>>>16&255]^o[h>>>8&255]^s[255&d]^n[m++],f=i[u>>>24]^r[h>>>16&255]^o[d>>>8&255]^s[255&c]^n[m++],v=i[h>>>24]^r[d>>>16&255]^o[c>>>8&255]^s[255&u]^n[m++],d=i[d>>>24]^r[c>>>16&255]^o[u>>>8&255]^s[255&h]^n[m++],c=g,u=f,h=v;g=(a[c>>>24]<<24|a[u>>>16&255]<<16|a[h>>>8&255]<<8|a[255&d])^n[m++],f=(a[u>>>24]<<24|a[h>>>16&255]<<16|a[d>>>8&255]<<8|a[255&c])^n[m++],v=(a[h>>>24]<<24|a[d>>>16&255]<<16|a[c>>>8&255]<<8|a[255&u])^n[m++],d=(a[d>>>24]<<24|a[c>>>16&255]<<16|a[u>>>8&255]<<8|a[255&h])^n[m++],e[t]=g,e[t+1]=f,e[t+2]=v,e[t+3]=d},keySize:8});e.AES=t._createHelper(n)}();var Hn,Gn=Wn,Kn=new Promise(function(e){Hn=e});var qn=o("systemjs"),Zn="MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQC8mDjlmjdBvK7eonacVtuNKoGu\nY1uJtpLYjp3ptzeT1ZgygwG+gA19HvbPZ4mjf9Iy7RH41O58GlUrqL3/mi6rdEFe\nbBa/vqmVtb49+sEGbwqjw94qDLsOGa4luf4xInoswywP/+HuxP1nn+NYyER8Ugsh\nsvo0gaiMFXiv9cfn1wIDAQAB",$n="MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQDsDGIqrmDXfzYlILwnJ0SSe5le\nfQX6EmTmOizn0YHT6YYdWlnV2GEBMU2Po6aCg8onLfGtpHXx3WV254GNUBB69jn8\n5Q/dMlhLaQ5E1kWCBRHPsqhHLlz21l3dRJafelXQ9ITgfgB+5N1WHjAA9kMOqz8P\n+2OImUt+qIKSkOxqmQIDAQAB";function Qn(e){return function(e){if(Array.isArray(e))return Jn(e)}(e)||function(e){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e))return Array.from(e)}(e)||function(e,t){if(!e)return;if("string"==typeof e)return Jn(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Jn(e,t)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Jn(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,i=new Array(t);n<t;n++)i[n]=e[n];return i}qn.registerDynamic("Encryption",["jsencrypt"],!0,function(){var t=new(window.JSEncrypt||o("jsencrypt").JSEncrypt);t.setPublicKey("PROD"==W.getEnv()||!g()&&"STAGE"==W.getEnv()?$n:Zn);var n=R("wh-",!0),i=t.encrypt(n),r={APIEncrypt:function(e){return t.encrypt(e)},encrypt:function(e){return Gn.AES.encrypt(e.toString(),n).toString()},decrypt:function(e){return Gn.AES.decrypt(e,n).toString(Gn.enc.Utf8)},get key(){return n},_setkey:function(e){n=e,i=t.encrypt(n)},send:function(t){return(t=void 0===t?{method:"POST",encryptprops:[],v2:!1}:t).encryptprops||(t.encryptprops=[]),t.encryptprops.forEach(function(e){if(t.data[e])try{t.data[e]=r.encrypt(t.data[e])}catch(e){}}),t.v2?(t.data.EncryptionKey=i,t.headers=t.headers||{},t.headers.EncryptionKey=i):t.data.publickey=i,delete t.encryptprops,it(t)}};return r});var Yn=!1;"undefined"!=typeof window&&(window.addEventListener("testPassive",null,Zr={get passive(){Yn=!0}}),window.removeEventListener("testPassive",null,Zr));function Xn(t){return si.some(function(e){return!(!e.options.allowTouchMove||!e.options.allowTouchMove(t))})}function ei(e){return e=e||window.event,!!Xn(e.target)||(1<e.touches.length||(e.preventDefault&&e.preventDefault(),!1))}function ti(i,e){var t;i?si.some(function(e){return e.targetElement===i})||(t={targetElement:i,options:e||{}},si=[].concat(Qn(si),[t]),oi?(i.ontouchstart=function(e){1===e.targetTouches.length&&(li=e.targetTouches[0].clientY)},i.ontouchmove=function(e){var t,n;1===e.targetTouches.length&&(n=i,e=(t=e).targetTouches[0].clientY-li,Xn(t.target)||(n&&0===n.scrollTop&&0<e||!!(n=n)&&n.scrollHeight-n.scrollTop<=n.clientHeight&&e<0?ei(t):t.stopPropagation()))},ai||(document.addEventListener("touchmove",ei,Yn?{passive:!1}:void 0),ai=!0)):(t=e,void 0===ri&&(e=!!t&&!0===t.reserveScrollBarGap,t=window.innerWidth-document.documentElement.clientWidth,e&&0<t&&(ri=document.body.style.paddingRight,document.body.style.paddingRight="".concat(t,"px"))),void 0===ii&&(ii=document.body.style.overflow,document.body.style.overflow="hidden"))):console.error("disableBodyScroll unsuccessful - targetElement must be provided when calling disableBodyScroll on IOS devices.")}function ni(t){t?(si=si.filter(function(e){return e.targetElement!==t}),oi?(t.ontouchstart=null,t.ontouchmove=null,ai&&0===si.length&&(document.removeEventListener("touchmove",ei,Yn?{passive:!1}:void 0),ai=!1)):si.length||(void 0!==ri&&(document.body.style.paddingRight=ri,ri=void 0),void 0!==ii&&(document.body.style.overflow=ii,ii=void 0))):console.error("enableBodyScroll unsuccessful - targetElement must be provided when calling enableBodyScroll on IOS devices.")}var ii,ri,oi="undefined"!=typeof window&&window.navigator&&window.navigator.platform&&(/iP(ad|hone|od)/.test(window.navigator.platform)||"MacIntel"===window.navigator.platform&&1<window.navigator.maxTouchPoints),si=[],ai=!1,li=-1,ci=["content"],ui=["dialog"];function hi(e,t){var n;1&e&&(n=u.ɵɵgetCurrentView(),u.ɵɵelementStart(0,"div",5),u.ɵɵlistener("onTap",function(){return u.ɵɵrestoreView(n),u.ɵɵnextContext().Close()}),u.ɵɵelementEnd()),2&e&&u.ɵɵproperty("zing-no-touch",!0)}function di(e,t){}function mi(e,t,n){return{opened:e,mobilefullscreen:t,"ng-md-fullscreen":n}}new Promise(function(t,e){o(["css:/modal-dialog.css"],function(e){t(d(e))},e)}).then(function(){},function(){});var pi=(gi.prototype._destroyActiveComponent=function(){this._activeComponent&&(this._activeComponent.destroy(),this._activeComponent=null,this.container.clear()),Ke.emit("to-top-arrow:show",!0)},gi.prototype.Close=function(e,t){var n=this;this.opened=!1,this.ready=!1,setTimeout(function(){j(function(){n._zone.run(function(){n._destroyActiveComponent(),t||n._dservice.canScroll(!0)})})},300),this.onClose.emit(e),this.myId="",this._scroll_lock&&(this._dservice.canScroll(!0),ni(this.myEl.nativeElement),this._scroll_lock=!1),this._headerWatch&&(this._headerWatch.unsubscribe(),this._headerWatch=null),this.fullscreenmode&&Ke.emit("header:visibility",!0,!0),this.fullInMobile&&this.fullinmobileheader&&st().classList.remove("ng-md-fullscreenmobile")},gi.prototype.Open=function(e,t,n){var i=this;this.opened=!0,this.ready=!0,this._destroyActiveComponent();e=this._resolver.resolveComponentFactory(e);this._activeComponent=this.container.createComponent(e);e=this._activeComponent.instance;return e.data=t,n&&(n.hostid&&(this.myId=n.hostid),"withclose"in n&&(this.hasclose=n.withclose)),this.fullscreenmode?(Ke.emit("header:visibility",!1,!0),this.hasclose=!1):this._headerWatch=Ke.subscribe("header:position-change",function(e){e&&0<e&&i.myEl?i.myEl.nativeElement.style.top=e+"px":i.myEl.nativeElement.style.top=""}),e.closeDialog=function(e){i._zone.run(function(){i.Close(e)})},!this._scroll_lock&&this.myEl&&(this._dservice.canScroll(!1),ti(this.myEl.nativeElement),this._scroll_lock=!0),Ke.emit("to-top-arrow:show",!1),this.fullInMobile&&this.fullinmobileheader&&st().classList.add("ng-md-fullscreenmobile"),this},gi.prototype.ngOnDestroy=function(){this._destroyActiveComponent(),this._headerWatch&&(this._headerWatch.unsubscribe(),this._headerWatch=null),this.onClose.complete&&this.onClose.complete(),this.fullscreenmode&&Ke.emit("header:visibility",!0,!0),this.fullInMobile&&this.fullinmobileheader&&st().classList.remove("ng-md-fullscreenmobile")},gi.ɵfac=function(e){return new(e||gi)(u.ɵɵdirectiveInject(u.ComponentFactoryResolver),u.ɵɵdirectiveInject(u.NgZone),u.ɵɵdirectiveInject(te))},gi.ɵcmp=u.ɵɵdefineComponent({type:gi,selectors:[["modal-dialog"]],viewQuery:function(e,t){1&e&&(u.ɵɵviewQuery(ci,!0,u.ViewContainerRef),u.ɵɵviewQuery(ui,!0)),2&e&&(u.ɵɵqueryRefresh(e=u.ɵɵloadQuery())&&(t.container=e.first),u.ɵɵqueryRefresh(e=u.ɵɵloadQuery())&&(t.myEl=e.first))},hostVars:1,hostBindings:function(e,t){2&e&&u.ɵɵattribute("id",t.myId)},inputs:{fullInMobile:["mobile-full","fullInMobile"],fullinmobileheader:["mobile-full-no-header","fullinmobileheader"],fullscreenmode:["fullscreen","fullscreenmode"]},outputs:{onClose:"onClose"},decls:6,vars:8,consts:[[1,"ng-modal-dialog",3,"ngClass"],["dialog",""],[1,"ng-modal-container"],["class","close-btn af-icon-cross-slim","zing-touch","","aria-label","Close overlay",3,"zing-no-touch","onTap",4,"ngIf"],["content",""],["zing-touch","","aria-label","Close overlay",1,"close-btn","af-icon-cross-slim",3,"zing-no-touch","onTap"]],template:function(e,t){1&e&&(u.ɵɵelementStart(0,"div",0,1),u.ɵɵelementStart(2,"div",2),u.ɵɵtemplate(3,hi,1,1,"div",3),u.ɵɵtemplate(4,di,0,0,"ng-template",null,4,u.ɵɵtemplateRefExtractor),u.ɵɵelementEnd(),u.ɵɵelementEnd()),2&e&&(u.ɵɵproperty("ngClass",u.ɵɵpureFunction3(4,mi,t.opened,t.fullInMobile,t.fullscreenmode)),u.ɵɵadvance(2),u.ɵɵclassProp("ready",t.ready),u.ɵɵadvance(1),u.ɵɵproperty("ngIf",t.hasclose))},directives:[u.NgClass,u.NgIf,K],encapsulation:2}),gi);function gi(e,t,n){this._resolver=e,this._zone=t,this._dservice=n,this.opened=!1,this.ready=!1,this.hasclose=!0,this.onClose=new u.EventEmitter,this.fullInMobile=!1,this.fullinmobileheader=!1,this.fullscreenmode=!1}u.setClassMetadata(pi,[{type:u.Component,args:[{selector:"modal-dialog",template:'<div class="ng-modal-dialog" #dialog  [ngClass]="{ \'opened\': opened, \'mobilefullscreen\' : fullInMobile, \'ng-md-fullscreen\' : fullscreenmode }">\n                    <div class="ng-modal-container" [class.ready]="ready">\n                        <div class="close-btn af-icon-cross-slim" zing-touch [zing-no-touch]="true" (onTap)="Close()" *ngIf="hasclose" aria-label="Close overlay"></div>\n                        <ng-template #content></ng-template>\n                    </div>\n                </div>',host:{"[attr.id]":"myId"}}]}],function(){return[{type:u.ComponentFactoryResolver},{type:u.NgZone},{type:te}]},{container:[{type:u.ViewChild,args:["content",{read:u.ViewContainerRef,static:!1}]}],onClose:[{type:u.Output,args:["onClose"]}],fullInMobile:[{type:u.Input,args:["mobile-full"]}],fullinmobileheader:[{type:u.Input,args:["mobile-full-no-header"]}],fullscreenmode:[{type:u.Input,args:["fullscreen"]}],myEl:[{type:u.ViewChild,args:["dialog",{static:!1}]}]});var fi=(vi.ɵmod=u.ɵɵdefineNgModule({type:vi}),vi.ɵinj=u.ɵɵdefineInjector({factory:function(e){return new(e||vi)},imports:[[u.CommonModule,Fe]]}),vi);function vi(){}u.setClassMetadata(fi,[{type:u.NgModule,args:[{declarations:[pi],exports:[pi],imports:[u.CommonModule,Fe]}]}],null,null);var yi=["class","progress-indicator-container"];function bi(e,t){1&e&&u.ɵɵelement(0,"p",6),2&e&&(e=u.ɵɵnextContext(),u.ɵɵproperty("innerHTML",e.titlecontent,u.ɵɵsanitizeHtml))}function _i(e,t){1&e&&u.ɵɵelement(0,"br")}function Si(e,t){var n;1&e&&(n=u.ɵɵgetCurrentView(),u.ɵɵelementStart(0,"p"),u.ɵɵtext(1,"If the issue persists please "),u.ɵɵelementStart(2,"span",7),u.ɵɵlistener("onTap",function(){return u.ɵɵrestoreView(n),u.ɵɵnextContext().ContactUs()}),u.ɵɵtext(3,"email us"),u.ɵɵelementEnd(),u.ɵɵtext(4),u.ɵɵelementEnd()),2&e&&(e=u.ɵɵnextContext(),u.ɵɵadvance(4),u.ɵɵtextInterpolate1(" and mention: ",e.data.type,""))}function wi(e,t){1&e&&u.ɵɵelement(0,"p",8),2&e&&(e=u.ɵɵnextContext(),u.ɵɵproperty("innerHTML",e.customcontent,u.ɵɵsanitizeHtml))}var Ei=["appErrors"],ki=o("systemjs");function xi(o,s){zn().then(function(r){r.withScope(function(e){var t={status:o?o.status:null,response:o&&o.data?JSON.stringify(o.data):null,path:window.location.pathname||window.location.href,arguments:{url:o&&o.options?o.options.url:null,action:o&&o.options&&o.options.data&&(o.options.data.action||o.options.data.customAction)||null,query:o&&o.options?"GET"==o.options.method?o.options.data:o.options.query:null}},n=t.arguments.action,i=t.arguments.url;(n||i)&&(s+="("+(n||i)+")"),e.setExtras(t),r.captureMessage(s,r.Severity.Warning)})})}V()||(Ke.subscribe("$server:error",function(e){xi(e,"NG Request Failed : Server Error")}),Ke.subscribe("$server:whiderror",function(e){xi(e,"NG Request Failed : WHID Fetch Error")}),Ke.subscribe("$server:csrferror",function(e){console.log(e),xi(e,"NG Request Failed : Xsrf Token Fetch Error")}));var Pi=(Oi.prototype._openMail=function(){var e=N(this.emailparams,!0);window.top.open("mailto:help@wallethub.com?"+e,m()?"_self":"_system")},Oi.prototype._stopProgress=function(){var e=this;setTimeout(function(){e.inprogress=!1},300)},Oi.prototype.ContactUs=function(){var e,t=this;this.inprogress=!0,e=Be()+"?action=get-my-ip",new Promise(function(t,n){function i(){$e(e).then(function(e){e.ip?t(e.ip):n(null)},function(){n(null)})}$e("https://api.ipify.org/?format=json").then(function(e){e.ip?t(e.ip):i()},function(){i()})}).then(function(e){t._stopProgress(),t.emailparams.body=b(t.emailparams.body,[e,"--",t.data.type]),t._openMail()},function(){t._stopProgress(),t.emailparams.body=b(t.emailparams.body,["--","--",t.data.type]),t._openMail()})},Oi.prototype.ngOnInit=function(){this.data.maintainance?(this.titlecontent=this.data.maintainancetitle||"Sorry! Be Right Back in 5 minutes.",this.customcontent=this.data.maintainancecontent||"Our engineers are upgrading our servers."):this.data.offline?(this.titlecontent="Connection could not be established",this.customcontent="Please make sure your internet is working properly and try again."):this.data.custom?(this.customcontent=this.data.content,this.titlecontent=this.data.title):(this.titlecontent="Oops, we encountered an error. Please retry.",this.iserror=!!this.data.type)},Oi.ɵfac=function(e){return new(e||Oi)},Oi.ɵcmp=u.ɵɵdefineComponent({type:Oi,selectors:[["error-message-overlay",8,"progress-indicator-container"]],attrs:yi,decls:9,vars:6,consts:[["class","bold-font",3,"innerHTML",4,"ngIf"],[4,"ngIf"],[3,"innerHTML",4,"ngIf"],[1,"overlay-row","center"],["zing-touch","",1,"btn","blue","fixed-w-c",3,"onTap"],[1,"progress-indicator"],[1,"bold-font",3,"innerHTML"],["zing-touch","",1,"link",3,"onTap"],[3,"innerHTML"]],template:function(e,t){1&e&&(u.ɵɵtemplate(0,bi,1,1,"p",0),u.ɵɵtemplate(1,_i,1,0,"br",1),u.ɵɵtemplate(2,Si,5,1,"p",1),u.ɵɵtemplate(3,wi,1,1,"p",2),u.ɵɵelementStart(4,"div",3),u.ɵɵelementStart(5,"button",4),u.ɵɵlistener("onTap",function(){return t.closeDialog()}),u.ɵɵtext(6,"Ok"),u.ɵɵelementEnd(),u.ɵɵelementEnd(),u.ɵɵelementStart(7,"div",5),u.ɵɵelement(8,"i"),u.ɵɵelementEnd()),2&e&&(u.ɵɵproperty("ngIf",t.titlecontent),u.ɵɵadvance(1),u.ɵɵproperty("ngIf",t.iserror||t.customcontent),u.ɵɵadvance(1),u.ɵɵproperty("ngIf",t.iserror),u.ɵɵadvance(1),u.ɵɵproperty("ngIf",t.customcontent),u.ɵɵadvance(4),u.ɵɵclassProp("visible",t.inprogress))},directives:[u.NgIf,K],styles:["[_nghost-%COMP%] { position:relative; text-align: center; max-width: 100%; width: 312px; display: block;}"]}),Oi);function Oi(){this.inprogress=!1,this.data={},this.emailparams={subject:"Internal Error",body:"Please help me with an error I encountered while using WalletHub. Details are below:\nIP address:{0}\nSupport ID:{1}\nCode:{2}"},this.iserror=!1,this.titlecontent="",this.customcontent=""}u.setClassMetadata(Pi,[{type:u.Component,args:[{selector:"error-message-overlay.progress-indicator-container",template:'<p class="bold-font" *ngIf="titlecontent" [innerHTML]="titlecontent"></p>\n    <br *ngIf="iserror || customcontent"/>    <p *ngIf="iserror">If the issue persists please <span class="link" zing-touch (onTap)="ContactUs()">email us</span> and mention: {{data.type}}</p>\n    <p *ngIf="customcontent" [innerHTML]="customcontent"></p>\n    <div class="overlay-row center">\n        <button class="btn blue fixed-w-c" zing-touch (onTap)="closeDialog()">Ok</button>\n    </div>\n    <div class="progress-indicator" [class.visible]="inprogress"><i></i></div>\n    ',styles:[":host { position:relative; text-align: center; max-width: 100%; width: 312px; display: block;}"]}]}],null,null);var Ci=(Ni.prototype._onClose=function(){var e=this;this._error_showing=!0;var t=this._appErrors.onClose.subscribe(function(){e._error_showing=!1,t&&t.unsubscribe()})},Ni.prototype.ngOnInit=function(){var t=this;Ke.subscribe("$server:error",function(){t._error_showing||(t._appErrors.Open(Pi,{type:"Internal Error"},{withclose:!1}),t._onClose())}),Ke.subscribe("$server:csrferror",function(){t._error_showing||(t._appErrors.Open(Pi,{type:"CSRF Error"},{withclose:!1}),t._onClose())}),Ke.subscribe("$server:whiderror",function(){t._error_showing||(t._appErrors.Open(Pi,{type:"WHID Error"},{withclose:!1}),t._onClose())}),Ke.subscribe("$server:maintainance",function(){t._error_showing||(t._appErrors.Open(Pi,{maintainance:!0},{withclose:!1}),t._onClose())}),Ke.subscribe("$device:no-internet",function(){t._error_showing||(t._appErrors.Open(Pi,{offline:!0},{withclose:!1}),t._onClose())}),Ke.subscribe("$app:error",function(e){t._error_showing||(t._appErrors.Open(Pi,{custom:!e.generic,title:e.title,content:e.content}),t._onClose())});var n=this._scservice.overwrite_to_body?window:this._scservice.element;Ke.subscribe("$shortcodes:set",function(){Promise.all([ki.import("shortcode-js"),ki.import("css:/shortcodes.css")]).then(function(e){e=e[0];e.ClearPrsWidgets(),e.SetPrsWidgets(n,Re()),e.ClearBoxes(),e.SetBoxes(n,Re())},function(){})})},Ni.prototype.ngOnDestroy=function(){!function(e,t){try{e()}catch(e){return O(t)&&t(e)}}(function(){Ke.terminate("$server:error"),Ke.terminate("$server:csrferror"),Ke.terminate("$server:whiderror"),Ke.terminate("$device:no-internet"),Ke.terminate("$app:error")})},Ni.ɵfac=function(e){return new(e||Ni)(u.ɵɵdirectiveInject(te))},Ni.ɵcmp=u.ɵɵdefineComponent({type:Ni,selectors:[["app-errors"]],viewQuery:function(e,t){var n;1&e&&u.ɵɵviewQuery(Ei,!0),2&e&&u.ɵɵqueryRefresh(n=u.ɵɵloadQuery())&&(t._appErrors=n.first)},decls:2,vars:0,consts:[["appErrors",""]],template:function(e,t){1&e&&u.ɵɵelement(0,"modal-dialog",null,0)},directives:[pi],encapsulation:2}),Ni);function Ni(e){this._scservice=e}u.setClassMetadata(Ci,[{type:u.Component,args:[{selector:"app-errors",template:"<modal-dialog #appErrors></modal-dialog>"}]}],function(){return[{type:te}]},{_appErrors:[{type:u.ViewChild,args:["appErrors",{static:!1}]}]});var Ti=(Ii.ɵmod=u.ɵɵdefineNgModule({type:Ii}),Ii.ɵinj=u.ɵɵdefineInjector({factory:function(e){return new(e||Ii)},imports:[[u.CommonModule,Fe,fi]]}),Ii);function Ii(){}function Fi(t,n,e,i,r,o,s){var a,l;return void 0===s&&(s={}),e.compileModuleAsync(i).then(function(e){e=(l=e.create(n)).componentFactoryResolver.resolveComponentFactory(r);return a=e.create(n,[],o),T(s,function(e,t){a.instance[t]=e}),t.attachView(a.hostView),{ngModule:l,Component:a,destroy:function(){l.destroy(),a.destroy()}}})}u.setClassMetadata(Ti,[{type:u.NgModule,args:[{declarations:[Ci,Pi],exports:[Ci,Pi],imports:[u.CommonModule,Fe,fi],entryComponents:[Pi]}]}],null,null);var Li=o("systemjs"),Vi=(Ai.prototype.Destroy=function(){this.scroller.ngOnDestroy(),this.renderer.destroy()},Ai);function Ai(e,t,n){this._rendererFactory=e,this._zone=t,this._service=n,this.renderer=this._rendererFactory.createRenderer(null,null),this.scroller=new ie({nativeElement:document.querySelector("#scroller")},this._zone,this.renderer,this._service),this.scroller.useZen=!0,this.scroller.use_body=!0,this.scroller.main_header_offset="web-app header[main-header]",this.scroller.ngOnInit(),this.scroller.ngAfterViewInit()}var Mi=(Object.defineProperty(zi.prototype,"src",{get:function(){return this._src},set:function(e){e?this._src=e:this.fallback&&(this._src=this.fallback)},enumerable:!1,configurable:!0}),zi.prototype.ngOnInit=function(){V()?this._src&&(this._renderer.setAttribute(this._el.nativeElement,this.prepare_ui?"data-src":"src",this._src),this.prepare_ui&&this._renderer.setStyle(this._el.nativeElement,"display","none")):this._Preload()},zi.prototype._Preload=function(){var e,t,n,i,r=this;this._el.nativeElement&&(this._src||this.fallback)&&(e=this._src||this.fallback,t=this._renderer.createElement("img"),n=this._renderer.listen(t,"load",function(){n(),i(),r._renderer.setAttribute(r._el.nativeElement,"src",e),r._renderer.setStyle(r._el.nativeElement,"display",""),t=null}),i=this._renderer.listen(t,"error",function(){i(),n(),r.onImageFailed.emit(),t=null}),this._renderer.setAttribute(t,"src",e),this._renderer.setStyle(this._el.nativeElement,"display","none"))},zi.ɵfac=function(e){return new(e||zi)(u.ɵɵdirectiveInject(u.ElementRef),u.ɵɵdirectiveInject(u.Renderer2))},zi.ɵdir=u.ɵɵdefineDirective({type:zi,selectors:[["","preload-src",""]],inputs:{src:["preload-src","src"],fallback:["src-fallback","fallback"],prepare_ui:["ui-hydrate","prepare_ui"]},outputs:{onImageFailed:"imageFailed"}}),zi);function zi(e,t){this._el=e,this._renderer=t,this.onImageFailed=new u.EventEmitter}u.setClassMetadata(Mi,[{type:u.Directive,args:[{selector:"[preload-src]"}]}],function(){return[{type:u.ElementRef},{type:u.Renderer2}]},{src:[{type:u.Input,args:["preload-src"]}],fallback:[{type:u.Input,args:["src-fallback"]}],onImageFailed:[{type:u.Output,args:["imageFailed"]}],prepare_ui:[{type:u.Input,args:["ui-hydrate"]}]});var Ri=(Di.ɵmod=u.ɵɵdefineNgModule({type:Di}),Di.ɵinj=u.ɵɵdefineInjector({factory:function(e){return new(e||Di)},imports:[[u.CommonModule]]}),Di);function Di(){}u.setClassMetadata(Ri,[{type:u.NgModule,args:[{imports:[u.CommonModule],declarations:[Mi],exports:[Mi]}]}],null,null);var Bi=["deferImg"],ji=(Object.defineProperty(Ui.prototype,"src",{get:function(){return this._src},set:function(e){e?this._src=e:this.fallback&&(this._src=this.fallback),this._src&&(this._viewed||(!this._has_intersect||V())&&this._src&&this.deferImg)&&this._renderer.setAttribute(this.deferImg.nativeElement,"src",this._src)},enumerable:!1,configurable:!0}),Ui.prototype.ngOnInit=function(){this.onError=this.onError.bind(this),this.onLoad=this.onLoad.bind(this),ht.getKey("server-render")&&(this._prepare_ui=!1)},Ui.prototype.ngAfterViewInit=function(){var e,t,n,i,o=this;this._has_intersect?(this._intersectionObserver=new IntersectionObserver(function(e){for(var t=!1,n=0,i=e.length;n<i;n++){var r=e[n];if(M(r.isIntersecting)&&o._isInViewport(r,!0)){t=!0;break}if(r.isIntersecting){t=!0;break}}t&&o._InitiateImageLoad()},{threshold:.7}),this._renderer.setStyle(this.deferImg.nativeElement,"opacity",0),e=this.deferImg.nativeElement.width,i=this.deferImg.nativeElement.height,window.getComputedStyle&&(t=E(window.getComputedStyle(this.deferImg.nativeElement).width),n=E(window.getComputedStyle(this.deferImg.nativeElement).height),w(t)&&w(n)&&(e=t,i=n)),e&&this._renderer.setStyle(this.deferImg.nativeElement,"width",e+"px"),i&&this._renderer.setStyle(this.deferImg.nativeElement,"height",i+"px"),this._intersectionObserver.observe(this._el.nativeElement),this._isInViewport(this._el)&&this._InitiateImageLoad()):this.src&&(i=this.deferImg.nativeElement,V()?this._prepare_ui?this._renderer.setStyle(i,"display","none"):this._renderer.setAttribute(i,"src",this.src):(this._renderer.listen(i,"error",this.onError),this._renderer.setAttribute(i,"src",this.src)))},Ui.prototype.ngOnDestroy=function(){this._intersectionObserver&&this._intersectionObserver.disconnect(),this._intersectionObserver=null},Ui.prototype.onError=function(e){!V()&&e&&(e=this.deferImg.nativeElement,this.fallback&&e.src!=this.fallback?(e.src=this.fallback,e.style.display=""):e.style.display="none")},Ui.prototype.onLoad=function(e){this._renderer.setStyle(this.deferImg.nativeElement,"display",""),this._renderer.addClass(this.deferImg.nativeElement,"defer-img-ok"),this._renderer.setStyle(this.deferImg.nativeElement,"opacity",""),this._renderer.addClass(this.deferImg.nativeElement,"ng-enter-element"),this._renderer.setStyle(this.deferImg.nativeElement,"width",""),this._renderer.setStyle(this.deferImg.nativeElement,"height","")},Ui.prototype._isInViewport=function(e,t){var n=t?e.boundingClientRect:e.nativeElement.getBoundingClientRect(),t=n.height||n.bottom-n.top,e=n.width||n.right-n.left;return!(!t||!e)&&!(n.top+.4*n.height>window.innerHeight||n.bottom<0)},Ui.prototype._InitiateImageLoad=function(){var e;this.src&&(this._viewed||(e=this.deferImg.nativeElement,this._renderer.listen(e,"error",this.onError),this._renderer.listen(e,"load",this.onLoad),this._viewed=!0,this._intersectionObserver&&(this._intersectionObserver.disconnect(),this._intersectionObserver=null),this._renderer.setAttribute(this.deferImg.nativeElement,"src",this.src)))},Ui.ɵfac=function(e){return new(e||Ui)(u.ɵɵdirectiveInject(u.ElementRef),u.ɵɵdirectiveInject(u.Renderer2))},Ui.ɵdir=u.ɵɵdefineDirective({type:Ui,selectors:[["","defer-src",""]],contentQueries:function(e,t,n){var i;1&e&&u.ɵɵcontentQuery(n,Bi,!0,u.ElementRef),2&e&&u.ɵɵqueryRefresh(i=u.ɵɵloadQuery())&&(t.deferImg=i.first)},inputs:{src:["defer-src","src"],fallback:["src-fallback","fallback"],_prepare_ui:["ui-hydrate","_prepare_ui"]}}),Ui);function Ui(e,t){this._el=e,this._renderer=t,this._viewed=!1,this._has_intersect=!(V()||!window.IntersectionObserver)}u.setClassMetadata(ji,[{type:u.Directive,args:[{selector:"[defer-src]"}]}],function(){return[{type:u.ElementRef},{type:u.Renderer2}]},{src:[{type:u.Input,args:["defer-src"]}],fallback:[{type:u.Input,args:["src-fallback"]}],deferImg:[{type:u.ContentChild,args:["deferImg",{read:u.ElementRef}]}],_prepare_ui:[{type:u.Input,args:["ui-hydrate"]}]});var Wi=(Hi.ɵmod=u.ɵɵdefineNgModule({type:Hi}),Hi.ɵinj=u.ɵɵdefineInjector({factory:function(e){return new(e||Hi)},imports:[[u.CommonModule]]}),Hi);function Hi(){}function Gi(e,t){var n=e.src||e.getAttribute("data-src");e.removeAttribute("src");var i=t.createRenderer(null,null),e=new Mi({nativeElement:e},i);return e.src=n,e.prepare_ui=!0,e.ngOnInit(),function(){i.destroy()}}function Ki(e,t){var n=e.src||e.getAttribute("data-src");e.removeAttribute("src"),e.removeAttribute("data-src");var i=t.createRenderer(null,null),r=new ji({nativeElement:e.parentNode},i);return r.deferImg={nativeElement:e},r.src=n,r.ngOnInit(),r.ngAfterViewInit(),function(){i.destroy(),r.ngOnDestroy()}}u.setClassMetadata(Wi,[{type:u.NgModule,args:[{declarations:[ji],exports:[ji],imports:[u.CommonModule]}]}],null,null);var qi=o("systemjs");var Zi=($i.prototype._TabSwitch=function(e,t){e.preventDefault();var e=t.getAttribute("href").substring(1),n=this._el.querySelectorAll(".top-nav .nav-content a");if(n&&0<n.length)for(var i=0,r=n.length;i<r;i++)n[i].classList.remove("selected");var o=this._el.querySelectorAll(".main-content .content");if(o&&0<o.length)for(i=0,r=n.length;i<r;i++)o[i].classList.remove("selected");t.classList.add("selected"),this._el.querySelector(".cc-section .main-content ."+e).classList.add("selected")},$i.prototype.Destroy=function(){P(this._cleanups,function(e){e()})},$i);function $i(e){var r=this;this._el=e,this._cleanups=[],this._TabSwitch=this._TabSwitch.bind(this);var o=e.querySelectorAll(".main-content .top-nav a");if(o&&0<o.length)for(var t=function(e,t){function n(e){r._TabSwitch(e,i)}var i=o[e];i.addEventListener("click",n),s._cleanups.push(function(){i.removeEventListener("click",n)})},s=this,n=0,i=o.length;n<i;n++)t(n)}function Qi(e){return e.replace(/[^\-?0-9.]/g,"")}var Ji=o("npm:tablesort/dist/tablesort.min.js");Ji.extend("number",function(e){return e.match(/^[-+]?[£\x24Û¢´€]?\d+\s*([,\.]\d{0,2})/)||e.match(/^[-+]?\d+\s*([,\.]\d{0,2})?[£\x24Û¢´€]/)||e.match(/^[-+]?(\d)*-?([,\.]){0,1}-?(\d)+([E,e][\-+][\d]+)?%?$/)},function(e,t){return e=Qi(e),t=Qi(t),t=t,e=e,t=parseFloat(t),e=parseFloat(e),(t=isNaN(t)?0:t)-(e=isNaN(e)?0:e)});var Yi=(Xi.prototype.Destroy=function(){P(this._obsEl,function(e){e.obs.complete()}),P(this._sbs,function(e){e.unsubscribe()}),this._intersected=[],this._obsEl=null,this._obs=[]},Xi.prototype.Observe=function(t){var e=this,n=this._obsEl.findIndex(function(e){return e.el==t}),i=new u.Subject;return n<0?(this._obsEl.push({el:t,obs:i}),n=this._obsEl.length-1):(this._obsEl[n].obs.complete(),this._obsEl[n].obs=i),j(function(){null!=e._obsEl&&(e._InViewport(t)?(e._obsEl.splice(n,1),i.next(),i.complete(),e._intersectionObserver&&e._intersectionObserver.unobserve(t)):e._intersectionObserver&&(e._intersectionObserver.unobserve(t),e._intersectionObserver.observe(t)))}),i},Xi.prototype.Unobserve=function(t){var e=this._obsEl.findIndex(function(e){return e.el==t});-1<e&&(this._obsEl[e].obs.complete(),this._obsEl.splice(e,1),this._intersectionObserver&&this._intersectionObserver.unobserve(t))},Xi.prototype._GetViewportSize=function(){var e=window;null!=e.innerWidth&&(this._viewport={w:e.innerWidth,h:e.innerHeight})},Xi.prototype._InViewport=function(e){if(!this._viewport)return!1;var t=e instanceof Element?e.getBoundingClientRect():e.boundingClientRect,n=t.height||t.bottom-t.top,e=t.width||t.right-t.left;return!(!n||!e)&&!(t.top+t.height*this.threshold>this._viewport.h||t.bottom<0)},Xi.prototype.CheckForIntersection=function(e){this._intersected=[];for(var t=0,n=e.length;t<n;t++){var i=e[t],r=e[t].target;(i.isIntersecting||M(i.isIntersecting)&&this._InViewport(i))&&this._intersected.push(r)}},Xi.prototype.CheckInView=function(){var n=this;this._obsEl&&P(this._obsEl,function(e,t){if(n._InViewport(e.el))return e.obs.next(),e.obs.complete(),n._obsEl.splice(t,1),!1})},Xi);function Xi(e,t,n){var i=this;void 0===t&&(t=.5),void 0===n&&(n=250),this._dservice=e,this.threshold=t,this._obsEl=[],this._sbs=[],this._obs=[],this._intersected=[],window.IntersectionObserver&&(this._intersectionObserver=new IntersectionObserver(function(e){i.CheckForIntersection(e)},{threshold:.5})),this._sbs.push(this._dservice.onScroll.subscribe(function(){clearTimeout(i._scrolltimer),i._scrolltimer=setTimeout(function(){i._intersectionObserver?(P(i._intersected,function(t){var e=i._obsEl.findIndex(function(e){return e.el==t}),n=i._obsEl[e];n&&(n.obs.next(),n.obs.complete(),i._obsEl.splice(e,1),i._intersectionObserver.unobserve(n.el))}),i._intersected=[]):i.CheckInView()},n)})),this._obs.push(u.fromEvent(window,"resize")),this._obs[this._obs.length-1].subscribe(function(){j(function(){i._GetViewportSize(),i._intersectionObserver||i.CheckInView()})}),this._GetViewportSize()}var er=["searchfield"],tr=["class","city-table-container"];function nr(e,n){var i,t;1&e&&(i=u.ɵɵgetCurrentView(),u.ɵɵelementStart(0,"th",9),u.ɵɵlistener("onTap",function(){u.ɵɵrestoreView(i);var e=n.$implicit,t=n.index;return u.ɵɵnextContext().SortToggle(e,t)}),u.ɵɵelement(1,"span",10),u.ɵɵelement(2,"b"),u.ɵɵelementEnd()),2&e&&(t=n.$implicit,e=u.ɵɵnextContext(),u.ɵɵclassProp("headerSortUp",t.sorted_by&&"asc"==e.sorting)("headerSortDown",t.sorted_by&&"desc"==e.sorting),u.ɵɵadvance(1),u.ɵɵproperty("cleanHTML",t.text))}function ir(e,t){1&e&&u.ɵɵelement(0,"td",10),2&e&&(t=t.$implicit,u.ɵɵproperty("cleanHTML",t))}function rr(e,t){var n,i;1&e&&(u.ɵɵelementStart(0,"tr"),u.ɵɵtemplate(1,ir,1,1,"td",12),u.ɵɵelementEnd()),2&e&&(n=(i=u.ɵɵnextContext()).index,e=i.$implicit,i=u.ɵɵnextContext(),u.ɵɵclassProp("ng-enter-element",n>=i.def_limit),u.ɵɵadvance(1),u.ɵɵproperty("ngForOf",e)("ngForTrackBy",i.trackByIndex))}function or(e,t){1&e&&(u.ɵɵelementContainerStart(0),u.ɵɵtemplate(1,rr,2,4,"tr",11),u.ɵɵelementContainerEnd()),2&e&&(e=t.index,t=u.ɵɵnextContext(),u.ɵɵadvance(1),u.ɵɵproperty("ngIf",e<t.limit||t.show_all))}function sr(e,t){var n;1&e&&(n=u.ɵɵgetCurrentView(),u.ɵɵelementStart(0,"div",13),u.ɵɵelementStart(1,"button",14),u.ɵɵlistener("onTap",function(){return u.ɵɵrestoreView(n),u.ɵɵnextContext().ToggleMore()}),u.ɵɵelement(2,"i",15),u.ɵɵelementStart(3,"span"),u.ɵɵtext(4),u.ɵɵelementEnd(),u.ɵɵelementEnd(),u.ɵɵelementEnd()),2&e&&(e=u.ɵɵnextContext(),u.ɵɵadvance(1),u.ɵɵclassProp("loadactive",e.toggling_display),u.ɵɵadvance(3),u.ɵɵtextInterpolate(e.show_all?"Show Less":"Show All"))}var ar=(lr.prototype.ngOnInit=function(){var o=this;this._inputValue=new u.BehaviorSubject(""),this.input.placeholder="&#xe80f;&nbsp;&nbsp;Search by "+(this.index||""),Object.defineProperty(this.input,"value",{get:function(){return o._inputValue.getValue()},set:function(e){o._inputValue.next(e)}}),this._inputValue.pipe(u.delay(50)).subscribe(function(i){2<i.length?o.itemsTable=o._itemsTableOrg.filter(function(e){var n=!1;return P(e,function(e,t){if(t==o._search_by){t=e.toString().toLowerCase(),e=i.toString().toLowerCase();return n=-1<t.indexOf(e),!1}}),n}):o.itemsTable=o._itemsTableOrg.slice(0),o._cd.detectChanges()}),this._max_limit=this.items.length,P(this.items,function(e,n){var i=[],r=0;T(e,function(e,t){0==n&&(o.headersTable.push({sorted_by:!1,text:t}),t==o.index&&(o._search_by=r),r++),i.push(e)}),o.itemsTable.push(i),o._itemsTableOrg.push(i)})},lr.prototype.ngAfterViewInit=function(){var e;V()||((e=document.createElement("span")).innerHTML=this.input.placeholder,this.searchfield.nativeElement.setAttribute("placeholder",e.textContent))},lr.prototype.ngOnDestroy=function(){this._inputValue&&this._inputValue.complete},lr.prototype._SortBy=function(){function e(e,t){return e=e[n.sorting_row],t=t[n.sorting_row],"asc"==n.sorting?w(e)?t-e:e<t?-1:t<e?1:0:w(e)?e-t:t<e?-1:e<t?1:0}var n=this;this.itemsTable.sort(e),j(function(){n._itemsTableOrg.sort(e)})},lr.prototype.trackByIndex=function(e){return e},lr.prototype.SortToggle=function(e,t){this.sorting_row=t,e.sorted_by?"desc"==this.sorting?this.sorting="asc":this.sorting="desc":(this.headersTable.forEach(function(e){e.sorted_by=!1}),e.sorted_by=!0,this.sorting="asc"),this._SortBy()},lr.prototype.Search=function(e){e=e.target.value;this.input.value=e},lr.prototype.ToggleMore=function(){var n,i,r=this;this.toggling_display||(this.toggling_display=!0,n=0,this._scrollservice.onScroll.pipe(u.take(1)).subscribe(function(e){n=e}),i=!1,j(function(){var e,t;(r.show_all?e=function(){r.limit--,r.limit>r.def_limit?r.limit%(2*r.def_limit)==0?j(e):e():(r.show_all=!1,r.toggling_display=!1)}:t=function(){r.limit++,i||(j(function(){r._scrollservice.scrollTo({position:n,timing:0})}),i=!0),r.limit<r._max_limit?r.limit%(2*r.def_limit)==0?j(t):t():(r.show_all=!0,r.toggling_display=!1)})()}))},lr.ɵfac=function(e){return new(e||lr)(u.ɵɵdirectiveInject(te),u.ɵɵdirectiveInject(u.ChangeDetectorRef))},lr.ɵcmp=u.ɵɵdefineComponent({type:lr,selectors:[["div",8,"city-table-container"]],viewQuery:function(e,t){var n;1&e&&u.ɵɵviewQuery(er,!0),2&e&&u.ɵɵqueryRefresh(n=u.ɵɵloadQuery())&&(t.searchfield=n.first)},inputs:{index:"index",items:"items"},attrs:tr,decls:13,vars:11,consts:[[1,"search-city-container"],[3,"id","for","hidden"],["type","text","role","textbox",1,"single",3,"value","id","input"],["searchfield",""],[1,"data-table"],["border","0","cellpadding","0","cellspacing","0",1,"city-table","center-aligned","table"],["zing-touch","",3,"headerSortUp","headerSortDown","onTap",4,"ngFor","ngForOf","ngForTrackBy"],[4,"ngFor","ngForOf","ngForTrackBy"],["class","btn-toggle-container",4,"ngIf"],["zing-touch","",3,"onTap"],[3,"cleanHTML"],[3,"ng-enter-element",4,"ngIf"],[3,"cleanHTML",4,"ngFor","ngForOf","ngForTrackBy"],[1,"btn-toggle-container"],["zing-touch","",1,"btn","blue","with-loader",3,"onTap"],[1,"btn-loader"]],template:function(e,t){1&e&&(u.ɵɵelementStart(0,"div",0),u.ɵɵelementStart(1,"label",1),u.ɵɵtext(2,"Search"),u.ɵɵelementEnd(),u.ɵɵelementStart(3,"input",2,3),u.ɵɵlistener("input",function(e){return t.Search(e)}),u.ɵɵelementEnd(),u.ɵɵelementEnd(),u.ɵɵelementStart(5,"div",4),u.ɵɵelementStart(6,"table",5),u.ɵɵelementStart(7,"thead"),u.ɵɵelementStart(8,"tr"),u.ɵɵtemplate(9,nr,3,5,"th",6),u.ɵɵelementEnd(),u.ɵɵelementEnd(),u.ɵɵelementStart(10,"tbody"),u.ɵɵtemplate(11,or,2,1,"ng-container",7),u.ɵɵelementEnd(),u.ɵɵelementEnd(),u.ɵɵelementEnd(),u.ɵɵtemplate(12,sr,5,3,"div",8)),2&e&&(u.ɵɵadvance(1),u.ɵɵproperty("id",t.index+"-ipt-label")("for",t.index+"-ipt")("hidden",!0),u.ɵɵadvance(2),u.ɵɵproperty("value",t.input.value)("id",t.index+"-ipt"),u.ɵɵattribute("aria-labelledby",t.index+"-ipt-label"),u.ɵɵadvance(6),u.ɵɵproperty("ngForOf",t.headersTable)("ngForTrackBy",t.trackByIndex),u.ɵɵadvance(2),u.ɵɵproperty("ngForOf",t.itemsTable)("ngForTrackBy",t.trackByIndex),u.ɵɵadvance(1),u.ɵɵproperty("ngIf",t.itemsTable.length>=t.limit))},directives:[u.NgForOf,u.NgIf,K,ke],encapsulation:2}),lr);function lr(e,t){this._scrollservice=e,this._cd=t,this.input={placeholder:""},this._search_by=null,this.headersTable=[],this.itemsTable=[],this._itemsTableOrg=[],this.sorting_row=null,this.show_all=!1,this.toggling_display=!1,this.limit=30,this._max_limit=30,this.def_limit=30}u.setClassMetadata(ar,[{type:u.Component,args:[{selector:"div.city-table-container",templateUrl:"/views/pages/edu/edu-table-search.html"}]}],function(){return[{type:te},{type:u.ChangeDetectorRef}]},{index:[{type:u.Input}],items:[{type:u.Input}],searchfield:[{type:u.ViewChild,args:["searchfield"]}]});var cr=(ur.ɵmod=u.ɵɵdefineNgModule({type:ur}),ur.ɵinj=u.ɵɵdefineInjector({factory:function(e){return new(e||ur)},imports:[[u.CommonModule,Fe]]}),ur);function ur(){}u.setClassMetadata(cr,[{type:u.NgModule,args:[{declarations:[ar],exports:[ar],entryComponents:[ar],imports:[u.CommonModule,Fe]}]}],null,null);var hr=(dr.prototype.ControlPopup=function(){var e=this,t=this._el.nativeElement,n=t.querySelector(".fcs-main-content");if(this.is_hidden=!this.is_hidden,this.initial)return this._render.setStyle(t,"bottom",-1*n.offsetHeight+"px"),this.initial=!1,this.active=!0,this._cd.detectChanges(),void j(function(){e._render.setStyle(t,"bottom","0px"),e._cd.detectChanges()});this.initial=!1,this.active=!0,this.is_hidden?this._render.setStyle(t,"bottom",-1*n.offsetHeight+"px"):this._render.setStyle(t,"bottom","0px"),this._cd.detectChanges()},dr.prototype.ngAfterViewInit=function(){var n=this;j(function(){var e=n._el.nativeElement,t=e.querySelector(".fcs-main-content");n._render.setStyle(e,"bottom",-1*t.offsetHeight+"px"),n._cd.detectChanges(),j(function(){n.initial=!1,n.active=!0,n._cd.detectChanges()})})},dr.ɵfac=function(e){return new(e||dr)(u.ɵɵdirectiveInject(u.ElementRef),u.ɵɵdirectiveInject(u.Renderer2),u.ɵɵdirectiveInject(u.ChangeDetectorRef))},dr.ɵcmp=u.ɵɵdefineComponent({type:dr,selectors:[["free-credit"]],hostVars:6,hostBindings:function(e,t){2&e&&u.ɵɵclassProp("fcs-hidden",t.is_hidden)("fcs-render",t.initial)("fcs-active",t.active)},decls:25,vars:0,consts:[["zing-touch","",1,"fcs-head-content","bold-font",3,"onTap"],[1,"fcs-cta-arrow"],[1,"af-icon-up-open"],[1,"af-icon-cross"],[1,"fcs-main-content"],[1,"fcs-mc-hd"],[1,"fcs-mc-prg","semi-bold-font"],[1,"fcs-mc-center"],["onclick","location.href='/join/';",1,"fcs-mc-button","semi-bold-font"],[1,"fcs-mc-bt-p","semi-bold-font"]],template:function(e,t){1&e&&(u.ɵɵelementStart(0,"div",0),u.ɵɵlistener("onTap",function(){return t.ControlPopup()}),u.ɵɵtext(1," GET YOUR FREE CREDIT SCORE & REPORT "),u.ɵɵelementStart(2,"span",1),u.ɵɵelement(3,"i",2),u.ɵɵelement(4,"i",3),u.ɵɵelementEnd(),u.ɵɵelementEnd(),u.ɵɵelementStart(5,"div",4),u.ɵɵelementStart(6,"div",5),u.ɵɵtext(7,"Join WalletHub"),u.ɵɵelementEnd(),u.ɵɵelementStart(8,"p",6),u.ɵɵtext(9,"+ 100% FREE"),u.ɵɵelementEnd(),u.ɵɵelementStart(10,"p",6),u.ɵɵtext(11,"+ Unlimited Credit Reports"),u.ɵɵelementEnd(),u.ɵɵelementStart(12,"p",6),u.ɵɵtext(13,"+ Unlimited Credit Scores"),u.ɵɵelementEnd(),u.ɵɵelementStart(14,"p",6),u.ɵɵtext(15,"+ Credit Monitoring Protection"),u.ɵɵelementEnd(),u.ɵɵelementStart(16,"p",6),u.ɵɵtext(17,"+ Credit Improvement Tips"),u.ɵɵelementEnd(),u.ɵɵelementStart(18,"p",6),u.ɵɵtext(19,"+ Automatically Finds Savings"),u.ɵɵelementEnd(),u.ɵɵelementStart(20,"div",7),u.ɵɵelementStart(21,"button",8),u.ɵɵtext(22,"SIGN UP FOR FREE"),u.ɵɵelementEnd(),u.ɵɵelementStart(23,"p",9),u.ɵɵtext(24,"No credit card needed"),u.ɵɵelementEnd(),u.ɵɵelementEnd(),u.ɵɵelementEnd())},directives:[K],encapsulation:2,changeDetection:0}),dr);function dr(e,t,n){this._el=e,this._render=t,this._cd=n,this.is_hidden=!0,this.initial=!0,this.active=!1}u.setClassMetadata(hr,[{type:u.Component,args:[{selector:"free-credit",templateUrl:"/views/components/free-credit-score-modal.html",host:{"[class.fcs-hidden]":"is_hidden","[class.fcs-render]":"initial","[class.fcs-active]":"active"},changeDetection:u.ChangeDetectionStrategy.OnPush}]}],function(){return[{type:u.ElementRef},{type:u.Renderer2},{type:u.ChangeDetectorRef}]},null);var mr=(pr.ɵmod=u.ɵɵdefineNgModule({type:pr}),pr.ɵinj=u.ɵɵdefineInjector({factory:function(e){return new(e||pr)},imports:[[Fe,u.CommonModule]]}),pr);function pr(){}function gr(e){return(gr="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}u.setClassMetadata(mr,[{type:u.NgModule,args:[{declarations:[hr],entryComponents:[hr],imports:[Fe,u.CommonModule]}]}],null,null),$r=function(e){function i(e,t){for(var n=0;n<t.length;n++){var i=t[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,i.key,i)}}function n(e,t,n){return t&&i(e.prototype,t),n&&i(e,n),e}function r(e,t){if(e!==t)throw new TypeError("Cannot instantiate an arrow function")}function t(e,t){return e(t={exports:{}},t.exports),t.exports}function o(e){if("function"!=typeof e)throw TypeError(e+" is not a function!");return e}function p(i,r,e){if(o(i),void 0===r)return i;switch(e){case 1:return function(e){return i.call(r,e)};case 2:return function(e,t){return i.call(r,e,t)};case 3:return function(e,t,n){return i.call(r,e,t,n)}}return function(){return i.apply(r,arguments)}}function s(e){return y.call(e).slice(8,-1)}function l(e){return"Symbol(".concat(void 0===e?"":e,")_",(++S+w).toString(36))}function a(e){var t;return void 0===e?"Undefined":null===e?"Null":"string"==typeof(e=function(e,t){try{return e[t]}catch(e){}}(t=Object(e),k))?e:x?s(t):"Object"==(e=s(t))&&"function"==typeof t.callee?"Arguments":e}function c(e){return"object"===gr(e)?null!==e:"function"==typeof e}function m(e){if(!c(e))throw TypeError(e+" is not an object!");return e}function u(e){try{return!!e()}catch(e){return!0}}function h(e){return C?O.createElement(e):{}}function d(e,t){if(!c(e))return e;var n,i;if(t&&"function"==typeof(n=e.toString)&&!c(i=n.call(e)))return i;if("function"==typeof(n=e.valueOf)&&!c(i=n.call(e)))return i;if(!t&&"function"==typeof(n=e.toString)&&!c(i=n.call(e)))return i;throw TypeError("Can't convert object to primitive value")}function g(e,t){return{enumerable:!(1&e),configurable:!(2&e),writable:!(4&e),value:t}}function f(e,t){return L.call(e,t)}var v=t(function(e){e=e.exports="undefined"!=typeof window&&window.Math==Math?window:"undefined"!=typeof self&&self.Math==Math?self:Function("return this")();"number"==typeof __g&&(__g=e)}),y={}.toString,b=t(function(e){e=e.exports={version:"2.6.1"};"number"==typeof __e&&(__e=e)}),_=t(function(e){var t="__core-js_shared__",n=v[t]||(v[t]={});(e.exports=function(e,t){return n[e]||(n[e]=void 0!==t?t:{})})("versions",[]).push({version:b.version,mode:"global",copyright:"© 2018 Denis Pushkarev (zloirock.ru)"})}),S=0,w=Math.random(),E=t(function(e){var t=_("wks"),n=v.Symbol,i="function"==typeof n;(e.exports=function(e){return t[e]||(t[e]=i&&n[e]||(i?n:l)("Symbol."+e))}).store=t}),k=E("toStringTag"),x="Arguments"==s(function(){return arguments}()),P=!u(function(){return 7!=Object.defineProperty({},"a",{get:function(){return 7}}).a}),O=v.document,C=c(O)&&c(O.createElement),N=!P&&!u(function(){return 7!=Object.defineProperty(h("div"),"a",{get:function(){return 7}}).a}),T=Object.defineProperty,I={f:P?Object.defineProperty:function(e,t,n){if(m(e),t=d(t,!0),m(n),N)try{return T(e,t,n)}catch(e){}if("get"in n||"set"in n)throw TypeError("Accessors not supported!");return"value"in n&&(e[t]=n.value),e}},F=P?function(e,t,n){return I.f(e,t,g(1,n))}:function(e,t,n){return e[t]=n,e},L={}.hasOwnProperty,V=t(function(e){var o=l("src"),t="toString",n=Function[t],s=(""+n).split(t);b.inspectSource=function(e){return n.call(e)},(e.exports=function(e,t,n,i){var r="function"==typeof n;r&&(f(n,"name")||F(n,"name",t)),e[t]!==n&&(r&&(f(n,o)||F(n,o,e[t]?""+e[t]:s.join(String(t)))),e===v?e[t]=n:i?e[t]?e[t]=n:F(e,t,n):(delete e[t],F(e,t,n)))})(Function.prototype,t,function(){return"function"==typeof this&&this[o]||n.call(this)})}),A="prototype",M=function e(t,n,i){var r,o,s,a=t&e.F,l=t&e.G,c=t&e.P,u=t&e.B,h=l?v:t&e.S?v[n]||(v[n]={}):(v[n]||{})[A],d=l?b:b[n]||(b[n]={}),m=d[A]||(d[A]={});for(r in i=l?n:i)o=((s=!a&&h&&void 0!==h[r])?h:i)[r],s=u&&s?p(o,v):c&&"function"==typeof o?p(Function.call,o):o,h&&V(h,r,o,t&e.U),d[r]!=o&&F(d,r,s),c&&m[r]!=o&&(m[r]=o)};v.core=b,M.F=1,M.G=2,M.S=4,M.P=8,M.B=16,M.W=32,M.U=64,M.R=128;function z(e){return isNaN(e=+e)?0:(0<e?K:G)(e)}function R(e){return 0<e?q(z(e),9007199254740991):0}function D(){var e,t=+this;se.hasOwnProperty(t)&&(e=se[t],delete se[t],e())}var B,j=M,U={},W=E("iterator"),H=Array.prototype,G=Math.ceil,K=Math.floor,q=Math.min,Z=E("iterator"),$=b.getIteratorMethod=function(e){if(null!=e)return e[Z]||e["@@iterator"]||U[a(e)]},Q=t(function(e){var h={},d={},e=e.exports=function(e,t,n,i,r){var o,s,a,l,r=r?function(){return e}:$(e),c=p(n,i,t?2:1),u=0;if("function"!=typeof r)throw TypeError(e+" is not iterable!");if(void 0===(i=r)||U.Array!==i&&H[W]!==i){for(a=r.call(e);!(s=a.next()).done;)if((l=function(t,e,n,i){try{return i?e(m(n)[0],n[1]):e(n)}catch(e){var r=t.return;throw void 0!==r&&m(r.call(t)),e}}(a,c,s.value,t))===h||l===d)return l}else for(o=R(e.length);u<o;u++)if((l=t?c(m(s=e[u])[0],s[1]):c(e[u]))===h||l===d)return l};e.BREAK=h,e.RETURN=d}),J=E("species"),Y=v.document,X=Y&&Y.documentElement,ee=v.process,te=v.setImmediate,ne=v.clearImmediate,ie=v.MessageChannel,re=v.Dispatch,oe=0,se={},ae="onreadystatechange",le=function(e){D.call(e.data)};te&&ne||(te=function(e){for(var t=[],n=1;n<arguments.length;)t.push(arguments[n++]);return se[++oe]=function(){!function(e,t,n){var i=void 0===n;switch(t.length){case 0:return i?e():e.call(n);case 1:return i?e(t[0]):e.call(n,t[0]);case 2:return i?e(t[0],t[1]):e.call(n,t[0],t[1]);case 3:return i?e(t[0],t[1],t[2]):e.call(n,t[0],t[1],t[2]);case 4:return i?e(t[0],t[1],t[2],t[3]):e.call(n,t[0],t[1],t[2],t[3])}e.apply(n,t)}("function"==typeof e?e:Function(e),t)},B(oe),oe},ne=function(e){delete se[e]},"process"==s(ee)?B=function(e){ee.nextTick(p(D,e,1))}:re&&re.now?B=function(e){re.now(p(D,e,1))}:ie?(pt=(ct=new ie).port2,ct.port1.onmessage=le,B=p(pt.postMessage,pt,1)):v.addEventListener&&"function"==typeof postMessage&&!v.importScripts?(B=function(e){v.postMessage(e+"","*")},v.addEventListener("message",le,!1)):B=ae in h("script")?function(e){X.appendChild(h("script"))[ae]=function(){X.removeChild(this),D.call(e)}}:function(e){setTimeout(p(D,e,1),0)});var ce={set:te,clear:ne},ue=ce.set,he=v.MutationObserver||v.WebKitMutationObserver,de=v.process,me=v.Promise,pe="process"==s(de);function ge(e){var n,i;this.promise=new e(function(e,t){if(void 0!==n||void 0!==i)throw TypeError("Bad Promise constructor");n=e,i=t}),this.resolve=o(n),this.reject=o(i)}function fe(e){try{return{e:!1,v:e()}}catch(e){return{e:!0,v:e}}}var ve={f:function(e){return new ge(e)}},ye=v.navigator,be=ye&&ye.userAgent||"",_e=I.f,Se=E("toStringTag"),M=function(e,t,n){e&&!f(e=n?e:e.prototype,Se)&&_e(e,Se,{configurable:!0,value:t})},we=E("species"),Ee=E("iterator"),ke=!1;try{[7][Ee]().return=function(){ke=!0}}catch(e){}var xe,Pe,Oe,Ce,Ne,Te,Ie=ce.set,Fe=(Ce=pe?function(){de.nextTick(Le)}:!he||v.navigator&&v.navigator.standalone?me&&me.resolve?(Oe=me.resolve(void 0),function(){Oe.then(Le)}):function(){ue.call(v,Le)}:(Ne=!0,Te=document.createTextNode(""),new he(Le).observe(Te,{characterData:!0}),function(){Te.data=Ne=!Ne}),function(e){e={fn:e,next:void 0};Pe&&(Pe.next=e),xe||(xe=e,Ce()),Pe=e});function Le(){var e,t;for(pe&&(e=de.domain)&&e.exit();xe;){t=xe.fn,xe=xe.next;try{t()}catch(e){throw xe?Ce():Pe=void 0,e}}Pe=void 0,e&&e.enter()}function Ve(){}function Ae(e){var t;return!(!c(e)||"function"!=typeof(t=e.then))&&t}function Me(u,t){var n;u._n||(u._n=!0,n=u._c,Fe(function(){for(var l=u._v,c=1==u._s,e=0;n.length>e;)!function(e){var t,n,i,r=c?e.ok:e.fail,o=e.resolve,s=e.reject,a=e.domain;try{r?(c||(2==u._h&&Xe(u),u._h=1),!0===r?t=l:(a&&a.enter(),t=r(l),a&&(a.exit(),i=!0)),t===e.promise?s(Ge("Promise-chain cycle")):(n=Ae(t))?n.call(t,o,s):o(t)):s(l)}catch(e){a&&!i&&a.exit(),s(e)}}(n[e++]);u._c=[],u._n=!1,t&&!u._h&&Je(u)}))}function ze(e){var t=this;t._d||(t._d=!0,(t=t._w||t)._v=e,t._s=2,t._a||(t._a=t._c.slice()),Me(t,!0))}function Re(e){var n,i=this;if(!i._d){i._d=!0,i=i._w||i;try{if(i===e)throw Ge("Promise can't be resolved itself");(n=Ae(e))?Fe(function(){var t={_w:i,_d:!1};try{n.call(e,p(Re,t,1),p(ze,t,1))}catch(e){ze.call(t,e)}}):(i._v=e,i._s=1,Me(i,!1))}catch(e){ze.call({_w:i,_d:!1},e)}}}var De,Be,je,Ue,We,He="Promise",Ge=v.TypeError,Ke=v.process,Y=Ke&&Ke.versions,qe=Y&&Y.v8||"",Ze=v[He],$e="process"==a(Ke),Qe=Be=ve.f,ie=!!function(){try{var e=Ze.resolve(1),t=(e.constructor={})[E("species")]=function(e){e(Ve,Ve)};return($e||"function"==typeof PromiseRejectionEvent)&&e.then(Ve)instanceof t&&0!==qe.indexOf("6.6")&&-1===be.indexOf("Chrome/66")}catch(e){}}(),Je=function(r){Ie.call(v,function(){var e,t,n=r._v,i=Ye(r);if(i&&(e=fe(function(){$e?Ke.emit("unhandledRejection",n,r):(t=v.onunhandledrejection)?t({promise:r,reason:n}):(t=v.console)&&t.error&&t.error("Unhandled promise rejection",n)}),r._h=$e||Ye(r)?2:1),r._a=void 0,i&&e.e)throw e.v})},Ye=function(e){return 1!==e._h&&0===(e._a||e._c).length},Xe=function(t){Ie.call(v,function(){var e;$e?Ke.emit("rejectionHandled",t):(e=v.onrejectionhandled)&&e({promise:t,reason:t._v})})};ie||(Ze=function(e){!function(e,t,n){if(!(e instanceof Ze)||void 0!==n&&n in e)throw TypeError(t+": incorrect invocation!")}(this,He,"_h"),o(e),De.call(this);try{e(p(Re,this,1),p(ze,this,1))}catch(e){ze.call(this,e)}},(De=function(e){this._c=[],this._a=void 0,this._s=0,this._d=!1,this._v=void 0,this._h=0,this._n=!1}).prototype=function(e,t,n){for(var i in t)V(e,i,t[i],n);return e}(Ze.prototype,{then:function(e,t){var n,i,r,r=Qe((i=Ze,void 0===(n=m(n=this).constructor)||null==(r=m(n)[J])?i:o(r)));return r.ok="function"!=typeof e||e,r.fail="function"==typeof t&&t,r.domain=$e?Ke.domain:void 0,this._c.push(r),this._a&&this._a.push(r),this._s&&Me(this,!1),r.promise},catch:function(e){return this.then(void 0,e)}}),je=function(){var e=new De;this.promise=e,this.resolve=p(Re,e,1),this.reject=p(ze,e,1)},ve.f=Qe=function(e){return e===Ze||e===Ue?new je:Be(e)}),j(j.G+j.W+j.F*!ie,{Promise:Ze}),M(Ze,He),We=v[We=He],P&&We&&!We[we]&&I.f(We,we,{configurable:!0,get:function(){return this}}),Ue=b[He],j(j.S+j.F*!ie,He,{reject:function(e){var t=Qe(this);return(0,t.reject)(e),t.promise}}),j(j.S+j.F*!ie,He,{resolve:function(e){return function(e,t){if(m(e),c(t)&&t.constructor===e)return t;e=ve.f(e);return(0,e.resolve)(t),e.promise}(this,e)}}),j(j.S+j.F*!(ie&&function(e,t){if(!t&&!ke)return!1;var n=!1;try{var i=[7],r=i[Ee]();r.next=function(){return{done:n=!0}},i[Ee]=function(){return r},e(i)}catch(e){}return n}(function(e){Ze.all(e).catch(Ve)})),He,{all:function(e){var s=this,t=Qe(s),a=t.resolve,l=t.reject,n=fe(function(){var i=[],r=0,o=1;Q(e,!1,function(e){var t=r++,n=!1;i.push(void 0),o++,s.resolve(e).then(function(e){n||(n=!0,i[t]=e,--o||a(i))},l)}),--o||a(i)});return n.e&&l(n.v),t.promise},race:function(e){var t=this,n=Qe(t),i=n.reject,r=fe(function(){Q(e,!1,function(e){t.resolve(e).then(n.resolve,i)})});return r.e&&i(r.v),n.promise}});function et(e){var t=b.Symbol||(b.Symbol=v.Symbol||{});"_"==e.charAt(0)||e in t||nt(t,e,{value:tt.f(e)})}var tt={f:E},nt=I.f;et("asyncIterator");function it(e){return ut(function(e){if(null==e)throw TypeError("Can't call method on  "+e);return e}(e))}function rt(e,t){var n,i=it(e),r=0,o=[];for(n in i)n!=ft&&f(i,n)&&o.push(n);for(;t.length>r;)f(i,n=t[r++])&&(~gt(o,n)||o.push(n));return o}function ot(){}function st(e){var t=Wt[e]=Pt(Mt[Dt]);return t._k=e,t}function at(e,t){m(e);for(var n,i=function(e){var t=yt(e),n=bt.f;if(n)for(var i,r=n(e),o=_t.f,s=0;r.length>s;)o.call(e,i=r[s++])&&t.push(i);return t}(t=it(t)),r=0,o=i.length;r<o;)$t(e,n=i[r++],t[n]);return e}var lt,ct=t(function(e){function n(e){t(e,i,{value:{i:"O"+ ++r,w:{}}})}var i=l("meta"),t=I.f,r=0,o=Object.isExtensible||function(){return!0},s=!u(function(){return o(Object.preventExtensions({}))}),a=e.exports={KEY:i,NEED:!1,fastKey:function(e,t){if(!c(e))return"symbol"==gr(e)?e:("string"==typeof e?"S":"P")+e;if(!f(e,i)){if(!o(e))return"F";if(!t)return"E";n(e)}return e[i].i},getWeak:function(e,t){if(!f(e,i)){if(!o(e))return!0;if(!t)return!1;n(e)}return e[i].w},onFreeze:function(e){return s&&a.NEED&&o(e)&&!f(e,i)&&n(e),e}}}),ut=Object("z").propertyIsEnumerable(0)?Object:function(e){return"String"==s(e)?e.split(""):Object(e)},ht=Math.max,dt=Math.min,mt=_("keys"),pt=function(e){return mt[e]||(mt[e]=l(e))},gt=(lt=!1,function(e,t,n){var i,r=it(e),o=R(r.length),s=(e=o,(n=z(n=n))<0?ht(n+e,0):dt(n,e));if(lt&&t!=t){for(;s<o;)if((i=r[s++])!=i)return!0}else for(;s<o;s++)if((lt||s in r)&&r[s]===t)return lt||s||0;return!lt&&-1}),ft=pt("IE_PROTO"),vt="constructor,hasOwnProperty,isPrototypeOf,propertyIsEnumerable,toLocaleString,toString,valueOf".split(","),yt=Object.keys||function(e){return rt(e,vt)},bt={f:Object.getOwnPropertySymbols},_t={f:{}.propertyIsEnumerable},St=Array.isArray||function(e){return"Array"==s(e)},wt=P?Object.defineProperties:function(e,t){m(e);for(var n,i=yt(t),r=i.length,o=0;o<r;)I.f(e,n=i[o++],t[n]);return e},Et=pt("IE_PROTO"),kt="prototype",xt=function(){var e=h("iframe"),t=vt.length;for(e.style.display="none",X.appendChild(e),e.src="javascript:",(e=e.contentWindow.document).open(),e.write("<script>document.F=Object<\/script>"),e.close(),xt=e.F;t--;)delete xt[kt][vt[t]];return xt()},Pt=Object.create||function(e,t){var n;return null!==e?(ot[kt]=m(e),n=new ot,ot[kt]=null,n[Et]=e):n=xt(),void 0===t?n:wt(n,t)},Ot=vt.concat("length","prototype"),le={f:Object.getOwnPropertyNames||function(e){return rt(e,Ot)}},Ct=le.f,Nt={}.toString,Tt="object"==("undefined"==typeof window?"undefined":gr(window))&&window&&Object.getOwnPropertyNames?Object.getOwnPropertyNames(window):[],te={f:function(e){return Tt&&"[object Window]"==Nt.call(e)?function(e){try{return Ct(e)}catch(e){return Tt.slice()}}(e):Ct(it(e))}},It=Object.getOwnPropertyDescriptor,ne={f:P?It:function(e,t){if(e=it(e),t=d(t,!0),N)try{return It(e,t)}catch(e){}if(f(e,t))return g(!_t.f.call(e,t),e[t])}},Ft=ct.KEY,Lt=ne.f,Vt=I.f,At=te.f,Mt=v.Symbol,zt=v.JSON,Rt=zt&&zt.stringify,Dt="prototype",Bt=E("_hidden"),ye=E("toPrimitive"),jt={}.propertyIsEnumerable,Ut=_("symbol-registry"),Wt=_("symbols"),Ht=_("op-symbols"),Gt=Object[Dt],ce="function"==typeof Mt,Y=v.QObject,Kt=!Y||!Y[Dt]||!Y[Dt].findChild,qt=P&&u(function(){return 7!=Pt(Vt({},"a",{get:function(){return Vt(this,"a",{value:7}).a}})).a})?function(e,t,n){var i=Lt(Gt,t);i&&delete Gt[t],Vt(e,t,n),i&&e!==Gt&&Vt(Gt,t,i)}:Vt,Zt=ce&&"symbol"==gr(Mt.iterator)?function(e){return"symbol"==gr(e)}:function(e){return e instanceof Mt},$t=function(e,t,n){return e===Gt&&$t(Ht,t,n),m(e),t=d(t,!0),m(n),f(Wt,t)?(n.enumerable?(f(e,Bt)&&e[Bt][t]&&(e[Bt][t]=!1),n=Pt(n,{enumerable:g(0,!1)})):(f(e,Bt)||Vt(e,Bt,g(1,{})),e[Bt][t]=!0),qt(e,t,n)):Vt(e,t,n)},ie=function(e){var t=jt.call(this,e=d(e,!0));return!(this===Gt&&f(Wt,e)&&!f(Ht,e))&&(!(t||!f(this,e)||!f(Wt,e)||f(this,Bt)&&this[Bt][e])||t)},pt=function(e,t){if(e=it(e),t=d(t,!0),e!==Gt||!f(Wt,t)||f(Ht,t)){var n=Lt(e,t);return!n||!f(Wt,t)||f(e,Bt)&&e[Bt][t]||(n.enumerable=!0),n}},ct=function(e){for(var t,n=At(it(e)),i=[],r=0;n.length>r;)f(Wt,t=n[r++])||t==Bt||t==Ft||i.push(t);return i},Y=function(e){for(var t,n=e===Gt,i=At(n?Ht:it(e)),r=[],o=0;i.length>o;)!f(Wt,t=i[o++])||n&&!f(Gt,t)||r.push(Wt[t]);return r};ce||(V((Mt=function(){if(this instanceof Mt)throw TypeError("Symbol is not a constructor!");function t(e){this===Gt&&t.call(Ht,e),f(this,Bt)&&f(this[Bt],n)&&(this[Bt][n]=!1),qt(this,n,g(1,e))}var n=l(0<arguments.length?arguments[0]:void 0);return P&&Kt&&qt(Gt,n,{configurable:!0,set:t}),st(n)})[Dt],"toString",function(){return this._k}),ne.f=pt,I.f=$t,le.f=te.f=ct,_t.f=ie,bt.f=Y,P&&V(Gt,"propertyIsEnumerable",ie,!0),tt.f=function(e){return st(E(e))}),j(j.G+j.W+j.F*!ce,{Symbol:Mt});for(var Qt="hasInstance,isConcatSpreadable,iterator,match,replace,search,species,split,toPrimitive,toStringTag,unscopables".split(","),Jt=0;Qt.length>Jt;)E(Qt[Jt++]);for(var Yt=yt(E.store),Xt=0;Yt.length>Xt;)et(Yt[Xt++]);j(j.S+j.F*!ce,"Symbol",{for:function(e){return f(Ut,e+="")?Ut[e]:Ut[e]=Mt(e)},keyFor:function(e){if(!Zt(e))throw TypeError(e+" is not a symbol!");for(var t in Ut)if(Ut[t]===e)return t},useSetter:function(){Kt=!0},useSimple:function(){Kt=!1}}),j(j.S+j.F*!ce,"Object",{create:function(e,t){return void 0===t?Pt(e):at(Pt(e),t)},defineProperty:$t,defineProperties:at,getOwnPropertyDescriptor:pt,getOwnPropertyNames:ct,getOwnPropertySymbols:Y}),zt&&j(j.S+j.F*(!ce||u(function(){var e=Mt();return"[null]"!=Rt([e])||"{}"!=Rt({a:e})||"{}"!=Rt(Object(e))})),"JSON",{stringify:function(e){for(var t,n,i=[e],r=1;r<arguments.length;)i.push(arguments[r++]);if(n=t=i[1],(c(t)||void 0!==e)&&!Zt(e))return St(t)||(t=function(e,t){if("function"==typeof n&&(t=n.call(this,e,t)),!Zt(t))return t}),i[1]=t,Rt.apply(zt,i)}}),Mt[Dt][ye]||F(Mt[Dt],ye,Mt[Dt].valueOf),M(Mt,"Symbol"),M(Math,"Math",!0),M(v.JSON,"JSON",!0);var en,tn=Symbol("loadScript"),nn=Symbol("instance"),M=function(){function t(){if(!function(e){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this),this[nn])return this[nn];this[nn]=this}return n(t,[{key:nn,get:function(){return en},set:function(e){en=e}}]),n(t,[{key:"reset",value:function(){en=null}},{key:tn,value:function(){var i=this;return this.scriptPromise||(this.scriptPromise=new Promise(function(t){r(this,i);var e=document.getElementsByTagName("body")[0],n=document.createElement("script");n.type="text/javascript",n.onload=function(){var e=this;rn.api=window.google,rn.api.charts.load("current",{packages:["corechart","table"]}),rn.api.charts.setOnLoadCallback(function(){r(this,e),t()}.bind(this))},n.src="https://www.gstatic.com/charts/loader.js",e.appendChild(n)}.bind(this))),this.scriptPromise}},{key:"load",value:function(t,n){var i=this;return this[tn]().then(function(){if(r(this,i),n){var e={},e=n instanceof Object?n:Array.isArray(n)?{packages:n}:{packages:[n]};this.api.charts.load("current",e),this.api.charts.setOnLoadCallback(t)}else{if("function"!=typeof t)throw"callback must be a function";t()}}.bind(this))}}]),t}(),rn=new M;e.GoogleCharts=rn,e.default=M,Object.defineProperty(e,"__esModule",{value:!0})},"object"===((Qr=void 0)===e?"undefined":gr(e))&&"undefined"!=typeof module?$r(e):"function"==typeof define&&define.amd?define(["exports"],$r):$r((Qr=Qr||self).googleCharts={});var fr={};function vr(e){return function(e){if(Array.isArray(e))return _r(e)}(e)||function(e){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e))return Array.from(e)}(e)||br(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function yr(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){if("undefined"==typeof Symbol||!(Symbol.iterator in Object(e)))return;var n=[],i=!0,r=!1,o=void 0;try{for(var s,a=e[Symbol.iterator]();!(i=(s=a.next()).done)&&(n.push(s.value),!t||n.length!==t);i=!0);}catch(e){r=!0,o=e}finally{try{i||null==a.return||a.return()}finally{if(r)throw o}}return n}(e,t)||br(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function br(e,t){if(e){if("string"==typeof e)return _r(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Map"===(n="Object"===n&&e.constructor?e.constructor.name:n)||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?_r(e,t):void 0}}function _r(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,i=new Array(t);n<t;n++)i[n]=e[n];return i}function Sr(e){return(Sr="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function wr(e,t){for(var n=0;n<t.length;n++){var i=t[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,i.key,i)}}fr.allowedTagList=["b","caption","cite","code","const","dd","del","div","dfn","dt","em","h1","h2","h3","h4","h5","h6","input","ins","kdb","label","li","option","output","p","q","s","sample","span","strong","td","th","u"],Object.freeze(fr.allowedTagList),Object.defineProperty(fr,"allowedTagList",{configurable:!1,writable:!1}),fr.keyCode={Backspace:8,Tab:9,Enter:13,Shift:16,Ctrl:17,Alt:18,Pause:19,CapsLock:20,Esc:27,Space:32,PageUp:33,PageDown:34,End:35,Home:36,LeftArrow:37,UpArrow:38,RightArrow:39,DownArrow:40,Insert:45,Delete:46,num0:48,num1:49,num2:50,num3:51,num4:52,num5:53,num6:54,num7:55,num8:56,num9:57,a:65,b:66,c:67,d:68,e:69,f:70,g:71,h:72,i:73,j:74,k:75,l:76,m:77,n:78,o:79,p:80,q:81,r:82,s:83,t:84,u:85,v:86,w:87,x:88,y:89,z:90,OSLeft:91,OSRight:92,ContextMenu:93,numpad0:96,numpad1:97,numpad2:98,numpad3:99,numpad4:100,numpad5:101,numpad6:102,numpad7:103,numpad8:104,numpad9:105,MultiplyNumpad:106,PlusNumpad:107,MinusNumpad:109,DotNumpad:110,SlashNumpad:111,F1:112,F2:113,F3:114,F4:115,F5:116,F6:117,F7:118,F8:119,F9:120,F10:121,F11:122,F12:123,NumLock:144,ScrollLock:145,HyphenFirefox:173,MyComputer:182,MyCalculator:183,Semicolon:186,Equal:187,Comma:188,Hyphen:189,Dot:190,Slash:191,Backquote:192,LeftBracket:219,Backslash:220,RightBracket:221,Quote:222,Command:224,AltGraph:225,AndroidDefault:229},Object.freeze(fr.keyCode),Object.defineProperty(fr,"keyCode",{configurable:!1,writable:!1}),fr.fromCharCodeKeyCode={0:"LaunchCalculator",8:"Backspace",9:"Tab",13:"Enter",16:"Shift",17:"Ctrl",18:"Alt",19:"Pause",20:"CapsLock",27:"Escape",32:" ",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"ArrowLeft",38:"ArrowUp",39:"ArrowRight",40:"ArrowDown",45:"Insert",46:"Delete",48:"0",49:"1",50:"2",51:"3",52:"4",53:"5",54:"6",55:"7",56:"8",57:"9",91:"OS",92:"OSRight",93:"ContextMenu",96:"0",97:"1",98:"2",99:"3",100:"4",101:"5",102:"6",103:"7",104:"8",105:"9",106:"*",107:"+",109:"-",110:".",111:"/",112:"F1",113:"F2",114:"F3",115:"F4",116:"F5",117:"F6",118:"F7",119:"F8",120:"F9",121:"F10",122:"F11",123:"F12",144:"NumLock",145:"ScrollLock",173:"-",182:"MyComputer",183:"MyCalculator",186:";",187:"=",188:",",189:"-",190:".",191:"/",192:"`",219:"[",220:"\\",221:"]",222:"'",224:"Meta",225:"AltGraph"},Object.freeze(fr.fromCharCodeKeyCode),Object.defineProperty(fr,"fromCharCodeKeyCode",{configurable:!1,writable:!1}),fr.keyName={Unidentified:"Unidentified",AndroidDefault:"AndroidDefault",Alt:"Alt",AltGr:"AltGraph",CapsLock:"CapsLock",Ctrl:"Control",Fn:"Fn",FnLock:"FnLock",Hyper:"Hyper",Meta:"Meta",OSLeft:"OS",OSRight:"OS",Command:"OS",NumLock:"NumLock",ScrollLock:"ScrollLock",Shift:"Shift",Super:"Super",Symbol:"Symbol",SymbolLock:"SymbolLock",Enter:"Enter",Tab:"Tab",Space:" ",LeftArrow:"ArrowLeft",UpArrow:"ArrowUp",RightArrow:"ArrowRight",DownArrow:"ArrowDown",End:"End",Home:"Home",PageUp:"PageUp",PageDown:"PageDown",Backspace:"Backspace",Clear:"Clear",Copy:"Copy",CrSel:"CrSel",Cut:"Cut",Delete:"Delete",EraseEof:"EraseEof",ExSel:"ExSel",Insert:"Insert",Paste:"Paste",Redo:"Redo",Undo:"Undo",Accept:"Accept",Again:"Again",Attn:"Attn",Cancel:"Cancel",ContextMenu:"ContextMenu",Esc:"Escape",Execute:"Execute",Find:"Find",Finish:"Finish",Help:"Help",Pause:"Pause",Play:"Play",Props:"Props",Select:"Select",ZoomIn:"ZoomIn",ZoomOut:"ZoomOut",BrightnessDown:"BrightnessDown",BrightnessUp:"BrightnessUp",Eject:"Eject",LogOff:"LogOff",Power:"Power",PowerOff:"PowerOff",PrintScreen:"PrintScreen",Hibernate:"Hibernate",Standby:"Standby",WakeUp:"WakeUp",Compose:"Compose",Dead:"Dead",F1:"F1",F2:"F2",F3:"F3",F4:"F4",F5:"F5",F6:"F6",F7:"F7",F8:"F8",F9:"F9",F10:"F10",F11:"F11",F12:"F12",Print:"Print",num0:"0",num1:"1",num2:"2",num3:"3",num4:"4",num5:"5",num6:"6",num7:"7",num8:"8",num9:"9",a:"a",b:"b",c:"c",d:"d",e:"e",f:"f",g:"g",h:"h",i:"i",j:"j",k:"k",l:"l",m:"m",n:"n",o:"o",p:"p",q:"q",r:"r",s:"s",t:"t",u:"u",v:"v",w:"w",x:"x",y:"y",z:"z",A:"A",B:"B",C:"C",D:"D",E:"E",F:"F",G:"G",H:"H",I:"I",J:"J",K:"K",L:"L",M:"M",N:"N",O:"O",P:"P",Q:"Q",R:"R",S:"S",T:"T",U:"U",V:"V",W:"W",X:"X",Y:"Y",Z:"Z",Semicolon:";",Equal:"=",Comma:",",Hyphen:"-",Minus:"-",Plus:"+",Dot:".",Slash:"/",Backquote:"`",LeftParenthesis:"(",RightParenthesis:")",LeftBracket:"[",RightBracket:"]",Backslash:"\\",Quote:"'",numpad0:"0",numpad1:"1",numpad2:"2",numpad3:"3",numpad4:"4",numpad5:"5",numpad6:"6",numpad7:"7",numpad8:"8",numpad9:"9",NumpadDot:".",NumpadDotAlt:",",NumpadMultiply:"*",NumpadPlus:"+",NumpadMinus:"-",NumpadSubtract:"-",NumpadSlash:"/",NumpadDotObsoleteBrowsers:"Decimal",NumpadMultiplyObsoleteBrowsers:"Multiply",NumpadPlusObsoleteBrowsers:"Add",NumpadMinusObsoleteBrowsers:"Subtract",NumpadSlashObsoleteBrowsers:"Divide",_allFnKeys:["F1","F2","F3","F4","F5","F6","F7","F8","F9","F10","F11","F12"],_someNonPrintableKeys:["Tab","Enter","Shift","ShiftLeft","ShiftRight","Control","ControlLeft","ControlRight","Alt","AltLeft","AltRight","Pause","CapsLock","Escape"],_directionKeys:["PageUp","PageDown","End","Home","ArrowDown","ArrowLeft","ArrowRight","ArrowUp"]},Object.freeze(fr.keyName._allFnKeys),Object.freeze(fr.keyName._someNonPrintableKeys),Object.freeze(fr.keyName._directionKeys),Object.freeze(fr.keyName),Object.defineProperty(fr,"keyName",{configurable:!1,writable:!1}),Object.freeze(fr);var Er=function(){function o(){!function(e){if(!(e instanceof o))throw new TypeError("Cannot call a class as a function")}(this)}var e,t,n;return e=o,n=[{key:"isNull",value:function(e){return null===e}},{key:"isUndefined",value:function(e){return void 0===e}},{key:"isUndefinedOrNullOrEmpty",value:function(e){return null==e||""===e}},{key:"isString",value:function(e){return"string"==typeof e||e instanceof String}},{key:"isEmptyString",value:function(e){return""===e}},{key:"isBoolean",value:function(e){return"boolean"==typeof e}},{key:"isTrueOrFalseString",value:function(e){e=String(e).toLowerCase();return"true"===e||"false"===e}},{key:"isObject",value:function(e){return"object"===Sr(e)&&null!==e&&!Array.isArray(e)}},{key:"isEmptyObj",value:function(e){for(var t in e)if(Object.prototype.hasOwnProperty.call(e,t))return!1;return!0}},{key:"isNumberStrict",value:function(e){return"number"==typeof e}},{key:"isNumber",value:function(e){return!this.isArray(e)&&!isNaN(parseFloat(e))&&isFinite(e)}},{key:"isDigit",value:function(e){return/\d/.test(e)}},{key:"isNumberOrArabic",value:function(e){e=this.arabicToLatinNumbers(e,!1,!0,!0);return this.isNumber(e)}},{key:"isInt",value:function(e){return"number"==typeof e&&parseFloat(e)===parseInt(e,10)&&!isNaN(e)}},{key:"isFunction",value:function(e){return"function"==typeof e}},{key:"isIE11",value:function(){return"undefined"!=typeof window&&!!window.MSInputMethodContext&&!!document.documentMode}},{key:"contains",value:function(e,t){return!(!this.isString(e)||!this.isString(t)||""===e||""===t)&&-1!==e.indexOf(t)}},{key:"isInArray",value:function(e,t){return!(!this.isArray(t)||t===[]||this.isUndefined(e))&&-1!==t.indexOf(e)}},{key:"isArray",value:function(e){if("[object Array]"===Object.prototype.toString.call([]))return Array.isArray(e)||"object"===Sr(e)&&"[object Array]"===Object.prototype.toString.call(e);throw new Error("toString message changed for Object Array")}},{key:"isElement",value:function(e){return"undefined"!=typeof Element&&e instanceof Element}},{key:"isInputElement",value:function(e){return this.isElement(e)&&"input"===e.tagName.toLowerCase()}},{key:"decimalPlaces",value:function(e){e=yr(e.split("."),2)[1];return this.isUndefined(e)?0:e.length}},{key:"indexFirstNonZeroDecimalPlace",value:function(e){e=yr(String(Math.abs(e)).split("."),2)[1];if(this.isUndefined(e))return 0;e=e.lastIndexOf("0");return-1===e?e=0:e+=2,e}},{key:"keyCodeNumber",value:function(e){return void 0===e.which?e.keyCode:e.which}},{key:"character",value:function(e){var t;if("Unidentified"===e.key||void 0===e.key||this.isSeleniumBot()){var n=this.keyCodeNumber(e);if(n===fr.keyCode.AndroidDefault)return fr.keyName.AndroidDefault;var i=fr.fromCharCodeKeyCode[n],r=o.isUndefinedOrNullOrEmpty(i)?String.fromCharCode(n):i}else switch(e.key){case"Add":r=fr.keyName.NumpadPlus;break;case"Apps":r=fr.keyName.ContextMenu;break;case"Crsel":r=fr.keyName.CrSel;break;case"Decimal":r=e.char||fr.keyName.NumpadDot;break;case"Del":r="firefox"===(t=this.browser()).name&&t.version<=36||"ie"===t.name&&t.version<=9?fr.keyName.Dot:fr.keyName.Delete;break;case"Divide":r=fr.keyName.NumpadSlash;break;case"Down":r=fr.keyName.DownArrow;break;case"Esc":r=fr.keyName.Esc;break;case"Exsel":r=fr.keyName.ExSel;break;case"Left":r=fr.keyName.LeftArrow;break;case"Meta":case"Super":r=fr.keyName.OSLeft;break;case"Multiply":r=fr.keyName.NumpadMultiply;break;case"Right":r=fr.keyName.RightArrow;break;case"Spacebar":r=fr.keyName.Space;break;case"Subtract":r=fr.keyName.NumpadMinus;break;case"Up":r=fr.keyName.UpArrow;break;default:r=e.key}return r}},{key:"browser",value:function(){var e,t=navigator.userAgent,n=t.match(/(opera|chrome|safari|firefox|msie|trident(?=\/))\/?\s*(\d+)/i)||[];return/trident/i.test(n[1])?{name:"ie",version:(e=/\brv[ :]+(\d+)/g.exec(t)||[])[1]||""}:"Chrome"===n[1]&&null!==(e=t.match(/\b(OPR|Edge)\/(\d+)/))?{name:e[1].replace("OPR","opera"),version:e[2]}:(n=n[2]?[n[1],n[2]]:[navigator.appName,navigator.appVersion,"-?"],null!==(e=t.match(/version\/(\d+)/i))&&n.splice(1,1,e[1]),{name:n[0].toLowerCase(),version:n[1]})}},{key:"isSeleniumBot",value:function(){return!0===window.navigator.webdriver}},{key:"isNegative",value:function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:"-",n=!(2<arguments.length&&void 0!==arguments[2])||arguments[2];return e===t||""!==e&&(o.isNumber(e)?e<0:n?this.contains(e,t):this.isNegativeStrict(e,t))}},{key:"isNegativeStrict",value:function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:"-";return e.charAt(0)===t}},{key:"isNegativeWithBrackets",value:function(e,t,n){return e.charAt(0)===t&&this.contains(e,n)}},{key:"isZeroOrHasNoValue",value:function(e){return!/[1-9]/g.test(e)}},{key:"setRawNegativeSign",value:function(e){return this.isNegativeStrict(e,"-")?e:"-".concat(e)}},{key:"replaceCharAt",value:function(e,t,n){return"".concat(e.substr(0,t)).concat(n).concat(e.substr(t+n.length))}},{key:"clampToRangeLimits",value:function(e,t){return Math.max(t.minimumValue,Math.min(t.maximumValue,e))}},{key:"countNumberCharactersOnTheCaretLeftSide",value:function(e,t,n){for(var i=new RegExp("[0-9".concat(n,"-]")),r=0,o=0;o<t;o++)i.test(e[o])&&r++;return r}},{key:"findCaretPositionInFormattedNumber",value:function(e,t,n,i){for(var r=n.length,o=e.length,s=0,a=0;a<r&&s<o&&s<t;a++)(e[s]===n[a]||"."===e[s]&&n[a]===i)&&s++;return a}},{key:"countCharInText",value:function(e,t){for(var n=0,i=0;i<t.length;i++)t[i]===e&&n++;return n}},{key:"convertCharacterCountToIndexPosition",value:function(e){return Math.max(e,e-1)}},{key:"getElementSelection",value:function(e){var t,n,i={};try{t=this.isUndefined(e.selectionStart)}catch(e){t=!1}try{t?(n=window.getSelection().getRangeAt(0),i.start=n.startOffset,i.end=n.endOffset):(i.start=e.selectionStart,i.end=e.selectionEnd),i.length=i.end-i.start}catch(e){i.start=0,i.end=0,i.length=0}return i}},{key:"setElementSelection",value:function(e,t){var n,i=2<arguments.length&&void 0!==arguments[2]?arguments[2]:null;this.isUndefinedOrNullOrEmpty(i)&&(i=t),this.isInputElement(e)?e.setSelectionRange(t,i):o.isNull(e.firstChild)||((n=document.createRange()).setStart(e.firstChild,t),n.setEnd(e.firstChild,i),(i=window.getSelection()).removeAllRanges(),i.addRange(n))}},{key:"throwError",value:function(e){throw new Error(e)}},{key:"warning",value:function(e){1<arguments.length&&void 0!==arguments[1]&&!arguments[1]||console.warn("Warning: ".concat(e))}},{key:"isWheelEvent",value:function(e){return e instanceof WheelEvent}},{key:"isWheelUpEvent",value:function(e){return this.isWheelEvent(e)&&!this.isUndefinedOrNullOrEmpty(e.deltaY)||this.throwError("The event passed as a parameter is not a valid wheel event, '".concat(e.type,"' given.")),e.deltaY<0}},{key:"isWheelDownEvent",value:function(e){return this.isWheelEvent(e)&&!this.isUndefinedOrNullOrEmpty(e.deltaY)||this.throwError("The event passed as a parameter is not a valid wheel event, '".concat(e.type,"' given.")),0<e.deltaY}},{key:"forceDecimalPlaces",value:function(e,t){var n=yr(String(e).split("."),2),i=n[0],n=n[1];return n?"".concat(i,".").concat(n.substr(0,t)):e}},{key:"roundToNearest",value:function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:1e3;return 0===e?0:(0===t&&this.throwError("The `stepPlace` used to round is equal to `0`. This value must not be equal to zero."),Math.round(e/t)*t)}},{key:"modifyAndRoundToNearestAuto",value:function(e,t,n){e=Number(this.forceDecimalPlaces(e,n));var i=Math.abs(e);if(0<=i&&i<1){var r=Math.pow(10,-n);if(0===e)return t?r:-r;i=n,n=this.indexFirstNonZeroDecimalPlace(e),r=i-1<=n?r:Math.pow(10,-(n+1)),n=t?e+r:e-r;return this.roundToNearest(n,r)}e=parseInt(e,10);var o,s=Math.abs(e).toString().length;switch(s){case 1:o=0;break;case 2:case 3:o=1;break;case 4:case 5:o=2;break;default:o=s-3}r=Math.pow(10,o),e=t?e+r:e-r;return e<=10&&-10<=e?e:this.roundToNearest(e,r)}},{key:"addAndRoundToNearestAuto",value:function(e,t){return this.modifyAndRoundToNearestAuto(e,!0,t)}},{key:"subtractAndRoundToNearestAuto",value:function(e,t){return this.modifyAndRoundToNearestAuto(e,!1,t)}},{key:"arabicToLatinNumbers",value:function(e){var t=!(1<arguments.length&&void 0!==arguments[1])||arguments[1],n=2<arguments.length&&void 0!==arguments[2]&&arguments[2],i=3<arguments.length&&void 0!==arguments[3]&&arguments[3];if(this.isNull(e))return e;var r=e.toString();if(""===r)return e;if(null===r.match(/[٠١٢٣٤٥٦٧٨٩۴۵۶]/g))return r=t?Number(r):r;n&&(r=r.replace(/٫/,".")),r=(r=i?r.replace(/٬/g,""):r).replace(/[٠١٢٣٤٥٦٧٨٩]/g,function(e){return e.charCodeAt(0)-1632}).replace(/[۰۱۲۳۴۵۶۷۸۹]/g,function(e){return e.charCodeAt(0)-1776});i=Number(r);return isNaN(i)||t?i:r}},{key:"triggerEvent",value:function(e){var t,n=1<arguments.length&&void 0!==arguments[1]?arguments[1]:document,i=2<arguments.length&&void 0!==arguments[2]?arguments[2]:null,r=!(3<arguments.length&&void 0!==arguments[3])||arguments[3],o=!(4<arguments.length&&void 0!==arguments[4])||arguments[4];window.CustomEvent?t=new CustomEvent(e,{detail:i,bubbles:r,cancelable:o}):(t=document.createEvent("CustomEvent")).initCustomEvent(e,r,o,{detail:i}),n.dispatchEvent(t)}},{key:"parseStr",value:function(e){var t,n,i,r,o={};if(e=(e=0===e&&1/e<0?"-0":e).toString(),this.isNegativeStrict(e,"-")?(e=e.slice(1),o.s=-1):o.s=1,-1<(t=e.indexOf("."))&&(e=e.replace(".","")),t<0&&(t=e.length),(n=-1===e.search(/[1-9]/i)?e.length:e.search(/[1-9]/i))===(i=e.length))o.e=0,o.c=[0];else{for(r=i-1;"0"===e.charAt(r);--r)--i;for(--i,o.e=t-n-1,o.c=[],t=0;n<=i;n+=1)o.c[t]=+e.charAt(n),t+=1}return o}},{key:"testMinMax",value:function(e,t){var n=t.c,i=e.c,r=t.s,o=e.s,s=t.e,t=e.e;if(!n[0]||!i[0]){e=n[0]?r:i[0]?-o:0;return e}if(r!==o)return r;var a=r<0;if(s!==t)return t<s^a?1:-1;for(r=-1,o=(s=n.length)<(t=i.length)?s:t,r+=1;r<o;r+=1)if(n[r]!==i[r])return n[r]>i[r]^a?1:-1;return s===t?0:t<s^a?1:-1}},{key:"randomString",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:5;return Math.random().toString(36).substr(2,e)}},{key:"domElement",value:function(e){return o.isString(e)?document.querySelector(e):e}},{key:"getElementValue",value:function(e){return"input"===e.tagName.toLowerCase()?e.value:this.text(e)}},{key:"setElementValue",value:function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:null;"input"===e.tagName.toLowerCase()?e.value=t:e.textContent=t}},{key:"setInvalidState",value:function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:"Invalid";""!==t&&!this.isNull(t)||this.throwError("Cannot set the invalid state with an empty message."),e.setCustomValidity(t)}},{key:"setValidState",value:function(e){e.setCustomValidity("")}},{key:"cloneObject",value:function(e){return Object.assign({},e)}},{key:"camelize",value:function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:"-",n=!(2<arguments.length&&void 0!==arguments[2])||arguments[2],i=!(3<arguments.length&&void 0!==arguments[3])||arguments[3];if(this.isNull(e))return null;t=(t=(e=n?e.replace(/^data-/,""):e).split(t).map(function(e){return"".concat(e.charAt(0).toUpperCase()).concat(e.slice(1))})).join("");return t=i?"".concat(t.charAt(0).toLowerCase()).concat(t.slice(1)):t}},{key:"text",value:function(e){var t=e.nodeType,e=t===Node.ELEMENT_NODE||t===Node.DOCUMENT_NODE||t===Node.DOCUMENT_FRAGMENT_NODE?e.textContent:t===Node.TEXT_NODE?e.nodeValue:"";return e}},{key:"setText",value:function(e,t){var n=e.nodeType;n!==Node.ELEMENT_NODE&&n!==Node.DOCUMENT_NODE&&n!==Node.DOCUMENT_FRAGMENT_NODE||(e.textContent=t)}},{key:"filterOut",value:function(e,t){var n=this;return e.filter(function(e){return!n.isInArray(e,t)})}},{key:"trimPaddedZerosFromDecimalPlaces",value:function(e){if(""===(e=String(e)))return"";var t=yr(e.split("."),2),e=t[0],t=t[1];if(this.isUndefinedOrNullOrEmpty(t))return e;t=t.replace(/0+$/g,""),t=""===t?e:"".concat(e,".").concat(t);return t}},{key:"getHoveredElement",value:function(){var e=vr(document.querySelectorAll(":hover"));return e[e.length-1]}},{key:"arrayTrim",value:function(e,t){var n=e.length;return 0===n||n<t?e:t<0?[]:(e.length=parseInt(t,10),e)}},{key:"arrayUnique",value:function(){var e;return vr(new Set((e=[]).concat.apply(e,arguments)))}},{key:"mergeMaps",value:function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return new Map(t.reduce(function(e,t){return e.concat(vr(t))},[]))}},{key:"objectKeyLookup",value:function(e,t){var n=Object.entries(e).find(function(e){return e[1]===t}),e=null;return e=void 0!==n?n[0]:e}},{key:"insertAt",value:function(e,t,n){if(n>(e=String(e)).length)throw new Error("The given index is out of the string range.");if(1!==t.length)throw new Error("The given string `char` should be only one character long.");return""===e&&0===n?t:"".concat(e.slice(0,n)).concat(t).concat(e.slice(n))}},{key:"scientificToDecimal",value:function(e){var t=Number(e);if(isNaN(t))return NaN;if(e=String(e),!(this.contains(e,"e")||this.contains(e,"E")))return e;var n=yr(e.split(/e/i),2),i=n[0],r=n[1],o=i<0;o&&(i=i.replace("-",""));t=+r<0;t&&(r=r.replace("-",""));var e=yr(i.split(/\./),2),n=e[0],e=e[1],s=t?(s=n.length>r?this.insertAt(n,".",n.length-r):"0.".concat("0".repeat(r-n.length)).concat(n),"".concat(s).concat(e||"")):e?(i="".concat(n).concat(e),r<e.length?this.insertAt(i,".",+r+n.length):"".concat(i).concat("0".repeat(r-e.length))):(i=i.replace(".",""),"".concat(i).concat("0".repeat(Number(r))));return s=o?"-".concat(s):s}}],(t=null)&&wr(e.prototype,t),n&&wr(e,n),o}();function kr(e,t){for(var n=0;n<t.length;n++){var i=t[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,i.key,i)}}var xr=function(){function t(e){if(!function(e){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this),null===e)throw new Error("Invalid AST")}var e,n,i;return e=t,(n=[{key:"evaluate",value:function(e){if(null==e)throw new Error("Invalid AST sub-tree");if("number"===e.type)return e.value;if("unaryMinus"===e.type)return-this.evaluate(e.left);var t=this.evaluate(e.left),n=this.evaluate(e.right);switch(e.type){case"op_+":return Number(t)+Number(n);case"op_-":return t-n;case"op_*":return t*n;case"op_/":return t/n;default:throw new Error("Invalid operator '".concat(e.type,"'"))}}}])&&kr(e.prototype,n),i&&kr(e,i),t}();function Pr(e,t){for(var n=0;n<t.length;n++){var i=t[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,i.key,i)}}var Or=function(){function r(){!function(e){if(!(e instanceof r))throw new TypeError("Cannot call a class as a function")}(this)}var e,t,n;return e=r,n=[{key:"createNode",value:function(e,t,n){var i=new r;return i.type=e,i.left=t,i.right=n,i}},{key:"createUnaryNode",value:function(e){var t=new r;return t.type="unaryMinus",t.left=e,t.right=null,t}},{key:"createLeaf",value:function(e){var t=new r;return t.type="number",t.value=e,t}}],(t=null)&&Pr(e.prototype,t),n&&Pr(e,n),r}();var Cr=function t(e,n,i){!function(e){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this),this.type=e,this.value=n,this.symbol=i};function Nr(e,t){for(var n=0;n<t.length;n++){var i=t[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,i.key,i)}}var Tr=function(){function t(e){!function(e){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this),this.text=e,this.textLength=e.length,this.index=0,this.token=new Cr("Error",0,0)}var e,n,i;return e=t,(n=[{key:"_skipSpaces",value:function(){for(;" "===this.text[this.index]&&this.index<=this.textLength;)this.index++}},{key:"getIndex",value:function(){return this.index}},{key:"getNextToken",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:".";if(this._skipSpaces(),this.textLength===this.index)return this.token.type="EOT",this.token;if(Er.isDigit(this.text[this.index]))return this.token.type="num",this.token.value=this._getNumber(e),this.token;switch(this.token.type="Error",this.text[this.index]){case"+":this.token.type="+";break;case"-":this.token.type="-";break;case"*":this.token.type="*";break;case"/":this.token.type="/";break;case"(":this.token.type="(";break;case")":this.token.type=")"}if("Error"===this.token.type)throw new Error("Unexpected token '".concat(this.token.symbol,"' at position '").concat(this.token.index,"' in the token function"));return this.token.symbol=this.text[this.index],this.index++,this.token}},{key:"_getNumber",value:function(e){this._skipSpaces();for(var t=this.index;this.index<=this.textLength&&Er.isDigit(this.text[this.index]);)this.index++;for(this.text[this.index]===e&&this.index++;this.index<=this.textLength&&Er.isDigit(this.text[this.index]);)this.index++;if(this.index===t)throw new Error("No number has been found while it was expected");return this.text.substring(t,this.index).replace(e,".")}}])&&Nr(e.prototype,n),i&&Nr(e,i),t}();function Ir(e,t){for(var n=0;n<t.length;n++){var i=t[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,i.key,i)}}var Fr=function(){function n(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:".";return function(e){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}(this),this.text=e,this.decimalCharacter=t,this.lexer=new Tr(e),this.token=this.lexer.getNextToken(this.decimalCharacter),this._exp()}var e,t,i;return e=n,(t=[{key:"_exp",value:function(){var e=this._term(),t=this._moreExp();return Or.createNode("op_+",e,t)}},{key:"_moreExp",value:function(){var e,t;switch(this.token.type){case"+":return this.token=this.lexer.getNextToken(this.decimalCharacter),e=this._term(),t=this._moreExp(),Or.createNode("op_+",t,e);case"-":return this.token=this.lexer.getNextToken(this.decimalCharacter),e=this._term(),t=this._moreExp(),Or.createNode("op_-",t,e)}return Or.createLeaf(0)}},{key:"_term",value:function(){var e=this._factor(),t=this._moreTerms();return Or.createNode("op_*",e,t)}},{key:"_moreTerms",value:function(){var e,t;switch(this.token.type){case"*":return this.token=this.lexer.getNextToken(this.decimalCharacter),e=this._factor(),t=this._moreTerms(),Or.createNode("op_*",t,e);case"/":return this.token=this.lexer.getNextToken(this.decimalCharacter),e=this._factor(),t=this._moreTerms(),Or.createNode("op_/",t,e)}return Or.createLeaf(1)}},{key:"_factor",value:function(){var e,t;switch(this.token.type){case"num":return t=this.token.value,this.token=this.lexer.getNextToken(this.decimalCharacter),Or.createLeaf(t);case"-":return this.token=this.lexer.getNextToken(this.decimalCharacter),e=this._factor(),Or.createUnaryNode(e);case"(":return this.token=this.lexer.getNextToken(this.decimalCharacter),e=this._exp(),this._match(")"),e;default:throw new Error("Unexpected token '".concat(this.token.symbol,"' with type '").concat(this.token.type,"' at position '").concat(this.token.index,"' in the factor function"))}}},{key:"_match",value:function(e){var t=this.lexer.getIndex()-1;if(this.text[t]!==e)throw new Error("Unexpected token '".concat(this.token.symbol,"' at position '").concat(t,"' in the match function"));this.token=this.lexer.getNextToken(this.decimalCharacter)}}])&&Ir(e.prototype,t),i&&Ir(e,i),n}();function Lr(e){return function(e){if(Array.isArray(e))return Mr(e)}(e)||function(e){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e))return Array.from(e)}(e)||Ar(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Vr(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){if("undefined"==typeof Symbol||!(Symbol.iterator in Object(e)))return;var n=[],i=!0,r=!1,o=void 0;try{for(var s,a=e[Symbol.iterator]();!(i=(s=a.next()).done)&&(n.push(s.value),!t||n.length!==t);i=!0);}catch(e){r=!0,o=e}finally{try{i||null==a.return||a.return()}finally{if(r)throw o}}return n}(e,t)||Ar(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Ar(e,t){if(e){if("string"==typeof e)return Mr(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Map"===(n="Object"===n&&e.constructor?e.constructor.name:n)||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?Mr(e,t):void 0}}function Mr(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,i=new Array(t);n<t;n++)i[n]=e[n];return i}function zr(e){return(zr="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function Rr(e,t){for(var n=0;n<t.length;n++){var i=t[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,i.key,i)}}var Dr,Br=function(){function I(){var r=this,e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:null,t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:null,n=2<arguments.length&&void 0!==arguments[2]?arguments[2]:null;!function(e){if(!(e instanceof I))throw new TypeError("Cannot call a class as a function")}(this);var i,e=I._setArgumentsValues(e,t,n),t=e.domElement,n=e.initialValue,e=e.userOptions;if(this.domElement=t,this.defaultRawValue="",this._setSettings(e,!1),this._checkElement(),this.savedCancellableValue=null,this.historyTable=[],this.historyTableIndex=-1,this.onGoingRedo=!1,this.parentForm=this._getParentForm(),!this.runOnce&&this.settings.formatOnPageLoad)this._formatDefaultValueOnPageLoad(n);else{if(Er.isNull(n))switch(this.settings.emptyInputBehavior){case I.options.emptyInputBehavior.min:i=this.settings.minimumValue;break;case I.options.emptyInputBehavior.max:i=this.settings.maximumValue;break;case I.options.emptyInputBehavior.zero:i="0";break;case I.options.emptyInputBehavior.focus:case I.options.emptyInputBehavior.press:case I.options.emptyInputBehavior.always:case I.options.emptyInputBehavior.null:i="";break;default:i=this.settings.emptyInputBehavior}else i=n;this._setElementAndRawValue(i)}this.runOnce=!0,this.hasEventListeners=!1,(this.isInputElement||this.isContentEditable)&&(this.settings.noEventListeners||this._createEventListeners(),this._setWritePermissions(!0)),this._saveInitialValues(n),this.sessionStorageAvailable=this.constructor._storageTest(),this.storageNamePrefix="AUTO_",this._setPersistentStorageName(),this.validState=!0,this.isFocused=!1,this.isWheelEvent=!1,this.isDropEvent=!1,this.isEditing=!1,this.rawValueOnFocus=void 0,this.internalModification=!1,this.attributeToWatch=this._getAttributeToWatch(),this.getterSetter=Object.getOwnPropertyDescriptor(this.domElement.__proto__,this.attributeToWatch),this._addWatcher(),this.settings.createLocalList&&this._createLocalList(),this.constructor._addToGlobalList(this),this.global={set:function(t){var n=1<arguments.length&&void 0!==arguments[1]?arguments[1]:null;r.autoNumericLocalList.forEach(function(e){e.set(t,n)})},setUnformatted:function(t){var n=1<arguments.length&&void 0!==arguments[1]?arguments[1]:null;r.autoNumericLocalList.forEach(function(e){e.setUnformatted(t,n)})},get:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:null,t=[];return r.autoNumericLocalList.forEach(function(e){t.push(e.get())}),r._executeCallback(t,e),t},getNumericString:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:null,t=[];return r.autoNumericLocalList.forEach(function(e){t.push(e.getNumericString())}),r._executeCallback(t,e),t},getFormatted:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:null,t=[];return r.autoNumericLocalList.forEach(function(e){t.push(e.getFormatted())}),r._executeCallback(t,e),t},getNumber:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:null,t=[];return r.autoNumericLocalList.forEach(function(e){t.push(e.getNumber())}),r._executeCallback(t,e),t},getLocalized:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:null,t=[];return r.autoNumericLocalList.forEach(function(e){t.push(e.getLocalized())}),r._executeCallback(t,e),t},reformat:function(){r.autoNumericLocalList.forEach(function(e){e.reformat()})},unformat:function(){r.autoNumericLocalList.forEach(function(e){e.unformat()})},unformatLocalized:function(){var t=0<arguments.length&&void 0!==arguments[0]?arguments[0]:null;r.autoNumericLocalList.forEach(function(e){e.unformatLocalized(t)})},update:function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];r.autoNumericLocalList.forEach(function(e){e.update.apply(e,t)})},isPristine:function(){var t=!(0<arguments.length&&void 0!==arguments[0])||arguments[0],n=!0;return r.autoNumericLocalList.forEach(function(e){n&&!e.isPristine(t)&&(n=!1)}),n},clear:function(){var t=0<arguments.length&&void 0!==arguments[0]&&arguments[0];r.autoNumericLocalList.forEach(function(e){e.clear(t)})},remove:function(){r.autoNumericLocalList.forEach(function(e){e.remove()})},wipe:function(){r.autoNumericLocalList.forEach(function(e){e.wipe()})},nuke:function(){r.autoNumericLocalList.forEach(function(e){e.nuke()})},has:function(e){e=e instanceof I?r.autoNumericLocalList.has(e.node()):r.autoNumericLocalList.has(e);return e},addObject:function(e){var t,n=e instanceof I?(t=e.node(),e):(t=e,I.getAutoNumericElement(t));r._hasLocalList()||r._createLocalList();var i,e=n._getLocalList();0===e.size&&(n._createLocalList(),e=n._getLocalList()),(i=e instanceof Map?Er.mergeMaps(r._getLocalList(),e):(r._addToLocalList(t,n),r._getLocalList())).forEach(function(e){e._setLocalList(i)})},removeObject:function(e){var t,n=1<arguments.length&&void 0!==arguments[1]&&arguments[1],i=e instanceof I?(t=e.node(),e):(t=e,I.getAutoNumericElement(t)),e=r.autoNumericLocalList;r.autoNumericLocalList.delete(t),e.forEach(function(e){e._setLocalList(r.autoNumericLocalList)}),n||t!==r.node()?i._createLocalList():i._setLocalList(new Map)},empty:function(){var t=0<arguments.length&&void 0!==arguments[0]&&arguments[0];r.autoNumericLocalList.forEach(function(e){t?e._createLocalList():e._setLocalList(new Map)})},elements:function(){var t=[];return r.autoNumericLocalList.forEach(function(e){t.push(e.node())}),t},getList:function(){return r.autoNumericLocalList},size:function(){return r.autoNumericLocalList.size}},this.options={reset:function(){return r.settings={rawValue:r.defaultRawValue},r.update(I.defaultSettings),r},allowDecimalPadding:function(e){return r.update({allowDecimalPadding:e}),r},alwaysAllowDecimalCharacter:function(e){return r.update({alwaysAllowDecimalCharacter:e}),r},caretPositionOnFocus:function(e){return r.settings.caretPositionOnFocus=e,r},createLocalList:function(e){return r.settings.createLocalList=e,r.settings.createLocalList?r._hasLocalList()||r._createLocalList():r._deleteLocalList(),r},currencySymbol:function(e){return r.update({currencySymbol:e}),r},currencySymbolPlacement:function(e){return r.update({currencySymbolPlacement:e}),r},decimalCharacter:function(e){return r.update({decimalCharacter:e}),r},decimalCharacterAlternative:function(e){return r.settings.decimalCharacterAlternative=e,r},decimalPlaces:function(e){return Er.warning("Using `options.decimalPlaces()` instead of calling the specific `options.decimalPlacesRawValue()`, `options.decimalPlacesShownOnFocus()` and `options.decimalPlacesShownOnBlur()` methods will reset those options.\nPlease call the specific methods if you do not want to reset those.",r.settings.showWarnings),r.update({decimalPlaces:e}),r},decimalPlacesRawValue:function(e){return r.update({decimalPlacesRawValue:e}),r},decimalPlacesShownOnBlur:function(e){return r.update({decimalPlacesShownOnBlur:e}),r},decimalPlacesShownOnFocus:function(e){return r.update({decimalPlacesShownOnFocus:e}),r},defaultValueOverride:function(e){return r.update({defaultValueOverride:e}),r},digitalGroupSpacing:function(e){return r.update({digitalGroupSpacing:e}),r},digitGroupSeparator:function(e){return r.update({digitGroupSeparator:e}),r},divisorWhenUnfocused:function(e){return r.update({divisorWhenUnfocused:e}),r},emptyInputBehavior:function(e){return null===r.rawValue&&e!==I.options.emptyInputBehavior.null&&(Er.warning("You are trying to modify the `emptyInputBehavior` option to something different than `'null'` (".concat(e,"), but the element raw value is currently set to `null`. This would result in an invalid `rawValue`. In order to fix that, the element value has been changed to the empty string `''`."),r.settings.showWarnings),r.rawValue=""),r.update({emptyInputBehavior:e}),r},eventBubbles:function(e){return r.settings.eventBubbles=e,r},eventIsCancelable:function(e){return r.settings.eventIsCancelable=e,r},failOnUnknownOption:function(e){return r.settings.failOnUnknownOption=e,r},formatOnPageLoad:function(e){return r.settings.formatOnPageLoad=e,r},formulaMode:function(e){return r.settings.formulaMode=e,r},historySize:function(e){return r.settings.historySize=e,r},invalidClass:function(e){return r.settings.invalidClass=e,r},isCancellable:function(e){return r.settings.isCancellable=e,r},leadingZero:function(e){return r.update({leadingZero:e}),r},maximumValue:function(e){return r.update({maximumValue:e}),r},minimumValue:function(e){return r.update({minimumValue:e}),r},modifyValueOnWheel:function(e){return r.settings.modifyValueOnWheel=e,r},negativeBracketsTypeOnBlur:function(e){return r.update({negativeBracketsTypeOnBlur:e}),r},negativePositiveSignPlacement:function(e){return r.update({negativePositiveSignPlacement:e}),r},negativeSignCharacter:function(e){return r.update({negativeSignCharacter:e}),r},noEventListeners:function(e){return e===I.options.noEventListeners.noEvents&&r.settings.noEventListeners===I.options.noEventListeners.addEvents&&r._removeEventListeners(),r.update({noEventListeners:e}),r},onInvalidPaste:function(e){return r.settings.onInvalidPaste=e,r},outputFormat:function(e){return r.settings.outputFormat=e,r},overrideMinMaxLimits:function(e){return r.update({overrideMinMaxLimits:e}),r},positiveSignCharacter:function(e){return r.update({positiveSignCharacter:e}),r},rawValueDivisor:function(e){return r.update({rawValueDivisor:e}),r},readOnly:function(e){return r.settings.readOnly=e,r._setWritePermissions(),r},roundingMethod:function(e){return r.update({roundingMethod:e}),r},saveValueToSessionStorage:function(e){return r.update({saveValueToSessionStorage:e}),r},symbolWhenUnfocused:function(e){return r.update({symbolWhenUnfocused:e}),r},selectNumberOnly:function(e){return r.settings.selectNumberOnly=e,r},selectOnFocus:function(e){return r.settings.selectOnFocus=e,r},serializeSpaces:function(e){return r.settings.serializeSpaces=e,r},showOnlyNumbersOnFocus:function(e){return r.update({showOnlyNumbersOnFocus:e}),r},showPositiveSign:function(e){return r.update({showPositiveSign:e}),r},showWarnings:function(e){return r.settings.showWarnings=e,r},styleRules:function(e){return r.update({styleRules:e}),r},suffixText:function(e){return r.update({suffixText:e}),r},unformatOnHover:function(e){return r.settings.unformatOnHover=e,r},unformatOnSubmit:function(e){return r.settings.unformatOnSubmit=e,r},valuesToStrings:function(e){return r.update({valuesToStrings:e}),r},watchExternalChanges:function(e){return r.update({watchExternalChanges:e}),r},wheelOn:function(e){return r.settings.wheelOn=e,r},wheelStep:function(e){return r.settings.wheelStep=e,r}},this._triggerEvent(I.events.initialized,this.domElement,{newValue:Er.getElementValue(this.domElement),newRawValue:this.rawValue,error:null,aNElement:this})}var e,t,n;return e=I,n=[{key:"version",value:function(){return"4.6.0"}},{key:"_setArgumentsValues",value:function(e,t,n){Er.isNull(e)&&Er.throwError("At least one valid parameter is needed in order to initialize an AutoNumeric object");var i,r,o,s=Er.isElement(e),a=Er.isString(e),l=Er.isObject(t),c=Array.isArray(t)&&0<t.length,u=Er.isNumberOrArabic(t)||""===t,h=this._isPreDefinedOptionValid(t),d=Er.isNull(t),m=Er.isEmptyString(t),p=Er.isObject(n),g=Array.isArray(n)&&0<n.length,f=Er.isNull(n),v=this._isPreDefinedOptionValid(n);return s&&d&&f?(i=e,r=o=null):s&&u&&f?(i=e,o=t,r=null):s&&l&&f?(i=e,o=null,r=t):s&&h&&f?(i=e,o=null,r=this._getOptionObject(t)):s&&c&&f?(i=e,o=null,r=this.mergeOptions(t)):s&&(d||m)&&p?(i=e,o=null,r=n):s&&(d||m)&&g?(i=e,o=null,r=this.mergeOptions(n)):a&&d&&f?(i=document.querySelector(e),r=o=null):a&&l&&f?(i=document.querySelector(e),o=null,r=t):a&&h&&f?(i=document.querySelector(e),o=null,r=this._getOptionObject(t)):a&&c&&f?(i=document.querySelector(e),o=null,r=this.mergeOptions(t)):a&&(d||m)&&p?(i=document.querySelector(e),o=null,r=n):a&&(d||m)&&g?(i=document.querySelector(e),o=null,r=this.mergeOptions(n)):a&&u&&f?(i=document.querySelector(e),o=t,r=null):a&&u&&p?(i=document.querySelector(e),o=t,r=n):a&&u&&v?(i=document.querySelector(e),o=t,r=this._getOptionObject(n)):a&&u&&g?(i=document.querySelector(e),o=t,r=this.mergeOptions(n)):s&&u&&p?(i=e,o=t,r=n):s&&u&&v?(i=e,o=t,r=this._getOptionObject(n)):s&&u&&g?(i=e,o=t,r=this.mergeOptions(n)):Er.throwError("The parameters given to the AutoNumeric object are not valid, '".concat(e,"', '").concat(t,"' and '").concat(n,"' given.")),Er.isNull(i)&&Er.throwError("The selector '".concat(e,"' did not select any valid DOM element. Please check on which element you called AutoNumeric.")),{domElement:i,initialValue:o,userOptions:r}}},{key:"mergeOptions",value:function(e){var t=this,n={};return e.forEach(function(e){Object.assign(n,t._getOptionObject(e))}),n}},{key:"_isPreDefinedOptionValid",value:function(e){return Object.prototype.hasOwnProperty.call(I.predefinedOptions,e)}},{key:"_getOptionObject",value:function(e){var t;return Er.isString(e)?null==(t=I.getPredefinedOptions()[e])&&Er.warning("The given pre-defined option [".concat(e,"] is not recognized by autoNumeric. Please check that pre-defined option name."),!0):t=e,t}},{key:"_doesFormHandlerListExists",value:function(){var e=zr(window.aNFormHandlerMap);return"undefined"!==e&&"object"===e}},{key:"_createFormHandlerList",value:function(){window.aNFormHandlerMap=new Map}},{key:"_checkValuesToStringsArray",value:function(e,t){return Er.isInArray(String(e),t)}},{key:"_checkValuesToStringsSettings",value:function(e,t){return this._checkValuesToStringsArray(e,Object.keys(t.valuesToStrings))}},{key:"_checkStringsToValuesSettings",value:function(e,t){return this._checkValuesToStringsArray(e,Object.values(t.valuesToStrings))}},{key:"_unformatAltHovered",value:function(e){e.hoveredWithAlt=!0,e.unformat()}},{key:"_reformatAltHovered",value:function(e){e.hoveredWithAlt=!1,e.reformat()}},{key:"_getChildANInputElement",value:function(e){var t=this,e=e.getElementsByTagName("input"),n=[];return Array.prototype.slice.call(e,0).forEach(function(e){t.test(e)&&n.push(e)}),n}},{key:"test",value:function(e){return this._isInGlobalList(Er.domElement(e))}},{key:"_createWeakMap",value:function(e){window[e]=new WeakMap}},{key:"_createGlobalList",value:function(){this.autoNumericGlobalListName="autoNumericGlobalList",this._createWeakMap(this.autoNumericGlobalListName)}},{key:"_doesGlobalListExists",value:function(){var e=zr(window[this.autoNumericGlobalListName]);return"undefined"!==e&&"object"===e}},{key:"_addToGlobalList",value:function(e){this._doesGlobalListExists()||this._createGlobalList();var t=e.node();if(this._isInGlobalList(t)){if(this._getFromGlobalList(t)===this)return;Er.warning("A reference to the DOM element you just initialized already exists in the global AutoNumeric element list. Please make sure to not initialize the same DOM element multiple times.",e.getSettings().showWarnings)}window[this.autoNumericGlobalListName].set(t,e)}},{key:"_removeFromGlobalList",value:function(e){this._doesGlobalListExists()&&window[this.autoNumericGlobalListName].delete(e.node())}},{key:"_getFromGlobalList",value:function(e){return this._doesGlobalListExists()?window[this.autoNumericGlobalListName].get(e):null}},{key:"_isInGlobalList",value:function(e){return!!this._doesGlobalListExists()&&window[this.autoNumericGlobalListName].has(e)}},{key:"validate",value:function(e){var t=!(1<arguments.length&&void 0!==arguments[1])||arguments[1],n=2<arguments.length&&void 0!==arguments[2]?arguments[2]:null;!Er.isUndefinedOrNullOrEmpty(e)&&Er.isObject(e)||Er.throwError("The userOptions are invalid ; it should be a valid object, [".concat(e,"] given."));var i,r=Er.isObject(n);r||Er.isNull(n)||Er.throwError("The 'originalOptions' parameter is invalid ; it should either be a valid option object or `null`, [".concat(e,"] given.")),Er.isNull(e)||this._convertOldOptionsToNewOnes(e),i=t?Object.assign({},this.getDefaultConfig(),e):e,Er.isTrueOrFalseString(i.showWarnings)||Er.isBoolean(i.showWarnings)||Er.throwError("The debug option 'showWarnings' is invalid ; it should be either 'true' or 'false', [".concat(i.showWarnings,"] given."));var o=/^[0-9]+$/,s=/[0-9]+/,a=/^-?[0-9]+(\.?[0-9]+)?$/,t=/^[0-9]+(\.?[0-9]+)?$/;Er.isTrueOrFalseString(i.allowDecimalPadding)||Er.isBoolean(i.allowDecimalPadding)||i.allowDecimalPadding===I.options.allowDecimalPadding.floats||Er.throwError("The decimal padding option 'allowDecimalPadding' is invalid ; it should either be `false`, `true` or `'floats'`, [".concat(i.allowDecimalPadding,"] given.")),i.allowDecimalPadding!==I.options.allowDecimalPadding.never&&"false"!==i.allowDecimalPadding||i.decimalPlaces===I.options.decimalPlaces.none&&i.decimalPlacesShownOnBlur===I.options.decimalPlacesShownOnBlur.none&&i.decimalPlacesShownOnFocus===I.options.decimalPlacesShownOnFocus.none||Er.warning("Setting 'allowDecimalPadding' to [".concat(i.allowDecimalPadding,"] will override the current 'decimalPlaces*' settings [").concat(i.decimalPlaces,", ").concat(i.decimalPlacesShownOnBlur," and ").concat(i.decimalPlacesShownOnFocus,"]."),i.showWarnings),Er.isTrueOrFalseString(i.alwaysAllowDecimalCharacter)||Er.isBoolean(i.alwaysAllowDecimalCharacter)||Er.throwError("The option 'alwaysAllowDecimalCharacter' is invalid ; it should either be `true` or `false`, [".concat(i.alwaysAllowDecimalCharacter,"] given.")),Er.isNull(i.caretPositionOnFocus)||Er.isInArray(i.caretPositionOnFocus,[I.options.caretPositionOnFocus.start,I.options.caretPositionOnFocus.end,I.options.caretPositionOnFocus.decimalLeft,I.options.caretPositionOnFocus.decimalRight])||Er.throwError("The display on empty string option 'caretPositionOnFocus' is invalid ; it should either be `null`, 'focus', 'press', 'always' or 'zero', [".concat(i.caretPositionOnFocus,"] given.")),e=r?n:this._correctCaretPositionOnFocusAndSelectOnFocusOptions(e),Er.isNull(e)||e.caretPositionOnFocus===I.options.caretPositionOnFocus.doNoForceCaretPosition||e.selectOnFocus!==I.options.selectOnFocus.select||Er.warning("The 'selectOnFocus' option is set to 'select', which is in conflict with the 'caretPositionOnFocus' which is set to '".concat(e.caretPositionOnFocus,"'. As a result, if this has been called when instantiating an AutoNumeric object, the 'selectOnFocus' option is forced to 'doNotSelect'."),i.showWarnings),Er.isInArray(i.digitGroupSeparator,[I.options.digitGroupSeparator.comma,I.options.digitGroupSeparator.dot,I.options.digitGroupSeparator.normalSpace,I.options.digitGroupSeparator.thinSpace,I.options.digitGroupSeparator.narrowNoBreakSpace,I.options.digitGroupSeparator.noBreakSpace,I.options.digitGroupSeparator.noSeparator,I.options.digitGroupSeparator.apostrophe,I.options.digitGroupSeparator.arabicThousandsSeparator,I.options.digitGroupSeparator.dotAbove,I.options.digitGroupSeparator.privateUseTwo])||Er.throwError("The thousand separator character option 'digitGroupSeparator' is invalid ; it should be ',', '.', '٬', '˙', \"'\", '', ' ', ' ', ' ', ' ' or empty (''), [".concat(i.digitGroupSeparator,"] given.")),Er.isTrueOrFalseString(i.showOnlyNumbersOnFocus)||Er.isBoolean(i.showOnlyNumbersOnFocus)||Er.throwError("The 'showOnlyNumbersOnFocus' option is invalid ; it should be either 'true' or 'false', [".concat(i.showOnlyNumbersOnFocus,"] given.")),Er.isInArray(i.digitalGroupSpacing,[I.options.digitalGroupSpacing.two,I.options.digitalGroupSpacing.twoScaled,I.options.digitalGroupSpacing.three,I.options.digitalGroupSpacing.four])||2<=i.digitalGroupSpacing&&i.digitalGroupSpacing<=4||Er.throwError("The grouping separator option for thousands 'digitalGroupSpacing' is invalid ; it should be '2', '2s', '3', or '4', [".concat(i.digitalGroupSpacing,"] given.")),Er.isInArray(i.decimalCharacter,[I.options.decimalCharacter.comma,I.options.decimalCharacter.dot,I.options.decimalCharacter.middleDot,I.options.decimalCharacter.arabicDecimalSeparator,I.options.decimalCharacter.decimalSeparatorKeySymbol])||Er.throwError("The decimal separator character option 'decimalCharacter' is invalid ; it should be '.', ',', '·', '⎖' or '٫', [".concat(i.decimalCharacter,"] given.")),i.decimalCharacter===i.digitGroupSeparator&&Er.throwError("autoNumeric will not function properly when the decimal character 'decimalCharacter' [".concat(i.decimalCharacter,"] and the thousand separator 'digitGroupSeparator' [").concat(i.digitGroupSeparator,"] are the same character.")),Er.isNull(i.decimalCharacterAlternative)||Er.isString(i.decimalCharacterAlternative)||Er.throwError("The alternate decimal separator character option 'decimalCharacterAlternative' is invalid ; it should be a string, [".concat(i.decimalCharacterAlternative,"] given.")),""===i.currencySymbol||Er.isString(i.currencySymbol)||Er.throwError("The currency symbol option 'currencySymbol' is invalid ; it should be a string, [".concat(i.currencySymbol,"] given.")),Er.isInArray(i.currencySymbolPlacement,[I.options.currencySymbolPlacement.prefix,I.options.currencySymbolPlacement.suffix])||Er.throwError("The placement of the currency sign option 'currencySymbolPlacement' is invalid ; it should either be 'p' (prefix) or 's' (suffix), [".concat(i.currencySymbolPlacement,"] given.")),Er.isInArray(i.negativePositiveSignPlacement,[I.options.negativePositiveSignPlacement.prefix,I.options.negativePositiveSignPlacement.suffix,I.options.negativePositiveSignPlacement.left,I.options.negativePositiveSignPlacement.right,I.options.negativePositiveSignPlacement.none])||Er.throwError("The placement of the negative sign option 'negativePositiveSignPlacement' is invalid ; it should either be 'p' (prefix), 's' (suffix), 'l' (left), 'r' (right) or 'null', [".concat(i.negativePositiveSignPlacement,"] given.")),Er.isTrueOrFalseString(i.showPositiveSign)||Er.isBoolean(i.showPositiveSign)||Er.throwError("The show positive sign option 'showPositiveSign' is invalid ; it should be either 'true' or 'false', [".concat(i.showPositiveSign,"] given.")),Er.isString(i.suffixText)&&(""===i.suffixText||!Er.isNegative(i.suffixText,i.negativeSignCharacter)&&!s.test(i.suffixText))||Er.throwError("The additional suffix option 'suffixText' is invalid ; it should not contains the negative sign '".concat(i.negativeSignCharacter,"' nor any numerical characters, [").concat(i.suffixText,"] given.")),Er.isString(i.negativeSignCharacter)&&1===i.negativeSignCharacter.length&&!Er.isUndefinedOrNullOrEmpty(i.negativeSignCharacter)&&!s.test(i.negativeSignCharacter)||Er.throwError("The negative sign character option 'negativeSignCharacter' is invalid ; it should be a single character, and cannot be any numerical characters, [".concat(i.negativeSignCharacter,"] given.")),Er.isString(i.positiveSignCharacter)&&1===i.positiveSignCharacter.length&&!Er.isUndefinedOrNullOrEmpty(i.positiveSignCharacter)&&!s.test(i.positiveSignCharacter)||Er.throwError("The positive sign character option 'positiveSignCharacter' is invalid ; it should be a single character, and cannot be any numerical characters, [".concat(i.positiveSignCharacter,"] given.\nIf you want to hide the positive sign character, you need to set the `showPositiveSign` option to `true`.")),i.negativeSignCharacter===i.positiveSignCharacter&&Er.throwError("The positive 'positiveSignCharacter' and negative 'negativeSignCharacter' sign characters cannot be identical ; [".concat(i.negativeSignCharacter,"] given."));e=Vr(Er.isNull(i.negativeBracketsTypeOnBlur)?["",""]:i.negativeBracketsTypeOnBlur.split(","),2),s=e[0],e=e[1];(Er.contains(i.digitGroupSeparator,i.negativeSignCharacter)||Er.contains(i.decimalCharacter,i.negativeSignCharacter)||Er.contains(i.decimalCharacterAlternative,i.negativeSignCharacter)||Er.contains(s,i.negativeSignCharacter)||Er.contains(e,i.negativeSignCharacter)||Er.contains(i.suffixText,i.negativeSignCharacter))&&Er.throwError("The negative sign character option 'negativeSignCharacter' is invalid ; it should not be equal or a part of the digit separator, the decimal character, the decimal character alternative, the negative brackets or the suffix text, [".concat(i.negativeSignCharacter,"] given.")),(Er.contains(i.digitGroupSeparator,i.positiveSignCharacter)||Er.contains(i.decimalCharacter,i.positiveSignCharacter)||Er.contains(i.decimalCharacterAlternative,i.positiveSignCharacter)||Er.contains(s,i.positiveSignCharacter)||Er.contains(e,i.positiveSignCharacter)||Er.contains(i.suffixText,i.positiveSignCharacter))&&Er.throwError("The positive sign character option 'positiveSignCharacter' is invalid ; it should not be equal or a part of the digit separator, the decimal character, the decimal character alternative, the negative brackets or the suffix text, [".concat(i.positiveSignCharacter,"] given.")),Er.isNull(i.overrideMinMaxLimits)||Er.isInArray(i.overrideMinMaxLimits,[I.options.overrideMinMaxLimits.ceiling,I.options.overrideMinMaxLimits.floor,I.options.overrideMinMaxLimits.ignore,I.options.overrideMinMaxLimits.invalid])||Er.throwError("The override min & max limits option 'overrideMinMaxLimits' is invalid ; it should either be 'ceiling', 'floor', 'ignore' or 'invalid', [".concat(i.overrideMinMaxLimits,"] given.")),i.overrideMinMaxLimits!==I.options.overrideMinMaxLimits.invalid&&i.overrideMinMaxLimits!==I.options.overrideMinMaxLimits.ignore&&(0<i.minimumValue||i.maximumValue<0)&&Er.warning("You've set a `minimumValue` or a `maximumValue` excluding the value `0`. AutoNumeric will force the users to always have a valid value in the input, hence preventing them to clear the field. If you want to allow for temporary invalid values (ie. out-of-range), you should use the 'invalid' option for the 'overrideMinMaxLimits' setting."),Er.isString(i.maximumValue)&&a.test(i.maximumValue)||Er.throwError("The maximum possible value option 'maximumValue' is invalid ; it should be a string that represents a positive or negative number, [".concat(i.maximumValue,"] given.")),Er.isString(i.minimumValue)&&a.test(i.minimumValue)||Er.throwError("The minimum possible value option 'minimumValue' is invalid ; it should be a string that represents a positive or negative number, [".concat(i.minimumValue,"] given.")),parseFloat(i.minimumValue)>parseFloat(i.maximumValue)&&Er.throwError("The minimum possible value option is greater than the maximum possible value option ; 'minimumValue' [".concat(i.minimumValue,"] should be smaller than 'maximumValue' [").concat(i.maximumValue,"].")),Er.isInt(i.decimalPlaces)&&0<=i.decimalPlaces||Er.isString(i.decimalPlaces)&&o.test(i.decimalPlaces)||Er.throwError("The number of decimal places option 'decimalPlaces' is invalid ; it should be a positive integer, [".concat(i.decimalPlaces,"] given.")),Er.isNull(i.decimalPlacesRawValue)||Er.isInt(i.decimalPlacesRawValue)&&0<=i.decimalPlacesRawValue||Er.isString(i.decimalPlacesRawValue)&&o.test(i.decimalPlacesRawValue)||Er.throwError("The number of decimal places for the raw value option 'decimalPlacesRawValue' is invalid ; it should be a positive integer or `null`, [".concat(i.decimalPlacesRawValue,"] given.")),this._validateDecimalPlacesRawValue(i),Er.isNull(i.decimalPlacesShownOnFocus)||o.test(String(i.decimalPlacesShownOnFocus))||Er.throwError("The number of expanded decimal places option 'decimalPlacesShownOnFocus' is invalid ; it should be a positive integer or `null`, [".concat(i.decimalPlacesShownOnFocus,"] given.")),!Er.isNull(i.decimalPlacesShownOnFocus)&&Number(i.decimalPlaces)>Number(i.decimalPlacesShownOnFocus)&&Er.warning("The extended decimal places 'decimalPlacesShownOnFocus' [".concat(i.decimalPlacesShownOnFocus,"] should be greater than the 'decimalPlaces' [").concat(i.decimalPlaces,"] value. Currently, this will limit the ability of your user to manually change some of the decimal places. Do you really want to do that?"),i.showWarnings),(Er.isNull(i.divisorWhenUnfocused)||t.test(i.divisorWhenUnfocused))&&0!==i.divisorWhenUnfocused&&"0"!==i.divisorWhenUnfocused&&1!==i.divisorWhenUnfocused&&"1"!==i.divisorWhenUnfocused||Er.throwError("The divisor option 'divisorWhenUnfocused' is invalid ; it should be a positive number higher than one, preferably an integer, [".concat(i.divisorWhenUnfocused,"] given.")),Er.isNull(i.decimalPlacesShownOnBlur)||o.test(i.decimalPlacesShownOnBlur)||Er.throwError("The number of decimals shown when unfocused option 'decimalPlacesShownOnBlur' is invalid ; it should be a positive integer or `null`, [".concat(i.decimalPlacesShownOnBlur,"] given.")),Er.isNull(i.symbolWhenUnfocused)||Er.isString(i.symbolWhenUnfocused)||Er.throwError("The symbol to show when unfocused option 'symbolWhenUnfocused' is invalid ; it should be a string, [".concat(i.symbolWhenUnfocused,"] given.")),Er.isTrueOrFalseString(i.saveValueToSessionStorage)||Er.isBoolean(i.saveValueToSessionStorage)||Er.throwError("The save to session storage option 'saveValueToSessionStorage' is invalid ; it should be either 'true' or 'false', [".concat(i.saveValueToSessionStorage,"] given.")),Er.isInArray(i.onInvalidPaste,[I.options.onInvalidPaste.error,I.options.onInvalidPaste.ignore,I.options.onInvalidPaste.clamp,I.options.onInvalidPaste.truncate,I.options.onInvalidPaste.replace])||Er.throwError("The paste behavior option 'onInvalidPaste' is invalid ; it should either be 'error', 'ignore', 'clamp', 'truncate' or 'replace' (cf. documentation), [".concat(i.onInvalidPaste,"] given.")),Er.isInArray(i.roundingMethod,[I.options.roundingMethod.halfUpSymmetric,I.options.roundingMethod.halfUpAsymmetric,I.options.roundingMethod.halfDownSymmetric,I.options.roundingMethod.halfDownAsymmetric,I.options.roundingMethod.halfEvenBankersRounding,I.options.roundingMethod.upRoundAwayFromZero,I.options.roundingMethod.downRoundTowardZero,I.options.roundingMethod.toCeilingTowardPositiveInfinity,I.options.roundingMethod.toFloorTowardNegativeInfinity,I.options.roundingMethod.toNearest05,I.options.roundingMethod.toNearest05Alt,I.options.roundingMethod.upToNext05,I.options.roundingMethod.downToNext05])||Er.throwError("The rounding method option 'roundingMethod' is invalid ; it should either be 'S', 'A', 's', 'a', 'B', 'U', 'D', 'C', 'F', 'N05', 'CHF', 'U05' or 'D05' (cf. documentation), [".concat(i.roundingMethod,"] given.")),Er.isNull(i.negativeBracketsTypeOnBlur)||Er.isInArray(i.negativeBracketsTypeOnBlur,[I.options.negativeBracketsTypeOnBlur.parentheses,I.options.negativeBracketsTypeOnBlur.brackets,I.options.negativeBracketsTypeOnBlur.chevrons,I.options.negativeBracketsTypeOnBlur.curlyBraces,I.options.negativeBracketsTypeOnBlur.angleBrackets,I.options.negativeBracketsTypeOnBlur.japaneseQuotationMarks,I.options.negativeBracketsTypeOnBlur.halfBrackets,I.options.negativeBracketsTypeOnBlur.whiteSquareBrackets,I.options.negativeBracketsTypeOnBlur.quotationMarks,I.options.negativeBracketsTypeOnBlur.guillemets])||Er.throwError("The brackets for negative values option 'negativeBracketsTypeOnBlur' is invalid ; it should either be '(,)', '[,]', '<,>', '{,}', '〈,〉', '｢,｣', '⸤,⸥', '⟦,⟧', '‹,›' or '«,»', [".concat(i.negativeBracketsTypeOnBlur,"] given.")),(Er.isString(i.emptyInputBehavior)||Er.isNumber(i.emptyInputBehavior))&&(Er.isInArray(i.emptyInputBehavior,[I.options.emptyInputBehavior.focus,I.options.emptyInputBehavior.press,I.options.emptyInputBehavior.always,I.options.emptyInputBehavior.min,I.options.emptyInputBehavior.max,I.options.emptyInputBehavior.zero,I.options.emptyInputBehavior.null])||a.test(i.emptyInputBehavior))||Er.throwError("The display on empty string option 'emptyInputBehavior' is invalid ; it should either be 'focus', 'press', 'always', 'min', 'max', 'zero', 'null', a number, or a string that represents a number, [".concat(i.emptyInputBehavior,"] given.")),i.emptyInputBehavior===I.options.emptyInputBehavior.zero&&(0<i.minimumValue||i.maximumValue<0)&&Er.throwError("The 'emptyInputBehavior' option is set to 'zero', but this value is outside of the range defined by 'minimumValue' and 'maximumValue' [".concat(i.minimumValue,", ").concat(i.maximumValue,"].")),a.test(String(i.emptyInputBehavior))&&(this._isWithinRangeWithOverrideOption(i.emptyInputBehavior,i)||Er.throwError("The 'emptyInputBehavior' option is set to a number or a string that represents a number, but its value [".concat(i.emptyInputBehavior,"] is outside of the range defined by the 'minimumValue' and 'maximumValue' options [").concat(i.minimumValue,", ").concat(i.maximumValue,"]."))),Er.isTrueOrFalseString(i.eventBubbles)||Er.isBoolean(i.eventBubbles)||Er.throwError("The event bubbles option 'eventBubbles' is invalid ; it should be either 'true' or 'false', [".concat(i.eventBubbles,"] given.")),Er.isTrueOrFalseString(i.eventIsCancelable)||Er.isBoolean(i.eventIsCancelable)||Er.throwError("The event is cancelable option 'eventIsCancelable' is invalid ; it should be either 'true' or 'false', [".concat(i.eventIsCancelable,"] given.")),!Er.isBoolean(i.invalidClass)&&/^-?[_a-zA-Z]+[_a-zA-Z0-9-]*$/.test(i.invalidClass)||Er.throwError("The name of the 'invalidClass' option is not a valid CSS class name ; it should not be empty, and should follow the '^-?[_a-zA-Z]+[_a-zA-Z0-9-]*$' regex, [".concat(i.invalidClass,"] given.")),Er.isInArray(i.leadingZero,[I.options.leadingZero.allow,I.options.leadingZero.deny,I.options.leadingZero.keep])||Er.throwError("The leading zero behavior option 'leadingZero' is invalid ; it should either be 'allow', 'deny' or 'keep', [".concat(i.leadingZero,"] given.")),Er.isTrueOrFalseString(i.formatOnPageLoad)||Er.isBoolean(i.formatOnPageLoad)||Er.throwError("The format on initialization option 'formatOnPageLoad' is invalid ; it should be either 'true' or 'false', [".concat(i.formatOnPageLoad,"] given.")),Er.isTrueOrFalseString(i.formulaMode)||Er.isBoolean(i.formulaMode)||Er.throwError("The formula mode option 'formulaMode' is invalid ; it should be either 'true' or 'false', [".concat(i.formulaMode,"] given.")),o.test(i.historySize)&&0!==i.historySize||Er.throwError("The history size option 'historySize' is invalid ; it should be a positive integer, [".concat(i.historySize,"] given.")),Er.isTrueOrFalseString(i.selectNumberOnly)||Er.isBoolean(i.selectNumberOnly)||Er.throwError("The select number only option 'selectNumberOnly' is invalid ; it should be either 'true' or 'false', [".concat(i.selectNumberOnly,"] given.")),Er.isTrueOrFalseString(i.selectOnFocus)||Er.isBoolean(i.selectOnFocus)||Er.throwError("The select on focus option 'selectOnFocus' is invalid ; it should be either 'true' or 'false', [".concat(i.selectOnFocus,"] given.")),Er.isNull(i.defaultValueOverride)||""===i.defaultValueOverride||a.test(i.defaultValueOverride)||Er.throwError("The unformatted default value option 'defaultValueOverride' is invalid ; it should be a string that represents a positive or negative number, [".concat(i.defaultValueOverride,"] given.")),Er.isTrueOrFalseString(i.unformatOnSubmit)||Er.isBoolean(i.unformatOnSubmit)||Er.throwError("The remove formatting on submit option 'unformatOnSubmit' is invalid ; it should be either 'true' or 'false', [".concat(i.unformatOnSubmit,"] given.")),Er.isNull(i.valuesToStrings)||Er.isObject(i.valuesToStrings)||Er.throwError("The option 'valuesToStrings' is invalid ; it should be an object, ideally with 'key -> value' entries, [".concat(i.valuesToStrings,"] given.")),Er.isNull(i.outputFormat)||Er.isInArray(i.outputFormat,[I.options.outputFormat.string,I.options.outputFormat.number,I.options.outputFormat.dot,I.options.outputFormat.negativeDot,I.options.outputFormat.comma,I.options.outputFormat.negativeComma,I.options.outputFormat.dotNegative,I.options.outputFormat.commaNegative])||Er.throwError("The custom locale format option 'outputFormat' is invalid ; it should either be null, 'string', 'number', '.', '-.', ',', '-,', '.-' or ',-', [".concat(i.outputFormat,"] given.")),Er.isTrueOrFalseString(i.isCancellable)||Er.isBoolean(i.isCancellable)||Er.throwError("The cancellable behavior option 'isCancellable' is invalid ; it should be either 'true' or 'false', [".concat(i.isCancellable,"] given.")),Er.isTrueOrFalseString(i.modifyValueOnWheel)||Er.isBoolean(i.modifyValueOnWheel)||Er.throwError("The increment/decrement on mouse wheel option 'modifyValueOnWheel' is invalid ; it should be either 'true' or 'false', [".concat(i.modifyValueOnWheel,"] given.")),Er.isTrueOrFalseString(i.watchExternalChanges)||Er.isBoolean(i.watchExternalChanges)||Er.throwError("The option 'watchExternalChanges' is invalid ; it should be either 'true' or 'false', [".concat(i.watchExternalChanges,"] given.")),Er.isInArray(i.wheelOn,[I.options.wheelOn.focus,I.options.wheelOn.hover])||Er.throwError("The wheel behavior option 'wheelOn' is invalid ; it should either be 'focus' or 'hover', [".concat(i.wheelOn,"] given.")),(Er.isString(i.wheelStep)||Er.isNumber(i.wheelStep))&&("progressive"===i.wheelStep||t.test(i.wheelStep))&&0!==Number(i.wheelStep)||Er.throwError("The wheel step value option 'wheelStep' is invalid ; it should either be the string 'progressive', or a number or a string that represents a positive number (excluding zero), [".concat(i.wheelStep,"] given.")),Er.isInArray(i.serializeSpaces,[I.options.serializeSpaces.plus,I.options.serializeSpaces.percent])||Er.throwError("The space replacement character option 'serializeSpaces' is invalid ; it should either be '+' or '%20', [".concat(i.serializeSpaces,"] given.")),Er.isTrueOrFalseString(i.noEventListeners)||Er.isBoolean(i.noEventListeners)||Er.throwError("The option 'noEventListeners' that prevent the creation of event listeners is invalid ; it should be either 'true' or 'false', [".concat(i.noEventListeners,"] given.")),Er.isNull(i.styleRules)||Er.isObject(i.styleRules)&&(Object.prototype.hasOwnProperty.call(i.styleRules,"positive")||Object.prototype.hasOwnProperty.call(i.styleRules,"negative")||Object.prototype.hasOwnProperty.call(i.styleRules,"ranges")||Object.prototype.hasOwnProperty.call(i.styleRules,"userDefined"))||Er.throwError("The option 'styleRules' is invalid ; it should be a correctly structured object, with one or more 'positive', 'negative', 'ranges' or 'userDefined' attributes, [".concat(i.styleRules,"] given.")),Er.isNull(i.styleRules)||!Object.prototype.hasOwnProperty.call(i.styleRules,"userDefined")||Er.isNull(i.styleRules.userDefined)||i.styleRules.userDefined.forEach(function(e){Object.prototype.hasOwnProperty.call(e,"callback")&&!Er.isFunction(e.callback)&&Er.throwError("The callback defined in the `userDefined` attribute is not a function, ".concat(zr(e.callback)," given."))}),(Er.isNull(i.rawValueDivisor)||t.test(i.rawValueDivisor))&&0!==i.rawValueDivisor&&"0"!==i.rawValueDivisor&&1!==i.rawValueDivisor&&"1"!==i.rawValueDivisor||Er.throwError("The raw value divisor option 'rawValueDivisor' is invalid ; it should be a positive number higher than one, preferably an integer, [".concat(i.rawValueDivisor,"] given.")),Er.isTrueOrFalseString(i.readOnly)||Er.isBoolean(i.readOnly)||Er.throwError("The option 'readOnly' is invalid ; it should be either 'true' or 'false', [".concat(i.readOnly,"] given.")),Er.isTrueOrFalseString(i.unformatOnHover)||Er.isBoolean(i.unformatOnHover)||Er.throwError("The option 'unformatOnHover' is invalid ; it should be either 'true' or 'false', [".concat(i.unformatOnHover,"] given.")),Er.isTrueOrFalseString(i.failOnUnknownOption)||Er.isBoolean(i.failOnUnknownOption)||Er.throwError("The debug option 'failOnUnknownOption' is invalid ; it should be either 'true' or 'false', [".concat(i.failOnUnknownOption,"] given.")),Er.isTrueOrFalseString(i.createLocalList)||Er.isBoolean(i.createLocalList)||Er.throwError("The debug option 'createLocalList' is invalid ; it should be either 'true' or 'false', [".concat(i.createLocalList,"] given."))}},{key:"_validateDecimalPlacesRawValue",value:function(e){Er.isNull(e.decimalPlacesRawValue)||(e.decimalPlacesRawValue<e.decimalPlaces&&Er.warning("The number of decimal places to store in the raw value [".concat(e.decimalPlacesRawValue,"] is lower than the ones to display [").concat(e.decimalPlaces,"]. This will likely confuse your users.\nTo solve that, you'd need to either set `decimalPlacesRawValue` to `null`, or set a number of decimal places for the raw value equal of bigger than `decimalPlaces`."),e.showWarnings),e.decimalPlacesRawValue<e.decimalPlacesShownOnFocus&&Er.warning("The number of decimal places to store in the raw value [".concat(e.decimalPlacesRawValue,"] is lower than the ones shown on focus [").concat(e.decimalPlacesShownOnFocus,"]. This will likely confuse your users.\nTo solve that, you'd need to either set `decimalPlacesRawValue` to `null`, or set a number of decimal places for the raw value equal of bigger than `decimalPlacesShownOnFocus`."),e.showWarnings),e.decimalPlacesRawValue<e.decimalPlacesShownOnBlur&&Er.warning("The number of decimal places to store in the raw value [".concat(e.decimalPlacesRawValue,"] is lower than the ones shown when unfocused [").concat(e.decimalPlacesShownOnBlur,"]. This will likely confuse your users.\nTo solve that, you'd need to either set `decimalPlacesRawValue` to `null`, or set a number of decimal places for the raw value equal of bigger than `decimalPlacesShownOnBlur`."),e.showWarnings))}},{key:"areSettingsValid",value:function(e){var t=!0;try{this.validate(e,!0)}catch(e){t=!1}return t}},{key:"getDefaultConfig",value:function(){return I.defaultSettings}},{key:"getPredefinedOptions",value:function(){return I.predefinedOptions}},{key:"_generateOptionsObjectFromOptionsArray",value:function(e){var t,n=this;return Er.isUndefinedOrNullOrEmpty(e)||0===e.length?t=null:(t={},1===e.length&&Array.isArray(e[0])?e[0].forEach(function(e){Object.assign(t,n._getOptionObject(e))}):1<=e.length&&e.forEach(function(e){Object.assign(t,n._getOptionObject(e))})),t}},{key:"format",value:function(e){if(Er.isUndefined(e)||null===e)return null;var t=Er.isElement(e)?Er.getElementValue(e):e;Er.isString(t)||Er.isNumber(t)||Er.throwError('The value "'.concat(t,'" being "set" is not numeric and therefore cannot be used appropriately.'));for(var n=arguments.length,i=new Array(1<n?n-1:0),r=1;r<n;r++)i[r-1]=arguments[r];var o=this._generateOptionsObjectFromOptionsArray(i),e=Object.assign({},this.getDefaultConfig(),o);e.isNegativeSignAllowed=t<0,e.isPositiveSignAllowed=0<=t,this._setBrackets(e);this._cachesUsualRegularExpressions(e,{});o=this._toNumericValue(t,e);return isNaN(Number(o))&&Er.throwError("The value [".concat(o,"] that you are trying to format is not a recognized number.")),this._isWithinRangeWithOverrideOption(o,e)||(Er.triggerEvent(I.events.formatted,document,{oldValue:null,newValue:null,oldRawValue:null,newRawValue:null,isPristine:null,error:"Range test failed",aNElement:null},!0,!0),Er.throwError("The value [".concat(o,"] being set falls outside of the minimumValue [").concat(e.minimumValue,"] and maximumValue [").concat(e.maximumValue,"] range set for this element"))),e.valuesToStrings&&this._checkValuesToStringsSettings(t,e)?e.valuesToStrings[t]:(this._correctNegativePositiveSignPlacementOption(e),this._calculateDecimalPlacesOnInit(e),Er.isUndefinedOrNullOrEmpty(e.rawValueDivisor)||0===e.rawValueDivisor||""===o||null===o||(o*=e.rawValueDivisor),o=this._roundFormattedValueShownOnFocus(o,e),o=this._modifyNegativeSignAndDecimalCharacterForFormattedValue(o,e),o=this._addGroupSeparators(o,e,!1,o))}},{key:"formatAndSet",value:function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:null,t=this.format(e,t);return Er.setElementValue(e,t),t}},{key:"unformat",value:function(e){if(Er.isNumberStrict(e))return e;var t=Er.isElement(e)?Er.getElementValue(e):e;if(""===t)return"";if(Er.isUndefined(t)||null===t)return null;(Er.isArray(t)||Er.isObject(t))&&Er.throwError("A number or a string representing a number is needed to be able to unformat it, [".concat(t,"] given."));for(var n=arguments.length,i=new Array(1<n?n-1:0),r=1;r<n;r++)i[r-1]=arguments[r];var o=this._generateOptionsObjectFromOptionsArray(i),e=Object.assign({},this.getDefaultConfig(),o);return e.isNegativeSignAllowed=!1,e.isPositiveSignAllowed=!0,t=t.toString(),e.valuesToStrings&&this._checkStringsToValuesSettings(t,e)?Er.objectKeyLookup(e.valuesToStrings,t):(Er.isNegative(t,e.negativeSignCharacter)?(e.isNegativeSignAllowed=!0,e.isPositiveSignAllowed=!1):Er.isNull(e.negativeBracketsTypeOnBlur)||(o=Vr(e.negativeBracketsTypeOnBlur.split(","),2),e.firstBracket=o[0],e.lastBracket=o[1],t.charAt(0)===e.firstBracket&&t.charAt(t.length-1)===e.lastBracket&&(e.isNegativeSignAllowed=!0,e.isPositiveSignAllowed=!1,t=this._removeBrackets(t,e,!1))),t=this._convertToNumericString(t,e),new RegExp("[^+-0123456789.]","gi").test(t)?NaN:(this._correctNegativePositiveSignPlacementOption(e),e.decimalPlacesRawValue?e.originalDecimalPlacesRawValue=e.decimalPlacesRawValue:e.originalDecimalPlacesRawValue=e.decimalPlaces,this._calculateDecimalPlacesOnInit(e),Er.isUndefinedOrNullOrEmpty(e.rawValueDivisor)||0===e.rawValueDivisor||""===t||null===t||(t/=e.rawValueDivisor),t=(t=this._roundRawValue(t,e)).replace(e.decimalCharacter,"."),t=this._toLocale(t,e.outputFormat,e)))}},{key:"unformatAndSet",value:function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:null,t=this.unformat(e,t);return Er.setElementValue(e,t),t}},{key:"localize",value:function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:null,n=Er.isElement(e)?Er.getElementValue(e):e;return""===n?"":(Er.isNull(t)&&(t=I.defaultSettings),n=this.unformat(n,t),0===Number(n)&&t.leadingZero!==I.options.leadingZero.keep&&(n="0"),e=(Er.isNull(t)?t:I.defaultSettings).outputFormat,this._toLocale(n,e,t))}},{key:"localizeAndSet",value:function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:null,t=this.localize(e,t);return Er.setElementValue(e,t),t}},{key:"isManagedByAutoNumeric",value:function(e){return this._isInGlobalList(Er.domElement(e))}},{key:"getAutoNumericElement",value:function(e){e=Er.domElement(e);return this.isManagedByAutoNumeric(e)?this._getFromGlobalList(e):null}},{key:"set",value:function(e,t){var n=2<arguments.length&&void 0!==arguments[2]?arguments[2]:null,i=!(3<arguments.length&&void 0!==arguments[3])||arguments[3],e=Er.domElement(e);if(this.isManagedByAutoNumeric(e))return this.getAutoNumericElement(e).set(t,n,i);n=!(!Er.isNull(n)&&Object.prototype.hasOwnProperty.call(n,"showWarnings"))||n.showWarnings;return Er.warning("Impossible to find an AutoNumeric object for the given DOM element or selector.",n),null}},{key:"getNumericString",value:function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:null;return this._get(e,"getNumericString",t)}},{key:"getFormatted",value:function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:null;return this._get(e,"getFormatted",t)}},{key:"getNumber",value:function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:null;return this._get(e,"getNumber",t)}},{key:"_get",value:function(e,t){var n=2<arguments.length&&void 0!==arguments[2]?arguments[2]:null,e=Er.domElement(e);return this.isManagedByAutoNumeric(e)||Er.throwError("Impossible to find an AutoNumeric object for the given DOM element or selector."),this.getAutoNumericElement(e)[t](n)}},{key:"getLocalized",value:function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:null,n=2<arguments.length&&void 0!==arguments[2]?arguments[2]:null,e=Er.domElement(e);return this.isManagedByAutoNumeric(e)||Er.throwError("Impossible to find an AutoNumeric object for the given DOM element or selector."),this.getAutoNumericElement(e).getLocalized(t,n)}},{key:"_stripAllNonNumberCharacters",value:function(e,t,n,i){return this._stripAllNonNumberCharactersExceptCustomDecimalChar(e,t,n,i).replace(t.decimalCharacter,".")}},{key:"_stripAllNonNumberCharactersExceptCustomDecimalChar",value:function(e,t,n,i){var r,o,s=(e=(e=this._normalizeCurrencySuffixAndNegativeSignCharacters(e,t)).replace(t.allowedAutoStrip,"")).match(t.numRegAutoStrip);return e=s?[s[1],s[2],s[3]].join(""):"",t.leadingZero!==I.options.leadingZero.allow&&t.leadingZero!==I.options.leadingZero.keep||(r="",s=(o=Vr(e.split(t.decimalCharacter),2))[0],o=o[1],s=s,Er.contains(s,t.negativeSignCharacter)&&(r=t.negativeSignCharacter,s=s.replace(t.negativeSignCharacter,"")),""===r&&s.length>t.mIntPos&&"0"===s.charAt(0)&&(s=s.slice(1)),""!==r&&s.length>t.mIntNeg&&"0"===s.charAt(0)&&(s=s.slice(1)),e="".concat(r).concat(s).concat(Er.isUndefined(o)?"":t.decimalCharacter+o)),e=n&&t.leadingZero===I.options.leadingZero.deny||!i&&t.leadingZero===I.options.leadingZero.allow?e.replace(t.stripReg,"$1$2"):e}},{key:"_toggleNegativeBracket",value:function(e,t,n){t=n?this._removeBrackets(e,t):this._addBrackets(e,t);return t}},{key:"_addBrackets",value:function(e,t){return Er.isNull(t.negativeBracketsTypeOnBlur)?e:"".concat(t.firstBracket).concat(e.replace(t.negativeSignCharacter,"")).concat(t.lastBracket)}},{key:"_removeBrackets",value:function(e,t){var n=!(2<arguments.length&&void 0!==arguments[2])||arguments[2],i=Er.isNull(t.negativeBracketsTypeOnBlur)||e.charAt(0)!==t.firstBracket?e:(i=(i=e.replace(t.firstBracket,"")).replace(t.lastBracket,""),n?(i=i.replace(t.currencySymbol,""),this._mergeCurrencySignNegativePositiveSignAndValue(i,t,!0,!1)):"".concat(t.negativeSignCharacter).concat(i));return i}},{key:"_setBrackets",value:function(e){var t,n;Er.isNull(e.negativeBracketsTypeOnBlur)?(e.firstBracket="",e.lastBracket=""):(t=(n=Vr(e.negativeBracketsTypeOnBlur.split(","),2))[0],n=n[1],e.firstBracket=t,e.lastBracket=n)}},{key:"_convertToNumericString",value:function(e,t){e=this._removeBrackets(e,t,!1),e=(e=this._normalizeCurrencySuffixAndNegativeSignCharacters(e,t)).replace(new RegExp("[".concat(t.digitGroupSeparator,"]"),"g"),""),"."!==t.decimalCharacter&&(e=e.replace(t.decimalCharacter,".")),Er.isNegative(e)&&e.lastIndexOf("-")===e.length-1&&(e=e.replace("-",""),e="-".concat(e)),t.showPositiveSign&&(e=e.replace(t.positiveSignCharacter,""));t=t.leadingZero!==I.options.leadingZero.keep,t=Er.arabicToLatinNumbers(e,t,!1,!1);return e=!isNaN(t)?t.toString():e}},{key:"_normalizeCurrencySuffixAndNegativeSignCharacters",value:function(e,t){return e=String(e),t.currencySymbol!==I.options.currencySymbol.none&&(e=e.replace(t.currencySymbol,"")),t.suffixText!==I.options.suffixText.none&&(e=e.replace(t.suffixText,"")),e=t.negativeSignCharacter!==I.options.negativeSignCharacter.hyphen?e.replace(t.negativeSignCharacter,"-"):e}},{key:"_toLocale",value:function(e,t,n){if(Er.isNull(t)||t===I.options.outputFormat.string)return e;var i;switch(t){case I.options.outputFormat.number:i=Number(e);break;case I.options.outputFormat.dotNegative:i=Er.isNegative(e)?e.replace("-","")+"-":e;break;case I.options.outputFormat.comma:case I.options.outputFormat.negativeComma:i=e.replace(".",",");break;case I.options.outputFormat.commaNegative:i=e.replace(".",","),i=Er.isNegative(i)?i.replace("-","")+"-":i;break;case I.options.outputFormat.dot:case I.options.outputFormat.negativeDot:i=e;break;default:Er.throwError("The given outputFormat [".concat(t,"] option is not recognized."))}return i=t!==I.options.outputFormat.number&&"-"!==n.negativeSignCharacter?i.replace("-",n.negativeSignCharacter):i}},{key:"_modifyNegativeSignAndDecimalCharacterForFormattedValue",value:function(e,t){return"-"!==t.negativeSignCharacter&&(e=e.replace("-",t.negativeSignCharacter)),e="."!==t.decimalCharacter?e.replace(".",t.decimalCharacter):e}},{key:"_isElementValueEmptyOrOnlyTheNegativeSign",value:function(e,t){return""===e||e===t.negativeSignCharacter}},{key:"_orderValueCurrencySymbolAndSuffixText",value:function(e,t,n){var i;if(t.emptyInputBehavior===I.options.emptyInputBehavior.always||n)switch(t.negativePositiveSignPlacement){case I.options.negativePositiveSignPlacement.left:case I.options.negativePositiveSignPlacement.prefix:case I.options.negativePositiveSignPlacement.none:i=e+t.currencySymbol+t.suffixText;break;default:i=t.currencySymbol+e+t.suffixText}else i=e;return i}},{key:"_addGroupSeparators",value:function(e,t,n,i){var r=4<arguments.length&&void 0!==arguments[4]?arguments[4]:null,o=Er.isNull(r)?Er.isNegative(e,t.negativeSignCharacter)||Er.isNegativeWithBrackets(e,t.firstBracket,t.lastBracket):r<0;if(e=this._stripAllNonNumberCharactersExceptCustomDecimalChar(e,t,!1,n),this._isElementValueEmptyOrOnlyTheNegativeSign(e,t))return this._orderValueCurrencySymbolAndSuffixText(e,t,!0);var s,a=Er.isZeroOrHasNoValue(e);switch(o&&(e=e.replace("-","")),t.digitalGroupSpacing=t.digitalGroupSpacing.toString(),t.digitalGroupSpacing){case I.options.digitalGroupSpacing.two:s=/(\d)((\d)(\d{2}?)+)$/;break;case I.options.digitalGroupSpacing.twoScaled:s=/(\d)((?:\d{2}){0,2}\d{3}(?:(?:\d{2}){2}\d{3})*?)$/;break;case I.options.digitalGroupSpacing.four:s=/(\d)((\d{4}?)+)$/;break;case I.options.digitalGroupSpacing.three:default:s=/(\d)((\d{3}?)+)$/}var l,c=Vr(e.split(t.decimalCharacter),2),u=c[0],c=c[1];if(t.decimalCharacterAlternative&&Er.isUndefined(c)&&(u=(l=Vr(e.split(t.decimalCharacterAlternative),2))[0],c=l[1]),""!==t.digitGroupSeparator)for(;s.test(u);)u=u.replace(s,"$1".concat(t.digitGroupSeparator,"$2"));return e=0===(l=n?t.decimalPlacesShownOnFocus:t.decimalPlacesShownOnBlur)||Er.isUndefined(c)?u:(c.length>l&&(c=c.substring(0,l)),"".concat(u).concat(t.decimalCharacter).concat(c)),e=I._mergeCurrencySignNegativePositiveSignAndValue(e,t,o,a),Er.isNull(r)&&(r=i),null!==t.negativeBracketsTypeOnBlur&&(r<0||Er.isNegativeStrict(e,t.negativeSignCharacter))&&(e=this._toggleNegativeBracket(e,t,n)),t.suffixText?"".concat(e).concat(t.suffixText):e}},{key:"_mergeCurrencySignNegativePositiveSignAndValue",value:function(e,t,n,i){var r,o="";if(n?o=t.negativeSignCharacter:t.showPositiveSign&&!i&&(o=t.positiveSignCharacter),t.currencySymbolPlacement===I.options.currencySymbolPlacement.prefix)if(t.negativePositiveSignPlacement!==I.options.negativePositiveSignPlacement.none&&(n||!n&&t.showPositiveSign&&!i))switch(t.negativePositiveSignPlacement){case I.options.negativePositiveSignPlacement.prefix:case I.options.negativePositiveSignPlacement.left:r="".concat(o).concat(t.currencySymbol).concat(e);break;case I.options.negativePositiveSignPlacement.right:r="".concat(t.currencySymbol).concat(o).concat(e);break;case I.options.negativePositiveSignPlacement.suffix:r="".concat(t.currencySymbol).concat(e).concat(o)}else r=t.currencySymbol+e;else if(t.currencySymbolPlacement===I.options.currencySymbolPlacement.suffix)if(t.negativePositiveSignPlacement!==I.options.negativePositiveSignPlacement.none&&(n||!n&&t.showPositiveSign&&!i))switch(t.negativePositiveSignPlacement){case I.options.negativePositiveSignPlacement.suffix:case I.options.negativePositiveSignPlacement.right:r="".concat(e).concat(t.currencySymbol).concat(o);break;case I.options.negativePositiveSignPlacement.left:r="".concat(e).concat(o).concat(t.currencySymbol);break;case I.options.negativePositiveSignPlacement.prefix:r="".concat(o).concat(e).concat(t.currencySymbol)}else r=e+t.currencySymbol;return r}},{key:"_truncateZeros",value:function(e,t){var n;switch(t){case 0:n=/(\.(?:\d*[1-9])?)0*$/;break;case 1:n=/(\.\d(?:\d*[1-9])?)0*$/;break;default:n=new RegExp("(\\.\\d{".concat(t,"}(?:\\d*[1-9])?)0*"))}return e=e.replace(n,"$1"),e=0===t?e.replace(/\.$/,""):e}},{key:"_roundRawValue",value:function(e,t){return this._roundValue(e,t,t.decimalPlacesRawValue)}},{key:"_roundFormattedValueShownOnFocus",value:function(e,t){return this._roundValue(e,t,Number(t.decimalPlacesShownOnFocus))}},{key:"_roundFormattedValueShownOnBlur",value:function(e,t){return this._roundValue(e,t,Number(t.decimalPlacesShownOnBlur))}},{key:"_roundFormattedValueShownOnFocusOrBlur",value:function(e,t,n){return n?this._roundFormattedValueShownOnFocus(e,t):this._roundFormattedValueShownOnBlur(e,t)}},{key:"_roundValue",value:function(e,t,n){if(Er.isNull(e))return e;if(e=""===e?"0":e.toString(),t.roundingMethod===I.options.roundingMethod.toNearest05||t.roundingMethod===I.options.roundingMethod.toNearest05Alt||t.roundingMethod===I.options.roundingMethod.upToNext05||t.roundingMethod===I.options.roundingMethod.downToNext05)return this._roundCloseTo05(e,t);var i,r=Vr(I._prepareValueForRounding(e,t),2),o=r[0],s=(e=r[1]).lastIndexOf("."),a=-1===s,l=Vr(e.split("."),2),r=l[0];if(!(0<l[1])&&(t.allowDecimalPadding===I.options.allowDecimalPadding.never||t.allowDecimalPadding===I.options.allowDecimalPadding.floats))return 0===Number(e)?r:"".concat(o).concat(r);i=t.allowDecimalPadding===I.options.allowDecimalPadding.always||t.allowDecimalPadding===I.options.allowDecimalPadding.floats?n:0;var r=a?e.length-1:s,c=e.length-1-r,u="";if(c<=n){if(u=e,c<i){a&&(u="".concat(u).concat(t.decimalCharacter));for(var h="000000";c<i;)u+=h=h.substring(0,i-c),c+=h.length}else i<c?u=this._truncateZeros(u,i):0===c&&0===i&&(u=u.replace(/\.$/,""));return 0===Number(u)?u:"".concat(o).concat(u)}n=a?n-1:Number(n)+Number(s);var s=Number(e.charAt(n+1)),d=e.substring(0,n+1).split(""),e="."===e.charAt(n)?e.charAt(n-1)%2:e.charAt(n)%2;if(this._shouldRoundUp(s,t,o,e))for(var m=d.length-1;0<=m;--m)if("."!==d[m]){if(d[m]=+d[m]+1,d[m]<10)break;0<m&&(d[m]="0")}return d=d.slice(0,n+1),u=this._truncateZeros(d.join(""),i),0===Number(u)?u:"".concat(o).concat(u)}},{key:"_roundCloseTo05",value:function(e,t){switch(t.roundingMethod){case I.options.roundingMethod.toNearest05:case I.options.roundingMethod.toNearest05Alt:e=(Math.round(20*e)/20).toString();break;case I.options.roundingMethod.upToNext05:e=(Math.ceil(20*e)/20).toString();break;default:e=(Math.floor(20*e)/20).toString()}t=Er.contains(e,".")?e.length-e.indexOf(".")<3?e+"0":e:e+".00";return t}},{key:"_prepareValueForRounding",value:function(e,t){var n="";return Er.isNegativeStrict(e,"-")&&(n="-",e=e.replace("-","")),e.match(/^\d/)||(e="0".concat(e)),[n=0===Number(e)?"":n,e=0<Number(e)&&t.leadingZero!==I.options.leadingZero.keep||0<e.length&&t.leadingZero===I.options.leadingZero.allow?e.replace(/^0*(\d)/,"$1"):e]}},{key:"_shouldRoundUp",value:function(e,t,n,i){return 4<e&&t.roundingMethod===I.options.roundingMethod.halfUpSymmetric||4<e&&t.roundingMethod===I.options.roundingMethod.halfUpAsymmetric&&""===n||5<e&&t.roundingMethod===I.options.roundingMethod.halfUpAsymmetric&&"-"===n||5<e&&t.roundingMethod===I.options.roundingMethod.halfDownSymmetric||5<e&&t.roundingMethod===I.options.roundingMethod.halfDownAsymmetric&&""===n||4<e&&t.roundingMethod===I.options.roundingMethod.halfDownAsymmetric&&"-"===n||5<e&&t.roundingMethod===I.options.roundingMethod.halfEvenBankersRounding||5===e&&t.roundingMethod===I.options.roundingMethod.halfEvenBankersRounding&&1===i||0<e&&t.roundingMethod===I.options.roundingMethod.toCeilingTowardPositiveInfinity&&""===n||0<e&&t.roundingMethod===I.options.roundingMethod.toFloorTowardNegativeInfinity&&"-"===n||0<e&&t.roundingMethod===I.options.roundingMethod.upRoundAwayFromZero}},{key:"_truncateDecimalPlaces",value:function(e,t,n,i){var r=Vr((e=n?this._roundFormattedValueShownOnFocus(e,t):e).split(t.decimalCharacter),2),n=r[0],r=r[1];return e=r&&r.length>i?0<i?(i=r.substring(0,i),"".concat(n).concat(t.decimalCharacter).concat(i)):n:e}},{key:"_checkIfInRangeWithOverrideOption",value:function(e,t){if(Er.isNull(e)&&t.emptyInputBehavior===I.options.emptyInputBehavior.null||t.overrideMinMaxLimits===I.options.overrideMinMaxLimits.ignore||t.overrideMinMaxLimits===I.options.overrideMinMaxLimits.invalid)return[!0,!0];e=(e=e.toString()).replace(",",".");var n,i=Er.parseStr(t.minimumValue),r=Er.parseStr(t.maximumValue),o=Er.parseStr(e);switch(t.overrideMinMaxLimits){case I.options.overrideMinMaxLimits.floor:n=[-1<Er.testMinMax(i,o),!0];break;case I.options.overrideMinMaxLimits.ceiling:n=[!0,Er.testMinMax(r,o)<1];break;default:n=[-1<Er.testMinMax(i,o),Er.testMinMax(r,o)<1]}return n}},{key:"_isWithinRangeWithOverrideOption",value:function(e,t){e=Vr(this._checkIfInRangeWithOverrideOption(e,t),2),t=e[0],e=e[1];return t&&e}},{key:"_cleanValueForRangeParse",value:function(e){return e=e.toString().replace(",","."),Er.parseStr(e)}},{key:"_isMinimumRangeRespected",value:function(e,t){return-1<Er.testMinMax(Er.parseStr(t.minimumValue),this._cleanValueForRangeParse(e))}},{key:"_isMaximumRangeRespected",value:function(e,t){return Er.testMinMax(Er.parseStr(t.maximumValue),this._cleanValueForRangeParse(e))<1}},{key:"_readCookie",value:function(e){for(var t=e+"=",n=document.cookie.split(";"),i="",r=0;r<n.length;r+=1){for(i=n[r];" "===i.charAt(0);)i=i.substring(1,i.length);if(0===i.indexOf(t))return i.substring(t.length,i.length)}return null}},{key:"_storageTest",value:function(){var e="modernizr";try{return sessionStorage.setItem(e,e),sessionStorage.removeItem(e),!0}catch(e){return!1}}},{key:"_correctNegativePositiveSignPlacementOption",value:function(e){if(Er.isNull(e.negativePositiveSignPlacement))if(Er.isUndefined(e)||!Er.isUndefinedOrNullOrEmpty(e.negativePositiveSignPlacement)||Er.isUndefinedOrNullOrEmpty(e.currencySymbol))e.negativePositiveSignPlacement=I.options.negativePositiveSignPlacement.left;else switch(e.currencySymbolPlacement){case I.options.currencySymbolPlacement.suffix:e.negativePositiveSignPlacement=I.options.negativePositiveSignPlacement.prefix;break;case I.options.currencySymbolPlacement.prefix:e.negativePositiveSignPlacement=I.options.negativePositiveSignPlacement.left}}},{key:"_correctCaretPositionOnFocusAndSelectOnFocusOptions",value:function(e){return Er.isNull(e)?null:(!Er.isUndefinedOrNullOrEmpty(e.caretPositionOnFocus)&&Er.isUndefinedOrNullOrEmpty(e.selectOnFocus)&&(e.selectOnFocus=I.options.selectOnFocus.doNotSelect),Er.isUndefinedOrNullOrEmpty(e.caretPositionOnFocus)&&!Er.isUndefinedOrNullOrEmpty(e.selectOnFocus)&&e.selectOnFocus===I.options.selectOnFocus.select&&(e.caretPositionOnFocus=I.options.caretPositionOnFocus.doNoForceCaretPosition),e)}},{key:"_calculateDecimalPlacesOnInit",value:function(e){this._validateDecimalPlacesRawValue(e),e.decimalPlacesShownOnFocus===I.options.decimalPlacesShownOnFocus.useDefault&&(e.decimalPlacesShownOnFocus=e.decimalPlaces),e.decimalPlacesShownOnBlur===I.options.decimalPlacesShownOnBlur.useDefault&&(e.decimalPlacesShownOnBlur=e.decimalPlaces),e.decimalPlacesRawValue===I.options.decimalPlacesRawValue.useDefault&&(e.decimalPlacesRawValue=e.decimalPlaces);var t=0;e.rawValueDivisor&&e.rawValueDivisor!==I.options.rawValueDivisor.none&&(t=String(e.rawValueDivisor).length-1)<0&&(t=0),e.decimalPlacesRawValue=Math.max(Math.max(e.decimalPlacesShownOnBlur,e.decimalPlacesShownOnFocus)+t,Number(e.originalDecimalPlacesRawValue)+t)}},{key:"_calculateDecimalPlacesOnUpdate",value:function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:null;this._validateDecimalPlacesRawValue(e),Er.isNull(t)&&Er.throwError("When updating the settings, the previous ones should be passed as an argument.");var n="decimalPlaces"in e;(n||"decimalPlacesRawValue"in e||"decimalPlacesShownOnFocus"in e||"decimalPlacesShownOnBlur"in e||"rawValueDivisor"in e)&&(n?("decimalPlacesShownOnFocus"in e&&e.decimalPlacesShownOnFocus!==I.options.decimalPlacesShownOnFocus.useDefault||(e.decimalPlacesShownOnFocus=e.decimalPlaces),"decimalPlacesShownOnBlur"in e&&e.decimalPlacesShownOnBlur!==I.options.decimalPlacesShownOnBlur.useDefault||(e.decimalPlacesShownOnBlur=e.decimalPlaces),"decimalPlacesRawValue"in e&&e.decimalPlacesRawValue!==I.options.decimalPlacesRawValue.useDefault||(e.decimalPlacesRawValue=e.decimalPlaces)):(Er.isUndefined(e.decimalPlacesShownOnFocus)&&(e.decimalPlacesShownOnFocus=t.decimalPlacesShownOnFocus),Er.isUndefined(e.decimalPlacesShownOnBlur)&&(e.decimalPlacesShownOnBlur=t.decimalPlacesShownOnBlur)),n=0,e.rawValueDivisor&&e.rawValueDivisor!==I.options.rawValueDivisor.none&&(n=String(e.rawValueDivisor).length-1)<0&&(n=0),e.decimalPlaces||e.decimalPlacesRawValue?e.decimalPlacesRawValue=Math.max(Math.max(e.decimalPlacesShownOnBlur,e.decimalPlacesShownOnFocus)+n,Number(e.decimalPlacesRawValue)+n):e.decimalPlacesRawValue=Math.max(Math.max(e.decimalPlacesShownOnBlur,e.decimalPlacesShownOnFocus)+n,Number(t.originalDecimalPlacesRawValue)+n))}},{key:"_cachesUsualRegularExpressions",value:function(e,t){var n=e.negativeSignCharacter!==I.options.negativeSignCharacter.hyphen?"([-\\".concat(e.negativeSignCharacter,"]?)"):"(-?)";t.aNegRegAutoStrip=n,e.allowedAutoStrip=new RegExp("[^-0123456789\\".concat(e.decimalCharacter,"]"),"g"),e.numRegAutoStrip=new RegExp("".concat(n,"(?:\\").concat(e.decimalCharacter,"?([0-9]+\\").concat(e.decimalCharacter,"[0-9]+)|([0-9]*(?:\\").concat(e.decimalCharacter,"[0-9]*)?))")),e.stripReg=new RegExp("^".concat(t.aNegRegAutoStrip,"0*([0-9])")),e.formulaChars=new RegExp("[0-9".concat(e.decimalCharacter,"+\\-*/() ]"))}},{key:"_convertOldOptionsToNewOnes",value:function(e){var t,n={aSep:"digitGroupSeparator",nSep:"showOnlyNumbersOnFocus",dGroup:"digitalGroupSpacing",aDec:"decimalCharacter",altDec:"decimalCharacterAlternative",aSign:"currencySymbol",pSign:"currencySymbolPlacement",pNeg:"negativePositiveSignPlacement",aSuffix:"suffixText",oLimits:"overrideMinMaxLimits",vMax:"maximumValue",vMin:"minimumValue",mDec:"decimalPlacesOverride",eDec:"decimalPlacesShownOnFocus",scaleDecimal:"decimalPlacesShownOnBlur",aStor:"saveValueToSessionStorage",mRound:"roundingMethod",aPad:"allowDecimalPadding",nBracket:"negativeBracketsTypeOnBlur",wEmpty:"emptyInputBehavior",lZero:"leadingZero",aForm:"formatOnPageLoad",sNumber:"selectNumberOnly",anDefault:"defaultValueOverride",unSetOnSubmit:"unformatOnSubmit",outputType:"outputFormat",debug:"showWarnings",allowDecimalPadding:!0,alwaysAllowDecimalCharacter:!0,caretPositionOnFocus:!0,createLocalList:!0,currencySymbol:!0,currencySymbolPlacement:!0,decimalCharacter:!0,decimalCharacterAlternative:!0,decimalPlaces:!0,decimalPlacesRawValue:!0,decimalPlacesShownOnBlur:!0,decimalPlacesShownOnFocus:!0,defaultValueOverride:!0,digitalGroupSpacing:!0,digitGroupSeparator:!0,divisorWhenUnfocused:!0,emptyInputBehavior:!0,eventBubbles:!0,eventIsCancelable:!0,failOnUnknownOption:!0,formatOnPageLoad:!0,formulaMode:!0,historySize:!0,isCancellable:!0,leadingZero:!0,maximumValue:!0,minimumValue:!0,modifyValueOnWheel:!0,negativeBracketsTypeOnBlur:!0,negativePositiveSignPlacement:!0,negativeSignCharacter:!0,noEventListeners:!0,onInvalidPaste:!0,outputFormat:!0,overrideMinMaxLimits:!0,positiveSignCharacter:!0,rawValueDivisor:!0,readOnly:!0,roundingMethod:!0,saveValueToSessionStorage:!0,selectNumberOnly:!0,selectOnFocus:!0,serializeSpaces:!0,showOnlyNumbersOnFocus:!0,showPositiveSign:!0,showWarnings:!0,styleRules:!0,suffixText:!0,symbolWhenUnfocused:!0,unformatOnHover:!0,unformatOnSubmit:!0,valuesToStrings:!0,watchExternalChanges:!0,wheelOn:!0,wheelStep:!0,allowedAutoStrip:!0,formulaChars:!0,isNegativeSignAllowed:!0,isPositiveSignAllowed:!0,mIntNeg:!0,mIntPos:!0,numRegAutoStrip:!0,originalDecimalPlaces:!0,originalDecimalPlacesRawValue:!0,stripReg:!0};for(t in e)Object.prototype.hasOwnProperty.call(e,t)&&!0!==n[t]&&(Object.prototype.hasOwnProperty.call(n,t)?(Er.warning("You are using the deprecated option name '".concat(t,"'. Please use '").concat(n[t],"' instead from now on. The old option name will be dropped very soon™."),!0),e[n[t]]=e[t],delete e[t]):e.failOnUnknownOption&&Er.throwError("Option name '".concat(t,"' is unknown. Please fix the options passed to autoNumeric")));"mDec"in e&&Er.warning("The old `mDec` option has been deprecated in favor of more accurate options ; `decimalPlaces`, `decimalPlacesRawValue`, `decimalPlacesShownOnFocus` and `decimalPlacesShownOnBlur`.",!0)}},{key:"_setNegativePositiveSignPermissions",value:function(e){e.isNegativeSignAllowed=e.minimumValue<0,e.isPositiveSignAllowed=0<=e.maximumValue}},{key:"_toNumericValue",value:function(e,t){var n;return Er.isNumber(Number(e))?n=Er.scientificToDecimal(e):(n=this._convertToNumericString(e.toString(),t),Er.isNumber(Number(n))||(Er.warning('The given value "'.concat(e,'" cannot be converted to a numeric one and therefore cannot be used appropriately.'),t.showWarnings),n=NaN)),n}},{key:"_checkIfInRange",value:function(e,t,n){e=Er.parseStr(e);return-1<Er.testMinMax(t,e)&&Er.testMinMax(n,e)<1}},{key:"_shouldSkipEventKey",value:function(e){var t=Er.isInArray(e,fr.keyName._allFnKeys),n=e===fr.keyName.OSLeft||e===fr.keyName.OSRight,i=e===fr.keyName.ContextMenu,r=Er.isInArray(e,fr.keyName._someNonPrintableKeys),o=e===fr.keyName.NumLock||e===fr.keyName.ScrollLock||e===fr.keyName.Insert||e===fr.keyName.Command,e=e===fr.keyName.Unidentified;return t||n||i||r||e||o}},{key:"_serialize",value:function(e){var t,i=this,r=1<arguments.length&&void 0!==arguments[1]&&arguments[1],o=2<arguments.length&&void 0!==arguments[2]?arguments[2]:"unformatted",n=3<arguments.length&&void 0!==arguments[3]?arguments[3]:"+",s=4<arguments.length&&void 0!==arguments[4]?arguments[4]:null,a=[];return"object"===zr(e)&&"form"===e.nodeName.toLowerCase()&&Array.prototype.slice.call(e.elements).forEach(function(t){if(t.name&&!t.disabled&&-1===["file","reset","submit","button"].indexOf(t.type))if("select-multiple"===t.type)Array.prototype.slice.call(t.options).forEach(function(e){e.selected&&(r?a.push({name:t.name,value:e.value}):a.push("".concat(encodeURIComponent(t.name),"=").concat(encodeURIComponent(e.value))))});else if(-1===["checkbox","radio"].indexOf(t.type)||t.checked){var e;if(i.isManagedByAutoNumeric(t))switch(o){case"unformatted":n=i.getAutoNumericElement(t),Er.isNull(n)||(e=i.unformat(t,n.getSettings()));break;case"localized":var n=i.getAutoNumericElement(t);Er.isNull(n)||(n=Er.cloneObject(n.getSettings()),Er.isNull(s)||(n.outputFormat=s),e=i.localize(t,n));break;case"formatted":default:e=t.value}else e=t.value;Er.isUndefined(e)&&Er.throwError("This error should never be hit. If it has, something really wrong happened!"),r?a.push({name:t.name,value:e}):a.push("".concat(encodeURIComponent(t.name),"=").concat(encodeURIComponent(e)))}}),r?t=a:(t=a.join("&"),"+"===n&&(t=t.replace(/%20/g,"+"))),t}},{key:"_serializeNumericString",value:function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:"+";return this._serialize(e,!1,"unformatted",t)}},{key:"_serializeFormatted",value:function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:"+";return this._serialize(e,!1,"formatted",t)}},{key:"_serializeLocalized",value:function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:"+",n=2<arguments.length&&void 0!==arguments[2]?arguments[2]:null;return this._serialize(e,!1,"localized",t,n)}},{key:"_serializeNumericStringArray",value:function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:"+";return this._serialize(e,!0,"unformatted",t)}},{key:"_serializeFormattedArray",value:function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:"+";return this._serialize(e,!0,"formatted",t)}},{key:"_serializeLocalizedArray",value:function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:"+",n=2<arguments.length&&void 0!==arguments[2]?arguments[2]:null;return this._serialize(e,!0,"localized",t,n)}}],(t=[{key:"_saveInitialValues",value:function(e){this.initialValueHtmlAttribute=Er.scientificToDecimal(this.domElement.getAttribute("value")),Er.isNull(this.initialValueHtmlAttribute)&&(this.initialValueHtmlAttribute=""),this.initialValue=e,Er.isNull(this.initialValue)&&(this.initialValue="")}},{key:"_createEventListeners",value:function(){var t=this;this.formulaMode=!1,this._onFocusInFunc=function(e){t._onFocusIn(e)},this._onFocusInAndMouseEnterFunc=function(e){t._onFocusInAndMouseEnter(e)},this._onFocusFunc=function(){t._onFocus()},this._onKeydownFunc=function(e){t._onKeydown(e)},this._onKeypressFunc=function(e){t._onKeypress(e)},this._onKeyupFunc=function(e){t._onKeyup(e)},this._onFocusOutAndMouseLeaveFunc=function(e){t._onFocusOutAndMouseLeave(e)},this._onPasteFunc=function(e){t._onPaste(e)},this._onWheelFunc=function(e){t._onWheel(e)},this._onDropFunc=function(e){t._onDrop(e)},this._onKeydownGlobalFunc=function(e){t._onKeydownGlobal(e)},this._onKeyupGlobalFunc=function(e){t._onKeyupGlobal(e)},this.domElement.addEventListener("focusin",this._onFocusInFunc,!1),this.domElement.addEventListener("focus",this._onFocusInAndMouseEnterFunc,!1),this.domElement.addEventListener("focus",this._onFocusFunc,!1),this.domElement.addEventListener("mouseenter",this._onFocusInAndMouseEnterFunc,!1),this.domElement.addEventListener("keydown",this._onKeydownFunc,!1),this.domElement.addEventListener("keypress",this._onKeypressFunc,!1),this.domElement.addEventListener("keyup",this._onKeyupFunc,!1),this.domElement.addEventListener("blur",this._onFocusOutAndMouseLeaveFunc,!1),this.domElement.addEventListener("mouseleave",this._onFocusOutAndMouseLeaveFunc,!1),this.domElement.addEventListener("paste",this._onPasteFunc,!1),this.domElement.addEventListener("wheel",this._onWheelFunc,!1),this.domElement.addEventListener("drop",this._onDropFunc,!1),this._setupFormListener(),this.hasEventListeners=!0,I._doesGlobalListExists()||(document.addEventListener("keydown",this._onKeydownGlobalFunc,!1),document.addEventListener("keyup",this._onKeyupGlobalFunc,!1))}},{key:"_removeEventListeners",value:function(){this.domElement.removeEventListener("focusin",this._onFocusInFunc,!1),this.domElement.removeEventListener("focus",this._onFocusInAndMouseEnterFunc,!1),this.domElement.removeEventListener("focus",this._onFocusFunc,!1),this.domElement.removeEventListener("mouseenter",this._onFocusInAndMouseEnterFunc,!1),this.domElement.removeEventListener("blur",this._onFocusOutAndMouseLeaveFunc,!1),this.domElement.removeEventListener("mouseleave",this._onFocusOutAndMouseLeaveFunc,!1),this.domElement.removeEventListener("keydown",this._onKeydownFunc,!1),this.domElement.removeEventListener("keypress",this._onKeypressFunc,!1),this.domElement.removeEventListener("keyup",this._onKeyupFunc,!1),this.domElement.removeEventListener("paste",this._onPasteFunc,!1),this.domElement.removeEventListener("wheel",this._onWheelFunc,!1),this.domElement.removeEventListener("drop",this._onDropFunc,!1),this._removeFormListener(),this.hasEventListeners=!1,document.removeEventListener("keydown",this._onKeydownGlobalFunc,!1),document.removeEventListener("keyup",this._onKeyupGlobalFunc,!1)}},{key:"_updateEventListeners",value:function(){this.settings.noEventListeners||this.hasEventListeners||this._createEventListeners(),this.settings.noEventListeners&&this.hasEventListeners&&this._removeEventListeners()}},{key:"_setupFormListener",value:function(){var e=this;Er.isNull(this.parentForm)||(this._onFormSubmitFunc=function(){e._onFormSubmit()},this._onFormResetFunc=function(){e._onFormReset()},this._hasParentFormCounter()?this._incrementParentFormCounter():(this._initializeFormCounterToOne(),this.parentForm.addEventListener("submit",this._onFormSubmitFunc,!1),this.parentForm.addEventListener("reset",this._onFormResetFunc,!1),this._storeFormHandlerFunction()))}},{key:"_removeFormListener",value:function(){var e;Er.isNull(this.parentForm)||(1===(e=this._getParentFormCounter())?(this.parentForm.removeEventListener("submit",this._getFormHandlerFunction().submitFn,!1),this.parentForm.removeEventListener("reset",this._getFormHandlerFunction().resetFn,!1),this._removeFormDataSetInfo()):1<e?this._decrementParentFormCounter():Er.throwError("The AutoNumeric object count on the form is incoherent."))}},{key:"_hasParentFormCounter",value:function(){return"anCount"in this.parentForm.dataset}},{key:"_getParentFormCounter",value:function(){return Number(this.parentForm.dataset.anCount)}},{key:"_initializeFormCounterToOne",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:null;this._getFormElement(e).dataset.anCount=1}},{key:"_incrementParentFormCounter",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:null;this._getFormElement(e).dataset.anCount++}},{key:"_decrementParentFormCounter",value:function(){this.parentForm.dataset.anCount--}},{key:"_hasFormHandlerFunction",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:null;return"anFormHandler"in this._getFormElement(e).dataset}},{key:"_getFormElement",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:null,e=Er.isNull(e)?this.parentForm:e;return e}},{key:"_storeFormHandlerFunction",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:null;this.constructor._doesFormHandlerListExists()||this.constructor._createFormHandlerList();var t=Er.randomString();this._getFormElement(e).dataset.anFormHandler=t,window.aNFormHandlerMap.set(t,{submitFn:this._onFormSubmitFunc,resetFn:this._onFormResetFunc})}},{key:"_getFormHandlerKey",value:function(){this._hasFormHandlerFunction()||Er.throwError("Unable to retrieve the form handler name");var e=this.parentForm.dataset.anFormHandler;return""===e&&Er.throwError("The form handler name is invalid"),e}},{key:"_getFormHandlerFunction",value:function(){var e=this._getFormHandlerKey();return window.aNFormHandlerMap.get(e)}},{key:"_removeFormDataSetInfo",value:function(){this._decrementParentFormCounter(),window.aNFormHandlerMap.delete(this._getFormHandlerKey()),this.parentForm.removeAttribute("data-an-count"),this.parentForm.removeAttribute("data-an-form-handler")}},{key:"_setWritePermissions",value:function(){0<arguments.length&&void 0!==arguments[0]&&arguments[0]&&this.domElement.readOnly||this.settings.readOnly?this._setReadOnly():this._setReadWrite()}},{key:"_setReadOnly",value:function(){this.isInputElement?this.domElement.readOnly=!0:this.domElement.setAttribute("contenteditable",!1)}},{key:"_setReadWrite",value:function(){this.isInputElement?this.domElement.readOnly=!1:this.domElement.setAttribute("contenteditable",!0)}},{key:"_addWatcher",value:function(){var e,t,n,i=this;Er.isUndefined(this.getterSetter)||(e=this.getterSetter,t=e.set,n=e.get,Object.defineProperty(this.domElement,this.attributeToWatch,{configurable:!0,get:function(){return n.call(i.domElement)},set:function(e){t.call(i.domElement,e),i.settings.watchExternalChanges&&!i.internalModification&&i.set(e)}}))}},{key:"_removeWatcher",value:function(){var e,t,n,i=this;Er.isUndefined(this.getterSetter)||(e=this.getterSetter,t=e.set,n=e.get,Object.defineProperty(this.domElement,this.attributeToWatch,{configurable:!0,get:function(){return n.call(i.domElement)},set:function(e){t.call(i.domElement,e)}}))}},{key:"_getAttributeToWatch",value:function(){var e,t;return this.isInputElement?e="value":(t=this.domElement.nodeType)===Node.ELEMENT_NODE||t===Node.DOCUMENT_NODE||t===Node.DOCUMENT_FRAGMENT_NODE?e="textContent":t===Node.TEXT_NODE&&(e="nodeValue"),e}},{key:"_historyTableAdd",value:function(){var e,t=0===this.historyTable.length;!t&&this.rawValue===this._historyTableCurrentValueUsed()||(e=!0,t||((t=this.historyTableIndex+1)<this.historyTable.length&&this.rawValue===this.historyTable[t].value?e=!1:Er.arrayTrim(this.historyTable,this.historyTableIndex+1)),this.historyTableIndex++,e&&(e=Er.getElementSelection(this.domElement),this.selectionStart=e.start,this.selectionEnd=e.end,this.historyTable.push({value:this.rawValue,start:this.selectionStart+1,end:this.selectionEnd+1}),1<this.historyTable.length&&(this.historyTable[this.historyTableIndex-1].start=this.selectionStart,this.historyTable[this.historyTableIndex-1].end=this.selectionEnd)),this.historyTable.length>this.settings.historySize&&this._historyTableForget())}},{key:"_historyTableUndoOrRedo",value:function(){var e;!(0<arguments.length&&void 0!==arguments[0])||arguments[0]?(e=0<this.historyTableIndex)&&this.historyTableIndex--:(e=this.historyTableIndex+1<this.historyTable.length)&&this.historyTableIndex++,e&&(e=this.historyTable[this.historyTableIndex],this.set(e.value,null,!1),Er.setElementSelection(this.domElement,e.start,e.end))}},{key:"_historyTableUndo",value:function(){this._historyTableUndoOrRedo(!0)}},{key:"_historyTableRedo",value:function(){this._historyTableUndoOrRedo(!1)}},{key:"_historyTableForget",value:function(){for(var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:1,t=[],n=0;n<e;n++)t.push(this.historyTable.shift()),this.historyTableIndex--,this.historyTableIndex<0&&(this.historyTableIndex=0);return 1===t.length?t[0]:t}},{key:"_historyTableCurrentValueUsed",value:function(){var e=this.historyTableIndex;return e<0&&(e=0),Er.isUndefinedOrNullOrEmpty(this.historyTable[e])?"":this.historyTable[e].value}},{key:"_parseStyleRules",value:function(){var i=this;Er.isUndefinedOrNullOrEmpty(this.settings.styleRules)||""===this.rawValue||(Er.isUndefinedOrNullOrEmpty(this.settings.styleRules.positive)||(0<=this.rawValue?this._addCSSClass(this.settings.styleRules.positive):this._removeCSSClass(this.settings.styleRules.positive)),Er.isUndefinedOrNullOrEmpty(this.settings.styleRules.negative)||(this.rawValue<0?this._addCSSClass(this.settings.styleRules.negative):this._removeCSSClass(this.settings.styleRules.negative)),Er.isUndefinedOrNullOrEmpty(this.settings.styleRules.ranges)||0===this.settings.styleRules.ranges.length||this.settings.styleRules.ranges.forEach(function(e){i.rawValue>=e.min&&i.rawValue<e.max?i._addCSSClass(e.class):i._removeCSSClass(e.class)}),Er.isUndefinedOrNullOrEmpty(this.settings.styleRules.userDefined)||0===this.settings.styleRules.userDefined.length||this.settings.styleRules.userDefined.forEach(function(e){var n;Er.isFunction(e.callback)?Er.isString(e.classes)?e.callback(i.rawValue)?i._addCSSClass(e.classes):i._removeCSSClass(e.classes):Er.isArray(e.classes)?2===e.classes.length?e.callback(i.rawValue)?(i._addCSSClass(e.classes[0]),i._removeCSSClass(e.classes[1])):(i._removeCSSClass(e.classes[0]),i._addCSSClass(e.classes[1])):2<e.classes.length?(n=e.callback(i.rawValue),Er.isArray(n)?e.classes.forEach(function(e,t){Er.isInArray(t,n)?i._addCSSClass(e):i._removeCSSClass(e)}):Er.isInt(n)?e.classes.forEach(function(e,t){t===n?i._addCSSClass(e):i._removeCSSClass(e)}):Er.isNull(n)?e.classes.forEach(function(e){i._removeCSSClass(e)}):Er.throwError("The callback result is not an array nor a valid array index, ".concat(zr(n)," given."))):Er.throwError("The classes attribute is not valid for the `styleRules` option."):Er.isUndefinedOrNullOrEmpty(e.classes)?e.callback(i):Er.throwError("The callback/classes structure is not valid for the `styleRules` option."):Er.warning("The given `styleRules` callback is not a function, ".concat("undefined"==typeof callback?"undefined":zr(callback)," given."),i.settings.showWarnings)}))}},{key:"_addCSSClass",value:function(e){this.domElement.classList.add(e)}},{key:"_removeCSSClass",value:function(e){this.domElement.classList.remove(e)}},{key:"update",value:function(){for(var t=this,e=arguments.length,n=new Array(e),i=0;i<e;i++)n[i]=arguments[i];Array.isArray(n)&&Array.isArray(n[0])&&(n=n[0]);var r=Er.cloneObject(this.settings),o=this.rawValue,s={};Er.isUndefinedOrNullOrEmpty(n)||0===n.length?s=null:1<=n.length&&n.forEach(function(e){t.constructor._isPreDefinedOptionValid(e)&&(e=t.constructor._getOptionObject(e)),Object.assign(s,e)});try{this._setSettings(s,!0),this._setWritePermissions(),this._updateEventListeners(),this.set(o)}catch(e){return this._setSettings(r,!0),Er.throwError("Unable to update the settings, those are invalid: [".concat(e,"]")),this}return this}},{key:"getSettings",value:function(){return this.settings}},{key:"set",value:function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:null,n=!(2<arguments.length&&void 0!==arguments[2])||arguments[2];if(Er.isUndefined(e))return Er.warning("You are trying to set an 'undefined' value ; an error could have occurred.",this.settings.showWarnings),this;if(Er.isNull(t)||this._setSettings(t,!0),null===e&&this.settings.emptyInputBehavior!==I.options.emptyInputBehavior.null)return Er.warning("You are trying to set the `null` value while the `emptyInputBehavior` option is set to ".concat(this.settings.emptyInputBehavior,". If you want to be able to set the `null` value, you need to change the 'emptyInputBehavior' option to `'null'`."),this.settings.showWarnings),this;if(null===e)return this._setElementAndRawValue(null,null,n),this._saveValueToPersistentStorage(),this;if(r=this.constructor._toNumericValue(e,this.settings),isNaN(Number(r)))return Er.warning("The value you are trying to set results in `NaN`. The element value is set to the empty string instead.",this.settings.showWarnings),this.setValue("",n),this;if(""===r)switch(this.settings.emptyInputBehavior){case I.options.emptyInputBehavior.zero:r=0;break;case I.options.emptyInputBehavior.min:r=this.settings.minimumValue;break;case I.options.emptyInputBehavior.max:r=this.settings.maximumValue;break;default:Er.isNumber(this.settings.emptyInputBehavior)&&(r=Number(this.settings.emptyInputBehavior))}if(""!==r){var t=Vr(this.constructor._checkIfInRangeWithOverrideOption(r,this.settings),2),e=t[0],i=t[1];if(e&&i&&this.settings.valuesToStrings&&this._checkValuesToStrings(r))return this._setElementAndRawValue(this.settings.valuesToStrings[r],r,n),this._saveValueToPersistentStorage(),this;if(Er.isZeroOrHasNoValue(r)&&(r="0"),e&&i){var t=this.constructor._roundRawValue(r,this.settings),t=this._trimLeadingAndTrailingZeros(t.replace(this.settings.decimalCharacter,".")),r=this._getRawValueToFormat(r);return r=this.isFocused?this.constructor._roundFormattedValueShownOnFocus(r,this.settings):(this.settings.divisorWhenUnfocused&&(r=(r/=this.settings.divisorWhenUnfocused).toString()),this.constructor._roundFormattedValueShownOnBlur(r,this.settings)),r=this.constructor._modifyNegativeSignAndDecimalCharacterForFormattedValue(r,this.settings),r=this.constructor._addGroupSeparators(r,this.settings,this.isFocused,this.rawValue,t),!this.isFocused&&this.settings.symbolWhenUnfocused&&(r="".concat(r).concat(this.settings.symbolWhenUnfocused)),(this.settings.decimalPlacesShownOnFocus||this.settings.divisorWhenUnfocused)&&this._saveValueToPersistentStorage(),this._setElementAndRawValue(r,t,n),this._setValidOrInvalidState(t),this}return this._triggerRangeEvents(e,i),Er.throwError("The value [".concat(r,"] being set falls outside of the minimumValue [").concat(this.settings.minimumValue,"] and maximumValue [").concat(this.settings.maximumValue,"] range set for this element")),this._removeValueFromPersistentStorage(),this.setValue("",n),this}i=this.settings.emptyInputBehavior===I.options.emptyInputBehavior.always?this.settings.currencySymbol:"";return this._setElementAndRawValue(i,"",n),this}},{key:"setUnformatted",value:function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:null;if(null===e||Er.isUndefined(e))return this;Er.isNull(t)||this._setSettings(t,!0);t=this.constructor._removeBrackets(e,this.settings),t=this.constructor._stripAllNonNumberCharacters(t,this.settings,!0,this.isFocused);return Er.isNumber(t)||Er.throwError("The value is not a valid one, it's not a numeric string nor a recognized currency."),this.constructor._isWithinRangeWithOverrideOption(t,this.settings)?this.setValue(e):Er.throwError("The value is out of the range limits [".concat(this.settings.minimumValue,", ").concat(this.settings.maximumValue,"].")),this}},{key:"setValue",value:function(e){var t=!(1<arguments.length&&void 0!==arguments[1])||arguments[1];return this._setElementAndRawValue(e,t),this}},{key:"_setRawValue",value:function(e){var t,n=!(1<arguments.length&&void 0!==arguments[1])||arguments[1];this.rawValue!==e&&(t=this.rawValue,this.rawValue=e,!Er.isNull(this.settings.rawValueDivisor)&&0!==this.settings.rawValueDivisor&&""!==e&&null!==e&&this._isUserManuallyEditingTheValue()&&(this.rawValue/=this.settings.rawValueDivisor),this._triggerEvent(I.events.rawValueModified,this.domElement,{oldRawValue:t,newRawValue:this.rawValue,isPristine:this.isPristine(!0),error:null,aNElement:this}),this._parseStyleRules(),n&&this._historyTableAdd())}},{key:"_setElementValue",value:function(e){var t=!(1<arguments.length&&void 0!==arguments[1])||arguments[1],n=Er.getElementValue(this.domElement);return e!==n&&(this.internalModification=!0,Er.setElementValue(this.domElement,e),this.internalModification=!1,t&&this._triggerEvent(I.events.formatted,this.domElement,{oldValue:n,newValue:e,oldRawValue:this.rawValue,newRawValue:this.rawValue,isPristine:this.isPristine(!1),error:null,aNElement:this})),this}},{key:"_setElementAndRawValue",value:function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:null,n=!(2<arguments.length&&void 0!==arguments[2])||arguments[2];return Er.isNull(t)?t=e:Er.isBoolean(t)&&(n=t,t=e),this._setElementValue(e),this._setRawValue(t,n),this}},{key:"_getRawValueToFormat",value:function(e){e=Er.isNull(this.settings.rawValueDivisor)||0===this.settings.rawValueDivisor||""===e||null===e?e:e*this.settings.rawValueDivisor;return e}},{key:"_checkValuesToStrings",value:function(e){return this.constructor._checkValuesToStringsArray(e,this.valuesToStringsKeys)}},{key:"_isUserManuallyEditingTheValue",value:function(){return this.isFocused&&this.isEditing||this.isDropEvent}},{key:"_executeCallback",value:function(e,t){!Er.isNull(t)&&Er.isFunction(t)&&t(e,this)}},{key:"_triggerEvent",value:function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:document,n=2<arguments.length&&void 0!==arguments[2]?arguments[2]:null;Er.triggerEvent(e,t,n,this.settings.eventBubbles,this.settings.eventIsCancelable)}},{key:"get",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:null;return this.getNumericString(e)}},{key:"getNumericString",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:null,t=Er.isNull(this.rawValue)?null:Er.trimPaddedZerosFromDecimalPlaces(this.rawValue);return this._executeCallback(t,e),t}},{key:"getFormatted",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:null;"value"in this.domElement||"textContent"in this.domElement||Er.throwError("Unable to get the formatted string from the element.");var t=Er.getElementValue(this.domElement);return this._executeCallback(t,e),t}},{key:"getNumber",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:null,t=null===this.rawValue?null:this.constructor._toLocale(this.getNumericString(),"number",this.settings);return this._executeCallback(t,e),t}},{key:"getLocalized",value:function(){var e,t=0<arguments.length&&void 0!==arguments[0]?arguments[0]:null,n=1<arguments.length&&void 0!==arguments[1]?arguments[1]:null;Er.isFunction(t)&&Er.isNull(n)&&(n=t,t=null),""!==(e=Er.isEmptyString(this.rawValue)?"":""+Number(this.rawValue))&&0===Number(e)&&this.settings.leadingZero!==I.options.leadingZero.keep&&(e="0"),t=Er.isNull(t)?this.settings.outputFormat:t;t=this.constructor._toLocale(e,t,this.settings);return this._executeCallback(t,n),t}},{key:"reformat",value:function(){return this.set(this.rawValue),this}},{key:"unformat",value:function(){return this._setElementValue(this.getNumericString()),this}},{key:"unformatLocalized",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:null;return this._setElementValue(this.getLocalized(e)),this}},{key:"isPristine",value:function(){var e=!(0<arguments.length&&void 0!==arguments[0])||arguments[0]?this.initialValue===this.getNumericString():this.initialValueHtmlAttribute===this.getFormatted();return e}},{key:"select",value:function(){return this.settings.selectNumberOnly?this.selectNumber():this._defaultSelectAll(),this}},{key:"_defaultSelectAll",value:function(){Er.setElementSelection(this.domElement,0,Er.getElementValue(this.domElement).length)}},{key:"selectNumber",value:function(){var e,t=Er.getElementValue(this.domElement),n=t.length,i=this.settings.currencySymbol.length,r=this.settings.currencySymbolPlacement,o=Er.isNegative(t,this.settings.negativeSignCharacter)?1:0,s=this.settings.suffixText.length,t=r===I.options.currencySymbolPlacement.suffix?0:this.settings.negativePositiveSignPlacement===I.options.negativePositiveSignPlacement.left&&1==o&&0<i?i+1:i;if(r===I.options.currencySymbolPlacement.prefix)e=n-s;else switch(this.settings.negativePositiveSignPlacement){case I.options.negativePositiveSignPlacement.left:e=n-(s+i);break;case I.options.negativePositiveSignPlacement.right:e=0<i?n-(i+o+s):n-(i+s);break;default:e=n-(i+s)}return Er.setElementSelection(this.domElement,t,e),this}},{key:"selectInteger",value:function(){var e=0,t=0<=this.rawValue;this.settings.currencySymbolPlacement!==I.options.currencySymbolPlacement.prefix&&(this.settings.currencySymbolPlacement!==I.options.currencySymbolPlacement.suffix||this.settings.negativePositiveSignPlacement!==I.options.negativePositiveSignPlacement.prefix&&this.settings.negativePositiveSignPlacement!==I.options.negativePositiveSignPlacement.none)||(this.settings.showPositiveSign&&t||!t&&this.settings.currencySymbolPlacement===I.options.currencySymbolPlacement.prefix&&this.settings.negativePositiveSignPlacement===I.options.negativePositiveSignPlacement.left)&&(e+=1),this.settings.currencySymbolPlacement===I.options.currencySymbolPlacement.prefix&&(e+=this.settings.currencySymbol.length);var n=Er.getElementValue(this.domElement),i=n.indexOf(this.settings.decimalCharacter);return-1===i&&(i=this.settings.currencySymbolPlacement===I.options.currencySymbolPlacement.suffix?n.length-this.settings.currencySymbol.length:n.length,t||this.settings.negativePositiveSignPlacement!==I.options.negativePositiveSignPlacement.suffix&&this.settings.currencySymbolPlacement!==I.options.currencySymbolPlacement.suffix||(i-=1),i-=this.settings.suffixText.length),Er.setElementSelection(this.domElement,e,i),this}},{key:"selectDecimal",value:function(){var e=Er.getElementValue(this.domElement).indexOf(this.settings.decimalCharacter),t=-1===e?e=0:(e+=1,t=this.isFocused?this.settings.decimalPlacesShownOnFocus:this.settings.decimalPlacesShownOnBlur,e+Number(t));return Er.setElementSelection(this.domElement,e,t),this}},{key:"node",value:function(){return this.domElement}},{key:"parent",value:function(){return this.domElement.parentNode}},{key:"detach",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:null,e=Er.isNull(e)?this.domElement:e.node();return this._removeFromLocalList(e),this}},{key:"attach",value:function(e){var t=!(1<arguments.length&&void 0!==arguments[1])||arguments[1];return this._addToLocalList(e.node()),t&&e.update(this.settings),this}},{key:"formatOther",value:function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:null;return this._formatOrUnformatOther(!0,e,t)}},{key:"unformatOther",value:function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:null;return this._formatOrUnformatOther(!1,e,t)}},{key:"_formatOrUnformatOther",value:function(e,t){var n=2<arguments.length&&void 0!==arguments[2]?arguments[2]:null,n=Er.isNull(n)?this.settings:this._cloneAndMergeSettings(n);if(Er.isElement(t)){var i=Er.getElementValue(t),i=e?I.format(i,n):I.unformat(i,n);return Er.setElementValue(t,i),null}return i=e?I.format(t,n):I.unformat(t,n)}},{key:"init",value:function(e){var i=this,r=!(1<arguments.length&&void 0!==arguments[1])||arguments[1],t=!1,n=[];if(Er.isString(e)?n=Lr(document.querySelectorAll(e)):Er.isElement(e)?(n.push(e),t=!0):Er.isArray(e)?n=e:Er.throwError("The given parameters to the 'init' function are invalid."),0===n.length)return Er.warning("No valid DOM elements were given hence no AutoNumeric object were instantiated.",!0),[];var o=this._getLocalList(),s=[];return n.forEach(function(e){var t=i.settings.createLocalList;r&&(i.settings.createLocalList=!1);var n=new I(e,Er.getElementValue(e),i.settings);r&&(n._setLocalList(o),i._addToLocalList(e,n),i.settings.createLocalList=t),s.push(n)}),t?s[0]:s}},{key:"clear",value:function(){var e;return 0<arguments.length&&void 0!==arguments[0]&&arguments[0]?(e={emptyInputBehavior:I.options.emptyInputBehavior.focus},this.set("",e)):this.set(""),this}},{key:"remove",value:function(){this._removeValueFromPersistentStorage(),this._removeEventListeners(),this._removeWatcher(),this._removeFromLocalList(this.domElement),this.constructor._removeFromGlobalList(this)}},{key:"wipe",value:function(){this._setElementValue("",!1),this.remove()}},{key:"nuke",value:function(){this.remove(),this.domElement.parentNode.removeChild(this.domElement)}},{key:"form",value:function(){var e,t;return(0<arguments.length&&void 0!==arguments[0]&&arguments[0]||Er.isUndefinedOrNullOrEmpty(this.parentForm))&&(e=this._getParentForm(),Er.isNull(e)||e===this.parentForm||(t=this._getFormAutoNumericChildren(this.parentForm),this.parentForm.dataset.anCount=t.length,this._hasFormHandlerFunction(e)?this._incrementParentFormCounter(e):(this._storeFormHandlerFunction(e),this._initializeFormCounterToOne(e))),this.parentForm=e),this.parentForm}},{key:"_getFormAutoNumericChildren",value:function(e){var t=this;return Lr(e.querySelectorAll("input")).filter(function(e){return t.constructor.isManagedByAutoNumeric(e)})}},{key:"_getParentForm",value:function(){if("body"===this.domElement.tagName.toLowerCase())return null;var e,t=this.domElement;do{if(t=t.parentNode,Er.isNull(t))return null}while("body"!==(e=t.tagName?t.tagName.toLowerCase():"")&&"form"!==e);return"form"===e?t:null}},{key:"formNumericString",value:function(){return this.constructor._serializeNumericString(this.form(),this.settings.serializeSpaces)}},{key:"formFormatted",value:function(){return this.constructor._serializeFormatted(this.form(),this.settings.serializeSpaces)}},{key:"formLocalized",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:null,e=Er.isNull(e)?this.settings.outputFormat:e;return this.constructor._serializeLocalized(this.form(),this.settings.serializeSpaces,e)}},{key:"formArrayNumericString",value:function(){return this.constructor._serializeNumericStringArray(this.form(),this.settings.serializeSpaces)}},{key:"formArrayFormatted",value:function(){return this.constructor._serializeFormattedArray(this.form(),this.settings.serializeSpaces)}},{key:"formArrayLocalized",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:null,e=Er.isNull(e)?this.settings.outputFormat:e;return this.constructor._serializeLocalizedArray(this.form(),this.settings.serializeSpaces,e)}},{key:"formJsonNumericString",value:function(){return JSON.stringify(this.formArrayNumericString())}},{key:"formJsonFormatted",value:function(){return JSON.stringify(this.formArrayFormatted())}},{key:"formJsonLocalized",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:null;return JSON.stringify(this.formArrayLocalized(e))}},{key:"formUnformat",value:function(){return this.constructor._getChildANInputElement(this.form()).forEach(function(e){I.getAutoNumericElement(e).unformat()}),this}},{key:"formUnformatLocalized",value:function(){return this.constructor._getChildANInputElement(this.form()).forEach(function(e){I.getAutoNumericElement(e).unformatLocalized()}),this}},{key:"formReformat",value:function(){return this.constructor._getChildANInputElement(this.form()).forEach(function(e){I.getAutoNumericElement(e).reformat()}),this}},{key:"formSubmitNumericString",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:null;return Er.isNull(e)?(this.formUnformat(),this.form().submit(),this.formReformat()):Er.isFunction(e)?e(this.formNumericString()):Er.throwError("The given callback is not a function."),this}},{key:"formSubmitFormatted",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:null;return Er.isNull(e)?this.form().submit():Er.isFunction(e)?e(this.formFormatted()):Er.throwError("The given callback is not a function."),this}},{key:"formSubmitLocalized",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:null,t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:null;return Er.isNull(t)?(this.formUnformatLocalized(),this.form().submit(),this.formReformat()):Er.isFunction(t)?t(this.formLocalized(e)):Er.throwError("The given callback is not a function."),this}},{key:"formSubmitArrayNumericString",value:function(e){return Er.isFunction(e)?e(this.formArrayNumericString()):Er.throwError("The given callback is not a function."),this}},{key:"formSubmitArrayFormatted",value:function(e){return Er.isFunction(e)?e(this.formArrayFormatted()):Er.throwError("The given callback is not a function."),this}},{key:"formSubmitArrayLocalized",value:function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:null;return Er.isFunction(e)?e(this.formArrayLocalized(t)):Er.throwError("The given callback is not a function."),this}},{key:"formSubmitJsonNumericString",value:function(e){return Er.isFunction(e)?e(this.formJsonNumericString()):Er.throwError("The given callback is not a function."),this}},{key:"formSubmitJsonFormatted",value:function(e){return Er.isFunction(e)?e(this.formJsonFormatted()):Er.throwError("The given callback is not a function."),this}},{key:"formSubmitJsonLocalized",value:function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:null;return Er.isFunction(e)?e(this.formJsonLocalized(t)):Er.throwError("The given callback is not a function."),this}},{key:"_createLocalList",value:function(){this.autoNumericLocalList=new Map,this._addToLocalList(this.domElement)}},{key:"_deleteLocalList",value:function(){delete this.autoNumericLocalList}},{key:"_setLocalList",value:function(e){this.autoNumericLocalList=e}},{key:"_getLocalList",value:function(){return this.autoNumericLocalList}},{key:"_hasLocalList",value:function(){return this.autoNumericLocalList instanceof Map&&0!==this.autoNumericLocalList.size}},{key:"_addToLocalList",value:function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:null;Er.isNull(t)&&(t=this),Er.isUndefined(this.autoNumericLocalList)?Er.throwError("The local list provided does not exists when trying to add an element. [".concat(this.autoNumericLocalList,"] given.")):this.autoNumericLocalList.set(e,t)}},{key:"_removeFromLocalList",value:function(e){Er.isUndefined(this.autoNumericLocalList)?this.settings.createLocalList&&Er.throwError("The local list provided does not exists when trying to remove an element. [".concat(this.autoNumericLocalList,"] given.")):this.autoNumericLocalList.delete(e)}},{key:"_mergeSettings",value:function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];Object.assign.apply(Object,[this.settings].concat(t))}},{key:"_cloneAndMergeSettings",value:function(){for(var e={},t=arguments.length,n=new Array(t),i=0;i<t;i++)n[i]=arguments[i];return Object.assign.apply(Object,[e,this.settings].concat(n)),e}},{key:"_updatePredefinedOptions",value:function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:null;return Er.isNull(t)?this.update(e):(this._mergeSettings(e,t),this.update(this.settings)),this}},{key:"french",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:null;return this._updatePredefinedOptions(I.getPredefinedOptions().French,e),this}},{key:"northAmerican",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:null;return this._updatePredefinedOptions(I.getPredefinedOptions().NorthAmerican,e),this}},{key:"british",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:null;return this._updatePredefinedOptions(I.getPredefinedOptions().British,e),this}},{key:"swiss",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:null;return this._updatePredefinedOptions(I.getPredefinedOptions().Swiss,e),this}},{key:"japanese",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:null;return this._updatePredefinedOptions(I.getPredefinedOptions().Japanese,e),this}},{key:"spanish",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:null;return this._updatePredefinedOptions(I.getPredefinedOptions().Spanish,e),this}},{key:"chinese",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:null;return this._updatePredefinedOptions(I.getPredefinedOptions().Chinese,e),this}},{key:"brazilian",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:null;return this._updatePredefinedOptions(I.getPredefinedOptions().Brazilian,e),this}},{key:"_runCallbacksFoundInTheSettingsObject",value:function(){for(var e in this.settings){var t;Object.prototype.hasOwnProperty.call(this.settings,e)&&("function"==typeof(t=this.settings[e])?this.settings[e]=t(this,e):(t=this.domElement.getAttribute(e),t=Er.camelize(t),"function"==typeof this.settings[t]&&(this.settings[e]=t(this,e))))}}},{key:"_setTrailingNegativeSignInfo",value:function(){this.isTrailingNegative=this.settings.currencySymbolPlacement===I.options.currencySymbolPlacement.prefix&&this.settings.negativePositiveSignPlacement===I.options.negativePositiveSignPlacement.suffix||this.settings.currencySymbolPlacement===I.options.currencySymbolPlacement.suffix&&(this.settings.negativePositiveSignPlacement===I.options.negativePositiveSignPlacement.left||this.settings.negativePositiveSignPlacement===I.options.negativePositiveSignPlacement.right)}},{key:"_modifyNegativeSignAndDecimalCharacterForRawValue",value:function(e){return"."!==this.settings.decimalCharacter&&(e=e.replace(this.settings.decimalCharacter,".")),(e="-"!==this.settings.negativeSignCharacter&&this.settings.isNegativeSignAllowed?e.replace(this.settings.negativeSignCharacter,"-"):e).match(/\d/)||(e+="0"),e}},{key:"_initialCaretPosition",value:function(e){Er.isNull(this.settings.caretPositionOnFocus)&&this.settings.selectOnFocus===I.options.selectOnFocus.doNotSelect&&Er.throwError("`_initialCaretPosition()` should never be called when the `caretPositionOnFocus` option is `null`.");var t,n=this.rawValue<0,i=Er.isZeroOrHasNoValue(e),r=e.length,o=0,s=0,a=0;this.settings.caretPositionOnFocus!==I.options.caretPositionOnFocus.start&&(o=(e=(e=(e=e.replace(this.settings.negativeSignCharacter,"")).replace(this.settings.positiveSignCharacter,"")).replace(this.settings.currencySymbol,"")).length,t=Er.contains(e,this.settings.decimalCharacter),this.settings.caretPositionOnFocus!==I.options.caretPositionOnFocus.decimalLeft&&this.settings.caretPositionOnFocus!==I.options.caretPositionOnFocus.decimalRight||(a=t?(s=e.indexOf(this.settings.decimalCharacter),this.settings.decimalCharacter.length):(s=o,0)));e="";n?e=this.settings.negativeSignCharacter:this.settings.showPositiveSign&&!i&&(e=this.settings.positiveSignCharacter);var l,c=e.length,u=this.settings.currencySymbol.length;if(this.settings.currencySymbolPlacement===I.options.currencySymbolPlacement.prefix){if(this.settings.caretPositionOnFocus===I.options.caretPositionOnFocus.start)if(this.settings.negativePositiveSignPlacement!==I.options.negativePositiveSignPlacement.none&&(n||!n&&this.settings.showPositiveSign&&!i))switch(this.settings.negativePositiveSignPlacement){case I.options.negativePositiveSignPlacement.prefix:case I.options.negativePositiveSignPlacement.left:case I.options.negativePositiveSignPlacement.right:l=c+u;break;case I.options.negativePositiveSignPlacement.suffix:l=u}else l=u;else if(this.settings.caretPositionOnFocus===I.options.caretPositionOnFocus.end)if(this.settings.negativePositiveSignPlacement!==I.options.negativePositiveSignPlacement.none&&(n||!n&&this.settings.showPositiveSign&&!i))switch(this.settings.negativePositiveSignPlacement){case I.options.negativePositiveSignPlacement.prefix:case I.options.negativePositiveSignPlacement.left:case I.options.negativePositiveSignPlacement.right:l=r;break;case I.options.negativePositiveSignPlacement.suffix:l=u+o}else l=r;else if(this.settings.caretPositionOnFocus===I.options.caretPositionOnFocus.decimalLeft)if(this.settings.negativePositiveSignPlacement!==I.options.negativePositiveSignPlacement.none&&(n||!n&&this.settings.showPositiveSign&&!i))switch(this.settings.negativePositiveSignPlacement){case I.options.negativePositiveSignPlacement.prefix:case I.options.negativePositiveSignPlacement.left:case I.options.negativePositiveSignPlacement.right:l=c+u+s;break;case I.options.negativePositiveSignPlacement.suffix:l=u+s}else l=u+s;else if(this.settings.caretPositionOnFocus===I.options.caretPositionOnFocus.decimalRight)if(this.settings.negativePositiveSignPlacement!==I.options.negativePositiveSignPlacement.none&&(n||!n&&this.settings.showPositiveSign&&!i))switch(this.settings.negativePositiveSignPlacement){case I.options.negativePositiveSignPlacement.prefix:case I.options.negativePositiveSignPlacement.left:case I.options.negativePositiveSignPlacement.right:l=c+u+s+a;break;case I.options.negativePositiveSignPlacement.suffix:l=u+s+a}else l=u+s+a}else if(this.settings.currencySymbolPlacement===I.options.currencySymbolPlacement.suffix)if(this.settings.caretPositionOnFocus===I.options.caretPositionOnFocus.start)if(this.settings.negativePositiveSignPlacement!==I.options.negativePositiveSignPlacement.none&&(n||!n&&this.settings.showPositiveSign&&!i))switch(this.settings.negativePositiveSignPlacement){case I.options.negativePositiveSignPlacement.suffix:case I.options.negativePositiveSignPlacement.right:case I.options.negativePositiveSignPlacement.left:l=0;break;case I.options.negativePositiveSignPlacement.prefix:l=c}else l=0;else if(this.settings.caretPositionOnFocus===I.options.caretPositionOnFocus.end)if(this.settings.negativePositiveSignPlacement!==I.options.negativePositiveSignPlacement.none&&(n||!n&&this.settings.showPositiveSign&&!i))switch(this.settings.negativePositiveSignPlacement){case I.options.negativePositiveSignPlacement.suffix:case I.options.negativePositiveSignPlacement.right:case I.options.negativePositiveSignPlacement.left:l=o;break;case I.options.negativePositiveSignPlacement.prefix:l=c+o}else l=o;else if(this.settings.caretPositionOnFocus===I.options.caretPositionOnFocus.decimalLeft)if(this.settings.negativePositiveSignPlacement!==I.options.negativePositiveSignPlacement.none&&(n||!n&&this.settings.showPositiveSign&&!i))switch(this.settings.negativePositiveSignPlacement){case I.options.negativePositiveSignPlacement.suffix:case I.options.negativePositiveSignPlacement.right:case I.options.negativePositiveSignPlacement.left:l=s;break;case I.options.negativePositiveSignPlacement.prefix:l=c+s}else l=s;else if(this.settings.caretPositionOnFocus===I.options.caretPositionOnFocus.decimalRight)if(this.settings.negativePositiveSignPlacement!==I.options.negativePositiveSignPlacement.none&&(n||!n&&this.settings.showPositiveSign&&!i))switch(this.settings.negativePositiveSignPlacement){case I.options.negativePositiveSignPlacement.suffix:case I.options.negativePositiveSignPlacement.right:case I.options.negativePositiveSignPlacement.left:l=s+a;break;case I.options.negativePositiveSignPlacement.prefix:l=c+s+a}else l=s+a;return l}},{key:"_triggerRangeEvents",value:function(e,t){e||this._triggerEvent(I.events.minRangeExceeded,this.domElement),t||this._triggerEvent(I.events.maxRangeExceeded,this.domElement)}},{key:"_setInvalidState",value:function(){this.isInputElement?Er.setInvalidState(this.domElement):this._addCSSClass(this.settings.invalidClass),this._triggerEvent(I.events.invalidValue,this.domElement),this.validState=!1}},{key:"_setValidState",value:function(){this.isInputElement?Er.setValidState(this.domElement):this._removeCSSClass(this.settings.invalidClass),this.validState||this._triggerEvent(I.events.correctedValue,this.domElement),this.validState=!0}},{key:"_setValidOrInvalidState",value:function(e){var t;this.settings.overrideMinMaxLimits===I.options.overrideMinMaxLimits.invalid&&(t=this.constructor._isMinimumRangeRespected(e,this.settings),e=this.constructor._isMaximumRangeRespected(e,this.settings),t&&e?this._setValidState():this._setInvalidState(),this._triggerRangeEvents(t,e))}},{key:"_keepAnOriginalSettingsCopy",value:function(){this.originalDigitGroupSeparator=this.settings.digitGroupSeparator,this.originalCurrencySymbol=this.settings.currencySymbol,this.originalSuffixText=this.settings.suffixText}},{key:"_trimLeadingAndTrailingZeros",value:function(e){if(""===e||null===e)return e;if(this.settings.leadingZero!==I.options.leadingZero.keep){if(0===Number(e))return"0";e=e.replace(/^(-)?0+(?=\d)/g,"$1")}return e=(e=Er.contains(e,".")?e.replace(/(\.[0-9]*?)0+$/,"$1"):e).replace(/\.$/,"")}},{key:"_setPersistentStorageName",value:function(){this.settings.saveValueToSessionStorage&&(""===this.domElement.name||Er.isUndefined(this.domElement.name)?this.rawValueStorageName="".concat(this.storageNamePrefix).concat(this.domElement.id):this.rawValueStorageName="".concat(this.storageNamePrefix).concat(decodeURIComponent(this.domElement.name)))}},{key:"_saveValueToPersistentStorage",value:function(){this.settings.saveValueToSessionStorage&&(this.sessionStorageAvailable?sessionStorage.setItem(this.rawValueStorageName,this.rawValue):document.cookie="".concat(this.rawValueStorageName,"=").concat(this.rawValue,"; expires= ; path=/"))}},{key:"_getValueFromPersistentStorage",value:function(){if(this.settings.saveValueToSessionStorage){var e=this.sessionStorageAvailable?sessionStorage.getItem(this.rawValueStorageName):this.constructor._readCookie(this.rawValueStorageName);return e}return Er.warning("`_getValueFromPersistentStorage()` is called but `settings.saveValueToSessionStorage` is false. There must be an error that needs fixing.",this.settings.showWarnings),null}},{key:"_removeValueFromPersistentStorage",value:function(){var e;this.settings.saveValueToSessionStorage&&(this.sessionStorageAvailable?sessionStorage.removeItem(this.rawValueStorageName):((e=new Date).setTime(e.getTime()-864e5),e="; expires=".concat(e.toUTCString()),document.cookie="".concat(this.rawValueStorageName,"='' ;").concat(e,"; path=/")))}},{key:"_getDefaultValue",value:function(e){e=e.getAttribute("value");return Er.isNull(e)?"":e}},{key:"_onFocusInAndMouseEnter",value:function(e){var t,n,i;this.isEditing=!1,!this.formulaMode&&this.settings.unformatOnHover&&"mouseenter"===e.type&&e.altKey?this.constructor._unformatAltHovered(this):("focus"===e.type&&(this.isFocused=!0,this.rawValueOnFocus=this.rawValue),"focus"===e.type&&this.settings.unformatOnHover&&this.hoveredWithAlt&&this.constructor._reformatAltHovered(this),"focus"!==e.type&&("mouseenter"!==e.type||this.isFocused)||(t=null,this.settings.emptyInputBehavior===I.options.emptyInputBehavior.focus&&this.rawValue<0&&null!==this.settings.negativeBracketsTypeOnBlur&&this.settings.isNegativeSignAllowed&&(t=this.constructor._removeBrackets(Er.getElementValue(this.domElement),this.settings)),""!==(n=this._getRawValueToFormat(this.rawValue))&&(i=this.constructor._roundFormattedValueShownOnFocusOrBlur(n,this.settings,this.isFocused),t=this.settings.showOnlyNumbersOnFocus===I.options.showOnlyNumbersOnFocus.onlyNumbers?(this.settings.digitGroupSeparator="",this.settings.currencySymbol="",this.settings.suffixText="",i.replace(".",this.settings.decimalCharacter)):Er.isNull(i)?"":this.constructor._addGroupSeparators(i.replace(".",this.settings.decimalCharacter),this.settings,this.isFocused,n)),Er.isNull(t)?this.valueOnFocus="":this.valueOnFocus=t,this.lastVal=this.valueOnFocus,i=this.constructor._isElementValueEmptyOrOnlyTheNegativeSign(this.valueOnFocus,this.settings),n=this.constructor._orderValueCurrencySymbolAndSuffixText(this.valueOnFocus,this.settings,!0),(i=i&&""!==n&&this.settings.emptyInputBehavior===I.options.emptyInputBehavior.focus)&&(t=n),Er.isNull(t)||this._setElementValue(t),i&&n===this.settings.currencySymbol&&this.settings.currencySymbolPlacement===I.options.currencySymbolPlacement.suffix&&Er.setElementSelection(e.target,0)))}},{key:"_onFocus",value:function(){this.settings.isCancellable&&this._saveCancellableValue()}},{key:"_onFocusIn",value:function(e){this.settings.selectOnFocus?this.select():Er.isNull(this.settings.caretPositionOnFocus)||Er.setElementSelection(e.target,this._initialCaretPosition(Er.getElementValue(this.domElement)))}},{key:"_enterFormulaMode",value:function(){this.settings.formulaMode&&(this.formulaMode=!0,Er.setElementValue(this.domElement,"="),Er.setElementSelection(this.domElement,1))}},{key:"_exitFormulaMode",value:function(){var t=(t=Er.getElementValue(this.domElement)).replace(/^\s*=/,"");try{var e=new Fr(t,this.settings.decimalCharacter),n=(new xr).evaluate(e)}catch(e){return this._triggerEvent(I.events.invalidFormula,this.domElement,{formula:t,aNElement:this}),this.reformat(),void(this.formulaMode=!1)}this._triggerEvent(I.events.validFormula,this.domElement,{formula:t,result:n,aNElement:this}),this.set(n),this.formulaMode=!1}},{key:"_acceptNonPrintableKeysInFormulaMode",value:function(){return this.eventKey===fr.keyName.Backspace||this.eventKey===fr.keyName.Delete||this.eventKey===fr.keyName.LeftArrow||this.eventKey===fr.keyName.RightArrow||this.eventKey===fr.keyName.Home||this.eventKey===fr.keyName.End}},{key:"_onKeydown",value:function(e){if(this.formatted=!1,this.isEditing=!0,this.formulaMode||this.isFocused||!this.settings.unformatOnHover||!e.altKey||this.domElement!==Er.getHoveredElement()){if(this._updateEventKeyInfo(e),this.keydownEventCounter+=1,1===this.keydownEventCounter&&(this.initialValueOnFirstKeydown=Er.getElementValue(e.target),this.initialRawValueOnFirstKeydown=this.rawValue),this.formulaMode){if(this.eventKey===fr.keyName.Esc)return this.formulaMode=!1,void this.reformat();if(this.eventKey===fr.keyName.Enter)return void this._exitFormulaMode();if(this._acceptNonPrintableKeysInFormulaMode())return}else if(this.eventKey===fr.keyName.Equal)return void this._enterFormulaMode();var t,n;this.domElement.readOnly||this.settings.readOnly||this.domElement.disabled?this.processed=!0:(this.eventKey===fr.keyName.Esc&&(e.preventDefault(),this.settings.isCancellable&&this.rawValue!==this.savedCancellableValue&&(this.set(this.savedCancellableValue),this._triggerEvent(I.events.native.input,e.target)),this.select()),t=Er.getElementValue(e.target),this.eventKey===fr.keyName.Enter&&this.rawValue!==this.rawValueOnFocus&&(this._triggerEvent(I.events.native.change,e.target),this.valueOnFocus=t,this.rawValueOnFocus=this.rawValue,this.settings.isCancellable&&this._saveCancellableValue()),this._updateInternalProperties(e),this._processNonPrintableKeysAndShortcuts(e)?this.processed=!0:this.eventKey!==fr.keyName.Backspace&&this.eventKey!==fr.keyName.Delete||(n=this._processCharacterDeletion(),this.processed=!0,n?(this._formatValue(e),(t=Er.getElementValue(e.target))!==this.lastVal&&this.throwInput&&(this._triggerEvent(I.events.native.input,e.target),e.preventDefault()),this.lastVal=t,this.throwInput=!0):e.preventDefault()))}else this.constructor._unformatAltHovered(this)}},{key:"_onKeypress",value:function(e){if(this.formulaMode)return this._acceptNonPrintableKeysInFormulaMode()||this.settings.formulaChars.test(this.eventKey)?void 0:void e.preventDefault();if(this.eventKey!==fr.keyName.Insert){var t=this.processed;if(this._updateInternalProperties(e),!this._processNonPrintableKeysAndShortcuts(e))if(t)e.preventDefault();else{if(this._processCharacterInsertion()){this._formatValue(e);t=Er.getElementValue(e.target);return t!==this.lastVal&&this.throwInput?this._triggerEvent(I.events.native.input,e.target):this.eventKey!==this.settings.decimalCharacter&&this.eventKey!==this.settings.decimalCharacterAlternative||Er.getElementSelection(e.target).start!==Er.getElementSelection(e.target).end||Er.getElementSelection(e.target).start!==t.indexOf(this.settings.decimalCharacter)||(t=Er.getElementSelection(e.target).start+1,Er.setElementSelection(e.target,t)),e.preventDefault(),this.lastVal=Er.getElementValue(e.target),this.throwInput=!0,void this._setValidOrInvalidState(this.rawValue)}e.preventDefault()}}}},{key:"_onKeyup",value:function(e){if(this.isEditing=!1,this.keydownEventCounter=0,!this.formulaMode)if(this.settings.isCancellable&&this.eventKey===fr.keyName.Esc)e.preventDefault();else{if(this.eventKey===fr.keyName.Z||this.eventKey===fr.keyName.z){if(e.ctrlKey&&e.shiftKey)return e.preventDefault(),this._historyTableRedo(),void(this.onGoingRedo=!0);if(e.ctrlKey&&!e.shiftKey){if(!this.onGoingRedo)return e.preventDefault(),void this._historyTableUndo();this.onGoingRedo=!1}}var t,n;this.onGoingRedo&&(e.ctrlKey||e.shiftKey)&&(this.onGoingRedo=!1),(e.ctrlKey||e.metaKey)&&this.eventKey===fr.keyName.x&&(n=Er.getElementSelection(this.domElement).start,t=this.constructor._toNumericValue(Er.getElementValue(e.target),this.settings),this.set(t),this._setCaretPosition(n)),this.eventKey===fr.keyName.Alt&&this.settings.unformatOnHover&&this.hoveredWithAlt?this.constructor._reformatAltHovered(this):!e.ctrlKey&&!e.metaKey||this.eventKey!==fr.keyName.Backspace&&this.eventKey!==fr.keyName.Delete?(this._updateInternalProperties(e),t=this._processNonPrintableKeysAndShortcuts(e),delete this.valuePartsBeforePaste,n=Er.getElementValue(e.target),t||""===n&&""===this.initialValueOnFirstKeydown||(n===this.settings.currencySymbol?this.settings.currencySymbolPlacement===I.options.currencySymbolPlacement.suffix?Er.setElementSelection(e.target,0):Er.setElementSelection(e.target,this.settings.currencySymbol.length):this.eventKey===fr.keyName.Tab&&Er.setElementSelection(e.target,0,n.length),(n===this.settings.suffixText||""===this.rawValue&&""!==this.settings.currencySymbol&&""!==this.settings.suffixText)&&Er.setElementSelection(e.target,0),null!==this.settings.decimalPlacesShownOnFocus&&this._saveValueToPersistentStorage(),this.formatted||this._formatValue(e),this._setValidOrInvalidState(this.rawValue),this._saveRawValueForAndroid(),n!==this.initialValueOnFirstKeydown&&this._triggerEvent(I.events.formatted,e.target,{oldValue:this.initialValueOnFirstKeydown,newValue:n,oldRawValue:this.initialRawValueOnFirstKeydown,newRawValue:this.rawValue,isPristine:this.isPristine(!1),error:null,aNElement:this}),1<this.historyTable.length&&(n=Er.getElementSelection(this.domElement),this.selectionStart=n.start,this.selectionEnd=n.end,this.historyTable[this.historyTableIndex].start=this.selectionStart,this.historyTable[this.historyTableIndex].end=this.selectionEnd))):(e=Er.getElementValue(e.target),this._setRawValue(this._formatOrUnformatOther(!1,e)))}}},{key:"_saveRawValueForAndroid",value:function(){var e;this.eventKey===fr.keyName.AndroidDefault&&(e=this.constructor._stripAllNonNumberCharactersExceptCustomDecimalChar(this.getFormatted(),this.settings,!0,this.isFocused),e=this.constructor._convertToNumericString(e,this.settings),this._setRawValue(e))}},{key:"_onFocusOutAndMouseLeave",value:function(e){if(this.isEditing=!1,"mouseleave"!==e.type||!this.formulaMode)if(this.settings.unformatOnHover&&"mouseleave"===e.type&&this.hoveredWithAlt)this.constructor._reformatAltHovered(this);else if("mouseleave"===e.type&&!this.isFocused||"blur"===e.type){"blur"===e.type&&this.formulaMode&&this._exitFormulaMode(),this._saveValueToPersistentStorage(),this.settings.showOnlyNumbersOnFocus===I.options.showOnlyNumbersOnFocus.onlyNumbers&&(this.settings.digitGroupSeparator=this.originalDigitGroupSeparator,this.settings.currencySymbol=this.originalCurrencySymbol,this.settings.suffixText=this.originalSuffixText);var t=this._getRawValueToFormat(this.rawValue),n=Er.isNull(t),i=Vr(this.constructor._checkIfInRangeWithOverrideOption(t,this.settings),2),r=i[0],o=i[1],i=!1;if(""===t||n||(this._triggerRangeEvents(r,o),this.settings.valuesToStrings&&this._checkValuesToStrings(t)&&(this._setElementValue(this.settings.valuesToStrings[t]),i=!0)),!i){var s=n||""===t?t:String(t);if(""===t||n){if(""===t)switch(this.settings.emptyInputBehavior){case I.options.emptyInputBehavior.zero:this._setRawValue("0"),s=this.constructor._roundValue("0",this.settings,0);break;case I.options.emptyInputBehavior.min:this._setRawValue(this.settings.minimumValue),s=this.constructor._roundFormattedValueShownOnFocusOrBlur(this.settings.minimumValue,this.settings,this.isFocused);break;case I.options.emptyInputBehavior.max:this._setRawValue(this.settings.maximumValue),s=this.constructor._roundFormattedValueShownOnFocusOrBlur(this.settings.maximumValue,this.settings,this.isFocused);break;default:Er.isNumber(this.settings.emptyInputBehavior)&&(this._setRawValue(this.settings.emptyInputBehavior),s=this.constructor._roundFormattedValueShownOnFocusOrBlur(this.settings.emptyInputBehavior,this.settings,this.isFocused))}}else r&&o&&!this.constructor._isElementValueEmptyOrOnlyTheNegativeSign(t,this.settings)?(s=this._modifyNegativeSignAndDecimalCharacterForRawValue(s),this.settings.divisorWhenUnfocused&&!Er.isNull(s)&&(s=(s/=this.settings.divisorWhenUnfocused).toString()),s=this.constructor._roundFormattedValueShownOnBlur(s,this.settings),s=this.constructor._modifyNegativeSignAndDecimalCharacterForFormattedValue(s,this.settings)):this._triggerRangeEvents(r,o);o=this.constructor._orderValueCurrencySymbolAndSuffixText(s,this.settings,!1);(o=!(this.constructor._isElementValueEmptyOrOnlyTheNegativeSign(s,this.settings)||n&&this.settings.emptyInputBehavior===I.options.emptyInputBehavior.null)?this.constructor._addGroupSeparators(s,this.settings,!1,t):o)===t&&""!==t&&this.settings.allowDecimalPadding!==I.options.allowDecimalPadding.never&&this.settings.allowDecimalPadding!==I.options.allowDecimalPadding.floats||(this.settings.symbolWhenUnfocused&&""!==t&&null!==t&&(o="".concat(o).concat(this.settings.symbolWhenUnfocused)),this._setElementValue(o))}this._setValidOrInvalidState(this.rawValue),"blur"===e.type&&this._onBlur(e)}}},{key:"_onPaste",value:function(e){if(e.preventDefault(),!(this.settings.readOnly||this.domElement.readOnly||this.domElement.disabled)){var t,n;window.clipboardData&&window.clipboardData.getData?t=window.clipboardData.getData("Text"):e.clipboardData&&e.clipboardData.getData?t=e.clipboardData.getData("text/plain"):Er.throwError("Unable to retrieve the pasted value. Please use a modern browser (ie. Firefox or Chromium)."),n=e.target.tagName?e.target:e.explicitOriginalTarget;var i=Er.getElementValue(n),r=n.selectionStart||0,o=n.selectionEnd||0,s=o-r;if(s===i.length){var a=this._preparePastedText(t),l=Er.arabicToLatinNumbers(a,!1,!1,!1);return"."===l||""===l||"."!==l&&!Er.isNumber(l)?(this.formatted=!0,void(this.settings.onInvalidPaste===I.options.onInvalidPaste.error&&Er.throwError("The pasted value '".concat(t,"' is not a valid paste content.")))):(this.set(l),this.formatted=!0,void this._triggerEvent(I.events.native.input,n))}e=Er.isNegativeStrict(t,this.settings.negativeSignCharacter);e&&(t=t.slice(1,t.length));var a=this._preparePastedText(t),c="."===a?".":Er.arabicToLatinNumbers(a,!1,!1,!1);if("."!==c&&(!Er.isNumber(c)||""===c))return this.formatted=!0,void(this.settings.onInvalidPaste===I.options.onInvalidPaste.error&&Er.throwError("The pasted value '".concat(t,"' is not a valid paste content.")));var l=Er.isNegativeStrict(this.getNumericString(),this.settings.negativeSignCharacter),u=!(!e||l)&&(l=!0),a=i.slice(0,r),e=i.slice(o,i.length);x=r!==o?this._preparePastedText(a+e):this._preparePastedText(i),l&&(x=Er.setRawNegativeSign(x)),w=Er.convertCharacterCountToIndexPosition(Er.countNumberCharactersOnTheCaretLeftSide(i,r,this.settings.decimalCharacter)),u&&w++;var h=x.slice(0,w),d=x.slice(w,x.length),m=!1;"."===c&&(Er.contains(h,".")&&(m=!0,h=h.replace(".","")),d=d.replace(".",""));var p=!1;switch(""===h&&"-"===d&&(h="-",p=!(d="")),this.settings.onInvalidPaste){case I.options.onInvalidPaste.truncate:case I.options.onInvalidPaste.replace:for(var g=Er.parseStr(this.settings.minimumValue),f=Er.parseStr(this.settings.maximumValue),v=x,y=0,b=h;y<c.length&&(x=(b+=c[y])+d,this.constructor._checkIfInRange(x,g,f));)v=x,y++;if(w+=y,p&&w++,this.settings.onInvalidPaste===I.options.onInvalidPaste.truncate){x=v,m&&w--;break}for(var _=w,S=v.length;y<c.length&&_<S;)if("."!==v[_]){if(x=Er.replaceCharAt(v,_,c[y]),!this.constructor._checkIfInRange(x,g,f))break;v=x,y++,_++}else _++;w=_,m&&w--,x=v;break;case I.options.onInvalidPaste.error:case I.options.onInvalidPaste.ignore:case I.options.onInvalidPaste.clamp:default:var w,E,k,x="".concat(h).concat(c).concat(d);r===o?w=Er.convertCharacterCountToIndexPosition(Er.countNumberCharactersOnTheCaretLeftSide(i,r,this.settings.decimalCharacter))+c.length:""===d?(w=Er.convertCharacterCountToIndexPosition(Er.countNumberCharactersOnTheCaretLeftSide(i,r,this.settings.decimalCharacter))+c.length,p&&w++):(E=Er.convertCharacterCountToIndexPosition(Er.countNumberCharactersOnTheCaretLeftSide(i,o,this.settings.decimalCharacter)),k=Er.getElementValue(n).slice(r,o),w=E-s+Er.countCharInText(this.settings.digitGroupSeparator,k)+c.length),u&&w++,m&&w--}if(Er.isNumber(x)&&""!==x){var P,O=!1,C=!1;try{this.set(x),O=!0}catch(e){switch(this.settings.onInvalidPaste){case I.options.onInvalidPaste.clamp:P=Er.clampToRangeLimits(x,this.settings);try{this.set(P)}catch(e){Er.throwError("Fatal error: Unable to set the clamped value '".concat(P,"'."))}O=C=!0,x=P;break;case I.options.onInvalidPaste.error:case I.options.onInvalidPaste.truncate:case I.options.onInvalidPaste.replace:Er.throwError("The pasted value '".concat(t,"' results in a value '").concat(x,"' that is outside of the minimum [").concat(this.settings.minimumValue,"] and maximum [").concat(this.settings.maximumValue,"] value range."));case I.options.onInvalidPaste.ignore:default:return}}var N,T=Er.getElementValue(n);if(O)switch(this.settings.onInvalidPaste){case I.options.onInvalidPaste.clamp:if(C){this.settings.currencySymbolPlacement===I.options.currencySymbolPlacement.suffix?Er.setElementSelection(n,T.length-this.settings.currencySymbol.length):Er.setElementSelection(n,T.length);break}case I.options.onInvalidPaste.error:case I.options.onInvalidPaste.ignore:case I.options.onInvalidPaste.truncate:case I.options.onInvalidPaste.replace:default:N=Er.findCaretPositionInFormattedNumber(x,w,T,this.settings.decimalCharacter),Er.setElementSelection(n,N)}O&&i!==T&&this._triggerEvent(I.events.native.input,n)}else this.settings.onInvalidPaste===I.options.onInvalidPaste.error&&Er.throwError("The pasted value '".concat(t,"' would result into an invalid content '").concat(x,"'."))}}},{key:"_onBlur",value:function(e){this.isFocused=!1,this.isEditing=!1,this.rawValue!==this.rawValueOnFocus&&this._triggerEvent(I.events.native.change,e.target),this.rawValueOnFocus=void 0}},{key:"_onWheel",value:function(e){this.formulaMode||this.settings.readOnly||this.domElement.readOnly||this.domElement.disabled||this.settings.modifyValueOnWheel&&(this.settings.wheelOn===I.options.wheelOn.focus?this.isFocused?e.shiftKey||this.wheelAction(e):e.shiftKey&&this.wheelAction(e):this.settings.wheelOn===I.options.wheelOn.hover?e.shiftKey?(e.preventDefault(),window.scrollBy(0,Er.isNegativeStrict(String(e.deltaY))?-50:50)):this.wheelAction(e):Er.throwError("Unknown `wheelOn` option."))}},{key:"wheelAction",value:function(e){this.isWheelEvent=!0;var t,n,i=e.target.selectionStart||0,r=e.target.selectionEnd||0,o=this.rawValue;Er.isUndefinedOrNullOrEmpty(o)?0<this.settings.minimumValue||this.settings.maximumValue<0?Er.isWheelUpEvent(e)?t=this.settings.minimumValue:Er.isWheelDownEvent(e)?t=this.settings.maximumValue:Er.throwError("The event is not a 'wheel' event."):t=0:t=o,t=+t,Er.isNumber(this.settings.wheelStep)?(n=+this.settings.wheelStep,Er.isWheelUpEvent(e)?t+=n:Er.isWheelDownEvent(e)&&(t-=n)):Er.isWheelUpEvent(e)?t=Er.addAndRoundToNearestAuto(t,this.settings.decimalPlacesRawValue):Er.isWheelDownEvent(e)&&(t=Er.subtractAndRoundToNearestAuto(t,this.settings.decimalPlacesRawValue)),(t=Er.clampToRangeLimits(t,this.settings))!==+o&&(this.set(t),this._triggerEvent(I.events.native.input,e.target)),e.preventDefault(),this._setSelection(i,r),this.isWheelEvent=!1}},{key:"_onDrop",value:function(e){var t;this.formulaMode||(this.isDropEvent=!0,e.preventDefault(),t=Er.isIE11()?"text":"text/plain",t=e.dataTransfer.getData(t),t=this.unformatOther(t),this.set(t),this.isDropEvent=!1)}},{key:"_onFormSubmit",value:function(){var t=this;return this._getFormAutoNumericChildren(this.parentForm).map(function(e){return t.constructor.getAutoNumericElement(e)}).forEach(function(e){return e._unformatOnSubmit()}),!0}},{key:"_onFormReset",value:function(){var n=this;this._getFormAutoNumericChildren(this.parentForm).map(function(e){return n.constructor.getAutoNumericElement(e)}).forEach(function(e){var t=n._getDefaultValue(e.node());setTimeout(function(){return e.set(t)},0)})}},{key:"_unformatOnSubmit",value:function(){this.settings.unformatOnSubmit&&this._setElementValue(this.rawValue)}},{key:"_onKeydownGlobal",value:function(e){Er.character(e)===fr.keyName.Alt&&(e=Er.getHoveredElement(),!I.isManagedByAutoNumeric(e)||!(e=I.getAutoNumericElement(e)).formulaMode&&e.settings.unformatOnHover&&this.constructor._unformatAltHovered(e))}},{key:"_onKeyupGlobal",value:function(e){Er.character(e)===fr.keyName.Alt&&(e=Er.getHoveredElement(),!I.isManagedByAutoNumeric(e)||!(e=I.getAutoNumericElement(e)).formulaMode&&e.settings.unformatOnHover&&this.constructor._reformatAltHovered(e))}},{key:"_isElementTagSupported",value:function(){return Er.isElement(this.domElement)||Er.throwError("The DOM element is not valid, ".concat(this.domElement," given.")),Er.isInArray(this.domElement.tagName.toLowerCase(),this.allowedTagList)}},{key:"_isInputElement",value:function(){return"input"===this.domElement.tagName.toLowerCase()}},{key:"_isInputTypeSupported",value:function(){return"text"===this.domElement.type||"hidden"===this.domElement.type||"tel"===this.domElement.type||Er.isUndefinedOrNullOrEmpty(this.domElement.type)}},{key:"_checkElement",value:function(){var e=this.domElement.tagName.toLowerCase();this._isElementTagSupported()||Er.throwError("The <".concat(e,"> tag is not supported by autoNumeric")),this._isInputElement()?(this._isInputTypeSupported()||Er.throwError('The input type "'.concat(this.domElement.type,'" is not supported by autoNumeric')),this.isInputElement=!0):(this.isInputElement=!1,this.isContentEditable=this.domElement.hasAttribute("contenteditable")&&"true"===this.domElement.getAttribute("contenteditable"))}},{key:"_formatDefaultValueOnPageLoad",value:function(){var e,t=0<arguments.length&&void 0!==arguments[0]?arguments[0]:null,n=!0;if(Er.isNull(t)?(e=Er.getElementValue(this.domElement).trim(),this.domElement.setAttribute("value",e)):e=t,this.isInputElement||this.isContentEditable){var i=this.constructor._toNumericValue(e,this.settings);if(this.domElement.hasAttribute("value")&&""!==this.domElement.getAttribute("value")?(null!==this.settings.defaultValueOverride&&this.settings.defaultValueOverride.toString()!==e||null===this.settings.defaultValueOverride&&""!==e&&e!==this.domElement.getAttribute("value")||""!==e&&"hidden"===this.domElement.getAttribute("type")&&!Er.isNumber(i))&&(this.settings.saveValueToSessionStorage&&(null!==this.settings.decimalPlacesShownOnFocus||this.settings.divisorWhenUnfocused)&&this._setRawValue(this._getValueFromPersistentStorage()),this.settings.saveValueToSessionStorage||(t=this.constructor._removeBrackets(e,this.settings),(this.settings.negativePositiveSignPlacement===I.options.negativePositiveSignPlacement.suffix||this.settings.negativePositiveSignPlacement!==I.options.negativePositiveSignPlacement.prefix&&this.settings.currencySymbolPlacement===I.options.currencySymbolPlacement.suffix)&&""!==this.settings.negativeSignCharacter&&Er.isNegative(e,this.settings.negativeSignCharacter)?this._setRawValue("-".concat(this.constructor._stripAllNonNumberCharacters(t,this.settings,!0,this.isFocused))):this._setRawValue(this.constructor._stripAllNonNumberCharacters(t,this.settings,!0,this.isFocused))),n=!1):isNaN(Number(i))||1/0===i?Er.throwError("The value [".concat(e,"] used in the input is not a valid value autoNumeric can work with.")):(this.set(i),n=!1),""===e)switch(this.settings.emptyInputBehavior){case I.options.emptyInputBehavior.focus:case I.options.emptyInputBehavior.null:case I.options.emptyInputBehavior.press:break;case I.options.emptyInputBehavior.always:this._setElementValue(this.settings.currencySymbol);break;case I.options.emptyInputBehavior.min:this.set(this.settings.minimumValue);break;case I.options.emptyInputBehavior.max:this.set(this.settings.maximumValue);break;case I.options.emptyInputBehavior.zero:this.set("0");break;default:this.set(this.settings.emptyInputBehavior)}else n&&e===this.domElement.getAttribute("value")&&this.set(e)}else null!==this.settings.defaultValueOverride&&this.settings.defaultValueOverride!==e||this.set(e)}},{key:"_calculateVMinAndVMaxIntegerSizes",value:function(){var e=Vr(this.settings.maximumValue.toString().split("."),1)[0],t=Vr(this.settings.minimumValue||0===this.settings.minimumValue?this.settings.minimumValue.toString().split("."):[],1)[0],e=e.replace(this.settings.negativeSignCharacter,""),t=t.replace(this.settings.negativeSignCharacter,"");this.settings.mIntPos=Math.max(e.length,1),this.settings.mIntNeg=Math.max(t.length,1)}},{key:"_calculateValuesToStringsKeys",value:function(){this.settings.valuesToStrings?this.valuesToStringsKeys=Object.keys(this.settings.valuesToStrings):this.valuesToStringsKeys=[]}},{key:"_transformOptionsValuesToDefaultTypes",value:function(){for(var e in this.settings){var t;Object.prototype.hasOwnProperty.call(this.settings,e)&&("true"!==(t=this.settings[e])&&"false"!==t||(this.settings[e]="true"===t),"number"==typeof t&&(this.settings[e]=t.toString()))}}},{key:"_setSettings",value:function(e){var t=1<arguments.length&&void 0!==arguments[1]&&arguments[1];!t&&Er.isNull(e)||this.constructor._convertOldOptionsToNewOnes(e),t?("decimalPlacesRawValue"in e&&(this.settings.originalDecimalPlacesRawValue=e.decimalPlacesRawValue),"decimalPlaces"in e&&(this.settings.originalDecimalPlaces=e.decimalPlaces),this.constructor._calculateDecimalPlacesOnUpdate(e,this.settings),this._mergeSettings(e)):(this.settings={},this._mergeSettings(this.constructor.getDefaultConfig(),this.domElement.dataset,e,{rawValue:this.defaultRawValue}),this.caretFix=!1,this.throwInput=!0,this.allowedTagList=fr.allowedTagList,this.runOnce=!1,this.hoveredWithAlt=!1),this._transformOptionsValuesToDefaultTypes(),this._runCallbacksFoundInTheSettingsObject(),this.constructor._correctNegativePositiveSignPlacementOption(this.settings),this.constructor._correctCaretPositionOnFocusAndSelectOnFocusOptions(this.settings),this.constructor._setNegativePositiveSignPermissions(this.settings),t||(Er.isNull(e)||!e.decimalPlaces?this.settings.originalDecimalPlaces=null:this.settings.originalDecimalPlaces=e.decimalPlaces,this.settings.originalDecimalPlacesRawValue=this.settings.decimalPlacesRawValue,this.constructor._calculateDecimalPlacesOnInit(this.settings)),this._calculateVMinAndVMaxIntegerSizes(),this._setTrailingNegativeSignInfo(),this.regex={},this.constructor._cachesUsualRegularExpressions(this.settings,this.regex),this.constructor._setBrackets(this.settings),this._calculateValuesToStringsKeys(),Er.isEmptyObj(this.settings)&&Er.throwError("Unable to set the settings, those are invalid ; an empty object was given."),this.constructor.validate(this.settings,!1,e),this._keepAnOriginalSettingsCopy()}},{key:"_preparePastedText",value:function(e){return this.constructor._stripAllNonNumberCharacters(e,this.settings,!0,this.isFocused)}},{key:"_updateInternalProperties",value:function(){this.selection=Er.getElementSelection(this.domElement),this.processed=!1}},{key:"_updateEventKeyInfo",value:function(e){this.eventKey=Er.character(e)}},{key:"_saveCancellableValue",value:function(){this.savedCancellableValue=this.rawValue}},{key:"_setSelection",value:function(e,t){e=Math.max(e,0),t=Math.min(t,Er.getElementValue(this.domElement).length),this.selection={start:e,end:t,length:t-e},Er.setElementSelection(this.domElement,e,t)}},{key:"_setCaretPosition",value:function(e){this._setSelection(e,e)}},{key:"_getLeftAndRightPartAroundTheSelection",value:function(){var e=Er.getElementValue(this.domElement);return[e.substring(0,this.selection.start),e.substring(this.selection.end,e.length)]}},{key:"_getUnformattedLeftAndRightPartAroundTheSelection",value:function(){var e=Vr(this._getLeftAndRightPartAroundTheSelection(),2),t=e[0],n=e[1];if(""===t&&""===n)return["",""];e=!0;return this.eventKey!==fr.keyName.Hyphen&&this.eventKey!==fr.keyName.Minus||0!==Number(t)||(e=!1),this.isTrailingNegative&&(Er.isNegative(n,this.settings.negativeSignCharacter)&&!Er.isNegative(t,this.settings.negativeSignCharacter)||""===n&&Er.isNegative(t,this.settings.negativeSignCharacter,!0))&&(t=t.replace(this.settings.negativeSignCharacter,""),n=n.replace(this.settings.negativeSignCharacter,""),t=t.replace("-",""),n=n.replace("-",""),t="-".concat(t)),[t=I._stripAllNonNumberCharactersExceptCustomDecimalChar(t,this.settings,e,this.isFocused),n=I._stripAllNonNumberCharactersExceptCustomDecimalChar(n,this.settings,!1,this.isFocused)]}},{key:"_normalizeParts",value:function(e,t){var n=!0;this.eventKey!==fr.keyName.Hyphen&&this.eventKey!==fr.keyName.Minus||0!==Number(e)||(n=!1),this.isTrailingNegative&&Er.isNegative(t,this.settings.negativeSignCharacter)&&!Er.isNegative(e,this.settings.negativeSignCharacter)&&(e="-".concat(e),t=t.replace(this.settings.negativeSignCharacter,"")),e=I._stripAllNonNumberCharactersExceptCustomDecimalChar(e,this.settings,n,this.isFocused),t=I._stripAllNonNumberCharactersExceptCustomDecimalChar(t,this.settings,!1,this.isFocused);var i=(e=!(this.settings.leadingZero!==I.options.leadingZero.deny||this.eventKey!==fr.keyName.num0&&this.eventKey!==fr.keyName.numpad0||0!==Number(e)||Er.contains(e,this.settings.decimalCharacter)||""===t)?e.substring(0,e.length-1):e)+t;return!this.settings.decimalCharacter||(n=i.match(new RegExp("^".concat(this.regex.aNegRegAutoStrip,"\\").concat(this.settings.decimalCharacter))))&&(i=(e=e.replace(n[1],n[1]+"0"))+t),[e,t,i]}},{key:"_setValueParts",value:function(e,t){var n=2<arguments.length&&void 0!==arguments[2]&&arguments[2],i=Vr(this._normalizeParts(e,t),3),r=i[0],o=i[1],s=i[2],e=Vr(I._checkIfInRangeWithOverrideOption(s,this.settings),2),t=e[0],i=e[1];if(t&&i){var a,e=I._truncateDecimalPlaces(s,this.settings,n,this.settings.decimalPlacesRawValue).replace(this.settings.decimalCharacter,".");if(""===e||e===this.settings.negativeSignCharacter){switch(this.settings.emptyInputBehavior){case I.options.emptyInputBehavior.focus:case I.options.emptyInputBehavior.press:case I.options.emptyInputBehavior.always:a="";break;case I.options.emptyInputBehavior.min:a=this.settings.minimumValue;break;case I.options.emptyInputBehavior.max:a=this.settings.maximumValue;break;case I.options.emptyInputBehavior.zero:a="0";break;case I.options.emptyInputBehavior.null:a=null;break;default:a=this.settings.emptyInputBehavior}this._setRawValue(a)}else this._setRawValue(this._trimLeadingAndTrailingZeros(e));s=I._truncateDecimalPlaces(s,this.settings,n,this.settings.decimalPlacesShownOnFocus),n=r.length;return 1===(n=n>s.length?s.length:n)&&"0"===r&&this.settings.leadingZero===I.options.leadingZero.deny&&(n=""===o||"0"===r&&""!==o?1:0),this._setElementValue(s,!1),this._setCaretPosition(n),!0}return this._triggerRangeEvents(t,i),!1}},{key:"_getSignPosition",value:function(){var e,t;return this.settings.currencySymbol?(e=this.settings.currencySymbol.length,t=Er.getElementValue(this.domElement),this.settings.currencySymbolPlacement===I.options.currencySymbolPlacement.prefix?this.settings.negativeSignCharacter&&t&&t.charAt(0)===this.settings.negativeSignCharacter?[1,e+1]:[0,e]:[(t=t.length)-e,t]):[1e3,-1]}},{key:"_expandSelectionOnSign",value:function(){var e=Vr(this._getSignPosition(),2),t=e[0],n=e[1],e=this.selection;e.start<n&&e.end>t&&((e.start<t||e.end>n)&&Er.getElementValue(this.domElement).substring(Math.max(e.start,t),Math.min(e.end,n)).match(/^\s*$/)?e.start<t?this._setSelection(e.start,t):this._setSelection(n,e.end):this._setSelection(Math.min(e.start,t),Math.max(e.end,n)))}},{key:"_checkPaste",value:function(){var e,t,n;this.formatted||Er.isUndefined(this.valuePartsBeforePaste)||(e=this.valuePartsBeforePaste,n=(t=Vr(this._getLeftAndRightPartAroundTheSelection(),2))[0],t=t[1],delete this.valuePartsBeforePaste,n=n.substr(0,e[0].length)+I._stripAllNonNumberCharactersExceptCustomDecimalChar(n.substr(e[0].length),this.settings,!0,this.isFocused),this._setValueParts(n,t,!0)||(this._setElementValue(e.join(""),!1),this._setCaretPosition(e[0].length)))}},{key:"_processNonPrintableKeysAndShortcuts",value:function(e){return(e.ctrlKey||e.metaKey)&&"keyup"===e.type&&!Er.isUndefined(this.valuePartsBeforePaste)||e.shiftKey&&this.eventKey===fr.keyName.Insert?(this._checkPaste(),!1):!!this.constructor._shouldSkipEventKey(this.eventKey)||((e.ctrlKey||e.metaKey)&&this.eventKey===fr.keyName.a?(this.settings.selectNumberOnly&&(e.preventDefault(),this.selectNumber()),!0):!e.ctrlKey&&!e.metaKey||this.eventKey!==fr.keyName.c&&this.eventKey!==fr.keyName.v&&this.eventKey!==fr.keyName.x?e.ctrlKey||e.metaKey?!(this.eventKey===fr.keyName.Z||this.eventKey===fr.keyName.z):this.eventKey!==fr.keyName.LeftArrow&&this.eventKey!==fr.keyName.RightArrow?Er.isInArray(this.eventKey,fr.keyName._directionKeys):("keydown"!==e.type||e.shiftKey||(t=Er.getElementValue(this.domElement),this.eventKey!==fr.keyName.LeftArrow||t.charAt(this.selection.start-2)!==this.settings.digitGroupSeparator&&t.charAt(this.selection.start-2)!==this.settings.decimalCharacter?this.eventKey!==fr.keyName.RightArrow||t.charAt(this.selection.start+1)!==this.settings.digitGroupSeparator&&t.charAt(this.selection.start+1)!==this.settings.decimalCharacter||this._setCaretPosition(this.selection.start+1):this._setCaretPosition(this.selection.start-1)),!0):("keydown"===e.type&&this._expandSelectionOnSign(),this.eventKey!==fr.keyName.v&&this.eventKey!==fr.keyName.Insert||("keydown"===e.type||"keypress"===e.type?Er.isUndefined(this.valuePartsBeforePaste)&&(this.valuePartsBeforePaste=this._getLeftAndRightPartAroundTheSelection()):this._checkPaste()),"keydown"===e.type||"keypress"===e.type||this.eventKey===fr.keyName.c));var t}},{key:"_processCharacterDeletionIfTrailingNegativeSign",value:function(e){var e=Vr(e,2),t=e[0],n=e[1],i=Er.getElementValue(this.domElement),r=Er.isNegative(i,this.settings.negativeSignCharacter);if(this.settings.currencySymbolPlacement===I.options.currencySymbolPlacement.prefix&&this.settings.negativePositiveSignPlacement===I.options.negativePositiveSignPlacement.suffix&&(this.eventKey===fr.keyName.Backspace?(this.caretFix=this.selection.start>=i.indexOf(this.settings.suffixText)&&""!==this.settings.suffixText,"-"===i.charAt(this.selection.start-1)?t=t.substring(1):this.selection.start<=i.length-this.settings.suffixText.length&&(t=t.substring(0,t.length-1))):(this.caretFix=this.selection.start>=i.indexOf(this.settings.suffixText)&&""!==this.settings.suffixText,this.selection.start>=i.indexOf(this.settings.currencySymbol)+this.settings.currencySymbol.length&&(n=n.substring(1,n.length)),Er.isNegative(t,this.settings.negativeSignCharacter)&&"-"===i.charAt(this.selection.start)&&(t=t.substring(1)))),this.settings.currencySymbolPlacement===I.options.currencySymbolPlacement.suffix)switch(this.settings.negativePositiveSignPlacement){case I.options.negativePositiveSignPlacement.left:this.caretFix=this.selection.start>=i.indexOf(this.settings.negativeSignCharacter)+this.settings.negativeSignCharacter.length,this.eventKey===fr.keyName.Backspace?this.selection.start===i.indexOf(this.settings.negativeSignCharacter)+this.settings.negativeSignCharacter.length&&r?t=t.substring(1):"-"!==t&&(this.selection.start<=i.indexOf(this.settings.negativeSignCharacter)||!r)&&(t=t.substring(0,t.length-1)):("-"===t[0]&&(n=n.substring(1)),this.selection.start===i.indexOf(this.settings.negativeSignCharacter)&&r&&(t=t.substring(1)));break;case I.options.negativePositiveSignPlacement.right:this.caretFix=this.selection.start>=i.indexOf(this.settings.negativeSignCharacter)+this.settings.negativeSignCharacter.length,this.eventKey===fr.keyName.Backspace?this.selection.start===i.indexOf(this.settings.negativeSignCharacter)+this.settings.negativeSignCharacter.length?t=t.substring(1):("-"!==t&&this.selection.start<=i.indexOf(this.settings.negativeSignCharacter)-this.settings.currencySymbol.length||""!==t&&!r)&&(t=t.substring(0,t.length-1)):(this.caretFix=this.selection.start>=i.indexOf(this.settings.currencySymbol)&&""!==this.settings.currencySymbol,this.selection.start===i.indexOf(this.settings.negativeSignCharacter)&&(t=t.substring(1)),n=n.substring(1))}return[t,n]}},{key:"_processCharacterDeletion",value:function(){var e,t,n;return this.selection.length?(this._expandSelectionOnSign(),t=(e=Vr(this._getUnformattedLeftAndRightPartAroundTheSelection(),2))[0],n=e[1]):(t=(e=Vr(this._getUnformattedLeftAndRightPartAroundTheSelection(),2))[0],n=e[1],""===t&&""===n&&(this.throwInput=!1),this.isTrailingNegative&&Er.isNegative(Er.getElementValue(this.domElement),this.settings.negativeSignCharacter)?(t=(e=Vr(this._processCharacterDeletionIfTrailingNegativeSign([t,n]),2))[0],n=e[1]):this.eventKey===fr.keyName.Backspace?t=t.substring(0,t.length-1):n=n.substring(1,n.length)),!!this.constructor._isWithinRangeWithOverrideOption("".concat(t).concat(n),this.settings)&&(this._setValueParts(t,n),!0)}},{key:"_isDecimalCharacterInsertionAllowed",value:function(){return String(this.settings.decimalPlacesShownOnFocus)!==String(I.options.decimalPlacesShownOnFocus.none)&&String(this.settings.decimalPlaces)!==String(I.options.decimalPlaces.none)}},{key:"_processCharacterInsertion",value:function(){var e=Vr(this._getUnformattedLeftAndRightPartAroundTheSelection(),2),t=e[0],n=e[1];if(this.eventKey!==fr.keyName.AndroidDefault&&(this.throwInput=!0),this.eventKey===this.settings.decimalCharacter||this.settings.decimalCharacterAlternative&&this.eventKey===this.settings.decimalCharacterAlternative){if(!this._isDecimalCharacterInsertionAllowed()||!this.settings.decimalCharacter)return!1;if(this.settings.alwaysAllowDecimalCharacter)t=t.replace(this.settings.decimalCharacter,""),n=n.replace(this.settings.decimalCharacter,"");else{if(Er.contains(t,this.settings.decimalCharacter))return!0;if(0<n.indexOf(this.settings.decimalCharacter))return!0;0===n.indexOf(this.settings.decimalCharacter)&&(n=n.substr(1))}return this.settings.negativeSignCharacter&&Er.contains(n,this.settings.negativeSignCharacter)&&(t="".concat(this.settings.negativeSignCharacter).concat(t),n=n.replace(this.settings.negativeSignCharacter,"")),this._setValueParts(t+this.settings.decimalCharacter,n),!0}if(("-"===this.eventKey||"+"===this.eventKey)&&this.settings.isNegativeSignAllowed)return""===t&&Er.contains(n,"-")?n=n.replace("-",""):t=Er.isNegativeStrict(t,"-")?t.replace("-",""):"".concat(this.settings.negativeSignCharacter).concat(t),this._setValueParts(t,n),!0;e=Number(this.eventKey);return 0<=e&&e<=9?(this.settings.isNegativeSignAllowed&&""===t&&Er.contains(n,"-")&&(t="-",n=n.substring(1,n.length)),this.settings.maximumValue<=0&&this.settings.minimumValue<this.settings.maximumValue&&!Er.contains(Er.getElementValue(this.domElement),this.settings.negativeSignCharacter)&&"0"!==this.eventKey&&(t="-".concat(t)),this._setValueParts("".concat(t).concat(this.eventKey),n),!0):this.throwInput=!1}},{key:"_formatValue",value:function(e){var t=Er.getElementValue(this.domElement),n=Vr(this._getUnformattedLeftAndRightPartAroundTheSelection(),1)[0];""!==this.settings.digitGroupSeparator&&(""===this.settings.digitGroupSeparator||Er.contains(t,this.settings.digitGroupSeparator))||""!==this.settings.currencySymbol&&(""===this.settings.currencySymbol||Er.contains(t,this.settings.currencySymbol))||(i=Vr(t.split(this.settings.decimalCharacter),1)[0],r="",Er.isNegative(i,this.settings.negativeSignCharacter)&&(r=this.settings.negativeSignCharacter,i=i.replace(this.settings.negativeSignCharacter,""),n=n.replace("-","")),""===r&&i.length>this.settings.mIntPos&&"0"===n.charAt(0)&&(n=n.slice(1)),r===this.settings.negativeSignCharacter&&i.length>this.settings.mIntNeg&&"0"===n.charAt(0)&&(n=n.slice(1)),this.isTrailingNegative||(n="".concat(r).concat(n)));var i=this.constructor._addGroupSeparators(t,this.settings,this.isFocused,this.rawValue),r=i.length;if(i){var o,s,a,l=n.split("");this.settings.negativePositiveSignPlacement!==I.options.negativePositiveSignPlacement.suffix&&(this.settings.negativePositiveSignPlacement===I.options.negativePositiveSignPlacement.prefix||this.settings.currencySymbolPlacement!==I.options.currencySymbolPlacement.suffix)||l[0]!==this.settings.negativeSignCharacter||this.settings.isNegativeSignAllowed||(l.shift(),this.eventKey!==fr.keyName.Backspace&&this.eventKey!==fr.keyName.Delete||!this.caretFix||((this.settings.currencySymbolPlacement===I.options.currencySymbolPlacement.suffix&&this.settings.negativePositiveSignPlacement===I.options.negativePositiveSignPlacement.left||this.settings.currencySymbolPlacement===I.options.currencySymbolPlacement.prefix&&this.settings.negativePositiveSignPlacement===I.options.negativePositiveSignPlacement.suffix)&&(l.push(this.settings.negativeSignCharacter),this.caretFix="keydown"===e.type),this.settings.currencySymbolPlacement===I.options.currencySymbolPlacement.suffix&&this.settings.negativePositiveSignPlacement===I.options.negativePositiveSignPlacement.right&&(o=this.settings.currencySymbol.split(""),s=["\\","^","$",".","|","?","*","+","(",")","["],a=[],o.forEach(function(e,t){t=o[e],Er.isInArray(t,s)?a.push("\\"+t):a.push(t)}),this.eventKey===fr.keyName.Backspace&&"-"===this.settings.negativeSignCharacter&&a.push("-"),l.push(a.join("")),this.caretFix="keydown"===e.type)));for(var c=0;c<l.length;c++)l[c].match("\\d")||(l[c]="\\"+l[c]);e=this.settings.currencySymbolPlacement===I.options.currencySymbolPlacement.suffix?new RegExp("^.*?".concat(l.join(".*?"))):new RegExp("^.*?".concat(this.settings.currencySymbol).concat(l.join(".*?")));e=i.match(e);e?(r=e[0].length,(0===(r=this.settings.showPositiveSign&&0===(r=0===r&&e.input.charAt(0)===this.settings.positiveSignCharacter?1===e.input.indexOf(this.settings.currencySymbol)?this.settings.currencySymbol.length+1:1:r)&&e.input.charAt(this.settings.currencySymbol.length)===this.settings.positiveSignCharacter?this.settings.currencySymbol.length+1:r)&&i.charAt(0)!==this.settings.negativeSignCharacter||1===r&&i.charAt(0)===this.settings.negativeSignCharacter)&&this.settings.currencySymbol&&this.settings.currencySymbolPlacement===I.options.currencySymbolPlacement.prefix&&(r=this.settings.currencySymbol.length+(Er.isNegativeStrict(i,this.settings.negativeSignCharacter)?1:0))):(this.settings.currencySymbol&&this.settings.currencySymbolPlacement===I.options.currencySymbolPlacement.suffix&&(r-=this.settings.currencySymbol.length),this.settings.suffixText&&(r-=this.settings.suffixText.length))}i!==t&&(this._setElementValue(i,!1),this._setCaretPosition(r)),this.formatted=!0}}])&&Rr(e.prototype,t),n&&Rr(e,n),I}();function jr(e,t){t=t||{bubbles:!1,cancelable:!1,detail:void 0};var n=document.createEvent("CustomEvent");return n.initCustomEvent(e,t.bubbles,t.cancelable,t.detail),n}Br.multiple=function(e){var n=1<arguments.length&&void 0!==arguments[1]?arguments[1]:null,t=2<arguments.length&&void 0!==arguments[2]?arguments[2]:null,i=[];if(Er.isObject(n)&&(t=n,n=null),Er.isString(e)?e=Lr(document.querySelectorAll(e)):Er.isObject(e)?(Object.prototype.hasOwnProperty.call(e,"rootElement")||Er.throwError("The object passed to the 'multiple' function is invalid ; no 'rootElement' attribute found."),o=Lr(e.rootElement.querySelectorAll("input")),e=Object.prototype.hasOwnProperty.call(e,"exclude")?(Array.isArray(e.exclude)||Er.throwError("The 'exclude' array passed to the 'multiple' function is invalid."),Er.filterOut(o,e.exclude)):o):Er.isArray(e)||Er.throwError("The given parameters to the 'multiple' function are invalid."),0===e.length){var r=!0;return!Er.isNull(t)&&Er.isBoolean(t.showWarnings)&&(r=t.showWarnings),Er.warning("No valid DOM elements were given hence no AutoNumeric objects were instantiated.",r),[]}var o=Er.isArray(n)&&1<=n.length,s=!1,r=!1;o&&(a=zr(Number(n[0])),(s="number"===a&&!isNaN(Number(n[0])))||"string"!==a&&!isNaN(a)&&"object"!==a||(r=!0));var a,l,o=!1;Er.isArray(t)&&1<=t.length&&("string"!==(a=zr(t[0]))&&"object"!==a||(o=!0)),l=r?Br.mergeOptions(n):o?Br.mergeOptions(t):t;var c,u=Er.isNumber(n);return s&&(c=n.length),e.forEach(function(e,t){u?i.push(new Br(e,n,l)):s&&t<=c?i.push(new Br(e,n[t],l)):i.push(new Br(e,null,l))}),i},Array.from||(Array.from=function(e){return[].slice.call(e)}),"undefined"!=typeof window&&"function"!=typeof window.CustomEvent&&(jr.prototype=window.Event.prototype,window.CustomEvent=jr),Br.events={correctedValue:"autoNumeric:correctedValue",initialized:"autoNumeric:initialized",invalidFormula:"autoNumeric:invalidFormula",invalidValue:"autoNumeric:invalidValue",formatted:"autoNumeric:formatted",rawValueModified:"autoNumeric:rawValueModified",minRangeExceeded:"autoNumeric:minExceeded",maxRangeExceeded:"autoNumeric:maxExceeded",native:{input:"input",change:"change"},validFormula:"autoNumeric:validFormula"},Object.freeze(Br.events.native),Object.freeze(Br.events),Object.defineProperty(Br,"events",{configurable:!1,writable:!1}),Br.options={allowDecimalPadding:{always:!0,never:!1,floats:"floats"},alwaysAllowDecimalCharacter:{alwaysAllow:!0,doNotAllow:!1},caretPositionOnFocus:{start:"start",end:"end",decimalLeft:"decimalLeft",decimalRight:"decimalRight",doNoForceCaretPosition:null},createLocalList:{createList:!0,doNotCreateList:!1},currencySymbol:{none:"",currencySign:"¤",austral:"₳",australCentavo:"¢",baht:"฿",cedi:"₵",cent:"¢",colon:"₡",cruzeiro:"₢",dollar:"$",dong:"₫",drachma:"₯",dram:"​֏",european:"₠",euro:"€",florin:"ƒ",franc:"₣",guarani:"₲",hryvnia:"₴",kip:"₭",att:"ອັດ",lepton:"Λ.",lira:"₺",liraOld:"₤",lari:"₾",mark:"ℳ",mill:"₥",naira:"₦",peseta:"₧",peso:"₱",pfennig:"₰",pound:"£",real:"R$",riel:"៛",ruble:"₽",rupee:"₹",rupeeOld:"₨",shekel:"₪",shekelAlt:"ש״ח‎‎",taka:"৳",tenge:"₸",togrog:"₮",won:"₩",yen:"¥"},currencySymbolPlacement:{prefix:"p",suffix:"s"},decimalCharacter:{comma:",",dot:".",middleDot:"·",arabicDecimalSeparator:"٫",decimalSeparatorKeySymbol:"⎖"},decimalCharacterAlternative:{none:null,comma:",",dot:"."},decimalPlaces:{none:0,one:1,two:2,three:3,four:4,five:5,six:6},decimalPlacesRawValue:{useDefault:null,none:0,one:1,two:2,three:3,four:4,five:5,six:6},decimalPlacesShownOnBlur:{useDefault:null,none:0,one:1,two:2,three:3,four:4,five:5,six:6},decimalPlacesShownOnFocus:{useDefault:null,none:0,one:1,two:2,three:3,four:4,five:5,six:6},defaultValueOverride:{doNotOverride:null},digitalGroupSpacing:{two:"2",twoScaled:"2s",three:"3",four:"4"},digitGroupSeparator:{comma:",",dot:".",normalSpace:" ",thinSpace:" ",narrowNoBreakSpace:" ",noBreakSpace:" ",noSeparator:"",apostrophe:"'",arabicThousandsSeparator:"٬",dotAbove:"˙",privateUseTwo:"’"},divisorWhenUnfocused:{none:null,percentage:100,permille:1e3,basisPoint:1e4},emptyInputBehavior:{focus:"focus",press:"press",always:"always",zero:"zero",min:"min",max:"max",null:"null"},eventBubbles:{bubbles:!0,doesNotBubble:!1},eventIsCancelable:{isCancelable:!0,isNotCancelable:!1},failOnUnknownOption:{fail:!0,ignore:!1},formatOnPageLoad:{format:!0,doNotFormat:!1},formulaMode:{enabled:!0,disabled:!1},historySize:{verySmall:5,small:10,medium:20,large:50,veryLarge:100,insane:Number.MAX_SAFE_INTEGER},invalidClass:"an-invalid",isCancellable:{cancellable:!0,notCancellable:!1},leadingZero:{allow:"allow",deny:"deny",keep:"keep"},maximumValue:{tenTrillions:"10000000000000",oneBillion:"1000000000",zero:"0"},minimumValue:{tenTrillions:"-10000000000000",oneBillion:"-1000000000",zero:"0"},modifyValueOnWheel:{modifyValue:!0,doNothing:!1},negativeBracketsTypeOnBlur:{parentheses:"(,)",brackets:"[,]",chevrons:"<,>",curlyBraces:"{,}",angleBrackets:"〈,〉",japaneseQuotationMarks:"｢,｣",halfBrackets:"⸤,⸥",whiteSquareBrackets:"⟦,⟧",quotationMarks:"‹,›",guillemets:"«,»",none:null},negativePositiveSignPlacement:{prefix:"p",suffix:"s",left:"l",right:"r",none:null},negativeSignCharacter:{hyphen:"-",minus:"−",heavyMinus:"➖",fullWidthHyphen:"－",circledMinus:"⊖",squaredMinus:"⊟",triangleMinus:"⨺",plusMinus:"±",minusPlus:"∓",dotMinus:"∸",minusTilde:"≂",not:"¬"},noEventListeners:{noEvents:!0,addEvents:!1},onInvalidPaste:{error:"error",ignore:"ignore",clamp:"clamp",truncate:"truncate",replace:"replace"},outputFormat:{string:"string",number:"number",dot:".",negativeDot:"-.",comma:",",negativeComma:"-,",dotNegative:".-",commaNegative:",-",none:null},overrideMinMaxLimits:{ceiling:"ceiling",floor:"floor",ignore:"ignore",invalid:"invalid",doNotOverride:null},positiveSignCharacter:{plus:"+",fullWidthPlus:"＋",heavyPlus:"➕",doublePlus:"⧺",triplePlus:"⧻",circledPlus:"⊕",squaredPlus:"⊞",trianglePlus:"⨹",plusMinus:"±",minusPlus:"∓",dotPlus:"∔",altHebrewPlus:"﬩",normalSpace:" ",thinSpace:" ",narrowNoBreakSpace:" ",noBreakSpace:" "},rawValueDivisor:{none:null,percentage:100,permille:1e3,basisPoint:1e4},readOnly:{readOnly:!0,readWrite:!1},roundingMethod:{halfUpSymmetric:"S",halfUpAsymmetric:"A",halfDownSymmetric:"s",halfDownAsymmetric:"a",halfEvenBankersRounding:"B",upRoundAwayFromZero:"U",downRoundTowardZero:"D",toCeilingTowardPositiveInfinity:"C",toFloorTowardNegativeInfinity:"F",toNearest05:"N05",toNearest05Alt:"CHF",upToNext05:"U05",downToNext05:"D05"},saveValueToSessionStorage:{save:!0,doNotSave:!1},selectNumberOnly:{selectNumbersOnly:!0,selectAll:!1},selectOnFocus:{select:!0,doNotSelect:!1},serializeSpaces:{plus:"+",percent:"%20"},showOnlyNumbersOnFocus:{onlyNumbers:!0,showAll:!1},showPositiveSign:{show:!0,hide:!1},showWarnings:{show:!0,hide:!1},styleRules:{none:null,positiveNegative:{positive:"autoNumeric-positive",negative:"autoNumeric-negative"},range0To100With4Steps:{ranges:[{min:0,max:25,class:"autoNumeric-red"},{min:25,max:50,class:"autoNumeric-orange"},{min:50,max:75,class:"autoNumeric-yellow"},{min:75,max:100,class:"autoNumeric-green"}]},evenOdd:{userDefined:[{callback:function(e){return e%2==0},classes:["autoNumeric-even","autoNumeric-odd"]}]},rangeSmallAndZero:{userDefined:[{callback:function(e){return-1<=e&&e<0?0:0===Number(e)?1:0<e&&e<=1?2:null},classes:["autoNumeric-small-negative","autoNumeric-zero","autoNumeric-small-positive"]}]}},suffixText:{none:"",percentage:"%",permille:"‰",basisPoint:"‱"},symbolWhenUnfocused:{none:null,percentage:"%",permille:"‰",basisPoint:"‱"},unformatOnHover:{unformat:!0,doNotUnformat:!1},unformatOnSubmit:{unformat:!0,keepCurrentValue:!1},valuesToStrings:{none:null,zeroDash:{0:"-"},oneAroundZero:{"-1":"Min",1:"Max"}},watchExternalChanges:{watch:!0,doNotWatch:!1},wheelOn:{focus:"focus",hover:"hover"},wheelStep:{progressive:"progressive"}},Dr=Br.options,Object.getOwnPropertyNames(Dr).forEach(function(e){"valuesToStrings"===e?Object.getOwnPropertyNames(Dr.valuesToStrings).forEach(function(e){Er.isIE11()||null===Dr.valuesToStrings[e]||Object.freeze(Dr.valuesToStrings[e])}):"styleRules"!==e&&(Er.isIE11()||null===Dr[e]||Object.freeze(Dr[e]))}),Object.freeze(Dr),Object.defineProperty(Br,"options",{configurable:!1,writable:!1}),Br.defaultSettings={allowDecimalPadding:Br.options.allowDecimalPadding.always,alwaysAllowDecimalCharacter:Br.options.alwaysAllowDecimalCharacter.doNotAllow,caretPositionOnFocus:Br.options.caretPositionOnFocus.doNoForceCaretPosition,createLocalList:Br.options.createLocalList.createList,currencySymbol:Br.options.currencySymbol.none,currencySymbolPlacement:Br.options.currencySymbolPlacement.prefix,decimalCharacter:Br.options.decimalCharacter.dot,decimalCharacterAlternative:Br.options.decimalCharacterAlternative.none,decimalPlaces:Br.options.decimalPlaces.two,decimalPlacesRawValue:Br.options.decimalPlacesRawValue.useDefault,decimalPlacesShownOnBlur:Br.options.decimalPlacesShownOnBlur.useDefault,decimalPlacesShownOnFocus:Br.options.decimalPlacesShownOnFocus.useDefault,defaultValueOverride:Br.options.defaultValueOverride.doNotOverride,digitalGroupSpacing:Br.options.digitalGroupSpacing.three,digitGroupSeparator:Br.options.digitGroupSeparator.comma,divisorWhenUnfocused:Br.options.divisorWhenUnfocused.none,emptyInputBehavior:Br.options.emptyInputBehavior.focus,eventBubbles:Br.options.eventBubbles.bubbles,eventIsCancelable:Br.options.eventIsCancelable.isCancelable,failOnUnknownOption:Br.options.failOnUnknownOption.ignore,formatOnPageLoad:Br.options.formatOnPageLoad.format,formulaMode:Br.options.formulaMode.disabled,historySize:Br.options.historySize.medium,invalidClass:Br.options.invalidClass,isCancellable:Br.options.isCancellable.cancellable,leadingZero:Br.options.leadingZero.deny,maximumValue:Br.options.maximumValue.tenTrillions,minimumValue:Br.options.minimumValue.tenTrillions,modifyValueOnWheel:Br.options.modifyValueOnWheel.modifyValue,negativeBracketsTypeOnBlur:Br.options.negativeBracketsTypeOnBlur.none,negativePositiveSignPlacement:Br.options.negativePositiveSignPlacement.none,negativeSignCharacter:Br.options.negativeSignCharacter.hyphen,noEventListeners:Br.options.noEventListeners.addEvents,onInvalidPaste:Br.options.onInvalidPaste.error,outputFormat:Br.options.outputFormat.none,overrideMinMaxLimits:Br.options.overrideMinMaxLimits.doNotOverride,positiveSignCharacter:Br.options.positiveSignCharacter.plus,rawValueDivisor:Br.options.rawValueDivisor.none,readOnly:Br.options.readOnly.readWrite,roundingMethod:Br.options.roundingMethod.halfUpSymmetric,saveValueToSessionStorage:Br.options.saveValueToSessionStorage.doNotSave,selectNumberOnly:Br.options.selectNumberOnly.selectNumbersOnly,selectOnFocus:Br.options.selectOnFocus.select,serializeSpaces:Br.options.serializeSpaces.plus,showOnlyNumbersOnFocus:Br.options.showOnlyNumbersOnFocus.showAll,showPositiveSign:Br.options.showPositiveSign.hide,showWarnings:Br.options.showWarnings.show,styleRules:Br.options.styleRules.none,suffixText:Br.options.suffixText.none,symbolWhenUnfocused:Br.options.symbolWhenUnfocused.none,unformatOnHover:Br.options.unformatOnHover.unformat,unformatOnSubmit:Br.options.unformatOnSubmit.keepCurrentValue,valuesToStrings:Br.options.valuesToStrings.none,watchExternalChanges:Br.options.watchExternalChanges.doNotWatch,wheelOn:Br.options.wheelOn.focus,wheelStep:Br.options.wheelStep.progressive},Object.freeze(Br.defaultSettings),Object.defineProperty(Br,"defaultSettings",{configurable:!1,writable:!1});var Ur={digitGroupSeparator:Br.options.digitGroupSeparator.dot,decimalCharacter:Br.options.decimalCharacter.comma,decimalCharacterAlternative:Br.options.decimalCharacterAlternative.dot,currencySymbol:" €",currencySymbolPlacement:Br.options.currencySymbolPlacement.suffix,negativePositiveSignPlacement:Br.options.negativePositiveSignPlacement.prefix},Wr={digitGroupSeparator:Br.options.digitGroupSeparator.comma,decimalCharacter:Br.options.decimalCharacter.dot,currencySymbol:Br.options.currencySymbol.dollar,currencySymbolPlacement:Br.options.currencySymbolPlacement.prefix,negativePositiveSignPlacement:Br.options.negativePositiveSignPlacement.right},Hr={digitGroupSeparator:Br.options.digitGroupSeparator.comma,decimalCharacter:Br.options.decimalCharacter.dot,currencySymbol:Br.options.currencySymbol.yen,currencySymbolPlacement:Br.options.currencySymbolPlacement.prefix,negativePositiveSignPlacement:Br.options.negativePositiveSignPlacement.right};Er.cloneObject(Ur).formulaMode=Br.options.formulaMode.enabled;H=Er.cloneObject(Ur);H.minimumValue=0;he=Er.cloneObject(Ur);he.maximumValue=0,he.negativePositiveSignPlacement=Br.options.negativePositiveSignPlacement.prefix;ce=Er.cloneObject(Ur);ce.digitGroupSeparator=Br.options.digitGroupSeparator.normalSpace;_e=Er.cloneObject(ce);_e.minimumValue=0;we=Er.cloneObject(ce);we.maximumValue=0,we.negativePositiveSignPlacement=Br.options.negativePositiveSignPlacement.prefix;ae=Er.cloneObject(Ur);ae.currencySymbol=Br.options.currencySymbol.none,ae.suffixText=" ".concat(Br.options.suffixText.percentage),ae.wheelStep=1e-4,ae.rawValueDivisor=Br.options.rawValueDivisor.percentage;Ce=Er.cloneObject(ae);Ce.minimumValue=0;Te=Er.cloneObject(ae);Te.maximumValue=0,Te.negativePositiveSignPlacement=Br.options.negativePositiveSignPlacement.prefix;Z=Er.cloneObject(ae);Z.decimalPlaces=3;wt=Er.cloneObject(Ce);wt.decimalPlaces=3;r=Er.cloneObject(Te);r.decimalPlaces=3,Er.cloneObject(Wr).formulaMode=Br.options.formulaMode.enabled;var Gr=Er.cloneObject(Wr);Gr.minimumValue=0;var Kr=Er.cloneObject(Wr);Kr.maximumValue=0,Kr.negativePositiveSignPlacement=Br.options.negativePositiveSignPlacement.prefix;var qr=Er.cloneObject(Kr);qr.negativeBracketsTypeOnBlur=Br.options.negativeBracketsTypeOnBlur.parentheses;qn=Er.cloneObject(Wr);qn.currencySymbol=Br.options.currencySymbol.none,qn.suffixText=Br.options.suffixText.percentage,qn.wheelStep=1e-4,qn.rawValueDivisor=Br.options.rawValueDivisor.percentage;var Zr=Er.cloneObject(qn);Zr.minimumValue=0;yi=Er.cloneObject(qn);yi.maximumValue=0,yi.negativePositiveSignPlacement=Br.options.negativePositiveSignPlacement.prefix;Ri=Er.cloneObject(qn);Ri.decimalPlaces=3;tr=Er.cloneObject(Zr);tr.decimalPlaces=3;var $r=Er.cloneObject(yi);$r.decimalPlaces=3;var Qr=Er.cloneObject(Ur);Qr.currencySymbol=Br.options.currencySymbol.lira,Br.predefinedOptions={euro:Ur,euroPos:H,euroNeg:he,euroSpace:ce,euroSpacePos:_e,euroSpaceNeg:we,percentageEU2dec:ae,percentageEU2decPos:Ce,percentageEU2decNeg:Te,percentageEU3dec:Z,percentageEU3decPos:wt,percentageEU3decNeg:r,dollar:Wr,dollarPos:Gr,dollarNeg:Kr,dollarNegBrackets:qr,percentageUS2dec:qn,percentageUS2decPos:Zr,percentageUS2decNeg:yi,percentageUS3dec:Ri,percentageUS3decPos:tr,percentageUS3decNeg:$r,French:Ur,Spanish:Ur,NorthAmerican:Wr,British:{digitGroupSeparator:Br.options.digitGroupSeparator.comma,decimalCharacter:Br.options.decimalCharacter.dot,currencySymbol:Br.options.currencySymbol.pound,currencySymbolPlacement:Br.options.currencySymbolPlacement.prefix,negativePositiveSignPlacement:Br.options.negativePositiveSignPlacement.right},Swiss:{digitGroupSeparator:Br.options.digitGroupSeparator.apostrophe,decimalCharacter:Br.options.decimalCharacter.dot,currencySymbol:" CHF",currencySymbolPlacement:Br.options.currencySymbolPlacement.suffix,negativePositiveSignPlacement:Br.options.negativePositiveSignPlacement.prefix},Japanese:Hr,Chinese:Hr,Brazilian:{digitGroupSeparator:Br.options.digitGroupSeparator.dot,decimalCharacter:Br.options.decimalCharacter.comma,currencySymbol:Br.options.currencySymbol.real,currencySymbolPlacement:Br.options.currencySymbolPlacement.prefix,negativePositiveSignPlacement:Br.options.negativePositiveSignPlacement.right},Turkish:Qr,dotDecimalCharCommaSeparator:{digitGroupSeparator:Br.options.digitGroupSeparator.comma,decimalCharacter:Br.options.decimalCharacter.dot},commaDecimalCharDotSeparator:{digitGroupSeparator:Br.options.digitGroupSeparator.dot,decimalCharacter:Br.options.decimalCharacter.comma,decimalCharacterAlternative:Br.options.decimalCharacterAlternative.dot},integer:{decimalPlaces:0},integerPos:{minimumValue:Br.options.minimumValue.zero,decimalPlaces:0},integerNeg:{maximumValue:Br.options.maximumValue.zero,decimalPlaces:0},float:{allowDecimalPadding:Br.options.allowDecimalPadding.never},floatPos:{allowDecimalPadding:Br.options.allowDecimalPadding.never,minimumValue:Br.options.minimumValue.zero,maximumValue:Br.options.maximumValue.tenTrillions},floatNeg:{allowDecimalPadding:Br.options.allowDecimalPadding.never,minimumValue:Br.options.minimumValue.tenTrillions,maximumValue:Br.options.maximumValue.zero},numeric:{digitGroupSeparator:Br.options.digitGroupSeparator.noSeparator,decimalCharacter:Br.options.decimalCharacter.dot,currencySymbol:Br.options.currencySymbol.none},numericPos:{digitGroupSeparator:Br.options.digitGroupSeparator.noSeparator,decimalCharacter:Br.options.decimalCharacter.dot,currencySymbol:Br.options.currencySymbol.none,minimumValue:Br.options.minimumValue.zero,maximumValue:Br.options.maximumValue.tenTrillions},numericNeg:{digitGroupSeparator:Br.options.digitGroupSeparator.noSeparator,decimalCharacter:Br.options.decimalCharacter.dot,currencySymbol:Br.options.currencySymbol.none,minimumValue:Br.options.minimumValue.tenTrillions,maximumValue:Br.options.maximumValue.zero}},Object.getOwnPropertyNames(Br.predefinedOptions).forEach(function(e){Object.freeze(Br.predefinedOptions[e])}),Object.freeze(Br.predefinedOptions),Object.defineProperty(Br,"predefinedOptions",{configurable:!1,writable:!1});var Jr=Object.freeze({__proto__:null,default:Br}),yi=(Object.defineProperty(Yr.prototype,"value",{get:function(){return this._value},set:function(e){if(e!==this._lastvalue)if(!V()&&this._Numeric)this._Numeric.set(null!=e?e:"");else{var t="",n="";switch(this.numeric_style){case"percentageUS2decPos":n="%";break;case"dollarPos":t="$"}null!=e?this._render.setProperty(this._el.nativeElement,"value",n+k(e,1,t)):this._render.setProperty(this._el.nativeElement,"value","")}this._value=e,this._lastvalue=e},enumerable:!1,configurable:!0}),Object.defineProperty(Yr.prototype,"min",{get:function(){return this._min},set:function(e){this._min=e,this._Numeric&&this._Numeric.update({minimumValue:e})},enumerable:!1,configurable:!0}),Object.defineProperty(Yr.prototype,"max",{get:function(){return this._max},set:function(e){var t=this;this._max=e,this._Numeric&&this._value&&this._value>this._max&&(this._Numeric.set(this._max),this._value=this._max,setTimeout(function(){t._valueUpdate.next(t._max)}))},enumerable:!1,configurable:!0}),Yr.prototype._OnInput=function(e){e.detail.newRawValue!==e.detail.oldRawValue&&this._valueUpdate.next(e.detail.newRawValue)},Yr.prototype.ngAfterViewInit=function(){var e,t,n,i=this;V()||(e=this.options,t=Br||Jr,this.numeric_style&&(e=Object.assign({},t.getPredefinedOptions()[this.numeric_style],this._def_options,e)),"percentageUS2decPos"==this.numeric_style&&(e.rawValueDivisor=null),this._Numeric=new t(this._el.nativeElement,e),this._Numeric.set(null!=this.value?this.value:""),this._Numeric.update({minimumValue:this.min}),this._el.nativeElement.addEventListener("autoNumeric:formatted",this._OnInput.bind(this)),t=this._valueUpdate,n=(t=e.delay?this._valueUpdate.pipe(u.debounceTime(e.delay)):t).subscribe(function(e){var t=E(e);if(w(t)){if(t>i._max)return void setTimeout(function(){t=i._max,i._lastvalue=t,i.numericInput.emit(t),i._Numeric.set(i._max)},100)}else t=e;i._lastvalue=t,i.numericInput.emit(t)},function(){},function(){n&&n.unsubscribe()}))},Yr.prototype.ngOnDestroy=function(){this._valueUpdate.complete(),this._Numeric&&(this._Numeric.remove(),this._Numeric=null),this._el.nativeElement.removeEventListener("autoNumeric:formatted",this._OnInput)},Yr.ɵfac=function(e){return new(e||Yr)(u.ɵɵdirectiveInject(u.ElementRef),u.ɵɵdirectiveInject(u.Renderer2))},Yr.ɵdir=u.ɵɵdefineDirective({type:Yr,selectors:[["","ng-numeric",""]],inputs:{options:["nr-options","options"],numeric_style:["nr-style","numeric_style"],value:["nr-value","value"],min:["nr-min","min"],max:["nr-max","max"]},outputs:{numericInput:"nrInput"}}),Yr);function Yr(e,t){this._el=e,this._render=t,this._def_options={historySize:5,allowDecimalPadding:!1,emptyInputBehavior:"focus",delay:100,showWarnings:!1},this.numeric_style="dollarPos",this._valueUpdate=new u.Subject,this.numericInput=new u.EventEmitter,this._min=0,this._max=1e6,this.options=L(this._def_options)}u.setClassMetadata(yi,[{type:u.Directive,args:[{selector:"[ng-numeric]"}]}],function(){return[{type:u.ElementRef},{type:u.Renderer2}]},{options:[{type:u.Input,args:["nr-options"]}],numeric_style:[{type:u.Input,args:["nr-style"]}],value:[{type:u.Input,args:["nr-value"]}],numericInput:[{type:u.Output,args:["nrInput"]}],min:[{type:u.Input,args:["nr-min"]}],max:[{type:u.Input,args:["nr-max"]}]});Xr.ɵmod=u.ɵɵdefineNgModule({type:Xr}),Xr.ɵinj=u.ɵɵdefineInjector({factory:function(e){return new(e||Xr)},imports:[[u.CommonModule]]}),Ri=Xr;function Xr(){}u.setClassMetadata(Ri,[{type:u.NgModule,args:[{declarations:[yi],exports:[yi],imports:[u.CommonModule]}]}],null,null);Object.defineProperty(eo.prototype,"show",{get:function(){return this._show},set:function(e){var t=this;e?(t._show=e,t._showtimeout&&clearTimeout(t._showtimeout),t._showtimeout=setTimeout(function(){t._show=!1,t._cd.detectChanges(),t.onhidden.emit()},t.timer)):t.close_on_change&&t._showtimeout&&(clearTimeout(t._showtimeout),t._show=!1,t.onhidden.emit()),t._cd.detectChanges()},enumerable:!1,configurable:!0}),eo.prototype.ngOnDestroy=function(){clearTimeout(this._showtimeout)},eo.ɵfac=function(e){return new(e||eo)(u.ɵɵdirectiveInject(u.ChangeDetectorRef))},eo.ɵcmp=u.ɵɵdefineComponent({type:eo,selectors:[["error-toast"]],hostVars:2,hostBindings:function(e,t){2&e&&u.ɵɵclassProp("error-toast-center",t.center)},inputs:{timer:"timer",message:"message",close_on_change:["close-on-change","close_on_change"],show:"show",center:"center"},outputs:{onhidden:"onhidden"},decls:2,vars:2,consts:[[1,"errortoast",3,"ng-hidden"]],template:function(e,t){1&e&&(u.ɵɵelementStart(0,"div",0),u.ɵɵtext(1),u.ɵɵelementEnd()),2&e&&(u.ɵɵproperty("ng-hidden",!t.show),u.ɵɵadvance(1),u.ɵɵtextInterpolate(t.message))},directives:[fe],encapsulation:2}),tr=eo;function eo(e){this._cd=e,this.timer=2500,this.message="something went wrong, please retry",this.close_on_change=!1,this.onhidden=new u.EventEmitter,this._show=!1,this.center=!1}u.setClassMetadata(tr,[{type:u.Component,args:[{selector:"error-toast",template:'<div class="errortoast" [ng-hidden]="!show">{{message}}</div>',host:{"[class.error-toast-center]":"center"}}]}],function(){return[{type:u.ChangeDetectorRef}]},{timer:[{type:u.Input}],message:[{type:u.Input}],close_on_change:[{type:u.Input,args:["close-on-change"]}],onhidden:[{type:u.Output}],show:[{type:u.Input}],center:[{type:u.Input}]});to.ɵmod=u.ɵɵdefineNgModule({type:to}),to.ɵinj=u.ɵɵdefineInjector({factory:function(e){return new(e||to)},imports:[[u.CommonModule,Fe]]}),$r=to;function to(){}u.setClassMetadata($r,[{type:u.NgModule,args:[{declarations:[tr],exports:[tr],imports:[u.CommonModule,Fe]}]}],null,null);var Ur=["hotelcalculator",""],Wr=["airlinecalculator",""],no=(io.prototype._showError=function(e){var t=this;this.api_message=e,this.api_error=!1,setTimeout(function(){t.api_error=!0})},io.prototype.Calculate=function(){var t=this;if(!w(this.field_value))return this._showError("Please enter a value"),this.api_error=!1,void setTimeout(function(){t.api_error=!0});this.input_updating=!0,it({method:"GET",url:Ue(),data:{action:"Calculators."+this._ajaxdir,input:this.field_value},before:function(){t.input_updating=!0},after:function(){t.input_updating=!1}}).then(function(e){if(!e||e.error||!e.message)throw new Error("error");e=e.message;"Best"in e&&("#REF!"==e.Best.name&&(e.Best.name="N/A"),"#REF!"==e.Best.value&&(e.Best.value="N/A"),t.best_program=e.Best.name,t.best_program_score=e.Best.value),"RunnerUp"in e&&("#REF!"==e.RunnerUp.name&&(e.RunnerUp.name="N/A"),"#REF!"==e.RunnerUp.value&&(e.RunnerUp.value="N/A"),t.runn_program=e.RunnerUp.name,t.runn_program_score=e.RunnerUp.value)}).catch(function(){t._showError("something went wrong, please retry")})},io.ɵfac=function(e){return new(e||io)},io.ɵcmp=u.ɵɵdefineComponent({type:io,selectors:[["div","hotelcalculator",""]],hostAttrs:[1,"ch-edu-calc"],attrs:Ur,decls:24,vars:12,consts:[[1,"ch-edu-calc-container"],[1,"ch-edu-calc-header"],[1,"ch-edu-calc-label"],[1,"ch-edu-calc-input"],["type","text","ng-numeric","",1,"numeric-input",3,"nr-value","nrInput"],["zing-touch","",1,"btn","purple","no-decoration","with-loader",3,"disabled","onTap"],[1,"btn-loader"],[1,"bt-text"],[3,"center","show","message"],[1,"ch-edu-calc-body"],[1,"ch-edu-calc-box"],[1,"ch-edu-calc-title",3,"ng-context"],[1,"ch-edu-calc-content"]],template:function(e,t){1&e&&(u.ɵɵelementStart(0,"div",0),u.ɵɵelementStart(1,"div",1),u.ɵɵelementStart(2,"div",2),u.ɵɵtext(3),u.ɵɵelementEnd(),u.ɵɵelementStart(4,"div",3),u.ɵɵelementStart(5,"input",4),u.ɵɵlistener("nrInput",function(e){return t.field_value=e}),u.ɵɵelementEnd(),u.ɵɵelementStart(6,"button",5),u.ɵɵlistener("onTap",function(){return t.Calculate()}),u.ɵɵelement(7,"i",6),u.ɵɵelementStart(8,"span",7),u.ɵɵtext(9,"Update"),u.ɵɵelementEnd(),u.ɵɵelementEnd(),u.ɵɵelement(10,"error-toast",8),u.ɵɵelementEnd(),u.ɵɵelementEnd(),u.ɵɵelementStart(11,"div",9),u.ɵɵelementStart(12,"div",10),u.ɵɵelementStart(13,"div",2),u.ɵɵtext(14,"Best Program"),u.ɵɵelementEnd(),u.ɵɵelement(15,"div",11),u.ɵɵelementStart(16,"div",12),u.ɵɵtext(17),u.ɵɵelementEnd(),u.ɵɵelementEnd(),u.ɵɵelementStart(18,"div",10),u.ɵɵelementStart(19,"div",2),u.ɵɵtext(20,"Runner Up"),u.ɵɵelementEnd(),u.ɵɵelement(21,"div",11),u.ɵɵelementStart(22,"div",12),u.ɵɵtext(23),u.ɵɵelementEnd(),u.ɵɵelementEnd(),u.ɵɵelementEnd(),u.ɵɵelementEnd()),2&e&&(u.ɵɵadvance(3),u.ɵɵtextInterpolate(t.title),u.ɵɵadvance(2),u.ɵɵproperty("nr-value",t.field_value),u.ɵɵadvance(1),u.ɵɵclassProp("loadactive",t.input_updating),u.ɵɵproperty("disabled",t.input_updating),u.ɵɵadvance(4),u.ɵɵproperty("center",!0)("show",t.api_error)("message",t.api_message),u.ɵɵadvance(5),u.ɵɵproperty("ng-context",t.best_program),u.ɵɵadvance(2),u.ɵɵtextInterpolate1("WalletHub Score: ",t.best_program_score,""),u.ɵɵadvance(4),u.ɵɵproperty("ng-context",t.runn_program),u.ɵɵadvance(2),u.ɵɵtextInterpolate1("WalletHub Score: ",t.runn_program_score,""))},directives:[yi,K,tr,Pe],encapsulation:2}),io);function io(){this.field_value=1e3,this.api_message="Please enter a value",this._ajaxdir="Hotelrewards",this.best_program="Wyndham Rewards",this.best_program_score="72.07",this.runn_program="Radisson Rewards",this.runn_program_score="64.36",this.title="Annual Amount Spent On Hotel Stays"}u.setClassMetadata(no,[{type:u.Component,args:[{selector:"div[hotelcalculator]",templateUrl:"/views/components/shortcodes/hotelcalculator.html",host:{class:"ch-edu-calc"}}]}],null,null);var ro,oo=(ro=no,__extends(so,ro),so.ɵfac=function(e){return ao(e||so)},so.ɵcmp=u.ɵɵdefineComponent({type:so,selectors:[["div","airlinecalculator",""]],hostAttrs:[1,"ch-edu-calc","airline"],features:[u.ɵɵInheritDefinitionFeature],attrs:Wr,decls:24,vars:12,consts:[[1,"ch-edu-calc-container"],[1,"ch-edu-calc-header"],[1,"ch-edu-calc-label"],[1,"ch-edu-calc-input"],["type","text","ng-numeric","",1,"numeric-input",3,"nr-value","nrInput"],["zing-touch","",1,"btn","purple","no-decoration","with-loader",3,"disabled","onTap"],[1,"btn-loader"],[1,"bt-text"],[3,"center","show","message"],[1,"ch-edu-calc-body"],[1,"ch-edu-calc-box"],[1,"ch-edu-calc-title",3,"ng-context"],[1,"ch-edu-calc-content"]],template:function(e,t){1&e&&(u.ɵɵelementStart(0,"div",0),u.ɵɵelementStart(1,"div",1),u.ɵɵelementStart(2,"div",2),u.ɵɵtext(3),u.ɵɵelementEnd(),u.ɵɵelementStart(4,"div",3),u.ɵɵelementStart(5,"input",4),u.ɵɵlistener("nrInput",function(e){return t.field_value=e}),u.ɵɵelementEnd(),u.ɵɵelementStart(6,"button",5),u.ɵɵlistener("onTap",function(){return t.Calculate()}),u.ɵɵelement(7,"i",6),u.ɵɵelementStart(8,"span",7),u.ɵɵtext(9,"Update"),u.ɵɵelementEnd(),u.ɵɵelementEnd(),u.ɵɵelement(10,"error-toast",8),u.ɵɵelementEnd(),u.ɵɵelementEnd(),u.ɵɵelementStart(11,"div",9),u.ɵɵelementStart(12,"div",10),u.ɵɵelementStart(13,"div",2),u.ɵɵtext(14,"Best Program"),u.ɵɵelementEnd(),u.ɵɵelement(15,"div",11),u.ɵɵelementStart(16,"div",12),u.ɵɵtext(17),u.ɵɵelementEnd(),u.ɵɵelementEnd(),u.ɵɵelementStart(18,"div",10),u.ɵɵelementStart(19,"div",2),u.ɵɵtext(20,"Runner Up"),u.ɵɵelementEnd(),u.ɵɵelement(21,"div",11),u.ɵɵelementStart(22,"div",12),u.ɵɵtext(23),u.ɵɵelementEnd(),u.ɵɵelementEnd(),u.ɵɵelementEnd(),u.ɵɵelementEnd()),2&e&&(u.ɵɵadvance(3),u.ɵɵtextInterpolate(t.title),u.ɵɵadvance(2),u.ɵɵproperty("nr-value",t.field_value),u.ɵɵadvance(1),u.ɵɵclassProp("loadactive",t.input_updating),u.ɵɵproperty("disabled",t.input_updating),u.ɵɵadvance(4),u.ɵɵproperty("center",!0)("show",t.api_error)("message",t.api_message),u.ɵɵadvance(5),u.ɵɵproperty("ng-context",t.best_program),u.ɵɵadvance(2),u.ɵɵtextInterpolate1("WalletHub Score: ",t.best_program_score,""),u.ɵɵadvance(4),u.ɵɵproperty("ng-context",t.runn_program),u.ɵɵadvance(2),u.ɵɵtextInterpolate1("WalletHub Score: ",t.runn_program_score,""))},directives:[yi,K,tr,Pe],encapsulation:2}),so);function so(){var e=null!==ro&&ro.apply(this,arguments)||this;return e._ajaxdir="Airlines",e.title="Annual Amount Spent On Airline Travel",e.best_program="Southwest Airlines",e.best_program_score="61.93",e.runn_program="United Airlines",e.runn_program_score="57.66",e}var ao=u.ɵɵgetInheritedFactory(oo);u.setClassMetadata(oo,[{type:u.Component,args:[{selector:"div[airlinecalculator]",templateUrl:"/views/components/shortcodes/hotelcalculator.html",host:{class:"ch-edu-calc airline"}}]}],null,null);var lo=(co.ɵmod=u.ɵɵdefineNgModule({type:co}),co.ɵinj=u.ɵɵdefineInjector({factory:function(e){return new(e||co)},imports:[[u.CommonModule,Fe,Ri,$r]]}),co);function co(){}u.setClassMetadata(lo,[{type:u.NgModule,args:[{imports:[u.CommonModule,Fe,Ri,$r],declarations:[no,oo],exports:[no,oo],entryComponents:[no,oo]}]}],null,null);var uo=o("systemjs"),ho=(mo.prototype._JumpTo=function(e,t){void 0===t&&(t=!1);for(var n=e.target;n&&"a"!=n.tagName.toLowerCase()&&"body"!=n.tagName.toLowerCase();)n=n.parentNode;var i=n.getAttribute("data-jump-to");i&&((i=document.querySelector(".edu-art-content-table a[name="+i+"]"))&&this._scrollservice.scrollTo({target:i,timing:t?0:300}),e.preventDefault(),e.stopPropagation())},mo.prototype._ToDisclosure=function(e){e.preventDefault(),e.stopPropagation();var t,e=document.querySelector(".edu-page-disclaimer");e&&(this._scrollservice.scrollTo({target:e}),(t=document.querySelector(".ed-disc-ad"))&&(t.classList.add("ed-disc-yellow"),setTimeout(function(){t.classList.remove("ed-disc-yellow")},3500)))},mo.prototype._Expand=function(){1003<window.innerWidth||this.parentNode.classList.toggle("edu-sidebar-expand")},mo.prototype.InitiateSharing=function(){var t=this;uo.import("components:/bootstrap/edu/edu-share-ui-component").then(function(e){document.querySelector("article .edu-art-main .social-share-box")&&Fi(t._AppRef,t._Injector,t._compiler,e.NgEduShareUIModule,e.EduShareBox,"article .edu-art-main .social-share-box",{title:t._data.title,template:"v2"!=t._data.template?"v1":"v2"}).then(function(e){t._cleanups.push(e.destroy)}),document.querySelector("article .edu-art-sidebar .social-share-box")&&Fi(t._AppRef,t._Injector,t._compiler,e.NgEduShareUIModule,e.EduShareBox,"article .edu-art-sidebar .social-share-box",{title:t._data.title,permanent_sticky:!0,no_shares:!0}).then(function(e){t._cleanups.push(e.destroy)})})},mo.prototype.InitiateHelpful=function(){var t=this;uo.import("modules:/Pages/edu/edu-helpful").then(function(e){Fi(t._AppRef,t._Injector,t._compiler,e.NgEduHepfulModule,e.EduHepful,"div.helpful-article").then(function(e){t._cleanups.push(e.destroy)})})},mo.prototype.InitiateQnA=function(){var i=this;return this._qnaModule=this._qnaModule||Promise.all([uo.import("components:/qna-comp"),uo.import("components:/bootstrap/route-ui-module"),uo.import("css:/components/qna-comp.css")]).then(function(e){var t=e[0],n=e[1];return i._compiler.compileModuleAsync(n.RouterModule).then(function(e){e=e.create(i._Injector);return i._cleanups.push(e.destroy),Fi(e.injector.get(u.ApplicationRef),e.injector,i._compiler,t.QnAModule,t.QnAComp,"section#qna-box",{layout_type:1,toggleSchema:!0,ques_data:i._data.qnadata,page_query:"p",ques_referer:i._data.qnauri,section_title:i._data.qna_header}).then(function(e){i._cleanups.push(e.destroy)}),{routeRef:e,ActivatedRoute:n.ActivatedRoute}})}),this._qnaModule},mo.prototype.InitiateExperts=function(o){var s=this,a=document.querySelector("div[id=experts-gallery]");return a?(this._expertsModule=this._expertsModule||Promise.all([uo.import("components:/bootstrap/experts-gallery-ui-component"),uo.import("css:/components/experts-gallery.css")]).then(function(e){var r=e[0];return s.InitiateQnA().then(function(i){return new Promise(function(t,e){var n=i.routeRef.injector.get(i.ActivatedRoute);r.CompileExpertsGallery(s._AppRef,s._Injector,s._compiler,n,{data:s._data.experts,hashname:o}).then(function(e){try{o?(s._scrollservice.scrollTo({target:a,timing:0}).then(function(){j(function(){t()})}),s._cleanups.push(function(){e.destroy()})):t()}catch(e){t()}}).catch(e),setTimeout(function(){t()},1e3)})})}),this._expertsModule):Promise.resolve(null)},mo.prototype.InitiateExpertsDev=function(t){var n=this;document.querySelector("div[id=experts-gallery]")&&Promise.all([uo.import("components:/bootstrap/experts-gallery-ui-component"),uo.import("css:/components/experts-gallery.css")]).then(function(e){e[0].CompileExpertsGallery(n._AppRef,n._Injector,n._compiler,t,{data:n._data.experts,expert_offset:-100,back_bt_text:(n._data.experts||{}).back_link_text,more_btn_txt:(n._data.experts||{}).more_text,max_experts:6}).then(function(e){n._cleanups.push(function(){e.destroy()})})})},mo.prototype.InitiateTableSorting=function(){var e=document.querySelectorAll(".cardhub-edu-table.sortable");if(e&&0<e.length)for(var t=0,n=e.length;t<n;t++){var i=e[t],r=i.querySelectorAll("thead th");if(r&&0<r.length)for(var o=0,s=r.length;o<s;o++){var a,l=r[o];l.classList.contains("rank-numeric")?(l.setAttribute("data-sort-method","number"),(a=l.querySelector("p"))?a.innerHTML+=' <i class="rank-arrow"></i>':l.innerHTML+=' <i class="rank-arrow"></i>'):l.setAttribute("data-sort-method","none")}new Ji(i,{})}},mo.prototype.InitiateTableSearch=function(){var n=this;P(this._data.tablesearchdata,function(e){var t=e.id;Fi(n._AppRef,n._Injector,n._compiler,cr,ar,'[data-ts-id="'+t+'"]',{items:e.list,index:e.index}).then(function(e){n._cleanups.push(e.destroy)}).catch(function(e){})})},mo.prototype.InitiateTableSearchNode=function(){},mo.prototype.InitiateGeoCharts=function(){var f=this;if(this._data.charts){var v=this,t=new Yi(this._scrollservice,.2,1);this._cleanups.push(function(){t.Destroy()});var n=document.querySelectorAll(".chart-container"),e=!1,i=function(){e||(e=!0,uo.import("npm:google-charts/dist/googleCharts.js").then(function(e){var t=e.GoogleCharts;return new Promise(function(e){t.load(function(){e(t.api)})})}).then(function(g){g.charts.load("current",{packages:["corechart"].concat(f._data.charts.packages)}),g.charts.setOnLoadCallback(function(){T({geo:"GeoChart",pie:"PieChart",column:"ColumnChart",line:"LineChart",bubble:"BubbleChart"},function(d,m){if(!v._data.charts[m]||v._data.charts[m].length<1)return!0;for(var p=0,e=v._data.charts[m].length;p<e;p++)!function(){var t=v._data.charts[m][p];if("id"in t&&"data"in t&&"config"in t){if("ToolTip"==t.data[0][t.data[0].length-1]&&(t.data[0][t.data[0].length-1]={role:"tooltip",p:{html:!0}}),"line"==m&&2==t.data[0].length){t.data[0].push({type:"string",role:"style"});for(var e=1;e<t.data.length;e++)t.data[e].push("point {stroke-width: 2;  stroke-color: #fff; }")}var n=g.visualization.arrayToDataTable(t.data),i=document.querySelector("#"+t.id),r=new g.visualization[d](i);if(-1<["column","line","geo"].indexOf(m)&&"fmt"in t.config){var o=t.data[0].length;if("pattern"in t.config.fmt&&x(t.config.fmt.pattern)&&t.config.fmt.pattern.length==o)for(var s=0;s<o;s++)new g.visualization.NumberFormat({pattern:t.config.fmt.pattern[s]}).format(n,s);else{"geo"==m&&(t.config.firstColStr=!0);for(s=t.config.firstColStr?2:1;s<=o;s++)new g.visualization.NumberFormat(t.config.fmt).format(n,s-1)}}"geo"==m&&t.data[0].length<3&&(t.config.hasOwnProperty("displayMode")?t.config.hasOwnProperty("displayMode")&&t.config.displayMode:(t.config.colors=["#2CDBDB","#fff"],document.querySelector("head").innerHTML+="<style>#"+t.id+" path{ stroke:#555; }</style>")),delete t.config.fmt,t.config.chartArea=t.config.chartArea||{},t.config.chartArea.width="100%",t.config.chartArea.bottom="bottom"in t.config.chartArea?t.config.chartArea.bottom:200,"column"!=m&&"line"!=m&&"bubble"!=m||(t.config.explorer={actions:["dragToZoom","rightClickToReset"],axis:"horizontal",keepInBounds:!0,maxZoomIn:4}),!t.config.legend||t.config.legend.position&&"right"!=t.config.legend.position||(t.config.legend.position="bottom");var a=i.parentNode,l=a.querySelector(".progress-indicator");try{l&&a.removeChild(l)}catch(e){}var c=t.config.width,u=t.config.height;window.addEventListener("resize",h),setTimeout(function(){j(h)},Math.floor(31*Math.random())+30),f._cleanups.push(function(){window.removeEventListener("resize",h),r.clearChart()}),"column"==m||"line"==m||"bubble"==m?g.visualization.events.addListener(r,"ready",function(){var e=document.createElement("div");e.classList.add("left-border");var t=document.createElement("div");t.classList.add("right-border"),i.appendChild(e),i.appendChild(t),i.classList.add("ng-enter-element")}):g.visualization.events.addListener(r,"ready",function(){i.classList.add("ng-enter-element")})}function h(){var e=i.getBoundingClientRect();M(c)||(t.config.width=e.width),!M(u)&&"auto"!=u||("geo"!=m&&"auto"!==u?t.config.height=Math.max(e.height,500):delete t.config.height),r.draw(n,t.config)}}()})})}).catch(function(t){zn().then(function(e){e.captureException(t)})}))};if(n&&0<n.length)for(var r=0,o=n.length;r<o;r++)!function(e){t.Observe(n[e]).subscribe(function(){i(),t.Unobserve(n[e])})}(r)}},mo.prototype.InitiateMobileRelated=function(){var t=this,n=document.querySelectorAll(".edu-art-cross-links .edu-sd-exp");if(n)for(var i=this,r=0,e=n.length;r<e;r++)!function(){var e=n[r].querySelector(".edu-art-sidebar-title");e.addEventListener("click",i._Expand),i._cleanups.push(function(){e.removeEventListener("click",t._Expand)})}()},mo.prototype.InitiateFreeCreditModal=function(){var e,t=this;tt.get("mw_signon")&&lt.get("has-sess")||(e=document.createElement("free-credit"),document.body.appendChild(e),Fi(this._AppRef,this._Injector,this._compiler,mr,hr,"free-credit").then(function(e){t._cleanups.push(e.destroy)}))},mo.prototype.InitiateLazyNgModules=function(){var r=this;return this._lazyNgModules=this._lazyNgModules||Promise.all([uo.import("components:/bootstrap/edu/edu-share-ui-component"),uo.import("components:/bootstrap/experts-gallery-ui-component"),uo.import("css:/components/experts-gallery.css"),uo.import("components:/qna-comp"),uo.import("components:/bootstrap/route-ui-module"),uo.import("css:/components/qna-comp.css")]).then(function(){var t,n,i;r.InitiateTableSearch(),document.querySelector("div[id=experts-gallery]")&&r._data.experts?r.InitiateExperts():r.InitiateQnA(),t=r._AppRef,n=r._Injector,i=r._compiler,(0<document.querySelectorAll("div.car-insurance-widget").length?qi.import("components:/ci-shortcode").then(function(e){return Fi(t,n,i,e.NGCIShortCodeModule,e.CIShortCode,"div.car-insurance-widget")}):Promise.resolve(null)).then(function(e){e&&r._cleanups.push(e.destroy)})}),this._lazyNgModules},mo.prototype.Destroy=function(){this._cleanups.forEach(function(e){e()})},mo);function mo(e,t,n,i,r,o){var s=this;if(this._AppRef=e,this._Injector=t,this._compiler=n,this._renderFactory=i,this._scrollservice=r,this._data=o,this._cleanups=[],this._ToDisclosure=this._ToDisclosure.bind(this),!V()){o=document.querySelector(".edu-auth-avatar img");o&&this._cleanups.push(Gi(o,this._renderFactory));var a=document.querySelectorAll(".edu-art-content-table img[class*=wp-image-]");if(a&&0<a.length)for(var l=0,c=a.length;l<c;l++){var u=(d=a[l]).parentNode;u&&u.classList&&u.classList.contains("wp-image-defer")?this._cleanups.push(Ki(d,this._renderFactory)):this._cleanups.push(Gi(d,this._renderFactory))}var h=document.querySelectorAll(".cardhub-edu-img,.cc-section .shortcode-img");if(h&&0<h.length)for(l=0,c=h.length;l<c;l++){var d=h[l];this._cleanups.push(Ki(d,this._renderFactory))}var m=document.querySelectorAll('a[href^="#"]');if(m&&0<m.length){this._JumpTo=this._JumpTo.bind(this);for(var p=this,l=0,c=m.length;l<c;l++)!function(){var e=m[l];e.setAttribute("data-jump-to",e.getAttribute("href").substring(1)),e.addEventListener("click",p._JumpTo),p._cleanups.push(function(){e.removeEventListener("click",s._JumpTo)})}()}location.hash&&location.hash.indexOf("expert=")<0&&(E=location.hash.replace("#",""),(E=document.querySelector(".edu-art-content-table a[name="+E+"]"))&&this._scrollservice.scrollTo({target:E,timing:0}));var g=document.querySelector(".edu-article .edu-art-tnav-disc");g&&(g.addEventListener("click",this._ToDisclosure),this._cleanups.push(function(){g.removeEventListener("click",s._ToDisclosure)}));var f=document.querySelectorAll(".cardhub-edu-spnsrd.link");if(f&&f.length)for(var v=this,l=0,c=f.length;l<c;l++)!function(){var e=f[l];e.addEventListener("click",v._ToDisclosure),v._cleanups.push(function(){e.removeEventListener("click",s._ToDisclosure)})}();var y=document.querySelectorAll(".cc-section");if(y&&0<y.length)for(var b=this,l=0,c=y.length;l<c;l++)!function(){var e=y[l],t=y[l].querySelector(".top-content a.ad");t&&(t.addEventListener("click",b._ToDisclosure),b._cleanups.push(function(){t.removeEventListener("click",s._ToDisclosure)})),e=new Zi(e),b._cleanups.push(e.Destroy)}();var _=document.querySelectorAll(".embedholder"),S={};if(_&&0<_.length){for(var w=this,l=0,c=_.length;l<c;l++)!function(){var e=_[l],t=e.querySelector("a"),n=e.querySelector("textarea");e.addEventListener("click",F),t.addEventListener("click",C),n.addEventListener("focus",N),n.addEventListener("mouseleave",T),n.addEventListener("mouseenter",I),n.setAttribute("readonly","readonly"),w._cleanups.push(function(){n.removeEventListener("focus",N),n.removeEventListener("mouseleave",T),t.removeEventListener("click",C),n.removeEventListener("mouseenter",I),e.removeEventListener("click",F)})}();window.addEventListener("click",L),this._cleanups.push(function(){window.removeEventListener("click",L)})}var E=document.querySelector(".edu-art-social-buttons .button-reddit");E&&(E.innerHTML='<script type="text/javascript" src="https://www.reddit.com/static/button/button2.js"><\/script>');for(var k=document.querySelectorAll('div[data-calculator="hotel"]'),l=0,c=k.length;l<c;l++){var x=k[l],P=R();x.setAttribute("calc-id",P),Fi(this._AppRef,this._Injector,this._compiler,lo,no,'div[calc-id="'+P+'"]').then(function(e){s._cleanups.push(e.destroy)})}for(var O=document.querySelectorAll('div[data-calculator="airline"]'),l=0,c=O.length;l<c;l++){x=O[l],P=R();x.setAttribute("calc-id",P),Fi(this._AppRef,this._Injector,this._compiler,lo,oo,'div[calc-id="'+P+'"]').then(function(e){s._cleanups.push(e.destroy)})}}function C(e){var t=this.parentNode.querySelector(".embedcode");t.style.display=t.style.display&&"block"==t.style.display?"none":"block",t.blur(),e.preventDefault(),e.stopPropagation()}function N(){this.select()}function T(){var e=this,t=e.parentNode.parentNode.getAttribute("id");S[t]=window.setTimeout(function(){e.parentNode.style.display="none"},1500)}function I(){var e=this.parentNode.parentNode.getAttribute("id");e in S&&window.clearTimeout(S[e])}function F(e){e.stopPropagation()}function L(){for(var e=0,t=_.length;e<t;e++)_[e].querySelector(".embedcode").style.display="none"}}var po,go,fo=(vo.ɵmod=u.ɵɵdefineNgModule({type:vo,bootstrap:[Fn]}),vo.ɵinj=u.ɵɵdefineInjector({factory:function(e){return new(e||vo)(u.ɵɵinject(u.NgZone),u.ɵɵinject(te),u.ɵɵinject(u.RendererFactory2),u.ɵɵinject(u.Compiler),u.ɵɵinject(u.Injector),u.ɵɵinject(u.ApplicationRef))},providers:[{provide:u.ErrorHandler,useClass:Rn}],imports:[[u.BrowserModule,u.CommonModule,Vn,Fe.forRoot()]]}),vo);function vo(e,t,n,i,r,o){this.zone=e,this.scroll=t,this.renderFactory=n,this.compiler=i,this.injector=r,this.appref=o}u.setClassMetadata(fo,[{type:u.NgModule,args:[{imports:[u.BrowserModule,u.CommonModule,Vn,Fe.forRoot()],bootstrap:[Fn],providers:[{provide:u.ErrorHandler,useClass:Rn}]}]}],function(){return[{type:u.NgZone},{type:te},{type:u.RendererFactory2},{type:u.Compiler},{type:u.Injector},{type:u.ApplicationRef}]},null),V()?W.setEnv(global.ISPROD?"PROD":"DEV"):W.setEnv(window.isDevEv||f?"DEV":window.isDEVSTAGE?"STAGE":"PROD"),go=po=v()?"cfstatic.efdevhub.info":"cdn.wallethub.com",ht.setKey("cdn_url",!V()&&window.CDN_URL||"https://"+po+"/"),ht.setKey("cdn_static_url",!V()&&window.CDN_STATIC_URL||"https://"+go+"/"),ht.setKey("fb_app_id",v()?"772865386137702":"171743162916597"),(p()||f)&&!V()||u.enableProdMode(),lt.group("mw"),ht.pageLoadPopulate(),Hn(),Kn.then(function(){var a=[],i=[];u.platformBrowser().bootstrapModule(fo).then(function(e){var n=ht.group("edu-page"),o=e.instance,t=new Vi(o.renderFactory,o.zone,o.scroll);a.push(t.Destroy);var s=new ho(o.appref,o.injector,o.compiler,o.renderFactory,o.scroll,n);a.push(s.Destroy),window.addEventListener("load",function(){var t=!1,e=location.hash;!t&&e&&-1<e.indexOf("expert=")&&n.experts&&(t=!0,e=e.split("expert="),s.InitiateExperts(e[e.length-1]).then(function(){t=!1}).catch(function(e){t=!1})),j(function(){s.InitiateTableSorting(),s.InitiateGeoCharts(),s.InitiateMobileRelated(),s.InitiateHelpful(),s.InitiateSharing();var t=o.scroll.onScroll.pipe(u.skip(1)).subscribe(function(e){var n,i,r;s.InitiateLazyNgModules(),n=o.appref,i=o.injector,r=o.compiler,Li.import("components:/site-footer-web").then(function(e){return Fi(n,i,r,e.FooterModule,e.PageFooter,"footer[main-footer]").then(function(t){return document.querySelector("app-errors")?Fi(n,i,r,Ti,Ci,"app-errors").then(function(e){return j(function(){Ke.emit("$shortcodes:set")}),function(){e.destroy(),t.destroy()}}):t.destroy})}).then(function(e){a.push(e)}),setTimeout(function(){t.unsubscribe()})});i.push(t),s.InitiateFreeCreditModal()})}),e.onDestroy(function(){t.Destroy(),P(i,function(e){e.unsubscribe()}),P(a,function(e){e()})})})});yo.prototype.submit=function(e){return this.onSubmit.emit(e),this._allow_submit||e.preventDefault(),this._allow_submit},yo.prototype.ngAfterViewInit=function(){this._form&&!V()&&this._form.addEventListener("submit",this.submit,!1)},yo.prototype.ngOnDestroy=function(){this._form&&!V()&&this._form.removeEventListener("submit",this.submit)},yo.ɵfac=function(e){return new(e||yo)(u.ɵɵdirectiveInject(u.ElementRef))},yo.ɵdir=u.ɵɵdefineDirective({type:yo,selectors:[["form","form-submit",""]],inputs:{_allow_submit:["allow-submit","_allow_submit"]},outputs:{onSubmit:"onSubmit"}}),Hr=yo;function yo(e){this.onSubmit=new u.EventEmitter,this._allow_submit=!1,this._form=e.nativeElement,this.submit=this.submit.bind(this)}u.setClassMetadata(Hr,[{type:u.Directive,args:[{selector:"form[form-submit]"}]}],function(){return[{type:u.ElementRef}]},{onSubmit:[{type:u.Output}],_allow_submit:[{type:u.Input,args:["allow-submit"]}]});bo.ɵmod=u.ɵɵdefineNgModule({type:bo}),bo.ɵinj=u.ɵɵdefineInjector({factory:function(e){return new(e||bo)},imports:[[u.CommonModule,Fe]]}),Qr=bo;function bo(){}u.setClassMetadata(Qr,[{type:u.NgModule,args:[{declarations:[Hr],exports:[Hr],imports:[u.CommonModule,Fe]}]}],null,null);Ur=["class","helpful-article"];function _o(e,t){var n;1&e&&(n=u.ɵɵgetCurrentView(),u.ɵɵelementContainerStart(0),u.ɵɵelementStart(1,"p",4),u.ɵɵtext(2,"Was this article helpful?"),u.ɵɵelementEnd(),u.ɵɵelementStart(3,"div",5),u.ɵɵelementStart(4,"button",6),u.ɵɵlistener("onTap",function(){return u.ɵɵrestoreView(n),u.ɵɵnextContext().Yes()}),u.ɵɵelement(5,"i",7),u.ɵɵelementStart(6,"span",8),u.ɵɵtext(7,"Yes"),u.ɵɵelementEnd(),u.ɵɵelementEnd(),u.ɵɵelementStart(8,"button",9),u.ɵɵlistener("onTap",function(){return u.ɵɵrestoreView(n),u.ɵɵnextContext().No()}),u.ɵɵtext(9,"No"),u.ɵɵelementEnd(),u.ɵɵelementEnd(),u.ɵɵelementContainerEnd()),2&e&&(e=u.ɵɵnextContext(),u.ɵɵadvance(4),u.ɵɵclassProp("loadactive",e.saving))}function So(e,t){1&e&&(u.ɵɵelementStart(0,"p",10),u.ɵɵtext(1,"Awesome! Thanks for your feedback."),u.ɵɵelementEnd())}function wo(e,t){1&e&&(u.ɵɵelementStart(0,"p",4),u.ɵɵtext(1,"Thank you for your feedback."),u.ɵɵelementEnd())}function Eo(e,t){var n;1&e&&(n=u.ɵɵgetCurrentView(),u.ɵɵelementStart(0,"form",11),u.ɵɵlistener("onSubmit",function(){return u.ɵɵrestoreView(n),u.ɵɵnextContext().SubmitReason()}),u.ɵɵelementStart(1,"p",4),u.ɵɵtext(2,"Sorry!"),u.ɵɵelementEnd(),u.ɵɵelementStart(3,"textarea",12),u.ɵɵlistener("input",function(e){return u.ɵɵrestoreView(n),u.ɵɵnextContext().reason=e.target.value}),u.ɵɵelementEnd(),u.ɵɵelementStart(4,"div",13),u.ɵɵelementStart(5,"button",14),u.ɵɵelement(6,"i",7),u.ɵɵelementStart(7,"span",8),u.ɵɵtext(8,"Submit"),u.ɵɵelementEnd(),u.ɵɵelementEnd(),u.ɵɵelement(9,"error-toast",15),u.ɵɵelementEnd(),u.ɵɵelementEnd()),2&e&&(e=u.ɵɵnextContext(),u.ɵɵadvance(3),u.ɵɵproperty("value",e.reason),u.ɵɵadvance(2),u.ɵɵclassProp("loadactive",e.saving),u.ɵɵadvance(4),u.ɵɵproperty("message",e.errormsg)("show",e.show_submit_error)("close-on-change",!0))}ko.prototype.ngOnInit=function(){this._url=(Re()+this._loc.path()).replace("https://",""),this.voted="1"==tt.get("h"+this._url)},ko.prototype.Yes=function(){var e=this,t="h"+this._url;tt.set(t,"1",7),it({url:Ue(),data:{action:"send_edu_feedback",postId:this.id,url:this._url,helpful:!0},before:function(){e.saving=!0},after:function(){e.saving=!1},silent:!0,headers:{"Content-Type":"application/x-www-form-urlencoded"}}),this.submited=!0},ko.prototype.No=function(){this.unhelpful=!0},ko.prototype._ShowReqError=function(){var e=this;this.show_submit_error&&(this.show_submit_error=!1),setTimeout(function(){e.show_submit_error=!0})},ko.prototype._ThrowReqError=function(e){var t=this;void 0===e&&(e="We encountered an error. Please retry"),this.errormsg?this.errormsg=null:this.errormsg=e,setTimeout(function(){t.errormsg=e},100),this._ShowReqError()},ko.prototype.SubmitReason=function(){var e,t,n=this;this.saving||((t=!(e=ct(this.reason||""))||e.length<10?"Content must have 30 characters":t)?this._ThrowReqError(t):it({url:Ue(),data:{action:"send_edu_feedback",postId:this.id,url:this._url,helpful:!1,feedback:e},before:function(){n.saving=!0},after:function(){n.saving=!1},headers:{"Content-Type":"application/x-www-form-urlencoded"}}).then(function(e){e.error?n._ThrowReqError():(n.voted=!0,n.unhelpful=!1,e="h"+n._url,tt.set(e,"0",7))}).catch(function(){n._ThrowReqError()}))},ko.ɵfac=function(e){return new(e||ko)(u.ɵɵdirectiveInject(u.Location))},ko.ɵcmp=u.ɵɵdefineComponent({type:ko,selectors:[["div",8,"helpful-article"]],hostAttrs:[1,"text-select","helpful-article"],inputs:{id:"id"},attrs:Ur,decls:4,vars:4,consts:[[4,"ngIf"],["class","ng-enter-element helpful-head",4,"ngIf"],["class","helpful-head",4,"ngIf"],["class","ng-enter-element","form-submit","",3,"onSubmit",4,"ngIf"],[1,"helpful-head"],[1,"helpful-btn-container"],["type","button","zing-touch","",1,"btn","blue-brds","helpful-btn","with-loader",3,"onTap"],[1,"btn-loader"],[1,"bt-text"],["type","button","zing-touch","",1,"btn","blue-brds","helpful-btn",3,"onTap"],[1,"ng-enter-element","helpful-head"],["form-submit","",1,"ng-enter-element",3,"onSubmit"],["placeholder","How can we improve it?",1,"textarea","large","helpful-textarea",3,"value","input"],[1,"helpful-form-btn"],["type","submit",1,"btn","fixed-w","with-loader"],[3,"message","show","close-on-change"]],template:function(e,t){1&e&&(u.ɵɵtemplate(0,_o,10,2,"ng-container",0),u.ɵɵtemplate(1,So,2,0,"p",1),u.ɵɵtemplate(2,wo,2,0,"p",2),u.ɵɵtemplate(3,Eo,10,6,"form",3)),2&e&&(u.ɵɵproperty("ngIf",!t.submited&&!t.voted&&!t.unhelpful),u.ɵɵadvance(1),u.ɵɵproperty("ngIf",t.submited),u.ɵɵadvance(1),u.ɵɵproperty("ngIf",t.voted),u.ɵɵadvance(1),u.ɵɵproperty("ngIf",t.unhelpful))},directives:[u.NgIf,K,Hr,tr],encapsulation:2}),Wr=ko;function ko(e){this._loc=e,this.submited=!1,this.reason=""}u.setClassMetadata(Wr,[{type:u.Component,args:[{selector:"div.helpful-article",templateUrl:"/views/pages/edu/edu-helpful.html",host:{class:"text-select helpful-article"}}]}],function(){return[{type:u.Location}]},{id:[{type:u.Input,args:["id"]}]});xo.ɵmod=u.ɵɵdefineNgModule({type:xo}),xo.ɵinj=u.ɵɵdefineInjector({factory:function(e){return new(e||xo)},imports:[[u.CommonModule,Fe,$r,Qr]]}),yi=xo;function xo(){}u.setClassMetadata(yi,[{type:u.NgModule,args:[{imports:[u.CommonModule,Fe,$r,Qr],declarations:[Wr],exports:[Wr]}]}],null,null);Object.defineProperty(Po.prototype,"refresh",{get:function(){return this._refresh},set:function(e){var t=this;this._refresh=e,!V()&&this._scroller&&setTimeout(function(){t._scrollWatch()})},enumerable:!1,configurable:!0}),Object.defineProperty(Po.prototype,"enabled",{get:function(){return this._enable},set:function(e){var t=this;(this._enable=e)&&!V()&&setTimeout(function(){t._scrollWatch()})},enumerable:!1,configurable:!0}),Po.prototype._getSupport=function(){if(!window.getComputedStyle)return!1;for(var e=document.createElement("div"),t=["","-webkit-","-moz-","-ms-"],n=null,i=0,r=t.length;i<r;i++){var o=t[i]+"sticky";try{e.style.position=o}catch(e){}if(e.style.position&&-1<e.style.position.indexOf("sticky")){n=o;break}}return n},Po.prototype._scrollWatch=function(){var e,t,n,i;this.enabled&&(e=this._el.nativeElement,i=this._el.nativeElement.parentNode.getBoundingClientRect(),t={},0===e.offsetHeight&&0===e.offsetWidth||((n=i.top<this.offset?this.offset:i.top)+e.offsetHeight>i.bottom&&(n=i.bottom-e.offsetHeight),t.top=n+"px",this.fixedcenter&&(t.left=i.left+"px",t.right=window.innerWidth-i.right+"px"),i="position:fixed;top:"+t.top+";left:"+t.left+";",t.right&&(i+="right:"+t.right),e.style.cssText!==i&&(e.style.cssText=i)))},Po.prototype.ngAfterViewInit=function(){var e,t=this;if(this._scrollWatch=this._scrollWatch.bind(this),!V()&&!window.JSTESTING){if(this.sticky_parent&&(this._el={nativeElement:this._el.nativeElement.parentNode}),this.trynative){var n=this._getSupport();if(n)return void(this._el.nativeElement.style.position=n)}this._scroller=this.scroller?document.querySelector(this.scroller):this._dserv.overwrite_to_body?window:this._dserv.element,this.scroller&&this.userscrolleroffset&&null===this.offset&&!this._dserv.overwrite_to_body&&(this.offset=this._scroller.getBoundingClientRect().top),null===this.offset&&(this.offset=0),e=!!U()&&{passive:!0},e=!1,this._zone.runOutsideAngular(function(){t._scroller.addEventListener("scroll",t._scrollWatch,e),window.addEventListener("resize",t._scrollWatch,e),t.auto_start&&j(function(){t._el.nativeElement.style.position=t._nativesupport,t._el.nativeElement.top="0px",t._scrollWatch()})})}},Po.prototype.ngOnDestroy=function(){this._scroller&&"fixed"==this._nativesupport&&(this._scroller.removeEventListener("scroll",this._scrollWatch),window.removeEventListener("resize",this._scrollWatch))},Po.ɵfac=function(e){return new(e||Po)(u.ɵɵdirectiveInject(u.ElementRef),u.ɵɵdirectiveInject(u.NgZone),u.ɵɵdirectiveInject(te))},Po.ɵdir=u.ɵɵdefineDirective({type:Po,selectors:[["","ng-sticky",""]],inputs:{scroller:["sticky-scroller","scroller"],offset:["stickyoffset","offset"],fixedcenter:["stickyfull","fixedcenter"],userscrolleroffset:["sticky-scroller-offset","userscrolleroffset"],refresh:["sticky-refresh-toggle","refresh"],enabled:["stickyenabled","enabled"],auto_start:["sticky-auto-start","auto_start"],trynative:["sticky-native","trynative"],sticky_parent:["sticky-parent","sticky_parent"]}}),Ri=Po;function Po(e,t,n){this._el=e,this._zone=t,this._dserv=n,this.offset=null,this.fixedcenter=!1,this.userscrolleroffset=!0,this._enable=!0,this.auto_start=!0,this._nativesupport="fixed",this.trynative=!1,this.sticky_parent=!1}u.setClassMetadata(Ri,[{type:u.Directive,args:[{selector:"[ng-sticky]"}]}],function(){return[{type:u.ElementRef},{type:u.NgZone},{type:te}]},{scroller:[{type:u.Input,args:["sticky-scroller"]}],offset:[{type:u.Input,args:["stickyoffset"]}],fixedcenter:[{type:u.Input,args:["stickyfull"]}],userscrolleroffset:[{type:u.Input,args:["sticky-scroller-offset"]}],refresh:[{type:u.Input,args:["sticky-refresh-toggle"]}],enabled:[{type:u.Input,args:["stickyenabled"]}],auto_start:[{type:u.Input,args:["sticky-auto-start"]}],trynative:[{type:u.Input,args:["sticky-native"]}],sticky_parent:[{type:u.Input,args:["sticky-parent"]}]});Object.defineProperty(Oo.prototype,"enabled",{get:function(){return this._enabled},set:function(e){var t=this;e!==this._enabled&&(e?(this._native&&this._renderer.setStyle(this._el.nativeElement,"position","sticky"),j(function(){t._ScrollWatch()})):this._renderer.setStyle(this._el.nativeElement,"position","")),this._enabled=e},enumerable:!1,configurable:!0}),Oo.prototype._getSupport=function(){if(!window.getComputedStyle)return!1;for(var e=document.createElement("div"),t=["","-webkit-","-moz-","-ms-"],n=null,i=0,r=t.length;i<r;i++){var o=t[i]+"sticky";try{e.style.position=o}catch(e){}if(e.style.position&&-1<e.style.position.indexOf("sticky")){n=o;break}}return n},Oo.prototype._ScrollWatch=function(l){var c=this;this.enabled&&this._zone.runOutsideAngular(function(){var e=c._el.nativeElement;if(c._native){var t=0,n=e.style.top?E(e.style.top):0,i=e.offsetTop;if(Ke.subscribe("header:position-change",function(e){t=e},function(){},function(){},[u.take(1)]),t!==n&&0!=i?c._renderer.setStyle(e,"top",t+"px"):0==i&&(t=0,c._renderer.setStyle(e,"top",t+"px")),c._stickyWayPoint){for(var r=c._stickyWayPoint.offsetTop,o=c._stickyWayPoint.offsetParent,i=e.offsetTop;o&&o!=c._dscroll.element;)r+=o.offsetTop,o=o.offsetParent;0!==i&&(r<i?c.onPosition.emit("sticky"):c.onPosition.emit("static"))}}else if(c._stickyContainer)if(l){for(var s,a=c._stickyContainer.offsetTop,o=c._stickyContainer.offsetParent;o&&o!=c._dscroll.element;)a+=o.offsetTop,o=o.offsetParent;a<=l?(s=0,Ke.subscribe("header:position-change",function(e){s=e},function(){},function(){},[u.take(1)]),c._renderer.setStyle(e,"top",s+"px"),c._renderer.setStyle(e,"position","fixed")):(c._renderer.setStyle(e,"top",""),c._renderer.setStyle(e,"position",""))}else c._renderer.setStyle(e,"top",""),c._renderer.setStyle(e,"position","")})},Oo.prototype.ngAfterViewInit=function(){var e,t=this;V()||f||(this.sticky_parent&&(this._el={nativeElement:this._el.nativeElement.parentNode}),this._native=!!this.allow_native&&this._getSupport(),this.enabled&&this._renderer.setStyle(this._el.nativeElement,"position",this._native?"sticky":""),this._native?(this._stickyWayPoint=document.createElement("div"),this._stickyWayPoint.classList.add("sticky-waypoint"),this._el.nativeElement&&this._el.nativeElement.before(this._stickyWayPoint)):(this._stickyContainer=document.createElement("div"),this._stickyContainer.classList.add("sticky-container"),e=this._el.nativeElement.getBoundingClientRect(),this._stickyContainer.style.height=e.height+"px",this._el.nativeElement.before(this._stickyContainer),this._stickyContainer.appendChild(this._el.nativeElement)),this._observables.push(u.fromEvent(window,"resize")),this._observables.forEach(function(e){t._subscriptions.push(e.subscribe(function(){var e;t._stickyContainer&&(e=t._el.nativeElement.getBoundingClientRect(),t._stickyContainer.style.height=e.height+"px"),t._ScrollWatch()}))}),this._subscriptions.push(this._dscroll.onScroll.subscribe(function(e){t._ScrollWatch(e)})),this._ScrollWatch())},Oo.prototype.ngOnDestroy=function(){if(this._subscriptions.forEach(function(e){e.unsubscribe()}),this._observables=[],this._stickyContainer){this._stickyContainer.after(this._el.nativeElement);try{this._stickyContainer.parentNode.removeChild(this._stickyContainer)}catch(e){}this._stickyContainer=null}if(this._stickyWayPoint){try{this._stickyWayPoint.parentNode.removeChild(this._stickyWayPoint)}catch(e){}this._stickyWayPoint=null}},Oo.ɵfac=function(e){return new(e||Oo)(u.ɵɵdirectiveInject(u.ElementRef),u.ɵɵdirectiveInject(u.NgZone),u.ɵɵdirectiveInject(te),u.ɵɵdirectiveInject(u.Renderer2))},Oo.ɵdir=u.ɵɵdefineDirective({type:Oo,selectors:[["","ng-position-sticky",""]],inputs:{allow_native:["native","allow_native"],enabled:"enabled",sticky_parent:["sticky-parent","sticky_parent"]},outputs:{onPosition:"onPosition"}}),Vn=Oo;function Oo(e,t,n,i){this._el=e,this._zone=t,this._dscroll=n,this._renderer=i,this.allow_native=!0,this.onPosition=new u.EventEmitter,this._enabled=!0,this.sticky_parent=!1,this._subscriptions=[],this._observables=[],this._native=!1,this._ScrollWatch=this._ScrollWatch.bind(this)}u.setClassMetadata(Vn,[{type:u.Directive,args:[{selector:"[ng-position-sticky]"}]}],function(){return[{type:u.ElementRef},{type:u.NgZone},{type:te},{type:u.Renderer2}]},{allow_native:[{type:u.Input,args:["native"]}],onPosition:[{type:u.Output,args:["onPosition"]}],enabled:[{type:u.Input,args:["enabled"]}],sticky_parent:[{type:u.Input,args:["sticky-parent"]}]});Co.ɵmod=u.ɵɵdefineNgModule({type:Co}),Co.ɵinj=u.ɵɵdefineInjector({factory:function(e){return new(e||Co)},imports:[[u.CommonModule]]}),Fn=Co;function Co(){}u.setClassMetadata(Fn,[{type:u.NgModule,args:[{declarations:[Ri,Vn],exports:[Ri,Vn],imports:[u.CommonModule]}]}],null,null);var No=["urlText"];function To(e,t){1&e&&u.ɵɵelement(0,"div",4)}function Io(e,t){1&e&&(u.ɵɵelementStart(0,"div",5),u.ɵɵtext(1,"Link copied to clipboard."),u.ɵɵelementEnd())}function Fo(e,t){var n;1&e&&(n=u.ɵɵgetCurrentView(),u.ɵɵelementStart(0,"div",6),u.ɵɵlistener("onTap",function(){return u.ɵɵrestoreView(n),u.ɵɵnextContext().closeDialog()}),u.ɵɵtext(1,"Close"),u.ɵɵelementEnd())}function Lo(e,t){var n;1&e&&(n=u.ɵɵgetCurrentView(),u.ɵɵelementContainerStart(0),u.ɵɵelementStart(1,"div",7),u.ɵɵtext(2,"Share"),u.ɵɵelementEnd(),u.ɵɵelementStart(3,"div",8),u.ɵɵelementStart(4,"span",9),u.ɵɵlistener("onTap",function(){u.ɵɵrestoreView(n);var e=u.ɵɵnextContext();return e.OpenUrl(e.data.fblink)}),u.ɵɵelement(5,"i",10),u.ɵɵelementStart(6,"span"),u.ɵɵtext(7,"Facebook"),u.ɵɵelementEnd(),u.ɵɵelementEnd(),u.ɵɵelementStart(8,"span",9),u.ɵɵlistener("onTap",function(){u.ɵɵrestoreView(n);var e=u.ɵɵnextContext();return e.OpenUrl(e.data.twlink)}),u.ɵɵelement(9,"i",11),u.ɵɵelementStart(10,"span"),u.ɵɵtext(11,"Twitter"),u.ɵɵelementEnd(),u.ɵɵelementEnd(),u.ɵɵelementStart(12,"span",9),u.ɵɵlistener("onTap",function(){u.ɵɵrestoreView(n);var e=u.ɵɵnextContext();return e.OpenUrl(e.data.inlink)}),u.ɵɵelement(13,"i",12),u.ɵɵelementStart(14,"span"),u.ɵɵtext(15,"LinkedIn"),u.ɵɵelementEnd(),u.ɵɵelementEnd(),u.ɵɵelementStart(16,"a",13),u.ɵɵelement(17,"i",14),u.ɵɵelementStart(18,"span"),u.ɵɵtext(19,"Email"),u.ɵɵelementEnd(),u.ɵɵelementEnd(),u.ɵɵelementEnd(),u.ɵɵelementStart(20,"div",15),u.ɵɵelement(21,"textarea",16,17),u.ɵɵelementStart(23,"span",18),u.ɵɵlistener("onTap",function(){return u.ɵɵrestoreView(n),u.ɵɵnextContext().CopyUrl()}),u.ɵɵtext(24,"copy"),u.ɵɵelementEnd(),u.ɵɵelementEnd(),u.ɵɵelementContainerEnd()),2&e&&(e=u.ɵɵnextContext(),u.ɵɵadvance(16),u.ɵɵproperty("href",e.email,u.ɵɵsanitizeUrl)("zing-url",!0),u.ɵɵadvance(5),u.ɵɵproperty("value",e.data.link))}var Vo=["shareBox"];function Ao(e,t){1&e&&(u.ɵɵelementStart(0,"span",6),u.ɵɵtext(1),u.ɵɵelementEnd()),2&e&&(e=u.ɵɵnextContext(),u.ɵɵadvance(1),u.ɵɵtextInterpolate(e.shares_count))}function Mo(e,t){1&e&&u.ɵɵelement(0,"modal-dialog",null,7)}var zo=(Ro.prototype.ngOnInit=function(){this.email="mailto:?subject="+encodeURIComponent(this.data.title)+"&body=",this.email+=encodeURIComponent("From WalletHub:\n"+this.data.title+"\n"+this.data.link+"?utm_source=emailshare")},Ro.prototype.CopyUrl=function(){var e,t,n,i=this,r=this.urlText.nativeElement;navigator.userAgent.match(/ipad|ipod|iphone/i)?(e=r.contentEditable,r.contentEditable="true",(t=document.createRange()).selectNodeContents(r),(n=window.getSelection()).removeAllRanges(),n.addRange(t),r.setSelectionRange(0,999999),r.contentEditable=e):r.select(),document.execCommand("copy"),r.blur(),setTimeout(function(){i.link_copied=!0},100)},Ro.prototype.OpenUrl=function(e){var t=(window.innerWidth-this.width)/2,n=(window.innerHeight-this.height)/2,t="status=1,width="+this.width+",height="+this.height+",top="+n+",left="+t;window.open(e,"whpopup",t)},Ro.ɵfac=function(e){return new(e||Ro)},Ro.ɵcmp=u.ɵɵdefineComponent({type:Ro,selectors:[["social-shareov"]],viewQuery:function(e,t){var n;1&e&&u.ɵɵviewQuery(No,!0),2&e&&u.ɵɵqueryRefresh(n=u.ɵɵloadQuery())&&(t.urlText=n.first)},hostVars:2,hostBindings:function(e,t){2&e&&u.ɵɵclassProp("edu-ss-copied",t.link_copied)},decls:4,vars:4,consts:[["class","edu-ss-link-cpy ng-enter-element",4,"ngIf"],["class","edu-ss-title ng-enter-element",4,"ngIf"],["class","edu-ss-link-cpy-bt btn fixed-w-b ng-enter-element","zing-touch","",3,"onTap",4,"ngIf"],[4,"ngIf"],[1,"edu-ss-link-cpy","ng-enter-element"],[1,"edu-ss-title","ng-enter-element"],["zing-touch","",1,"edu-ss-link-cpy-bt","btn","fixed-w-b","ng-enter-element",3,"onTap"],[1,"edu-ss-title"],[1,"edu-ss-links-bt-box"],["zing-touch","",1,"edu-ss-ln-bt",3,"onTap"],[1,"edu-ss-ln-ic","bf-icon-social-fbk"],[1,"edu-ss-ln-ic","bf-icon-social-tw"],[1,"edu-ss-ln-ic","bf-icon-social-in"],["zing-touch","","target","_system",1,"edu-ss-ln-bt",3,"href","zing-url"],[1,"edu-ss-ln-ic","bf-icon-social-email"],[1,"edu-copy-url"],[1,"edu-cpu-txt",3,"value"],["urlText",""],["zing-touch","",1,"edu-cpu-bt","semi-bold-font",3,"onTap"]],template:function(e,t){1&e&&(u.ɵɵtemplate(0,To,1,0,"div",0),u.ɵɵtemplate(1,Io,2,0,"div",1),u.ɵɵtemplate(2,Fo,2,0,"div",2),u.ɵɵtemplate(3,Lo,25,3,"ng-container",3)),2&e&&(u.ɵɵproperty("ngIf",t.link_copied),u.ɵɵadvance(1),u.ɵɵproperty("ngIf",t.link_copied),u.ɵɵadvance(1),u.ɵɵproperty("ngIf",t.link_copied),u.ɵɵadvance(1),u.ɵɵproperty("ngIf",!t.link_copied))},directives:[u.NgIf,K],encapsulation:2}),Ro);function Ro(){this.width=575,this.height=400}u.setClassMetadata(zo,[{type:u.Component,args:[{selector:"social-shareov",template:'<div class="edu-ss-link-cpy ng-enter-element" *ngIf="link_copied"></div>\n                <div class="edu-ss-title ng-enter-element" *ngIf="link_copied">Link copied to clipboard.</div>\n                <div class="edu-ss-link-cpy-bt btn fixed-w-b ng-enter-element" *ngIf="link_copied" zing-touch (onTap)="closeDialog()">Close</div>\n                <ng-container *ngIf="!link_copied">\n                <div class="edu-ss-title">Share</div>\n                <div class="edu-ss-links-bt-box">\n                    <span class="edu-ss-ln-bt" zing-touch (onTap)="OpenUrl(data.fblink)">\n                        <i class="edu-ss-ln-ic bf-icon-social-fbk"></i>\n                        <span>Facebook</span>\n                    </span>\n                    <span class="edu-ss-ln-bt" zing-touch (onTap)="OpenUrl(data.twlink)">\n                        <i class="edu-ss-ln-ic bf-icon-social-tw"></i>\n                        <span>Twitter</span>\n                    </span>\n                    <span class="edu-ss-ln-bt" zing-touch (onTap)="OpenUrl(data.inlink)">\n                        <i class="edu-ss-ln-ic bf-icon-social-in"></i>\n                        <span>LinkedIn</span>\n                    </span>\n                    <a class="edu-ss-ln-bt" [href]="email" zing-touch [zing-url]="true" target="_system">\n                        <i class="edu-ss-ln-ic bf-icon-social-email"></i>\n                        <span>Email</span>\n                    </a>\n                </div>\n                <div class="edu-copy-url">\n                    <textarea class="edu-cpu-txt" [value]="data.link" #urlText></textarea>\n                    <span class="edu-cpu-bt semi-bold-font" zing-touch (onTap)="CopyUrl()">copy</span>\n                </div>\n                </ng-container>',host:{"[class.edu-ss-copied]":"link_copied"}}]}],null,{urlText:[{type:u.ViewChild,args:["urlText",{static:!1}]}]});Do.prototype.ngOnInit=function(){var t=this;this.is_web=!V();var e=encodeURIComponent(this.url||"https://wallethub.com"+this._loc.path()),n=encodeURIComponent((this.title||"Wallethub").replace(/ /g,"+")),i=ht.getKey("fb_app_id");this.fblink="http://www.facebook.com/share.php?display=popup&app_id="+i+"&skip_api_login=1&u="+e+"&title="+n,this.twlink="https://twitter.com/intent/tweet?text="+n+"+"+e+"+"+encodeURIComponent("via+@WalletHub"),this.inlink="http://www.linkedin.com/shareArticle?mini=true&source=WalletHub&url="+e+"&title="+n,V()||p()||!this.float_shares||it({method:"GET",url:"https://opensharecount.com/count.json",query:{url:"https://wallethub.com"+this._loc.path()}}).then(function(e){e&&w(e.count)?t.shares_count=e.count:t.shares_count=0}).catch(function(){t.shares_count=0})},Do.prototype.ngOnDestroy=function(){this.eventresize&&(this.eventresize=null),this.subsresize&&this.subsresize.unsubscribe()},Do.prototype.OpenShare=function(){var e=this;this.shareBox.Open(zo,{fblink:this.fblink,twlink:this.twlink,inlink:this.inlink,link:this.url||"https://wallethub.com"+this._loc.path(),title:this.title}),this.eventresize=u.fromEvent(window,"resize"),this.subsresize=this.eventresize.subscribe(function(){e.shareBox.Close(),setTimeout(function(){e.eventresize&&(e.eventresize=null),e.subsresize&&e.subsresize.unsubscribe()})})},Do.prototype.OpenUrl=function(e){var t=(window.innerWidth-this.width)/2,n=(window.innerHeight-this.height)/2,t="status=1,width="+this.width+",height="+this.height+",top="+n+",left="+t;window.open(e,"whpopup",t)},Do.ɵfac=function(e){return new(e||Do)(u.ɵɵdirectiveInject(u.Location))},Do.ɵcmp=u.ɵɵdefineComponent({type:Do,selectors:[["social-share"]],viewQuery:function(e,t){var n;1&e&&u.ɵɵviewQuery(Vo,!0),2&e&&u.ɵɵqueryRefresh(n=u.ɵɵloadQuery())&&(t.shareBox=n.first)},hostVars:4,hostBindings:function(e,t){2&e&&u.ɵɵclassProp("edu-ss-float",t.float_shares&&t.shares_count)("edu-ss-shares-static",t.shares_count)},inputs:{title:"title",url:"url",float_shares:["float-shares","float_shares"]},decls:6,vars:2,consts:[["class","edu-ss-link edu-ss-shares-link ng-enter-element","data-after","shares",4,"ngIf"],["zing-touch","",1,"edu-ss-link","edu-ss-fb","bf-icon-social-fbk",3,"onTap"],["zing-touch","",1,"edu-ss-link","edu-ss-tw","bf-icon-social-tw",3,"onTap"],["zing-touch","",1,"edu-ss-link","edu-ss-in","bf-icon-social-in",3,"onTap"],["zing-touch","",1,"edu-ss-link","edu-ss-email","bf-icon-social-email",3,"onTap"],[4,"ngIf"],["data-after","shares",1,"edu-ss-link","edu-ss-shares-link","ng-enter-element"],["shareBox",""]],template:function(e,t){1&e&&(u.ɵɵtemplate(0,Ao,2,1,"span",0),u.ɵɵelementStart(1,"span",1),u.ɵɵlistener("onTap",function(){return t.OpenUrl(t.fblink)}),u.ɵɵelementEnd(),u.ɵɵelementStart(2,"span",2),u.ɵɵlistener("onTap",function(){return t.OpenUrl(t.twlink)}),u.ɵɵelementEnd(),u.ɵɵelementStart(3,"span",3),u.ɵɵlistener("onTap",function(){return t.OpenUrl(t.inlink)}),u.ɵɵelementEnd(),u.ɵɵelementStart(4,"span",4),u.ɵɵlistener("onTap",function(){return t.OpenShare()}),u.ɵɵelementEnd(),u.ɵɵtemplate(5,Mo,2,0,"modal-dialog",5)),2&e&&(u.ɵɵproperty("ngIf",t.float_shares&&t.shares_count),u.ɵɵadvance(5),u.ɵɵproperty("ngIf",t.is_web))},directives:[u.NgIf,K,pi],encapsulation:2}),Rn=Do;function Do(e){this._loc=e,this.shares_count=0,this.is_web=!1,this.width=575,this.height=400}u.setClassMetadata(Rn,[{type:u.Component,args:[{selector:"social-share",template:'<span class="edu-ss-link edu-ss-shares-link ng-enter-element" data-after="shares" *ngIf="float_shares && shares_count">{{shares_count}}</span>\n                <span class="edu-ss-link edu-ss-fb bf-icon-social-fbk" zing-touch (onTap)="OpenUrl(fblink)"></span> \n                <span class="edu-ss-link edu-ss-tw bf-icon-social-tw" zing-touch (onTap)="OpenUrl(twlink)"></span>\n                <span class="edu-ss-link edu-ss-in bf-icon-social-in" zing-touch (onTap)="OpenUrl(inlink)"></span>\n                <span class="edu-ss-link edu-ss-email bf-icon-social-email" zing-touch (onTap)="OpenShare()"></span>\n                <modal-dialog #shareBox *ngIf="is_web"></modal-dialog>',host:{"[class.edu-ss-float]":"float_shares && shares_count","[class.edu-ss-shares-static]":"shares_count"}}]}],function(){return[{type:u.Location}]},{title:[{type:u.Input,args:["title"]}],url:[{type:u.Input,args:["url"]}],float_shares:[{type:u.Input,args:["float-shares"]}],shareBox:[{type:u.ViewChild,args:["shareBox"]}]});Bo.ɵmod=u.ɵɵdefineNgModule({type:Bo}),Bo.ɵinj=u.ɵɵdefineInjector({factory:function(e){return new(e||Bo)},imports:[[u.CommonModule,Fe,fi,Fn]]}),Ur=Bo;function Bo(){}u.setClassMetadata(Ur,[{type:u.NgModule,args:[{declarations:[Rn,zo],exports:[Rn],imports:[u.CommonModule,Fe,fi,Fn],entryComponents:[zo]}]}],null,null);Ri=["class","social-share-box"],jo.prototype.ngOnInit=function(){var e,t=this;V()||(this.permanent_sticky?(this.sticky_social=!0,this.social_shares=!1):(this._windowobs=u.fromEvent(window,"resize"),this._windowsubs=this._windowobs.subscribe(function(){var e=window.innerWidth;t.sticky_social=e<=767}),e=window.innerWidth,this.sticky_social=e<=767))},jo.prototype.ngOnDestroy=function(){this._windowobs&&(this._windowsubs.unsubscribe(),this._windowobs=null)},jo.prototype.SocialFloating=function(e){this.no_shares||(this.social_shares="sticky"==e)},jo.ɵfac=function(e){return new(e||jo)},jo.ɵcmp=u.ɵɵdefineComponent({type:jo,selectors:[["",8,"social-share-box"]],inputs:{title:"title",template:"template",permanent_sticky:["sticky","permanent_sticky"],no_shares:["no-shares","no_shares"]},attrs:Ri,decls:1,vars:6,consts:[["ng-position-sticky","",3,"title","float-shares","enabled","sticky-parent","onPosition"]],template:function(e,t){1&e&&(u.ɵɵelementStart(0,"social-share",0),u.ɵɵlistener("onPosition",function(e){return t.SocialFloating(e)}),u.ɵɵelementEnd()),2&e&&(u.ɵɵclassProp("social-share-mobile-only","v1"==t.template),u.ɵɵproperty("title",t.title)("float-shares",t.social_shares)("enabled",t.sticky_social)("sticky-parent",!0))},directives:[Rn,Vn],encapsulation:2}),Rn=jo;function jo(){this.template="v1",this.permanent_sticky=!1,this.no_shares=!1,this.social_shares=!1,this.sticky_social=!1}u.setClassMetadata(Rn,[{type:u.Component,args:[{selector:".social-share-box",template:'<social-share [title]="title" [float-shares]="social_shares" [class.social-share-mobile-only]="template == \'v1\'" ng-position-sticky (onPosition)="SocialFloating($event)" [enabled]="sticky_social" [sticky-parent]="true"></social-share>'}]}],null,{title:[{type:u.Input,args:["title"]}],template:[{type:u.Input,args:["template"]}],permanent_sticky:[{type:u.Input,args:["sticky"]}],no_shares:[{type:u.Input,args:["no-shares"]}]});Uo.ɵmod=u.ɵɵdefineNgModule({type:Uo}),Uo.ɵinj=u.ɵɵdefineInjector({factory:function(e){return new(e||Uo)},imports:[[u.CommonModule,Fn,Ur]]}),Vn=Uo;function Uo(){}u.setClassMetadata(Vn,[{type:u.NgModule,args:[{imports:[u.CommonModule,Fn,Ur],declarations:[Rn],exports:[Rn]}]}],null,null),e.$http=it,e.$httpAbort=rt,e.AppContainer=st,e.AppData=ht,e.AppModule=fo,e.Cookies=tt,e.DirectivesModule=Fe,e.EduHepful=Wr,e.EduShareBox=Rn,e.ErrorToastComponent=tr,e.ErrorsModule=$r,e.Events=Ke,e.FormSubmit=Hr,e.FormSubmitModule=Qr,e.ImageLoader=ji,e.ImageLoaderModule=Wi,e.NgEduHepfulModule=yi,e.NgEduShareUIModule=Vn,e.RavenJs=zn,e.RavenRequestFail=function(n,i,r,o){void 0===o&&(o="warning");var e=p();zn().then(function(t){A(n.status,[-1,-999,-10,400])||n.status&&500<=n.status||(n.status&&(i+="; status: "+n.status),e?console.warn(i):t.withScope(function(e){switch(e.setExtras({details:JSON.stringify(n),params:r?JSON.stringify(r):null,path:window.location.pathname||window.location.href}),o){case"critical":e.setLevel(t.Severity.Critical);break;case"error":e.setLevel(t.Severity.Error);break;default:e.setLevel(t.Severity.Warning);break;case"info":e.setLevel(t.Severity.Info);break;case"debug":e.setLevel(t.Severity.Debug)}t.captureMessage(i)}))})},e.Sanitize=ge,e.ScrollerService=te,e.StickerModule=Fn,e.TouchGestures=K,e.ajaxUrl=Ue,e.arrayForEach=P,e.baseUrl=Re,e.cleanInput=ct,e.injectModuleAsync=Fi,e.isAny=A,e.isArray=x,e.isNode=V,e.isNullorUndefined=M,e.isObject=C,e.isWeb=m,e.ngAttribute=ye,e.ngCleanBind=Pe,e.ngCleanHTML=ke,e.ngHidden=fe,e.ngModalDialog=pi,e.ngModalsModule=fi,e.ngZenScroll=oe,e.objectForEach=T,e.objectFromParam=function(e,r,o){void 0===r&&(r=null),void 0===o&&(o=!1);var s={};return e.split("&").map(function(e){var e=e.split("="),t=e[0],n=e[1];if(void 0!==n){var i=r;try{i=""===t?n:decodeURIComponent(n)}catch(e){}o?(s.params||(s.params={},s.paramstring=""),s.params[t]=i,s.paramstring&&(s.paramstring+="&"),s.paramstring+=t+"="+n):s[t]=i}else t&&(o?(s.nulls||(s.nulls={}),s.nulls[t]=r):s[t]=r)}),s},e.reqAnimationFrame=j,e.stringGetDigits=S,e.toNumber=E,e.trim=y,e.uniqid=R});