function _typeof2(n){"@babel/helpers - typeof";return _typeof2="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(n){return typeof n}:function(n){return n&&"function"==typeof Symbol&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},_typeof2(n)}function stopListSpinner(n){n?$("#stopListSpinner").removeClass("d-none"):$("#stopListSpinner").addClass("d-none")}function departuresSpinner(n){n?$("#departuresSpinner").removeClass("d-none"):$("#departuresSpinner").addClass("d-none")}function mapSpinner(n){n?$("#mapSpinner").removeClass("d-none"):$("#mapSpinner").addClass("d-none")}function isLoading(n){n?$("#departuresSpinner").removeClass("d-none"):$("#departuresSpinner").addClass("d-none")}function initializeMap(){mapSpinner(!0);$("#NexTripMap").length&&!mapInitialized?typeof require=="function"?require(["esri/map","esri/layers/FeatureLayer","dojo/domReady!"],function(n,t){var i,r;NexTripMap||(NexTripMap=new n("NexTripMap",{basemap:"streets",center:[-93.265,44.9778],zoom:12}),i=new t("https://mtgis.metc.state.mn.us/transit/rest/services/transit/TRIM/MapServer/4",{mode:t.MODE_ONDEMAND,outFields:["*"]}),NexTripMap.addLayer(i),r=new t("https://mtgis.metc.state.mn.us/transit/rest/services/transit/TRIM/MapServer/1",{mode:t.MODE_ONDEMAND,outFields:["*"]}),NexTripMap.addLayer(r),scalebar=new Scalebar({map:NexTripMap,scalebarUnit:"english"}),mapInitialized=!0);mapSpinner(!1)}):console.error("require is not available."):console.error("#NexTripMap element is not available.")}var version,AutocompleteAddress,TripPlan,ParkRideServices,StopServices,NexTrip,customDateTimePickers,Main,$jscomp;if(function(n,t){"use strict";typeof module=="object"&&typeof module.exports=="object"?module.exports=n.document?t(n,!0):function(n){if(!n.document)throw new Error("jQuery requires a window with a document");return t(n)}:t(n)}(typeof window!="undefined"?window:this,function(n,t){"use strict";function yr(n,t,i){i=i||f;var r,e,u=i.createElement("script");if(u.text=n,t)for(r in ie)e=t[r]||t.getAttribute&&t.getAttribute(r),e&&u.setAttribute(r,e);i.head.appendChild(u).parentNode.removeChild(u)}function it(n){return n==null?n+"":typeof n=="object"||typeof n=="function"?ti[ar.call(n)]||"object":typeof n}function ai(n){var t=!!n&&"length"in n&&n.length,i=it(n);return u(n)||tt(n)?!1:i==="array"||t===0||typeof t=="number"&&t>0&&t-1 in n}function l(n,t){return n.nodeName&&n.nodeName.toLowerCase()===t.toLowerCase()}function yi(n,t,r){return u(t)?i.grep(n,function(n,i){return!!t.call(n,i,n)!==r}):t.nodeType?i.grep(n,function(n){return n===t!==r}):typeof t!="string"?i.grep(n,function(n){return ni.call(t,n)>-1!==r}):i.filter(t,n,r)}function iu(n,t){while((n=n[t])&&n.nodeType!==1);return n}function ue(n){var t={};return i.each(n.match(a)||[],function(n,i){t[i]=!0}),t}function ut(n){return n}function ri(n){throw n;}function ru(n,t,i,r){var f;try{n&&u(f=n.promise)?f.call(n).done(t).fail(i):n&&u(f=n.then)?f.call(n,t,i):t.apply(undefined,[n].slice(r))}catch(n){i.apply(undefined,[n])}}function fi(){f.removeEventListener("DOMContentLoaded",fi);n.removeEventListener("load",fi);i.ready()}function oe(n,t){return t.toUpperCase()}function y(n){return n.replace(fe,"ms-").replace(ee,oe)}function yt(){this.expando=i.expando+yt.uid++}function ce(n){return n==="true"?!0:n==="false"?!1:n==="null"?null:n===+n+""?+n:se.test(n)?JSON.parse(n):n}function fu(n,t,i){var r;if(i===undefined&&n.nodeType===1)if(r="data-"+t.replace(he,"-$&").toLowerCase(),i=n.getAttribute(r),typeof i=="string"){try{i=ce(i)}catch(u){}o.set(n,t,i)}else i=undefined;return i}function ou(n,t,r,u){var s,h,c=20,l=u?function(){return u.cur()}:function(){return i.css(n,t,"")},o=l(),e=r&&r[3]||(i.cssNumber[t]?"":"px"),f=n.nodeType&&(i.cssNumber[t]||e!=="px"&&+o)&&pt.exec(i.css(n,t));if(f&&f[3]!==e){for(o=o/2,e=e||f[3],f=+o||1;c--;)i.style(n,t,f+e),(1-h)*(1-(h=l()/o||.5))<=0&&(c=0),f=f/h;f=f*2;i.style(n,t,f+e);r=r||[]}return r&&(f=+f||+o||0,s=r[1]?f+(r[1]+1)*r[2]:+r[2],u&&(u.unit=e,u.start=f,u.end=s)),s}function ae(n){var r,f=n.ownerDocument,u=n.nodeName,t=wi[u];return t?t:(r=f.body.appendChild(f.createElement(u)),t=i.css(r,"display"),r.parentNode.removeChild(r),t==="none"&&(t="block"),wi[u]=t,t)}function et(n,t){for(var e,u,f=[],i=0,o=n.length;i<o;i++)(u=n[i],u.style)&&(e=u.style.display,t?(e==="none"&&(f[i]=r.get(u,"display")||null,f[i]||(u.style.display="")),u.style.display===""&&bt(u)&&(f[i]=ae(u))):e!=="none"&&(f[i]="none",r.set(u,"display",e)));for(i=0;i<o;i++)f[i]!=null&&(n[i].style.display=f[i]);return n}function s(n,t){var r;return(r=typeof n.getElementsByTagName!="undefined"?n.getElementsByTagName(t||"*"):typeof n.querySelectorAll!="undefined"?n.querySelectorAll(t||"*"):[],t===undefined||t&&l(n,t))?i.merge([n],r):r}function bi(n,t){for(var i=0,u=n.length;i<u;i++)r.set(n[i],"globalEval",!t||r.get(t[i],"globalEval"))}function lu(n,t,r,u,f){for(var e,o,p,a,w,v,h=t.createDocumentFragment(),y=[],l=0,b=n.length;l<b;l++)if(e=n[l],e||e===0)if(it(e)==="object")i.merge(y,e.nodeType?[e]:e);else if(cu.test(e)){for(o=o||h.appendChild(t.createElement("div")),p=(su.exec(e)||["",""])[1].toLowerCase(),a=c[p]||c._default,o.innerHTML=a[1]+i.htmlPrefilter(e)+a[2],v=a[0];v--;)o=o.lastChild;i.merge(y,o.childNodes);o=h.firstChild;o.textContent=""}else y.push(t.createTextNode(e));for(h.textContent="",l=0;e=y[l++];){if(u&&i.inArray(e,u)>-1){f&&f.push(e);continue}if(w=ft(e),o=s(h.appendChild(e),"script"),w&&bi(o),r)for(v=0;e=o[v++];)hu.test(e.type||"")&&r.push(e)}return h}function ot(){return!0}function st(){return!1}function pe(n,t){return n===we()==(t==="focus")}function we(){try{return f.activeElement}catch(n){}}function ki(n,t,r,u,f,e){var o,s;if(typeof t=="object"){typeof r!="string"&&(u=u||r,r=undefined);for(s in t)ki(n,s,r,u,t[s],e);return n}if(u==null&&f==null?(f=r,u=r=undefined):f==null&&(typeof r=="string"?(f=u,u=undefined):(f=u,u=r,r=undefined)),f===!1)f=st;else if(!f)return n;return e===1&&(o=f,f=function(n){return i().off(n),o.apply(this,arguments)},f.guid=o.guid||(o.guid=i.guid++)),n.each(function(){i.event.add(this,t,f,u,r)})}function ei(n,t,u){if(!u){r.get(n,t)===undefined&&i.event.add(n,t,ot);return}r.set(n,t,!1);i.event.add(n,t,{namespace:!1,handler:function(n){var o,e,f=r.get(this,t);if(n.isTrigger&1&&this[t]){if(f.length)(i.event.special[t]||{}).delegateType&&n.stopPropagation();else if(f=b.call(arguments),r.set(this,t,f),o=u(this,t),this[t](),e=r.get(this,t),f!==e||o?r.set(this,t,!1):e={},f!==e)return n.stopImmediatePropagation(),n.preventDefault(),e.value}else f.length&&(r.set(this,t,{value:i.event.trigger(i.extend(f[0],i.Event.prototype),f.slice(1),this)}),n.stopImmediatePropagation())}})}function vu(n,t){return l(n,"table")&&l(t.nodeType!==11?t:t.firstChild,"tr")?i(n).children("tbody")[0]||n:n}function no(n){return n.type=(n.getAttribute("type")!==null)+"/"+n.type,n}function to(n){return(n.type||"").slice(0,5)==="true/"?n.type=n.type.slice(5):n.removeAttribute("type"),n}function yu(n,t){var f,c,e,s,h,l,a,u;if(t.nodeType===1){if(r.hasData(n)&&(s=r.access(n),h=r.set(t,s),u=s.events,u)){delete h.handle;h.events={};for(e in u)for(f=0,c=u[e].length;f<c;f++)i.event.add(t,e,u[e][f])}o.hasData(n)&&(l=o.access(n),a=i.extend({},l),o.set(t,a))}}function io(n,t){var i=t.nodeName.toLowerCase();i==="input"&&kt.test(n.type)?t.checked=n.checked:(i==="input"||i==="textarea")&&(t.defaultValue=n.defaultValue)}function ht(n,t,f,o){t=lr.apply([],t);var a,w,l,v,h,b,c=0,y=n.length,d=y-1,p=t[0],k=u(p);if(k||y>1&&typeof p=="string"&&!e.checkClone&&de.test(p))return n.each(function(i){var r=n.eq(i);k&&(t[0]=p.call(this,i,r.html()));ht(r,t,f,o)});if(y&&(a=lu(t,n[0].ownerDocument,!1,n,o),w=a.firstChild,a.childNodes.length===1&&(a=w),w||o)){for(l=i.map(s(a,"script"),no),v=l.length;c<y;c++)h=a,c!==d&&(h=i.clone(h,!0,!0),v&&i.merge(l,s(h,"script"))),f.call(n[c],h,c);if(v)for(b=l[l.length-1].ownerDocument,i.map(l,to),c=0;c<v;c++)h=l[c],hu.test(h.type||"")&&!r.access(h,"globalEval")&&i.contains(b,h)&&(h.src&&(h.type||"").toLowerCase()!=="module"?i._evalUrl&&!h.noModule&&i._evalUrl(h.src,{nonce:h.nonce||h.getAttribute("nonce")}):yr(h.textContent.replace(ge,""),h,b))}return n}function pu(n,t,r){for(var u,e=t?i.filter(t,n):n,f=0;(u=e[f])!=null;f++)r||u.nodeType!==1||i.cleanData(s(u)),u.parentNode&&(r&&ft(u)&&bi(s(u,"script")),u.parentNode.removeChild(u));return n}function dt(n,t,r){var o,s,h,u,f=n.style;return r=r||oi(n),r&&(u=r.getPropertyValue(t)||r[t],u!==""||ft(n)||(u=i.style(n,t)),!e.pixelBoxStyles()&&di.test(u)&&ro.test(t)&&(o=f.width,s=f.minWidth,h=f.maxWidth,f.minWidth=f.maxWidth=f.width=u,u=r.width,f.width=o,f.minWidth=s,f.maxWidth=h)),u!==undefined?u+"":u}function wu(n,t){return{get:function(){if(n()){delete this.get;return}return(this.get=t).apply(this,arguments)}}}function uo(n){for(var i=n[0].toUpperCase()+n.slice(1),t=bu.length;t--;)if(n=bu[t]+i,n in ku)return n}function gi(n){var t=i.cssProps[n]||du[n];return t?t:n in ku?n:du[n]=uo(n)||n}function tf(n,t,i){var r=pt.exec(t);return r?Math.max(0,r[2]-(i||0))+(r[3]||"px"):t}function nr(n,t,r,u,f,e){var o=t==="width"?1:0,h=0,s=0;if(r===(u?"border":"content"))return 0;for(;o<4;o+=2)r==="margin"&&(s+=i.css(n,r+w[o],!0,f)),u?(r==="content"&&(s-=i.css(n,"padding"+w[o],!0,f)),r!=="margin"&&(s-=i.css(n,"border"+w[o]+"Width",!0,f))):(s+=i.css(n,"padding"+w[o],!0,f),r!=="padding"?s+=i.css(n,"border"+w[o]+"Width",!0,f):h+=i.css(n,"border"+w[o]+"Width",!0,f));return!u&&e>=0&&(s+=Math.max(0,Math.ceil(n["offset"+t[0].toUpperCase()+t.slice(1)]-e-s-h-.5))||0),s}function rf(n,t,r){var f=oi(n),c=!e.boxSizingReliable()||r,o=c&&i.css(n,"boxSizing",!1,f)==="border-box",s=o,u=dt(n,t,f),h="offset"+t[0].toUpperCase()+t.slice(1);if(di.test(u)){if(!r)return u;u="auto"}return(!e.boxSizingReliable()&&o||u==="auto"||!parseFloat(u)&&i.css(n,"display",!1,f)==="inline")&&n.getClientRects().length&&(o=i.css(n,"boxSizing",!1,f)==="border-box",s=h in n,s&&(u=n[h])),u=parseFloat(u)||0,u+nr(n,t,r||(o?"border":"content"),s,f,u)+"px"}function h(n,t,i,r,u){return new h.prototype.init(n,t,i,r,u)}function tr(){si&&(f.hidden===!1&&n.requestAnimationFrame?n.requestAnimationFrame(tr):n.setTimeout(tr,i.fx.interval),i.fx.tick())}function ef(){return n.setTimeout(function(){ct=undefined}),ct=Date.now()}function hi(n,t){var r,u=0,i={height:n};for(t=t?1:0;u<4;u+=2-t)r=w[u],i["margin"+r]=i["padding"+r]=n;return t&&(i.opacity=i.width=n),i}function of(n,t,i){for(var u,f=(v.tweeners[t]||[]).concat(v.tweeners["*"]),r=0,e=f.length;r<e;r++)if(u=f[r].call(i,t,n))return u}function oo(n,t,u){var f,y,w,c,b,s,o,l,k="width"in t||"height"in t,v=this,p={},h=n.style,a=n.nodeType&&bt(n),e=r.get(n,"fxshow");u.queue||(c=i._queueHooks(n,"fx"),c.unqueued==null&&(c.unqueued=0,b=c.empty.fire,c.empty.fire=function(){c.unqueued||b()}),c.unqueued++,v.always(function(){v.always(function(){c.unqueued--;i.queue(n,"fx").length||c.empty.fire()})}));for(f in t)if(y=t[f],uf.test(y)){if(delete t[f],w=w||y==="toggle",y===(a?"hide":"show"))if(y==="show"&&e&&e[f]!==undefined)a=!0;else continue;p[f]=e&&e[f]||i.style(n,f)}if(s=!i.isEmptyObject(t),s||!i.isEmptyObject(p)){k&&n.nodeType===1&&(u.overflow=[h.overflow,h.overflowX,h.overflowY],o=e&&e.display,o==null&&(o=r.get(n,"display")),l=i.css(n,"display"),l==="none"&&(o?l=o:(et([n],!0),o=n.style.display||o,l=i.css(n,"display"),et([n]))),(l==="inline"||l==="inline-block"&&o!=null)&&i.css(n,"float")==="none"&&(s||(v.done(function(){h.display=o}),o==null&&(l=h.display,o=l==="none"?"":l)),h.display="inline-block"));u.overflow&&(h.overflow="hidden",v.always(function(){h.overflow=u.overflow[0];h.overflowX=u.overflow[1];h.overflowY=u.overflow[2]}));s=!1;for(f in p)s||(e?"hidden"in e&&(a=e.hidden):e=r.access(n,"fxshow",{display:o}),w&&(e.hidden=!a),a&&et([n],!0),v.done(function(){a||et([n]);r.remove(n,"fxshow");for(f in p)i.style(n,f,p[f])})),s=of(a?e[f]:0,f,v),f in e||(e[f]=s.start,a&&(s.end=s.start,s.start=0))}}function so(n,t){var r,f,e,u,o;for(r in n)if(f=y(r),e=t[f],u=n[r],Array.isArray(u)&&(e=u[1],u=n[r]=u[0]),r!==f&&(n[f]=u,delete n[r]),o=i.cssHooks[f],o&&"expand"in o){u=o.expand(u);delete n[f];for(r in u)r in n||(n[r]=u[r],t[r]=e)}else t[f]=e}function v(n,t,r){var o,s,h=0,a=v.prefilters.length,e=i.Deferred().always(function(){delete l.elem}),l=function(){if(s)return!1;for(var o=ct||ef(),t=Math.max(0,f.startTime+f.duration-o),h=t/f.duration||0,i=1-h,r=0,u=f.tweens.length;r<u;r++)f.tweens[r].run(i);return(e.notifyWith(n,[f,i,t]),i<1&&u)?t:(u||e.notifyWith(n,[f,1,0]),e.resolveWith(n,[f]),!1)},f=e.promise({elem:n,props:i.extend({},t),opts:i.extend(!0,{specialEasing:{},easing:i.easing._default},r),originalProperties:t,originalOptions:r,startTime:ct||ef(),duration:r.duration,tweens:[],createTween:function(t,r){var u=i.Tween(n,f.opts,t,r,f.opts.specialEasing[t]||f.opts.easing);return f.tweens.push(u),u},stop:function(t){var i=0,r=t?f.tweens.length:0;if(s)return this;for(s=!0;i<r;i++)f.tweens[i].run(1);return t?(e.notifyWith(n,[f,1,0]),e.resolveWith(n,[f,t])):e.rejectWith(n,[f,t]),this}}),c=f.props;for(so(c,f.opts.specialEasing);h<a;h++)if(o=v.prefilters[h].call(f,n,c,f.opts),o)return u(o.stop)&&(i._queueHooks(f.elem,f.opts.queue).stop=o.stop.bind(o)),o;return i.map(c,of,f),u(f.opts.start)&&f.opts.start.call(n,f),f.progress(f.opts.progress).done(f.opts.done,f.opts.complete).fail(f.opts.fail).always(f.opts.always),i.fx.timer(i.extend(l,{elem:n,anim:f,queue:f.opts.queue})),f}function g(n){var t=n.match(a)||[];return t.join(" ")}function nt(n){return n.getAttribute&&n.getAttribute("class")||""}function ir(n){return Array.isArray(n)?n:typeof n=="string"?n.match(a)||[]:[]}function er(n,t,r,u){var f;if(Array.isArray(t))i.each(t,function(t,i){r||ho.test(n)?u(n,i):er(n+"["+(typeof i=="object"&&i!=null?t:"")+"]",i,r,u)});else if(r||it(t)!=="object")u(n,t);else for(f in t)er(n+"["+f+"]",t[f],r,u)}function wf(n){return function(t,i){typeof t!="string"&&(i=t,t="*");var r,f=0,e=t.toLowerCase().match(a)||[];if(u(i))while(r=e[f++])r[0]==="+"?(r=r.slice(1)||"*",(n[r]=n[r]||[]).unshift(i)):(n[r]=n[r]||[]).push(i)}}function bf(n,t,r,u){function e(s){var h;return f[s]=!0,i.each(n[s]||[],function(n,i){var s=i(t,r,u);if(typeof s!="string"||o||f[s]){if(o)return!(h=s)}else return t.dataTypes.unshift(s),e(s),!1}),h}var f={},o=n===or;return e(t.dataTypes[0])||!f["*"]&&e("*")}function hr(n,t){var r,u,f=i.ajaxSettings.flatOptions||{};for(r in t)t[r]!==undefined&&((f[r]?n:u||(u={}))[r]=t[r]);return u&&i.extend(!0,n,u),n}function ko(n,t,i){for(var e,u,f,o,s=n.contents,r=n.dataTypes;r[0]==="*";)r.shift(),e===undefined&&(e=n.mimeType||t.getResponseHeader("Content-Type"));if(e)for(u in s)if(s[u]&&s[u].test(e)){r.unshift(u);break}if(r[0]in i)f=r[0];else{for(u in i){if(!r[0]||n.converters[u+" "+r[0]]){f=u;break}o||(o=u)}f=f||o}if(f)return f!==r[0]&&r.unshift(f),i[f]}function go(n,t,i,r){var h,u,f,s,e,o={},c=n.dataTypes.slice();if(c[1])for(f in n.converters)o[f.toLowerCase()]=n.converters[f];for(u=c.shift();u;)if(n.responseFields[u]&&(i[n.responseFields[u]]=t),!e&&r&&n.dataFilter&&(t=n.dataFilter(t,n.dataType)),e=u,u=c.shift(),u)if(u==="*")u=e;else if(e!=="*"&&e!==u){if(f=o[e+" "+u]||o["* "+u],!f)for(h in o)if(s=h.split(" "),s[1]===u&&(f=o[e+" "+s[0]]||o["* "+s[0]],f)){f===!0?f=o[h]:o[h]!==!0&&(u=s[0],c.unshift(s[1]));break}if(f!==!0)if(f&&n.throws)t=f(t);else try{t=f(t)}catch(l){return{state:"parsererror",error:f?l:"No conversion from "+e+" to "+u}}}return{state:"success",data:t}}var d=[],f=n.document,ne=Object.getPrototypeOf,b=d.slice,lr=d.concat,li=d.push,ni=d.indexOf,ti={},ar=ti.toString,ii=ti.hasOwnProperty,vr=ii.toString,te=vr.call(Object),e={},u=function(n){return typeof n=="function"&&typeof n.nodeType!="number"},tt=function(n){return n!=null&&n===n.window},ie={type:!0,src:!0,nonce:!0,noModule:!0},pr="3.4.1",i=function(n,t){return new i.fn.init(n,t)},re=/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,k,vi,kr,dr,gr,nu,tu,a,uu,ui,vt,bt,pi,wi,cu,ct,si,uf,ff,sf,lt,hf,cf,lf,rr,ur,kf,at,cr,ci,df,gf;i.fn=i.prototype={jquery:pr,constructor:i,length:0,toArray:function(){return b.call(this)},get:function(n){return n==null?b.call(this):n<0?this[n+this.length]:this[n]},pushStack:function(n){var t=i.merge(this.constructor(),n);return t.prevObject=this,t},each:function(n){return i.each(this,n)},map:function(n){return this.pushStack(i.map(this,function(t,i){return n.call(t,i,t)}))},slice:function(){return this.pushStack(b.apply(this,arguments))},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},eq:function(n){var i=this.length,t=+n+(n<0?i:0);return this.pushStack(t>=0&&t<i?[this[t]]:[])},end:function(){return this.prevObject||this.constructor()},push:li,sort:d.sort,splice:d.splice};i.extend=i.fn.extend=function(){var s,f,e,t,o,c,n=arguments[0]||{},r=1,l=arguments.length,h=!1;for(typeof n=="boolean"&&(h=n,n=arguments[r]||{},r++),typeof n=="object"||u(n)||(n={}),r===l&&(n=this,r--);r<l;r++)if((s=arguments[r])!=null)for(f in s)(t=s[f],f!=="__proto__"&&n!==t)&&(h&&t&&(i.isPlainObject(t)||(o=Array.isArray(t)))?(e=n[f],c=o&&!Array.isArray(e)?[]:o||i.isPlainObject(e)?e:{},o=!1,n[f]=i.extend(h,c,t)):t!==undefined&&(n[f]=t));return n};i.extend({expando:"jQuery"+(pr+Math.random()).replace(/\D/g,""),isReady:!0,error:function(n){throw new Error(n);},noop:function(){},isPlainObject:function(n){var t,i;return!n||ar.call(n)!=="[object Object]"?!1:(t=ne(n),!t)?!0:(i=ii.call(t,"constructor")&&t.constructor,typeof i=="function"&&vr.call(i)===te)},isEmptyObject:function(n){for(var t in n)return!1;return!0},globalEval:function(n,t){yr(n,{nonce:t&&t.nonce})},each:function(n,t){var r,i=0;if(ai(n)){for(r=n.length;i<r;i++)if(t.call(n[i],i,n[i])===!1)break}else for(i in n)if(t.call(n[i],i,n[i])===!1)break;return n},trim:function(n){return n==null?"":(n+"").replace(re,"")},makeArray:function(n,t){var r=t||[];return n!=null&&(ai(Object(n))?i.merge(r,typeof n=="string"?[n]:n):li.call(r,n)),r},inArray:function(n,t,i){return t==null?-1:ni.call(t,n,i)},merge:function(n,t){for(var u=+t.length,i=0,r=n.length;i<u;i++)n[r++]=t[i];return n.length=r,n},grep:function(n,t,i){for(var u,f=[],r=0,e=n.length,o=!i;r<e;r++)u=!t(n[r],r),u!==o&&f.push(n[r]);return f},map:function(n,t,i){var e,u,r=0,f=[];if(ai(n))for(e=n.length;r<e;r++)u=t(n[r],r,i),u!=null&&f.push(u);else for(r in n)u=t(n[r],r,i),u!=null&&f.push(u);return lr.apply([],f)},guid:1,support:e});typeof Symbol=="function"&&(i.fn[Symbol.iterator]=d[Symbol.iterator]);i.each("Boolean Number String Function Array Date RegExp Object Error Symbol".split(" "),function(n,t){ti["[object "+t+"]"]=t.toLowerCase()});k=function(n){function u(n,t,r,u){var s,w,l,v,d,y,g,p=t&&t.ownerDocument,a=t?t.nodeType:9;if(r=r||[],typeof n!="string"||!n||a!==1&&a!==9&&a!==11)return r;if(!u&&((t?t.ownerDocument||t:c)!==i&&b(t),t=t||i,h)){if(a!==11&&(d=ar.exec(n)))if(s=d[1]){if(a===9)if(l=t.getElementById(s)){if(l.id===s)return r.push(l),r}else return r;else if(p&&(l=p.getElementById(s))&&et(t,l)&&l.id===s)return r.push(l),r}else{if(d[2])return k.apply(r,t.getElementsByTagName(n)),r;if((s=d[3])&&e.getElementsByClassName&&t.getElementsByClassName)return k.apply(r,t.getElementsByClassName(s)),r}if(e.qsa&&!lt[n+" "]&&(!o||!o.test(n))&&(a!==1||t.nodeName.toLowerCase()!=="object")){if(g=n,p=t,a===1&&er.test(n)){for((v=t.getAttribute("id"))?v=v.replace(yi,pi):t.setAttribute("id",v=f),y=ft(n),w=y.length;w--;)y[w]="#"+v+" "+pt(y[w]);g=y.join(",");p=ti.test(n)&&ri(t.parentNode)||t}try{return k.apply(r,p.querySelectorAll(g)),r}catch(nt){lt(n,!0)}finally{v===f&&t.removeAttribute("id")}}}return si(n.replace(at,"$1"),t,r,u)}function yt(){function n(r,u){return i.push(r+" ")>t.cacheLength&&delete n[i.shift()],n[r+" "]=u}var i=[];return n}function l(n){return n[f]=!0,n}function a(n){var t=i.createElement("fieldset");try{return!!n(t)}catch(r){return!1}finally{t.parentNode&&t.parentNode.removeChild(t);t=null}}function ii(n,i){for(var r=n.split("|"),u=r.length;u--;)t.attrHandle[r[u]]=i}function bi(n,t){var i=t&&n,r=i&&n.nodeType===1&&t.nodeType===1&&n.sourceIndex-t.sourceIndex;if(r)return r;if(i)while(i=i.nextSibling)if(i===t)return-1;return n?1:-1}function yr(n){return function(t){var i=t.nodeName.toLowerCase();return i==="input"&&t.type===n}}function pr(n){return function(t){var i=t.nodeName.toLowerCase();return(i==="input"||i==="button")&&t.type===n}}function ki(n){return function(t){return"form"in t?t.parentNode&&t.disabled===!1?"label"in t?"label"in t.parentNode?t.parentNode.disabled===n:t.disabled===n:t.isDisabled===n||t.isDisabled!==!n&&vr(t)===n:t.disabled===n:"label"in t?t.disabled===n:!1}}function it(n){return l(function(t){return t=+t,l(function(i,r){for(var u,f=n([],i.length,t),e=f.length;e--;)i[u=f[e]]&&(i[u]=!(r[u]=i[u]))})})}function ri(n){return n&&typeof n.getElementsByTagName!="undefined"&&n}function di(){}function pt(n){for(var t=0,r=n.length,i="";t<r;t++)i+=n[t].value;return i}function wt(n,t,i){var r=t.dir,u=t.next,e=u||r,o=i&&e==="parentNode",s=gi++;return t.first?function(t,i,u){while(t=t[r])if(t.nodeType===1||o)return n(t,i,u);return!1}:function(t,i,h){var c,l,a,y=[v,s];if(h){while(t=t[r])if((t.nodeType===1||o)&&n(t,i,h))return!0}else while(t=t[r])if(t.nodeType===1||o)if(a=t[f]||(t[f]={}),l=a[t.uniqueID]||(a[t.uniqueID]={}),u&&u===t.nodeName.toLowerCase())t=t[r]||t;else{if((c=l[e])&&c[0]===v&&c[1]===s)return y[2]=c[2];if(l[e]=y,y[2]=n(t,i,h))return!0}return!1}}function ui(n){return n.length>1?function(t,i,r){for(var u=n.length;u--;)if(!n[u](t,i,r))return!1;return!0}:n[0]}function wr(n,t,i){for(var r=0,f=t.length;r<f;r++)u(n,t[r],i);return i}function bt(n,t,i,r,u){for(var e,o=[],f=0,s=n.length,h=t!=null;f<s;f++)(e=n[f])&&(!i||i(e,r,u))&&(o.push(e),h&&t.push(f));return o}function fi(n,t,i,r,u,e){return r&&!r[f]&&(r=fi(r)),u&&!u[f]&&(u=fi(u,e)),l(function(f,e,o,s){var l,c,a,p=[],y=[],w=e.length,b=f||wr(t||"*",o.nodeType?[o]:o,[]),v=n&&(f||!t)?bt(b,p,n,o,s):b,h=i?u||(f?n:w||r)?[]:e:v;if(i&&i(v,h,o,s),r)for(l=bt(h,y),r(l,[],o,s),c=l.length;c--;)(a=l[c])&&(h[y[c]]=!(v[y[c]]=a));if(f){if(u||n){if(u){for(l=[],c=h.length;c--;)(a=h[c])&&l.push(v[c]=a);u(null,h=[],l,s)}for(c=h.length;c--;)(a=h[c])&&(l=u?nt(f,a):p[c])>-1&&(f[l]=!(e[l]=a))}}else h=bt(h===e?h.splice(w,h.length):h),u?u(null,e,h,s):k.apply(e,h)})}function ei(n){for(var o,u,r,s=n.length,h=t.relative[n[0].type],c=h||t.relative[" "],i=h?1:0,l=wt(function(n){return n===o},c,!0),a=wt(function(n){return nt(o,n)>-1},c,!0),e=[function(n,t,i){var r=!h&&(i||t!==ht)||((o=t).nodeType?l(n,t,i):a(n,t,i));return o=null,r}];i<s;i++)if(u=t.relative[n[i].type])e=[wt(ui(e),u)];else{if(u=t.filter[n[i].type].apply(null,n[i].matches),u[f]){for(r=++i;r<s;r++)if(t.relative[n[r].type])break;return fi(i>1&&ui(e),i>1&&pt(n.slice(0,i-1).concat({value:n[i-2].type===" "?"*":""})).replace(at,"$1"),u,i<r&&ei(n.slice(i,r)),r<s&&ei(n=n.slice(r)),r<s&&pt(n))}e.push(u)}return ui(e)}function br(n,r){var f=r.length>0,e=n.length>0,o=function(o,s,c,l,a){var y,nt,d,g=0,p="0",tt=o&&[],w=[],it=ht,rt=o||e&&t.find.TAG("*",a),ut=v+=it==null?1:Math.random()||.1,ft=rt.length;for(a&&(ht=s===i||s||a);p!==ft&&(y=rt[p])!=null;p++){if(e&&y){for(nt=0,s||y.ownerDocument===i||(b(y),c=!h);d=n[nt++];)if(d(y,s||i,c)){l.push(y);break}a&&(v=ut)}f&&((y=!d&&y)&&g--,o&&tt.push(y))}if(g+=p,f&&p!==g){for(nt=0;d=r[nt++];)d(tt,w,s,c);if(o){if(g>0)while(p--)tt[p]||w[p]||(w[p]=tr.call(l));w=bt(w)}k.apply(l,w);a&&!o&&w.length>0&&g+r.length>1&&u.uniqueSort(l)}return a&&(v=ut,ht=it),tt};return f?l(o):o}var rt,e,t,st,oi,ft,kt,si,ht,w,ut,b,i,s,h,o,d,ct,et,f="sizzle"+1*new Date,c=n.document,v=0,gi=0,hi=yt(),ci=yt(),li=yt(),lt=yt(),dt=function(n,t){return n===t&&(ut=!0),0},nr={}.hasOwnProperty,g=[],tr=g.pop,ir=g.push,k=g.push,ai=g.slice,nt=function(n,t){for(var i=0,r=n.length;i<r;i++)if(n[i]===t)return i;return-1},gt="checked|selected|async|autofocus|autoplay|controls|defer|disabled|hidden|ismap|loop|multiple|open|readonly|required|scoped",r="[\\x20\\t\\r\\n\\f]",tt="(?:\\\\.|[\\w-]|[^\0-\\xa0])+",vi="\\["+r+"*("+tt+")(?:"+r+"*([*^$|!~]?=)"+r+"*(?:'((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\"|("+tt+"))|)"+r+"*\\]",ni=":("+tt+")(?:\\((('((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\")|((?:\\\\.|[^\\\\()[\\]]|"+vi+")*)|.*)\\)|)",rr=new RegExp(r+"+","g"),at=new RegExp("^"+r+"+|((?:^|[^\\\\])(?:\\\\.)*)"+r+"+$","g"),ur=new RegExp("^"+r+"*,"+r+"*"),fr=new RegExp("^"+r+"*([>+~]|"+r+")"+r+"*"),er=new RegExp(r+"|>"),or=new RegExp(ni),sr=new RegExp("^"+tt+"$"),vt={ID:new RegExp("^#("+tt+")"),CLASS:new RegExp("^\\.("+tt+")"),TAG:new RegExp("^("+tt+"|[*])"),ATTR:new RegExp("^"+vi),PSEUDO:new RegExp("^"+ni),CHILD:new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+r+"*(even|odd|(([+-]|)(\\d*)n|)"+r+"*(?:([+-]|)"+r+"*(\\d+)|))"+r+"*\\)|)","i"),bool:new RegExp("^(?:"+gt+")$","i"),needsContext:new RegExp("^"+r+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+r+"*((?:-\\d)?\\d*)"+r+"*\\)|)(?=[^-]|$)","i")},hr=/HTML$/i,cr=/^(?:input|select|textarea|button)$/i,lr=/^h\d$/i,ot=/^[^{]+\{\s*\[native \w/,ar=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,ti=/[+~]/,y=new RegExp("\\\\([\\da-f]{1,6}"+r+"?|("+r+")|.)","ig"),p=function(n,t,i){var r="0x"+t-65536;return r!==r||i?t:r<0?String.fromCharCode(r+65536):String.fromCharCode(r>>10|55296,r&1023|56320)},yi=/([\0-\x1f\x7f]|^-?\d)|^-$|[^\0-\x1f\x7f-\uFFFF\w-]/g,pi=function(n,t){return t?n==="\0"?"�":n.slice(0,-1)+"\\"+n.charCodeAt(n.length-1).toString(16)+" ":"\\"+n},wi=function(){b()},vr=wt(function(n){return n.disabled===!0&&n.nodeName.toLowerCase()==="fieldset"},{dir:"parentNode",next:"legend"});try{k.apply(g=ai.call(c.childNodes),c.childNodes);g[c.childNodes.length].nodeType}catch(kr){k={apply:g.length?function(n,t){ir.apply(n,ai.call(t))}:function(n,t){for(var i=n.length,r=0;n[i++]=t[r++];);n.length=i-1}}}e=u.support={};oi=u.isXML=function(n){var i=n.namespaceURI,t=(n.ownerDocument||n).documentElement;return!hr.test(i||t&&t.nodeName||"HTML")};b=u.setDocument=function(n){var v,u,l=n?n.ownerDocument||n:c;return l===i||l.nodeType!==9||!l.documentElement?i:(i=l,s=i.documentElement,h=!oi(i),c!==i&&(u=i.defaultView)&&u.top!==u&&(u.addEventListener?u.addEventListener("unload",wi,!1):u.attachEvent&&u.attachEvent("onunload",wi)),e.attributes=a(function(n){return n.className="i",!n.getAttribute("className")}),e.getElementsByTagName=a(function(n){return n.appendChild(i.createComment("")),!n.getElementsByTagName("*").length}),e.getElementsByClassName=ot.test(i.getElementsByClassName),e.getById=a(function(n){return s.appendChild(n).id=f,!i.getElementsByName||!i.getElementsByName(f).length}),e.getById?(t.filter.ID=function(n){var t=n.replace(y,p);return function(n){return n.getAttribute("id")===t}},t.find.ID=function(n,t){if(typeof t.getElementById!="undefined"&&h){var i=t.getElementById(n);return i?[i]:[]}}):(t.filter.ID=function(n){var t=n.replace(y,p);return function(n){var i=typeof n.getAttributeNode!="undefined"&&n.getAttributeNode("id");return i&&i.value===t}},t.find.ID=function(n,t){if(typeof t.getElementById!="undefined"&&h){var i,u,f,r=t.getElementById(n);if(r){if(i=r.getAttributeNode("id"),i&&i.value===n)return[r];for(f=t.getElementsByName(n),u=0;r=f[u++];)if(i=r.getAttributeNode("id"),i&&i.value===n)return[r]}return[]}}),t.find.TAG=e.getElementsByTagName?function(n,t){return typeof t.getElementsByTagName!="undefined"?t.getElementsByTagName(n):e.qsa?t.querySelectorAll(n):void 0}:function(n,t){var i,r=[],f=0,u=t.getElementsByTagName(n);if(n==="*"){while(i=u[f++])i.nodeType===1&&r.push(i);return r}return u},t.find.CLASS=e.getElementsByClassName&&function(n,t){if(typeof t.getElementsByClassName!="undefined"&&h)return t.getElementsByClassName(n)},d=[],o=[],(e.qsa=ot.test(i.querySelectorAll))&&(a(function(n){s.appendChild(n).innerHTML="<a id='"+f+"'><\/a><select id='"+f+"-\r\\' msallowcapture=''><option selected=''><\/option><\/select>";n.querySelectorAll("[msallowcapture^='']").length&&o.push("[*^$]="+r+"*(?:''|\"\")");n.querySelectorAll("[selected]").length||o.push("\\["+r+"*(?:value|"+gt+")");n.querySelectorAll("[id~="+f+"-]").length||o.push("~=");n.querySelectorAll(":checked").length||o.push(":checked");n.querySelectorAll("a#"+f+"+*").length||o.push(".#.+[+~]")}),a(function(n){n.innerHTML="<a href='' disabled='disabled'><\/a><select disabled='disabled'><option/><\/select>";var t=i.createElement("input");t.setAttribute("type","hidden");n.appendChild(t).setAttribute("name","D");n.querySelectorAll("[name=d]").length&&o.push("name"+r+"*[*^$|!~]?=");n.querySelectorAll(":enabled").length!==2&&o.push(":enabled",":disabled");s.appendChild(n).disabled=!0;n.querySelectorAll(":disabled").length!==2&&o.push(":enabled",":disabled");n.querySelectorAll("*,:x");o.push(",.*:")})),(e.matchesSelector=ot.test(ct=s.matches||s.webkitMatchesSelector||s.mozMatchesSelector||s.oMatchesSelector||s.msMatchesSelector))&&a(function(n){e.disconnectedMatch=ct.call(n,"*");ct.call(n,"[s!='']:x");d.push("!=",ni)}),o=o.length&&new RegExp(o.join("|")),d=d.length&&new RegExp(d.join("|")),v=ot.test(s.compareDocumentPosition),et=v||ot.test(s.contains)?function(n,t){var r=n.nodeType===9?n.documentElement:n,i=t&&t.parentNode;return n===i||!!(i&&i.nodeType===1&&(r.contains?r.contains(i):n.compareDocumentPosition&&n.compareDocumentPosition(i)&16))}:function(n,t){if(t)while(t=t.parentNode)if(t===n)return!0;return!1},dt=v?function(n,t){if(n===t)return ut=!0,0;var r=!n.compareDocumentPosition-!t.compareDocumentPosition;return r?r:(r=(n.ownerDocument||n)===(t.ownerDocument||t)?n.compareDocumentPosition(t):1,r&1||!e.sortDetached&&t.compareDocumentPosition(n)===r)?n===i||n.ownerDocument===c&&et(c,n)?-1:t===i||t.ownerDocument===c&&et(c,t)?1:w?nt(w,n)-nt(w,t):0:r&4?-1:1}:function(n,t){if(n===t)return ut=!0,0;var r,u=0,o=n.parentNode,s=t.parentNode,f=[n],e=[t];if(o&&s){if(o===s)return bi(n,t)}else return n===i?-1:t===i?1:o?-1:s?1:w?nt(w,n)-nt(w,t):0;for(r=n;r=r.parentNode;)f.unshift(r);for(r=t;r=r.parentNode;)e.unshift(r);while(f[u]===e[u])u++;return u?bi(f[u],e[u]):f[u]===c?-1:e[u]===c?1:0},i)};u.matches=function(n,t){return u(n,null,null,t)};u.matchesSelector=function(n,t){if((n.ownerDocument||n)!==i&&b(n),e.matchesSelector&&h&&!lt[t+" "]&&(!d||!d.test(t))&&(!o||!o.test(t)))try{var r=ct.call(n,t);if(r||e.disconnectedMatch||n.document&&n.document.nodeType!==11)return r}catch(f){lt(t,!0)}return u(t,i,null,[n]).length>0};u.contains=function(n,t){return(n.ownerDocument||n)!==i&&b(n),et(n,t)};u.attr=function(n,r){(n.ownerDocument||n)!==i&&b(n);var f=t.attrHandle[r.toLowerCase()],u=f&&nr.call(t.attrHandle,r.toLowerCase())?f(n,r,!h):undefined;return u!==undefined?u:e.attributes||!h?n.getAttribute(r):(u=n.getAttributeNode(r))&&u.specified?u.value:null};u.escape=function(n){return(n+"").replace(yi,pi)};u.error=function(n){throw new Error("Syntax error, unrecognized expression: "+n);};u.uniqueSort=function(n){var r,u=[],t=0,i=0;if(ut=!e.detectDuplicates,w=!e.sortStable&&n.slice(0),n.sort(dt),ut){while(r=n[i++])r===n[i]&&(t=u.push(i));while(t--)n.splice(u[t],1)}return w=null,n};st=u.getText=function(n){var r,i="",u=0,t=n.nodeType;if(t){if(t===1||t===9||t===11){if(typeof n.textContent=="string")return n.textContent;for(n=n.firstChild;n;n=n.nextSibling)i+=st(n)}else if(t===3||t===4)return n.nodeValue}else while(r=n[u++])i+=st(r);return i};t=u.selectors={cacheLength:50,createPseudo:l,match:vt,attrHandle:{},find:{},relative:{">":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(n){return n[1]=n[1].replace(y,p),n[3]=(n[3]||n[4]||n[5]||"").replace(y,p),n[2]==="~="&&(n[3]=" "+n[3]+" "),n.slice(0,4)},CHILD:function(n){return n[1]=n[1].toLowerCase(),n[1].slice(0,3)==="nth"?(n[3]||u.error(n[0]),n[4]=+(n[4]?n[5]+(n[6]||1):2*(n[3]==="even"||n[3]==="odd")),n[5]=+(n[7]+n[8]||n[3]==="odd")):n[3]&&u.error(n[0]),n},PSEUDO:function(n){var i,t=!n[6]&&n[2];return vt.CHILD.test(n[0])?null:(n[3]?n[2]=n[4]||n[5]||"":t&&or.test(t)&&(i=ft(t,!0))&&(i=t.indexOf(")",t.length-i)-t.length)&&(n[0]=n[0].slice(0,i),n[2]=t.slice(0,i)),n.slice(0,3))}},filter:{TAG:function(n){var t=n.replace(y,p).toLowerCase();return n==="*"?function(){return!0}:function(n){return n.nodeName&&n.nodeName.toLowerCase()===t}},CLASS:function(n){var t=hi[n+" "];return t||(t=new RegExp("(^|"+r+")"+n+"("+r+"|$)"))&&hi(n,function(n){return t.test(typeof n.className=="string"&&n.className||typeof n.getAttribute!="undefined"&&n.getAttribute("class")||"")})},ATTR:function(n,t,i){return function(r){var f=u.attr(r,n);return f==null?t==="!=":t?(f+="",t==="="?f===i:t==="!="?f!==i:t==="^="?i&&f.indexOf(i)===0:t==="*="?i&&f.indexOf(i)>-1:t==="$="?i&&f.slice(-i.length)===i:t==="~="?(" "+f.replace(rr," ")+" ").indexOf(i)>-1:t==="|="?f===i||f.slice(0,i.length+1)===i+"-":!1):!0}},CHILD:function(n,t,i,r,u){var s=n.slice(0,3)!=="nth",o=n.slice(-4)!=="last",e=t==="of-type";return r===1&&u===0?function(n){return!!n.parentNode}:function(t,i,h){var p,w,y,c,a,b,k=s!==o?"nextSibling":"previousSibling",d=t.parentNode,nt=e&&t.nodeName.toLowerCase(),g=!h&&!e,l=!1;if(d){if(s){while(k){for(c=t;c=c[k];)if(e?c.nodeName.toLowerCase()===nt:c.nodeType===1)return!1;b=k=n==="only"&&!b&&"nextSibling"}return!0}if(b=[o?d.firstChild:d.lastChild],o&&g){for(c=d,y=c[f]||(c[f]={}),w=y[c.uniqueID]||(y[c.uniqueID]={}),p=w[n]||[],a=p[0]===v&&p[1],l=a&&p[2],c=a&&d.childNodes[a];c=++a&&c&&c[k]||(l=a=0)||b.pop();)if(c.nodeType===1&&++l&&c===t){w[n]=[v,a,l];break}}else if(g&&(c=t,y=c[f]||(c[f]={}),w=y[c.uniqueID]||(y[c.uniqueID]={}),p=w[n]||[],a=p[0]===v&&p[1],l=a),l===!1)while(c=++a&&c&&c[k]||(l=a=0)||b.pop())if((e?c.nodeName.toLowerCase()===nt:c.nodeType===1)&&++l&&(g&&(y=c[f]||(c[f]={}),w=y[c.uniqueID]||(y[c.uniqueID]={}),w[n]=[v,l]),c===t))break;return l-=u,l===r||l%r==0&&l/r>=0}}},PSEUDO:function(n,i){var e,r=t.pseudos[n]||t.setFilters[n.toLowerCase()]||u.error("unsupported pseudo: "+n);return r[f]?r(i):r.length>1?(e=[n,n,"",i],t.setFilters.hasOwnProperty(n.toLowerCase())?l(function(n,t){for(var u,f=r(n,i),e=f.length;e--;)u=nt(n,f[e]),n[u]=!(t[u]=f[e])}):function(n){return r(n,0,e)}):r}},pseudos:{not:l(function(n){var t=[],r=[],i=kt(n.replace(at,"$1"));return i[f]?l(function(n,t,r,u){for(var e,o=i(n,null,u,[]),f=n.length;f--;)(e=o[f])&&(n[f]=!(t[f]=e))}):function(n,u,f){return t[0]=n,i(t,null,f,r),t[0]=null,!r.pop()}}),has:l(function(n){return function(t){return u(n,t).length>0}}),contains:l(function(n){return n=n.replace(y,p),function(t){return(t.textContent||st(t)).indexOf(n)>-1}}),lang:l(function(n){return sr.test(n||"")||u.error("unsupported lang: "+n),n=n.replace(y,p).toLowerCase(),function(t){var i;do if(i=h?t.lang:t.getAttribute("xml:lang")||t.getAttribute("lang"))return i=i.toLowerCase(),i===n||i.indexOf(n+"-")===0;while((t=t.parentNode)&&t.nodeType===1);return!1}}),target:function(t){var i=n.location&&n.location.hash;return i&&i.slice(1)===t.id},root:function(n){return n===s},focus:function(n){return n===i.activeElement&&(!i.hasFocus||i.hasFocus())&&!!(n.type||n.href||~n.tabIndex)},enabled:ki(!1),disabled:ki(!0),checked:function(n){var t=n.nodeName.toLowerCase();return t==="input"&&!!n.checked||t==="option"&&!!n.selected},selected:function(n){return n.parentNode&&n.parentNode.selectedIndex,n.selected===!0},empty:function(n){for(n=n.firstChild;n;n=n.nextSibling)if(n.nodeType<6)return!1;return!0},parent:function(n){return!t.pseudos.empty(n)},header:function(n){return lr.test(n.nodeName)},input:function(n){return cr.test(n.nodeName)},button:function(n){var t=n.nodeName.toLowerCase();return t==="input"&&n.type==="button"||t==="button"},text:function(n){var t;return n.nodeName.toLowerCase()==="input"&&n.type==="text"&&((t=n.getAttribute("type"))==null||t.toLowerCase()==="text")},first:it(function(){return[0]}),last:it(function(n,t){return[t-1]}),eq:it(function(n,t,i){return[i<0?i+t:i]}),even:it(function(n,t){for(var i=0;i<t;i+=2)n.push(i);return n}),odd:it(function(n,t){for(var i=1;i<t;i+=2)n.push(i);return n}),lt:it(function(n,t,i){for(var r=i<0?i+t:i>t?t:i;--r>=0;)n.push(r);return n}),gt:it(function(n,t,i){for(var r=i<0?i+t:i;++r<t;)n.push(r);return n})}};t.pseudos.nth=t.pseudos.eq;for(rt in{radio:!0,checkbox:!0,file:!0,password:!0,image:!0})t.pseudos[rt]=yr(rt);for(rt in{submit:!0,reset:!0})t.pseudos[rt]=pr(rt);return di.prototype=t.filters=t.pseudos,t.setFilters=new di,ft=u.tokenize=function(n,i){var e,f,s,o,r,h,c,l=ci[n+" "];if(l)return i?0:l.slice(0);for(r=n,h=[],c=t.preFilter;r;){(!e||(f=ur.exec(r)))&&(f&&(r=r.slice(f[0].length)||r),h.push(s=[]));e=!1;(f=fr.exec(r))&&(e=f.shift(),s.push({value:e,type:f[0].replace(at," ")}),r=r.slice(e.length));for(o in t.filter)(f=vt[o].exec(r))&&(!c[o]||(f=c[o](f)))&&(e=f.shift(),s.push({value:e,type:o,matches:f}),r=r.slice(e.length));if(!e)break}return i?r.length:r?u.error(n):ci(n,h).slice(0)},kt=u.compile=function(n,t){var r,u=[],e=[],i=li[n+" "];if(!i){for(t||(t=ft(n)),r=t.length;r--;)i=ei(t[r]),i[f]?u.push(i):e.push(i);i=li(n,br(e,u));i.selector=n}return i},si=u.select=function(n,i,r,u){var o,f,e,l,a,c=typeof n=="function"&&n,s=!u&&ft(n=c.selector||n);if(r=r||[],s.length===1){if(f=s[0]=s[0].slice(0),f.length>2&&(e=f[0]).type==="ID"&&i.nodeType===9&&h&&t.relative[f[1].type]){if(i=(t.find.ID(e.matches[0].replace(y,p),i)||[])[0],i)c&&(i=i.parentNode);else return r;n=n.slice(f.shift().value.length)}for(o=vt.needsContext.test(n)?0:f.length;o--;){if(e=f[o],t.relative[l=e.type])break;if((a=t.find[l])&&(u=a(e.matches[0].replace(y,p),ti.test(f[0].type)&&ri(i.parentNode)||i))){if(f.splice(o,1),n=u.length&&pt(f),!n)return k.apply(r,u),r;break}}}return(c||kt(n,s))(u,i,!h,r,!i||ti.test(n)&&ri(i.parentNode)||i),r},e.sortStable=f.split("").sort(dt).join("")===f,e.detectDuplicates=!!ut,b(),e.sortDetached=a(function(n){return n.compareDocumentPosition(i.createElement("fieldset"))&1}),a(function(n){return n.innerHTML="<a href='#'><\/a>",n.firstChild.getAttribute("href")==="#"})||ii("type|href|height|width",function(n,t,i){if(!i)return n.getAttribute(t,t.toLowerCase()==="type"?1:2)}),e.attributes&&a(function(n){return n.innerHTML="<input/>",n.firstChild.setAttribute("value",""),n.firstChild.getAttribute("value")===""})||ii("value",function(n,t,i){if(!i&&n.nodeName.toLowerCase()==="input")return n.defaultValue}),a(function(n){return n.getAttribute("disabled")==null})||ii(gt,function(n,t,i){var r;if(!i)return n[t]===!0?t.toLowerCase():(r=n.getAttributeNode(t))&&r.specified?r.value:null}),u}(n);i.find=k;i.expr=k.selectors;i.expr[":"]=i.expr.pseudos;i.uniqueSort=i.unique=k.uniqueSort;i.text=k.getText;i.isXMLDoc=k.isXML;i.contains=k.contains;i.escapeSelector=k.escape;var rt=function(n,t,r){for(var u=[],f=r!==undefined;(n=n[t])&&n.nodeType!==9;)if(n.nodeType===1){if(f&&i(n).is(r))break;u.push(n)}return u},wr=function(n,t){for(var i=[];n;n=n.nextSibling)n.nodeType===1&&n!==t&&i.push(n);return i},br=i.expr.match.needsContext;vi=/^<([a-z][^\/\0>:\x20\t\r\n\f]*)[\x20\t\r\n\f]*\/?>(?:<\/\1>|)$/i;i.filter=function(n,t,r){var u=t[0];return(r&&(n=":not("+n+")"),t.length===1&&u.nodeType===1)?i.find.matchesSelector(u,n)?[u]:[]:i.find.matches(n,i.grep(t,function(n){return n.nodeType===1}))};i.fn.extend({find:function(n){var t,r,u=this.length,f=this;if(typeof n!="string")return this.pushStack(i(n).filter(function(){for(t=0;t<u;t++)if(i.contains(f[t],this))return!0}));for(r=this.pushStack([]),t=0;t<u;t++)i.find(n,f[t],r);return u>1?i.uniqueSort(r):r},filter:function(n){return this.pushStack(yi(this,n||[],!1))},not:function(n){return this.pushStack(yi(this,n||[],!0))},is:function(n){return!!yi(this,typeof n=="string"&&br.test(n)?i(n):n||[],!1).length}});dr=/^(?:\s*(<[\w\W]+>)[^>]*|#([\w-]+))$/;gr=i.fn.init=function(n,t,r){var e,o;if(!n)return this;if(r=r||kr,typeof n=="string"){if(e=n[0]==="<"&&n[n.length-1]===">"&&n.length>=3?[null,n,null]:dr.exec(n),e&&(e[1]||!t)){if(e[1]){if(t=t instanceof i?t[0]:t,i.merge(this,i.parseHTML(e[1],t&&t.nodeType?t.ownerDocument||t:f,!0)),vi.test(e[1])&&i.isPlainObject(t))for(e in t)u(this[e])?this[e](t[e]):this.attr(e,t[e]);return this}return o=f.getElementById(e[2]),o&&(this[0]=o,this.length=1),this}return!t||t.jquery?(t||r).find(n):this.constructor(t).find(n)}return n.nodeType?(this[0]=n,this.length=1,this):u(n)?r.ready!==undefined?r.ready(n):n(i):i.makeArray(n,this)};gr.prototype=i.fn;kr=i(f);nu=/^(?:parents|prev(?:Until|All))/;tu={children:!0,contents:!0,next:!0,prev:!0};i.fn.extend({has:function(n){var t=i(n,this),r=t.length;return this.filter(function(){for(var n=0;n<r;n++)if(i.contains(this,t[n]))return!0})},closest:function(n,t){var r,f=0,o=this.length,u=[],e=typeof n!="string"&&i(n);if(!br.test(n))for(;f<o;f++)for(r=this[f];r&&r!==t;r=r.parentNode)if(r.nodeType<11&&(e?e.index(r)>-1:r.nodeType===1&&i.find.matchesSelector(r,n))){u.push(r);break}return this.pushStack(u.length>1?i.uniqueSort(u):u)},index:function(n){return n?typeof n=="string"?ni.call(i(n),this[0]):ni.call(this,n.jquery?n[0]:n):this[0]&&this[0].parentNode?this.first().prevAll().length:-1},add:function(n,t){return this.pushStack(i.uniqueSort(i.merge(this.get(),i(n,t))))},addBack:function(n){return this.add(n==null?this.prevObject:this.prevObject.filter(n))}});i.each({parent:function(n){var t=n.parentNode;return t&&t.nodeType!==11?t:null},parents:function(n){return rt(n,"parentNode")},parentsUntil:function(n,t,i){return rt(n,"parentNode",i)},next:function(n){return iu(n,"nextSibling")},prev:function(n){return iu(n,"previousSibling")},nextAll:function(n){return rt(n,"nextSibling")},prevAll:function(n){return rt(n,"previousSibling")},nextUntil:function(n,t,i){return rt(n,"nextSibling",i)},prevUntil:function(n,t,i){return rt(n,"previousSibling",i)},siblings:function(n){return wr((n.parentNode||{}).firstChild,n)},children:function(n){return wr(n.firstChild)},contents:function(n){return typeof n.contentDocument!="undefined"?n.contentDocument:(l(n,"template")&&(n=n.content||n),i.merge([],n.childNodes))}},function(n,t){i.fn[n]=function(r,u){var f=i.map(this,t,r);return n.slice(-5)!=="Until"&&(u=r),u&&typeof u=="string"&&(f=i.filter(u,f)),this.length>1&&(tu[n]||i.uniqueSort(f),nu.test(n)&&f.reverse()),this.pushStack(f)}});a=/[^\x20\t\r\n\f]+/g;i.Callbacks=function(n){n=typeof n=="string"?ue(n):i.extend({},n);var o,r,c,f,t=[],s=[],e=-1,l=function(){for(f=f||n.once,c=o=!0;s.length;e=-1)for(r=s.shift();++e<t.length;)t[e].apply(r[0],r[1])===!1&&n.stopOnFalse&&(e=t.length,r=!1);n.memory||(r=!1);o=!1;f&&(t=r?[]:"")},h={add:function(){return t&&(r&&!o&&(e=t.length-1,s.push(r)),function f(r){i.each(r,function(i,r){u(r)?n.unique&&h.has(r)||t.push(r):r&&r.length&&it(r)!=="string"&&f(r)})}(arguments),r&&!o&&l()),this},remove:function(){return i.each(arguments,function(n,r){for(var u;(u=i.inArray(r,t,u))>-1;)t.splice(u,1),u<=e&&e--}),this},has:function(n){return n?i.inArray(n,t)>-1:t.length>0},empty:function(){return t&&(t=[]),this},disable:function(){return f=s=[],t=r="",this},disabled:function(){return!t},lock:function(){return f=s=[],r||o||(t=r=""),this},locked:function(){return!!f},fireWith:function(n,t){return f||(t=t||[],t=[n,t.slice?t.slice():t],s.push(t),o||l()),this},fire:function(){return h.fireWith(this,arguments),this},fired:function(){return!!c}};return h};i.extend({Deferred:function(t){var f=[["notify","progress",i.Callbacks("memory"),i.Callbacks("memory"),2],["resolve","done",i.Callbacks("once memory"),i.Callbacks("once memory"),0,"resolved"],["reject","fail",i.Callbacks("once memory"),i.Callbacks("once memory"),1,"rejected"]],o="pending",e={state:function(){return o},always:function(){return r.done(arguments).fail(arguments),this},"catch":function(n){return e.then(null,n)},pipe:function(){var n=arguments;return i.Deferred(function(t){i.each(f,function(i,f){var e=u(n[f[4]])&&n[f[4]];r[f[1]](function(){var n=e&&e.apply(this,arguments);n&&u(n.promise)?n.promise().progress(t.notify).done(t.resolve).fail(t.reject):t[f[0]+"With"](this,e?[n]:arguments)})});n=null}).promise()},then:function(t,r,e){function s(t,r,f,e){return function(){var h=this,c=arguments,a=function(){var n,i;if(!(t<o)){if(n=f.apply(h,c),n===r.promise())throw new TypeError("Thenable self-resolution");i=n&&(typeof n=="object"||typeof n=="function")&&n.then;u(i)?e?i.call(n,s(o,r,ut,e),s(o,r,ri,e)):(o++,i.call(n,s(o,r,ut,e),s(o,r,ri,e),s(o,r,ut,r.notifyWith))):(f!==ut&&(h=undefined,c=[n]),(e||r.resolveWith)(h,c))}},l=e?a:function(){try{a()}catch(n){i.Deferred.exceptionHook&&i.Deferred.exceptionHook(n,l.stackTrace);t+1>=o&&(f!==ri&&(h=undefined,c=[n]),r.rejectWith(h,c))}};t?l():(i.Deferred.getStackHook&&(l.stackTrace=i.Deferred.getStackHook()),n.setTimeout(l))}}var o=0;return i.Deferred(function(n){f[0][3].add(s(0,n,u(e)?e:ut,n.notifyWith));f[1][3].add(s(0,n,u(t)?t:ut));f[2][3].add(s(0,n,u(r)?r:ri))}).promise()},promise:function(n){return n!=null?i.extend(n,e):e}},r={};return i.each(f,function(n,t){var i=t[2],u=t[5];e[t[1]]=i.add;u&&i.add(function(){o=u},f[3-n][2].disable,f[3-n][3].disable,f[0][2].lock,f[0][3].lock);i.add(t[3].fire);r[t[0]]=function(){return r[t[0]+"With"](this===r?undefined:this,arguments),this};r[t[0]+"With"]=i.fireWith}),e.promise(r),t&&t.call(r,r),r},when:function(n){var e=arguments.length,t=e,o=Array(t),f=b.call(arguments),r=i.Deferred(),s=function(n){return function(t){o[n]=this;f[n]=arguments.length>1?b.call(arguments):t;--e||r.resolveWith(o,f)}};if(e<=1&&(ru(n,r.done(s(t)).resolve,r.reject,!e),r.state()==="pending"||u(f[t]&&f[t].then)))return r.then();while(t--)ru(f[t],s(t),r.reject);return r.promise()}});uu=/^(Eval|Internal|Range|Reference|Syntax|Type|URI)Error$/;i.Deferred.exceptionHook=function(t,i){n.console&&n.console.warn&&t&&uu.test(t.name)&&n.console.warn("jQuery.Deferred exception: "+t.message,t.stack,i)};i.readyException=function(t){n.setTimeout(function(){throw t;})};ui=i.Deferred();i.fn.ready=function(n){return ui.then(n).catch(function(n){i.readyException(n)}),this};i.extend({isReady:!1,readyWait:1,ready:function(n){(n===!0?--i.readyWait:i.isReady)||(i.isReady=!0,n!==!0&&--i.readyWait>0)||ui.resolveWith(f,[i])}});i.ready.then=ui.then;f.readyState!=="complete"&&(f.readyState==="loading"||f.documentElement.doScroll)?(f.addEventListener("DOMContentLoaded",fi),n.addEventListener("load",fi)):n.setTimeout(i.ready);var p=function(n,t,r,f,e,o,s){var h=0,l=n.length,c=r==null;if(it(r)==="object"){e=!0;for(h in r)p(n,t,h,r[h],!0,o,s)}else if(f!==undefined&&(e=!0,u(f)||(s=!0),c&&(s?(t.call(n,f),t=null):(c=t,t=function(n,t,r){return c.call(i(n),r)})),t))for(;h<l;h++)t(n[h],r,s?f:f.call(n[h],h,t(n[h],r)));return e?n:c?t.call(n):l?t(n[0],r):o},fe=/^-ms-/,ee=/-([a-z])/g;vt=function(n){return n.nodeType===1||n.nodeType===9||!+n.nodeType};yt.uid=1;yt.prototype={cache:function(n){var t=n[this.expando];return t||(t={},vt(n)&&(n.nodeType?n[this.expando]=t:Object.defineProperty(n,this.expando,{value:t,configurable:!0}))),t},set:function(n,t,i){var r,u=this.cache(n);if(typeof t=="string")u[y(t)]=i;else for(r in t)u[y(r)]=t[r];return u},get:function(n,t){return t===undefined?this.cache(n):n[this.expando]&&n[this.expando][y(t)]},access:function(n,t,i){return t===undefined||t&&typeof t=="string"&&i===undefined?this.get(n,t):(this.set(n,t,i),i!==undefined?i:t)},remove:function(n,t){var u,r=n[this.expando];if(r!==undefined){if(t!==undefined)for(Array.isArray(t)?t=t.map(y):(t=y(t),t=t in r?[t]:t.match(a)||[]),u=t.length;u--;)delete r[t[u]];(t===undefined||i.isEmptyObject(r))&&(n.nodeType?n[this.expando]=undefined:delete n[this.expando])}},hasData:function(n){var t=n[this.expando];return t!==undefined&&!i.isEmptyObject(t)}};var r=new yt,o=new yt,se=/^(?:\{[\w\W]*\}|\[[\w\W]*\])$/,he=/[A-Z]/g;i.extend({hasData:function(n){return o.hasData(n)||r.hasData(n)},data:function(n,t,i){return o.access(n,t,i)},removeData:function(n,t){o.remove(n,t)},_data:function(n,t,i){return r.access(n,t,i)},_removeData:function(n,t){r.remove(n,t)}});i.fn.extend({data:function(n,t){var f,u,e,i=this[0],s=i&&i.attributes;if(n===undefined){if(this.length&&(e=o.get(i),i.nodeType===1&&!r.get(i,"hasDataAttrs"))){for(f=s.length;f--;)s[f]&&(u=s[f].name,u.indexOf("data-")===0&&(u=y(u.slice(5)),fu(i,u,e[u])));r.set(i,"hasDataAttrs",!0)}return e}return typeof n=="object"?this.each(function(){o.set(this,n)}):p(this,function(t){var r;if(i&&t===undefined)return(r=o.get(i,n),r!==undefined)?r:(r=fu(i,n),r!==undefined)?r:void 0;this.each(function(){o.set(this,n,t)})},null,t,arguments.length>1,null,!0)},removeData:function(n){return this.each(function(){o.remove(this,n)})}});i.extend({queue:function(n,t,u){var f;if(n)return t=(t||"fx")+"queue",f=r.get(n,t),u&&(!f||Array.isArray(u)?f=r.access(n,t,i.makeArray(u)):f.push(u)),f||[]},dequeue:function(n,t){t=t||"fx";var r=i.queue(n,t),e=r.length,u=r.shift(),f=i._queueHooks(n,t),o=function(){i.dequeue(n,t)};u==="inprogress"&&(u=r.shift(),e--);u&&(t==="fx"&&r.unshift("inprogress"),delete f.stop,u.call(n,o,f));!e&&f&&f.empty.fire()},_queueHooks:function(n,t){var u=t+"queueHooks";return r.get(n,u)||r.access(n,u,{empty:i.Callbacks("once memory").add(function(){r.remove(n,[t+"queue",u])})})}});i.fn.extend({queue:function(n,t){var r=2;return(typeof n!="string"&&(t=n,n="fx",r--),arguments.length<r)?i.queue(this[0],n):t===undefined?this:this.each(function(){var r=i.queue(this,n,t);i._queueHooks(this,n);n==="fx"&&r[0]!=="inprogress"&&i.dequeue(this,n)})},dequeue:function(n){return this.each(function(){i.dequeue(this,n)})},clearQueue:function(n){return this.queue(n||"fx",[])},promise:function(n,t){var u,e=1,o=i.Deferred(),f=this,s=this.length,h=function(){--e||o.resolveWith(f,[f])};for(typeof n!="string"&&(t=n,n=undefined),n=n||"fx";s--;)u=r.get(f[s],n+"queueHooks"),u&&u.empty&&(e++,u.empty.add(h));return h(),o.promise(t)}});var eu=/[+-]?(?:\d*\.|)\d+(?:[eE][+-]?\d+|)/.source,pt=new RegExp("^(?:([+-])=|)("+eu+")([a-z%]*)$","i"),w=["Top","Right","Bottom","Left"],wt=f.documentElement,ft=function(n){return i.contains(n.ownerDocument,n)},le={composed:!0};wt.getRootNode&&(ft=function(n){return i.contains(n.ownerDocument,n)||n.getRootNode(le)===n.ownerDocument});bt=function(n,t){return n=t||n,n.style.display==="none"||n.style.display===""&&ft(n)&&i.css(n,"display")==="none"};pi=function(n,t,i,r){var f,u,e={};for(u in t)e[u]=n.style[u],n.style[u]=t[u];f=i.apply(n,r||[]);for(u in t)n.style[u]=e[u];return f};wi={};i.fn.extend({show:function(){return et(this,!0)},hide:function(){return et(this)},toggle:function(n){return typeof n=="boolean"?n?this.show():this.hide():this.each(function(){bt(this)?i(this).show():i(this).hide()})}});var kt=/^(?:checkbox|radio)$/i,su=/<([a-z][^\/\0>\x20\t\r\n\f]*)/i,hu=/^$|^module$|\/(?:java|ecma)script/i,c={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,"",""]};c.optgroup=c.option;c.tbody=c.tfoot=c.colgroup=c.caption=c.thead;c.th=c.td;cu=/<|&#?\w+;/,function(){var i=f.createDocumentFragment(),n=i.appendChild(f.createElement("div")),t=f.createElement("input");t.setAttribute("type","radio");t.setAttribute("checked","checked");t.setAttribute("name","t");n.appendChild(t);e.checkClone=n.cloneNode(!0).cloneNode(!0).lastChild.checked;n.innerHTML="<textarea>x<\/textarea>";e.noCloneChecked=!!n.cloneNode(!0).lastChild.defaultValue}();var ve=/^key/,ye=/^(?:mouse|pointer|contextmenu|drag|drop)|click/,au=/^([^.]*)(?:\.(.+)|)/;i.event={global:{},add:function(n,t,u,f,e){var v,y,w,p,b,h,s,c,o,k,d,l=r.get(n);if(l)for(u.handler&&(v=u,u=v.handler,e=v.selector),e&&i.find.matchesSelector(wt,e),u.guid||(u.guid=i.guid++),(p=l.events)||(p=l.events={}),(y=l.handle)||(y=l.handle=function(t){return typeof i!="undefined"&&i.event.triggered!==t.type?i.event.dispatch.apply(n,arguments):undefined}),t=(t||"").match(a)||[""],b=t.length;b--;)(w=au.exec(t[b])||[],o=d=w[1],k=(w[2]||"").split(".").sort(),o)&&(s=i.event.special[o]||{},o=(e?s.delegateType:s.bindType)||o,s=i.event.special[o]||{},h=i.extend({type:o,origType:d,data:f,handler:u,guid:u.guid,selector:e,needsContext:e&&i.expr.match.needsContext.test(e),namespace:k.join(".")},v),(c=p[o])||(c=p[o]=[],c.delegateCount=0,s.setup&&s.setup.call(n,f,k,y)!==!1||n.addEventListener&&n.addEventListener(o,y)),s.add&&(s.add.call(n,h),h.handler.guid||(h.handler.guid=u.guid)),e?c.splice(c.delegateCount++,0,h):c.push(h),i.event.global[o]=!0)},remove:function(n,t,u,f,e){var y,k,h,v,p,s,c,l,o,b,d,w=r.hasData(n)&&r.get(n);if(w&&(v=w.events)){for(t=(t||"").match(a)||[""],p=t.length;p--;){if(h=au.exec(t[p])||[],o=d=h[1],b=(h[2]||"").split(".").sort(),!o){for(o in v)i.event.remove(n,o+t[p],u,f,!0);continue}for(c=i.event.special[o]||{},o=(f?c.delegateType:c.bindType)||o,l=v[o]||[],h=h[2]&&new RegExp("(^|\\.)"+b.join("\\.(?:.*\\.|)")+"(\\.|$)"),k=y=l.length;y--;)s=l[y],(e||d===s.origType)&&(!u||u.guid===s.guid)&&(!h||h.test(s.namespace))&&(!f||f===s.selector||f==="**"&&s.selector)&&(l.splice(y,1),s.selector&&l.delegateCount--,c.remove&&c.remove.call(n,s));k&&!l.length&&(c.teardown&&c.teardown.call(n,b,w.handle)!==!1||i.removeEvent(n,o,w.handle),delete v[o])}i.isEmptyObject(v)&&r.remove(n,"handle events")}},dispatch:function(n){var t=i.event.fix(n),u,c,s,e,f,l,h=new Array(arguments.length),a=(r.get(this,"events")||{})[t.type]||[],o=i.event.special[t.type]||{};for(h[0]=t,u=1;u<arguments.length;u++)h[u]=arguments[u];if(t.delegateTarget=this,!o.preDispatch||o.preDispatch.call(this,t)!==!1){for(l=i.event.handlers.call(this,t,a),u=0;(e=l[u++])&&!t.isPropagationStopped();)for(t.currentTarget=e.elem,c=0;(f=e.handlers[c++])&&!t.isImmediatePropagationStopped();)(!t.rnamespace||f.namespace===!1||t.rnamespace.test(f.namespace))&&(t.handleObj=f,t.data=f.data,s=((i.event.special[f.origType]||{}).handle||f.handler).apply(e.elem,h),s!==undefined&&(t.result=s)===!1&&(t.preventDefault(),t.stopPropagation()));return o.postDispatch&&o.postDispatch.call(this,t),t.result}},handlers:function(n,t){var f,e,u,o,s,c=[],h=t.delegateCount,r=n.target;if(h&&r.nodeType&&!(n.type==="click"&&n.button>=1))for(;r!==this;r=r.parentNode||this)if(r.nodeType===1&&!(n.type==="click"&&r.disabled===!0)){for(o=[],s={},f=0;f<h;f++)e=t[f],u=e.selector+" ",s[u]===undefined&&(s[u]=e.needsContext?i(u,this).index(r)>-1:i.find(u,this,null,[r]).length),s[u]&&o.push(e);o.length&&c.push({elem:r,handlers:o})}return r=this,h<t.length&&c.push({elem:r,handlers:t.slice(h)}),c},addProp:function(n,t){Object.defineProperty(i.Event.prototype,n,{enumerable:!0,configurable:!0,get:u(t)?function(){if(this.originalEvent)return t(this.originalEvent)}:function(){if(this.originalEvent)return this.originalEvent[n]},set:function(t){Object.defineProperty(this,n,{enumerable:!0,configurable:!0,writable:!0,value:t})}})},fix:function(n){return n[i.expando]?n:new i.Event(n)},special:{load:{noBubble:!0},click:{setup:function(n){var t=this||n;return kt.test(t.type)&&t.click&&l(t,"input")&&ei(t,"click",ot),!1},trigger:function(n){var t=this||n;return kt.test(t.type)&&t.click&&l(t,"input")&&ei(t,"click"),!0},_default:function(n){var t=n.target;return kt.test(t.type)&&t.click&&l(t,"input")&&r.get(t,"click")||l(t,"a")}},beforeunload:{postDispatch:function(n){n.result!==undefined&&n.originalEvent&&(n.originalEvent.returnValue=n.result)}}}};i.removeEvent=function(n,t,i){n.removeEventListener&&n.removeEventListener(t,i)};i.Event=function(n,t){if(!(this instanceof i.Event))return new i.Event(n,t);n&&n.type?(this.originalEvent=n,this.type=n.type,this.isDefaultPrevented=n.defaultPrevented||n.defaultPrevented===undefined&&n.returnValue===!1?ot:st,this.target=n.target&&n.target.nodeType===3?n.target.parentNode:n.target,this.currentTarget=n.currentTarget,this.relatedTarget=n.relatedTarget):this.type=n;t&&i.extend(this,t);this.timeStamp=n&&n.timeStamp||Date.now();this[i.expando]=!0};i.Event.prototype={constructor:i.Event,isDefaultPrevented:st,isPropagationStopped:st,isImmediatePropagationStopped:st,isSimulated:!1,preventDefault:function(){var n=this.originalEvent;this.isDefaultPrevented=ot;n&&!this.isSimulated&&n.preventDefault()},stopPropagation:function(){var n=this.originalEvent;this.isPropagationStopped=ot;n&&!this.isSimulated&&n.stopPropagation()},stopImmediatePropagation:function(){var n=this.originalEvent;this.isImmediatePropagationStopped=ot;n&&!this.isSimulated&&n.stopImmediatePropagation();this.stopPropagation()}};i.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(n){var t=n.button;return n.which==null&&ve.test(n.type)?n.charCode!=null?n.charCode:n.keyCode:!n.which&&t!==undefined&&ye.test(n.type)?t&1?1:t&2?3:t&4?2:0:n.which}},i.event.addProp);i.each({focus:"focusin",blur:"focusout"},function(n,t){i.event.special[n]={setup:function(){return ei(this,n,pe),!1},trigger:function(){return ei(this,n),!0},delegateType:t}});i.each({mouseenter:"mouseover",mouseleave:"mouseout",pointerenter:"pointerover",pointerleave:"pointerout"},function(n,t){i.event.special[n]={delegateType:t,bindType:t,handle:function(n){var u,f=this,r=n.relatedTarget,e=n.handleObj;return r&&(r===f||i.contains(f,r))||(n.type=e.origType,u=e.handler.apply(this,arguments),n.type=t),u}}});i.fn.extend({on:function(n,t,i,r){return ki(this,n,t,i,r)},one:function(n,t,i,r){return ki(this,n,t,i,r,1)},off:function(n,t,r){var u,f;if(n&&n.preventDefault&&n.handleObj)return u=n.handleObj,i(n.delegateTarget).off(u.namespace?u.origType+"."+u.namespace:u.origType,u.selector,u.handler),this;if(typeof n=="object"){for(f in n)this.off(f,t,n[f]);return this}return(t===!1||typeof t=="function")&&(r=t,t=undefined),r===!1&&(r=st),this.each(function(){i.event.remove(this,n,r,t)})}});var be=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([a-z][^\/\0>\x20\t\r\n\f]*)[^>]*)\/>/gi,ke=/<script|<style|<link/i,de=/checked\s*(?:[^=]|=\s*.checked.)/i,ge=/^\s*<!(?:\[CDATA\[|--)|(?:\]\]|--)>\s*$/g;i.extend({htmlPrefilter:function(n){return n.replace(be,"<$1><\/$2>")},clone:function(n,t,r){var u,c,o,f,h=n.cloneNode(!0),l=ft(n);if(!e.noCloneChecked&&(n.nodeType===1||n.nodeType===11)&&!i.isXMLDoc(n))for(f=s(h),o=s(n),u=0,c=o.length;u<c;u++)io(o[u],f[u]);if(t)if(r)for(o=o||s(n),f=f||s(h),u=0,c=o.length;u<c;u++)yu(o[u],f[u]);else yu(n,h);return f=s(h,"script"),f.length>0&&bi(f,!l&&s(n,"script")),h},cleanData:function(n){for(var u,t,f,s=i.event.special,e=0;(t=n[e])!==undefined;e++)if(vt(t)){if(u=t[r.expando]){if(u.events)for(f in u.events)s[f]?i.event.remove(t,f):i.removeEvent(t,f,u.handle);t[r.expando]=undefined}t[o.expando]&&(t[o.expando]=undefined)}}});i.fn.extend({detach:function(n){return pu(this,n,!0)},remove:function(n){return pu(this,n)},text:function(n){return p(this,function(n){return n===undefined?i.text(this):this.empty().each(function(){(this.nodeType===1||this.nodeType===11||this.nodeType===9)&&(this.textContent=n)})},null,n,arguments.length)},append:function(){return ht(this,arguments,function(n){if(this.nodeType===1||this.nodeType===11||this.nodeType===9){var t=vu(this,n);t.appendChild(n)}})},prepend:function(){return ht(this,arguments,function(n){if(this.nodeType===1||this.nodeType===11||this.nodeType===9){var t=vu(this,n);t.insertBefore(n,t.firstChild)}})},before:function(){return ht(this,arguments,function(n){this.parentNode&&this.parentNode.insertBefore(n,this)})},after:function(){return ht(this,arguments,function(n){this.parentNode&&this.parentNode.insertBefore(n,this.nextSibling)})},empty:function(){for(var n,t=0;(n=this[t])!=null;t++)n.nodeType===1&&(i.cleanData(s(n,!1)),n.textContent="");return this},clone:function(n,t){return n=n==null?!1:n,t=t==null?n:t,this.map(function(){return i.clone(this,n,t)})},html:function(n){return p(this,function(n){var t=this[0]||{},r=0,u=this.length;if(n===undefined&&t.nodeType===1)return t.innerHTML;if(typeof n=="string"&&!ke.test(n)&&!c[(su.exec(n)||["",""])[1].toLowerCase()]){n=i.htmlPrefilter(n);try{for(;r<u;r++)t=this[r]||{},t.nodeType===1&&(i.cleanData(s(t,!1)),t.innerHTML=n);t=0}catch(f){}}t&&this.empty().append(n)},null,n,arguments.length)},replaceWith:function(){var n=[];return ht(this,arguments,function(t){var r=this.parentNode;i.inArray(this,n)<0&&(i.cleanData(s(this)),r&&r.replaceChild(t,this))},n)}});i.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(n,t){i.fn[n]=function(n){for(var u,f=[],e=i(n),o=e.length-1,r=0;r<=o;r++)u=r===o?this:this.clone(!0),i(e[r])[t](u),li.apply(f,u.get());return this.pushStack(f)}});var di=new RegExp("^("+eu+")(?!px)[a-z%]+$","i"),oi=function(t){var i=t.ownerDocument.defaultView;return i&&i.opener||(i=n),i.getComputedStyle(t)},ro=new RegExp(w.join("|"),"i");(function(){function r(){if(t){o.style.cssText="position:absolute;left:-11111px;width:60px;margin-top:1px;padding:0;border:0";t.style.cssText="position:relative;display:block;box-sizing:border-box;overflow:scroll;margin:auto;border:1px;padding:1px;width:60%;top:1%";wt.appendChild(o).appendChild(t);var i=n.getComputedStyle(t);s=i.top!=="1%";a=u(i.marginLeft)===12;t.style.right="60%";l=u(i.right)===36;h=u(i.width)===36;t.style.position="absolute";c=u(t.offsetWidth/3)===12;wt.removeChild(o);t=null}}function u(n){return Math.round(parseFloat(n))}var s,h,c,l,a,o=f.createElement("div"),t=f.createElement("div");t.style&&(t.style.backgroundClip="content-box",t.cloneNode(!0).style.backgroundClip="",e.clearCloneStyle=t.style.backgroundClip==="content-box",i.extend(e,{boxSizingReliable:function(){return r(),h},pixelBoxStyles:function(){return r(),l},pixelPosition:function(){return r(),s},reliableMarginLeft:function(){return r(),a},scrollboxSize:function(){return r(),c}}))})();var bu=["Webkit","Moz","ms"],ku=f.createElement("div").style,du={};var fo=/^(none|table(?!-c[ea]).+)/,gu=/^--/,eo={position:"absolute",visibility:"hidden",display:"block"},nf={letterSpacing:"0",fontWeight:"400"};i.extend({cssHooks:{opacity:{get:function(n,t){if(t){var i=dt(n,"opacity");return i===""?"1":i}}}},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(n,t,r,u){if(n&&n.nodeType!==3&&n.nodeType!==8&&n.style){var f,s,o,c=y(t),l=gu.test(t),h=n.style;if(l||(t=gi(c)),o=i.cssHooks[t]||i.cssHooks[c],r!==undefined){if(s=typeof r,s==="string"&&(f=pt.exec(r))&&f[1]&&(r=ou(n,t,f),s="number"),r==null||r!==r)return;s!=="number"||l||(r+=f&&f[3]||(i.cssNumber[c]?"":"px"));e.clearCloneStyle||r!==""||t.indexOf("background")!==0||(h[t]="inherit");o&&"set"in o&&(r=o.set(n,r,u))===undefined||(l?h.setProperty(t,r):h[t]=r)}else return o&&"get"in o&&(f=o.get(n,!1,u))!==undefined?f:h[t]}},css:function(n,t,r,u){var f,o,e,s=y(t),h=gu.test(t);return(h||(t=gi(s)),e=i.cssHooks[t]||i.cssHooks[s],e&&"get"in e&&(f=e.get(n,!0,r)),f===undefined&&(f=dt(n,t,u)),f==="normal"&&t in nf&&(f=nf[t]),r===""||r)?(o=parseFloat(f),r===!0||isFinite(o)?o||0:f):f}});i.each(["height","width"],function(n,t){i.cssHooks[t]={get:function(n,r,u){if(r)return fo.test(i.css(n,"display"))&&(!n.getClientRects().length||!n.getBoundingClientRect().width)?pi(n,eo,function(){return rf(n,t,u)}):rf(n,t,u)},set:function(n,r,u){var s,f=oi(n),h=!e.scrollboxSize()&&f.position==="absolute",l=h||u,c=l&&i.css(n,"boxSizing",!1,f)==="border-box",o=u?nr(n,t,u,c,f):0;return c&&h&&(o-=Math.ceil(n["offset"+t[0].toUpperCase()+t.slice(1)]-parseFloat(f[t])-nr(n,t,"border",!1,f)-.5)),o&&(s=pt.exec(r))&&(s[3]||"px")!=="px"&&(n.style[t]=r,r=i.css(n,t)),tf(n,r,o)}}});i.cssHooks.marginLeft=wu(e.reliableMarginLeft,function(n,t){if(t)return(parseFloat(dt(n,"marginLeft"))||n.getBoundingClientRect().left-pi(n,{marginLeft:0},function(){return n.getBoundingClientRect().left}))+"px"});i.each({margin:"",padding:"",border:"Width"},function(n,t){i.cssHooks[n+t]={expand:function(i){for(var r=0,f={},u=typeof i=="string"?i.split(" "):[i];r<4;r++)f[n+w[r]+t]=u[r]||u[r-2]||u[0];return f}};n!=="margin"&&(i.cssHooks[n+t].set=tf)});i.fn.extend({css:function(n,t){return p(this,function(n,t,r){var f,e,o={},u=0;if(Array.isArray(t)){for(f=oi(n),e=t.length;u<e;u++)o[t[u]]=i.css(n,t[u],!1,f);return o}return r!==undefined?i.style(n,t,r):i.css(n,t)},n,t,arguments.length>1)}});i.Tween=h;h.prototype={constructor:h,init:function(n,t,r,u,f,e){this.elem=n;this.prop=r;this.easing=f||i.easing._default;this.options=t;this.start=this.now=this.cur();this.end=u;this.unit=e||(i.cssNumber[r]?"":"px")},cur:function(){var n=h.propHooks[this.prop];return n&&n.get?n.get(this):h.propHooks._default.get(this)},run:function(n){var t,r=h.propHooks[this.prop];return this.pos=this.options.duration?t=i.easing[this.easing](n,this.options.duration*n,0,1,this.options.duration):t=n,this.now=(this.end-this.start)*t+this.start,this.options.step&&this.options.step.call(this.elem,this.now,this),r&&r.set?r.set(this):h.propHooks._default.set(this),this}};h.prototype.init.prototype=h.prototype;h.propHooks={_default:{get:function(n){var t;return n.elem.nodeType!==1||n.elem[n.prop]!=null&&n.elem.style[n.prop]==null?n.elem[n.prop]:(t=i.css(n.elem,n.prop,""),!t||t==="auto"?0:t)},set:function(n){i.fx.step[n.prop]?i.fx.step[n.prop](n):n.elem.nodeType===1&&(i.cssHooks[n.prop]||n.elem.style[gi(n.prop)]!=null)?i.style(n.elem,n.prop,n.now+n.unit):n.elem[n.prop]=n.now}}};h.propHooks.scrollTop=h.propHooks.scrollLeft={set:function(n){n.elem.nodeType&&n.elem.parentNode&&(n.elem[n.prop]=n.now)}};i.easing={linear:function(n){return n},swing:function(n){return.5-Math.cos(n*Math.PI)/2},_default:"swing"};i.fx=h.prototype.init;i.fx.step={};uf=/^(?:toggle|show|hide)$/;ff=/queueHooks$/;i.Animation=i.extend(v,{tweeners:{"*":[function(n,t){var i=this.createTween(n,t);return ou(i.elem,n,pt.exec(t),i),i}]},tweener:function(n,t){u(n)?(t=n,n=["*"]):n=n.match(a);for(var i,r=0,f=n.length;r<f;r++)i=n[r],v.tweeners[i]=v.tweeners[i]||[],v.tweeners[i].unshift(t)},prefilters:[oo],prefilter:function(n,t){t?v.prefilters.unshift(n):v.prefilters.push(n)}});i.speed=function(n,t,r){var f=n&&typeof n=="object"?i.extend({},n):{complete:r||!r&&t||u(n)&&n,duration:n,easing:r&&t||t&&!u(t)&&t};return i.fx.off?f.duration=0:typeof f.duration!="number"&&(f.duration=f.duration in i.fx.speeds?i.fx.speeds[f.duration]:i.fx.speeds._default),(f.queue==null||f.queue===!0)&&(f.queue="fx"),f.old=f.complete,f.complete=function(){u(f.old)&&f.old.call(this);f.queue&&i.dequeue(this,f.queue)},f};i.fn.extend({fadeTo:function(n,t,i,r){return this.filter(bt).css("opacity",0).show().end().animate({opacity:t},n,i,r)},animate:function(n,t,u,f){var s=i.isEmptyObject(n),o=i.speed(t,u,f),e=function(){var t=v(this,i.extend({},n),o);(s||r.get(this,"finish"))&&t.stop(!0)};return e.finish=e,s||o.queue===!1?this.each(e):this.queue(o.queue,e)},stop:function(n,t,u){var f=function(n){var t=n.stop;delete n.stop;t(u)};return typeof n!="string"&&(u=t,t=n,n=undefined),t&&n!==!1&&this.queue(n||"fx",[]),this.each(function(){var s=!0,t=n!=null&&n+"queueHooks",o=i.timers,e=r.get(this);if(t)e[t]&&e[t].stop&&f(e[t]);else for(t in e)e[t]&&e[t].stop&&ff.test(t)&&f(e[t]);for(t=o.length;t--;)o[t].elem===this&&(n==null||o[t].queue===n)&&(o[t].anim.stop(u),s=!1,o.splice(t,1));(s||!u)&&i.dequeue(this,n)})},finish:function(n){return n!==!1&&(n=n||"fx"),this.each(function(){var t,e=r.get(this),u=e[n+"queue"],o=e[n+"queueHooks"],f=i.timers,s=u?u.length:0;for(e.finish=!0,i.queue(this,n,[]),o&&o.stop&&o.stop.call(this,!0),t=f.length;t--;)f[t].elem===this&&f[t].queue===n&&(f[t].anim.stop(!0),f.splice(t,1));for(t=0;t<s;t++)u[t]&&u[t].finish&&u[t].finish.call(this);delete e.finish})}});i.each(["toggle","show","hide"],function(n,t){var r=i.fn[t];i.fn[t]=function(n,i,u){return n==null||typeof n=="boolean"?r.apply(this,arguments):this.animate(hi(t,!0),n,i,u)}});i.each({slideDown:hi("show"),slideUp:hi("hide"),slideToggle:hi("toggle"),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"},fadeToggle:{opacity:"toggle"}},function(n,t){i.fn[n]=function(n,i,r){return this.animate(t,n,i,r)}});i.timers=[];i.fx.tick=function(){var r,n=0,t=i.timers;for(ct=Date.now();n<t.length;n++)r=t[n],r()||t[n]!==r||t.splice(n--,1);t.length||i.fx.stop();ct=undefined};i.fx.timer=function(n){i.timers.push(n);i.fx.start()};i.fx.interval=13;i.fx.start=function(){si||(si=!0,tr())};i.fx.stop=function(){si=null};i.fx.speeds={slow:600,fast:200,_default:400};i.fn.delay=function(t,r){return t=i.fx?i.fx.speeds[t]||t:t,r=r||"fx",this.queue(r,function(i,r){var u=n.setTimeout(i,t);r.stop=function(){n.clearTimeout(u)}})},function(){var n=f.createElement("input"),t=f.createElement("select"),i=t.appendChild(f.createElement("option"));n.type="checkbox";e.checkOn=n.value!=="";e.optSelected=i.selected;n=f.createElement("input");n.value="t";n.type="radio";e.radioValue=n.value==="t"}();lt=i.expr.attrHandle;i.fn.extend({attr:function(n,t){return p(this,i.attr,n,t,arguments.length>1)},removeAttr:function(n){return this.each(function(){i.removeAttr(this,n)})}});i.extend({attr:function(n,t,r){var u,f,e=n.nodeType;if(e!==3&&e!==8&&e!==2){if(typeof n.getAttribute=="undefined")return i.prop(n,t,r);if(e===1&&i.isXMLDoc(n)||(f=i.attrHooks[t.toLowerCase()]||(i.expr.match.bool.test(t)?sf:undefined)),r!==undefined){if(r===null){i.removeAttr(n,t);return}return f&&"set"in f&&(u=f.set(n,r,t))!==undefined?u:(n.setAttribute(t,r+""),r)}return f&&"get"in f&&(u=f.get(n,t))!==null?u:(u=i.find.attr(n,t),u==null?undefined:u)}},attrHooks:{type:{set:function(n,t){if(!e.radioValue&&t==="radio"&&l(n,"input")){var i=n.value;return n.setAttribute("type",t),i&&(n.value=i),t}}}},removeAttr:function(n,t){var i,u=0,r=t&&t.match(a);if(r&&n.nodeType===1)while(i=r[u++])n.removeAttribute(i)}});sf={set:function(n,t,r){return t===!1?i.removeAttr(n,r):n.setAttribute(r,r),r}};i.each(i.expr.match.bool.source.match(/\w+/g),function(n,t){var r=lt[t]||i.find.attr;lt[t]=function(n,t,i){var f,e,u=t.toLowerCase();return i||(e=lt[u],lt[u]=f,f=r(n,t,i)!=null?u:null,lt[u]=e),f}});hf=/^(?:input|select|textarea|button)$/i;cf=/^(?:a|area)$/i;i.fn.extend({prop:function(n,t){return p(this,i.prop,n,t,arguments.length>1)},removeProp:function(n){return this.each(function(){delete this[i.propFix[n]||n]})}});i.extend({prop:function(n,t,r){var f,u,e=n.nodeType;if(e!==3&&e!==8&&e!==2)return(e===1&&i.isXMLDoc(n)||(t=i.propFix[t]||t,u=i.propHooks[t]),r!==undefined)?u&&"set"in u&&(f=u.set(n,r,t))!==undefined?f:n[t]=r:u&&"get"in u&&(f=u.get(n,t))!==null?f:n[t]},propHooks:{tabIndex:{get:function(n){var t=i.find.attr(n,"tabindex");return t?parseInt(t,10):hf.test(n.nodeName)||cf.test(n.nodeName)&&n.href?0:-1}}},propFix:{"for":"htmlFor","class":"className"}});e.optSelected||(i.propHooks.selected={get:function(n){var t=n.parentNode;return t&&t.parentNode&&t.parentNode.selectedIndex,null},set:function(n){var t=n.parentNode;t&&(t.selectedIndex,t.parentNode&&t.parentNode.selectedIndex)}});i.each(["tabIndex","readOnly","maxLength","cellSpacing","cellPadding","rowSpan","colSpan","useMap","frameBorder","contentEditable"],function(){i.propFix[this.toLowerCase()]=this});i.fn.extend({addClass:function(n){var f,r,t,e,o,h,s,c=0;if(u(n))return this.each(function(t){i(this).addClass(n.call(this,t,nt(this)))});if(f=ir(n),f.length)while(r=this[c++])if(e=nt(r),t=r.nodeType===1&&" "+g(e)+" ",t){for(h=0;o=f[h++];)t.indexOf(" "+o+" ")<0&&(t+=o+" ");s=g(t);e!==s&&r.setAttribute("class",s)}return this},removeClass:function(n){var f,r,t,e,o,h,s,c=0;if(u(n))return this.each(function(t){i(this).removeClass(n.call(this,t,nt(this)))});if(!arguments.length)return this.attr("class","");if(f=ir(n),f.length)while(r=this[c++])if(e=nt(r),t=r.nodeType===1&&" "+g(e)+" ",t){for(h=0;o=f[h++];)while(t.indexOf(" "+o+" ")>-1)t=t.replace(" "+o+" "," ");s=g(t);e!==s&&r.setAttribute("class",s)}return this},toggleClass:function(n,t){var f=typeof n,e=f==="string"||Array.isArray(n);return typeof t=="boolean"&&e?t?this.addClass(n):this.removeClass(n):u(n)?this.each(function(r){i(this).toggleClass(n.call(this,r,nt(this),t),t)}):this.each(function(){var t,o,u,s;if(e)for(o=0,u=i(this),s=ir(n);t=s[o++];)u.hasClass(t)?u.removeClass(t):u.addClass(t);else(n===undefined||f==="boolean")&&(t=nt(this),t&&r.set(this,"__className__",t),this.setAttribute&&this.setAttribute("class",t||n===!1?"":r.get(this,"__className__")||""))})},hasClass:function(n){for(var t,r=0,i=" "+n+" ";t=this[r++];)if(t.nodeType===1&&(" "+g(nt(t))+" ").indexOf(i)>-1)return!0;return!1}});lf=/\r/g;i.fn.extend({val:function(n){var t,r,e,f=this[0];return arguments.length?(e=u(n),this.each(function(r){var u;this.nodeType===1&&(u=e?n.call(this,r,i(this).val()):n,u==null?u="":typeof u=="number"?u+="":Array.isArray(u)&&(u=i.map(u,function(n){return n==null?"":n+""})),t=i.valHooks[this.type]||i.valHooks[this.nodeName.toLowerCase()],t&&"set"in t&&t.set(this,u,"value")!==undefined||(this.value=u))})):f?(t=i.valHooks[f.type]||i.valHooks[f.nodeName.toLowerCase()],t&&"get"in t&&(r=t.get(f,"value"))!==undefined)?r:(r=f.value,typeof r=="string")?r.replace(lf,""):r==null?"":r:void 0}});i.extend({valHooks:{option:{get:function(n){var t=i.find.attr(n,"value");return t!=null?t:g(i.text(n))}},select:{get:function(n){for(var e,t,o=n.options,u=n.selectedIndex,f=n.type==="select-one",s=f?null:[],h=f?u+1:o.length,r=u<0?h:f?u:0;r<h;r++)if(t=o[r],(t.selected||r===u)&&!t.disabled&&(!t.parentNode.disabled||!l(t.parentNode,"optgroup"))){if(e=i(t).val(),f)return e;s.push(e)}return s},set:function(n,t){for(var u,r,f=n.options,e=i.makeArray(t),o=f.length;o--;)r=f[o],(r.selected=i.inArray(i.valHooks.option.get(r),e)>-1)&&(u=!0);return u||(n.selectedIndex=-1),e}}}});i.each(["radio","checkbox"],function(){i.valHooks[this]={set:function(n,t){if(Array.isArray(t))return n.checked=i.inArray(i(n).val(),t)>-1}};e.checkOn||(i.valHooks[this].get=function(n){return n.getAttribute("value")===null?"on":n.value})});e.focusin="onfocusin"in n;rr=/^(?:focusinfocus|focusoutblur)$/;ur=function(n){n.stopPropagation()};i.extend(i.event,{trigger:function(t,e,o,s){var k,c,l,d,v,y,a,w,b=[o||f],h=ii.call(t,"type")?t.type:t,p=ii.call(t,"namespace")?t.namespace.split("."):[];if((c=w=l=o=o||f,o.nodeType!==3&&o.nodeType!==8)&&!rr.test(h+i.event.triggered)&&(h.indexOf(".")>-1&&(p=h.split("."),h=p.shift(),p.sort()),v=h.indexOf(":")<0&&"on"+h,t=t[i.expando]?t:new i.Event(h,typeof t=="object"&&t),t.isTrigger=s?2:3,t.namespace=p.join("."),t.rnamespace=t.namespace?new RegExp("(^|\\.)"+p.join("\\.(?:.*\\.|)")+"(\\.|$)"):null,t.result=undefined,t.target||(t.target=o),e=e==null?[t]:i.makeArray(e,[t]),a=i.event.special[h]||{},s||!a.trigger||a.trigger.apply(o,e)!==!1)){if(!s&&!a.noBubble&&!tt(o)){for(d=a.delegateType||h,rr.test(d+h)||(c=c.parentNode);c;c=c.parentNode)b.push(c),l=c;l===(o.ownerDocument||f)&&b.push(l.defaultView||l.parentWindow||n)}for(k=0;(c=b[k++])&&!t.isPropagationStopped();)w=c,t.type=k>1?d:a.bindType||h,y=(r.get(c,"events")||{})[t.type]&&r.get(c,"handle"),y&&y.apply(c,e),y=v&&c[v],y&&y.apply&&vt(c)&&(t.result=y.apply(c,e),t.result===!1&&t.preventDefault());return t.type=h,s||t.isDefaultPrevented()||(!a._default||a._default.apply(b.pop(),e)===!1)&&vt(o)&&v&&u(o[h])&&!tt(o)&&(l=o[v],l&&(o[v]=null),i.event.triggered=h,t.isPropagationStopped()&&w.addEventListener(h,ur),o[h](),t.isPropagationStopped()&&w.removeEventListener(h,ur),i.event.triggered=undefined,l&&(o[v]=l)),t.result}},simulate:function(n,t,r){var u=i.extend(new i.Event,r,{type:n,isSimulated:!0});i.event.trigger(u,null,t)}});i.fn.extend({trigger:function(n,t){return this.each(function(){i.event.trigger(n,t,this)})},triggerHandler:function(n,t){var r=this[0];if(r)return i.event.trigger(n,t,r,!0)}});e.focusin||i.each({focus:"focusin",blur:"focusout"},function(n,t){var u=function(n){i.event.simulate(t,n.target,i.event.fix(n))};i.event.special[t]={setup:function(){var i=this.ownerDocument||this,f=r.access(i,t);f||i.addEventListener(n,u,!0);r.access(i,t,(f||0)+1)},teardown:function(){var i=this.ownerDocument||this,f=r.access(i,t)-1;f?r.access(i,t,f):(i.removeEventListener(n,u,!0),r.remove(i,t))}}});var gt=n.location,af=Date.now(),fr=/\?/;i.parseXML=function(t){var r;if(!t||typeof t!="string")return null;try{r=(new n.DOMParser).parseFromString(t,"text/xml")}catch(u){r=undefined}return(!r||r.getElementsByTagName("parsererror").length)&&i.error("Invalid XML: "+t),r};var ho=/\[\]$/,vf=/\r?\n/g,co=/^(?:submit|button|image|reset|file)$/i,lo=/^(?:input|select|textarea|keygen)/i;i.param=function(n,t){var r,f=[],e=function(n,t){var i=u(t)?t():t;f[f.length]=encodeURIComponent(n)+"="+encodeURIComponent(i==null?"":i)};if(n==null)return"";if(Array.isArray(n)||n.jquery&&!i.isPlainObject(n))i.each(n,function(){e(this.name,this.value)});else for(r in n)er(r,n[r],t,e);return f.join("&")};i.fn.extend({serialize:function(){return i.param(this.serializeArray())},serializeArray:function(){return this.map(function(){var n=i.prop(this,"elements");return n?i.makeArray(n):this}).filter(function(){var n=this.type;return this.name&&!i(this).is(":disabled")&&lo.test(this.nodeName)&&!co.test(n)&&(this.checked||!kt.test(n))}).map(function(n,t){var r=i(this).val();return r==null?null:Array.isArray(r)?i.map(r,function(n){return{name:t.name,value:n.replace(vf,"\r\n")}}):{name:t.name,value:r.replace(vf,"\r\n")}}).get()}});var ao=/%20/g,vo=/#.*$/,yo=/([?&])_=[^&]*/,po=/^(.*?):[ \t]*([^\r\n]*)$/mg,wo=/^(?:GET|HEAD)$/,bo=/^\/\//,yf={},or={},pf="*/".concat("*"),sr=f.createElement("a");return sr.href=gt.href,i.extend({active:0,lastModified:{},etag:{},ajaxSettings:{url:gt.href,type:"GET",isLocal:/^(?:about|app|app-storage|.+-extension|file|res|widget):$/.test(gt.protocol),global:!0,processData:!0,async:!0,contentType:"application/x-www-form-urlencoded; charset=UTF-8",accepts:{"*":pf,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":i.parseXML},flatOptions:{url:!0,context:!0}},ajaxSetup:function(n,t){return t?hr(hr(n,i.ajaxSettings),t):hr(i.ajaxSettings,n)},ajaxPrefilter:wf(yf),ajaxTransport:wf(or),ajax:function(t,r){function b(t,r,f,l){var v,rt,g,p,b,a=r;s||(s=!0,d&&n.clearTimeout(d),c=undefined,k=l||"",e.readyState=t>0?4:0,v=t>=200&&t<300||t===304,f&&(p=ko(u,e,f)),p=go(u,p,e,v),v?(u.ifModified&&(b=e.getResponseHeader("Last-Modified"),b&&(i.lastModified[o]=b),b=e.getResponseHeader("etag"),b&&(i.etag[o]=b)),t===204||u.type==="HEAD"?a="nocontent":t===304?a="notmodified":(a=p.state,rt=p.data,g=p.error,v=!g)):(g=a,(t||!a)&&(a="error",t<0&&(t=0))),e.status=t,e.statusText=(r||a)+"",v?tt.resolveWith(h,[rt,a,e]):tt.rejectWith(h,[e,a,g]),e.statusCode(w),w=undefined,y&&nt.trigger(v?"ajaxSuccess":"ajaxError",[e,u,v?rt:g]),it.fireWith(h,[e,a]),y&&(nt.trigger("ajaxComplete",[e,u]),--i.active||i.event.trigger("ajaxStop")))}typeof t=="object"&&(r=t,t=undefined);r=r||{};var c,o,k,v,d,l,s,y,g,p,u=i.ajaxSetup({},r),h=u.context||u,nt=u.context&&(h.nodeType||h.jquery)?i(h):i.event,tt=i.Deferred(),it=i.Callbacks("once memory"),w=u.statusCode||{},rt={},ut={},ft="canceled",e={readyState:0,getResponseHeader:function(n){var t;if(s){if(!v)for(v={};t=po.exec(k);)v[t[1].toLowerCase()+" "]=(v[t[1].toLowerCase()+" "]||[]).concat(t[2]);t=v[n.toLowerCase()+" "]}return t==null?null:t.join(", ")},getAllResponseHeaders:function(){return s?k:null},setRequestHeader:function(n,t){return s==null&&(n=ut[n.toLowerCase()]=ut[n.toLowerCase()]||n,rt[n]=t),this},overrideMimeType:function(n){return s==null&&(u.mimeType=n),this},statusCode:function(n){var t;if(n)if(s)e.always(n[e.status]);else for(t in n)w[t]=[w[t],n[t]];return this},abort:function(n){var t=n||ft;return c&&c.abort(t),b(0,t),this}};if(tt.promise(e),u.url=((t||u.url||gt.href)+"").replace(bo,gt.protocol+"//"),u.type=r.method||r.type||u.method||u.type,u.dataTypes=(u.dataType||"*").toLowerCase().match(a)||[""],u.crossDomain==null){l=f.createElement("a");try{l.href=u.url;l.href=l.href;u.crossDomain=sr.protocol+"//"+sr.host!=l.protocol+"//"+l.host}catch(et){u.crossDomain=!0}}if(u.data&&u.processData&&typeof u.data!="string"&&(u.data=i.param(u.data,u.traditional)),bf(yf,u,r,e),s)return e;y=i.event&&u.global;y&&i.active++==0&&i.event.trigger("ajaxStart");u.type=u.type.toUpperCase();u.hasContent=!wo.test(u.type);o=u.url.replace(vo,"");u.hasContent?u.data&&u.processData&&(u.contentType||"").indexOf("application/x-www-form-urlencoded")===0&&(u.data=u.data.replace(ao,"+")):(p=u.url.slice(o.length),u.data&&(u.processData||typeof u.data=="string")&&(o+=(fr.test(o)?"&":"?")+u.data,delete u.data),u.cache===!1&&(o=o.replace(yo,"$1"),p=(fr.test(o)?"&":"?")+"_="+af+++p),u.url=o+p);u.ifModified&&(i.lastModified[o]&&e.setRequestHeader("If-Modified-Since",i.lastModified[o]),i.etag[o]&&e.setRequestHeader("If-None-Match",i.etag[o]));(u.data&&u.hasContent&&u.contentType!==!1||r.contentType)&&e.setRequestHeader("Content-Type",u.contentType);e.setRequestHeader("Accept",u.dataTypes[0]&&u.accepts[u.dataTypes[0]]?u.accepts[u.dataTypes[0]]+(u.dataTypes[0]!=="*"?", "+pf+"; q=0.01":""):u.accepts["*"]);for(g in u.headers)e.setRequestHeader(g,u.headers[g]);if(u.beforeSend&&(u.beforeSend.call(h,e,u)===!1||s))return e.abort();if(ft="abort",it.add(u.complete),e.done(u.success),e.fail(u.error),c=bf(or,u,r,e),c){if(e.readyState=1,y&&nt.trigger("ajaxSend",[e,u]),s)return e;u.async&&u.timeout>0&&(d=n.setTimeout(function(){e.abort("timeout")},u.timeout));try{s=!1;c.send(rt,b)}catch(et){if(s)throw et;b(-1,et)}}else b(-1,"No Transport");return e},getJSON:function(n,t,r){return i.get(n,t,r,"json")},getScript:function(n,t){return i.get(n,undefined,t,"script")}}),i.each(["get","post"],function(n,t){i[t]=function(n,r,f,e){return u(r)&&(e=e||f,f=r,r=undefined),i.ajax(i.extend({url:n,type:t,dataType:e,data:r,success:f},i.isPlainObject(n)&&n))}}),i._evalUrl=function(n,t){return i.ajax({url:n,type:"GET",dataType:"script",cache:!0,async:!1,global:!1,converters:{"text script":function(){}},dataFilter:function(n){i.globalEval(n,t)}})},i.fn.extend({wrapAll:function(n){var t;return this[0]&&(u(n)&&(n=n.call(this[0])),t=i(n,this[0].ownerDocument).eq(0).clone(!0),this[0].parentNode&&t.insertBefore(this[0]),t.map(function(){for(var n=this;n.firstElementChild;)n=n.firstElementChild;return n}).append(this)),this},wrapInner:function(n){return u(n)?this.each(function(t){i(this).wrapInner(n.call(this,t))}):this.each(function(){var t=i(this),r=t.contents();r.length?r.wrapAll(n):t.append(n)})},wrap:function(n){var t=u(n);return this.each(function(r){i(this).wrapAll(t?n.call(this,r):n)})},unwrap:function(n){return this.parent(n).not("body").each(function(){i(this).replaceWith(this.childNodes)}),this}}),i.expr.pseudos.hidden=function(n){return!i.expr.pseudos.visible(n)},i.expr.pseudos.visible=function(n){return!!(n.offsetWidth||n.offsetHeight||n.getClientRects().length)},i.ajaxSettings.xhr=function(){try{return new n.XMLHttpRequest}catch(t){}},kf={0:200,1223:204},at=i.ajaxSettings.xhr(),e.cors=!!at&&"withCredentials"in at,e.ajax=at=!!at,i.ajaxTransport(function(t){var i,r;if(e.cors||at&&!t.crossDomain)return{send:function(u,f){var o,e=t.xhr();if(e.open(t.type,t.url,t.async,t.username,t.password),t.xhrFields)for(o in t.xhrFields)e[o]=t.xhrFields[o];t.mimeType&&e.overrideMimeType&&e.overrideMimeType(t.mimeType);t.crossDomain||u["X-Requested-With"]||(u["X-Requested-With"]="XMLHttpRequest");for(o in u)e.setRequestHeader(o,u[o]);i=function(n){return function(){i&&(i=r=e.onload=e.onerror=e.onabort=e.ontimeout=e.onreadystatechange=null,n==="abort"?e.abort():n==="error"?typeof e.status!="number"?f(0,"error"):f(e.status,e.statusText):f(kf[e.status]||e.status,e.statusText,(e.responseType||"text")!=="text"||typeof e.responseText!="string"?{binary:e.response}:{text:e.responseText},e.getAllResponseHeaders()))}};e.onload=i();r=e.onerror=e.ontimeout=i("error");e.onabort!==undefined?e.onabort=r:e.onreadystatechange=function(){e.readyState===4&&n.setTimeout(function(){i&&r()})};i=i("abort");try{e.send(t.hasContent&&t.data||null)}catch(s){if(i)throw s;}},abort:function(){i&&i()}}}),i.ajaxPrefilter(function(n){n.crossDomain&&(n.contents.script=!1)}),i.ajaxSetup({accepts:{script:"text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"},contents:{script:/\b(?:java|ecma)script\b/},converters:{"text script":function(n){return i.globalEval(n),n}}}),i.ajaxPrefilter("script",function(n){n.cache===undefined&&(n.cache=!1);n.crossDomain&&(n.type="GET")}),i.ajaxTransport("script",function(n){if(n.crossDomain||n.scriptAttrs){var r,t;return{send:function(u,e){r=i("<script>").attr(n.scriptAttrs||{}).prop({charset:n.scriptCharset,src:n.url}).on("load error",t=function(n){r.remove();t=null;n&&e(n.type==="error"?404:200,n.type)});f.head.appendChild(r[0])},abort:function(){t&&t()}}}}),cr=[],ci=/(=)\?(?=&|$)|\?\?/,i.ajaxSetup({jsonp:"callback",jsonpCallback:function(){var n=cr.pop()||i.expando+"_"+af++;return this[n]=!0,n}}),i.ajaxPrefilter("json jsonp",function(t,r,f){var e,o,s,h=t.jsonp!==!1&&(ci.test(t.url)?"url":typeof t.data=="string"&&(t.contentType||"").indexOf("application/x-www-form-urlencoded")===0&&ci.test(t.data)&&"data");if(h||t.dataTypes[0]==="jsonp")return e=t.jsonpCallback=u(t.jsonpCallback)?t.jsonpCallback():t.jsonpCallback,h?t[h]=t[h].replace(ci,"$1"+e):t.jsonp!==!1&&(t.url+=(fr.test(t.url)?"&":"?")+t.jsonp+"="+e),t.converters["script json"]=function(){return s||i.error(e+" was not called"),s[0]},t.dataTypes[0]="json",o=n[e],n[e]=function(){s=arguments},f.always(function(){o===undefined?i(n).removeProp(e):n[e]=o;t[e]&&(t.jsonpCallback=r.jsonpCallback,cr.push(e));s&&u(o)&&o(s[0]);s=o=undefined}),"script"}),e.createHTMLDocument=function(){var n=f.implementation.createHTMLDocument("").body;return n.innerHTML="<form><\/form><form><\/form>",n.childNodes.length===2}(),i.parseHTML=function(n,t,r){if(typeof n!="string")return[];typeof t=="boolean"&&(r=t,t=!1);var s,u,o;return(t||(e.createHTMLDocument?(t=f.implementation.createHTMLDocument(""),s=t.createElement("base"),s.href=f.location.href,t.head.appendChild(s)):t=f),u=vi.exec(n),o=!r&&[],u)?[t.createElement(u[1])]:(u=lu([n],t,o),o&&o.length&&i(o).remove(),i.merge([],u.childNodes))},i.fn.load=function(n,t,r){var f,s,h,e=this,o=n.indexOf(" ");return o>-1&&(f=g(n.slice(o)),n=n.slice(0,o)),u(t)?(r=t,t=undefined):t&&typeof t=="object"&&(s="POST"),e.length>0&&i.ajax({url:n,type:s||"GET",dataType:"html",data:t}).done(function(n){h=arguments;e.html(f?i("<div>").append(i.parseHTML(n)).find(f):n)}).always(r&&function(n,t){e.each(function(){r.apply(this,h||[n.responseText,t,n])})}),this},i.each(["ajaxStart","ajaxStop","ajaxComplete","ajaxError","ajaxSuccess","ajaxSend"],function(n,t){i.fn[t]=function(n){return this.on(t,n)}}),i.expr.pseudos.animated=function(n){return i.grep(i.timers,function(t){return n===t.elem}).length},i.offset={setOffset:function(n,t,r){var o,s,h,c,f,l,y,a=i.css(n,"position"),v=i(n),e={};a==="static"&&(n.style.position="relative");f=v.offset();h=i.css(n,"top");l=i.css(n,"left");y=(a==="absolute"||a==="fixed")&&(h+l).indexOf("auto")>-1;y?(o=v.position(),c=o.top,s=o.left):(c=parseFloat(h)||0,s=parseFloat(l)||0);u(t)&&(t=t.call(n,r,i.extend({},f)));t.top!=null&&(e.top=t.top-f.top+c);t.left!=null&&(e.left=t.left-f.left+s);"using"in t?t.using.call(n,e):v.css(e)}},i.fn.extend({offset:function(n){if(arguments.length)return n===undefined?this:this.each(function(t){i.offset.setOffset(this,n,t)});var r,u,t=this[0];if(t)return t.getClientRects().length?(r=t.getBoundingClientRect(),u=t.ownerDocument.defaultView,{top:r.top+u.pageYOffset,left:r.left+u.pageXOffset}):{top:0,left:0}},position:function(){if(this[0]){var n,u,f,t=this[0],r={top:0,left:0};if(i.css(t,"position")==="fixed")u=t.getBoundingClientRect();else{for(u=this.offset(),f=t.ownerDocument,n=t.offsetParent||f.documentElement;n&&(n===f.body||n===f.documentElement)&&i.css(n,"position")==="static";)n=n.parentNode;n&&n!==t&&n.nodeType===1&&(r=i(n).offset(),r.top+=i.css(n,"borderTopWidth",!0),r.left+=i.css(n,"borderLeftWidth",!0))}return{top:u.top-r.top-i.css(t,"marginTop",!0),left:u.left-r.left-i.css(t,"marginLeft",!0)}}},offsetParent:function(){return this.map(function(){for(var n=this.offsetParent;n&&i.css(n,"position")==="static";)n=n.offsetParent;return n||wt})}}),i.each({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},function(n,t){var r="pageYOffset"===t;i.fn[n]=function(i){return p(this,function(n,i,u){var f;if(tt(n)?f=n:n.nodeType===9&&(f=n.defaultView),u===undefined)return f?f[t]:n[i];f?f.scrollTo(r?f.pageXOffset:u,r?u:f.pageYOffset):n[i]=u},n,i,arguments.length)}}),i.each(["top","left"],function(n,t){i.cssHooks[t]=wu(e.pixelPosition,function(n,r){if(r)return r=dt(n,t),di.test(r)?i(n).position()[t]+"px":r})}),i.each({Height:"height",Width:"width"},function(n,t){i.each({padding:"inner"+n,content:t,"":"outer"+n},function(r,u){i.fn[u]=function(f,e){var o=arguments.length&&(r||typeof f!="boolean"),s=r||(f===!0||e===!0?"margin":"border");return p(this,function(t,r,f){var e;return tt(t)?u.indexOf("outer")===0?t["inner"+n]:t.document.documentElement["client"+n]:t.nodeType===9?(e=t.documentElement,Math.max(t.body["scroll"+n],e["scroll"+n],t.body["offset"+n],e["offset"+n],e["client"+n])):f===undefined?i.css(t,r,s):i.style(t,r,f,s)},t,o?f:undefined,o)}})}),i.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(n,t){i.fn[t]=function(n,i){return arguments.length>0?this.on(t,null,n,i):this.trigger(t)}}),i.fn.extend({hover:function(n,t){return this.mouseenter(n).mouseleave(t||n)}}),i.fn.extend({bind:function(n,t,i){return this.on(n,null,t,i)},unbind:function(n,t){return this.off(n,null,t)},delegate:function(n,t,i,r){return this.on(t,n,i,r)},undelegate:function(n,t,i){return arguments.length===1?this.off(n,"**"):this.off(t,n||"**",i)}}),i.proxy=function(n,t){var f,e,r;return(typeof t=="string"&&(f=n[t],t=n,n=f),!u(n))?undefined:(e=b.call(arguments,2),r=function(){return n.apply(t||this,e.concat(b.call(arguments)))},r.guid=n.guid=n.guid||i.guid++,r)},i.holdReady=function(n){n?i.readyWait++:i.ready(!0)},i.isArray=Array.isArray,i.parseJSON=JSON.parse,i.nodeName=l,i.isFunction=u,i.isWindow=tt,i.camelCase=y,i.type=it,i.now=Date.now,i.isNumeric=function(n){var t=i.type(n);return(t==="number"||t==="string")&&!isNaN(n-parseFloat(n))},typeof define=="function"&&define.amd&&define("jquery",[],function(){return i}),df=n.jQuery,gf=n.$,i.noConflict=function(t){return n.$===i&&(n.$=gf),t&&n.jQuery===i&&(n.jQuery=df),i},t||(n.jQuery=n.$=i),i}),function(n,t){typeof exports=="object"&&typeof module!="undefined"?module.exports=t():typeof define=="function"&&define.amd?define(t):n.Popper=t()}(this,function(){"use strict";function ei(n){var t=!1;return function(){t||(t=!0,window.Promise.resolve().then(function(){t=!1;n()}))}}function oi(n){var t=!1;return function(){t||(t=!0,setTimeout(function(){t=!1;n()},ot))}}function ct(n){return n&&{}.toString.call(n)==="[object Function]"}function i(n,t){if(n.nodeType!==1)return[];var r=n.ownerDocument.defaultView,i=r.getComputedStyle(n,null);return t?i[t]:i}function w(n){return n.nodeName==="HTML"?n:n.parentNode||n.host}function s(n){if(!n)return document.body;switch(n.nodeName){case"HTML":case"BODY":return n.ownerDocument.body;case"#document":return n.body}var t=i(n),r=t.overflow,u=t.overflowX,f=t.overflowY;return/(auto|scroll|overlay)/.test(r+f+u)?n:s(w(n))}function r(n){return n===11?b:n===10?k:b||k}function u(n){var e,t,f;if(!n)return document.documentElement;for(e=r(10)?document.body:null,t=n.offsetParent||null;t===e&&n.nextElementSibling;)t=(n=n.nextElementSibling).offsetParent;return(f=t&&t.nodeName,!f||f==="BODY"||f==="HTML")?n?n.ownerDocument.documentElement:document.documentElement:["TH","TD","TABLE"].indexOf(t.nodeName)!==-1&&i(t,"position")==="static"?u(t):t}function si(n){var t=n.nodeName;return t==="BODY"?!1:t==="HTML"||u(n.firstElementChild)===n}function d(n){return n.parentNode!==null?d(n.parentNode):n}function c(n,t){var i,f;if(!n||!n.nodeType||!t||!t.nodeType)return document.documentElement;var e=n.compareDocumentPosition(t)&Node.DOCUMENT_POSITION_FOLLOWING,o=e?n:t,s=e?t:n,r=document.createRange();return(r.setStart(o,0),r.setEnd(s,0),i=r.commonAncestorContainer,n!==i&&t!==i||o.contains(s))?si(i)?i:u(i):(f=d(n),f.host?c(f.host,t):c(n,d(t).host))}function f(n){var f=arguments.length>1&&arguments[1]!==undefined?arguments[1]:"top",t=f==="top"?"scrollTop":"scrollLeft",i=n.nodeName,r,u;return i==="BODY"||i==="HTML"?(r=n.ownerDocument.documentElement,u=n.ownerDocument.scrollingElement||r,u[t]):n[t]}function hi(n,t){var e=arguments.length>2&&arguments[2]!==undefined?arguments[2]:!1,r=f(t,"top"),u=f(t,"left"),i=e?-1:1;return n.top+=r*i,n.bottom+=r*i,n.left+=u*i,n.right+=u*i,n}function lt(n,t){var i=t==="x"?"Left":"Top",r=i==="Left"?"Right":"Bottom";return parseFloat(n["border"+i+"Width"],10)+parseFloat(n["border"+r+"Width"],10)}function at(n,t,i,u){return Math.max(t["offset"+n],t["scroll"+n],i["client"+n],i["offset"+n],i["scroll"+n],r(10)?parseInt(i["offset"+n])+parseInt(u["margin"+(n==="Height"?"Top":"Left")])+parseInt(u["margin"+(n==="Height"?"Bottom":"Right")]):0)}function vt(n){var i=n.body,t=n.documentElement,u=r(10)&&getComputedStyle(t);return{height:at("Height",i,t,u),width:at("Width",i,t,u)}}function t(t){return n({},t,{right:t.left+t.width,bottom:t.top+t.height})}function g(n){var u={},o,s,l;try{r(10)?(u=n.getBoundingClientRect(),o=f(n,"top"),s=f(n,"left"),u.top+=o,u.left+=s,u.bottom+=o,u.right+=s):u=n.getBoundingClientRect()}catch(p){}var e={left:u.left,top:u.top,width:u.right-u.left,height:u.bottom-u.top},a=n.nodeName==="HTML"?vt(n.ownerDocument):{},v=a.width||n.clientWidth||e.right-e.left,y=a.height||n.clientHeight||e.bottom-e.top,h=n.offsetWidth-v,c=n.offsetHeight-y;return(h||c)&&(l=i(n),h-=lt(l,"x"),c-=lt(l,"y"),e.width-=h,e.height-=c),t(e)}function nt(n,u){var p=arguments.length>2&&arguments[2]!==undefined?arguments[2]:!1,w=r(10),b=u.nodeName==="HTML",o=g(n),e=g(u),a=s(n),h=i(u),v=parseFloat(h.borderTopWidth,10),y=parseFloat(h.borderLeftWidth,10),f,c,l;return p&&b&&(e.top=Math.max(e.top,0),e.left=Math.max(e.left,0)),f=t({top:o.top-e.top-v,left:o.left-e.left-y,width:o.width,height:o.height}),f.marginTop=0,f.marginLeft=0,!w&&b&&(c=parseFloat(h.marginTop,10),l=parseFloat(h.marginLeft,10),f.top-=v-c,f.bottom-=v-c,f.left-=y-l,f.right-=y-l,f.marginTop=c,f.marginLeft=l),(w&&!p?u.contains(a):u===a&&a.nodeName!=="BODY")&&(f=hi(f,u)),f}function ai(n){var u=arguments.length>1&&arguments[1]!==undefined?arguments[1]:!1,i=n.ownerDocument.documentElement,r=nt(n,i),e=Math.max(i.clientWidth,window.innerWidth||0),o=Math.max(i.clientHeight,window.innerHeight||0),s=u?0:f(i),h=u?0:f(i,"left"),c={top:s-r.top+r.marginTop,left:h-r.left+r.marginLeft,width:e,height:o};return t(c)}function yt(n){var r=n.nodeName,t;return r==="BODY"||r==="HTML"?!1:i(n,"position")==="fixed"?!0:(t=w(n),!t)?!1:yt(t)}function pt(n){if(!n||!n.parentElement||r())return document.documentElement;for(var t=n.parentElement;t&&i(t,"transform")==="none";)t=t.parentElement;return t||document.documentElement}function tt(n,t,i,r){var h=arguments.length>4&&arguments[4]!==undefined?arguments[4]:!1,u={top:0,left:0},l=h?pt(n):c(n,t),e,f,o;if(r==="viewport")u=ai(l,h);else if(e=void 0,r==="scrollParent"?(e=s(w(t)),e.nodeName==="BODY"&&(e=n.ownerDocument.documentElement)):e=r==="window"?n.ownerDocument.documentElement:r,f=nt(e,l,h),e.nodeName!=="HTML"||yt(l))u=f;else{var a=vt(n.ownerDocument),v=a.height,y=a.width;u.top+=f.top-f.marginTop;u.bottom=v+f.top;u.left+=f.left-f.marginLeft;u.right=y+f.left}return i=i||0,o=typeof i=="number",u.left+=o?i:i.left||0,u.top+=o?i:i.top||0,u.right-=o?i:i.right||0,u.bottom-=o?i:i.bottom||0,u}function vi(n){var t=n.width,i=n.height;return t*i}function wt(t,i,r,u,f){var l=arguments.length>5&&arguments[5]!==undefined?arguments[5]:0;if(t.indexOf("auto")===-1)return t;var e=tt(r,u,l,f),o={top:{width:e.width,height:i.top-e.top},right:{width:e.right-i.right,height:e.height},bottom:{width:e.width,height:e.bottom-i.bottom},left:{width:i.left-e.left,height:e.height}},s=Object.keys(o).map(function(t){return n({key:t},o[t],{area:vi(o[t])})}).sort(function(n,t){return t.area-n.area}),h=s.filter(function(n){var t=n.width,i=n.height;return t>=r.clientWidth&&i>=r.clientHeight}),a=h.length>0?h[0].key:s[0].key,c=t.split("-")[1];return a+(c?"-"+c:"")}function bt(n,t,i){var r=arguments.length>3&&arguments[3]!==undefined?arguments[3]:null,u=r?pt(t):c(t,i);return nt(i,u,r)}function kt(n){var i=n.ownerDocument.defaultView,t=i.getComputedStyle(n),r=parseFloat(t.marginTop||0)+parseFloat(t.marginBottom||0),u=parseFloat(t.marginLeft||0)+parseFloat(t.marginRight||0);return{width:n.offsetWidth+u,height:n.offsetHeight+r}}function l(n){var t={left:"right",right:"left",bottom:"top",top:"bottom"};return n.replace(/left|right|bottom|top/g,function(n){return t[n]})}function dt(n,t,i){i=i.split("-")[0];var r=kt(n),e={width:r.width,height:r.height},u=["right","left"].indexOf(i)!==-1,o=u?"top":"left",f=u?"left":"top",s=u?"height":"width",h=u?"width":"height";return e[o]=t[o]+t[s]/2-r[s]/2,e[f]=i===f?t[f]-r[h]:t[l(f)],e}function h(n,t){return Array.prototype.find?n.find(t):n.filter(t)[0]}function yi(n,t,i){if(Array.prototype.findIndex)return n.findIndex(function(n){return n[t]===i});var r=h(n,function(n){return n[t]===i});return n.indexOf(r)}function gt(n,i,r){var u=r===undefined?n:n.slice(0,yi(n,"name",r));return u.forEach(function(n){n["function"]&&console.warn("`modifier.function` is deprecated, use `modifier.fn`!");var r=n["function"]||n.fn;n.enabled&&ct(r)&&(i.offsets.popper=t(i.offsets.popper),i.offsets.reference=t(i.offsets.reference),i=r(i,n))}),i}function pi(){if(!this.state.isDestroyed){var n={instance:this,styles:{},arrowStyles:{},attributes:{},flipped:!1,offsets:{}};if(n.offsets.reference=bt(this.state,this.popper,this.reference,this.options.positionFixed),n.placement=wt(this.options.placement,n.offsets.reference,this.popper,this.reference,this.options.modifiers.flip.boundariesElement,this.options.modifiers.flip.padding),n.originalPlacement=n.placement,n.positionFixed=this.options.positionFixed,n.offsets.popper=dt(this.popper,n.offsets.reference,n.placement),n.offsets.popper.position=this.options.positionFixed?"fixed":"absolute",n=gt(this.modifiers,n),this.state.isCreated)this.options.onUpdate(n);else{this.state.isCreated=!0;this.options.onCreate(n)}}}function ni(n,t){return n.some(function(n){var i=n.name,r=n.enabled;return r&&i===t})}function it(n){for(var i,r,u=[!1,"ms","Webkit","Moz","O"],f=n.charAt(0).toUpperCase()+n.slice(1),t=0;t<u.length;t++)if(i=u[t],r=i?""+i+f:n,typeof document.body.style[r]!="undefined")return r;return null}function wi(){return this.state.isDestroyed=!0,ni(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[it("transform")]=""),this.disableEventListeners(),this.options.removeOnDestroy&&this.popper.parentNode.removeChild(this.popper),this}function ti(n){var t=n.ownerDocument;return t?t.defaultView:window}function ii(n,t,i,r){var f=n.nodeName==="BODY",u=f?n.ownerDocument.defaultView:n;u.addEventListener(t,i,{passive:!0});f||ii(s(u.parentNode),t,i,r);r.push(u)}function bi(n,t,i,r){i.updateBound=r;ti(n).addEventListener("resize",i.updateBound,{passive:!0});var u=s(n);return ii(u,"scroll",i.updateBound,i.scrollParents),i.scrollElement=u,i.eventsEnabled=!0,i}function ki(){this.state.eventsEnabled||(this.state=bi(this.reference,this.options,this.state,this.scheduleUpdate))}function di(n,t){return ti(n).removeEventListener("resize",t.updateBound),t.scrollParents.forEach(function(n){n.removeEventListener("scroll",t.updateBound)}),t.updateBound=null,t.scrollParents=[],t.scrollElement=null,t.eventsEnabled=!1,t}function gi(){this.state.eventsEnabled&&(cancelAnimationFrame(this.scheduleUpdate),this.state=di(this.reference,this.state))}function rt(n){return n!==""&&!isNaN(parseFloat(n))&&isFinite(n)}function ut(n,t){Object.keys(t).forEach(function(i){var r="";["width","height","top","right","bottom","left"].indexOf(i)!==-1&&rt(t[i])&&(r="px");n.style[i]=t[i]+r})}function nr(n,t){Object.keys(t).forEach(function(i){var r=t[i];r!==!1?n.setAttribute(i,t[i]):n.removeAttribute(i)})}function tr(n){return ut(n.instance.popper,n.styles),nr(n.instance.popper,n.attributes),n.arrowElement&&Object.keys(n.arrowStyles).length&&ut(n.arrowElement,n.arrowStyles),n}function ir(n,t,i,r,u){var f=bt(u,t,n,i.positionFixed),e=wt(i.placement,f,t,n,i.modifiers.flip.boundariesElement,i.modifiers.flip.padding);return t.setAttribute("x-placement",e),ut(t,{position:i.positionFixed?"fixed":"absolute"}),i}function rr(n,t){var u=n.offsets,i=u.popper,l=u.reference,r=Math.round,a=Math.floor,f=function(n){return n},e=r(l.width),o=r(i.width),v=["left","right"].indexOf(n.placement)!==-1,s=n.placement.indexOf("-")!==-1,y=e%2==o%2,p=e%2==1&&o%2==1,h=t?v||s||y?r:a:f,c=t?r:f;return{left:h(p&&!s&&t?i.left-1:i.left),top:c(i.top),bottom:c(i.bottom),right:h(i.right)}}function ur(t,i){var k=i.x,d=i.y,nt=t.offsets.popper,c=h(t.instance.modifiers,function(n){return n.name==="applyStyle"}).gpuAcceleration,p,w,b;c!==undefined&&console.warn("WARNING: `gpuAcceleration` option moved to `computeStyle` modifier and will not be supported in future versions of Popper.js!");var tt=c!==undefined?c:i.gpuAcceleration,e=u(t.instance.popper),v=g(e),r={position:nt.position},f=rr(t,window.devicePixelRatio<2||!ri),o=k==="bottom"?"top":"bottom",s=d==="right"?"left":"right",y=it("transform"),l=void 0,a=void 0;return a=o==="bottom"?e.nodeName==="HTML"?-e.clientHeight+f.bottom:-v.height+f.bottom:f.top,l=s==="right"?e.nodeName==="HTML"?-e.clientWidth+f.right:-v.width+f.right:f.left,tt&&y?(r[y]="translate3d("+l+"px, "+a+"px, 0)",r[o]=0,r[s]=0,r.willChange="transform"):(p=o==="bottom"?-1:1,w=s==="right"?-1:1,r[o]=a*p,r[s]=l*w,r.willChange=o+", "+s),b={"x-placement":t.placement},t.attributes=n({},b,t.attributes),t.styles=n({},r,t.styles),t.arrowStyles=n({},t.offsets.arrow,t.arrowStyles),t}function ui(n,t,i){var u=h(n,function(n){var i=n.name;return i===t}),f=!!u&&n.some(function(n){return n.name===i&&n.enabled&&n.order<u.order}),r,e;return f||(r="`"+t+"`",e="`"+i+"`",console.warn(e+" modifier is required by "+r+" modifier in order to work, be sure to include it before "+r+"!")),f}function fr(n,r){var c,f;if(!ui(n.instance.modifiers,"arrow","keepTogether"))return n;if(f=r.element,typeof f=="string"){if(f=n.instance.popper.querySelector(f),!f)return n}else if(!n.instance.popper.contains(f))return console.warn("WARNING: `arrow.element` must be child of its popper element!"),n;var k=n.placement.split("-")[0],w=n.offsets,h=w.popper,o=w.reference,l=["left","right"].indexOf(k)!==-1,v=l?"height":"width",y=l?"Top":"Left",u=y.toLowerCase(),d=l?"left":"top",a=l?"bottom":"right",s=kt(f)[v];o[a]-s<h[u]&&(n.offsets.popper[u]-=h[u]-(o[a]-s));o[u]+s>h[a]&&(n.offsets.popper[u]+=o[u]+s-h[a]);n.offsets.popper=t(n.offsets.popper);var g=o[u]+o[v]/2-s/2,b=i(n.instance.popper),nt=parseFloat(b["margin"+y],10),tt=parseFloat(b["border"+y+"Width"],10),p=g-n.offsets.popper[u]-nt-tt;return p=Math.max(Math.min(h[v]-s,p),0),n.arrowElement=f,n.offsets.arrow=(c={},e(c,u,Math.round(p)),e(c,d,""),c),n}function er(n){return n==="end"?"start":n==="start"?"end":n}function fi(n){var r=arguments.length>1&&arguments[1]!==undefined?arguments[1]:!1,t=a.indexOf(n),i=a.slice(t+1).concat(a.slice(0,t));return r?i.reverse():i}function or(t,i){if(ni(t.instance.modifiers,"inner")||t.flipped&&t.placement===t.originalPlacement)return t;var e=tt(t.instance.popper,t.instance.reference,i.padding,i.boundariesElement,t.positionFixed),r=t.placement.split("-")[0],o=l(r),u=t.placement.split("-")[1]||"",f=[];switch(i.behavior){case v.FLIP:f=[r,o];break;case v.CLOCKWISE:f=fi(r);break;case v.COUNTERCLOCKWISE:f=fi(r,!0);break;default:f=i.behavior}return f.forEach(function(s,h){if(r!==s||f.length===h+1)return t;r=t.placement.split("-")[0];o=l(r);var a=t.offsets.popper,y=t.offsets.reference,c=Math.floor,d=r==="left"&&c(a.right)>c(y.left)||r==="right"&&c(a.left)<c(y.right)||r==="top"&&c(a.bottom)>c(y.top)||r==="bottom"&&c(a.top)<c(y.bottom),p=c(a.left)<c(e.left),w=c(a.right)>c(e.right),b=c(a.top)<c(e.top),k=c(a.bottom)>c(e.bottom),g=r==="left"&&p||r==="right"&&w||r==="top"&&b||r==="bottom"&&k,v=["top","bottom"].indexOf(r)!==-1,tt=!!i.flipVariations&&(v&&u==="start"&&p||v&&u==="end"&&w||!v&&u==="start"&&b||!v&&u==="end"&&k),it=!!i.flipVariationsByContent&&(v&&u==="start"&&w||v&&u==="end"&&p||!v&&u==="start"&&k||!v&&u==="end"&&b),nt=tt||it;(d||g||nt)&&(t.flipped=!0,(d||g)&&(r=f[h+1]),nt&&(u=er(u)),t.placement=r+(u?"-"+u:""),t.offsets.popper=n({},t.offsets.popper,dt(t.instance.popper,t.offsets.reference,t.placement)),t=gt(t.instance.modifiers,t,"flip"))}),t}function sr(n){var o=n.offsets,u=o.popper,i=o.reference,s=n.placement.split("-")[0],r=Math.floor,f=["top","bottom"].indexOf(s)!==-1,e=f?"right":"bottom",t=f?"left":"top",h=f?"width":"height";return u[e]<r(i[t])&&(n.offsets.popper[t]=r(i[t])-u[h]),u[t]>r(i[e])&&(n.offsets.popper[t]=r(i[e])),n}function hr(n,i,r,u){var h=n.match(/((?:\-|\+)?\d*\.?\d*)(.*)/),e=+h[1],f=h[2],o,c,s;if(!e)return n;if(f.indexOf("%")===0){o=void 0;switch(f){case"%p":o=r;break;case"%":case"%r":default:o=u}return c=t(o),c[i]/100*e}return f==="vh"||f==="vw"?(s=void 0,s=f==="vh"?Math.max(document.documentElement.clientHeight,window.innerHeight||0):Math.max(document.documentElement.clientWidth,window.innerWidth||0),s/100*e):e}function cr(n,t,i,r){var s=[0,0],c=["right","left"].indexOf(r)!==-1,u=n.split(/(\+|\-)/).map(function(n){return n.trim()}),f=u.indexOf(h(u,function(n){return n.search(/,|\s/)!==-1})),o,e;return u[f]&&u[f].indexOf(",")===-1&&console.warn("Offsets separated by white space(s) are deprecated, use a comma (,) instead."),o=/\s*,\s*|\s+/,e=f!==-1?[u.slice(0,f).concat([u[f].split(o)[0]]),[u[f].split(o)[1]].concat(u.slice(f+1))]:[u],e=e.map(function(n,r){var f=(r===1?!c:c)?"height":"width",u=!1;return n.reduce(function(n,t){return n[n.length-1]===""&&["+","-"].indexOf(t)!==-1?(n[n.length-1]=t,u=!0,n):u?(n[n.length-1]+=t,u=!1,n):n.concat(t)},[]).map(function(n){return hr(n,f,t,i)})}),e.forEach(function(n,t){n.forEach(function(i,r){rt(i)&&(s[t]+=i*(n[r-1]==="-"?-1:1))})}),s}function lr(n,t){var f=t.offset,o=n.placement,e=n.offsets,i=e.popper,s=e.reference,u=o.split("-")[0],r=void 0;return r=rt(+f)?[+f,0]:cr(f,i,s,u),u==="left"?(i.top+=r[0],i.left-=r[1]):u==="right"?(i.top+=r[0],i.left+=r[1]):u==="top"?(i.left+=r[0],i.top-=r[1]):u==="bottom"&&(i.left+=r[0],i.top+=r[1]),n.popper=i,n}function ar(t,i){var s=i.boundariesElement||u(t.instance.popper),o;t.instance.reference===s&&(s=u(s));var h=it("transform"),f=t.instance.popper.style,c=f.top,l=f.left,a=f[h];f.top="";f.left="";f[h]="";o=tt(t.instance.popper,t.instance.reference,i.padding,s,t.positionFixed);f.top=c;f.left=l;f[h]=a;i.boundaries=o;var v=i.priority,r=t.offsets.popper,y={primary:function(n){var t=r[n];return r[n]<o[n]&&!i.escapeWithReference&&(t=Math.max(r[n],o[n])),e({},n,t)},secondary:function(n){var t=n==="right"?"left":"top",u=r[t];return r[n]>o[n]&&!i.escapeWithReference&&(u=Math.min(r[t],o[n]-(n==="right"?r.width:r.height))),e({},t,u)}};return v.forEach(function(t){var i=["left","top"].indexOf(t)!==-1?"primary":"secondary";r=n({},r,y[i](t))}),t.offsets.popper=r,t}function vr(t){var u=t.placement,l=u.split("-")[0],f=u.split("-")[1];if(f){var o=t.offsets,r=o.reference,s=o.popper,h=["bottom","top"].indexOf(l)!==-1,i=h?"left":"top",c=h?"width":"height",a={start:e({},i,r[i]),end:e({},i,r[i]+r[c]-s[c])};t.offsets.popper=n({},s,a[f])}return t}function yr(n){if(!ui(n.instance.modifiers,"hide","preventOverflow"))return n;var t=n.offsets.reference,i=h(n.instance.modifiers,function(n){return n.name==="preventOverflow"}).boundaries;if(t.bottom<i.top||t.left>i.right||t.top>i.bottom||t.right<i.left){if(n.hide===!0)return n;n.hide=!0;n.attributes["x-out-of-boundaries"]=""}else{if(n.hide===!1)return n;n.hide=!1;n.attributes["x-out-of-boundaries"]=!1}return n}function pr(n){var u=n.placement,i=u.split("-")[0],f=n.offsets,r=f.popper,o=f.reference,e=["left","right"].indexOf(i)!==-1,s=["top","left"].indexOf(i)===-1;return r[e?"left":"top"]=o[i]-(s?r[e?"width":"height"]:0),n.placement=l(u),n.offsets.popper=t(r),n}for(var st,ht,b,k,ri,ft,a,v,o=typeof window!="undefined"&&typeof document!="undefined",et=["Edge","Trident","Firefox"],ot=0,p=0;p<et.length;p+=1)if(o&&navigator.userAgent.indexOf(et[p])>=0){ot=1;break}st=o&&window.Promise;ht=st?ei:oi;b=o&&!!(window.MSInputMethodContext&&document.documentMode);k=o&&/MSIE 10/.test(navigator.userAgent);var ci=function(n,t){if(!(n instanceof t))throw new TypeError("Cannot call a class as a function");},li=function(){function n(n,t){for(var i,r=0;r<t.length;r++)i=t[r],i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(n,i.key,i)}return function(t,i,r){return i&&n(t.prototype,i),r&&n(t,r),t}}(),e=function(n,t,i){return t in n?Object.defineProperty(n,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):n[t]=i,n},n=Object.assign||function(n){for(var i,r,t=1;t<arguments.length;t++){i=arguments[t];for(r in i)Object.prototype.hasOwnProperty.call(i,r)&&(n[r]=i[r])}return n};ri=o&&/Firefox/i.test(navigator.userAgent);ft=["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"];a=ft.slice(3);v={FLIP:"flip",CLOCKWISE:"clockwise",COUNTERCLOCKWISE:"counterclockwise"};var wr={shift:{order:100,enabled:!0,fn:vr},offset:{order:200,enabled:!0,fn:lr,offset:0},preventOverflow:{order:300,enabled:!0,fn:ar,priority:["left","right","top","bottom"],padding:5,boundariesElement:"scrollParent"},keepTogether:{order:400,enabled:!0,fn:sr},arrow:{order:500,enabled:!0,fn:fr,element:"[x-arrow]"},flip:{order:600,enabled:!0,fn:or,behavior:"flip",padding:5,boundariesElement:"viewport",flipVariations:!1,flipVariationsByContent:!1},inner:{order:700,enabled:!1,fn:pr},hide:{order:800,enabled:!0,fn:yr},computeStyle:{order:850,enabled:!0,fn:ur,gpuAcceleration:!0,x:"bottom",y:"right"},applyStyle:{order:900,enabled:!0,fn:tr,onLoad:ir,gpuAcceleration:undefined}},br={placement:"bottom",positionFixed:!1,eventsEnabled:!0,removeOnDestroy:!1,onCreate:function(){},onUpdate:function(){},modifiers:wr},y=function(){function t(i,r){var u=this,f=arguments.length>2&&arguments[2]!==undefined?arguments[2]:{},e;ci(this,t);this.scheduleUpdate=function(){return requestAnimationFrame(u.update)};this.update=ht(this.update.bind(this));this.options=n({},t.Defaults,f);this.state={isDestroyed:!1,isCreated:!1,scrollParents:[]};this.reference=i&&i.jquery?i[0]:i;this.popper=r&&r.jquery?r[0]:r;this.options.modifiers={};Object.keys(n({},t.Defaults.modifiers,f.modifiers)).forEach(function(i){u.options.modifiers[i]=n({},t.Defaults.modifiers[i]||{},f.modifiers?f.modifiers[i]:{})});this.modifiers=Object.keys(this.options.modifiers).map(function(t){return n({name:t},u.options.modifiers[t])}).sort(function(n,t){return n.order-t.order});this.modifiers.forEach(function(n){if(n.enabled&&ct(n.onLoad))n.onLoad(u.reference,u.popper,u.options,n,u.state)});this.update();e=this.options.eventsEnabled;e&&this.enableEventListeners();this.state.eventsEnabled=e}return li(t,[{key:"update",value:function(){return pi.call(this)}},{key:"destroy",value:function(){return wi.call(this)}},{key:"enableEventListeners",value:function(){return ki.call(this)}},{key:"disableEventListeners",value:function(){return gi.call(this)}}]),t}();return y.Utils=(typeof window!="undefined"?window:global).PopperUtils,y.placements=ft,y.Defaults=br,y}),function(n,t){typeof exports=="object"&&typeof module!="undefined"?t(exports,require("jquery"),require("popper.js")):typeof define=="function"&&define.amd?define(["exports","jquery","popper.js"],t):(n=n||self,t(n.bootstrap={},n.jQuery,n.Popper))}(this,function(n,t,i){"use strict";function eu(n,t){for(var i,r=0;r<t.length;r++)i=t[r],i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(n,i.key,i)}function p(n,t,i){return t&&eu(n.prototype,t),i&&eu(n,i),n}function gu(n,t,i){return t in n?Object.defineProperty(n,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):n[t]=i,n}function o(n){for(var i,r,t=1;t<arguments.length;t++)i=arguments[t]!=null?arguments[t]:{},r=Object.keys(i),typeof Object.getOwnPropertySymbols=="function"&&(r=r.concat(Object.getOwnPropertySymbols(i).filter(function(n){return Object.getOwnPropertyDescriptor(i,n).enumerable}))),r.forEach(function(t){gu(n,t,i[t])});return n}function nf(n,t){n.prototype=Object.create(t.prototype);n.prototype.constructor=n;n.__proto__=t}function uf(n){return{}.toString.call(n).match(/\s([a-z]+)/i)[1].toLowerCase()}function ff(){return{bindType:nr,delegateType:nr,handle:function(n){return t(n.target).is(this)?n.handleObj.handler.apply(this,arguments):undefined}}}function ef(n){var u=this,i=!1;t(this).one(r.TRANSITION_END,function(){i=!0});return setTimeout(function(){i||r.triggerTransitionEnd(u)},n),this}function of(){t.fn.emulateTransitionEnd=ef;t.event.special[r.TRANSITION_END]=ff()}function ye(n,t){var r=n.nodeName.toLowerCase(),u,i,f;if(t.indexOf(r)!==-1)return le.indexOf(r)!==-1?Boolean(n.nodeValue.match(ae)||n.nodeValue.match(ve)):!0;for(u=t.filter(function(n){return n instanceof RegExp}),i=0,f=u.length;i<f;i++)if(r.match(u[i]))return!0;return!1}function au(n,t,i){var r,u,o;if(n.length===0)return n;if(i&&typeof i=="function")return i(n);var s=new window.DOMParser,f=s.parseFromString(n,"text/html"),h=Object.keys(t),e=[].slice.call(f.body.querySelectorAll("*")),c=function(n){var i=e[n],f=i.nodeName.toLowerCase(),r,u;if(h.indexOf(i.nodeName.toLowerCase())===-1)return i.parentNode.removeChild(i),"continue";r=[].slice.call(i.attributes);u=[].concat(t["*"]||[],t[f]||[]);r.forEach(function(n){ye(n,u)||i.removeAttribute(n.nodeName)})};for(r=0,u=e.length;r<u;r++)o=c(r,u),o==="continue";return f.body.innerHTML}var r;t=t&&t.hasOwnProperty("default")?t["default"]:t;i=i&&i.hasOwnProperty("default")?i["default"]:i;var nr="transitionend",tf=1e6,rf=1e3;r={TRANSITION_END:"bsTransitionEnd",getUID:function(n){do n+=~~(Math.random()*tf);while(document.getElementById(n));return n},getSelectorFromElement:function(n){var t=n.getAttribute("data-target"),i;t&&t!=="#"||(i=n.getAttribute("href"),t=i&&i!=="#"?i.trim():"");try{return document.querySelector(t)?t:null}catch(r){return null}},getTransitionDurationFromElement:function(n){if(!n)return 0;var i=t(n).css("transition-duration"),r=t(n).css("transition-delay"),u=parseFloat(i),f=parseFloat(r);return!u&&!f?0:(i=i.split(",")[0],r=r.split(",")[0],(parseFloat(i)+parseFloat(r))*rf)},reflow:function(n){return n.offsetHeight},triggerTransitionEnd:function(n){t(n).trigger(nr)},supportsTransitionEnd:function(){return Boolean(nr)},isElement:function(n){return(n[0]||n).nodeType},typeCheckConfig:function(n,t,i){for(var u in i)if(Object.prototype.hasOwnProperty.call(i,u)){var e=i[u],f=t[u],o=f&&r.isElement(f)?"element":uf(f);if(!new RegExp(e).test(o))throw new Error(n.toUpperCase()+": "+('Option "'+u+'" provided type "'+o+'" ')+('but expected type "'+e+'".'));}},findShadowRoot:function(n){if(!document.documentElement.attachShadow)return null;if(typeof n.getRootNode=="function"){var t=n.getRootNode();return t instanceof ShadowRoot?t:null}return n instanceof ShadowRoot?n:n.parentNode?r.findShadowRoot(n.parentNode):null}};of();var fi="alert",sf="4.3.1",tr="bs.alert",ar="."+tr,hf=t.fn[fi],vr={CLOSE:"close"+ar,CLOSED:"closed"+ar,CLICK_DATA_API:"click"+ar+".data-api"},yr={ALERT:"alert",FADE:"fade",SHOW:"show"},wt=function(){function n(n){this._element=n}var i=n.prototype;return i.close=function(n){var t=this._element,i;(n&&(t=this._getRootElement(n)),i=this._triggerCloseEvent(t),i.isDefaultPrevented())||this._removeElement(t)},i.dispose=function(){t.removeData(this._element,tr);this._element=null},i._getRootElement=function(n){var u=r.getSelectorFromElement(n),i=!1;return u&&(i=document.querySelector(u)),i||(i=t(n).closest("."+yr.ALERT)[0]),i},i._triggerCloseEvent=function(n){var i=t.Event(vr.CLOSE);return t(n).trigger(i),i},i._removeElement=function(n){var u=this,i;if(t(n).removeClass(yr.SHOW),!t(n).hasClass(yr.FADE)){this._destroyElement(n);return}i=r.getTransitionDurationFromElement(n);t(n).one(r.TRANSITION_END,function(t){return u._destroyElement(n,t)}).emulateTransitionEnd(i)},i._destroyElement=function(n){t(n).detach().trigger(vr.CLOSED).remove()},n._jQueryInterface=function(i){return this.each(function(){var u=t(this),r=u.data(tr);r||(r=new n(this),u.data(tr,r));i==="close"&&r[i](this)})},n._handleDismiss=function(n){return function(t){t&&t.preventDefault();n.close(this)}},p(n,null,[{key:"VERSION",get:function(){return sf}}]),n}();t(document).on(vr.CLICK_DATA_API,{DISMISS:'[data-dismiss="alert"]'}.DISMISS,wt._handleDismiss(new wt));t.fn[fi]=wt._jQueryInterface;t.fn[fi].Constructor=wt;t.fn[fi].noConflict=function(){return t.fn[fi]=hf,wt._jQueryInterface};var ei="button",cf="4.3.1",ir="bs.button",pr="."+ir,wr=".data-api",lf=t.fn[ei],ct={ACTIVE:"active",BUTTON:"btn",FOCUS:"focus"},lt={DATA_TOGGLE_CARROT:'[data-toggle^="button"]',DATA_TOGGLE:'[data-toggle="buttons"]',INPUT:'input:not([type="hidden"])',ACTIVE:".active",BUTTON:".btn"},ou={CLICK_DATA_API:"click"+pr+wr,FOCUS_BLUR_DATA_API:"focus"+pr+wr+" "+("blur"+pr+wr)},oi=function(){function n(n){this._element=n}var i=n.prototype;return i.toggle=function(){var r=!0,f=!0,i=t(this._element).closest(lt.DATA_TOGGLE)[0],n,u;if(i&&(n=this._element.querySelector(lt.INPUT),n)){if(n.type==="radio"&&(n.checked&&this._element.classList.contains(ct.ACTIVE)?r=!1:(u=i.querySelector(lt.ACTIVE),u&&t(u).removeClass(ct.ACTIVE))),r){if(n.hasAttribute("disabled")||i.hasAttribute("disabled")||n.classList.contains("disabled")||i.classList.contains("disabled"))return;n.checked=!this._element.classList.contains(ct.ACTIVE);t(n).trigger("change")}n.focus();f=!1}f&&this._element.setAttribute("aria-pressed",!this._element.classList.contains(ct.ACTIVE));r&&t(this._element).toggleClass(ct.ACTIVE)},i.dispose=function(){t.removeData(this._element,ir);this._element=null},n._jQueryInterface=function(i){return this.each(function(){var r=t(this).data(ir);r||(r=new n(this),t(this).data(ir,r));i==="toggle"&&r[i]()})},p(n,null,[{key:"VERSION",get:function(){return cf}}]),n}();t(document).on(ou.CLICK_DATA_API,lt.DATA_TOGGLE_CARROT,function(n){n.preventDefault();var i=n.target;t(i).hasClass(ct.BUTTON)||(i=t(i).closest(lt.BUTTON));oi._jQueryInterface.call(t(i),"toggle")}).on(ou.FOCUS_BLUR_DATA_API,lt.DATA_TOGGLE_CARROT,function(n){var i=t(n.target).closest(lt.BUTTON)[0];t(i).toggleClass(ct.FOCUS,/^focus(in)?$/.test(n.type))});t.fn[ei]=oi._jQueryInterface;t.fn[ei].Constructor=oi;t.fn[ei].noConflict=function(){return t.fn[ei]=lf,oi._jQueryInterface};var bt="carousel",af="4.3.1",si="bs.carousel",c="."+si,su=".data-api",vf=t.fn[bt],yf=37,pf=39,wf=500,bf=40,br={interval:5e3,keyboard:!0,slide:!1,pause:"hover",wrap:!0,touch:!0},kf={interval:"(number|boolean)",keyboard:"boolean",slide:"(boolean|string)",pause:"(string|boolean)",wrap:"boolean",touch:"boolean"},d={NEXT:"next",PREV:"prev",LEFT:"left",RIGHT:"right"},l={SLIDE:"slide"+c,SLID:"slid"+c,KEYDOWN:"keydown"+c,MOUSEENTER:"mouseenter"+c,MOUSELEAVE:"mouseleave"+c,TOUCHSTART:"touchstart"+c,TOUCHMOVE:"touchmove"+c,TOUCHEND:"touchend"+c,POINTERDOWN:"pointerdown"+c,POINTERUP:"pointerup"+c,DRAG_START:"dragstart"+c,LOAD_DATA_API:"load"+c+su,CLICK_DATA_API:"click"+c+su},a={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"},g={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"]'},hu={TOUCH:"touch",PEN:"pen"},kt=function(){function i(n,t){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(t);this._element=n;this._indicatorsElement=this._element.querySelector(g.INDICATORS);this._touchSupported="ontouchstart"in document.documentElement||navigator.maxTouchPoints>0;this._pointerEvent=Boolean(window.PointerEvent||window.MSPointerEvent);this._addEventListeners()}var n=i.prototype;return n.next=function(){this._isSliding||this._slide(d.NEXT)},n.nextWhenVisible=function(){!document.hidden&&t(this._element).is(":visible")&&t(this._element).css("visibility")!=="hidden"&&this.next()},n.prev=function(){this._isSliding||this._slide(d.PREV)},n.pause=function(n){n||(this._isPaused=!0);this._element.querySelector(g.NEXT_PREV)&&(r.triggerTransitionEnd(this._element),this.cycle(!0));clearInterval(this._interval);this._interval=null},n.cycle=function(n){n||(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))},n.to=function(n){var u=this,i,r;if(this._activeElement=this._element.querySelector(g.ACTIVE_ITEM),i=this._getItemIndex(this._activeElement),!(n>this._items.length-1)&&!(n<0)){if(this._isSliding){t(this._element).one(l.SLID,function(){return u.to(n)});return}if(i===n){this.pause();this.cycle();return}r=n>i?d.NEXT:d.PREV;this._slide(r,this._items[n])}},n.dispose=function(){t(this._element).off(c);t.removeData(this._element,si);this._items=null;this._config=null;this._element=null;this._interval=null;this._isPaused=null;this._isSliding=null;this._activeElement=null;this._indicatorsElement=null},n._getConfig=function(n){return n=o({},br,n),r.typeCheckConfig(bt,n,kf),n},n._handleSwipe=function(){var t=Math.abs(this.touchDeltaX),n;t<=bf||(n=t/this.touchDeltaX,n>0&&this.prev(),n<0&&this.next())},n._addEventListeners=function(){var n=this;if(this._config.keyboard)t(this._element).on(l.KEYDOWN,function(t){return n._keydown(t)});if(this._config.pause==="hover")t(this._element).on(l.MOUSEENTER,function(t){return n.pause(t)}).on(l.MOUSELEAVE,function(t){return n.cycle(t)});this._config.touch&&this._addTouchEventListeners()},n._addTouchEventListeners=function(){var n=this;if(this._touchSupported){var i=function(t){n._pointerEvent&&hu[t.originalEvent.pointerType.toUpperCase()]?n.touchStartX=t.originalEvent.clientX:n._pointerEvent||(n.touchStartX=t.originalEvent.touches[0].clientX)},u=function(t){n.touchDeltaX=t.originalEvent.touches&&t.originalEvent.touches.length>1?0:t.originalEvent.touches[0].clientX-n.touchStartX},r=function(t){n._pointerEvent&&hu[t.originalEvent.pointerType.toUpperCase()]&&(n.touchDeltaX=t.originalEvent.clientX-n.touchStartX);n._handleSwipe();n._config.pause==="hover"&&(n.pause(),n.touchTimeout&&clearTimeout(n.touchTimeout),n.touchTimeout=setTimeout(function(t){return n.cycle(t)},wf+n._config.interval))};t(this._element.querySelectorAll(g.ITEM_IMG)).on(l.DRAG_START,function(n){return n.preventDefault()});if(this._pointerEvent){t(this._element).on(l.POINTERDOWN,function(n){return i(n)});t(this._element).on(l.POINTERUP,function(n){return r(n)});this._element.classList.add(a.POINTER_EVENT)}else{t(this._element).on(l.TOUCHSTART,function(n){return i(n)});t(this._element).on(l.TOUCHMOVE,function(n){return u(n)});t(this._element).on(l.TOUCHEND,function(n){return r(n)})}}},n._keydown=function(n){if(!/input|textarea/i.test(n.target.tagName))switch(n.which){case yf:n.preventDefault();this.prev();break;case pf:n.preventDefault();this.next()}},n._getItemIndex=function(n){return this._items=n&&n.parentNode?[].slice.call(n.parentNode.querySelectorAll(g.ITEM)):[],this._items.indexOf(n)},n._getItemByDirection=function(n,t){var f=n===d.NEXT,e=n===d.PREV,i=this._getItemIndex(t),o=this._items.length-1,s=e&&i===0||f&&i===o,u,r;return s&&!this._config.wrap?t:(u=n===d.PREV?-1:1,r=(i+u)%this._items.length,r===-1?this._items[this._items.length-1]:this._items[r])},n._triggerSlideEvent=function(n,i){var u=this._getItemIndex(n),f=this._getItemIndex(this._element.querySelector(g.ACTIVE_ITEM)),r=t.Event(l.SLIDE,{relatedTarget:n,direction:i,from:f,to:u});return t(this._element).trigger(r),r},n._setActiveIndicatorElement=function(n){var r,i;this._indicatorsElement&&(r=[].slice.call(this._indicatorsElement.querySelectorAll(g.ACTIVE)),t(r).removeClass(a.ACTIVE),i=this._indicatorsElement.children[this._getItemIndex(n)],i&&t(i).addClass(a.ACTIVE))},n._slide=function(n,i){var v=this,f=this._element.querySelector(g.ACTIVE_ITEM),b=this._getItemIndex(f),u=i||f&&this._getItemByDirection(n,f),k=this._getItemIndex(u),y=Boolean(this._interval),e,o,s,p,h,c,w;if(n===d.NEXT?(e=a.LEFT,o=a.NEXT,s=d.LEFT):(e=a.RIGHT,o=a.PREV,s=d.RIGHT),u&&t(u).hasClass(a.ACTIVE)){this._isSliding=!1;return}(p=this._triggerSlideEvent(u,s),p.isDefaultPrevented())||f&&u&&(this._isSliding=!0,y&&this.pause(),this._setActiveIndicatorElement(u),h=t.Event(l.SLID,{relatedTarget:u,direction:s,from:b,to:k}),t(this._element).hasClass(a.SLIDE)?(t(u).addClass(o),r.reflow(u),t(f).addClass(e),t(u).addClass(e),c=parseInt(u.getAttribute("data-interval"),10),c?(this._config.defaultInterval=this._config.defaultInterval||this._config.interval,this._config.interval=c):this._config.interval=this._config.defaultInterval||this._config.interval,w=r.getTransitionDurationFromElement(f),t(f).one(r.TRANSITION_END,function(){t(u).removeClass(e+" "+o).addClass(a.ACTIVE);t(f).removeClass(a.ACTIVE+" "+o+" "+e);v._isSliding=!1;setTimeout(function(){return t(v._element).trigger(h)},0)}).emulateTransitionEnd(w)):(t(f).removeClass(a.ACTIVE),t(u).addClass(a.ACTIVE),this._isSliding=!1,t(this._element).trigger(h)),y&&this.cycle())},i._jQueryInterface=function(n){return this.each(function(){var r=t(this).data(si),u=o({},br,t(this).data()),f;if(typeof n=="object"&&(u=o({},u,n)),f=typeof n=="string"?n:u.slide,r||(r=new i(this,u),t(this).data(si,r)),typeof n=="number")r.to(n);else if(typeof f=="string"){if(typeof r[f]=="undefined")throw new TypeError('No method named "'+f+'"');r[f]()}else u.interval&&u.ride&&(r.pause(),r.cycle())})},i._dataApiClickHandler=function(n){var s=r.getSelectorFromElement(this),u,e,f;s&&(u=t(s)[0],u&&t(u).hasClass(a.CAROUSEL))&&(e=o({},t(u).data(),t(this).data()),f=this.getAttribute("data-slide-to"),f&&(e.interval=!1),i._jQueryInterface.call(t(u),e),f&&t(u).data(si).to(f),n.preventDefault())},p(i,null,[{key:"VERSION",get:function(){return af}},{key:"Default",get:function(){return br}}]),i}();t(document).on(l.CLICK_DATA_API,g.DATA_SLIDE,kt._dataApiClickHandler);t(window).on(l.LOAD_DATA_API,function(){for(var i,r=[].slice.call(document.querySelectorAll(g.DATA_RIDE)),n=0,u=r.length;n<u;n++)i=t(r[n]),kt._jQueryInterface.call(i,i.data())});t.fn[bt]=kt._jQueryInterface;t.fn[bt].Constructor=kt;t.fn[bt].noConflict=function(){return t.fn[bt]=vf,kt._jQueryInterface};var dt="collapse",df="4.3.1",at="bs.collapse",hi="."+at,gf=t.fn[dt],kr={toggle:!0,parent:""},ne={toggle:"boolean",parent:"(string|element)"},ci={SHOW:"show"+hi,SHOWN:"shown"+hi,HIDE:"hide"+hi,HIDDEN:"hidden"+hi,CLICK_DATA_API:"click"+hi+".data-api"},e={SHOW:"show",COLLAPSE:"collapse",COLLAPSING:"collapsing",COLLAPSED:"collapsed"},dr={WIDTH:"width",HEIGHT:"height"},gr={ACTIVES:".show, .collapsing",DATA_TOGGLE:'[data-toggle="collapse"]'},li=function(){function i(n,t){var u,i,e;for(this._isTransitioning=!1,this._element=n,this._config=this._getConfig(t),this._triggerArray=[].slice.call(document.querySelectorAll('[data-toggle="collapse"][href="#'+n.id+'"],'+('[data-toggle="collapse"][data-target="#'+n.id+'"]'))),u=[].slice.call(document.querySelectorAll(gr.DATA_TOGGLE)),i=0,e=u.length;i<e;i++){var o=u[i],f=r.getSelectorFromElement(o),s=[].slice.call(document.querySelectorAll(f)).filter(function(t){return t===n});f!==null&&s.length>0&&(this._selector=f,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 n=i.prototype;return n.toggle=function(){t(this._element).hasClass(e.SHOW)?this.hide():this.show()},n.show=function(){var u=this,n,o,s,f;if(!this._isTransitioning&&!t(this._element).hasClass(e.SHOW)&&(this._parent&&(n=[].slice.call(this._parent.querySelectorAll(gr.ACTIVES)).filter(function(n){return typeof u._config.parent=="string"?n.getAttribute("data-parent")===u._config.parent:n.classList.contains(e.COLLAPSE)}),n.length===0&&(n=null)),!n||(o=t(n).not(this._selector).data(at),!o||!o._isTransitioning))&&(s=t.Event(ci.SHOW),t(this._element).trigger(s),!s.isDefaultPrevented())){n&&(i._jQueryInterface.call(t(n).not(this._selector),"hide"),o||t(n).data(at,null));f=this._getDimension();t(this._element).removeClass(e.COLLAPSE).addClass(e.COLLAPSING);this._element.style[f]=0;this._triggerArray.length&&t(this._triggerArray).removeClass(e.COLLAPSED).attr("aria-expanded",!0);this.setTransitioning(!0);var h=function(){t(u._element).removeClass(e.COLLAPSING).addClass(e.COLLAPSE).addClass(e.SHOW);u._element.style[f]="";u.setTransitioning(!1);t(u._element).trigger(ci.SHOWN)},c=f[0].toUpperCase()+f.slice(1),l="scroll"+c,a=r.getTransitionDurationFromElement(this._element);t(this._element).one(r.TRANSITION_END,h).emulateTransitionEnd(a);this._element.style[f]=this._element[l]+"px"}},n.hide=function(){var h=this,u,n,f,i,o,s,c,l,a;if(!this._isTransitioning&&t(this._element).hasClass(e.SHOW)&&(u=t.Event(ci.HIDE),t(this._element).trigger(u),!u.isDefaultPrevented())){if(n=this._getDimension(),this._element.style[n]=this._element.getBoundingClientRect()[n]+"px",r.reflow(this._element),t(this._element).addClass(e.COLLAPSING).removeClass(e.COLLAPSE).removeClass(e.SHOW),f=this._triggerArray.length,f>0)for(i=0;i<f;i++)o=this._triggerArray[i],s=r.getSelectorFromElement(o),s!==null&&(c=t([].slice.call(document.querySelectorAll(s))),c.hasClass(e.SHOW)||t(o).addClass(e.COLLAPSED).attr("aria-expanded",!1));this.setTransitioning(!0);l=function(){h.setTransitioning(!1);t(h._element).removeClass(e.COLLAPSING).addClass(e.COLLAPSE).trigger(ci.HIDDEN)};this._element.style[n]="";a=r.getTransitionDurationFromElement(this._element);t(this._element).one(r.TRANSITION_END,l).emulateTransitionEnd(a)}},n.setTransitioning=function(n){this._isTransitioning=n},n.dispose=function(){t.removeData(this._element,at);this._config=null;this._parent=null;this._element=null;this._triggerArray=null;this._isTransitioning=null},n._getConfig=function(n){return n=o({},kr,n),n.toggle=Boolean(n.toggle),r.typeCheckConfig(dt,n,ne),n},n._getDimension=function(){var n=t(this._element).hasClass(dr.WIDTH);return n?dr.WIDTH:dr.HEIGHT},n._getParent=function(){var e=this,n,u,f;return r.isElement(this._config.parent)?(n=this._config.parent,typeof this._config.parent.jquery!="undefined"&&(n=this._config.parent[0])):n=document.querySelector(this._config.parent),u='[data-toggle="collapse"][data-parent="'+this._config.parent+'"]',f=[].slice.call(n.querySelectorAll(u)),t(f).each(function(n,t){e._addAriaAndCollapsedClass(i._getTargetFromElement(t),[t])}),n},n._addAriaAndCollapsedClass=function(n,i){var r=t(n).hasClass(e.SHOW);i.length&&t(i).toggleClass(e.COLLAPSED,!r).attr("aria-expanded",r)},i._getTargetFromElement=function(n){var t=r.getSelectorFromElement(n);return t?document.querySelector(t):null},i._jQueryInterface=function(n){return this.each(function(){var u=t(this),r=u.data(at),f=o({},kr,u.data(),typeof n=="object"&&n?n:{});if(!r&&f.toggle&&/show|hide/.test(n)&&(f.toggle=!1),r||(r=new i(this,f),u.data(at,r)),typeof n=="string"){if(typeof r[n]=="undefined")throw new TypeError('No method named "'+n+'"');r[n]()}})},p(i,null,[{key:"VERSION",get:function(){return df}},{key:"Default",get:function(){return kr}}]),i}();t(document).on(ci.CLICK_DATA_API,gr.DATA_TOGGLE,function(n){n.currentTarget.tagName==="A"&&n.preventDefault();var i=t(this),u=r.getSelectorFromElement(this),f=[].slice.call(document.querySelectorAll(u));t(f).each(function(){var n=t(this),r=n.data(at),u=r?"toggle":i.data();li._jQueryInterface.call(n,u)})});t.fn[dt]=li._jQueryInterface;t.fn[dt].Constructor=li;t.fn[dt].noConflict=function(){return t.fn[dt]=gf,li._jQueryInterface};var gt="dropdown",te="4.3.1",ai="bs.dropdown",ut="."+ai,nu=".data-api",ie=t.fn[gt],rr=27,cu=32,lu=9,tu=38,iu=40,re=3,ue=new RegExp(tu+"|"+iu+"|"+rr),s={HIDE:"hide"+ut,HIDDEN:"hidden"+ut,SHOW:"show"+ut,SHOWN:"shown"+ut,CLICK:"click"+ut,CLICK_DATA_API:"click"+ut+nu,KEYDOWN_DATA_API:"keydown"+ut+nu,KEYUP_DATA_API:"keyup"+ut+nu},u={DISABLED:"disabled",SHOW:"show",DROPUP:"dropup",DROPRIGHT:"dropright",DROPLEFT:"dropleft",MENURIGHT:"dropdown-menu-right",MENULEFT:"dropdown-menu-left",POSITION_STATIC:"position-static"},nt={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)"},ni={TOP:"top-start",TOPEND:"top-end",BOTTOM:"bottom-start",BOTTOMEND:"bottom-end",RIGHT:"right-start",RIGHTEND:"right-end",LEFT:"left-start",LEFTEND:"left-end"},fe={offset:0,flip:!0,boundary:"scrollParent",reference:"toggle",display:"dynamic"},ee={offset:"(number|string|function)",flip:"boolean",boundary:"(string|element)",reference:"(string|element)",display:"string"},et=function(){function n(n,t){this._element=n;this._popper=null;this._config=this._getConfig(t);this._menu=this._getMenuElement();this._inNavbar=this._detectNavbar();this._addEventListeners()}var f=n.prototype;return f.toggle=function(){var f,c,o,h,e;if(!this._element.disabled&&!t(this._element).hasClass(u.DISABLED)&&(f=n._getParentFromElement(this._element),c=t(this._menu).hasClass(u.SHOW),n._clearMenus(),!c)&&(o={relatedTarget:this._element},h=t.Event(s.SHOW,o),t(f).trigger(h),!h.isDefaultPrevented())){if(!this._inNavbar){if(typeof i=="undefined")throw new TypeError("Bootstrap's dropdowns require Popper.js (https://popper.js.org/)");e=this._element;this._config.reference==="parent"?e=f:r.isElement(this._config.reference)&&(e=this._config.reference,typeof this._config.reference.jquery!="undefined"&&(e=this._config.reference[0]));this._config.boundary!=="scrollParent"&&t(f).addClass(u.POSITION_STATIC);this._popper=new i(e,this._menu,this._getPopperConfig())}if("ontouchstart"in document.documentElement&&t(f).closest(nt.NAVBAR_NAV).length===0)t(document.body).children().on("mouseover",null,t.noop);this._element.focus();this._element.setAttribute("aria-expanded",!0);t(this._menu).toggleClass(u.SHOW);t(f).toggleClass(u.SHOW).trigger(t.Event(s.SHOWN,o))}},f.show=function(){if(!this._element.disabled&&!t(this._element).hasClass(u.DISABLED)&&!t(this._menu).hasClass(u.SHOW)){var i={relatedTarget:this._element},r=t.Event(s.SHOW,i),f=n._getParentFromElement(this._element);(t(f).trigger(r),r.isDefaultPrevented())||(t(this._menu).toggleClass(u.SHOW),t(f).toggleClass(u.SHOW).trigger(t.Event(s.SHOWN,i)))}},f.hide=function(){if(!this._element.disabled&&!t(this._element).hasClass(u.DISABLED)&&t(this._menu).hasClass(u.SHOW)){var i={relatedTarget:this._element},r=t.Event(s.HIDE,i),f=n._getParentFromElement(this._element);(t(f).trigger(r),r.isDefaultPrevented())||(t(this._menu).toggleClass(u.SHOW),t(f).toggleClass(u.SHOW).trigger(t.Event(s.HIDDEN,i)))}},f.dispose=function(){t.removeData(this._element,ai);t(this._element).off(ut);this._element=null;this._menu=null;this._popper!==null&&(this._popper.destroy(),this._popper=null)},f.update=function(){this._inNavbar=this._detectNavbar();this._popper!==null&&this._popper.scheduleUpdate()},f._addEventListeners=function(){var n=this;t(this._element).on(s.CLICK,function(t){t.preventDefault();t.stopPropagation();n.toggle()})},f._getConfig=function(n){return n=o({},this.constructor.Default,t(this._element).data(),n),r.typeCheckConfig(gt,n,this.constructor.DefaultType),n},f._getMenuElement=function(){if(!this._menu){var t=n._getParentFromElement(this._element);t&&(this._menu=t.querySelector(nt.MENU))}return this._menu},f._getPlacement=function(){var i=t(this._element.parentNode),n=ni.BOTTOM;return i.hasClass(u.DROPUP)?(n=ni.TOP,t(this._menu).hasClass(u.MENURIGHT)&&(n=ni.TOPEND)):i.hasClass(u.DROPRIGHT)?n=ni.RIGHT:i.hasClass(u.DROPLEFT)?n=ni.LEFT:t(this._menu).hasClass(u.MENURIGHT)&&(n=ni.BOTTOMEND),n},f._detectNavbar=function(){return t(this._element).closest(".navbar").length>0},f._getOffset=function(){var t=this,n={};return typeof this._config.offset=="function"?n.fn=function(n){return n.offsets=o({},n.offsets,t._config.offset(n.offsets,t._element)||{}),n}:n.offset=this._config.offset,n},f._getPopperConfig=function(){var n={placement:this._getPlacement(),modifiers:{offset:this._getOffset(),flip:{enabled:this._config.flip},preventOverflow:{boundariesElement:this._config.boundary}}};return this._config.display==="static"&&(n.modifiers.applyStyle={enabled:!1}),n},n._jQueryInterface=function(i){return this.each(function(){var r=t(this).data(ai),u=typeof i=="object"?i:null;if(r||(r=new n(this,u),t(this).data(ai,r)),typeof i=="string"){if(typeof r[i]=="undefined")throw new TypeError('No method named "'+i+'"');r[i]()}})},n._clearMenus=function(i){var f,r,c,a,h;if(!i||i.which!==re&&(i.type!=="keyup"||i.which===lu))for(f=[].slice.call(document.querySelectorAll(nt.DATA_TOGGLE)),r=0,c=f.length;r<c;r++){var e=n._getParentFromElement(f[r]),l=t(f[r]).data(ai),o={relatedTarget:f[r]};(i&&i.type==="click"&&(o.clickEvent=i),l)&&(a=l._menu,t(e).hasClass(u.SHOW))&&(i&&(i.type==="click"&&/input|textarea/i.test(i.target.tagName)||i.type==="keyup"&&i.which===lu)&&t.contains(e,i.target)||(h=t.Event(s.HIDE,o),t(e).trigger(h),h.isDefaultPrevented())||("ontouchstart"in document.documentElement&&t(document.body).children().off("mouseover",null,t.noop),f[r].setAttribute("aria-expanded","false"),t(a).removeClass(u.SHOW),t(e).removeClass(u.SHOW).trigger(t.Event(s.HIDDEN,o))))}},n._getParentFromElement=function(n){var t,i=r.getSelectorFromElement(n);return i&&(t=document.querySelector(i)),t||n.parentNode},n._dataApiKeydownHandler=function(i){var e,o,s,f,r;if((/input|textarea/i.test(i.target.tagName)?i.which!==cu&&(i.which===rr||(i.which===iu||i.which===tu)&&!t(i.target).closest(nt.MENU).length):ue.test(i.which))&&(i.preventDefault(),i.stopPropagation(),!this.disabled&&!t(this).hasClass(u.DISABLED))){if(e=n._getParentFromElement(this),o=t(e).hasClass(u.SHOW),!o||o&&(i.which===rr||i.which===cu)){i.which===rr&&(s=e.querySelector(nt.DATA_TOGGLE),t(s).trigger("focus"));t(this).trigger("click");return}(f=[].slice.call(e.querySelectorAll(nt.VISIBLE_ITEMS)),f.length!==0)&&(r=f.indexOf(i.target),i.which===tu&&r>0&&r--,i.which===iu&&r<f.length-1&&r++,r<0&&(r=0),f[r].focus())}},p(n,null,[{key:"VERSION",get:function(){return te}},{key:"Default",get:function(){return fe}},{key:"DefaultType",get:function(){return ee}}]),n}();t(document).on(s.KEYDOWN_DATA_API,nt.DATA_TOGGLE,et._dataApiKeydownHandler).on(s.KEYDOWN_DATA_API,nt.MENU,et._dataApiKeydownHandler).on(s.CLICK_DATA_API+" "+s.KEYUP_DATA_API,et._clearMenus).on(s.CLICK_DATA_API,nt.DATA_TOGGLE,function(n){n.preventDefault();n.stopPropagation();et._jQueryInterface.call(t(this),"toggle")}).on(s.CLICK_DATA_API,nt.FORM_CHILD,function(n){n.stopPropagation()});t.fn[gt]=et._jQueryInterface;t.fn[gt].Constructor=et;t.fn[gt].noConflict=function(){return t.fn[gt]=ie,et._jQueryInterface};var ti="modal",oe="4.3.1",vi="bs.modal",v="."+vi,se=t.fn[ti],he=27,ru={backdrop:!0,keyboard:!0,focus:!0,show:!0},ce={backdrop:"(boolean|string)",keyboard:"boolean",focus:"boolean",show:"boolean"},f={HIDE:"hide"+v,HIDDEN:"hidden"+v,SHOW:"show"+v,SHOWN:"shown"+v,FOCUSIN:"focusin"+v,RESIZE:"resize"+v,CLICK_DISMISS:"click.dismiss"+v,KEYDOWN_DISMISS:"keydown.dismiss"+v,MOUSEUP_DISMISS:"mouseup.dismiss"+v,MOUSEDOWN_DISMISS:"mousedown.dismiss"+v,CLICK_DATA_API:"click"+v+".data-api"},h={SCROLLABLE:"modal-dialog-scrollable",SCROLLBAR_MEASURER:"modal-scrollbar-measure",BACKDROP:"modal-backdrop",OPEN:"modal-open",FADE:"fade",SHOW:"show"},ot={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"},yi=function(){function i(n,t){this._config=this._getConfig(t);this._element=n;this._dialog=n.querySelector(ot.DIALOG);this._backdrop=null;this._isShown=!1;this._isBodyOverflowing=!1;this._ignoreBackdropClick=!1;this._isTransitioning=!1;this._scrollbarWidth=0}var n=i.prototype;return n.toggle=function(n){return this._isShown?this.hide():this.show(n)},n.show=function(n){var i=this,r;if(!this._isShown&&!this._isTransitioning&&(t(this._element).hasClass(h.FADE)&&(this._isTransitioning=!0),r=t.Event(f.SHOW,{relatedTarget:n}),t(this._element).trigger(r),!this._isShown&&!r.isDefaultPrevented())){this._isShown=!0;this._checkScrollbar();this._setScrollbar();this._adjustDialog();this._setEscapeEvent();this._setResizeEvent();t(this._element).on(f.CLICK_DISMISS,ot.DATA_DISMISS,function(n){return i.hide(n)});t(this._dialog).on(f.MOUSEDOWN_DISMISS,function(){t(i._element).one(f.MOUSEUP_DISMISS,function(n){t(n.target).is(i._element)&&(i._ignoreBackdropClick=!0)})});this._showBackdrop(function(){return i._showElement(n)})}},n.hide=function(n){var o=this,i,u,e;(n&&n.preventDefault(),this._isShown&&!this._isTransitioning)&&(i=t.Event(f.HIDE),t(this._element).trigger(i),this._isShown&&!i.isDefaultPrevented())&&(this._isShown=!1,u=t(this._element).hasClass(h.FADE),u&&(this._isTransitioning=!0),this._setEscapeEvent(),this._setResizeEvent(),t(document).off(f.FOCUSIN),t(this._element).removeClass(h.SHOW),t(this._element).off(f.CLICK_DISMISS),t(this._dialog).off(f.MOUSEDOWN_DISMISS),u?(e=r.getTransitionDurationFromElement(this._element),t(this._element).one(r.TRANSITION_END,function(n){return o._hideModal(n)}).emulateTransitionEnd(e)):this._hideModal())},n.dispose=function(){[window,this._element,this._dialog].forEach(function(n){return t(n).off(v)});t(document).off(f.FOCUSIN);t.removeData(this._element,vi);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},n.handleUpdate=function(){this._adjustDialog()},n._getConfig=function(n){return n=o({},ru,n),r.typeCheckConfig(ti,n,ce),n},n._showElement=function(n){var i=this,e=t(this._element).hasClass(h.FADE),o,u,s;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);t(this._dialog).hasClass(h.SCROLLABLE)?this._dialog.querySelector(ot.MODAL_BODY).scrollTop=0:this._element.scrollTop=0;e&&r.reflow(this._element);t(this._element).addClass(h.SHOW);this._config.focus&&this._enforceFocus();o=t.Event(f.SHOWN,{relatedTarget:n});u=function(){i._config.focus&&i._element.focus();i._isTransitioning=!1;t(i._element).trigger(o)};e?(s=r.getTransitionDurationFromElement(this._dialog),t(this._dialog).one(r.TRANSITION_END,u).emulateTransitionEnd(s)):u()},n._enforceFocus=function(){var n=this;t(document).off(f.FOCUSIN).on(f.FOCUSIN,function(i){document!==i.target&&n._element!==i.target&&t(n._element).has(i.target).length===0&&n._element.focus()})},n._setEscapeEvent=function(){var n=this;if(this._isShown&&this._config.keyboard)t(this._element).on(f.KEYDOWN_DISMISS,function(t){t.which===he&&(t.preventDefault(),n.hide())});else this._isShown||t(this._element).off(f.KEYDOWN_DISMISS)},n._setResizeEvent=function(){var n=this;if(this._isShown)t(window).on(f.RESIZE,function(t){return n.handleUpdate(t)});else t(window).off(f.RESIZE)},n._hideModal=function(){var n=this;this._element.style.display="none";this._element.setAttribute("aria-hidden",!0);this._element.removeAttribute("aria-modal");this._isTransitioning=!1;this._showBackdrop(function(){t(document.body).removeClass(h.OPEN);n._resetAdjustments();n._resetScrollbar();t(n._element).trigger(f.HIDDEN)})},n._removeBackdrop=function(){this._backdrop&&(t(this._backdrop).remove(),this._backdrop=null)},n._showBackdrop=function(n){var i=this,u=t(this._element).hasClass(h.FADE)?h.FADE:"",o,e,s;if(this._isShown&&this._config.backdrop){this._backdrop=document.createElement("div");this._backdrop.className=h.BACKDROP;u&&this._backdrop.classList.add(u);t(this._backdrop).appendTo(document.body);t(this._element).on(f.CLICK_DISMISS,function(n){if(i._ignoreBackdropClick){i._ignoreBackdropClick=!1;return}n.target===n.currentTarget&&(i._config.backdrop==="static"?i._element.focus():i.hide())});if(u&&r.reflow(this._backdrop),t(this._backdrop).addClass(h.SHOW),!n)return;if(!u){n();return}o=r.getTransitionDurationFromElement(this._backdrop);t(this._backdrop).one(r.TRANSITION_END,n).emulateTransitionEnd(o)}else!this._isShown&&this._backdrop?(t(this._backdrop).removeClass(h.SHOW),e=function(){i._removeBackdrop();n&&n()},t(this._element).hasClass(h.FADE)?(s=r.getTransitionDurationFromElement(this._backdrop),t(this._backdrop).one(r.TRANSITION_END,e).emulateTransitionEnd(s)):e()):n&&n()},n._adjustDialog=function(){var n=this._element.scrollHeight>document.documentElement.clientHeight;!this._isBodyOverflowing&&n&&(this._element.style.paddingLeft=this._scrollbarWidth+"px");this._isBodyOverflowing&&!n&&(this._element.style.paddingRight=this._scrollbarWidth+"px")},n._resetAdjustments=function(){this._element.style.paddingLeft="";this._element.style.paddingRight=""},n._checkScrollbar=function(){var n=document.body.getBoundingClientRect();this._isBodyOverflowing=n.left+n.right<window.innerWidth;this._scrollbarWidth=this._getScrollbarWidth()},n._setScrollbar=function(){var n=this,i,r,u,f;this._isBodyOverflowing&&(i=[].slice.call(document.querySelectorAll(ot.FIXED_CONTENT)),r=[].slice.call(document.querySelectorAll(ot.STICKY_CONTENT)),t(i).each(function(i,r){var u=r.style.paddingRight,f=t(r).css("padding-right");t(r).data("padding-right",u).css("padding-right",parseFloat(f)+n._scrollbarWidth+"px")}),t(r).each(function(i,r){var u=r.style.marginRight,f=t(r).css("margin-right");t(r).data("margin-right",u).css("margin-right",parseFloat(f)-n._scrollbarWidth+"px")}),u=document.body.style.paddingRight,f=t(document.body).css("padding-right"),t(document.body).data("padding-right",u).css("padding-right",parseFloat(f)+this._scrollbarWidth+"px"));t(document.body).addClass(h.OPEN)},n._resetScrollbar=function(){var r=[].slice.call(document.querySelectorAll(ot.FIXED_CONTENT)),i,n;t(r).each(function(n,i){var r=t(i).data("padding-right");t(i).removeData("padding-right");i.style.paddingRight=r?r:""});i=[].slice.call(document.querySelectorAll(""+ot.STICKY_CONTENT));t(i).each(function(n,i){var r=t(i).data("margin-right");typeof r!="undefined"&&t(i).css("margin-right",r).removeData("margin-right")});n=t(document.body).data("padding-right");t(document.body).removeData("padding-right");document.body.style.paddingRight=n?n:""},n._getScrollbarWidth=function(){var n=document.createElement("div"),t;return n.className=h.SCROLLBAR_MEASURER,document.body.appendChild(n),t=n.getBoundingClientRect().width-n.clientWidth,document.body.removeChild(n),t},i._jQueryInterface=function(n,r){return this.each(function(){var u=t(this).data(vi),f=o({},ru,t(this).data(),typeof n=="object"&&n?n:{});if(u||(u=new i(this,f),t(this).data(vi,u)),typeof n=="string"){if(typeof u[n]=="undefined")throw new TypeError('No method named "'+n+'"');u[n](r)}else f.show&&u.show(r)})},p(i,null,[{key:"VERSION",get:function(){return oe}},{key:"Default",get:function(){return ru}}]),i}();t(document).on(f.CLICK_DATA_API,ot.DATA_TOGGLE,function(n){var u=this,i,e=r.getSelectorFromElement(this),s,h;e&&(i=document.querySelector(e));s=t(i).data(vi)?"toggle":o({},t(i).data(),t(this).data());(this.tagName==="A"||this.tagName==="AREA")&&n.preventDefault();h=t(i).one(f.SHOW,function(n){if(!n.isDefaultPrevented())h.one(f.HIDDEN,function(){t(u).is(":visible")&&u.focus()})});yi._jQueryInterface.call(t(i),s,this)});t.fn[ti]=yi._jQueryInterface;t.fn[ti].Constructor=yi;t.fn[ti].noConflict=function(){return t.fn[ti]=se,yi._jQueryInterface};var le=["background","cite","href","itemtype","longdesc","poster","src","xlink:href"],ae=/^(?:(?:https?|mailto|ftp|tel|file):|[^&:/?#]*(?:[/?#]|$))/gi,ve=/^data:(?:image\/(?:bmp|gif|jpeg|jpg|png|tiff|webp)|video\/(?:mpeg|mp4|ogg|webm)|audio\/(?:mp3|oga|ogg|opus));base64,[a-z0-9+/]+=*$/i;var vt="tooltip",pe="4.3.1",ur="bs.tooltip",w="."+ur,we=t.fn[vt],vu="bs-tooltip",be=new RegExp("(^|\\s)"+vu+"\\S+","g"),ke=["sanitize","whiteList","sanitizeFn"],de={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"},ge={AUTO:"auto",TOP:"top",RIGHT:"right",BOTTOM:"bottom",LEFT:"left"},no={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:{"*":["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:[]}},st={SHOW:"show",OUT:"out"},to={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},tt={FADE:"fade",SHOW:"show"},yu={TOOLTIP:".tooltip",TOOLTIP_INNER:".tooltip-inner",ARROW:".arrow"},it={HOVER:"hover",FOCUS:"focus",CLICK:"click",MANUAL:"manual"},yt=function(){function u(n,t){if(typeof i=="undefined")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=n;this.config=this._getConfig(t);this.tip=null;this._setListeners()}var n=u.prototype;return n.enable=function(){this._isEnabled=!0},n.disable=function(){this._isEnabled=!1},n.toggleEnabled=function(){this._isEnabled=!this._isEnabled},n.toggle=function(n){if(this._isEnabled)if(n){var r=this.constructor.DATA_KEY,i=t(n.currentTarget).data(r);i||(i=new this.constructor(n.currentTarget,this._getDelegateConfig()),t(n.currentTarget).data(r,i));i._activeTrigger.click=!i._activeTrigger.click;i._isWithActiveTrigger()?i._enter(null,i):i._leave(null,i)}else{if(t(this.getTipElement()).hasClass(tt.SHOW)){this._leave(null,this);return}this._enter(null,this)}},n.dispose=function(){clearTimeout(this._timeout);t.removeData(this.element,this.constructor.DATA_KEY);t(this.element).off(this.constructor.EVENT_KEY);t(this.element).closest(".modal").off("hide.bs.modal");this.tip&&t(this.tip).remove();this._isEnabled=null;this._timeout=null;this._hoverState=null;this._activeTrigger=null;this._popper!==null&&this._popper.destroy();this._popper=null;this.element=null;this.config=null;this.tip=null},n.show=function(){var n=this,f,e,c,u,o,l,s,a,h,v;if(t(this.element).css("display")==="none")throw new Error("Please use show on visible elements");if(f=t.Event(this.constructor.Event.SHOW),this.isWithContent()&&this._isEnabled){if(t(this.element).trigger(f),e=r.findShadowRoot(this.element),c=t.contains(e!==null?e:this.element.ownerDocument.documentElement,this.element),f.isDefaultPrevented()||!c)return;if(u=this.getTipElement(),o=r.getUID(this.constructor.NAME),u.setAttribute("id",o),this.element.setAttribute("aria-describedby",o),this.setContent(),this.config.animation&&t(u).addClass(tt.FADE),l=typeof this.config.placement=="function"?this.config.placement.call(this,u,this.element):this.config.placement,s=this._getAttachment(l),this.addAttachmentClass(s),a=this._getContainer(),t(u).data(this.constructor.DATA_KEY,this),t.contains(this.element.ownerDocument.documentElement,this.tip)||t(u).appendTo(a),t(this.element).trigger(this.constructor.Event.INSERTED),this._popper=new i(this.element,u,{placement:s,modifiers:{offset:this._getOffset(),flip:{behavior:this.config.fallbackPlacement},arrow:{element:yu.ARROW},preventOverflow:{boundariesElement:this.config.boundary}},onCreate:function(t){t.originalPlacement!==t.placement&&n._handlePopperPlacementChange(t)},onUpdate:function(t){return n._handlePopperPlacementChange(t)}}),t(u).addClass(tt.SHOW),"ontouchstart"in document.documentElement)t(document.body).children().on("mouseover",null,t.noop);h=function(){n.config.animation&&n._fixTransition();var i=n._hoverState;n._hoverState=null;t(n.element).trigger(n.constructor.Event.SHOWN);i===st.OUT&&n._leave(null,n)};t(this.tip).hasClass(tt.FADE)?(v=r.getTransitionDurationFromElement(this.tip),t(this.tip).one(r.TRANSITION_END,h).emulateTransitionEnd(v)):h()}},n.hide=function(n){var i=this,u=this.getTipElement(),f=t.Event(this.constructor.Event.HIDE),e=function(){i._hoverState!==st.SHOW&&u.parentNode&&u.parentNode.removeChild(u);i._cleanTipClass();i.element.removeAttribute("aria-describedby");t(i.element).trigger(i.constructor.Event.HIDDEN);i._popper!==null&&i._popper.destroy();n&&n()},o;(t(this.element).trigger(f),f.isDefaultPrevented())||(t(u).removeClass(tt.SHOW),"ontouchstart"in document.documentElement&&t(document.body).children().off("mouseover",null,t.noop),this._activeTrigger[it.CLICK]=!1,this._activeTrigger[it.FOCUS]=!1,this._activeTrigger[it.HOVER]=!1,t(this.tip).hasClass(tt.FADE)?(o=r.getTransitionDurationFromElement(u),t(u).one(r.TRANSITION_END,e).emulateTransitionEnd(o)):e(),this._hoverState="")},n.update=function(){this._popper!==null&&this._popper.scheduleUpdate()},n.isWithContent=function(){return Boolean(this.getTitle())},n.addAttachmentClass=function(n){t(this.getTipElement()).addClass(vu+"-"+n)},n.getTipElement=function(){return this.tip=this.tip||t(this.config.template)[0],this.tip},n.setContent=function(){var n=this.getTipElement();this.setElementContent(t(n.querySelectorAll(yu.TOOLTIP_INNER)),this.getTitle());t(n).removeClass(tt.FADE+" "+tt.SHOW)},n.setElementContent=function(n,i){if(typeof i=="object"&&(i.nodeType||i.jquery)){this.config.html?t(i).parent().is(n)||n.empty().append(i):n.text(t(i).text());return}this.config.html?(this.config.sanitize&&(i=au(i,this.config.whiteList,this.config.sanitizeFn)),n.html(i)):n.text(i)},n.getTitle=function(){var n=this.element.getAttribute("data-original-title");return n||(n=typeof this.config.title=="function"?this.config.title.call(this.element):this.config.title),n},n._getOffset=function(){var t=this,n={};return typeof this.config.offset=="function"?n.fn=function(n){return n.offsets=o({},n.offsets,t.config.offset(n.offsets,t.element)||{}),n}:n.offset=this.config.offset,n},n._getContainer=function(){return this.config.container===!1?document.body:r.isElement(this.config.container)?t(this.config.container):t(document).find(this.config.container)},n._getAttachment=function(n){return ge[n.toUpperCase()]},n._setListeners=function(){var n=this,i=this.config.trigger.split(" ");i.forEach(function(i){if(i==="click")t(n.element).on(n.constructor.Event.CLICK,n.config.selector,function(t){return n.toggle(t)});else if(i!==it.MANUAL){var r=i===it.HOVER?n.constructor.Event.MOUSEENTER:n.constructor.Event.FOCUSIN,u=i===it.HOVER?n.constructor.Event.MOUSELEAVE:n.constructor.Event.FOCUSOUT;t(n.element).on(r,n.config.selector,function(t){return n._enter(t)}).on(u,n.config.selector,function(t){return n._leave(t)})}});t(this.element).closest(".modal").on("hide.bs.modal",function(){n.element&&n.hide()});this.config.selector?this.config=o({},this.config,{trigger:"manual",selector:""}):this._fixTitle()},n._fixTitle=function(){var n=typeof this.element.getAttribute("data-original-title");(this.element.getAttribute("title")||n!=="string")&&(this.element.setAttribute("data-original-title",this.element.getAttribute("title")||""),this.element.setAttribute("title",""))},n._enter=function(n,i){var r=this.constructor.DATA_KEY;if(i=i||t(n.currentTarget).data(r),i||(i=new this.constructor(n.currentTarget,this._getDelegateConfig()),t(n.currentTarget).data(r,i)),n&&(i._activeTrigger[n.type==="focusin"?it.FOCUS:it.HOVER]=!0),t(i.getTipElement()).hasClass(tt.SHOW)||i._hoverState===st.SHOW){i._hoverState=st.SHOW;return}if(clearTimeout(i._timeout),i._hoverState=st.SHOW,!i.config.delay||!i.config.delay.show){i.show();return}i._timeout=setTimeout(function(){i._hoverState===st.SHOW&&i.show()},i.config.delay.show)},n._leave=function(n,i){var r=this.constructor.DATA_KEY;if(i=i||t(n.currentTarget).data(r),i||(i=new this.constructor(n.currentTarget,this._getDelegateConfig()),t(n.currentTarget).data(r,i)),n&&(i._activeTrigger[n.type==="focusout"?it.FOCUS:it.HOVER]=!1),!i._isWithActiveTrigger()){if(clearTimeout(i._timeout),i._hoverState=st.OUT,!i.config.delay||!i.config.delay.hide){i.hide();return}i._timeout=setTimeout(function(){i._hoverState===st.OUT&&i.hide()},i.config.delay.hide)}},n._isWithActiveTrigger=function(){for(var n in this._activeTrigger)if(this._activeTrigger[n])return!0;return!1},n._getConfig=function(n){var i=t(this.element).data();return Object.keys(i).forEach(function(n){ke.indexOf(n)!==-1&&delete i[n]}),n=o({},this.constructor.Default,i,typeof n=="object"&&n?n:{}),typeof n.delay=="number"&&(n.delay={show:n.delay,hide:n.delay}),typeof n.title=="number"&&(n.title=n.title.toString()),typeof n.content=="number"&&(n.content=n.content.toString()),r.typeCheckConfig(vt,n,this.constructor.DefaultType),n.sanitize&&(n.template=au(n.template,n.whiteList,n.sanitizeFn)),n},n._getDelegateConfig=function(){var t={},n;if(this.config)for(n in this.config)this.constructor.Default[n]!==this.config[n]&&(t[n]=this.config[n]);return t},n._cleanTipClass=function(){var i=t(this.getTipElement()),n=i.attr("class").match(be);n!==null&&n.length&&i.removeClass(n.join(""))},n._handlePopperPlacementChange=function(n){var t=n.instance;this.tip=t.popper;this._cleanTipClass();this.addAttachmentClass(this._getAttachment(n.placement))},n._fixTransition=function(){var n=this.getTipElement(),i=this.config.animation;n.getAttribute("x-placement")===null&&(t(n).removeClass(tt.FADE),this.config.animation=!1,this.hide(),this.show(),this.config.animation=i)},u._jQueryInterface=function(n){return this.each(function(){var i=t(this).data(ur),r=typeof n=="object"&&n;if((i||!/dispose|hide/.test(n))&&(i||(i=new u(this,r),t(this).data(ur,i)),typeof n=="string")){if(typeof i[n]=="undefined")throw new TypeError('No method named "'+n+'"');i[n]()}})},p(u,null,[{key:"VERSION",get:function(){return pe}},{key:"Default",get:function(){return no}},{key:"NAME",get:function(){return vt}},{key:"DATA_KEY",get:function(){return ur}},{key:"Event",get:function(){return to}},{key:"EVENT_KEY",get:function(){return w}},{key:"DefaultType",get:function(){return de}}]),u}();t.fn[vt]=yt._jQueryInterface;t.fn[vt].Constructor=yt;t.fn[vt].noConflict=function(){return t.fn[vt]=we,yt._jQueryInterface};var ii="popover",io="4.3.1",fr="bs.popover",b="."+fr,ro=t.fn[ii],pu="bs-popover",uo=new RegExp("(^|\\s)"+pu+"\\S+","g"),fo=o({},yt.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>'}),eo=o({},yt.DefaultType,{content:"(string|element|function)"}),wu={FADE:"fade",SHOW:"show"},bu={TITLE:".popover-header",CONTENT:".popover-body"},oo={HIDE:"hide"+b,HIDDEN:"hidden"+b,SHOW:"show"+b,SHOWN:"shown"+b,INSERTED:"inserted"+b,CLICK:"click"+b,FOCUSIN:"focusin"+b,FOCUSOUT:"focusout"+b,MOUSEENTER:"mouseenter"+b,MOUSELEAVE:"mouseleave"+b},er=function(n){function i(){return n.apply(this,arguments)||this}nf(i,n);var r=i.prototype;return r.isWithContent=function(){return this.getTitle()||this._getContent()},r.addAttachmentClass=function(n){t(this.getTipElement()).addClass(pu+"-"+n)},r.getTipElement=function(){return this.tip=this.tip||t(this.config.template)[0],this.tip},r.setContent=function(){var i=t(this.getTipElement()),n;this.setElementContent(i.find(bu.TITLE),this.getTitle());n=this._getContent();typeof n=="function"&&(n=n.call(this.element));this.setElementContent(i.find(bu.CONTENT),n);i.removeClass(wu.FADE+" "+wu.SHOW)},r._getContent=function(){return this.element.getAttribute("data-content")||this.config.content},r._cleanTipClass=function(){var i=t(this.getTipElement()),n=i.attr("class").match(uo);n!==null&&n.length>0&&i.removeClass(n.join(""))},i._jQueryInterface=function(n){return this.each(function(){var r=t(this).data(fr),u=typeof n=="object"?n:null;if((r||!/dispose|hide/.test(n))&&(r||(r=new i(this,u),t(this).data(fr,r)),typeof n=="string")){if(typeof r[n]=="undefined")throw new TypeError('No method named "'+n+'"');r[n]()}})},p(i,null,[{key:"VERSION",get:function(){return io}},{key:"Default",get:function(){return fo}},{key:"NAME",get:function(){return ii}},{key:"DATA_KEY",get:function(){return fr}},{key:"Event",get:function(){return oo}},{key:"EVENT_KEY",get:function(){return b}},{key:"DefaultType",get:function(){return eo}}]),i}(yt);t.fn[ii]=er._jQueryInterface;t.fn[ii].Constructor=er;t.fn[ii].noConflict=function(){return t.fn[ii]=ro,er._jQueryInterface};var pt="scrollspy",so="4.3.1",or="bs.scrollspy",sr="."+or,ho=t.fn[pt],ku={offset:10,method:"auto",target:""},co={offset:"number",method:"string",target:"(string|element)"},uu={ACTIVATE:"activate"+sr,SCROLL:"scroll"+sr,LOAD_DATA_API:"load"+sr+".data-api"},ht={DROPDOWN_ITEM:"dropdown-item",DROPDOWN_MENU:"dropdown-menu",ACTIVE:"active"},y={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"},fu={OFFSET:"offset",POSITION:"position"},pi=function(){function i(n,i){var r=this;this._element=n;this._scrollElement=n.tagName==="BODY"?window:n;this._config=this._getConfig(i);this._selector=this._config.target+" "+y.NAV_LINKS+","+(this._config.target+" "+y.LIST_ITEMS+",")+(this._config.target+" "+y.DROPDOWN_ITEMS);this._offsets=[];this._targets=[];this._activeTarget=null;this._scrollHeight=0;t(this._scrollElement).on(uu.SCROLL,function(n){return r._process(n)});this.refresh();this._process()}var n=i.prototype;return n.refresh=function(){var n=this,f=this._scrollElement===this._scrollElement.window?fu.OFFSET:fu.POSITION,i=this._config.method==="auto"?f:this._config.method,e=i===fu.POSITION?this._getScrollTop():0,u;this._offsets=[];this._targets=[];this._scrollHeight=this._getScrollHeight();u=[].slice.call(document.querySelectorAll(this._selector));u.map(function(n){var u,f=r.getSelectorFromElement(n),o;return(f&&(u=document.querySelector(f)),u&&(o=u.getBoundingClientRect(),o.width||o.height))?[t(u)[i]().top+e,f]:null}).filter(function(n){return n}).sort(function(n,t){return n[0]-t[0]}).forEach(function(t){n._offsets.push(t[0]);n._targets.push(t[1])})},n.dispose=function(){t.removeData(this._element,or);t(this._scrollElement).off(sr);this._element=null;this._scrollElement=null;this._config=null;this._selector=null;this._offsets=null;this._targets=null;this._activeTarget=null;this._scrollHeight=null},n._getConfig=function(n){if(n=o({},ku,typeof n=="object"&&n?n:{}),typeof n.target!="string"){var i=t(n.target).attr("id");i||(i=r.getUID(pt),t(n.target).attr("id",i));n.target="#"+i}return r.typeCheckConfig(pt,n,co),n},n._getScrollTop=function(){return this._scrollElement===window?this._scrollElement.pageYOffset:this._scrollElement.scrollTop},n._getScrollHeight=function(){return this._scrollElement.scrollHeight||Math.max(document.body.scrollHeight,document.documentElement.scrollHeight)},n._getOffsetHeight=function(){return this._scrollElement===window?window.innerHeight:this._scrollElement.getBoundingClientRect().height},n._process=function(){var t=this._getScrollTop()+this._config.offset,r=this._getScrollHeight(),e=this._config.offset+r-this._getOffsetHeight(),i,u,n,f;if(this._scrollHeight!==r&&this.refresh(),t>=e){i=this._targets[this._targets.length-1];this._activeTarget!==i&&this._activate(i);return}if(this._activeTarget&&t<this._offsets[0]&&this._offsets[0]>0){this._activeTarget=null;this._clear();return}for(u=this._offsets.length,n=u;n--;)f=this._activeTarget!==this._targets[n]&&t>=this._offsets[n]&&(typeof this._offsets[n+1]=="undefined"||t<this._offsets[n+1]),f&&this._activate(this._targets[n])},n._activate=function(n){this._activeTarget=n;this._clear();var r=this._selector.split(",").map(function(t){return t+'[data-target="'+n+'"],'+t+'[href="'+n+'"]'}),i=t([].slice.call(document.querySelectorAll(r.join(","))));i.hasClass(ht.DROPDOWN_ITEM)?(i.closest(y.DROPDOWN).find(y.DROPDOWN_TOGGLE).addClass(ht.ACTIVE),i.addClass(ht.ACTIVE)):(i.addClass(ht.ACTIVE),i.parents(y.NAV_LIST_GROUP).prev(y.NAV_LINKS+", "+y.LIST_ITEMS).addClass(ht.ACTIVE),i.parents(y.NAV_LIST_GROUP).prev(y.NAV_ITEMS).children(y.NAV_LINKS).addClass(ht.ACTIVE));t(this._scrollElement).trigger(uu.ACTIVATE,{relatedTarget:n})},n._clear=function(){[].slice.call(document.querySelectorAll(this._selector)).filter(function(n){return n.classList.contains(ht.ACTIVE)}).forEach(function(n){return n.classList.remove(ht.ACTIVE)})},i._jQueryInterface=function(n){return this.each(function(){var r=t(this).data(or),u=typeof n=="object"&&n;if(r||(r=new i(this,u),t(this).data(or,r)),typeof n=="string"){if(typeof r[n]=="undefined")throw new TypeError('No method named "'+n+'"');r[n]()}})},p(i,null,[{key:"VERSION",get:function(){return so}},{key:"Default",get:function(){return ku}}]),i}();t(window).on(uu.LOAD_DATA_API,function(){for(var n,i=[].slice.call(document.querySelectorAll(y.DATA_SPY)),u=i.length,r=u;r--;)n=t(i[r]),pi._jQueryInterface.call(n,n.data())});t.fn[pt]=pi._jQueryInterface;t.fn[pt].Constructor=pi;t.fn[pt].noConflict=function(){return t.fn[pt]=ho,pi._jQueryInterface};var wi="tab",lo="4.3.1",hr="bs.tab",bi="."+hr,ao=t.fn[wi],ki={HIDE:"hide"+bi,HIDDEN:"hidden"+bi,SHOW:"show"+bi,SHOWN:"shown"+bi,CLICK_DATA_API:"click"+bi+".data-api"},k={DROPDOWN_MENU:"dropdown-menu",ACTIVE:"active",DISABLED:"disabled",FADE:"fade",SHOW:"show"},ft={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"},di=function(){function n(n){this._element=n}var i=n.prototype;return i.show=function(){var h=this,u,n,i,f,c,e,o,s;this._element.parentNode&&this._element.parentNode.nodeType===Node.ELEMENT_NODE&&t(this._element).hasClass(k.ACTIVE)||t(this._element).hasClass(k.DISABLED)||(i=t(this._element).closest(ft.NAV_LIST_GROUP)[0],f=r.getSelectorFromElement(this._element),i&&(c=i.nodeName==="UL"||i.nodeName==="OL"?ft.ACTIVE_UL:ft.ACTIVE,n=t.makeArray(t(i).find(c)),n=n[n.length-1]),e=t.Event(ki.HIDE,{relatedTarget:this._element}),o=t.Event(ki.SHOW,{relatedTarget:n}),n&&t(n).trigger(e),t(this._element).trigger(o),o.isDefaultPrevented()||e.isDefaultPrevented())||(f&&(u=document.querySelector(f)),this._activate(this._element,i),s=function(){var i=t.Event(ki.HIDDEN,{relatedTarget:h._element}),r=t.Event(ki.SHOWN,{relatedTarget:n});t(n).trigger(i);t(h._element).trigger(r)},u?this._activate(u,u.parentNode,s):s())},i.dispose=function(){t.removeData(this._element,hr);this._element=null},i._activate=function(n,i,u){var s=this,h=i&&(i.nodeName==="UL"||i.nodeName==="OL")?t(i).find(ft.ACTIVE_UL):t(i).children(ft.ACTIVE),f=h[0],c=u&&f&&t(f).hasClass(k.FADE),e=function(){return s._transitionComplete(n,f,u)},o;f&&c?(o=r.getTransitionDurationFromElement(f),t(f).removeClass(k.SHOW).one(r.TRANSITION_END,e).emulateTransitionEnd(o)):e()},i._transitionComplete=function(n,i,u){var f,e,o;i&&(t(i).removeClass(k.ACTIVE),f=t(i.parentNode).find(ft.DROPDOWN_ACTIVE_CHILD)[0],f&&t(f).removeClass(k.ACTIVE),i.getAttribute("role")==="tab"&&i.setAttribute("aria-selected",!1));t(n).addClass(k.ACTIVE);n.getAttribute("role")==="tab"&&n.setAttribute("aria-selected",!0);r.reflow(n);n.classList.contains(k.FADE)&&n.classList.add(k.SHOW);n.parentNode&&t(n.parentNode).hasClass(k.DROPDOWN_MENU)&&(e=t(n).closest(ft.DROPDOWN)[0],e&&(o=[].slice.call(e.querySelectorAll(ft.DROPDOWN_TOGGLE)),t(o).addClass(k.ACTIVE)),n.setAttribute("aria-expanded",!0));u&&u()},n._jQueryInterface=function(i){return this.each(function(){var u=t(this),r=u.data(hr);if(r||(r=new n(this),u.data(hr,r)),typeof i=="string"){if(typeof r[i]=="undefined")throw new TypeError('No method named "'+i+'"');r[i]()}})},p(n,null,[{key:"VERSION",get:function(){return lo}}]),n}();t(document).on(ki.CLICK_DATA_API,ft.DATA_TOGGLE,function(n){n.preventDefault();di._jQueryInterface.call(t(this),"show")});t.fn[wi]=di._jQueryInterface;t.fn[wi].Constructor=di;t.fn[wi].noConflict=function(){return t.fn[wi]=ao,di._jQueryInterface};var ri="toast",vo="4.3.1",cr="bs.toast",gi="."+cr,yo=t.fn[ri],ui={CLICK_DISMISS:"click.dismiss"+gi,HIDE:"hide"+gi,HIDDEN:"hidden"+gi,SHOW:"show"+gi,SHOWN:"shown"+gi},rt={FADE:"fade",HIDE:"hide",SHOW:"show",SHOWING:"showing"},po={animation:"boolean",autohide:"boolean",delay:"number"},du={animation:!0,autohide:!0,delay:500},wo={DATA_DISMISS:'[data-dismiss="toast"]'},lr=function(){function i(n,t){this._element=n;this._config=this._getConfig(t);this._timeout=null;this._setListeners()}var n=i.prototype;return n.show=function(){var n=this,i,u;t(this._element).trigger(ui.SHOW);this._config.animation&&this._element.classList.add(rt.FADE);i=function(){n._element.classList.remove(rt.SHOWING);n._element.classList.add(rt.SHOW);t(n._element).trigger(ui.SHOWN);n._config.autohide&&n.hide()};this._element.classList.remove(rt.HIDE);this._element.classList.add(rt.SHOWING);this._config.animation?(u=r.getTransitionDurationFromElement(this._element),t(this._element).one(r.TRANSITION_END,i).emulateTransitionEnd(u)):i()},n.hide=function(n){var i=this;this._element.classList.contains(rt.SHOW)&&(t(this._element).trigger(ui.HIDE),n?this._close():this._timeout=setTimeout(function(){i._close()},this._config.delay))},n.dispose=function(){clearTimeout(this._timeout);this._timeout=null;this._element.classList.contains(rt.SHOW)&&this._element.classList.remove(rt.SHOW);t(this._element).off(ui.CLICK_DISMISS);t.removeData(this._element,cr);this._element=null;this._config=null},n._getConfig=function(n){return n=o({},du,t(this._element).data(),typeof n=="object"&&n?n:{}),r.typeCheckConfig(ri,n,this.constructor.DefaultType),n},n._setListeners=function(){var n=this;t(this._element).on(ui.CLICK_DISMISS,wo.DATA_DISMISS,function(){return n.hide(!0)})},n._close=function(){var n=this,i=function(){n._element.classList.add(rt.HIDE);t(n._element).trigger(ui.HIDDEN)},u;this._element.classList.remove(rt.SHOW);this._config.animation?(u=r.getTransitionDurationFromElement(this._element),t(this._element).one(r.TRANSITION_END,i).emulateTransitionEnd(u)):i()},i._jQueryInterface=function(n){return this.each(function(){var u=t(this),r=u.data(cr),f=typeof n=="object"&&n;if(r||(r=new i(this,f),u.data(cr,r)),typeof n=="string"){if(typeof r[n]=="undefined")throw new TypeError('No method named "'+n+'"');r[n](this)}})},p(i,null,[{key:"VERSION",get:function(){return vo}},{key:"DefaultType",get:function(){return po}},{key:"Default",get:function(){return du}}]),i}();t.fn[ri]=lr._jQueryInterface;t.fn[ri].Constructor=lr;t.fn[ri].noConflict=function(){return t.fn[ri]=yo,lr._jQueryInterface},function(){if(typeof t=="undefined")throw new TypeError("Bootstrap's JavaScript requires jQuery. jQuery must be included before Bootstrap's JavaScript.");var n=t.fn.jquery.split(" ")[0].split("."),i=9;if(n[0]<2&&n[1]<i||n[0]===1&&n[1]===i&&n[2]<1||n[0]>=4)throw new Error("Bootstrap's JavaScript requires at least jQuery v1.9.1 but less than v4.0.0");}();n.Util=r;n.Alert=wt;n.Button=oi;n.Carousel=kt;n.Collapse=li;n.Dropdown=et;n.Modal=yi;n.Popover=er;n.Scrollspy=pi;n.Tab=di;n.Toast=lr;n.Tooltip=yt;Object.defineProperty(n,"__esModule",{value:!0})}),function(){"use strict";var r;if(typeof window!="undefined"&&window.addEventListener){var n=Object.create(null),u,f,t=function(){clearTimeout(f);f=setTimeout(u,100)},i=function(){return},o=function(){var n;window.addEventListener("resize",t,!1);window.addEventListener("orientationchange",t,!1);window.MutationObserver?(n=new MutationObserver(t),n.observe(document.documentElement,{childList:!0,subtree:!0,attributes:!0}),i=function(){try{n.disconnect();window.removeEventListener("resize",t,!1);window.removeEventListener("orientationchange",t,!1)}catch(i){}}):(document.documentElement.addEventListener("DOMSubtreeModified",t,!1),i=function(){document.documentElement.removeEventListener("DOMSubtreeModified",t,!1);window.removeEventListener("resize",t,!1);window.removeEventListener("orientationchange",t,!1)})},s=function(n){function r(n){var t;return n.protocol!==undefined?t=n:(t=document.createElement("a"),t.href=n),t.protocol.replace(/:/g,"")+t.host}var t,u,i;return window.XMLHttpRequest&&(t=new XMLHttpRequest,u=r(location),i=r(n),t=t.withCredentials===undefined&&i!==""&&i!==u?XDomainRequest||undefined:XMLHttpRequest),t},e="http://www.w3.org/1999/xlink";u=function(){function w(){a-=1;a===0&&(i(),o())}function k(t){return function(){n[t.base]!==!0&&(t.useEl.setAttributeNS(e,"xlink:href","#"+t.hash),t.useEl.hasAttribute("href")&&t.useEl.setAttribute("href","#"+t.hash))}}function g(n){return function(){var i=document.body,r=document.createElement("x"),t;n.onload=null;r.innerHTML=n.responseText;t=r.getElementsByTagName("svg")[0];t&&(t.setAttribute("aria-hidden","true"),t.style.position="absolute",t.style.width=0,t.style.height=0,t.style.overflow="hidden",i.insertBefore(t,i.firstChild));w()}}function d(n){return function(){n.onerror=null;n.ontimeout=null;w()}}var t,h,b="",c,l,u,a=0,v,y,p,f,r;for(i(),f=document.getElementsByTagName("use"),u=0;u<f.length;u+=1){try{h=f[u].getBoundingClientRect()}catch(nt){h=!1}l=f[u].getAttribute("href")||f[u].getAttributeNS(e,"href")||f[u].getAttribute("xlink:href");p=l&&l.split?l.split("#"):["",""];t=p[0];c=p[1];v=h&&h.left===0&&h.right===0&&h.top===0&&h.bottom===0;h&&h.width===0&&h.height===0&&!v?(b&&!t.length&&c&&!document.getElementById(c)&&(t=b),f[u].hasAttribute("href")&&f[u].setAttributeNS(e,"xlink:href",l),t.length&&(r=n[t],r!==!0&&setTimeout(k({useEl:f[u],base:t,hash:c}),0),r===undefined&&(y=s(t),y!==undefined&&(r=new y,n[t]=r,r.onload=g(r),r.onerror=d(r),r.ontimeout=d(r),r.open("GET",t),r.send(),a+=1)))):v?t.length&&n[t]&&setTimeout(k({useEl:f[u],base:t,hash:c}),0):n[t]===undefined?n[t]=!0:n[t].onload&&(n[t].abort(),delete n[t].onload,n[t]=!0)}f="";a+=1;w()};r=function(){window.removeEventListener("load",r,!1);f=setTimeout(u,0)};document.readyState!=="complete"?window.addEventListener("load",r,!1):r()}}(),function(n){"use strict";typeof define=="function"&&define.amd?define(["jquery"],n):typeof exports=="object"&&typeof require=="function"?n(require("jquery")):n(jQuery)}(function(n){"use strict";function i(t,r){var u=this;u.element=t;u.el=n(t);u.suggestions=[];u.badQueries=[];u.selectedIndex=-1;u.currentValue=u.element.value;u.timeoutId=null;u.cachedResponse={};u.onChangeTimeout=null;u.onChange=null;u.isLocal=!1;u.suggestionsContainer=null;u.noSuggestionsContainer=null;u.options=n.extend(!0,{},i.defaults,r);u.classes={selected:"autocomplete-selected",suggestion:"autocomplete-suggestion"};u.hint=null;u.hintValue="";u.selection=null;u.initialize();u.setOptions(r)}function f(n,t,i){return n.value.toLowerCase().indexOf(i)!==-1}function e(t){return typeof t=="string"?n.parseJSON(t):t}function o(n,t){if(!t)return n.value;var i="("+u.escapeRegExChars(t)+")";return n.value.replace(new RegExp(i,"gi"),"<strong>$1<\/strong>").replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/"/g,"&quot;").replace(/&lt;(\/?strong)&gt;/g,"<$1>")}function s(n,t){return'<div class="autocomplete-group">'+t+"<\/div>"}var u=function(){return{escapeRegExChars:function(n){return n.replace(/[|\\{}()[\]^$+*?.]/g,"\\$&")},createNode:function(n,t){var i=document.createElement("div");return i.id=t,i.className=n,i.setAttribute("role","listbox"),i.style.position="absolute",i.style.display="none",i}}}(),t={ESC:27,TAB:9,RETURN:13,LEFT:37,UP:38,RIGHT:39,DOWN:40},r=n.noop;i.utils=u;n.Autocomplete=i;i.defaults={ajaxSettings:{},autoSelectFirst:!1,appendTo:"body",serviceUrl:null,lookup:null,onSelect:null,width:"auto",minChars:1,maxHeight:300,deferRequestBy:0,params:{},formatResult:o,formatGroup:s,delimiter:null,zIndex:9999,type:"GET",noCache:!1,onSearchStart:r,onSearchComplete:r,onSearchError:r,preserveInput:!1,containerClass:"autocomplete-suggestions",tabDisabled:!1,dataType:"text",currentRequest:null,triggerSelectOnValidInput:!0,preventBadQueries:!0,lookupFilter:f,paramName:"query",transformResult:e,showNoSuggestionNotice:!1,noSuggestionNotice:"No results",orientation:"bottom",forceFixPosition:!1};i.prototype={initialize:function(){var t=this,f="."+t.classes.suggestion,e=t.classes.selected,u=t.options,r,o;t.element.setAttribute("autocomplete","off");o=t.element.id+"Suggestions";t.noSuggestionsContainer=n("<div id="+t.element.name+' class="autocomplete-no-suggestion"><\/div>').html(this.options.noSuggestionNotice).get(0);t.suggestionsContainer=i.utils.createNode(u.containerClass,o);r=n(t.suggestionsContainer);r.appendTo(u.appendTo||"body");u.width!=="auto"&&r.css("width",u.width);r.on("mouseover.autocomplete",f,function(){t.activate(n(this).data("index"))});r.on("mouseout.autocomplete",function(){t.selectedIndex=-1;r.children("."+e).removeClass(e)});r.on("click.autocomplete",f,function(){t.select(n(this).data("index"))});r.on("click.autocomplete",function(){clearTimeout(t.blurTimeoutId)});t.fixPositionCapture=function(){t.visible&&t.fixPosition()};n(window).on("resize.autocomplete",t.fixPositionCapture);t.el.on("keydown.autocomplete",function(n){t.onKeyPress(n)});t.el.on("keyup.autocomplete",function(n){t.onKeyUp(n)});t.el.on("blur.autocomplete",function(){t.onBlur()});t.el.on("focus.autocomplete",function(){t.onFocus()});t.el.on("change.autocomplete",function(n){t.onKeyUp(n)});t.el.on("input.autocomplete",function(n){t.onKeyUp(n)})},onFocus:function(){var n=this;n.fixPosition();n.el.val().length>=n.options.minChars&&n.onValueChange()},onBlur:function(){var t=this,i=t.options,r=t.el.val(),u=t.getQuery(r);t.blurTimeoutId=setTimeout(function(){t.hide();t.selection&&t.currentValue!==u&&(i.onInvalidateSelection||n.noop).call(t.element)},200)},abortAjax:function(){var n=this;n.currentRequest&&(n.currentRequest.abort(),n.currentRequest=null)},setOptions:function(t){var r=this,i=n.extend({},r.options,t);r.isLocal=Array.isArray(i.lookup);r.isLocal&&(i.lookup=r.verifySuggestionsFormat(i.lookup));i.orientation=r.validateOrientation(i.orientation,"bottom");n(r.suggestionsContainer).css({"max-height":i.maxHeight+"px",width:i.width+"px","z-index":i.zIndex});this.options=i},clearCache:function(){this.cachedResponse={};this.badQueries=[]},clear:function(){this.clearCache();this.currentValue="";this.suggestions=[]},disable:function(){var n=this;n.disabled=!0;clearTimeout(n.onChangeTimeout);n.abortAjax()},enable:function(){this.disabled=!1},fixPosition:function(){var t=this,i=n(t.suggestionsContainer),f=i.parent().get(0),a,s;if(f===document.body||t.options.forceFixPosition){var e=t.options.orientation,o=i.outerHeight(),h=t.el.outerHeight(),u=t.el.offset(),r={top:u.top,left:u.left};if(e==="auto"){var v=n(window).height(),c=n(window).scrollTop(),l=-c+u.top-o,y=c+v-(u.top+h+o);e=Math.max(l,y)===l?"top":"bottom"}r.top+=e==="top"?-o:h;f!==document.body&&(a=i.css("opacity"),t.visible||i.css("opacity",0).show(),s=i.offsetParent().offset(),r.top-=s.top,r.top+=f.scrollTop,r.left-=s.left,t.visible||i.css("opacity",a).hide());t.options.width==="auto"&&(r.width=t.el.outerWidth()+"px");i.css(r)}},isCursorAtEnd:function(){var i=this,n=i.el.val().length,r=i.element.selectionStart,t;return typeof r=="number"?r===n:document.selection?(t=document.selection.createRange(),t.moveStart("character",-n),n===t.text.length):!0},onKeyPress:function(n){var i=this;if(!i.disabled&&!i.visible&&n.which===t.DOWN&&i.currentValue){i.suggest();return}if(!i.disabled&&i.visible){switch(n.which){case t.ESC:i.el.val(i.currentValue);i.hide();break;case t.RIGHT:if(i.hint&&i.options.onHint&&i.isCursorAtEnd()){i.selectHint();break}return;case t.TAB:if(i.hint&&i.options.onHint){i.selectHint();return}if(i.selectedIndex===-1){i.hide();return}if(i.select(i.selectedIndex),i.options.tabDisabled===!1)return;break;case t.RETURN:if(i.selectedIndex===-1){i.hide();return}i.select(i.selectedIndex);break;case t.UP:i.moveUp();break;case t.DOWN:i.moveDown();break;default:return}n.stopImmediatePropagation();n.preventDefault()}},onKeyUp:function(n){var i=this;if(!i.disabled){switch(n.which){case t.UP:case t.DOWN:return}clearTimeout(i.onChangeTimeout);i.currentValue!==i.el.val()&&(i.findBestHint(),i.options.deferRequestBy>0?i.onChangeTimeout=setTimeout(function(){i.onValueChange()},i.options.deferRequestBy):i.onValueChange())}},onValueChange:function(){if(this.ignoreValueChange){this.ignoreValueChange=!1;return}var t=this,r=t.options,u=t.el.val(),i=t.getQuery(u);if(t.selection&&t.currentValue!==i&&(t.selection=null,(r.onInvalidateSelection||n.noop).call(t.element)),clearTimeout(t.onChangeTimeout),t.currentValue=u,t.selectedIndex=-1,r.triggerSelectOnValidInput&&t.isExactMatch(i)){t.select(0);return}i.length<r.minChars?t.hide():t.getSuggestions(i)},isExactMatch:function(n){var t=this.suggestions;return t.length===1&&t[0].value.toLowerCase()===n.toLowerCase()},getQuery:function(t){var r=this.options.delimiter,i;return r?(i=t.split(r),n.trim(i[i.length-1])):t},getSuggestionsLocal:function(t){var f=this,r=f.options,e=t.toLowerCase(),o=r.lookupFilter,u=parseInt(r.lookupLimit,10),i;return i={suggestions:n.grep(r.lookup,function(n){return o(n,t,e)})},u&&i.suggestions.length>u&&(i.suggestions=i.suggestions.slice(0,u)),i},getSuggestions:function(t){var u,i=this,r=i.options,f=r.serviceUrl,e,o,s;if(r.params[r.paramName]=t,r.onSearchStart.call(i.element,r.params)!==!1){if(e=r.ignoreParams?null:r.params,n.isFunction(r.lookup)){r.lookup(t,function(n){i.suggestions=n.suggestions;i.suggest();r.onSearchComplete.call(i.element,t,n.suggestions)});return}i.isLocal?u=i.getSuggestionsLocal(t):(n.isFunction(f)&&(f=f.call(i.element,t)),o=f+"?"+n.param(e||{}),u=i.cachedResponse[o]);u&&Array.isArray(u.suggestions)?(i.suggestions=u.suggestions,i.suggest(),r.onSearchComplete.call(i.element,t,u.suggestions)):i.isBadQuery(t)?r.onSearchComplete.call(i.element,t,[]):(i.abortAjax(),s={url:f,data:e,type:r.type,dataType:r.dataType},n.extend(s,r.ajaxSettings),i.currentRequest=n.ajax(s).done(function(n){var u;i.currentRequest=null;u=r.transformResult(n,t);i.processResponse(u,t,o);r.onSearchComplete.call(i.element,t,u.suggestions)}).fail(function(n,u,f){r.onSearchError.call(i.element,t,n,u,f)}))}},isBadQuery:function(n){if(!this.options.preventBadQueries)return!1;for(var t=this.badQueries,i=t.length;i--;)if(n.indexOf(t[i])===0)return!0;return!1},hide:function(){var t=this,i=n(t.suggestionsContainer);n.isFunction(t.options.onHide)&&t.visible&&t.options.onHide.call(t.element,i);t.visible=!1;t.selectedIndex=-1;clearTimeout(t.onChangeTimeout);n(t.suggestionsContainer).hide();t.signalHint(null)},suggest:function(){if(!this.suggestions.length){this.options.showNoSuggestionNotice?this.noSuggestions():this.hide();return}var t=this,i=t.options,o=i.groupBy,c=i.formatResult,u=t.getQuery(t.currentValue),s=t.classes.suggestion,l=t.classes.selected,r=n(t.suggestionsContainer),a=n(t.noSuggestionsContainer),h=i.beforeRender,f="",e,v=function(n){var t=n.data[o];return e===t?"":(e=t,i.formatGroup(n,e))};if(i.triggerSelectOnValidInput&&t.isExactMatch(u)){t.select(0);return}n.each(t.suggestions,function(n,t){o&&(f+=v(t,u,n));f+='<div class="'+s+'" data-index="'+n+'" role="option">'+c(t,u,n)+"<\/div>"});this.adjustContainerWidth();a.detach();r.html(f);n.isFunction(h)&&h.call(t.element,r,t.suggestions);t.fixPosition();r.show();i.autoSelectFirst&&(t.selectedIndex=0,r.scrollTop(0),r.children("."+s).first().addClass(l));t.visible=!0;t.findBestHint()},noSuggestions:function(){var t=this,r=t.options.beforeRender,i=n(t.suggestionsContainer),u=n(t.noSuggestionsContainer);this.adjustContainerWidth();u.detach();i.empty();i.append(u);n.isFunction(r)&&r.call(t.element,i,t.suggestions);t.fixPosition();i.show();t.visible=!0},adjustContainerWidth:function(){var t=this,r=t.options,i,u=n(t.suggestionsContainer);r.width==="auto"?(i=t.el.outerWidth(),u.css("width",i>0?i:300)):r.width==="flex"&&u.css("width","")},findBestHint:function(){var t=this,i=t.el.val().toLowerCase(),r=null;i&&(n.each(t.suggestions,function(n,t){var u=t.value.toLowerCase().indexOf(i)===0;return u&&(r=t),!u}),t.signalHint(r))},signalHint:function(t){var r="",i=this;t&&(r=i.currentValue+t.value.substr(i.currentValue.length));i.hintValue!==r&&(i.hintValue=r,i.hint=t,(this.options.onHint||n.noop)(r))},verifySuggestionsFormat:function(t){return t.length&&typeof t[0]=="string"?n.map(t,function(n){return{value:n,data:null}}):t},validateOrientation:function(t,i){return t=n.trim(t||"").toLowerCase(),n.inArray(t,["auto","bottom","top"])===-1&&(t=i),t},processResponse:function(n,t,i){var r=this,u=r.options;(n.suggestions=r.verifySuggestionsFormat(n.suggestions),u.noCache||(r.cachedResponse[i]=n,u.preventBadQueries&&!n.suggestions.length&&r.badQueries.push(t)),t===r.getQuery(r.currentValue))&&(r.suggestions=n.suggestions,r.suggest())},activate:function(t){var i=this,r,u=i.classes.selected,f=n(i.suggestionsContainer),e=f.find("."+i.classes.suggestion);return(f.find("."+u).removeClass(u),i.selectedIndex=t,i.selectedIndex!==-1&&e.length>i.selectedIndex)?(r=e.get(i.selectedIndex),n(r).addClass(u),r):null},selectHint:function(){var t=this,i=n.inArray(t.hint,t.suggestions);t.select(i)},select:function(n){var t=this;t.hide();t.onSelect(n)},moveUp:function(){var t=this;if(t.selectedIndex!==-1){if(t.selectedIndex===0){n(t.suggestionsContainer).children("."+t.classes.suggestion).first().removeClass(t.classes.selected);t.selectedIndex=-1;t.ignoreValueChange=!1;t.el.val(t.currentValue);t.findBestHint();return}t.adjustScroll(t.selectedIndex-1)}},moveDown:function(){var n=this;n.selectedIndex!==n.suggestions.length-1&&n.adjustScroll(n.selectedIndex+1)},adjustScroll:function(t){var i=this,u=i.activate(t),r,f,o,e;u&&(e=n(u).outerHeight(),r=u.offsetTop,f=n(i.suggestionsContainer).scrollTop(),o=f+i.options.maxHeight-e,r<f?n(i.suggestionsContainer).scrollTop(r):r>o&&n(i.suggestionsContainer).scrollTop(r-i.options.maxHeight+e),i.options.preserveInput||(i.ignoreValueChange=!0,i.el.val(i.getValue(i.suggestions[t].value))),i.signalHint(null))},onSelect:function(t){var i=this,u=i.options.onSelect,r=i.suggestions[t];i.currentValue=i.getValue(r.value);i.currentValue===i.el.val()||i.options.preserveInput||i.el.val(i.currentValue);i.signalHint(null);i.suggestions=[];i.selection=r;n.isFunction(u)&&u.call(i.element,r)},getValue:function(n){var r=this,u=r.options.delimiter,t,i;return u?(t=r.currentValue,i=t.split(u),i.length===1)?n:t.substr(0,t.length-i[i.length-1].length)+n:n},dispose:function(){var t=this;t.el.off(".autocomplete").removeData("autocomplete");n(window).off("resize.autocomplete",t.fixPositionCapture);n(t.suggestionsContainer).remove()}};n.fn.devbridgeAutocomplete=function(t,r){var u="autocomplete";return arguments.length?this.each(function(){var e=n(this),f=e.data(u);typeof t=="string"?f&&typeof f[t]=="function"&&f[t](r):(f&&f.dispose&&f.dispose(),f=new i(this,t),e.data(u,f))}):this.first().data(u)};n.fn.autocomplete||(n.fn.autocomplete=n.fn.devbridgeAutocomplete)}),function(n,t){typeof exports=="object"&&typeof module!="undefined"?module.exports=t():typeof define=="function"&&define.amd?define(t):n.moment=t()}(this,function(){"use strict";function t(){return af.apply(null,arguments)}function gs(n){af=n}function tt(n){return n instanceof Array||Object.prototype.toString.call(n)==="[object Array]"}function li(n){return n!=null&&Object.prototype.toString.call(n)==="[object Object]"}function nh(n){if(Object.getOwnPropertyNames)return Object.getOwnPropertyNames(n).length===0;for(var t in n)if(n.hasOwnProperty(t))return!1;return!0}function p(n){return n===void 0}function dt(n){return typeof n=="number"||Object.prototype.toString.call(n)==="[object Number]"}function gi(n){return n instanceof Date||Object.prototype.toString.call(n)==="[object Date]"}function vf(n,t){for(var r=[],i=0;i<n.length;++i)r.push(t(n[i],i));return r}function l(n,t){return Object.prototype.hasOwnProperty.call(n,t)}function yt(n,t){for(var i in t)l(t,i)&&(n[i]=t[i]);return l(t,"toString")&&(n.toString=t.toString),l(t,"valueOf")&&(n.valueOf=t.valueOf),n}function et(n,t,i,r){return yo(n,t,i,r,!0).utc()}function th(){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 u(n){return n._pf==null&&(n._pf=th()),n._pf}function tu(n){if(n._isValid==null){var t=u(n),r=yf.call(t.parsedDateParts,function(n){return n!=null}),i=!isNaN(n._d.getTime())&&t.overflow<0&&!t.empty&&!t.invalidMonth&&!t.invalidWeekday&&!t.weekdayMismatch&&!t.nullInput&&!t.invalidFormat&&!t.userInvalidated&&(!t.meridiem||t.meridiem&&r);if(n._strict&&(i=i&&t.charsLeftOver===0&&t.unusedTokens.length===0&&t.bigHour===undefined),Object.isFrozen!=null&&Object.isFrozen(n))return i;n._isValid=i}return n._isValid}function nr(n){var t=et(NaN);return n!=null?yt(u(t),n):u(t).userInvalidated=!0,t}function iu(n,t){var i,r,f;if(p(t._isAMomentObject)||(n._isAMomentObject=t._isAMomentObject),p(t._i)||(n._i=t._i),p(t._f)||(n._f=t._f),p(t._l)||(n._l=t._l),p(t._strict)||(n._strict=t._strict),p(t._tzm)||(n._tzm=t._tzm),p(t._isUTC)||(n._isUTC=t._isUTC),p(t._offset)||(n._offset=t._offset),p(t._pf)||(n._pf=u(t)),p(t._locale)||(n._locale=t._locale),tr.length>0)for(i=0;i<tr.length;i++)r=tr[i],f=t[r],p(f)||(n[r]=f);return n}function ai(n){iu(this,n);this._d=new Date(n._d!=null?n._d.getTime():NaN);this.isValid()||(this._d=new Date(NaN));ir===!1&&(ir=!0,t.updateOffset(this),ir=!1)}function pt(n){return n instanceof ai||n!=null&&n._isAMomentObject!=null}function d(n){return n<0?Math.ceil(n)||0:Math.floor(n)}function f(n){var t=+n,i=0;return t!==0&&isFinite(t)&&(i=d(t)),i}function pf(n,t,i){for(var e=Math.min(n.length,t.length),o=Math.abs(n.length-t.length),u=0,r=0;r<e;r++)(i&&n[r]!==t[r]||!i&&f(n[r])!==f(t[r]))&&u++;return u+o}function wf(n){t.suppressDeprecationWarnings===!1&&typeof console!="undefined"&&console.warn&&console.warn("Deprecation warning: "+n)}function g(n,i){var r=!0;return yt(function(){var e,u,f,o;if(t.deprecationHandler!=null&&t.deprecationHandler(null,n),r){for(e=[],f=0;f<arguments.length;f++){if(u="",typeof arguments[f]=="object"){u+="\n["+f+"] ";for(o in arguments[0])u+=o+": "+arguments[0][o]+", ";u=u.slice(0,-2)}else u=arguments[f];e.push(u)}wf(n+"\nArguments: "+Array.prototype.slice.call(e).join("")+"\n"+(new Error).stack);r=!1}return i.apply(this,arguments)},i)}function bf(n,i){t.deprecationHandler!=null&&t.deprecationHandler(n,i);ru[n]||(wf(i),ru[n]=!0)}function ot(n){return n instanceof Function||Object.prototype.toString.call(n)==="[object Function]"}function ih(n){var t;for(var i in n)t=n[i],ot(t)?this[i]=t:this["_"+i]=t;this._config=n;this._dayOfMonthOrdinalParseLenient=new RegExp((this._dayOfMonthOrdinalParse.source||this._ordinalParse.source)+"|"+/\d{1,2}/.source)}function kf(n,t){var r=yt({},n);for(var i in t)l(t,i)&&(li(n[i])&&li(t[i])?(r[i]={},yt(r[i],n[i]),yt(r[i],t[i])):t[i]!=null?r[i]=t[i]:delete r[i]);for(i in n)l(n,i)&&!l(t,i)&&li(n[i])&&(r[i]=yt({},r[i]));return r}function uu(n){n!=null&&this.set(n)}function rh(n,t,i){var r=this._calendar[n]||this._calendar.sameElse;return ot(r)?r.call(t,i):r}function uh(n){var t=this._longDateFormat[n],i=this._longDateFormat[n.toUpperCase()];return t||!i?t:(this._longDateFormat[n]=i.replace(/MMMM|MM|DD|dddd/g,function(n){return n.slice(1)}),this._longDateFormat[n])}function fh(){return this._invalidDate}function eh(n){return this._ordinal.replace("%d",n)}function oh(n,t,i,r){var u=this._relativeTime[i];return ot(u)?u(n,t,i,r):u.replace(/%d/i,n)}function sh(n,t){var i=this._relativeTime[n>0?"future":"past"];return ot(i)?i(t):i.replace(/%s/i,t)}function w(n,t){var i=n.toLowerCase();ui[i]=ui[i+"s"]=ui[t]=n}function nt(n){return typeof n=="string"?ui[n]||ui[n.toLowerCase()]:undefined}function fu(n){var r={},t;for(var i in n)l(n,i)&&(t=nt(i),t&&(r[t]=n[i]));return r}function b(n,t){eu[n]=t}function hh(n){var t=[];for(var i in n)t.push({unit:i,priority:eu[i]});return t.sort(function(n,t){return n.priority-t.priority}),t}function ct(n,t,i){var r=""+Math.abs(n),u=t-r.length,f=n>=0;return(f?i?"+":"":"-")+Math.pow(10,Math.max(0,u)).toString().substr(1)+r}function r(n,t,i,r){var u=r;typeof r=="string"&&(u=function(){return this[r]()});n&&(fi[n]=u);t&&(fi[t[0]]=function(){return ct(u.apply(this,arguments),t[1],t[2])});i&&(fi[i]=function(){return this.localeData().ordinal(u.apply(this,arguments),n)})}function ch(n){return n.match(/\[[\s\S]/)?n.replace(/^\[|\]$/g,""):n.replace(/\\/g,"")}function lh(n){for(var t=n.match(fe),i=0,r=t.length;i<r;i++)t[i]=fi[t[i]]?fi[t[i]]:ch(t[i]);return function(i){for(var f="",u=0;u<r;u++)f+=ot(t[u])?t[u].call(i,n):t[u];return f}}function ur(n,t){return n.isValid()?(t=ee(t,n.localeData()),ou[t]=ou[t]||lh(t),ou[t](n)):n.localeData().invalidDate()}function ee(n,t){function r(n){return t.longDateFormat(n)||n}var i=5;for(rr.lastIndex=0;i>=0&&rr.test(n);)n=n.replace(rr,r),rr.lastIndex=0,i-=1;return n}function i(n,t,i){cu[n]=ot(t)?t:function(n){return n&&i?i:t}}function vh(n,t){return l(cu,n)?cu[n](t._strict,t._locale):new RegExp(yh(n))}function yh(n){return gt(n.replace("\\","").replace(/\\(\[)|\\(\])|\[([^\]\[]*)\]|\\(.)/g,function(n,t,i,r,u){return t||i||r||u}))}function gt(n){return n.replace(/[-\/\\^$*+?.()|[\]{}]/g,"\\$&")}function h(n,t){var i,r=t;for(typeof n=="string"&&(n=[n]),dt(t)&&(r=function(n,i){i[t]=f(n)}),i=0;i<n.length;i++)cr[n[i]]=r}function yi(n,t){h(n,function(n,i,r,u){r._w=r._w||{};t(n,r._w,r,u)})}function ph(n,t,i){t!=null&&l(cr,n)&&cr[n](t,i._a,i,n)}function pi(n){return lr(n)?366:365}function lr(n){return n%4==0&&n%100!=0||n%400==0}function kh(){return lr(this.year())}function ei(n,i){return function(r){return r!=null?(le(this,n,r),t.updateOffset(this,i),this):ar(this,n)}}function ar(n,t){return n.isValid()?n._d["get"+(n._isUTC?"UTC":"")+t]():NaN}function le(n,t,i){n.isValid()&&!isNaN(i)&&(t==="FullYear"&&lr(n.year())&&n.month()===1&&n.date()===29?n._d["set"+(n._isUTC?"UTC":"")+t](i,n.month(),vr(i,n.month())):n._d["set"+(n._isUTC?"UTC":"")+t](i))}function dh(n){return(n=nt(n),ot(this[n]))?this[n]():this}function gh(n,t){var r,i;if(typeof n=="object")for(n=fu(n),r=hh(n),i=0;i<r.length;i++)this[r[i].unit](n[r[i].unit]);else if(n=nt(n),ot(this[n]))return this[n](t);return this}function nc(n,t){return(n%t+t)%t}function vr(n,t){if(isNaN(n)||isNaN(t))return NaN;var i=nc(t,12);return n+=(t-i)/12,i===1?lr(n)?29:28:31-i%7%2}function tc(n,t){return n?tt(this._months)?this._months[n.month()]:this._months[(this._months.isFormat||au).test(t)?"format":"standalone"][n.month()]:tt(this._months)?this._months:this._months.standalone}function ic(n,t){return n?tt(this._monthsShort)?this._monthsShort[n.month()]:this._monthsShort[au.test(t)?"format":"standalone"][n.month()]:tt(this._monthsShort)?this._monthsShort:this._monthsShort.standalone}function rc(n,t,i){var u,r,e,f=n.toLocaleLowerCase();if(!this._monthsParse)for(this._monthsParse=[],this._longMonthsParse=[],this._shortMonthsParse=[],u=0;u<12;++u)e=et([2e3,u]),this._shortMonthsParse[u]=this.monthsShort(e,"").toLocaleLowerCase(),this._longMonthsParse[u]=this.months(e,"").toLocaleLowerCase();return i?t==="MMM"?(r=a.call(this._shortMonthsParse,f),r!==-1?r:null):(r=a.call(this._longMonthsParse,f),r!==-1?r:null):t==="MMM"?(r=a.call(this._shortMonthsParse,f),r!==-1)?r:(r=a.call(this._longMonthsParse,f),r!==-1?r:null):(r=a.call(this._longMonthsParse,f),r!==-1)?r:(r=a.call(this._shortMonthsParse,f),r!==-1?r:null)}function uc(n,t,i){var r,u,f;if(this._monthsParseExact)return rc.call(this,n,t,i);for(this._monthsParse||(this._monthsParse=[],this._longMonthsParse=[],this._shortMonthsParse=[]),r=0;r<12;r++)if((u=et([2e3,r]),i&&!this._longMonthsParse[r]&&(this._longMonthsParse[r]=new RegExp("^"+this.months(u,"").replace(".","")+"$","i"),this._shortMonthsParse[r]=new RegExp("^"+this.monthsShort(u,"").replace(".","")+"$","i")),i||this._monthsParse[r]||(f="^"+this.months(u,"")+"|^"+this.monthsShort(u,""),this._monthsParse[r]=new RegExp(f.replace(".",""),"i")),i&&t==="MMMM"&&this._longMonthsParse[r].test(n))||i&&t==="MMM"&&this._shortMonthsParse[r].test(n)||!i&&this._monthsParse[r].test(n))return r}function ve(n,t){var i;if(!n.isValid())return n;if(typeof t=="string")if(/^\d+$/.test(t))t=f(t);else if(t=n.localeData().monthsParse(t),!dt(t))return n;return i=Math.min(n.date(),vr(n.year(),t)),n._d["set"+(n._isUTC?"UTC":"")+"Month"](t,i),n}function ye(n){return n!=null?(ve(this,n),t.updateOffset(this,!0),this):ar(this,"Month")}function fc(){return vr(this.year(),this.month())}function ec(n){return this._monthsParseExact?(l(this,"_monthsRegex")||be.call(this),n?this._monthsShortStrictRegex:this._monthsShortRegex):(l(this,"_monthsShortRegex")||(this._monthsShortRegex=pe),this._monthsShortStrictRegex&&n?this._monthsShortStrictRegex:this._monthsShortRegex)}function oc(n){return this._monthsParseExact?(l(this,"_monthsRegex")||be.call(this),n?this._monthsStrictRegex:this._monthsRegex):(l(this,"_monthsRegex")||(this._monthsRegex=we),this._monthsStrictRegex&&n?this._monthsStrictRegex:this._monthsRegex)}function be(){function f(n,t){return t.length-n.length}for(var i=[],r=[],t=[],u,n=0;n<12;n++)u=et([2e3,n]),i.push(this.monthsShort(u,"")),r.push(this.months(u,"")),t.push(this.months(u,"")),t.push(this.monthsShort(u,""));for(i.sort(f),r.sort(f),t.sort(f),n=0;n<12;n++)i[n]=gt(i[n]),r[n]=gt(r[n]);for(n=0;n<24;n++)t[n]=gt(t[n]);this._monthsRegex=new RegExp("^("+t.join("|")+")","i");this._monthsShortRegex=this._monthsRegex;this._monthsStrictRegex=new RegExp("^("+r.join("|")+")","i");this._monthsShortStrictRegex=new RegExp("^("+i.join("|")+")","i")}function sc(n,t,i,r,u,f,e){var o=new Date(n,t,i,r,u,f,e);return n<100&&n>=0&&isFinite(o.getFullYear())&&o.setFullYear(n),o}function wi(n){var t=new Date(Date.UTC.apply(null,arguments));return n<100&&n>=0&&isFinite(t.getUTCFullYear())&&t.setUTCFullYear(n),t}function yr(n,t,i){var r=7+t-i,u=(7+wi(n,0,r).getUTCDay()-t)%7;return-u+r-1}function ke(n,t,i,r,u){var s=(7+i-r)%7,h=yr(n,r,u),f=1+7*(t-1)+s+h,e,o;return f<=0?(e=n-1,o=pi(e)+f):f>pi(n)?(e=n+1,o=f-pi(n)):(e=n,o=f),{year:e,dayOfYear:o}}function bi(n,t,i){var e=yr(n.year(),t,i),r=Math.floor((n.dayOfYear()-e-1)/7)+1,f,u;return r<1?(u=n.year()-1,f=r+ti(u,t,i)):r>ti(n.year(),t,i)?(f=r-ti(n.year(),t,i),u=n.year()+1):(u=n.year(),f=r),{week:f,year:u}}function ti(n,t,i){var r=yr(n,t,i),u=yr(n+1,t,i);return(pi(n)-r+u)/7}function hc(n){return bi(n,this._week.dow,this._week.doy).week}function cc(){return this._week.dow}function lc(){return this._week.doy}function ac(n){var t=this.localeData().week(this);return n==null?t:this.add((n-t)*7,"d")}function vc(n){var t=bi(this,1,4).week;return n==null?t:this.add((n-t)*7,"d")}function yc(n,t){return typeof n!="string"?n:isNaN(n)?(n=t.weekdaysParse(n),typeof n=="number")?n:null:parseInt(n,10)}function pc(n,t){return typeof n=="string"?t.weekdaysParse(n)%7||7:isNaN(n)?null:n}function wc(n,t){return n?tt(this._weekdays)?this._weekdays[n.day()]:this._weekdays[this._weekdays.isFormat.test(t)?"format":"standalone"][n.day()]:tt(this._weekdays)?this._weekdays:this._weekdays.standalone}function bc(n){return n?this._weekdaysShort[n.day()]:this._weekdaysShort}function kc(n){return n?this._weekdaysMin[n.day()]:this._weekdaysMin}function dc(n,t,i){var f,r,e,u=n.toLocaleLowerCase();if(!this._weekdaysParse)for(this._weekdaysParse=[],this._shortWeekdaysParse=[],this._minWeekdaysParse=[],f=0;f<7;++f)e=et([2e3,1]).day(f),this._minWeekdaysParse[f]=this.weekdaysMin(e,"").toLocaleLowerCase(),this._shortWeekdaysParse[f]=this.weekdaysShort(e,"").toLocaleLowerCase(),this._weekdaysParse[f]=this.weekdays(e,"").toLocaleLowerCase();return i?t==="dddd"?(r=a.call(this._weekdaysParse,u),r!==-1?r:null):t==="ddd"?(r=a.call(this._shortWeekdaysParse,u),r!==-1?r:null):(r=a.call(this._minWeekdaysParse,u),r!==-1?r:null):t==="dddd"?(r=a.call(this._weekdaysParse,u),r!==-1)?r:(r=a.call(this._shortWeekdaysParse,u),r!==-1)?r:(r=a.call(this._minWeekdaysParse,u),r!==-1?r:null):t==="ddd"?(r=a.call(this._shortWeekdaysParse,u),r!==-1)?r:(r=a.call(this._weekdaysParse,u),r!==-1)?r:(r=a.call(this._minWeekdaysParse,u),r!==-1?r:null):(r=a.call(this._minWeekdaysParse,u),r!==-1)?r:(r=a.call(this._weekdaysParse,u),r!==-1)?r:(r=a.call(this._shortWeekdaysParse,u),r!==-1?r:null)}function gc(n,t,i){var r,u,f;if(this._weekdaysParseExact)return dc.call(this,n,t,i);for(this._weekdaysParse||(this._weekdaysParse=[],this._minWeekdaysParse=[],this._shortWeekdaysParse=[],this._fullWeekdaysParse=[]),r=0;r<7;r++)if((u=et([2e3,1]).day(r),i&&!this._fullWeekdaysParse[r]&&(this._fullWeekdaysParse[r]=new RegExp("^"+this.weekdays(u,"").replace(".",".?")+"$","i"),this._shortWeekdaysParse[r]=new RegExp("^"+this.weekdaysShort(u,"").replace(".",".?")+"$","i"),this._minWeekdaysParse[r]=new RegExp("^"+this.weekdaysMin(u,"").replace(".",".?")+"$","i")),this._weekdaysParse[r]||(f="^"+this.weekdays(u,"")+"|^"+this.weekdaysShort(u,"")+"|^"+this.weekdaysMin(u,""),this._weekdaysParse[r]=new RegExp(f.replace(".",""),"i")),i&&t==="dddd"&&this._fullWeekdaysParse[r].test(n))||i&&t==="ddd"&&this._shortWeekdaysParse[r].test(n)||i&&t==="dd"&&this._minWeekdaysParse[r].test(n)||!i&&this._weekdaysParse[r].test(n))return r}function nl(n){if(!this.isValid())return n!=null?this:NaN;var t=this._isUTC?this._d.getUTCDay():this._d.getDay();return n!=null?(n=yc(n,this.localeData()),this.add(n-t,"d")):t}function tl(n){if(!this.isValid())return n!=null?this:NaN;var t=(this.day()+7-this.localeData()._week.dow)%7;return n==null?t:this.add(n-t,"d")}function il(n){if(!this.isValid())return n!=null?this:NaN;if(n!=null){var t=pc(n,this.localeData());return this.day(this.day()%7?t:t-7)}return this.day()||7}function rl(n){return this._weekdaysParseExact?(l(this,"_weekdaysRegex")||pu.call(this),n?this._weekdaysStrictRegex:this._weekdaysRegex):(l(this,"_weekdaysRegex")||(this._weekdaysRegex=to),this._weekdaysStrictRegex&&n?this._weekdaysStrictRegex:this._weekdaysRegex)}function ul(n){return this._weekdaysParseExact?(l(this,"_weekdaysRegex")||pu.call(this),n?this._weekdaysShortStrictRegex:this._weekdaysShortRegex):(l(this,"_weekdaysShortRegex")||(this._weekdaysShortRegex=io),this._weekdaysShortStrictRegex&&n?this._weekdaysShortStrictRegex:this._weekdaysShortRegex)}function fl(n){return this._weekdaysParseExact?(l(this,"_weekdaysRegex")||pu.call(this),n?this._weekdaysMinStrictRegex:this._weekdaysMinRegex):(l(this,"_weekdaysMinRegex")||(this._weekdaysMinRegex=ro),this._weekdaysMinStrictRegex&&n?this._weekdaysMinStrictRegex:this._weekdaysMinRegex)}function pu(){function u(n,t){return t.length-n.length}for(var e=[],i=[],r=[],t=[],f,o,s,h,n=0;n<7;n++)f=et([2e3,1]).day(n),o=this.weekdaysMin(f,""),s=this.weekdaysShort(f,""),h=this.weekdays(f,""),e.push(o),i.push(s),r.push(h),t.push(o),t.push(s),t.push(h);for(e.sort(u),i.sort(u),r.sort(u),t.sort(u),n=0;n<7;n++)i[n]=gt(i[n]),r[n]=gt(r[n]),t[n]=gt(t[n]);this._weekdaysRegex=new RegExp("^("+t.join("|")+")","i");this._weekdaysShortRegex=this._weekdaysRegex;this._weekdaysMinRegex=this._weekdaysRegex;this._weekdaysStrictRegex=new RegExp("^("+r.join("|")+")","i");this._weekdaysShortStrictRegex=new RegExp("^("+i.join("|")+")","i");this._weekdaysMinStrictRegex=new RegExp("^("+e.join("|")+")","i")}function wu(){return this.hours()%12||12}function el(){return this.hours()||24}function uo(n,t){r(n,0,0,function(){return this.localeData().meridiem(this.hours(),this.minutes(),t)})}function fo(n,t){return t._meridiemParse}function ol(n){return(n+"").toLowerCase().charAt(0)==="p"}function sl(n,t,i){return n>11?i?"pm":"PM":i?"am":"AM"}function so(n){return n?n.toLowerCase().replace("_","-"):n}function cl(n){for(var r=0,i,t,f,u;r<n.length;){for(u=so(n[r]).split("-"),i=u.length,t=so(n[r+1]),t=t?t.split("-"):null;i>0;){if(f=pr(u.slice(0,i).join("-")),f)return f;if(t&&t.length>=i&&pf(u,t,!0)>=i-1)break;i--}r++}return di}function pr(n){var t=null,i;if(!y[n]&&typeof module!="undefined"&&module&&module.exports)try{t=di._abbr;i=require;i("./locale/"+n);oi(t)}catch(r){}return y[n]}function oi(n,t){var i;return n&&(i=p(t)?wt(n):bu(n,t),i?di=i:typeof console!="undefined"&&console.warn&&console.warn("Locale "+n+" not found. Did you forget to load it?")),di._abbr}function bu(n,t){if(t!==null){var r,i=oo;if(t.abbr=n,y[n]!=null)bf("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."),i=y[n]._config;else if(t.parentLocale!=null)if(y[t.parentLocale]!=null)i=y[t.parentLocale]._config;else if(r=pr(t.parentLocale),r!=null)i=r._config;else return ki[t.parentLocale]||(ki[t.parentLocale]=[]),ki[t.parentLocale].push({name:n,config:t}),null;return y[n]=new uu(kf(i,t)),ki[n]&&ki[n].forEach(function(n){bu(n.name,n.config)}),oi(n),y[n]}return delete y[n],null}function ll(n,t){if(t!=null){var i,r,u=oo;r=pr(n);r!=null&&(u=r._config);t=kf(u,t);i=new uu(t);i.parentLocale=y[n];y[n]=i;oi(n)}else y[n]!=null&&(y[n].parentLocale!=null?y[n]=y[n].parentLocale:y[n]!=null&&delete y[n]);return y[n]}function wt(n){var t;if(n&&n._locale&&n._locale._abbr&&(n=n._locale._abbr),!n)return di;if(!tt(n)){if(t=pr(n),t)return t;n=[n]}return cl(n)}function al(){return df(y)}function ku(n){var i,t=n._a;return t&&u(n).overflow===-2&&(i=t[lt]<0||t[lt]>11?lt:t[st]<1||t[st]>vr(t[it],t[lt])?st:t[v]<0||t[v]>24||t[v]===24&&(t[rt]!==0||t[at]!==0||t[ni]!==0)?v:t[rt]<0||t[rt]>59?rt:t[at]<0||t[at]>59?at:t[ni]<0||t[ni]>999?ni:-1,u(n)._overflowDayOfYear&&(i<it||i>st)&&(i=st),u(n)._overflowWeeks&&i===-1&&(i=wh),u(n)._overflowWeekday&&i===-1&&(i=bh),u(n).overflow=i),n}function si(n,t,i){return n!=null?n:t!=null?t:i}function vl(n){var i=new Date(t.now());return n._useUTC?[i.getUTCFullYear(),i.getUTCMonth(),i.getUTCDate(),]:[i.getFullYear(),i.getMonth(),i.getDate(),]}function du(n){var t,i,r=[],f,o,e;if(!n._d){for(f=vl(n),n._w&&n._a[st]==null&&n._a[lt]==null&&yl(n),n._dayOfYear!=null&&(e=si(n._a[it],f[it]),(n._dayOfYear>pi(e)||n._dayOfYear===0)&&(u(n)._overflowDayOfYear=!0),i=wi(e,0,n._dayOfYear),n._a[lt]=i.getUTCMonth(),n._a[st]=i.getUTCDate()),t=0;t<3&&n._a[t]==null;++t)n._a[t]=r[t]=f[t];for(;t<7;t++)n._a[t]=r[t]=n._a[t]==null?t===2?1:0:n._a[t];n._a[v]===24&&n._a[rt]===0&&n._a[at]===0&&n._a[ni]===0&&(n._nextDay=!0,n._a[v]=0);n._d=(n._useUTC?wi:sc).apply(null,r);o=n._useUTC?n._d.getUTCDay():n._d.getDay();n._tzm!=null&&n._d.setUTCMinutes(n._d.getUTCMinutes()-n._tzm);n._nextDay&&(n._a[v]=24);n._w&&typeof n._w.d!="undefined"&&n._w.d!==o&&(u(n).weekdayMismatch=!0)}}function yl(n){var t,o,f,i,r,e,h,s,l;t=n._w;t.GG!=null||t.W!=null||t.E!=null?(r=1,e=4,o=si(t.GG,n._a[it],bi(c(),1,4).year),f=si(t.W,1),i=si(t.E,1),(i<1||i>7)&&(s=!0)):(r=n._locale._week.dow,e=n._locale._week.doy,l=bi(c(),r,e),o=si(t.gg,n._a[it],l.year),f=si(t.w,l.week),t.d!=null?(i=t.d,(i<0||i>6)&&(s=!0)):t.e!=null?(i=t.e+r,(t.e<0||t.e>6)&&(s=!0)):i=r);f<1||f>ti(o,r,e)?u(n)._overflowWeeks=!0:s!=null?u(n)._overflowWeekday=!0:(h=ke(o,f,i,r,e),n._a[it]=h.year,n._dayOfYear=h.dayOfYear)}function ho(n){var t,r,o=n._i,i=pl.exec(o)||wl.exec(o),s,e,f,h;if(i){for(u(n).iso=!0,t=0,r=wr.length;t<r;t++)if(wr[t][1].exec(i[1])){e=wr[t][0];s=wr[t][2]!==!1;break}if(e==null){n._isValid=!1;return}if(i[3]){for(t=0,r=gu.length;t<r;t++)if(gu[t][1].exec(i[3])){f=(i[2]||" ")+gu[t][0];break}if(f==null){n._isValid=!1;return}}if(!s&&f!=null){n._isValid=!1;return}if(i[4])if(bl.exec(i[4]))h="Z";else{n._isValid=!1;return}n._f=e+(f||"")+(h||"");nf(n)}else n._isValid=!1}function dl(n,t,i,r,u,f){var e=[gl(n),vu.indexOf(t),parseInt(i,10),parseInt(r,10),parseInt(u,10),];return f&&e.push(parseInt(f,10)),e}function gl(n){var t=parseInt(n,10);return t<=49?2e3+t:t<=999?1900+t:t}function na(n){return n.replace(/\([^)]*\)|[\n\t]/g," ").replace(/(\s\s+)/g," ").trim()}function ta(n,t,i){if(n){var r=yu.indexOf(n),f=new Date(t[0],t[1],t[2]).getDay();if(r!==f)return u(i).weekdayMismatch=!0,i._isValid=!1,!1}return!0}function ia(n,t,i){if(n)return lo[n];if(t)return 0;var r=parseInt(i,10),u=r%100,f=(r-u)/100;return f*60+u}function ao(n){var t=co.exec(na(n._i)),i;if(t){if(i=dl(t[4],t[3],t[2],t[5],t[6],t[7]),!ta(t[1],i,n))return;n._a=i;n._tzm=ia(t[8],t[9],t[10]);n._d=wi.apply(null,n._a);n._d.setUTCMinutes(n._d.getUTCMinutes()-n._tzm);u(n).rfc2822=!0}else n._isValid=!1}function ra(n){var i=kl.exec(n._i);if(i!==null){n._d=new Date(+i[1]);return}if(ho(n),n._isValid===!1)delete n._isValid;else return;if(ao(n),n._isValid===!1)delete n._isValid;else return;t.createFromInputFallback(n)}function nf(n){if(n._f===t.ISO_8601){ho(n);return}if(n._f===t.RFC_2822){ao(n);return}n._a=[];u(n).empty=!0;for(var i=""+n._i,r,f,s,c=i.length,h=0,o=ee(n._f,n._locale).match(fe)||[],e=0;e<o.length;e++)f=o[e],r=(i.match(vh(f,n))||[])[0],r&&(s=i.substr(0,i.indexOf(r)),s.length>0&&u(n).unusedInput.push(s),i=i.slice(i.indexOf(r)+r.length),h+=r.length),fi[f]?(r?u(n).empty=!1:u(n).unusedTokens.push(f),ph(f,r,n)):n._strict&&!r&&u(n).unusedTokens.push(f);u(n).charsLeftOver=c-h;i.length>0&&u(n).unusedInput.push(i);n._a[v]<=12&&u(n).bigHour===!0&&n._a[v]>0&&(u(n).bigHour=undefined);u(n).parsedDateParts=n._a.slice(0);u(n).meridiem=n._meridiem;n._a[v]=ua(n._locale,n._a[v],n._meridiem);du(n);ku(n)}function ua(n,t,i){var r;return i==null?t:n.meridiemHour!=null?n.meridiemHour(t,i):n.isPM!=null?(r=n.isPM(i),r&&t<12&&(t+=12),r||t!==12||(t=0),t):t}function fa(n){var t,e,f,r,i;if(n._f.length===0){u(n).invalidFormat=!0;n._d=new Date(NaN);return}for(r=0;r<n._f.length;r++)(i=0,t=iu({},n),n._useUTC!=null&&(t._useUTC=n._useUTC),t._f=n._f[r],nf(t),tu(t))&&(i+=u(t).charsLeftOver,i+=u(t).unusedTokens.length*10,u(t).score=i,(f==null||i<f)&&(f=i,e=t));yt(n,e||t)}function ea(n){if(!n._d){var t=fu(n._i);n._a=vf([t.year,t.month,t.day||t.date,t.hour,t.minute,t.second,t.millisecond,],function(n){return n&&parseInt(n,10)});du(n)}}function oa(n){var t=new ai(ku(vo(n)));return t._nextDay&&(t.add(1,"d"),t._nextDay=undefined),t}function vo(n){var t=n._i,i=n._f;return(n._locale=n._locale||wt(n._l),t===null||i===undefined&&t==="")?nr({nullInput:!0}):(typeof t=="string"&&(n._i=t=n._locale.preparse(t)),pt(t))?new ai(ku(t)):(gi(t)?n._d=t:tt(i)?fa(n):i?nf(n):sa(n),tu(n)||(n._d=null),n)}function sa(n){var i=n._i;p(i)?n._d=new Date(t.now()):gi(i)?n._d=new Date(i.valueOf()):typeof i=="string"?ra(n):tt(i)?(n._a=vf(i.slice(0),function(n){return parseInt(n,10)}),du(n)):li(i)?ea(n):dt(i)?n._d=new Date(i):t.createFromInputFallback(n)}function yo(n,t,i,r,u){var f={};return(i===!0||i===!1)&&(r=i,i=undefined),(li(n)&&nh(n)||tt(n)&&n.length===0)&&(n=undefined),f._isAMomentObject=!0,f._useUTC=f._isUTC=u,f._l=i,f._i=n,f._f=t,f._strict=r,oa(f)}function c(n,t,i,r){return yo(n,t,i,r,!1)}function bo(n,t){var r,i;if(t.length===1&&tt(t[0])&&(t=t[0]),!t.length)return c();for(r=t[0],i=1;i<t.length;++i)(!t[i].isValid()||t[i][n](r))&&(r=t[i]);return r}function ha(){var n=[].slice.call(arguments,0);return bo("isBefore",n)}function ca(){var n=[].slice.call(arguments,0);return bo("isAfter",n)}function la(n){var i,r,t;for(i in n)if(!(a.call(hi,i)!==-1&&(n[i]==null||!isNaN(n[i]))))return!1;for(r=!1,t=0;t<hi.length;++t)if(n[hi[t]]){if(r)return!1;parseFloat(n[hi[t]])!==f(n[hi[t]])&&(r=!0)}return!0}function aa(){return this._isValid}function va(){return ut(NaN)}function br(n){var t=fu(n),i=t.year||0,r=t.quarter||0,u=t.month||0,f=t.week||0,e=t.day||0,o=t.hour||0,s=t.minute||0,h=t.second||0,c=t.millisecond||0;this._isValid=la(t);this._milliseconds=+c+h*1e3+s*6e4+o*36e5;this._days=+e+f*7;this._months=+u+r*3+i*12;this._data={};this._locale=wt();this._bubble()}function tf(n){return n instanceof br}function rf(n){return n<0?Math.round(-1*n)*-1:Math.round(n)}function go(n,t){r(n,0,0,function(){var n=this.utcOffset(),i="+";return n<0&&(n=-n,i="-"),i+ct(~~(n/60),2)+t+ct(~~n%60,2)})}function uf(n,t){var i=(t||"").match(n);if(i===null)return null;var e=i[i.length-1]||[],r=(e+"").match(ns)||["-",0,0],u=+(r[1]*60)+f(r[2]);return u===0?0:r[0]==="+"?u:-u}function ff(n,i){var r,u;return i._isUTC?(r=i.clone(),u=(pt(n)||gi(n)?n.valueOf():c(n).valueOf())-r.valueOf(),r._d.setTime(r._d.valueOf()+u),t.updateOffset(r,!1),r):c(n).local()}function ef(n){return-Math.round(n._d.getTimezoneOffset()/15)*15}function ya(n,i,r){var u=this._offset||0,f;if(!this.isValid())return n!=null?this:NaN;if(n!=null){if(typeof n=="string"){if(n=uf(hr,n),n===null)return this}else Math.abs(n)<16&&!r&&(n=n*60);return!this._isUTC&&i&&(f=ef(this)),this._offset=n,this._isUTC=!0,f!=null&&this.add(f,"m"),u!==n&&(!i||this._changeInProgress?es(this,ut(n-u,"m"),1,!1):this._changeInProgress||(this._changeInProgress=!0,t.updateOffset(this,!0),this._changeInProgress=null)),this}return this._isUTC?u:ef(this)}function pa(n,t){return n!=null?(typeof n!="string"&&(n=-n),this.utcOffset(n,t),this):-this.utcOffset()}function wa(n){return this.utcOffset(0,n)}function ba(n){return this._isUTC&&(this.utcOffset(0,n),this._isUTC=!1,n&&this.subtract(ef(this),"m")),this}function ka(){if(this._tzm!=null)this.utcOffset(this._tzm,!1,!0);else if(typeof this._i=="string"){var n=uf(ah,this._i);n!=null?this.utcOffset(n):this.utcOffset(0,!0)}return this}function da(n){return this.isValid()?(n=n?c(n).utcOffset():0,(this.utcOffset()-n)%60==0):!1}function ga(){return this.utcOffset()>this.clone().month(0).utcOffset()||this.utcOffset()>this.clone().month(5).utcOffset()}function nv(){var n,t;return p(this._isDSTShifted)?(n={},iu(n,this),n=vo(n),n._a?(t=n._isUTC?et(n._a):c(n._a),this._isDSTShifted=this.isValid()&&pf(n._a,t.toArray())>0):this._isDSTShifted=!1,this._isDSTShifted):this._isDSTShifted}function tv(){return this.isValid()?!this._isUTC:!1}function iv(){return this.isValid()?this._isUTC:!1}function ts(){return this.isValid()?this._isUTC&&this._offset===0:!1}function ut(n,t){var i=n,r=null,u,e,o;return tf(n)?i={ms:n._milliseconds,d:n._days,M:n._months}:dt(n)?(i={},t?i[t]=n:i.milliseconds=n):(r=is.exec(n))?(u=r[1]==="-"?-1:1,i={y:0,d:f(r[st])*u,h:f(r[v])*u,m:f(r[rt])*u,s:f(r[at])*u,ms:f(rf(r[ni]*1e3))*u}):(r=rs.exec(n))?(u=r[1]==="-"?-1:r[1]==="+"?1:1,i={y:ii(r[2],u),M:ii(r[3],u),w:ii(r[4],u),d:ii(r[5],u),h:ii(r[6],u),m:ii(r[7],u),s:ii(r[8],u)}):i==null?i={}:typeof i=="object"&&("from"in i||"to"in i)&&(o=rv(c(i.from),c(i.to)),i={},i.ms=o.milliseconds,i.M=o.months),e=new br(i),tf(n)&&l(n,"_locale")&&(e._locale=n._locale),e}function ii(n,t){var i=n&&parseFloat(n.replace(",","."));return(isNaN(i)?0:i)*t}function us(n,t){var i={milliseconds:0,months:0};return i.months=t.month()-n.month()+(t.year()-n.year())*12,n.clone().add(i.months,"M").isAfter(t)&&--i.months,i.milliseconds=+t-+n.clone().add(i.months,"M"),i}function rv(n,t){var i;return(n.isValid()&&t.isValid())?(t=ff(t,n),n.isBefore(t)?i=us(n,t):(i=us(t,n),i.milliseconds=-i.milliseconds,i.months=-i.months),i):{milliseconds:0,months:0}}function fs(n,t){return function(i,r){var u,f;return r===null||isNaN(+r)||(bf(t,"moment()."+t+"(period, number) is deprecated. Please use moment()."+t+"(number, period). See http://momentjs.com/guides/#/warnings/add-inverted-param/ for more info."),f=i,i=r,r=f),i=typeof i=="string"?+i:i,u=ut(i,r),es(this,u,n),this}}function es(n,i,r,u){var o=i._milliseconds,f=rf(i._days),e=rf(i._months);n.isValid()&&(u=u==null?!0:u,e&&ve(n,ar(n,"Month")+e*r),f&&le(n,"Date",ar(n,"Date")+f*r),o&&n._d.setTime(n._d.valueOf()+o*r),u&&t.updateOffset(n,f||e))}function uv(n,t){var i=n.diff(t,"days",!0);return i<-6?"sameElse":i<-1?"lastWeek":i<0?"lastDay":i<1?"sameDay":i<2?"nextDay":i<7?"nextWeek":"sameElse"}function fv(n,i){var u=n||c(),f=ff(u,this).startOf("day"),r=t.calendarFormat(this,f)||"sameElse",e=i&&(ot(i[r])?i[r].call(this,u):i[r]);return this.format(e||this.localeData().calendar(r,this,c(u)))}function ev(){return new ai(this)}function ov(n,t){var i=pt(n)?n:c(n);return(this.isValid()&&i.isValid())?(t=nt(p(t)?"millisecond":t),t==="millisecond"?this.valueOf()>i.valueOf():i.valueOf()<this.clone().startOf(t).valueOf()):!1}function sv(n,t){var i=pt(n)?n:c(n);return(this.isValid()&&i.isValid())?(t=nt(p(t)?"millisecond":t),t==="millisecond"?this.valueOf()<i.valueOf():this.clone().endOf(t).valueOf()<i.valueOf()):!1}function hv(n,t,i,r){return r=r||"()",(r[0]==="("?this.isAfter(n,i):!this.isBefore(n,i))&&(r[1]===")"?this.isBefore(t,i):!this.isAfter(t,i))}function cv(n,t){var i=pt(n)?n:c(n),r;return(this.isValid()&&i.isValid())?(t=nt(t||"millisecond"),t==="millisecond"?this.valueOf()===i.valueOf():(r=i.valueOf(),this.clone().startOf(t).valueOf()<=r&&r<=this.clone().endOf(t).valueOf())):!1}function lv(n,t){return this.isSame(n,t)||this.isAfter(n,t)}function av(n,t){return this.isSame(n,t)||this.isBefore(n,t)}function vv(n,t,i){var r,f,u;if(!this.isValid())return NaN;if(r=ff(n,this),!r.isValid())return NaN;f=(r.utcOffset()-this.utcOffset())*6e4;t=nt(t);switch(t){case"year":u=of(this,r)/12;break;case"month":u=of(this,r);break;case"quarter":u=of(this,r)/3;break;case"second":u=(this-r)/1e3;break;case"minute":u=(this-r)/6e4;break;case"hour":u=(this-r)/36e5;break;case"day":u=(this-r-f)/864e5;break;case"week":u=(this-r-f)/6048e5;break;default:u=this-r}return i?u:d(u)}function of(n,t){var r=(t.year()-n.year())*12+(t.month()-n.month()),i=n.clone().add(r,"months"),u,f;return t-i<0?(u=n.clone().add(r-1,"months"),f=(t-i)/(i-u)):(u=n.clone().add(r+1,"months"),f=(t-i)/(u-i)),-(r+f)||0}function yv(){return this.clone().locale("en").format("ddd MMM DD YYYY HH:mm:ss [GMT]ZZ")}function pv(n){if(!this.isValid())return null;var i=n!==!0,t=i?this.clone().utc():this;return t.year()<0||t.year()>9999?ur(t,i?"YYYYYY-MM-DD[T]HH:mm:ss.SSS[Z]":"YYYYYY-MM-DD[T]HH:mm:ss.SSSZ"):ot(Date.prototype.toISOString)?i?this.toDate().toISOString():new Date(this.valueOf()+this.utcOffset()*6e4).toISOString().replace("Z",ur(t,"Z")):ur(t,i?"YYYY-MM-DD[T]HH:mm:ss.SSS[Z]":"YYYY-MM-DD[T]HH:mm:ss.SSSZ")}function wv(){var n,t;if(!this.isValid())return"moment.invalid(/* "+this._i+" */)";n="moment";t="";this.isLocal()||(n=this.utcOffset()===0?"moment.utc":"moment.parseZone",t="Z");var i="["+n+'("]',r=0<=this.year()&&this.year()<=9999?"YYYY":"YYYYYY",u=t+'[")]';return this.format(i+r+"-MM-DD[T]HH:mm:ss.SSS"+u)}function bv(n){n||(n=this.isUtc()?t.defaultFormatUtc:t.defaultFormat);var i=ur(this,n);return this.localeData().postformat(i)}function kv(n,t){return this.isValid()&&(pt(n)&&n.isValid()||c(n).isValid())?ut({to:this,from:n}).locale(this.locale()).humanize(!t):this.localeData().invalidDate()}function dv(n){return this.from(c(),n)}function gv(n,t){return this.isValid()&&(pt(n)&&n.isValid()||c(n).isValid())?ut({from:this,to:n}).locale(this.locale()).humanize(!t):this.localeData().invalidDate()}function ny(n){return this.to(c(),n)}function hs(n){var t;return n===undefined?this._locale._abbr:(t=wt(n),t!=null&&(this._locale=t),this)}function cs(){return this._locale}function ty(n){n=nt(n);switch(n){case"year":this.month(0);case"quarter":case"month":this.date(1);case"week":case"isoWeek":case"day":case"date":this.hours(0);case"hour":this.minutes(0);case"minute":this.seconds(0);case"second":this.milliseconds(0)}return n==="week"&&this.weekday(0),n==="isoWeek"&&this.isoWeekday(1),n==="quarter"&&this.month(Math.floor(this.month()/3)*3),this}function iy(n){return(n=nt(n),n===undefined||n==="millisecond")?this:(n==="date"&&(n="day"),this.startOf(n).add(1,n==="isoWeek"?"week":n).subtract(1,"ms"))}function ry(){return this._d.valueOf()-(this._offset||0)*6e4}function uy(){return Math.floor(this.valueOf()/1e3)}function fy(){return new Date(this.valueOf())}function ey(){var n=this;return[n.year(),n.month(),n.date(),n.hour(),n.minute(),n.second(),n.millisecond(),]}function oy(){var n=this;return{years:n.year(),months:n.month(),date:n.date(),hours:n.hours(),minutes:n.minutes(),seconds:n.seconds(),milliseconds:n.milliseconds()}}function sy(){return this.isValid()?this.toISOString():null}function hy(){return tu(this)}function cy(){return yt({},u(this))}function ly(){return u(this).overflow}function ay(){return{input:this._i,format:this._f,locale:this._locale,isUTC:this._isUTC,strict:this._strict}}function kr(n,t){r(0,[n,n.length],0,t)}function vy(n){return ls.call(this,n,this.week(),this.weekday(),this.localeData()._week.dow,this.localeData()._week.doy)}function yy(n){return ls.call(this,n,this.isoWeek(),this.isoWeekday(),1,4)}function py(){return ti(this.year(),1,4)}function wy(){var n=this.localeData()._week;return ti(this.year(),n.dow,n.doy)}function ls(n,t,i,r,u){var f;return n==null?bi(this,r,u).year:(f=ti(n,r,u),t>f&&(t=f),by.call(this,n,t,i,r,u))}function by(n,t,i,r,u){var e=ke(n,t,i,r,u),f=wi(e.year,0,e.dayOfYear);return this.year(f.getUTCFullYear()),this.month(f.getUTCMonth()),this.date(f.getUTCDate()),this}function ky(n){return n==null?Math.ceil((this.month()+1)/3):this.month((n-1)*3+this.month()%3)}function dy(n){var t=Math.round((this.clone().startOf("day")-this.clone().startOf("year"))/864e5)+1;return n==null?t:this.add(n-t,"d")}function gy(n,t){t[ni]=f(("0."+n)*1e3)}function np(){return this._isUTC?"UTC":""}function tp(){return this._isUTC?"Coordinated Universal Time":""}function ip(n){return c(n*1e3)}function rp(){return c.apply(null,arguments).parseZone()}function ps(n){return n}function dr(n,t,i,r){var u=wt(),f=et().set(r,t);return u[i](f,n)}function ws(n,t,i){if(dt(n)&&(t=n,n=undefined),n=n||"",t!=null)return dr(n,t,i,"month");for(var u=[],r=0;r<12;r++)u[r]=dr(n,r,i,"month");return u}function cf(n,t,i,r){var o,f,u,e;if(typeof n=="boolean"?(dt(t)&&(i=t,t=undefined),t=t||""):(t=n,i=t,n=!1,dt(t)&&(i=t,t=undefined),t=t||""),o=wt(),f=n?o._week.dow:0,i!=null)return dr(t,(i+f)%7,r,"day");for(e=[],u=0;u<7;u++)e[u]=dr(t,(u+f)%7,r,"day");return e}function up(n,t){return ws(n,t,"months")}function fp(n,t){return ws(n,t,"monthsShort")}function ep(n,t,i){return cf(n,t,i,"weekdays")}function op(n,t,i){return cf(n,t,i,"weekdaysShort")}function sp(n,t,i){return cf(n,t,i,"weekdaysMin")}function hp(){var n=this._data;return this._milliseconds=ht(this._milliseconds),this._days=ht(this._days),this._months=ht(this._months),n.milliseconds=ht(n.milliseconds),n.seconds=ht(n.seconds),n.minutes=ht(n.minutes),n.hours=ht(n.hours),n.months=ht(n.months),n.years=ht(n.years),this}function bs(n,t,i,r){var u=ut(t,i);return n._milliseconds+=r*u._milliseconds,n._days+=r*u._days,n._months+=r*u._months,n._bubble()}function cp(n,t){return bs(this,n,t,1)}function lp(n,t){return bs(this,n,t,-1)}function ks(n){return n<0?Math.floor(n):Math.ceil(n)}function ap(){var r=this._milliseconds,n=this._days,t=this._months,i=this._data,u,f,e,s,o;return r>=0&&n>=0&&t>=0||r<=0&&n<=0&&t<=0||(r+=ks(lf(t)+n)*864e5,n=0,t=0),i.milliseconds=r%1e3,u=d(r/1e3),i.seconds=u%60,f=d(u/60),i.minutes=f%60,e=d(f/60),i.hours=e%24,n+=d(e/24),o=d(ds(n)),t+=o,n-=ks(lf(o)),s=d(t/12),t%=12,i.days=n,i.months=t,i.years=s,this}function ds(n){return n*4800/146097}function lf(n){return n*146097/4800}function vp(n){if(!this.isValid())return NaN;var t,r,i=this._milliseconds;if(n=nt(n),n==="month"||n==="year")return t=this._days+i/864e5,r=this._months+ds(t),n==="month"?r:r/12;t=this._days+Math.round(lf(this._months));switch(n){case"week":return t/7+i/6048e5;case"day":return t+i/864e5;case"hour":return t*24+i/36e5;case"minute":return t*1440+i/6e4;case"second":return t*86400+i/1e3;case"millisecond":return Math.floor(t*864e5)+i;default:throw new Error("Unknown unit "+n);}}function yp(){return this.isValid()?this._milliseconds+this._days*864e5+this._months%12*2592e6+f(this._months/12)*31536e6:NaN}function kt(n){return function(){return this.as(n)}}function iw(){return ut(this)}function rw(n){return n=nt(n),this.isValid()?this[n+"s"]():NaN}function ri(n){return function(){return this.isValid()?this._data[n]:NaN}}function lw(){return d(this.days()/7)}function aw(n,t,i,r,u){return u.relativeTime(t||1,!!i,n,r)}function vw(n,t,i){var r=ut(n).abs(),u=vt(r.as("s")),e=vt(r.as("m")),o=vt(r.as("h")),s=vt(r.as("d")),h=vt(r.as("M")),c=vt(r.as("y")),f=u<=ft.ss&&["s",u]||u<ft.s&&["ss",u]||e<=1&&["m"]||e<ft.m&&["mm",e]||o<=1&&["h"]||o<ft.h&&["hh",o]||s<=1&&["d"]||s<ft.d&&["dd",s]||h<=1&&["M"]||h<ft.M&&["MM",h]||c<=1&&["y"]||["yy",c];return f[2]=t,f[3]=+n>0,f[4]=i,aw.apply(null,f)}function yw(n){return n===undefined?vt:typeof n=="function"?(vt=n,!0):!1}function pw(n,t){return ft[n]===undefined?!1:t===undefined?ft[n]:(ft[n]=t,n==="s"&&(ft.ss=t-1),!0)}function ww(n){if(!this.isValid())return this.localeData().invalidDate();var t=this.localeData(),i=vw(this,!n,t);return n&&(i=t.pastFuture(+this,i)),t.postformat(i)}function ci(n){return(n>0)-(n<0)||+n}function nu(){if(!this.isValid())return this.localeData().invalidDate();var t=gr(this._milliseconds)/1e3,y=gr(this._days),r=gr(this._months),i,s,h;i=d(t/60);s=d(i/60);t%=60;i%=60;h=d(r/12);r%=12;var c=h,l=r,a=y,u=s,f=i,e=t?t.toFixed(3).replace(/\.?0+$/,""):"",n=this.asSeconds();if(!n)return"P0D";var p=n<0?"-":"",v=ci(this._months)!==ci(n)?"-":"",w=ci(this._days)!==ci(n)?"-":"",o=ci(this._milliseconds)!==ci(n)?"-":"";return p+"P"+(c?v+c+"Y":"")+(l?v+l+"M":"")+(a?w+a+"D":"")+(u||f||e?"T":"")+(u?o+u+"H":"")+(f?o+f+"M":"")+(e?o+e+"S":"")}var af,yf,tr,ir,ru,df,gf,ne,te,ie,re,ue,ui,eu,cr,lu,a,au,ae,vu,pe,we,de,ge,yu,no,to,io,ro,eo,co,lo,po,wo,ko,hi,ns,is,rs,os,ss,sf,hf,as,vs,bt,ys,n,o,ht,vt,ft,gr,e;yf=Array.prototype.some?Array.prototype.some:function(n){for(var i=Object(this),r=i.length>>>0,t=0;t<r;t++)if(t in i&&n.call(this,i[t],t,i))return!0;return!1};tr=t.momentProperties=[];ir=!1;ru={};t.suppressDeprecationWarnings=!1;t.deprecationHandler=null;df=Object.keys?Object.keys:function(n){var t,i=[];for(t in n)l(n,t)&&i.push(t);return i};gf={sameDay:"[Today at] LT",nextDay:"[Tomorrow at] LT",nextWeek:"dddd [at] LT",lastDay:"[Yesterday at] LT",lastWeek:"[Last] dddd [at] LT",sameElse:"L"};ne={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"};te="Invalid date";ie="%d";re=/\d{1,2}/;ue={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"};ui={};eu={};var fe=/(\[[^\[]*\])|(\\)?([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,rr=/(\[[^\[]*\])|(\\)?(LTS|LT|LL?L?L?|l{1,4})/g,ou={},fi={};var oe=/\d/,k=/\d\d/,se=/\d{3}/,su=/\d{4}/,fr=/[+-]?\d{6}/,s=/\d\d?/,he=/\d\d\d\d?/,ce=/\d\d\d\d\d\d?/,er=/\d{1,3}/,hu=/\d{1,4}/,or=/[+-]?\d{1,6}/,sr=/[+-]?\d+/,ah=/Z|[+-]\d\d:?\d\d/gi,hr=/Z|[+-]\d\d(?::?\d\d)?/gi,vi=/[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,cu={};cr={};var it=0,lt=1,st=2,v=3,rt=4,at=5,ni=6,wh=7,bh=8;r("Y",0,0,function(){var n=this.year();return n<=9999?""+n:"+"+n});r(0,["YY",2],0,function(){return this.year()%100});r(0,["YYYY",4],0,"year");r(0,["YYYYY",5],0,"year");r(0,["YYYYYY",6,!0],0,"year");w("year","y");b("year",1);i("Y",sr);i("YY",s,k);i("YYYY",hu,su);i("YYYYY",or,fr);i("YYYYYY",or,fr);h(["YYYYY","YYYYYY"],it);h("YYYY",function(n,i){i[it]=n.length===2?t.parseTwoDigitYear(n):f(n)});h("YY",function(n,i){i[it]=t.parseTwoDigitYear(n)});h("Y",function(n,t){t[it]=parseInt(n,10)});t.parseTwoDigitYear=function(n){return f(n)+(f(n)>68?1900:2e3)};lu=ei("FullYear",!0);a=Array.prototype.indexOf?Array.prototype.indexOf:function(n){for(var t=0;t<this.length;++t)if(this[t]===n)return t;return-1};r("M",["MM",2],"Mo",function(){return this.month()+1});r("MMM",0,0,function(n){return this.localeData().monthsShort(this,n)});r("MMMM",0,0,function(n){return this.localeData().months(this,n)});w("month","M");b("month",8);i("M",s);i("MM",s,k);i("MMM",function(n,t){return t.monthsShortRegex(n)});i("MMMM",function(n,t){return t.monthsRegex(n)});h(["M","MM"],function(n,t){t[lt]=f(n)-1});h(["MMM","MMMM"],function(n,t,i,r){var f=i._locale.monthsParse(n,r,i._strict);f!=null?t[lt]=f:u(i).invalidMonth=n});au=/D[oD]?(\[[^\[\]]*\]|\s)+MMMM?/;ae="January_February_March_April_May_June_July_August_September_October_November_December".split("_");vu="Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec".split("_");pe=vi;we=vi;r("w",["ww",2],"wo","week");r("W",["WW",2],"Wo","isoWeek");w("week","w");w("isoWeek","W");b("week",5);b("isoWeek",5);i("w",s);i("ww",s,k);i("W",s);i("WW",s,k);yi(["w","ww","W","WW"],function(n,t,i,r){t[r.substr(0,1)]=f(n)});de={dow:0,doy:6};r("d",0,"do","day");r("dd",0,0,function(n){return this.localeData().weekdaysMin(this,n)});r("ddd",0,0,function(n){return this.localeData().weekdaysShort(this,n)});r("dddd",0,0,function(n){return this.localeData().weekdays(this,n)});r("e",0,0,"weekday");r("E",0,0,"isoWeekday");w("day","d");w("weekday","e");w("isoWeekday","E");b("day",11);b("weekday",11);b("isoWeekday",11);i("d",s);i("e",s);i("E",s);i("dd",function(n,t){return t.weekdaysMinRegex(n)});i("ddd",function(n,t){return t.weekdaysShortRegex(n)});i("dddd",function(n,t){return t.weekdaysRegex(n)});yi(["dd","ddd","dddd"],function(n,t,i,r){var f=i._locale.weekdaysParse(n,r,i._strict);f!=null?t.d=f:u(i).invalidWeekday=n});yi(["d","e","E"],function(n,t,i,r){t[r]=f(n)});ge="Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_");yu="Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_");no="Su_Mo_Tu_We_Th_Fr_Sa".split("_");to=vi;io=vi;ro=vi;r("H",["HH",2],0,"hour");r("h",["hh",2],0,wu);r("k",["kk",2],0,el);r("hmm",0,0,function(){return""+wu.apply(this)+ct(this.minutes(),2)});r("hmmss",0,0,function(){return""+wu.apply(this)+ct(this.minutes(),2)+ct(this.seconds(),2)});r("Hmm",0,0,function(){return""+this.hours()+ct(this.minutes(),2)});r("Hmmss",0,0,function(){return""+this.hours()+ct(this.minutes(),2)+ct(this.seconds(),2)});uo("a",!0);uo("A",!1);w("hour","h");b("hour",13);i("a",fo);i("A",fo);i("H",s);i("h",s);i("k",s);i("HH",s,k);i("hh",s,k);i("kk",s,k);i("hmm",he);i("hmmss",ce);i("Hmm",he);i("Hmmss",ce);h(["H","HH"],v);h(["k","kk"],function(n,t){var i=f(n);t[v]=i===24?0:i});h(["a","A"],function(n,t,i){i._isPm=i._locale.isPM(n);i._meridiem=n});h(["h","hh"],function(n,t,i){t[v]=f(n);u(i).bigHour=!0});h("hmm",function(n,t,i){var r=n.length-2;t[v]=f(n.substr(0,r));t[rt]=f(n.substr(r));u(i).bigHour=!0});h("hmmss",function(n,t,i){var r=n.length-4,e=n.length-2;t[v]=f(n.substr(0,r));t[rt]=f(n.substr(r,2));t[at]=f(n.substr(e));u(i).bigHour=!0});h("Hmm",function(n,t){var i=n.length-2;t[v]=f(n.substr(0,i));t[rt]=f(n.substr(i))});h("Hmmss",function(n,t){var i=n.length-4,r=n.length-2;t[v]=f(n.substr(0,i));t[rt]=f(n.substr(i,2));t[at]=f(n.substr(r))});eo=/[ap]\.?m?\.?/i;var hl=ei("Hours",!0),oo={calendar:gf,longDateFormat:ne,invalidDate:te,ordinal:ie,dayOfMonthOrdinalParse:re,relativeTime:ue,months:ae,monthsShort:vu,week:de,weekdays:ge,weekdaysMin:no,weekdaysShort:yu,meridiemParse:eo},y={},ki={},di;var pl=/^\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)?)?$/,wl=/^\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)?)?$/,bl=/Z|[+-]\d\d(?::?\d\d)?/,wr=[["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}/],],gu=[["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/],],kl=/^\/?Date\((\-?\d+)/i;for(co=/^(?:(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}))$/,lo={UT:0,GMT:0,EDT:-240,EST:-300,CDT:-300,CST:-360,MDT:-360,MST:-420,PDT:-420,PST:-480},t.createFromInputFallback=g("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(n){n._d=new Date(n._i+(n._useUTC?" UTC":""))}),t.ISO_8601=function(){},t.RFC_2822=function(){},po=g("moment().min is deprecated, use moment.max instead. http://momentjs.com/guides/#/warnings/min-max/",function(){var n=c.apply(null,arguments);return this.isValid()&&n.isValid()?n<this?this:n:nr()}),wo=g("moment().max is deprecated, use moment.min instead. http://momentjs.com/guides/#/warnings/min-max/",function(){var n=c.apply(null,arguments);return this.isValid()&&n.isValid()?n>this?this:n:nr()}),ko=function(){return Date.now?Date.now():+new Date},hi=["year","quarter","month","week","day","hour","minute","second","millisecond",],go("Z",":"),go("ZZ",""),i("Z",hr),i("ZZ",hr),h(["Z","ZZ"],function(n,t,i){i._useUTC=!0;i._tzm=uf(hr,n)}),ns=/([\+\-]|\d\d)/gi,t.updateOffset=function(){},is=/^(\-|\+)?(?:(\d*)[. ])?(\d+)\:(\d+)(?:\:(\d+)(\.\d*)?)?$/,rs=/^(-|\+)?P(?:([-+]?[0-9,.]*)Y)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)W)?(?:([-+]?[0-9,.]*)D)?(?:T(?:([-+]?[0-9,.]*)H)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)S)?)?$/,ut.fn=br.prototype,ut.invalid=va,os=fs(1,"add"),ss=fs(-1,"subtract"),t.defaultFormat="YYYY-MM-DDTHH:mm:ssZ",t.defaultFormatUtc="YYYY-MM-DDTHH:mm:ss[Z]",sf=g("moment().lang() is deprecated. Instead, use moment().localeData() to get the language configuration. Use moment().locale() to change languages.",function(n){return n===undefined?this.localeData():this.locale(n)}),r(0,["gg",2],0,function(){return this.weekYear()%100}),r(0,["GG",2],0,function(){return this.isoWeekYear()%100}),kr("gggg","weekYear"),kr("ggggg","weekYear"),kr("GGGG","isoWeekYear"),kr("GGGGG","isoWeekYear"),w("weekYear","gg"),w("isoWeekYear","GG"),b("weekYear",1),b("isoWeekYear",1),i("G",sr),i("g",sr),i("GG",s,k),i("gg",s,k),i("GGGG",hu,su),i("gggg",hu,su),i("GGGGG",or,fr),i("ggggg",or,fr),yi(["gggg","ggggg","GGGG","GGGGG"],function(n,t,i,r){t[r.substr(0,2)]=f(n)}),yi(["gg","GG"],function(n,i,r,u){i[u]=t.parseTwoDigitYear(n)}),r("Q",0,"Qo","quarter"),w("quarter","Q"),b("quarter",7),i("Q",oe),h("Q",function(n,t){t[lt]=(f(n)-1)*3}),r("D",["DD",2],"Do","date"),w("date","D"),b("date",9),i("D",s),i("DD",s,k),i("Do",function(n,t){return n?t._dayOfMonthOrdinalParse||t._ordinalParse:t._dayOfMonthOrdinalParseLenient}),h(["D","DD"],st),h("Do",function(n,t){t[st]=f(n.match(s)[0])}),hf=ei("Date",!0),r("DDD",["DDDD",3],"DDDo","dayOfYear"),w("dayOfYear","DDD"),b("dayOfYear",4),i("DDD",er),i("DDDD",se),h(["DDD","DDDD"],function(n,t,i){i._dayOfYear=f(n)}),r("m",["mm",2],0,"minute"),w("minute","m"),b("minute",14),i("m",s),i("mm",s,k),h(["m","mm"],rt),as=ei("Minutes",!1),r("s",["ss",2],0,"second"),w("second","s"),b("second",15),i("s",s),i("ss",s,k),h(["s","ss"],at),vs=ei("Seconds",!1),r("S",0,0,function(){return~~(this.millisecond()/100)}),r(0,["SS",2],0,function(){return~~(this.millisecond()/10)}),r(0,["SSS",3],0,"millisecond"),r(0,["SSSS",4],0,function(){return this.millisecond()*10}),r(0,["SSSSS",5],0,function(){return this.millisecond()*100}),r(0,["SSSSSS",6],0,function(){return this.millisecond()*1e3}),r(0,["SSSSSSS",7],0,function(){return this.millisecond()*1e4}),r(0,["SSSSSSSS",8],0,function(){return this.millisecond()*1e5}),r(0,["SSSSSSSSS",9],0,function(){return this.millisecond()*1e6}),w("millisecond","ms"),b("millisecond",16),i("S",er,oe),i("SS",er,k),i("SSS",er,se),bt="SSSS";bt.length<=9;bt+="S")i(bt,/\d+/);for(bt="S";bt.length<=9;bt+="S")h(bt,gy);ys=ei("Milliseconds",!1);r("z",0,0,"zoneAbbr");r("zz",0,0,"zoneName");n=ai.prototype;n.add=os;n.calendar=fv;n.clone=ev;n.diff=vv;n.endOf=iy;n.format=bv;n.from=kv;n.fromNow=dv;n.to=gv;n.toNow=ny;n.get=dh;n.invalidAt=ly;n.isAfter=ov;n.isBefore=sv;n.isBetween=hv;n.isSame=cv;n.isSameOrAfter=lv;n.isSameOrBefore=av;n.isValid=hy;n.lang=sf;n.locale=hs;n.localeData=cs;n.max=wo;n.min=po;n.parsingFlags=cy;n.set=gh;n.startOf=ty;n.subtract=ss;n.toArray=ey;n.toObject=oy;n.toDate=fy;n.toISOString=pv;n.inspect=wv;n.toJSON=sy;n.toString=yv;n.unix=uy;n.valueOf=ry;n.creationData=ay;n.year=lu;n.isLeapYear=kh;n.weekYear=vy;n.isoWeekYear=yy;n.quarter=n.quarters=ky;n.month=ye;n.daysInMonth=fc;n.week=n.weeks=ac;n.isoWeek=n.isoWeeks=vc;n.weeksInYear=wy;n.isoWeeksInYear=py;n.date=hf;n.day=n.days=nl;n.weekday=tl;n.isoWeekday=il;n.dayOfYear=dy;n.hour=n.hours=hl;n.minute=n.minutes=as;n.second=n.seconds=vs;n.millisecond=n.milliseconds=ys;n.utcOffset=ya;n.utc=wa;n.local=ba;n.parseZone=ka;n.hasAlignedHourOffset=da;n.isDST=ga;n.isLocal=tv;n.isUtcOffset=iv;n.isUtc=ts;n.isUTC=ts;n.zoneAbbr=np;n.zoneName=tp;n.dates=g("dates accessor is deprecated. Use date instead.",hf);n.months=g("months accessor is deprecated. Use month instead",ye);n.years=g("years accessor is deprecated. Use year instead",lu);n.zone=g("moment().zone is deprecated, use moment().utcOffset instead. http://momentjs.com/guides/#/warnings/zone/",pa);n.isDSTShifted=g("isDSTShifted is deprecated. See http://momentjs.com/guides/#/warnings/dst-shifted/ for more information",nv);o=uu.prototype;o.calendar=rh;o.longDateFormat=uh;o.invalidDate=fh;o.ordinal=eh;o.preparse=ps;o.postformat=ps;o.relativeTime=oh;o.pastFuture=sh;o.set=ih;o.months=tc;o.monthsShort=ic;o.monthsParse=uc;o.monthsRegex=oc;o.monthsShortRegex=ec;o.week=hc;o.firstDayOfYear=lc;o.firstDayOfWeek=cc;o.weekdays=wc;o.weekdaysMin=kc;o.weekdaysShort=bc;o.weekdaysParse=gc;o.weekdaysRegex=rl;o.weekdaysShortRegex=ul;o.weekdaysMinRegex=fl;o.isPM=ol;o.meridiem=sl;oi("en",{dayOfMonthOrdinalParse:/\d{1,2}(th|st|nd|rd)/,ordinal:function(n){var t=n%10,i=f(n%100/10)===1?"th":t===1?"st":t===2?"nd":t===3?"rd":"th";return n+i}});t.lang=g("moment.lang is deprecated. Use moment.locale instead.",oi);t.langData=g("moment.langData is deprecated. Use moment.localeData instead.",wt);ht=Math.abs;var pp=kt("ms"),wp=kt("s"),bp=kt("m"),kp=kt("h"),dp=kt("d"),gp=kt("w"),nw=kt("M"),tw=kt("y");var uw=ri("milliseconds"),fw=ri("seconds"),ew=ri("minutes"),ow=ri("hours"),sw=ri("days"),hw=ri("months"),cw=ri("years");return vt=Math.round,ft={ss:44,s:45,m:45,h:22,d:26,M:11},gr=Math.abs,e=br.prototype,e.isValid=aa,e.abs=hp,e.add=cp,e.subtract=lp,e.as=vp,e.asMilliseconds=pp,e.asSeconds=wp,e.asMinutes=bp,e.asHours=kp,e.asDays=dp,e.asWeeks=gp,e.asMonths=nw,e.asYears=tw,e.valueOf=yp,e._bubble=ap,e.clone=iw,e.get=rw,e.milliseconds=uw,e.seconds=fw,e.minutes=ew,e.hours=ow,e.days=sw,e.weeks=lw,e.months=hw,e.years=cw,e.humanize=ww,e.toISOString=nu,e.toString=nu,e.toJSON=nu,e.locale=hs,e.localeData=cs,e.toIsoString=g("toIsoString() is deprecated. Please use toISOString() instead (notice the capitals)",nu),e.lang=sf,r("X",0,0,"unix"),r("x",0,0,"valueOf"),i("x",sr),i("X",/[+-]?\d+(\.\d{1,3})?/),h("X",function(n,t,i){i._d=new Date(parseFloat(n,10)*1e3)}),h("x",function(n,t,i){i._d=new Date(f(n))}),t.version="2.21.0",gs(c),t.fn=n,t.min=ha,t.max=ca,t.now=ko,t.utc=et,t.unix=ip,t.months=up,t.isDate=gi,t.locale=oi,t.invalid=nr,t.duration=ut,t.isMoment=pt,t.weekdays=ep,t.parseZone=rp,t.localeData=wt,t.isDuration=tf,t.monthsShort=fp,t.weekdaysMin=sp,t.defineLocale=bu,t.updateLocale=ll,t.locales=al,t.weekdaysShort=op,t.normalizeUnits=nt,t.relativeTimeRounding=yw,t.relativeTimeThreshold=pw,t.calendarFormat=uv,t.prototype=n,t.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:"YYYY-[W]WW",MONTH:"YYYY-MM"},t}),typeof jQuery=="undefined")throw new Error("Tempus Dominus Bootstrap4's requires jQuery. jQuery must be included before Tempus Dominus Bootstrap4's JavaScript.");if(+function(n){var t=n.fn.jquery.split(" ")[0].split(".");if(t[0]<2&&t[1]<9||t[0]===1&&t[1]===9&&t[2]<1||t[0]>=4)throw new Error("Tempus Dominus Bootstrap4's requires at least jQuery v3.0.0 but less than v4.0.0");}(jQuery),typeof moment=="undefined")throw new Error("Tempus Dominus Bootstrap4's requires moment.js. Moment.js must be included before Tempus Dominus Bootstrap4's JavaScript.");if(version=moment.version.split("."),version[0]<=2&&version[1]<17||version[0]>=3)throw new Error("Tempus Dominus Bootstrap4's requires at least moment.js v2.17.0 but less than v3.0.0");+function(){function u(n,t){if(!n)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t&&(_typeof2(t)==="object"||typeof t=="function")?t:n}function f(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function, not "+_typeof2(t));n.prototype=Object.create(t&&t.prototype,{constructor:{value:n,enumerable:!1,writable:!0,configurable:!0}});t&&(Object.setPrototypeOf?Object.setPrototypeOf(n,t):n.__proto__=t)}function t(n,t){if(!(n instanceof t))throw new TypeError("Cannot call a class as a function");}var i=typeof Symbol=="function"&&_typeof2(Symbol.iterator)==="symbol"?function(n){return _typeof2(n)}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":_typeof2(n)},r=function(){function n(n,t){for(var i,r=0;r<t.length;r++)i=t[r],i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(n,i.key,i)}return function(t,i,r){return i&&n(t.prototype,i),r&&n(t,r),t}}(),n=function(n,i){var e="datetimepicker",o=""+e,u="."+o,h=".data-api",v={DATA_TOGGLE:'[data-toggle="'+o+'"]'},y={INPUT:e+"-input"},p={CHANGE:"change"+u,BLUR:"blur"+u,KEYUP:"keyup"+u,KEYDOWN:"keydown"+u,FOCUS:"focus"+u,CLICK_DATA_API:"click"+u+h,UPDATE:"update"+u,ERROR:"error"+u,HIDE:"hide"+u,SHOW:"show"+u},c=[{CLASS_NAME:"days",NAV_FUNCTION:"M",NAV_STEP:1},{CLASS_NAME:"months",NAV_FUNCTION:"y",NAV_STEP:1},{CLASS_NAME:"years",NAV_FUNCTION:"y",NAV_STEP:10},{CLASS_NAME:"decades",NAV_FUNCTION:"y",NAV_STEP:100}],l={up:38,38:"up",down:40,40:"down",left:37,37:"left",right:39,39:"right",tab:9,9:"tab",escape:27,27:"escape",enter:13,13:"enter",pageUp:33,33:"pageUp",pageDown:34,34:"pageDown",shift:16,16:"shift",control:17,17:"control",space:32,32:"space",t:84,84:"t","delete":46,46:"delete",backspace:8,8:"backspace"},w=["times","days","months","years","decades"],f={},a={},s={timeZone:"",format:!1,dayViewHeaderFormat:"MMMM YYYY",extraFormats:!1,stepping:1,minDate:!1,maxDate:!1,useCurrent:!0,collapse:!0,locale:i.locale(),defaultDate:!1,disabledDates:!1,enabledDates:!1,icons:{time:"fa fa-clock-o",date:"fa fa-calendar",up:"fa fa-arrow-up",down:"fa fa-arrow-down",previous:"fa fa-chevron-left",next:"fa fa-chevron-right",today:"fa fa-calendar-check-o",clear:"fa fa-delete",close:"fa fa-times"},tooltips:{today:"Go to today",clear:"Clear selection",close:"Close the picker",selectMonth:"Select Month",prevMonth:"Previous Month",nextMonth:"Next Month",selectYear:"Select Year",prevYear:"Previous Year",nextYear:"Next Year",selectDecade:"Select Decade",prevDecade:"Previous Decade",nextDecade:"Next Decade",prevCentury:"Previous Century",nextCentury:"Next Century",pickHour:"Pick Hour",incrementHour:"Increment Hour",decrementHour:"Decrement Hour",pickMinute:"Pick Minute",incrementMinute:"Increment Minute",decrementMinute:"Decrement Minute",pickSecond:"Pick Second",incrementSecond:"Increment Second",decrementSecond:"Decrement Second",togglePeriod:"Toggle Period",selectTime:"Select Time",selectDate:"Select Date"},useStrict:!1,sideBySide:!1,daysOfWeekDisabled:!1,calendarWeeks:!1,viewMode:"days",toolbarPlacement:"default",buttons:{showToday:!1,showClear:!1,showClose:!1},widgetPositioning:{horizontal:"auto",vertical:"auto"},widgetParent:null,ignoreReadonly:!1,keepOpen:!1,focusOnShow:!0,inline:!1,keepInvalid:!1,keyBinds:{up:function(){if(!this.widget)return!1;var n=this._dates[0]||this.getMoment();return this.widget.find(".datepicker").is(":visible")?this.widget.find(".datepicker-years").is(":visible")?this.date(n.clone().add(1,"y")):this.widget.find(".datepicker-months").is(":visible")?this.date(n.clone().add(1,"M")):this.date(n.clone().subtract(7,"d")):this.date(n.clone().add(this.stepping(),"m")),!0},down:function(){if(!this.widget)return this.show(),!1;var n=this._dates[0]||this.getMoment();return this.widget.find(".datepicker").is(":visible")?this.widget.find(".datepicker-years").is(":visible")?this.date(n.clone().subtract(1,"y")):this.widget.find(".datepicker-months").is(":visible")?this.date(n.clone().subtract(1,"M")):this.date(n.clone().add(7,"d")):this.date(n.clone().subtract(this.stepping(),"m")),!0},"control up":function(){if(!this.widget)return!1;var n=this._dates[0]||this.getMoment();return this.widget.find(".datepicker").is(":visible")?this.date(n.clone().subtract(10,"y")):this.date(n.clone().add(1,"h")),!0},"control down":function(){if(!this.widget)return!1;var n=this._dates[0]||this.getMoment();return this.widget.find(".datepicker").is(":visible")?this.date(n.clone().add(10,"y")):this.date(n.clone().subtract(1,"h")),!0},"shift up":function(){if(!this.widget)return!1;var n=this._dates[0]||this.getMoment();return this.widget.find(".datepicker").is(":visible")?this.date(n.clone().subtract(10,"y")):this.date(n.clone().add(1,"h")),!0},"shift down":function(){if(!this.widget)return!1;var n=this._dates[0]||this.getMoment();return this.widget.find(".datepicker").is(":visible")?this.date(n.clone().add(10,"y")):this.date(n.clone().subtract(1,"h")),!0},left:function(){if(!this.widget)return!1;var n=this._dates[0]||this.getMoment();return this.widget.find(".datepicker").is(":visible")&&(this.widget.find(".datepicker-years").is(":visible")?this.date(n.clone().subtract(1,"y")):this.widget.find(".datepicker-months").is(":visible")?this.date(n.clone().subtract(1,"M")):this.date(n.clone().subtract(1,"d"))),!0},right:function(){if(!this.widget)return!1;var n=this._dates[0]||this.getMoment();return this.widget.find(".datepicker").is(":visible")&&(this.widget.find(".datepicker-years").is(":visible")?this.date(n.clone().add(1,"y")):this.widget.find(".datepicker-months").is(":visible")?this.date(n.clone().add(1,"M")):this.date(n.clone().add(1,"d"))),!0},"control left":function(){if(!this.widget)return!1;var n=this._dates[0]||this.getMoment();return this.widget.find(".datepicker").is(":visible")?this.widget.find(".datepicker-years").is(":visible")?this.date(n.clone().subtract(10,"y")):this.date(n.clone().subtract(1,"y")):this.date(n.clone().add(1,"h")),!0},"control right":function(){if(!this.widget)return!1;var n=this._dates[0]||this.getMoment();return this.widget.find(".datepicker").is(":visible")?this.widget.find(".datepicker-years").is(":visible")?this.date(n.clone().add(10,"y")):this.date(n.clone().add(1,"y")):this.date(n.clone().subtract(1,"h")),!0},"shift left":function(){if(!this.widget)return!1;var n=this._dates[0]||this.getMoment();return this.widget.find(".datepicker").is(":visible")?this.widget.find(".datepicker-years").is(":visible")?this.date(n.clone().subtract(10,"y")):this.date(n.clone().subtract(1,"y")):this.date(n.clone().add(1,"h")),!0},"shift right":function(){if(!this.widget)return!1;var n=this._dates[0]||this.getMoment();return this.widget.find(".datepicker").is(":visible")?this.widget.find(".datepicker-years").is(":visible")?this.date(n.clone().add(10,"y")):this.date(n.clone().add(1,"y")):this.date(n.clone().subtract(1,"h")),!0},pageUp:function(){if(!this.widget)return!1;var n=this._dates[0]||this.getMoment();return this.widget.find(".datepicker").is(":visible")&&this.date(n.clone().subtract(1,"M")),!0},pageDown:function(){if(!this.widget)return!1;var n=this._dates[0]||this.getMoment();return this.widget.find(".datepicker").is(":visible")&&this.date(n.clone().add(1,"M")),!0},enter:function(){return this.widget?(this.widget.find(".datepicker").is(":visible")&&(this.widget.find(".datepicker-years").is(":visible")?(this.widget.find(".datepicker:visible .datepicker-years").hide(),this.widget.find(".datepicker:visible .datepicker-months").show()):this.widget.find(".datepicker-months").is(":visible")?(this.widget.find(".datepicker:visible .datepicker-months").hide(),this.widget.find(".datepicker:visible .datepicker-days").show()):this.hide()),!0):!1},space:function(){return this.widget?(this.widget.find(".datepicker").is(":visible")&&(this.widget.find(".datepicker-years").is(":visible")?(this.widget.find(".datepicker:visible .datepicker-years").hide(),this.widget.find(".datepicker:visible .datepicker-months").show()):this.widget.find(".datepicker-months").is(":visible")?(this.widget.find(".datepicker:visible .datepicker-months").hide(),this.widget.find(".datepicker:visible .datepicker-days").show()):this.hide()),!0):!1},escape:function(){return this.widget?(this.hide(),!0):!1},"control space":function(){return this.widget?(this.widget.find(".timepicker").is(":visible")&&this.widget.find('.btn[data-action="togglePeriod"]').click(),!0):!1},t:function(){return this.widget?(this.date(this.getMoment()),!0):!1},"delete":function(){return this.widget?(this.clear(),!0):!1},backspace:function(){return this.widget?(this.clear(),!0):!1}},debug:!1,allowInputToggle:!1,disabledTimeIntervals:!1,disabledHours:!1,enabledHours:!1,viewDate:!1,allowMultidate:!1,multidateSeparator:","};return function(){function b(n,i){t(this,b);this._options=this._getOptions(i);this._element=n;this._dates=[];this._datesFormatted=[];this._viewDate=null;this.unset=!0;this.component=!1;this.widget=!1;this.use24Hours=null;this.actualFormat=null;this.parseFormats=null;this.currentViewMode=null;this.MinViewModeNumber=0;this._int()}return b.prototype._int=function(){var t=this._element.data("target-input");this._element.is("input")?this.input=this._element:t!==undefined&&(this.input=t==="nearest"?this._element.find("input"):n(t));this._dates=[];this._dates[0]=this.getMoment();this._viewDate=this.getMoment().clone();n.extend(!0,this._options,this._dataToOptions());this.options(this._options);this._initFormatting();this.input!==undefined&&this.input.is("input")&&this.input.val().trim().length!==0?this._setValue(this._parseInputDate(this.input.val().trim()),0):this._options.defaultDate&&this.input!==undefined&&this.input.attr("placeholder")===undefined&&this._setValue(this._options.defaultDate,0);this._options.inline&&this.show()},b.prototype._update=function(){this.widget&&(this._fillDate(),this._fillTime())},b.prototype._setValue=function(n,t){var r=this.unset?null:this._dates[t],i="",u;if(!n){this._options.allowMultidate&&this._dates.length!==1?(i=this._element.data("date")+",",i=i.replace(r.format(this.actualFormat)+",","").replace(",,","").replace(/,\s*$/,""),this._dates.splice(t,1),this._datesFormatted.splice(t,1)):(this.unset=!0,this._dates=[],this._dates[0]=this.getMoment(),this._viewDate=this.getMoment().locale(this._options.locale).clone(),this._datesFormatted=[]);this.input!==undefined&&(this.input.val(i),this.input.trigger("input"));this._element.data("date",i);this._notifyEvent({type:b.Event.CHANGE,date:!1,oldDate:r});this._update();return}if(n=n.clone().locale(this._options.locale),this._hasTimeZone()&&n.tz(this._options.timeZone),this._options.stepping!==1&&n.minutes(Math.round(n.minutes()/this._options.stepping)*this._options.stepping).seconds(0),this._isValid(n)){if(this._dates[t]=n,this._datesFormatted[t]=n.format("YYYY-MM-DD"),this._viewDate=n.clone(),this._options.allowMultidate&&this._dates.length>1){for(u=0;u<this._dates.length;u++)i+=""+this._dates[u].format(this.actualFormat)+this._options.multidateSeparator;i=i.replace(/,\s*$/,"")}else i=this._dates[t].format(this.actualFormat);this.input!==undefined&&(this.input.val(i),this.input.trigger("input"));this._element.data("date",i);this.unset=!1;this._update();this._notifyEvent({type:b.Event.CHANGE,date:this._dates[t].clone(),oldDate:r})}else this._options.keepInvalid?this._notifyEvent({type:b.Event.CHANGE,date:n,oldDate:r}):this.input!==undefined&&(this.input.val(""+(this.unset?"":this._dates[t].format(this.actualFormat))),this.input.trigger("input")),this._notifyEvent({type:b.Event.ERROR,date:n,oldDate:r})},b.prototype._change=function(t){var i=n(t.target).val().trim(),r=i?this._parseInputDate(i):null;return this._setValue(r),t.stopImmediatePropagation(),!1},b.prototype._getOptions=function(t){return n.extend(!0,{},s,t)},b.prototype._hasTimeZone=function(){return i.tz!==undefined&&this._options.timeZone!==undefined&&this._options.timeZone!==null&&this._options.timeZone!==""},b.prototype._isEnabled=function(n){if(typeof n!="string"||n.length>1)throw new TypeError("isEnabled expects a single character string parameter");switch(n){case"y":return this.actualFormat.indexOf("Y")!==-1;case"M":return this.actualFormat.indexOf("M")!==-1;case"d":return this.actualFormat.toLowerCase().indexOf("d")!==-1;case"h":case"H":return this.actualFormat.toLowerCase().indexOf("h")!==-1;case"m":return this.actualFormat.indexOf("m")!==-1;case"s":return this.actualFormat.indexOf("s")!==-1;case"a":case"A":return this.actualFormat.toLowerCase().indexOf("a")!==-1;default:return!1}},b.prototype._hasTime=function(){return this._isEnabled("h")||this._isEnabled("m")||this._isEnabled("s")},b.prototype._hasDate=function(){return this._isEnabled("y")||this._isEnabled("M")||this._isEnabled("d")},b.prototype._dataToOptions=function(){var t=this._element.data(),i={};return t.dateOptions&&t.dateOptions instanceof Object&&(i=n.extend(!0,i,t.dateOptions)),n.each(this._options,function(n){var r="date"+n.charAt(0).toUpperCase()+n.slice(1);t[r]!==undefined?i[n]=t[r]:delete i[n]}),i},b.prototype._notifyEvent=function(n){(n.type!==b.Event.CHANGE||(!n.date||!n.date.isSame(n.oldDate))&&(n.date||n.oldDate))&&this._element.trigger(n)},b.prototype._viewUpdate=function(n){n==="y"&&(n="YYYY");this._notifyEvent({type:b.Event.UPDATE,change:n,viewDate:this._viewDate.clone()})},b.prototype._showMode=function(n){this.widget&&(n&&(this.currentViewMode=Math.max(this.MinViewModeNumber,Math.min(3,this.currentViewMode+n))),this.widget.find(".datepicker > div").hide().filter(".datepicker-"+c[this.currentViewMode].CLASS_NAME).show())},b.prototype._isInDisabledDates=function(n){return this._options.disabledDates[n.format("YYYY-MM-DD")]===!0},b.prototype._isInEnabledDates=function(n){return this._options.enabledDates[n.format("YYYY-MM-DD")]===!0},b.prototype._isInDisabledHours=function(n){return this._options.disabledHours[n.format("H")]===!0},b.prototype._isInEnabledHours=function(n){return this._options.enabledHours[n.format("H")]===!0},b.prototype._isValid=function(t,i){if(!t.isValid()||this._options.disabledDates&&i==="d"&&this._isInDisabledDates(t)||this._options.enabledDates&&i==="d"&&!this._isInEnabledDates(t)||this._options.minDate&&t.isBefore(this._options.minDate,i)||this._options.maxDate&&t.isAfter(this._options.maxDate,i)||this._options.daysOfWeekDisabled&&i==="d"&&this._options.daysOfWeekDisabled.indexOf(t.day())!==-1||this._options.disabledHours&&(i==="h"||i==="m"||i==="s")&&this._isInDisabledHours(t)||this._options.enabledHours&&(i==="h"||i==="m"||i==="s")&&!this._isInEnabledHours(t))return!1;if(this._options.disabledTimeIntervals&&(i==="h"||i==="m"||i==="s")){var r=!1;if(n.each(this._options.disabledTimeIntervals,function(){if(t.isBetween(this[0],this[1]))return r=!0,!1}),r)return!1}return!0},b.prototype._parseInputDate=function(n){return this._options.parseInputDate===undefined?i.isMoment(n)||(n=this.getMoment(n)):n=this._options.parseInputDate(n),n},b.prototype._keydown=function(n){var u=null,t=void 0,r=void 0,i=void 0,e=void 0,s=[],h={},o=n.which,c="p";f[o]=c;for(t in f)f.hasOwnProperty(t)&&f[t]===c&&(s.push(t),parseInt(t,10)!==o&&(h[t]=!0));for(t in this._options.keyBinds)if(this._options.keyBinds.hasOwnProperty(t)&&typeof this._options.keyBinds[t]=="function"&&(i=t.split(" "),i.length===s.length&&l[o]===i[i.length-1])){for(e=!0,r=i.length-2;r>=0;r--)if(!(l[i[r]]in h)){e=!1;break}if(e){u=this._options.keyBinds[t];break}}u&&u.call(this)&&(n.stopPropagation(),n.preventDefault(),this._keyup(n))},b.prototype._keyup=function(n){f[n.which]="r";a[n.which]&&(a[n.which]=!1,n.stopPropagation(),n.preventDefault())},b.prototype._indexGivenDates=function(t){var i={},r=this;return n.each(t,function(){var n=r._parseInputDate(this);n.isValid()&&(i[n.format("YYYY-MM-DD")]=!0)}),Object.keys(i).length?i:!1},b.prototype._indexGivenHours=function(t){var i={};return n.each(t,function(){i[this]=!0}),Object.keys(i).length?i:!1},b.prototype._initFormatting=function(){var n=this._options.format||"L LT",t=this;this.actualFormat=n.replace(/(\[[^\[]*])|(\\)?(LTS|LT|LL?L?L?|l{1,4})/g,function(n){return t._dates[0].localeData().longDateFormat(n)||n});this.parseFormats=this._options.extraFormats?this._options.extraFormats.slice():[];this.parseFormats.indexOf(n)<0&&this.parseFormats.indexOf(this.actualFormat)<0&&this.parseFormats.push(this.actualFormat);this.use24Hours=this.actualFormat.toLowerCase().indexOf("a")<1&&this.actualFormat.replace(/\[.*?]/g,"").indexOf("h")<1;this._isEnabled("y")&&(this.MinViewModeNumber=2);this._isEnabled("M")&&(this.MinViewModeNumber=1);this._isEnabled("d")&&(this.MinViewModeNumber=0);this.currentViewMode=Math.max(this.MinViewModeNumber,this.currentViewMode);this.unset||this._setValue(this._dates[0],0)},b.prototype._getLastPickedDate=function(){return this._dates[this._getLastPickedDateIndex()]},b.prototype._getLastPickedDateIndex=function(){return this._dates.length-1},b.prototype.getMoment=function(n){var t=void 0;return t=n===undefined||n===null?i():this._hasTimeZone()?i.tz(n,this.parseFormats,this._options.locale,this._options.useStrict,this._options.timeZone):i(n,this.parseFormats,this._options.locale,this._options.useStrict),this._hasTimeZone()&&t.tz(this._options.timeZone),t},b.prototype.toggle=function(){return this.widget?this.hide():this.show()},b.prototype.ignoreReadonly=function(n){if(arguments.length===0)return this._options.ignoreReadonly;if(typeof n!="boolean")throw new TypeError("ignoreReadonly () expects a boolean parameter");this._options.ignoreReadonly=n},b.prototype.options=function(t){if(arguments.length===0)return n.extend(!0,{},this._options);if(!(t instanceof Object))throw new TypeError("options() this.options parameter should be an object");n.extend(!0,this._options,t);var i=this;n.each(this._options,function(n,t){i[n]!==undefined&&i[n](t)})},b.prototype.date=function(n,t){if(t=t||0,arguments.length===0)return this.unset?null:this._options.allowMultidate?this._dates.join(this._options.multidateSeparator):this._dates[t].clone();if(n!==null&&typeof n!="string"&&!i.isMoment(n)&&!(n instanceof Date))throw new TypeError("date() parameter must be one of [null, string, moment or Date]");this._setValue(n===null?null:this._parseInputDate(n),t)},b.prototype.format=function(n){if(arguments.length===0)return this._options.format;if(typeof n!="string"&&(typeof n!="boolean"||n!==!1))throw new TypeError("format() expects a string or boolean:false parameter "+n);this._options.format=n;this.actualFormat&&this._initFormatting()},b.prototype.timeZone=function(n){if(arguments.length===0)return this._options.timeZone;if(typeof n!="string")throw new TypeError("newZone() expects a string parameter");this._options.timeZone=n},b.prototype.dayViewHeaderFormat=function(n){if(arguments.length===0)return this._options.dayViewHeaderFormat;if(typeof n!="string")throw new TypeError("dayViewHeaderFormat() expects a string parameter");this._options.dayViewHeaderFormat=n},b.prototype.extraFormats=function(n){if(arguments.length===0)return this._options.extraFormats;if(n!==!1&&!(n instanceof Array))throw new TypeError("extraFormats() expects an array or false parameter");this._options.extraFormats=n;this.parseFormats&&this._initFormatting()},b.prototype.disabledDates=function(t){if(arguments.length===0)return this._options.disabledDates?n.extend({},this._options.disabledDates):this._options.disabledDates;if(!t)return this._options.disabledDates=!1,this._update(),!0;if(!(t instanceof Array))throw new TypeError("disabledDates() expects an array parameter");this._options.disabledDates=this._indexGivenDates(t);this._options.enabledDates=!1;this._update()},b.prototype.enabledDates=function(t){if(arguments.length===0)return this._options.enabledDates?n.extend({},this._options.enabledDates):this._options.enabledDates;if(!t)return this._options.enabledDates=!1,this._update(),!0;if(!(t instanceof Array))throw new TypeError("enabledDates() expects an array parameter");this._options.enabledDates=this._indexGivenDates(t);this._options.disabledDates=!1;this._update()},b.prototype.daysOfWeekDisabled=function(n){var t,i;if(arguments.length===0)return this._options.daysOfWeekDisabled.splice(0);if(typeof n=="boolean"&&!n)return this._options.daysOfWeekDisabled=!1,this._update(),!0;if(!(n instanceof Array))throw new TypeError("daysOfWeekDisabled() expects an array parameter");if(this._options.daysOfWeekDisabled=n.reduce(function(n,t){return(t=parseInt(t,10),t>6||t<0||isNaN(t))?n:(n.indexOf(t)===-1&&n.push(t),n)},[]).sort(),this._options.useCurrent&&!this._options.keepInvalid)for(t=0;t<this._dates.length;t++){for(i=0;!this._isValid(this._dates[t],"d");){if(this._dates[t].add(1,"d"),i===31)throw"Tried 31 times to find a valid date";i++}this._setValue(this._dates[t],t)}this._update()},b.prototype.maxDate=function(n){var t,i;if(arguments.length===0)return this._options.maxDate?this._options.maxDate.clone():this._options.maxDate;if(typeof n=="boolean"&&n===!1)return this._options.maxDate=!1,this._update(),!0;if(typeof n=="string"&&(n==="now"||n==="moment")&&(n=this.getMoment()),t=this._parseInputDate(n),!t.isValid())throw new TypeError("maxDate() Could not parse date parameter: "+n);if(this._options.minDate&&t.isBefore(this._options.minDate))throw new TypeError("maxDate() date parameter is before this.options.minDate: "+t.format(this.actualFormat));for(this._options.maxDate=t,i=0;i<this._dates.length;i++)this._options.useCurrent&&!this._options.keepInvalid&&this._dates[i].isAfter(n)&&this._setValue(this._options.maxDate,i);this._viewDate.isAfter(t)&&(this._viewDate=t.clone().subtract(this._options.stepping,"m"));this._update()},b.prototype.minDate=function(n){var t,i;if(arguments.length===0)return this._options.minDate?this._options.minDate.clone():this._options.minDate;if(typeof n=="boolean"&&n===!1)return this._options.minDate=!1,this._update(),!0;if(typeof n=="string"&&(n==="now"||n==="moment")&&(n=this.getMoment()),t=this._parseInputDate(n),!t.isValid())throw new TypeError("minDate() Could not parse date parameter: "+n);if(this._options.maxDate&&t.isAfter(this._options.maxDate))throw new TypeError("minDate() date parameter is after this.options.maxDate: "+t.format(this.actualFormat));for(this._options.minDate=t,i=0;i<this._dates.length;i++)this._options.useCurrent&&!this._options.keepInvalid&&this._dates[i].isBefore(n)&&this._setValue(this._options.minDate,i);this._viewDate.isBefore(t)&&(this._viewDate=t.clone().add(this._options.stepping,"m"));this._update()},b.prototype.defaultDate=function(n){if(arguments.length===0)return this._options.defaultDate?this._options.defaultDate.clone():this._options.defaultDate;if(!n)return this._options.defaultDate=!1,!0;typeof n=="string"&&(n=n==="now"||n==="moment"?this.getMoment():this.getMoment(n));var t=this._parseInputDate(n);if(!t.isValid())throw new TypeError("defaultDate() Could not parse date parameter: "+n);if(!this._isValid(t))throw new TypeError("defaultDate() date passed is invalid according to component setup validations");this._options.defaultDate=t;(this._options.defaultDate&&this._options.inline||this.input!==undefined&&this.input.val().trim()==="")&&this._setValue(this._options.defaultDate,0)},b.prototype.locale=function(n){if(arguments.length===0)return this._options.locale;if(!i.localeData(n))throw new TypeError("locale() locale "+n+" is not loaded from moment locales!");this._options.locale=n;for(var t=0;t<this._dates.length;t++)this._dates[t].locale(this._options.locale);this._viewDate.locale(this._options.locale);this.actualFormat&&this._initFormatting();this.widget&&(this.hide(),this.show())},b.prototype.stepping=function(n){if(arguments.length===0)return this._options.stepping;n=parseInt(n,10);(isNaN(n)||n<1)&&(n=1);this._options.stepping=n},b.prototype.useCurrent=function(n){var t=["year","month","day","hour","minute"];if(arguments.length===0)return this._options.useCurrent;if(typeof n!="boolean"&&typeof n!="string")throw new TypeError("useCurrent() expects a boolean or string parameter");if(typeof n=="string"&&t.indexOf(n.toLowerCase())===-1)throw new TypeError("useCurrent() expects a string parameter of "+t.join(", "));this._options.useCurrent=n},b.prototype.collapse=function(n){if(arguments.length===0)return this._options.collapse;if(typeof n!="boolean")throw new TypeError("collapse() expects a boolean parameter");if(this._options.collapse===n)return!0;this._options.collapse=n;this.widget&&(this.hide(),this.show())},b.prototype.icons=function(t){if(arguments.length===0)return n.extend({},this._options.icons);if(!(t instanceof Object))throw new TypeError("icons() expects parameter to be an Object");n.extend(this._options.icons,t);this.widget&&(this.hide(),this.show())},b.prototype.tooltips=function(t){if(arguments.length===0)return n.extend({},this._options.tooltips);if(!(t instanceof Object))throw new TypeError("tooltips() expects parameter to be an Object");n.extend(this._options.tooltips,t);this.widget&&(this.hide(),this.show())},b.prototype.useStrict=function(n){if(arguments.length===0)return this._options.useStrict;if(typeof n!="boolean")throw new TypeError("useStrict() expects a boolean parameter");this._options.useStrict=n},b.prototype.sideBySide=function(n){if(arguments.length===0)return this._options.sideBySide;if(typeof n!="boolean")throw new TypeError("sideBySide() expects a boolean parameter");this._options.sideBySide=n;this.widget&&(this.hide(),this.show())},b.prototype.viewMode=function(n){if(arguments.length===0)return this._options.viewMode;if(typeof n!="string")throw new TypeError("viewMode() expects a string parameter");if(b.ViewModes.indexOf(n)===-1)throw new TypeError("viewMode() parameter must be one of ("+b.ViewModes.join(", ")+") value");this._options.viewMode=n;this.currentViewMode=Math.max(b.ViewModes.indexOf(n)-1,this.MinViewModeNumber);this._showMode()},b.prototype.calendarWeeks=function(n){if(arguments.length===0)return this._options.calendarWeeks;if(typeof n!="boolean")throw new TypeError("calendarWeeks() expects parameter to be a boolean value");this._options.calendarWeeks=n;this._update()},b.prototype.buttons=function(t){if(arguments.length===0)return n.extend({},this._options.buttons);if(!(t instanceof Object))throw new TypeError("buttons() expects parameter to be an Object");if(n.extend(this._options.buttons,t),typeof this._options.buttons.showToday!="boolean")throw new TypeError("buttons.showToday expects a boolean parameter");if(typeof this._options.buttons.showClear!="boolean")throw new TypeError("buttons.showClear expects a boolean parameter");if(typeof this._options.buttons.showClose!="boolean")throw new TypeError("buttons.showClose expects a boolean parameter");this.widget&&(this.hide(),this.show())},b.prototype.keepOpen=function(n){if(arguments.length===0)return this._options.keepOpen;if(typeof n!="boolean")throw new TypeError("keepOpen() expects a boolean parameter");this._options.keepOpen=n},b.prototype.focusOnShow=function(n){if(arguments.length===0)return this._options.focusOnShow;if(typeof n!="boolean")throw new TypeError("focusOnShow() expects a boolean parameter");this._options.focusOnShow=n},b.prototype.inline=function(n){if(arguments.length===0)return this._options.inline;if(typeof n!="boolean")throw new TypeError("inline() expects a boolean parameter");this._options.inline=n},b.prototype.clear=function(){this._setValue(null)},b.prototype.keyBinds=function(n){if(arguments.length===0)return this._options.keyBinds;this._options.keyBinds=n},b.prototype.debug=function(n){if(typeof n!="boolean")throw new TypeError("debug() expects a boolean parameter");this._options.debug=n},b.prototype.allowInputToggle=function(n){if(arguments.length===0)return this._options.allowInputToggle;if(typeof n!="boolean")throw new TypeError("allowInputToggle() expects a boolean parameter");this._options.allowInputToggle=n},b.prototype.keepInvalid=function(n){if(arguments.length===0)return this._options.keepInvalid;if(typeof n!="boolean")throw new TypeError("keepInvalid() expects a boolean parameter");this._options.keepInvalid=n},b.prototype.datepickerInput=function(n){if(arguments.length===0)return this._options.datepickerInput;if(typeof n!="string")throw new TypeError("datepickerInput() expects a string parameter");this._options.datepickerInput=n},b.prototype.parseInputDate=function(n){if(arguments.length===0)return this._options.parseInputDate;if(typeof n!="function")throw new TypeError("parseInputDate() should be as function");this._options.parseInputDate=n},b.prototype.disabledTimeIntervals=function(t){if(arguments.length===0)return this._options.disabledTimeIntervals?n.extend({},this._options.disabledTimeIntervals):this._options.disabledTimeIntervals;if(!t)return this._options.disabledTimeIntervals=!1,this._update(),!0;if(!(t instanceof Array))throw new TypeError("disabledTimeIntervals() expects an array parameter");this._options.disabledTimeIntervals=t;this._update()},b.prototype.disabledHours=function(t){var i,r;if(arguments.length===0)return this._options.disabledHours?n.extend({},this._options.disabledHours):this._options.disabledHours;if(!t)return this._options.disabledHours=!1,this._update(),!0;if(!(t instanceof Array))throw new TypeError("disabledHours() expects an array parameter");if(this._options.disabledHours=this._indexGivenHours(t),this._options.enabledHours=!1,this._options.useCurrent&&!this._options.keepInvalid)for(i=0;i<this._dates.length;i++){for(r=0;!this._isValid(this._dates[i],"h");){if(this._dates[i].add(1,"h"),r===24)throw"Tried 24 times to find a valid date";r++}this._setValue(this._dates[i],i)}this._update()},b.prototype.enabledHours=function(t){var i,r;if(arguments.length===0)return this._options.enabledHours?n.extend({},this._options.enabledHours):this._options.enabledHours;if(!t)return this._options.enabledHours=!1,this._update(),!0;if(!(t instanceof Array))throw new TypeError("enabledHours() expects an array parameter");if(this._options.enabledHours=this._indexGivenHours(t),this._options.disabledHours=!1,this._options.useCurrent&&!this._options.keepInvalid)for(i=0;i<this._dates.length;i++){for(r=0;!this._isValid(this._dates[i],"h");){if(this._dates[i].add(1,"h"),r===24)throw"Tried 24 times to find a valid date";r++}this._setValue(this._dates[i],i)}this._update()},b.prototype.viewDate=function(n){if(arguments.length===0)return this._viewDate.clone();if(!n)return this._viewDate=(this._dates[0]||this.getMoment()).clone(),!0;if(typeof n!="string"&&!i.isMoment(n)&&!(n instanceof Date))throw new TypeError("viewDate() parameter must be one of [string, moment or Date]");this._viewDate=this._parseInputDate(n);this._viewUpdate()},b.prototype.allowMultidate=function(n){if(typeof n!="boolean")throw new TypeError("allowMultidate() expects a boolean parameter");this._options.allowMultidate=n},b.prototype.multidateSeparator=function(n){if(arguments.length===0)return this._options.multidateSeparator;if(typeof n!="string"||n.length>1)throw new TypeError("multidateSeparator expects a single character string parameter");this._options.multidateSeparator=n},r(b,null,[{key:"NAME",get:function(){return e}},{key:"DATA_KEY",get:function(){return o}},{key:"EVENT_KEY",get:function(){return u}},{key:"DATA_API_KEY",get:function(){return h}},{key:"DatePickerModes",get:function(){return c}},{key:"ViewModes",get:function(){return w}},{key:"Event",get:function(){return p}},{key:"Selector",get:function(){return v}},{key:"Default",get:function(){return s},set:function(n){s=n}},{key:"ClassName",get:function(){return y}}]),b}()}(jQuery,moment),e=function(r){var l=r.fn[n.NAME],s=["top","bottom","auto"],h=["left","right","auto"],c=["default","top","bottom"],o=function(t){var i=t.data("target"),u=void 0;return(i||(i=t.attr("href")||"",i=/^#[a-z]/i.test(i)?i:null),u=r(i),u.length===0)?u:(u.data(n.DATA_KEY)||r.extend({},u.data(),r(this).data()),u)},e=function(e){function o(n,i){t(this,o);var r=u(this,e.call(this,n,i));return r._init(),r}return f(o,e),o.prototype._init=function(){if(this._element.hasClass("input-group")){var n=this._element.find(".datepickerbutton");this.component=n.length===0?this._element.find('[data-toggle="datetimepicker"]'):n}},o.prototype._getDatePickerTemplate=function(){var n=r("<thead>").append(r("<tr>").append(r("<th>").addClass("prev").attr("data-action","previous").append(r("<span>").addClass(this._options.icons.previous))).append(r("<th>").addClass("picker-switch").attr("data-action","pickerSwitch").attr("colspan",""+(this._options.calendarWeeks?"6":"5"))).append(r("<th>").addClass("next").attr("data-action","next").append(r("<span>").addClass(this._options.icons.next)))),t=r("<tbody>").append(r("<tr>").append(r("<td>").attr("colspan",""+(this._options.calendarWeeks?"8":"7"))));return[r("<div>").addClass("datepicker-days").append(r("<table>").addClass("table table-sm").append(n).append(r("<tbody>"))),r("<div>").addClass("datepicker-months").append(r("<table>").addClass("table-condensed").append(n.clone()).append(t.clone())),r("<div>").addClass("datepicker-years").append(r("<table>").addClass("table-condensed").append(n.clone()).append(t.clone())),r("<div>").addClass("datepicker-decades").append(r("<table>").addClass("table-condensed").append(n.clone()).append(t.clone()))]},o.prototype._getTimePickerMainTemplate=function(){var n=r("<tr>"),t=r("<tr>"),i=r("<tr>");return this._isEnabled("h")&&(n.append(r("<td>").append(r("<a>").attr({href:"#",tabindex:"-1",title:this._options.tooltips.incrementHour}).addClass("btn").attr("data-action","incrementHours").append(r("<span>").addClass(this._options.icons.up)))),t.append(r("<td>").append(r("<span>").addClass("timepicker-hour").attr({"data-time-component":"hours",title:this._options.tooltips.pickHour}).attr("data-action","showHours"))),i.append(r("<td>").append(r("<a>").attr({href:"#",tabindex:"-1",title:this._options.tooltips.decrementHour}).addClass("btn").attr("data-action","decrementHours").append(r("<span>").addClass(this._options.icons.down))))),this._isEnabled("m")&&(this._isEnabled("h")&&(n.append(r("<td>").addClass("separator")),t.append(r("<td>").addClass("separator").html(":")),i.append(r("<td>").addClass("separator"))),n.append(r("<td>").append(r("<a>").attr({href:"#",tabindex:"-1",title:this._options.tooltips.incrementMinute}).addClass("btn").attr("data-action","incrementMinutes").append(r("<span>").addClass(this._options.icons.up)))),t.append(r("<td>").append(r("<span>").addClass("timepicker-minute").attr({"data-time-component":"minutes",title:this._options.tooltips.pickMinute}).attr("data-action","showMinutes"))),i.append(r("<td>").append(r("<a>").attr({href:"#",tabindex:"-1",title:this._options.tooltips.decrementMinute}).addClass("btn").attr("data-action","decrementMinutes").append(r("<span>").addClass(this._options.icons.down))))),this._isEnabled("s")&&(this._isEnabled("m")&&(n.append(r("<td>").addClass("separator")),t.append(r("<td>").addClass("separator").html(":")),i.append(r("<td>").addClass("separator"))),n.append(r("<td>").append(r("<a>").attr({href:"#",tabindex:"-1",title:this._options.tooltips.incrementSecond}).addClass("btn").attr("data-action","incrementSeconds").append(r("<span>").addClass(this._options.icons.up)))),t.append(r("<td>").append(r("<span>").addClass("timepicker-second").attr({"data-time-component":"seconds",title:this._options.tooltips.pickSecond}).attr("data-action","showSeconds"))),i.append(r("<td>").append(r("<a>").attr({href:"#",tabindex:"-1",title:this._options.tooltips.decrementSecond}).addClass("btn").attr("data-action","decrementSeconds").append(r("<span>").addClass(this._options.icons.down))))),this.use24Hours||(n.append(r("<td>").addClass("separator")),t.append(r("<td>").append(r("<button>").addClass("btn btn-gray").attr({"data-action":"togglePeriod",tabindex:"-1",title:this._options.tooltips.togglePeriod}))),i.append(r("<td>").addClass("separator"))),r("<div>").addClass("timepicker-picker").append(r("<table>").addClass("table-condensed").append([n,t,i]))},o.prototype._getTimePickerTemplate=function(){var t=r("<div>").addClass("timepicker-hours").append(r("<table>").addClass("table-condensed")),i=r("<div>").addClass("timepicker-minutes").append(r("<table>").addClass("table-condensed")),u=r("<div>").addClass("timepicker-seconds").append(r("<table>").addClass("table-condensed")),n=[this._getTimePickerMainTemplate()];return this._isEnabled("h")&&n.push(t),this._isEnabled("m")&&n.push(i),this._isEnabled("s")&&n.push(u),n},o.prototype._getToolbar=function(){var n=[],t,i;return this._options.buttons.showToday&&n.push(r("<td>").append(r("<a>").attr({href:"#",tabindex:"-1","data-action":"today",title:this._options.tooltips.today}).append(r("<span>").addClass(this._options.icons.today)))),!this._options.sideBySide&&this._hasDate()&&this._hasTime()&&(t=void 0,i=void 0,this._options.viewMode==="times"?(t=this._options.tooltips.selectDate,i=this._options.icons.date):(t=this._options.tooltips.selectTime,i=this._options.icons.time),n.push(r("<td>").append(r("<a>").attr({href:"#",tabindex:"-1","data-action":"togglePicker",title:t}).append(r("<span>").addClass(i))))),this._options.buttons.showClear&&n.push(r("<td>").append(r("<a>").attr({href:"#",tabindex:"-1","data-action":"clear",title:this._options.tooltips.clear}).append(r("<span>").addClass(this._options.icons.clear)))),this._options.buttons.showClose&&n.push(r("<td>").append(r("<a>").attr({href:"#",tabindex:"-1","data-action":"close",title:this._options.tooltips.close}).append(r("<span>").addClass(this._options.icons.close)))),n.length===0?"":r("<table>").addClass("table-condensed").append(r("<tbody>").append(r("<tr>").append(n)))},o.prototype._getTemplate=function(){var n=r("<div>").addClass("bootstrap-datetimepicker-widget dropdown-menu"),u=r("<div>").addClass("datepicker").append(this._getDatePickerTemplate()),f=r("<div>").addClass("timepicker").append(this._getTimePickerTemplate()),t=r("<ul>").addClass("list-unstyled"),i=r("<li>").addClass("picker-switch"+(this._options.collapse?" accordion-toggle":"")).append(this._getToolbar());return(this._options.inline&&n.removeClass("dropdown-menu"),this.use24Hours&&n.addClass("usetwentyfour"),this._isEnabled("s")&&!this.use24Hours&&n.addClass("wider"),this._options.sideBySide&&this._hasDate()&&this._hasTime())?(n.addClass("timepicker-sbs"),this._options.toolbarPlacement==="top"&&n.append(i),n.append(r("<div>").addClass("row").append(u.addClass("col-md-6")).append(f.addClass("col-md-6"))),(this._options.toolbarPlacement==="bottom"||this._options.toolbarPlacement==="default")&&n.append(i),n):(this._options.toolbarPlacement==="top"&&t.append(i),this._hasDate()&&t.append(r("<li>").addClass(this._options.collapse&&this._hasTime()?"collapse":"").addClass(this._options.collapse&&this._hasTime()&&this._options.viewMode==="times"?"":"show").append(u)),this._options.toolbarPlacement==="default"&&t.append(i),this._hasTime()&&t.append(r("<li>").addClass(this._options.collapse&&this._hasDate()?"collapse":"").addClass(this._options.collapse&&this._hasDate()&&this._options.viewMode==="times"?"show":"").append(f)),this._options.toolbarPlacement==="bottom"&&t.append(i),n.append(t))},o.prototype._place=function(n){var t=n&&n.data&&n.data.picker||this,u=t._options.widgetPositioning.vertical,f=t._options.widgetPositioning.horizontal,i=void 0,e=(t.component&&t.component.length?t.component:t._element).position(),o=(t.component&&t.component.length?t.component:t._element).offset();if(t._options.widgetParent)i=t._options.widgetParent.append(t.widget);else if(t._element.is("input"))i=t._element.after(t.widget).parent();else{if(t._options.inline){i=t._element.append(t.widget);return}i=t._element;t._element.children().first().after(t.widget)}if(u==="auto"&&(u=o.top+t.widget.height()*1.5>=r(window).height()+r(window).scrollTop()&&t.widget.height()+t._element.outerHeight()<o.top?"top":"bottom"),f==="auto"&&(f=i.width()<o.left+t.widget.outerWidth()/2&&o.left+t.widget.outerWidth()>r(window).width()?"right":"left"),u==="top"?t.widget.addClass("top").removeClass("bottom"):t.widget.addClass("bottom").removeClass("top"),f==="right"?t.widget.addClass("float-right"):t.widget.removeClass("float-right"),i.css("position")!=="relative"&&(i=i.parents().filter(function(){return r(this).css("position")==="relative"}).first()),i.length===0)throw new Error("datetimepicker component should be placed within a relative positioned container");t.widget.css({top:u==="top"?"auto":e.top+t._element.outerHeight()+"px",bottom:u==="top"?i.outerHeight()-(i===t._element?0:e.top)+"px":"auto",left:f==="left"?(i===t._element?0:e.left)+"px":"auto",right:f==="left"?"auto":i.outerWidth()-t._element.outerWidth()-(i===t._element?0:e.left)+"px"})},o.prototype._fillDow=function(){var n=r("<tr>"),t=this._viewDate.clone().startOf("w").startOf("d");for(this._options.calendarWeeks===!0&&n.append(r("<th>").addClass("cw").text("#"));t.isBefore(this._viewDate.clone().endOf("w"));)n.append(r("<th>").addClass("dow").text(t.format("dd"))),t.add(1,"d");this.widget.find(".datepicker-days thead").append(n)},o.prototype._fillMonths=function(){for(var t=[],n=this._viewDate.clone().startOf("y").startOf("d");n.isSame(this._viewDate,"y");)t.push(r("<span>").attr("data-action","selectMonth").addClass("month").text(n.format("MMM"))),n.add(1,"M");this.widget.find(".datepicker-months td").empty().append(t)},o.prototype._updateMonths=function(){var t=this.widget.find(".datepicker-months"),n=t.find("th"),i=t.find("tbody").find("span"),u=this;n.eq(0).find("span").attr("title",this._options.tooltips.prevYear);n.eq(1).attr("title",this._options.tooltips.selectYear);n.eq(2).find("span").attr("title",this._options.tooltips.nextYear);t.find(".disabled").removeClass("disabled");this._isValid(this._viewDate.clone().subtract(1,"y"),"y")||n.eq(0).addClass("disabled");n.eq(1).text(this._viewDate.year());this._isValid(this._viewDate.clone().add(1,"y"),"y")||n.eq(2).addClass("disabled");i.removeClass("active");this._getLastPickedDate().isSame(this._viewDate,"y")&&!this.unset&&i.eq(this._getLastPickedDate().month()).addClass("active");i.each(function(n){u._isValid(u._viewDate.clone().month(n),"M")||r(this).addClass("disabled")})},o.prototype._getStartEndYear=function(n,t){var i=n/10,r=Math.floor(t/n)*n,u=r+i*9,f=Math.floor(t/i)*i;return[r,u,f]},o.prototype._updateYears=function(){var r=this.widget.find(".datepicker-years"),t=r.find("th"),f=this._getStartEndYear(10,this._viewDate.year()),n=this._viewDate.clone().year(f[0]),u=this._viewDate.clone().year(f[1]),i="";for(t.eq(0).find("span").attr("title",this._options.tooltips.prevDecade),t.eq(1).attr("title",this._options.tooltips.selectDecade),t.eq(2).find("span").attr("title",this._options.tooltips.nextDecade),r.find(".disabled").removeClass("disabled"),this._options.minDate&&this._options.minDate.isAfter(n,"y")&&t.eq(0).addClass("disabled"),t.eq(1).text(n.year()+"-"+u.year()),this._options.maxDate&&this._options.maxDate.isBefore(u,"y")&&t.eq(2).addClass("disabled"),i+='<span data-action="selectYear" class="year old'+(this._isValid(n,"y")?"":" disabled")+'">'+(n.year()-1)+"<\/span>";!n.isAfter(u,"y");)i+='<span data-action="selectYear" class="year'+(n.isSame(this._getLastPickedDate(),"y")&&!this.unset?" active":"")+(this._isValid(n,"y")?"":" disabled")+'">'+n.year()+"<\/span>",n.add(1,"y");i+='<span data-action="selectYear" class="year old'+(this._isValid(n,"y")?"":" disabled")+'">'+n.year()+"<\/span>";r.find("td").html(i)},o.prototype._updateDecades=function(){var u=this.widget.find(".datepicker-decades"),t=u.find("th"),e=this._getStartEndYear(100,this._viewDate.year()),n=this._viewDate.clone().year(e[0]),f=this._viewDate.clone().year(e[1]),o=!1,s=!1,i=void 0,r="";for(t.eq(0).find("span").attr("title",this._options.tooltips.prevCentury),t.eq(2).find("span").attr("title",this._options.tooltips.nextCentury),u.find(".disabled").removeClass("disabled"),(n.year()===0||this._options.minDate&&this._options.minDate.isAfter(n,"y"))&&t.eq(0).addClass("disabled"),t.eq(1).text(n.year()+"-"+f.year()),this._options.maxDate&&this._options.maxDate.isBefore(f,"y")&&t.eq(2).addClass("disabled"),r+=n.year()-10<0?"<span>&nbsp;<\/span>":'<span data-action="selectDecade" class="decade old" data-selection="'+(n.year()+6)+'">'+(n.year()-10)+"<\/span>";!n.isAfter(f,"y");)i=n.year()+11,o=this._options.minDate&&this._options.minDate.isAfter(n,"y")&&this._options.minDate.year()<=i,s=this._options.maxDate&&this._options.maxDate.isAfter(n,"y")&&this._options.maxDate.year()<=i,r+='<span data-action="selectDecade" class="decade'+(this._getLastPickedDate().isAfter(n)&&this._getLastPickedDate().year()<=i?" active":"")+(!this._isValid(n,"y")&&!o&&!s?" disabled":"")+'" data-selection="'+(n.year()+6)+'">'+n.year()+"<\/span>",n.add(10,"y");r+='<span data-action="selectDecade" class="decade old" data-selection="'+(n.year()+6)+'">'+n.year()+"<\/span>";u.find("td").html(r)},o.prototype._fillDate=function(){var f=this.widget.find(".datepicker-days"),i=f.find("th"),s=[],n=void 0,u=void 0,t=void 0,e=void 0,o;if(this._hasDate()){for(i.eq(0).find("span").attr("title",this._options.tooltips.prevMonth),i.eq(1).attr("title",this._options.tooltips.selectMonth),i.eq(2).find("span").attr("title",this._options.tooltips.nextMonth),f.find(".disabled").removeClass("disabled"),i.eq(1).text(this._viewDate.format(this._options.dayViewHeaderFormat)),this._isValid(this._viewDate.clone().subtract(1,"M"),"M")||i.eq(0).addClass("disabled"),this._isValid(this._viewDate.clone().add(1,"M"),"M")||i.eq(2).addClass("disabled"),n=this._viewDate.clone().startOf("M").startOf("w").startOf("d"),e=0;e<42;e++)n.weekday()===0&&(u=r("<tr>"),this._options.calendarWeeks&&u.append('<td class="cw">'+n.week()+"<\/td>"),s.push(u)),t="",n.isBefore(this._viewDate,"M")&&(t+=" old"),n.isAfter(this._viewDate,"M")&&(t+=" new"),this._options.allowMultidate?(o=this._datesFormatted.indexOf(n.format("YYYY-MM-DD")),o!==-1&&n.isSame(this._datesFormatted[o],"d")&&!this.unset&&(t+=" active")):n.isSame(this._getLastPickedDate(),"d")&&!this.unset&&(t+=" active"),this._isValid(n,"d")||(t+=" disabled"),n.isSame(this.getMoment(),"d")&&(t+=" today"),(n.day()===0||n.day()===6)&&(t+=" weekend"),u.append('<td data-action="selectDay" data-day="'+n.format("L")+'" class="day'+t+'">'+n.date()+"<\/td>"),n.add(1,"d");f.find("tbody").empty().append(s);this._updateMonths();this._updateYears();this._updateDecades()}},o.prototype._fillHours=function(){var u=this.widget.find(".timepicker-hours table"),n=this._viewDate.clone().startOf("d"),i=[],t=r("<tr>");for(this._viewDate.hour()>11&&!this.use24Hours&&n.hour(12);n.isSame(this._viewDate,"d")&&(this.use24Hours||this._viewDate.hour()<12&&n.hour()<12||this._viewDate.hour()>11);)n.hour()%4==0&&(t=r("<tr>"),i.push(t)),t.append('<td data-action="selectHour" class="hour'+(this._isValid(n,"h")?"":" disabled")+'">'+n.format(this.use24Hours?"HH":"hh")+"<\/td>"),n.add(1,"h");u.empty().append(i)},o.prototype._fillMinutes=function(){for(var f=this.widget.find(".timepicker-minutes table"),n=this._viewDate.clone().startOf("h"),i=[],u=this._options.stepping===1?5:this._options.stepping,t=r("<tr>");this._viewDate.isSame(n,"h");)n.minute()%(u*4)==0&&(t=r("<tr>"),i.push(t)),t.append('<td data-action="selectMinute" class="minute'+(this._isValid(n,"m")?"":" disabled")+'">'+n.format("mm")+"<\/td>"),n.add(u,"m");f.empty().append(i)},o.prototype._fillSeconds=function(){for(var u=this.widget.find(".timepicker-seconds table"),n=this._viewDate.clone().startOf("m"),i=[],t=r("<tr>");this._viewDate.isSame(n,"m");)n.second()%20==0&&(t=r("<tr>"),i.push(t)),t.append('<td data-action="selectSecond" class="second'+(this._isValid(n,"s")?"":" disabled")+'">'+n.format("ss")+"<\/td>"),n.add(5,"s");u.empty().append(i)},o.prototype._fillTime=function(){var n=void 0,i=void 0,t=this.widget.find(".timepicker span[data-time-component]");this.use24Hours||(n=this.widget.find(".timepicker [data-action=togglePeriod]"),i=this._getLastPickedDate().clone().add(this._getLastPickedDate().hours()>=12?-12:12,"h"),n.text(this._getLastPickedDate().format("A")),this._isValid(i,"h")?n.removeClass("disabled"):n.addClass("disabled"));t.filter("[data-time-component=hours]").text(this._getLastPickedDate().format(""+(this.use24Hours?"HH":"hh")));t.filter("[data-time-component=minutes]").text(this._getLastPickedDate().format("mm"));t.filter("[data-time-component=seconds]").text(this._getLastPickedDate().format("ss"));this._fillHours();this._fillMinutes();this._fillSeconds()},o.prototype._doAction=function(t,i){var u=this._getLastPickedDate(),l,a,nt,tt,it,s,h,c,v,y,p,w,b,k,e,g;if(r(t.currentTarget).is(".disabled"))return!1;i=i||r(t.currentTarget).data("action");switch(i){case"next":l=n.DatePickerModes[this.currentViewMode].NAV_FUNCTION;this._viewDate.add(n.DatePickerModes[this.currentViewMode].NAV_STEP,l);this._fillDate();this._viewUpdate(l);break;case"previous":a=n.DatePickerModes[this.currentViewMode].NAV_FUNCTION;this._viewDate.subtract(n.DatePickerModes[this.currentViewMode].NAV_STEP,a);this._fillDate();this._viewUpdate(a);break;case"pickerSwitch":this._showMode(1);break;case"selectMonth":nt=r(t.target).closest("tbody").find("span").index(r(t.target));this._viewDate.month(nt);this.currentViewMode===this.MinViewModeNumber?(this._setValue(u.clone().year(this._viewDate.year()).month(this._viewDate.month()),this._getLastPickedDateIndex()),this._options.inline||this.hide()):(this._showMode(-1),this._fillDate());this._viewUpdate("M");break;case"selectYear":tt=parseInt(r(t.target).text(),10)||0;this._viewDate.year(tt);this.currentViewMode===this.MinViewModeNumber?(this._setValue(u.clone().year(this._viewDate.year()),this._getLastPickedDateIndex()),this._options.inline||this.hide()):(this._showMode(-1),this._fillDate());this._viewUpdate("YYYY");break;case"selectDecade":it=parseInt(r(t.target).data("selection"),10)||0;this._viewDate.year(it);this.currentViewMode===this.MinViewModeNumber?(this._setValue(u.clone().year(this._viewDate.year()),this._getLastPickedDateIndex()),this._options.inline||this.hide()):(this._showMode(-1),this._fillDate());this._viewUpdate("YYYY");break;case"selectDay":s=this._viewDate.clone();r(t.target).is(".old")&&s.subtract(1,"M");r(t.target).is(".new")&&s.add(1,"M");h=s.date(parseInt(r(t.target).text(),10));c=0;this._options.allowMultidate?(c=this._datesFormatted.indexOf(h.format("YYYY-MM-DD")),c!==-1?this._setValue(null,c):this._setValue(h,this._getLastPickedDateIndex()+1)):this._setValue(h,this._getLastPickedDateIndex());this._hasTime()||this._options.keepOpen||this._options.inline||this._options.allowMultidate||this.hide();break;case"incrementHours":v=u.clone().add(1,"h");this._isValid(v,"h")&&this._setValue(v,this._getLastPickedDateIndex());break;case"incrementMinutes":y=u.clone().add(this._options.stepping,"m");this._isValid(y,"m")&&this._setValue(y,this._getLastPickedDateIndex());break;case"incrementSeconds":p=u.clone().add(1,"s");this._isValid(p,"s")&&this._setValue(p,this._getLastPickedDateIndex());break;case"decrementHours":w=u.clone().subtract(1,"h");this._isValid(w,"h")&&this._setValue(w,this._getLastPickedDateIndex());break;case"decrementMinutes":b=u.clone().subtract(this._options.stepping,"m");this._isValid(b,"m")&&this._setValue(b,this._getLastPickedDateIndex());break;case"decrementSeconds":k=u.clone().subtract(1,"s");this._isValid(k,"s")&&this._setValue(k,this._getLastPickedDateIndex());break;case"togglePeriod":this._setValue(u.clone().add(u.hours()>=12?-12:12,"h"),this._getLastPickedDateIndex());break;case"togglePicker":var o=r(t.target),rt=o.closest("a"),ut=o.closest("ul"),f=ut.find(".show"),ft=ut.find(".collapse:not(.show)"),et=o.is("span")?o:o.find("span"),d=void 0;if(f&&f.length){if(d=f.data("collapse"),d&&d.transitioning)return!0;f.collapse?(f.collapse("hide"),ft.collapse("show")):(f.removeClass("show"),ft.addClass("show"));et.toggleClass(this._options.icons.time+" "+this._options.icons.date);et.hasClass(this._options.icons.date)?rt.attr("title",this._options.tooltips.selectDate):rt.attr("title",this._options.tooltips.selectTime)}break;case"showPicker":this.widget.find(".timepicker > div:not(.timepicker-picker)").hide();this.widget.find(".timepicker .timepicker-picker").show();break;case"showHours":this.widget.find(".timepicker .timepicker-picker").hide();this.widget.find(".timepicker .timepicker-hours").show();break;case"showMinutes":this.widget.find(".timepicker .timepicker-picker").hide();this.widget.find(".timepicker .timepicker-minutes").show();break;case"showSeconds":this.widget.find(".timepicker .timepicker-picker").hide();this.widget.find(".timepicker .timepicker-seconds").show();break;case"selectHour":e=parseInt(r(t.target).text(),10);this.use24Hours||(u.hours()>=12?e!==12&&(e+=12):e===12&&(e=0));this._setValue(u.clone().hours(e),this._getLastPickedDateIndex());this._isEnabled("a")||this._isEnabled("m")||this._options.keepOpen||this._options.inline?this._doAction(t,"showPicker"):this.hide();break;case"selectMinute":this._setValue(u.clone().minutes(parseInt(r(t.target).text(),10)),this._getLastPickedDateIndex());this._isEnabled("a")||this._isEnabled("s")||this._options.keepOpen||this._options.inline?this._doAction(t,"showPicker"):this.hide();break;case"selectSecond":this._setValue(u.clone().seconds(parseInt(r(t.target).text(),10)),this._getLastPickedDateIndex());this._isEnabled("a")||this._options.keepOpen||this._options.inline?this._doAction(t,"showPicker"):this.hide();break;case"clear":this.clear();break;case"close":this.hide();break;case"today":g=this.getMoment();this._isValid(g,"d")&&this._setValue(g,this._getLastPickedDateIndex())}return!1},o.prototype.hide=function(){var t=!1;this.widget&&((this.widget.find(".collapse").each(function(){var n=r(this).data("collapse");return n&&n.transitioning?(t=!0,!1):!0}),t)||(this.component&&this.component.hasClass("btn")&&this.component.toggleClass("active"),this.widget.hide(),r(window).off("resize",this._place),this.widget.off("click","[data-action]"),this.widget.off("mousedown",!1),this.widget.remove(),this.widget=!1,this._notifyEvent({type:n.Event.HIDE,date:this._getLastPickedDate().clone()}),this.input!==undefined&&this.input.blur(),this._viewDate=this._getLastPickedDate().clone()))},o.prototype.show=function(){var t=void 0,i={year:function(n){return n.month(0).date(1).hours(0).seconds(0).minutes(0)},month:function(n){return n.date(1).hours(0).seconds(0).minutes(0)},day:function(n){return n.hours(0).seconds(0).minutes(0)},hour:function(n){return n.seconds(0).minutes(0)},minute:function(n){return n.seconds(0)}};if(this.input!==undefined){if(this.input.prop("disabled")||!this._options.ignoreReadonly&&this.input.prop("readonly")||this.widget)return;this.input.val()!==undefined&&this.input.val().trim().length!==0?this._setValue(this._parseInputDate(this.input.val().trim()),0):this.unset&&this._options.useCurrent&&(t=this.getMoment(),typeof this._options.useCurrent=="string"&&(t=i[this._options.useCurrent](t)),this._setValue(t,0))}else this.unset&&this._options.useCurrent&&(t=this.getMoment(),typeof this._options.useCurrent=="string"&&(t=i[this._options.useCurrent](t)),this._setValue(t,0));this.widget=this._getTemplate();this._fillDow();this._fillMonths();this.widget.find(".timepicker-hours").hide();this.widget.find(".timepicker-minutes").hide();this.widget.find(".timepicker-seconds").hide();this._update();this._showMode();r(window).on("resize",{picker:this},this._place);this.widget.on("click","[data-action]",r.proxy(this._doAction,this));this.widget.on("mousedown",!1);this.component&&this.component.hasClass("btn")&&this.component.toggleClass("active");this._place();this.widget.show();this.input!==undefined&&this._options.focusOnShow&&!this.input.is(":focus")&&this.input.focus();this._notifyEvent({type:n.Event.SHOW})},o.prototype.destroy=function(){this.hide();this._element.removeData(n.DATA_KEY);this._element.removeData("date")},o.prototype.disable=function(){this.hide();this.component&&this.component.hasClass("btn")&&this.component.addClass("disabled");this.input!==undefined&&this.input.prop("disabled",!0)},o.prototype.enable=function(){this.component&&this.component.hasClass("btn")&&this.component.removeClass("disabled");this.input!==undefined&&this.input.prop("disabled",!1)},o.prototype.toolbarPlacement=function(n){if(arguments.length===0)return this._options.toolbarPlacement;if(typeof n!="string")throw new TypeError("toolbarPlacement() expects a string parameter");if(c.indexOf(n)===-1)throw new TypeError("toolbarPlacement() parameter must be one of ("+c.join(", ")+") value");this._options.toolbarPlacement=n;this.widget&&(this.hide(),this.show())},o.prototype.widgetPositioning=function(n){if(arguments.length===0)return r.extend({},this._options.widgetPositioning);if({}.toString.call(n)!=="[object Object]")throw new TypeError("widgetPositioning() expects an object variable");if(n.horizontal){if(typeof n.horizontal!="string")throw new TypeError("widgetPositioning() horizontal variable must be a string");if(n.horizontal=n.horizontal.toLowerCase(),h.indexOf(n.horizontal)===-1)throw new TypeError("widgetPositioning() expects horizontal parameter to be one of ("+h.join(", ")+")");this._options.widgetPositioning.horizontal=n.horizontal}if(n.vertical){if(typeof n.vertical!="string")throw new TypeError("widgetPositioning() vertical variable must be a string");if(n.vertical=n.vertical.toLowerCase(),s.indexOf(n.vertical)===-1)throw new TypeError("widgetPositioning() expects vertical parameter to be one of ("+s.join(", ")+")");this._options.widgetPositioning.vertical=n.vertical}this._update()},o.prototype.widgetParent=function(n){if(arguments.length===0)return this._options.widgetParent;if(typeof n=="string"&&(n=r(n)),n!==null&&typeof n!="string"&&!(n instanceof r))throw new TypeError("widgetParent() expects a string or a jQuery object parameter");this._options.widgetParent=n;this.widget&&(this.hide(),this.show())},o._jQueryHandleThis=function(t,u,f){var e=r(t).data(n.DATA_KEY);if((typeof u=="undefined"?"undefined":i(u))==="object"&&r.extend({},n.Default,u),e||(e=new o(r(t),u),r(t).data(n.DATA_KEY,e)),typeof u=="string"){if(e[u]===undefined)throw new Error('No method named "'+u+'"');return f===undefined?e[u]():e[u](f)}},o._jQueryInterface=function(n,t){return this.length===1?o._jQueryHandleThis(this[0],n,t):this.each(function(){o._jQueryHandleThis(this,n,t)})},o}(n);r(document).on(n.Event.CLICK_DATA_API,n.Selector.DATA_TOGGLE,function(){var n=o(r(this));n.length!==0&&e._jQueryInterface.call(n,"toggle")}).on(n.Event.CHANGE,"."+n.ClassName.INPUT,function(n){var t=o(r(this));t.length!==0&&e._jQueryInterface.call(t,"_change",n)}).on(n.Event.BLUR,"."+n.ClassName.INPUT,function(t){var i=o(r(this)),u=i.data(n.DATA_KEY);i.length!==0&&(u._options.debug||window.debug||e._jQueryInterface.call(i,"hide",t))}).on(n.Event.KEYDOWN,"."+n.ClassName.INPUT,function(n){var t=o(r(this));t.length!==0&&e._jQueryInterface.call(t,"_keydown",n)}).on(n.Event.KEYUP,"."+n.ClassName.INPUT,function(n){var t=o(r(this));t.length!==0&&e._jQueryInterface.call(t,"_keyup",n)}).on(n.Event.FOCUS,"."+n.ClassName.INPUT,function(t){var i=o(r(this)),u=i.data(n.DATA_KEY);i.length!==0&&typeof u!="undefined"&&u!=null&&u._options.allowInputToggle&&setTimeout(function(){r(".datepicker").is(":visible")||e._jQueryInterface.call(i,"show",t)},150)});return r.fn[n.NAME]=e._jQueryInterface,r.fn[n.NAME].Constructor=e,r.fn[n.NAME].noConflict=function(){return r.fn[n.NAME]=l,e._jQueryInterface},e}(jQuery)}();AutocompleteAddress=function(n,t){function o(n){return n.replace(/&/g,"and")}var i={},r=null,u=function(){return r},e=function(){return n.Deferred(function(n){navigator.geolocation?navigator.geolocation.getCurrentPosition(function(t){var i=[];CoordinateConversion.LatLonToUTMXY(CoordinateConversion.DegToRad(t.coords.latitude),CoordinateConversion.DegToRad(t.coords.longitude),15,i);r={LatLon:{x:t.coords.longitude,y:t.coords.latitude,spatialReference:{wkid:4326}},UTM:{x:i[0],y:i[1],spatialReference:{wkid:26915}}};n.resolve(r)},function(t){console.warn("getLocation failed: "+t);n.reject("Geolocation unavailable")},{enableHighAccuracy:!0,timeout:5e3,maximumAge:0}):n.reject("Geolocation unavailable")}).promise()},f=function(n){delete i[n]},s=function(r,e,s){n("#"+r).devbridgeAutocomplete({noCache:!0,autoSelectFirst:!0,minChars:1,showNoSuggestionNotice:!0,noSuggestionNotice:r==="fromLocation"?"No results - please check your spelling or use a Stop Number (include the word Stop)":"No results",width:"flex",lookup:function(i,r){var f=u(),e=f?JSON.stringify(f.LatLon):"{ x: -93.21, y: 44.97, spatialReference: { wkid: 4326 } }",s=o(i.replace(/[.,\/#!$%\^\*;:{}=\_`~()]/g,""));n.ajax({type:"get",url:t.serviceHostUrl+"/tripplanner/suggest/"+s+"/"+e,data:{},dataType:"json"}).done(function(t){var i=n.map(t,function(n){return{value:n.text,data:{magic_key:n.magic_key,geolocator:n.geolocator}}});r({suggestions:i})}).fail(function(){console.warn("Address locator failed for: "+i)})},onSelect:function(u){f(r);n.ajax({type:"get",url:t.serviceHostUrl+"/tripplanner/findaddress/"+u.data.magic_key+"/"+u.data.geolocator,data:{},dataType:"json"}).done(function(n){var t=[];CoordinateConversion.UTMXYToLatLon(parseFloat(n.x),parseFloat(n.y),15,!1,t);var f=CoordinateConversion.RadToDeg(t[0]),o=CoordinateConversion.RadToDeg(t[1]),h={address:n.address,attributes:{LongLabel:u.value,ATIS_ID:n.atis_id},location:{x:e?n.x:o,y:e?n.y:f}};i[r]=h;s&&s()}).fail(function(){console.warn("Call to FindCandidate failed for: "+u.value)});setTimeout(function(){n("#"+r+"Suggestions").hide()},3e3)}})},h=function(n){var t=null;return typeof i[n]!="undefined"&&(t=i[n]),t},c=function(n,t){var r=i[n];i[n]=i[t];i[t]=r},l=function(n){var t=null;return r&&(t={address:"your location",attributes:{LongLabel:"your current location",ATIS_ID:""},location:{x:r.UTM.x,y:r.UTM.y}},i[n]=t),t};return{init:s,getChoice:h,deleteChoice:f,fetchUserLoc:u,getUserLocation:e,exchangeValues:c,setUserLoc:l}}(jQuery,window,document);$(function(){AutocompleteAddress.getUserLocation()});"use strict";var _TIMECLOCK=null,CoordinateConversion=function(){function e(i){var u,f,e,o,s,r;return r=(t-n)/(t+n),u=(t+n)/2*(1+Math.pow(r,2)/4+Math.pow(r,4)/64),f=-3*r/2+9*Math.pow(r,3)/16+-3*Math.pow(r,5)/32,e=15*Math.pow(r,2)/16+-15*Math.pow(r,4)/32,o=-35*Math.pow(r,3)/48+105*Math.pow(r,5)/256,s=315*Math.pow(r,4)/512,u*(i+f*Math.sin(2*i)+e*Math.sin(4*i)+o*Math.sin(6*i)+s*Math.sin(8*i))}function u(n){return f(-183+n*6)}function o(i){var u,f,e,o,s,h,r;return r=(t-n)/(t+n),f=(t+n)/2*(1+Math.pow(r,2)/4+Math.pow(r,4)/64),u=i/f,e=3*r/2+-27*Math.pow(r,3)/32+269*Math.pow(r,5)/512,o=21*Math.pow(r,2)/16+-55*Math.pow(r,4)/32,s=151*Math.pow(r,3)/96+-417*Math.pow(r,5)/128,h=1097*Math.pow(r,4)/512,u+e*Math.sin(2*u)+o*Math.sin(4*u)+s*Math.sin(6*u)+h*Math.sin(8*u)}function s(i,r,u,f){var h,s,a,l,o,c,v,y,p,w,b,k,d;a=(Math.pow(t,2)-Math.pow(n,2))/Math.pow(n,2);s=a*Math.pow(Math.cos(i),2);h=Math.pow(t,2)/(n*Math.sqrt(1+s));l=Math.tan(i);o=l*l;d=o*o*o-Math.pow(l,6);c=r-u;v=1-o+s;y=5-o+9*s+4*s*s;p=5-18*o+o*o+14*s-58*o*s;w=61-58*o+o*o+270*s-330*o*s;b=61-479*o+179*o*o-o*o*o;k=1385-3111*o+543*o*o-o*o*o;f[0]=h*Math.cos(i)*c+h/6*Math.pow(Math.cos(i),3)*v*Math.pow(c,3)+h/120*Math.pow(Math.cos(i),5)*p*Math.pow(c,5)+h/5040*Math.pow(Math.cos(i),7)*b*Math.pow(c,7);f[1]=e(i)+l/2*h*Math.pow(Math.cos(i),2)*Math.pow(c,2)+l/24*h*Math.pow(Math.cos(i),4)*y*Math.pow(c,4)+l/720*h*Math.pow(Math.cos(i),6)*w*Math.pow(c,6)+l/40320*h*Math.pow(Math.cos(i),8)*k*Math.pow(c,8);return}function h(i,r,u,f){var y,c,e,h,p,l,s,a,v,w,b,k,d,g,nt,tt,it,rt,ut,ft,et,ot,st,ht;y=o(r);p=(Math.pow(t,2)-Math.pow(n,2))/Math.pow(n,2);v=Math.cos(y);h=p*Math.pow(v,2);c=Math.pow(t,2)/(n*Math.sqrt(1+h));e=c;l=Math.tan(y);s=l*l;a=s*s;w=1/(e*v);e*=c;b=l/(2*e);e*=c;k=1/(6*e*v);e*=c;d=l/(24*e);e*=c;g=1/(120*e*v);e*=c;nt=l/(720*e);e*=c;tt=1/(5040*e*v);e*=c;it=l/(40320*e);rt=-1-h;ut=-1-2*s-h;ft=5+3*s+6*h-6*s*h-3*h*h-9*s*h*h;et=5+28*s+24*a+6*h+8*s*h;ot=-61-90*s-45*a-107*h+162*s*h;st=-61-662*s-1320*a-720*a*s;ht=1385+3633*s+4095*a+1575*a*s;f[0]=y+b*rt*i*i+d*ft*Math.pow(i,4)+nt*ot*Math.pow(i,6)+it*ht*Math.pow(i,8);f[1]=u+w*i+k*ut*Math.pow(i,3)+g*et*Math.pow(i,5)+tt*st*Math.pow(i,7);return}var r=3.14159265358979,t=6378137,n=6356752.314,i=.9996,c=function(n,t,r,f){return s(n,t,u(r),f),f[0]=f[0]*i+5e5,f[1]=f[1]*i,f[1]<0&&(f[1]=f[1]+1e7),r},l=function(n,t,r,f,e){var o;n-=5e5;n/=i;t/=i;o=u(r);h(n,t,o,e);return},f=function(n){return n/180*r},a=function(n){return n/r*180};return{UTMXYToLatLon:l,LatLonToUTMXY:c,DegToRad:f,RadToDeg:a}}(),TRIM=function(n,t,i){"use strict";function v(i){n("#mapPopUpDepartures table").html("");n.get(t.serviceHostUrl+"/nextripv2/"+i).done(function(t){var e=n('<caption class="sr-only">Departures table<\/caption>'),o=n('<th class="route">Route<\/th>'),s=n('<th class="destination">Destination<\/th>'),h=n('<th class="departs text-right">Departs<\/th>'),i,f,r,u;n(".departures-table").append(e).append("<thead/>").append("<tbody/>");n(".departures-table thead").append("<tr/>");n(".departures-table thead tr").append(o).append(s).append(h);t.departures.length?(i=0,t.departures.forEach(function(n){n.schedule_relationship==="Skipped"&&i++}),i===t.departures.length?n('<tr><td class="stop-closed-msg"><span class="h3">Stop closed<\/span><\/td><\/tr>').appendTo(".departures-table"):(f=t.departures.sort(function(n,t){return n=new Date(n.departure_time),t=new Date(t.departure_time),n<t?-1:n>t?1:0}),f.forEach(function(t){var u=t.hasOwnProperty("terminal")?t.terminal:"",r=n("<tr/>",{"class":"departure"}),i;r.append(n("<td/>",{"class":"route-number mr-2"}).text(t.route_short_name+u));r.append(n("<td/>",{"class":"route-name"}).text(t.description));i=n("<td/>",{"class":"depart-time ml-auto"});t.actual===!0&&i.append(n("<img/>",{"class":"icon blink mr-1",src:"/img/svg/broadcast-blue.svg"}));t.schedule_relationship.length!==null?t.schedule_relationship=="Canceled"||t.schedule_relationship=="Skipped"?i.append('<span class="red">Canceled<br/>'+t.departure_text+"<\/span>"):i.append("<span>"+t.departure_text+"<\/span>"):i.append("<span>"+t.departure_text+"<\/span>");i.appendTo(r);r.appendTo(n(".departures-table"))}))):(r=!1,t.alerts.forEach(function(n){n.stop_closed===!0&&(r=!0)}),r?n('<tr><td class="stop-closed-msg"><span class="h3">Stop closed<\/span><\/td><\/tr>').appendTo(".departures-table"):(u=n("<tr/>",{"class":"departure"}),u.append(n("<td/>",{"class":"no-departures-msg",colspan:3}).text("No departures available at this time.")),u.appendTo(n(".departures-table"))))}).fail(function(){console.warn("Nextrip failed for stop "+i)})}var r=null,u=null,o="https://mtgis.metc.state.mn.us/transit/rest/services/transit/TRIM/MapServer",p=function(n){var t=n.toString();return t?/\S/.test(t):!1},f=function(n){return p(n)?!isNaN(+n):!1},d=function(n){require(["esri/geometry/Extent"],function(t){if(n){var u,i=n.split(",");i.length===4?f(i[0])&&f(i[1])&&f(i[2])&&f(i[3])&&(u=new t({xmin:parseFloat(i[1]),ymin:parseFloat(i[0]),xmax:parseFloat(i[3]),ymax:parseFloat(i[2]),spatialReference:r.spatialReference}),r.setExtent(u,!0)):i.length===2&&f(i[0])&&f(i[1])&&(u=new t({xmin:parseFloat(i[1]),ymin:parseFloat(i[0]),xmax:parseFloat(i[1])+2,ymax:parseFloat(i[0])+2,spatialReference:r.spatialReference}),r.setExtent(u,!0))}})},l=function(){u.locate()},e=function(n,t,i){var u=typeof i!="undefined"?i:null;r.graphics.clear();require(["esri/graphic","esri/geometry/Point","esri/symbols/PictureMarkerSymbol"],function(i,f,e){var h=new f(n,t),o=new i,s;o.setGeometry(h);s=new e("/img/svg/map-icons/pin-red.svg",20,24);s.setOffset(0,15);o.setSymbol(s);r.graphics.add(o);r.centerAt(h).then(function(){u&&r.setLevel(u)})})},a=function(n,t){var i=r.getLayer(n);i?i.visible?i.hide():(i.show(),t&&r.setZoom(t)):console.warn("ToggleLayer: "+n+" not found.")},s=function(n){var f=r.getLayer("routeStops"),u,t,i,e;if(f){if(u=[],t="",n)for(i=0,e=n.length;i<e;i++)i>0&&(t+=" or "),t+="ROUTES LIKE '% "+n[i]+" %' or ",t+="ROUTES LIKE '"+n[i]+" %' or ",t+="ROUTES LIKE '% "+n[i]+"' or ",t+="ROUTES = '"+n[i]+"'";else t="1=0";u[0]=t;f.setLayerDefinitions(u)}},h=function(t,i){var e,o,u,f,s;if(i=typeof i!="undefined"?i:!1,e=r.getLayer("routes"),e){if(o=[],o[4]="1=0",t){for(t=t.filter(function(n){return n!=="906"}),u="ROUTENUMBER in (",f=0,s=t.length;f<s;f++)f>0&&(u+=","),u+=t[f];u+=")";o[4]=u}e.setLayerDefinitions(o);t&&i&&n.ajax({type:"get",url:e.url+"/4/query",data:{where:u,returnGeometry:!0,outFields:"ROUTENUMBER",f:"json"},dataType:"json"}).done(function(n){n.features.length>0&&require(["esri/geometry/Polyline"],function(t){for(var f,u,i=0,e=n.features.length;i<e;i++)f=new t({paths:n.features[i].geometry.paths,spatialReference:n.spatialReference}),u=i===0?f.getExtent():u.union(f.getExtent());r.setExtent(u,!0)})}).fail(function(n){console.warn("Routes fatal error fetching polylines: "+n.Message)})}},w=function(t){require(["esri/graphic","esri/Color","esri/geometry/Point","esri/geometry/Polyline","esri/geometry/webMercatorUtils","esri/symbols/PictureMarkerSymbol","esri/symbols/CartographicLineSymbol","esri/symbols/SimpleMarkerSymbol","esri/symbols/SimpleLineSymbol","esri/symbols/TextSymbol","esri/symbols/Font"],function(i,u,f,e,o,s,h,c,a,v,y){var p=JSON.parse(sessionStorage.getItem("routeColorMap"))||{},nt=function(n,t,e){var b=n.split(","),w=[],g,h,l;CoordinateConversion.UTMXYToLatLon(parseFloat(b[1]),parseFloat(b[0]),15,!1,w);var nt=CoordinateConversion.RadToDeg(w[1]),tt=CoordinateConversion.RadToDeg(w[0]),k=new f(nt,tt),it=new i(k,new c(c.STYLE_CIRCLE,20,new a(a.STYLE_SOLID,e,3),e));r.getLayer("tripStop").add(it);var d={888:"NST",901:"BLU",902:"GRN",903:"RED",904:"ORNG",905:"GOLD",921:"A",922:"B",923:"C",924:"D",925:"E",991:"BLU",992:"GRN"},o=new v,s=new y;s.setFamily("proxima-nova");s.setWeight(y.WEIGHT_BOLD);g=t.toString();t in d?(t>920&&t<929?s.setSize(12):s.setSize(8),o.setText(d[t])):t===887?(o.setText("NSL"),s.setSize(8)):(t>9?s.setSize(10):s.setSize(12),o.setText(g));h=parseInt(t,10);h>=2&&h<=887?p.hasOwnProperty(h)&&[1,3].includes(p[h])?o.setColor(new u([0,0,0,255])):o.setColor(new u("white")):h===905?o.setColor(new u([0,0,0,255])):o.setColor("white");o.setOffset(0,-3);o.setFont(s);l=new i;l.setGeometry(k);l.setSymbol(o);r.getLayer("tripStop").add(l)},b=function(n,t){var c=n.point.split(","),e=[],l,a,v;CoordinateConversion.UTMXYToLatLon(parseFloat(c[1]),parseFloat(c[0]),15,!1,e);var y=CoordinateConversion.RadToDeg(e[1]),p=CoordinateConversion.RadToDeg(e[0]),o=new f(y,p),h={StopID:n.ID,LocationName:n.label},u;t==="Board"?(l=new s("/img/svg/map-icons/circle-gray-outline-green.svg",24,24),u=new i(o,l,h)):t==="Exit"?(a=new s("/img/svg/map-icons/circle-gray-outline-red.svg",24,24),u=new i(o,a,h)):t==="Transfer"&&(v=new s("/img/svg/map-icons/circle-gray-outline-white.svg",20,20),u=new i(o,v,h));r.getLayer("tripStop").add(u)},d=function(n,t){var i=t.geometry.getExtent();return n?(i.xmin<n.xmin&&(n.xmin=i.xmin),i.ymin<n.ymin&&(n.ymin=i.ymin),i.xmax>n.xmax&&(n.xmax=i.xmax),i.ymax>n.ymax&&(n.ymax=i.ymax)):n=i,n};r.getLayer("trip").clear();r.getLayer("tripStop").clear();var w=null,g=0,k=t.legs.length-1,tt=t.walk[0].hasOwnProperty("points")?!0:!1,it=t.walk[k+1].hasOwnProperty("points")?!0:!1;n.ajax({url:"https://mtgis.metc.state.mn.us/transit/rest/services/transit/TRIM/MapServer/4?f=pjson",method:"GET",dataType:"json"}).then(function(n){var a=8,s=n.drawingInfo.renderer.uniqueValueInfos,f="",c=[[244,50,130,255],[0,227,250,255],[170,0,204,255],[110,207,0,255],[0,100,255,255]],v=0,y=JSON.parse(sessionStorage.getItem("tripJSON")),rt=y.itin.map(function(n){return n.legs.map(function(n){return n.routeColor="rgba(".concat(c[v].join(","),")"),n})});rt.forEach(function(n){n.forEach(function(n){var l=n.service.route;t.legs.forEach(function(n,t){var st,ht,l,v,y,rt,ut,ft,et,ot,lt;(t!==g||t===g&&tt)&&(st={ID:"Transfer",label:n.firststop.description,point:n.firststop.point},b(st,"Transfer"));(t!==k||t===k&&it)&&(ht={ID:"Transfer",label:n.laststop.description,point:n.laststop.point},b(ht,"Transfer"));switch(n.route){case 901:case 991:case 888:l=s.find(function(n){return n.value==="901"||n.value==="991"||n.value==="888"});l&&(f=new u(l.symbol.color));break;case 902:case 992:v=s.find(function(n){return n.value==="902"||n.value==="992"});(v||greenBus)&&(f=new u(v.symbol.color));break;case 903:y=s.find(function(n){return n.value==="903"});y&&(f=new u(y.symbol.color));break;case 904:rt=s.find(function(n){return n.value==="904"});rt&&(f=new u(rt.symbol.color));break;case 905:ut=s.find(function(n){return n.value==="905"});ut&&(f=new u(ut.symbol.color));break;case 921:case 922:case 923:case 924:ft=s.find(function(n){return n.value==="921"||n.value==="922"||n.value==="923"||n.value==="924"});ft&&(f=new u(ft.symbol.color));break;default:n.route>=2&&n.route<=887?p.hasOwnProperty(n.route)&&(p===5&&(p=0),f=new u(c[p[n.route]])):f="0"}et=[];n.points.forEach(function(n){var i=n.split(","),t=[];CoordinateConversion.UTMXYToLatLon(parseFloat(i[1]),parseFloat(i[0]),15,!1,t);var r=CoordinateConversion.RadToDeg(t[1]),u=CoordinateConversion.RadToDeg(t[0]),f=o.lngLatToXY(r,u);et.push(f)});ot=new e(r.spatialReference);ot.addPath(et);var at=new h(h.STYLE_SOLID,f,a,h.CAP_ROUND,h.JOIN_ROUND),ct=new i(ot,at,{},null);r.getLayer("trip").add(ct);w=d(w,ct);lt=n.points[Math.round(n.points.length/2.5)];nt(lt,n.route,f)});t.walk.forEach(function(n){var t=[],f;if(n.hasOwnProperty("points")&&(n.points.forEach(function(n){var r=n.split(","),i=[];CoordinateConversion.UTMXYToLatLon(parseFloat(r[1]),parseFloat(r[0]),15,!1,i);var u=CoordinateConversion.RadToDeg(i[1]),f=CoordinateConversion.RadToDeg(i[0]),e=o.lngLatToXY(u,f);t.push(e)}),t.length>0)){f=new e(r.spatialReference);f.addPath(t);var c=new h(h.STYLE_SHORTDOT,new u([0,180,210,.77]),8,h.CAP_ROUND,h.JOIN_ROUND),s=new i(f,c,{},null);r.getLayer("trip").add(s);w=d(w,s)}})})});b({ID:"Origin",label:t.from.label,point:t.from.point},"Board");b({ID:"Destination",label:t.to.label,point:t.to.point},"Exit");t.zoom?r.setExtent(w,!0):l()}).catch(function(n){console.error("There was a problem fetching the data: ".concat(n))})})},c=function c(t){u=null;var f=null;return n.Deferred(function(e){var l=i.getElementById(t),h,s;l||(setTimeout(c,1e3),console.error("Element with ID ".concat(t," not found.")),e.reject("Element with ID ".concat(t," not found.")));h=l.getAttribute("maptype");s=h!==null?h:"full";require(["esri/map","esri/basemaps","esri/graphic","esri/Color","esri/SpatialReference","esri/geometry/Extent","esri/layers/ArcGISDynamicMapServiceLayer","esri/layers/GraphicsLayer","esri/tasks/query","esri/tasks/QueryTask","esri/symbols/PictureMarkerSymbol","esri/symbols/SimpleMarkerSymbol","esri/symbols/SimpleFillSymbol","esri/dijit/Scalebar","esri/dijit/Popup","esri/dijit/LocateButton","dojo/on","dojo/domReady!"],function(h,c,l,a,y,p,w,b,k,d,g,nt,tt,it,rt,ut,ft){var st=null,pt=function(){var n=new k,t=new d("https://mtgis.metc.state.mn.us/transit/rest/services/transit/TRIM/MapServer/4");n.returnGeometry=!1;n.where="1=1";n.outFields=["ROUTENUM","ROUTEDESCRIPTION"];t.execute(n);t.on("error",function(n){console.warn("createRouteList error");console.dir(n)});t.on("complete",function(n){var i,r,t;if(n.featureSet.features.length>0)for(st={},i=0,r=n.featureSet.features.length;i<r;i++)t=n.featureSet.features[i].attributes,st[t.ROUTENUM]=t.ROUTENUM>887?t.ROUTEDESCRIPTION:t.ROUTENUM.toString()+" "+t.ROUTEDESCRIPTION})},wt=function(n){var e="",r=n.split(" "),u,h,o,f,c,t,s,i;if(r.length>0){for(u=0,h=r.length;u<h;u++)r[u]=parseInt(r[u]);for(o=r.sort(function(n,t){return n-t}),f=0,c=o.length;f<c;f++)t=o[f],s="",st&&(s=st[t]),i='<div class="route-service"><input id="cb'+t+'"',i+='dojotype="dijit.form.RadioButton"',i+='onclick="javascript:TRIM.drawRoutes(['+t+"]);TRIM.drawRouteStops(["+t+']);return true;"',i+='name="optRoute" type="radio" />',i+='<label for="cb'+t+'">'+s+"<\/label><\/div>",e+=i}else e='<span style="font-size:larger">No routes service this stop.<\/span>';return e},bt=function(t){var i=new k,e=new d("https://mtgis.metc.state.mn.us/transit/rest/services/transit/TRIM/MapServer/1"),o=r.extent.getWidth()/r.width,u=20*o;i.returnGeometry=!0;i.spatialRelationship=k.SPATIAL_REL_INTERSECTS;i.where="NROUTES <> 0";i.outFields=["SITEID","SITE_ON","SITE_AT","ROUTES","SYMBOL","NROUTES","description"];i.geometry=new p(t.mapPoint.x-u,t.mapPoint.y-u,t.mapPoint.x+u,t.mapPoint.y+u,r.spatialReference);r.infoWindow.hide();r.getLayer("stops").clear();e.execute(i);e.on("error",function(n){console.warn("Bus Stop Query Error: "+n)});e.on("complete",function(i){var s,u,e,o,h;i.featureSet.features.length===0||(s=i.featureSet.features[0],u=s.attributes,r.infoWindow.setTitle('<h4 class="mb-0">'+u.description+"<\/h4>Stop Number: "+u.siteid),r.infoWindow.show(t.screenPoint,r.getInfoWindowAnchor(t.screenPoint)),e=new l,e.setGeometry(s.geometry),u.Symbol===0?o=new g("/img/svg/map-icons/badge-blue-bus.svg",25,25):u.Symbol===1?o=new g("/img/svg/map-icons/badge-blue-lrt.svg",24,24):u.Symbol===2&&(o=new g("/img/svg/map-icons/badge-blue-train.svg",24,24)),e.setSymbol(o),r.getLayer("stops").add(e),h=u.site_on.trim(),h+=u.site_at.trim()!=="null"?" & "+u.site_at.trim():"",n("#mapPopUpRoutes").html(wt(u.ROUTES)),v(u.siteid),clearInterval(f),f=setInterval(function(){v(u.siteid)},3e4),t.screenX>760&&r.centerAt(t.mapPoint))})},ht,ct,et,ot,vt,lt;pt();var kt=new y({wkid:3857}),ii=new p({xmin:-10385405,ymin:5615111,xmax:-10379460,ymax:5619877,spatialReference:kt}),dt=i.createElement("div"),yt=new rt({zoomFactor:4,marginLeft:20,marginRight:20,anchor:"auto",pagingControls:!1,pagingInfo:!1,markerSymbol:new nt("circle",32,null,new a([0,0,0,.25])),highlight:!0},dt);yt.startup();c.metCouncilWebMercator={baseMapLayers:[{url:"https://mtgis.metc.state.mn.us/arcgis/rest/services/BaseLayer/BasemapWM/MapServer"}],title:"MetCouncil"};c.transitVector={title:"TransitVector",baseMapLayers:[{url:"/js/basemapStylev3.min.json",type:"VectorTile"}]};r=new h(t,{autoResize:!0,logo:!1,showAttribution:!1,infoWindow:yt,sliderPosition:"bottom-right",basemap:"transitVector",maxZoom:18,minZoom:9,center:[-93.27,44.975],zoom:14});r.on("load",function(){var t=new b({id:"overlayLayer"}),f=new a([227,227,224,.3]),e=(new tt).setColor(f),o=new l({geometry:r.extent,symbol:e}),h;t.add(o);r.addLayer(t);u=new ut({map:r,scale:1e4},"trimLocate");u.startup();u.on("locate",function(){ft.once(r,"click",function(){u.clear()})});h=new it({map:r,attachTo:"bottom-left",scalebarUnit:"english"});r.disableScrollWheel();r.disableDoubleClickZoom();s==="route"&&(r.disablePan(),r.disableMapNavigation(),r.hideZoomSlider(),n("#trimLocate").hide(),i.querySelector("#trimLocate").style.display="none");i.querySelector("#trimPopUp")&&(r.infoWindow.setContent(n("#trimPopUp")[0]),i.querySelector("#trimPopUp").style.display="block")});r.on("click",function(n){s==="full"&&(r.infoWindow.isShowing&&r.infoWindow.hide(),bt(n))});r.on("resize",function(){});r.on("update-start",function(){i.querySelector(".mapLoading").style.display="block"});r.on("update-end",function(){i.querySelector(".mapLoading").style.display="none"});r.on("layers-add-result",function(){s==="trip"&&(i.querySelector(".mapLoading").style.display="none");e.resolve()});r.on("layer-add-result",function(n){n.error&&console.error("Layer add "+n.error+" for "+n.layer.url)});ht=new w(o,{id:"allStops",opacity:.6});ht.setImageFormat("svg");ht.setVisibleLayers([1]);ct=new w(o,{id:"parkAndRides",opacity:1,visible:!1});ct.setImageFormat("svg");ct.setVisibleLayers([8]);et=new w(o,{id:"routeStops",opacity:1});et.setImageFormat("svg");et.setVisibleLayers([0]);et.setLayerDefinitions(["1=0"]);ot=new w(o,{id:"routes",opacity:.7});ot.setImageFormat("svg");ot.setVisibleLayers([4]);vt=[];vt[4]="1=0";ot.setLayerDefinitions(vt);lt=new w(o,{id:"goTo",opacity:1,visible:!1});lt.setImageFormat("svg");lt.setVisibleLayers([2]);var gt=new b({id:"trip",opacity:.75}),ni=new b({id:"tripStop"}),ti=new b({id:"stops"}),at=[];s==="full"?at=[ht,ct,lt,ot,et,ti]:s==="route"?at=[ot,et]:s==="trip"&&(at=[gt,ni]);r.addLayers(at);e.resolve()})}).promise()},y=function(t){var i="siteid = "+t;return n.Deferred(function(r){n.ajax({type:"get",url:"https://mtgis.metc.state.mn.us/transit/rest/services/transit/TRIM/MapServer/1/query",data:{where:i,returnGeometry:!0,outFields:"site_on, site_at, ROUTES, ROUTEDIRS",outSR:4326,f:"json"},dataType:"json"}).done(function(n){if(n.error)console.warn("Stop lookup failed"),r.reject();else if(n.features.length>0){var i=n.features[0],f=i.geometry.x,e=i.geometry.y,u=i.attributes.site_on.trim();u+=i.attributes.site_at.trim()!=="null"?" & "+i.attributes.site_at.trim():"";r.resolve(f,e,u)}else console.warn("stops query returned no results: "+t),r.reject()}).fail(function(){console.warn("Stop service failed");r.reject()})}).promise()},b=function(i,r,u,f,o,l){var p=typeof l!="undefined"?l:null,v=n(t).height();v>1e3?n(".map").css({height:v-500}):v>500&&n(".map").css({height:v-220});c(i).then(function(){r?u?(h([r],!1),s([r]),y(u).then(function(t,i,r){var f="Stop "+u+" / "+r;n("#page-title-text").html(f);e(t,i,17)}).fail(function(){console.warn("Requested stop "+u+" not found.")})):(h([r],!0),s([r])):u?y(u).then(function(t,i,r){var f="Stop "+u+" / "+r;n("#page-title-text").html(f);e(t,i,17)}).fail(function(){console.warn("Requested stop "+u+" not found.")}):f&&o&&(p==="gt"?(a("goTo"),e(parseFloat(f),parseFloat(o),17)):p==="pr"?e(parseFloat(f),parseFloat(o),16):e(parseFloat(f),parseFloat(o),16))})},k=function(){u=null;r=null};return{fullPageSetup:b,centerMarkerAtPoint:e,drawTrip:w,drawRouteStops:s,drawRoutes:h,geoLocate:l,toggleLayer:a,destroy:k,init:c}}(jQuery,window,document),BOM=function(n,t,i){"use strict";var r,h=null,c=!1,f=null,w=null,v=null,et="https://mtgis.metc.state.mn.us/transit/rest/services/transit/BOM_Points/MapServer/0",d="https://mtgis.metc.state.mn.us/transit/rest/services/transit/TRIM/MapServer",b=4,l=!0,g=7500,y=0,o=80,nt="Click or tap",e,u=!1,ot=function(){e.locate()},st=function(){return l},ht=function(n){g=n},ct=function(n){o=n===0?null:n},lt=function(){r.getLayer("Markers").clear()},at=function(n){r.getLayer("Markers").clear();require(["esri/graphic","esri/symbols/PictureMarkerSymbol"],function(t,i){var u=new t,f;u.setGeometry(n);f=new i("/img/svg/map-icons/pin-red.svg",20,24);f.setOffset(0,10);u.setSymbol(f);r.getLayer("Markers").add(u)})},tt=function(n,t,i,u){require(["esri/graphic","esri/symbols/PictureMarkerSymbol","esri/symbols/TextSymbol","esri/symbols/Font","esri/Color"],function(f,e,o,s,h){var v,c,l,a,p;if(n){v=new f;v.setGeometry(n);c=new e("../../../img/svg/map-icons/circle-bus-up.svg",65,65);switch(t){case"888":switch(u){case"NB":c=new e("../../../img/svg/map-icons/circle-ns-up.svg",65,65);break;case"SB":c=new e("../../../img/svg/map-icons/circle-ns-down.svg",65,65)}break;case"901":switch(u){case"NB":c=new e("../../../img/svg/map-icons/circle-blue-lrt-up.svg",65,65);break;case"SB":c=new e("../../../img/svg/map-icons/circle-blue-lrt-down.svg",65,65)}break;case"902":switch(u){case"WB":c=new e("../../../img/svg/map-icons/circle-green-lrt-left.svg",65,65);break;case"EB":c=new e("../../../img/svg/map-icons/circle-green-lrt-right.svg",65,65)}break;default:switch(u){case"WB":c=new e("../../../img/svg/map-icons/circle-bus-left.svg",65,65);break;case"EB":c=new e("../../../img/svg/map-icons/circle-bus-right.svg",65,65);break;case"SB":c=new e("../../../img/svg/map-icons/circle-bus-down.svg",65,65)}}c.setOffset(0,20);v.setSymbol(c);r.getLayer("BusesOnMap").add(v);l=new o;a=new s;a.setFamily("proxima-nova-condensed");a.setWeight(s.WEIGHT_BOLD);var w={888:"",901:"BLU",991:"BLU",902:"GRN",992:"GRN",903:"RED",904:"ORNG",905:"GOLD"},b={921:"A",922:"B",923:"C",924:"D",925:"E"},y=parseInt(t);y in w?(a.setSize(10),l.setText(w[y])):y in b?(a.setSize(13),l.setText(b[y])):(a.setSize(13),l.setText(t+i),/^\d{3}[A-Z]$/i.test(t+i)&&a.setSize(10));t==="888"||t==="901"||t==="902"?(l.setOffset(0,24.5),a.setSize(10)):l.setOffset(0,28);l.setColor(new h([98,100,98,1]));l.setFont(a);p=new f;p.setGeometry(n);p.setSymbol(l);r.getLayer("BusesOnMap").add(p)}})},vt=function(i,e){var s,o,y,l,p,a,b;for(u&&console.log("+++   D R A W     B U S E S    ++ Zoom: "+i),s=[],s=c?[0]:f?f:w,o=[],y=[],l=0,p=s.length;l<p;l++)a=s[l],b=t.serviceHostUrl+"/nextripv2/vehicles/"+a,y.push(n.ajax({type:"get",cache:!1,url:b,dataType:"json"}).done(function(t,i,r){var u=r.getResponseHeader("content-type")||"";u.indexOf("html")>-1?console.warn("Location service failed for "+a+": "+i):n.merge(o,t)}).fail(function(){console.warn("Location service failed for route "+a)}));n.when.apply(n,y).then(function(){var a,f,s,t,l,y,p,w,b;if(r.getLayer("BusesOnMap").clear(),a=0,f=0,o.length>0){n.each(o,function(){var n,t=this.hasOwnProperty("terminal")?this.terminal:"",i=this.hasOwnProperty("direction")?this.direction:"NB";v?(v.indexOf(this.route_id+t)>-1||c)&&(n=rt(this.latitude,this.longitude),tt(n,this.route_id,t,i,this.location_time,this.bearing,this.speed,this.trip_id),a++):(n=rt(this.latitude,this.longitude),tt(n,this.route_id,t,i,this.location_time,this.bearing,this.speed,this.trip_id),a++)});u&&console.log("Total drawn: "+a);s=r.extent;t=0;do l=0,t>0&&(l=h.resolution*Math.pow(2,t-1)),y=l*r.width/2,p=l*r.height/2,u&&console.log(t+" xD = "+y+" yD = "+p+" z = "+l),n.each(o,function(){var n=wt(this.latitude,this.longitude);n.x>s.xmin-y&&n.x<s.xmax+y&&n.y>s.ymin-p&&n.y<s.ymax+p&&f++}),u&&console.log("Level "+(h.level-t)+" count "+f+" of "+o.length),f>0&&t>0&&i&&r.setLevel(h.level-t).then(),t++;while(f===0&&h.level-t>=r.getMinZoom())}w=new Date;b=("0"+w.getHours()).slice(-2)+":"+("0"+w.getMinutes()).slice(-2)+":"+("0"+w.getSeconds()).slice(-2);n("#bomticker").html("Updated "+b);typeof e=="function"&&e(f,o.length)}).fail(function(){console.warn("DrawBuses call failed");typeof e=="function"&&e(null)})},s=function(t,i){n("#bombanner").html(t);n(".mapbanner").css("display","block");i==="fade"&&n(".mapbanner").delay(5e3).fadeOut(3e3)},yt=function(){n(".mapbanner").css("display","none")},p=function(){_TIMECLOCK&&(clearInterval(_TIMECLOCK),_TIMECLOCK=null);y=0;l=!1},it=function(n){yt();l=!0;o&&(y++,y>o&&(p(),s("Real-time locations are paused.<\/br>"+nt+" the map to resume.")));var t=typeof n!="undefined"?n:!1;vt(t,function(n,t){u&&console.log("++ Buses Showing = "+n+" Total = "+t);n===null?(s("Real-time locations unavailable at this time."),o&&(p(),setTimeout(function(){s("Real-time locations are paused.<\/br>"+nt+" the map to resume.")},1e4))):t===0&&o&&(s("Real-time data are not available<\/br>or there is no service."),p())});u&&console.log("Ticks: "+y)},a=function(n){it(n);_TIMECLOCK=setInterval(function(){l?it():(clearInterval(_TIMECLOCK),_TIMECLOCK=null)},g)},pt=function(){n.each(r.layerIds,function(n,t){var i=r.getLayer(t),u=i.visible?" visible":" hidden";console.log("Layer: "+i.id+", "+u+", opacity: "+i.opacity+" "+i.url)});n.each(r.graphicsLayerIds,function(n,t){var i=r.getLayer(t),u=i.visible?" visible":" hidden";console.log("Graphics Layer: "+i.id+", "+u+", opacity: "+i.opacity+" "+i.url)})},ni=function(n){var t=null,i;return n&&n.indexOf("(")>-1&&(i=n.substring(n.indexOf("(")+1,n.indexOf(")")),t=Date.now()-parseFloat(i)),t/1e3},wt=function(n,t){var i=null;return require(["esri/geometry/Point","esri/geometry/webMercatorUtils"],function(u,f){i=new u(f.lngLatToXY(t,n),r.spatialReference)}),i},rt=function(n,t){var i=null;return require(["esri/geometry/Point"],function(r){i=new r(parseFloat(t),parseFloat(n))}),i},bt=function(n,t){var i=null;return require(["esri/geometry/Point"],function(r){var u=[0,0];CoordinateConversion.UTMXYToLatLon(n,t,15,!1,u);i=new r(CoordinateConversion.RadToDeg(parseFloat(u[1])),CoordinateConversion.RadToDeg(parseFloat(u[0])))}),i},ut=function(t){return n.Deferred(function(n){var f=i.getElementById(t).getAttribute("maptype"),o=f!==null?f:"BOM";require(["esri/map","esri/config","esri/basemaps","esri/dijit/Scalebar","esri/dijit/LocateButton","esri/graphic","esri/layers/GraphicsLayer","esri/layers/ArcGISDynamicMapServiceLayer","esri/symbols/SimpleFillSymbol","esri/symbols/SimpleLineSymbol","esri/Color","dojo/on","dojo/domReady!"],function(i,f,o,c,v,y,p,w,k,g,nt){var tt,it;f.defaults.map.panRate=1;f.defaults.map.panDuration=1;o.metCouncilWebMercator={baseMapLayers:[{url:"https://mtgis.metc.state.mn.us/arcgis/rest/services/BaseLayer/BasemapWM/MapServer"}],title:"MetCouncil"};o.transitVector={title:"TransitVector",baseMapLayers:[{url:"/js/basemapStylev3.min.json",type:"VectorTile"}]};r=new i(t,{logo:!1,showAttribution:!1,sliderPosition:"bottom-right",basemap:"transitVector",maxZoom:18,minZoom:9,center:[-93.27,44.975],zoom:14});r.disableDoubleClickZoom();r.on("load",function(){e=new v({map:r,scale:1e4},"bomlocate");e.startup();e.clearOnTrackingStop=!0;e.on("locate",function(n){n.error&&s("We're unable to determine your location. Check your browser permissions.","fade")});var n=new c({map:r,attachTo:"bottom-left",scalebarUnit:"english"})});r.on("layer-add-result",function(n){n.error&&console.error("Layer load failed -  "+n.error+" for "+n.layer.url)});r.on("layers-add-result",function(){u&&pt();n.resolve()});r.on("extent-change",function(n){u&&console.log("extent-change fired");h=n.lod});r.on("click",function(){u&&console.log("map clicked");l===!1&&a(!0)});tt=[];tt.push(new p({id:"Markers"}));it=new w(d,{id:"Routes",opacity:.66,visible:!1});it.setVisibleLayers([b]);it.setImageFormat("svg");tt.push(it);tt.push(new p({id:"BusesOnMap"}));var ut=new p({id:"OverlayLayer"}),ft=new k(k.STYLE_SOLID,new g(g.STYLE_SOLID,new nt([227,227,224,.3]),1),new nt([227,227,224,.3])),rt=new y(r.extent,ft);ut.add(rt);r.addLayer(ut);r.on("extent-change",function(n){rt.setGeometry(n.extent)});r.on("resize",function(){rt.setGeometry(r.extent)});r.addLayers(tt)})}).promise()},kt=function(t){var i="site_id = "+t;return u&&console.log("ShowStop "+i),n.Deferred(function(r){n.ajax({type:"get",url:et+"/query",data:{where:i,returnGeometry:!0,outFields:"site_id, site_on, site_at, ROUTES, NROUTES, ROUTEDIRS, ROUTETERMDIRS",f:"json"},dataType:"json"}).done(function(i){var e=null,f,h,o,s;i.error?(console.warn("Stop lookup failed"),r.reject()):i.features.length>0?(u&&console.log("Stop Lookup succeeded"),f=i.features[0],e=bt(f.geometry.x,f.geometry.y),at(e),o=[],s=[],typeof f.attributes!="undefined"&&(s=f.attributes.ROUTES.split(" "),f.attributes.hasOwnProperty("ROUTETERMDIRS")&&f.attributes.ROUTETERMDIRS!==""&&(h=f.attributes.ROUTETERMDIRS.split(","),n.each(h,function(n,t){o.push(t.trim().substring(0,t.indexOf(":")))}))),r.resolve(s,o,e)):(console.warn("stops query returned no results: "+t),r.reject())}).fail(function(){console.warn("Stop service failed");r.reject()})}).promise()},k=function(t){var e=[],i,f;for(t=t.filter(function(n){return n!=="906"}),i="ROUTENUMBER in (",f=0;f<t.length;f++)f>0&&(i+=","),i+=t[f];return i+=")",u&&console.log("ShowRoute "+i),e[b]=i,r.getLayer("Routes").setLayerDefinitions(e),n.Deferred(function(t){n.ajax({type:"get",cache:!1,url:d+"/"+b+"/query",data:{where:i,returnGeometry:!0,outFields:"ROUTENUMBER",f:"json"},dataType:"json"}).then(function(n){if(n.error)console.warn("Route lookup error "+i),t.reject();else if(n.features.length>0){var u=null;require(["esri/geometry/Polyline"],function(t){for(var r,i=0,f=n.features.length;i<f;i++)r=new t({paths:n.features[i].geometry.paths,spatialReference:n.spatialReference}),u=i===0?r.getExtent():u.union(r.getExtent())});r.getLayer("Routes").setVisibility(!0);t.resolve(u)}else console.warn("route query returned no results: "+i),t.reject()},function(){console.warn("Route service failure");t.reject()})}).promise()},ft=function(t){e.clear();c=!1;f=null;w=null;v=null;t.routeID&&(t.routeID==="0"?c=!0:f=t.routeID.split(","));var i=null;t.stopID?n.when(kt(t.stopID)).then(function(n,t,r){r&&(i=r);w=n;v=t;f?k(f):k(n)}).then(function(){r.centerAndZoom(i,t.stopZoomLevel).then(function(){a(t.zoomToNearestBus)})}).fail(function(){console.warn("Requested stop "+t.stopID+" not found.")}):c?a(t.zoomToNearestBus):f?n.when(k(f)).then(function(n){n&&r.setExtent(n,!0).then(function(){a(t.zoomToNearestBus)})}).fail(function(){console.warn("Requested route "+t.routeID+" not found.")}):s("No stop or route requested.")},dt=function(i,r,u){var f=n(t).height(),e;f>1e3?n(".map").css({height:f-220}):f>600&&n(".map").css({height:f-160});e={stopID:r,routeID:u,zoomToNearestBus:!0,stopZoomLevel:16};ut(i).then(function(){ft(e)})},gt=function(){e.destroy();e=null;r.destroy();r=null};return{fullPageBOM:dt,geoLocate:ot,BOM_running:st,clearMarkerAtPoint:lt,drawBusesOnMap:a,startBusesOnMap:ft,stopBusesOnMap:p,setTimeInterval:ht,setTickStop:ct,destroy:gt,init:ut}}(jQuery,window,document);$(document).ready(function(){document.querySelector("#TRIMap")&&document.querySelector("#TRIMap").getAttribute("maptype")==="full"&&(AutocompleteAddress.init("interactiveMapSearch",!1,function(){var n=AutocompleteAddress.getChoice("interactiveMapSearch");TRIM.centerMarkerAtPoint(n.location.x,n.location.y,15)}),TRIM.init("TRIMap").then(function(){TRIM.geoLocate()}),document.querySelector("#stopsStationsMapLayer").addEventListener("change",function(){TRIM.toggleLayer("allStops",14)}),document.querySelector("#parkRideMapLayer").addEventListener("change",function(){TRIM.toggleLayer("parkAndRides",10)}))});TripPlan=function(n,t,i){function h(n){switch(n){case"1":return.25;case"2":return.5;case"3":return 1;default:return.5}}var f={},r={},u=!1,c=function(i){return n("#spinner").removeClass("d-none"),n.Deferred(function(r){var u,e,o,s;f={};u={description:i.fromLocation.address,point:{x:i.fromLocation.location.x,y:i.fromLocation.location.y},landmarkid:0};i.fromLocation.attributes.ATIS_ID.indexOf(";")>-1&&(u.landmarkid=parseInt(i.fromLocation.attributes.ATIS_ID.split(";")[1]));e={description:i.toLocation.address,point:{x:i.toLocation.location.x,y:i.toLocation.location.y},landmarkid:0};i.toLocation.attributes.ATIS_ID.indexOf(";")>-1&&(e.landmarkid=parseInt(i.toLocation.attributes.ATIS_ID.split(";")[1]));o=n("#isAccessible").is(":checked");s={origin:u,destination:e,arrdep:i.arrdep.substr(0,1),walkdist:parseFloat(i.walkdist),minimize:i.minimize.substr(0,1),accessible:o,xmode:i.xmode,datetime:moment(i.datetime).format("YYYY-MM-DDTHH:mm:ss.SSS")};n.post({contentType:"application/json",url:t.serviceHostUrl+"/tripplanner/plantrip",data:JSON.stringify(s),dataType:"json"}).done(function(n){n.error?r.reject({Message:n.error}):n.TrapEx?r.reject(n.TrapEx):(f=n,r.resolve())}).fail(function(n){var i="no response",t;n&&(t=n.responseJSON,i=t.status+" "+t.title+": "+t.detail);r.reject("TripPlan failed:"+i)})}).promise()},l=function(n){return n<0?'<span class="text-danger"><strong>Currently '+n*-1+'<abbr title="minutes"> min<\/abbr> late<\/strong><br><\/span>':" "},o=function(n){return moment(n,"hmm").format("h:mm A")},a=function(i,r,u,f){var e="Alerts"+i+r,s,o;if(!f||f.every(function(n){return n<=0}))return"";s=[];o=[];f.forEach(function(i,r){i>0&&s.push(n.get({url:t.serviceHostUrl+"/alerts/alert/"+i,dataType:"json"}).done(function(n){n&&o.push({ID:i,alertHTML:'<button type="button" class="btn btn-trigger text-left collapsed" data-toggle="collapse" data-target="#'.concat(e+r,'" aria-expanded="false"><span class="alert-title d-block">').concat(n.effect_detail.toLowerCase().replace(/_/g," "),'<\/span><span class="btn-text d-block">').concat(n.header_text.translation[0].text,'<\/span><\/button><div id="').concat(e+r,'" class="alert-content collapse" data-parent="#').concat(e,'"><p class="alert-description">').concat(n.description_text.translation[0].text,"<\/p><\/div>"),timestamp:n.last_modified_timestamp})}).fail(function(n,t,i){console.error("Failed to get alert data. Status:",t,"Error:",i)}))});n("#tripModal").on("shown.bs.modal",function(){n.when.apply(n,s).then(function(){o.sort(function(n,t){return t.timestamp-n.timestamp});var i=o.map(function(n){return n.alertHTML}).join(""),t=n("#".concat(e," .accordion"));t.length===0&&(n("#".concat(e)).append('<div class="accordion"><\/div>'),t=n("#".concat(e," .accordion")));t.html(i);n("#view".concat(e)).text("(view alerts)");n("#view".concat(e)).on("click",function(){n(this).text(function(n,t){return t==="(view alerts)"?"(hide alerts)":"(view alerts)"})})})});return'<button type="button" id="view'.concat(e,'" class="btn btn-link collapsed" data-toggle="collapse" data-target="#').concat(e,'" aria-expanded="false" aria-controls="').concat(e,'">(view alerts)<\/button><div id="').concat(e,'" class="collapse" aria-labelledby="view').concat(e,'"><div class="accordion"><\/div><\/div>')},v=function(i,r,u,f){n.post({contentType:"application/x-www-form-urlencoded",url:t.serviceHostUrl+"/tripplanner/moreinfo?moreInfo="+encodeURIComponent(r.itin[i].moreinfo),dataType:"json"}).done(function(n){if(n.error)console.warn("TripPlan moreinfo failed: "+n.error);else{var t={from:{label:r.input.origintext,point:r.input.originlat.toString()+","+r.input.originlong.toString()},to:{label:r.input.destinationtext,point:r.input.destinationlat.toString()+","+r.input.destinationlong.toString()},legs:n.itinresponse.legs,walk:n.legs,zoom:u,routeColorMap:f};TRIM.drawTrip(t)}}).fail(function(n){var t="no response";n&&(t=n.status+" "+n.statusText);console.warn("TripPlan moreinfo failed: "+t)})},s=function(t){var h=t.itin.length,s="Suggested trip",f;s+=h>1?"s":"";n("#trip-result-count").html(s);n(".tp-results").empty();f=0;n.ajax({url:"https://mtgis.metc.state.mn.us/transit/rest/services/transit/TRIM/MapServer/4?f=pjson",method:"GET",dataType:"json"}).then(function(){var s="",c,h;t.itin.forEach(function(i,h){var w=[],p=[],d=null,tt=null,v="",y="",ut,ft,it,g,rt,nt,b,k;for(i.legs.forEach(function(n){v=n.service.realtime.tripcanceled;var i=n.service.sign.split(" ")[0],u=n.service.route,t=n.service.routeTypeClass;d===null&&(d=o(n.ontime));tt=o(n.offtime);switch(n.service.route){case 901:case 906:case 991:t=n.service.route===901?"lightrail":"bus";s="blue";switch(n.service.route){case 901:i="BLUE";break;case 906:i="AIRPORT";break;case 991:i="BLU BUS"}break;case 902:case 992:s="green";t=n.service.route===902?"lightrail":"bus";i=n.service.route===992?"GRN BUS":"GREEN";break;case 903:s="red";t="bus";break;case 904:s="orange";t="bus";break;case 905:s="gold";t="bus";break;case 888:s="blue";t="train";break;case 425:i="ORNG LINK";s="gray";t="bus";break;default:n.service.route>=921&&n.service.route<=924?(s="gray",t="bus"):n.service.route>=2&&n.service.route<=887&&(t="bus",n.service.route===887&&(i="NS LINK"),r.hasOwnProperty(u)?s=r[u]:(r[u]=f,f++,f===5&&(f=0),s=r[u]))}n.hasOwnProperty("walktext")&&w.push('<span class="summary-leg has-walk '.concat(v==="Y"?"walk-cancelled":"",'"><span class="border-bottom-value-walk"><\/span><\/span>'));w.push('<span class="summary-leg '.concat(v==="Y"?"is-cancelled":"",'">').concat(v==="Y"?'<span class="cancelled-icon"><\/span>':"",'<span class="mode ').concat(t," border-bottom-value-").concat(s,'"><span class="badge badge-value-').concat(s,'">').concat(i,"<\/span><\/span><\/span>"))}),i.hasOwnProperty("finalwalktext")&&w.push('<span class="summary-leg has-walk '.concat(v==="Y"?"walk-cancelled":"",'"><span class="border-bottom-value-walk"><\/span><\/span>')),p.push('<div class="leg"><div class="leg-header"><div class="row"><div class="leg-time"><\/div><div class="leg-mode start-point"><strong>Depart<\/strong> '.concat(t.input.origintext,"<\/div><\/div><\/div><\/div>")),i.legs.forEach(function(t,i){var c=null;v=t.service.realtime.tripcanceled;var u=t.service.sign.split(" ")[0],e=t.service.route,w=t.service.sign;t.hasOwnProperty("statuses")&&(c=t.statuses);switch(t.service.route){case 901:case 906:case 991:y=t.service.route===901?"lightrail":"bus";s="blue";switch(t.service.route){case 901:u="BLUE LINE";break;case 906:u="AIRPORT";break;case 991:u="BLUE BUS"}break;case 902:case 992:s="green";u=t.service.route===902?"GREEN LINE":"GREEN BUS";y=t.service.route===902?"lightrail":"bus";break;case 903:s="red";y="bus";break;case 904:s="orange";y="bus";break;case 905:s="gold";y="bus";break;case 888:s="blue";y="train";break;case 425:u="ORNG LINK";s="gray";y="bus";break;default:t.service.route>=921&&t.service.route<=924?(s="gray",y="bus"):t.service.route>=2&&t.service.route<=887&&(y="bus",t.service.route===887&&(u="NS Link"),r.hasOwnProperty(e)?s=r[e]:(r[e]=f,f++,f===5&&(f=0),s=r[e]))}t.hasOwnProperty("walktext")&&(t.walktext=t.walktext&&t.walktext.startsWith("Walk ")?t.walktext.replace("Walk ","<strong>Walk<\/strong>&nbsp;"):t.walktext,p.push('<div class="leg"><div class="leg-body has-walk '.concat(v==="Y"?"walk-cancelled":"",'"><div class="row"><p class="walk border-left-value-').concat(t.onwalkdist===-1?"nowalk":"walk",'">').concat(t.walktext,"<\/p><\/div><\/div><\/div>")));var b=0,k=moment(t.ontime,"HHmm"),d=moment(t.offtime,"HHmm"),g=moment.duration(d.diff(k));b+=g.asMinutes();p.push('<div class="leg '.concat(v==="Y"?"is-cancelled":"",'">\n\t\t\t\t\t\t\t\t<div class="leg-header">\n\t\t\t\t\t\t\t\t\t<div class="row">\n\t\t\t\t\t\t\t\t\t\t<div class="leg-time"><\/div>\n\t\t\t\t\t\t\t\t\t\t<div class="leg-mode ').concat(y," border-left-value-").concat(s,'">\n\t\t\t\t\t\t\t\t\t\t\t<div class="leg-service-sign">\n\t\t\t\t\t\t\t\t\t\t\t\t<span class="badge badge-value-').concat(s,'">').concat(u,'<\/span>\n\t\t\t\t\t\t\t\t\t\t\t\t<span class="route-description">\n\t\t\t\t\t\t\t\t\t\t\t\t\t').concat(l(t.service.adherance),"\n\t\t\t\t\t\t\t\t\t\t\t\t\t<strong>to ").concat(w.substring(w.indexOf(" ")+1),"<\/strong>\n\t\t\t\t\t\t\t\t\t\t\t\t<\/span>\n\t\t\t\t\t\t\t\t\t\t\t<\/div>\n\t\t\t\t\t\t\t\t\t\t\t").concat(v==="Y"?'<span class="cancelled-msg"><\/span>':a(h,i,t.service.route,c),'\n\t\t\t\t\t\t\t\t\t\t<\/div>\n\t\t\t\t\t\t\t\t\t<\/div>\n\t\t\t\t\t\t\t\t<\/div>\n\t\t\t\t\t\t\t\t<div class="leg-body">\n\t\t\t\t\t\t\t\t\t<div class="row">\n\t\t\t\t\t\t\t\t\t\t<div class="leg-time">\n\t\t\t\t\t\t\t\t\t\t\t<strong>').concat(o(t.ontime),'<\/strong>\n\t\t\t\t\t\t\t\t\t\t\t<div class="mt-1">(').concat(b,' min)<\/div>\n\t\t\t\t\t\t\t\t\t\t<\/div>\n\t\t\t\t\t\t\t\t\t\t<div class="leg-mode border-left-value-').concat(s,'">\n\t\t\t\t\t\t\t\t\t\t\t<span class="leg-details"><strong>Depart<\/strong> from ').concat(t.onstopdata.description," Stop #").concat(t.onstopdata.stopid,'<\/span>\n\t\t\t\t\t\t\t\t\t\t<\/div>\n\t\t\t\t\t\t\t\t\t<\/div>\n\t\t\t\t\t\t\t\t\t<div class="row">\n\t\t\t\t\t\t\t\t\t\t<div class="leg-time">\n\t\t\t\t\t\t\t\t\t\t\t<strong>').concat(o(t.offtime),'<\/strong>\n\t\t\t\t\t\t\t\t\t\t<\/div>\n\t\t\t\t\t\t\t\t\t\t<div class="leg-mode border-left-value-').concat(s,'">\n\t\t\t\t\t\t\t\t\t\t\t<span class="leg-details"><strong>Arrive<\/strong> at ').concat(t.offstopdata.description," Stop #").concat(t.offstopdata.stopid,"<\/span>\n\t\t\t\t\t\t\t\t\t\t<\/div>\n\t\t\t\t\t\t\t\t\t<\/div>\n\t\t\t\t\t\t\t\t<\/div>\n\t\t\t\t\t\t\t<\/div>"));n()}),i.hasOwnProperty("finalwalktext")&&(i.finalwalktext=i.finalwalktext&&i.finalwalktext.startsWith("Walk ")?i.finalwalktext.replace("Walk ","<strong>Walk<\/strong>&nbsp;"):i.finalwalktext,p.push('<div class="leg"><div class="leg-body has-walk '.concat(v==="Y"?"walk-cancelled":"",'"><div class="row"><p class="walk border-left-value-walk">').concat(i.finalwalktext,"<\/p><\/div><\/div><\/div>"))),p.push('<div class="leg"><div class="leg-header"><div class="row"><div class="leg-time"><\/div><div class="leg-mode end-point"><strong>Arrive<\/strong> '.concat(t.input.destinationtext,"<\/div><\/div><\/div><\/div>")),ut=i.regularfare.toFixed(2),ft=i.reducedfare.toFixed(2),p.push('<div class="fares-container"><div class="trip-plan-cost"><div class="fares">Regular Fare <strong>$'.concat(ut,"<\/strong><br/>Reduced Fare <strong>$").concat(ft,"<\/strong><\/div><\/div><\/div>")),it="",g=0;g<w.length;g++)it+=w[g];rt=moment(d,"hh:mm A");nt=moment(tt,"hh:mm A");nt.isBefore(rt)&&nt.add(1,"days");b=moment.duration(nt.diff(rt));k="";b.hours()>0&&(k+=b.hours()+" hr ");(b.minutes()>0||k==="")&&(k+=b.minutes()+" min");n(".tp-results").append('<div class="card"><div class="card-header"><button type="button" id="tripBtn'.concat(h,'" class="btn btn-block text-left" data-toggle="modal" data-target="#tripModal" name="thisName').concat(h,'"><span class="tp-total-time">').concat(k,'<\/span><span class="tp-time">').concat(d.replace(/\b(AM|PM)\b/g,'<span class="font-weight-normal">$1<\/span>')," - ").concat(tt.replace(/\b(AM|PM)\b/g,'<span class="font-weight-normal">$1<\/span>'),'<\/span><span class="d-flex flex-row tp-route"><span class="tp-route-summary">').concat(it,"<\/span><\/span><\/button><\/div><\/div>"));n("#tripBtn".concat(h)).on("click",function(){n("#modalContent").empty();n("#modalContent").html('<div class="itinerary">'.concat(p.join(" "),'<\/div><div class="tp-basemap esrimap').concat(h,'"><\/div>'));u&&(TRIM.destroy(),e(),n("esrimap".concat(h)).empty(),u=!1,n(".map-container").remove());u||n(".esrimap".concat(h)).append(c)})});c='<div class="map-container"><div id="tripPlanMap" class="map" mapType="trip" aria-label="interactive map showing route of transit trip plan"><div id="trimLocate"><\/div><div class="mapLoading"><\/div> <\/div><\/div>';sessionStorage.setItem("routeColorMap",JSON.stringify(r));var y=null,p=function(f){n("#tripBtn".concat(f)).attr("data-trip-index",f);n("#tripBtn".concat(f)).on("click",function(){y=f});n("#tripModal").on("shown.bs.modal",function(){u||y!==null&&y===f&&(n(".esrimap".concat(f," .map-container")).remove(),n(".esrimap".concat(f)).append(c),i.getElementById("tripPlanMap")?(i.getElementById("trimLocate")&&n("#trimLocate").remove(),TRIM.init("tripPlanMap").then(function(){u=!0;v(f,t,!0,r)}).catch(function(n){console.error("Error initializing TRIM:",n)})):console.warn("Element with ID tripPlanMap not found."))});n("#tripModal").on("hidden.bs.modal",function(){e();n("#modalContent").empty()})};for(h=0;h<3;h++)p(h)}).catch(function(n){console.error("There was a problem fetcing the data: ",n)})},e=function(){u&&(TRIM.destroy(),u=!1)},y=function(){AutocompleteAddress.init("fromLocation",!0,function(){AutocompleteAddress.getChoice("fromLocation")&&(n("#fromLocation").removeClass("is-invalid"),n("#fromErrorMessage").addClass("d-none"))});AutocompleteAddress.init("toLocation",!0,function(){AutocompleteAddress.getChoice("toLocation")&&(n("#toLocation").removeClass("is-invalid"),n("#toErrorMessage").addClass("d-none"))});n("#tpUseCurrentLoc").click(function(t){t.preventDefault();AutocompleteAddress.getUserLocation().then(function(){var t=AutocompleteAddress.setUserLoc("fromLocation");t&&n("#fromLocation").val("Current Location")})});n(".location-toggler").click(function(){var t=n("#fromLocation, #toLocation"),i=t[0].value;t[0].value=t[1].value;t[1].value=i;AutocompleteAddress.exchangeValues("fromLocation","toLocation")});n(".time-elements").hide();n("#selectTime").on("change",function(){this.value!=="leave-now"?(n("#dateTimePickerFutureOnly").val(moment().format("L LT")),n(".time-elements").slideDown()):n(".time-elements").slideUp()});n('button[name="planMyTrip"]').on("click",function(){var t,i,r,u,o,l,a;if(n("#tripPlannerResults").hide(),e(),t=AutocompleteAddress.getChoice("fromLocation"),t===null){n("#fromLocation").addClass("is-invalid").focus();n("#fromErrorMessage").removeClass("d-none");event.preventDefault();return}if(i=AutocompleteAddress.getChoice("toLocation"),i===null){n("#toLocation").addClass("is-invalid").focus();n("#toErrorMessage").removeClass("d-none");event.preventDefault();return}r="Depart";u=n("#selectTime").val();u==="arrive-by"&&(r="Arrive");o=moment();u!=="leave-now"&&(l=n("#dateTime").val(),o=moment(l,"MM/DD/YYYY hh:mm A"));var v=n("input[name='serviceType']:checked").val(),y=n("input[name='convenience']:checked").val(),p=h(n("#distanceRange").val()),w=n("#isAccessible").is(":checked");n("#distanceRange").on("input",function(){var t=n(this).val();n(this).attr("value",t)});t&&i&&(a={fromLocation:t,toLocation:i,xmode:v,arrdep:r,walkdist:p,minimize:y,accessible:w,datetime:o},c(a).then(function(){var t=f;sessionStorage.setItem("tripJSON",JSON.stringify(f));t.itin.length>0?(s(t),n(".trips-found").show(),n(".no-trips-found").hide(),n("#spinner").addClass("d-none"),n("#planTrip").hide("slow"),n("#tripPlannerResults").show()):(n(".trips-found").hide(),n(".no-trips-found").show(),n("#spinner").addClass("d-none"),n("#planTrip").hide("slow"),n("#tripPlannerResults").show("slow"),n(".tp-results").empty())}).fail(function(t){console.warn("Trip Plan Failed:",t);n(".tp-results").empty();n(".trips-found").show();n(".no-trips-found").show();n("#spinner").addClass("d-none");n("#planTrip").hide("slow");n("#tripPlannerResults").show()}))});n("#editMyTrip").on("click",function(){sessionStorage.clear();e();for(var t in r)r.hasOwnProperty(t)&&delete r[t];n("#tripPlannerResults").hide("slow");n("#planTrip").show("slow");n("#fromLocation").focus();n("#modalContent").empty();n("#tripModal").off("shown.bs.modal hidden.bs.modal")});n("#startTripOver").on("click",function(){function t(n){var t=i.getElementsByName(n);t.forEach(function(n){n.checked=n.hasAttribute("checked")})}sessionStorage.clear();e();for(var u in r)r.hasOwnProperty(u)&&delete r[u];n("#tripPlannerResults").hide("slow");n("#planTrip").show("slow");AutocompleteAddress.deleteChoice("fromLocation");n("#fromLocation").val("");AutocompleteAddress.deleteChoice("toLocation");n("#toLocation").val("");n(".time-elements").hide();n("#selectTime").val("leave-now");n("#halfMile");n("#tpMoreOptions").collapse("hide");n("#fromLocation").focus();n("modalContent").empty();t("walkingDistance");t("serviceType");t("convenience");t("accessible");n("#tripModal").off("shown.bs.modal hidden.bs.modal")});n("#tpMoreOptions").on("shown.bs.modal",function(){n("#distanceRange").on("input",function(){var t=n(this).val();n(this).attr("value",t)})});n("#tpMoreOptions").on("hidden.bs.modal",function(){n("#distanceRange").off("input")})},p=function(t){if(t){var i=JSON.parse(t);f=i;i.itin.length>0&&(s(i),n(".trips-found").show(),n(".no-trips-found").hide(),n("#spinner").addClass("d-none"),n("#planTrip").hide("slow"),n("#tripPlannerResults").show("slow"))}};return{init:y,refreshTrip:p}}(jQuery,window,document);$(function(){if($("#planMyTrip").length){TripPlan.init();var n=sessionStorage.getItem("tripJSON");n&&TripPlan.refreshTrip(n)}});ParkRideServices=function(n,t){function i(i){return n("#prFinderResults .accordion").remove(),n.Deferred(function(r){var u="0",f;i.attributes.ATIS_ID.indexOf(";")>-1&&(u=i.attributes.ATIS_ID.split(";")[1]);f={location:{description:i.attributes.LongLabel,point:{x:+i.location.x,y:+i.location.y},landmarkid:+u}};n.post({contentType:"application/json",url:t.serviceHostUrl+"/tripplanner/nearestparkandrides",data:JSON.stringify(f),dataType:"json"}).done(function(n){r.resolve(n)}).fail(function(n){r.reject("ParkRideServiceFinder failed - No results "+n)})}).promise()}function r(t){n(".spinner").removeClass("d-none");i(t).then(function(i){i.pnrs.forEach(function(t){var u=function(n){return n.map(function(n){return'<a href="/route/'.concat(n.routeurlparam,'">').concat(n.routepublic,"<\/a>")})},f=u(t.routes).join(", "),i=[],r;CoordinateConversion.UTMXYToLatLon(+t.pnrpoint.x,+t.pnrpoint.y,15,!1,i);t.pnrpoint.x=CoordinateConversion.RadToDeg(i[1]).toFixed(4);t.pnrpoint.y=CoordinateConversion.RadToDeg(i[0]).toFixed(4);r="/imap/interactivemap.aspx?x="+t.pnrpoint.x+"&y="+t.pnrpoint.y+"&t=pr";console.log(r);var e=t.capacity?'<span class="badge cyan-bg">'.concat(t.capacity," spaces<\/span>"):"",o=t.hasbikelocker?'<span class="badge transit-blue-bg">Bike lockers<\/span>':"",s=t.coveredparking?'<span class="badge orange-bg">Covered parking<\/span>':"",h=t.hasshelter?'<span class="badge green-bg">Shelter<\/span>':"";n("#prFinderResults").append('<div class="accordion">\n\t\t\t\t\t\t\t<button type="button" class="btn btn-trigger text-left collapsed" data-target="#pnrid-'.concat(t.pnrid,'" data-toggle="collapse" aria-expanded="false">\n\t\t\t\t\t\t\t\t<span class="pr-location">').concat(t.pnrdescription.replace(/Park and Ride/g,"Park & Ride"),"&nbsp;(").concat(t.pnrdistance,'&nbsp;mi.)<\/span>\n\t\t\t\t\t\t\t<\/button>\n\t\t\t\t\t\t\t<div id="pnrid-').concat(t.pnrid,'" class="collapse">\n\t\t\t\t\t\t\t\t<div class="p-3">\n\t\t\t\t\t\t\t\t\t<p><strong>Served by routes:&nbsp;<\/strong>').concat(f,"<br />\n\t\t\t\t\t\t\t\t\t\t").concat(t.pnraddress,'<br />\n\t\t\t\t\t\t\t\t\t\t<a href="').concat(r,'">View on map<\/a>\n\t\t\t\t\t\t\t\t\t<\/p>\n\t\t\t\t\t\t\t\t\t<div class="d-flex justify-content-start">\n\t\t\t\t\t\t\t\t\t\t').concat(e,"\n\t\t\t\t\t\t\t\t\t\t").concat(o,"\n\t\t\t\t\t\t\t\t\t\t").concat(s,"\n\t\t\t\t\t\t\t\t\t\t").concat(h,"\n\t\t\t\t\t\t\t\t\t<\/div>\n\t\t\t\t\t\t\t\t<\/div>\n\t\t\t\t\t\t\t<\/div>\n\t\t\t\t\t\t<\/div>"))});i.length===0&&n("#prFinderResults").append('<p class="result-msg">No Park & Rides close to '+t.attributes.LongLabel+"<\/p>");n(".spinner").addClass("d-none");sessionStorage.setItem("prFinderResults",n("#prFinderResults").html())}).fail(function(){n("#prFinderResults").append('<p class="result-msg">No Park & Rides close to '+t.address+"<\/p>")})}return{formatPage:r}}(jQuery,window,document);$(function(){$("#parkRides").length&&(AutocompleteAddress.init("parkRidesSearch",!0,function(){var n=AutocompleteAddress.getChoice("parkRidesSearch");ParkRideServices.formatPage(n)}),sessionStorage.getItem("prFinderResults")===null||$("#prFinderResults").html(sessionStorage.getItem("prFinderResults")),$("#prUseCurrentLoc").click(function(n){n.preventDefault();AutocompleteAddress.getUserLocation().then(function(){$("#parkRidesSearch").val("Current Location");var n=AutocompleteAddress.setUserLoc("parkRidesFindMe");n&&ParkRideServices.formatPage(n)})}))});StopServices=function(n,t){function i(i){return n.Deferred(function(r){let u="0";i.attributes.ATIS_ID.indexOf(";")>-1&&(u=i.attributes.ATIS_ID.split(";")[1]);var f={location:{description:i.attributes.LongLabel,point:{x:+i.location.x,y:+i.location.y},landmarkid:+u},accessible:!1};n.post({contentType:"application/json",url:t.serviceHostUrl+"/tripplanner/servicenearby",data:JSON.stringify(f),dataType:"json"}).done(function(n){r.resolve(n)}).fail(function(n){r.reject("StopServiceFinder failed - No results "+n)})}).promise()}function r(n){let t="/route/"+n,i={887:"link",888:"nstar",901:"blue",991:"blue",902:"green",992:"green",903:"red",904:"orange",905:"gold",921:"aline",922:"bline",923:"cline",924:"dline",925:"eline"};return+n in i&&(t="/route/"+i[+n]),t}function u(t){const u={N:"North",S:"South",E:"East",W:"West"};n("#stopFinderResults").empty();n("#stopFinderResults").append('<p class="result-msg">Transit service near '+t.attributes.LongLabel+"<\/p>");i(t).then(function(t){if(t.hasOwnProperty("atstop")){let i=t.atstop;i.forEach(function(t){let e="/imap/0/"+t.stopid,i=[];i.push(`
					<div class="row">
						<div class="col-lg-1">
					`);t.service[0].routetype==="L"?i.push('<img alt="" class="icon mb-4 mb-lg-0" src="/img/svg/circle-gray-lrt.svg" />'):t.service[0].route==="888"?i.push('<img alt="" class="icon mb-4 mb-lg-0" src="/img/svg/circle-gray-outline-train.svg" />'):i.push('<img alt="" class="icon mb-4 mb-lg-0" src="/img/svg/circle-gray-outline-bus.svg" />');i.push(`
						</div>
					<div class="col-lg-10">
						<div class="transit-service">
					`);let f=[];t.service.forEach(function(n){if(!f.includes(n.route)){let t=r(n.route);i.push(`<a href="${t}" class="btn btn-route-lg routes">${n.publicroute} ${u[n.direction]}</a>`);f.push(n.route)}});i.push("<\/div><\/div><\/div>");n("#stopFinderResults").append(`
					<div class="gray-bg-100 p-4 mb-4">
						<div class="row">
							<div class="col-lg-7">
								<h2>${t.description}</h2>
							</div>
							<div class="col-lg-5">
								<div class="row">
									<div class="col-6">
										<p class="stop-id"><strong>Stop ID:</strong> ${t.stopid}</p>
									</div>
									<div class="col-6 map">
										<p><a class="map-link" href="${e}">Map</a></p>
									</div>
								</div>
							</div>
						</div>
						${i.join("")}
					</div>
					`);sessionStorage.setItem("stopFinderResults",n("#stopFinderResults").html())})}else n("#stopFinderResults").append('<p class="result-msg">No transit service available within a half-mile.<\/p>')}).fail(function(t){console.warn("StopServices"+t);n("#stopFinderResults").append('<p class="result-msg">No transit service available within a half-mile.<\/p>')})}return{formatPage:u,findNearestStops:i}}(jQuery,window,document);$(function(){$("#stopsStationsSearch").length&&(AutocompleteAddress.init("stopsStationsSearch",!0,function(){var n=AutocompleteAddress.getChoice("stopsStationsSearch");StopServices.formatPage(n)}),sessionStorage.getItem("stopFinderResults")===null||$("#stopFinderResults").html(sessionStorage.getItem("stopFinderResults")),$("#ssUseCurrentLoc").click(function(){AutocompleteAddress.getUserLocation().then(function(){$("#stopsStationsSearch").val("Current Location");let n=AutocompleteAddress.setUserLoc("stopsStationsFindMe");n&&StopServices.formatPage(n)})}))});"use strict";let News=function(n,t,i,r){"use strict";let u=function(){let t=[],f=n(".articleDisplayDate"),u=n(".articleDisplayTitle>h2>a"),e=n(".articleImageAbstract>img"),o=n(".articleDisplayAbstract"),c=Math.max(3,u.length);for(let n=0;n<c;n++){let h=f[n]!=r?f[n].textContent.trim():"",c=u[n]!=r?u[n].text:"Article",l=u[n]!=r?u[n].href:"#",s=e[n]!=r?e[n]:i.createElement("img");s.src||(s.src="/img/placeholder-300x300.png",s.alt="placeholder");let a=o[n]!=r?o[n].innerHTML:"";t[n]={date:h,title:c,link:l,img:s,abstract:a}}let s=n("#newsEvents>div.news-card-deck div.card");s.length&&n.each(s,(i,r)=>{let u=n(r).find("img.card-img-top").attr("class")||"",f=t[i].img.className||"";n(r).find("img.card-img-top").attr({alt:t[i].img.alt,src:t[i].img.src,"class":u.concat(" ",f).trim()});n(r).find("div.card-text a").text(t[i].title).attr("href",t[i].link)});let h=n(".news-revamp>.articleRow").removeClass("d-none").remove();h.length&&n.each(t,(t,i)=>{let r=h.clone(),u=r.find("img.articleImage").attr("class")||"",f=i.img.className||"";r.find("img.articleImage").attr({alt:i.img.alt,src:i.img.src,"class":u.concat(" ",f).trim()});r.find(".articleContent>h2").text(i.title);r.find(".articleDate").text(i.date);r.find(".articleText").html(i.abstract);r.find(".articleLink").attr("href",i.link);n(".news-revamp").append(r)})};return{init:u}}(jQuery,window,document);"use strict";var activeTab="route",locationBtnClicked=!1,scalebar=null,mapInitialized=!1,lastPushedState=null;NexTrip=function(n,t,i,r){function nt(n){if(!p[n]){var t=Object.keys(p).length%5;p[n]="badge-value-"+t}return p[n]}function tt(){var i=arguments.length>0&&arguments[0]!==r?arguments[0]:!1,t=n("#ntRoute");t.children().length>1&&!i||n.get(a+"/nextripv2/routes").done(function(i){var r=JSON.parse(JSON.stringify(i));t.empty();t.append("<option selected>Select route<\/option>");n.each(r,function(i,r){t.append(n("<option/>").val(r.route_id).text(r.route_label))})}).fail(function(n,t,i){console.error("Failed to load routes: ",t,i)})}function it(t){n.get(a+"/nextripv2/directions/"+t).done(function(t){var r=JSON.parse(JSON.stringify(t)),i=n("#ntDirection");i.empty();i.append("<option>Select direction<\/option>");n.each(r,function(t,r){i.append(n("<option/>").val(r.direction_id).text(r.direction_name))});n(".select-route-direction").fadeIn("slow").css("display","flex");i.val("Select direction");i.trigger("change")}).fail(function(n,t,i){console.error("Failed to load directions: ",t,i)})}function rt(t,i){n.get(a+"/nextripv2/stops/"+t+"/"+i).done(function(t){var r=JSON.parse(JSON.stringify(t)),i=n("#ntStop");i.find("option:gt(0)").remove();n.each(r,function(t,r){i.append(n("<option/>").val(r.place_code).text(r.description))});n(".select-route-stop").fadeIn("slow").css("display","flex")}).fail(function(n,t,i){console.error("Failed to load stops: ",t,i)})}function b(t,i,r){var u="/nextrip/"+t+"/"+i+"/"+r;n.get(a+"/nextripv2/"+t+"/"+i+"/"+r).done(function(n){d(JSON.parse(JSON.stringify(n)));lastPushedState!==u&&(history.pushState({},"",u),lastPushedState=u)}).fail(function(n,t,i){console.error("Failed to load timepoint departures: ",t,i)})}function l(t){var i="/nextrip/"+t;n.get(a+"/nextripv2/"+t).done(function(n){d(JSON.parse(JSON.stringify(n)));lastPushedState!==i&&(history.pushState({},"",i),lastPushedState=i)}).fail(function(){n(".stop-departures tbody").empty();n(".stop-departures").hide();n("#toggleDepartures").hide();n(".map-container").hide();n("#nextripDepartures").show();n(".stop-description").html('<p class="fail-text">'+t+" is not a valid stop number.<\/p>");u&&(clearInterval(u),u=null)})}function d(t){var i,r,e,u,o;if(n("#nextripDepartures").show(),n(".map-container").show(),n(".stop-departures").show(),i=n(".stop-departures tbody"),i.empty(),t.stops&&t.stops.length>0)r=t.stops[0],f=r.stop_id,e='<div class="stop-number"><span class="badge badge-gray mb-2">Stop #: '.concat(t.stops.map(function(n){return n.stop_id}).join(", "),'<\/span><\/div><h3 class="h2 stop-name">').concat(r.description,"<\/h3>"),n(".stop-description").html(e);else{n(".stop-description").html('<p class="no-stops-msg"><strong>No stop information available.<\/strong><\/p>');return}if(u=!1,t.alerts&&Array.isArray(t.alerts)&&(u=t.alerts.some(function(n){return n.stop_closed===!0})),u){i.append('<tr><td class="no-departures-msg" colspan="3"><strong>Stop closed.<\/strong><\/td><\/tr>');n("#toggleDepartures").hide();n(".map-container").hide();return}t.departures&&t.departures.length>0?(o=t.departures.slice(0,18),n.each(o,function(t,r){var e="badge-gray",o=r.route_short_name.toLowerCase(),u,f;isNaN(o)||(e=k[o]||"badge-value-gray");u=n("<tr/>",{"class":"departure"}).appendTo(i);u.append(n("<td/>",{"class":"route-number mr-2"}).html('<span class="badge '+e+'">'+r.route_short_name+(r.terminal?r.terminal:"")+"<\/span>"));u.append(n("<td/>",{"class":"route-name"}).text(r.description));f=n("<td/>",{"class":"depart-time ml-auto"}).appendTo(u);(r.departure_text.indexOf("Min")>0||r.departure_text==="Due")&&f.append(n("<img/>",{"class":"icon blink mr-1",src:"/img/svg/broadcast-blue.svg"}));r.schedule_relationship==="Skipped"?f.append('<span class="red">Canceled<br/>'+r.departure_text+"<\/span>"):f.append("<span>"+r.departure_text+"<\/span>");t>=4&&u.addClass("d-none")}),t.departures.length>4?n("#toggleDepartures").show():n("#toggleDepartures").hide(),y&&(n(".departure").removeClass("d-none"),n("#toggleDepartures").attr("aria-expanded","true").html('<span class="sr-only">Show less<\/span>'))):(i.append('<tr><td class="no-departures-msg" colspan="3"><strong>No departures at this time<\/strong><\/td><\/tr>'),n("#toggleDepartures").hide(),n(".map-container").hide())}function g(){u&&(clearInterval(u),u=null);n("#ntRoute").val("Select route");n(".direction").hide();n(".stop").hide();n(".stop-departures tbody").empty();n("#nextripDepartures").hide()}function ut(t){f=t;l(f);u?console.log("Timer already running, no need to start a new one"):u=setInterval(function(){l(f)},3e4);n("#nextripModal").modal("show")}function ft(){stopListSpinner(!0);var n=AutocompleteAddress.setUserLoc("nexTrip");if(!n){s.empty();stopListSpinner(!1);c.addClass("d-none");return}StopServices.findNearestStops(n).done(function(n){if(s.empty(),n.atstop&&n.atstop.length>0){var t=n.atstop;t.length>3?c.removeClass("d-none"):c.addClass("d-none");t.forEach(function(n,t){var i='<div class="card has-icon-right '.concat(t>=3?"show-more":"",'" role="button" tabindex="0" aria-label="').concat(n.stopid,'" onclick="javascript:NexTrip.showDepartures(').concat(n.stopid,');"><div class="card-body d-flex justify-content-between align-items-center"><div class="row card-content"><div class="col-6"><div class="badge badge-gray stop">Stop # ').concat(n.stopid,'<\/div><p class="card-text">').concat(n.description,'<\/p><\/div><div class="col-6 border-left route-container">').concat(et(n.service),"<\/div><\/div><\/div><\/div>");s.append(i)})}else console.warn("No stops found."),s.append('<p class="no-stops-msg">No stops found based on your location.<\/p>')}).always(function(){stopListSpinner(!1)}).fail(function(){console.error("Failed to find nearest stops.");s.empty();stopListSpinner(!1);c.addClass("d-none")})}function et(t){function r(n){switch(n){case"N":return"North";case"S":return"South";case"E":return"East";case"W":return"West";default:return""}}var i="";return n.each(t,function(n,t){var f="",u=t.publicroute.toLowerCase(),e;f=isNaN(u)?k[u]||"badge-value-gray":nt(u,n);e=r(t.direction);i+='<div class="route-direction"><span class="badge '.concat(f,'">').concat(t.publicroute,"<\/span> <span>").concat(e,"<\/span><\/div>")}),i}function ot(){Main.enterKeyPressHandler("#stopNumber","#searchStopsButton");var i=t.location.pathname.split("/");i[1].toLowerCase()==="nextrip"&&(i.length!==3||isNaN(i[2])?i.length===5&&(e=i[2],o=i[3],h=i[4],b(e,o,h),n("#nextripModal").modal("show"),u||(u=setInterval(function(){l(f)},3e4))):(f=i[2],l(f),n("#nextripModal").modal("show"),u||(u=setInterval(function(){l(f)},3e4))));tt();n("#ntRoute").on("change",function(){e=this.value;e&&(n("#ntStop").val("Select direction"),n(".select-route-stop").hide(),it(e))});n("#ntDirection").on("change",function(){o=this.value;o&&o!=="Select direction"&&(n("#ntStop").val(""),rt(e,o))});n("#ntStop").on("change",function(){h=this.value;h&&(b(e,o,h),u?console.log("Timer already running, no need to start a new one"):u=setInterval(function(){b(e,o,h)},3e4));n("#nextripModal").modal("show")});n("#ntrUseCurrentLoc").on("click",function(){locationBtnClicked=!0;stopListSpinner(!0);n(".nav-tabs .nav-link").removeClass("active");n("#ntrUseCurrentLoc").addClass("active");n(".tab-pane").removeClass("show active");n("#nextrip").addClass("show active");n("#currentLocation").addClass("show active");AutocompleteAddress.getUserLocation().then(function(){ft()}).catch(function(){stopListSpinner(!1);s.html('<div class="alert alert-info">Location service is either disabled on your device, or service is not available.<\/div>')})});n("#ntrUseCurrentLoc, #byRouteTab, #byStopTab").on("click",function(){n("#nTab").addClass("active").attr("aria-selected","true");n("#tpTab").removeClass("active").attr("aria-selected","false")});n("#searchStopsButton").on("click",function(){f=n("#stopNumber").val();f.length&&(e="",o="",h="",g(),l(f),u?console.log("Timer is running, no need to start a new one"):u=setInterval(function(){l(f)},3e4));n("#nextripModal").modal("show")})}var e,o,h,f,u,v=!1,a=n("meta[name=web-service-uri]").attr("content"),s=n(".nextrip-stop-list"),c=n(".btn-scroll"),w=!0,y=!1,p={},k={blue:"badge-value-blue",gold:"badge-value-gold",gray:"badge-value-gray",green:"badge-value-green",nstar:"badge-value-nstar",orange:"badge-value-orange",purple:"badge-value-purple",red:"badge-value-red"};n("#ttTabs .nav-link").on("click",function(){activeTab=n(this).attr("id")});c.on("click keydown",function(n){(n.type==="click"||n.type==="keydown"&&(n.key==="Enter"||n.key===" "))&&(w?(s.animate({scrollTop:s[0].scrollHeight},400,"swing"),c.attr("aria-label","Scroll to top").css("transform","rotate(180deg)")):(s.animate({scrollTop:0},400,"swing"),c.attr("aria-label","Scroll to bottom").css("transform","rotate(0deg)")),w=!w)});n("#toggleDepartures").on("click",function(){var t=n(".departure");y?(t.slice(4).fadeOut(500,function(){n(this).addClass("d-none")}),n(this).attr("aria-expanded","false").html('<span class="sr-only">Show more<\/span>'),n("#nextripModal .modal-body").animate({scrollTop:0},300)):(t.fadeIn(1e3).removeClass("d-none"),n(this).attr("aria-expanded","true").html('<span class="sr-only">Show less<\/span>'));y=!y});t.addEventListener("popstate",function(){var r=t.location.pathname,i=n("#nextripModal");i.hasClass("show")&&(i.modal("hide"),r.includes("/nextrip/")&&NexTrip.init());t.location.reload()});n("#nextripModal").on("shown.bs.modal",function(){initializeMap();mapInitialized&&NexTripMap.resize();var t={stopID:f||null,routeID:e||null,zoomToNearestBus:!0};v?BOM.startBusesOnMap(t):(BOM&&BOM.widgets&&BOM.widgets.bomlocate&&(BOM.widgets.bomlocate.destroy(),delete BOM.widgets.bomlocate),BOM.init("NexTripMap").then(function(){v=!0;BOM.startBusesOnMap(t)}));n("#toggleDepartures").attr("aria-expanded","false");n(".stop-departures .departure").slice(4).addClass("d-none")});n("#nextripModal").on("hidden.bs.modal",function(){u&&(clearInterval(u),u=null);f=null;mapInitialized=!1;n("#ntStop").val("Select stop");n(".stop-departures tbody").empty();n("#nextripDepartures").hide();n(".map-container").hide();v&&(BOM.stopBusesOnMap(),v=!1,_TIMECLOCK&&clearInterval(_TIMECLOCK),scalebar&&(scalebar.destroy(),scalebar=null),BOM&&BOM.destroy())});return{init:ot,showDepartures:ut,resetUI:g}}(jQuery,window,document);$(document).ready(function(){NexTrip.init()});customDateTimePickers=function(n){var t=moment(),i=function(){n("#dateTimePicker").datetimepicker({allowInputToggle:!0,inLine:!0,sideBySide:!0,icons:{previous:"icon chevron-sm-left-cyan",next:"icon chevron-sm-right-cyan",up:"icon chevron-sm-up-cyan",down:"icon chevron-sm-down-cyan"},widgetPositioning:{horizontal:"left",vertical:"top"}});n("#datePicker, .datepicker").datetimepicker({allowInputToggle:!0,format:"L",icons:{previous:"icon chevron-sm-left-cyan",next:"icon chevron-sm-right-cyan"},widgetPositioning:{horizontal:"left",vertical:"top"}});n("#timePicker, .timepicker").datetimepicker({allowInputToggle:!0,format:"LT",icons:{up:"icon chevron-sm-up-cyan",down:"icon chevron-sm-down-cyan"},widgetPositioning:{horizontal:"left",vertical:"top"}});var i=n("#dateTimePickerFutureOnly");i.datetimepicker({allowInputToggle:!0,useCurrent:!0,minDate:t.clone().startOf("day"),icons:{date:"icon calendar-gray",time:"icon clock-gray",previous:"icon chevron-sm-left-gray",next:"icon chevron-sm-right-gray",up:"icon chevron-sm-up-gray",down:"icon chevron-sm-down-gray"},widgetPositioning:{horizontal:"right",vertical:"top"}});i.on("dp.change",function(t){var r=t.date,i=moment();r.isSame(i,"day")?n("#dateTimePickerFutureOnly").data("DateTimePicker").options({enabledHours:Array.from({length:24},function(n,t){return t}).filter(function(n){return n>=i.hour()})}):n("#dateTimePickerFutureOnly").data("DateTimePicker").options({enabledHours:null})});n("#dateTimePickerStart").datetimepicker({allowInputToggle:!0,inLine:!0,sideBySide:!0,icons:{previous:"icon chevron-sm-left-cyan",next:"icon chevron-sm-right-cyan",up:"icon chevron-sm-up-cyan",down:"icon chevron-sm-down-cyan"},widgetPositioning:{horizontal:"left",vertical:"top"}});n("#dateTimePickerEnd").datetimepicker({useCurrent:!1,allowInputToggle:!0,inLine:!0,sideBySide:!0,icons:{previous:"icon chevron-sm-left-cyan",next:"icon chevron-sm-right-cyan",up:"icon chevron-sm-up-cyan",down:"icon chevron-sm-down-cyan"},widgetPositioning:{horizontal:"left",vertical:"top"}});n("#dateTimePickerStart").on("change.datetimepicker",function(t){n("#dateTimePickerEnd").datetimepicker("clear");n("#dateTimePickerEnd").datetimepicker("minDate",t.date)});n("#dateTimePickerEnd").on("change.datetimepicker",function(t){n("#dateTimePickerStart").datetimepicker("maxDate",t.date)});n("#datePickerPastOnly, .datepicker-past-only").datetimepicker({allowInputToggle:!0,format:"MM/DD/YYYY",maxDate:t,icons:{previous:"icon chevron-sm-left-cyan",next:"icon chevron-sm-right-cyan"},widgetPositioning:{horizontal:"left",vertical:"top"}});n("#timePickerPastOnly, .timepicker-past-only").datetimepicker({allowInputToggle:!0,format:"LT",icons:{up:"icon chevron-sm-up-cyan",down:"icon chevron-sm-down-cyan"},widgetPositioning:{horizontal:"left",vertical:"top"}});n("#datePickerFutureOnly, .datepicker-future-only").datetimepicker({allowInputToggle:!0,format:"MM/DD/YYYY",minDate:t,icons:{previous:"icon chevron-sm-left-cyan",next:"icon chevron-sm-right-cyan"},widgetPositioning:{horizontal:"left",vertical:"top"}});n("#datePickerStart").datetimepicker({allowInputToggle:!0,format:"L",minDate:t,icons:{previous:"icon chevron-sm-left-cyan",next:"icon chevron-sm-right-cyan"},widgetPositioning:{horizontal:"left",vertical:"top"}});n("#datePickerEnd").datetimepicker({allowInputToggle:!0,minDate:t,format:"L",icons:{previous:"icon chevron-sm-left-cyan",next:"icon chevron-sm-right-cyan"},widgetPositioning:{horizontal:"left",vertical:"top"}});n("#timePickerStart").datetimepicker({allowInputToggle:!0,format:"LT",icons:{up:"icon chevron-sm-up-cyan",down:"icon chevron-sm-down-cyan"},widgetPositioning:{horizontal:"left",vertical:"top"}});n("#timePickerEnd").datetimepicker({allowInputToggle:!0,format:"LT",icons:{up:"icon chevron-sm-up-cyan",down:"icon chevron-sm-down-cyan"},widgetPositioning:{horizontal:"left",vertical:"top"}});n("#linkedDatePickerStart").datetimepicker({allowInputToggle:!0,format:"L",minDate:t,icons:{previous:"icon chevron-sm-left-cyan",next:"icon chevron-sm-right-cyan"},widgetPositioning:{horizontal:"left",vertical:"top"}});n("#linkedDatePickerEnd").datetimepicker({allowInputToggle:!0,useCurrent:!1,format:"L",icons:{previous:"icon chevron-sm-left-cyan",next:"icon chevron-sm-right-cyan"},widgetPositioning:{horizontal:"left",vertical:"top"}});n("#linkedTimePickerStart").datetimepicker({allowInputToggle:!0,format:"LT",icons:{up:"icon chevron-sm-up-cyan",down:"icon chevron-sm-down-cyan"},widgetPositioning:{horizontal:"left",vertical:"top"}});n("#linkedTimePickerEnd").datetimepicker({allowInputToggle:!0,format:"LT",icons:{up:"icon chevron-sm-up-cyan",down:"icon chevron-sm-down-cyan"},widgetPositioning:{horizontal:"left",vertical:"top"}});n("#linkedDatePickerStart").on("change.datetimepicker",function(t){n("#linkedDatePickerEnd, #linkedTimePickerStart, #linkedTimePickerEnd").datetimepicker("clear");n("#linkedDatePickerEnd").datetimepicker("minDate",t.date)});n("#linkedTimePickerStart").on("change.datetimepicker",function(t){n("#linkedDatePickerEnd, #linkedTimePickerEnd").datetimepicker("clear");n("#linkedTimePickerEnd").datetimepicker("minDate",t.date)});n("#linkedDatePickerEnd").on("change.datetimepicker",function(){n("#linkedTimePickerEnd").datetimepicker("clear")})};return{init:i}}(jQuery,window,document);$(function(){customDateTimePickers.init()});Main=function(n,t,i){function h(n){var t=n.toString();return t?/\S/.test(t):!1}function c(n){return h(n)?!isNaN(+n):!1}function l(n){return c(n)?n.toString().search(/^[0-9]+$/)===0:!1}var r=function(n){for(var f=i.cookie.split(";"),t="",u="",e="",o=!1,r="",r=0;r<f.length;r++){if(t=f[r].split("="),u=t[0].replace(/^\s+|\s+$/g,""),u===n)return o=!0,t.length>1&&(e=unescape(t[1].replace(/^\s+|\s+$/g,""))),e;t=null;u=""}if(!o)return null},f=function(n,t,r,u,f,e){var o=new Date,s;o.setTime(o.getTime());r&&(r=r*864e5);r=0;s=new Date(o.getTime()+r);i.cookie=n+"="+escape(t)+(r?";expires="+s.toGMTString():"")+(u?";path="+u:"")+(f?";domain="+f:"")+(e?";secure":"")},a=function(n,t,u){r(n)&&(i.cookie=n+"="+(t?";path="+t:"")+(u?";domain="+u:"")+";expires=Thu, 01-Jan-1970 00:00:01 GMT")},o=function(t,i){if(n(".alert-popup").length&&t.substring(0,3)==="pop"&&r("PopupNoticeShown"+t)!=="true"){f("PopupNoticeShown"+t,"true",i);n("<div />").prependTo("body").addClass("alert-popup-overlay");n("body").addClass("hidden-overflow");n(".alert-popup").show();n('button[data-dismiss="alert"]').on("click",function(){n(".alert-popup").hide();n(".alert-popup-overlay").remove();n("body").removeClass("hidden-overflow")})}if(n(".alert-topmargin").length){t.substring(0,3)==="top"&&r("PopupNoticeShown"+t)!=="true"&&n("body").prepend(n(".alert-topmargin").show());n(".alert-topmargin .close").on("click",function(){f("PopupNoticeShown"+t,"true",i)})}},s=function(t,r){var u=n(t);u.on("focus",function(){n(i).on("keydown",function(t){u.attr("id")===t.target.id&&u.val()!==""&&t.which===13&&(t.preventDefault(),n(r).trigger("click"))})});u.on("blur",function(){n(i).off("keydown")})},u,e;n("#schedulesByRoute").on("keydown",function(t){t.key==="Enter"&&(t.preventDefault(),n("#searchRoutesButton").click())});n("#searchRoutesButton").on("click",function(n){n.preventDefault();u()});return u=function(){var t=n("#schedulesByRoute").val();if(console.log("Term entered: ",t),t.length){var u=t.toLowerCase().trim().split(" "),r={north:"nstar",northstar:"nstar",blue:"blue",gold:"gold",green:"green",red:"red",orange:"orange",a:"aline",b:"bline",c:"cline",d:"dline"},i=!0;u.forEach(function(n){l(n)?(location.assign("/route/"+n),i=!1):r[n]&&(location.assign("/route/"+r[n]),i=!1)});i&&location.assign("/route/0")}},e=function(){var f=r("cart_status"),e,u;f!==null&&f>0&&n("<span/>",{"class":"badge badge-info"}).text(f).appendTo(n("a.store-icon"));n('[data-toggle="popover"]').popover({html:!0,trigger:"focus"});n("#header img.active").hide();e=n("#header .nav-item");n(e).hover(function(){n(this).find("img.inactive").hide();n(this).find("img.active").show()},function(){n(this).find("img.inactive").show();n(this).find("img.active").hide()});n(".secondary-nav").length&&n('.secondary-nav > ul > li > a[href="'+location.pathname.replace("/","\\/")+'"]').addClass("active");n("#siteSearchBtn").on("click",function(){t.location=n("meta[name=metrotransit-org-uri]").attr("content")+"/website-search-results?q="+encodeURI(n("#siteSearch").val())});n(".custom-file input").on("change",function(){for(var i=[],t=0;t<n(this)[0].files.length;t++)i.push(n(this)[0].files[t].name);n(this).next(".custom-file-label").html(i.join(", "))});n('[data-trigger="#navbarSupportedContent"]').on("click",function(){n(".navbar-collapse").addClass("show");n("#overlay").addClass("show");n("body").toggleClass("offcanvas-active")});n(".offcanvas-header .btn-close").click(function(){n(".navbar-collapse").removeClass("show");n("body").removeClass("offcanvas-active");n("#overlay").removeClass("show")});n(".modal").on("show.bs.modal",function(t){var r;if((u=n(t.relatedTarget),r=n(this),r.attr("inert")!=="true"&&!(r.closest('[inert="true"]').length>0))&&n(".modal:visible").last().is(this)){var f=r.find('input, button, select, textarea, a[href], [tabindex]:not([tabindex="-1"])'),e=f.first(),o=f.last();e.focus();f.on("keydown",function(t){t.key==="Tab"&&(t.shiftKey&&n(i.activeElement).is(e)?(t.preventDefault(),o.focus()):!t.shiftKey&&n(i.activeElement).is(o)&&(t.preventDefault(),e.focus()))})}});n(".modal").on("hide.bs.modal",function(){var t=n(this);t.find(":focus").blur();u?u.focus():n("body").focus()});n(".modal").on("hidden.bs.modal",function(){var t=n(this);t.find('input, button, select, textarea, a[href], [tabindex]:not([tabindex="-1"])').off("keydown");u=null});Main.enterKeyPressHandler("#siteSearch","#siteSearchBtn")},{init:e,enterKeyPressHandler:s,popupAlertNotice:o,searchSchedules:u}}(jQuery,window,document);$(function(){Main.init()}),function(n){n.serviceHostUrl=$("meta[name=web-service-uri]").attr("content")}(window),function(n,t){typeof define=="function"&&define.amd?define(["jQuery"],t):typeof exports=="object"?t(require("jQuery")):t(n.jQuery)}(this,function(){var r=function(){var t={},n=4,i=new RegExp("{{([^}]+)}}","g"),r=function(n){for(var t=[],r;r=i.exec(n);)t.push(r);return t};return t.parse=function(t){var f={inpts:{},chars:{}},e=r(t),s=t.length,u=0,o=0,i=0,h=function(t){for(var e=t.length,r=0;r<e;r++)f.inpts[o]=t.charAt(r),o++;u++;i+=t.length+n-1};for(i;i<s;i++)u<e.length&&i===e[u].index?h(e[u][1]):f.chars[i-u*n]=t.charAt(i);return f.mLength=i-u*n,f},t}(),t=function(){var n={},t=typeof navigator!="undefined"?navigator.userAgent:null;return n.extend=function(n){for(var i,t=1;t<arguments.length;t++)for(i in arguments[t])n[i]=arguments[t][i];return n},n.addChars=function(n,t,i){return n.substr(0,i)+t+n.substr(i,n.length)},n.removeChars=function(n,t,i){return n.substr(0,t)+n.substr(i,n.length)},n.isBetween=function(n,t){return t.sort(function(n,t){return n-t}),n>t[0]&&n<t[1]},n.addListener=function(n,t,i){return typeof n.addEventListener!="undefined"?n.addEventListener(t,i,!1):n.attachEvent("on"+t,i)},n.preventDefault=function(n){return n.preventDefault?n.preventDefault():n.returnValue=!1},n.getClip=function(n){return n.clipboardData?n.clipboardData.getData("Text"):window.clipboardData?window.clipboardData.getData("Text"):void 0},n.getMatchingKey=function(n,t,i){var r,u;for(r in i)if(u=i[r],n===u.which&&t===u.keyCode)return r},n.isDelKeyDown=function(t,i){return n.getMatchingKey(t,i,{backspace:{which:8,keyCode:8},"delete":{which:46,keyCode:46}})},n.isDelKeyPress=function(t,i){return n.getMatchingKey(t,i,{backspace:{which:8,keyCode:8,shiftKey:!1},"delete":{which:0,keyCode:46}})},n.isSpecialKeyPress=function(t,i){return n.getMatchingKey(t,i,{tab:{which:0,keyCode:9},enter:{which:13,keyCode:13},end:{which:0,keyCode:35},home:{which:0,keyCode:36},leftarrow:{which:0,keyCode:37},uparrow:{which:0,keyCode:38},rightarrow:{which:0,keyCode:39},downarrow:{which:0,keyCode:40},F5:{which:116,keyCode:116}})},n.isModifier=function(n){return n.ctrlKey||n.altKey||n.metaKey},n.forEach=function(n,t,i){var r,f,u;if(n.hasOwnProperty("length")){for(r=0,f=n.length;r<f;r++)if(t.call(i,n[r],r,n)===!1)break}else for(u in n)if(n.hasOwnProperty(u)&&t.call(i,n[u],u,n)===!1)break},n}(),u=function(n,t){function r(r){var u=[],f=[],e;return t.forEach(r,function(r){t.forEach(r,function(t,r){var e=n.parse(t),o=i(r);return u.push(o),f.push(e),!1})}),e=function(n){var i;return t.forEach(u,function(t,r){if(t.test(n))return i=r,!1}),i===undefined?null:f[i]},{getPattern:e,patterns:f,matchers:u}}var i=function(n){return n==="*"?/.*/:new RegExp(n)};return r}(r,t),f=function(){var n={};return n.get=function(n){var t;if(typeof n.selectionStart=="number")return{begin:n.selectionStart,end:n.selectionEnd};if(t=document.selection.createRange(),t&&t.parentElement()===n){var i=n.createTextRange(),u=n.createTextRange(),r=n.value.length;return(i.moveToBookmark(t.getBookmark()),u.collapse(!1),i.compareEndPoints("StartToEnd",u)>-1)?{begin:r,end:r}:{begin:-i.moveStart("character",-r),end:-i.moveEnd("character",-r)}}return{begin:0,end:0}},n.set=function(n,t){if(typeof t!="object"&&(t={begin:t,end:t}),n.setSelectionRange)n.focus(),n.setSelectionRange(t.begin,t.end);else if(n.createTextRange){var i=n.createTextRange();i.collapse(!0);i.moveEnd("character",t.end);i.moveStart("character",t.begin);i.select()}},n}(),i=function(n,t,i){function r(t,r){var u=this;if(u.el=t,!u.el)throw new TypeError("Must provide an existing element");if(u.opts=i.extend({},f,r),typeof u.opts.pattern!="undefined"&&(u.opts.patterns=u._specFromSinglePattern(u.opts.pattern),delete u.opts.pattern),typeof u.opts.patterns=="undefined")throw new TypeError("Must provide a pattern or array of patterns");u.patternMatcher=n(u.opts.patterns);u._updatePattern();u.hldrs={};u.focus=0;i.addListener(u.el,"keydown",function(n){u._keyDown(n)});i.addListener(u.el,"keypress",function(n){u._keyPress(n)});i.addListener(u.el,"paste",function(n){u._paste(n)});i.addListener(u.el,"input",function(n){if(u._keyPress(n),u.el!=null)if(u.el.createTextRange){var t=u.el.createTextRange();t.move("character",u.el.value.length);t.select()}else u.el.selectionStart?(u.el.focus(),u.el.setSelectionRange(u.el.value.length,u.el.value.length)):u.el.focus()});u.opts.persistent&&(u._processKey("",!1,!0),u.el.blur(),i.addListener(u.el,"focus",function(n){u._focus(n)}),i.addListener(u.el,"click",function(n){u._focus(n)}),i.addListener(u.el,"touchstart",function(n){u._focus(n)}))}var f={persistent:!1,repeat:!1,placeholder:" "},u={"9":/[0-9]/,a:/[A-Za-z]/,"*":/[A-Za-z0-9]/};return r.addInptType=function(n,t){u[n]=t},r.prototype.resetPattern=function(i){this.opts.patterns=i?this._specFromSinglePattern(i):this.opts.patterns;this.sel=t.get(this.el);this.val=this.el.value;this.delta=0;this._removeChars();this.patternMatcher=n(this.opts.patterns);var r=this.patternMatcher.getPattern(this.val);this.mLength=r.mLength;this.chars=r.chars;this.inpts=r.inpts;this._processKey("",!1,!0)},r.prototype._updatePattern=function(){var n=this.patternMatcher.getPattern(this.val);n&&(this.mLength=n.mLength,this.chars=n.chars,this.inpts=n.inpts)},r.prototype._keyDown=function(n){var t=n.which||n.keyCode;if(t&&i.isDelKeyDown(n.which,n.keyCode))return this._processKey(null,t),i.preventDefault(n)},r.prototype._keyPress=function(n){var t,r;return t=n.which||n.keyCode,r=i.isSpecialKeyPress(n.which,n.keyCode),!i.isDelKeyPress(n.which,n.keyCode)&&!r&&!i.isModifier(n)?(this._processKey(String.fromCharCode(t),!1),i.preventDefault(n)):void 0},r.prototype._paste=function(n){return this._processKey(i.getClip(n),!1),i.preventDefault(n)},r.prototype._focus=function(){var n=this;setTimeout(function(){var i=t.get(n.el),r=i.end>n.focus,u=i.end===0;(r||u)&&t.set(n.el,n.focus)},0)},r.prototype._processKey=function(n,r,u){if(this.sel=t.get(this.el),this.val=this.el.value,this.delta=0,this.sel.begin!==this.sel.end)this.delta=-1*Math.abs(this.sel.begin-this.sel.end),this.val=i.removeChars(this.val,this.sel.begin,this.sel.end);else if(r&&r===46)this._delete();else if(r&&this.sel.begin-1>=0)this.val=i.removeChars(this.val,this.sel.end-1,this.sel.end),this.delta-=1;else if(r)return!0;r||(this.val=i.addChars(this.val,n,this.sel.begin),this.delta+=n.length);this._formatValue(u)},r.prototype._delete=function(){while(this.chars[this.sel.begin])this._nextPos();this.sel.begin<this.val.length&&(this._nextPos(),this.val=i.removeChars(this.val,this.sel.end-1,this.sel.end),this.delta=-1)},r.prototype._nextPos=function(){this.sel.end++;this.sel.begin++},r.prototype._formatValue=function(n){this.newPos=this.sel.end+this.delta;this._removeChars();this._updatePattern();this._validateInpts();this._addChars();this.el.value=this.val.substr(0,this.mLength);(typeof n=="undefined"||n===!1)&&t.set(this.el,this.newPos)},r.prototype._removeChars=function(){var r,n;for(this.sel.end>this.focus&&(this.delta+=this.sel.end-this.focus),r=0,n=0;n<=this.mLength;n++){var f=this.chars[n],e=this.hldrs[n],t=n+r,u;t=n>=this.sel.begin?t+this.delta:t;u=this.val.charAt(t);(f&&f===u||e&&e===u)&&(this.val=i.removeChars(this.val,t,t+1),r--)}this.hldrs={};this.focus=this.val.length},r.prototype._validateInpts=function(){for(var n=0;n<this.val.length;n++){var t=this.inpts[n],r=!u[t],f=!r&&!u[t].test(this.val.charAt(n)),e=this.inpts[n];(r||f)&&e&&(this.val=i.removeChars(this.val,n,n+1),this.focusStart--,this.newPos--,this.delta--,n--)}},r.prototype._addChars=function(){var n,t;if(this.opts.persistent){for(n=0;n<=this.mLength;n++)this.val.charAt(n)||(this.val=i.addChars(this.val,this.opts.placeholder,n),this.hldrs[n]=this.opts.placeholder),this._addChar(n);while(this.chars[this.focus])this.focus++}else for(t=0;t<=this.val.length;t++){if(this.delta<=0&&t===this.focus)return!0;this._addChar(t)}},r.prototype._addChar=function(n){var t=this.chars[n];if(!t)return!0;i.isBetween(n,[this.sel.begin-1,this.newPos+1])&&(this.newPos++,this.delta++);n<=this.focus&&this.focus++;this.hldrs[n]&&(delete this.hldrs[n],this.hldrs[n+1]=this.opts.placeholder);this.val=i.addChars(this.val,t,n)},r.prototype._specFromSinglePattern=function(n){return[{"*":n}]},r}(u,f,t),n="formatter";$.fn[n]=function(t){return typeof t=="object"&&this.each(function(){$.data(this,"plugin_"+n)||$.data(this,"plugin_"+n,new i(this,t))}),this.resetPattern=function(t){return this.each(function(){var i=$.data(this,"plugin_"+n);i&&i.resetPattern(t)}),this},this};$.fn[n].addInptType=function(n,t){i.addInptType(n,t)}});$jscomp=$jscomp||{};$jscomp.scope={};$jscomp.findInternal=function(n,t,i){var f,r,u;for(n instanceof String&&(n=String(n)),f=n.length,r=0;r<f;r++)if(u=n[r],t.call(i,u,r,n))return{i:r,v:u};return{i:-1,v:void 0}};$jscomp.ASSUME_ES5=!1;$jscomp.ASSUME_NO_NATIVE_MAP=!1;$jscomp.ASSUME_NO_NATIVE_SET=!1;$jscomp.SIMPLE_FROUND_POLYFILL=!1;$jscomp.defineProperty=$jscomp.ASSUME_ES5||"function"==typeof Object.defineProperties?Object.defineProperty:function(n,t,i){n!=Array.prototype&&n!=Object.prototype&&(n[t]=i.value)};$jscomp.getGlobal=function(n){return"undefined"!=typeof window&&window===n?n:"undefined"!=typeof global&&null!=global?global:n};$jscomp.global=$jscomp.getGlobal(this);$jscomp.polyfill=function(n,t,i,r){if(t){for(i=$jscomp.global,n=n.split("."),r=0;r<n.length-1;r++){var u=n[r];u in i||(i[u]={});i=i[u]}n=n[n.length-1];r=i[n];t=t(r);t!=r&&null!=t&&$jscomp.defineProperty(i,n,{configurable:!0,writable:!0,value:t})}};$jscomp.polyfill("Array.prototype.find",function(n){return n?n:function(n,t){return $jscomp.findInternal(this,n,t).v}},"es6","es3"),function(n,t,i){"function"==typeof define&&define.amd?define(["jquery"],n):"object"==typeof exports&&"undefined"==typeof Meteor?module.exports=n(require("jquery")):n(t||i)}(function(n){var i=function(t,i,r){var u={invalid:[],getCaret:function(){var r;try{var n=0,e=t.get(0),f=document.selection,i=e.selectionStart;return f&&-1===navigator.appVersion.indexOf("MSIE 10")?(r=f.createRange(),r.moveStart("character",-u.val().length),n=r.text.length):(i||"0"===i)&&(n=i),n}catch(o){}},setCaret:function(n){var r,i;try{t.is(":focus")&&(r=t.get(0),r.setSelectionRange?r.setSelectionRange(n,n):(i=r.createTextRange(),i.collapse(!0),i.moveEnd("character",n),i.moveStart("character",n),i.select()))}catch(u){}},events:function(){t.on("keydown.mask",function(n){t.data("mask-keycode",n.keyCode||n.which);t.data("mask-previus-value",t.val());t.data("mask-previus-caret-pos",u.getCaret());u.maskDigitPosMapOld=u.maskDigitPosMap}).on(n.jMaskGlobals.useInput?"input.mask":"keyup.mask",u.behaviour).on("paste.mask drop.mask",function(){setTimeout(function(){t.keydown().keyup()},100)}).on("change.mask",function(){t.data("changed",!0)}).on("blur.mask",function(){e===u.val()||t.data("changed")||t.trigger("change");t.data("changed",!1)}).on("blur.mask",function(){e=u.val()}).on("focus.mask",function(t){!0===r.selectOnFocus&&n(t.target).select()}).on("focusout.mask",function(){r.clearIfNotMatch&&!o.test(u.val())&&u.val("")})},getRegexMask:function(){for(var n=[],t,e,o,r,u=0;u<i.length;u++)(t=f.translation[i.charAt(u)])?(e=t.pattern.toString().replace(/.{1}$|^.{1}/g,""),o=t.optional,(t=t.recursive)?(n.push(i.charAt(u)),r={digit:i.charAt(u),pattern:e}):n.push(o||t?e+"?":e)):n.push(i.charAt(u).replace(/[-\/\\^$*+?.()|[\]{}]/g,"\\$&"));return n=n.join(""),r&&(n=n.replace(new RegExp("("+r.digit+"(.*"+r.digit+")?)"),"($1)?").replace(new RegExp(r.digit,"g"),r.pattern)),new RegExp(n)},destroyEvents:function(){t.off("input keydown keyup paste drop blur focusout ".split(" ").join(".mask "))},val:function(n){var i=t.is("input")?"val":"text";return 0<arguments.length?(t[i]()!==n&&t[i](n),i=t):i=t[i](),i},calculateCaretPosition:function(n){var e=u.getMasked(),i=u.getCaret(),f;if(n!==e){f=t.data("mask-previus-caret-pos")||0;e=e.length;for(var h=n.length,c=n=0,o=0,s=0,r=i;r<e&&u.maskDigitPosMap[r];r++)c++;for(r=i-1;0<=r&&u.maskDigitPosMap[r];r--)n++;for(r=i-1;0<=r;r--)u.maskDigitPosMap[r]&&o++;for(r=f-1;0<=r;r--)u.maskDigitPosMapOld[r]&&s++;i>h?i=10*e:f>=i&&f!==h?u.maskDigitPosMapOld[i]||(f=i,i=i-(s-o)-n,u.maskDigitPosMap[i]&&(i=f)):i>f&&(i=i+(o-s)+c)}return i},behaviour:function(i){var r,e,o;return i=i||window.event,u.invalid=[],r=t.data("mask-keycode"),-1===n.inArray(r,f.byPassKeys)?(r=u.getMasked(),e=u.getCaret(),o=t.data("mask-previus-value")||"",setTimeout(function(){u.setCaret(u.calculateCaretPosition(o))},n.jMaskGlobals.keyStrokeCompensation),u.val(r),u.setCaret(e),u.callbacks(i)):void 0},getMasked:function(n,t){var h=[],nt=void 0===t?u.val():t+"",e=0,y=i.length,o=0,p=nt.length,s=1,w="push",l=-1,k=0,a,d,g;for(t=[],r.reverse?(w="unshift",s=-1,a=0,e=y-1,o=p-1,d=function(){return-1<e&&-1<o}):(a=y-1,d=function(){return e<y&&o<p});d();){var b=i.charAt(e),v=nt.charAt(o),c=f.translation[b];c?(v.match(c.pattern)?(h[w](v),c.recursive&&(-1===l?l=e:e===a&&e!==l&&(e=l-s),a===l&&(e-=s)),e+=s):v===g?(k--,g=void 0):c.optional?(e+=s,o-=s):c.fallback?(h[w](c.fallback),e+=s,o-=s):u.invalid.push({p:o,v:v,e:c.pattern}),o+=s):(n||h[w](b),v===b?(t.push(o),o+=s):(g=b,t.push(o+k),k++),e+=s)}return n=i.charAt(a),y!==p+1||f.translation[n]||h.push(n),h=h.join(""),u.mapMaskdigitPositions(h,t,p),h},mapMaskdigitPositions:function(n,t,i){for(n=r.reverse?n.length-i:0,u.maskDigitPosMap={},i=0;i<t.length;i++)u.maskDigitPosMap[t[i]+n]=1},callbacks:function(n){var f=u.val(),h=f!==e,s=[f,n,t,r],o=function(n,t,i){"function"==typeof r[n]&&t&&r[n].apply(this,i)};o("onChange",!0===h,s);o("onKeyPress",!0===h,s);o("onComplete",f.length===i.length,s);o("onInvalid",0<u.invalid.length,[f,n,t,u.invalid,r])}},f,e,o;t=n(t);f=this;e=u.val();i="function"==typeof i?i(u.val(),void 0,t,r):i;f.mask=i;f.options=r;f.remove=function(){var n=u.getCaret();return f.options.placeholder&&t.removeAttr("placeholder"),t.data("mask-maxlength")&&t.removeAttr("maxlength"),u.destroyEvents(),u.val(f.getCleanVal()),u.setCaret(n),t};f.getCleanVal=function(){return u.getMasked(!0)};f.getMaskedVal=function(n){return u.getMasked(!1,n)};f.init=function(e){var s,h;if(e=e||!1,r=r||{},f.clearIfNotMatch=n.jMaskGlobals.clearIfNotMatch,f.byPassKeys=n.jMaskGlobals.byPassKeys,f.translation=n.extend({},n.jMaskGlobals.translation,r.translation),f=n.extend(!0,{},f,r),o=u.getRegexMask(),e)u.events(),u.val(u.getMasked());else{for(r.placeholder&&t.attr("placeholder",r.placeholder),t.data("mask")&&t.attr("autocomplete","off"),e=0,s=!0;e<i.length;e++)if(h=f.translation[i.charAt(e)],h&&h.recursive){s=!1;break}s&&t.attr("maxlength",i.length).data("mask-maxlength",!0);u.destroyEvents();u.events();e=u.getCaret();u.val(u.getMasked());u.setCaret(e)}};f.init(!t.is("input"))};n.maskWatchers={};var u=function(){var t=n(this),u={},f=t.attr("data-mask");return t.attr("data-mask-reverse")&&(u.reverse=!0),t.attr("data-mask-clearifnotmatch")&&(u.clearIfNotMatch=!0),"true"===t.attr("data-mask-selectonfocus")&&(u.selectOnFocus=!0),r(t,f,u)?t.data("mask",new i(this,f,u)):void 0},r=function(t,i,r){r=r||{};var u=n(t).data("mask"),f=JSON.stringify;t=n(t).val()||n(t).text();try{return"function"==typeof i&&(i=i(t)),"object"!=typeof u||f(u.options)!==f(r)||u.mask!==i}catch(e){}},t=function(n){var i=document.createElement("div"),t;return n="on"+n,t=n in i,t||(i.setAttribute(n,"return;"),t="function"==typeof i[n]),t};n.fn.mask=function(t,u){var o;u=u||{};var f=this.selector,e=n.jMaskGlobals,s=e.watchInterval;return e=u.watchInputs||e.watchInputs,o=function(){if(r(this,t,u))return n(this).data("mask",new i(this,t,u))},n(this).each(o),f&&""!==f&&e&&(clearInterval(n.maskWatchers[f]),n.maskWatchers[f]=setInterval(function(){n(document).find(f).each(o)},s)),this};n.fn.masked=function(n){return this.data("mask").getMaskedVal(n)};n.fn.unmask=function(){return clearInterval(n.maskWatchers[this.selector]),delete n.maskWatchers[this.selector],this.each(function(){var t=n(this).data("mask");t&&t.remove().removeData("mask")})};n.fn.cleanVal=function(){return this.data("mask").getCleanVal()};n.applyDataMask=function(t){t=t||n.jMaskGlobals.maskElements;(t instanceof n?t:n(t)).filter(n.jMaskGlobals.dataMaskAttr).each(u)};t={maskElements:"input,td,span,div",dataMaskAttr:"*[data-mask]",dataMask:!0,watchInterval:300,watchInputs:!0,keyStrokeCompensation:10,useInput:!/Chrome\/[2-4][0-9]|SamsungBrowser/.test(window.navigator.userAgent)&&t("input"),watchDataMask:!1,byPassKeys:[9,16,17,18,36,37,38,39,40,91],translation:{0:{pattern:/\d/},9:{pattern:/\d/,optional:!0},"#":{pattern:/\d/,recursive:!0},A:{pattern:/[a-zA-Z0-9]/},S:{pattern:/[a-zA-Z]/}}};n.jMaskGlobals=n.jMaskGlobals||{};t=n.jMaskGlobals=n.extend(!0,{},t,n.jMaskGlobals);t.dataMask&&n.applyDataMask();setInterval(function(){n.jMaskGlobals.watchDataMask&&n.applyDataMask()},t.watchInterval)},window.jQuery,window.Zepto)