openc3-cosmos-tool-scriptrunner 5.5.2 → 5.6.0

Sign up to get free protection for your applications and to get access to all the features.
@@ -0,0 +1,51 @@
1
+ (self["webpackChunk_openc3_cosmos_tool_scriptrunner"]=self["webpackChunk_openc3_cosmos_tool_scriptrunner"]||[]).push([[807],{47146:function(e,t,n){"use strict";n.d(t,{ju:function(){return a},zD:function(){return b}});var r={logger:self.console,WebSocket:self.WebSocket},i={log(...e){this.enabled&&(e.push(Date.now()),r.logger.log("[ActionCable]",...e))}};const o=()=>(new Date).getTime(),s=e=>(o()-e)/1e3;class a{constructor(e){this.visibilityDidChange=this.visibilityDidChange.bind(this),this.connection=e,this.reconnectAttempts=0}start(){this.isRunning()||(this.startedAt=o(),delete this.stoppedAt,this.startPolling(),addEventListener("visibilitychange",this.visibilityDidChange),i.log(`ConnectionMonitor started. stale threshold = ${this.constructor.staleThreshold} s`))}stop(){this.isRunning()&&(this.stoppedAt=o(),this.stopPolling(),removeEventListener("visibilitychange",this.visibilityDidChange),i.log("ConnectionMonitor stopped"))}isRunning(){return this.startedAt&&!this.stoppedAt}recordPing(){this.pingedAt=o()}recordConnect(){this.reconnectAttempts=0,this.recordPing(),delete this.disconnectedAt,i.log("ConnectionMonitor recorded connect")}recordDisconnect(){this.disconnectedAt=o(),i.log("ConnectionMonitor recorded disconnect")}startPolling(){this.stopPolling(),this.poll()}stopPolling(){clearTimeout(this.pollTimeout)}poll(){this.pollTimeout=setTimeout((()=>{this.reconnectIfStale(),this.poll()}),this.getPollInterval())}getPollInterval(){const{staleThreshold:e,reconnectionBackoffRate:t}=this.constructor,n=Math.pow(1+t,Math.min(this.reconnectAttempts,10)),r=0===this.reconnectAttempts?1:t,i=r*Math.random();return 1e3*e*n*(1+i)}reconnectIfStale(){this.connectionIsStale()&&(i.log(`ConnectionMonitor detected stale connection. reconnectAttempts = ${this.reconnectAttempts}, time stale = ${s(this.refreshedAt)} s, stale threshold = ${this.constructor.staleThreshold} s`),this.reconnectAttempts++,this.disconnectedRecently()?i.log(`ConnectionMonitor skipping reopening recent disconnect. time disconnected = ${s(this.disconnectedAt)} s`):(i.log("ConnectionMonitor reopening"),this.connection.reopen()))}get refreshedAt(){return this.pingedAt?this.pingedAt:this.startedAt}connectionIsStale(){return s(this.refreshedAt)>this.constructor.staleThreshold}disconnectedRecently(){return this.disconnectedAt&&s(this.disconnectedAt)<this.constructor.staleThreshold}visibilityDidChange(){"visible"===document.visibilityState&&setTimeout((()=>{!this.connectionIsStale()&&this.connection.isOpen()||(i.log(`ConnectionMonitor reopening stale connection on visibilitychange. visibilityState = ${document.visibilityState}`),this.connection.reopen())}),200)}}a.staleThreshold=6,a.reconnectionBackoffRate=.15;var l={message_types:{welcome:"welcome",disconnect:"disconnect",ping:"ping",confirmation:"confirm_subscription",rejection:"reject_subscription"},disconnect_reasons:{unauthorized:"unauthorized",invalid_request:"invalid_request",server_restart:"server_restart"},default_mount_path:"/cable",protocols:["actioncable-v1-json","actioncable-unsupported"]};const{message_types:c,protocols:u}=l,h=u.slice(0,u.length-1),f=[].indexOf;class d{constructor(e){this.open=this.open.bind(this),this.consumer=e,this.subscriptions=this.consumer.subscriptions,this.monitor=new a(this),this.disconnected=!0}send(e){return!!this.isOpen()&&(this.webSocket.send(JSON.stringify(e)),!0)}open(){return this.isActive()?(i.log(`Attempted to open WebSocket, but existing socket is ${this.getState()}`),!1):(i.log(`Opening WebSocket, current state is ${this.getState()}, subprotocols: ${u}`),this.webSocket&&this.uninstallEventHandlers(),this.webSocket=new r.WebSocket(this.consumer.url,u),this.installEventHandlers(),this.monitor.start(),!0)}close({allowReconnect:e}={allowReconnect:!0}){if(e||this.monitor.stop(),this.isOpen())return this.webSocket.close()}reopen(){if(i.log(`Reopening WebSocket, current state is ${this.getState()}`),!this.isActive())return this.open();try{return this.close()}catch(e){i.log("Failed to reopen WebSocket",e)}finally{i.log(`Reopening WebSocket in ${this.constructor.reopenDelay}ms`),setTimeout(this.open,this.constructor.reopenDelay)}}getProtocol(){if(this.webSocket)return this.webSocket.protocol}isOpen(){return this.isState("open")}isActive(){return this.isState("open","connecting")}isProtocolSupported(){return f.call(h,this.getProtocol())>=0}isState(...e){return f.call(e,this.getState())>=0}getState(){if(this.webSocket)for(let e in r.WebSocket)if(r.WebSocket[e]===this.webSocket.readyState)return e.toLowerCase();return null}installEventHandlers(){for(let e in this.events){const t=this.events[e].bind(this);this.webSocket[`on${e}`]=t}}uninstallEventHandlers(){for(let e in this.events)this.webSocket[`on${e}`]=function(){}}}d.reopenDelay=500,d.prototype.events={message(e){if(!this.isProtocolSupported())return;const{identifier:t,message:n,reason:r,reconnect:o,type:s}=JSON.parse(e.data);switch(s){case c.welcome:return this.monitor.recordConnect(),this.subscriptions.reload();case c.disconnect:return i.log(`Disconnecting. Reason: ${r}`),this.close({allowReconnect:o});case c.ping:return this.monitor.recordPing();case c.confirmation:return this.subscriptions.confirmSubscription(t),this.subscriptions.notify(t,"connected");case c.rejection:return this.subscriptions.reject(t);default:return this.subscriptions.notify(t,"received",n)}},open(){if(i.log(`WebSocket onopen event, using '${this.getProtocol()}' subprotocol`),this.disconnected=!1,!this.isProtocolSupported())return i.log("Protocol is unsupported. Stopping monitor and disconnecting."),this.close({allowReconnect:!1})},close(e){if(i.log("WebSocket onclose event"),!this.disconnected)return this.disconnected=!0,this.monitor.recordDisconnect(),this.subscriptions.notifyAll("disconnected",{willAttemptReconnect:this.monitor.isRunning()})},error(){i.log("WebSocket onerror event")}};const p=function(e,t){if(null!=t)for(let n in t){const r=t[n];e[n]=r}return e};class g{constructor(e,t={},n){this.consumer=e,this.identifier=JSON.stringify(t),p(this,n)}perform(e,t={}){return t.action=e,this.send(t)}send(e){return this.consumer.send({command:"message",identifier:this.identifier,data:JSON.stringify(e)})}unsubscribe(){return this.consumer.subscriptions.remove(this)}}class m{constructor(e){this.subscriptions=e,this.pendingSubscriptions=[]}guarantee(e){-1==this.pendingSubscriptions.indexOf(e)?(i.log(`SubscriptionGuarantor guaranteeing ${e.identifier}`),this.pendingSubscriptions.push(e)):i.log(`SubscriptionGuarantor already guaranteeing ${e.identifier}`),this.startGuaranteeing()}forget(e){i.log(`SubscriptionGuarantor forgetting ${e.identifier}`),this.pendingSubscriptions=this.pendingSubscriptions.filter((t=>t!==e))}startGuaranteeing(){this.stopGuaranteeing(),this.retrySubscribing()}stopGuaranteeing(){clearTimeout(this.retryTimeout)}retrySubscribing(){this.retryTimeout=setTimeout((()=>{this.subscriptions&&"function"===typeof this.subscriptions.subscribe&&this.pendingSubscriptions.map((e=>{i.log(`SubscriptionGuarantor resubscribing ${e.identifier}`),this.subscriptions.subscribe(e)}))}),500)}}class v{constructor(e){this.consumer=e,this.guarantor=new m(this),this.subscriptions=[]}create(e,t){const n=e,r="object"===typeof n?n:{channel:n},i=new g(this.consumer,r,t);return this.add(i)}add(e){return this.subscriptions.push(e),this.consumer.ensureActiveConnection(),this.notify(e,"initialized"),this.subscribe(e),e}remove(e){return this.forget(e),this.findAll(e.identifier).length||this.sendCommand(e,"unsubscribe"),e}reject(e){return this.findAll(e).map((e=>(this.forget(e),this.notify(e,"rejected"),e)))}forget(e){return this.guarantor.forget(e),this.subscriptions=this.subscriptions.filter((t=>t!==e)),e}findAll(e){return this.subscriptions.filter((t=>t.identifier===e))}reload(){return this.subscriptions.map((e=>this.subscribe(e)))}notifyAll(e,...t){return this.subscriptions.map((n=>this.notify(n,e,...t)))}notify(e,t,...n){let r;return r="string"===typeof e?this.findAll(e):[e],r.map((e=>"function"===typeof e[t]?e[t](...n):void 0))}subscribe(e){this.sendCommand(e,"subscribe")&&this.guarantor.guarantee(e)}confirmSubscription(e){i.log(`Subscription confirmed ${e}`),this.findAll(e).map((e=>this.guarantor.forget(e)))}sendCommand(e,t){const{identifier:n}=e;return this.consumer.send({command:t,identifier:n})}}class y{constructor(e){this._url=e,this.subscriptions=new v(this),this.connection=new d(this)}get url(){return w(this._url)}send(e){return this.connection.send(e)}connect(){return this.connection.open()}disconnect(){return this.connection.close({allowReconnect:!1})}ensureActiveConnection(){if(!this.connection.isActive())return this.connection.open()}}function w(e){if("function"===typeof e&&(e=e()),e&&!/^wss?:/i.test(e)){const t=document.createElement("a");return t.href=e,t.href=t.href,t.protocol=t.protocol.replace("http","ws"),t.href}return e}function b(e=x("url")||l.default_mount_path){return new y(e)}function x(e){const t=document.head.querySelector(`meta[name='action-cable-${e}']`);if(t)return t.getAttribute("content")}},83923:function(e,t,n){e=n.nmd(e),ace.define("ace/snippets",["require","exports","module","ace/lib/dom","ace/lib/oop","ace/lib/event_emitter","ace/lib/lang","ace/range","ace/range_list","ace/keyboard/hash_handler","ace/tokenizer","ace/clipboard","ace/editor"],(function(e,t,n){"use strict";function r(e){var t=(new Date).toLocaleString("en-us",e);return 1==t.length?"0"+t:t}var i=e("./lib/dom"),o=e("./lib/oop"),s=e("./lib/event_emitter").EventEmitter,a=e("./lib/lang"),l=e("./range").Range,c=e("./range_list").RangeList,u=e("./keyboard/hash_handler").HashHandler,h=e("./tokenizer").Tokenizer,f=e("./clipboard"),d={CURRENT_WORD:function(e){return e.session.getTextRange(e.session.getWordRange())},SELECTION:function(e,t,n){var r=e.session.getTextRange();return n?r.replace(/\n\r?([ \t]*\S)/g,"\n"+n+"$1"):r},CURRENT_LINE:function(e){return e.session.getLine(e.getCursorPosition().row)},PREV_LINE:function(e){return e.session.getLine(e.getCursorPosition().row-1)},LINE_INDEX:function(e){return e.getCursorPosition().row},LINE_NUMBER:function(e){return e.getCursorPosition().row+1},SOFT_TABS:function(e){return e.session.getUseSoftTabs()?"YES":"NO"},TAB_SIZE:function(e){return e.session.getTabSize()},CLIPBOARD:function(e){return f.getText&&f.getText()},FILENAME:function(e){return/[^/\\]*$/.exec(this.FILEPATH(e))[0]},FILENAME_BASE:function(e){return/[^/\\]*$/.exec(this.FILEPATH(e))[0].replace(/\.[^.]*$/,"")},DIRECTORY:function(e){return this.FILEPATH(e).replace(/[^/\\]*$/,"")},FILEPATH:function(e){return"/not implemented.txt"},WORKSPACE_NAME:function(){return"Unknown"},FULLNAME:function(){return"Unknown"},BLOCK_COMMENT_START:function(e){var t=e.session.$mode||{};return t.blockComment&&t.blockComment.start||""},BLOCK_COMMENT_END:function(e){var t=e.session.$mode||{};return t.blockComment&&t.blockComment.end||""},LINE_COMMENT:function(e){var t=e.session.$mode||{};return t.lineCommentStart||""},CURRENT_YEAR:r.bind(null,{year:"numeric"}),CURRENT_YEAR_SHORT:r.bind(null,{year:"2-digit"}),CURRENT_MONTH:r.bind(null,{month:"numeric"}),CURRENT_MONTH_NAME:r.bind(null,{month:"long"}),CURRENT_MONTH_NAME_SHORT:r.bind(null,{month:"short"}),CURRENT_DATE:r.bind(null,{day:"2-digit"}),CURRENT_DAY_NAME:r.bind(null,{weekday:"long"}),CURRENT_DAY_NAME_SHORT:r.bind(null,{weekday:"short"}),CURRENT_HOUR:r.bind(null,{hour:"2-digit",hour12:!1}),CURRENT_MINUTE:r.bind(null,{minute:"2-digit"}),CURRENT_SECOND:r.bind(null,{second:"2-digit"})};d.SELECTED_TEXT=d.SELECTION;var p=function(){this.snippetMap={},this.snippetNameMap={}};(function(){o.implement(this,s),this.getTokenizer=function(){return p.$tokenizer||this.createTokenizer()},this.createTokenizer=function(){function e(e){return e=e.substr(1),/^\d+$/.test(e)?[{tabstopId:parseInt(e,10)}]:[{text:e}]}function t(e){return"(?:[^\\\\"+e+"]|\\\\.)"}var n={regex:"/("+t("/")+"+)/",onMatch:function(e,t,n){var r=n[0];return r.fmtString=!0,r.guard=e.slice(1,-1),r.flag="",""},next:"formatString"};return p.$tokenizer=new h({start:[{regex:/\\./,onMatch:function(e,t,n){var r=e[1];return("}"==r&&n.length||-1!="`$\\".indexOf(r))&&(e=r),[e]}},{regex:/}/,onMatch:function(e,t,n){return[n.length?n.shift():e]}},{regex:/\$(?:\d+|\w+)/,onMatch:e},{regex:/\$\{[\dA-Z_a-z]+/,onMatch:function(t,n,r){var i=e(t.substr(1));return r.unshift(i[0]),i},next:"snippetVar"},{regex:/\n/,token:"newline",merge:!1}],snippetVar:[{regex:"\\|"+t("\\|")+"*\\|",onMatch:function(e,t,n){var r=e.slice(1,-1).replace(/\\[,|\\]|,/g,(function(e){return 2==e.length?e[1]:"\0"})).split("\0").map((function(e){return{value:e}}));return n[0].choices=r,[r[0]]},next:"start"},n,{regex:"([^:}\\\\]|\\\\.)*:?",token:"",next:"start"}],formatString:[{regex:/:/,onMatch:function(e,t,n){return n.length&&n[0].expectElse?(n[0].expectElse=!1,n[0].ifEnd={elseEnd:n[0]},[n[0].ifEnd]):":"}},{regex:/\\./,onMatch:function(e,t,n){var r=e[1];return"}"==r&&n.length||-1!="`$\\".indexOf(r)?e=r:"n"==r?e="\n":"t"==r?e="\t":-1!="ulULE".indexOf(r)&&(e={changeCase:r,local:r>"a"}),[e]}},{regex:"/\\w*}",onMatch:function(e,t,n){var r=n.shift();return r&&(r.flag=e.slice(1,-1)),this.next=r&&r.tabstopId?"start":"",[r||e]},next:"start"},{regex:/\$(?:\d+|\w+)/,onMatch:function(e,t,n){return[{text:e.slice(1)}]}},{regex:/\${\w+/,onMatch:function(e,t,n){var r={text:e.slice(2)};return n.unshift(r),[r]},next:"formatStringVar"},{regex:/\n/,token:"newline",merge:!1},{regex:/}/,onMatch:function(e,t,n){var r=n.shift();return this.next=r&&r.tabstopId?"start":"",[r||e]},next:"start"}],formatStringVar:[{regex:/:\/\w+}/,onMatch:function(e,t,n){var r=n[0];return r.formatFunction=e.slice(2,-1),[n.shift()]},next:"formatString"},n,{regex:/:[\?\-+]?/,onMatch:function(e,t,n){"+"==e[1]&&(n[0].ifEnd=n[0]),"?"==e[1]&&(n[0].expectElse=!0)},next:"formatString"},{regex:"([^:}\\\\]|\\\\.)*:?",token:"",next:"formatString"}]}),p.$tokenizer},this.tokenizeTmSnippet=function(e,t){return this.getTokenizer().getLineTokens(e,t).tokens.map((function(e){return e.value||e}))},this.getVariableValue=function(e,t,n){if(/^\d+$/.test(t))return(this.variables.__||{})[t]||"";if(/^[A-Z]\d+$/.test(t))return(this.variables[t[0]+"__"]||{})[t.substr(1)]||"";if(t=t.replace(/^TM_/,""),!this.variables.hasOwnProperty(t))return"";var r=this.variables[t];return"function"==typeof r&&(r=this.variables[t](e,t,n)),null==r?"":r},this.variables=d,this.tmStrFormat=function(e,t,n){if(!t.fmt)return e;var r=t.flag||"",i=t.guard;i=new RegExp(i,r.replace(/[^gim]/g,""));var o="string"==typeof t.fmt?this.tokenizeTmSnippet(t.fmt,"formatString"):t.fmt,s=this,a=e.replace(i,(function(){var e=s.variables.__;s.variables.__=[].slice.call(arguments);for(var t=s.resolveVariables(o,n),r="E",i=0;i<t.length;i++){var a=t[i];if("object"==typeof a)if(t[i]="",a.changeCase&&a.local){var l=t[i+1];l&&"string"==typeof l&&("u"==a.changeCase?t[i]=l[0].toUpperCase():t[i]=l[0].toLowerCase(),t[i+1]=l.substr(1))}else a.changeCase&&(r=a.changeCase);else"U"==r?t[i]=a.toUpperCase():"L"==r&&(t[i]=a.toLowerCase())}return s.variables.__=e,t.join("")}));return a},this.tmFormatFunction=function(e,t,n){return"upcase"==t.formatFunction?e.toUpperCase():"downcase"==t.formatFunction?e.toLowerCase():e},this.resolveVariables=function(e,t){function n(t){var n=e.indexOf(t,s+1);-1!=n&&(s=n)}for(var r=[],i="",o=!0,s=0;s<e.length;s++){var a=e[s];if("string"!=typeof a){if(a){if(o=!1,a.fmtString){var l=e.indexOf(a,s+1);-1==l&&(l=e.length),a.fmt=e.slice(s+1,l),s=l}if(a.text){var c=this.getVariableValue(t,a.text,i)+"";a.fmtString&&(c=this.tmStrFormat(c,a,t)),a.formatFunction&&(c=this.tmFormatFunction(c,a,t)),c&&!a.ifEnd?(r.push(c),n(a)):!c&&a.ifEnd&&n(a.ifEnd)}else a.elseEnd?n(a.elseEnd):(null!=a.tabstopId||null!=a.changeCase)&&r.push(a)}}else r.push(a),"\n"==a?(o=!0,i=""):o&&(i=/^\t*/.exec(a)[0],o=/\S/.test(a))}return r};var e=function(e,t,n){function r(e){for(var t=[],n=0;n<e.length;n++){var r=e[n];if("object"==typeof r){if(u[r.tabstopId])continue;var i=e.lastIndexOf(r,n-1);r=t[i]||{tabstopId:r.tabstopId}}t[n]=r}return t}var i=e.getCursorPosition(),o=e.session.getLine(i.row),s=e.session.getTabString(),a=o.match(/^\s*/)[0];i.column<a.length&&(a=a.slice(0,i.column)),t=t.replace(/\r/g,"");var l=this.tokenizeTmSnippet(t);l=this.resolveVariables(l,e),l=l.map((function(e){return"\n"==e?e+a:"string"==typeof e?e.replace(/\t/g,s):e}));var c=[];l.forEach((function(e,t){if("object"==typeof e){var n=e.tabstopId,r=c[n];if(r||(r=c[n]=[],r.index=n,r.value="",r.parents={}),-1===r.indexOf(e)){e.choices&&!r.choices&&(r.choices=e.choices),r.push(e);var i=l.indexOf(e,t+1);if(-1!==i){var o=l.slice(t+1,i),s=o.some((function(e){return"object"==typeof e}));s&&!r.value?r.value=o:o.length&&(!r.value||"string"!=typeof r.value)&&(r.value=o.join(""))}}}})),c.forEach((function(e){e.length=0}));for(var u={},h=0;h<l.length;h++){var f=l[h];if("object"==typeof f){var d=f.tabstopId,p=c[d],g=l.indexOf(f,h+1);if(u[d])u[d]===f&&(delete u[d],Object.keys(u).forEach((function(e){p.parents[e]=!0})));else{u[d]=f;var m=p.value;"string"!=typeof m?m=r(m):f.fmt&&(m=this.tmStrFormat(m,f,e)),l.splice.apply(l,[h+1,Math.max(0,g-h)].concat(m,f)),-1===p.indexOf(f)&&p.push(f)}}}var v=0,y=0,w="";return l.forEach((function(e){if("string"==typeof e){var t=e.split("\n");t.length>1?(y=t[t.length-1].length,v+=t.length-1):y+=e.length,w+=e}else e&&(e.start?e.end={row:v,column:y}:e.start={row:v,column:y})})),{text:w,tabstops:c,tokens:l}};this.getDisplayTextForSnippet=function(t,n){var r=e.call(this,t,n);return r.text},this.insertSnippetForSelection=function(t,n,r){var i=e.call(this,t,n),o=t.getSelectionRange();r&&0===r.compareRange(o)&&(o=r);var s=t.session.replace(o,i.text),a=new g(t),l=t.inVirtualSelectionMode&&t.selection.index;a.addTabstops(i.tabstops,o.start,s,l)},this.insertSnippet=function(e,t,n){var r=this;if(e.inVirtualSelectionMode)return r.insertSnippetForSelection(e,t,n);e.forEachSelection((function(){r.insertSnippetForSelection(e,t,n)}),null,{keepOrder:!0}),e.tabstopManager&&e.tabstopManager.tabNext()},this.$getScope=function(e){var t=e.session.$mode.$id||"";if(t=t.split("/").pop(),"html"===t||"php"===t){"php"===t&&!e.session.$mode.inlinePhp&&(t="html");var n=e.getCursorPosition(),r=e.session.getState(n.row);"object"==typeof r&&(r=r[0]),r.substring&&("js-"==r.substring(0,3)?t="javascript":"css-"==r.substring(0,4)?t="css":"php-"==r.substring(0,4)&&(t="php"))}return t},this.getActiveScopes=function(e){var t=this.$getScope(e),n=[t],r=this.snippetMap;return r[t]&&r[t].includeScopes&&n.push.apply(n,r[t].includeScopes),n.push("_"),n},this.expandWithTab=function(e,t){var n=this,r=e.forEachSelection((function(){return n.expandSnippetForSelection(e,t)}),null,{keepOrder:!0});return r&&e.tabstopManager&&e.tabstopManager.tabNext(),r},this.expandSnippetForSelection=function(e,t){var n,r=e.getCursorPosition(),i=e.session.getLine(r.row),o=i.substring(0,r.column),s=i.substr(r.column),a=this.snippetMap;return this.getActiveScopes(e).some((function(e){var t=a[e];return t&&(n=this.findMatchingSnippet(t,o,s)),!!n}),this),!!n&&(t&&t.dryRun||(e.session.doc.removeInLine(r.row,r.column-n.replaceBefore.length,r.column+n.replaceAfter.length),this.variables.M__=n.matchBefore,this.variables.T__=n.matchAfter,this.insertSnippetForSelection(e,n.content),this.variables.M__=this.variables.T__=null),!0)},this.findMatchingSnippet=function(e,t,n){for(var r=e.length;r--;){var i=e[r];if((!i.startRe||i.startRe.test(t))&&((!i.endRe||i.endRe.test(n))&&(i.startRe||i.endRe)))return i.matchBefore=i.startRe?i.startRe.exec(t):[""],i.matchAfter=i.endRe?i.endRe.exec(n):[""],i.replaceBefore=i.triggerRe?i.triggerRe.exec(t)[0]:"",i.replaceAfter=i.endTriggerRe?i.endTriggerRe.exec(n)[0]:"",i}},this.snippetMap={},this.snippetNameMap={},this.register=function(e,t){function n(e){return e&&!/^\^?\(.*\)\$?$|^\\b$/.test(e)&&(e="(?:"+e+")"),e||""}function r(e,t,r){return e=n(e),t=n(t),r?(e=t+e,e&&"$"!=e[e.length-1]&&(e+="$")):(e+=t,e&&"^"!=e[0]&&(e="^"+e)),new RegExp(e)}function i(e){e.scope||(e.scope=t||"_"),t=e.scope,o[t]||(o[t]=[],s[t]={});var n=s[t];if(e.name){var i=n[e.name];i&&l.unregister(i),n[e.name]=e}o[t].push(e),e.prefix&&(e.tabTrigger=e.prefix),!e.content&&e.body&&(e.content=Array.isArray(e.body)?e.body.join("\n"):e.body),e.tabTrigger&&!e.trigger&&(!e.guard&&/^\w/.test(e.tabTrigger)&&(e.guard="\\b"),e.trigger=a.escapeRegExp(e.tabTrigger)),(e.trigger||e.guard||e.endTrigger||e.endGuard)&&(e.startRe=r(e.trigger,e.guard,!0),e.triggerRe=new RegExp(e.trigger),e.endRe=r(e.endTrigger,e.endGuard,!0),e.endTriggerRe=new RegExp(e.endTrigger))}var o=this.snippetMap,s=this.snippetNameMap,l=this;e||(e=[]),Array.isArray(e)?e.forEach(i):Object.keys(e).forEach((function(t){i(e[t])})),this._signal("registerSnippets",{scope:t})},this.unregister=function(e,t){function n(e){var n=i[e.scope||t];if(n&&n[e.name]){delete n[e.name];var o=r[e.scope||t],s=o&&o.indexOf(e);s>=0&&o.splice(s,1)}}var r=this.snippetMap,i=this.snippetNameMap;e.content?n(e):Array.isArray(e)&&e.forEach(n)},this.parseSnippetFile=function(e){e=e.replace(/\r/g,"");var t,n=[],r={},i=/^#.*|^({[\s\S]*})\s*$|^(\S+) (.*)$|^((?:\n*\t.*)+)/gm;while(t=i.exec(e)){if(t[1])try{r=JSON.parse(t[1]),n.push(r)}catch(s){}if(t[4])r.content=t[4].replace(/^\t/gm,""),n.push(r),r={};else{var o=t[2],a=t[3];if("regex"==o){var l=/\/((?:[^\/\\]|\\.)*)|$/g;r.guard=l.exec(a)[1],r.trigger=l.exec(a)[1],r.endTrigger=l.exec(a)[1],r.endGuard=l.exec(a)[1]}else"snippet"==o?(r.tabTrigger=a.match(/^\S*/)[0],r.name||(r.name=a)):o&&(r[o]=a)}}return n},this.getSnippetByName=function(e,t){var n,r=this.snippetNameMap;return this.getActiveScopes(t).some((function(t){var i=r[t];return i&&(n=i[e]),!!n}),this),n}}).call(p.prototype);var g=function(e){if(e.tabstopManager)return e.tabstopManager;e.tabstopManager=this,this.$onChange=this.onChange.bind(this),this.$onChangeSelection=a.delayedCall(this.onChangeSelection.bind(this)).schedule,this.$onChangeSession=this.onChangeSession.bind(this),this.$onAfterExec=this.onAfterExec.bind(this),this.attach(e)};(function(){this.attach=function(e){this.index=0,this.ranges=[],this.tabstops=[],this.$openTabstops=null,this.selectedTabstop=null,this.editor=e,this.editor.on("change",this.$onChange),this.editor.on("changeSelection",this.$onChangeSelection),this.editor.on("changeSession",this.$onChangeSession),this.editor.commands.on("afterExec",this.$onAfterExec),this.editor.keyBinding.addKeyboardHandler(this.keyboardHandler)},this.detach=function(){this.tabstops.forEach(this.removeTabstopMarkers,this),this.ranges=null,this.tabstops=null,this.selectedTabstop=null,this.editor.removeListener("change",this.$onChange),this.editor.removeListener("changeSelection",this.$onChangeSelection),this.editor.removeListener("changeSession",this.$onChangeSession),this.editor.commands.removeListener("afterExec",this.$onAfterExec),this.editor.keyBinding.removeKeyboardHandler(this.keyboardHandler),this.editor.tabstopManager=null,this.editor=null},this.onChange=function(e){for(var t="r"==e.action[0],n=this.selectedTabstop||{},r=n.parents||{},i=(this.tabstops||[]).slice(),o=0;o<i.length;o++){var s=i[o],a=s==n||r[s.index];if(s.rangeList.$bias=a?0:1,"remove"==e.action&&s!==n){var l=s.parents&&s.parents[n.index],c=s.rangeList.pointIndex(e.start,l);c=c<0?-c-1:c+1;var u=s.rangeList.pointIndex(e.end,l);u=u<0?-u-1:u-1;for(var h=s.rangeList.ranges.slice(c,u),f=0;f<h.length;f++)this.removeRange(h[f])}s.rangeList.$onChange(e)}var d=this.editor.session;!this.$inChange&&t&&1==d.getLength()&&!d.getValue()&&this.detach()},this.updateLinkedFields=function(){var e=this.selectedTabstop;if(e&&e.hasLinkedRanges&&e.firstNonLinked){this.$inChange=!0;for(var n=this.editor.session,r=n.getTextRange(e.firstNonLinked),i=0;i<e.length;i++){var o=e[i];if(o.linked){var s=o.original,a=t.snippetManager.tmStrFormat(r,s,this.editor);n.replace(o,a)}}this.$inChange=!1}},this.onAfterExec=function(e){e.command&&!e.command.readOnly&&this.updateLinkedFields()},this.onChangeSelection=function(){if(this.editor){for(var e=this.editor.selection.lead,t=this.editor.selection.anchor,n=this.editor.selection.isEmpty(),r=0;r<this.ranges.length;r++)if(!this.ranges[r].linked){var i=this.ranges[r].contains(e.row,e.column),o=n||this.ranges[r].contains(t.row,t.column);if(i&&o)return}this.detach()}},this.onChangeSession=function(){this.detach()},this.tabNext=function(e){var t=this.tabstops.length,n=this.index+(e||1);n=Math.min(Math.max(n,1),t),n==t&&(n=0),this.selectTabstop(n),0===n&&this.detach()},this.selectTabstop=function(e){this.$openTabstops=null;var t=this.tabstops[this.index];if(t&&this.addTabstopMarkers(t),this.index=e,t=this.tabstops[this.index],t&&t.length){this.selectedTabstop=t;var n=t.firstNonLinked||t;if(t.choices&&(n.cursor=n.start),this.editor.inVirtualSelectionMode)this.editor.selection.fromOrientedRange(n);else{var r=this.editor.multiSelect;r.toSingleRange(n);for(var i=0;i<t.length;i++)t.hasLinkedRanges&&t[i].linked||r.addRange(t[i].clone(),!0)}this.editor.keyBinding.addKeyboardHandler(this.keyboardHandler),this.selectedTabstop&&this.selectedTabstop.choices&&this.editor.execCommand("startAutocomplete",{matches:this.selectedTabstop.choices})}},this.addTabstops=function(e,t,n){var r=this.useLink||!this.editor.getOption("enableMultiselect");if(this.$openTabstops||(this.$openTabstops=[]),!e[0]){var i=l.fromPoints(n,n);v(i.start,t),v(i.end,t),e[0]=[i],e[0].index=0}var o=this.index,s=[o+1,0],a=this.ranges;e.forEach((function(e,n){for(var i=this.$openTabstops[n]||e,o=0;o<e.length;o++){var u=e[o],h=l.fromPoints(u.start,u.end||u.start);m(h.start,t),m(h.end,t),h.original=u,h.tabstop=i,a.push(h),i!=e?i.unshift(h):i[o]=h,u.fmtString||i.firstNonLinked&&r?(h.linked=!0,i.hasLinkedRanges=!0):i.firstNonLinked||(i.firstNonLinked=h)}i.firstNonLinked||(i.hasLinkedRanges=!1),i===e&&(s.push(i),this.$openTabstops[n]=i),this.addTabstopMarkers(i),i.rangeList=i.rangeList||new c,i.rangeList.$bias=0,i.rangeList.addList(i)}),this),s.length>2&&(this.tabstops.length&&s.push(s.splice(2,1)[0]),this.tabstops.splice.apply(this.tabstops,s))},this.addTabstopMarkers=function(e){var t=this.editor.session;e.forEach((function(e){e.markerId||(e.markerId=t.addMarker(e,"ace_snippet-marker","text"))}))},this.removeTabstopMarkers=function(e){var t=this.editor.session;e.forEach((function(e){t.removeMarker(e.markerId),e.markerId=null}))},this.removeRange=function(e){var t=e.tabstop.indexOf(e);-1!=t&&e.tabstop.splice(t,1),t=this.ranges.indexOf(e),-1!=t&&this.ranges.splice(t,1),t=e.tabstop.rangeList.ranges.indexOf(e),-1!=t&&e.tabstop.splice(t,1),this.editor.session.removeMarker(e.markerId),e.tabstop.length||(t=this.tabstops.indexOf(e.tabstop),-1!=t&&this.tabstops.splice(t,1),this.tabstops.length||this.detach())},this.keyboardHandler=new u,this.keyboardHandler.bindKeys({Tab:function(e){t.snippetManager&&t.snippetManager.expandWithTab(e)||(e.tabstopManager.tabNext(1),e.renderer.scrollCursorIntoView())},"Shift-Tab":function(e){e.tabstopManager.tabNext(-1),e.renderer.scrollCursorIntoView()},Esc:function(e){e.tabstopManager.detach()}})}).call(g.prototype);var m=function(e,t){0==e.row&&(e.column+=t.column),e.row+=t.row},v=function(e,t){e.row==t.row&&(e.column-=t.column),e.row-=t.row};i.importCssString("\n.ace_snippet-marker {\n -moz-box-sizing: border-box;\n box-sizing: border-box;\n background: rgba(194, 193, 208, 0.09);\n border: 1px dotted rgba(211, 208, 235, 0.62);\n position: absolute;\n}","snippets.css",!1),t.snippetManager=new p;var y=e("./editor").Editor;(function(){this.insertSnippet=function(e,n){return t.snippetManager.insertSnippet(this,e,n)},this.expandSnippet=function(e){return t.snippetManager.expandWithTab(this,e)}}).call(y.prototype)})),ace.define("ace/autocomplete/popup",["require","exports","module","ace/virtual_renderer","ace/editor","ace/range","ace/lib/event","ace/lib/lang","ace/lib/dom"],(function(e,t,n){"use strict";var r=e("../virtual_renderer").VirtualRenderer,i=e("../editor").Editor,o=e("../range").Range,s=e("../lib/event"),a=e("../lib/lang"),l=e("../lib/dom"),c=function(e){return"suggest-aria-id:".concat(e)},u=function(e){var t=new r(e);t.$maxLines=4;var n=new i(t);return n.setHighlightActiveLine(!1),n.setShowPrintMargin(!1),n.renderer.setShowGutter(!1),n.renderer.setHighlightGutterLine(!1),n.$mouseHandler.$focusTimeout=0,n.$highlightTagPending=!0,n},h=function(){function e(e){var t=l.createElement("div"),n=new u(t);e&&e.appendChild(t),t.style.display="none",n.renderer.content.style.cursor="default",n.renderer.setStyle("ace_autocomplete"),n.renderer.container.setAttribute("role","listbox"),n.renderer.container.setAttribute("aria-label","Autocomplete suggestions"),n.setOption("displayIndentGuides",!1),n.setOption("dragDelay",150);var r=function(){};n.focus=r,n.$isFocused=!0,n.renderer.$cursorLayer.restartTimer=r,n.renderer.$cursorLayer.element.style.opacity=0,n.renderer.$maxLines=8,n.renderer.$keepTextAreaAtCursor=!1,n.setHighlightActiveLine(!1),n.session.highlight(""),n.session.$searchHighlight.clazz="ace_highlight-marker",n.on("mousedown",(function(e){var t=e.getDocumentPosition();n.selection.moveToPosition(t),f.start.row=f.end.row=t.row,e.stop()}));var i,h=new o(-1,0,-1,1/0),f=new o(-1,0,-1,1/0);f.id=n.session.addMarker(f,"ace_active-line","fullLine"),n.setSelectOnHover=function(e){e?h.id&&(n.session.removeMarker(h.id),h.id=null):h.id=n.session.addMarker(h,"ace_line-hover","fullLine")},n.setSelectOnHover(!1),n.on("mousemove",(function(e){if(i){if(i.x!=e.x||i.y!=e.y){i=e,i.scrollTop=n.renderer.scrollTop;var t=i.getDocumentPosition().row;h.start.row!=t&&(h.id||n.setRow(t),p(t))}}else i=e})),n.renderer.on("beforeRender",(function(){if(i&&-1!=h.start.row){i.$pos=null;var e=i.getDocumentPosition().row;h.id||n.setRow(e),p(e,!0)}})),n.renderer.on("afterRender",(function(){var e=n.getRow(),t=n.renderer.$textLayer,r=t.element.childNodes[e-t.config.firstRow],i=document.activeElement;if(r!==t.selectedNode&&t.selectedNode&&(l.removeCssClass(t.selectedNode,"ace_selected"),i.removeAttribute("aria-activedescendant"),t.selectedNode.removeAttribute("id")),t.selectedNode=r,r){l.addCssClass(r,"ace_selected");var o=c(e);r.id=o,n.renderer.container.setAttribute("aria-activedescendant",o),i.setAttribute("aria-activedescendant",o),r.setAttribute("role","option"),r.setAttribute("aria-label",n.getData(e).value),r.setAttribute("aria-setsize",n.data.length),r.setAttribute("aria-posinset",e)}}));var d=function(){p(-1)},p=function(e,t){e!==h.start.row&&(h.start.row=h.end.row=e,t||n.session._emit("changeBackMarker"),n._emit("changeHoverMarker"))};n.getHoveredRow=function(){return h.start.row},s.addListener(n.container,"mouseout",d),n.on("hide",d),n.on("changeSelection",d),n.session.doc.getLength=function(){return n.data.length},n.session.doc.getLine=function(e){var t=n.data[e];return"string"==typeof t?t:t&&t.value||""};var g=n.session.bgTokenizer;return g.$tokenizeRow=function(e){function t(e,t){e&&i.push({type:(r.className||"")+(t||""),value:e})}var r=n.data[e],i=[];if(!r)return i;"string"==typeof r&&(r={value:r});for(var o=r.caption||r.value||r.name,s=o.toLowerCase(),a=(n.filterText||"").toLowerCase(),l=0,c=0,u=0;u<=a.length;u++)if(u!=c&&(r.matchMask&1<<u||u==a.length)){var h=a.slice(c,u);c=u;var f=s.indexOf(h,l);if(-1==f)continue;t(o.slice(l,f),""),l=f+h.length,t(o.slice(f,l),"completion-highlight")}return t(o.slice(l,o.length),""),r.meta&&i.push({type:"completion-meta",value:r.meta}),r.message&&i.push({type:"completion-message",value:r.message}),i},g.$updateOnChange=r,g.start=r,n.session.$computeWidth=function(){return this.screenWidth=0},n.isOpen=!1,n.isTopdown=!1,n.autoSelect=!0,n.filterText="",n.data=[],n.setData=function(e,t){n.filterText=t||"",n.setValue(a.stringRepeat("\n",e.length),-1),n.data=e||[],n.setRow(0)},n.getData=function(e){return n.data[e]},n.getRow=function(){return f.start.row},n.setRow=function(e){e=Math.max(this.autoSelect?0:-1,Math.min(this.data.length,e)),f.start.row!=e&&(n.selection.clearSelection(),f.start.row=f.end.row=e||0,n.session._emit("changeBackMarker"),n.moveCursorTo(e||0,0),n.isOpen&&n._signal("select"))},n.on("changeSelection",(function(){n.isOpen&&n.setRow(n.selection.lead.row),n.renderer.scrollCursorIntoView()})),n.hide=function(){this.container.style.display="none",n.anchorPos=null,n.anchor=null,n.isOpen&&(n.isOpen=!1,this._signal("hide"))},n.tryShow=function(e,t,r,o){if(!o&&n.isOpen&&n.anchorPos&&n.anchor&&n.anchorPos.top===e.top&&n.anchorPos.left===e.left&&n.anchor===r)return!0;var s=this.container,a=window.innerHeight,l=window.innerWidth,c=this.renderer,u=c.$maxLines*t*1.4,h={top:0,bottom:0,left:0},f=a-e.top-3*this.$borderSize-t,d=e.top-3*this.$borderSize;r||(r=d<=f||f>=u?"bottom":"top"),"top"===r?(h.bottom=e.top-this.$borderSize,h.top=h.bottom-u):"bottom"===r&&(h.top=e.top+t+this.$borderSize,h.bottom=h.top+u);var p=h.top>=0&&h.bottom<=a;if(!o&&!p)return!1;c.$maxPixelHeight=p?null:"top"===r?d:f,"top"===r?(s.style.top="",s.style.bottom=a-h.bottom+"px",n.isTopdown=!1):(s.style.top=h.top+"px",s.style.bottom="",n.isTopdown=!0),s.style.display="";var g=e.left;return g+s.offsetWidth>l&&(g=l-s.offsetWidth),s.style.left=g+"px",s.style.right="",n.isOpen||(n.isOpen=!0,this._signal("show"),i=null),n.anchorPos=e,n.anchor=r,!0},n.show=function(e,t,n){this.tryShow(e,t,n?"bottom":void 0,!0)},n.goTo=function(e){var t=this.getRow(),n=this.session.getLength()-1;switch(e){case"up":t=t<=0?n:t-1;break;case"down":t=t>=n?-1:t+1;break;case"start":t=0;break;case"end":t=n}this.setRow(t)},n.getTextLeftOffset=function(){return this.$borderSize+this.renderer.$padding+this.$imageSize},n.$imageSize=0,n.$borderSize=1,n}return e}();l.importCssString("\n.ace_editor.ace_autocomplete .ace_marker-layer .ace_active-line {\n background-color: #CAD6FA;\n z-index: 1;\n}\n.ace_dark.ace_editor.ace_autocomplete .ace_marker-layer .ace_active-line {\n background-color: #3a674e;\n}\n.ace_editor.ace_autocomplete .ace_line-hover {\n border: 1px solid #abbffe;\n margin-top: -1px;\n background: rgba(233,233,253,0.4);\n position: absolute;\n z-index: 2;\n}\n.ace_dark.ace_editor.ace_autocomplete .ace_line-hover {\n border: 1px solid rgba(109, 150, 13, 0.8);\n background: rgba(58, 103, 78, 0.62);\n}\n.ace_completion-meta {\n opacity: 0.5;\n margin: 0 0.9em;\n}\n.ace_completion-message {\n color: blue;\n}\n.ace_editor.ace_autocomplete .ace_completion-highlight{\n color: #2d69c7;\n}\n.ace_dark.ace_editor.ace_autocomplete .ace_completion-highlight{\n color: #93ca12;\n}\n.ace_editor.ace_autocomplete {\n width: 300px;\n z-index: 200000;\n border: 1px lightgray solid;\n position: fixed;\n box-shadow: 2px 3px 5px rgba(0,0,0,.2);\n line-height: 1.4;\n background: #fefefe;\n color: #111;\n}\n.ace_dark.ace_editor.ace_autocomplete {\n border: 1px #484747 solid;\n box-shadow: 2px 3px 5px rgba(0, 0, 0, 0.51);\n line-height: 1.4;\n background: #25282c;\n color: #c1c1c1;\n}\n.ace_autocomplete_right .ace_text-layer {\n width: calc(100% - 8px);\n}\n.ace_autocomplete_right .ace_line {\n display: flex;\n}\n.ace_autocomplete_right .ace_completion-meta {\n flex: 1;\n text-align: right;\n}\n","autocompletion.css",!1),t.AcePopup=h,t.$singleLineEditor=u,t.getAriaId=c})),ace.define("ace/autocomplete/inline",["require","exports","module","ace/snippets"],(function(e,t,n){"use strict";var r=e("../snippets").snippetManager,i=function(){function e(){this.editor=null}return e.prototype.show=function(e,t,n){if(n=n||"",e&&this.editor&&this.editor!==e&&(this.hide(),this.editor=null),!e||!t)return!1;var i=t.snippet?r.getDisplayTextForSnippet(e,t.snippet):t.value;return!(!i||!i.startsWith(n))&&(this.editor=e,i=i.slice(n.length),""===i?e.removeGhostText():e.setGhostText(i),!0)},e.prototype.isOpen=function(){return!!this.editor&&!!this.editor.renderer.$ghostText},e.prototype.hide=function(){return!!this.editor&&(this.editor.removeGhostText(),!0)},e.prototype.destroy=function(){this.hide(),this.editor=null},e}();t.AceInline=i})),ace.define("ace/autocomplete/util",["require","exports","module"],(function(e,t,n){"use strict";t.parForEach=function(e,t,n){var r=0,i=e.length;0===i&&n();for(var o=0;o<i;o++)t(e[o],(function(e,t){r++,r===i&&n(e,t)}))};var r=/[a-zA-Z_0-9\$\-\u00A2-\u2000\u2070-\uFFFF]/;t.retrievePrecedingIdentifier=function(e,t,n){n=n||r;for(var i=[],o=t-1;o>=0;o--){if(!n.test(e[o]))break;i.push(e[o])}return i.reverse().join("")},t.retrieveFollowingIdentifier=function(e,t,n){n=n||r;for(var i=[],o=t;o<e.length;o++){if(!n.test(e[o]))break;i.push(e[o])}return i},t.getCompletionPrefix=function(e){var t,n=e.getCursorPosition(),r=e.session.getLine(n.row);return e.completers.forEach(function(e){e.identifierRegexps&&e.identifierRegexps.forEach(function(e){!t&&e&&(t=this.retrievePrecedingIdentifier(r,n.column,e))}.bind(this))}.bind(this)),t||this.retrievePrecedingIdentifier(r,n.column)}})),ace.define("ace/autocomplete",["require","exports","module","ace/keyboard/hash_handler","ace/autocomplete/popup","ace/autocomplete/inline","ace/autocomplete/popup","ace/autocomplete/util","ace/lib/lang","ace/lib/dom","ace/snippets","ace/config"],(function(e,t,n){"use strict";var r=e("./keyboard/hash_handler").HashHandler,i=e("./autocomplete/popup").AcePopup,o=e("./autocomplete/inline").AceInline,s=e("./autocomplete/popup").getAriaId,a=e("./autocomplete/util"),l=e("./lib/lang"),c=e("./lib/dom"),u=e("./snippets").snippetManager,h=e("./config"),f=function(e,t){t.completer&&t.completer.destroy()},d=function(){function e(){this.autoInsert=!1,this.autoSelect=!0,this.exactMatch=!1,this.inlineEnabled=!1,this.keyboardHandler=new r,this.keyboardHandler.bindKeys(this.commands),this.blurListener=this.blurListener.bind(this),this.changeListener=this.changeListener.bind(this),this.mousedownListener=this.mousedownListener.bind(this),this.mousewheelListener=this.mousewheelListener.bind(this),this.changeTimer=l.delayedCall(function(){this.updateCompletions(!0)}.bind(this)),this.tooltipTimer=l.delayedCall(this.updateDocTooltip.bind(this),50)}return e.prototype.$init=function(){return this.popup=new i(document.body||document.documentElement),this.popup.on("click",function(e){this.insertMatch(),e.stop()}.bind(this)),this.popup.focus=this.editor.focus.bind(this.editor),this.popup.on("show",this.$onPopupChange.bind(this)),this.popup.on("hide",this.$onHidePopup.bind(this)),this.popup.on("select",this.$onPopupChange.bind(this)),this.popup.on("changeHoverMarker",this.tooltipTimer.bind(null,null)),this.popup},e.prototype.$initInline=function(){if(this.inlineEnabled&&!this.inlineRenderer)return this.inlineRenderer=new o,this.inlineRenderer},e.prototype.getPopup=function(){return this.popup||this.$init()},e.prototype.$onHidePopup=function(){this.inlineRenderer&&this.inlineRenderer.hide(),this.hideDocTooltip()},e.prototype.$onPopupChange=function(e){if(this.inlineRenderer&&this.inlineEnabled){var t=e?null:this.popup.getData(this.popup.getRow()),n=a.getCompletionPrefix(this.editor);this.inlineRenderer.show(this.editor,t,n)||this.inlineRenderer.hide(),this.$updatePopupPosition()}this.tooltipTimer.call(null,null)},e.prototype.$updatePopupPosition=function(){var e=this.editor,t=e.renderer,n=t.layerConfig.lineHeight,r=t.$cursorLayer.getPixelPosition(this.base,!0);r.left-=this.popup.getTextLeftOffset();var i=e.container.getBoundingClientRect();r.top+=i.top-t.layerConfig.offset,r.left+=i.left-e.renderer.scrollLeft,r.left+=t.gutterWidth;var o={top:r.top,left:r.left};t.$ghostText&&t.$ghostTextWidget&&this.base.row===t.$ghostText.position.row&&(o.top+=t.$ghostTextWidget.el.offsetHeight),this.popup.tryShow(o,n,"bottom")||this.popup.tryShow(r,n,"top")||this.popup.show(r,n)},e.prototype.openPopup=function(e,t,n){this.popup||this.$init(),this.inlineEnabled&&!this.inlineRenderer&&this.$initInline(),this.popup.autoSelect=this.autoSelect,this.popup.setData(this.completions.filtered,this.completions.filterText),this.editor.textInput.setAriaOptions&&this.editor.textInput.setAriaOptions({activeDescendant:s(this.popup.getRow()),inline:this.inlineEnabled}),e.keyBinding.addKeyboardHandler(this.keyboardHandler),this.popup.setRow(this.autoSelect?0:-1),n?n&&!t&&this.detach():(this.popup.setTheme(e.getTheme()),this.popup.setFontSize(e.getFontSize()),this.$updatePopupPosition(),this.tooltipNode&&this.updateDocTooltip()),this.changeTimer.cancel()},e.prototype.detach=function(){this.editor&&(this.editor.keyBinding.removeKeyboardHandler(this.keyboardHandler),this.editor.off("changeSelection",this.changeListener),this.editor.off("blur",this.blurListener),this.editor.off("mousedown",this.mousedownListener),this.editor.off("mousewheel",this.mousewheelListener)),this.changeTimer.cancel(),this.hideDocTooltip(),this.completionProvider&&this.completionProvider.detach(),this.popup&&this.popup.isOpen&&this.popup.hide(),this.base&&this.base.detach(),this.activated=!1,this.completionProvider=this.completions=this.base=null},e.prototype.changeListener=function(e){var t=this.editor.selection.lead;(t.row!=this.base.row||t.column<this.base.column)&&this.detach(),this.activated?this.changeTimer.schedule():this.detach()},e.prototype.blurListener=function(e){var t=document.activeElement,n=this.editor.textInput.getElement(),r=e.relatedTarget&&this.tooltipNode&&this.tooltipNode.contains(e.relatedTarget),i=this.popup&&this.popup.container;t!=n&&t.parentNode!=i&&!r&&t!=this.tooltipNode&&e.relatedTarget!=n&&this.detach()},e.prototype.mousedownListener=function(e){this.detach()},e.prototype.mousewheelListener=function(e){this.detach()},e.prototype.goTo=function(e){this.popup.goTo(e)},e.prototype.insertMatch=function(e,t){if(e||(e=this.popup.getData(this.popup.getRow())),!e)return!1;var n=this.completions,r=this.getCompletionProvider().insertMatch(this.editor,e,n.filterText,t);return this.completions==n&&this.detach(),r},e.prototype.showPopup=function(e,t){this.editor&&this.detach(),this.activated=!0,this.editor=e,e.completer!=this&&(e.completer&&e.completer.detach(),e.completer=this),e.on("changeSelection",this.changeListener),e.on("blur",this.blurListener),e.on("mousedown",this.mousedownListener),e.on("mousewheel",this.mousewheelListener),this.updateCompletions(!1,t)},e.prototype.getCompletionProvider=function(){return this.completionProvider||(this.completionProvider=new p),this.completionProvider},e.prototype.gatherCompletions=function(e,t){return this.getCompletionProvider().gatherCompletions(e,t)},e.prototype.updateCompletions=function(e,t){if(e&&this.base&&this.completions){var n=this.editor.getCursorPosition(),r=this.editor.session.getTextRange({start:this.base,end:n});if(r==this.completions.filterText)return;return this.completions.setFilter(r),this.completions.filtered.length?1!=this.completions.filtered.length||this.completions.filtered[0].value!=r||this.completions.filtered[0].snippet?void this.openPopup(this.editor,r,e):this.detach():this.detach()}if(t&&t.matches){n=this.editor.getSelectionRange().start;return this.base=this.editor.session.doc.createAnchor(n.row,n.column),this.base.$insertRight=!0,this.completions=new g(t.matches),this.openPopup(this.editor,"",e)}var i=this.editor.getSession();n=this.editor.getCursorPosition(),r=a.getCompletionPrefix(this.editor);this.base=i.doc.createAnchor(n.row,n.column-r.length),this.base.$insertRight=!0;var o={exactMatch:this.exactMatch};this.getCompletionProvider().provideCompletions(this.editor,o,function(t,n,r){var i=n.filtered,o=a.getCompletionPrefix(this.editor);if(r){if(!i.length)return this.detach();if(1==i.length&&i[0].value==o&&!i[0].snippet)return this.detach();if(this.autoInsert&&1==i.length)return this.insertMatch(i[0])}this.completions=n,this.openPopup(this.editor,o,e)}.bind(this))},e.prototype.cancelContextMenu=function(){this.editor.$mouseHandler.cancelContextMenu()},e.prototype.updateDocTooltip=function(){var e=this.popup,t=e.data,n=t&&(t[e.getHoveredRow()]||t[e.getRow()]),r=null;if(!n||!this.editor||!this.popup.isOpen)return this.hideDocTooltip();for(var i=this.editor.completers.length,o=0;o<i;o++){var s=this.editor.completers[o];if(s.getDocTooltip&&n.completerId===s.id){r=s.getDocTooltip(n);break}}if(!r&&"string"!=typeof n&&(r=n),"string"==typeof r&&(r={docText:r}),!r||!r.docHTML&&!r.docText)return this.hideDocTooltip();this.showDocTooltip(r)},e.prototype.showDocTooltip=function(e){this.tooltipNode||(this.tooltipNode=c.createElement("div"),this.tooltipNode.className="ace_tooltip ace_doc-tooltip",this.tooltipNode.style.margin=0,this.tooltipNode.style.pointerEvents="auto",this.tooltipNode.tabIndex=-1,this.tooltipNode.onblur=this.blurListener.bind(this),this.tooltipNode.onclick=this.onTooltipClick.bind(this));var t=this.tooltipNode;e.docHTML?t.innerHTML=e.docHTML:e.docText&&(t.textContent=e.docText),t.parentNode||document.body.appendChild(t);var n=this.popup,r=n.container.getBoundingClientRect();t.style.top=n.container.style.top,t.style.bottom=n.container.style.bottom,t.style.display="block",window.innerWidth-r.right<320?r.left<320?n.isTopdown?(t.style.top=r.bottom+"px",t.style.left=r.left+"px",t.style.right="",t.style.bottom=""):(t.style.top=n.container.offsetTop-t.offsetHeight+"px",t.style.left=r.left+"px",t.style.right="",t.style.bottom=""):(t.style.right=window.innerWidth-r.left+"px",t.style.left=""):(t.style.left=r.right+1+"px",t.style.right="")},e.prototype.hideDocTooltip=function(){if(this.tooltipTimer.cancel(),this.tooltipNode){var e=this.tooltipNode;!this.editor.isFocused()&&document.activeElement==e&&this.editor.focus(),this.tooltipNode=null,e.parentNode&&e.parentNode.removeChild(e)}},e.prototype.onTooltipClick=function(e){var t=e.target;while(t&&t!=this.tooltipNode){if("A"==t.nodeName&&t.href){t.rel="noreferrer",t.target="_blank";break}t=t.parentNode}},e.prototype.destroy=function(){if(this.detach(),this.popup){this.popup.destroy();var e=this.popup.container;e&&e.parentNode&&e.parentNode.removeChild(e)}this.editor&&this.editor.completer==this&&(this.editor.off("destroy",f),this.editor.completer=null),this.inlineRenderer=this.popup=this.editor=null},e}();d.prototype.commands={Up:function(e){e.completer.goTo("up")},Down:function(e){e.completer.goTo("down")},"Ctrl-Up|Ctrl-Home":function(e){e.completer.goTo("start")},"Ctrl-Down|Ctrl-End":function(e){e.completer.goTo("end")},Esc:function(e){e.completer.detach()},Return:function(e){return e.completer.insertMatch()},"Shift-Return":function(e){e.completer.insertMatch(null,{deleteSuffix:!0})},Tab:function(e){var t=e.completer.insertMatch();if(t||e.tabstopManager)return t;e.completer.goTo("down")},PageUp:function(e){e.completer.popup.gotoPageUp()},PageDown:function(e){e.completer.popup.gotoPageDown()}},d.for=function(e){return e.completer instanceof d||(e.completer&&(e.completer.destroy(),e.completer=null),h.get("sharedPopups")?(d.$sharedInstance||(d.$sharedInstance=new d),e.completer=d.$sharedInstance):(e.completer=new d,e.once("destroy",f))),e.completer},d.startCommand={name:"startAutocomplete",exec:function(e,t){var n=d.for(e);n.autoInsert=!1,n.autoSelect=!0,n.showPopup(e,t),n.cancelContextMenu()},bindKey:"Ctrl-Space|Ctrl-Shift-Space|Alt-Space"};var p=function(){function e(){this.active=!0}return e.prototype.insertByIndex=function(e,t,n){return!(!this.completions||!this.completions.filtered)&&this.insertMatch(e,this.completions.filtered[t],n)},e.prototype.insertMatch=function(e,t,n){if(!t)return!1;if(e.startOperation({command:{name:"insertMatch"}}),t.completer&&t.completer.insertMatch)t.completer.insertMatch(e,t);else{if(!this.completions)return!1;if(this.completions.filterText)for(var r,i=e.selection.getAllRanges(),o=0;r=i[o];o++)r.start.column-=this.completions.filterText.length,e.session.remove(r);t.snippet?u.insertSnippet(e,t.snippet,t.range):this.$insertString(e,t),t.command&&"startAutocomplete"===t.command&&e.execCommand(t.command)}return e.endOperation(),!0},e.prototype.$insertString=function(e,t){var n=t.value||t;if(t.range){if(e.inVirtualSelectionMode)return e.session.replace(t.range,n);e.forEachSelection((function(){var r=e.getSelectionRange();0===t.range.compareRange(r)?e.session.replace(t.range,n):e.insert(n)}),null,{keepOrder:!0})}else e.execCommand("insertstring",n)},e.prototype.gatherCompletions=function(e,t){var n=e.getSession(),r=e.getCursorPosition(),i=a.getCompletionPrefix(e),o=[],s=e.completers.length;return e.completers.forEach((function(l,c){l.getCompletions(e,n,r,i,(function(n,r){!n&&r&&(o=o.concat(r)),t(null,{prefix:a.getCompletionPrefix(e),matches:o,finished:0===--s})}))})),!0},e.prototype.provideCompletions=function(e,t,n){var r=function(e){var r=e.prefix,i=e.matches;this.completions=new g(i),t.exactMatch&&(this.completions.exactMatch=!0),t.ignoreCaption&&(this.completions.ignoreCaption=!0),this.completions.setFilter(r),(e.finished||this.completions.filtered.length)&&n(null,this.completions,e.finished)}.bind(this),i=!0,o=null;if(this.gatherCompletions(e,function(e,t){if(this.active){e&&(n(e,[],!0),this.detach());var s=t.prefix;0===s.indexOf(t.prefix)&&(i?o=t:r(t))}}.bind(this)),i=!1,o){var s=o;o=null,r(s)}},e.prototype.detach=function(){this.active=!1},e}(),g=function(){function e(e,t){this.all=e,this.filtered=e,this.filterText=t||"",this.exactMatch=!1,this.ignoreCaption=!1}return e.prototype.setFilter=function(e){if(e.length>this.filterText&&0===e.lastIndexOf(this.filterText,0))var t=this.filtered;else t=this.all;this.filterText=e,t=this.filterCompletions(t,this.filterText),t=t.sort((function(e,t){return t.exactMatch-e.exactMatch||t.$score-e.$score||(e.caption||e.value).localeCompare(t.caption||t.value)}));var n=null;t=t.filter((function(e){var t=e.snippet||e.caption||e.value;return t!==n&&(n=t,!0)})),this.filtered=t},e.prototype.filterCompletions=function(e,t){var n=[],r=t.toUpperCase(),i=t.toLowerCase();e:for(var o,s=0;o=e[s];s++){var a=!this.ignoreCaption&&o.caption||o.value||o.snippet;if(a){var l,c,u=-1,h=0,f=0;if(this.exactMatch){if(t!==a.substr(0,t.length))continue e}else{var d=a.toLowerCase().indexOf(i);if(d>-1)f=d;else for(var p=0;p<t.length;p++){var g=a.indexOf(i[p],u+1),m=a.indexOf(r[p],u+1);if(l=g>=0&&(m<0||g<m)?g:m,l<0)continue e;c=l-u-1,c>0&&(-1===u&&(f+=10),f+=c,h|=1<<p),u=l}}o.matchMask=h,o.exactMatch=f?0:1,o.$score=(o.score||0)-f,n.push(o)}}return n},e}();t.Autocomplete=d,t.CompletionProvider=p,t.FilteredList=g})),ace.define("ace/autocomplete/text_completer",["require","exports","module","ace/range"],(function(e,t,n){function r(e,t){var n=e.getTextRange(o.fromPoints({row:0,column:0},t));return n.split(s).length-1}function i(e,t){var n=r(e,t),i=e.getValue().split(s),o=Object.create(null),a=i[n];return i.forEach((function(e,t){if(e&&e!==a){var r=Math.abs(n-t),s=i.length-r;o[e]?o[e]=Math.max(s,o[e]):o[e]=s}})),o}var o=e("../range").Range,s=/[^a-zA-Z_0-9\$\-\u00C0-\u1FFF\u2C00-\uD7FF\w]+/;t.getCompletions=function(e,t,n,r,o){var s=i(t,n),a=Object.keys(s);o(null,a.map((function(e){return{caption:e,value:e,score:s[e],meta:"local"}})))}})),ace.define("ace/ext/language_tools",["require","exports","module","ace/snippets","ace/autocomplete","ace/config","ace/lib/lang","ace/autocomplete/util","ace/autocomplete/text_completer","ace/editor","ace/config"],(function(e,t,n){"use strict";var r=e("../snippets").snippetManager,i=e("../autocomplete").Autocomplete,o=e("../config"),s=e("../lib/lang"),a=e("../autocomplete/util"),l=e("../autocomplete/text_completer"),c={getCompletions:function(e,t,n,r,i){if(t.$mode.completer)return t.$mode.completer.getCompletions(e,t,n,r,i);var o=e.session.getState(n.row),s=t.$mode.getCompletions(o,t,n,r);s=s.map((function(e){return e.completerId=c.id,e})),i(null,s)},id:"keywordCompleter"},u=function(e){var t={};return e.replace(/\${(\d+)(:(.*?))?}/g,(function(e,n,r,i){return t[n]=i||""})).replace(/\$(\d+?)/g,(function(e,n){return t[n]}))},h={getCompletions:function(e,t,n,i,o){var s=[],a=t.getTokenAt(n.row,n.column);a&&a.type.match(/(tag-name|tag-open|tag-whitespace|attribute-name|attribute-value)\.xml$/)?s.push("html-tag"):s=r.getActiveScopes(e);var l=r.snippetMap,c=[];s.forEach((function(e){for(var t=l[e]||[],n=t.length;n--;){var r=t[n],i=r.name||r.tabTrigger;i&&c.push({caption:i,snippet:r.content,meta:r.tabTrigger&&!r.name?r.tabTrigger+"⇥ ":"snippet",completerId:h.id})}}),this),o(null,c)},getDocTooltip:function(e){e.snippet&&!e.docHTML&&(e.docHTML=["<b>",s.escapeHTML(e.caption),"</b>","<hr></hr>",s.escapeHTML(u(e.snippet))].join(""))},id:"snippetCompleter"},f=[h,l,c];t.setCompleters=function(e){f.length=0,e&&f.push.apply(f,e)},t.addCompleter=function(e){f.push(e)},t.textCompleter=l,t.keyWordCompleter=c,t.snippetCompleter=h;var d={name:"expandSnippet",exec:function(e){return r.expandWithTab(e)},bindKey:"Tab"},p=function(e,t){g(t.session.$mode)},g=function(e){"string"==typeof e&&(e=o.$modes[e]),e&&(r.files||(r.files={}),m(e.$id,e.snippetFileId),e.modes&&e.modes.forEach(g))},m=function(e,t){t&&e&&!r.files[e]&&(r.files[e]={},o.loadModule(t,(function(t){t&&(r.files[e]=t,!t.snippets&&t.snippetText&&(t.snippets=r.parseSnippetFile(t.snippetText)),r.register(t.snippets||[],t.scope),t.includeScopes&&(r.snippetMap[t.scope].includeScopes=t.includeScopes,t.includeScopes.forEach((function(e){g("ace/mode/"+e)}))))})))},v=function(e){var t=e.editor,n=t.completer&&t.completer.activated;if("backspace"===e.command.name)n&&!a.getCompletionPrefix(t)&&t.completer.detach();else if("insertstring"===e.command.name){var r=a.getCompletionPrefix(t);if(r&&!n){var o=i.for(t);o.autoInsert=!1,o.showPopup(t)}}},y=e("../editor").Editor;e("../config").defineOptions(y.prototype,"editor",{enableBasicAutocompletion:{set:function(e){e?(this.completers||(this.completers=Array.isArray(e)?e:f),this.commands.addCommand(i.startCommand)):this.commands.removeCommand(i.startCommand)},value:!1},enableLiveAutocompletion:{set:function(e){e?(this.completers||(this.completers=Array.isArray(e)?e:f),this.commands.on("afterExec",v)):this.commands.removeListener("afterExec",v)},value:!1},enableSnippets:{set:function(e){e?(this.commands.addCommand(d),this.on("changeMode",p),p(null,this)):(this.commands.removeCommand(d),this.off("changeMode",p))},value:!1}})})),function(){ace.require(["ace/ext/language_tools"],(function(t){e&&(e.exports=t)}))}()},72375:function(e,t,n){e=n.nmd(e),ace.define("ace/ext/searchbox.css",["require","exports","module"],(function(e,t,n){n.exports='\n\n/* ------------------------------------------------------------------------------------------\n * Editor Search Form\n * --------------------------------------------------------------------------------------- */\n.ace_search {\n background-color: #ddd;\n color: #666;\n border: 1px solid #cbcbcb;\n border-top: 0 none;\n overflow: hidden;\n margin: 0;\n padding: 4px 6px 0 4px;\n position: absolute;\n top: 0;\n z-index: 99;\n white-space: normal;\n}\n.ace_search.left {\n border-left: 0 none;\n border-radius: 0px 0px 5px 0px;\n left: 0;\n}\n.ace_search.right {\n border-radius: 0px 0px 0px 5px;\n border-right: 0 none;\n right: 0;\n}\n\n.ace_search_form, .ace_replace_form {\n margin: 0 20px 4px 0;\n overflow: hidden;\n line-height: 1.9;\n}\n.ace_replace_form {\n margin-right: 0;\n}\n.ace_search_form.ace_nomatch {\n outline: 1px solid red;\n}\n\n.ace_search_field {\n border-radius: 3px 0 0 3px;\n background-color: white;\n color: black;\n border: 1px solid #cbcbcb;\n border-right: 0 none;\n outline: 0;\n padding: 0;\n font-size: inherit;\n margin: 0;\n line-height: inherit;\n padding: 0 6px;\n min-width: 17em;\n vertical-align: top;\n min-height: 1.8em;\n box-sizing: content-box;\n}\n.ace_searchbtn {\n border: 1px solid #cbcbcb;\n line-height: inherit;\n display: inline-block;\n padding: 0 6px;\n background: #fff;\n border-right: 0 none;\n border-left: 1px solid #dcdcdc;\n cursor: pointer;\n margin: 0;\n position: relative;\n color: #666;\n}\n.ace_searchbtn:last-child {\n border-radius: 0 3px 3px 0;\n border-right: 1px solid #cbcbcb;\n}\n.ace_searchbtn:disabled {\n background: none;\n cursor: default;\n}\n.ace_searchbtn:hover {\n background-color: #eef1f6;\n}\n.ace_searchbtn.prev, .ace_searchbtn.next {\n padding: 0px 0.7em\n}\n.ace_searchbtn.prev:after, .ace_searchbtn.next:after {\n content: "";\n border: solid 2px #888;\n width: 0.5em;\n height: 0.5em;\n border-width: 2px 0 0 2px;\n display:inline-block;\n transform: rotate(-45deg);\n}\n.ace_searchbtn.next:after {\n border-width: 0 2px 2px 0 ;\n}\n.ace_searchbtn_close {\n background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAA4AAAAcCAYAAABRVo5BAAAAZ0lEQVR42u2SUQrAMAhDvazn8OjZBilCkYVVxiis8H4CT0VrAJb4WHT3C5xU2a2IQZXJjiQIRMdkEoJ5Q2yMqpfDIo+XY4k6h+YXOyKqTIj5REaxloNAd0xiKmAtsTHqW8sR2W5f7gCu5nWFUpVjZwAAAABJRU5ErkJggg==) no-repeat 50% 0;\n border-radius: 50%;\n border: 0 none;\n color: #656565;\n cursor: pointer;\n font: 16px/16px Arial;\n padding: 0;\n height: 14px;\n width: 14px;\n top: 9px;\n right: 7px;\n position: absolute;\n}\n.ace_searchbtn_close:hover {\n background-color: #656565;\n background-position: 50% 100%;\n color: white;\n}\n\n.ace_button {\n margin-left: 2px;\n cursor: pointer;\n -webkit-user-select: none;\n -moz-user-select: none;\n -o-user-select: none;\n -ms-user-select: none;\n user-select: none;\n overflow: hidden;\n opacity: 0.7;\n border: 1px solid rgba(100,100,100,0.23);\n padding: 1px;\n box-sizing: border-box!important;\n color: black;\n}\n\n.ace_button:hover {\n background-color: #eee;\n opacity:1;\n}\n.ace_button:active {\n background-color: #ddd;\n}\n\n.ace_button.checked {\n border-color: #3399ff;\n opacity:1;\n}\n\n.ace_search_options{\n margin-bottom: 3px;\n text-align: right;\n -webkit-user-select: none;\n -moz-user-select: none;\n -o-user-select: none;\n -ms-user-select: none;\n user-select: none;\n clear: both;\n}\n\n.ace_search_counter {\n float: left;\n font-family: arial;\n padding: 0 8px;\n}'})),ace.define("ace/ext/searchbox",["require","exports","module","ace/lib/dom","ace/lib/lang","ace/lib/event","ace/ext/searchbox.css","ace/keyboard/hash_handler","ace/lib/keys"],(function(e,t,n){"use strict";var r=e("../lib/dom"),i=e("../lib/lang"),o=e("../lib/event"),s=e("./searchbox.css"),a=e("../keyboard/hash_handler").HashHandler,l=e("../lib/keys"),c=999;r.importCssString(s,"ace_searchbox",!1);var u=function(){function e(e,t,n){var i=r.createElement("div");r.buildDom(["div",{class:"ace_search right"},["span",{action:"hide",class:"ace_searchbtn_close"}],["div",{class:"ace_search_form"},["input",{class:"ace_search_field",placeholder:"Search for",spellcheck:"false"}],["span",{action:"findPrev",class:"ace_searchbtn prev"},"​"],["span",{action:"findNext",class:"ace_searchbtn next"},"​"],["span",{action:"findAll",class:"ace_searchbtn",title:"Alt-Enter"},"All"]],["div",{class:"ace_replace_form"},["input",{class:"ace_search_field",placeholder:"Replace with",spellcheck:"false"}],["span",{action:"replaceAndFindNext",class:"ace_searchbtn"},"Replace"],["span",{action:"replaceAll",class:"ace_searchbtn"},"All"]],["div",{class:"ace_search_options"},["span",{action:"toggleReplace",class:"ace_button",title:"Toggle Replace mode",style:"float:left;margin-top:-2px;padding:0 5px;"},"+"],["span",{class:"ace_search_counter"}],["span",{action:"toggleRegexpMode",class:"ace_button",title:"RegExp Search"},".*"],["span",{action:"toggleCaseSensitive",class:"ace_button",title:"CaseSensitive Search"},"Aa"],["span",{action:"toggleWholeWords",class:"ace_button",title:"Whole Word Search"},"\\b"],["span",{action:"searchInSelection",class:"ace_button",title:"Search In Selection"},"S"]]],i),this.element=i.firstChild,this.setSession=this.setSession.bind(this),this.$init(),this.setEditor(e),r.importCssString(s,"ace_searchbox",e.container),this.$searchBarKb=new a,this.$searchBarKb.bindKeys({"Ctrl-f|Command-f":function(e){var t=e.isReplace=!e.isReplace;e.replaceBox.style.display=t?"":"none",e.replaceOption.checked=!1,e.$syncOptions(),e.searchInput.focus()},"Ctrl-H|Command-Option-F":function(e){e.editor.getReadOnly()||(e.replaceOption.checked=!0,e.$syncOptions(),e.replaceInput.focus())},"Ctrl-G|Command-G":function(e){e.findNext()},"Ctrl-Shift-G|Command-Shift-G":function(e){e.findPrev()},esc:function(e){setTimeout((function(){e.hide()}))},Return:function(e){e.activeInput==e.replaceInput&&e.replace(),e.findNext()},"Shift-Return":function(e){e.activeInput==e.replaceInput&&e.replace(),e.findPrev()},"Alt-Return":function(e){e.activeInput==e.replaceInput&&e.replaceAll(),e.findAll()},Tab:function(e){(e.activeInput==e.replaceInput?e.searchInput:e.replaceInput).focus()}}),this.$searchBarKb.addCommands([{name:"toggleRegexpMode",bindKey:{win:"Alt-R|Alt-/",mac:"Ctrl-Alt-R|Ctrl-Alt-/"},exec:function(e){e.regExpOption.checked=!e.regExpOption.checked,e.$syncOptions()}},{name:"toggleCaseSensitive",bindKey:{win:"Alt-C|Alt-I",mac:"Ctrl-Alt-R|Ctrl-Alt-I"},exec:function(e){e.caseSensitiveOption.checked=!e.caseSensitiveOption.checked,e.$syncOptions()}},{name:"toggleWholeWords",bindKey:{win:"Alt-B|Alt-W",mac:"Ctrl-Alt-B|Ctrl-Alt-W"},exec:function(e){e.wholeWordOption.checked=!e.wholeWordOption.checked,e.$syncOptions()}},{name:"toggleReplace",exec:function(e){e.replaceOption.checked=!e.replaceOption.checked,e.$syncOptions()}},{name:"searchInSelection",exec:function(e){e.searchOption.checked=!e.searchRange,e.setSearchRange(e.searchOption.checked&&e.editor.getSelectionRange()),e.$syncOptions()}}]),this.$closeSearchBarKb=new a([{bindKey:"Esc",name:"closeSearchBar",exec:function(e){e.searchBox.hide()}}])}return e.prototype.setEditor=function(e){e.searchBox=this,e.renderer.scroller.appendChild(this.element),this.editor=e},e.prototype.setSession=function(e){this.searchRange=null,this.$syncOptions(!0)},e.prototype.$initElements=function(e){this.searchBox=e.querySelector(".ace_search_form"),this.replaceBox=e.querySelector(".ace_replace_form"),this.searchOption=e.querySelector("[action=searchInSelection]"),this.replaceOption=e.querySelector("[action=toggleReplace]"),this.regExpOption=e.querySelector("[action=toggleRegexpMode]"),this.caseSensitiveOption=e.querySelector("[action=toggleCaseSensitive]"),this.wholeWordOption=e.querySelector("[action=toggleWholeWords]"),this.searchInput=this.searchBox.querySelector(".ace_search_field"),this.replaceInput=this.replaceBox.querySelector(".ace_search_field"),this.searchCounter=e.querySelector(".ace_search_counter")},e.prototype.$init=function(){var e=this.element;this.$initElements(e);var t=this;o.addListener(e,"mousedown",(function(e){setTimeout((function(){t.activeInput.focus()}),0),o.stopPropagation(e)})),o.addListener(e,"click",(function(e){var n=e.target||e.srcElement,r=n.getAttribute("action");r&&t[r]?t[r]():t.$searchBarKb.commands[r]&&t.$searchBarKb.commands[r].exec(t),o.stopPropagation(e)})),o.addCommandKeyListener(e,(function(e,n,r){var i=l.keyCodeToString(r),s=t.$searchBarKb.findKeyCommand(n,i);s&&s.exec&&(s.exec(t),o.stopEvent(e))})),this.$onChange=i.delayedCall((function(){t.find(!1,!1)})),o.addListener(this.searchInput,"input",(function(){t.$onChange.schedule(20)})),o.addListener(this.searchInput,"focus",(function(){t.activeInput=t.searchInput,t.searchInput.value&&t.highlight()})),o.addListener(this.replaceInput,"focus",(function(){t.activeInput=t.replaceInput,t.searchInput.value&&t.highlight()}))},e.prototype.setSearchRange=function(e){this.searchRange=e,e?this.searchRangeMarker=this.editor.session.addMarker(e,"ace_active-line"):this.searchRangeMarker&&(this.editor.session.removeMarker(this.searchRangeMarker),this.searchRangeMarker=null)},e.prototype.$syncOptions=function(e){r.setCssClass(this.replaceOption,"checked",this.searchRange),r.setCssClass(this.searchOption,"checked",this.searchOption.checked),this.replaceOption.textContent=this.replaceOption.checked?"-":"+",r.setCssClass(this.regExpOption,"checked",this.regExpOption.checked),r.setCssClass(this.wholeWordOption,"checked",this.wholeWordOption.checked),r.setCssClass(this.caseSensitiveOption,"checked",this.caseSensitiveOption.checked);var t=this.editor.getReadOnly();this.replaceOption.style.display=t?"none":"",this.replaceBox.style.display=this.replaceOption.checked&&!t?"":"none",this.find(!1,!1,e)},e.prototype.highlight=function(e){this.editor.session.highlight(e||this.editor.$search.$options.re),this.editor.renderer.updateBackMarkers()},e.prototype.find=function(e,t,n){var i=this.editor.find(this.searchInput.value,{skipCurrent:e,backwards:t,wrap:!0,regExp:this.regExpOption.checked,caseSensitive:this.caseSensitiveOption.checked,wholeWord:this.wholeWordOption.checked,preventScroll:n,range:this.searchRange}),o=!i&&this.searchInput.value;r.setCssClass(this.searchBox,"ace_nomatch",o),this.editor._emit("findSearchBox",{match:!o}),this.highlight(),this.updateCounter()},e.prototype.updateCounter=function(){var e=this.editor,t=e.$search.$options.re,n=0,r=0;if(t){var i=this.searchRange?e.session.getTextRange(this.searchRange):e.getValue(),o=e.session.doc.positionToIndex(e.selection.anchor);this.searchRange&&(o-=e.session.doc.positionToIndex(this.searchRange.start));var s,a=t.lastIndex=0;while(s=t.exec(i)){if(n++,a=s.index,a<=o&&r++,n>c)break;if(!s[0]&&(t.lastIndex=a+=1,a>=i.length))break}}this.searchCounter.textContent=r+" of "+(n>c?c+"+":n)},e.prototype.findNext=function(){this.find(!0,!1)},e.prototype.findPrev=function(){this.find(!0,!0)},e.prototype.findAll=function(){var e=this.editor.findAll(this.searchInput.value,{regExp:this.regExpOption.checked,caseSensitive:this.caseSensitiveOption.checked,wholeWord:this.wholeWordOption.checked}),t=!e&&this.searchInput.value;r.setCssClass(this.searchBox,"ace_nomatch",t),this.editor._emit("findSearchBox",{match:!t}),this.highlight(),this.hide()},e.prototype.replace=function(){this.editor.getReadOnly()||this.editor.replace(this.replaceInput.value)},e.prototype.replaceAndFindNext=function(){this.editor.getReadOnly()||(this.editor.replace(this.replaceInput.value),this.findNext())},e.prototype.replaceAll=function(){this.editor.getReadOnly()||this.editor.replaceAll(this.replaceInput.value)},e.prototype.hide=function(){this.active=!1,this.setSearchRange(null),this.editor.off("changeSession",this.setSession),this.element.style.display="none",this.editor.keyBinding.removeKeyboardHandler(this.$closeSearchBarKb),this.editor.focus()},e.prototype.show=function(e,t){this.active=!0,this.editor.on("changeSession",this.setSession),this.element.style.display="",this.replaceOption.checked=t,e&&(this.searchInput.value=e),this.searchInput.focus(),this.searchInput.select(),this.editor.keyBinding.addKeyboardHandler(this.$closeSearchBarKb),this.$syncOptions(!0)},e.prototype.isFocused=function(){var e=document.activeElement;return e==this.searchInput||e==this.replaceInput},e}();t.SearchBox=u,t.Search=function(e,t){var n=e.searchBox||new u(e);n.show(e.session.getTextRange(),t)}})),function(){ace.require(["ace/ext/searchbox"],(function(t){e&&(e.exports=t)}))}()},5343:function(e,t,n){e=n.nmd(e),ace.define("ace/mode/ruby_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"],(function(e,t,n){"use strict";var r=e("../lib/oop"),i=e("./text_highlight_rules").TextHighlightRules,o=t.constantOtherSymbol={token:"constant.other.symbol.ruby",regex:"[:](?:[A-Za-z_]|[@$](?=[a-zA-Z0-9_]))[a-zA-Z0-9_]*[!=?]?"};t.qString={token:"string",regex:"['](?:(?:\\\\.)|(?:[^'\\\\]))*?[']"},t.qqString={token:"string",regex:'["](?:(?:\\\\.)|(?:[^"\\\\]))*?["]'},t.tString={token:"string",regex:"[`](?:(?:\\\\.)|(?:[^'\\\\]))*?[`]"};var s=t.constantNumericHex={token:"constant.numeric",regex:"0[xX][0-9a-fA-F](?:[0-9a-fA-F]|_(?=[0-9a-fA-F]))*\\b"},a=t.constantNumericBinary={token:"constant.numeric",regex:/\b(0[bB][01](?:[01]|_(?=[01]))*)\b/},l=t.constantNumericDecimal={token:"constant.numeric",regex:/\b(0[dD](?:[1-9](?:[\d]|_(?=[\d]))*|0))\b/},c=t.constantNumericDecimal={token:"constant.numeric",regex:/\b(0[oO]?(?:[1-7](?:[0-7]|_(?=[0-7]))*|0))\b/},u=t.constantNumericRational={token:"constant.numeric",regex:/\b([\d]+(?:[./][\d]+)?ri?)\b/},h=t.constantNumericComplex={token:"constant.numeric",regex:/\b([\d]i)\b/},f=t.constantNumericFloat={token:"constant.numeric",regex:"[+-]?\\d(?:\\d|_(?=\\d))*(?:(?:\\.\\d(?:\\d|_(?=\\d))*)?(?:[eE][+-]?\\d+)?)?i?\\b"},d=t.instanceVariable={token:"variable.instance",regex:"@{1,2}[a-zA-Z_\\d]+"},p=function(){var e="abort|Array|assert|assert_equal|assert_not_equal|assert_same|assert_not_same|assert_nil|assert_not_nil|assert_match|assert_no_match|assert_in_delta|assert_throws|assert_raise|assert_nothing_raised|assert_instance_of|assert_kind_of|assert_respond_to|assert_operator|assert_send|assert_difference|assert_no_difference|assert_recognizes|assert_generates|assert_response|assert_redirected_to|assert_template|assert_select|assert_select_email|assert_select_rjs|assert_select_encoded|css_select|at_exit|attr|attr_writer|attr_reader|attr_accessor|attr_accessible|autoload|binding|block_given?|callcc|caller|catch|chomp|chomp!|chop|chop!|defined?|delete_via_redirect|eval|exec|exit|exit!|fail|Float|flunk|follow_redirect!|fork|form_for|form_tag|format|gets|global_variables|gsub|gsub!|get_via_redirect|host!|https?|https!|include|Integer|lambda|link_to|link_to_unless_current|link_to_function|link_to_remote|load|local_variables|loop|open|open_session|p|print|printf|proc|putc|puts|post_via_redirect|put_via_redirect|raise|rand|raw|readline|readlines|redirect?|request_via_redirect|require|scan|select|set_trace_func|sleep|split|sprintf|srand|String|stylesheet_link_tag|syscall|system|sub|sub!|test|throw|trace_var|trap|untrace_var|atan2|cos|exp|frexp|ldexp|log|log10|sin|sqrt|tan|render|javascript_include_tag|csrf_meta_tag|label_tag|text_field_tag|submit_tag|check_box_tag|content_tag|radio_button_tag|text_area_tag|password_field_tag|hidden_field_tag|fields_for|select_tag|options_for_select|options_from_collection_for_select|collection_select|time_zone_select|select_date|select_time|select_datetime|date_select|time_select|datetime_select|select_year|select_month|select_day|select_hour|select_minute|select_second|file_field_tag|file_field|respond_to|skip_before_filter|around_filter|after_filter|verify|protect_from_forgery|rescue_from|helper_method|redirect_to|before_filter|send_data|send_file|validates_presence_of|validates_uniqueness_of|validates_length_of|validates_format_of|validates_acceptance_of|validates_associated|validates_exclusion_of|validates_inclusion_of|validates_numericality_of|validates_with|validates_each|authenticate_or_request_with_http_basic|authenticate_or_request_with_http_digest|filter_parameter_logging|match|get|post|resources|redirect|scope|assert_routing|translate|localize|extract_locale_from_tld|caches_page|expire_page|caches_action|expire_action|cache|expire_fragment|expire_cache_for|observe|cache_sweeper|has_many|has_one|belongs_to|has_and_belongs_to_many|p|warn|refine|using|module_function|extend|alias_method|private_class_method|remove_method|undef_method",t="alias|and|BEGIN|begin|break|case|class|def|defined|do|else|elsif|END|end|ensure|__FILE__|finally|for|gem|if|in|__LINE__|module|next|not|or|private|protected|public|redo|rescue|retry|return|super|then|undef|unless|until|when|while|yield|__ENCODING__|prepend",n="true|TRUE|false|FALSE|nil|NIL|ARGF|ARGV|DATA|ENV|RUBY_PLATFORM|RUBY_RELEASE_DATE|RUBY_VERSION|STDERR|STDIN|STDOUT|TOPLEVEL_BINDING|RUBY_PATCHLEVEL|RUBY_REVISION|RUBY_COPYRIGHT|RUBY_ENGINE|RUBY_ENGINE_VERSION|RUBY_DESCRIPTION",r="$DEBUG|$defout|$FILENAME|$LOAD_PATH|$SAFE|$stdin|$stdout|$stderr|$VERBOSE|$!|root_url|flash|session|cookies|params|request|response|logger|self",i=this.$keywords=this.createKeywordMapper({keyword:t,"constant.language":n,"variable.language":r,"support.function":e,"invalid.deprecated":"debugger"},"identifier"),p="\\\\(?:n(?:[1-7][0-7]{0,2}|0)|[nsrtvfbae'\"\\\\]|c(?:\\\\M-)?.|M-(?:\\\\C-|\\\\c)?.|C-(?:\\\\M-)?.|[0-7]{3}|x[\\da-fA-F]{2}|u[\\da-fA-F]{4}|u{[\\da-fA-F]{1,6}(?:\\s[\\da-fA-F]{1,6})*})",g={"(":")","[":"]","{":"}","<":">","^":"^","|":"|","%":"%"};this.$rules={start:[{token:"comment",regex:"#.*$"},{token:"comment.multiline",regex:"^=begin(?=$|\\s.*$)",next:"comment"},{token:"string.regexp",regex:/[/](?=.*\/)/,next:"regex"},[{token:["constant.other.symbol.ruby","string.start"],regex:/(:)?(")/,push:[{token:"constant.language.escape",regex:p},{token:"paren.start",regex:/#{/,push:"start"},{token:"string.end",regex:/"/,next:"pop"},{defaultToken:"string"}]},{token:"string.start",regex:/`/,push:[{token:"constant.language.escape",regex:p},{token:"paren.start",regex:/#{/,push:"start"},{token:"string.end",regex:/`/,next:"pop"},{defaultToken:"string"}]},{token:["constant.other.symbol.ruby","string.start"],regex:/(:)?(')/,push:[{token:"constant.language.escape",regex:/\\['\\]/},{token:"string.end",regex:/'/,next:"pop"},{defaultToken:"string"}]},{token:"string.start",regex:/%[qwx]([(\[<{^|%])/,onMatch:function(e,t,n){n.length&&(n=[]);var r=e[e.length-1];return n.unshift(r,t),this.next="qStateWithoutInterpolation",this.token}},{token:"string.start",regex:/%[QWX]?([(\[<{^|%])/,onMatch:function(e,t,n){n.length&&(n=[]);var r=e[e.length-1];return n.unshift(r,t),this.next="qStateWithInterpolation",this.token}},{token:"constant.other.symbol.ruby",regex:/%[si]([(\[<{^|%])/,onMatch:function(e,t,n){n.length&&(n=[]);var r=e[e.length-1];return n.unshift(r,t),this.next="sStateWithoutInterpolation",this.token}},{token:"constant.other.symbol.ruby",regex:/%[SI]([(\[<{^|%])/,onMatch:function(e,t,n){n.length&&(n=[]);var r=e[e.length-1];return n.unshift(r,t),this.next="sStateWithInterpolation",this.token}},{token:"string.regexp",regex:/%[r]([(\[<{^|%])/,onMatch:function(e,t,n){n.length&&(n=[]);var r=e[e.length-1];return n.unshift(r,t),this.next="rState",this.token}}],{token:"punctuation",regex:"::"},d,{token:"variable.global",regex:"[$][a-zA-Z_\\d]+"},{token:"support.class",regex:"[A-Z][a-zA-Z_\\d]*"},{token:["punctuation.operator","support.function"],regex:/(\.)([a-zA-Z_\d]+)(?=\()/},{token:["punctuation.operator","identifier"],regex:/(\.)([a-zA-Z_][a-zA-Z_\d]*)/},{token:"string.character",regex:"\\B\\?(?:"+p+"|\\S)"},{token:"punctuation.operator",regex:/\?(?=.+:)/},u,h,o,s,f,a,l,c,{token:"constant.language.boolean",regex:"(?:true|false)\\b"},{token:i,regex:"[a-zA-Z_$][a-zA-Z0-9_$]*\\b"},{token:"punctuation.separator.key-value",regex:"=>"},{stateName:"heredoc",onMatch:function(e,t,n){var r="-"==e[2]||"~"==e[2]?"indentedHeredoc":"heredoc",i=e.split(this.splitRegex);return n.push(r,i[3]),[{type:"constant",value:i[1]},{type:"string",value:i[2]},{type:"support.class",value:i[3]},{type:"string",value:i[4]}]},regex:"(<<[-~]?)(['\"`]?)([\\w]+)(['\"`]?)",rules:{heredoc:[{onMatch:function(e,t,n){return e===n[1]?(n.shift(),n.shift(),this.next=n[0]||"start","support.class"):(this.next="","string")},regex:".*$",next:"start"}],indentedHeredoc:[{token:"string",regex:"^ +"},{onMatch:function(e,t,n){return e===n[1]?(n.shift(),n.shift(),this.next=n[0]||"start","support.class"):(this.next="","string")},regex:".*$",next:"start"}]}},{regex:"$",token:"empty",next:function(e,t){return"heredoc"===t[0]||"indentedHeredoc"===t[0]?t[0]:e}},{token:"keyword.operator",regex:"!|\\$|%|&|\\*|/|\\-\\-|\\-|\\+\\+|\\+|~|===|==|=|!=|!==|<=|>=|<<=|>>=|>>>=|<>|<|>|!|&&|\\|\\||\\?\\:|\\*=|%=|\\+=|\\-=|&=|\\^=|\\||\\b(?:in|instanceof|new|delete|typeof|void)"},{token:"paren.lparen",regex:"[[({]"},{token:"paren.rparen",regex:"[\\])}]",onMatch:function(e,t,n){return this.next="","}"==e&&n.length>1&&"start"!=n[1]&&(n.shift(),this.next=n.shift()),this.token}},{token:"text",regex:"\\s+"},{token:"punctuation.operator",regex:/[?:,;.]/}],comment:[{token:"comment.multiline",regex:"^=end(?=$|\\s.*$)",next:"start"},{token:"comment",regex:".+"}],qStateWithInterpolation:[{token:"string.start",regex:/[(\[<{]/,onMatch:function(e,t,n){return n.length&&e===n[0]?(n.unshift(e,t),this.token):"string"}},{token:"constant.language.escape",regex:p},{token:"constant.language.escape",regex:/\\./},{token:"paren.start",regex:/#{/,push:"start"},{token:"string.end",regex:/[)\]>}^|%]/,onMatch:function(e,t,n){return n.length&&e===g[n[0]]?(n.shift(),this.next=n.shift(),this.token):(this.next="","string")}},{defaultToken:"string"}],qStateWithoutInterpolation:[{token:"string.start",regex:/[(\[<{]/,onMatch:function(e,t,n){return n.length&&e===n[0]?(n.unshift(e,t),this.token):"string"}},{token:"constant.language.escape",regex:/\\['\\]/},{token:"constant.language.escape",regex:/\\./},{token:"string.end",regex:/[)\]>}^|%]/,onMatch:function(e,t,n){return n.length&&e===g[n[0]]?(n.shift(),this.next=n.shift(),this.token):(this.next="","string")}},{defaultToken:"string"}],sStateWithoutInterpolation:[{token:"constant.other.symbol.ruby",regex:/[(\[<{]/,onMatch:function(e,t,n){return n.length&&e===n[0]?(n.unshift(e,t),this.token):"constant.other.symbol.ruby"}},{token:"constant.other.symbol.ruby",regex:/[)\]>}^|%]/,onMatch:function(e,t,n){return n.length&&e===g[n[0]]?(n.shift(),this.next=n.shift(),this.token):(this.next="","constant.other.symbol.ruby")}},{defaultToken:"constant.other.symbol.ruby"}],sStateWithInterpolation:[{token:"constant.other.symbol.ruby",regex:/[(\[<{]/,onMatch:function(e,t,n){return n.length&&e===n[0]?(n.unshift(e,t),this.token):"constant.other.symbol.ruby"}},{token:"constant.language.escape",regex:p},{token:"constant.language.escape",regex:/\\./},{token:"paren.start",regex:/#{/,push:"start"},{token:"constant.other.symbol.ruby",regex:/[)\]>}^|%]/,onMatch:function(e,t,n){return n.length&&e===g[n[0]]?(n.shift(),this.next=n.shift(),this.token):(this.next="","constant.other.symbol.ruby")}},{defaultToken:"constant.other.symbol.ruby"}],rState:[{token:"string.regexp",regex:/[(\[<{]/,onMatch:function(e,t,n){return n.length&&e===n[0]?(n.unshift(e,t),this.token):"constant.language.escape"}},{token:"paren.start",regex:/#{/,push:"start"},{token:"string.regexp",regex:/\//},{token:"string.regexp",regex:/[)\]>}^|%][imxouesn]*/,onMatch:function(e,t,n){return n.length&&e[0]===g[n[0]]?(n.shift(),this.next=n.shift(),this.token):(this.next="","constant.language.escape")}},{include:"regex"},{defaultToken:"string.regexp"}],regex:[{token:"regexp.keyword",regex:/\\[wWdDhHsS]/},{token:"constant.language.escape",regex:/\\[AGbBzZ]/},{token:"constant.language.escape",regex:/\\g<[a-zA-Z0-9]*>/},{token:["constant.language.escape","regexp.keyword","constant.language.escape"],regex:/(\\p{\^?)(Alnum|Alpha|Blank|Cntrl|Digit|Graph|Lower|Print|Punct|Space|Upper|XDigit|Word|ASCII|Any|Assigned|Arabic|Armenian|Balinese|Bengali|Bopomofo|Braille|Buginese|Buhid|Canadian_Aboriginal|Carian|Cham|Cherokee|Common|Coptic|Cuneiform|Cypriot|Cyrillic|Deseret|Devanagari|Ethiopic|Georgian|Glagolitic|Gothic|Greek|Gujarati|Gurmukhi|Han|Hangul|Hanunoo|Hebrew|Hiragana|Inherited|Kannada|Katakana|Kayah_Li|Kharoshthi|Khmer|Lao|Latin|Lepcha|Limbu|Linear_B|Lycian|Lydian|Malayalam|Mongolian|Myanmar|New_Tai_Lue|Nko|Ogham|Ol_Chiki|Old_Italic|Old_Persian|Oriya|Osmanya|Phags_Pa|Phoenician|Rejang|Runic|Saurashtra|Shavian|Sinhala|Sundanese|Syloti_Nagri|Syriac|Tagalog|Tagbanwa|Tai_Le|Tamil|Telugu|Thaana|Thai|Tibetan|Tifinagh|Ugaritic|Vai|Yi|Ll|Lm|Lt|Lu|Lo|Mn|Mc|Me|Nd|Nl|Pc|Pd|Ps|Pe|Pi|Pf|Po|No|Sm|Sc|Sk|So|Zs|Zl|Zp|Cc|Cf|Cn|Co|Cs|N|L|M|P|S|Z|C)(})/},{token:["constant.language.escape","invalid","constant.language.escape"],regex:/(\\p{\^?)([^/]*)(})/},{token:"regexp.keyword.operator",regex:"\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"},{token:"string.regexp",regex:/[/][imxouesn]*/,next:"start"},{token:"invalid",regex:/\{\d+\b,?\d*\}[+*]|[+*$^?][+*]|[$^][?]|\?{3,}/},{token:"constant.language.escape",regex:/\(\?(?:[:=!>]|<'?[a-zA-Z]*'?>|<[=!])|\)|\{\d+\b,?\d*\}|[+*]\?|[()$^+*?.]/},{token:"constant.language.delimiter",regex:/\|/},{token:"regexp.keyword",regex:/\[\[:(?:alnum|alpha|blank|cntrl|digit|graph|lower|print|punct|space|upper|xdigit|word|ascii):\]\]/},{token:"constant.language.escape",regex:/\[\^?/,push:"regex_character_class"},{defaultToken:"string.regexp"}],regex_character_class:[{token:"regexp.keyword",regex:/\\[wWdDhHsS]/},{token:"regexp.charclass.keyword.operator",regex:"\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"},{token:"constant.language.escape",regex:/&?&?\[\^?/,push:"regex_character_class"},{token:"constant.language.escape",regex:"]",next:"pop"},{token:"constant.language.escape",regex:"-"},{defaultToken:"string.regexp.characterclass"}]},this.normalizeRules()};r.inherits(p,i),t.RubyHighlightRules=p})),ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"],(function(e,t,n){"use strict";var r=e("../range").Range,i=function(){};(function(){this.checkOutdent=function(e,t){return!!/^\s+$/.test(e)&&/^\s*\}/.test(t)},this.autoOutdent=function(e,t){var n=e.getLine(t),i=n.match(/^(\s*\})/);if(!i)return 0;var o=i[1].length,s=e.findMatchingBracket({row:t,column:o});if(!s||s.row==t)return 0;var a=this.$getIndent(e.getLine(s.row));e.replace(new r(t,0,t,o-1),a)},this.$getIndent=function(e){return e.match(/^\s*/)[0]}}).call(i.prototype),t.MatchingBraceOutdent=i})),ace.define("ace/mode/folding/ruby",["require","exports","module","ace/lib/oop","ace/mode/folding/fold_mode","ace/range","ace/token_iterator"],(function(e,t,n){"use strict";var r=e("../../lib/oop"),i=e("./fold_mode").FoldMode,o=e("../../range").Range,s=e("../../token_iterator").TokenIterator,a=t.FoldMode=function(){};r.inherits(a,i),function(){this.indentKeywords={class:1,def:1,module:1,do:1,unless:1,if:1,while:1,for:1,until:1,begin:1,else:0,elsif:0,rescue:0,ensure:0,when:0,end:-1,case:1,"=begin":1,"=end":-1},this.foldingStartMarker=/(?:\s|^)(def|do|while|class|unless|module|if|for|until|begin|else|elsif|case|rescue|ensure|when)\b|({\s*$)|(=begin)/,this.foldingStopMarker=/(=end(?=$|\s.*$))|(^\s*})|\b(end)\b/,this.getFoldWidget=function(e,t,n){var r=e.getLine(n),i=this.foldingStartMarker.test(r),o=this.foldingStopMarker.test(r);if(i&&!o){var s=r.match(this.foldingStartMarker);if(s[1]){if("if"==s[1]||"else"==s[1]||"while"==s[1]||"until"==s[1]||"unless"==s[1]){if("else"==s[1]&&!1===/^\s*else\s*$/.test(r))return;if(!1===/^\s*(?:if|else|while|until|unless)\s*/.test(r))return}if("when"==s[1]&&!0===/\sthen\s/.test(r))return;if("keyword"===e.getTokenAt(n,s.index+2).type)return"start"}else{if(!s[3])return"start";if("comment.multiline"===e.getTokenAt(n,s.index+1).type)return"start"}}if("markbeginend"!=t||!o||i&&o)return"";s=r.match(this.foldingStopMarker);if("end"===s[3]){if("keyword"===e.getTokenAt(n,s.index+1).type)return"end"}else{if(!s[1])return"end";if("comment.multiline"===e.getTokenAt(n,s.index+1).type)return"end"}},this.getFoldWidgetRange=function(e,t,n){var r=e.doc.getLine(n),i=this.foldingStartMarker.exec(r);if(i)return i[1]||i[3]?this.rubyBlock(e,n,i.index+2):this.openingBracketBlock(e,"{",n,i.index);i=this.foldingStopMarker.exec(r);return i?"end"===i[3]&&"keyword"===e.getTokenAt(n,i.index+1).type||"=end"===i[1]&&"comment.multiline"===e.getTokenAt(n,i.index+1).type?this.rubyBlock(e,n,i.index+1):this.closingBracketBlock(e,"}",n,i.index+i[0].length):void 0},this.rubyBlock=function(e,t,n,r){var i=new s(e,t,n),a=i.getCurrentToken();if(a&&("keyword"==a.type||"comment.multiline"==a.type)){var l=a.value,c=e.getLine(t);switch(a.value){case"if":case"unless":case"while":case"until":var u=new RegExp("^\\s*"+a.value);if(!u.test(c))return;var h=this.indentKeywords[l];break;case"when":if(/\sthen\s/.test(c))return;case"elsif":case"rescue":case"ensure":h=1;break;case"else":u=new RegExp("^\\s*"+a.value+"\\s*$");if(!u.test(c))return;h=1;break;default:h=this.indentKeywords[l]}var f=[l];if(h){var d=-1===h?e.getLine(t-1).length:e.getLine(t).length,p=t,g=[];if(g.push(i.getCurrentTokenRange()),i.step=-1===h?i.stepBackward:i.stepForward,"comment.multiline"==a.type){while(a=i.step())if("comment.multiline"===a.type)if(1==h){if(d=6,"=end"==a.value)break}else if("=begin"==a.value)break}else while(a=i.step()){var m=!1;if("keyword"===a.type){var v=h*this.indentKeywords[a.value];switch(c=e.getLine(i.getCurrentTokenRow()),a.value){case"do":for(var y=i.$tokenIndex-1;y>=0;y--){var w=i.$rowTokens[y];if(w&&("while"==w.value||"until"==w.value||"for"==w.value)){v=0;break}}break;case"else":u=new RegExp("^\\s*"+a.value+"\\s*$");u.test(c)&&"case"!=l||(v=0,m=!0);break;case"if":case"unless":case"while":case"until":u=new RegExp("^\\s*"+a.value);u.test(c)||(v=0,m=!0);break;case"when":(/\sthen\s/.test(c)||"case"==l)&&(v=0,m=!0)}if(v>0)f.unshift(a.value);else if(v<=0&&!1===m){if(f.shift(),!f.length){if(("while"==l||"until"==l||"for"==l)&&"do"!=a.value)break;if("do"==a.value&&-1==h&&0!=v)break;if("do"!=a.value)break}0===v&&f.unshift(a.value)}}}if(!a)return null;if(r)return g.push(i.getCurrentTokenRange()),g;t=i.getCurrentTokenRow();if(-1===h){if("comment.multiline"===a.type)var b=6;else b=e.getLine(t).length;return new o(t,b,p-1,d)}return new o(p,d,t-1,e.getLine(t-1).length)}}}}.call(a.prototype)})),ace.define("ace/mode/ruby",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/ruby_highlight_rules","ace/mode/matching_brace_outdent","ace/range","ace/mode/behaviour/cstyle","ace/mode/folding/ruby"],(function(e,t,n){"use strict";var r=e("../lib/oop"),i=e("./text").Mode,o=e("./ruby_highlight_rules").RubyHighlightRules,s=e("./matching_brace_outdent").MatchingBraceOutdent,a=e("../range").Range,l=e("./behaviour/cstyle").CstyleBehaviour,c=e("./folding/ruby").FoldMode,u=function(){this.HighlightRules=o,this.$outdent=new s,this.$behaviour=new l,this.foldingRules=new c,this.indentKeywords=this.foldingRules.indentKeywords};r.inherits(u,i),function(){this.lineCommentStart="#",this.getNextLineIndent=function(e,t,n){var r=this.$getIndent(t),i=this.getTokenizer().getLineTokens(t,e),o=i.tokens;if(o.length&&"comment"==o[o.length-1].type)return r;if("start"==e){var s=t.match(/^.*[\{\(\[]\s*$/),a=t.match(/^\s*(class|def|module)\s.*$/),l=t.match(/.*do(\s*|\s+\|.*\|\s*)$/),c=t.match(/^\s*(if|else|when|elsif|unless|while|for|begin|rescue|ensure)\s*/);(s||a||l||c)&&(r+=n)}return r},this.checkOutdent=function(e,t,n){return/^\s+(end|else|rescue|ensure)$/.test(t+n)||this.$outdent.checkOutdent(t,n)},this.autoOutdent=function(e,t,n){var r=t.getLine(n);if(/}/.test(r))return this.$outdent.autoOutdent(t,n);var i=this.$getIndent(r),o=t.getLine(n-1),s=this.$getIndent(o),l=t.getTabString();s.length<=i.length&&i.slice(-l.length)==l&&t.remove(new a(n,i.length-l.length,n,i.length))},this.getMatching=function(e,t,n){if(void 0==t){var r=e.selection.lead;n=r.column,t=r.row}var i=e.getTokenAt(t,n);if(i&&i.value in this.indentKeywords)return this.foldingRules.rubyBlock(e,t,n,!0)},this.$id="ace/mode/ruby",this.snippetFileId="ace/snippets/ruby"}.call(u.prototype),t.Mode=u})),function(){ace.require(["ace/mode/ruby"],(function(t){e&&(e.exports=t)}))}()},71747:function(e,t,n){e=n.nmd(e),function(){ace.require(["ace/mode/text"],(function(t){e&&(e.exports=t)}))}()},40419:function(e,t,n){e=n.nmd(e),ace.define("ace/theme/twilight.css",["require","exports","module"],(function(e,t,n){n.exports=".ace-twilight .ace_gutter {\n background: #232323;\n color: #E2E2E2\n}\n\n.ace-twilight .ace_print-margin {\n width: 1px;\n background: #232323\n}\n\n.ace-twilight {\n background-color: #141414;\n color: #F8F8F8\n}\n\n.ace-twilight .ace_cursor {\n color: #A7A7A7\n}\n\n.ace-twilight .ace_marker-layer .ace_selection {\n background: rgba(221, 240, 255, 0.20)\n}\n\n.ace-twilight.ace_multiselect .ace_selection.ace_start {\n box-shadow: 0 0 3px 0px #141414;\n}\n\n.ace-twilight .ace_marker-layer .ace_step {\n background: rgb(102, 82, 0)\n}\n\n.ace-twilight .ace_marker-layer .ace_bracket {\n margin: -1px 0 0 -1px;\n border: 1px solid rgba(255, 255, 255, 0.25)\n}\n\n.ace-twilight .ace_marker-layer .ace_active-line {\n background: rgba(255, 255, 255, 0.031)\n}\n\n.ace-twilight .ace_gutter-active-line {\n background-color: rgba(255, 255, 255, 0.031)\n}\n\n.ace-twilight .ace_marker-layer .ace_selected-word {\n border: 1px solid rgba(221, 240, 255, 0.20)\n}\n\n.ace-twilight .ace_invisible {\n color: rgba(255, 255, 255, 0.25)\n}\n\n.ace-twilight .ace_keyword,\n.ace-twilight .ace_meta {\n color: #CDA869\n}\n\n.ace-twilight .ace_constant,\n.ace-twilight .ace_constant.ace_character,\n.ace-twilight .ace_constant.ace_character.ace_escape,\n.ace-twilight .ace_constant.ace_other,\n.ace-twilight .ace_heading,\n.ace-twilight .ace_markup.ace_heading,\n.ace-twilight .ace_support.ace_constant {\n color: #CF6A4C\n}\n\n.ace-twilight .ace_invalid.ace_illegal {\n color: #F8F8F8;\n background-color: rgba(86, 45, 86, 0.75)\n}\n\n.ace-twilight .ace_invalid.ace_deprecated {\n text-decoration: underline;\n font-style: italic;\n color: #D2A8A1\n}\n\n.ace-twilight .ace_support {\n color: #9B859D\n}\n\n.ace-twilight .ace_fold {\n background-color: #AC885B;\n border-color: #F8F8F8\n}\n\n.ace-twilight .ace_support.ace_function {\n color: #DAD085\n}\n\n.ace-twilight .ace_list,\n.ace-twilight .ace_markup.ace_list,\n.ace-twilight .ace_storage {\n color: #F9EE98\n}\n\n.ace-twilight .ace_entity.ace_name.ace_function,\n.ace-twilight .ace_meta.ace_tag {\n color: #AC885B\n}\n\n.ace-twilight .ace_string {\n color: #8F9D6A\n}\n\n.ace-twilight .ace_string.ace_regexp {\n color: #E9C062\n}\n\n.ace-twilight .ace_comment {\n font-style: italic;\n color: #5F5A60\n}\n\n.ace-twilight .ace_variable {\n color: #7587A6\n}\n\n.ace-twilight .ace_xml-pe {\n color: #494949\n}\n\n.ace-twilight .ace_indent-guide {\n background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAEklEQVQImWMQERFpYLC1tf0PAAgOAnPnhxyiAAAAAElFTkSuQmCC) right repeat-y\n}\n\n.ace-twilight .ace_indent-guide-active {\n background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAEklEQVQIW2PQ1dX9zzBz5sz/ABCcBFFentLlAAAAAElFTkSuQmCC) right repeat-y;\n}\n"})),ace.define("ace/theme/twilight",["require","exports","module","ace/theme/twilight.css","ace/lib/dom"],(function(e,t,n){t.isDark=!0,t.cssClass="ace-twilight",t.cssText=e("./twilight.css");var r=e("../lib/dom");r.importCssString(t.cssText,t.cssClass,!1)})),function(){ace.require(["ace/theme/twilight"],(function(t){e&&(e.exports=t)}))}()},95095:function(e,t,n){e=n.nmd(e),function(){var e="ace",t=function(){return this}();if(t||"undefined"==typeof window||(t=window),e||"undefined"===typeof requirejs){var n=function(e,t,r){"string"===typeof e?(2==arguments.length&&(r=t),n.modules[e]||(n.payloads[e]=r,n.modules[e]=null)):n.original?n.original.apply(this,arguments):(console.error("dropping module because define wasn't a string."),console.trace())};n.modules={},n.payloads={};var r=function(e,t,n){if("string"===typeof t){var r=s(e,t);if(void 0!=r)return n&&n(),r}else if("[object Array]"===Object.prototype.toString.call(t)){for(var o=[],a=0,l=t.length;a<l;++a){var c=s(e,t[a]);if(void 0==c&&i.original)return;o.push(c)}return n&&n.apply(null,o)||!0}},i=function(e,t){var n=r("",e,t);return void 0==n&&i.original?i.original.apply(this,arguments):n},o=function(e,t){if(-1!==t.indexOf("!")){var n=t.split("!");return o(e,n[0])+"!"+o(e,n[1])}if("."==t.charAt(0)){var r=e.split("/").slice(0,-1).join("/");t=r+"/"+t;while(-1!==t.indexOf(".")&&i!=t){var i=t;t=t.replace(/\/\.\//,"/").replace(/[^\/]+\/\.\.\//,"")}}return t},s=function(e,t){t=o(e,t);var i=n.modules[t];if(!i){if(i=n.payloads[t],"function"===typeof i){var s={},a={id:t,uri:"",exports:s,packaged:!0},l=function(e,n){return r(t,e,n)},c=i(l,s,a);s=c||a.exports,n.modules[t]=s,delete n.payloads[t]}i=n.modules[t]=s||i}return i};a(e)}function a(e){var r=t;e&&(t[e]||(t[e]={}),r=t[e]),r.define&&r.define.packaged||(n.original=r.define,r.define=n,r.define.packaged=!0),r.require&&r.require.packaged||(i.original=r.require,r.require=i,r.require.packaged=!0)}}(),ace.define("ace/lib/es6-shim",["require","exports","module"],(function(e,t,n){function r(e,t,n){Object.defineProperty(e,t,{value:n,enumerable:!1,writable:!0,configurable:!0})}String.prototype.startsWith||r(String.prototype,"startsWith",(function(e,t){return t=t||0,this.lastIndexOf(e,t)===t})),String.prototype.endsWith||r(String.prototype,"endsWith",(function(e,t){var n=this;(void 0===t||t>n.length)&&(t=n.length),t-=e.length;var r=n.indexOf(e,t);return-1!==r&&r===t})),String.prototype.repeat||r(String.prototype,"repeat",(function(e){var t="",n=this;while(e>0)1&e&&(t+=n),(e>>=1)&&(n+=n);return t})),String.prototype.includes||r(String.prototype,"includes",(function(e,t){return-1!=this.indexOf(e,t)})),Object.assign||(Object.assign=function(e){if(void 0===e||null===e)throw new TypeError("Cannot convert undefined or null to object");for(var t=Object(e),n=1;n<arguments.length;n++){var r=arguments[n];void 0!==r&&null!==r&&Object.keys(r).forEach((function(e){t[e]=r[e]}))}return t}),Object.values||(Object.values=function(e){return Object.keys(e).map((function(t){return e[t]}))}),Array.prototype.find||r(Array.prototype,"find",(function(e){for(var t=this.length,n=arguments[1],r=0;r<t;r++){var i=this[r];if(e.call(n,i,r,this))return i}})),Array.prototype.findIndex||r(Array.prototype,"findIndex",(function(e){for(var t=this.length,n=arguments[1],r=0;r<t;r++){var i=this[r];if(e.call(n,i,r,this))return r}})),Array.prototype.includes||r(Array.prototype,"includes",(function(e,t){return-1!=this.indexOf(e,t)})),Array.prototype.fill||r(Array.prototype,"fill",(function(e){var t=this,n=t.length>>>0,r=arguments[1],i=r>>0,o=i<0?Math.max(n+i,0):Math.min(i,n),s=arguments[2],a=void 0===s?n:s>>0,l=a<0?Math.max(n+a,0):Math.min(a,n);while(o<l)t[o]=e,o++;return t})),Array.of||r(Array,"of",(function(){return Array.prototype.slice.call(arguments)}))})),ace.define("ace/lib/fixoldbrowsers",["require","exports","module","ace/lib/es6-shim"],(function(e,t,n){"use strict";e("./es6-shim")})),ace.define("ace/lib/lang",["require","exports","module"],(function(e,t,n){"use strict";t.last=function(e){return e[e.length-1]},t.stringReverse=function(e){return e.split("").reverse().join("")},t.stringRepeat=function(e,t){var n="";while(t>0)1&t&&(n+=e),(t>>=1)&&(e+=e);return n};var r=/^\s\s*/,i=/\s\s*$/;t.stringTrimLeft=function(e){return e.replace(r,"")},t.stringTrimRight=function(e){return e.replace(i,"")},t.copyObject=function(e){var t={};for(var n in e)t[n]=e[n];return t},t.copyArray=function(e){for(var t=[],n=0,r=e.length;n<r;n++)e[n]&&"object"==typeof e[n]?t[n]=this.copyObject(e[n]):t[n]=e[n];return t},t.deepCopy=function e(t){if("object"!==typeof t||!t)return t;var n;if(Array.isArray(t)){n=[];for(var r=0;r<t.length;r++)n[r]=e(t[r]);return n}if("[object Object]"!==Object.prototype.toString.call(t))return t;for(var r in n={},t)n[r]=e(t[r]);return n},t.arrayToMap=function(e){for(var t={},n=0;n<e.length;n++)t[e[n]]=1;return t},t.createMap=function(e){var t=Object.create(null);for(var n in e)t[n]=e[n];return t},t.arrayRemove=function(e,t){for(var n=0;n<=e.length;n++)t===e[n]&&e.splice(n,1)},t.escapeRegExp=function(e){return e.replace(/([.*+?^${}()|[\]\/\\])/g,"\\$1")},t.escapeHTML=function(e){return(""+e).replace(/&/g,"&#38;").replace(/"/g,"&#34;").replace(/'/g,"&#39;").replace(/</g,"&#60;")},t.getMatchOffsets=function(e,t){var n=[];return e.replace(t,(function(e){n.push({offset:arguments[arguments.length-2],length:e.length})})),n},t.deferredCall=function(e){var t=null,n=function(){t=null,e()},r=function(e){return r.cancel(),t=setTimeout(n,e||0),r};return r.schedule=r,r.call=function(){return this.cancel(),e(),r},r.cancel=function(){return clearTimeout(t),t=null,r},r.isPending=function(){return t},r},t.delayedCall=function(e,t){var n=null,r=function(){n=null,e()},i=function(e){null==n&&(n=setTimeout(r,e||t))};return i.delay=function(e){n&&clearTimeout(n),n=setTimeout(r,e||t)},i.schedule=i,i.call=function(){this.cancel(),e()},i.cancel=function(){n&&clearTimeout(n),n=null},i.isPending=function(){return n},i}})),ace.define("ace/lib/useragent",["require","exports","module"],(function(e,t,n){"use strict";t.OS={LINUX:"LINUX",MAC:"MAC",WINDOWS:"WINDOWS"},t.getOS=function(){return t.isMac?t.OS.MAC:t.isLinux?t.OS.LINUX:t.OS.WINDOWS};var r="object"==typeof navigator?navigator:{},i=(/mac|win|linux/i.exec(r.platform)||["other"])[0].toLowerCase(),o=r.userAgent||"",s=r.appName||"";t.isWin="win"==i,t.isMac="mac"==i,t.isLinux="linux"==i,t.isIE="Microsoft Internet Explorer"==s||s.indexOf("MSAppHost")>=0?parseFloat((o.match(/(?:MSIE |Trident\/[0-9]+[\.0-9]+;.*rv:)([0-9]+[\.0-9]+)/)||[])[1]):parseFloat((o.match(/(?:Trident\/[0-9]+[\.0-9]+;.*rv:)([0-9]+[\.0-9]+)/)||[])[1]),t.isOldIE=t.isIE&&t.isIE<9,t.isGecko=t.isMozilla=o.match(/ Gecko\/\d+/),t.isOpera="object"==typeof opera&&"[object Opera]"==Object.prototype.toString.call(window.opera),t.isWebKit=parseFloat(o.split("WebKit/")[1])||void 0,t.isChrome=parseFloat(o.split(" Chrome/")[1])||void 0,t.isEdge=parseFloat(o.split(" Edge/")[1])||void 0,t.isAIR=o.indexOf("AdobeAIR")>=0,t.isAndroid=o.indexOf("Android")>=0,t.isChromeOS=o.indexOf(" CrOS ")>=0,t.isIOS=/iPad|iPhone|iPod/.test(o)&&!window.MSStream,t.isIOS&&(t.isMac=!0),t.isMobile=t.isIOS||t.isAndroid})),ace.define("ace/lib/dom",["require","exports","module","ace/lib/useragent"],(function(e,t,n){"use strict";var r,i=e("./useragent"),o="http://www.w3.org/1999/xhtml";t.buildDom=function e(t,n,r){if("string"==typeof t&&t){var i=document.createTextNode(t);return n&&n.appendChild(i),i}if(!Array.isArray(t))return t&&t.appendChild&&n&&n.appendChild(t),t;if("string"!=typeof t[0]||!t[0]){for(var o=[],s=0;s<t.length;s++){var a=e(t[s],n,r);a&&o.push(a)}return o}var l=document.createElement(t[0]),c=t[1],u=1;c&&"object"==typeof c&&!Array.isArray(c)&&(u=2);for(s=u;s<t.length;s++)e(t[s],l,r);return 2==u&&Object.keys(c).forEach((function(e){var t=c[e];"class"===e?l.className=Array.isArray(t)?t.join(" "):t:"function"==typeof t||"value"==e||"$"==e[0]?l[e]=t:"ref"===e?r&&(r[t]=l):"style"===e?"string"==typeof t&&(l.style.cssText=t):null!=t&&l.setAttribute(e,t)})),n&&n.appendChild(l),l},t.getDocumentHead=function(e){return e||(e=document),e.head||e.getElementsByTagName("head")[0]||e.documentElement},t.createElement=function(e,t){return document.createElementNS?document.createElementNS(t||o,e):document.createElement(e)},t.removeChildren=function(e){e.innerHTML=""},t.createTextNode=function(e,t){var n=t?t.ownerDocument:document;return n.createTextNode(e)},t.createFragment=function(e){var t=e?e.ownerDocument:document;return t.createDocumentFragment()},t.hasCssClass=function(e,t){var n=(e.className+"").split(/\s+/g);return-1!==n.indexOf(t)},t.addCssClass=function(e,n){t.hasCssClass(e,n)||(e.className+=" "+n)},t.removeCssClass=function(e,t){var n=e.className.split(/\s+/g);while(1){var r=n.indexOf(t);if(-1==r)break;n.splice(r,1)}e.className=n.join(" ")},t.toggleCssClass=function(e,t){var n=e.className.split(/\s+/g),r=!0;while(1){var i=n.indexOf(t);if(-1==i)break;r=!1,n.splice(i,1)}return r&&n.push(t),e.className=n.join(" "),r},t.setCssClass=function(e,n,r){r?t.addCssClass(e,n):t.removeCssClass(e,n)},t.hasCssString=function(e,t){var n,r=0;if(t=t||document,n=t.querySelectorAll("style"))while(r<n.length)if(n[r++].id===e)return!0},t.removeElementById=function(e,t){t=t||document,t.getElementById(e)&&t.getElementById(e).remove()};var s=[];function a(){var e=s;s=null,e&&e.forEach((function(e){l(e[0],e[1])}))}function l(e,n,i){if("undefined"!=typeof document){if(s)if(i)a();else if(!1===i)return s.push([e,n]);if(!r){var o=i;i&&i.getRootNode?(o=i.getRootNode(),o&&o!=i||(o=document)):o=document;var l=o.ownerDocument||o;if(n&&t.hasCssString(n,o))return null;n&&(e+="\n/*# sourceURL=ace/css/"+n+" */");var c=t.createElement("style");c.appendChild(l.createTextNode(e)),n&&(c.id=n),o==l&&(o=t.getDocumentHead(l)),o.insertBefore(c,o.firstChild)}}}if(t.useStrictCSP=function(e){r=e,0==e?a():s||(s=[])},t.importCssString=l,t.importCssStylsheet=function(e,n){t.buildDom(["link",{rel:"stylesheet",href:e}],t.getDocumentHead(n))},t.scrollbarWidth=function(e){var n=t.createElement("ace_inner");n.style.width="100%",n.style.minWidth="0px",n.style.height="200px",n.style.display="block";var r=t.createElement("ace_outer"),i=r.style;i.position="absolute",i.left="-10000px",i.overflow="hidden",i.width="200px",i.minWidth="0px",i.height="150px",i.display="block",r.appendChild(n);var o=e&&e.documentElement||document&&document.documentElement;if(!o)return 0;o.appendChild(r);var s=n.offsetWidth;i.overflow="scroll";var a=n.offsetWidth;return s===a&&(a=r.clientWidth),o.removeChild(r),s-a},t.computedStyle=function(e,t){return window.getComputedStyle(e,"")||{}},t.setStyle=function(e,t,n){e[t]!==n&&(e[t]=n)},t.HAS_CSS_ANIMATION=!1,t.HAS_CSS_TRANSFORMS=!1,t.HI_DPI=!i.isWin||"undefined"!==typeof window&&window.devicePixelRatio>=1.5,i.isChromeOS&&(t.HI_DPI=!1),"undefined"!==typeof document){var c=document.createElement("div");t.HI_DPI&&void 0!==c.style.transform&&(t.HAS_CSS_TRANSFORMS=!0),i.isEdge||"undefined"===typeof c.style.animationName||(t.HAS_CSS_ANIMATION=!0),c=null}t.HAS_CSS_TRANSFORMS?t.translate=function(e,t,n){e.style.transform="translate("+Math.round(t)+"px, "+Math.round(n)+"px)"}:t.translate=function(e,t,n){e.style.top=Math.round(n)+"px",e.style.left=Math.round(t)+"px"}})),ace.define("ace/lib/net",["require","exports","module","ace/lib/dom"],(function(e,t,n){
2
+ /*
3
+ * based on code from:
4
+ *
5
+ * @license RequireJS text 0.25.0 Copyright (c) 2010-2011, The Dojo Foundation All Rights Reserved.
6
+ * Available via the MIT or new BSD license.
7
+ * see: http://github.com/jrburke/requirejs for details
8
+ */
9
+ "use strict";var r=e("./dom");t.get=function(e,t){var n=new XMLHttpRequest;n.open("GET",e,!0),n.onreadystatechange=function(){4===n.readyState&&t(n.responseText)},n.send(null)},t.loadScript=function(e,t){var n=r.getDocumentHead(),i=document.createElement("script");i.src=e,n.appendChild(i),i.onload=i.onreadystatechange=function(e,n){!n&&i.readyState&&"loaded"!=i.readyState&&"complete"!=i.readyState||(i=i.onload=i.onreadystatechange=null,n||t())}},t.qualifyURL=function(e){var t=document.createElement("a");return t.href=e,t.href}})),ace.define("ace/lib/oop",["require","exports","module"],(function(e,t,n){"use strict";t.inherits=function(e,t){e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}})},t.mixin=function(e,t){for(var n in t)e[n]=t[n];return e},t.implement=function(e,n){t.mixin(e,n)}})),ace.define("ace/lib/event_emitter",["require","exports","module"],(function(e,t,n){"use strict";var r={},i=function(){this.propagationStopped=!0},o=function(){this.defaultPrevented=!0};r._emit=r._dispatchEvent=function(e,t){this._eventRegistry||(this._eventRegistry={}),this._defaultHandlers||(this._defaultHandlers={});var n=this._eventRegistry[e]||[],r=this._defaultHandlers[e];if(n.length||r){"object"==typeof t&&t||(t={}),t.type||(t.type=e),t.stopPropagation||(t.stopPropagation=i),t.preventDefault||(t.preventDefault=o),n=n.slice();for(var s=0;s<n.length;s++)if(n[s](t,this),t.propagationStopped)break;return r&&!t.defaultPrevented?r(t,this):void 0}},r._signal=function(e,t){var n=(this._eventRegistry||{})[e];if(n){n=n.slice();for(var r=0;r<n.length;r++)n[r](t,this)}},r.once=function(e,t){var n=this;if(this.on(e,(function r(){n.off(e,r),t.apply(null,arguments)})),!t)return new Promise((function(e){t=e}))},r.setDefaultHandler=function(e,t){var n=this._defaultHandlers;if(n||(n=this._defaultHandlers={_disabled_:{}}),n[e]){var r=n[e],i=n._disabled_[e];i||(n._disabled_[e]=i=[]),i.push(r);var o=i.indexOf(t);-1!=o&&i.splice(o,1)}n[e]=t},r.removeDefaultHandler=function(e,t){var n=this._defaultHandlers;if(n){var r=n._disabled_[e];if(n[e]==t)r&&this.setDefaultHandler(e,r.pop());else if(r){var i=r.indexOf(t);-1!=i&&r.splice(i,1)}}},r.on=r.addEventListener=function(e,t,n){this._eventRegistry=this._eventRegistry||{};var r=this._eventRegistry[e];return r||(r=this._eventRegistry[e]=[]),-1==r.indexOf(t)&&r[n?"unshift":"push"](t),t},r.off=r.removeListener=r.removeEventListener=function(e,t){this._eventRegistry=this._eventRegistry||{};var n=this._eventRegistry[e];if(n){var r=n.indexOf(t);-1!==r&&n.splice(r,1)}},r.removeAllListeners=function(e){e||(this._eventRegistry=this._defaultHandlers=void 0),this._eventRegistry&&(this._eventRegistry[e]=void 0),this._defaultHandlers&&(this._defaultHandlers[e]=void 0)},t.EventEmitter=r})),ace.define("ace/lib/app_config",["require","exports","module","ace/lib/oop","ace/lib/event_emitter"],(function(e,t,n){var r=e("./oop"),i=e("./event_emitter").EventEmitter,o={setOptions:function(e){Object.keys(e).forEach((function(t){this.setOption(t,e[t])}),this)},getOptions:function(e){var t={};if(e)Array.isArray(e)||(t=e,e=Object.keys(t));else{var n=this.$options;e=Object.keys(n).filter((function(e){return!n[e].hidden}))}return e.forEach((function(e){t[e]=this.getOption(e)}),this),t},setOption:function(e,t){if(this["$"+e]!==t){var n=this.$options[e];if(!n)return s('misspelled option "'+e+'"');if(n.forwardTo)return this[n.forwardTo]&&this[n.forwardTo].setOption(e,t);n.handlesSet||(this["$"+e]=t),n&&n.set&&n.set.call(this,t)}},getOption:function(e){var t=this.$options[e];return t?t.forwardTo?this[t.forwardTo]&&this[t.forwardTo].getOption(e):t&&t.get?t.get.call(this):this["$"+e]:s('misspelled option "'+e+'"')}};function s(e){"undefined"!=typeof console&&console.warn&&console.warn.apply(console,arguments)}function a(e,t){var n=new Error(e);n.data=t,"object"==typeof console&&console.error&&console.error(n),setTimeout((function(){throw n}))}var l=function(){function e(){this.$defaultOptions={}}return e.prototype.defineOptions=function(e,t,n){return e.$options||(this.$defaultOptions[t]=e.$options={}),Object.keys(n).forEach((function(t){var r=n[t];"string"==typeof r&&(r={forwardTo:r}),r.name||(r.name=t),e.$options[r.name]=r,"initialValue"in r&&(e["$"+r.name]=r.initialValue)})),r.implement(e,o),this},e.prototype.resetOptions=function(e){Object.keys(e.$options).forEach((function(t){var n=e.$options[t];"value"in n&&e.setOption(t,n.value)}))},e.prototype.setDefaultValue=function(e,t,n){if(!e){for(e in this.$defaultOptions)if(this.$defaultOptions[e][t])break;if(!this.$defaultOptions[e][t])return!1}var r=this.$defaultOptions[e]||(this.$defaultOptions[e]={});r[t]&&(r.forwardTo?this.setDefaultValue(r.forwardTo,t,n):r[t].value=n)},e.prototype.setDefaultValues=function(e,t){Object.keys(t).forEach((function(n){this.setDefaultValue(e,n,t[n])}),this)},e}();l.prototype.warn=s,l.prototype.reportError=a,r.implement(l.prototype,i),t.AppConfig=l})),ace.define("ace/theme/textmate.css",["require","exports","module"],(function(e,t,n){n.exports='.ace-tm .ace_gutter {\n background: #f0f0f0;\n color: #333;\n}\n\n.ace-tm .ace_print-margin {\n width: 1px;\n background: #e8e8e8;\n}\n\n.ace-tm .ace_fold {\n background-color: #6B72E6;\n}\n\n.ace-tm {\n background-color: #FFFFFF;\n color: black;\n}\n\n.ace-tm .ace_cursor {\n color: black;\n}\n \n.ace-tm .ace_invisible {\n color: rgb(191, 191, 191);\n}\n\n.ace-tm .ace_storage,\n.ace-tm .ace_keyword {\n color: blue;\n}\n\n.ace-tm .ace_constant {\n color: rgb(197, 6, 11);\n}\n\n.ace-tm .ace_constant.ace_buildin {\n color: rgb(88, 72, 246);\n}\n\n.ace-tm .ace_constant.ace_language {\n color: rgb(88, 92, 246);\n}\n\n.ace-tm .ace_constant.ace_library {\n color: rgb(6, 150, 14);\n}\n\n.ace-tm .ace_invalid {\n background-color: rgba(255, 0, 0, 0.1);\n color: red;\n}\n\n.ace-tm .ace_support.ace_function {\n color: rgb(60, 76, 114);\n}\n\n.ace-tm .ace_support.ace_constant {\n color: rgb(6, 150, 14);\n}\n\n.ace-tm .ace_support.ace_type,\n.ace-tm .ace_support.ace_class {\n color: rgb(109, 121, 222);\n}\n\n.ace-tm .ace_keyword.ace_operator {\n color: rgb(104, 118, 135);\n}\n\n.ace-tm .ace_string {\n color: rgb(3, 106, 7);\n}\n\n.ace-tm .ace_comment {\n color: rgb(76, 136, 107);\n}\n\n.ace-tm .ace_comment.ace_doc {\n color: rgb(0, 102, 255);\n}\n\n.ace-tm .ace_comment.ace_doc.ace_tag {\n color: rgb(128, 159, 191);\n}\n\n.ace-tm .ace_constant.ace_numeric {\n color: rgb(0, 0, 205);\n}\n\n.ace-tm .ace_variable {\n color: rgb(49, 132, 149);\n}\n\n.ace-tm .ace_xml-pe {\n color: rgb(104, 104, 91);\n}\n\n.ace-tm .ace_entity.ace_name.ace_function {\n color: #0000A2;\n}\n\n\n.ace-tm .ace_heading {\n color: rgb(12, 7, 255);\n}\n\n.ace-tm .ace_list {\n color:rgb(185, 6, 144);\n}\n\n.ace-tm .ace_meta.ace_tag {\n color:rgb(0, 22, 142);\n}\n\n.ace-tm .ace_string.ace_regex {\n color: rgb(255, 0, 0)\n}\n\n.ace-tm .ace_marker-layer .ace_selection {\n background: rgb(181, 213, 255);\n}\n.ace-tm.ace_multiselect .ace_selection.ace_start {\n box-shadow: 0 0 3px 0px white;\n}\n.ace-tm .ace_marker-layer .ace_step {\n background: rgb(252, 255, 0);\n}\n\n.ace-tm .ace_marker-layer .ace_stack {\n background: rgb(164, 229, 101);\n}\n\n.ace-tm .ace_marker-layer .ace_bracket {\n margin: -1px 0 0 -1px;\n border: 1px solid rgb(192, 192, 192);\n}\n\n.ace-tm .ace_marker-layer .ace_active-line {\n background: rgba(0, 0, 0, 0.07);\n}\n\n.ace-tm .ace_gutter-active-line {\n background-color : #dcdcdc;\n}\n\n.ace-tm .ace_marker-layer .ace_selected-word {\n background: rgb(250, 250, 255);\n border: 1px solid rgb(200, 200, 250);\n}\n\n.ace-tm .ace_indent-guide {\n background: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAE0lEQVQImWP4////f4bLly//BwAmVgd1/w11/gAAAABJRU5ErkJggg==") right repeat-y;\n}\n\n.ace-tm .ace_indent-guide-active {\n background: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAACXBIWXMAAAsTAAALEwEAmpwYAAAAIGNIUk0AAHolAACAgwAA+f8AAIDpAAB1MAAA6mAAADqYAAAXb5JfxUYAAAAZSURBVHjaYvj///9/hivKyv8BAAAA//8DACLqBhbvk+/eAAAAAElFTkSuQmCC") right repeat-y;\n}\n'})),ace.define("ace/theme/textmate",["require","exports","module","ace/theme/textmate.css","ace/lib/dom"],(function(e,t,n){"use strict";t.isDark=!1,t.cssClass="ace-tm",t.cssText=e("./textmate.css"),t.$id="ace/theme/textmate";var r=e("../lib/dom");r.importCssString(t.cssText,t.cssClass,!1)})),ace.define("ace/config",["require","exports","module","ace/lib/lang","ace/lib/net","ace/lib/dom","ace/lib/app_config","ace/theme/textmate"],(function(e,t,n){var r=e("./lib/lang"),i=e("./lib/net"),o=e("./lib/dom"),s=e("./lib/app_config").AppConfig;n.exports=t=new s;var a={packaged:!1,workerPath:null,modePath:null,themePath:null,basePath:"",suffix:".js",$moduleUrls:{},loadWorkerFromBlob:!0,sharedPopups:!1,useStrictCSP:null};t.get=function(e){if(!a.hasOwnProperty(e))throw new Error("Unknown config key: "+e);return a[e]},t.set=function(e,t){if(a.hasOwnProperty(e))a[e]=t;else if(0==this.setDefaultValue("",e,t))throw new Error("Unknown config key: "+e);"useStrictCSP"==e&&o.useStrictCSP(t)},t.all=function(){return r.copyObject(a)},t.$modes={},t.moduleUrl=function(e,t){if(a.$moduleUrls[e])return a.$moduleUrls[e];var n=e.split("/");t=t||n[n.length-2]||"";var r="snippets"==t?"/":"-",i=n[n.length-1];if("worker"==t&&"-"==r){var o=new RegExp("^"+t+"[\\-_]|[\\-_]"+t+"$","g");i=i.replace(o,"")}(!i||i==t)&&n.length>1&&(i=n[n.length-2]);var s=a[t+"Path"];return null==s?s=a.basePath:"/"==r&&(t=r=""),s&&"/"!=s.slice(-1)&&(s+="/"),s+t+r+i+this.get("suffix")},t.setModuleUrl=function(e,t){return a.$moduleUrls[e]=t};var l=function(t,n){return"ace/theme/textmate"===t||"./theme/textmate"===t?n(null,e("./theme/textmate")):console.error("loader is not configured")};t.setLoader=function(e){l=e},t.dynamicModules=Object.create(null),t.$loading={},t.loadModule=function(n,r){var o,s;Array.isArray(n)&&(s=n[0],n=n[1]);var a=function(e){if(e&&!t.$loading[n])return r&&r(e);if(t.$loading[n]||(t.$loading[n]=[]),t.$loading[n].push(r),!(t.$loading[n].length>1)){var o=function(){l(n,(function(e,r){t._emit("load.module",{name:n,module:r});var i=t.$loading[n];t.$loading[n]=null,i.forEach((function(e){e&&e(r)}))}))};if(!t.get("packaged"))return o();i.loadScript(t.moduleUrl(n,s),o),c()}};if(t.dynamicModules[n])t.dynamicModules[n]().then((function(e){e.default?a(e.default):a(e)}));else{try{o=e(n)}catch(u){}a(o)}},t.setModuleLoader=function(e,n){t.dynamicModules[e]=n};var c=function(){a.basePath||a.workerPath||a.modePath||a.themePath||Object.keys(a.$moduleUrls).length||(console.error("Unable to infer path to ace from script src,","use ace.config.set('basePath', 'path') to enable dynamic loading of modes and themes","or with webpack use ace/webpack-resolver"),c=function(){})};t.version="1.17.0"})),ace.define("ace/loader_build",["require","exports","module","ace/lib/fixoldbrowsers","ace/config"],(function(e,t,r){"use strict";e("./lib/fixoldbrowsers");var i=e("./config");i.setLoader((function(t,n){e([t],(function(e){n(null,e)}))}));var o=function(){return this||"undefined"!=typeof window&&window}();function s(t){if(o&&o.document){i.set("packaged",t||e.packaged||r.packaged||o.define&&n.amdD.packaged);var s={},l="",c=document.currentScript||document._currentScript,u=c&&c.ownerDocument||document;c&&c.src&&(l=c.src.split(/[?#]/)[0].split("/").slice(0,-1).join("/")||"");for(var h=u.getElementsByTagName("script"),f=0;f<h.length;f++){var d=h[f],p=d.src||d.getAttribute("src");if(p){for(var g=d.attributes,m=0,v=g.length;m<v;m++){var y=g[m];0===y.name.indexOf("data-ace-")&&(s[a(y.name.replace(/^data-ace-/,""))]=y.value)}var w=p.match(/^(.*)\/ace([\-.]\w+)?\.js(\?|$)/);w&&(l=w[1])}}for(var b in l&&(s.base=s.base||l,s.packaged=!0),s.basePath=s.base,s.workerPath=s.workerPath||s.base,s.modePath=s.modePath||s.base,s.themePath=s.themePath||s.base,delete s.base,s)"undefined"!==typeof s[b]&&i.set(b,s[b])}}function a(e){return e.replace(/-(.)/g,(function(e,t){return t.toUpperCase()}))}r.exports=function(t){i.init=s,t.require=e,t.define=n.amdD},s(!0)})),ace.define("ace/range",["require","exports","module"],(function(e,t,n){"use strict";var r=function(e,t){return e.row-t.row||e.column-t.column},i=function(){function e(e,t,n,r){this.start={row:e,column:t},this.end={row:n,column:r}}return e.prototype.isEqual=function(e){return this.start.row===e.start.row&&this.end.row===e.end.row&&this.start.column===e.start.column&&this.end.column===e.end.column},e.prototype.toString=function(){return"Range: ["+this.start.row+"/"+this.start.column+"] -> ["+this.end.row+"/"+this.end.column+"]"},e.prototype.contains=function(e,t){return 0==this.compare(e,t)},e.prototype.compareRange=function(e){var t,n=e.end,r=e.start;return t=this.compare(n.row,n.column),1==t?(t=this.compare(r.row,r.column),1==t?2:0==t?1:0):-1==t?-2:(t=this.compare(r.row,r.column),-1==t?-1:1==t?42:0)},e.prototype.comparePoint=function(e){return this.compare(e.row,e.column)},e.prototype.containsRange=function(e){return 0==this.comparePoint(e.start)&&0==this.comparePoint(e.end)},e.prototype.intersects=function(e){var t=this.compareRange(e);return-1==t||0==t||1==t},e.prototype.isEnd=function(e,t){return this.end.row==e&&this.end.column==t},e.prototype.isStart=function(e,t){return this.start.row==e&&this.start.column==t},e.prototype.setStart=function(e,t){"object"==typeof e?(this.start.column=e.column,this.start.row=e.row):(this.start.row=e,this.start.column=t)},e.prototype.setEnd=function(e,t){"object"==typeof e?(this.end.column=e.column,this.end.row=e.row):(this.end.row=e,this.end.column=t)},e.prototype.inside=function(e,t){return 0==this.compare(e,t)&&(!this.isEnd(e,t)&&!this.isStart(e,t))},e.prototype.insideStart=function(e,t){return 0==this.compare(e,t)&&!this.isEnd(e,t)},e.prototype.insideEnd=function(e,t){return 0==this.compare(e,t)&&!this.isStart(e,t)},e.prototype.compare=function(e,t){return this.isMultiLine()||e!==this.start.row?e<this.start.row?-1:e>this.end.row?1:this.start.row===e?t>=this.start.column?0:-1:this.end.row===e?t<=this.end.column?0:1:0:t<this.start.column?-1:t>this.end.column?1:0},e.prototype.compareStart=function(e,t){return this.start.row==e&&this.start.column==t?-1:this.compare(e,t)},e.prototype.compareEnd=function(e,t){return this.end.row==e&&this.end.column==t?1:this.compare(e,t)},e.prototype.compareInside=function(e,t){return this.end.row==e&&this.end.column==t?1:this.start.row==e&&this.start.column==t?-1:this.compare(e,t)},e.prototype.clipRows=function(t,n){if(this.end.row>n)var r={row:n+1,column:0};else if(this.end.row<t)r={row:t,column:0};if(this.start.row>n)var i={row:n+1,column:0};else if(this.start.row<t)i={row:t,column:0};return e.fromPoints(i||this.start,r||this.end)},e.prototype.extend=function(t,n){var r=this.compare(t,n);if(0==r)return this;if(-1==r)var i={row:t,column:n};else var o={row:t,column:n};return e.fromPoints(i||this.start,o||this.end)},e.prototype.isEmpty=function(){return this.start.row===this.end.row&&this.start.column===this.end.column},e.prototype.isMultiLine=function(){return this.start.row!==this.end.row},e.prototype.clone=function(){return e.fromPoints(this.start,this.end)},e.prototype.collapseRows=function(){return 0==this.end.column?new e(this.start.row,0,Math.max(this.start.row,this.end.row-1),0):new e(this.start.row,0,this.end.row,0)},e.prototype.toScreenRange=function(t){var n=t.documentToScreenPosition(this.start),r=t.documentToScreenPosition(this.end);return new e(n.row,n.column,r.row,r.column)},e.prototype.moveBy=function(e,t){this.start.row+=e,this.start.column+=t,this.end.row+=e,this.end.column+=t},e}();i.fromPoints=function(e,t){return new i(e.row,e.column,t.row,t.column)},i.comparePoints=r,i.comparePoints=function(e,t){return e.row-t.row||e.column-t.column},t.Range=i})),ace.define("ace/lib/keys",["require","exports","module","ace/lib/oop"],(function(e,t,n){
10
+ /*! @license
11
+ ==========================================================================
12
+ SproutCore -- JavaScript Application Framework
13
+ copyright 2006-2009, Sprout Systems Inc., Apple Inc. and contributors.
14
+
15
+ Permission is hereby granted, free of charge, to any person obtaining a
16
+ copy of this software and associated documentation files (the "Software"),
17
+ to deal in the Software without restriction, including without limitation
18
+ the rights to use, copy, modify, merge, publish, distribute, sublicense,
19
+ and/or sell copies of the Software, and to permit persons to whom the
20
+ Software is furnished to do so, subject to the following conditions:
21
+
22
+ The above copyright notice and this permission notice shall be included in
23
+ all copies or substantial portions of the Software.
24
+
25
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
26
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
27
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
28
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
29
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
30
+ FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
31
+ DEALINGS IN THE SOFTWARE.
32
+
33
+ SproutCore and the SproutCore logo are trademarks of Sprout Systems, Inc.
34
+
35
+ For more information about SproutCore, visit http://www.sproutcore.com
36
+
37
+
38
+ ==========================================================================
39
+ @license */
40
+ "use strict";var r=e("./oop"),i=function(){var e,t,n={MODIFIER_KEYS:{16:"Shift",17:"Ctrl",18:"Alt",224:"Meta",91:"MetaLeft",92:"MetaRight",93:"ContextMenu"},KEY_MODS:{ctrl:1,alt:2,option:2,shift:4,super:8,meta:8,command:8,cmd:8,control:1},FUNCTION_KEYS:{8:"Backspace",9:"Tab",13:"Return",19:"Pause",27:"Esc",32:"Space",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"Left",38:"Up",39:"Right",40:"Down",44:"Print",45:"Insert",46:"Delete",96:"Numpad0",97:"Numpad1",98:"Numpad2",99:"Numpad3",100:"Numpad4",101:"Numpad5",102:"Numpad6",103:"Numpad7",104:"Numpad8",105:"Numpad9","-13":"NumpadEnter",112:"F1",113:"F2",114:"F3",115:"F4",116:"F5",117:"F6",118:"F7",119:"F8",120:"F9",121:"F10",122:"F11",123:"F12",144:"Numlock",145:"Scrolllock"},PRINTABLE_KEYS:{32:" ",48:"0",49:"1",50:"2",51:"3",52:"4",53:"5",54:"6",55:"7",56:"8",57:"9",59:";",61:"=",65:"a",66:"b",67:"c",68:"d",69:"e",70:"f",71:"g",72:"h",73:"i",74:"j",75:"k",76:"l",77:"m",78:"n",79:"o",80:"p",81:"q",82:"r",83:"s",84:"t",85:"u",86:"v",87:"w",88:"x",89:"y",90:"z",107:"+",109:"-",110:".",186:";",187:"=",188:",",189:"-",190:".",191:"/",192:"`",219:"[",220:"\\",221:"]",222:"'",111:"/",106:"*"}};for(t in n.PRINTABLE_KEYS[173]="-",n.FUNCTION_KEYS)e=n.FUNCTION_KEYS[t].toLowerCase(),n[e]=parseInt(t,10);for(t in n.PRINTABLE_KEYS)e=n.PRINTABLE_KEYS[t].toLowerCase(),n[e]=parseInt(t,10);return r.mixin(n,n.MODIFIER_KEYS),r.mixin(n,n.PRINTABLE_KEYS),r.mixin(n,n.FUNCTION_KEYS),n.enter=n["return"],n.escape=n.esc,n.del=n["delete"],function(){for(var e=["cmd","ctrl","alt","shift"],t=Math.pow(2,e.length);t--;)n.KEY_MODS[t]=e.filter((function(e){return t&n.KEY_MODS[e]})).join("-")+"-"}(),n.KEY_MODS[0]="",n.KEY_MODS[-1]="input-",n}();r.mixin(t,i),t.keyCodeToString=function(e){var t=i[e];return"string"!=typeof t&&(t=String.fromCharCode(e)),t.toLowerCase()}})),ace.define("ace/lib/event",["require","exports","module","ace/lib/keys","ace/lib/useragent"],(function(e,t,n){"use strict";var r,i=e("./keys"),o=e("./useragent"),s=null,a=0;function l(){r=!1;try{document.createComment("").addEventListener("test",(function(){}),{get passive(){r={passive:!1}}})}catch(e){}}function c(){return void 0==r&&l(),r}function u(e,t,n){this.elem=e,this.type=t,this.callback=n}u.prototype.destroy=function(){f(this.elem,this.type,this.callback),this.elem=this.type=this.callback=void 0};var h=t.addListener=function(e,t,n,r){e.addEventListener(t,n,c()),r&&r.$toDestroy.push(new u(e,t,n))},f=t.removeListener=function(e,t,n){e.removeEventListener(t,n,c())};t.stopEvent=function(e){return t.stopPropagation(e),t.preventDefault(e),!1},t.stopPropagation=function(e){e.stopPropagation&&e.stopPropagation()},t.preventDefault=function(e){e.preventDefault&&e.preventDefault()},t.getButton=function(e){return"dblclick"==e.type?0:"contextmenu"==e.type||o.isMac&&e.ctrlKey&&!e.altKey&&!e.shiftKey?2:e.button},t.capture=function(e,t,n){var r=e&&e.ownerDocument||document;function i(e){t&&t(e),n&&n(e),f(r,"mousemove",t),f(r,"mouseup",i),f(r,"dragstart",i)}return h(r,"mousemove",t),h(r,"mouseup",i),h(r,"dragstart",i),i},t.addMouseWheelListener=function(e,t,n){h(e,"wheel",(function(e){var n=.15,r=e.deltaX||0,i=e.deltaY||0;switch(e.deltaMode){case e.DOM_DELTA_PIXEL:e.wheelX=r*n,e.wheelY=i*n;break;case e.DOM_DELTA_LINE:var o=15;e.wheelX=r*o,e.wheelY=i*o;break;case e.DOM_DELTA_PAGE:var s=150;e.wheelX=r*s,e.wheelY=i*s;break}t(e)}),n)},t.addMultiMouseDownListener=function(e,n,r,i,s){var a,l,c,u=0,f={2:"dblclick",3:"tripleclick",4:"quadclick"};function d(e){if(0!==t.getButton(e)?u=0:e.detail>1?(u++,u>4&&(u=1)):u=1,o.isIE){var s=Math.abs(e.clientX-a)>5||Math.abs(e.clientY-l)>5;c&&!s||(u=1),c&&clearTimeout(c),c=setTimeout((function(){c=null}),n[u-1]||600),1==u&&(a=e.clientX,l=e.clientY)}if(e._clicks=u,r[i]("mousedown",e),u>4)u=0;else if(u>1)return r[i](f[u],e)}Array.isArray(e)||(e=[e]),e.forEach((function(e){h(e,"mousedown",d,s)}))};var d=function(e){return 0|(e.ctrlKey?1:0)|(e.altKey?2:0)|(e.shiftKey?4:0)|(e.metaKey?8:0)};function p(e,t,n){var r=d(t);if(!o.isMac&&s){if(t.getModifierState&&(t.getModifierState("OS")||t.getModifierState("Win"))&&(r|=8),s.altGr){if(3==(3&r))return;s.altGr=0}if(18===n||17===n){var l="location"in t?t.location:t.keyLocation;if(17===n&&1===l)1==s[n]&&(a=t.timeStamp);else if(18===n&&3===r&&2===l){var c=t.timeStamp-a;c<50&&(s.altGr=!0)}}}if(n in i.MODIFIER_KEYS&&(n=-1),!r&&13===n){l="location"in t?t.location:t.keyLocation;if(3===l&&(e(t,r,-n),t.defaultPrevented))return}if(o.isChromeOS&&8&r){if(e(t,r,n),t.defaultPrevented)return;r&=-9}return!!(r||n in i.FUNCTION_KEYS||n in i.PRINTABLE_KEYS)&&e(t,r,n)}function g(){s=Object.create(null)}if(t.getModifierString=function(e){return i.KEY_MODS[d(e)]},t.addCommandKeyListener=function(e,n,r){if(o.isOldGecko||o.isOpera&&!("KeyboardEvent"in window)){var i=null;h(e,"keydown",(function(e){i=e.keyCode}),r),h(e,"keypress",(function(e){return p(n,e,i)}),r)}else{var a=null;h(e,"keydown",(function(e){s[e.keyCode]=(s[e.keyCode]||0)+1;var t=p(n,e,e.keyCode);return a=e.defaultPrevented,t}),r),h(e,"keypress",(function(e){a&&(e.ctrlKey||e.altKey||e.shiftKey||e.metaKey)&&(t.stopEvent(e),a=null)}),r),h(e,"keyup",(function(e){s[e.keyCode]=null}),r),s||(g(),h(window,"focus",g))}},"object"==typeof window&&window.postMessage&&!o.isOldIE){var m=1;t.nextTick=function(e,n){n=n||window;var r="zero-timeout-message-"+m++,i=function(o){o.data==r&&(t.stopPropagation(o),f(n,"message",i),e())};h(n,"message",i),n.postMessage(r,"*")}}t.$idleBlocked=!1,t.onIdle=function(e,n){return setTimeout((function n(){t.$idleBlocked?setTimeout(n,100):e()}),n)},t.$idleBlockId=null,t.blockIdle=function(e){t.$idleBlockId&&clearTimeout(t.$idleBlockId),t.$idleBlocked=!0,t.$idleBlockId=setTimeout((function(){t.$idleBlocked=!1}),e||100)},t.nextFrame="object"==typeof window&&(window.requestAnimationFrame||window.mozRequestAnimationFrame||window.webkitRequestAnimationFrame||window.msRequestAnimationFrame||window.oRequestAnimationFrame),t.nextFrame?t.nextFrame=t.nextFrame.bind(window):t.nextFrame=function(e){setTimeout(e,17)}})),ace.define("ace/clipboard",["require","exports","module"],(function(e,t,n){"use strict";var r;n.exports={lineMode:!1,pasteCancelled:function(){return!!(r&&r>Date.now()-50)||(r=!1)},cancel:function(){r=Date.now()}}})),ace.define("ace/keyboard/textinput",["require","exports","module","ace/lib/event","ace/lib/useragent","ace/lib/dom","ace/lib/lang","ace/clipboard","ace/lib/keys"],(function(e,t,n){"use strict";var r=e("../lib/event"),i=e("../lib/useragent"),o=e("../lib/dom"),s=e("../lib/lang"),a=e("../clipboard"),l=i.isChrome<18,c=i.isIE,u=i.isChrome>63,h=400,f=e("../lib/keys"),d=f.KEY_MODS,p=i.isIOS,g=p?/\s/:/\n/,m=i.isMobile,v=function(e,t){var n=o.createElement("textarea");n.className="ace_text-input",n.setAttribute("wrap","off"),n.setAttribute("autocorrect","off"),n.setAttribute("autocapitalize","off"),n.setAttribute("spellcheck",!1),n.style.opacity="0",e.insertBefore(n,e.firstChild);var v=!1,y=!1,w=!1,b=!1,x="";m||(n.style.fontSize="1px");var S=!1,_=!1,k="",C=0,$=0,A=0;try{var R=document.activeElement===n}catch(Q){}this.setAriaOptions=function(e){e.activeDescendant?(n.setAttribute("aria-haspopup","true"),n.setAttribute("aria-autocomplete",e.inline?"both":"list"),n.setAttribute("aria-activedescendant",e.activeDescendant)):(n.setAttribute("aria-haspopup","false"),n.setAttribute("aria-autocomplete","both"),n.removeAttribute("aria-activedescendant")),e.role&&n.setAttribute("role",e.role)},this.setAriaOptions({role:"textbox"}),r.addListener(n,"blur",(function(e){_||(t.onBlur(e),R=!1,m&&!p&&document.removeEventListener("selectionchange",M))}),t),r.addListener(n,"focus",(function(e){if(!_){if(R=!0,i.isEdge)try{if(!document.hasFocus())return}catch(e){}t.onFocus(e),i.isEdge?setTimeout(T):T(),m&&!p&&document.addEventListener("selectionchange",M)}}),t),this.$focusScroll=!1,this.focus=function(){if(x||u||"browser"==this.$focusScroll)return n.focus({preventScroll:!0});var e=n.style.top;n.style.position="fixed",n.style.top="0px";try{var t=0!=n.getBoundingClientRect().top}catch(Q){return}var r=[];if(t){var i=n.parentElement;while(i&&1==i.nodeType)r.push(i),i.setAttribute("ace_nocontext",!0),i=!i.parentElement&&i.getRootNode?i.getRootNode().host:i.parentElement}n.focus({preventScroll:!0}),t&&r.forEach((function(e){e.removeAttribute("ace_nocontext")})),setTimeout((function(){n.style.position="","0px"==n.style.top&&(n.style.top=e)}),0)},this.blur=function(){n.blur()},this.isFocused=function(){return R},t.on("beforeEndOperation",(function(){var e=t.curOp,r=e&&e.command&&e.command.name;if("insertstring"!=r){var i=r&&(e.docChanged||e.selectionChanged);w&&i&&(k=n.value="",U()),T()}}));var T=p?function(e){if(R&&(!v||e)&&!b){e||(e="");var r="\n ab"+e+"cde fg\n";r!=n.value&&(n.value=k=r);var i=4,o=4+(e.length||(t.selection.isEmpty()?0:1));C==i&&$==o||n.setSelectionRange(i,o),C=i,$=o}}:function(){if(!w&&!b&&(R||I)){w=!0;var e=0,r=0,i="";if(t.session){var o=t.selection,s=o.getRange(),a=o.cursor.row;if(e=s.start.column,r=s.end.column,i=t.session.getLine(a),s.start.row!=a){var l=t.session.getLine(a-1);e=s.start.row<a-1?0:e,r+=l.length+1,i=l+"\n"+i}else if(s.end.row!=a){var c=t.session.getLine(a+1);r=s.end.row>a+1?c.length:r,r+=i.length+1,i=i+"\n"+c}else m&&a>0&&(i="\n"+i,r+=1,e+=1);i.length>h&&(e<h&&r<h?i=i.slice(0,h):(i="\n",e==r?e=r=0:(e=0,r=1)))}var u=i+"\n\n";if(u!=k&&(n.value=k=u,C=$=u.length),I&&(C=n.selectionStart,$=n.selectionEnd),$!=r||C!=e||n.selectionEnd!=$)try{n.setSelectionRange(e,r),C=e,$=r}catch(Q){}w=!1}};this.resetSelection=T,R&&t.onFocus();var E=function(e){return 0===e.selectionStart&&e.selectionEnd>=k.length&&e.value===k&&k&&e.selectionEnd!==$},L=function(e){w||(v?v=!1:E(n)?(t.selectAll(),T()):m&&n.selectionStart!=C&&T())};function M(e){if(n&&n.parentNode||document.removeEventListener("selectionchange",M),!w&&n.selectionStart===n.selectionEnd){var r=n.selectionStart-C,i=$-C;r>0?r=Math.max(r-i,1):0===r&&i&&(r=-1);for(var o=Math.abs(r),s=r>0?f.right:f.left,a=0;a<o;a++)t.onCommandKey({},0,s)}}var O=null;this.setInputHandler=function(e){O=e},this.getInputHandler=function(){return O};var I=!1,P=function(e,r){if(I&&(I=!1),y)return T(),e&&t.onPaste(e),y=!1,"";var o=n.selectionStart,s=n.selectionEnd,a=C,l=k.length-$,c=e,u=e.length-o,h=e.length-s,f=0;while(a>0&&k[f]==e[f])f++,a--;c=c.slice(f),f=1;while(l>0&&k.length-f>C-1&&k[k.length-f]==e[e.length-f])f++,l--;u-=f-1,h-=f-1;var d=c.length-f+1;if(d<0&&(a=-d,d=0),c=c.slice(0,d),!r&&!c&&!u&&!a&&!l&&!h)return"";b=!0;var p=!1;return i.isAndroid&&". "==c&&(c=" ",p=!0),c&&!a&&!l&&!u&&!h||S?t.onTextInput(c):t.onTextInput(c,{extendLeft:a,extendRight:l,restoreStart:u,restoreEnd:h}),b=!1,k=e,C=o,$=s,A=h,p?"\n":c},D=function(e){if(w)return z();if(e&&e.inputType){if("historyUndo"==e.inputType)return t.execCommand("undo");if("historyRedo"==e.inputType)return t.execCommand("redo")}var r=n.value,i=P(r,!0);(r.length>h+100||g.test(i)||m&&C<1&&C==$)&&T()},F=function(e,t,n){var r=e.clipboardData||window.clipboardData;if(r&&!l){var i=c||n?"Text":"text/plain";try{return t?!1!==r.setData(i,t):r.getData(i)}catch(e){if(!n)return F(e,t,!0)}}},B=function(e,i){var o=t.getCopyText();if(!o)return r.preventDefault(e);F(e,o)?(p&&(T(o),v=o,setTimeout((function(){v=!1}),10)),i?t.onCut():t.onCopy(),r.preventDefault(e)):(v=!0,n.value=o,n.select(),setTimeout((function(){v=!1,T(),i?t.onCut():t.onCopy()})))},W=function(e){B(e,!0)},N=function(e){B(e,!1)},H=function(e){var o=F(e);a.pasteCancelled()||("string"==typeof o?(o&&t.onPaste(o,e),i.isIE&&setTimeout(T),r.preventDefault(e)):(n.value="",y=!0))};r.addCommandKeyListener(n,t.onCommandKey.bind(t),t),r.addListener(n,"select",L,t),r.addListener(n,"input",D,t),r.addListener(n,"cut",W,t),r.addListener(n,"copy",N,t),r.addListener(n,"paste",H,t),"oncut"in n&&"oncopy"in n&&"onpaste"in n||r.addListener(e,"keydown",(function(e){if((!i.isMac||e.metaKey)&&e.ctrlKey)switch(e.keyCode){case 67:N(e);break;case 86:H(e);break;case 88:W(e);break}}),t);var j=function(e){if(!w&&t.onCompositionStart&&!t.$readOnly&&(w={},!S)){e.data&&(w.useTextareaForIME=!1),setTimeout(z,0),t._signal("compositionStart"),t.on("mousedown",V);var r=t.getSelectionRange();r.end.row=r.start.row,r.end.column=r.start.column,w.markerRange=r,w.selectionStart=C,t.onCompositionStart(w),w.useTextareaForIME?(k=n.value="",C=0,$=0):(n.msGetInputContext&&(w.context=n.msGetInputContext()),n.getInputContext&&(w.context=n.getInputContext()))}},z=function(){if(w&&t.onCompositionUpdate&&!t.$readOnly){if(S)return V();if(w.useTextareaForIME)t.onCompositionUpdate(n.value);else{var e=n.value;P(e),w.markerRange&&(w.context&&(w.markerRange.start.column=w.selectionStart=w.context.compositionStartOffset),w.markerRange.end.column=w.markerRange.start.column+$-w.selectionStart+A)}}},U=function(e){t.onCompositionEnd&&!t.$readOnly&&(w=!1,t.onCompositionEnd(),t.off("mousedown",V),e&&D())};function V(){_=!0,n.blur(),n.focus(),_=!1}var G,K=s.delayedCall(z,50).schedule.bind(null,null);function q(e){27==e.keyCode&&n.value.length<n.selectionStart&&(w||(k=n.value),C=$=-1,T()),K()}function Z(){clearTimeout(G),G=setTimeout((function(){x&&(n.style.cssText=x,x=""),t.renderer.$isMousePressed=!1,t.renderer.$keepTextAreaAtCursor&&t.renderer.$moveTextAreaToCursor()}),0)}r.addListener(n,"compositionstart",j,t),r.addListener(n,"compositionupdate",z,t),r.addListener(n,"keyup",q,t),r.addListener(n,"keydown",K,t),r.addListener(n,"compositionend",U,t),this.getElement=function(){return n},this.setCommandMode=function(e){S=e,n.readOnly=!1},this.setReadOnly=function(e){S||(n.readOnly=e)},this.setCopyWithEmptySelection=function(e){},this.onContextMenu=function(e){I=!0,T(),t._emit("nativecontextmenu",{target:t,domEvent:e}),this.moveToMouse(e,!0)},this.moveToMouse=function(e,s){x||(x=n.style.cssText),n.style.cssText=(s?"z-index:100000;":"")+(i.isIE?"opacity:0.1;":"")+"text-indent: -"+(C+$)*t.renderer.characterWidth*.5+"px;";var a=t.container.getBoundingClientRect(),l=o.computedStyle(t.container),c=a.top+(parseInt(l.borderTopWidth)||0),u=a.left+(parseInt(a.borderLeftWidth)||0),h=a.bottom-c-n.clientHeight-2,f=function(e){o.translate(n,e.clientX-u-2,Math.min(e.clientY-c-2,h))};f(e),"mousedown"==e.type&&(t.renderer.$isMousePressed=!0,clearTimeout(G),i.isWin&&r.capture(t.container,f,Z))},this.onContextMenuClose=Z;var Y=function(e){t.textInput.onContextMenu(e),Z()};function X(e,t,n){var r=null,i=!1;n.addEventListener("keydown",(function(e){r&&clearTimeout(r),i=!0}),!0),n.addEventListener("keyup",(function(e){r=setTimeout((function(){i=!1}),100)}),!0);var o=function(e){if(document.activeElement===n&&!(i||w||t.$mouseHandler.isMousePressed)&&!v){var r=n.selectionStart,o=n.selectionEnd,s=null,a=0;if(0==r?s=f.up:1==r?s=f.home:o>$&&"\n"==k[o]?s=f.end:r<C&&" "==k[r-1]?(s=f.left,a=d.option):r<C||r==C&&$!=C&&r==o?s=f.left:o>$&&k.slice(0,o).split("\n").length>2?s=f.down:o>$&&" "==k[o-1]?(s=f.right,a=d.option):(o>$||o==$&&$!=C&&r==o)&&(s=f.right),r!==o&&(a|=d.shift),s){var l=t.onCommandKey({},a,s);if(!l&&t.commands){s=f.keyCodeToString(s);var c=t.commands.findKeyCommand(a,s);c&&t.execCommand(c)}C=r,$=o,T("")}}};document.addEventListener("selectionchange",o),t.on("destroy",(function(){document.removeEventListener("selectionchange",o)}))}r.addListener(n,"mouseup",Y,t),r.addListener(n,"mousedown",(function(e){e.preventDefault(),Z()}),t),r.addListener(t.renderer.scroller,"contextmenu",Y,t),r.addListener(n,"contextmenu",Y,t),p&&X(e,t,n),this.destroy=function(){n.parentElement&&n.parentElement.removeChild(n)}};t.TextInput=v,t.$setUserAgentForTests=function(e,t){m=e,p=t}})),ace.define("ace/mouse/default_handlers",["require","exports","module","ace/lib/useragent"],(function(e,t,n){"use strict";var r=e("../lib/useragent"),i=0,o=550,s=function(){function e(e){e.$clickSelection=null;var t=e.editor;t.setDefaultHandler("mousedown",this.onMouseDown.bind(e)),t.setDefaultHandler("dblclick",this.onDoubleClick.bind(e)),t.setDefaultHandler("tripleclick",this.onTripleClick.bind(e)),t.setDefaultHandler("quadclick",this.onQuadClick.bind(e)),t.setDefaultHandler("mousewheel",this.onMouseWheel.bind(e));var n=["select","startSelect","selectEnd","selectAllEnd","selectByWordsEnd","selectByLinesEnd","dragWait","dragWaitEnd","focusWait"];n.forEach((function(t){e[t]=this[t]}),this),e.selectByLines=this.extendSelectionBy.bind(e,"getLineRange"),e.selectByWords=this.extendSelectionBy.bind(e,"getWordRange")}return e.prototype.onMouseDown=function(e){var t=e.inSelection(),n=e.getDocumentPosition();this.mousedownEvent=e;var i=this.editor,o=e.getButton();if(0!==o){var s=i.getSelectionRange(),a=s.isEmpty();return(a||1==o)&&i.selection.moveToPosition(n),void(2==o&&(i.textInput.onContextMenu(e.domEvent),r.isMozilla||e.preventDefault()))}return this.mousedownEvent.time=Date.now(),!t||i.isFocused()||(i.focus(),!this.$focusTimeout||this.$clickSelection||i.inMultiSelectMode)?(this.captureMouse(e),this.startSelect(n,e.domEvent._clicks>1),e.preventDefault()):(this.setState("focusWait"),void this.captureMouse(e))},e.prototype.startSelect=function(e,t){e=e||this.editor.renderer.screenToTextCoordinates(this.x,this.y);var n=this.editor;this.mousedownEvent&&(this.mousedownEvent.getShiftKey()?n.selection.selectToPosition(e):t||n.selection.moveToPosition(e),t||this.select(),n.setStyle("ace_selecting"),this.setState("select"))},e.prototype.select=function(){var e,t=this.editor,n=t.renderer.screenToTextCoordinates(this.x,this.y);if(this.$clickSelection){var r=this.$clickSelection.comparePoint(n);if(-1==r)e=this.$clickSelection.end;else if(1==r)e=this.$clickSelection.start;else{var i=l(this.$clickSelection,n);n=i.cursor,e=i.anchor}t.selection.setSelectionAnchor(e.row,e.column)}t.selection.selectToPosition(n),t.renderer.scrollCursorIntoView()},e.prototype.extendSelectionBy=function(e){var t,n=this.editor,r=n.renderer.screenToTextCoordinates(this.x,this.y),i=n.selection[e](r.row,r.column);if(this.$clickSelection){var o=this.$clickSelection.comparePoint(i.start),s=this.$clickSelection.comparePoint(i.end);if(-1==o&&s<=0)t=this.$clickSelection.end,i.end.row==r.row&&i.end.column==r.column||(r=i.start);else if(1==s&&o>=0)t=this.$clickSelection.start,i.start.row==r.row&&i.start.column==r.column||(r=i.end);else if(-1==o&&1==s)r=i.end,t=i.start;else{var a=l(this.$clickSelection,r);r=a.cursor,t=a.anchor}n.selection.setSelectionAnchor(t.row,t.column)}n.selection.selectToPosition(r),n.renderer.scrollCursorIntoView()},e.prototype.selectByLinesEnd=function(){this.$clickSelection=null,this.editor.unsetStyle("ace_selecting")},e.prototype.focusWait=function(){var e=a(this.mousedownEvent.x,this.mousedownEvent.y,this.x,this.y),t=Date.now();(e>i||t-this.mousedownEvent.time>this.$focusTimeout)&&this.startSelect(this.mousedownEvent.getDocumentPosition())},e.prototype.onDoubleClick=function(e){var t=e.getDocumentPosition(),n=this.editor,r=n.session,i=r.getBracketRange(t);i?(i.isEmpty()&&(i.start.column--,i.end.column++),this.setState("select")):(i=n.selection.getWordRange(t.row,t.column),this.setState("selectByWords")),this.$clickSelection=i,this.select()},e.prototype.onTripleClick=function(e){var t=e.getDocumentPosition(),n=this.editor;this.setState("selectByLines");var r=n.getSelectionRange();r.isMultiLine()&&r.contains(t.row,t.column)?(this.$clickSelection=n.selection.getLineRange(r.start.row),this.$clickSelection.end=n.selection.getLineRange(r.end.row).end):this.$clickSelection=n.selection.getLineRange(t.row),this.select()},e.prototype.onQuadClick=function(e){var t=this.editor;t.selectAll(),this.$clickSelection=t.getSelectionRange(),this.setState("selectAll")},e.prototype.onMouseWheel=function(e){if(!e.getAccelKey()){e.getShiftKey()&&e.wheelY&&!e.wheelX&&(e.wheelX=e.wheelY,e.wheelY=0);var t=this.editor;this.$lastScroll||(this.$lastScroll={t:0,vx:0,vy:0,allowed:0});var n=this.$lastScroll,r=e.domEvent.timeStamp,i=r-n.t,s=i?e.wheelX/i:n.vx,a=i?e.wheelY/i:n.vy;i<o&&(s=(s+n.vx)/2,a=(a+n.vy)/2);var l=Math.abs(s/a),c=!1;if(l>=1&&t.renderer.isScrollableBy(e.wheelX*e.speed,0)&&(c=!0),l<=1&&t.renderer.isScrollableBy(0,e.wheelY*e.speed)&&(c=!0),c)n.allowed=r;else if(r-n.allowed<o){var u=Math.abs(s)<=1.5*Math.abs(n.vx)&&Math.abs(a)<=1.5*Math.abs(n.vy);u?(c=!0,n.allowed=r):n.allowed=0}return n.t=r,n.vx=s,n.vy=a,c?(t.renderer.scrollBy(e.wheelX*e.speed,e.wheelY*e.speed),e.stop()):void 0}},e}();function a(e,t,n,r){return Math.sqrt(Math.pow(n-e,2)+Math.pow(r-t,2))}function l(e,t){if(e.start.row==e.end.row)var n=2*t.column-e.start.column-e.end.column;else if(e.start.row!=e.end.row-1||e.start.column||e.end.column)n=2*t.row-e.start.row-e.end.row;else var n=t.column-4;return n<0?{cursor:e.start,anchor:e.end}:{cursor:e.end,anchor:e.start}}s.prototype.selectEnd=s.prototype.selectByLinesEnd,s.prototype.selectAllEnd=s.prototype.selectByLinesEnd,s.prototype.selectByWordsEnd=s.prototype.selectByLinesEnd,t.DefaultHandlers=s})),ace.define("ace/tooltip",["require","exports","module","ace/lib/dom"],(function(e,t,n){"use strict";var r=e("./lib/dom"),i="ace_tooltip",o=function(){function e(e){this.isOpen=!1,this.$element=null,this.$parentNode=e}return e.prototype.$init=function(){return this.$element=r.createElement("div"),this.$element.className=i,this.$element.style.display="none",this.$parentNode.appendChild(this.$element),this.$element},e.prototype.getElement=function(){return this.$element||this.$init()},e.prototype.setText=function(e){this.getElement().textContent=e},e.prototype.setHtml=function(e){this.getElement().innerHTML=e},e.prototype.setPosition=function(e,t){this.getElement().style.left=e+"px",this.getElement().style.top=t+"px"},e.prototype.setClassName=function(e){r.addCssClass(this.getElement(),e)},e.prototype.show=function(e,t,n){null!=e&&this.setText(e),null!=t&&null!=n&&this.setPosition(t,n),this.isOpen||(this.getElement().style.display="block",this.isOpen=!0)},e.prototype.hide=function(){this.isOpen&&(this.getElement().style.display="none",this.getElement().className=i,this.isOpen=!1)},e.prototype.getHeight=function(){return this.getElement().offsetHeight},e.prototype.getWidth=function(){return this.getElement().offsetWidth},e.prototype.destroy=function(){this.isOpen=!1,this.$element&&this.$element.parentNode&&this.$element.parentNode.removeChild(this.$element)},e}();t.Tooltip=o})),ace.define("ace/mouse/default_gutter_handler",["require","exports","module","ace/lib/dom","ace/lib/event","ace/tooltip"],(function(e,t,n){"use strict";var r=this&&this.__extends||function(){var e=function(t,n){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])},e(t,n)};return function(t,n){if("function"!==typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function r(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),i=e("../lib/dom"),o=e("../lib/event"),s=e("../tooltip").Tooltip;function a(e){var t,n,r,s=e.editor,a=s.renderer.$gutterLayer,c=new l(s.container);function u(){var t=n.getDocumentPosition().row,i=a.$annotations[t];if(!i)return h();var o=s.session.getLength();if(t==o){var l=s.renderer.pixelToScreenCoordinates(0,n.y).row,u=n.$pos;if(l>s.session.documentToScreenRow(u.row,u.column))return h()}for(var d={error:[],warning:[],info:[]},p={error:{singular:"error",plural:"errors"},warning:{singular:"warning",plural:"warnings"},info:{singular:"information message",plural:"information messages"}},g=a.$useSvgGutterIcons?"ace_icon_svg":"ace_icon",m=0;m<i.text.length;m++){var v="<span class='ace_".concat(i.type[m]," ").concat(g,"' aria-label='").concat(p[i.type[m]].singular,"' role=img> </span> ").concat(i.text[m]);d[i.type[m]].push(v)}var y="<div class='ace_gutter-tooltip_body'>";y+=[].concat(d.error,d.warning,d.info).join("<br>"),y+="</div>";var w=!1,b="<div class='ace_gutter-tooltip_header'>";for(m=0;m<3;m++){var x=["error","warning","info"][m];if(d[x].length>0){var S=1===d[x].length?p[x].singular:p[x].plural;b+="".concat(w?", ":"").concat(d[x].length," ").concat(S),w=!0}}if(b+="</div>",r=b+y,c.setHtml(r),c.setClassName("ace_gutter-tooltip"),c.$element.setAttribute("aria-live","polite"),c.show(),s._signal("showGutterTooltip",c),s.on("mousewheel",h),e.$tooltipFollowsMouse)f(n);else{var _=n.domEvent.target,k=_.getBoundingClientRect(),C=c.getElement().style;C.left=k.right+"px",C.top=k.bottom+"px"}}function h(){t&&(t=clearTimeout(t)),r&&(c.hide(),r=null,s._signal("hideGutterTooltip",c),s.off("mousewheel",h))}function f(e){c.setPosition(e.x,e.y)}e.editor.setDefaultHandler("guttermousedown",(function(t){if(s.isFocused()&&0==t.getButton()){var n=a.getRegion(t);if("foldWidgets"!=n){var r=t.getDocumentPosition().row,i=s.session.selection;if(t.getShiftKey())i.selectTo(r,0);else{if(2==t.domEvent.detail)return s.selectAll(),t.preventDefault();e.$clickSelection=s.selection.getLineRange(r)}return e.setState("selectByLines"),e.captureMouse(t),t.preventDefault()}}})),e.editor.setDefaultHandler("guttermousemove",(function(o){var s=o.domEvent.target||o.domEvent.srcElement;if(i.hasCssClass(s,"ace_fold-widget"))return h();r&&e.$tooltipFollowsMouse&&f(o),n=o,t||(t=setTimeout((function(){t=null,n&&!e.isMousePressed?u():h()}),50))})),o.addListener(s.renderer.$gutter,"mouseout",(function(e){n=null,r&&!t&&(t=setTimeout((function(){t=null,h()}),50))}),s),s.on("changeSession",h)}var l=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return r(t,e),t.prototype.setPosition=function(e,t){var n=window.innerWidth||document.documentElement.clientWidth,r=window.innerHeight||document.documentElement.clientHeight,i=this.getWidth(),o=this.getHeight();e+=15,t+=15,e+i>n&&(e-=e+i-n),t+o>r&&(t-=20+o),s.prototype.setPosition.call(this,e,t)},t}(s);t.GutterHandler=a})),ace.define("ace/mouse/mouse_event",["require","exports","module","ace/lib/event","ace/lib/useragent"],(function(e,t,n){"use strict";var r=e("../lib/event"),i=e("../lib/useragent"),o=function(){function e(e,t){this.domEvent=e,this.editor=t,this.x=this.clientX=e.clientX,this.y=this.clientY=e.clientY,this.$pos=null,this.$inSelection=null,this.propagationStopped=!1,this.defaultPrevented=!1,this.getAccelKey=i.isMac?function(){return this.domEvent.metaKey}:function(){return this.domEvent.ctrlKey}}return e.prototype.stopPropagation=function(){r.stopPropagation(this.domEvent),this.propagationStopped=!0},e.prototype.preventDefault=function(){r.preventDefault(this.domEvent),this.defaultPrevented=!0},e.prototype.stop=function(){this.stopPropagation(),this.preventDefault()},e.prototype.getDocumentPosition=function(){return this.$pos||(this.$pos=this.editor.renderer.screenToTextCoordinates(this.clientX,this.clientY)),this.$pos},e.prototype.inSelection=function(){if(null!==this.$inSelection)return this.$inSelection;var e=this.editor,t=e.getSelectionRange();if(t.isEmpty())this.$inSelection=!1;else{var n=this.getDocumentPosition();this.$inSelection=t.contains(n.row,n.column)}return this.$inSelection},e.prototype.getButton=function(){return r.getButton(this.domEvent)},e.prototype.getShiftKey=function(){return this.domEvent.shiftKey},e}();t.MouseEvent=o})),ace.define("ace/mouse/dragdrop_handler",["require","exports","module","ace/lib/dom","ace/lib/event","ace/lib/useragent"],(function(e,t,n){"use strict";var r=e("../lib/dom"),i=e("../lib/event"),o=e("../lib/useragent"),s=200,a=200,l=5;function c(e){var t=e.editor,n=r.createElement("div");n.style.cssText="top:-100px;position:absolute;z-index:2147483647;opacity:0.5",n.textContent=" ";var c=["dragWait","dragWaitEnd","startDrag","dragReadyEnd","onMouseDrag"];c.forEach((function(t){e[t]=this[t]}),this),t.on("mousedown",this.onMouseDown.bind(e));var h,f,d,p,g,m,v,y,w,b,x,S=t.container,_=0;function k(e,n){var r=Date.now(),i=!n||e.row!=n.row,o=!n||e.column!=n.column;if(!b||i||o)t.moveCursorToPosition(e),b=r,x={x:f,y:d};else{var s=u(x.x,x.y,f,d);s>l?b=null:r-b>=a&&(t.renderer.scrollCursorIntoView(),b=null)}}function C(e,n){var r=Date.now(),i=t.renderer.layerConfig.lineHeight,o=t.renderer.layerConfig.characterWidth,a=t.renderer.scroller.getBoundingClientRect(),l={x:{left:f-a.left,right:a.right-f},y:{top:d-a.top,bottom:a.bottom-d}},c=Math.min(l.x.left,l.x.right),u=Math.min(l.y.top,l.y.bottom),h={row:e.row,column:e.column};c/o<=2&&(h.column+=l.x.left<l.x.right?-3:2),u/i<=1&&(h.row+=l.y.top<l.y.bottom?-1:1);var p=e.row!=h.row,g=e.column!=h.column,m=!n||e.row!=n.row;p||g&&!m?w?r-w>=s&&t.renderer.scrollCursorIntoView(h):w=r:w=null}function $(){var e=m;m=t.renderer.screenToTextCoordinates(f,d),k(m,e),C(m,e)}function A(){g=t.selection.toOrientedRange(),h=t.session.addMarker(g,"ace_selection",t.getSelectionStyle()),t.clearSelection(),t.isFocused()&&t.renderer.$cursorLayer.setBlinking(!1),clearInterval(p),$(),p=setInterval($,20),_=0,i.addListener(document,"mousemove",E)}function R(){clearInterval(p),t.session.removeMarker(h),h=null,t.selection.fromOrientedRange(g),t.isFocused()&&!y&&t.$resetCursorStyle(),g=null,m=null,_=0,w=null,b=null,i.removeListener(document,"mousemove",E)}this.onDragStart=function(e){if(this.cancelDrag||!S.draggable){var r=this;return setTimeout((function(){r.startSelect(),r.captureMouse(e)}),0),e.preventDefault()}g=t.getSelectionRange();var i=e.dataTransfer;i.effectAllowed=t.getReadOnly()?"copy":"copyMove",t.container.appendChild(n),i.setDragImage&&i.setDragImage(n,0,0),setTimeout((function(){t.container.removeChild(n)})),i.clearData(),i.setData("Text",t.session.getTextRange()),y=!0,this.setState("drag")},this.onDragEnd=function(e){if(S.draggable=!1,y=!1,this.setState(null),!t.getReadOnly()){var n=e.dataTransfer.dropEffect;v||"move"!=n||t.session.remove(t.getSelectionRange()),t.$resetCursorStyle()}this.editor.unsetStyle("ace_dragging"),this.editor.renderer.setCursorStyle("")},this.onDragEnter=function(e){if(!t.getReadOnly()&&L(e.dataTransfer))return f=e.clientX,d=e.clientY,h||A(),_++,e.dataTransfer.dropEffect=v=M(e),i.preventDefault(e)},this.onDragOver=function(e){if(!t.getReadOnly()&&L(e.dataTransfer))return f=e.clientX,d=e.clientY,h||(A(),_++),null!==T&&(T=null),e.dataTransfer.dropEffect=v=M(e),i.preventDefault(e)},this.onDragLeave=function(e){if(_--,_<=0&&h)return R(),v=null,i.preventDefault(e)},this.onDrop=function(e){if(m){var n=e.dataTransfer;if(y)switch(v){case"move":g=g.contains(m.row,m.column)?{start:m,end:m}:t.moveText(g,m);break;case"copy":g=t.moveText(g,m,!0);break}else{var r=n.getData("Text");g={start:m,end:t.session.insert(m,r)},t.focus(),v=null}return R(),i.preventDefault(e)}},i.addListener(S,"dragstart",this.onDragStart.bind(e),t),i.addListener(S,"dragend",this.onDragEnd.bind(e),t),i.addListener(S,"dragenter",this.onDragEnter.bind(e),t),i.addListener(S,"dragover",this.onDragOver.bind(e),t),i.addListener(S,"dragleave",this.onDragLeave.bind(e),t),i.addListener(S,"drop",this.onDrop.bind(e),t);var T=null;function E(){null==T&&(T=setTimeout((function(){null!=T&&h&&R()}),20))}function L(e){var t=e.types;return!t||Array.prototype.some.call(t,(function(e){return"text/plain"==e||"Text"==e}))}function M(e){var t=["copy","copymove","all","uninitialized"],n=["move","copymove","linkmove","all","uninitialized"],r=o.isMac?e.altKey:e.ctrlKey,i="uninitialized";try{i=e.dataTransfer.effectAllowed.toLowerCase()}catch(e){}var s="none";return r&&t.indexOf(i)>=0?s="copy":n.indexOf(i)>=0?s="move":t.indexOf(i)>=0&&(s="copy"),s}}function u(e,t,n,r){return Math.sqrt(Math.pow(n-e,2)+Math.pow(r-t,2))}(function(){this.dragWait=function(){var e=Date.now()-this.mousedownEvent.time;e>this.editor.getDragDelay()&&this.startDrag()},this.dragWaitEnd=function(){var e=this.editor.container;e.draggable=!1,this.startSelect(this.mousedownEvent.getDocumentPosition()),this.selectEnd()},this.dragReadyEnd=function(e){this.editor.$resetCursorStyle(),this.editor.unsetStyle("ace_dragging"),this.editor.renderer.setCursorStyle(""),this.dragWaitEnd()},this.startDrag=function(){this.cancelDrag=!1;var e=this.editor,t=e.container;t.draggable=!0,e.renderer.$cursorLayer.setBlinking(!1),e.setStyle("ace_dragging");var n=o.isWin?"default":"move";e.renderer.setCursorStyle(n),this.setState("dragReady")},this.onMouseDrag=function(e){var t=this.editor.container;if(o.isIE&&"dragReady"==this.state){var n=u(this.mousedownEvent.x,this.mousedownEvent.y,this.x,this.y);n>3&&t.dragDrop()}if("dragWait"===this.state){n=u(this.mousedownEvent.x,this.mousedownEvent.y,this.x,this.y);n>0&&(t.draggable=!1,this.startSelect(this.mousedownEvent.getDocumentPosition()))}},this.onMouseDown=function(e){if(this.$dragEnabled){this.mousedownEvent=e;var t=this.editor,n=e.inSelection(),r=e.getButton(),i=e.domEvent.detail||1;if(1===i&&0===r&&n){if(e.editor.inMultiSelectMode&&(e.getAccelKey()||e.getShiftKey()))return;this.mousedownEvent.time=Date.now();var s=e.domEvent.target||e.domEvent.srcElement;if("unselectable"in s&&(s.unselectable="on"),t.getDragDelay()){if(o.isWebKit){this.cancelDrag=!0;var a=t.container;a.draggable=!0}this.setState("dragWait")}else this.startDrag();this.captureMouse(e,this.onMouseDrag.bind(this)),e.defaultPrevented=!0}}}}).call(c.prototype),t.DragdropHandler=c})),ace.define("ace/mouse/touch_handler",["require","exports","module","ace/mouse/mouse_event","ace/lib/event","ace/lib/dom"],(function(e,t,n){"use strict";var r=e("./mouse_event").MouseEvent,i=e("../lib/event"),o=e("../lib/dom");t.addTouchListeners=function(e,t){var n,s,a,l,c,u,h,f,d,p="scroll",g=0,m=0,v=0,y=0;function w(){var e=window.navigator&&window.navigator.clipboard,n=!1,r=function(){var r=t.getCopyText(),i=t.session.getUndoManager().hasUndo();d.replaceChild(o.buildDom(n?["span",!r&&["span",{class:"ace_mobile-button",action:"selectall"},"Select All"],r&&["span",{class:"ace_mobile-button",action:"copy"},"Copy"],r&&["span",{class:"ace_mobile-button",action:"cut"},"Cut"],e&&["span",{class:"ace_mobile-button",action:"paste"},"Paste"],i&&["span",{class:"ace_mobile-button",action:"undo"},"Undo"],["span",{class:"ace_mobile-button",action:"find"},"Find"],["span",{class:"ace_mobile-button",action:"openCommandPallete"},"Palette"]]:["span"]),d.firstChild)},i=function(i){var o=i.target.getAttribute("action");if("more"==o||!n)return n=!n,r();"paste"==o?e.readText().then((function(e){t.execCommand(o,e)})):o&&("cut"!=o&&"copy"!=o||(e?e.writeText(t.getCopyText()):document.execCommand("copy")),t.execCommand(o)),d.firstChild.style.display="none",n=!1,"openCommandPallete"!=o&&t.focus()};d=o.buildDom(["div",{class:"ace_mobile-menu",ontouchstart:function(e){p="menu",e.stopPropagation(),e.preventDefault(),t.textInput.focus()},ontouchend:function(e){e.stopPropagation(),e.preventDefault(),i(e)},onclick:i},["span"],["span",{class:"ace_mobile-button",action:"more"},"..."]],t.container)}function b(){d||w();var e=t.selection.cursor,n=t.renderer.textToScreenCoordinates(e.row,e.column),r=t.renderer.textToScreenCoordinates(0,0).pageX,i=t.renderer.scrollLeft,o=t.container.getBoundingClientRect();d.style.top=n.pageY-o.top-3+"px",n.pageX-o.left<o.width-70?(d.style.left="",d.style.right="10px"):(d.style.right="",d.style.left=r+i-o.left+"px"),d.style.display="",d.firstChild.style.display="none",t.on("input",x)}function x(e){d&&(d.style.display="none"),t.off("input",x)}function S(){c=null,clearTimeout(c);var e=t.selection.getRange(),n=e.contains(h.row,h.column);!e.isEmpty()&&n||(t.selection.moveToPosition(h),t.selection.selectWord()),p="wait",b()}function _(){c=null,clearTimeout(c),t.selection.moveToPosition(h);var e=m>=2?t.selection.getLineRange(h.row):t.session.getBracketRange(h);e&&!e.isEmpty()?t.selection.setRange(e):t.selection.selectWord(),p="wait"}function k(){g+=60,u=setInterval((function(){g--<=0&&(clearInterval(u),u=null),Math.abs(v)<.01&&(v=0),Math.abs(y)<.01&&(y=0),g<20&&(v*=.9),g<20&&(y*=.9);var e=t.session.getScrollTop();t.renderer.scrollBy(10*v,10*y),e==t.session.getScrollTop()&&(g=0)}),10)}i.addListener(e,"contextmenu",(function(e){if(f){var n=t.textInput.getElement();n.focus()}}),t),i.addListener(e,"touchstart",(function(e){var i=e.touches;if(c||i.length>1)return clearTimeout(c),c=null,a=-1,void(p="zoom");f=t.$mouseHandler.isMousePressed=!0;var o=t.renderer.layerConfig.lineHeight,u=t.renderer.layerConfig.lineHeight,d=e.timeStamp;l=d;var w=i[0],b=w.clientX,x=w.clientY;Math.abs(n-b)+Math.abs(s-x)>o&&(a=-1),n=e.clientX=b,s=e.clientY=x,v=y=0;var k=new r(e,t);if(h=k.getDocumentPosition(),d-a<500&&1==i.length&&!g)m++,e.preventDefault(),e.button=0,_();else{m=0;var C=t.selection.cursor,$=t.selection.isEmpty()?C:t.selection.anchor,A=t.renderer.$cursorLayer.getPixelPosition(C,!0),R=t.renderer.$cursorLayer.getPixelPosition($,!0),T=t.renderer.scroller.getBoundingClientRect(),E=t.renderer.layerConfig.offset,L=t.renderer.scrollLeft,M=function(e,t){return e/=u,t=t/o-.75,e*e+t*t};if(e.clientX<T.left)return void(p="zoom");var O=M(e.clientX-T.left-A.left+L,e.clientY-T.top-A.top+E),I=M(e.clientX-T.left-R.left+L,e.clientY-T.top-R.top+E);O<3.5&&I<3.5&&(p=O>I?"cursor":"anchor"),p=I<3.5?"anchor":O<3.5?"cursor":"scroll",c=setTimeout(S,450)}a=d}),t),i.addListener(e,"touchend",(function(e){f=t.$mouseHandler.isMousePressed=!1,u&&clearInterval(u),"zoom"==p?(p="",g=0):c?(t.selection.moveToPosition(h),g=0,b()):"scroll"==p?(k(),x()):b(),clearTimeout(c),c=null}),t),i.addListener(e,"touchmove",(function(e){c&&(clearTimeout(c),c=null);var i=e.touches;if(!(i.length>1||"zoom"==p)){var o=i[0],a=n-o.clientX,u=s-o.clientY;if("wait"==p){if(!(a*a+u*u>4))return e.preventDefault();p="cursor"}n=o.clientX,s=o.clientY,e.clientX=o.clientX,e.clientY=o.clientY;var h=e.timeStamp,f=h-l;if(l=h,"scroll"==p){var d=new r(e,t);d.speed=1,d.wheelX=a,d.wheelY=u,10*Math.abs(a)<Math.abs(u)&&(a=0),10*Math.abs(u)<Math.abs(a)&&(u=0),0!=f&&(v=a/f,y=u/f),t._emit("mousewheel",d),d.propagationStopped||(v=y=0)}else{var g=new r(e,t),m=g.getDocumentPosition();"cursor"==p?t.selection.moveCursorToPosition(m):"anchor"==p&&t.selection.setSelectionAnchor(m.row,m.column),t.renderer.scrollCursorIntoView(m),e.preventDefault()}}}),t)}})),ace.define("ace/mouse/mouse_handler",["require","exports","module","ace/lib/event","ace/lib/useragent","ace/mouse/default_handlers","ace/mouse/default_gutter_handler","ace/mouse/mouse_event","ace/mouse/dragdrop_handler","ace/mouse/touch_handler","ace/config"],(function(e,t,n){"use strict";var r=e("../lib/event"),i=e("../lib/useragent"),o=e("./default_handlers").DefaultHandlers,s=e("./default_gutter_handler").GutterHandler,a=e("./mouse_event").MouseEvent,l=e("./dragdrop_handler").DragdropHandler,c=e("./touch_handler").addTouchListeners,u=e("../config"),h=function(){function e(e){var t=this;this.editor=e,new o(this),new s(this),new l(this);var n=function(t){var n=!document.hasFocus||!document.hasFocus()||!e.isFocused()&&document.activeElement==(e.textInput&&e.textInput.getElement());n&&window.focus(),e.focus(),setTimeout((function(){e.isFocused()||e.focus()}))},a=e.renderer.getMouseEventTarget();r.addListener(a,"click",this.onMouseEvent.bind(this,"click"),e),r.addListener(a,"mousemove",this.onMouseMove.bind(this,"mousemove"),e),r.addMultiMouseDownListener([a,e.renderer.scrollBarV&&e.renderer.scrollBarV.inner,e.renderer.scrollBarH&&e.renderer.scrollBarH.inner,e.textInput&&e.textInput.getElement()].filter(Boolean),[400,300,250],this,"onMouseEvent",e),r.addMouseWheelListener(e.container,this.onMouseWheel.bind(this,"mousewheel"),e),c(e.container,e);var u=e.renderer.$gutter;r.addListener(u,"mousedown",this.onMouseEvent.bind(this,"guttermousedown"),e),r.addListener(u,"click",this.onMouseEvent.bind(this,"gutterclick"),e),r.addListener(u,"dblclick",this.onMouseEvent.bind(this,"gutterdblclick"),e),r.addListener(u,"mousemove",this.onMouseEvent.bind(this,"guttermousemove"),e),r.addListener(a,"mousedown",n,e),r.addListener(u,"mousedown",n,e),i.isIE&&e.renderer.scrollBarV&&(r.addListener(e.renderer.scrollBarV.element,"mousedown",n,e),r.addListener(e.renderer.scrollBarH.element,"mousedown",n,e)),e.on("mousemove",(function(n){if(!t.state&&!t.$dragDelay&&t.$dragEnabled){var r=e.renderer.screenToTextCoordinates(n.x,n.y),i=e.session.selection.getRange(),o=e.renderer;!i.isEmpty()&&i.insideStart(r.row,r.column)?o.setCursorStyle("default"):o.setCursorStyle("")}}),e)}return e.prototype.onMouseEvent=function(e,t){this.editor.session&&this.editor._emit(e,new a(t,this.editor))},e.prototype.onMouseMove=function(e,t){var n=this.editor._eventRegistry&&this.editor._eventRegistry.mousemove;n&&n.length&&this.editor._emit(e,new a(t,this.editor))},e.prototype.onMouseWheel=function(e,t){var n=new a(t,this.editor);n.speed=2*this.$scrollSpeed,n.wheelX=t.wheelX,n.wheelY=t.wheelY,this.editor._emit(e,n)},e.prototype.setState=function(e){this.state=e},e.prototype.captureMouse=function(e,t){this.x=e.x,this.y=e.y,this.isMousePressed=!0;var n=this.editor,o=this.editor.renderer;o.$isMousePressed=!0;var s=this,l=function(e){if(e){if(i.isWebKit&&!e.which&&s.releaseMouse)return s.releaseMouse();s.x=e.clientX,s.y=e.clientY,t&&t(e),s.mouseEvent=new a(e,s.editor),s.$mouseMoved=!0}},c=function(e){n.off("beforeEndOperation",h),clearInterval(f),n.session&&u(),s[s.state+"End"]&&s[s.state+"End"](e),s.state="",s.isMousePressed=o.$isMousePressed=!1,o.$keepTextAreaAtCursor&&o.$moveTextAreaToCursor(),s.$onCaptureMouseMove=s.releaseMouse=null,e&&s.onMouseEvent("mouseup",e),n.endOperation()},u=function(){s[s.state]&&s[s.state](),s.$mouseMoved=!1};if(i.isOldIE&&"dblclick"==e.domEvent.type)return setTimeout((function(){c(e)}));var h=function(e){s.releaseMouse&&n.curOp.command.name&&n.curOp.selectionChanged&&(s[s.state+"End"]&&s[s.state+"End"](),s.state="",s.releaseMouse())};n.on("beforeEndOperation",h),n.startOperation({command:{name:"mouse"}}),s.$onCaptureMouseMove=l,s.releaseMouse=r.capture(this.editor.container,l,c);var f=setInterval(u,20)},e.prototype.cancelContextMenu=function(){var e=function(t){t&&t.domEvent&&"contextmenu"!=t.domEvent.type||(this.editor.off("nativecontextmenu",e),t&&t.domEvent&&r.stopEvent(t.domEvent))}.bind(this);setTimeout(e,10),this.editor.on("nativecontextmenu",e)},e.prototype.destroy=function(){this.releaseMouse&&this.releaseMouse()},e}();h.prototype.releaseMouse=null,u.defineOptions(h.prototype,"mouseHandler",{scrollSpeed:{initialValue:2},dragDelay:{initialValue:i.isMac?150:0},dragEnabled:{initialValue:!0},focusTimeout:{initialValue:0},tooltipFollowsMouse:{initialValue:!0}}),t.MouseHandler=h})),ace.define("ace/mouse/fold_handler",["require","exports","module","ace/lib/dom"],(function(e,t,n){"use strict";var r=e("../lib/dom"),i=function(){function e(e){e.on("click",(function(t){var n=t.getDocumentPosition(),i=e.session,o=i.getFoldAt(n.row,n.column,1);o&&(t.getAccelKey()?i.removeFold(o):i.expandFold(o),t.stop());var s=t.domEvent&&t.domEvent.target;s&&r.hasCssClass(s,"ace_inline_button")&&r.hasCssClass(s,"ace_toggle_wrap")&&(i.setOption("wrap",!i.getUseWrapMode()),e.renderer.scrollCursorIntoView())})),e.on("gutterclick",(function(t){var n=e.renderer.$gutterLayer.getRegion(t);if("foldWidgets"==n){var r=t.getDocumentPosition().row,i=e.session;i.foldWidgets&&i.foldWidgets[r]&&e.session.onFoldWidgetClick(r,t),e.isFocused()||e.focus(),t.stop()}})),e.on("gutterdblclick",(function(t){var n=e.renderer.$gutterLayer.getRegion(t);if("foldWidgets"==n){var r=t.getDocumentPosition().row,i=e.session,o=i.getParentFoldRangeData(r,!0),s=o.range||o.firstRange;if(s){r=s.start.row;var a=i.getFoldAt(r,i.getLine(r).length,1);a?i.removeFold(a):(i.addFold("...",s),e.renderer.scrollCursorIntoView({row:s.start.row,column:0}))}t.stop()}}))}return e}();t.FoldHandler=i})),ace.define("ace/keyboard/keybinding",["require","exports","module","ace/lib/keys","ace/lib/event"],(function(e,t,n){"use strict";var r=e("../lib/keys"),i=e("../lib/event"),o=function(){function e(e){this.$editor=e,this.$data={editor:e},this.$handlers=[],this.setDefaultHandler(e.commands)}return e.prototype.setDefaultHandler=function(e){this.removeKeyboardHandler(this.$defaultHandler),this.$defaultHandler=e,this.addKeyboardHandler(e,0)},e.prototype.setKeyboardHandler=function(e){var t=this.$handlers;if(t[t.length-1]!=e){while(t[t.length-1]&&t[t.length-1]!=this.$defaultHandler)this.removeKeyboardHandler(t[t.length-1]);this.addKeyboardHandler(e,1)}},e.prototype.addKeyboardHandler=function(e,t){if(e){"function"!=typeof e||e.handleKeyboard||(e.handleKeyboard=e);var n=this.$handlers.indexOf(e);-1!=n&&this.$handlers.splice(n,1),void 0==t?this.$handlers.push(e):this.$handlers.splice(t,0,e),-1==n&&e.attach&&e.attach(this.$editor)}},e.prototype.removeKeyboardHandler=function(e){var t=this.$handlers.indexOf(e);return-1!=t&&(this.$handlers.splice(t,1),e.detach&&e.detach(this.$editor),!0)},e.prototype.getKeyboardHandler=function(){return this.$handlers[this.$handlers.length-1]},e.prototype.getStatusText=function(){var e=this.$data,t=e.editor;return this.$handlers.map((function(n){return n.getStatusText&&n.getStatusText(t,e)||""})).filter(Boolean).join(" ")},e.prototype.$callKeyboardHandlers=function(e,t,n,r){for(var o,s=!1,a=this.$editor.commands,l=this.$handlers.length;l--;)if(o=this.$handlers[l].handleKeyboard(this.$data,e,t,n,r),o&&o.command&&(s="null"==o.command||a.exec(o.command,this.$editor,o.args,r),s&&r&&-1!=e&&1!=o.passEvent&&1!=o.command.passEvent&&i.stopEvent(r),s))break;return s||-1!=e||(o={command:"insertstring"},s=a.exec("insertstring",this.$editor,t)),s&&this.$editor._signal&&this.$editor._signal("keyboardActivity",o),s},e.prototype.onCommandKey=function(e,t,n){var i=r.keyCodeToString(n);return this.$callKeyboardHandlers(t,i,n,e)},e.prototype.onTextInput=function(e){return this.$callKeyboardHandlers(-1,e)},e}();t.KeyBinding=o})),ace.define("ace/lib/bidiutil",["require","exports","module"],(function(e,t,n){"use strict";var r=0,i=0,o=!1,s=!1,a=!1,l=[[0,3,0,1,0,0,0],[0,3,0,1,2,2,0],[0,3,0,17,2,0,1],[0,3,5,5,4,1,0],[0,3,21,21,4,0,1],[0,3,5,5,4,2,0]],c=[[2,0,1,1,0,1,0],[2,0,1,1,0,2,0],[2,0,2,1,3,2,0],[2,0,2,33,3,1,1]],u=0,h=1,f=0,d=1,p=2,g=3,m=4,v=5,y=6,w=7,b=8,x=9,S=10,_=11,k=12,C=13,$=14,A=15,R=16,T=17,E=18,L=[E,E,E,E,E,E,E,E,E,y,v,y,b,v,E,E,E,E,E,E,E,E,E,E,E,E,E,E,v,v,v,y,b,m,m,_,_,_,m,m,m,m,m,S,x,S,x,x,p,p,p,p,p,p,p,p,p,p,x,m,m,m,m,m,m,f,f,f,f,f,f,f,f,f,f,f,f,f,f,f,f,f,f,f,f,f,f,f,f,f,f,m,m,m,m,m,m,f,f,f,f,f,f,f,f,f,f,f,f,f,f,f,f,f,f,f,f,f,f,f,f,f,f,m,m,m,m,E,E,E,E,E,E,v,E,E,E,E,E,E,E,E,E,E,E,E,E,E,E,E,E,E,E,E,E,E,E,E,E,E,x,m,_,_,_,_,m,m,m,m,f,m,m,E,m,m,_,_,p,p,m,f,m,m,m,p,f,m,m,m,m,m],M=[b,b,b,b,b,b,b,b,b,b,b,E,E,E,f,d,m,m,m,m,m,m,m,m,m,m,m,m,m,m,m,m,m,m,m,m,m,m,m,m,b,v,C,$,A,R,T,x,_,_,_,_,_,m,m,m,m,m,m,m,m,m,m,m,m,m,m,m,x,m,m,m,m,m,m,m,m,m,m,m,m,m,m,m,m,m,m,m,m,m,m,m,m,m,m,b];function O(e,t,n,u){var h=r?c:l,f=null,d=null,p=null,g=0,m=null,w=null,x=-1,S=null,_=null,k=[];if(!u)for(S=0,u=[];S<n;S++)u[S]=D(e[S]);for(i=r,o=!1,!1,s=!1,a=!1,_=0;_<n;_++){if(f=g,k[_]=d=P(e,u,k,_),g=h[f][d],m=240&g,g&=15,t[_]=p=h[g][5],m>0)if(16==m){for(S=x;S<_;S++)t[S]=1;x=-1}else x=-1;if(w=h[g][6],w)-1==x&&(x=_);else if(x>-1){for(S=x;S<_;S++)t[S]=p;x=-1}u[_]==v&&(t[_]=0),i|=p}if(a)for(S=0;S<n;S++)if(u[S]==y){t[S]=r;for(var C=S-1;C>=0;C--){if(u[C]!=b)break;t[C]=r}}}function I(e,t,n){if(!(i<e))if(1!=e||r!=h||s){var o,a,l,c,u=n.length,f=0;while(f<u){if(t[f]>=e){o=f+1;while(o<u&&t[o]>=e)o++;for(a=f,l=o-1;a<l;a++,l--)c=n[a],n[a]=n[l],n[l]=c;f=o}f++}}else n.reverse()}function P(e,t,n,i){var l,c,u,h,L=t[i];switch(L){case f:case d:o=!1;case m:case g:return L;case p:return o?g:p;case w:return o=!0,!0,d;case b:return m;case x:return i<1||i+1>=t.length||(l=n[i-1])!=p&&l!=g||(c=t[i+1])!=p&&c!=g?m:(o&&(c=g),c==l?c:m);case S:return l=i>0?n[i-1]:v,l==p&&i+1<t.length&&t[i+1]==p?p:m;case _:if(i>0&&n[i-1]==p)return p;if(o)return m;h=i+1,u=t.length;while(h<u&&t[h]==_)h++;return h<u&&t[h]==p?p:m;case k:u=t.length,h=i+1;while(h<u&&t[h]==k)h++;if(h<u){var M=e[i],O=M>=1425&&M<=2303||64286==M;if(l=t[h],O&&(l==d||l==w))return d}return i<1||(l=t[i-1])==v?m:n[i-1];case v:return o=!1,s=!0,r;case y:return a=!0,m;case C:case $:case R:case T:case A:o=!1;case E:return m}}function D(e){var t=e.charCodeAt(0),n=t>>8;return 0==n?t>191?f:L[t]:5==n?/[\u0591-\u05f4]/.test(e)?d:f:6==n?/[\u0610-\u061a\u064b-\u065f\u06d6-\u06e4\u06e7-\u06ed]/.test(e)?k:/[\u0660-\u0669\u066b-\u066c]/.test(e)?g:1642==t?_:/[\u06f0-\u06f9]/.test(e)?p:w:32==n&&t<=8287?M[255&t]:254==n&&t>=65136?w:m}t.L=f,t.R=d,t.EN=p,t.ON_R=3,t.AN=4,t.R_H=5,t.B=6,t.RLE=7,t.DOT="·",t.doBidiReorder=function(e,n,i){if(e.length<2)return{};var o=e.split(""),s=new Array(o.length),a=new Array(o.length),l=[];r=i?h:u,O(o,l,o.length,n);for(var c=0;c<s.length;s[c]=c,c++);I(2,l,s),I(1,l,s);for(c=0;c<s.length-1;c++)n[c]===g?l[c]=t.AN:l[c]===d&&(n[c]>w&&n[c]<C||n[c]===m||n[c]===E)?l[c]=t.ON_R:c>0&&"ل"===o[c-1]&&/\u0622|\u0623|\u0625|\u0627/.test(o[c])&&(l[c-1]=l[c]=t.R_H,c++);o[o.length-1]===t.DOT&&(l[o.length-1]=t.B),"‫"===o[0]&&(l[0]=t.RLE);for(c=0;c<s.length;c++)a[c]=l[s[c]];return{logicalFromVisual:s,bidiLevels:a}},t.hasBidiCharacters=function(e,t){for(var n=!1,r=0;r<e.length;r++)t[r]=D(e.charAt(r)),n||t[r]!=d&&t[r]!=w&&t[r]!=g||(n=!0);return n},t.getVisualFromLogicalIdx=function(e,t){for(var n=0;n<t.logicalFromVisual.length;n++)if(t.logicalFromVisual[n]==e)return n;return 0}})),ace.define("ace/bidihandler",["require","exports","module","ace/lib/bidiutil","ace/lib/lang"],(function(e,t,n){"use strict";var r=e("./lib/bidiutil"),i=e("./lib/lang"),o=/[\u0590-\u05f4\u0600-\u06ff\u0700-\u08ac\u202B]/,s=function(){function e(e){this.session=e,this.bidiMap={},this.currentRow=null,this.bidiUtil=r,this.charWidths=[],this.EOL="¬",this.showInvisibles=!0,this.isRtlDir=!1,this.$isRtl=!1,this.line="",this.wrapIndent=0,this.EOF="¶",this.RLE="‫",this.contentWidth=0,this.fontMetrics=null,this.rtlLineOffset=0,this.wrapOffset=0,this.isMoveLeftOperation=!1,this.seenBidi=o.test(e.getValue())}return e.prototype.isBidiRow=function(e,t,n){return!!this.seenBidi&&(e!==this.currentRow&&(this.currentRow=e,this.updateRowLine(t,n),this.updateBidiMap()),this.bidiMap.bidiLevels)},e.prototype.onChange=function(e){this.seenBidi?this.currentRow=null:"insert"==e.action&&o.test(e.lines.join("\n"))&&(this.seenBidi=!0,this.currentRow=null)},e.prototype.getDocumentRow=function(){var e=0,t=this.session.$screenRowCache;if(t.length){var n=this.session.$getRowCacheIndex(t,this.currentRow);n>=0&&(e=this.session.$docRowCache[n])}return e},e.prototype.getSplitIndex=function(){var e=0,t=this.session.$screenRowCache;if(t.length){var n,r=this.session.$getRowCacheIndex(t,this.currentRow);while(this.currentRow-e>0){if(n=this.session.$getRowCacheIndex(t,this.currentRow-e-1),n!==r)break;r=n,e++}}else e=this.currentRow;return e},e.prototype.updateRowLine=function(e,t){void 0===e&&(e=this.getDocumentRow());var n=e===this.session.getLength()-1,o=n?this.EOF:this.EOL;if(this.wrapIndent=0,this.line=this.session.getLine(e),this.isRtlDir=this.$isRtl||this.line.charAt(0)===this.RLE,this.session.$useWrapMode){var s=this.session.$wrapData[e];s&&(void 0===t&&(t=this.getSplitIndex()),t>0&&s.length?(this.wrapIndent=s.indent,this.wrapOffset=this.wrapIndent*this.charWidths[r.L],this.line=t<s.length?this.line.substring(s[t-1],s[t]):this.line.substring(s[s.length-1])):this.line=this.line.substring(0,s[t]),t==s.length&&(this.line+=this.showInvisibles?o:r.DOT))}else this.line+=this.showInvisibles?o:r.DOT;var a,l=this.session,c=0;this.line=this.line.replace(/\t|[\u1100-\u2029, \u202F-\uFFE6]/g,(function(e,t){return"\t"===e||l.isFullWidth(e.charCodeAt(0))?(a="\t"===e?l.getScreenTabSize(t+c):2,c+=a-1,i.stringRepeat(r.DOT,a)):e})),this.isRtlDir&&(this.fontMetrics.$main.textContent=this.line.charAt(this.line.length-1)==r.DOT?this.line.substr(0,this.line.length-1):this.line,this.rtlLineOffset=this.contentWidth-this.fontMetrics.$main.getBoundingClientRect().width)},e.prototype.updateBidiMap=function(){var e=[];r.hasBidiCharacters(this.line,e)||this.isRtlDir?this.bidiMap=r.doBidiReorder(this.line,e,this.isRtlDir):this.bidiMap={}},e.prototype.markAsDirty=function(){this.currentRow=null},e.prototype.updateCharacterWidths=function(e){if(this.characterWidth!==e.$characterSize.width){this.fontMetrics=e;var t=this.characterWidth=e.$characterSize.width,n=e.$measureCharWidth("ה");this.charWidths[r.L]=this.charWidths[r.EN]=this.charWidths[r.ON_R]=t,this.charWidths[r.R]=this.charWidths[r.AN]=n,this.charWidths[r.R_H]=.45*n,this.charWidths[r.B]=this.charWidths[r.RLE]=0,this.currentRow=null}},e.prototype.setShowInvisibles=function(e){this.showInvisibles=e,this.currentRow=null},e.prototype.setEolChar=function(e){this.EOL=e},e.prototype.setContentWidth=function(e){this.contentWidth=e},e.prototype.isRtlLine=function(e){return!!this.$isRtl||(void 0!=e?this.session.getLine(e).charAt(0)==this.RLE:this.isRtlDir)},e.prototype.setRtlDirection=function(e,t){for(var n=e.getCursorPosition(),r=e.selection.getSelectionAnchor().row;r<=n.row;r++)t||e.session.getLine(r).charAt(0)!==e.session.$bidiHandler.RLE?t&&e.session.getLine(r).charAt(0)!==e.session.$bidiHandler.RLE&&e.session.doc.insert({column:0,row:r},e.session.$bidiHandler.RLE):e.session.doc.removeInLine(r,0,1)},e.prototype.getPosLeft=function(e){e-=this.wrapIndent;var t=this.line.charAt(0)===this.RLE?1:0,n=e>t?this.session.getOverwrite()?e:e-1:t,i=r.getVisualFromLogicalIdx(n,this.bidiMap),o=this.bidiMap.bidiLevels,s=0;!this.session.getOverwrite()&&e<=t&&o[i]%2!==0&&i++;for(var a=0;a<i;a++)s+=this.charWidths[o[a]];return!this.session.getOverwrite()&&e>t&&o[i]%2===0&&(s+=this.charWidths[o[i]]),this.wrapIndent&&(s+=this.isRtlDir?-1*this.wrapOffset:this.wrapOffset),this.isRtlDir&&(s+=this.rtlLineOffset),s},e.prototype.getSelections=function(e,t){var n,r=this.bidiMap,i=r.bidiLevels,o=[],s=0,a=Math.min(e,t)-this.wrapIndent,l=Math.max(e,t)-this.wrapIndent,c=!1,u=!1,h=0;this.wrapIndent&&(s+=this.isRtlDir?-1*this.wrapOffset:this.wrapOffset);for(var f,d=0;d<i.length;d++)f=r.logicalFromVisual[d],n=i[d],c=f>=a&&f<l,c&&!u?h=s:!c&&u&&o.push({left:h,width:s-h}),s+=this.charWidths[n],u=c;if(c&&d===i.length&&o.push({left:h,width:s-h}),this.isRtlDir)for(var p=0;p<o.length;p++)o[p].left+=this.rtlLineOffset;return o},e.prototype.offsetToCol=function(e){this.isRtlDir&&(e-=this.rtlLineOffset);var t=0,n=(e=Math.max(e,0),0),r=0,i=this.bidiMap.bidiLevels,o=this.charWidths[i[r]];this.wrapIndent&&(e-=this.isRtlDir?-1*this.wrapOffset:this.wrapOffset);while(e>n+o/2){if(n+=o,r===i.length-1){o=0;break}o=this.charWidths[i[++r]]}return r>0&&i[r-1]%2!==0&&i[r]%2===0?(e<n&&r--,t=this.bidiMap.logicalFromVisual[r]):r>0&&i[r-1]%2===0&&i[r]%2!==0?t=1+(e>n?this.bidiMap.logicalFromVisual[r]:this.bidiMap.logicalFromVisual[r-1]):this.isRtlDir&&r===i.length-1&&0===o&&i[r-1]%2===0||!this.isRtlDir&&0===r&&i[r]%2!==0?t=1+this.bidiMap.logicalFromVisual[r]:(r>0&&i[r-1]%2!==0&&0!==o&&r--,t=this.bidiMap.logicalFromVisual[r]),0===t&&this.isRtlDir&&t++,t+this.wrapIndent},e}();t.BidiHandler=s})),ace.define("ace/selection",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/lib/event_emitter","ace/range"],(function(e,t,n){"use strict";var r=e("./lib/oop"),i=e("./lib/lang"),o=e("./lib/event_emitter").EventEmitter,s=e("./range").Range,a=function(e){this.session=e,this.doc=e.getDocument(),this.clearSelection(),this.cursor=this.lead=this.doc.createAnchor(0,0),this.anchor=this.doc.createAnchor(0,0),this.$silent=!1;var t=this;this.cursor.on("change",(function(e){t.$cursorChanged=!0,t.$silent||t._emit("changeCursor"),t.$isEmpty||t.$silent||t._emit("changeSelection"),t.$keepDesiredColumnOnChange||e.old.column==e.value.column||(t.$desiredColumn=null)})),this.anchor.on("change",(function(){t.$anchorChanged=!0,t.$isEmpty||t.$silent||t._emit("changeSelection")}))};(function(){r.implement(this,o),this.isEmpty=function(){return this.$isEmpty||this.anchor.row==this.lead.row&&this.anchor.column==this.lead.column},this.isMultiLine=function(){return!this.$isEmpty&&this.anchor.row!=this.cursor.row},this.getCursor=function(){return this.lead.getPosition()},this.setAnchor=function(e,t){this.$isEmpty=!1,this.anchor.setPosition(e,t)},this.setSelectionAnchor=this.setAnchor,this.getAnchor=function(){return this.$isEmpty?this.getSelectionLead():this.anchor.getPosition()},this.getSelectionAnchor=this.getAnchor,this.getSelectionLead=function(){return this.lead.getPosition()},this.isBackwards=function(){var e=this.anchor,t=this.lead;return e.row>t.row||e.row==t.row&&e.column>t.column},this.getRange=function(){var e=this.anchor,t=this.lead;return this.$isEmpty?s.fromPoints(t,t):this.isBackwards()?s.fromPoints(t,e):s.fromPoints(e,t)},this.clearSelection=function(){this.$isEmpty||(this.$isEmpty=!0,this._emit("changeSelection"))},this.selectAll=function(){this.$setSelection(0,0,Number.MAX_VALUE,Number.MAX_VALUE)},this.setRange=this.setSelectionRange=function(e,t){var n=t?e.end:e.start,r=t?e.start:e.end;this.$setSelection(n.row,n.column,r.row,r.column)},this.$setSelection=function(e,t,n,r){if(!this.$silent){var i=this.$isEmpty,o=this.inMultiSelectMode;this.$silent=!0,this.$cursorChanged=this.$anchorChanged=!1,this.anchor.setPosition(e,t),this.cursor.setPosition(n,r),this.$isEmpty=!s.comparePoints(this.anchor,this.cursor),this.$silent=!1,this.$cursorChanged&&this._emit("changeCursor"),(this.$cursorChanged||this.$anchorChanged||i!=this.$isEmpty||o)&&this._emit("changeSelection")}},this.$moveSelection=function(e){var t=this.lead;this.$isEmpty&&this.setSelectionAnchor(t.row,t.column),e.call(this)},this.selectTo=function(e,t){this.$moveSelection((function(){this.moveCursorTo(e,t)}))},this.selectToPosition=function(e){this.$moveSelection((function(){this.moveCursorToPosition(e)}))},this.moveTo=function(e,t){this.clearSelection(),this.moveCursorTo(e,t)},this.moveToPosition=function(e){this.clearSelection(),this.moveCursorToPosition(e)},this.selectUp=function(){this.$moveSelection(this.moveCursorUp)},this.selectDown=function(){this.$moveSelection(this.moveCursorDown)},this.selectRight=function(){this.$moveSelection(this.moveCursorRight)},this.selectLeft=function(){this.$moveSelection(this.moveCursorLeft)},this.selectLineStart=function(){this.$moveSelection(this.moveCursorLineStart)},this.selectLineEnd=function(){this.$moveSelection(this.moveCursorLineEnd)},this.selectFileEnd=function(){this.$moveSelection(this.moveCursorFileEnd)},this.selectFileStart=function(){this.$moveSelection(this.moveCursorFileStart)},this.selectWordRight=function(){this.$moveSelection(this.moveCursorWordRight)},this.selectWordLeft=function(){this.$moveSelection(this.moveCursorWordLeft)},this.getWordRange=function(e,t){if("undefined"==typeof t){var n=e||this.lead;e=n.row,t=n.column}return this.session.getWordRange(e,t)},this.selectWord=function(){this.setSelectionRange(this.getWordRange())},this.selectAWord=function(){var e=this.getCursor(),t=this.session.getAWordRange(e.row,e.column);this.setSelectionRange(t)},this.getLineRange=function(e,t){var n,r="number"==typeof e?e:this.lead.row,i=this.session.getFoldLine(r);return i?(r=i.start.row,n=i.end.row):n=r,!0===t?new s(r,0,n,this.session.getLine(n).length):new s(r,0,n+1,0)},this.selectLine=function(){this.setSelectionRange(this.getLineRange())},this.moveCursorUp=function(){this.moveCursorBy(-1,0)},this.moveCursorDown=function(){this.moveCursorBy(1,0)},this.wouldMoveIntoSoftTab=function(e,t,n){var r=e.column,i=e.column+t;return n<0&&(r=e.column-t,i=e.column),this.session.isTabStop(e)&&this.doc.getLine(e.row).slice(r,i).split(" ").length-1==t},this.moveCursorLeft=function(){var e,t=this.lead.getPosition();if(e=this.session.getFoldAt(t.row,t.column,-1))this.moveCursorTo(e.start.row,e.start.column);else if(0===t.column)t.row>0&&this.moveCursorTo(t.row-1,this.doc.getLine(t.row-1).length);else{var n=this.session.getTabSize();this.wouldMoveIntoSoftTab(t,n,-1)&&!this.session.getNavigateWithinSoftTabs()?this.moveCursorBy(0,-n):this.moveCursorBy(0,-1)}},this.moveCursorRight=function(){var e,t=this.lead.getPosition();if(e=this.session.getFoldAt(t.row,t.column,1))this.moveCursorTo(e.end.row,e.end.column);else if(this.lead.column==this.doc.getLine(this.lead.row).length)this.lead.row<this.doc.getLength()-1&&this.moveCursorTo(this.lead.row+1,0);else{var n=this.session.getTabSize();t=this.lead;this.wouldMoveIntoSoftTab(t,n,1)&&!this.session.getNavigateWithinSoftTabs()?this.moveCursorBy(0,n):this.moveCursorBy(0,1)}},this.moveCursorLineStart=function(){var e=this.lead.row,t=this.lead.column,n=this.session.documentToScreenRow(e,t),r=this.session.screenToDocumentPosition(n,0),i=this.session.getDisplayLine(e,null,r.row,r.column),o=i.match(/^\s*/);o[0].length==t||this.session.$useEmacsStyleLineStart||(r.column+=o[0].length),this.moveCursorToPosition(r)},this.moveCursorLineEnd=function(){var e=this.lead,t=this.session.getDocumentLastRowColumnPosition(e.row,e.column);if(this.lead.column==t.column){var n=this.session.getLine(t.row);if(t.column==n.length){var r=n.search(/\s+$/);r>0&&(t.column=r)}}this.moveCursorTo(t.row,t.column)},this.moveCursorFileEnd=function(){var e=this.doc.getLength()-1,t=this.doc.getLine(e).length;this.moveCursorTo(e,t)},this.moveCursorFileStart=function(){this.moveCursorTo(0,0)},this.moveCursorLongWordRight=function(){var e=this.lead.row,t=this.lead.column,n=this.doc.getLine(e),r=n.substring(t);this.session.nonTokenRe.lastIndex=0,this.session.tokenRe.lastIndex=0;var i=this.session.getFoldAt(e,t,1);if(i)this.moveCursorTo(i.end.row,i.end.column);else{if(this.session.nonTokenRe.exec(r)&&(t+=this.session.nonTokenRe.lastIndex,this.session.nonTokenRe.lastIndex=0,r=n.substring(t)),t>=n.length)return this.moveCursorTo(e,n.length),this.moveCursorRight(),void(e<this.doc.getLength()-1&&this.moveCursorWordRight());this.session.tokenRe.exec(r)&&(t+=this.session.tokenRe.lastIndex,this.session.tokenRe.lastIndex=0),this.moveCursorTo(e,t)}},this.moveCursorLongWordLeft=function(){var e,t=this.lead.row,n=this.lead.column;if(e=this.session.getFoldAt(t,n,-1))this.moveCursorTo(e.start.row,e.start.column);else{var r=this.session.getFoldStringAt(t,n,-1);null==r&&(r=this.doc.getLine(t).substring(0,n));var o=i.stringReverse(r);if(this.session.nonTokenRe.lastIndex=0,this.session.tokenRe.lastIndex=0,this.session.nonTokenRe.exec(o)&&(n-=this.session.nonTokenRe.lastIndex,o=o.slice(this.session.nonTokenRe.lastIndex),this.session.nonTokenRe.lastIndex=0),n<=0)return this.moveCursorTo(t,0),this.moveCursorLeft(),void(t>0&&this.moveCursorWordLeft());this.session.tokenRe.exec(o)&&(n-=this.session.tokenRe.lastIndex,this.session.tokenRe.lastIndex=0),this.moveCursorTo(t,n)}},this.$shortWordEndIndex=function(e){var t,n=0,r=/\s/,i=this.session.tokenRe;if(i.lastIndex=0,this.session.tokenRe.exec(e))n=this.session.tokenRe.lastIndex;else{while((t=e[n])&&r.test(t))n++;if(n<1){i.lastIndex=0;while((t=e[n])&&!i.test(t))if(i.lastIndex=0,n++,r.test(t)){if(n>2){n--;break}while((t=e[n])&&r.test(t))n++;if(n>2)break}}}return i.lastIndex=0,n},this.moveCursorShortWordRight=function(){var e=this.lead.row,t=this.lead.column,n=this.doc.getLine(e),r=n.substring(t),i=this.session.getFoldAt(e,t,1);if(i)return this.moveCursorTo(i.end.row,i.end.column);if(t==n.length){var o=this.doc.getLength();do{e++,r=this.doc.getLine(e)}while(e<o&&/^\s*$/.test(r));/^\s+/.test(r)||(r=""),t=0}var s=this.$shortWordEndIndex(r);this.moveCursorTo(e,t+s)},this.moveCursorShortWordLeft=function(){var e,t=this.lead.row,n=this.lead.column;if(e=this.session.getFoldAt(t,n,-1))return this.moveCursorTo(e.start.row,e.start.column);var r=this.session.getLine(t).substring(0,n);if(0===n){do{t--,r=this.doc.getLine(t)}while(t>0&&/^\s*$/.test(r));n=r.length,/\s+$/.test(r)||(r="")}var o=i.stringReverse(r),s=this.$shortWordEndIndex(o);return this.moveCursorTo(t,n-s)},this.moveCursorWordRight=function(){this.session.$selectLongWords?this.moveCursorLongWordRight():this.moveCursorShortWordRight()},this.moveCursorWordLeft=function(){this.session.$selectLongWords?this.moveCursorLongWordLeft():this.moveCursorShortWordLeft()},this.moveCursorBy=function(e,t){var n,r=this.session.documentToScreenPosition(this.lead.row,this.lead.column);if(0===t&&(0!==e&&(this.session.$bidiHandler.isBidiRow(r.row,this.lead.row)?(n=this.session.$bidiHandler.getPosLeft(r.column),r.column=Math.round(n/this.session.$bidiHandler.charWidths[0])):n=r.column*this.session.$bidiHandler.charWidths[0]),this.$desiredColumn?r.column=this.$desiredColumn:this.$desiredColumn=r.column),0!=e&&this.session.lineWidgets&&this.session.lineWidgets[this.lead.row]){var i=this.session.lineWidgets[this.lead.row];e<0?e-=i.rowsAbove||0:e>0&&(e+=i.rowCount-(i.rowsAbove||0))}var o=this.session.screenToDocumentPosition(r.row+e,r.column,n);0!==e&&0===t&&o.row===this.lead.row&&(o.column,this.lead.column),this.moveCursorTo(o.row,o.column+t,0===t)},this.moveCursorToPosition=function(e){this.moveCursorTo(e.row,e.column)},this.moveCursorTo=function(e,t,n){var r=this.session.getFoldAt(e,t,1);r&&(e=r.start.row,t=r.start.column),this.$keepDesiredColumnOnChange=!0;var i=this.session.getLine(e);/[\uDC00-\uDFFF]/.test(i.charAt(t))&&i.charAt(t-1)&&(this.lead.row==e&&this.lead.column==t+1?t-=1:t+=1),this.lead.setPosition(e,t),this.$keepDesiredColumnOnChange=!1,n||(this.$desiredColumn=null)},this.moveCursorToScreen=function(e,t,n){var r=this.session.screenToDocumentPosition(e,t);this.moveCursorTo(r.row,r.column,n)},this.detach=function(){this.lead.detach(),this.anchor.detach()},this.fromOrientedRange=function(e){this.setSelectionRange(e,e.cursor==e.start),this.$desiredColumn=e.desiredColumn||this.$desiredColumn},this.toOrientedRange=function(e){var t=this.getRange();return e?(e.start.column=t.start.column,e.start.row=t.start.row,e.end.column=t.end.column,e.end.row=t.end.row):e=t,e.cursor=this.isBackwards()?e.start:e.end,e.desiredColumn=this.$desiredColumn,e},this.getRangeOfMovements=function(e){var t=this.getCursor();try{e(this);var n=this.getCursor();return s.fromPoints(t,n)}catch(r){return s.fromPoints(t,t)}finally{this.moveCursorToPosition(t)}},this.toJSON=function(){if(this.rangeCount)var e=this.ranges.map((function(e){var t=e.clone();return t.isBackwards=e.cursor==e.start,t}));else{e=this.getRange();e.isBackwards=this.isBackwards()}return e},this.fromJSON=function(e){if(void 0==e.start){if(this.rangeList&&e.length>1){this.toSingleRange(e[0]);for(var t=e.length;t--;){var n=s.fromPoints(e[t].start,e[t].end);e[t].isBackwards&&(n.cursor=n.start),this.addRange(n,!0)}return}e=e[0]}this.rangeList&&this.toSingleRange(e),this.setSelectionRange(e,e.isBackwards)},this.isEqual=function(e){if((e.length||this.rangeCount)&&e.length!=this.rangeCount)return!1;if(!e.length||!this.ranges)return this.getRange().isEqual(e);for(var t=this.ranges.length;t--;)if(!this.ranges[t].isEqual(e[t]))return!1;return!0}}).call(a.prototype),t.Selection=a})),ace.define("ace/tokenizer",["require","exports","module","ace/config"],(function(e,t,n){"use strict";var r=e("./config"),i=2e3,o=function(){function e(e){for(var t in this.states=e,this.regExps={},this.matchMappings={},this.states){for(var n=this.states[t],r=[],i=0,o=this.matchMappings[t]={defaultToken:"text"},s="g",a=[],l=0;l<n.length;l++){var c=n[l];if(c.defaultToken&&(o.defaultToken=c.defaultToken),c.caseInsensitive&&-1===s.indexOf("i")&&(s+="i"),c.unicode&&-1===s.indexOf("u")&&(s+="u"),null!=c.regex){c.regex instanceof RegExp&&(c.regex=c.regex.toString().slice(1,-1));var u=c.regex,h=new RegExp("(?:("+u+")|(.))").exec("a").length-2;Array.isArray(c.token)?1==c.token.length||1==h?c.token=c.token[0]:h-1!=c.token.length?(this.reportError("number of classes and regexp groups doesn't match",{rule:c,groupCount:h-1}),c.token=c.token[0]):(c.tokenArray=c.token,c.token=null,c.onMatch=this.$arrayTokens):"function"!=typeof c.token||c.onMatch||(c.onMatch=h>1?this.$applyToken:c.token),h>1&&(/\\\d/.test(c.regex)?u=c.regex.replace(/\\([0-9]+)/g,(function(e,t){return"\\"+(parseInt(t,10)+i+1)})):(h=1,u=this.removeCapturingGroups(c.regex)),c.splitRegex||"string"==typeof c.token||a.push(c)),o[i]=l,i+=h,r.push(u),c.onMatch||(c.onMatch=null)}}r.length||(o[0]=0,r.push("$")),a.forEach((function(e){e.splitRegex=this.createSplitterRegexp(e.regex,s)}),this),this.regExps[t]=new RegExp("("+r.join(")|(")+")|($)",s)}}return e.prototype.$setMaxTokenCount=function(e){i=0|e},e.prototype.$applyToken=function(e){var t=this.splitRegex.exec(e).slice(1),n=this.token.apply(this,t);if("string"===typeof n)return[{type:n,value:e}];for(var r=[],i=0,o=n.length;i<o;i++)t[i]&&(r[r.length]={type:n[i],value:t[i]});return r},e.prototype.$arrayTokens=function(e){if(!e)return[];var t=this.splitRegex.exec(e);if(!t)return"text";for(var n=[],r=this.tokenArray,i=0,o=r.length;i<o;i++)t[i+1]&&(n[n.length]={type:r[i],value:t[i+1]});return n},e.prototype.removeCapturingGroups=function(e){var t=e.replace(/\\.|\[(?:\\.|[^\\\]])*|\(\?[:=!<]|(\()/g,(function(e,t){return t?"(?:":e}));return t},e.prototype.createSplitterRegexp=function(e,t){if(-1!=e.indexOf("(?=")){var n=0,r=!1,i={};e.replace(/(\\.)|(\((?:\?[=!])?)|(\))|([\[\]])/g,(function(e,t,o,s,a,l){return r?r="]"!=a:a?r=!0:s?(n==i.stack&&(i.end=l+1,i.stack=-1),n--):o&&(n++,1!=o.length&&(i.stack=n,i.start=l)),e})),null!=i.end&&/^\)*$/.test(e.substr(i.end))&&(e=e.substring(0,i.start)+e.substr(i.end))}return"^"!=e.charAt(0)&&(e="^"+e),"$"!=e.charAt(e.length-1)&&(e+="$"),new RegExp(e,(t||"").replace("g",""))},e.prototype.getLineTokens=function(e,t){if(t&&"string"!=typeof t){var n=t.slice(0);t=n[0],"#tmp"===t&&(n.shift(),t=n.shift())}else n=[];var r=t||"start",o=this.states[r];o||(r="start",o=this.states[r]);var s=this.matchMappings[r],a=this.regExps[r];a.lastIndex=0;var l,c=[],u=0,h=0,f={type:null,value:""};while(l=a.exec(e)){var d=s.defaultToken,p=null,g=l[0],m=a.lastIndex;if(m-g.length>u){var v=e.substring(u,m-g.length);f.type==d?f.value+=v:(f.type&&c.push(f),f={type:d,value:v})}for(var y=0;y<l.length-2;y++)if(void 0!==l[y+1]){p=o[s[y]],d=p.onMatch?p.onMatch(g,r,n,e):p.token,p.next&&(r="string"==typeof p.next?p.next:p.next(r,n),o=this.states[r],o||(this.reportError("state doesn't exist",r),r="start",o=this.states[r]),s=this.matchMappings[r],u=m,a=this.regExps[r],a.lastIndex=m),p.consumeLineEnd&&(u=m);break}if(g)if("string"===typeof d)p&&!1===p.merge||f.type!==d?(f.type&&c.push(f),f={type:d,value:g}):f.value+=g;else if(d){f.type&&c.push(f),f={type:null,value:""};for(y=0;y<d.length;y++)c.push(d[y])}if(u==e.length)break;if(u=m,h++>i){h>2*e.length&&this.reportError("infinite loop with in ace tokenizer",{startState:t,line:e});while(u<e.length)f.type&&c.push(f),f={value:e.substring(u,u+=500),type:"overflow"};r="start",n=[];break}}return f.type&&c.push(f),n.length>1&&n[0]!==r&&n.unshift("#tmp",r),{tokens:c,state:n.length?n:r}},e}();o.prototype.reportError=r.reportError,t.Tokenizer=o})),ace.define("ace/mode/text_highlight_rules",["require","exports","module","ace/lib/lang"],(function(e,t,n){"use strict";var r=e("../lib/lang"),i=function(){this.$rules={start:[{token:"empty_line",regex:"^$"},{defaultToken:"text"}]}};(function(){this.addRules=function(e,t){if(t)for(var n in e){for(var r=e[n],i=0;i<r.length;i++){var o=r[i];(o.next||o.onMatch)&&("string"==typeof o.next&&0!==o.next.indexOf(t)&&(o.next=t+o.next),o.nextState&&0!==o.nextState.indexOf(t)&&(o.nextState=t+o.nextState))}this.$rules[t+n]=r}else for(var n in e)this.$rules[n]=e[n]},this.getRules=function(){return this.$rules},this.embedRules=function(e,t,n,i,o){var s="function"==typeof e?(new e).getRules():e;if(i)for(var a=0;a<i.length;a++)i[a]=t+i[a];else for(var l in i=[],s)i.push(t+l);if(this.addRules(s,t),n){var c=Array.prototype[o?"push":"unshift"];for(a=0;a<i.length;a++)c.apply(this.$rules[i[a]],r.deepCopy(n))}this.$embeds||(this.$embeds=[]),this.$embeds.push(t)},this.getEmbeds=function(){return this.$embeds};var e=function(e,t){return("start"!=e||t.length)&&t.unshift(this.nextState,e),this.nextState},t=function(e,t){return t.shift(),t.shift()||"start"};this.normalizeRules=function(){var n=0,r=this.$rules;function i(o){var s=r[o];s.processed=!0;for(var a=0;a<s.length;a++){var l=s[a],c=null;Array.isArray(l)&&(c=l,l={}),!l.regex&&l.start&&(l.regex=l.start,l.next||(l.next=[]),l.next.push({defaultToken:l.token},{token:l.token+".end",regex:l.end||l.start,next:"pop"}),l.token=l.token+".start",l.push=!0);var u=l.next||l.push;if(u&&Array.isArray(u)){var h=l.stateName;h||(h=l.token,"string"!=typeof h&&(h=h[0]||""),r[h]&&(h+=n++)),r[h]=u,l.next=h,i(h)}else"pop"==u&&(l.next=t);if(l.push&&(l.nextState=l.next||l.push,l.next=e,delete l.push),l.rules)for(var f in l.rules)r[f]?r[f].push&&r[f].push.apply(r[f],l.rules[f]):r[f]=l.rules[f];var d="string"==typeof l?l:l.include;if(d&&("$self"===d&&(d="start"),c=Array.isArray(d)?d.map((function(e){return r[e]})):r[d]),c){var p=[a,1].concat(c);l.noEscape&&(p=p.filter((function(e){return!e.next}))),s.splice.apply(s,p),a--}l.keywordMap&&(l.token=this.createKeywordMapper(l.keywordMap,l.defaultToken||"text",l.caseInsensitive),delete l.defaultToken)}}Object.keys(r).forEach(i,this)},this.createKeywordMapper=function(e,t,n,r){var i=Object.create(null);return this.$keywordList=[],Object.keys(e).forEach((function(t){for(var o=e[t],s=o.split(r||"|"),a=s.length;a--;){var l=s[a];this.$keywordList.push(l),n&&(l=l.toLowerCase()),i[l]=t}}),this),e=null,n?function(e){return i[e.toLowerCase()]||t}:function(e){return i[e]||t}},this.getKeywords=function(){return this.$keywords}}).call(i.prototype),t.TextHighlightRules=i})),ace.define("ace/mode/behaviour",["require","exports","module"],(function(e,t,n){"use strict";var r=function(){this.$behaviours={}};(function(){this.add=function(e,t,n){switch(void 0){case this.$behaviours:this.$behaviours={};case this.$behaviours[e]:this.$behaviours[e]={}}this.$behaviours[e][t]=n},this.addBehaviours=function(e){for(var t in e)for(var n in e[t])this.add(t,n,e[t][n])},this.remove=function(e){this.$behaviours&&this.$behaviours[e]&&delete this.$behaviours[e]},this.inherit=function(e,t){if("function"===typeof e)var n=(new e).getBehaviours(t);else n=e.getBehaviours(t);this.addBehaviours(n)},this.getBehaviours=function(e){if(e){for(var t={},n=0;n<e.length;n++)this.$behaviours[e[n]]&&(t[e[n]]=this.$behaviours[e[n]]);return t}return this.$behaviours}}).call(r.prototype),t.Behaviour=r})),ace.define("ace/token_iterator",["require","exports","module","ace/range"],(function(e,t,n){"use strict";var r=e("./range").Range,i=function(){function e(e,t,n){this.$session=e,this.$row=t,this.$rowTokens=e.getTokens(t);var r=e.getTokenAt(t,n);this.$tokenIndex=r?r.index:-1}return e.prototype.stepBackward=function(){this.$tokenIndex-=1;while(this.$tokenIndex<0){if(this.$row-=1,this.$row<0)return this.$row=0,null;this.$rowTokens=this.$session.getTokens(this.$row),this.$tokenIndex=this.$rowTokens.length-1}return this.$rowTokens[this.$tokenIndex]},e.prototype.stepForward=function(){var e;this.$tokenIndex+=1;while(this.$tokenIndex>=this.$rowTokens.length){if(this.$row+=1,e||(e=this.$session.getLength()),this.$row>=e)return this.$row=e-1,null;this.$rowTokens=this.$session.getTokens(this.$row),this.$tokenIndex=0}return this.$rowTokens[this.$tokenIndex]},e.prototype.getCurrentToken=function(){return this.$rowTokens[this.$tokenIndex]},e.prototype.getCurrentTokenRow=function(){return this.$row},e.prototype.getCurrentTokenColumn=function(){var e=this.$rowTokens,t=this.$tokenIndex,n=e[t].start;if(void 0!==n)return n;n=0;while(t>0)t-=1,n+=e[t].value.length;return n},e.prototype.getCurrentTokenPosition=function(){return{row:this.$row,column:this.getCurrentTokenColumn()}},e.prototype.getCurrentTokenRange=function(){var e=this.$rowTokens[this.$tokenIndex],t=this.getCurrentTokenColumn();return new r(this.$row,t,this.$row,t+e.value.length)},e}();t.TokenIterator=i})),ace.define("ace/mode/behaviour/cstyle",["require","exports","module","ace/lib/oop","ace/mode/behaviour","ace/token_iterator","ace/lib/lang"],(function(e,t,n){"use strict";var r,i=e("../../lib/oop"),o=e("../behaviour").Behaviour,s=e("../../token_iterator").TokenIterator,a=e("../../lib/lang"),l=["text","paren.rparen","rparen","paren","punctuation.operator"],c=["text","paren.rparen","rparen","paren","punctuation.operator","comment"],u={},h={'"':'"',"'":"'"},f=function(e){var t=-1;if(e.multiSelect&&(t=e.selection.index,u.rangeCount!=e.multiSelect.rangeCount&&(u={rangeCount:e.multiSelect.rangeCount})),u[t])return r=u[t];r=u[t]={autoInsertedBrackets:0,autoInsertedRow:-1,autoInsertedLineEnd:"",maybeInsertedBrackets:0,maybeInsertedRow:-1,maybeInsertedLineStart:"",maybeInsertedLineEnd:""}},d=function(e,t,n,r){var i=e.end.row-e.start.row;return{text:n+t+r,selection:[0,e.start.column+1,i,e.end.column+(i?0:1)]}},p=function(e){this.add("braces","insertion",(function(t,n,i,o,s){var l=i.getCursorPosition(),c=o.doc.getLine(l.row);if("{"==s){f(i);var u=i.getSelectionRange(),h=o.doc.getTextRange(u);if(""!==h&&"{"!==h&&i.getWrapBehavioursEnabled())return d(u,h,"{","}");if(p.isSaneInsertion(i,o))return/[\]\}\)]/.test(c[l.column])||i.inMultiSelectMode||e&&e.braces?(p.recordAutoInsert(i,o,"}"),{text:"{}",selection:[1,1]}):(p.recordMaybeInsert(i,o,"{"),{text:"{",selection:[1,1]})}else if("}"==s){f(i);var g=c.substring(l.column,l.column+1);if("}"==g){var m=o.$findOpeningBracket("}",{column:l.column+1,row:l.row});if(null!==m&&p.isAutoInsertedClosing(l,c,s))return p.popAutoInsertedClosing(),{text:"",selection:[1,1]}}}else{if("\n"==s||"\r\n"==s){f(i);var v="";p.isMaybeInsertedClosing(l,c)&&(v=a.stringRepeat("}",r.maybeInsertedBrackets),p.clearMaybeInsertedClosing());g=c.substring(l.column,l.column+1);if("}"===g){var y=o.findMatchingBracket({row:l.row,column:l.column+1},"}");if(!y)return null;var w=this.$getIndent(o.getLine(y.row))}else{if(!v)return void p.clearMaybeInsertedClosing();w=this.$getIndent(c)}var b=w+o.getTabString();return{text:"\n"+b+"\n"+w+v,selection:[1,b.length,1,b.length]}}p.clearMaybeInsertedClosing()}})),this.add("braces","deletion",(function(e,t,n,i,o){var s=i.doc.getTextRange(o);if(!o.isMultiLine()&&"{"==s){f(n);var a=i.doc.getLine(o.start.row),l=a.substring(o.end.column,o.end.column+1);if("}"==l)return o.end.column++,o;r.maybeInsertedBrackets--}})),this.add("parens","insertion",(function(e,t,n,r,i){if("("==i){f(n);var o=n.getSelectionRange(),s=r.doc.getTextRange(o);if(""!==s&&n.getWrapBehavioursEnabled())return d(o,s,"(",")");if(p.isSaneInsertion(n,r))return p.recordAutoInsert(n,r,")"),{text:"()",selection:[1,1]}}else if(")"==i){f(n);var a=n.getCursorPosition(),l=r.doc.getLine(a.row),c=l.substring(a.column,a.column+1);if(")"==c){var u=r.$findOpeningBracket(")",{column:a.column+1,row:a.row});if(null!==u&&p.isAutoInsertedClosing(a,l,i))return p.popAutoInsertedClosing(),{text:"",selection:[1,1]}}}})),this.add("parens","deletion",(function(e,t,n,r,i){var o=r.doc.getTextRange(i);if(!i.isMultiLine()&&"("==o){f(n);var s=r.doc.getLine(i.start.row),a=s.substring(i.start.column+1,i.start.column+2);if(")"==a)return i.end.column++,i}})),this.add("brackets","insertion",(function(e,t,n,r,i){if("["==i){f(n);var o=n.getSelectionRange(),s=r.doc.getTextRange(o);if(""!==s&&n.getWrapBehavioursEnabled())return d(o,s,"[","]");if(p.isSaneInsertion(n,r))return p.recordAutoInsert(n,r,"]"),{text:"[]",selection:[1,1]}}else if("]"==i){f(n);var a=n.getCursorPosition(),l=r.doc.getLine(a.row),c=l.substring(a.column,a.column+1);if("]"==c){var u=r.$findOpeningBracket("]",{column:a.column+1,row:a.row});if(null!==u&&p.isAutoInsertedClosing(a,l,i))return p.popAutoInsertedClosing(),{text:"",selection:[1,1]}}}})),this.add("brackets","deletion",(function(e,t,n,r,i){var o=r.doc.getTextRange(i);if(!i.isMultiLine()&&"["==o){f(n);var s=r.doc.getLine(i.start.row),a=s.substring(i.start.column+1,i.start.column+2);if("]"==a)return i.end.column++,i}})),this.add("string_dquotes","insertion",(function(e,t,n,r,i){var o=r.$mode.$quotes||h;if(1==i.length&&o[i]){if(this.lineCommentStart&&-1!=this.lineCommentStart.indexOf(i))return;f(n);var s=i,a=n.getSelectionRange(),l=r.doc.getTextRange(a);if(!(""===l||1==l.length&&o[l])&&n.getWrapBehavioursEnabled())return d(a,l,s,s);if(!l){var c=n.getCursorPosition(),u=r.doc.getLine(c.row),p=u.substring(c.column-1,c.column),g=u.substring(c.column,c.column+1),m=r.getTokenAt(c.row,c.column),v=r.getTokenAt(c.row,c.column+1);if("\\"==p&&m&&/escape/.test(m.type))return null;var y,w=m&&/string|escape/.test(m.type),b=!v||/string|escape/.test(v.type);if(g==s)y=w!==b,y&&/string\.end/.test(v.type)&&(y=!1);else{if(w&&!b)return null;if(w&&b)return null;var x=r.$mode.tokenRe;x.lastIndex=0;var S=x.test(p);x.lastIndex=0;var _=x.test(g),k=r.$mode.$pairQuotesAfter,C=k&&k[s]&&k[s].test(p);if(!C&&S||_)return null;if(g&&!/[\s;,.})\]\\]/.test(g))return null;var $=u[c.column-2];if(p==s&&($==s||x.test($)))return null;y=!0}return{text:y?s+s:"",selection:[1,1]}}}})),this.add("string_dquotes","deletion",(function(e,t,n,r,i){var o=r.$mode.$quotes||h,s=r.doc.getTextRange(i);if(!i.isMultiLine()&&o.hasOwnProperty(s)){f(n);var a=r.doc.getLine(i.start.row),l=a.substring(i.start.column+1,i.start.column+2);if(l==s)return i.end.column++,i}}))};p.isSaneInsertion=function(e,t){var n=e.getCursorPosition(),r=new s(t,n.row,n.column);if(!this.$matchTokenType(r.getCurrentToken()||"text",l)){if(/[)}\]]/.test(e.session.getLine(n.row)[n.column]))return!0;var i=new s(t,n.row,n.column+1);if(!this.$matchTokenType(i.getCurrentToken()||"text",l))return!1}return r.stepForward(),r.getCurrentTokenRow()!==n.row||this.$matchTokenType(r.getCurrentToken()||"text",c)},p.$matchTokenType=function(e,t){return t.indexOf(e.type||e)>-1},p.recordAutoInsert=function(e,t,n){var i=e.getCursorPosition(),o=t.doc.getLine(i.row);this.isAutoInsertedClosing(i,o,r.autoInsertedLineEnd[0])||(r.autoInsertedBrackets=0),r.autoInsertedRow=i.row,r.autoInsertedLineEnd=n+o.substr(i.column),r.autoInsertedBrackets++},p.recordMaybeInsert=function(e,t,n){var i=e.getCursorPosition(),o=t.doc.getLine(i.row);this.isMaybeInsertedClosing(i,o)||(r.maybeInsertedBrackets=0),r.maybeInsertedRow=i.row,r.maybeInsertedLineStart=o.substr(0,i.column)+n,r.maybeInsertedLineEnd=o.substr(i.column),r.maybeInsertedBrackets++},p.isAutoInsertedClosing=function(e,t,n){return r.autoInsertedBrackets>0&&e.row===r.autoInsertedRow&&n===r.autoInsertedLineEnd[0]&&t.substr(e.column)===r.autoInsertedLineEnd},p.isMaybeInsertedClosing=function(e,t){return r.maybeInsertedBrackets>0&&e.row===r.maybeInsertedRow&&t.substr(e.column)===r.maybeInsertedLineEnd&&t.substr(0,e.column)==r.maybeInsertedLineStart},p.popAutoInsertedClosing=function(){r.autoInsertedLineEnd=r.autoInsertedLineEnd.substr(1),r.autoInsertedBrackets--},p.clearMaybeInsertedClosing=function(){r&&(r.maybeInsertedBrackets=0,r.maybeInsertedRow=-1)},i.inherits(p,o),t.CstyleBehaviour=p})),ace.define("ace/unicode",["require","exports","module"],(function(e,t,n){"use strict";for(var r=[48,9,8,25,5,0,2,25,48,0,11,0,5,0,6,22,2,30,2,457,5,11,15,4,8,0,2,0,18,116,2,1,3,3,9,0,2,2,2,0,2,19,2,82,2,138,2,4,3,155,12,37,3,0,8,38,10,44,2,0,2,1,2,1,2,0,9,26,6,2,30,10,7,61,2,9,5,101,2,7,3,9,2,18,3,0,17,58,3,100,15,53,5,0,6,45,211,57,3,18,2,5,3,11,3,9,2,1,7,6,2,2,2,7,3,1,3,21,2,6,2,0,4,3,3,8,3,1,3,3,9,0,5,1,2,4,3,11,16,2,2,5,5,1,3,21,2,6,2,1,2,1,2,1,3,0,2,4,5,1,3,2,4,0,8,3,2,0,8,15,12,2,2,8,2,2,2,21,2,6,2,1,2,4,3,9,2,2,2,2,3,0,16,3,3,9,18,2,2,7,3,1,3,21,2,6,2,1,2,4,3,8,3,1,3,2,9,1,5,1,2,4,3,9,2,0,17,1,2,5,4,2,2,3,4,1,2,0,2,1,4,1,4,2,4,11,5,4,4,2,2,3,3,0,7,0,15,9,18,2,2,7,2,2,2,22,2,9,2,4,4,7,2,2,2,3,8,1,2,1,7,3,3,9,19,1,2,7,2,2,2,22,2,9,2,4,3,8,2,2,2,3,8,1,8,0,2,3,3,9,19,1,2,7,2,2,2,22,2,15,4,7,2,2,2,3,10,0,9,3,3,9,11,5,3,1,2,17,4,23,2,8,2,0,3,6,4,0,5,5,2,0,2,7,19,1,14,57,6,14,2,9,40,1,2,0,3,1,2,0,3,0,7,3,2,6,2,2,2,0,2,0,3,1,2,12,2,2,3,4,2,0,2,5,3,9,3,1,35,0,24,1,7,9,12,0,2,0,2,0,5,9,2,35,5,19,2,5,5,7,2,35,10,0,58,73,7,77,3,37,11,42,2,0,4,328,2,3,3,6,2,0,2,3,3,40,2,3,3,32,2,3,3,6,2,0,2,3,3,14,2,56,2,3,3,66,5,0,33,15,17,84,13,619,3,16,2,25,6,74,22,12,2,6,12,20,12,19,13,12,2,2,2,1,13,51,3,29,4,0,5,1,3,9,34,2,3,9,7,87,9,42,6,69,11,28,4,11,5,11,11,39,3,4,12,43,5,25,7,10,38,27,5,62,2,28,3,10,7,9,14,0,89,75,5,9,18,8,13,42,4,11,71,55,9,9,4,48,83,2,2,30,14,230,23,280,3,5,3,37,3,5,3,7,2,0,2,0,2,0,2,30,3,52,2,6,2,0,4,2,2,6,4,3,3,5,5,12,6,2,2,6,67,1,20,0,29,0,14,0,17,4,60,12,5,0,4,11,18,0,5,0,3,9,2,0,4,4,7,0,2,0,2,0,2,3,2,10,3,3,6,4,5,0,53,1,2684,46,2,46,2,132,7,6,15,37,11,53,10,0,17,22,10,6,2,6,2,6,2,6,2,6,2,6,2,6,2,6,2,31,48,0,470,1,36,5,2,4,6,1,5,85,3,1,3,2,2,89,2,3,6,40,4,93,18,23,57,15,513,6581,75,20939,53,1164,68,45,3,268,4,27,21,31,3,13,13,1,2,24,9,69,11,1,38,8,3,102,3,1,111,44,25,51,13,68,12,9,7,23,4,0,5,45,3,35,13,28,4,64,15,10,39,54,10,13,3,9,7,22,4,1,5,66,25,2,227,42,2,1,3,9,7,11171,13,22,5,48,8453,301,3,61,3,105,39,6,13,4,6,11,2,12,2,4,2,0,2,1,2,1,2,107,34,362,19,63,3,53,41,11,5,15,17,6,13,1,25,2,33,4,2,134,20,9,8,25,5,0,2,25,12,88,4,5,3,5,3,5,3,2],i=0,o=[],s=0;s<r.length;s+=2)o.push(i+=r[s]),r[s+1]&&o.push(45,i+=r[s+1]);t.wordChars=String.fromCharCode.apply(null,o)})),ace.define("ace/mode/text",["require","exports","module","ace/config","ace/tokenizer","ace/mode/text_highlight_rules","ace/mode/behaviour/cstyle","ace/unicode","ace/lib/lang","ace/token_iterator","ace/range"],(function(e,t,n){"use strict";var r=e("../config"),i=e("../tokenizer").Tokenizer,o=e("./text_highlight_rules").TextHighlightRules,s=e("./behaviour/cstyle").CstyleBehaviour,a=e("../unicode"),l=e("../lib/lang"),c=e("../token_iterator").TokenIterator,u=e("../range").Range,h=function(){this.HighlightRules=o};(function(){this.$defaultBehaviour=new s,this.tokenRe=new RegExp("^["+a.wordChars+"\\$_]+","g"),this.nonTokenRe=new RegExp("^(?:[^"+a.wordChars+"\\$_]|\\s])+","g"),this.getTokenizer=function(){return this.$tokenizer||(this.$highlightRules=this.$highlightRules||new this.HighlightRules(this.$highlightRuleConfig),this.$tokenizer=new i(this.$highlightRules.getRules())),this.$tokenizer},this.lineCommentStart="",this.blockComment="",this.toggleCommentLines=function(e,t,n,r){var i=t.doc,o=!0,s=!0,a=1/0,c=t.getTabSize(),u=!1;if(this.lineCommentStart){if(Array.isArray(this.lineCommentStart))g=this.lineCommentStart.map(l.escapeRegExp).join("|"),d=this.lineCommentStart[0];else g=l.escapeRegExp(this.lineCommentStart),d=this.lineCommentStart;g=new RegExp("^(\\s*)(?:"+g+") ?"),u=t.getUseSoftTabs();y=function(e,t){var n=e.match(g);if(n){var r=n[1].length,o=n[0].length;f(e,r,o)||" "!=n[0][o-1]||o--,i.removeInLine(t,r,o)}};var h=d+" ",f=(v=function(e,t){o&&!/\S/.test(e)||(f(e,a,a)?i.insertInLine({row:t,column:a},h):i.insertInLine({row:t,column:a},d))},w=function(e,t){return g.test(e)},function(e,t,n){var r=0;while(t--&&" "==e.charAt(t))r++;if(r%c!=0)return!1;r=0;while(" "==e.charAt(n++))r++;return c>2?r%c!=c-1:r%c==0})}else{if(!this.blockComment)return!1;var d=this.blockComment.start,p=this.blockComment.end,g=new RegExp("^(\\s*)(?:"+l.escapeRegExp(d)+")"),m=new RegExp("(?:"+l.escapeRegExp(p)+")\\s*$"),v=function(e,t){w(e,t)||o&&!/\S/.test(e)||(i.insertInLine({row:t,column:e.length},p),i.insertInLine({row:t,column:a},d))},y=function(e,t){var n;(n=e.match(m))&&i.removeInLine(t,e.length-n[0].length,e.length),(n=e.match(g))&&i.removeInLine(t,n[1].length,n[0].length)},w=function(e,n){if(g.test(e))return!0;for(var r=t.getTokens(n),i=0;i<r.length;i++)if("comment"===r[i].type)return!0}}function b(e){for(var t=n;t<=r;t++)e(i.getLine(t),t)}var x=1/0;b((function(e,t){var n=e.search(/\S/);-1!==n?(n<a&&(a=n),s&&!w(e,t)&&(s=!1)):x>e.length&&(x=e.length)})),a==1/0&&(a=x,o=!1,s=!1),u&&a%c!=0&&(a=Math.floor(a/c)*c),b(s?y:v)},this.toggleBlockComment=function(e,t,n,r){var i=this.blockComment;if(i){!i.start&&i[0]&&(i=i[0]);var o,s,a=new c(t,r.row,r.column),l=a.getCurrentToken(),h=(t.selection,t.selection.toOrientedRange());if(l&&/comment/.test(l.type)){var f,d;while(l&&/comment/.test(l.type)){var p=l.value.indexOf(i.start);if(-1!=p){var g=a.getCurrentTokenRow(),m=a.getCurrentTokenColumn()+p;f=new u(g,m,g,m+i.start.length);break}l=a.stepBackward()}a=new c(t,r.row,r.column),l=a.getCurrentToken();while(l&&/comment/.test(l.type)){p=l.value.indexOf(i.end);if(-1!=p){g=a.getCurrentTokenRow(),m=a.getCurrentTokenColumn()+p;d=new u(g,m,g,m+i.end.length);break}l=a.stepForward()}d&&t.remove(d),f&&(t.remove(f),o=f.start.row,s=-i.start.length)}else s=i.start.length,o=n.start.row,t.insert(n.end,i.end),t.insert(n.start,i.start);h.start.row==o&&(h.start.column+=s),h.end.row==o&&(h.end.column+=s),t.selection.fromOrientedRange(h)}},this.getNextLineIndent=function(e,t,n){return this.$getIndent(t)},this.checkOutdent=function(e,t,n){return!1},this.autoOutdent=function(e,t,n){},this.$getIndent=function(e){return e.match(/^\s*/)[0]},this.createWorker=function(e){return null},this.createModeDelegates=function(e){for(var t in this.$embeds=[],this.$modes={},e)if(e[t]){var n=e[t],i=n.prototype.$id,o=r.$modes[i];o||(r.$modes[i]=o=new n),r.$modes[t]||(r.$modes[t]=o),this.$embeds.push(t),this.$modes[t]=o}var s=["toggleBlockComment","toggleCommentLines","getNextLineIndent","checkOutdent","autoOutdent","transformAction","getCompletions"];for(t=0;t<s.length;t++)(function(e){var n=s[t],r=e[n];e[s[t]]=function(){return this.$delegator(n,arguments,r)}})(this)},this.$delegator=function(e,t,n){var r=t[0]||"start";if("string"!=typeof r){if(Array.isArray(r[2])){var i=r[2][r[2].length-1],o=this.$modes[i];if(o)return o[e].apply(o,[r[1]].concat([].slice.call(t,1)))}r=r[0]||"start"}for(var s=0;s<this.$embeds.length;s++)if(this.$modes[this.$embeds[s]]){var a=r.split(this.$embeds[s]);if(!a[0]&&a[1]){t[0]=a[1];o=this.$modes[this.$embeds[s]];return o[e].apply(o,t)}}var l=n.apply(this,t);return n?l:void 0},this.transformAction=function(e,t,n,r,i){if(this.$behaviour){var o=this.$behaviour.getBehaviours();for(var s in o)if(o[s][t]){var a=o[s][t].apply(this,arguments);if(a)return a}}},this.getKeywords=function(e){if(!this.completionKeywords){var t=this.$tokenizer.rules,n=[];for(var r in t)for(var i=t[r],o=0,s=i.length;o<s;o++)if("string"===typeof i[o].token)/keyword|support|storage/.test(i[o].token)&&n.push(i[o].regex);else if("object"===typeof i[o].token)for(var a=0,l=i[o].token.length;a<l;a++)if(/keyword|support|storage/.test(i[o].token[a])){r=i[o].regex.match(/\(.+?\)/g)[a];n.push(r.substr(1,r.length-2))}this.completionKeywords=n}return e?n.concat(this.$keywordList||[]):this.$keywordList},this.$createKeywordList=function(){return this.$highlightRules||this.getTokenizer(),this.$keywordList=this.$highlightRules.$keywordList||[]},this.getCompletions=function(e,t,n,r){var i=this.$keywordList||this.$createKeywordList();return i.map((function(e){return{name:e,value:e,score:0,meta:"keyword"}}))},this.$id="ace/mode/text"}).call(h.prototype),t.Mode=h})),ace.define("ace/apply_delta",["require","exports","module"],(function(e,t,n){"use strict";t.applyDelta=function(e,t,n){var r=t.start.row,i=t.start.column,o=e[r]||"";switch(t.action){case"insert":var s=t.lines;if(1===s.length)e[r]=o.substring(0,i)+t.lines[0]+o.substring(i);else{var a=[r,1].concat(t.lines);e.splice.apply(e,a),e[r]=o.substring(0,i)+e[r],e[r+t.lines.length-1]+=o.substring(i)}break;case"remove":var l=t.end.column,c=t.end.row;r===c?e[r]=o.substring(0,i)+o.substring(l):e.splice(r,c-r+1,o.substring(0,i)+e[c].substring(l));break}}})),ace.define("ace/anchor",["require","exports","module","ace/lib/oop","ace/lib/event_emitter"],(function(e,t,n){"use strict";var r=e("./lib/oop"),i=e("./lib/event_emitter").EventEmitter,o=function(){function e(e,t,n){this.$onChange=this.onChange.bind(this),this.attach(e),"undefined"==typeof n?this.setPosition(t.row,t.column):this.setPosition(t,n)}return e.prototype.getPosition=function(){return this.$clipPositionToDocument(this.row,this.column)},e.prototype.getDocument=function(){return this.document},e.prototype.onChange=function(e){if((e.start.row!=e.end.row||e.start.row==this.row)&&!(e.start.row>this.row)){var t=a(e,{row:this.row,column:this.column},this.$insertRight);this.setPosition(t.row,t.column,!0)}},e.prototype.setPosition=function(e,t,n){var r;if(r=n?{row:e,column:t}:this.$clipPositionToDocument(e,t),this.row!=r.row||this.column!=r.column){var i={row:this.row,column:this.column};this.row=r.row,this.column=r.column,this._signal("change",{old:i,value:r})}},e.prototype.detach=function(){this.document.off("change",this.$onChange)},e.prototype.attach=function(e){this.document=e||this.document,this.document.on("change",this.$onChange)},e.prototype.$clipPositionToDocument=function(e,t){var n={};return e>=this.document.getLength()?(n.row=Math.max(0,this.document.getLength()-1),n.column=this.document.getLine(n.row).length):e<0?(n.row=0,n.column=0):(n.row=e,n.column=Math.min(this.document.getLine(n.row).length,Math.max(0,t))),t<0&&(n.column=0),n},e}();function s(e,t,n){var r=n?e.column<=t.column:e.column<t.column;return e.row<t.row||e.row==t.row&&r}function a(e,t,n){var r="insert"==e.action,i=(r?1:-1)*(e.end.row-e.start.row),o=(r?1:-1)*(e.end.column-e.start.column),a=e.start,l=r?a:e.end;return s(t,a,n)?{row:t.row,column:t.column}:s(l,t,!n)?{row:t.row+i,column:t.column+(t.row==l.row?o:0)}:{row:a.row,column:a.column}}o.prototype.$insertRight=!1,r.implement(o.prototype,i),t.Anchor=o})),ace.define("ace/document",["require","exports","module","ace/lib/oop","ace/apply_delta","ace/lib/event_emitter","ace/range","ace/anchor"],(function(e,t,n){"use strict";var r=e("./lib/oop"),i=e("./apply_delta").applyDelta,o=e("./lib/event_emitter").EventEmitter,s=e("./range").Range,a=e("./anchor").Anchor,l=function(){function e(e){this.$lines=[""],0===e.length?this.$lines=[""]:Array.isArray(e)?this.insertMergedLines({row:0,column:0},e):this.insert({row:0,column:0},e)}return e.prototype.setValue=function(e){var t=this.getLength()-1;this.remove(new s(0,0,t,this.getLine(t).length)),this.insert({row:0,column:0},e||"")},e.prototype.getValue=function(){return this.getAllLines().join(this.getNewLineCharacter())},e.prototype.createAnchor=function(e,t){return new a(this,e,t)},e.prototype.$detectNewLine=function(e){var t=e.match(/^.*?(\r\n|\r|\n)/m);this.$autoNewLine=t?t[1]:"\n",this._signal("changeNewLineMode")},e.prototype.getNewLineCharacter=function(){switch(this.$newLineMode){case"windows":return"\r\n";case"unix":return"\n";default:return this.$autoNewLine||"\n"}},e.prototype.setNewLineMode=function(e){this.$newLineMode!==e&&(this.$newLineMode=e,this._signal("changeNewLineMode"))},e.prototype.getNewLineMode=function(){return this.$newLineMode},e.prototype.isNewLine=function(e){return"\r\n"==e||"\r"==e||"\n"==e},e.prototype.getLine=function(e){return this.$lines[e]||""},e.prototype.getLines=function(e,t){return this.$lines.slice(e,t+1)},e.prototype.getAllLines=function(){return this.getLines(0,this.getLength())},e.prototype.getLength=function(){return this.$lines.length},e.prototype.getTextRange=function(e){return this.getLinesForRange(e).join(this.getNewLineCharacter())},e.prototype.getLinesForRange=function(e){var t;if(e.start.row===e.end.row)t=[this.getLine(e.start.row).substring(e.start.column,e.end.column)];else{t=this.getLines(e.start.row,e.end.row),t[0]=(t[0]||"").substring(e.start.column);var n=t.length-1;e.end.row-e.start.row==n&&(t[n]=t[n].substring(0,e.end.column))}return t},e.prototype.insertLines=function(e,t){return console.warn("Use of document.insertLines is deprecated. Use the insertFullLines method instead."),this.insertFullLines(e,t)},e.prototype.removeLines=function(e,t){return console.warn("Use of document.removeLines is deprecated. Use the removeFullLines method instead."),this.removeFullLines(e,t)},e.prototype.insertNewLine=function(e){return console.warn("Use of document.insertNewLine is deprecated. Use insertMergedLines(position, ['', '']) instead."),this.insertMergedLines(e,["",""])},e.prototype.insert=function(e,t){return this.getLength()<=1&&this.$detectNewLine(t),this.insertMergedLines(e,this.$split(t))},e.prototype.insertInLine=function(e,t){var n=this.clippedPos(e.row,e.column),r=this.pos(e.row,e.column+t.length);return this.applyDelta({start:n,end:r,action:"insert",lines:[t]},!0),this.clonePos(r)},e.prototype.clippedPos=function(e,t){var n=this.getLength();void 0===e?e=n:e<0?e=0:e>=n&&(e=n-1,t=void 0);var r=this.getLine(e);return void 0==t&&(t=r.length),t=Math.min(Math.max(t,0),r.length),{row:e,column:t}},e.prototype.clonePos=function(e){return{row:e.row,column:e.column}},e.prototype.pos=function(e,t){return{row:e,column:t}},e.prototype.$clipPosition=function(e){var t=this.getLength();return e.row>=t?(e.row=Math.max(0,t-1),e.column=this.getLine(t-1).length):(e.row=Math.max(0,e.row),e.column=Math.min(Math.max(e.column,0),this.getLine(e.row).length)),e},e.prototype.insertFullLines=function(e,t){e=Math.min(Math.max(e,0),this.getLength());var n=0;e<this.getLength()?(t=t.concat([""]),n=0):(t=[""].concat(t),e--,n=this.$lines[e].length),this.insertMergedLines({row:e,column:n},t)},e.prototype.insertMergedLines=function(e,t){var n=this.clippedPos(e.row,e.column),r={row:n.row+t.length-1,column:(1==t.length?n.column:0)+t[t.length-1].length};return this.applyDelta({start:n,end:r,action:"insert",lines:t}),this.clonePos(r)},e.prototype.remove=function(e){var t=this.clippedPos(e.start.row,e.start.column),n=this.clippedPos(e.end.row,e.end.column);return this.applyDelta({start:t,end:n,action:"remove",lines:this.getLinesForRange({start:t,end:n})}),this.clonePos(t)},e.prototype.removeInLine=function(e,t,n){var r=this.clippedPos(e,t),i=this.clippedPos(e,n);return this.applyDelta({start:r,end:i,action:"remove",lines:this.getLinesForRange({start:r,end:i})},!0),this.clonePos(r)},e.prototype.removeFullLines=function(e,t){e=Math.min(Math.max(0,e),this.getLength()-1),t=Math.min(Math.max(0,t),this.getLength()-1);var n=t==this.getLength()-1&&e>0,r=t<this.getLength()-1,i=n?e-1:e,o=n?this.getLine(i).length:0,a=r?t+1:t,l=r?0:this.getLine(a).length,c=new s(i,o,a,l),u=this.$lines.slice(e,t+1);return this.applyDelta({start:c.start,end:c.end,action:"remove",lines:this.getLinesForRange(c)}),u},e.prototype.removeNewLine=function(e){e<this.getLength()-1&&e>=0&&this.applyDelta({start:this.pos(e,this.getLine(e).length),end:this.pos(e+1,0),action:"remove",lines:["",""]})},e.prototype.replace=function(e,t){return e instanceof s||(e=s.fromPoints(e.start,e.end)),0===t.length&&e.isEmpty()?e.start:t==this.getTextRange(e)?e.end:(this.remove(e),n=t?this.insert(e.start,t):e.start,n);var n},e.prototype.applyDeltas=function(e){for(var t=0;t<e.length;t++)this.applyDelta(e[t])},e.prototype.revertDeltas=function(e){for(var t=e.length-1;t>=0;t--)this.revertDelta(e[t])},e.prototype.applyDelta=function(e,t){var n="insert"==e.action;(n?e.lines.length<=1&&!e.lines[0]:!s.comparePoints(e.start,e.end))||(n&&e.lines.length>2e4?this.$splitAndapplyLargeDelta(e,2e4):(i(this.$lines,e,t),this._signal("change",e)))},e.prototype.$safeApplyDelta=function(e){var t=this.$lines.length;("remove"==e.action&&e.start.row<t&&e.end.row<t||"insert"==e.action&&e.start.row<=t)&&this.applyDelta(e)},e.prototype.$splitAndapplyLargeDelta=function(e,t){for(var n=e.lines,r=n.length-t+1,i=e.start.row,o=e.start.column,s=0,a=0;s<r;s=a){a+=t-1;var l=n.slice(s,a);l.push(""),this.applyDelta({start:this.pos(i+s,o),end:this.pos(i+a,o=0),action:e.action,lines:l},!0)}e.lines=n.slice(s),e.start.row=i+s,e.start.column=o,this.applyDelta(e,!0)},e.prototype.revertDelta=function(e){this.$safeApplyDelta({start:this.clonePos(e.start),end:this.clonePos(e.end),action:"insert"==e.action?"remove":"insert",lines:e.lines.slice()})},e.prototype.indexToPosition=function(e,t){for(var n=this.$lines||this.getAllLines(),r=this.getNewLineCharacter().length,i=t||0,o=n.length;i<o;i++)if(e-=n[i].length+r,e<0)return{row:i,column:e+n[i].length+r};return{row:o-1,column:e+n[o-1].length+r}},e.prototype.positionToIndex=function(e,t){for(var n=this.$lines||this.getAllLines(),r=this.getNewLineCharacter().length,i=0,o=Math.min(e.row,n.length),s=t||0;s<o;++s)i+=n[s].length+r;return i+e.column},e}();l.prototype.$split=0==="aaa".split(/a/).length?function(e){return e.replace(/\r\n|\r/g,"\n").split("\n")}:function(e){return e.split(/\r\n|\r|\n/)},l.prototype.$autoNewLine="",l.prototype.$newLineMode="auto",r.implement(l.prototype,o),t.Document=l})),ace.define("ace/background_tokenizer",["require","exports","module","ace/lib/oop","ace/lib/event_emitter"],(function(e,t,n){"use strict";var r=e("./lib/oop"),i=e("./lib/event_emitter").EventEmitter,o=function(){function e(e,t){this.running=!1,this.lines=[],this.states=[],this.currentLine=0,this.tokenizer=e;var n=this;this.$worker=function(){if(n.running){var e=new Date,t=n.currentLine,r=-1,i=n.doc,o=t;while(n.lines[t])t++;var s=i.getLength(),a=0;n.running=!1;while(t<s){n.$tokenizeRow(t),r=t;do{t++}while(n.lines[t]);if(a++,a%5===0&&new Date-e>20){n.running=setTimeout(n.$worker,20);break}}n.currentLine=t,-1==r&&(r=t),o<=r&&n.fireUpdateEvent(o,r)}}}return e.prototype.setTokenizer=function(e){this.tokenizer=e,this.lines=[],this.states=[],this.start(0)},e.prototype.setDocument=function(e){this.doc=e,this.lines=[],this.states=[],this.stop()},e.prototype.fireUpdateEvent=function(e,t){var n={first:e,last:t};this._signal("update",{data:n})},e.prototype.start=function(e){this.currentLine=Math.min(e||0,this.currentLine,this.doc.getLength()),this.lines.splice(this.currentLine,this.lines.length),this.states.splice(this.currentLine,this.states.length),this.stop(),this.running=setTimeout(this.$worker,700)},e.prototype.scheduleStart=function(){this.running||(this.running=setTimeout(this.$worker,700))},e.prototype.$updateOnChange=function(e){var t=e.start.row,n=e.end.row-t;if(0===n)this.lines[t]=null;else if("remove"==e.action)this.lines.splice(t,n+1,null),this.states.splice(t,n+1,null);else{var r=Array(n+1);r.unshift(t,1),this.lines.splice.apply(this.lines,r),this.states.splice.apply(this.states,r)}this.currentLine=Math.min(t,this.currentLine,this.doc.getLength()),this.stop()},e.prototype.stop=function(){this.running&&clearTimeout(this.running),this.running=!1},e.prototype.getTokens=function(e){return this.lines[e]||this.$tokenizeRow(e)},e.prototype.getState=function(e){return this.currentLine==e&&this.$tokenizeRow(e),this.states[e]||"start"},e.prototype.$tokenizeRow=function(e){var t=this.doc.getLine(e),n=this.states[e-1],r=this.tokenizer.getLineTokens(t,n,e);return this.states[e]+""!==r.state+""?(this.states[e]=r.state,this.lines[e+1]=null,this.currentLine>e+1&&(this.currentLine=e+1)):this.currentLine==e&&(this.currentLine=e+1),this.lines[e]=r.tokens},e.prototype.cleanup=function(){this.running=!1,this.lines=[],this.states=[],this.currentLine=0,this.removeAllListeners()},e}();r.implement(o.prototype,i),t.BackgroundTokenizer=o})),ace.define("ace/search_highlight",["require","exports","module","ace/lib/lang","ace/range"],(function(e,t,n){"use strict";var r=e("./lib/lang"),i=e("./range").Range,o=function(){function e(e,t,n){void 0===n&&(n="text"),this.setRegexp(e),this.clazz=t,this.type=n}return e.prototype.setRegexp=function(e){this.regExp+""!=e+""&&(this.regExp=e,this.cache=[])},e.prototype.update=function(e,t,n,o){if(this.regExp)for(var s=o.firstRow,a=o.lastRow,l={},c=s;c<=a;c++){var u=this.cache[c];null==u&&(u=r.getMatchOffsets(n.getLine(c),this.regExp),u.length>this.MAX_RANGES&&(u=u.slice(0,this.MAX_RANGES)),u=u.map((function(e){return new i(c,e.offset,c,e.offset+e.length)})),this.cache[c]=u.length?u:"");for(var h=u.length;h--;){var f=u[h].toScreenRange(n),d=f.toString();l[d]||(l[d]=!0,t.drawSingleLineMarker(e,f,this.clazz,o))}}},e}();o.prototype.MAX_RANGES=500,t.SearchHighlight=o})),ace.define("ace/edit_session/fold_line",["require","exports","module","ace/range"],(function(e,t,n){"use strict";var r=e("../range").Range,i=function(){function e(e,t){this.foldData=e,Array.isArray(t)?this.folds=t:t=this.folds=[t];var n=t[t.length-1];this.range=new r(t[0].start.row,t[0].start.column,n.end.row,n.end.column),this.start=this.range.start,this.end=this.range.end,this.folds.forEach((function(e){e.setFoldLine(this)}),this)}return e.prototype.shiftRow=function(e){this.start.row+=e,this.end.row+=e,this.folds.forEach((function(t){t.start.row+=e,t.end.row+=e}))},e.prototype.addFold=function(e){if(e.sameRow){if(e.start.row<this.startRow||e.endRow>this.endRow)throw new Error("Can't add a fold to this FoldLine as it has no connection");this.folds.push(e),this.folds.sort((function(e,t){return-e.range.compareEnd(t.start.row,t.start.column)})),this.range.compareEnd(e.start.row,e.start.column)>0?(this.end.row=e.end.row,this.end.column=e.end.column):this.range.compareStart(e.end.row,e.end.column)<0&&(this.start.row=e.start.row,this.start.column=e.start.column)}else if(e.start.row==this.end.row)this.folds.push(e),this.end.row=e.end.row,this.end.column=e.end.column;else{if(e.end.row!=this.start.row)throw new Error("Trying to add fold to FoldRow that doesn't have a matching row");this.folds.unshift(e),this.start.row=e.start.row,this.start.column=e.start.column}e.foldLine=this},e.prototype.containsRow=function(e){return e>=this.start.row&&e<=this.end.row},e.prototype.walk=function(e,t,n){var r,i,o,s=0,a=this.folds,l=!0;null==t&&(t=this.end.row,n=this.end.column);for(var c=0;c<a.length;c++){if(r=a[c],i=r.range.compareStart(t,n),-1==i)return void e(null,t,n,s,l);if(o=e(null,r.start.row,r.start.column,s,l),o=!o&&e(r.placeholder,r.start.row,r.start.column,s),o||0===i)return;l=!r.sameRow,s=r.end.column}e(null,t,n,s,l)},e.prototype.getNextFoldTo=function(e,t){for(var n,r,i=0;i<this.folds.length;i++){if(n=this.folds[i],r=n.range.compareEnd(e,t),-1==r)return{fold:n,kind:"after"};if(0===r)return{fold:n,kind:"inside"}}return null},e.prototype.addRemoveChars=function(e,t,n){var r,i,o=this.getNextFoldTo(e,t);if(o)if(r=o.fold,"inside"==o.kind&&r.start.column!=t&&r.start.row!=e)window.console&&window.console.log(e,t,r);else if(r.start.row==e){i=this.folds;var s=i.indexOf(r);for(0===s&&(this.start.column+=n),s;s<i.length;s++){if(r=i[s],r.start.column+=n,!r.sameRow)return;r.end.column+=n}this.end.column+=n}},e.prototype.split=function(t,n){var r=this.getNextFoldTo(t,n);if(!r||"inside"==r.kind)return null;var i=r.fold,o=this.folds,s=this.foldData,a=o.indexOf(i),l=o[a-1];this.end.row=l.end.row,this.end.column=l.end.column,o=o.splice(a,o.length-a);var c=new e(s,o);return s.splice(s.indexOf(this)+1,0,c),c},e.prototype.merge=function(e){for(var t=e.folds,n=0;n<t.length;n++)this.addFold(t[n]);var r=this.foldData;r.splice(r.indexOf(e),1)},e.prototype.toString=function(){var e=[this.range.toString()+": ["];return this.folds.forEach((function(t){e.push(" "+t.toString())})),e.push("]"),e.join("\n")},e.prototype.idxToPosition=function(e){for(var t=0,n=0;n<this.folds.length;n++){var r=this.folds[n];if(e-=r.start.column-t,e<0)return{row:r.start.row,column:r.start.column+e};if(e-=r.placeholder.length,e<0)return r.start;t=r.end.column}return{row:this.end.row,column:this.end.column+e}},e}();t.FoldLine=i})),ace.define("ace/range_list",["require","exports","module","ace/range"],(function(e,t,n){"use strict";var r=e("./range").Range,i=r.comparePoints,o=function(){function e(){this.ranges=[],this.$bias=1}return e.prototype.pointIndex=function(e,t,n){for(var r=this.ranges,o=n||0;o<r.length;o++){var s=r[o],a=i(e,s.end);if(!(a>0)){var l=i(e,s.start);return 0===a?t&&0!==l?-o-2:o:l>0||0===l&&!t?o:-o-1}}return-o-1},e.prototype.add=function(e){var t=!e.isEmpty(),n=this.pointIndex(e.start,t);n<0&&(n=-n-1);var r=this.pointIndex(e.end,t,n);return r<0?r=-r-1:r++,this.ranges.splice(n,r-n,e)},e.prototype.addList=function(e){for(var t=[],n=e.length;n--;)t.push.apply(t,this.add(e[n]));return t},e.prototype.substractPoint=function(e){var t=this.pointIndex(e);if(t>=0)return this.ranges.splice(t,1)},e.prototype.merge=function(){var e=[],t=this.ranges;t=t.sort((function(e,t){return i(e.start,t.start)}));for(var n,r=t[0],o=1;o<t.length;o++){n=r,r=t[o];var s=i(n.end,r.start);s<0||(0!=s||n.isEmpty()||r.isEmpty())&&(i(n.end,r.end)<0&&(n.end.row=r.end.row,n.end.column=r.end.column),t.splice(o,1),e.push(r),r=n,o--)}return this.ranges=t,e},e.prototype.contains=function(e,t){return this.pointIndex({row:e,column:t})>=0},e.prototype.containsPoint=function(e){return this.pointIndex(e)>=0},e.prototype.rangeAtPoint=function(e){var t=this.pointIndex(e);if(t>=0)return this.ranges[t]},e.prototype.clipRows=function(e,t){var n=this.ranges;if(n[0].start.row>t||n[n.length-1].start.row<e)return[];var r=this.pointIndex({row:e,column:0});r<0&&(r=-r-1);var i=this.pointIndex({row:t,column:0},r);i<0&&(i=-i-1);for(var o=[],s=r;s<i;s++)o.push(n[s]);return o},e.prototype.removeAll=function(){return this.ranges.splice(0,this.ranges.length)},e.prototype.attach=function(e){this.session&&this.detach(),this.session=e,this.onChange=this.$onChange.bind(this),this.session.on("change",this.onChange)},e.prototype.detach=function(){this.session&&(this.session.removeListener("change",this.onChange),this.session=null)},e.prototype.$onChange=function(e){for(var t=e.start,n=e.end,r=t.row,i=n.row,o=this.ranges,s=0,a=o.length;s<a;s++){var l=o[s];if(l.end.row>=r)break}if("insert"==e.action)for(var c=i-r,u=-t.column+n.column;s<a;s++){l=o[s];if(l.start.row>r)break;if(l.start.row==r&&l.start.column>=t.column&&(l.start.column==t.column&&this.$bias<=0||(l.start.column+=u,l.start.row+=c)),l.end.row==r&&l.end.column>=t.column){if(l.end.column==t.column&&this.$bias<0)continue;l.end.column==t.column&&u>0&&s<a-1&&l.end.column>l.start.column&&l.end.column==o[s+1].start.column&&(l.end.column-=u),l.end.column+=u,l.end.row+=c}}else for(c=r-i,u=t.column-n.column;s<a;s++){l=o[s];if(l.start.row>i)break;l.end.row<i&&(r<l.end.row||r==l.end.row&&t.column<l.end.column)?(l.end.row=r,l.end.column=t.column):l.end.row==i?l.end.column<=n.column?(c||l.end.column>t.column)&&(l.end.column=t.column,l.end.row=t.row):(l.end.column+=u,l.end.row+=c):l.end.row>i&&(l.end.row+=c),l.start.row<i&&(r<l.start.row||r==l.start.row&&t.column<l.start.column)?(l.start.row=r,l.start.column=t.column):l.start.row==i?l.start.column<=n.column?(c||l.start.column>t.column)&&(l.start.column=t.column,l.start.row=t.row):(l.start.column+=u,l.start.row+=c):l.start.row>i&&(l.start.row+=c)}if(0!=c&&s<a)for(;s<a;s++){l=o[s];l.start.row+=c,l.end.row+=c}},e}();o.prototype.comparePoints=i,t.RangeList=o})),ace.define("ace/edit_session/fold",["require","exports","module","ace/range_list"],(function(e,t,n){"use strict";var r=this&&this.__extends||function(){var e=function(t,n){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])},e(t,n)};return function(t,n){if("function"!==typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function r(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),i=e("../range_list").RangeList,o=function(e){function t(t,n){var r=e.call(this)||this;return r.foldLine=null,r.placeholder=n,r.range=t,r.start=t.start,r.end=t.end,r.sameRow=t.start.row==t.end.row,r.subFolds=r.ranges=[],r}return r(t,e),t.prototype.toString=function(){return'"'+this.placeholder+'" '+this.range.toString()},t.prototype.setFoldLine=function(e){this.foldLine=e,this.subFolds.forEach((function(t){t.setFoldLine(e)}))},t.prototype.clone=function(){var e=this.range.clone(),n=new t(e,this.placeholder);return this.subFolds.forEach((function(e){n.subFolds.push(e.clone())})),n.collapseChildren=this.collapseChildren,n},t.prototype.addSubFold=function(e){if(!this.range.isEqual(e)){a(e,this.start);for(var t=e.start.row,n=e.start.column,r=0,i=-1;r<this.subFolds.length;r++)if(i=this.subFolds[r].range.compare(t,n),1!=i)break;var o=this.subFolds[r],s=0;if(0==i){if(o.range.containsRange(e))return o.addSubFold(e);s=1}t=e.range.end.row,n=e.range.end.column;var l=r;for(i=-1;l<this.subFolds.length;l++)if(i=this.subFolds[l].range.compare(t,n),1!=i)break;0==i&&l++;for(var c=this.subFolds.splice(r,l-r,e),u=0==i?c.length-1:c.length,h=s;h<u;h++)e.addSubFold(c[h]);return e.setFoldLine(this.foldLine),e}},t.prototype.restoreRange=function(e){return c(e,this.start)},t}(i);function s(e,t){e.row-=t.row,0==e.row&&(e.column-=t.column)}function a(e,t){s(e.start,t),s(e.end,t)}function l(e,t){0==e.row&&(e.column+=t.column),e.row+=t.row}function c(e,t){l(e.start,t),l(e.end,t)}t.Fold=o})),ace.define("ace/edit_session/folding",["require","exports","module","ace/range","ace/edit_session/fold_line","ace/edit_session/fold","ace/token_iterator"],(function(e,t,n){"use strict";var r=e("../range").Range,i=e("./fold_line").FoldLine,o=e("./fold").Fold,s=e("../token_iterator").TokenIterator;function a(){this.getFoldAt=function(e,t,n){var r=this.getFoldLine(e);if(!r)return null;for(var i=r.folds,o=0;o<i.length;o++){var s=i[o].range;if(s.contains(e,t)){if(1==n&&s.isEnd(e,t)&&!s.isEmpty())continue;if(-1==n&&s.isStart(e,t)&&!s.isEmpty())continue;return i[o]}}},this.getFoldsInRange=function(e){var t=e.start,n=e.end,r=this.$foldData,i=[];t.column+=1,n.column-=1;for(var o=0;o<r.length;o++){var s=r[o].range.compareRange(e);if(2!=s){if(-2==s)break;for(var a=r[o].folds,l=0;l<a.length;l++){var c=a[l];if(s=c.range.compareRange(e),-2==s)break;if(2!=s){if(42==s)break;i.push(c)}}}}return t.column-=1,n.column+=1,i},this.getFoldsInRangeList=function(e){if(Array.isArray(e)){var t=[];e.forEach((function(e){t=t.concat(this.getFoldsInRange(e))}),this)}else t=this.getFoldsInRange(e);return t},this.getAllFolds=function(){for(var e=[],t=this.$foldData,n=0;n<t.length;n++)for(var r=0;r<t[n].folds.length;r++)e.push(t[n].folds[r]);return e},this.getFoldStringAt=function(e,t,n,r){if(r=r||this.getFoldLine(e),!r)return null;for(var i,o,s={end:{column:0}},a=0;a<r.folds.length;a++){o=r.folds[a];var l=o.range.compareEnd(e,t);if(-1==l){i=this.getLine(o.start.row).substring(s.end.column,o.start.column);break}if(0===l)return null;s=o}return i||(i=this.getLine(o.start.row).substring(s.end.column)),-1==n?i.substring(0,t-s.end.column):1==n?i.substring(t-s.end.column):i},this.getFoldLine=function(e,t){var n=this.$foldData,r=0;for(t&&(r=n.indexOf(t)),-1==r&&(r=0),r;r<n.length;r++){var i=n[r];if(i.start.row<=e&&i.end.row>=e)return i;if(i.end.row>e)return null}return null},this.getNextFoldLine=function(e,t){var n=this.$foldData,r=0;for(t&&(r=n.indexOf(t)),-1==r&&(r=0),r;r<n.length;r++){var i=n[r];if(i.end.row>=e)return i}return null},this.getFoldedRowCount=function(e,t){for(var n=this.$foldData,r=t-e+1,i=0;i<n.length;i++){var o=n[i],s=o.end.row,a=o.start.row;if(s>=t){a<t&&(a>=e?r-=t-a:r=0);break}s>=e&&(r-=a>=e?s-a:s-e+1)}return r},this.$addFoldLine=function(e){return this.$foldData.push(e),this.$foldData.sort((function(e,t){return e.start.row-t.start.row})),e},this.addFold=function(e,t){var n,r=this.$foldData,s=!1;e instanceof o?n=e:(n=new o(t,e),n.collapseChildren=t.collapseChildren),this.$clipRangeToDocument(n.range);var a=n.start.row,l=n.start.column,c=n.end.row,u=n.end.column,h=this.getFoldAt(a,l,1),f=this.getFoldAt(c,u,-1);if(h&&f==h)return h.addSubFold(n);h&&!h.range.isStart(a,l)&&this.removeFold(h),f&&!f.range.isEnd(c,u)&&this.removeFold(f);var d=this.getFoldsInRange(n.range);d.length>0&&(this.removeFolds(d),n.collapseChildren||d.forEach((function(e){n.addSubFold(e)})));for(var p=0;p<r.length;p++){var g=r[p];if(c==g.start.row){g.addFold(n),s=!0;break}if(a==g.end.row){if(g.addFold(n),s=!0,!n.sameRow){var m=r[p+1];if(m&&m.start.row==c){g.merge(m);break}}break}if(c<=g.start.row)break}return s||(g=this.$addFoldLine(new i(this.$foldData,n))),this.$useWrapMode?this.$updateWrapData(g.start.row,g.start.row):this.$updateRowLengthCache(g.start.row,g.start.row),this.$modified=!0,this._signal("changeFold",{data:n,action:"add"}),n},this.addFolds=function(e){e.forEach((function(e){this.addFold(e)}),this)},this.removeFold=function(e){var t=e.foldLine,n=t.start.row,r=t.end.row,i=this.$foldData,o=t.folds;if(1==o.length)i.splice(i.indexOf(t),1);else if(t.range.isEnd(e.end.row,e.end.column))o.pop(),t.end.row=o[o.length-1].end.row,t.end.column=o[o.length-1].end.column;else if(t.range.isStart(e.start.row,e.start.column))o.shift(),t.start.row=o[0].start.row,t.start.column=o[0].start.column;else if(e.sameRow)o.splice(o.indexOf(e),1);else{var s=t.split(e.start.row,e.start.column);o=s.folds,o.shift(),s.start.row=o[0].start.row,s.start.column=o[0].start.column}this.$updating||(this.$useWrapMode?this.$updateWrapData(n,r):this.$updateRowLengthCache(n,r)),this.$modified=!0,this._signal("changeFold",{data:e,action:"remove"})},this.removeFolds=function(e){for(var t=[],n=0;n<e.length;n++)t.push(e[n]);t.forEach((function(e){this.removeFold(e)}),this),this.$modified=!0},this.expandFold=function(e){this.removeFold(e),e.subFolds.forEach((function(t){e.restoreRange(t),this.addFold(t)}),this),e.collapseChildren>0&&this.foldAll(e.start.row+1,e.end.row,e.collapseChildren-1),e.subFolds=[]},this.expandFolds=function(e){e.forEach((function(e){this.expandFold(e)}),this)},this.unfold=function(e,t){var n,i;if(null==e)n=new r(0,0,this.getLength(),0),null==t&&(t=!0);else if("number"==typeof e)n=new r(e,0,e,this.getLine(e).length);else if("row"in e)n=r.fromPoints(e,e);else{if(Array.isArray(e))return i=[],e.forEach((function(e){i=i.concat(this.unfold(e))}),this),i;n=e}i=this.getFoldsInRangeList(n);var o=i;while(1==i.length&&r.comparePoints(i[0].start,n.start)<0&&r.comparePoints(i[0].end,n.end)>0)this.expandFolds(i),i=this.getFoldsInRangeList(n);if(0!=t?this.removeFolds(i):this.expandFolds(i),o.length)return o},this.isRowFolded=function(e,t){return!!this.getFoldLine(e,t)},this.getRowFoldEnd=function(e,t){var n=this.getFoldLine(e,t);return n?n.end.row:e},this.getRowFoldStart=function(e,t){var n=this.getFoldLine(e,t);return n?n.start.row:e},this.getFoldDisplayLine=function(e,t,n,r,i){null==r&&(r=e.start.row),null==i&&(i=0),null==t&&(t=e.end.row),null==n&&(n=this.getLine(t).length);var o=this.doc,s="";return e.walk((function(e,t,n,a){if(!(t<r)){if(t==r){if(n<i)return;a=Math.max(i,a)}s+=null!=e?e:o.getLine(t).substring(a,n)}}),t,n),s},this.getDisplayLine=function(e,t,n,r){var i,o=this.getFoldLine(e);return o?this.getFoldDisplayLine(o,e,t,n,r):(i=this.doc.getLine(e),i.substring(r||0,t||i.length))},this.$cloneFoldData=function(){var e=[];return e=this.$foldData.map((function(t){var n=t.folds.map((function(e){return e.clone()}));return new i(e,n)})),e},this.toggleFold=function(e){var t,n,r=this.selection,i=r.getRange();if(i.isEmpty()){var o=i.start;if(t=this.getFoldAt(o.row,o.column),t)return void this.expandFold(t);(n=this.findMatchingBracket(o))?1==i.comparePoint(n)?i.end=n:(i.start=n,i.start.column++,i.end.column--):(n=this.findMatchingBracket({row:o.row,column:o.column+1}))?(1==i.comparePoint(n)?i.end=n:i.start=n,i.start.column++):i=this.getCommentFoldRange(o.row,o.column)||i}else{var s=this.getFoldsInRange(i);if(e&&s.length)return void this.expandFolds(s);1==s.length&&(t=s[0])}if(t||(t=this.getFoldAt(i.start.row,i.start.column)),t&&t.range.toString()==i.toString())this.expandFold(t);else{var a="...";if(!i.isMultiLine()){if(a=this.getTextRange(i),a.length<4)return;a=a.trim().substring(0,2)+".."}this.addFold(a,i)}},this.getCommentFoldRange=function(e,t,n){var i=new s(this,e,t),o=i.getCurrentToken(),a=o&&o.type;if(o&&/^comment|string/.test(a)){a=a.match(/comment|string/)[0],"comment"==a&&(a+="|doc-start");var l=new RegExp(a),c=new r;if(1!=n){do{o=i.stepBackward()}while(o&&l.test(o.type)&&!/^comment.end/.test(o.type));o=i.stepForward()}if(c.start.row=i.getCurrentTokenRow(),c.start.column=i.getCurrentTokenColumn()+(/^comment.start/.test(o.type)?o.value.length:2),i=new s(this,e,t),-1!=n){var u=-1;do{if(o=i.stepForward(),-1==u){var h=this.getState(i.$row);l.test(h)||(u=i.$row)}else if(i.$row>u)break}while(o&&l.test(o.type)&&!/^comment.start/.test(o.type));o=i.stepBackward()}else o=i.getCurrentToken();return c.end.row=i.getCurrentTokenRow(),c.end.column=i.getCurrentTokenColumn(),/^comment.end/.test(o.type)||(c.end.column+=o.value.length-2),c}},this.foldAll=function(e,t,n,r){void 0==n&&(n=1e5);var i=this.foldWidgets;if(i){t=t||this.getLength(),e=e||0;for(var o=e;o<t;o++)if(null==i[o]&&(i[o]=this.getFoldWidget(o)),"start"==i[o]&&(!r||r(o))){var s=this.getFoldWidgetRange(o);s&&s.isMultiLine()&&s.end.row<=t&&s.start.row>=e&&(o=s.end.row,s.collapseChildren=n,this.addFold("...",s))}}},this.foldToLevel=function(e){this.foldAll();while(e-- >0)this.unfold(null,!1)},this.foldAllComments=function(){var e=this;this.foldAll(null,null,null,(function(t){for(var n=e.getTokens(t),r=0;r<n.length;r++){var i=n[r];if("text"!=i.type||!/^\s+$/.test(i.value))return!!/comment/.test(i.type)}}))},this.$foldStyles={manual:1,markbegin:1,markbeginend:1},this.$foldStyle="markbegin",this.setFoldStyle=function(e){if(!this.$foldStyles[e])throw new Error("invalid fold style: "+e+"["+Object.keys(this.$foldStyles).join(", ")+"]");if(this.$foldStyle!=e){this.$foldStyle=e,"manual"==e&&this.unfold();var t=this.$foldMode;this.$setFolding(null),this.$setFolding(t)}},this.$setFolding=function(e){this.$foldMode!=e&&(this.$foldMode=e,this.off("change",this.$updateFoldWidgets),this.off("tokenizerUpdate",this.$tokenizerUpdateFoldWidgets),this._signal("changeAnnotation"),e&&"manual"!=this.$foldStyle?(this.foldWidgets=[],this.getFoldWidget=e.getFoldWidget.bind(e,this,this.$foldStyle),this.getFoldWidgetRange=e.getFoldWidgetRange.bind(e,this,this.$foldStyle),this.$updateFoldWidgets=this.updateFoldWidgets.bind(this),this.$tokenizerUpdateFoldWidgets=this.tokenizerUpdateFoldWidgets.bind(this),this.on("change",this.$updateFoldWidgets),this.on("tokenizerUpdate",this.$tokenizerUpdateFoldWidgets)):this.foldWidgets=null)},this.getParentFoldRangeData=function(e,t){var n=this.foldWidgets;if(!n||t&&n[e])return{};var r,i=e-1;while(i>=0){var o=n[i];if(null==o&&(o=n[i]=this.getFoldWidget(i)),"start"==o){var s=this.getFoldWidgetRange(i);if(r||(r=s),s&&s.end.row>=e)break}i--}return{range:-1!==i&&s,firstRange:r}},this.onFoldWidgetClick=function(e,t){t=t.domEvent;var n={children:t.shiftKey,all:t.ctrlKey||t.metaKey,siblings:t.altKey},r=this.$toggleFoldWidget(e,n);if(!r){var i=t.target||t.srcElement;i&&/ace_fold-widget/.test(i.className)&&(i.className+=" ace_invalid")}},this.$toggleFoldWidget=function(e,t){if(this.getFoldWidget){var n=this.getFoldWidget(e),r=this.getLine(e),i="end"===n?-1:1,o=this.getFoldAt(e,-1===i?0:r.length,i);if(o)return t.children||t.all?this.removeFold(o):this.expandFold(o),o;var s=this.getFoldWidgetRange(e,!0);if(s&&!s.isMultiLine()&&(o=this.getFoldAt(s.start.row,s.start.column,1),o&&s.isEqual(o.range)))return this.removeFold(o),o;if(t.siblings){var a=this.getParentFoldRangeData(e);if(a.range)var l=a.range.start.row+1,c=a.range.end.row;this.foldAll(l,c,t.all?1e4:0)}else t.children?(c=s?s.end.row:this.getLength(),this.foldAll(e+1,c,t.all?1e4:0)):s&&(t.all&&(s.collapseChildren=1e4),this.addFold("...",s));return s}},this.toggleFoldWidget=function(e){var t=this.selection.getCursor().row;t=this.getRowFoldStart(t);var n=this.$toggleFoldWidget(t,{});if(!n){var r=this.getParentFoldRangeData(t,!0);if(n=r.range||r.firstRange,n){t=n.start.row;var i=this.getFoldAt(t,this.getLine(t).length,1);i?this.removeFold(i):this.addFold("...",n)}}},this.updateFoldWidgets=function(e){var t=e.start.row,n=e.end.row-t;if(0===n)this.foldWidgets[t]=null;else if("remove"==e.action)this.foldWidgets.splice(t,n+1,null);else{var r=Array(n+1);r.unshift(t,1),this.foldWidgets.splice.apply(this.foldWidgets,r)}},this.tokenizerUpdateFoldWidgets=function(e){var t=e.data;t.first!=t.last&&this.foldWidgets.length>t.first&&this.foldWidgets.splice(t.first,this.foldWidgets.length)}}t.Folding=a})),ace.define("ace/edit_session/bracket_match",["require","exports","module","ace/token_iterator","ace/range"],(function(e,t,n){"use strict";var r=e("../token_iterator").TokenIterator,i=e("../range").Range;function o(){this.findMatchingBracket=function(e,t){if(0==e.column)return null;var n=t||this.getLine(e.row).charAt(e.column-1);if(""==n)return null;var r=n.match(/([\(\[\{])|([\)\]\}])/);return r?r[1]?this.$findClosingBracket(r[1],e):this.$findOpeningBracket(r[2],e):null},this.getBracketRange=function(e){var t,n=this.getLine(e.row),r=!0,o=n.charAt(e.column-1),s=o&&o.match(/([\(\[\{])|([\)\]\}])/);if(s||(o=n.charAt(e.column),e={row:e.row,column:e.column+1},s=o&&o.match(/([\(\[\{])|([\)\]\}])/),r=!1),!s)return null;if(s[1]){var a=this.$findClosingBracket(s[1],e);if(!a)return null;t=i.fromPoints(e,a),r||(t.end.column++,t.start.column--),t.cursor=t.end}else{a=this.$findOpeningBracket(s[2],e);if(!a)return null;t=i.fromPoints(a,e),r||(t.start.column++,t.end.column--),t.cursor=t.start}return t},this.getMatchingBracketRanges=function(e,t){var n=this.getLine(e.row),r=/([\(\[\{])|([\)\]\}])/,o=!t&&n.charAt(e.column-1),s=o&&o.match(r);if(s||(o=(void 0===t||t)&&n.charAt(e.column),e={row:e.row,column:e.column+1},s=o&&o.match(r)),!s)return null;var a=new i(e.row,e.column-1,e.row,e.column),l=s[1]?this.$findClosingBracket(s[1],e):this.$findOpeningBracket(s[2],e);if(!l)return[a];var c=new i(l.row,l.column,l.row,l.column+1);return[a,c]},this.$brackets={")":"(","(":")","]":"[","[":"]","{":"}","}":"{","<":">",">":"<"},this.$findOpeningBracket=function(e,t,n){var i=this.$brackets[e],o=1,s=new r(this,t.row,t.column),a=s.getCurrentToken();if(a||(a=s.stepForward()),a){n||(n=new RegExp("(\\.?"+a.type.replace(".","\\.").replace("rparen",".paren").replace(/\b(?:end)\b/,"(?:start|begin|end)").replace(/-close\b/,"-(close|open)")+")+"));var l=t.column-s.getCurrentTokenColumn()-2,c=a.value;while(1){while(l>=0){var u=c.charAt(l);if(u==i){if(o-=1,0==o)return{row:s.getCurrentTokenRow(),column:l+s.getCurrentTokenColumn()}}else u==e&&(o+=1);l-=1}do{a=s.stepBackward()}while(a&&!n.test(a.type));if(null==a)break;c=a.value,l=c.length-1}return null}},this.$findClosingBracket=function(e,t,n){var i=this.$brackets[e],o=1,s=new r(this,t.row,t.column),a=s.getCurrentToken();if(a||(a=s.stepForward()),a){n||(n=new RegExp("(\\.?"+a.type.replace(".","\\.").replace("lparen",".paren").replace(/\b(?:start|begin)\b/,"(?:start|begin|end)").replace(/-open\b/,"-(close|open)")+")+"));var l=t.column-s.getCurrentTokenColumn();while(1){var c=a.value,u=c.length;while(l<u){var h=c.charAt(l);if(h==i){if(o-=1,0==o)return{row:s.getCurrentTokenRow(),column:l+s.getCurrentTokenColumn()}}else h==e&&(o+=1);l+=1}do{a=s.stepForward()}while(a&&!n.test(a.type));if(null==a)break;l=0}return null}},this.getMatchingTags=function(e){var t=new r(this,e.row,e.column),n=this.$findTagName(t);if(n){var i=t.stepBackward();return"<"===i.value?this.$findClosingTag(t,n):this.$findOpeningTag(t,n)}},this.$findTagName=function(e){var t=e.getCurrentToken(),n=!1,r=!1;if(t&&-1===t.type.indexOf("tag-name"))do{t=r?e.stepBackward():e.stepForward(),t&&("/>"===t.value?r=!0:-1!==t.type.indexOf("tag-name")&&(n=!0))}while(t&&!n);return t},this.$findClosingTag=function(e,t){var n,r=t.value,o=t.value,s=0,a=new i(e.getCurrentTokenRow(),e.getCurrentTokenColumn(),e.getCurrentTokenRow(),e.getCurrentTokenColumn()+1);t=e.stepForward();var l=new i(e.getCurrentTokenRow(),e.getCurrentTokenColumn(),e.getCurrentTokenRow(),e.getCurrentTokenColumn()+t.value.length),c=!1;do{if(n=t,t=e.stepForward(),t){if(">"===t.value&&!c){var u=new i(e.getCurrentTokenRow(),e.getCurrentTokenColumn(),e.getCurrentTokenRow(),e.getCurrentTokenColumn()+1);c=!0}if(-1!==t.type.indexOf("tag-name")){if(r=t.value,o===r)if("<"===n.value)s++;else if("</"===n.value&&(s--,s<0)){e.stepBackward();var h=new i(e.getCurrentTokenRow(),e.getCurrentTokenColumn(),e.getCurrentTokenRow(),e.getCurrentTokenColumn()+2);t=e.stepForward();var f=new i(e.getCurrentTokenRow(),e.getCurrentTokenColumn(),e.getCurrentTokenRow(),e.getCurrentTokenColumn()+t.value.length);if(t=e.stepForward(),!t||">"!==t.value)return;var d=new i(e.getCurrentTokenRow(),e.getCurrentTokenColumn(),e.getCurrentTokenRow(),e.getCurrentTokenColumn()+1)}}else if(o===r&&"/>"===t.value&&(s--,s<0))h=new i(e.getCurrentTokenRow(),e.getCurrentTokenColumn(),e.getCurrentTokenRow(),e.getCurrentTokenColumn()+2),f=h,d=f,u=new i(l.end.row,l.end.column,l.end.row,l.end.column+1)}}while(t&&s>=0);if(a&&u&&h&&d&&l&&f)return{openTag:new i(a.start.row,a.start.column,u.end.row,u.end.column),closeTag:new i(h.start.row,h.start.column,d.end.row,d.end.column),openTagName:l,closeTagName:f}},this.$findOpeningTag=function(e,t){var n=e.getCurrentToken(),r=t.value,o=0,s=e.getCurrentTokenRow(),a=e.getCurrentTokenColumn(),l=a+2,c=new i(s,a,s,l);e.stepForward();var u=new i(e.getCurrentTokenRow(),e.getCurrentTokenColumn(),e.getCurrentTokenRow(),e.getCurrentTokenColumn()+t.value.length);if(t=e.stepForward(),t&&">"===t.value){var h=new i(e.getCurrentTokenRow(),e.getCurrentTokenColumn(),e.getCurrentTokenRow(),e.getCurrentTokenColumn()+1);e.stepBackward(),e.stepBackward();do{if(t=n,s=e.getCurrentTokenRow(),a=e.getCurrentTokenColumn(),l=a+t.value.length,n=e.stepBackward(),t)if(-1!==t.type.indexOf("tag-name")){if(r===t.value)if("<"===n.value){if(o++,o>0){var f=new i(s,a,s,l),d=new i(e.getCurrentTokenRow(),e.getCurrentTokenColumn(),e.getCurrentTokenRow(),e.getCurrentTokenColumn()+1);do{t=e.stepForward()}while(t&&">"!==t.value);var p=new i(e.getCurrentTokenRow(),e.getCurrentTokenColumn(),e.getCurrentTokenRow(),e.getCurrentTokenColumn()+1)}}else"</"===n.value&&o--}else if("/>"===t.value){var g=0,m=n;while(m){if(-1!==m.type.indexOf("tag-name")&&m.value===r){o--;break}if("<"===m.value)break;m=e.stepBackward(),g++}for(var v=0;v<g;v++)e.stepForward()}}while(n&&o<=0);return d&&p&&c&&h&&f&&u?{openTag:new i(d.start.row,d.start.column,p.end.row,p.end.column),closeTag:new i(c.start.row,c.start.column,h.end.row,h.end.column),openTagName:f,closeTagName:u}:void 0}}}t.BracketMatch=o})),ace.define("ace/edit_session",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/bidihandler","ace/config","ace/lib/event_emitter","ace/selection","ace/mode/text","ace/range","ace/document","ace/background_tokenizer","ace/search_highlight","ace/edit_session/folding","ace/edit_session/bracket_match"],(function(e,t,n){"use strict";var r=e("./lib/oop"),i=e("./lib/lang"),o=e("./bidihandler").BidiHandler,s=e("./config"),a=e("./lib/event_emitter").EventEmitter,l=e("./selection").Selection,c=e("./mode/text").Mode,u=e("./range").Range,h=e("./document").Document,f=e("./background_tokenizer").BackgroundTokenizer,d=e("./search_highlight").SearchHighlight,p=function(){function e(t,n){this.$breakpoints=[],this.$decorations=[],this.$frontMarkers={},this.$backMarkers={},this.$markerId=1,this.$undoSelect=!0,this.$foldData=[],this.id="session"+ ++e.$uid,this.$foldData.toString=function(){return this.join("\n")},this.bgTokenizer=new f((new c).getTokenizer(),this);var r=this;this.bgTokenizer.on("update",(function(e){r._signal("tokenizerUpdate",e)})),this.on("changeFold",this.onChangeFold.bind(this)),this.$onChange=this.onChange.bind(this),"object"==typeof t&&t.getLine||(t=new h(t)),this.setDocument(t),this.selection=new l(this),this.$bidiHandler=new o(this),s.resetOptions(this),this.setMode(n),s._signal("session",this),this.destroyed=!1}return e.prototype.setDocument=function(e){this.doc&&this.doc.off("change",this.$onChange),this.doc=e,e.on("change",this.$onChange,!0),this.bgTokenizer.setDocument(this.getDocument()),this.resetCaches()},e.prototype.getDocument=function(){return this.doc},e.prototype.$resetRowCache=function(e){if(!e)return this.$docRowCache=[],void(this.$screenRowCache=[]);var t=this.$docRowCache.length,n=this.$getRowCacheIndex(this.$docRowCache,e)+1;t>n&&(this.$docRowCache.splice(n,t),this.$screenRowCache.splice(n,t))},e.prototype.$getRowCacheIndex=function(e,t){var n=0,r=e.length-1;while(n<=r){var i=n+r>>1,o=e[i];if(t>o)n=i+1;else{if(!(t<o))return i;r=i-1}}return n-1},e.prototype.resetCaches=function(){this.$modified=!0,this.$wrapData=[],this.$rowLengthCache=[],this.$resetRowCache(0),this.destroyed||this.bgTokenizer.start(0)},e.prototype.onChangeFold=function(e){var t=e.data;this.$resetRowCache(t.start.row)},e.prototype.onChange=function(e){this.$modified=!0,this.$bidiHandler.onChange(e),this.$resetRowCache(e.start.row);var t=this.$updateInternalDataOnChange(e);!this.$fromUndo&&this.$undoManager&&(t&&t.length&&(this.$undoManager.add({action:"removeFolds",folds:t},this.mergeUndoDeltas),this.mergeUndoDeltas=!0),this.$undoManager.add(e,this.mergeUndoDeltas),this.mergeUndoDeltas=!0,this.$informUndoManager.schedule()),this.bgTokenizer.$updateOnChange(e),this._signal("change",e)},e.prototype.setValue=function(e){this.doc.setValue(e),this.selection.moveTo(0,0),this.$resetRowCache(0),this.setUndoManager(this.$undoManager),this.getUndoManager().reset()},e.prototype.toString=function(){return this.doc.getValue()},e.prototype.getSelection=function(){return this.selection},e.prototype.getState=function(e){return this.bgTokenizer.getState(e)},e.prototype.getTokens=function(e){return this.bgTokenizer.getTokens(e)},e.prototype.getTokenAt=function(e,t){var n,r=this.bgTokenizer.getTokens(e),i=0;if(null==t){var o=r.length-1;i=this.getLine(e).length}else for(o=0;o<r.length;o++)if(i+=r[o].value.length,i>=t)break;return n=r[o],n?(n.index=o,n.start=i-n.value.length,n):null},e.prototype.setUndoManager=function(e){if(this.$undoManager=e,this.$informUndoManager&&this.$informUndoManager.cancel(),e){var t=this;e.addSession(this),this.$syncInformUndoManager=function(){t.$informUndoManager.cancel(),t.mergeUndoDeltas=!1},this.$informUndoManager=i.delayedCall(this.$syncInformUndoManager)}else this.$syncInformUndoManager=function(){}},e.prototype.markUndoGroup=function(){this.$syncInformUndoManager&&this.$syncInformUndoManager()},e.prototype.getUndoManager=function(){return this.$undoManager||this.$defaultUndoManager},e.prototype.getTabString=function(){return this.getUseSoftTabs()?i.stringRepeat(" ",this.getTabSize()):"\t"},e.prototype.setUseSoftTabs=function(e){this.setOption("useSoftTabs",e)},e.prototype.getUseSoftTabs=function(){return this.$useSoftTabs&&!this.$mode.$indentWithTabs},e.prototype.setTabSize=function(e){this.setOption("tabSize",e)},e.prototype.getTabSize=function(){return this.$tabSize},e.prototype.isTabStop=function(e){return this.$useSoftTabs&&e.column%this.$tabSize===0},e.prototype.setNavigateWithinSoftTabs=function(e){this.setOption("navigateWithinSoftTabs",e)},e.prototype.getNavigateWithinSoftTabs=function(){return this.$navigateWithinSoftTabs},e.prototype.setOverwrite=function(e){this.setOption("overwrite",e)},e.prototype.getOverwrite=function(){return this.$overwrite},e.prototype.toggleOverwrite=function(){this.setOverwrite(!this.$overwrite)},e.prototype.addGutterDecoration=function(e,t){this.$decorations[e]||(this.$decorations[e]=""),this.$decorations[e]+=" "+t,this._signal("changeBreakpoint",{})},e.prototype.removeGutterDecoration=function(e,t){this.$decorations[e]=(this.$decorations[e]||"").replace(" "+t,""),this._signal("changeBreakpoint",{})},e.prototype.getBreakpoints=function(){return this.$breakpoints},e.prototype.setBreakpoints=function(e){this.$breakpoints=[];for(var t=0;t<e.length;t++)this.$breakpoints[e[t]]="ace_breakpoint";this._signal("changeBreakpoint",{})},e.prototype.clearBreakpoints=function(){this.$breakpoints=[],this._signal("changeBreakpoint",{})},e.prototype.setBreakpoint=function(e,t){void 0===t&&(t="ace_breakpoint"),t?this.$breakpoints[e]=t:delete this.$breakpoints[e],this._signal("changeBreakpoint",{})},e.prototype.clearBreakpoint=function(e){delete this.$breakpoints[e],this._signal("changeBreakpoint",{})},e.prototype.addMarker=function(e,t,n,r){var i=this.$markerId++,o={range:e,type:n||"line",renderer:"function"==typeof n?n:null,clazz:t,inFront:!!r,id:i};return r?(this.$frontMarkers[i]=o,this._signal("changeFrontMarker")):(this.$backMarkers[i]=o,this._signal("changeBackMarker")),i},e.prototype.addDynamicMarker=function(e,t){if(e.update){var n=this.$markerId++;return e.id=n,e.inFront=!!t,t?(this.$frontMarkers[n]=e,this._signal("changeFrontMarker")):(this.$backMarkers[n]=e,this._signal("changeBackMarker")),e}},e.prototype.removeMarker=function(e){var t=this.$frontMarkers[e]||this.$backMarkers[e];if(t){var n=t.inFront?this.$frontMarkers:this.$backMarkers;delete n[e],this._signal(t.inFront?"changeFrontMarker":"changeBackMarker")}},e.prototype.getMarkers=function(e){return e?this.$frontMarkers:this.$backMarkers},e.prototype.highlight=function(e){if(!this.$searchHighlight){var t=new d(null,"ace_selected-word","text");this.$searchHighlight=this.addDynamicMarker(t)}this.$searchHighlight.setRegexp(e)},e.prototype.highlightLines=function(e,t,n,r){"number"!=typeof t&&(n=t,t=e),n||(n="ace_step");var i=new u(e,0,t,1/0);return i.id=this.addMarker(i,n,"fullLine",r),i},e.prototype.setAnnotations=function(e){this.$annotations=e,this._signal("changeAnnotation",{})},e.prototype.getAnnotations=function(){return this.$annotations||[]},e.prototype.clearAnnotations=function(){this.setAnnotations([])},e.prototype.$detectNewLine=function(e){var t=e.match(/^.*?(\r?\n)/m);this.$autoNewLine=t?t[1]:"\n"},e.prototype.getWordRange=function(e,t){var n=this.getLine(e),r=!1;if(t>0&&(r=!!n.charAt(t-1).match(this.tokenRe)),r||(r=!!n.charAt(t).match(this.tokenRe)),r)var i=this.tokenRe;else if(/^\s+$/.test(n.slice(t-1,t+1)))i=/\s/;else i=this.nonTokenRe;var o=t;if(o>0){do{o--}while(o>=0&&n.charAt(o).match(i));o++}var s=t;while(s<n.length&&n.charAt(s).match(i))s++;return new u(e,o,e,s)},e.prototype.getAWordRange=function(e,t){var n=this.getWordRange(e,t),r=this.getLine(n.end.row);while(r.charAt(n.end.column).match(/[ \t]/))n.end.column+=1;return n},e.prototype.setNewLineMode=function(e){this.doc.setNewLineMode(e)},e.prototype.getNewLineMode=function(){return this.doc.getNewLineMode()},e.prototype.setUseWorker=function(e){this.setOption("useWorker",e)},e.prototype.getUseWorker=function(){return this.$useWorker},e.prototype.onReloadTokenizer=function(e){var t=e.data;this.bgTokenizer.start(t.first),this._signal("tokenizerUpdate",e)},e.prototype.setMode=function(e,t){if(e&&"object"===typeof e){if(e.getTokenizer)return this.$onChangeMode(e);var n=e,r=n.path}else r=e||"ace/mode/text";if(this.$modes["ace/mode/text"]||(this.$modes["ace/mode/text"]=new c),this.$modes[r]&&!n)return this.$onChangeMode(this.$modes[r]),void(t&&t());this.$modeId=r,s.loadModule(["mode",r],function(e){if(this.$modeId!==r)return t&&t();this.$modes[r]&&!n?this.$onChangeMode(this.$modes[r]):e&&e.Mode&&(e=new e.Mode(n),n||(this.$modes[r]=e,e.$id=r),this.$onChangeMode(e)),t&&t()}.bind(this)),this.$mode||this.$onChangeMode(this.$modes["ace/mode/text"],!0)},e.prototype.$onChangeMode=function(e,t){if(t||(this.$modeId=e.$id),this.$mode!==e){var n=this.$mode;this.$mode=e,this.$stopWorker(),this.$useWorker&&this.$startWorker();var r=e.getTokenizer();if(void 0!==r.on){var i=this.onReloadTokenizer.bind(this);r.on("update",i)}this.bgTokenizer.setTokenizer(r),this.bgTokenizer.setDocument(this.getDocument()),this.tokenRe=e.tokenRe,this.nonTokenRe=e.nonTokenRe,t||(e.attachToSession&&e.attachToSession(this),this.$options.wrapMethod.set.call(this,this.$wrapMethod),this.$setFolding(e.foldingRules),this.bgTokenizer.start(0),this._emit("changeMode",{oldMode:n,mode:e}))}},e.prototype.$stopWorker=function(){this.$worker&&(this.$worker.terminate(),this.$worker=null)},e.prototype.$startWorker=function(){try{this.$worker=this.$mode.createWorker(this)}catch(e){s.warn("Could not load worker",e),this.$worker=null}},e.prototype.getMode=function(){return this.$mode},e.prototype.setScrollTop=function(e){this.$scrollTop===e||isNaN(e)||(this.$scrollTop=e,this._signal("changeScrollTop",e))},e.prototype.getScrollTop=function(){return this.$scrollTop},e.prototype.setScrollLeft=function(e){this.$scrollLeft===e||isNaN(e)||(this.$scrollLeft=e,this._signal("changeScrollLeft",e))},e.prototype.getScrollLeft=function(){return this.$scrollLeft},e.prototype.getScreenWidth=function(){return this.$computeWidth(),this.lineWidgets?Math.max(this.getLineWidgetMaxWidth(),this.screenWidth):this.screenWidth},e.prototype.getLineWidgetMaxWidth=function(){if(null!=this.lineWidgetsWidth)return this.lineWidgetsWidth;var e=0;return this.lineWidgets.forEach((function(t){t&&t.screenWidth>e&&(e=t.screenWidth)})),this.lineWidgetWidth=e},e.prototype.$computeWidth=function(e){if(this.$modified||e){if(this.$modified=!1,this.$useWrapMode)return this.screenWidth=this.$wrapLimit;for(var t=this.doc.getAllLines(),n=this.$rowLengthCache,r=0,i=0,o=this.$foldData[i],s=o?o.start.row:1/0,a=t.length,l=0;l<a;l++){if(l>s){if(l=o.end.row+1,l>=a)break;o=this.$foldData[i++],s=o?o.start.row:1/0}null==n[l]&&(n[l]=this.$getStringScreenWidth(t[l])[0]),n[l]>r&&(r=n[l])}this.screenWidth=r}},e.prototype.getLine=function(e){return this.doc.getLine(e)},e.prototype.getLines=function(e,t){return this.doc.getLines(e,t)},e.prototype.getLength=function(){return this.doc.getLength()},e.prototype.getTextRange=function(e){return this.doc.getTextRange(e||this.selection.getRange())},e.prototype.insert=function(e,t){return this.doc.insert(e,t)},e.prototype.remove=function(e){return this.doc.remove(e)},e.prototype.removeFullLines=function(e,t){return this.doc.removeFullLines(e,t)},e.prototype.undoChanges=function(e,t){if(e.length){this.$fromUndo=!0;for(var n=e.length-1;-1!=n;n--){var r=e[n];"insert"==r.action||"remove"==r.action?this.doc.revertDelta(r):r.folds&&this.addFolds(r.folds)}!t&&this.$undoSelect&&(e.selectionBefore?this.selection.fromJSON(e.selectionBefore):this.selection.setRange(this.$getUndoSelection(e,!0))),this.$fromUndo=!1}},e.prototype.redoChanges=function(e,t){if(e.length){this.$fromUndo=!0;for(var n=0;n<e.length;n++){var r=e[n];"insert"!=r.action&&"remove"!=r.action||this.doc.$safeApplyDelta(r)}!t&&this.$undoSelect&&(e.selectionAfter?this.selection.fromJSON(e.selectionAfter):this.selection.setRange(this.$getUndoSelection(e,!1))),this.$fromUndo=!1}},e.prototype.setUndoSelect=function(e){this.$undoSelect=e},e.prototype.$getUndoSelection=function(e,t){function n(e){return t?"insert"!==e.action:"insert"===e.action}for(var r,i,o=0;o<e.length;o++){var s=e[o];s.start&&(r?n(s)?(i=s.start,-1==r.compare(i.row,i.column)&&r.setStart(i),i=s.end,1==r.compare(i.row,i.column)&&r.setEnd(i)):(i=s.start,-1==r.compare(i.row,i.column)&&(r=u.fromPoints(s.start,s.start))):r=n(s)?u.fromPoints(s.start,s.end):u.fromPoints(s.start,s.start))}return r},e.prototype.replace=function(e,t){return this.doc.replace(e,t)},e.prototype.moveText=function(e,t,n){var r=this.getTextRange(e),i=this.getFoldsInRange(e),o=u.fromPoints(t,t);if(!n){this.remove(e);var s=e.start.row-e.end.row,a=s?-e.end.column:e.start.column-e.end.column;a&&(o.start.row==e.end.row&&o.start.column>e.end.column&&(o.start.column+=a),o.end.row==e.end.row&&o.end.column>e.end.column&&(o.end.column+=a)),s&&o.start.row>=e.end.row&&(o.start.row+=s,o.end.row+=s)}if(o.end=this.insert(o.start,r),i.length){var l=e.start,c=o.start;s=c.row-l.row,a=c.column-l.column;this.addFolds(i.map((function(e){return e=e.clone(),e.start.row==l.row&&(e.start.column+=a),e.end.row==l.row&&(e.end.column+=a),e.start.row+=s,e.end.row+=s,e})))}return o},e.prototype.indentRows=function(e,t,n){n=n.replace(/\t/g,this.getTabString());for(var r=e;r<=t;r++)this.doc.insertInLine({row:r,column:0},n)},e.prototype.outdentRows=function(e){for(var t=e.collapseRows(),n=new u(0,0,0,0),r=this.getTabSize(),i=t.start.row;i<=t.end.row;++i){var o=this.getLine(i);n.start.row=i,n.end.row=i;for(var s=0;s<r;++s)if(" "!=o.charAt(s))break;s<r&&"\t"==o.charAt(s)?(n.start.column=s,n.end.column=s+1):(n.start.column=0,n.end.column=s),this.remove(n)}},e.prototype.$moveLines=function(e,t,n){if(e=this.getRowFoldStart(e),t=this.getRowFoldEnd(t),n<0){var r=this.getRowFoldStart(e+n);if(r<0)return 0;var i=r-e}else if(n>0){r=this.getRowFoldEnd(t+n);if(r>this.doc.getLength()-1)return 0;i=r-t}else{e=this.$clipRowToDocument(e),t=this.$clipRowToDocument(t);i=t-e+1}var o=new u(e,0,t,Number.MAX_VALUE),s=this.getFoldsInRange(o).map((function(e){return e=e.clone(),e.start.row+=i,e.end.row+=i,e})),a=0==n?this.doc.getLines(e,t):this.doc.removeFullLines(e,t);return this.doc.insertFullLines(e+i,a),s.length&&this.addFolds(s),i},e.prototype.moveLinesUp=function(e,t){return this.$moveLines(e,t,-1)},e.prototype.moveLinesDown=function(e,t){return this.$moveLines(e,t,1)},e.prototype.duplicateLines=function(e,t){return this.$moveLines(e,t,0)},e.prototype.$clipRowToDocument=function(e){return Math.max(0,Math.min(e,this.doc.getLength()-1))},e.prototype.$clipColumnToRow=function(e,t){return t<0?0:Math.min(this.doc.getLine(e).length,t)},e.prototype.$clipPositionToDocument=function(e,t){if(t=Math.max(0,t),e<0)e=0,t=0;else{var n=this.doc.getLength();e>=n?(e=n-1,t=this.doc.getLine(n-1).length):t=Math.min(this.doc.getLine(e).length,t)}return{row:e,column:t}},e.prototype.$clipRangeToDocument=function(e){e.start.row<0?(e.start.row=0,e.start.column=0):e.start.column=this.$clipColumnToRow(e.start.row,e.start.column);var t=this.doc.getLength()-1;return e.end.row>t?(e.end.row=t,e.end.column=this.doc.getLine(t).length):e.end.column=this.$clipColumnToRow(e.end.row,e.end.column),e},e.prototype.setUseWrapMode=function(e){if(e!=this.$useWrapMode){if(this.$useWrapMode=e,this.$modified=!0,this.$resetRowCache(0),e){var t=this.getLength();this.$wrapData=Array(t),this.$updateWrapData(0,t-1)}this._signal("changeWrapMode")}},e.prototype.getUseWrapMode=function(){return this.$useWrapMode},e.prototype.setWrapLimitRange=function(e,t){this.$wrapLimitRange.min===e&&this.$wrapLimitRange.max===t||(this.$wrapLimitRange={min:e,max:t},this.$modified=!0,this.$bidiHandler.markAsDirty(),this.$useWrapMode&&this._signal("changeWrapMode"))},e.prototype.adjustWrapLimit=function(e,t){var n=this.$wrapLimitRange;n.max<0&&(n={min:t,max:t});var r=this.$constrainWrapLimit(e,n.min,n.max);return r!=this.$wrapLimit&&r>1&&(this.$wrapLimit=r,this.$modified=!0,this.$useWrapMode&&(this.$updateWrapData(0,this.getLength()-1),this.$resetRowCache(0),this._signal("changeWrapLimit")),!0)},e.prototype.$constrainWrapLimit=function(e,t,n){return t&&(e=Math.max(t,e)),n&&(e=Math.min(n,e)),e},e.prototype.getWrapLimit=function(){return this.$wrapLimit},e.prototype.setWrapLimit=function(e){this.setWrapLimitRange(e,e)},e.prototype.getWrapLimitRange=function(){return{min:this.$wrapLimitRange.min,max:this.$wrapLimitRange.max}},e.prototype.$updateInternalDataOnChange=function(e){var t=this.$useWrapMode,n=e.action,r=e.start,i=e.end,o=r.row,s=i.row,a=s-o,l=null;if(this.$updating=!0,0!=a)if("remove"===n){this[t?"$wrapData":"$rowLengthCache"].splice(o,a);var c=this.$foldData;l=this.getFoldsInRange(e),this.removeFolds(l);var u=this.getFoldLine(i.row),h=0;if(u){u.addRemoveChars(i.row,i.column,r.column-i.column),u.shiftRow(-a);var f=this.getFoldLine(o);f&&f!==u&&(f.merge(u),u=f),h=c.indexOf(u)+1}for(h;h<c.length;h++){u=c[h];u.start.row>=i.row&&u.shiftRow(-a)}s=o}else{var d=Array(a);d.unshift(o,0);var p=t?this.$wrapData:this.$rowLengthCache;p.splice.apply(p,d);c=this.$foldData,u=this.getFoldLine(o),h=0;if(u){var g=u.range.compareInside(r.row,r.column);0==g?(u=u.split(r.row,r.column),u&&(u.shiftRow(a),u.addRemoveChars(s,0,i.column-r.column))):-1==g&&(u.addRemoveChars(o,0,i.column-r.column),u.shiftRow(a)),h=c.indexOf(u)+1}for(h;h<c.length;h++){u=c[h];u.start.row>=o&&u.shiftRow(a)}}else{a=Math.abs(e.start.column-e.end.column),"remove"===n&&(l=this.getFoldsInRange(e),this.removeFolds(l),a=-a);u=this.getFoldLine(o);u&&u.addRemoveChars(o,r.column,a)}return t&&this.$wrapData.length!=this.doc.getLength()&&console.error("doc.getLength() and $wrapData.length have to be the same!"),this.$updating=!1,t?this.$updateWrapData(o,s):this.$updateRowLengthCache(o,s),l},e.prototype.$updateRowLengthCache=function(e,t,n){this.$rowLengthCache[e]=null,this.$rowLengthCache[t]=null},e.prototype.$updateWrapData=function(e,t){var n,r,i=this.doc.getAllLines(),o=this.getTabSize(),s=this.$wrapData,a=this.$wrapLimit,l=e;t=Math.min(t,i.length-1);while(l<=t)r=this.getFoldLine(l,r),r?(n=[],r.walk(function(e,t,r,o){var s;if(null!=e){s=this.$getDisplayTokens(e,n.length),s[0]=v;for(var a=1;a<s.length;a++)s[a]=y}else s=this.$getDisplayTokens(i[t].substring(o,r),n.length);n=n.concat(s)}.bind(this),r.end.row,i[r.end.row].length+1),s[r.start.row]=this.$computeWrapSplits(n,a,o),l=r.end.row+1):(n=this.$getDisplayTokens(i[l]),s[l]=this.$computeWrapSplits(n,a,o),l++)},e.prototype.$computeWrapSplits=function(e,t,n){if(0==e.length)return[];var r=[],i=e.length,o=0,s=0,a=this.$wrapAsCode,l=this.$indentedSoftWrap,c=t<=Math.max(2*n,8)||!1===l?0:Math.floor(t/2);function u(){var t=0;if(0===c)return t;if(l)for(var r=0;r<e.length;r++){var i=e[r];if(i==b)t+=1;else{if(i!=x){if(i==S)continue;break}t+=n}}return a&&!1!==l&&(t+=n),Math.min(t,c)}function h(t){for(var n=t-o,i=o;i<t;i++){var a=e[i];12!==a&&2!==a||(n-=1)}r.length||(f=u(),r.indent=f),s+=n,r.push(s),o=t}var f=0;while(i-o>t-f){var d=o+t-f;if(e[d-1]>=b&&e[d]>=b)h(d);else if(e[d]!=v&&e[d]!=y){var p=Math.max(d-(t-(t>>2)),o-1);while(d>p&&e[d]<v)d--;if(a){while(d>p&&e[d]<v)d--;while(d>p&&e[d]==w)d--}else while(d>p&&e[d]<b)d--;d>p?h(++d):(d=o+t,e[d]==m&&d--,h(d-f))}else{for(d;d!=o-1;d--)if(e[d]==v)break;if(d>o){h(d);continue}for(d=o+t,d;d<e.length;d++)if(e[d]!=y)break;if(d==e.length)break;h(d)}}return r},e.prototype.$getDisplayTokens=function(e,t){var n,r=[];t=t||0;for(var i=0;i<e.length;i++){var o=e.charCodeAt(i);if(9==o){n=this.getScreenTabSize(r.length+t),r.push(x);for(var s=1;s<n;s++)r.push(S)}else 32==o?r.push(b):o>39&&o<48||o>57&&o<64?r.push(w):o>=4352&&_(o)?r.push(g,m):r.push(g)}return r},e.prototype.$getStringScreenWidth=function(e,t,n){if(0==t)return[0,0];var r,i;for(null==t&&(t=1/0),n=n||0,i=0;i<e.length;i++)if(r=e.charCodeAt(i),9==r?n+=this.getScreenTabSize(n):r>=4352&&_(r)?n+=2:n+=1,n>t)break;return[n,i]},e.prototype.getRowLength=function(e){var t=1;return this.lineWidgets&&(t+=this.lineWidgets[e]&&this.lineWidgets[e].rowCount||0),this.$useWrapMode&&this.$wrapData[e]?this.$wrapData[e].length+t:t},e.prototype.getRowLineCount=function(e){return this.$useWrapMode&&this.$wrapData[e]?this.$wrapData[e].length+1:1},e.prototype.getRowWrapIndent=function(e){if(this.$useWrapMode){var t=this.screenToDocumentPosition(e,Number.MAX_VALUE),n=this.$wrapData[t.row];return n.length&&n[0]<t.column?n.indent:0}return 0},e.prototype.getScreenLastRowColumn=function(e){var t=this.screenToDocumentPosition(e,Number.MAX_VALUE);return this.documentToScreenColumn(t.row,t.column)},e.prototype.getDocumentLastRowColumn=function(e,t){var n=this.documentToScreenRow(e,t);return this.getScreenLastRowColumn(n)},e.prototype.getDocumentLastRowColumnPosition=function(e,t){var n=this.documentToScreenRow(e,t);return this.screenToDocumentPosition(n,Number.MAX_VALUE/10)},e.prototype.getRowSplitData=function(e){return this.$useWrapMode?this.$wrapData[e]:void 0},e.prototype.getScreenTabSize=function(e){return this.$tabSize-(e%this.$tabSize|0)},e.prototype.screenToDocumentRow=function(e,t){return this.screenToDocumentPosition(e,t).row},e.prototype.screenToDocumentColumn=function(e,t){return this.screenToDocumentPosition(e,t).column},e.prototype.screenToDocumentPosition=function(e,t,n){if(e<0)return{row:0,column:0};var r,i,o=0,s=0,a=0,l=0,c=this.$screenRowCache,u=this.$getRowCacheIndex(c,e),h=c.length;if(h&&u>=0){a=c[u],o=this.$docRowCache[u];var f=e>c[h-1]}else f=!h;var d=this.getLength()-1,p=this.getNextFoldLine(o),g=p?p.start.row:1/0;while(a<=e){if(l=this.getRowLength(o),a+l>e||o>=d)break;a+=l,o++,o>g&&(o=p.end.row+1,p=this.getNextFoldLine(o,p),g=p?p.start.row:1/0),f&&(this.$docRowCache.push(o),this.$screenRowCache.push(a))}if(p&&p.start.row<=o)r=this.getFoldDisplayLine(p),o=p.start.row;else{if(a+l<=e||o>d)return{row:d,column:this.getLine(d).length};r=this.getLine(o),p=null}var m=0,v=Math.floor(e-a);if(this.$useWrapMode){var y=this.$wrapData[o];y&&(i=y[v],v>0&&y.length&&(m=y.indent,s=y[v-1]||y[y.length-1],r=r.substring(s)))}return void 0!==n&&this.$bidiHandler.isBidiRow(a+v,o,v)&&(t=this.$bidiHandler.offsetToCol(n)),s+=this.$getStringScreenWidth(r,t-m)[1],this.$useWrapMode&&s>=i&&(s=i-1),p?p.idxToPosition(s):{row:o,column:s}},e.prototype.documentToScreenPosition=function(e,t){if("undefined"===typeof t)var n=this.$clipPositionToDocument(e.row,e.column);else n=this.$clipPositionToDocument(e,t);e=n.row,t=n.column;var r=0,i=null,o=null;o=this.getFoldAt(e,t,1),o&&(e=o.start.row,t=o.start.column);var s,a=0,l=this.$docRowCache,c=this.$getRowCacheIndex(l,e),u=l.length;if(u&&c>=0){a=l[c],r=this.$screenRowCache[c];var h=e>l[u-1]}else h=!u;var f=this.getNextFoldLine(a),d=f?f.start.row:1/0;while(a<e){if(a>=d){if(s=f.end.row+1,s>e)break;f=this.getNextFoldLine(s,f),d=f?f.start.row:1/0}else s=a+1;r+=this.getRowLength(a),a=s,h&&(this.$docRowCache.push(a),this.$screenRowCache.push(r))}var p="";f&&a>=d?(p=this.getFoldDisplayLine(f,e,t),i=f.start.row):(p=this.getLine(e).substring(0,t),i=e);var g=0;if(this.$useWrapMode){var m=this.$wrapData[i];if(m){var v=0;while(p.length>=m[v])r++,v++;p=p.substring(m[v-1]||0,p.length),g=v>0?m.indent:0}}return this.lineWidgets&&this.lineWidgets[a]&&this.lineWidgets[a].rowsAbove&&(r+=this.lineWidgets[a].rowsAbove),{row:r,column:g+this.$getStringScreenWidth(p)[0]}},e.prototype.documentToScreenColumn=function(e,t){return this.documentToScreenPosition(e,t).column},e.prototype.documentToScreenRow=function(e,t){return this.documentToScreenPosition(e,t).row},e.prototype.getScreenLength=function(){var e=0,t=null;if(this.$useWrapMode){var n=this.$wrapData.length,r=0,i=(a=0,t=this.$foldData[a++],t?t.start.row:1/0);while(r<n){var o=this.$wrapData[r];e+=o?o.length+1:1,r++,r>i&&(r=t.end.row+1,t=this.$foldData[a++],i=t?t.start.row:1/0)}}else{e=this.getLength();for(var s=this.$foldData,a=0;a<s.length;a++)t=s[a],e-=t.end.row-t.start.row}return this.lineWidgets&&(e+=this.$getWidgetScreenLength()),e},e.prototype.$setFontMetrics=function(e){this.$enableVarChar&&(this.$getStringScreenWidth=function(t,n,r){if(0===n)return[0,0];var i,o;for(n||(n=1/0),r=r||0,o=0;o<t.length;o++)if(i=t.charAt(o),r+="\t"===i?this.getScreenTabSize(r):e.getCharacterWidth(i),r>n)break;return[r,o]})},e.prototype.destroy=function(){this.destroyed||(this.bgTokenizer.setDocument(null),this.bgTokenizer.cleanup(),this.destroyed=!0),this.$stopWorker(),this.removeAllListeners(),this.doc&&this.doc.off("change",this.$onChange),this.selection.detach()},e}();p.$uid=0,p.prototype.$modes=s.$modes,p.prototype.getValue=p.prototype.toString,p.prototype.$defaultUndoManager={undo:function(){},redo:function(){},hasUndo:function(){},hasRedo:function(){},reset:function(){},add:function(){},addSelection:function(){},startNewGroup:function(){},addSession:function(){}},p.prototype.$overwrite=!1,p.prototype.$mode=null,p.prototype.$modeId=null,p.prototype.$scrollTop=0,p.prototype.$scrollLeft=0,p.prototype.$wrapLimit=80,p.prototype.$useWrapMode=!1,p.prototype.$wrapLimitRange={min:null,max:null},p.prototype.lineWidgets=null,p.prototype.isFullWidth=_,r.implement(p.prototype,a);var g=1,m=2,v=3,y=4,w=9,b=10,x=11,S=12;function _(e){return!(e<4352)&&(e>=4352&&e<=4447||e>=4515&&e<=4519||e>=4602&&e<=4607||e>=9001&&e<=9002||e>=11904&&e<=11929||e>=11931&&e<=12019||e>=12032&&e<=12245||e>=12272&&e<=12283||e>=12288&&e<=12350||e>=12353&&e<=12438||e>=12441&&e<=12543||e>=12549&&e<=12589||e>=12593&&e<=12686||e>=12688&&e<=12730||e>=12736&&e<=12771||e>=12784&&e<=12830||e>=12832&&e<=12871||e>=12880&&e<=13054||e>=13056&&e<=19903||e>=19968&&e<=42124||e>=42128&&e<=42182||e>=43360&&e<=43388||e>=44032&&e<=55203||e>=55216&&e<=55238||e>=55243&&e<=55291||e>=63744&&e<=64255||e>=65040&&e<=65049||e>=65072&&e<=65106||e>=65108&&e<=65126||e>=65128&&e<=65131||e>=65281&&e<=65376||e>=65504&&e<=65510)}e("./edit_session/folding").Folding.call(p.prototype),e("./edit_session/bracket_match").BracketMatch.call(p.prototype),s.defineOptions(p.prototype,"session",{wrap:{set:function(e){if(e&&"off"!=e?"free"==e?e=!0:"printMargin"==e?e=-1:"string"==typeof e&&(e=parseInt(e,10)||!1):e=!1,this.$wrap!=e)if(this.$wrap=e,e){var t="number"==typeof e?e:null;this.setWrapLimitRange(t,t),this.setUseWrapMode(!0)}else this.setUseWrapMode(!1)},get:function(){return this.getUseWrapMode()?-1==this.$wrap?"printMargin":this.getWrapLimitRange().min?this.$wrap:"free":"off"},handlesSet:!0},wrapMethod:{set:function(e){e="auto"==e?"text"!=this.$mode.type:"text"!=e,e!=this.$wrapAsCode&&(this.$wrapAsCode=e,this.$useWrapMode&&(this.$useWrapMode=!1,this.setUseWrapMode(!0)))},initialValue:"auto"},indentedSoftWrap:{set:function(){this.$useWrapMode&&(this.$useWrapMode=!1,this.setUseWrapMode(!0))},initialValue:!0},firstLineNumber:{set:function(){this._signal("changeBreakpoint")},initialValue:1},useWorker:{set:function(e){this.$useWorker=e,this.$stopWorker(),e&&this.$startWorker()},initialValue:!0},useSoftTabs:{initialValue:!0},tabSize:{set:function(e){e=parseInt(e),e>0&&this.$tabSize!==e&&(this.$modified=!0,this.$rowLengthCache=[],this.$tabSize=e,this._signal("changeTabSize"))},initialValue:4,handlesSet:!0},navigateWithinSoftTabs:{initialValue:!1},foldStyle:{set:function(e){this.setFoldStyle(e)},handlesSet:!0},overwrite:{set:function(e){this._signal("changeOverwrite")},initialValue:!1},newLineMode:{set:function(e){this.doc.setNewLineMode(e)},get:function(){return this.doc.getNewLineMode()},handlesSet:!0},mode:{set:function(e){this.setMode(e)},get:function(){return this.$modeId},handlesSet:!0}}),t.EditSession=p})),ace.define("ace/search",["require","exports","module","ace/lib/lang","ace/lib/oop","ace/range"],(function(e,t,n){"use strict";var r=e("./lib/lang"),i=e("./lib/oop"),o=e("./range").Range,s=function(){function e(){this.$options={}}return e.prototype.set=function(e){return i.mixin(this.$options,e),this},e.prototype.getOptions=function(){return r.copyObject(this.$options)},e.prototype.setOptions=function(e){this.$options=e},e.prototype.find=function(e){var t=this.$options,n=this.$matchIterator(e,t);if(!n)return!1;var r=null;return n.forEach((function(e,n,i,s){return r=new o(e,n,i,s),!(n==s&&t.start&&t.start.start&&0!=t.skipCurrent&&r.isEqual(t.start))||(r=null,!1)})),r},e.prototype.findAll=function(e){var t=this.$options;if(!t.needle)return[];this.$assembleRegExp(t);var n=t.range,i=n?e.getLines(n.start.row,n.end.row):e.doc.getAllLines(),s=[],a=t.re;if(t.$isMultiLine){var l,c=a.length,u=i.length-c;e:for(var h=a.offset||0;h<=u;h++){for(var f=0;f<c;f++)if(-1==i[h+f].search(a[f]))continue e;var d=i[h],p=i[h+c-1],g=d.length-d.match(a[0])[0].length,m=p.match(a[c-1])[0].length;l&&l.end.row===h&&l.end.column>g||(s.push(l=new o(h,g,h+c-1,m)),c>2&&(h=h+c-2))}}else for(var v=0;v<i.length;v++){var y=r.getMatchOffsets(i[v],a);for(f=0;f<y.length;f++){var w=y[f];s.push(new o(v,w.offset,v,w.offset+w.length))}}if(n){var b=n.start.column,x=n.end.column;v=0,f=s.length-1;while(v<f&&s[v].start.column<b&&0==s[v].start.row)v++;var S=n.end.row-n.start.row;while(v<f&&s[f].end.column>x&&s[f].end.row==S)f--;for(s=s.slice(v,f+1),v=0,f=s.length;v<f;v++)s[v].start.row+=n.start.row,s[v].end.row+=n.start.row}return s},e.prototype.replace=function(e,t){var n=this.$options,r=this.$assembleRegExp(n);if(n.$isMultiLine)return t;if(r){var i=r.exec(e);if(!i||i[0].length!=e.length)return null;if(t=e.replace(r,t),n.preserveCase){t=t.split("");for(var o=Math.min(e.length,e.length);o--;){var s=e[o];s&&s.toLowerCase()!=s?t[o]=t[o].toUpperCase():t[o]=t[o].toLowerCase()}t=t.join("")}return t}},e.prototype.$assembleRegExp=function(e,t){if(e.needle instanceof RegExp)return e.re=e.needle;var n=e.needle;if(!e.needle)return e.re=!1;e.regExp||(n=r.escapeRegExp(n)),e.wholeWord&&(n=a(n,e));var i=e.caseSensitive?"gm":"gmi";if(e.$isMultiLine=!t&&/[\n\r]/.test(n),e.$isMultiLine)return e.re=this.$assembleMultilineRegExp(n,i);try{var o=new RegExp(n,i)}catch(s){o=!1}return e.re=o},e.prototype.$assembleMultilineRegExp=function(e,t){for(var n=e.replace(/\r\n|\r|\n/g,"$\n^").split("\n"),r=[],i=0;i<n.length;i++)try{r.push(new RegExp(n[i],t))}catch(o){return!1}return r},e.prototype.$matchIterator=function(e,t){var n=this.$assembleRegExp(t);if(!n)return!1;var r=1==t.backwards,i=0!=t.skipCurrent,o=t.range,s=t.start;s||(s=o?o[r?"end":"start"]:e.selection.getRange()),s.start&&(s=s[i!=r?"end":"start"]);var a=o?o.start.row:0,l=o?o.end.row:e.getLength()-1;if(r)var c=function(e){var n=s.row;if(!h(n,s.column,e)){for(n--;n>=a;n--)if(h(n,Number.MAX_VALUE,e))return;if(0!=t.wrap)for(n=l,a=s.row;n>=a;n--)if(h(n,Number.MAX_VALUE,e))return}};else c=function(e){var n=s.row;if(!h(n,s.column,e)){for(n+=1;n<=l;n++)if(h(n,0,e))return;if(0!=t.wrap)for(n=a,l=s.row;n<=l;n++)if(h(n,0,e))return}};if(t.$isMultiLine)var u=n.length,h=function(t,i,o){var s=r?t-u+1:t;if(!(s<0||s+u>e.getLength())){var a=e.getLine(s),l=a.search(n[0]);if(!(!r&&l<i||-1===l)){for(var c=1;c<u;c++)if(a=e.getLine(s+c),-1==a.search(n[c]))return;var h=a.match(n[u-1])[0].length;if(!(r&&h>i))return!!o(s,l,s+u-1,h)||void 0}}};else if(r)h=function(t,r,i){var o,s=e.getLine(t),a=[],l=0;n.lastIndex=0;while(o=n.exec(s)){var c=o[0].length;if(l=o.index,!c){if(l>=s.length)break;n.lastIndex=l+=1}if(o.index+c>r)break;a.push(o.index,c)}for(var u=a.length-1;u>=0;u-=2){var h=a[u-1];c=a[u];if(i(t,h,t,h+c))return!0}};else h=function(t,r,i){var o,s,a=e.getLine(t);n.lastIndex=r;while(s=n.exec(a)){var l=s[0].length;if(o=s.index,i(t,o,t,o+l))return!0;if(!l&&(n.lastIndex=o+=1,o>=a.length))return!1}};return{forEach:c}},e}();function a(e,t){function n(e){return/\w/.test(e)||t.regExp?"\\b":""}return n(e[0])+e+n(e[e.length-1])}t.Search=s})),ace.define("ace/keyboard/hash_handler",["require","exports","module","ace/lib/keys","ace/lib/useragent"],(function(e,t,n){"use strict";var r=e("../lib/keys"),i=e("../lib/useragent"),o=r.KEY_MODS;function s(e,t){this.platform=t||(i.isMac?"mac":"win"),this.commands={},this.commandKeyBinding={},this.addCommands(e),this.$singleCommand=!0}function a(e,t){s.call(this,e,t),this.$singleCommand=!1}a.prototype=s.prototype,function(){function e(e){return"object"==typeof e&&e.bindKey&&e.bindKey.position||(e.isDefault?-100:0)}this.addCommand=function(e){this.commands[e.name]&&this.removeCommand(e),this.commands[e.name]=e,e.bindKey&&this._buildKeyHash(e)},this.removeCommand=function(e,t){var n=e&&("string"===typeof e?e:e.name);e=this.commands[n],t||delete this.commands[n];var r=this.commandKeyBinding;for(var i in r){var o=r[i];if(o==e)delete r[i];else if(Array.isArray(o)){var s=o.indexOf(e);-1!=s&&(o.splice(s,1),1==o.length&&(r[i]=o[0]))}}},this.bindKey=function(e,t,n){if("object"==typeof e&&e&&(void 0==n&&(n=e.position),e=e[this.platform]),e)return"function"==typeof t?this.addCommand({exec:t,bindKey:e,name:t.name||e}):void e.split("|").forEach((function(e){var r="";if(-1!=e.indexOf(" ")){var i=e.split(/\s+/);e=i.pop(),i.forEach((function(e){var t=this.parseKeys(e),n=o[t.hashId]+t.key;r+=(r?" ":"")+n,this._addCommandToBinding(r,"chainKeys")}),this),r+=" "}var s=this.parseKeys(e),a=o[s.hashId]+s.key;this._addCommandToBinding(r+a,t,n)}),this)},this._addCommandToBinding=function(t,n,r){var i,o=this.commandKeyBinding;if(n)if(!o[t]||this.$singleCommand)o[t]=n;else{Array.isArray(o[t])?-1!=(i=o[t].indexOf(n))&&o[t].splice(i,1):o[t]=[o[t]],"number"!=typeof r&&(r=e(n));var s=o[t];for(i=0;i<s.length;i++){var a=s[i],l=e(a);if(l>r)break}s.splice(i,0,n)}else delete o[t]},this.addCommands=function(e){e&&Object.keys(e).forEach((function(t){var n=e[t];if(n){if("string"===typeof n)return this.bindKey(n,t);"function"===typeof n&&(n={exec:n}),"object"===typeof n&&(n.name||(n.name=t),this.addCommand(n))}}),this)},this.removeCommands=function(e){Object.keys(e).forEach((function(t){this.removeCommand(e[t])}),this)},this.bindKeys=function(e){Object.keys(e).forEach((function(t){this.bindKey(t,e[t])}),this)},this._buildKeyHash=function(e){this.bindKey(e.bindKey,e)},this.parseKeys=function(e){var t=e.toLowerCase().split(/[\-\+]([\-\+])?/).filter((function(e){return e})),n=t.pop(),i=r[n];if(r.FUNCTION_KEYS[i])n=r.FUNCTION_KEYS[i].toLowerCase();else{if(!t.length)return{key:n,hashId:-1};if(1==t.length&&"shift"==t[0])return{key:n.toUpperCase(),hashId:-1}}for(var o=0,s=t.length;s--;){var a=r.KEY_MODS[t[s]];if(null==a)return"undefined"!=typeof console&&console.error("invalid modifier "+t[s]+" in "+e),!1;o|=a}return{key:n,hashId:o}},this.findKeyCommand=function(e,t){var n=o[e]+t;return this.commandKeyBinding[n]},this.handleKeyboard=function(e,t,n,r){if(!(r<0)){var i=o[t]+n,s=this.commandKeyBinding[i];return e.$keyChain&&(e.$keyChain+=" "+i,s=this.commandKeyBinding[e.$keyChain]||s),!s||"chainKeys"!=s&&"chainKeys"!=s[s.length-1]?(e.$keyChain&&(t&&4!=t||1!=n.length?(-1==t||r>0)&&(e.$keyChain=""):e.$keyChain=e.$keyChain.slice(0,-i.length-1)),{command:s}):(e.$keyChain=e.$keyChain||i,{command:"null"})}},this.getStatusText=function(e,t){return t.$keyChain||""}}.call(s.prototype),t.HashHandler=s,t.MultiHashHandler=a})),ace.define("ace/commands/command_manager",["require","exports","module","ace/lib/oop","ace/keyboard/hash_handler","ace/lib/event_emitter"],(function(e,t,n){"use strict";var r=this&&this.__extends||function(){var e=function(t,n){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])},e(t,n)};return function(t,n){if("function"!==typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function r(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),i=e("../lib/oop"),o=e("../keyboard/hash_handler").MultiHashHandler,s=e("../lib/event_emitter").EventEmitter,a=function(e){function t(t,n){var r=e.call(this,n,t)||this;return r.byName=r.commands,r.setDefaultHandler("exec",(function(e){return e.args?e.command.exec(e.editor,e.args,e.event,!1):e.command.exec(e.editor,{},e.event,!0)})),r}return r(t,e),t.prototype.exec=function(e,t,n){if(Array.isArray(e)){for(var r=e.length;r--;)if(this.exec(e[r],t,n))return!0;return!1}if("string"===typeof e&&(e=this.commands[e]),!e)return!1;if(t&&t.$readOnly&&!e.readOnly)return!1;if(0!=this.$checkCommandState&&e.isAvailable&&!e.isAvailable(t))return!1;var i={editor:t,command:e,args:n};return i.returnValue=this._emit("exec",i),this._signal("afterExec",i),!1!==i.returnValue},t.prototype.toggleRecording=function(e){if(!this.$inReplay)return e&&e._emit("changeStatus"),this.recording?(this.macro.pop(),this.off("exec",this.$addCommandToMacro),this.macro.length||(this.macro=this.oldMacro),this.recording=!1):(this.$addCommandToMacro||(this.$addCommandToMacro=function(e){this.macro.push([e.command,e.args])}.bind(this)),this.oldMacro=this.macro,this.macro=[],this.on("exec",this.$addCommandToMacro),this.recording=!0)},t.prototype.replay=function(e){if(!this.$inReplay&&this.macro){if(this.recording)return this.toggleRecording(e);try{this.$inReplay=!0,this.macro.forEach((function(t){"string"==typeof t?this.exec(t,e):this.exec(t[0],e,t[1])}),this)}finally{this.$inReplay=!1}}},t.prototype.trimMacro=function(e){return e.map((function(e){return"string"!=typeof e[0]&&(e[0]=e[0].name),e[1]||(e=e[0]),e}))},t}(o);i.implement(a.prototype,s),t.CommandManager=a})),ace.define("ace/commands/default_commands",["require","exports","module","ace/lib/lang","ace/config","ace/range"],(function(e,t,n){"use strict";var r=e("../lib/lang"),i=e("../config"),o=e("../range").Range;function s(e,t){return{win:e,mac:t}}t.commands=[{name:"showSettingsMenu",description:"Show settings menu",bindKey:s("Ctrl-,","Command-,"),exec:function(e){i.loadModule("ace/ext/settings_menu",(function(t){t.init(e),e.showSettingsMenu()}))},readOnly:!0},{name:"goToNextError",description:"Go to next error",bindKey:s("Alt-E","F4"),exec:function(e){i.loadModule("ace/ext/error_marker",(function(t){t.showErrorMarker(e,1)}))},scrollIntoView:"animate",readOnly:!0},{name:"goToPreviousError",description:"Go to previous error",bindKey:s("Alt-Shift-E","Shift-F4"),exec:function(e){i.loadModule("ace/ext/error_marker",(function(t){t.showErrorMarker(e,-1)}))},scrollIntoView:"animate",readOnly:!0},{name:"selectall",description:"Select all",bindKey:s("Ctrl-A","Command-A"),exec:function(e){e.selectAll()},readOnly:!0},{name:"centerselection",description:"Center selection",bindKey:s(null,"Ctrl-L"),exec:function(e){e.centerSelection()},readOnly:!0},{name:"gotoline",description:"Go to line...",bindKey:s("Ctrl-L","Command-L"),exec:function(e,t){"number"!==typeof t||isNaN(t)||e.gotoLine(t),e.prompt({$type:"gotoLine"})},readOnly:!0},{name:"fold",bindKey:s("Alt-L|Ctrl-F1","Command-Alt-L|Command-F1"),exec:function(e){e.session.toggleFold(!1)},multiSelectAction:"forEach",scrollIntoView:"center",readOnly:!0},{name:"unfold",bindKey:s("Alt-Shift-L|Ctrl-Shift-F1","Command-Alt-Shift-L|Command-Shift-F1"),exec:function(e){e.session.toggleFold(!0)},multiSelectAction:"forEach",scrollIntoView:"center",readOnly:!0},{name:"toggleFoldWidget",description:"Toggle fold widget",bindKey:s("F2","F2"),exec:function(e){e.session.toggleFoldWidget()},multiSelectAction:"forEach",scrollIntoView:"center",readOnly:!0},{name:"toggleParentFoldWidget",description:"Toggle parent fold widget",bindKey:s("Alt-F2","Alt-F2"),exec:function(e){e.session.toggleFoldWidget(!0)},multiSelectAction:"forEach",scrollIntoView:"center",readOnly:!0},{name:"foldall",description:"Fold all",bindKey:s(null,"Ctrl-Command-Option-0"),exec:function(e){e.session.foldAll()},scrollIntoView:"center",readOnly:!0},{name:"foldAllComments",description:"Fold all comments",bindKey:s(null,"Ctrl-Command-Option-0"),exec:function(e){e.session.foldAllComments()},scrollIntoView:"center",readOnly:!0},{name:"foldOther",description:"Fold other",bindKey:s("Alt-0","Command-Option-0"),exec:function(e){e.session.foldAll(),e.session.unfold(e.selection.getAllRanges())},scrollIntoView:"center",readOnly:!0},{name:"unfoldall",description:"Unfold all",bindKey:s("Alt-Shift-0","Command-Option-Shift-0"),exec:function(e){e.session.unfold()},scrollIntoView:"center",readOnly:!0},{name:"findnext",description:"Find next",bindKey:s("Ctrl-K","Command-G"),exec:function(e){e.findNext()},multiSelectAction:"forEach",scrollIntoView:"center",readOnly:!0},{name:"findprevious",description:"Find previous",bindKey:s("Ctrl-Shift-K","Command-Shift-G"),exec:function(e){e.findPrevious()},multiSelectAction:"forEach",scrollIntoView:"center",readOnly:!0},{name:"selectOrFindNext",description:"Select or find next",bindKey:s("Alt-K","Ctrl-G"),exec:function(e){e.selection.isEmpty()?e.selection.selectWord():e.findNext()},readOnly:!0},{name:"selectOrFindPrevious",description:"Select or find previous",bindKey:s("Alt-Shift-K","Ctrl-Shift-G"),exec:function(e){e.selection.isEmpty()?e.selection.selectWord():e.findPrevious()},readOnly:!0},{name:"find",description:"Find",bindKey:s("Ctrl-F","Command-F"),exec:function(e){i.loadModule("ace/ext/searchbox",(function(t){t.Search(e)}))},readOnly:!0},{name:"overwrite",description:"Overwrite",bindKey:"Insert",exec:function(e){e.toggleOverwrite()},readOnly:!0},{name:"selecttostart",description:"Select to start",bindKey:s("Ctrl-Shift-Home","Command-Shift-Home|Command-Shift-Up"),exec:function(e){e.getSelection().selectFileStart()},multiSelectAction:"forEach",readOnly:!0,scrollIntoView:"animate",aceCommandGroup:"fileJump"},{name:"gotostart",description:"Go to start",bindKey:s("Ctrl-Home","Command-Home|Command-Up"),exec:function(e){e.navigateFileStart()},multiSelectAction:"forEach",readOnly:!0,scrollIntoView:"animate",aceCommandGroup:"fileJump"},{name:"selectup",description:"Select up",bindKey:s("Shift-Up","Shift-Up|Ctrl-Shift-P"),exec:function(e){e.getSelection().selectUp()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"golineup",description:"Go line up",bindKey:s("Up","Up|Ctrl-P"),exec:function(e,t){e.navigateUp(t.times)},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selecttoend",description:"Select to end",bindKey:s("Ctrl-Shift-End","Command-Shift-End|Command-Shift-Down"),exec:function(e){e.getSelection().selectFileEnd()},multiSelectAction:"forEach",readOnly:!0,scrollIntoView:"animate",aceCommandGroup:"fileJump"},{name:"gotoend",description:"Go to end",bindKey:s("Ctrl-End","Command-End|Command-Down"),exec:function(e){e.navigateFileEnd()},multiSelectAction:"forEach",readOnly:!0,scrollIntoView:"animate",aceCommandGroup:"fileJump"},{name:"selectdown",description:"Select down",bindKey:s("Shift-Down","Shift-Down|Ctrl-Shift-N"),exec:function(e){e.getSelection().selectDown()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"golinedown",description:"Go line down",bindKey:s("Down","Down|Ctrl-N"),exec:function(e,t){e.navigateDown(t.times)},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectwordleft",description:"Select word left",bindKey:s("Ctrl-Shift-Left","Option-Shift-Left"),exec:function(e){e.getSelection().selectWordLeft()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotowordleft",description:"Go to word left",bindKey:s("Ctrl-Left","Option-Left"),exec:function(e){e.navigateWordLeft()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selecttolinestart",description:"Select to line start",bindKey:s("Alt-Shift-Left","Command-Shift-Left|Ctrl-Shift-A"),exec:function(e){e.getSelection().selectLineStart()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotolinestart",description:"Go to line start",bindKey:s("Alt-Left|Home","Command-Left|Home|Ctrl-A"),exec:function(e){e.navigateLineStart()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectleft",description:"Select left",bindKey:s("Shift-Left","Shift-Left|Ctrl-Shift-B"),exec:function(e){e.getSelection().selectLeft()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotoleft",description:"Go to left",bindKey:s("Left","Left|Ctrl-B"),exec:function(e,t){e.navigateLeft(t.times)},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectwordright",description:"Select word right",bindKey:s("Ctrl-Shift-Right","Option-Shift-Right"),exec:function(e){e.getSelection().selectWordRight()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotowordright",description:"Go to word right",bindKey:s("Ctrl-Right","Option-Right"),exec:function(e){e.navigateWordRight()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selecttolineend",description:"Select to line end",bindKey:s("Alt-Shift-Right","Command-Shift-Right|Shift-End|Ctrl-Shift-E"),exec:function(e){e.getSelection().selectLineEnd()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotolineend",description:"Go to line end",bindKey:s("Alt-Right|End","Command-Right|End|Ctrl-E"),exec:function(e){e.navigateLineEnd()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectright",description:"Select right",bindKey:s("Shift-Right","Shift-Right"),exec:function(e){e.getSelection().selectRight()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotoright",description:"Go to right",bindKey:s("Right","Right|Ctrl-F"),exec:function(e,t){e.navigateRight(t.times)},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectpagedown",description:"Select page down",bindKey:"Shift-PageDown",exec:function(e){e.selectPageDown()},readOnly:!0},{name:"pagedown",description:"Page down",bindKey:s(null,"Option-PageDown"),exec:function(e){e.scrollPageDown()},readOnly:!0},{name:"gotopagedown",description:"Go to page down",bindKey:s("PageDown","PageDown|Ctrl-V"),exec:function(e){e.gotoPageDown()},readOnly:!0},{name:"selectpageup",description:"Select page up",bindKey:"Shift-PageUp",exec:function(e){e.selectPageUp()},readOnly:!0},{name:"pageup",description:"Page up",bindKey:s(null,"Option-PageUp"),exec:function(e){e.scrollPageUp()},readOnly:!0},{name:"gotopageup",description:"Go to page up",bindKey:"PageUp",exec:function(e){e.gotoPageUp()},readOnly:!0},{name:"scrollup",description:"Scroll up",bindKey:s("Ctrl-Up",null),exec:function(e){e.renderer.scrollBy(0,-2*e.renderer.layerConfig.lineHeight)},readOnly:!0},{name:"scrolldown",description:"Scroll down",bindKey:s("Ctrl-Down",null),exec:function(e){e.renderer.scrollBy(0,2*e.renderer.layerConfig.lineHeight)},readOnly:!0},{name:"selectlinestart",description:"Select line start",bindKey:"Shift-Home",exec:function(e){e.getSelection().selectLineStart()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectlineend",description:"Select line end",bindKey:"Shift-End",exec:function(e){e.getSelection().selectLineEnd()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"togglerecording",description:"Toggle recording",bindKey:s("Ctrl-Alt-E","Command-Option-E"),exec:function(e){e.commands.toggleRecording(e)},readOnly:!0},{name:"replaymacro",description:"Replay macro",bindKey:s("Ctrl-Shift-E","Command-Shift-E"),exec:function(e){e.commands.replay(e)},readOnly:!0},{name:"jumptomatching",description:"Jump to matching",bindKey:s("Ctrl-\\|Ctrl-P","Command-\\"),exec:function(e){e.jumpToMatching()},multiSelectAction:"forEach",scrollIntoView:"animate",readOnly:!0},{name:"selecttomatching",description:"Select to matching",bindKey:s("Ctrl-Shift-\\|Ctrl-Shift-P","Command-Shift-\\"),exec:function(e){e.jumpToMatching(!0)},multiSelectAction:"forEach",scrollIntoView:"animate",readOnly:!0},{name:"expandToMatching",description:"Expand to matching",bindKey:s("Ctrl-Shift-M","Ctrl-Shift-M"),exec:function(e){e.jumpToMatching(!0,!0)},multiSelectAction:"forEach",scrollIntoView:"animate",readOnly:!0},{name:"passKeysToBrowser",description:"Pass keys to browser",bindKey:s(null,null),exec:function(){},passEvent:!0,readOnly:!0},{name:"copy",description:"Copy",exec:function(e){},readOnly:!0},{name:"cut",description:"Cut",exec:function(e){var t=e.$copyWithEmptySelection&&e.selection.isEmpty(),n=t?e.selection.getLineRange():e.selection.getRange();e._emit("cut",n),n.isEmpty()||e.session.remove(n),e.clearSelection()},scrollIntoView:"cursor",multiSelectAction:"forEach"},{name:"paste",description:"Paste",exec:function(e,t){e.$handlePaste(t)},scrollIntoView:"cursor"},{name:"removeline",description:"Remove line",bindKey:s("Ctrl-D","Command-D"),exec:function(e){e.removeLines()},scrollIntoView:"cursor",multiSelectAction:"forEachLine"},{name:"duplicateSelection",description:"Duplicate selection",bindKey:s("Ctrl-Shift-D","Command-Shift-D"),exec:function(e){e.duplicateSelection()},scrollIntoView:"cursor",multiSelectAction:"forEach"},{name:"sortlines",description:"Sort lines",bindKey:s("Ctrl-Alt-S","Command-Alt-S"),exec:function(e){e.sortLines()},scrollIntoView:"selection",multiSelectAction:"forEachLine"},{name:"togglecomment",description:"Toggle comment",bindKey:s("Ctrl-/","Command-/"),exec:function(e){e.toggleCommentLines()},multiSelectAction:"forEachLine",scrollIntoView:"selectionPart"},{name:"toggleBlockComment",description:"Toggle block comment",bindKey:s("Ctrl-Shift-/","Command-Shift-/"),exec:function(e){e.toggleBlockComment()},multiSelectAction:"forEach",scrollIntoView:"selectionPart"},{name:"modifyNumberUp",description:"Modify number up",bindKey:s("Ctrl-Shift-Up","Alt-Shift-Up"),exec:function(e){e.modifyNumber(1)},scrollIntoView:"cursor",multiSelectAction:"forEach"},{name:"modifyNumberDown",description:"Modify number down",bindKey:s("Ctrl-Shift-Down","Alt-Shift-Down"),exec:function(e){e.modifyNumber(-1)},scrollIntoView:"cursor",multiSelectAction:"forEach"},{name:"replace",description:"Replace",bindKey:s("Ctrl-H","Command-Option-F"),exec:function(e){i.loadModule("ace/ext/searchbox",(function(t){t.Search(e,!0)}))}},{name:"undo",description:"Undo",bindKey:s("Ctrl-Z","Command-Z"),exec:function(e){e.undo()}},{name:"redo",description:"Redo",bindKey:s("Ctrl-Shift-Z|Ctrl-Y","Command-Shift-Z|Command-Y"),exec:function(e){e.redo()}},{name:"copylinesup",description:"Copy lines up",bindKey:s("Alt-Shift-Up","Command-Option-Up"),exec:function(e){e.copyLinesUp()},scrollIntoView:"cursor"},{name:"movelinesup",description:"Move lines up",bindKey:s("Alt-Up","Option-Up"),exec:function(e){e.moveLinesUp()},scrollIntoView:"cursor"},{name:"copylinesdown",description:"Copy lines down",bindKey:s("Alt-Shift-Down","Command-Option-Down"),exec:function(e){e.copyLinesDown()},scrollIntoView:"cursor"},{name:"movelinesdown",description:"Move lines down",bindKey:s("Alt-Down","Option-Down"),exec:function(e){e.moveLinesDown()},scrollIntoView:"cursor"},{name:"del",description:"Delete",bindKey:s("Delete","Delete|Ctrl-D|Shift-Delete"),exec:function(e){e.remove("right")},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"backspace",description:"Backspace",bindKey:s("Shift-Backspace|Backspace","Ctrl-Backspace|Shift-Backspace|Backspace|Ctrl-H"),exec:function(e){e.remove("left")},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"cut_or_delete",description:"Cut or delete",bindKey:s("Shift-Delete",null),exec:function(e){if(!e.selection.isEmpty())return!1;e.remove("left")},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"removetolinestart",description:"Remove to line start",bindKey:s("Alt-Backspace","Command-Backspace"),exec:function(e){e.removeToLineStart()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"removetolineend",description:"Remove to line end",bindKey:s("Alt-Delete","Ctrl-K|Command-Delete"),exec:function(e){e.removeToLineEnd()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"removetolinestarthard",description:"Remove to line start hard",bindKey:s("Ctrl-Shift-Backspace",null),exec:function(e){var t=e.selection.getRange();t.start.column=0,e.session.remove(t)},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"removetolineendhard",description:"Remove to line end hard",bindKey:s("Ctrl-Shift-Delete",null),exec:function(e){var t=e.selection.getRange();t.end.column=Number.MAX_VALUE,e.session.remove(t)},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"removewordleft",description:"Remove word left",bindKey:s("Ctrl-Backspace","Alt-Backspace|Ctrl-Alt-Backspace"),exec:function(e){e.removeWordLeft()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"removewordright",description:"Remove word right",bindKey:s("Ctrl-Delete","Alt-Delete"),exec:function(e){e.removeWordRight()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"outdent",description:"Outdent",bindKey:s("Shift-Tab","Shift-Tab"),exec:function(e){e.blockOutdent()},multiSelectAction:"forEach",scrollIntoView:"selectionPart"},{name:"indent",description:"Indent",bindKey:s("Tab","Tab"),exec:function(e){e.indent()},multiSelectAction:"forEach",scrollIntoView:"selectionPart"},{name:"blockoutdent",description:"Block outdent",bindKey:s("Ctrl-[","Ctrl-["),exec:function(e){e.blockOutdent()},multiSelectAction:"forEachLine",scrollIntoView:"selectionPart"},{name:"blockindent",description:"Block indent",bindKey:s("Ctrl-]","Ctrl-]"),exec:function(e){e.blockIndent()},multiSelectAction:"forEachLine",scrollIntoView:"selectionPart"},{name:"insertstring",description:"Insert string",exec:function(e,t){e.insert(t)},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"inserttext",description:"Insert text",exec:function(e,t){e.insert(r.stringRepeat(t.text||"",t.times||1))},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"splitline",description:"Split line",bindKey:s(null,"Ctrl-O"),exec:function(e){e.splitLine()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"transposeletters",description:"Transpose letters",bindKey:s("Alt-Shift-X","Ctrl-T"),exec:function(e){e.transposeLetters()},multiSelectAction:function(e){e.transposeSelections(1)},scrollIntoView:"cursor"},{name:"touppercase",description:"To uppercase",bindKey:s("Ctrl-U","Ctrl-U"),exec:function(e){e.toUpperCase()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"tolowercase",description:"To lowercase",bindKey:s("Ctrl-Shift-U","Ctrl-Shift-U"),exec:function(e){e.toLowerCase()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"autoindent",description:"Auto Indent",bindKey:s(null,null),exec:function(e){e.autoIndent()},multiSelectAction:"forEachLine",scrollIntoView:"animate"},{name:"expandtoline",description:"Expand to line",bindKey:s("Ctrl-Shift-L","Command-Shift-L"),exec:function(e){var t=e.selection.getRange();t.start.column=t.end.column=0,t.end.row++,e.selection.setRange(t,!1)},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"openlink",bindKey:s("Ctrl+F3","F3"),exec:function(e){e.openLink()}},{name:"joinlines",description:"Join lines",bindKey:s(null,null),exec:function(e){for(var t=e.selection.isBackwards(),n=t?e.selection.getSelectionLead():e.selection.getSelectionAnchor(),i=t?e.selection.getSelectionAnchor():e.selection.getSelectionLead(),s=e.session.doc.getLine(n.row).length,a=e.session.doc.getTextRange(e.selection.getRange()),l=a.replace(/\n\s*/," ").length,c=e.session.doc.getLine(n.row),u=n.row+1;u<=i.row+1;u++){var h=r.stringTrimLeft(r.stringTrimRight(e.session.doc.getLine(u)));0!==h.length&&(h=" "+h),c+=h}i.row+1<e.session.doc.getLength()-1&&(c+=e.session.doc.getNewLineCharacter()),e.clearSelection(),e.session.doc.replace(new o(n.row,0,i.row+2,0),c),l>0?(e.selection.moveCursorTo(n.row,n.column),e.selection.selectTo(n.row,n.column+l)):(s=e.session.doc.getLine(n.row).length>s?s+1:s,e.selection.moveCursorTo(n.row,s))},multiSelectAction:"forEach",readOnly:!0},{name:"invertSelection",description:"Invert selection",bindKey:s(null,null),exec:function(e){var t=e.session.doc.getLength()-1,n=e.session.doc.getLine(t).length,r=e.selection.rangeList.ranges,i=[];r.length<1&&(r=[e.selection.getRange()]);for(var s=0;s<r.length;s++)s==r.length-1&&(r[s].end.row===t&&r[s].end.column===n||i.push(new o(r[s].end.row,r[s].end.column,t,n))),0===s?0===r[s].start.row&&0===r[s].start.column||i.push(new o(0,0,r[s].start.row,r[s].start.column)):i.push(new o(r[s-1].end.row,r[s-1].end.column,r[s].start.row,r[s].start.column));e.exitMultiSelectMode(),e.clearSelection();for(s=0;s<i.length;s++)e.selection.addRange(i[s],!1)},readOnly:!0,scrollIntoView:"none"},{name:"addLineAfter",description:"Add new line after the current line",exec:function(e){e.selection.clearSelection(),e.navigateLineEnd(),e.insert("\n")},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"addLineBefore",description:"Add new line before the current line",exec:function(e){e.selection.clearSelection();var t=e.getCursorPosition();e.selection.moveTo(t.row-1,Number.MAX_VALUE),e.insert("\n"),0===t.row&&e.navigateUp()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"openCommandPallete",description:"Open command palette",bindKey:s("F1","F1"),exec:function(e){e.prompt({$type:"commands"})},readOnly:!0},{name:"modeSelect",description:"Change language mode...",bindKey:s(null,null),exec:function(e){e.prompt({$type:"modes"})},readOnly:!0}];for(var a=1;a<9;a++)t.commands.push({name:"foldToLevel"+a,description:"Fold To Level "+a,level:a,exec:function(e){e.session.foldToLevel(this.level)},scrollIntoView:"center",readOnly:!0})})),ace.define("ace/line_widgets",["require","exports","module","ace/lib/dom"],(function(e,t,n){"use strict";var r=e("./lib/dom"),i=function(){function e(e){this.session=e,this.session.widgetManager=this,this.session.getRowLength=this.getRowLength,this.session.$getWidgetScreenLength=this.$getWidgetScreenLength,this.updateOnChange=this.updateOnChange.bind(this),this.renderWidgets=this.renderWidgets.bind(this),this.measureWidgets=this.measureWidgets.bind(this),this.session._changedWidgets=[],this.$onChangeEditor=this.$onChangeEditor.bind(this),this.session.on("change",this.updateOnChange),this.session.on("changeFold",this.updateOnFold),this.session.on("changeEditor",this.$onChangeEditor)}return e.prototype.getRowLength=function(e){var t;return t=this.lineWidgets&&this.lineWidgets[e]&&this.lineWidgets[e].rowCount||0,this.$useWrapMode&&this.$wrapData[e]?this.$wrapData[e].length+1+t:1+t},e.prototype.$getWidgetScreenLength=function(){var e=0;return this.lineWidgets.forEach((function(t){t&&t.rowCount&&!t.hidden&&(e+=t.rowCount)})),e},e.prototype.$onChangeEditor=function(e){this.attach(e.editor)},e.prototype.attach=function(e){e&&e.widgetManager&&e.widgetManager!=this&&e.widgetManager.detach(),this.editor!=e&&(this.detach(),this.editor=e,e&&(e.widgetManager=this,e.renderer.on("beforeRender",this.measureWidgets),e.renderer.on("afterRender",this.renderWidgets)))},e.prototype.detach=function(e){var t=this.editor;if(t){this.editor=null,t.widgetManager=null,t.renderer.off("beforeRender",this.measureWidgets),t.renderer.off("afterRender",this.renderWidgets);var n=this.session.lineWidgets;n&&n.forEach((function(e){e&&e.el&&e.el.parentNode&&(e._inDocument=!1,e.el.parentNode.removeChild(e.el))}))}},e.prototype.updateOnFold=function(e,t){var n=t.lineWidgets;if(n&&e.action){for(var r=e.data,i=r.start.row,o=r.end.row,s="add"==e.action,a=i+1;a<o;a++)n[a]&&(n[a].hidden=s);n[o]&&(s?n[i]?n[o].hidden=s:n[i]=n[o]:(n[i]==n[o]&&(n[i]=void 0),n[o].hidden=s))}},e.prototype.updateOnChange=function(e){var t=this.session.lineWidgets;if(t){var n=e.start.row,r=e.end.row-n;if(0===r);else if("remove"==e.action){var i=t.splice(n+1,r);!t[n]&&i[i.length-1]&&(t[n]=i.pop()),i.forEach((function(e){e&&this.removeLineWidget(e)}),this),this.$updateRows()}else{var o=new Array(r);t[n]&&null!=t[n].column&&e.start.column>t[n].column&&n++,o.unshift(n,0),t.splice.apply(t,o),this.$updateRows()}}},e.prototype.$updateRows=function(){var e=this.session.lineWidgets;if(e){var t=!0;e.forEach((function(e,n){if(e){t=!1,e.row=n;while(e.$oldWidget)e.$oldWidget.row=n,e=e.$oldWidget}})),t&&(this.session.lineWidgets=null)}},e.prototype.$registerLineWidget=function(e){this.session.lineWidgets||(this.session.lineWidgets=new Array(this.session.getLength()));var t=this.session.lineWidgets[e.row];return t&&(e.$oldWidget=t,t.el&&t.el.parentNode&&(t.el.parentNode.removeChild(t.el),t._inDocument=!1)),this.session.lineWidgets[e.row]=e,e},e.prototype.addLineWidget=function(e){if(this.$registerLineWidget(e),e.session=this.session,!this.editor)return e;var t=this.editor.renderer;e.html&&!e.el&&(e.el=r.createElement("div"),e.el.innerHTML=e.html),e.text&&!e.el&&(e.el=r.createElement("div"),e.el.textContent=e.text),e.el&&(r.addCssClass(e.el,"ace_lineWidgetContainer"),e.className&&r.addCssClass(e.el,e.className),e.el.style.position="absolute",e.el.style.zIndex=5,t.container.appendChild(e.el),e._inDocument=!0,e.coverGutter||(e.el.style.zIndex=3),null==e.pixelHeight&&(e.pixelHeight=e.el.offsetHeight)),null==e.rowCount&&(e.rowCount=e.pixelHeight/t.layerConfig.lineHeight);var n=this.session.getFoldAt(e.row,0);if(e.$fold=n,n){var i=this.session.lineWidgets;e.row!=n.end.row||i[n.start.row]?e.hidden=!0:i[n.start.row]=e}return this.session._emit("changeFold",{data:{start:{row:e.row}}}),this.$updateRows(),this.renderWidgets(null,t),this.onWidgetChanged(e),e},e.prototype.removeLineWidget=function(e){if(e._inDocument=!1,e.session=null,e.el&&e.el.parentNode&&e.el.parentNode.removeChild(e.el),e.editor&&e.editor.destroy)try{e.editor.destroy()}catch(n){}if(this.session.lineWidgets){var t=this.session.lineWidgets[e.row];if(t==e)this.session.lineWidgets[e.row]=e.$oldWidget,e.$oldWidget&&this.onWidgetChanged(e.$oldWidget);else while(t){if(t.$oldWidget==e){t.$oldWidget=e.$oldWidget;break}t=t.$oldWidget}}this.session._emit("changeFold",{data:{start:{row:e.row}}}),this.$updateRows()},e.prototype.getWidgetsAtRow=function(e){var t=this.session.lineWidgets,n=t&&t[e],r=[];while(n)r.push(n),n=n.$oldWidget;return r},e.prototype.onWidgetChanged=function(e){this.session._changedWidgets.push(e),this.editor&&this.editor.renderer.updateFull()},e.prototype.measureWidgets=function(e,t){var n=this.session._changedWidgets,r=t.layerConfig;if(n&&n.length){for(var i=1/0,o=0;o<n.length;o++){var s=n[o];if(s&&s.el&&s.session==this.session){if(!s._inDocument){if(this.session.lineWidgets[s.row]!=s)continue;s._inDocument=!0,t.container.appendChild(s.el)}s.h=s.el.offsetHeight,s.fixedWidth||(s.w=s.el.offsetWidth,s.screenWidth=Math.ceil(s.w/r.characterWidth));var a=s.h/r.lineHeight;s.coverLine&&(a-=this.session.getRowLineCount(s.row),a<0&&(a=0)),s.rowCount!=a&&(s.rowCount=a,s.row<i&&(i=s.row))}}i!=1/0&&(this.session._emit("changeFold",{data:{start:{row:i}}}),this.session.lineWidgetWidth=null),this.session._changedWidgets=[]}},e.prototype.renderWidgets=function(e,t){var n=t.layerConfig,r=this.session.lineWidgets;if(r){var i=Math.min(this.firstRow,n.firstRow),o=Math.max(this.lastRow,n.lastRow,r.length);while(i>0&&!r[i])i--;this.firstRow=n.firstRow,this.lastRow=n.lastRow,t.$cursorLayer.config=n;for(var s=i;s<=o;s++){var a=r[s];if(a&&a.el)if(a.hidden)a.el.style.top=-100-(a.pixelHeight||0)+"px";else{a._inDocument||(a._inDocument=!0,t.container.appendChild(a.el));var l=t.$cursorLayer.getPixelPosition({row:s,column:0},!0).top;a.coverLine||(l+=n.lineHeight*this.session.getRowLineCount(a.row)),a.el.style.top=l-n.offset+"px";var c=a.coverGutter?0:t.gutterWidth;a.fixedWidth||(c-=t.scrollLeft),a.el.style.left=c+"px",a.fullWidth&&a.screenWidth&&(a.el.style.minWidth=n.width+2*n.padding+"px"),a.fixedWidth?a.el.style.right=t.scrollBar.getWidth()+"px":a.el.style.right=""}}}},e}();t.LineWidgets=i})),ace.define("ace/editor",["require","exports","module","ace/lib/oop","ace/lib/dom","ace/lib/lang","ace/lib/useragent","ace/keyboard/textinput","ace/mouse/mouse_handler","ace/mouse/fold_handler","ace/keyboard/keybinding","ace/edit_session","ace/search","ace/range","ace/lib/event_emitter","ace/commands/command_manager","ace/commands/default_commands","ace/config","ace/token_iterator","ace/line_widgets","ace/clipboard","ace/lib/keys"],(function(e,t,n){"use strict";var r=this&&this.__values||function(e){var t="function"===typeof Symbol&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&"number"===typeof e.length)return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")},i=e("./lib/oop"),o=e("./lib/dom"),s=e("./lib/lang"),a=e("./lib/useragent"),l=e("./keyboard/textinput").TextInput,c=e("./mouse/mouse_handler").MouseHandler,u=e("./mouse/fold_handler").FoldHandler,h=e("./keyboard/keybinding").KeyBinding,f=e("./edit_session").EditSession,d=e("./search").Search,p=e("./range").Range,g=e("./lib/event_emitter").EventEmitter,m=e("./commands/command_manager").CommandManager,v=e("./commands/default_commands").commands,y=e("./config"),w=e("./token_iterator").TokenIterator,b=e("./line_widgets").LineWidgets,x=e("./clipboard"),S=e("./lib/keys"),_=function(){function e(t,n,r){this.$toDestroy=[];var i=t.getContainerElement();this.container=i,this.renderer=t,this.id="editor"+ ++e.$uid,this.commands=new m(a.isMac?"mac":"win",v),"object"==typeof document&&(this.textInput=new l(t.getTextAreaContainer(),this),this.renderer.textarea=this.textInput.getElement(),this.$mouseHandler=new c(this),new u(this)),this.keyBinding=new h(this),this.$search=(new d).set({wrap:!0}),this.$historyTracker=this.$historyTracker.bind(this),this.commands.on("exec",this.$historyTracker),this.$initOperationListeners(),this._$emitInputEvent=s.delayedCall(function(){this._signal("input",{}),this.session&&!this.session.destroyed&&this.session.bgTokenizer.scheduleStart()}.bind(this)),this.on("change",(function(e,t){t._$emitInputEvent.schedule(31)})),this.setSession(n||r&&r.session||new f("")),y.resetOptions(this),r&&this.setOptions(r),y._signal("editor",this)}return e.prototype.$initOperationListeners=function(){this.commands.on("exec",this.startOperation.bind(this),!0),this.commands.on("afterExec",this.endOperation.bind(this),!0),this.$opResetTimer=s.delayedCall(this.endOperation.bind(this,!0)),this.on("change",function(){this.curOp||(this.startOperation(),this.curOp.selectionBefore=this.$lastSel),this.curOp.docChanged=!0}.bind(this),!0),this.on("changeSelection",function(){this.curOp||(this.startOperation(),this.curOp.selectionBefore=this.$lastSel),this.curOp.selectionChanged=!0}.bind(this),!0)},e.prototype.startOperation=function(e){if(this.curOp){if(!e||this.curOp.command)return;this.prevOp=this.curOp}e||(this.previousCommand=null,e={}),this.$opResetTimer.schedule(),this.curOp=this.session.curOp={command:e.command||{},args:e.args,scrollTop:this.renderer.scrollTop},this.curOp.selectionBefore=this.selection.toJSON()},e.prototype.endOperation=function(e){if(this.curOp&&this.session){if(e&&!1===e.returnValue||!this.session)return this.curOp=null;if(1==e&&this.curOp.command&&"mouse"==this.curOp.command.name)return;if(this._signal("beforeEndOperation"),!this.curOp)return;var t=this.curOp.command,n=t&&t.scrollIntoView;if(n){switch(n){case"center-animate":n="animate";case"center":this.renderer.scrollCursorIntoView(null,.5);break;case"animate":case"cursor":this.renderer.scrollCursorIntoView();break;case"selectionPart":var r=this.selection.getRange(),i=this.renderer.layerConfig;(r.start.row>=i.lastRow||r.end.row<=i.firstRow)&&this.renderer.scrollSelectionIntoView(this.selection.anchor,this.selection.lead);break;default:break}"animate"==n&&this.renderer.animateScrolling(this.curOp.scrollTop)}var o=this.selection.toJSON();this.curOp.selectionAfter=o,this.$lastSel=this.selection.toJSON(),this.session.getUndoManager().addSelection(o),this.prevOp=this.curOp,this.curOp=null}},e.prototype.$historyTracker=function(e){if(this.$mergeUndoDeltas){var t=this.prevOp,n=this.$mergeableCommands,r=t.command&&e.command.name==t.command.name;if("insertstring"==e.command.name){var i=e.args;void 0===this.mergeNextCommand&&(this.mergeNextCommand=!0),r=r&&this.mergeNextCommand&&(!/\s/.test(i)||/\s/.test(t.args)),this.mergeNextCommand=!0}else r=r&&-1!==n.indexOf(e.command.name);"always"!=this.$mergeUndoDeltas&&Date.now()-this.sequenceStartTime>2e3&&(r=!1),r?this.session.mergeUndoDeltas=!0:-1!==n.indexOf(e.command.name)&&(this.sequenceStartTime=Date.now())}},e.prototype.setKeyboardHandler=function(e,t){if(e&&"string"===typeof e&&"ace"!=e){this.$keybindingId=e;var n=this;y.loadModule(["keybinding",e],(function(r){n.$keybindingId==e&&n.keyBinding.setKeyboardHandler(r&&r.handler),t&&t()}))}else this.$keybindingId=null,this.keyBinding.setKeyboardHandler(e),t&&t()},e.prototype.getKeyboardHandler=function(){return this.keyBinding.getKeyboardHandler()},e.prototype.setSession=function(e){if(this.session!=e){this.curOp&&this.endOperation(),this.curOp={};var t=this.session;if(t){this.session.off("change",this.$onDocumentChange),this.session.off("changeMode",this.$onChangeMode),this.session.off("tokenizerUpdate",this.$onTokenizerUpdate),this.session.off("changeTabSize",this.$onChangeTabSize),this.session.off("changeWrapLimit",this.$onChangeWrapLimit),this.session.off("changeWrapMode",this.$onChangeWrapMode),this.session.off("changeFold",this.$onChangeFold),this.session.off("changeFrontMarker",this.$onChangeFrontMarker),this.session.off("changeBackMarker",this.$onChangeBackMarker),this.session.off("changeBreakpoint",this.$onChangeBreakpoint),this.session.off("changeAnnotation",this.$onChangeAnnotation),this.session.off("changeOverwrite",this.$onCursorChange),this.session.off("changeScrollTop",this.$onScrollTopChange),this.session.off("changeScrollLeft",this.$onScrollLeftChange);var n=this.session.getSelection();n.off("changeCursor",this.$onCursorChange),n.off("changeSelection",this.$onSelectionChange)}this.session=e,e?(this.$onDocumentChange=this.onDocumentChange.bind(this),e.on("change",this.$onDocumentChange),this.renderer.setSession(e),this.$onChangeMode=this.onChangeMode.bind(this),e.on("changeMode",this.$onChangeMode),this.$onTokenizerUpdate=this.onTokenizerUpdate.bind(this),e.on("tokenizerUpdate",this.$onTokenizerUpdate),this.$onChangeTabSize=this.renderer.onChangeTabSize.bind(this.renderer),e.on("changeTabSize",this.$onChangeTabSize),this.$onChangeWrapLimit=this.onChangeWrapLimit.bind(this),e.on("changeWrapLimit",this.$onChangeWrapLimit),this.$onChangeWrapMode=this.onChangeWrapMode.bind(this),e.on("changeWrapMode",this.$onChangeWrapMode),this.$onChangeFold=this.onChangeFold.bind(this),e.on("changeFold",this.$onChangeFold),this.$onChangeFrontMarker=this.onChangeFrontMarker.bind(this),this.session.on("changeFrontMarker",this.$onChangeFrontMarker),this.$onChangeBackMarker=this.onChangeBackMarker.bind(this),this.session.on("changeBackMarker",this.$onChangeBackMarker),this.$onChangeBreakpoint=this.onChangeBreakpoint.bind(this),this.session.on("changeBreakpoint",this.$onChangeBreakpoint),this.$onChangeAnnotation=this.onChangeAnnotation.bind(this),this.session.on("changeAnnotation",this.$onChangeAnnotation),this.$onCursorChange=this.onCursorChange.bind(this),this.session.on("changeOverwrite",this.$onCursorChange),this.$onScrollTopChange=this.onScrollTopChange.bind(this),this.session.on("changeScrollTop",this.$onScrollTopChange),this.$onScrollLeftChange=this.onScrollLeftChange.bind(this),this.session.on("changeScrollLeft",this.$onScrollLeftChange),this.selection=e.getSelection(),this.selection.on("changeCursor",this.$onCursorChange),this.$onSelectionChange=this.onSelectionChange.bind(this),this.selection.on("changeSelection",this.$onSelectionChange),this.onChangeMode(),this.onCursorChange(),this.onScrollTopChange(),this.onScrollLeftChange(),this.onSelectionChange(),this.onChangeFrontMarker(),this.onChangeBackMarker(),this.onChangeBreakpoint(),this.onChangeAnnotation(),this.session.getUseWrapMode()&&this.renderer.adjustWrapLimit(),this.renderer.updateFull()):(this.selection=null,this.renderer.setSession(e)),this._signal("changeSession",{session:e,oldSession:t}),this.curOp=null,t&&t._signal("changeEditor",{oldEditor:this}),e&&e._signal("changeEditor",{editor:this}),e&&!e.destroyed&&e.bgTokenizer.scheduleStart()}},e.prototype.getSession=function(){return this.session},e.prototype.setValue=function(e,t){return this.session.doc.setValue(e),t?1==t?this.navigateFileEnd():-1==t&&this.navigateFileStart():this.selectAll(),e},e.prototype.getValue=function(){return this.session.getValue()},e.prototype.getSelection=function(){return this.selection},e.prototype.resize=function(e){this.renderer.onResize(e)},e.prototype.setTheme=function(e,t){this.renderer.setTheme(e,t)},e.prototype.getTheme=function(){return this.renderer.getTheme()},e.prototype.setStyle=function(e){this.renderer.setStyle(e)},e.prototype.unsetStyle=function(e){this.renderer.unsetStyle(e)},e.prototype.getFontSize=function(){return this.getOption("fontSize")||o.computedStyle(this.container).fontSize},e.prototype.setFontSize=function(e){this.setOption("fontSize",e)},e.prototype.$highlightBrackets=function(){if(!this.$highlightPending){var e=this;this.$highlightPending=!0,setTimeout((function(){e.$highlightPending=!1;var t=e.session;if(t&&!t.destroyed){t.$bracketHighlight&&(t.$bracketHighlight.markerIds.forEach((function(e){t.removeMarker(e)})),t.$bracketHighlight=null);var n=e.getCursorPosition(),r=e.getKeyboardHandler(),i=r&&r.$getDirectionForHighlight&&r.$getDirectionForHighlight(e),o=t.getMatchingBracketRanges(n,i);if(!o){var s=new w(t,n.row,n.column),a=s.getCurrentToken();if(a&&/\b(?:tag-open|tag-name)/.test(a.type)){var l=t.getMatchingTags(n);l&&(o=[l.openTagName,l.closeTagName])}}if(!o&&t.$mode.getMatching&&(o=t.$mode.getMatching(e.session)),o){var c="ace_bracket";Array.isArray(o)?1==o.length&&(c="ace_error_bracket"):o=[o],2==o.length&&(0==p.comparePoints(o[0].end,o[1].start)?o=[p.fromPoints(o[0].start,o[1].end)]:0==p.comparePoints(o[0].start,o[1].end)&&(o=[p.fromPoints(o[1].start,o[0].end)])),t.$bracketHighlight={ranges:o,markerIds:o.map((function(e){return t.addMarker(e,c,"text")}))},e.getHighlightIndentGuides()&&e.renderer.$textLayer.$highlightIndentGuide()}else e.getHighlightIndentGuides()&&e.renderer.$textLayer.$highlightIndentGuide()}}),50)}},e.prototype.focus=function(){this.textInput.focus()},e.prototype.isFocused=function(){return this.textInput.isFocused()},e.prototype.blur=function(){this.textInput.blur()},e.prototype.onFocus=function(e){this.$isFocused||(this.$isFocused=!0,this.renderer.showCursor(),this.renderer.visualizeFocus(),this._emit("focus",e))},e.prototype.onBlur=function(e){this.$isFocused&&(this.$isFocused=!1,this.renderer.hideCursor(),this.renderer.visualizeBlur(),this._emit("blur",e))},e.prototype.$cursorChange=function(){this.renderer.updateCursor(),this.$highlightBrackets(),this.$updateHighlightActiveLine()},e.prototype.onDocumentChange=function(e){var t=this.session.$useWrapMode,n=e.start.row==e.end.row?e.end.row:1/0;this.renderer.updateLines(e.start.row,n,t),this._signal("change",e),this.$cursorChange()},e.prototype.onTokenizerUpdate=function(e){var t=e.data;this.renderer.updateLines(t.first,t.last)},e.prototype.onScrollTopChange=function(){this.renderer.scrollToY(this.session.getScrollTop())},e.prototype.onScrollLeftChange=function(){this.renderer.scrollToX(this.session.getScrollLeft())},e.prototype.onCursorChange=function(){this.$cursorChange(),this._signal("changeSelection")},e.prototype.$updateHighlightActiveLine=function(){var e,t=this.getSession();if(this.$highlightActiveLine&&("line"==this.$selectionStyle&&this.selection.isMultiLine()||(e=this.getCursorPosition()),this.renderer.theme&&this.renderer.theme.$selectionColorConflict&&!this.selection.isEmpty()&&(e=!1),!this.renderer.$maxLines||1!==this.session.getLength()||this.renderer.$minLines>1||(e=!1)),t.$highlightLineMarker&&!e)t.removeMarker(t.$highlightLineMarker.id),t.$highlightLineMarker=null;else if(!t.$highlightLineMarker&&e){var n=new p(e.row,e.column,e.row,1/0);n.id=t.addMarker(n,"ace_active-line","screenLine"),t.$highlightLineMarker=n}else e&&(t.$highlightLineMarker.start.row=e.row,t.$highlightLineMarker.end.row=e.row,t.$highlightLineMarker.start.column=e.column,t._signal("changeBackMarker"))},e.prototype.onSelectionChange=function(e){var t=this.session;if(t.$selectionMarker&&t.removeMarker(t.$selectionMarker),t.$selectionMarker=null,this.selection.isEmpty())this.$updateHighlightActiveLine();else{var n=this.selection.getRange(),r=this.getSelectionStyle();t.$selectionMarker=t.addMarker(n,"ace_selection",r)}var i=this.$highlightSelectedWord&&this.$getSelectionHighLightRegexp();this.session.highlight(i),this._signal("changeSelection")},e.prototype.$getSelectionHighLightRegexp=function(){var e=this.session,t=this.getSelectionRange();if(!t.isEmpty()&&!t.isMultiLine()){var n=t.start.column,r=t.end.column,i=e.getLine(t.start.row),o=i.substring(n,r);if(!(o.length>5e3)&&/[\w\d]/.test(o)){var s=this.$search.$assembleRegExp({wholeWord:!0,caseSensitive:!0,needle:o}),a=i.substring(n-1,r+1);if(s.test(a))return s}}},e.prototype.onChangeFrontMarker=function(){this.renderer.updateFrontMarkers()},e.prototype.onChangeBackMarker=function(){this.renderer.updateBackMarkers()},e.prototype.onChangeBreakpoint=function(){this.renderer.updateBreakpoints()},e.prototype.onChangeAnnotation=function(){this.renderer.setAnnotations(this.session.getAnnotations())},e.prototype.onChangeMode=function(e){this.renderer.updateText(),this._emit("changeMode",e)},e.prototype.onChangeWrapLimit=function(){this.renderer.updateFull()},e.prototype.onChangeWrapMode=function(){this.renderer.onResize(!0)},e.prototype.onChangeFold=function(){this.$updateHighlightActiveLine(),this.renderer.updateFull()},e.prototype.getSelectedText=function(){return this.session.getTextRange(this.getSelectionRange())},e.prototype.getCopyText=function(){var e=this.getSelectedText(),t=this.session.doc.getNewLineCharacter(),n=!1;if(!e&&this.$copyWithEmptySelection){n=!0;for(var r=this.selection.getAllRanges(),i=0;i<r.length;i++){var o=r[i];i&&r[i-1].start.row==o.start.row||(e+=this.session.getLine(o.start.row)+t)}}var s={text:e};return this._signal("copy",s),x.lineMode=!!n&&s.text,s.text},e.prototype.onCopy=function(){this.commands.exec("copy",this)},e.prototype.onCut=function(){this.commands.exec("cut",this)},e.prototype.onPaste=function(e,t){var n={text:e,event:t};this.commands.exec("paste",this,n)},e.prototype.$handlePaste=function(e){"string"==typeof e&&(e={text:e}),this._signal("paste",e);var t=e.text,n=t===x.lineMode,r=this.session;if(!this.inMultiSelectMode||this.inVirtualSelectionMode)n?r.insert({row:this.selection.lead.row,column:0},t):this.insert(t);else if(n)this.selection.rangeList.ranges.forEach((function(e){r.insert({row:e.start.row,column:0},t)}));else{var i=t.split(/\r\n|\r|\n/),o=this.selection.rangeList.ranges,s=2==i.length&&(!i[0]||!i[1]);if(i.length!=o.length||s)return this.commands.exec("insertstring",this,t);for(var a=o.length;a--;){var l=o[a];l.isEmpty()||r.remove(l),r.insert(l.start,i[a])}}},e.prototype.execCommand=function(e,t){return this.commands.exec(e,this,t)},e.prototype.insert=function(e,t){var n=this.session,r=n.getMode(),i=this.getCursorPosition();if(this.getBehavioursEnabled()&&!t){var o=r.transformAction(n.getState(i.row),"insertion",this,n,e);o&&(e!==o.text&&(this.inVirtualSelectionMode||(this.session.mergeUndoDeltas=!1,this.mergeNextCommand=!1)),e=o.text)}if("\t"==e&&(e=this.session.getTabString()),this.selection.isEmpty()){if(this.session.getOverwrite()&&-1==e.indexOf("\n")){s=new p.fromPoints(i,i);s.end.column+=e.length,this.session.remove(s)}}else{var s=this.getSelectionRange();i=this.session.remove(s),this.clearSelection()}if("\n"==e||"\r\n"==e){var a=n.getLine(i.row);if(i.column>a.search(/\S|$/)){var l=a.substr(i.column).search(/\S|$/);n.doc.removeInLine(i.row,i.column,i.column+l)}}this.clearSelection();var c=i.column,u=n.getState(i.row),h=(a=n.getLine(i.row),r.checkOutdent(u,a,e));if(n.insert(i,e),o&&o.selection&&(2==o.selection.length?this.selection.setSelectionRange(new p(i.row,c+o.selection[0],i.row,c+o.selection[1])):this.selection.setSelectionRange(new p(i.row+o.selection[0],o.selection[1],i.row+o.selection[2],o.selection[3]))),this.$enableAutoIndent){if(n.getDocument().isNewLine(e)){var f=r.getNextLineIndent(u,a.slice(0,i.column),n.getTabString());n.insert({row:i.row+1,column:0},f)}h&&r.autoOutdent(u,n,i.row)}},e.prototype.autoIndent=function(){var e,t,n=this.session,r=n.getMode();if(this.selection.isEmpty())e=0,t=n.doc.getLength()-1;else{var i=this.getSelectionRange();e=i.start.row,t=i.end.row}for(var o,s,a,l="",c="",u="",h=n.getTabString(),f=e;f<=t;f++)f>0&&(l=n.getState(f-1),c=n.getLine(f-1),u=r.getNextLineIndent(l,c,h)),o=n.getLine(f),s=r.$getIndent(o),u!==s&&(s.length>0&&(a=new p(f,0,f,s.length),n.remove(a)),u.length>0&&n.insert({row:f,column:0},u)),r.autoOutdent(l,n,f)},e.prototype.onTextInput=function(e,t){if(!t)return this.keyBinding.onTextInput(e);this.startOperation({command:{name:"insertstring"}});var n=this.applyComposition.bind(this,e,t);this.selection.rangeCount?this.forEachSelection(n):n(),this.endOperation()},e.prototype.applyComposition=function(e,t){if(t.extendLeft||t.extendRight){var n=this.selection.getRange();n.start.column-=t.extendLeft,n.end.column+=t.extendRight,n.start.column<0&&(n.start.row--,n.start.column+=this.session.getLine(n.start.row).length+1),this.selection.setRange(n),e||n.isEmpty()||this.remove()}if(!e&&this.selection.isEmpty()||this.insert(e,!0),t.restoreStart||t.restoreEnd){n=this.selection.getRange();n.start.column-=t.restoreStart,n.end.column-=t.restoreEnd,this.selection.setRange(n)}},e.prototype.onCommandKey=function(e,t,n){return this.keyBinding.onCommandKey(e,t,n)},e.prototype.setOverwrite=function(e){this.session.setOverwrite(e)},e.prototype.getOverwrite=function(){return this.session.getOverwrite()},e.prototype.toggleOverwrite=function(){this.session.toggleOverwrite()},e.prototype.setScrollSpeed=function(e){this.setOption("scrollSpeed",e)},e.prototype.getScrollSpeed=function(){return this.getOption("scrollSpeed")},e.prototype.setDragDelay=function(e){this.setOption("dragDelay",e)},e.prototype.getDragDelay=function(){return this.getOption("dragDelay")},e.prototype.setSelectionStyle=function(e){this.setOption("selectionStyle",e)},e.prototype.getSelectionStyle=function(){return this.getOption("selectionStyle")},e.prototype.setHighlightActiveLine=function(e){this.setOption("highlightActiveLine",e)},e.prototype.getHighlightActiveLine=function(){return this.getOption("highlightActiveLine")},e.prototype.setHighlightGutterLine=function(e){this.setOption("highlightGutterLine",e)},e.prototype.getHighlightGutterLine=function(){return this.getOption("highlightGutterLine")},e.prototype.setHighlightSelectedWord=function(e){this.setOption("highlightSelectedWord",e)},e.prototype.getHighlightSelectedWord=function(){return this.$highlightSelectedWord},e.prototype.setAnimatedScroll=function(e){this.renderer.setAnimatedScroll(e)},e.prototype.getAnimatedScroll=function(){return this.renderer.getAnimatedScroll()},e.prototype.setShowInvisibles=function(e){this.renderer.setShowInvisibles(e)},e.prototype.getShowInvisibles=function(){return this.renderer.getShowInvisibles()},e.prototype.setDisplayIndentGuides=function(e){this.renderer.setDisplayIndentGuides(e)},e.prototype.getDisplayIndentGuides=function(){return this.renderer.getDisplayIndentGuides()},e.prototype.setHighlightIndentGuides=function(e){this.renderer.setHighlightIndentGuides(e)},e.prototype.getHighlightIndentGuides=function(){return this.renderer.getHighlightIndentGuides()},e.prototype.setShowPrintMargin=function(e){this.renderer.setShowPrintMargin(e)},e.prototype.getShowPrintMargin=function(){return this.renderer.getShowPrintMargin()},e.prototype.setPrintMarginColumn=function(e){this.renderer.setPrintMarginColumn(e)},e.prototype.getPrintMarginColumn=function(){return this.renderer.getPrintMarginColumn()},e.prototype.setReadOnly=function(e){this.setOption("readOnly",e)},e.prototype.getReadOnly=function(){return this.getOption("readOnly")},e.prototype.setBehavioursEnabled=function(e){this.setOption("behavioursEnabled",e)},e.prototype.getBehavioursEnabled=function(){return this.getOption("behavioursEnabled")},e.prototype.setWrapBehavioursEnabled=function(e){this.setOption("wrapBehavioursEnabled",e)},e.prototype.getWrapBehavioursEnabled=function(){return this.getOption("wrapBehavioursEnabled")},e.prototype.setShowFoldWidgets=function(e){this.setOption("showFoldWidgets",e)},e.prototype.getShowFoldWidgets=function(){return this.getOption("showFoldWidgets")},e.prototype.setFadeFoldWidgets=function(e){this.setOption("fadeFoldWidgets",e)},e.prototype.getFadeFoldWidgets=function(){return this.getOption("fadeFoldWidgets")},e.prototype.remove=function(e){this.selection.isEmpty()&&("left"==e?this.selection.selectLeft():this.selection.selectRight());var t=this.getSelectionRange();if(this.getBehavioursEnabled()){var n=this.session,r=n.getState(t.start.row),i=n.getMode().transformAction(r,"deletion",this,n,t);if(0===t.end.column){var o=n.getTextRange(t);if("\n"==o[o.length-1]){var s=n.getLine(t.end.row);/^\s+$/.test(s)&&(t.end.column=s.length)}}i&&(t=i)}this.session.remove(t),this.clearSelection()},e.prototype.removeWordRight=function(){this.selection.isEmpty()&&this.selection.selectWordRight(),this.session.remove(this.getSelectionRange()),this.clearSelection()},e.prototype.removeWordLeft=function(){this.selection.isEmpty()&&this.selection.selectWordLeft(),this.session.remove(this.getSelectionRange()),this.clearSelection()},e.prototype.removeToLineStart=function(){this.selection.isEmpty()&&this.selection.selectLineStart(),this.selection.isEmpty()&&this.selection.selectLeft(),this.session.remove(this.getSelectionRange()),this.clearSelection()},e.prototype.removeToLineEnd=function(){this.selection.isEmpty()&&this.selection.selectLineEnd();var e=this.getSelectionRange();e.start.column==e.end.column&&e.start.row==e.end.row&&(e.end.column=0,e.end.row++),this.session.remove(e),this.clearSelection()},e.prototype.splitLine=function(){this.selection.isEmpty()||(this.session.remove(this.getSelectionRange()),this.clearSelection());var e=this.getCursorPosition();this.insert("\n"),this.moveCursorToPosition(e)},e.prototype.setGhostText=function(e,t){this.session.widgetManager||(this.session.widgetManager=new b(this.session),this.session.widgetManager.attach(this)),this.renderer.setGhostText(e,t)},e.prototype.removeGhostText=function(){this.session.widgetManager&&this.renderer.removeGhostText()},e.prototype.transposeLetters=function(){if(this.selection.isEmpty()){var e=this.getCursorPosition(),t=e.column;if(0!==t){var n,r,i=this.session.getLine(e.row);t<i.length?(n=i.charAt(t)+i.charAt(t-1),r=new p(e.row,t-1,e.row,t+1)):(n=i.charAt(t-1)+i.charAt(t-2),r=new p(e.row,t-2,e.row,t)),this.session.replace(r,n),this.session.selection.moveToPosition(r.end)}}},e.prototype.toLowerCase=function(){var e=this.getSelectionRange();this.selection.isEmpty()&&this.selection.selectWord();var t=this.getSelectionRange(),n=this.session.getTextRange(t);this.session.replace(t,n.toLowerCase()),this.selection.setSelectionRange(e)},e.prototype.toUpperCase=function(){var e=this.getSelectionRange();this.selection.isEmpty()&&this.selection.selectWord();var t=this.getSelectionRange(),n=this.session.getTextRange(t);this.session.replace(t,n.toUpperCase()),this.selection.setSelectionRange(e)},e.prototype.indent=function(){var e=this.session,t=this.getSelectionRange();if(!(t.start.row<t.end.row)){if(t.start.column<t.end.column){var n=e.getTextRange(t);if(!/^\s+$/.test(n)){u=this.$getSelectedRows();return void e.indentRows(u.first,u.last,"\t")}}var r=e.getLine(t.start.row),i=t.start,o=e.getTabSize(),a=e.documentToScreenColumn(i.row,i.column);if(this.session.getUseSoftTabs())var l=o-a%o,c=s.stringRepeat(" ",l);else{l=a%o;while(" "==r[t.start.column-1]&&l)t.start.column--,l--;this.selection.setSelectionRange(t),c="\t"}return this.insert(c)}var u=this.$getSelectedRows();e.indentRows(u.first,u.last,"\t")},e.prototype.blockIndent=function(){var e=this.$getSelectedRows();this.session.indentRows(e.first,e.last,"\t")},e.prototype.blockOutdent=function(){var e=this.session.getSelection();this.session.outdentRows(e.getRange())},e.prototype.sortLines=function(){for(var e=this.$getSelectedRows(),t=this.session,n=[],r=e.first;r<=e.last;r++)n.push(t.getLine(r));n.sort((function(e,t){return e.toLowerCase()<t.toLowerCase()?-1:e.toLowerCase()>t.toLowerCase()?1:0}));var i=new p(0,0,0,0);for(r=e.first;r<=e.last;r++){var o=t.getLine(r);i.start.row=r,i.end.row=r,i.end.column=o.length,t.replace(i,n[r-e.first])}},e.prototype.toggleCommentLines=function(){var e=this.session.getState(this.getCursorPosition().row),t=this.$getSelectedRows();this.session.getMode().toggleCommentLines(e,this.session,t.first,t.last)},e.prototype.toggleBlockComment=function(){var e=this.getCursorPosition(),t=this.session.getState(e.row),n=this.getSelectionRange();this.session.getMode().toggleBlockComment(t,this.session,n,e)},e.prototype.getNumberAt=function(e,t){var n=/[\-]?[0-9]+(?:\.[0-9]+)?/g;n.lastIndex=0;var r=this.session.getLine(e);while(n.lastIndex<t){var i=n.exec(r);if(i.index<=t&&i.index+i[0].length>=t){var o={value:i[0],start:i.index,end:i.index+i[0].length};return o}}return null},e.prototype.modifyNumber=function(e){var t=this.selection.getCursor().row,n=this.selection.getCursor().column,r=new p(t,n-1,t,n),i=this.session.getTextRange(r);if(!isNaN(parseFloat(i))&&isFinite(i)){var o=this.getNumberAt(t,n);if(o){var s=o.value.indexOf(".")>=0?o.start+o.value.indexOf(".")+1:o.end,a=o.start+o.value.length-s,l=parseFloat(o.value);l*=Math.pow(10,a),s!==o.end&&n<s?e*=Math.pow(10,o.end-n-1):e*=Math.pow(10,o.end-n),l+=e,l/=Math.pow(10,a);var c=l.toFixed(a),u=new p(t,o.start,t,o.end);this.session.replace(u,c),this.moveCursorTo(t,Math.max(o.start+1,n+c.length-o.value.length))}}else this.toggleWord()},e.prototype.toggleWord=function(){var e=this.selection.getCursor().row,t=this.selection.getCursor().column;this.selection.selectWord();var n=this.getSelectedText(),r=this.selection.getWordRange().start.column,i=n.replace(/([a-z]+|[A-Z]+)(?=[A-Z_]|$)/g,"$1 ").split(/\s/),o=t-r-1;o<0&&(o=0);var a=0,l=0,c=this;n.match(/[A-Za-z0-9_]+/)&&i.forEach((function(t,i){l=a+t.length,o>=a&&o<=l&&(n=t,c.selection.clearSelection(),c.moveCursorTo(e,a+r),c.selection.selectTo(e,l+r)),a=l}));for(var u,h=this.$toggleWordPairs,f=0;f<h.length;f++)for(var d=h[f],p=0;p<=1;p++){var g=+!p,m=n.match(new RegExp("^\\s?_?("+s.escapeRegExp(d[p])+")\\s?$","i"));if(m){var v=n.match(new RegExp("([_]|^|\\s)("+s.escapeRegExp(m[1])+")($|\\s)","g"));v&&(u=n.replace(new RegExp(s.escapeRegExp(d[p]),"i"),(function(e){var t=d[g];return e.toUpperCase()==e?t=t.toUpperCase():e.charAt(0).toUpperCase()==e.charAt(0)&&(t=t.substr(0,0)+d[g].charAt(0).toUpperCase()+t.substr(1)),t})),this.insert(u),u="")}}},e.prototype.findLinkAt=function(e,t){var n,i,o=this.session.getLine(e),s=o.split(/((?:https?|ftp):\/\/[\S]+)/),a=t;a<0&&(a=0);var l,c=0,u=0;try{for(var h=r(s),f=h.next();!f.done;f=h.next()){var d=f.value;if(u=c+d.length,a>=c&&a<=u&&d.match(/((?:https?|ftp):\/\/[\S]+)/)){l=d.replace(/[\s:.,'";}\]]+$/,"");break}c=u}}catch(p){n={error:p}}finally{try{f&&!f.done&&(i=h.return)&&i.call(h)}finally{if(n)throw n.error}}return l},e.prototype.openLink=function(){var e=this.selection.getCursor(),t=this.findLinkAt(e.row,e.column);return t&&window.open(t,"_blank"),null!=t},e.prototype.removeLines=function(){var e=this.$getSelectedRows();this.session.removeFullLines(e.first,e.last),this.clearSelection()},e.prototype.duplicateSelection=function(){var e=this.selection,t=this.session,n=e.getRange(),r=e.isBackwards();if(n.isEmpty()){var i=n.start.row;t.duplicateLines(i,i)}else{var o=r?n.start:n.end,s=t.insert(o,t.getTextRange(n),!1);n.start=o,n.end=s,e.setSelectionRange(n,r)}},e.prototype.moveLinesDown=function(){this.$moveLines(1,!1)},e.prototype.moveLinesUp=function(){this.$moveLines(-1,!1)},e.prototype.moveText=function(e,t,n){return this.session.moveText(e,t,n)},e.prototype.copyLinesUp=function(){this.$moveLines(-1,!0)},e.prototype.copyLinesDown=function(){this.$moveLines(1,!0)},e.prototype.$moveLines=function(e,t){var n,r,i=this.selection;if(!i.inMultiSelectMode||this.inVirtualSelectionMode){var o=i.toOrientedRange();n=this.$getSelectedRows(o),r=this.session.$moveLines(n.first,n.last,t?0:e),t&&-1==e&&(r=0),o.moveBy(r,0),i.fromOrientedRange(o)}else{var s=i.rangeList.ranges;i.rangeList.detach(this.session),this.inVirtualSelectionMode=!0;for(var a=0,l=0,c=s.length,u=0;u<c;u++){var h=u;s[u].moveBy(a,0),n=this.$getSelectedRows(s[u]);var f=n.first,d=n.last;while(++u<c){l&&s[u].moveBy(l,0);var p=this.$getSelectedRows(s[u]);if(t&&p.first!=d)break;if(!t&&p.first>d+1)break;d=p.last}u--,a=this.session.$moveLines(f,d,t?0:e),t&&-1==e&&(h=u+1);while(h<=u)s[h].moveBy(a,0),h++;t||(a=0),l+=a}i.fromOrientedRange(i.ranges[0]),i.rangeList.attach(this.session),this.inVirtualSelectionMode=!1}},e.prototype.$getSelectedRows=function(e){return e=(e||this.getSelectionRange()).collapseRows(),{first:this.session.getRowFoldStart(e.start.row),last:this.session.getRowFoldEnd(e.end.row)}},e.prototype.onCompositionStart=function(e){this.renderer.showComposition(e)},e.prototype.onCompositionUpdate=function(e){this.renderer.setCompositionText(e)},e.prototype.onCompositionEnd=function(){this.renderer.hideComposition()},e.prototype.getFirstVisibleRow=function(){return this.renderer.getFirstVisibleRow()},e.prototype.getLastVisibleRow=function(){return this.renderer.getLastVisibleRow()},e.prototype.isRowVisible=function(e){return e>=this.getFirstVisibleRow()&&e<=this.getLastVisibleRow()},e.prototype.isRowFullyVisible=function(e){return e>=this.renderer.getFirstFullyVisibleRow()&&e<=this.renderer.getLastFullyVisibleRow()},e.prototype.$getVisibleRowCount=function(){return this.renderer.getScrollBottomRow()-this.renderer.getScrollTopRow()+1},e.prototype.$moveByPage=function(e,t){var n=this.renderer,r=this.renderer.layerConfig,i=e*Math.floor(r.height/r.lineHeight);!0===t?this.selection.$moveSelection((function(){this.moveCursorBy(i,0)})):!1===t&&(this.selection.moveCursorBy(i,0),this.selection.clearSelection());var o=n.scrollTop;n.scrollBy(0,i*r.lineHeight),null!=t&&n.scrollCursorIntoView(null,.5),n.animateScrolling(o)},e.prototype.selectPageDown=function(){this.$moveByPage(1,!0)},e.prototype.selectPageUp=function(){this.$moveByPage(-1,!0)},e.prototype.gotoPageDown=function(){this.$moveByPage(1,!1)},e.prototype.gotoPageUp=function(){this.$moveByPage(-1,!1)},e.prototype.scrollPageDown=function(){this.$moveByPage(1)},e.prototype.scrollPageUp=function(){this.$moveByPage(-1)},e.prototype.scrollToRow=function(e){this.renderer.scrollToRow(e)},e.prototype.scrollToLine=function(e,t,n,r){this.renderer.scrollToLine(e,t,n,r)},e.prototype.centerSelection=function(){var e=this.getSelectionRange(),t={row:Math.floor(e.start.row+(e.end.row-e.start.row)/2),column:Math.floor(e.start.column+(e.end.column-e.start.column)/2)};this.renderer.alignCursor(t,.5)},e.prototype.getCursorPosition=function(){return this.selection.getCursor()},e.prototype.getCursorPositionScreen=function(){return this.session.documentToScreenPosition(this.getCursorPosition())},e.prototype.getSelectionRange=function(){return this.selection.getRange()},e.prototype.selectAll=function(){this.selection.selectAll()},e.prototype.clearSelection=function(){this.selection.clearSelection()},e.prototype.moveCursorTo=function(e,t){this.selection.moveCursorTo(e,t)},e.prototype.moveCursorToPosition=function(e){this.selection.moveCursorToPosition(e)},e.prototype.jumpToMatching=function(e,t){var n=this.getCursorPosition(),r=new w(this.session,n.row,n.column),i=r.getCurrentToken(),o=0;i&&-1!==i.type.indexOf("tag-name")&&(i=r.stepBackward());var s=i||r.stepForward();if(s){var a,l,c=!1,u={},h=n.column-s.start,f={")":"(","(":"(","]":"[","[":"[","{":"{","}":"{"};do{if(s.value.match(/[{}()\[\]]/g)){for(;h<s.value.length&&!c;h++)if(f[s.value[h]])switch(l=f[s.value[h]]+"."+s.type.replace("rparen","lparen"),isNaN(u[l])&&(u[l]=0),s.value[h]){case"(":case"[":case"{":u[l]++;break;case")":case"]":case"}":u[l]--,-1===u[l]&&(a="bracket",c=!0);break}}else-1!==s.type.indexOf("tag-name")&&(isNaN(u[s.value])&&(u[s.value]=0),"<"===i.value&&o>1?u[s.value]++:"</"===i.value&&u[s.value]--,-1===u[s.value]&&(a="tag",c=!0));c||(i=s,o++,s=r.stepForward(),h=0)}while(s&&!c);if(a){var d,g;if("bracket"===a)d=this.session.getBracketRange(n),d||(d=new p(r.getCurrentTokenRow(),r.getCurrentTokenColumn()+h-1,r.getCurrentTokenRow(),r.getCurrentTokenColumn()+h-1),g=d.start,(t||g.row===n.row&&Math.abs(g.column-n.column)<2)&&(d=this.session.getBracketRange(g)));else if("tag"===a){if(!s||-1===s.type.indexOf("tag-name"))return;if(d=new p(r.getCurrentTokenRow(),r.getCurrentTokenColumn()-2,r.getCurrentTokenRow(),r.getCurrentTokenColumn()-2),0===d.compare(n.row,n.column)){var m=this.session.getMatchingTags(n);m&&(m.openTag.contains(n.row,n.column)?(d=m.closeTag,g=d.start):(d=m.openTag,g=m.closeTag.start.row===n.row&&m.closeTag.start.column===n.column?d.end:d.start))}g=g||d.start}g=d&&d.cursor||g,g&&(e?d&&t?this.selection.setRange(d):d&&d.isEqual(this.getSelectionRange())?this.clearSelection():this.selection.selectTo(g.row,g.column):this.selection.moveTo(g.row,g.column))}}},e.prototype.gotoLine=function(e,t,n){this.selection.clearSelection(),this.session.unfold({row:e-1,column:t||0}),this.exitMultiSelectMode&&this.exitMultiSelectMode(),this.moveCursorTo(e-1,t||0),this.isRowFullyVisible(e-1)||this.scrollToLine(e-1,!0,n)},e.prototype.navigateTo=function(e,t){this.selection.moveTo(e,t)},e.prototype.navigateUp=function(e){if(this.selection.isMultiLine()&&!this.selection.isBackwards()){var t=this.selection.anchor.getPosition();return this.moveCursorToPosition(t)}this.selection.clearSelection(),this.selection.moveCursorBy(-e||-1,0)},e.prototype.navigateDown=function(e){if(this.selection.isMultiLine()&&this.selection.isBackwards()){var t=this.selection.anchor.getPosition();return this.moveCursorToPosition(t)}this.selection.clearSelection(),this.selection.moveCursorBy(e||1,0)},e.prototype.navigateLeft=function(e){if(this.selection.isEmpty()){e=e||1;while(e--)this.selection.moveCursorLeft()}else{var t=this.getSelectionRange().start;this.moveCursorToPosition(t)}this.clearSelection()},e.prototype.navigateRight=function(e){if(this.selection.isEmpty()){e=e||1;while(e--)this.selection.moveCursorRight()}else{var t=this.getSelectionRange().end;this.moveCursorToPosition(t)}this.clearSelection()},e.prototype.navigateLineStart=function(){this.selection.moveCursorLineStart(),this.clearSelection()},e.prototype.navigateLineEnd=function(){this.selection.moveCursorLineEnd(),this.clearSelection()},e.prototype.navigateFileEnd=function(){this.selection.moveCursorFileEnd(),this.clearSelection()},e.prototype.navigateFileStart=function(){this.selection.moveCursorFileStart(),this.clearSelection()},e.prototype.navigateWordRight=function(){this.selection.moveCursorWordRight(),this.clearSelection()},e.prototype.navigateWordLeft=function(){this.selection.moveCursorWordLeft(),this.clearSelection()},e.prototype.replace=function(e,t){t&&this.$search.set(t);var n=this.$search.find(this.session),r=0;return n?(this.$tryReplace(n,e)&&(r=1),this.selection.setSelectionRange(n),this.renderer.scrollSelectionIntoView(n.start,n.end),r):r},e.prototype.replaceAll=function(e,t){t&&this.$search.set(t);var n=this.$search.findAll(this.session),r=0;if(!n.length)return r;var i=this.getSelectionRange();this.selection.moveTo(0,0);for(var o=n.length-1;o>=0;--o)this.$tryReplace(n[o],e)&&r++;return this.selection.setSelectionRange(i),r},e.prototype.$tryReplace=function(e,t){var n=this.session.getTextRange(e);return t=this.$search.replace(n,t),null!==t?(e.end=this.session.replace(e,t),e):null},e.prototype.getLastSearchOptions=function(){return this.$search.getOptions()},e.prototype.find=function(e,t,n){t||(t={}),"string"==typeof e||e instanceof RegExp?t.needle=e:"object"==typeof e&&i.mixin(t,e);var r=this.selection.getRange();null==t.needle&&(e=this.session.getTextRange(r)||this.$search.$options.needle,e||(r=this.session.getWordRange(r.start.row,r.start.column),e=this.session.getTextRange(r)),this.$search.set({needle:e})),this.$search.set(t),t.start||this.$search.set({start:r});var o=this.$search.find(this.session);return t.preventScroll?o:o?(this.revealRange(o,n),o):(t.backwards?r.start=r.end:r.end=r.start,void this.selection.setRange(r))},e.prototype.findNext=function(e,t){this.find({skipCurrent:!0,backwards:!1},e,t)},e.prototype.findPrevious=function(e,t){this.find(e,{skipCurrent:!0,backwards:!0},t)},e.prototype.revealRange=function(e,t){this.session.unfold(e),this.selection.setSelectionRange(e);var n=this.renderer.scrollTop;this.renderer.scrollSelectionIntoView(e.start,e.end,.5),!1!==t&&this.renderer.animateScrolling(n)},e.prototype.undo=function(){this.session.getUndoManager().undo(this.session),this.renderer.scrollCursorIntoView(null,.5)},e.prototype.redo=function(){this.session.getUndoManager().redo(this.session),this.renderer.scrollCursorIntoView(null,.5)},e.prototype.destroy=function(){this.$toDestroy&&(this.$toDestroy.forEach((function(e){e.destroy()})),this.$toDestroy=null),this.$mouseHandler&&this.$mouseHandler.destroy(),this.renderer.destroy(),this._signal("destroy",this),this.session&&this.session.destroy(),this._$emitInputEvent&&this._$emitInputEvent.cancel(),this.removeAllListeners()},e.prototype.setAutoScrollEditorIntoView=function(e){if(e){var t,n=this,r=!1;this.$scrollAnchor||(this.$scrollAnchor=document.createElement("div"));var i=this.$scrollAnchor;i.style.cssText="position:absolute",this.container.insertBefore(i,this.container.firstChild);var o=this.on("changeSelection",(function(){r=!0})),s=this.renderer.on("beforeRender",(function(){r&&(t=n.renderer.container.getBoundingClientRect())})),a=this.renderer.on("afterRender",(function(){if(r&&t&&(n.isFocused()||n.searchBox&&n.searchBox.isFocused())){var e=n.renderer,o=e.$cursorLayer.$pixelPos,s=e.layerConfig,a=o.top-s.offset;r=o.top>=0&&a+t.top<0||!(o.top<s.height&&o.top+t.top+s.lineHeight>window.innerHeight)&&null,null!=r&&(i.style.top=a+"px",i.style.left=o.left+"px",i.style.height=s.lineHeight+"px",i.scrollIntoView(r)),r=t=null}}));this.setAutoScrollEditorIntoView=function(e){e||(delete this.setAutoScrollEditorIntoView,this.off("changeSelection",o),this.renderer.off("afterRender",a),this.renderer.off("beforeRender",s))}}},e.prototype.$resetCursorStyle=function(){var e=this.$cursorStyle||"ace",t=this.renderer.$cursorLayer;t&&(t.setSmoothBlinking(/smooth/.test(e)),t.isBlinking=!this.$readOnly&&"wide"!=e,o.setCssClass(t.element,"ace_slim-cursors",/slim/.test(e)))},e.prototype.prompt=function(e,t,n){var r=this;y.loadModule("ace/ext/prompt",(function(i){i.prompt(r,e,t,n)}))},e}();_.$uid=0,_.prototype.curOp=null,_.prototype.prevOp={},_.prototype.$mergeableCommands=["backspace","del","insertstring"],_.prototype.$toggleWordPairs=[["first","last"],["true","false"],["yes","no"],["width","height"],["top","bottom"],["right","left"],["on","off"],["x","y"],["get","set"],["max","min"],["horizontal","vertical"],["show","hide"],["add","remove"],["up","down"],["before","after"],["even","odd"],["in","out"],["inside","outside"],["next","previous"],["increase","decrease"],["attach","detach"],["&&","||"],["==","!="]],i.implement(_.prototype,g),y.defineOptions(_.prototype,"editor",{selectionStyle:{set:function(e){this.onSelectionChange(),this._signal("changeSelectionStyle",{data:e})},initialValue:"line"},highlightActiveLine:{set:function(){this.$updateHighlightActiveLine()},initialValue:!0},highlightSelectedWord:{set:function(e){this.$onSelectionChange()},initialValue:!0},readOnly:{set:function(e){this.textInput.setReadOnly(e),this.$resetCursorStyle()},initialValue:!1},copyWithEmptySelection:{set:function(e){this.textInput.setCopyWithEmptySelection(e)},initialValue:!1},cursorStyle:{set:function(e){this.$resetCursorStyle()},values:["ace","slim","smooth","wide"],initialValue:"ace"},mergeUndoDeltas:{values:[!1,!0,"always"],initialValue:!0},behavioursEnabled:{initialValue:!0},wrapBehavioursEnabled:{initialValue:!0},enableAutoIndent:{initialValue:!0},autoScrollEditorIntoView:{set:function(e){this.setAutoScrollEditorIntoView(e)}},keyboardHandler:{set:function(e){this.setKeyboardHandler(e)},get:function(){return this.$keybindingId},handlesSet:!0},value:{set:function(e){this.session.setValue(e)},get:function(){return this.getValue()},handlesSet:!0,hidden:!0},session:{set:function(e){this.setSession(e)},get:function(){return this.session},handlesSet:!0,hidden:!0},showLineNumbers:{set:function(e){this.renderer.$gutterLayer.setShowLineNumbers(e),this.renderer.$loop.schedule(this.renderer.CHANGE_GUTTER),e&&this.$relativeLineNumbers?k.attach(this):k.detach(this)},initialValue:!0},relativeLineNumbers:{set:function(e){this.$showLineNumbers&&e?k.attach(this):k.detach(this)}},placeholder:{set:function(e){this.$updatePlaceholder||(this.$updatePlaceholder=function(){var e=this.session&&(this.renderer.$composition||this.getValue());if(e&&this.renderer.placeholderNode)this.renderer.off("afterRender",this.$updatePlaceholder),o.removeCssClass(this.container,"ace_hasPlaceholder"),this.renderer.placeholderNode.remove(),this.renderer.placeholderNode=null;else if(e||this.renderer.placeholderNode)!e&&this.renderer.placeholderNode&&(this.renderer.placeholderNode.textContent=this.$placeholder||"");else{this.renderer.on("afterRender",this.$updatePlaceholder),o.addCssClass(this.container,"ace_hasPlaceholder");var t=o.createElement("div");t.className="ace_placeholder",t.textContent=this.$placeholder||"",this.renderer.placeholderNode=t,this.renderer.content.appendChild(this.renderer.placeholderNode)}}.bind(this),this.on("input",this.$updatePlaceholder)),this.$updatePlaceholder()}},enableKeyboardAccessibility:{set:function(e){var t={name:"blurTextInput",description:"Set focus to the editor content div to allow tabbing through the page",bindKey:"Esc",exec:function(e){e.blur(),e.renderer.content.focus()},readOnly:!0},n=function(e){e.target==this.renderer.content&&e.keyCode===S["enter"]&&(e.stopPropagation(),e.preventDefault(),this.focus())},r="ace_keyboard-focus";e?(this.textInput.getElement().setAttribute("tabindex",-1),this.renderer.content.setAttribute("tabindex",0),this.renderer.content.classList.add(r),this.renderer.content.setAttribute("aria-label","Editor, press Enter key to start editing, press Escape key to exit"),this.renderer.content.addEventListener("keyup",n.bind(this)),this.commands.addCommand(t)):(this.textInput.getElement().setAttribute("tabindex",0),this.renderer.content.setAttribute("tabindex",-1),this.renderer.content.classList.remove(r),this.renderer.content.setAttribute("aria-label",""),this.renderer.content.removeEventListener("keyup",n.bind(this)),this.commands.removeCommand(t))},initialValue:!1},customScrollbar:"renderer",hScrollBarAlwaysVisible:"renderer",vScrollBarAlwaysVisible:"renderer",highlightGutterLine:"renderer",animatedScroll:"renderer",showInvisibles:"renderer",showPrintMargin:"renderer",printMarginColumn:"renderer",printMargin:"renderer",fadeFoldWidgets:"renderer",showFoldWidgets:"renderer",displayIndentGuides:"renderer",highlightIndentGuides:"renderer",showGutter:"renderer",fontSize:"renderer",fontFamily:"renderer",maxLines:"renderer",minLines:"renderer",scrollPastEnd:"renderer",fixedWidthGutter:"renderer",theme:"renderer",hasCssTransforms:"renderer",maxPixelHeight:"renderer",useTextareaForIME:"renderer",useResizeObserver:"renderer",useSvgGutterIcons:"renderer",scrollSpeed:"$mouseHandler",dragDelay:"$mouseHandler",dragEnabled:"$mouseHandler",focusTimeout:"$mouseHandler",tooltipFollowsMouse:"$mouseHandler",firstLineNumber:"session",overwrite:"session",newLineMode:"session",useWorker:"session",useSoftTabs:"session",navigateWithinSoftTabs:"session",tabSize:"session",wrap:"session",indentedSoftWrap:"session",foldStyle:"session",mode:"session"});var k={getText:function(e,t){return(Math.abs(e.selection.lead.row-t)||t+1+(t<9?"·":""))+""},getWidth:function(e,t,n){return Math.max(t.toString().length,(n.lastRow+1).toString().length,2)*n.characterWidth},update:function(e,t){t.renderer.$loop.schedule(t.renderer.CHANGE_GUTTER)},attach:function(e){e.renderer.$gutterLayer.$renderer=this,e.on("changeSelection",this.update),this.update(null,e)},detach:function(e){e.renderer.$gutterLayer.$renderer==this&&(e.renderer.$gutterLayer.$renderer=null),e.off("changeSelection",this.update),this.update(null,e)}};t.Editor=_})),ace.define("ace/undomanager",["require","exports","module","ace/range"],(function(e,t,n){"use strict";var r=function(){function e(){this.$maxRev=0,this.$fromUndo=!1,this.$undoDepth=1/0,this.reset()}return e.prototype.addSession=function(e){this.$session=e},e.prototype.add=function(e,t,n){if(!this.$fromUndo&&e!=this.$lastDelta){if(this.$keepRedoStack||(this.$redoStack.length=0),!1===t||!this.lastDeltas){this.lastDeltas=[];var r=this.$undoStack.length;r>this.$undoDepth-1&&this.$undoStack.splice(0,r-this.$undoDepth+1),this.$undoStack.push(this.lastDeltas),e.id=this.$rev=++this.$maxRev}"remove"!=e.action&&"insert"!=e.action||(this.$lastDelta=e),this.lastDeltas.push(e)}},e.prototype.addSelection=function(e,t){this.selections.push({value:e,rev:t||this.$rev})},e.prototype.startNewGroup=function(){return this.lastDeltas=null,this.$rev},e.prototype.markIgnored=function(e,t){null==t&&(t=this.$rev+1);for(var n=this.$undoStack,r=n.length;r--;){var i=n[r][0];if(i.id<=e)break;i.id<t&&(i.ignore=!0)}this.lastDeltas=null},e.prototype.getSelection=function(e,t){for(var n=this.selections,r=n.length;r--;){var i=n[r];if(i.rev<e)return t&&(i=n[r+1]),i}},e.prototype.getRevision=function(){return this.$rev},e.prototype.getDeltas=function(e,t){null==t&&(t=this.$rev+1);for(var n=this.$undoStack,r=null,i=0,o=n.length;o--;){var s=n[o][0];if(s.id<t&&!r&&(r=o+1),s.id<=e){i=o+1;break}}return n.slice(i,r)},e.prototype.getChangedRanges=function(e,t){null==t&&(t=this.$rev+1)},e.prototype.getChangedLines=function(e,t){null==t&&(t=this.$rev+1)},e.prototype.undo=function(e,t){this.lastDeltas=null;var n=this.$undoStack;if(i(n,n.length)){e||(e=this.$session),this.$redoStackBaseRev!==this.$rev&&this.$redoStack.length&&(this.$redoStack=[]),this.$fromUndo=!0;var r=n.pop(),o=null;return r&&(o=e.undoChanges(r,t),this.$redoStack.push(r),this.$syncRev()),this.$fromUndo=!1,o}},e.prototype.redo=function(e,t){if(this.lastDeltas=null,e||(e=this.$session),this.$fromUndo=!0,this.$redoStackBaseRev!=this.$rev){var n=this.getDeltas(this.$redoStackBaseRev,this.$rev+1);y(this.$redoStack,n),this.$redoStackBaseRev=this.$rev,this.$redoStack.forEach((function(e){e[0].id=++this.$maxRev}),this)}var r=this.$redoStack.pop(),i=null;return r&&(i=e.redoChanges(r,t),this.$undoStack.push(r),this.$syncRev()),this.$fromUndo=!1,i},e.prototype.$syncRev=function(){var e=this.$undoStack,t=e[e.length-1],n=t&&t[0].id||0;this.$redoStackBaseRev=n,this.$rev=n},e.prototype.reset=function(){this.lastDeltas=null,this.$lastDelta=null,this.$undoStack=[],this.$redoStack=[],this.$rev=0,this.mark=0,this.$redoStackBaseRev=this.$rev,this.selections=[]},e.prototype.canUndo=function(){return this.$undoStack.length>0},e.prototype.canRedo=function(){return this.$redoStack.length>0},e.prototype.bookmark=function(e){void 0==e&&(e=this.$rev),this.mark=e},e.prototype.isAtBookmark=function(){return this.$rev===this.mark},e.prototype.toJSON=function(){},e.prototype.fromJSON=function(){},e.prototype.$prettyPrint=function(e){return e?c(e):c(this.$undoStack)+"\n---\n"+c(this.$redoStack)},e}();function i(e,t){for(var n=t;n--;){var r=e[n];if(r&&!r[0].ignore){while(n<t-1){var i=f(e[n],e[n+1]);e[n]=i[0],e[n+1]=i[1],n++}return!0}}}r.prototype.hasUndo=r.prototype.canUndo,r.prototype.hasRedo=r.prototype.canRedo,r.prototype.isClean=r.prototype.isAtBookmark,r.prototype.markClean=r.prototype.bookmark;var o=e("./range").Range,s=o.comparePoints;o.comparePoints;function a(e){return{row:e.row,column:e.column}}function l(e){return{start:a(e.start),end:a(e.end),action:e.action,lines:e.lines.slice()}}function c(e){if(e=e||this,Array.isArray(e))return e.map(c).join("\n");var t="";return e.action?(t="insert"==e.action?"+":"-",t+="["+e.lines+"]"):e.value&&(t=Array.isArray(e.value)?e.value.map(u).join("\n"):u(e.value)),e.start&&(t+=u(e)),(e.id||e.rev)&&(t+="\t("+(e.id||e.rev)+")"),t}function u(e){return e.start.row+":"+e.start.column+"=>"+e.end.row+":"+e.end.column}function h(e,t){var n="insert"==e.action,r="insert"==t.action;if(n&&r)if(s(t.start,e.end)>=0)p(t,e,-1);else{if(!(s(t.start,e.start)<=0))return null;p(e,t,1)}else if(n&&!r)if(s(t.start,e.end)>=0)p(t,e,-1);else{if(!(s(t.end,e.start)<=0))return null;p(e,t,-1)}else if(!n&&r)if(s(t.start,e.start)>=0)p(t,e,1);else{if(!(s(t.start,e.start)<=0))return null;p(e,t,1)}else if(!n&&!r)if(s(t.start,e.start)>=0)p(t,e,1);else{if(!(s(t.end,e.start)<=0))return null;p(e,t,-1)}return[t,e]}function f(e,t){for(var n=e.length;n--;)for(var r=0;r<t.length;r++)if(!h(e[n],t[r])){while(n<e.length){while(r--)h(t[r],e[n]);r=t.length,n++}return[e,t]}return e.selectionBefore=t.selectionBefore=e.selectionAfter=t.selectionAfter=null,[t,e]}function d(e,t){var n="insert"==e.action,r="insert"==t.action;if(n&&r)s(e.start,t.start)<0?p(t,e,1):p(e,t,1);else if(n&&!r)s(e.start,t.end)>=0?p(e,t,-1):(s(e.start,t.start)<=0||p(e,o.fromPoints(t.start,e.start),-1),p(t,e,1));else if(!n&&r)s(t.start,e.end)>=0?p(t,e,-1):(s(t.start,e.start)<=0||p(t,o.fromPoints(e.start,t.start),-1),p(e,t,1));else if(!n&&!r)if(s(t.start,e.end)>=0)p(t,e,-1);else{var i,a;if(!(s(t.end,e.start)<=0))return s(e.start,t.start)<0&&(i=e,e=m(e,t.start)),s(e.end,t.end)>0&&(a=m(e,t.end)),g(t.end,e.start,e.end,-1),a&&!i&&(e.lines=a.lines,e.start=a.start,e.end=a.end,a=e),[t,i,a].filter(Boolean);p(e,t,-1)}return[t,e]}function p(e,t,n){g(e.start,t.start,t.end,n),g(e.end,t.start,t.end,n)}function g(e,t,n,r){e.row==(1==r?t:n).row&&(e.column+=r*(n.column-t.column)),e.row+=r*(n.row-t.row)}function m(e,t){var n=e.lines,r=e.end;e.end=a(t);var i=e.end.row-e.start.row,o=n.splice(i,n.length),s=i?t.column:t.column-e.start.column;n.push(o[0].substring(0,s)),o[0]=o[0].substr(s);var l={start:a(t),end:r,lines:o,action:e.action};return l}function v(e,t){t=l(t);for(var n=e.length;n--;){for(var r=e[n],i=0;i<r.length;i++){var o=r[i],s=d(o,t);t=s[0],2!=s.length&&(s[2]?(r.splice(i+1,1,s[1],s[2]),i++):s[1]||(r.splice(i,1),i--))}r.length||e.splice(n,1)}return e}function y(e,t){for(var n=0;n<t.length;n++)for(var r=t[n],i=0;i<r.length;i++)v(e,r[i])}t.UndoManager=r})),ace.define("ace/layer/lines",["require","exports","module","ace/lib/dom"],(function(e,t,n){"use strict";var r=e("../lib/dom"),i=function(){function e(e,t){this.element=e,this.canvasHeight=t||5e5,this.element.style.height=2*this.canvasHeight+"px",this.cells=[],this.cellCache=[],this.$offsetCoefficient=0}return e.prototype.moveContainer=function(e){r.translate(this.element,0,-e.firstRowScreen*e.lineHeight%this.canvasHeight-e.offset*this.$offsetCoefficient)},e.prototype.pageChanged=function(e,t){return Math.floor(e.firstRowScreen*e.lineHeight/this.canvasHeight)!==Math.floor(t.firstRowScreen*t.lineHeight/this.canvasHeight)},e.prototype.computeLineTop=function(e,t,n){var r=t.firstRowScreen*t.lineHeight,i=Math.floor(r/this.canvasHeight),o=n.documentToScreenRow(e,0)*t.lineHeight;return o-i*this.canvasHeight},e.prototype.computeLineHeight=function(e,t,n){return t.lineHeight*n.getRowLineCount(e)},e.prototype.getLength=function(){return this.cells.length},e.prototype.get=function(e){return this.cells[e]},e.prototype.shift=function(){this.$cacheCell(this.cells.shift())},e.prototype.pop=function(){this.$cacheCell(this.cells.pop())},e.prototype.push=function(e){if(Array.isArray(e)){this.cells.push.apply(this.cells,e);for(var t=r.createFragment(this.element),n=0;n<e.length;n++)t.appendChild(e[n].element);this.element.appendChild(t)}else this.cells.push(e),this.element.appendChild(e.element)},e.prototype.unshift=function(e){if(Array.isArray(e)){this.cells.unshift.apply(this.cells,e);for(var t=r.createFragment(this.element),n=0;n<e.length;n++)t.appendChild(e[n].element);this.element.firstChild?this.element.insertBefore(t,this.element.firstChild):this.element.appendChild(t)}else this.cells.unshift(e),this.element.insertAdjacentElement("afterbegin",e.element)},e.prototype.last=function(){return this.cells.length?this.cells[this.cells.length-1]:null},e.prototype.$cacheCell=function(e){e&&(e.element.remove(),this.cellCache.push(e))},e.prototype.createCell=function(e,t,n,i){var o=this.cellCache.pop();if(!o){var s=r.createElement("div");i&&i(s),this.element.appendChild(s),o={element:s,text:"",row:e}}return o.row=e,o},e}();t.Lines=i})),ace.define("ace/layer/gutter",["require","exports","module","ace/lib/dom","ace/lib/oop","ace/lib/lang","ace/lib/event_emitter","ace/layer/lines"],(function(e,t,n){"use strict";var r=e("../lib/dom"),i=e("../lib/oop"),o=e("../lib/lang"),s=e("../lib/event_emitter").EventEmitter,a=e("./lines").Lines,l=function(){function e(e){this.element=r.createElement("div"),this.element.className="ace_layer ace_gutter-layer",e.appendChild(this.element),this.setShowFoldWidgets(this.$showFoldWidgets),this.gutterWidth=0,this.$annotations=[],this.$updateAnnotations=this.$updateAnnotations.bind(this),this.$lines=new a(this.element),this.$lines.$offsetCoefficient=1}return e.prototype.setSession=function(e){this.session&&this.session.off("change",this.$updateAnnotations),this.session=e,e&&e.on("change",this.$updateAnnotations)},e.prototype.addGutterDecoration=function(e,t){window.console&&console.warn&&console.warn("deprecated use session.addGutterDecoration"),this.session.addGutterDecoration(e,t)},e.prototype.removeGutterDecoration=function(e,t){window.console&&console.warn&&console.warn("deprecated use session.removeGutterDecoration"),this.session.removeGutterDecoration(e,t)},e.prototype.setAnnotations=function(e){this.$annotations=[];for(var t=0;t<e.length;t++){var n=e[t],r=n.row,i=this.$annotations[r];i||(i=this.$annotations[r]={text:[],type:[]});var s=n.text,a=n.type;s=s?o.escapeHTML(s):n.html||"",-1===i.text.indexOf(s)&&(i.text.push(s),i.type.push(a));var l=n.className;l?i.className=l:"error"==a?i.className=" ace_error":"warning"==a&&" ace_error"!=i.className?i.className=" ace_warning":"info"!=a||i.className||(i.className=" ace_info")}},e.prototype.$updateAnnotations=function(e){if(this.$annotations.length){var t=e.start.row,n=e.end.row-t;if(0===n);else if("remove"==e.action)this.$annotations.splice(t,n+1,null);else{var r=new Array(n+1);r.unshift(t,1),this.$annotations.splice.apply(this.$annotations,r)}}},e.prototype.update=function(e){this.config=e;var t=this.session,n=e.firstRow,r=Math.min(e.lastRow+e.gutterOffset,t.getLength()-1);this.oldLastRow=r,this.config=e,this.$lines.moveContainer(e),this.$updateCursorRow();var i=t.getNextFoldLine(n),o=i?i.start.row:1/0,s=null,a=-1,l=n;while(1){if(l>o&&(l=i.end.row+1,i=t.getNextFoldLine(l,i),o=i?i.start.row:1/0),l>r){while(this.$lines.getLength()>a+1)this.$lines.pop();break}s=this.$lines.get(++a),s?s.row=l:(s=this.$lines.createCell(l,e,this.session,c),this.$lines.push(s)),this.$renderCell(s,e,i,l),l++}this._signal("afterRender"),this.$updateGutterWidth(e)},e.prototype.$updateGutterWidth=function(e){var t=this.session,n=t.gutterRenderer||this.$renderer,r=t.$firstLineNumber,i=this.$lines.last()?this.$lines.last().text:"";(this.$fixedWidth||t.$useWrapMode)&&(i=t.getLength()+r-1);var o=n?n.getWidth(t,i,e):i.toString().length*e.characterWidth,s=this.$padding||this.$computePadding();o+=s.left+s.right,o===this.gutterWidth||isNaN(o)||(this.gutterWidth=o,this.element.parentNode.style.width=this.element.style.width=Math.ceil(this.gutterWidth)+"px",this._signal("changeGutterWidth",o))},e.prototype.$updateCursorRow=function(){if(this.$highlightGutterLine){var e=this.session.selection.getCursor();this.$cursorRow!==e.row&&(this.$cursorRow=e.row)}},e.prototype.updateLineHighlight=function(){if(this.$highlightGutterLine){var e=this.session.selection.cursor.row;if(this.$cursorRow=e,!this.$cursorCell||this.$cursorCell.row!=e){this.$cursorCell&&(this.$cursorCell.element.className=this.$cursorCell.element.className.replace("ace_gutter-active-line ",""));var t=this.$lines.cells;this.$cursorCell=null;for(var n=0;n<t.length;n++){var r=t[n];if(r.row>=this.$cursorRow){if(r.row>this.$cursorRow){var i=this.session.getFoldLine(this.$cursorRow);if(!(n>0&&i&&i.start.row==t[n-1].row))break;r=t[n-1]}r.element.className="ace_gutter-active-line "+r.element.className,this.$cursorCell=r;break}}}}},e.prototype.scrollLines=function(e){var t=this.config;if(this.config=e,this.$updateCursorRow(),this.$lines.pageChanged(t,e))return this.update(e);this.$lines.moveContainer(e);var n=Math.min(e.lastRow+e.gutterOffset,this.session.getLength()-1),r=this.oldLastRow;if(this.oldLastRow=n,!t||r<e.firstRow)return this.update(e);if(n<t.firstRow)return this.update(e);if(t.firstRow<e.firstRow)for(var i=this.session.getFoldedRowCount(t.firstRow,e.firstRow-1);i>0;i--)this.$lines.shift();if(r>n)for(i=this.session.getFoldedRowCount(n+1,r);i>0;i--)this.$lines.pop();e.firstRow<t.firstRow&&this.$lines.unshift(this.$renderLines(e,e.firstRow,t.firstRow-1)),n>r&&this.$lines.push(this.$renderLines(e,r+1,n)),this.updateLineHighlight(),this._signal("afterRender"),this.$updateGutterWidth(e)},e.prototype.$renderLines=function(e,t,n){var r=[],i=t,o=this.session.getNextFoldLine(i),s=o?o.start.row:1/0;while(1){if(i>s&&(i=o.end.row+1,o=this.session.getNextFoldLine(i,o),s=o?o.start.row:1/0),i>n)break;var a=this.$lines.createCell(i,e,this.session,c);this.$renderCell(a,e,o,i),r.push(a),i++}return r},e.prototype.$renderCell=function(e,t,n,i){var o=e.element,s=this.session,a=o.childNodes[0],l=o.childNodes[1],c=o.childNodes[2],u=s.$firstLineNumber,h=s.$breakpoints,f=s.$decorations,d=s.gutterRenderer||this.$renderer,p=this.$showFoldWidgets&&s.foldWidgets,g=n?n.start.row:Number.MAX_VALUE,m=t.lineHeight+"px";if(this.$useSvgGutterIcons?(y="ace_gutter-cell_svg-icons ",this.$annotations[i]?(c.className="ace_icon_svg"+this.$annotations[i].className,r.setStyle(c.style,"height",m),r.setStyle(c.style,"display","block")):r.setStyle(c.style,"display","none")):(y="ace_gutter-cell ",r.setStyle(c.style,"display","none")),this.$highlightGutterLine&&(i==this.$cursorRow||n&&i<this.$cursorRow&&i>=g&&this.$cursorRow<=n.end.row)&&(y+="ace_gutter-active-line ",this.$cursorCell!=e&&(this.$cursorCell&&(this.$cursorCell.element.className=this.$cursorCell.element.className.replace("ace_gutter-active-line ","")),this.$cursorCell=e)),h[i]&&(y+=h[i]),f[i]&&(y+=f[i]),this.$annotations[i]&&(y+=this.$annotations[i].className),o.className!=y&&(o.className=y),p){var v=p[i];null==v&&(v=p[i]=s.getFoldWidget(i))}if(v){var y="ace_fold-widget ace_"+v;"start"==v&&i==g&&i<n.end.row?y+=" ace_closed":y+=" ace_open",l.className!=y&&(l.className=y),r.setStyle(l.style,"height",m),r.setStyle(l.style,"display","inline-block")}else l&&r.setStyle(l.style,"display","none");var w=(d?d.getText(s,i):i+u).toString();return w!==a.data&&(a.data=w),r.setStyle(e.element.style,"height",this.$lines.computeLineHeight(i,t,s)+"px"),r.setStyle(e.element.style,"top",this.$lines.computeLineTop(i,t,s)+"px"),e.text=w,e},e.prototype.setHighlightGutterLine=function(e){this.$highlightGutterLine=e},e.prototype.setShowLineNumbers=function(e){this.$renderer=!e&&{getWidth:function(){return 0},getText:function(){return""}}},e.prototype.getShowLineNumbers=function(){return this.$showLineNumbers},e.prototype.setShowFoldWidgets=function(e){e?r.addCssClass(this.element,"ace_folding-enabled"):r.removeCssClass(this.element,"ace_folding-enabled"),this.$showFoldWidgets=e,this.$padding=null},e.prototype.getShowFoldWidgets=function(){return this.$showFoldWidgets},e.prototype.$computePadding=function(){if(!this.element.firstChild)return{left:0,right:0};var e=r.computedStyle(this.element.firstChild);return this.$padding={},this.$padding.left=(parseInt(e.borderLeftWidth)||0)+(parseInt(e.paddingLeft)||0)+1,this.$padding.right=(parseInt(e.borderRightWidth)||0)+(parseInt(e.paddingRight)||0),this.$padding},e.prototype.getRegion=function(e){var t=this.$padding||this.$computePadding(),n=this.element.getBoundingClientRect();return e.x<t.left+n.left?"markers":this.$showFoldWidgets&&e.x>n.right-t.right?"foldWidgets":void 0},e}();function c(e){var t=document.createTextNode("");e.appendChild(t);var n=r.createElement("span");e.appendChild(n);var i=r.createElement("span");return e.appendChild(i),e}l.prototype.$fixedWidth=!1,l.prototype.$highlightGutterLine=!0,l.prototype.$renderer="",l.prototype.$showLineNumbers=!0,l.prototype.$showFoldWidgets=!0,i.implement(l.prototype,s),t.Gutter=l})),ace.define("ace/layer/marker",["require","exports","module","ace/range","ace/lib/dom"],(function(e,t,n){"use strict";var r=e("../range").Range,i=e("../lib/dom"),o=function(){function e(e){this.element=i.createElement("div"),this.element.className="ace_layer ace_marker-layer",e.appendChild(this.element)}return e.prototype.setPadding=function(e){this.$padding=e},e.prototype.setSession=function(e){this.session=e},e.prototype.setMarkers=function(e){this.markers=e},e.prototype.elt=function(e,t){var n=-1!=this.i&&this.element.childNodes[this.i];n?this.i++:(n=document.createElement("div"),this.element.appendChild(n),this.i=-1),n.style.cssText=t,n.className=e},e.prototype.update=function(e){if(e){var t;for(var n in this.config=e,this.i=0,this.markers){var r=this.markers[n];if(r.range){var i=r.range.clipRows(e.firstRow,e.lastRow);if(!i.isEmpty())if(i=i.toScreenRange(this.session),r.renderer){var o=this.$getTop(i.start.row,e),s=this.$padding+i.start.column*e.characterWidth;r.renderer(t,i,s,o,e)}else"fullLine"==r.type?this.drawFullLineMarker(t,i,r.clazz,e):"screenLine"==r.type?this.drawScreenLineMarker(t,i,r.clazz,e):i.isMultiLine()?"text"==r.type?this.drawTextMarker(t,i,r.clazz,e):this.drawMultiLineMarker(t,i,r.clazz,e):this.drawSingleLineMarker(t,i,r.clazz+" ace_start ace_br15",e)}else r.update(t,this,this.session,e)}if(-1!=this.i)while(this.i<this.element.childElementCount)this.element.removeChild(this.element.lastChild)}},e.prototype.$getTop=function(e,t){return(e-t.firstRowScreen)*t.lineHeight},e.prototype.drawTextMarker=function(e,t,n,i,o){for(var a=this.session,l=t.start.row,c=t.end.row,u=l,h=0,f=0,d=a.getScreenLastRowColumn(u),p=new r(u,t.start.column,u,f);u<=c;u++)p.start.row=p.end.row=u,p.start.column=u==l?t.start.column:a.getRowWrapIndent(u),p.end.column=d,h=f,f=d,d=u+1<c?a.getScreenLastRowColumn(u+1):u==c?0:t.end.column,this.drawSingleLineMarker(e,p,n+(u==l?" ace_start":"")+" ace_br"+s(u==l||u==l+1&&t.start.column,h<f,f>d,u==c),i,u==c?0:1,o)},e.prototype.drawMultiLineMarker=function(e,t,n,r,i){var o=this.$padding,s=r.lineHeight,a=this.$getTop(t.start.row,r),l=o+t.start.column*r.characterWidth;if(i=i||"",this.session.$bidiHandler.isBidiRow(t.start.row)){var c=t.clone();c.end.row=c.start.row,c.end.column=this.session.getLine(c.start.row).length,this.drawBidiSingleLineMarker(e,c,n+" ace_br1 ace_start",r,null,i)}else this.elt(n+" ace_br1 ace_start","height:"+s+"px;right:0;top:"+a+"px;left:"+l+"px;"+(i||""));if(this.session.$bidiHandler.isBidiRow(t.end.row)){c=t.clone();c.start.row=c.end.row,c.start.column=0,this.drawBidiSingleLineMarker(e,c,n+" ace_br12",r,null,i)}else{a=this.$getTop(t.end.row,r);var u=t.end.column*r.characterWidth;this.elt(n+" ace_br12","height:"+s+"px;width:"+u+"px;top:"+a+"px;left:"+o+"px;"+(i||""))}if(s=(t.end.row-t.start.row-1)*r.lineHeight,!(s<=0)){a=this.$getTop(t.start.row+1,r);var h=(t.start.column?1:0)|(t.end.column?0:8);this.elt(n+(h?" ace_br"+h:""),"height:"+s+"px;right:0;top:"+a+"px;left:"+o+"px;"+(i||""))}},e.prototype.drawSingleLineMarker=function(e,t,n,r,i,o){if(this.session.$bidiHandler.isBidiRow(t.start.row))return this.drawBidiSingleLineMarker(e,t,n,r,i,o);var s=r.lineHeight,a=(t.end.column+(i||0)-t.start.column)*r.characterWidth,l=this.$getTop(t.start.row,r),c=this.$padding+t.start.column*r.characterWidth;this.elt(n,"height:"+s+"px;width:"+a+"px;top:"+l+"px;left:"+c+"px;"+(o||""))},e.prototype.drawBidiSingleLineMarker=function(e,t,n,r,i,o){var s=r.lineHeight,a=this.$getTop(t.start.row,r),l=this.$padding,c=this.session.$bidiHandler.getSelections(t.start.column,t.end.column);c.forEach((function(e){this.elt(n,"height:"+s+"px;width:"+(e.width+(i||0))+"px;top:"+a+"px;left:"+(l+e.left)+"px;"+(o||""))}),this)},e.prototype.drawFullLineMarker=function(e,t,n,r,i){var o=this.$getTop(t.start.row,r),s=r.lineHeight;t.start.row!=t.end.row&&(s+=this.$getTop(t.end.row,r)-o),this.elt(n,"height:"+s+"px;top:"+o+"px;left:0;right:0;"+(i||""))},e.prototype.drawScreenLineMarker=function(e,t,n,r,i){var o=this.$getTop(t.start.row,r),s=r.lineHeight;this.elt(n,"height:"+s+"px;top:"+o+"px;left:0;right:0;"+(i||""))},e}();function s(e,t,n,r){return(e?1:0)|(t?2:0)|(n?4:0)|(r?8:0)}o.prototype.$padding=0,t.Marker=o})),ace.define("ace/layer/text",["require","exports","module","ace/lib/oop","ace/lib/dom","ace/lib/lang","ace/layer/lines","ace/lib/event_emitter"],(function(e,t,n){"use strict";var r=e("../lib/oop"),i=e("../lib/dom"),o=e("../lib/lang"),s=e("./lines").Lines,a=e("../lib/event_emitter").EventEmitter,l=function(){function e(e){this.dom=i,this.element=this.dom.createElement("div"),this.element.className="ace_layer ace_text-layer",e.appendChild(this.element),this.$updateEolChar=this.$updateEolChar.bind(this),this.$lines=new s(this.element)}return e.prototype.$updateEolChar=function(){var e=this.session.doc,t="\n"==e.getNewLineCharacter()&&"windows"!=e.getNewLineMode(),n=t?this.EOL_CHAR_LF:this.EOL_CHAR_CRLF;if(this.EOL_CHAR!=n)return this.EOL_CHAR=n,!0},e.prototype.setPadding=function(e){this.$padding=e,this.element.style.margin="0 "+e+"px"},e.prototype.getLineHeight=function(){return this.$fontMetrics.$characterSize.height||0},e.prototype.getCharacterWidth=function(){return this.$fontMetrics.$characterSize.width||0},e.prototype.$setFontMetrics=function(e){this.$fontMetrics=e,this.$fontMetrics.on("changeCharacterSize",function(e){this._signal("changeCharacterSize",e)}.bind(this)),this.$pollSizeChanges()},e.prototype.checkForSizeChanges=function(){this.$fontMetrics.checkForSizeChanges()},e.prototype.$pollSizeChanges=function(){return this.$pollSizeChangesTimer=this.$fontMetrics.$pollSizeChanges()},e.prototype.setSession=function(e){this.session=e,e&&this.$computeTabString()},e.prototype.setShowInvisibles=function(e){return this.showInvisibles!=e&&(this.showInvisibles=e,"string"==typeof e?(this.showSpaces=/tab/i.test(e),this.showTabs=/space/i.test(e),this.showEOL=/eol/i.test(e)):this.showSpaces=this.showTabs=this.showEOL=e,this.$computeTabString(),!0)},e.prototype.setDisplayIndentGuides=function(e){return this.displayIndentGuides!=e&&(this.displayIndentGuides=e,this.$computeTabString(),!0)},e.prototype.setHighlightIndentGuides=function(e){return this.$highlightIndentGuides!==e&&(this.$highlightIndentGuides=e,e)},e.prototype.$computeTabString=function(){var e=this.session.getTabSize();this.tabSize=e;for(var t=this.$tabStrings=[0],n=1;n<e+1;n++)if(this.showTabs){var r=this.dom.createElement("span");r.className="ace_invisible ace_invisible_tab",r.textContent=o.stringRepeat(this.TAB_CHAR,n),t.push(r)}else t.push(this.dom.createTextNode(o.stringRepeat(" ",n),this.element));if(this.displayIndentGuides){this.$indentGuideRe=/\s\S| \t|\t |\s$/;var i="ace_indent-guide",s=this.showSpaces?" ace_invisible ace_invisible_space":"",a=this.showSpaces?o.stringRepeat(this.SPACE_CHAR,this.tabSize):o.stringRepeat(" ",this.tabSize),l=this.showTabs?" ace_invisible ace_invisible_tab":"",c=this.showTabs?o.stringRepeat(this.TAB_CHAR,this.tabSize):a;r=this.dom.createElement("span");r.className=i+s,r.textContent=a,this.$tabStrings[" "]=r;r=this.dom.createElement("span");r.className=i+l,r.textContent=c,this.$tabStrings["\t"]=r}},e.prototype.updateLines=function(e,t,n){if(this.config.lastRow!=e.lastRow||this.config.firstRow!=e.firstRow)return this.update(e);this.config=e;for(var r=Math.max(t,e.firstRow),i=Math.min(n,e.lastRow),o=this.element.childNodes,s=0,a=e.firstRow;a<r;a++){var l=this.session.getFoldLine(a);if(l){if(l.containsRow(r)){r=l.start.row;break}a=l.end.row}s++}var c=!1,u=(a=r,l=this.session.getNextFoldLine(a),l?l.start.row:1/0);while(1){if(a>u&&(a=l.end.row+1,l=this.session.getNextFoldLine(a,l),u=l?l.start.row:1/0),a>i)break;var h=o[s++];if(h){this.dom.removeChildren(h),this.$renderLine(h,a,a==u&&l),c&&(h.style.top=this.$lines.computeLineTop(a,e,this.session)+"px");var f=e.lineHeight*this.session.getRowLength(a)+"px";h.style.height!=f&&(c=!0,h.style.height=f)}a++}if(c)while(s<this.$lines.cells.length){var d=this.$lines.cells[s++];d.element.style.top=this.$lines.computeLineTop(d.row,e,this.session)+"px"}},e.prototype.scrollLines=function(e){var t=this.config;if(this.config=e,this.$lines.pageChanged(t,e))return this.update(e);this.$lines.moveContainer(e);var n=e.lastRow,r=t?t.lastRow:-1;if(!t||r<e.firstRow)return this.update(e);if(n<t.firstRow)return this.update(e);if(!t||t.lastRow<e.firstRow)return this.update(e);if(e.lastRow<t.firstRow)return this.update(e);if(t.firstRow<e.firstRow)for(var i=this.session.getFoldedRowCount(t.firstRow,e.firstRow-1);i>0;i--)this.$lines.shift();if(t.lastRow>e.lastRow)for(i=this.session.getFoldedRowCount(e.lastRow+1,t.lastRow);i>0;i--)this.$lines.pop();e.firstRow<t.firstRow&&this.$lines.unshift(this.$renderLinesFragment(e,e.firstRow,t.firstRow-1)),e.lastRow>t.lastRow&&this.$lines.push(this.$renderLinesFragment(e,t.lastRow+1,e.lastRow)),this.$highlightIndentGuide()},e.prototype.$renderLinesFragment=function(e,t,n){var r=[],o=t,s=this.session.getNextFoldLine(o),a=s?s.start.row:1/0;while(1){if(o>a&&(o=s.end.row+1,s=this.session.getNextFoldLine(o,s),a=s?s.start.row:1/0),o>n)break;var l=this.$lines.createCell(o,e,this.session),c=l.element;this.dom.removeChildren(c),i.setStyle(c.style,"height",this.$lines.computeLineHeight(o,e,this.session)+"px"),i.setStyle(c.style,"top",this.$lines.computeLineTop(o,e,this.session)+"px"),this.$renderLine(c,o,o==a&&s),this.$useLineGroups()?c.className="ace_line_group":c.className="ace_line",r.push(l),o++}return r},e.prototype.update=function(e){this.$lines.moveContainer(e),this.config=e;var t=e.firstRow,n=e.lastRow,r=this.$lines;while(r.getLength())r.pop();r.push(this.$renderLinesFragment(e,t,n))},e.prototype.$renderToken=function(e,t,n,r){var i,s=this,a=/(\t)|( +)|([\x00-\x1f\x80-\xa0\xad\u1680\u180E\u2000-\u200f\u2028\u2029\u202F\u205F\uFEFF\uFFF9-\uFFFC\u2066\u2067\u2068\u202A\u202B\u202D\u202E\u202C\u2069]+)|(\u3000)|([\u1100-\u115F\u11A3-\u11A7\u11FA-\u11FF\u2329-\u232A\u2E80-\u2E99\u2E9B-\u2EF3\u2F00-\u2FD5\u2FF0-\u2FFB\u3001-\u303E\u3041-\u3096\u3099-\u30FF\u3105-\u312D\u3131-\u318E\u3190-\u31BA\u31C0-\u31E3\u31F0-\u321E\u3220-\u3247\u3250-\u32FE\u3300-\u4DBF\u4E00-\uA48C\uA490-\uA4C6\uA960-\uA97C\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFAFF\uFE10-\uFE19\uFE30-\uFE52\uFE54-\uFE66\uFE68-\uFE6B\uFF01-\uFF60\uFFE0-\uFFE6]|[\uD800-\uDBFF][\uDC00-\uDFFF])/g,l=this.dom.createFragment(this.element),c=0;while(i=a.exec(r)){var u=i[1],h=i[2],f=i[3],d=i[4],p=i[5];if(s.showSpaces||!h){var g=c!=i.index?r.slice(c,i.index):"";if(c=i.index+i[0].length,g&&l.appendChild(this.dom.createTextNode(g,this.element)),u){var m=s.session.getScreenTabSize(t+i.index);l.appendChild(s.$tabStrings[m].cloneNode(!0)),t+=m-1}else if(h)if(s.showSpaces){var v=this.dom.createElement("span");v.className="ace_invisible ace_invisible_space",v.textContent=o.stringRepeat(s.SPACE_CHAR,h.length),l.appendChild(v)}else l.appendChild(this.com.createTextNode(h,this.element));else if(f){v=this.dom.createElement("span");v.className="ace_invisible ace_invisible_space ace_invalid",v.textContent=o.stringRepeat(s.SPACE_CHAR,f.length),l.appendChild(v)}else if(d){t+=1;v=this.dom.createElement("span");v.style.width=2*s.config.characterWidth+"px",v.className=s.showSpaces?"ace_cjk ace_invisible ace_invisible_space":"ace_cjk",v.textContent=s.showSpaces?s.SPACE_CHAR:d,l.appendChild(v)}else if(p){t+=1;v=this.dom.createElement("span");v.style.width=2*s.config.characterWidth+"px",v.className="ace_cjk",v.textContent=p,l.appendChild(v)}}}if(l.appendChild(this.dom.createTextNode(c?r.slice(c):r,this.element)),this.$textToken[n.type])e.appendChild(l);else{var y="ace_"+n.type.replace(/\./g," ace_");v=this.dom.createElement("span");"fold"==n.type&&(v.style.width=n.value.length*this.config.characterWidth+"px"),v.className=y,v.appendChild(l),e.appendChild(v)}return t+r.length},e.prototype.renderIndentGuide=function(e,t,n){var r=t.search(this.$indentGuideRe);if(r<=0||r>=n)return t;if(" "==t[0]){r-=r%this.tabSize;for(var i=r/this.tabSize,o=0;o<i;o++)e.appendChild(this.$tabStrings[" "].cloneNode(!0));return this.$highlightIndentGuide(),t.substr(r)}if("\t"==t[0]){for(o=0;o<r;o++)e.appendChild(this.$tabStrings["\t"].cloneNode(!0));return this.$highlightIndentGuide(),t.substr(r)}return this.$highlightIndentGuide(),t},e.prototype.$highlightIndentGuide=function(){if(this.$highlightIndentGuides&&this.displayIndentGuides){this.$highlightIndentGuideMarker={indentLevel:void 0,start:void 0,end:void 0,dir:void 0};var e=this.session.doc.$lines;if(e){var t=this.session.selection.getCursor(),n=/^\s*/.exec(this.session.doc.getLine(t.row))[0].length,r=Math.floor(n/this.tabSize);this.$highlightIndentGuideMarker={indentLevel:r,start:t.row};var i=this.session.$bracketHighlight;if(i)for(var o=this.session.$bracketHighlight.ranges,s=0;s<o.length;s++)if(t.row!==o[s].start.row){this.$highlightIndentGuideMarker.end=o[s].start.row,t.row>o[s].start.row?this.$highlightIndentGuideMarker.dir=-1:this.$highlightIndentGuideMarker.dir=1;break}if(!this.$highlightIndentGuideMarker.end&&""!==e[t.row]&&t.column===e[t.row].length){this.$highlightIndentGuideMarker.dir=1;for(s=t.row+1;s<e.length;s++){var a=e[s],l=/^\s*/.exec(a)[0].length;if(""!==a&&(this.$highlightIndentGuideMarker.end=s,l<=n))break}}this.$renderHighlightIndentGuide()}}},e.prototype.$clearActiveIndentGuide=function(){for(var e=this.$lines.cells,t=0;t<e.length;t++){var n=e[t],r=n.element.childNodes;if(r.length>0)for(var i=0;i<r.length;i++)if(r[i].classList&&r[i].classList.contains("ace_indent-guide-active")){r[i].classList.remove("ace_indent-guide-active");break}}},e.prototype.$setIndentGuideActive=function(e,t){var n=this.session.doc.getLine(e.row);if(""!==n){var r=e.element.childNodes;if(r){var i=r[t-1];i&&i.classList&&i.classList.contains("ace_indent-guide")&&i.classList.add("ace_indent-guide-active")}}},e.prototype.$renderHighlightIndentGuide=function(){if(this.$lines){var e=this.$lines.cells;this.$clearActiveIndentGuide();var t=this.$highlightIndentGuideMarker.indentLevel;if(0!==t)if(1===this.$highlightIndentGuideMarker.dir)for(var n=0;n<e.length;n++){var r=e[n];if(this.$highlightIndentGuideMarker.end&&r.row>=this.$highlightIndentGuideMarker.start+1){if(r.row>=this.$highlightIndentGuideMarker.end)break;this.$setIndentGuideActive(r,t)}}else for(n=e.length-1;n>=0;n--){r=e[n];if(this.$highlightIndentGuideMarker.end&&r.row<this.$highlightIndentGuideMarker.start){if(r.row<=this.$highlightIndentGuideMarker.end)break;this.$setIndentGuideActive(r,t)}}}},e.prototype.$createLineElement=function(e){var t=this.dom.createElement("div");return t.className="ace_line",t.style.height=this.config.lineHeight+"px",t},e.prototype.$renderWrappedLine=function(e,t,n){var r=0,i=0,s=n[0],a=0,l=this.$createLineElement();e.appendChild(l);for(var c=0;c<t.length;c++){var u=t[c],h=u.value;if(0==c&&this.displayIndentGuides){if(r=h.length,h=this.renderIndentGuide(l,h,s),!h)continue;r-=h.length}if(r+h.length<s)a=this.$renderToken(l,a,u,h),r+=h.length;else{while(r+h.length>=s)a=this.$renderToken(l,a,u,h.substring(0,s-r)),h=h.substring(s-r),r=s,l=this.$createLineElement(),e.appendChild(l),l.appendChild(this.dom.createTextNode(o.stringRepeat(" ",n.indent),this.element)),i++,a=0,s=n[i]||Number.MAX_VALUE;0!=h.length&&(r+=h.length,a=this.$renderToken(l,a,u,h))}}n[n.length-1]>this.MAX_LINE_LENGTH&&this.$renderOverflowMessage(l,a,null,"",!0)},e.prototype.$renderSimpleLine=function(e,t){for(var n=0,r=0;r<t.length;r++){var i=t[r],o=i.value;if(0!=r||!this.displayIndentGuides||(o=this.renderIndentGuide(e,o),o)){if(n+o.length>this.MAX_LINE_LENGTH)return this.$renderOverflowMessage(e,n,i,o);n=this.$renderToken(e,n,i,o)}}},e.prototype.$renderOverflowMessage=function(e,t,n,r,i){n&&this.$renderToken(e,t,n,r.slice(0,this.MAX_LINE_LENGTH-t));var o=this.dom.createElement("span");o.className="ace_inline_button ace_keyword ace_toggle_wrap",o.textContent=i?"<hide>":"<click to see more...>",e.appendChild(o)},e.prototype.$renderLine=function(e,t,n){if(n||0==n||(n=this.session.getFoldLine(t)),n)var r=this.$getFoldLineTokens(t,n);else r=this.session.getTokens(t);var i=e;if(r.length){var o=this.session.getRowSplitData(t);if(o&&o.length){this.$renderWrappedLine(e,r,o);i=e.lastChild}else{i=e;this.$useLineGroups()&&(i=this.$createLineElement(),e.appendChild(i)),this.$renderSimpleLine(i,r)}}else this.$useLineGroups()&&(i=this.$createLineElement(),e.appendChild(i));if(this.showEOL&&i){n&&(t=n.end.row);var s=this.dom.createElement("span");s.className="ace_invisible ace_invisible_eol",s.textContent=t==this.session.getLength()-1?this.EOF_CHAR:this.EOL_CHAR,i.appendChild(s)}},e.prototype.$getFoldLineTokens=function(e,t){var n=this.session,r=[];function i(e,t,n){var i=0,o=0;while(o+e[i].value.length<t)if(o+=e[i].value.length,i++,i==e.length)return;if(o!=t){var s=e[i].value.substring(t-o);s.length>n-t&&(s=s.substring(0,n-t)),r.push({type:e[i].type,value:s}),o=t+s.length,i+=1}while(o<n&&i<e.length){s=e[i].value;s.length+o>n?r.push({type:e[i].type,value:s.substring(0,n-o)}):r.push(e[i]),o+=s.length,i+=1}}var o=n.getTokens(e);return t.walk((function(e,t,s,a,l){null!=e?r.push({type:"fold",value:e}):(l&&(o=n.getTokens(t)),o.length&&i(o,a,s))}),t.end.row,this.session.getLine(t.end.row).length),r},e.prototype.$useLineGroups=function(){return this.session.getUseWrapMode()},e}();l.prototype.$textToken={text:!0,rparen:!0,lparen:!0},l.prototype.EOF_CHAR="¶",l.prototype.EOL_CHAR_LF="¬",l.prototype.EOL_CHAR_CRLF="¤",l.prototype.EOL_CHAR=l.prototype.EOL_CHAR_LF,l.prototype.TAB_CHAR="—",l.prototype.SPACE_CHAR="·",l.prototype.$padding=0,l.prototype.MAX_LINE_LENGTH=1e4,l.prototype.showInvisibles=!1,l.prototype.showSpaces=!1,l.prototype.showTabs=!1,l.prototype.showEOL=!1,l.prototype.displayIndentGuides=!0,l.prototype.$highlightIndentGuides=!0,l.prototype.$tabStrings=[],l.prototype.destroy={},l.prototype.onChangeTabSize=l.prototype.$computeTabString,r.implement(l.prototype,a),t.Text=l})),ace.define("ace/layer/cursor",["require","exports","module","ace/lib/dom"],(function(e,t,n){"use strict";var r=e("../lib/dom"),i=function(){function e(e){this.element=r.createElement("div"),this.element.className="ace_layer ace_cursor-layer",e.appendChild(this.element),this.isVisible=!1,this.isBlinking=!0,this.blinkInterval=1e3,this.smoothBlinking=!1,this.cursors=[],this.cursor=this.addCursor(),r.addCssClass(this.element,"ace_hidden-cursors"),this.$updateCursors=this.$updateOpacity.bind(this)}return e.prototype.$updateOpacity=function(e){for(var t=this.cursors,n=t.length;n--;)r.setStyle(t[n].style,"opacity",e?"":"0")},e.prototype.$startCssAnimation=function(){for(var e=this.cursors,t=e.length;t--;)e[t].style.animationDuration=this.blinkInterval+"ms";this.$isAnimating=!0,setTimeout(function(){this.$isAnimating&&r.addCssClass(this.element,"ace_animate-blinking")}.bind(this))},e.prototype.$stopCssAnimation=function(){this.$isAnimating=!1,r.removeCssClass(this.element,"ace_animate-blinking")},e.prototype.setPadding=function(e){this.$padding=e},e.prototype.setSession=function(e){this.session=e},e.prototype.setBlinking=function(e){e!=this.isBlinking&&(this.isBlinking=e,this.restartTimer())},e.prototype.setBlinkInterval=function(e){e!=this.blinkInterval&&(this.blinkInterval=e,this.restartTimer())},e.prototype.setSmoothBlinking=function(e){e!=this.smoothBlinking&&(this.smoothBlinking=e,r.setCssClass(this.element,"ace_smooth-blinking",e),this.$updateCursors(!0),this.restartTimer())},e.prototype.addCursor=function(){var e=r.createElement("div");return e.className="ace_cursor",this.element.appendChild(e),this.cursors.push(e),e},e.prototype.removeCursor=function(){if(this.cursors.length>1){var e=this.cursors.pop();return e.parentNode.removeChild(e),e}},e.prototype.hideCursor=function(){this.isVisible=!1,r.addCssClass(this.element,"ace_hidden-cursors"),this.restartTimer()},e.prototype.showCursor=function(){this.isVisible=!0,r.removeCssClass(this.element,"ace_hidden-cursors"),this.restartTimer()},e.prototype.restartTimer=function(){var e=this.$updateCursors;if(clearInterval(this.intervalId),clearTimeout(this.timeoutId),this.$stopCssAnimation(),this.smoothBlinking&&(this.$isSmoothBlinking=!1,r.removeCssClass(this.element,"ace_smooth-blinking")),e(!0),this.isBlinking&&this.blinkInterval&&this.isVisible)if(this.smoothBlinking&&(this.$isSmoothBlinking=!0,setTimeout(function(){this.$isSmoothBlinking&&r.addCssClass(this.element,"ace_smooth-blinking")}.bind(this))),r.HAS_CSS_ANIMATION)this.$startCssAnimation();else{var t=function(){this.timeoutId=setTimeout((function(){e(!1)}),.6*this.blinkInterval)}.bind(this);this.intervalId=setInterval((function(){e(!0),t()}),this.blinkInterval),t()}else this.$stopCssAnimation()},e.prototype.getPixelPosition=function(e,t){if(!this.config||!this.session)return{left:0,top:0};e||(e=this.session.selection.getCursor());var n=this.session.documentToScreenPosition(e),r=this.$padding+(this.session.$bidiHandler.isBidiRow(n.row,e.row)?this.session.$bidiHandler.getPosLeft(n.column):n.column*this.config.characterWidth),i=(n.row-(t?this.config.firstRowScreen:0))*this.config.lineHeight;return{left:r,top:i}},e.prototype.isCursorInView=function(e,t){return e.top>=0&&e.top<t.maxHeight},e.prototype.update=function(e){this.config=e;var t=this.session.$selectionMarkers,n=0,i=0;void 0!==t&&0!==t.length||(t=[{cursor:null}]);n=0;for(var o=t.length;n<o;n++){var s=this.getPixelPosition(t[n].cursor,!0);if(!((s.top>e.height+e.offset||s.top<0)&&n>1)){var a=this.cursors[i++]||this.addCursor(),l=a.style;this.drawCursor?this.drawCursor(a,s,e,t[n],this.session):this.isCursorInView(s,e)?(r.setStyle(l,"display","block"),r.translate(a,s.left,s.top),r.setStyle(l,"width",Math.round(e.characterWidth)+"px"),r.setStyle(l,"height",e.lineHeight+"px")):r.setStyle(l,"display","none")}}while(this.cursors.length>i)this.removeCursor();var c=this.session.getOverwrite();this.$setOverwrite(c),this.$pixelPos=s,this.restartTimer()},e.prototype.$setOverwrite=function(e){e!=this.overwrite&&(this.overwrite=e,e?r.addCssClass(this.element,"ace_overwrite-cursors"):r.removeCssClass(this.element,"ace_overwrite-cursors"))},e.prototype.destroy=function(){clearInterval(this.intervalId),clearTimeout(this.timeoutId)},e}();i.prototype.$padding=0,i.prototype.drawCursor=null,t.Cursor=i})),ace.define("ace/scrollbar",["require","exports","module","ace/lib/oop","ace/lib/dom","ace/lib/event","ace/lib/event_emitter"],(function(e,t,n){"use strict";var r=this&&this.__extends||function(){var e=function(t,n){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])},e(t,n)};return function(t,n){if("function"!==typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function r(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),i=e("./lib/oop"),o=e("./lib/dom"),s=e("./lib/event"),a=e("./lib/event_emitter").EventEmitter,l=32768,c=function(){function e(e,t){this.element=o.createElement("div"),this.element.className="ace_scrollbar ace_scrollbar"+t,this.inner=o.createElement("div"),this.inner.className="ace_scrollbar-inner",this.inner.textContent=" ",this.element.appendChild(this.inner),e.appendChild(this.element),this.setVisible(!1),this.skipEvent=!1,s.addListener(this.element,"scroll",this.onScroll.bind(this)),s.addListener(this.element,"mousedown",s.preventDefault)}return e.prototype.setVisible=function(e){this.element.style.display=e?"":"none",this.isVisible=e,this.coeff=1},e}();i.implement(c.prototype,a);var u=function(e){function t(t,n){var r=e.call(this,t,"-v")||this;return r.scrollTop=0,r.scrollHeight=0,n.$scrollbarWidth=r.width=o.scrollbarWidth(t.ownerDocument),r.inner.style.width=r.element.style.width=(r.width||15)+5+"px",r.$minWidth=0,r}return r(t,e),t.prototype.onScroll=function(){if(!this.skipEvent){if(this.scrollTop=this.element.scrollTop,1!=this.coeff){var e=this.element.clientHeight/this.scrollHeight;this.scrollTop=this.scrollTop*(1-e)/(this.coeff-e)}this._emit("scroll",{data:this.scrollTop})}this.skipEvent=!1},t.prototype.getWidth=function(){return Math.max(this.isVisible?this.width:0,this.$minWidth||0)},t.prototype.setHeight=function(e){this.element.style.height=e+"px"},t.prototype.setScrollHeight=function(e){this.scrollHeight=e,e>l?(this.coeff=l/e,e=l):1!=this.coeff&&(this.coeff=1),this.inner.style.height=e+"px"},t.prototype.setScrollTop=function(e){this.scrollTop!=e&&(this.skipEvent=!0,this.scrollTop=e,this.element.scrollTop=e*this.coeff)},t}(c);u.prototype.setInnerHeight=u.prototype.setScrollHeight;var h=function(e){function t(t,n){var r=e.call(this,t,"-h")||this;return r.scrollLeft=0,r.height=n.$scrollbarWidth,r.inner.style.height=r.element.style.height=(r.height||15)+5+"px",r}return r(t,e),t.prototype.onScroll=function(){this.skipEvent||(this.scrollLeft=this.element.scrollLeft,this._emit("scroll",{data:this.scrollLeft})),this.skipEvent=!1},t.prototype.getHeight=function(){return this.isVisible?this.height:0},t.prototype.setWidth=function(e){this.element.style.width=e+"px"},t.prototype.setInnerWidth=function(e){this.inner.style.width=e+"px"},t.prototype.setScrollWidth=function(e){this.inner.style.width=e+"px"},t.prototype.setScrollLeft=function(e){this.scrollLeft!=e&&(this.skipEvent=!0,this.scrollLeft=this.element.scrollLeft=e)},t}(c);t.ScrollBar=u,t.ScrollBarV=u,t.ScrollBarH=h,t.VScrollBar=u,t.HScrollBar=h})),ace.define("ace/scrollbar_custom",["require","exports","module","ace/lib/oop","ace/lib/dom","ace/lib/event","ace/lib/event_emitter"],(function(e,t,n){"use strict";var r=this&&this.__extends||function(){var e=function(t,n){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])},e(t,n)};return function(t,n){if("function"!==typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function r(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),i=e("./lib/oop"),o=e("./lib/dom"),s=e("./lib/event"),a=e("./lib/event_emitter").EventEmitter;o.importCssString(".ace_editor>.ace_sb-v div, .ace_editor>.ace_sb-h div{\n position: absolute;\n background: rgba(128, 128, 128, 0.6);\n -moz-box-sizing: border-box;\n box-sizing: border-box;\n border: 1px solid #bbb;\n border-radius: 2px;\n z-index: 8;\n}\n.ace_editor>.ace_sb-v, .ace_editor>.ace_sb-h {\n position: absolute;\n z-index: 6;\n background: none;\n overflow: hidden!important;\n}\n.ace_editor>.ace_sb-v {\n z-index: 6;\n right: 0;\n top: 0;\n width: 12px;\n}\n.ace_editor>.ace_sb-v div {\n z-index: 8;\n right: 0;\n width: 100%;\n}\n.ace_editor>.ace_sb-h {\n bottom: 0;\n left: 0;\n height: 12px;\n}\n.ace_editor>.ace_sb-h div {\n bottom: 0;\n height: 100%;\n}\n.ace_editor>.ace_sb_grabbed {\n z-index: 8;\n background: #000;\n}","ace_scrollbar.css",!1);var l=function(){function e(e,t){this.element=o.createElement("div"),this.element.className="ace_sb"+t,this.inner=o.createElement("div"),this.inner.className="",this.element.appendChild(this.inner),this.VScrollWidth=12,this.HScrollHeight=12,e.appendChild(this.element),this.setVisible(!1),this.skipEvent=!1,s.addMultiMouseDownListener(this.element,[500,300,300],this,"onMouseDown")}return e.prototype.setVisible=function(e){this.element.style.display=e?"":"none",this.isVisible=e,this.coeff=1},e}();i.implement(l.prototype,a);var c=function(e){function t(t,n){var r=e.call(this,t,"-v")||this;return r.scrollTop=0,r.scrollHeight=0,r.parent=t,r.width=r.VScrollWidth,r.renderer=n,r.inner.style.width=r.element.style.width=(r.width||15)+"px",r.$minWidth=0,r}return r(t,e),t.prototype.onMouseDown=function(e,t){if("mousedown"===e&&0===s.getButton(t)&&2!==t.detail){if(t.target===this.inner){var n=this,r=t.clientY,i=function(e){r=e.clientY},o=function(){clearInterval(u)},a=t.clientY,l=this.thumbTop,c=function(){if(void 0!==r){var e=n.scrollTopFromThumbTop(l+r-a);e!==n.scrollTop&&n._emit("scroll",{data:e})}};s.capture(this.inner,i,o);var u=setInterval(c,20);return s.preventDefault(t)}var h=t.clientY-this.element.getBoundingClientRect().top-this.thumbHeight/2;return this._emit("scroll",{data:this.scrollTopFromThumbTop(h)}),s.preventDefault(t)}},t.prototype.getHeight=function(){return this.height},t.prototype.scrollTopFromThumbTop=function(e){var t=e*(this.pageHeight-this.viewHeight)/(this.slideHeight-this.thumbHeight);return t>>=0,t<0?t=0:t>this.pageHeight-this.viewHeight&&(t=this.pageHeight-this.viewHeight),t},t.prototype.getWidth=function(){return Math.max(this.isVisible?this.width:0,this.$minWidth||0)},t.prototype.setHeight=function(e){this.height=Math.max(0,e),this.slideHeight=this.height,this.viewHeight=this.height,this.setScrollHeight(this.pageHeight,!0)},t.prototype.setScrollHeight=function(e,t){(this.pageHeight!==e||t)&&(this.pageHeight=e,this.thumbHeight=this.slideHeight*this.viewHeight/this.pageHeight,this.thumbHeight>this.slideHeight&&(this.thumbHeight=this.slideHeight),this.thumbHeight<15&&(this.thumbHeight=15),this.inner.style.height=this.thumbHeight+"px",this.scrollTop>this.pageHeight-this.viewHeight&&(this.scrollTop=this.pageHeight-this.viewHeight,this.scrollTop<0&&(this.scrollTop=0),this._emit("scroll",{data:this.scrollTop})))},t.prototype.setScrollTop=function(e){this.scrollTop=e,e<0&&(e=0),this.thumbTop=e*(this.slideHeight-this.thumbHeight)/(this.pageHeight-this.viewHeight),this.inner.style.top=this.thumbTop+"px"},t}(l);c.prototype.setInnerHeight=c.prototype.setScrollHeight;var u=function(e){function t(t,n){var r=e.call(this,t,"-h")||this;return r.scrollLeft=0,r.scrollWidth=0,r.height=r.HScrollHeight,r.inner.style.height=r.element.style.height=(r.height||12)+"px",r.renderer=n,r}return r(t,e),t.prototype.onMouseDown=function(e,t){if("mousedown"===e&&0===s.getButton(t)&&2!==t.detail){if(t.target===this.inner){var n=this,r=t.clientX,i=function(e){r=e.clientX},o=function(){clearInterval(u)},a=t.clientX,l=this.thumbLeft,c=function(){if(void 0!==r){var e=n.scrollLeftFromThumbLeft(l+r-a);e!==n.scrollLeft&&n._emit("scroll",{data:e})}};s.capture(this.inner,i,o);var u=setInterval(c,20);return s.preventDefault(t)}var h=t.clientX-this.element.getBoundingClientRect().left-this.thumbWidth/2;return this._emit("scroll",{data:this.scrollLeftFromThumbLeft(h)}),s.preventDefault(t)}},t.prototype.getHeight=function(){return this.isVisible?this.height:0},t.prototype.scrollLeftFromThumbLeft=function(e){var t=e*(this.pageWidth-this.viewWidth)/(this.slideWidth-this.thumbWidth);return t>>=0,t<0?t=0:t>this.pageWidth-this.viewWidth&&(t=this.pageWidth-this.viewWidth),t},t.prototype.setWidth=function(e){this.width=Math.max(0,e),this.element.style.width=this.width+"px",this.slideWidth=this.width,this.viewWidth=this.width,this.setScrollWidth(this.pageWidth,!0)},t.prototype.setScrollWidth=function(e,t){(this.pageWidth!==e||t)&&(this.pageWidth=e,this.thumbWidth=this.slideWidth*this.viewWidth/this.pageWidth,this.thumbWidth>this.slideWidth&&(this.thumbWidth=this.slideWidth),this.thumbWidth<15&&(this.thumbWidth=15),this.inner.style.width=this.thumbWidth+"px",this.scrollLeft>this.pageWidth-this.viewWidth&&(this.scrollLeft=this.pageWidth-this.viewWidth,this.scrollLeft<0&&(this.scrollLeft=0),this._emit("scroll",{data:this.scrollLeft})))},t.prototype.setScrollLeft=function(e){this.scrollLeft=e,e<0&&(e=0),this.thumbLeft=e*(this.slideWidth-this.thumbWidth)/(this.pageWidth-this.viewWidth),this.inner.style.left=this.thumbLeft+"px"},t}(l);u.prototype.setInnerWidth=u.prototype.setScrollWidth,t.ScrollBar=c,t.ScrollBarV=c,t.ScrollBarH=u,t.VScrollBar=c,t.HScrollBar=u})),ace.define("ace/renderloop",["require","exports","module","ace/lib/event"],(function(e,t,n){"use strict";var r=e("./lib/event"),i=function(){function e(e,t){this.onRender=e,this.pending=!1,this.changes=0,this.$recursionLimit=2,this.window=t||window;var n=this;this._flush=function(e){n.pending=!1;var t=n.changes;if(t&&(r.blockIdle(100),n.changes=0,n.onRender(t)),n.changes){if(n.$recursionLimit--<0)return;n.schedule()}else n.$recursionLimit=2}}return e.prototype.schedule=function(e){this.changes=this.changes|e,this.changes&&!this.pending&&(r.nextFrame(this._flush),this.pending=!0)},e.prototype.clear=function(e){var t=this.changes;return this.changes=0,t},e}();t.RenderLoop=i})),ace.define("ace/layer/font_metrics",["require","exports","module","ace/lib/oop","ace/lib/dom","ace/lib/lang","ace/lib/event","ace/lib/useragent","ace/lib/event_emitter"],(function(e,t,n){var r=e("../lib/oop"),i=e("../lib/dom"),o=e("../lib/lang"),s=e("../lib/event"),a=e("../lib/useragent"),l=e("../lib/event_emitter").EventEmitter,c=512,u="function"==typeof ResizeObserver,h=200,f=function(){function e(e){this.el=i.createElement("div"),this.$setMeasureNodeStyles(this.el.style,!0),this.$main=i.createElement("div"),this.$setMeasureNodeStyles(this.$main.style),this.$measureNode=i.createElement("div"),this.$setMeasureNodeStyles(this.$measureNode.style),this.el.appendChild(this.$main),this.el.appendChild(this.$measureNode),e.appendChild(this.el),this.$measureNode.textContent=o.stringRepeat("X",c),this.$characterSize={width:0,height:0},u?this.$addObserver():this.checkForSizeChanges()}return e.prototype.$setMeasureNodeStyles=function(e,t){e.width=e.height="auto",e.left=e.top="0px",e.visibility="hidden",e.position="absolute",e.whiteSpace="pre",a.isIE<8?e["font-family"]="inherit":e.font="inherit",e.overflow=t?"hidden":"visible"},e.prototype.checkForSizeChanges=function(e){if(void 0===e&&(e=this.$measureSizes()),e&&(this.$characterSize.width!==e.width||this.$characterSize.height!==e.height)){this.$measureNode.style.fontWeight="bold";var t=this.$measureSizes();this.$measureNode.style.fontWeight="",this.$characterSize=e,this.charSizes=Object.create(null),this.allowBoldFonts=t&&t.width===e.width&&t.height===e.height,this._emit("changeCharacterSize",{data:e})}},e.prototype.$addObserver=function(){var e=this;this.$observer=new window.ResizeObserver((function(t){e.checkForSizeChanges()})),this.$observer.observe(this.$measureNode)},e.prototype.$pollSizeChanges=function(){if(this.$pollSizeChangesTimer||this.$observer)return this.$pollSizeChangesTimer;var e=this;return this.$pollSizeChangesTimer=s.onIdle((function t(){e.checkForSizeChanges(),s.onIdle(t,500)}),500)},e.prototype.setPolling=function(e){e?this.$pollSizeChanges():this.$pollSizeChangesTimer&&(clearInterval(this.$pollSizeChangesTimer),this.$pollSizeChangesTimer=0)},e.prototype.$measureSizes=function(e){var t={height:(e||this.$measureNode).clientHeight,width:(e||this.$measureNode).clientWidth/c};return 0===t.width||0===t.height?null:t},e.prototype.$measureCharWidth=function(e){this.$main.textContent=o.stringRepeat(e,c);var t=this.$main.getBoundingClientRect();return t.width/c},e.prototype.getCharacterWidth=function(e){var t=this.charSizes[e];return void 0===t&&(t=this.charSizes[e]=this.$measureCharWidth(e)/this.$characterSize.width),t},e.prototype.destroy=function(){clearInterval(this.$pollSizeChangesTimer),this.$observer&&this.$observer.disconnect(),this.el&&this.el.parentNode&&this.el.parentNode.removeChild(this.el)},e.prototype.$getZoom=function(e){return e&&e.parentElement?(window.getComputedStyle(e).zoom||1)*this.$getZoom(e.parentElement):1},e.prototype.$initTransformMeasureNodes=function(){var e=function(e,t){return["div",{style:"position: absolute;top:"+e+"px;left:"+t+"px;"}]};this.els=i.buildDom([e(0,0),e(h,0),e(0,h),e(h,h)],this.el)},e.prototype.transformCoordinates=function(e,t){if(e){var n=this.$getZoom(this.el);e=s(1/n,e)}function r(e,t,n){var r=e[1]*t[0]-e[0]*t[1];return[(-t[1]*n[0]+t[0]*n[1])/r,(+e[1]*n[0]-e[0]*n[1])/r]}function i(e,t){return[e[0]-t[0],e[1]-t[1]]}function o(e,t){return[e[0]+t[0],e[1]+t[1]]}function s(e,t){return[e*t[0],e*t[1]]}function a(e){var t=e.getBoundingClientRect();return[t.left,t.top]}this.els||this.$initTransformMeasureNodes();var l=a(this.els[0]),c=a(this.els[1]),u=a(this.els[2]),f=a(this.els[3]),d=r(i(f,c),i(f,u),i(o(c,u),o(f,l))),p=s(1+d[0],i(c,l)),g=s(1+d[1],i(u,l));if(t){var m=t,v=d[0]*m[0]/h+d[1]*m[1]/h+1,y=o(s(m[0],p),s(m[1],g));return o(s(1/v/h,y),l)}var w=i(e,l),b=r(i(p,s(d[0],w)),i(g,s(d[1],w)),w);return s(h,b)},e}();f.prototype.$characterSize={width:0,height:0},r.implement(f.prototype,l),t.FontMetrics=f})),ace.define("ace/css/editor.css",["require","exports","module"],(function(e,t,n){n.exports='\n.ace_br1 {border-top-left-radius : 3px;}\n.ace_br2 {border-top-right-radius : 3px;}\n.ace_br3 {border-top-left-radius : 3px; border-top-right-radius: 3px;}\n.ace_br4 {border-bottom-right-radius: 3px;}\n.ace_br5 {border-top-left-radius : 3px; border-bottom-right-radius: 3px;}\n.ace_br6 {border-top-right-radius : 3px; border-bottom-right-radius: 3px;}\n.ace_br7 {border-top-left-radius : 3px; border-top-right-radius: 3px; border-bottom-right-radius: 3px;}\n.ace_br8 {border-bottom-left-radius : 3px;}\n.ace_br9 {border-top-left-radius : 3px; border-bottom-left-radius: 3px;}\n.ace_br10{border-top-right-radius : 3px; border-bottom-left-radius: 3px;}\n.ace_br11{border-top-left-radius : 3px; border-top-right-radius: 3px; border-bottom-left-radius: 3px;}\n.ace_br12{border-bottom-right-radius: 3px; border-bottom-left-radius: 3px;}\n.ace_br13{border-top-left-radius : 3px; border-bottom-right-radius: 3px; border-bottom-left-radius: 3px;}\n.ace_br14{border-top-right-radius : 3px; border-bottom-right-radius: 3px; border-bottom-left-radius: 3px;}\n.ace_br15{border-top-left-radius : 3px; border-top-right-radius: 3px; border-bottom-right-radius: 3px; border-bottom-left-radius: 3px;}\n\n\n.ace_editor {\n position: relative;\n overflow: hidden;\n padding: 0;\n font: 12px/normal \'Monaco\', \'Menlo\', \'Ubuntu Mono\', \'Consolas\', \'Source Code Pro\', \'source-code-pro\', monospace;\n direction: ltr;\n text-align: left;\n -webkit-tap-highlight-color: rgba(0, 0, 0, 0);\n}\n\n.ace_scroller {\n position: absolute;\n overflow: hidden;\n top: 0;\n bottom: 0;\n background-color: inherit;\n -ms-user-select: none;\n -moz-user-select: none;\n -webkit-user-select: none;\n user-select: none;\n cursor: text;\n}\n\n.ace_content {\n position: absolute;\n box-sizing: border-box;\n min-width: 100%;\n contain: style size layout;\n font-variant-ligatures: no-common-ligatures;\n}\n\n.ace_keyboard-focus:focus {\n box-shadow: inset 0 0 0 2px #5E9ED6;\n outline: none;\n}\n\n.ace_dragging .ace_scroller:before{\n position: absolute;\n top: 0;\n left: 0;\n right: 0;\n bottom: 0;\n content: \'\';\n background: rgba(250, 250, 250, 0.01);\n z-index: 1000;\n}\n.ace_dragging.ace_dark .ace_scroller:before{\n background: rgba(0, 0, 0, 0.01);\n}\n\n.ace_gutter {\n position: absolute;\n overflow : hidden;\n width: auto;\n top: 0;\n bottom: 0;\n left: 0;\n cursor: default;\n z-index: 4;\n -ms-user-select: none;\n -moz-user-select: none;\n -webkit-user-select: none;\n user-select: none;\n contain: style size layout;\n}\n\n.ace_gutter-active-line {\n position: absolute;\n left: 0;\n right: 0;\n}\n\n.ace_scroller.ace_scroll-left:after {\n content: "";\n position: absolute;\n top: 0;\n right: 0;\n bottom: 0;\n left: 0;\n box-shadow: 17px 0 16px -16px rgba(0, 0, 0, 0.4) inset;\n pointer-events: none;\n}\n\n.ace_gutter-cell, .ace_gutter-cell_svg-icons {\n position: absolute;\n top: 0;\n left: 0;\n right: 0;\n padding-left: 19px;\n padding-right: 6px;\n background-repeat: no-repeat;\n}\n\n.ace_gutter-cell_svg-icons .ace_icon_svg{\n margin-left: -14px;\n float: left;\n}\n\n.ace_gutter-cell.ace_error, .ace_icon.ace_error {\n background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAMAAAAoLQ9TAAABOFBMVEX/////////QRswFAb/Ui4wFAYwFAYwFAaWGAfDRymzOSH/PxswFAb/SiUwFAYwFAbUPRvjQiDllog5HhHdRybsTi3/Tyv9Tir+Syj/UC3////XurebMBIwFAb/RSHbPx/gUzfdwL3kzMivKBAwFAbbvbnhPx66NhowFAYwFAaZJg8wFAaxKBDZurf/RB6mMxb/SCMwFAYwFAbxQB3+RB4wFAb/Qhy4Oh+4QifbNRcwFAYwFAYwFAb/QRzdNhgwFAYwFAbav7v/Uy7oaE68MBK5LxLewr/r2NXewLswFAaxJw4wFAbkPRy2PyYwFAaxKhLm1tMwFAazPiQwFAaUGAb/QBrfOx3bvrv/VC/maE4wFAbRPBq6MRO8Qynew8Dp2tjfwb0wFAbx6eju5+by6uns4uH9/f36+vr/GkHjAAAAYnRSTlMAGt+64rnWu/bo8eAA4InH3+DwoN7j4eLi4xP99Nfg4+b+/u9B/eDs1MD1mO7+4PHg2MXa347g7vDizMLN4eG+Pv7i5evs/v79yu7S3/DV7/498Yv24eH+4ufQ3Ozu/v7+y13sRqwAAADLSURBVHjaZc/XDsFgGIBhtDrshlitmk2IrbHFqL2pvXf/+78DPokj7+Fz9qpU/9UXJIlhmPaTaQ6QPaz0mm+5gwkgovcV6GZzd5JtCQwgsxoHOvJO15kleRLAnMgHFIESUEPmawB9ngmelTtipwwfASilxOLyiV5UVUyVAfbG0cCPHig+GBkzAENHS0AstVF6bacZIOzgLmxsHbt2OecNgJC83JERmePUYq8ARGkJx6XtFsdddBQgZE2nPR6CICZhawjA4Fb/chv+399kfR+MMMDGOQAAAABJRU5ErkJggg==");\n background-repeat: no-repeat;\n background-position: 2px center;\n}\n\n.ace_gutter-cell.ace_warning, .ace_icon.ace_warning {\n background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAMAAAAoLQ9TAAAAmVBMVEX///8AAAD///8AAAAAAABPSzb/5sAAAAB/blH/73z/ulkAAAAAAAD85pkAAAAAAAACAgP/vGz/rkDerGbGrV7/pkQICAf////e0IsAAAD/oED/qTvhrnUAAAD/yHD/njcAAADuv2r/nz//oTj/p064oGf/zHAAAAA9Nir/tFIAAAD/tlTiuWf/tkIAAACynXEAAAAAAAAtIRW7zBpBAAAAM3RSTlMAABR1m7RXO8Ln31Z36zT+neXe5OzooRDfn+TZ4p3h2hTf4t3k3ucyrN1K5+Xaks52Sfs9CXgrAAAAjklEQVR42o3PbQ+CIBQFYEwboPhSYgoYunIqqLn6/z8uYdH8Vmdnu9vz4WwXgN/xTPRD2+sgOcZjsge/whXZgUaYYvT8QnuJaUrjrHUQreGczuEafQCO/SJTufTbroWsPgsllVhq3wJEk2jUSzX3CUEDJC84707djRc5MTAQxoLgupWRwW6UB5fS++NV8AbOZgnsC7BpEAAAAABJRU5ErkJggg==");\n background-repeat: no-repeat;\n background-position: 2px center;\n}\n\n.ace_gutter-cell.ace_info, .ace_icon.ace_info {\n background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAAAAAA6mKC9AAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAAJ0Uk5TAAB2k804AAAAPklEQVQY02NgIB68QuO3tiLznjAwpKTgNyDbMegwisCHZUETUZV0ZqOquBpXj2rtnpSJT1AEnnRmL2OgGgAAIKkRQap2htgAAAAASUVORK5CYII=");\n background-repeat: no-repeat;\n background-position: 2px center;\n}\n.ace_dark .ace_gutter-cell.ace_info, .ace_dark .ace_icon.ace_info {\n background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQBAMAAADt3eJSAAAAJFBMVEUAAAChoaGAgIAqKiq+vr6tra1ZWVmUlJSbm5s8PDxubm56enrdgzg3AAAAAXRSTlMAQObYZgAAAClJREFUeNpjYMAPdsMYHegyJZFQBlsUlMFVCWUYKkAZMxZAGdxlDMQBAG+TBP4B6RyJAAAAAElFTkSuQmCC");\n}\n\n.ace_icon_svg.ace_error {\n -webkit-mask-image: url("data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAxNiAxNiI+CjxnIHN0cm9rZS13aWR0aD0iMiIgc3Ryb2tlPSJyZWQiIHNoYXBlLXJlbmRlcmluZz0iZ2VvbWV0cmljUHJlY2lzaW9uIj4KPGNpcmNsZSBmaWxsPSJub25lIiBjeD0iOCIgY3k9IjgiIHI9IjciIHN0cm9rZS1saW5lam9pbj0icm91bmQiLz4KPGxpbmUgeDE9IjExIiB5MT0iNSIgeDI9IjUiIHkyPSIxMSIvPgo8bGluZSB4MT0iMTEiIHkxPSIxMSIgeDI9IjUiIHkyPSI1Ii8+CjwvZz4KPC9zdmc+");\n background-color: crimson;\n}\n.ace_icon_svg.ace_warning {\n -webkit-mask-image: url("data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAxNiAxNiI+CjxnIHN0cm9rZS13aWR0aD0iMiIgc3Ryb2tlPSJkYXJrb3JhbmdlIiBzaGFwZS1yZW5kZXJpbmc9Imdlb21ldHJpY1ByZWNpc2lvbiI+Cjxwb2x5Z29uIHN0cm9rZS1saW5lam9pbj0icm91bmQiIGZpbGw9Im5vbmUiIHBvaW50cz0iOCAxIDE1IDE1IDEgMTUgOCAxIi8+CjxyZWN0IHg9IjgiIHk9IjEyIiB3aWR0aD0iMC4wMSIgaGVpZ2h0PSIwLjAxIi8+CjxsaW5lIHgxPSI4IiB5MT0iNiIgeDI9IjgiIHkyPSIxMCIvPgo8L2c+Cjwvc3ZnPg==");\n background-color: darkorange;\n}\n.ace_icon_svg.ace_info {\n -webkit-mask-image: url("data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAxNiAxNiI+CjxnIHN0cm9rZS13aWR0aD0iMiIgc3Ryb2tlPSJibHVlIiBzaGFwZS1yZW5kZXJpbmc9Imdlb21ldHJpY1ByZWNpc2lvbiI+CjxjaXJjbGUgZmlsbD0ibm9uZSIgY3g9IjgiIGN5PSI4IiByPSI3IiBzdHJva2UtbGluZWpvaW49InJvdW5kIi8+Cjxwb2x5bGluZSBwb2ludHM9IjggMTEgOCA4Ii8+Cjxwb2x5bGluZSBwb2ludHM9IjkgOCA2IDgiLz4KPGxpbmUgeDE9IjEwIiB5MT0iMTEiIHgyPSI2IiB5Mj0iMTEiLz4KPHJlY3QgeD0iOCIgeT0iNSIgd2lkdGg9IjAuMDEiIGhlaWdodD0iMC4wMSIvPgo8L2c+Cjwvc3ZnPg==");\n background-color: royalblue;\n}\n\n.ace_scrollbar {\n contain: strict;\n position: absolute;\n right: 0;\n bottom: 0;\n z-index: 6;\n}\n\n.ace_scrollbar-inner {\n position: absolute;\n cursor: text;\n left: 0;\n top: 0;\n}\n\n.ace_scrollbar-v{\n overflow-x: hidden;\n overflow-y: scroll;\n top: 0;\n}\n\n.ace_scrollbar-h {\n overflow-x: scroll;\n overflow-y: hidden;\n left: 0;\n}\n\n.ace_print-margin {\n position: absolute;\n height: 100%;\n}\n\n.ace_text-input {\n position: absolute;\n z-index: 0;\n width: 0.5em;\n height: 1em;\n opacity: 0;\n background: transparent;\n -moz-appearance: none;\n appearance: none;\n border: none;\n resize: none;\n outline: none;\n overflow: hidden;\n font: inherit;\n padding: 0 1px;\n margin: 0 -1px;\n contain: strict;\n -ms-user-select: text;\n -moz-user-select: text;\n -webkit-user-select: text;\n user-select: text;\n /*with `pre-line` chrome inserts &nbsp; instead of space*/\n white-space: pre!important;\n}\n.ace_text-input.ace_composition {\n background: transparent;\n color: inherit;\n z-index: 1000;\n opacity: 1;\n}\n.ace_composition_placeholder { color: transparent }\n.ace_composition_marker { \n border-bottom: 1px solid;\n position: absolute;\n border-radius: 0;\n margin-top: 1px;\n}\n\n[ace_nocontext=true] {\n transform: none!important;\n filter: none!important;\n clip-path: none!important;\n mask : none!important;\n contain: none!important;\n perspective: none!important;\n mix-blend-mode: initial!important;\n z-index: auto;\n}\n\n.ace_layer {\n z-index: 1;\n position: absolute;\n overflow: hidden;\n /* workaround for chrome bug https://github.com/ajaxorg/ace/issues/2312*/\n word-wrap: normal;\n white-space: pre;\n height: 100%;\n width: 100%;\n box-sizing: border-box;\n /* setting pointer-events: auto; on node under the mouse, which changes\n during scroll, will break mouse wheel scrolling in Safari */\n pointer-events: none;\n}\n\n.ace_gutter-layer {\n position: relative;\n width: auto;\n text-align: right;\n pointer-events: auto;\n height: 1000000px;\n contain: style size layout;\n}\n\n.ace_text-layer {\n font: inherit !important;\n position: absolute;\n height: 1000000px;\n width: 1000000px;\n contain: style size layout;\n}\n\n.ace_text-layer > .ace_line, .ace_text-layer > .ace_line_group {\n contain: style size layout;\n position: absolute;\n top: 0;\n left: 0;\n right: 0;\n}\n\n.ace_hidpi .ace_text-layer,\n.ace_hidpi .ace_gutter-layer,\n.ace_hidpi .ace_content,\n.ace_hidpi .ace_gutter {\n contain: strict;\n}\n.ace_hidpi .ace_text-layer > .ace_line, \n.ace_hidpi .ace_text-layer > .ace_line_group {\n contain: strict;\n}\n\n.ace_cjk {\n display: inline-block;\n text-align: center;\n}\n\n.ace_cursor-layer {\n z-index: 4;\n}\n\n.ace_cursor {\n z-index: 4;\n position: absolute;\n box-sizing: border-box;\n border-left: 2px solid;\n /* workaround for smooth cursor repaintng whole screen in chrome */\n transform: translatez(0);\n}\n\n.ace_multiselect .ace_cursor {\n border-left-width: 1px;\n}\n\n.ace_slim-cursors .ace_cursor {\n border-left-width: 1px;\n}\n\n.ace_overwrite-cursors .ace_cursor {\n border-left-width: 0;\n border-bottom: 1px solid;\n}\n\n.ace_hidden-cursors .ace_cursor {\n opacity: 0.2;\n}\n\n.ace_hasPlaceholder .ace_hidden-cursors .ace_cursor {\n opacity: 0;\n}\n\n.ace_smooth-blinking .ace_cursor {\n transition: opacity 0.18s;\n}\n\n.ace_animate-blinking .ace_cursor {\n animation-duration: 1000ms;\n animation-timing-function: step-end;\n animation-name: blink-ace-animate;\n animation-iteration-count: infinite;\n}\n\n.ace_animate-blinking.ace_smooth-blinking .ace_cursor {\n animation-duration: 1000ms;\n animation-timing-function: ease-in-out;\n animation-name: blink-ace-animate-smooth;\n}\n \n@keyframes blink-ace-animate {\n from, to { opacity: 1; }\n 60% { opacity: 0; }\n}\n\n@keyframes blink-ace-animate-smooth {\n from, to { opacity: 1; }\n 45% { opacity: 1; }\n 60% { opacity: 0; }\n 85% { opacity: 0; }\n}\n\n.ace_marker-layer .ace_step, .ace_marker-layer .ace_stack {\n position: absolute;\n z-index: 3;\n}\n\n.ace_marker-layer .ace_selection {\n position: absolute;\n z-index: 5;\n}\n\n.ace_marker-layer .ace_bracket {\n position: absolute;\n z-index: 6;\n}\n\n.ace_marker-layer .ace_error_bracket {\n position: absolute;\n border-bottom: 1px solid #DE5555;\n border-radius: 0;\n}\n\n.ace_marker-layer .ace_active-line {\n position: absolute;\n z-index: 2;\n}\n\n.ace_marker-layer .ace_selected-word {\n position: absolute;\n z-index: 4;\n box-sizing: border-box;\n}\n\n.ace_line .ace_fold {\n box-sizing: border-box;\n\n display: inline-block;\n height: 11px;\n margin-top: -2px;\n vertical-align: middle;\n\n background-image:\n url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABEAAAAJCAYAAADU6McMAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAJpJREFUeNpi/P//PwOlgAXGYGRklAVSokD8GmjwY1wasKljQpYACtpCFeADcHVQfQyMQAwzwAZI3wJKvCLkfKBaMSClBlR7BOQikCFGQEErIH0VqkabiGCAqwUadAzZJRxQr/0gwiXIal8zQQPnNVTgJ1TdawL0T5gBIP1MUJNhBv2HKoQHHjqNrA4WO4zY0glyNKLT2KIfIMAAQsdgGiXvgnYAAAAASUVORK5CYII="),\n url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAA3CAYAAADNNiA5AAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAACJJREFUeNpi+P//fxgTAwPDBxDxD078RSX+YeEyDFMCIMAAI3INmXiwf2YAAAAASUVORK5CYII=");\n background-repeat: no-repeat, repeat-x;\n background-position: center center, top left;\n color: transparent;\n\n border: 1px solid black;\n border-radius: 2px;\n\n cursor: pointer;\n pointer-events: auto;\n}\n\n.ace_dark .ace_fold {\n}\n\n.ace_fold:hover{\n background-image:\n url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABEAAAAJCAYAAADU6McMAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAJpJREFUeNpi/P//PwOlgAXGYGRklAVSokD8GmjwY1wasKljQpYACtpCFeADcHVQfQyMQAwzwAZI3wJKvCLkfKBaMSClBlR7BOQikCFGQEErIH0VqkabiGCAqwUadAzZJRxQr/0gwiXIal8zQQPnNVTgJ1TdawL0T5gBIP1MUJNhBv2HKoQHHjqNrA4WO4zY0glyNKLT2KIfIMAAQsdgGiXvgnYAAAAASUVORK5CYII="),\n url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAA3CAYAAADNNiA5AAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAACBJREFUeNpi+P//fz4TAwPDZxDxD5X4i5fLMEwJgAADAEPVDbjNw87ZAAAAAElFTkSuQmCC");\n}\n\n.ace_tooltip {\n background-color: #f5f5f5;\n border: 1px solid gray;\n border-radius: 1px;\n box-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);\n color: black;\n max-width: 100%;\n padding: 3px 4px;\n position: fixed;\n z-index: 999999;\n box-sizing: border-box;\n cursor: default;\n white-space: pre;\n word-wrap: break-word;\n line-height: normal;\n font-style: normal;\n font-weight: normal;\n letter-spacing: normal;\n pointer-events: none;\n}\n\n.ace_tooltip:focus {\n outline: 1px solid black;\n}\n\n.ace_gutter-tooltip_header {\n font-weight: bold;\n}\n\n.ace_gutter-tooltip_body {\n padding-top: 5px;\n}\n\n.ace_gutter-tooltip .ace_icon {\n display: inline-block;\n width: 18px;\n}\n\n.ace_icon_svg {\n display: inline-block;\n width: 12px;\n vertical-align: top;\n -webkit-mask-repeat: no-repeat;\n -webkit-mask-size: 12px;\n -webkit-mask-position: center;\n}\n\n.ace_folding-enabled > .ace_gutter-cell, .ace_folding-enabled > .ace_gutter-cell_svg-icons {\n padding-right: 13px;\n}\n\n.ace_fold-widget {\n box-sizing: border-box;\n\n margin: 0 -12px 0 1px;\n display: none;\n width: 11px;\n vertical-align: top;\n\n background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAANElEQVR42mWKsQ0AMAzC8ixLlrzQjzmBiEjp0A6WwBCSPgKAXoLkqSot7nN3yMwR7pZ32NzpKkVoDBUxKAAAAABJRU5ErkJggg==");\n background-repeat: no-repeat;\n background-position: center;\n\n border-radius: 3px;\n \n border: 1px solid transparent;\n cursor: pointer;\n}\n\n.ace_folding-enabled .ace_fold-widget {\n display: inline-block; \n}\n\n.ace_fold-widget.ace_end {\n background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAANElEQVR42m3HwQkAMAhD0YzsRchFKI7sAikeWkrxwScEB0nh5e7KTPWimZki4tYfVbX+MNl4pyZXejUO1QAAAABJRU5ErkJggg==");\n}\n\n.ace_fold-widget.ace_closed {\n background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAMAAAAGCAYAAAAG5SQMAAAAOUlEQVR42jXKwQkAMAgDwKwqKD4EwQ26sSOkVWjgIIHAzPiCgaqiqnJHZnKICBERHN194O5b9vbLuAVRL+l0YWnZAAAAAElFTkSuQmCCXA==");\n}\n\n.ace_fold-widget:hover {\n border: 1px solid rgba(0, 0, 0, 0.3);\n background-color: rgba(255, 255, 255, 0.2);\n box-shadow: 0 1px 1px rgba(255, 255, 255, 0.7);\n}\n\n.ace_fold-widget:active {\n border: 1px solid rgba(0, 0, 0, 0.4);\n background-color: rgba(0, 0, 0, 0.05);\n box-shadow: 0 1px 1px rgba(255, 255, 255, 0.8);\n}\n/**\n * Dark version for fold widgets\n */\n.ace_dark .ace_fold-widget {\n background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAAHklEQVQIW2P4//8/AzoGEQ7oGCaLLAhWiSwB146BAQCSTPYocqT0AAAAAElFTkSuQmCC");\n}\n.ace_dark .ace_fold-widget.ace_end {\n background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAAH0lEQVQIW2P4//8/AxQ7wNjIAjDMgC4AxjCVKBirIAAF0kz2rlhxpAAAAABJRU5ErkJggg==");\n}\n.ace_dark .ace_fold-widget.ace_closed {\n background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAMAAAAFCAYAAACAcVaiAAAAHElEQVQIW2P4//+/AxAzgDADlOOAznHAKgPWAwARji8UIDTfQQAAAABJRU5ErkJggg==");\n}\n.ace_dark .ace_fold-widget:hover {\n box-shadow: 0 1px 1px rgba(255, 255, 255, 0.2);\n background-color: rgba(255, 255, 255, 0.1);\n}\n.ace_dark .ace_fold-widget:active {\n box-shadow: 0 1px 1px rgba(255, 255, 255, 0.2);\n}\n\n.ace_inline_button {\n border: 1px solid lightgray;\n display: inline-block;\n margin: -1px 8px;\n padding: 0 5px;\n pointer-events: auto;\n cursor: pointer;\n}\n.ace_inline_button:hover {\n border-color: gray;\n background: rgba(200,200,200,0.2);\n display: inline-block;\n pointer-events: auto;\n}\n\n.ace_fold-widget.ace_invalid {\n background-color: #FFB4B4;\n border-color: #DE5555;\n}\n\n.ace_fade-fold-widgets .ace_fold-widget {\n transition: opacity 0.4s ease 0.05s;\n opacity: 0;\n}\n\n.ace_fade-fold-widgets:hover .ace_fold-widget {\n transition: opacity 0.05s ease 0.05s;\n opacity:1;\n}\n\n.ace_underline {\n text-decoration: underline;\n}\n\n.ace_bold {\n font-weight: bold;\n}\n\n.ace_nobold .ace_bold {\n font-weight: normal;\n}\n\n.ace_italic {\n font-style: italic;\n}\n\n\n.ace_error-marker {\n background-color: rgba(255, 0, 0,0.2);\n position: absolute;\n z-index: 9;\n}\n\n.ace_highlight-marker {\n background-color: rgba(255, 255, 0,0.2);\n position: absolute;\n z-index: 8;\n}\n\n.ace_mobile-menu {\n position: absolute;\n line-height: 1.5;\n border-radius: 4px;\n -ms-user-select: none;\n -moz-user-select: none;\n -webkit-user-select: none;\n user-select: none;\n background: white;\n box-shadow: 1px 3px 2px grey;\n border: 1px solid #dcdcdc;\n color: black;\n}\n.ace_dark > .ace_mobile-menu {\n background: #333;\n color: #ccc;\n box-shadow: 1px 3px 2px grey;\n border: 1px solid #444;\n\n}\n.ace_mobile-button {\n padding: 2px;\n cursor: pointer;\n overflow: hidden;\n}\n.ace_mobile-button:hover {\n background-color: #eee;\n opacity:1;\n}\n.ace_mobile-button:active {\n background-color: #ddd;\n}\n\n.ace_placeholder {\n font-family: arial;\n transform: scale(0.9);\n transform-origin: left;\n white-space: pre;\n opacity: 0.7;\n margin: 0 10px;\n}\n\n.ace_ghost_text {\n opacity: 0.5;\n font-style: italic;\n white-space: pre;\n}'})),ace.define("ace/layer/decorators",["require","exports","module","ace/lib/dom","ace/lib/oop","ace/lib/event_emitter"],(function(e,t,n){"use strict";var r=e("../lib/dom"),i=e("../lib/oop"),o=e("../lib/event_emitter").EventEmitter,s=function(){function e(e,t){this.canvas=r.createElement("canvas"),this.renderer=t,this.pixelRatio=1,this.maxHeight=t.layerConfig.maxHeight,this.lineHeight=t.layerConfig.lineHeight,this.canvasHeight=e.parent.scrollHeight,this.heightRatio=this.canvasHeight/this.maxHeight,this.canvasWidth=e.width,this.minDecorationHeight=2*this.pixelRatio|0,this.halfMinDecorationHeight=this.minDecorationHeight/2|0,this.canvas.width=this.canvasWidth,this.canvas.height=this.canvasHeight,this.canvas.style.top="0px",this.canvas.style.right="0px",this.canvas.style.zIndex="7px",this.canvas.style.position="absolute",this.colors={},this.colors.dark={error:"rgba(255, 18, 18, 1)",warning:"rgba(18, 136, 18, 1)",info:"rgba(18, 18, 136, 1)"},this.colors.light={error:"rgb(255,51,51)",warning:"rgb(32,133,72)",info:"rgb(35,68,138)"},e.element.appendChild(this.canvas)}return e.prototype.$updateDecorators=function(e){var t=!0===this.renderer.theme.isDark?this.colors.dark:this.colors.light;if(e){this.maxHeight=e.maxHeight,this.lineHeight=e.lineHeight,this.canvasHeight=e.height;var n=(e.lastRow+1)*this.lineHeight;n<this.canvasHeight?this.heightRatio=1:this.heightRatio=this.canvasHeight/this.maxHeight}var r=this.canvas.getContext("2d");function i(e,t){return e.priority<t.priority?-1:e.priority>t.priority?1:0}var o=this.renderer.session.$annotations;if(r.clearRect(0,0,this.canvas.width,this.canvas.height),o){var s={info:1,warning:2,error:3};o.forEach((function(e){e.priority=s[e.type]||null})),o=o.sort(i);for(var a=this.renderer.session.$foldData,l=0;l<o.length;l++){var c=o[l].row,u=this.compensateFoldRows(c,a),h=Math.round((c-u)*this.lineHeight*this.heightRatio),f=Math.round((c-u)*this.lineHeight*this.heightRatio),d=Math.round(((c-u)*this.lineHeight+this.lineHeight)*this.heightRatio),p=d-f;if(p<this.minDecorationHeight){var g=(f+d)/2|0;g<this.halfMinDecorationHeight?g=this.halfMinDecorationHeight:g+this.halfMinDecorationHeight>this.canvasHeight&&(g=this.canvasHeight-this.halfMinDecorationHeight),f=Math.round(g-this.halfMinDecorationHeight),d=Math.round(g+this.halfMinDecorationHeight)}r.fillStyle=t[o[l].type]||null,r.fillRect(0,h,this.canvasWidth,d-f)}}var m=this.renderer.session.selection.getCursor();if(m){u=this.compensateFoldRows(m.row,a),h=Math.round((m.row-u)*this.lineHeight*this.heightRatio);r.fillStyle="rgba(0, 0, 0, 0.5)",r.fillRect(0,h,this.canvasWidth,2)}},e.prototype.compensateFoldRows=function(e,t){var n=0;if(t&&t.length>0)for(var r=0;r<t.length;r++)e>t[r].start.row&&e<t[r].end.row?n+=e-t[r].start.row:e>=t[r].end.row&&(n+=t[r].end.row-t[r].start.row);return n},e}();i.implement(s.prototype,o),t.Decorator=s})),ace.define("ace/virtual_renderer",["require","exports","module","ace/lib/oop","ace/lib/dom","ace/lib/lang","ace/config","ace/layer/gutter","ace/layer/marker","ace/layer/text","ace/layer/cursor","ace/scrollbar","ace/scrollbar","ace/scrollbar_custom","ace/scrollbar_custom","ace/renderloop","ace/layer/font_metrics","ace/lib/event_emitter","ace/css/editor.css","ace/layer/decorators","ace/lib/useragent"],(function(e,t,n){"use strict";var r=e("./lib/oop"),i=e("./lib/dom"),o=e("./lib/lang"),s=e("./config"),a=e("./layer/gutter").Gutter,l=e("./layer/marker").Marker,c=e("./layer/text").Text,u=e("./layer/cursor").Cursor,h=e("./scrollbar").HScrollBar,f=e("./scrollbar").VScrollBar,d=e("./scrollbar_custom").HScrollBar,p=e("./scrollbar_custom").VScrollBar,g=e("./renderloop").RenderLoop,m=e("./layer/font_metrics").FontMetrics,v=e("./lib/event_emitter").EventEmitter,y=e("./css/editor.css"),w=e("./layer/decorators").Decorator,b=e("./lib/useragent");i.importCssString(y,"ace_editor.css",!1);var x=function(){function e(e,t){var n=this;this.container=e||i.createElement("div"),i.addCssClass(this.container,"ace_editor"),i.HI_DPI&&i.addCssClass(this.container,"ace_hidpi"),this.setTheme(t),null==s.get("useStrictCSP")&&s.set("useStrictCSP",!1),this.$gutter=i.createElement("div"),this.$gutter.className="ace_gutter",this.container.appendChild(this.$gutter),this.$gutter.setAttribute("aria-hidden",!0),this.scroller=i.createElement("div"),this.scroller.className="ace_scroller",this.container.appendChild(this.scroller),this.content=i.createElement("div"),this.content.className="ace_content",this.scroller.appendChild(this.content),this.$gutterLayer=new a(this.$gutter),this.$gutterLayer.on("changeGutterWidth",this.onGutterResize.bind(this)),this.$markerBack=new l(this.content);var r=this.$textLayer=new c(this.content);this.canvas=r.element,this.$markerFront=new l(this.content),this.$cursorLayer=new u(this.content),this.$horizScroll=!1,this.$vScroll=!1,this.scrollBar=this.scrollBarV=new f(this.container,this),this.scrollBarH=new h(this.container,this),this.scrollBarV.on("scroll",(function(e){n.$scrollAnimation||n.session.setScrollTop(e.data-n.scrollMargin.top)})),this.scrollBarH.on("scroll",(function(e){n.$scrollAnimation||n.session.setScrollLeft(e.data-n.scrollMargin.left)})),this.scrollTop=0,this.scrollLeft=0,this.cursorPos={row:0,column:0},this.$fontMetrics=new m(this.container),this.$textLayer.$setFontMetrics(this.$fontMetrics),this.$textLayer.on("changeCharacterSize",(function(e){n.updateCharacterSize(),n.onResize(!0,n.gutterWidth,n.$size.width,n.$size.height),n._signal("changeCharacterSize",e)})),this.$size={width:0,height:0,scrollerHeight:0,scrollerWidth:0,$dirty:!0},this.layerConfig={width:1,padding:0,firstRow:0,firstRowScreen:0,lastRow:0,lineHeight:0,characterWidth:0,minHeight:1,maxHeight:1,offset:0,height:1,gutterOffset:1},this.scrollMargin={left:0,right:0,top:0,bottom:0,v:0,h:0},this.margin={left:0,right:0,top:0,bottom:0,v:0,h:0},this.$keepTextAreaAtCursor=!b.isIOS,this.$loop=new g(this.$renderChanges.bind(this),this.container.ownerDocument.defaultView),this.$loop.schedule(this.CHANGE_FULL),this.updateCharacterSize(),this.setPadding(4),this.$addResizeObserver(),s.resetOptions(this),s._signal("renderer",this)}return e.prototype.updateCharacterSize=function(){this.$textLayer.allowBoldFonts!=this.$allowBoldFonts&&(this.$allowBoldFonts=this.$textLayer.allowBoldFonts,this.setStyle("ace_nobold",!this.$allowBoldFonts)),this.layerConfig.characterWidth=this.characterWidth=this.$textLayer.getCharacterWidth(),this.layerConfig.lineHeight=this.lineHeight=this.$textLayer.getLineHeight(),this.$updatePrintMargin(),i.setStyle(this.scroller.style,"line-height",this.lineHeight+"px")},e.prototype.setSession=function(e){this.session&&this.session.doc.off("changeNewLineMode",this.onChangeNewLineMode),this.session=e,e&&this.scrollMargin.top&&e.getScrollTop()<=0&&e.setScrollTop(-this.scrollMargin.top),this.$cursorLayer.setSession(e),this.$markerBack.setSession(e),this.$markerFront.setSession(e),this.$gutterLayer.setSession(e),this.$textLayer.setSession(e),e&&(this.$loop.schedule(this.CHANGE_FULL),this.session.$setFontMetrics(this.$fontMetrics),this.scrollBarH.scrollLeft=this.scrollBarV.scrollTop=null,this.onChangeNewLineMode=this.onChangeNewLineMode.bind(this),this.onChangeNewLineMode(),this.session.doc.on("changeNewLineMode",this.onChangeNewLineMode))},e.prototype.updateLines=function(e,t,n){if(void 0===t&&(t=1/0),this.$changedLines?(this.$changedLines.firstRow>e&&(this.$changedLines.firstRow=e),this.$changedLines.lastRow<t&&(this.$changedLines.lastRow=t)):this.$changedLines={firstRow:e,lastRow:t},this.$changedLines.lastRow<this.layerConfig.firstRow){if(!n)return;this.$changedLines.lastRow=this.layerConfig.lastRow}this.$changedLines.firstRow>this.layerConfig.lastRow||this.$loop.schedule(this.CHANGE_LINES)},e.prototype.onChangeNewLineMode=function(){this.$loop.schedule(this.CHANGE_TEXT),this.$textLayer.$updateEolChar(),this.session.$bidiHandler.setEolChar(this.$textLayer.EOL_CHAR)},e.prototype.onChangeTabSize=function(){this.$loop.schedule(this.CHANGE_TEXT|this.CHANGE_MARKER),this.$textLayer.onChangeTabSize()},e.prototype.updateText=function(){this.$loop.schedule(this.CHANGE_TEXT)},e.prototype.updateFull=function(e){e?this.$renderChanges(this.CHANGE_FULL,!0):this.$loop.schedule(this.CHANGE_FULL)},e.prototype.updateFontSize=function(){this.$textLayer.checkForSizeChanges()},e.prototype.$updateSizeAsync=function(){this.$loop.pending?this.$size.$dirty=!0:this.onResize()},e.prototype.onResize=function(e,t,n,r){if(!(this.resizing>2)){this.resizing>0?this.resizing++:this.resizing=e?1:0;var i=this.container;r||(r=i.clientHeight||i.scrollHeight),n||(n=i.clientWidth||i.scrollWidth);var o=this.$updateCachedSize(e,t,n,r);if(this.$resizeTimer&&this.$resizeTimer.cancel(),!this.$size.scrollerHeight||!n&&!r)return this.resizing=0;e&&(this.$gutterLayer.$padding=null),e?this.$renderChanges(o|this.$changes,!0):this.$loop.schedule(o|this.$changes),this.resizing&&(this.resizing=0),this.scrollBarH.scrollLeft=this.scrollBarV.scrollTop=null,this.$customScrollbar&&this.$updateCustomScrollbar(!0)}},e.prototype.$updateCachedSize=function(e,t,n,r){r-=this.$extraHeight||0;var o=0,s=this.$size,a={width:s.width,height:s.height,scrollerHeight:s.scrollerHeight,scrollerWidth:s.scrollerWidth};if(r&&(e||s.height!=r)&&(s.height=r,o|=this.CHANGE_SIZE,s.scrollerHeight=s.height,this.$horizScroll&&(s.scrollerHeight-=this.scrollBarH.getHeight()),this.scrollBarV.setHeight(s.scrollerHeight),this.scrollBarV.element.style.bottom=this.scrollBarH.getHeight()+"px",o|=this.CHANGE_SCROLL),n&&(e||s.width!=n)){o|=this.CHANGE_SIZE,s.width=n,null==t&&(t=this.$showGutter?this.$gutter.offsetWidth:0),this.gutterWidth=t,i.setStyle(this.scrollBarH.element.style,"left",t+"px"),i.setStyle(this.scroller.style,"left",t+this.margin.left+"px"),s.scrollerWidth=Math.max(0,n-t-this.scrollBarV.getWidth()-this.margin.h),i.setStyle(this.$gutter.style,"left",this.margin.left+"px");var l=this.scrollBarV.getWidth()+"px";i.setStyle(this.scrollBarH.element.style,"right",l),i.setStyle(this.scroller.style,"right",l),i.setStyle(this.scroller.style,"bottom",this.scrollBarH.getHeight()),this.scrollBarH.setWidth(s.scrollerWidth),(this.session&&this.session.getUseWrapMode()&&this.adjustWrapLimit()||e)&&(o|=this.CHANGE_FULL)}return s.$dirty=!n||!r,o&&this._signal("resize",a),o},e.prototype.onGutterResize=function(e){var t=this.$showGutter?e:0;t!=this.gutterWidth&&(this.$changes|=this.$updateCachedSize(!0,t,this.$size.width,this.$size.height)),this.session.getUseWrapMode()&&this.adjustWrapLimit()||this.$size.$dirty?this.$loop.schedule(this.CHANGE_FULL):this.$computeLayerConfig()},e.prototype.adjustWrapLimit=function(){var e=this.$size.scrollerWidth-2*this.$padding,t=Math.floor(e/this.characterWidth);return this.session.adjustWrapLimit(t,this.$showPrintMargin&&this.$printMarginColumn)},e.prototype.setAnimatedScroll=function(e){this.setOption("animatedScroll",e)},e.prototype.getAnimatedScroll=function(){return this.$animatedScroll},e.prototype.setShowInvisibles=function(e){this.setOption("showInvisibles",e),this.session.$bidiHandler.setShowInvisibles(e)},e.prototype.getShowInvisibles=function(){return this.getOption("showInvisibles")},e.prototype.getDisplayIndentGuide=function(){return this.getOption("displayIndentGuides")},e.prototype.setDisplayIndentGuides=function(e){this.setOption("displayIndentGuides",e)},e.prototype.getHighlightIndentGuides=function(){return this.getOption("highlightIndentGuides")},e.prototype.setHighlightIndentGuides=function(e){this.setOption("highlightIndentGuides",e)},e.prototype.setShowPrintMargin=function(e){this.setOption("showPrintMargin",e)},e.prototype.getShowPrintMargin=function(){return this.getOption("showPrintMargin")},e.prototype.setPrintMarginColumn=function(e){this.setOption("printMarginColumn",e)},e.prototype.getPrintMarginColumn=function(){return this.getOption("printMarginColumn")},e.prototype.getShowGutter=function(){return this.getOption("showGutter")},e.prototype.setShowGutter=function(e){return this.setOption("showGutter",e)},e.prototype.getFadeFoldWidgets=function(){return this.getOption("fadeFoldWidgets")},e.prototype.setFadeFoldWidgets=function(e){this.setOption("fadeFoldWidgets",e)},e.prototype.setHighlightGutterLine=function(e){this.setOption("highlightGutterLine",e)},e.prototype.getHighlightGutterLine=function(){return this.getOption("highlightGutterLine")},e.prototype.$updatePrintMargin=function(){if(this.$showPrintMargin||this.$printMarginEl){if(!this.$printMarginEl){var e=i.createElement("div");e.className="ace_layer ace_print-margin-layer",this.$printMarginEl=i.createElement("div"),this.$printMarginEl.className="ace_print-margin",e.appendChild(this.$printMarginEl),this.content.insertBefore(e,this.content.firstChild)}var t=this.$printMarginEl.style;t.left=Math.round(this.characterWidth*this.$printMarginColumn+this.$padding)+"px",t.visibility=this.$showPrintMargin?"visible":"hidden",this.session&&-1==this.session.$wrap&&this.adjustWrapLimit()}},e.prototype.getContainerElement=function(){return this.container},e.prototype.getMouseEventTarget=function(){return this.scroller},e.prototype.getTextAreaContainer=function(){return this.container},e.prototype.$moveTextAreaToCursor=function(){if(!this.$isMousePressed){var e=this.textarea.style,t=this.$composition;if(this.$keepTextAreaAtCursor||t){var n=this.$cursorLayer.$pixelPos;if(n){t&&t.markerRange&&(n=this.$cursorLayer.getPixelPosition(t.markerRange.start,!0));var r=this.layerConfig,o=n.top,s=n.left;o-=r.offset;var a=t&&t.useTextareaForIME||b.isMobile?this.lineHeight:1;if(o<0||o>r.height-a)i.translate(this.textarea,0,0);else{var l=1,c=this.$size.height-a;if(t)if(t.useTextareaForIME){var u=this.textarea.value;l=this.characterWidth*this.session.$getStringScreenWidth(u)[0]}else o+=this.lineHeight+2;else o+=this.lineHeight;s-=this.scrollLeft,s>this.$size.scrollerWidth-l&&(s=this.$size.scrollerWidth-l),s+=this.gutterWidth+this.margin.left,i.setStyle(e,"height",a+"px"),i.setStyle(e,"width",l+"px"),i.translate(this.textarea,Math.min(s,this.$size.scrollerWidth-l),Math.min(o,c))}}}else i.translate(this.textarea,-100,0)}},e.prototype.getFirstVisibleRow=function(){return this.layerConfig.firstRow},e.prototype.getFirstFullyVisibleRow=function(){return this.layerConfig.firstRow+(0===this.layerConfig.offset?0:1)},e.prototype.getLastFullyVisibleRow=function(){var e=this.layerConfig,t=e.lastRow,n=this.session.documentToScreenRow(t,0)*e.lineHeight;return n-this.session.getScrollTop()>e.height-e.lineHeight?t-1:t},e.prototype.getLastVisibleRow=function(){return this.layerConfig.lastRow},e.prototype.setPadding=function(e){this.$padding=e,this.$textLayer.setPadding(e),this.$cursorLayer.setPadding(e),this.$markerFront.setPadding(e),this.$markerBack.setPadding(e),this.$loop.schedule(this.CHANGE_FULL),this.$updatePrintMargin()},e.prototype.setScrollMargin=function(e,t,n,r){var i=this.scrollMargin;i.top=0|e,i.bottom=0|t,i.right=0|r,i.left=0|n,i.v=i.top+i.bottom,i.h=i.left+i.right,i.top&&this.scrollTop<=0&&this.session&&this.session.setScrollTop(-i.top),this.updateFull()},e.prototype.setMargin=function(e,t,n,r){var i=this.margin;i.top=0|e,i.bottom=0|t,i.right=0|r,i.left=0|n,i.v=i.top+i.bottom,i.h=i.left+i.right,this.$updateCachedSize(!0,this.gutterWidth,this.$size.width,this.$size.height),this.updateFull()},e.prototype.getHScrollBarAlwaysVisible=function(){return this.$hScrollBarAlwaysVisible},e.prototype.setHScrollBarAlwaysVisible=function(e){this.setOption("hScrollBarAlwaysVisible",e)},e.prototype.getVScrollBarAlwaysVisible=function(){return this.$vScrollBarAlwaysVisible},e.prototype.setVScrollBarAlwaysVisible=function(e){this.setOption("vScrollBarAlwaysVisible",e)},e.prototype.$updateScrollBarV=function(){var e=this.layerConfig.maxHeight,t=this.$size.scrollerHeight;!this.$maxLines&&this.$scrollPastEnd&&(e-=(t-this.lineHeight)*this.$scrollPastEnd,this.scrollTop>e-t&&(e=this.scrollTop+t,this.scrollBarV.scrollTop=null)),this.scrollBarV.setScrollHeight(e+this.scrollMargin.v),this.scrollBarV.setScrollTop(this.scrollTop+this.scrollMargin.top)},e.prototype.$updateScrollBarH=function(){this.scrollBarH.setScrollWidth(this.layerConfig.width+2*this.$padding+this.scrollMargin.h),this.scrollBarH.setScrollLeft(this.scrollLeft+this.scrollMargin.left)},e.prototype.freeze=function(){this.$frozen=!0},e.prototype.unfreeze=function(){this.$frozen=!1},e.prototype.$renderChanges=function(e,t){if(this.$changes&&(e|=this.$changes,this.$changes=0),this.session&&this.container.offsetWidth&&!this.$frozen&&(e||t)){if(this.$size.$dirty)return this.$changes|=e,this.onResize(!0);this.lineHeight||this.$textLayer.checkForSizeChanges(),this._signal("beforeRender",e),this.session&&this.session.$bidiHandler&&this.session.$bidiHandler.updateCharacterWidths(this.$fontMetrics);var n=this.layerConfig;if(e&this.CHANGE_FULL||e&this.CHANGE_SIZE||e&this.CHANGE_TEXT||e&this.CHANGE_LINES||e&this.CHANGE_SCROLL||e&this.CHANGE_H_SCROLL){if(e|=this.$computeLayerConfig()|this.$loop.clear(),n.firstRow!=this.layerConfig.firstRow&&n.firstRowScreen==this.layerConfig.firstRowScreen){var r=this.scrollTop+(n.firstRow-Math.max(this.layerConfig.firstRow,0))*this.lineHeight;r>0&&(this.scrollTop=r,e|=this.CHANGE_SCROLL,e|=this.$computeLayerConfig()|this.$loop.clear())}n=this.layerConfig,this.$updateScrollBarV(),e&this.CHANGE_H_SCROLL&&this.$updateScrollBarH(),i.translate(this.content,-this.scrollLeft,-n.offset);var o=n.width+2*this.$padding+"px",s=n.minHeight+"px";i.setStyle(this.content.style,"width",o),i.setStyle(this.content.style,"height",s)}if(e&this.CHANGE_H_SCROLL&&(i.translate(this.content,-this.scrollLeft,-n.offset),this.scroller.className=this.scrollLeft<=0?"ace_scroller":"ace_scroller ace_scroll-left"),e&this.CHANGE_FULL)return this.$changedLines=null,this.$textLayer.update(n),this.$showGutter&&this.$gutterLayer.update(n),this.$customScrollbar&&this.$scrollDecorator.$updateDecorators(n),this.$markerBack.update(n),this.$markerFront.update(n),this.$cursorLayer.update(n),this.$moveTextAreaToCursor(),void this._signal("afterRender",e);if(e&this.CHANGE_SCROLL)return this.$changedLines=null,e&this.CHANGE_TEXT||e&this.CHANGE_LINES?this.$textLayer.update(n):this.$textLayer.scrollLines(n),this.$showGutter&&(e&this.CHANGE_GUTTER||e&this.CHANGE_LINES?this.$gutterLayer.update(n):this.$gutterLayer.scrollLines(n)),this.$customScrollbar&&this.$scrollDecorator.$updateDecorators(n),this.$markerBack.update(n),this.$markerFront.update(n),this.$cursorLayer.update(n),this.$moveTextAreaToCursor(),void this._signal("afterRender",e);e&this.CHANGE_TEXT?(this.$changedLines=null,this.$textLayer.update(n),this.$showGutter&&this.$gutterLayer.update(n),this.$customScrollbar&&this.$scrollDecorator.$updateDecorators(n)):e&this.CHANGE_LINES?((this.$updateLines()||e&this.CHANGE_GUTTER&&this.$showGutter)&&this.$gutterLayer.update(n),this.$customScrollbar&&this.$scrollDecorator.$updateDecorators(n)):e&this.CHANGE_TEXT||e&this.CHANGE_GUTTER?(this.$showGutter&&this.$gutterLayer.update(n),this.$customScrollbar&&this.$scrollDecorator.$updateDecorators(n)):e&this.CHANGE_CURSOR&&(this.$highlightGutterLine&&this.$gutterLayer.updateLineHighlight(n),this.$customScrollbar&&this.$scrollDecorator.$updateDecorators(n)),e&this.CHANGE_CURSOR&&(this.$cursorLayer.update(n),this.$moveTextAreaToCursor()),e&(this.CHANGE_MARKER|this.CHANGE_MARKER_FRONT)&&this.$markerFront.update(n),e&(this.CHANGE_MARKER|this.CHANGE_MARKER_BACK)&&this.$markerBack.update(n),this._signal("afterRender",e)}else this.$changes|=e},e.prototype.$autosize=function(){var e=this.session.getScreenLength()*this.lineHeight,t=this.$maxLines*this.lineHeight,n=Math.min(t,Math.max((this.$minLines||1)*this.lineHeight,e))+this.scrollMargin.v+(this.$extraHeight||0);this.$horizScroll&&(n+=this.scrollBarH.getHeight()),this.$maxPixelHeight&&n>this.$maxPixelHeight&&(n=this.$maxPixelHeight);var r=n<=2*this.lineHeight,i=!r&&e>t;if(n!=this.desiredHeight||this.$size.height!=this.desiredHeight||i!=this.$vScroll){i!=this.$vScroll&&(this.$vScroll=i,this.scrollBarV.setVisible(i));var o=this.container.clientWidth;this.container.style.height=n+"px",this.$updateCachedSize(!0,this.$gutterWidth,o,n),this.desiredHeight=n,this._signal("autosize")}},e.prototype.$computeLayerConfig=function(){var e=this.session,t=this.$size,n=t.height<=2*this.lineHeight,r=this.session.getScreenLength(),i=r*this.lineHeight,o=this.$getLongestLine(),s=!n&&(this.$hScrollBarAlwaysVisible||t.scrollerWidth-o-2*this.$padding<0),a=this.$horizScroll!==s;a&&(this.$horizScroll=s,this.scrollBarH.setVisible(s));var l=this.$vScroll;this.$maxLines&&this.lineHeight>1&&this.$autosize();var c=t.scrollerHeight+this.lineHeight,u=!this.$maxLines&&this.$scrollPastEnd?(t.scrollerHeight-this.lineHeight)*this.$scrollPastEnd:0;i+=u;var h=this.scrollMargin;this.session.setScrollTop(Math.max(-h.top,Math.min(this.scrollTop,i-t.scrollerHeight+h.bottom))),this.session.setScrollLeft(Math.max(-h.left,Math.min(this.scrollLeft,o+2*this.$padding-t.scrollerWidth+h.right)));var f=!n&&(this.$vScrollBarAlwaysVisible||t.scrollerHeight-i+u<0||this.scrollTop>h.top),d=l!==f;d&&(this.$vScroll=f,this.scrollBarV.setVisible(f));var p,g,m=this.scrollTop%this.lineHeight,v=Math.ceil(c/this.lineHeight)-1,y=Math.max(0,Math.round((this.scrollTop-m)/this.lineHeight)),w=y+v,b=this.lineHeight;y=e.screenToDocumentRow(y,0);var x=e.getFoldLine(y);x&&(y=x.start.row),p=e.documentToScreenRow(y,0),g=e.getRowLength(y)*b,w=Math.min(e.screenToDocumentRow(w,0),e.getLength()-1),c=t.scrollerHeight+e.getRowLength(w)*b+g,m=this.scrollTop-p*b;var S=0;return(this.layerConfig.width!=o||a)&&(S=this.CHANGE_H_SCROLL),(a||d)&&(S|=this.$updateCachedSize(!0,this.gutterWidth,t.width,t.height),this._signal("scrollbarVisibilityChanged"),d&&(o=this.$getLongestLine())),this.layerConfig={width:o,padding:this.$padding,firstRow:y,firstRowScreen:p,lastRow:w,lineHeight:b,characterWidth:this.characterWidth,minHeight:c,maxHeight:i,offset:m,gutterOffset:b?Math.max(0,Math.ceil((m+t.height-t.scrollerHeight)/b)):0,height:this.$size.scrollerHeight},this.session.$bidiHandler&&this.session.$bidiHandler.setContentWidth(o-this.$padding),S},e.prototype.$updateLines=function(){if(this.$changedLines){var e=this.$changedLines.firstRow,t=this.$changedLines.lastRow;this.$changedLines=null;var n=this.layerConfig;if(!(e>n.lastRow+1)&&!(t<n.firstRow))return t===1/0?(this.$showGutter&&this.$gutterLayer.update(n),void this.$textLayer.update(n)):(this.$textLayer.updateLines(n,e,t),!0)}},e.prototype.$getLongestLine=function(){var e=this.session.getScreenWidth();return this.showInvisibles&&!this.session.$useWrapMode&&(e+=1),this.$textLayer&&e>this.$textLayer.MAX_LINE_LENGTH&&(e=this.$textLayer.MAX_LINE_LENGTH+30),Math.max(this.$size.scrollerWidth-2*this.$padding,Math.round(e*this.characterWidth))},e.prototype.updateFrontMarkers=function(){this.$markerFront.setMarkers(this.session.getMarkers(!0)),this.$loop.schedule(this.CHANGE_MARKER_FRONT)},e.prototype.updateBackMarkers=function(){this.$markerBack.setMarkers(this.session.getMarkers()),this.$loop.schedule(this.CHANGE_MARKER_BACK)},e.prototype.addGutterDecoration=function(e,t){this.$gutterLayer.addGutterDecoration(e,t)},e.prototype.removeGutterDecoration=function(e,t){this.$gutterLayer.removeGutterDecoration(e,t)},e.prototype.updateBreakpoints=function(e){this.$loop.schedule(this.CHANGE_GUTTER)},e.prototype.setAnnotations=function(e){this.$gutterLayer.setAnnotations(e),this.$loop.schedule(this.CHANGE_GUTTER)},e.prototype.updateCursor=function(){this.$loop.schedule(this.CHANGE_CURSOR)},e.prototype.hideCursor=function(){this.$cursorLayer.hideCursor()},e.prototype.showCursor=function(){this.$cursorLayer.showCursor()},e.prototype.scrollSelectionIntoView=function(e,t,n){this.scrollCursorIntoView(e,n),this.scrollCursorIntoView(t,n)},e.prototype.scrollCursorIntoView=function(e,t,n){if(0!==this.$size.scrollerHeight){var r=this.$cursorLayer.getPixelPosition(e),i=r.left,o=r.top,s=n&&n.top||0,a=n&&n.bottom||0;this.$scrollAnimation&&(this.$stopAnimation=!0);var l=this.$scrollAnimation?this.session.getScrollTop():this.scrollTop;l+s>o?(t&&l+s>o+this.lineHeight&&(o-=t*this.$size.scrollerHeight),0===o&&(o=-this.scrollMargin.top),this.session.setScrollTop(o)):l+this.$size.scrollerHeight-a<o+this.lineHeight&&(t&&l+this.$size.scrollerHeight-a<o-this.lineHeight&&(o+=t*this.$size.scrollerHeight),this.session.setScrollTop(o+this.lineHeight+a-this.$size.scrollerHeight));var c=this.scrollLeft,u=2*this.layerConfig.characterWidth;i-u<c?(i-=u,i<this.$padding+u&&(i=-this.scrollMargin.left),this.session.setScrollLeft(i)):(i+=u,c+this.$size.scrollerWidth<i+this.characterWidth?this.session.setScrollLeft(Math.round(i+this.characterWidth-this.$size.scrollerWidth)):c<=this.$padding&&i-c<this.characterWidth&&this.session.setScrollLeft(0))}},e.prototype.getScrollTop=function(){return this.session.getScrollTop()},e.prototype.getScrollLeft=function(){return this.session.getScrollLeft()},e.prototype.getScrollTopRow=function(){return this.scrollTop/this.lineHeight},e.prototype.getScrollBottomRow=function(){return Math.max(0,Math.floor((this.scrollTop+this.$size.scrollerHeight)/this.lineHeight)-1)},e.prototype.scrollToRow=function(e){this.session.setScrollTop(e*this.lineHeight)},e.prototype.alignCursor=function(e,t){"number"==typeof e&&(e={row:e,column:0});var n=this.$cursorLayer.getPixelPosition(e),r=this.$size.scrollerHeight-this.lineHeight,i=n.top-r*(t||0);return this.session.setScrollTop(i),i},e.prototype.$calcSteps=function(e,t){var n=0,r=this.STEPS,i=[],o=function(e,t,n){return n*(Math.pow(e-1,3)+1)+t};for(n=0;n<r;++n)i.push(o(n/this.STEPS,e,t-e));return i},e.prototype.scrollToLine=function(e,t,n,r){var i=this.$cursorLayer.getPixelPosition({row:e,column:0}),o=i.top;t&&(o-=this.$size.scrollerHeight/2);var s=this.scrollTop;this.session.setScrollTop(o),!1!==n&&this.animateScrolling(s,r)},e.prototype.animateScrolling=function(e,t){var n=this.scrollTop;if(this.$animatedScroll){var r=this;if(e!=n){if(this.$scrollAnimation){var i=this.$scrollAnimation.steps;if(i.length&&(e=i[0],e==n))return}var o=r.$calcSteps(e,n);this.$scrollAnimation={from:e,to:n,steps:o},clearInterval(this.$timer),r.session.setScrollTop(o.shift()),r.session.$scrollTop=n,this.$timer=setInterval((function(){if(!r.$stopAnimation)return r.session?void(o.length?(r.session.setScrollTop(o.shift()),r.session.$scrollTop=n):null!=n?(r.session.$scrollTop=-1,r.session.setScrollTop(n),n=null):s()):clearInterval(r.$timer);s()}),10)}}function s(){r.$timer=clearInterval(r.$timer),r.$scrollAnimation=null,r.$stopAnimation=!1,t&&t()}},e.prototype.scrollToY=function(e){this.scrollTop!==e&&(this.$loop.schedule(this.CHANGE_SCROLL),this.scrollTop=e)},e.prototype.scrollToX=function(e){this.scrollLeft!==e&&(this.scrollLeft=e),this.$loop.schedule(this.CHANGE_H_SCROLL)},e.prototype.scrollTo=function(e,t){this.session.setScrollTop(t),this.session.setScrollLeft(e)},e.prototype.scrollBy=function(e,t){t&&this.session.setScrollTop(this.session.getScrollTop()+t),e&&this.session.setScrollLeft(this.session.getScrollLeft()+e)},e.prototype.isScrollableBy=function(e,t){return t<0&&this.session.getScrollTop()>=1-this.scrollMargin.top||(t>0&&this.session.getScrollTop()+this.$size.scrollerHeight-this.layerConfig.maxHeight<-1+this.scrollMargin.bottom||(e<0&&this.session.getScrollLeft()>=1-this.scrollMargin.left||(e>0&&this.session.getScrollLeft()+this.$size.scrollerWidth-this.layerConfig.width<-1+this.scrollMargin.right||void 0)))},e.prototype.pixelToScreenCoordinates=function(e,t){var n;if(this.$hasCssTransforms){n={top:0,left:0};var r=this.$fontMetrics.transformCoordinates([e,t]);e=r[1]-this.gutterWidth-this.margin.left,t=r[0]}else n=this.scroller.getBoundingClientRect();var i=e+this.scrollLeft-n.left-this.$padding,o=i/this.characterWidth,s=Math.floor((t+this.scrollTop-n.top)/this.lineHeight),a=this.$blockCursor?Math.floor(o):Math.round(o);return{row:s,column:a,side:o-a>0?1:-1,offsetX:i}},e.prototype.screenToTextCoordinates=function(e,t){var n;if(this.$hasCssTransforms){n={top:0,left:0};var r=this.$fontMetrics.transformCoordinates([e,t]);e=r[1]-this.gutterWidth-this.margin.left,t=r[0]}else n=this.scroller.getBoundingClientRect();var i=e+this.scrollLeft-n.left-this.$padding,o=i/this.characterWidth,s=this.$blockCursor?Math.floor(o):Math.round(o),a=Math.floor((t+this.scrollTop-n.top)/this.lineHeight);return this.session.screenToDocumentPosition(a,Math.max(s,0),i)},e.prototype.textToScreenCoordinates=function(e,t){var n=this.scroller.getBoundingClientRect(),r=this.session.documentToScreenPosition(e,t),i=this.$padding+(this.session.$bidiHandler.isBidiRow(r.row,e)?this.session.$bidiHandler.getPosLeft(r.column):Math.round(r.column*this.characterWidth)),o=r.row*this.lineHeight;return{pageX:n.left+i-this.scrollLeft,pageY:n.top+o-this.scrollTop}},e.prototype.visualizeFocus=function(){i.addCssClass(this.container,"ace_focus")},e.prototype.visualizeBlur=function(){i.removeCssClass(this.container,"ace_focus")},e.prototype.showComposition=function(e){this.$composition=e,e.cssText||(e.cssText=this.textarea.style.cssText),void 0==e.useTextareaForIME&&(e.useTextareaForIME=this.$useTextareaForIME),this.$useTextareaForIME?(i.addCssClass(this.textarea,"ace_composition"),this.textarea.style.cssText="",this.$moveTextAreaToCursor(),this.$cursorLayer.element.style.display="none"):e.markerId=this.session.addMarker(e.markerRange,"ace_composition_marker","text")},e.prototype.setCompositionText=function(e){var t=this.session.selection.cursor;this.addToken(e,"composition_placeholder",t.row,t.column),this.$moveTextAreaToCursor()},e.prototype.hideComposition=function(){if(this.$composition){this.$composition.markerId&&this.session.removeMarker(this.$composition.markerId),i.removeCssClass(this.textarea,"ace_composition"),this.textarea.style.cssText=this.$composition.cssText;var e=this.session.selection.cursor;this.removeExtraToken(e.row,e.column),this.$composition=null,this.$cursorLayer.element.style.display=""}},e.prototype.setGhostText=function(e,t){var n=this.session.selection.cursor,r=t||{row:n.row,column:n.column};this.removeGhostText();var i=e.split("\n");this.addToken(i[0],"ghost_text",r.row,r.column),this.$ghostText={text:e,position:{row:r.row,column:r.column}},i.length>1&&(this.$ghostTextWidget={text:i.slice(1).join("\n"),row:r.row,column:r.column,className:"ace_ghost_text"},this.session.widgetManager.addLineWidget(this.$ghostTextWidget))},e.prototype.removeGhostText=function(){if(this.$ghostText){var e=this.$ghostText.position;this.removeExtraToken(e.row,e.column),this.$ghostTextWidget&&(this.session.widgetManager.removeLineWidget(this.$ghostTextWidget),this.$ghostTextWidget=null),this.$ghostText=null}},e.prototype.addToken=function(e,t,n,r){var i=this.session;i.bgTokenizer.lines[n]=null;var o={type:t,value:e},s=i.getTokens(n);if(null!=r&&s.length)for(var a=0,l=0;l<s.length;l++){var c=s[l];if(a+=c.value.length,r<=a){var u=c.value.length-(a-r),h=c.value.slice(0,u),f=c.value.slice(u);s.splice(l,1,{type:c.type,value:h},o,{type:c.type,value:f});break}}else s.push(o);this.updateLines(n,n)},e.prototype.removeExtraToken=function(e,t){this.session.bgTokenizer.lines[e]=null,this.updateLines(e,e)},e.prototype.setTheme=function(e,t){var n=this;if(this.$themeId=e,n._dispatchEvent("themeChange",{theme:e}),e&&"string"!=typeof e)o(e);else{var r=e||this.$options.theme.initialValue;s.loadModule(["theme",r],o)}function o(r){if(n.$themeId!=e)return t&&t();if(!r||!r.cssClass)throw new Error("couldn't load module "+e+" or it didn't call define");r.$id&&(n.$themeId=r.$id),i.importCssString(r.cssText,r.cssClass,n.container),n.theme&&i.removeCssClass(n.container,n.theme.cssClass);var o="padding"in r?r.padding:"padding"in(n.theme||{})?4:n.$padding;n.$padding&&o!=n.$padding&&n.setPadding(o),n.$theme=r.cssClass,n.theme=r,i.addCssClass(n.container,r.cssClass),i.setCssClass(n.container,"ace_dark",r.isDark),n.$size&&(n.$size.width=0,n.$updateSizeAsync()),n._dispatchEvent("themeLoaded",{theme:r}),t&&t()}},e.prototype.getTheme=function(){return this.$themeId},e.prototype.setStyle=function(e,t){i.setCssClass(this.container,e,!1!==t)},e.prototype.unsetStyle=function(e){i.removeCssClass(this.container,e)},e.prototype.setCursorStyle=function(e){i.setStyle(this.scroller.style,"cursor",e)},e.prototype.setMouseCursor=function(e){i.setStyle(this.scroller.style,"cursor",e)},e.prototype.attachToShadowRoot=function(){i.importCssString(y,"ace_editor.css",this.container)},e.prototype.destroy=function(){this.freeze(),this.$fontMetrics.destroy(),this.$cursorLayer.destroy(),this.removeAllListeners(),this.container.textContent="",this.setOption("useResizeObserver",!1)},e.prototype.$updateCustomScrollbar=function(e){var t=this;this.$horizScroll=this.$vScroll=null,this.scrollBarV.element.remove(),this.scrollBarH.element.remove(),this.$scrollDecorator&&delete this.$scrollDecorator,!0===e?(this.scrollBarV=new p(this.container,this),this.scrollBarH=new d(this.container,this),this.scrollBarV.setHeight(this.$size.scrollerHeight),this.scrollBarH.setWidth(this.$size.scrollerWidth),this.scrollBarV.addEventListener("scroll",(function(e){t.$scrollAnimation||t.session.setScrollTop(e.data-t.scrollMargin.top)})),this.scrollBarH.addEventListener("scroll",(function(e){t.$scrollAnimation||t.session.setScrollLeft(e.data-t.scrollMargin.left)})),this.$scrollDecorator=new w(this.scrollBarV,this),this.$scrollDecorator.$updateDecorators()):(this.scrollBarV=new f(this.container,this),this.scrollBarH=new h(this.container,this),this.scrollBarV.addEventListener("scroll",(function(e){t.$scrollAnimation||t.session.setScrollTop(e.data-t.scrollMargin.top)})),this.scrollBarH.addEventListener("scroll",(function(e){t.$scrollAnimation||t.session.setScrollLeft(e.data-t.scrollMargin.left)})))},e.prototype.$addResizeObserver=function(){if(window.ResizeObserver&&!this.$resizeObserver){var e=this;this.$resizeTimer=o.delayedCall((function(){e.destroyed||e.onResize()}),50),this.$resizeObserver=new window.ResizeObserver((function(t){var n=t[0].contentRect.width,r=t[0].contentRect.height;Math.abs(e.$size.width-n)>1||Math.abs(e.$size.height-r)>1?e.$resizeTimer.delay():e.$resizeTimer.cancel()})),this.$resizeObserver.observe(this.container)}},e}();x.prototype.CHANGE_CURSOR=1,x.prototype.CHANGE_MARKER=2,x.prototype.CHANGE_GUTTER=4,x.prototype.CHANGE_SCROLL=8,x.prototype.CHANGE_LINES=16,x.prototype.CHANGE_TEXT=32,x.prototype.CHANGE_SIZE=64,x.prototype.CHANGE_MARKER_BACK=128,x.prototype.CHANGE_MARKER_FRONT=256,x.prototype.CHANGE_FULL=512,x.prototype.CHANGE_H_SCROLL=1024,x.prototype.$changes=0,x.prototype.$padding=null,x.prototype.$frozen=!1,x.prototype.STEPS=8,r.implement(x.prototype,v),s.defineOptions(x.prototype,"renderer",{useResizeObserver:{set:function(e){!e&&this.$resizeObserver?(this.$resizeObserver.disconnect(),this.$resizeTimer.cancel(),this.$resizeTimer=this.$resizeObserver=null):e&&!this.$resizeObserver&&this.$addResizeObserver()}},animatedScroll:{initialValue:!1},showInvisibles:{set:function(e){this.$textLayer.setShowInvisibles(e)&&this.$loop.schedule(this.CHANGE_TEXT)},initialValue:!1},showPrintMargin:{set:function(){this.$updatePrintMargin()},initialValue:!0},printMarginColumn:{set:function(){this.$updatePrintMargin()},initialValue:80},printMargin:{set:function(e){"number"==typeof e&&(this.$printMarginColumn=e),this.$showPrintMargin=!!e,this.$updatePrintMargin()},get:function(){return this.$showPrintMargin&&this.$printMarginColumn}},showGutter:{set:function(e){this.$gutter.style.display=e?"block":"none",this.$loop.schedule(this.CHANGE_FULL),this.onGutterResize()},initialValue:!0},useSvgGutterIcons:{set:function(e){this.$gutterLayer.$useSvgGutterIcons=e},initialValue:!1},fadeFoldWidgets:{set:function(e){i.setCssClass(this.$gutter,"ace_fade-fold-widgets",e)},initialValue:!1},showFoldWidgets:{set:function(e){this.$gutterLayer.setShowFoldWidgets(e),this.$loop.schedule(this.CHANGE_GUTTER)},initialValue:!0},displayIndentGuides:{set:function(e){this.$textLayer.setDisplayIndentGuides(e)&&this.$loop.schedule(this.CHANGE_TEXT)},initialValue:!0},highlightIndentGuides:{set:function(e){1==this.$textLayer.setHighlightIndentGuides(e)?this.$textLayer.$highlightIndentGuide():this.$textLayer.$clearActiveIndentGuide(this.$textLayer.$lines.cells)},initialValue:!0},highlightGutterLine:{set:function(e){this.$gutterLayer.setHighlightGutterLine(e),this.$loop.schedule(this.CHANGE_GUTTER)},initialValue:!0},hScrollBarAlwaysVisible:{set:function(e){this.$hScrollBarAlwaysVisible&&this.$horizScroll||this.$loop.schedule(this.CHANGE_SCROLL)},initialValue:!1},vScrollBarAlwaysVisible:{set:function(e){this.$vScrollBarAlwaysVisible&&this.$vScroll||this.$loop.schedule(this.CHANGE_SCROLL)},initialValue:!1},fontSize:{set:function(e){"number"==typeof e&&(e+="px"),this.container.style.fontSize=e,this.updateFontSize()},initialValue:12},fontFamily:{set:function(e){this.container.style.fontFamily=e,this.updateFontSize()}},maxLines:{set:function(e){this.updateFull()}},minLines:{set:function(e){this.$minLines<562949953421311||(this.$minLines=0),this.updateFull()}},maxPixelHeight:{set:function(e){this.updateFull()},initialValue:0},scrollPastEnd:{set:function(e){e=+e||0,this.$scrollPastEnd!=e&&(this.$scrollPastEnd=e,this.$loop.schedule(this.CHANGE_SCROLL))},initialValue:0,handlesSet:!0},fixedWidthGutter:{set:function(e){this.$gutterLayer.$fixedWidth=!!e,this.$loop.schedule(this.CHANGE_GUTTER)}},customScrollbar:{set:function(e){this.$updateCustomScrollbar(e)},initialValue:!1},theme:{set:function(e){this.setTheme(e)},get:function(){return this.$themeId||this.theme},initialValue:"./theme/textmate",handlesSet:!0},hasCssTransforms:{},useTextareaForIME:{initialValue:!b.isMobile&&!b.isIE}}),t.VirtualRenderer=x})),ace.define("ace/worker/worker_client",["require","exports","module","ace/lib/oop","ace/lib/net","ace/lib/event_emitter","ace/config"],(function(e,t,n){"use strict";var r=e("../lib/oop"),i=e("../lib/net"),o=e("../lib/event_emitter").EventEmitter,s=e("../config");function a(e){var t="importScripts('"+i.qualifyURL(e)+"');";try{return new Blob([t],{type:"application/javascript"})}catch(o){var n=window.BlobBuilder||window.WebKitBlobBuilder||window.MozBlobBuilder,r=new n;return r.append(t),r.getBlob("application/javascript")}}function l(e){if("undefined"==typeof Worker)return{postMessage:function(){},terminate:function(){}};if(s.get("loadWorkerFromBlob")){var t=a(e),n=window.URL||window.webkitURL,r=n.createObjectURL(t);return new Worker(r)}return new Worker(e)}var c=function(e){e.postMessage||(e=this.$createWorkerFromOldConfig.apply(this,arguments)),this.$worker=e,this.$sendDeltaQueue=this.$sendDeltaQueue.bind(this),this.changeListener=this.changeListener.bind(this),this.onMessage=this.onMessage.bind(this),this.callbackId=1,this.callbacks={},this.$worker.onmessage=this.onMessage};(function(){r.implement(this,o),this.$createWorkerFromOldConfig=function(t,n,r,i,o){if(e.nameToUrl&&!e.toUrl&&(e.toUrl=e.nameToUrl),s.get("packaged")||!e.toUrl)i=i||s.moduleUrl(n,"worker");else{var a=this.$normalizePath;i=i||a(e.toUrl("ace/worker/worker.js",null,"_"));var c={};t.forEach((function(t){c[t]=a(e.toUrl(t,null,"_").replace(/(\.js)?(\?.*)?$/,""))}))}return this.$worker=l(i),o&&this.send("importScripts",o),this.$worker.postMessage({init:!0,tlns:c,module:n,classname:r}),this.$worker},this.onMessage=function(e){var t=e.data;switch(t.type){case"event":this._signal(t.name,{data:t.data});break;case"call":var n=this.callbacks[t.id];n&&(n(t.data),delete this.callbacks[t.id]);break;case"error":this.reportError(t.data);break;case"log":window.console&&console.log&&console.log.apply(console,t.data);break}},this.reportError=function(e){window.console&&console.error&&console.error(e)},this.$normalizePath=function(e){return i.qualifyURL(e)},this.terminate=function(){this._signal("terminate",{}),this.deltaQueue=null,this.$worker.terminate(),this.$worker=null,this.$doc&&this.$doc.off("change",this.changeListener),this.$doc=null},this.send=function(e,t){this.$worker.postMessage({command:e,args:t})},this.call=function(e,t,n){if(n){var r=this.callbackId++;this.callbacks[r]=n,t.push(r)}this.send(e,t)},this.emit=function(e,t){try{t.data&&t.data.err&&(t.data.err={message:t.data.err.message,stack:t.data.err.stack,code:t.data.err.code}),this.$worker&&this.$worker.postMessage({event:e,data:{data:t.data}})}catch(n){console.error(n.stack)}},this.attachToDocument=function(e){this.$doc&&this.terminate(),this.$doc=e,this.call("setValue",[e.getValue()]),e.on("change",this.changeListener,!0)},this.changeListener=function(e){this.deltaQueue||(this.deltaQueue=[],setTimeout(this.$sendDeltaQueue,0)),"insert"==e.action?this.deltaQueue.push(e.start,e.lines):this.deltaQueue.push(e.start,e.end)},this.$sendDeltaQueue=function(){var e=this.deltaQueue;e&&(this.deltaQueue=null,e.length>50&&e.length>this.$doc.getLength()>>1?this.call("setValue",[this.$doc.getValue()]):this.emit("change",{data:e}))}}).call(c.prototype);var u=function(e,t,n){var r=null,i=!1,a=Object.create(o),l=[],u=new c({messageBuffer:l,terminate:function(){},postMessage:function(e){l.push(e),r&&(i?setTimeout(h):h())}});u.setEmitSync=function(e){i=e};var h=function(){var e=l.shift();e.command?r[e.command].apply(r,e.args):e.event&&a._signal(e.event,e.data)};return a.postMessage=function(e){u.onMessage({data:e})},a.callback=function(e,t){this.postMessage({type:"call",id:t,data:e})},a.emit=function(e,t){this.postMessage({type:"event",name:e,data:t})},s.loadModule(["worker",t],(function(e){r=new e[n](a);while(l.length)h()})),u};t.UIWorkerClient=u,t.WorkerClient=c,t.createWorker=l})),ace.define("ace/placeholder",["require","exports","module","ace/range","ace/lib/event_emitter","ace/lib/oop"],(function(e,t,n){"use strict";var r=e("./range").Range,i=e("./lib/event_emitter").EventEmitter,o=e("./lib/oop"),s=function(){function e(e,t,n,r,i,o){var s=this;this.length=t,this.session=e,this.doc=e.getDocument(),this.mainClass=i,this.othersClass=o,this.$onUpdate=this.onUpdate.bind(this),this.doc.on("change",this.$onUpdate,!0),this.$others=r,this.$onCursorChange=function(){setTimeout((function(){s.onCursorChange()}))},this.$pos=n;var a=e.getUndoManager().$undoStack||e.getUndoManager().$undostack||{length:-1};this.$undoStackDepth=a.length,this.setup(),e.selection.on("changeCursor",this.$onCursorChange)}return e.prototype.setup=function(){var e=this,t=this.doc,n=this.session;this.selectionBefore=n.selection.toJSON(),n.selection.inMultiSelectMode&&n.selection.toSingleRange(),this.pos=t.createAnchor(this.$pos.row,this.$pos.column);var i=this.pos;i.$insertRight=!0,i.detach(),i.markerId=n.addMarker(new r(i.row,i.column,i.row,i.column+this.length),this.mainClass,null,!1),this.others=[],this.$others.forEach((function(n){var r=t.createAnchor(n.row,n.column);r.$insertRight=!0,r.detach(),e.others.push(r)})),n.setUndoSelect(!1)},e.prototype.showOtherMarkers=function(){if(!this.othersActive){var e=this.session,t=this;this.othersActive=!0,this.others.forEach((function(n){n.markerId=e.addMarker(new r(n.row,n.column,n.row,n.column+t.length),t.othersClass,null,!1)}))}},e.prototype.hideOtherMarkers=function(){if(this.othersActive){this.othersActive=!1;for(var e=0;e<this.others.length;e++)this.session.removeMarker(this.others[e].markerId)}},e.prototype.onUpdate=function(e){if(this.$updating)return this.updateAnchors(e);var t=e;if(t.start.row===t.end.row&&t.start.row===this.pos.row){this.$updating=!0;var n="insert"===e.action?t.end.column-t.start.column:t.start.column-t.end.column,i=t.start.column>=this.pos.column&&t.start.column<=this.pos.column+this.length+1,o=t.start.column-this.pos.column;if(this.updateAnchors(e),i&&(this.length+=n),i&&!this.session.$fromUndo)if("insert"===e.action)for(var s=this.others.length-1;s>=0;s--){var a=this.others[s],l={row:a.row,column:a.column+o};this.doc.insertMergedLines(l,e.lines)}else if("remove"===e.action)for(s=this.others.length-1;s>=0;s--){a=this.others[s],l={row:a.row,column:a.column+o};this.doc.remove(new r(l.row,l.column,l.row,l.column-n))}this.$updating=!1,this.updateMarkers()}},e.prototype.updateAnchors=function(e){this.pos.onChange(e);for(var t=this.others.length;t--;)this.others[t].onChange(e);this.updateMarkers()},e.prototype.updateMarkers=function(){if(!this.$updating){var e=this,t=this.session,n=function(n,i){t.removeMarker(n.markerId),n.markerId=t.addMarker(new r(n.row,n.column,n.row,n.column+e.length),i,null,!1)};n(this.pos,this.mainClass);for(var i=this.others.length;i--;)n(this.others[i],this.othersClass)}},e.prototype.onCursorChange=function(e){if(!this.$updating&&this.session){var t=this.session.selection.getCursor();t.row===this.pos.row&&t.column>=this.pos.column&&t.column<=this.pos.column+this.length?(this.showOtherMarkers(),this._emit("cursorEnter",e)):(this.hideOtherMarkers(),this._emit("cursorLeave",e))}},e.prototype.detach=function(){this.session.removeMarker(this.pos&&this.pos.markerId),this.hideOtherMarkers(),this.doc.off("change",this.$onUpdate),this.session.selection.off("changeCursor",this.$onCursorChange),this.session.setUndoSelect(!0),this.session=null},e.prototype.cancel=function(){if(-1!==this.$undoStackDepth){for(var e=this.session.getUndoManager(),t=(e.$undoStack||e.$undostack).length-this.$undoStackDepth,n=0;n<t;n++)e.undo(this.session,!0);this.selectionBefore&&this.session.selection.fromJSON(this.selectionBefore)}},e}();o.implement(s.prototype,i),t.PlaceHolder=s})),ace.define("ace/mouse/multi_select_handler",["require","exports","module","ace/lib/event","ace/lib/useragent"],(function(e,t,n){var r=e("../lib/event"),i=e("../lib/useragent");function o(e,t){return e.row==t.row&&e.column==t.column}function s(e){var t=e.domEvent,n=t.altKey,s=t.shiftKey,a=t.ctrlKey,l=e.getAccelKey(),c=e.getButton();if(a&&i.isMac&&(c=t.button),e.editor.inMultiSelectMode&&2==c)e.editor.textInput.onContextMenu(e.domEvent);else if(a||n||l){if(0===c){var u,h=e.editor,f=h.selection,d=h.inMultiSelectMode,p=e.getDocumentPosition(),g=f.getCursor(),m=e.inSelection()||f.isEmpty()&&o(p,g),v=e.x,y=e.y,w=function(e){v=e.clientX,y=e.clientY},b=h.session,x=h.renderer.pixelToScreenCoordinates(v,y),S=x;if(h.$mouseHandler.$enableJumpToDef)a&&n||l&&n?u=s?"block":"add":n&&h.$blockSelectEnabled&&(u="block");else if(l&&!n){if(u="add",!d&&s)return}else n&&h.$blockSelectEnabled&&(u="block");if(u&&i.isMac&&t.ctrlKey&&h.$mouseHandler.cancelContextMenu(),"add"==u){if(!d&&m)return;if(!d){var _=f.toOrientedRange();h.addSelectionMarker(_)}var k=f.rangeList.rangeAtPoint(p);h.inVirtualSelectionMode=!0,s&&(k=null,_=f.ranges[0]||_,h.removeSelectionMarker(_)),h.once("mouseup",(function(){var e=f.toOrientedRange();k&&e.isEmpty()&&o(k.cursor,e.cursor)?f.substractPoint(e.cursor):(s?f.substractPoint(_.cursor):_&&(h.removeSelectionMarker(_),f.addRange(_)),f.addRange(e)),h.inVirtualSelectionMode=!1}))}else if("block"==u){var C;e.stop(),h.inVirtualSelectionMode=!0;var $=[],A=function(){var e=h.renderer.pixelToScreenCoordinates(v,y),t=b.screenToDocumentPosition(e.row,e.column,e.offsetX);o(S,e)&&o(t,f.lead)||(S=e,h.selection.moveToPosition(t),h.renderer.scrollCursorIntoView(),h.removeSelectionMarkers($),$=f.rectangularRangeBlock(S,x),h.$mouseHandler.$clickSelection&&1==$.length&&$[0].isEmpty()&&($[0]=h.$mouseHandler.$clickSelection.clone()),$.forEach(h.addSelectionMarker,h),h.updateSelectionMarkers())};d&&!l?f.toSingleRange():!d&&l&&(C=f.toOrientedRange(),h.addSelectionMarker(C)),s?x=b.documentToScreenPosition(f.lead):f.moveToPosition(p),S={row:-1,column:-1};var R=function(e){A(),clearInterval(E),h.removeSelectionMarkers($),$.length||($=[f.toOrientedRange()]),C&&(h.removeSelectionMarker(C),f.toSingleRange(C));for(var t=0;t<$.length;t++)f.addRange($[t]);h.inVirtualSelectionMode=!1,h.$mouseHandler.$clickSelection=null},T=A;r.capture(h.container,w,R);var E=setInterval((function(){T()}),20);return e.preventDefault()}}}else 0===c&&e.editor.inMultiSelectMode&&e.editor.exitMultiSelectMode()}t.onMouseDown=s})),ace.define("ace/commands/multi_select_commands",["require","exports","module","ace/keyboard/hash_handler"],(function(e,t,n){t.defaultCommands=[{name:"addCursorAbove",description:"Add cursor above",exec:function(e){e.selectMoreLines(-1)},bindKey:{win:"Ctrl-Alt-Up",mac:"Ctrl-Alt-Up"},scrollIntoView:"cursor",readOnly:!0},{name:"addCursorBelow",description:"Add cursor below",exec:function(e){e.selectMoreLines(1)},bindKey:{win:"Ctrl-Alt-Down",mac:"Ctrl-Alt-Down"},scrollIntoView:"cursor",readOnly:!0},{name:"addCursorAboveSkipCurrent",description:"Add cursor above (skip current)",exec:function(e){e.selectMoreLines(-1,!0)},bindKey:{win:"Ctrl-Alt-Shift-Up",mac:"Ctrl-Alt-Shift-Up"},scrollIntoView:"cursor",readOnly:!0},{name:"addCursorBelowSkipCurrent",description:"Add cursor below (skip current)",exec:function(e){e.selectMoreLines(1,!0)},bindKey:{win:"Ctrl-Alt-Shift-Down",mac:"Ctrl-Alt-Shift-Down"},scrollIntoView:"cursor",readOnly:!0},{name:"selectMoreBefore",description:"Select more before",exec:function(e){e.selectMore(-1)},bindKey:{win:"Ctrl-Alt-Left",mac:"Ctrl-Alt-Left"},scrollIntoView:"cursor",readOnly:!0},{name:"selectMoreAfter",description:"Select more after",exec:function(e){e.selectMore(1)},bindKey:{win:"Ctrl-Alt-Right",mac:"Ctrl-Alt-Right"},scrollIntoView:"cursor",readOnly:!0},{name:"selectNextBefore",description:"Select next before",exec:function(e){e.selectMore(-1,!0)},bindKey:{win:"Ctrl-Alt-Shift-Left",mac:"Ctrl-Alt-Shift-Left"},scrollIntoView:"cursor",readOnly:!0},{name:"selectNextAfter",description:"Select next after",exec:function(e){e.selectMore(1,!0)},bindKey:{win:"Ctrl-Alt-Shift-Right",mac:"Ctrl-Alt-Shift-Right"},scrollIntoView:"cursor",readOnly:!0},{name:"toggleSplitSelectionIntoLines",description:"Split selection into lines",exec:function(e){e.multiSelect.rangeCount>1?e.multiSelect.joinSelections():e.multiSelect.splitIntoLines()},bindKey:{win:"Ctrl-Alt-L",mac:"Ctrl-Alt-L"},readOnly:!0},{name:"splitSelectionIntoLines",description:"Split into lines",exec:function(e){e.multiSelect.splitIntoLines()},readOnly:!0},{name:"alignCursors",description:"Align cursors",exec:function(e){e.alignCursors()},bindKey:{win:"Ctrl-Alt-A",mac:"Ctrl-Alt-A"},scrollIntoView:"cursor"},{name:"findAll",description:"Find all",exec:function(e){e.findAll()},bindKey:{win:"Ctrl-Alt-K",mac:"Ctrl-Alt-G"},scrollIntoView:"cursor",readOnly:!0}],t.multiSelectCommands=[{name:"singleSelection",description:"Single selection",bindKey:"esc",exec:function(e){e.exitMultiSelectMode()},scrollIntoView:"cursor",readOnly:!0,isAvailable:function(e){return e&&e.inMultiSelectMode}}];var r=e("../keyboard/hash_handler").HashHandler;t.keyboardHandler=new r(t.multiSelectCommands)})),ace.define("ace/multi_select",["require","exports","module","ace/range_list","ace/range","ace/selection","ace/mouse/multi_select_handler","ace/lib/event","ace/lib/lang","ace/commands/multi_select_commands","ace/search","ace/edit_session","ace/editor","ace/config"],(function(e,t,n){var r=e("./range_list").RangeList,i=e("./range").Range,o=e("./selection").Selection,s=e("./mouse/multi_select_handler").onMouseDown,a=e("./lib/event"),l=e("./lib/lang"),c=e("./commands/multi_select_commands");t.commands=c.defaultCommands.concat(c.multiSelectCommands);var u=e("./search").Search,h=new u;function f(e,t,n){return h.$options.wrap=!0,h.$options.needle=t,h.$options.backwards=-1==n,h.find(e)}var d=e("./edit_session").EditSession;(function(){this.getSelectionMarkers=function(){return this.$selectionMarkers}}).call(d.prototype),function(){this.ranges=null,this.rangeList=null,this.addRange=function(e,t){if(e){if(!this.inMultiSelectMode&&0===this.rangeCount){var n=this.toOrientedRange();if(this.rangeList.add(n),this.rangeList.add(e),2!=this.rangeList.ranges.length)return this.rangeList.removeAll(),t||this.fromOrientedRange(e);this.rangeList.removeAll(),this.rangeList.add(n),this.$onAddRange(n)}e.cursor||(e.cursor=e.end);var r=this.rangeList.add(e);return this.$onAddRange(e),r.length&&this.$onRemoveRange(r),this.rangeCount>1&&!this.inMultiSelectMode&&(this._signal("multiSelect"),this.inMultiSelectMode=!0,this.session.$undoSelect=!1,this.rangeList.attach(this.session)),t||this.fromOrientedRange(e)}},this.toSingleRange=function(e){e=e||this.ranges[0];var t=this.rangeList.removeAll();t.length&&this.$onRemoveRange(t),e&&this.fromOrientedRange(e)},this.substractPoint=function(e){var t=this.rangeList.substractPoint(e);if(t)return this.$onRemoveRange(t),t[0]},this.mergeOverlappingRanges=function(){var e=this.rangeList.merge();e.length&&this.$onRemoveRange(e)},this.$onAddRange=function(e){this.rangeCount=this.rangeList.ranges.length,this.ranges.unshift(e),this._signal("addRange",{range:e})},this.$onRemoveRange=function(e){if(this.rangeCount=this.rangeList.ranges.length,1==this.rangeCount&&this.inMultiSelectMode){var t=this.rangeList.ranges.pop();e.push(t),this.rangeCount=0}for(var n=e.length;n--;){var r=this.ranges.indexOf(e[n]);this.ranges.splice(r,1)}this._signal("removeRange",{ranges:e}),0===this.rangeCount&&this.inMultiSelectMode&&(this.inMultiSelectMode=!1,this._signal("singleSelect"),this.session.$undoSelect=!0,this.rangeList.detach(this.session)),t=t||this.ranges[0],t&&!t.isEqual(this.getRange())&&this.fromOrientedRange(t)},this.$initRangeList=function(){this.rangeList||(this.rangeList=new r,this.ranges=[],this.rangeCount=0)},this.getAllRanges=function(){return this.rangeCount?this.rangeList.ranges.concat():[this.getRange()]},this.splitIntoLines=function(){for(var e=this.ranges.length?this.ranges:[this.getRange()],t=[],n=0;n<e.length;n++){var r=e[n],o=r.start.row,s=r.end.row;if(o===s)t.push(r.clone());else{t.push(new i(o,r.start.column,o,this.session.getLine(o).length));while(++o<s)t.push(this.getLineRange(o,!0));t.push(new i(s,0,s,r.end.column))}0!=n||this.isBackwards()||(t=t.reverse())}this.toSingleRange();for(n=t.length;n--;)this.addRange(t[n])},this.joinSelections=function(){var e=this.rangeList.ranges,t=e[e.length-1],n=i.fromPoints(e[0].start,t.end);this.toSingleRange(),this.setSelectionRange(n,t.cursor==t.start)},this.toggleBlockSelection=function(){if(this.rangeCount>1){var e=this.rangeList.ranges,t=e[e.length-1],n=i.fromPoints(e[0].start,t.end);this.toSingleRange(),this.setSelectionRange(n,t.cursor==t.start)}else{var r=this.session.documentToScreenPosition(this.cursor),o=this.session.documentToScreenPosition(this.anchor),s=this.rectangularRangeBlock(r,o);s.forEach(this.addRange,this)}},this.rectangularRangeBlock=function(e,t,n){var r=[],o=e.column<t.column;if(o)var s=e.column,a=t.column,l=e.offsetX,c=t.offsetX;else s=t.column,a=e.column,l=t.offsetX,c=e.offsetX;var u,h=e.row<t.row;if(h)var f=e.row,d=t.row;else f=t.row,d=e.row;s<0&&(s=0),f<0&&(f=0),f==d&&(n=!0);for(var p=f;p<=d;p++){var m=i.fromPoints(this.session.screenToDocumentPosition(p,s,l),this.session.screenToDocumentPosition(p,a,c));if(m.isEmpty()){if(u&&g(m.end,u))break;u=m.end}m.cursor=o?m.start:m.end,r.push(m)}if(h&&r.reverse(),!n){var v=r.length-1;while(r[v].isEmpty()&&v>0)v--;if(v>0){var y=0;while(r[y].isEmpty())y++}for(var w=v;w>=y;w--)r[w].isEmpty()&&r.splice(w,1)}return r}}.call(o.prototype);var p=e("./editor").Editor;function g(e,t){return e.row==t.row&&e.column==t.column}function m(e){e.$multiselectOnSessionChange||(e.$onAddRange=e.$onAddRange.bind(e),e.$onRemoveRange=e.$onRemoveRange.bind(e),e.$onMultiSelect=e.$onMultiSelect.bind(e),e.$onSingleSelect=e.$onSingleSelect.bind(e),e.$multiselectOnSessionChange=t.onSessionChange.bind(e),e.$checkMultiselectChange=e.$checkMultiselectChange.bind(e),e.$multiselectOnSessionChange(e),e.on("changeSession",e.$multiselectOnSessionChange),e.on("mousedown",s),e.commands.addCommands(c.defaultCommands),v(e))}function v(e){if(e.textInput){var t=e.textInput.getElement(),n=!1;a.addListener(t,"keydown",(function(t){var i=18==t.keyCode&&!(t.ctrlKey||t.shiftKey||t.metaKey);e.$blockSelectEnabled&&i?n||(e.renderer.setMouseCursor("crosshair"),n=!0):n&&r()}),e),a.addListener(t,"keyup",r,e),a.addListener(t,"blur",r,e)}function r(t){n&&(e.renderer.setMouseCursor(""),n=!1)}}(function(){this.updateSelectionMarkers=function(){this.renderer.updateCursor(),this.renderer.updateBackMarkers()},this.addSelectionMarker=function(e){e.cursor||(e.cursor=e.end);var t=this.getSelectionStyle();return e.marker=this.session.addMarker(e,"ace_selection",t),this.session.$selectionMarkers.push(e),this.session.selectionMarkerCount=this.session.$selectionMarkers.length,e},this.removeSelectionMarker=function(e){if(e.marker){this.session.removeMarker(e.marker);var t=this.session.$selectionMarkers.indexOf(e);-1!=t&&this.session.$selectionMarkers.splice(t,1),this.session.selectionMarkerCount=this.session.$selectionMarkers.length}},this.removeSelectionMarkers=function(e){for(var t=this.session.$selectionMarkers,n=e.length;n--;){var r=e[n];if(r.marker){this.session.removeMarker(r.marker);var i=t.indexOf(r);-1!=i&&t.splice(i,1)}}this.session.selectionMarkerCount=t.length},this.$onAddRange=function(e){this.addSelectionMarker(e.range),this.renderer.updateCursor(),this.renderer.updateBackMarkers()},this.$onRemoveRange=function(e){this.removeSelectionMarkers(e.ranges),this.renderer.updateCursor(),this.renderer.updateBackMarkers()},this.$onMultiSelect=function(e){this.inMultiSelectMode||(this.inMultiSelectMode=!0,this.setStyle("ace_multiselect"),this.keyBinding.addKeyboardHandler(c.keyboardHandler),this.commands.setDefaultHandler("exec",this.$onMultiSelectExec),this.renderer.updateCursor(),this.renderer.updateBackMarkers())},this.$onSingleSelect=function(e){this.session.multiSelect.inVirtualMode||(this.inMultiSelectMode=!1,this.unsetStyle("ace_multiselect"),this.keyBinding.removeKeyboardHandler(c.keyboardHandler),this.commands.removeDefaultHandler("exec",this.$onMultiSelectExec),this.renderer.updateCursor(),this.renderer.updateBackMarkers(),this._emit("changeSelection"))},this.$onMultiSelectExec=function(e){var t=e.command,n=e.editor;if(n.multiSelect){if(t.multiSelectAction)"forEach"==t.multiSelectAction?r=n.forEachSelection(t,e.args):"forEachLine"==t.multiSelectAction?r=n.forEachSelection(t,e.args,!0):"single"==t.multiSelectAction?(n.exitMultiSelectMode(),r=t.exec(n,e.args||{})):r=t.multiSelectAction(n,e.args||{});else{var r=t.exec(n,e.args||{});n.multiSelect.addRange(n.multiSelect.toOrientedRange()),n.multiSelect.mergeOverlappingRanges()}return r}},this.forEachSelection=function(e,t,n){if(!this.inVirtualSelectionMode){var r,i=n&&n.keepOrder,s=1==n||n&&n.$byLines,a=this.session,l=this.selection,c=l.rangeList,u=(i?l:c).ranges;if(!u.length)return e.exec?e.exec(this,t||{}):e(this,t||{});var h=l._eventRegistry;l._eventRegistry={};var f=new o(a);this.inVirtualSelectionMode=!0;for(var d=u.length;d--;){if(s)while(d>0&&u[d].start.row==u[d-1].end.row)d--;f.fromOrientedRange(u[d]),f.index=d,this.selection=a.selection=f;var p=e.exec?e.exec(this,t||{}):e(this,t||{});r||void 0===p||(r=p),f.toOrientedRange(u[d])}f.detach(),this.selection=a.selection=l,this.inVirtualSelectionMode=!1,l._eventRegistry=h,l.mergeOverlappingRanges(),l.ranges[0]&&l.fromOrientedRange(l.ranges[0]);var g=this.renderer.$scrollAnimation;return this.onCursorChange(),this.onSelectionChange(),g&&g.from==g.to&&this.renderer.animateScrolling(g.from),r}},this.exitMultiSelectMode=function(){this.inMultiSelectMode&&!this.inVirtualSelectionMode&&this.multiSelect.toSingleRange()},this.getSelectedText=function(){var e="";if(this.inMultiSelectMode&&!this.inVirtualSelectionMode){for(var t=this.multiSelect.rangeList.ranges,n=[],r=0;r<t.length;r++)n.push(this.session.getTextRange(t[r]));var i=this.session.getDocument().getNewLineCharacter();e=n.join(i),e.length==(n.length-1)*i.length&&(e="")}else this.selection.isEmpty()||(e=this.session.getTextRange(this.getSelectionRange()));return e},this.$checkMultiselectChange=function(e,t){if(this.inMultiSelectMode&&!this.inVirtualSelectionMode){var n=this.multiSelect.ranges[0];if(this.multiSelect.isEmpty()&&t==this.multiSelect.anchor)return;var r=t==this.multiSelect.anchor?n.cursor==n.start?n.end:n.start:n.cursor;r.row!=t.row||this.session.$clipPositionToDocument(r.row,r.column).column!=t.column?this.multiSelect.toSingleRange(this.multiSelect.toOrientedRange()):this.multiSelect.mergeOverlappingRanges()}},this.findAll=function(e,t,n){if(t=t||{},t.needle=e||t.needle,void 0==t.needle){var r=this.selection.isEmpty()?this.selection.getWordRange():this.selection.getRange();t.needle=this.session.getTextRange(r)}this.$search.set(t);var i=this.$search.findAll(this.session);if(!i.length)return 0;var o=this.multiSelect;n||o.toSingleRange(i[0]);for(var s=i.length;s--;)o.addRange(i[s],!0);return r&&o.rangeList.rangeAtPoint(r.start)&&o.addRange(r,!0),i.length},this.selectMoreLines=function(e,t){var n=this.selection.toOrientedRange(),r=n.cursor==n.end,o=this.session.documentToScreenPosition(n.cursor);this.selection.$desiredColumn&&(o.column=this.selection.$desiredColumn);var s=this.session.screenToDocumentPosition(o.row+e,o.column);if(n.isEmpty())l=s;else var a=this.session.documentToScreenPosition(r?n.end:n.start),l=this.session.screenToDocumentPosition(a.row+e,a.column);if(r){var c=i.fromPoints(s,l);c.cursor=c.start}else{c=i.fromPoints(l,s);c.cursor=c.end}if(c.desiredColumn=o.column,this.selection.inMultiSelectMode){if(t)var u=n.cursor}else this.selection.addRange(n);this.selection.addRange(c),u&&this.selection.substractPoint(u)},this.transposeSelections=function(e){for(var t=this.session,n=t.multiSelect,r=n.ranges,i=r.length;i--;){var o=r[i];if(o.isEmpty()){var s=t.getWordRange(o.start.row,o.start.column);o.start.row=s.start.row,o.start.column=s.start.column,o.end.row=s.end.row,o.end.column=s.end.column}}n.mergeOverlappingRanges();var a=[];for(i=r.length;i--;){o=r[i];a.unshift(t.getTextRange(o))}e<0?a.unshift(a.pop()):a.push(a.shift());for(i=r.length;i--;){o=r[i],s=o.clone();t.replace(o,a[i]),o.start.row=s.start.row,o.start.column=s.start.column}n.fromOrientedRange(n.ranges[0])},this.selectMore=function(e,t,n){var r=this.session,i=r.multiSelect,o=i.toOrientedRange();if(!o.isEmpty()||(o=r.getWordRange(o.start.row,o.start.column),o.cursor=-1==e?o.start:o.end,this.multiSelect.addRange(o),!n)){var s=r.getTextRange(o),a=f(r,s,e);a&&(a.cursor=-1==e?a.start:a.end,this.session.unfold(a),this.multiSelect.addRange(a),this.renderer.scrollCursorIntoView(null,.5)),t&&this.multiSelect.substractPoint(o.cursor)}},this.alignCursors=function(){var e=this.session,t=e.multiSelect,n=t.ranges,r=-1,o=n.filter((function(e){if(e.cursor.row==r)return!0;r=e.cursor.row}));if(n.length&&o.length!=n.length-1){o.forEach((function(e){t.substractPoint(e.cursor)}));var s=0,a=1/0,c=n.map((function(t){var n=t.cursor,r=e.getLine(n.row),i=r.substr(n.column).search(/\S/g);return-1==i&&(i=0),n.column>s&&(s=n.column),i<a&&(a=i),i}));n.forEach((function(t,n){var r=t.cursor,o=s-r.column,u=c[n]-a;o>u?e.insert(r,l.stringRepeat(" ",o-u)):e.remove(new i(r.row,r.column,r.row,r.column-o+u)),t.start.column=t.end.column=s,t.start.row=t.end.row=r.row,t.cursor=t.end})),t.fromOrientedRange(n[0]),this.renderer.updateCursor(),this.renderer.updateBackMarkers()}else{var u=this.selection.getRange(),h=u.start.row,f=u.end.row,d=h==f;if(d){var p,g=this.session.getLength();do{p=this.session.getLine(f)}while(/[=:]/.test(p)&&++f<g);do{p=this.session.getLine(h)}while(/[=:]/.test(p)&&--h>0);h<0&&(h=0),f>=g&&(f=g-1)}var m=this.session.removeFullLines(h,f);m=this.$reAlignText(m,d),this.session.insert({row:h,column:0},m.join("\n")+"\n"),d||(u.start.column=0,u.end.column=m[m.length-1].length),this.selection.setRange(u)}},this.$reAlignText=function(e,t){var n,r,i,o=!0,s=!0;return e.map((function(e){var t=e.match(/(\s*)(.*?)(\s*)([=:].*)/);return t?null==n?(n=t[1].length,r=t[2].length,i=t[3].length,t):(n+r+i!=t[1].length+t[2].length+t[3].length&&(s=!1),n!=t[1].length&&(o=!1),n>t[1].length&&(n=t[1].length),r<t[2].length&&(r=t[2].length),i>t[3].length&&(i=t[3].length),t):[e]})).map(t?c:o?s?u:c:h);function a(e){return l.stringRepeat(" ",e)}function c(e){return e[2]?a(n)+e[2]+a(r-e[2].length+i)+e[4].replace(/^([=:])\s+/,"$1 "):e[0]}function u(e){return e[2]?a(n+r-e[2].length)+e[2]+a(i)+e[4].replace(/^([=:])\s+/,"$1 "):e[0]}function h(e){return e[2]?a(n)+e[2]+a(i)+e[4].replace(/^([=:])\s+/,"$1 "):e[0]}}}).call(p.prototype),t.onSessionChange=function(e){var t=e.session;t&&!t.multiSelect&&(t.$selectionMarkers=[],t.selection.$initRangeList(),t.multiSelect=t.selection),this.multiSelect=t&&t.multiSelect;var n=e.oldSession;n&&(n.multiSelect.off("addRange",this.$onAddRange),n.multiSelect.off("removeRange",this.$onRemoveRange),n.multiSelect.off("multiSelect",this.$onMultiSelect),n.multiSelect.off("singleSelect",this.$onSingleSelect),n.multiSelect.lead.off("change",this.$checkMultiselectChange),n.multiSelect.anchor.off("change",this.$checkMultiselectChange)),t&&(t.multiSelect.on("addRange",this.$onAddRange),t.multiSelect.on("removeRange",this.$onRemoveRange),t.multiSelect.on("multiSelect",this.$onMultiSelect),t.multiSelect.on("singleSelect",this.$onSingleSelect),t.multiSelect.lead.on("change",this.$checkMultiselectChange),t.multiSelect.anchor.on("change",this.$checkMultiselectChange)),t&&this.inMultiSelectMode!=t.selection.inMultiSelectMode&&(t.selection.inMultiSelectMode?this.$onMultiSelect():this.$onSingleSelect())},t.MultiSelect=m,e("./config").defineOptions(p.prototype,"editor",{enableMultiselect:{set:function(e){m(this),e?(this.on("changeSession",this.$multiselectOnSessionChange),this.on("mousedown",s)):(this.off("changeSession",this.$multiselectOnSessionChange),this.off("mousedown",s))},value:!0},enableBlockSelect:{set:function(e){this.$blockSelectEnabled=e},value:!0}})})),ace.define("ace/mode/folding/fold_mode",["require","exports","module","ace/range"],(function(e,t,n){"use strict";var r=e("../../range").Range,i=t.FoldMode=function(){};(function(){this.foldingStartMarker=null,this.foldingStopMarker=null,this.getFoldWidget=function(e,t,n){var r=e.getLine(n);return this.foldingStartMarker.test(r)?"start":"markbeginend"==t&&this.foldingStopMarker&&this.foldingStopMarker.test(r)?"end":""},this.getFoldWidgetRange=function(e,t,n){return null},this.indentationBlock=function(e,t,n){var i=/\S/,o=e.getLine(t),s=o.search(i);if(-1!=s){var a=n||o.length,l=e.getLength(),c=t,u=t;while(++t<l){var h=e.getLine(t).search(i);if(-1!=h){if(h<=s){var f=e.getTokenAt(t,0);if(!f||"string"!==f.type)break}u=t}}if(u>c){var d=e.getLine(u).length;return new r(c,a,u,d)}}},this.openingBracketBlock=function(e,t,n,i,o){var s={row:n,column:i+1},a=e.$findClosingBracket(t,s,o);if(a){var l=e.foldWidgets[a.row];return null==l&&(l=e.getFoldWidget(a.row)),"start"==l&&a.row>s.row&&(a.row--,a.column=e.getLine(a.row).length),r.fromPoints(s,a)}},this.closingBracketBlock=function(e,t,n,i,o){var s={row:n,column:i},a=e.$findOpeningBracket(t,s);if(a)return a.column++,s.column--,r.fromPoints(a,s)}}).call(i.prototype)})),ace.define("ace/ext/error_marker",["require","exports","module","ace/line_widgets","ace/lib/dom","ace/range"],(function(e,t,n){"use strict";var r=e("../line_widgets").LineWidgets,i=e("../lib/dom"),o=e("../range").Range;function s(e,t,n){var r=0,i=e.length-1;while(r<=i){var o=r+i>>1,s=n(t,e[o]);if(s>0)r=o+1;else{if(!(s<0))return o;i=o-1}}return-(r+1)}function a(e,t,n){var r=e.getAnnotations().sort(o.comparePoints);if(r.length){var i=s(r,{row:t,column:-1},o.comparePoints);i<0&&(i=-i-1),i>=r.length?i=n>0?0:r.length-1:0===i&&n<0&&(i=r.length-1);var a=r[i];if(a&&n){if(a.row===t){do{a=r[i+=n]}while(a&&a.row===t);if(!a)return r.slice()}var l=[];t=a.row;do{l[n<0?"unshift":"push"](a),a=r[i+=n]}while(a&&a.row==t);return l.length&&l}}}t.showErrorMarker=function(e,t){var n=e.session;n.widgetManager||(n.widgetManager=new r(n),n.widgetManager.attach(e));var o=e.getCursorPosition(),s=o.row,l=n.widgetManager.getWidgetsAtRow(s).filter((function(e){return"errorMarker"==e.type}))[0];l?l.destroy():s-=t;var c,u=a(n,s,t);if(u){var h=u[0];o.column=(h.pos&&"number"!=typeof h.column?h.pos.sc:h.column)||0,o.row=h.row,c=e.renderer.$gutterLayer.$annotations[o.row]}else{if(l)return;c={text:["Looks good!"],className:"ace_ok"}}e.session.unfold(o.row),e.selection.moveToPosition(o);var f={row:o.row,fixedWidth:!0,coverGutter:!0,el:i.createElement("div"),type:"errorMarker"},d=f.el.appendChild(i.createElement("div")),p=f.el.appendChild(i.createElement("div"));p.className="error_widget_arrow "+c.className;var g=e.renderer.$cursorLayer.getPixelPosition(o).left;p.style.left=g+e.renderer.gutterWidth-5+"px",f.el.className="error_widget_wrapper",d.className="error_widget "+c.className,d.innerHTML=c.text.join("<br>"),d.appendChild(i.createElement("div"));var m=function(e,t,n){if(0===t&&("esc"===n||"return"===n))return f.destroy(),{command:"null"}};f.destroy=function(){e.$mouseHandler.isMousePressed||(e.keyBinding.removeKeyboardHandler(m),n.widgetManager.removeLineWidget(f),e.off("changeSelection",f.destroy),e.off("changeSession",f.destroy),e.off("mouseup",f.destroy),e.off("change",f.destroy))},e.keyBinding.addKeyboardHandler(m),e.on("changeSelection",f.destroy),e.on("changeSession",f.destroy),e.on("mouseup",f.destroy),e.on("change",f.destroy),e.session.widgetManager.addLineWidget(f),f.el.onmousedown=e.focus.bind(e),e.renderer.scrollCursorIntoView(null,.5,{bottom:f.el.offsetHeight})},i.importCssString("\n .error_widget_wrapper {\n background: inherit;\n color: inherit;\n border:none\n }\n .error_widget {\n border-top: solid 2px;\n border-bottom: solid 2px;\n margin: 5px 0;\n padding: 10px 40px;\n white-space: pre-wrap;\n }\n .error_widget.ace_error, .error_widget_arrow.ace_error{\n border-color: #ff5a5a\n }\n .error_widget.ace_warning, .error_widget_arrow.ace_warning{\n border-color: #F1D817\n }\n .error_widget.ace_info, .error_widget_arrow.ace_info{\n border-color: #5a5a5a\n }\n .error_widget.ace_ok, .error_widget_arrow.ace_ok{\n border-color: #5aaa5a\n }\n .error_widget_arrow {\n position: absolute;\n border: solid 5px;\n border-top-color: transparent!important;\n border-right-color: transparent!important;\n border-left-color: transparent!important;\n top: -5px;\n }\n","error_marker.css",!1)})),ace.define("ace/ace",["require","exports","module","ace/lib/dom","ace/range","ace/editor","ace/edit_session","ace/undomanager","ace/virtual_renderer","ace/worker/worker_client","ace/keyboard/hash_handler","ace/placeholder","ace/multi_select","ace/mode/folding/fold_mode","ace/theme/textmate","ace/ext/error_marker","ace/config","ace/loader_build"],(function(e,t,n){"use strict";e("./loader_build")(t);var r=e("./lib/dom"),i=e("./range").Range,o=e("./editor").Editor,s=e("./edit_session").EditSession,a=e("./undomanager").UndoManager,l=e("./virtual_renderer").VirtualRenderer;e("./worker/worker_client"),e("./keyboard/hash_handler"),e("./placeholder"),e("./multi_select"),e("./mode/folding/fold_mode"),e("./theme/textmate"),e("./ext/error_marker"),t.config=e("./config"),t.edit=function(e,n){if("string"==typeof e){var i=e;if(e=document.getElementById(i),!e)throw new Error("ace.edit can't find div #"+i)}if(e&&e.env&&e.env.editor instanceof o)return e.env.editor;var s="";if(e&&/input|textarea/i.test(e.tagName)){var a=e;s=a.value,e=r.createElement("pre"),a.parentNode.replaceChild(e,a)}else e&&(s=e.textContent,e.innerHTML="");var c=t.createEditSession(s),u=new o(new l(e),c,n),h={document:c,editor:u,onResize:u.resize.bind(u,null)};return a&&(h.textarea=a),u.on("destroy",(function(){h.editor.container.env=null})),u.container.env=u.env=h,u},t.createEditSession=function(e,t){var n=new s(e,t);return n.setUndoManager(new a),n},t.Range=i,t.Editor=o,t.EditSession=s,t.UndoManager=a,t.VirtualRenderer=l,t.version=t.config.version})),function(){ace.require(["ace/ace"],(function(t){for(var n in t&&(t.config.init(!0),t.define=ace.define),window.ace||(window.ace=t),t)t.hasOwnProperty(n)&&(window.ace[n]=t[n]);window.ace["default"]=window.ace,e&&(e.exports=window.ace)}))}()},89644:function(e,t,n){e.exports=n(25644)},70353:function(e,t,n){"use strict";var r=n(93044),i=n(86955),o=n(92233),s=n(68030),a=n(97948),l=n(51875),c=n(60842),u=n(98560),h=n(21218),f=n(68047),d=n(10738);e.exports=function(e){return new Promise((function(t,n){var p,g=e.data,m=e.headers,v=e.responseType;function y(){e.cancelToken&&e.cancelToken.unsubscribe(p),e.signal&&e.signal.removeEventListener("abort",p)}r.isFormData(g)&&r.isStandardBrowserEnv()&&delete m["Content-Type"];var w=new XMLHttpRequest;if(e.auth){var b=e.auth.username||"",x=e.auth.password?unescape(encodeURIComponent(e.auth.password)):"";m.Authorization="Basic "+btoa(b+":"+x)}var S=a(e.baseURL,e.url);function _(){if(w){var r="getAllResponseHeaders"in w?l(w.getAllResponseHeaders()):null,o=v&&"text"!==v&&"json"!==v?w.response:w.responseText,s={data:o,status:w.status,statusText:w.statusText,headers:r,config:e,request:w};i((function(e){t(e),y()}),(function(e){n(e),y()}),s),w=null}}if(w.open(e.method.toUpperCase(),s(S,e.params,e.paramsSerializer),!0),w.timeout=e.timeout,"onloadend"in w?w.onloadend=_:w.onreadystatechange=function(){w&&4===w.readyState&&(0!==w.status||w.responseURL&&0===w.responseURL.indexOf("file:"))&&setTimeout(_)},w.onabort=function(){w&&(n(new h("Request aborted",h.ECONNABORTED,e,w)),w=null)},w.onerror=function(){n(new h("Network Error",h.ERR_NETWORK,e,w,w)),w=null},w.ontimeout=function(){var t=e.timeout?"timeout of "+e.timeout+"ms exceeded":"timeout exceeded",r=e.transitional||u;e.timeoutErrorMessage&&(t=e.timeoutErrorMessage),n(new h(t,r.clarifyTimeoutError?h.ETIMEDOUT:h.ECONNABORTED,e,w)),w=null},r.isStandardBrowserEnv()){var k=(e.withCredentials||c(S))&&e.xsrfCookieName?o.read(e.xsrfCookieName):void 0;k&&(m[e.xsrfHeaderName]=k)}"setRequestHeader"in w&&r.forEach(m,(function(e,t){"undefined"===typeof g&&"content-type"===t.toLowerCase()?delete m[t]:w.setRequestHeader(t,e)})),r.isUndefined(e.withCredentials)||(w.withCredentials=!!e.withCredentials),v&&"json"!==v&&(w.responseType=e.responseType),"function"===typeof e.onDownloadProgress&&w.addEventListener("progress",e.onDownloadProgress),"function"===typeof e.onUploadProgress&&w.upload&&w.upload.addEventListener("progress",e.onUploadProgress),(e.cancelToken||e.signal)&&(p=function(e){w&&(n(!e||e&&e.type?new f:e),w.abort(),w=null)},e.cancelToken&&e.cancelToken.subscribe(p),e.signal&&(e.signal.aborted?p():e.signal.addEventListener("abort",p))),g||(g=null);var C=d(S);C&&-1===["http","https","file"].indexOf(C)?n(new h("Unsupported protocol "+C+":",h.ERR_BAD_REQUEST,e)):w.send(g)}))}},25644:function(e,t,n){"use strict";var r=n(93044),i=n(73644),o=n(62215),s=n(92937),a=n(10663);function l(e){var t=new o(e),n=i(o.prototype.request,t);return r.extend(n,o.prototype,t),r.extend(n,t),n.create=function(t){return l(s(e,t))},n}var c=l(a);c.Axios=o,c.CanceledError=n(68047),c.CancelToken=n(34089),c.isCancel=n(98041),c.VERSION=n(29241).version,c.toFormData=n(49027),c.AxiosError=n(21218),c.Cancel=c.CanceledError,c.all=function(e){return Promise.all(e)},c.spread=n(70783),c.isAxiosError=n(65587),e.exports=c,e.exports["default"]=c},34089:function(e,t,n){"use strict";var r=n(68047);function i(e){if("function"!==typeof e)throw new TypeError("executor must be a function.");var t;this.promise=new Promise((function(e){t=e}));var n=this;this.promise.then((function(e){if(n._listeners){var t,r=n._listeners.length;for(t=0;t<r;t++)n._listeners[t](e);n._listeners=null}})),this.promise.then=function(e){var t,r=new Promise((function(e){n.subscribe(e),t=e})).then(e);return r.cancel=function(){n.unsubscribe(t)},r},e((function(e){n.reason||(n.reason=new r(e),t(n.reason))}))}i.prototype.throwIfRequested=function(){if(this.reason)throw this.reason},i.prototype.subscribe=function(e){this.reason?e(this.reason):this._listeners?this._listeners.push(e):this._listeners=[e]},i.prototype.unsubscribe=function(e){if(this._listeners){var t=this._listeners.indexOf(e);-1!==t&&this._listeners.splice(t,1)}},i.source=function(){var e,t=new i((function(t){e=t}));return{token:t,cancel:e}},e.exports=i},68047:function(e,t,n){"use strict";var r=n(21218),i=n(93044);function o(e){r.call(this,null==e?"canceled":e,r.ERR_CANCELED),this.name="CanceledError"}i.inherits(o,r,{__CANCEL__:!0}),e.exports=o},98041:function(e){"use strict";e.exports=function(e){return!(!e||!e.__CANCEL__)}},62215:function(e,t,n){"use strict";var r=n(93044),i=n(68030),o=n(946),s=n(6895),a=n(92937),l=n(97948),c=n(23455),u=c.validators;function h(e){this.defaults=e,this.interceptors={request:new o,response:new o}}h.prototype.request=function(e,t){"string"===typeof e?(t=t||{},t.url=e):t=e||{},t=a(this.defaults,t),t.method?t.method=t.method.toLowerCase():this.defaults.method?t.method=this.defaults.method.toLowerCase():t.method="get";var n=t.transitional;void 0!==n&&c.assertOptions(n,{silentJSONParsing:u.transitional(u.boolean),forcedJSONParsing:u.transitional(u.boolean),clarifyTimeoutError:u.transitional(u.boolean)},!1);var r=[],i=!0;this.interceptors.request.forEach((function(e){"function"===typeof e.runWhen&&!1===e.runWhen(t)||(i=i&&e.synchronous,r.unshift(e.fulfilled,e.rejected))}));var o,l=[];if(this.interceptors.response.forEach((function(e){l.push(e.fulfilled,e.rejected)})),!i){var h=[s,void 0];Array.prototype.unshift.apply(h,r),h=h.concat(l),o=Promise.resolve(t);while(h.length)o=o.then(h.shift(),h.shift());return o}var f=t;while(r.length){var d=r.shift(),p=r.shift();try{f=d(f)}catch(g){p(g);break}}try{o=s(f)}catch(g){return Promise.reject(g)}while(l.length)o=o.then(l.shift(),l.shift());return o},h.prototype.getUri=function(e){e=a(this.defaults,e);var t=l(e.baseURL,e.url);return i(t,e.params,e.paramsSerializer)},r.forEach(["delete","get","head","options"],(function(e){h.prototype[e]=function(t,n){return this.request(a(n||{},{method:e,url:t,data:(n||{}).data}))}})),r.forEach(["post","put","patch"],(function(e){function t(t){return function(n,r,i){return this.request(a(i||{},{method:e,headers:t?{"Content-Type":"multipart/form-data"}:{},url:n,data:r}))}}h.prototype[e]=t(),h.prototype[e+"Form"]=t(!0)})),e.exports=h},21218:function(e,t,n){"use strict";var r=n(93044);function i(e,t,n,r,i){Error.call(this),this.message=e,this.name="AxiosError",t&&(this.code=t),n&&(this.config=n),r&&(this.request=r),i&&(this.response=i)}r.inherits(i,Error,{toJSON:function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:this.config,code:this.code,status:this.response&&this.response.status?this.response.status:null}}});var o=i.prototype,s={};["ERR_BAD_OPTION_VALUE","ERR_BAD_OPTION","ECONNABORTED","ETIMEDOUT","ERR_NETWORK","ERR_FR_TOO_MANY_REDIRECTS","ERR_DEPRECATED","ERR_BAD_RESPONSE","ERR_BAD_REQUEST","ERR_CANCELED"].forEach((function(e){s[e]={value:e}})),Object.defineProperties(i,s),Object.defineProperty(o,"isAxiosError",{value:!0}),i.from=function(e,t,n,s,a,l){var c=Object.create(o);return r.toFlatObject(e,c,(function(e){return e!==Error.prototype})),i.call(c,e.message,t,n,s,a),c.name=e.name,l&&Object.assign(c,l),c},e.exports=i},946:function(e,t,n){"use strict";var r=n(93044);function i(){this.handlers=[]}i.prototype.use=function(e,t,n){return this.handlers.push({fulfilled:e,rejected:t,synchronous:!!n&&n.synchronous,runWhen:n?n.runWhen:null}),this.handlers.length-1},i.prototype.eject=function(e){this.handlers[e]&&(this.handlers[e]=null)},i.prototype.forEach=function(e){r.forEach(this.handlers,(function(t){null!==t&&e(t)}))},e.exports=i},97948:function(e,t,n){"use strict";var r=n(99192),i=n(48762);e.exports=function(e,t){return e&&!r(t)?i(e,t):t}},6895:function(e,t,n){"use strict";var r=n(93044),i=n(38556),o=n(98041),s=n(10663),a=n(68047);function l(e){if(e.cancelToken&&e.cancelToken.throwIfRequested(),e.signal&&e.signal.aborted)throw new a}e.exports=function(e){l(e),e.headers=e.headers||{},e.data=i.call(e,e.data,e.headers,e.transformRequest),e.headers=r.merge(e.headers.common||{},e.headers[e.method]||{},e.headers),r.forEach(["delete","get","head","post","put","patch","common"],(function(t){delete e.headers[t]}));var t=e.adapter||s.adapter;return t(e).then((function(t){return l(e),t.data=i.call(e,t.data,t.headers,e.transformResponse),t}),(function(t){return o(t)||(l(e),t&&t.response&&(t.response.data=i.call(e,t.response.data,t.response.headers,e.transformResponse))),Promise.reject(t)}))}},92937:function(e,t,n){"use strict";var r=n(93044);e.exports=function(e,t){t=t||{};var n={};function i(e,t){return r.isPlainObject(e)&&r.isPlainObject(t)?r.merge(e,t):r.isPlainObject(t)?r.merge({},t):r.isArray(t)?t.slice():t}function o(n){return r.isUndefined(t[n])?r.isUndefined(e[n])?void 0:i(void 0,e[n]):i(e[n],t[n])}function s(e){if(!r.isUndefined(t[e]))return i(void 0,t[e])}function a(n){return r.isUndefined(t[n])?r.isUndefined(e[n])?void 0:i(void 0,e[n]):i(void 0,t[n])}function l(n){return n in t?i(e[n],t[n]):n in e?i(void 0,e[n]):void 0}var c={url:s,method:s,data:s,baseURL:a,transformRequest:a,transformResponse:a,paramsSerializer:a,timeout:a,timeoutMessage:a,withCredentials:a,adapter:a,responseType:a,xsrfCookieName:a,xsrfHeaderName:a,onUploadProgress:a,onDownloadProgress:a,decompress:a,maxContentLength:a,maxBodyLength:a,beforeRedirect:a,transport:a,httpAgent:a,httpsAgent:a,cancelToken:a,socketPath:a,responseEncoding:a,validateStatus:l};return r.forEach(Object.keys(e).concat(Object.keys(t)),(function(e){var t=c[e]||o,i=t(e);r.isUndefined(i)&&t!==l||(n[e]=i)})),n}},86955:function(e,t,n){"use strict";var r=n(21218);e.exports=function(e,t,n){var i=n.config.validateStatus;n.status&&i&&!i(n.status)?t(new r("Request failed with status code "+n.status,[r.ERR_BAD_REQUEST,r.ERR_BAD_RESPONSE][Math.floor(n.status/100)-4],n.config,n.request,n)):e(n)}},38556:function(e,t,n){"use strict";var r=n(93044),i=n(10663);e.exports=function(e,t,n){var o=this||i;return r.forEach(n,(function(n){e=n.call(o,e,t)})),e}},10663:function(e,t,n){"use strict";var r=n(93044),i=n(98868),o=n(21218),s=n(98560),a=n(49027),l={"Content-Type":"application/x-www-form-urlencoded"};function c(e,t){!r.isUndefined(e)&&r.isUndefined(e["Content-Type"])&&(e["Content-Type"]=t)}function u(){var e;return("undefined"!==typeof XMLHttpRequest||"undefined"!==typeof process&&"[object process]"===Object.prototype.toString.call(process))&&(e=n(70353)),e}function h(e,t,n){if(r.isString(e))try{return(t||JSON.parse)(e),r.trim(e)}catch(i){if("SyntaxError"!==i.name)throw i}return(n||JSON.stringify)(e)}var f={transitional:s,adapter:u(),transformRequest:[function(e,t){if(i(t,"Accept"),i(t,"Content-Type"),r.isFormData(e)||r.isArrayBuffer(e)||r.isBuffer(e)||r.isStream(e)||r.isFile(e)||r.isBlob(e))return e;if(r.isArrayBufferView(e))return e.buffer;if(r.isURLSearchParams(e))return c(t,"application/x-www-form-urlencoded;charset=utf-8"),e.toString();var n,o=r.isObject(e),s=t&&t["Content-Type"];if((n=r.isFileList(e))||o&&"multipart/form-data"===s){var l=this.env&&this.env.FormData;return a(n?{"files[]":e}:e,l&&new l)}return o||"application/json"===s?(c(t,"application/json"),h(e)):e}],transformResponse:[function(e){var t=this.transitional||f.transitional,n=t&&t.silentJSONParsing,i=t&&t.forcedJSONParsing,s=!n&&"json"===this.responseType;if(s||i&&r.isString(e)&&e.length)try{return JSON.parse(e)}catch(a){if(s){if("SyntaxError"===a.name)throw o.from(a,o.ERR_BAD_RESPONSE,this,null,this.response);throw a}}return e}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:n(84684)},validateStatus:function(e){return e>=200&&e<300},headers:{common:{Accept:"application/json, text/plain, */*"}}};r.forEach(["delete","get","head"],(function(e){f.headers[e]={}})),r.forEach(["post","put","patch"],(function(e){f.headers[e]=r.merge(l)})),e.exports=f},98560:function(e){"use strict";e.exports={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1}},29241:function(e){e.exports={version:"0.27.2"}},73644:function(e){"use strict";e.exports=function(e,t){return function(){for(var n=new Array(arguments.length),r=0;r<n.length;r++)n[r]=arguments[r];return e.apply(t,n)}}},68030:function(e,t,n){"use strict";var r=n(93044);function i(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}e.exports=function(e,t,n){if(!t)return e;var o;if(n)o=n(t);else if(r.isURLSearchParams(t))o=t.toString();else{var s=[];r.forEach(t,(function(e,t){null!==e&&"undefined"!==typeof e&&(r.isArray(e)?t+="[]":e=[e],r.forEach(e,(function(e){r.isDate(e)?e=e.toISOString():r.isObject(e)&&(e=JSON.stringify(e)),s.push(i(t)+"="+i(e))})))})),o=s.join("&")}if(o){var a=e.indexOf("#");-1!==a&&(e=e.slice(0,a)),e+=(-1===e.indexOf("?")?"?":"&")+o}return e}},48762:function(e){"use strict";e.exports=function(e,t){return t?e.replace(/\/+$/,"")+"/"+t.replace(/^\/+/,""):e}},92233:function(e,t,n){"use strict";var r=n(93044);e.exports=r.isStandardBrowserEnv()?function(){return{write:function(e,t,n,i,o,s){var a=[];a.push(e+"="+encodeURIComponent(t)),r.isNumber(n)&&a.push("expires="+new Date(n).toGMTString()),r.isString(i)&&a.push("path="+i),r.isString(o)&&a.push("domain="+o),!0===s&&a.push("secure"),document.cookie=a.join("; ")},read:function(e){var t=document.cookie.match(new RegExp("(^|;\\s*)("+e+")=([^;]*)"));return t?decodeURIComponent(t[3]):null},remove:function(e){this.write(e,"",Date.now()-864e5)}}}():function(){return{write:function(){},read:function(){return null},remove:function(){}}}()},99192:function(e){"use strict";e.exports=function(e){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(e)}},65587:function(e,t,n){"use strict";var r=n(93044);e.exports=function(e){return r.isObject(e)&&!0===e.isAxiosError}},60842:function(e,t,n){"use strict";var r=n(93044);e.exports=r.isStandardBrowserEnv()?function(){var e,t=/(msie|trident)/i.test(navigator.userAgent),n=document.createElement("a");function i(e){var r=e;return t&&(n.setAttribute("href",r),r=n.href),n.setAttribute("href",r),{href:n.href,protocol:n.protocol?n.protocol.replace(/:$/,""):"",host:n.host,search:n.search?n.search.replace(/^\?/,""):"",hash:n.hash?n.hash.replace(/^#/,""):"",hostname:n.hostname,port:n.port,pathname:"/"===n.pathname.charAt(0)?n.pathname:"/"+n.pathname}}return e=i(window.location.href),function(t){var n=r.isString(t)?i(t):t;return n.protocol===e.protocol&&n.host===e.host}}():function(){return function(){return!0}}()},98868:function(e,t,n){"use strict";var r=n(93044);e.exports=function(e,t){r.forEach(e,(function(n,r){r!==t&&r.toUpperCase()===t.toUpperCase()&&(e[t]=n,delete e[r])}))}},84684:function(e){e.exports=null},51875:function(e,t,n){"use strict";var r=n(93044),i=["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"];e.exports=function(e){var t,n,o,s={};return e?(r.forEach(e.split("\n"),(function(e){if(o=e.indexOf(":"),t=r.trim(e.substr(0,o)).toLowerCase(),n=r.trim(e.substr(o+1)),t){if(s[t]&&i.indexOf(t)>=0)return;s[t]="set-cookie"===t?(s[t]?s[t]:[]).concat([n]):s[t]?s[t]+", "+n:n}})),s):s}},10738:function(e){"use strict";e.exports=function(e){var t=/^([-+\w]{1,25})(:?\/\/|:)/.exec(e);return t&&t[1]||""}},70783:function(e){"use strict";e.exports=function(e){return function(t){return e.apply(null,t)}}},49027:function(e,t,n){"use strict";var r=n(93044);function i(e,t){t=t||new FormData;var n=[];function i(e){return null===e?"":r.isDate(e)?e.toISOString():r.isArrayBuffer(e)||r.isTypedArray(e)?"function"===typeof Blob?new Blob([e]):Buffer.from(e):e}function o(e,s){if(r.isPlainObject(e)||r.isArray(e)){if(-1!==n.indexOf(e))throw Error("Circular reference detected in "+s);n.push(e),r.forEach(e,(function(e,n){if(!r.isUndefined(e)){var a,l=s?s+"."+n:n;if(e&&!s&&"object"===typeof e)if(r.endsWith(n,"{}"))e=JSON.stringify(e);else if(r.endsWith(n,"[]")&&(a=r.toArray(e)))return void a.forEach((function(e){!r.isUndefined(e)&&t.append(l,i(e))}));o(e,l)}})),n.pop()}else t.append(s,i(e))}return o(e),t}e.exports=i},23455:function(e,t,n){"use strict";var r=n(29241).version,i=n(21218),o={};["object","boolean","number","function","string","symbol"].forEach((function(e,t){o[e]=function(n){return typeof n===e||"a"+(t<1?"n ":" ")+e}}));var s={};function a(e,t,n){if("object"!==typeof e)throw new i("options must be an object",i.ERR_BAD_OPTION_VALUE);var r=Object.keys(e),o=r.length;while(o-- >0){var s=r[o],a=t[s];if(a){var l=e[s],c=void 0===l||a(l,s,e);if(!0!==c)throw new i("option "+s+" must be "+c,i.ERR_BAD_OPTION_VALUE)}else if(!0!==n)throw new i("Unknown option "+s,i.ERR_BAD_OPTION)}}o.transitional=function(e,t,n){function o(e,t){return"[Axios v"+r+"] Transitional option '"+e+"'"+t+(n?". "+n:"")}return function(n,r,a){if(!1===e)throw new i(o(r," has been removed"+(t?" in "+t:"")),i.ERR_DEPRECATED);return t&&!s[r]&&(s[r]=!0,console.warn(o(r," has been deprecated since v"+t+" and will be removed in the near future"))),!e||e(n,r,a)}},e.exports={assertOptions:a,validators:o}},93044:function(e,t,n){"use strict";var r=n(73644),i=Object.prototype.toString,o=function(e){return function(t){var n=i.call(t);return e[n]||(e[n]=n.slice(8,-1).toLowerCase())}}(Object.create(null));function s(e){return e=e.toLowerCase(),function(t){return o(t)===e}}function a(e){return Array.isArray(e)}function l(e){return"undefined"===typeof e}function c(e){return null!==e&&!l(e)&&null!==e.constructor&&!l(e.constructor)&&"function"===typeof e.constructor.isBuffer&&e.constructor.isBuffer(e)}var u=s("ArrayBuffer");function h(e){var t;return t="undefined"!==typeof ArrayBuffer&&ArrayBuffer.isView?ArrayBuffer.isView(e):e&&e.buffer&&u(e.buffer),t}function f(e){return"string"===typeof e}function d(e){return"number"===typeof e}function p(e){return null!==e&&"object"===typeof e}function g(e){if("object"!==o(e))return!1;var t=Object.getPrototypeOf(e);return null===t||t===Object.prototype}var m=s("Date"),v=s("File"),y=s("Blob"),w=s("FileList");function b(e){return"[object Function]"===i.call(e)}function x(e){return p(e)&&b(e.pipe)}function S(e){var t="[object FormData]";return e&&("function"===typeof FormData&&e instanceof FormData||i.call(e)===t||b(e.toString)&&e.toString()===t)}var _=s("URLSearchParams");function k(e){return e.trim?e.trim():e.replace(/^\s+|\s+$/g,"")}function C(){return("undefined"===typeof navigator||"ReactNative"!==navigator.product&&"NativeScript"!==navigator.product&&"NS"!==navigator.product)&&("undefined"!==typeof window&&"undefined"!==typeof document)}function $(e,t){if(null!==e&&"undefined"!==typeof e)if("object"!==typeof e&&(e=[e]),a(e))for(var n=0,r=e.length;n<r;n++)t.call(null,e[n],n,e);else for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.call(null,e[i],i,e)}function A(){var e={};function t(t,n){g(e[n])&&g(t)?e[n]=A(e[n],t):g(t)?e[n]=A({},t):a(t)?e[n]=t.slice():e[n]=t}for(var n=0,r=arguments.length;n<r;n++)$(arguments[n],t);return e}function R(e,t,n){return $(t,(function(t,i){e[i]=n&&"function"===typeof t?r(t,n):t})),e}function T(e){return 65279===e.charCodeAt(0)&&(e=e.slice(1)),e}function E(e,t,n,r){e.prototype=Object.create(t.prototype,r),e.prototype.constructor=e,n&&Object.assign(e.prototype,n)}function L(e,t,n){var r,i,o,s={};t=t||{};do{r=Object.getOwnPropertyNames(e),i=r.length;while(i-- >0)o=r[i],s[o]||(t[o]=e[o],s[o]=!0);e=Object.getPrototypeOf(e)}while(e&&(!n||n(e,t))&&e!==Object.prototype);return t}function M(e,t,n){e=String(e),(void 0===n||n>e.length)&&(n=e.length),n-=t.length;var r=e.indexOf(t,n);return-1!==r&&r===n}function O(e){if(!e)return null;var t=e.length;if(l(t))return null;var n=new Array(t);while(t-- >0)n[t]=e[t];return n}var I=function(e){return function(t){return e&&t instanceof e}}("undefined"!==typeof Uint8Array&&Object.getPrototypeOf(Uint8Array));e.exports={isArray:a,isArrayBuffer:u,isBuffer:c,isFormData:S,isArrayBufferView:h,isString:f,isNumber:d,isObject:p,isPlainObject:g,isUndefined:l,isDate:m,isFile:v,isBlob:y,isFunction:b,isStream:x,isURLSearchParams:_,isStandardBrowserEnv:C,forEach:$,merge:A,extend:R,trim:k,stripBOM:T,inherits:E,toFlatObject:L,kindOf:o,kindOfTest:s,endsWith:M,toArray:O,isTypedArray:I,isFileList:w}},86522:function(e){e.exports=function(e,t,n,r,i){var o,s;if(void 0===r)r=0;else if(r|=0,r<0||r>=e.length)throw new RangeError("invalid lower bound");if(void 0===i)i=e.length-1;else if(i|=0,i<r||i>=e.length)throw new RangeError("invalid upper bound");while(r<=i)if(o=r+(i-r>>>1),s=+n(e[o],t,o,e),s<0)r=o+1;else{if(!(s>0))return o;i=o-1}return~r}},9772:function(e){e.exports="undefined"!=typeof ArrayBuffer&&"undefined"!=typeof DataView},9918:function(e,t,n){"use strict";var r,i,o,s=n(9772),a=n(7400),l=n(9859),c=n(26733),u=n(85052),h=n(98270),f=n(81589),d=n(59821),p=n(75762),g=n(14768),m=n(96616),v=n(91321),y=n(67567),w=n(56540),b=n(70095),x=n(81441),S=n(56407),_=S.enforce,k=S.get,C=l.Int8Array,$=C&&C.prototype,A=l.Uint8ClampedArray,R=A&&A.prototype,T=C&&y(C),E=$&&y($),L=Object.prototype,M=l.TypeError,O=b("toStringTag"),I=x("TYPED_ARRAY_TAG"),P="TypedArrayConstructor",D=s&&!!w&&"Opera"!==f(l.opera),F=!1,B={Int8Array:1,Uint8Array:1,Uint8ClampedArray:1,Int16Array:2,Uint16Array:2,Int32Array:4,Uint32Array:4,Float32Array:4,Float64Array:8},W={BigInt64Array:8,BigUint64Array:8},N=function(e){if(!u(e))return!1;var t=f(e);return"DataView"===t||h(B,t)||h(W,t)},H=function(e){var t=y(e);if(u(t)){var n=k(t);return n&&h(n,P)?n[P]:H(t)}},j=function(e){if(!u(e))return!1;var t=f(e);return h(B,t)||h(W,t)},z=function(e){if(j(e))return e;throw M("Target is not a typed array")},U=function(e){if(c(e)&&(!w||v(T,e)))return e;throw M(d(e)+" is not a typed array constructor")},V=function(e,t,n,r){if(a){if(n)for(var i in B){var o=l[i];if(o&&h(o.prototype,e))try{delete o.prototype[e]}catch(s){try{o.prototype[e]=t}catch(c){}}}E[e]&&!n||g(E,e,n?t:D&&$[e]||t,r)}},G=function(e,t,n){var r,i;if(a){if(w){if(n)for(r in B)if(i=l[r],i&&h(i,e))try{delete i[e]}catch(o){}if(T[e]&&!n)return;try{return g(T,e,n?t:D&&T[e]||t)}catch(o){}}for(r in B)i=l[r],!i||i[e]&&!n||g(i,e,t)}};for(r in B)i=l[r],o=i&&i.prototype,o?_(o)[P]=i:D=!1;for(r in W)i=l[r],o=i&&i.prototype,o&&(_(o)[P]=i);if((!D||!c(T)||T===Function.prototype)&&(T=function(){throw M("Incorrect invocation")},D))for(r in B)l[r]&&w(l[r],T);if((!D||!E||E===L)&&(E=T.prototype,D))for(r in B)l[r]&&w(l[r].prototype,E);if(D&&y(R)!==E&&w(R,E),a&&!h(E,O))for(r in F=!0,m(E,O,{configurable:!0,get:function(){return u(this)?this[I]:void 0}}),B)l[r]&&p(l[r],I,r);e.exports={NATIVE_ARRAY_BUFFER_VIEWS:D,TYPED_ARRAY_TAG:F&&I,aTypedArray:z,aTypedArrayConstructor:U,exportTypedArrayMethod:V,exportTypedArrayStaticMethod:G,getTypedArrayConstructor:H,isView:N,isTypedArray:j,TypedArray:T,TypedArrayPrototype:E}},53816:function(e,t,n){"use strict";var r=n(9859),i=n(65968),o=n(7400),s=n(9772),a=n(51805),l=n(75762),c=n(96616),u=n(8312),h=n(24229),f=n(57728),d=n(43329),p=n(34237),g=n(7331),m=n(56201),v=n(67567),y=n(56540),w=n(78151).f,b=n(97065),x=n(69794),S=n(54555),_=n(56407),k=a.PROPER,C=a.CONFIGURABLE,$="ArrayBuffer",A="DataView",R="prototype",T="Wrong length",E="Wrong index",L=_.getterFor($),M=_.getterFor(A),O=_.set,I=r[$],P=I,D=P&&P[R],F=r[A],B=F&&F[R],W=Object.prototype,N=r.Array,H=r.RangeError,j=i(b),z=i([].reverse),U=m.pack,V=m.unpack,G=function(e){return[255&e]},K=function(e){return[255&e,e>>8&255]},q=function(e){return[255&e,e>>8&255,e>>16&255,e>>24&255]},Z=function(e){return e[3]<<24|e[2]<<16|e[1]<<8|e[0]},Y=function(e){return U(e,23,4)},X=function(e){return U(e,52,8)},Q=function(e,t,n){c(e[R],t,{configurable:!0,get:function(){return n(this)[t]}})},J=function(e,t,n,r){var i=g(n),o=M(e);if(i+t>o.byteLength)throw H(E);var s=o.bytes,a=i+o.byteOffset,l=x(s,a,a+t);return r?l:z(l)},ee=function(e,t,n,r,i,o){var s=g(n),a=M(e);if(s+t>a.byteLength)throw H(E);for(var l=a.bytes,c=s+a.byteOffset,u=r(+i),h=0;h<t;h++)l[c+h]=u[o?h:t-h-1]};if(s){var te=k&&I.name!==$;if(h((function(){I(1)}))&&h((function(){new I(-1)}))&&!h((function(){return new I,new I(1.5),new I(NaN),1!=I.length||te&&!C})))te&&C&&l(I,"name",$);else{P=function(e){return f(this,D),new I(g(e))},P[R]=D;for(var ne,re=w(I),ie=0;re.length>ie;)(ne=re[ie++])in P||l(P,ne,I[ne]);D.constructor=P}y&&v(B)!==W&&y(B,W);var oe=new F(new P(2)),se=i(B.setInt8);oe.setInt8(0,2147483648),oe.setInt8(1,2147483649),!oe.getInt8(0)&&oe.getInt8(1)||u(B,{setInt8:function(e,t){se(this,e,t<<24>>24)},setUint8:function(e,t){se(this,e,t<<24>>24)}},{unsafe:!0})}else P=function(e){f(this,D);var t=g(e);O(this,{type:$,bytes:j(N(t),0),byteLength:t}),o||(this.byteLength=t,this.detached=!1)},D=P[R],F=function(e,t,n){f(this,B),f(e,D);var r=L(e),i=r.byteLength,s=d(t);if(s<0||s>i)throw H("Wrong offset");if(n=void 0===n?i-s:p(n),s+n>i)throw H(T);O(this,{type:A,buffer:e,byteLength:n,byteOffset:s,bytes:r.bytes}),o||(this.buffer=e,this.byteLength=n,this.byteOffset=s)},B=F[R],o&&(Q(P,"byteLength",L),Q(F,"buffer",M),Q(F,"byteLength",M),Q(F,"byteOffset",M)),u(B,{getInt8:function(e){return J(this,1,e)[0]<<24>>24},getUint8:function(e){return J(this,1,e)[0]},getInt16:function(e){var t=J(this,2,e,arguments.length>1?arguments[1]:void 0);return(t[1]<<8|t[0])<<16>>16},getUint16:function(e){var t=J(this,2,e,arguments.length>1?arguments[1]:void 0);return t[1]<<8|t[0]},getInt32:function(e){return Z(J(this,4,e,arguments.length>1?arguments[1]:void 0))},getUint32:function(e){return Z(J(this,4,e,arguments.length>1?arguments[1]:void 0))>>>0},getFloat32:function(e){return V(J(this,4,e,arguments.length>1?arguments[1]:void 0),23)},getFloat64:function(e){return V(J(this,8,e,arguments.length>1?arguments[1]:void 0),52)},setInt8:function(e,t){ee(this,1,e,G,t)},setUint8:function(e,t){ee(this,1,e,G,t)},setInt16:function(e,t){ee(this,2,e,K,t,arguments.length>2?arguments[2]:void 0)},setUint16:function(e,t){ee(this,2,e,K,t,arguments.length>2?arguments[2]:void 0)},setInt32:function(e,t){ee(this,4,e,q,t,arguments.length>2?arguments[2]:void 0)},setUint32:function(e,t){ee(this,4,e,q,t,arguments.length>2?arguments[2]:void 0)},setFloat32:function(e,t){ee(this,4,e,Y,t,arguments.length>2?arguments[2]:void 0)},setFloat64:function(e,t){ee(this,8,e,X,t,arguments.length>2?arguments[2]:void 0)}});S(P,$),S(F,A),e.exports={ArrayBuffer:P,DataView:F}},77154:function(e,t,n){"use strict";var r=n(92991),i=n(43231),o=n(39646),s=n(79563),a=Math.min;e.exports=[].copyWithin||function(e,t){var n=r(this),l=o(n),c=i(e,l),u=i(t,l),h=arguments.length>2?arguments[2]:void 0,f=a((void 0===h?l:i(h,l))-u,l-c),d=1;u<c&&c<u+f&&(d=-1,u+=f-1,c+=f-1);while(f-- >0)u in n?n[c]=n[u]:s(n,c),c+=d,u+=d;return n}},41253:function(e,t,n){var r=n(39646);e.exports=function(e,t){var n=0,i=r(t),o=new e(i);while(i>n)o[n]=t[n++];return o}},15439:function(e,t,n){var r=n(97636),i=n(9337),o=n(92991),s=n(39646),a=function(e){var t=1==e;return function(n,a,l){var c,u,h=o(n),f=i(h),d=r(a,l),p=s(f);while(p-- >0)if(c=f[p],u=d(c,p,h),u)switch(e){case 0:return c;case 1:return p}return t?-1:void 0}};e.exports={findLast:a(0),findLastIndex:a(1)}},86462:function(e,t,n){"use strict";var r=n(53171),i=n(10905),o=n(43329),s=n(39646),a=n(96038),l=Math.min,c=[].lastIndexOf,u=!!c&&1/[1].lastIndexOf(1,-0)<0,h=a("lastIndexOf"),f=u||!h;e.exports=f?function(e){if(u)return r(c,this,arguments)||0;var t=i(this),n=s(t),a=n-1;for(arguments.length>1&&(a=l(a,o(arguments[1]))),a<0&&(a=n+a);a>=0;a--)if(a in t&&t[a]===e)return a||0;return-1}:c},21178:function(e,t,n){var r=n(39646);e.exports=function(e,t){for(var n=r(e),i=new t(n),o=0;o<n;o++)i[o]=e[n-o-1];return i}},69647:function(e,t,n){var r=n(39646),i=n(43329),o=RangeError;e.exports=function(e,t,n,s){var a=r(e),l=i(n),c=l<0?a+l:l;if(c>=a||c<0)throw o("Incorrect index");for(var u=new t(a),h=0;h<a;h++)u[h]=h===c?s:e[h];return u}},98081:function(e,t,n){"use strict";var r=n(22391),i=n(96616),o=n(8312),s=n(97636),a=n(57728),l=n(9650),c=n(89003),u=n(12707),h=n(33684),f=n(71832),d=n(7400),p=n(95926).fastKey,g=n(56407),m=g.set,v=g.getterFor;e.exports={getConstructor:function(e,t,n,u){var h=e((function(e,i){a(e,f),m(e,{type:t,index:r(null),first:void 0,last:void 0,size:0}),d||(e.size=0),l(i)||c(i,e[u],{that:e,AS_ENTRIES:n})})),f=h.prototype,g=v(t),y=function(e,t,n){var r,i,o=g(e),s=w(e,t);return s?s.value=n:(o.last=s={index:i=p(t,!0),key:t,value:n,previous:r=o.last,next:void 0,removed:!1},o.first||(o.first=s),r&&(r.next=s),d?o.size++:e.size++,"F"!==i&&(o.index[i]=s)),e},w=function(e,t){var n,r=g(e),i=p(t);if("F"!==i)return r.index[i];for(n=r.first;n;n=n.next)if(n.key==t)return n};return o(f,{clear:function(){var e=this,t=g(e),n=t.index,r=t.first;while(r)r.removed=!0,r.previous&&(r.previous=r.previous.next=void 0),delete n[r.index],r=r.next;t.first=t.last=void 0,d?t.size=0:e.size=0},delete:function(e){var t=this,n=g(t),r=w(t,e);if(r){var i=r.next,o=r.previous;delete n.index[r.index],r.removed=!0,o&&(o.next=i),i&&(i.previous=o),n.first==r&&(n.first=i),n.last==r&&(n.last=o),d?n.size--:t.size--}return!!r},forEach:function(e){var t,n=g(this),r=s(e,arguments.length>1?arguments[1]:void 0);while(t=t?t.next:n.first){r(t.value,t.key,this);while(t&&t.removed)t=t.previous}},has:function(e){return!!w(this,e)}}),o(f,n?{get:function(e){var t=w(this,e);return t&&t.value},set:function(e,t){return y(this,0===e?0:e,t)}}:{add:function(e){return y(this,e=0===e?0:e,e)}}),d&&i(f,"size",{configurable:!0,get:function(){return g(this).size}}),h},setStrong:function(e,t,n){var r=t+" Iterator",i=v(t),o=v(r);u(e,t,(function(e,t){m(this,{type:r,target:e,state:i(e),kind:t,last:void 0})}),(function(){var e=o(this),t=e.kind,n=e.last;while(n&&n.removed)n=n.previous;return e.target&&(e.last=n=n?n.next:e.state.first)?h("keys"==t?n.key:"values"==t?n.value:[n.key,n.value],!1):(e.target=void 0,h(void 0,!0))}),n?"entries":"values",!n,!0),f(t)}}},63370:function(e,t,n){"use strict";var r=n(65968),i=n(8312),o=n(95926).getWeakData,s=n(57728),a=n(21176),l=n(9650),c=n(85052),u=n(89003),h=n(89996),f=n(98270),d=n(56407),p=d.set,g=d.getterFor,m=h.find,v=h.findIndex,y=r([].splice),w=0,b=function(e){return e.frozen||(e.frozen=new x)},x=function(){this.entries=[]},S=function(e,t){return m(e.entries,(function(e){return e[0]===t}))};x.prototype={get:function(e){var t=S(this,e);if(t)return t[1]},has:function(e){return!!S(this,e)},set:function(e,t){var n=S(this,e);n?n[1]=t:this.entries.push([e,t])},delete:function(e){var t=v(this.entries,(function(t){return t[0]===e}));return~t&&y(this.entries,t,1),!!~t}},e.exports={getConstructor:function(e,t,n,r){var h=e((function(e,i){s(e,d),p(e,{type:t,id:w++,frozen:void 0}),l(i)||u(i,e[r],{that:e,AS_ENTRIES:n})})),d=h.prototype,m=g(t),v=function(e,t,n){var r=m(e),i=o(a(t),!0);return!0===i?b(r).set(t,n):i[r.id]=n,e};return i(d,{delete:function(e){var t=m(this);if(!c(e))return!1;var n=o(e);return!0===n?b(t)["delete"](e):n&&f(n,t.id)&&delete n[t.id]},has:function(e){var t=m(this);if(!c(e))return!1;var n=o(e);return!0===n?b(t).has(e):n&&f(n,t.id)}}),i(d,n?{get:function(e){var t=m(this);if(c(e)){var n=o(e);return!0===n?b(t).get(e):n?n[t.id]:void 0}},set:function(e,t){return v(this,e,t)}}:{add:function(e){return v(this,e,!0)}}),h}}},69789:function(e,t,n){"use strict";var r=n(23103),i=n(9859),o=n(65968),s=n(46541),a=n(14768),l=n(95926),c=n(89003),u=n(57728),h=n(26733),f=n(9650),d=n(85052),p=n(24229),g=n(74575),m=n(54555),v=n(20835);e.exports=function(e,t,n){var y=-1!==e.indexOf("Map"),w=-1!==e.indexOf("Weak"),b=y?"set":"add",x=i[e],S=x&&x.prototype,_=x,k={},C=function(e){var t=o(S[e]);a(S,e,"add"==e?function(e){return t(this,0===e?0:e),this}:"delete"==e?function(e){return!(w&&!d(e))&&t(this,0===e?0:e)}:"get"==e?function(e){return w&&!d(e)?void 0:t(this,0===e?0:e)}:"has"==e?function(e){return!(w&&!d(e))&&t(this,0===e?0:e)}:function(e,n){return t(this,0===e?0:e,n),this})},$=s(e,!h(x)||!(w||S.forEach&&!p((function(){(new x).entries().next()}))));if($)_=n.getConstructor(t,e,y,b),l.enable();else if(s(e,!0)){var A=new _,R=A[b](w?{}:-0,1)!=A,T=p((function(){A.has(1)})),E=g((function(e){new x(e)})),L=!w&&p((function(){var e=new x,t=5;while(t--)e[b](t,t);return!e.has(-0)}));E||(_=t((function(e,t){u(e,S);var n=v(new x,e,_);return f(t)||c(t,n[b],{that:n,AS_ENTRIES:y}),n})),_.prototype=S,S.constructor=_),(T||L)&&(C("delete"),C("has"),y&&C("get")),(L||R)&&C(b),w&&S.clear&&delete S.clear}return k[e]=_,r({global:!0,constructor:!0,forced:_!=x},k),m(_,e),w||n.setStrong(_,e,y),_}},8312:function(e,t,n){var r=n(14768);e.exports=function(e,t,n){for(var i in t)r(e,i,t[i],n);return e}},56201:function(e){var t=Array,n=Math.abs,r=Math.pow,i=Math.floor,o=Math.log,s=Math.LN2,a=function(e,a,l){var c,u,h,f=t(l),d=8*l-a-1,p=(1<<d)-1,g=p>>1,m=23===a?r(2,-24)-r(2,-77):0,v=e<0||0===e&&1/e<0?1:0,y=0;e=n(e),e!=e||e===1/0?(u=e!=e?1:0,c=p):(c=i(o(e)/s),h=r(2,-c),e*h<1&&(c--,h*=2),e+=c+g>=1?m/h:m*r(2,1-g),e*h>=2&&(c++,h/=2),c+g>=p?(u=0,c=p):c+g>=1?(u=(e*h-1)*r(2,a),c+=g):(u=e*r(2,g-1)*r(2,a),c=0));while(a>=8)f[y++]=255&u,u/=256,a-=8;c=c<<a|u,d+=a;while(d>0)f[y++]=255&c,c/=256,d-=8;return f[--y]|=128*v,f},l=function(e,t){var n,i=e.length,o=8*i-t-1,s=(1<<o)-1,a=s>>1,l=o-7,c=i-1,u=e[c--],h=127&u;u>>=7;while(l>0)h=256*h+e[c--],l-=8;n=h&(1<<-l)-1,h>>=-l,l+=t;while(l>0)n=256*n+e[c--],l-=8;if(0===h)h=1-a;else{if(h===s)return n?NaN:u?-1/0:1/0;n+=r(2,t),h-=a}return(u?-1:1)*n*r(2,h-t)};e.exports={pack:a,unpack:l}},79098:function(e,t,n){var r=n(81589);e.exports=function(e){var t=r(e);return"BigInt64Array"==t||"BigUint64Array"==t}},82292:function(e,t,n){var r=n(85052),i=Math.floor;e.exports=Number.isInteger||function(e){return!r(e)&&isFinite(e)&&i(e)===e}},45496:function(e,t,n){var r=n(9859),i=n(24229),o=n(65968),s=n(83326),a=n(1017).trim,l=n(41647),c=o("".charAt),u=r.parseFloat,h=r.Symbol,f=h&&h.iterator,d=1/u(l+"-0")!==-1/0||f&&!i((function(){u(Object(f))}));e.exports=d?function(e){var t=a(s(e)),n=u(t);return 0===n&&"-"==c(t,0)?-0:n}:u},72101:function(e){e.exports=Object.is||function(e,t){return e===t?0!==e||1/e===1/t:e!=e&&t!=t}},57456:function(e,t,n){var r=n(80598);e.exports=/Version\/10(?:\.\d+){1,2}(?: [\w./]+)?(?: Mobile\/\w+)? Safari\//.test(r)},46650:function(e,t,n){var r=n(65968),i=n(34237),o=n(83326),s=n(93124),a=n(58885),l=r(s),c=r("".slice),u=Math.ceil,h=function(e){return function(t,n,r){var s,h,f=o(a(t)),d=i(n),p=f.length,g=void 0===r?" ":o(r);return d<=p||""==g?f:(s=d-p,h=l(g,u(s/g.length)),h.length>s&&(h=c(h,0,s)),e?f+h:h+f)}};e.exports={start:h(!1),end:h(!0)}},77321:function(e,t,n){var r=n(65968),i=2147483647,o=36,s=1,a=26,l=38,c=700,u=72,h=128,f="-",d=/[^\0-\u007E]/,p=/[.\u3002\uFF0E\uFF61]/g,g="Overflow: input needs wider integers to process",m=o-s,v=RangeError,y=r(p.exec),w=Math.floor,b=String.fromCharCode,x=r("".charCodeAt),S=r([].join),_=r([].push),k=r("".replace),C=r("".split),$=r("".toLowerCase),A=function(e){var t=[],n=0,r=e.length;while(n<r){var i=x(e,n++);if(i>=55296&&i<=56319&&n<r){var o=x(e,n++);56320==(64512&o)?_(t,((1023&i)<<10)+(1023&o)+65536):(_(t,i),n--)}else _(t,i)}return t},R=function(e){return e+22+75*(e<26)},T=function(e,t,n){var r=0;e=n?w(e/c):e>>1,e+=w(e/t);while(e>m*a>>1)e=w(e/m),r+=o;return w(r+(m+1)*e/(e+l))},E=function(e){var t=[];e=A(e);var n,r,l=e.length,c=h,d=0,p=u;for(n=0;n<e.length;n++)r=e[n],r<128&&_(t,b(r));var m=t.length,y=m;m&&_(t,f);while(y<l){var x=i;for(n=0;n<e.length;n++)r=e[n],r>=c&&r<x&&(x=r);var k=y+1;if(x-c>w((i-d)/k))throw v(g);for(d+=(x-c)*k,c=x,n=0;n<e.length;n++){if(r=e[n],r<c&&++d>i)throw v(g);if(r==c){var C=d,$=o;while(1){var E=$<=p?s:$>=p+a?a:$-p;if(C<E)break;var L=C-E,M=o-E;_(t,b(R(E+L%M))),C=w(L/M),$+=o}_(t,b(R(C))),p=T(d,k,y==m),d=0,y++}}d++,c++}return S(t,"")};e.exports=function(e){var t,n,r=[],i=C(k($(e),p,"."),".");for(t=0;t<i.length;t++)n=i[t],_(r,y(d,n)?"xn--"+E(n):n);return S(r,".")}},19123:function(e,t,n){var r=n(92066),i=TypeError;e.exports=function(e){var t=r(e,"number");if("number"==typeof t)throw i("Can't convert number to bigint");return BigInt(t)}},7331:function(e,t,n){var r=n(43329),i=n(34237),o=RangeError;e.exports=function(e){if(void 0===e)return 0;var t=r(e),n=i(t);if(t!==n)throw o("Wrong length or index");return n}},84262:function(e,t,n){var r=n(72002),i=RangeError;e.exports=function(e,t){var n=r(e);if(n%t)throw i("Wrong offset");return n}},72002:function(e,t,n){var r=n(43329),i=RangeError;e.exports=function(e){var t=r(e);if(t<0)throw i("The argument can't be less than 0");return t}},42574:function(e,t,n){"use strict";var r=n(23103),i=n(9859),o=n(20266),s=n(7400),a=n(48200),l=n(9918),c=n(53816),u=n(57728),h=n(65358),f=n(75762),d=n(82292),p=n(34237),g=n(7331),m=n(84262),v=n(39310),y=n(98270),w=n(81589),b=n(85052),x=n(49395),S=n(22391),_=n(91321),k=n(56540),C=n(78151).f,$=n(35215),A=n(89996).forEach,R=n(71832),T=n(96616),E=n(31787),L=n(97933),M=n(56407),O=n(20835),I=M.get,P=M.set,D=M.enforce,F=E.f,B=L.f,W=Math.round,N=i.RangeError,H=c.ArrayBuffer,j=H.prototype,z=c.DataView,U=l.NATIVE_ARRAY_BUFFER_VIEWS,V=l.TYPED_ARRAY_TAG,G=l.TypedArray,K=l.TypedArrayPrototype,q=l.aTypedArrayConstructor,Z=l.isTypedArray,Y="BYTES_PER_ELEMENT",X="Wrong length",Q=function(e,t){q(e);var n=0,r=t.length,i=new e(r);while(r>n)i[n]=t[n++];return i},J=function(e,t){T(e,t,{configurable:!0,get:function(){return I(this)[t]}})},ee=function(e){var t;return _(j,e)||"ArrayBuffer"==(t=w(e))||"SharedArrayBuffer"==t},te=function(e,t){return Z(e)&&!x(t)&&t in e&&d(+t)&&t>=0},ne=function(e,t){return t=v(t),te(e,t)?h(2,e[t]):B(e,t)},re=function(e,t,n){return t=v(t),!(te(e,t)&&b(n)&&y(n,"value"))||y(n,"get")||y(n,"set")||n.configurable||y(n,"writable")&&!n.writable||y(n,"enumerable")&&!n.enumerable?F(e,t,n):(e[t]=n.value,e)};s?(U||(L.f=ne,E.f=re,J(K,"buffer"),J(K,"byteOffset"),J(K,"byteLength"),J(K,"length")),r({target:"Object",stat:!0,forced:!U},{getOwnPropertyDescriptor:ne,defineProperty:re}),e.exports=function(e,t,n){var s=e.match(/\d+/)[0]/8,l=e+(n?"Clamped":"")+"Array",c="get"+e,h="set"+e,d=i[l],v=d,y=v&&v.prototype,w={},x=function(e,t){var n=I(e);return n.view[c](t*s+n.byteOffset,!0)},_=function(e,t,r){var i=I(e);n&&(r=(r=W(r))<0?0:r>255?255:255&r),i.view[h](t*s+i.byteOffset,r,!0)},T=function(e,t){F(e,t,{get:function(){return x(this,t)},set:function(e){return _(this,t,e)},enumerable:!0})};U?a&&(v=t((function(e,t,n,r){return u(e,y),O(function(){return b(t)?ee(t)?void 0!==r?new d(t,m(n,s),r):void 0!==n?new d(t,m(n,s)):new d(t):Z(t)?Q(v,t):o($,v,t):new d(g(t))}(),e,v)})),k&&k(v,G),A(C(d),(function(e){e in v||f(v,e,d[e])})),v.prototype=y):(v=t((function(e,t,n,r){u(e,y);var i,a,l,c=0,h=0;if(b(t)){if(!ee(t))return Z(t)?Q(v,t):o($,v,t);i=t,h=m(n,s);var f=t.byteLength;if(void 0===r){if(f%s)throw N(X);if(a=f-h,a<0)throw N(X)}else if(a=p(r)*s,a+h>f)throw N(X);l=a/s}else l=g(t),a=l*s,i=new H(a);P(e,{buffer:i,byteOffset:h,byteLength:a,length:l,view:new z(i)});while(c<l)T(e,c++)})),k&&k(v,G),y=v.prototype=S(K)),y.constructor!==v&&f(y,"constructor",v),D(y).TypedArrayConstructor=v,V&&f(y,V,l);var E=v!=d;w[l]=v,r({global:!0,constructor:!0,forced:E,sham:!U},w),Y in v||f(v,Y,s),Y in y||f(y,Y,s),R(l)}):e.exports=function(){}},48200:function(e,t,n){var r=n(9859),i=n(24229),o=n(74575),s=n(9918).NATIVE_ARRAY_BUFFER_VIEWS,a=r.ArrayBuffer,l=r.Int8Array;e.exports=!s||!i((function(){l(1)}))||!i((function(){new l(-1)}))||!o((function(e){new l,new l(null),new l(1.5),new l(e)}),!0)||i((function(){return 1!==new l(new a(2),1,void 0).length}))},88874:function(e,t,n){var r=n(41253),i=n(54622);e.exports=function(e,t){return r(i(e),t)}},35215:function(e,t,n){var r=n(97636),i=n(20266),o=n(57988),s=n(92991),a=n(39646),l=n(28403),c=n(78830),u=n(91943),h=n(79098),f=n(9918).aTypedArrayConstructor,d=n(19123);e.exports=function(e){var t,n,p,g,m,v,y,w,b=o(this),x=s(e),S=arguments.length,_=S>1?arguments[1]:void 0,k=void 0!==_,C=c(x);if(C&&!u(C)){y=l(x,C),w=y.next,x=[];while(!(v=i(w,y)).done)x.push(v.value)}for(k&&S>2&&(_=r(_,arguments[2])),n=a(x),p=new(f(b))(n),g=h(p),t=0;n>t;t++)m=k?_(x[t],t):x[t],p[t]=g?d(m):+m;return p}},54622:function(e,t,n){var r=n(9918),i=n(37942),o=r.aTypedArrayConstructor,s=r.getTypedArrayConstructor;e.exports=function(e){return o(i(e,s(e)))}},34144:function(e,t,n){var r=n(24229),i=n(70095),o=n(7400),s=n(24231),a=i("iterator");e.exports=!r((function(){var e=new URL("b?a=1&b=2&c=3","http://a"),t=e.searchParams,n="";return e.pathname="c%20d",t.forEach((function(e,r){t["delete"]("b"),n+=r+e})),s&&!e.toJSON||!t.size&&(s||!o)||!t.sort||"http://a/c%20d?a=1&c=3"!==e.href||"3"!==t.get("c")||"a=1"!==String(new URLSearchParams("?a=1"))||!t[a]||"a"!==new URL("https://a@b").username||"b"!==new URLSearchParams(new URLSearchParams("a=b")).get("a")||"xn--e1aybc"!==new URL("http://тест").host||"#%D0%B1"!==new URL("http://a#б").hash||"a1c3"!==n||"x"!==new URL("http://x",void 0).host}))},9949:function(e,t,n){"use strict";var r=n(23103),i=n(89996).findIndex,o=n(9736),s="findIndex",a=!0;s in[]&&Array(1)[s]((function(){a=!1})),r({target:"Array",proto:!0,forced:a},{findIndex:function(e){return i(this,e,arguments.length>1?arguments[1]:void 0)}}),o(s)},99805:function(e,t,n){"use strict";var r=n(23103),i=n(92991),o=n(43231),s=n(43329),a=n(39646),l=n(36554),c=n(13064),u=n(87501),h=n(62324),f=n(79563),d=n(31460),p=d("splice"),g=Math.max,m=Math.min;r({target:"Array",proto:!0,forced:!p},{splice:function(e,t){var n,r,d,p,v,y,w=i(this),b=a(w),x=o(e,b),S=arguments.length;for(0===S?n=r=0:1===S?(n=0,r=b-x):(n=S-2,r=m(g(s(t),0),b-x)),c(b+n-r),d=u(w,r),p=0;p<r;p++)v=x+p,v in w&&h(d,p,w[v]);if(d.length=r,n<r){for(p=x;p<b-r;p++)v=p+r,y=p+n,v in w?w[y]=w[v]:f(w,y);for(p=b;p>b-r+n;p--)f(w,p-1)}else if(n>r)for(p=b-r;p>x;p--)v=p+r-1,y=p+n-1,v in w?w[y]=w[v]:f(w,y);for(p=0;p<n;p++)w[p+x]=arguments[p+2];return l(w,b-r+n),d}})},17525:function(e,t,n){var r=n(9859),i=n(54555);i(r.JSON,"JSON",!0)},19294:function(e,t,n){"use strict";var r=n(69789),i=n(98081);r("Map",(function(e){return function(){return e(this,arguments.length?arguments[0]:void 0)}}),i)},79321:function(e,t,n){n(19294)},18275:function(e,t,n){var r=n(54555);r(Math,"Math",!0)},33132:function(e,t,n){var r=n(23103),i=n(82292);r({target:"Number",stat:!0},{isInteger:i})},35883:function(e,t,n){var r=n(23103),i=n(87664).entries;r({target:"Object",stat:!0},{entries:function(e){return i(e)}})},24905:function(e,t,n){var r=n(23103),i=n(24229),o=n(10166).f,s=i((function(){return!Object.getOwnPropertyNames(1)}));r({target:"Object",stat:!0,forced:s},{getOwnPropertyNames:o})},13489:function(e,t,n){var r=n(23103),i=n(45496);r({global:!0,forced:parseFloat!=i},{parseFloat:i})},17368:function(e,t,n){var r=n(7400),i=n(9859),o=n(65968),s=n(46541),a=n(20835),l=n(75762),c=n(78151).f,u=n(91321),h=n(48311),f=n(83326),d=n(83349),p=n(25650),g=n(26060),m=n(14768),v=n(24229),y=n(98270),w=n(56407).enforce,b=n(71832),x=n(70095),S=n(42926),_=n(10461),k=x("match"),C=i.RegExp,$=C.prototype,A=i.SyntaxError,R=o($.exec),T=o("".charAt),E=o("".replace),L=o("".indexOf),M=o("".slice),O=/^\?<[^\s\d!#%&*+<=>@^][^\s!#%&*+<=>@^]*>/,I=/a/g,P=/a/g,D=new C(I)!==I,F=p.MISSED_STICKY,B=p.UNSUPPORTED_Y,W=r&&(!D||F||S||_||v((function(){return P[k]=!1,C(I)!=I||C(P)==P||"/a/i"!=C(I,"i")}))),N=function(e){for(var t,n=e.length,r=0,i="",o=!1;r<=n;r++)t=T(e,r),"\\"!==t?o||"."!==t?("["===t?o=!0:"]"===t&&(o=!1),i+=t):i+="[\\s\\S]":i+=t+T(e,++r);return i},H=function(e){for(var t,n=e.length,r=0,i="",o=[],s={},a=!1,l=!1,c=0,u="";r<=n;r++){if(t=T(e,r),"\\"===t)t+=T(e,++r);else if("]"===t)a=!1;else if(!a)switch(!0){case"["===t:a=!0;break;case"("===t:R(O,M(e,r+1))&&(r+=2,l=!0),i+=t,c++;continue;case">"===t&&l:if(""===u||y(s,u))throw new A("Invalid capture group name");s[u]=!0,o[o.length]=[u,c],l=!1,u="";continue}l?u+=t:i+=t}return[i,o]};if(s("RegExp",W)){for(var j=function(e,t){var n,r,i,o,s,c,p=u($,this),g=h(e),m=void 0===t,v=[],y=e;if(!p&&g&&m&&e.constructor===j)return e;if((g||u($,e))&&(e=e.source,m&&(t=d(y))),e=void 0===e?"":f(e),t=void 0===t?"":f(t),y=e,S&&"dotAll"in I&&(r=!!t&&L(t,"s")>-1,r&&(t=E(t,/s/g,""))),n=t,F&&"sticky"in I&&(i=!!t&&L(t,"y")>-1,i&&B&&(t=E(t,/y/g,""))),_&&(o=H(e),e=o[0],v=o[1]),s=a(C(e,t),p?this:$,j),(r||i||v.length)&&(c=w(s),r&&(c.dotAll=!0,c.raw=j(N(e),n)),i&&(c.sticky=!0),v.length&&(c.groups=v)),e!==y)try{l(s,"source",""===y?"(?:)":y)}catch(b){}return s},z=c(C),U=0;z.length>U;)g(j,C,z[U++]);$.constructor=j,j.prototype=$,m(i,"RegExp",j,{constructor:!0})}b("RegExp")},24471:function(e,t,n){var r=n(7400),i=n(42926),o=n(27079),s=n(96616),a=n(56407).get,l=RegExp.prototype,c=TypeError;r&&i&&s(l,"dotAll",{configurable:!0,get:function(){if(this!==l){if("RegExp"===o(this))return!!a(this).dotAll;throw c("Incompatible receiver, RegExp required")}}})},51172:function(e,t,n){var r=n(7400),i=n(25650).MISSED_STICKY,o=n(27079),s=n(96616),a=n(56407).get,l=RegExp.prototype,c=TypeError;r&&i&&s(l,"sticky",{configurable:!0,get:function(){if(this!==l){if("RegExp"===o(this))return!!a(this).sticky;throw c("Incompatible receiver, RegExp required")}}})},72560:function(e,t,n){"use strict";var r=n(69789),i=n(98081);r("Set",(function(e){return function(){return e(this,arguments.length?arguments[0]:void 0)}}),i)},93244:function(e,t,n){n(72560)},96708:function(e,t,n){"use strict";var r=n(23103),i=n(44745),o=n(97933).f,s=n(34237),a=n(83326),l=n(47272),c=n(58885),u=n(48127),h=n(24231),f=i("".endsWith),d=i("".slice),p=Math.min,g=u("endsWith"),m=!h&&!g&&!!function(){var e=o(String.prototype,"endsWith");return e&&!e.writable}();r({target:"String",proto:!0,forced:!m&&!g},{endsWith:function(e){var t=a(c(this));l(e);var n=arguments.length>1?arguments[1]:void 0,r=t.length,i=void 0===n?r:p(s(n),r),o=a(e);return f?f(t,o,i):d(t,i-o.length,i)===o}})},35734:function(e,t,n){"use strict";var r=n(23103),i=n(46650).start,o=n(57456);r({target:"String",proto:!0,forced:o},{padStart:function(e){return i(this,e,arguments.length>1?arguments[1]:void 0)}})},71639:function(e,t,n){"use strict";var r=n(23103),i=n(20266),o=n(65968),s=n(58885),a=n(26733),l=n(9650),c=n(48311),u=n(83326),h=n(55300),f=n(83349),d=n(70017),p=n(70095),g=n(24231),m=p("replace"),v=TypeError,y=o("".indexOf),w=o("".replace),b=o("".slice),x=Math.max,S=function(e,t,n){return n>e.length?-1:""===t?n:y(e,t,n)};r({target:"String",proto:!0},{replaceAll:function(e,t){var n,r,o,p,_,k,C,$,A,R=s(this),T=0,E=0,L="";if(!l(e)){if(n=c(e),n&&(r=u(s(f(e))),!~y(r,"g")))throw v("`.replaceAll` does not allow non-global regexes");if(o=h(e,m),o)return i(o,e,R,t);if(g&&n)return w(u(R),e,t)}p=u(R),_=u(e),k=a(t),k||(t=u(t)),C=_.length,$=x(1,C),T=S(p,_,0);while(-1!==T)A=k?u(t(_,T,p)):d(_,p,T,[],void 0,t),L+=b(p,E,T)+A,E=T+C,T=S(p,_,T+$);return E<p.length&&(L+=b(p,E)),L}})},94908:function(e,t,n){"use strict";var r=n(20266),i=n(94954),o=n(21176),s=n(9650),a=n(58885),l=n(72101),c=n(83326),u=n(55300),h=n(98115);i("search",(function(e,t,n){return[function(t){var n=a(this),i=s(t)?void 0:u(t,e);return i?r(i,t,n):new RegExp(t)[e](c(n))},function(e){var r=o(this),i=c(e),s=n(t,r,i);if(s.done)return s.value;var a=r.lastIndex;l(a,0)||(r.lastIndex=0);var u=h(r,i);return l(r.lastIndex,a)||(r.lastIndex=a),null===u?-1:u.index}]}))},96882:function(e,t,n){var r=n(63524);r("asyncIterator")},38859:function(e,t,n){var r=n(31333),i=n(63524),o=n(54555);i("toStringTag"),o(r("Symbol"),"Symbol")},94898:function(e,t,n){"use strict";var r=n(9918),i=n(39646),o=n(43329),s=r.aTypedArray,a=r.exportTypedArrayMethod;a("at",(function(e){var t=s(this),n=i(t),r=o(e),a=r>=0?r:n+r;return a<0||a>=n?void 0:t[a]}))},5825:function(e,t,n){"use strict";var r=n(65968),i=n(9918),o=n(77154),s=r(o),a=i.aTypedArray,l=i.exportTypedArrayMethod;l("copyWithin",(function(e,t){return s(a(this),e,t,arguments.length>2?arguments[2]:void 0)}))},67170:function(e,t,n){"use strict";var r=n(9918),i=n(89996).every,o=r.aTypedArray,s=r.exportTypedArrayMethod;s("every",(function(e){return i(o(this),e,arguments.length>1?arguments[1]:void 0)}))},38857:function(e,t,n){"use strict";var r=n(9918),i=n(97065),o=n(19123),s=n(81589),a=n(20266),l=n(65968),c=n(24229),u=r.aTypedArray,h=r.exportTypedArrayMethod,f=l("".slice),d=c((function(){var e=0;return new Int8Array(2).fill({valueOf:function(){return e++}}),1!==e}));h("fill",(function(e){var t=arguments.length;u(this);var n="Big"===f(s(this),0,3)?o(e):+e;return a(i,this,n,t>1?arguments[1]:void 0,t>2?arguments[2]:void 0)}),d)},58329:function(e,t,n){"use strict";var r=n(9918),i=n(89996).filter,o=n(88874),s=r.aTypedArray,a=r.exportTypedArrayMethod;a("filter",(function(e){var t=i(s(this),e,arguments.length>1?arguments[1]:void 0);return o(this,t)}))},427:function(e,t,n){"use strict";var r=n(9918),i=n(89996).findIndex,o=r.aTypedArray,s=r.exportTypedArrayMethod;s("findIndex",(function(e){return i(o(this),e,arguments.length>1?arguments[1]:void 0)}))},57093:function(e,t,n){"use strict";var r=n(9918),i=n(15439).findLastIndex,o=r.aTypedArray,s=r.exportTypedArrayMethod;s("findLastIndex",(function(e){return i(o(this),e,arguments.length>1?arguments[1]:void 0)}))},40171:function(e,t,n){"use strict";var r=n(9918),i=n(15439).findLast,o=r.aTypedArray,s=r.exportTypedArrayMethod;s("findLast",(function(e){return i(o(this),e,arguments.length>1?arguments[1]:void 0)}))},76279:function(e,t,n){"use strict";var r=n(9918),i=n(89996).find,o=r.aTypedArray,s=r.exportTypedArrayMethod;s("find",(function(e){return i(o(this),e,arguments.length>1?arguments[1]:void 0)}))},11159:function(e,t,n){"use strict";var r=n(9918),i=n(89996).forEach,o=r.aTypedArray,s=r.exportTypedArrayMethod;s("forEach",(function(e){i(o(this),e,arguments.length>1?arguments[1]:void 0)}))},42516:function(e,t,n){"use strict";var r=n(9918),i=n(19540).includes,o=r.aTypedArray,s=r.exportTypedArrayMethod;s("includes",(function(e){return i(o(this),e,arguments.length>1?arguments[1]:void 0)}))},64349:function(e,t,n){"use strict";var r=n(9918),i=n(19540).indexOf,o=r.aTypedArray,s=r.exportTypedArrayMethod;s("indexOf",(function(e){return i(o(this),e,arguments.length>1?arguments[1]:void 0)}))},15273:function(e,t,n){"use strict";var r=n(9859),i=n(24229),o=n(65968),s=n(9918),a=n(15735),l=n(70095),c=l("iterator"),u=r.Uint8Array,h=o(a.values),f=o(a.keys),d=o(a.entries),p=s.aTypedArray,g=s.exportTypedArrayMethod,m=u&&u.prototype,v=!i((function(){m[c].call([1])})),y=!!m&&m.values&&m[c]===m.values&&"values"===m.values.name,w=function(){return h(p(this))};g("entries",(function(){return d(p(this))}),v),g("keys",(function(){return f(p(this))}),v),g("values",w,v||!y,{name:"values"}),g(c,w,v||!y,{name:"values"})},16729:function(e,t,n){"use strict";var r=n(9918),i=n(65968),o=r.aTypedArray,s=r.exportTypedArrayMethod,a=i([].join);s("join",(function(e){return a(o(this),e)}))},41801:function(e,t,n){"use strict";var r=n(9918),i=n(53171),o=n(86462),s=r.aTypedArray,a=r.exportTypedArrayMethod;a("lastIndexOf",(function(e){var t=arguments.length;return i(o,s(this),t>1?[e,arguments[1]]:[e])}))},50574:function(e,t,n){"use strict";var r=n(9918),i=n(89996).map,o=n(54622),s=r.aTypedArray,a=r.exportTypedArrayMethod;a("map",(function(e){return i(s(this),e,arguments.length>1?arguments[1]:void 0,(function(e,t){return new(o(e))(t)}))}))},39271:function(e,t,n){"use strict";var r=n(9918),i=n(43143).right,o=r.aTypedArray,s=r.exportTypedArrayMethod;s("reduceRight",(function(e){var t=arguments.length;return i(o(this),e,t,t>1?arguments[1]:void 0)}))},5787:function(e,t,n){"use strict";var r=n(9918),i=n(43143).left,o=r.aTypedArray,s=r.exportTypedArrayMethod;s("reduce",(function(e){var t=arguments.length;return i(o(this),e,t,t>1?arguments[1]:void 0)}))},73160:function(e,t,n){"use strict";var r=n(9918),i=r.aTypedArray,o=r.exportTypedArrayMethod,s=Math.floor;o("reverse",(function(){var e,t=this,n=i(t).length,r=s(n/2),o=0;while(o<r)e=t[o],t[o++]=t[--n],t[n]=e;return t}))},65688:function(e,t,n){"use strict";var r=n(9859),i=n(20266),o=n(9918),s=n(39646),a=n(84262),l=n(92991),c=n(24229),u=r.RangeError,h=r.Int8Array,f=h&&h.prototype,d=f&&f.set,p=o.aTypedArray,g=o.exportTypedArrayMethod,m=!c((function(){var e=new Uint8ClampedArray(2);return i(d,e,{length:1,0:3},1),3!==e[1]})),v=m&&o.NATIVE_ARRAY_BUFFER_VIEWS&&c((function(){var e=new h(2);return e.set(1),e.set("2",1),0!==e[0]||2!==e[1]}));g("set",(function(e){p(this);var t=a(arguments.length>1?arguments[1]:void 0,1),n=l(e);if(m)return i(d,this,n,t);var r=this.length,o=s(n),c=0;if(o+t>r)throw u("Wrong length");while(c<o)this[t+c]=n[c++]}),!m||v)},93157:function(e,t,n){"use strict";var r=n(9918),i=n(54622),o=n(24229),s=n(1909),a=r.aTypedArray,l=r.exportTypedArrayMethod,c=o((function(){new Int8Array(1).slice()}));l("slice",(function(e,t){var n=s(a(this),e,t),r=i(this),o=0,l=n.length,c=new r(l);while(l>o)c[o]=n[o++];return c}),c)},33333:function(e,t,n){"use strict";var r=n(9918),i=n(89996).some,o=r.aTypedArray,s=r.exportTypedArrayMethod;s("some",(function(e){return i(o(this),e,arguments.length>1?arguments[1]:void 0)}))},70315:function(e,t,n){"use strict";var r=n(9859),i=n(44745),o=n(24229),s=n(77111),a=n(33867),l=n(9918),c=n(22671),u=n(48506),h=n(6358),f=n(49811),d=l.aTypedArray,p=l.exportTypedArrayMethod,g=r.Uint16Array,m=g&&i(g.prototype.sort),v=!!m&&!(o((function(){m(new g(2),null)}))&&o((function(){m(new g(2),{})}))),y=!!m&&!o((function(){if(h)return h<74;if(c)return c<67;if(u)return!0;if(f)return f<602;var e,t,n=new g(516),r=Array(516);for(e=0;e<516;e++)t=e%4,n[e]=515-e,r[e]=e-2*t+3;for(m(n,(function(e,t){return(e/4|0)-(t/4|0)})),e=0;e<516;e++)if(n[e]!==r[e])return!0})),w=function(e){return function(t,n){return void 0!==e?+e(t,n)||0:n!==n?-1:t!==t?1:0===t&&0===n?1/t>0&&1/n<0?1:-1:t>n}};p("sort",(function(e){return void 0!==e&&s(e),y?m(this,e):a(d(this),w(e))}),!y||v)},50556:function(e,t,n){"use strict";var r=n(9859),i=n(53171),o=n(9918),s=n(24229),a=n(1909),l=r.Int8Array,c=o.aTypedArray,u=o.exportTypedArrayMethod,h=[].toLocaleString,f=!!l&&s((function(){h.call(new l(1))})),d=s((function(){return[1,2].toLocaleString()!=new l([1,2]).toLocaleString()}))||!s((function(){l.prototype.toLocaleString.call([1,2])}));u("toLocaleString",(function(){return i(h,f?a(c(this)):c(this),a(arguments))}),d)},92529:function(e,t,n){"use strict";var r=n(21178),i=n(9918),o=i.aTypedArray,s=i.exportTypedArrayMethod,a=i.getTypedArrayConstructor;s("toReversed",(function(){return r(o(this),a(this))}))},86943:function(e,t,n){"use strict";var r=n(9918),i=n(65968),o=n(77111),s=n(41253),a=r.aTypedArray,l=r.getTypedArrayConstructor,c=r.exportTypedArrayMethod,u=i(r.TypedArrayPrototype.sort);c("toSorted",(function(e){void 0!==e&&o(e);var t=a(this),n=s(l(t),t);return u(n,e)}))},29224:function(e,t,n){"use strict";var r=n(9918).exportTypedArrayMethod,i=n(24229),o=n(9859),s=n(65968),a=o.Uint8Array,l=a&&a.prototype||{},c=[].toString,u=s([].join);i((function(){c.call({})}))&&(c=function(){return u(this)});var h=l.toString!=c;r("toString",c,h)},13675:function(e,t,n){var r=n(42574);r("Uint8",(function(e){return function(t,n,r){return e(this,t,n,r)}}))},91157:function(e,t,n){"use strict";var r=n(69647),i=n(9918),o=n(79098),s=n(43329),a=n(19123),l=i.aTypedArray,c=i.getTypedArrayConstructor,u=i.exportTypedArrayMethod,h=!!function(){try{new Int8Array(1)["with"](2,{valueOf:function(){throw 8}})}catch(e){return 8===e}}();u("with",{with:function(e,t){var n=l(this),i=s(e),u=o(n)?a(t):+t;return r(n,c(n),i,u)}}["with"],!h)},6418:function(e,t,n){"use strict";var r,i=n(68476),o=n(9859),s=n(65968),a=n(8312),l=n(95926),c=n(69789),u=n(63370),h=n(85052),f=n(56407).enforce,d=n(24229),p=n(51180),g=Object,m=Array.isArray,v=g.isExtensible,y=g.isFrozen,w=g.isSealed,b=g.freeze,x=g.seal,S={},_={},k=!o.ActiveXObject&&"ActiveXObject"in o,C=function(e){return function(){return e(this,arguments.length?arguments[0]:void 0)}},$=c("WeakMap",C,u),A=$.prototype,R=s(A.set),T=function(){return i&&d((function(){var e=b([]);return R(new $,e,1),!y(e)}))};if(p)if(k){r=u.getConstructor(C,"WeakMap",!0),l.enable();var E=s(A["delete"]),L=s(A.has),M=s(A.get);a(A,{delete:function(e){if(h(e)&&!v(e)){var t=f(this);return t.frozen||(t.frozen=new r),E(this,e)||t.frozen["delete"](e)}return E(this,e)},has:function(e){if(h(e)&&!v(e)){var t=f(this);return t.frozen||(t.frozen=new r),L(this,e)||t.frozen.has(e)}return L(this,e)},get:function(e){if(h(e)&&!v(e)){var t=f(this);return t.frozen||(t.frozen=new r),L(this,e)?M(this,e):t.frozen.get(e)}return M(this,e)},set:function(e,t){if(h(e)&&!v(e)){var n=f(this);n.frozen||(n.frozen=new r),L(this,e)?R(this,e,t):n.frozen.set(e,t)}else R(this,e,t);return this}})}else T()&&a(A,{set:function(e,t){var n;return m(e)&&(y(e)?n=S:w(e)&&(n=_)),R(this,e,t),n==S&&b(e),n==_&&x(e),this}})},52356:function(e,t,n){n(6418)},22649:function(e,t,n){n(92529)},80014:function(e,t,n){n(86943)},61996:function(e,t,n){n(91157)},62653:function(e,t,n){"use strict";n(15735);var r=n(23103),i=n(9859),o=n(20266),s=n(65968),a=n(7400),l=n(34144),c=n(14768),u=n(96616),h=n(8312),f=n(54555),d=n(42247),p=n(56407),g=n(57728),m=n(26733),v=n(98270),y=n(97636),w=n(81589),b=n(21176),x=n(85052),S=n(83326),_=n(22391),k=n(65358),C=n(28403),$=n(78830),A=n(77579),R=n(70095),T=n(33867),E=R("iterator"),L="URLSearchParams",M=L+"Iterator",O=p.set,I=p.getterFor(L),P=p.getterFor(M),D=Object.getOwnPropertyDescriptor,F=function(e){if(!a)return i[e];var t=D(i,e);return t&&t.value},B=F("fetch"),W=F("Request"),N=F("Headers"),H=W&&W.prototype,j=N&&N.prototype,z=i.RegExp,U=i.TypeError,V=i.decodeURIComponent,G=i.encodeURIComponent,K=s("".charAt),q=s([].join),Z=s([].push),Y=s("".replace),X=s([].shift),Q=s([].splice),J=s("".split),ee=s("".slice),te=/\+/g,ne=Array(4),re=function(e){return ne[e-1]||(ne[e-1]=z("((?:%[\\da-f]{2}){"+e+"})","gi"))},ie=function(e){try{return V(e)}catch(t){return e}},oe=function(e){var t=Y(e,te," "),n=4;try{return V(t)}catch(r){while(n)t=Y(t,re(n--),ie);return t}},se=/[!'()~]|%20/g,ae={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+"},le=function(e){return ae[e]},ce=function(e){return Y(G(e),se,le)},ue=d((function(e,t){O(this,{type:M,iterator:C(I(e).entries),kind:t})}),"Iterator",(function(){var e=P(this),t=e.kind,n=e.iterator.next(),r=n.value;return n.done||(n.value="keys"===t?r.key:"values"===t?r.value:[r.key,r.value]),n}),!0),he=function(e){this.entries=[],this.url=null,void 0!==e&&(x(e)?this.parseObject(e):this.parseQuery("string"==typeof e?"?"===K(e,0)?ee(e,1):e:S(e)))};he.prototype={type:L,bindURL:function(e){this.url=e,this.update()},parseObject:function(e){var t,n,r,i,s,a,l,c=$(e);if(c){t=C(e,c),n=t.next;while(!(r=o(n,t)).done){if(i=C(b(r.value)),s=i.next,(a=o(s,i)).done||(l=o(s,i)).done||!o(s,i).done)throw U("Expected sequence with length 2");Z(this.entries,{key:S(a.value),value:S(l.value)})}}else for(var u in e)v(e,u)&&Z(this.entries,{key:u,value:S(e[u])})},parseQuery:function(e){if(e){var t,n,r=J(e,"&"),i=0;while(i<r.length)t=r[i++],t.length&&(n=J(t,"="),Z(this.entries,{key:oe(X(n)),value:oe(q(n,"="))}))}},serialize:function(){var e,t=this.entries,n=[],r=0;while(r<t.length)e=t[r++],Z(n,ce(e.key)+"="+ce(e.value));return q(n,"&")},update:function(){this.entries.length=0,this.parseQuery(this.url.query)},updateURL:function(){this.url&&this.url.update()}};var fe=function(){g(this,de);var e=arguments.length>0?arguments[0]:void 0,t=O(this,new he(e));a||(this.length=t.entries.length)},de=fe.prototype;if(h(de,{append:function(e,t){A(arguments.length,2);var n=I(this);Z(n.entries,{key:S(e),value:S(t)}),a||this.length++,n.updateURL()},delete:function(e){A(arguments.length,1);var t=I(this),n=t.entries,r=S(e),i=0;while(i<n.length)n[i].key===r?Q(n,i,1):i++;a||(this.length=n.length),t.updateURL()},get:function(e){A(arguments.length,1);for(var t=I(this).entries,n=S(e),r=0;r<t.length;r++)if(t[r].key===n)return t[r].value;return null},getAll:function(e){A(arguments.length,1);for(var t=I(this).entries,n=S(e),r=[],i=0;i<t.length;i++)t[i].key===n&&Z(r,t[i].value);return r},has:function(e){A(arguments.length,1);var t=I(this).entries,n=S(e),r=0;while(r<t.length)if(t[r++].key===n)return!0;return!1},set:function(e,t){A(arguments.length,1);for(var n,r=I(this),i=r.entries,o=!1,s=S(e),l=S(t),c=0;c<i.length;c++)n=i[c],n.key===s&&(o?Q(i,c--,1):(o=!0,n.value=l));o||Z(i,{key:s,value:l}),a||(this.length=i.length),r.updateURL()},sort:function(){var e=I(this);T(e.entries,(function(e,t){return e.key>t.key?1:-1})),e.updateURL()},forEach:function(e){var t,n=I(this).entries,r=y(e,arguments.length>1?arguments[1]:void 0),i=0;while(i<n.length)t=n[i++],r(t.value,t.key,this)},keys:function(){return new ue(this,"keys")},values:function(){return new ue(this,"values")},entries:function(){return new ue(this,"entries")}},{enumerable:!0}),c(de,E,de.entries,{name:"entries"}),c(de,"toString",(function(){return I(this).serialize()}),{enumerable:!0}),a&&u(de,"size",{get:function(){return I(this).entries.length},configurable:!0,enumerable:!0}),f(fe,L),r({global:!0,constructor:!0,forced:!l},{URLSearchParams:fe}),!l&&m(N)){var pe=s(j.has),ge=s(j.set),me=function(e){if(x(e)){var t,n=e.body;if(w(n)===L)return t=e.headers?new N(e.headers):new N,pe(t,"content-type")||ge(t,"content-type","application/x-www-form-urlencoded;charset=UTF-8"),_(e,{body:k(0,S(n)),headers:k(0,t)})}return e};if(m(B)&&r({global:!0,enumerable:!0,dontCallGetSet:!0,forced:!0},{fetch:function(e){return B(e,arguments.length>1?me(arguments[1]):{})}}),m(W)){var ve=function(e){return g(this,H),new W(e,arguments.length>1?me(arguments[1]):{})};H.constructor=ve,ve.prototype=H,r({global:!0,constructor:!0,dontCallGetSet:!0,forced:!0},{Request:ve})}}e.exports={URLSearchParams:fe,getState:I}},60523:function(e,t,n){n(62653)},95340:function(e,t,n){"use strict";n(28673);var r,i=n(23103),o=n(7400),s=n(34144),a=n(9859),l=n(97636),c=n(65968),u=n(14768),h=n(96616),f=n(57728),d=n(98270),p=n(47),g=n(10507),m=n(69794),v=n(30966).codeAt,y=n(77321),w=n(83326),b=n(54555),x=n(77579),S=n(62653),_=n(56407),k=_.set,C=_.getterFor("URL"),$=S.URLSearchParams,A=S.getState,R=a.URL,T=a.TypeError,E=a.parseInt,L=Math.floor,M=Math.pow,O=c("".charAt),I=c(/./.exec),P=c([].join),D=c(1..toString),F=c([].pop),B=c([].push),W=c("".replace),N=c([].shift),H=c("".split),j=c("".slice),z=c("".toLowerCase),U=c([].unshift),V="Invalid authority",G="Invalid scheme",K="Invalid host",q="Invalid port",Z=/[a-z]/i,Y=/[\d+-.a-z]/i,X=/\d/,Q=/^0x/i,J=/^[0-7]+$/,ee=/^\d+$/,te=/^[\da-f]+$/i,ne=/[\0\t\n\r #%/:<>?@[\\\]^|]/,re=/[\0\t\n\r #/:<>?@[\\\]^|]/,ie=/^[\u0000-\u0020]+/,oe=/(^|[^\u0000-\u0020])[\u0000-\u0020]+$/,se=/[\t\n\r]/g,ae=function(e){var t,n,r,i,o,s,a,l=H(e,".");if(l.length&&""==l[l.length-1]&&l.length--,t=l.length,t>4)return e;for(n=[],r=0;r<t;r++){if(i=l[r],""==i)return e;if(o=10,i.length>1&&"0"==O(i,0)&&(o=I(Q,i)?16:8,i=j(i,8==o?1:2)),""===i)s=0;else{if(!I(10==o?ee:8==o?J:te,i))return e;s=E(i,o)}B(n,s)}for(r=0;r<t;r++)if(s=n[r],r==t-1){if(s>=M(256,5-t))return null}else if(s>255)return null;for(a=F(n),r=0;r<n.length;r++)a+=n[r]*M(256,3-r);return a},le=function(e){var t,n,r,i,o,s,a,l=[0,0,0,0,0,0,0,0],c=0,u=null,h=0,f=function(){return O(e,h)};if(":"==f()){if(":"!=O(e,1))return;h+=2,c++,u=c}while(f()){if(8==c)return;if(":"!=f()){t=n=0;while(n<4&&I(te,f()))t=16*t+E(f(),16),h++,n++;if("."==f()){if(0==n)return;if(h-=n,c>6)return;r=0;while(f()){if(i=null,r>0){if(!("."==f()&&r<4))return;h++}if(!I(X,f()))return;while(I(X,f())){if(o=E(f(),10),null===i)i=o;else{if(0==i)return;i=10*i+o}if(i>255)return;h++}l[c]=256*l[c]+i,r++,2!=r&&4!=r||c++}if(4!=r)return;break}if(":"==f()){if(h++,!f())return}else if(f())return;l[c++]=t}else{if(null!==u)return;h++,c++,u=c}}if(null!==u){s=c-u,c=7;while(0!=c&&s>0)a=l[c],l[c--]=l[u+s-1],l[u+--s]=a}else if(8!=c)return;return l},ce=function(e){for(var t=null,n=1,r=null,i=0,o=0;o<8;o++)0!==e[o]?(i>n&&(t=r,n=i),r=null,i=0):(null===r&&(r=o),++i);return i>n&&(t=r,n=i),t},ue=function(e){var t,n,r,i;if("number"==typeof e){for(t=[],n=0;n<4;n++)U(t,e%256),e=L(e/256);return P(t,".")}if("object"==typeof e){for(t="",r=ce(e),n=0;n<8;n++)i&&0===e[n]||(i&&(i=!1),r===n?(t+=n?":":"::",i=!0):(t+=D(e[n],16),n<7&&(t+=":")));return"["+t+"]"}return e},he={},fe=p({},he,{" ":1,'"':1,"<":1,">":1,"`":1}),de=p({},fe,{"#":1,"?":1,"{":1,"}":1}),pe=p({},de,{"/":1,":":1,";":1,"=":1,"@":1,"[":1,"\\":1,"]":1,"^":1,"|":1}),ge=function(e,t){var n=v(e,0);return n>32&&n<127&&!d(t,e)?e:encodeURIComponent(e)},me={ftp:21,file:null,http:80,https:443,ws:80,wss:443},ve=function(e,t){var n;return 2==e.length&&I(Z,O(e,0))&&(":"==(n=O(e,1))||!t&&"|"==n)},ye=function(e){var t;return e.length>1&&ve(j(e,0,2))&&(2==e.length||"/"===(t=O(e,2))||"\\"===t||"?"===t||"#"===t)},we=function(e){return"."===e||"%2e"===z(e)},be=function(e){return e=z(e),".."===e||"%2e."===e||".%2e"===e||"%2e%2e"===e},xe={},Se={},_e={},ke={},Ce={},$e={},Ae={},Re={},Te={},Ee={},Le={},Me={},Oe={},Ie={},Pe={},De={},Fe={},Be={},We={},Ne={},He={},je=function(e,t,n){var r,i,o,s=w(e);if(t){if(i=this.parse(s),i)throw T(i);this.searchParams=null}else{if(void 0!==n&&(r=new je(n,!0)),i=this.parse(s,null,r),i)throw T(i);o=A(new $),o.bindURL(this),this.searchParams=o}};je.prototype={type:"URL",parse:function(e,t,n){var i,o,s,a,l=this,c=t||xe,u=0,h="",f=!1,p=!1,v=!1;e=w(e),t||(l.scheme="",l.username="",l.password="",l.host=null,l.port=null,l.path=[],l.query=null,l.fragment=null,l.cannotBeABaseURL=!1,e=W(e,ie,""),e=W(e,oe,"$1")),e=W(e,se,""),i=g(e);while(u<=i.length){switch(o=i[u],c){case xe:if(!o||!I(Z,o)){if(t)return G;c=_e;continue}h+=z(o),c=Se;break;case Se:if(o&&(I(Y,o)||"+"==o||"-"==o||"."==o))h+=z(o);else{if(":"!=o){if(t)return G;h="",c=_e,u=0;continue}if(t&&(l.isSpecial()!=d(me,h)||"file"==h&&(l.includesCredentials()||null!==l.port)||"file"==l.scheme&&!l.host))return;if(l.scheme=h,t)return void(l.isSpecial()&&me[l.scheme]==l.port&&(l.port=null));h="","file"==l.scheme?c=Ie:l.isSpecial()&&n&&n.scheme==l.scheme?c=ke:l.isSpecial()?c=Re:"/"==i[u+1]?(c=Ce,u++):(l.cannotBeABaseURL=!0,B(l.path,""),c=We)}break;case _e:if(!n||n.cannotBeABaseURL&&"#"!=o)return G;if(n.cannotBeABaseURL&&"#"==o){l.scheme=n.scheme,l.path=m(n.path),l.query=n.query,l.fragment="",l.cannotBeABaseURL=!0,c=He;break}c="file"==n.scheme?Ie:$e;continue;case ke:if("/"!=o||"/"!=i[u+1]){c=$e;continue}c=Te,u++;break;case Ce:if("/"==o){c=Ee;break}c=Be;continue;case $e:if(l.scheme=n.scheme,o==r)l.username=n.username,l.password=n.password,l.host=n.host,l.port=n.port,l.path=m(n.path),l.query=n.query;else if("/"==o||"\\"==o&&l.isSpecial())c=Ae;else if("?"==o)l.username=n.username,l.password=n.password,l.host=n.host,l.port=n.port,l.path=m(n.path),l.query="",c=Ne;else{if("#"!=o){l.username=n.username,l.password=n.password,l.host=n.host,l.port=n.port,l.path=m(n.path),l.path.length--,c=Be;continue}l.username=n.username,l.password=n.password,l.host=n.host,l.port=n.port,l.path=m(n.path),l.query=n.query,l.fragment="",c=He}break;case Ae:if(!l.isSpecial()||"/"!=o&&"\\"!=o){if("/"!=o){l.username=n.username,l.password=n.password,l.host=n.host,l.port=n.port,c=Be;continue}c=Ee}else c=Te;break;case Re:if(c=Te,"/"!=o||"/"!=O(h,u+1))continue;u++;break;case Te:if("/"!=o&&"\\"!=o){c=Ee;continue}break;case Ee:if("@"==o){f&&(h="%40"+h),f=!0,s=g(h);for(var y=0;y<s.length;y++){var b=s[y];if(":"!=b||v){var x=ge(b,pe);v?l.password+=x:l.username+=x}else v=!0}h=""}else if(o==r||"/"==o||"?"==o||"#"==o||"\\"==o&&l.isSpecial()){if(f&&""==h)return V;u-=g(h).length+1,h="",c=Le}else h+=o;break;case Le:case Me:if(t&&"file"==l.scheme){c=De;continue}if(":"!=o||p){if(o==r||"/"==o||"?"==o||"#"==o||"\\"==o&&l.isSpecial()){if(l.isSpecial()&&""==h)return K;if(t&&""==h&&(l.includesCredentials()||null!==l.port))return;if(a=l.parseHost(h),a)return a;if(h="",c=Fe,t)return;continue}"["==o?p=!0:"]"==o&&(p=!1),h+=o}else{if(""==h)return K;if(a=l.parseHost(h),a)return a;if(h="",c=Oe,t==Me)return}break;case Oe:if(!I(X,o)){if(o==r||"/"==o||"?"==o||"#"==o||"\\"==o&&l.isSpecial()||t){if(""!=h){var S=E(h,10);if(S>65535)return q;l.port=l.isSpecial()&&S===me[l.scheme]?null:S,h=""}if(t)return;c=Fe;continue}return q}h+=o;break;case Ie:if(l.scheme="file","/"==o||"\\"==o)c=Pe;else{if(!n||"file"!=n.scheme){c=Be;continue}if(o==r)l.host=n.host,l.path=m(n.path),l.query=n.query;else if("?"==o)l.host=n.host,l.path=m(n.path),l.query="",c=Ne;else{if("#"!=o){ye(P(m(i,u),""))||(l.host=n.host,l.path=m(n.path),l.shortenPath()),c=Be;continue}l.host=n.host,l.path=m(n.path),l.query=n.query,l.fragment="",c=He}}break;case Pe:if("/"==o||"\\"==o){c=De;break}n&&"file"==n.scheme&&!ye(P(m(i,u),""))&&(ve(n.path[0],!0)?B(l.path,n.path[0]):l.host=n.host),c=Be;continue;case De:if(o==r||"/"==o||"\\"==o||"?"==o||"#"==o){if(!t&&ve(h))c=Be;else if(""==h){if(l.host="",t)return;c=Fe}else{if(a=l.parseHost(h),a)return a;if("localhost"==l.host&&(l.host=""),t)return;h="",c=Fe}continue}h+=o;break;case Fe:if(l.isSpecial()){if(c=Be,"/"!=o&&"\\"!=o)continue}else if(t||"?"!=o)if(t||"#"!=o){if(o!=r&&(c=Be,"/"!=o))continue}else l.fragment="",c=He;else l.query="",c=Ne;break;case Be:if(o==r||"/"==o||"\\"==o&&l.isSpecial()||!t&&("?"==o||"#"==o)){if(be(h)?(l.shortenPath(),"/"==o||"\\"==o&&l.isSpecial()||B(l.path,"")):we(h)?"/"==o||"\\"==o&&l.isSpecial()||B(l.path,""):("file"==l.scheme&&!l.path.length&&ve(h)&&(l.host&&(l.host=""),h=O(h,0)+":"),B(l.path,h)),h="","file"==l.scheme&&(o==r||"?"==o||"#"==o))while(l.path.length>1&&""===l.path[0])N(l.path);"?"==o?(l.query="",c=Ne):"#"==o&&(l.fragment="",c=He)}else h+=ge(o,de);break;case We:"?"==o?(l.query="",c=Ne):"#"==o?(l.fragment="",c=He):o!=r&&(l.path[0]+=ge(o,he));break;case Ne:t||"#"!=o?o!=r&&("'"==o&&l.isSpecial()?l.query+="%27":l.query+="#"==o?"%23":ge(o,he)):(l.fragment="",c=He);break;case He:o!=r&&(l.fragment+=ge(o,fe));break}u++}},parseHost:function(e){var t,n,r;if("["==O(e,0)){if("]"!=O(e,e.length-1))return K;if(t=le(j(e,1,-1)),!t)return K;this.host=t}else if(this.isSpecial()){if(e=y(e),I(ne,e))return K;if(t=ae(e),null===t)return K;this.host=t}else{if(I(re,e))return K;for(t="",n=g(e),r=0;r<n.length;r++)t+=ge(n[r],he);this.host=t}},cannotHaveUsernamePasswordPort:function(){return!this.host||this.cannotBeABaseURL||"file"==this.scheme},includesCredentials:function(){return""!=this.username||""!=this.password},isSpecial:function(){return d(me,this.scheme)},shortenPath:function(){var e=this.path,t=e.length;!t||"file"==this.scheme&&1==t&&ve(e[0],!0)||e.length--},serialize:function(){var e=this,t=e.scheme,n=e.username,r=e.password,i=e.host,o=e.port,s=e.path,a=e.query,l=e.fragment,c=t+":";return null!==i?(c+="//",e.includesCredentials()&&(c+=n+(r?":"+r:"")+"@"),c+=ue(i),null!==o&&(c+=":"+o)):"file"==t&&(c+="//"),c+=e.cannotBeABaseURL?s[0]:s.length?"/"+P(s,"/"):"",null!==a&&(c+="?"+a),null!==l&&(c+="#"+l),c},setHref:function(e){var t=this.parse(e);if(t)throw T(t);this.searchParams.update()},getOrigin:function(){var e=this.scheme,t=this.port;if("blob"==e)try{return new ze(e.path[0]).origin}catch(n){return"null"}return"file"!=e&&this.isSpecial()?e+"://"+ue(this.host)+(null!==t?":"+t:""):"null"},getProtocol:function(){return this.scheme+":"},setProtocol:function(e){this.parse(w(e)+":",xe)},getUsername:function(){return this.username},setUsername:function(e){var t=g(w(e));if(!this.cannotHaveUsernamePasswordPort()){this.username="";for(var n=0;n<t.length;n++)this.username+=ge(t[n],pe)}},getPassword:function(){return this.password},setPassword:function(e){var t=g(w(e));if(!this.cannotHaveUsernamePasswordPort()){this.password="";for(var n=0;n<t.length;n++)this.password+=ge(t[n],pe)}},getHost:function(){var e=this.host,t=this.port;return null===e?"":null===t?ue(e):ue(e)+":"+t},setHost:function(e){this.cannotBeABaseURL||this.parse(e,Le)},getHostname:function(){var e=this.host;return null===e?"":ue(e)},setHostname:function(e){this.cannotBeABaseURL||this.parse(e,Me)},getPort:function(){var e=this.port;return null===e?"":w(e)},setPort:function(e){this.cannotHaveUsernamePasswordPort()||(e=w(e),""==e?this.port=null:this.parse(e,Oe))},getPathname:function(){var e=this.path;return this.cannotBeABaseURL?e[0]:e.length?"/"+P(e,"/"):""},setPathname:function(e){this.cannotBeABaseURL||(this.path=[],this.parse(e,Fe))},getSearch:function(){var e=this.query;return e?"?"+e:""},setSearch:function(e){e=w(e),""==e?this.query=null:("?"==O(e,0)&&(e=j(e,1)),this.query="",this.parse(e,Ne)),this.searchParams.update()},getSearchParams:function(){return this.searchParams.facade},getHash:function(){var e=this.fragment;return e?"#"+e:""},setHash:function(e){e=w(e),""!=e?("#"==O(e,0)&&(e=j(e,1)),this.fragment="",this.parse(e,He)):this.fragment=null},update:function(){this.query=this.searchParams.serialize()||null}};var ze=function(e){var t=f(this,Ue),n=x(arguments.length,1)>1?arguments[1]:void 0,r=k(t,new je(e,!1,n));o||(t.href=r.serialize(),t.origin=r.getOrigin(),t.protocol=r.getProtocol(),t.username=r.getUsername(),t.password=r.getPassword(),t.host=r.getHost(),t.hostname=r.getHostname(),t.port=r.getPort(),t.pathname=r.getPathname(),t.search=r.getSearch(),t.searchParams=r.getSearchParams(),t.hash=r.getHash())},Ue=ze.prototype,Ve=function(e,t){return{get:function(){return C(this)[e]()},set:t&&function(e){return C(this)[t](e)},configurable:!0,enumerable:!0}};if(o&&(h(Ue,"href",Ve("serialize","setHref")),h(Ue,"origin",Ve("getOrigin")),h(Ue,"protocol",Ve("getProtocol","setProtocol")),h(Ue,"username",Ve("getUsername","setUsername")),h(Ue,"password",Ve("getPassword","setPassword")),h(Ue,"host",Ve("getHost","setHost")),h(Ue,"hostname",Ve("getHostname","setHostname")),h(Ue,"port",Ve("getPort","setPort")),h(Ue,"pathname",Ve("getPathname","setPathname")),h(Ue,"search",Ve("getSearch","setSearch")),h(Ue,"searchParams",Ve("getSearchParams")),h(Ue,"hash",Ve("getHash","setHash"))),u(Ue,"toJSON",(function(){return C(this).serialize()}),{enumerable:!0}),u(Ue,"toString",(function(){return C(this).serialize()}),{enumerable:!0}),R){var Ge=R.createObjectURL,Ke=R.revokeObjectURL;Ge&&u(ze,"createObjectURL",l(Ge,R)),Ke&&u(ze,"revokeObjectURL",l(Ke,R))}b(ze,"URL"),i({global:!0,constructor:!0,forced:!s,sham:!o},{URL:ze})},14121:function(e,t,n){n(95340)},796:function(e,t,n){"use strict";n.r(t);var r=n(39601),i=n.n(r),o=n(82609),s=n.n(o),a=s()(i());a.push([e.id,'.uplot,.uplot *,.uplot :after,.uplot :before{box-sizing:border-box}.uplot{font-family:system-ui,-apple-system,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;line-height:1.5;width:-moz-min-content;width:min-content}.u-title{text-align:center;font-size:18px;font-weight:700}.u-wrap{position:relative;-webkit-user-select:none;-moz-user-select:none;user-select:none}.u-over,.u-under{position:absolute}.u-under{overflow:hidden}.uplot canvas{display:block;position:relative;width:100%;height:100%}.u-axis{position:absolute}.u-legend{font-size:14px;margin:auto;text-align:center}.u-inline{display:block}.u-inline *{display:inline-block}.u-inline tr{margin-right:16px}.u-legend th{font-weight:600}.u-legend th>*{vertical-align:middle;display:inline-block}.u-legend .u-marker{width:1em;height:1em;margin-right:4px;background-clip:padding-box!important}.u-inline.u-live th:after{content:":";vertical-align:middle}.u-inline:not(.u-live) .u-value{display:none}.u-series>*{padding:4px}.u-series th{cursor:pointer}.u-legend .u-off>*{opacity:.3}.u-select{background:rgba(0,0,0,.07)}.u-cursor-x,.u-cursor-y,.u-select{position:absolute;pointer-events:none}.u-cursor-x,.u-cursor-y{left:0;top:0;will-change:transform;z-index:100}.u-hz .u-cursor-x,.u-vt .u-cursor-y{height:100%;border-right:1px dashed #607d8b}.u-hz .u-cursor-y,.u-vt .u-cursor-x{width:100%;border-bottom:1px dashed #607d8b}.u-cursor-pt{position:absolute;top:0;left:0;border-radius:50%;border:0 solid;pointer-events:none;will-change:transform;z-index:100;background-clip:padding-box!important}.u-axis.u-off,.u-cursor-pt.u-off,.u-cursor-x.u-off,.u-cursor-y.u-off,.u-select.u-off{display:none}',""]),t["default"]=a},15344:function(e,t,n){"use strict";n.d(t,{Z:function(){return V}});var r={lessThanXSeconds:{one:"less than a second",other:"less than {{count}} seconds"},xSeconds:{one:"1 second",other:"{{count}} seconds"},halfAMinute:"half a minute",lessThanXMinutes:{one:"less than a minute",other:"less than {{count}} minutes"},xMinutes:{one:"1 minute",other:"{{count}} minutes"},aboutXHours:{one:"about 1 hour",other:"about {{count}} hours"},xHours:{one:"1 hour",other:"{{count}} hours"},xDays:{one:"1 day",other:"{{count}} days"},aboutXWeeks:{one:"about 1 week",other:"about {{count}} weeks"},xWeeks:{one:"1 week",other:"{{count}} weeks"},aboutXMonths:{one:"about 1 month",other:"about {{count}} months"},xMonths:{one:"1 month",other:"{{count}} months"},aboutXYears:{one:"about 1 year",other:"about {{count}} years"},xYears:{one:"1 year",other:"{{count}} years"},overXYears:{one:"over 1 year",other:"over {{count}} years"},almostXYears:{one:"almost 1 year",other:"almost {{count}} years"}},i=function(e,t,n){var i,o=r[e];return i="string"===typeof o?o:1===t?o.one:o.other.replace("{{count}}",t.toString()),null!==n&&void 0!==n&&n.addSuffix?n.comparison&&n.comparison>0?"in "+i:i+" ago":i},o=i;function s(e){return function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=t.width?String(t.width):e.defaultWidth,r=e.formats[n]||e.formats[e.defaultWidth];return r}}var a={full:"EEEE, MMMM do, y",long:"MMMM do, y",medium:"MMM d, y",short:"MM/dd/yyyy"},l={full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},c={full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},u={date:s({formats:a,defaultWidth:"full"}),time:s({formats:l,defaultWidth:"full"}),dateTime:s({formats:c,defaultWidth:"full"})},h=u,f={lastWeek:"'last' eeee 'at' p",yesterday:"'yesterday at' p",today:"'today at' p",tomorrow:"'tomorrow at' p",nextWeek:"eeee 'at' p",other:"P"},d=function(e,t,n,r){return f[e]},p=d;function g(e){return function(t,n){var r,i=null!==n&&void 0!==n&&n.context?String(n.context):"standalone";if("formatting"===i&&e.formattingValues){var o=e.defaultFormattingWidth||e.defaultWidth,s=null!==n&&void 0!==n&&n.width?String(n.width):o;r=e.formattingValues[s]||e.formattingValues[o]}else{var a=e.defaultWidth,l=null!==n&&void 0!==n&&n.width?String(n.width):e.defaultWidth;r=e.values[l]||e.values[a]}var c=e.argumentCallback?e.argumentCallback(t):t;return r[c]}}var m={narrow:["B","A"],abbreviated:["BC","AD"],wide:["Before Christ","Anno Domini"]},v={narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]},y={narrow:["J","F","M","A","M","J","J","A","S","O","N","D"],abbreviated:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],wide:["January","February","March","April","May","June","July","August","September","October","November","December"]},w={narrow:["S","M","T","W","T","F","S"],short:["Su","Mo","Tu","We","Th","Fr","Sa"],abbreviated:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],wide:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},b={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"}},x={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"}},S=function(e,t){var n=Number(e),r=n%100;if(r>20||r<10)switch(r%10){case 1:return n+"st";case 2:return n+"nd";case 3:return n+"rd"}return n+"th"},_={ordinalNumber:S,era:g({values:m,defaultWidth:"wide"}),quarter:g({values:v,defaultWidth:"wide",argumentCallback:function(e){return e-1}}),month:g({values:y,defaultWidth:"wide"}),day:g({values:w,defaultWidth:"wide"}),dayPeriod:g({values:b,defaultWidth:"wide",formattingValues:x,defaultFormattingWidth:"wide"})},k=_;function C(e){return function(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=n.width,i=r&&e.matchPatterns[r]||e.matchPatterns[e.defaultMatchWidth],o=t.match(i);if(!o)return null;var s,a=o[0],l=r&&e.parsePatterns[r]||e.parsePatterns[e.defaultParseWidth],c=Array.isArray(l)?A(l,(function(e){return e.test(a)})):$(l,(function(e){return e.test(a)}));s=e.valueCallback?e.valueCallback(c):c,s=n.valueCallback?n.valueCallback(s):s;var u=t.slice(a.length);return{value:s,rest:u}}}function $(e,t){for(var n in e)if(e.hasOwnProperty(n)&&t(e[n]))return n}function A(e,t){for(var n=0;n<e.length;n++)if(t(e[n]))return n}function R(e){return function(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=t.match(e.matchPattern);if(!r)return null;var i=r[0],o=t.match(e.parsePattern);if(!o)return null;var s=e.valueCallback?e.valueCallback(o[0]):o[0];s=n.valueCallback?n.valueCallback(s):s;var a=t.slice(i.length);return{value:s,rest:a}}}var T=/^(\d+)(th|st|nd|rd)?/i,E=/\d+/i,L={narrow:/^(b|a)/i,abbreviated:/^(b\.?\s?c\.?|b\.?\s?c\.?\s?e\.?|a\.?\s?d\.?|c\.?\s?e\.?)/i,wide:/^(before christ|before common era|anno domini|common era)/i},M={any:[/^b/i,/^(a|c)/i]},O={narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](th|st|nd|rd)? quarter/i},I={any:[/1/i,/2/i,/3/i,/4/i]},P={narrow:/^[jfmasond]/i,abbreviated:/^(jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)/i,wide:/^(january|february|march|april|may|june|july|august|september|october|november|december)/i},D={narrow:[/^j/i,/^f/i,/^m/i,/^a/i,/^m/i,/^j/i,/^j/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^ja/i,/^f/i,/^mar/i,/^ap/i,/^may/i,/^jun/i,/^jul/i,/^au/i,/^s/i,/^o/i,/^n/i,/^d/i]},F={narrow:/^[smtwf]/i,short:/^(su|mo|tu|we|th|fr|sa)/i,abbreviated:/^(sun|mon|tue|wed|thu|fri|sat)/i,wide:/^(sunday|monday|tuesday|wednesday|thursday|friday|saturday)/i},B={narrow:[/^s/i,/^m/i,/^t/i,/^w/i,/^t/i,/^f/i,/^s/i],any:[/^su/i,/^m/i,/^tu/i,/^w/i,/^th/i,/^f/i,/^sa/i]},W={narrow:/^(a|p|mi|n|(in the|at) (morning|afternoon|evening|night))/i,any:/^([ap]\.?\s?m\.?|midnight|noon|(in the|at) (morning|afternoon|evening|night))/i},N={any:{am:/^a/i,pm:/^p/i,midnight:/^mi/i,noon:/^no/i,morning:/morning/i,afternoon:/afternoon/i,evening:/evening/i,night:/night/i}},H={ordinalNumber:R({matchPattern:T,parsePattern:E,valueCallback:function(e){return parseInt(e,10)}}),era:C({matchPatterns:L,defaultMatchWidth:"wide",parsePatterns:M,defaultParseWidth:"any"}),quarter:C({matchPatterns:O,defaultMatchWidth:"wide",parsePatterns:I,defaultParseWidth:"any",valueCallback:function(e){return e+1}}),month:C({matchPatterns:P,defaultMatchWidth:"wide",parsePatterns:D,defaultParseWidth:"any"}),day:C({matchPatterns:F,defaultMatchWidth:"wide",parsePatterns:B,defaultParseWidth:"any"}),dayPeriod:C({matchPatterns:W,defaultMatchWidth:"any",parsePatterns:N,defaultParseWidth:"any"})},j=H,z={code:"en-US",formatDistance:o,formatLong:h,formatRelative:p,localize:k,match:j,options:{weekStartsOn:0,firstWeekContainsDate:1}},U=z,V=U},18667:function(e,t,n){"use strict";n.d(t,{j:function(){return i}});var r={};function i(){return r}},60429:function(e,t){"use strict";var n=function(e,t){switch(e){case"P":return t.date({width:"short"});case"PP":return t.date({width:"medium"});case"PPP":return t.date({width:"long"});case"PPPP":default:return t.date({width:"full"})}},r=function(e,t){switch(e){case"p":return t.time({width:"short"});case"pp":return t.time({width:"medium"});case"ppp":return t.time({width:"long"});case"pppp":default:return t.time({width:"full"})}},i=function(e,t){var i,o=e.match(/(P+)(p+)?/)||[],s=o[1],a=o[2];if(!a)return n(e,t);switch(s){case"P":i=t.dateTime({width:"short"});break;case"PP":i=t.dateTime({width:"medium"});break;case"PPP":i=t.dateTime({width:"long"});break;case"PPPP":default:i=t.dateTime({width:"full"});break}return i.replace("{{date}}",n(s,t)).replace("{{time}}",r(a,t))},o={p:r,P:i};t["Z"]=o},1645:function(e,t,n){"use strict";function r(e){var t=new Date(Date.UTC(e.getFullYear(),e.getMonth(),e.getDate(),e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds()));return t.setUTCFullYear(e.getFullYear()),e.getTime()-t.getTime()}n.d(t,{Z:function(){return r}})},17898:function(e,t,n){"use strict";n.d(t,{Z:function(){return c}});var r=n(66700),i=n(55143),o=n(90257),s=n(19785);function a(e){(0,s.Z)(1,arguments);var t=(0,o.Z)(e),n=new Date(0);n.setUTCFullYear(t,0,4),n.setUTCHours(0,0,0,0);var r=(0,i.Z)(n);return r}var l=6048e5;function c(e){(0,s.Z)(1,arguments);var t=(0,r.Z)(e),n=(0,i.Z)(t).getTime()-a(t).getTime();return Math.round(n/l)+1}},90257:function(e,t,n){"use strict";n.d(t,{Z:function(){return s}});var r=n(66700),i=n(19785),o=n(55143);function s(e){(0,i.Z)(1,arguments);var t=(0,r.Z)(e),n=t.getUTCFullYear(),s=new Date(0);s.setUTCFullYear(n+1,0,4),s.setUTCHours(0,0,0,0);var a=(0,o.Z)(s),l=new Date(0);l.setUTCFullYear(n,0,4),l.setUTCHours(0,0,0,0);var c=(0,o.Z)(l);return t.getTime()>=a.getTime()?n+1:t.getTime()>=c.getTime()?n:n-1}},46733:function(e,t,n){"use strict";n.d(t,{Z:function(){return h}});var r=n(66700),i=n(52329),o=n(72763),s=n(19785),a=n(42765),l=n(18667);function c(e,t){var n,r,c,u,h,f,d,p;(0,s.Z)(1,arguments);var g=(0,l.j)(),m=(0,a.Z)(null!==(n=null!==(r=null!==(c=null!==(u=null===t||void 0===t?void 0:t.firstWeekContainsDate)&&void 0!==u?u:null===t||void 0===t||null===(h=t.locale)||void 0===h||null===(f=h.options)||void 0===f?void 0:f.firstWeekContainsDate)&&void 0!==c?c:g.firstWeekContainsDate)&&void 0!==r?r:null===(d=g.locale)||void 0===d||null===(p=d.options)||void 0===p?void 0:p.firstWeekContainsDate)&&void 0!==n?n:1),v=(0,o.Z)(e,t),y=new Date(0);y.setUTCFullYear(v,0,m),y.setUTCHours(0,0,0,0);var w=(0,i.Z)(y,t);return w}var u=6048e5;function h(e,t){(0,s.Z)(1,arguments);var n=(0,r.Z)(e),o=(0,i.Z)(n,t).getTime()-c(n,t).getTime();return Math.round(o/u)+1}},72763:function(e,t,n){"use strict";n.d(t,{Z:function(){return l}});var r=n(66700),i=n(19785),o=n(52329),s=n(42765),a=n(18667);function l(e,t){var n,l,c,u,h,f,d,p;(0,i.Z)(1,arguments);var g=(0,r.Z)(e),m=g.getUTCFullYear(),v=(0,a.j)(),y=(0,s.Z)(null!==(n=null!==(l=null!==(c=null!==(u=null===t||void 0===t?void 0:t.firstWeekContainsDate)&&void 0!==u?u:null===t||void 0===t||null===(h=t.locale)||void 0===h||null===(f=h.options)||void 0===f?void 0:f.firstWeekContainsDate)&&void 0!==c?c:v.firstWeekContainsDate)&&void 0!==l?l:null===(d=v.locale)||void 0===d||null===(p=d.options)||void 0===p?void 0:p.firstWeekContainsDate)&&void 0!==n?n:1);if(!(y>=1&&y<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var w=new Date(0);w.setUTCFullYear(m+1,0,y),w.setUTCHours(0,0,0,0);var b=(0,o.Z)(w,t),x=new Date(0);x.setUTCFullYear(m,0,y),x.setUTCHours(0,0,0,0);var S=(0,o.Z)(x,t);return g.getTime()>=b.getTime()?m+1:g.getTime()>=S.getTime()?m:m-1}},13503:function(e,t,n){"use strict";n.d(t,{Do:function(){return s},Iu:function(){return o},qp:function(){return a}});var r=["D","DD"],i=["YY","YYYY"];function o(e){return-1!==r.indexOf(e)}function s(e){return-1!==i.indexOf(e)}function a(e,t,n){if("YYYY"===e)throw new RangeError("Use `yyyy` instead of `YYYY` (in `".concat(t,"`) for formatting years to the input `").concat(n,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"));if("YY"===e)throw new RangeError("Use `yy` instead of `YY` (in `".concat(t,"`) for formatting years to the input `").concat(n,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"));if("D"===e)throw new RangeError("Use `d` instead of `D` (in `".concat(t,"`) for formatting days of the month to the input `").concat(n,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"));if("DD"===e)throw new RangeError("Use `dd` instead of `DD` (in `".concat(t,"`) for formatting days of the month to the input `").concat(n,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"))}},19785:function(e,t,n){"use strict";function r(e,t){if(t.length<e)throw new TypeError(e+" argument"+(e>1?"s":"")+" required, but only "+t.length+" present")}n.d(t,{Z:function(){return r}})},55143:function(e,t,n){"use strict";n.d(t,{Z:function(){return o}});var r=n(66700),i=n(19785);function o(e){(0,i.Z)(1,arguments);var t=1,n=(0,r.Z)(e),o=n.getUTCDay(),s=(o<t?7:0)+o-t;return n.setUTCDate(n.getUTCDate()-s),n.setUTCHours(0,0,0,0),n}},52329:function(e,t,n){"use strict";n.d(t,{Z:function(){return a}});var r=n(66700),i=n(19785),o=n(42765),s=n(18667);function a(e,t){var n,a,l,c,u,h,f,d;(0,i.Z)(1,arguments);var p=(0,s.j)(),g=(0,o.Z)(null!==(n=null!==(a=null!==(l=null!==(c=null===t||void 0===t?void 0:t.weekStartsOn)&&void 0!==c?c:null===t||void 0===t||null===(u=t.locale)||void 0===u||null===(h=u.options)||void 0===h?void 0:h.weekStartsOn)&&void 0!==l?l:p.weekStartsOn)&&void 0!==a?a:null===(f=p.locale)||void 0===f||null===(d=f.options)||void 0===d?void 0:d.weekStartsOn)&&void 0!==n?n:0);if(!(g>=0&&g<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");var m=(0,r.Z)(e),v=m.getUTCDay(),y=(v<g?7:0)+v-g;return m.setUTCDate(m.getUTCDate()-y),m.setUTCHours(0,0,0,0),m}},42765:function(e,t,n){"use strict";function r(e){if(null===e||!0===e||!1===e)return NaN;var t=Number(e);return isNaN(t)?t:t<0?Math.ceil(t):Math.floor(t)}n.d(t,{Z:function(){return r}})},73053:function(e,t,n){"use strict";n.d(t,{Z:function(){return O}});var r=n(31200),i=n(89248),o=n(66700),s=n(19785),a=864e5;function l(e){(0,s.Z)(1,arguments);var t=(0,o.Z)(e),n=t.getTime();t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0);var r=t.getTime(),i=n-r;return Math.floor(i/a)+1}var c=n(17898),u=n(90257),h=n(46733),f=n(72763);function d(e,t){var n=e<0?"-":"",r=Math.abs(e).toString();while(r.length<t)r="0"+r;return n+r}var p={y:function(e,t){var n=e.getUTCFullYear(),r=n>0?n:1-n;return d("yy"===t?r%100:r,t.length)},M:function(e,t){var n=e.getUTCMonth();return"M"===t?String(n+1):d(n+1,2)},d:function(e,t){return d(e.getUTCDate(),t.length)},a:function(e,t){var n=e.getUTCHours()/12>=1?"pm":"am";switch(t){case"a":case"aa":return n.toUpperCase();case"aaa":return n;case"aaaaa":return n[0];case"aaaa":default:return"am"===n?"a.m.":"p.m."}},h:function(e,t){return d(e.getUTCHours()%12||12,t.length)},H:function(e,t){return d(e.getUTCHours(),t.length)},m:function(e,t){return d(e.getUTCMinutes(),t.length)},s:function(e,t){return d(e.getUTCSeconds(),t.length)},S:function(e,t){var n=t.length,r=e.getUTCMilliseconds(),i=Math.floor(r*Math.pow(10,n-3));return d(i,t.length)}},g=p,m={am:"am",pm:"pm",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},v={G:function(e,t,n){var r=e.getUTCFullYear()>0?1:0;switch(t){case"G":case"GG":case"GGG":return n.era(r,{width:"abbreviated"});case"GGGGG":return n.era(r,{width:"narrow"});case"GGGG":default:return n.era(r,{width:"wide"})}},y:function(e,t,n){if("yo"===t){var r=e.getUTCFullYear(),i=r>0?r:1-r;return n.ordinalNumber(i,{unit:"year"})}return g.y(e,t)},Y:function(e,t,n,r){var i=(0,f.Z)(e,r),o=i>0?i:1-i;if("YY"===t){var s=o%100;return d(s,2)}return"Yo"===t?n.ordinalNumber(o,{unit:"year"}):d(o,t.length)},R:function(e,t){var n=(0,u.Z)(e);return d(n,t.length)},u:function(e,t){var n=e.getUTCFullYear();return d(n,t.length)},Q:function(e,t,n){var r=Math.ceil((e.getUTCMonth()+1)/3);switch(t){case"Q":return String(r);case"QQ":return d(r,2);case"Qo":return n.ordinalNumber(r,{unit:"quarter"});case"QQQ":return n.quarter(r,{width:"abbreviated",context:"formatting"});case"QQQQQ":return n.quarter(r,{width:"narrow",context:"formatting"});case"QQQQ":default:return n.quarter(r,{width:"wide",context:"formatting"})}},q:function(e,t,n){var r=Math.ceil((e.getUTCMonth()+1)/3);switch(t){case"q":return String(r);case"qq":return d(r,2);case"qo":return n.ordinalNumber(r,{unit:"quarter"});case"qqq":return n.quarter(r,{width:"abbreviated",context:"standalone"});case"qqqqq":return n.quarter(r,{width:"narrow",context:"standalone"});case"qqqq":default:return n.quarter(r,{width:"wide",context:"standalone"})}},M:function(e,t,n){var r=e.getUTCMonth();switch(t){case"M":case"MM":return g.M(e,t);case"Mo":return n.ordinalNumber(r+1,{unit:"month"});case"MMM":return n.month(r,{width:"abbreviated",context:"formatting"});case"MMMMM":return n.month(r,{width:"narrow",context:"formatting"});case"MMMM":default:return n.month(r,{width:"wide",context:"formatting"})}},L:function(e,t,n){var r=e.getUTCMonth();switch(t){case"L":return String(r+1);case"LL":return d(r+1,2);case"Lo":return n.ordinalNumber(r+1,{unit:"month"});case"LLL":return n.month(r,{width:"abbreviated",context:"standalone"});case"LLLLL":return n.month(r,{width:"narrow",context:"standalone"});case"LLLL":default:return n.month(r,{width:"wide",context:"standalone"})}},w:function(e,t,n,r){var i=(0,h.Z)(e,r);return"wo"===t?n.ordinalNumber(i,{unit:"week"}):d(i,t.length)},I:function(e,t,n){var r=(0,c.Z)(e);return"Io"===t?n.ordinalNumber(r,{unit:"week"}):d(r,t.length)},d:function(e,t,n){return"do"===t?n.ordinalNumber(e.getUTCDate(),{unit:"date"}):g.d(e,t)},D:function(e,t,n){var r=l(e);return"Do"===t?n.ordinalNumber(r,{unit:"dayOfYear"}):d(r,t.length)},E:function(e,t,n){var r=e.getUTCDay();switch(t){case"E":case"EE":case"EEE":return n.day(r,{width:"abbreviated",context:"formatting"});case"EEEEE":return n.day(r,{width:"narrow",context:"formatting"});case"EEEEEE":return n.day(r,{width:"short",context:"formatting"});case"EEEE":default:return n.day(r,{width:"wide",context:"formatting"})}},e:function(e,t,n,r){var i=e.getUTCDay(),o=(i-r.weekStartsOn+8)%7||7;switch(t){case"e":return String(o);case"ee":return d(o,2);case"eo":return n.ordinalNumber(o,{unit:"day"});case"eee":return n.day(i,{width:"abbreviated",context:"formatting"});case"eeeee":return n.day(i,{width:"narrow",context:"formatting"});case"eeeeee":return n.day(i,{width:"short",context:"formatting"});case"eeee":default:return n.day(i,{width:"wide",context:"formatting"})}},c:function(e,t,n,r){var i=e.getUTCDay(),o=(i-r.weekStartsOn+8)%7||7;switch(t){case"c":return String(o);case"cc":return d(o,t.length);case"co":return n.ordinalNumber(o,{unit:"day"});case"ccc":return n.day(i,{width:"abbreviated",context:"standalone"});case"ccccc":return n.day(i,{width:"narrow",context:"standalone"});case"cccccc":return n.day(i,{width:"short",context:"standalone"});case"cccc":default:return n.day(i,{width:"wide",context:"standalone"})}},i:function(e,t,n){var r=e.getUTCDay(),i=0===r?7:r;switch(t){case"i":return String(i);case"ii":return d(i,t.length);case"io":return n.ordinalNumber(i,{unit:"day"});case"iii":return n.day(r,{width:"abbreviated",context:"formatting"});case"iiiii":return n.day(r,{width:"narrow",context:"formatting"});case"iiiiii":return n.day(r,{width:"short",context:"formatting"});case"iiii":default:return n.day(r,{width:"wide",context:"formatting"})}},a:function(e,t,n){var r=e.getUTCHours(),i=r/12>=1?"pm":"am";switch(t){case"a":case"aa":return n.dayPeriod(i,{width:"abbreviated",context:"formatting"});case"aaa":return n.dayPeriod(i,{width:"abbreviated",context:"formatting"}).toLowerCase();case"aaaaa":return n.dayPeriod(i,{width:"narrow",context:"formatting"});case"aaaa":default:return n.dayPeriod(i,{width:"wide",context:"formatting"})}},b:function(e,t,n){var r,i=e.getUTCHours();switch(r=12===i?m.noon:0===i?m.midnight:i/12>=1?"pm":"am",t){case"b":case"bb":return n.dayPeriod(r,{width:"abbreviated",context:"formatting"});case"bbb":return n.dayPeriod(r,{width:"abbreviated",context:"formatting"}).toLowerCase();case"bbbbb":return n.dayPeriod(r,{width:"narrow",context:"formatting"});case"bbbb":default:return n.dayPeriod(r,{width:"wide",context:"formatting"})}},B:function(e,t,n){var r,i=e.getUTCHours();switch(r=i>=17?m.evening:i>=12?m.afternoon:i>=4?m.morning:m.night,t){case"B":case"BB":case"BBB":return n.dayPeriod(r,{width:"abbreviated",context:"formatting"});case"BBBBB":return n.dayPeriod(r,{width:"narrow",context:"formatting"});case"BBBB":default:return n.dayPeriod(r,{width:"wide",context:"formatting"})}},h:function(e,t,n){if("ho"===t){var r=e.getUTCHours()%12;return 0===r&&(r=12),n.ordinalNumber(r,{unit:"hour"})}return g.h(e,t)},H:function(e,t,n){return"Ho"===t?n.ordinalNumber(e.getUTCHours(),{unit:"hour"}):g.H(e,t)},K:function(e,t,n){var r=e.getUTCHours()%12;return"Ko"===t?n.ordinalNumber(r,{unit:"hour"}):d(r,t.length)},k:function(e,t,n){var r=e.getUTCHours();return 0===r&&(r=24),"ko"===t?n.ordinalNumber(r,{unit:"hour"}):d(r,t.length)},m:function(e,t,n){return"mo"===t?n.ordinalNumber(e.getUTCMinutes(),{unit:"minute"}):g.m(e,t)},s:function(e,t,n){return"so"===t?n.ordinalNumber(e.getUTCSeconds(),{unit:"second"}):g.s(e,t)},S:function(e,t){return g.S(e,t)},X:function(e,t,n,r){var i=r._originalDate||e,o=i.getTimezoneOffset();if(0===o)return"Z";switch(t){case"X":return w(o);case"XXXX":case"XX":return b(o);case"XXXXX":case"XXX":default:return b(o,":")}},x:function(e,t,n,r){var i=r._originalDate||e,o=i.getTimezoneOffset();switch(t){case"x":return w(o);case"xxxx":case"xx":return b(o);case"xxxxx":case"xxx":default:return b(o,":")}},O:function(e,t,n,r){var i=r._originalDate||e,o=i.getTimezoneOffset();switch(t){case"O":case"OO":case"OOO":return"GMT"+y(o,":");case"OOOO":default:return"GMT"+b(o,":")}},z:function(e,t,n,r){var i=r._originalDate||e,o=i.getTimezoneOffset();switch(t){case"z":case"zz":case"zzz":return"GMT"+y(o,":");case"zzzz":default:return"GMT"+b(o,":")}},t:function(e,t,n,r){var i=r._originalDate||e,o=Math.floor(i.getTime()/1e3);return d(o,t.length)},T:function(e,t,n,r){var i=r._originalDate||e,o=i.getTime();return d(o,t.length)}};function y(e,t){var n=e>0?"-":"+",r=Math.abs(e),i=Math.floor(r/60),o=r%60;if(0===o)return n+String(i);var s=t||"";return n+String(i)+s+d(o,2)}function w(e,t){if(e%60===0){var n=e>0?"-":"+";return n+d(Math.abs(e)/60,2)}return b(e,t)}function b(e,t){var n=t||"",r=e>0?"-":"+",i=Math.abs(e),o=d(Math.floor(i/60),2),s=d(i%60,2);return r+o+n+s}var x=v,S=n(60429),_=n(1645),k=n(13503),C=n(42765),$=n(18667),A=n(15344),R=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,T=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,E=/^'([^]*?)'?$/,L=/''/g,M=/[a-zA-Z]/;function O(e,t,n){var a,l,c,u,h,f,d,p,g,m,v,y,w,b,E,L,O,P;(0,s.Z)(2,arguments);var D=String(t),F=(0,$.j)(),B=null!==(a=null!==(l=null===n||void 0===n?void 0:n.locale)&&void 0!==l?l:F.locale)&&void 0!==a?a:A.Z,W=(0,C.Z)(null!==(c=null!==(u=null!==(h=null!==(f=null===n||void 0===n?void 0:n.firstWeekContainsDate)&&void 0!==f?f:null===n||void 0===n||null===(d=n.locale)||void 0===d||null===(p=d.options)||void 0===p?void 0:p.firstWeekContainsDate)&&void 0!==h?h:F.firstWeekContainsDate)&&void 0!==u?u:null===(g=F.locale)||void 0===g||null===(m=g.options)||void 0===m?void 0:m.firstWeekContainsDate)&&void 0!==c?c:1);if(!(W>=1&&W<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var N=(0,C.Z)(null!==(v=null!==(y=null!==(w=null!==(b=null===n||void 0===n?void 0:n.weekStartsOn)&&void 0!==b?b:null===n||void 0===n||null===(E=n.locale)||void 0===E||null===(L=E.options)||void 0===L?void 0:L.weekStartsOn)&&void 0!==w?w:F.weekStartsOn)&&void 0!==y?y:null===(O=F.locale)||void 0===O||null===(P=O.options)||void 0===P?void 0:P.weekStartsOn)&&void 0!==v?v:0);if(!(N>=0&&N<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");if(!B.localize)throw new RangeError("locale must contain localize property");if(!B.formatLong)throw new RangeError("locale must contain formatLong property");var H=(0,o.Z)(e);if(!(0,r.Z)(H))throw new RangeError("Invalid time value");var j=(0,_.Z)(H),z=(0,i.Z)(H,j),U={firstWeekContainsDate:W,weekStartsOn:N,locale:B,_originalDate:H},V=D.match(T).map((function(e){var t=e[0];if("p"===t||"P"===t){var n=S.Z[t];return n(e,B.formatLong)}return e})).join("").match(R).map((function(r){if("''"===r)return"'";var i=r[0];if("'"===i)return I(r);var o=x[i];if(o)return null!==n&&void 0!==n&&n.useAdditionalWeekYearTokens||!(0,k.Do)(r)||(0,k.qp)(r,t,String(e)),null!==n&&void 0!==n&&n.useAdditionalDayOfYearTokens||!(0,k.Iu)(r)||(0,k.qp)(r,t,String(e)),o(z,r,B.localize,U);if(i.match(M))throw new RangeError("Format string contains an unescaped latin alphabet character `"+i+"`");return r})).join("");return V}function I(e){var t=e.match(E);return t?t[1].replace(L,"'"):e}},31200:function(e,t,n){"use strict";n.d(t,{Z:function(){return a}});var r=n(19785);function i(e){return i="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"===typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},i(e)}function o(e){return(0,r.Z)(1,arguments),e instanceof Date||"object"===i(e)&&"[object Date]"===Object.prototype.toString.call(e)}var s=n(66700);function a(e){if((0,r.Z)(1,arguments),!o(e)&&"number"!==typeof e)return!1;var t=(0,s.Z)(e);return!isNaN(Number(t))}},10247:function(e,t,n){"use strict";n.d(t,{Z:function(){return ja}});var r=n(15344),i=n(89248),o=n(66700);function s(e,t){if(null==e)throw new TypeError("assign requires that input parameter not be null or undefined");for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e}var a=n(60429),l=n(1645),c=n(13503),u=n(42765),h=n(19785);function f(e){return f="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"===typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},f(e)}function d(e,t){if("function"!==typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&p(e,t)}function p(e,t){return p=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},p(e,t)}function g(e){var t=y();return function(){var n,r=w(e);if(t){var i=w(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return m(this,n)}}function m(e,t){return!t||"object"!==f(t)&&"function"!==typeof t?v(e):t}function v(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function y(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}function w(e){return w=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},w(e)}function b(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function x(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function S(e,t,n){return t&&x(e.prototype,t),n&&x(e,n),e}function _(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var k=10,C=function(){function e(){b(this,e),_(this,"subPriority",0)}return S(e,[{key:"validate",value:function(e,t){return!0}}]),e}(),$=function(e){d(n,e);var t=g(n);function n(e,r,i,o,s){var a;return b(this,n),a=t.call(this),a.value=e,a.validateValue=r,a.setValue=i,a.priority=o,s&&(a.subPriority=s),a}return S(n,[{key:"validate",value:function(e,t){return this.validateValue(e,this.value,t)}},{key:"set",value:function(e,t,n){return this.setValue(e,t,this.value,n)}}]),n}(C),A=function(e){d(n,e);var t=g(n);function n(){var e;b(this,n);for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];return e=t.call.apply(t,[this].concat(i)),_(v(e),"priority",k),_(v(e),"subPriority",-1),e}return S(n,[{key:"set",value:function(e,t){if(t.timestampIsSet)return e;var n=new Date(0);return n.setFullYear(e.getUTCFullYear(),e.getUTCMonth(),e.getUTCDate()),n.setHours(e.getUTCHours(),e.getUTCMinutes(),e.getUTCSeconds(),e.getUTCMilliseconds()),n}}]),n}(C);function R(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function T(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function E(e,t,n){return t&&T(e.prototype,t),n&&T(e,n),e}var L=function(){function e(){R(this,e)}return E(e,[{key:"run",value:function(e,t,n,r){var i=this.parse(e,t,n,r);return i?{setter:new $(i.value,this.validate,this.set,this.priority,this.subPriority),rest:i.rest}:null}},{key:"validate",value:function(e,t,n){return!0}}]),e}();function M(e){return M="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"===typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},M(e)}function O(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function I(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function P(e,t,n){return t&&I(e.prototype,t),n&&I(e,n),e}function D(e,t){if("function"!==typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&F(e,t)}function F(e,t){return F=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},F(e,t)}function B(e){var t=H();return function(){var n,r=j(e);if(t){var i=j(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return W(this,n)}}function W(e,t){return!t||"object"!==M(t)&&"function"!==typeof t?N(e):t}function N(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function H(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}function j(e){return j=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},j(e)}function z(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var U=function(e){D(n,e);var t=B(n);function n(){var e;O(this,n);for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];return e=t.call.apply(t,[this].concat(i)),z(N(e),"priority",140),z(N(e),"incompatibleTokens",["R","u","t","T"]),e}return P(n,[{key:"parse",value:function(e,t,n){switch(t){case"G":case"GG":case"GGG":return n.era(e,{width:"abbreviated"})||n.era(e,{width:"narrow"});case"GGGGG":return n.era(e,{width:"narrow"});case"GGGG":default:return n.era(e,{width:"wide"})||n.era(e,{width:"abbreviated"})||n.era(e,{width:"narrow"})}}},{key:"set",value:function(e,t,n){return t.era=n,e.setUTCFullYear(n,0,1),e.setUTCHours(0,0,0,0),e}}]),n}(L),V=(Math.pow(10,8),6e4),G=36e5,K=1e3,q={month:/^(1[0-2]|0?\d)/,date:/^(3[0-1]|[0-2]?\d)/,dayOfYear:/^(36[0-6]|3[0-5]\d|[0-2]?\d?\d)/,week:/^(5[0-3]|[0-4]?\d)/,hour23h:/^(2[0-3]|[0-1]?\d)/,hour24h:/^(2[0-4]|[0-1]?\d)/,hour11h:/^(1[0-1]|0?\d)/,hour12h:/^(1[0-2]|0?\d)/,minute:/^[0-5]?\d/,second:/^[0-5]?\d/,singleDigit:/^\d/,twoDigits:/^\d{1,2}/,threeDigits:/^\d{1,3}/,fourDigits:/^\d{1,4}/,anyDigitsSigned:/^-?\d+/,singleDigitSigned:/^-?\d/,twoDigitsSigned:/^-?\d{1,2}/,threeDigitsSigned:/^-?\d{1,3}/,fourDigitsSigned:/^-?\d{1,4}/},Z={basicOptionalMinutes:/^([+-])(\d{2})(\d{2})?|Z/,basic:/^([+-])(\d{2})(\d{2})|Z/,basicOptionalSeconds:/^([+-])(\d{2})(\d{2})((\d{2}))?|Z/,extended:/^([+-])(\d{2}):(\d{2})|Z/,extendedOptionalSeconds:/^([+-])(\d{2}):(\d{2})(:(\d{2}))?|Z/};function Y(e,t){return e?{value:t(e.value),rest:e.rest}:e}function X(e,t){var n=t.match(e);return n?{value:parseInt(n[0],10),rest:t.slice(n[0].length)}:null}function Q(e,t){var n=t.match(e);if(!n)return null;if("Z"===n[0])return{value:0,rest:t.slice(1)};var r="+"===n[1]?1:-1,i=n[2]?parseInt(n[2],10):0,o=n[3]?parseInt(n[3],10):0,s=n[5]?parseInt(n[5],10):0;return{value:r*(i*G+o*V+s*K),rest:t.slice(n[0].length)}}function J(e){return X(q.anyDigitsSigned,e)}function ee(e,t){switch(e){case 1:return X(q.singleDigit,t);case 2:return X(q.twoDigits,t);case 3:return X(q.threeDigits,t);case 4:return X(q.fourDigits,t);default:return X(new RegExp("^\\d{1,"+e+"}"),t)}}function te(e,t){switch(e){case 1:return X(q.singleDigitSigned,t);case 2:return X(q.twoDigitsSigned,t);case 3:return X(q.threeDigitsSigned,t);case 4:return X(q.fourDigitsSigned,t);default:return X(new RegExp("^-?\\d{1,"+e+"}"),t)}}function ne(e){switch(e){case"morning":return 4;case"evening":return 17;case"pm":case"noon":case"afternoon":return 12;case"am":case"midnight":case"night":default:return 0}}function re(e,t){var n,r=t>0,i=r?t:1-t;if(i<=50)n=e||100;else{var o=i+50,s=100*Math.floor(o/100),a=e>=o%100;n=e+s-(a?100:0)}return r?n:1-n}function ie(e){return e%400===0||e%4===0&&e%100!==0}function oe(e){return oe="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"===typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},oe(e)}function se(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function ae(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function le(e,t,n){return t&&ae(e.prototype,t),n&&ae(e,n),e}function ce(e,t){if("function"!==typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&ue(e,t)}function ue(e,t){return ue=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},ue(e,t)}function he(e){var t=pe();return function(){var n,r=ge(e);if(t){var i=ge(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return fe(this,n)}}function fe(e,t){return!t||"object"!==oe(t)&&"function"!==typeof t?de(e):t}function de(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function pe(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}function ge(e){return ge=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},ge(e)}function me(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var ve=function(e){ce(n,e);var t=he(n);function n(){var e;se(this,n);for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];return e=t.call.apply(t,[this].concat(i)),me(de(e),"priority",130),me(de(e),"incompatibleTokens",["Y","R","u","w","I","i","e","c","t","T"]),e}return le(n,[{key:"parse",value:function(e,t,n){var r=function(e){return{year:e,isTwoDigitYear:"yy"===t}};switch(t){case"y":return Y(ee(4,e),r);case"yo":return Y(n.ordinalNumber(e,{unit:"year"}),r);default:return Y(ee(t.length,e),r)}}},{key:"validate",value:function(e,t){return t.isTwoDigitYear||t.year>0}},{key:"set",value:function(e,t,n){var r=e.getUTCFullYear();if(n.isTwoDigitYear){var i=re(n.year,r);return e.setUTCFullYear(i,0,1),e.setUTCHours(0,0,0,0),e}var o="era"in t&&1!==t.era?1-n.year:n.year;return e.setUTCFullYear(o,0,1),e.setUTCHours(0,0,0,0),e}}]),n}(L),ye=n(72763),we=n(52329);function be(e){return be="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"===typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},be(e)}function xe(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Se(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function _e(e,t,n){return t&&Se(e.prototype,t),n&&Se(e,n),e}function ke(e,t){if("function"!==typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Ce(e,t)}function Ce(e,t){return Ce=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},Ce(e,t)}function $e(e){var t=Te();return function(){var n,r=Ee(e);if(t){var i=Ee(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Ae(this,n)}}function Ae(e,t){return!t||"object"!==be(t)&&"function"!==typeof t?Re(e):t}function Re(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function Te(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}function Ee(e){return Ee=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},Ee(e)}function Le(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Me=function(e){ke(n,e);var t=$e(n);function n(){var e;xe(this,n);for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];return e=t.call.apply(t,[this].concat(i)),Le(Re(e),"priority",130),Le(Re(e),"incompatibleTokens",["y","R","u","Q","q","M","L","I","d","D","i","t","T"]),e}return _e(n,[{key:"parse",value:function(e,t,n){var r=function(e){return{year:e,isTwoDigitYear:"YY"===t}};switch(t){case"Y":return Y(ee(4,e),r);case"Yo":return Y(n.ordinalNumber(e,{unit:"year"}),r);default:return Y(ee(t.length,e),r)}}},{key:"validate",value:function(e,t){return t.isTwoDigitYear||t.year>0}},{key:"set",value:function(e,t,n,r){var i=(0,ye.Z)(e,r);if(n.isTwoDigitYear){var o=re(n.year,i);return e.setUTCFullYear(o,0,r.firstWeekContainsDate),e.setUTCHours(0,0,0,0),(0,we.Z)(e,r)}var s="era"in t&&1!==t.era?1-n.year:n.year;return e.setUTCFullYear(s,0,r.firstWeekContainsDate),e.setUTCHours(0,0,0,0),(0,we.Z)(e,r)}}]),n}(L),Oe=n(55143);function Ie(e){return Ie="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"===typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Ie(e)}function Pe(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function De(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Fe(e,t,n){return t&&De(e.prototype,t),n&&De(e,n),e}function Be(e,t){if("function"!==typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&We(e,t)}function We(e,t){return We=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},We(e,t)}function Ne(e){var t=ze();return function(){var n,r=Ue(e);if(t){var i=Ue(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return He(this,n)}}function He(e,t){return!t||"object"!==Ie(t)&&"function"!==typeof t?je(e):t}function je(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function ze(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}function Ue(e){return Ue=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},Ue(e)}function Ve(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Ge=function(e){Be(n,e);var t=Ne(n);function n(){var e;Pe(this,n);for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];return e=t.call.apply(t,[this].concat(i)),Ve(je(e),"priority",130),Ve(je(e),"incompatibleTokens",["G","y","Y","u","Q","q","M","L","w","d","D","e","c","t","T"]),e}return Fe(n,[{key:"parse",value:function(e,t){return te("R"===t?4:t.length,e)}},{key:"set",value:function(e,t,n){var r=new Date(0);return r.setUTCFullYear(n,0,4),r.setUTCHours(0,0,0,0),(0,Oe.Z)(r)}}]),n}(L);function Ke(e){return Ke="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"===typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Ke(e)}function qe(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Ze(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Ye(e,t,n){return t&&Ze(e.prototype,t),n&&Ze(e,n),e}function Xe(e,t){if("function"!==typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Qe(e,t)}function Qe(e,t){return Qe=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},Qe(e,t)}function Je(e){var t=nt();return function(){var n,r=rt(e);if(t){var i=rt(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return et(this,n)}}function et(e,t){return!t||"object"!==Ke(t)&&"function"!==typeof t?tt(e):t}function tt(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function nt(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}function rt(e){return rt=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},rt(e)}function it(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var ot=function(e){Xe(n,e);var t=Je(n);function n(){var e;qe(this,n);for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];return e=t.call.apply(t,[this].concat(i)),it(tt(e),"priority",130),it(tt(e),"incompatibleTokens",["G","y","Y","R","w","I","i","e","c","t","T"]),e}return Ye(n,[{key:"parse",value:function(e,t){return te("u"===t?4:t.length,e)}},{key:"set",value:function(e,t,n){return e.setUTCFullYear(n,0,1),e.setUTCHours(0,0,0,0),e}}]),n}(L);function st(e){return st="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"===typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},st(e)}function at(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function lt(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function ct(e,t,n){return t&&lt(e.prototype,t),n&&lt(e,n),e}function ut(e,t){if("function"!==typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&ht(e,t)}function ht(e,t){return ht=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},ht(e,t)}function ft(e){var t=gt();return function(){var n,r=mt(e);if(t){var i=mt(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return dt(this,n)}}function dt(e,t){return!t||"object"!==st(t)&&"function"!==typeof t?pt(e):t}function pt(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function gt(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}function mt(e){return mt=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},mt(e)}function vt(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var yt=function(e){ut(n,e);var t=ft(n);function n(){var e;at(this,n);for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];return e=t.call.apply(t,[this].concat(i)),vt(pt(e),"priority",120),vt(pt(e),"incompatibleTokens",["Y","R","q","M","L","w","I","d","D","i","e","c","t","T"]),e}return ct(n,[{key:"parse",value:function(e,t,n){switch(t){case"Q":case"QQ":return ee(t.length,e);case"Qo":return n.ordinalNumber(e,{unit:"quarter"});case"QQQ":return n.quarter(e,{width:"abbreviated",context:"formatting"})||n.quarter(e,{width:"narrow",context:"formatting"});case"QQQQQ":return n.quarter(e,{width:"narrow",context:"formatting"});case"QQQQ":default:return n.quarter(e,{width:"wide",context:"formatting"})||n.quarter(e,{width:"abbreviated",context:"formatting"})||n.quarter(e,{width:"narrow",context:"formatting"})}}},{key:"validate",value:function(e,t){return t>=1&&t<=4}},{key:"set",value:function(e,t,n){return e.setUTCMonth(3*(n-1),1),e.setUTCHours(0,0,0,0),e}}]),n}(L);function wt(e){return wt="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"===typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},wt(e)}function bt(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function xt(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function St(e,t,n){return t&&xt(e.prototype,t),n&&xt(e,n),e}function _t(e,t){if("function"!==typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&kt(e,t)}function kt(e,t){return kt=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},kt(e,t)}function Ct(e){var t=Rt();return function(){var n,r=Tt(e);if(t){var i=Tt(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return $t(this,n)}}function $t(e,t){return!t||"object"!==wt(t)&&"function"!==typeof t?At(e):t}function At(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function Rt(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}function Tt(e){return Tt=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},Tt(e)}function Et(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Lt=function(e){_t(n,e);var t=Ct(n);function n(){var e;bt(this,n);for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];return e=t.call.apply(t,[this].concat(i)),Et(At(e),"priority",120),Et(At(e),"incompatibleTokens",["Y","R","Q","M","L","w","I","d","D","i","e","c","t","T"]),e}return St(n,[{key:"parse",value:function(e,t,n){switch(t){case"q":case"qq":return ee(t.length,e);case"qo":return n.ordinalNumber(e,{unit:"quarter"});case"qqq":return n.quarter(e,{width:"abbreviated",context:"standalone"})||n.quarter(e,{width:"narrow",context:"standalone"});case"qqqqq":return n.quarter(e,{width:"narrow",context:"standalone"});case"qqqq":default:return n.quarter(e,{width:"wide",context:"standalone"})||n.quarter(e,{width:"abbreviated",context:"standalone"})||n.quarter(e,{width:"narrow",context:"standalone"})}}},{key:"validate",value:function(e,t){return t>=1&&t<=4}},{key:"set",value:function(e,t,n){return e.setUTCMonth(3*(n-1),1),e.setUTCHours(0,0,0,0),e}}]),n}(L);function Mt(e){return Mt="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"===typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Mt(e)}function Ot(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function It(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Pt(e,t,n){return t&&It(e.prototype,t),n&&It(e,n),e}function Dt(e,t){if("function"!==typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Ft(e,t)}function Ft(e,t){return Ft=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},Ft(e,t)}function Bt(e){var t=Ht();return function(){var n,r=jt(e);if(t){var i=jt(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Wt(this,n)}}function Wt(e,t){return!t||"object"!==Mt(t)&&"function"!==typeof t?Nt(e):t}function Nt(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function Ht(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}function jt(e){return jt=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},jt(e)}function zt(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Ut=function(e){Dt(n,e);var t=Bt(n);function n(){var e;Ot(this,n);for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];return e=t.call.apply(t,[this].concat(i)),zt(Nt(e),"incompatibleTokens",["Y","R","q","Q","L","w","I","D","i","e","c","t","T"]),zt(Nt(e),"priority",110),e}return Pt(n,[{key:"parse",value:function(e,t,n){var r=function(e){return e-1};switch(t){case"M":return Y(X(q.month,e),r);case"MM":return Y(ee(2,e),r);case"Mo":return Y(n.ordinalNumber(e,{unit:"month"}),r);case"MMM":return n.month(e,{width:"abbreviated",context:"formatting"})||n.month(e,{width:"narrow",context:"formatting"});case"MMMMM":return n.month(e,{width:"narrow",context:"formatting"});case"MMMM":default:return n.month(e,{width:"wide",context:"formatting"})||n.month(e,{width:"abbreviated",context:"formatting"})||n.month(e,{width:"narrow",context:"formatting"})}}},{key:"validate",value:function(e,t){return t>=0&&t<=11}},{key:"set",value:function(e,t,n){return e.setUTCMonth(n,1),e.setUTCHours(0,0,0,0),e}}]),n}(L);function Vt(e){return Vt="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"===typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Vt(e)}function Gt(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Kt(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function qt(e,t,n){return t&&Kt(e.prototype,t),n&&Kt(e,n),e}function Zt(e,t){if("function"!==typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Yt(e,t)}function Yt(e,t){return Yt=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},Yt(e,t)}function Xt(e){var t=en();return function(){var n,r=tn(e);if(t){var i=tn(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Qt(this,n)}}function Qt(e,t){return!t||"object"!==Vt(t)&&"function"!==typeof t?Jt(e):t}function Jt(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function en(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}function tn(e){return tn=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},tn(e)}function nn(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var rn=function(e){Zt(n,e);var t=Xt(n);function n(){var e;Gt(this,n);for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];return e=t.call.apply(t,[this].concat(i)),nn(Jt(e),"priority",110),nn(Jt(e),"incompatibleTokens",["Y","R","q","Q","M","w","I","D","i","e","c","t","T"]),e}return qt(n,[{key:"parse",value:function(e,t,n){var r=function(e){return e-1};switch(t){case"L":return Y(X(q.month,e),r);case"LL":return Y(ee(2,e),r);case"Lo":return Y(n.ordinalNumber(e,{unit:"month"}),r);case"LLL":return n.month(e,{width:"abbreviated",context:"standalone"})||n.month(e,{width:"narrow",context:"standalone"});case"LLLLL":return n.month(e,{width:"narrow",context:"standalone"});case"LLLL":default:return n.month(e,{width:"wide",context:"standalone"})||n.month(e,{width:"abbreviated",context:"standalone"})||n.month(e,{width:"narrow",context:"standalone"})}}},{key:"validate",value:function(e,t){return t>=0&&t<=11}},{key:"set",value:function(e,t,n){return e.setUTCMonth(n,1),e.setUTCHours(0,0,0,0),e}}]),n}(L),on=n(46733);function sn(e,t,n){(0,h.Z)(2,arguments);var r=(0,o.Z)(e),i=(0,u.Z)(t),s=(0,on.Z)(r,n)-i;return r.setUTCDate(r.getUTCDate()-7*s),r}function an(e){return an="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"===typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},an(e)}function ln(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function cn(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function un(e,t,n){return t&&cn(e.prototype,t),n&&cn(e,n),e}function hn(e,t){if("function"!==typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&fn(e,t)}function fn(e,t){return fn=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},fn(e,t)}function dn(e){var t=mn();return function(){var n,r=vn(e);if(t){var i=vn(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return pn(this,n)}}function pn(e,t){return!t||"object"!==an(t)&&"function"!==typeof t?gn(e):t}function gn(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function mn(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}function vn(e){return vn=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},vn(e)}function yn(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var wn=function(e){hn(n,e);var t=dn(n);function n(){var e;ln(this,n);for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];return e=t.call.apply(t,[this].concat(i)),yn(gn(e),"priority",100),yn(gn(e),"incompatibleTokens",["y","R","u","q","Q","M","L","I","d","D","i","t","T"]),e}return un(n,[{key:"parse",value:function(e,t,n){switch(t){case"w":return X(q.week,e);case"wo":return n.ordinalNumber(e,{unit:"week"});default:return ee(t.length,e)}}},{key:"validate",value:function(e,t){return t>=1&&t<=53}},{key:"set",value:function(e,t,n,r){return(0,we.Z)(sn(e,n,r),r)}}]),n}(L),bn=n(17898);function xn(e,t){(0,h.Z)(2,arguments);var n=(0,o.Z)(e),r=(0,u.Z)(t),i=(0,bn.Z)(n)-r;return n.setUTCDate(n.getUTCDate()-7*i),n}function Sn(e){return Sn="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"===typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Sn(e)}function _n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function kn(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Cn(e,t,n){return t&&kn(e.prototype,t),n&&kn(e,n),e}function $n(e,t){if("function"!==typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&An(e,t)}function An(e,t){return An=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},An(e,t)}function Rn(e){var t=Ln();return function(){var n,r=Mn(e);if(t){var i=Mn(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Tn(this,n)}}function Tn(e,t){return!t||"object"!==Sn(t)&&"function"!==typeof t?En(e):t}function En(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function Ln(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}function Mn(e){return Mn=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},Mn(e)}function On(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var In=function(e){$n(n,e);var t=Rn(n);function n(){var e;_n(this,n);for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];return e=t.call.apply(t,[this].concat(i)),On(En(e),"priority",100),On(En(e),"incompatibleTokens",["y","Y","u","q","Q","M","L","w","d","D","e","c","t","T"]),e}return Cn(n,[{key:"parse",value:function(e,t,n){switch(t){case"I":return X(q.week,e);case"Io":return n.ordinalNumber(e,{unit:"week"});default:return ee(t.length,e)}}},{key:"validate",value:function(e,t){return t>=1&&t<=53}},{key:"set",value:function(e,t,n){return(0,Oe.Z)(xn(e,n))}}]),n}(L);function Pn(e){return Pn="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"===typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Pn(e)}function Dn(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Fn(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Bn(e,t,n){return t&&Fn(e.prototype,t),n&&Fn(e,n),e}function Wn(e,t){if("function"!==typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Nn(e,t)}function Nn(e,t){return Nn=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},Nn(e,t)}function Hn(e){var t=Un();return function(){var n,r=Vn(e);if(t){var i=Vn(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return jn(this,n)}}function jn(e,t){return!t||"object"!==Pn(t)&&"function"!==typeof t?zn(e):t}function zn(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function Un(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}function Vn(e){return Vn=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},Vn(e)}function Gn(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Kn=[31,28,31,30,31,30,31,31,30,31,30,31],qn=[31,29,31,30,31,30,31,31,30,31,30,31],Zn=function(e){Wn(n,e);var t=Hn(n);function n(){var e;Dn(this,n);for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];return e=t.call.apply(t,[this].concat(i)),Gn(zn(e),"priority",90),Gn(zn(e),"subPriority",1),Gn(zn(e),"incompatibleTokens",["Y","R","q","Q","w","I","D","i","e","c","t","T"]),e}return Bn(n,[{key:"parse",value:function(e,t,n){switch(t){case"d":return X(q.date,e);case"do":return n.ordinalNumber(e,{unit:"date"});default:return ee(t.length,e)}}},{key:"validate",value:function(e,t){var n=e.getUTCFullYear(),r=ie(n),i=e.getUTCMonth();return r?t>=1&&t<=qn[i]:t>=1&&t<=Kn[i]}},{key:"set",value:function(e,t,n){return e.setUTCDate(n),e.setUTCHours(0,0,0,0),e}}]),n}(L);function Yn(e){return Yn="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"===typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Yn(e)}function Xn(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Qn(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Jn(e,t,n){return t&&Qn(e.prototype,t),n&&Qn(e,n),e}function er(e,t){if("function"!==typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&tr(e,t)}function tr(e,t){return tr=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},tr(e,t)}function nr(e){var t=or();return function(){var n,r=sr(e);if(t){var i=sr(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return rr(this,n)}}function rr(e,t){return!t||"object"!==Yn(t)&&"function"!==typeof t?ir(e):t}function ir(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function or(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}function sr(e){return sr=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},sr(e)}function ar(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var lr=function(e){er(n,e);var t=nr(n);function n(){var e;Xn(this,n);for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];return e=t.call.apply(t,[this].concat(i)),ar(ir(e),"priority",90),ar(ir(e),"subpriority",1),ar(ir(e),"incompatibleTokens",["Y","R","q","Q","M","L","w","I","d","E","i","e","c","t","T"]),e}return Jn(n,[{key:"parse",value:function(e,t,n){switch(t){case"D":case"DD":return X(q.dayOfYear,e);case"Do":return n.ordinalNumber(e,{unit:"date"});default:return ee(t.length,e)}}},{key:"validate",value:function(e,t){var n=e.getUTCFullYear(),r=ie(n);return r?t>=1&&t<=366:t>=1&&t<=365}},{key:"set",value:function(e,t,n){return e.setUTCMonth(0,n),e.setUTCHours(0,0,0,0),e}}]),n}(L),cr=n(18667);function ur(e,t,n){var r,i,s,a,l,c,f,d;(0,h.Z)(2,arguments);var p=(0,cr.j)(),g=(0,u.Z)(null!==(r=null!==(i=null!==(s=null!==(a=null===n||void 0===n?void 0:n.weekStartsOn)&&void 0!==a?a:null===n||void 0===n||null===(l=n.locale)||void 0===l||null===(c=l.options)||void 0===c?void 0:c.weekStartsOn)&&void 0!==s?s:p.weekStartsOn)&&void 0!==i?i:null===(f=p.locale)||void 0===f||null===(d=f.options)||void 0===d?void 0:d.weekStartsOn)&&void 0!==r?r:0);if(!(g>=0&&g<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");var m=(0,o.Z)(e),v=(0,u.Z)(t),y=m.getUTCDay(),w=v%7,b=(w+7)%7,x=(b<g?7:0)+v-y;return m.setUTCDate(m.getUTCDate()+x),m}function hr(e){return hr="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"===typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},hr(e)}function fr(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function dr(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function pr(e,t,n){return t&&dr(e.prototype,t),n&&dr(e,n),e}function gr(e,t){if("function"!==typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&mr(e,t)}function mr(e,t){return mr=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},mr(e,t)}function vr(e){var t=br();return function(){var n,r=xr(e);if(t){var i=xr(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return yr(this,n)}}function yr(e,t){return!t||"object"!==hr(t)&&"function"!==typeof t?wr(e):t}function wr(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function br(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}function xr(e){return xr=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},xr(e)}function Sr(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var _r=function(e){gr(n,e);var t=vr(n);function n(){var e;fr(this,n);for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];return e=t.call.apply(t,[this].concat(i)),Sr(wr(e),"priority",90),Sr(wr(e),"incompatibleTokens",["D","i","e","c","t","T"]),e}return pr(n,[{key:"parse",value:function(e,t,n){switch(t){case"E":case"EE":case"EEE":return n.day(e,{width:"abbreviated",context:"formatting"})||n.day(e,{width:"short",context:"formatting"})||n.day(e,{width:"narrow",context:"formatting"});case"EEEEE":return n.day(e,{width:"narrow",context:"formatting"});case"EEEEEE":return n.day(e,{width:"short",context:"formatting"})||n.day(e,{width:"narrow",context:"formatting"});case"EEEE":default:return n.day(e,{width:"wide",context:"formatting"})||n.day(e,{width:"abbreviated",context:"formatting"})||n.day(e,{width:"short",context:"formatting"})||n.day(e,{width:"narrow",context:"formatting"})}}},{key:"validate",value:function(e,t){return t>=0&&t<=6}},{key:"set",value:function(e,t,n,r){return e=ur(e,n,r),e.setUTCHours(0,0,0,0),e}}]),n}(L);function kr(e){return kr="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"===typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},kr(e)}function Cr(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function $r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Ar(e,t,n){return t&&$r(e.prototype,t),n&&$r(e,n),e}function Rr(e,t){if("function"!==typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Tr(e,t)}function Tr(e,t){return Tr=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},Tr(e,t)}function Er(e){var t=Or();return function(){var n,r=Ir(e);if(t){var i=Ir(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Lr(this,n)}}function Lr(e,t){return!t||"object"!==kr(t)&&"function"!==typeof t?Mr(e):t}function Mr(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function Or(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}function Ir(e){return Ir=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},Ir(e)}function Pr(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Dr=function(e){Rr(n,e);var t=Er(n);function n(){var e;Cr(this,n);for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];return e=t.call.apply(t,[this].concat(i)),Pr(Mr(e),"priority",90),Pr(Mr(e),"incompatibleTokens",["y","R","u","q","Q","M","L","I","d","D","E","i","c","t","T"]),e}return Ar(n,[{key:"parse",value:function(e,t,n,r){var i=function(e){var t=7*Math.floor((e-1)/7);return(e+r.weekStartsOn+6)%7+t};switch(t){case"e":case"ee":return Y(ee(t.length,e),i);case"eo":return Y(n.ordinalNumber(e,{unit:"day"}),i);case"eee":return n.day(e,{width:"abbreviated",context:"formatting"})||n.day(e,{width:"short",context:"formatting"})||n.day(e,{width:"narrow",context:"formatting"});case"eeeee":return n.day(e,{width:"narrow",context:"formatting"});case"eeeeee":return n.day(e,{width:"short",context:"formatting"})||n.day(e,{width:"narrow",context:"formatting"});case"eeee":default:return n.day(e,{width:"wide",context:"formatting"})||n.day(e,{width:"abbreviated",context:"formatting"})||n.day(e,{width:"short",context:"formatting"})||n.day(e,{width:"narrow",context:"formatting"})}}},{key:"validate",value:function(e,t){return t>=0&&t<=6}},{key:"set",value:function(e,t,n,r){return e=ur(e,n,r),e.setUTCHours(0,0,0,0),e}}]),n}(L);function Fr(e){return Fr="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"===typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Fr(e)}function Br(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Wr(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Nr(e,t,n){return t&&Wr(e.prototype,t),n&&Wr(e,n),e}function Hr(e,t){if("function"!==typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&jr(e,t)}function jr(e,t){return jr=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},jr(e,t)}function zr(e){var t=Gr();return function(){var n,r=Kr(e);if(t){var i=Kr(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Ur(this,n)}}function Ur(e,t){return!t||"object"!==Fr(t)&&"function"!==typeof t?Vr(e):t}function Vr(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function Gr(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}function Kr(e){return Kr=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},Kr(e)}function qr(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Zr=function(e){Hr(n,e);var t=zr(n);function n(){var e;Br(this,n);for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];return e=t.call.apply(t,[this].concat(i)),qr(Vr(e),"priority",90),qr(Vr(e),"incompatibleTokens",["y","R","u","q","Q","M","L","I","d","D","E","i","e","t","T"]),e}return Nr(n,[{key:"parse",value:function(e,t,n,r){var i=function(e){var t=7*Math.floor((e-1)/7);return(e+r.weekStartsOn+6)%7+t};switch(t){case"c":case"cc":return Y(ee(t.length,e),i);case"co":return Y(n.ordinalNumber(e,{unit:"day"}),i);case"ccc":return n.day(e,{width:"abbreviated",context:"standalone"})||n.day(e,{width:"short",context:"standalone"})||n.day(e,{width:"narrow",context:"standalone"});case"ccccc":return n.day(e,{width:"narrow",context:"standalone"});case"cccccc":return n.day(e,{width:"short",context:"standalone"})||n.day(e,{width:"narrow",context:"standalone"});case"cccc":default:return n.day(e,{width:"wide",context:"standalone"})||n.day(e,{width:"abbreviated",context:"standalone"})||n.day(e,{width:"short",context:"standalone"})||n.day(e,{width:"narrow",context:"standalone"})}}},{key:"validate",value:function(e,t){return t>=0&&t<=6}},{key:"set",value:function(e,t,n,r){return e=ur(e,n,r),e.setUTCHours(0,0,0,0),e}}]),n}(L);function Yr(e,t){(0,h.Z)(2,arguments);var n=(0,u.Z)(t);n%7===0&&(n-=7);var r=1,i=(0,o.Z)(e),s=i.getUTCDay(),a=n%7,l=(a+7)%7,c=(l<r?7:0)+n-s;return i.setUTCDate(i.getUTCDate()+c),i}function Xr(e){return Xr="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"===typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Xr(e)}function Qr(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Jr(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function ei(e,t,n){return t&&Jr(e.prototype,t),n&&Jr(e,n),e}function ti(e,t){if("function"!==typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&ni(e,t)}function ni(e,t){return ni=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},ni(e,t)}function ri(e){var t=si();return function(){var n,r=ai(e);if(t){var i=ai(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return ii(this,n)}}function ii(e,t){return!t||"object"!==Xr(t)&&"function"!==typeof t?oi(e):t}function oi(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function si(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}function ai(e){return ai=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},ai(e)}function li(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var ci=function(e){ti(n,e);var t=ri(n);function n(){var e;Qr(this,n);for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];return e=t.call.apply(t,[this].concat(i)),li(oi(e),"priority",90),li(oi(e),"incompatibleTokens",["y","Y","u","q","Q","M","L","w","d","D","E","e","c","t","T"]),e}return ei(n,[{key:"parse",value:function(e,t,n){var r=function(e){return 0===e?7:e};switch(t){case"i":case"ii":return ee(t.length,e);case"io":return n.ordinalNumber(e,{unit:"day"});case"iii":return Y(n.day(e,{width:"abbreviated",context:"formatting"})||n.day(e,{width:"short",context:"formatting"})||n.day(e,{width:"narrow",context:"formatting"}),r);case"iiiii":return Y(n.day(e,{width:"narrow",context:"formatting"}),r);case"iiiiii":return Y(n.day(e,{width:"short",context:"formatting"})||n.day(e,{width:"narrow",context:"formatting"}),r);case"iiii":default:return Y(n.day(e,{width:"wide",context:"formatting"})||n.day(e,{width:"abbreviated",context:"formatting"})||n.day(e,{width:"short",context:"formatting"})||n.day(e,{width:"narrow",context:"formatting"}),r)}}},{key:"validate",value:function(e,t){return t>=1&&t<=7}},{key:"set",value:function(e,t,n){return e=Yr(e,n),e.setUTCHours(0,0,0,0),e}}]),n}(L);function ui(e){return ui="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"===typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},ui(e)}function hi(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function fi(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function di(e,t,n){return t&&fi(e.prototype,t),n&&fi(e,n),e}function pi(e,t){if("function"!==typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&gi(e,t)}function gi(e,t){return gi=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},gi(e,t)}function mi(e){var t=wi();return function(){var n,r=bi(e);if(t){var i=bi(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return vi(this,n)}}function vi(e,t){return!t||"object"!==ui(t)&&"function"!==typeof t?yi(e):t}function yi(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function wi(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}function bi(e){return bi=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},bi(e)}function xi(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Si=function(e){pi(n,e);var t=mi(n);function n(){var e;hi(this,n);for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];return e=t.call.apply(t,[this].concat(i)),xi(yi(e),"priority",80),xi(yi(e),"incompatibleTokens",["b","B","H","k","t","T"]),e}return di(n,[{key:"parse",value:function(e,t,n){switch(t){case"a":case"aa":case"aaa":return n.dayPeriod(e,{width:"abbreviated",context:"formatting"})||n.dayPeriod(e,{width:"narrow",context:"formatting"});case"aaaaa":return n.dayPeriod(e,{width:"narrow",context:"formatting"});case"aaaa":default:return n.dayPeriod(e,{width:"wide",context:"formatting"})||n.dayPeriod(e,{width:"abbreviated",context:"formatting"})||n.dayPeriod(e,{width:"narrow",context:"formatting"})}}},{key:"set",value:function(e,t,n){return e.setUTCHours(ne(n),0,0,0),e}}]),n}(L);function _i(e){return _i="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"===typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},_i(e)}function ki(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Ci(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function $i(e,t,n){return t&&Ci(e.prototype,t),n&&Ci(e,n),e}function Ai(e,t){if("function"!==typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Ri(e,t)}function Ri(e,t){return Ri=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},Ri(e,t)}function Ti(e){var t=Mi();return function(){var n,r=Oi(e);if(t){var i=Oi(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Ei(this,n)}}function Ei(e,t){return!t||"object"!==_i(t)&&"function"!==typeof t?Li(e):t}function Li(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function Mi(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}function Oi(e){return Oi=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},Oi(e)}function Ii(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Pi=function(e){Ai(n,e);var t=Ti(n);function n(){var e;ki(this,n);for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];return e=t.call.apply(t,[this].concat(i)),Ii(Li(e),"priority",80),Ii(Li(e),"incompatibleTokens",["a","B","H","k","t","T"]),e}return $i(n,[{key:"parse",value:function(e,t,n){switch(t){case"b":case"bb":case"bbb":return n.dayPeriod(e,{width:"abbreviated",context:"formatting"})||n.dayPeriod(e,{width:"narrow",context:"formatting"});case"bbbbb":return n.dayPeriod(e,{width:"narrow",context:"formatting"});case"bbbb":default:return n.dayPeriod(e,{width:"wide",context:"formatting"})||n.dayPeriod(e,{width:"abbreviated",context:"formatting"})||n.dayPeriod(e,{width:"narrow",context:"formatting"})}}},{key:"set",value:function(e,t,n){return e.setUTCHours(ne(n),0,0,0),e}}]),n}(L);function Di(e){return Di="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"===typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Di(e)}function Fi(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Bi(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Wi(e,t,n){return t&&Bi(e.prototype,t),n&&Bi(e,n),e}function Ni(e,t){if("function"!==typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Hi(e,t)}function Hi(e,t){return Hi=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},Hi(e,t)}function ji(e){var t=Vi();return function(){var n,r=Gi(e);if(t){var i=Gi(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return zi(this,n)}}function zi(e,t){return!t||"object"!==Di(t)&&"function"!==typeof t?Ui(e):t}function Ui(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function Vi(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}function Gi(e){return Gi=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},Gi(e)}function Ki(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var qi=function(e){Ni(n,e);var t=ji(n);function n(){var e;Fi(this,n);for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];return e=t.call.apply(t,[this].concat(i)),Ki(Ui(e),"priority",80),Ki(Ui(e),"incompatibleTokens",["a","b","t","T"]),e}return Wi(n,[{key:"parse",value:function(e,t,n){switch(t){case"B":case"BB":case"BBB":return n.dayPeriod(e,{width:"abbreviated",context:"formatting"})||n.dayPeriod(e,{width:"narrow",context:"formatting"});case"BBBBB":return n.dayPeriod(e,{width:"narrow",context:"formatting"});case"BBBB":default:return n.dayPeriod(e,{width:"wide",context:"formatting"})||n.dayPeriod(e,{width:"abbreviated",context:"formatting"})||n.dayPeriod(e,{width:"narrow",context:"formatting"})}}},{key:"set",value:function(e,t,n){return e.setUTCHours(ne(n),0,0,0),e}}]),n}(L);function Zi(e){return Zi="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"===typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Zi(e)}function Yi(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Xi(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Qi(e,t,n){return t&&Xi(e.prototype,t),n&&Xi(e,n),e}function Ji(e,t){if("function"!==typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&eo(e,t)}function eo(e,t){return eo=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},eo(e,t)}function to(e){var t=io();return function(){var n,r=oo(e);if(t){var i=oo(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return no(this,n)}}function no(e,t){return!t||"object"!==Zi(t)&&"function"!==typeof t?ro(e):t}function ro(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function io(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}function oo(e){return oo=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},oo(e)}function so(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var ao=function(e){Ji(n,e);var t=to(n);function n(){var e;Yi(this,n);for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];return e=t.call.apply(t,[this].concat(i)),so(ro(e),"priority",70),so(ro(e),"incompatibleTokens",["H","K","k","t","T"]),e}return Qi(n,[{key:"parse",value:function(e,t,n){switch(t){case"h":return X(q.hour12h,e);case"ho":return n.ordinalNumber(e,{unit:"hour"});default:return ee(t.length,e)}}},{key:"validate",value:function(e,t){return t>=1&&t<=12}},{key:"set",value:function(e,t,n){var r=e.getUTCHours()>=12;return r&&n<12?e.setUTCHours(n+12,0,0,0):r||12!==n?e.setUTCHours(n,0,0,0):e.setUTCHours(0,0,0,0),e}}]),n}(L);function lo(e){return lo="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"===typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},lo(e)}function co(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function uo(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function ho(e,t,n){return t&&uo(e.prototype,t),n&&uo(e,n),e}function fo(e,t){if("function"!==typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&po(e,t)}function po(e,t){return po=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},po(e,t)}function go(e){var t=yo();return function(){var n,r=wo(e);if(t){var i=wo(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return mo(this,n)}}function mo(e,t){return!t||"object"!==lo(t)&&"function"!==typeof t?vo(e):t}function vo(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function yo(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}function wo(e){return wo=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},wo(e)}function bo(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var xo=function(e){fo(n,e);var t=go(n);function n(){var e;co(this,n);for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];return e=t.call.apply(t,[this].concat(i)),bo(vo(e),"priority",70),bo(vo(e),"incompatibleTokens",["a","b","h","K","k","t","T"]),e}return ho(n,[{key:"parse",value:function(e,t,n){switch(t){case"H":return X(q.hour23h,e);case"Ho":return n.ordinalNumber(e,{unit:"hour"});default:return ee(t.length,e)}}},{key:"validate",value:function(e,t){return t>=0&&t<=23}},{key:"set",value:function(e,t,n){return e.setUTCHours(n,0,0,0),e}}]),n}(L);function So(e){return So="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"===typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},So(e)}function _o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function ko(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Co(e,t,n){return t&&ko(e.prototype,t),n&&ko(e,n),e}function $o(e,t){if("function"!==typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Ao(e,t)}function Ao(e,t){return Ao=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},Ao(e,t)}function Ro(e){var t=Lo();return function(){var n,r=Mo(e);if(t){var i=Mo(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return To(this,n)}}function To(e,t){return!t||"object"!==So(t)&&"function"!==typeof t?Eo(e):t}function Eo(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function Lo(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}function Mo(e){return Mo=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},Mo(e)}function Oo(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Io=function(e){$o(n,e);var t=Ro(n);function n(){var e;_o(this,n);for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];return e=t.call.apply(t,[this].concat(i)),Oo(Eo(e),"priority",70),Oo(Eo(e),"incompatibleTokens",["h","H","k","t","T"]),e}return Co(n,[{key:"parse",value:function(e,t,n){switch(t){case"K":return X(q.hour11h,e);case"Ko":return n.ordinalNumber(e,{unit:"hour"});default:return ee(t.length,e)}}},{key:"validate",value:function(e,t){return t>=0&&t<=11}},{key:"set",value:function(e,t,n){var r=e.getUTCHours()>=12;return r&&n<12?e.setUTCHours(n+12,0,0,0):e.setUTCHours(n,0,0,0),e}}]),n}(L);function Po(e){return Po="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"===typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Po(e)}function Do(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Fo(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Bo(e,t,n){return t&&Fo(e.prototype,t),n&&Fo(e,n),e}function Wo(e,t){if("function"!==typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&No(e,t)}function No(e,t){return No=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},No(e,t)}function Ho(e){var t=Uo();return function(){var n,r=Vo(e);if(t){var i=Vo(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return jo(this,n)}}function jo(e,t){return!t||"object"!==Po(t)&&"function"!==typeof t?zo(e):t}function zo(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function Uo(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}function Vo(e){return Vo=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},Vo(e)}function Go(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Ko=function(e){Wo(n,e);var t=Ho(n);function n(){var e;Do(this,n);for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];return e=t.call.apply(t,[this].concat(i)),Go(zo(e),"priority",70),Go(zo(e),"incompatibleTokens",["a","b","h","H","K","t","T"]),e}return Bo(n,[{key:"parse",value:function(e,t,n){switch(t){case"k":return X(q.hour24h,e);case"ko":return n.ordinalNumber(e,{unit:"hour"});default:return ee(t.length,e)}}},{key:"validate",value:function(e,t){return t>=1&&t<=24}},{key:"set",value:function(e,t,n){var r=n<=24?n%24:n;return e.setUTCHours(r,0,0,0),e}}]),n}(L);function qo(e){return qo="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"===typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},qo(e)}function Zo(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Yo(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Xo(e,t,n){return t&&Yo(e.prototype,t),n&&Yo(e,n),e}function Qo(e,t){if("function"!==typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Jo(e,t)}function Jo(e,t){return Jo=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},Jo(e,t)}function es(e){var t=rs();return function(){var n,r=is(e);if(t){var i=is(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return ts(this,n)}}function ts(e,t){return!t||"object"!==qo(t)&&"function"!==typeof t?ns(e):t}function ns(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function rs(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}function is(e){return is=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},is(e)}function os(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var ss=function(e){Qo(n,e);var t=es(n);function n(){var e;Zo(this,n);for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];return e=t.call.apply(t,[this].concat(i)),os(ns(e),"priority",60),os(ns(e),"incompatibleTokens",["t","T"]),e}return Xo(n,[{key:"parse",value:function(e,t,n){switch(t){case"m":return X(q.minute,e);case"mo":return n.ordinalNumber(e,{unit:"minute"});default:return ee(t.length,e)}}},{key:"validate",value:function(e,t){return t>=0&&t<=59}},{key:"set",value:function(e,t,n){return e.setUTCMinutes(n,0,0),e}}]),n}(L);function as(e){return as="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"===typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},as(e)}function ls(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function cs(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function us(e,t,n){return t&&cs(e.prototype,t),n&&cs(e,n),e}function hs(e,t){if("function"!==typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&fs(e,t)}function fs(e,t){return fs=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},fs(e,t)}function ds(e){var t=ms();return function(){var n,r=vs(e);if(t){var i=vs(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return ps(this,n)}}function ps(e,t){return!t||"object"!==as(t)&&"function"!==typeof t?gs(e):t}function gs(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function ms(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}function vs(e){return vs=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},vs(e)}function ys(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var ws=function(e){hs(n,e);var t=ds(n);function n(){var e;ls(this,n);for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];return e=t.call.apply(t,[this].concat(i)),ys(gs(e),"priority",50),ys(gs(e),"incompatibleTokens",["t","T"]),e}return us(n,[{key:"parse",value:function(e,t,n){switch(t){case"s":return X(q.second,e);case"so":return n.ordinalNumber(e,{unit:"second"});default:return ee(t.length,e)}}},{key:"validate",value:function(e,t){return t>=0&&t<=59}},{key:"set",value:function(e,t,n){return e.setUTCSeconds(n,0),e}}]),n}(L);function bs(e){return bs="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"===typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},bs(e)}function xs(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Ss(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function _s(e,t,n){return t&&Ss(e.prototype,t),n&&Ss(e,n),e}function ks(e,t){if("function"!==typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Cs(e,t)}function Cs(e,t){return Cs=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},Cs(e,t)}function $s(e){var t=Ts();return function(){var n,r=Es(e);if(t){var i=Es(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return As(this,n)}}function As(e,t){return!t||"object"!==bs(t)&&"function"!==typeof t?Rs(e):t}function Rs(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function Ts(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}function Es(e){return Es=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},Es(e)}function Ls(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Ms=function(e){ks(n,e);var t=$s(n);function n(){var e;xs(this,n);for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];return e=t.call.apply(t,[this].concat(i)),Ls(Rs(e),"priority",30),Ls(Rs(e),"incompatibleTokens",["t","T"]),e}return _s(n,[{key:"parse",value:function(e,t){var n=function(e){return Math.floor(e*Math.pow(10,3-t.length))};return Y(ee(t.length,e),n)}},{key:"set",value:function(e,t,n){return e.setUTCMilliseconds(n),e}}]),n}(L);function Os(e){return Os="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"===typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Os(e)}function Is(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Ps(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Ds(e,t,n){return t&&Ps(e.prototype,t),n&&Ps(e,n),e}function Fs(e,t){if("function"!==typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Bs(e,t)}function Bs(e,t){return Bs=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},Bs(e,t)}function Ws(e){var t=js();return function(){var n,r=zs(e);if(t){var i=zs(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Ns(this,n)}}function Ns(e,t){return!t||"object"!==Os(t)&&"function"!==typeof t?Hs(e):t}function Hs(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function js(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}function zs(e){return zs=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},zs(e)}function Us(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Vs=function(e){Fs(n,e);var t=Ws(n);function n(){var e;Is(this,n);for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];return e=t.call.apply(t,[this].concat(i)),Us(Hs(e),"priority",10),Us(Hs(e),"incompatibleTokens",["t","T","x"]),e}return Ds(n,[{key:"parse",value:function(e,t){switch(t){case"X":return Q(Z.basicOptionalMinutes,e);case"XX":return Q(Z.basic,e);case"XXXX":return Q(Z.basicOptionalSeconds,e);case"XXXXX":return Q(Z.extendedOptionalSeconds,e);case"XXX":default:return Q(Z.extended,e)}}},{key:"set",value:function(e,t,n){return t.timestampIsSet?e:new Date(e.getTime()-n)}}]),n}(L);function Gs(e){return Gs="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"===typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Gs(e)}function Ks(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function qs(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Zs(e,t,n){return t&&qs(e.prototype,t),n&&qs(e,n),e}function Ys(e,t){if("function"!==typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Xs(e,t)}function Xs(e,t){return Xs=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},Xs(e,t)}function Qs(e){var t=ta();return function(){var n,r=na(e);if(t){var i=na(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Js(this,n)}}function Js(e,t){return!t||"object"!==Gs(t)&&"function"!==typeof t?ea(e):t}function ea(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function ta(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}function na(e){return na=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},na(e)}function ra(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var ia=function(e){Ys(n,e);var t=Qs(n);function n(){var e;Ks(this,n);for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];return e=t.call.apply(t,[this].concat(i)),ra(ea(e),"priority",10),ra(ea(e),"incompatibleTokens",["t","T","X"]),e}return Zs(n,[{key:"parse",value:function(e,t){switch(t){case"x":return Q(Z.basicOptionalMinutes,e);case"xx":return Q(Z.basic,e);case"xxxx":return Q(Z.basicOptionalSeconds,e);case"xxxxx":return Q(Z.extendedOptionalSeconds,e);case"xxx":default:return Q(Z.extended,e)}}},{key:"set",value:function(e,t,n){return t.timestampIsSet?e:new Date(e.getTime()-n)}}]),n}(L);function oa(e){return oa="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"===typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},oa(e)}function sa(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function aa(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function la(e,t,n){return t&&aa(e.prototype,t),n&&aa(e,n),e}function ca(e,t){if("function"!==typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&ua(e,t)}function ua(e,t){return ua=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},ua(e,t)}function ha(e){var t=pa();return function(){var n,r=ga(e);if(t){var i=ga(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return fa(this,n)}}function fa(e,t){return!t||"object"!==oa(t)&&"function"!==typeof t?da(e):t}function da(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function pa(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}function ga(e){return ga=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},ga(e)}function ma(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var va=function(e){ca(n,e);var t=ha(n);function n(){var e;sa(this,n);for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];return e=t.call.apply(t,[this].concat(i)),ma(da(e),"priority",40),ma(da(e),"incompatibleTokens","*"),e}return la(n,[{key:"parse",value:function(e){return J(e)}},{key:"set",value:function(e,t,n){return[new Date(1e3*n),{timestampIsSet:!0}]}}]),n}(L);function ya(e){return ya="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"===typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},ya(e)}function wa(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function ba(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function xa(e,t,n){return t&&ba(e.prototype,t),n&&ba(e,n),e}function Sa(e,t){if("function"!==typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&_a(e,t)}function _a(e,t){return _a=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},_a(e,t)}function ka(e){var t=Aa();return function(){var n,r=Ra(e);if(t){var i=Ra(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Ca(this,n)}}function Ca(e,t){return!t||"object"!==ya(t)&&"function"!==typeof t?$a(e):t}function $a(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function Aa(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}function Ra(e){return Ra=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},Ra(e)}function Ta(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Ea=function(e){Sa(n,e);var t=ka(n);function n(){var e;wa(this,n);for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];return e=t.call.apply(t,[this].concat(i)),Ta($a(e),"priority",20),Ta($a(e),"incompatibleTokens","*"),e}return xa(n,[{key:"parse",value:function(e){return J(e)}},{key:"set",value:function(e,t,n){return[new Date(n),{timestampIsSet:!0}]}}]),n}(L),La={G:new U,y:new ve,Y:new Me,R:new Ge,u:new ot,Q:new yt,q:new Lt,M:new Ut,L:new rn,w:new wn,I:new In,d:new Zn,D:new lr,E:new _r,e:new Dr,c:new Zr,i:new ci,a:new Si,b:new Pi,B:new qi,h:new ao,H:new xo,K:new Io,k:new Ko,m:new ss,s:new ws,S:new Ms,X:new Vs,x:new ia,t:new va,T:new Ea};function Ma(e){return Ma="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"===typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Ma(e)}function Oa(e,t){var n;if("undefined"===typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(n=Ia(e))||t&&e&&"number"===typeof e.length){n&&(e=n);var r=0,i=function(){};return{s:i,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,s=!0,a=!1;return{s:function(){n=e[Symbol.iterator]()},n:function(){var e=n.next();return s=e.done,e},e:function(e){a=!0,o=e},f:function(){try{s||null==n.return||n.return()}finally{if(a)throw o}}}}function Ia(e,t){if(e){if("string"===typeof e)return Pa(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?Pa(e,t):void 0}}function Pa(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var Da=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,Fa=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,Ba=/^'([^]*?)'?$/,Wa=/''/g,Na=/\S/,Ha=/[a-zA-Z]/;function ja(e,t,n,f){var d,p,g,m,v,y,w,b,x,S,_,k,C,$,R,T,E,L;(0,h.Z)(3,arguments);var M=String(e),O=String(t),I=(0,cr.j)(),P=null!==(d=null!==(p=null===f||void 0===f?void 0:f.locale)&&void 0!==p?p:I.locale)&&void 0!==d?d:r.Z;if(!P.match)throw new RangeError("locale must contain match property");var D=(0,u.Z)(null!==(g=null!==(m=null!==(v=null!==(y=null===f||void 0===f?void 0:f.firstWeekContainsDate)&&void 0!==y?y:null===f||void 0===f||null===(w=f.locale)||void 0===w||null===(b=w.options)||void 0===b?void 0:b.firstWeekContainsDate)&&void 0!==v?v:I.firstWeekContainsDate)&&void 0!==m?m:null===(x=I.locale)||void 0===x||null===(S=x.options)||void 0===S?void 0:S.firstWeekContainsDate)&&void 0!==g?g:1);if(!(D>=1&&D<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var F=(0,u.Z)(null!==(_=null!==(k=null!==(C=null!==($=null===f||void 0===f?void 0:f.weekStartsOn)&&void 0!==$?$:null===f||void 0===f||null===(R=f.locale)||void 0===R||null===(T=R.options)||void 0===T?void 0:T.weekStartsOn)&&void 0!==C?C:I.weekStartsOn)&&void 0!==k?k:null===(E=I.locale)||void 0===E||null===(L=E.options)||void 0===L?void 0:L.weekStartsOn)&&void 0!==_?_:0);if(!(F>=0&&F<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");if(""===O)return""===M?(0,o.Z)(n):new Date(NaN);var B,W={firstWeekContainsDate:D,weekStartsOn:F,locale:P},N=[new A],H=O.match(Fa).map((function(e){var t=e[0];if(t in a.Z){var n=a.Z[t];return n(e,P.formatLong)}return e})).join("").match(Da),j=[],z=Oa(H);try{var U=function(){var t=B.value;null!==f&&void 0!==f&&f.useAdditionalWeekYearTokens||!(0,c.Do)(t)||(0,c.qp)(t,O,e),null!==f&&void 0!==f&&f.useAdditionalDayOfYearTokens||!(0,c.Iu)(t)||(0,c.qp)(t,O,e);var n=t[0],r=La[n];if(r){var i=r.incompatibleTokens;if(Array.isArray(i)){var o=j.find((function(e){return i.includes(e.token)||e.token===n}));if(o)throw new RangeError("The format string mustn't contain `".concat(o.fullToken,"` and `").concat(t,"` at the same time"))}else if("*"===r.incompatibleTokens&&j.length>0)throw new RangeError("The format string mustn't contain `".concat(t,"` and any other token at the same time"));j.push({token:n,fullToken:t});var s=r.run(M,t,P.match,W);if(!s)return{v:new Date(NaN)};N.push(s.setter),M=s.rest}else{if(n.match(Ha))throw new RangeError("Format string contains an unescaped latin alphabet character `"+n+"`");if("''"===t?t="'":"'"===n&&(t=za(t)),0!==M.indexOf(t))return{v:new Date(NaN)};M=M.slice(t.length)}};for(z.s();!(B=z.n()).done;){var V=U();if("object"===Ma(V))return V.v}}catch(ee){z.e(ee)}finally{z.f()}if(M.length>0&&Na.test(M))return new Date(NaN);var G=N.map((function(e){return e.priority})).sort((function(e,t){return t-e})).filter((function(e,t,n){return n.indexOf(e)===t})).map((function(e){return N.filter((function(t){return t.priority===e})).sort((function(e,t){return t.subPriority-e.subPriority}))})).map((function(e){return e[0]})),K=(0,o.Z)(n);if(isNaN(K.getTime()))return new Date(NaN);var q,Z=(0,i.Z)(K,(0,l.Z)(K)),Y={},X=Oa(G);try{for(X.s();!(q=X.n()).done;){var Q=q.value;if(!Q.validate(Z,W))return new Date(NaN);var J=Q.set(Z,Y,W);Array.isArray(J)?(Z=J[0],s(Y,J[1])):Z=J}}catch(ee){X.e(ee)}finally{X.f()}return Z}function za(e){return e.match(Ba)[1].replace(Wa,"'")}},59800:function(e,t,n){"use strict";n.d(t,{Z:function(){return h}});var r=n(42765),i=n(66700),o=n(19785);function s(e,t){(0,o.Z)(2,arguments);var n=(0,i.Z)(e),s=(0,r.Z)(t);return isNaN(s)?new Date(NaN):s?(n.setDate(n.getDate()+s),n):n}function a(e,t){(0,o.Z)(2,arguments);var n=(0,r.Z)(t);return s(e,-n)}function l(e,t){(0,o.Z)(2,arguments);var n=(0,i.Z)(e),s=(0,r.Z)(t);if(isNaN(s))return new Date(NaN);if(!s)return n;var a=n.getDate(),l=new Date(n.getTime());l.setMonth(n.getMonth()+s+1,0);var c=l.getDate();return a>=c?l:(n.setFullYear(l.getFullYear(),l.getMonth(),a),n)}function c(e,t){(0,o.Z)(2,arguments);var n=(0,r.Z)(t);return l(e,-n)}function u(e){return u="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"===typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},u(e)}function h(e,t){if((0,o.Z)(2,arguments),!t||"object"!==u(t))return new Date(NaN);var n=t.years?(0,r.Z)(t.years):0,i=t.months?(0,r.Z)(t.months):0,s=t.weeks?(0,r.Z)(t.weeks):0,l=t.days?(0,r.Z)(t.days):0,h=t.hours?(0,r.Z)(t.hours):0,f=t.minutes?(0,r.Z)(t.minutes):0,d=t.seconds?(0,r.Z)(t.seconds):0,p=c(e,i+12*n),g=a(p,l+7*s),m=f+60*h,v=d+60*m,y=1e3*v,w=new Date(g.getTime()-y);return w}},89248:function(e,t,n){"use strict";n.d(t,{Z:function(){return a}});var r=n(42765),i=n(66700),o=n(19785);function s(e,t){(0,o.Z)(2,arguments);var n=(0,i.Z)(e).getTime(),s=(0,r.Z)(t);return new Date(n+s)}function a(e,t){(0,o.Z)(2,arguments);var n=(0,r.Z)(t);return s(e,-n)}},66700:function(e,t,n){"use strict";n.d(t,{Z:function(){return o}});var r=n(19785);function i(e){return i="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"===typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},i(e)}function o(e){(0,r.Z)(1,arguments);var t=Object.prototype.toString.call(e);return e instanceof Date||"object"===i(e)&&"[object Date]"===t?new Date(e.getTime()):"number"===typeof e||"[object Number]"===t?new Date(e):("string"!==typeof e&&"[object String]"!==t||"undefined"===typeof console||(console.warn("Starting with v2.0.0-beta.1 date-fns doesn't accept strings as date arguments. Please use `parseISO` to parse strings. See: https://github.com/date-fns/date-fns/blob/master/docs/upgradeGuide.md#string-arguments"),console.warn((new Error).stack)),new Date(NaN))}},50857:function(e,t,n){var r=n(37772),i=r.Symbol;e.exports=i},50343:function(e){function t(e,t){var n=-1,r=null==e?0:e.length,i=Array(r);while(++n<r)i[n]=t(e[n],n,e);return i}e.exports=t},81207:function(e){function t(e,t,n,r){var i=-1,o=null==e?0:e.length;r&&o&&(n=e[++i]);while(++i<o)n=t(n,e[i],i,e);return n}e.exports=t},50217:function(e){function t(e){return e.split("")}e.exports=t},45981:function(e){var t=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g;function n(e){return e.match(t)||[]}e.exports=n},53366:function(e,t,n){var r=n(50857),i=n(62107),o=n(37157),s="[object Null]",a="[object Undefined]",l=r?r.toStringTag:void 0;function c(e){return null==e?void 0===e?a:s:l&&l in Object(e)?i(e):o(e)}e.exports=c},6435:function(e){function t(e){return function(t){return null==e?void 0:e[t]}}e.exports=t},39872:function(e){function t(e,t,n){var r=-1,i=e.length;t<0&&(t=-t>i?0:i+t),n=n>i?i:n,n<0&&(n+=i),i=t>n?0:n-t>>>0,t>>>=0;var o=Array(i);while(++r<i)o[r]=e[r+t];return o}e.exports=t},1054:function(e,t,n){var r=n(50857),i=n(50343),o=n(86152),s=n(4795),a=1/0,l=r?r.prototype:void 0,c=l?l.toString:void 0;function u(e){if("string"==typeof e)return e;if(o(e))return i(e,u)+"";if(s(e))return c?c.call(e):"";var t=e+"";return"0"==t&&1/e==-a?"-0":t}e.exports=u},23895:function(e,t,n){var r=n(39872);function i(e,t,n){var i=e.length;return n=void 0===n?i:n,!t&&n>=i?e:r(e,t,n)}e.exports=i},83126:function(e,t,n){var r=n(23895),i=n(33880),o=n(8435),s=n(66188);function a(e){return function(t){t=s(t);var n=i(t)?o(t):void 0,a=n?n[0]:t.charAt(0),l=n?r(n,1).join(""):t.slice(1);return a[e]()+l}}e.exports=a},34311:function(e,t,n){var r=n(81207),i=n(97329),o=n(11618),s="['’]",a=RegExp(s,"g");function l(e){return function(t){return r(o(i(t).replace(a,"")),e,"")}}e.exports=l},61655:function(e,t,n){var r=n(6435),i={"À":"A","Á":"A","Â":"A","Ã":"A","Ä":"A","Å":"A","à":"a","á":"a","â":"a","ã":"a","ä":"a","å":"a","Ç":"C","ç":"c","Ð":"D","ð":"d","È":"E","É":"E","Ê":"E","Ë":"E","è":"e","é":"e","ê":"e","ë":"e","Ì":"I","Í":"I","Î":"I","Ï":"I","ì":"i","í":"i","î":"i","ï":"i","Ñ":"N","ñ":"n","Ò":"O","Ó":"O","Ô":"O","Õ":"O","Ö":"O","Ø":"O","ò":"o","ó":"o","ô":"o","õ":"o","ö":"o","ø":"o","Ù":"U","Ú":"U","Û":"U","Ü":"U","ù":"u","ú":"u","û":"u","ü":"u","Ý":"Y","ý":"y","ÿ":"y","Æ":"Ae","æ":"ae","Þ":"Th","þ":"th","ß":"ss","Ā":"A","Ă":"A","Ą":"A","ā":"a","ă":"a","ą":"a","Ć":"C","Ĉ":"C","Ċ":"C","Č":"C","ć":"c","ĉ":"c","ċ":"c","č":"c","Ď":"D","Đ":"D","ď":"d","đ":"d","Ē":"E","Ĕ":"E","Ė":"E","Ę":"E","Ě":"E","ē":"e","ĕ":"e","ė":"e","ę":"e","ě":"e","Ĝ":"G","Ğ":"G","Ġ":"G","Ģ":"G","ĝ":"g","ğ":"g","ġ":"g","ģ":"g","Ĥ":"H","Ħ":"H","ĥ":"h","ħ":"h","Ĩ":"I","Ī":"I","Ĭ":"I","Į":"I","İ":"I","ĩ":"i","ī":"i","ĭ":"i","į":"i","ı":"i","Ĵ":"J","ĵ":"j","Ķ":"K","ķ":"k","ĸ":"k","Ĺ":"L","Ļ":"L","Ľ":"L","Ŀ":"L","Ł":"L","ĺ":"l","ļ":"l","ľ":"l","ŀ":"l","ł":"l","Ń":"N","Ņ":"N","Ň":"N","Ŋ":"N","ń":"n","ņ":"n","ň":"n","ŋ":"n","Ō":"O","Ŏ":"O","Ő":"O","ō":"o","ŏ":"o","ő":"o","Ŕ":"R","Ŗ":"R","Ř":"R","ŕ":"r","ŗ":"r","ř":"r","Ś":"S","Ŝ":"S","Ş":"S","Š":"S","ś":"s","ŝ":"s","ş":"s","š":"s","Ţ":"T","Ť":"T","Ŧ":"T","ţ":"t","ť":"t","ŧ":"t","Ũ":"U","Ū":"U","Ŭ":"U","Ů":"U","Ű":"U","Ų":"U","ũ":"u","ū":"u","ŭ":"u","ů":"u","ű":"u","ų":"u","Ŵ":"W","ŵ":"w","Ŷ":"Y","ŷ":"y","Ÿ":"Y","Ź":"Z","Ż":"Z","Ž":"Z","ź":"z","ż":"z","ž":"z","IJ":"IJ","ij":"ij","Œ":"Oe","œ":"oe","ʼn":"'n","ſ":"s"},o=r(i);e.exports=o},51242:function(e,t,n){var r="object"==typeof n.g&&n.g&&n.g.Object===Object&&n.g;e.exports=r},62107:function(e,t,n){var r=n(50857),i=Object.prototype,o=i.hasOwnProperty,s=i.toString,a=r?r.toStringTag:void 0;function l(e){var t=o.call(e,a),n=e[a];try{e[a]=void 0;var r=!0}catch(l){}var i=s.call(e);return r&&(t?e[a]=n:delete e[a]),i}e.exports=l},33880:function(e){var t="\\ud800-\\udfff",n="\\u0300-\\u036f",r="\\ufe20-\\ufe2f",i="\\u20d0-\\u20ff",o=n+r+i,s="\\ufe0e\\ufe0f",a="\\u200d",l=RegExp("["+a+t+o+s+"]");function c(e){return l.test(e)}e.exports=c},83559:function(e){var t=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/;function n(e){return t.test(e)}e.exports=n},37157:function(e){var t=Object.prototype,n=t.toString;function r(e){return n.call(e)}e.exports=r},37772:function(e,t,n){var r=n(51242),i="object"==typeof self&&self&&self.Object===Object&&self,o=r||i||Function("return this")();e.exports=o},8435:function(e,t,n){var r=n(50217),i=n(33880),o=n(63344);function s(e){return i(e)?o(e):r(e)}e.exports=s},63344:function(e){var t="\\ud800-\\udfff",n="\\u0300-\\u036f",r="\\ufe20-\\ufe2f",i="\\u20d0-\\u20ff",o=n+r+i,s="\\ufe0e\\ufe0f",a="["+t+"]",l="["+o+"]",c="\\ud83c[\\udffb-\\udfff]",u="(?:"+l+"|"+c+")",h="[^"+t+"]",f="(?:\\ud83c[\\udde6-\\uddff]){2}",d="[\\ud800-\\udbff][\\udc00-\\udfff]",p="\\u200d",g=u+"?",m="["+s+"]?",v="(?:"+p+"(?:"+[h,f,d].join("|")+")"+m+g+")*",y=m+g+v,w="(?:"+[h+l+"?",l,f,d,a].join("|")+")",b=RegExp(c+"(?="+c+")|"+w+y,"g");function x(e){return e.match(b)||[]}e.exports=x},75304:function(e){var t="\\ud800-\\udfff",n="\\u0300-\\u036f",r="\\ufe20-\\ufe2f",i="\\u20d0-\\u20ff",o=n+r+i,s="\\u2700-\\u27bf",a="a-z\\xdf-\\xf6\\xf8-\\xff",l="\\xac\\xb1\\xd7\\xf7",c="\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf",u="\\u2000-\\u206f",h=" \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",f="A-Z\\xc0-\\xd6\\xd8-\\xde",d="\\ufe0e\\ufe0f",p=l+c+u+h,g="['’]",m="["+p+"]",v="["+o+"]",y="\\d+",w="["+s+"]",b="["+a+"]",x="[^"+t+p+y+s+a+f+"]",S="\\ud83c[\\udffb-\\udfff]",_="(?:"+v+"|"+S+")",k="[^"+t+"]",C="(?:\\ud83c[\\udde6-\\uddff]){2}",$="[\\ud800-\\udbff][\\udc00-\\udfff]",A="["+f+"]",R="\\u200d",T="(?:"+b+"|"+x+")",E="(?:"+A+"|"+x+")",L="(?:"+g+"(?:d|ll|m|re|s|t|ve))?",M="(?:"+g+"(?:D|LL|M|RE|S|T|VE))?",O=_+"?",I="["+d+"]?",P="(?:"+R+"(?:"+[k,C,$].join("|")+")"+I+O+")*",D="\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",F="\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])",B=I+O+P,W="(?:"+[w,C,$].join("|")+")"+B,N=RegExp([A+"?"+b+"+"+L+"(?="+[m,A,"$"].join("|")+")",E+"+"+M+"(?="+[m,A+T,"$"].join("|")+")",A+"?"+T+"+"+L,A+"+"+M,F,D,y,W].join("|"),"g");function H(e){return e.match(N)||[]}e.exports=H},96009:function(e,t,n){var r=n(82108),i=n(34311),o=i((function(e,t,n){return t=t.toLowerCase(),e+(n?r(t):t)}));e.exports=o},82108:function(e,t,n){var r=n(66188),i=n(23779);function o(e){return i(r(e).toLowerCase())}e.exports=o},97329:function(e,t,n){var r=n(61655),i=n(66188),o=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,s="\\u0300-\\u036f",a="\\ufe20-\\ufe2f",l="\\u20d0-\\u20ff",c=s+a+l,u="["+c+"]",h=RegExp(u,"g");function f(e){return e=i(e),e&&e.replace(o,r).replace(h,"")}e.exports=f},86152:function(e){var t=Array.isArray;e.exports=t},15125:function(e){function t(e){return null!=e&&"object"==typeof e}e.exports=t},4795:function(e,t,n){var r=n(53366),i=n(15125),o="[object Symbol]";function s(e){return"symbol"==typeof e||i(e)&&r(e)==o}e.exports=s},76635:function(e,t,n){var r;
41
+ /**
42
+ * @license
43
+ * Lodash <https://lodash.com/>
44
+ * Copyright OpenJS Foundation and other contributors <https://openjsf.org/>
45
+ * Released under MIT license <https://lodash.com/license>
46
+ * Based on Underscore.js 1.8.3 <http://underscorejs.org/LICENSE>
47
+ * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors
48
+ */e=n.nmd(e),function(){var i,o="4.17.21",s=200,a="Unsupported core-js use. Try https://npms.io/search?q=ponyfill.",l="Expected a function",c="Invalid `variable` option passed into `_.template`",u="__lodash_hash_undefined__",h=500,f="__lodash_placeholder__",d=1,p=2,g=4,m=1,v=2,y=1,w=2,b=4,x=8,S=16,_=32,k=64,C=128,$=256,A=512,R=30,T="...",E=800,L=16,M=1,O=2,I=3,P=1/0,D=9007199254740991,F=17976931348623157e292,B=NaN,W=4294967295,N=W-1,H=W>>>1,j=[["ary",C],["bind",y],["bindKey",w],["curry",x],["curryRight",S],["flip",A],["partial",_],["partialRight",k],["rearg",$]],z="[object Arguments]",U="[object Array]",V="[object AsyncFunction]",G="[object Boolean]",K="[object Date]",q="[object DOMException]",Z="[object Error]",Y="[object Function]",X="[object GeneratorFunction]",Q="[object Map]",J="[object Number]",ee="[object Null]",te="[object Object]",ne="[object Promise]",re="[object Proxy]",ie="[object RegExp]",oe="[object Set]",se="[object String]",ae="[object Symbol]",le="[object Undefined]",ce="[object WeakMap]",ue="[object WeakSet]",he="[object ArrayBuffer]",fe="[object DataView]",de="[object Float32Array]",pe="[object Float64Array]",ge="[object Int8Array]",me="[object Int16Array]",ve="[object Int32Array]",ye="[object Uint8Array]",we="[object Uint8ClampedArray]",be="[object Uint16Array]",xe="[object Uint32Array]",Se=/\b__p \+= '';/g,_e=/\b(__p \+=) '' \+/g,ke=/(__e\(.*?\)|\b__t\)) \+\n'';/g,Ce=/&(?:amp|lt|gt|quot|#39);/g,$e=/[&<>"']/g,Ae=RegExp(Ce.source),Re=RegExp($e.source),Te=/<%-([\s\S]+?)%>/g,Ee=/<%([\s\S]+?)%>/g,Le=/<%=([\s\S]+?)%>/g,Me=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,Oe=/^\w*$/,Ie=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,Pe=/[\\^$.*+?()[\]{}|]/g,De=RegExp(Pe.source),Fe=/^\s+/,Be=/\s/,We=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/,Ne=/\{\n\/\* \[wrapped with (.+)\] \*/,He=/,? & /,je=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g,ze=/[()=,{}\[\]\/\s]/,Ue=/\\(\\)?/g,Ve=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,Ge=/\w*$/,Ke=/^[-+]0x[0-9a-f]+$/i,qe=/^0b[01]+$/i,Ze=/^\[object .+?Constructor\]$/,Ye=/^0o[0-7]+$/i,Xe=/^(?:0|[1-9]\d*)$/,Qe=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,Je=/($^)/,et=/['\n\r\u2028\u2029\\]/g,tt="\\ud800-\\udfff",nt="\\u0300-\\u036f",rt="\\ufe20-\\ufe2f",it="\\u20d0-\\u20ff",ot=nt+rt+it,st="\\u2700-\\u27bf",at="a-z\\xdf-\\xf6\\xf8-\\xff",lt="\\xac\\xb1\\xd7\\xf7",ct="\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf",ut="\\u2000-\\u206f",ht=" \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",ft="A-Z\\xc0-\\xd6\\xd8-\\xde",dt="\\ufe0e\\ufe0f",pt=lt+ct+ut+ht,gt="['’]",mt="["+tt+"]",vt="["+pt+"]",yt="["+ot+"]",wt="\\d+",bt="["+st+"]",xt="["+at+"]",St="[^"+tt+pt+wt+st+at+ft+"]",_t="\\ud83c[\\udffb-\\udfff]",kt="(?:"+yt+"|"+_t+")",Ct="[^"+tt+"]",$t="(?:\\ud83c[\\udde6-\\uddff]){2}",At="[\\ud800-\\udbff][\\udc00-\\udfff]",Rt="["+ft+"]",Tt="\\u200d",Et="(?:"+xt+"|"+St+")",Lt="(?:"+Rt+"|"+St+")",Mt="(?:"+gt+"(?:d|ll|m|re|s|t|ve))?",Ot="(?:"+gt+"(?:D|LL|M|RE|S|T|VE))?",It=kt+"?",Pt="["+dt+"]?",Dt="(?:"+Tt+"(?:"+[Ct,$t,At].join("|")+")"+Pt+It+")*",Ft="\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",Bt="\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])",Wt=Pt+It+Dt,Nt="(?:"+[bt,$t,At].join("|")+")"+Wt,Ht="(?:"+[Ct+yt+"?",yt,$t,At,mt].join("|")+")",jt=RegExp(gt,"g"),zt=RegExp(yt,"g"),Ut=RegExp(_t+"(?="+_t+")|"+Ht+Wt,"g"),Vt=RegExp([Rt+"?"+xt+"+"+Mt+"(?="+[vt,Rt,"$"].join("|")+")",Lt+"+"+Ot+"(?="+[vt,Rt+Et,"$"].join("|")+")",Rt+"?"+Et+"+"+Mt,Rt+"+"+Ot,Bt,Ft,wt,Nt].join("|"),"g"),Gt=RegExp("["+Tt+tt+ot+dt+"]"),Kt=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/,qt=["Array","Buffer","DataView","Date","Error","Float32Array","Float64Array","Function","Int8Array","Int16Array","Int32Array","Map","Math","Object","Promise","RegExp","Set","String","Symbol","TypeError","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","WeakMap","_","clearTimeout","isFinite","parseInt","setTimeout"],Zt=-1,Yt={};Yt[de]=Yt[pe]=Yt[ge]=Yt[me]=Yt[ve]=Yt[ye]=Yt[we]=Yt[be]=Yt[xe]=!0,Yt[z]=Yt[U]=Yt[he]=Yt[G]=Yt[fe]=Yt[K]=Yt[Z]=Yt[Y]=Yt[Q]=Yt[J]=Yt[te]=Yt[ie]=Yt[oe]=Yt[se]=Yt[ce]=!1;var Xt={};Xt[z]=Xt[U]=Xt[he]=Xt[fe]=Xt[G]=Xt[K]=Xt[de]=Xt[pe]=Xt[ge]=Xt[me]=Xt[ve]=Xt[Q]=Xt[J]=Xt[te]=Xt[ie]=Xt[oe]=Xt[se]=Xt[ae]=Xt[ye]=Xt[we]=Xt[be]=Xt[xe]=!0,Xt[Z]=Xt[Y]=Xt[ce]=!1;var Qt={"À":"A","Á":"A","Â":"A","Ã":"A","Ä":"A","Å":"A","à":"a","á":"a","â":"a","ã":"a","ä":"a","å":"a","Ç":"C","ç":"c","Ð":"D","ð":"d","È":"E","É":"E","Ê":"E","Ë":"E","è":"e","é":"e","ê":"e","ë":"e","Ì":"I","Í":"I","Î":"I","Ï":"I","ì":"i","í":"i","î":"i","ï":"i","Ñ":"N","ñ":"n","Ò":"O","Ó":"O","Ô":"O","Õ":"O","Ö":"O","Ø":"O","ò":"o","ó":"o","ô":"o","õ":"o","ö":"o","ø":"o","Ù":"U","Ú":"U","Û":"U","Ü":"U","ù":"u","ú":"u","û":"u","ü":"u","Ý":"Y","ý":"y","ÿ":"y","Æ":"Ae","æ":"ae","Þ":"Th","þ":"th","ß":"ss","Ā":"A","Ă":"A","Ą":"A","ā":"a","ă":"a","ą":"a","Ć":"C","Ĉ":"C","Ċ":"C","Č":"C","ć":"c","ĉ":"c","ċ":"c","č":"c","Ď":"D","Đ":"D","ď":"d","đ":"d","Ē":"E","Ĕ":"E","Ė":"E","Ę":"E","Ě":"E","ē":"e","ĕ":"e","ė":"e","ę":"e","ě":"e","Ĝ":"G","Ğ":"G","Ġ":"G","Ģ":"G","ĝ":"g","ğ":"g","ġ":"g","ģ":"g","Ĥ":"H","Ħ":"H","ĥ":"h","ħ":"h","Ĩ":"I","Ī":"I","Ĭ":"I","Į":"I","İ":"I","ĩ":"i","ī":"i","ĭ":"i","į":"i","ı":"i","Ĵ":"J","ĵ":"j","Ķ":"K","ķ":"k","ĸ":"k","Ĺ":"L","Ļ":"L","Ľ":"L","Ŀ":"L","Ł":"L","ĺ":"l","ļ":"l","ľ":"l","ŀ":"l","ł":"l","Ń":"N","Ņ":"N","Ň":"N","Ŋ":"N","ń":"n","ņ":"n","ň":"n","ŋ":"n","Ō":"O","Ŏ":"O","Ő":"O","ō":"o","ŏ":"o","ő":"o","Ŕ":"R","Ŗ":"R","Ř":"R","ŕ":"r","ŗ":"r","ř":"r","Ś":"S","Ŝ":"S","Ş":"S","Š":"S","ś":"s","ŝ":"s","ş":"s","š":"s","Ţ":"T","Ť":"T","Ŧ":"T","ţ":"t","ť":"t","ŧ":"t","Ũ":"U","Ū":"U","Ŭ":"U","Ů":"U","Ű":"U","Ų":"U","ũ":"u","ū":"u","ŭ":"u","ů":"u","ű":"u","ų":"u","Ŵ":"W","ŵ":"w","Ŷ":"Y","ŷ":"y","Ÿ":"Y","Ź":"Z","Ż":"Z","Ž":"Z","ź":"z","ż":"z","ž":"z","IJ":"IJ","ij":"ij","Œ":"Oe","œ":"oe","ʼn":"'n","ſ":"s"},Jt={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;"},en={"&amp;":"&","&lt;":"<","&gt;":">","&quot;":'"',"&#39;":"'"},tn={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},nn=parseFloat,rn=parseInt,on="object"==typeof n.g&&n.g&&n.g.Object===Object&&n.g,sn="object"==typeof self&&self&&self.Object===Object&&self,an=on||sn||Function("return this")(),ln=t&&!t.nodeType&&t,cn=ln&&e&&!e.nodeType&&e,un=cn&&cn.exports===ln,hn=un&&on.process,fn=function(){try{var e=cn&&cn.require&&cn.require("util").types;return e||hn&&hn.binding&&hn.binding("util")}catch(t){}}(),dn=fn&&fn.isArrayBuffer,pn=fn&&fn.isDate,gn=fn&&fn.isMap,mn=fn&&fn.isRegExp,vn=fn&&fn.isSet,yn=fn&&fn.isTypedArray;function wn(e,t,n){switch(n.length){case 0:return e.call(t);case 1:return e.call(t,n[0]);case 2:return e.call(t,n[0],n[1]);case 3:return e.call(t,n[0],n[1],n[2])}return e.apply(t,n)}function bn(e,t,n,r){var i=-1,o=null==e?0:e.length;while(++i<o){var s=e[i];t(r,s,n(s),e)}return r}function xn(e,t){var n=-1,r=null==e?0:e.length;while(++n<r)if(!1===t(e[n],n,e))break;return e}function Sn(e,t){var n=null==e?0:e.length;while(n--)if(!1===t(e[n],n,e))break;return e}function _n(e,t){var n=-1,r=null==e?0:e.length;while(++n<r)if(!t(e[n],n,e))return!1;return!0}function kn(e,t){var n=-1,r=null==e?0:e.length,i=0,o=[];while(++n<r){var s=e[n];t(s,n,e)&&(o[i++]=s)}return o}function Cn(e,t){var n=null==e?0:e.length;return!!n&&Fn(e,t,0)>-1}function $n(e,t,n){var r=-1,i=null==e?0:e.length;while(++r<i)if(n(t,e[r]))return!0;return!1}function An(e,t){var n=-1,r=null==e?0:e.length,i=Array(r);while(++n<r)i[n]=t(e[n],n,e);return i}function Rn(e,t){var n=-1,r=t.length,i=e.length;while(++n<r)e[i+n]=t[n];return e}function Tn(e,t,n,r){var i=-1,o=null==e?0:e.length;r&&o&&(n=e[++i]);while(++i<o)n=t(n,e[i],i,e);return n}function En(e,t,n,r){var i=null==e?0:e.length;r&&i&&(n=e[--i]);while(i--)n=t(n,e[i],i,e);return n}function Ln(e,t){var n=-1,r=null==e?0:e.length;while(++n<r)if(t(e[n],n,e))return!0;return!1}var Mn=Hn("length");function On(e){return e.split("")}function In(e){return e.match(je)||[]}function Pn(e,t,n){var r;return n(e,(function(e,n,i){if(t(e,n,i))return r=n,!1})),r}function Dn(e,t,n,r){var i=e.length,o=n+(r?1:-1);while(r?o--:++o<i)if(t(e[o],o,e))return o;return-1}function Fn(e,t,n){return t===t?dr(e,t,n):Dn(e,Wn,n)}function Bn(e,t,n,r){var i=n-1,o=e.length;while(++i<o)if(r(e[i],t))return i;return-1}function Wn(e){return e!==e}function Nn(e,t){var n=null==e?0:e.length;return n?Vn(e,t)/n:B}function Hn(e){return function(t){return null==t?i:t[e]}}function jn(e){return function(t){return null==e?i:e[t]}}function zn(e,t,n,r,i){return i(e,(function(e,i,o){n=r?(r=!1,e):t(n,e,i,o)})),n}function Un(e,t){var n=e.length;e.sort(t);while(n--)e[n]=e[n].value;return e}function Vn(e,t){var n,r=-1,o=e.length;while(++r<o){var s=t(e[r]);s!==i&&(n=n===i?s:n+s)}return n}function Gn(e,t){var n=-1,r=Array(e);while(++n<e)r[n]=t(n);return r}function Kn(e,t){return An(t,(function(t){return[t,e[t]]}))}function qn(e){return e?e.slice(0,vr(e)+1).replace(Fe,""):e}function Zn(e){return function(t){return e(t)}}function Yn(e,t){return An(t,(function(t){return e[t]}))}function Xn(e,t){return e.has(t)}function Qn(e,t){var n=-1,r=e.length;while(++n<r&&Fn(t,e[n],0)>-1);return n}function Jn(e,t){var n=e.length;while(n--&&Fn(t,e[n],0)>-1);return n}function er(e,t){var n=e.length,r=0;while(n--)e[n]===t&&++r;return r}var tr=jn(Qt),nr=jn(Jt);function rr(e){return"\\"+tn[e]}function ir(e,t){return null==e?i:e[t]}function or(e){return Gt.test(e)}function sr(e){return Kt.test(e)}function ar(e){var t,n=[];while(!(t=e.next()).done)n.push(t.value);return n}function lr(e){var t=-1,n=Array(e.size);return e.forEach((function(e,r){n[++t]=[r,e]})),n}function cr(e,t){return function(n){return e(t(n))}}function ur(e,t){var n=-1,r=e.length,i=0,o=[];while(++n<r){var s=e[n];s!==t&&s!==f||(e[n]=f,o[i++]=n)}return o}function hr(e){var t=-1,n=Array(e.size);return e.forEach((function(e){n[++t]=e})),n}function fr(e){var t=-1,n=Array(e.size);return e.forEach((function(e){n[++t]=[e,e]})),n}function dr(e,t,n){var r=n-1,i=e.length;while(++r<i)if(e[r]===t)return r;return-1}function pr(e,t,n){var r=n+1;while(r--)if(e[r]===t)return r;return r}function gr(e){return or(e)?wr(e):Mn(e)}function mr(e){return or(e)?br(e):On(e)}function vr(e){var t=e.length;while(t--&&Be.test(e.charAt(t)));return t}var yr=jn(en);function wr(e){var t=Ut.lastIndex=0;while(Ut.test(e))++t;return t}function br(e){return e.match(Ut)||[]}function xr(e){return e.match(Vt)||[]}var Sr=function e(t){t=null==t?an:_r.defaults(an.Object(),t,_r.pick(an,qt));var n=t.Array,r=t.Date,Be=t.Error,je=t.Function,tt=t.Math,nt=t.Object,rt=t.RegExp,it=t.String,ot=t.TypeError,st=n.prototype,at=je.prototype,lt=nt.prototype,ct=t["__core-js_shared__"],ut=at.toString,ht=lt.hasOwnProperty,ft=0,dt=function(){var e=/[^.]+$/.exec(ct&&ct.keys&&ct.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}(),pt=lt.toString,gt=ut.call(nt),mt=an._,vt=rt("^"+ut.call(ht).replace(Pe,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),yt=un?t.Buffer:i,wt=t.Symbol,bt=t.Uint8Array,xt=yt?yt.allocUnsafe:i,St=cr(nt.getPrototypeOf,nt),_t=nt.create,kt=lt.propertyIsEnumerable,Ct=st.splice,$t=wt?wt.isConcatSpreadable:i,At=wt?wt.iterator:i,Rt=wt?wt.toStringTag:i,Tt=function(){try{var e=Ks(nt,"defineProperty");return e({},"",{}),e}catch(t){}}(),Et=t.clearTimeout!==an.clearTimeout&&t.clearTimeout,Lt=r&&r.now!==an.Date.now&&r.now,Mt=t.setTimeout!==an.setTimeout&&t.setTimeout,Ot=tt.ceil,It=tt.floor,Pt=nt.getOwnPropertySymbols,Dt=yt?yt.isBuffer:i,Ft=t.isFinite,Bt=st.join,Wt=cr(nt.keys,nt),Nt=tt.max,Ht=tt.min,Ut=r.now,Vt=t.parseInt,Gt=tt.random,Kt=st.reverse,Qt=Ks(t,"DataView"),Jt=Ks(t,"Map"),en=Ks(t,"Promise"),tn=Ks(t,"Set"),on=Ks(t,"WeakMap"),sn=Ks(nt,"create"),ln=on&&new on,cn={},hn=Ma(Qt),fn=Ma(Jt),Mn=Ma(en),On=Ma(tn),jn=Ma(on),dr=wt?wt.prototype:i,wr=dr?dr.valueOf:i,br=dr?dr.toString:i;function Sr(e){if(Cu(e)&&!lu(e)&&!(e instanceof Ar)){if(e instanceof $r)return e;if(ht.call(e,"__wrapped__"))return Ia(e)}return new $r(e)}var kr=function(){function e(){}return function(t){if(!ku(t))return{};if(_t)return _t(t);e.prototype=t;var n=new e;return e.prototype=i,n}}();function Cr(){}function $r(e,t){this.__wrapped__=e,this.__actions__=[],this.__chain__=!!t,this.__index__=0,this.__values__=i}function Ar(e){this.__wrapped__=e,this.__actions__=[],this.__dir__=1,this.__filtered__=!1,this.__iteratees__=[],this.__takeCount__=W,this.__views__=[]}function Rr(){var e=new Ar(this.__wrapped__);return e.__actions__=is(this.__actions__),e.__dir__=this.__dir__,e.__filtered__=this.__filtered__,e.__iteratees__=is(this.__iteratees__),e.__takeCount__=this.__takeCount__,e.__views__=is(this.__views__),e}function Tr(){if(this.__filtered__){var e=new Ar(this);e.__dir__=-1,e.__filtered__=!0}else e=this.clone(),e.__dir__*=-1;return e}function Er(){var e=this.__wrapped__.value(),t=this.__dir__,n=lu(e),r=t<0,i=n?e.length:0,o=Qs(0,i,this.__views__),s=o.start,a=o.end,l=a-s,c=r?a:s-1,u=this.__iteratees__,h=u.length,f=0,d=Ht(l,this.__takeCount__);if(!n||!r&&i==l&&d==l)return Wo(e,this.__actions__);var p=[];e:while(l--&&f<d){c+=t;var g=-1,m=e[c];while(++g<h){var v=u[g],y=v.iteratee,w=v.type,b=y(m);if(w==O)m=b;else if(!b){if(w==M)continue e;break e}}p[f++]=m}return p}function Lr(e){var t=-1,n=null==e?0:e.length;this.clear();while(++t<n){var r=e[t];this.set(r[0],r[1])}}function Mr(){this.__data__=sn?sn(null):{},this.size=0}function Or(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}function Ir(e){var t=this.__data__;if(sn){var n=t[e];return n===u?i:n}return ht.call(t,e)?t[e]:i}function Pr(e){var t=this.__data__;return sn?t[e]!==i:ht.call(t,e)}function Dr(e,t){var n=this.__data__;return this.size+=this.has(e)?0:1,n[e]=sn&&t===i?u:t,this}function Fr(e){var t=-1,n=null==e?0:e.length;this.clear();while(++t<n){var r=e[t];this.set(r[0],r[1])}}function Br(){this.__data__=[],this.size=0}function Wr(e){var t=this.__data__,n=ui(t,e);if(n<0)return!1;var r=t.length-1;return n==r?t.pop():Ct.call(t,n,1),--this.size,!0}function Nr(e){var t=this.__data__,n=ui(t,e);return n<0?i:t[n][1]}function Hr(e){return ui(this.__data__,e)>-1}function jr(e,t){var n=this.__data__,r=ui(n,e);return r<0?(++this.size,n.push([e,t])):n[r][1]=t,this}function zr(e){var t=-1,n=null==e?0:e.length;this.clear();while(++t<n){var r=e[t];this.set(r[0],r[1])}}function Ur(){this.size=0,this.__data__={hash:new Lr,map:new(Jt||Fr),string:new Lr}}function Vr(e){var t=Vs(this,e)["delete"](e);return this.size-=t?1:0,t}function Gr(e){return Vs(this,e).get(e)}function Kr(e){return Vs(this,e).has(e)}function qr(e,t){var n=Vs(this,e),r=n.size;return n.set(e,t),this.size+=n.size==r?0:1,this}function Zr(e){var t=-1,n=null==e?0:e.length;this.__data__=new zr;while(++t<n)this.add(e[t])}function Yr(e){return this.__data__.set(e,u),this}function Xr(e){return this.__data__.has(e)}function Qr(e){var t=this.__data__=new Fr(e);this.size=t.size}function Jr(){this.__data__=new Fr,this.size=0}function ei(e){var t=this.__data__,n=t["delete"](e);return this.size=t.size,n}function ti(e){return this.__data__.get(e)}function ni(e){return this.__data__.has(e)}function ri(e,t){var n=this.__data__;if(n instanceof Fr){var r=n.__data__;if(!Jt||r.length<s-1)return r.push([e,t]),this.size=++n.size,this;n=this.__data__=new zr(r)}return n.set(e,t),this.size=n.size,this}function ii(e,t){var n=lu(e),r=!n&&au(e),i=!n&&!r&&du(e),o=!n&&!r&&!i&&Nu(e),s=n||r||i||o,a=s?Gn(e.length,it):[],l=a.length;for(var c in e)!t&&!ht.call(e,c)||s&&("length"==c||i&&("offset"==c||"parent"==c)||o&&("buffer"==c||"byteLength"==c||"byteOffset"==c)||sa(c,l))||a.push(c);return a}function oi(e){var t=e.length;return t?e[yo(0,t-1)]:i}function si(e,t){return Ta(is(e),mi(t,0,e.length))}function ai(e){return Ta(is(e))}function li(e,t,n){(n!==i&&!iu(e[t],n)||n===i&&!(t in e))&&pi(e,t,n)}function ci(e,t,n){var r=e[t];ht.call(e,t)&&iu(r,n)&&(n!==i||t in e)||pi(e,t,n)}function ui(e,t){var n=e.length;while(n--)if(iu(e[n][0],t))return n;return-1}function hi(e,t,n,r){return Si(e,(function(e,i,o){t(r,e,n(e),o)})),r}function fi(e,t){return e&&os(t,Sh(t),e)}function di(e,t){return e&&os(t,_h(t),e)}function pi(e,t,n){"__proto__"==t&&Tt?Tt(e,t,{configurable:!0,enumerable:!0,value:n,writable:!0}):e[t]=n}function gi(e,t){var r=-1,o=t.length,s=n(o),a=null==e;while(++r<o)s[r]=a?i:mh(e,t[r]);return s}function mi(e,t,n){return e===e&&(n!==i&&(e=e<=n?e:n),t!==i&&(e=e>=t?e:t)),e}function vi(e,t,n,r,o,s){var a,l=t&d,c=t&p,u=t&g;if(n&&(a=o?n(e,r,o,s):n(e)),a!==i)return a;if(!ku(e))return e;var h=lu(e);if(h){if(a=ta(e),!l)return is(e,a)}else{var f=Xs(e),m=f==Y||f==X;if(du(e))return qo(e,l);if(f==te||f==z||m&&!o){if(a=c||m?{}:na(e),!l)return c?as(e,di(a,e)):ss(e,fi(a,e))}else{if(!Xt[f])return o?e:{};a=ra(e,f,l)}}s||(s=new Qr);var v=s.get(e);if(v)return v;s.set(e,a),Fu(e)?e.forEach((function(r){a.add(vi(r,t,n,r,e,s))})):$u(e)&&e.forEach((function(r,i){a.set(i,vi(r,t,n,i,e,s))}));var y=u?c?Ns:Ws:c?_h:Sh,w=h?i:y(e);return xn(w||e,(function(r,i){w&&(i=r,r=e[i]),ci(a,i,vi(r,t,n,i,e,s))})),a}function yi(e){var t=Sh(e);return function(n){return wi(n,e,t)}}function wi(e,t,n){var r=n.length;if(null==e)return!r;e=nt(e);while(r--){var o=n[r],s=t[o],a=e[o];if(a===i&&!(o in e)||!s(a))return!1}return!0}function bi(e,t,n){if("function"!=typeof e)throw new ot(l);return Ca((function(){e.apply(i,n)}),t)}function xi(e,t,n,r){var i=-1,o=Cn,a=!0,l=e.length,c=[],u=t.length;if(!l)return c;n&&(t=An(t,Zn(n))),r?(o=$n,a=!1):t.length>=s&&(o=Xn,a=!1,t=new Zr(t));e:while(++i<l){var h=e[i],f=null==n?h:n(h);if(h=r||0!==h?h:0,a&&f===f){var d=u;while(d--)if(t[d]===f)continue e;c.push(h)}else o(t,f,r)||c.push(h)}return c}Sr.templateSettings={escape:Te,evaluate:Ee,interpolate:Le,variable:"",imports:{_:Sr}},Sr.prototype=Cr.prototype,Sr.prototype.constructor=Sr,$r.prototype=kr(Cr.prototype),$r.prototype.constructor=$r,Ar.prototype=kr(Cr.prototype),Ar.prototype.constructor=Ar,Lr.prototype.clear=Mr,Lr.prototype["delete"]=Or,Lr.prototype.get=Ir,Lr.prototype.has=Pr,Lr.prototype.set=Dr,Fr.prototype.clear=Br,Fr.prototype["delete"]=Wr,Fr.prototype.get=Nr,Fr.prototype.has=Hr,Fr.prototype.set=jr,zr.prototype.clear=Ur,zr.prototype["delete"]=Vr,zr.prototype.get=Gr,zr.prototype.has=Kr,zr.prototype.set=qr,Zr.prototype.add=Zr.prototype.push=Yr,Zr.prototype.has=Xr,Qr.prototype.clear=Jr,Qr.prototype["delete"]=ei,Qr.prototype.get=ti,Qr.prototype.has=ni,Qr.prototype.set=ri;var Si=us(Li),_i=us(Mi,!0);function ki(e,t){var n=!0;return Si(e,(function(e,r,i){return n=!!t(e,r,i),n})),n}function Ci(e,t,n){var r=-1,o=e.length;while(++r<o){var s=e[r],a=t(s);if(null!=a&&(l===i?a===a&&!Wu(a):n(a,l)))var l=a,c=s}return c}function $i(e,t,n,r){var o=e.length;n=qu(n),n<0&&(n=-n>o?0:o+n),r=r===i||r>o?o:qu(r),r<0&&(r+=o),r=n>r?0:Zu(r);while(n<r)e[n++]=t;return e}function Ai(e,t){var n=[];return Si(e,(function(e,r,i){t(e,r,i)&&n.push(e)})),n}function Ri(e,t,n,r,i){var o=-1,s=e.length;n||(n=oa),i||(i=[]);while(++o<s){var a=e[o];t>0&&n(a)?t>1?Ri(a,t-1,n,r,i):Rn(i,a):r||(i[i.length]=a)}return i}var Ti=hs(),Ei=hs(!0);function Li(e,t){return e&&Ti(e,t,Sh)}function Mi(e,t){return e&&Ei(e,t,Sh)}function Oi(e,t){return kn(t,(function(t){return xu(e[t])}))}function Ii(e,t){t=Uo(t,e);var n=0,r=t.length;while(null!=e&&n<r)e=e[La(t[n++])];return n&&n==r?e:i}function Pi(e,t,n){var r=t(e);return lu(e)?r:Rn(r,n(e))}function Di(e){return null==e?e===i?le:ee:Rt&&Rt in nt(e)?qs(e):wa(e)}function Fi(e,t){return e>t}function Bi(e,t){return null!=e&&ht.call(e,t)}function Wi(e,t){return null!=e&&t in nt(e)}function Ni(e,t,n){return e>=Ht(t,n)&&e<Nt(t,n)}function Hi(e,t,r){var o=r?$n:Cn,s=e[0].length,a=e.length,l=a,c=n(a),u=1/0,h=[];while(l--){var f=e[l];l&&t&&(f=An(f,Zn(t))),u=Ht(f.length,u),c[l]=!r&&(t||s>=120&&f.length>=120)?new Zr(l&&f):i}f=e[0];var d=-1,p=c[0];e:while(++d<s&&h.length<u){var g=f[d],m=t?t(g):g;if(g=r||0!==g?g:0,!(p?Xn(p,m):o(h,m,r))){l=a;while(--l){var v=c[l];if(!(v?Xn(v,m):o(e[l],m,r)))continue e}p&&p.push(m),h.push(g)}}return h}function ji(e,t,n,r){return Li(e,(function(e,i,o){t(r,n(e),i,o)})),r}function zi(e,t,n){t=Uo(t,e),e=xa(e,t);var r=null==e?e:e[La(ol(t))];return null==r?i:wn(r,e,n)}function Ui(e){return Cu(e)&&Di(e)==z}function Vi(e){return Cu(e)&&Di(e)==he}function Gi(e){return Cu(e)&&Di(e)==K}function Ki(e,t,n,r,i){return e===t||(null==e||null==t||!Cu(e)&&!Cu(t)?e!==e&&t!==t:qi(e,t,n,r,Ki,i))}function qi(e,t,n,r,i,o){var s=lu(e),a=lu(t),l=s?U:Xs(e),c=a?U:Xs(t);l=l==z?te:l,c=c==z?te:c;var u=l==te,h=c==te,f=l==c;if(f&&du(e)){if(!du(t))return!1;s=!0,u=!1}if(f&&!u)return o||(o=new Qr),s||Nu(e)?Ps(e,t,n,r,i,o):Ds(e,t,l,n,r,i,o);if(!(n&m)){var d=u&&ht.call(e,"__wrapped__"),p=h&&ht.call(t,"__wrapped__");if(d||p){var g=d?e.value():e,v=p?t.value():t;return o||(o=new Qr),i(g,v,n,r,o)}}return!!f&&(o||(o=new Qr),Fs(e,t,n,r,i,o))}function Zi(e){return Cu(e)&&Xs(e)==Q}function Yi(e,t,n,r){var o=n.length,s=o,a=!r;if(null==e)return!s;e=nt(e);while(o--){var l=n[o];if(a&&l[2]?l[1]!==e[l[0]]:!(l[0]in e))return!1}while(++o<s){l=n[o];var c=l[0],u=e[c],h=l[1];if(a&&l[2]){if(u===i&&!(c in e))return!1}else{var f=new Qr;if(r)var d=r(u,h,c,e,t,f);if(!(d===i?Ki(h,u,m|v,r,f):d))return!1}}return!0}function Xi(e){if(!ku(e)||ha(e))return!1;var t=xu(e)?vt:Ze;return t.test(Ma(e))}function Qi(e){return Cu(e)&&Di(e)==ie}function Ji(e){return Cu(e)&&Xs(e)==oe}function eo(e){return Cu(e)&&_u(e.length)&&!!Yt[Di(e)]}function to(e){return"function"==typeof e?e:null==e?Lf:"object"==typeof e?lu(e)?ao(e[0],e[1]):so(e):Uf(e)}function no(e){if(!da(e))return Wt(e);var t=[];for(var n in nt(e))ht.call(e,n)&&"constructor"!=n&&t.push(n);return t}function ro(e){if(!ku(e))return ya(e);var t=da(e),n=[];for(var r in e)("constructor"!=r||!t&&ht.call(e,r))&&n.push(r);return n}function io(e,t){return e<t}function oo(e,t){var r=-1,i=uu(e)?n(e.length):[];return Si(e,(function(e,n,o){i[++r]=t(e,n,o)})),i}function so(e){var t=Gs(e);return 1==t.length&&t[0][2]?ga(t[0][0],t[0][1]):function(n){return n===e||Yi(n,e,t)}}function ao(e,t){return la(e)&&pa(t)?ga(La(e),t):function(n){var r=mh(n,e);return r===i&&r===t?yh(n,e):Ki(t,r,m|v)}}function lo(e,t,n,r,o){e!==t&&Ti(t,(function(s,a){if(o||(o=new Qr),ku(s))co(e,t,a,n,lo,r,o);else{var l=r?r(_a(e,a),s,a+"",e,t,o):i;l===i&&(l=s),li(e,a,l)}}),_h)}function co(e,t,n,r,o,s,a){var l=_a(e,n),c=_a(t,n),u=a.get(c);if(u)li(e,n,u);else{var h=s?s(l,c,n+"",e,t,a):i,f=h===i;if(f){var d=lu(c),p=!d&&du(c),g=!d&&!p&&Nu(c);h=c,d||p||g?lu(l)?h=l:hu(l)?h=is(l):p?(f=!1,h=qo(c,!0)):g?(f=!1,h=Jo(c,!0)):h=[]:Iu(c)||au(c)?(h=l,au(l)?h=Xu(l):ku(l)&&!xu(l)||(h=na(c))):f=!1}f&&(a.set(c,h),o(h,c,r,s,a),a["delete"](c)),li(e,n,h)}}function uo(e,t){var n=e.length;if(n)return t+=t<0?n:0,sa(t,n)?e[t]:i}function ho(e,t,n){t=t.length?An(t,(function(e){return lu(e)?function(t){return Ii(t,1===e.length?e[0]:e)}:e})):[Lf];var r=-1;t=An(t,Zn(Us()));var i=oo(e,(function(e,n,i){var o=An(t,(function(t){return t(e)}));return{criteria:o,index:++r,value:e}}));return Un(i,(function(e,t){return ts(e,t,n)}))}function fo(e,t){return po(e,t,(function(t,n){return yh(e,n)}))}function po(e,t,n){var r=-1,i=t.length,o={};while(++r<i){var s=t[r],a=Ii(e,s);n(a,s)&&ko(o,Uo(s,e),a)}return o}function go(e){return function(t){return Ii(t,e)}}function mo(e,t,n,r){var i=r?Bn:Fn,o=-1,s=t.length,a=e;e===t&&(t=is(t)),n&&(a=An(e,Zn(n)));while(++o<s){var l=0,c=t[o],u=n?n(c):c;while((l=i(a,u,l,r))>-1)a!==e&&Ct.call(a,l,1),Ct.call(e,l,1)}return e}function vo(e,t){var n=e?t.length:0,r=n-1;while(n--){var i=t[n];if(n==r||i!==o){var o=i;sa(i)?Ct.call(e,i,1):Do(e,i)}}return e}function yo(e,t){return e+It(Gt()*(t-e+1))}function wo(e,t,r,i){var o=-1,s=Nt(Ot((t-e)/(r||1)),0),a=n(s);while(s--)a[i?s:++o]=e,e+=r;return a}function bo(e,t){var n="";if(!e||t<1||t>D)return n;do{t%2&&(n+=e),t=It(t/2),t&&(e+=e)}while(t);return n}function xo(e,t){return $a(ba(e,t,Lf),e+"")}function So(e){return oi(Hh(e))}function _o(e,t){var n=Hh(e);return Ta(n,mi(t,0,n.length))}function ko(e,t,n,r){if(!ku(e))return e;t=Uo(t,e);var o=-1,s=t.length,a=s-1,l=e;while(null!=l&&++o<s){var c=La(t[o]),u=n;if("__proto__"===c||"constructor"===c||"prototype"===c)return e;if(o!=a){var h=l[c];u=r?r(h,c,l):i,u===i&&(u=ku(h)?h:sa(t[o+1])?[]:{})}ci(l,c,u),l=l[c]}return e}var Co=ln?function(e,t){return ln.set(e,t),e}:Lf,$o=Tt?function(e,t){return Tt(e,"toString",{configurable:!0,enumerable:!1,value:Af(t),writable:!0})}:Lf;function Ao(e){return Ta(Hh(e))}function Ro(e,t,r){var i=-1,o=e.length;t<0&&(t=-t>o?0:o+t),r=r>o?o:r,r<0&&(r+=o),o=t>r?0:r-t>>>0,t>>>=0;var s=n(o);while(++i<o)s[i]=e[i+t];return s}function To(e,t){var n;return Si(e,(function(e,r,i){return n=t(e,r,i),!n})),!!n}function Eo(e,t,n){var r=0,i=null==e?r:e.length;if("number"==typeof t&&t===t&&i<=H){while(r<i){var o=r+i>>>1,s=e[o];null!==s&&!Wu(s)&&(n?s<=t:s<t)?r=o+1:i=o}return i}return Lo(e,t,Lf,n)}function Lo(e,t,n,r){var o=0,s=null==e?0:e.length;if(0===s)return 0;t=n(t);var a=t!==t,l=null===t,c=Wu(t),u=t===i;while(o<s){var h=It((o+s)/2),f=n(e[h]),d=f!==i,p=null===f,g=f===f,m=Wu(f);if(a)var v=r||g;else v=u?g&&(r||d):l?g&&d&&(r||!p):c?g&&d&&!p&&(r||!m):!p&&!m&&(r?f<=t:f<t);v?o=h+1:s=h}return Ht(s,N)}function Mo(e,t){var n=-1,r=e.length,i=0,o=[];while(++n<r){var s=e[n],a=t?t(s):s;if(!n||!iu(a,l)){var l=a;o[i++]=0===s?0:s}}return o}function Oo(e){return"number"==typeof e?e:Wu(e)?B:+e}function Io(e){if("string"==typeof e)return e;if(lu(e))return An(e,Io)+"";if(Wu(e))return br?br.call(e):"";var t=e+"";return"0"==t&&1/e==-P?"-0":t}function Po(e,t,n){var r=-1,i=Cn,o=e.length,a=!0,l=[],c=l;if(n)a=!1,i=$n;else if(o>=s){var u=t?null:Ts(e);if(u)return hr(u);a=!1,i=Xn,c=new Zr}else c=t?[]:l;e:while(++r<o){var h=e[r],f=t?t(h):h;if(h=n||0!==h?h:0,a&&f===f){var d=c.length;while(d--)if(c[d]===f)continue e;t&&c.push(f),l.push(h)}else i(c,f,n)||(c!==l&&c.push(f),l.push(h))}return l}function Do(e,t){return t=Uo(t,e),e=xa(e,t),null==e||delete e[La(ol(t))]}function Fo(e,t,n,r){return ko(e,t,n(Ii(e,t)),r)}function Bo(e,t,n,r){var i=e.length,o=r?i:-1;while((r?o--:++o<i)&&t(e[o],o,e));return n?Ro(e,r?0:o,r?o+1:i):Ro(e,r?o+1:0,r?i:o)}function Wo(e,t){var n=e;return n instanceof Ar&&(n=n.value()),Tn(t,(function(e,t){return t.func.apply(t.thisArg,Rn([e],t.args))}),n)}function No(e,t,r){var i=e.length;if(i<2)return i?Po(e[0]):[];var o=-1,s=n(i);while(++o<i){var a=e[o],l=-1;while(++l<i)l!=o&&(s[o]=xi(s[o]||a,e[l],t,r))}return Po(Ri(s,1),t,r)}function Ho(e,t,n){var r=-1,o=e.length,s=t.length,a={};while(++r<o){var l=r<s?t[r]:i;n(a,e[r],l)}return a}function jo(e){return hu(e)?e:[]}function zo(e){return"function"==typeof e?e:Lf}function Uo(e,t){return lu(e)?e:la(e,t)?[e]:Ea(Ju(e))}var Vo=xo;function Go(e,t,n){var r=e.length;return n=n===i?r:n,!t&&n>=r?e:Ro(e,t,n)}var Ko=Et||function(e){return an.clearTimeout(e)};function qo(e,t){if(t)return e.slice();var n=e.length,r=xt?xt(n):new e.constructor(n);return e.copy(r),r}function Zo(e){var t=new e.constructor(e.byteLength);return new bt(t).set(new bt(e)),t}function Yo(e,t){var n=t?Zo(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.byteLength)}function Xo(e){var t=new e.constructor(e.source,Ge.exec(e));return t.lastIndex=e.lastIndex,t}function Qo(e){return wr?nt(wr.call(e)):{}}function Jo(e,t){var n=t?Zo(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.length)}function es(e,t){if(e!==t){var n=e!==i,r=null===e,o=e===e,s=Wu(e),a=t!==i,l=null===t,c=t===t,u=Wu(t);if(!l&&!u&&!s&&e>t||s&&a&&c&&!l&&!u||r&&a&&c||!n&&c||!o)return 1;if(!r&&!s&&!u&&e<t||u&&n&&o&&!r&&!s||l&&n&&o||!a&&o||!c)return-1}return 0}function ts(e,t,n){var r=-1,i=e.criteria,o=t.criteria,s=i.length,a=n.length;while(++r<s){var l=es(i[r],o[r]);if(l){if(r>=a)return l;var c=n[r];return l*("desc"==c?-1:1)}}return e.index-t.index}function ns(e,t,r,i){var o=-1,s=e.length,a=r.length,l=-1,c=t.length,u=Nt(s-a,0),h=n(c+u),f=!i;while(++l<c)h[l]=t[l];while(++o<a)(f||o<s)&&(h[r[o]]=e[o]);while(u--)h[l++]=e[o++];return h}function rs(e,t,r,i){var o=-1,s=e.length,a=-1,l=r.length,c=-1,u=t.length,h=Nt(s-l,0),f=n(h+u),d=!i;while(++o<h)f[o]=e[o];var p=o;while(++c<u)f[p+c]=t[c];while(++a<l)(d||o<s)&&(f[p+r[a]]=e[o++]);return f}function is(e,t){var r=-1,i=e.length;t||(t=n(i));while(++r<i)t[r]=e[r];return t}function os(e,t,n,r){var o=!n;n||(n={});var s=-1,a=t.length;while(++s<a){var l=t[s],c=r?r(n[l],e[l],l,n,e):i;c===i&&(c=e[l]),o?pi(n,l,c):ci(n,l,c)}return n}function ss(e,t){return os(e,Zs(e),t)}function as(e,t){return os(e,Ys(e),t)}function ls(e,t){return function(n,r){var i=lu(n)?bn:hi,o=t?t():{};return i(n,e,Us(r,2),o)}}function cs(e){return xo((function(t,n){var r=-1,o=n.length,s=o>1?n[o-1]:i,a=o>2?n[2]:i;s=e.length>3&&"function"==typeof s?(o--,s):i,a&&aa(n[0],n[1],a)&&(s=o<3?i:s,o=1),t=nt(t);while(++r<o){var l=n[r];l&&e(t,l,r,s)}return t}))}function us(e,t){return function(n,r){if(null==n)return n;if(!uu(n))return e(n,r);var i=n.length,o=t?i:-1,s=nt(n);while(t?o--:++o<i)if(!1===r(s[o],o,s))break;return n}}function hs(e){return function(t,n,r){var i=-1,o=nt(t),s=r(t),a=s.length;while(a--){var l=s[e?a:++i];if(!1===n(o[l],l,o))break}return t}}function fs(e,t,n){var r=t&y,i=gs(e);function o(){var t=this&&this!==an&&this instanceof o?i:e;return t.apply(r?n:this,arguments)}return o}function ds(e){return function(t){t=Ju(t);var n=or(t)?mr(t):i,r=n?n[0]:t.charAt(0),o=n?Go(n,1).join(""):t.slice(1);return r[e]()+o}}function ps(e){return function(t){return Tn(Sf(qh(t).replace(jt,"")),e,"")}}function gs(e){return function(){var t=arguments;switch(t.length){case 0:return new e;case 1:return new e(t[0]);case 2:return new e(t[0],t[1]);case 3:return new e(t[0],t[1],t[2]);case 4:return new e(t[0],t[1],t[2],t[3]);case 5:return new e(t[0],t[1],t[2],t[3],t[4]);case 6:return new e(t[0],t[1],t[2],t[3],t[4],t[5]);case 7:return new e(t[0],t[1],t[2],t[3],t[4],t[5],t[6])}var n=kr(e.prototype),r=e.apply(n,t);return ku(r)?r:n}}function ms(e,t,r){var o=gs(e);function s(){var a=arguments.length,l=n(a),c=a,u=zs(s);while(c--)l[c]=arguments[c];var h=a<3&&l[0]!==u&&l[a-1]!==u?[]:ur(l,u);if(a-=h.length,a<r)return As(e,t,ws,s.placeholder,i,l,h,i,i,r-a);var f=this&&this!==an&&this instanceof s?o:e;return wn(f,this,l)}return s}function vs(e){return function(t,n,r){var o=nt(t);if(!uu(t)){var s=Us(n,3);t=Sh(t),n=function(e){return s(o[e],e,o)}}var a=e(t,n,r);return a>-1?o[s?t[a]:a]:i}}function ys(e){return Bs((function(t){var n=t.length,r=n,o=$r.prototype.thru;e&&t.reverse();while(r--){var s=t[r];if("function"!=typeof s)throw new ot(l);if(o&&!a&&"wrapper"==js(s))var a=new $r([],!0)}r=a?r:n;while(++r<n){s=t[r];var c=js(s),u="wrapper"==c?Hs(s):i;a=u&&ua(u[0])&&u[1]==(C|x|_|$)&&!u[4].length&&1==u[9]?a[js(u[0])].apply(a,u[3]):1==s.length&&ua(s)?a[c]():a.thru(s)}return function(){var e=arguments,r=e[0];if(a&&1==e.length&&lu(r))return a.plant(r).value();var i=0,o=n?t[i].apply(this,e):r;while(++i<n)o=t[i].call(this,o);return o}}))}function ws(e,t,r,o,s,a,l,c,u,h){var f=t&C,d=t&y,p=t&w,g=t&(x|S),m=t&A,v=p?i:gs(e);function b(){var i=arguments.length,y=n(i),w=i;while(w--)y[w]=arguments[w];if(g)var x=zs(b),S=er(y,x);if(o&&(y=ns(y,o,s,g)),a&&(y=rs(y,a,l,g)),i-=S,g&&i<h){var _=ur(y,x);return As(e,t,ws,b.placeholder,r,y,_,c,u,h-i)}var k=d?r:this,C=p?k[e]:e;return i=y.length,c?y=Sa(y,c):m&&i>1&&y.reverse(),f&&u<i&&(y.length=u),this&&this!==an&&this instanceof b&&(C=v||gs(C)),C.apply(k,y)}return b}function bs(e,t){return function(n,r){return ji(n,e,t(r),{})}}function xs(e,t){return function(n,r){var o;if(n===i&&r===i)return t;if(n!==i&&(o=n),r!==i){if(o===i)return r;"string"==typeof n||"string"==typeof r?(n=Io(n),r=Io(r)):(n=Oo(n),r=Oo(r)),o=e(n,r)}return o}}function Ss(e){return Bs((function(t){return t=An(t,Zn(Us())),xo((function(n){var r=this;return e(t,(function(e){return wn(e,r,n)}))}))}))}function _s(e,t){t=t===i?" ":Io(t);var n=t.length;if(n<2)return n?bo(t,e):t;var r=bo(t,Ot(e/gr(t)));return or(t)?Go(mr(r),0,e).join(""):r.slice(0,e)}function ks(e,t,r,i){var o=t&y,s=gs(e);function a(){var t=-1,l=arguments.length,c=-1,u=i.length,h=n(u+l),f=this&&this!==an&&this instanceof a?s:e;while(++c<u)h[c]=i[c];while(l--)h[c++]=arguments[++t];return wn(f,o?r:this,h)}return a}function Cs(e){return function(t,n,r){return r&&"number"!=typeof r&&aa(t,n,r)&&(n=r=i),t=Ku(t),n===i?(n=t,t=0):n=Ku(n),r=r===i?t<n?1:-1:Ku(r),wo(t,n,r,e)}}function $s(e){return function(t,n){return"string"==typeof t&&"string"==typeof n||(t=Yu(t),n=Yu(n)),e(t,n)}}function As(e,t,n,r,o,s,a,l,c,u){var h=t&x,f=h?a:i,d=h?i:a,p=h?s:i,g=h?i:s;t|=h?_:k,t&=~(h?k:_),t&b||(t&=~(y|w));var m=[e,t,o,p,f,g,d,l,c,u],v=n.apply(i,m);return ua(e)&&ka(v,m),v.placeholder=r,Aa(v,e,t)}function Rs(e){var t=tt[e];return function(e,n){if(e=Yu(e),n=null==n?0:Ht(qu(n),292),n&&Ft(e)){var r=(Ju(e)+"e").split("e"),i=t(r[0]+"e"+(+r[1]+n));return r=(Ju(i)+"e").split("e"),+(r[0]+"e"+(+r[1]-n))}return t(e)}}var Ts=tn&&1/hr(new tn([,-0]))[1]==P?function(e){return new tn(e)}:Wf;function Es(e){return function(t){var n=Xs(t);return n==Q?lr(t):n==oe?fr(t):Kn(t,e(t))}}function Ls(e,t,n,r,o,s,a,c){var u=t&w;if(!u&&"function"!=typeof e)throw new ot(l);var h=r?r.length:0;if(h||(t&=~(_|k),r=o=i),a=a===i?a:Nt(qu(a),0),c=c===i?c:qu(c),h-=o?o.length:0,t&k){var f=r,d=o;r=o=i}var p=u?i:Hs(e),g=[e,t,n,r,o,f,d,s,a,c];if(p&&va(g,p),e=g[0],t=g[1],n=g[2],r=g[3],o=g[4],c=g[9]=g[9]===i?u?0:e.length:Nt(g[9]-h,0),!c&&t&(x|S)&&(t&=~(x|S)),t&&t!=y)m=t==x||t==S?ms(e,t,c):t!=_&&t!=(y|_)||o.length?ws.apply(i,g):ks(e,t,n,r);else var m=fs(e,t,n);var v=p?Co:ka;return Aa(v(m,g),e,t)}function Ms(e,t,n,r){return e===i||iu(e,lt[n])&&!ht.call(r,n)?t:e}function Os(e,t,n,r,o,s){return ku(e)&&ku(t)&&(s.set(t,e),lo(e,t,i,Os,s),s["delete"](t)),e}function Is(e){return Iu(e)?i:e}function Ps(e,t,n,r,o,s){var a=n&m,l=e.length,c=t.length;if(l!=c&&!(a&&c>l))return!1;var u=s.get(e),h=s.get(t);if(u&&h)return u==t&&h==e;var f=-1,d=!0,p=n&v?new Zr:i;s.set(e,t),s.set(t,e);while(++f<l){var g=e[f],y=t[f];if(r)var w=a?r(y,g,f,t,e,s):r(g,y,f,e,t,s);if(w!==i){if(w)continue;d=!1;break}if(p){if(!Ln(t,(function(e,t){if(!Xn(p,t)&&(g===e||o(g,e,n,r,s)))return p.push(t)}))){d=!1;break}}else if(g!==y&&!o(g,y,n,r,s)){d=!1;break}}return s["delete"](e),s["delete"](t),d}function Ds(e,t,n,r,i,o,s){switch(n){case fe:if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case he:return!(e.byteLength!=t.byteLength||!o(new bt(e),new bt(t)));case G:case K:case J:return iu(+e,+t);case Z:return e.name==t.name&&e.message==t.message;case ie:case se:return e==t+"";case Q:var a=lr;case oe:var l=r&m;if(a||(a=hr),e.size!=t.size&&!l)return!1;var c=s.get(e);if(c)return c==t;r|=v,s.set(e,t);var u=Ps(a(e),a(t),r,i,o,s);return s["delete"](e),u;case ae:if(wr)return wr.call(e)==wr.call(t)}return!1}function Fs(e,t,n,r,o,s){var a=n&m,l=Ws(e),c=l.length,u=Ws(t),h=u.length;if(c!=h&&!a)return!1;var f=c;while(f--){var d=l[f];if(!(a?d in t:ht.call(t,d)))return!1}var p=s.get(e),g=s.get(t);if(p&&g)return p==t&&g==e;var v=!0;s.set(e,t),s.set(t,e);var y=a;while(++f<c){d=l[f];var w=e[d],b=t[d];if(r)var x=a?r(b,w,d,t,e,s):r(w,b,d,e,t,s);if(!(x===i?w===b||o(w,b,n,r,s):x)){v=!1;break}y||(y="constructor"==d)}if(v&&!y){var S=e.constructor,_=t.constructor;S==_||!("constructor"in e)||!("constructor"in t)||"function"==typeof S&&S instanceof S&&"function"==typeof _&&_ instanceof _||(v=!1)}return s["delete"](e),s["delete"](t),v}function Bs(e){return $a(ba(e,i,qa),e+"")}function Ws(e){return Pi(e,Sh,Zs)}function Ns(e){return Pi(e,_h,Ys)}var Hs=ln?function(e){return ln.get(e)}:Wf;function js(e){var t=e.name+"",n=cn[t],r=ht.call(cn,t)?n.length:0;while(r--){var i=n[r],o=i.func;if(null==o||o==e)return i.name}return t}function zs(e){var t=ht.call(Sr,"placeholder")?Sr:e;return t.placeholder}function Us(){var e=Sr.iteratee||Mf;return e=e===Mf?to:e,arguments.length?e(arguments[0],arguments[1]):e}function Vs(e,t){var n=e.__data__;return ca(t)?n["string"==typeof t?"string":"hash"]:n.map}function Gs(e){var t=Sh(e),n=t.length;while(n--){var r=t[n],i=e[r];t[n]=[r,i,pa(i)]}return t}function Ks(e,t){var n=ir(e,t);return Xi(n)?n:i}function qs(e){var t=ht.call(e,Rt),n=e[Rt];try{e[Rt]=i;var r=!0}catch(s){}var o=pt.call(e);return r&&(t?e[Rt]=n:delete e[Rt]),o}var Zs=Pt?function(e){return null==e?[]:(e=nt(e),kn(Pt(e),(function(t){return kt.call(e,t)})))}:qf,Ys=Pt?function(e){var t=[];while(e)Rn(t,Zs(e)),e=St(e);return t}:qf,Xs=Di;function Qs(e,t,n){var r=-1,i=n.length;while(++r<i){var o=n[r],s=o.size;switch(o.type){case"drop":e+=s;break;case"dropRight":t-=s;break;case"take":t=Ht(t,e+s);break;case"takeRight":e=Nt(e,t-s);break}}return{start:e,end:t}}function Js(e){var t=e.match(Ne);return t?t[1].split(He):[]}function ea(e,t,n){t=Uo(t,e);var r=-1,i=t.length,o=!1;while(++r<i){var s=La(t[r]);if(!(o=null!=e&&n(e,s)))break;e=e[s]}return o||++r!=i?o:(i=null==e?0:e.length,!!i&&_u(i)&&sa(s,i)&&(lu(e)||au(e)))}function ta(e){var t=e.length,n=new e.constructor(t);return t&&"string"==typeof e[0]&&ht.call(e,"index")&&(n.index=e.index,n.input=e.input),n}function na(e){return"function"!=typeof e.constructor||da(e)?{}:kr(St(e))}function ra(e,t,n){var r=e.constructor;switch(t){case he:return Zo(e);case G:case K:return new r(+e);case fe:return Yo(e,n);case de:case pe:case ge:case me:case ve:case ye:case we:case be:case xe:return Jo(e,n);case Q:return new r;case J:case se:return new r(e);case ie:return Xo(e);case oe:return new r;case ae:return Qo(e)}}function ia(e,t){var n=t.length;if(!n)return e;var r=n-1;return t[r]=(n>1?"& ":"")+t[r],t=t.join(n>2?", ":" "),e.replace(We,"{\n/* [wrapped with "+t+"] */\n")}function oa(e){return lu(e)||au(e)||!!($t&&e&&e[$t])}function sa(e,t){var n=typeof e;return t=null==t?D:t,!!t&&("number"==n||"symbol"!=n&&Xe.test(e))&&e>-1&&e%1==0&&e<t}function aa(e,t,n){if(!ku(n))return!1;var r=typeof t;return!!("number"==r?uu(n)&&sa(t,n.length):"string"==r&&t in n)&&iu(n[t],e)}function la(e,t){if(lu(e))return!1;var n=typeof e;return!("number"!=n&&"symbol"!=n&&"boolean"!=n&&null!=e&&!Wu(e))||(Oe.test(e)||!Me.test(e)||null!=t&&e in nt(t))}function ca(e){var t=typeof e;return"string"==t||"number"==t||"symbol"==t||"boolean"==t?"__proto__"!==e:null===e}function ua(e){var t=js(e),n=Sr[t];if("function"!=typeof n||!(t in Ar.prototype))return!1;if(e===n)return!0;var r=Hs(n);return!!r&&e===r[0]}function ha(e){return!!dt&&dt in e}(Qt&&Xs(new Qt(new ArrayBuffer(1)))!=fe||Jt&&Xs(new Jt)!=Q||en&&Xs(en.resolve())!=ne||tn&&Xs(new tn)!=oe||on&&Xs(new on)!=ce)&&(Xs=function(e){var t=Di(e),n=t==te?e.constructor:i,r=n?Ma(n):"";if(r)switch(r){case hn:return fe;case fn:return Q;case Mn:return ne;case On:return oe;case jn:return ce}return t});var fa=ct?xu:Zf;function da(e){var t=e&&e.constructor,n="function"==typeof t&&t.prototype||lt;return e===n}function pa(e){return e===e&&!ku(e)}function ga(e,t){return function(n){return null!=n&&(n[e]===t&&(t!==i||e in nt(n)))}}function ma(e){var t=Nc(e,(function(e){return n.size===h&&n.clear(),e})),n=t.cache;return t}function va(e,t){var n=e[1],r=t[1],i=n|r,o=i<(y|w|C),s=r==C&&n==x||r==C&&n==$&&e[7].length<=t[8]||r==(C|$)&&t[7].length<=t[8]&&n==x;if(!o&&!s)return e;r&y&&(e[2]=t[2],i|=n&y?0:b);var a=t[3];if(a){var l=e[3];e[3]=l?ns(l,a,t[4]):a,e[4]=l?ur(e[3],f):t[4]}return a=t[5],a&&(l=e[5],e[5]=l?rs(l,a,t[6]):a,e[6]=l?ur(e[5],f):t[6]),a=t[7],a&&(e[7]=a),r&C&&(e[8]=null==e[8]?t[8]:Ht(e[8],t[8])),null==e[9]&&(e[9]=t[9]),e[0]=t[0],e[1]=i,e}function ya(e){var t=[];if(null!=e)for(var n in nt(e))t.push(n);return t}function wa(e){return pt.call(e)}function ba(e,t,r){return t=Nt(t===i?e.length-1:t,0),function(){var i=arguments,o=-1,s=Nt(i.length-t,0),a=n(s);while(++o<s)a[o]=i[t+o];o=-1;var l=n(t+1);while(++o<t)l[o]=i[o];return l[t]=r(a),wn(e,this,l)}}function xa(e,t){return t.length<2?e:Ii(e,Ro(t,0,-1))}function Sa(e,t){var n=e.length,r=Ht(t.length,n),o=is(e);while(r--){var s=t[r];e[r]=sa(s,n)?o[s]:i}return e}function _a(e,t){if(("constructor"!==t||"function"!==typeof e[t])&&"__proto__"!=t)return e[t]}var ka=Ra(Co),Ca=Mt||function(e,t){return an.setTimeout(e,t)},$a=Ra($o);function Aa(e,t,n){var r=t+"";return $a(e,ia(r,Oa(Js(r),n)))}function Ra(e){var t=0,n=0;return function(){var r=Ut(),o=L-(r-n);if(n=r,o>0){if(++t>=E)return arguments[0]}else t=0;return e.apply(i,arguments)}}function Ta(e,t){var n=-1,r=e.length,o=r-1;t=t===i?r:t;while(++n<t){var s=yo(n,o),a=e[s];e[s]=e[n],e[n]=a}return e.length=t,e}var Ea=ma((function(e){var t=[];return 46===e.charCodeAt(0)&&t.push(""),e.replace(Ie,(function(e,n,r,i){t.push(r?i.replace(Ue,"$1"):n||e)})),t}));function La(e){if("string"==typeof e||Wu(e))return e;var t=e+"";return"0"==t&&1/e==-P?"-0":t}function Ma(e){if(null!=e){try{return ut.call(e)}catch(t){}try{return e+""}catch(t){}}return""}function Oa(e,t){return xn(j,(function(n){var r="_."+n[0];t&n[1]&&!Cn(e,r)&&e.push(r)})),e.sort()}function Ia(e){if(e instanceof Ar)return e.clone();var t=new $r(e.__wrapped__,e.__chain__);return t.__actions__=is(e.__actions__),t.__index__=e.__index__,t.__values__=e.__values__,t}function Pa(e,t,r){t=(r?aa(e,t,r):t===i)?1:Nt(qu(t),0);var o=null==e?0:e.length;if(!o||t<1)return[];var s=0,a=0,l=n(Ot(o/t));while(s<o)l[a++]=Ro(e,s,s+=t);return l}function Da(e){var t=-1,n=null==e?0:e.length,r=0,i=[];while(++t<n){var o=e[t];o&&(i[r++]=o)}return i}function Fa(){var e=arguments.length;if(!e)return[];var t=n(e-1),r=arguments[0],i=e;while(i--)t[i-1]=arguments[i];return Rn(lu(r)?is(r):[r],Ri(t,1))}var Ba=xo((function(e,t){return hu(e)?xi(e,Ri(t,1,hu,!0)):[]})),Wa=xo((function(e,t){var n=ol(t);return hu(n)&&(n=i),hu(e)?xi(e,Ri(t,1,hu,!0),Us(n,2)):[]})),Na=xo((function(e,t){var n=ol(t);return hu(n)&&(n=i),hu(e)?xi(e,Ri(t,1,hu,!0),i,n):[]}));function Ha(e,t,n){var r=null==e?0:e.length;return r?(t=n||t===i?1:qu(t),Ro(e,t<0?0:t,r)):[]}function ja(e,t,n){var r=null==e?0:e.length;return r?(t=n||t===i?1:qu(t),t=r-t,Ro(e,0,t<0?0:t)):[]}function za(e,t){return e&&e.length?Bo(e,Us(t,3),!0,!0):[]}function Ua(e,t){return e&&e.length?Bo(e,Us(t,3),!0):[]}function Va(e,t,n,r){var i=null==e?0:e.length;return i?(n&&"number"!=typeof n&&aa(e,t,n)&&(n=0,r=i),$i(e,t,n,r)):[]}function Ga(e,t,n){var r=null==e?0:e.length;if(!r)return-1;var i=null==n?0:qu(n);return i<0&&(i=Nt(r+i,0)),Dn(e,Us(t,3),i)}function Ka(e,t,n){var r=null==e?0:e.length;if(!r)return-1;var o=r-1;return n!==i&&(o=qu(n),o=n<0?Nt(r+o,0):Ht(o,r-1)),Dn(e,Us(t,3),o,!0)}function qa(e){var t=null==e?0:e.length;return t?Ri(e,1):[]}function Za(e){var t=null==e?0:e.length;return t?Ri(e,P):[]}function Ya(e,t){var n=null==e?0:e.length;return n?(t=t===i?1:qu(t),Ri(e,t)):[]}function Xa(e){var t=-1,n=null==e?0:e.length,r={};while(++t<n){var i=e[t];r[i[0]]=i[1]}return r}function Qa(e){return e&&e.length?e[0]:i}function Ja(e,t,n){var r=null==e?0:e.length;if(!r)return-1;var i=null==n?0:qu(n);return i<0&&(i=Nt(r+i,0)),Fn(e,t,i)}function el(e){var t=null==e?0:e.length;return t?Ro(e,0,-1):[]}var tl=xo((function(e){var t=An(e,jo);return t.length&&t[0]===e[0]?Hi(t):[]})),nl=xo((function(e){var t=ol(e),n=An(e,jo);return t===ol(n)?t=i:n.pop(),n.length&&n[0]===e[0]?Hi(n,Us(t,2)):[]})),rl=xo((function(e){var t=ol(e),n=An(e,jo);return t="function"==typeof t?t:i,t&&n.pop(),n.length&&n[0]===e[0]?Hi(n,i,t):[]}));function il(e,t){return null==e?"":Bt.call(e,t)}function ol(e){var t=null==e?0:e.length;return t?e[t-1]:i}function sl(e,t,n){var r=null==e?0:e.length;if(!r)return-1;var o=r;return n!==i&&(o=qu(n),o=o<0?Nt(r+o,0):Ht(o,r-1)),t===t?pr(e,t,o):Dn(e,Wn,o,!0)}function al(e,t){return e&&e.length?uo(e,qu(t)):i}var ll=xo(cl);function cl(e,t){return e&&e.length&&t&&t.length?mo(e,t):e}function ul(e,t,n){return e&&e.length&&t&&t.length?mo(e,t,Us(n,2)):e}function hl(e,t,n){return e&&e.length&&t&&t.length?mo(e,t,i,n):e}var fl=Bs((function(e,t){var n=null==e?0:e.length,r=gi(e,t);return vo(e,An(t,(function(e){return sa(e,n)?+e:e})).sort(es)),r}));function dl(e,t){var n=[];if(!e||!e.length)return n;var r=-1,i=[],o=e.length;t=Us(t,3);while(++r<o){var s=e[r];t(s,r,e)&&(n.push(s),i.push(r))}return vo(e,i),n}function pl(e){return null==e?e:Kt.call(e)}function gl(e,t,n){var r=null==e?0:e.length;return r?(n&&"number"!=typeof n&&aa(e,t,n)?(t=0,n=r):(t=null==t?0:qu(t),n=n===i?r:qu(n)),Ro(e,t,n)):[]}function ml(e,t){return Eo(e,t)}function vl(e,t,n){return Lo(e,t,Us(n,2))}function yl(e,t){var n=null==e?0:e.length;if(n){var r=Eo(e,t);if(r<n&&iu(e[r],t))return r}return-1}function wl(e,t){return Eo(e,t,!0)}function bl(e,t,n){return Lo(e,t,Us(n,2),!0)}function xl(e,t){var n=null==e?0:e.length;if(n){var r=Eo(e,t,!0)-1;if(iu(e[r],t))return r}return-1}function Sl(e){return e&&e.length?Mo(e):[]}function _l(e,t){return e&&e.length?Mo(e,Us(t,2)):[]}function kl(e){var t=null==e?0:e.length;return t?Ro(e,1,t):[]}function Cl(e,t,n){return e&&e.length?(t=n||t===i?1:qu(t),Ro(e,0,t<0?0:t)):[]}function $l(e,t,n){var r=null==e?0:e.length;return r?(t=n||t===i?1:qu(t),t=r-t,Ro(e,t<0?0:t,r)):[]}function Al(e,t){return e&&e.length?Bo(e,Us(t,3),!1,!0):[]}function Rl(e,t){return e&&e.length?Bo(e,Us(t,3)):[]}var Tl=xo((function(e){return Po(Ri(e,1,hu,!0))})),El=xo((function(e){var t=ol(e);return hu(t)&&(t=i),Po(Ri(e,1,hu,!0),Us(t,2))})),Ll=xo((function(e){var t=ol(e);return t="function"==typeof t?t:i,Po(Ri(e,1,hu,!0),i,t)}));function Ml(e){return e&&e.length?Po(e):[]}function Ol(e,t){return e&&e.length?Po(e,Us(t,2)):[]}function Il(e,t){return t="function"==typeof t?t:i,e&&e.length?Po(e,i,t):[]}function Pl(e){if(!e||!e.length)return[];var t=0;return e=kn(e,(function(e){if(hu(e))return t=Nt(e.length,t),!0})),Gn(t,(function(t){return An(e,Hn(t))}))}function Dl(e,t){if(!e||!e.length)return[];var n=Pl(e);return null==t?n:An(n,(function(e){return wn(t,i,e)}))}var Fl=xo((function(e,t){return hu(e)?xi(e,t):[]})),Bl=xo((function(e){return No(kn(e,hu))})),Wl=xo((function(e){var t=ol(e);return hu(t)&&(t=i),No(kn(e,hu),Us(t,2))})),Nl=xo((function(e){var t=ol(e);return t="function"==typeof t?t:i,No(kn(e,hu),i,t)})),Hl=xo(Pl);function jl(e,t){return Ho(e||[],t||[],ci)}function zl(e,t){return Ho(e||[],t||[],ko)}var Ul=xo((function(e){var t=e.length,n=t>1?e[t-1]:i;return n="function"==typeof n?(e.pop(),n):i,Dl(e,n)}));function Vl(e){var t=Sr(e);return t.__chain__=!0,t}function Gl(e,t){return t(e),e}function Kl(e,t){return t(e)}var ql=Bs((function(e){var t=e.length,n=t?e[0]:0,r=this.__wrapped__,o=function(t){return gi(t,e)};return!(t>1||this.__actions__.length)&&r instanceof Ar&&sa(n)?(r=r.slice(n,+n+(t?1:0)),r.__actions__.push({func:Kl,args:[o],thisArg:i}),new $r(r,this.__chain__).thru((function(e){return t&&!e.length&&e.push(i),e}))):this.thru(o)}));function Zl(){return Vl(this)}function Yl(){return new $r(this.value(),this.__chain__)}function Xl(){this.__values__===i&&(this.__values__=Gu(this.value()));var e=this.__index__>=this.__values__.length,t=e?i:this.__values__[this.__index__++];return{done:e,value:t}}function Ql(){return this}function Jl(e){var t,n=this;while(n instanceof Cr){var r=Ia(n);r.__index__=0,r.__values__=i,t?o.__wrapped__=r:t=r;var o=r;n=n.__wrapped__}return o.__wrapped__=e,t}function ec(){var e=this.__wrapped__;if(e instanceof Ar){var t=e;return this.__actions__.length&&(t=new Ar(this)),t=t.reverse(),t.__actions__.push({func:Kl,args:[pl],thisArg:i}),new $r(t,this.__chain__)}return this.thru(pl)}function tc(){return Wo(this.__wrapped__,this.__actions__)}var nc=ls((function(e,t,n){ht.call(e,n)?++e[n]:pi(e,n,1)}));function rc(e,t,n){var r=lu(e)?_n:ki;return n&&aa(e,t,n)&&(t=i),r(e,Us(t,3))}function ic(e,t){var n=lu(e)?kn:Ai;return n(e,Us(t,3))}var oc=vs(Ga),sc=vs(Ka);function ac(e,t){return Ri(mc(e,t),1)}function lc(e,t){return Ri(mc(e,t),P)}function cc(e,t,n){return n=n===i?1:qu(n),Ri(mc(e,t),n)}function uc(e,t){var n=lu(e)?xn:Si;return n(e,Us(t,3))}function hc(e,t){var n=lu(e)?Sn:_i;return n(e,Us(t,3))}var fc=ls((function(e,t,n){ht.call(e,n)?e[n].push(t):pi(e,n,[t])}));function dc(e,t,n,r){e=uu(e)?e:Hh(e),n=n&&!r?qu(n):0;var i=e.length;return n<0&&(n=Nt(i+n,0)),Bu(e)?n<=i&&e.indexOf(t,n)>-1:!!i&&Fn(e,t,n)>-1}var pc=xo((function(e,t,r){var i=-1,o="function"==typeof t,s=uu(e)?n(e.length):[];return Si(e,(function(e){s[++i]=o?wn(t,e,r):zi(e,t,r)})),s})),gc=ls((function(e,t,n){pi(e,n,t)}));function mc(e,t){var n=lu(e)?An:oo;return n(e,Us(t,3))}function vc(e,t,n,r){return null==e?[]:(lu(t)||(t=null==t?[]:[t]),n=r?i:n,lu(n)||(n=null==n?[]:[n]),ho(e,t,n))}var yc=ls((function(e,t,n){e[n?0:1].push(t)}),(function(){return[[],[]]}));function wc(e,t,n){var r=lu(e)?Tn:zn,i=arguments.length<3;return r(e,Us(t,4),n,i,Si)}function bc(e,t,n){var r=lu(e)?En:zn,i=arguments.length<3;return r(e,Us(t,4),n,i,_i)}function xc(e,t){var n=lu(e)?kn:Ai;return n(e,Hc(Us(t,3)))}function Sc(e){var t=lu(e)?oi:So;return t(e)}function _c(e,t,n){t=(n?aa(e,t,n):t===i)?1:qu(t);var r=lu(e)?si:_o;return r(e,t)}function kc(e){var t=lu(e)?ai:Ao;return t(e)}function Cc(e){if(null==e)return 0;if(uu(e))return Bu(e)?gr(e):e.length;var t=Xs(e);return t==Q||t==oe?e.size:no(e).length}function $c(e,t,n){var r=lu(e)?Ln:To;return n&&aa(e,t,n)&&(t=i),r(e,Us(t,3))}var Ac=xo((function(e,t){if(null==e)return[];var n=t.length;return n>1&&aa(e,t[0],t[1])?t=[]:n>2&&aa(t[0],t[1],t[2])&&(t=[t[0]]),ho(e,Ri(t,1),[])})),Rc=Lt||function(){return an.Date.now()};function Tc(e,t){if("function"!=typeof t)throw new ot(l);return e=qu(e),function(){if(--e<1)return t.apply(this,arguments)}}function Ec(e,t,n){return t=n?i:t,t=e&&null==t?e.length:t,Ls(e,C,i,i,i,i,t)}function Lc(e,t){var n;if("function"!=typeof t)throw new ot(l);return e=qu(e),function(){return--e>0&&(n=t.apply(this,arguments)),e<=1&&(t=i),n}}var Mc=xo((function(e,t,n){var r=y;if(n.length){var i=ur(n,zs(Mc));r|=_}return Ls(e,r,t,n,i)})),Oc=xo((function(e,t,n){var r=y|w;if(n.length){var i=ur(n,zs(Oc));r|=_}return Ls(t,r,e,n,i)}));function Ic(e,t,n){t=n?i:t;var r=Ls(e,x,i,i,i,i,i,t);return r.placeholder=Ic.placeholder,r}function Pc(e,t,n){t=n?i:t;var r=Ls(e,S,i,i,i,i,i,t);return r.placeholder=Pc.placeholder,r}function Dc(e,t,n){var r,o,s,a,c,u,h=0,f=!1,d=!1,p=!0;if("function"!=typeof e)throw new ot(l);function g(t){var n=r,s=o;return r=o=i,h=t,a=e.apply(s,n),a}function m(e){return h=e,c=Ca(w,t),f?g(e):a}function v(e){var n=e-u,r=e-h,i=t-n;return d?Ht(i,s-r):i}function y(e){var n=e-u,r=e-h;return u===i||n>=t||n<0||d&&r>=s}function w(){var e=Rc();if(y(e))return b(e);c=Ca(w,v(e))}function b(e){return c=i,p&&r?g(e):(r=o=i,a)}function x(){c!==i&&Ko(c),h=0,r=u=o=c=i}function S(){return c===i?a:b(Rc())}function _(){var e=Rc(),n=y(e);if(r=arguments,o=this,u=e,n){if(c===i)return m(u);if(d)return Ko(c),c=Ca(w,t),g(u)}return c===i&&(c=Ca(w,t)),a}return t=Yu(t)||0,ku(n)&&(f=!!n.leading,d="maxWait"in n,s=d?Nt(Yu(n.maxWait)||0,t):s,p="trailing"in n?!!n.trailing:p),_.cancel=x,_.flush=S,_}var Fc=xo((function(e,t){return bi(e,1,t)})),Bc=xo((function(e,t,n){return bi(e,Yu(t)||0,n)}));function Wc(e){return Ls(e,A)}function Nc(e,t){if("function"!=typeof e||null!=t&&"function"!=typeof t)throw new ot(l);var n=function(){var r=arguments,i=t?t.apply(this,r):r[0],o=n.cache;if(o.has(i))return o.get(i);var s=e.apply(this,r);return n.cache=o.set(i,s)||o,s};return n.cache=new(Nc.Cache||zr),n}function Hc(e){if("function"!=typeof e)throw new ot(l);return function(){var t=arguments;switch(t.length){case 0:return!e.call(this);case 1:return!e.call(this,t[0]);case 2:return!e.call(this,t[0],t[1]);case 3:return!e.call(this,t[0],t[1],t[2])}return!e.apply(this,t)}}function jc(e){return Lc(2,e)}Nc.Cache=zr;var zc=Vo((function(e,t){t=1==t.length&&lu(t[0])?An(t[0],Zn(Us())):An(Ri(t,1),Zn(Us()));var n=t.length;return xo((function(r){var i=-1,o=Ht(r.length,n);while(++i<o)r[i]=t[i].call(this,r[i]);return wn(e,this,r)}))})),Uc=xo((function(e,t){var n=ur(t,zs(Uc));return Ls(e,_,i,t,n)})),Vc=xo((function(e,t){var n=ur(t,zs(Vc));return Ls(e,k,i,t,n)})),Gc=Bs((function(e,t){return Ls(e,$,i,i,i,t)}));function Kc(e,t){if("function"!=typeof e)throw new ot(l);return t=t===i?t:qu(t),xo(e,t)}function qc(e,t){if("function"!=typeof e)throw new ot(l);return t=null==t?0:Nt(qu(t),0),xo((function(n){var r=n[t],i=Go(n,0,t);return r&&Rn(i,r),wn(e,this,i)}))}function Zc(e,t,n){var r=!0,i=!0;if("function"!=typeof e)throw new ot(l);return ku(n)&&(r="leading"in n?!!n.leading:r,i="trailing"in n?!!n.trailing:i),Dc(e,t,{leading:r,maxWait:t,trailing:i})}function Yc(e){return Ec(e,1)}function Xc(e,t){return Uc(zo(t),e)}function Qc(){if(!arguments.length)return[];var e=arguments[0];return lu(e)?e:[e]}function Jc(e){return vi(e,g)}function eu(e,t){return t="function"==typeof t?t:i,vi(e,g,t)}function tu(e){return vi(e,d|g)}function nu(e,t){return t="function"==typeof t?t:i,vi(e,d|g,t)}function ru(e,t){return null==t||wi(e,t,Sh(t))}function iu(e,t){return e===t||e!==e&&t!==t}var ou=$s(Fi),su=$s((function(e,t){return e>=t})),au=Ui(function(){return arguments}())?Ui:function(e){return Cu(e)&&ht.call(e,"callee")&&!kt.call(e,"callee")},lu=n.isArray,cu=dn?Zn(dn):Vi;function uu(e){return null!=e&&_u(e.length)&&!xu(e)}function hu(e){return Cu(e)&&uu(e)}function fu(e){return!0===e||!1===e||Cu(e)&&Di(e)==G}var du=Dt||Zf,pu=pn?Zn(pn):Gi;function gu(e){return Cu(e)&&1===e.nodeType&&!Iu(e)}function mu(e){if(null==e)return!0;if(uu(e)&&(lu(e)||"string"==typeof e||"function"==typeof e.splice||du(e)||Nu(e)||au(e)))return!e.length;var t=Xs(e);if(t==Q||t==oe)return!e.size;if(da(e))return!no(e).length;for(var n in e)if(ht.call(e,n))return!1;return!0}function vu(e,t){return Ki(e,t)}function yu(e,t,n){n="function"==typeof n?n:i;var r=n?n(e,t):i;return r===i?Ki(e,t,i,n):!!r}function wu(e){if(!Cu(e))return!1;var t=Di(e);return t==Z||t==q||"string"==typeof e.message&&"string"==typeof e.name&&!Iu(e)}function bu(e){return"number"==typeof e&&Ft(e)}function xu(e){if(!ku(e))return!1;var t=Di(e);return t==Y||t==X||t==V||t==re}function Su(e){return"number"==typeof e&&e==qu(e)}function _u(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=D}function ku(e){var t=typeof e;return null!=e&&("object"==t||"function"==t)}function Cu(e){return null!=e&&"object"==typeof e}var $u=gn?Zn(gn):Zi;function Au(e,t){return e===t||Yi(e,t,Gs(t))}function Ru(e,t,n){return n="function"==typeof n?n:i,Yi(e,t,Gs(t),n)}function Tu(e){return Ou(e)&&e!=+e}function Eu(e){if(fa(e))throw new Be(a);return Xi(e)}function Lu(e){return null===e}function Mu(e){return null==e}function Ou(e){return"number"==typeof e||Cu(e)&&Di(e)==J}function Iu(e){if(!Cu(e)||Di(e)!=te)return!1;var t=St(e);if(null===t)return!0;var n=ht.call(t,"constructor")&&t.constructor;return"function"==typeof n&&n instanceof n&&ut.call(n)==gt}var Pu=mn?Zn(mn):Qi;function Du(e){return Su(e)&&e>=-D&&e<=D}var Fu=vn?Zn(vn):Ji;function Bu(e){return"string"==typeof e||!lu(e)&&Cu(e)&&Di(e)==se}function Wu(e){return"symbol"==typeof e||Cu(e)&&Di(e)==ae}var Nu=yn?Zn(yn):eo;function Hu(e){return e===i}function ju(e){return Cu(e)&&Xs(e)==ce}function zu(e){return Cu(e)&&Di(e)==ue}var Uu=$s(io),Vu=$s((function(e,t){return e<=t}));function Gu(e){if(!e)return[];if(uu(e))return Bu(e)?mr(e):is(e);if(At&&e[At])return ar(e[At]());var t=Xs(e),n=t==Q?lr:t==oe?hr:Hh;return n(e)}function Ku(e){if(!e)return 0===e?e:0;if(e=Yu(e),e===P||e===-P){var t=e<0?-1:1;return t*F}return e===e?e:0}function qu(e){var t=Ku(e),n=t%1;return t===t?n?t-n:t:0}function Zu(e){return e?mi(qu(e),0,W):0}function Yu(e){if("number"==typeof e)return e;if(Wu(e))return B;if(ku(e)){var t="function"==typeof e.valueOf?e.valueOf():e;e=ku(t)?t+"":t}if("string"!=typeof e)return 0===e?e:+e;e=qn(e);var n=qe.test(e);return n||Ye.test(e)?rn(e.slice(2),n?2:8):Ke.test(e)?B:+e}function Xu(e){return os(e,_h(e))}function Qu(e){return e?mi(qu(e),-D,D):0===e?e:0}function Ju(e){return null==e?"":Io(e)}var eh=cs((function(e,t){if(da(t)||uu(t))os(t,Sh(t),e);else for(var n in t)ht.call(t,n)&&ci(e,n,t[n])})),th=cs((function(e,t){os(t,_h(t),e)})),nh=cs((function(e,t,n,r){os(t,_h(t),e,r)})),rh=cs((function(e,t,n,r){os(t,Sh(t),e,r)})),ih=Bs(gi);function oh(e,t){var n=kr(e);return null==t?n:fi(n,t)}var sh=xo((function(e,t){e=nt(e);var n=-1,r=t.length,o=r>2?t[2]:i;o&&aa(t[0],t[1],o)&&(r=1);while(++n<r){var s=t[n],a=_h(s),l=-1,c=a.length;while(++l<c){var u=a[l],h=e[u];(h===i||iu(h,lt[u])&&!ht.call(e,u))&&(e[u]=s[u])}}return e})),ah=xo((function(e){return e.push(i,Os),wn(Ah,i,e)}));function lh(e,t){return Pn(e,Us(t,3),Li)}function ch(e,t){return Pn(e,Us(t,3),Mi)}function uh(e,t){return null==e?e:Ti(e,Us(t,3),_h)}function hh(e,t){return null==e?e:Ei(e,Us(t,3),_h)}function fh(e,t){return e&&Li(e,Us(t,3))}function dh(e,t){return e&&Mi(e,Us(t,3))}function ph(e){return null==e?[]:Oi(e,Sh(e))}function gh(e){return null==e?[]:Oi(e,_h(e))}function mh(e,t,n){var r=null==e?i:Ii(e,t);return r===i?n:r}function vh(e,t){return null!=e&&ea(e,t,Bi)}function yh(e,t){return null!=e&&ea(e,t,Wi)}var wh=bs((function(e,t,n){null!=t&&"function"!=typeof t.toString&&(t=pt.call(t)),e[t]=n}),Af(Lf)),bh=bs((function(e,t,n){null!=t&&"function"!=typeof t.toString&&(t=pt.call(t)),ht.call(e,t)?e[t].push(n):e[t]=[n]}),Us),xh=xo(zi);function Sh(e){return uu(e)?ii(e):no(e)}function _h(e){return uu(e)?ii(e,!0):ro(e)}function kh(e,t){var n={};return t=Us(t,3),Li(e,(function(e,r,i){pi(n,t(e,r,i),e)})),n}function Ch(e,t){var n={};return t=Us(t,3),Li(e,(function(e,r,i){pi(n,r,t(e,r,i))})),n}var $h=cs((function(e,t,n){lo(e,t,n)})),Ah=cs((function(e,t,n,r){lo(e,t,n,r)})),Rh=Bs((function(e,t){var n={};if(null==e)return n;var r=!1;t=An(t,(function(t){return t=Uo(t,e),r||(r=t.length>1),t})),os(e,Ns(e),n),r&&(n=vi(n,d|p|g,Is));var i=t.length;while(i--)Do(n,t[i]);return n}));function Th(e,t){return Lh(e,Hc(Us(t)))}var Eh=Bs((function(e,t){return null==e?{}:fo(e,t)}));function Lh(e,t){if(null==e)return{};var n=An(Ns(e),(function(e){return[e]}));return t=Us(t),po(e,n,(function(e,n){return t(e,n[0])}))}function Mh(e,t,n){t=Uo(t,e);var r=-1,o=t.length;o||(o=1,e=i);while(++r<o){var s=null==e?i:e[La(t[r])];s===i&&(r=o,s=n),e=xu(s)?s.call(e):s}return e}function Oh(e,t,n){return null==e?e:ko(e,t,n)}function Ih(e,t,n,r){return r="function"==typeof r?r:i,null==e?e:ko(e,t,n,r)}var Ph=Es(Sh),Dh=Es(_h);function Fh(e,t,n){var r=lu(e),i=r||du(e)||Nu(e);if(t=Us(t,4),null==n){var o=e&&e.constructor;n=i?r?new o:[]:ku(e)&&xu(o)?kr(St(e)):{}}return(i?xn:Li)(e,(function(e,r,i){return t(n,e,r,i)})),n}function Bh(e,t){return null==e||Do(e,t)}function Wh(e,t,n){return null==e?e:Fo(e,t,zo(n))}function Nh(e,t,n,r){return r="function"==typeof r?r:i,null==e?e:Fo(e,t,zo(n),r)}function Hh(e){return null==e?[]:Yn(e,Sh(e))}function jh(e){return null==e?[]:Yn(e,_h(e))}function zh(e,t,n){return n===i&&(n=t,t=i),n!==i&&(n=Yu(n),n=n===n?n:0),t!==i&&(t=Yu(t),t=t===t?t:0),mi(Yu(e),t,n)}function Uh(e,t,n){return t=Ku(t),n===i?(n=t,t=0):n=Ku(n),e=Yu(e),Ni(e,t,n)}function Vh(e,t,n){if(n&&"boolean"!=typeof n&&aa(e,t,n)&&(t=n=i),n===i&&("boolean"==typeof t?(n=t,t=i):"boolean"==typeof e&&(n=e,e=i)),e===i&&t===i?(e=0,t=1):(e=Ku(e),t===i?(t=e,e=0):t=Ku(t)),e>t){var r=e;e=t,t=r}if(n||e%1||t%1){var o=Gt();return Ht(e+o*(t-e+nn("1e-"+((o+"").length-1))),t)}return yo(e,t)}var Gh=ps((function(e,t,n){return t=t.toLowerCase(),e+(n?Kh(t):t)}));function Kh(e){return xf(Ju(e).toLowerCase())}function qh(e){return e=Ju(e),e&&e.replace(Qe,tr).replace(zt,"")}function Zh(e,t,n){e=Ju(e),t=Io(t);var r=e.length;n=n===i?r:mi(qu(n),0,r);var o=n;return n-=t.length,n>=0&&e.slice(n,o)==t}function Yh(e){return e=Ju(e),e&&Re.test(e)?e.replace($e,nr):e}function Xh(e){return e=Ju(e),e&&De.test(e)?e.replace(Pe,"\\$&"):e}var Qh=ps((function(e,t,n){return e+(n?"-":"")+t.toLowerCase()})),Jh=ps((function(e,t,n){return e+(n?" ":"")+t.toLowerCase()})),ef=ds("toLowerCase");function tf(e,t,n){e=Ju(e),t=qu(t);var r=t?gr(e):0;if(!t||r>=t)return e;var i=(t-r)/2;return _s(It(i),n)+e+_s(Ot(i),n)}function nf(e,t,n){e=Ju(e),t=qu(t);var r=t?gr(e):0;return t&&r<t?e+_s(t-r,n):e}function rf(e,t,n){e=Ju(e),t=qu(t);var r=t?gr(e):0;return t&&r<t?_s(t-r,n)+e:e}function of(e,t,n){return n||null==t?t=0:t&&(t=+t),Vt(Ju(e).replace(Fe,""),t||0)}function sf(e,t,n){return t=(n?aa(e,t,n):t===i)?1:qu(t),bo(Ju(e),t)}function af(){var e=arguments,t=Ju(e[0]);return e.length<3?t:t.replace(e[1],e[2])}var lf=ps((function(e,t,n){return e+(n?"_":"")+t.toLowerCase()}));function cf(e,t,n){return n&&"number"!=typeof n&&aa(e,t,n)&&(t=n=i),n=n===i?W:n>>>0,n?(e=Ju(e),e&&("string"==typeof t||null!=t&&!Pu(t))&&(t=Io(t),!t&&or(e))?Go(mr(e),0,n):e.split(t,n)):[]}var uf=ps((function(e,t,n){return e+(n?" ":"")+xf(t)}));function hf(e,t,n){return e=Ju(e),n=null==n?0:mi(qu(n),0,e.length),t=Io(t),e.slice(n,n+t.length)==t}function ff(e,t,n){var r=Sr.templateSettings;n&&aa(e,t,n)&&(t=i),e=Ju(e),t=nh({},t,r,Ms);var o,s,a=nh({},t.imports,r.imports,Ms),l=Sh(a),u=Yn(a,l),h=0,f=t.interpolate||Je,d="__p += '",p=rt((t.escape||Je).source+"|"+f.source+"|"+(f===Le?Ve:Je).source+"|"+(t.evaluate||Je).source+"|$","g"),g="//# sourceURL="+(ht.call(t,"sourceURL")?(t.sourceURL+"").replace(/\s/g," "):"lodash.templateSources["+ ++Zt+"]")+"\n";e.replace(p,(function(t,n,r,i,a,l){return r||(r=i),d+=e.slice(h,l).replace(et,rr),n&&(o=!0,d+="' +\n__e("+n+") +\n'"),a&&(s=!0,d+="';\n"+a+";\n__p += '"),r&&(d+="' +\n((__t = ("+r+")) == null ? '' : __t) +\n'"),h=l+t.length,t})),d+="';\n";var m=ht.call(t,"variable")&&t.variable;if(m){if(ze.test(m))throw new Be(c)}else d="with (obj) {\n"+d+"\n}\n";d=(s?d.replace(Se,""):d).replace(_e,"$1").replace(ke,"$1;"),d="function("+(m||"obj")+") {\n"+(m?"":"obj || (obj = {});\n")+"var __t, __p = ''"+(o?", __e = _.escape":"")+(s?", __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\n":";\n")+d+"return __p\n}";var v=_f((function(){return je(l,g+"return "+d).apply(i,u)}));if(v.source=d,wu(v))throw v;return v}function df(e){return Ju(e).toLowerCase()}function pf(e){return Ju(e).toUpperCase()}function gf(e,t,n){if(e=Ju(e),e&&(n||t===i))return qn(e);if(!e||!(t=Io(t)))return e;var r=mr(e),o=mr(t),s=Qn(r,o),a=Jn(r,o)+1;return Go(r,s,a).join("")}function mf(e,t,n){if(e=Ju(e),e&&(n||t===i))return e.slice(0,vr(e)+1);if(!e||!(t=Io(t)))return e;var r=mr(e),o=Jn(r,mr(t))+1;return Go(r,0,o).join("")}function vf(e,t,n){if(e=Ju(e),e&&(n||t===i))return e.replace(Fe,"");if(!e||!(t=Io(t)))return e;var r=mr(e),o=Qn(r,mr(t));return Go(r,o).join("")}function yf(e,t){var n=R,r=T;if(ku(t)){var o="separator"in t?t.separator:o;n="length"in t?qu(t.length):n,r="omission"in t?Io(t.omission):r}e=Ju(e);var s=e.length;if(or(e)){var a=mr(e);s=a.length}if(n>=s)return e;var l=n-gr(r);if(l<1)return r;var c=a?Go(a,0,l).join(""):e.slice(0,l);if(o===i)return c+r;if(a&&(l+=c.length-l),Pu(o)){if(e.slice(l).search(o)){var u,h=c;o.global||(o=rt(o.source,Ju(Ge.exec(o))+"g")),o.lastIndex=0;while(u=o.exec(h))var f=u.index;c=c.slice(0,f===i?l:f)}}else if(e.indexOf(Io(o),l)!=l){var d=c.lastIndexOf(o);d>-1&&(c=c.slice(0,d))}return c+r}function wf(e){return e=Ju(e),e&&Ae.test(e)?e.replace(Ce,yr):e}var bf=ps((function(e,t,n){return e+(n?" ":"")+t.toUpperCase()})),xf=ds("toUpperCase");function Sf(e,t,n){return e=Ju(e),t=n?i:t,t===i?sr(e)?xr(e):In(e):e.match(t)||[]}var _f=xo((function(e,t){try{return wn(e,i,t)}catch(n){return wu(n)?n:new Be(n)}})),kf=Bs((function(e,t){return xn(t,(function(t){t=La(t),pi(e,t,Mc(e[t],e))})),e}));function Cf(e){var t=null==e?0:e.length,n=Us();return e=t?An(e,(function(e){if("function"!=typeof e[1])throw new ot(l);return[n(e[0]),e[1]]})):[],xo((function(n){var r=-1;while(++r<t){var i=e[r];if(wn(i[0],this,n))return wn(i[1],this,n)}}))}function $f(e){return yi(vi(e,d))}function Af(e){return function(){return e}}function Rf(e,t){return null==e||e!==e?t:e}var Tf=ys(),Ef=ys(!0);function Lf(e){return e}function Mf(e){return to("function"==typeof e?e:vi(e,d))}function Of(e){return so(vi(e,d))}function If(e,t){return ao(e,vi(t,d))}var Pf=xo((function(e,t){return function(n){return zi(n,e,t)}})),Df=xo((function(e,t){return function(n){return zi(e,n,t)}}));function Ff(e,t,n){var r=Sh(t),i=Oi(t,r);null!=n||ku(t)&&(i.length||!r.length)||(n=t,t=e,e=this,i=Oi(t,Sh(t)));var o=!(ku(n)&&"chain"in n)||!!n.chain,s=xu(e);return xn(i,(function(n){var r=t[n];e[n]=r,s&&(e.prototype[n]=function(){var t=this.__chain__;if(o||t){var n=e(this.__wrapped__),i=n.__actions__=is(this.__actions__);return i.push({func:r,args:arguments,thisArg:e}),n.__chain__=t,n}return r.apply(e,Rn([this.value()],arguments))})})),e}function Bf(){return an._===this&&(an._=mt),this}function Wf(){}function Nf(e){return e=qu(e),xo((function(t){return uo(t,e)}))}var Hf=Ss(An),jf=Ss(_n),zf=Ss(Ln);function Uf(e){return la(e)?Hn(La(e)):go(e)}function Vf(e){return function(t){return null==e?i:Ii(e,t)}}var Gf=Cs(),Kf=Cs(!0);function qf(){return[]}function Zf(){return!1}function Yf(){return{}}function Xf(){return""}function Qf(){return!0}function Jf(e,t){if(e=qu(e),e<1||e>D)return[];var n=W,r=Ht(e,W);t=Us(t),e-=W;var i=Gn(r,t);while(++n<e)t(n);return i}function ed(e){return lu(e)?An(e,La):Wu(e)?[e]:is(Ea(Ju(e)))}function td(e){var t=++ft;return Ju(e)+t}var nd=xs((function(e,t){return e+t}),0),rd=Rs("ceil"),id=xs((function(e,t){return e/t}),1),od=Rs("floor");function sd(e){return e&&e.length?Ci(e,Lf,Fi):i}function ad(e,t){return e&&e.length?Ci(e,Us(t,2),Fi):i}function ld(e){return Nn(e,Lf)}function cd(e,t){return Nn(e,Us(t,2))}function ud(e){return e&&e.length?Ci(e,Lf,io):i}function hd(e,t){return e&&e.length?Ci(e,Us(t,2),io):i}var fd=xs((function(e,t){return e*t}),1),dd=Rs("round"),pd=xs((function(e,t){return e-t}),0);function gd(e){return e&&e.length?Vn(e,Lf):0}function md(e,t){return e&&e.length?Vn(e,Us(t,2)):0}return Sr.after=Tc,Sr.ary=Ec,Sr.assign=eh,Sr.assignIn=th,Sr.assignInWith=nh,Sr.assignWith=rh,Sr.at=ih,Sr.before=Lc,Sr.bind=Mc,Sr.bindAll=kf,Sr.bindKey=Oc,Sr.castArray=Qc,Sr.chain=Vl,Sr.chunk=Pa,Sr.compact=Da,Sr.concat=Fa,Sr.cond=Cf,Sr.conforms=$f,Sr.constant=Af,Sr.countBy=nc,Sr.create=oh,Sr.curry=Ic,Sr.curryRight=Pc,Sr.debounce=Dc,Sr.defaults=sh,Sr.defaultsDeep=ah,Sr.defer=Fc,Sr.delay=Bc,Sr.difference=Ba,Sr.differenceBy=Wa,Sr.differenceWith=Na,Sr.drop=Ha,Sr.dropRight=ja,Sr.dropRightWhile=za,Sr.dropWhile=Ua,Sr.fill=Va,Sr.filter=ic,Sr.flatMap=ac,Sr.flatMapDeep=lc,Sr.flatMapDepth=cc,Sr.flatten=qa,Sr.flattenDeep=Za,Sr.flattenDepth=Ya,Sr.flip=Wc,Sr.flow=Tf,Sr.flowRight=Ef,Sr.fromPairs=Xa,Sr.functions=ph,Sr.functionsIn=gh,Sr.groupBy=fc,Sr.initial=el,Sr.intersection=tl,Sr.intersectionBy=nl,Sr.intersectionWith=rl,Sr.invert=wh,Sr.invertBy=bh,Sr.invokeMap=pc,Sr.iteratee=Mf,Sr.keyBy=gc,Sr.keys=Sh,Sr.keysIn=_h,Sr.map=mc,Sr.mapKeys=kh,Sr.mapValues=Ch,Sr.matches=Of,Sr.matchesProperty=If,Sr.memoize=Nc,Sr.merge=$h,Sr.mergeWith=Ah,Sr.method=Pf,Sr.methodOf=Df,Sr.mixin=Ff,Sr.negate=Hc,Sr.nthArg=Nf,Sr.omit=Rh,Sr.omitBy=Th,Sr.once=jc,Sr.orderBy=vc,Sr.over=Hf,Sr.overArgs=zc,Sr.overEvery=jf,Sr.overSome=zf,Sr.partial=Uc,Sr.partialRight=Vc,Sr.partition=yc,Sr.pick=Eh,Sr.pickBy=Lh,Sr.property=Uf,Sr.propertyOf=Vf,Sr.pull=ll,Sr.pullAll=cl,Sr.pullAllBy=ul,Sr.pullAllWith=hl,Sr.pullAt=fl,Sr.range=Gf,Sr.rangeRight=Kf,Sr.rearg=Gc,Sr.reject=xc,Sr.remove=dl,Sr.rest=Kc,Sr.reverse=pl,Sr.sampleSize=_c,Sr.set=Oh,Sr.setWith=Ih,Sr.shuffle=kc,Sr.slice=gl,Sr.sortBy=Ac,Sr.sortedUniq=Sl,Sr.sortedUniqBy=_l,Sr.split=cf,Sr.spread=qc,Sr.tail=kl,Sr.take=Cl,Sr.takeRight=$l,Sr.takeRightWhile=Al,Sr.takeWhile=Rl,Sr.tap=Gl,Sr.throttle=Zc,Sr.thru=Kl,Sr.toArray=Gu,Sr.toPairs=Ph,Sr.toPairsIn=Dh,Sr.toPath=ed,Sr.toPlainObject=Xu,Sr.transform=Fh,Sr.unary=Yc,Sr.union=Tl,Sr.unionBy=El,Sr.unionWith=Ll,Sr.uniq=Ml,Sr.uniqBy=Ol,Sr.uniqWith=Il,Sr.unset=Bh,Sr.unzip=Pl,Sr.unzipWith=Dl,Sr.update=Wh,Sr.updateWith=Nh,Sr.values=Hh,Sr.valuesIn=jh,Sr.without=Fl,Sr.words=Sf,Sr.wrap=Xc,Sr.xor=Bl,Sr.xorBy=Wl,Sr.xorWith=Nl,Sr.zip=Hl,Sr.zipObject=jl,Sr.zipObjectDeep=zl,Sr.zipWith=Ul,Sr.entries=Ph,Sr.entriesIn=Dh,Sr.extend=th,Sr.extendWith=nh,Ff(Sr,Sr),Sr.add=nd,Sr.attempt=_f,Sr.camelCase=Gh,Sr.capitalize=Kh,Sr.ceil=rd,Sr.clamp=zh,Sr.clone=Jc,Sr.cloneDeep=tu,Sr.cloneDeepWith=nu,Sr.cloneWith=eu,Sr.conformsTo=ru,Sr.deburr=qh,Sr.defaultTo=Rf,Sr.divide=id,Sr.endsWith=Zh,Sr.eq=iu,Sr.escape=Yh,Sr.escapeRegExp=Xh,Sr.every=rc,Sr.find=oc,Sr.findIndex=Ga,Sr.findKey=lh,Sr.findLast=sc,Sr.findLastIndex=Ka,Sr.findLastKey=ch,Sr.floor=od,Sr.forEach=uc,Sr.forEachRight=hc,Sr.forIn=uh,Sr.forInRight=hh,Sr.forOwn=fh,Sr.forOwnRight=dh,Sr.get=mh,Sr.gt=ou,Sr.gte=su,Sr.has=vh,Sr.hasIn=yh,Sr.head=Qa,Sr.identity=Lf,Sr.includes=dc,Sr.indexOf=Ja,Sr.inRange=Uh,Sr.invoke=xh,Sr.isArguments=au,Sr.isArray=lu,Sr.isArrayBuffer=cu,Sr.isArrayLike=uu,Sr.isArrayLikeObject=hu,Sr.isBoolean=fu,Sr.isBuffer=du,Sr.isDate=pu,Sr.isElement=gu,Sr.isEmpty=mu,Sr.isEqual=vu,Sr.isEqualWith=yu,Sr.isError=wu,Sr.isFinite=bu,Sr.isFunction=xu,Sr.isInteger=Su,Sr.isLength=_u,Sr.isMap=$u,Sr.isMatch=Au,Sr.isMatchWith=Ru,Sr.isNaN=Tu,Sr.isNative=Eu,Sr.isNil=Mu,Sr.isNull=Lu,Sr.isNumber=Ou,Sr.isObject=ku,Sr.isObjectLike=Cu,Sr.isPlainObject=Iu,Sr.isRegExp=Pu,Sr.isSafeInteger=Du,Sr.isSet=Fu,Sr.isString=Bu,Sr.isSymbol=Wu,Sr.isTypedArray=Nu,Sr.isUndefined=Hu,Sr.isWeakMap=ju,Sr.isWeakSet=zu,Sr.join=il,Sr.kebabCase=Qh,Sr.last=ol,Sr.lastIndexOf=sl,Sr.lowerCase=Jh,Sr.lowerFirst=ef,Sr.lt=Uu,Sr.lte=Vu,Sr.max=sd,Sr.maxBy=ad,Sr.mean=ld,Sr.meanBy=cd,Sr.min=ud,Sr.minBy=hd,Sr.stubArray=qf,Sr.stubFalse=Zf,Sr.stubObject=Yf,Sr.stubString=Xf,Sr.stubTrue=Qf,Sr.multiply=fd,Sr.nth=al,Sr.noConflict=Bf,Sr.noop=Wf,Sr.now=Rc,Sr.pad=tf,Sr.padEnd=nf,Sr.padStart=rf,Sr.parseInt=of,Sr.random=Vh,Sr.reduce=wc,Sr.reduceRight=bc,Sr.repeat=sf,Sr.replace=af,Sr.result=Mh,Sr.round=dd,Sr.runInContext=e,Sr.sample=Sc,Sr.size=Cc,Sr.snakeCase=lf,Sr.some=$c,Sr.sortedIndex=ml,Sr.sortedIndexBy=vl,Sr.sortedIndexOf=yl,Sr.sortedLastIndex=wl,Sr.sortedLastIndexBy=bl,Sr.sortedLastIndexOf=xl,Sr.startCase=uf,Sr.startsWith=hf,Sr.subtract=pd,Sr.sum=gd,Sr.sumBy=md,Sr.template=ff,Sr.times=Jf,Sr.toFinite=Ku,Sr.toInteger=qu,Sr.toLength=Zu,Sr.toLower=df,Sr.toNumber=Yu,Sr.toSafeInteger=Qu,Sr.toString=Ju,Sr.toUpper=pf,Sr.trim=gf,Sr.trimEnd=mf,Sr.trimStart=vf,Sr.truncate=yf,Sr.unescape=wf,Sr.uniqueId=td,Sr.upperCase=bf,Sr.upperFirst=xf,Sr.each=uc,Sr.eachRight=hc,Sr.first=Qa,Ff(Sr,function(){var e={};return Li(Sr,(function(t,n){ht.call(Sr.prototype,n)||(e[n]=t)})),e}(),{chain:!1}),Sr.VERSION=o,xn(["bind","bindKey","curry","curryRight","partial","partialRight"],(function(e){Sr[e].placeholder=Sr})),xn(["drop","take"],(function(e,t){Ar.prototype[e]=function(n){n=n===i?1:Nt(qu(n),0);var r=this.__filtered__&&!t?new Ar(this):this.clone();return r.__filtered__?r.__takeCount__=Ht(n,r.__takeCount__):r.__views__.push({size:Ht(n,W),type:e+(r.__dir__<0?"Right":"")}),r},Ar.prototype[e+"Right"]=function(t){return this.reverse()[e](t).reverse()}})),xn(["filter","map","takeWhile"],(function(e,t){var n=t+1,r=n==M||n==I;Ar.prototype[e]=function(e){var t=this.clone();return t.__iteratees__.push({iteratee:Us(e,3),type:n}),t.__filtered__=t.__filtered__||r,t}})),xn(["head","last"],(function(e,t){var n="take"+(t?"Right":"");Ar.prototype[e]=function(){return this[n](1).value()[0]}})),xn(["initial","tail"],(function(e,t){var n="drop"+(t?"":"Right");Ar.prototype[e]=function(){return this.__filtered__?new Ar(this):this[n](1)}})),Ar.prototype.compact=function(){return this.filter(Lf)},Ar.prototype.find=function(e){return this.filter(e).head()},Ar.prototype.findLast=function(e){return this.reverse().find(e)},Ar.prototype.invokeMap=xo((function(e,t){return"function"==typeof e?new Ar(this):this.map((function(n){return zi(n,e,t)}))})),Ar.prototype.reject=function(e){return this.filter(Hc(Us(e)))},Ar.prototype.slice=function(e,t){e=qu(e);var n=this;return n.__filtered__&&(e>0||t<0)?new Ar(n):(e<0?n=n.takeRight(-e):e&&(n=n.drop(e)),t!==i&&(t=qu(t),n=t<0?n.dropRight(-t):n.take(t-e)),n)},Ar.prototype.takeRightWhile=function(e){return this.reverse().takeWhile(e).reverse()},Ar.prototype.toArray=function(){return this.take(W)},Li(Ar.prototype,(function(e,t){var n=/^(?:filter|find|map|reject)|While$/.test(t),r=/^(?:head|last)$/.test(t),o=Sr[r?"take"+("last"==t?"Right":""):t],s=r||/^find/.test(t);o&&(Sr.prototype[t]=function(){var t=this.__wrapped__,a=r?[1]:arguments,l=t instanceof Ar,c=a[0],u=l||lu(t),h=function(e){var t=o.apply(Sr,Rn([e],a));return r&&f?t[0]:t};u&&n&&"function"==typeof c&&1!=c.length&&(l=u=!1);var f=this.__chain__,d=!!this.__actions__.length,p=s&&!f,g=l&&!d;if(!s&&u){t=g?t:new Ar(this);var m=e.apply(t,a);return m.__actions__.push({func:Kl,args:[h],thisArg:i}),new $r(m,f)}return p&&g?e.apply(this,a):(m=this.thru(h),p?r?m.value()[0]:m.value():m)})})),xn(["pop","push","shift","sort","splice","unshift"],(function(e){var t=st[e],n=/^(?:push|sort|unshift)$/.test(e)?"tap":"thru",r=/^(?:pop|shift)$/.test(e);Sr.prototype[e]=function(){var e=arguments;if(r&&!this.__chain__){var i=this.value();return t.apply(lu(i)?i:[],e)}return this[n]((function(n){return t.apply(lu(n)?n:[],e)}))}})),Li(Ar.prototype,(function(e,t){var n=Sr[t];if(n){var r=n.name+"";ht.call(cn,r)||(cn[r]=[]),cn[r].push({name:t,func:n})}})),cn[ws(i,w).name]=[{name:"wrapper",func:i}],Ar.prototype.clone=Rr,Ar.prototype.reverse=Tr,Ar.prototype.value=Er,Sr.prototype.at=ql,Sr.prototype.chain=Zl,Sr.prototype.commit=Yl,Sr.prototype.next=Xl,Sr.prototype.plant=Jl,Sr.prototype.reverse=ec,Sr.prototype.toJSON=Sr.prototype.valueOf=Sr.prototype.value=tc,Sr.prototype.first=Sr.prototype.head,At&&(Sr.prototype[At]=Ql),Sr},_r=Sr();an._=_r,r=function(){return _r}.call(t,n,t,e),r===i||(e.exports=r)}.call(this)},66188:function(e,t,n){var r=n(1054);function i(e){return null==e?"":r(e)}e.exports=i},23779:function(e,t,n){var r=n(83126),i=r("toUpperCase");e.exports=i},11618:function(e,t,n){var r=n(45981),i=n(83559),o=n(66188),s=n(75304);function a(e,t,n){return e=o(e),t=n?void 0:t,void 0===t?i(e)?s(e):r(e):e.match(t)||[]}e.exports=a},80131:function(e,t,n){var r;!function(){"use strict";var i={not_string:/[^s]/,not_bool:/[^t]/,not_type:/[^T]/,not_primitive:/[^v]/,number:/[diefg]/,numeric_arg:/[bcdiefguxX]/,json:/[j]/,not_json:/[^j]/,text:/^[^\x25]+/,modulo:/^\x25{2}/,placeholder:/^\x25(?:([1-9]\d*)\$|\(([^)]+)\))?(\+)?(0|'[^$])?(-)?(\d+)?(?:\.(\d+))?([b-gijostTuvxX])/,key:/^([a-z_][a-z_\d]*)/i,key_access:/^\.([a-z_][a-z_\d]*)/i,index_access:/^\[(\d+)\]/,sign:/^[+-]/};function o(e){return a(c(e),arguments)}function s(e,t){return o.apply(null,[e].concat(t||[]))}function a(e,t){var n,r,s,a,l,c,u,h,f,d=1,p=e.length,g="";for(r=0;r<p;r++)if("string"===typeof e[r])g+=e[r];else if("object"===typeof e[r]){if(a=e[r],a.keys)for(n=t[d],s=0;s<a.keys.length;s++){if(void 0==n)throw new Error(o('[sprintf] Cannot access property "%s" of undefined value "%s"',a.keys[s],a.keys[s-1]));n=n[a.keys[s]]}else n=a.param_no?t[a.param_no]:t[d++];if(i.not_type.test(a.type)&&i.not_primitive.test(a.type)&&n instanceof Function&&(n=n()),i.numeric_arg.test(a.type)&&"number"!==typeof n&&isNaN(n))throw new TypeError(o("[sprintf] expecting number but found %T",n));switch(i.number.test(a.type)&&(h=n>=0),a.type){case"b":n=parseInt(n,10).toString(2);break;case"c":n=String.fromCharCode(parseInt(n,10));break;case"d":case"i":n=parseInt(n,10);break;case"j":n=JSON.stringify(n,null,a.width?parseInt(a.width):0);break;case"e":n=a.precision?parseFloat(n).toExponential(a.precision):parseFloat(n).toExponential();break;case"f":n=a.precision?parseFloat(n).toFixed(a.precision):parseFloat(n);break;case"g":n=a.precision?String(Number(n.toPrecision(a.precision))):parseFloat(n);break;case"o":n=(parseInt(n,10)>>>0).toString(8);break;case"s":n=String(n),n=a.precision?n.substring(0,a.precision):n;break;case"t":n=String(!!n),n=a.precision?n.substring(0,a.precision):n;break;case"T":n=Object.prototype.toString.call(n).slice(8,-1).toLowerCase(),n=a.precision?n.substring(0,a.precision):n;break;case"u":n=parseInt(n,10)>>>0;break;case"v":n=n.valueOf(),n=a.precision?n.substring(0,a.precision):n;break;case"x":n=(parseInt(n,10)>>>0).toString(16);break;case"X":n=(parseInt(n,10)>>>0).toString(16).toUpperCase();break}i.json.test(a.type)?g+=n:(!i.number.test(a.type)||h&&!a.sign?f="":(f=h?"+":"-",n=n.toString().replace(i.sign,"")),c=a.pad_char?"0"===a.pad_char?"0":a.pad_char.charAt(1):" ",u=a.width-(f+n).length,l=a.width&&u>0?c.repeat(u):"",g+=a.align?f+n+l:"0"===c?f+l+n:l+f+n)}return g}var l=Object.create(null);function c(e){if(l[e])return l[e];var t,n=e,r=[],o=0;while(n){if(null!==(t=i.text.exec(n)))r.push(t[0]);else if(null!==(t=i.modulo.exec(n)))r.push("%");else{if(null===(t=i.placeholder.exec(n)))throw new SyntaxError("[sprintf] unexpected placeholder");if(t[2]){o|=1;var s=[],a=t[2],c=[];if(null===(c=i.key.exec(a)))throw new SyntaxError("[sprintf] failed to parse named argument key");s.push(c[1]);while(""!==(a=a.substring(c[0].length)))if(null!==(c=i.key_access.exec(a)))s.push(c[1]);else{if(null===(c=i.index_access.exec(a)))throw new SyntaxError("[sprintf] failed to parse named argument key");s.push(c[1])}t[2]=s}else o|=2;if(3===o)throw new Error("[sprintf] mixing positional and named placeholders is not (yet) supported");r.push({placeholder:t[0],param_no:t[1],keys:t[2],sign:t[3],pad_char:t[4],align:t[5],width:t[6],precision:t[7],type:t[8]})}n=n.substring(t[0].length)}return l[e]=r}o,s,"undefined"!==typeof window&&(window["sprintf"]=o,window["vsprintf"]=s,r=function(){return{sprintf:o,vsprintf:s}}.call(t,n,t,e),void 0===r||(e.exports=r))}()},3276:function(e,t,n){"use strict";n.d(t,{Z:function(){return ni}});const r=!0,i="u-",o="uplot",s=i+"hz",a=i+"vt",l=i+"title",c=i+"wrap",u=i+"under",h=i+"over",f=i+"axis",d=i+"off",p=i+"select",g=i+"cursor-x",m=i+"cursor-y",v=i+"cursor-pt",y=i+"legend",w=i+"live",b=i+"inline",x=i+"thead",S=i+"series",_=i+"marker",k=i+"label",C=i+"value",$="width",A="height",R="top",T="bottom",E="left",L="right",M="#000",O=M+"0",I="mousemove",P="mousedown",D="mouseup",F="mouseenter",B="mouseleave",W="dblclick",N="resize",H="scroll",j="change",z="dppxchange",U="--",V="undefined"!=typeof window,G=V?document:null,K=V?window:null,q=V?navigator:null;let Z,Y;function X(){let e=devicePixelRatio;Z!=e&&(Z=e,Y&&fe(j,Y,X),Y=matchMedia(`(min-resolution: ${Z-.001}dppx) and (max-resolution: ${Z+.001}dppx)`),he(j,Y,X),K.dispatchEvent(new CustomEvent(z)))}function Q(e,t){if(null!=t){let n=e.classList;!n.contains(t)&&n.add(t)}}function J(e,t){let n=e.classList;n.contains(t)&&n.remove(t)}function ee(e,t,n){e.style[t]=n+"px"}function te(e,t,n,r){let i=G.createElement(e);return null!=t&&Q(i,t),null!=n&&n.insertBefore(i,r),i}function ne(e,t){return te("div",e,t)}const re=new WeakMap;function ie(e,t,n,r,i){let o="translate("+t+"px,"+n+"px)",s=re.get(e);o!=s&&(e.style.transform=o,re.set(e,o),t<0||n<0||t>r||n>i?Q(e,d):J(e,d))}const oe=new WeakMap;function se(e,t,n){let r=t+n,i=oe.get(e);r!=i&&(oe.set(e,r),e.style.background=t,e.style.borderColor=n)}const ae=new WeakMap;function le(e,t,n,r){let i=t+""+n,o=ae.get(e);i!=o&&(ae.set(e,i),e.style.height=n+"px",e.style.width=t+"px",e.style.marginLeft=r?-t/2+"px":0,e.style.marginTop=r?-n/2+"px":0)}const ce={passive:!0},ue={...ce,capture:!0};function he(e,t,n,r){t.addEventListener(e,n,r?ue:ce)}function fe(e,t,n,r){t.removeEventListener(e,n,r?ue:ce)}function de(e,t,n,r){let i;n=n||0,r=r||t.length-1;let o=r<=2147483647;while(r-n>1)i=o?n+r>>1:Me((n+r)/2),t[i]<e?n=i:r=i;return e-t[n]<=t[r]-e?n:r}function pe(e,t,n,r){for(let i=1==r?t:n;i>=t&&i<=n;i+=r)if(null!=e[i])return i;return-1}function ge(e,t,n,r){let i=ze,o=-ze;if(1==r)i=e[t],o=e[n];else if(-1==r)i=e[n],o=e[t];else for(let s=t;s<=n;s++)null!=e[s]&&(i=Pe(i,e[s]),o=De(o,e[s]));return[i,o]}function me(e,t,n){let r=ze,i=-ze;for(let o=t;o<=n;o++)e[o]>0&&(r=Pe(r,e[o]),i=De(i,e[o]));return[r==ze?1:r,i==-ze?10:i]}function ve(e,t,n,r){let i=Be(e),o=Be(t),s=10==n?We:Ne;e==t&&(-1==i?(e*=n,t/=n):(e/=n,t*=n));let a=1==i?Me:Ie,l=1==o?Ie:Me,c=a(s(Le(e))),u=l(s(Le(t))),h=Fe(n,c),f=Fe(n,u);return 10==n&&(c<0&&(h=rt(h,-c)),u<0&&(f=rt(f,-u))),r||2==n?(e=h*i,t=f*o):(e=nt(e,h),t=tt(t,f)),[e,t]}function ye(e,t,n,r){let i=ve(e,t,n,r);return 0==e&&(i[0]=0),0==t&&(i[1]=0),i}V&&X();const we=.1,be={mode:3,pad:we},xe={pad:0,soft:null,mode:0},Se={min:xe,max:xe};function _e(e,t,n,r){return pt(n)?$e(e,t,n):(xe.pad=n,xe.soft=r?0:null,xe.mode=r?3:0,$e(e,t,Se))}function ke(e,t){return null==e?t:e}function Ce(e,t,n){t=ke(t,0),n=ke(n,e.length-1);while(t<=n){if(null!=e[t])return!0;t++}return!1}function $e(e,t,n){let r=n.min,i=n.max,o=ke(r.pad,0),s=ke(i.pad,0),a=ke(r.hard,-ze),l=ke(i.hard,ze),c=ke(r.soft,ze),u=ke(i.soft,-ze),h=ke(r.mode,0),f=ke(i.mode,0),d=t-e,p=We(d),g=De(Le(e),Le(t)),m=We(g),v=Le(m-p);(d<1e-9||v>10)&&(d=0,0!=e&&0!=t||(d=1e-9,2==h&&c!=ze&&(o=0),2==f&&u!=-ze&&(s=0)));let y=d||g||1e3,w=We(y),b=Fe(10,Me(w)),x=y*(0==d?0==e?.1:1:o),S=rt(nt(e-x,b/10),9),_=e>=c&&(1==h||3==h&&S<=c||2==h&&S>=c)?c:ze,k=De(a,S<_&&e>=_?_:Pe(_,S)),C=y*(0==d?0==t?.1:1:s),$=rt(tt(t+C,b/10),9),A=t<=u&&(1==f||3==f&&$>=u||2==f&&$<=u)?u:-ze,R=Pe(l,$>A&&t<=A?A:De(A,$));return k==R&&0==k&&(R=100),[k,R]}const Ae=new Intl.NumberFormat(V?q.language:"en-US"),Re=e=>Ae.format(e),Te=Math,Ee=Te.PI,Le=Te.abs,Me=Te.floor,Oe=Te.round,Ie=Te.ceil,Pe=Te.min,De=Te.max,Fe=Te.pow,Be=Te.sign,We=Te.log10,Ne=Te.log2,He=(e,t=1)=>Te.sinh(e)*t,je=(e,t=1)=>Te.asinh(e/t),ze=1/0;function Ue(e){return 1+(0|We((e^e>>31)-(e>>31)))}function Ve(e,t,n){return Pe(De(e,t),n)}function Ge(e){return"function"==typeof e?e:()=>e}const Ke=()=>{},qe=e=>e,Ze=(e,t)=>t,Ye=e=>null,Xe=e=>!0,Qe=(e,t)=>e==t,Je=e=>rt(e,14);function et(e,t){return Je(rt(Je(e/t))*t)}function tt(e,t){return Je(Ie(Je(e/t))*t)}function nt(e,t){return Je(Me(Je(e/t))*t)}function rt(e,t=0){if(ht(e))return e;let n=10**t,r=e*n*(1+Number.EPSILON);return Oe(r)/n}const it=new Map;function ot(e){return((""+e).split(".")[1]||"").length}function st(e,t,n,r){let i=[],o=r.map(ot);for(let s=t;s<n;s++){let t=Le(s),n=rt(Fe(e,s),t);for(let e=0;e<r.length;e++){let a=r[e]*n,l=(a>=0&&s>=0?0:t)+(s>=o[e]?0:o[e]),c=rt(a,l);i.push(c),it.set(c,l)}}return i}const at={},lt=[],ct=[null,null],ut=Array.isArray,ht=Number.isInteger,ft=e=>void 0===e;function dt(e){return"string"==typeof e}function pt(e){let t=!1;if(null!=e){let n=e.constructor;t=null==n||n==Object}return t}function gt(e){return null!=e&&"object"==typeof e}const mt=Object.getPrototypeOf(Uint8Array);function vt(e,t=pt){let n;if(ut(e)){let r=e.find((e=>null!=e));if(ut(r)||t(r)){n=Array(e.length);for(let r=0;r<e.length;r++)n[r]=vt(e[r],t)}else n=e.slice()}else if(e instanceof mt)n=e.slice();else if(t(e)){n={};for(let r in e)n[r]=vt(e[r],t)}else n=e;return n}function yt(e){let t=arguments;for(let n=1;n<t.length;n++){let r=t[n];for(let t in r)pt(e[t])?yt(e[t],vt(r[t])):e[t]=vt(r[t])}return e}const wt=0,bt=1,xt=2;function St(e,t,n){for(let r,i=0,o=-1;i<t.length;i++){let s=t[i];if(s>o){r=s-1;while(r>=0&&null==e[r])e[r--]=null;r=s+1;while(r<n&&null==e[r])e[o=r++]=null}}}function _t(e,t){let n=new Set;for(let s=0;s<e.length;s++){let t=e[s],r=t[0],i=r.length;for(let e=0;e<i;e++)n.add(r[e])}let r=[Array.from(n).sort(((e,t)=>e-t))],i=r[0].length,o=new Map;for(let s=0;s<i;s++)o.set(r[0][s],s);for(let s=0;s<e.length;s++){let n=e[s],a=n[0];for(let e=1;e<n.length;e++){let l=n[e],c=Array(i).fill(void 0),u=t?t[s][e]:bt,h=[];for(let e=0;e<l.length;e++){let t=l[e],n=o.get(a[e]);null===t?u!=wt&&(c[n]=t,u==xt&&h.push(n)):c[n]=t}St(c,h,i),r.push(c)}}return r}const kt="undefined"==typeof queueMicrotask?e=>Promise.resolve().then(e):queueMicrotask,Ct=["January","February","March","April","May","June","July","August","September","October","November","December"],$t=["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"];function At(e){return e.slice(0,3)}const Rt=$t.map(At),Tt=Ct.map(At),Et={MMMM:Ct,MMM:Tt,WWWW:$t,WWW:Rt};function Lt(e){return(e<10?"0":"")+e}function Mt(e){return(e<10?"00":e<100?"0":"")+e}const Ot={YYYY:e=>e.getFullYear(),YY:e=>(e.getFullYear()+"").slice(2),MMMM:(e,t)=>t.MMMM[e.getMonth()],MMM:(e,t)=>t.MMM[e.getMonth()],MM:e=>Lt(e.getMonth()+1),M:e=>e.getMonth()+1,DD:e=>Lt(e.getDate()),D:e=>e.getDate(),WWWW:(e,t)=>t.WWWW[e.getDay()],WWW:(e,t)=>t.WWW[e.getDay()],HH:e=>Lt(e.getHours()),H:e=>e.getHours(),h:e=>{let t=e.getHours();return 0==t?12:t>12?t-12:t},AA:e=>e.getHours()>=12?"PM":"AM",aa:e=>e.getHours()>=12?"pm":"am",a:e=>e.getHours()>=12?"p":"a",mm:e=>Lt(e.getMinutes()),m:e=>e.getMinutes(),ss:e=>Lt(e.getSeconds()),s:e=>e.getSeconds(),fff:e=>Mt(e.getMilliseconds())};function It(e,t){t=t||Et;let n,r=[],i=/\{([a-z]+)\}|[^{]+/gi;while(n=i.exec(e))r.push("{"==n[0][0]?Ot[n[1]]:n[0]);return e=>{let n="";for(let i=0;i<r.length;i++)n+="string"==typeof r[i]?r[i]:r[i](e,t);return n}}const Pt=(new Intl.DateTimeFormat).resolvedOptions().timeZone;function Dt(e,t){let n;return"UTC"==t||"Etc/UTC"==t?n=new Date(+e+6e4*e.getTimezoneOffset()):t==Pt?n=e:(n=new Date(e.toLocaleString("en-US",{timeZone:t})),n.setMilliseconds(e.getMilliseconds())),n}const Ft=e=>e%1==0,Bt=[1,2,2.5,5],Wt=st(10,-16,0,Bt),Nt=st(10,0,16,Bt),Ht=Nt.filter(Ft),jt=Wt.concat(Nt),zt="\n",Ut="{YYYY}",Vt=zt+Ut,Gt="{M}/{D}",Kt=zt+Gt,qt=Kt+"/{YY}",Zt="{aa}",Yt="{h}:{mm}",Xt=Yt+Zt,Qt=zt+Xt,Jt=":{ss}",en=null;function tn(e){let t=1e3*e,n=60*t,r=60*n,i=24*r,o=30*i,s=365*i,a=1==e?st(10,0,3,Bt).filter(Ft):st(10,-3,0,Bt),l=a.concat([t,5*t,10*t,15*t,30*t,n,5*n,10*n,15*n,30*n,r,2*r,3*r,4*r,6*r,8*r,12*r,i,2*i,3*i,4*i,5*i,6*i,7*i,8*i,9*i,10*i,15*i,o,2*o,3*o,4*o,6*o,s,2*s,5*s,10*s,25*s,50*s,100*s]);const c=[[s,Ut,en,en,en,en,en,en,1],[28*i,"{MMM}",Vt,en,en,en,en,en,1],[i,Gt,Vt,en,en,en,en,en,1],[r,"{h}"+Zt,qt,en,Kt,en,en,en,1],[n,Xt,qt,en,Kt,en,en,en,1],[t,Jt,qt+" "+Xt,en,Kt+" "+Xt,en,Qt,en,1],[e,Jt+".{fff}",qt+" "+Xt,en,Kt+" "+Xt,en,Qt,en,1]];function u(t){return(a,l,c,u,h,f)=>{let d=[],p=h>=s,g=h>=o&&h<s,m=t(c),v=rt(m*e,3),y=fn(m.getFullYear(),p?0:m.getMonth(),g||p?1:m.getDate()),w=rt(y*e,3);if(g||p){let n=g?h/o:0,r=p?h/s:0,i=v==w?v:rt(fn(y.getFullYear()+r,y.getMonth()+n,1)*e,3),a=new Date(Oe(i/e)),l=a.getFullYear(),c=a.getMonth();for(let o=0;i<=u;o++){let s=fn(l+r*o,c+n*o,1),a=s-t(rt(s*e,3));i=rt((+s+a)*e,3),i<=u&&d.push(i)}}else{let o=h>=i?i:h,s=Me(c)-Me(v),p=w+s+tt(v-w,o);d.push(p);let g=t(p),m=g.getHours()+g.getMinutes()/n+g.getSeconds()/r,y=h/r,b=a.axes[l]._space,x=f/b;while(1){if(p=rt(p+h,1==e?0:3),p>u)break;if(y>1){let e=Me(rt(m+y,6))%24,n=t(p),i=n.getHours(),o=i-e;o>1&&(o=-1),p-=o*r,m=(m+y)%24;let s=d[d.length-1],a=rt((p-s)/h,3);a*x>=.7&&d.push(p)}else d.push(p)}}return d}}return[l,c,u]}const[nn,rn,on]=tn(1),[sn,an,ln]=tn(.001);function cn(e,t){return e.map((e=>e.map(((n,r)=>0==r||8==r||null==n?n:t(1==r||0==e[8]?n:e[1]+n)))))}function un(e,t){return(n,r,i,o,s)=>{let a,l,c,u,h,f,d=t.find((e=>s>=e[0]))||t[t.length-1];return r.map((t=>{let n=e(t),r=n.getFullYear(),i=n.getMonth(),o=n.getDate(),s=n.getHours(),p=n.getMinutes(),g=n.getSeconds(),m=r!=a&&d[2]||i!=l&&d[3]||o!=c&&d[4]||s!=u&&d[5]||p!=h&&d[6]||g!=f&&d[7]||d[1];return a=r,l=i,c=o,u=s,h=p,f=g,m(n)}))}}function hn(e,t){let n=It(t);return(t,r,i,o,s)=>r.map((t=>n(e(t))))}function fn(e,t,n){return new Date(e,t,n)}function dn(e,t){return t(e)}st(2,-53,53,[1]);const pn="{YYYY}-{MM}-{DD} {h}:{mm}{aa}";function gn(e,t){return(n,r,i,o)=>null==o?U:t(e(r))}function mn(e,t){let n=e.series[t];return n.width?n.stroke(e,t):n.points.width?n.points.stroke(e,t):null}function vn(e,t){return e.series[t].fill(e,t)}const yn={show:!0,live:!0,isolate:!1,mount:Ke,markers:{show:!0,width:2,stroke:mn,fill:vn,dash:"solid"},idx:null,idxs:null,values:[]};function wn(e,t){let n=e.cursor.points,r=ne(),i=n.size(e,t);ee(r,$,i),ee(r,A,i);let o=i/-2;ee(r,"marginLeft",o),ee(r,"marginTop",o);let s=n.width(e,t,i);return s&&ee(r,"borderWidth",s),r}function bn(e,t){let n=e.series[t].points;return n._fill||n._stroke}function xn(e,t){let n=e.series[t].points;return n._stroke||n._fill}function Sn(e,t){let n=e.series[t].points;return n.size}function _n(e,t,n){return n}const kn=[0,0];function Cn(e,t,n){return kn[0]=t,kn[1]=n,kn}function $n(e,t,n){return e=>{0==e.button&&n(e)}}function An(e,t,n){return n}const Rn={show:!0,x:!0,y:!0,lock:!1,move:Cn,points:{show:wn,size:Sn,width:0,stroke:xn,fill:bn},bind:{mousedown:$n,mouseup:$n,click:$n,dblclick:$n,mousemove:An,mouseleave:An,mouseenter:An},drag:{setScale:!0,x:!0,y:!1,dist:0,uni:null,click:(e,t)=>{t.stopPropagation(),t.stopImmediatePropagation()},_x:!1,_y:!1},focus:{prox:-1,bias:0},left:-10,top:-10,idx:null,dataIdx:_n,idxs:null},Tn={show:!0,stroke:"rgba(0,0,0,0.07)",width:2},En=yt({},Tn,{filter:Ze}),Ln=yt({},En,{size:10}),Mn=yt({},Tn,{show:!1}),On='12px system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji"',In="bold "+On,Pn=1.5,Dn={show:!0,scale:"x",stroke:M,space:50,gap:5,size:50,labelGap:0,labelSize:30,labelFont:In,side:2,grid:En,ticks:Ln,border:Mn,font:On,rotate:0},Fn="Value",Bn="Time",Wn={show:!0,scale:"x",auto:!1,sorted:1,min:ze,max:-ze,idxs:[]};function Nn(e,t,n,r,i){return t.map((e=>null==e?"":Re(e)))}function Hn(e,t,n,r,i,o,s){let a=[],l=it.get(i)||0;n=s?n:rt(tt(n,i),l);for(let c=n;c<=r;c=rt(c+i,l))a.push(Object.is(c,-0)?0:c);return a}function jn(e,t,n,r,i,o,s){const a=[],l=e.scales[e.axes[t].scale].log,c=10==l?We:Ne,u=Me(c(n));i=Fe(l,u),10==l&&u<0&&(i=rt(i,-u));let h=n;do{a.push(h),h+=i,10==l&&(h=rt(h,it.get(i))),h>=i*l&&(i=h)}while(h<=r);return a}function zn(e,t,n,r,i,o,s){let a=e.scales[e.axes[t].scale],l=a.asinh,c=r>l?jn(e,t,De(l,n),r,i):[l],u=r>=0&&n<=0?[0]:[],h=n<-l?jn(e,t,De(l,-r),-n,i):[l];return h.reverse().map((e=>-e)).concat(u,c)}const Un=/./,Vn=/[12357]/,Gn=/[125]/,Kn=/1/;function qn(e,t,n,r,i){let o=e.axes[n],s=o.scale,a=e.scales[s];if(3==a.distr&&2==a.log)return t;let l=e.valToPos,c=o._space,u=l(10,s),h=l(9,s)-u>=c?Un:l(7,s)-u>=c?Vn:l(5,s)-u>=c?Gn:Kn;return t.map((e=>4==a.distr&&0==e||h.test(e)?e:null))}function Zn(e,t,n,r){return null==r?U:null==t?"":Re(t)}const Yn={show:!0,scale:"y",stroke:M,space:30,gap:5,size:50,labelGap:0,labelSize:30,labelFont:In,side:3,grid:En,ticks:Ln,border:Mn,font:On,rotate:0};function Xn(e,t){let n=3+2*(e||1);return rt(n*t,3)}function Qn(e,t){let{scale:n,idxs:r}=e.series[0],i=e._data[0],o=e.valToPos(i[r[0]],n,!0),s=e.valToPos(i[r[1]],n,!0),a=Le(s-o),l=e.series[t],c=a/(l.points.space*Z);return r[1]-r[0]<=c}const Jn={scale:null,auto:!0,sorted:0,min:ze,max:-ze},er=(e,t,n,r,i)=>i,tr={show:!0,auto:!0,sorted:0,gaps:er,alpha:1,facets:[yt({},Jn,{scale:"x"}),yt({},Jn,{scale:"y"})]},nr={scale:"y",auto:!0,sorted:0,show:!0,spanGaps:!1,gaps:er,alpha:1,points:{show:Qn,filter:null},values:null,min:ze,max:-ze,idxs:[],path:null,clip:null};function rr(e,t,n,r,i){return n/10}const ir={time:r,auto:!0,distr:1,log:10,asinh:1,min:null,max:null,dir:1,ori:0},or=yt({},ir,{time:!1,ori:1}),sr={};function ar(e,t){let n=sr[e];return n||(n={key:e,plots:[],sub(e){n.plots.push(e)},unsub(e){n.plots=n.plots.filter((t=>t!=e))},pub(e,t,r,i,o,s,a){for(let l=0;l<n.plots.length;l++)n.plots[l]!=t&&n.plots[l].pub(e,t,r,i,o,s,a)}},null!=e&&(sr[e]=n)),n}const lr=1,cr=2;function ur(e,t,n){const r=e.mode,i=e.series[t],o=2==r?e._data[t]:e._data,s=e.scales,a=e.bbox;let l=o[0],c=2==r?o[1]:o[t],u=2==r?s[i.facets[0].scale]:s[e.series[0].scale],h=2==r?s[i.facets[1].scale]:s[i.scale],f=a.left,d=a.top,p=a.width,g=a.height,m=e.valToPosH,v=e.valToPosV;return 0==u.ori?n(i,l,c,u,h,m,v,f,d,p,g,wr,xr,_r,Cr,Ar):n(i,l,c,u,h,v,m,d,f,g,p,br,Sr,kr,$r,Rr)}function hr(e,t){let n=0,r=0,i=ke(e.bands,lt);for(let o=0;o<i.length;o++){let e=i[o];e.series[0]==t?n=e.dir:e.series[1]==t&&(1==e.dir?r|=1:r|=2)}return[n,1==r?-1:2==r?1:3==r?2:0]}function fr(e,t,n,r,i){let o=e.mode,s=e.series[t],a=2==o?s.facets[1].scale:s.scale,l=e.scales[a];return-1==i?l.min:1==i?l.max:3==l.distr?1==l.dir?l.min:l.max:0}function dr(e,t,n,r,i,o){return ur(e,t,((e,t,s,a,l,c,u,h,f,d,p)=>{let g=e.pxRound;const m=a.dir*(0==a.ori?1:-1),v=0==a.ori?xr:Sr;let y,w;1==m?(y=n,w=r):(y=r,w=n);let b=g(c(t[y],a,d,h)),x=g(u(s[y],l,p,f)),S=g(c(t[w],a,d,h)),_=g(u(1==o?l.max:l.min,l,p,f)),k=new Path2D(i);return v(k,S,_),v(k,b,_),v(k,b,x),k}))}function pr(e,t,n,r,i,o){let s=null;if(e.length>0){s=new Path2D;const a=0==t?_r:kr;let l=n;for(let t=0;t<e.length;t++){let n=e[t];if(n[1]>n[0]){let e=n[0]-l;e>0&&a(s,l,r,e,r+o),l=n[1]}}let c=n+i-l;c>0&&a(s,l,r,c,r+o)}return s}function gr(e,t,n){let r=e[e.length-1];r&&r[0]==t?r[1]=n:e.push([t,n])}function mr(e,t,n,r,i,o,s){let a=[],l=e.length;for(let c=1==i?n:r;c>=n&&c<=r;c+=i){let u=t[c];if(null===u){let u=c,h=c;if(1==i)while(++c<=r&&null===t[c])h=c;else while(--c>=n&&null===t[c])h=c;let f=o(e[u]),d=h==u?f:o(e[h]),p=u-i,g=s<=0&&p>=0&&p<l?o(e[p]):f;f=g;let m=h+i,v=s>=0&&m>=0&&m<l?o(e[m]):d;d=v,d>=f&&a.push([f,d])}}return a}function vr(e){return 0==e?qe:1==e?Oe:t=>et(t,e)}function yr(e){let t=0==e?wr:br,n=0==e?(e,t,n,r,i,o)=>{e.arcTo(t,n,r,i,o)}:(e,t,n,r,i,o)=>{e.arcTo(n,t,i,r,o)},r=0==e?(e,t,n,r,i)=>{e.rect(t,n,r,i)}:(e,t,n,r,i)=>{e.rect(n,t,i,r)};return(e,i,o,s,a,l=0,c=0)=>{0==l&&0==c?r(e,i,o,s,a):(l=Pe(l,s/2,a/2),c=Pe(c,s/2,a/2),t(e,i+l,o),n(e,i+s,o,i+s,o+a,l),n(e,i+s,o+a,i,o+a,c),n(e,i,o+a,i,o,c),n(e,i,o,i+s,o,l),e.closePath())}}const wr=(e,t,n)=>{e.moveTo(t,n)},br=(e,t,n)=>{e.moveTo(n,t)},xr=(e,t,n)=>{e.lineTo(t,n)},Sr=(e,t,n)=>{e.lineTo(n,t)},_r=yr(0),kr=yr(1),Cr=(e,t,n,r,i,o)=>{e.arc(t,n,r,i,o)},$r=(e,t,n,r,i,o)=>{e.arc(n,t,r,i,o)},Ar=(e,t,n,r,i,o,s)=>{e.bezierCurveTo(t,n,r,i,o,s)},Rr=(e,t,n,r,i,o,s)=>{e.bezierCurveTo(n,t,i,r,s,o)};function Tr(e){return(e,t,n,r,i)=>ur(e,t,((t,o,s,a,l,c,u,h,f,d,p)=>{let g,m,{pxRound:v,points:y}=t;0==a.ori?(g=wr,m=Cr):(g=br,m=$r);const w=rt(y.width*Z,3);let b=(y.size-y.width)/2*Z,x=rt(2*b,3),S=new Path2D,_=new Path2D,{left:k,top:C,width:$,height:A}=e.bbox;_r(_,k-x,C-x,$+2*x,A+2*x);const R=e=>{if(null!=s[e]){let t=v(c(o[e],a,d,h)),n=v(u(s[e],l,p,f));g(S,t+b,n),m(S,t,n,b,0,2*Ee)}};if(i)i.forEach(R);else for(let e=n;e<=r;e++)R(e);return{stroke:w>0?S:null,fill:S,clip:_,flags:lr|cr}}))}function Er(e){return(t,n,r,i,o,s)=>{r!=i&&(o!=r&&s!=r&&e(t,n,r),o!=i&&s!=i&&e(t,n,i),e(t,n,s))}}const Lr=Er(xr),Mr=Er(Sr);function Or(e){const t=ke(e?.alignGaps,0);return(e,n,r,i)=>ur(e,n,((o,s,a,l,c,u,h,f,d,p,g)=>{let m,v,y=o.pxRound,w=e=>y(u(e,l,p,f)),b=e=>y(h(e,c,g,d));0==l.ori?(m=xr,v=Lr):(m=Sr,v=Mr);const x=l.dir*(0==l.ori?1:-1),S={stroke:new Path2D,fill:null,clip:null,band:null,gaps:null,flags:lr},_=S.stroke;let k,C,$,A=ze,R=-ze,T=w(s[1==x?r:i]),E=pe(a,r,i,1*x),L=pe(a,r,i,-1*x),M=w(s[E]),O=w(s[L]),I=!1;for(let e=1==x?r:i;e>=r&&e<=i;e+=x){let t=w(s[e]),n=a[e];t==T?null!=n?(C=b(n),A==ze&&(m(_,t,C),k=C),A=Pe(C,A),R=De(C,R)):null===n&&(I=!0):(A!=ze&&(v(_,T,A,R,k,C),$=T),null!=n?(C=b(n),m(_,t,C),A=R=k=C):(A=ze,R=-ze,null===n&&(I=!0)),T=t)}A!=ze&&A!=R&&$!=T&&v(_,T,A,R,k,C);let[P,D]=hr(e,n);if(null!=o.fill||0!=P){let t=S.fill=new Path2D(_),r=o.fillTo(e,n,o.min,o.max,P),i=b(r);m(t,O,i),m(t,M,i)}if(!o.spanGaps){let c=[];I&&c.push(...mr(s,a,r,i,x,w,t)),S.gaps=c=o.gaps(e,n,r,i,c),S.clip=pr(c,l.ori,f,d,p,g)}return 0!=D&&(S.band=2==D?[dr(e,n,r,i,_,-1),dr(e,n,r,i,_,1)]:dr(e,n,r,i,_,D)),S}))}function Ir(e){const t=ke(e.align,1),n=ke(e.ascDesc,!1),r=ke(e.alignGaps,0),i=ke(e.extend,!1);return(e,o,s,a)=>ur(e,o,((l,c,u,h,f,d,p,g,m,v,y)=>{let w=l.pxRound,{left:b,width:x}=e.bbox,S=e=>w(d(e,h,v,g)),_=e=>w(p(e,f,y,m)),k=0==h.ori?xr:Sr;const C={stroke:new Path2D,fill:null,clip:null,band:null,gaps:null,flags:lr},$=C.stroke,A=h.dir*(0==h.ori?1:-1);s=pe(u,s,a,1),a=pe(u,s,a,-1);let R=_(u[1==A?s:a]),T=S(c[1==A?s:a]),E=T,L=T;i&&-1==t&&(L=b,k($,L,R)),k($,T,R);for(let e=1==A?s:a;e>=s&&e<=a;e+=A){let n=u[e];if(null==n)continue;let r=S(c[e]),i=_(n);1==t?k($,r,R):k($,E,i),k($,r,i),R=i,E=r}let M=E;i&&1==t&&(M=b+x,k($,M,R));let[O,I]=hr(e,o);if(null!=l.fill||0!=O){let t=C.fill=new Path2D($),n=l.fillTo(e,o,l.min,l.max,O),r=_(n);k(t,M,r),k(t,L,r)}if(!l.spanGaps){let i=[];i.push(...mr(c,u,s,a,A,S,r));let f=l.width*Z/2,d=n||1==t?f:-f,p=n||-1==t?-f:f;i.forEach((e=>{e[0]+=d,e[1]+=p})),C.gaps=i=l.gaps(e,o,s,a,i),C.clip=pr(i,h.ori,g,m,v,y)}return 0!=I&&(C.band=2==I?[dr(e,o,s,a,$,-1),dr(e,o,s,a,$,1)]:dr(e,o,s,a,$,I)),C}))}function Pr(e){e=e||at;const t=ke(e.size,[.6,ze,1]),n=e.align||0,r=(e.gap||0)*Z;let i=e.radius;i=null==i?[0,0]:"number"==typeof i?[i,0]:i;const o=Ge(i),s=1-t[0],a=ke(t[1],ze)*Z,l=ke(t[2],1)*Z,c=ke(e.disp,at),u=ke(e.each,(e=>{})),{fill:h,stroke:f}=c;return(e,t,i,d)=>ur(e,t,((p,g,m,v,y,w,b,x,S,_,k)=>{let C,$,A=p.pxRound;0==v.ori?[C,$]=o(e,t):[$,C]=o(e,t);const R=v.dir*(0==v.ori?1:-1),T=y.dir*(1==y.ori?1:-1);let E,L,M=0==v.ori?_r:kr,O=0==v.ori?u:(e,t,n,r,i,o,s)=>{u(e,t,n,i,r,s,o)},[I,P]=hr(e,t),D=3==y.distr?1==I?y.max:y.min:0,F=b(D,y,k,S),B=A(p.width*Z),W=!1,N=null,H=null,j=null,z=null;null==h||0!=B&&null==f||(W=!0,N=h.values(e,t,i,d),H=new Map,new Set(N).forEach((e=>{null!=e&&H.set(e,new Path2D)})),B>0&&(j=f.values(e,t,i,d),z=new Map,new Set(j).forEach((e=>{null!=e&&z.set(e,new Path2D)}))));let{x0:U,size:V}=c;if(null!=U&&null!=V){g=U.values(e,t,i,d),2==U.unit&&(g=g.map((t=>e.posToVal(x+t*_,v.key,!0))));let n=V.values(e,t,i,d);L=2==V.unit?n[0]*_:w(n[0],v,_,x)-w(0,v,_,x),L=A(L-B),E=1==R?-B/2:L+B/2}else{let e=_;if(g.length>1){let t=null;for(let n=0,r=1/0;n<g.length;n++)if(void 0!==m[n]){if(null!=t){let i=Le(g[n]-g[t]);i<r&&(r=i,e=Le(w(g[n],v,_,x)-w(g[t],v,_,x)))}t=n}}let t=e*s;L=A(Pe(a,De(l,e-t))-B-r),E=(0==n?L/2:n==R?0:L)-n*R*r/2}const G={stroke:null,fill:null,clip:null,band:null,gaps:null,flags:lr|cr};let K;0!=P&&(G.band=new Path2D,K=A(b(1==P?y.max:y.min,y,k,S)));const q=W?null:new Path2D,Y=G.band;let{y0:X,y1:Q}=c,J=null;null!=X&&null!=Q&&(m=Q.values(e,t,i,d),J=X.values(e,t,i,d));let ee=C*L,te=$*L;for(let n=1==R?i:d;n>=i&&n<=d;n+=R){let r=m[n];if(void 0===r)continue;let i=2!=v.distr||null!=c?g[n]:n,o=w(i,v,_,x),s=b(ke(r,D),y,k,S);null!=J&&null!=r&&(F=b(J[n],y,k,S));let a=A(o-E),l=A(De(s,F)),u=A(Pe(s,F)),h=l-u;if(null!=r){let i=r<0?te:ee,o=r<0?ee:te;W?(B>0&&null!=j[n]&&M(z.get(j[n]),a,u+Me(B/2),L,De(0,h-B),i,o),null!=N[n]&&M(H.get(N[n]),a,u+Me(B/2),L,De(0,h-B),i,o)):M(q,a,u+Me(B/2),L,De(0,h-B),i,o),O(e,t,n,a-B/2,u,L+B,h)}0!=P&&(T*P==1?(l=u,u=K):(u=l,l=K),h=l-u,M(Y,a-B/2,u,L+B,De(0,h),0,0))}return B>0&&(G.stroke=W?z:q),G.fill=W?H:q,G}))}function Dr(e,t){const n=ke(t?.alignGaps,0);return(t,r,i,o)=>ur(t,r,((s,a,l,c,u,h,f,d,p,g,m)=>{let v,y,w,b=s.pxRound,x=e=>b(h(e,c,g,d)),S=e=>b(f(e,u,m,p));0==c.ori?(v=wr,w=xr,y=Ar):(v=br,w=Sr,y=Rr);const _=c.dir*(0==c.ori?1:-1);i=pe(l,i,o,1),o=pe(l,i,o,-1);let k=x(a[1==_?i:o]),C=k,$=[],A=[];for(let e=1==_?i:o;e>=i&&e<=o;e+=_){let t=l[e];if(null!=t){let t=a[e],n=x(t);$.push(C=n),A.push(S(l[e]))}}const R={stroke:e($,A,v,w,y,b),fill:null,clip:null,band:null,gaps:null,flags:lr},T=R.stroke;let[E,L]=hr(t,r);if(null!=s.fill||0!=E){let e=R.fill=new Path2D(T),n=s.fillTo(t,r,s.min,s.max,E),i=S(n);w(e,C,i),w(e,k,i)}if(!s.spanGaps){let e=[];e.push(...mr(a,l,i,o,_,x,n)),R.gaps=e=s.gaps(t,r,i,o,e),R.clip=pr(e,c.ori,d,p,g,m)}return 0!=L&&(R.band=2==L?[dr(t,r,i,o,T,-1),dr(t,r,i,o,T,1)]:dr(t,r,i,o,T,L)),R}))}function Fr(e){return Dr(Br,e)}function Br(e,t,n,r,i,o){const s=e.length;if(s<2)return null;const a=new Path2D;if(n(a,e[0],t[0]),2==s)r(a,e[1],t[1]);else{let n=Array(s),r=Array(s-1),o=Array(s-1),l=Array(s-1);for(let i=0;i<s-1;i++)o[i]=t[i+1]-t[i],l[i]=e[i+1]-e[i],r[i]=o[i]/l[i];n[0]=r[0];for(let e=1;e<s-1;e++)0===r[e]||0===r[e-1]||r[e-1]>0!==r[e]>0?n[e]=0:(n[e]=3*(l[e-1]+l[e])/((2*l[e]+l[e-1])/r[e-1]+(l[e]+2*l[e-1])/r[e]),isFinite(n[e])||(n[e]=0));n[s-1]=r[s-2];for(let c=0;c<s-1;c++)i(a,e[c]+l[c]/3,t[c]+n[c]*l[c]/3,e[c+1]-l[c]/3,t[c+1]-n[c+1]*l[c]/3,e[c+1],t[c+1])}return a}const Wr=new Set;function Nr(){for(let e of Wr)e.syncRect(!0)}V&&(he(N,K,Nr),he(H,K,Nr,!0),he(z,K,(()=>{ni.pxRatio=Z})));const Hr=Or(),jr=Tr();function zr(e,t,n,r){let i=r?[e[0],e[1]].concat(e.slice(2)):[e[0]].concat(e.slice(1));return i.map(((e,r)=>Vr(e,r,t,n)))}function Ur(e,t){return e.map(((e,n)=>0==n?null:yt({},t,e)))}function Vr(e,t,n,r){return yt({},0==t?n:r,e)}function Gr(e,t,n){return null==t?ct:[t,n]}const Kr=Gr;function qr(e,t,n){return null==t?ct:_e(t,n,we,!0)}function Zr(e,t,n,r){return null==t?ct:ve(t,n,e.scales[r].log,!1)}const Yr=Zr;function Xr(e,t,n,r){return null==t?ct:ye(t,n,e.scales[r].log,!1)}const Qr=Xr;function Jr(e,t,n,r,i){let o=De(Ue(e),Ue(t)),s=t-e,a=de(i/r*s,n);do{let e=n[a],t=r*e/s;if(t>=i&&o+(e<5?it.get(e):0)<=17)return[e,t]}while(++a<n.length);return[0,0]}function ei(e){let t,n;return e=e.replace(/(\d+)px/,((e,r)=>(t=Oe((n=+r)*Z))+"px")),[e,t,n]}function ti(e){e.show&&[e.font,e.labelFont].forEach((e=>{let t=rt(e[2]*Z,1);e[0]=e[0].replace(/[0-9.]+px/,t+"px"),e[1]=t}))}function ni(e,t,n){const r={mode:ke(e.mode,1)},i=r.mode;function M(e,t){let n=3==t.distr?We(e>0?e:t.clamp(r,e,t.min,t.max,t.key)):4==t.distr?je(e,t.asinh):e;return(n-t._min)/(t._max-t._min)}function N(e,t,n,r){let i=M(e,t);return r+n*(-1==t.dir?1-i:i)}function H(e,t,n,r){let i=M(e,t);return r+n*(-1==t.dir?i:1-i)}function j(e,t,n,r){return 0==t.ori?N(e,t,n,r):H(e,t,n,r)}r.valToPosH=N,r.valToPosV=H;let V=!1;r.status=0;const q=r.root=ne(o);if(null!=e.id&&(q.id=e.id),Q(q,e.class),e.title){let t=ne(l,q);t.textContent=e.title}const Y=te("canvas"),X=r.ctx=Y.getContext("2d"),re=ne(c,q);he("click",re,(e=>{let t=pi!=ui||gi!=hi;t&&xi.click(r,e)}),!0);const oe=r.under=ne(u,re);re.appendChild(Y);const ae=r.over=ne(h,re);e=vt(e);const ce=+ke(e.pxAlign,1),ue=vr(ce);(e.plugins||[]).forEach((t=>{t.opts&&(e=t.opts(r,e)||e)}));const pe=e.ms||.001,xe=r.series=1==i?zr(e.series||[],Wn,nr,!1):Ur(e.series||[null],tr),Se=r.axes=zr(e.axes||[],Dn,Yn,!0),$e=r.scales={},Ae=r.bands=e.bands||[];Ae.forEach((e=>{e.fill=Ge(e.fill||null),e.dir=ke(e.dir,-1)}));const Re=2==i?xe[1].facets[0].scale:xe[0].scale,Te={axes:ni,series:Rr},Me=(e.drawOrder||["axes","series"]).map((e=>Te[e]));function Be(t){let n=$e[t];if(null==n){let r=(e.scales||at)[t]||at;if(null!=r.from)Be(r.from),$e[t]=yt({},$e[r.from],r,{key:t});else{n=$e[t]=yt({},t==Re?ir:or,r),n.key=t;let e=n.time,o=n.range,s=ut(o);if((t!=Re||2==i&&!e)&&(!s||null!=o[0]&&null!=o[1]||(o={min:null==o[0]?be:{mode:1,hard:o[0],soft:o[0]},max:null==o[1]?be:{mode:1,hard:o[1],soft:o[1]}},s=!1),!s&&pt(o))){let e=o;o=(t,n,r)=>null==n?ct:_e(n,r,e)}n.range=Ge(o||(e?Kr:t==Re?3==n.distr?Yr:4==n.distr?Qr:Gr:3==n.distr?Zr:4==n.distr?Xr:qr)),n.auto=Ge(!s&&n.auto),n.clamp=Ge(n.clamp||rr),n._min=n._max=null}}}Be("x"),Be("y"),1==i&&xe.forEach((e=>{Be(e.scale)})),Se.forEach((e=>{Be(e.scale)}));for(let o in e.scales)Be(o);const Ne=$e[Re],Ue=Ne.distr;let Ke,qe;0==Ne.ori?(Q(q,s),Ke=N,qe=H):(Q(q,a),Ke=H,qe=N);const Je={};for(let o in $e){let e=$e[o];null==e.min&&null==e.max||(Je[o]={min:e.min,max:e.max},e.min=e.max=null)}const nt=e.tzDate||(e=>new Date(Oe(e/pe))),it=e.fmtDate||It,ot=1==pe?on(nt):ln(nt),st=un(nt,cn(1==pe?rn:an,it)),ht=gn(nt,dn(pn,it)),mt=[],wt=r.legend=yt({},yn,e.legend),bt=wt.show,xt=wt.markers;let St;wt.idxs=mt,xt.width=Ge(xt.width),xt.dash=Ge(xt.dash),xt.stroke=Ge(xt.stroke),xt.fill=Ge(xt.fill);let _t,Ct=[],$t=[],At=!1,Rt={};if(wt.live){const e=xe[1]?xe[1].values:null;At=null!=e,_t=At?e(r,1,0):{_:0};for(let t in _t)Rt[t]=U}if(bt)if(St=te("table",y,q),wt.mount(r,St),At){let e=te("tr",x,St);for(var Tt in te("th",null,e),_t)te("th",k,e).textContent=Tt}else Q(St,b),wt.live&&Q(St,w);const Et={show:!0},Lt={show:!1};function Mt(e,t){if(0==t&&(At||!wt.live||2==i))return ct;let n=[],o=te("tr",S,St,St.childNodes[t]);Q(o,e.class),e.show||Q(o,d);let s=te("th",null,o);if(xt.show){let e=ne(_,s);if(t>0){let n=xt.width(r,t);n&&(e.style.border=n+"px "+xt.dash(r,t)+" "+xt.stroke(r,t)),e.style.background=xt.fill(r,t)}}let a=ne(k,s);for(var l in a.textContent=e.label,t>0&&(xt.show||(a.style.color=e.width>0?xt.stroke(r,t):xt.fill(r,t)),Pt("click",s,(t=>{if(Sn._lock)return;let n=xe.indexOf(e);if((t.ctrlKey||t.metaKey)!=wt.isolate){let e=xe.some(((e,t)=>t>0&&t!=n&&e.show));xe.forEach(((t,r)=>{r>0&&Ti(r,e?r==n?Et:Lt:Et,!0,uo.setSeries)}))}else Ti(n,{show:!e.show},!0,uo.setSeries)})),kn&&Pt(F,s,(t=>{Sn._lock||Ti(xe.indexOf(e),Fi,!0,uo.setSeries)}))),_t){let e=te("td",C,o);e.textContent="--",n.push(e)}return[o,n]}const Ot=new Map;function Pt(e,t,n){const i=Ot.get(t)||{},o=Sn.bind[e](r,t,n);o&&(he(e,t,i[e]=o),Ot.set(t,i))}function Dt(e,t,n){const r=Ot.get(t)||{};for(let i in r)null!=e&&i!=e||(fe(i,t,r[i]),delete r[i]);null==e&&Ot.delete(t)}let Ft=0,Bt=0,Wt=0,Nt=0,zt=0,Ut=0,Vt=0,Gt=0,Kt=0,qt=0;r.bbox={};let Zt=!1,Yt=!1,Xt=!1,Qt=!1,Jt=!1,en=!1;function tn(e,t,n){(n||e!=r.width||t!=r.height)&&fn(e,t),ri(!1),Xt=!0,Yt=!0,Sn.left>=0&&(Qt=en=!0),vi()}function fn(e,t){r.width=Ft=Wt=e,r.height=Bt=Nt=t,zt=Ut=0,bn(),xn();let n=r.bbox;Vt=n.left=et(zt*Z,.5),Gt=n.top=et(Ut*Z,.5),Kt=n.width=et(Wt*Z,.5),qt=n.height=et(Nt*Z,.5)}const mn=3;function vn(){let e=!1,t=0;while(!e){t++;let n=Br(t),i=Nr(t);e=t==mn||n&&i,e||(fn(r.width,r.height),Yt=!0)}}function wn({width:e,height:t}){tn(e,t)}function bn(){let e=!1,t=!1,n=!1,r=!1;Se.forEach(((i,o)=>{if(i.show&&i._show){let{side:o,_size:s}=i,a=o%2,l=null!=i.label?i.labelSize:0,c=s+l;c>0&&(a?(Wt-=c,3==o?(zt+=c,r=!0):n=!0):(Nt-=c,0==o?(Ut+=c,e=!0):t=!0))}})),Ln[0]=e,Ln[1]=n,Ln[2]=t,Ln[3]=r,Wt-=Un[1]+Un[3],zt+=Un[3],Nt-=Un[2]+Un[0],Ut+=Un[0]}function xn(){let e=zt+Wt,t=Ut+Nt,n=zt,r=Ut;function i(i,o){switch(i){case 1:return e+=o,e-o;case 2:return t+=o,t-o;case 3:return n-=o,n+o;case 0:return r-=o,r+o}}Se.forEach(((e,t)=>{if(e.show&&e._show){let t=e.side;e._pos=i(t,e._size),null!=e.label&&(e._lpos=i(t,e.labelSize))}}))}r.setSize=wn;const Sn=r.cursor=yt({},Rn,{drag:{y:2==i}},e.cursor);{Sn.idxs=mt,Sn._lock=!1;let e=Sn.points;e.show=Ge(e.show),e.size=Ge(e.size),e.stroke=Ge(e.stroke),e.width=Ge(e.width),e.fill=Ge(e.fill)}const _n=r.focus=yt({},e.focus||{alpha:.3},Sn.focus);0!=_n.bias&&(_n.prox=1e5);const kn=_n.prox>=0;let Cn=[null];function $n(e,t){if(t>0){let n=Sn.points.show(r,t);if(n)return Q(n,v),Q(n,e.class),ie(n,-10,-10,Wt,Nt),ae.insertBefore(n,Cn[t]),n}}function An(e,t){if(1==i||t>0){let t=1==i&&$e[e.scale].time,n=e.value;e.value=t?dt(n)?gn(nt,dn(n,it)):n||ht:n||Zn,e.label=e.label||(t?Bn:Fn)}if(t>0){e.width=null==e.width?1:e.width,e.paths=e.paths||Hr||Ye,e.fillTo=Ge(e.fillTo||fr),e.pxAlign=+ke(e.pxAlign,ce),e.pxRound=vr(e.pxAlign),e.stroke=Ge(e.stroke||null),e.fill=Ge(e.fill||null),e._stroke=e._fill=e._paths=e._focus=null;let t=Xn(De(1,e.width),1),n=e.points=yt({},{size:t,width:De(1,.2*t),stroke:e.stroke,space:2*t,paths:jr,_stroke:null,_fill:null},e.points);n.show=Ge(n.show),n.filter=Ge(n.filter),n.fill=Ge(n.fill),n.stroke=Ge(n.stroke),n.paths=Ge(n.paths),n.pxAlign=e.pxAlign}if(bt){let n=Mt(e,t);Ct.splice(t,0,n[0]),$t.splice(t,0,n[1]),wt.values.push(null)}if(Sn.show){mt.splice(t,0,null);let n=$n(e,t);n&&Cn.splice(t,0,n)}co("addSeries",t)}function Tn(e,t){t=null==t?xe.length:t,e=1==i?Vr(e,t,Wn,nr):Vr(e,t,null,tr),xe.splice(t,0,e),An(xe[t],t)}function En(e){if(xe.splice(e,1),bt){wt.values.splice(e,1),$t.splice(e,1);let t=Ct.splice(e,1)[0];Dt(null,t.firstChild),t.remove()}Sn.show&&(mt.splice(e,1),Cn.length>1&&Cn.splice(e,1)[0].remove()),co("delSeries",e)}r.addSeries=Tn,r.delSeries=En;const Ln=[!1,!1,!1,!1];function Mn(e,t){if(e._show=e.show,e.show){let n=e.side%2,i=$e[e.scale];null==i&&(e.scale=n?xe[1].scale:Re,i=$e[e.scale]);let o=i.time;e.size=Ge(e.size),e.space=Ge(e.space),e.rotate=Ge(e.rotate),e.incrs=Ge(e.incrs||(2==i.distr?Ht:o?1==pe?nn:sn:jt)),e.splits=Ge(e.splits||(o&&1==i.distr?ot:3==i.distr?jn:4==i.distr?zn:Hn)),e.stroke=Ge(e.stroke),e.grid.stroke=Ge(e.grid.stroke),e.ticks.stroke=Ge(e.ticks.stroke),e.border.stroke=Ge(e.border.stroke);let s=e.values;e.values=ut(s)&&!ut(s[0])?Ge(s):o?ut(s)?un(nt,cn(s,it)):dt(s)?hn(nt,s):s||st:s||Nn,e.filter=Ge(e.filter||(i.distr>=3&&10==i.log?qn:Ze)),e.font=ei(e.font),e.labelFont=ei(e.labelFont),e._size=e.size(r,null,t,0),e._space=e._rotate=e._incrs=e._found=e._splits=e._values=null,e._size>0&&(Ln[t]=!0,e._el=ne(f,re))}}function On(e,t,n,r){let[i,o,s,a]=n,l=t%2,c=0;return 0==l&&(a||o)&&(c=0==t&&!i||2==t&&!s?Oe(Dn.size/3):0),1==l&&(i||s)&&(c=1==t&&!o||3==t&&!a?Oe(Yn.size/2):0),c}const In=r.padding=(e.padding||[On,On,On,On]).map((e=>Ge(ke(e,On)))),Un=r._padding=In.map(((e,t)=>e(r,t,Ln,0)));let Vn,Gn=null,Kn=null;const Qn=1==i?xe[0].idxs:null;let Jn,er,sr,ur,hr,dr,pr,gr,mr,yr,wr=null,br=!1;function xr(e,n){if(t=null==e?[]:vt(e,gt),2==i){Vn=0;for(let e=1;e<xe.length;e++)Vn+=t[e][0].length;r.data=t=e}else if(null==t[0]&&(t[0]=[]),r.data=t.slice(),wr=t[0],Vn=wr.length,2==Ue){t[0]=Array(Vn);for(let e=0;e<Vn;e++)t[0][e]=e}if(r._data=t,ri(!0),co("setData"),2==Ue&&(Xt=!0),!1!==n){let e=Ne;e.auto(r,br)?Sr():Ri(Re,e.min,e.max),Qt=Sn.left>=0,en=!0,vi()}}function Sr(){let e,n;br=!0,1==i&&(Vn>0?(Gn=Qn[0]=0,Kn=Qn[1]=Vn-1,e=t[0][Gn],n=t[0][Kn],2==Ue?(e=Gn,n=Kn):1==Vn&&(3==Ue?[e,n]=ve(e,e,Ne.log,!1):4==Ue?[e,n]=ye(e,e,Ne.log,!1):Ne.time?n=e+Oe(86400/pe):[e,n]=_e(e,n,we,!0))):(Gn=Qn[0]=e=null,Kn=Qn[1]=n=null)),Ri(Re,e,n)}function _r(e,t,n,r,i,o){e??=O,n??=lt,r??="butt",i??=O,o??="round",e!=Jn&&(X.strokeStyle=Jn=e),i!=er&&(X.fillStyle=er=i),t!=sr&&(X.lineWidth=sr=t),o!=hr&&(X.lineJoin=hr=o),r!=dr&&(X.lineCap=dr=r),n!=ur&&X.setLineDash(ur=n)}function kr(e,t,n,r){t!=er&&(X.fillStyle=er=t),e!=pr&&(X.font=pr=e),n!=gr&&(X.textAlign=gr=n),r!=mr&&(X.textBaseline=mr=r)}function Cr(e,t,n,i,o=0){if(i.length>0&&e.auto(r,br)&&(null==t||null==t.min)){let t=ke(Gn,0),r=ke(Kn,i.length-1),s=null==n.min?3==e.distr?me(i,t,r):ge(i,t,r,o):[n.min,n.max];e.min=Pe(e.min,n.min=s[0]),e.max=De(e.max,n.max=s[1])}}function $r(){let e=vt($e,gt);for(let t in e){let n=e[t],o=Je[t];if(null!=o&&null!=o.min)yt(n,o),t==Re&&ri(!0);else if(t!=Re||2==i)if(0==Vn&&null==n.from){let e=n.range(r,null,null,t);n.min=e[0],n.max=e[1]}else n.min=ze,n.max=-ze}if(Vn>0){xe.forEach(((n,o)=>{if(1==i){let i=n.scale,s=e[i],a=Je[i];if(0==o){let e=s.range(r,s.min,s.max,i);s.min=e[0],s.max=e[1],Gn=de(s.min,t[0]),Kn=de(s.max,t[0]),Kn-Gn>1&&(t[0][Gn]<s.min&&Gn++,t[0][Kn]>s.max&&Kn--),n.min=wr[Gn],n.max=wr[Kn]}else n.show&&n.auto&&Cr(s,a,n,t[o],n.sorted);n.idxs[0]=Gn,n.idxs[1]=Kn}else if(o>0&&n.show&&n.auto){let[r,i]=n.facets,s=r.scale,a=i.scale,[l,c]=t[o];Cr(e[s],Je[s],r,l,r.sorted),Cr(e[a],Je[a],i,c,i.sorted),n.min=i.min,n.max=i.max}}));for(let t in e){let n=e[t],i=Je[t];if(null==n.from&&(null==i||null==i.min)){let e=n.range(r,n.min==ze?null:n.min,n.max==-ze?null:n.max,t);n.min=e[0],n.max=e[1]}}}for(let t in e){let n=e[t];if(null!=n.from){let i=e[n.from];if(null==i.min)n.min=n.max=null;else{let e=n.range(r,i.min,i.max,t);n.min=e[0],n.max=e[1]}}}let n={},o=!1;for(let t in e){let r=e[t],i=$e[t];if(i.min!=r.min||i.max!=r.max){i.min=r.min,i.max=r.max;let e=i.distr;i._min=3==e?We(i.min):4==e?je(i.min,i.asinh):i.min,i._max=3==e?We(i.max):4==e?je(i.max,i.asinh):i.max,n[t]=o=!0}}if(o){xe.forEach(((e,t)=>{2==i?t>0&&n.y&&(e._paths=null):n[e.scale]&&(e._paths=null)}));for(let e in n)Xt=!0,co("setScale",e);Sn.show&&Sn.left>=0&&(Qt=en=!0)}for(let t in Je)Je[t]=null}function Ar(e){let t=Ve(Gn-1,0,Vn-1),n=Ve(Kn+1,0,Vn-1);while(null==e[t]&&t>0)t--;while(null==e[n]&&n<Vn-1)n++;return[t,n]}function Rr(){Vn>0&&(xe.forEach(((e,n)=>{if(n>0&&e.show&&null==e._paths){let o=2==i?[0,t[n][0].length-1]:Ar(t[n]);e._paths=e.paths(r,n,o[0],o[1])}})),xe.forEach(((e,t)=>{if(t>0&&e.show){yr!=e.alpha&&(X.globalAlpha=yr=e.alpha),Tr(t,!1),e._paths&&Er(t,!1);{Tr(t,!0);let n=e._paths?e._paths.gaps:null,i=e.points.show(r,t,Gn,Kn,n),o=e.points.filter(r,t,i,n);(i||o)&&(e.points._paths=e.points.paths(r,t,Gn,Kn,o),Er(t,!0))}1!=yr&&(X.globalAlpha=yr=1),co("drawSeries",t)}})))}function Tr(e,t){let n=t?xe[e].points:xe[e];n._stroke=n.stroke(r,e),n._fill=n.fill(r,e)}function Er(e,t){let n=t?xe[e].points:xe[e],r=n._stroke,i=n._fill,{stroke:o,fill:s,clip:a,flags:l}=n._paths,c=null,u=rt(n.width*Z,3),h=u%2/2;t&&null==i&&(i=u>0?"#fff":r);let f=1==n.pxAlign;if(f&&X.translate(h,h),!t){let e=Vt,t=Gt,r=Kt,i=qt,o=u*Z/2;0==n.min&&(i+=o),0==n.max&&(t-=o,i+=o),c=new Path2D,c.rect(e,t,r,i)}t?Or(r,u,n.dash,n.cap,i,o,s,l,a):Lr(e,r,u,n.dash,n.cap,i,o,s,l,c,a),f&&X.translate(-h,-h)}function Lr(e,n,i,o,s,a,l,c,u,h,f){let d=!1;Ae.forEach(((p,g)=>{if(p.series[0]==e){let e,m=xe[p.series[1]],v=t[p.series[1]],y=(m._paths||at).band;ut(y)&&(y=1==p.dir?y[0]:y[1]);let w=null;m.show&&y&&Ce(v,Gn,Kn)?(w=p.fill(r,g)||a,e=m._paths.clip):y=null,Or(n,i,o,s,w,l,c,u,h,f,e,y),d=!0}})),d||Or(n,i,o,s,a,l,c,u,h,f)}r.setData=xr;const Mr=lr|cr;function Or(e,t,n,r,i,o,s,a,l,c,u,h){_r(e,t,n,r,i),(l||c||h)&&(X.save(),l&&X.clip(l),c&&X.clip(c)),h?(a&Mr)==Mr?(X.clip(h),u&&X.clip(u),Pr(i,s),Ir(e,o,t)):a&cr?(Pr(i,s),X.clip(h),Ir(e,o,t)):a&lr&&(X.save(),X.clip(h),u&&X.clip(u),Pr(i,s),X.restore(),Ir(e,o,t)):(Pr(i,s),Ir(e,o,t)),(l||c||h)&&X.restore()}function Ir(e,t,n){n>0&&(t instanceof Map?t.forEach(((e,t)=>{X.strokeStyle=Jn=t,X.stroke(e)})):null!=t&&e&&X.stroke(t))}function Pr(e,t){t instanceof Map?t.forEach(((e,t)=>{X.fillStyle=er=t,X.fill(e)})):null!=t&&e&&X.fill(t)}function Dr(e,t,n,i){let o,s=Se[e];if(i<=0)o=[0,0];else{let a=s._space=s.space(r,e,t,n,i),l=s._incrs=s.incrs(r,e,t,n,i,a);o=Jr(t,n,l,i,a)}return s._found=o}function Fr(e,t,n,r,i,o,s,a,l,c){let u=s%2/2;1==ce&&X.translate(u,u),_r(a,s,l,c,a),X.beginPath();let h,f,d,p,g=i+(0==r||3==r?-o:o);0==n?(f=i,p=g):(h=i,d=g);for(let m=0;m<e.length;m++)null!=t[m]&&(0==n?h=d=e[m]:f=p=e[m],X.moveTo(h,f),X.lineTo(d,p));X.stroke(),1==ce&&X.translate(-u,-u)}function Br(e){let t=!0;return Se.forEach(((n,i)=>{if(!n.show)return;let o=$e[n.scale];if(null==o.min)return void(n._show&&(t=!1,n._show=!1,ri(!1)));n._show||(t=!1,n._show=!0,ri(!1));let s=n.side,a=s%2,{min:l,max:c}=o,[u,h]=Dr(i,l,c,0==a?Wt:Nt);if(0==h)return;let f=2==o.distr,d=n._splits=n.splits(r,i,l,c,u,h,f),p=2==o.distr?d.map((e=>wr[e])):d,g=2==o.distr?wr[d[1]]-wr[d[0]]:u,m=n._values=n.values(r,n.filter(r,p,i,h,g),i,h,g);n._rotate=2==s?n.rotate(r,m,i,h):0;let v=n._size;n._size=Ie(n.size(r,m,i,e)),null!=v&&n._size!=v&&(t=!1)})),t}function Nr(e){let t=!0;return In.forEach(((n,i)=>{let o=n(r,i,Ln,e);o!=Un[i]&&(t=!1),Un[i]=o})),t}function ni(){for(let e=0;e<Se.length;e++){let t=Se[e];if(!t.show||!t._show)continue;let n,i,o=t.side,s=o%2,a=t.stroke(r,e),l=0==o||3==o?-1:1;if(t.label){let e=t.labelGap*l,r=Oe((t._lpos+e)*Z);kr(t.labelFont[0],a,"center",2==o?R:T),X.save(),1==s?(n=i=0,X.translate(r,Oe(Gt+qt/2)),X.rotate((3==o?-Ee:Ee)/2)):(n=Oe(Vt+Kt/2),i=r),X.fillText(t.label,n,i),X.restore()}let[c,u]=t._found;if(0==u)continue;let h=$e[t.scale],f=0==s?Kt:qt,d=0==s?Vt:Gt,p=Oe(t.gap*Z),g=t._splits,m=2==h.distr?g.map((e=>wr[e])):g,v=2==h.distr?wr[g[1]]-wr[g[0]]:c,y=t.ticks,w=t.border,b=y.show?Oe(y.size*Z):0,x=t._rotate*-Ee/180,S=ue(t._pos*Z),_=(b+p)*l,k=S+_;i=0==s?k:0,n=1==s?k:0;let C=t.font[0],$=1==t.align?E:2==t.align?L:x>0?E:x<0?L:0==s?"center":3==o?L:E,A=x||1==s?"middle":2==o?R:T;kr(C,a,$,A);let M=t.font[1]*Pn,O=g.map((e=>ue(j(e,h,f,d)))),I=t._values;for(let e=0;e<I.length;e++){let t=I[e];if(null!=t){0==s?n=O[e]:i=O[e],t=""+t;let r=-1==t.indexOf("\n")?[t]:t.split(/\n/gm);for(let e=0;e<r.length;e++){let t=r[e];x?(X.save(),X.translate(n,i+e*M),X.rotate(x),X.fillText(t,0,0),X.restore()):X.fillText(t,n,i+e*M)}}}y.show&&Fr(O,y.filter(r,m,e,u,v),s,o,S,b,rt(y.width*Z,3),y.stroke(r,e),y.dash,y.cap);let P=t.grid;P.show&&Fr(O,P.filter(r,m,e,u,v),s,0==s?2:1,0==s?Gt:Vt,0==s?qt:Kt,rt(P.width*Z,3),P.stroke(r,e),P.dash,P.cap),w.show&&Fr([S],[1],0==s?1:0,0==s?1:2,1==s?Gt:Vt,1==s?qt:Kt,rt(w.width*Z,3),w.stroke(r,e),w.dash,w.cap)}co("drawAxes")}function ri(e){xe.forEach(((t,n)=>{n>0&&(t._paths=null,e&&(1==i?(t.min=null,t.max=null):t.facets.forEach((e=>{e.min=null,e.max=null}))))}))}let ii,oi,si,ai,li,ci,ui,hi,fi,di,pi,gi,mi=!1;function vi(){mi||(kt(yi),mi=!0)}function yi(){Zt&&($r(),Zt=!1),Xt&&(vn(),Xt=!1),Yt&&(ee(oe,E,zt),ee(oe,R,Ut),ee(oe,$,Wt),ee(oe,A,Nt),ee(ae,E,zt),ee(ae,R,Ut),ee(ae,$,Wt),ee(ae,A,Nt),ee(re,$,Ft),ee(re,A,Bt),Y.width=Oe(Ft*Z),Y.height=Oe(Bt*Z),Se.forEach((({_el:e,_show:t,_size:n,_pos:r,side:i})=>{if(null!=e)if(t){let t=3===i||0===i?n:0,o=i%2==1;ee(e,o?"left":"top",r-t),ee(e,o?"width":"height",n),ee(e,o?"top":"left",o?Ut:zt),ee(e,o?"height":"width",o?Nt:Wt),J(e,d)}else Q(e,d)})),Jn=er=sr=hr=dr=pr=gr=mr=ur=null,yr=1,Xi(!0),co("setSize"),Yt=!1),Ft>0&&Bt>0&&(X.clearRect(0,0,Y.width,Y.height),co("drawClear"),Me.forEach((e=>e())),co("draw")),ki.show&&Jt&&($i(ki),Jt=!1),Sn.show&&Qt&&(Zi(null,!0,!1),Qt=!1),wt.show&&wt.live&&en&&(Ki(),en=!1),V||(V=!0,r.status=1,co("ready")),br=!1,mi=!1}function wi(e,n){let i=$e[e];if(null==i.from){if(0==Vn){let t=i.range(r,n.min,n.max,e);n.min=t[0],n.max=t[1]}if(n.min>n.max){let e=n.min;n.min=n.max,n.max=e}if(Vn>1&&null!=n.min&&null!=n.max&&n.max-n.min<1e-16)return;e==Re&&2==i.distr&&Vn>0&&(n.min=de(n.min,t[0]),n.max=de(n.max,t[0]),n.min==n.max&&n.max++),Je[e]=n,Zt=!0,vi()}}r.redraw=(e,t)=>{Xt=t||!1,!1!==e?Ri(Re,Ne.min,Ne.max):vi()},r.setScale=wi;let bi=!1;const xi=Sn.drag;let Si=xi.x,_i=xi.y;Sn.show&&(Sn.x&&(ii=ne(g,ae)),Sn.y&&(oi=ne(m,ae)),0==Ne.ori?(si=ii,ai=oi):(si=oi,ai=ii),pi=Sn.left,gi=Sn.top);const ki=r.select=yt({show:!0,over:!0,left:0,width:0,top:0,height:0},e.select),Ci=ki.show?ne(p,ki.over?ae:oe):null;function $i(e,t){if(ki.show){for(let t in e)ki[t]=e[t],t in eo&&ee(Ci,t,e[t]);!1!==t&&co("setSelect")}}function Ai(e,t){let n=xe[e],r=bt?Ct[e]:null;n.show?r&&J(r,d):(r&&Q(r,d),Cn.length>1&&ie(Cn[e],-10,-10,Wt,Nt))}function Ri(e,t,n){wi(e,{min:t,max:n})}function Ti(e,t,n,o){null!=t.focus&&Bi(e),null!=t.show&&xe.forEach(((n,r)=>{r>0&&(e==r||null==e)&&(n.show=t.show,Ai(r,t.show),Ri(2==i?n.facets[1].scale:n.scale,null,null),vi())})),!1!==n&&co("setSeries",e,t),o&&po("setSeries",r,e,t)}function Ei(e,t){yt(Ae[e],t)}function Li(e,t){e.fill=Ge(e.fill||null),e.dir=ke(e.dir,-1),t=null==t?Ae.length:t,Ae.splice(t,0,e)}function Mi(e){null==e?Ae.length=0:Ae.splice(e,1)}function Oi(e,t){xe[e].alpha=t,Sn.show&&Cn[e]&&(Cn[e].style.opacity=t),bt&&Ct[e]&&(Ct[e].style.opacity=t)}let Ii,Pi,Di;r.setSelect=$i,r.setSeries=Ti,r.addBand=Li,r.setBand=Ei,r.delBand=Mi;const Fi={focus:!0};function Bi(e){if(e!=Di){let t=null==e,n=1!=_n.alpha;xe.forEach(((r,i)=>{let o=t||0==i||i==e;r._focus=t?null:o,n&&Oi(i,o?1:_n.alpha)})),Di=e,n&&vi()}}function Wi(e,t,n){let r=$e[t];n&&(e=e/Z-(1==r.ori?Ut:zt));let i=Wt;1==r.ori&&(i=Nt,e=i-e),-1==r.dir&&(e=i-e);let o=r._min,s=r._max,a=e/i,l=o+(s-o)*a,c=r.distr;return 3==c?Fe(10,l):4==c?He(l,r.asinh):l}function Ni(e,n){let r=Wi(e,Re,n);return de(r,t[0],Gn,Kn)}function Hi(e){e(r),vi()}function ji(e,t){ee(Ci,E,ki.left=e),ee(Ci,$,ki.width=t)}function zi(e,t){ee(Ci,R,ki.top=e),ee(Ci,A,ki.height=t)}bt&&kn&&he(B,St,(e=>{Sn._lock||null!=Di&&Ti(null,Fi,!0,uo.setSeries)})),r.valToIdx=e=>de(e,t[0]),r.posToIdx=Ni,r.posToVal=Wi,r.valToPos=(e,t,n)=>0==$e[t].ori?N(e,$e[t],n?Kt:Wt,n?Vt:0):H(e,$e[t],n?qt:Nt,n?Gt:0),r.batch=Hi,r.setCursor=(e,t,n)=>{pi=e.left,gi=e.top,Zi(null,t,n)};let Ui=0==Ne.ori?ji:zi,Vi=1==Ne.ori?ji:zi;function Gi(){if(bt&&wt.live)for(let e=2==i?1:0;e<xe.length;e++){if(0==e&&At)continue;let t=wt.values[e],n=0;for(let r in t)$t[e][n++].firstChild.nodeValue=t[r]}}function Ki(e,t){null!=e&&(e.idxs?e.idxs.forEach(((e,t)=>{mt[t]=e})):ft(e.idx)||mt.fill(e.idx),wt.idx=mt[0]);for(let n=0;n<xe.length;n++)(n>0||1==i&&!At)&&qi(n,mt[n]);bt&&wt.live&&Gi(),en=!1,!1!==t&&co("setLegend")}function qi(e,n){let i,o=xe[e],s=0==e&&2==Ue?wr:t[e];At?i=o.values(r,e,n)??Rt:(i=o.value(r,null==n?null:s[n],e,n),i=null==i?Rt:{_:i}),wt.values[e]=i}function Zi(e,n,o){let s;fi=pi,di=gi,[pi,gi]=Sn.move(r,pi,gi),Sn.show&&(si&&ie(si,Oe(pi),0,Wt,Nt),ai&&ie(ai,0,Oe(gi),Wt,Nt));let a=Gn>Kn;Ii=ze;let l=0==Ne.ori?Wt:Nt,c=1==Ne.ori?Wt:Nt;if(pi<0||0==Vn||a){s=null;for(let e=0;e<xe.length;e++)e>0&&Cn.length>1&&ie(Cn[e],-10,-10,Wt,Nt);kn&&Ti(null,Fi,!0,null==e&&uo.setSeries),wt.live&&(mt.fill(s),en=!0)}else{let e,n,o;1==i&&(e=0==Ne.ori?pi:gi,n=Wi(e,Re),s=de(n,t[0],Gn,Kn),o=Ke(t[0][s],Ne,l,0));for(let a=2==i?1:0;a<xe.length;a++){let e=xe[a],u=mt[a],h=1==i?t[a][u]:t[a][1][u],f=Sn.dataIdx(r,a,s,n),d=1==i?t[a][f]:t[a][1][f];en=en||d!=h||f!=u,mt[a]=f;let p=tt(f==s?o:Ke(1==i?t[0][f]:t[a][0][f],Ne,l,0),1);if(a>0&&e.show){let t,n,o=null==d?-10:tt(qe(d,1==i?$e[e.scale]:$e[e.facets[1].scale],c,0),1);if(kn&&o>=0&&1==i){let t=Le(o-gi),n=_n.bias;if(0!=n){let r=1==Ne.ori?pi:gi,i=Wi(r,e.scale),o=d>=0?1:-1,s=i>=0?1:-1;s==o&&t<Ii&&(1==s?1==n?d>=i:d<=i:1==n?d<=i:d>=i)&&(Ii=t,Pi=a)}else t<Ii&&(Ii=t,Pi=a)}if(0==Ne.ori?(t=p,n=o):(t=o,n=p),en&&Cn.length>1){se(Cn[a],Sn.points.fill(r,a),Sn.points.stroke(r,a));let e,i,o,s,l=!0,c=Sn.points.bbox;if(null!=c){l=!1;let t=c(r,a);o=t.left,s=t.top,e=t.width,i=t.height}else o=t,s=n,e=i=Sn.points.size(r,a);le(Cn[a],e,i,l),ie(Cn[a],o,s,Wt,Nt)}}}}if(Sn.idx=s,Sn.left=pi,Sn.top=gi,en&&(wt.idx=s,Ki()),ki.show&&bi)if(null!=e){let[t,n]=uo.scales,[r,i]=uo.match,[o,s]=e.cursor.sync.scales,a=e.cursor.drag;if(Si=a._x,_i=a._y,Si||_i){let a,u,h,f,d,{left:p,top:g,width:m,height:v}=e.select,y=e.scales[t].ori,w=e.posToVal,b=null!=t&&r(t,o),x=null!=n&&i(n,s);b&&Si?(0==y?(a=p,u=m):(a=g,u=v),h=$e[t],f=Ke(w(a,o),h,l,0),d=Ke(w(a+u,o),h,l,0),Ui(Pe(f,d),Le(d-f))):Ui(0,l),x&&_i?(1==y?(a=p,u=m):(a=g,u=v),h=$e[n],f=qe(w(a,s),h,c,0),d=qe(w(a+u,s),h,c,0),Vi(Pe(f,d),Le(d-f))):Vi(0,c)}else to()}else{let e=Le(fi-li),t=Le(di-ci);if(1==Ne.ori){let n=e;e=t,t=n}Si=xi.x&&e>=xi.dist,_i=xi.y&&t>=xi.dist;let n,r,i=xi.uni;null!=i?Si&&_i&&(Si=e>=i,_i=t>=i,Si||_i||(t>e?_i=!0:Si=!0)):xi.x&&xi.y&&(Si||_i)&&(Si=_i=!0),Si&&(0==Ne.ori?(n=ui,r=pi):(n=hi,r=gi),Ui(Pe(n,r),Le(r-n)),_i||Vi(0,c)),_i&&(1==Ne.ori?(n=ui,r=pi):(n=hi,r=gi),Vi(Pe(n,r),Le(r-n)),Si||Ui(0,l)),Si||_i||(Ui(0,0),Vi(0,0))}if(xi._x=Si,xi._y=_i,null==e){if(o){if(null!=ho){let[e,t]=uo.scales;uo.values[0]=null!=e?Wi(0==Ne.ori?pi:gi,e):null,uo.values[1]=null!=t?Wi(1==Ne.ori?pi:gi,t):null}po(I,r,pi,gi,Wt,Nt,s)}if(kn){let e=o&&uo.setSeries,t=_n.prox;null==Di?Ii<=t&&Ti(Pi,Fi,!0,e):Ii>t?Ti(null,Fi,!0,e):Pi!=Di&&Ti(Pi,Fi,!0,e)}}!1!==n&&co("setCursor")}r.setLegend=Ki;let Yi=null;function Xi(e){!0===e?Yi=null:(Yi=ae.getBoundingClientRect(),co("syncRect",Yi))}function Qi(e,t,n,r,i,o,s){Sn._lock||bi&&null!=e&&0==e.movementX&&0==e.movementY||(Ji(e,t,n,r,i,o,s,!1,null!=e),null!=e?Zi(null,!0,!0):Zi(t,!0,!1))}function Ji(e,t,n,i,o,s,a,l,c){if(null==Yi&&Xi(!1),null!=e)n=e.clientX-Yi.left,i=e.clientY-Yi.top;else{if(n<0||i<0)return pi=-10,void(gi=-10);let[e,r]=uo.scales,a=t.cursor.sync,[l,c]=a.values,[u,h]=a.scales,[f,d]=uo.match,p=t.axes[0].side%2==1,g=0==Ne.ori?Wt:Nt,m=1==Ne.ori?Wt:Nt,v=p?s:o,y=p?o:s,w=p?i:n,b=p?n:i;if(n=null!=u?f(e,u)?j(l,$e[e],g,0):-10:g*(w/v),i=null!=h?d(r,h)?j(c,$e[r],m,0):-10:m*(b/y),1==Ne.ori){let e=n;n=i,i=e}}c&&((n<=1||n>=Wt-1)&&(n=et(n,Wt)),(i<=1||i>=Nt-1)&&(i=et(i,Nt))),l?(li=n,ci=i,[ui,hi]=Sn.move(r,n,i)):(pi=n,gi=i)}const eo={width:0,height:0,left:0,top:0};function to(){$i(eo,!1)}function no(e,t,n,i,o,s,a){bi=!0,Si=_i=xi._x=xi._y=!1,Ji(e,t,n,i,o,s,a,!0,!1),null!=e&&(Pt(D,G,ro),po(P,r,ui,hi,Wt,Nt,null))}function ro(e,t,n,i,o,s,a){bi=xi._x=xi._y=!1,Ji(e,t,n,i,o,s,a,!1,!0);let{left:l,top:c,width:u,height:h}=ki,f=u>0||h>0;if(f&&$i(ki),xi.setScale&&f){let e=l,t=u,n=c,r=h;if(1==Ne.ori&&(e=c,t=h,n=l,r=u),Si&&Ri(Re,Wi(e,Re),Wi(e+t,Re)),_i)for(let i in $e){let e=$e[i];i!=Re&&null==e.from&&e.min!=ze&&Ri(i,Wi(n+r,i),Wi(n,i))}to()}else Sn.lock&&(Sn._lock=!Sn._lock,Sn._lock||Zi(null,!0,!1));null!=e&&(Dt(D,G),po(D,r,pi,gi,Wt,Nt,null))}function io(e,t,n,r,i,o,s){if(!Sn._lock){let e=bi;if(bi){let e,t,n=!0,r=!0,i=10;0==Ne.ori?(e=Si,t=_i):(e=_i,t=Si),e&&t&&(n=pi<=i||pi>=Wt-i,r=gi<=i||gi>=Nt-i),e&&n&&(pi=pi<ui?0:Wt),t&&r&&(gi=gi<hi?0:Nt),Zi(null,!0,!0),bi=!1}pi=-10,gi=-10,Zi(null,!0,!0),e&&(bi=e)}}function oo(e,t,n,i,o,s,a){Sr(),to(),null!=e&&po(W,r,pi,gi,Wt,Nt,null)}function so(){Se.forEach(ti),tn(r.width,r.height,!0)}he(z,K,so);const ao={};ao.mousedown=no,ao.mousemove=Qi,ao.mouseup=ro,ao.dblclick=oo,ao["setSeries"]=(e,t,n,r)=>{Ti(n,r,!0,!1)},Sn.show&&(Pt(P,ae,no),Pt(I,ae,Qi),Pt(F,ae,Xi),Pt(B,ae,io),Pt(W,ae,oo),Wr.add(r),r.syncRect=Xi);const lo=r.hooks=e.hooks||{};function co(e,t,n){e in lo&&lo[e].forEach((e=>{e.call(null,r,t,n)}))}(e.plugins||[]).forEach((e=>{for(let t in e.hooks)lo[t]=(lo[t]||[]).concat(e.hooks[t])}));const uo=yt({key:null,setSeries:!1,filters:{pub:Xe,sub:Xe},scales:[Re,xe[1]?xe[1].scale:null],match:[Qe,Qe],values:[null,null]},Sn.sync);Sn.sync=uo;const ho=uo.key,fo=ar(ho);function po(e,t,n,r,i,o,s){uo.filters.pub(e,t,n,r,i,o,s)&&fo.pub(e,t,n,r,i,o,s)}function go(e,t,n,r,i,o,s){uo.filters.sub(e,t,n,r,i,o,s)&&ao[e](null,t,n,r,i,o,s)}function mo(){fo.unsub(r),Wr.delete(r),Ot.clear(),fe(z,K,so),q.remove(),St?.remove(),co("destroy")}function vo(){co("init",e,t),xr(t||e.data,!1),Je[Re]?wi(Re,Je[Re]):Sr(),Jt=ki.show,Qt=en=!0,tn(e.width,e.height)}return fo.sub(r),r.pub=go,r.destroy=mo,xe.forEach(An),Se.forEach(Mn),n?n instanceof HTMLElement?(n.appendChild(q),vo()):n(r,vo):vo(),r}ni.assign=yt,ni.fmtNum=Re,ni.rangeNum=_e,ni.rangeLog=ve,ni.rangeAsinh=ye,ni.orient=ur,ni.pxRatio=Z,ni.join=_t,ni.fmtDate=It,ni.tzDate=Dt,ni.sync=ar;{ni.addGap=gr,ni.clipGaps=pr;let e=ni.paths={points:Tr};e.linear=Or,e.stepped=Ir,e.bars=Pr,e.spline=Fr}},67284:function(e,t,n){"use strict";n.d(t,{P:function(){return a},x:function(){return s}});var r="horizontal",i="vertical",o={name:"multipane",props:{layout:{type:String,default:i}},data:function(){return{isResizing:!1}},computed:{classnames:function(){return["multipane","layout-"+this.layout.slice(0,1),this.isResizing?"is-resizing":""]},cursor:function(){return this.isResizing?this.layout==i?"col-resize":"row-resize":""},userSelect:function(){return this.isResizing?"none":""}},methods:{onMouseDown:function(e){var t=e.target,n=e.pageX,o=e.pageY;if(t.className&&t.className.match("multipane-resizer")){var s=this,a=s.$el,l=s.layout,c=t.previousElementSibling,u=c.offsetWidth,h=c.offsetHeight,f=!!(c.style.width+"").match("%"),d=window.addEventListener,p=window.removeEventListener,g=function(e,t){if(void 0===t&&(t=0),l==i){var n=a.clientWidth,o=e+t;return c.style.width=f?o/n*100+"%":o+"px"}if(l==r){var s=a.clientHeight,u=e+t;return c.style.height=f?u/s*100+"%":u+"px"}};s.isResizing=!0;var m=g();s.$emit("paneResizeStart",c,t,m);var v=function(e){var r=e.pageX,a=e.pageY;m=l==i?g(u,r-n):g(h,a-o),s.$emit("paneResize",c,t,m)},y=function(){m=g(l==i?c.clientWidth:c.clientHeight),s.isResizing=!1,p("mousemove",v),p("mouseup",y),s.$emit("paneResizeStop",c,t,m)};d("mousemove",v),d("mouseup",y)}}}};!function(){if("undefined"!=typeof document){var e=document.head||document.getElementsByTagName("head")[0],t=document.createElement("style"),n=".multipane { display: flex; } .multipane.layout-h { flex-direction: column; } .multipane.layout-v { flex-direction: row; } .multipane > div { position: relative; z-index: 1; } .multipane-resizer { display: block; position: relative; z-index: 2; } .layout-h > .multipane-resizer { width: 100%; height: 10px; margin-top: -10px; top: 5px; cursor: row-resize; } .layout-v > .multipane-resizer { width: 10px; height: 100%; margin-left: -10px; left: 5px; cursor: col-resize; } ";t.type="text/css",t.styleSheet?t.styleSheet.cssText=n:t.appendChild(document.createTextNode(n)),e.appendChild(t)}}();var s=Object.assign(o,{render:function(){var e=this,t=e.$createElement;return(e._self._c||t)("div",{class:e.classnames,style:{cursor:e.cursor,userSelect:e.userSelect},on:{mousedown:e.onMouseDown}},[e._t("default")],2)},staticRenderFns:[]});s.prototype=o.prototype,function(){if("undefined"!=typeof document){var e=document.head||document.getElementsByTagName("head")[0],t=document.createElement("style");t.type="text/css",t.styleSheet?t.styleSheet.cssText="":t.appendChild(document.createTextNode("")),e.appendChild(t)}}();var a={render:function(){var e=this,t=e.$createElement;return(e._self._c||t)("div",{staticClass:"multipane-resizer"},[e._t("default")],2)},staticRenderFns:[]};"undefined"!=typeof window&&window.Vue&&(window.Vue.component("multipane",s),window.Vue.component("multipane-resizer",a))},8514:function(e,t,n){var r=n(796);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(3514).Z;i("400a75d9",r,!0,{sourceMap:!1,shadowMode:!1})},49502:function(e,t,n){"use strict";n.d(t,{Z:function(){return i}});n(58188);function r(e,t,n,r,i,o,s){try{var a=e[o](s),l=a.value}catch(c){return void n(c)}a.done?t(l):Promise.resolve(l).then(r,i)}function i(e){return function(){var t=this,n=arguments;return new Promise((function(i,o){var s=e.apply(t,n);function a(e){r(s,i,o,a,l,"next",e)}function l(e){r(s,i,o,a,l,"throw",e)}a(void 0)}))}}},96050:function(e,t,n){"use strict";n.d(t,{Z:function(){return r}});n(71372);function r(e,t,n){if(!t.has(e))throw new TypeError("attempted to "+n+" private field on non-instance");return t.get(e)}},72645:function(e,t,n){"use strict";function r(e,t){return t.get?t.get.call(e):t.value}n.d(t,{Z:function(){return o}});var i=n(96050);function o(e,t){var n=(0,i.Z)(e,t,"get");return r(e,n)}},22124:function(e,t,n){"use strict";n.d(t,{Z:function(){return i}});n(71372);function r(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}function i(e,t,n){r(e,t),t.set(e,n)}},82842:function(e,t,n){"use strict";n.d(t,{Z:function(){return o}});n(71372);function r(e,t,n){if(t.set)t.set.call(e,n);else{if(!t.writable)throw new TypeError("attempted to set read only private field");t.value=n}}var i=n(96050);function o(e,t,n){var o=(0,i.Z)(e,t,"set");return r(e,o,n),n}},78081:function(e,t,n){"use strict";n.d(t,{Z:function(){return i}});n(34115),n(634),n(58188),n(20796),n(28673),n(6886),n(71372);var r=n(93511);function i(e,t){var n="undefined"!==typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!n){if(Array.isArray(e)||(n=(0,r.Z)(e))||t&&e&&"number"===typeof e.length){n&&(e=n);var i=0,o=function(){};return{s:o,n:function(){return i>=e.length?{done:!0}:{done:!1,value:e[i++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var s,a=!0,l=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return a=e.done,e},e:function(e){l=!0,s=e},f:function(){try{a||null==n["return"]||n["return"]()}finally{if(l)throw s}}}}},15789:function(e,t,n){"use strict";n.d(t,{Z:function(){return i}});n(95094),n(34115),n(634),n(58188),n(20796),n(28673),n(6886),n(96882),n(38859),n(17525),n(18275),n(96928),n(71372),n(36728),n(1939),n(52506),n(32501);var r=n(26259);function i(){
49
+ /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */
50
+ i=function(){return e};var e={},t=Object.prototype,n=t.hasOwnProperty,o=Object.defineProperty||function(e,t,n){e[t]=n.value},s="function"==typeof Symbol?Symbol:{},a=s.iterator||"@@iterator",l=s.asyncIterator||"@@asyncIterator",c=s.toStringTag||"@@toStringTag";function u(e,t,n){return Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}),e[t]}try{u({},"")}catch(E){u=function(e,t,n){return e[t]=n}}function h(e,t,n,r){var i=t&&t.prototype instanceof p?t:p,s=Object.create(i.prototype),a=new A(r||[]);return o(s,"_invoke",{value:_(e,n,a)}),s}function f(e,t,n){try{return{type:"normal",arg:e.call(t,n)}}catch(E){return{type:"throw",arg:E}}}e.wrap=h;var d={};function p(){}function g(){}function m(){}var v={};u(v,a,(function(){return this}));var y=Object.getPrototypeOf,w=y&&y(y(R([])));w&&w!==t&&n.call(w,a)&&(v=w);var b=m.prototype=p.prototype=Object.create(v);function x(e){["next","throw","return"].forEach((function(t){u(e,t,(function(e){return this._invoke(t,e)}))}))}function S(e,t){function i(o,s,a,l){var c=f(e[o],e,s);if("throw"!==c.type){var u=c.arg,h=u.value;return h&&"object"==(0,r.Z)(h)&&n.call(h,"__await")?t.resolve(h.__await).then((function(e){i("next",e,a,l)}),(function(e){i("throw",e,a,l)})):t.resolve(h).then((function(e){u.value=e,a(u)}),(function(e){return i("throw",e,a,l)}))}l(c.arg)}var s;o(this,"_invoke",{value:function(e,n){function r(){return new t((function(t,r){i(e,n,t,r)}))}return s=s?s.then(r,r):r()}})}function _(e,t,n){var r="suspendedStart";return function(i,o){if("executing"===r)throw new Error("Generator is already running");if("completed"===r){if("throw"===i)throw o;return T()}for(n.method=i,n.arg=o;;){var s=n.delegate;if(s){var a=k(s,n);if(a){if(a===d)continue;return a}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if("suspendedStart"===r)throw r="completed",n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);r="executing";var l=f(e,t,n);if("normal"===l.type){if(r=n.done?"completed":"suspendedYield",l.arg===d)continue;return{value:l.arg,done:n.done}}"throw"===l.type&&(r="completed",n.method="throw",n.arg=l.arg)}}}function k(e,t){var n=t.method,r=e.iterator[n];if(void 0===r)return t.delegate=null,"throw"===n&&e.iterator["return"]&&(t.method="return",t.arg=void 0,k(e,t),"throw"===t.method)||"return"!==n&&(t.method="throw",t.arg=new TypeError("The iterator does not provide a '"+n+"' method")),d;var i=f(r,e.iterator,t.arg);if("throw"===i.type)return t.method="throw",t.arg=i.arg,t.delegate=null,d;var o=i.arg;return o?o.done?(t[e.resultName]=o.value,t.next=e.nextLoc,"return"!==t.method&&(t.method="next",t.arg=void 0),t.delegate=null,d):o:(t.method="throw",t.arg=new TypeError("iterator result is not an object"),t.delegate=null,d)}function C(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function $(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function A(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(C,this),this.reset(!0)}function R(e){if(e){var t=e[a];if(t)return t.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var r=-1,i=function t(){for(;++r<e.length;)if(n.call(e,r))return t.value=e[r],t.done=!1,t;return t.value=void 0,t.done=!0,t};return i.next=i}}return{next:T}}function T(){return{value:void 0,done:!0}}return g.prototype=m,o(b,"constructor",{value:m,configurable:!0}),o(m,"constructor",{value:g,configurable:!0}),g.displayName=u(m,c,"GeneratorFunction"),e.isGeneratorFunction=function(e){var t="function"==typeof e&&e.constructor;return!!t&&(t===g||"GeneratorFunction"===(t.displayName||t.name))},e.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,m):(e.__proto__=m,u(e,c,"GeneratorFunction")),e.prototype=Object.create(b),e},e.awrap=function(e){return{__await:e}},x(S.prototype),u(S.prototype,l,(function(){return this})),e.AsyncIterator=S,e.async=function(t,n,r,i,o){void 0===o&&(o=Promise);var s=new S(h(t,n,r,i),o);return e.isGeneratorFunction(n)?s:s.next().then((function(e){return e.done?e.value:s.next()}))},x(b),u(b,c,"Generator"),u(b,a,(function(){return this})),u(b,"toString",(function(){return"[object Generator]"})),e.keys=function(e){var t=Object(e),n=[];for(var r in t)n.push(r);return n.reverse(),function e(){for(;n.length;){var r=n.pop();if(r in t)return e.value=r,e.done=!1,e}return e.done=!0,e}},e.values=R,A.prototype={constructor:A,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEach($),!e)for(var t in this)"t"===t.charAt(0)&&n.call(this,t)&&!isNaN(+t.slice(1))&&(this[t]=void 0)},stop:function(){this.done=!0;var e=this.tryEntries[0].completion;if("throw"===e.type)throw e.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var t=this;function r(n,r){return s.type="throw",s.arg=e,t.next=n,r&&(t.method="next",t.arg=void 0),!!r}for(var i=this.tryEntries.length-1;i>=0;--i){var o=this.tryEntries[i],s=o.completion;if("root"===o.tryLoc)return r("end");if(o.tryLoc<=this.prev){var a=n.call(o,"catchLoc"),l=n.call(o,"finallyLoc");if(a&&l){if(this.prev<o.catchLoc)return r(o.catchLoc,!0);if(this.prev<o.finallyLoc)return r(o.finallyLoc)}else if(a){if(this.prev<o.catchLoc)return r(o.catchLoc,!0)}else{if(!l)throw new Error("try statement without catch or finally");if(this.prev<o.finallyLoc)return r(o.finallyLoc)}}}},abrupt:function(e,t){for(var r=this.tryEntries.length-1;r>=0;--r){var i=this.tryEntries[r];if(i.tryLoc<=this.prev&&n.call(i,"finallyLoc")&&this.prev<i.finallyLoc){var o=i;break}}o&&("break"===e||"continue"===e)&&o.tryLoc<=t&&t<=o.finallyLoc&&(o=null);var s=o?o.completion:{};return s.type=e,s.arg=t,o?(this.method="next",this.next=o.finallyLoc,d):this.complete(s)},complete:function(e,t){if("throw"===e.type)throw e.arg;return"break"===e.type||"continue"===e.type?this.next=e.arg:"return"===e.type?(this.rval=this.arg=e.arg,this.method="return",this.next="end"):"normal"===e.type&&t&&(this.next=t),d},finish:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.finallyLoc===e)return this.complete(n.completion,n.afterLoc),$(n),d}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.tryLoc===e){var r=n.completion;if("throw"===r.type){var i=r.arg;$(n)}return i}}throw new Error("illegal catch attempt")},delegateYield:function(e,t,n){return this.delegate={iterator:R(e),resultName:t,nextLoc:n},"next"===this.method&&(this.arg=void 0),d}},e}},50615:function(e,t,n){"use strict";n.d(t,{Z:function(){return l}});var r=n(43692);function i(e){if(Array.isArray(e))return(0,r.Z)(e)}n(34115),n(634),n(58188),n(20796),n(28673),n(6886),n(27233);function o(e){if("undefined"!==typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}var s=n(93511);n(71372);function a(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function l(e){return i(e)||o(e)||(0,s.Z)(e)||a()}}}]);
51
+ //# sourceMappingURL=807.js.map