forgeplus/public/assets/application-860dba70259cdc6...

16 lines
495 KiB
JavaScript

(function(){var t=this;(function(){(function(){this.Rails={linkClickSelector:"a[data-confirm], a[data-method], a[data-remote]:not([disabled]), a[data-disable-with], a[data-disable]",buttonClickSelector:{selector:"button[data-remote]:not([form]), button[data-confirm]:not([form])",exclude:"form button"},inputChangeSelector:"select[data-remote], input[data-remote], textarea[data-remote]",formSubmitSelector:"form",formInputClickSelector:"form input[type=submit], form input[type=image], form button[type=submit], form button:not([type]), input[type=submit][form], input[type=image][form], button[type=submit][form], button[form]:not([type])",formDisableSelector:"input[data-disable-with]:enabled, button[data-disable-with]:enabled, textarea[data-disable-with]:enabled, input[data-disable]:enabled, button[data-disable]:enabled, textarea[data-disable]:enabled",formEnableSelector:"input[data-disable-with]:disabled, button[data-disable-with]:disabled, textarea[data-disable-with]:disabled, input[data-disable]:disabled, button[data-disable]:disabled, textarea[data-disable]:disabled",fileInputSelector:"input[name][type=file]:not([disabled])",linkDisableSelector:"a[data-disable-with], a[data-disable]",buttonDisableSelector:"button[data-remote][data-disable-with], button[data-remote][data-disable]"}}).call(this)}).call(t);var v=t.Rails;(function(){(function(){var e;e=null,v.loadCSPNonce=function(){var t;return e=null!=(t=document.querySelector("meta[name=csp-nonce]"))?t.content:void 0},v.cspNonce=function(){return null!=e?e:v.loadCSPNonce()}}).call(this),function(){var r,n;n=Element.prototype.matches||Element.prototype.matchesSelector||Element.prototype.mozMatchesSelector||Element.prototype.msMatchesSelector||Element.prototype.oMatchesSelector||Element.prototype.webkitMatchesSelector,v.matches=function(t,e){return null!=e.exclude?n.call(t,e.selector)&&!n.call(t,e.exclude):n.call(t,e)},r="_ujsData",v.getData=function(t,e){var n;return null!=(n=t[r])?n[e]:void 0},v.setData=function(t,e,n){return null==t[r]&&(t[r]={}),t[r][e]=n},v.$=function(t){return Array.prototype.slice.call(document.querySelectorAll(t))}}.call(this),function(){var n,r,i;n=v.$,i=v.csrfToken=function(){var t;return(t=document.querySelector("meta[name=csrf-token]"))&&t.content},r=v.csrfParam=function(){var t;return(t=document.querySelector("meta[name=csrf-param]"))&&t.content},v.CSRFProtection=function(t){var e;if(null!=(e=i()))return t.setRequestHeader("X-CSRF-Token",e)},v.refreshCSRFTokens=function(){var t,e;if(e=i(),t=r(),null!=e&&null!=t)return n('form input[name="'+t+'"]').forEach(function(t){return t.value=e})}}.call(this),function(){var i,e,o,n;o=v.matches,"function"!=typeof(i=window.CustomEvent)&&((i=function(t,e){var n;return(n=document.createEvent("CustomEvent")).initCustomEvent(t,e.bubbles,e.cancelable,e.detail),n}).prototype=window.Event.prototype,n=i.prototype.preventDefault,i.prototype.preventDefault=function(){var t;return t=n.call(this),this.cancelable&&!this.defaultPrevented&&Object.defineProperty(this,"defaultPrevented",{get:function(){return!0}}),t}),e=v.fire=function(t,e,n){var r;return r=new i(e,{bubbles:!0,cancelable:!0,detail:n}),t.dispatchEvent(r),!r.defaultPrevented},v.stopEverything=function(t){return e(t.target,"ujs:everythingStopped"),t.preventDefault(),t.stopPropagation(),t.stopImmediatePropagation()},v.delegate=function(t,n,e,r){return t.addEventListener(e,function(t){var e;for(e=t.target;e instanceof Element&&!o(e,n);)e=e.parentNode;if(e instanceof Element&&!1===r.call(e,t))return t.preventDefault(),t.stopPropagation()})}}.call(this),function(){var e,r,t,o,i,a;o=v.cspNonce,r=v.CSRFProtection,v.fire,e={"*":"*/*",text:"text/plain",html:"text/html",xml:"application/xml, text/xml",json:"application/json, text/javascript",script:"text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"},v.ajax=function(n){var r;return n=i(n),r=t(n,function(){var t,e;return e=a(null!=(t=r.response)?t:r.responseText,r.getResponseHeader("Content-Type")),2===Math.floor(r.status/100)?"function"==typeof n.success&&n.success(e,r.statusText,r):"function"==typeof n.error&&n.error(e,r.statusText,r),"function"==typeof n.complete?n.complete(r,r.statusText):void 0}),!(null!=n.beforeSend&&!n.beforeSend(r,n))&&(r.readyState===XMLHttpRequest.OPENED?r.send(n.data):void 0)},i=function(t){return t.url=t.url||location.href,t.type=t.type.toUpperCase(),"GET"===t.type&&t.data&&(t.url.indexOf("?")<0?t.url+="?"+t.data:t.url+="&"+t.data),null==e[t.dataType]&&(t.dataType="*"),t.accept=e[t.dataType],"*"!==t.dataType&&(t.accept+=", */*; q=0.01"),t},t=function(t,e){var n;return(n=new XMLHttpRequest).open(t.type,t.url,!0),n.setRequestHeader("Accept",t.accept),"string"==typeof t.data&&n.setRequestHeader("Content-Type","application/x-www-form-urlencoded; charset=UTF-8"),t.crossDomain||n.setRequestHeader("X-Requested-With","XMLHttpRequest"),r(n),n.withCredentials=!!t.withCredentials,n.onreadystatechange=function(){if(n.readyState===XMLHttpRequest.DONE)return e(n)},n},a=function(t,e){var n,r;if("string"==typeof t&&"string"==typeof e)if(e.match(/\bjson\b/))try{t=JSON.parse(t)}catch(i){}else if(e.match(/\b(?:java|ecma)script\b/))(r=document.createElement("script")).setAttribute("nonce",o()),r.text=t,document.head.appendChild(r).parentNode.removeChild(r);else if(e.match(/\b(xml|html|svg)\b/)){n=new DOMParser,e=e.replace(/;.+/,"");try{t=n.parseFromString(t,e)}catch(i){}}return t},v.href=function(t){return t.href},v.isCrossDomain=function(t){var e,n;(e=document.createElement("a")).href=location.href,n=document.createElement("a");try{return n.href=t,!((!n.protocol||":"===n.protocol)&&!n.host||e.protocol+"//"+e.host==n.protocol+"//"+n.host)}catch(r){return r,!0}}}.call(this),function(){var i,o;i=v.matches,o=function(t){return Array.prototype.slice.call(t)},v.serializeElement=function(t,e){var n,r;return n=[t],i(t,"form")&&(n=o(t.elements)),r=[],n.forEach(function(e){if(e.name&&!e.disabled)return i(e,"select")?o(e.options).forEach(function(t){if(t.selected)return r.push({name:e.name,value:t.value})}):e.checked||-1===["radio","checkbox","submit"].indexOf(e.type)?r.push({name:e.name,value:e.value}):void 0}),e&&r.push(e),r.map(function(t){return null!=t.name?encodeURIComponent(t.name)+"="+encodeURIComponent(t.value):t}).join("&")},v.formElements=function(t,e){return i(t,"form")?o(t.elements).filter(function(t){return i(t,e)}):o(t.querySelectorAll(e))}}.call(this),function(){var e,o,n;o=v.fire,n=v.stopEverything,v.handleConfirm=function(t){if(!e(this))return n(t)},e=function(t){var e,n,r;if(!(r=t.getAttribute("data-confirm")))return!0;if(e=!1,o(t,"confirm")){try{e=confirm(r)}catch(i){}n=o(t,"confirm:complete",[e])}return e&&n}}.call(this),function(){var n,r,i,o,a,s,e,l,u,c,d;u=v.matches,l=v.getData,c=v.setData,d=v.stopEverything,e=v.formElements,v.handleDisabledElement=function(t){if(this.disabled)return d(t)},v.enableElement=function(t){var e;return e=t instanceof Event?t.target:t,u(e,v.linkDisableSelector)?s(e):u(e,v.buttonDisableSelector)||u(e,v.formEnableSelector)?o(e):u(e,v.formSubmitSelector)?a(e):void 0},v.disableElement=function(t){var e;return e=t instanceof Event?t.target:t,u(e,v.linkDisableSelector)?i(e):u(e,v.buttonDisableSelector)||u(e,v.formDisableSelector)?n(e):u(e,v.formSubmitSelector)?r(e):void 0},i=function(t){var e;return null!=(e=t.getAttribute("data-disable-with"))&&(c(t,"ujs:enable-with",t.innerHTML),t.innerHTML=e),t.addEventListener("click",d),c(t,"ujs:disabled",!0)},s=function(t){var e;return null!=(e=l(t,"ujs:enable-with"))&&(t.innerHTML=e,c(t,"ujs:enable-with",null)),t.removeEventListener("click",d),c(t,"ujs:disabled",null)},r=function(t){return e(t,v.formDisableSelector).forEach(n)},n=function(t){var e;return null!=(e=t.getAttribute("data-disable-with"))&&(u(t,"button")?(c(t,"ujs:enable-with",t.innerHTML),t.innerHTML=e):(c(t,"ujs:enable-with",t.value),t.value=e)),t.disabled=!0,c(t,"ujs:disabled",!0)},a=function(t){return e(t,v.formEnableSelector).forEach(o)},o=function(t){var e;return null!=(e=l(t,"ujs:enable-with"))&&(u(t,"button")?t.innerHTML=e:t.value=e,c(t,"ujs:enable-with",null)),t.disabled=!1,c(t,"ujs:disabled",null)}}.call(this),function(){var l;l=v.stopEverything,v.handleMethod=function(t){var e,n,r,i,o,a,s;if(s=(a=this).getAttribute("data-method"))return o=v.href(a),n=v.csrfToken(),e=v.csrfParam(),r=document.createElement("form"),i="<input name='_method' value='"+s+"' type='hidden' />",null==e||null==n||v.isCrossDomain(o)||(i+="<input name='"+e+"' value='"+n+"' type='hidden' />"),i+='<input type="submit" />',r.method="post",r.action=o,r.target=a.target,r.innerHTML=i,r.style.display="none",document.body.appendChild(r),r.querySelector('[type="submit"]').click(),l(t)}}.call(this),function(){var l,u,c,d,h,f,p,g,m,y=[].slice;f=v.matches,c=v.getData,g=v.setData,u=v.fire,m=v.stopEverything,l=v.ajax,d=v.isCrossDomain,p=v.serializeElement,h=function(t){var e;return null!=(e=t.getAttribute("data-remote"))&&"false"!==e},v.handleRemote=function(t){var e,n,r,i,o,a,s;return!h(i=this)||(u(i,"ajax:before")?(s=i.getAttribute("data-with-credentials"),r=i.getAttribute("data-type")||"script",f(i,v.formSubmitSelector)?(e=c(i,"ujs:submit-button"),o=c(i,"ujs:submit-button-formmethod")||i.method,a=c(i,"ujs:submit-button-formaction")||i.getAttribute("action")||location.href,"GET"===o.toUpperCase()&&(a=a.replace(/\?.*$/,"")),"multipart/form-data"===i.enctype?(n=new FormData(i),null!=e&&n.append(e.name,e.value)):n=p(i,e),g(i,"ujs:submit-button",null),g(i,"ujs:submit-button-formmethod",null),g(i,"ujs:submit-button-formaction",null)):f(i,v.buttonClickSelector)||f(i,v.inputChangeSelector)?(o=i.getAttribute("data-method"),a=i.getAttribute("data-url"),n=p(i,i.getAttribute("data-params"))):(o=i.getAttribute("data-method"),a=v.href(i),n=i.getAttribute("data-params")),l({type:o||"GET",url:a,data:n,dataType:r,beforeSend:function(t,e){return u(i,"ajax:beforeSend",[t,e])?u(i,"ajax:send",[t]):(u(i,"ajax:stopped"),!1)},success:function(){var t;return t=1<=arguments.length?y.call(arguments,0):[],u(i,"ajax:success",t)},error:function(){var t;return t=1<=arguments.length?y.call(arguments,0):[],u(i,"ajax:error",t)},complete:function(){var t;return t=1<=arguments.length?y.call(arguments,0):[],u(i,"ajax:complete",t)},crossDomain:d(a),withCredentials:null!=s&&"false"!==s}),m(t)):(u(i,"ajax:stopped"),!1))},v.formSubmitButtonClick=function(){var t,e;if(e=(t=this).form)return t.name&&g(e,"ujs:submit-button",{name:t.name,value:t.value}),g(e,"ujs:formnovalidate-button",t.formNoValidate),g(e,"ujs:submit-button-formaction",t.getAttribute("formaction")),g(e,"ujs:submit-button-formmethod",t.getAttribute("formmethod"))},v.preventInsignificantClick=function(t){var e,n,r,i;if(i=((r=this).getAttribute("data-method")||"GET").toUpperCase(),e=r.getAttribute("data-params"),n=(t.metaKey||t.ctrlKey)&&"GET"===i&&!e,null!=t.button&&0!==t.button||n)return t.stopImmediatePropagation()}}.call(this),function(){var t,r,e,n,i,o,a,s,l,u,c,d,h,f,p;if(o=v.fire,e=v.delegate,s=v.getData,t=v.$,p=v.refreshCSRFTokens,r=v.CSRFProtection,h=v.loadCSPNonce,i=v.enableElement,n=v.disableElement,u=v.handleDisabledElement,l=v.handleConfirm,f=v.preventInsignificantClick,d=v.handleRemote,a=v.formSubmitButtonClick,c=v.handleMethod,"undefined"!=typeof jQuery&&null!==jQuery&&null!=jQuery.ajax){if(jQuery.rails)throw new Error("If you load both jquery_ujs and rails-ujs, use rails-ujs only.");jQuery.rails=v,jQuery.ajaxPrefilter(function(t,e,n){if(!t.crossDomain)return r(n)})}v.start=function(){if(window._rails_loaded)throw new Error("rails-ujs has already been loaded!");return window.addEventListener("pageshow",function(){return t(v.formEnableSelector).forEach(function(t){if(s(t,"ujs:disabled"))return i(t)}),t(v.linkDisableSelector).forEach(function(t){if(s(t,"ujs:disabled"))return i(t)})}),e(document,v.linkDisableSelector,"ajax:complete",i),e(document,v.linkDisableSelector,"ajax:stopped",i),e(document,v.buttonDisableSelector,"ajax:complete",i),e(document,v.buttonDisableSelector,"ajax:stopped",i),e(document,v.linkClickSelector,"click",f),e(document,v.linkClickSelector,"click",u),e(document,v.linkClickSelector,"click",l),e(document,v.linkClickSelector,"click",n),e(document,v.linkClickSelector,"click",d),e(document,v.linkClickSelector,"click",c),e(document,v.buttonClickSelector,"click",f),e(document,v.buttonClickSelector,"click",u),e(document,v.buttonClickSelector,"click",l),e(document,v.buttonClickSelector,"click",n),e(document,v.buttonClickSelector,"click",d),e(document,v.inputChangeSelector,"change",u),e(document,v.inputChangeSelector,"change",l),e(document,v.inputChangeSelector,"change",d),e(document,v.formSubmitSelector,"submit",u),e(document,v.formSubmitSelector,"submit",l),e(document,v.formSubmitSelector,"submit",d),e(document,v.formSubmitSelector,"submit",function(t){return setTimeout(function(){return n(t)},13)}),e(document,v.formSubmitSelector,"ajax:send",n),e(document,v.formSubmitSelector,"ajax:complete",i),e(document,v.formInputClickSelector,"click",f),e(document,v.formInputClickSelector,"click",u),e(document,v.formInputClickSelector,"click",l),e(document,v.formInputClickSelector,"click",a),document.addEventListener("DOMContentLoaded",p),document.addEventListener("DOMContentLoaded",h),window._rails_loaded=!0},window.Rails===v&&o(document,"rails:attachBindings")&&v.start()}.call(this)}).call(this),"object"==typeof module&&module.exports?module.exports=v:"function"==typeof define&&define.amd&&define(v)}).call(this),function(t,e){"object"==typeof exports&&"undefined"!=typeof module?e(exports):"function"==typeof define&&define.amd?define(["exports"],e):e(t.ActiveStorage={})}(this,function(t){"use strict";function e(t,e){return t(e={exports:{}},e.exports),e.exports}function a(t){var e=r(document.head,'meta[name="'+t+'"]');if(e)return e.getAttribute("content")}function i(t,e){return"string"==typeof t&&(e=t,t=document),o(t.querySelectorAll(e))}function r(t,e){return"string"==typeof t&&(e=t,t=document),t.querySelector(e)}function l(t,e,n){var r=2<arguments.length&&n!==undefined?arguments[2]:{},i=t.disabled,o=r.bubbles,a=r.cancelable,s=r.detail,l=document.createEvent("Event");l.initEvent(e,o||!0,a||!0),l.detail=s||{};try{t.disabled=!1,t.dispatchEvent(l)}finally{t.disabled=i}return l}function o(t){return Array.isArray(t)?t:Array.from?Array.from(t):[].slice.call(t)}function s(t,e){if(t&&"function"==typeof t[e]){for(var n=arguments.length,r=Array(2<n?n-2:0),i=2;i<n;i++)r[i-2]=arguments[i];return t[e].apply(t,r)}}function n(){O||(O=!0,document.addEventListener("click",u,!0),document.addEventListener("submit",c),document.addEventListener("ajax:before",d))}function u(t){var e=t.target;"INPUT"!=e.tagName&&"BUTTON"!=e.tagName||"submit"!=e.type||!e.form||M.set(e.form,e)}function c(t){h(t)}function d(t){"FORM"==t.target.tagName&&h(t)}function h(t){var e=t.target;if(e.hasAttribute(A))t.preventDefault();else{var n=new D(e),r=n.inputs;r.length&&(t.preventDefault(),e.setAttribute(A,""),r.forEach(p),n.start(function(t){e.removeAttribute(A),t?r.forEach(g):f(e)}))}}function f(t){var e=M.get(t)||r(t,"input[type=submit], button[type=submit]");if(e){var n=e.disabled;e.disabled=!1,e.focus(),e.click(),e.disabled=n}else(e=document.createElement("input")).type="submit",e.style.display="none",t.appendChild(e),e.click(),t.removeChild(e);M["delete"](t)}function p(t){t.disabled=!0}function g(t){t.disabled=!1}function m(){window.ActiveStorage&&n()}var y=e(function(t){var e;e=function(c){function u(t,e){var n=t[0],r=t[1],i=t[2],o=t[3];r=((r+=((i=((i+=((o=((o+=((n=((n+=(r&i|~r&o)+e[0]-680876936|0)<<7|n>>>25)+r|0)&r|~n&i)+e[1]-389564586|0)<<12|o>>>20)+n|0)&n|~o&r)+e[2]+606105819|0)<<17|i>>>15)+o|0)&o|~i&n)+e[3]-1044525330|0)<<22|r>>>10)+i|0,r=((r+=((i=((i+=((o=((o+=((n=((n+=(r&i|~r&o)+e[4]-176418897|0)<<7|n>>>25)+r|0)&r|~n&i)+e[5]+1200080426|0)<<12|o>>>20)+n|0)&n|~o&r)+e[6]-1473231341|0)<<17|i>>>15)+o|0)&o|~i&n)+e[7]-45705983|0)<<22|r>>>10)+i|0,r=((r+=((i=((i+=((o=((o+=((n=((n+=(r&i|~r&o)+e[8]+1770035416|0)<<7|n>>>25)+r|0)&r|~n&i)+e[9]-1958414417|0)<<12|o>>>20)+n|0)&n|~o&r)+e[10]-42063|0)<<17|i>>>15)+o|0)&o|~i&n)+e[11]-1990404162|0)<<22|r>>>10)+i|0,r=((r+=((i=((i+=((o=((o+=((n=((n+=(r&i|~r&o)+e[12]+1804603682|0)<<7|n>>>25)+r|0)&r|~n&i)+e[13]-40341101|0)<<12|o>>>20)+n|0)&n|~o&r)+e[14]-1502002290|0)<<17|i>>>15)+o|0)&o|~i&n)+e[15]+1236535329|0)<<22|r>>>10)+i|0,r=((r+=((i=((i+=((o=((o+=((n=((n+=(r&o|i&~o)+e[1]-165796510|0)<<5|n>>>27)+r|0)&i|r&~i)+e[6]-1069501632|0)<<9|o>>>23)+n|0)&r|n&~r)+e[11]+643717713|0)<<14|i>>>18)+o|0)&n|o&~n)+e[0]-373897302|0)<<20|r>>>12)+i|0,r=((r+=((i=((i+=((o=((o+=((n=((n+=(r&o|i&~o)+e[5]-701558691|0)<<5|n>>>27)+r|0)&i|r&~i)+e[10]+38016083|0)<<9|o>>>23)+n|0)&r|n&~r)+e[15]-660478335|0)<<14|i>>>18)+o|0)&n|o&~n)+e[4]-405537848|0)<<20|r>>>12)+i|0,r=((r+=((i=((i+=((o=((o+=((n=((n+=(r&o|i&~o)+e[9]+568446438|0)<<5|n>>>27)+r|0)&i|r&~i)+e[14]-1019803690|0)<<9|o>>>23)+n|0)&r|n&~r)+e[3]-187363961|0)<<14|i>>>18)+o|0)&n|o&~n)+e[8]+1163531501|0)<<20|r>>>12)+i|0,r=((r+=((i=((i+=((o=((o+=((n=((n+=(r&o|i&~o)+e[13]-1444681467|0)<<5|n>>>27)+r|0)&i|r&~i)+e[2]-51403784|0)<<9|o>>>23)+n|0)&r|n&~r)+e[7]+1735328473|0)<<14|i>>>18)+o|0)&n|o&~n)+e[12]-1926607734|0)<<20|r>>>12)+i|0,r=((r+=((i=((i+=((o=((o+=((n=((n+=(r^i^o)+e[5]-378558|0)<<4|n>>>28)+r|0)^r^i)+e[8]-2022574463|0)<<11|o>>>21)+n|0)^n^r)+e[11]+1839030562|0)<<16|i>>>16)+o|0)^o^n)+e[14]-35309556|0)<<23|r>>>9)+i|0,r=((r+=((i=((i+=((o=((o+=((n=((n+=(r^i^o)+e[1]-1530992060|0)<<4|n>>>28)+r|0)^r^i)+e[4]+1272893353|0)<<11|o>>>21)+n|0)^n^r)+e[7]-155497632|0)<<16|i>>>16)+o|0)^o^n)+e[10]-1094730640|0)<<23|r>>>9)+i|0,r=((r+=((i=((i+=((o=((o+=((n=((n+=(r^i^o)+e[13]+681279174|0)<<4|n>>>28)+r|0)^r^i)+e[0]-358537222|0)<<11|o>>>21)+n|0)^n^r)+e[3]-722521979|0)<<16|i>>>16)+o|0)^o^n)+e[6]+76029189|0)<<23|r>>>9)+i|0,r=((r+=((i=((i+=((o=((o+=((n=((n+=(r^i^o)+e[9]-640364487|0)<<4|n>>>28)+r|0)^r^i)+e[12]-421815835|0)<<11|o>>>21)+n|0)^n^r)+e[15]+530742520|0)<<16|i>>>16)+o|0)^o^n)+e[2]-995338651|0)<<23|r>>>9)+i|0,r=((r+=((o=((o+=(r^((n=((n+=(i^(r|~o))+e[0]-198630844|0)<<6|n>>>26)+r|0)|~i))+e[7]+1126891415|0)<<10|o>>>22)+n|0)^((i=((i+=(n^(o|~r))+e[14]-1416354905|0)<<15|i>>>17)+o|0)|~n))+e[5]-57434055|0)<<21|r>>>11)+i|0,r=((r+=((o=((o+=(r^((n=((n+=(i^(r|~o))+e[12]+1700485571|0)<<6|n>>>26)+r|0)|~i))+e[3]-1894986606|0)<<10|o>>>22)+n|0)^((i=((i+=(n^(o|~r))+e[10]-1051523|0)<<15|i>>>17)+o|0)|~n))+e[1]-2054922799|0)<<21|r>>>11)+i|0,r=((r+=((o=((o+=(r^((n=((n+=(i^(r|~o))+e[8]+1873313359|0)<<6|n>>>26)+r|0)|~i))+e[15]-30611744|0)<<10|o>>>22)+n|0)^((i=((i+=(n^(o|~r))+e[6]-1560198380|0)<<15|i>>>17)+o|0)|~n))+e[13]+1309151649|0)<<21|r>>>11)+i|0,r=((r+=((o=((o+=(r^((n=((n+=(i^(r|~o))+e[4]-145523070|0)<<6|n>>>26)+r|0)|~i))+e[11]-1120210379|0)<<10|o>>>22)+n|0)^((i=((i+=(n^(o|~r))+e[2]+718787259|0)<<15|i>>>17)+o|0)|~n))+e[9]-343485551|0)<<21|r>>>11)+i|0,t[0]=n+t[0]|0,t[1]=r+t[1]|0,t[2]=i+t[2]|0,t[3]=o+t[3]|0}function d(t){var e,n=[];for(e=0;e<64;e+=4)n[e>>2]=t.charCodeAt(e)+(t.charCodeAt(e+1)<<8)+(t.charCodeAt(e+2)<<16)+(t.charCodeAt(e+3)<<24);return n}function h(t){var e,n=[];for(e=0;e<64;e+=4)n[e>>2]=t[e]+(t[e+1]<<8)+(t[e+2]<<16)+(t[e+3]<<24);return n}function r(t){var e,n,r,i,o,a,s=t.length,l=[1732584193,-271733879,-1732584194,271733878];for(e=64;e<=s;e+=64)u(l,d(t.substring(e-64,e)));for(n=(t=t.substring(e-64)).length,r=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],e=0;e<n;e+=1)r[e>>2]|=t.charCodeAt(e)<<(e%4<<3);if(r[e>>2]|=128<<(e%4<<3),55<e)for(u(l,r),e=0;e<16;e+=1)r[e]=0;return i=(i=8*s).toString(16).match(/(.*?)(.{0,8})$/),o=parseInt(i[2],16),a=parseInt(i[1],16)||0,r[14]=o,r[15]=a,u(l,r),l}function i(t){var e,n,r,i,o,a,s=t.length,l=[1732584193,-271733879,-1732584194,271733878];for(e=64;e<=s;e+=64)u(l,h(t.subarray(e-64,e)));for(n=(t=e-64<s?t.subarray(e-64):new Uint8Array(0)).length,r=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],e=0;e<n;e+=1)r[e>>2]|=t[e]<<(e%4<<3);if(r[e>>2]|=128<<(e%4<<3),55<e)for(u(l,r),e=0;e<16;e+=1)r[e]=0;return i=(i=8*s).toString(16).match(/(.*?)(.{0,8})$/),o=parseInt(i[2],16),a=parseInt(i[1],16)||0,r[14]=o,r[15]=a,u(l,r),l}function n(t){var e,n="";for(e=0;e<4;e+=1)n+=g[t>>8*e+4&15]+g[t>>8*e&15];return n}function a(t){var e;for(e=0;e<t.length;e+=1)t[e]=n(t[e]);return t.join("")}function o(t){return/[\u0080-\uFFFF]/.test(t)&&(t=unescape(encodeURIComponent(t))),t}function e(t,e){var n,r=t.length,i=new ArrayBuffer(r),o=new Uint8Array(i);for(n=0;n<r;n+=1)o[n]=t.charCodeAt(n);return e?o:i}function s(t){return String.fromCharCode.apply(null,new Uint8Array(t))}function l(t,e,n){var r=new Uint8Array(t.byteLength+e.byteLength);return r.set(new Uint8Array(t)),r.set(new Uint8Array(e),t.byteLength),n?r:r.buffer}function f(t){var e,n=[],r=t.length;for(e=0;e<r-1;e+=2)n.push(parseInt(t.substr(e,2),16));return String.fromCharCode.apply(String,n)}function p(){this.reset()}var g=["0","1","2","3","4","5","6","7","8","9","a","b","c","d","e","f"];return a(r("hello")),"undefined"==typeof ArrayBuffer||ArrayBuffer.prototype.slice||function(){function u(t,e){return(t=0|t||0)<0?Math.max(t+e,0):Math.min(t,e)}ArrayBuffer.prototype.slice=function(t,e){var n,r,i,o,a=this.byteLength,s=u(t,a),l=a;return e!==c&&(l=u(e,a)),l<s?new ArrayBuffer(0):(n=l-s,r=new ArrayBuffer(n),i=new Uint8Array(r),o=new Uint8Array(this,s,n),i.set(o),r)}}(),p.prototype.append=function(t){return this.appendBinary(o(t)),this},p.prototype.appendBinary=function(t){this._buff+=t,this._length+=t.length;var e,n=this._buff.length;for(e=64;e<=n;e+=64)u(this._hash,d(this._buff.substring(e-64,e)));return this._buff=this._buff.substring(e-64),this},p.prototype.end=function(t){var e,n,r=this._buff,i=r.length,o=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0];for(e=0;e<i;e+=1)o[e>>2]|=r.charCodeAt(e)<<(e%4<<3);return this._finish(o,i),n=a(this._hash),t&&(n=f(n)),this.reset(),n},p.prototype.reset=function(){return this._buff="",this._length=0,this._hash=[1732584193,-271733879,-1732584194,271733878],this},p.prototype.getState=function(){return{buff:this._buff,length:this._length,hash:this._hash}},p.prototype.setState=function(t){return this._buff=t.buff,this._length=t.length,this._hash=t.hash,this},p.prototype.destroy=function(){delete this._hash,delete this._buff,delete this._length},p.prototype._finish=function(t,e){var n,r,i,o=e;if(t[o>>2]|=128<<(o%4<<3),55<o)for(u(this._hash,t),o=0;o<16;o+=1)t[o]=0;n=(n=8*this._length).toString(16).match(/(.*?)(.{0,8})$/),r=parseInt(n[2],16),i=parseInt(n[1],16)||0,t[14]=r,t[15]=i,u(this._hash,t)},p.hash=function(t,e){return p.hashBinary(o(t),e)},p.hashBinary=function(t,e){var n=a(r(t));return e?f(n):n},p.ArrayBuffer=function(){this.reset()},p.ArrayBuffer.prototype.append=function(t){var e,n=l(this._buff.buffer,t,!0),r=n.length;for(this._length+=t.byteLength,e=64;e<=r;e+=64)u(this._hash,h(n.subarray(e-64,e)));return this._buff=e-64<r?new Uint8Array(n.buffer.slice(e-64)):new Uint8Array(0),this},p.ArrayBuffer.prototype.end=function(t){var e,n,r=this._buff,i=r.length,o=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0];for(e=0;e<i;e+=1)o[e>>2]|=r[e]<<(e%4<<3);return this._finish(o,i),n=a(this._hash),t&&(n=f(n)),this.reset(),n},p.ArrayBuffer.prototype.reset=function(){return this._buff=new Uint8Array(0),this._length=0,this._hash=[1732584193,-271733879,-1732584194,271733878],this},p.ArrayBuffer.prototype.getState=function(){var t=p.prototype.getState.call(this);return t.buff=s(t.buff),t},p.ArrayBuffer.prototype.setState=function(t){return t.buff=e(t.buff,!0),p.prototype.setState.call(this,t)},p.ArrayBuffer.prototype.destroy=p.prototype.destroy,p.ArrayBuffer.prototype._finish=p.prototype._finish,p.ArrayBuffer.hash=function(t,e){var n=a(i(new Uint8Array(t)));return e?f(n):n},p},t.exports=e()}),v=function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")},b=function(){function r(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(t,e,n){return e&&r(t.prototype,e),n&&r(t,n),t}}(),_=File.prototype.slice||File.prototype.mozSlice||File.prototype.webkitSlice,x=function(){function n(t){v(this,n),this.file=t,this.chunkSize=2097152,this.chunkCount=Math.ceil(this.file.size/this.chunkSize),this.chunkIndex=0}return b(n,null,[{key:"create",value:function r(t,e){new n(t).create(e)}}]),b(n,[{key:"create",value:function r(t){var e=this;this.callback=t,this.md5Buffer=new y.ArrayBuffer,this.fileReader=new FileReader,this.fileReader.addEventListener("load",function(t){return e.fileReaderDidLoad(t)}),this.fileReader.addEventListener("error",function(t){return e.fileReaderDidError(t)}),this.readNextChunk()}},{key:"fileReaderDidLoad",value:function i(t){if(this.md5Buffer.append(t.target.result),!this.readNextChunk()){var e=this.md5Buffer.end(!0),n=btoa(e);this.callback(null,n)}}},{key:"fileReaderDidError",value:function t(){this.callback("Error reading "+this.file.name)}},{key:"readNextChunk",value:function o(){if(this.chunkIndex<this.chunkCount||0==this.chunkIndex&&0==this.chunkCount){var t=this.chunkIndex*this.chunkSize,e=Math.min(t+this.chunkSize,this.file.size),n=_.call(this.file,t,e);return this.fileReader.readAsArrayBuffer(n),this.chunkIndex++,!0}return!1}}]),n}(),w=function(){function i(t,e,n){var r=this;v(this,i),this.file=t,this.attributes={filename:t.name,content_type:t.type,byte_size:t.size,checksum:e},this.xhr=new XMLHttpRequest,this.xhr.open("POST",n,!0),this.xhr.responseType="json",this.xhr.setRequestHeader("Content-Type","application/json"),this.xhr.setRequestHeader("Accept","application/json"),this.xhr.setRequestHeader("X-Requested-With","XMLHttpRequest"),this.xhr.setRequestHeader("X-CSRF-Token",a("csrf-token")),this.xhr.addEventListener("load",function(t){return r.requestDidLoad(t)}),this.xhr.addEventListener("error",function(t){return r.requestDidError(t)})}return b(i,[{key:"create",value:function e(t){this.callback=t,this.xhr.send(JSON.stringify({blob:this.attributes}))}},{key:"requestDidLoad",value:function r(t){if(200<=this.status&&this.status<300){var e=this.response,n=e.direct_upload;delete e.direct_upload,this.attributes=e,this.directUploadData=n,this.callback(null,this.toJSON())}else this.requestDidError(t)}},{key:"requestDidError",value:function t(){this.callback('Error creating Blob for "'+this.file.name+'". Status: '+this.status)}},{key:"toJSON",value:function n(){var t={};for(var e in this.attributes)t[e]=this.attributes[e];return t}},{key:"status",get:function o(){return this.xhr.status}},{key:"response",get:function o(){var t=this.xhr,e=t.responseType,n=t.response;return"json"==e?n:JSON.parse(n)}}]),i}(),S=function(){function a(t){var e=this;v(this,a),this.blob=t,this.file=t.file;var n=t.directUploadData,r=n.url,i=n.headers;for(var o in this.xhr=new XMLHttpRequest,this.xhr.open("PUT",r,!0),this.xhr.responseType="text",i)this.xhr.setRequestHeader(o,i[o]);this.xhr.addEventListener("load",function(t){return e.requestDidLoad(t)}),this.xhr.addEventListener("error",function(t){return e.requestDidError(t)})}return b(a,[{key:"create",value:function e(t){this.callback=t,this.xhr.send(this.file.slice())}},{key:"requestDidLoad",value:function i(t){var e=this.xhr,n=e.status,r=e.response;200<=n&&n<300?this.callback(null,r):this.requestDidError(t)}},{key:"requestDidError",value:function t(){this.callback('Error storing "'+this.file.name+'". Status: '+this.xhr.status)}}]),a}(),T=0,k=function(){function r(t,e,n){v(this,r),this.id=++T,this.file=t,this.url=e,this.delegate=n}return b(r,[{key:"create",value:function t(r){var i=this;x.create(this.file,function(t,e){if(t)r(t);else{var n=new w(i.file,e,i.url);s(i.delegate,"directUploadWillCreateBlobWithXHR",n.xhr),n.create(function(t){if(t)r(t);else{var e=new S(n);s(i.delegate,"directUploadWillStoreFileWithXHR",e.xhr),e.create(function(t){t?r(t):r(null,n.toJSON())})}})}})}}]),r}(),C=function(){function n(t,e){v(this,n),this.input=t,this.file=e,this.directUpload=new k(this.file,this.url,this),this.dispatch("initialize")}return b(n,[{key:"start",value:function t(n){var r=this,i=document.createElement("input");i.type="hidden",i.name=this.input.name,this.input.insertAdjacentElement("beforebegin",i),this.dispatch("start"),this.directUpload.create(function(t,e){t?(i.parentNode.removeChild(i),r.dispatchError(t)):i.value=e.signed_id,r.dispatch("end"),n(t)})}},{key:"uploadRequestDidProgress",value:function r(t){var e=t.loaded/t.total*100;e&&this.dispatch("progress",{progress:e})}},{key:"dispatch",value:function i(t,e){var n=1<arguments.length&&e!==undefined?arguments[1]:{};return n.file=this.file,n.id=this.directUpload.id,l(this.input,"direct-upload:"+t,{detail:n})}},{key:"dispatchError",value:function e(t){this.dispatch("error",{error:t}).defaultPrevented||alert(t)}},{key:"directUploadWillCreateBlobWithXHR",value:function o(t){this.dispatch("before-blob-request",{xhr:t})}},{key:"directUploadWillStoreFileWithXHR",value:function a(t){var e=this;this.dispatch("before-storage-request",{xhr:t}),t.upload.addEventListener("progress",function(t){return e.uploadRequestDidProgress(t)})}},{key:"url",get:function s(){return this.input.getAttribute("data-direct-upload-url")}}]),n}(),E="input[type=file][data-direct-upload-url]:not([disabled])",D=function(){function e(t){v(this,e),this.form=t,this.inputs=i(t,E).filter(function(t){return t.files.length})}return b(e,[{key:"start",value:function t(e){var n=this,r=this.createDirectUploadControllers(),i=function i(){var t=r.shift();t?t.start(function(t){t?(e(t),n.dispatch("end")):i()}):(e(),n.dispatch("end"))};this.dispatch("start"),i()}},{key:"createDirectUploadControllers",value:function n(){var r=[];return this.inputs.forEach(function(n){o(n.files).forEach(function(t){var e=new C(n,t);r.push(e)})}),r}},{key:"dispatch",value:function r(t,e){var n=1<arguments.length&&e!==undefined?arguments[1]:{};return l(this.form,"direct-uploads:"+t,{detail:n})}}]),e}(),A="data-direct-uploads-processing",M=new WeakMap,O=!1;setTimeout(m,1),t.start=n,t.DirectUpload=k,Object.defineProperty(t,"__esModule",{value:!0})}),function(){var t=this;(function(){(function(){this.Turbolinks={supported:null!=window.history.pushState&&null!=window.requestAnimationFrame&&null!=window.addEventListener,visit:function(t,e){return c.controller.visit(t,e)},clearCache:function(){return c.controller.clearCache()},setProgressBarDelay:function(t){return c.controller.setProgressBarDelay(t)}}}).call(this)}).call(t);var c=t.Turbolinks;(function(){(function(){var n,r,l,t,e,i,o,a,s,u=[].slice;c.copyObject=function(t){var e,n,r;for(e in n={},t)r=t[e],n[e]=r;return n},c.closest=function(t,e){return n.call(t,e)},n=null!=(s=document.documentElement.closest)?s:function(t){var e;for(e=this;e;){if(e.nodeType===Node.ELEMENT_NODE&&r.call(e,t))return e;e=e.parentNode}},c.defer=function(t){return setTimeout(t,1)},c.throttle=function(n){var r;return r=null,function(){var t,e;return t=1<=arguments.length?u.call(arguments,0):[],null!=r?r:r=requestAnimationFrame((e=this,function(){return r=null,n.apply(e,t)}))}},c.dispatch=function(t,e){var n,r,i,o,a,s;return s=(a=null!=e?e:{}).target,n=a.cancelable,r=a.data,(i=document.createEvent("Events")).initEvent(t,!0,!0===n),i.data=null!=r?r:{},i.cancelable&&!l&&(o=i.preventDefault,i.preventDefault=function(){return this.defaultPrevented||Object.defineProperty(this,"defaultPrevented",{get:function(){return!0}}),o.call(this)}),(null!=s?s:document).dispatchEvent(i),i},(a=document.createEvent("Events")).initEvent("test",!0,!0),a.preventDefault(),l=a.defaultPrevented,c.match=function(t,e){return r.call(t,e)},r=null!=(e=null!=(i=null!=(o=(t=document.documentElement).matchesSelector)?o:t.webkitMatchesSelector)?i:t.msMatchesSelector)?e:t.mozMatchesSelector,c.uuid=function(){var t,e,n;for(n="",t=e=1;e<=36;t=++e)n+=9===t||14===t||19===t||24===t?"-":15===t?"4":20===t?(Math.floor(4*Math.random())+8).toString(16):Math.floor(15*Math.random()).toString(16);return n}}).call(this),function(){c.Location=function(){function t(t){var e,n;null==t&&(t=""),(n=document.createElement("a")).href=t.toString(),this.absoluteURL=n.href,(e=n.hash.length)<2?this.requestURL=this.absoluteURL:(this.requestURL=this.absoluteURL.slice(0,-e),this.anchor=n.hash.slice(1))}var e,n,r,i;return t.wrap=function(t){return t instanceof this?t:new this(t)},t.prototype.getOrigin=function(){return this.absoluteURL.split("/",3).join("/")},t.prototype.getPath=function(){var t,e;return null!=(t=null!=(e=this.requestURL.match(/\/\/[^\/]*(\/[^?;]*)/))?e[1]:void 0)?t:"/"},t.prototype.getPathComponents=function(){return this.getPath().split("/").slice(1)},t.prototype.getLastPathComponent=function(){return this.getPathComponents().slice(-1)[0]},t.prototype.getExtension=function(){var t,e;return null!=(t=null!=(e=this.getLastPathComponent().match(/\.[^.]*$/))?e[0]:void 0)?t:""},t.prototype.isHTML=function(){return this.getExtension().match(/^(?:|\.(?:htm|html|xhtml))$/)},t.prototype.isPrefixedBy=function(t
){var e;return e=n(t),this.isEqualTo(t)||i(this.absoluteURL,e)},t.prototype.isEqualTo=function(t){return this.absoluteURL===(null!=t?t.absoluteURL:void 0)},t.prototype.toCacheKey=function(){return this.requestURL},t.prototype.toJSON=function(){return this.absoluteURL},t.prototype.toString=function(){return this.absoluteURL},t.prototype.valueOf=function(){return this.absoluteURL},n=function(t){return e(t.getOrigin()+t.getPath())},e=function(t){return r(t,"/")?t:t+"/"},i=function(t,e){return t.slice(0,e.length)===e},r=function(t,e){return t.slice(-e.length)===e},t}()}.call(this),function(){var r=function(t,e){return function(){return t.apply(e,arguments)}};c.HttpRequest=function(){function t(t,e,n){this.delegate=t,this.requestCanceled=r(this.requestCanceled,this),this.requestTimedOut=r(this.requestTimedOut,this),this.requestFailed=r(this.requestFailed,this),this.requestLoaded=r(this.requestLoaded,this),this.requestProgressed=r(this.requestProgressed,this),this.url=c.Location.wrap(e).requestURL,this.referrer=c.Location.wrap(n).absoluteURL,this.createXHR()}return t.NETWORK_FAILURE=0,t.TIMEOUT_FAILURE=-1,t.timeout=60,t.prototype.send=function(){var t;return this.xhr&&!this.sent?(this.notifyApplicationBeforeRequestStart(),this.setProgress(0),this.xhr.send(),this.sent=!0,"function"==typeof(t=this.delegate).requestStarted?t.requestStarted():void 0):void 0},t.prototype.cancel=function(){return this.xhr&&this.sent?this.xhr.abort():void 0},t.prototype.requestProgressed=function(t){return t.lengthComputable?this.setProgress(t.loaded/t.total):void 0},t.prototype.requestLoaded=function(){return this.endRequest((e=this,function(){var t;return 200<=(t=e.xhr.status)&&t<300?e.delegate.requestCompletedWithResponse(e.xhr.responseText,e.xhr.getResponseHeader("Turbolinks-Location")):(e.failed=!0,e.delegate.requestFailedWithStatusCode(e.xhr.status,e.xhr.responseText))}));var e},t.prototype.requestFailed=function(){return this.endRequest((t=this,function(){return t.failed=!0,t.delegate.requestFailedWithStatusCode(t.constructor.NETWORK_FAILURE)}));var t},t.prototype.requestTimedOut=function(){return this.endRequest((t=this,function(){return t.failed=!0,t.delegate.requestFailedWithStatusCode(t.constructor.TIMEOUT_FAILURE)}));var t},t.prototype.requestCanceled=function(){return this.endRequest()},t.prototype.notifyApplicationBeforeRequestStart=function(){return c.dispatch("turbolinks:request-start",{data:{url:this.url,xhr:this.xhr}})},t.prototype.notifyApplicationAfterRequestEnd=function(){return c.dispatch("turbolinks:request-end",{data:{url:this.url,xhr:this.xhr}})},t.prototype.createXHR=function(){return this.xhr=new XMLHttpRequest,this.xhr.open("GET",this.url,!0),this.xhr.timeout=1e3*this.constructor.timeout,this.xhr.setRequestHeader("Accept","text/html, application/xhtml+xml"),this.xhr.setRequestHeader("Turbolinks-Referrer",this.referrer),this.xhr.onprogress=this.requestProgressed,this.xhr.onload=this.requestLoaded,this.xhr.onerror=this.requestFailed,this.xhr.ontimeout=this.requestTimedOut,this.xhr.onabort=this.requestCanceled},t.prototype.endRequest=function(t){return this.xhr?(this.notifyApplicationAfterRequestEnd(),null!=t&&t.call(this),this.destroy()):void 0},t.prototype.setProgress=function(t){var e;return this.progress=t,"function"==typeof(e=this.delegate).requestProgressed?e.requestProgressed(this.progress):void 0},t.prototype.destroy=function(){var t;return this.setProgress(1),"function"==typeof(t=this.delegate).requestFinished&&t.requestFinished(),this.delegate=null,this.xhr=null},t}()}.call(this),function(){var n=function(t,e){return function(){return t.apply(e,arguments)}};c.ProgressBar=function(){function t(){this.trickle=n(this.trickle,this),this.stylesheetElement=this.createStylesheetElement(),this.progressElement=this.createProgressElement()}var e;return e=300,t.defaultCSS=".turbolinks-progress-bar {\n position: fixed;\n display: block;\n top: 0;\n left: 0;\n height: 3px;\n background: #0076ff;\n z-index: 9999;\n transition: width "+e+"ms ease-out, opacity "+e/2+"ms "+e/2+"ms ease-in;\n transform: translate3d(0, 0, 0);\n}",t.prototype.show=function(){return this.visible?void 0:(this.visible=!0,this.installStylesheetElement(),this.installProgressElement(),this.startTrickling())},t.prototype.hide=function(){return this.visible&&!this.hiding?(this.hiding=!0,this.fadeProgressElement((t=this,function(){return t.uninstallProgressElement(),t.stopTrickling(),t.visible=!1,t.hiding=!1}))):void 0;var t},t.prototype.setValue=function(t){return this.value=t,this.refresh()},t.prototype.installStylesheetElement=function(){return document.head.insertBefore(this.stylesheetElement,document.head.firstChild)},t.prototype.installProgressElement=function(){return this.progressElement.style.width=0,this.progressElement.style.opacity=1,document.documentElement.insertBefore(this.progressElement,document.body),this.refresh()},t.prototype.fadeProgressElement=function(t){return this.progressElement.style.opacity=0,setTimeout(t,1.5*e)},t.prototype.uninstallProgressElement=function(){return this.progressElement.parentNode?document.documentElement.removeChild(this.progressElement):void 0},t.prototype.startTrickling=function(){return null!=this.trickleInterval?this.trickleInterval:this.trickleInterval=setInterval(this.trickle,e)},t.prototype.stopTrickling=function(){return clearInterval(this.trickleInterval),this.trickleInterval=null},t.prototype.trickle=function(){return this.setValue(this.value+Math.random()/100)},t.prototype.refresh=function(){return requestAnimationFrame((t=this,function(){return t.progressElement.style.width=10+90*t.value+"%"}));var t},t.prototype.createStylesheetElement=function(){var t;return(t=document.createElement("style")).type="text/css",t.textContent=this.constructor.defaultCSS,t},t.prototype.createProgressElement=function(){var t;return(t=document.createElement("div")).className="turbolinks-progress-bar",t},t}()}.call(this),function(){var i=function(t,e){return function(){return t.apply(e,arguments)}};c.BrowserAdapter=function(){function t(t){this.controller=t,this.showProgressBar=i(this.showProgressBar,this),this.progressBar=new c.ProgressBar}var n,r,e;return e=c.HttpRequest,n=e.NETWORK_FAILURE,r=e.TIMEOUT_FAILURE,t.prototype.visitProposedToLocationWithAction=function(t,e){return this.controller.startVisitToLocationWithAction(t,e)},t.prototype.visitStarted=function(t){return t.issueRequest(),t.changeHistory(),t.loadCachedSnapshot()},t.prototype.visitRequestStarted=function(t){return this.progressBar.setValue(0),t.hasCachedSnapshot()||"restore"!==t.action?this.showProgressBarAfterDelay():this.showProgressBar()},t.prototype.visitRequestProgressed=function(t){return this.progressBar.setValue(t.progress)},t.prototype.visitRequestCompleted=function(t){return t.loadResponse()},t.prototype.visitRequestFailedWithStatusCode=function(t,e){switch(e){case n:case r:return this.reload();default:return t.loadResponse()}},t.prototype.visitRequestFinished=function(){return this.hideProgressBar()},t.prototype.visitCompleted=function(t){return t.followRedirect()},t.prototype.pageInvalidated=function(){return this.reload()},t.prototype.showProgressBarAfterDelay=function(){return this.progressBarTimeout=setTimeout(this.showProgressBar,this.controller.progressBarDelay)},t.prototype.showProgressBar=function(){return this.progressBar.show()},t.prototype.hideProgressBar=function(){return this.progressBar.hide(),clearTimeout(this.progressBarTimeout)},t.prototype.reload=function(){return window.location.reload()},t}()}.call(this),function(){var e=function(t,e){return function(){return t.apply(e,arguments)}};c.History=function(){function t(t){this.delegate=t,this.onPageLoad=e(this.onPageLoad,this),this.onPopState=e(this.onPopState,this)}return t.prototype.start=function(){return this.started?void 0:(addEventListener("popstate",this.onPopState,!1),addEventListener("load",this.onPageLoad,!1),this.started=!0)},t.prototype.stop=function(){return this.started?(removeEventListener("popstate",this.onPopState,!1),removeEventListener("load",this.onPageLoad,!1),this.started=!1):void 0},t.prototype.push=function(t,e){return t=c.Location.wrap(t),this.update("push",t,e)},t.prototype.replace=function(t,e){return t=c.Location.wrap(t),this.update("replace",t,e)},t.prototype.onPopState=function(t){var e,n,r,i;return this.shouldHandlePopState()&&(i=null!=(n=t.state)?n.turbolinks:void 0)?(e=c.Location.wrap(window.location),r=i.restorationIdentifier,this.delegate.historyPoppedToLocationWithRestorationIdentifier(e,r)):void 0},t.prototype.onPageLoad=function(){return c.defer((t=this,function(){return t.pageLoaded=!0}));var t},t.prototype.shouldHandlePopState=function(){return this.pageIsLoaded()},t.prototype.pageIsLoaded=function(){return this.pageLoaded||"complete"===document.readyState},t.prototype.update=function(t,e,n){var r;return r={turbolinks:{restorationIdentifier:n}},history[t+"State"](r,null,e)},t}()}.call(this),function(){c.HeadDetails=function(){function t(t){var e,n,r,i,o;for(this.elements={},n=0,i=t.length;n<i;n++)(o=t[n]).nodeType===Node.ELEMENT_NODE&&(r=o.outerHTML,(null!=(e=this.elements)[r]?e[r]:e[r]={type:s(o),tracked:a(o),elements:[]}).elements.push(o))}var o,e,n,a,s;return t.fromHeadElement=function(t){var e;return new this(null!=(e=null!=t?t.childNodes:void 0)?e:[])},t.prototype.hasElementWithKey=function(t){return t in this.elements},t.prototype.getTrackedElementSignature=function(){var n;return function(){var t,e;for(n in e=[],t=this.elements)t[n].tracked&&e.push(n);return e}.call(this).join("")},t.prototype.getScriptElementsNotInDetails=function(t){return this.getElementsMatchingTypeNotInDetails("script",t)},t.prototype.getStylesheetElementsNotInDetails=function(t){return this.getElementsMatchingTypeNotInDetails("stylesheet",t)},t.prototype.getElementsMatchingTypeNotInDetails=function(t,e){var n,r,i,o,a,s;for(r in a=[],i=this.elements)s=(o=i[r]).type,n=o.elements,s!==t||e.hasElementWithKey(r)||a.push(n[0]);return a},t.prototype.getProvisionalElements=function(){var t,e,n,r,i,o,a;for(e in n=[],r=this.elements)a=(i=r[e]).type,o=i.tracked,t=i.elements,null!=a||o?1<t.length&&n.push.apply(n,t.slice(1)):n.push.apply(n,t);return n},t.prototype.getMetaValue=function(t){var e;return null!=(e=this.findMetaElementByName(t))?e.getAttribute("content"):void 0},t.prototype.findMetaElementByName=function(t){var e,n,r,i;for(r in e=void 0,i=this.elements)n=i[r].elements,o(n[0],t)&&(e=n[0]);return e},s=function(t){return e(t)?"script":n(t)?"stylesheet":void 0},a=function(t){return"reload"===t.getAttribute("data-turbolinks-track")},e=function(t){return"script"===t.tagName.toLowerCase()},n=function(t){var e;return"style"===(e=t.tagName.toLowerCase())||"link"===e&&"stylesheet"===t.getAttribute("rel")},o=function(t,e){return"meta"===t.tagName.toLowerCase()&&t.getAttribute("name")===e},t}()}.call(this),function(){c.Snapshot=function(){function t(t,e){this.headDetails=t,this.bodyElement=e}return t.wrap=function(t){return t instanceof this?t:"string"==typeof t?this.fromHTMLString(t):this.fromHTMLElement(t)},t.fromHTMLString=function(t){var e;return(e=document.createElement("html")).innerHTML=t,this.fromHTMLElement(e)},t.fromHTMLElement=function(t){var e,n,r;return n=t.querySelector("head"),e=null!=(r=t.querySelector("body"))?r:document.createElement("body"),new this(c.HeadDetails.fromHeadElement(n),e)},t.prototype.clone=function(){return new this.constructor(this.headDetails,this.bodyElement.cloneNode(!0))},t.prototype.getRootLocation=function(){var t,e;return e=null!=(t=this.getSetting("root"))?t:"/",new c.Location(e)},t.prototype.getCacheControlValue=function(){return this.getSetting("cache-control")},t.prototype.getElementForAnchor=function(t){try{return this.bodyElement.querySelector("[id='"+t+"'], a[name='"+t+"']")}catch(c){}},t.prototype.getPermanentElements=function(){return this.bodyElement.querySelectorAll("[id][data-turbolinks-permanent]")},t.prototype.getPermanentElementById=function(t){return this.bodyElement.querySelector("#"+t+"[data-turbolinks-permanent]")},t.prototype.getPermanentElementsPresentInSnapshot=function(t){var e,n,r,i,o;for(o=[],n=0,r=(i=this.getPermanentElements()).length;n<r;n++)e=i[n],t.getPermanentElementById(e.id)&&o.push(e);return o},t.prototype.findFirstAutofocusableElement=function(){return this.bodyElement.querySelector("[autofocus]")},t.prototype.hasAnchor=function(t){return null!=this.getElementForAnchor(t)},t.prototype.isPreviewable=function(){return"no-preview"!==this.getCacheControlValue()},t.prototype.isCacheable=function(){return"no-cache"!==this.getCacheControlValue()},t.prototype.isVisitable=function(){return"reload"!==this.getSetting("visit-control")},t.prototype.getSetting=function(t){return this.headDetails.getMetaValue("turbolinks-"+t)},t}()}.call(this),function(){var o=[].slice;c.Renderer=function(){function t(){}var n;return t.render=function(t,e){var n,r,i;return r=t,n=e,(i=function(t,e,n){n.prototype=t.prototype;var r=new n,i=t.apply(r,e);return Object(i)===i?i:r}(this,3<=arguments.length?o.call(arguments,2):[],function(){})).delegate=r,i.render(n),i},t.prototype.renderView=function(t){return this.delegate.viewWillRender(this.newBody),t(),this.delegate.viewRendered(this.newBody)},t.prototype.invalidateView=function(){return this.delegate.viewInvalidated()},t.prototype.createScriptElement=function(t){var e;return"false"===t.getAttribute("data-turbolinks-eval")?t:((e=document.createElement("script")).textContent=t.textContent,e.async=!1,n(e,t),e)},n=function(t,e){var n,r,i,o,a,s,l;for(s=[],n=0,r=(o=e.attributes).length;n<r;n++)i=(a=o[n]).name,l=a.value,s.push(t.setAttribute(i,l));return s},t}()}.call(this),function(){var s,l,n=function(t,e){function n(){this.constructor=t}for(var r in e)i.call(e,r)&&(t[r]=e[r]);return n.prototype=e.prototype,t.prototype=new n,t.__super__=e.prototype,t},i={}.hasOwnProperty;c.SnapshotRenderer=function(t){function e(t,e,n){this.currentSnapshot=t,this.newSnapshot=e,this.isPreview=n,this.currentHeadDetails=this.currentSnapshot.headDetails,this.newHeadDetails=this.newSnapshot.headDetails,this.currentBody=this.currentSnapshot.bodyElement,this.newBody=this.newSnapshot.bodyElement}return n(e,t),e.prototype.render=function(t){return this.shouldRender()?(this.mergeHead(),this.renderView((e=this,function(){return e.replaceBody(),e.isPreview||e.focusFirstAutofocusableElement(),t()}))):this.invalidateView();var e},e.prototype.mergeHead=function(){return this.copyNewHeadStylesheetElements(),this.copyNewHeadScriptElements(),this.removeCurrentHeadProvisionalElements(),this.copyNewHeadProvisionalElements()},e.prototype.replaceBody=function(){var t;return t=this.relocateCurrentBodyPermanentElements(),this.activateNewBodyScriptElements(),this.assignNewBody(),this.replacePlaceholderElementsWithClonedPermanentElements(t)},e.prototype.shouldRender=function(){return this.newSnapshot.isVisitable()&&this.trackedElementsAreIdentical()},e.prototype.trackedElementsAreIdentical=function(){return this.currentHeadDetails.getTrackedElementSignature()===this.newHeadDetails.getTrackedElementSignature()},e.prototype.copyNewHeadStylesheetElements=function(){var t,e,n,r,i;for(i=[],e=0,n=(r=this.getNewHeadStylesheetElements()).length;e<n;e++)t=r[e],i.push(document.head.appendChild(t));return i},e.prototype.copyNewHeadScriptElements=function(){var t,e,n,r,i;for(i=[],e=0,n=(r=this.getNewHeadScriptElements()).length;e<n;e++)t=r[e],i.push(document.head.appendChild(this.createScriptElement(t)));return i},e.prototype.removeCurrentHeadProvisionalElements=function(){var t,e,n,r,i;for(i=[],e=0,n=(r=this.getCurrentHeadProvisionalElements()).length;e<n;e++)t=r[e],i.push(document.head.removeChild(t));return i},e.prototype.copyNewHeadProvisionalElements=function(){var t,e,n,r,i;for(i=[],e=0,n=(r=this.getNewHeadProvisionalElements()).length;e<n;e++)t=r[e],i.push(document.head.appendChild(t));return i},e.prototype.relocateCurrentBodyPermanentElements=function(){var t,e,n,r,i,o,a;for(a=[],t=0,e=(o=this.getCurrentBodyPermanentElements()).length;t<e;t++)r=o[t],i=s(r),n=this.newSnapshot.getPermanentElementById(r.id),l(r,i.element),l(n,r),a.push(i);return a},e.prototype.replacePlaceholderElementsWithClonedPermanentElements=function(t){var e,n,r,i,o,a;for(a=[],r=0,i=t.length;r<i;r++)n=(o=t[r]).element,e=o.permanentElement.cloneNode(!0),a.push(l(n,e));return a},e.prototype.activateNewBodyScriptElements=function(){var t,e,n,r,i,o;for(o=[],e=0,r=(i=this.getNewBodyScriptElements()).length;e<r;e++)n=i[e],t=this.createScriptElement(n),o.push(l(n,t));return o},e.prototype.assignNewBody=function(){return document.body=this.newBody},e.prototype.focusFirstAutofocusableElement=function(){var t;return null!=(t=this.newSnapshot.findFirstAutofocusableElement())?t.focus():void 0},e.prototype.getNewHeadStylesheetElements=function(){return this.newHeadDetails.getStylesheetElementsNotInDetails(this.currentHeadDetails)},e.prototype.getNewHeadScriptElements=function(){return this.newHeadDetails.getScriptElementsNotInDetails(this.currentHeadDetails)},e.prototype.getCurrentHeadProvisionalElements=function(){return this.currentHeadDetails.getProvisionalElements()},e.prototype.getNewHeadProvisionalElements=function(){return this.newHeadDetails.getProvisionalElements()},e.prototype.getCurrentBodyPermanentElements=function(){return this.currentSnapshot.getPermanentElementsPresentInSnapshot(this.newSnapshot)},e.prototype.getNewBodyScriptElements=function(){return this.newBody.querySelectorAll("script")},e}(c.Renderer),s=function(t){var e;return(e=document.createElement("meta")).setAttribute("name","turbolinks-permanent-placeholder"),e.setAttribute("content",t.id),{element:e,permanentElement:t}},l=function(t,e){var n;return(n=t.parentNode)?n.replaceChild(e,t):void 0}}.call(this),function(){var n=function(t,e){function n(){this.constructor=t}for(var r in e)i.call(e,r)&&(t[r]=e[r]);return n.prototype=e.prototype,t.prototype=new n,t.__super__=e.prototype,t},i={}.hasOwnProperty;c.ErrorRenderer=function(t){function e(t){var e;(e=document.createElement("html")).innerHTML=t,this.newHead=e.querySelector("head"),this.newBody=e.querySelector("body")}return n(e,t),e.prototype.render=function(t){return this.renderView((e=this,function(){return e.replaceHeadAndBody(),e.activateBodyScriptElements(),t()}));var e},e.prototype.replaceHeadAndBody=function(){var t,e;return e=document.head,t=document.body,e.parentNode.replaceChild(this.newHead,e),t.parentNode.replaceChild(this.newBody,t)},e.prototype.activateBodyScriptElements=function(){var t,e,n,r,i,o;for(o=[],e=0,n=(r=this.getScriptElements()).length;e<n;e++)i=r[e],t=this.createScriptElement(i),o.push(i.parentNode.replaceChild(t,i));return o},e.prototype.getScriptElements=function(){return document.documentElement.querySelectorAll("script")},e}(c.Renderer)}.call(this),function(){c.View=function(){function t(t){this.delegate=t,this.htmlElement=document.documentElement}return t.prototype.getRootLocation=function(){return this.getSnapshot().getRootLocation()},t.prototype.getElementForAnchor=function(t){return this.getSnapshot().getElementForAnchor(t)},t.prototype.getSnapshot=function(){return c.Snapshot.fromHTMLElement(this.htmlElement)},t.prototype.render=function(t,e){var n,r,i;return i=t.snapshot,n=t.error,r=t.isPreview,this.markAsPreview(r),null!=i?this.renderSnapshot(i,r,e):this.renderError(n,e)},t.prototype.markAsPreview=function(t){return t?this.htmlElement.setAttribute("data-turbolinks-preview",""):this.htmlElement.removeAttribute("data-turbolinks-preview")},t.prototype.renderSnapshot=function(t,e,n){return c.SnapshotRenderer.render(this.delegate,n,this.getSnapshot(),c.Snapshot.wrap(t),e)},t.prototype.renderError=function(t,e){return c.ErrorRenderer.render(this.delegate,e,t)},t}()}.call(this),function(){var e=function(t,e){return function(){return t.apply(e,arguments)}};c.ScrollManager=function(){function t(t){this.delegate=t,this.onScroll=e(this.onScroll,this),this.onScroll=c.throttle(this.onScroll)}return t.prototype.start=function(){return this.started?void 0:(addEventListener("scroll",this.onScroll,!1),this.onScroll(),this.started=!0)},t.prototype.stop=function(){return this.started?(removeEventListener("scroll",this.onScroll,!1),this.started=!1):void 0},t.prototype.scrollToElement=function(t){return t.scrollIntoView()},t.prototype.scrollToPosition=function(t){var e,n;return e=t.x,n=t.y,window.scrollTo(e,n)},t.prototype.onScroll=function(){return this.updatePosition({x:window.pageXOffset,y:window.pageYOffset})},t.prototype.updatePosition=function(t){var e;return this.position=t,null!=(e=this.delegate)?e.scrollPositionChanged(this.position):void 0},t}()}.call(this),function(){c.SnapshotCache=function(){function t(t){this.size=t,this.keys=[],this.snapshots={}}var r;return t.prototype.has=function(t){return r(t)in this.snapshots},t.prototype.get=function(t){var e;if(this.has(t))return e=this.read(t),this.touch(t),e},t.prototype.put=function(t,e){return this.write(t,e),this.touch(t),e},t.prototype.read=function(t){var e;return e=r(t),this.snapshots[e]},t.prototype.write=function(t,e){var n;return n=r(t),this.snapshots[n]=e},t.prototype.touch=function(t){var e,n;return n=r(t),-1<(e=this.keys.indexOf(n))&&this.keys.splice(e,1),this.keys.unshift(n),this.trim()},t.prototype.trim=function(){var t,e,n,r,i;for(i=[],t=0,n=(r=this.keys.splice(this.size)).length;t<n;t++)e=r[t],i.push(delete this.snapshots[e]);return i},r=function(t){return c.Location.wrap(t).toCacheKey()},t}()}.call(this),function(){var r=function(t,e){return function(){return t.apply(e,arguments)}};c.Visit=function(){function t(t,e,n){this.controller=t,this.action=n,this.performScroll=r(this.performScroll,this),this.identifier=c.uuid(),this.location=c.Location.wrap(e),this.adapter=this.controller.adapter,this.state="initialized",this.timingMetrics={}}var n;return t.prototype.start=function(){return"initialized"===this.state?(this.recordTimingMetric("visitStart"),this.state="started",this.adapter.visitStarted(this)):void 0},t.prototype.cancel=function(){var t;return"started"===this.state?(null!=(t=this.request)&&t.cancel(),this.cancelRender(),this.state="canceled"):void 0},t.prototype.complete=function(){var t;return"started"===this.state?(this.recordTimingMetric("visitEnd"),this.state="completed","function"==typeof(t=this.adapter).visitCompleted&&t.visitCompleted(this),this.controller.visitCompleted(this)):void 0},t.prototype.fail=function(){var t;return"started"===this.state?(this.state="failed","function"==typeof(t=this.adapter).visitFailed?t.visitFailed(this):void 0):void 0},t.prototype.changeHistory=function(){var t,e;return this.historyChanged?void 0:(t=this.location.isEqualTo(this.referrer)?"replace":this.action,e=n(t),this.controller[e](this.location,this.restorationIdentifier),this.historyChanged=!0)},t.prototype.issueRequest=function(){return this.shouldIssueRequest()&&null==this.request?(this.progress=0,this.request=new c.HttpRequest(this,this.location,this.referrer),this.request.send()):void 0},t.prototype.getCachedSnapshot=function(){var t;return!(t=this.controller.getCachedSnapshotForLocation(this.location))||null!=this.location.anchor&&!t.hasAnchor(this.location.anchor)||"restore"!==this.action&&!t.isPreviewable()?void 0:t},t.prototype.hasCachedSnapshot=function(){return null!=this.getCachedSnapshot()},t.prototype.loadCachedSnapshot=function(){var e,n;return(n=this.getCachedSnapshot())?(e=this.shouldIssueRequest(),this.render(function(){var t;return this.cacheSnapshot(),this.controller.render({snapshot:n,isPreview:e},this.performScroll),"function"==typeof(t=this.adapter).visitRendered&&t.visitRendered(this),e?void 0:this.complete()})):void 0},t.prototype.loadResponse=function(){return null!=this.response?this.render(function(){var t,e;return this.cacheSnapshot(),this.request.failed?(this.controller.render({error:this.response},this.performScroll),"function"==typeof(t=this.adapter).visitRendered&&t.visitRendered(this),this.fail()):(this.controller.render({snapshot:this.response},this.performScroll),"function"==typeof(e=this.adapter).visitRendered&&e.visitRendered(this),this.complete())}):void 0},t.prototype.followRedirect=function(){return this.redirectedToLocation&&!this.followedRedirect?(this.location=this.redirectedToLocation,this.controller.replaceHistoryWithLocationAndRestorationIdentifier(this.redirectedToLocation,this.restorationIdentifier),this.followedRedirect=!0):void 0},t.prototype.requestStarted=function(){var t;return this.recordTimingMetric("requestStart"),"function"==typeof(t=this.adapter).visitRequestStarted?t.visitRequestStarted(this):void 0},t.prototype.requestProgressed=function(t){var e;return this.progress=t,"function"==typeof(e=this.adapter).visitRequestProgressed?e.visitRequestProgressed(this):void 0},t.prototype.requestCompletedWithResponse=function(t,e){return this.response=t,null!=e&&(this.redirectedToLocation=c.Location.wrap(e)),this.adapter.visitRequestCompleted(this)},t.prototype.requestFailedWithStatusCode=function(t,e){return this.response=e,this.adapter.visitRequestFailedWithStatusCode(this,t)},t.prototype.requestFinished=function(){var t;return this.recordTimingMetric("requestEnd"),"function"==typeof(t=this.adapter).visitRequestFinished?t.visitRequestFinished(this):void 0},t.prototype.performScroll=function(){return this.scrolled?void 0:("restore"===this.action?this.scrollToRestoredPosition()||this.scrollToTop():this.scrollToAnchor()||this.scrollToTop(),this.scrolled=!0)},t.prototype.scrollToRestoredPosition=function(){var t,e;return null!=(t=null!=(e=this.restorationData)?e.scrollPosition:void 0)?(this.controller.scrollToPosition(t),!0):void 0},t.prototype.scrollToAnchor=function(){return null!=this.location.anchor?(this.controller.scrollToAnchor(this.location.anchor),!0):void 0},t.prototype.scrollToTop=function(){return this.controller.scrollToPosition({x:0,y:0})},t.prototype.recordTimingMetric=function(t){var e;return null!=(e=this.timingMetrics)[t]?e[t]:e[t]=(new Date).getTime()},t.prototype.getTimingMetrics=function(){return c.copyObject(this.timingMetrics)},n=function(t){switch(t){case"replace":return"replaceHistoryWithLocationAndRestorationIdentifier";case"advance":case"restore":return"pushHistoryWithLocationAndRestorationIdentifier"}},t.prototype.shouldIssueRequest=function(){return"restore"!==this.action||!this.hasCachedSnapshot()},t.prototype.cacheSnapshot=function(){return this.snapshotCached?void 0:(this.controller.cacheSnapshot(),this.snapshotCached=!0)},t.prototype.render=function(t){return this.cancelRender(),this.frame=requestAnimationFrame((e=this,function(){return e.frame=null,t.call(e)}));var e},t.prototype.cancelRender=function(){return this.frame?cancelAnimationFrame(this.frame):void 0},t}()}.call(this),function(){var e=function(t,e){return function(){return t.apply(e,arguments)}};c.Controller=function(){function t(){this.clickBubbled=e(this.clickBubbled,this),this.clickCaptured=e(this.clickCaptured,this),this.pageLoaded=e(this.pageLoaded,this),this.history=new c.History(this),this.view=new c.View(this),this.scrollManager=new c.ScrollManager(this),this.restorationData={},this.clearCache(),this.setProgressBarDelay(500)}return t.prototype.start=function(){return c.supported&&!this.started?(addEventListener("click",this.clickCaptured,!0),addEventListener("DOMContentLoaded",this.pageLoaded,!1),this.scrollManager.start(),this.startHistory(),this.started=!0,this.enabled=!0):void 0},t.prototype.disable=function(){return this.enabled=!1},t.prototype.stop=function(){return this.started?(removeEventListener("click",this.clickCaptured,!0),removeEventListener("DOMContentLoaded",this.pageLoaded,!1),this.scrollManager.stop(),this.stopHistory(),this.started=!1):void 0},t.prototype.clearCache=function(){return this.cache=new c.SnapshotCache(10)},t.prototype.visit=function(t,e){var n,r;return null==e&&(e={}),t=c.Location.wrap(t),this.applicationAllowsVisitingLocation(t)?this.locationIsVisitable(t)?(n=null!=(r=e.action)?r:"advance",this.adapter.visitProposedToLocationWithAction(t,n)):window.location=t:void 0},t.prototype.startVisitToLocationWithAction=function(t,e,n){var r;return c.supported?(r=this.getRestorationDataForIdentifier(n),this.startVisit(t,e,{restorationData:r})):window.location=t},t.prototype.setProgressBarDelay=function(t){return this.progressBarDelay=t},t.prototype.startHistory=function(){return this.location=c.Location.wrap(window.location),this.restorationIdentifier=c.uuid(),this.history.start(),this.history.replace(this.location,this.restorationIdentifier)},t.prototype.stopHistory=function(){return this.history.stop()},t.prototype.pushHistoryWithLocationAndRestorationIdentifier=function(t,e){return this.restorationIdentifier=e,this.location=c.Location.wrap(t),this.history.push(this.location,this.restorationIdentifier)},t.prototype.replaceHistoryWithLocationAndRestorationIdentifier=function(t,e){return this.restorationIdentifier=e,this.location=c.Location.wrap(t),this.history.replace(this.location,this.restorationIdentifier)},t.prototype.historyPoppedToLocationWithRestorationIdentifier=function(t,e){var n;return this.restorationIdentifier=e,this.enabled?(n=this.getRestorationDataForIdentifier(this.restorationIdentifier),this.startVisit(t,"restore",{restorationIdentifier:this.restorationIdentifier,restorationData:n,historyChanged:!0}),this.location=c.Location.wrap(t)):this.adapter.pageInvalidated()},t.prototype.getCachedSnapshotForLocation=function(t){var e;return null!=(e=this.cache.get(t))?e.clone():void 0},t.prototype.shouldCacheSnapshot=function(){return this.view.getSnapshot().isCacheable()},t.prototype.cacheSnapshot=function(){var t,e,n;return this.shouldCacheSnapshot()?(this.notifyApplicationBeforeCachingSnapshot(),e=this.view.getSnapshot(),t=this.lastRenderedLocation,c.defer((n=this,function(){return n.cache.put(t,e.clone())}))):void 0},t.prototype.scrollToAnchor=function(t){var e;return(e=this.view.getElementForAnchor(t))?this.scrollToElement(e):this.scrollToPosition({x:0,y:0})},t.prototype.scrollToElement=function(t){return this.scrollManager.scrollToElement(t)},t.prototype.scrollToPosition=function(t){return this.scrollManager.scrollToPosition(t)},t.prototype.scrollPositionChanged=function(t){return this.getCurrentRestorationData().scrollPosition=t},t.prototype.render=function(t,e){return this.view.render(t,e)},t.prototype.viewInvalidated=function(){return this.adapter.pageInvalidated()},t.prototype.viewWillRender=function(t){return this.notifyApplicationBeforeRender(t)},t.prototype.viewRendered=function(){return this.lastRenderedLocation=this.currentVisit.location,this.notifyApplicationAfterRender()},t.prototype.pageLoaded=function(){return this.lastRenderedLocation=this.location,this.notifyApplicationAfterPageLoad()},t.prototype.clickCaptured=function(){return removeEventListener("click",this.clickBubbled,!1),addEventListener("click",this.clickBubbled,!1)},t.prototype.clickBubbled=function(t){var e,n,r;return this.enabled&&this.clickEventIsSignificant(t)&&(n=this.getVisitableLinkForNode(t.target))&&(r=this.getVisitableLocationForLink(n))&&this.applicationAllowsFollowingLinkToLocation(n,r)?(t.preventDefault(),e=this.getActionForLink(n),this.visit(r,{action:e})):void 0},t.prototype.applicationAllowsFollowingLinkToLocation=function(t,e){return!this.notifyApplicationAfterClickingLinkToLocation(t,e).defaultPrevented},t.prototype.applicationAllowsVisitingLocation=function(t){return!this.notifyApplicationBeforeVisitingLocation(t).defaultPrevented},t.prototype.notifyApplicationAfterClickingLinkToLocation=function(t,e){return c.dispatch("turbolinks:click",{target:t,data:{url:e.absoluteURL},cancelable:!0})},t.prototype.notifyApplicationBeforeVisitingLocation=function(t){return c.dispatch("turbolinks:before-visit",{data:{url:t.absoluteURL},cancelable:!0})},t.prototype.notifyApplicationAfterVisitingLocation=function(t){return c.dispatch("turbolinks:visit",{data:{url:t.absoluteURL}})},t.prototype.notifyApplicationBeforeCachingSnapshot=function(){return c.dispatch("turbolinks:before-cache")},t.prototype.notifyApplicationBeforeRender=function(t){return c.dispatch("turbolinks:before-render",{data:{newBody:t}})},t.prototype.notifyApplicationAfterRender=function(){return c.dispatch("turbolinks:render")},t.prototype.notifyApplicationAfterPageLoad=function(t){return null==t&&(t={}),c.dispatch("turbolinks:load",{data:{url:this.location.absoluteURL,timing:t}})},t.prototype.startVisit=function(t,e,n){var r;return null!=(r=this.currentVisit)&&r.cancel(),this.currentVisit=this.createVisit(t,e,n),this.currentVisit.start(),this.notifyApplicationAfterVisitingLocation(t)},t.prototype.createVisit=function(t,e,n){var r,i,o,a,s;return a=(i=null!=n?n:{}).restorationIdentifier,o=i.restorationData,r=i.historyChanged,(s=new c.Visit(this,t,e)
).restorationIdentifier=null!=a?a:c.uuid(),s.restorationData=c.copyObject(o),s.historyChanged=r,s.referrer=this.location,s},t.prototype.visitCompleted=function(t){return this.notifyApplicationAfterPageLoad(t.getTimingMetrics())},t.prototype.clickEventIsSignificant=function(t){return!(t.defaultPrevented||t.target.isContentEditable||1<t.which||t.altKey||t.ctrlKey||t.metaKey||t.shiftKey)},t.prototype.getVisitableLinkForNode=function(t){return this.nodeIsVisitable(t)?c.closest(t,"a[href]:not([target]):not([download])"):void 0},t.prototype.getVisitableLocationForLink=function(t){var e;return e=new c.Location(t.getAttribute("href")),this.locationIsVisitable(e)?e:void 0},t.prototype.getActionForLink=function(t){var e;return null!=(e=t.getAttribute("data-turbolinks-action"))?e:"advance"},t.prototype.nodeIsVisitable=function(t){var e;return!(e=c.closest(t,"[data-turbolinks]"))||"false"!==e.getAttribute("data-turbolinks")},t.prototype.locationIsVisitable=function(t){return t.isPrefixedBy(this.view.getRootLocation())&&t.isHTML()},t.prototype.getCurrentRestorationData=function(){return this.getRestorationDataForIdentifier(this.restorationIdentifier)},t.prototype.getRestorationDataForIdentifier=function(t){var e;return null!=(e=this.restorationData)[t]?e[t]:e[t]={}},t}()}.call(this),function(){!function(){var t,e;if((t=e=document.currentScript)&&!e.hasAttribute("data-turbolinks-suppress-warning"))for(;t=t.parentNode;)if(t===document.body)return console.warn("You are loading Turbolinks from a <script> element inside the <body> element. This is probably not what you meant to do!\n\nLoad your application\u2019s JavaScript bundle inside the <head> element instead. <script> elements in <body> are evaluated with each page change.\n\nFor more information, see: https://github.com/turbolinks/turbolinks#working-with-script-elements\n\n\u2014\u2014\nSuppress this warning by adding a `data-turbolinks-suppress-warning` attribute to: %s",e.outerHTML)}()}.call(this),function(){var t,e,n;c.start=function(){return e()?(null==c.controller&&(c.controller=t()),c.controller.start()):void 0},e=function(){return null==window.Turbolinks&&(window.Turbolinks=c),n()},t=function(){var t;return(t=new c.Controller).adapter=new c.BrowserAdapter(t),t},(n=function(){return window.Turbolinks===c})()&&c.start()}.call(this)}).call(this),"object"==typeof module&&module.exports?module.exports=c:"function"==typeof define&&define.amd&&define(c)}.call(this),function(t,e){"use strict";"object"==typeof module&&"object"==typeof module.exports?module.exports=t.document?e(t,!0):function(t){if(!t.document)throw new Error("jQuery requires a window with a document");return e(t)}:e(t)}("undefined"!=typeof window?window:this,function(T,t){"use strict";function g(t,e,n){var r,i,o=(n=n||lt).createElement("script");if(o.text=t,e)for(r in wt)(i=e[r]||e.getAttribute&&e.getAttribute(r))&&o.setAttribute(r,i);n.head.appendChild(o).parentNode.removeChild(o)}function m(t){return null==t?t+"":"object"==typeof t||"function"==typeof t?pt[gt.call(t)]||"object":typeof t}function s(t){var e=!!t&&"length"in t&&t.length,n=m(t);return!_t(t)&&!xt(t)&&("array"===n||0===e||"number"==typeof e&&0<e&&e-1 in t)}function u(t,e){return t.nodeName&&t.nodeName.toLowerCase()===e.toLowerCase()}function e(t,n,r){return _t(n)?Tt.grep(t,function(t,e){return!!n.call(t,e,t)!==r}):n.nodeType?Tt.grep(t,function(t){return t===n!==r}):"string"!=typeof n?Tt.grep(t,function(t){return-1<ft.call(n,t)!==r}):Tt.filter(n,t,r)}function n(t,e){for(;(t=t[e])&&1!==t.nodeType;);return t}function c(t){var n={};return Tt.each(t.match(Nt)||[],function(t,e){n[e]=!0}),n}function d(t){return t}function h(t){throw t}function l(t,e,n,r){var i;try{t&&_t(i=t.promise)?i.call(t).done(e).fail(n):t&&_t(i=t.then)?i.call(t,e,n):e.apply(undefined,[t].slice(r))}catch(t){n.apply(undefined,[t])}}function r(){lt.removeEventListener("DOMContentLoaded",r),T.removeEventListener("load",r),Tt.ready()}function i(t,e){return e.toUpperCase()}function f(t){return t.replace(jt,"ms-").replace(Wt,i)}function o(){this.expando=Tt.expando+o.uid++}function a(t){return"true"===t||"false"!==t&&("null"===t?null:t===+t+""?+t:qt.test(t)?JSON.parse(t):t)}function p(t,e,n){var r;if(n===undefined&&1===t.nodeType)if(r="data-"+e.replace(Ut,"-$&").toLowerCase(),"string"==typeof(n=t.getAttribute(r))){try{n=a(n)}catch(i){}Vt.set(t,e,n)}else n=undefined;return n}function y(t,e,n,r){var i,o,a=20,s=r?function(){return r.cur()}:function(){return Tt.css(t,e,"")},l=s(),u=n&&n[3]||(Tt.cssNumber[e]?"":"px"),c=t.nodeType&&(Tt.cssNumber[e]||"px"!==u&&+l)&&Gt.exec(Tt.css(t,e));if(c&&c[3]!==u){for(l/=2,u=u||c[3],c=+l||1;a--;)Tt.style(t,e,c+u),(1-o)*(1-(o=s()/l||.5))<=0&&(a=0),c/=o;c*=2,Tt.style(t,e,c+u),n=n||[]}return n&&(c=+c||+l||0,i=n[1]?c+(n[1]+1)*n[2]:+n[2],r&&(r.unit=u,r.start=c,r.end=i)),i}function v(t){var e,n=t.ownerDocument,r=t.nodeName,i=te[r];return i||(e=n.body.appendChild(n.createElement(r)),i=Tt.css(e,"display"),e.parentNode.removeChild(e),"none"===i&&(i="block"),te[r]=i)}function b(t,e){for(var n,r,i=[],o=0,a=t.length;o<a;o++)(r=t[o]).style&&(n=r.style.display,e?("none"===n&&(i[o]=Bt.get(r,"display")||null,i[o]||(r.style.display="")),""===r.style.display&&Zt(r)&&(i[o]=v(r))):"none"!==n&&(i[o]="none",Bt.set(r,"display",n)));for(o=0;o<a;o++)null!=i[o]&&(t[o].style.display=i[o]);return t}function _(t,e){var n;return n="undefined"!=typeof t.getElementsByTagName?t.getElementsByTagName(e||"*"):"undefined"!=typeof t.querySelectorAll?t.querySelectorAll(e||"*"):[],e===undefined||e&&u(t,e)?Tt.merge([t],n):n}function x(t,e){for(var n=0,r=t.length;n<r;n++)Bt.set(t[n],"globalEval",!e||Bt.get(e[n],"globalEval"))}function w(t,e,n,r,i){for(var o,a,s,l,u,c,d=e.createDocumentFragment(),h=[],f=0,p=t.length;f<p;f++)if((o=t[f])||0===o)if("object"===m(o))Tt.merge(h,o.nodeType?[o]:o);else if(se.test(o)){for(a=a||d.appendChild(e.createElement("div")),s=(ne.exec(o)||["",""])[1].toLowerCase(),l=ie[s]||ie._default,a.innerHTML=l[1]+Tt.htmlPrefilter(o)+l[2],c=l[0];c--;)a=a.lastChild;Tt.merge(h,a.childNodes),(a=d.firstChild).textContent=""}else h.push(e.createTextNode(o));for(d.textContent="",f=0;o=h[f++];)if(r&&-1<Tt.inArray(o,r))i&&i.push(o);else if(u=Qt(o),a=_(d.appendChild(o),"script"),u&&x(a),n)for(c=0;o=a[c++];)re.test(o.type||"")&&n.push(o);return d}function S(){return!0}function k(){return!1}function C(t,e){return t===E()==("focus"===e)}function E(){try{return lt.activeElement}catch(t){}}function D(t,e,n,r,i,o){var a,s;if("object"==typeof e){for(s in"string"!=typeof n&&(r=r||n,n=undefined),e)D(t,s,n,r,e[s],o);return t}if(null==r&&null==i?(i=n,r=n=undefined):null==i&&("string"==typeof n?(i=r,r=undefined):(i=r,r=n,n=undefined)),!1===i)i=k;else if(!i)return t;return 1===o&&(a=i,(i=function(t){return Tt().off(t),a.apply(this,arguments)}).guid=a.guid||(a.guid=Tt.guid++)),t.each(function(){Tt.event.add(this,e,i,r,n)})}function A(t,i,o){o?(Bt.set(t,i,!1),Tt.event.add(t,i,{namespace:!1,handler:function(t){var e,n,r=Bt.get(this,i);if(1&t.isTrigger&&this[i]){if(r.length)(Tt.event.special[i]||{}).delegateType&&t.stopPropagation();else if(r=ct.call(arguments),Bt.set(this,i,r),e=o(this,i),this[i](),r!==(n=Bt.get(this,i))||e?Bt.set(this,i,!1):n={},r!==n)return t.stopImmediatePropagation(),t.preventDefault(),n.value}else r.length&&(Bt.set(this,i,{value:Tt.event.trigger(Tt.extend(r[0],Tt.Event.prototype),r.slice(1),this)}),t.stopImmediatePropagation())}})):Bt.get(t,i)===undefined&&Tt.event.add(t,i,S)}function M(t,e){return u(t,"table")&&u(11!==e.nodeType?e:e.firstChild,"tr")&&Tt(t).children("tbody")[0]||t}function O(t){return t.type=(null!==t.getAttribute("type"))+"/"+t.type,t}function I(t){return"true/"===(t.type||"").slice(0,5)?t.type=t.type.slice(5):t.removeAttribute("type"),t}function P(t,e){var n,r,i,o,a,s,l,u;if(1===e.nodeType){if(Bt.hasData(t)&&(o=Bt.access(t),a=Bt.set(e,o),u=o.events))for(i in delete a.handle,a.events={},u)for(n=0,r=u[i].length;n<r;n++)Tt.event.add(e,i,u[i][n]);Vt.hasData(t)&&(s=Vt.access(t),l=Tt.extend({},s),Vt.set(e,l))}}function L(t,e){var n=e.nodeName.toLowerCase();"input"===n&&ee.test(t.type)?e.checked=t.checked:"input"!==n&&"textarea"!==n||(e.defaultValue=t.defaultValue)}function N(n,r,i,o){r=dt.apply([],r);var t,e,a,s,l,u,c=0,d=n.length,h=d-1,f=r[0],p=_t(f);if(p||1<d&&"string"==typeof f&&!bt.checkClone&&fe.test(f))return n.each(function(t){var e=n.eq(t);p&&(r[0]=f.call(this,t,e.html())),N(e,r,i,o)});if(d&&(e=(t=w(r,n[0].ownerDocument,!1,n,o)).firstChild,1===t.childNodes.length&&(t=e),e||o)){for(s=(a=Tt.map(_(t,"script"),O)).length;c<d;c++)l=t,c!==h&&(l=Tt.clone(l,!0,!0),s&&Tt.merge(a,_(l,"script"))),i.call(n[c],l,c);if(s)for(u=a[a.length-1].ownerDocument,Tt.map(a,I),c=0;c<s;c++)l=a[c],re.test(l.type||"")&&!Bt.access(l,"globalEval")&&Tt.contains(u,l)&&(l.src&&"module"!==(l.type||"").toLowerCase()?Tt._evalUrl&&!l.noModule&&Tt._evalUrl(l.src,{nonce:l.nonce||l.getAttribute("nonce")}):g(l.textContent.replace(pe,""),l,u))}return n}function R(t,e,n){for(var r,i=e?Tt.filter(e,t):t,o=0;null!=(r=i[o]);o++)n||1!==r.nodeType||Tt.cleanData(_(r)),r.parentNode&&(n&&Qt(r)&&x(_(r,"script")),r.parentNode.removeChild(r));return t}function F(t,e,n){var r,i,o,a,s=t.style;return(n=n||me(t))&&(""!==(a=n.getPropertyValue(e)||n[e])||Qt(t)||(a=Tt.style(t,e)),!bt.pixelBoxStyles()&&ge.test(a)&&ye.test(e)&&(r=s.width,i=s.minWidth,o=s.maxWidth,s.minWidth=s.maxWidth=s.width=a,a=n.width,s.width=r,s.minWidth=i,s.maxWidth=o)),a!==undefined?a+"":a}function H(t,e){return{get:function(){if(!t())return(this.get=e).apply(this,arguments);delete this.get}}}function j(t){for(var e=t[0].toUpperCase()+t.slice(1),n=ve.length;n--;)if((t=ve[n]+e)in be)return t}function W(t){var e=Tt.cssProps[t]||_e[t];return e||(t in be?t:_e[t]=j(t)||t)}function z(t,e,n){var r=Gt.exec(e);return r?Math.max(0,r[2]-(n||0))+(r[3]||"px"):e}function B(t,e,n,r,i,o){var a="width"===e?1:0,s=0,l=0;if(n===(r?"border":"content"))return 0;for(;a<4;a+=2)"margin"===n&&(l+=Tt.css(t,n+Kt[a],!0,i)),r?("content"===n&&(l-=Tt.css(t,"padding"+Kt[a],!0,i)),"margin"!==n&&(l-=Tt.css(t,"border"+Kt[a]+"Width",!0,i))):(l+=Tt.css(t,"padding"+Kt[a],!0,i),"padding"!==n?l+=Tt.css(t,"border"+Kt[a]+"Width",!0,i):s+=Tt.css(t,"border"+Kt[a]+"Width",!0,i));return!r&&0<=o&&(l+=Math.max(0,Math.ceil(t["offset"+e[0].toUpperCase()+e.slice(1)]-o-l-s-.5))||0),l}function V(t,e,n){var r=me(t),i=(!bt.boxSizingReliable()||n)&&"border-box"===Tt.css(t,"boxSizing",!1,r),o=i,a=F(t,e,r),s="offset"+e[0].toUpperCase()+e.slice(1);if(ge.test(a)){if(!n)return a;a="auto"}return(!bt.boxSizingReliable()&&i||"auto"===a||!parseFloat(a)&&"inline"===Tt.css(t,"display",!1,r))&&t.getClientRects().length&&(i="border-box"===Tt.css(t,"boxSizing",!1,r),(o=s in t)&&(a=t[s])),(a=parseFloat(a)||0)+B(t,e,n||(i?"border":"content"),o,r,a)+"px"}function q(t,e,n,r,i){return new q.prototype.init(t,e,n,r,i)}function U(){Ce&&(!1===lt.hidden&&T.requestAnimationFrame?T.requestAnimationFrame(U):T.setTimeout(U,Tt.fx.interval),Tt.fx.tick())}function Y(){return T.setTimeout(function(){ke=undefined}),ke=Date.now()}function G(t,e){var n,r=0,i={height:t};for(e=e?1:0;r<4;r+=2-e)i["margin"+(n=Kt[r])]=i["padding"+n]=t;return e&&(i.opacity=i.width=t),i}function K(t,e,n){for(var r,i=($.tweeners[e]||[]).concat($.tweeners["*"]),o=0,a=i.length;o<a;o++)if(r=i[o].call(n,e,t))return r}function X(t,e,n){var r,i,o,a,s,l,u,c,d="width"in e||"height"in e,h=this,f={},p=t.style,g=t.nodeType&&Zt(t),m=Bt.get(t,"fxshow");for(r in n.queue||(null==(a=Tt._queueHooks(t,"fx")).unqueued&&(a.unqueued=0,s=a.empty.fire,a.empty.fire=function(){a.unqueued||s()}),a.unqueued++,h.always(function(){h.always(function(){a.unqueued--,Tt.queue(t,"fx").length||a.empty.fire()})})),e)if(i=e[r],Ae.test(i)){if(delete e[r],o=o||"toggle"===i,i===(g?"hide":"show")){if("show"!==i||!m||m[r]===undefined)continue;g=!0}f[r]=m&&m[r]||Tt.style(t,r)}if((l=!Tt.isEmptyObject(e))||!Tt.isEmptyObject(f))for(r in d&&1===t.nodeType&&(n.overflow=[p.overflow,p.overflowX,p.overflowY],null==(u=m&&m.display)&&(u=Bt.get(t,"display")),"none"===(c=Tt.css(t,"display"))&&(u?c=u:(b([t],!0),u=t.style.display||u,c=Tt.css(t,"display"),b([t]))),("inline"===c||"inline-block"===c&&null!=u)&&"none"===Tt.css(t,"float")&&(l||(h.done(function(){p.display=u}),null==u&&(c=p.display,u="none"===c?"":c)),p.display="inline-block")),n.overflow&&(p.overflow="hidden",h.always(function(){p.overflow=n.overflow[0],p.overflowX=n.overflow[1],p.overflowY=n.overflow[2]})),l=!1,f)l||(m?"hidden"in m&&(g=m.hidden):m=Bt.access(t,"fxshow",{display:u}),o&&(m.hidden=!g),g&&b([t],!0),h.done(function(){for(r in g||b([t]),Bt.remove(t,"fxshow"),f)Tt.style(t,r,f[r])})),l=K(g?m[r]:0,r,h),r in m||(m[r]=l.start,g&&(l.end=l.start,l.start=0))}function Q(t,e){var n,r,i,o,a;for(n in t)if(i=e[r=f(n)],o=t[n],Array.isArray(o)&&(i=o[1],o=t[n]=o[0]),n!==r&&(t[r]=o,delete t[n]),(a=Tt.cssHooks[r])&&"expand"in a)for(n in o=a.expand(o),delete t[r],o)n in t||(t[n]=o[n],e[n]=i);else e[r]=i}function $(o,t,e){var n,a,r=0,i=$.prefilters.length,s=Tt.Deferred().always(function(){delete l.elem}),l=function(){if(a)return!1;for(var t=ke||Y(),e=Math.max(0,u.startTime+u.duration-t),n=1-(e/u.duration||0),r=0,i=u.tweens.length;r<i;r++)u.tweens[r].run(n);return s.notifyWith(o,[u,n,e]),n<1&&i?e:(i||s.notifyWith(o,[u,1,0]),s.resolveWith(o,[u]),!1)},u=s.promise({elem:o,props:Tt.extend({},t),opts:Tt.extend(!0,{specialEasing:{},easing:Tt.easing._default},e),originalProperties:t,originalOptions:e,startTime:ke||Y(),duration:e.duration,tweens:[],createTween:function(t,e){var n=Tt.Tween(o,u.opts,t,e,u.opts.specialEasing[t]||u.opts.easing);return u.tweens.push(n),n},stop:function(t){var e=0,n=t?u.tweens.length:0;if(a)return this;for(a=!0;e<n;e++)u.tweens[e].run(1);return t?(s.notifyWith(o,[u,1,0]),s.resolveWith(o,[u,t])):s.rejectWith(o,[u,t]),this}}),c=u.props;for(Q(c,u.opts.specialEasing);r<i;r++)if(n=$.prefilters[r].call(u,o,c,u.opts))return _t(n.stop)&&(Tt._queueHooks(u.elem,u.opts.queue).stop=n.stop.bind(n)),n;return Tt.map(c,K,u),_t(u.opts.start)&&u.opts.start.call(o,u),u.progress(u.opts.progress).done(u.opts.done,u.opts.complete).fail(u.opts.fail).always(u.opts.always),Tt.fx.timer(Tt.extend(l,{elem:o,anim:u,queue:u.opts.queue})),u}function Z(t){return(t.match(Nt)||[]).join(" ")}function J(t){return t.getAttribute&&t.getAttribute("class")||""}function tt(t){return Array.isArray(t)?t:"string"==typeof t&&t.match(Nt)||[]}function et(n,t,r,i){var e;if(Array.isArray(t))Tt.each(t,function(t,e){r||ze.test(n)?i(n,e):et(n+"["+("object"==typeof e&&null!=e?t:"")+"]",e,r,i)});else if(r||"object"!==m(t))i(n,t);else for(e in t)et(n+"["+e+"]",t[e],r,i)}function nt(o){return function(t,e){"string"!=typeof t&&(e=t,t="*");var n,r=0,i=t.toLowerCase().match(Nt)||[];if(_t(e))for(;n=i[r++];)"+"===n[0]?(n=n.slice(1)||"*",(o[n]=o[n]||[]).unshift(e)):(o[n]=o[n]||[]).push(e)}}function rt(e,i,o,a){function s(t){var r;return l[t]=!0,Tt.each(e[t]||[],function(t,e){var n=e(i,o,a);return"string"!=typeof n||u||l[n]?u?!(r=n):void 0:(i.dataTypes.unshift(n),s(n),!1)}),r}var l={},u=e===Je;return s(i.dataTypes[0])||!l["*"]&&s("*")}function it(t,e){var n,r,i=Tt.ajaxSettings.flatOptions||{};for(n in e)e[n]!==undefined&&((i[n]?t:r||(r={}))[n]=e[n]);return r&&Tt.extend(!0,t,r),t}function ot(t,e,n){for(var r,i,o,a,s=t.contents,l=t.dataTypes;"*"===l[0];)l.shift(),r===undefined&&(r=t.mimeType||e.getResponseHeader("Content-Type"));if(r)for(i in s)if(s[i]&&s[i].test(r)){l.unshift(i);break}if(l[0]in n)o=l[0];else{for(i in n){if(!l[0]||t.converters[i+" "+l[0]]){o=i;break}a||(a=i)}o=o||a}if(o)return o!==l[0]&&l.unshift(o),n[o]}function at(t,e,n,r){var i,o,a,s,l,u={},c=t.dataTypes.slice();if(c[1])for(a in t.converters)u[a.toLowerCase()]=t.converters[a];for(o=c.shift();o;)if(t.responseFields[o]&&(n[t.responseFields[o]]=e),!l&&r&&t.dataFilter&&(e=t.dataFilter(e,t.dataType)),l=o,o=c.shift())if("*"===o)o=l;else if("*"!==l&&l!==o){if(!(a=u[l+" "+o]||u["* "+o]))for(i in u)if((s=i.split(" "))[1]===o&&(a=u[l+" "+s[0]]||u["* "+s[0]])){!0===a?a=u[i]:!0!==u[i]&&(o=s[0],c.unshift(s[1]));break}if(!0!==a)if(a&&t["throws"])e=a(e);else try{e=a(e)}catch(d){return{state:"parsererror",error:a?d:"No conversion from "+l+" to "+o}}}return{state:"success",data:e}}var st=[],lt=T.document,ut=Object.getPrototypeOf,ct=st.slice,dt=st.concat,ht=st.push,ft=st.indexOf,pt={},gt=pt.toString,mt=pt.hasOwnProperty,yt=mt.toString,vt=yt.call(Object),bt={},_t=function _t(t){return"function"==typeof t&&"number"!=typeof t.nodeType},xt=function xt(t){return null!=t&&t===t.window},wt={type:!0,src:!0,nonce:!0,noModule:!0},St="3.4.1",Tt=function(t,e){return new Tt.fn.init(t,e)},kt=/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g;Tt.fn=Tt.prototype={jquery:St,constructor:Tt,length:0,toArray:function(){return ct.call(this)},get:function(t){return null==t?ct.call(this):t<0?this[t+this.length]:this[t]},pushStack:function(t){var e=Tt.merge(this.constructor(),t);return e.prevObject=this,e},each:function(t){return Tt.each(this,t)},map:function(n){return this.pushStack(Tt.map(this,function(t,e){return n.call(t,e,t)}))},slice:function(){return this.pushStack(ct.apply(this,arguments))},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},eq:function(t){var e=this.length,n=+t+(t<0?e:0);return this.pushStack(0<=n&&n<e?[this[n]]:[])},end:function(){return this.prevObject||this.constructor()},push:ht,sort:st.sort,splice:st.splice},Tt.extend=Tt.fn.extend=function(t){var e,n,r,i,o,a,s=t||{},l=1,u=arguments.length,c=!1;for("boolean"==typeof s&&(c=s,s=arguments[l]||{},l++),"object"==typeof s||_t(s)||(s={}),l===u&&(s=this,l--);l<u;l++)if(null!=(e=arguments[l]))for(n in e)i=e[n],"__proto__"!==n&&s!==i&&(c&&i&&(Tt.isPlainObject(i)||(o=Array.isArray(i)))?(r=s[n],a=o&&!Array.isArray(r)?[]:o||Tt.isPlainObject(r)?r:{},o=!1,s[n]=Tt.extend(c,a,i)):i!==undefined&&(s[n]=i));return s},Tt.extend({expando:"jQuery"+(St+Math.random()).replace(/\D/g,""),isReady:!0,error:function(t){throw new Error(t)},noop:function(){},isPlainObject:function(t){var e,n;return!(!t||"[object Object]"!==gt.call(t))&&(!(e=ut(t))||"function"==typeof(n=mt.call(e,"constructor")&&e.constructor)&&yt.call(n)===vt)},isEmptyObject:function(t){var e;for(e in t)return!1;return!0},globalEval:function(t,e){g(t,{nonce:e&&e.nonce})},each:function(t,e){var n,r=0;if(s(t))for(n=t.length;r<n&&!1!==e.call(t[r],r,t[r]);r++);else for(r in t)if(!1===e.call(t[r],r,t[r]))break;return t},trim:function(t){return null==t?"":(t+"").replace(kt,"")},makeArray:function(t,e){var n=e||[];return null!=t&&(s(Object(t))?Tt.merge(n,"string"==typeof t?[t]:t):ht.call(n,t)),n},inArray:function(t,e,n){return null==e?-1:ft.call(e,t,n)},merge:function(t,e){for(var n=+e.length,r=0,i=t.length;r<n;r++)t[i++]=e[r];return t.length=i,t},grep:function(t,e,n){for(var r=[],i=0,o=t.length,a=!n;i<o;i++)!e(t[i],i)!==a&&r.push(t[i]);return r},map:function(t,e,n){var r,i,o=0,a=[];if(s(t))for(r=t.length;o<r;o++)null!=(i=e(t[o],o,n))&&a.push(i);else for(o in t)null!=(i=e(t[o],o,n))&&a.push(i);return dt.apply([],a)},guid:1,support:bt}),"function"==typeof Symbol&&(Tt.fn[Symbol.iterator]=st[Symbol.iterator]),Tt.each("Boolean Number String Function Array Date RegExp Object Error Symbol".split(" "),function(t,e){pt["[object "+e+"]"]=e.toLowerCase()});var Ct=function(n){function _(t,e,n,r){var i,o,a,s,l,u,c,d=e&&e.ownerDocument,h=e?e.nodeType:9;if(n=n||[],"string"!=typeof t||!t||1!==h&&9!==h&&11!==h)return n;if(!r&&((e?e.ownerDocument||e:z)!==P&&I(e),e=e||P,N)){if(11!==h&&(l=bt.exec(t)))if(i=l[1]){if(9===h){if(!(a=e.getElementById(i)))return n;if(a.id===i)return n.push(a),n}else if(d&&(a=d.getElementById(i))&&j(e,a)&&a.id===i)return n.push(a),n}else{if(l[2])return J.apply(n,e.getElementsByTagName(t)),n;if((i=l[3])&&w.getElementsByClassName&&e.getElementsByClassName)return J.apply(n,e.getElementsByClassName(i)),n}if(w.qsa&&!G[t+" "]&&(!R||!R.test(t))&&(1!==h||"object"!==e.nodeName.toLowerCase())){if(c=t,d=e,1===h&&dt.test(t)){for((s=e.getAttribute("id"))?s=s.replace(St,Tt):e.setAttribute("id",s=W),o=(u=C(t)).length;o--;)u[o]="#"+s+" "+g(u[o]);c=u.join(","),d=_t.test(t)&&p(e.parentNode)||e}try{return J.apply(n,d.querySelectorAll(c)),n}catch(f){G(t,!0)}finally{s===W&&e.removeAttribute("id")}}}return D(t.replace(lt,"$1"),e,n,r)}function t(){function n(t,e){return r.push(t+" ")>S.cacheLength&&delete n[r.shift()],n[t+" "]=e}var r=[];return n}function l(t){return t[W]=!0,t}function i(t){var e=P.createElement("fieldset");try{return!!t(e)}catch(n){return!1}finally{e.parentNode&&e.parentNode.removeChild(e),e=null}}function e(t,e){for(var n=t.split("|"),r=n.length;r--;)S.attrHandle[n[r]]=e}function u(t,e){var n=e&&t,r=n&&1===t.nodeType&&1===e.nodeType&&t.sourceIndex-e.sourceIndex;if(r)return r;if(n)for(;n=n.nextSibling;)if(n===e)return-1;return t?1:-1}function r(e){return function(t){return"input"===t.nodeName.toLowerCase()&&t.type===e}}function o(n){return function(t){var e=t.nodeName.toLowerCase();return("input"===e||"button"===e)&&t.type===n}}function a(e){return function(t){return"form"in t?t.parentNode&&!1===t.disabled?"label"in t?"label"in t.parentNode?t.parentNode.disabled===e:t.disabled===e:t.isDisabled===e||t.isDisabled!==!e&&Ct(t)===e:t.disabled===e:"label"in t&&t.disabled===e}}function s(a){return l(function(o){return o=+o,l(function(t,e){for(var n,r=a([],t.length,o),i=r.length;i--;)t[n=r[i]]&&(t[n]=!(e[n]=t[n]))})})}function p(t){return t&&"undefined"!=typeof t.getElementsByTagName&&t}function c(){}function g(t){for(var e=0,n=t.length,r="";e<n;e++)r+=t[e].value;return r}function d(s,t,e){var l=t.dir,u=t.next,c=u||l,d=e&&"parentNode"===c,h=V++;return t.first?function(t,e,n){for(;t=t[l];)if(1===t.nodeType||d)return s(t,e,n);return!1}:function(t,e,n){var r,i,o,a=[B,h];if(n){for(;t=t[l];)if((1===t.nodeType||d)&&s(t,e,n))return!0}else for(;t=t[l];)if(1===t.nodeType||d)if(i=(o=t[W]||(t[W]={}))[t.uniqueID]||(o[t.uniqueID]={}),u&&u===t.nodeName.toLowerCase())t=t[l]||t;else{if((r=i[c])&&r[0]===B&&r[1]===h)return a[2]=r[2];if((i[c]=a)[2]=s(t,e,n))return!0}return!1}}function h(i){return 1<i.length?function(t,e,n){for(var r=i.length;r--;)if(!i[r](t,e,n))return!1;return!0}:i[0]}function v(t,e,n){for(var r=0,i=e.length;r<i;r++)_(t,e[r],n);return n}function x(t,e,n,r,i){for(var o,a=[],s=0,l=t.length,u=null!=e;s<l;s++)(o=t[s])&&(n&&!n(o,r,i)||(a.push(o),u&&e.push(s)));return a}function b(f,p,g,m,y,t){return m&&!m[W]&&(m=b(m)),y&&!y[W]&&(y=b(y,t)),l(function(t,e,n,r){var i,o,a,s=[],l=[],u=e.length,c=t||v(p||"*",n.nodeType?[n]:n,[]),d=!f||!t&&p?c:x(c,s,f,n,r),h=g?y||(t?f:u||m)?[]:e:d;if(g&&g(d,h,n,r),m)for(i=x(h,l),m(i,[],n,r),o=i.length;o--;)(a=i[o])&&(h[l[o]]=!(d[l[o]]=a));if(t){if(y||f){if(y){for(i=[],o=h.length;o--;)(a=h[o])&&i.push(d[o]=a);y(null,h=[],i,r)}for(o=h.length;o--;)(a=h[o])&&-1<(i=y?et(t,a):s[o])&&(t[i]=!(e[i]=a))}}else h=x(h===e?h.splice(u,h.length):h),y?y(null,e,h,r):J.apply(e,h)})}function f(t){for(var i,e,n,r=t.length,o=S.relative[t[0].type],a=o||S.relative[" "],s=o?1:0,l=d(function(t){return t===i},a,!0),u=d(function(t){return-1<et(i,t)},a,!0),c=[function(t,e,n){var r=!o&&(n||e!==A)||((i=e).nodeType?l(t,e,n):u(t,e,n));return i=null,r}];s<r;s++)if(e=S.relative[t[s].type])c=[d(h(c),e)];else{if((e=S.filter[t[s].type].apply(null,t[s].matches))[W]){for(n=++s;n<r&&!S.relative[t[n].type];n++);return b(1<s&&h(c),1<s&&g(t.slice(0,s-1).concat({value:" "===t[s-2].type?"*":""})).replace(lt,"$1"),e,s<n&&f(t.slice(s,n)),n<r&&f(t=t.slice(n)),n<r&&g(t))}c.push(e)}return h(c)}function m(m,y){var v=0<y.length,b=0<m.length,t=function(t,e,n,r,i){var o,a,s,l=0,u="0",c=t&&[],d=[],h=A,f=t||b&&S.find.TAG("*",i),p=B+=null==h?1:Math.random()||.1,g=f.length;for(i&&(A=e===P||e||i);u!==g&&null!=(o=f[u]);u++){if(b&&o){for(a=0,e||o.ownerDocument===P||(I(o),n=!N);s=m[a++];)if(s(o,e||P,n)){r.push(o);break}i&&(B=p)}v&&((o=!s&&o)&&l--,t&&c.push(o))}if(l+=u,v&&u!==l){for(a=0;s=y[a++];)s(c,d,e,n);if(t){if(0<l)for(;u--;)c[u]||d[u]||(d[u]=$.call(r));d=x(d)}J.apply(r,d),i&&!t&&0<d.length&&1<l+y.length&&_.uniqueSort(r)}return i&&(B=p,A=h),c};return v?l(t):t}var y,w,S,T,k,C,E,D,A,M,O,I,P,L,N,R,F,H,j,W="sizzle"+1*new Date,z=n.document,B=0,V=0,q=t(),U=t(),Y=t(),G=t(),K=function(t,e){return t===e&&(O=!0),0},X={}.hasOwnProperty,Q=[],$=Q.pop,Z=Q.push,J=Q.push,tt=Q.slice,et=function(t,e){for(var n=0,r=t.length;n<r;n++)if(t[n]===e)return n;return-1},nt="checked|selected|async|autofocus|autoplay|controls|defer|disabled|hidden|ismap|loop|multiple|open|readonly|required|scoped",rt="[\\x20\\t\\r\\n\\f]",it="(?:\\\\.|[\\w-]|[^\0-\\xa0])+",ot="\\["+rt+"*("+it+")(?:"+rt+"*([*^$|!~]?=)"+rt+"*(?:'((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\"|("+it+"))|)"+rt+"*\\]",at=":("+it+")(?:\\((('((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\")|((?:\\\\.|[^\\\\()[\\]]|"+ot+")*)|.*)\\)|)",st=new RegExp(rt+"+","g"),lt=new RegExp("^"+rt+"+|((?:^|[^\\\\])(?:\\\\.)*)"+rt+"+$","g"),ut=new RegExp("^"+rt+"*,"+rt+"*"),ct=new RegExp("^"+rt+"*([>+~]|"+rt+")"+rt+"*"),dt=new RegExp(rt+"|>"),ht=new RegExp(at),ft=new RegExp("^"+it+"$"),pt={ID:new RegExp("^#("+it+")"),CLASS:new RegExp("^\\.("+it+")"),TAG:new RegExp("^("+it+"|[*])"),ATTR:new RegExp("^"+ot),PSEUDO:new RegExp("^"+at),CHILD:new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+rt+"*(even|odd|(([+-]|)(\\d*)n|)"+rt+"*(?:([+-]|)"+rt+"*(\\d+)|))"+rt+"*\\)|)","i"),bool:new RegExp("^(?:"+nt+")$","i"),needsContext:new RegExp("^"+rt+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+rt+"*((?:-\\d)?\\d*)"+rt+"*\\)|)(?=[^-]|$)","i")},gt=/HTML$/i,mt=/^(?:input|select|textarea|button)$/i,yt=/^h\d$/i,vt=/^[^{]+\{\s*\[native \w/,bt=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,_t=/[+~]/,xt=new RegExp("\\\\([\\da-f]{1,6}"+rt+"?|("+rt+")|.)","ig"),wt=function(t,e,n){var r="0x"+e-65536;return r!=r||n?e:r<0?String.fromCharCode(r+65536):String.fromCharCode(r>>10|55296,1023&r|56320)},St=/([\0-\x1f\x7f]|^-?\d)|^-$|[^\0-\x1f\x7f-\uFFFF\w-]/g,Tt=function(t,e){return e?"\0"===t?"\ufffd":t.slice(0,-1)+"\\"+t.charCodeAt(t.length-1).toString(16)+" ":"\\"+t},kt=function(){I()},Ct=d(function(t){return!0===t.disabled&&"fieldset"===t.nodeName.toLowerCase()},{dir:"parentNode",next:"legend"});try{J.apply(Q=tt.call(z.childNodes),z.childNodes),Q[z.childNodes.length].nodeType}catch(Et){J={apply:Q.length?function(t,e){Z.apply(t,tt.call(e))}:function(t,e){for(var n=t.length,r=0;t[n++]=e[r++];);t.length=n-1}}}for(y in w=_.support={},k=_.isXML=function(t){var e=t.namespaceURI,n=(t.ownerDocument||t).documentElement;return!gt.test(e||n&&n.nodeName||"HTML")},I=_.setDocument=function(t){var e,n,r=t?t.ownerDocument||t:z;return r!==P&&9===r.nodeType&&r.documentElement&&(L=(P=r).documentElement,N=!k(P),z!==P&&(n=P.defaultView)&&n.top!==n&&(n.addEventListener?n.addEventListener("unload",kt,!1):n.attachEvent&&n.attachEvent("onunload",kt)),w.attributes=i(function(t){return t.className="i",!t.getAttribute("className")}),w.getElementsByTagName=i(function(t){return t.appendChild(P.createComment("")),!t.getElementsByTagName("*").length}),w.getElementsByClassName=vt.test(P.getElementsByClassName),w.getById=i(function(t){return L.appendChild(t).id=W,!P.getElementsByName||!P.getElementsByName(W).length}),w.getById?(S.filter.ID=function(t){var e=t.replace(xt,wt);return function(t){return t.getAttribute("id")===e}},S.find.ID=function(t,e){if("undefined"!=typeof e.getElementById&&N){var n=e.getElementById(t);return n?[n]:[]}}):(S.filter.ID=function(t){var n=t.replace(xt,wt);return function(t){var e="undefined"!=typeof t.getAttributeNode&&t.getAttributeNode("id");return e&&e.value===n}},S.find.ID=function(t,e){if("undefined"!=typeof e.getElementById&&N){var n,r,i,o=e.getElementById(t);if(o){if((n=o.getAttributeNode("id"))&&n.value===t)return[o];for(i=e.getElementsByName(t),r=0;o=i[r++];)if((n=o.getAttributeNode("id"))&&n.value===t)return[o]}return[]}}),S.find.TAG=w.getElementsByTagName?function(t,e){return"undefined"!=typeof e.getElementsByTagName?e.getElementsByTagName(t):w.qsa?e.querySelectorAll(t):void 0}:function(t,e){var n,r=[],i=0,o=e.getElementsByTagName(t);if("*"!==t)return o;for(;n=o[i++];)1===n.nodeType&&r.push(n);return r},S.find.CLASS=w.getElementsByClassName&&function(t,e){if("undefined"!=typeof e.getElementsByClassName&&N)return e.getElementsByClassName(t)},F=[],R=[],(w.qsa=vt.test(P.querySelectorAll))&&(i(function(t){L.appendChild(t).innerHTML="<a id='"+W+"'></a><select id='"+W+"-\r\\' msallowcapture=''><option selected=''></option></select>",t.querySelectorAll("[msallowcapture^='']").length&&R.push("[*^$]="+rt+"*(?:''|\"\")"),t.querySelectorAll("[selected]").length||R.push("\\["+rt+"*(?:value|"+nt+")"),t.querySelectorAll("[id~="+W+"-]").length||R.push("~="),t.querySelectorAll(":checked").length||R.push(":checked"),t.querySelectorAll("a#"+W+"+*").length||R.push(".#.+[+~]")}),i(function(t){t.innerHTML="<a href='' disabled='disabled'></a><select disabled='disabled'><option/></select>";var e=P.createElement("input");e.setAttribute("type","hidden"),t.appendChild(e).setAttribute("name","D"),t.querySelectorAll("[name=d]").length&&R.push("name"+rt+"*[*^$|!~]?="),2!==t.querySelectorAll(":enabled").length&&R.push(":enabled",":disabled"),L.appendChild(t).disabled=!0,2!==t.querySelectorAll(":disabled").length&&R.push(":enabled",":disabled"),t.querySelectorAll("*,:x"),R.push(",.*:")})),(w.matchesSelector=vt.test(H=L.matches||L.webkitMatchesSelector||L.mozMatchesSelector||L.oMatchesSelector||L.msMatchesSelector))&&i(function(t){w.disconnectedMatch=H.call(t,"*"),H.call(t,"[s!='']:x"),F.push("!=",at)}),R=R.length&&new RegExp(R.join("|")),F=F.length&&new RegExp(F.join("|")),e=vt.test(L.compareDocumentPosition),j=e||vt.test(L.contains)?function(t,e){var n=9===t.nodeType?t.documentElement:t,r=e&&e.parentNode;return t===r||!(!r||1!==r.nodeType||!(n.contains?n.contains(r):t.compareDocumentPosition&&16&t.compareDocumentPosition(r)))}:function(t,e){if(e)for(;e=e.parentNode;)if(e===t)return!0;return!1},K=e?function(t,e){if(t===e)return O=!0,0;var n=!t.compareDocumentPosition-!e.compareDocumentPosition;return n||(1&(n=(t.ownerDocument||t)===(e.ownerDocument||e)?t.compareDocumentPosition(e):1)||!w.sortDetached&&e.compareDocumentPosition(t)===n?t===P||t.ownerDocument===z&&j(z,t)?-1:e===P||e.ownerDocument===z&&j(z,e)?1:M?et(M,t)-et(M,e):0:4&n?-1:1)}:function(t,e){if(t===e)return O=!0,0;var n,r=0,i=t.parentNode,o=e.parentNode,a=[t],s=[e];if(!i||!o)return t===P?-1:e===P?1:i?-1:o?1:M?et(M,t)-et(M,e):0;if(i===o)return u(t,e);for(n=t;n=n.parentNode;)a.unshift(n);for(n=e;n=n.parentNode;)s.unshift(n);for(;a[r]===s[r];)r++;return r?u(a[r],s[r]):a[r]===z?-1:s[r]===z?1:0}),P},_.matches=function(t,e){return _(t,null,null,e)},_.matchesSelector=function(t,e){if((t.ownerDocument||t)!==P&&I(t),w.matchesSelector&&N&&!G[e+" "]&&(!F||!F.test(e))&&(!R||!R.test(e)))try{var n=H.call(t,e);if(n||w.disconnectedMatch||t.document&&11!==t.document.nodeType)return n}catch(Et){G(e,!0)}return 0<_(e,P,null,[t]).length},_.contains=function(t,e){return(t.ownerDocument||t)!==P&&I(t),j(t,e)},_.attr=function(t,e){(t.ownerDocument||t)!==P&&I(t);var n=S.attrHandle[e.toLowerCase()],r=n&&X.call(S.attrHandle,e.toLowerCase())?n(t,e,!N):undefined;return r!==undefined?r:w.attributes||!N?t.getAttribute(e):(r=t.getAttributeNode(e))&&r.specified?r.value:null},_.escape=function(t){return(t+"").replace(St,Tt)},_.error=function(t){throw new Error("Syntax error, unrecognized expression: "+t)},_.uniqueSort=function(t){var e,n=[],r=0,i=0;if(O=!w.detectDuplicates,M=!w.sortStable&&t.slice(0),t.sort(K),O){for(;e=t[i++];)e===t[i]&&(r=n.push(i));for(;r--;)t.splice(n[r],1)}return M=null,t},T=_.getText=function(t){var e,n="",r=0,i=t.nodeType;if(i){if(1===i||9===i||11===i){if("string"==typeof t.textContent)return t.textContent;for(t=t.firstChild;t;t=t.nextSibling)n+=T(t)}else if(3===i||4===i)return t.nodeValue}else for(;e=t[r++];)n+=T(e);return n},(S=_.selectors={cacheLength:50,createPseudo:l,match:pt,attrHandle:{},find:{},relative:{">":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(t){return t[1]=t[1].replace(xt,wt),t[3]=(t[3]||t[4]||t[5]||"").replace(xt,wt),"~="===t[2]&&(t[3]=" "+t[3]+" "),t.slice(0,4)},CHILD:function(t){return t[1]=t[1].toLowerCase(),"nth"===t[1].slice(0,3)?(t[3]||_.error(t[0]),t[4]=+(t[4]?t[5]+(t[6]||1):2*("even"===t[3]||"odd"===t[3])),t[5]=+(t[7]+t[8]||"odd"===t[3])):t[3]&&_.error(t[0]),t},PSEUDO:function(t){var e,n=!t[6]&&t[2];return pt.CHILD.test(t[0])?null:(t[3]?t[2]=t[4]||t[5]||"":n&&ht.test(n)&&(e=C(n,!0))&&(e=n.indexOf(")",n.length-e)-n.length)&&(t[0]=t[0].slice(0,e),t[2]=n.slice(0,e)),t.slice(0,3))}},filter:{TAG:function(t){var e=t.replace(xt,wt).toLowerCase();return"*"===t?function(){return!0}:function(t){return t.nodeName&&t.nodeName.toLowerCase()===e}},CLASS:function(t){var e=q[t+" "];return e||(e=new RegExp("(^|"+rt+")"+t+"("+rt+"|$)"))&&q(t,function(t){return e.test(
"string"==typeof t.className&&t.className||"undefined"!=typeof t.getAttribute&&t.getAttribute("class")||"")})},ATTR:function(n,r,i){return function(t){var e=_.attr(t,n);return null==e?"!="===r:!r||(e+="","="===r?e===i:"!="===r?e!==i:"^="===r?i&&0===e.indexOf(i):"*="===r?i&&-1<e.indexOf(i):"$="===r?i&&e.slice(-i.length)===i:"~="===r?-1<(" "+e.replace(st," ")+" ").indexOf(i):"|="===r&&(e===i||e.slice(0,i.length+1)===i+"-"))}},CHILD:function(p,t,e,g,m){var y="nth"!==p.slice(0,3),v="last"!==p.slice(-4),b="of-type"===t;return 1===g&&0===m?function(t){return!!t.parentNode}:function(t,e,n){var r,i,o,a,s,l,u=y!==v?"nextSibling":"previousSibling",c=t.parentNode,d=b&&t.nodeName.toLowerCase(),h=!n&&!b,f=!1;if(c){if(y){for(;u;){for(a=t;a=a[u];)if(b?a.nodeName.toLowerCase()===d:1===a.nodeType)return!1;l=u="only"===p&&!l&&"nextSibling"}return!0}if(l=[v?c.firstChild:c.lastChild],v&&h){for(f=(s=(r=(i=(o=(a=c)[W]||(a[W]={}))[a.uniqueID]||(o[a.uniqueID]={}))[p]||[])[0]===B&&r[1])&&r[2],a=s&&c.childNodes[s];a=++s&&a&&a[u]||(f=s=0)||l.pop();)if(1===a.nodeType&&++f&&a===t){i[p]=[B,s,f];break}}else if(h&&(f=s=(r=(i=(o=(a=t)[W]||(a[W]={}))[a.uniqueID]||(o[a.uniqueID]={}))[p]||[])[0]===B&&r[1]),!1===f)for(;(a=++s&&a&&a[u]||(f=s=0)||l.pop())&&((b?a.nodeName.toLowerCase()!==d:1!==a.nodeType)||!++f||(h&&((i=(o=a[W]||(a[W]={}))[a.uniqueID]||(o[a.uniqueID]={}))[p]=[B,f]),a!==t)););return(f-=m)===g||f%g==0&&0<=f/g}}},PSEUDO:function(t,o){var e,a=S.pseudos[t]||S.setFilters[t.toLowerCase()]||_.error("unsupported pseudo: "+t);return a[W]?a(o):1<a.length?(e=[t,t,"",o],S.setFilters.hasOwnProperty(t.toLowerCase())?l(function(t,e){for(var n,r=a(t,o),i=r.length;i--;)t[n=et(t,r[i])]=!(e[n]=r[i])}):function(t){return a(t,0,e)}):a}},pseudos:{not:l(function(t){var r=[],i=[],s=E(t.replace(lt,"$1"));return s[W]?l(function(t,e,n,r){for(var i,o=s(t,null,r,[]),a=t.length;a--;)(i=o[a])&&(t[a]=!(e[a]=i))}):function(t,e,n){return r[0]=t,s(r,null,n,i),r[0]=null,!i.pop()}}),has:l(function(e){return function(t){return 0<_(e,t).length}}),contains:l(function(e){return e=e.replace(xt,wt),function(t){return-1<(t.textContent||T(t)).indexOf(e)}}),lang:l(function(n){return ft.test(n||"")||_.error("unsupported lang: "+n),n=n.replace(xt,wt).toLowerCase(),function(t){var e;do{if(e=N?t.lang:t.getAttribute("xml:lang")||t.getAttribute("lang"))return(e=e.toLowerCase())===n||0===e.indexOf(n+"-")}while((t=t.parentNode)&&1===t.nodeType);return!1}}),target:function(t){var e=n.location&&n.location.hash;return e&&e.slice(1)===t.id},root:function(t){return t===L},focus:function(t){return t===P.activeElement&&(!P.hasFocus||P.hasFocus())&&!!(t.type||t.href||~t.tabIndex)},enabled:a(!1),disabled:a(!0),checked:function(t){var e=t.nodeName.toLowerCase();return"input"===e&&!!t.checked||"option"===e&&!!t.selected},selected:function(t){return t.parentNode&&t.parentNode.selectedIndex,!0===t.selected},empty:function(t){for(t=t.firstChild;t;t=t.nextSibling)if(t.nodeType<6)return!1;return!0},parent:function(t){return!S.pseudos.empty(t)},header:function(t){return yt.test(t.nodeName)},input:function(t){return mt.test(t.nodeName)},button:function(t){var e=t.nodeName.toLowerCase();return"input"===e&&"button"===t.type||"button"===e},text:function(t){var e;return"input"===t.nodeName.toLowerCase()&&"text"===t.type&&(null==(e=t.getAttribute("type"))||"text"===e.toLowerCase())},first:s(function(){return[0]}),last:s(function(t,e){return[e-1]}),eq:s(function(t,e,n){return[n<0?n+e:n]}),even:s(function(t,e){for(var n=0;n<e;n+=2)t.push(n);return t}),odd:s(function(t,e){for(var n=1;n<e;n+=2)t.push(n);return t}),lt:s(function(t,e,n){for(var r=n<0?n+e:e<n?e:n;0<=--r;)t.push(r);return t}),gt:s(function(t,e,n){for(var r=n<0?n+e:n;++r<e;)t.push(r);return t})}}).pseudos.nth=S.pseudos.eq,{radio:!0,checkbox:!0,file:!0,password:!0,image:!0})S.pseudos[y]=r(y);for(y in{submit:!0,reset:!0})S.pseudos[y]=o(y);return c.prototype=S.filters=S.pseudos,S.setFilters=new c,C=_.tokenize=function(t,e){var n,r,i,o,a,s,l,u=U[t+" "];if(u)return e?0:u.slice(0);for(a=t,s=[],l=S.preFilter;a;){for(o in n&&!(r=ut.exec(a))||(r&&(a=a.slice(r[0].length)||a),s.push(i=[])),n=!1,(r=ct.exec(a))&&(n=r.shift(),i.push({value:n,type:r[0].replace(lt," ")}),a=a.slice(n.length)),S.filter)!(r=pt[o].exec(a))||l[o]&&!(r=l[o](r))||(n=r.shift(),i.push({value:n,type:o,matches:r}),a=a.slice(n.length));if(!n)break}return e?a.length:a?_.error(t):U(t,s).slice(0)},E=_.compile=function(t,e){var n,r=[],i=[],o=Y[t+" "];if(!o){for(e||(e=C(t)),n=e.length;n--;)(o=f(e[n]))[W]?r.push(o):i.push(o);(o=Y(t,m(i,r))).selector=t}return o},D=_.select=function(t,e,n,r){var i,o,a,s,l,u="function"==typeof t&&t,c=!r&&C(t=u.selector||t);if(n=n||[],1===c.length){if(2<(o=c[0]=c[0].slice(0)).length&&"ID"===(a=o[0]).type&&9===e.nodeType&&N&&S.relative[o[1].type]){if(!(e=(S.find.ID(a.matches[0].replace(xt,wt),e)||[])[0]))return n;u&&(e=e.parentNode),t=t.slice(o.shift().value.length)}for(i=pt.needsContext.test(t)?0:o.length;i--&&(a=o[i],!S.relative[s=a.type]);)if((l=S.find[s])&&(r=l(a.matches[0].replace(xt,wt),_t.test(o[0].type)&&p(e.parentNode)||e))){if(o.splice(i,1),!(t=r.length&&g(o)))return J.apply(n,r),n;break}}return(u||E(t,c))(r,e,!N,n,!e||_t.test(t)&&p(e.parentNode)||e),n},w.sortStable=W.split("").sort(K).join("")===W,w.detectDuplicates=!!O,I(),w.sortDetached=i(function(t){return 1&t.compareDocumentPosition(P.createElement("fieldset"))}),i(function(t){return t.innerHTML="<a href='#'></a>","#"===t.firstChild.getAttribute("href")})||e("type|href|height|width",function(t,e,n){if(!n)return t.getAttribute(e,"type"===e.toLowerCase()?1:2)}),w.attributes&&i(function(t){return t.innerHTML="<input/>",t.firstChild.setAttribute("value",""),""===t.firstChild.getAttribute("value")})||e("value",function(t,e,n){if(!n&&"input"===t.nodeName.toLowerCase())return t.defaultValue}),i(function(t){return null==t.getAttribute("disabled")})||e(nt,function(t,e,n){var r;if(!n)return!0===t[e]?e.toLowerCase():(r=t.getAttributeNode(e))&&r.specified?r.value:null}),_}(T);Tt.find=Ct,Tt.expr=Ct.selectors,Tt.expr[":"]=Tt.expr.pseudos,Tt.uniqueSort=Tt.unique=Ct.uniqueSort,Tt.text=Ct.getText,Tt.isXMLDoc=Ct.isXML,Tt.contains=Ct.contains,Tt.escapeSelector=Ct.escape;var Et=function(t,e,n){for(var r=[],i=n!==undefined;(t=t[e])&&9!==t.nodeType;)if(1===t.nodeType){if(i&&Tt(t).is(n))break;r.push(t)}return r},Dt=function(t,e){for(var n=[];t;t=t.nextSibling)1===t.nodeType&&t!==e&&n.push(t);return n},At=Tt.expr.match.needsContext,Mt=/^<([a-z][^\/\0>:\x20\t\r\n\f]*)[\x20\t\r\n\f]*\/?>(?:<\/\1>|)$/i;Tt.filter=function(t,e,n){var r=e[0];return n&&(t=":not("+t+")"),1===e.length&&1===r.nodeType?Tt.find.matchesSelector(r,t)?[r]:[]:Tt.find.matches(t,Tt.grep(e,function(t){return 1===t.nodeType}))},Tt.fn.extend({find:function(t){var e,n,r=this.length,i=this;if("string"!=typeof t)return this.pushStack(Tt(t).filter(function(){for(e=0;e<r;e++)if(Tt.contains(i[e],this))return!0}));for(n=this.pushStack([]),e=0;e<r;e++)Tt.find(t,i[e],n);return 1<r?Tt.uniqueSort(n):n},filter:function(t){return this.pushStack(e(this,t||[],!1))},not:function(t){return this.pushStack(e(this,t||[],!0))},is:function(t){return!!e(this,"string"==typeof t&&At.test(t)?Tt(t):t||[],!1).length}});var Ot,It=/^(?:\s*(<[\w\W]+>)[^>]*|#([\w-]+))$/;(Tt.fn.init=function(t,e,n){var r,i;if(!t)return this;if(n=n||Ot,"string"!=typeof t)return t.nodeType?(this[0]=t,this.length=1,this):_t(t)?n.ready!==undefined?n.ready(t):t(Tt):Tt.makeArray(t,this);if(!(r="<"===t[0]&&">"===t[t.length-1]&&3<=t.length?[null,t,null]:It.exec(t))||!r[1]&&e)return!e||e.jquery?(e||n).find(t):this.constructor(e).find(t);if(r[1]){if(e=e instanceof Tt?e[0]:e,Tt.merge(this,Tt.parseHTML(r[1],e&&e.nodeType?e.ownerDocument||e:lt,!0)),Mt.test(r[1])&&Tt.isPlainObject(e))for(r in e)_t(this[r])?this[r](e[r]):this.attr(r,e[r]);return this}return(i=lt.getElementById(r[2]))&&(this[0]=i,this.length=1),this}).prototype=Tt.fn,Ot=Tt(lt);var Pt=/^(?:parents|prev(?:Until|All))/,Lt={children:!0,contents:!0,next:!0,prev:!0};Tt.fn.extend({has:function(t){var e=Tt(t,this),n=e.length;return this.filter(function(){for(var t=0;t<n;t++)if(Tt.contains(this,e[t]))return!0})},closest:function(t,e){var n,r=0,i=this.length,o=[],a="string"!=typeof t&&Tt(t);if(!At.test(t))for(;r<i;r++)for(n=this[r];n&&n!==e;n=n.parentNode)if(n.nodeType<11&&(a?-1<a.index(n):1===n.nodeType&&Tt.find.matchesSelector(n,t))){o.push(n);break}return this.pushStack(1<o.length?Tt.uniqueSort(o):o)},index:function(t){return t?"string"==typeof t?ft.call(Tt(t),this[0]):ft.call(this,t.jquery?t[0]:t):this[0]&&this[0].parentNode?this.first().prevAll().length:-1},add:function(t,e){return this.pushStack(Tt.uniqueSort(Tt.merge(this.get(),Tt(t,e))))},addBack:function(t){return this.add(null==t?this.prevObject:this.prevObject.filter(t))}}),Tt.each({parent:function(t){var e=t.parentNode;return e&&11!==e.nodeType?e:null},parents:function(t){return Et(t,"parentNode")},parentsUntil:function(t,e,n){return Et(t,"parentNode",n)},next:function(t){return n(t,"nextSibling")},prev:function(t){return n(t,"previousSibling")},nextAll:function(t){return Et(t,"nextSibling")},prevAll:function(t){return Et(t,"previousSibling")},nextUntil:function(t,e,n){return Et(t,"nextSibling",n)},prevUntil:function(t,e,n){return Et(t,"previousSibling",n)},siblings:function(t){return Dt((t.parentNode||{}).firstChild,t)},children:function(t){return Dt(t.firstChild)},contents:function(t){return"undefined"!=typeof t.contentDocument?t.contentDocument:(u(t,"template")&&(t=t.content||t),Tt.merge([],t.childNodes))}},function(r,i){Tt.fn[r]=function(t,e){var n=Tt.map(this,i,t);return"Until"!==r.slice(-5)&&(e=t),e&&"string"==typeof e&&(n=Tt.filter(e,n)),1<this.length&&(Lt[r]||Tt.uniqueSort(n),Pt.test(r)&&n.reverse()),this.pushStack(n)}});var Nt=/[^\x20\t\r\n\f]+/g;Tt.Callbacks=function(r){r="string"==typeof r?c(r):Tt.extend({},r);var i,t,e,n,o=[],a=[],s=-1,l=function(){for(n=n||r.once,e=i=!0;a.length;s=-1)for(t=a.shift();++s<o.length;)!1===o[s].apply(t[0],t[1])&&r.stopOnFalse&&(s=o.length,t=!1);r.memory||(t=!1),i=!1,n&&(o=t?[]:"")},u={add:function(){return o&&(t&&!i&&(s=o.length-1,a.push(t)),function n(t){Tt.each(t,function(t,e){_t(e)?r.unique&&u.has(e)||o.push(e):e&&e.length&&"string"!==m(e)&&n(e)})}(arguments),t&&!i&&l()),this},remove:function(){return Tt.each(arguments,function(t,e){for(var n;-1<(n=Tt.inArray(e,o,n));)o.splice(n,1),n<=s&&s--}),this},has:function(t){return t?-1<Tt.inArray(t,o):0<o.length},empty:function(){return o&&(o=[]),this},disable:function(){return n=a=[],o=t="",this},disabled:function(){return!o},lock:function(){return n=a=[],t||i||(o=t=""),this},locked:function(){return!!n},fireWith:function(t,e){return n||(e=[t,(e=e||[]).slice?e.slice():e],a.push(e),i||l()),this},fire:function(){return u.fireWith(this,arguments),this},fired:function(){return!!e}};return u},Tt.extend({Deferred:function(t){var o=[["notify","progress",Tt.Callbacks("memory"),Tt.Callbacks("memory"),2],["resolve","done",Tt.Callbacks("once memory"),Tt.Callbacks("once memory"),0,"resolved"],["reject","fail",Tt.Callbacks("once memory"),Tt.Callbacks("once memory"),1,"rejected"]],i="pending",a={state:function(){return i},always:function(){return s.done(arguments).fail(arguments),this},"catch":function(t){return a.then(null,t)},pipe:function(){var i=arguments;return Tt.Deferred(function(r){Tt.each(o,function(t,e){var n=_t(i[e[4]])&&i[e[4]];s[e[1]](function(){var t=n&&n.apply(this,arguments);t&&_t(t.promise)?t.promise().progress(r.notify).done(r.resolve).fail(r.reject):r[e[0]+"With"](this,n?[t]:arguments)})}),i=null}).promise()},then:function(e,n,r){function u(o,a,s,l){return function(){var n=this,r=arguments,e=function(){var t,e;if(!(o<c)){if((t=s.apply(n,r))===a.promise())throw new TypeError("Thenable self-resolution");e=t&&("object"==typeof t||"function"==typeof t)&&t.then,_t(e)?l?e.call(t,u(c,a,d,l),u(c,a,h,l)):(c++,e.call(t,u(c,a,d,l),u(c,a,h,l),u(c,a,d,a.notifyWith))):(s!==d&&(n=undefined,r=[t]),(l||a.resolveWith)(n,r))}},i=l?e:function(){try{e()}catch(t){Tt.Deferred.exceptionHook&&Tt.Deferred.exceptionHook(t,i.stackTrace),c<=o+1&&(s!==h&&(n=undefined,r=[t]),a.rejectWith(n,r))}};o?i():(Tt.Deferred.getStackHook&&(i.stackTrace=Tt.Deferred.getStackHook()),T.setTimeout(i))}}var c=0;return Tt.Deferred(function(t){o[0][3].add(u(0,t,_t(r)?r:d,t.notifyWith)),o[1][3].add(u(0,t,_t(e)?e:d)),o[2][3].add(u(0,t,_t(n)?n:h))}).promise()},promise:function(t){return null!=t?Tt.extend(t,a):a}},s={};return Tt.each(o,function(t,e){var n=e[2],r=e[5];a[e[1]]=n.add,r&&n.add(function(){i=r},o[3-t][2].disable,o[3-t][3].disable,o[0][2].lock,o[0][3].lock),n.add(e[3].fire),s[e[0]]=function(){return s[e[0]+"With"](this===s?undefined:this,arguments),this},s[e[0]+"With"]=n.fireWith}),a.promise(s),t&&t.call(s,s),s},when:function(t){var n=arguments.length,e=n,r=Array(e),i=ct.call(arguments),o=Tt.Deferred(),a=function(e){return function(t){r[e]=this,i[e]=1<arguments.length?ct.call(arguments):t,--n||o.resolveWith(r,i)}};if(n<=1&&(l(t,o.done(a(e)).resolve,o.reject,!n),"pending"===o.state()||_t(i[e]&&i[e].then)))return o.then();for(;e--;)l(i[e],a(e),o.reject);return o.promise()}});var Rt=/^(Eval|Internal|Range|Reference|Syntax|Type|URI)Error$/;Tt.Deferred.exceptionHook=function(t,e){T.console&&T.console.warn&&t&&Rt.test(t.name)&&T.console.warn("jQuery.Deferred exception: "+t.message,t.stack,e)},Tt.readyException=function(t){T.setTimeout(function(){throw t})};var Ft=Tt.Deferred();Tt.fn.ready=function(t){return Ft.then(t)["catch"](function(t){Tt.readyException(t)}),this},Tt.extend({isReady:!1,readyWait:1,ready:function(t){(!0===t?--Tt.readyWait:Tt.isReady)||(Tt.isReady=!0)!==t&&0<--Tt.readyWait||Ft.resolveWith(lt,[Tt])}}),Tt.ready.then=Ft.then,"complete"===lt.readyState||"loading"!==lt.readyState&&!lt.documentElement.doScroll?T.setTimeout(Tt.ready):(lt.addEventListener("DOMContentLoaded",r),T.addEventListener("load",r));var Ht=function(t,e,n,r,i,o,a){var s=0,l=t.length,u=null==n;if("object"===m(n))for(s in i=!0,n)Ht(t,e,s,n[s],!0,o,a);else if(r!==undefined&&(i=!0,_t(r)||(a=!0),u&&(a?(e.call(t,r),e=null):(u=e,e=function(t,e,n){return u.call(Tt(t),n)})),e))for(;s<l;s++)e(t[s],n,a?r:r.call(t[s],s,e(t[s],n)));return i?t:u?e.call(t):l?e(t[0],n):o},jt=/^-ms-/,Wt=/-([a-z])/g,zt=function(t){return 1===t.nodeType||9===t.nodeType||!+t.nodeType};o.uid=1,o.prototype={cache:function(t){var e=t[this.expando];return e||(e={},zt(t)&&(t.nodeType?t[this.expando]=e:Object.defineProperty(t,this.expando,{value:e,configurable:!0}))),e},set:function(t,e,n){var r,i=this.cache(t);if("string"==typeof e)i[f(e)]=n;else for(r in e)i[f(r)]=e[r];return i},get:function(t,e){return e===undefined?this.cache(t):t[this.expando]&&t[this.expando][f(e)]},access:function(t,e,n){return e===undefined||e&&"string"==typeof e&&n===undefined?this.get(t,e):(this.set(t,e,n),n!==undefined?n:e)},remove:function(t,e){var n,r=t[this.expando];if(r!==undefined){if(e!==undefined){n=(e=Array.isArray(e)?e.map(f):(e=f(e))in r?[e]:e.match(Nt)||[]).length;for(;n--;)delete r[e[n]]}(e===undefined||Tt.isEmptyObject(r))&&(t.nodeType?t[this.expando]=undefined:delete t[this.expando])}},hasData:function(t){var e=t[this.expando];return e!==undefined&&!Tt.isEmptyObject(e)}};var Bt=new o,Vt=new o,qt=/^(?:\{[\w\W]*\}|\[[\w\W]*\])$/,Ut=/[A-Z]/g;Tt.extend({hasData:function(t){return Vt.hasData(t)||Bt.hasData(t)},data:function(t,e,n){return Vt.access(t,e,n)},removeData:function(t,e){Vt.remove(t,e)},_data:function(t,e,n){return Bt.access(t,e,n)},_removeData:function(t,e){Bt.remove(t,e)}}),Tt.fn.extend({data:function(n,t){var e,r,i,o=this[0],a=o&&o.attributes;if(n!==undefined)return"object"==typeof n?this.each(function(){Vt.set(this,n)}):Ht(this,function(t){var e;if(o&&t===undefined)return(e=Vt.get(o,n))!==undefined?e:(e=p(o,n))!==undefined?e:void 0;this.each(function(){Vt.set(this,n,t)})},null,t,1<arguments.length,null,!0);if(this.length&&(i=Vt.get(o),1===o.nodeType&&!Bt.get(o,"hasDataAttrs"))){for(e=a.length;e--;)a[e]&&0===(r=a[e].name).indexOf("data-")&&(r=f(r.slice(5)),p(o,r,i[r]));Bt.set(o,"hasDataAttrs",!0)}return i},removeData:function(t){return this.each(function(){Vt.remove(this,t)})}}),Tt.extend({queue:function(t,e,n){var r;if(t)return e=(e||"fx")+"queue",r=Bt.get(t,e),n&&(!r||Array.isArray(n)?r=Bt.access(t,e,Tt.makeArray(n)):r.push(n)),r||[]},dequeue:function(t,e){e=e||"fx";var n=Tt.queue(t,e),r=n.length,i=n.shift(),o=Tt._queueHooks(t,e),a=function(){Tt.dequeue(t,e)};"inprogress"===i&&(i=n.shift(),r--),i&&("fx"===e&&n.unshift("inprogress"),delete o.stop,i.call(t,a,o)),!r&&o&&o.empty.fire()},_queueHooks:function(t,e){var n=e+"queueHooks";return Bt.get(t,n)||Bt.access(t,n,{empty:Tt.Callbacks("once memory").add(function(){Bt.remove(t,[e+"queue",n])})})}}),Tt.fn.extend({queue:function(e,n){var t=2;return"string"!=typeof e&&(n=e,e="fx",t--),arguments.length<t?Tt.queue(this[0],e):n===undefined?this:this.each(function(){var t=Tt.queue(this,e,n);Tt._queueHooks(this,e),"fx"===e&&"inprogress"!==t[0]&&Tt.dequeue(this,e)})},dequeue:function(t){return this.each(function(){Tt.dequeue(this,t)})},clearQueue:function(t){return this.queue(t||"fx",[])},promise:function(t,e){var n,r=1,i=Tt.Deferred(),o=this,a=this.length,s=function(){--r||i.resolveWith(o,[o])};for("string"!=typeof t&&(e=t,t=undefined),t=t||"fx";a--;)(n=Bt.get(o[a],t+"queueHooks"))&&n.empty&&(r++,n.empty.add(s));return s(),i.promise(e)}});var Yt=/[+-]?(?:\d*\.|)\d+(?:[eE][+-]?\d+|)/.source,Gt=new RegExp("^(?:([+-])=|)("+Yt+")([a-z%]*)$","i"),Kt=["Top","Right","Bottom","Left"],Xt=lt.documentElement,Qt=function(t){return Tt.contains(t.ownerDocument,t)},$t={composed:!0};Xt.getRootNode&&(Qt=function(t){return Tt.contains(t.ownerDocument,t)||t.getRootNode($t)===t.ownerDocument});var Zt=function(t,e){return"none"===(t=e||t).style.display||""===t.style.display&&Qt(t)&&"none"===Tt.css(t,"display")},Jt=function(t,e,n,r){var i,o,a={};for(o in e)a[o]=t.style[o],t.style[o]=e[o];for(o in i=n.apply(t,r||[]),e)t.style[o]=a[o];return i},te={};Tt.fn.extend({show:function(){return b(this,!0)},hide:function(){return b(this)},toggle:function(t){return"boolean"==typeof t?t?this.show():this.hide():this.each(function(){Zt(this)?Tt(this).show():Tt(this).hide()})}});var ee=/^(?:checkbox|radio)$/i,ne=/<([a-z][^\/\0>\x20\t\r\n\f]*)/i,re=/^$|^module$|\/(?:java|ecma)script/i,ie={option:[1,"<select multiple='multiple'>","</select>"],thead:[1,"<table>","</table>"],col:[2,"<table><colgroup>","</colgroup></table>"],tr:[2,"<table><tbody>","</tbody></table>"],td:[3,"<table><tbody><tr>","</tr></tbody></table>"],_default:[0,"",""]};ie.optgroup=ie.option,ie.tbody=ie.tfoot=ie.colgroup=ie.caption=ie.thead,ie.th=ie.td;var oe,ae,se=/<|&#?\w+;/;oe=lt.createDocumentFragment().appendChild(lt.createElement("div")),(ae=lt.createElement("input")).setAttribute("type","radio"),ae.setAttribute("checked","checked"),ae.setAttribute("name","t"),oe.appendChild(ae),bt.checkClone=oe.cloneNode(!0).cloneNode(!0).lastChild.checked,oe.innerHTML="<textarea>x</textarea>",bt.noCloneChecked=!!oe.cloneNode(!0).lastChild.defaultValue;var le=/^key/,ue=/^(?:mouse|pointer|contextmenu|drag|drop)|click/,ce=/^([^.]*)(?:\.(.+)|)/;Tt.event={global:{},add:function(e,t,n,r,i){var o,a,s,l,u,c,d,h,f,p,g,m=Bt.get(e);if(m)for(n.handler&&(n=(o=n).handler,i=o.selector),i&&Tt.find.matchesSelector(Xt,i),n.guid||(n.guid=Tt.guid++),(l=m.events)||(l=m.events={}),(a=m.handle)||(a=m.handle=function(t){return void 0!==Tt&&Tt.event.triggered!==t.type?Tt.event.dispatch.apply(e,arguments):undefined}),u=(t=(t||"").match(Nt)||[""]).length;u--;)f=g=(s=ce.exec(t[u])||[])[1],p=(s[2]||"").split(".").sort(),f&&(d=Tt.event.special[f]||{},f=(i?d.delegateType:d.bindType)||f,d=Tt.event.special[f]||{},c=Tt.extend({type:f,origType:g,data:r,handler:n,guid:n.guid,selector:i,needsContext:i&&Tt.expr.match.needsContext.test(i),namespace:p.join(".")},o),(h=l[f])||((h=l[f]=[]).delegateCount=0,d.setup&&!1!==d.setup.call(e,r,p,a)||e.addEventListener&&e.addEventListener(f,a)),d.add&&(d.add.call(e,c),c.handler.guid||(c.handler.guid=n.guid)),i?h.splice(h.delegateCount++,0,c):h.push(c),Tt.event.global[f]=!0)},remove:function(t,e,n,r,i){var o,a,s,l,u,c,d,h,f,p,g,m=Bt.hasData(t)&&Bt.get(t);if(m&&(l=m.events)){for(u=(e=(e||"").match(Nt)||[""]).length;u--;)if(f=g=(s=ce.exec(e[u])||[])[1],p=(s[2]||"").split(".").sort(),f){for(d=Tt.event.special[f]||{},h=l[f=(r?d.delegateType:d.bindType)||f]||[],s=s[2]&&new RegExp("(^|\\.)"+p.join("\\.(?:.*\\.|)")+"(\\.|$)"),a=o=h.length;o--;)c=h[o],!i&&g!==c.origType||n&&n.guid!==c.guid||s&&!s.test(c.namespace)||r&&r!==c.selector&&("**"!==r||!c.selector)||(h.splice(o,1),c.selector&&h.delegateCount--,d.remove&&d.remove.call(t,c));a&&!h.length&&(d.teardown&&!1!==d.teardown.call(t,p,m.handle)||Tt.removeEvent(t,f,m.handle),delete l[f])}else for(f in l)Tt.event.remove(t,f+e[u],n,r,!0);Tt.isEmptyObject(l)&&Bt.remove(t,"handle events")}},dispatch:function(t){var e,n,r,i,o,a,s=Tt.event.fix(t),l=new Array(arguments.length),u=(Bt.get(this,"events")||{})[s.type]||[],c=Tt.event.special[s.type]||{};for(l[0]=s,e=1;e<arguments.length;e++)l[e]=arguments[e];if(s.delegateTarget=this,!c.preDispatch||!1!==c.preDispatch.call(this,s)){for(a=Tt.event.handlers.call(this,s,u),e=0;(i=a[e++])&&!s.isPropagationStopped();)for(s.currentTarget=i.elem,n=0;(o=i.handlers[n++])&&!s.isImmediatePropagationStopped();)s.rnamespace&&!1!==o.namespace&&!s.rnamespace.test(o.namespace)||(s.handleObj=o,s.data=o.data,(r=((Tt.event.special[o.origType]||{}).handle||o.handler).apply(i.elem,l))!==undefined&&!1===(s.result=r)&&(s.preventDefault(),s.stopPropagation()));return c.postDispatch&&c.postDispatch.call(this,s),s.result}},handlers:function(t,e){var n,r,i,o,a,s=[],l=e.delegateCount,u=t.target;if(l&&u.nodeType&&!("click"===t.type&&1<=t.button))for(;u!==this;u=u.parentNode||this)if(1===u.nodeType&&("click"!==t.type||!0!==u.disabled)){for(o=[],a={},n=0;n<l;n++)a[i=(r=e[n]).selector+" "]===undefined&&(a[i]=r.needsContext?-1<Tt(i,this).index(u):Tt.find(i,this,null,[u]).length),a[i]&&o.push(r);o.length&&s.push({elem:u,handlers:o})}return u=this,l<e.length&&s.push({elem:u,handlers:e.slice(l)}),s},addProp:function(e,t){Object.defineProperty(Tt.Event.prototype,e,{enumerable:!0,configurable:!0,get:_t(t)?function(){if(this.originalEvent)return t(this.originalEvent)}:function(){if(this.originalEvent)return this.originalEvent[e]},set:function(t){Object.defineProperty(this,e,{enumerable:!0,configurable:!0,writable:!0,value:t})}})},fix:function(t){return t[Tt.expando]?t:new Tt.Event(t)},special:{load:{noBubble:!0},click:{setup:function(t){var e=this||t;return ee.test(e.type)&&e.click&&u(e,"input")&&A(e,"click",S),!1},trigger:function(t){var e=this||t;return ee.test(e.type)&&e.click&&u(e,"input")&&A(e,"click"),!0},_default:function(t){var e=t.target;return ee.test(e.type)&&e.click&&u(e,"input")&&Bt.get(e,"click")||u(e,"a")}},beforeunload:{postDispatch:function(t){t.result!==undefined&&t.originalEvent&&(t.originalEvent.returnValue=t.result)}}}},Tt.removeEvent=function(t,e,n){t.removeEventListener&&t.removeEventListener(e,n)},Tt.Event=function(t,e){if(!(this instanceof Tt.Event))return new Tt.Event(t,e);t&&t.type?(this.originalEvent=t,this.type=t.type,this.isDefaultPrevented=t.defaultPrevented||t.defaultPrevented===undefined&&!1===t.returnValue?S:k,this.target=t.target&&3===t.target.nodeType?t.target.parentNode:t.target,this.currentTarget=t.currentTarget,this.relatedTarget=t.relatedTarget):this.type=t,e&&Tt.extend(this,e),this.timeStamp=t&&t.timeStamp||Date.now(),this[Tt.expando]=!0},Tt.Event.prototype={constructor:Tt.Event,isDefaultPrevented:k,isPropagationStopped:k,isImmediatePropagationStopped:k,isSimulated:!1,preventDefault:function(){var t=this.originalEvent;this.isDefaultPrevented=S,t&&!this.isSimulated&&t.preventDefault()},stopPropagation:function(){var t=this.originalEvent;this.isPropagationStopped=S,t&&!this.isSimulated&&t.stopPropagation()},stopImmediatePropagation:function(){var t=this.originalEvent;this.isImmediatePropagationStopped=S,t&&!this.isSimulated&&t.stopImmediatePropagation(),this.stopPropagation()}},Tt.each({altKey:!0,bubbles:!0,cancelable:!0,changedTouches:!0,ctrlKey:!0,detail:!0,eventPhase:!0,metaKey:!0,pageX:!0,pageY:!0,shiftKey:!0,view:!0,"char":!0,code:!0,charCode:!0,key:!0,keyCode:!0,button:!0,buttons:!0,clientX:!0,clientY:!0,offsetX:!0,offsetY:!0,pointerId:!0,pointerType:!0,screenX:!0,screenY:!0,targetTouches:!0,toElement:!0,touches:!0,which:function(t){var e=t.button;return null==t.which&&le.test(t.type)?null!=t.charCode?t.charCode:t.keyCode:!t.which&&e!==undefined&&ue.test(t.type)?1&e?1:2&e?3:4&e?2:0:t.which}},Tt.event.addProp),Tt.each({focus:"focusin",blur:"focusout"},function(t,e){Tt.event.special[t]={setup:function(){return A(this,t,C),!1},trigger:function(){return A(this,t),!0},delegateType:e}}),Tt.each({mouseenter:"mouseover",mouseleave:"mouseout",pointerenter:"pointerover",pointerleave:"pointerout"},function(t,o){Tt.event.special[t]={delegateType:o,bindType:o,handle:function(t){var e,n=this,r=t.relatedTarget,i=t.handleObj;return r&&(r===n||Tt.contains(n,r))||(t.type=i.origType,e=i.handler.apply(this,arguments),t.type=o),e}}}),Tt.fn.extend({on:function(t,e,n,r){return D(this,t,e,n,r)},one:function(t,e,n,r){return D(this,t,e,n,r,1)},off:function(t,e,n){var r,i;if(t&&t.preventDefault&&t.handleObj)return r=t.handleObj,Tt(t.delegateTarget).off(r.namespace?r.origType+"."+r.namespace:r.origType,r.selector,r.handler),this;if("object"!=typeof t)return!1!==e&&"function"!=typeof e||(n=e,e=undefined),!1===n&&(n=k),this.each(function(){Tt.event.remove(this,t,n,e)});for(i in t)this.off(i,e,t[i]);return this}});var de=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([a-z][^\/\0>\x20\t\r\n\f]*)[^>]*)\/>/gi,he=/<script|<style|<link/i,fe=/checked\s*(?:[^=]|=\s*.checked.)/i,pe=/^\s*<!(?:\[CDATA\[|--)|(?:\]\]|--)>\s*$/g;Tt.extend({htmlPrefilter:function(t){return t.replace(de,"<$1></$2>")},clone:function(t,e,n){var r,i,o,a,s=t.cloneNode(!0),l=Qt(t);if(!(bt.noCloneChecked||1!==t.nodeType&&11!==t.nodeType||Tt.isXMLDoc(t)))for(a=_(s),r=0,i=(o=_(t)).length;r<i;r++)L(o[r],a[r]);if(e)if(n)for(o=o||_(t),a=a||_(s),r=0,i=o.length;r<i;r++)P(o[r],a[r]);else P(t,s);return 0<(a=_(s,"script")).length&&x(a,!l&&_(t,"script")),s},cleanData:function(t){for(var e,n,r,i=Tt.event.special,o=0;(n=t[o])!==undefined;o++)if(zt(n)){if(e=n[Bt.expando]){if(e.events)for(r in e.events)i[r]?Tt.event.remove(n,r):Tt.removeEvent(n,r,e.handle);n[Bt.expando]=undefined}n[Vt.expando]&&(n[Vt.expando]=undefined)}}}),Tt.fn.extend({detach:function(t){return R(this,t,!0)},remove:function(t){return R(this,t)},text:function(t){return Ht(this,function(t){return t===undefined?Tt.text(this):this.empty().each(function(){1!==this.nodeType&&11!==this.nodeType&&9!==this.nodeType||(this.textContent=t)})},null,t,arguments.length)},append:function(){return N(this,arguments,function(t){1!==this.nodeType&&11!==this.nodeType&&9!==this.nodeType||M(this,t).appendChild(t)})},prepend:function(){return N(this,arguments,function(t){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var e=M(this,t);e.insertBefore(t,e.firstChild)}})},before:function(){return N(this,arguments,function(t){this.parentNode&&this.parentNode.insertBefore(t,this)})},after:function(){return N(this,arguments,function(t){this.parentNode&&this.parentNode.insertBefore(t,this.nextSibling)})},empty:function(){for(var t,e=0;null!=(t=this[e]);e++)1===t.nodeType&&(Tt.cleanData(_(t,!1)),t.textContent="");return this},clone:function(t,e){return t=null!=t&&t,e=null==e?t:e,this.map(function(){return Tt.clone(this,t,e)})},html:function(t){return Ht(this,function(t){var e=this[0]||{},n=0,r=this.length;if(t===undefined&&1===e.nodeType)return e.innerHTML;if("string"==typeof t&&!he.test(t)&&!ie[(ne.exec(t)||["",""])[1].toLowerCase()]){t=Tt.htmlPrefilter(t);try{for(;n<r;n++)1===(e=this[n]||{}).nodeType&&(Tt.cleanData(_(e,!1)),e.innerHTML=t);e=0}catch(i){}}e&&this.empty().append(t)},null,t,arguments.length)},replaceWith:function(){var n=[];return N(this,arguments,function(t){var e=this.parentNode;Tt.inArray(this,n)<0&&(Tt.cleanData(_(this)),e&&e.replaceChild(t,this))},n)}}),Tt.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(t,a){Tt.fn[t]=function(t){for(var e,n=[],r=Tt(t),i=r.length-1,o=0;o<=i;o++)e=o===i?this:this.clone(!0),Tt(r[o])[a](e),ht.apply(n,e.get());return this.pushStack(n)}});var ge=new RegExp("^("+Yt+")(?!px)[a-z%]+$","i"),me=function(t){var e=t.ownerDocument.defaultView;return e&&e.opener||(e=T),e.getComputedStyle(t)},ye=new RegExp(Kt.join("|"),"i");!function(){function t(){if(l){s.style.cssText="position:absolute;left:-11111px;width:60px;margin-top:1px;padding:0;border:0",l.style.cssText="position:relative;display:block;box-sizing:border-box;overflow:scroll;margin:auto;border:1px;padding:1px;width:60%;top:1%",Xt.appendChild(s).appendChild(l);var t=T.getComputedStyle(l);n="1%"!==t.top,a=12===e(t.marginLeft),l.style.right="60%",o=36===e(t.right),r=36===e(t.width),l.style.position="absolute",i=12===e(l.offsetWidth/3),Xt.removeChild(s),l=null}}function e(t){return Math.round(parseFloat(t))}var n,r,i,o,a,s=lt.createElement("div"),l=lt.createElement("div");l.style&&(l.style.backgroundClip="content-box",l.cloneNode(!0).style.backgroundClip="",bt.clearCloneStyle="content-box"===l.style.backgroundClip,Tt.extend(bt,{boxSizingReliable:function(){return t(),r},pixelBoxStyles:function(){return t(),o},pixelPosition:function(){return t(),n},reliableMarginLeft:function(){return t(),a},scrollboxSize:function(){return t(),i}}))}();var ve=["Webkit","Moz","ms"],be=lt.createElement("div").style,_e={},xe=/^(none|table(?!-c[ea]).+)/,we=/^--/,Se={position:"absolute",visibility:"hidden",display:"block"},Te={letterSpacing:"0",fontWeight:"400"};Tt.extend({cssHooks:{opacity:{get:function(t,e){if(e){var n=F(t,"opacity");return""===n?"1":n}}}},cssNumber:{animationIterationCount:!0,columnCount:!0,fillOpacity:!0,flexGrow:!0,flexShrink:!0,fontWeight:!0,gridArea:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnStart:!0,gridRow:!0,gridRowEnd:!0,gridRowStart:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,widows:!0,zIndex:!0,zoom:!0},cssProps:{},style:function(t,e,n,r){if(t&&3!==t.nodeType&&8!==t.nodeType&&t.style){var i,o,a,s=f(e),l=we.test(e),u=t.style;if(l||(e=W(s)),a=Tt.cssHooks[e]||Tt.cssHooks[s],n===undefined)return a&&"get"in a&&(i=a.get(t,!1,r))!==undefined?i:u[e];"string"===(o=typeof n)&&(i=Gt.exec(n))&&i[1]&&(n=y(t,e,i),o="number"),null!=n&&n==n&&("number"!==o||l||(n+=i&&i[3]||(Tt.cssNumber[s]?"":"px")),bt.clearCloneStyle||""!==n||0!==e.indexOf("background")||(u[e]="inherit"),a&&"set"in a&&(n=a.set(t,n,r))===undefined||(l?u.setProperty(e,n):u[e]=n))}},css:function(t,e,n,r){var i,o,a,s=f(e);return we.test(e)||(e=W(s)),(a=Tt.cssHooks[e]||Tt.cssHooks[s])&&"get"in a&&(i=a.get(t,!0,n)),i===undefined&&(i=F(t,e,r)),"normal"===i&&e in Te&&(i=Te[e]),""===n||n?(o=parseFloat(i),!0===n||isFinite(o)?o||0:i):i}}),Tt.each(["height","width"],function(t,l){Tt.cssHooks[l]={get:function(t,e,n){if(e)return!xe.test(Tt.css(t,"display"))||t.getClientRects().length&&t.getBoundingClientRect().width?V(t,l,n):Jt(t,Se,function(){return V(t,l,n)})},set:function(t,e,n){var r,i=me(t),o=!bt.scrollboxSize()&&"absolute"===i.position,a=(o||n)&&"border-box"===Tt.css(t,"boxSizing",!1,i),s=n?B(t,l,n,a,i):0;return a&&o&&(s-=Math.ceil(t["offset"+l[0].toUpperCase()+l.slice(1)]-parseFloat(i[l])-B(t,l,"border",!1,i)-.5)),s&&(r=Gt.exec(e))&&"px"!==(r[3]||"px")&&(t.style[l]=e,e=Tt.css(t,l)),z(t,e,s)}}}),Tt.cssHooks.marginLeft=H(bt.reliableMarginLeft,function(t,e){if(e)return(parseFloat(F(t,"marginLeft"))||t.getBoundingClientRect().left-Jt(t,{marginLeft:0},function(){return t.getBoundingClientRect().left}))+"px"}),Tt.each({margin:"",padding:"",border:"Width"},function(i,o){Tt.cssHooks[i+o]={expand:function(t){for(var e=0,n={},r="string"==typeof t?t.split(" "):[t];e<4;e++)n[i+Kt[e]+o]=r[e]||r[e-2]||r[0];return n}},"margin"!==i&&(Tt.cssHooks[i+o].set=z)}),Tt.fn.extend({css:function(t,e){return Ht(this,function(t,e,n){var r,i,o={},a=0;if(Array.isArray(e)){for(r=me(t),i=e.length;a<i;a++)o[e[a]]=Tt.css(t,e[a],!1,r);return o}return n!==undefined?Tt.style(t,e,n):Tt.css(t,e)},t,e,1<arguments.length)}}),(Tt.Tween=q).prototype={constructor:q,init:function(t,e,n,r,i,o){this.elem=t,this.prop=n,this.easing=i||Tt.easing._default,this.options=e,this.start=this.now=this.cur(),this.end=r,this.unit=o||(Tt.cssNumber[n]?"":"px")},cur:function(){var t=q.propHooks[this.prop];return t&&t.get?t.get(this):q.propHooks._default.get(this)},run:function(t){var e,n=q.propHooks[this.prop];return this.options.duration?this.pos=e=Tt.easing[this.easing](t,this.options.duration*t,0,1,this.options.duration):this.pos=e=t,this.now=(this.end-this.start)*e+this.start,this.options.step&&this.options.step.call(this.elem,this.now,this),n&&n.set?n.set(this
):q.propHooks._default.set(this),this}},q.prototype.init.prototype=q.prototype,q.propHooks={_default:{get:function(t){var e;return 1!==t.elem.nodeType||null!=t.elem[t.prop]&&null==t.elem.style[t.prop]?t.elem[t.prop]:(e=Tt.css(t.elem,t.prop,""))&&"auto"!==e?e:0},set:function(t){Tt.fx.step[t.prop]?Tt.fx.step[t.prop](t):1!==t.elem.nodeType||!Tt.cssHooks[t.prop]&&null==t.elem.style[W(t.prop)]?t.elem[t.prop]=t.now:Tt.style(t.elem,t.prop,t.now+t.unit)}}},q.propHooks.scrollTop=q.propHooks.scrollLeft={set:function(t){t.elem.nodeType&&t.elem.parentNode&&(t.elem[t.prop]=t.now)}},Tt.easing={linear:function(t){return t},swing:function(t){return.5-Math.cos(t*Math.PI)/2},_default:"swing"},Tt.fx=q.prototype.init,Tt.fx.step={};var ke,Ce,Ee,De,Ae=/^(?:toggle|show|hide)$/,Me=/queueHooks$/;Tt.Animation=Tt.extend($,{tweeners:{"*":[function(t,e){var n=this.createTween(t,e);return y(n.elem,t,Gt.exec(e),n),n}]},tweener:function(t,e){_t(t)?(e=t,t=["*"]):t=t.match(Nt);for(var n,r=0,i=t.length;r<i;r++)n=t[r],$.tweeners[n]=$.tweeners[n]||[],$.tweeners[n].unshift(e)},prefilters:[X],prefilter:function(t,e){e?$.prefilters.unshift(t):$.prefilters.push(t)}}),Tt.speed=function(t,e,n){var r=t&&"object"==typeof t?Tt.extend({},t):{complete:n||!n&&e||_t(t)&&t,duration:t,easing:n&&e||e&&!_t(e)&&e};return Tt.fx.off?r.duration=0:"number"!=typeof r.duration&&(r.duration in Tt.fx.speeds?r.duration=Tt.fx.speeds[r.duration]:r.duration=Tt.fx.speeds._default),null!=r.queue&&!0!==r.queue||(r.queue="fx"),r.old=r.complete,r.complete=function(){_t(r.old)&&r.old.call(this),r.queue&&Tt.dequeue(this,r.queue)},r},Tt.fn.extend({fadeTo:function(t,e,n,r){return this.filter(Zt).css("opacity",0).show().end().animate({opacity:e},t,n,r)},animate:function(e,t,n,r){var i=Tt.isEmptyObject(e),o=Tt.speed(t,n,r),a=function(){var t=$(this,Tt.extend({},e),o);(i||Bt.get(this,"finish"))&&t.stop(!0)};return a.finish=a,i||!1===o.queue?this.each(a):this.queue(o.queue,a)},stop:function(i,t,o){var a=function(t){var e=t.stop;delete t.stop,e(o)};return"string"!=typeof i&&(o=t,t=i,i=undefined),t&&!1!==i&&this.queue(i||"fx",[]),this.each(function(){var t=!0,e=null!=i&&i+"queueHooks",n=Tt.timers,r=Bt.get(this);if(e)r[e]&&r[e].stop&&a(r[e]);else for(e in r)r[e]&&r[e].stop&&Me.test(e)&&a(r[e]);for(e=n.length;e--;)n[e].elem!==this||null!=i&&n[e].queue!==i||(n[e].anim.stop(o),t=!1,n.splice(e,1));!t&&o||Tt.dequeue(this,i)})},finish:function(a){return!1!==a&&(a=a||"fx"),this.each(function(){var t,e=Bt.get(this),n=e[a+"queue"],r=e[a+"queueHooks"],i=Tt.timers,o=n?n.length:0;for(e.finish=!0,Tt.queue(this,a,[]),r&&r.stop&&r.stop.call(this,!0),t=i.length;t--;)i[t].elem===this&&i[t].queue===a&&(i[t].anim.stop(!0),i.splice(t,1));for(t=0;t<o;t++)n[t]&&n[t].finish&&n[t].finish.call(this);delete e.finish})}}),Tt.each(["toggle","show","hide"],function(t,r){var i=Tt.fn[r];Tt.fn[r]=function(t,e,n){return null==t||"boolean"==typeof t?i.apply(this,arguments):this.animate(G(r,!0),t,e,n)}}),Tt.each({slideDown:G("show"),slideUp:G("hide"),slideToggle:G("toggle"),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"},fadeToggle:{opacity:"toggle"}},function(t,r){Tt.fn[t]=function(t,e,n){return this.animate(r,t,e,n)}}),Tt.timers=[],Tt.fx.tick=function(){var t,e=0,n=Tt.timers;for(ke=Date.now();e<n.length;e++)(t=n[e])()||n[e]!==t||n.splice(e--,1);n.length||Tt.fx.stop(),ke=undefined},Tt.fx.timer=function(t){Tt.timers.push(t),Tt.fx.start()},Tt.fx.interval=13,Tt.fx.start=function(){Ce||(Ce=!0,U())},Tt.fx.stop=function(){Ce=null},Tt.fx.speeds={slow:600,fast:200,_default:400},Tt.fn.delay=function(r,t){return r=Tt.fx&&Tt.fx.speeds[r]||r,t=t||"fx",this.queue(t,function(t,e){var n=T.setTimeout(t,r);e.stop=function(){T.clearTimeout(n)}})},Ee=lt.createElement("input"),De=lt.createElement("select").appendChild(lt.createElement("option")),Ee.type="checkbox",bt.checkOn=""!==Ee.value,bt.optSelected=De.selected,(Ee=lt.createElement("input")).value="t",Ee.type="radio",bt.radioValue="t"===Ee.value;var Oe,Ie=Tt.expr.attrHandle;Tt.fn.extend({attr:function(t,e){return Ht(this,Tt.attr,t,e,1<arguments.length)},removeAttr:function(t){return this.each(function(){Tt.removeAttr(this,t)})}}),Tt.extend({attr:function(t,e,n){var r,i,o=t.nodeType;if(3!==o&&8!==o&&2!==o)return"undefined"==typeof t.getAttribute?Tt.prop(t,e,n):(1===o&&Tt.isXMLDoc(t)||(i=Tt.attrHooks[e.toLowerCase()]||(Tt.expr.match.bool.test(e)?Oe:undefined)),n!==undefined?null===n?void Tt.removeAttr(t,e):i&&"set"in i&&(r=i.set(t,n,e))!==undefined?r:(t.setAttribute(e,n+""),n):i&&"get"in i&&null!==(r=i.get(t,e))?r:null==(r=Tt.find.attr(t,e))?undefined:r)},attrHooks:{type:{set:function(t,e){if(!bt.radioValue&&"radio"===e&&u(t,"input")){var n=t.value;return t.setAttribute("type",e),n&&(t.value=n),e}}}},removeAttr:function(t,e){var n,r=0,i=e&&e.match(Nt);if(i&&1===t.nodeType)for(;n=i[r++];)t.removeAttribute(n)}}),Oe={set:function(t,e,n){return!1===e?Tt.removeAttr(t,n):t.setAttribute(n,n),n}},Tt.each(Tt.expr.match.bool.source.match(/\w+/g),function(t,e){var a=Ie[e]||Tt.find.attr;Ie[e]=function(t,e,n){var r,i,o=e.toLowerCase();return n||(i=Ie[o],Ie[o]=r,r=null!=a(t,e,n)?o:null,Ie[o]=i),r}});var Pe=/^(?:input|select|textarea|button)$/i,Le=/^(?:a|area)$/i;Tt.fn.extend({prop:function(t,e){return Ht(this,Tt.prop,t,e,1<arguments.length)},removeProp:function(t){return this.each(function(){delete this[Tt.propFix[t]||t]})}}),Tt.extend({prop:function(t,e,n){var r,i,o=t.nodeType;if(3!==o&&8!==o&&2!==o)return 1===o&&Tt.isXMLDoc(t)||(e=Tt.propFix[e]||e,i=Tt.propHooks[e]),n!==undefined?i&&"set"in i&&(r=i.set(t,n,e))!==undefined?r:t[e]=n:i&&"get"in i&&null!==(r=i.get(t,e))?r:t[e]},propHooks:{tabIndex:{get:function(t){var e=Tt.find.attr(t,"tabindex");return e?parseInt(e,10):Pe.test(t.nodeName)||Le.test(t.nodeName)&&t.href?0:-1}}},propFix:{"for":"htmlFor","class":"className"}}),bt.optSelected||(Tt.propHooks.selected={get:function(t){var e=t.parentNode;return e&&e.parentNode&&e.parentNode.selectedIndex,null},set:function(t){var e=t.parentNode;e&&(e.selectedIndex,e.parentNode&&e.parentNode.selectedIndex)}}),Tt.each(["tabIndex","readOnly","maxLength","cellSpacing","cellPadding","rowSpan","colSpan","useMap","frameBorder","contentEditable"],function(){Tt.propFix[this.toLowerCase()]=this}),Tt.fn.extend({addClass:function(e){var t,n,r,i,o,a,s,l=0;if(_t(e))return this.each(function(t){Tt(this).addClass(e.call(this,t,J(this)))});if((t=tt(e)).length)for(;n=this[l++];)if(i=J(n),r=1===n.nodeType&&" "+Z(i)+" "){for(a=0;o=t[a++];)r.indexOf(" "+o+" ")<0&&(r+=o+" ");i!==(s=Z(r))&&n.setAttribute("class",s)}return this},removeClass:function(e){var t,n,r,i,o,a,s,l=0;if(_t(e))return this.each(function(t){Tt(this).removeClass(e.call(this,t,J(this)))});if(!arguments.length)return this.attr("class","");if((t=tt(e)).length)for(;n=this[l++];)if(i=J(n),r=1===n.nodeType&&" "+Z(i)+" "){for(a=0;o=t[a++];)for(;-1<r.indexOf(" "+o+" ");)r=r.replace(" "+o+" "," ");i!==(s=Z(r))&&n.setAttribute("class",s)}return this},toggleClass:function(i,e){var o=typeof i,a="string"===o||Array.isArray(i);return"boolean"==typeof e&&a?e?this.addClass(i):this.removeClass(i):_t(i)?this.each(function(t){Tt(this).toggleClass(i.call(this,t,J(this),e),e)}):this.each(function(){var t,e,n,r;if(a)for(e=0,n=Tt(this),r=tt(i);t=r[e++];)n.hasClass(t)?n.removeClass(t):n.addClass(t);else i!==undefined&&"boolean"!==o||((t=J(this))&&Bt.set(this,"__className__",t),this.setAttribute&&this.setAttribute("class",t||!1===i?"":Bt.get(this,"__className__")||""))})},hasClass:function(t){var e,n,r=0;for(e=" "+t+" ";n=this[r++];)if(1===n.nodeType&&-1<(" "+Z(J(n))+" ").indexOf(e))return!0;return!1}});var Ne=/\r/g;Tt.fn.extend({val:function(n){var r,t,i,e=this[0];return arguments.length?(i=_t(n),this.each(function(t){var e;1===this.nodeType&&(null==(e=i?n.call(this,t,Tt(this).val()):n)?e="":"number"==typeof e?e+="":Array.isArray(e)&&(e=Tt.map(e,function(t){return null==t?"":t+""})),(r=Tt.valHooks[this.type]||Tt.valHooks[this.nodeName.toLowerCase()])&&"set"in r&&r.set(this,e,"value")!==undefined||(this.value=e))})):e?(r=Tt.valHooks[e.type]||Tt.valHooks[e.nodeName.toLowerCase()])&&"get"in r&&(t=r.get(e,"value"))!==undefined?t:"string"==typeof(t=e.value)?t.replace(Ne,""):null==t?"":t:void 0}}),Tt.extend({valHooks:{option:{get:function(t){var e=Tt.find.attr(t,"value");return null!=e?e:Z(Tt.text(t))}},select:{get:function(t){var e,n,r,i=t.options,o=t.selectedIndex,a="select-one"===t.type,s=a?null:[],l=a?o+1:i.length;for(r=o<0?l:a?o:0;r<l;r++)if(((n=i[r]).selected||r===o)&&!n.disabled&&(!n.parentNode.disabled||!u(n.parentNode,"optgroup"))){if(e=Tt(n).val(),a)return e;s.push(e)}return s},set:function(t,e){for(var n,r,i=t.options,o=Tt.makeArray(e),a=i.length;a--;)((r=i[a]).selected=-1<Tt.inArray(Tt.valHooks.option.get(r),o))&&(n=!0);return n||(t.selectedIndex=-1),o}}}}),Tt.each(["radio","checkbox"],function(){Tt.valHooks[this]={set:function(t,e){if(Array.isArray(e))return t.checked=-1<Tt.inArray(Tt(t).val(),e)}},bt.checkOn||(Tt.valHooks[this].get=function(t){return null===t.getAttribute("value")?"on":t.value})}),bt.focusin="onfocusin"in T;var Re=/^(?:focusinfocus|focusoutblur)$/,Fe=function(t){t.stopPropagation()};Tt.extend(Tt.event,{trigger:function(t,e,n,r){var i,o,a,s,l,u,c,d,h=[n||lt],f=mt.call(t,"type")?t.type:t,p=mt.call(t,"namespace")?t.namespace.split("."):[];if(o=d=a=n=n||lt,3!==n.nodeType&&8!==n.nodeType&&!Re.test(f+Tt.event.triggered)&&(-1<f.indexOf(".")&&(f=(p=f.split(".")).shift(),p.sort()),l=f.indexOf(":")<0&&"on"+f,(t=t[Tt.expando]?t:new Tt.Event(f,"object"==typeof t&&t)).isTrigger=r?2:3,t.namespace=p.join("."),t.rnamespace=t.namespace?new RegExp("(^|\\.)"+p.join("\\.(?:.*\\.|)")+"(\\.|$)"):null,t.result=undefined,t.target||(t.target=n),e=null==e?[t]:Tt.makeArray(e,[t]),c=Tt.event.special[f]||{},r||!c.trigger||!1!==c.trigger.apply(n,e))){if(!r&&!c.noBubble&&!xt(n)){for(s=c.delegateType||f,Re.test(s+f)||(o=o.parentNode);o;o=o.parentNode)h.push(o),a=o;a===(n.ownerDocument||lt)&&h.push(a.defaultView||a.parentWindow||T)}for(i=0;(o=h[i++])&&!t.isPropagationStopped();)d=o,t.type=1<i?s:c.bindType||f,(u=(Bt.get(o,"events")||{})[t.type]&&Bt.get(o,"handle"))&&u.apply(o,e),(u=l&&o[l])&&u.apply&&zt(o)&&(t.result=u.apply(o,e),!1===t.result&&t.preventDefault());return t.type=f,r||t.isDefaultPrevented()||c._default&&!1!==c._default.apply(h.pop(),e)||!zt(n)||l&&_t(n[f])&&!xt(n)&&((a=n[l])&&(n[l]=null),Tt.event.triggered=f,t.isPropagationStopped()&&d.addEventListener(f,Fe),n[f](),t.isPropagationStopped()&&d.removeEventListener(f,Fe),Tt.event.triggered=undefined,a&&(n[l]=a)),t.result}},simulate:function(t,e,n){var r=Tt.extend(new Tt.Event,n,{type:t,isSimulated:!0});Tt.event.trigger(r,null,e)}}),Tt.fn.extend({trigger:function(t,e){return this.each(function(){Tt.event.trigger(t,e,this)})},triggerHandler:function(t,e){var n=this[0];if(n)return Tt.event.trigger(t,e,n,!0)}}),bt.focusin||Tt.each({focus:"focusin",blur:"focusout"},function(n,r){var i=function(t){Tt.event.simulate(r,t.target,Tt.event.fix(t))};Tt.event.special[r]={setup:function(){var t=this.ownerDocument||this,e=Bt.access(t,r);e||t.addEventListener(n,i,!0),Bt.access(t,r,(e||0)+1)},teardown:function(){var t=this.ownerDocument||this,e=Bt.access(t,r)-1;e?Bt.access(t,r,e):(t.removeEventListener(n,i,!0),Bt.remove(t,r))}}});var He=T.location,je=Date.now(),We=/\?/;Tt.parseXML=function(t){var e;if(!t||"string"!=typeof t)return null;try{e=(new T.DOMParser).parseFromString(t,"text/xml")}catch(n){e=undefined}return e&&!e.getElementsByTagName("parsererror").length||Tt.error("Invalid XML: "+t),e};var ze=/\[\]$/,Be=/\r?\n/g,Ve=/^(?:submit|button|image|reset|file)$/i,qe=/^(?:input|select|textarea|keygen)/i;Tt.param=function(t,e){var n,r=[],i=function(t,e){var n=_t(e)?e():e;r[r.length]=encodeURIComponent(t)+"="+encodeURIComponent(null==n?"":n)};if(null==t)return"";if(Array.isArray(t)||t.jquery&&!Tt.isPlainObject(t))Tt.each(t,function(){i(this.name,this.value)});else for(n in t)et(n,t[n],e,i);return r.join("&")},Tt.fn.extend({serialize:function(){return Tt.param(this.serializeArray())},serializeArray:function(){return this.map(function(){var t=Tt.prop(this,"elements");return t?Tt.makeArray(t):this}).filter(function(){var t=this.type;return this.name&&!Tt(this).is(":disabled")&&qe.test(this.nodeName)&&!Ve.test(t)&&(this.checked||!ee.test(t))}).map(function(t,e){var n=Tt(this).val();return null==n?null:Array.isArray(n)?Tt.map(n,function(t){return{name:e.name,value:t.replace(Be,"\r\n")}}):{name:e.name,value:n.replace(Be,"\r\n")}}).get()}});var Ue=/%20/g,Ye=/#.*$/,Ge=/([?&])_=[^&]*/,Ke=/^(.*?):[ \t]*([^\r\n]*)$/gm,Xe=/^(?:about|app|app-storage|.+-extension|file|res|widget):$/,Qe=/^(?:GET|HEAD)$/,$e=/^\/\//,Ze={},Je={},tn="*/".concat("*"),en=lt.createElement("a");en.href=He.href,Tt.extend({active:0,lastModified:{},etag:{},ajaxSettings:{url:He.href,type:"GET",isLocal:Xe.test(He.protocol),global:!0,processData:!0,async:!0,contentType:"application/x-www-form-urlencoded; charset=UTF-8",accepts:{"*":tn,text:"text/plain",html:"text/html",xml:"application/xml, text/xml",json:"application/json, text/javascript"},contents:{xml:/\bxml\b/,html:/\bhtml/,json:/\bjson\b/},responseFields:{xml:"responseXML",text:"responseText",json:"responseJSON"},converters:{"* text":String,"text html":!0,"text json":JSON.parse,"text xml":Tt.parseXML},flatOptions:{url:!0,context:!0}},ajaxSetup:function(t,e){return e?it(it(t,Tt.ajaxSettings),e):it(Tt.ajaxSettings,t)},ajaxPrefilter:nt(Ze),ajaxTransport:nt(Je),ajax:function(t,e){function n(t,e,n,r){var i,o,a,s,l,u=e;p||(p=!0,f&&T.clearTimeout(f),c=undefined,h=r||"",w.readyState=0<t?4:0,i=200<=t&&t<300||304===t,n&&(s=ot(m,w,n)),s=at(m,s,w,i),i?(m.ifModified&&((l=w.getResponseHeader("Last-Modified"))&&(Tt.lastModified[d]=l),(l=w.getResponseHeader("etag"))&&(Tt.etag[d]=l)),204===t||"HEAD"===m.type?u="nocontent":304===t?u="notmodified":(u=s.state,o=s.data,i=!(a=s.error))):(a=u,!t&&u||(u="error",t<0&&(t=0))),w.status=t,w.statusText=(e||u)+"",i?b.resolveWith(y,[o,u,w]):b.rejectWith(y,[w,u,a]),w.statusCode(x),x=undefined,g&&v.trigger(i?"ajaxSuccess":"ajaxError",[w,m,i?o:a]),_.fireWith(y,[w,u]),g&&(v.trigger("ajaxComplete",[w,m]),--Tt.active||Tt.event.trigger("ajaxStop")))}"object"==typeof t&&(e=t,t=undefined),e=e||{};var c,d,h,r,f,i,p,g,o,a,m=Tt.ajaxSetup({},e),y=m.context||m,v=m.context&&(y.nodeType||y.jquery)?Tt(y):Tt.event,b=Tt.Deferred(),_=Tt.Callbacks("once memory"),x=m.statusCode||{},s={},l={},u="canceled",w={readyState:0,getResponseHeader:function(t){var e;if(p){if(!r)for(r={};e=Ke.exec(h);)r[e[1].toLowerCase()+" "]=(r[e[1].toLowerCase()+" "]||[]).concat(e[2]);e=r[t.toLowerCase()+" "]}return null==e?null:e.join(", ")},getAllResponseHeaders:function(){return p?h:null},setRequestHeader:function(t,e){return null==p&&(t=l[t.toLowerCase()]=l[t.toLowerCase()]||t,s[t]=e),this},overrideMimeType:function(t){return null==p&&(m.mimeType=t),this},statusCode:function(t){var e;if(t)if(p)w.always(t[w.status]);else for(e in t)x[e]=[x[e],t[e]];return this},abort:function(t){var e=t||u;return c&&c.abort(e),n(0,e),this}};if(b.promise(w),m.url=((t||m.url||He.href)+"").replace($e,He.protocol+"//"),m.type=e.method||e.type||m.method||m.type,m.dataTypes=(m.dataType||"*").toLowerCase().match(Nt)||[""],null==m.crossDomain){i=lt.createElement("a");try{i.href=m.url,i.href=i.href,m.crossDomain=en.protocol+"//"+en.host!=i.protocol+"//"+i.host}catch(S){m.crossDomain=!0}}if(m.data&&m.processData&&"string"!=typeof m.data&&(m.data=Tt.param(m.data,m.traditional)),rt(Ze,m,e,w),p)return w;for(o in(g=Tt.event&&m.global)&&0==Tt.active++&&Tt.event.trigger("ajaxStart"),m.type=m.type.toUpperCase(),m.hasContent=!Qe.test(m.type),d=m.url.replace(Ye,""),m.hasContent?m.data&&m.processData&&0===(m.contentType||"").indexOf("application/x-www-form-urlencoded")&&(m.data=m.data.replace(Ue,"+")):(a=m.url.slice(d.length),m.data&&(m.processData||"string"==typeof m.data)&&(d+=(We.test(d)?"&":"?")+m.data,delete m.data),!1===m.cache&&(d=d.replace(Ge,"$1"),a=(We.test(d)?"&":"?")+"_="+je+++a),m.url=d+a),m.ifModified&&(Tt.lastModified[d]&&w.setRequestHeader("If-Modified-Since",Tt.lastModified[d]),Tt.etag[d]&&w.setRequestHeader("If-None-Match",Tt.etag[d])),(m.data&&m.hasContent&&!1!==m.contentType||e.contentType)&&w.setRequestHeader("Content-Type",m.contentType),w.setRequestHeader("Accept",m.dataTypes[0]&&m.accepts[m.dataTypes[0]]?m.accepts[m.dataTypes[0]]+("*"!==m.dataTypes[0]?", "+tn+"; q=0.01":""):m.accepts["*"]),m.headers)w.setRequestHeader(o,m.headers[o]);if(m.beforeSend&&(!1===m.beforeSend.call(y,w,m)||p))return w.abort();if(u="abort",_.add(m.complete),w.done(m.success),w.fail(m.error),c=rt(Je,m,e,w)){if(w.readyState=1,g&&v.trigger("ajaxSend",[w,m]),p)return w;m.async&&0<m.timeout&&(f=T.setTimeout(function(){w.abort("timeout")},m.timeout));try{p=!1,c.send(s,n)}catch(S){if(p)throw S;n(-1,S)}}else n(-1,"No Transport");return w},getJSON:function(t,e,n){return Tt.get(t,e,n,"json")},getScript:function(t,e){return Tt.get(t,undefined,e,"script")}}),Tt.each(["get","post"],function(t,i){Tt[i]=function(t,e,n,r){return _t(e)&&(r=r||n,n=e,e=undefined),Tt.ajax(Tt.extend({url:t,type:i,dataType:r,data:e,success:n},Tt.isPlainObject(t)&&t))}}),Tt._evalUrl=function(t,e){return Tt.ajax({url:t,type:"GET",dataType:"script",cache:!0,async:!1,global:!1,converters:{"text script":function(){}},dataFilter:function(t){Tt.globalEval(t,e)}})},Tt.fn.extend({wrapAll:function(t){var e;return this[0]&&(_t(t)&&(t=t.call(this[0])),e=Tt(t,this[0].ownerDocument).eq(0).clone(!0),this[0].parentNode&&e.insertBefore(this[0]),e.map(function(){for(var t=this;t.firstElementChild;)t=t.firstElementChild;return t}).append(this)),this},wrapInner:function(n){return _t(n)?this.each(function(t){Tt(this).wrapInner(n.call(this,t))}):this.each(function(){var t=Tt(this),e=t.contents();e.length?e.wrapAll(n):t.append(n)})},wrap:function(e){var n=_t(e);return this.each(function(t){Tt(this).wrapAll(n?e.call(this,t):e)})},unwrap:function(t){return this.parent(t).not("body").each(function(){Tt(this).replaceWith(this.childNodes)}),this}}),Tt.expr.pseudos.hidden=function(t){return!Tt.expr.pseudos.visible(t)},Tt.expr.pseudos.visible=function(t){return!!(t.offsetWidth||t.offsetHeight||t.getClientRects().length)},Tt.ajaxSettings.xhr=function(){try{return new T.XMLHttpRequest}catch(t){}};var nn={0:200,1223:204},rn=Tt.ajaxSettings.xhr();bt.cors=!!rn&&"withCredentials"in rn,bt.ajax=rn=!!rn,Tt.ajaxTransport(function(o){var a,s;if(bt.cors||rn&&!o.crossDomain)return{send:function(t,e){var n,r=o.xhr();if(r.open(o.type,o.url,o.async,o.username,o.password),o.xhrFields)for(n in o.xhrFields)r[n]=o.xhrFields[n];for(n in o.mimeType&&r.overrideMimeType&&r.overrideMimeType(o.mimeType),o.crossDomain||t["X-Requested-With"]||(t["X-Requested-With"]="XMLHttpRequest"),t)r.setRequestHeader(n,t[n]);a=function(t){return function(){a&&(a=s=r.onload=r.onerror=r.onabort=r.ontimeout=r.onreadystatechange=null,"abort"===t?r.abort():"error"===t?"number"!=typeof r.status?e(0,"error"):e(r.status,r.statusText):e(nn[r.status]||r.status,r.statusText,"text"!==(r.responseType||"text")||"string"!=typeof r.responseText?{binary:r.response}:{text:r.responseText},r.getAllResponseHeaders()))}},r.onload=a(),s=r.onerror=r.ontimeout=a("error"),r.onabort!==undefined?r.onabort=s:r.onreadystatechange=function(){4===r.readyState&&T.setTimeout(function(){a&&s()})},a=a("abort");try{r.send(o.hasContent&&o.data||null)}catch(i){if(a)throw i}},abort:function(){a&&a()}}}),Tt.ajaxPrefilter(function(t){t.crossDomain&&(t.contents.script=!1)}),Tt.ajaxSetup({accepts:{script:"text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"},contents:{script:/\b(?:java|ecma)script\b/},converters:{"text script":function(t){return Tt.globalEval(t),t}}}),Tt.ajaxPrefilter("script",function(t){t.cache===undefined&&(t.cache=!1),t.crossDomain&&(t.type="GET")}),Tt.ajaxTransport("script",function(n){var r,i;if(n.crossDomain||n.scriptAttrs)return{send:function(t,e){r=Tt("<script>").attr(n.scriptAttrs||{}).prop({charset:n.scriptCharset,src:n.url}).on("load error",i=function(t){r.remove(),i=null,t&&e("error"===t.type?404:200,t.type)}),lt.head.appendChild(r[0])},abort:function(){i&&i()}}});var on,an=[],sn=/(=)\?(?=&|$)|\?\?/;Tt.ajaxSetup({jsonp:"callback",jsonpCallback:function(){var t=an.pop()||Tt.expando+"_"+je++;return this[t]=!0,t}}),Tt.ajaxPrefilter("json jsonp",function(t,e,n){var r,i,o,a=!1!==t.jsonp&&(sn.test(t.url)?"url":"string"==typeof t.data&&0===(t.contentType||"").indexOf("application/x-www-form-urlencoded")&&sn.test(t.data)&&"data");if(a||"jsonp"===t.dataTypes[0])return r=t.jsonpCallback=_t(t.jsonpCallback)?t.jsonpCallback():t.jsonpCallback,a?t[a]=t[a].replace(sn,"$1"+r):!1!==t.jsonp&&(t.url+=(We.test(t.url)?"&":"?")+t.jsonp+"="+r),t.converters["script json"]=function(){return o||Tt.error(r+" was not called"),o[0]},t.dataTypes[0]="json",i=T[r],T[r]=function(){o=arguments},n.always(function(){i===undefined?Tt(T).removeProp(r):T[r]=i,t[r]&&(t.jsonpCallback=e.jsonpCallback,an.push(r)),o&&_t(i)&&i(o[0]),o=i=undefined}),"script"}),bt.createHTMLDocument=((on=lt.implementation.createHTMLDocument("").body).innerHTML="<form></form><form></form>",2===on.childNodes.length),Tt.parseHTML=function(t,e,n){return"string"!=typeof t?[]:("boolean"==typeof e&&(n=e,e=!1),e||(bt.createHTMLDocument?((r=(e=lt.implementation.createHTMLDocument("")).createElement("base")).href=lt.location.href,e.head.appendChild(r)):e=lt),o=!n&&[],(i=Mt.exec(t))?[e.createElement(i[1])]:(i=w([t],e,o),o&&o.length&&Tt(o).remove(),Tt.merge([],i.childNodes)));var r,i,o},Tt.fn.load=function(t,e,n){var r,i,o,a=this,s=t.indexOf(" ");return-1<s&&(r=Z(t.slice(s)),t=t.slice(0,s)),_t(e)?(n=e,e=undefined):e&&"object"==typeof e&&(i="POST"),0<a.length&&Tt.ajax({url:t,type:i||"GET",dataType:"html",data:e}).done(function(t){o=arguments,a.html(r?Tt("<div>").append(Tt.parseHTML(t)).find(r):t)}).always(n&&function(t,e){a.each(function(){n.apply(this,o||[t.responseText,e,t])})}),this},Tt.each(["ajaxStart","ajaxStop","ajaxComplete","ajaxError","ajaxSuccess","ajaxSend"],function(t,e){Tt.fn[e]=function(t){return this.on(e,t)}}),Tt.expr.pseudos.animated=function(e){return Tt.grep(Tt.timers,function(t){return e===t.elem}).length},Tt.offset={setOffset:function(t,e,n){var r,i,o,a,s,l,u=Tt.css(t,"position"),c=Tt(t),d={};"static"===u&&(t.style.position="relative"),s=c.offset(),o=Tt.css(t,"top"),l=Tt.css(t,"left"),("absolute"===u||"fixed"===u)&&-1<(o+l).indexOf("auto")?(a=(r=c.position()).top,i=r.left):(a=parseFloat(o)||0,i=parseFloat(l)||0),_t(e)&&(e=e.call(t,n,Tt.extend({},s))),null!=e.top&&(d.top=e.top-s.top+a),null!=e.left&&(d.left=e.left-s.left+i),"using"in e?e.using.call(t,d):c.css(d)}},Tt.fn.extend({offset:function(e){if(arguments.length)return e===undefined?this:this.each(function(t){Tt.offset.setOffset(this,e,t)});var t,n,r=this[0];return r?r.getClientRects().length?(t=r.getBoundingClientRect(),n=r.ownerDocument.defaultView,{top:t.top+n.pageYOffset,left:t.left+n.pageXOffset}):{top:0,left:0}:void 0},position:function(){if(this[0]){var t,e,n,r=this[0],i={top:0,left:0};if("fixed"===Tt.css(r,"position"))e=r.getBoundingClientRect();else{for(e=this.offset(),n=r.ownerDocument,t=r.offsetParent||n.documentElement;t&&(t===n.body||t===n.documentElement)&&"static"===Tt.css(t,"position");)t=t.parentNode;t&&t!==r&&1===t.nodeType&&((i=Tt(t).offset()).top+=Tt.css(t,"borderTopWidth",!0),i.left+=Tt.css(t,"borderLeftWidth",!0))}return{top:e.top-i.top-Tt.css(r,"marginTop",!0),left:e.left-i.left-Tt.css(r,"marginLeft",!0)}}},offsetParent:function(){return this.map(function(){for(var t=this.offsetParent;t&&"static"===Tt.css(t,"position");)t=t.offsetParent;return t||Xt})}}),Tt.each({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},function(e,i){var o="pageYOffset"===i;Tt.fn[e]=function(t){return Ht(this,function(t,e,n){var r;if(xt(t)?r=t:9===t.nodeType&&(r=t.defaultView),n===undefined)return r?r[i]:t[e];r?r.scrollTo(o?r.pageXOffset:n,o?n:r.pageYOffset):t[e]=n},e,t,arguments.length)}}),Tt.each(["top","left"],function(t,n){Tt.cssHooks[n]=H(bt.pixelPosition,function(t,e){if(e)return e=F(t,n),ge.test(e)?Tt(t).position()[n]+"px":e})}),Tt.each({Height:"height",Width:"width"},function(a,s){Tt.each({padding:"inner"+a,content:s,"":"outer"+a},function(r,o){Tt.fn[o]=function(t,e){var n=arguments.length&&(r||"boolean"!=typeof t),i=r||(!0===t||!0===e?"margin":"border");return Ht(this,function(t,e,n){var r;return xt(t)?0===o.indexOf("outer")?t["inner"+a]:t.document.documentElement["client"+a]:9===t.nodeType?(r=t.documentElement,Math.max(t.body["scroll"+a],r["scroll"+a],t.body["offset"+a],r["offset"+a],r["client"+a])):n===undefined?Tt.css(t,e,i):Tt.style(t,e,n,i)},s,n?t:undefined,n)}})}),Tt.each("blur focus focusin focusout resize scroll click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select submit keydown keypress keyup contextmenu".split(" "),function(t,n){Tt.fn[n]=function(t,e){return 0<arguments.length?this.on(n,null,t,e):this.trigger(n)}}),Tt.fn.extend({hover:function(t,e){return this.mouseenter(t).mouseleave(e||t)}}),Tt.fn.extend({bind:function(t,e,n){return this.on(t,null,e,n)},unbind:function(t,e){return this.off(t,null,e)},delegate:function(t,e,n,r){return this.on(e,t,n,r)},undelegate:function(t,e,n){return 1===arguments.length?this.off(t,"**"):this.off(e,t||"**",n)}}),Tt.proxy=function(t,e){var n,r,i;return"string"==typeof e&&(n=t[e],e=t,t=n),_t(t)?(r=ct.call(arguments,2),(i=function(){return t.apply(e||this,r.concat(ct.call(arguments)))}).guid=t.guid=t.guid||Tt.guid++,i):undefined},Tt.holdReady=function(t){t?Tt.readyWait++:Tt.ready(!0)},Tt.isArray=Array.isArray,Tt.parseJSON=JSON.parse,Tt.nodeName=u,Tt.isFunction=_t,Tt.isWindow=xt,Tt.camelCase=f,Tt.type=m,Tt.now=Date.now,Tt.isNumeric=function(t){var e=Tt.type(t);return("number"===e||"string"===e)&&!isNaN(t-parseFloat(t))},"function"==typeof define&&define.amd&&define("jquery",[],function(){return Tt});var ln=T.jQuery,un=T.$;return Tt.noConflict=function(t){return T.$===Tt&&(T.$=un),t&&T.jQuery===Tt&&(T.jQuery=ln),Tt},t||(T.jQuery=T.$=Tt),Tt}),function(t,e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e():"function"==typeof define&&define.amd?define(e):t.Popper=e()}(this,function(){"use strict";function s(t){return t&&"[object Function]"==={}.toString.call(t)}function _(t,e){if(1!==t.nodeType)return[];var n=t.ownerDocument.defaultView.getComputedStyle(t,null);return e?n[e]:n}function p(t){return"HTML"===t.nodeName?t:t.parentNode||t.host}function g(t){if(!t)return document.body;switch(t.nodeName){case"HTML":case"BODY":return t.ownerDocument.body;case"#document":return t.body}var e=_(t),n=e.overflow,r=e.overflowX,i=e.overflowY;return/(auto|scroll|overlay)/.test(n+i+r)?t:g(p(t))}function m(t){return t&&t.referenceNode?t.referenceNode:t}function y(t){return 11===t?it:10===t?ot:it||ot}function b(t){if(!t)return document.documentElement;for(var e=y(10)?document.body:null,n=t.offsetParent||null;n===e&&t.nextElementSibling;)n=(t=t.nextElementSibling).offsetParent;var r=n&&n.nodeName;return r&&"BODY"!==r&&"HTML"!==r?-1!==["TH","TD","TABLE"].indexOf(n.nodeName)&&"static"===_(n,"position")?b(n):n:t?t.ownerDocument.documentElement:document.documentElement}function l(t){var e=t.nodeName;return"BODY"!==e&&("HTML"===e||b(t.firstElementChild)===t)}function u(t){return null===t.parentNode?t:u(t.parentNode)}function v(t,e){if(!(t&&t.nodeType&&e&&e.nodeType))return document.documentElement;var n=t.compareDocumentPosition(e)&Node.DOCUMENT_POSITION_FOLLOWING,r=n?t:e,i=n?e:t,o=document.createRange();o.setStart(r,0),o.setEnd(i,0);var a=o.commonAncestorContainer;if(t!==a&&e!==a||r.contains(i))return l(a)?a:b(a);var s=u(t);return s.host?v(s.host,e):v(t,u(e).host)}function d(t,e){var n="top"===(1<arguments.length&&void 0!==e?arguments[1]:"top")?"scrollTop":"scrollLeft",r=t.nodeName;if("BODY"!==r&&"HTML"!==r)return t[n];var i=t.ownerDocument.documentElement;return(t.ownerDocument.scrollingElement||i)[n]}function x(t,e,n){var r=2<arguments.length&&void 0!==n&&arguments[2],i=d(e,"top"),o=d(e,"left"),a=r?-1:1;return t.top+=i*a,t.bottom+=i*a,t.left+=o*a,t.right+=o*a,t}function h(t,e){var n="x"===e?"Left":"Top",r="Left"==n?"Right":"Bottom";return parseFloat(t["border"+n+"Width"],10)+parseFloat(t["border"+r+"Width"],10)}function i(t,e,n,r){return tt(e["offset"+t],e["scroll"+t],n["client"+t],n["offset"+t],n["scroll"+t],y(10)?parseInt(n["offset"+t])+parseInt(r["margin"+("Height"===t?"Top":"Left")])+parseInt(r["margin"+("Height"===t?"Bottom":"Right")]):0)}function w(t){var e=t.body,n=t.documentElement,r=y(10)&&getComputedStyle(n);return{height:i("Height",e,n,r),width:i("Width",e,n,r)}}function S(t){return ut({},t,{right:t.left+t.width,bottom:t.top+t.height})}function T(t){var e={};try{if(y(10)){e=t.getBoundingClientRect();var n=d(t,"top"),r=d(t,"left");e.top+=n,e.left+=r,e.bottom+=n,e.right+=r}else e=t.getBoundingClientRect()}catch(_){}var i={left:e.left,top:e.top,width:e.right-e.left,height:e.bottom-e.top},o="HTML"===t.nodeName?w(t.ownerDocument):{},a=o.width||t.clientWidth||i.width,s=o.height||t.clientHeight||i.height,l=t.offsetWidth-a,u=t.offsetHeight-s;if(l||u){var c=_(t);l-=h(c,"x"),u-=h(c,"y"),i.width-=l,i.height-=u}return S(i)}function k(t,e,n){var r=2<arguments.length&&void 0!==n&&arguments[2],i=y(10),o="HTML"===e.nodeName,a=T(t),s=T(e),l=g(t),u=_(e),c=parseFloat(u.borderTopWidth,10),d=parseFloat(u.borderLeftWidth,10);r&&o&&(s.top=tt(s.top,0),s.left=tt(s.left,0));var h=S({top:a.top-s.top-c,left:a.left-s.left-d,width:a.width,height:a.height});if(h.marginTop=0,h.marginLeft=0,!i&&o){var f=parseFloat(u.marginTop,10),p=parseFloat(u.marginLeft,10);h.top-=c-f,h.bottom-=c-f,h.left-=d-p,h.right-=d-p,h.marginTop=f,h.marginLeft=p}return(i&&!r?e.contains(l):e===l&&"BODY"!==l.nodeName)&&(h=x(h,e)),h}function C(t,e){var n=1<arguments.length&&void 0!==e&&arguments[1],r=t.ownerDocument.documentElement,i=k(t,r),o=tt(r.clientWidth,window.innerWidth||0),a=tt(r.clientHeight,window.innerHeight||0),s=n?0:d(r),l=n?0:d(r,"left");return S({top:s-i.top+i.marginTop,left:l-i.left+i.marginLeft,width:o,height:a})}function E(t){var e=t.nodeName;if("BODY"===e||"HTML"===e)return!1;if("fixed"===_(t,"position"))return!0;var n=p(t);return!!n&&E(n)}function D(t){if(!t||!t.parentElement||y())return document.documentElement;for(var e=t.parentElement;e&&"none"===_(e,"transform");)e=e.parentElement;return e||document.documentElement}function f(t,e,n,r,i){var o=4<arguments.length&&void 0!==i&&arguments[4],a={top:0,left:0},s=o?D(t):v(t,m(e));if("viewport"===r)a=C(s,o);else{var l;"scrollParent"===r?"BODY"===(l=g(p(e))).nodeName&&(l=t.ownerDocument.documentElement):l="window"===r?t.ownerDocument.documentElement:r;var u=k(l,s,o);if("HTML"!==l.nodeName||E(s))a=u;else{var c=w(t.ownerDocument),d=c.height,h=c.width;a.top+=u.top-u.marginTop,a.bottom=d+u.top,a.left+=u.left-u.marginLeft,a.right=h+u.left}}var f="number"==typeof(n=n||0);return a.left+=f?n:n.left||0,a.top+=f?n:n.top||0,a.right-=f?n:n.right||0,a.bottom-=f?n:n.bottom||0,a}function A(t){return t.width*t.height}function c(t,e,r,n,i,o){var a=5<arguments.length&&void 0!==o?arguments[5]:0;if(-1===t.indexOf("auto"))return t;var s=f(r,n,a,i),l={top:{width:s.width,height:e.top-s.top},right:{width:s.right-e.right,height:s.height},bottom:{width:s.width,height:s.bottom-e.bottom},left:{width:e.left-s.left,height:s.height}},u=Object.keys(l).map(function(t){return ut({key:t},l[t],{area:A(l[t])})}).sort(function(t,e){return e.area-t.area}),c=u.filter(function(t){var e=t.width,n=t.height;return e>=r.clientWidth&&n>=r.clientHeight}),d=0<c.length?c[0].key:u[0].key,h=t.split("-")[1];return d+(h?"-"+h:"")}function M(t,e,n,r){var i=3<arguments.length&&void 0!==r?arguments[3]:null;return k(n,i?D(e):v(e,m(n)),i)}function O(t){var e=t.ownerDocument.defaultView.getComputedStyle(t),n=parseFloat(e.marginTop||0)+parseFloat(e.marginBottom||0),r=parseFloat(e.marginLeft||0)+parseFloat(e.marginRight||0);return{width:t.offsetWidth+r,height:t.offsetHeight+n}}function I(t){var e={left:"right",right:"left",bottom:"top",top:"bottom"};return t.replace(/left|right|bottom|top/g,function(t){return e[t]})}function P(t,e,n){n=n.split("-")[0];var r=O(t),i={width:r.width,height:r.height},o=-1!==["right","left"].indexOf(n),a=o?"top":"left",s=o?"left":"top",l=o?"height":"width",u=o?"width":"height";return i[a]=e[a]+e[l]/2-r[l]/2,i[s]=n===s?e[s]-r[u]:e[I(s)],i}function L(t,e){return Array.prototype.find?t.find(e):t.filter(e)[0]}function r(t,e,n){if(Array.prototype.findIndex)return t.findIndex(function(t){return t[e]===n});var r=L(t,function(t){return t[e]===n});return t.indexOf(r)}function N(t,n,e){return(void 0===e?t:t.slice(0,r(t,"name",e))).forEach(function(t){t["function"]&&console.warn("`modifier.function` is deprecated, use `modifier.fn`!");var e=t["function"]||t.fn;t.enabled&&s(e)&&(n.offsets.popper=S(n.offsets.popper),n.offsets.reference=S(n.offsets.reference),
n=e(n,t))}),n}function t(){if(!this.state.isDestroyed){var t={instance:this,styles:{},arrowStyles:{},attributes:{},flipped:!1,offsets:{}};t.offsets.reference=M(this.state,this.popper,this.reference,this.options.positionFixed),t.placement=c(this.options.placement,t.offsets.reference,this.popper,this.reference,this.options.modifiers.flip.boundariesElement,this.options.modifiers.flip.padding),t.originalPlacement=t.placement,t.positionFixed=this.options.positionFixed,t.offsets.popper=P(this.popper,t.offsets.reference,t.placement),t.offsets.popper.position=this.options.positionFixed?"fixed":"absolute",t=N(this.modifiers,t),this.state.isCreated?this.options.onUpdate(t):(this.state.isCreated=!0,this.options.onCreate(t))}}function e(t,n){return t.some(function(t){var e=t.name;return t.enabled&&e===n})}function R(t){for(var e=[!1,"ms","Webkit","Moz","O"],n=t.charAt(0).toUpperCase()+t.slice(1),r=0;r<e.length;r++){var i=e[r],o=i?""+i+n:t;if("undefined"!=typeof document.body.style[o])return o}return null}function n(){return this.state.isDestroyed=!0,e(this.modifiers,"applyStyle")&&(this.popper.removeAttribute("x-placement"),this.popper.style.position="",this.popper.style.top="",this.popper.style.left="",this.popper.style.right="",this.popper.style.bottom="",this.popper.style.willChange="",this.popper.style[R("transform")]=""),this.disableEventListeners(),this.options.removeOnDestroy&&this.popper.parentNode.removeChild(this.popper),this}function o(t){var e=t.ownerDocument;return e?e.defaultView:window}function a(t,e,n,r){var i="BODY"===t.nodeName,o=i?t.ownerDocument.defaultView:t;o.addEventListener(e,n,{passive:!0}),i||a(g(o.parentNode),e,n,r),r.push(o)}function F(t,e,n,r){n.updateBound=r,o(t).addEventListener("resize",n.updateBound,{passive:!0});var i=g(t);return a(i,"scroll",n.updateBound,n.scrollParents),n.scrollElement=i,n.eventsEnabled=!0,n}function H(){this.state.eventsEnabled||(this.state=F(this.reference,this.options,this.state,this.scheduleUpdate))}function j(t,e){return o(t).removeEventListener("resize",e.updateBound),e.scrollParents.forEach(function(t){t.removeEventListener("scroll",e.updateBound)}),e.updateBound=null,e.scrollParents=[],e.scrollElement=null,e.eventsEnabled=!1,e}function W(){this.state.eventsEnabled&&(cancelAnimationFrame(this.scheduleUpdate),this.state=j(this.reference,this.state))}function z(t){return""!==t&&!isNaN(parseFloat(t))&&isFinite(t)}function B(n,r){Object.keys(r).forEach(function(t){var e="";-1!==["width","height","top","right","bottom","left"].indexOf(t)&&z(r[t])&&(e="px"),n.style[t]=r[t]+e})}function V(e,n){Object.keys(n).forEach(function(t){!1===n[t]?e.removeAttribute(t):e.setAttribute(t,n[t])})}function q(t,e){var n=t.offsets,r=n.popper,i=n.reference,o=J,a=function(t){return t},s=o(i.width),l=o(r.width),u=-1!==["left","right"].indexOf(t.placement),c=-1!==t.placement.indexOf("-"),d=e?u||c||s%2==l%2?o:Z:a,h=e?o:a;return{left:d(1==s%2&&1==l%2&&!c&&e?r.left-1:r.left),top:h(r.top),bottom:h(r.bottom),right:d(r.right)}}function U(t,e,n){var r=L(t,function(t){return t.name===e}),i=!!r&&t.some(function(t){return t.name===n&&t.enabled&&t.order<r.order});if(!i){var o="`"+e+"`";console.warn("`"+n+"` modifier is required by "+o+" modifier in order to work, be sure to include it before "+o+"!")}return i}function Y(t){return"end"===t?"start":"start"===t?"end":t}function G(t,e){var n=1<arguments.length&&void 0!==e&&arguments[1],r=ht.indexOf(t),i=ht.slice(r+1).concat(ht.slice(0,r));return n?i.reverse():i}function K(t,e,n,r){var i,o=t.match(/((?:\-|\+)?\d*\.?\d*)(.*)/),a=+o[1],s=o[2];if(!a)return t;if(0!==s.indexOf("%"))return"vh"!==s&&"vw"!==s?a:("vh"===s?tt(document.documentElement.clientHeight,window.innerHeight||0):tt(document.documentElement.clientWidth,window.innerWidth||0))/100*a;switch(s){case"%p":i=n;break;case"%":case"%r":default:i=r}return S(i)[e]/100*a}function X(t,i,o,e){var a=[0,0],s=-1!==["right","left"].indexOf(e),n=t.split(/(\+|\-)/).map(function(t){return t.trim()}),r=n.indexOf(L(n,function(t){return-1!==t.search(/,|\s/)}));n[r]&&-1===n[r].indexOf(",")&&console.warn("Offsets separated by white space(s) are deprecated, use a comma (,) instead.");var l=/\s*,\s*|\s+/,u=-1===r?[n]:[n.slice(0,r).concat([n[r].split(l)[0]]),[n[r].split(l)[1]].concat(n.slice(r+1))];return(u=u.map(function(t,e){var n=(1===e?!s:s)?"height":"width",r=!1;return t.reduce(function(t,e){return""===t[t.length-1]&&-1!==["+","-"].indexOf(e)?(t[t.length-1]=e,r=!0,t):r?(t[t.length-1]+=e,r=!1,t):t.concat(e)},[]).map(function(t){return K(t,n,i,o)})})).forEach(function(n,r){n.forEach(function(t,e){z(t)&&(a[r]+=t*("-"===n[e-1]?-1:1))})}),a}function Q(t,e){var n,r=e.offset,i=t.placement,o=t.offsets,a=o.popper,s=o.reference,l=i.split("-")[0];return n=z(+r)?[+r,0]:X(r,a,s,l),"left"===l?(a.top+=n[0],a.left-=n[1]):"right"===l?(a.top+=n[0],a.left+=n[1]):"top"===l?(a.left+=n[0],a.top-=n[1]):"bottom"===l&&(a.left+=n[0],a.top+=n[1]),t.popper=a,t}var $=Math.min,Z=Math.floor,J=Math.round,tt=Math.max,et="undefined"!=typeof window&&"undefined"!=typeof document&&"undefined"!=typeof navigator,nt=function(){for(var t=["Edge","Trident","Firefox"],e=0;e<t.length;e+=1)if(et&&0<=navigator.userAgent.indexOf(t[e]))return 1;return 0}(),rt=et&&window.Promise?function(t){var e=!1;return function(){e||(e=!0,window.Promise.resolve().then(function(){e=!1,t()}))}}:function(t){var e=!1;return function(){e||(e=!0,setTimeout(function(){e=!1,t()},nt))}},it=et&&!(!window.MSInputMethodContext||!document.documentMode),ot=et&&/MSIE 10/.test(navigator.userAgent),at=function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")},st=function(){function r(t,e){for(var n,r=0;r<e.length;r++)(n=e[r]).enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}return function(t,e,n){return e&&r(t.prototype,e),n&&r(t,n),t}}(),lt=function(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t},ut=Object.assign||function(t){for(var e,n=1;n<arguments.length;n++)for(var r in e=arguments[n])Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t},ct=et&&/Firefox/i.test(navigator.userAgent),dt=["auto-start","auto","auto-end","top-start","top","top-end","right-start","right","right-end","bottom-end","bottom","bottom-start","left-end","left","left-start"],ht=dt.slice(3),ft={FLIP:"flip",CLOCKWISE:"clockwise",COUNTERCLOCKWISE:"counterclockwise"},pt=function(){function a(t,e,n){var r=this,i=2<arguments.length&&void 0!==n?arguments[2]:{};at(this,a),this.scheduleUpdate=function(){return requestAnimationFrame(r.update)},this.update=rt(this.update.bind(this)),this.options=ut({},a.Defaults,i),this.state={isDestroyed:!1,isCreated:!1,scrollParents:[]},this.reference=t&&t.jquery?t[0]:t,this.popper=e&&e.jquery?e[0]:e,this.options.modifiers={},Object.keys(ut({},a.Defaults.modifiers,i.modifiers)).forEach(function(t){r.options.modifiers[t]=ut({},a.Defaults.modifiers[t]||{},i.modifiers?i.modifiers[t]:{})}),this.modifiers=Object.keys(this.options.modifiers).map(function(t){return ut({name:t},r.options.modifiers[t])}).sort(function(t,e){return t.order-e.order}),this.modifiers.forEach(function(t){t.enabled&&s(t.onLoad)&&t.onLoad(r.reference,r.popper,r.options,t,r.state)}),this.update();var o=this.options.eventsEnabled;o&&this.enableEventListeners(),this.state.eventsEnabled=o}return st(a,[{key:"update",value:function(){return t.call(this)}},{key:"destroy",value:function(){return n.call(this)}},{key:"enableEventListeners",value:function(){return H.call(this)}},{key:"disableEventListeners",value:function(){return W.call(this)}}]),a}();return pt.Utils=("undefined"==typeof window?global:window).PopperUtils,pt.placements=dt,pt.Defaults={placement:"bottom",positionFixed:!1,eventsEnabled:!0,removeOnDestroy:!1,onCreate:function(){},onUpdate:function(){},modifiers:{shift:{order:100,enabled:!0,fn:function(t){var e=t.placement,n=e.split("-")[0],r=e.split("-")[1];if(r){var i=t.offsets,o=i.reference,a=i.popper,s=-1!==["bottom","top"].indexOf(n),l=s?"left":"top",u=s?"width":"height",c={start:lt({},l,o[l]),end:lt({},l,o[l]+o[u]-a[u])};t.offsets.popper=ut({},a,c[r])}return t}},offset:{order:200,enabled:!0,fn:Q,offset:0},preventOverflow:{order:300,enabled:!0,fn:function(t,r){var e=r.boundariesElement||b(t.instance.popper);t.instance.reference===e&&(e=b(e));var n=R("transform"),i=t.instance.popper.style,o=i.top,a=i.left,s=i[n];i.top="",i.left="",i[n]="";var l=f(t.instance.popper,t.instance.reference,r.padding,e,t.positionFixed);i.top=o,i.left=a,i[n]=s,r.boundaries=l;var u=r.priority,c=t.offsets.popper,d={primary:function(t){var e=c[t];return c[t]<l[t]&&!r.escapeWithReference&&(e=tt(c[t],l[t])),lt({},t,e)},secondary:function(t){var e="right"===t?"left":"top",n=c[e];return c[t]>l[t]&&!r.escapeWithReference&&(n=$(c[e],l[t]-("right"===t?c.width:c.height))),lt({},e,n)}};return u.forEach(function(t){var e=-1===["left","top"].indexOf(t)?"secondary":"primary";c=ut({},c,d[e](t))}),t.offsets.popper=c,t},priority:["left","right","top","bottom"],padding:5,boundariesElement:"scrollParent"},keepTogether:{order:400,enabled:!0,fn:function(t){var e=t.offsets,n=e.popper,r=e.reference,i=t.placement.split("-")[0],o=Z,a=-1!==["top","bottom"].indexOf(i),s=a?"right":"bottom",l=a?"left":"top",u=a?"width":"height";return n[s]<o(r[l])&&(t.offsets.popper[l]=o(r[l])-n[u]),n[l]>o(r[s])&&(t.offsets.popper[l]=o(r[s])),t}},arrow:{order:500,enabled:!0,fn:function(t,e){var n;if(!U(t.instance.modifiers,"arrow","keepTogether"))return t;var r=e.element;if("string"==typeof r){if(!(r=t.instance.popper.querySelector(r)))return t}else if(!t.instance.popper.contains(r))return console.warn("WARNING: `arrow.element` must be child of its popper element!"),t;var i=t.placement.split("-")[0],o=t.offsets,a=o.popper,s=o.reference,l=-1!==["left","right"].indexOf(i),u=l?"height":"width",c=l?"Top":"Left",d=c.toLowerCase(),h=l?"left":"top",f=l?"bottom":"right",p=O(r)[u];s[f]-p<a[d]&&(t.offsets.popper[d]-=a[d]-(s[f]-p)),s[d]+p>a[f]&&(t.offsets.popper[d]+=s[d]+p-a[f]),t.offsets.popper=S(t.offsets.popper);var g=s[d]+s[u]/2-p/2,m=_(t.instance.popper),y=parseFloat(m["margin"+c],10),v=parseFloat(m["border"+c+"Width"],10),b=g-t.offsets.popper[d]-y-v;return b=tt($(a[u]-p,b),0),t.arrowElement=r,t.offsets.arrow=(lt(n={},d,J(b)),lt(n,h,""),n),t},element:"[x-arrow]"},flip:{order:600,enabled:!0,fn:function(g,m){if(e(g.instance.modifiers,"inner"))return g;if(g.flipped&&g.placement===g.originalPlacement)return g;var y=f(g.instance.popper,g.instance.reference,m.padding,m.boundariesElement,g.positionFixed),v=g.placement.split("-")[0],b=I(v),_=g.placement.split("-")[1]||"",x=[];switch(m.behavior){case ft.FLIP:x=[v,b];break;case ft.CLOCKWISE:x=G(v);break;case ft.COUNTERCLOCKWISE:x=G(v,!0);break;default:x=m.behavior}return x.forEach(function(t,e){if(v!==t||x.length===e+1)return g;v=g.placement.split("-")[0],b=I(v);var n=g.offsets.popper,r=g.offsets.reference,i=Z,o="left"===v&&i(n.right)>i(r.left)||"right"===v&&i(n.left)<i(r.right)||"top"===v&&i(n.bottom)>i(r.top)||"bottom"===v&&i(n.top)<i(r.bottom),a=i(n.left)<i(y.left),s=i(n.right)>i(y.right),l=i(n.top)<i(y.top),u=i(n.bottom)>i(y.bottom),c="left"===v&&a||"right"===v&&s||"top"===v&&l||"bottom"===v&&u,d=-1!==["top","bottom"].indexOf(v),h=!!m.flipVariations&&(d&&"start"===_&&a||d&&"end"===_&&s||!d&&"start"===_&&l||!d&&"end"===_&&u),f=!!m.flipVariationsByContent&&(d&&"start"===_&&s||d&&"end"===_&&a||!d&&"start"===_&&u||!d&&"end"===_&&l),p=h||f;(o||c||p)&&(g.flipped=!0,(o||c)&&(v=x[e+1]),p&&(_=Y(_)),g.placement=v+(_?"-"+_:""),g.offsets.popper=ut({},g.offsets.popper,P(g.instance.popper,g.offsets.reference,g.placement)),g=N(g.instance.modifiers,g,"flip"))}),g},behavior:"flip",padding:5,boundariesElement:"viewport",flipVariations:!1,flipVariationsByContent:!1},inner:{order:700,enabled:!1,fn:function(t){var e=t.placement,n=e.split("-")[0],r=t.offsets,i=r.popper,o=r.reference,a=-1!==["left","right"].indexOf(n),s=-1===["top","left"].indexOf(n);return i[a?"left":"top"]=o[n]-(s?i[a?"width":"height"]:0),t.placement=I(e),t.offsets.popper=S(i),t}},hide:{order:800,enabled:!0,fn:function(t){if(!U(t.instance.modifiers,"hide","preventOverflow"))return t;var e=t.offsets.reference,n=L(t.instance.modifiers,function(t){return"preventOverflow"===t.name}).boundaries;if(e.bottom<n.top||e.left>n.right||e.top>n.bottom||e.right<n.left){if(!0===t.hide)return t;t.hide=!0,t.attributes["x-out-of-boundaries"]=""}else{if(!1===t.hide)return t;t.hide=!1,t.attributes["x-out-of-boundaries"]=!1}return t}},computeStyle:{order:850,enabled:!0,fn:function(t,e){var n=e.x,r=e.y,i=t.offsets.popper,o=L(t.instance.modifiers,function(t){return"applyStyle"===t.name}).gpuAcceleration;void 0!==o&&console.warn("WARNING: `gpuAcceleration` option moved to `computeStyle` modifier and will not be supported in future versions of Popper.js!");var a,s,l=void 0===o?e.gpuAcceleration:o,u=b(t.instance.popper),c=T(u),d={position:i.position},h=q(t,window.devicePixelRatio<2||!ct),f="bottom"===n?"top":"bottom",p="right"===r?"left":"right",g=R("transform");if(s="bottom"==f?"HTML"===u.nodeName?-u.clientHeight+h.bottom:-c.height+h.bottom:h.top,a="right"==p?"HTML"===u.nodeName?-u.clientWidth+h.right:-c.width+h.right:h.left,l&&g)d[g]="translate3d("+a+"px, "+s+"px, 0)",d[f]=0,d[p]=0,d.willChange="transform";else{var m="bottom"==f?-1:1,y="right"==p?-1:1;d[f]=s*m,d[p]=a*y,d.willChange=f+", "+p}var v={"x-placement":t.placement};return t.attributes=ut({},v,t.attributes),t.styles=ut({},d,t.styles),t.arrowStyles=ut({},t.offsets.arrow,t.arrowStyles),t},gpuAcceleration:!0,x:"bottom",y:"right"},applyStyle:{order:900,enabled:!0,fn:function(t){return B(t.instance.popper,t.styles),V(t.instance.popper,t.attributes),t.arrowElement&&Object.keys(t.arrowStyles).length&&B(t.arrowElement,t.arrowStyles),t},onLoad:function(t,e,n,r,i){var o=M(i,e,t,n.positionFixed),a=c(n.placement,o,e,t,n.modifiers.flip.boundariesElement,n.modifiers.flip.padding);return e.setAttribute("x-placement",a),B(e,{position:n.positionFixed?"fixed":"absolute"}),n},gpuAcceleration:void 0}}},pt}),function(t,e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e(require("jquery")):"function"==typeof define&&define.amd?define(["jquery"],e):(t=t||self).Util=e(t.jQuery)}(this,function(o){"use strict";function s(t){return{}.toString.call(t).match(/\s([a-z]+)/i)[1].toLowerCase()}function t(){return{bindType:r,delegateType:r,handle:function e(t){return o(t.target).is(this)?t.handleObj.handler.apply(this,arguments):undefined}}}function e(t){var e=this,n=!1;return o(this).one(l.TRANSITION_END,function(){n=!0}),setTimeout(function(){n||l.triggerTransitionEnd(e)},t),this}function n(){o.fn.emulateTransitionEnd=e,o.event.special[l.TRANSITION_END]=t()}o=o&&o.hasOwnProperty("default")?o["default"]:o;var r="transitionend",i=1e6,a=1e3,l={TRANSITION_END:"bsTransitionEnd",getUID:function u(t){for(;t+=~~(Math.random()*i),document.getElementById(t););return t},getSelectorFromElement:function c(t){var e=t.getAttribute("data-target");if(!e||"#"===e){var n=t.getAttribute("href");e=n&&"#"!==n?n.trim():""}try{return document.querySelector(e)?e:null}catch(r){return null}},getTransitionDurationFromElement:function d(t){if(!t)return 0;var e=o(t).css("transition-duration"),n=o(t).css("transition-delay"),r=parseFloat(e),i=parseFloat(n);return r||i?(e=e.split(",")[0],n=n.split(",")[0],(parseFloat(e)+parseFloat(n))*a):0},reflow:function h(t){return t.offsetHeight},triggerTransitionEnd:function f(t){o(t).trigger(r)},supportsTransitionEnd:function p(){return Boolean(r)},isElement:function g(t){return(t[0]||t).nodeType},typeCheckConfig:function m(t,e,n){for(var r in n)if(Object.prototype.hasOwnProperty.call(n,r)){var i=n[r],o=e[r],a=o&&l.isElement(o)?"element":s(o);if(!new RegExp(i).test(a))throw new Error(t.toUpperCase()+': Option "'+r+'" provided type "'+a+'" but expected type "'+i+'".')}},findShadowRoot:function y(t){if(!document.documentElement.attachShadow)return null;if("function"!=typeof t.getRootNode)return t instanceof ShadowRoot?t:t.parentNode?l.findShadowRoot(t.parentNode):null;var e=t.getRootNode();return e instanceof ShadowRoot?e:null}};return n(),l}),function(t,e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e(require("jquery"),require("./util.js")):"function"==typeof define&&define.amd?define(["jquery","./util.js"],e):(t=t||self).Alert=e(t.jQuery,t.Util)}(this,function(d,h){"use strict";function r(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}function f(t,e,n){return e&&r(t.prototype,e),n&&r(t,n),t}d=d&&d.hasOwnProperty("default")?d["default"]:d,h=h&&h.hasOwnProperty("default")?h["default"]:h;var t="alert",p="4.3.1",g="bs.alert",e="."+g,n=".data-api",i=d.fn[t],o={DISMISS:'[data-dismiss="alert"]'},m={CLOSE:"close"+e,CLOSED:"closed"+e,CLICK_DATA_API:"click"+e+n},y={ALERT:"alert",FADE:"fade",SHOW:"show"},a=function(){function r(t){this._element=t}var t=r.prototype;return t.close=function n(t){var e=this._element;t&&(e=this._getRootElement(t)),this._triggerCloseEvent(e).isDefaultPrevented()||this._removeElement(e)},t.dispose=function e(){d.removeData(this._element,g),this._element=null},t._getRootElement=function i(t){var e=h.getSelectorFromElement(t),n=!1;return e&&(n=document.querySelector(e)),n||(n=d(t).closest("."+y.ALERT)[0]),n},t._triggerCloseEvent=function o(t){var e=d.Event(m.CLOSE);return d(t).trigger(e),e},t._removeElement=function a(e){var n=this;if(d(e).removeClass(y.SHOW),d(e).hasClass(y.FADE)){var t=h.getTransitionDurationFromElement(e);d(e).one(h.TRANSITION_END,function(t){return n._destroyElement(e,t)}).emulateTransitionEnd(t)}else this._destroyElement(e)},t._destroyElement=function s(t){d(t).detach().trigger(m.CLOSED).remove()},r._jQueryInterface=function l(n){return this.each(function(){var t=d(this),e=t.data(g);e||(e=new r(this),t.data(g,e)),"close"===n&&e[n](this)})},r._handleDismiss=function u(e){return function(t){t&&t.preventDefault(),e.close(this)}},f(r,null,[{key:"VERSION",get:function c(){return p}}]),r}();return d(document).on(m.CLICK_DATA_API,o.DISMISS,a._handleDismiss(new a)),d.fn[t]=a._jQueryInterface,d.fn[t].Constructor=a,d.fn[t].noConflict=function(){return d.fn[t]=i,a._jQueryInterface},a}),function(t,e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e(require("jquery")):"function"==typeof define&&define.amd?define(["jquery"],e):(t=t||self).Button=e(t.jQuery)}(this,function(a){"use strict";function r(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}function s(t,e,n){return e&&r(t.prototype,e),n&&r(t,n),t}a=a&&a.hasOwnProperty("default")?a["default"]:a;var t="button",l="4.3.1",u="bs.button",e="."+u,n=".data-api",i=a.fn[t],c={ACTIVE:"active",BUTTON:"btn",FOCUS:"focus"},d={DATA_TOGGLE_CARROT:'[data-toggle^="button"]',DATA_TOGGLE:'[data-toggle="buttons"]',INPUT:'input:not([type="hidden"])',ACTIVE:".active",BUTTON:".btn"},o={CLICK_DATA_API:"click"+e+n,FOCUS_BLUR_DATA_API:"focus"+e+n+" blur"+e+n},h=function(){function n(t){this._element=t}var t=n.prototype;return t.toggle=function o(){var t=!0,e=!0,n=a(this._element).closest(d.DATA_TOGGLE)[0];if(n){var r=this._element.querySelector(d.INPUT);if(r){if("radio"===r.type)if(r.checked&&this._element.classList.contains(c.ACTIVE))t=!1;else{var i=n.querySelector(d.ACTIVE);i&&a(i).removeClass(c.ACTIVE)}if(t){if(r.hasAttribute("disabled")||n.hasAttribute("disabled")||r.classList.contains("disabled")||n.classList.contains("disabled"))return;r.checked=!this._element.classList.contains(c.ACTIVE),a(r).trigger("change")}r.focus(),e=!1}}e&&this._element.setAttribute("aria-pressed",!this._element.classList.contains(c.ACTIVE)),t&&a(this._element).toggleClass(c.ACTIVE)},t.dispose=function e(){a.removeData(this._element,u),this._element=null},n._jQueryInterface=function r(e){return this.each(function(){var t=a(this).data(u);t||(t=new n(this),a(this).data(u,t)),"toggle"===e&&t[e]()})},s(n,null,[{key:"VERSION",get:function i(){return l}}]),n}();return a(document).on(o.CLICK_DATA_API,d.DATA_TOGGLE_CARROT,function(t){t.preventDefault();var e=t.target;a(e).hasClass(c.BUTTON)||(e=a(e).closest(d.BUTTON)),h._jQueryInterface.call(a(e),"toggle")}).on(o.FOCUS_BLUR_DATA_API,d.DATA_TOGGLE_CARROT,function(t){var e=a(t.target).closest(d.BUTTON)[0];a(e).toggleClass(c.FOCUS,/^focus(in)?$/.test(t.type))}),a.fn[t]=h._jQueryInterface,a.fn[t].Constructor=h,a.fn[t].noConflict=function(){return a.fn[t]=i,h._jQueryInterface},h}),function(t,e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e(require("jquery"),require("./util.js")):"function"==typeof define&&define.amd?define(["jquery","./util.js"],e):(t=t||self).Carousel=e(t.jQuery,t.Util)}(this,function(w,S){"use strict";function r(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}function T(t,e,n){return e&&r(t.prototype,e),n&&r(t,n),t}function i(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function k(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},r=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(n).filter(function(t){return Object.getOwnPropertyDescriptor(n,t).enumerable}))),r.forEach(function(t){i(e,t,n[t])})}return e}w=w&&w.hasOwnProperty("default")?w["default"]:w,S=S&&S.hasOwnProperty("default")?S["default"]:S;var C="carousel",E="4.3.1",D="bs.carousel",A="."+D,t=".data-api",e=w.fn[C],M=37,O=39,I=500,P=40,L={interval:5e3,keyboard:!0,slide:!1,pause:"hover",wrap:!0,touch:!0},N={interval:"(number|boolean)",keyboard:"boolean",slide:"(boolean|string)",pause:"(string|boolean)",wrap:"boolean",touch:"boolean"},R={NEXT:"next",PREV:"prev",LEFT:"left",RIGHT:"right"},F={SLIDE:"slide"+A,SLID:"slid"+A,KEYDOWN:"keydown"+A,MOUSEENTER:"mouseenter"+A,MOUSELEAVE:"mouseleave"+A,TOUCHSTART:"touchstart"+A,TOUCHMOVE:"touchmove"+A,TOUCHEND:"touchend"+A,POINTERDOWN:"pointerdown"+A,POINTERUP:"pointerup"+A,DRAG_START:"dragstart"+A,LOAD_DATA_API:"load"+A+t,CLICK_DATA_API:"click"+A+t},H={CAROUSEL:"carousel",ACTIVE:"active",SLIDE:"slide",RIGHT:"carousel-item-right",LEFT:"carousel-item-left",NEXT:"carousel-item-next",PREV:"carousel-item-prev",ITEM:"carousel-item",POINTER_EVENT:"pointer-event"},j={ACTIVE:".active",ACTIVE_ITEM:".active.carousel-item",ITEM:".carousel-item",ITEM_IMG:".carousel-item img",NEXT_PREV:".carousel-item-next, .carousel-item-prev",INDICATORS:".carousel-indicators",DATA_SLIDE:"[data-slide], [data-slide-to]",DATA_RIDE:'[data-ride="carousel"]'},W={TOUCH:"touch",PEN:"pen"},o=function(){function o(t,e){this._items=null,this._interval=null,this._activeElement=null,this._isPaused=!1,this._isSliding=!1,this.touchTimeout=null,this.touchStartX=0,this.touchDeltaX=0,this._config=this._getConfig(e),this._element=t,this._indicatorsElement=this._element.querySelector(j.INDICATORS),this._touchSupported="ontouchstart"in document.documentElement||0<navigator.maxTouchPoints,this._pointerEvent=Boolean(window.PointerEvent||window.MSPointerEvent),this._addEventListeners()}var t=o.prototype;return t.next=function e(){this._isSliding||this._slide(R.NEXT)},t.nextWhenVisible=function n(){!document.hidden&&w(this._element).is(":visible")&&"hidden"!==w(this._element).css("visibility")&&this.next()},t.prev=function r(){this._isSliding||this._slide(R.PREV)},t.pause=function i(t){t||(this._isPaused=!0),this._element.querySelector(j.NEXT_PREV)&&(S.triggerTransitionEnd(this._element),this.cycle(!0)),clearInterval(this._interval),this._interval=null},t.cycle=function a(t){t||(this._isPaused=!1),this._interval&&(clearInterval(this._interval),this._interval=null),this._config.interval&&!this._isPaused&&(this._interval=setInterval((document.visibilityState?this.nextWhenVisible:this.next).bind(this),this._config.interval))},t.to=function s(t){var e=this;this._activeElement=this._element.querySelector(j.ACTIVE_ITEM);var n=this._getItemIndex(this._activeElement);if(!(t>this._items.length-1||t<0))if(this._isSliding)w(this._element).one(F.SLID,function(){return e.to(t)});else{if(n===t)return this.pause(),void this.cycle();var r=n<t?R.NEXT:R.PREV;this._slide(r,this._items[t])}},t.dispose=function l(){w(this._element).off(A),w.removeData(this._element,D),this._items=null,this._config=null,this._element=null,this._interval=null,this._isPaused=null,this._isSliding=null,this._activeElement=null,this._indicatorsElement=null},t._getConfig=function u(t){return t=k({},L,t),S.typeCheckConfig(C,t,N),t},t._handleSwipe=function c(){var t=Math.abs(this.touchDeltaX);if(!(t<=P)){var e=t/this.touchDeltaX;0<e&&this.prev(),e<0&&this.next()}},t._addEventListeners=function d(){var e=this;this._config.keyboard&&w(this._element).on(F.KEYDOWN,function(t){return e._keydown(t)}),"hover"===this._config.pause&&w(this._element).on(F.MOUSEENTER,function(t){return e.pause(t)}).on(F.MOUSELEAVE,function(t){return e.cycle(t)}),this._config.touch&&this._addTouchEventListeners()},t._addTouchEventListeners=function h(){var e=this;if(this._touchSupported){var n=function n(t){e._pointerEvent&&W[t.originalEvent.pointerType.toUpperCase()]?e.touchStartX=t.originalEvent.clientX:e._pointerEvent||(e.touchStartX=t.originalEvent.touches[0].clientX)},r=function r(t){t.originalEvent.touches&&1<t.originalEvent.touches.length?e.touchDeltaX=0:e.touchDeltaX=t.originalEvent.touches[0].clientX-e.touchStartX},i=function i(t){e._pointerEvent&&W[t.originalEvent.pointerType.toUpperCase()]&&(e.touchDeltaX=t.originalEvent.clientX-e.touchStartX),e._handleSwipe(),"hover"===e._config.pause&&(e.pause(),e.touchTimeout&&clearTimeout(e.touchTimeout),e.touchTimeout=setTimeout(function(t){return e.cycle(t)},I+e._config.interval))};w(this._element.querySelectorAll(j.ITEM_IMG)).on(F.DRAG_START,function(t){return t.preventDefault()}),this._pointerEvent?(w(this._element).on(F.POINTERDOWN,function(t){return n(t)}),w(this._element).on(F.POINTERUP,function(t){return i(t)}),this._element.classList.add(H.POINTER_EVENT)):(w(this._element).on(F.TOUCHSTART,function(t){return n(t)}),w(this._element).on(F.TOUCHMOVE,function(t){return r(t)}),w(this._element).on(F.TOUCHEND,function(t){return i(t)}))}},t._keydown=function f(t){if(!/input|textarea/i.test(t.target.tagName))switch(t.which){case M:t.preventDefault(),this.prev();break;case O:t.preventDefault(),this.next()}},t._getItemIndex=function p(t){return this._items=t&&t.parentNode?[].slice.call(t.parentNode.querySelectorAll(j.ITEM)):[],this._items.indexOf(t)},t._getItemByDirection=function g(t,e){var n=t===R.NEXT,r=t===R.PREV,i=this._getItemIndex(e),o=this._items.length-1;if((r&&0===i||n&&i===o)&&!this._config.wrap)return e;var a=(i+(t===R.PREV?-1:1))%this._items.length;return-1===a?this._items[this._items.length-1]:this._items[a]},t._triggerSlideEvent=function m(t,e){var n=this._getItemIndex(t),r=this._getItemIndex(this._element.querySelector(j.ACTIVE_ITEM)),i=w.Event(F.SLIDE,{relatedTarget:t,direction:e,from:r,to:n});return w(this._element).trigger(i),i},t._setActiveIndicatorElement=function y(t){if(this._indicatorsElement){var e=[].slice.call(this._indicatorsElement.querySelectorAll(j.ACTIVE));w(e).removeClass(H.ACTIVE);var n=this._indicatorsElement.children[this._getItemIndex(t)];n&&w(n).addClass(H.ACTIVE)}},t._slide=function v(t,e){var n,r,i,o=this,a=this._element.querySelector(j.ACTIVE_ITEM),s=this._getItemIndex(a),l=e||a&&this._getItemByDirection(t,a),u=this._getItemIndex(l),c=Boolean(this._interval);if(t===R.NEXT?(n=H.LEFT,r=H.NEXT,i=R.LEFT):(n=H.RIGHT,r=H.PREV,i=R.RIGHT),l&&w(l).hasClass(H.ACTIVE))this._isSliding=!1;else if(!this._triggerSlideEvent(l,i).isDefaultPrevented()&&a&&l){this._isSliding=!0,c&&this.pause(),this._setActiveIndicatorElement(l);var d=w.Event(F.SLID,{relatedTarget:l,direction:i,from:s,to:u});if(w(this._element).hasClass(H.SLIDE)){w(l).addClass(r),S.reflow(l),w(a).addClass(n),w(l).addClass(n);var h=parseInt(l.getAttribute("data-interval"),10);h?(this._config.defaultInterval=this._config.defaultInterval||this._config.interval,this._config.interval=h):this._config.interval=this._config.defaultInterval||this._config.interval;var f=S.getTransitionDurationFromElement(a);w(a).one(S.TRANSITION_END,function(){w(l).removeClass(n+" "+r).addClass(H.ACTIVE),w(a).removeClass(H.ACTIVE+" "+r+" "+n),o._isSliding=!1,setTimeout(function(){return w(o._element).trigger(d)},0)}).emulateTransitionEnd(f)}else w(a).removeClass(H.ACTIVE),w(l).addClass(H.ACTIVE),this._isSliding=!1,w(this._element).trigger(d);c&&this.cycle()}},o._jQueryInterface=function b(r){return this.each(function(){var t=w(this).data(D),e=k({},L,w(this).data());"object"==typeof r&&(e=k({},e,r));var n="string"==typeof r?r:e.slide;if(t||(t=new o(this,e),w(this).data(D,t)),"number"==typeof r)t.to(r);else if("string"==typeof n){if("undefined"==typeof t[n])throw new TypeError('No method named "'+n+'"');t[n]()}else e.interval&&e.ride&&(t.pause(),t.cycle())})},o._dataApiClickHandler=function _(t){var e=S.getSelectorFromElement(this);if(e){var n=w(e)[0];if(n&&w(n).hasClass(H.CAROUSEL)){var r=k({},w(n).data(),w(this).data()),i=this.getAttribute("data-slide-to");i&&(r.interval=!1),o._jQueryInterface.call(w(n),r),i&&w(n).data(D).to(i),t.preventDefault()}}},T(o,null,[{key:"VERSION",get:function x(){return E}},{key:"Default",get:function x(){return L}}]),o}();return w(document).on(F.CLICK_DATA_API,j.DATA_SLIDE,o._dataApiClickHandler),w(window).on(F.LOAD_DATA_API,function(){for(var t=[].slice.call(document.querySelectorAll(j.DATA_RIDE)),e=0,n=t.length;e<n;e++){var r=w(t[e]);o._jQueryInterface.call(r,r.data())}}),w.fn[C]=o._jQueryInterface,w.fn[C].Constructor=o,w.fn[C].noConflict=function(){return w.fn[C]=e,o._jQueryInterface},o}),function(t,e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e(require("jquery"),require("./util.js")):"function"==typeof define&&define.amd?define(["jquery","./util.js"],e):(t=t||self).Collapse=e(t.jQuery,t.Util)}(this,function(p,g){"use strict";function r(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}function m(t,e,n){return e&&r(t.prototype,e),n&&r(t,n),t}function i(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function y(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},r=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(n).filter(function(t){return Object.getOwnPropertyDescriptor(n,t).enumerable}))),r.forEach(function(t){i(e,t,n[t])})}return e}p=p&&p.hasOwnProperty("default")?p["default"]:p,g=g&&g.hasOwnProperty("default")?g["default"]:g;var v="collapse",b="4.3.1",_="bs.collapse",t="."+_,e=".data-api",n=p.fn[v],x={toggle:!0,parent:""},w={toggle:"boolean",parent:"(string|element)"},S={SHOW:"show"+t,SHOWN:"shown"+t,HIDE:"hide"+t,HIDDEN:"hidden"+t,CLICK_DATA_API:"click"+t+e},T={SHOW:"show",COLLAPSE:"collapse",COLLAPSING:"collapsing",COLLAPSED:"collapsed"},k={WIDTH:"width",HEIGHT:"height"},C={ACTIVES:".show, .collapsing",DATA_TOGGLE:'[data-toggle="collapse"]'},o=function(){function l(e,t){this._isTransitioning=!1,this._element=e,this._config=this._getConfig(t),this._triggerArray=[].slice.call(document.querySelectorAll('[data-toggle="collapse"][href="#'+e.id+'"],[data-toggle="collapse"][data-target="#'+e.id+'"]'));for(var n=[].slice.call(document.querySelectorAll(C.DATA_TOGGLE)),r=0,i=n.length;r<i;r++){var o=n[r],a=g.getSelectorFromElement(o),s=[].slice.call(document.querySelectorAll(a)).filter(function(t){return t===e});null!==a&&0<s.length&&(this._selector=a,this._triggerArray.push(o))}this._parent=this._config.parent?this._getParent():null,this._config.parent||this._addAriaAndCollapsedClass(this._element,this._triggerArray),this._config.toggle&&this.toggle()}var t=l.prototype;return t.toggle=function e(){p(this._element).hasClass(T.SHOW)?this.hide():this.show()},t.show=function u(){var t,e,n=this;if(!this._isTransitioning&&!p(this._element).hasClass(T.SHOW)&&(this._parent&&0===(t=[].slice.call(this._parent.querySelectorAll(C.ACTIVES)).filter(function(t){return"string"==typeof n._config.parent?t.getAttribute("data-parent")===n._config.parent:t.classList.contains(T.COLLAPSE)})).length&&(t=null),!(t&&(e=p(t).not(this._selector).data(_))&&e._isTransitioning))){var r=p.Event(S.SHOW);if(p(this._element).trigger(r),!r.isDefaultPrevented()){t&&(l._jQueryInterface.call(p(t).not(this._selector),"hide"),e||p(t).data(_,null));var i=this._getDimension();p(this._element
).removeClass(T.COLLAPSE).addClass(T.COLLAPSING),this._element.style[i]=0,this._triggerArray.length&&p(this._triggerArray).removeClass(T.COLLAPSED).attr("aria-expanded",!0),this.setTransitioning(!0);var o=function o(){p(n._element).removeClass(T.COLLAPSING).addClass(T.COLLAPSE).addClass(T.SHOW),n._element.style[i]="",n.setTransitioning(!1),p(n._element).trigger(S.SHOWN)},a="scroll"+(i[0].toUpperCase()+i.slice(1)),s=g.getTransitionDurationFromElement(this._element);p(this._element).one(g.TRANSITION_END,o).emulateTransitionEnd(s),this._element.style[i]=this._element[a]+"px"}}},t.hide=function c(){var t=this;if(!this._isTransitioning&&p(this._element).hasClass(T.SHOW)){var e=p.Event(S.HIDE);if(p(this._element).trigger(e),!e.isDefaultPrevented()){var n=this._getDimension();this._element.style[n]=this._element.getBoundingClientRect()[n]+"px",g.reflow(this._element),p(this._element).addClass(T.COLLAPSING).removeClass(T.COLLAPSE).removeClass(T.SHOW);var r=this._triggerArray.length;if(0<r)for(var i=0;i<r;i++){var o=this._triggerArray[i],a=g.getSelectorFromElement(o);if(null!==a)p([].slice.call(document.querySelectorAll(a))).hasClass(T.SHOW)||p(o).addClass(T.COLLAPSED).attr("aria-expanded",!1)}this.setTransitioning(!0);var s=function s(){t.setTransitioning(!1),p(t._element).removeClass(T.COLLAPSING).addClass(T.COLLAPSE).trigger(S.HIDDEN)};this._element.style[n]="";var l=g.getTransitionDurationFromElement(this._element);p(this._element).one(g.TRANSITION_END,s).emulateTransitionEnd(l)}}},t.setTransitioning=function n(t){this._isTransitioning=t},t.dispose=function r(){p.removeData(this._element,_),this._config=null,this._parent=null,this._element=null,this._triggerArray=null,this._isTransitioning=null},t._getConfig=function i(t){return(t=y({},x,t)).toggle=Boolean(t.toggle),g.typeCheckConfig(v,t,w),t},t._getDimension=function o(){return p(this._element).hasClass(k.WIDTH)?k.WIDTH:k.HEIGHT},t._getParent=function a(){var t,n=this;g.isElement(this._config.parent)?(t=this._config.parent,"undefined"!=typeof this._config.parent.jquery&&(t=this._config.parent[0])):t=document.querySelector(this._config.parent);var e='[data-toggle="collapse"][data-parent="'+this._config.parent+'"]',r=[].slice.call(t.querySelectorAll(e));return p(r).each(function(t,e){n._addAriaAndCollapsedClass(l._getTargetFromElement(e),[e])}),t},t._addAriaAndCollapsedClass=function s(t,e){var n=p(t).hasClass(T.SHOW);e.length&&p(e).toggleClass(T.COLLAPSED,!n).attr("aria-expanded",n)},l._getTargetFromElement=function d(t){var e=g.getSelectorFromElement(t);return e?document.querySelector(e):null},l._jQueryInterface=function h(r){return this.each(function(){var t=p(this),e=t.data(_),n=y({},x,t.data(),"object"==typeof r&&r?r:{});if(!e&&n.toggle&&/show|hide/.test(r)&&(n.toggle=!1),e||(e=new l(this,n),t.data(_,e)),"string"==typeof r){if("undefined"==typeof e[r])throw new TypeError('No method named "'+r+'"');e[r]()}})},m(l,null,[{key:"VERSION",get:function f(){return b}},{key:"Default",get:function f(){return x}}]),l}();return p(document).on(S.CLICK_DATA_API,C.DATA_TOGGLE,function(t){"A"===t.currentTarget.tagName&&t.preventDefault();var n=p(this),e=g.getSelectorFromElement(this),r=[].slice.call(document.querySelectorAll(e));p(r).each(function(){var t=p(this),e=t.data(_)?"toggle":n.data();o._jQueryInterface.call(t,e)})}),p.fn[v]=o._jQueryInterface,p.fn[v].Constructor=o,p.fn[v].noConflict=function(){return p.fn[v]=n,o._jQueryInterface},o}),function(t,e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e(require("jquery"),require("popper.js"),require("./util.js")):"function"==typeof define&&define.amd?define(["jquery","popper.js","./util.js"],e):(t=t||self).Dropdown=e(t.jQuery,t.Popper,t.Util)}(this,function(b,_,x){"use strict";function r(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}function w(t,e,n){return e&&r(t.prototype,e),n&&r(t,n),t}function i(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function S(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},r=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(n).filter(function(t){return Object.getOwnPropertyDescriptor(n,t).enumerable}))),r.forEach(function(t){i(e,t,n[t])})}return e}b=b&&b.hasOwnProperty("default")?b["default"]:b,_=_&&_.hasOwnProperty("default")?_["default"]:_,x=x&&x.hasOwnProperty("default")?x["default"]:x;var T="dropdown",k="4.3.1",C="bs.dropdown",E="."+C,t=".data-api",e=b.fn[T],D=27,A=32,M=9,O=38,I=40,P=3,L=new RegExp(O+"|"+I+"|"+D),N={HIDE:"hide"+E,HIDDEN:"hidden"+E,SHOW:"show"+E,SHOWN:"shown"+E,CLICK:"click"+E,CLICK_DATA_API:"click"+E+t,KEYDOWN_DATA_API:"keydown"+E+t,KEYUP_DATA_API:"keyup"+E+t},R={DISABLED:"disabled",SHOW:"show",DROPUP:"dropup",DROPRIGHT:"dropright",DROPLEFT:"dropleft",MENURIGHT:"dropdown-menu-right",MENULEFT:"dropdown-menu-left",POSITION_STATIC:"position-static"},F={DATA_TOGGLE:'[data-toggle="dropdown"]',FORM_CHILD:".dropdown form",MENU:".dropdown-menu",NAVBAR_NAV:".navbar-nav",VISIBLE_ITEMS:".dropdown-menu .dropdown-item:not(.disabled):not(:disabled)"},H={TOP:"top-start",TOPEND:"top-end",BOTTOM:"bottom-start",BOTTOMEND:"bottom-end",RIGHT:"right-start",RIGHTEND:"right-end",LEFT:"left-start",LEFTEND:"left-end"},j={offset:0,flip:!0,boundary:"scrollParent",reference:"toggle",display:"dynamic"},W={offset:"(number|string|function)",flip:"boolean",boundary:"(string|element)",reference:"(string|element)",display:"string"},n=function(){function u(t,e){this._element=t,this._popper=null,this._config=this._getConfig(e),this._menu=this._getMenuElement(),this._inNavbar=this._detectNavbar(),this._addEventListeners()}var t=u.prototype;return t.toggle=function o(){if(!this._element.disabled&&!b(this._element).hasClass(R.DISABLED)){var t=u._getParentFromElement(this._element),e=b(this._menu).hasClass(R.SHOW);if(u._clearMenus(),!e){var n={relatedTarget:this._element},r=b.Event(N.SHOW,n);if(b(t).trigger(r),!r.isDefaultPrevented()){if(!this._inNavbar){if(void 0===_)throw new TypeError("Bootstrap's dropdowns require Popper.js (https://popper.js.org/)");var i=this._element;"parent"===this._config.reference?i=t:x.isElement(this._config.reference)&&(i=this._config.reference,"undefined"!=typeof this._config.reference.jquery&&(i=this._config.reference[0])),"scrollParent"!==this._config.boundary&&b(t).addClass(R.POSITION_STATIC),this._popper=new _(i,this._menu,this._getPopperConfig())}"ontouchstart"in document.documentElement&&0===b(t).closest(F.NAVBAR_NAV).length&&b(document.body).children().on("mouseover",null,b.noop),this._element.focus(),this._element.setAttribute("aria-expanded",!0),b(this._menu).toggleClass(R.SHOW),b(t).toggleClass(R.SHOW).trigger(b.Event(N.SHOWN,n))}}}},t.show=function r(){if(!(this._element.disabled||b(this._element).hasClass(R.DISABLED)||b(this._menu).hasClass(R.SHOW))){var t={relatedTarget:this._element},e=b.Event(N.SHOW,t),n=u._getParentFromElement(this._element);b(n).trigger(e),e.isDefaultPrevented()||(b(this._menu).toggleClass(R.SHOW),b(n).toggleClass(R.SHOW).trigger(b.Event(N.SHOWN,t)))}},t.hide=function i(){if(!this._element.disabled&&!b(this._element).hasClass(R.DISABLED)&&b(this._menu).hasClass(R.SHOW)){var t={relatedTarget:this._element},e=b.Event(N.HIDE,t),n=u._getParentFromElement(this._element);b(n).trigger(e),e.isDefaultPrevented()||(b(this._menu).toggleClass(R.SHOW),b(n).toggleClass(R.SHOW).trigger(b.Event(N.HIDDEN,t)))}},t.dispose=function e(){b.removeData(this._element,C),b(this._element).off(E),this._element=null,(this._menu=null)!==this._popper&&(this._popper.destroy(),this._popper=null)},t.update=function n(){this._inNavbar=this._detectNavbar(),null!==this._popper&&this._popper.scheduleUpdate()},t._addEventListeners=function a(){var e=this;b(this._element).on(N.CLICK,function(t){t.preventDefault(),t.stopPropagation(),e.toggle()})},t._getConfig=function s(t){return t=S({},this.constructor.Default,b(this._element).data(),t),x.typeCheckConfig(T,t,this.constructor.DefaultType),t},t._getMenuElement=function l(){if(!this._menu){var t=u._getParentFromElement(this._element);t&&(this._menu=t.querySelector(F.MENU))}return this._menu},t._getPlacement=function c(){var t=b(this._element.parentNode),e=H.BOTTOM;return t.hasClass(R.DROPUP)?(e=H.TOP,b(this._menu).hasClass(R.MENURIGHT)&&(e=H.TOPEND)):t.hasClass(R.DROPRIGHT)?e=H.RIGHT:t.hasClass(R.DROPLEFT)?e=H.LEFT:b(this._menu).hasClass(R.MENURIGHT)&&(e=H.BOTTOMEND),e},t._detectNavbar=function d(){return 0<b(this._element).closest(".navbar").length},t._getOffset=function h(){var e=this,t={};return"function"==typeof this._config.offset?t.fn=function(t){return t.offsets=S({},t.offsets,e._config.offset(t.offsets,e._element)||{}),t}:t.offset=this._config.offset,t},t._getPopperConfig=function f(){var t={placement:this._getPlacement(),modifiers:{offset:this._getOffset(),flip:{enabled:this._config.flip},preventOverflow:{boundariesElement:this._config.boundary}}};return"static"===this._config.display&&(t.modifiers.applyStyle={enabled:!1}),t},u._jQueryInterface=function p(e){return this.each(function(){var t=b(this).data(C);if(t||(t=new u(this,"object"==typeof e?e:null),b(this).data(C,t)),"string"==typeof e){if("undefined"==typeof t[e])throw new TypeError('No method named "'+e+'"');t[e]()}})},u._clearMenus=function g(t){if(!t||t.which!==P&&("keyup"!==t.type||t.which===M))for(var e=[].slice.call(document.querySelectorAll(F.DATA_TOGGLE)),n=0,r=e.length;n<r;n++){var i=u._getParentFromElement(e[n]),o=b(e[n]).data(C),a={relatedTarget:e[n]};if(t&&"click"===t.type&&(a.clickEvent=t),o){var s=o._menu;if(b(i).hasClass(R.SHOW)&&!(t&&("click"===t.type&&/input|textarea/i.test(t.target.tagName)||"keyup"===t.type&&t.which===M)&&b.contains(i,t.target))){var l=b.Event(N.HIDE,a);b(i).trigger(l),l.isDefaultPrevented()||("ontouchstart"in document.documentElement&&b(document.body).children().off("mouseover",null,b.noop),e[n].setAttribute("aria-expanded","false"),b(s).removeClass(R.SHOW),b(i).removeClass(R.SHOW).trigger(b.Event(N.HIDDEN,a)))}}}},u._getParentFromElement=function m(t){var e,n=x.getSelectorFromElement(t);return n&&(e=document.querySelector(n)),e||t.parentNode},u._dataApiKeydownHandler=function y(t){if((/input|textarea/i.test(t.target.tagName)?!(t.which===A||t.which!==D&&(t.which!==I&&t.which!==O||b(t.target).closest(F.MENU).length)):L.test(t.which))&&(t.preventDefault(),t.stopPropagation(),!this.disabled&&!b(this).hasClass(R.DISABLED))){var e=u._getParentFromElement(this),n=b(e).hasClass(R.SHOW);if(n&&(!n||t.which!==D&&t.which!==A)){var r=[].slice.call(e.querySelectorAll(F.VISIBLE_ITEMS));if(0!==r.length){var i=r.indexOf(t.target);t.which===O&&0<i&&i--,t.which===I&&i<r.length-1&&i++,i<0&&(i=0),r[i].focus()}}else{if(t.which===D){var o=e.querySelector(F.DATA_TOGGLE);b(o).trigger("focus")}b(this).trigger("click")}}},w(u,null,[{key:"VERSION",get:function v(){return k}},{key:"Default",get:function v(){return j}},{key:"DefaultType",get:function v(){return W}}]),u}();return b(document).on(N.KEYDOWN_DATA_API,F.DATA_TOGGLE,n._dataApiKeydownHandler).on(N.KEYDOWN_DATA_API,F.MENU,n._dataApiKeydownHandler).on(N.CLICK_DATA_API+" "+N.KEYUP_DATA_API,n._clearMenus).on(N.CLICK_DATA_API,F.DATA_TOGGLE,function(t){t.preventDefault(),t.stopPropagation(),n._jQueryInterface.call(b(this),"toggle")}).on(N.CLICK_DATA_API,F.FORM_CHILD,function(t){t.stopPropagation()}),b.fn[T]=n._jQueryInterface,b.fn[T].Constructor=n,b.fn[T].noConflict=function(){return b.fn[T]=e,n._jQueryInterface},n}),function(t,e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e(require("jquery"),require("./util.js")):"function"==typeof define&&define.amd?define(["jquery","./util.js"],e):(t=t||self).Modal=e(t.jQuery,t.Util)}(this,function(S,T){"use strict";function r(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}function k(t,e,n){return e&&r(t.prototype,e),n&&r(t,n),t}function i(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function C(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},r=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(n).filter(function(t){return Object.getOwnPropertyDescriptor(n,t).enumerable}))),r.forEach(function(t){i(e,t,n[t])})}return e}S=S&&S.hasOwnProperty("default")?S["default"]:S,T=T&&T.hasOwnProperty("default")?T["default"]:T;var E="modal",D="4.3.1",A="bs.modal",M="."+A,t=".data-api",e=S.fn[E],O=27,I={backdrop:!0,keyboard:!0,focus:!0,show:!0},P={backdrop:"(boolean|string)",keyboard:"boolean",focus:"boolean",show:"boolean"},L={HIDE:"hide"+M,HIDDEN:"hidden"+M,SHOW:"show"+M,SHOWN:"shown"+M,FOCUSIN:"focusin"+M,RESIZE:"resize"+M,CLICK_DISMISS:"click.dismiss"+M,KEYDOWN_DISMISS:"keydown.dismiss"+M,MOUSEUP_DISMISS:"mouseup.dismiss"+M,MOUSEDOWN_DISMISS:"mousedown.dismiss"+M,CLICK_DATA_API:"click"+M+t},N={SCROLLABLE:"modal-dialog-scrollable",SCROLLBAR_MEASURER:"modal-scrollbar-measure",BACKDROP:"modal-backdrop",OPEN:"modal-open",FADE:"fade",SHOW:"show"},R={DIALOG:".modal-dialog",MODAL_BODY:".modal-body",DATA_TOGGLE:'[data-toggle="modal"]',DATA_DISMISS:'[data-dismiss="modal"]',FIXED_CONTENT:".fixed-top, .fixed-bottom, .is-fixed, .sticky-top",STICKY_CONTENT:".sticky-top"},a=function(){function i(t,e){this._config=this._getConfig(e),this._element=t,this._dialog=t.querySelector(R.DIALOG),this._backdrop=null,this._isShown=!1,this._isBodyOverflowing=!1,this._ignoreBackdropClick=!1,this._isTransitioning=!1,this._scrollbarWidth=0}var t=i.prototype;return t.toggle=function e(t){return this._isShown?this.hide():this.show(t)},t.show=function r(t){var e=this;if(!this._isShown&&!this._isTransitioning){S(this._element).hasClass(N.FADE)&&(this._isTransitioning=!0);var n=S.Event(L.SHOW,{relatedTarget:t});S(this._element).trigger(n),this._isShown||n.isDefaultPrevented()||(this._isShown=!0,this._checkScrollbar(),this._setScrollbar(),this._adjustDialog(),this._setEscapeEvent(),this._setResizeEvent(),S(this._element).on(L.CLICK_DISMISS,R.DATA_DISMISS,function(t){return e.hide(t)}),S(this._dialog).on(L.MOUSEDOWN_DISMISS,function(){S(e._element).one(L.MOUSEUP_DISMISS,function(t){S(t.target).is(e._element)&&(e._ignoreBackdropClick=!0)})}),this._showBackdrop(function(){return e._showElement(t)}))}},t.hide=function o(t){var e=this;if(t&&t.preventDefault(),this._isShown&&!this._isTransitioning){var n=S.Event(L.HIDE);if(S(this._element).trigger(n),this._isShown&&!n.isDefaultPrevented()){this._isShown=!1;var r=S(this._element).hasClass(N.FADE);if(r&&(this._isTransitioning=!0),this._setEscapeEvent(),this._setResizeEvent(),S(document).off(L.FOCUSIN),S(this._element).removeClass(N.SHOW),S(this._element).off(L.CLICK_DISMISS),S(this._dialog).off(L.MOUSEDOWN_DISMISS),r){var i=T.getTransitionDurationFromElement(this._element);S(this._element).one(T.TRANSITION_END,function(t){return e._hideModal(t)}).emulateTransitionEnd(i)}else this._hideModal()}}},t.dispose=function n(){[window,this._element,this._dialog].forEach(function(t){return S(t).off(M)}),S(document).off(L.FOCUSIN),S.removeData(this._element,A),this._config=null,this._element=null,this._dialog=null,this._backdrop=null,this._isShown=null,this._isBodyOverflowing=null,this._ignoreBackdropClick=null,this._isTransitioning=null,this._scrollbarWidth=null},t.handleUpdate=function a(){this._adjustDialog()},t._getConfig=function s(t){return t=C({},I,t),T.typeCheckConfig(E,t,P),t},t._showElement=function l(t){var e=this,n=S(this._element).hasClass(N.FADE);this._element.parentNode&&this._element.parentNode.nodeType===Node.ELEMENT_NODE||document.body.appendChild(this._element),this._element.style.display="block",this._element.removeAttribute("aria-hidden"),this._element.setAttribute("aria-modal",!0),S(this._dialog).hasClass(N.SCROLLABLE)?this._dialog.querySelector(R.MODAL_BODY).scrollTop=0:this._element.scrollTop=0,n&&T.reflow(this._element),S(this._element).addClass(N.SHOW),this._config.focus&&this._enforceFocus();var r=S.Event(L.SHOWN,{relatedTarget:t}),i=function i(){e._config.focus&&e._element.focus(),e._isTransitioning=!1,S(e._element).trigger(r)};if(n){var o=T.getTransitionDurationFromElement(this._dialog);S(this._dialog).one(T.TRANSITION_END,i).emulateTransitionEnd(o)}else i()},t._enforceFocus=function u(){var e=this;S(document).off(L.FOCUSIN).on(L.FOCUSIN,function(t){document!==t.target&&e._element!==t.target&&0===S(e._element).has(t.target).length&&e._element.focus()})},t._setEscapeEvent=function c(){var e=this;this._isShown&&this._config.keyboard?S(this._element).on(L.KEYDOWN_DISMISS,function(t){t.which===O&&(t.preventDefault(),e.hide())}):this._isShown||S(this._element).off(L.KEYDOWN_DISMISS)},t._setResizeEvent=function d(){var e=this;this._isShown?S(window).on(L.RESIZE,function(t){return e.handleUpdate(t)}):S(window).off(L.RESIZE)},t._hideModal=function h(){var t=this;this._element.style.display="none",this._element.setAttribute("aria-hidden",!0),this._element.removeAttribute("aria-modal"),this._isTransitioning=!1,this._showBackdrop(function(){S(document.body).removeClass(N.OPEN),t._resetAdjustments(),t._resetScrollbar(),S(t._element).trigger(L.HIDDEN)})},t._removeBackdrop=function f(){this._backdrop&&(S(this._backdrop).remove(),this._backdrop=null)},t._showBackdrop=function p(t){var e=this,n=S(this._element).hasClass(N.FADE)?N.FADE:"";if(this._isShown&&this._config.backdrop){if(this._backdrop=document.createElement("div"),this._backdrop.className=N.BACKDROP,n&&this._backdrop.classList.add(n),S(this._backdrop).appendTo(document.body),S(this._element).on(L.CLICK_DISMISS,function(t){e._ignoreBackdropClick?e._ignoreBackdropClick=!1:t.target===t.currentTarget&&("static"===e._config.backdrop?e._element.focus():e.hide())}),n&&T.reflow(this._backdrop),S(this._backdrop).addClass(N.SHOW),!t)return;if(!n)return void t();var r=T.getTransitionDurationFromElement(this._backdrop);S(this._backdrop).one(T.TRANSITION_END,t).emulateTransitionEnd(r)}else if(!this._isShown&&this._backdrop){S(this._backdrop).removeClass(N.SHOW);var i=function i(){e._removeBackdrop(),t&&t()};if(S(this._element).hasClass(N.FADE)){var o=T.getTransitionDurationFromElement(this._backdrop);S(this._backdrop).one(T.TRANSITION_END,i).emulateTransitionEnd(o)}else i()}else t&&t()},t._adjustDialog=function g(){var t=this._element.scrollHeight>document.documentElement.clientHeight;!this._isBodyOverflowing&&t&&(this._element.style.paddingLeft=this._scrollbarWidth+"px"),this._isBodyOverflowing&&!t&&(this._element.style.paddingRight=this._scrollbarWidth+"px")},t._resetAdjustments=function m(){this._element.style.paddingLeft="",this._element.style.paddingRight=""},t._checkScrollbar=function y(){var t=document.body.getBoundingClientRect();this._isBodyOverflowing=t.left+t.right<window.innerWidth,this._scrollbarWidth=this._getScrollbarWidth()},t._setScrollbar=function v(){var i=this;if(this._isBodyOverflowing){var t=[].slice.call(document.querySelectorAll(R.FIXED_CONTENT)),e=[].slice.call(document.querySelectorAll(R.STICKY_CONTENT));S(t).each(function(t,e){var n=e.style.paddingRight,r=S(e).css("padding-right");S(e).data("padding-right",n).css("padding-right",parseFloat(r)+i._scrollbarWidth+"px")}),S(e).each(function(t,e){var n=e.style.marginRight,r=S(e).css("margin-right");S(e).data("margin-right",n).css("margin-right",parseFloat(r)-i._scrollbarWidth+"px")});var n=document.body.style.paddingRight,r=S(document.body).css("padding-right");S(document.body).data("padding-right",n).css("padding-right",parseFloat(r)+this._scrollbarWidth+"px")}S(document.body).addClass(N.OPEN)},t._resetScrollbar=function b(){var t=[].slice.call(document.querySelectorAll(R.FIXED_CONTENT));S(t).each(function(t,e){var n=S(e).data("padding-right");S(e).removeData("padding-right"),e.style.paddingRight=n||""});var e=[].slice.call(document.querySelectorAll(""+R.STICKY_CONTENT));S(e).each(function(t,e){var n=S(e).data("margin-right");void 0!==n&&S(e).css("margin-right",n).removeData("margin-right")});var n=S(document.body).data("padding-right");S(document.body).removeData("padding-right"),document.body.style.paddingRight=n||""},t._getScrollbarWidth=function _(){var t=document.createElement("div");t.className=N.SCROLLBAR_MEASURER,document.body.appendChild(t);var e=t.getBoundingClientRect().width-t.clientWidth;return document.body.removeChild(t),e},i._jQueryInterface=function x(n,r){return this.each(function(){var t=S(this).data(A),e=C({},I,S(this).data(),"object"==typeof n&&n?n:{});if(t||(t=new i(this,e),S(this).data(A,t)),"string"==typeof n){if("undefined"==typeof t[n])throw new TypeError('No method named "'+n+'"');t[n](r)}else e.show&&t.show(r)})},k(i,null,[{key:"VERSION",get:function w(){return D}},{key:"Default",get:function w(){return I}}]),i}();return S(document).on(L.CLICK_DATA_API,R.DATA_TOGGLE,function(t){var e,n=this,r=T.getSelectorFromElement(this);r&&(e=document.querySelector(r));var i=S(e).data(A)?"toggle":C({},S(e).data(),S(this).data());"A"!==this.tagName&&"AREA"!==this.tagName||t.preventDefault();var o=S(e).one(L.SHOW,function(t){t.isDefaultPrevented()||o.one(L.HIDDEN,function(){S(n).is(":visible")&&n.focus()})});a._jQueryInterface.call(S(e),i,this)}),S.fn[E]=a._jQueryInterface,S.fn[E].Constructor=a,S.fn[E].noConflict=function(){return S.fn[E]=e,a._jQueryInterface},a}),function(t,e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e(require("jquery"),require("popper.js"),require("./util.js")):"function"==typeof define&&define.amd?define(["jquery","popper.js","./util.js"],e):(t=t||self).Tooltip=e(t.jQuery,t.Popper,t.Util)}(this,function(O,I,P){"use strict";function r(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}function L(t,e,n){return e&&r(t.prototype,e),n&&r(t,n),t}function i(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function N(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},r=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(n).filter(function(t){return Object.getOwnPropertyDescriptor(n,t).enumerable}))),r.forEach(function(t){i(e,t,n[t])})}return e}function u(t,e){var n=t.nodeName.toLowerCase();if(-1!==e.indexOf(n))return-1===a.indexOf(n)||Boolean(t.nodeValue.match(s)||t.nodeValue.match(l));for(var r=e.filter(function(t){return t instanceof RegExp}),i=0,o=r.length;i<o;i++)if(n.match(r[i]))return!0;return!1}function R(t,o,e){if(0===t.length)return t;if(e&&"function"==typeof e)return e(t);for(var n=(new window.DOMParser).parseFromString(t,"text/html"),a=Object.keys(o),s=[].slice.call(n.body.querySelectorAll("*")),l=function l(t){var e=s[t],n=e.nodeName.toLowerCase();if(-1===a.indexOf(e.nodeName.toLowerCase()))return e.parentNode.removeChild(e),"continue";var r=[].slice.call(e.attributes),i=[].concat(o["*"]||[],o[n]||[]);r.forEach(function(t){u(t,i)||e.removeAttribute(t.nodeName)})},r=0,i=s.length;r<i;r++)l(r,i);return n.body.innerHTML}O=O&&O.hasOwnProperty("default")?O["default"]:O,I=I&&I.hasOwnProperty("default")?I["default"]:I,P=P&&P.hasOwnProperty("default")?P["default"]:P;var a=["background","cite","href","itemtype","longdesc","poster","src","xlink:href"],t={"*":["class","dir","id","lang","role",/^aria-[\w-]*$/i],a:["target","href","title","rel"],area:[],b:[],br:[],col:[],code:[],div:[],em:[],hr:[],h1:[],h2:[],h3:[],h4:[],h5:[],h6:[],i:[],img:["src","alt","title","width","height"],li:[],ol:[],p:[],pre:[],s:[],small:[],span:[],sub:[],sup:[],strong:[],u:[],ul:[]},s=/^(?:(?:https?|mailto|ftp|tel|file):|[^&:/?#]*(?:[/?#]|$))/gi,l=/^data:(?:image\/(?:bmp|gif|jpeg|jpg|png|tiff|webp)|video\/(?:mpeg|mp4|ogg|webm)|audio\/(?:mp3|oga|ogg|opus));base64,[a-z0-9+/]+=*$/i,F="tooltip",H="4.3.1",j="bs.tooltip",W="."+j,e=O.fn[F],z="bs-tooltip",B=new RegExp("(^|\\s)"+z+"\\S+","g"),V=["sanitize","whiteList","sanitizeFn"],q={animation:"boolean",template:"string",title:"(string|element|function)",trigger:"string",delay:"(number|object)",html:"boolean",selector:"(string|boolean)",placement:"(string|function)",offset:"(number|string|function)",container:"(string|element|boolean)",fallbackPlacement:"(string|array)",boundary:"(string|element)",sanitize:"boolean",sanitizeFn:"(null|function)",whiteList:"object"},U={AUTO:"auto",TOP:"top",RIGHT:"right",BOTTOM:"bottom",LEFT:"left"},Y={animation:!0,template:'<div class="tooltip" role="tooltip"><div class="arrow"></div><div class="tooltip-inner"></div></div>',trigger:"hover focus",title:"",delay:0,html:!1,selector:!1,placement:"top",offset:0,container:!1,fallbackPlacement:"flip",boundary:"scrollParent",sanitize:!0,sanitizeFn:null,whiteList:t},G={SHOW:"show",OUT:"out"},K={HIDE:"hide"+W,HIDDEN:"hidden"+W,SHOW:"show"+W,SHOWN:"shown"+W,INSERTED:"inserted"+W,CLICK:"click"+W,FOCUSIN:"focusin"+W,FOCUSOUT:"focusout"+W,MOUSEENTER:"mouseenter"+W,MOUSELEAVE:"mouseleave"+W},X={FADE:"fade",SHOW:"show"},Q={TOOLTIP:".tooltip",TOOLTIP_INNER:".tooltip-inner",ARROW:".arrow"},$={HOVER:"hover",FOCUS:"focus",CLICK:"click",MANUAL:"manual"},n=function(){function r(t,e){if(void 0===I)throw new TypeError("Bootstrap's tooltips require Popper.js (https://popper.js.org/)");this._isEnabled=!0,this._timeout=0,this._hoverState="",this._activeTrigger={},this._popper=null,this.element=t,this.config=this._getConfig(e),this.tip=null,this._setListeners()}var t=r.prototype;return t.enable=function e(){this._isEnabled=!0},t.disable=function n(){this._isEnabled=!1},t.toggleEnabled=function i(){this._isEnabled=!this._isEnabled},t.toggle=function o(t){if(this._isEnabled)if(t){var e=this.constructor.DATA_KEY,n=O(t.currentTarget).data(e);n||(n=new this.constructor(t.currentTarget,this._getDelegateConfig()),O(t.currentTarget).data(e,n)),n._activeTrigger.click=!n._activeTrigger.click,n._isWithActiveTrigger()?n._enter(null,n):n._leave(null,n)}else{if(O(this.getTipElement()).hasClass(X.SHOW))return void this._leave(null,this);this._enter(null,this)}},t.dispose=function a(){clearTimeout(this._timeout),O.removeData(this.element,this.constructor.DATA_KEY),O(this.element).off(this.constructor.EVENT_KEY),O(this.element).closest(".modal").off("hide.bs.modal"),this.tip&&O(this.tip).remove(),this._isEnabled=null,this._timeout=null,this._hoverState=null,(this._activeTrigger=null)!==this._popper&&this._popper.destroy(),this._popper=null,this.element=null,this.config=null,this.tip=null},t.show=function f(){var e=this;if("none"===O(this.element).css("display"))throw new Error("Please use show on visible elements");var t=O.Event(this.constructor.Event.SHOW);if(this.isWithContent()&&this._isEnabled){O(this.element).trigger(t);var n=P.findShadowRoot(this.element),r=O.contains(null!==n?n:this.element.ownerDocument.documentElement,this.element);if(t.isDefaultPrevented()||!r)return;var i=this.getTipElement(),o=P.getUID(this.constructor.NAME);i.setAttribute("id",o),this.element.setAttribute("aria-describedby",o),this.setContent(),this.config.animation&&O(i).addClass(X.FADE);var a="function"==typeof this.config.placement?this.config.placement.call(this,i,this.element):this.config.placement,s=this._getAttachment(a);this.addAttachmentClass(s);var l=this._getContainer();O(i).data(this.constructor.DATA_KEY,this),O.contains(this.element.ownerDocument.documentElement,this.tip)||O(i).appendTo(l),O(this.element).trigger(this.constructor.Event.INSERTED),this._popper=new I(this.element,i,{placement:s,modifiers:{offset:this._getOffset(),flip:{behavior:this.config.fallbackPlacement},arrow:{element:Q.ARROW},preventOverflow:{boundariesElement:this.config.boundary}},onCreate:function d(t){t.originalPlacement!==t.placement&&e._handlePopperPlacementChange(t)},onUpdate:function h(t){return e._handlePopperPlacementChange(t)}}),O(i).addClass(X.SHOW),"ontouchstart"in document.documentElement&&O(document.body).children().on("mouseover",null,O.noop);var u=function u(){e.config.animation&&e._fixTransition();var t=e._hoverState;e._hoverState=null,O(e.element).trigger(e.constructor.Event.SHOWN),t===G.OUT&&e._leave(null,e)};if(O(this.tip).hasClass(X.FADE)){var c=P.getTransitionDurationFromElement(this.tip);O(this.tip).one(P.TRANSITION_END,u).emulateTransitionEnd(c)}else u()}},t.hide=function s(t){var e=this,n=this.getTipElement(),r=O.Event(this.constructor.Event.HIDE),i=function i(){e._hoverState!==G.SHOW&&n.parentNode&&n.parentNode.removeChild(n),e._cleanTipClass(),e.element.removeAttribute("aria-describedby"),O(e.element).trigger(e.constructor.Event.HIDDEN),null!==e._popper&&e._popper.destroy(),t&&t()};if(O(this.element).trigger(r),!r.isDefaultPrevented()){if(O(n).removeClass(X.SHOW),"ontouchstart"in document.documentElement&&O(document.body).children().off("mouseover",null,O.noop),this._activeTrigger[$.CLICK]=!1,this._activeTrigger[$.FOCUS]=!1,this._activeTrigger[$.HOVER]=!1,O(this.tip).hasClass(X.FADE)){var o=P.getTransitionDurationFromElement(n);O(n).one(P.TRANSITION_END,i).emulateTransitionEnd(o)}else i();this._hoverState=""}},t.update=function l(){null!==this._popper&&this._popper.scheduleUpdate()},t.isWithContent=function u(){return Boolean(this.getTitle())},t.addAttachmentClass=function c(t){O(this.getTipElement()).addClass(z+"-"+t)},t.getTipElement=function d(){return this.tip=this.tip||O(this.config.template)[0],this.tip},t.setContent=function h(){var t=this.getTipElement();this.setElementContent(O(t.querySelectorAll(Q.TOOLTIP_INNER)),this.getTitle()),O(t).removeClass(X.FADE+" "+X.SHOW)},t.setElementContent=function p(t,e){"object"!=typeof e||!e.nodeType&&!e.jquery?this.config.html?(this.config.sanitize&&(e=R(e,this.config.whiteList,this.config.sanitizeFn)),t.html(e)):t.text(e):this.config.html?O(e).parent().is(t)||t.empty().append(e):t.text(O(e).text())},t.getTitle=function g(){var t=this.element.getAttribute("data-original-title");return t||(t="function"==typeof this.config.title?this.config.title.call(this.element):this.config.title),t},t._getOffset=function m(){var e=this,t={};return"function"==typeof this.config.offset?t.fn=function(t){return t.offsets=N({},t.offsets,e.config.offset(t.offsets,e.element)||{}),t}:t.offset=this.config.offset,t},t._getContainer=function y(){return!1===this.config.container?document.body:P.isElement(this.config.container)?O(this.config.container):O(document).find(this.config.container)},t._getAttachment=function v(t){return U[t.toUpperCase()]},t._setListeners=function b(){var r=this;this.config.trigger.split(" ").forEach(function(t){if("click"===t)O(r.element).on(r.constructor.Event.CLICK,r.config.selector,function(t){return r.toggle(t)});else if(t!==$.MANUAL){var e=t===$.HOVER?r.constructor.Event.MOUSEENTER:r.constructor.Event.FOCUSIN,n=t===$.HOVER?r.constructor.Event.MOUSELEAVE:r.constructor.Event.FOCUSOUT;O(r.element).on(e,r.config.selector,function(t){return r._enter(t)}).on(n,r.config.selector,function(t){return r._leave(t)})}}),O(this.element).closest(".modal").on("hide.bs.modal",function(){r.element&&r.hide()}),this.config.selector?this.config=N({},this.config,{trigger:"manual",selector:""}):this._fixTitle()},t._fixTitle=function _(){var t=typeof this.element.getAttribute("data-original-title");(this.element.getAttribute("title")||"string"!==t)&&(this.element.setAttribute("data-original-title",this.element.getAttribute("title")||""),this.element.setAttribute("title",""))},t._enter=function x(t,e){var n=this.constructor.DATA_KEY;(e=e||O(t.currentTarget).data(n))||(e=new this.constructor(t.currentTarget,this._getDelegateConfig()),O(t.currentTarget).data(n,e)),t&&(e._activeTrigger["focusin"===t.type?$.FOCUS:$.HOVER]=!0),O(e.getTipElement()).hasClass(X.SHOW)||e._hoverState===G.SHOW?e._hoverState=G.SHOW:(clearTimeout(e._timeout),e._hoverState=G.SHOW,e.config.delay&&e.config.delay.show?e._timeout=setTimeout(function(){e._hoverState===G.SHOW&&e.show()},e.config.delay.show):e.show())},t._leave=function w(t,e){var n=this.constructor.DATA_KEY;(e=e||O(t.currentTarget).data(n))||(e=new this.constructor(t.currentTarget,this._getDelegateConfig()),O(t.currentTarget).data(n,e)),t&&(e._activeTrigger["focusout"===t.type?$.FOCUS:$.HOVER]=!1),e._isWithActiveTrigger()||(clearTimeout(e._timeout),e._hoverState=G.OUT,e.config.delay&&e.config.delay.hide?e._timeout=setTimeout(function(){e._hoverState===G.OUT&&e.hide()},e.config.delay.hide):e.hide())},t._isWithActiveTrigger=function S(){for(var t in this._activeTrigger)if(this._activeTrigger[t])return!0;return!1},t._getConfig=function T(t){var e=O(this.element).data();return Object.keys(e).forEach(function(t){-1!==V.indexOf(t)&&delete e[t]}),
"number"==typeof(t=N({},this.constructor.Default,e,"object"==typeof t&&t?t:{})).delay&&(t.delay={show:t.delay,hide:t.delay}),"number"==typeof t.title&&(t.title=t.title.toString()),"number"==typeof t.content&&(t.content=t.content.toString()),P.typeCheckConfig(F,t,this.constructor.DefaultType),t.sanitize&&(t.template=R(t.template,t.whiteList,t.sanitizeFn)),t},t._getDelegateConfig=function k(){var t={};if(this.config)for(var e in this.config)this.constructor.Default[e]!==this.config[e]&&(t[e]=this.config[e]);return t},t._cleanTipClass=function C(){var t=O(this.getTipElement()),e=t.attr("class").match(B);null!==e&&e.length&&t.removeClass(e.join(""))},t._handlePopperPlacementChange=function E(t){var e=t.instance;this.tip=e.popper,this._cleanTipClass(),this.addAttachmentClass(this._getAttachment(t.placement))},t._fixTransition=function D(){var t=this.getTipElement(),e=this.config.animation;null===t.getAttribute("x-placement")&&(O(t).removeClass(X.FADE),this.config.animation=!1,this.hide(),this.show(),this.config.animation=e)},r._jQueryInterface=function A(n){return this.each(function(){var t=O(this).data(j),e="object"==typeof n&&n;if((t||!/dispose|hide/.test(n))&&(t||(t=new r(this,e),O(this).data(j,t)),"string"==typeof n)){if("undefined"==typeof t[n])throw new TypeError('No method named "'+n+'"');t[n]()}})},L(r,null,[{key:"VERSION",get:function M(){return H}},{key:"Default",get:function M(){return Y}},{key:"NAME",get:function M(){return F}},{key:"DATA_KEY",get:function M(){return j}},{key:"Event",get:function M(){return K}},{key:"EVENT_KEY",get:function M(){return W}},{key:"DefaultType",get:function M(){return q}}]),r}();return O.fn[F]=n._jQueryInterface,O.fn[F].Constructor=n,O.fn[F].noConflict=function(){return O.fn[F]=e,n._jQueryInterface},n}),function(t,e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e(require("jquery"),require("./tooltip.js")):"function"==typeof define&&define.amd?define(["jquery","./tooltip.js"],e):(t=t||self).Popover=e(t.jQuery,t.Tooltip)}(this,function(d,t){"use strict";function r(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}function h(t,e,n){return e&&r(t.prototype,e),n&&r(t,n),t}function i(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function e(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},r=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(n).filter(function(t){return Object.getOwnPropertyDescriptor(n,t).enumerable}))),r.forEach(function(t){i(e,t,n[t])})}return e}function f(t,e){t.prototype=Object.create(e.prototype),(t.prototype.constructor=t).__proto__=e}d=d&&d.hasOwnProperty("default")?d["default"]:d,t=t&&t.hasOwnProperty("default")?t["default"]:t;var p="popover",g="4.3.1",m="bs.popover",y="."+m,n=d.fn[p],v="bs-popover",b=new RegExp("(^|\\s)"+v+"\\S+","g"),_=e({},t.Default,{placement:"right",trigger:"click",content:"",template:'<div class="popover" role="tooltip"><div class="arrow"></div><h3 class="popover-header"></h3><div class="popover-body"></div></div>'}),x=e({},t.DefaultType,{content:"(string|element|function)"}),w={FADE:"fade",SHOW:"show"},S={TITLE:".popover-header",CONTENT:".popover-body"},T={HIDE:"hide"+y,HIDDEN:"hidden"+y,SHOW:"show"+y,SHOWN:"shown"+y,INSERTED:"inserted"+y,CLICK:"click"+y,FOCUSIN:"focusin"+y,FOCUSOUT:"focusout"+y,MOUSEENTER:"mouseenter"+y,MOUSELEAVE:"mouseleave"+y},o=function(t){function r(){return t.apply(this,arguments)||this}f(r,t);var e=r.prototype;return e.isWithContent=function n(){return this.getTitle()||this._getContent()},e.addAttachmentClass=function i(t){d(this.getTipElement()).addClass(v+"-"+t)},e.getTipElement=function o(){return this.tip=this.tip||d(this.config.template)[0],this.tip},e.setContent=function a(){var t=d(this.getTipElement());this.setElementContent(t.find(S.TITLE),this.getTitle());var e=this._getContent();"function"==typeof e&&(e=e.call(this.element)),this.setElementContent(t.find(S.CONTENT),e),t.removeClass(w.FADE+" "+w.SHOW)},e._getContent=function s(){return this.element.getAttribute("data-content")||this.config.content},e._cleanTipClass=function l(){var t=d(this.getTipElement()),e=t.attr("class").match(b);null!==e&&0<e.length&&t.removeClass(e.join(""))},r._jQueryInterface=function u(n){return this.each(function(){var t=d(this).data(m),e="object"==typeof n?n:null;if((t||!/dispose|hide/.test(n))&&(t||(t=new r(this,e),d(this).data(m,t)),"string"==typeof n)){if("undefined"==typeof t[n])throw new TypeError('No method named "'+n+'"');t[n]()}})},h(r,null,[{key:"VERSION",get:function c(){return g}},{key:"Default",get:function c(){return _}},{key:"NAME",get:function c(){return p}},{key:"DATA_KEY",get:function c(){return m}},{key:"Event",get:function c(){return T}},{key:"EVENT_KEY",get:function c(){return y}},{key:"DefaultType",get:function c(){return x}}]),r}(t);return d.fn[p]=o._jQueryInterface,d.fn[p].Constructor=o,d.fn[p].noConflict=function(){return d.fn[p]=n,o._jQueryInterface},o}),function(t,e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e(require("jquery"),require("./util.js")):"function"==typeof define&&define.amd?define(["jquery","./util.js"],e):(t=t||self).ScrollSpy=e(t.jQuery,t.Util)}(this,function(f,p){"use strict";function r(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}function g(t,e,n){return e&&r(t.prototype,e),n&&r(t,n),t}function i(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function m(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},r=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(n).filter(function(t){return Object.getOwnPropertyDescriptor(n,t).enumerable}))),r.forEach(function(t){i(e,t,n[t])})}return e}f=f&&f.hasOwnProperty("default")?f["default"]:f,p=p&&p.hasOwnProperty("default")?p["default"]:p;var y="scrollspy",v="4.3.1",b="bs.scrollspy",_="."+b,t=".data-api",e=f.fn[y],x={offset:10,method:"auto",target:""},w={offset:"number",method:"string",target:"(string|element)"},S={ACTIVATE:"activate"+_,SCROLL:"scroll"+_,LOAD_DATA_API:"load"+_+t},T={DROPDOWN_ITEM:"dropdown-item",DROPDOWN_MENU:"dropdown-menu",ACTIVE:"active"},k={DATA_SPY:'[data-spy="scroll"]',ACTIVE:".active",NAV_LIST_GROUP:".nav, .list-group",NAV_LINKS:".nav-link",NAV_ITEMS:".nav-item",LIST_ITEMS:".list-group-item",DROPDOWN:".dropdown",DROPDOWN_ITEMS:".dropdown-item",DROPDOWN_TOGGLE:".dropdown-toggle"},C={OFFSET:"offset",POSITION:"position"},o=function(){function n(t,e){var n=this;this._element=t,this._scrollElement="BODY"===t.tagName?window:t,this._config=this._getConfig(e),this._selector=this._config.target+" "+k.NAV_LINKS+","+this._config.target+" "+k.LIST_ITEMS+","+this._config.target+" "+k.DROPDOWN_ITEMS,this._offsets=[],this._targets=[],this._activeTarget=null,this._scrollHeight=0,f(this._scrollElement).on(S.SCROLL,function(t){return n._process(t)}),this.refresh(),this._process()}var t=n.prototype;return t.refresh=function r(){var e=this,t=this._scrollElement===this._scrollElement.window?C.OFFSET:C.POSITION,i="auto"===this._config.method?t:this._config.method,o=i===C.POSITION?this._getScrollTop():0;this._offsets=[],this._targets=[],this._scrollHeight=this._getScrollHeight(),[].slice.call(document.querySelectorAll(this._selector)).map(function(t){var e,n=p.getSelectorFromElement(t);if(n&&(e=document.querySelector(n)),e){var r=e.getBoundingClientRect();if(r.width||r.height)return[f(e)[i]().top+o,n]}return null}).filter(function(t){return t}).sort(function(t,e){return t[0]-e[0]}).forEach(function(t){e._offsets.push(t[0]),e._targets.push(t[1])})},t.dispose=function e(){f.removeData(this._element,b),f(this._scrollElement).off(_),this._element=null,this._scrollElement=null,this._config=null,this._selector=null,this._offsets=null,this._targets=null,this._activeTarget=null,this._scrollHeight=null},t._getConfig=function i(t){if("string"!=typeof(t=m({},x,"object"==typeof t&&t?t:{})).target){var e=f(t.target).attr("id");e||(e=p.getUID(y),f(t.target).attr("id",e)),t.target="#"+e}return p.typeCheckConfig(y,t,w),t},t._getScrollTop=function o(){return this._scrollElement===window?this._scrollElement.pageYOffset:this._scrollElement.scrollTop},t._getScrollHeight=function a(){return this._scrollElement.scrollHeight||Math.max(document.body.scrollHeight,document.documentElement.scrollHeight)},t._getOffsetHeight=function s(){return this._scrollElement===window?window.innerHeight:this._scrollElement.getBoundingClientRect().height},t._process=function l(){var t=this._getScrollTop()+this._config.offset,e=this._getScrollHeight(),n=this._config.offset+e-this._getOffsetHeight();if(this._scrollHeight!==e&&this.refresh(),n<=t){var r=this._targets[this._targets.length-1];this._activeTarget!==r&&this._activate(r)}else{if(this._activeTarget&&t<this._offsets[0]&&0<this._offsets[0])return this._activeTarget=null,void this._clear();for(var i=this._offsets.length;i--;){this._activeTarget!==this._targets[i]&&t>=this._offsets[i]&&("undefined"==typeof this._offsets[i+1]||t<this._offsets[i+1])&&this._activate(this._targets[i])}}},t._activate=function u(e){this._activeTarget=e,this._clear();var t=this._selector.split(",").map(function(t){return t+'[data-target="'+e+'"],'+t+'[href="'+e+'"]'}),n=f([].slice.call(document.querySelectorAll(t.join(","))));n.hasClass(T.DROPDOWN_ITEM)?(n.closest(k.DROPDOWN).find(k.DROPDOWN_TOGGLE).addClass(T.ACTIVE),n.addClass(T.ACTIVE)):(n.addClass(T.ACTIVE),n.parents(k.NAV_LIST_GROUP).prev(k.NAV_LINKS+", "+k.LIST_ITEMS).addClass(T.ACTIVE),n.parents(k.NAV_LIST_GROUP).prev(k.NAV_ITEMS).children(k.NAV_LINKS).addClass(T.ACTIVE)),f(this._scrollElement).trigger(S.ACTIVATE,{relatedTarget:e})},t._clear=function c(){[].slice.call(document.querySelectorAll(this._selector)).filter(function(t){return t.classList.contains(T.ACTIVE)}).forEach(function(t){return t.classList.remove(T.ACTIVE)})},n._jQueryInterface=function d(e){return this.each(function(){var t=f(this).data(b);if(t||(t=new n(this,"object"==typeof e&&e),f(this).data(b,t)),"string"==typeof e){if("undefined"==typeof t[e])throw new TypeError('No method named "'+e+'"');t[e]()}})},g(n,null,[{key:"VERSION",get:function h(){return v}},{key:"Default",get:function h(){return x}}]),n}();return f(window).on(S.LOAD_DATA_API,function(){for(var t=[].slice.call(document.querySelectorAll(k.DATA_SPY)),e=t.length;e--;){var n=f(t[e]);o._jQueryInterface.call(n,n.data())}}),f.fn[y]=o._jQueryInterface,f.fn[y].Constructor=o,f.fn[y].noConflict=function(){return f.fn[y]=e,o._jQueryInterface},o}),function(t,e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e(require("jquery"),require("./util.js")):"function"==typeof define&&define.amd?define(["jquery","./util.js"],e):(t=t||self).Tab=e(t.jQuery,t.Util)}(this,function(c,d){"use strict";function r(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}function o(t,e,n){return e&&r(t.prototype,e),n&&r(t,n),t}c=c&&c.hasOwnProperty("default")?c["default"]:c,d=d&&d.hasOwnProperty("default")?d["default"]:d;var t="tab",s="4.3.1",h="bs.tab",e="."+h,n=".data-api",i=c.fn[t],f={HIDE:"hide"+e,HIDDEN:"hidden"+e,SHOW:"show"+e,SHOWN:"shown"+e,CLICK_DATA_API:"click"+e+n},p={DROPDOWN_MENU:"dropdown-menu",ACTIVE:"active",DISABLED:"disabled",FADE:"fade",SHOW:"show"},g={DROPDOWN:".dropdown",NAV_LIST_GROUP:".nav, .list-group",ACTIVE:".active",ACTIVE_UL:"> li > .active",DATA_TOGGLE:'[data-toggle="tab"], [data-toggle="pill"], [data-toggle="list"]',DROPDOWN_TOGGLE:".dropdown-toggle",DROPDOWN_ACTIVE_CHILD:"> .dropdown-menu .active"},a=function(){function r(t){this._element=t}var t=r.prototype;return t.show=function u(){var n=this;if(!(this._element.parentNode&&this._element.parentNode.nodeType===Node.ELEMENT_NODE&&c(this._element).hasClass(p.ACTIVE)||c(this._element).hasClass(p.DISABLED))){var t,r,e=c(this._element).closest(g.NAV_LIST_GROUP)[0],i=d.getSelectorFromElement(this._element);if(e){var o="UL"===e.nodeName||"OL"===e.nodeName?g.ACTIVE_UL:g.ACTIVE;r=(r=c.makeArray(c(e).find(o)))[r.length-1]}var a=c.Event(f.HIDE,{relatedTarget:this._element}),s=c.Event(f.SHOW,{relatedTarget:r});if(r&&c(r).trigger(a),c(this._element).trigger(s),!s.isDefaultPrevented()&&!a.isDefaultPrevented()){i&&(t=document.querySelector(i)),this._activate(this._element,e);var l=function l(){var t=c.Event(f.HIDDEN,{relatedTarget:n._element}),e=c.Event(f.SHOWN,{relatedTarget:r});c(r).trigger(t),c(n._element).trigger(e)};t?this._activate(t,t.parentNode,l):l()}}},t.dispose=function e(){c.removeData(this._element,h),this._element=null},t._activate=function l(t,e,n){var r=this,i=(!e||"UL"!==e.nodeName&&"OL"!==e.nodeName?c(e).children(g.ACTIVE):c(e).find(g.ACTIVE_UL))[0],o=n&&i&&c(i).hasClass(p.FADE),a=function a(){return r._transitionComplete(t,i,n)};if(i&&o){var s=d.getTransitionDurationFromElement(i);c(i).removeClass(p.SHOW).one(d.TRANSITION_END,a).emulateTransitionEnd(s)}else a()},t._transitionComplete=function a(t,e,n){if(e){c(e).removeClass(p.ACTIVE);var r=c(e.parentNode).find(g.DROPDOWN_ACTIVE_CHILD)[0];r&&c(r).removeClass(p.ACTIVE),"tab"===e.getAttribute("role")&&e.setAttribute("aria-selected",!1)}if(c(t).addClass(p.ACTIVE),"tab"===t.getAttribute("role")&&t.setAttribute("aria-selected",!0),d.reflow(t),t.classList.contains(p.FADE)&&t.classList.add(p.SHOW),t.parentNode&&c(t.parentNode).hasClass(p.DROPDOWN_MENU)){var i=c(t).closest(g.DROPDOWN)[0];if(i){var o=[].slice.call(i.querySelectorAll(g.DROPDOWN_TOGGLE));c(o).addClass(p.ACTIVE)}t.setAttribute("aria-expanded",!0)}n&&n()},r._jQueryInterface=function i(n){return this.each(function(){var t=c(this),e=t.data(h);if(e||(e=new r(this),t.data(h,e)),"string"==typeof n){if("undefined"==typeof e[n])throw new TypeError('No method named "'+n+'"');e[n]()}})},o(r,null,[{key:"VERSION",get:function n(){return s}}]),r}();return c(document).on(f.CLICK_DATA_API,g.DATA_TOGGLE,function(t){t.preventDefault(),a._jQueryInterface.call(c(this),"show")}),c.fn[t]=a._jQueryInterface,c.fn[t].Constructor=a,c.fn[t].noConflict=function(){return c.fn[t]=i,a._jQueryInterface},a}),function(t,e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e(require("jquery"),require("./util.js")):"function"==typeof define&&define.amd?define(["jquery","./util.js"],e):(t=t||self).Toast=e(t.jQuery,t.Util)}(this,function(c,d){"use strict";function r(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}function h(t,e,n){return e&&r(t.prototype,e),n&&r(t,n),t}function i(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function f(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},r=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(n).filter(function(t){return Object.getOwnPropertyDescriptor(n,t).enumerable}))),r.forEach(function(t){i(e,t,n[t])})}return e}c=c&&c.hasOwnProperty("default")?c["default"]:c,d=d&&d.hasOwnProperty("default")?d["default"]:d;var p="toast",g="4.3.1",m="bs.toast",t="."+m,e=c.fn[p],y={CLICK_DISMISS:"click.dismiss"+t,HIDE:"hide"+t,HIDDEN:"hidden"+t,SHOW:"show"+t,SHOWN:"shown"+t},v={FADE:"fade",HIDE:"hide",SHOW:"show",SHOWING:"showing"},b={animation:"boolean",autohide:"boolean",delay:"number"},_={animation:!0,autohide:!0,delay:500},x={DATA_DISMISS:'[data-dismiss="toast"]'},n=function(){function r(t,e){this._element=t,this._config=this._getConfig(e),this._timeout=null,this._setListeners()}var t=r.prototype;return t.show=function i(){var t=this;c(this._element).trigger(y.SHOW),this._config.animation&&this._element.classList.add(v.FADE);var e=function e(){t._element.classList.remove(v.SHOWING),t._element.classList.add(v.SHOW),c(t._element).trigger(y.SHOWN),t._config.autohide&&t.hide()};if(this._element.classList.remove(v.HIDE),this._element.classList.add(v.SHOWING),this._config.animation){var n=d.getTransitionDurationFromElement(this._element);c(this._element).one(d.TRANSITION_END,e).emulateTransitionEnd(n)}else e()},t.hide=function n(t){var e=this;this._element.classList.contains(v.SHOW)&&(c(this._element).trigger(y.HIDE),t?this._close():this._timeout=setTimeout(function(){e._close()},this._config.delay))},t.dispose=function e(){clearTimeout(this._timeout),this._timeout=null,this._element.classList.contains(v.SHOW)&&this._element.classList.remove(v.SHOW),c(this._element).off(y.CLICK_DISMISS),c.removeData(this._element,m),this._element=null,this._config=null},t._getConfig=function o(t){return t=f({},_,c(this._element).data(),"object"==typeof t&&t?t:{}),d.typeCheckConfig(p,t,this.constructor.DefaultType),t},t._setListeners=function a(){var t=this;c(this._element).on(y.CLICK_DISMISS,x.DATA_DISMISS,function(){return t.hide(!0)})},t._close=function s(){var t=this,e=function e(){t._element.classList.add(v.HIDE),c(t._element).trigger(y.HIDDEN)};if(this._element.classList.remove(v.SHOW),this._config.animation){var n=d.getTransitionDurationFromElement(this._element);c(this._element).one(d.TRANSITION_END,e).emulateTransitionEnd(n)}else e()},r._jQueryInterface=function l(n){return this.each(function(){var t=c(this),e=t.data(m);if(e||(e=new r(this,"object"==typeof n&&n),t.data(m,e)),"string"==typeof n){if("undefined"==typeof e[n])throw new TypeError('No method named "'+n+'"');e[n](this)}})},h(r,null,[{key:"VERSION",get:function u(){return g}},{key:"DefaultType",get:function u(){return b}},{key:"Default",get:function u(){return _}}]),r}();return c.fn[p]=n._jQueryInterface,c.fn[p].Constructor=n,c.fn[p].noConflict=function(){return c.fn[p]=e,n._jQueryInterface},n}),function(t,e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e():"function"==typeof define&&define.amd?define(e):(t=t||self).Chartkick=e()}(this,function(){"use strict";function h(t){return"[object Array]"===Object.prototype.toString.call(t)}function a(t){return t instanceof Function}function r(t){return"[object Object]"===Object.prototype.toString.call(t)&&!a(t)&&t instanceof Object}function i(t,e){var n;for(n in e)"__proto__"!==n&&(r(e[n])||h(e[n])?(r(e[n])&&!r(t[n])&&(t[n]={}),h(e[n])&&!h(t[n])&&(t[n]=[]),i(t[n],e[n])):e[n]!==undefined&&(t[n]=e[n]))}function Y(t,e){var n={};return i(n,t),i(n,e),n}function o(t){var e,n,r,i,o,a,s,l,u,c,d;return"[object Date]"===(c=Object.prototype.toString.call(t))?t:"[object String]"===c&&(r=t.match(W))?(d=parseInt(r[1],10),a=parseInt(r[3],10)-1,e=parseInt(r[5],10),n=parseInt(r[7],10),o=r[9]?parseInt(r[9],10):0,u=r[11]?parseInt(r[11],10):0,i=r[12]?1e3*parseFloat(z+r[12].slice(1)):0,l=Date.UTC(d,a,e,n,o,u,i),r[13]&&r[14]&&(s=60*r[15],r[17]&&(s+=parseInt(r[17],10)),l-=60*(s*="-"===r[14]?-1:1)*1e3),new Date(l)):void 0}function f(t){var e,n,r;for(e=0;e<t.length;e++)for(r=t[e].data,n=0;n<r.length;n++)if(r[n][1]<0)return!0;return!1}function p(t){return""+t}function G(t){return parseFloat(t)}function K(t){var e,n,r,i;if("object"!=typeof t)if("number"==typeof t)t=new Date(1e3*t);else{if(e=(t=p(t)).match(j))return n=parseInt(e[1],10),r=parseInt(e[3],10)-1,i=parseInt(e[5],10),new Date(n,r,i);t=o(t.replace(/ /,"T").replace(" ","").replace("UTC","Z"))||new Date(t)}return t}function s(t){if(!h(t)){var e,n=[];for(e in t)t.hasOwnProperty(e)&&n.push([e,t[e]]);t=n}return t}function l(o,a,s,l,u,c,d,h){return function(t,e,n){var r=t.data,i=Y({},o);return i=Y(i,n||{}),(t.hideLegend||"legend"in e)&&a(i,e.legend,t.hideLegend),e.title&&s(i,e.title),"min"in e?l(i,e.min):f(r)||l(i,0),e.max&&u(i,e.max),"stacked"in e&&c(i,e.stacked),e.colors&&(i.colors=e.colors),e.xtitle&&d(i,e.xtitle),e.ytitle&&h(i,e.ytitle),i=Y(i,e.library||{})}}function g(t,e){return t[0].getTime()-e[0].getTime()}function m(t,e){return t[0]-e[0]}function X(t,e){return t-e}function Q(t){return 0===t.getMilliseconds()&&0===t.getSeconds()}function $(t){return Q(t)&&0===t.getMinutes()}function Z(t){return $(t)&&0===t.getHours()}function J(t,e){return Z(t)&&t.getDay()===e}function tt(t){return Z(t)&&1===t.getDate()}function et(t){return tt(t)&&0===t.getMonth()}function n(t){return!isNaN(K(t))&&6<=p(t).length}function u(t){return"number"==typeof t}function y(t,e,n,r){t=t||"",n.prefix&&(e<0&&(e*=-1,t+="-"),t+=n.prefix);var i=n.suffix||"",o=n.precision,a=n.round;if(n.byteScale){var s=r?n.byteScale:e;1099511627776<=s?(e/=1099511627776,i=" TB"):1073741824<=s?(e/=1073741824,i=" GB"):1048576<=s?(e/=1048576,i=" MB"):1024<=s?(e/=1024,i=" KB"):i=" bytes",o===undefined&&a===undefined&&(o=3)}if(o!==undefined&&a!==undefined)throw Error("Use either round or precision, not both");if(!r&&(o!==undefined&&(e=e.toPrecision(o),n.zeros||(e=parseFloat(e))),a!==undefined))if(a<0){var l=Math.pow(10,-1*a);e=parseInt((1*e/l).toFixed(0))*l}else e=e.toFixed(a),n.zeros||(e=parseFloat(e));if(n.thousands||n.decimal){var u=(e=p(e)).split(".");e=u[0],n.thousands&&(e=e.replace(/\B(?=(\d{3})+(?!\d))/g,n.thousands)),1<u.length&&(e+=(n.decimal||".")+u[1])}return t+e+i}function nt(t,e,n){return n in e?e[n]:n in t.options?t.options[n]:null}function c(t){var e,n,r;for(e=0;e<t.length;e++)for(r=t[e].data,n=0;n<r.length;n++)if(0!=r[n][1])return!1;return!0}function d(t,e,n){Ft.push([t,e,n]),v()}function v(){if(Ht<jt){var t=Ft.shift();t&&(Ht++,e(t[0],t[1],t[2]),v())}}function b(){Ht--,v()}function e(t,e,i){_(t,e,function(t,e,n){var r="string"==typeof n?n:n.message;i(r)})}function _(t,e,n){var r=window.jQuery||window.Zepto||window.$;if(r&&r.ajax)r.ajax({dataType:"json",url:t,success:e,error:n,complete:b});else{var i=new XMLHttpRequest;i.open("GET",t,!0),i.setRequestHeader("Content-Type","application/json"),i.onload=function(){b(),200===i.status?e(JSON.parse(i.responseText),i.statusText,i):n(i,"error",i.statusText)},i.send()}}function x(t,e){document.body.innerText?t.innerText=e:t.textContent=e}function w(t,e,n){n||(e="Error Loading Chart: "+e),x(t,e),t.style.color="#ff0000"}function S(t){try{t.__render()}catch(e){throw w(t.element,e.message),e}}function T(e,t){if("string"==typeof t)d(t,function(t){e.rawData=t,S(e)},function(t){w(e.element,t)});else if("function"==typeof t)try{t(function(t){e.rawData=t,S(e)},function(t){w(e.element,t,!0)})}catch(n){w(e.element,n,!0)}else e.rawData=t,S(e)}function k(n){var r=n.element,i=document.createElement("a"),o=n.options.download;!0===o?o={}:"string"==typeof o&&(o={filename:o}),i.download=o.filename||"chart.png",i.style.position="absolute",i.style.top="20px",i.style.right="20px",i.style.zIndex=1e3,i.style.lineHeight="20px",i.target="_blank";var t=document.createElement("img");t.alt="Download",t.style.border="none",t.src="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABQAAAAUCAMAAAC6V+0/AAABCFBMVEUAAADMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMzMywEsqxAAAAV3RSTlMAAQIDBggJCgsMDQ4PERQaHB0eISIjJCouLzE0OTo/QUJHSUpLTU5PUllhYmltcHh5foWLjI+SlaCio6atr7S1t7m6vsHHyM7R2tze5Obo7fHz9ff5+/1hlxK2AAAA30lEQVQYGUXBhVYCQQBA0TdYWAt2d3d3YWAHyur7/z9xgD16Lw0DW+XKx+1GgX+FRzM3HWQWrHl5N/oapW5RPe0PkBu+UYeICvozTWZVK23Ao04B79oJrOsJDOoxkZoQPWgX29pHpCZEk7rEvQYiNSFq1UMqvlCjJkRBS1R8hb00Vb/TajtBL7nTHE1X1vyMQF732dQhyF2o6SAwrzP06iUQzvwsArlnzcOdrgBhJyHa1QOgO9U1GsKuvjUTjavliZYQ8nNPapG6sap/3nrIdJ6bOWzmX/fy0XVpfzZP3S8OJT3g9EEiJwAAAABJRU5ErkJggg==",i.appendChild(t),r.style.position="relative",n.__downloadAttached=!0,n.__enterEvent=C(r,"mouseover",function(t){var e=t.relatedTarget;e&&(e===this||E(this,e))||!n.options.download||(i.href=n.toImage(o),r.appendChild(i))}),n.__leaveEvent=C(r,"mouseout",function(t){var e=t.relatedTarget;e&&(e===this||E(this,e))||i.parentNode&&i.parentNode.removeChild(i)})}function C(t,e,n){if(t.addEventListener)return t.addEventListener(e,n,!1),n;var r=function(){return n.call(t,window.event)};return t.attachEvent("on"+e,r),r}function t(t,e,n){t.removeEventListener?t.removeEventListener(e,n,!1):t.detachEvent("on"+e,n)}function E(t,e){if(t===e)return!1;for(;e&&e!==t;)e=e.parentNode;return e===t}function D(t){if(t){if("Highcharts"===t.product)return St;if(t.charts)return Rt;if(a(t))return yt}throw new Error("Unknown adapter")}function A(t){var e=new(D(t))(t);-1===zt.indexOf(e)&&zt.push(e)}function M(){"Chart"in window&&A(window.Chart),"Highcharts"in window&&A(window.Highcharts),window.google&&window.google.charts&&A(window.google)}function O(t,e){if("PieChart"===e||"GeoChart"===e||"Timeline"===e)return 0===t.length;for(var n=0;n<t.length;n++)if(0<t[n].data.length)return!1;return!0}function I(t,e){e.options.messages&&e.options.messages.empty&&O(e.data,t)?x(e.element,e.options.messages.empty):(P(t,e),e.options.download&&!e.__downloadAttached&&"chartjs"===e.adapter&&k(e))}function P(t,e){var n,r,i,o;for(i="render"+t,o=e.options.adapter,M(),n=0;n<zt.length;n++)if(r=zt[n],(!o||o===r.name)&&a(r[i]))return e.adapter=r.name,(e.__adapterObject=r)[i](e);throw 0<zt.length?new Error("No charting library found for "+t):new Error("No charting libraries found - be sure to include one before your charts")}function L(t,e){return N(t,u)?"number":!e&&N(t,n)?"datetime":"string"}function N(t,e){var n,r,i;for(n=0;n<t.length;n++)for(i=s(t[n].data),r=0;r<i.length;r++)if(!e(i[r][0]))return!1;return!0}function R(t){var e,n,r=[];for(e=0;e<t.length;e++){var i={};for(n in t[e])t[e].hasOwnProperty(n)&&(i[n]=t[e][n]);r.push(i)}return r}function F(t,e,n){var r,i=t.options,o=t.rawData;for(!h(o)||"object"!=typeof o[0]||h(o[0])?(o=[{name:i.label,data:o}],t.hideLegend=!0):t.hideLegend=!1,t.xtype=e||(i.discrete?"string":L(o,n)),o=R(o),r=0;r<o.length;r++)o[r].data=Vt(s(o[r].data),t.xtype);return o}function H(t){var e,n=s(t.rawData);for(e=0;e<n.length;e++)n[e]=[p(n[e][0]),G(n[e][1])];return n}var j=/^(\d\d\d\d)(-)?(\d\d)(-)?(\d\d)$/i,W=/(\d\d\d\d)(-)?(\d\d)(-)?(\d\d)(T)?(\d\d)(:)?(\d\d)?(:)?(\d\d)?([.,]\d+)?($|Z|([+-])(\d\d)(:)?(\d\d)?)/i,z=String(1.5).charAt(1),B={maintainAspectRatio:!1,animation:!1,tooltips:{displayColors:!1,callbacks:{}},legend:{},title:{fontSize:20,fontColor:"#333"}},V={scales:{yAxes:[{ticks:{maxTicksLimit:4},scaleLabel:{fontSize:16,fontColor:"#333"}}],xAxes:[{gridLines:{drawOnChartArea:!1},scaleLabel:{fontSize:16,fontColor:"#333"},time:{},ticks:{}}]}},rt=["#3366CC","#DC3912","#FF9900","#109618","#990099","#3B3EAC","#0099C6","#DD4477","#66AA00","#B82E2E","#316395","#994499","#22AA99","#AAAA11","#6633CC","#E67300","#8B0707","#329262","#5574A6","#651067"],q=function(t,e,n){e!==undefined?(t.legend.display=!!e,e&&!0!==e&&(t.legend.position=e)):n&&(t.legend.display=!1)},U=function(t,e){t.title.display=!0,t.title.text=e},it=function(t,e){null!==e&&(t.scales.yAxes[0].ticks.min=G(e))},ot=function(t,e){t.scales.yAxes[0].ticks.max=G(e)},at=function(t,e){null!==e&&(t.scales.xAxes[0].ticks.min=G(e))},st=function(t,e){t.scales.xAxes[0].ticks.max=G(e)},lt=function(t,e){t.scales.xAxes[0].stacked=!!e,t.scales.yAxes[0].stacked=!!e},ut=function(t,e){t.scales.xAxes[0].scaleLabel.display=!0,t.scales.xAxes[0].scaleLabel.labelString=e},ct=function(t,e){t.scales.yAxes[0].scaleLabel.display=!0,t.scales.yAxes[0].scaleLabel.labelString=e},dt=function(t,e){var n=/^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i.exec(t);return n?"rgba("+parseInt(n[1],16)+", "+parseInt(n[2],16)+", "+parseInt(n[3],16)+", "+e+")":t},ht=function(t){return null!=t},ft=function(t,e,n){var r=Math.ceil(t.element.offsetWidth/4/e.labels.length);25<r?r=25:r<10&&(r=10),n.scales.xAxes[0].ticks.callback||(n.scales.xAxes[0].ticks.callback=function(t){return(t=p(t)).length>r?t.substring(0,r-2)+"...":t})},pt=function(t,e,n){var i={prefix:t.options.prefix,suffix:t.options.suffix,thousands:t.options.thousands,decimal:t.options.decimal,precision:t.options.precision,round:t.options.round,zeros:t.options.zeros};if(t.options.bytes){var r=t.data;"pie"===n&&(r=[{data:r}]);for(var o=0,a=0;a<r.length;a++)for(var s=r[a],l=0;l<s.data.length;l++)s.data[l][1]>o&&(o=s.data[l][1]);for(var u=1;1024<=o;)u*=1024,o/=1024;i.byteScale=u}if("pie"!==n){var c=e.scales.yAxes;"bar"===n&&(c=e.scales.xAxes),i.byteScale&&(c[0].ticks.stepSize||(c[0].ticks.stepSize=i.byteScale/2),c[0].ticks.maxTicksLimit||(c[0].ticks.maxTicksLimit=4)),c[0].ticks.callback||(c[0].ticks.callback=function(t){return y("",t,i,!0)})}if(!e.tooltips.callbacks.label)if("scatter"===n)e.tooltips.callbacks.label=function(t,e){var n=e.datasets[t.datasetIndex].label||"";return n&&(n+=": "),n+"("+t.xLabel+", "+t.yLabel+")"};else if("bubble"===n)e.tooltips.callbacks.label=function(t,e){var n=e.datasets[t.datasetIndex].label||"";n&&(n+=": ");var r=e.datasets[t.datasetIndex].data[t.index];return n+"("+t.xLabel+", "+t.yLabel+", "+r.v+")"};else if("pie"===n)e.tooltips.callbacks.label=function(t,e){var n=e.labels[t.index],r=": ";return h(n)?(n=n.slice())[0]+=r:n+=r,y(n,e.datasets[t.datasetIndex].data[t.index],i)};else{var d="bar"===n?"xLabel":"yLabel";e.tooltips.callbacks.label=function(t,e){var n=e.datasets[t.datasetIndex].label||"";return n&&(n+=": "),y(n,t[d],i)}}},gt=l(Y(B,V),q,U,it,ot,lt,ut,ct),mt=function(t,e,n,r){var i,o=[],a=[],s=t.options.colors||rt,l=!0,u=!0,c=!0,d=!0,h=!0,f=!0,p=t.data,g=0;if("bubble"===n)for(var m=0;m<p.length;m++)for(var y=p[m],v=0;v<y.data.length;v++)y.data[v][2]>g&&(g=y.data[v][2]);var b,_,x,w,S,T=[],k=[];if("bar"===n||"column"===n||"number"!==t.xtype&&"bubble"!==t.xtype){var C,E,D=[];for(b=0;b<p.length;b++)for(x=p[b],_=0;_<x.data.length;_++)w=x.data[_],T[S="datetime"==t.xtype?w[0].getTime():w[0]]||(T[S]=new Array(p.length)),T[S][b]=G(w[1]),-1===D.indexOf(S)&&D.push(S);for("datetime"!==t.xtype&&"number"!==t.xtype||D.sort(X),_=0;_<p.length;_++)k.push([]);for(E=0;E<D.length;E++)for(b=D[E],"datetime"===t.xtype?(C=new Date(G(b)),l=l&&Z(C),i||(i=C.getDay()),u=u&&J(C,i),c=c&&tt(C),d=d&&et(C),h=h&&$(C),f=f&&Q(C)):C=b,a.push(C),_=0;_<p.length;_++)k[_].push(T[b][_]===undefined?null:T[b][_])}else for(var A=0;A<p.length;A++){for(var M=p[A],O=[],I=0;I<M.data.length;I++){var P={x:G(M.data[I][0]),y:G(M.data[I][1])};"bubble"===n&&(P.r=20*G(M.data[I][2])/g,P.v=M.data[I][2]),O.push(P)}k.push(O)}for(b=0;b<p.length;b++){var L=(x=p[b]).color||s[b],N="line"!==n?dt(L,.5):L,R={label:x.name||"",data:k[b],fill:"area"===n,borderColor:L,backgroundColor:N,pointBackgroundColor:L,borderWidth:2,pointHoverBackgroundColor:L};x.stack&&(R.stack=x.stack),!1===nt(t,x,"curve")&&(R.lineTension=0),!1===nt(t,x,"points")&&(R.pointRadius=0,R.pointHitRadius=5),R=Y(R=Y(R=Y(R,t.options.dataset||{}),x.library||{}),x.dataset||{}),o.push(R)}var F=t.options.xmin,H=t.options.xmax;if("datetime"===t.xtype){var j="math"in r.helpers?"ticks":"time";ht(F)&&(e.scales.xAxes[0][j].min=K(F).getTime()),ht(H)&&(e.scales.xAxes[0][j].max=K(H).getTime())}else"number"===t.xtype&&(ht(F)&&(e.scales.xAxes[0].ticks.min=F),ht(H)&&(e.scales.xAxes[0].ticks.max=H));if("datetime"===t.xtype&&0<a.length){var W=(ht(F)?K(F):a[0]).getTime(),z=(ht(H)?K(H):a[0]).getTime();for(b=1;b<a.length;b++){var B=a[b].getTime();B<W&&(W=B),z<B&&(z=B)}var V,q=(z-W)/864e5;if(!e.scales.xAxes[0].time.unit)if(d||3650<q?(e.scales.xAxes[0].time.unit="year",V=365):c||300<q?(e.scales.xAxes[0].time.unit="month",V=30):l||10<q?(e.scales.xAxes[0].time.unit="day",V=1):h||.5<q?(e.scales.xAxes[0].time.displayFormats={hour:"MMM D, h a"},e.scales.xAxes[0].time.unit="hour",V=1/24):f&&(e.scales.xAxes[0].time.displayFormats={minute:"h:mm a"},e.scales.xAxes[0].time.unit="minute",V=1/24/60),V&&0<q){var U=Math.ceil(q/V/(t.element.offsetWidth/100));u&&1===V&&(U=7*Math.ceil(U/7)),e.scales.xAxes[0].time.unitStepSize=U}e.scales.xAxes[0].time.tooltipFormat||(l?e.scales.xAxes[0].time.tooltipFormat="ll":h?e.scales.xAxes[0].time.tooltipFormat="MMM D, h a":f&&(e.scales.xAxes[0].time.tooltipFormat="h:mm a"))}return{labels:a,datasets:o}},yt=function yt(t){this.name="chartjs",this.library=t};yt.prototype.renderLineChart=function Yt(t,e){var n={};!t.options.max&&c(t.data)&&(n.max=1);var r=gt(t,Y(n,t.options));pt(t,r,e);var i=mt(t,r,e||"line",this.library);"number"===t.xtype?(r.scales.xAxes[0].type="linear",r.scales.xAxes[0].position="bottom"):r.scales.xAxes[0].type="string"===t.xtype?"category":"time",this.drawChart(t,"line",i,r)},yt.prototype.renderPieChart=function Gt(t){var e=Y({},B);t.options.donut&&(e.cutoutPercentage=50),"legend"in t.options&&q(e,t.options.legend),t.options.title&&U(e,t.options.title),e=Y(e,t.options.library||{}),pt(t,e,"pie");for(
var n=[],r=[],i=0;i<t.data.length;i++){var o=t.data[i];n.push(o[0]),r.push(o[1])}var a={data:r,backgroundColor:t.options.colors||rt},s={labels:n,datasets:[a=Y(a,t.options.dataset||{})]};this.drawChart(t,"pie",s,e)},yt.prototype.renderColumnChart=function Kt(t,e){var n;if("bar"===e){var r=Y(B,V);delete r.scales.yAxes[0].ticks.maxTicksLimit,n=l(r,q,U,at,st,lt,ut,ct)(t,t.options)}else n=gt(t,t.options);pt(t,n,e);var i=mt(t,n,"column",this.library);"bar"!==e&&ft(t,i,n),this.drawChart(t,"bar"===e?"horizontalBar":"bar",i,n)},yt.prototype.renderAreaChart=function Xt(t){this.renderLineChart(t,"area")},yt.prototype.renderBarChart=function Qt(t){this.renderColumnChart(t,"bar")},yt.prototype.renderScatterChart=function $t(t,e){e=e||"scatter";var n=gt(t,t.options);pt(t,n,e),"showLines"in n||(n.showLines=!1);var r=mt(t,n,e,this.library);n.scales.xAxes[0].type="linear",n.scales.xAxes[0].position="bottom",this.drawChart(t,e,r,n)},yt.prototype.renderBubbleChart=function Zt(t){this.renderScatterChart(t,"bubble")},yt.prototype.destroy=function Jt(t){t.chart&&t.chart.destroy()};var vt={chart:{},xAxis:{title:{text:null},labels:{style:{fontSize:"12px"}}},yAxis:{title:{text:null},labels:{style:{fontSize:"12px"}}},title:{text:null},credits:{enabled:!(yt.prototype.drawChart=function te(t,e,n,r){this.destroy(t);var i={type:e,data:n,options:r};t.options.code&&window.console.log("new Chart(ctx, "+JSON.stringify(i)+");"),t.element.innerHTML="<canvas></canvas>";var o=t.element.getElementsByTagName("CANVAS")[0];t.chart=new this.library(o,i)})},legend:{borderWidth:0},tooltip:{style:{fontSize:"12px"}},plotOptions:{areaspline:{},area:{},series:{marker:{}}}},bt=function(t,e,n){e!==undefined?(t.legend.enabled=!!e,e&&!0!==e&&("top"===e||"bottom"===e?t.legend.verticalAlign=e:(t.legend.layout="vertical",t.legend.verticalAlign="middle",t.legend.align=e))):n&&(t.legend.enabled=!1)},_t=function(t,e){t.title.text=e},xt=l(vt,bt,_t,function(t,e){t.yAxis.min=e},function(t,e){t.yAxis.max=e},function(t,e){var n=e?!0===e?"normal":e:null;t.plotOptions.series.stacking=n,t.plotOptions.area.stacking=n,t.plotOptions.areaspline.stacking=n},function(t,e){t.xAxis.title.text=e},function(t,e){t.yAxis.title.text=e}),wt=function(t,e,n){var r={prefix:t.options.prefix,suffix:t.options.suffix,thousands:t.options.thousands,decimal:t.options.decimal,precision:t.options.precision,round:t.options.round,zeros:t.options.zeros};"pie"===n||e.yAxis.labels.formatter||(e.yAxis.labels.formatter=function(){return y("",this.value,r)}),e.tooltip.pointFormatter||(e.tooltip.pointFormatter=function(){return'<span style="color:'+this.color+'">\u25cf</span> '+y(this.series.name+": <b>",this.y,r)+"</b><br/>"})},St=function yt(t){this.name="highcharts",this.library=t};St.prototype.renderLineChart=function Yt(t,e){var n={};"areaspline"===(e=e||"spline")&&(n={plotOptions:{areaspline:{stacking:"normal"},area:{stacking:"normal"},series:{marker:{enabled:!1}}}}),!1===t.options.curve&&("areaspline"===e?e="area":"spline"===e&&(e="line"));var r,i,o,a=xt(t,t.options,n);a.xAxis.type="string"===t.xtype?"category":"number"===t.xtype?"linear":"datetime",a.chart.type||(a.chart.type=e),wt(t,a,e);var s=t.data;for(i=0;i<s.length;i++){if(s[i].name=s[i].name||"Value",r=s[i].data,"datetime"===t.xtype)for(o=0;o<r.length;o++)r[o][0]=r[o][0].getTime();!(s[i].marker={symbol:"circle"})===t.options.points&&(s[i].marker.enabled=!1)}this.drawChart(t,s,a)},St.prototype.renderScatterChart=function $t(t){var e=xt(t,t.options,{});e.chart.type="scatter",this.drawChart(t,t.data,e)},St.prototype.renderPieChart=function Gt(t){var e=Y(vt,{});t.options.colors&&(e.colors=t.options.colors),t.options.donut&&(e.plotOptions={pie:{innerSize:"50%"}}),"legend"in t.options&&bt(e,t.options.legend),t.options.title&&_t(e,t.options.title);var n=Y(e,t.options.library||{});wt(t,n,"pie");var r=[{type:"pie",name:t.options.label||"Value",data:t.data}];this.drawChart(t,r,n)},St.prototype.renderColumnChart=function Kt(t,e){e=e||"column";var n,r,i,o,a=t.data,s=xt(t,t.options),l=[],u=[];for(s.chart.type=e,wt(t,s,e),n=0;n<a.length;n++)for(i=a[n],r=0;r<i.data.length;r++)l[(o=i.data[r])[0]]||(l[o[0]]=new Array(a.length),u.push(o[0])),l[o[0]][n]=o[1];"number"===t.xtype&&u.sort(X),s.xAxis.categories=u;var c,d=[];for(n=0;n<a.length;n++){for(o=[],r=0;r<u.length;r++)o.push(l[u[r]][n]||0);c={name:a[n].name||"Value",data:o},a[n].stack&&(c.stack=a[n].stack),d.push(c)}this.drawChart(t,d,s)},St.prototype.renderBarChart=function Qt(t){this.renderColumnChart(t,"bar")},St.prototype.renderAreaChart=function Xt(t){this.renderLineChart(t,"areaspline")},St.prototype.destroy=function Jt(t){t.chart&&t.chart.destroy()},St.prototype.drawChart=function te(t,e,n){this.destroy(t),n.chart.renderTo=t.element.id,n.series=e,t.options.code&&window.console.log("new Highcharts.Chart("+JSON.stringify(n)+");"),t.chart=new this.library.Chart(n)};var Tt={},kt=[],Ct={chartArea:{},fontName:"'Lucida Grande', 'Lucida Sans Unicode', Verdana, Arial, Helvetica, sans-serif",pointSize:6,legend:{textStyle:{fontSize:12,color:"#444"},alignment:"center",position:"right"},curveType:"function",hAxis:{textStyle:{color:"#666",fontSize:12},titleTextStyle:{},gridlines:{color:"transparent"},baselineColor:"#ccc",viewWindow:{}},vAxis:{textStyle:{color:"#666",fontSize:12},titleTextStyle:{},baselineColor:"#ccc",viewWindow:{}},tooltip:{textStyle:{color:"#666",fontSize:12}}},Et=function(t,e,n){var r;e!==undefined?(r=e?!0===e?"right":e:"none",t.legend.position=r):n&&(t.legend.position="none")},Dt=function(t,e){t.title=e,t.titleTextStyle={color:"#333",fontSize:"20px"}},At=function(t,e){t.hAxis.viewWindow.min=e},Mt=function(t,e){t.hAxis.viewWindow.max=e},Ot=function(t,e){t.isStacked=e||!1},It=function(t,e){t.hAxis.title=e,t.hAxis.titleTextStyle.italic=!1},Pt=function(t,e){t.vAxis.title=e,t.vAxis.titleTextStyle.italic=!1},Lt=l(Ct,Et,Dt,function(t,e){t.vAxis.viewWindow.min=e},function(t,e){t.vAxis.viewWindow.max=e},Ot,It,Pt),Nt=function(t){window.attachEvent?window.attachEvent("onresize",t):window.addEventListener&&window.addEventListener("resize",t,!0),t()},Rt=function yt(t){this.name="google",this.library=t};Rt.prototype.renderLineChart=function Yt(r){var i=this;this.waitForLoaded(r,function(){var t={};!1===r.options.curve&&(t.curveType="none"),!1===r.options.points&&(t.pointSize=0);var e=Lt(r,r.options,t),n=i.createDataTable(r.data,r.xtype);i.drawChart(r,"LineChart",n,e)})},Rt.prototype.renderPieChart=function Gt(r){var i=this;this.waitForLoaded(r,function(){var t={chartArea:{top:"10%",height:"80%"},legend:{}};r.options.colors&&(t.colors=r.options.colors),r.options.donut&&(t.pieHole=.5),"legend"in r.options&&Et(t,r.options.legend),r.options.title&&Dt(t,r.options.title);var e=Y(Y(Ct,t),r.options.library||{}),n=new i.library.visualization.DataTable;n.addColumn("string",""),n.addColumn("number","Value"),n.addRows(r.data),i.drawChart(r,"PieChart",n,e)})},Rt.prototype.renderColumnChart=function Kt(n){var r=this;this.waitForLoaded(n,function(){var t=Lt(n,n.options),e=r.createDataTable(n.data,n.xtype);r.drawChart(n,"ColumnChart",e,t)})},Rt.prototype.renderBarChart=function Qt(r){var i=this;this.waitForLoaded(r,function(){var t={hAxis:{gridlines:{color:"#ccc"}}},e=l(Ct,Et,Dt,At,Mt,Ot,It,Pt)(r,r.options,t),n=i.createDataTable(r.data,r.xtype);i.drawChart(r,"BarChart",n,e)})},Rt.prototype.renderAreaChart=function Xt(r){var i=this;this.waitForLoaded(r,function(){var t={isStacked:!0,pointSize:0,areaOpacity:.5},e=Lt(r,r.options,t),n=i.createDataTable(r.data,r.xtype);i.drawChart(r,"AreaChart",n,e)})},Rt.prototype.renderGeoChart=function ee(r){var i=this;this.waitForLoaded(r,function(){var t={legend:"none",colorAxis:{colors:r.options.colors||["#f6c7b6","#ce502d"]}},e=Y(Y(Ct,t),r.options.library||{}),n=new i.library.visualization.DataTable;n.addColumn("string",""),n.addColumn("number",r.options.label||"Value"),n.addRows(r.data),i.drawChart(r,"GeoChart",n,e)})},Rt.prototype.renderScatterChart=function $t(u){var c=this;this.waitForLoaded(u,function(){var t,e,n,r,i={},o=Lt(u,u.options,i),a=u.data,s=[];for(t=0;t<a.length;t++)for(a[t].name=a[t].name||"Value",r=a[t].data,e=0;e<r.length;e++){var l=new Array(a.length+1);l[0]=r[e][0],l[t+1]=r[e][1],s.push(l)}for((n=new c.library.visualization.DataTable).addColumn("number",""),t=0;t<a.length;t++)n.addColumn("number",a[t].name);n.addRows(s),c.drawChart(u,"ScatterChart",n,o)})},Rt.prototype.renderTimeline=function ne(r){var i=this;this.waitForLoaded(r,"timeline",function(){var t={legend:"none"};r.options.colors&&(t.colors=r.options.colors);var e=Y(Y(Ct,t),r.options.library||{}),n=new i.library.visualization.DataTable;n.addColumn({type:"string",id:"Name"}),n.addColumn({type:"date",id:"Start"}),n.addColumn({type:"date",id:"End"}),n.addRows(r.data),r.element.style.lineHeight="normal",i.drawChart(r,"Timeline",n,e)})},Rt.prototype.destroy=function Jt(t){t.chart&&t.chart.clearChart()},Rt.prototype.drawChart=function te(t,e,n,r){this.destroy(t),t.options.code&&window.console.log("var data = new google.visualization.DataTable("+n.toJSON()+");\nvar chart = new google.visualization."+e+"(element);\nchart.draw(data, "+JSON.stringify(r)+");"),t.chart=new this.library.visualization[e](t.element),Nt(function(){t.chart.draw(n,r)})},Rt.prototype.waitForLoaded=function re(t,e,n){var r=this;if(n||(n=e,e="corechart"),kt.push({pack:e,callback:n}),Tt[e])this.runCallbacks();else{Tt[e]=!0;var i={packages:[e],callback:function(){r.runCallbacks()}},o=t.__config();o.language&&(i.language=o.language),"corechart"===e&&o.mapsApiKey&&(i.mapsApiKey=o.mapsApiKey),this.library.charts.load("current",i)}},Rt.prototype.runCallbacks=function ie(){for(var t,e=0;e<kt.length;e++)t=kt[e],this.library.visualization&&("corechart"===t.pack&&this.library.visualization.LineChart||"timeline"===t.pack&&this.library.visualization.Timeline)&&(t.callback(),kt.splice(e,1),e--)},Rt.prototype.createDataTable=function mt(t,e){var n,r,i,o,a,s=[],l=[];for(n=0;n<t.length;n++)for(i=t[n],t[n].name=t[n].name||"Value",r=0;r<i.data.length;r++)o=i.data[r],s[a="datetime"===e?o[0].getTime():o[0]]||(s[a]=new Array(t.length),l.push(a)),s[a][n]=G(o[1]);var u,c=[],d=!0;for(r=0;r<l.length;r++)n=l[r],"datetime"===e?(u=new Date(G(n)),d=d&&Z(u)):u="number"===e?G(n):n,c.push([u].concat(s[n]));if("datetime"===e)c.sort(g);else if("number"===e){for(c.sort(m),n=0;n<c.length;n++)c[n][0]=p(c[n][0]);e="string"}var h=new this.library.visualization.DataTable;for(e="datetime"===e&&d?"date":e,h.addColumn(e,""),n=0;n<t.length;n++)h.addColumn("number",t[n].name);return h.addRows(c),h};var Ft=[],Ht=0,jt=4,Wt={},zt=[],Bt=function(t,e){return t="number"===e?G(t):"datetime"===e?K(t):p(t)},Vt=function(t,e){var n,r,i=[];for(r=0;r<t.length;r++)"bubble"===e?i.push([G(t[r][0]),G(t[r][1]),G(t[r][2])]):(n=Bt(t[r][0],e),i.push([n,G(t[r][1])]));return"datetime"===e?i.sort(g):"number"===e&&i.sort(m),i},qt=function qt(t,e,n){var r;if("string"==typeof t&&(r=t,!(t=document.getElementById(t))))throw new Error("No element with id "+r);this.element=t,this.options=Y(Ut.options,n||{}),this.dataSource=e,T(Ut.charts[t.id]=this,e),this.options.refresh&&this.startRefresh()};qt.prototype.getElement=function oe(){return this.element},qt.prototype.getDataSource=function ae(){return this.dataSource},qt.prototype.getData=function se(){return this.data},qt.prototype.getOptions=function le(){return this.options},qt.prototype.getChartObject=function ue(){return this.chart},qt.prototype.getAdapter=function ce(){return this.adapter},qt.prototype.updateData=function de(t,e){this.dataSource=t,e&&this.__updateOptions(e),T(this,t)},qt.prototype.setOptions=function he(t){this.__updateOptions(t),this.redraw()},qt.prototype.redraw=function fe(){T(this,this.rawData)},qt.prototype.refreshData=function pe(){if("string"==typeof this.dataSource){var t=-1===this.dataSource.indexOf("?")?"?":"&";T(this,this.dataSource+t+"_="+(new Date).getTime())}else"function"==typeof this.dataSource&&T(this,this.dataSource)},qt.prototype.startRefresh=function ge(){var t=this,e=this.options.refresh;if(e&&"string"!=typeof this.dataSource&&"function"!=typeof this.dataSource)throw new Error("Data source must be a URL or callback for refresh");if(!this.intervalId){if(!e)throw new Error("No refresh interval");this.intervalId=setInterval(function(){t.refreshData()},1e3*e)}},qt.prototype.stopRefresh=function me(){this.intervalId&&(clearInterval(this.intervalId),this.intervalId=null)},qt.prototype.toImage=function ye(t){if("chartjs"!==this.adapter)return null;if(t&&t.background&&"transparent"!==t.background){var e=this.chart.chart.canvas,n=this.chart.chart.ctx,r=document.createElement("canvas"),i=r.getContext("2d");return r.width=n.canvas.width,r.height=n.canvas.height,i.fillStyle=t.background,i.fillRect(0,0,r.width,r.height),i.drawImage(e,0,0),r.toDataURL("image/png")}return this.chart.toBase64Image()},qt.prototype.destroy=function Jt(){this.__adapterObject&&this.__adapterObject.destroy(this),this.__enterEvent&&t(this.element,"mouseover",this.__enterEvent),this.__leaveEvent&&t(this.element,"mouseout",this.__leaveEvent)},qt.prototype.__updateOptions=function ve(t){var e=t.refresh&&t.refresh!==this.options.refresh;this.options=Y(Ut.options,t),e&&(this.stopRefresh(),this.startRefresh())},qt.prototype.__render=function be(){this.data=this.__processData(),I(this.__chartName(),this)},qt.prototype.__config=function _e(){return Wt};var Ut={LineChart:function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),e.prototype=Object.create(t&&t.prototype),(e.prototype.constructor=e).prototype.__processData=function n(){return F(this)},e.prototype.__chartName=function r(){return"LineChart"},e}(qt),PieChart:function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),e.prototype=Object.create(t&&t.prototype),(e.prototype.constructor=e).prototype.__processData=function n(){return H(this)},e.prototype.__chartName=function r(){return"PieChart"},e}(qt),ColumnChart:function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),e.prototype=Object.create(t&&t.prototype),(e.prototype.constructor=e).prototype.__processData=function n(){return F(this,null,!0)},e.prototype.__chartName=function r(){return"ColumnChart"},e}(qt),BarChart:function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),e.prototype=Object.create(t&&t.prototype),(e.prototype.constructor=e).prototype.__processData=function n(){return F(this,null,!0)},e.prototype.__chartName=function r(){return"BarChart"},e}(qt),AreaChart:function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),e.prototype=Object.create(t&&t.prototype),(e.prototype.constructor=e).prototype.__processData=function n(){return F(this)},e.prototype.__chartName=function r(){return"AreaChart"},e}(qt),GeoChart:function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),e.prototype=Object.create(t&&t.prototype),(e.prototype.constructor=e).prototype.__processData=function n(){return H(this)},e.prototype.__chartName=function r(){return"GeoChart"},e}(qt),ScatterChart:function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),e.prototype=Object.create(t&&t.prototype),(e.prototype.constructor=e).prototype.__processData=function n(){return F(this,"number")},e.prototype.__chartName=function r(){return"ScatterChart"},e}(qt),BubbleChart:function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),e.prototype=Object.create(t&&t.prototype),(e.prototype.constructor=e).prototype.__processData=function n(){return F(this,"bubble")},e.prototype.__chartName=function r(){return"BubbleChart"},e}(qt),Timeline:function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),e.prototype=Object.create(t&&t.prototype),(e.prototype.constructor=e).prototype.__processData=function n(){var t,e=this.rawData;for(t=0;t<e.length;t++)e[t][1]=K(e[t][1]),e[t][2]=K(e[t][2]);return e},e.prototype.__chartName=function r(){return"Timeline"},e}(qt),charts:{},configure:function(t){for(var e in t)t.hasOwnProperty(e)&&(Wt[e]=t[e])},setDefaultOptions:function(t){Ut.options=t},eachChart:function(t){for(var e in Ut.charts)Ut.charts.hasOwnProperty(e)&&t(Ut.charts[e])},config:Wt,options:{},adapters:zt,addAdapter:A,use:function(t){return A(t),Ut}};return"undefined"==typeof window||window.Chartkick||(window.Chartkick=Ut),Ut["default"]=Ut}),function(t,e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e():"function"==typeof define&&define.amd?define(e):(t=t||self).Chart=e()}(this,function(){"use strict";function zo(){throw new Error("Dynamic requires are not currently supported by rollup-plugin-commonjs")}function t(t,e){return t(e={exports:{}},e.exports),e.exports}function e(t){return t&&t["default"]||t}function u(){for(var t={},e=Object.keys(Ge),n=e.length,r=0;r<n;r++)t[e[r]]={distance:-1,parent:null};return t}function s(t){var e=u(),n=[t];for(e[t].distance=0;n.length;)for(var r=n.pop(),i=Object.keys(Ge[r]),o=i.length,a=0;a<o;a++){var s=i[a],l=e[s];-1===l.distance&&(l.distance=e[r].distance+1,l.parent=r,n.unshift(s))}return e}function o(e,n){return function(t){return n(e(t))}}function l(t,e){for(var n=[e[t].parent,t],r=Ge[e[t].parent][t],i=e[t].parent;e[i].parent;)n.unshift(e[i].parent),r=o(Ge[e[i].parent][i],r),i=e[i].parent;return r.conversion=n,r}function i(e){var t=function(t){return t===undefined||null===t?t:(1<arguments.length&&(t=Array.prototype.slice.call(arguments)),e(t))};return"conversion"in e&&(t.conversion=e.conversion),t}function a(i){var t=function(t){if(t===undefined||null===t)return t;1<arguments.length&&(t=Array.prototype.slice.call(arguments));var e=i(t);if("object"==typeof e)for(var n=e.length,r=0;r<n;r++)e[r]=Math.round(e[r]);return e};return"conversion"in i&&(t.conversion=i.conversion),t}function n(t){if(t){var e=/^#([a-fA-F0-9]{3,4})$/i,n=/^#([a-fA-F0-9]{6}([a-fA-F0-9]{2})?)$/i,r=/^rgba?\(\s*([+-]?\d+)\s*,\s*([+-]?\d+)\s*,\s*([+-]?\d+)\s*(?:,\s*([+-]?[\d\.]+)\s*)?\)$/i,i=/^rgba?\(\s*([+-]?[\d\.]+)\%\s*,\s*([+-]?[\d\.]+)\%\s*,\s*([+-]?[\d\.]+)\%\s*(?:,\s*([+-]?[\d\.]+)\s*)?\)$/i,o=/(\w+)/,a=[0,0,0],s=1,l=t.match(e),u="";if(l){u=(l=l[1])[3];for(var c=0;c<a.length;c++)a[c]=parseInt(l[c]+l[c],16);u&&(s=Math.round(parseInt(u+u,16)/255*100)/100)}else if(l=t.match(n)){u=l[2],l=l[1];for(c=0;c<a.length;c++)a[c]=parseInt(l.slice(2*c,2*c+2),16);u&&(s=Math.round(parseInt(u,16)/255*100)/100)}else if(l=t.match(r)){for(c=0;c<a.length;c++)a[c]=parseInt(l[c+1]);s=parseFloat(l[4])}else if(l=t.match(i)){for(c=0;c<a.length;c++)a[c]=Math.round(2.55*parseFloat(l[c+1]));s=parseFloat(l[4])}else if(l=t.match(o)){if("transparent"==l[1])return[0,0,0,0];if(!(a=$e[l[1]]))return}for(c=0;c<a.length;c++)a[c]=S(a[c],0,255);return s=s||0==s?S(s,0,1):1,a[3]=s,a}}function r(t){if(t){var e=/^hsla?\(\s*([+-]?\d+)(?:deg)?\s*,\s*([+-]?[\d\.]+)%\s*,\s*([+-]?[\d\.]+)%\s*(?:,\s*([+-]?[\d\.]+)\s*)?\)/,n=t.match(e);if(n){var r=parseFloat(n[4]);return[S(parseInt(n[1]),0,360),S(parseFloat(n[2]),0,100),S(parseFloat(n[3]),0,100),S(isNaN(r)?1:r,0,1)]}}}function c(t){if(t){var e=/^hwb\(\s*([+-]?\d+)(?:deg)?\s*,\s*([+-]?[\d\.]+)%\s*,\s*([+-]?[\d\.]+)%\s*(?:,\s*([+-]?[\d\.]+)\s*)?\)/,n=t.match(e);if(n){var r=parseFloat(n[4]);return[S(parseInt(n[1]),0,360),S(parseFloat(n[2]),0,100),S(parseFloat(n[3]),0,100),S(isNaN(r)?1:r,0,1)]}}}function d(t){var e=n(t);return e&&e.slice(0,3)}function h(t){var e=r(t);return e&&e.slice(0,3)}function f(t){var e=n(t);return e?e[3]:(e=r(t))?e[3]:(e=c(t))?e[3]:void 0}function p(t,e){e=e!==undefined&&3===t.length?e:t[3];return"#"+T(t[0])+T(t[1])+T(t[2])+(0<=e&&e<1?T(Math.round(255*e)):"")}function g(t,e){return e<1||t[3]&&t[3]<1?m(t,e):"rgb("+t[0]+", "+t[1]+", "+t[2]+")"}function m(t,e){return e===undefined&&(e=t[3]!==undefined?t[3]:1),"rgba("+t[0]+", "+t[1]+", "+t[2]+", "+e+")"}function y(t,e){return e<1||t[3]&&t[3]<1?v(t,e):"rgb("+Math.round(t[0]/255*100)+"%, "+Math.round(t[1]/255*100)+"%, "+Math.round(t[2]/255*100)+"%)"}function v(t,e){return"rgba("+Math.round(t[0]/255*100)+"%, "+Math.round(t[1]/255*100)+"%, "+Math.round(t[2]/255*100)+"%, "+(e||t[3]||1)+")"}function b(t,e){return e<1||t[3]&&t[3]<1?_(t,e):"hsl("+t[0]+", "+t[1]+"%, "+t[2]+"%)"}function _(t,e){return e===undefined&&(e=t[3]!==undefined?t[3]:1),"hsla("+t[0]+", "+t[1]+"%, "+t[2]+"%, "+e+")"}function x(t,e){return e===undefined&&(e=t[3]!==undefined?t[3]:1),"hwb("+t[0]+", "+t[1]+"%, "+t[2]+"%"+(e!==undefined&&1!==e?", "+e:"")+")"}function w(t){return Je[t.slice(0,3)]}function S(t,e,n){return Math.min(Math.max(e,t),n)}function T(t){var e=t.toString(16).toUpperCase();return e.length<2?"0"+e:e}function k(t){return!t||an.isNullOrUndef(t.size)||an.isNullOrUndef(t.family)?null:(t.style?t.style+" ":"")+(t.weight?t.weight+" ":"")+t.size+"px "+t.family}function C(t,e,n,r){var i,o,a,s,l,u,c,d,h,f=Object.keys(n);for(i=0,o=f.length;i<o;++i)if(u=n[a=f[i]],e.hasOwnProperty(a)||(e[a]=u),(s=e[a])!==u&&"_"!==a[0]){if(t.hasOwnProperty(a)||(t[a]=s),(c=typeof u)===typeof(l=t[a]))if("string"===c){if((d=rn(l)).valid&&(h=rn(u)).valid){e[a]=h.mix(d,r).rgbString();continue}}else if(kn.isFinite(l)&&kn.isFinite(u)){e[a]=l+(u-l)*r;continue}e[a]=u}}function E(i,t){i._chartjs?i._chartjs.listeners.push(t):(Object.defineProperty(i,"_chartjs",{configurable:!0,enumerable:!1,value:{listeners:[t]}}),Fn.forEach(function(t){var n="onData"+t.charAt(0).toUpperCase()+t.slice(1),r=i[t];Object.defineProperty(i,t,{configurable:!0,enumerable:!1,value:function(){var e=Array.prototype.slice.call(arguments),t=r.apply(this,e);return kn.each(i._chartjs.listeners,function(t){"function"==typeof t[n]&&t[n].apply(t,e)}),t}})}))}function D(e,t){var n=e._chartjs;if(n){var r=n.listeners,i=r.indexOf(t);-1!==i&&r.splice(i,1),0<r.length||(Fn.forEach(function(t){delete e[t]}),delete e._chartjs)}}function A(t,e){var n=e.startAngle,r=e.endAngle,i=e.pixelMargin,o=i/e.outerRadius,a=e.x,s=e.y;t.beginPath(),t.arc(a,s,e.outerRadius,n-o,r+o),e.innerRadius>i?(o=i/e.innerRadius,t.arc(a,s,e.innerRadius-i,r+o,n-o,!0)):t.arc(a,s,i,r+Math.PI/2,n-Math.PI/2),t.closePath(),t.clip()}function M(t,e,n,r){var i,o=n.endAngle;for(r&&(n.endAngle=n.startAngle+Wn,A(t,n),n.endAngle=o,n.endAngle===n.startAngle&&n.fullCircles&&(n.endAngle+=Wn,n.fullCircles--)),t.beginPath(),t.arc(n.x,n.y,n.innerRadius,n.startAngle+Wn,n.startAngle,!0),i=0;i<n.fullCircles;++i)t.stroke();for(t.beginPath(),t.arc(n.x,n.y,e.outerRadius,n.startAngle,n.startAngle+Wn),i=0;i<n.fullCircles;++i)t.stroke()}function O(t,e,n){var r="inner"===e.borderAlign;r?(t.lineWidth=2*e.borderWidth,t.lineJoin="round"):(t.lineWidth=e.borderWidth,t.lineJoin="bevel"),n.fullCircles&&M(t,e,n,r),r&&A(t,n),t.beginPath(),t.arc(n.x,n.y,e.outerRadius,n.startAngle,n.endAngle),t.arc(n.x,n.y,n.innerRadius,n.endAngle,n.startAngle,!0),t.closePath(),t.stroke()}function I(t){var e=this._view;return!!e&&Math.abs(t-e.x)<e.radius+e.hitRadius}function P(t){var e=this._view;return!!e&&Math.abs(t-e.y)<e.radius+e.hitRadius}function L(t){return t&&t.width!==undefined}function N(t){var e,n,r,i,o;return L(t)?(o=t.width/2,e=t.x-o,n=t.x+o,r=Math.min(t.y,t.base),i=Math.max(t.y,t.base)):(o=t.height/2,e=Math.min(t.x,t.base),n=Math.max(t.x,t.base),r=t.y-o,i=t.y+o),{left:e,top:r,right:n,bottom:i}}function R(t,e,n){return t===e?n:t===n?e:t}function F(t){var e=t.borderSkipped,n={};return e&&(t.horizontal?t.base>t.x&&(e=R(e,"left","right")):t.base<t.y&&(e=R(e,"bottom","top")),n[e]=!0),n}function H(t,e,n){var r,i,o,a,s=t.borderWidth,l=F(t);return kn.isObject(s)?(r=+s.top||0,i=+s.right||0,o=+s.bottom||0,a=+s.left||0):r=i=o=a=+s||0,{t:l.top||r<0?0:n<r?n:r,r:l.right||i<0?0:e<i?e:i,b:l.bottom||o<0?0:n<o?n:o,l:l.left||a<0?0:e<a?e:a}}function j(t){var e=N(t),n=e.right-e.left,r=e.bottom-e.top,i=H(t,n/2,r/2);return{outer:{x:e.left,y:e.top,w:n,h:r},inner:{x:e.left+i.l,y:e.top+i.t,w:n-i.l-i.r,h:r-i.t-i.b}}}function W(t,e,n){var r=null===e,i=null===n,o=!(!t||r&&i)&&N(t);return o&&(r||e>=o.left&&e<=o.right)&&(i||n>=o.top&&n<=o.bottom)}function z(t,e){var n,r,i,o,a=t._length;for(i=1,o=e.length;i<o;++i)a=Math.min(a,Math.abs(e[i]-e[i-1]));for(i=0,o=t.getTicks().length;i<o;++i)r=t.getPixelForTick(i),a=0<i?Math.min(a,Math.abs(r-n)):a,n=r;return a}function B(t,e,n){var r,i,o=n.barThickness,a=e.stackCount,s=e.pixels[t],l=kn.isNullOrUndef(o)?z(e.scale,e.pixels):-1;return kn.isNullOrUndef(o)?(r=l*n.categoryPercentage,i=n.barPercentage):(r=o*a,i=1),{chunk:r/a,ratio:i,start:s-r/2}}function V(t,e,n){var r,i=e.pixels,o=i[t],a=0<t?i[t-1]:null,s=t<i.length-1?i[t+1]:null,l=n.categoryPercentage;return null===a&&(a=o-(null===s?e.end-e.start:s-o)),null===s&&(s=o+o-a),r=o-(o-Math.min(a,s))/2*l,{chunk:Math.abs(s-a)/2*l/e.stackCount,ratio:n.barPercentage,start:r}}function q(t,e){var n=t&&t.options.ticks||{},r=n.reverse,i=n.min===undefined?e:0,o=n.max===undefined?e:0;return{start:r?o:i,end:r?i:o}}function U(t,e,n){var r=n/2,i=q(t,r),o=q(e,r);return{top:o.end,right:i.end,bottom:o.start,left:i.start}}function Y(t){var e,n,r,i;return kn.isObject(t)?(e=t.top,n=t.right,r=t.bottom,i=t.left):e=n=r=i=t,{top:e,right:n,bottom:r,left:i}}function G(t,e){return t["native"]?{x:t.x,y:t.y}:kn.getRelativePosition(t,e)}function K(t,e){var n,r,i,o,a,s,l=t._getSortedVisibleDatasetMetas();for(r=0,o=l.length;r<o;++r)for(i=0,a=(n=l[r].data).length;i<a;++i)(s=n[i])._view.skip||e(s)}function X(t,e){var n=[];return K(t,function(t){t.inRange(e.x,e.y)&&n.push(t)}),n}function Q(t,r,i,o){var a=Number.POSITIVE_INFINITY,s=[];return K(t,function(t){if(!i||t.inRange(r.x,r.y)){var e=t.getCenterPoint(),n=o(r,e);n<a?(s=[t],a=n):n===a&&s.push(t)}}),s}function $(t){var i=-1!==t.indexOf("x"),o=-1!==t.indexOf("y");return function(t,e){var n=i?Math.abs(t.x-e.x):0,r=o?Math.abs(t.y-e.y):0;return Math.sqrt(Math.pow(n,2)+Math.pow(r,2))}}function Z(t,e,n){var r=G(e,t);n.axis=n.axis||"x";var i=$(n.axis),o=n.intersect?X(t,r):Q(t,r,!1,i),a=[];return o.length?(t._getSortedVisibleDatasetMetas().forEach(function(t){var e=t.data[o[0]._index];e&&!e._view.skip&&a.push(e)}),a):[]}function J(t,e){return kn.where(t,function(t){return t.pos===e})}function tt(t,i){return t.sort(function(t,e){var n=i?e:t,r=i?t:e;return n.weight===r.weight?n.index-r.index:n.weight-r.weight})}function et(t){var e,n,r,i=[];for(e=0,n=(t||[]).length;e<n;++e)r=t[e],i.push({index:e,box:r,pos:r.position,horizontal:r.isHorizontal(),weight:r.weight});return i}function nt(t,e){var n,r,i;for(n=0,r=t.length;n<r;++n)(i=t[n]).width=i.horizontal?i.box.fullWidth&&e.availableWidth:e.vBoxMaxWidth,i.height=i.horizontal&&e.hBoxMaxHeight}function rt(t){var e=et(t),n=tt(J(e,"left"),!0),r=tt(J(e,"right")),i=tt(J(e,"top"),!0),o=tt(J(e,"bottom"));return{leftAndTop:n.concat(i),rightAndBottom:r.concat(o),chartArea:J(e,"chartArea"),vertical:n.concat(r),horizontal:i.concat(o)}}function it(t,e,n,r){return Math.max(t[n],e[n])+Math.max(t[r],e[r])}function ot(t,e,n){var r,i,o=n.box,a=t.maxPadding;if(n.size&&(t[n.pos]-=n.size),n.size=n.horizontal?o.height:o.width,t[n.pos]+=n.size,o.getPadding){var s=o.getPadding();a.top=Math.max(a.top,s.top),a.left=Math.max(a.left,s.left),a.bottom=Math.max(a.bottom,s.bottom),a.right=Math.max(a.right,s.right)}if(r=e.outerWidth-it(a,t,"left","right"),i=e.outerHeight-it(a,t,"top","bottom"),r!==t.w||i!==t.h)return t.w=r,t.h=i,n.horizontal?r!==t.w:i!==t.h}function at(n){function t(t){var e=Math.max(r[t]-n[t],0);return n[t]+=e,e}var r=n.maxPadding;n.y+=t("top"),n.x+=t("left"),t("right"),t("bottom")}function st(t,n){function e(t){var e={left:0,top:0,right:0,bottom:0};return t.forEach(function(t){e[t]=Math.max(n[t],r[t])}),e}var r=n.maxPadding;return e(t?["left","right"]:["top","bottom"])}function lt(t,e,n){var r,i,o,a,s,l,u=[];for(r=0,i=t.length;r<i;++r)(a=(o=t[r]).box).update(o.width||e.w,o.height||e.h,st(o.horizontal,e)),ot(e,n,o)&&(l=!0,u.length&&(s=!0)),a.fullWidth||u.push(o);return s&&lt(u,e,n)||l}function ut(t,e,n){var r,i,o,a,s=n.padding,l=e.x,u=e.y;for(r=0,i=t.length;r<i;++r)a=(o=t[r]).box,o.horizontal?(a.left=a.fullWidth?s.left:e.left,a.right=a.fullWidth?n.outerWidth-s.right:e.left+e.w,a.top=u,a.bottom=u+a.height,a.width=a.right-a.left,u=a.bottom):(a.left=l,a.right=l+a.width,a.top=e.top,a.bottom=e.top+e.h,a.height=a.bottom-a.top,l=a.right);e.x=l,e.y=u}function ct(t,e){var n=kn.getStyle(t,e),r=n&&n.match(/^(\d+)(\.\d+)?px$/);return r?Number(r[1]):undefined}function dt(t,e){var n=t.style,r=t.getAttribute("height"),i=t.getAttribute("width");if(t[Ar]={initial:{height:r,width:i,style:{display:n.display,height:n.height,width:n.width}}},n.display=n.display||"block",null===i||""===i){var o=ct(t,"width");o!==undefined&&(t.width=o)}if(null===r||""===r)if(""===t.style.height)t.height=t.width/(e.options.aspectRatio||2);else{var a=ct(t,"height");o!==undefined&&(t.height=a)}return t}function ht(t,e,n){t.addEventListener(e,n,Rr)}function ft(t,e,n){t.removeEventListener(e,n,Rr)}function pt(t,e,n,r,i){return{type:t,chart:e,"native":i||null,x:n!==undefined?n:null,y:r!==undefined?r:null}}function gt(t,e){var n=Nr[t.type]||t.type,r=kn.getRelativePosition(t,e);return pt(n,e,r.x,r.y,t)}function mt(t,e){var n=!1,r=[];return function(){r=Array.prototype.slice.call(arguments),e=e||this,n||(n=!0,kn.requestAnimFrame.call(window,function(){n=!1,t.apply(e,r)}))}}function yt(t){var e=document.createElement("div");return e.className=t||"",e}function vt(t){var e=1e6,n=yt(Or),r=yt(Or+"-expand"),i=yt(Or+"-shrink");r.appendChild(yt()),i.appendChild(yt()),n.appendChild(r),n.appendChild(i),n._reset=function(){r.scrollLeft=e,r.scrollTop=e,i.scrollLeft=e,i.scrollTop=e};var o=function(){n._reset(),t()};return ht(r,"scroll",o.bind(r,"expand")),ht(i,"scroll",o.bind(i,"shrink")),n}function bt(e,n){var t=e[Ar]||(e[Ar]={}),r=t.renderProxy=function(t){t.animationName===Pr&&n()};kn.each(Lr,function(t){ht(e,t,r)}),t.reflow=!!e.offsetParent,e.classList.add(Ir)}function _t(e){var t=e[Ar]||{},n=t.renderProxy;n&&(kn.each(Lr,function(t){ft(e,t,n)}),delete t.renderProxy),e.classList.remove(Ir)}function xt(n,r,i){var o=n[Ar]||(n[Ar]={}),e=o.resizer=vt(mt(function(){if(o.resizer){var t=i.options.maintainAspectRatio&&n.parentNode,e=t?t.clientWidth:0;r(pt("resize",i)),t&&t.clientWidth<e&&i.canvas&&r(pt("resize",i))}}));bt(n,function(){if(o.resizer){var t=n.parentNode;t&&t!==e.parentNode&&t.insertBefore(e,t.firstChild),e._reset()}})}function wt(t){var e=t[Ar]||{},n=e.resizer;delete e.resizer,_t(t),n&&n.parentNode&&n.parentNode.removeChild(n)}function St(t,e){var n=t[Ar]||(t[Ar]={});if(!n.containsStyles){n.containsStyles=!0,e="/* Chart.js */\n"+e;var r=document.createElement("style");r.setAttribute("type","text/css"),r.appendChild(document.createTextNode(e)),t.appendChild(r)}}function Tt(t,e){return e&&(kn.isArray(e)?Array.prototype.push.apply(t,e):t.push(e)),t}function kt(t){return("string"==typeof t||t instanceof String)&&-1<t.indexOf("\n")?t.split("\n"):t}function Ct(t){var e=t._xScale,n=t._yScale||t._scale,r=t._index,i=t._datasetIndex,o=t._chart.getDatasetMeta(i).controller,a=o._getIndexScale(),s=o._getValueScale();return{xLabel:e?e.getLabelForIndex(r,i):"",yLabel:n?n.getLabelForIndex(r,i):"",label:a?""+a.getLabelForIndex(r,i):"",value:s?""+s.getLabelForIndex(r,i):"",index:r,datasetIndex:i,x:t._model.x,y:t._model.y}}function Et(t){var e=vn.global;return{xPadding:t.xPadding,yPadding:t.yPadding,xAlign:t.xAlign,yAlign:t.yAlign,rtl:t.rtl,textDirection:t.textDirection,bodyFontColor:t.bodyFontColor,_bodyFontFamily:Br(t.bodyFontFamily,e.defaultFontFamily),_bodyFontStyle:Br(t.bodyFontStyle,e.defaultFontStyle),_bodyAlign:t.bodyAlign,bodyFontSize:Br(t.bodyFontSize,e.defaultFontSize),bodySpacing:t.bodySpacing,titleFontColor:t.titleFontColor,_titleFontFamily:Br(t.titleFontFamily,e.defaultFontFamily),_titleFontStyle:Br(t.titleFontStyle,e.defaultFontStyle),titleFontSize:Br(t.titleFontSize,e.defaultFontSize),_titleAlign:t.titleAlign,titleSpacing:t.titleSpacing,titleMarginBottom:t.titleMarginBottom,footerFontColor:t.footerFontColor,_footerFontFamily:Br(t.footerFontFamily,e.defaultFontFamily),_footerFontStyle:Br(t.footerFontStyle,e.defaultFontStyle),footerFontSize:Br(t.footerFontSize,e.defaultFontSize),_footerAlign:t.footerAlign,footerSpacing:t.footerSpacing,footerMarginTop:t.footerMarginTop,caretSize:t.caretSize,cornerRadius:t.cornerRadius,backgroundColor:t.backgroundColor,opacity:0,legendColorBackground:t.multiKeyBackground,displayColors:t.displayColors,borderColor:t.borderColor,borderWidth:t.borderWidth}}function Dt(t,e){var n=t._chart.ctx,r=2*e.yPadding,i=0,o=e.body,a=o.reduce(function(t,e){return t+e.before.length+e.lines.length+e.after.length},0);a+=e.beforeBody.length+e.afterBody.length;var s=e.title.length,l=e.footer.length,u=e.titleFontSize,c=e.bodyFontSize,d=e.footerFontSize;r+=s*u,r+=s?(s-1)*e.titleSpacing:0,r+=s?e.titleMarginBottom:0,r+=a*c,r+=a?(a-1)*e.bodySpacing:0,r+=l?e.footerMarginTop:0,r+=l*d,r+=l?(l-1)*e.footerSpacing:0;var h=0,f=function(t){i=Math.max(i,n.measureText(t).width+h)};return n.font=kn.fontString(u,e._titleFontStyle,e._titleFontFamily),
kn.each(e.title,f),n.font=kn.fontString(c,e._bodyFontStyle,e._bodyFontFamily),kn.each(e.beforeBody.concat(e.afterBody),f),h=e.displayColors?c+2:0,kn.each(o,function(t){kn.each(t.before,f),kn.each(t.lines,f),kn.each(t.after,f)}),h=0,n.font=kn.fontString(d,e._footerFontStyle,e._footerFontFamily),kn.each(e.footer,f),{width:i+=2*e.xPadding,height:r}}function At(t,e){var n,r,i,o,a,s=t._model,l=t._chart,u=t._chart.chartArea,c="center",d="center";s.y<e.height?d="top":s.y>l.height-e.height&&(d="bottom");var h=(u.left+u.right)/2,f=(u.top+u.bottom)/2;"center"===d?(n=function(t){return t<=h},r=function(t){return h<t}):(n=function(t){return t<=e.width/2},r=function(t){return t>=l.width-e.width/2}),i=function(t){return t+e.width+s.caretSize+s.caretPadding>l.width},o=function(t){return t-e.width-s.caretSize-s.caretPadding<0},a=function(t){return t<=f?"top":"bottom"},n(s.x)?(c="left",i(s.x)&&(c="center",d=a(s.y))):r(s.x)&&(c="right",o(s.x)&&(c="center",d=a(s.y)));var p=t._options;return{xAlign:p.xAlign?p.xAlign:c,yAlign:p.yAlign?p.yAlign:d}}function Mt(t,e,n,r){var i=t.x,o=t.y,a=t.caretSize,s=t.caretPadding,l=t.cornerRadius,u=n.xAlign,c=n.yAlign,d=a+s,h=l+s;return"right"===u?i-=e.width:"center"===u&&((i-=e.width/2)+e.width>r.width&&(i=r.width-e.width),i<0&&(i=0)),"top"===c?o+=d:o-="bottom"===c?e.height+d:e.height/2,"center"===c?"left"===u?i+=d:"right"===u&&(i-=d):"left"===u?i-=h:"right"===u&&(i+=h),{x:i,y:o}}function Ot(t,e){return"center"===e?t.x+t.width/2:"right"===e?t.x+t.width-t.xPadding:t.x+t.xPadding}function It(t){return Tt([],kt(t))}function Pt(){return kn.merge({},[].slice.call(arguments),{merger:function(t,e,n,r){if("xAxes"===t||"yAxes"===t){var i,o,a,s=n[t].length;for(e[t]||(e[t]=[]),i=0;i<s;++i)a=n[t][i],o=Kr(a.type,"xAxes"===t?"category":"linear"),i>=e[t].length&&e[t].push({}),!e[t][i].type||a.type&&a.type!==e[t][i].type?kn.merge(e[t][i],[zr.getScaleDefaults(o),a]):kn.merge(e[t][i],a)}else kn._merger(t,e,n,r)}})}function Lt(){return kn.merge({},[].slice.call(arguments),{merger:function(t,e,n,r){var i=e[t]||{},o=n[t];"scales"===t?e[t]=Pt(i,o):"scale"===t?e[t]=kn.merge(i,[zr.getScaleDefaults(o.type),o]):kn._merger(t,e,n,r)}})}function Nt(t){var e=(t=t||{}).data=t.data||{};return e.datasets=e.datasets||[],e.labels=e.labels||[],t.options=Lt(vn.global,vn[t.type],t.options||{}),t}function Rt(e){var t=e.options;kn.each(e.scales,function(t){kr.removeBox(e,t)}),t=Lt(vn.global,vn[e.config.type],t),e.options=e.config.options=t,e.ensureScalesHaveIDs(),e.buildOrUpdateScales(),e.tooltip._options=t.tooltips,e.tooltip.initialize()}function Ft(t,e,n){for(var r,i=function(t){return t.id===r};r=e+n++,0<=kn.findIndex(t,i););return r}function Ht(t){return"top"===t||"bottom"===t}function jt(n,r){return function(t,e){return t[n]===e[n]?t[r]-e[r]:t[n]-e[n]}}function Wt(){throw new Error("This method is not implemented: either no adapter can be found or an incomplete integration was provided.")}function zt(t){this.options=t||{}}function Bt(t,e){for(var n=[],r=t.length/e,i=0,o=t.length;i<o;i+=r)n.push(t[Math.floor(i)]);return n}function Vt(t,e,n){var r,i=t.getTicks().length,o=Math.min(e,i-1),a=t.getPixelForTick(o),s=t._startPixel,l=t._endPixel,u=1e-6;if(!(n&&(r=1===i?Math.max(a-s,l-a):0===e?(t.getPixelForTick(1)-a)/2:(a-t.getPixelForTick(o-1))/2,(a+=o<e?r:-r)<s-u||l+u<a)))return a}function qt(t,i){kn.each(t,function(t){var e,n=t.gc,r=n.length/2;if(i<r){for(e=0;e<r;++e)delete t.data[n[e]];n.splice(0,r)}})}function Ut(t,e,n,r){function i(t){return{width:b[t]||0,height:_[t]||0,offset:x[t]||0}}var o,a,s,l,u,c,d,h,f,p,g,m,y,v=n.length,b=[],_=[],x=[];for(o=0;o<v;++o){if(l=n[o].label,u=n[o].major?e.major:e.minor,t.font=c=u.string,d=r[c]=r[c]||{data:{},gc:[]},h=u.lineHeight,f=p=0,ei(l)||ti(l)){if(ti(l))for(a=0,s=l.length;a<s;++a)g=l[a],ei(g)||ti(g)||(f=kn.measureText(t,d.data,d.gc,f,g),p+=h)}else f=kn.measureText(t,d.data,d.gc,f,l),p=h;b.push(f),_.push(p),x.push(h/2)}return qt(r,v),m=b.indexOf(Math.max.apply(null,b)),y=_.indexOf(Math.max.apply(null,_)),{first:i(0),last:i(v-1),widest:i(m),highest:i(y)}}function Yt(t){return t.drawTicks?t.tickMarkLength:0}function Gt(t){var e,n;return t.display?(e=kn.options._parseFont(t),n=kn.options.toPadding(t.padding),e.lineHeight+n.height):0}function Kt(t,e){return kn.extend(kn.options._parseFont({fontFamily:ni(e.fontFamily,t.fontFamily),fontSize:ni(e.fontSize,t.fontSize),fontStyle:ni(e.fontStyle,t.fontStyle),lineHeight:ni(e.lineHeight,t.lineHeight)}),{color:kn.options.resolve([e.fontColor,t.fontColor,vn.global.defaultFontColor])})}function Xt(t){var e=Kt(t,t.minor);return{minor:e,major:t.major.enabled?Kt(t,t.major):e}}function Qt(t){var e,n,r,i=[];for(n=0,r=t.length;n<r;++n)"undefined"!=typeof(e=t[n])._index&&i.push(e);return i}function $t(t){var e,n,r=t.length;if(r<2)return!1;for(n=t[0],e=1;e<r;++e)if(t[e]-t[e-1]!==n)return!1;return n}function Zt(t,e,n,r){var i,o,a,s,l=$t(t),u=(e.length-1)/r;if(!l)return Math.max(u,1);for(a=0,s=(i=kn.math._factorize(l)).length-1;a<s;a++)if(u<(o=i[a]))return o;return Math.max(u,1)}function Jt(t){var e,n,r=[];for(e=0,n=t.length;e<n;e++)t[e].major&&r.push(e);return r}function te(t,e,n){var r,i,o=0,a=e[0];for(n=Math.ceil(n),r=0;r<t.length;r++)i=t[r],r===a?(i._index=r,a=e[++o*n]):delete i.label}function ee(t,e,n,r){var i,o,a,s,l=ni(n,0),u=Math.min(ni(r,t.length),t.length),c=0;for(e=Math.ceil(e),r&&(e=(i=r-n)/Math.floor(i/e)),s=l;s<0;)c++,s=Math.round(l+c*e);for(o=Math.max(l,0);o<u;o++)a=t[o],o===s?(a._index=o,c++,s=Math.round(l+c*e)):delete a.label}function ne(t,e){var n,r,i,o,a=[],s=1e-14,l=t.stepSize,u=l||1,c=t.maxTicks-1,d=t.min,h=t.max,f=t.precision,p=e.min,g=e.max,m=kn.niceNum((g-p)/c/u)*u;if(m<s&&di(d)&&di(h))return[p,g];c<(o=Math.ceil(g/m)-Math.floor(p/m))&&(m=kn.niceNum(o*m/c/u)*u),l||di(f)?n=Math.pow(10,kn._decimalPlaces(m)):(n=Math.pow(10,f),m=Math.ceil(m*n)/n),r=Math.floor(p/m)*m,i=Math.ceil(g/m)*m,l&&(!di(d)&&kn.almostWhole(d/m,m/1e3)&&(r=d),!di(h)&&kn.almostWhole(h/m,m/1e3)&&(i=h)),o=(i-r)/m,o=kn.almostEquals(o,Math.round(o),m/1e3)?Math.round(o):Math.ceil(o),r=Math.round(r*n)/n,i=Math.round(i*n)/n,a.push(di(d)?r:d);for(var y=1;y<o;++y)a.push(Math.round((r+y*m)*n)/n);return a.push(di(h)?i:h),a}function re(t,e,n){var r=[n.type,e===undefined&&n.stack===undefined?n.index:"",n.stack].join(".");return t[r]===undefined&&(t[r]={pos:[],neg:[]}),t[r]}function ie(t,e,n,r){var i,o,a=t.options,s=re(e,a.stacked,n),l=s.pos,u=s.neg,c=r.length;for(i=0;i<c;++i)o=t._parseValue(r[i]),isNaN(o.min)||isNaN(o.max)||n.data[i].hidden||(l[i]=l[i]||0,u[i]=u[i]||0,a.relativePoints?l[i]=100:o.min<0||o.max<0?u[i]+=o.min:l[i]+=o.max)}function oe(t,e,n){var r,i,o=n.length;for(r=0;r<o;++r)i=t._parseValue(n[r]),isNaN(i.min)||isNaN(i.max)||e.data[r].hidden||(t.min=Math.min(t.min,i.min),t.max=Math.max(t.max,i.max))}function ae(t,e){var n,r,i=[],o=vi(t.min,Math.pow(10,Math.floor(bi(e.min)))),a=Math.floor(bi(e.max)),s=Math.ceil(e.max/Math.pow(10,a));0===o?(n=Math.floor(bi(e.minNotZero)),r=Math.floor(e.minNotZero/Math.pow(10,n)),i.push(o),o=r*Math.pow(10,n)):(n=Math.floor(bi(o)),r=Math.floor(o/Math.pow(10,n)));for(var l=n<0?Math.pow(10,Math.abs(n)):1;i.push(o),10===++r&&(r=1,l=0<=++n?1:l),o=Math.round(r*Math.pow(10,n)*l)/l,n<a||n===a&&r<s;);var u=vi(t.max,o);return i.push(u),i}function se(t,e){return kn.isFinite(t)&&0<=t?t:e}function le(t){var e=t.ticks;return e.display&&t.display?Si(e.fontSize,vn.global.defaultFontSize)+2*e.backdropPaddingY:0}function ue(t,e,n){return kn.isArray(n)?{w:kn.longestText(t,t.font,n),h:n.length*e}:{w:t.measureText(n).width,h:e}}function ce(t,e,n,r,i){return t===r||t===i?{start:e-n/2,end:e+n/2}:t<r||i<t?{start:e-n,end:e}:{start:e,end:e+n}}function de(t){var e,n,r,i=kn.options._parseFont(t.options.pointLabels),o={l:0,r:t.width,t:0,b:t.height-t.paddingTop},a={};t.ctx.font=i.string,t._pointLabelSizes=[];var s=t.chart.data.labels.length;for(e=0;e<s;e++){r=t.getPointPosition(e,t.drawingArea+5),n=ue(t.ctx,i.lineHeight,t.pointLabels[e]),t._pointLabelSizes[e]=n;var l=t.getIndexAngle(e),u=kn.toDegrees(l)%360,c=ce(u,r.x,n.w,0,180),d=ce(u,r.y,n.h,90,270);c.start<o.l&&(o.l=c.start,a.l=l),c.end>o.r&&(o.r=c.end,a.r=l),d.start<o.t&&(o.t=d.start,a.t=l),d.end>o.b&&(o.b=d.end,a.b=l)}t.setReductions(t.drawingArea,o,a)}function he(t){return 0===t||180===t?"center":t<180?"left":"right"}function fe(t,e,n,r){var i,o,a=n.y+r/2;if(kn.isArray(e))for(i=0,o=e.length;i<o;++i)t.fillText(e[i],n.x,a),a+=r;else t.fillText(e,n.x,a)}function pe(t,e,n){90===t||270===t?n.y-=e.h/2:(270<t||t<90)&&(n.y-=e.h)}function ge(t){var e=t.ctx,n=t.options,r=n.pointLabels,i=le(n),o=t.getDistanceFromCenterForValue(n.ticks.reverse?t.min:t.max),a=kn.options._parseFont(r);e.save(),e.font=a.string,e.textBaseline="middle";for(var s=t.chart.data.labels.length-1;0<=s;s--){var l=0===s?i/2:0,u=t.getPointPosition(s,o+l+5),c=Ti(r.fontColor,s,vn.global.defaultFontColor);e.fillStyle=c;var d=t.getIndexAngle(s),h=kn.toDegrees(d);e.textAlign=he(h),pe(h,t._pointLabelSizes[s],u),fe(e,t.pointLabels[s],u,a.lineHeight)}e.restore()}function me(t,e,n,r){var i,o=t.ctx,a=e.circular,s=t.chart.data.labels.length,l=Ti(e.color,r-1),u=Ti(e.lineWidth,r-1);if((a||s)&&l&&u){if(o.save(),o.strokeStyle=l,o.lineWidth=u,o.setLineDash&&(o.setLineDash(e.borderDash||[]),o.lineDashOffset=e.borderDashOffset||0),o.beginPath(),a)o.arc(t.xCenter,t.yCenter,n,0,2*Math.PI);else{i=t.getPointPosition(0,n),o.moveTo(i.x,i.y);for(var c=1;c<s;c++)i=t.getPointPosition(c,n),o.lineTo(i.x,i.y)}o.closePath(),o.stroke(),o.restore()}}function ye(t){return kn.isNumber(t)?t:0}function ve(t,e){return t-e}function be(t){var e,n,r,i={},o=[];for(e=0,n=t.length;e<n;++e)i[r=t[e]]||(i[r]=!0,o.push(r));return o}function _e(t){return kn.valueOrDefault(t.time.min,t.ticks.min)}function xe(t){return kn.valueOrDefault(t.time.max,t.ticks.max)}function we(t,e,n,r){if("linear"===r||!t.length)return[{time:e,pos:0},{time:n,pos:1}];var i,o,a,s,l,u=[],c=[e];for(i=0,o=t.length;i<o;++i)e<(s=t[i])&&s<n&&c.push(s);for(c.push(n),i=0,o=c.length;i<o;++i)l=c[i+1],a=c[i-1],s=c[i],a!==undefined&&l!==undefined&&Math.round((l+a)/2)===s||u.push({time:s,pos:i/(o-1)});return u}function Se(t,e,n){for(var r,i,o,a=0,s=t.length-1;0<=a&&a<=s;){if(i=t[(r=a+s>>1)-1]||null,o=t[r],!i)return{lo:null,hi:o};if(o[e]<n)a=r+1;else{if(!(i[e]>n))return{lo:i,hi:o};s=r-1}}return{lo:o,hi:null}}function Te(t,e,n,r){var i=Se(t,e,n),o=i.lo?i.hi?i.lo:t[t.length-2]:t[0],a=i.lo?i.hi?i.hi:t[t.length-1]:t[1],s=a[e]-o[e],l=s?(n-o[e])/s:0,u=(a[r]-o[r])*l;return o[r]+u}function ke(t,e){var n=t._adapter,r=t.options.time,i=r.parser,o=i||r.format,a=e;return"function"==typeof i&&(a=i(a)),kn.isFinite(a)||(a="string"==typeof o?n.parse(a,o):n.parse(a)),null!==a?+a:(i||"function"!=typeof o||(a=o(e),kn.isFinite(a)||(a=n.parse(a))),a)}function Ce(t,e){if(kn.isNullOrUndef(e))return null;var n=t.options.time,r=ke(t,t.getRightValue(e));return null===r||n.round&&(r=+t._adapter.startOf(r,n.round)),r}function Ee(t,e,n,r){var i,o,a,s=Ni.length;for(i=Ni.indexOf(t);i<s-1;++i)if(a=(o=Li[Ni[i]]).steps?o.steps:Pi,o.common&&Math.ceil((n-e)/(a*o.size))<=r)return Ni[i];return Ni[s-1]}function De(t,e,n,r,i){var o,a;for(o=Ni.length-1;o>=Ni.indexOf(n);o--)if(a=Ni[o],Li[a].common&&t._adapter.diff(i,r,a)>=e-1)return a;return Ni[n?Ni.indexOf(n):0]}function Ae(t){for(var e=Ni.indexOf(t)+1,n=Ni.length;e<n;++e)if(Li[Ni[e]].common)return Ni[e]}function Me(t,e,n,r){var i,o=t._adapter,a=t.options,s=a.time,l=s.unit||Ee(s.minUnit,e,n,r),u=Mi([s.stepSize,s.unitStepSize,1]),c="week"===l&&s.isoWeekday,d=e,h=[];if(c&&(d=+o.startOf(d,"isoWeek",c)),d=+o.startOf(d,c?"day":l),o.diff(n,e,l)>1e5*u)throw e+" and "+n+" are too far apart with stepSize of "+u+" "+l;for(i=d;i<n;i=+o.add(i,u,l))h.push(i);return i!==n&&"ticks"!==a.bounds||h.push(i),h}function Oe(t,e,n,r,i){var o,a,s=0,l=0;return i.offset&&e.length&&(o=Te(t,"time",e[0],"pos"),s=1===e.length?1-o:(Te(t,"time",e[1],"pos")-o)/2,a=Te(t,"time",e[e.length-1],"pos"),l=1===e.length?a:(a-Te(t,"time",e[e.length-2],"pos"))/2),{start:s,end:l,factor:1/(s+1+l)}}function Ie(t,e,n,r){var i,o,a=t._adapter,s=+a.startOf(e[0].value,r),l=e[e.length-1].value;for(i=s;i<=l;i=+a.add(i,1,r))0<=(o=n[i])&&(e[o].major=!0);return e}function Pe(t,e,n){var r,i,o=[],a={},s=e.length;for(r=0;r<s;++r)a[i=e[r]]=r,o.push({value:i,major:!1});return 0!==s&&n?Ie(t,o,a,n):o}function Le(t,e,n){var r,i=t._model||{},o=i.fill;if(o===undefined&&(o=!!i.backgroundColor),!1===o||null===o)return!1;if(!0===o)return"origin";if(r=parseFloat(o,10),isFinite(r)&&Math.floor(r)===r)return"-"!==o[0]&&"+"!==o[0]||(r=e+r),!(r===e||r<0||n<=r)&&r;switch(o){case"bottom":return"start";case"top":return"end";case"zero":return"origin";case"origin":case"start":case"end":return o;default:return!1}}function Ne(t){var e,n=t.el._model||{},r=t.el._scale||{},i=t.fill,o=null;if(isFinite(i))return null;if("start"===i?o=n.scaleBottom===undefined?r.bottom:n.scaleBottom:"end"===i?o=n.scaleTop===undefined?r.top:n.scaleTop:n.scaleZero!==undefined?o=n.scaleZero:r.getBasePixel&&(o=r.getBasePixel()),o!==undefined&&null!==o){if(o.x!==undefined&&o.y!==undefined)return o;if(kn.isFinite(o))return{x:(e=r.isHorizontal())?o:null,y:e?null:o}}return null}function Re(t){var e,n,r,i,o,a=t.el._scale,s=a.options,l=a.chart.data.labels.length,u=t.fill,c=[];if(!l)return null;for(e=s.ticks.reverse?a.max:a.min,n=s.ticks.reverse?a.min:a.max,r=a.getPointPositionForValue(0,e),i=0;i<l;++i)o="start"===u||"end"===u?a.getPointPositionForValue(i,"start"===u?e:n):a.getBasePosition(i),s.gridLines.circular&&(o.cx=r.x,o.cy=r.y,o.angle=a.getIndexAngle(i)-Math.PI/2),c.push(o);return c}function Fe(t){return(t.el._scale||{}).getPointPositionForValue?Re(t):Ne(t)}function He(t,e,n){var r,i=t[e].fill,o=[e];if(!n)return i;for(;!1!==i&&-1===o.indexOf(i);){if(!isFinite(i))return i;if(!(r=t[i]))return!1;if(r.visible)return i;o.push(i),i=r.fill}return!1}function je(t){var e=t.fill,n="dataset";return!1===e?null:(isFinite(e)||(n="boundary"),Bi[n](t))}function We(t){return t&&!t.skip}function ze(t,e,n,r,i){var o,a,s,l;if(r&&i){for(t.moveTo(e[0].x,e[0].y),o=1;o<r;++o)kn.canvas.lineTo(t,e[o-1],e[o]);if(n[0].angle===undefined)for(t.lineTo(n[i-1].x,n[i-1].y),o=i-1;0<o;--o)kn.canvas.lineTo(t,n[o],n[o-1],!0);else for(a=n[0].cx,s=n[0].cy,l=Math.sqrt(Math.pow(n[0].x-a,2)+Math.pow(n[0].y-s,2)),o=i-1;0<o;--o)t.arc(a,s,l,n[o].angle,n[o-1].angle,!0)}}function Be(t,e,n,r,i,o){var a,s,l,u,c,d,h,f,p=e.length,g=r.spanGaps,m=[],y=[],v=0,b=0;for(t.beginPath(),a=0,s=p;a<s;++a)c=n(u=e[l=a%p]._view,l,r),d=We(u),h=We(c),o&&f===undefined&&d&&(s=p+(f=a+1)),d&&h?(v=m.push(u),b=y.push(c)):v&&b&&(g?(d&&m.push(u),h&&y.push(c)):(ze(t,m,y,v,b),v=b=0,m=[],y=[]));ze(t,m,y,v,b),t.closePath(),t.fillStyle=i,t.fill()}function Ve(t,e){return t.usePointStyle&&t.boxWidth>e?e:t.boxWidth}function qe(t,e){var n=new Gi({ctx:t.ctx,options:e,chart:t});kr.configure(t,n,e),kr.addBox(t,n),t.legend=n}function Ue(t,e){var n=new Qi({ctx:t.ctx,options:e,chart:t});kr.configure(t,n,e),kr.addBox(t,n),t.titleBlock=n}"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self&&self;var Ye={aliceblue:[240,248,255],antiquewhite:[250,235,215],aqua:[0,255,255],aquamarine:[127,255,212],azure:[240,255,255],beige:[245,245,220],bisque:[255,228,196],black:[0,0,0],blanchedalmond:[255,235,205],blue:[0,0,255],blueviolet:[138,43,226],brown:[165,42,42],burlywood:[222,184,135],cadetblue:[95,158,160],chartreuse:[127,255,0],chocolate:[210,105,30],coral:[255,127,80],cornflowerblue:[100,149,237],cornsilk:[255,248,220],crimson:[220,20,60],cyan:[0,255,255],darkblue:[0,0,139],darkcyan:[0,139,139],darkgoldenrod:[184,134,11],darkgray:[169,169,169],darkgreen:[0,100,0],darkgrey:[169,169,169],darkkhaki:[189,183,107],darkmagenta:[139,0,139],darkolivegreen:[85,107,47],darkorange:[255,140,0],darkorchid:[153,50,204],darkred:[139,0,0],darksalmon:[233,150,122],darkseagreen:[143,188,143],darkslateblue:[72,61,139],darkslategray:[47,79,79],darkslategrey:[47,79,79],darkturquoise:[0,206,209],darkviolet:[148,0,211],deeppink:[255,20,147],deepskyblue:[0,191,255],dimgray:[105,105,105],dimgrey:[105,105,105],dodgerblue:[30,144,255],firebrick:[178,34,34],floralwhite:[255,250,240],forestgreen:[34,139,34],fuchsia:[255,0,255],gainsboro:[220,220,220],ghostwhite:[248,248,255],gold:[255,215,0],goldenrod:[218,165,32],gray:[128,128,128],green:[0,128,0],greenyellow:[173,255,47],grey:[128,128,128],honeydew:[240,255,240],hotpink:[255,105,180],indianred:[205,92,92],indigo:[75,0,130],ivory:[255,255,240],khaki:[240,230,140],lavender:[230,230,250],lavenderblush:[255,240,245],lawngreen:[124,252,0],lemonchiffon:[255,250,205],lightblue:[173,216,230],lightcoral:[240,128,128],lightcyan:[224,255,255],lightgoldenrodyellow:[250,250,210],lightgray:[211,211,211],lightgreen:[144,238,144],lightgrey:[211,211,211],lightpink:[255,182,193],lightsalmon:[255,160,122],lightseagreen:[32,178,170],lightskyblue:[135,206,250],lightslategray:[119,136,153],lightslategrey:[119,136,153],lightsteelblue:[176,196,222],lightyellow:[255,255,224],lime:[0,255,0],limegreen:[50,205,50],linen:[250,240,230],magenta:[255,0,255],maroon:[128,0,0],mediumaquamarine:[102,205,170],mediumblue:[0,0,205],mediumorchid:[186,85,211],mediumpurple:[147,112,219],mediumseagreen:[60,179,113],mediumslateblue:[123,104,238],mediumspringgreen:[0,250,154],mediumturquoise:[72,209,204],mediumvioletred:[199,21,133],midnightblue:[25,25,112],mintcream:[245,255,250],mistyrose:[255,228,225],moccasin:[255,228,181],navajowhite:[255,222,173],navy:[0,0,128],oldlace:[253,245,230],olive:[128,128,0],olivedrab:[107,142,35],orange:[255,165,0],orangered:[255,69,0],orchid:[218,112,214],palegoldenrod:[238,232,170],palegreen:[152,251,152],paleturquoise:[175,238,238],palevioletred:[219,112,147],papayawhip:[255,239,213],peachpuff:[255,218,185],peru:[205,133,63],pink:[255,192,203],plum:[221,160,221],powderblue:[176,224,230],purple:[128,0,128],rebeccapurple:[102,51,153],red:[255,0,0],rosybrown:[188,143,143],royalblue:[65,105,225],saddlebrown:[139,69,19],salmon:[250,128,114],sandybrown:[244,164,96],seagreen:[46,139,87],seashell:[255,245,238],sienna:[160,82,45],silver:[192,192,192],skyblue:[135,206,235],slateblue:[106,90,205],slategray:[112,128,144],slategrey:[112,128,144],snow:[255,250,250],springgreen:[0,255,127],steelblue:[70,130,180],tan:[210,180,140],teal:[0,128,128],thistle:[216,191,216],tomato:[255,99,71],turquoise:[64,224,208],violet:[238,130,238],wheat:[245,222,179],white:[255,255,255],whitesmoke:[245,245,245],yellow:[255,255,0],yellowgreen:[154,205,50]},Ge=t(function(t){function a(t,e){return Math.pow(t[0]-e[0],2)+Math.pow(t[1]-e[1],2)+Math.pow(t[2]-e[2],2)}var s={};for(var e in Ye)Ye.hasOwnProperty(e)&&(s[Ye[e]]=e);var l=t.exports={rgb:{channels:3,labels:"rgb"},hsl:{channels:3,labels:"hsl"},hsv:{channels:3,labels:"hsv"},hwb:{channels:3,labels:"hwb"},cmyk:{channels:4,labels:"cmyk"},xyz:{channels:3,labels:"xyz"},lab:{channels:3,labels:"lab"},lch:{channels:3,labels:"lch"},hex:{channels:1,labels:["hex"]},keyword:{channels:1,labels:["keyword"]},ansi16:{channels:1,labels:["ansi16"]},ansi256:{channels:1,labels:["ansi256"]},hcg:{channels:3,labels:["h","c","g"]},apple:{channels:3,labels:["r16","g16","b16"]},gray:{channels:1,labels:["gray"]}};for(var n in l)if(l.hasOwnProperty(n)){if(!("channels"in l[n]))throw new Error("missing channels property: "+n);if(!("labels"in l[n]))throw new Error("missing channel labels property: "+n);if(l[n].labels.length!==l[n].channels)throw new Error("channel and label counts mismatch: "+n);var r=l[n].channels,i=l[n].labels;delete l[n].channels,delete l[n].labels,Object.defineProperty(l[n],"channels",{value:r}),Object.defineProperty(l[n],"labels",{value:i})}l.rgb.hsl=function(t){var e,n,r=t[0]/255,i=t[1]/255,o=t[2]/255,a=Math.min(r,i,o),s=Math.max(r,i,o),l=s-a;return s===a?e=0:r===s?e=(i-o)/l:i===s?e=2+(o-r)/l:o===s&&(e=4+(r-i)/l),(e=Math.min(60*e,360))<0&&(e+=360),n=(a+s)/2,[e,100*(s===a?0:n<=.5?l/(s+a):l/(2-s-a)),100*n]},l.rgb.hsv=function(t){var e,n,r,i,o,a=t[0]/255,s=t[1]/255,l=t[2]/255,u=Math.max(a,s,l),c=u-Math.min(a,s,l),d=function(t){return(u-t)/6/c+.5};return 0===c?i=o=0:(o=c/u,e=d(a),n=d(s),r=d(l),a===u?i=r-n:s===u?i=1/3+e-r:l===u&&(i=2/3+n-e),i<0?i+=1:1<i&&(i-=1)),[360*i,100*o,100*u]},l.rgb.hwb=function(t){var e=t[0],n=t[1],r=t[2];return[l.rgb.hsl(t)[0],100*(1/255*Math.min(e,Math.min(n,r))),100*(r=1-1/255*Math.max(e,Math.max(n,r)))]},l.rgb.cmyk=function(t){var e,n=t[0]/255,r=t[1]/255,i=t[2]/255;return[100*((1-n-(e=Math.min(1-n,1-r,1-i)))/(1-e)||0),100*((1-r-e)/(1-e)||0),100*((1-i-e)/(1-e)||0),100*e]},l.rgb.keyword=function(t){var e=s[t];if(e)return e;var n,r=Infinity;for(var i in Ye)if(Ye.hasOwnProperty(i)){var o=a(t,Ye[i]);o<r&&(r=o,n=i)}return n},l.keyword.rgb=function(t){return Ye[t]},l.rgb.xyz=function(t){var e=t[0]/255,n=t[1]/255,r=t[2]/255;return[100*(.4124*(e=.04045<e?Math.pow((e+.055)/1.055,2.4):e/12.92)+.3576*(n=.04045<n?Math.pow((n+.055)/1.055,2.4):n/12.92)+.1805*(r=.04045<r?Math.pow((r+.055)/1.055,2.4):r/12.92)),100*(.2126*e+.7152*n+.0722*r),100*(.0193*e+.1192*n+.9505*r)]},l.rgb.lab=function(t){var e=l.rgb.xyz(t),n=e[0],r=e[1],i=e[2];return r/=100,i/=108.883,n=.008856<(n/=95.047)?Math.pow(n,1/3):7.787*n+16/116,[116*(r=.008856<r?Math.pow(r,1/3):7.787*r+16/116)-16,500*(n-r),200*(r-(i=.008856<i?Math.pow(i,1/3):7.787*i+16/116))]},l.hsl.rgb=function(t){var e,n,r,i,o,a=t[0]/360,s=t[1]/100,l=t[2]/100;if(0===s)return[o=255*l,o,o];e=2*l-(n=l<.5?l*(1+s):l+s-l*s),i=[0,0,0];for(var u=0;u<3;u++)(r=a+1/3*-(u-1))<0&&r++,1<r&&r--,o=6*r<1?e+6*(n-e)*r:2*r<1?n:3*r<2?e+(n-e)*(2/3-r)*6:e,i[u]=255*o;return i},l.hsl.hsv=function(t){var e=t[0],n=t[1]/100,r=t[2]/100,i=n,o=Math.max(r,.01);return n*=(r*=2)<=1?r:2-r,i*=o<=1?o:2-o,[e,100*(0===r?2*i/(o+i):2*n/(r+n)),100*((r+n)/2)]},l.hsv.rgb=function(t){var e=t[0]/60,n=t[1]/100,r=t[2]/100,i=Math.floor(e)%6,o=e-Math.floor(e),a=255*r*(1-n),s=255*r*(1-n*o),l=255*r*(1-n*(1-o));switch(r*=255,i){case 0:return[r,l,a];case 1:return[s,r,a];case 2:return[a,r,l];case 3:return[a,s,r];case 4:return[l,a,r];case 5:return[r,a,s]}},l.hsv.hsl=function(t){var e,n,r,i=t[0],o=t[1]/100,a=t[2]/100,s=Math.max(a,.01);return r=(2-o)*a,n=o*s,[i,100*(n=(n/=(e=(2-o)*s)<=1?e:2-e)||0),100*(r/=2)]},l.hwb.rgb=function(t){var e,n,r,i,o,a,s,l=t[0]/360,u=t[1]/100,c=t[2]/100,d=u+c;switch(1<d&&(u/=d,c/=d),r=6*l-(e=Math.floor(6*l)),0!=(1&e)&&(r=1-r),i=u+r*((n=1-c)-u),e){default:case 6:case 0:o=n,a=i,s=u;break;case 1:o=i,a=n,s=u;break;case 2:o=u,a=n,s=i;break;case 3:o=u,a=i,s=n;break;case 4:o=i,a=u,s=n;break;case 5:o=n,a=u,s=i}return[255*o,255*a,255*s]},l.cmyk.rgb=function(t){var e=t[0]/100,n=t[1]/100,r=t[2]/100,i=t[3]/100;return[255*(1-Math.min(1,e*(1-i)+i)),255*(1-Math.min(1,n*(1-i)+i)),255*(1-Math.min(1,r*(1-i)+i))]},l.xyz.rgb=function(t){var e,n,r,i=t[0]/100,o=t[1]/100,a=t[2]/100;return n=-.9689*i+1.8758*o+.0415*a,r=.0557*i+-.204*o+1.057*a,e=.0031308<(e=3.2406*i+-1.5372*o+-.4986*a)?1.055*Math.pow(e,1/2.4)-.055:12.92*e,n=.0031308<n?1.055*Math.pow(n,1/2.4)-.055:12.92*n,r=.0031308<r?1.055*Math.pow(r,1/2.4)-.055:12.92*r,[255*(e=Math.min(Math.max(0,e),1)),255*(n=Math.min(Math.max(0,n),1)),255*(r=Math.min(Math.max(0,r),1))]},l.xyz.lab=function(t){var e=t[0],n=t[1],r=t[2];return n/=100,r/=108.883,e=.008856<(e/=95.047)?Math.pow(e,1/3):7.787*e+16/116,[116*(n=.008856<n?Math.pow(n,1/3):7.787*n+16/116)-16,500*(e-n),200*(n-(r=.008856<r?Math.pow(r,1/3):7.787*r+16/116))]},l.lab.xyz=function(t){var e,n,r,i=t[0];e=t[1]/500+(n=(i+16)/116),r=n-t[2]/200;var o=Math.pow(n,3),a=Math.pow(e,3),s=Math.pow(r,3);return n=.008856<o?o:(n-16/116)/7.787,e=.008856<a?a:(e-16/116)/7.787,r=.008856<s?s:(r-16/116)/7.787,[e*=95.047,n*=100,r*=108.883]},l.lab.lch=function(t){var e,n=t[0],r=t[1],i=t[2];return(e=360*Math.atan2(i,r)/2/Math.PI)<0&&(e+=360),[n,Math.sqrt(r*r+i*i),e]},l.lch.lab=function(t){var e,n=t[0],r=t[1];return e=t[2]/360*2*Math.PI,[n,r*Math.cos(e),r*Math.sin(e)]},l.rgb.ansi16=function(t,e){var n=t[0],r=t[1],i=t[2],o=1 in arguments?e:l.rgb.hsv(t)[2];if(0===(o=Math.round(o/50)))return 30;var a=30+(Math.round(i/255)<<2|Math.round(r/255)<<1|Math.round(n/255));return 2===o&&(a+=60),a},l.hsv.ansi16=function(t){return l.rgb.ansi16(l.hsv.rgb(t),t[2])},l.rgb.ansi256=function(t){var e=t[0],n=t[1],r=t[2];return e===n&&n===r?e<8?16:248<e?231:Math.round((e-8)/247*24)+232:16+36*Math.round(e/255*5)+6*Math.round(n/255*5)+Math.round(r/255*5)},l.ansi16.rgb=function(t){var e=t%10;if(0===e||7===e)return 50<t&&(e+=3.5),[e=e/10.5*255,e,e];var n=.5*(1+~~(50<t));return[(1&e)*n*255,(e>>1&1)*n*255,(e>>2&1)*n*255]},l.ansi256.rgb=function(t){if(232<=t){var e=10*(t-232)+8;return[e,e,e]}var n;return t-=16,[Math.floor(t/36)/5*255,Math.floor((n=t%36)/6)/5*255,n%6/5*255]},l.rgb.hex=function(t){var e=(((255&Math.round(t[0]))<<16)+((255&Math.round(t[1]))<<8)+(255&Math.round(t[2]))).toString(16).toUpperCase();return"000000".substring(e.length)+e},l.hex.rgb=function(t){var e=t.toString(16).match(/[a-f0-9]{6}|[a-f0-9]{3}/i);if(!e)return[0,0,0];var n=e[0];3===e[0].length&&(n=n.split("").map(function(t){return t+t}).join(""));var r=parseInt(n,16);return[r>>16&255,r>>8&255,255&r]},l.rgb.hcg=function(t){var e,n=t[0]/255,r=t[1]/255,i=t[2]/255,o=Math.max(Math.max(n,r),i),a=Math.min(Math.min(n,r),i),s=o-a;return e=s<=0?0:o===n?(r-i)/s%6:o===r?2+(i-n)/s:4+(n-r)/s+4,e/=6,[360*(e%=1),100*s,100*(s<1?a/(1-s):0)]},l.hsl.hcg=function(t){var e=t[1]/100,n=t[2]/100,r=1,i=0;return(r=n<.5?2*e*n:2*e*(1-n))<1&&(i=(n-.5*r)/(1-r)),[t[0],100*r,100*i]},l.hsv.hcg=function(t){var e=t[1]/100,n=t[2]/100,r=e*n,i=0;return r<1&&(i=(n-r)/(1-r)),[t[0],100*r,100*i]},l.hcg.rgb=function(t){var e=t[0]/360,n=t[1]/100,r=t[2]/100;if(0===n)return[255*r,255*r,255*r];var i=[0,0,0],o=e%1*6,a=o%1,s=1-a,l=0;switch(Math.floor(o)){case 0:i[0]=1,i[1]=a,i[2]=0;break;case 1:i[0]=s,i[1]=1,i[2]=0;break;case 2:i[0]=0,i[1]=1,i[2]=a;break;case 3:i[0]=0,i[1]=s,i[2]=1;break;case 4:i[0]=a,i[1]=0,i[2]=1;break;default:i[0]=1,i[1]=0,i[2]=s}return l=(1-n)*r,[255*(n*i[0]+l),255*(n*i[1]+l),255*(n*i[2]+l)]},l.hcg.hsv=function(t){var e=t[1]/100,n=e+t[2]/100*(1-e),r=0;return 0<n&&(r=e/n),[t[0],100*r,100*n]},l.hcg.hsl=function(t){var e=t[1]/100,n=t[2]/100*(1-e)+.5*e,r=0;return 0<n&&n<.5?r=e/(2*n):.5<=n&&n<1&&(r=e/(2*(1-n))),[t[0],100*r,100*n]},l.hcg.hwb=function(t){var e=t[1]/100,n=e+t[2]/100*(1-e);return[t[0],100*(n-e),100*(1-n)]},l.hwb.hcg=function(t){var e=t[1]/100,n=1-t[2]/100,r=n-e,i=0;return r<1&&(i=(n-r)/(1-r)),[t[0],100*r,100*i]},l.apple.rgb=function(t){return[t[0]/65535*255,t[1]/65535*255,t[2]/65535*255]},l.rgb.apple=function(t){return[t[0]/255*65535,t[1]/255*65535,t[2]/255*65535]},l.gray.rgb=function(t){return[t[0]/100*255,t[0]/100*255,t[0]/100*255]},l.gray.hsl=l.gray.hsv=function(t){return[0,0,t[0]]},l.gray.hwb=function(t){return[0,100,t[0]]},l.gray.cmyk=function(t){return[0,0,0,t[0]]},l.gray.lab=function(t){return[t[0],0,0]},l.gray.hex=function(t){var e=255&Math.round(t[0]/100*255),n=((e<<16)+(e<<8)+e).toString(16).toUpperCase();return"000000".substring(n.length)+n},l.rgb.gray=function(t){return[(t[0]+t[1]+t[2])/3/255*100]}}),Ke=(Ge.rgb,Ge.hsl,Ge.hsv,Ge.hwb,Ge.cmyk,Ge.xyz,Ge.lab,Ge.lch,Ge.hex,Ge.keyword,Ge.ansi16,Ge.ansi256,Ge.hcg,Ge.apple,Ge.gray,function(t){for(var e=s(t),n={},r=Object.keys(e),i=r.length,o=0;o<i;o++){var a=r[o];null!==e[a].parent&&(n[a]=l(a,e))}return n}),Xe={};Object.keys(Ge).forEach(function(n){Xe[n]={},Object.defineProperty(Xe[n],"channels",{value:Ge[n].channels}),Object.defineProperty(Xe[n],"labels",{value:Ge[n].labels});var r=Ke(n);Object.keys(r).forEach(function(t){var e=r[t];Xe[n][t]=a(e),Xe[n][t].raw=i(e)})});var Qe=Xe,$e={aliceblue:[240,248,255],antiquewhite:[250,235,215],aqua:[0,255,255],aquamarine:[127,255,212],azure:[240,255,255],beige:[245,245,220],bisque:[255,228,196],black:[0,0,0],blanchedalmond:[255,235,205],blue:[0,0,255],blueviolet:[138,43,226],brown:[165,42,42],burlywood:[222,184,135],cadetblue:[95,158,160],chartreuse:[127,255,0],chocolate:[210,105,30],coral:[255,127,80],cornflowerblue:[100,149,237],cornsilk:[255,248,220],crimson:[220,20,60],cyan:[0,255,255],darkblue:[0,0,139],darkcyan:[0,139,139],darkgoldenrod:[184,134,11],darkgray:[169,169,169],darkgreen:[0,100,0],darkgrey:[169,169,169],darkkhaki:[189,183,107],darkmagenta:[139,0,139],darkolivegreen:[85,107,47],darkorange:[255,140,0],darkorchid:[153,50,204],darkred:[139,0,0],darksalmon:[233,150,122],darkseagreen:[143,188,143],darkslateblue:[72,61,139],darkslategray:[47,79,79],darkslategrey:[47,79,79],darkturquoise:[0,206,209],darkviolet:[148,0,211],deeppink:[255,20,147],deepskyblue:[0,191,255],dimgray:[105,105,105],dimgrey:[105,105,105],dodgerblue:[30,144,255],firebrick:[178,34,34],floralwhite:[255,250,240],forestgreen:[34,139,34],fuchsia:[255,0,255],gainsboro:[220,220,220],ghostwhite:[248,248,255],gold:[255,215,0],goldenrod:[218,165,32],gray:[128,128,128],green:[0,128,0],greenyellow:[173,255,47],grey:[128,128,128],honeydew:[240,255,240],hotpink:[255,105,180],indianred:[205,92,92],indigo:[75,0,130],ivory:[255,255,240],khaki:[240,230,140],lavender:[230,230,250],lavenderblush:[255,240,245],lawngreen:[124,252,0],lemonchiffon:[255,250,205],lightblue:[173,216,230],lightcoral:[240,128,128],lightcyan:[224,255,255],lightgoldenrodyellow:[250,250,210],lightgray:[211,211,211],lightgreen:[144,238,144],lightgrey:[211,211,211],lightpink:[255,182,193],lightsalmon:[255,160,122],lightseagreen:[32,178,170],lightskyblue:[135,206,250],lightslategray:[119,136,153],lightslategrey:[119,136,153],lightsteelblue:[176,196,222],lightyellow:[255,255,224],lime:[0,255,0],limegreen:[50,205,50],linen:[250,240,230],magenta:[255,0,255],maroon:[128,0,0],mediumaquamarine:[102,205,170],mediumblue:[0,0,205],mediumorchid:[186,85,211],mediumpurple:[147,112,219],mediumseagreen:[60,179,113],mediumslateblue:[123,104,238],mediumspringgreen:[0,250,154],mediumturquoise:[72,209,204],mediumvioletred:[199,21,133],midnightblue:[25,25,112],mintcream:[245,255,250],mistyrose:[255,228,225],moccasin:[255,228,181],navajowhite:[255,222,173],navy:[0,0,128],oldlace:[253,245,230],olive:[128,128,0],olivedrab:[107,142,35],orange:[255,165,0],orangered:[255,69,0],orchid:[218,112,214],palegoldenrod:[238,232,170],palegreen:[152,251,152],paleturquoise:[175,238,238],palevioletred:[219,112,147],papayawhip:[255,239,213],peachpuff:[255,218,185],peru:[205,133,63],pink:[255,192,203],plum:[221,160,221],powderblue:[176,224,230],purple:[128,0,128],rebeccapurple:[102,51,153],red:[255,0,0],rosybrown:[188,143,143],royalblue:[65,105,225],saddlebrown:[139,69,19],salmon:[250,128,114],sandybrown:[244,164,96],seagreen:[46,139,87],seashell:[255,245,238],sienna:[160,82,45],silver:[192,192,192],skyblue:[135,206,235],slateblue:[106,90,205],slategray:[112,128,144],slategrey:[112,128,144],snow:[255,250,250],springgreen:[0,255,127],steelblue:[70,130,180],tan:[210,180,140],teal:[0,128,128],thistle:[216,191,216],tomato:[255,99,71],turquoise:[64,224,208],violet:[238,130,238],wheat:[245,222,179],white:[255,255,255],whitesmoke:[245,245,245],yellow:[255,255,0],yellowgreen:[154,205,50]},Ze={getRgba:n,getHsla:r,getRgb:d,getHsl:h,getHwb:c,getAlpha:f,hexString:p,rgbString:g,rgbaString:m,percentString:y,percentaString:v,hslString:b,hslaString:_,hwbString:x,keyword:w},Je={};for(var tn in $e)Je[$e[tn]]=tn;var en=function(t){return t instanceof en?t:this instanceof en?(this.valid=!1,this.values={rgb:[0,0,0],hsl:[0,0,0],hsv:[0,0,0],hwb:[0,0,0],cmyk:[0,0,0,0],alpha:1},void("string"==typeof t?(e=Ze.getRgba(t))?this.setValues("rgb",e):(e=Ze.getHsla(t))?this.setValues("hsl",e):(e=Ze.getHwb(t))&&this.setValues("hwb",e):"object"==typeof t&&((e=t).r!==undefined||e.red!==undefined?this.setValues("rgb",e):e.l!==undefined||e.lightness!==undefined?this.setValues("hsl",e):e.v!==undefined||e.value!==undefined?this.setValues("hsv",e):e.w!==undefined||e.whiteness!==undefined?this.setValues("hwb",e):e.c===undefined&&e.cyan===undefined||this.setValues("cmyk",e)))):new en(t);var e};en.prototype={isValid:function(){return this.valid},rgb:function(){return this.setSpace("rgb",arguments)},hsl:function(){return this.setSpace("hsl",arguments)},hsv:function(){return this.setSpace("hsv",arguments)},hwb:function(){return this.setSpace("hwb",arguments)},cmyk:function(){return this.setSpace("cmyk",arguments)},rgbArray:function(){return this.values.rgb},hslArray:function(){return this.values.hsl},hsvArray:function(){return this.values.hsv},hwbArray:function(){var t=this.values;return 1!==t.alpha?t.hwb.concat([t.alpha]):t.hwb},cmykArray:function(){return this.values.cmyk},rgbaArray:function(){var t=this.values;return t.rgb.concat([t.alpha])},hslaArray:function(){var t=this.values;return t.hsl.concat([t.alpha])},alpha:function(t){return t===undefined?this.values.alpha:(this.setValues("alpha",t),this)},red:function(t){return this.setChannel("rgb",0,t)},green:function(t){return this.setChannel("rgb",1,t)},blue:function(t){return this.setChannel("rgb",2,t)},hue:function(t){return t&&(t=(t%=360)<0?360+t:t),this.setChannel("hsl",0,t)},
saturation:function(t){return this.setChannel("hsl",1,t)},lightness:function(t){return this.setChannel("hsl",2,t)},saturationv:function(t){return this.setChannel("hsv",1,t)},whiteness:function(t){return this.setChannel("hwb",1,t)},blackness:function(t){return this.setChannel("hwb",2,t)},value:function(t){return this.setChannel("hsv",2,t)},cyan:function(t){return this.setChannel("cmyk",0,t)},magenta:function(t){return this.setChannel("cmyk",1,t)},yellow:function(t){return this.setChannel("cmyk",2,t)},black:function(t){return this.setChannel("cmyk",3,t)},hexString:function(){return Ze.hexString(this.values.rgb)},rgbString:function(){return Ze.rgbString(this.values.rgb,this.values.alpha)},rgbaString:function(){return Ze.rgbaString(this.values.rgb,this.values.alpha)},percentString:function(){return Ze.percentString(this.values.rgb,this.values.alpha)},hslString:function(){return Ze.hslString(this.values.hsl,this.values.alpha)},hslaString:function(){return Ze.hslaString(this.values.hsl,this.values.alpha)},hwbString:function(){return Ze.hwbString(this.values.hwb,this.values.alpha)},keyword:function(){return Ze.keyword(this.values.rgb,this.values.alpha)},rgbNumber:function(){var t=this.values.rgb;return t[0]<<16|t[1]<<8|t[2]},luminosity:function(){for(var t=this.values.rgb,e=[],n=0;n<t.length;n++){var r=t[n]/255;e[n]=r<=.03928?r/12.92:Math.pow((r+.055)/1.055,2.4)}return.2126*e[0]+.7152*e[1]+.0722*e[2]},contrast:function(t){var e=this.luminosity(),n=t.luminosity();return n<e?(e+.05)/(n+.05):(n+.05)/(e+.05)},level:function(t){var e=this.contrast(t);return 7.1<=e?"AAA":4.5<=e?"AA":""},dark:function(){var t=this.values.rgb;return(299*t[0]+587*t[1]+114*t[2])/1e3<128},light:function(){return!this.dark()},negate:function(){for(var t=[],e=0;e<3;e++)t[e]=255-this.values.rgb[e];return this.setValues("rgb",t),this},lighten:function(t){var e=this.values.hsl;return e[2]+=e[2]*t,this.setValues("hsl",e),this},darken:function(t){var e=this.values.hsl;return e[2]-=e[2]*t,this.setValues("hsl",e),this},saturate:function(t){var e=this.values.hsl;return e[1]+=e[1]*t,this.setValues("hsl",e),this},desaturate:function(t){var e=this.values.hsl;return e[1]-=e[1]*t,this.setValues("hsl",e),this},whiten:function(t){var e=this.values.hwb;return e[1]+=e[1]*t,this.setValues("hwb",e),this},blacken:function(t){var e=this.values.hwb;return e[2]+=e[2]*t,this.setValues("hwb",e),this},greyscale:function(){var t=this.values.rgb,e=.3*t[0]+.59*t[1]+.11*t[2];return this.setValues("rgb",[e,e,e]),this},clearer:function(t){var e=this.values.alpha;return this.setValues("alpha",e-e*t),this},opaquer:function(t){var e=this.values.alpha;return this.setValues("alpha",e+e*t),this},rotate:function(t){var e=this.values.hsl,n=(e[0]+t)%360;return e[0]=n<0?360+n:n,this.setValues("hsl",e),this},mix:function(t,e){var n=this,r=t,i=e===undefined?.5:e,o=2*i-1,a=n.alpha()-r.alpha(),s=((o*a==-1?o:(o+a)/(1+o*a))+1)/2,l=1-s;return this.rgb(s*n.red()+l*r.red(),s*n.green()+l*r.green(),s*n.blue()+l*r.blue()).alpha(n.alpha()*i+r.alpha()*(1-i))},toJSON:function(){return this.rgb()},clone:function(){var t,e,n=new en,r=this.values,i=n.values;for(var o in r)r.hasOwnProperty(o)&&(t=r[o],"[object Array]"===(e={}.toString.call(t))?i[o]=t.slice(0):"[object Number]"===e?i[o]=t:console.error("unexpected color value:",t));return n}},en.prototype.spaces={rgb:["red","green","blue"],hsl:["hue","saturation","lightness"],hsv:["hue","saturation","value"],hwb:["hue","whiteness","blackness"],cmyk:["cyan","magenta","yellow","black"]},en.prototype.maxes={rgb:[255,255,255],hsl:[360,100,100],hsv:[360,100,100],hwb:[360,100,100],cmyk:[100,100,100,100]},en.prototype.getValues=function(t){for(var e=this.values,n={},r=0;r<t.length;r++)n[t.charAt(r)]=e[t][r];return 1!==e.alpha&&(n.a=e.alpha),n},en.prototype.setValues=function(t,e){var n,r,i=this.values,o=this.spaces,a=this.maxes,s=1;if(this.valid=!0,"alpha"===t)s=e;else if(e.length)i[t]=e.slice(0,t.length),s=e[t.length];else if(e[t.charAt(0)]!==undefined){for(n=0;n<t.length;n++)i[t][n]=e[t.charAt(n)];s=e.a}else if(e[o[t][0]]!==undefined){var l=o[t];for(n=0;n<t.length;n++)i[t][n]=e[l[n]];s=e.alpha}if(i.alpha=Math.max(0,Math.min(1,s===undefined?i.alpha:s)),"alpha"===t)return!1;for(n=0;n<t.length;n++)r=Math.max(0,Math.min(a[t][n],i[t][n])),i[t][n]=Math.round(r);for(var u in o)u!==t&&(i[u]=Qe[t][u](i[t]));return!0},en.prototype.setSpace=function(t,e){var n=e[0];return n===undefined?this.getValues(t):("number"==typeof n&&(n=Array.prototype.slice.call(e)),this.setValues(t,n),this)},en.prototype.setChannel=function(t,e,n){var r=this.values[t];return n===undefined?r[e]:(n===r[e]||(r[e]=n,this.setValues(t,r)),this)},"undefined"!=typeof window&&(window.Color=en);var nn,rn=en,on={noop:function(){},uid:(nn=0,function(){return nn++}),isNullOrUndef:function(t){return null==t},isArray:function(t){if(Array.isArray&&Array.isArray(t))return!0;var e=Object.prototype.toString.call(t);return"[object"===e.substr(0,7)&&"Array]"===e.substr(-6)},isObject:function(t){return null!==t&&"[object Object]"===Object.prototype.toString.call(t)},isFinite:function(t){return("number"==typeof t||t instanceof Number)&&isFinite(t)},valueOrDefault:function(t,e){return void 0===t?e:t},valueAtIndexOrDefault:function(t,e,n){return on.valueOrDefault(on.isArray(t)?t[e]:t,n)},callback:function(t,e,n){if(t&&"function"==typeof t.call)return t.apply(n,e)},each:function(t,e,n,r){var i,o,a;if(on.isArray(t))if(o=t.length,r)for(i=o-1;0<=i;i--)e.call(n,t[i],i);else for(i=0;i<o;i++)e.call(n,t[i],i);else if(on.isObject(t))for(o=(a=Object.keys(t)).length,i=0;i<o;i++)e.call(n,t[a[i]],a[i])},arrayEquals:function(t,e){var n,r,i,o;if(!t||!e||t.length!==e.length)return!1;for(n=0,r=t.length;n<r;++n)if(i=t[n],o=e[n],i instanceof Array&&o instanceof Array){if(!on.arrayEquals(i,o))return!1}else if(i!==o)return!1;return!0},clone:function(t){if(on.isArray(t))return t.map(on.clone);if(on.isObject(t)){for(var e={},n=Object.keys(t),r=n.length,i=0;i<r;++i)e[n[i]]=on.clone(t[n[i]]);return e}return t},_merger:function(t,e,n,r){var i=e[t],o=n[t];on.isObject(i)&&on.isObject(o)?on.merge(i,o,r):e[t]=on.clone(o)},_mergerIf:function(t,e,n){var r=e[t],i=n[t];on.isObject(r)&&on.isObject(i)?on.mergeIf(r,i):e.hasOwnProperty(t)||(e[t]=on.clone(i))},merge:function(t,e,n){var r,i,o,a,s,l=on.isArray(e)?e:[e],u=l.length;if(!on.isObject(t))return t;for(r=(n=n||{}).merger||on._merger,i=0;i<u;++i)if(e=l[i],on.isObject(e))for(s=0,a=(o=Object.keys(e)).length;s<a;++s)r(o[s],t,e,n);return t},mergeIf:function(t,e){return on.merge(t,e,{merger:on._mergerIf})},extend:Object.assign||function(t){return on.merge(t,[].slice.call(arguments,1),{merger:function(t,e,n){e[t]=n[t]}})},inherits:function(t){var e=this,n=t&&t.hasOwnProperty("constructor")?t.constructor:function(){return e.apply(this,arguments)},r=function(){this.constructor=n};return r.prototype=e.prototype,n.prototype=new r,n.extend=on.inherits,t&&on.extend(n.prototype,t),n.__super__=e.prototype,n},_deprecated:function(t,e,n,r){e!==undefined&&console.warn(t+': "'+n+'" is deprecated. Please use "'+r+'" instead')}},an=on;on.callCallback=on.callback,on.indexOf=function(t,e,n){return Array.prototype.indexOf.call(t,e,n)},on.getValueOrDefault=on.valueOrDefault,on.getValueAtIndexOrDefault=on.valueAtIndexOrDefault;var sn={linear:function(t){return t},easeInQuad:function(t){return t*t},easeOutQuad:function(t){return-t*(t-2)},easeInOutQuad:function(t){return(t/=.5)<1?.5*t*t:-.5*(--t*(t-2)-1)},easeInCubic:function(t){return t*t*t},easeOutCubic:function(t){return(t-=1)*t*t+1},easeInOutCubic:function(t){return(t/=.5)<1?.5*t*t*t:.5*((t-=2)*t*t+2)},easeInQuart:function(t){return t*t*t*t},easeOutQuart:function(t){return-((t-=1)*t*t*t-1)},easeInOutQuart:function(t){return(t/=.5)<1?.5*t*t*t*t:-.5*((t-=2)*t*t*t-2)},easeInQuint:function(t){return t*t*t*t*t},easeOutQuint:function(t){return(t-=1)*t*t*t*t+1},easeInOutQuint:function(t){return(t/=.5)<1?.5*t*t*t*t*t:.5*((t-=2)*t*t*t*t+2)},easeInSine:function(t){return 1-Math.cos(t*(Math.PI/2))},easeOutSine:function(t){return Math.sin(t*(Math.PI/2))},easeInOutSine:function(t){return-.5*(Math.cos(Math.PI*t)-1)},easeInExpo:function(t){return 0===t?0:Math.pow(2,10*(t-1))},easeOutExpo:function(t){return 1===t?1:1-Math.pow(2,-10*t)},easeInOutExpo:function(t){return 0===t?0:1===t?1:(t/=.5)<1?.5*Math.pow(2,10*(t-1)):.5*(2-Math.pow(2,-10*--t))},easeInCirc:function(t){return 1<=t?t:-(Math.sqrt(1-t*t)-1)},easeOutCirc:function(t){return Math.sqrt(1-(t-=1)*t)},easeInOutCirc:function(t){return(t/=.5)<1?-.5*(Math.sqrt(1-t*t)-1):.5*(Math.sqrt(1-(t-=2)*t)+1)},easeInElastic:function(t){var e=1.70158,n=0,r=1;return 0===t?0:1===t?1:(n||(n=.3),r<1?(r=1,e=n/4):e=n/(2*Math.PI)*Math.asin(1/r),-r*Math.pow(2,10*(t-=1))*Math.sin((t-e)*(2*Math.PI)/n))},easeOutElastic:function(t){var e=1.70158,n=0,r=1;return 0===t?0:1===t?1:(n||(n=.3),r<1?(r=1,e=n/4):e=n/(2*Math.PI)*Math.asin(1/r),r*Math.pow(2,-10*t)*Math.sin((t-e)*(2*Math.PI)/n)+1)},easeInOutElastic:function(t){var e=1.70158,n=0,r=1;return 0===t?0:2==(t/=.5)?1:(n||(n=.45),r<1?(r=1,e=n/4):e=n/(2*Math.PI)*Math.asin(1/r),t<1?r*Math.pow(2,10*(t-=1))*Math.sin((t-e)*(2*Math.PI)/n)*-.5:r*Math.pow(2,-10*(t-=1))*Math.sin((t-e)*(2*Math.PI)/n)*.5+1)},easeInBack:function(t){var e=1.70158;return t*t*((e+1)*t-e)},easeOutBack:function(t){var e=1.70158;return(t-=1)*t*((e+1)*t+e)+1},easeInOutBack:function(t){var e=1.70158;return(t/=.5)<1?t*t*((1+(e*=1.525))*t-e)*.5:.5*((t-=2)*t*((1+(e*=1.525))*t+e)+2)},easeInBounce:function(t){return 1-sn.easeOutBounce(1-t)},easeOutBounce:function(t){return t<1/2.75?7.5625*t*t:t<2/2.75?7.5625*(t-=1.5/2.75)*t+.75:t<2.5/2.75?7.5625*(t-=2.25/2.75)*t+.9375:7.5625*(t-=2.625/2.75)*t+.984375},easeInOutBounce:function(t){return t<.5?.5*sn.easeInBounce(2*t):.5*sn.easeOutBounce(2*t-1)+.5}},ln={effects:sn};an.easingEffects=sn;var un=Math.PI,cn=un/180,dn=2*un,hn=un/2,fn=un/4,pn=2*un/3,gn={clear:function(t){t.ctx.clearRect(0,0,t.width,t.height)},roundedRect:function(t,e,n,r,i,o){if(o){var a=Math.min(o,i/2,r/2),s=e+a,l=n+a,u=e+r-a,c=n+i-a;t.moveTo(e,l),s<u&&l<c?(t.arc(s,l,a,-un,-hn),t.arc(u,l,a,-hn,0),t.arc(u,c,a,0,hn),t.arc(s,c,a,hn,un)):s<u?(t.moveTo(s,n),t.arc(u,l,a,-hn,hn),t.arc(s,l,a,hn,un+hn)):l<c?(t.arc(s,l,a,-un,0),t.arc(s,c,a,0,un)):t.arc(s,l,a,-un,un),t.closePath(),t.moveTo(e,n)}else t.rect(e,n,r,i)},drawPoint:function(t,e,n,r,i,o){var a,s,l,u,c,d=(o||0)*cn;if(e&&"object"==typeof e&&("[object HTMLImageElement]"===(a=e.toString())||"[object HTMLCanvasElement]"===a))return t.save(),t.translate(r,i),t.rotate(d),t.drawImage(e,-e.width/2,-e.height/2,e.width,e.height),void t.restore();if(!(isNaN(n)||n<=0)){switch(t.beginPath(),e){default:t.arc(r,i,n,0,dn),t.closePath();break;case"triangle":t.moveTo(r+Math.sin(d)*n,i-Math.cos(d)*n),d+=pn,t.lineTo(r+Math.sin(d)*n,i-Math.cos(d)*n),d+=pn,t.lineTo(r+Math.sin(d)*n,i-Math.cos(d)*n),t.closePath();break;case"rectRounded":u=n-(c=.516*n),s=Math.cos(d+fn)*u,l=Math.sin(d+fn)*u,t.arc(r-s,i-l,c,d-un,d-hn),t.arc(r+l,i-s,c,d-hn,d),t.arc(r+s,i+l,c,d,d+hn),t.arc(r-l,i+s,c,d+hn,d+un),t.closePath();break;case"rect":if(!o){u=Math.SQRT1_2*n,t.rect(r-u,i-u,2*u,2*u);break}d+=fn;case"rectRot":s=Math.cos(d)*n,l=Math.sin(d)*n,t.moveTo(r-s,i-l),t.lineTo(r+l,i-s),t.lineTo(r+s,i+l),t.lineTo(r-l,i+s),t.closePath();break;case"crossRot":d+=fn;case"cross":s=Math.cos(d)*n,l=Math.sin(d)*n,t.moveTo(r-s,i-l),t.lineTo(r+s,i+l),t.moveTo(r+l,i-s),t.lineTo(r-l,i+s);break;case"star":s=Math.cos(d)*n,l=Math.sin(d)*n,t.moveTo(r-s,i-l),t.lineTo(r+s,i+l),t.moveTo(r+l,i-s),t.lineTo(r-l,i+s),d+=fn,s=Math.cos(d)*n,l=Math.sin(d)*n,t.moveTo(r-s,i-l),t.lineTo(r+s,i+l),t.moveTo(r+l,i-s),t.lineTo(r-l,i+s);break;case"line":s=Math.cos(d)*n,l=Math.sin(d)*n,t.moveTo(r-s,i-l),t.lineTo(r+s,i+l);break;case"dash":t.moveTo(r,i),t.lineTo(r+Math.cos(d)*n,i+Math.sin(d)*n)}t.fill(),t.stroke()}},_isPointInArea:function(t,e){var n=1e-6;return t.x>e.left-n&&t.x<e.right+n&&t.y>e.top-n&&t.y<e.bottom+n},clipArea:function(t,e){t.save(),t.beginPath(),t.rect(e.left,e.top,e.right-e.left,e.bottom-e.top),t.clip()},unclipArea:function(t){t.restore()},lineTo:function(t,e,n,r){var i=n.steppedLine;if(i){if("middle"===i){var o=(e.x+n.x)/2;t.lineTo(o,r?n.y:e.y),t.lineTo(o,r?e.y:n.y)}else"after"===i&&!r||"after"!==i&&r?t.lineTo(e.x,n.y):t.lineTo(n.x,e.y);t.lineTo(n.x,n.y)}else n.tension?t.bezierCurveTo(r?e.controlPointPreviousX:e.controlPointNextX,r?e.controlPointPreviousY:e.controlPointNextY,r?n.controlPointNextX:n.controlPointPreviousX,r?n.controlPointNextY:n.controlPointPreviousY,n.x,n.y):t.lineTo(n.x,n.y)}},mn=gn;an.clear=gn.clear,an.drawRoundedRectangle=function(t){t.beginPath(),gn.roundedRect.apply(gn,arguments)};var yn={_set:function(t,e){return an.merge(this[t]||(this[t]={}),e)}};yn._set("global",{defaultColor:"rgba(0,0,0,0.1)",defaultFontColor:"#666",defaultFontFamily:"'Helvetica Neue', 'Helvetica', 'Arial', sans-serif",defaultFontSize:12,defaultFontStyle:"normal",defaultLineHeight:1.2,showLines:!0});var vn=yn,bn=an.valueOrDefault,_n={toLineHeight:function(t,e){var n=(""+t).match(/^(normal|(\d+(?:\.\d+)?)(px|em|%)?)$/);if(!n||"normal"===n[1])return 1.2*e;switch(t=+n[2],n[3]){case"px":return t;case"%":t/=100}return e*t},toPadding:function(t){var e,n,r,i;return an.isObject(t)?(e=+t.top||0,n=+t.right||0,r=+t.bottom||0,i=+t.left||0):e=n=r=i=+t||0,{top:e,right:n,bottom:r,left:i,height:e+r,width:i+n}},_parseFont:function(t){var e=vn.global,n=bn(t.fontSize,e.defaultFontSize),r={family:bn(t.fontFamily,e.defaultFontFamily),lineHeight:an.options.toLineHeight(bn(t.lineHeight,e.defaultLineHeight),n),size:n,style:bn(t.fontStyle,e.defaultFontStyle),weight:null,string:""};return r.string=k(r),r},resolve:function(t,e,n,r){var i,o,a,s=!0;for(i=0,o=t.length;i<o;++i)if((a=t[i])!==undefined&&(e!==undefined&&"function"==typeof a&&(a=a(e),s=!1),n!==undefined&&an.isArray(a)&&(a=a[n],s=!1),a!==undefined))return r&&!s&&(r.cacheable=!1),a}},xn={_factorize:function(t){var e,n=[],r=Math.sqrt(t);for(e=1;e<r;e++)t%e==0&&(n.push(e),n.push(t/e));return r===(0|r)&&n.push(r),n.sort(function(t,e){return t-e}).pop(),n},log10:Math.log10||function(t){var e=Math.log(t)*Math.LOG10E,n=Math.round(e);return t===Math.pow(10,n)?n:e}},wn=xn;an.log10=xn.log10;var Sn=function(e,n){return{x:function(t){return e+e+n-t},setWidth:function(t){n=t},textAlign:function(t){return"center"===t?t:"right"===t?"left":"right"},xPlus:function(t,e){return t-e},leftForLtr:function(t,e){return t-e}}},Tn=function(){return{x:function(t){return t},setWidth:function(){},textAlign:function(t){return t},xPlus:function(t,e){return t+e},leftForLtr:function(t){return t}}},kn=an,Cn=ln,En=mn,Dn=_n,An=wn,Mn={getRtlAdapter:function(t,e,n){return t?Sn(e,n):Tn()},overrideTextDirection:function(t,e){var n,r;"ltr"!==e&&"rtl"!==e||(r=[(n=t.canvas.style).getPropertyValue("direction"),n.getPropertyPriority("direction")],n.setProperty("direction",e,"important"),t.prevTextDirection=r)},restoreTextDirection:function(t){var e=t.prevTextDirection;e!==undefined&&(delete t.prevTextDirection,t.canvas.style.setProperty("direction",e[0],e[1]))}};kn.easing=Cn,kn.canvas=En,kn.options=Dn,kn.math=An,kn.rtl=Mn;var On=function(t){kn.extend(this,t),this.initialize.apply(this,arguments)};kn.extend(On.prototype,{_type:undefined,initialize:function(){this.hidden=!1},pivot:function(){var t=this;return t._view||(t._view=kn.extend({},t._model)),t._start={},t},transition:function(t){var e=this,n=e._model,r=e._start,i=e._view;return n&&1!==t?(i||(i=e._view={}),r||(r=e._start={}),C(r,i,n,t)):(e._view=kn.extend({},n),e._start=null),e},tooltipPosition:function(){return{x:this._model.x,y:this._model.y}},hasValue:function(){return kn.isNumber(this._model.x)&&kn.isNumber(this._model.y)}}),On.extend=kn.inherits;var In=On,Pn=In.extend({chart:null,currentStep:0,numSteps:60,easing:"",render:null,onAnimationProgress:null,onAnimationComplete:null}),Ln=Pn;Object.defineProperty(Pn.prototype,"animationObject",{get:function(){return this}}),Object.defineProperty(Pn.prototype,"chartInstance",{get:function(){return this.chart},set:function(t){this.chart=t}}),vn._set("global",{animation:{duration:1e3,easing:"easeOutQuart",onProgress:kn.noop,onComplete:kn.noop}});var Nn={animations:[],request:null,addAnimation:function(t,e,n,r){var i,o,a=this.animations;for(e.chart=t,e.startTime=Date.now(),e.duration=n,r||(t.animating=!0),i=0,o=a.length;i<o;++i)if(a[i].chart===t)return void(a[i]=e);a.push(e),1===a.length&&this.requestAnimationFrame()},cancelAnimation:function(e){var t=kn.findIndex(this.animations,function(t){return t.chart===e});-1!==t&&(this.animations.splice(t,1),e.animating=!1)},requestAnimationFrame:function(){var t=this;null===t.request&&(t.request=kn.requestAnimFrame.call(window,function(){t.request=null,t.startDigest()}))},startDigest:function(){var t=this;t.advance(),0<t.animations.length&&t.requestAnimationFrame()},advance:function(){for(var t,e,n,r,i=this.animations,o=0;o<i.length;)e=(t=i[o]).chart,n=t.numSteps,r=Math.floor((Date.now()-t.startTime)/t.duration*n)+1,t.currentStep=Math.min(r,n),kn.callback(t.render,[e,t],e),kn.callback(t.onAnimationProgress,[t],e),t.currentStep>=n?(kn.callback(t.onAnimationComplete,[t],e),e.animating=!1,i.splice(o,1)):++o}},Rn=kn.options.resolve,Fn=["push","pop","shift","splice","unshift"],Hn=function(t,e){this.initialize(t,e)};kn.extend(Hn.prototype,{datasetElementType:null,dataElementType:null,_datasetElementOptions:["backgroundColor","borderCapStyle","borderColor","borderDash","borderDashOffset","borderJoinStyle","borderWidth"],_dataElementOptions:["backgroundColor","borderColor","borderWidth","pointStyle"],initialize:function(t,e){var n=this;n.chart=t,n.index=e,n.linkScales(),n.addElements(),n._type=n.getMeta().type},updateIndex:function(t){this.index=t},linkScales:function(){var t=this,e=t.getMeta(),n=t.chart,r=n.scales,i=t.getDataset(),o=n.options.scales;null!==e.xAxisID&&e.xAxisID in r&&!i.xAxisID||(e.xAxisID=i.xAxisID||o.xAxes[0].id),null!==e.yAxisID&&e.yAxisID in r&&!i.yAxisID||(e.yAxisID=i.yAxisID||o.yAxes[0].id)},getDataset:function(){return this.chart.data.datasets[this.index]},getMeta:function(){return this.chart.getDatasetMeta(this.index)},getScaleForId:function(t){return this.chart.scales[t]},_getValueScaleId:function(){return this.getMeta().yAxisID},_getIndexScaleId:function(){return this.getMeta().xAxisID},_getValueScale:function(){return this.getScaleForId(this._getValueScaleId())},_getIndexScale:function(){return this.getScaleForId(this._getIndexScaleId())},reset:function(){this._update(!0)},destroy:function(){this._data&&D(this._data,this)},createMetaDataset:function(){var t=this,e=t.datasetElementType;return e&&new e({_chart:t.chart,_datasetIndex:t.index})},createMetaData:function(t){var e=this,n=e.dataElementType;return n&&new n({_chart:e.chart,_datasetIndex:e.index,_index:t})},addElements:function(){var t,e,n=this,r=n.getMeta(),i=n.getDataset().data||[],o=r.data;for(t=0,e=i.length;t<e;++t)o[t]=o[t]||n.createMetaData(t);r.dataset=r.dataset||n.createMetaDataset()},addElementAndReset:function(t){var e=this.createMetaData(t);this.getMeta().data.splice(t,0,e),this.updateElement(e,t,!0)},buildOrUpdateElements:function(){var t=this,e=t.getDataset(),n=e.data||(e.data=[]);t._data!==n&&(t._data&&D(t._data,t),n&&Object.isExtensible(n)&&E(n,t),t._data=n),t.resyncElements()},_configure:function(){var t=this;t._config=kn.merge({},[t.chart.options.datasets[t._type],t.getDataset()],{merger:function(t,e,n){"_meta"!==t&&"data"!==t&&kn._merger(t,e,n)}})},_update:function(t){var e=this;e._configure(),e._cachedDataOpts=null,e.update(t)},update:kn.noop,transition:function(t){for(var e=this.getMeta(),n=e.data||[],r=n.length,i=0;i<r;++i)n[i].transition(t);e.dataset&&e.dataset.transition(t)},draw:function(){var t=this.getMeta(),e=t.data||[],n=e.length,r=0;for(t.dataset&&t.dataset.draw();r<n;++r)e[r].draw()},getStyle:function(t){var e,n=this,r=n.getMeta(),i=r.dataset;return n._configure(),i&&t===undefined?e=n._resolveDatasetElementOptions(i||{}):(t=t||0,e=n._resolveDataElementOptions(r.data[t]||{},t)),!1!==e.fill&&null!==e.fill||(e.backgroundColor=e.borderColor),e},_resolveDatasetElementOptions:function(t,e){var n,r,i,o,a=this,s=a.chart,l=a._config,u=t.custom||{},c=s.options.elements[a.datasetElementType.prototype._type]||{},d=a._datasetElementOptions,h={},f={chart:s,dataset:a.getDataset(),datasetIndex:a.index,hover:e};for(n=0,r=d.length;n<r;++n)i=d[n],o=e?"hover"+i.charAt(0).toUpperCase()+i.slice(1):i,h[i]=Rn([u[o],l[o],c[o]],f);return h},_resolveDataElementOptions:function(t,e){var n=this,r=t&&t.custom,i=n._cachedDataOpts;if(i&&!r)return i;var o,a,s,l,u=n.chart,c=n._config,d=u.options.elements[n.dataElementType.prototype._type]||{},h=n._dataElementOptions,f={},p={chart:u,dataIndex:e,dataset:n.getDataset(),datasetIndex:n.index},g={cacheable:!r};if(r=r||{},kn.isArray(h))for(a=0,s=h.length;a<s;++a)f[l=h[a]]=Rn([r[l],c[l],d[l]],p,e,g);else for(a=0,s=(o=Object.keys(h)).length;a<s;++a)f[l=o[a]]=Rn([r[l],c[h[l]],c[l],d[l]],p,e,g);return g.cacheable&&(n._cachedDataOpts=Object.freeze(f)),f},removeHoverStyle:function(t){kn.merge(t._model,t.$previousStyle||{}),delete t.$previousStyle},setHoverStyle:function(t){var e=this.chart.data.datasets[t._datasetIndex],n=t._index,r=t.custom||{},i=t._model,o=kn.getHoverColor;t.$previousStyle={backgroundColor:i.backgroundColor,borderColor:i.borderColor,borderWidth:i.borderWidth},i.backgroundColor=Rn([r.hoverBackgroundColor,e.hoverBackgroundColor,o(i.backgroundColor)],undefined,n),i.borderColor=Rn([r.hoverBorderColor,e.hoverBorderColor,o(i.borderColor)],undefined,n),i.borderWidth=Rn([r.hoverBorderWidth,e.hoverBorderWidth,i.borderWidth],undefined,n)},_removeDatasetHoverStyle:function(){var t=this.getMeta().dataset;t&&this.removeHoverStyle(t)},_setDatasetHoverStyle:function(){var t,e,n,r,i,o,a=this.getMeta().dataset,s={};if(a){for(o=a._model,i=this._resolveDatasetElementOptions(a,!0),t=0,e=(r=Object.keys(i)).length;t<e;++t)s[n=r[t]]=o[n],o[n]=i[n];a.$previousStyle=s}},resyncElements:function(){var t=this,e=t.getMeta(),n=t.getDataset().data,r=e.data.length,i=n.length;i<r?e.data.splice(i,r-i):r<i&&t.insertElements(r,i-r)},insertElements:function(t,e){for(var n=0;n<e;++n)this.addElementAndReset(t+n)},onDataPush:function(){var t=arguments.length;this.insertElements(this.getDataset().data.length-t,t)},onDataPop:function(){this.getMeta().data.pop()},onDataShift:function(){this.getMeta().data.shift()},onDataSplice:function(t,e){this.getMeta().data.splice(t,e),this.insertElements(t,arguments.length-2)},onDataUnshift:function(){this.insertElements(0,arguments.length)}}),Hn.extend=kn.inherits;var jn=Hn,Wn=2*Math.PI;vn._set("global",{elements:{arc:{backgroundColor:vn.global.defaultColor,borderColor:"#fff",borderWidth:2,borderAlign:"center"}}});var zn=In.extend({_type:"arc",inLabelRange:function(t){var e=this._view;return!!e&&Math.pow(t-e.x,2)<Math.pow(e.radius+e.hoverRadius,2)},inRange:function(t,e){var n=this._view;if(n){for(var r=kn.getAngleFromPoint(n,{x:t,y:e}),i=r.angle,o=r.distance,a=n.startAngle,s=n.endAngle;s<a;)s+=Wn;for(;s<i;)i-=Wn;for(;i<a;)i+=Wn;var l=a<=i&&i<=s,u=o>=n.innerRadius&&o<=n.outerRadius;return l&&u}return!1},getCenterPoint:function(){var t=this._view,e=(t.startAngle+t.endAngle)/2,n=(t.innerRadius+t.outerRadius)/2;return{x:t.x+Math.cos(e)*n,y:t.y+Math.sin(e)*n}},getArea:function(){var t=this._view;return Math.PI*((t.endAngle-t.startAngle)/(2*Math.PI))*(Math.pow(t.outerRadius,2)-Math.pow(t.innerRadius,2))},tooltipPosition:function(){var t=this._view,e=t.startAngle+(t.endAngle-t.startAngle)/2,n=(t.outerRadius-t.innerRadius)/2+t.innerRadius;return{x:t.x+Math.cos(e)*n,y:t.y+Math.sin(e)*n}},draw:function(){var t,e=this._chart.ctx,n=this._view,r="inner"===n.borderAlign?.33:0,i={x:n.x,y:n.y,innerRadius:n.innerRadius,outerRadius:Math.max(n.outerRadius-r,0),pixelMargin:r,startAngle:n.startAngle,endAngle:n.endAngle,fullCircles:Math.floor(n.circumference/Wn)};if(e.save(),e.fillStyle=n.backgroundColor,e.strokeStyle=n.borderColor,i.fullCircles){for(i.endAngle=i.startAngle+Wn,e.beginPath(),e.arc(i.x,i.y,i.outerRadius,i.startAngle,i.endAngle),e.arc(i.x,i.y,i.innerRadius,i.endAngle,i.startAngle,!0),e.closePath(),t=0;t<i.fullCircles;++t)e.fill();i.endAngle=i.startAngle+n.circumference%Wn}e.beginPath(),e.arc(i.x,i.y,i.outerRadius,i.startAngle,i.endAngle),e.arc(i.x,i.y,i.innerRadius,i.endAngle,i.startAngle,!0),e.closePath(),e.fill(),n.borderWidth&&O(e,n,i),e.restore()}}),Bn=kn.valueOrDefault,Vn=vn.global.defaultColor;vn._set("global",{elements:{line:{tension:.4,backgroundColor:Vn,borderWidth:3,borderColor:Vn,borderCapStyle:"butt",borderDash:[],borderDashOffset:0,borderJoinStyle:"miter",capBezierPoints:!0,fill:!0}}});var qn=In.extend({_type:"line",draw:function(){var t,e,n,r=this,i=r._view,o=r._chart.ctx,a=i.spanGaps,s=r._children.slice(),l=vn.global,u=l.elements.line,c=-1,d=r._loop;if(s.length){if(r._loop){for(t=0;t<s.length;++t)if(e=kn.previousItem(s,t),!s[t]._view.skip&&e._view.skip){s=s.slice(t).concat(s.slice(0,t)),d=a;break}d&&s.push(s[0])}for(o.save(),o.lineCap=i.borderCapStyle||u.borderCapStyle,o.setLineDash&&o.setLineDash(i.borderDash||u.borderDash),o.lineDashOffset=Bn(i.borderDashOffset,u.borderDashOffset),o.lineJoin=i.borderJoinStyle||u.borderJoinStyle,o.lineWidth=Bn(i.borderWidth,u.borderWidth),o.strokeStyle=i.borderColor||l.defaultColor,o.beginPath(),(n=s[0]._view).skip||(o.moveTo(n.x,n.y),c=0),t=1;t<s.length;++t)n=s[t]._view,e=-1===c?kn.previousItem(s,t):s[c],n.skip||(c!==t-1&&!a||-1===c?o.moveTo(n.x,n.y):kn.canvas.lineTo(o,e._view,n),c=t);d&&o.closePath(),o.stroke(),o.restore()}}}),Un=kn.valueOrDefault,Yn=vn.global.defaultColor;vn._set("global",{elements:{point:{radius:3,pointStyle:"circle",backgroundColor:Yn,borderColor:Yn,borderWidth:1,hitRadius:1,hoverRadius:4,hoverBorderWidth:1}}});var Gn=In.extend({_type:"point",inRange:function(t,e){var n=this._view;return!!n&&Math.pow(t-n.x,2)+Math.pow(e-n.y,2)<Math.pow(n.hitRadius+n.radius,2)},inLabelRange:I,inXRange:I,inYRange:P,getCenterPoint:function(){var t=this._view;return{x:t.x,y:t.y}},getArea:function(){return Math.PI*Math.pow(this._view.radius,2)},tooltipPosition:function(){var t=this._view;return{x:t.x,y:t.y,padding:t.radius+t.borderWidth}},draw:function(t){var e=this._view,n=this._chart.ctx,r=e.pointStyle,i=e.rotation,o=e.radius,a=e.x,s=e.y,l=vn.global,u=l.defaultColor;e.skip||(t===undefined||kn.canvas._isPointInArea(e,t))&&(n.strokeStyle=e.borderColor||u,n.lineWidth=Un(e.borderWidth,l.elements.point.borderWidth),n.fillStyle=e.backgroundColor||u,kn.canvas.drawPoint(n,r,o,a,s,i))}}),Kn=vn.global.defaultColor;vn._set("global",{elements:{rectangle:{backgroundColor:Kn,borderColor:Kn,borderSkipped:"bottom",borderWidth:0}}});var Xn=In.extend({_type:"rectangle",draw:function(){var t=this._chart.ctx,e=this._view,n=j(e),r=n.outer,i=n.inner;t.fillStyle=e.backgroundColor,t.fillRect(r.x,r.y,r.w,r.h),r.w===i.w&&r.h===i.h||(t.save(),t.beginPath(),t.rect(r.x,r.y,r.w,r.h),t.clip(),t.fillStyle=e.borderColor,t.rect(i.x,i.y,i.w,i.h),t.fill("evenodd"),t.restore())},height:function(){var t=this._view;return t.base-t.y},inRange:function(t,e){return W(this._view,t,e)},inLabelRange:function(t,e){var n=this._view;return L(n)?W(n,t,null):W(n,null,e)},inXRange:function(t){return W(this._view,t,null)},inYRange:function(t){return W(this._view,null,t)},getCenterPoint:function(){var t,e,n=this._view;return L(n)?(t=n.x,e=(n.y+n.base)/2):(t=(n.x+n.base)/2,e=n.y),{x:t,y:e}},getArea:function(){var t=this._view;return L(t)?t.width*Math.abs(t.y-t.base):t.height*Math.abs(t.x-t.base)},tooltipPosition:function(){var t=this._view;return{x:t.x,y:t.y}}}),Qn={},$n=zn,Zn=qn,Jn=Gn,tr=Xn;Qn.Arc=$n,Qn.Line=Zn,Qn.Point=Jn,Qn.Rectangle=tr;var er=kn._deprecated,nr=kn.valueOrDefault;vn._set("bar",{hover:{mode:"label"},scales:{xAxes:[{type:"category",offset:!0,gridLines:{offsetGridLines:!0}}],yAxes:[{type:"linear"}]}}),vn._set("global",{datasets:{bar:{categoryPercentage:.8,barPercentage:.9}}});var rr=jn.extend({dataElementType:Qn.Rectangle,_dataElementOptions:["backgroundColor","borderColor","borderSkipped","borderWidth","barPercentage","barThickness","categoryPercentage","maxBarThickness","minBarLength"],initialize:function(){var t,e,n=this;jn.prototype.initialize.apply(n,arguments),(t=n.getMeta()).stack=n.getDataset().stack,t.bar=!0,e=n._getIndexScale().options,er("bar chart",e.barPercentage,"scales.[x/y]Axes.barPercentage","dataset.barPercentage"),er("bar chart",e.barThickness,"scales.[x/y]Axes.barThickness","dataset.barThickness"),er("bar chart",e.categoryPercentage,"scales.[x/y]Axes.categoryPercentage","dataset.categoryPercentage"),er("bar chart",n._getValueScale().options.minBarLength,"scales.[x/y]Axes.minBarLength","dataset.minBarLength"),er("bar chart",e.maxBarThickness,"scales.[x/y]Axes.maxBarThickness","dataset.maxBarThickness")},update:function(t){var e,n,r=this,i=r.getMeta().data;for(r._ruler=r.getRuler(),e=0,n=i.length;e<n;++e)r.updateElement(i[e],e,t)},updateElement:function(t,e,n){var r=this,i=r.getMeta(),o=r.getDataset(),a=r._resolveDataElementOptions(t,e);t._xScale=r.getScaleForId(i.xAxisID),t._yScale=r.getScaleForId(i.yAxisID),t._datasetIndex=r.index,t._index=e,t._model={backgroundColor:a.backgroundColor,borderColor:a.borderColor,borderSkipped:a.borderSkipped,borderWidth:a.borderWidth,datasetLabel:o.label,label:r.chart.data.labels[e]},kn.isArray(o.data[e])&&(t._model.borderSkipped=null),r._updateElementGeometry(t,e,n,a),t.pivot()},_updateElementGeometry:function(t,e,n,r){var i=this,o=t._model,a=i._getValueScale(),s=a.getBasePixel(),l=a.isHorizontal(),u=i._ruler||i.getRuler(),c=i.calculateBarValuePixels(i.index,e,r),d=i.calculateBarIndexPixels(i.index,e,u,r);o.horizontal=l,o.base=n?s:c.base,o.x=l?n?s:c.head:d.center,o.y=l?d.center:n?s:c.head,o.height=l?d.size:undefined,o.width=l?undefined:d.size},_getStacks:function(t){var e,n,r=this,i=r._getIndexScale(),o=i._getMatchingVisibleMetas(r._type),a=i.options.stacked,s=o.length,l=[];for(e=0;e<s&&(n=o[e],(!1===a||-1===l.indexOf(n.stack)||a===undefined&&n.stack===undefined)&&l.push(n.stack),n.index!==t);++e);return l},getStackCount:function(){return this._getStacks().length},getStackIndex:function(t,e){var n=this._getStacks(t),r=e!==undefined?n.indexOf(e):-1;return-1===r?n.length-1:r},getRuler:function(){var t,e,n=this,r=n._getIndexScale(),i=[];for(t=0,e=n.getMeta().data.length;t<e;++t)i.push(r.getPixelForValue(null,t,n.index));return{pixels:i,start:r._startPixel,end:r._endPixel,stackCount:n.getStackCount(),scale:r}},calculateBarValuePixels:function(t,e,n){var r,i,o,a,s,l,u,c=this,d=c.chart,h=c._getValueScale(),f=h.isHorizontal(),p=d.data.datasets,g=h._getMatchingVisibleMetas(c._type),m=h._parseValue(p[t].data[e]),y=n.minBarLength,v=h.options.stacked,b=c.getMeta().stack,_=m.start===undefined?0:0<=m.max&&0<=m.min?m.min:m.max,x=m.start===undefined?m.end:0<=m.max&&0<=m.min?m.max-m.min:m.min-m.max,w=g.length;if(v||v===undefined&&b!==undefined)for(r=0;r<w&&(i=g[r]).index!==t;++r)i.stack===b&&(o=(u=h._parseValue(p[i.index].data[e])).start===undefined?u.end:0<=u.min&&0<=u.max?u.max:u.min,(m.min<0&&o<0||0<=m.max&&0<o)&&(_+=o));return a=h.getPixelForValue(_),l=(s=h.getPixelForValue(_+x))-a,y!==undefined&&Math.abs(l)<y&&(l=y,s=0<=x&&!f||x<0&&f?a-y:a+y),{size:l,base:a,head:s,center:s+l/2}},calculateBarIndexPixels:function(t,e,n,r){var i=this,o="flex"===r.barThickness?V(e,n,r):B(e,n,r),a=i.getStackIndex(t,i.getMeta().stack),s=o.start+o.chunk*a+o.chunk/2,l=Math.min(nr(r.maxBarThickness,Infinity),o.chunk*o.ratio);return{base:s-l/2,head:s+l/2,center:s,size:l}},draw:function(){var t=this,e=t.chart,n=t._getValueScale(),r=t.getMeta().data,i=t.getDataset(),o=r.length,a=0;for(kn.canvas.clipArea(e.ctx,e.chartArea);a<o;++a){var s=n._parseValue(i.data[a]);isNaN(s.min)||isNaN(s.max)||r[a].draw()}kn.canvas.unclipArea(e.ctx)},_resolveDataElementOptions:function(){var t=this,e=kn.extend({},jn.prototype._resolveDataElementOptions.apply(t,arguments)),n=t._getIndexScale().options,r=t._getValueScale().options;return e.barPercentage=nr(n.barPercentage,e.barPercentage),e.barThickness=nr(n.barThickness,e.barThickness),e.categoryPercentage=nr(n.categoryPercentage,e.categoryPercentage),e.maxBarThickness=nr(n.maxBarThickness,e.maxBarThickness),e.minBarLength=nr(r.minBarLength,e.minBarLength),e}}),ir=kn.valueOrDefault,or=kn.options.resolve;vn._set("bubble",{hover:{mode:"single"},scales:{xAxes:[{type:"linear",position:"bottom",id:"x-axis-0"}],yAxes:[{type:"linear",position:"left",id:"y-axis-0"}]},tooltips:{callbacks:{title:function(){return""},label:function(t,e){var n=e.datasets[t.datasetIndex].label||"",r=e.datasets[t.datasetIndex].data[t.index];return n+": ("+t.xLabel+", "+t.yLabel+", "+r.r+")"}}}});var ar=jn.extend({dataElementType:Qn.Point,_dataElementOptions:["backgroundColor","borderColor","borderWidth","hoverBackgroundColor","hoverBorderColor","hoverBorderWidth","hoverRadius","hitRadius","pointStyle","rotation"],update:function(n){
var r=this,t=r.getMeta().data;kn.each(t,function(t,e){r.updateElement(t,e,n)})},updateElement:function(t,e,n){var r=this,i=r.getMeta(),o=t.custom||{},a=r.getScaleForId(i.xAxisID),s=r.getScaleForId(i.yAxisID),l=r._resolveDataElementOptions(t,e),u=r.getDataset().data[e],c=r.index,d=n?a.getPixelForDecimal(.5):a.getPixelForValue("object"==typeof u?u:NaN,e,c),h=n?s.getBasePixel():s.getPixelForValue(u,e,c);t._xScale=a,t._yScale=s,t._options=l,t._datasetIndex=c,t._index=e,t._model={backgroundColor:l.backgroundColor,borderColor:l.borderColor,borderWidth:l.borderWidth,hitRadius:l.hitRadius,pointStyle:l.pointStyle,rotation:l.rotation,radius:n?0:l.radius,skip:o.skip||isNaN(d)||isNaN(h),x:d,y:h},t.pivot()},setHoverStyle:function(t){var e=t._model,n=t._options,r=kn.getHoverColor;t.$previousStyle={backgroundColor:e.backgroundColor,borderColor:e.borderColor,borderWidth:e.borderWidth,radius:e.radius},e.backgroundColor=ir(n.hoverBackgroundColor,r(n.backgroundColor)),e.borderColor=ir(n.hoverBorderColor,r(n.borderColor)),e.borderWidth=ir(n.hoverBorderWidth,n.borderWidth),e.radius=n.radius+n.hoverRadius},_resolveDataElementOptions:function(t,e){var n=this,r=n.chart,i=n.getDataset(),o=t.custom||{},a=i.data[e]||{},s=jn.prototype._resolveDataElementOptions.apply(n,arguments),l={chart:r,dataIndex:e,dataset:i,datasetIndex:n.index};return n._cachedDataOpts===s&&(s=kn.extend({},s)),s.radius=or([o.radius,a.r,n._config.radius,r.options.elements.point.radius],l,e),s}}),sr=kn.valueOrDefault,lr=Math.PI,ur=2*lr,cr=lr/2;vn._set("doughnut",{animation:{animateRotate:!0,animateScale:!1},hover:{mode:"single"},legendCallback:function(t){var e,n,r,i=document.createElement("ul"),o=t.data,a=o.datasets,s=o.labels;if(i.setAttribute("class",t.id+"-legend"),a.length)for(n=a[e=0].data.length;e<n;++e)(r=i.appendChild(document.createElement("li"))).appendChild(document.createElement("span")).style.backgroundColor=a[0].backgroundColor[e],s[e]&&r.appendChild(document.createTextNode(s[e]));return i.outerHTML},legend:{labels:{generateLabels:function(i){var o=i.data;return o.labels.length&&o.datasets.length?o.labels.map(function(t,e){var n=i.getDatasetMeta(0),r=n.controller.getStyle(e);return{text:t,fillStyle:r.backgroundColor,strokeStyle:r.borderColor,lineWidth:r.borderWidth,hidden:isNaN(o.datasets[0].data[e])||n.data[e].hidden,index:e}}):[]}},onClick:function(t,e){var n,r,i,o=e.index,a=this.chart;for(n=0,r=(a.data.datasets||[]).length;n<r;++n)(i=a.getDatasetMeta(n)).data[o]&&(i.data[o].hidden=!i.data[o].hidden);a.update()}},cutoutPercentage:50,rotation:-cr,circumference:ur,tooltips:{callbacks:{title:function(){return""},label:function(t,e){var n=e.labels[t.index],r=": "+e.datasets[t.datasetIndex].data[t.index];return kn.isArray(n)?(n=n.slice())[0]+=r:n+=r,n}}}});var dr=jn.extend({dataElementType:Qn.Arc,linkScales:kn.noop,_dataElementOptions:["backgroundColor","borderColor","borderWidth","borderAlign","hoverBackgroundColor","hoverBorderColor","hoverBorderWidth"],getRingIndex:function(t){for(var e=0,n=0;n<t;++n)this.chart.isDatasetVisible(n)&&++e;return e},update:function(t){var e,n,r,i,o=this,a=o.chart,s=a.chartArea,l=a.options,u=1,c=1,d=0,h=0,f=o.getMeta(),p=f.data,g=l.cutoutPercentage/100||0,m=l.circumference,y=o._getRingWeight(o.index);if(m<ur){var v=l.rotation%ur,b=(v+=lr<=v?-ur:v<-lr?ur:0)+m,_=Math.cos(v),x=Math.sin(v),w=Math.cos(b),S=Math.sin(b),T=v<=0&&0<=b||ur<=b,k=v<=cr&&cr<=b||ur+cr<=b,C=v<=-cr&&-cr<=b||lr+cr<=b,E=v===-lr||lr<=b?-1:Math.min(_,_*g,w,w*g),D=C?-1:Math.min(x,x*g,S,S*g),A=T?1:Math.max(_,_*g,w,w*g),M=k?1:Math.max(x,x*g,S,S*g);u=(A-E)/2,c=(M-D)/2,d=-(A+E)/2,h=-(M+D)/2}for(r=0,i=p.length;r<i;++r)p[r]._options=o._resolveDataElementOptions(p[r],r);for(a.borderWidth=o.getMaxBorderWidth(),e=(s.right-s.left-a.borderWidth)/u,n=(s.bottom-s.top-a.borderWidth)/c,a.outerRadius=Math.max(Math.min(e,n)/2,0),a.innerRadius=Math.max(a.outerRadius*g,0),a.radiusLength=(a.outerRadius-a.innerRadius)/(o._getVisibleDatasetWeightTotal()||1),a.offsetX=d*a.outerRadius,a.offsetY=h*a.outerRadius,f.total=o.calculateTotal(),o.outerRadius=a.outerRadius-a.radiusLength*o._getRingWeightOffset(o.index),o.innerRadius=Math.max(o.outerRadius-a.radiusLength*y,0),r=0,i=p.length;r<i;++r)o.updateElement(p[r],r,t)},updateElement:function(t,e,n){var r=this,i=r.chart,o=i.chartArea,a=i.options,s=a.animation,l=(o.left+o.right)/2,u=(o.top+o.bottom)/2,c=a.rotation,d=a.rotation,h=r.getDataset(),f=n&&s.animateRotate?0:t.hidden?0:r.calculateCircumference(h.data[e])*(a.circumference/ur),p=n&&s.animateScale?0:r.innerRadius,g=n&&s.animateScale?0:r.outerRadius,m=t._options||{};kn.extend(t,{_datasetIndex:r.index,_index:e,_model:{backgroundColor:m.backgroundColor,borderColor:m.borderColor,borderWidth:m.borderWidth,borderAlign:m.borderAlign,x:l+i.offsetX,y:u+i.offsetY,startAngle:c,endAngle:d,circumference:f,outerRadius:g,innerRadius:p,label:kn.valueAtIndexOrDefault(h.label,e,i.data.labels[e])}});var y=t._model;n&&s.animateRotate||(y.startAngle=0===e?a.rotation:r.getMeta().data[e-1]._model.endAngle,y.endAngle=y.startAngle+y.circumference),t.pivot()},calculateTotal:function(){var n,r=this.getDataset(),t=this.getMeta(),i=0;return kn.each(t.data,function(t,e){n=r.data[e],isNaN(n)||t.hidden||(i+=Math.abs(n))}),i},calculateCircumference:function(t){var e=this.getMeta().total;return 0<e&&!isNaN(t)?ur*(Math.abs(t)/e):0},getMaxBorderWidth:function(t){var e,n,r,i,o,a,s,l,u=this,c=0,d=u.chart;if(!t)for(e=0,n=d.data.datasets.length;e<n;++e)if(d.isDatasetVisible(e)){t=(r=d.getDatasetMeta(e)).data,e!==u.index&&(o=r.controller);break}if(!t)return 0;for(e=0,n=t.length;e<n;++e)i=t[e],o?(o._configure(),a=o._resolveDataElementOptions(i,e)):a=i._options,"inner"!==a.borderAlign&&(c=(c=c<(s=a.borderWidth)?s:c)<(l=a.hoverBorderWidth)?l:c);return c},setHoverStyle:function(t){var e=t._model,n=t._options,r=kn.getHoverColor;t.$previousStyle={backgroundColor:e.backgroundColor,borderColor:e.borderColor,borderWidth:e.borderWidth},e.backgroundColor=sr(n.hoverBackgroundColor,r(n.backgroundColor)),e.borderColor=sr(n.hoverBorderColor,r(n.borderColor)),e.borderWidth=sr(n.hoverBorderWidth,n.borderWidth)},_getRingWeightOffset:function(t){for(var e=0,n=0;n<t;++n)this.chart.isDatasetVisible(n)&&(e+=this._getRingWeight(n));return e},_getRingWeight:function(t){return Math.max(sr(this.chart.data.datasets[t].weight,1),0)},_getVisibleDatasetWeightTotal:function(){return this._getRingWeightOffset(this.chart.data.datasets.length)}});vn._set("horizontalBar",{hover:{mode:"index",axis:"y"},scales:{xAxes:[{type:"linear",position:"bottom"}],yAxes:[{type:"category",position:"left",offset:!0,gridLines:{offsetGridLines:!0}}]},elements:{rectangle:{borderSkipped:"left"}},tooltips:{mode:"index",axis:"y"}}),vn._set("global",{datasets:{horizontalBar:{categoryPercentage:.8,barPercentage:.9}}});var hr=rr.extend({_getValueScaleId:function(){return this.getMeta().xAxisID},_getIndexScaleId:function(){return this.getMeta().yAxisID}}),fr=kn.valueOrDefault,pr=kn.options.resolve,gr=kn.canvas._isPointInArea;vn._set("line",{showLines:!0,spanGaps:!1,hover:{mode:"label"},scales:{xAxes:[{type:"category",id:"x-axis-0"}],yAxes:[{type:"linear",id:"y-axis-0"}]}});var mr=jn.extend({datasetElementType:Qn.Line,dataElementType:Qn.Point,_datasetElementOptions:["backgroundColor","borderCapStyle","borderColor","borderDash","borderDashOffset","borderJoinStyle","borderWidth","cubicInterpolationMode","fill"],_dataElementOptions:{backgroundColor:"pointBackgroundColor",borderColor:"pointBorderColor",borderWidth:"pointBorderWidth",hitRadius:"pointHitRadius",hoverBackgroundColor:"pointHoverBackgroundColor",hoverBorderColor:"pointHoverBorderColor",hoverBorderWidth:"pointHoverBorderWidth",hoverRadius:"pointHoverRadius",pointStyle:"pointStyle",radius:"pointRadius",rotation:"pointRotation"},update:function(t){var e,n,r=this,i=r.getMeta(),o=i.dataset,a=i.data||[],s=r.chart.options,l=r._config,u=r._showLine=fr(l.showLine,s.showLines);for(r._xScale=r.getScaleForId(i.xAxisID),r._yScale=r.getScaleForId(i.yAxisID),u&&(l.tension!==undefined&&l.lineTension===undefined&&(l.lineTension=l.tension),o._scale=r._yScale,o._datasetIndex=r.index,o._children=a,o._model=r._resolveDatasetElementOptions(o),o.pivot()),e=0,n=a.length;e<n;++e)r.updateElement(a[e],e,t);for(u&&0!==o._model.tension&&r.updateBezierControlPoints(),e=0,n=a.length;e<n;++e)a[e].pivot()},updateElement:function(t,e,n){var r,i,o=this,a=o.getMeta(),s=t.custom||{},l=o.getDataset(),u=o.index,c=l.data[e],d=o._xScale,h=o._yScale,f=a.dataset._model,p=o._resolveDataElementOptions(t,e);r=d.getPixelForValue("object"==typeof c?c:NaN,e,u),i=n?h.getBasePixel():o.calculatePointY(c,e,u),t._xScale=d,t._yScale=h,t._options=p,t._datasetIndex=u,t._index=e,t._model={x:r,y:i,skip:s.skip||isNaN(r)||isNaN(i),radius:p.radius,pointStyle:p.pointStyle,rotation:p.rotation,backgroundColor:p.backgroundColor,borderColor:p.borderColor,borderWidth:p.borderWidth,tension:fr(s.tension,f?f.tension:0),steppedLine:!!f&&f.steppedLine,hitRadius:p.hitRadius}},_resolveDatasetElementOptions:function(t){var e=this,n=e._config,r=t.custom||{},i=e.chart.options,o=i.elements.line,a=jn.prototype._resolveDatasetElementOptions.apply(e,arguments);return a.spanGaps=fr(n.spanGaps,i.spanGaps),a.tension=fr(n.lineTension,o.tension),a.steppedLine=pr([r.steppedLine,n.steppedLine,o.stepped]),a.clip=Y(fr(n.clip,U(e._xScale,e._yScale,a.borderWidth))),a},calculatePointY:function(t,e,n){var r,i,o,a,s,l,u,c=this,d=c.chart,h=c._yScale,f=0,p=0;if(h.options.stacked){for(s=+h.getRightValue(t),u=(l=d._getSortedVisibleDatasetMetas()).length,r=0;r<u&&(o=l[r]).index!==n;++r)i=d.data.datasets[o.index],"line"===o.type&&o.yAxisID===h.id&&((a=+h.getRightValue(i.data[e]))<0?p+=a||0:f+=a||0);return s<0?h.getPixelForValue(p+s):h.getPixelForValue(f+s)}return h.getPixelForValue(t)},updateBezierControlPoints:function(){function t(t,e,n){return Math.max(Math.min(t,n),e)}var e,n,r,i,o=this,a=o.chart,s=o.getMeta(),l=s.dataset._model,u=a.chartArea,c=s.data||[];if(l.spanGaps&&(c=c.filter(function(t){return!t._model.skip})),"monotone"===l.cubicInterpolationMode)kn.splineCurveMonotone(c);else for(e=0,n=c.length;e<n;++e)r=c[e]._model,i=kn.splineCurve(kn.previousItem(c,e)._model,r,kn.nextItem(c,e)._model,l.tension),r.controlPointPreviousX=i.previous.x,r.controlPointPreviousY=i.previous.y,r.controlPointNextX=i.next.x,r.controlPointNextY=i.next.y;if(a.options.elements.line.capBezierPoints)for(e=0,n=c.length;e<n;++e)r=c[e]._model,gr(r,u)&&(0<e&&gr(c[e-1]._model,u)&&(r.controlPointPreviousX=t(r.controlPointPreviousX,u.left,u.right),r.controlPointPreviousY=t(r.controlPointPreviousY,u.top,u.bottom)),e<c.length-1&&gr(c[e+1]._model,u)&&(r.controlPointNextX=t(r.controlPointNextX,u.left,u.right),r.controlPointNextY=t(r.controlPointNextY,u.top,u.bottom)))},draw:function(){var t,e=this,n=e.chart,r=e.getMeta(),i=r.data||[],o=n.chartArea,a=n.canvas,s=0,l=i.length;for(e._showLine&&(t=r.dataset._model.clip,kn.canvas.clipArea(n.ctx,{left:!1===t.left?0:o.left-t.left,right:!1===t.right?a.width:o.right+t.right,top:!1===t.top?0:o.top-t.top,bottom:!1===t.bottom?a.height:o.bottom+t.bottom}),r.dataset.draw(),kn.canvas.unclipArea(n.ctx));s<l;++s)i[s].draw(o)},setHoverStyle:function(t){var e=t._model,n=t._options,r=kn.getHoverColor;t.$previousStyle={backgroundColor:e.backgroundColor,borderColor:e.borderColor,borderWidth:e.borderWidth,radius:e.radius},e.backgroundColor=fr(n.hoverBackgroundColor,r(n.backgroundColor)),e.borderColor=fr(n.hoverBorderColor,r(n.borderColor)),e.borderWidth=fr(n.hoverBorderWidth,n.borderWidth),e.radius=fr(n.hoverRadius,n.radius)}}),yr=kn.options.resolve;vn._set("polarArea",{scale:{type:"radialLinear",angleLines:{display:!1},gridLines:{circular:!0},pointLabels:{display:!1},ticks:{beginAtZero:!0}},animation:{animateRotate:!0,animateScale:!0},startAngle:-.5*Math.PI,legendCallback:function(t){var e,n,r,i=document.createElement("ul"),o=t.data,a=o.datasets,s=o.labels;if(i.setAttribute("class",t.id+"-legend"),a.length)for(n=a[e=0].data.length;e<n;++e)(r=i.appendChild(document.createElement("li"))).appendChild(document.createElement("span")).style.backgroundColor=a[0].backgroundColor[e],s[e]&&r.appendChild(document.createTextNode(s[e]));return i.outerHTML},legend:{labels:{generateLabels:function(i){var o=i.data;return o.labels.length&&o.datasets.length?o.labels.map(function(t,e){var n=i.getDatasetMeta(0),r=n.controller.getStyle(e);return{text:t,fillStyle:r.backgroundColor,strokeStyle:r.borderColor,lineWidth:r.borderWidth,hidden:isNaN(o.datasets[0].data[e])||n.data[e].hidden,index:e}}):[]}},onClick:function(t,e){var n,r,i,o=e.index,a=this.chart;for(n=0,r=(a.data.datasets||[]).length;n<r;++n)(i=a.getDatasetMeta(n)).data[o].hidden=!i.data[o].hidden;a.update()}},tooltips:{callbacks:{title:function(){return""},label:function(t,e){return e.labels[t.index]+": "+t.yLabel}}}});var vr=jn.extend({dataElementType:Qn.Arc,linkScales:kn.noop,_dataElementOptions:["backgroundColor","borderColor","borderWidth","borderAlign","hoverBackgroundColor","hoverBorderColor","hoverBorderWidth"],_getIndexScaleId:function(){return this.chart.scale.id},_getValueScaleId:function(){return this.chart.scale.id},update:function(t){var e,n,r,i=this,o=i.getDataset(),a=i.getMeta(),s=i.chart.options.startAngle||0,l=i._starts=[],u=i._angles=[],c=a.data;for(i._updateRadius(),a.count=i.countVisibleElements(),e=0,n=o.data.length;e<n;e++)l[e]=s,r=i._computeAngle(e),s+=u[e]=r;for(e=0,n=c.length;e<n;++e)c[e]._options=i._resolveDataElementOptions(c[e],e),i.updateElement(c[e],e,t)},_updateRadius:function(){var t=this,e=t.chart,n=e.chartArea,r=e.options,i=Math.min(n.right-n.left,n.bottom-n.top);e.outerRadius=Math.max(i/2,0),e.innerRadius=Math.max(r.cutoutPercentage?e.outerRadius/100*r.cutoutPercentage:1,0),e.radiusLength=(e.outerRadius-e.innerRadius)/e.getVisibleDatasetCount(),t.outerRadius=e.outerRadius-e.radiusLength*t.index,t.innerRadius=t.outerRadius-e.radiusLength},updateElement:function(t,e,n){var r=this,i=r.chart,o=r.getDataset(),a=i.options,s=a.animation,l=i.scale,u=i.data.labels,c=l.xCenter,d=l.yCenter,h=a.startAngle,f=t.hidden?0:l.getDistanceFromCenterForValue(o.data[e]),p=r._starts[e],g=p+(t.hidden?0:r._angles[e]),m=s.animateScale?0:l.getDistanceFromCenterForValue(o.data[e]),y=t._options||{};kn.extend(t,{_datasetIndex:r.index,_index:e,_scale:l,_model:{backgroundColor:y.backgroundColor,borderColor:y.borderColor,borderWidth:y.borderWidth,borderAlign:y.borderAlign,x:c,y:d,innerRadius:0,outerRadius:n?m:f,startAngle:n&&s.animateRotate?h:p,endAngle:n&&s.animateRotate?h:g,label:kn.valueAtIndexOrDefault(u,e,u[e])}}),t.pivot()},countVisibleElements:function(){var n=this.getDataset(),t=this.getMeta(),r=0;return kn.each(t.data,function(t,e){isNaN(n.data[e])||t.hidden||r++}),r},setHoverStyle:function(t){var e=t._model,n=t._options,r=kn.getHoverColor,i=kn.valueOrDefault;t.$previousStyle={backgroundColor:e.backgroundColor,borderColor:e.borderColor,borderWidth:e.borderWidth},e.backgroundColor=i(n.hoverBackgroundColor,r(n.backgroundColor)),e.borderColor=i(n.hoverBorderColor,r(n.borderColor)),e.borderWidth=i(n.hoverBorderWidth,n.borderWidth)},_computeAngle:function(t){var e=this,n=this.getMeta().count,r=e.getDataset(),i=e.getMeta();if(isNaN(r.data[t])||i.data[t].hidden)return 0;var o={chart:e.chart,dataIndex:t,dataset:r,datasetIndex:e.index};return yr([e.chart.options.elements.arc.angle,2*Math.PI/n],o,t)}});vn._set("pie",kn.clone(vn.doughnut)),vn._set("pie",{cutoutPercentage:0});var br=dr,_r=kn.valueOrDefault;vn._set("radar",{spanGaps:!1,scale:{type:"radialLinear"},elements:{line:{fill:"start",tension:0}}});var xr=jn.extend({datasetElementType:Qn.Line,dataElementType:Qn.Point,linkScales:kn.noop,_datasetElementOptions:["backgroundColor","borderWidth","borderColor","borderCapStyle","borderDash","borderDashOffset","borderJoinStyle","fill"],_dataElementOptions:{backgroundColor:"pointBackgroundColor",borderColor:"pointBorderColor",borderWidth:"pointBorderWidth",hitRadius:"pointHitRadius",hoverBackgroundColor:"pointHoverBackgroundColor",hoverBorderColor:"pointHoverBorderColor",hoverBorderWidth:"pointHoverBorderWidth",hoverRadius:"pointHoverRadius",pointStyle:"pointStyle",radius:"pointRadius",rotation:"pointRotation"},_getIndexScaleId:function(){return this.chart.scale.id},_getValueScaleId:function(){return this.chart.scale.id},update:function(t){var e,n,r=this,i=r.getMeta(),o=i.dataset,a=i.data||[],s=r.chart.scale,l=r._config;for(l.tension!==undefined&&l.lineTension===undefined&&(l.lineTension=l.tension),o._scale=s,o._datasetIndex=r.index,o._children=a,o._loop=!0,o._model=r._resolveDatasetElementOptions(o),o.pivot(),e=0,n=a.length;e<n;++e)r.updateElement(a[e],e,t);for(r.updateBezierControlPoints(),e=0,n=a.length;e<n;++e)a[e].pivot()},updateElement:function(t,e,n){var r=this,i=t.custom||{},o=r.getDataset(),a=r.chart.scale,s=a.getPointPositionForValue(e,o.data[e]),l=r._resolveDataElementOptions(t,e),u=r.getMeta().dataset._model,c=n?a.xCenter:s.x,d=n?a.yCenter:s.y;t._scale=a,t._options=l,t._datasetIndex=r.index,t._index=e,t._model={x:c,y:d,skip:i.skip||isNaN(c)||isNaN(d),radius:l.radius,pointStyle:l.pointStyle,rotation:l.rotation,backgroundColor:l.backgroundColor,borderColor:l.borderColor,borderWidth:l.borderWidth,tension:_r(i.tension,u?u.tension:0),hitRadius:l.hitRadius}},_resolveDatasetElementOptions:function(){var t=this,e=t._config,n=t.chart.options,r=jn.prototype._resolveDatasetElementOptions.apply(t,arguments);return r.spanGaps=_r(e.spanGaps,n.spanGaps),r.tension=_r(e.lineTension,n.elements.line.tension),r},updateBezierControlPoints:function(){function t(t,e,n){return Math.max(Math.min(t,n),e)}var e,n,r,i,o=this,a=o.getMeta(),s=o.chart.chartArea,l=a.data||[];for(a.dataset._model.spanGaps&&(l=l.filter(function(t){return!t._model.skip})),e=0,n=l.length;e<n;++e)r=l[e]._model,i=kn.splineCurve(kn.previousItem(l,e,!0)._model,r,kn.nextItem(l,e,!0)._model,r.tension),r.controlPointPreviousX=t(i.previous.x,s.left,s.right),r.controlPointPreviousY=t(i.previous.y,s.top,s.bottom),r.controlPointNextX=t(i.next.x,s.left,s.right),r.controlPointNextY=t(i.next.y,s.top,s.bottom)},setHoverStyle:function(t){var e=t._model,n=t._options,r=kn.getHoverColor;t.$previousStyle={backgroundColor:e.backgroundColor,borderColor:e.borderColor,borderWidth:e.borderWidth,radius:e.radius},e.backgroundColor=_r(n.hoverBackgroundColor,r(n.backgroundColor)),e.borderColor=_r(n.hoverBorderColor,r(n.borderColor)),e.borderWidth=_r(n.hoverBorderWidth,n.borderWidth),e.radius=_r(n.hoverRadius,n.radius)}});vn._set("scatter",{hover:{mode:"single"},scales:{xAxes:[{id:"x-axis-1",type:"linear",position:"bottom"}],yAxes:[{id:"y-axis-1",type:"linear",position:"left"}]},tooltips:{callbacks:{title:function(){return""},label:function(t){return"("+t.xLabel+", "+t.yLabel+")"}}}}),vn._set("global",{datasets:{scatter:{showLine:!1}}});var wr={bar:rr,bubble:ar,doughnut:dr,horizontalBar:hr,line:mr,polarArea:vr,pie:br,radar:xr,scatter:mr},Sr={modes:{single:function(t,e){var n=G(e,t),r=[];return K(t,function(t){if(t.inRange(n.x,n.y))return r.push(t),r}),r.slice(0,1)},label:Z,index:Z,dataset:function(t,e,n){var r=G(e,t);n.axis=n.axis||"xy";var i=$(n.axis),o=n.intersect?X(t,r):Q(t,r,!1,i);return 0<o.length&&(o=t.getDatasetMeta(o[0]._datasetIndex).data),o},"x-axis":function(t,e){return Z(t,e,{intersect:!1})},point:function(t,e){return X(t,G(e,t))},nearest:function(t,e,n){var r=G(e,t);n.axis=n.axis||"xy";var i=$(n.axis);return Q(t,r,n.intersect,i)},x:function(t,e,n){var r=G(e,t),i=[],o=!1;return K(t,function(t){t.inXRange(r.x)&&i.push(t),t.inRange(r.x,r.y)&&(o=!0)}),n.intersect&&!o&&(i=[]),i},y:function(t,e,n){var r=G(e,t),i=[],o=!1;return K(t,function(t){t.inYRange(r.y)&&i.push(t),t.inRange(r.x,r.y)&&(o=!0)}),n.intersect&&!o&&(i=[]),i}}},Tr=kn.extend;vn._set("global",{layout:{padding:{top:0,right:0,bottom:0,left:0}}});var kr={defaults:{},addBox:function(t,e){t.boxes||(t.boxes=[]),e.fullWidth=e.fullWidth||!1,e.position=e.position||"top",e.weight=e.weight||0,e._layers=e._layers||function(){return[{z:0,draw:function(){e.draw.apply(e,arguments)}}]},t.boxes.push(e)},removeBox:function(t,e){var n=t.boxes?t.boxes.indexOf(e):-1;-1!==n&&t.boxes.splice(n,1)},configure:function(t,e,n){for(var r,i=["fullWidth","position","weight"],o=i.length,a=0;a<o;++a)r=i[a],n.hasOwnProperty(r)&&(e[r]=n[r])},update:function(n,t,e){if(n){var r=n.options.layout||{},i=kn.options.toPadding(r.padding),o=t-i.width,a=e-i.height,s=rt(n.boxes),l=s.vertical,u=s.horizontal,c=Object.freeze({outerWidth:t,outerHeight:e,padding:i,availableWidth:o,vBoxMaxWidth:o/2/l.length,hBoxMaxHeight:a/2}),d=Tr({maxPadding:Tr({},i),w:o,h:a,x:i.left,y:i.top},i);nt(l.concat(u),c),lt(l,d,c),lt(u,d,c)&&lt(l,d,c),at(d),ut(s.leftAndTop,d,c),d.x+=d.w,d.y+=d.h,ut(s.rightAndBottom,d,c),n.chartArea={left:d.left,top:d.top,right:d.left+d.w,bottom:d.top+d.h},kn.each(s.chartArea,function(t){var e=t.box;Tr(e,n.chartArea),e.update(d.w,d.h)})}}},Cr={acquireContext:function(t){return t&&t.canvas&&(t=t.canvas),t&&t.getContext("2d")||null}},Er="/*\n * DOM element rendering detection\n * https://davidwalsh.name/detect-node-insertion\n */\n@keyframes chartjs-render-animation {\n\tfrom { opacity: 0.99; }\n\tto { opacity: 1; }\n}\n\n.chartjs-render-monitor {\n\tanimation: chartjs-render-animation 0.001s;\n}\n\n/*\n * DOM element resizing detection\n * https://github.com/marcj/css-element-queries\n */\n.chartjs-size-monitor,\n.chartjs-size-monitor-expand,\n.chartjs-size-monitor-shrink {\n\tposition: absolute;\n\tdirection: ltr;\n\tleft: 0;\n\ttop: 0;\n\tright: 0;\n\tbottom: 0;\n\toverflow: hidden;\n\tpointer-events: none;\n\tvisibility: hidden;\n\tz-index: -1;\n}\n\n.chartjs-size-monitor-expand > div {\n\tposition: absolute;\n\twidth: 1000000px;\n\theight: 1000000px;\n\tleft: 0;\n\ttop: 0;\n}\n\n.chartjs-size-monitor-shrink > div {\n\tposition: absolute;\n\twidth: 200%;\n\theight: 200%;\n\tleft: 0;\n\ttop: 0;\n}\n",Dr=e(Object.freeze({__proto__:null,"default":Er})),Ar="$chartjs",Mr="chartjs-",Or=Mr+"size-monitor",Ir=Mr+"render-monitor",Pr=Mr+"render-animation",Lr=["animationstart","webkitAnimationStart"],Nr={touchstart:"mousedown",touchmove:"mousemove",touchend:"mouseup",pointerenter:"mouseenter",pointerdown:"mousedown",pointermove:"mousemove",pointerup:"mouseup",pointerleave:"mouseout",pointerout:"mouseout"},Rr=!!function(){var t=!1;try{var e=Object.defineProperty({},"passive",{get:function(){t=!0}});window.addEventListener("e",null,e)}catch(n){}return t}()&&{passive:!0},Fr={disableCSSInjection:!1,_enabled:"undefined"!=typeof window&&"undefined"!=typeof document,_ensureLoaded:function(t){if(!this.disableCSSInjection){var e=t.getRootNode?t.getRootNode():document;St(e.host?e:document.head,Dr)}},acquireContext:function(t,e){"string"==typeof t?t=document.getElementById(t):t.length&&(t=t[0]),t&&t.canvas&&(t=t.canvas);var n=t&&t.getContext&&t.getContext("2d");return n&&n.canvas===t?(this._ensureLoaded(t),dt(t,e),n):null},releaseContext:function(t){var n=t.canvas;if(n[Ar]){var r=n[Ar].initial;["height","width"].forEach(function(t){var e=r[t];kn.isNullOrUndef(e)?n.removeAttribute(t):n.setAttribute(t,e)}),kn.each(r.style||{},function(t,e){n.style[e]=t}),n.width=n.width,delete n[Ar]}},addEventListener:function(e,t,n){var r=e.canvas;if("resize"!==t){var i=n[Ar]||(n[Ar]={});ht(r,t,(i.proxies||(i.proxies={}))[e.id+"_"+t]=function(t){n(gt(t,e))})}else xt(r,n,e)},removeEventListener:function(t,e,n){var r=t.canvas;if("resize"!==e){var i=((n[Ar]||{}).proxies||{})[t.id+"_"+e];i&&ft(r,e,i)}else wt(r)}};kn.addEvent=ht,kn.removeEvent=ft;var Hr=Fr._enabled?Fr:Cr,jr=kn.extend({initialize:function(){},acquireContext:function(){},releaseContext:function(){},addEventListener:function(){},removeEventListener:function(){}},Hr);vn._set("global",{plugins:{}});var Wr={_plugins:[],_cacheId:0,register:function(t){var e=this._plugins;[].concat(t).forEach(function(t){-1===e.indexOf(t)&&e.push(t)}),this._cacheId++},unregister:function(t){var n=this._plugins;[].concat(t).forEach(function(t){var e=n.indexOf(t);-1!==e&&n.splice(e,1)}),this._cacheId++},clear:function(){this._plugins=[],this._cacheId++},count:function(){return this._plugins.length},getAll:function(){return this._plugins},notify:function(t,e,n){var r,i,o,a,s,l=this.descriptors(t),u=l.length;for(r=0;r<u;++r)if("function"==typeof(s=(o=(i=l[r]).plugin)[e])&&((a=[t].concat(n||[])).push(i.options),!1===s.apply(o,a)))return!1;return!0},descriptors:function(t){var e=t.$plugins||(t.$plugins={});if(e.id===this._cacheId)return e.descriptors;var r=[],i=[],n=t&&t.config||{},o=n.options&&n.options.plugins||{};return this._plugins.concat(n.plugins||[]).forEach(function(t){if(-1===r.indexOf(t)){var e=t.id,n=o[e];!1!==n&&(!0===n&&(n=kn.clone(vn.global.plugins[e])),r.push(t),i.push({plugin:t,options:n||{}}))}}),e.descriptors=i,e.id=this._cacheId,i},_invalidate:function(t){delete t.$plugins}},zr={constructors:{},defaults:{},registerScaleType:function(t,e,n){this.constructors[t]=e,this.defaults[t]=kn.clone(n)},getScaleConstructor:function(t){return this.constructors.hasOwnProperty(t)?this.constructors[t]:undefined},getScaleDefaults:function(t){return this.defaults.hasOwnProperty(t)?kn.merge({},[vn.scale,this.defaults[t]]):{}},updateScaleDefaults:function(t,e){var n=this;n.defaults.hasOwnProperty(t)&&(n.defaults[t]=kn.extend(n.defaults[t],e))},addScalesToLayout:function(e){kn.each(e.scales,function(t){t.fullWidth=t.options.fullWidth,t.position=t.options.position,t.weight=t.options.weight,kr.addBox(e,t)})}},Br=kn.valueOrDefault,Vr=kn.rtl.getRtlAdapter;vn._set("global",{tooltips:{enabled:!0,custom:null,mode:"nearest",position:"average",intersect:!0,backgroundColor:"rgba(0,0,0,0.8)",titleFontStyle:"bold",titleSpacing:2,titleMarginBottom:6,titleFontColor:"#fff",titleAlign:"left",bodySpacing:2,bodyFontColor:"#fff",bodyAlign:"left",footerFontStyle:"bold",footerSpacing:2,footerMarginTop:6,footerFontColor:"#fff",footerAlign:"left",yPadding:6,xPadding:6,caretPadding:2,caretSize:5,cornerRadius:6,multiKeyBackground:"#fff",displayColors:!0,borderColor:"rgba(0,0,0,0)",borderWidth:0,callbacks:{beforeTitle:kn.noop,title:function(t,e){var n="",r=e.labels,i=r?r.length:0;if(0<t.length){var o=t[0];o.label?n=o.label:o.xLabel?n=o.xLabel:0<i&&o.index<i&&(n=r[o.index])}return n},afterTitle:kn.noop,beforeBody:kn.noop,beforeLabel:kn.noop,label:function(t,e){var n=e.datasets[t.datasetIndex].label||"";return n&&(n+=": "),kn.isNullOrUndef(t.value)?n+=t.yLabel:n+=t.value,n},labelColor:function(t,e){var n=e.getDatasetMeta(t.datasetIndex).data[t.index]._view;return{borderColor:n.borderColor,backgroundColor:n.backgroundColor}},labelTextColor:function(){return this._options.bodyFontColor},afterLabel:kn.noop,afterBody:kn.noop,beforeFooter:kn.noop,footer:kn.noop,afterFooter:kn.noop}}});var qr={average:function(t){if(!t.length)return!1;var e,n,r=0,i=0,o=0;for(e=0,n=t.length;e<n;++e){var a=t[e];if(a&&a.hasValue()){var s=a.tooltipPosition();r+=s.x,i+=s.y,++o}}return{x:r/o,y:i/o}},nearest:function(t,e){var n,r,i,o=e.x,a=e.y,s=Number.POSITIVE_INFINITY;for(n=0,r=t.length;n<r;++n){var l=t[n];if(l&&l.hasValue()){var u=l.getCenterPoint(),c=kn.distanceBetweenPoints(e,u);c<s&&(s=c,i=l)}}if(i){var d=i.tooltipPosition();o=d.x,a=d.y}return{x:o,y:a}}},Ur=In.extend({initialize:function(){this._model=Et(this._options),this._lastActive=[]},getTitle:function(){var t=this,e=t._options.callbacks,n=e.beforeTitle.apply(t,arguments),r=e.title.apply(t,arguments),i=e.afterTitle.apply(t,arguments),o=[];return o=Tt(o=Tt(o=Tt(o,kt(n)),kt(r)),kt(i))},getBeforeBody:function(){return It(this._options.callbacks.beforeBody.apply(this,arguments))},getBody:function(t,n){var r=this,i=r._options.callbacks,o=[];return kn.each(t,function(t){var e={before:[],lines:[],after:[]};Tt(e.before,kt(i.beforeLabel.call(r,t,n))),Tt(e.lines,i.label.call(r,t,n)),Tt(e.after,kt(i.afterLabel.call(r,t,n))),o.push(e)}),o},getAfterBody:function(){return It(this._options.callbacks.afterBody.apply(this,arguments))},getFooter:function(){var t=this,e=t._options.callbacks,n=e.beforeFooter.apply(t,arguments),r=e.footer.apply(t,arguments),i=e.afterFooter.apply(t,arguments),o=[];return o=Tt(o=Tt(o=Tt(o,kt(n)),kt(r)),kt(i))},update:function(t){var e,n,r=this,i=r._options,o=r._model,a=r._model=Et(i),s=r._active,l=r._data,u={xAlign:o.xAlign,yAlign:o.yAlign},c={x:o.x,y:o.y},d={width:o.width,height:o.height},h={x:o.caretX,y:o.caretY};if(s.length){a.opacity=1;var f=[],p=[];h=qr[i.position].call(r,s,r._eventPosition);var g=[];for(e=0,n=s.length;e<n;++e)g.push(Ct(s[e]));i.filter&&(g=g.filter(function(t){return i.filter(t,l)})),i.itemSort&&(g=g.sort(function(t,e){return i.itemSort(t,e,l)})),kn.each(g,function(t){f.push(i.callbacks.labelColor.call(r,t,r._chart)),p.push(i.callbacks.labelTextColor.call(r,t,r._chart))}),a.title=r.getTitle(g,l),a.beforeBody=r.getBeforeBody(g,l),a.body=r.getBody(g,l),a.afterBody=r.getAfterBody(g,l),a.footer=r.getFooter(g,l),a.x=h.x,a.y=h.y,a.caretPadding=i.caretPadding,a.labelColors=f,a.labelTextColors=p,a.dataPoints=g,c=Mt(a,d=Dt(this,a),u=At(this,d),r._chart)}else a.opacity=0;return a.xAlign=u.xAlign,a.yAlign=u.yAlign,a.x=c.x,a.y=c.y,a.width=d.width,a.height=d.height,a.caretX=h.x,a.caretY=h.y,r._model=a,t&&i.custom&&i.custom.call(r,a),r},drawCaret:function(t,e){var n=this._chart.ctx,r=this._view,i=this.getCaretPosition(t,e,r);n.lineTo(i.x1,i.y1),n.lineTo(i.x2,i.y2),n.lineTo(i.x3,i.y3)},getCaretPosition:function(t,e,n){var r,i,o,a,s,l,u=n.caretSize,c=n.cornerRadius,d=n.xAlign,h=n.yAlign,f=t.x,p=t.y,g=e.width,m=e.height;if("center"===h)s=p+m/2,"left"===d?(i=(r=f)-u,o=r,a=s+u,l=s-u):(i=(r=f+g)+u,o=r,a=s-u,l=s+u);else if(r="left"===d?(i=f+c+u)-u:"right"===d?(i=f+g-c-u)-u:(i=n.caretX)-u,o=i+u,"top"===h)s=(a=p)-u,l=a;else{s=(a=p+m)+u,l=a;var y=o;o=r,r=y}return{x1:r,x2:i,x3:o,y1:a,y2:s,y3:l}},drawTitle:function(t,e,n){var r,i,o,a=e.title,s=a.length;if(s){var l=Vr(e.rtl,e.x,e.width);for(t.x=Ot(e,e._titleAlign),n.textAlign=l.textAlign(e._titleAlign),n.textBaseline="middle",r=e.titleFontSize,i=e.titleSpacing,n.fillStyle=e.titleFontColor,n.font=kn.fontString(r,e._titleFontStyle,e._titleFontFamily),o=0;o<s;++o)n.fillText(a[o],l.x(t.x),t.y+r/2),t.y+=r+i,o+1===s&&(t.y+=e.titleMarginBottom-i)}},drawBody:function(e,t,n){var r,i,o,a,s,l,u,c,d=t.bodyFontSize,h=t.bodySpacing,f=t._bodyAlign,p=t.body,g=t.displayColors,m=0,y=g?Ot(t,"left"):0,v=Vr(t.rtl,t.x,t.width),b=function(t){n.fillText(t,v.x(e.x+m),e.y+d/2),e.y+=d+h},_=v.textAlign(f);for(n.textAlign=f,n.textBaseline="middle",n.font=kn.fontString(d,t._bodyFontStyle,t._bodyFontFamily),e.x=Ot(t,_),n.fillStyle=t.bodyFontColor,kn.each(t.beforeBody,b),m=g&&"right"!==_?"center"===f?d/2+1:d+2:0,s=0,u=p.length;s<u;++s){for(r=p[s],i=t.labelTextColors[s],o=t.labelColors[s],n.fillStyle=i,kn.each(r.before,b),l=0,c=(a=r.lines).length;l<c;++l){if(g){var x=v.x(y);n.fillStyle=t.legendColorBackground,n.fillRect(v.leftForLtr(x,d),e.y,d,d),n.lineWidth=1,n.strokeStyle=o.borderColor,n.strokeRect(v.leftForLtr(x,d),e.y,d,d),n.fillStyle=o.backgroundColor,n.fillRect(v.leftForLtr(v.xPlus(x,1),d-2),e.y+1,d-2,d-2),n.fillStyle=i}b(a[l])}kn.each(r.after,b)}m=0,kn.each(t.afterBody,b),e.y-=h},drawFooter:function(t,e,n){var r,i,o=e.footer,a=o.length;if(a){var s=Vr(e.rtl,e.x,e.width);for(t.x=Ot(e,e._footerAlign),t.y+=e.footerMarginTop,n.textAlign=s.textAlign(e._footerAlign),n.textBaseline="middle",r=e.footerFontSize,n.fillStyle=e.footerFontColor,n.font=kn.fontString(r,e._footerFontStyle,e._footerFontFamily),i=0;i<a;++i)n.fillText(o[i],s.x(t.x),t.y+r/2),t.y+=r+e.footerSpacing}},drawBackground:function(t,e,n,r){n.fillStyle=e.backgroundColor,n.strokeStyle=e.borderColor,n.lineWidth=e.borderWidth;var i=e.xAlign,o=e.yAlign,a=t.x,s=t.y,l=r.width,u=r.height,c=e.cornerRadius;n.beginPath(),n.moveTo(a+c,s),"top"===o&&this.drawCaret(t,r),n.lineTo(a+l-c,s),n.quadraticCurveTo(a+l,s,a+l,s+c),"center"===o&&"right"===i&&this.drawCaret(t,r),n.lineTo(a+l,s+u-c),n.quadraticCurveTo(a+l,s+u,a+l-c,s+u),"bottom"===o&&this.drawCaret(t,r),n.lineTo(a+c,s+u),n.quadraticCurveTo(a,s+u,a,s+u-c),"center"===o&&"left"===i&&this.drawCaret(t,r),n.lineTo(a,s+c),n.quadraticCurveTo(a,s,a+c,s),n.closePath(),n.fill(),0<e.borderWidth&&n.stroke()},draw:function(){var t=this._chart.ctx,e=this._view;if(0!==e.opacity){var n={width:e.width,height:e.height},r={x:e.x,y:e.y},i=Math.abs(e.opacity<.001)?0:e.opacity,o=e.title.length||e.beforeBody.length||e.body.length||e.afterBody.length||e.footer.length;this._options.enabled&&o&&(t.save(),t.globalAlpha=i,this.drawBackground(r,e,t,n),r.y+=e.yPadding,kn.rtl.overrideTextDirection(t,e.textDirection),this.drawTitle(r,e,t),this.drawBody(r,e,t),this.drawFooter(r,e,t),kn.rtl.restoreTextDirection(t,e.textDirection),t.restore())}},handleEvent:function(t){var e=this,n=e._options,r=!1;return e._lastActive=e._lastActive||[],"mouseout"===t.type?e._active=[]:(e._active=e._chart.getElementsAtEventForMode(t,n.mode,n),n.reverse&&e._active.reverse()),(
r=!kn.arrayEquals(e._active,e._lastActive))&&(e._lastActive=e._active,(n.enabled||n.custom)&&(e._eventPosition={x:t.x,y:t.y},e.update(!0),e.pivot())),r}}),Yr=qr,Gr=Ur;Gr.positioners=Yr;var Kr=kn.valueOrDefault;vn._set("global",{elements:{},events:["mousemove","mouseout","click","touchstart","touchmove"],hover:{onHover:null,mode:"nearest",intersect:!0,animationDuration:400},onClick:null,maintainAspectRatio:!0,responsive:!0,responsiveAnimationDuration:0});var Xr=function(t,e){return this.construct(t,e),this};kn.extend(Xr.prototype,{construct:function(t,e){var n=this;e=Nt(e);var r=jr.acquireContext(t,e),i=r&&r.canvas,o=i&&i.height,a=i&&i.width;n.id=kn.uid(),n.ctx=r,n.canvas=i,n.config=e,n.width=a,n.height=o,n.aspectRatio=o?a/o:null,n.options=e.options,n._bufferedRender=!1,n._layers=[],(n.chart=n).controller=n,Xr.instances[n.id]=n,Object.defineProperty(n,"data",{get:function(){return n.config.data},set:function(t){n.config.data=t}}),r&&i?(n.initialize(),n.update()):console.error("Failed to create chart: can't acquire context from the given item")},initialize:function(){var t=this;return Wr.notify(t,"beforeInit"),kn.retinaScale(t,t.options.devicePixelRatio),t.bindEvents(),t.options.responsive&&t.resize(!0),t.initToolTip(),Wr.notify(t,"afterInit"),t},clear:function(){return kn.canvas.clear(this),this},stop:function(){return Nn.cancelAnimation(this),this},resize:function(t){var e=this,n=e.options,r=e.canvas,i=n.maintainAspectRatio&&e.aspectRatio||null,o=Math.max(0,Math.floor(kn.getMaximumWidth(r))),a=Math.max(0,Math.floor(i?o/i:kn.getMaximumHeight(r)));if((e.width!==o||e.height!==a)&&(r.width=e.width=o,r.height=e.height=a,r.style.width=o+"px",r.style.height=a+"px",kn.retinaScale(e,n.devicePixelRatio),!t)){var s={width:o,height:a};Wr.notify(e,"resize",[s]),n.onResize&&n.onResize(e,s),e.stop(),e.update({duration:n.responsiveAnimationDuration})}},ensureScalesHaveIDs:function(){var t=this.options,n=t.scales||{},e=t.scale;kn.each(n.xAxes,function(t,e){t.id||(t.id=Ft(n.xAxes,"x-axis-",e))}),kn.each(n.yAxes,function(t,e){t.id||(t.id=Ft(n.yAxes,"y-axis-",e))}),e&&(e.id=e.id||"scale")},buildOrUpdateScales:function(){var a=this,t=a.options,s=a.scales||{},e=[],l=Object.keys(s).reduce(function(t,e){return t[e]=!1,t},{});t.scales&&(e=e.concat((t.scales.xAxes||[]).map(function(t){return{options:t,dtype:"category",dposition:"bottom"}}),(t.scales.yAxes||[]).map(function(t){return{options:t,dtype:"linear",dposition:"left"}}))),t.scale&&e.push({options:t.scale,dtype:"radialLinear",isDefault:!0,dposition:"chartArea"}),kn.each(e,function(t){var e=t.options,n=e.id,r=Kr(e.type,t.dtype);Ht(e.position)!==Ht(t.dposition)&&(e.position=t.dposition),l[n]=!0;var i=null;if(n in s&&s[n].type===r)(i=s[n]).options=e,i.ctx=a.ctx,i.chart=a;else{var o=zr.getScaleConstructor(r);if(!o)return;i=new o({id:n,type:r,options:e,ctx:a.ctx,chart:a}),s[i.id]=i}i.mergeTicksOptions(),t.isDefault&&(a.scale=i)}),kn.each(l,function(t,e){t||delete s[e]}),a.scales=s,zr.addScalesToLayout(this)},buildOrUpdateControllers:function(){var t,e,n=this,r=[],i=n.data.datasets;for(t=0,e=i.length;t<e;t++){var o=i[t],a=n.getDatasetMeta(t),s=o.type||n.config.type;if(a.type&&a.type!==s&&(n.destroyDatasetMeta(t),a=n.getDatasetMeta(t)),a.type=s,a.order=o.order||0,a.index=t,a.controller)a.controller.updateIndex(t),a.controller.linkScales();else{var l=wr[a.type];if(l===undefined)throw new Error('"'+a.type+'" is not a chart type.');a.controller=new l(n,t),r.push(a.controller)}}return r},resetElements:function(){var n=this;kn.each(n.data.datasets,function(t,e){n.getDatasetMeta(e).controller.reset()},n)},reset:function(){this.resetElements(),this.tooltip.initialize()},update:function(t,e){var n,r,i=this;if(t&&"object"==typeof t||(t={duration:t,lazy:e}),Rt(i),Wr._invalidate(i),!1!==Wr.notify(i,"beforeUpdate")){i.tooltip._data=i.data;var o=i.buildOrUpdateControllers();for(n=0,r=i.data.datasets.length;n<r;n++)i.getDatasetMeta(n).controller.buildOrUpdateElements();i.updateLayout(),i.options.animation&&i.options.animation.duration&&kn.each(o,function(t){t.reset()}),i.updateDatasets(),i.tooltip.initialize(),i.lastActive=[],Wr.notify(i,"afterUpdate"),i._layers.sort(jt("z","_idx")),i._bufferedRender?i._bufferedRequest={duration:t.duration,easing:t.easing,lazy:t.lazy}:i.render(t)}},updateLayout:function(){var e=this;!1!==Wr.notify(e,"beforeLayout")&&(kr.update(this,this.width,this.height),e._layers=[],kn.each(e.boxes,function(t){t._configure&&t._configure(),e._layers.push.apply(e._layers,t._layers())},e),e._layers.forEach(function(t,e){t._idx=e}),Wr.notify(e,"afterScaleUpdate"),Wr.notify(e,"afterLayout"))},updateDatasets:function(){var t=this;if(!1!==Wr.notify(t,"beforeDatasetsUpdate")){for(var e=0,n=t.data.datasets.length;e<n;++e)t.updateDataset(e);Wr.notify(t,"afterDatasetsUpdate")}},updateDataset:function(t){var e=this,n=e.getDatasetMeta(t),r={meta:n,index:t};!1!==Wr.notify(e,"beforeDatasetUpdate",[r])&&(n.controller._update(),Wr.notify(e,"afterDatasetUpdate",[r]))},render:function(t,e){var n=this;t&&"object"==typeof t||(t={duration:t,lazy:e});var r=n.options.animation,i=Kr(t.duration,r&&r.duration),o=t.lazy;if(!1!==Wr.notify(n,"beforeRender")){var a=function(t){Wr.notify(n,"afterRender"),kn.callback(r&&r.onComplete,[t],n)};if(r&&i){var s=new Ln({numSteps:i/16.66,easing:t.easing||r.easing,render:function(t,e){var n=kn.easing.effects[e.easing],r=e.currentStep,i=r/e.numSteps;t.draw(n(i),i,r)},onAnimationProgress:r.onProgress,onAnimationComplete:a});Nn.addAnimation(n,s,i,o)}else n.draw(),a(new Ln({numSteps:0,chart:n}));return n}},draw:function(t){var e,n,r=this;if(r.clear(),kn.isNullOrUndef(t)&&(t=1),r.transition(t),!(r.width<=0||r.height<=0)&&!1!==Wr.notify(r,"beforeDraw",[t])){for(n=r._layers,e=0;e<n.length&&n[e].z<=0;++e)n[e].draw(r.chartArea);for(r.drawDatasets(t);e<n.length;++e)n[e].draw(r.chartArea);r._drawTooltip(t),Wr.notify(r,"afterDraw",[t])}},transition:function(t){for(var e=this,n=0,r=(e.data.datasets||[]).length;n<r;++n)e.isDatasetVisible(n)&&e.getDatasetMeta(n).controller.transition(t);e.tooltip.transition(t)},_getSortedDatasetMetas:function(t){var e,n,r=this,i=[];for(e=0,n=(r.data.datasets||[]).length;e<n;++e)t&&!r.isDatasetVisible(e)||i.push(r.getDatasetMeta(e));return i.sort(jt("order","index")),i},_getSortedVisibleDatasetMetas:function(){return this._getSortedDatasetMetas(!0)},drawDatasets:function(t){var e,n,r=this;if(!1!==Wr.notify(r,"beforeDatasetsDraw",[t])){for(n=(e=r._getSortedVisibleDatasetMetas()).length-1;0<=n;--n)r.drawDataset(e[n],t);Wr.notify(r,"afterDatasetsDraw",[t])}},drawDataset:function(t,e){var n=this,r={meta:t,index:t.index,easingValue:e};!1!==Wr.notify(n,"beforeDatasetDraw",[r])&&(t.controller.draw(e),Wr.notify(n,"afterDatasetDraw",[r]))},_drawTooltip:function(t){var e=this,n=e.tooltip,r={tooltip:n,easingValue:t};!1!==Wr.notify(e,"beforeTooltipDraw",[r])&&(n.draw(),Wr.notify(e,"afterTooltipDraw",[r]))},getElementAtEvent:function(t){return Sr.modes.single(this,t)},getElementsAtEvent:function(t){return Sr.modes.label(this,t,{intersect:!0})},getElementsAtXAxis:function(t){return Sr.modes["x-axis"](this,t,{intersect:!0})},getElementsAtEventForMode:function(t,e,n){var r=Sr.modes[e];return"function"==typeof r?r(this,t,n):[]},getDatasetAtEvent:function(t){return Sr.modes.dataset(this,t,{intersect:!0})},getDatasetMeta:function(t){var e=this,n=e.data.datasets[t];n._meta||(n._meta={});var r=n._meta[e.id];return r||(r=n._meta[e.id]={type:null,data:[],dataset:null,controller:null,hidden:null,xAxisID:null,yAxisID:null,order:n.order||0,index:t}),r},getVisibleDatasetCount:function(){for(var t=0,e=0,n=this.data.datasets.length;e<n;++e)this.isDatasetVisible(e)&&t++;return t},isDatasetVisible:function(t){var e=this.getDatasetMeta(t);return"boolean"==typeof e.hidden?!e.hidden:!this.data.datasets[t].hidden},generateLegend:function(){return this.options.legendCallback(this)},destroyDatasetMeta:function(t){var e=this.id,n=this.data.datasets[t],r=n._meta&&n._meta[e];r&&(r.controller.destroy(),delete n._meta[e])},destroy:function(){var t,e,n=this,r=n.canvas;for(n.stop(),t=0,e=n.data.datasets.length;t<e;++t)n.destroyDatasetMeta(t);r&&(n.unbindEvents(),kn.canvas.clear(n),jr.releaseContext(n.ctx),n.canvas=null,n.ctx=null),Wr.notify(n,"destroy"),delete Xr.instances[n.id]},toBase64Image:function(){return this.canvas.toDataURL.apply(this.canvas,arguments)},initToolTip:function(){var t=this;t.tooltip=new Gr({_chart:t,_chartInstance:t,_data:t.data,_options:t.options.tooltips},t)},bindEvents:function(){var e=this,n=e._listeners={},r=function(){e.eventHandler.apply(e,arguments)};kn.each(e.options.events,function(t){jr.addEventListener(e,t,r),n[t]=r}),e.options.responsive&&(r=function(){e.resize()},jr.addEventListener(e,"resize",r),n.resize=r)},unbindEvents:function(){var n=this,t=n._listeners;t&&(delete n._listeners,kn.each(t,function(t,e){jr.removeEventListener(n,e,t)}))},updateHoverStyle:function(t,e,n){var r,i,o,a=n?"set":"remove";for(i=0,o=t.length;i<o;++i)(r=t[i])&&this.getDatasetMeta(r._datasetIndex).controller[a+"HoverStyle"](r);"dataset"===e&&this.getDatasetMeta(t[0]._datasetIndex).controller["_"+a+"DatasetHoverStyle"]()},eventHandler:function(t){var e=this,n=e.tooltip;if(!1!==Wr.notify(e,"beforeEvent",[t])){e._bufferedRender=!0,e._bufferedRequest=null;var r=e.handleEvent(t);n&&(r=n._start?n.handleEvent(t):r|n.handleEvent(t)),Wr.notify(e,"afterEvent",[t]);var i=e._bufferedRequest;return i?e.render(i):r&&!e.animating&&(e.stop(),e.render({duration:e.options.hover.animationDuration,lazy:!0})),e._bufferedRender=!1,e._bufferedRequest=null,e}},handleEvent:function(t){var e=this,n=e.options||{},r=n.hover,i=!1;return e.lastActive=e.lastActive||[],"mouseout"===t.type?e.active=[]:e.active=e.getElementsAtEventForMode(t,r.mode,r),kn.callback(n.onHover||n.hover.onHover,[t["native"],e.active],e),"mouseup"!==t.type&&"click"!==t.type||n.onClick&&n.onClick.call(e,t["native"],e.active),e.lastActive.length&&e.updateHoverStyle(e.lastActive,r.mode,!1),e.active.length&&r.mode&&e.updateHoverStyle(e.active,r.mode,!0),i=!kn.arrayEquals(e.active,e.lastActive),e.lastActive=e.active,i}}),Xr.instances={};var Qr=Xr;(Xr.Controller=Xr).types={},kn.configMerge=Lt,kn.scaleMerge=Pt;var $r=function(){function c(t,e,n){var r;return"string"==typeof t?(r=parseInt(t,10),-1!==t.indexOf("%")&&(r=r/100*e.parentNode[n])):r=t,r}function d(t){return t!==undefined&&null!==t&&"none"!==t}function e(t,e,n){var r=document.defaultView,i=kn._getParentNode(t),o=r.getComputedStyle(t)[e],a=r.getComputedStyle(i)[e],s=d(o),l=d(a),u=Number.POSITIVE_INFINITY;return s||l?Math.min(s?c(o,t,n):u,l?c(a,i,n):u):"none"}kn.where=function(t,e){if(kn.isArray(t)&&Array.prototype.filter)return t.filter(e);var n=[];return kn.each(t,function(t){e(t)&&n.push(t)}),n},kn.findIndex=Array.prototype.findIndex?function(t,e,n){return t.findIndex(e,n)}:function(t,e,n){n=n===undefined?t:n;for(var r=0,i=t.length;r<i;++r)if(e.call(n,t[r],r,t))return r;return-1},kn.findNextWhere=function(t,e,n){kn.isNullOrUndef(n)&&(n=-1);for(var r=n+1;r<t.length;r++){var i=t[r];if(e(i))return i}},kn.findPreviousWhere=function(t,e,n){kn.isNullOrUndef(n)&&(n=t.length);for(var r=n-1;0<=r;r--){var i=t[r];if(e(i))return i}},kn.isNumber=function(t){return!isNaN(parseFloat(t))&&isFinite(t)},kn.almostEquals=function(t,e,n){return Math.abs(t-e)<n},kn.almostWhole=function(t,e){var n=Math.round(t);return n-e<=t&&t<=n+e},kn.max=function(t){return t.reduce(function(t,e){return isNaN(e)?t:Math.max(t,e)},Number.NEGATIVE_INFINITY)},kn.min=function(t){return t.reduce(function(t,e){return isNaN(e)?t:Math.min(t,e)},Number.POSITIVE_INFINITY)},kn.sign=Math.sign?function(t){return Math.sign(t)}:function(t){return 0===(t=+t)||isNaN(t)?t:0<t?1:-1},kn.toRadians=function(t){return t*(Math.PI/180)},kn.toDegrees=function(t){return t*(180/Math.PI)},kn._decimalPlaces=function(t){if(kn.isFinite(t)){for(var e=1,n=0;Math.round(t*e)/e!==t;)e*=10,n++;return n}},kn.getAngleFromPoint=function(t,e){var n=e.x-t.x,r=e.y-t.y,i=Math.sqrt(n*n+r*r),o=Math.atan2(r,n);return o<-.5*Math.PI&&(o+=2*Math.PI),{angle:o,distance:i}},kn.distanceBetweenPoints=function(t,e){return Math.sqrt(Math.pow(e.x-t.x,2)+Math.pow(e.y-t.y,2))},kn.aliasPixel=function(t){return t%2==0?0:.5},kn._alignPixel=function(t,e,n){var r=t.currentDevicePixelRatio,i=n/2;return Math.round((e-i)*r)/r+i},kn.splineCurve=function(t,e,n,r){var i=t.skip?e:t,o=e,a=n.skip?e:n,s=Math.sqrt(Math.pow(o.x-i.x,2)+Math.pow(o.y-i.y,2)),l=Math.sqrt(Math.pow(a.x-o.x,2)+Math.pow(a.y-o.y,2)),u=s/(s+l),c=l/(s+l),d=r*(u=isNaN(u)?0:u),h=r*(c=isNaN(c)?0:c);return{previous:{x:o.x-d*(a.x-i.x),y:o.y-d*(a.y-i.y)},next:{x:o.x+h*(a.x-i.x),y:o.y+h*(a.y-i.y)}}},kn.EPSILON=Number.EPSILON||1e-14,kn.splineCurveMonotone=function(t){var e,n,r,i,o,a,s,l,u,c=(t||[]).map(function(t){return{model:t._model,deltaK:0,mK:0}}),d=c.length;for(e=0;e<d;++e)if(!(r=c[e]).model.skip){if(n=0<e?c[e-1]:null,(i=e<d-1?c[e+1]:null)&&!i.model.skip){var h=i.model.x-r.model.x;r.deltaK=0!==h?(i.model.y-r.model.y)/h:0}!n||n.model.skip?r.mK=r.deltaK:!i||i.model.skip?r.mK=n.deltaK:this.sign(n.deltaK)!==this.sign(r.deltaK)?r.mK=0:r.mK=(n.deltaK+r.deltaK)/2}for(e=0;e<d-1;++e)r=c[e],i=c[e+1],r.model.skip||i.model.skip||(kn.almostEquals(r.deltaK,0,this.EPSILON)?r.mK=i.mK=0:(o=r.mK/r.deltaK,a=i.mK/r.deltaK,(l=Math.pow(o,2)+Math.pow(a,2))<=9||(s=3/Math.sqrt(l),r.mK=o*s*r.deltaK,i.mK=a*s*r.deltaK)));for(e=0;e<d;++e)(r=c[e]).model.skip||(n=0<e?c[e-1]:null,i=e<d-1?c[e+1]:null,n&&!n.model.skip&&(u=(r.model.x-n.model.x)/3,r.model.controlPointPreviousX=r.model.x-u,r.model.controlPointPreviousY=r.model.y-u*r.mK),i&&!i.model.skip&&(u=(i.model.x-r.model.x)/3,r.model.controlPointNextX=r.model.x+u,r.model.controlPointNextY=r.model.y+u*r.mK))},kn.nextItem=function(t,e,n){return n?e>=t.length-1?t[0]:t[e+1]:e>=t.length-1?t[t.length-1]:t[e+1]},kn.previousItem=function(t,e,n){return n?e<=0?t[t.length-1]:t[e-1]:e<=0?t[0]:t[e-1]},kn.niceNum=function(t,e){var n=Math.floor(kn.log10(t)),r=t/Math.pow(10,n);return(e?r<1.5?1:r<3?2:r<7?5:10:r<=1?1:r<=2?2:r<=5?5:10)*Math.pow(10,n)},kn.requestAnimFrame="undefined"==typeof window?function(t){t()}:window.requestAnimationFrame||window.webkitRequestAnimationFrame||window.mozRequestAnimationFrame||window.oRequestAnimationFrame||window.msRequestAnimationFrame||function(t){return window.setTimeout(t,1e3/60)},kn.getRelativePosition=function(t,e){var n,r,i=t.originalEvent||t,o=t.target||t.srcElement,a=o.getBoundingClientRect(),s=i.touches;s&&0<s.length?(n=s[0].clientX,r=s[0].clientY):(n=i.clientX,r=i.clientY);var l=parseFloat(kn.getStyle(o,"padding-left")),u=parseFloat(kn.getStyle(o,"padding-top")),c=parseFloat(kn.getStyle(o,"padding-right")),d=parseFloat(kn.getStyle(o,"padding-bottom")),h=a.right-a.left-l-c,f=a.bottom-a.top-u-d;return{x:n=Math.round((n-a.left-l)/h*o.width/e.currentDevicePixelRatio),y:r=Math.round((r-a.top-u)/f*o.height/e.currentDevicePixelRatio)}},kn.getConstraintWidth=function(t){return e(t,"max-width","clientWidth")},kn.getConstraintHeight=function(t){return e(t,"max-height","clientHeight")},kn._calculatePadding=function(t,e,n){return-1<(e=kn.getStyle(t,e)).indexOf("%")?n*parseInt(e,10)/100:parseInt(e,10)},kn._getParentNode=function(t){var e=t.parentNode;return e&&"[object ShadowRoot]"===e.toString()&&(e=e.host),e},kn.getMaximumWidth=function(t){var e=kn._getParentNode(t);if(!e)return t.clientWidth;var n=e.clientWidth,r=n-kn._calculatePadding(e,"padding-left",n)-kn._calculatePadding(e,"padding-right",n),i=kn.getConstraintWidth(t);return isNaN(i)?r:Math.min(r,i)},kn.getMaximumHeight=function(t){var e=kn._getParentNode(t);if(!e)return t.clientHeight;var n=e.clientHeight,r=n-kn._calculatePadding(e,"padding-top",n)-kn._calculatePadding(e,"padding-bottom",n),i=kn.getConstraintHeight(t);return isNaN(i)?r:Math.min(r,i)},kn.getStyle=function(t,e){return t.currentStyle?t.currentStyle[e]:document.defaultView.getComputedStyle(t,null).getPropertyValue(e)},kn.retinaScale=function(t,e){var n=t.currentDevicePixelRatio=e||"undefined"!=typeof window&&window.devicePixelRatio||1;if(1!==n){var r=t.canvas,i=t.height,o=t.width;r.height=i*n,r.width=o*n,t.ctx.scale(n,n),r.style.height||r.style.width||(r.style.height=i+"px",r.style.width=o+"px")}},kn.fontString=function(t,e,n){return e+" "+t+"px "+n},kn.longestText=function(t,e,n,r){var i=(r=r||{}).data=r.data||{},o=r.garbageCollect=r.garbageCollect||[];r.font!==e&&(i=r.data={},o=r.garbageCollect=[],r.font=e),t.font=e;var a,s,l,u,c,d=0,h=n.length;for(a=0;a<h;a++)if((u=n[a])!==undefined&&null!==u&&!0!==kn.isArray(u))d=kn.measureText(t,i,o,d,u);else if(kn.isArray(u))for(s=0,l=u.length;s<l;s++)(c=u[s])===undefined||null===c||kn.isArray(c)||(d=kn.measureText(t,i,o,d,c));var f=o.length/2;if(f>n.length){for(a=0;a<f;a++)delete i[o[a]];o.splice(0,f)}return d},kn.measureText=function(t,e,n,r,i){var o=e[i];return o||(o=e[i]=t.measureText(i).width,n.push(i)),r<o&&(r=o),r},kn.numberOfLabelLines=function(t){var e=1;return kn.each(t,function(t){kn.isArray(t)&&t.length>e&&(e=t.length)}),e},kn.color=rn?function(t){return t instanceof CanvasGradient&&(t=vn.global.defaultColor),rn(t)}:function(t){return console.error("Color.js not found!"),t},kn.getHoverColor=function(t){return t instanceof CanvasPattern||t instanceof CanvasGradient?t:kn.color(t).saturate(.5).darken(.1).rgbString()}};kn.extend(zt.prototype,{formats:Wt,parse:Wt,format:Wt,add:Wt,diff:Wt,startOf:Wt,endOf:Wt,_create:function(t){return t}}),zt.override=function(t){kn.extend(zt.prototype,t)};var Zr={_date:zt},Jr={formatters:{values:function(t){return kn.isArray(t)?t:""+t},linear:function(t,e,n){var r=3<n.length?n[2]-n[1]:n[1]-n[0];1<Math.abs(r)&&t!==Math.floor(t)&&(r=t-Math.floor(t));var i=kn.log10(Math.abs(r)),o="";if(0!==t)if(Math.max(Math.abs(n[0]),Math.abs(n[n.length-1]))<1e-4){var a=kn.log10(Math.abs(t)),s=Math.floor(a)-Math.floor(i);s=Math.max(Math.min(s,20),0),o=t.toExponential(s)}else{var l=-1*Math.floor(i);l=Math.max(Math.min(l,20),0),o=t.toFixed(l)}else o="0";return o},logarithmic:function(t,e,n){var r=t/Math.pow(10,Math.floor(kn.log10(t)));return 0===t?"0":1===r||2===r||5===r||0===e||e===n.length-1?t.toExponential():""}}},ti=kn.isArray,ei=kn.isNullOrUndef,ni=kn.valueOrDefault,ri=kn.valueAtIndexOrDefault;vn._set("scale",{display:!0,position:"left",offset:!1,gridLines:{display:!0,color:"rgba(0,0,0,0.1)",lineWidth:1,drawBorder:!0,drawOnChartArea:!0,drawTicks:!0,tickMarkLength:10,zeroLineWidth:1,zeroLineColor:"rgba(0,0,0,0.25)",zeroLineBorderDash:[],zeroLineBorderDashOffset:0,offsetGridLines:!1,borderDash:[],borderDashOffset:0},scaleLabel:{display:!1,labelString:"",padding:{top:4,bottom:4}},ticks:{beginAtZero:!1,minRotation:0,maxRotation:50,mirror:!1,padding:0,reverse:!1,display:!0,autoSkip:!0,autoSkipPadding:0,labelOffset:0,callback:Jr.formatters.values,minor:{},major:{}}});var ii=In.extend({zeroLineIndex:0,getPadding:function(){var t=this;return{left:t.paddingLeft||0,top:t.paddingTop||0,right:t.paddingRight||0,bottom:t.paddingBottom||0}},getTicks:function(){return this._ticks},_getLabels:function(){var t=this.chart.data;return this.options.labels||(this.isHorizontal()?t.xLabels:t.yLabels)||t.labels||[]},mergeTicksOptions:function(){},beforeUpdate:function(){kn.callback(this.options.beforeUpdate,[this])},update:function(t,e,n){var r,i,o,a,s,l=this,u=l.options.ticks,c=u.sampleSize;if(l.beforeUpdate(),l.maxWidth=t,l.maxHeight=e,l.margins=kn.extend({left:0,right:0,top:0,bottom:0},n),l._ticks=null,l.ticks=null,l._labelSizes=null,l._maxLabelLines=0,l.longestLabelWidth=0,l.longestTextCache=l.longestTextCache||{},l._gridLineItems=null,l._labelItems=null,l.beforeSetDimensions(),l.setDimensions(),l.afterSetDimensions(),l.beforeDataLimits(),l.determineDataLimits(),l.afterDataLimits(),l.beforeBuildTicks(),a=l.buildTicks()||[],(!(a=l.afterBuildTicks(a)||a)||!a.length)&&l.ticks)for(a=[],r=0,i=l.ticks.length;r<i;++r)a.push({value:l.ticks[r],major:!1});return s=c<(l._ticks=a).length,o=l._convertTicksToLabels(s?Bt(a,c):a),l._configure(),l.beforeCalculateTickRotation(),l.calculateTickRotation(),l.afterCalculateTickRotation(),l.beforeFit(),l.fit(),l.afterFit(),l._ticksToDraw=u.display&&(u.autoSkip||"auto"===u.source)?l._autoSkip(a):a,s&&(o=l._convertTicksToLabels(l._ticksToDraw)),l.ticks=o,l.afterUpdate(),l.minSize},_configure:function(){var t,e,n=this,r=n.options.ticks.reverse;n.isHorizontal()?(t=n.left,e=n.right):(t=n.top,e=n.bottom,r=!r),n._startPixel=t,n._endPixel=e,n._reversePixels=r,n._length=e-t},afterUpdate:function(){kn.callback(this.options.afterUpdate,[this])},beforeSetDimensions:function(){kn.callback(this.options.beforeSetDimensions,[this])},setDimensions:function(){var t=this;t.isHorizontal()?(t.width=t.maxWidth,t.left=0,t.right=t.width):(t.height=t.maxHeight,t.top=0,t.bottom=t.height),t.paddingLeft=0,t.paddingTop=0,t.paddingRight=0,t.paddingBottom=0},afterSetDimensions:function(){kn.callback(this.options.afterSetDimensions,[this])},beforeDataLimits:function(){kn.callback(this.options.beforeDataLimits,[this])},determineDataLimits:kn.noop,afterDataLimits:function(){kn.callback(this.options.afterDataLimits,[this])},beforeBuildTicks:function(){kn.callback(this.options.beforeBuildTicks,[this])},buildTicks:kn.noop,afterBuildTicks:function(t){var e=this;return ti(t)&&t.length?kn.callback(e.options.afterBuildTicks,[e,t]):(e.ticks=kn.callback(e.options.afterBuildTicks,[e,e.ticks])||e.ticks,t)},beforeTickToLabelConversion:function(){kn.callback(this.options.beforeTickToLabelConversion,[this])},convertTicksToLabels:function(){var t=this,e=t.options.ticks;t.ticks=t.ticks.map(e.userCallback||e.callback,this)},afterTickToLabelConversion:function(){kn.callback(this.options.afterTickToLabelConversion,[this])},beforeCalculateTickRotation:function(){kn.callback(this.options.beforeCalculateTickRotation,[this])},calculateTickRotation:function(){var t,e,n,r,i,o,a,s=this,l=s.options,u=l.ticks,c=s.getTicks().length,d=u.minRotation||0,h=u.maxRotation,f=d;!s._isVisible()||!u.display||h<=d||c<=1||!s.isHorizontal()?s.labelRotation=d:(e=(t=s._getLabelSizes()).widest.width,n=t.highest.height-t.highest.offset,r=Math.min(s.maxWidth,s.chart.width-e),(i=l.offset?s.maxWidth/c:r/(c-1))<e+6&&(i=r/(c-(l.offset?.5:1)),o=s.maxHeight-Yt(l.gridLines)-u.padding-Gt(l.scaleLabel),a=Math.sqrt(e*e+n*n),f=kn.toDegrees(Math.min(Math.asin(Math.min((t.highest.height+6)/i,1)),Math.asin(Math.min(o/a,1))-Math.asin(n/a))),f=Math.max(d,Math.min(h,f))),s.labelRotation=f)},afterCalculateTickRotation:function(){kn.callback(this.options.afterCalculateTickRotation,[this])},beforeFit:function(){kn.callback(this.options.beforeFit,[this])},fit:function(){var t=this,e=t.minSize={width:0,height:0},n=t.chart,r=t.options,i=r.ticks,o=r.scaleLabel,a=r.gridLines,s=t._isVisible(),l="bottom"===r.position,u=t.isHorizontal();if(u?e.width=t.maxWidth:s&&(e.width=Yt(a)+Gt(o)),u?s&&(e.height=Yt(a)+Gt(o)):e.height=t.maxHeight,i.display&&s){var c=Xt(i),d=t._getLabelSizes(),h=d.first,f=d.last,p=d.widest,g=d.highest,m=.4*c.minor.lineHeight,y=i.padding;if(u){var v=0!==t.labelRotation,b=kn.toRadians(t.labelRotation),_=Math.cos(b),x=Math.sin(b),w=x*p.width+_*(g.height-(v?g.offset:0))+(v?0:m);e.height=Math.min(t.maxHeight,e.height+w+y);var S,T,k=t.getPixelForTick(0)-t.left,C=t.right-t.getPixelForTick(t.getTicks().length-1);v?(S=l?_*h.width+x*h.offset:x*(h.height-h.offset),T=l?x*(f.height-f.offset):_*f.width+x*f.offset):(S=h.width/2,T=f.width/2),t.paddingLeft=Math.max((S-k)*t.width/(t.width-k),0)+3,t.paddingRight=Math.max((T-C)*t.width/(t.width-C),0)+3}else{var E=i.mirror?0:p.width+y+m;e.width=Math.min(t.maxWidth,e.width+E),t.paddingTop=h.height/2,t.paddingBottom=f.height/2}}t.handleMargins(),u?(t.width=t._length=n.width-t.margins.left-t.margins.right,t.height=e.height):(t.width=e.width,t.height=t._length=n.height-t.margins.top-t.margins.bottom)},handleMargins:function(){var t=this;t.margins&&(t.margins.left=Math.max(t.paddingLeft,t.margins.left),t.margins.top=Math.max(t.paddingTop,t.margins.top),t.margins.right=Math.max(t.paddingRight,t.margins.right),t.margins.bottom=Math.max(t.paddingBottom,t.margins.bottom))},afterFit:function(){kn.callback(this.options.afterFit,[this])},isHorizontal:function(){var t=this.options.position;return"top"===t||"bottom"===t},isFullWidth:function(){return this.options.fullWidth},getRightValue:function(t){if(ei(t))return NaN;if(("number"==typeof t||t instanceof Number)&&!isFinite(t))return NaN;if(t)if(this.isHorizontal()){if(t.x!==undefined)return this.getRightValue(t.x)}else if(t.y!==undefined)return this.getRightValue(t.y);return t},_convertTicksToLabels:function(t){var e,n,r,i=this;for(i.ticks=t.map(function(t){return t.value}),i.beforeTickToLabelConversion(),e=i.convertTicksToLabels(t)||i.ticks,i.afterTickToLabelConversion(),n=0,r=t.length;n<r;++n)t[n].label=e[n];return e},_getLabelSizes:function(){var t=this,e=t._labelSizes;return e||(t._labelSizes=e=Ut(t.ctx,Xt(t.options.ticks),t.getTicks(),t.longestTextCache),t.longestLabelWidth=e.widest.width),e},_parseValue:function(t){var e,n,r,i;return ti(t)?(e=+this.getRightValue(t[0]),n=+this.getRightValue(t[1]),r=Math.min(e,n),i=Math.max(e,n)):(t=+this.getRightValue(t),e=undefined,i=r=n=t),{min:r,max:i,start:e,end:n}},_getScaleLabel:function(t){var e=this._parseValue(t);return e.start!==undefined?"["+e.start+", "+e.end+"]":+this.getRightValue(t)},getLabelForIndex:kn.noop,getPixelForValue:kn.noop,getValueForPixel:kn.noop,getPixelForTick:function(t){var e=this,n=e.options.offset,r=e._ticks.length,i=1/Math.max(r-(n?0:1),1);return t<0||r-1<t?null:e.getPixelForDecimal(t*i+(n?i/2:0))},getPixelForDecimal:function(t){var e=this;return e._reversePixels&&(t=1-t),e._startPixel+t*e._length},getDecimalForPixel:function(t){var e=(t-this._startPixel)/this._length;return this._reversePixels?1-e:e},getBasePixel:function(){return this.getPixelForValue(this.getBaseValue())},getBaseValue:function(){var t=this,e=t.min,n=t.max;return t.beginAtZero?0:e<0&&n<0?n:0<e&&0<n?e:0},_autoSkip:function(t){var e,n,r,i,o=this,a=o.options.ticks,s=o._length,l=a.maxTicksLimit||s/o._tickSize()+1,u=a.major.enabled?Jt(t):[],c=u.length,d=u[0],h=u[c-1];if(l<c)return te(t,u,c/l),Qt(t);if(r=Zt(u,t,s,l),0<c){for(e=0,n=c-1;e<n;e++)ee(t,r,u[e],u[e+1]);return i=1<c?(h-d)/(c-1):null,ee(t,r,kn.isNullOrUndef(i)?0:d-i,d),ee(t,r,h,kn.isNullOrUndef(i)?t.length:h+i),Qt(t)}return ee(t,r),Qt(t)},_tickSize:function(){var t=this,e=t.options.ticks,n=kn.toRadians(t.labelRotation),r=Math.abs(Math.cos(n)),i=Math.abs(Math.sin(n)),o=t._getLabelSizes(),a=e.autoSkipPadding||0,s=o?o.widest.width+a:0,l=o?o.highest.height+a:0;return t.isHorizontal()?s*i<l*r?s/r:l/i:l*i<s*r?l/r:s/i},_isVisible:function(){var t,e,n,r=this,i=r.chart,o=r.options.display;if("auto"!==o)return!!o;for(t=0,e=i.data.datasets.length;t<e;++t)if(i.isDatasetVisible(t)&&((n=i.getDatasetMeta(t)).xAxisID===r.id||n.yAxisID===r.id))return!0;return!1},_computeGridLineItems:function(t){var e,n,r,i,o,a,s,l,u,c,d,h,f,p,g,m,y,v=this,b=v.chart,_=v.options,x=_.gridLines,w=_.position,S=x.offsetGridLines,T=v.isHorizontal(),k=v._ticksToDraw,C=k.length+(S?1:0),E=Yt(x),D=[],A=x.drawBorder?ri(x.lineWidth,0,0):0,M=A/2,O=kn._alignPixel,I=function(t){return O(b,t,A)};for("top"===w?(e=I(v.bottom),s=v.bottom-E,u=e-M,d=I(t.top)+M,f=t.bottom):"bottom"===w?(e=I(v.top),d=t.top,f=I(t.bottom)-M,s=e+M,u=v.top+E):"left"===w?(e=I(v.right),a=v.right-E,l=e-M,c=I(t.left)+M,h=t.right):(e=I(v.left),c=t.left,h=I(t.right)-M,a=e+M,l=v.left+E),n=0;n<C;++n)r=k[n]||{},ei(r.label)&&n<k.length||(n===v.zeroLineIndex&&_.offset===S?(p=x.zeroLineWidth,g=x.zeroLineColor,m=x.zeroLineBorderDash||[],y=x.zeroLineBorderDashOffset||0):(p=ri(x.lineWidth,n,1),g=ri(x.color,n,"rgba(0,0,0,0.1)"),m=x.borderDash||[],y=x.borderDashOffset||0),(i=Vt(v,r._index||n,S))!==undefined&&(o=O(b,i,p),T?a=l=c=h=o:s=u=d=f=o,D.push({tx1:a,ty1:s,tx2:l,ty2:u,x1:c,y1:d,x2:h,y2:f,width:p,color:g,borderDash:m,borderDashOffset:y})));return D.ticksLength=C,D.borderValue=e,D},_computeLabelItems:function(){var t,e,n,r,i,o,a,s,l,u,c,d,h=this,f=h.options,p=f.ticks,g=f.position,m=p.mirror,y=h.isHorizontal(),v=h._ticksToDraw,b=Xt(p),_=p.padding,x=Yt(f.gridLines),w=-kn.toRadians(h.labelRotation),S=[];for("top"===g?(o=h.bottom-x-_,a=w?"left":"center"):"bottom"===g?(o=h.top+x+_,a=w?"right":"center"):"left"===g?(i=h.right-(m?0:x)-_,a=m?"left":"right"):(i=h.left+(m?0:x)+_,a=m?"right":"left"),t=0,e=v.length;t<e;++t)r=(n=v[t]).label,ei(r)||(s=h.getPixelForTick(n._index||t)+p.labelOffset,u=(l=n.major?b.major:b.minor).lineHeight,c=ti(r)?r.length:1,y?(i=s,d="top"===g?((w?1:.5)-c)*u:(w?0:.5)*u):(o=s,d=(1-c)*u/2),S.push({x:i,y:o,rotation:w,label:r,font:l,textOffset:d,textAlign:a}));return S},_drawGrid:function(t){var e=this,n=e.options.gridLines;if(n.display){var r,i,o,a,s,l=e.ctx,u=e.chart,c=kn._alignPixel,d=n.drawBorder?ri(n.lineWidth,0,0):0,h=e._gridLineItems||(e._gridLineItems=e._computeGridLineItems(t));for(o=0,a=h.length;o<a;++o)r=(s=h[o]).width,i=s.color,r&&i&&(l.save(),l.lineWidth=r,l.strokeStyle=i,l.setLineDash&&(l.setLineDash(s.borderDash),l.lineDashOffset=s.borderDashOffset),l.beginPath(),n.drawTicks&&(l.moveTo(s.tx1,s.ty1),l.lineTo(s.tx2,s.ty2)),n.drawOnChartArea&&(l.moveTo(s.x1,s.y1),l.lineTo(s.x2,s.y2)),l.stroke(),l.restore());if(d){var f,p,g,m,y=d,v=ri(n.lineWidth,h.ticksLength-1,1),b=h.borderValue;e.isHorizontal()?(f=c(u,e.left,y)-y/2,p=c(u,e.right,v)+v/2,g=m=b):(g=c(u,e.top,y)-y/2,m=c(u,e.bottom,v)+v/2,f=p=b),l.lineWidth=d,l.strokeStyle=ri(n.color,0),l.beginPath(),l.moveTo(f,g),l.lineTo(p,m),l.stroke()}}},_drawLabels:function(){var t=this;if(t.options.ticks.display){var e,n,r,i,o,a,s,l,u=t.ctx,c=t._labelItems||(t._labelItems=t._computeLabelItems());for(e=0,r=c.length;e<r;++e){if(a=(o=c[e]).font,u.save(),u.translate(o.x,o.y),u.rotate(o.rotation),u.font=a.string,u.fillStyle=a.color,u.textBaseline="middle",u.textAlign=o.textAlign,s=o.label,l=o.textOffset,ti(s))for(n=0,i=s.length;n<i;++n)u.fillText(""+s[n],0,l),l+=a.lineHeight;else u.fillText(s,0,l);u.restore()}}},_drawTitle:function(){var t=this,e=t.ctx,n=t.options,r=n.scaleLabel;if(r.display){var i,o,a=ni(r.fontColor,vn.global.defaultFontColor),s=kn.options._parseFont(r),l=kn.options.toPadding(r.padding),u=s.lineHeight/2,c=n.position,d=0;if(t.isHorizontal())i=t.left+t.width/2,o="bottom"===c?t.bottom-u-l.bottom:t.top+u+l.top;else{var h="left"===c;i=h?t.left+u+l.top:t.right-u-l.top,o=t.top+t.height/2,d=h?-.5*Math.PI:.5*Math.PI}e.save(),e.translate(i,o),e.rotate(d),e.textAlign="center",e.textBaseline="middle",e.fillStyle=a,e.font=s.string,e.fillText(r.labelString,0,0),e.restore()}},draw:function(t){var e=this;e._isVisible()&&(e._drawGrid(t),e._drawTitle(),e._drawLabels())},_layers:function(){var t=this,e=t.options,n=e.ticks&&e.ticks.z||0,r=e.gridLines&&e.gridLines.z||0;return t._isVisible()&&n!==r&&t.draw===t._draw?[{z:r,draw:function(){t._drawGrid.apply(t,arguments),t._drawTitle.apply(t,arguments)}},{z:n,draw:function(){t._drawLabels.apply(t,arguments)}}]:[{z:n,draw:function(){t.draw.apply(t,arguments)}}]},_getMatchingVisibleMetas:function(e){var n=this,r=n.isHorizontal();return n.chart._getSortedVisibleDatasetMetas().filter(function(t){return(!e||t.type===e)&&(r?t.xAxisID===n.id:t.yAxisID===n.id)})}});ii.prototype._draw=ii.prototype.draw;var oi=ii,ai=kn.isNullOrUndef,si={position:"bottom"},li=oi.extend({determineDataLimits:function(){var t,e=this,n=e._getLabels(),r=e.options.ticks,i=r.min,o=r.max,a=0,s=n.length-1;i!==undefined&&0<=(t=n.indexOf(i))&&(a=t),o!==undefined&&0<=(t=n.indexOf(o))&&(s=t),e.minIndex=a,e.maxIndex=s,e.min=n[a],e.max=n[s]},buildTicks:function(){var t=this,e=t._getLabels(),n=t.minIndex,r=t.maxIndex;t.ticks=0===n&&r===e.length-1?e:e.slice(n,r+1)},getLabelForIndex:function(t,e){var n=this,r=n.chart;return r.getDatasetMeta(e).controller._getValueScaleId()===n.id?n.getRightValue(r.data.datasets[e].data[t]):n._getLabels()[t]},_configure:function(){var t=this,e=t.options.offset,n=t.ticks;oi.prototype._configure.call(t),t.isHorizontal()||(t._reversePixels=!t._reversePixels),n&&(t._startValue=t.minIndex-(e?.5:0),t._valueRange=Math.max(n.length-(e?0:1),1))},getPixelForValue:function(t,e,n){var r,i,o,a=this;return ai(e)||ai(n)||(t=a.chart.data.datasets[n].data[e]),ai(t)||(r=a.isHorizontal()?t.x:t.y),(r!==undefined||t!==undefined&&isNaN(e))&&(i=a._getLabels(),t=kn.valueOrDefault(r,t),e=-1!==(o=i.indexOf(t))?o:e,isNaN(e)&&(e=t)),a.getPixelForDecimal((e-a._startValue)/a._valueRange)},getPixelForTick:function(t){var e=this.ticks;return t<0||t>e.length-1?null:this.getPixelForValue(e[t],t+this.minIndex)},getValueForPixel:function(t){var e=this,n=Math.round(e._startValue+e.getDecimalForPixel(t)*e._valueRange);return Math.min(Math.max(n,0),e.ticks.length-1)},getBasePixel:function(){return this.bottom}}),ui=si;li._defaults=ui;var ci=kn.noop,di=kn.isNullOrUndef,hi=oi.extend({getRightValue:function(t){return"string"==typeof t?+t:oi.prototype.getRightValue.call(this,t)},
handleTickRangeOptions:function(){var t=this,e=t.options.ticks;if(e.beginAtZero){var n=kn.sign(t.min),r=kn.sign(t.max);n<0&&r<0?t.max=0:0<n&&0<r&&(t.min=0)}var i=e.min!==undefined||e.suggestedMin!==undefined,o=e.max!==undefined||e.suggestedMax!==undefined;e.min!==undefined?t.min=e.min:e.suggestedMin!==undefined&&(null===t.min?t.min=e.suggestedMin:t.min=Math.min(t.min,e.suggestedMin)),e.max!==undefined?t.max=e.max:e.suggestedMax!==undefined&&(null===t.max?t.max=e.suggestedMax:t.max=Math.max(t.max,e.suggestedMax)),i!==o&&t.min>=t.max&&(i?t.max=t.min+1:t.min=t.max-1),t.min===t.max&&(t.max++,e.beginAtZero||t.min--)},getTickLimit:function(){var t,e=this,n=e.options.ticks,r=n.stepSize,i=n.maxTicksLimit;return r?t=Math.ceil(e.max/r)-Math.floor(e.min/r)+1:(t=e._computeTickLimit(),i=i||11),i&&(t=Math.min(i,t)),t},_computeTickLimit:function(){return Number.POSITIVE_INFINITY},handleDirectionalChanges:ci,buildTicks:function(){var t=this,e=t.options.ticks,n=t.getTickLimit(),r={maxTicks:n=Math.max(2,n),min:e.min,max:e.max,precision:e.precision,stepSize:kn.valueOrDefault(e.fixedStepSize,e.stepSize)},i=t.ticks=ne(r,t);t.handleDirectionalChanges(),t.max=kn.max(i),t.min=kn.min(i),e.reverse?(i.reverse(),t.start=t.max,t.end=t.min):(t.start=t.min,t.end=t.max)},convertTicksToLabels:function(){var t=this;t.ticksAsNumbers=t.ticks.slice(),t.zeroLineIndex=t.ticks.indexOf(0),oi.prototype.convertTicksToLabels.call(t)},_configure:function(){var t,e=this,n=e.getTicks(),r=e.min,i=e.max;oi.prototype._configure.call(e),e.options.offset&&n.length&&(r-=t=(i-r)/Math.max(n.length-1,1)/2,i+=t),e._startValue=r,e._endValue=i,e._valueRange=i-r}}),fi={position:"left",ticks:{callback:Jr.formatters.linear}},pi=0,gi=1,mi=hi.extend({determineDataLimits:function(){var t,e,n,r,i=this,o=i.options,a=i.chart.data.datasets,s=i._getMatchingVisibleMetas(),l=o.stacked,u={},c=s.length;if(i.min=Number.POSITIVE_INFINITY,i.max=Number.NEGATIVE_INFINITY,l===undefined)for(t=0;!l&&t<c;++t)l=(e=s[t]).stack!==undefined;for(t=0;t<c;++t)n=a[(e=s[t]).index].data,l?ie(i,u,e,n):oe(i,e,n);kn.each(u,function(t){r=t.pos.concat(t.neg),i.min=Math.min(i.min,kn.min(r)),i.max=Math.max(i.max,kn.max(r))}),i.min=kn.isFinite(i.min)&&!isNaN(i.min)?i.min:pi,i.max=kn.isFinite(i.max)&&!isNaN(i.max)?i.max:gi,i.handleTickRangeOptions()},_computeTickLimit:function(){var t,e=this;return e.isHorizontal()?Math.ceil(e.width/40):(t=kn.options._parseFont(e.options.ticks),Math.ceil(e.height/t.lineHeight))},handleDirectionalChanges:function(){this.isHorizontal()||this.ticks.reverse()},getLabelForIndex:function(t,e){return this._getScaleLabel(this.chart.data.datasets[e].data[t])},getPixelForValue:function(t){var e=this;return e.getPixelForDecimal((+e.getRightValue(t)-e._startValue)/e._valueRange)},getValueForPixel:function(t){return this._startValue+this.getDecimalForPixel(t)*this._valueRange},getPixelForTick:function(t){var e=this.ticksAsNumbers;return t<0||t>e.length-1?null:this.getPixelForValue(e[t])}}),yi=fi;mi._defaults=yi;var vi=kn.valueOrDefault,bi=kn.math.log10,_i={position:"left",ticks:{callback:Jr.formatters.logarithmic}},xi=oi.extend({determineDataLimits:function(){function t(t){return d?t.xAxisID===s.id:t.yAxisID===s.id}var e,n,r,i,o,a,s=this,l=s.options,u=s.chart,c=u.data.datasets,d=s.isHorizontal();s.min=Number.POSITIVE_INFINITY,s.max=Number.NEGATIVE_INFINITY,s.minNotZero=Number.POSITIVE_INFINITY;var h=l.stacked;if(h===undefined)for(e=0;e<c.length;e++)if(n=u.getDatasetMeta(e),u.isDatasetVisible(e)&&t(n)&&n.stack!==undefined){h=!0;break}if(l.stacked||h){var f={};for(e=0;e<c.length;e++){var p=[(n=u.getDatasetMeta(e)).type,l.stacked===undefined&&n.stack===undefined?e:"",n.stack].join(".");if(u.isDatasetVisible(e)&&t(n))for(f[p]===undefined&&(f[p]=[]),o=0,a=(i=c[e].data).length;o<a;o++){var g=f[p];r=s._parseValue(i[o]),isNaN(r.min)||isNaN(r.max)||n.data[o].hidden||r.min<0||r.max<0||(g[o]=g[o]||0,g[o]+=r.max)}}kn.each(f,function(t){if(0<t.length){var e=kn.min(t),n=kn.max(t);s.min=Math.min(s.min,e),s.max=Math.max(s.max,n)}})}else for(e=0;e<c.length;e++)if(n=u.getDatasetMeta(e),u.isDatasetVisible(e)&&t(n))for(o=0,a=(i=c[e].data).length;o<a;o++)r=s._parseValue(i[o]),isNaN(r.min)||isNaN(r.max)||n.data[o].hidden||r.min<0||r.max<0||(s.min=Math.min(r.min,s.min),s.max=Math.max(r.max,s.max),0!==r.min&&(s.minNotZero=Math.min(r.min,s.minNotZero)));s.min=kn.isFinite(s.min)?s.min:null,s.max=kn.isFinite(s.max)?s.max:null,s.minNotZero=kn.isFinite(s.minNotZero)?s.minNotZero:null,this.handleTickRangeOptions()},handleTickRangeOptions:function(){var t=this,e=t.options.ticks,n=1,r=10;t.min=se(e.min,t.min),t.max=se(e.max,t.max),t.min===t.max&&(0!==t.min&&null!==t.min?(t.min=Math.pow(10,Math.floor(bi(t.min))-1),t.max=Math.pow(10,Math.floor(bi(t.max))+1)):(t.min=n,t.max=r)),null===t.min&&(t.min=Math.pow(10,Math.floor(bi(t.max))-1)),null===t.max&&(t.max=0!==t.min?Math.pow(10,Math.floor(bi(t.min))+1):r),null===t.minNotZero&&(0<t.min?t.minNotZero=t.min:t.max<1?t.minNotZero=Math.pow(10,Math.floor(bi(t.max))):t.minNotZero=n)},buildTicks:function(){var t=this,e=t.options.ticks,n=!t.isHorizontal(),r={min:se(e.min),max:se(e.max)},i=t.ticks=ae(r,t);t.max=kn.max(i),t.min=kn.min(i),e.reverse?(n=!n,t.start=t.max,t.end=t.min):(t.start=t.min,t.end=t.max),n&&i.reverse()},convertTicksToLabels:function(){this.tickValues=this.ticks.slice(),oi.prototype.convertTicksToLabels.call(this)},getLabelForIndex:function(t,e){return this._getScaleLabel(this.chart.data.datasets[e].data[t])},getPixelForTick:function(t){var e=this.tickValues;return t<0||t>e.length-1?null:this.getPixelForValue(e[t])},_getFirstTickValue:function(t){var e=Math.floor(bi(t));return Math.floor(t/Math.pow(10,e))*Math.pow(10,e)},_configure:function(){var t=this,e=t.min,n=0;oi.prototype._configure.call(t),0===e&&(e=t._getFirstTickValue(t.minNotZero),n=vi(t.options.ticks.fontSize,vn.global.defaultFontSize)/t._length),t._startValue=bi(e),t._valueOffset=n,t._valueRange=(bi(t.max)-bi(e))/(1-n)},getPixelForValue:function(t){var e=this,n=0;return(t=+e.getRightValue(t))>e.min&&0<t&&(n=(bi(t)-e._startValue)/e._valueRange+e._valueOffset),e.getPixelForDecimal(n)},getValueForPixel:function(t){var e=this,n=e.getDecimalForPixel(t);return 0===n&&0===e.min?0:Math.pow(10,e._startValue+(n-e._valueOffset)*e._valueRange)}}),wi=_i;xi._defaults=wi;var Si=kn.valueOrDefault,Ti=kn.valueAtIndexOrDefault,ki=kn.options.resolve,Ci={display:!0,animate:!0,position:"chartArea",angleLines:{display:!0,color:"rgba(0,0,0,0.1)",lineWidth:1,borderDash:[],borderDashOffset:0},gridLines:{circular:!1},ticks:{showLabelBackdrop:!0,backdropColor:"rgba(255,255,255,0.75)",backdropPaddingY:2,backdropPaddingX:2,callback:Jr.formatters.linear},pointLabels:{display:!0,fontSize:10,callback:function(t){return t}}},Ei=hi.extend({setDimensions:function(){var t=this;t.width=t.maxWidth,t.height=t.maxHeight,t.paddingTop=le(t.options)/2,t.xCenter=Math.floor(t.width/2),t.yCenter=Math.floor((t.height-t.paddingTop)/2),t.drawingArea=Math.min(t.height-t.paddingTop,t.width)/2},determineDataLimits:function(){var i=this,n=i.chart,o=Number.POSITIVE_INFINITY,a=Number.NEGATIVE_INFINITY;kn.each(n.data.datasets,function(t,e){if(n.isDatasetVisible(e)){var r=n.getDatasetMeta(e);kn.each(t.data,function(t,e){var n=+i.getRightValue(t);isNaN(n)||r.data[e].hidden||(o=Math.min(n,o),a=Math.max(n,a))})}}),i.min=o===Number.POSITIVE_INFINITY?0:o,i.max=a===Number.NEGATIVE_INFINITY?0:a,i.handleTickRangeOptions()},_computeTickLimit:function(){return Math.ceil(this.drawingArea/le(this.options))},convertTicksToLabels:function(){var e=this;hi.prototype.convertTicksToLabels.call(e),e.pointLabels=e.chart.data.labels.map(function(){var t=kn.callback(e.options.pointLabels.callback,arguments,e);return t||0===t?t:""})},getLabelForIndex:function(t,e){return+this.getRightValue(this.chart.data.datasets[e].data[t])},fit:function(){var t=this,e=t.options;e.display&&e.pointLabels.display?de(t):t.setCenterPoint(0,0,0,0)},setReductions:function(t,e,n){var r=this,i=e.l/Math.sin(n.l),o=Math.max(e.r-r.width,0)/Math.sin(n.r),a=-e.t/Math.cos(n.t),s=-Math.max(e.b-(r.height-r.paddingTop),0)/Math.cos(n.b);i=ye(i),o=ye(o),a=ye(a),s=ye(s),r.drawingArea=Math.min(Math.floor(t-(i+o)/2),Math.floor(t-(a+s)/2)),r.setCenterPoint(i,o,a,s)},setCenterPoint:function(t,e,n,r){var i=this,o=i.width-e-i.drawingArea,a=t+i.drawingArea,s=n+i.drawingArea,l=i.height-i.paddingTop-r-i.drawingArea;i.xCenter=Math.floor((a+o)/2+i.left),i.yCenter=Math.floor((s+l)/2+i.top+i.paddingTop)},getIndexAngle:function(t){var e=this.chart,n=(t*(360/e.data.labels.length)+((e.options||{}).startAngle||0))%360;return(n<0?n+360:n)*Math.PI*2/360},getDistanceFromCenterForValue:function(t){var e=this;if(kn.isNullOrUndef(t))return NaN;var n=e.drawingArea/(e.max-e.min);return e.options.ticks.reverse?(e.max-t)*n:(t-e.min)*n},getPointPosition:function(t,e){var n=this,r=n.getIndexAngle(t)-Math.PI/2;return{x:Math.cos(r)*e+n.xCenter,y:Math.sin(r)*e+n.yCenter}},getPointPositionForValue:function(t,e){return this.getPointPosition(t,this.getDistanceFromCenterForValue(e))},getBasePosition:function(t){var e=this,n=e.min,r=e.max;return e.getPointPositionForValue(t||0,e.beginAtZero?0:n<0&&r<0?r:0<n&&0<r?n:0)},_drawGrid:function(){var t,n,e,r=this,i=r.ctx,o=r.options,a=o.gridLines,s=o.angleLines,l=Si(s.lineWidth,a.lineWidth),u=Si(s.color,a.color);if(o.pointLabels.display&&ge(r),a.display&&kn.each(r.ticks,function(t,e){0!==e&&(n=r.getDistanceFromCenterForValue(r.ticksAsNumbers[e]),me(r,a,n,e))}),s.display&&l&&u){for(i.save(),i.lineWidth=l,i.strokeStyle=u,i.setLineDash&&(i.setLineDash(ki([s.borderDash,a.borderDash,[]])),i.lineDashOffset=ki([s.borderDashOffset,a.borderDashOffset,0])),t=r.chart.data.labels.length-1;0<=t;t--)n=r.getDistanceFromCenterForValue(o.ticks.reverse?r.min:r.max),e=r.getPointPosition(t,n),i.beginPath(),i.moveTo(r.xCenter,r.yCenter),i.lineTo(e.x,e.y),i.stroke();i.restore()}},_drawLabels:function(){var n=this,r=n.ctx,i=n.options.ticks;if(i.display){var o,a,t=n.getIndexAngle(0),s=kn.options._parseFont(i),l=Si(i.fontColor,vn.global.defaultFontColor);r.save(),r.font=s.string,r.translate(n.xCenter,n.yCenter),r.rotate(t),r.textAlign="center",r.textBaseline="middle",kn.each(n.ticks,function(t,e){(0!==e||i.reverse)&&(o=n.getDistanceFromCenterForValue(n.ticksAsNumbers[e]),i.showLabelBackdrop&&(a=r.measureText(t).width,r.fillStyle=i.backdropColor,r.fillRect(-a/2-i.backdropPaddingX,-o-s.size/2-i.backdropPaddingY,a+2*i.backdropPaddingX,s.size+2*i.backdropPaddingY)),r.fillStyle=l,r.fillText(t,0,-o))}),r.restore()}},_drawTitle:kn.noop}),Di=Ci;Ei._defaults=Di;var Ai=kn._deprecated,Mi=kn.options.resolve,Oi=kn.valueOrDefault,Ii=Number.MIN_SAFE_INTEGER||-9007199254740991,Pi=Number.MAX_SAFE_INTEGER||9007199254740991,Li={millisecond:{common:!0,size:1,steps:1e3},second:{common:!0,size:1e3,steps:60},minute:{common:!0,size:6e4,steps:60},hour:{common:!0,size:36e5,steps:24},day:{common:!0,size:864e5,steps:30},week:{common:!1,size:6048e5,steps:4},month:{common:!0,size:2628e6,steps:12},quarter:{common:!1,size:7884e6,steps:4},year:{common:!0,size:3154e7}},Ni=Object.keys(Li),Ri={position:"bottom",distribution:"linear",bounds:"data",adapters:{},time:{parser:!1,unit:!1,round:!1,displayFormat:!1,isoWeekday:!1,minUnit:"millisecond",displayFormats:{}},ticks:{autoSkip:!1,source:"auto",major:{enabled:!1}}},Fi=oi.extend({initialize:function(){this.mergeTicksOptions(),oi.prototype.initialize.call(this)},update:function(){var t=this,e=t.options,n=e.time||(e.time={}),r=t._adapter=new Zr._date(e.adapters.date);return Ai("time scale",n.format,"time.format","time.parser"),Ai("time scale",n.min,"time.min","ticks.min"),Ai("time scale",n.max,"time.max","ticks.max"),kn.mergeIf(n.displayFormats,r.formats()),oi.prototype.update.apply(t,arguments)},getRightValue:function(t){return t&&t.t!==undefined&&(t=t.t),oi.prototype.getRightValue.call(this,t)},determineDataLimits:function(){var t,e,n,r,i,o,a,s=this,l=s.chart,u=s._adapter,c=s.options,d=c.time.unit||"day",h=Pi,f=Ii,p=[],g=[],m=[],y=s._getLabels();for(t=0,n=y.length;t<n;++t)m.push(Ce(s,y[t]));for(t=0,n=(l.data.datasets||[]).length;t<n;++t)if(l.isDatasetVisible(t))if(i=l.data.datasets[t].data,kn.isObject(i[0]))for(g[t]=[],e=0,r=i.length;e<r;++e)o=Ce(s,i[e]),p.push(o),g[t][e]=o;else g[t]=m.slice(0),a||(p=p.concat(m),a=!0);else g[t]=[];m.length&&(h=Math.min(h,m[0]),f=Math.max(f,m[m.length-1])),p.length&&(p=1<n?be(p).sort(ve):p.sort(ve),h=Math.min(h,p[0]),f=Math.max(f,p[p.length-1])),h=Ce(s,_e(c))||h,f=Ce(s,xe(c))||f,h=h===Pi?+u.startOf(Date.now(),d):h,f=f===Ii?+u.endOf(Date.now(),d)+1:f,s.min=Math.min(h,f),s.max=Math.max(h+1,f),s._table=[],s._timestamps={data:p,datasets:g,labels:m}},buildTicks:function(){var t,e,n,r=this,i=r.min,o=r.max,a=r.options,s=a.ticks,l=a.time,u=r._timestamps,c=[],d=r.getLabelCapacity(i),h=s.source,f=a.distribution;for(u="data"===h||"auto"===h&&"series"===f?u.data:"labels"===h?u.labels:Me(r,i,o,d),"ticks"===a.bounds&&u.length&&(i=u[0],o=u[u.length-1]),i=Ce(r,_e(a))||i,o=Ce(r,xe(a))||o,t=0,e=u.length;t<e;++t)i<=(n=u[t])&&n<=o&&c.push(n);return r.min=i,r.max=o,r._unit=l.unit||(s.autoSkip?Ee(l.minUnit,r.min,r.max,d):De(r,c.length,l.minUnit,r.min,r.max)),r._majorUnit=s.major.enabled&&"year"!==r._unit?Ae(r._unit):undefined,r._table=we(r._timestamps.data,i,o,f),r._offsets=Oe(r._table,c,i,o,a),s.reverse&&c.reverse(),Pe(r,c,r._majorUnit)},getLabelForIndex:function(t,e){var n=this,r=n._adapter,i=n.chart.data,o=n.options.time,a=i.labels&&t<i.labels.length?i.labels[t]:"",s=i.datasets[e].data[t];return kn.isObject(s)&&(a=n.getRightValue(s)),o.tooltipFormat?r.format(ke(n,a),o.tooltipFormat):"string"==typeof a?a:r.format(ke(n,a),o.displayFormats.datetime)},tickFormatFunction:function(t,e,n,r){var i=this,o=i._adapter,a=i.options,s=a.time.displayFormats,l=s[i._unit],u=i._majorUnit,c=s[u],d=n[e],h=a.ticks,f=u&&c&&d&&d.major,p=o.format(t,r||(f?c:l)),g=f?h.major:h.minor,m=Mi([g.callback,g.userCallback,h.callback,h.userCallback]);return m?m(p,e,n):p},convertTicksToLabels:function(t){var e,n,r=[];for(e=0,n=t.length;e<n;++e)r.push(this.tickFormatFunction(t[e].value,e,t));return r},getPixelForOffset:function(t){var e=this,n=e._offsets,r=Te(e._table,"time",t,"pos");return e.getPixelForDecimal((n.start+r)*n.factor)},getPixelForValue:function(t,e,n){var r=this,i=null;if(e!==undefined&&n!==undefined&&(i=r._timestamps.datasets[n][e]),null===i&&(i=Ce(r,t)),null!==i)return r.getPixelForOffset(i)},getPixelForTick:function(t){var e=this.getTicks();return 0<=t&&t<e.length?this.getPixelForOffset(e[t].value):null},getValueForPixel:function(t){var e=this,n=e._offsets,r=e.getDecimalForPixel(t)/n.factor-n.end,i=Te(e._table,"pos",r,"time");return e._adapter._create(i)},_getLabelSize:function(t){var e=this,n=e.options.ticks,r=e.ctx.measureText(t).width,i=kn.toRadians(e.isHorizontal()?n.maxRotation:n.minRotation),o=Math.cos(i),a=Math.sin(i),s=Oi(n.fontSize,vn.global.defaultFontSize);return{w:r*o+s*a,h:r*a+s*o}},getLabelWidth:function(t){return this._getLabelSize(t).w},getLabelCapacity:function(t){var e=this,n=e.options.time,r=n.displayFormats,i=r[n.unit]||r.millisecond,o=e.tickFormatFunction(t,0,Pe(e,[t],e._majorUnit),i),a=e._getLabelSize(o),s=Math.floor(e.isHorizontal()?e.width/a.w:e.height/a.h);return e.options.offset&&s--,0<s?s:1}}),Hi=Ri;Fi._defaults=Hi;var ji={category:li,linear:mi,logarithmic:xi,radialLinear:Ei,time:Fi},Wi=t(function(Wo){var t;t=function(){function u(){return Or.apply(null,arguments)}function t(t){Or=t}function a(t){return t instanceof Array||"[object Array]"===Object.prototype.toString.call(t)}function s(t){return null!=t&&"[object Object]"===Object.prototype.toString.call(t)}function l(t){if(Object.getOwnPropertyNames)return 0===Object.getOwnPropertyNames(t).length;var e;for(e in t)if(t.hasOwnProperty(e))return!1;return!0}function o(t){return void 0===t}function c(t){return"number"==typeof t||"[object Number]"===Object.prototype.toString.call(t)}function i(t){return t instanceof Date||"[object Date]"===Object.prototype.toString.call(t)}function n(t,e){var n,r=[];for(n=0;n<t.length;++n)r.push(e(t[n],n));return r}function d(t,e){return Object.prototype.hasOwnProperty.call(t,e)}function h(t,e){for(var n in e)d(e,n)&&(t[n]=e[n]);return d(e,"toString")&&(t.toString=e.toString),d(e,"valueOf")&&(t.valueOf=e.valueOf),t}function f(t,e,n,r){return ke(t,e,n,r,!0).utc()}function e(){return{empty:!1,unusedTokens:[],unusedInput:[],overflow:-2,charsLeftOver:0,nullInput:!1,invalidMonth:null,invalidFormat:!1,userInvalidated:!1,iso:!1,parsedDateParts:[],meridiem:null,rfc2822:!1,weekdayMismatch:!1}}function p(t){return null==t._pf&&(t._pf=e()),t._pf}function g(t){if(null==t._isValid){var e=p(t),n=Ir.call(e.parsedDateParts,function(t){return null!=t}),r=!isNaN(t._d.getTime())&&e.overflow<0&&!e.empty&&!e.invalidMonth&&!e.invalidWeekday&&!e.weekdayMismatch&&!e.nullInput&&!e.invalidFormat&&!e.userInvalidated&&(!e.meridiem||e.meridiem&&n);if(t._strict&&(r=r&&0===e.charsLeftOver&&0===e.unusedTokens.length&&e.bigHour===undefined),null!=Object.isFrozen&&Object.isFrozen(t))return r;t._isValid=r}return t._isValid}function r(t){var e=f(NaN);return null!=t?h(p(e),t):p(e).userInvalidated=!0,e}function m(t,e){var n,r,i;if(o(e._isAMomentObject)||(t._isAMomentObject=e._isAMomentObject),o(e._i)||(t._i=e._i),o(e._f)||(t._f=e._f),o(e._l)||(t._l=e._l),o(e._strict)||(t._strict=e._strict),o(e._tzm)||(t._tzm=e._tzm),o(e._isUTC)||(t._isUTC=e._isUTC),o(e._offset)||(t._offset=e._offset),o(e._pf)||(t._pf=p(e)),o(e._locale)||(t._locale=e._locale),0<Lr.length)for(n=0;n<Lr.length;n++)o(i=e[r=Lr[n]])||(t[r]=i);return t}function y(t){m(this,t),this._d=new Date(null!=t._d?t._d.getTime():NaN),this.isValid()||(this._d=new Date(NaN)),!1===Nr&&(Nr=!0,u.updateOffset(this),Nr=!1)}function v(t){return t instanceof y||null!=t&&null!=t._isAMomentObject}function b(t){return t<0?Math.ceil(t)||0:Math.floor(t)}function _(t){var e=+t,n=0;return 0!==e&&isFinite(e)&&(n=b(e)),n}function x(t,e,n){var r,i=Math.min(t.length,e.length),o=Math.abs(t.length-e.length),a=0;for(r=0;r<i;r++)(n&&t[r]!==e[r]||!n&&_(t[r])!==_(e[r]))&&a++;return a+o}function w(t){!1===u.suppressDeprecationWarnings&&"undefined"!=typeof console&&console.warn&&console.warn("Deprecation warning: "+t)}function S(o,a){var s=!0;return h(function(t){if(null!=u.deprecationHandler&&u.deprecationHandler(null,o),s){for(var e,n=[],r=0;r<arguments.length;r++){if(e="","object"==typeof arguments[r]){for(var i in e+="\n["+r+"] ",t)e+=i+": "+arguments[0][i]+", ";e=e.slice(0,-2)}else e=arguments[r];n.push(e)}w(o+"\nArguments: "+Array.prototype.slice.call(n).join("")+"\n"+(new Error).stack),s=!1}return a.apply(this,arguments)},a)}function T(t,e){null!=u.deprecationHandler&&u.deprecationHandler(t,e),Rr[t]||(w(e),Rr[t]=!0)}function k(t){return t instanceof Function||"[object Function]"===Object.prototype.toString.call(t)}function C(t){var e,n;for(n in t)k(e=t[n])?this[n]=e:this["_"+n]=e;this._config=t,this._dayOfMonthOrdinalParseLenient=new RegExp((this._dayOfMonthOrdinalParse.source||this._ordinalParse.source)+"|"+/\d{1,2}/.source)}function E(t,e){var n,r=h({},t);for(n in e)d(e,n)&&(s(t[n])&&s(e[n])?(r[n]={},h(r[n],t[n]),h(r[n],e[n])):null!=e[n]?r[n]=e[n]:delete r[n]);for(n in t)d(t,n)&&!d(e,n)&&s(t[n])&&(r[n]=h({},r[n]));return r}function D(t){null!=t&&this.set(t)}function A(t,e,n){var r=this._calendar[t]||this._calendar.sameElse;return k(r)?r.call(e,n):r}function M(t){var e=this._longDateFormat[t],n=this._longDateFormat[t.toUpperCase()];return e||!n?e:(this._longDateFormat[t]=n.replace(/MMMM|MM|DD|dddd/g,function(t){return t.slice(1)}),this._longDateFormat[t])}function O(){return this._invalidDate}function I(t){return this._ordinal.replace("%d",t)}function P(t,e,n,r){var i=this._relativeTime[n];return k(i)?i(t,e,n,r):i.replace(/%d/i,t)}function L(t,e){var n=this._relativeTime[0<t?"future":"past"];return k(n)?n(e):n.replace(/%s/i,e)}function N(t,e){var n=t.toLowerCase();Vr[n]=Vr[n+"s"]=Vr[e]=t}function R(t){return"string"==typeof t?Vr[t]||Vr[t.toLowerCase()]:undefined}function F(t){var e,n,r={};for(n in t)d(t,n)&&(e=R(n))&&(r[e]=t[n]);return r}function H(t,e){qr[t]=e}function j(t){var e=[];for(var n in t)e.push({unit:n,priority:qr[n]});return e.sort(function(t,e){return t.priority-e.priority}),e}function W(t,e,n){var r=""+Math.abs(t),i=e-r.length;return(0<=t?n?"+":"":"-")+Math.pow(10,Math.max(0,i)).toString().substr(1)+r}function z(t,e,n,r){var i=r;"string"==typeof r&&(i=function(){return this[r]()}),t&&(Kr[t]=i),e&&(Kr[e[0]]=function(){return W(i.apply(this,arguments),e[1],e[2])}),n&&(Kr[n]=function(){return this.localeData().ordinal(i.apply(this,arguments),t)})}function B(t){return t.match(/\[[\s\S]/)?t.replace(/^\[|\]$/g,""):t.replace(/\\/g,"")}function V(r){var t,i,o=r.match(Ur);for(t=0,i=o.length;t<i;t++)Kr[o[t]]?o[t]=Kr[o[t]]:o[t]=B(o[t]);return function(t){var e,n="";for(e=0;e<i;e++)n+=k(o[e])?o[e].call(t,r):o[e];return n}}function q(t,e){return t.isValid()?(e=U(e,t.localeData()),Gr[e]=Gr[e]||V(e),Gr[e](t)):t.localeData().invalidDate()}function U(t,e){function n(t){return e.longDateFormat(t)||t}var r=5;for(Yr.lastIndex=0;0<=r&&Yr.test(t);)t=t.replace(Yr,n),Yr.lastIndex=0,r-=1;return t}function Y(t,e,n){hi[t]=k(e)?e:function(t){return t&&n?n:e}}function G(t,e){return d(hi,t)?hi[t](e._strict,e._locale):new RegExp(K(t))}function K(t){return X(t.replace("\\","").replace(/\\(\[)|\\(\])|\[([^\]\[]*)\]|\\(.)/g,function(t,e,n,r,i){return e||n||r||i}))}function X(t){return t.replace(/[-\/\\^$*+?.()|[\]{}]/g,"\\$&")}function Q(t,n){var e,r=n;for("string"==typeof t&&(t=[t]),c(n)&&(r=function(t,e){e[n]=_(t)}),e=0;e<t.length;e++)fi[t[e]]=r}function $(t,i){Q(t,function(t,e,n,r){n._w=n._w||{},i(t,n._w,n,r)})}function Z(t,e,n){null!=e&&d(fi,t)&&fi[t](e,n._a,n,t)}function J(t){return tt(t)?366:365}function tt(t){return t%4==0&&t%100!=0||t%400==0}function et(){return tt(this.year())}function nt(e,n){return function(t){return null!=t?(it(this,e,t),u.updateOffset(this,n),this):rt(this,e)}}function rt(t,e){return t.isValid()?t._d["get"+(t._isUTC?"UTC":"")+e]():NaN}function it(t,e,n){t.isValid()&&!isNaN(n)&&("FullYear"===e&&tt(t.year())&&1===t.month()&&29===t.date()?t._d["set"+(t._isUTC?"UTC":"")+e](n,t.month(),lt(n,t.month())):t._d["set"+(t._isUTC?"UTC":"")+e](n))}function ot(t){return k(this[t=R(t)])?this[t]():this}function at(t,e){if("object"==typeof t)for(var n=j(t=F(t)),r=0;r<n.length;r++)this[n[r].unit](t[n[r].unit]);else if(k(this[t=R(t)]))return this[t](e);return this}function st(t,e){return(t%e+e)%e}function lt(t,e){if(isNaN(t)||isNaN(e))return NaN;var n=st(e,12);return t+=(e-n)/12,1===n?tt(t)?29:28:31-n%7%2}function ut(t,e){return t?a(this._months)?this._months[t.month()]:this._months[(this._months.isFormat||ki).test(e)?"format":"standalone"][t.month()]:a(this._months)?this._months:this._months.standalone}function ct(t,e){return t?a(this._monthsShort)?this._monthsShort[t.month()]:this._monthsShort[ki.test(e)?"format":"standalone"][t.month()]:a(this._monthsShort)?this._monthsShort:this._monthsShort.standalone}function dt(t,e,n){var r,i,o,a=t.toLocaleLowerCase();if(!this._monthsParse)for(this._monthsParse=[],this._longMonthsParse=[],this._shortMonthsParse=[],r=0;r<12;++r)o=f([2e3,r]),this._shortMonthsParse[r]=this.monthsShort(o,"").toLocaleLowerCase(),this._longMonthsParse[r]=this.months(o,"").toLocaleLowerCase();return n?"MMM"===e?-1!==(i=Si.call(this._shortMonthsParse,a))?i:null:-1!==(i=Si.call(this._longMonthsParse,a))?i:null:"MMM"===e?-1!==(i=Si.call(this._shortMonthsParse,a))?i:-1!==(i=Si.call(this._longMonthsParse,a))?i:null:-1!==(i=Si.call(this._longMonthsParse,a))?i:-1!==(i=Si.call(this._shortMonthsParse,a))?i:null}function ht(t,e,n){var r,i,o;if(this._monthsParseExact)return dt.call(this,t,e,n);for(this._monthsParse||(this._monthsParse=[],this._longMonthsParse=[],this._shortMonthsParse=[]),r=0;r<12;r++){if(i=f([2e3,r]),n&&!this._longMonthsParse[r]&&(this._longMonthsParse[r]=new RegExp("^"+this.months(i,"").replace(".","")+"$","i"),this._shortMonthsParse[r]=new RegExp("^"+this.monthsShort(i,"").replace(".","")+"$","i")),n||this._monthsParse[r]||(o="^"+this.months(i,"")+"|^"+this.monthsShort(i,""),this._monthsParse[r]=new RegExp(o.replace(".",""),"i")),n&&"MMMM"===e&&this._longMonthsParse[r].test(t))return r;if(n&&"MMM"===e&&this._shortMonthsParse[r].test(t))return r;if(!n&&this._monthsParse[r].test(t))return r}}function ft(t,e){var n;if(!t.isValid())return t;if("string"==typeof e)if(/^\d+$/.test(e))e=_(e);else if(!c(e=t.localeData().monthsParse(e)))return t;return n=Math.min(t.date(),lt(t.year(),e)),t._d["set"+(t._isUTC?"UTC":"")+"Month"](e,n),t}function pt(t){return null!=t?(ft(this,t),u.updateOffset(this,!0),this):rt(this,"Month")}function gt(){return lt(this.year(),this.month())}function mt(t){return this._monthsParseExact?(d(this,"_monthsRegex")||vt.call(this),t?this._monthsShortStrictRegex:this._monthsShortRegex):(d(this,"_monthsShortRegex")||(this._monthsShortRegex=Di),this._monthsShortStrictRegex&&t?this._monthsShortStrictRegex:this._monthsShortRegex)}function yt(t){return this._monthsParseExact?(d(this,"_monthsRegex")||vt.call(this),t?this._monthsStrictRegex:this._monthsRegex):(d(this,"_monthsRegex")||(this._monthsRegex=Ai),this._monthsStrictRegex&&t?this._monthsStrictRegex:this._monthsRegex)}function vt(){function t(t,e){return e.length-t.length}var e,n,r=[],i=[],o=[];for(e=0;e<12;e++)n=f([2e3,e]),r.push(this.monthsShort(n,"")),i.push(this.months(n,"")),o.push(this.months(n,"")),o.push(this.monthsShort(n,""));for(r.sort(t),i.sort(t),o.sort(t),e=0;e<12;e++)r[e]=X(r[e]),i[e]=X(i[e]);for(e=0;e<24;e++)o[e]=X(o[e]);this._monthsRegex=new RegExp("^("+o.join("|")+")","i"),this._monthsShortRegex=this._monthsRegex,this._monthsStrictRegex=new RegExp("^("+i.join("|")+")","i"),this._monthsShortStrictRegex=new RegExp("^("+r.join("|")+")","i")}function bt(t,e,n,r,i,o,a){var s;return t<100&&0<=t?(s=new Date(t+400,e,n,r,i,o,a),isFinite(s.getFullYear())&&s.setFullYear(t)):s=new Date(t,e,n,r,i,o,a),s}function _t(t){var e;if(t<100&&0<=t){var n=Array.prototype.slice.call(arguments);n[0]=t+400,e=new Date(Date.UTC.apply(null,n)),isFinite(e.getUTCFullYear())&&e.setUTCFullYear(t)}else e=new Date(Date.UTC.apply(null,arguments));return e}function xt(t,e,n){var r=7+e-n;return-((7+_t(t,0,r).getUTCDay()-e)%7)+r-1}function wt(t,e,n,r,i){var o,a,s=1+7*(e-1)+(7+n-r)%7+xt(t,r,i);return s<=0?a=J(o=t-1)+s:s>J(t)?(o=t+1,a=s-J(t)):(o=t,a=s),{year:o,dayOfYear:a}}function St(t,e,n){var r,i,o=xt(t.year(),e,n),a=Math.floor((t.dayOfYear()-o-1)/7)+1;return a<1?r=a+Tt(i=t.year()-1,e,n):a>Tt(t.year(),e,n)?(r=a-Tt(t.year(),e,n),i=t.year()+1):(i=t.year(),r=a),{week:r,year:i}}function Tt(t,e,n){var r=xt(t,e,n),i=xt(t+1,e,n);return(J(t)-r+i)/7}function kt(t){return St(t,this._week.dow,this._week.doy).week}function Ct(){return this._week.dow}function Et(){return this._week.doy}function Dt(t){var e=this.localeData().week(this);return null==t?e:this.add(7*(t-e),"d")}function At(t){var e=St(this,1,4).week;return null==t?e:this.add(7*(t-e),"d")}function Mt(t,e){return"string"!=typeof t?t:isNaN(t)?"number"==typeof(t=e.weekdaysParse(t))?t:null:parseInt(t,10)}function Ot(t,e){return"string"==typeof t?e.weekdaysParse(t)%7||7:isNaN(t)?null:t}function It(t,e){return t.slice(e,7).concat(t.slice(0,e))}function Pt(t,e){var n=a(this._weekdays)?this._weekdays:this._weekdays[t&&!0!==t&&this._weekdays.isFormat.test(e)?"format":"standalone"];return!0===t?It(n,this._week.dow):t?n[t.day()]:n}function Lt(t){return!0===t?It(this._weekdaysShort,this._week.dow):t?this._weekdaysShort[t.day()]:this._weekdaysShort}function Nt(t){return!0===t?It(this._weekdaysMin,this._week.dow):t?this._weekdaysMin[t.day()]:this._weekdaysMin}function Rt(t,e,n){var r,i,o,a=t.toLocaleLowerCase();if(!this._weekdaysParse)for(this._weekdaysParse=[],this._shortWeekdaysParse=[],this._minWeekdaysParse=[],r=0;r<7;++r)o=f([2e3,1]).day(r),this._minWeekdaysParse[r]=this.weekdaysMin(o,"").toLocaleLowerCase(),this._shortWeekdaysParse[r]=this.weekdaysShort(o,"").toLocaleLowerCase(),this._weekdaysParse[r]=this.weekdays(o,"").toLocaleLowerCase();return n?"dddd"===e?-1!==(i=Si.call(this._weekdaysParse,a))?i:null:"ddd"===e?-1!==(i=Si.call(this._shortWeekdaysParse,a))?i:null:-1!==(i=Si.call(this._minWeekdaysParse,a))?i:null:"dddd"===e?-1!==(i=Si.call(this._weekdaysParse,a))?i:-1!==(i=Si.call(this._shortWeekdaysParse,a))?i:-1!==(i=Si.call(this._minWeekdaysParse,a))?i:null:"ddd"===e?-1!==(i=Si.call(this._shortWeekdaysParse,a))?i:-1!==(i=Si.call(this._weekdaysParse,a))?i:-1!==(i=Si.call(this._minWeekdaysParse,a))?i:null:-1!==(i=Si.call(this._minWeekdaysParse,a))?i:-1!==(i=Si.call(this._weekdaysParse,a))?i:-1!==(i=Si.call(this._shortWeekdaysParse,a))?i:null}function Ft(t,e,n){var r,i,o;if(this._weekdaysParseExact)return Rt.call(this,t,e,n);for(this._weekdaysParse||(this._weekdaysParse=[],this._minWeekdaysParse=[],this._shortWeekdaysParse=[],this._fullWeekdaysParse=[]),r=0;r<7;r++){if(i=f([2e3,1]).day(r),n&&!this._fullWeekdaysParse[r]&&(this._fullWeekdaysParse[r]=new RegExp("^"+this.weekdays(i,"").replace(".","\\.?")+"$","i"),this._shortWeekdaysParse[r]=new RegExp("^"+this.weekdaysShort(i,"").replace(".","\\.?")+"$","i"),this._minWeekdaysParse[r]=new RegExp("^"+this.weekdaysMin(i,"").replace(".","\\.?")+"$","i")),this._weekdaysParse[r]||(o="^"+this.weekdays(i,"")+"|^"+this.weekdaysShort(i,"")+"|^"+this.weekdaysMin(i,""),this._weekdaysParse[r]=new RegExp(o.replace(".",""),"i")),n&&"dddd"===e&&this._fullWeekdaysParse[r].test(t))return r;if(n&&"ddd"===e&&this._shortWeekdaysParse[r].test(t))return r;if(n&&"dd"===e&&this._minWeekdaysParse[r].test(t))return r;if(!n&&this._weekdaysParse[r].test(t))return r}}function Ht(t){if(!this.isValid())return null!=t?this:NaN;var e=this._isUTC?this._d.getUTCDay():this._d.getDay();return null!=t?(t=Mt(t,this.localeData()),this.add(t-e,"d")):e}function jt(t){if(!this.isValid())return null!=t?this:NaN;var e=(this.day()+7-this.localeData()._week.dow)%7;return null==t?e:this.add(t-e,"d")}function Wt(t){if(!this.isValid())return null!=t?this:NaN;if(null==t)return this.day()||7;var e=Ot(t,this.localeData());return this.day(this.day()%7?e:e-7)}function zt(t){return this._weekdaysParseExact?(d(this,"_weekdaysRegex")||qt.call(this),t?this._weekdaysStrictRegex:this._weekdaysRegex):(d(this,"_weekdaysRegex")||(this._weekdaysRegex=Li),this._weekdaysStrictRegex&&t?this._weekdaysStrictRegex:this._weekdaysRegex)}function Bt(t){return this._weekdaysParseExact?(d(this,"_weekdaysRegex")||qt.call(this),t?this._weekdaysShortStrictRegex:this._weekdaysShortRegex):(d(this,"_weekdaysShortRegex")||(this._weekdaysShortRegex=Ni),this._weekdaysShortStrictRegex&&t?this._weekdaysShortStrictRegex:this._weekdaysShortRegex)}function Vt(t){return this._weekdaysParseExact?(d(this,"_weekdaysRegex")||qt.call(this),t?this._weekdaysMinStrictRegex:this._weekdaysMinRegex):(d(this,"_weekdaysMinRegex")||(this._weekdaysMinRegex=Ri),this._weekdaysMinStrictRegex&&t?this._weekdaysMinStrictRegex:this._weekdaysMinRegex)}function qt(){function t(t,e){return e.length-t.length}var e,n,r,i,o,a=[],s=[],l=[],u=[];for(e=0;e<7;e++)n=f([2e3,1]).day(e),r=this.weekdaysMin(n,""),i=this.weekdaysShort(n,""),o=this.weekdays(n,""),a.push(r),s.push(i),l.push(o),u.push(r),u.push(i),u.push(o);for(a.sort(t),s.sort(t),l.sort(t),u.sort(t),e=0;e<7;e++)s[e]=X(s[e]),l[e]=X(l[e]),u[e]=X(u[e]);this._weekdaysRegex=new RegExp("^("+u.join("|")+")","i"),this._weekdaysShortRegex=this._weekdaysRegex,this._weekdaysMinRegex=this._weekdaysRegex,this._weekdaysStrictRegex=new RegExp("^("+l.join("|")+")","i"),this._weekdaysShortStrictRegex=new RegExp("^("+s.join("|")+")","i"),this._weekdaysMinStrictRegex=new RegExp("^("+a.join("|")+")","i")}function Ut(){return this.hours()%12||12}function Yt(){return this.hours()||24}function Gt(t,e){z(t,0,0,function(){return this.localeData().meridiem(this.hours(),this.minutes(),e)})}function Kt(t,e){return e._meridiemParse}function Xt(t){return"p"===(t+"").toLowerCase().charAt(0)}function Qt(t,e,n){return 11<t?n?"pm":"PM":n?"am":"AM"}function $t(t){return t?t.toLowerCase().replace("_","-"):t}function Zt(t){for(var e,n,r,i,o=0;o<t.length;){for(e=(i=$t(t[o]).split("-")).length,n=(n=$t(t[o+1]))?n.split("-"):null;0<e;){if(r=Jt(i.slice(0,e).join("-")))return r;if(n&&n.length>=e&&x(i,n,!0)>=e-1)break;e--}o++}return Fi}function Jt(t){var e=null;if(!zi[t]&&Wo&&Wo.exports)try{e=Fi._abbr,zo("./locale/"+t),te(e)}catch(n){}return zi[t]}function te(t,e){var n;return t&&((n=o(e)?re(t):ee(t,e))?Fi=n:"undefined"!=typeof console&&console.warn&&console.warn("Locale "+t+" not found. Did you forget to load it?")),Fi._abbr}function ee(t,e){if(null===e)return delete zi[t],null;var n,r=Wi;if(e.abbr=t,null!=zi[t])T("defineLocaleOverride",
"use moment.updateLocale(localeName, config) to change an existing locale. moment.defineLocale(localeName, config) should only be used for creating a new locale See http://momentjs.com/guides/#/warnings/define-locale/ for more info."),r=zi[t]._config;else if(null!=e.parentLocale)if(null!=zi[e.parentLocale])r=zi[e.parentLocale]._config;else{if(null==(n=Jt(e.parentLocale)))return Bi[e.parentLocale]||(Bi[e.parentLocale]=[]),Bi[e.parentLocale].push({name:t,config:e}),null;r=n._config}return zi[t]=new D(E(r,e)),Bi[t]&&Bi[t].forEach(function(t){ee(t.name,t.config)}),te(t),zi[t]}function ne(t,e){if(null!=e){var n,r,i=Wi;null!=(r=Jt(t))&&(i=r._config),(n=new D(e=E(i,e))).parentLocale=zi[t],zi[t]=n,te(t)}else null!=zi[t]&&(null!=zi[t].parentLocale?zi[t]=zi[t].parentLocale:null!=zi[t]&&delete zi[t]);return zi[t]}function re(t){var e;if(t&&t._locale&&t._locale._abbr&&(t=t._locale._abbr),!t)return Fi;if(!a(t)){if(e=Jt(t))return e;t=[t]}return Zt(t)}function ie(){return Pr(zi)}function oe(t){var e,n=t._a;return n&&-2===p(t).overflow&&(e=n[gi]<0||11<n[gi]?gi:n[mi]<1||n[mi]>lt(n[pi],n[gi])?mi:n[yi]<0||24<n[yi]||24===n[yi]&&(0!==n[vi]||0!==n[bi]||0!==n[_i])?yi:n[vi]<0||59<n[vi]?vi:n[bi]<0||59<n[bi]?bi:n[_i]<0||999<n[_i]?_i:-1,p(t)._overflowDayOfYear&&(e<pi||mi<e)&&(e=mi),p(t)._overflowWeeks&&-1===e&&(e=xi),p(t)._overflowWeekday&&-1===e&&(e=wi),p(t).overflow=e),t}function ae(t,e,n){return null!=t?t:null!=e?e:n}function se(t){var e=new Date(u.now());return t._useUTC?[e.getUTCFullYear(),e.getUTCMonth(),e.getUTCDate()]:[e.getFullYear(),e.getMonth(),e.getDate()]}function le(t){var e,n,r,i,o,a=[];if(!t._d){for(r=se(t),t._w&&null==t._a[mi]&&null==t._a[gi]&&ue(t),null!=t._dayOfYear&&(o=ae(t._a[pi],r[pi]),(t._dayOfYear>J(o)||0===t._dayOfYear)&&(p(t)._overflowDayOfYear=!0),n=_t(o,0,t._dayOfYear),t._a[gi]=n.getUTCMonth(),t._a[mi]=n.getUTCDate()),e=0;e<3&&null==t._a[e];++e)t._a[e]=a[e]=r[e];for(;e<7;e++)t._a[e]=a[e]=null==t._a[e]?2===e?1:0:t._a[e];24===t._a[yi]&&0===t._a[vi]&&0===t._a[bi]&&0===t._a[_i]&&(t._nextDay=!0,t._a[yi]=0),t._d=(t._useUTC?_t:bt).apply(null,a),i=t._useUTC?t._d.getUTCDay():t._d.getDay(),null!=t._tzm&&t._d.setUTCMinutes(t._d.getUTCMinutes()-t._tzm),t._nextDay&&(t._a[yi]=24),t._w&&"undefined"!=typeof t._w.d&&t._w.d!==i&&(p(t).weekdayMismatch=!0)}}function ue(t){var e,n,r,i,o,a,s,l;if(null!=(e=t._w).GG||null!=e.W||null!=e.E)o=1,a=4,n=ae(e.GG,t._a[pi],St(Ce(),1,4).year),r=ae(e.W,1),((i=ae(e.E,1))<1||7<i)&&(l=!0);else{o=t._locale._week.dow,a=t._locale._week.doy;var u=St(Ce(),o,a);n=ae(e.gg,t._a[pi],u.year),r=ae(e.w,u.week),null!=e.d?((i=e.d)<0||6<i)&&(l=!0):null!=e.e?(i=e.e+o,(e.e<0||6<e.e)&&(l=!0)):i=o}r<1||r>Tt(n,o,a)?p(t)._overflowWeeks=!0:null!=l?p(t)._overflowWeekday=!0:(s=wt(n,r,i,o,a),t._a[pi]=s.year,t._dayOfYear=s.dayOfYear)}function ce(t){var e,n,r,i,o,a,s=t._i,l=Vi.exec(s)||qi.exec(s);if(l){for(p(t).iso=!0,e=0,n=Yi.length;e<n;e++)if(Yi[e][1].exec(l[1])){i=Yi[e][0],r=!1!==Yi[e][2];break}if(null==i)return void(t._isValid=!1);if(l[3]){for(e=0,n=Gi.length;e<n;e++)if(Gi[e][1].exec(l[3])){o=(l[2]||" ")+Gi[e][0];break}if(null==o)return void(t._isValid=!1)}if(!r&&null!=o)return void(t._isValid=!1);if(l[4]){if(!Ui.exec(l[4]))return void(t._isValid=!1);a="Z"}t._f=i+(o||"")+(a||""),ve(t)}else t._isValid=!1}function de(t,e,n,r,i,o){var a=[he(t),Ei.indexOf(e),parseInt(n,10),parseInt(r,10),parseInt(i,10)];return o&&a.push(parseInt(o,10)),a}function he(t){var e=parseInt(t,10);return e<=49?2e3+e:e<=999?1900+e:e}function fe(t){return t.replace(/\([^)]*\)|[\n\t]/g," ").replace(/(\s\s+)/g," ").replace(/^\s\s*/,"").replace(/\s\s*$/,"")}function pe(t,e,n){if(t&&Ii.indexOf(t)!==new Date(e[0],e[1],e[2]).getDay())return p(n).weekdayMismatch=!0,n._isValid=!1;return!0}function ge(t,e,n){if(t)return Qi[t];if(e)return 0;var r=parseInt(n,10),i=r%100;return 60*((r-i)/100)+i}function me(t){var e=Xi.exec(fe(t._i));if(e){var n=de(e[4],e[3],e[2],e[5],e[6],e[7]);if(!pe(e[1],n,t))return;t._a=n,t._tzm=ge(e[8],e[9],e[10]),t._d=_t.apply(null,t._a),t._d.setUTCMinutes(t._d.getUTCMinutes()-t._tzm),p(t).rfc2822=!0}else t._isValid=!1}function ye(t){var e=Ki.exec(t._i);null===e?(ce(t),!1===t._isValid&&(delete t._isValid,me(t),!1===t._isValid&&(delete t._isValid,u.createFromInputFallback(t)))):t._d=new Date(+e[1])}function ve(t){if(t._f!==u.ISO_8601)if(t._f!==u.RFC_2822){t._a=[],p(t).empty=!0;var e,n,r,i,o,a=""+t._i,s=a.length,l=0;for(r=U(t._f,t._locale).match(Ur)||[],e=0;e<r.length;e++)i=r[e],(n=(a.match(G(i,t))||[])[0])&&(0<(o=a.substr(0,a.indexOf(n))).length&&p(t).unusedInput.push(o),a=a.slice(a.indexOf(n)+n.length),l+=n.length),Kr[i]?(n?p(t).empty=!1:p(t).unusedTokens.push(i),Z(i,n,t)):t._strict&&!n&&p(t).unusedTokens.push(i);p(t).charsLeftOver=s-l,0<a.length&&p(t).unusedInput.push(a),t._a[yi]<=12&&!0===p(t).bigHour&&0<t._a[yi]&&(p(t).bigHour=undefined),p(t).parsedDateParts=t._a.slice(0),p(t).meridiem=t._meridiem,t._a[yi]=be(t._locale,t._a[yi],t._meridiem),le(t),oe(t)}else me(t);else ce(t)}function be(t,e,n){var r;return null==n?e:null!=t.meridiemHour?t.meridiemHour(e,n):(null!=t.isPM&&((r=t.isPM(n))&&e<12&&(e+=12),r||12!==e||(e=0)),e)}function _e(t){var e,n,r,i,o;if(0===t._f.length)return p(t).invalidFormat=!0,void(t._d=new Date(NaN));for(i=0;i<t._f.length;i++)o=0,e=m({},t),null!=t._useUTC&&(e._useUTC=t._useUTC),e._f=t._f[i],ve(e),g(e)&&(o+=p(e).charsLeftOver,o+=10*p(e).unusedTokens.length,p(e).score=o,(null==r||o<r)&&(r=o,n=e));h(t,n||e)}function xe(t){if(!t._d){var e=F(t._i);t._a=n([e.year,e.month,e.day||e.date,e.hour,e.minute,e.second,e.millisecond],function(t){return t&&parseInt(t,10)}),le(t)}}function we(t){var e=new y(oe(Se(t)));return e._nextDay&&(e.add(1,"d"),e._nextDay=undefined),e}function Se(t){var e=t._i,n=t._f;return t._locale=t._locale||re(t._l),null===e||n===undefined&&""===e?r({nullInput:!0}):("string"==typeof e&&(t._i=e=t._locale.preparse(e)),v(e)?new y(oe(e)):(i(e)?t._d=e:a(n)?_e(t):n?ve(t):Te(t),g(t)||(t._d=null),t))}function Te(t){var e=t._i;o(e)?t._d=new Date(u.now()):i(e)?t._d=new Date(e.valueOf()):"string"==typeof e?ye(t):a(e)?(t._a=n(e.slice(0),function(t){return parseInt(t,10)}),le(t)):s(e)?xe(t):c(e)?t._d=new Date(e):u.createFromInputFallback(t)}function ke(t,e,n,r,i){var o={};return!0!==n&&!1!==n||(r=n,n=undefined),(s(t)&&l(t)||a(t)&&0===t.length)&&(t=undefined),o._isAMomentObject=!0,o._useUTC=o._isUTC=i,o._l=n,o._i=t,o._f=e,o._strict=r,we(o)}function Ce(t,e,n,r){return ke(t,e,n,r,!1)}function Ee(t,e){var n,r;if(1===e.length&&a(e[0])&&(e=e[0]),!e.length)return Ce();for(n=e[0],r=1;r<e.length;++r)e[r].isValid()&&!e[r][t](n)||(n=e[r]);return n}function De(){return Ee("isBefore",[].slice.call(arguments,0))}function Ae(){return Ee("isAfter",[].slice.call(arguments,0))}function Me(t){for(var e in t)if(-1===Si.call(to,e)||null!=t[e]&&isNaN(t[e]))return!1;for(var n=!1,r=0;r<to.length;++r)if(t[to[r]]){if(n)return!1;parseFloat(t[to[r]])!==_(t[to[r]])&&(n=!0)}return!0}function Oe(){return this._isValid}function Ie(){return $e(NaN)}function Pe(t){var e=F(t),n=e.year||0,r=e.quarter||0,i=e.month||0,o=e.week||e.isoWeek||0,a=e.day||0,s=e.hour||0,l=e.minute||0,u=e.second||0,c=e.millisecond||0;this._isValid=Me(e),this._milliseconds=+c+1e3*u+6e4*l+1e3*s*60*60,this._days=+a+7*o,this._months=+i+3*r+12*n,this._data={},this._locale=re(),this._bubble()}function Le(t){return t instanceof Pe}function Ne(t){return t<0?-1*Math.round(-1*t):Math.round(t)}function Re(t,n){z(t,0,0,function(){var t=this.utcOffset(),e="+";return t<0&&(t=-t,e="-"),e+W(~~(t/60),2)+n+W(~~t%60,2)})}function Fe(t,e){var n=(e||"").match(t);if(null===n)return null;var r=((n[n.length-1]||[])+"").match(eo)||["-",0,0],i=60*r[1]+_(r[2]);return 0===i?0:"+"===r[0]?i:-i}function He(t,e){var n,r;return e._isUTC?(n=e.clone(),r=(v(t)||i(t)?t.valueOf():Ce(t).valueOf())-n.valueOf(),n._d.setTime(n._d.valueOf()+r),u.updateOffset(n,!1),n):Ce(t).local()}function je(t){return 15*-Math.round(t._d.getTimezoneOffset()/15)}function We(t,e,n){var r,i=this._offset||0;if(!this.isValid())return null!=t?this:NaN;if(null==t)return this._isUTC?i:je(this);if("string"==typeof t){if(null===(t=Fe(ui,t)))return this}else Math.abs(t)<16&&!n&&(t*=60);return!this._isUTC&&e&&(r=je(this)),this._offset=t,this._isUTC=!0,null!=r&&this.add(r,"m"),i!==t&&(!e||this._changeInProgress?nn(this,$e(t-i,"m"),1,!1):this._changeInProgress||(this._changeInProgress=!0,u.updateOffset(this,!0),this._changeInProgress=null)),this}function ze(t,e){return null!=t?("string"!=typeof t&&(t=-t),this.utcOffset(t,e),this):-this.utcOffset()}function Be(t){return this.utcOffset(0,t)}function Ve(t){return this._isUTC&&(this.utcOffset(0,t),this._isUTC=!1,t&&this.subtract(je(this),"m")),this}function qe(){if(null!=this._tzm)this.utcOffset(this._tzm,!1,!0);else if("string"==typeof this._i){var t=Fe(li,this._i);null!=t?this.utcOffset(t):this.utcOffset(0,!0)}return this}function Ue(t){return!!this.isValid()&&(t=t?Ce(t).utcOffset():0,(this.utcOffset()-t)%60==0)}function Ye(){return this.utcOffset()>this.clone().month(0).utcOffset()||this.utcOffset()>this.clone().month(5).utcOffset()}function Ge(){if(!o(this._isDSTShifted))return this._isDSTShifted;var t={};if(m(t,this),(t=Se(t))._a){var e=t._isUTC?f(t._a):Ce(t._a);this._isDSTShifted=this.isValid()&&0<x(t._a,e.toArray())}else this._isDSTShifted=!1;return this._isDSTShifted}function Ke(){return!!this.isValid()&&!this._isUTC}function Xe(){return!!this.isValid()&&this._isUTC}function Qe(){return!!this.isValid()&&(this._isUTC&&0===this._offset)}function $e(t,e){var n,r,i,o=t,a=null;return Le(t)?o={ms:t._milliseconds,d:t._days,M:t._months}:c(t)?(o={},e?o[e]=t:o.milliseconds=t):(a=no.exec(t))?(n="-"===a[1]?-1:1,o={y:0,d:_(a[mi])*n,h:_(a[yi])*n,m:_(a[vi])*n,s:_(a[bi])*n,ms:_(Ne(1e3*a[_i]))*n}):(a=ro.exec(t))?(n="-"===a[1]?-1:1,o={y:Ze(a[2],n),M:Ze(a[3],n),w:Ze(a[4],n),d:Ze(a[5],n),h:Ze(a[6],n),m:Ze(a[7],n),s:Ze(a[8],n)}):null==o?o={}:"object"==typeof o&&("from"in o||"to"in o)&&(i=tn(Ce(o.from),Ce(o.to)),(o={}).ms=i.milliseconds,o.M=i.months),r=new Pe(o),Le(t)&&d(t,"_locale")&&(r._locale=t._locale),r}function Ze(t,e){var n=t&&parseFloat(t.replace(",","."));return(isNaN(n)?0:n)*e}function Je(t,e){var n={};return n.months=e.month()-t.month()+12*(e.year()-t.year()),t.clone().add(n.months,"M").isAfter(e)&&--n.months,n.milliseconds=+e-+t.clone().add(n.months,"M"),n}function tn(t,e){var n;return t.isValid()&&e.isValid()?(e=He(e,t),t.isBefore(e)?n=Je(t,e):((n=Je(e,t)).milliseconds=-n.milliseconds,n.months=-n.months),n):{milliseconds:0,months:0}}function en(r,i){return function(t,e){var n;return null===e||isNaN(+e)||(T(i,"moment()."+i+"(period, number) is deprecated. Please use moment()."+i+"(number, period). See http://momentjs.com/guides/#/warnings/add-inverted-param/ for more info."),n=t,t=e,e=n),nn(this,$e(t="string"==typeof t?+t:t,e),r),this}}function nn(t,e,n,r){var i=e._milliseconds,o=Ne(e._days),a=Ne(e._months);t.isValid()&&(r=null==r||r,a&&ft(t,rt(t,"Month")+a*n),o&&it(t,"Date",rt(t,"Date")+o*n),i&&t._d.setTime(t._d.valueOf()+i*n),r&&u.updateOffset(t,o||a))}function rn(t,e){var n=t.diff(e,"days",!0);return n<-6?"sameElse":n<-1?"lastWeek":n<0?"lastDay":n<1?"sameDay":n<2?"nextDay":n<7?"nextWeek":"sameElse"}function on(t,e){var n=t||Ce(),r=He(n,this).startOf("day"),i=u.calendarFormat(this,r)||"sameElse",o=e&&(k(e[i])?e[i].call(this,n):e[i]);return this.format(o||this.localeData().calendar(i,this,Ce(n)))}function an(){return new y(this)}function sn(t,e){var n=v(t)?t:Ce(t);return!(!this.isValid()||!n.isValid())&&("millisecond"===(e=R(e)||"millisecond")?this.valueOf()>n.valueOf():n.valueOf()<this.clone().startOf(e).valueOf())}function ln(t,e){var n=v(t)?t:Ce(t);return!(!this.isValid()||!n.isValid())&&("millisecond"===(e=R(e)||"millisecond")?this.valueOf()<n.valueOf():this.clone().endOf(e).valueOf()<n.valueOf())}function un(t,e,n,r){var i=v(t)?t:Ce(t),o=v(e)?e:Ce(e);return!!(this.isValid()&&i.isValid()&&o.isValid())&&(("("===(r=r||"()")[0]?this.isAfter(i,n):!this.isBefore(i,n))&&(")"===r[1]?this.isBefore(o,n):!this.isAfter(o,n)))}function cn(t,e){var n,r=v(t)?t:Ce(t);return!(!this.isValid()||!r.isValid())&&("millisecond"===(e=R(e)||"millisecond")?this.valueOf()===r.valueOf():(n=r.valueOf(),this.clone().startOf(e).valueOf()<=n&&n<=this.clone().endOf(e).valueOf()))}function dn(t,e){return this.isSame(t,e)||this.isAfter(t,e)}function hn(t,e){return this.isSame(t,e)||this.isBefore(t,e)}function fn(t,e,n){var r,i,o;if(!this.isValid())return NaN;if(!(r=He(t,this)).isValid())return NaN;switch(i=6e4*(r.utcOffset()-this.utcOffset()),e=R(e)){case"year":o=pn(this,r)/12;break;case"month":o=pn(this,r);break;case"quarter":o=pn(this,r)/3;break;case"second":o=(this-r)/1e3;break;case"minute":o=(this-r)/6e4;break;case"hour":o=(this-r)/36e5;break;case"day":o=(this-r-i)/864e5;break;case"week":o=(this-r-i)/6048e5;break;default:o=this-r}return n?o:b(o)}function pn(t,e){var n=12*(e.year()-t.year())+(e.month()-t.month()),r=t.clone().add(n,"months");return-(n+(e-r<0?(e-r)/(r-t.clone().add(n-1,"months")):(e-r)/(t.clone().add(n+1,"months")-r)))||0}function gn(){return this.clone().locale("en").format("ddd MMM DD YYYY HH:mm:ss [GMT]ZZ")}function mn(t){if(!this.isValid())return null;var e=!0!==t,n=e?this.clone().utc():this;return n.year()<0||9999<n.year()?q(n,e?"YYYYYY-MM-DD[T]HH:mm:ss.SSS[Z]":"YYYYYY-MM-DD[T]HH:mm:ss.SSSZ"):k(Date.prototype.toISOString)?e?this.toDate().toISOString():new Date(this.valueOf()+60*this.utcOffset()*1e3).toISOString().replace("Z",q(n,"Z")):q(n,e?"YYYY-MM-DD[T]HH:mm:ss.SSS[Z]":"YYYY-MM-DD[T]HH:mm:ss.SSSZ")}function yn(){if(!this.isValid())return"moment.invalid(/* "+this._i+" */)";var t="moment",e="";this.isLocal()||(t=0===this.utcOffset()?"moment.utc":"moment.parseZone",e="Z");var n="["+t+'("]',r=0<=this.year()&&this.year()<=9999?"YYYY":"YYYYYY",i="-MM-DD[T]HH:mm:ss.SSS",o=e+'[")]';return this.format(n+r+i+o)}function vn(t){t||(t=this.isUtc()?u.defaultFormatUtc:u.defaultFormat);var e=q(this,t);return this.localeData().postformat(e)}function bn(t,e){return this.isValid()&&(v(t)&&t.isValid()||Ce(t).isValid())?$e({to:this,from:t}).locale(this.locale()).humanize(!e):this.localeData().invalidDate()}function _n(t){return this.from(Ce(),t)}function xn(t,e){return this.isValid()&&(v(t)&&t.isValid()||Ce(t).isValid())?$e({from:this,to:t}).locale(this.locale()).humanize(!e):this.localeData().invalidDate()}function wn(t){return this.to(Ce(),t)}function Sn(t){var e;return t===undefined?this._locale._abbr:(null!=(e=re(t))&&(this._locale=e),this)}function Tn(){return this._locale}function kn(t,e){return(t%e+e)%e}function Cn(t,e,n){return t<100&&0<=t?new Date(t+400,e,n)-co:new Date(t,e,n).valueOf()}function En(t,e,n){return t<100&&0<=t?Date.UTC(t+400,e,n)-co:Date.UTC(t,e,n)}function Dn(t){var e;if((t=R(t))===undefined||"millisecond"===t||!this.isValid())return this;var n=this._isUTC?En:Cn;switch(t){case"year":e=n(this.year(),0,1);break;case"quarter":e=n(this.year(),this.month()-this.month()%3,1);break;case"month":e=n(this.year(),this.month(),1);break;case"week":e=n(this.year(),this.month(),this.date()-this.weekday());break;case"isoWeek":e=n(this.year(),this.month(),this.date()-(this.isoWeekday()-1));break;case"day":case"date":e=n(this.year(),this.month(),this.date());break;case"hour":e=this._d.valueOf(),e-=kn(e+(this._isUTC?0:this.utcOffset()*lo),uo);break;case"minute":e=this._d.valueOf(),e-=kn(e,lo);break;case"second":e=this._d.valueOf(),e-=kn(e,so)}return this._d.setTime(e),u.updateOffset(this,!0),this}function An(t){var e;if((t=R(t))===undefined||"millisecond"===t||!this.isValid())return this;var n=this._isUTC?En:Cn;switch(t){case"year":e=n(this.year()+1,0,1)-1;break;case"quarter":e=n(this.year(),this.month()-this.month()%3+3,1)-1;break;case"month":e=n(this.year(),this.month()+1,1)-1;break;case"week":e=n(this.year(),this.month(),this.date()-this.weekday()+7)-1;break;case"isoWeek":e=n(this.year(),this.month(),this.date()-(this.isoWeekday()-1)+7)-1;break;case"day":case"date":e=n(this.year(),this.month(),this.date()+1)-1;break;case"hour":e=this._d.valueOf(),e+=uo-kn(e+(this._isUTC?0:this.utcOffset()*lo),uo)-1;break;case"minute":e=this._d.valueOf(),e+=lo-kn(e,lo)-1;break;case"second":e=this._d.valueOf(),e+=so-kn(e,so)-1}return this._d.setTime(e),u.updateOffset(this,!0),this}function Mn(){return this._d.valueOf()-6e4*(this._offset||0)}function On(){return Math.floor(this.valueOf()/1e3)}function In(){return new Date(this.valueOf())}function Pn(){var t=this;return[t.year(),t.month(),t.date(),t.hour(),t.minute(),t.second(),t.millisecond()]}function Ln(){var t=this;return{years:t.year(),months:t.month(),date:t.date(),hours:t.hours(),minutes:t.minutes(),seconds:t.seconds(),milliseconds:t.milliseconds()}}function Nn(){return this.isValid()?this.toISOString():null}function Rn(){return g(this)}function Fn(){return h({},p(this))}function Hn(){return p(this).overflow}function jn(){return{input:this._i,format:this._f,locale:this._locale,isUTC:this._isUTC,strict:this._strict}}function Wn(t,e){z(0,[t,t.length],0,e)}function zn(t){return Un.call(this,t,this.week(),this.weekday(),this.localeData()._week.dow,this.localeData()._week.doy)}function Bn(t){return Un.call(this,t,this.isoWeek(),this.isoWeekday(),1,4)}function Vn(){return Tt(this.year(),1,4)}function qn(){var t=this.localeData()._week;return Tt(this.year(),t.dow,t.doy)}function Un(t,e,n,r,i){var o;return null==t?St(this,r,i).year:((o=Tt(t,r,i))<e&&(e=o),Yn.call(this,t,e,n,r,i))}function Yn(t,e,n,r,i){var o=wt(t,e,n,r,i),a=_t(o.year,0,o.dayOfYear);return this.year(a.getUTCFullYear()),this.month(a.getUTCMonth()),this.date(a.getUTCDate()),this}function Gn(t){return null==t?Math.ceil((this.month()+1)/3):this.month(3*(t-1)+this.month()%3)}function Kn(t){var e=Math.round((this.clone().startOf("day")-this.clone().startOf("year"))/864e5)+1;return null==t?e:this.add(t-e,"d")}function Xn(t,e){e[_i]=_(1e3*("0."+t))}function Qn(){return this._isUTC?"UTC":""}function $n(){return this._isUTC?"Coordinated Universal Time":""}function Zn(t){return Ce(1e3*t)}function Jn(){return Ce.apply(null,arguments).parseZone()}function tr(t){return t}function er(t,e,n,r){var i=re(),o=f().set(r,e);return i[n](o,t)}function nr(t,e,n){if(c(t)&&(e=t,t=undefined),t=t||"",null!=e)return er(t,e,n,"month");var r,i=[];for(r=0;r<12;r++)i[r]=er(t,r,n,"month");return i}function rr(t,e,n,r){"boolean"==typeof t?c(e)&&(n=e,e=undefined):(e=t,t=!1,c(n=e)&&(n=e,e=undefined)),e=e||"";var i,o=re(),a=t?o._week.dow:0;if(null!=n)return er(e,(n+a)%7,r,"day");var s=[];for(i=0;i<7;i++)s[i]=er(e,(i+a)%7,r,"day");return s}function ir(t,e){return nr(t,e,"months")}function or(t,e){return nr(t,e,"monthsShort")}function ar(t,e,n){return rr(t,e,n,"weekdays")}function sr(t,e,n){return rr(t,e,n,"weekdaysShort")}function lr(t,e,n){return rr(t,e,n,"weekdaysMin")}function ur(){var t=this._data;return this._milliseconds=bo(this._milliseconds),this._days=bo(this._days),this._months=bo(this._months),t.milliseconds=bo(t.milliseconds),t.seconds=bo(t.seconds),t.minutes=bo(t.minutes),t.hours=bo(t.hours),t.months=bo(t.months),t.years=bo(t.years),this}function cr(t,e,n,r){var i=$e(e,n);return t._milliseconds+=r*i._milliseconds,t._days+=r*i._days,t._months+=r*i._months,t._bubble()}function dr(t,e){return cr(this,t,e,1)}function hr(t,e){return cr(this,t,e,-1)}function fr(t){return t<0?Math.floor(t):Math.ceil(t)}function pr(){var t,e,n,r,i,o=this._milliseconds,a=this._days,s=this._months,l=this._data;return 0<=o&&0<=a&&0<=s||o<=0&&a<=0&&s<=0||(o+=864e5*fr(mr(s)+a),s=a=0),l.milliseconds=o%1e3,t=b(o/1e3),l.seconds=t%60,e=b(t/60),l.minutes=e%60,n=b(e/60),l.hours=n%24,s+=i=b(gr(a+=b(n/24))),a-=fr(mr(i)),r=b(s/12),s%=12,l.days=a,l.months=s,l.years=r,this}function gr(t){return 4800*t/146097}function mr(t){return 146097*t/4800}function yr(t){if(!this.isValid())return NaN;var e,n,r=this._milliseconds;if("month"===(t=R(t))||"quarter"===t||"year"===t)switch(e=this._days+r/864e5,n=this._months+gr(e),t){case"month":return n;case"quarter":return n/3;case"year":return n/12}else switch(e=this._days+Math.round(mr(this._months)),t){case"week":return e/7+r/6048e5;case"day":return e+r/864e5;case"hour":return 24*e+r/36e5;case"minute":return 1440*e+r/6e4;case"second":return 86400*e+r/1e3;case"millisecond":return Math.floor(864e5*e)+r;default:throw new Error("Unknown unit "+t)}}function vr(){return this.isValid()?this._milliseconds+864e5*this._days+this._months%12*2592e6+31536e6*_(this._months/12):NaN}function br(t){return function(){return this.as(t)}}function _r(){return $e(this)}function xr(t){return t=R(t),this.isValid()?this[t+"s"]():NaN}function wr(t){return function(){return this.isValid()?this._data[t]:NaN}}function Sr(){return b(this.days()/7)}function Tr(t,e,n,r,i){return i.relativeTime(e||1,!!n,t,r)}function kr(t,e,n){var r=$e(t).abs(),i=Ro(r.as("s")),o=Ro(r.as("m")),a=Ro(r.as("h")),s=Ro(r.as("d")),l=Ro(r.as("M")),u=Ro(r.as("y")),c=i<=Fo.ss&&["s",i]||i<Fo.s&&["ss",i]||o<=1&&["m"]||o<Fo.m&&["mm",o]||a<=1&&["h"]||a<Fo.h&&["hh",a]||s<=1&&["d"]||s<Fo.d&&["dd",s]||l<=1&&["M"]||l<Fo.M&&["MM",l]||u<=1&&["y"]||["yy",u];return c[2]=e,c[3]=0<+t,c[4]=n,Tr.apply(null,c)}function Cr(t){return t===undefined?Ro:"function"==typeof t&&(Ro=t,!0)}function Er(t,e){return Fo[t]!==undefined&&(e===undefined?Fo[t]:(Fo[t]=e,"s"===t&&(Fo.ss=e-1),!0))}function Dr(t){if(!this.isValid())return this.localeData().invalidDate();var e=this.localeData(),n=kr(this,!t,e);return t&&(n=e.pastFuture(+this,n)),e.postformat(n)}function Ar(t){return(0<t)-(t<0)||+t}function Mr(){if(!this.isValid())return this.localeData().invalidDate();var t,e,n=Ho(this._milliseconds)/1e3,r=Ho(this._days),i=Ho(this._months);e=b((t=b(n/60))/60),n%=60,t%=60;var o=b(i/12),a=i%=12,s=r,l=e,u=t,c=n?n.toFixed(3).replace(/\.?0+$/,""):"",d=this.asSeconds();if(!d)return"P0D";var h=d<0?"-":"",f=Ar(this._months)!==Ar(d)?"-":"",p=Ar(this._days)!==Ar(d)?"-":"",g=Ar(this._milliseconds)!==Ar(d)?"-":"";return h+"P"+(o?f+o+"Y":"")+(a?f+a+"M":"")+(s?p+s+"D":"")+(l||u||c?"T":"")+(l?g+l+"H":"")+(u?g+u+"M":"")+(c?g+c+"S":"")}var Or,Ir;Ir=Array.prototype.some?Array.prototype.some:function(t){for(var e=Object(this),n=e.length>>>0,r=0;r<n;r++)if(r in e&&t.call(this,e[r],r,e))return!0;return!1};var Pr,Lr=u.momentProperties=[],Nr=!1,Rr={};u.suppressDeprecationWarnings=!1,u.deprecationHandler=null,Pr=Object.keys?Object.keys:function(t){var e,n=[];for(e in t)d(t,e)&&n.push(e);return n};var Fr={sameDay:"[Today at] LT",nextDay:"[Tomorrow at] LT",nextWeek:"dddd [at] LT",lastDay:"[Yesterday at] LT",lastWeek:"[Last] dddd [at] LT",sameElse:"L"},Hr={LTS:"h:mm:ss A",LT:"h:mm A",L:"MM/DD/YYYY",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY h:mm A",LLLL:"dddd, MMMM D, YYYY h:mm A"},jr="Invalid date",Wr="%d",zr=/\d{1,2}/,Br={future:"in %s",past:"%s ago",s:"a few seconds",ss:"%d seconds",m:"a minute",mm:"%d minutes",h:"an hour",hh:"%d hours",d:"a day",dd:"%d days",M:"a month",MM:"%d months",y:"a year",yy:"%d years"},Vr={},qr={},Ur=/(\[[^\[]*\])|(\\)?([Hh]mm(ss)?|Mo|MM?M?M?|Do|DDDo|DD?D?D?|ddd?d?|do?|w[o|w]?|W[o|W]?|Qo?|YYYYYY|YYYYY|YYYY|YY|gg(ggg?)?|GG(GGG?)?|e|E|a|A|hh?|HH?|kk?|mm?|ss?|S{1,9}|x|X|zz?|ZZ?|.)/g,Yr=/(\[[^\[]*\])|(\\)?(LTS|LT|LL?L?L?|l{1,4})/g,Gr={},Kr={},Xr=/\d/,Qr=/\d\d/,$r=/\d{3}/,Zr=/\d{4}/,Jr=/[+-]?\d{6}/,ti=/\d\d?/,ei=/\d\d\d\d?/,ni=/\d\d\d\d\d\d?/,ri=/\d{1,3}/,ii=/\d{1,4}/,oi=/[+-]?\d{1,6}/,ai=/\d+/,si=/[+-]?\d+/,li=/Z|[+-]\d\d:?\d\d/gi,ui=/Z|[+-]\d\d(?::?\d\d)?/gi,ci=/[+-]?\d+(\.\d{1,3})?/,di=/[0-9]{0,256}['a-z\u00A0-\u05FF\u0700-\uD7FF\uF900-\uFDCF\uFDF0-\uFF07\uFF10-\uFFEF]{1,256}|[\u0600-\u06FF\/]{1,256}(\s*?[\u0600-\u06FF]{1,256}){1,2}/i,hi={},fi={},pi=0,gi=1,mi=2,yi=3,vi=4,bi=5,_i=6,xi=7,wi=8;z("Y",0,0,function(){var t=this.year();return t<=9999?""+t:"+"+t}),z(0,["YY",2],0,function(){return this.year()%100}),z(0,["YYYY",4],0,"year"),z(0,["YYYYY",5],0,"year"),z(0,["YYYYYY",6,!0],0,"year"),N("year","y"),H("year",1),Y("Y",si),Y("YY",ti,Qr),Y("YYYY",ii,Zr),Y("YYYYY",oi,Jr),Y("YYYYYY",oi,Jr),Q(["YYYYY","YYYYYY"],pi),Q("YYYY",function(t,e){e[pi]=2===t.length?u.parseTwoDigitYear(t):_(t)}),Q("YY",function(t,e){e[pi]=u.parseTwoDigitYear(t)}),Q("Y",function(t,e){e[pi]=parseInt(t,10)}),u.parseTwoDigitYear=function(t){return _(t)+(68<_(t)?1900:2e3)};var Si,Ti=nt("FullYear",!0);Si=Array.prototype.indexOf?Array.prototype.indexOf:function(t){var e;for(e=0;e<this.length;++e)if(this[e]===t)return e;return-1},z("M",["MM",2],"Mo",function(){return this.month()+1}),z("MMM",0,0,function(t){return this.localeData().monthsShort(this,t)}),z("MMMM",0,0,function(t){return this.localeData().months(this,t)}),N("month","M"),H("month",8),Y("M",ti),Y("MM",ti,Qr),Y("MMM",function(t,e){return e.monthsShortRegex(t)}),Y("MMMM",function(t,e){return e.monthsRegex(t)}),Q(["M","MM"],function(t,e){e[gi]=_(t)-1}),Q(["MMM","MMMM"],function(t,e,n,r){var i=n._locale.monthsParse(t,r,n._strict);null!=i?e[gi]=i:p(n).invalidMonth=t});var ki=/D[oD]?(\[[^\[\]]*\]|\s)+MMMM?/,Ci="January_February_March_April_May_June_July_August_September_October_November_December".split("_"),Ei="Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec".split("_"),Di=di,Ai=di;z("w",["ww",2],"wo","week"),z("W",["WW",2],"Wo","isoWeek"),N("week","w"),N("isoWeek","W"),H("week",5),H("isoWeek",5),Y("w",ti),Y("ww",ti,Qr),Y("W",ti),Y("WW",ti,Qr),$(["w","ww","W","WW"],function(t,e,n,r){e[r.substr(0,1)]=_(t)});var Mi={dow:0,doy:6};z("d",0,"do","day"),z("dd",0,0,function(t){return this.localeData().weekdaysMin(this,t)}),z("ddd",0,0,function(t){return this.localeData().weekdaysShort(this,t)}),z("dddd",0,0,function(t){return this.localeData().weekdays(this,t)}),z("e",0,0,"weekday"),z("E",0,0,"isoWeekday"),N("day","d"),N("weekday","e"),N("isoWeekday","E"),H("day",11),H("weekday",11),H("isoWeekday",11),Y("d",ti),Y("e",ti),Y("E",ti),Y("dd",function(t,e){return e.weekdaysMinRegex(t)}),Y("ddd",function(t,e){return e.weekdaysShortRegex(t)}),Y("dddd",function(t,e){return e.weekdaysRegex(t)}),$(["dd","ddd","dddd"],function(t,e,n,r){var i=n._locale.weekdaysParse(t,r,n._strict);null!=i?e.d=i:p(n).invalidWeekday=t}),$(["d","e","E"],function(t,e,n,r){e[r]=_(t)});var Oi="Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),Ii="Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"),Pi="Su_Mo_Tu_We_Th_Fr_Sa".split("_"),Li=di,Ni=di,Ri=di;z("H",["HH",2],0,"hour"),z("h",["hh",2],0,Ut),z("k",["kk",2],0,Yt),z("hmm",0,0,function(){return""+Ut.apply(this)+W(this.minutes(),2)}),z("hmmss",0,0,function(){return""+Ut.apply(this)+W(this.minutes(),2)+W(this.seconds(),2)}),z("Hmm",0,0,function(){return""+this.hours()+W(this.minutes(),2)}),z("Hmmss",0,0,function(){return""+this.hours()+W(this.minutes(),2)+W(this.seconds(),2)}),Gt("a",!0),Gt("A",!1),N("hour","h"),H("hour",13),Y("a",Kt),Y("A",Kt),Y("H",ti),Y("h",ti),Y("k",ti),Y("HH",ti,Qr),Y("hh",ti,Qr),Y("kk",ti,Qr),Y("hmm",ei),Y("hmmss",ni),Y("Hmm",ei),Y("Hmmss",ni),Q(["H","HH"],yi),Q(["k","kk"],function(t,e){var n=_(t);e[yi]=24===n?0:n}),Q(["a","A"],function(t,e,n){n._isPm=n._locale.isPM(t),n._meridiem=t}),Q(["h","hh"],function(t,e,n){e[yi]=_(t),p(n).bigHour=!0}),Q("hmm",function(t,e,n){var r=t.length-2;e[yi]=_(t.substr(0,r)),e[vi]=_(t.substr(r)),p(n).bigHour=!0}),Q("hmmss",function(t,e,n){var r=t.length-4,i=t.length-2;e[yi]=_(t.substr(0,r)),e[vi]=_(t.substr(r,2)),e[bi]=_(t.substr(i)),p(n).bigHour=!0}),Q("Hmm",function(t,e){var n=t.length-2;e[yi]=_(t.substr(0,n)),e[vi]=_(t.substr(n))}),Q("Hmmss",function(t,e){var n=t.length-4,r=t.length-2;e[yi]=_(t.substr(0,n)),e[vi]=_(t.substr(n,2)),e[bi]=_(t.substr(r))});var Fi,Hi=/[ap]\.?m?\.?/i,ji=nt("Hours",!0),Wi={calendar:Fr,longDateFormat:Hr,invalidDate:jr,ordinal:Wr,dayOfMonthOrdinalParse:zr,relativeTime:Br,months:Ci,monthsShort:Ei,week:Mi,weekdays:Oi,weekdaysMin:Pi,weekdaysShort:Ii,meridiemParse:Hi},zi={},Bi={},Vi=/^\s*((?:[+-]\d{6}|\d{4})-(?:\d\d-\d\d|W\d\d-\d|W\d\d|\d\d\d|\d\d))(?:(T| )(\d\d(?::\d\d(?::\d\d(?:[.,]\d+)?)?)?)([\+\-]\d\d(?::?\d\d)?|\s*Z)?)?$/,qi=/^\s*((?:[+-]\d{6}|\d{4})(?:\d\d\d\d|W\d\d\d|W\d\d|\d\d\d|\d\d))(?:(T| )(\d\d(?:\d\d(?:\d\d(?:[.,]\d+)?)?)?)([\+\-]\d\d(?::?\d\d)?|\s*Z)?)?$/,Ui=/Z|[+-]\d\d(?::?\d\d)?/,Yi=[["YYYYYY-MM-DD",/[+-]\d{6}-\d\d-\d\d/],["YYYY-MM-DD",/\d{4}-\d\d-\d\d/],["GGGG-[W]WW-E",/\d{4}-W\d\d-\d/],["GGGG-[W]WW",/\d{4}-W\d\d/,!1],["YYYY-DDD",/\d{4}-\d{3}/],["YYYY-MM",/\d{4}-\d\d/,!1],["YYYYYYMMDD",/[+-]\d{10}/],["YYYYMMDD",/\d{8}/],["GGGG[W]WWE",/\d{4}W\d{3}/],["GGGG[W]WW",/\d{4}W\d{2}/,!1],["YYYYDDD",/\d{7}/]],Gi=[["HH:mm:ss.SSSS",/\d\d:\d\d:\d\d\.\d+/],["HH:mm:ss,SSSS",/\d\d:\d\d:\d\d,\d+/],["HH:mm:ss",/\d\d:\d\d:\d\d/],["HH:mm",/\d\d:\d\d/],["HHmmss.SSSS",/\d\d\d\d\d\d\.\d+/],["HHmmss,SSSS",/\d\d\d\d\d\d,\d+/],["HHmmss",/\d\d\d\d\d\d/],["HHmm",/\d\d\d\d/],["HH",/\d\d/]],Ki=/^\/?Date\((\-?\d+)/i,Xi=/^(?:(Mon|Tue|Wed|Thu|Fri|Sat|Sun),?\s)?(\d{1,2})\s(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)\s(\d{2,4})\s(\d\d):(\d\d)(?::(\d\d))?\s(?:(UT|GMT|[ECMP][SD]T)|([Zz])|([+-]\d{4}))$/,Qi={UT:0,GMT:0,EDT:-240,EST:-300,CDT:-300,CST:-360,MDT:-360,MST:-420,PDT:-420,PST:-480};u.createFromInputFallback=S("value provided is not in a recognized RFC2822 or ISO format. moment construction falls back to js Date(), which is not reliable across all browsers and versions. Non RFC2822/ISO date formats are discouraged and will be removed in an upcoming major release. Please refer to http://momentjs.com/guides/#/warnings/js-date/ for more info.",function(t){t._d=new Date(t._i+(t._useUTC?" UTC":""))}),u.ISO_8601=function(){},u.RFC_2822=function(){};var $i=S("moment().min is deprecated, use moment.max instead. http://momentjs.com/guides/#/warnings/min-max/",function(){var t=Ce.apply(null,arguments);return this.isValid()&&t.isValid()?t<this?this:t:r()}),Zi=S("moment().max is deprecated, use moment.min instead. http://momentjs.com/guides/#/warnings/min-max/",function(){var t=Ce.apply(null,arguments);return this.isValid()&&t.isValid()?this<t?this:t:r()}),Ji=function(){return Date.now?Date.now():+new Date},to=["year","quarter","month","week","day","hour","minute","second","millisecond"];Re("Z",":"),Re("ZZ",""),Y("Z",ui),Y("ZZ",ui),Q(["Z","ZZ"],function(t,e,n){n._useUTC=!0,n._tzm=Fe(ui,t)});var eo=/([\+\-]|\d\d)/gi;u.updateOffset=function(){};var no=/^(\-|\+)?(?:(\d*)[. ])?(\d+)\:(\d+)(?:\:(\d+)(\.\d*)?)?$/,ro=/^(-|\+)?P(?:([-+]?[0-9,.]*)Y)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)W)?(?:([-+]?[0-9,.]*)D)?(?:T(?:([-+]?[0-9,.]*)H)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)S)?)?$/;$e.fn=Pe.prototype,$e.invalid=Ie;var io=en(1,"add"),oo=en(-1,"subtract");u.defaultFormat="YYYY-MM-DDTHH:mm:ssZ",u.defaultFormatUtc="YYYY-MM-DDTHH:mm:ss[Z]";var ao=S("moment().lang() is deprecated. Instead, use moment().localeData() to get the language configuration. Use moment().locale() to change languages.",function(t){return t===undefined?this.localeData():this.locale(t)}),so=1e3,lo=60*so,uo=60*lo,co=3506328*uo;z(0,["gg",2],0,function(){return this.weekYear()%100}),z(0,["GG",2],0,function(){return this.isoWeekYear()%100}),Wn("gggg","weekYear"),Wn("ggggg","weekYear"),Wn("GGGG","isoWeekYear"),Wn("GGGGG","isoWeekYear"),N("weekYear","gg"),N("isoWeekYear","GG"),H("weekYear",1),H("isoWeekYear",1),Y("G",si),Y("g",si),Y("GG",ti,Qr),Y("gg",ti,Qr),Y("GGGG",ii,Zr),Y("gggg",ii,Zr),Y("GGGGG",oi,Jr),Y("ggggg",oi,Jr),$(["gggg","ggggg","GGGG","GGGGG"],function(t,e,n,r){e[r.substr(0,2)]=_(t)}),$(["gg","GG"],function(t,e,n,r){e[r]=u.parseTwoDigitYear(t)}),z("Q",0,"Qo","quarter"),N("quarter","Q"),H("quarter",7),Y("Q",Xr),Q("Q",function(t,e){e[gi]=3*(_(t)-1)}),z("D",["DD",2],"Do","date"),N("date","D"),H("date",9),Y("D",ti),Y("DD",ti,Qr),Y("Do",function(t,e){return t?e._dayOfMonthOrdinalParse||e._ordinalParse:e._dayOfMonthOrdinalParseLenient}),Q(["D","DD"],mi),Q("Do",function(t,e){e[mi]=_(t.match(ti)[0])});var ho=nt("Date",!0);z("DDD",["DDDD",3],"DDDo","dayOfYear"),N("dayOfYear","DDD"),H("dayOfYear",4),Y("DDD",ri),Y("DDDD",$r),Q(["DDD","DDDD"],function(t,e,n){n._dayOfYear=_(t)}),z("m",["mm",2],0,"minute"),N("minute","m"),H("minute",14),Y("m",ti),Y("mm",ti,Qr),Q(["m","mm"],vi);var fo=nt("Minutes",!1);z("s",["ss",2],0,"second"),N("second","s"),H("second",15),Y("s",ti),Y("ss",ti,Qr),Q(["s","ss"],bi);var po,go=nt("Seconds",!1);for(z("S",0,0,function(){return~~(this.millisecond()/100)}),z(0,["SS",2],0,function(){return~~(this.millisecond()/10)}),z(0,["SSS",3],0,"millisecond"),z(0,["SSSS",4],0,function(){return 10*this.millisecond()}),z(0,["SSSSS",5],0,function(){return 100*this.millisecond()}),z(0,["SSSSSS",6],0,function(){return 1e3*this.millisecond()}),z(0,["SSSSSSS",7],0,function(){return 1e4*this.millisecond()}),z(0,["SSSSSSSS",8],0,function(){return 1e5*this.millisecond()}),z(0,["SSSSSSSSS",9],0,function(){return 1e6*this.millisecond()}),N("millisecond","ms"),H("millisecond",16),Y("S",ri,Xr),Y("SS",ri,Qr),Y("SSS",ri,$r),po="SSSS";po.length<=9;po+="S")Y(po,ai);for(po="S";po.length<=9;po+="S")Q(po,Xn);var mo=nt("Milliseconds",!1);z("z",0,0,"zoneAbbr"),z("zz",0,0,"zoneName");var yo=y.prototype;yo.add=io,yo.calendar=on,yo.clone=an,yo.diff=fn,yo.endOf=An,
yo.format=vn,yo.from=bn,yo.fromNow=_n,yo.to=xn,yo.toNow=wn,yo.get=ot,yo.invalidAt=Hn,yo.isAfter=sn,yo.isBefore=ln,yo.isBetween=un,yo.isSame=cn,yo.isSameOrAfter=dn,yo.isSameOrBefore=hn,yo.isValid=Rn,yo.lang=ao,yo.locale=Sn,yo.localeData=Tn,yo.max=Zi,yo.min=$i,yo.parsingFlags=Fn,yo.set=at,yo.startOf=Dn,yo.subtract=oo,yo.toArray=Pn,yo.toObject=Ln,yo.toDate=In,yo.toISOString=mn,yo.inspect=yn,yo.toJSON=Nn,yo.toString=gn,yo.unix=On,yo.valueOf=Mn,yo.creationData=jn,yo.year=Ti,yo.isLeapYear=et,yo.weekYear=zn,yo.isoWeekYear=Bn,yo.quarter=yo.quarters=Gn,yo.month=pt,yo.daysInMonth=gt,yo.week=yo.weeks=Dt,yo.isoWeek=yo.isoWeeks=At,yo.weeksInYear=qn,yo.isoWeeksInYear=Vn,yo.date=ho,yo.day=yo.days=Ht,yo.weekday=jt,yo.isoWeekday=Wt,yo.dayOfYear=Kn,yo.hour=yo.hours=ji,yo.minute=yo.minutes=fo,yo.second=yo.seconds=go,yo.millisecond=yo.milliseconds=mo,yo.utcOffset=We,yo.utc=Be,yo.local=Ve,yo.parseZone=qe,yo.hasAlignedHourOffset=Ue,yo.isDST=Ye,yo.isLocal=Ke,yo.isUtcOffset=Xe,yo.isUtc=Qe,yo.isUTC=Qe,yo.zoneAbbr=Qn,yo.zoneName=$n,yo.dates=S("dates accessor is deprecated. Use date instead.",ho),yo.months=S("months accessor is deprecated. Use month instead",pt),yo.years=S("years accessor is deprecated. Use year instead",Ti),yo.zone=S("moment().zone is deprecated, use moment().utcOffset instead. http://momentjs.com/guides/#/warnings/zone/",ze),yo.isDSTShifted=S("isDSTShifted is deprecated. See http://momentjs.com/guides/#/warnings/dst-shifted/ for more information",Ge);var vo=D.prototype;vo.calendar=A,vo.longDateFormat=M,vo.invalidDate=O,vo.ordinal=I,vo.preparse=tr,vo.postformat=tr,vo.relativeTime=P,vo.pastFuture=L,vo.set=C,vo.months=ut,vo.monthsShort=ct,vo.monthsParse=ht,vo.monthsRegex=yt,vo.monthsShortRegex=mt,vo.week=kt,vo.firstDayOfYear=Et,vo.firstDayOfWeek=Ct,vo.weekdays=Pt,vo.weekdaysMin=Nt,vo.weekdaysShort=Lt,vo.weekdaysParse=Ft,vo.weekdaysRegex=zt,vo.weekdaysShortRegex=Bt,vo.weekdaysMinRegex=Vt,vo.isPM=Xt,vo.meridiem=Qt,te("en",{dayOfMonthOrdinalParse:/\d{1,2}(th|st|nd|rd)/,ordinal:function(t){var e=t%10;return t+(1===_(t%100/10)?"th":1===e?"st":2===e?"nd":3===e?"rd":"th")}}),u.lang=S("moment.lang is deprecated. Use moment.locale instead.",te),u.langData=S("moment.langData is deprecated. Use moment.localeData instead.",re);var bo=Math.abs,_o=br("ms"),xo=br("s"),wo=br("m"),So=br("h"),To=br("d"),ko=br("w"),Co=br("M"),Eo=br("Q"),Do=br("y"),Ao=wr("milliseconds"),Mo=wr("seconds"),Oo=wr("minutes"),Io=wr("hours"),Po=wr("days"),Lo=wr("months"),No=wr("years"),Ro=Math.round,Fo={ss:44,s:45,m:45,h:22,d:26,M:11},Ho=Math.abs,jo=Pe.prototype;return jo.isValid=Oe,jo.abs=ur,jo.add=dr,jo.subtract=hr,jo.as=yr,jo.asMilliseconds=_o,jo.asSeconds=xo,jo.asMinutes=wo,jo.asHours=So,jo.asDays=To,jo.asWeeks=ko,jo.asMonths=Co,jo.asQuarters=Eo,jo.asYears=Do,jo.valueOf=vr,jo._bubble=pr,jo.clone=_r,jo.get=xr,jo.milliseconds=Ao,jo.seconds=Mo,jo.minutes=Oo,jo.hours=Io,jo.days=Po,jo.weeks=Sr,jo.months=Lo,jo.years=No,jo.humanize=Dr,jo.toISOString=Mr,jo.toString=Mr,jo.toJSON=Mr,jo.locale=Sn,jo.localeData=Tn,jo.toIsoString=S("toIsoString() is deprecated. Please use toISOString() instead (notice the capitals)",Mr),jo.lang=ao,z("X",0,0,"unix"),z("x",0,0,"valueOf"),Y("x",si),Y("X",ci),Q("X",function(t,e,n){n._d=new Date(1e3*parseFloat(t,10))}),Q("x",function(t,e,n){n._d=new Date(_(t))}),u.version="2.24.0",t(Ce),u.fn=yo,u.min=De,u.max=Ae,u.now=Ji,u.utc=f,u.unix=Zn,u.months=ir,u.isDate=i,u.locale=te,u.invalid=r,u.duration=$e,u.isMoment=v,u.weekdays=ar,u.parseZone=Jn,u.localeData=re,u.isDuration=Le,u.monthsShort=or,u.weekdaysMin=lr,u.defineLocale=ee,u.updateLocale=ne,u.locales=ie,u.weekdaysShort=sr,u.normalizeUnits=R,u.relativeTimeRounding=Cr,u.relativeTimeThreshold=Er,u.calendarFormat=rn,u.prototype=yo,u.HTML5_FMT={DATETIME_LOCAL:"YYYY-MM-DDTHH:mm",DATETIME_LOCAL_SECONDS:"YYYY-MM-DDTHH:mm:ss",DATETIME_LOCAL_MS:"YYYY-MM-DDTHH:mm:ss.SSS",DATE:"YYYY-MM-DD",TIME:"HH:mm",TIME_SECONDS:"HH:mm:ss",TIME_MS:"HH:mm:ss.SSS",WEEK:"GGGG-[W]WW",MONTH:"YYYY-MM"},u},Wo.exports=t()}),zi={datetime:"MMM D, YYYY, h:mm:ss a",millisecond:"h:mm:ss.SSS a",second:"h:mm:ss a",minute:"h:mm a",hour:"hA",day:"MMM D",week:"ll",month:"MMM YYYY",quarter:"[Q]Q - YYYY",year:"YYYY"};Zr._date.override("function"==typeof Wi?{_id:"moment",formats:function(){return zi},parse:function(t,e){return"string"==typeof t&&"string"==typeof e?t=Wi(t,e):t instanceof Wi||(t=Wi(t)),t.isValid()?t.valueOf():null},format:function(t,e){return Wi(t).format(e)},add:function(t,e,n){return Wi(t).add(e,n).valueOf()},diff:function(t,e,n){return Wi(t).diff(Wi(e),n)},startOf:function(t,e,n){return t=Wi(t),"isoWeek"===e?t.isoWeekday(n).valueOf():t.startOf(e).valueOf()},endOf:function(t,e){return Wi(t).endOf(e).valueOf()},_create:function(t){return Wi(t)}}:{}),vn._set("global",{plugins:{filler:{propagate:!0}}});var Bi={dataset:function(t){var e=t.fill,n=t.chart,r=n.getDatasetMeta(e),i=r&&n.isDatasetVisible(e)&&r.dataset._children||[],o=i.length||0;return o?function(t,e){return e<o&&i[e]._view||null}:null},boundary:function(t){var n=t.boundary,e=n?n.x:null,r=n?n.y:null;return kn.isArray(n)?function(t,e){return n[e]}:function(t){return{x:null===e?t.x:e,y:null===r?t.y:r}}}},Vi={id:"filler",afterDatasetsUpdate:function(t,e){var n,r,i,o,a=(t.data.datasets||[]).length,s=e.propagate,l=[];for(r=0;r<a;++r)o=null,(i=(n=t.getDatasetMeta(r)).dataset)&&i._model&&i instanceof Qn.Line&&(o={visible:t.isDatasetVisible(r),fill:Le(i,r,a),chart:t,el:i}),n.$filler=o,l.push(o);for(r=0;r<a;++r)(o=l[r])&&(o.fill=He(l,r,s),o.boundary=Fe(o),o.mapper=je(o))},beforeDatasetsDraw:function(t){var e,n,r,i,o,a,s,l=t._getSortedVisibleDatasetMetas(),u=t.ctx;for(n=l.length-1;0<=n;--n)(e=l[n].$filler)&&e.visible&&(i=(r=e.el)._view,o=r._children||[],a=e.mapper,s=i.backgroundColor||vn.global.defaultColor,a&&s&&o.length&&(kn.canvas.clipArea(u,t.chartArea),Be(u,o,a,i,s,r._loop),kn.canvas.unclipArea(u)))}},qi=kn.rtl.getRtlAdapter,Ui=kn.noop,Yi=kn.valueOrDefault;vn._set("global",{legend:{display:!0,position:"top",align:"center",fullWidth:!0,reverse:!1,weight:1e3,onClick:function(t,e){var n=e.datasetIndex,r=this.chart,i=r.getDatasetMeta(n);i.hidden=null===i.hidden?!r.data.datasets[n].hidden:null,r.update()},onHover:null,onLeave:null,labels:{boxWidth:40,padding:10,generateLabels:function(n){var r=n.data.datasets,t=n.options.legend||{},i=t.labels&&t.labels.usePointStyle;return n._getSortedDatasetMetas().map(function(t){var e=t.controller.getStyle(i?0:undefined);return{text:r[t.index].label,fillStyle:e.backgroundColor,hidden:!n.isDatasetVisible(t.index),lineCap:e.borderCapStyle,lineDash:e.borderDash,lineDashOffset:e.borderDashOffset,lineJoin:e.borderJoinStyle,lineWidth:e.borderWidth,strokeStyle:e.borderColor,pointStyle:e.pointStyle,rotation:e.rotation,datasetIndex:t.index}},this)}}},legendCallback:function(t){var e,n,r,i=document.createElement("ul"),o=t.data.datasets;for(i.setAttribute("class",t.id+"-legend"),e=0,n=o.length;e<n;e++)(r=i.appendChild(document.createElement("li"))).appendChild(document.createElement("span")).style.backgroundColor=o[e].backgroundColor,o[e].label&&r.appendChild(document.createTextNode(o[e].label));return i.outerHTML}});var Gi=In.extend({initialize:function(t){var e=this;kn.extend(e,t),e.legendHitBoxes=[],e._hoveredItem=null,e.doughnutMode=!1},beforeUpdate:Ui,update:function(t,e,n){var r=this;return r.beforeUpdate(),r.maxWidth=t,r.maxHeight=e,r.margins=n,r.beforeSetDimensions(),r.setDimensions(),r.afterSetDimensions(),r.beforeBuildLabels(),r.buildLabels(),r.afterBuildLabels(),r.beforeFit(),r.fit(),r.afterFit(),r.afterUpdate(),r.minSize},afterUpdate:Ui,beforeSetDimensions:Ui,setDimensions:function(){var t=this;t.isHorizontal()?(t.width=t.maxWidth,t.left=0,t.right=t.width):(t.height=t.maxHeight,t.top=0,t.bottom=t.height),t.paddingLeft=0,t.paddingTop=0,t.paddingRight=0,t.paddingBottom=0,t.minSize={width:0,height:0}},afterSetDimensions:Ui,beforeBuildLabels:Ui,buildLabels:function(){var e=this,n=e.options.labels||{},t=kn.callback(n.generateLabels,[e.chart],e)||[];n.filter&&(t=t.filter(function(t){return n.filter(t,e.chart.data)})),e.options.reverse&&t.reverse(),e.legendItems=t},afterBuildLabels:Ui,beforeFit:Ui,fit:function(){var t=this,e=t.options,r=e.labels,n=e.display,i=t.ctx,o=kn.options._parseFont(r),a=o.size,s=t.legendHitBoxes=[],l=t.minSize,u=t.isHorizontal();if(u?(l.width=t.maxWidth,l.height=n?10:0):(l.width=n?10:0,l.height=t.maxHeight),n){if(i.font=o.string,u){var c=t.lineWidths=[0],d=0;i.textAlign="left",i.textBaseline="middle",kn.each(t.legendItems,function(t,e){var n=Ve(r,a)+a/2+i.measureText(t.text).width;(0===e||c[c.length-1]+n+2*r.padding>l.width)&&(d+=a+r.padding,c[c.length-(0<e?0:1)]=0),s[e]={left:0,top:0,width:n,height:a},c[c.length-1]+=n+r.padding}),l.height+=d}else{var h=r.padding,f=t.columnWidths=[],p=t.columnHeights=[],g=r.padding,m=0,y=0;kn.each(t.legendItems,function(t,e){var n=Ve(r,a)+a/2+i.measureText(t.text).width;0<e&&y+a+2*h>l.height&&(g+=m+r.padding,f.push(m),p.push(y),y=m=0),m=Math.max(m,n),y+=a+h,s[e]={left:0,top:0,width:n,height:a}}),g+=m,f.push(m),p.push(y),l.width+=g}t.width=l.width,t.height=l.height}else t.width=l.width=t.height=l.height=0},afterFit:Ui,isHorizontal:function(){return"top"===this.options.position||"bottom"===this.options.position},draw:function(){var s=this,n=s.options,l=n.labels,t=vn.global,u=t.defaultColor,c=t.elements.line,d=s.height,h=s.columnHeights,f=s.width,p=s.lineWidths;if(n.display){var g,m=qi(n.rtl,s.left,s.minSize.width),y=s.ctx,e=Yi(l.fontColor,t.defaultFontColor),r=kn.options._parseFont(l),v=r.size;y.textAlign=m.textAlign("left"),y.textBaseline="middle",y.lineWidth=.5,y.strokeStyle=e,y.fillStyle=e,y.font=r.string;var b=Ve(l,v),_=s.legendHitBoxes,x=function(t,e,n){if(!(isNaN(b)||b<=0)){y.save();var r=Yi(n.lineWidth,c.borderWidth);if(y.fillStyle=Yi(n.fillStyle,u),y.lineCap=Yi(n.lineCap,c.borderCapStyle),y.lineDashOffset=Yi(n.lineDashOffset,c.borderDashOffset),y.lineJoin=Yi(n.lineJoin,c.borderJoinStyle),y.lineWidth=r,y.strokeStyle=Yi(n.strokeStyle,u),y.setLineDash&&y.setLineDash(Yi(n.lineDash,c.borderDash)),l&&l.usePointStyle){var i=b*Math.SQRT2/2,o=m.xPlus(t,b/2),a=e+v/2;kn.canvas.drawPoint(y,n.pointStyle,i,o,a,n.rotation)}else y.fillRect(m.leftForLtr(t,b),e,b,v),0!==r&&y.strokeRect(m.leftForLtr(t,b),e,b,v);y.restore()}},w=function(t,e,n,r){var i=v/2,o=m.xPlus(t,b+i),a=e+i;y.fillText(n.text,o,a),n.hidden&&(y.beginPath(),y.lineWidth=2,y.moveTo(o,a),y.lineTo(m.xPlus(o,r),a),y.stroke())},S=function(t,e){switch(n.align){case"start":return l.padding;case"end":return t-e;default:return(t-e+l.padding)/2}},T=s.isHorizontal();g=T?{x:s.left+S(f,p[0]),y:s.top+l.padding,line:0}:{x:s.left+l.padding,y:s.top+S(d,h[0]),line:0},kn.rtl.overrideTextDirection(s.ctx,n.textDirection);var k=v+l.padding;kn.each(s.legendItems,function(t,e){var n=y.measureText(t.text).width,r=b+v/2+n,i=g.x,o=g.y;m.setWidth(s.minSize.width),T?0<e&&i+r+l.padding>s.left+s.minSize.width&&(o=g.y+=k,g.line++,i=g.x=s.left+S(f,p[g.line])):0<e&&o+k>s.top+s.minSize.height&&(i=g.x=i+s.columnWidths[g.line]+l.padding,g.line++,o=g.y=s.top+S(d,h[g.line]));var a=m.x(i);x(a,o,t),_[e].left=m.leftForLtr(a,_[e].width),_[e].top=o,w(a,o,t,n),T?g.x+=r+l.padding:g.y+=k}),kn.rtl.restoreTextDirection(s.ctx,n.textDirection)}},_getLegendItemAt:function(t,e){var n,r,i,o=this;if(t>=o.left&&t<=o.right&&e>=o.top&&e<=o.bottom)for(i=o.legendHitBoxes,n=0;n<i.length;++n)if(t>=(r=i[n]).left&&t<=r.left+r.width&&e>=r.top&&e<=r.top+r.height)return o.legendItems[n];return null},handleEvent:function(t){var e,n=this,r=n.options,i="mouseup"===t.type?"click":t.type;if("mousemove"===i){if(!r.onHover&&!r.onLeave)return}else{if("click"!==i)return;if(!r.onClick)return}e=n._getLegendItemAt(t.x,t.y),"click"===i?e&&r.onClick&&r.onClick.call(n,t["native"],e):(r.onLeave&&e!==n._hoveredItem&&(n._hoveredItem&&r.onLeave.call(n,t["native"],n._hoveredItem),n._hoveredItem=e),r.onHover&&e&&r.onHover.call(n,t["native"],e))}}),Ki={id:"legend",_element:Gi,beforeInit:function(t){var e=t.options.legend;e&&qe(t,e)},beforeUpdate:function(t){var e=t.options.legend,n=t.legend;e?(kn.mergeIf(e,vn.global.legend),n?(kr.configure(t,n,e),n.options=e):qe(t,e)):n&&(kr.removeBox(t,n),delete t.legend)},afterEvent:function(t,e){var n=t.legend;n&&n.handleEvent(e)}},Xi=kn.noop;vn._set("global",{title:{display:!1,fontStyle:"bold",fullWidth:!0,padding:10,position:"top",text:"",weight:2e3}});var Qi=In.extend({initialize:function(t){var e=this;kn.extend(e,t),e.legendHitBoxes=[]},beforeUpdate:Xi,update:function(t,e,n){var r=this;return r.beforeUpdate(),r.maxWidth=t,r.maxHeight=e,r.margins=n,r.beforeSetDimensions(),r.setDimensions(),r.afterSetDimensions(),r.beforeBuildLabels(),r.buildLabels(),r.afterBuildLabels(),r.beforeFit(),r.fit(),r.afterFit(),r.afterUpdate(),r.minSize},afterUpdate:Xi,beforeSetDimensions:Xi,setDimensions:function(){var t=this;t.isHorizontal()?(t.width=t.maxWidth,t.left=0,t.right=t.width):(t.height=t.maxHeight,t.top=0,t.bottom=t.height),t.paddingLeft=0,t.paddingTop=0,t.paddingRight=0,t.paddingBottom=0,t.minSize={width:0,height:0}},afterSetDimensions:Xi,beforeBuildLabels:Xi,buildLabels:Xi,afterBuildLabels:Xi,beforeFit:Xi,fit:function(){var t,e=this,n=e.options,r=e.minSize={},i=e.isHorizontal();n.display?(t=(kn.isArray(n.text)?n.text.length:1)*kn.options._parseFont(n).lineHeight+2*n.padding,e.width=r.width=i?e.maxWidth:t,e.height=r.height=i?t:e.maxHeight):e.width=r.width=e.height=r.height=0},afterFit:Xi,isHorizontal:function(){var t=this.options.position;return"top"===t||"bottom"===t},draw:function(){var t=this,e=t.ctx,n=t.options;if(n.display){var r,i,o,a=kn.options._parseFont(n),s=a.lineHeight,l=s/2+n.padding,u=0,c=t.top,d=t.left,h=t.bottom,f=t.right;e.fillStyle=kn.valueOrDefault(n.fontColor,vn.global.defaultFontColor),e.font=a.string,t.isHorizontal()?(i=d+(f-d)/2,o=c+l,r=f-d):(i="left"===n.position?d+l:f-l,o=c+(h-c)/2,r=h-c,u=Math.PI*("left"===n.position?-.5:.5)),e.save(),e.translate(i,o),e.rotate(u),e.textAlign="center",e.textBaseline="middle";var p=n.text;if(kn.isArray(p))for(var g=0,m=0;m<p.length;++m)e.fillText(p[m],0,g,r),g+=s;else e.fillText(p,0,0,r);e.restore()}}}),$i={},Zi=Vi,Ji=Ki,to={id:"title",_element:Qi,beforeInit:function(t){var e=t.options.title;e&&Ue(t,e)},beforeUpdate:function(t){var e=t.options.title,n=t.titleBlock;e?(kn.mergeIf(e,vn.global.title),n?(kr.configure(t,n,e),n.options=e):Ue(t,e)):n&&(kr.removeBox(t,n),delete t.titleBlock)}};for(var eo in $i.filler=Zi,$i.legend=Ji,$i.title=to,Qr.helpers=kn,$r(),Qr._adapters=Zr,Qr.Animation=Ln,Qr.animationService=Nn,Qr.controllers=wr,Qr.DatasetController=jn,Qr.defaults=vn,Qr.Element=In,Qr.elements=Qn,Qr.Interaction=Sr,Qr.layouts=kr,Qr.platform=jr,Qr.plugins=Wr,Qr.Scale=oi,Qr.scaleService=zr,Qr.Ticks=Jr,Qr.Tooltip=Gr,Qr.helpers.each(ji,function(t,e){Qr.scaleService.registerScaleType(e,t,t._defaults)}),$i)$i.hasOwnProperty(eo)&&Qr.plugins.register($i[eo]);Qr.platform.initialize();var no=Qr;return"undefined"!=typeof window&&(window.Chart=Qr),(Qr.Chart=Qr).Legend=$i.legend._element,Qr.Title=$i.title._element,Qr.pluginService=Qr.plugins,Qr.PluginBase=Qr.Element.extend({}),Qr.canvasHelpers=Qr.helpers.canvas,Qr.layoutService=Qr.layouts,Qr.LinearScaleBase=hi,Qr.helpers.each(["Bar","Bubble","Doughnut","Line","PolarArea","Radar","Scatter"],function(n){Qr[n]=function(t,e){return new Qr(t,Qr.helpers.merge(e||{},{type:n.charAt(0).toLowerCase()+n.slice(1)}))}}),no});