var Zt=Object.defineProperty,Ot=Object.defineProperties;var Dt=Object.getOwnPropertyDescriptors;var Gt=Object.getOwnPropertySymbols;var Kt=Object.prototype.hasOwnProperty,zt=Object.prototype.propertyIsEnumerable;var Wt=(Ie,le,Fe)=>le in Ie?Zt(Ie,le,{enumerable:!0,configurable:!0,writable:!0,value:Fe}):Ie[le]=Fe,kt=(Ie,le)=>{for(var Fe in le||(le={}))Kt.call(le,Fe)&&Wt(Ie,Fe,le[Fe]);if(Gt)for(var Fe of Gt(le))zt.call(le,Fe)&&Wt(Ie,Fe,le[Fe]);return Ie},Et=(Ie,le)=>Ot(Ie,Dt(le));import{m as ut}from"./api.16658261995936.js";import{P as Xt}from"./ProjectEnvSelect.1665826199593.js";import{i as Tt,a as Pt,b as Yt}from"./assert.1665826199593.js";import{f as Jt}from"./format.1665826199593.js";import{a7 as Ut,A as Ft,t as _t,q as Mt,r as Vt,o as Qt,a8 as qt,v as ei,_ as jt,m as ti,d as qe,e as gt,h as tt,l as ii,b as Je,g as Be,w as Ge,F as It,j as bt,k as mt,i as Rt,y as ni,B as At,E as ft}from"./index.1665826199593.js";import"./Api.1665826199593.js";import"./api.16658261995934.js";var Ht={exports:{}};/*!
 * jsoneditor.js
 *
 * @brief
 * JSONEditor is a web-based tool to view, edit, format, and validate JSON.
 * It has various modes such as a tree editor, a code editor, and a plain text
 * editor.
 *
 * Supported browsers: Chrome, Firefox, Safari, Opera, Internet Explorer 8+
 *
 * @license
 * Licensed under the Apache License, Version 2.0 (the "License"); you may not
 * use this file except in compliance with the License. You may obtain a copy
 * of the License at
 *
 * http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
 * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
 * License for the specific language governing permissions and limitations under
 * the License.
 *
 * Copyright (c) 2011-2022 Jos de Jong, http://jsoneditoronline.org
 *
 * @author  Jos de Jong, <wjosdejong@gmail.com>
 * @version 9.9.2
 * @date    2022-09-20
 */(function(Ie,le){(function(Fe,it){Ie.exports=it()})(self,function(){return it={897:function(ie,u,V){V.d(u,{x:function(){return O}});var X=V(2602),k=V(9791),N=V(7907);function Z(W,F){for(var L=0;L<F.length;L++){var C=F[L];C.enumerable=C.enumerable||!1,C.configurable=!0,"value"in C&&(C.writable=!0),Object.defineProperty(W,C.key,C)}}var O=function(){function W(C,x){if(!(this instanceof W))throw new TypeError("Cannot call a class as a function");this.dom={};var b=this,l=this.dom,x=(this.anchor=void 0,this.items=C,this.eventListeners={},this.selection=void 0,this.onClose=x?x.close:void 0,this.limitHeight=!!x&&x.limitHeight,document.createElement("div")),p=(x.className="jsoneditor-contextmenu-root",l.root=x,document.createElement("div")),x=(p.className="jsoneditor-contextmenu",l.menu=p,x.appendChild(p),document.createElement("ul")),p=(x.className="jsoneditor-menu",p.appendChild(x),l.list=x,l.items=[],document.createElement("button")),l=(p.type="button",l.focusButton=p,document.createElement("li"));l.style.overflow="hidden",l.style.height="0",l.appendChild(p),x.appendChild(l),function s(n,t,i){i.forEach(function(e){var r,a,o,c,h,A;e.type==="separator"?((h=document.createElement("div")).className="jsoneditor-separator",(a=document.createElement("li")).appendChild(h),n.appendChild(a)):(r={},h=document.createElement("li"),n.appendChild(h),(a=document.createElement("button")).type="button",a.className=e.className,r.button=a,e.title&&(a.title=e.title),e.click&&(a.onclick=function(v){v.preventDefault(),b.hide(),e.click()}),h.appendChild(a),e.submenu?((c=document.createElement("div")).className="jsoneditor-icon",a.appendChild(c),(c=document.createElement("div")).className="jsoneditor-text"+(e.click?"":" jsoneditor-right-margin"),c.appendChild(document.createTextNode(e.text)),a.appendChild(c),(o=e.click?(a.className+=" jsoneditor-default",(c=document.createElement("button")).type="button",(r.buttonExpand=c).className="jsoneditor-expand",(A=document.createElement("div")).className="jsoneditor-expand",c.appendChild(A),h.appendChild(c),e.submenuTitle&&(c.title=e.submenuTitle),c):((A=document.createElement("div")).className="jsoneditor-expand",a.appendChild(A),a)).onclick=function(v){v.preventDefault(),b._onExpandItem(r),o.focus()},r.subItems=c=[],A=document.createElement("ul"),(r.ul=A).className="jsoneditor-menu",A.style.height="0",h.appendChild(A),s(A,c,e.submenu)):((h=document.createElement("div")).className="jsoneditor-icon",a.appendChild(h),(A=document.createElement("div")).className="jsoneditor-text",A.appendChild(document.createTextNode((0,N.Iu)(e.text))),a.appendChild(A)),t.push(r))})}(x,this.dom.items,C),this.maxHeight=0,C.forEach(function(s){s=24*(C.length+(s.submenu?s.submenu.length:0)),b.maxHeight=Math.max(b.maxHeight,s)})}var F,L;return F=W,(L=[{key:"_getVisibleButtons",value:function(){var C=[],m=this;return this.dom.items.forEach(function(b){C.push(b.button),b.buttonExpand&&C.push(b.buttonExpand),b.subItems&&b===m.expandedItem&&b.subItems.forEach(function(x){C.push(x.button),x.buttonExpand&&C.push(x.buttonExpand)})}),C}},{key:"show",value:function(C,t,b){this.hide();var x=!0,l=C.parentNode,p=C.getBoundingClientRect(),l=l.getBoundingClientRect(),s=t.getBoundingClientRect(),n=this,t=(this.dom.absoluteAnchor=(0,X.w)(C,t,function(){n.hide()}),p.bottom+this.maxHeight<s.bottom||p.top-this.maxHeight>s.top&&(x=!1),b?0:p.top-l.top);x?(b=C.offsetHeight,this.dom.menu.style.left="0",this.dom.menu.style.top=t+b+"px",this.dom.menu.style.bottom=""):(this.dom.menu.style.left="0",this.dom.menu.style.top="",this.dom.menu.style.bottom="0px"),this.limitHeight&&(l=x?s.bottom-p.bottom-10:p.top-s.top-10,this.dom.list.style.maxHeight=l+"px",this.dom.list.style.overflowY="auto"),this.dom.absoluteAnchor.appendChild(this.dom.root),this.selection=(0,k.getSelection)(),this.anchor=C,setTimeout(function(){n.dom.focusButton.focus()},0),W.visibleMenu&&W.visibleMenu.hide(),W.visibleMenu=this}},{key:"hide",value:function(){this.dom.absoluteAnchor&&(this.dom.absoluteAnchor.destroy(),delete this.dom.absoluteAnchor),this.dom.root.parentNode&&(this.dom.root.parentNode.removeChild(this.dom.root),this.onClose&&this.onClose()),W.visibleMenu===this&&(W.visibleMenu=void 0)}},{key:"_onExpandItem",value:function(C){var m,b=this,x=C===this.expandedItem,p=this.expandedItem;p&&(p.ul.style.height="0",p.ul.style.padding="",setTimeout(function(){b.expandedItem!==p&&(p.ul.style.display="",k.removeClassName)(p.ul.parentNode,"jsoneditor-selected")},300),this.expandedItem=void 0),x||((m=C.ul).style.display="block",m.clientHeight,setTimeout(function(){if(b.expandedItem===C){for(var l=0,s=0;s<m.childNodes.length;s++)l+=m.childNodes[s].clientHeight;m.style.height=l+"px",m.style.padding="5px 10px"}},0),(0,k.addClassName)(m.parentNode,"jsoneditor-selected"),this.expandedItem=C)}},{key:"_onKeyDown",value:function(C){var m,b,x,p,l=C.target,s=C.which,n=!1;s===27?(this.selection&&(0,k.setSelection)(this.selection),this.anchor&&this.anchor.focus(),this.hide(),n=!0):s===9?C.shiftKey?(b=(m=this._getVisibleButtons()).indexOf(l))===0&&(m[m.length-1].focus(),n=!0):(b=(m=this._getVisibleButtons()).indexOf(l))===m.length-1&&(m[0].focus(),n=!0):s===37?(l.className==="jsoneditor-expand"&&(b=(m=this._getVisibleButtons()).indexOf(l),(x=m[b-1])&&x.focus()),n=!0):s===38?(b=(m=this._getVisibleButtons()).indexOf(l),(x=(x=(x=m[b-1])&&x.className==="jsoneditor-expand"?m[b-2]:x)||m[m.length-1])&&x.focus(),n=!0):s===39?(b=(m=this._getVisibleButtons()).indexOf(l),(p=m[b+1])&&p.className==="jsoneditor-expand"&&p.focus(),n=!0):s===40&&(b=(m=this._getVisibleButtons()).indexOf(l),(p=(p=(p=m[b+1])&&p.className==="jsoneditor-expand"?m[b+2]:p)||m[0])&&(p.focus(),n=!0),n=!0),n&&(C.stopPropagation(),C.preventDefault())}}])&&Z(F.prototype,L),Object.defineProperty(F,"prototype",{writable:!1}),W}();O.visibleMenu=void 0},6436:function(ie,u,V){function X(N,Z){for(var O=0;O<Z.length;O++){var W=Z[O];W.enumerable=W.enumerable||!1,W.configurable=!0,"value"in W&&(W.writable=!0),Object.defineProperty(N,W.key,W)}}V.d(u,{Q:function(){return k}});var k=function(){function N(F){if(!(this instanceof N))throw new TypeError("Cannot call a class as a function");this.errorTableVisible=F.errorTableVisible,this.onToggleVisibility=F.onToggleVisibility,this.onFocusLine=F.onFocusLine||function(){},this.onChangeHeight=F.onChangeHeight,this.dom={};var F=document.createElement("div"),L=(F.className="jsoneditor-validation-errors-container",this.dom.validationErrorsContainer=F,document.createElement("div")),F=(L.style.display="none",L.className="jsoneditor-additional-errors fadein",L.textContent="Scroll for more \u25BF",this.dom.additionalErrorsIndication=L,F.appendChild(L),document.createElement("span")),L=(F.className="jsoneditor-validation-error-icon",F.style.display="none",this.dom.validationErrorIcon=F,document.createElement("span"));L.className="jsoneditor-validation-error-count",L.style.display="none",this.dom.validationErrorCount=L,this.dom.parseErrorIndication=document.createElement("span"),this.dom.parseErrorIndication.className="jsoneditor-parse-error-icon",this.dom.parseErrorIndication.style.display="none"}var Z,O;return Z=N,(O=[{key:"getErrorTable",value:function(){return this.dom.validationErrorsContainer}},{key:"getErrorCounter",value:function(){return this.dom.validationErrorCount}},{key:"getWarningIcon",value:function(){return this.dom.validationErrorIcon}},{key:"getErrorIcon",value:function(){return this.dom.parseErrorIndication}},{key:"toggleTableVisibility",value:function(){this.errorTableVisible=!this.errorTableVisible,this.onToggleVisibility(this.errorTableVisible)}},{key:"setErrors",value:function(W,F){var L,C,m=this,b=(this.dom.validationErrors&&(this.dom.validationErrors.parentNode.removeChild(this.dom.validationErrors),this.dom.validationErrors=null,this.dom.additionalErrorsIndication.style.display="none"),this.errorTableVisible&&0<W.length?((b=document.createElement("div")).className="jsoneditor-validation-errors",(C=document.createElement("table")).className="jsoneditor-text-errors",b.appendChild(C),L=document.createElement("tbody"),C.appendChild(L),W.forEach(function(x){isNaN(x.line)?x.dataPath&&(l=F.find(function(t){return t.path===x.dataPath}))&&(p=l.line+1):p=x.line;var p,l=document.createElement("tr"),s=(l.className=isNaN(p)?"":"jump-to-line",x.type==="error"?l.className+=" parse-error":l.className+=" validation-error",document.createElement("td")),n=document.createElement("button"),n=(n.className="jsoneditor-schema-error",s.appendChild(n),l.appendChild(s),document.createElement("td"));n.style="white-space: nowrap;",n.textContent=isNaN(p)?"":"Ln "+p,l.appendChild(n),typeof x=="string"?((s=document.createElement("td")).colSpan=2,(n=document.createElement("pre")).appendChild(document.createTextNode(x)),s.appendChild(n),l.appendChild(s)):((n=document.createElement("td")).appendChild(document.createTextNode(x.dataPath||"")),l.appendChild(n),s=document.createElement("td"),(n=document.createElement("pre")).appendChild(document.createTextNode(x.message.replace(/<br>/gi,`
`))),s.appendChild(n),l.appendChild(s)),l.onclick=function(){m.onFocusLine(p)},L.appendChild(l)}),this.dom.validationErrors=b,this.dom.validationErrorsContainer.appendChild(b),this.dom.additionalErrorsIndication.title=W.length+" errors total",this.dom.validationErrorsContainer.clientHeight<this.dom.validationErrorsContainer.scrollHeight?(this.dom.additionalErrorsIndication.style.display="block",this.dom.validationErrorsContainer.onscroll=function(){m.dom.additionalErrorsIndication.style.display=0<m.dom.validationErrorsContainer.clientHeight&&m.dom.validationErrorsContainer.scrollTop===0?"block":"none"}):this.dom.validationErrorsContainer.onscroll=void 0,C=this.dom.validationErrorsContainer.clientHeight+(this.dom.statusBar?this.dom.statusBar.clientHeight:0),this.onChangeHeight(C)):this.onChangeHeight(0),W.filter(function(x){return x.type!=="error"}).length);0<b?(this.dom.validationErrorCount.style.display="inline",this.dom.validationErrorCount.innerText=b,this.dom.validationErrorCount.onclick=this.toggleTableVisibility.bind(this),this.dom.validationErrorIcon.style.display="inline",this.dom.validationErrorIcon.title=b+" schema validation error(s) found",this.dom.validationErrorIcon.onclick=this.toggleTableVisibility.bind(this)):(this.dom.validationErrorCount.style.display="none",this.dom.validationErrorIcon.style.display="none"),W.some(function(x){return x.type==="error"})?(C=W[0].line,this.dom.parseErrorIndication.style.display="block",this.dom.parseErrorIndication.title=isNaN(C)?"parse error - check that the json is valid":"parse error on line "+C,this.dom.parseErrorIndication.onclick=this.toggleTableVisibility.bind(this)):this.dom.parseErrorIndication.style.display="none"}}])&&X(Z.prototype,O),Object.defineProperty(Z,"prototype",{writable:!1}),N}()},2474:function(ie,u,V){function X(N,Z){for(var O=0;O<Z.length;O++){var W=Z[O];W.enumerable=W.enumerable||!1,W.configurable=!0,"value"in W&&(W.writable=!0),Object.defineProperty(N,W.key,W)}}V.d(u,{R:function(){return k}});var k=function(){function N(W){if(!(this instanceof N))throw new TypeError("Cannot call a class as a function");if(this.target=W.target||null,!this.target)throw new Error('FocusTracker constructor called without a "target" to track.');this.onFocus=typeof W.onFocus=="function"?W.onFocus:null,this.onBlur=typeof W.onBlur=="function"?W.onBlur:null,this._onClick=this._onEvent.bind(this),this._onKeyUp=function(F){F.which!==9&&F.keyCode!==9||this._onEvent(F)}.bind(this),this._onBlur=this._onEvent.bind(this),this.focusFlag=!1,this.firstEventFlag=!0,(this.onFocus||this.onBlur)&&(document.addEventListener("click",this._onClick),document.addEventListener("keyup",this._onKeyUp),document.addEventListener("blur",this._onBlur))}var Z,O;return Z=N,(O=[{key:"destroy",value:function(){document.removeEventListener("click",this._onClick),document.removeEventListener("keyup",this._onKeyUp),document.removeEventListener("blur",this._onBlur),this._onEvent({target:document.body})}},{key:"_onEvent",value:function(W){W=W.target,W=W===this.target||!(!this.target.contains(W)&&!this.target.contains(document.activeElement)),W?this.focusFlag||(this.onFocus&&this.onFocus({type:"focus",target:this.target}),this.focusFlag=!0):(this.focusFlag||this.firstEventFlag)&&(this.onBlur&&this.onBlur({type:"blur",target:this.target}),this.focusFlag=!1,this.firstEventFlag&&(this.firstEventFlag=!1))}}])&&X(Z.prototype,O),Object.defineProperty(Z,"prototype",{writable:!1}),N}()},3161:function(ie,u,V){var X=V(8170),k=V(8037),N=V(8038).treeModeMixins,Z=V(8458).textModeMixins,O=V(341).previewModeMixins,b=V(9791),W=b.clear,F=b.extend,L=b.getInnerText,C=b.getInternetExplorerVersion,m=b.parse,b=V(2744).tryRequireAjv,x=V(2558).showTransformModal,p=V(6210).showSortModal,l=b();function s(n,t,i){if(!(this instanceof s))throw new Error('JSONEditor constructor called without "new".');var e=C();if(e!==-1&&e<9)throw new Error("Unsupported browser, IE9 or newer required. Please install the newest version of your browser.");t&&(t.error&&(console.warn('Option "error" has been renamed to "onError"'),t.onError=t.error,delete t.error),t.change&&(console.warn('Option "change" has been renamed to "onChange"'),t.onChange=t.change,delete t.change),t.editable&&(console.warn('Option "editable" has been renamed to "onEditable"'),t.onEditable=t.editable,delete t.editable),t.onChangeJSON&&(t.mode==="text"||t.mode==="code"||t.modes&&(t.modes.indexOf("text")!==-1||t.modes.indexOf("code")!==-1))&&console.warn('Option "onChangeJSON" is not applicable to modes "text" and "code". Use "onChangeText" or "onChange" instead.'),t&&Object.keys(t).forEach(function(r){s.VALID_OPTIONS.indexOf(r)===-1&&console.warn('Unknown option "'+r+'". This option will be ignored')})),arguments.length&&this._create(n,t,i)}typeof Promise=="undefined"&&console.error("Promise undefined. Please load a Promise polyfill in the browser in order to use JSONEditor"),s.modes={},s.prototype.DEBOUNCE_INTERVAL=150,s.VALID_OPTIONS=["ajv","schema","schemaRefs","templates","ace","theme","autocomplete","onChange","onChangeJSON","onChangeText","onExpand","onEditable","onError","onEvent","onModeChange","onNodeName","onValidate","onCreateMenu","onSelectionChange","onTextSelectionChange","onClassName","onFocus","onBlur","colorPicker","onColorPicker","timestampTag","timestampFormat","escapeUnicode","history","search","mode","modes","name","indentation","sortObjectKeys","navigationBar","statusBar","mainMenuBar","languages","language","enableSort","enableTransform","limitDragging","maxVisibleChilds","onValidationError","modalAnchor","popupAnchor","createQuery","executeQuery","queryDescription","allowSchemaSuggestions"],s.prototype._create=function(n,t,i){this.container=n,this.options=t||{},this.json=i||{},n=this.options.mode||this.options.modes&&this.options.modes[0]||"tree",this.setMode(n)},s.prototype.destroy=function(){},s.prototype.set=function(n){this.json=n},s.prototype.get=function(){return this.json},s.prototype.setText=function(n){this.json=m(n)},s.prototype.getText=function(){return JSON.stringify(this.json)},s.prototype.setName=function(n){this.options||(this.options={}),this.options.name=n},s.prototype.getName=function(){return this.options&&this.options.name},s.prototype.setMode=function(n){if(n!==this.options.mode||!this.create){var t=this.container,i=F({},this.options),e=i.mode,r=(i.mode=n,s.modes[n]);if(!r)throw new Error('Unknown mode "'+i.mode+'"');var a=r.data==="text",o=this.getName(),c=this[a?"getText":"get"]();if(this.destroy(),W(this),F(this,r.mixin),this.create(t,i),this.setName(o),this[a?"setText":"set"](c),typeof r.load=="function")try{r.load.call(this)}catch(h){console.error(h)}if(typeof i.onModeChange=="function"&&n!==e)try{i.onModeChange(n,e)}catch(h){console.error(h)}}},s.prototype.getMode=function(){return this.options.mode},s.prototype._onError=function(n){this.options&&typeof this.options.onError=="function"?this.options.onError(n):window.alert(n.toString())},s.prototype.setSchema=function(n,t){if(n){var i;try{this.options.ajv?i=this.options.ajv:((i=l({allErrors:!0,verbose:!0,schemaId:"auto",$data:!0})).addMetaSchema(V(7171)),i.addMetaSchema(V(6273)))}catch{console.warn("Failed to create an instance of Ajv, JSON Schema validation is not available. Please use a JSONEditor bundle including Ajv, or pass an instance of Ajv as via the configuration option `ajv`.")}if(i){if(t){for(var e in t)i.removeSchema(e),t[e]&&i.addSchema(t[e],e);this.options.schemaRefs=t}this.validateSchema=i.compile(n),this.options.schema=n,this.options.schemaRefs=t,this.validate()}}else this.validateSchema=null,this.options.schema=null,this.options.schemaRefs=null,this.validate();this.refresh(),typeof this._onSchemaChange=="function"&&this._onSchemaChange(n,t)},s.prototype.validate=function(){},s.prototype.refresh=function(){},(s.registerMode=function(n){var t;if(Array.isArray(n))for(r=0;r<n.length;r++)s.registerMode(n[r]);else{if(!("mode"in n))throw new Error('Property "mode" missing');if(!("mixin"in n))throw new Error('Property "mixin" missing');if(!("data"in n))throw new Error('Property "data" missing');var i=n.mode;if(i in s.modes)throw new Error('Mode "'+i+'" already registered');if(typeof n.mixin.create!="function")throw new Error('Required function "create" missing on mixin');for(var e=["setMode","registerMode","modes"],r=0;r<e.length;r++)if((t=e[r])in n.mixin)throw new Error('Reserved property "'+t+'" not allowed in mixin');s.modes[i]=n}})(N),s.registerMode(Z),s.registerMode(O),s.ace=X,s.Ajv=l,s.VanillaPicker=k,s.showTransformModal=x,s.showSortModal=p,s.getInnerText=L,ie.exports=s.default=s},6617:function(ie,u,V){V.d(u,{x:function(){return Z}});var X=V(897),k=V(7907);function N(O,W){for(var F=0;F<W.length;F++){var L=W[F];L.enumerable=L.enumerable||!1,L.configurable=!0,"value"in L&&(L.writable=!0),Object.defineProperty(O,L.key,L)}}var Z=function(){function O(L,C,m,b){if(!(this instanceof O))throw new TypeError("Cannot call a class as a function");for(var x={code:{text:(0,k.Iu)("modeCodeText"),title:(0,k.Iu)("modeCodeTitle"),click:function(){b("code")}},form:{text:(0,k.Iu)("modeFormText"),title:(0,k.Iu)("modeFormTitle"),click:function(){b("form")}},text:{text:(0,k.Iu)("modeTextText"),title:(0,k.Iu)("modeTextTitle"),click:function(){b("text")}},tree:{text:(0,k.Iu)("modeTreeText"),title:(0,k.Iu)("modeTreeTitle"),click:function(){b("tree")}},view:{text:(0,k.Iu)("modeViewText"),title:(0,k.Iu)("modeViewTitle"),click:function(){b("view")}},preview:{text:(0,k.Iu)("modePreviewText"),title:(0,k.Iu)("modePreviewTitle"),click:function(){b("preview")}}},p=[],l=0;l<C.length;l++){var s=C[l],n=x[s];if(!n)throw new Error('Unknown mode "'+s+'"');n.className="jsoneditor-type-modes"+(m===s?" jsoneditor-selected":""),p.push(n)}var i=x[m];if(!i)throw new Error('Unknown mode "'+m+'"');var i=i.text,t=document.createElement("button"),i=(t.type="button",t.className="jsoneditor-modes jsoneditor-separator",t.textContent=i+" \u25BE",t.title=(0,k.Iu)("modeEditorTitle"),t.onclick=function(){new X.x(p).show(t,L)},document.createElement("div"));i.className="jsoneditor-modes",i.style.position="relative",i.appendChild(t),L.appendChild(i),this.dom={container:L,box:t,frame:i}}var W,F;return W=O,(F=[{key:"focus",value:function(){this.dom.box.focus()}},{key:"destroy",value:function(){this.dom&&this.dom.frame&&this.dom.frame.parentNode&&this.dom.frame.parentNode.removeChild(this.dom.frame),this.dom=null}}])&&N(W.prototype,F),Object.defineProperty(W,"prototype",{writable:!1}),O}()},8170:function(ie,u,V){var X;if(window.ace)X=window.ace;else try{X=V(6225),V(4091),V(3330),V(4317);var k=V(7923);X.config.setModuleUrl("ace/mode/json_worker",k)}catch{}ie.exports=X},4864:function(){window.ace.define("ace/theme/jsoneditor",["require","exports","module","ace/lib/dom"],function(ie,u,V){u.isDark=!1,u.cssClass="ace-jsoneditor",u.cssText=`.ace-jsoneditor .ace_gutter {
background: #ebebeb;
color: #333
}

.ace-jsoneditor.ace_editor {
line-height: 1.3;
background-color: #fff;
}
.ace-jsoneditor .ace_print-margin {
width: 1px;
background: #e8e8e8
}
.ace-jsoneditor .ace_scroller {
background-color: #FFFFFF
}
.ace-jsoneditor .ace_text-layer {
color: gray
}
.ace-jsoneditor .ace_variable {
color: #1a1a1a
}
.ace-jsoneditor .ace_cursor {
border-left: 2px solid #000000
}
.ace-jsoneditor .ace_overwrite-cursors .ace_cursor {
border-left: 0px;
border-bottom: 1px solid #000000
}
.ace-jsoneditor .ace_marker-layer .ace_selection {
background: lightgray
}
.ace-jsoneditor.ace_multiselect .ace_selection.ace_start {
box-shadow: 0 0 3px 0px #FFFFFF;
border-radius: 2px
}
.ace-jsoneditor .ace_marker-layer .ace_step {
background: rgb(255, 255, 0)
}
.ace-jsoneditor .ace_marker-layer .ace_bracket {
margin: -1px 0 0 -1px;
border: 1px solid #BFBFBF
}
.ace-jsoneditor .ace_marker-layer .ace_active-line {
background: #FFFBD1
}
.ace-jsoneditor .ace_gutter-active-line {
background-color : #dcdcdc
}
.ace-jsoneditor .ace_marker-layer .ace_selected-word {
border: 1px solid lightgray
}
.ace-jsoneditor .ace_invisible {
color: #BFBFBF
}
.ace-jsoneditor .ace_keyword,
.ace-jsoneditor .ace_meta,
.ace-jsoneditor .ace_support.ace_constant.ace_property-value {
color: #AF956F
}
.ace-jsoneditor .ace_keyword.ace_operator {
color: #484848
}
.ace-jsoneditor .ace_keyword.ace_other.ace_unit {
color: #96DC5F
}
.ace-jsoneditor .ace_constant.ace_language {
color: darkorange
}
.ace-jsoneditor .ace_constant.ace_numeric {
color: red
}
.ace-jsoneditor .ace_constant.ace_character.ace_entity {
color: #BF78CC
}
.ace-jsoneditor .ace_invalid {
color: #FFFFFF;
background-color: #FF002A;
}
.ace-jsoneditor .ace_fold {
background-color: #AF956F;
border-color: #000000
}
.ace-jsoneditor .ace_storage,
.ace-jsoneditor .ace_support.ace_class,
.ace-jsoneditor .ace_support.ace_function,
.ace-jsoneditor .ace_support.ace_other,
.ace-jsoneditor .ace_support.ace_type {
color: #C52727
}
.ace-jsoneditor .ace_string {
color: green
}
.ace-jsoneditor .ace_comment {
color: #BCC8BA
}
.ace-jsoneditor .ace_entity.ace_name.ace_tag,
.ace-jsoneditor .ace_entity.ace_other.ace_attribute-name {
color: #606060
}
.ace-jsoneditor .ace_markup.ace_underline {
text-decoration: underline
}
.ace-jsoneditor .ace_indent-guide {
background: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAE0lEQVQImWP4////f4bLly//BwAmVgd1/w11/gAAAABJRU5ErkJggg==") right repeat-y
}`,ie("../lib/dom").importCssString(u.cssText,u.cssClass)})},6589:function(ie,u){(V={trace:function(){},yy:{},symbols_:{error:2,JSONString:3,STRING:4,JSONNumber:5,NUMBER:6,JSONNullLiteral:7,NULL:8,JSONBooleanLiteral:9,TRUE:10,FALSE:11,JSONText:12,JSONValue:13,EOF:14,JSONObject:15,JSONArray:16,"{":17,"}":18,JSONMemberList:19,JSONMember:20,":":21,",":22,"[":23,"]":24,JSONElementList:25,$accept:0,$end:1},terminals_:{2:"error",4:"STRING",6:"NUMBER",8:"NULL",10:"TRUE",11:"FALSE",14:"EOF",17:"{",18:"}",21:":",22:",",23:"[",24:"]"},productions_:[0,[3,1],[5,1],[7,1],[9,1],[9,1],[12,2],[13,1],[13,1],[13,1],[13,1],[13,1],[13,1],[15,2],[15,3],[20,3],[19,1],[19,3],[16,2],[16,3],[25,1],[25,3]],performAction:function(X,k,N,Z,O,W,F){var L=W.length-1;switch(O){case 1:this.$=X.replace(/\\(\\|")/g,"$1").replace(/\\n/g,`
`).replace(/\\r/g,"\r").replace(/\\t/g,"	").replace(/\\v/g,"\v").replace(/\\f/g,"\f").replace(/\\b/g,"\b");break;case 2:this.$=Number(X);break;case 3:this.$=null;break;case 4:this.$=!0;break;case 5:this.$=!1;break;case 6:return this.$=W[L-1];case 13:this.$={};break;case 14:this.$=W[L-1];break;case 15:this.$=[W[L-2],W[L]];break;case 16:this.$={},this.$[W[L][0]]=W[L][1];break;case 17:this.$=W[L-2],W[L-2][W[L][0]]=W[L][1];break;case 18:this.$=[];break;case 19:this.$=W[L-1];break;case 20:this.$=[W[L]];break;case 21:this.$=W[L-2],W[L-2].push(W[L])}},table:[{3:5,4:[1,12],5:6,6:[1,13],7:3,8:[1,9],9:4,10:[1,10],11:[1,11],12:1,13:2,15:7,16:8,17:[1,14],23:[1,15]},{1:[3]},{14:[1,16]},{14:[2,7],18:[2,7],22:[2,7],24:[2,7]},{14:[2,8],18:[2,8],22:[2,8],24:[2,8]},{14:[2,9],18:[2,9],22:[2,9],24:[2,9]},{14:[2,10],18:[2,10],22:[2,10],24:[2,10]},{14:[2,11],18:[2,11],22:[2,11],24:[2,11]},{14:[2,12],18:[2,12],22:[2,12],24:[2,12]},{14:[2,3],18:[2,3],22:[2,3],24:[2,3]},{14:[2,4],18:[2,4],22:[2,4],24:[2,4]},{14:[2,5],18:[2,5],22:[2,5],24:[2,5]},{14:[2,1],18:[2,1],21:[2,1],22:[2,1],24:[2,1]},{14:[2,2],18:[2,2],22:[2,2],24:[2,2]},{3:20,4:[1,12],18:[1,17],19:18,20:19},{3:5,4:[1,12],5:6,6:[1,13],7:3,8:[1,9],9:4,10:[1,10],11:[1,11],13:23,15:7,16:8,17:[1,14],23:[1,15],24:[1,21],25:22},{1:[2,6]},{14:[2,13],18:[2,13],22:[2,13],24:[2,13]},{18:[1,24],22:[1,25]},{18:[2,16],22:[2,16]},{21:[1,26]},{14:[2,18],18:[2,18],22:[2,18],24:[2,18]},{22:[1,28],24:[1,27]},{22:[2,20],24:[2,20]},{14:[2,14],18:[2,14],22:[2,14],24:[2,14]},{3:20,4:[1,12],20:29},{3:5,4:[1,12],5:6,6:[1,13],7:3,8:[1,9],9:4,10:[1,10],11:[1,11],13:30,15:7,16:8,17:[1,14],23:[1,15]},{14:[2,19],18:[2,19],22:[2,19],24:[2,19]},{3:5,4:[1,12],5:6,6:[1,13],7:3,8:[1,9],9:4,10:[1,10],11:[1,11],13:31,15:7,16:8,17:[1,14],23:[1,15]},{18:[2,17],22:[2,17]},{18:[2,15],22:[2,15]},{22:[2,21],24:[2,21]}],defaultActions:{16:[2,6]},parseError:function(X,k){throw new Error(X)},parse:function(X){var k=this,N=[0],Z=[null],O=[],W=this.table,F="",L=0,C=0,m=0,b=(this.lexer.setInput(X),this.lexer.yy=this.yy,this.yy.lexer=this.lexer,this.lexer.yylloc===void 0&&(this.lexer.yylloc={}),this.lexer.yylloc);function x(){var h=k.lexer.lex()||1;return h=typeof h!="number"&&k.symbols_[h]||h}O.push(b),typeof this.yy.parseError=="function"&&(this.parseError=this.yy.parseError);for(var p,l,s,n,t,i,e,r,a,o={};;){if(s=N[N.length-1],(n=this.defaultActions[s]||(p==null&&(p=x()),W[s]&&W[s][p]))===void 0||!n.length||!n[0]){if(!m){for(t in r=[],W[s])this.terminals_[t]&&2<t&&r.push("'"+this.terminals_[t]+"'");var c="",c=this.lexer.showPosition?"Parse error on line "+(L+1)+`:
`+this.lexer.showPosition()+`
Expecting `+r.join(", ")+", got '"+this.terminals_[p]+"'":"Parse error on line "+(L+1)+": Unexpected "+(p==1?"end of input":"'"+(this.terminals_[p]||p)+"'");this.parseError(c,{text:this.lexer.match,token:this.terminals_[p]||p,line:this.lexer.yylineno,loc:b,expected:r})}if(m==3){if(p==1)throw new Error(c||"Parsing halted.");C=this.lexer.yyleng,F=this.lexer.yytext,L=this.lexer.yylineno,b=this.lexer.yylloc,p=x()}for(;!(2 .toString()in W[s]);){if(s==0)throw new Error(c||"Parsing halted.");a=1,N.length=N.length-2*a,Z.length=Z.length-a,O.length=O.length-a,s=N[N.length-1]}l=p,p=2,n=W[s=N[N.length-1]]&&W[s][2],m=3}if(n[0]instanceof Array&&1<n.length)throw new Error("Parse Error: multiple actions possible at state: "+s+", token: "+p);switch(n[0]){case 1:N.push(p),Z.push(this.lexer.yytext),O.push(this.lexer.yylloc),N.push(n[1]),p=null,l?(p=l,l=null):(C=this.lexer.yyleng,F=this.lexer.yytext,L=this.lexer.yylineno,b=this.lexer.yylloc,0<m&&m--);break;case 2:if(i=this.productions_[n[1]][1],o.$=Z[Z.length-i],o._$={first_line:O[O.length-(i||1)].first_line,last_line:O[O.length-1].last_line,first_column:O[O.length-(i||1)].first_column,last_column:O[O.length-1].last_column},(e=this.performAction.call(o,F,C,L,this.yy,n[1],Z,O))!==void 0)return e;i&&(N=N.slice(0,-1*i*2),Z=Z.slice(0,-1*i),O=O.slice(0,-1*i)),N.push(this.productions_[n[1]][0]),Z.push(o.$),O.push(o._$),e=W[N[N.length-2]][N[N.length-1]],N.push(e);break;case 3:return!0}}return!0}}).lexer={EOF:1,parseError:function(X,k){if(!this.yy.parseError)throw new Error(X);this.yy.parseError(X,k)},setInput:function(X){return this._input=X,this._more=this._less=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this},input:function(){var X=this._input[0];return this.yytext+=X,this.yyleng++,this.match+=X,this.matched+=X,X.match(/\n/)&&this.yylineno++,this._input=this._input.slice(1),X},unput:function(X){return this._input=X+this._input,this},more:function(){return this._more=!0,this},less:function(X){this._input=this.match.slice(X)+this._input},pastInput:function(){var X=this.matched.substr(0,this.matched.length-this.match.length);return(20<X.length?"...":"")+X.substr(-20).replace(/\n/g,"")},upcomingInput:function(){var X=this.match;return X.length<20&&(X+=this._input.substr(0,20-X.length)),(X.substr(0,20)+(20<X.length?"...":"")).replace(/\n/g,"")},showPosition:function(){var X=this.pastInput(),k=new Array(X.length+1).join("-");return X+this.upcomingInput()+`
`+k+"^"},next:function(){if(this.done)return this.EOF;this._input||(this.done=!0),this._more||(this.yytext="",this.match="");for(var X,k,N,Z,O=this._currentRules(),W=0;W<O.length&&(!(k=this._input.match(this.rules[O[W]]))||X&&!(k[0].length>X[0].length)||(X=k,N=W,this.options.flex));W++);return X?((Z=X[0].match(/\n.*/g))&&(this.yylineno+=Z.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:Z?Z[Z.length-1].length-1:this.yylloc.last_column+X[0].length},this.yytext+=X[0],this.match+=X[0],this.yyleng=this.yytext.length,this._more=!1,this._input=this._input.slice(X[0].length),this.matched+=X[0],Z=this.performAction.call(this,this.yy,this,O[N],this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),Z||void 0):this._input===""?this.EOF:void this.parseError("Lexical error on line "+(this.yylineno+1)+`. Unrecognized text.
`+this.showPosition(),{text:"",token:null,line:this.yylineno})},lex:function(){var X=this.next();return X!==void 0?X:this.lex()},begin:function(X){this.conditionStack.push(X)},popState:function(){return this.conditionStack.pop()},_currentRules:function(){return this.conditions[this.conditionStack[this.conditionStack.length-1]].rules},topState:function(){return this.conditionStack[this.conditionStack.length-2]},pushState:function(X){this.begin(X)},options:{},performAction:function(X,k,N,Z){switch(N){case 0:break;case 1:return 6;case 2:return k.yytext=k.yytext.substr(1,k.yyleng-2),4;case 3:return 17;case 4:return 18;case 5:return 23;case 6:return 24;case 7:return 22;case 8:return 21;case 9:return 10;case 10:return 11;case 11:return 8;case 12:return 14;case 13:return"INVALID"}},rules:[/^(?:\s+)/,/^(?:(-?([0-9]|[1-9][0-9]+))(\.[0-9]+)?([eE][-+]?[0-9]+)?\b)/,/^(?:"(?:\\[\\"bfnrt/]|\\u[a-fA-F0-9]{4}|[^\\\0-\x09\x0a-\x1f"])*")/,/^(?:\{)/,/^(?:\})/,/^(?:\[)/,/^(?:\])/,/^(?:,)/,/^(?::)/,/^(?:true\b)/,/^(?:false\b)/,/^(?:null\b)/,/^(?:$)/,/^(?:.)/],conditions:{INITIAL:{rules:[0,1,2,3,4,5,6,7,8,9,10,11,12,13],inclusive:!0}}};var V;u.parser=V,u.parse=V.parse.bind(V)},3879:function(ie){function u(){}u.prototype={on:function(L,C){this._events=this._events||{},this._events[L]=this._events[L]||[],this._events[L].push(C)},off:function(L,C){this._events=this._events||{},L in this._events&&this._events[L].splice(this._events[L].indexOf(C),1)},emit:function(L){if(this._events=this._events||{},L in this._events)for(var C=0;C<this._events[L].length;C++)this._events[L][C].apply(this,Array.prototype.slice.call(arguments,1))}},u.mixin=function(L){for(var C=["on","off","emit"],m=0;m<C.length;m++)typeof L=="function"?L.prototype[C[m]]=u.prototype[C[m]]:L[C[m]]=u.prototype[C[m]];return L};var V={escapeRegExp:function(L){var C=/[\\^$.*+?()[\]{}|]/g,m=new RegExp(C.source);return L&&m.test(L)?L.replace(C,"\\$&"):L},extend:function(L,C){for(var m in C){var b;C.hasOwnProperty(m)&&((b=C[m])&&Object.prototype.toString.call(b)==="[object Object]"?(L[m]=L[m]||{},V.extend(L[m],b)):L[m]=b)}return L},each:function(L,C,m){if(Object.prototype.toString.call(L)==="[object Object]")for(var b in L)Object.prototype.hasOwnProperty.call(L,b)&&C.call(m,b,L[b],L);else for(var x=0,p=L.length;x<p;x++)C.call(m,x,L[x],L)},createElement:function(L,C){var m,b=document.createElement(L);if(C&&Object.prototype.toString.call(C)==="[object Object]")for(m in C)m in b?b[m]=C[m]:m==="html"?b.innerHTML=C[m]:b.setAttribute(m,C[m]);return b},hasClass:function(L,C){if(L)return L.classList?L.classList.contains(C):!!L.className&&!!L.className.match(new RegExp("(\\s|^)"+C+"(\\s|$)"))},addClass:function(L,C){V.hasClass(L,C)||(L.classList?L.classList.add(C):L.className=L.className.trim()+" "+C)},removeClass:function(L,C){V.hasClass(L,C)&&(L.classList?L.classList.remove(C):L.className=L.className.replace(new RegExp("(^|\\s)"+C.split(" ").join("|")+"(\\s|$)","gi")," "))},closest:function(L,C){return L&&L!==document.body&&(C(L)?L:V.closest(L.parentNode,C))},isInt:function(L){return typeof L=="number"&&isFinite(L)&&Math.floor(L)===L},debounce:function(L,C,m){var b;return function(){var x=this,p=arguments,l=m&&!b;clearTimeout(b),b=setTimeout(function(){b=null,m||L.apply(x,p)},C),l&&L.apply(x,p)}},rect:function(b,p){var m=window,b=b.getBoundingClientRect(),x=p?m.pageXOffset:0,p=p?m.pageYOffset:0;return{bottom:b.bottom+p,height:b.height,left:b.left+x,right:b.right+x,top:b.top+p,width:b.width}},includes:function(L,C){return-1<L.indexOf(C)},startsWith:function(L,C){return L.substr(0,C.length)===C},truncate:function(L){for(;L.firstChild;)L.removeChild(L.firstChild)}};function X(L,C){return L.hasOwnProperty(C)&&(L[C]===!0||L[C].length)}function k(L,C,m){L.parentNode?L.parentNode.parentNode||C.appendChild(L.parentNode):C.appendChild(L),V.removeClass(L,"excluded"),m||(L.textContent=L.textContent)}function N(){var L,C;this.items.length&&(L=document.createDocumentFragment(),this.config.pagination?(C=this.pages.slice(0,this.pageIndex),V.each(C,function(m,b){V.each(b,function(x,p){k(p,L,this.customOption)},this)},this)):V.each(this.items,function(m,b){k(b,L,this.customOption)},this),L.childElementCount&&(V.removeClass(this.items[this.navIndex],"active"),this.navIndex=(L.querySelector(".selectr-option.selected")||L.querySelector(".selectr-option")).idx,V.addClass(this.items[this.navIndex],"active")),this.tree.appendChild(L))}function Z(L,C){C=C||L;var m={class:"selectr-option",role:"treeitem","aria-selected":!1};return this.customOption?m.html=this.config.renderOption(C):m.textContent=L.textContent,(C=V.createElement("li",m)).idx=L.idx,this.items.push(C),L.defaultSelected&&this.defaultSelected.push(L.idx),L.disabled&&(C.disabled=!0,V.addClass(C,"disabled")),C}function O(){var L,C=this.tree,m=C.scrollTop;C.scrollHeight-C.offsetHeight<=m&&this.pageIndex<this.pages.length&&(L=document.createDocumentFragment(),V.each(this.pages[this.pageIndex],function(b,x){k(x,L,this.customOption)},this),C.appendChild(L),this.pageIndex++,this.emit("selectr.paginate",{items:this.items.length,total:this.data.length,page:this.pageIndex,pages:this.pages.length}))}function W(){(this.config.searchable||this.config.taggable)&&(this.input.value=null,this.searching=!1,this.config.searchable&&V.removeClass(this.inputContainer,"active"),V.hasClass(this.container,"notice")&&(V.removeClass(this.container,"notice"),V.addClass(this.container,"open"),this.input.focus()),V.each(this.items,function(L,C){V.removeClass(C,"excluded"),this.customOption||(C.textContent=C.textContent)},this))}function F(L,C){if(!L)throw new Error("You must supply either a HTMLSelectElement or a CSS3 selector string.");if(typeof(this.el=L)=="string"&&(this.el=document.querySelector(L)),this.el===null)throw new Error("The element you passed to Selectr can not be found.");if(this.el.nodeName.toLowerCase()!=="select")throw new Error("The element you passed to Selectr is not a HTMLSelectElement.");this.render(C)}F.prototype.render=function(L){var C;this.rendered||((this.el.selectr=this).config=V.extend({defaultSelected:!0,width:"auto",disabled:!1,disabledMobile:!1,searchable:!0,clearable:!1,sortSelected:!1,allowDeselect:!1,closeOnScroll:!1,nativeDropdown:!1,nativeKeyboard:!1,placeholder:"Select an option...",taggable:!1,tagPlaceholder:"Enter a tag...",messages:{noResults:"No results.",noOptions:"No options available.",maxSelections:"A maximum of {max} items can be selected.",tagDuplicate:"That tag is already in use.",searchPlaceholder:"Search options..."}},L),this.originalType=this.el.type,this.originalIndex=this.el.tabIndex,this.defaultSelected=[],this.originalOptionCount=this.el.options.length,(this.config.multiple||this.config.taggable)&&(this.el.multiple=!0),this.disabled=X(this.config,"disabled"),this.opened=!1,this.config.taggable&&(this.config.searchable=!1),this.navigating=!1,this.mobileDevice=!1,!this.config.disabledMobile&&/Android|webOS|iPhone|iPad|BlackBerry|Windows Phone|Opera Mini|IEMobile|Mobile/i.test(navigator.userAgent)&&(this.mobileDevice=!0),this.customOption=this.config.hasOwnProperty("renderOption")&&typeof this.config.renderOption=="function",this.customSelected=this.config.hasOwnProperty("renderSelection")&&typeof this.config.renderSelection=="function",this.supportsEventPassiveOption=this.detectEventPassiveOption(),u.mixin(this),function(){this.requiresPagination=this.config.pagination&&0<this.config.pagination,X(this.config,"width")&&(V.isInt(this.config.width)?this.width=this.config.width+"px":this.config.width==="auto"?this.width="100%":V.includes(this.config.width,"%")&&(this.width=this.config.width)),this.container=V.createElement("div",{class:"selectr-container"}),this.config.customClass&&V.addClass(this.container,this.config.customClass),this.mobileDevice?V.addClass(this.container,"selectr-mobile"):V.addClass(this.container,"selectr-desktop"),this.el.tabIndex=-1,this.config.nativeDropdown||this.mobileDevice?V.addClass(this.el,"selectr-visible"):V.addClass(this.el,"selectr-hidden"),this.selected=V.createElement("div",{class:"selectr-selected",disabled:this.disabled,tabIndex:0,"aria-expanded":!1}),this.label=V.createElement(this.el.multiple?"ul":"span",{class:"selectr-label"});var m=V.createElement("div",{class:"selectr-options-container"});if(this.tree=V.createElement("ul",{class:"selectr-options",role:"tree","aria-hidden":!0,"aria-expanded":!1}),this.notice=V.createElement("div",{class:"selectr-notice"}),this.el.setAttribute("aria-hidden",!0),this.disabled&&(this.el.disabled=!0),this.el.multiple?(V.addClass(this.label,"selectr-tags"),V.addClass(this.container,"multiple"),this.tags=[],this.selectedValues=this.config.defaultSelected?this.getSelectedProperties("value"):[],this.selectedIndexes=this.getSelectedProperties("idx")):(this.selectedValue=null,this.selectedIndex=-1),this.selected.appendChild(this.label),this.config.clearable&&(this.selectClear=V.createElement("button",{class:"selectr-clear",type:"button"}),this.container.appendChild(this.selectClear),V.addClass(this.container,"clearable")),this.config.taggable){var b=V.createElement("li",{class:"input-tag"});if(this.input=V.createElement("input",{class:"selectr-tag-input",placeholder:this.config.tagPlaceholder,tagIndex:0,autocomplete:"off",autocorrect:"off",autocapitalize:"off",spellcheck:"false",role:"textbox",type:"search"}),b.appendChild(this.input),this.label.appendChild(b),V.addClass(this.container,"taggable"),this.tagSeperators=[","],this.config.tagSeperators){this.tagSeperators=this.tagSeperators.concat(this.config.tagSeperators);for(var x=[],p=0;p<this.tagSeperators.length;p++)x.push(V.escapeRegExp(this.tagSeperators[p]));this.tagSeperatorsRegex=new RegExp(x.join("|"),"i")}else this.tagSeperatorsRegex=new RegExp(",","i")}this.config.searchable&&(this.input=V.createElement("input",{class:"selectr-input",tagIndex:-1,autocomplete:"off",autocorrect:"off",autocapitalize:"off",spellcheck:"false",role:"textbox",type:"search",placeholder:this.config.messages.searchPlaceholder}),this.inputClear=V.createElement("button",{class:"selectr-input-clear",type:"button"}),this.inputContainer=V.createElement("div",{class:"selectr-input-container"}),this.inputContainer.appendChild(this.input),this.inputContainer.appendChild(this.inputClear),m.appendChild(this.inputContainer)),m.appendChild(this.notice),m.appendChild(this.tree),this.items=[],this.options=[],this.el.options.length&&(this.options=[].slice.call(this.el.options));var l,s,n,t=!1,i=0;this.el.children.length&&V.each(this.el.children,function(r,a){a.nodeName==="OPTGROUP"?(t=V.createElement("ul",{class:"selectr-optgroup",role:"group",html:"<li class='selectr-optgroup--label'>"+a.label+"</li>"}),V.each(a.children,function(o,c){c.idx=i,t.appendChild(Z.call(this,c,t)),i++},this)):(a.idx=i,Z.call(this,a),i++)},this),this.config.data&&Array.isArray(this.config.data)&&(l=!(this.data=[]),t=!1,i=0,V.each(this.config.data,function(r,a){X(a,"children")?(l=V.createElement("optgroup",{label:a.text}),t=V.createElement("ul",{class:"selectr-optgroup",role:"group",html:"<li class='selectr-optgroup--label'>"+a.text+"</li>"}),V.each(a.children,function(o,c){(s=new Option(c.text,c.value,!1,c.hasOwnProperty("selected")&&c.selected===!0)).disabled=X(c,"disabled"),this.options.push(s),l.appendChild(s),s.idx=i,t.appendChild(Z.call(this,s,c)),this.data[i]=c,i++},this),this.el.appendChild(l)):((s=new Option(a.text,a.value,!1,a.hasOwnProperty("selected")&&a.selected===!0)).disabled=X(a,"disabled"),this.options.push(s),s.idx=i,Z.call(this,s,a),this.data[i]=a,i++)},this)),this.setSelected(!0);for(var e=this.navIndex=0;e<this.items.length;e++)if(n=this.items[e],!V.hasClass(n,"disabled")){V.addClass(n,"active"),this.navIndex=e;break}this.requiresPagination&&(this.pageIndex=1,this.paginate()),this.container.appendChild(this.selected),this.container.appendChild(m),this.placeEl=V.createElement("div",{class:"selectr-placeholder"}),this.setPlaceholder(),this.selected.appendChild(this.placeEl),this.disabled&&this.disable(),this.el.parentNode.insertBefore(this.container,this.el),this.container.appendChild(this.el)}.call(this),this.bindEvents(),this.update(),this.optsRect=V.rect(this.tree),this.rendered=!0,this.el.multiple||(this.el.selectedIndex=this.selectedIndex),C=this,setTimeout(function(){C.emit("selectr.init")},20))},F.prototype.getSelected=function(){return this.el.querySelectorAll("option:checked")},F.prototype.getSelectedProperties=function(L){var C=this.getSelected();return[].slice.call(C).map(function(m){return m[L]}).filter(function(m){return m!=null})},F.prototype.detectEventPassiveOption=function(){var L=!1;try{var C=Object.defineProperty({},"passive",{get:function(){L=!0}});window.addEventListener("test",null,C)}catch{}return L},F.prototype.bindEvents=function(){var L,C=this;this.events={},this.events.dismiss=function(m){m=m.target,this.container.contains(m)||!this.opened&&!V.hasClass(this.container,"notice")||this.close()}.bind(this),this.events.navigate=function(m){if(m=m||window.event,this.items.length&&this.opened&&V.includes([13,38,40],m.which)){if(m.preventDefault(),m.which===13)return!(this.noResults||this.config.taggable&&0<this.input.value.length)&&this.change(this.navIndex);var b,x=this.items[this.navIndex],p=this.navIndex;switch(m.which){case 38:(b=0)<this.navIndex&&this.navIndex--;break;case 40:this.navIndex<this.items.length-(b=1)&&this.navIndex++}for(this.navigating=!0;V.hasClass(this.items[this.navIndex],"disabled")||V.hasClass(this.items[this.navIndex],"excluded");){if(!(0<this.navIndex&&this.navIndex<this.items.length-1)){this.navIndex=p;break}if(b?this.navIndex++:this.navIndex--,this.searching){if(this.navIndex>this.tree.lastElementChild.idx){this.navIndex=this.tree.lastElementChild.idx;break}if(this.navIndex<this.tree.firstElementChild.idx){this.navIndex=this.tree.firstElementChild.idx;break}}}m=V.rect(this.items[this.navIndex]),b?(this.navIndex===0?this.tree.scrollTop=0:m.top+m.height>this.optsRect.top+this.optsRect.height&&(this.tree.scrollTop=this.tree.scrollTop+(m.top+m.height-(this.optsRect.top+this.optsRect.height))),this.navIndex===this.tree.childElementCount-1&&this.requiresPagination&&O.call(this)):this.navIndex===0?this.tree.scrollTop=0:m.top-this.optsRect.top<0&&(this.tree.scrollTop=this.tree.scrollTop+(m.top-this.optsRect.top)),x&&V.removeClass(x,"active"),V.addClass(this.items[this.navIndex],"active")}else this.navigating=!1}.bind(this),this.events.reset=this.reset.bind(this),(this.config.nativeDropdown||this.mobileDevice)&&(this.container.addEventListener("touchstart",function(m){m.changedTouches[0].target===C.el&&C.toggle()},!!this.supportsEventPassiveOption&&{passive:!0}),this.container.addEventListener("click",function(m){m.target===C.el&&C.toggle()}),this.el.addEventListener("change",function(m){m.__selfTriggered||(C.el.multiple?(m=C.getSelectedProperties("idx"),m=function(b,x){for(var p,l=[],s=b.slice(0),n=0;n<x.length;n++)-1<(p=s.indexOf(x[n]))?s.splice(p,1):l.push(x[n]);return[l,s]}(C.selectedIndexes,m),V.each(m[0],function(b,x){C.select(x)},C),V.each(m[1],function(b,x){C.deselect(x)},C)):-1<C.el.selectedIndex&&C.select(C.el.selectedIndex))})),this.config.nativeDropdown&&this.container.addEventListener("keydown",function(m){m.key==="Enter"&&C.selected===document.activeElement&&(C.toggle(),setTimeout(function(){C.el.focus()},200))}),this.selected.addEventListener("click",function(m){C.disabled||C.toggle(),m.preventDefault()}),this.config.nativeKeyboard&&(L="",this.selected.addEventListener("keydown",function(m){var b;C.disabled||C.selected!==document.activeElement||m.altKey||m.ctrlKey||m.metaKey||(m.key===" "||!C.opened&&-1<["Enter","ArrowUp","ArrowDown"].indexOf(m.key)?(C.toggle(),m.preventDefault(),m.stopPropagation()):m.key.length<=2&&String[String.fromCodePoint?"fromCodePoint":"fromCharCode"](m.key[String.codePointAt?"codePointAt":"charCodeAt"](0))===m.key&&(C.config.multiple?(C.open(),C.config.searchable&&(C.input.value=m.key,C.input.focus(),C.search(null,!0))):(L+=m.key,(b=C.search(L,!0))&&b.length&&(C.clear(),C.setValue(b[0].value)),setTimeout(function(){L=""},1e3)),m.preventDefault(),m.stopPropagation()))}),this.container.addEventListener("keyup",function(m){C.opened&&m.key==="Escape"&&(C.close(),m.stopPropagation(),C.selected.focus())})),this.label.addEventListener("click",function(m){V.hasClass(m.target,"selectr-tag-remove")&&C.deselect(m.target.parentNode.idx)}),this.selectClear&&this.selectClear.addEventListener("click",this.clear.bind(this)),this.tree.addEventListener("mousedown",function(m){m.preventDefault()}),this.tree.addEventListener("click",function(m){var b=V.closest(m.target,function(x){return x&&V.hasClass(x,"selectr-option")});b&&!V.hasClass(b,"disabled")&&(V.hasClass(b,"selected")?(C.el.multiple||!C.el.multiple&&C.config.allowDeselect)&&C.deselect(b.idx):C.select(b.idx),C.opened&&!C.el.multiple&&C.close()),m.preventDefault(),m.stopPropagation()}),this.tree.addEventListener("mouseover",function(m){!V.hasClass(m.target,"selectr-option")||V.hasClass(m.target,"disabled")||(V.removeClass(C.items[C.navIndex],"active"),V.addClass(m.target,"active"),C.navIndex=[].slice.call(C.items).indexOf(m.target))}),this.config.searchable&&(this.input.addEventListener("focus",function(m){C.searching=!0}),this.input.addEventListener("blur",function(m){C.searching=!1}),this.input.addEventListener("keyup",function(m){C.search(),C.config.taggable||(this.value.length?V.addClass(this.parentNode,"active"):V.removeClass(this.parentNode,"active"))}),this.inputClear.addEventListener("click",function(m){C.input.value=null,W.call(C),C.tree.childElementCount||N.call(C)})),this.config.taggable&&this.input.addEventListener("keyup",function(m){var b,x;C.search(),C.config.taggable&&this.value.length&&(b=this.value.trim()).length&&(m.which===13||C.tagSeperatorsRegex.test(b))&&(m=b.replace(C.tagSeperatorsRegex,""),(x=(m=(m=V.escapeRegExp(m)).trim()).length?C.add({value:m,textContent:m,selected:!0},!0):x)?(C.close(),W.call(C)):(this.value="",C.setMessage(C.config.messages.tagDuplicate)))}),this.update=V.debounce(function(){C.opened&&C.config.closeOnScroll&&C.close(),C.width&&(C.container.style.width=C.width),C.invert()},50),this.requiresPagination&&(this.paginateItems=V.debounce(function(){O.call(this)},50),this.tree.addEventListener("scroll",this.paginateItems.bind(this))),document.addEventListener("click",this.events.dismiss),window.addEventListener("keydown",this.events.navigate),window.addEventListener("resize",this.update),window.addEventListener("scroll",this.update),this.on("selectr.destroy",function(){document.removeEventListener("click",this.events.dismiss),window.removeEventListener("keydown",this.events.navigate),window.removeEventListener("resize",this.update),window.removeEventListener("scroll",this.update)}),this.el.form&&(this.el.form.addEventListener("reset",this.events.reset),this.on("selectr.destroy",function(){this.el.form.removeEventListener("reset",this.events.reset)}))},F.prototype.setSelected=function(L){var C;this.config.data||this.el.multiple||!this.el.options.length||(this.el.selectedIndex!==0||this.el.options[0].defaultSelected||this.config.defaultSelected||(this.el.selectedIndex=-1),this.selectedIndex=this.el.selectedIndex,-1<this.selectedIndex&&this.select(this.selectedIndex)),this.config.multiple&&this.originalType==="select-one"&&!this.config.data&&this.el.options[0].selected&&!this.el.options[0].defaultSelected&&(this.el.options[0].selected=!1),V.each(this.options,function(m,b){b.selected&&b.defaultSelected&&this.select(b.idx)},this),this.config.selectedValue&&this.setValue(this.config.selectedValue),this.config.data&&(!this.el.multiple&&this.config.defaultSelected&&this.el.selectedIndex<0&&0<this.config.data.length&&this.select(0),C=0,V.each(this.config.data,function(m,b){X(b,"children")?V.each(b.children,function(x,p){p.hasOwnProperty("selected")&&p.selected===!0&&this.select(C),C++},this):(b.hasOwnProperty("selected")&&b.selected===!0&&this.select(C),C++)},this))},F.prototype.destroy=function(){this.rendered&&(this.emit("selectr.destroy"),this.originalType==="select-one"&&(this.el.multiple=!1),this.config.data&&(this.el.innerHTML=""),V.removeClass(this.el,"selectr-hidden"),this.container.parentNode.replaceChild(this.el,this.container),this.rendered=!1,delete this.el.selectr)},F.prototype.change=function(L){var C=this.items[L],m=this.options[L];m.disabled||(m.selected&&V.hasClass(C,"selected")?this.deselect(L):this.select(L),this.opened&&!this.el.multiple&&this.close())},F.prototype.select=function(L){var C=this.items[L],m=[].slice.call(this.el.options),b=this.options[L];if(this.el.multiple){if(V.includes(this.selectedIndexes,L))return!1;if(this.config.maxSelections&&this.tags.length===this.config.maxSelections)return this.setMessage(this.config.messages.maxSelections.replace("{max}",this.config.maxSelections),!0),!1;this.selectedValues.push(b.value),this.selectedIndexes.push(L),function(p){var l,s=this,n=document.createDocumentFragment(),t=this.options[p.idx],i=this.data?this.data[p.idx]:t,e={class:"selectr-tag"},i=(this.customSelected?e.html=this.config.renderSelection(i):e.textContent=t.textContent,V.createElement("li",e)),e=V.createElement("button",{class:"selectr-tag-remove",type:"button"});i.appendChild(e),i.idx=p.idx,i.tag=t.value,this.tags.push(i),this.config.sortSelected?(e=this.tags.slice(),l=function(r,a){r.replace(/(\d+)|(\D+)/g,function(o,c,h){a.push([c||1/0,h||""])})},e.sort(function(r,a){var o,c,h=[],A=[];for(s.config.sortSelected===!0?(o=r.tag,c=a.tag):s.config.sortSelected==="text"&&(o=r.textContent,c=a.textContent),l(o,h),l(c,A);h.length&&A.length;){var d=h.shift(),v=A.shift(),d=d[0]-v[0]||d[1].localeCompare(v[1]);if(d)return d}return h.length-A.length}),V.each(e,function(r,a){n.appendChild(a)}),this.label.innerHTML=""):n.appendChild(i),this.config.taggable?this.label.insertBefore(n,this.input.parentNode):this.label.appendChild(n)}.call(this,C)}else{var x=this.data?this.data[L]:b;this.customSelected?this.label.innerHTML=this.config.renderSelection(x):this.label.textContent=b.textContent,this.selectedValue=b.value,this.selectedIndex=L,V.each(this.options,function(p,l){var s=this.items[p];p!==L&&(s&&V.removeClass(s,"selected"),l.selected=!1,l.removeAttribute("selected"))},this)}V.includes(m,b)||this.el.add(b),C.setAttribute("aria-selected",!0),V.addClass(C,"selected"),V.addClass(this.container,"has-selected"),b.selected=!0,b.setAttribute("selected",""),this.emit("selectr.change",b),this.emit("selectr.select",b),"createEvent"in document?((x=document.createEvent("HTMLEvents")).initEvent("change",!0,!0),x.__selfTriggered=!0,this.el.dispatchEvent(x)):this.el.fireEvent("onchange")},F.prototype.deselect=function(L,C){var m=this.items[L],b=this.options[L];if(this.el.multiple){var x=this.selectedIndexes.indexOf(L),x=(this.selectedIndexes.splice(x,1),this.selectedValues.indexOf(b.value));this.selectedValues.splice(x,1),function(p){var l=!1;V.each(this.tags,function(s,n){n.idx===p.idx&&(l=n)},this),l&&(this.label.removeChild(l),this.tags.splice(this.tags.indexOf(l),1))}.call(this,m),this.tags.length||V.removeClass(this.container,"has-selected")}else{if(!C&&!this.config.clearable&&!this.config.allowDeselect)return!1;this.label.innerHTML="",this.selectedValue=null,this.el.selectedIndex=this.selectedIndex=-1,V.removeClass(this.container,"has-selected")}this.items[L].setAttribute("aria-selected",!1),V.removeClass(this.items[L],"selected"),b.selected=!1,b.removeAttribute("selected"),this.emit("selectr.change",null),this.emit("selectr.deselect",b),"createEvent"in document?((x=document.createEvent("HTMLEvents")).initEvent("change",!0,!0),x.__selfTriggered=!0,this.el.dispatchEvent(x)):this.el.fireEvent("onchange")},F.prototype.setValue=function(L){var C=Array.isArray(L);if(C||(L=L.toString().trim()),!this.el.multiple&&C)return!1;V.each(this.options,function(m,b){(C&&-1<L.indexOf(b.value)||b.value===L)&&this.change(b.idx)},this)},F.prototype.getValue=function(L,C){var m,b;return this.el.multiple?L?this.selectedIndexes.length&&(b={values:[]},V.each(this.selectedIndexes,function(x,p){p=this.options[p],b.values[x]={value:p.value,text:p.textContent}},this)):b=this.selectedValues.slice():b=L?{value:(m=this.options[this.selectedIndex]).value,text:m.textContent}:this.selectedValue,b=L&&C?JSON.stringify(b):b},F.prototype.add=function(L,C){if(L){if(this.data=this.data||[],this.items=this.items||[],this.options=this.options||[],Array.isArray(L))V.each(L,function(x,p){this.add(p,C)},this);else if(Object.prototype.toString.call(L)==="[object Object]"){if(C){var m=!1;if(V.each(this.options,function(x,p){p.value.toLowerCase()===L.value.toLowerCase()&&(m=!0)}),m)return!1}var b=V.createElement("option",L);return this.data.push(L),this.mobileDevice&&this.el.add(b),this.options.push(b),b.idx=0<this.options.length?this.options.length-1:0,Z.call(this,b),L.selected&&this.select(b.idx),this.setPlaceholder(),b}return this.config.pagination&&this.paginate(),!0}},F.prototype.remove=function(L){var C,m=[];Array.isArray(L)?V.each(L,function(b,x){V.isInt(x)?m.push(this.getOptionByIndex(x)):typeof x=="string"&&m.push(this.getOptionByValue(x))},this):V.isInt(L)?m.push(this.getOptionByIndex(L)):typeof L=="string"&&m.push(this.getOptionByValue(L)),m.length&&(V.each(m,function(b,x){C=x.idx,this.el.remove(x),this.options.splice(C,1),x=this.items[C].parentNode,x&&x.removeChild(this.items[C]),this.items.splice(C,1),V.each(this.options,function(p,l){l.idx=p,this.items[p].idx=p},this)},this),this.setPlaceholder(),this.config.pagination&&this.paginate())},F.prototype.removeAll=function(){this.clear(!0),V.each(this.el.options,function(L,C){this.el.remove(C)},this),V.truncate(this.tree),this.items=[],this.options=[],this.data=[],this.navIndex=0,this.requiresPagination&&(this.requiresPagination=!1,this.pageIndex=1,this.pages=[]),this.setPlaceholder()},F.prototype.search=function(L,C){var m,b,x,p,l;if(!this.navigating)return m=!1,L||(L=this.input.value,m=!0,this.removeMessage(),V.truncate(this.tree)),b=[],x=document.createDocumentFragment(),0<(L=L.trim().toLowerCase()).length?(p=C?V.startsWith:V.includes,V.each(this.options,function(s,n){var t,i,e,r,a=this.items[n.idx];p(n.textContent.trim().toLowerCase(),L)&&!n.disabled?(b.push({text:n.textContent,value:n.value}),m&&(k(a,x,this.customOption),V.removeClass(a,"excluded"),this.customOption||(t=L,e=(n=n).textContent,t=new RegExp(t,"ig"),(r=t.exec(e))&&(n.innerHTML="",(i=document.createElement("span")).classList.add("selectr-match"),i.textContent=r[0],n.appendChild(document.createTextNode(e.substring(0,r.index))),n.appendChild(i),n.appendChild(document.createTextNode(e.substring(t.lastIndex))))))):m&&V.addClass(a,"excluded")},this),m&&(x.childElementCount?(C=this.items[this.navIndex],l=x.querySelector(".selectr-option:not(.excluded)"),this.noResults=!1,V.removeClass(C,"active"),this.navIndex=l.idx,V.addClass(l,"active")):this.config.taggable||(this.noResults=!0,this.setMessage(this.config.messages.noResults)),this.tree.appendChild(x))):N.call(this),b},F.prototype.toggle=function(){this.disabled||(this.opened?this.close():this.open())},F.prototype.open=function(){var L=this;if(!this.options.length)return!1;this.opened||this.emit("selectr.open"),this.opened=!0,this.mobileDevice||this.config.nativeDropdown?(V.addClass(this.container,"native-open"),this.config.data&&V.each(this.options,function(C,m){this.el.add(m)},this)):(V.addClass(this.container,"open"),N.call(this),this.invert(),this.tree.scrollTop=0,V.removeClass(this.container,"notice"),this.selected.setAttribute("aria-expanded",!0),this.tree.setAttribute("aria-hidden",!1),this.tree.setAttribute("aria-expanded",!0),this.config.searchable&&!this.config.taggable&&setTimeout(function(){L.input.focus(),L.input.tabIndex=0},10))},F.prototype.close=function(){var L;this.opened&&this.emit("selectr.close"),this.opened=!1,this.navigating=!1,this.mobileDevice||this.config.nativeDropdown?V.removeClass(this.container,"native-open"):(L=V.hasClass(this.container,"notice"),this.config.searchable&&!L&&(this.input.blur(),this.input.tabIndex=-1,this.searching=!1),L&&(V.removeClass(this.container,"notice"),this.notice.textContent=""),V.removeClass(this.container,"open"),V.removeClass(this.container,"native-open"),this.selected.setAttribute("aria-expanded",!1),this.tree.setAttribute("aria-hidden",!0),this.tree.setAttribute("aria-expanded",!1),V.truncate(this.tree),W.call(this))},F.prototype.enable=function(){this.disabled=!1,this.el.disabled=!1,this.selected.tabIndex=this.originalIndex,this.el.multiple&&V.each(this.tags,function(L,C){C.lastElementChild.tabIndex=0}),V.removeClass(this.container,"selectr-disabled")},F.prototype.disable=function(L){L||(this.el.disabled=!0),this.selected.tabIndex=-1,this.el.multiple&&V.each(this.tags,function(C,m){m.lastElementChild.tabIndex=-1}),this.disabled=!0,V.addClass(this.container,"selectr-disabled")},F.prototype.reset=function(){this.disabled||(this.clear(),this.setSelected(!0),V.each(this.defaultSelected,function(L,C){this.select(C)},this),this.emit("selectr.reset"))},F.prototype.clear=function(L,C){var m;this.el.multiple?this.selectedIndexes.length&&(m=this.selectedIndexes.slice(),C?this.deselect(m.slice(-1)[0]):V.each(m,function(b,x){this.deselect(x)},this)):-1<this.selectedIndex&&this.deselect(this.selectedIndex,L),this.emit("selectr.clear")},F.prototype.serialise=function(L){var C=[];return V.each(this.options,function(m,b){var x={value:b.value,text:b.textContent};b.selected&&(x.selected=!0),b.disabled&&(x.disabled=!0),C[m]=x}),L?JSON.stringify(C):C},F.prototype.serialize=function(L){return this.serialise(L)},F.prototype.setPlaceholder=function(L){L=L||this.config.placeholder||this.el.getAttribute("placeholder"),this.options.length||(L=this.config.messages.noOptions),this.placeEl.innerHTML=L},F.prototype.paginate=function(){var L;if(this.items.length)return(L=this).pages=this.items.map(function(C,m){return m%L.config.pagination==0?L.items.slice(m,m+L.config.pagination):null}).filter(function(C){return C}),this.pages},F.prototype.setMessage=function(L,C){C&&this.close(),V.addClass(this.container,"notice"),this.notice.textContent=L},F.prototype.removeMessage=function(){V.removeClass(this.container,"notice"),this.notice.innerHTML=""},F.prototype.invert=function(){var L=V.rect(this.selected),C=this.tree.parentNode.offsetHeight,m=window.innerHeight;L.top+L.height+C>m?(V.addClass(this.container,"inverted"),this.isInverted=!0):(V.removeClass(this.container,"inverted"),this.isInverted=!1),this.optsRect=V.rect(this.tree)},F.prototype.getOptionByIndex=function(L){return this.options[L]},F.prototype.getOptionByValue=function(L){for(var C=!1,m=0,b=this.options.length;m<b;m++)if(this.options[m].value.trim()===L.toString().trim()){C=this.options[m];break}return C},ie.exports=F},4188:function(ie,u,V){V.d(u,{EX:function(){return k},WF:function(){return N},oW:function(){return Z},qD:function(){return X}});var X=document.body,k=10485760,N=2e4,Z=2147483648},2602:function(ie,u,V){V.d(u,{w:function(){return k}});var X=V(9791);function k(N,Z,O){var W,F=3<arguments.length&&arguments[3]!==void 0&&arguments[3],L=typeof(m=N).getRootNode=="function"?m.getRootNode():window,C={},m=N.getBoundingClientRect(),b=Z.getBoundingClientRect(),x=document.createElement("div");function p(){if(x&&x.parentNode){for(var s in x.parentNode.removeChild(x),C)n=s,Object.prototype.hasOwnProperty.call(C,n)&&((n=C[s])&&(0,X.removeEventListener)(L,s,n),delete C[s]);typeof O=="function"&&O(N)}var n}function l(s){(s=s.target)===x||(0,X.isChildOf)(s,x)||p()}return x.className="jsoneditor-anchor",x.style.position="absolute",x.style.left=m.left-b.left+"px",x.style.top=m.top-b.top+"px",x.style.width=m.width-2+"px",x.style.height=m.height-2+"px",x.style.boxSizing="border-box",Z.appendChild(x),C.mousedown=(0,X.addEventListener)(L,"mousedown",l),C.mousewheel=(0,X.addEventListener)(L,"mousewheel",l),F&&(W=null,x.onmouseover=function(){clearTimeout(W),W=null},x.onmouseout=function(){W=W||setTimeout(p,200)}),x.destroy=p,x}},7923:function(ie){ie.exports="data:application/javascript;base64,[encoded data, 68432 characters]"},7907:function(ie,u,V){V.d(u,{Iu:function(){return L},cC:function(){return F},m0:function(){return W}}),V(4987);var X={en:{array:"Array",auto:"Auto",appendText:"Append",appendTitle:"Append a new field with type 'auto' after this field (Ctrl+Shift+Ins)",appendSubmenuTitle:"Select the type of the field to be appended",appendTitleAuto:"Append a new field with type 'auto' (Ctrl+Shift+Ins)",ascending:"Ascending",ascendingTitle:"Sort the childs of this ${type} in ascending order",actionsMenu:"Click to open the actions menu (Ctrl+M)",cannotParseFieldError:"Cannot parse field into JSON",cannotParseValueError:"Cannot parse value into JSON",collapseAll:"Collapse all fields",compactTitle:"Compact JSON data, remove all whitespaces (Ctrl+Shift+I)",descending:"Descending",descendingTitle:"Sort the childs of this ${type} in descending order",drag:"Drag to move this field (Alt+Shift+Arrows)",duplicateKey:"duplicate key",duplicateText:"Duplicate",duplicateTitle:"Duplicate selected fields (Ctrl+D)",duplicateField:"Duplicate this field (Ctrl+D)",duplicateFieldError:"Duplicate field name",empty:"empty",expandAll:"Expand all fields",expandTitle:`Click to expand/collapse this field (Ctrl+E). 
Ctrl+Click to expand/collapse including all childs.`,formatTitle:"Format JSON data, with proper indentation and line feeds (Ctrl+I)",insert:"Insert",insertTitle:"Insert a new field with type 'auto' before this field (Ctrl+Ins)",insertSub:"Select the type of the field to be inserted",object:"Object",ok:"Ok",redo:"Redo (Ctrl+Shift+Z)",removeText:"Remove",removeTitle:"Remove selected fields (Ctrl+Del)",removeField:"Remove this field (Ctrl+Del)",repairTitle:"Repair JSON: fix quotes and escape characters, remove comments and JSONP notation, turn JavaScript objects into JSON.",searchTitle:"Search fields and values",searchNextResultTitle:"Next result (Enter)",searchPreviousResultTitle:"Previous result (Shift + Enter)",selectNode:"Select a node...",showAll:"show all",showMore:"show more",showMoreStatus:"displaying ${visibleChilds} of ${totalChilds} items.",sort:"Sort",sortTitle:"Sort the childs of this ${type}",sortTitleShort:"Sort contents",sortFieldLabel:"Field:",sortDirectionLabel:"Direction:",sortFieldTitle:"Select the nested field by which to sort the array or object",sortAscending:"Ascending",sortAscendingTitle:"Sort the selected field in ascending order",sortDescending:"Descending",sortDescendingTitle:"Sort the selected field in descending order",string:"String",transform:"Transform",transformTitle:"Filter, sort, or transform the childs of this ${type}",transformTitleShort:"Filter, sort, or transform contents",extract:"Extract",extractTitle:"Extract this ${type}",transformQueryTitle:"Enter a JMESPath query",transformWizardLabel:"Wizard",transformWizardFilter:"Filter",transformWizardSortBy:"Sort by",transformWizardSelectFields:"Select fields",transformQueryLabel:"Query",transformPreviewLabel:"Preview",type:"Type",typeTitle:"Change the type of this field",openUrl:"Ctrl+Click or Ctrl+Enter to open url in new window",undo:"Undo last action (Ctrl+Z)",validationCannotMove:"Cannot move a field into a child of itself",autoType:'Field type "auto". The field type is automatically determined from the value and can be a string, number, boolean, or null.',objectType:'Field type "object". An object contains an unordered set of key/value pairs.',arrayType:'Field type "array". An array contains an ordered collection of values.',stringType:'Field type "string". Field type is not determined from the value, but always returned as string.',modeEditorTitle:"Switch Editor Mode",modeCodeText:"Code",modeCodeTitle:"Switch to code highlighter",modeFormText:"Form",modeFormTitle:"Switch to form editor",modeTextText:"Text",modeTextTitle:"Switch to plain text editor",modeTreeText:"Tree",modeTreeTitle:"Switch to tree editor",modeViewText:"View",modeViewTitle:"Switch to tree view",modePreviewText:"Preview",modePreviewTitle:"Switch to preview mode",examples:"Examples",default:"Default",containsInvalidProperties:"Contains invalid properties",containsInvalidItems:"Contains invalid items"},es:{array:"Matriz",auto:"Auto",appendText:"Agregar",appendTitle:"Agregue un nuevo campo con el tipo 'auto' despu\xE9s de este campo (Ctrl + Shift + Ins)",appendSubmenuTitle:"Seleccione el tipo de campo que se agregar\xE1",appendTitleAuto:"Agregue un nuevo campo con el tipo 'auto' (Ctrl + Shift + Ins)",ascending:"Ascendente",ascendingTitle:"Ordene los elementos secundarios de este ${type} en orden ascendente",actionsMenu:"Haga clic para abrir el men\xFA de acciones (Ctrl + M)",cannotParseFieldError:"No se puede parsear el campo en JSON",cannotParseValueError:"No se puede parsear el valor en JSON",collapseAll:"Contraer todos los campos",compactTitle:"Compactar datos JSON, eliminar todos los espacios en blanco (Ctrl + Shift + I)",descending:"Descendente",descendingTitle:"Ordene los hijos de este ${type} en orden descendente",drag:"Arrastre para mover este campo (Alt + May\xFAs + Flechas)",duplicateKey:"llave duplicada",duplicateText:"Duplicar",duplicateTitle:"Duplicar campos seleccionados (Ctrl + D)",duplicateField:"Duplicar este campo (Ctrl + D)",duplicateFieldError:"Nombre de campo duplicado",empty:"vacio",expandAll:"Expandir todos los campos",expandTitle:`Haga clic para expandir/contraer este campo (Ctrl + E). 
  Ctrl+Clic para expandir/contraer incluyendo todos los ni\xF1os.`,formatTitle:"Formatee los datos JSON, con la sangr\xEDa y los avances de l\xEDnea adecuados (Ctrl + I)",insert:"Insertar",insertTitle:"Inserte un nuevo campo con el tipo 'auto' antes de este campo (Ctrl + Ins)",insertSub:"Seleccione el tipo de campo a insertar",object:"Objeto",ok:"Ok",redo:"Rehacer (Ctrl+May\xFAs+Z)",removeText:"Eliminar",removeTitle:"Eliminar campos seleccionados (Ctrl+Supr)",removeField:"Eliminar este campo (Ctrl+Supr)",repairTitle:"Reparar JSON: corrija comillas y caracteres de escape, elimine comentarios y notaci\xF3n JSONP, convierta objetos JavaScript en JSON.",searchTitle:"Campos de b\xFAsqueda y valores",searchNextResultTitle:"Siguiente resultado (Entrar)",searchPreviousResultTitle:"Resultado anterior (Shift + Enter)",selectNode:"Seleccione un nodo...",showAll:"mostrar todo",showMore:"mostrar m\xE1s",showMoreStatus:"mostrando ${visibleChilds} de ${totalChilds} elementos.",sort:"Ordenar",sortTitle:"Ordene los hijos de este ${type}",sortTitleShort:"Ordenar contenidos",sortFieldLabel:"Campo:",sortDirectionLabel:"Direcci\xF3n:",sortFieldTitle:"Seleccione el campo anidado por el cual ordenar la matriz u objeto",sortAscending:"Ascendente",sortAscendingTitle:"Ordenar el campo seleccionado en orden ascendente",sortDescending:"Descendente",sortDescendingTitle:"Ordenar por el campo seleccionado, en orden descendente",string:"Texto",transform:"Transformar",transformTitle:"Filtrar, ordenar o transformar los hijos de este ${type}",transformTitleShort:"Filtrar, ordenar o transformar contenidos",extract:"Extraer",extractTitle:"Extrae este ${type}",transformQueryTitle:"Ingrese una consulta JMESPath",transformWizardLabel:"Wizard",transformWizardFilter:"Filtro",transformWizardSortBy:"Ordenar por",transformWizardSelectFields:"Seleccione un campo",transformQueryLabel:"Consulta",transformPreviewLabel:"Vista Previa",type:"Tipo",typeTitle:"Cambiar el tipo de campo",openUrl:"Ctrl+Click o Ctrl+Enter para abrir la URL en una nueva ventana",undo:"Deshacer la \xFAltima acci\xF3n (Ctrl+Z)",validationCannotMove:"No se puede mover un campo a un hijo de s\xED mismo.",autoType:'Field type "auto". The field type is automatically determined from the value and can be a string, number, boolean, or null.',objectType:'Tipo de campo "objeto".  Un objeto contiene un conjunto desordenado de pares clave/valor.',arrayType:'Tipo de campo "matriz".  Una matriz contiene una colecci\xF3n ordenada de valores.',stringType:'Tipo de campo "cadena".  El tipo de campo no se determina a partir del valor,  pero siempre se devuelve como una cadena.',modeEditorTitle:"Cambiar modo de editor",modeCodeText:"Codigo",modeCodeTitle:"Cambiar al resaltador de c\xF3digo",modeFormText:"Formulario",modeFormTitle:"Cambiar al editor de formularios",modeTextText:"Texto",modeTextTitle:"Cambiar al editor de texto sin formato",modeTreeText:"Arbol",modeTreeTitle:"Cambiar al editor de \xE1rbol",modeViewText:"Vista",modeViewTitle:"Cambiar a la vista de \xE1rbol",modePreviewText:"Vista Previa",modePreviewTitle:"Cambiar al modo de vista previa",examples:"Ejemplos",default:"Predeterminado",containsInvalidProperties:"Contiene propiedades no validas",containsInvalidItems:"Contiene items no validos"},"zh-CN":{array:"\u6570\u7EC4",auto:"\u81EA\u52A8",appendText:"\u8FFD\u52A0",appendTitle:"\u5728\u6B64\u5B57\u6BB5\u540E\u8FFD\u52A0\u4E00\u4E2A\u7C7B\u578B\u4E3A\u201Cauto\u201D\u7684\u65B0\u5B57\u6BB5 (Ctrl+Shift+Ins)",appendSubmenuTitle:"\u9009\u62E9\u8981\u8FFD\u52A0\u7684\u5B57\u6BB5\u7C7B\u578B",appendTitleAuto:"\u8FFD\u52A0\u7C7B\u578B\u4E3A\u201Cauto\u201D\u7684\u65B0\u5B57\u6BB5 (Ctrl+Shift+Ins)",ascending:"\u5347\u5E8F",ascendingTitle:"\u5347\u5E8F\u6392\u5217${type}\u7684\u5B50\u8282\u70B9",actionsMenu:"\u70B9\u51FB\u6253\u5F00\u52A8\u4F5C\u83DC\u5355(Ctrl+M)",cannotParseFieldError:"\u65E0\u6CD5\u5C06\u5B57\u6BB5\u89E3\u6790\u4E3AJSON",cannotParseValueError:"\u65E0\u6CD5\u5C06\u503C\u89E3\u6790\u4E3AJSON",collapseAll:"\u7F29\u8FDB\u6240\u6709\u5B57\u6BB5",compactTitle:"\u538B\u7F29JSON\u6570\u636E\uFF0C\u5220\u9664\u6240\u6709\u7A7A\u683C (Ctrl+Shift+I)",descending:"\u964D\u5E8F",descendingTitle:"\u964D\u5E8F\u6392\u5217${type}\u7684\u5B50\u8282\u70B9",drag:"\u62D6\u62FD\u79FB\u52A8\u8BE5\u8282\u70B9(Alt+Shift+Arrows)",duplicateKey:"\u91CD\u590D\u952E",duplicateText:"\u590D\u5236",duplicateTitle:"\u590D\u5236\u9009\u4E2D\u5B57\u6BB5(Ctrl+D)",duplicateField:"\u590D\u5236\u8BE5\u5B57\u6BB5(Ctrl+D)",duplicateFieldError:"\u91CD\u590D\u7684\u5B57\u6BB5\u540D\u79F0",empty:"\u6E05\u7A7A",expandAll:"\u5C55\u5F00\u6240\u6709\u5B57\u6BB5",expandTitle:`\u70B9\u51FB \u5C55\u5F00/\u6536\u7F29 \u8BE5\u5B57\u6BB5(Ctrl+E). 
Ctrl+Click \u5C55\u5F00/\u6536\u7F29 \u5305\u542B\u6240\u6709\u5B50\u8282\u70B9.`,formatTitle:"\u4F7F\u7528\u9002\u5F53\u7684\u7F29\u8FDB\u548C\u6362\u884C\u7B26\u683C\u5F0F\u5316JSON\u6570\u636E (Ctrl+I)",insert:"\u63D2\u5165",insertTitle:"\u5728\u6B64\u5B57\u6BB5\u524D\u63D2\u5165\u7C7B\u578B\u4E3A\u201Cauto\u201D\u7684\u65B0\u5B57\u6BB5 (Ctrl+Ins)",insertSub:"\u9009\u62E9\u8981\u63D2\u5165\u7684\u5B57\u6BB5\u7C7B\u578B",object:"\u5BF9\u8C61",ok:"Ok",redo:"\u91CD\u505A (Ctrl+Shift+Z)",removeText:"\u79FB\u9664",removeTitle:"\u79FB\u9664\u9009\u4E2D\u5B57\u6BB5 (Ctrl+Del)",removeField:"\u79FB\u9664\u8BE5\u5B57\u6BB5 (Ctrl+Del)",repairTitle:"\u4FEE\u590DJSON\uFF1A\u4FEE\u590D\u5F15\u53F7\u548C\u8F6C\u4E49\u7B26\uFF0C\u5220\u9664\u6CE8\u91CA\u548CJSONP\u8868\u793A\u6CD5\uFF0C\u5C06JavaScript\u5BF9\u8C61\u8F6C\u6362\u4E3AJSON\u3002",selectNode:"\u9009\u62E9\u4E00\u4E2A\u8282\u70B9...",showAll:"\u5C55\u793A\u5168\u90E8",showMore:"\u5C55\u793A\u66F4\u591A",showMoreStatus:"\u663E\u793A${totalChilds}\u7684${visibleChilds}\u9879\u76EE.",sort:"\u6392\u5E8F",sortTitle:"\u6392\u5E8F${type}\u7684\u5B50\u8282\u70B9",sortTitleShort:"\u5185\u5BB9\u6392\u5E8F",sortFieldLabel:"\u5B57\u6BB5\uFF1A",sortDirectionLabel:"\u65B9\u5411\uFF1A",sortFieldTitle:"\u9009\u62E9\u7528\u4E8E\u5BF9\u6570\u7EC4\u6216\u5BF9\u8C61\u6392\u5E8F\u7684\u5D4C\u5957\u5B57\u6BB5",sortAscending:"\u5347\u5E8F\u6392\u5E8F",sortAscendingTitle:"\u6309\u7167\u8BE5\u5B57\u6BB5\u5347\u5E8F\u6392\u5E8F",sortDescending:"\u964D\u5E8F\u6392\u5E8F",sortDescendingTitle:"\u6309\u7167\u8BE5\u5B57\u6BB5\u964D\u5E8F\u6392\u5E8F",string:"\u5B57\u7B26\u4E32",transform:"\u53D8\u6362",transformTitle:"\u7B5B\u9009\uFF0C\u6392\u5E8F\uFF0C\u6216\u8005\u8F6C\u6362${type}\u7684\u5B50\u8282\u70B9",transformTitleShort:"\u7B5B\u9009\uFF0C\u6392\u5E8F\uFF0C\u6216\u8005\u8F6C\u6362\u5185\u5BB9",extract:"\u63D0\u53D6",extractTitle:"\u63D0\u53D6\u8FD9\u4E2A ${type}",transformQueryTitle:"\u8F93\u5165JMESPath\u67E5\u8BE2",transformWizardLabel:"\u5411\u5BFC",transformWizardFilter:"\u7B5B\u9009",transformWizardSortBy:"\u6392\u5E8F",transformWizardSelectFields:"\u9009\u62E9\u5B57\u6BB5",transformQueryLabel:"\u67E5\u8BE2",transformPreviewLabel:"\u9884\u89C8",type:"\u7C7B\u578B",typeTitle:"\u66F4\u6539\u5B57\u6BB5\u7C7B\u578B",openUrl:"Ctrl+Click \u6216\u8005 Ctrl+Enter \u5728\u65B0\u7A97\u53E3\u6253\u5F00\u94FE\u63A5",undo:"\u64A4\u9500\u4E0A\u6B21\u52A8\u4F5C (Ctrl+Z)",validationCannotMove:"\u65E0\u6CD5\u5C06\u5B57\u6BB5\u79FB\u5165\u5176\u5B50\u8282\u70B9",autoType:'\u5B57\u6BB5\u7C7B\u578B "auto". \u5B57\u6BB5\u7C7B\u578B\u7531\u503C\u81EA\u52A8\u786E\u5B9A \u53EF\u4EE5\u4E3A string\uFF0Cnumber\uFF0Cboolean\uFF0C\u6216\u8005 null.',objectType:'\u5B57\u6BB5\u7C7B\u578B "object". \u5BF9\u8C61\u5305\u542B\u4E00\u7EC4\u65E0\u5E8F\u7684\u952E/\u503C\u5BF9.',arrayType:'\u5B57\u6BB5\u7C7B\u578B "array". \u6570\u7EC4\u5305\u542B\u503C\u7684\u6709\u5E8F\u96C6\u5408.',stringType:'\u5B57\u6BB5\u7C7B\u578B "string". \u5B57\u6BB5\u7C7B\u578B\u7531\u503C\u81EA\u52A8\u786E\u5B9A\uFF0C\u4F46\u59CB\u7EC8\u4F5C\u4E3A\u5B57\u7B26\u4E32\u8FD4\u56DE.',modeCodeText:"\u4EE3\u7801",modeCodeTitle:"\u5207\u6362\u81F3\u4EE3\u7801\u9AD8\u4EAE",modeFormText:"\u8868\u5355",modeFormTitle:"\u5207\u6362\u81F3\u8868\u5355\u7F16\u8F91",modeTextText:"\u6587\u672C",modeTextTitle:"\u5207\u6362\u81F3\u6587\u672C\u7F16\u8F91",modeTreeText:"\u6811",modeTreeTitle:"\u5207\u6362\u81F3\u6811\u7F16\u8F91",modeViewText:"\u89C6\u56FE",modeViewTitle:"\u5207\u6362\u81F3\u6811\u89C6\u56FE",modePreviewText:"\u9884\u89C8",modePreviewTitle:"\u5207\u6362\u81F3\u9884\u89C8\u6A21\u5F0F",examples:"\u4F8B\u5B50",default:"\u7F3A\u7701",containsInvalidProperties:"\u5305\u542B\u65E0\u6548\u7684\u5C5E\u6027",containsInvalidItems:"\u5305\u542B\u65E0\u6548\u9879\u76EE"},"pt-BR":{array:"Lista",auto:"Automatico",appendText:"Adicionar",appendTitle:"Adicionar novo campo com tipo 'auto' depois deste campo (Ctrl+Shift+Ins)",appendSubmenuTitle:"Selecione o tipo do campo a ser adicionado",appendTitleAuto:"Adicionar novo campo com tipo 'auto' (Ctrl+Shift+Ins)",ascending:"Ascendente",ascendingTitle:"Organizar filhor do tipo ${type} em crescente",actionsMenu:"Clique para abrir o menu de a\xE7\xF5es (Ctrl+M)",cannotParseFieldError:"N\xE3o \xE9 poss\xEDvel analisar o campo no JSON",cannotParseValueError:"N\xE3o \xE9 poss\xEDvel analisar o valor em JSON",collapseAll:"Fechar todos campos",compactTitle:"Dados JSON compactos, remova todos os espa\xE7os em branco (Ctrl+Shift+I)",descending:"Descendente",descendingTitle:"Organizar o filhos do tipo ${type} em decrescente",duplicateKey:"chave duplicada",drag:"Arraste para mover este campo (Alt+Shift+Arrows)",duplicateText:"Duplicar",duplicateTitle:"Duplicar campos selecionados (Ctrl+D)",duplicateField:"Duplicar este campo (Ctrl+D)",duplicateFieldError:"Nome do campo duplicado",empty:"vazio",expandAll:"Expandir todos campos",expandTitle:`Clique para expandir/encolher este campo (Ctrl+E). 
Ctrl+Click para expandir/encolher incluindo todos os filhos.`,formatTitle:"Formate dados JSON, com recuo e feeds de linha adequados (Ctrl+I)",insert:"Inserir",insertTitle:"Inserir um novo campo do tipo 'auto' antes deste campo (Ctrl+Ins)",insertSub:"Selecionar o tipo de campo a ser inserido",object:"Objeto",ok:"Ok",redo:"Refazer (Ctrl+Shift+Z)",removeText:"Remover",removeTitle:"Remover campos selecionados (Ctrl+Del)",removeField:"Remover este campo (Ctrl+Del)",repairTitle:"Repare JSON: corrija aspas e caracteres de escape, remova coment\xE1rios e nota\xE7\xE3o JSONP, transforme objetos JavaScript em JSON.",selectNode:"Selecione um n\xF3dulo...",showAll:"mostrar todos",showMore:"mostrar mais",showMoreStatus:"exibindo ${visibleChilds} de ${totalChilds} itens.",sort:"Organizar",sortTitle:"Organizar os filhos deste ${type}",sortTitleShort:"Organizar os filhos",sortFieldLabel:"Campo:",sortDirectionLabel:"Dire\xE7\xE3o:",sortFieldTitle:"Selecione um campo filho pelo qual ordenar o array ou objeto",sortAscending:"Ascendente",sortAscendingTitle:"Ordenar o campo selecionado por ordem ascendente",sortDescending:"Descendente",sortDescendingTitle:"Ordenar o campo selecionado por ordem descendente",string:"Texto",transform:"Transformar",transformTitle:"Filtrar, ordenar ou transformar os filhos deste ${type}",transformTitleShort:"Filtrar, ordenar ou transformar conte\xFAdos",transformQueryTitle:"Insira uma express\xE3o JMESPath",transformWizardLabel:"Assistente",transformWizardFilter:"Filtro",transformWizardSortBy:"Ordenar por",transformWizardSelectFields:"Selecionar campos",transformQueryLabel:"Express\xE3o",transformPreviewLabel:"Visualizar",type:"Tipo",typeTitle:"Mudar o tipo deste campo",openUrl:"Ctrl+Click ou Ctrl+Enter para abrir link em nova janela",undo:"Desfazer \xFAltimo a\xE7\xE3o (Ctrl+Z)",validationCannotMove:"N\xE3o pode mover um campo como filho dele mesmo",autoType:'Campo do tipo "auto". O tipo do campo \xE9 determinao automaticamente a partir do seu valor e pode ser texto, n\xFAmero, verdade/falso ou nulo.',objectType:'Campo do tipo "objeto". Um objeto cont\xE9m uma lista de pares com chave e valor.',arrayType:'Campo do tipo "lista". Uma lista contem uma cole\xE7\xE3o de valores ordenados.',stringType:'Campo do tipo "string". Campo do tipo nao \xE9 determinado atrav\xE9s do seu valor, mas sempre retornara um texto.',examples:"Exemplos",default:"Revelia",containsInvalidProperties:"Cont\xE9m propriedades inv\xE1lidas",containsInvalidItems:"Cont\xE9m itens inv\xE1lidos"},tr:{array:"Dizin",auto:"Otomatik",appendText:"Ekle",appendTitle:"Bu alan\u0131n alt\u0131na 'otomatik' tipinde yeni bir alan ekle (Ctrl+Shift+Ins)",appendSubmenuTitle:"Eklenecek alan\u0131n tipini se\xE7",appendTitleAuto:"'Otomatik' tipinde yeni bir alan ekle (Ctrl+Shift+Ins)",ascending:"Artan",ascendingTitle:"${type}'\u0131n alt tiplerini artan d\xFCzende s\u0131rala",actionsMenu:"Aksiyon men\xFCs\xFCn\xFC a\xE7mak i\xE7in t\u0131klay\u0131n (Ctrl+M)",collapseAll:"T\xFCm alanlar\u0131 kapat",descending:"Azalan",descendingTitle:"${type}'\u0131n alt tiplerini azalan d\xFCzende s\u0131rala",drag:"Bu alan\u0131 ta\u015F\u0131mak i\xE7in s\xFCr\xFCkleyin (Alt+Shift+Arrows)",duplicateKey:"Var olan anahtar",duplicateText:"A\u015Fa\u011F\u0131ya kopyala",duplicateTitle:"Se\xE7ili alanlardan bir daha olu\u015Ftur (Ctrl+D)",duplicateField:"Bu alandan bir daha olu\u015Ftur (Ctrl+D)",duplicateFieldError:"Duplicate field name",cannotParseFieldError:"Alan JSON'a ayr\u0131\u015Ft\u0131r\u0131lam\u0131yor",cannotParseValueError:"JSON'a de\u011Fer ayr\u0131\u015Ft\u0131r\u0131lam\u0131yor",empty:"bo\u015F",expandAll:"T\xFCm alanlar\u0131 a\xE7",expandTitle:`Bu alan\u0131 a\xE7mak/kapatmak i\xE7in t\u0131kla (Ctrl+E). 
Alt alanlarda dahil t\xFCm alanlar\u0131 a\xE7mak i\xE7in Ctrl+Click `,insert:"Ekle",insertTitle:"Bu alan\u0131n \xFCst\xFCne 'otomatik' tipinde yeni bir alan ekle (Ctrl+Ins)",insertSub:"Araya eklenecek alan\u0131n tipini se\xE7",object:"Nesne",ok:"Tamam",redo:"Yeniden yap (Ctrl+Shift+Z)",removeText:"Kald\u0131r",removeTitle:"Se\xE7ilen alanlar\u0131 kald\u0131r (Ctrl+Del)",removeField:"Bu alan\u0131 kald\u0131r (Ctrl+Del)",selectNode:"Bir nesne se\xE7...",showAll:"t\xFCm\xFCn\xFC g\xF6ster",showMore:"daha fazla g\xF6ster",showMoreStatus:"${totalChilds} alan\u0131n ${visibleChilds} alt alanlar\u0131 g\xF6steriliyor",sort:"S\u0131rala",sortTitle:"${type}'\u0131n alt alanlar\u0131n\u0131 s\u0131rala",sortTitleShort:"\u0130\xE7erikleri s\u0131rala",sortFieldLabel:"Alan:",sortDirectionLabel:"Y\xF6n:",sortFieldTitle:"Diziyi veya nesneyi s\u0131ralamak i\xE7in i\xE7 i\xE7e ge\xE7mi\u015F alan\u0131 se\xE7in",sortAscending:"Artan",sortAscendingTitle:"Se\xE7ili alan\u0131 artan d\xFCzende s\u0131rala",sortDescending:"Azalan",sortDescendingTitle:"Se\xE7ili alan\u0131 azalan d\xFCzende s\u0131rala",string:"Karakter Dizisi",transform:"D\xF6n\xFC\u015Ft\xFCr",transformTitle:"${type}'\u0131n alt alanlar\u0131n\u0131 filtrele, s\u0131rala veya d\xF6n\xFC\u015Ft\xFCr",transformTitleShort:"\u0130\xE7erikleri filterele, s\u0131rala veya d\xF6n\xFC\u015Ft\xFCr",transformQueryTitle:"JMESPath sorgusu gir",transformWizardLabel:"Sihirbaz",transformWizardFilter:"Filtre",transformWizardSortBy:"S\u0131rala",transformWizardSelectFields:"Alanlar\u0131 se\xE7",transformQueryLabel:"Sorgu",transformPreviewLabel:"\xD6nizleme",type:"Tip",typeTitle:"Bu alan\u0131n tipini de\u011Fi\u015Ftir",openUrl:"URL'i yeni bir pencerede a\xE7mak i\xE7in Ctrl+Click veya Ctrl+Enter",undo:"Son de\u011Fi\u015Fikli\u011Fi geri al (Ctrl+Z)",validationCannotMove:"Alt alan olarak ta\u015F\u0131nam\u0131yor",autoType:'Alan tipi "otomatik". Alan t\xFCr\xFC otomatik olarak de\u011Ferden belirlenirve bir dize, say\u0131, boolean veya null olabilir.',objectType:'Alan tipi "nesne". Bir nesne, s\u0131ralanmam\u0131\u015F bir anahtar / de\u011Fer \xE7ifti k\xFCmesi i\xE7erir.',arrayType:'Alan tipi "dizi". Bir dizi, d\xFCzenli de\u011Ferler koleksiyonu i\xE7erir.',stringType:'Alan tipi "karakter dizisi". Alan t\xFCr\xFC de\u011Ferden belirlenmez,ancak her zaman karakter dizisi olarak d\xF6nd\xFCr\xFCl\xFCr.',modeCodeText:"Kod",modeCodeTitle:"Kod vurgulay\u0131c\u0131ya ge\xE7",modeFormText:"Form",modeFormTitle:"Form d\xFCzenleyiciye ge\xE7",modeTextText:"Metin",modeTextTitle:"D\xFCz metin d\xFCzenleyiciye ge\xE7",modeTreeText:"A\u011Fa\xE7",modeTreeTitle:"A\u011Fa\xE7 d\xFCzenleyiciye ge\xE7",modeViewText:"G\xF6r\xFCn\xFCm",modeViewTitle:"A\u011Fa\xE7 g\xF6r\xFCn\xFCm\xFCne ge\xE7",examples:"\xD6rnekler",default:"Varsay\u0131lan",containsInvalidProperties:"Ge\xE7ersiz \xF6zellikler i\xE7eriyor",containsInvalidItems:"Ge\xE7ersiz \xF6\u011Feler i\xE7eriyor"},ja:{array:"\u914D\u5217",auto:"\u30AA\u30FC\u30C8",appendText:"\u8FFD\u52A0",appendTitle:'\u6B21\u306E\u30D5\u30A3\u30FC\u30EB\u30C9\u306B"\u30AA\u30FC\u30C8"\u306E\u30D5\u30A3\u30FC\u30EB\u30C9\u3092\u8FFD\u52A0 (Ctrl+Shift+Ins)',appendSubmenuTitle:"\u8FFD\u52A0\u3059\u308B\u30D5\u30A3\u30FC\u30EB\u30C9\u306E\u578B\u3092\u9078\u629E\u3057\u3066\u304F\u3060\u3055\u3044",appendTitleAuto:'"\u30AA\u30FC\u30C8"\u306E\u30D5\u30A3\u30FC\u30EB\u30C9\u3092\u8FFD\u52A0 (Ctrl+Shift+Ins)',ascending:"\u6607\u9806",ascendingTitle:"${type}\u306E\u5B50\u8981\u7D20\u3092\u6607\u9806\u306B\u4E26\u3079\u66FF\u3048",actionsMenu:"\u30AF\u30EA\u30C3\u30AF\u3057\u3066\u30A2\u30AF\u30B7\u30E7\u30F3\u30E1\u30CB\u30E5\u30FC\u3092\u958B\u304F (Ctrl+M)",collapseAll:"\u3059\u3079\u3066\u3092\u6298\u308A\u305F\u305F\u3080",descending:"\u964D\u9806",descendingTitle:"${type}\u306E\u5B50\u8981\u7D20\u3092\u964D\u9806\u306B\u4E26\u3079\u66FF\u3048",drag:"\u30C9\u30E9\u30C3\u30B0\u3057\u3066\u9078\u629E\u4E2D\u306E\u30D5\u30A3\u30FC\u30EB\u30C9\u3092\u79FB\u52D5 (Alt+Shift+Arrows)",duplicateKey:"\u8907\u88FD\u30AD\u30FC",duplicateText:"\u8907\u88FD",duplicateTitle:"\u9078\u629E\u4E2D\u306E\u30D5\u30A3\u30FC\u30EB\u30C9\u3092\u8907\u88FD (Ctrl+D)",duplicateField:"\u9078\u629E\u4E2D\u306E\u30D5\u30A3\u30FC\u30EB\u30C9\u3092\u8907\u88FD (Ctrl+D)",duplicateFieldError:"\u30D5\u30A3\u30FC\u30EB\u30C9\u540D\u304C\u91CD\u8907\u3057\u3066\u3044\u307E\u3059",cannotParseFieldError:"JSON\u306E\u30D5\u30A3\u30FC\u30EB\u30C9\u3092\u89E3\u6790\u3067\u304D\u307E\u305B\u3093",cannotParseValueError:"JSON\u306E\u5024\u3092\u89E3\u6790\u3067\u304D\u307E\u305B\u3093",empty:"\u7A7A",expandAll:"\u3059\u3079\u3066\u3092\u5C55\u958B",expandTitle:`\u30AF\u30EA\u30C3\u30AF\u3057\u3066\u30D5\u30A3\u30FC\u30EB\u30C9\u3092\u5C55\u958B/\u6298\u308A\u305F\u305F\u3080 (Ctrl+E). 
Ctrl+Click \u3067\u3059\u3079\u3066\u306E\u5B50\u8981\u7D20\u3092\u5C55\u958B/\u6298\u308A\u305F\u305F\u3080`,insert:"\u633F\u5165",insertTitle:"\u9078\u629E\u4E2D\u306E\u30D5\u30A3\u30FC\u30EB\u30C9\u306E\u524D\u306B\u65B0\u3057\u3044\u30D5\u30A3\u30FC\u30EB\u30C9\u3092\u633F\u5165 (Ctrl+Ins)",insertSub:"\u633F\u5165\u3059\u308B\u30D5\u30A3\u30FC\u30EB\u30C9\u306E\u578B\u3092\u9078\u629E",object:"\u30AA\u30D6\u30B8\u30A7\u30AF\u30C8",ok:"\u5B9F\u884C",redo:"\u3084\u308A\u76F4\u3059 (Ctrl+Shift+Z)",removeText:"\u524A\u9664",removeTitle:"\u9078\u629E\u4E2D\u306E\u30D5\u30A3\u30FC\u30EB\u30C9\u3092\u524A\u9664 (Ctrl+Del)",removeField:"\u9078\u629E\u4E2D\u306E\u30D5\u30A3\u30FC\u30EB\u30C9\u3092\u524A\u9664 (Ctrl+Del)",selectNode:"\u30CE\u30FC\u30C9\u3092\u9078\u629E...",showAll:"\u3059\u3079\u3066\u3092\u8868\u793A",showMore:"\u3082\u3063\u3068\u898B\u308B",showMoreStatus:"${totalChilds}\u500B\u306E\u30A2\u30A4\u30C6\u30E0\u306E\u3046\u3061 ${visibleChilds}\u500B\u3092\u8868\u793A\u3057\u3066\u3044\u307E\u3059\u3002",sort:"\u4E26\u3079\u66FF\u3048",sortTitle:"${type}\u306E\u5B50\u8981\u7D20\u3092\u4E26\u3079\u66FF\u3048",sortTitleShort:"\u4E26\u3079\u66FF\u3048",sortFieldLabel:"\u30D5\u30A3\u30FC\u30EB\u30C9:",sortDirectionLabel:"\u9806\u5E8F:",sortFieldTitle:"\u914D\u5217\u307E\u305F\u306F\u30AA\u30D6\u30B8\u30A7\u30AF\u30C8\u3092\u4E26\u3073\u66FF\u3048\u308B\u305F\u3081\u306E\u30D5\u30A3\u30FC\u30EB\u30C9\u3092\u9078\u629E",sortAscending:"\u6607\u9806",sortAscendingTitle:"\u9078\u629E\u4E2D\u306E\u30D5\u30A3\u30FC\u30EB\u30C9\u3092\u6607\u9806\u306B\u4E26\u3073\u66FF\u3048",sortDescending:"\u964D\u9806",sortDescendingTitle:"\u9078\u629E\u4E2D\u306E\u30D5\u30A3\u30FC\u30EB\u30C9\u3092\u964D\u9806\u306B\u4E26\u3073\u66FF\u3048",string:"\u6587\u5B57\u5217",transform:"\u5909\u63DB",transformTitle:"${type}\u306E\u5B50\u8981\u7D20\u3092\u30D5\u30A3\u30EB\u30BF\u30FC\u30FB\u4E26\u3073\u66FF\u3048\u30FB\u5909\u63DB\u3059\u308B",transformTitleShort:"\u5185\u5BB9\u3092\u30D5\u30A3\u30EB\u30BF\u30FC\u30FB\u4E26\u3073\u66FF\u3048\u30FB\u5909\u63DB\u3059\u308B",extract:"\u62BD\u51FA",extractTitle:"${type}\u3092\u62BD\u51FA",transformQueryTitle:"JMESPath\u30AF\u30A8\u30EA\u3092\u5165\u529B",transformWizardLabel:"\u30A6\u30A3\u30B6\u30FC\u30C9",transformWizardFilter:"\u30D5\u30A3\u30EB\u30BF\u30FC",transformWizardSortBy:"\u4E26\u3073\u66FF\u3048",transformWizardSelectFields:"\u30D5\u30A3\u30FC\u30EB\u30C9\u3092\u9078\u629E",transformQueryLabel:"\u30AF\u30A8\u30EA",transformPreviewLabel:"\u30D7\u30EC\u30D3\u30E5\u30FC",type:"\u578B",typeTitle:"\u9078\u629E\u4E2D\u306E\u30D5\u30A3\u30FC\u30EB\u30C9\u306E\u578B\u3092\u5909\u66F4",openUrl:"Ctrl+Click \u307E\u305F\u306F Ctrl+Enter \u3067 \u65B0\u898F\u30A6\u30A3\u30F3\u30C9\u30A6\u3067URL\u3092\u958B\u304F",undo:"\u5143\u306B\u623B\u3059 (Ctrl+Z)",validationCannotMove:"\u5B50\u8981\u7D20\u306B\u79FB\u52D5\u3067\u304D\u307E\u305B\u3093 ",autoType:"\u30AA\u30FC\u30C8\uFF1A \u30D5\u30A3\u30FC\u30EB\u30C9\u306E\u578B\u306F\u5024\u304B\u3089\u81EA\u52D5\u7684\u306B\u6C7A\u5B9A\u3055\u308C\u307E\u3059\u3002 (\u6587\u5B57\u5217\u30FB\u6570\u5024\u30FB\u30D6\u30FC\u30EB\u30FBnull)",objectType:"\u30AA\u30D6\u30B8\u30A7\u30AF\u30C8\uFF1A \u30AA\u30D6\u30B8\u30A7\u30AF\u30C8\u306F\u9806\u5E8F\u304C\u6C7A\u307E\u3063\u3066\u3044\u306A\u3044\u30AD\u30FC\u3068\u5024\u306E\u30DA\u30A2\u7D44\u307F\u5408\u308F\u305B\u3067\u3059\u3002",arrayType:"\u914D\u5217\uFF1A \u914D\u5217\u306F\u9806\u5E8F\u304C\u6C7A\u307E\u3063\u3066\u3044\u308B\u5024\u306E\u96C6\u5408\u4F53\u3067\u3059\u3002",stringType:"\u6587\u5B57\u5217\uFF1A \u30D5\u30A3\u30FC\u30EB\u30C9\u578B\u306F\u5024\u304B\u3089\u6C7A\u5B9A\u3055\u308C\u307E\u305B\u3093\u304C\u3001\u5E38\u306B\u6587\u5B57\u5217\u3068\u3057\u3066\u8FD4\u3055\u308C\u307E\u3059\u3002",modeCodeText:"\u30B3\u30FC\u30C9\u30E2\u30FC\u30C9",modeCodeTitle:"\u30CF\u30A4\u30E9\u30A4\u30C8\u30E2\u30FC\u30C9\u306B\u5207\u308A\u66FF\u3048",modeFormText:"\u30D5\u30A9\u30FC\u30E0\u30E2\u30FC\u30C9",modeFormTitle:"\u30D5\u30A9\u30FC\u30E0\u30E2\u30FC\u30C9\u306B\u5207\u308A\u66FF\u3048",modeTextText:"\u30C6\u30AD\u30B9\u30C8\u30E2\u30FC\u30C9",modeTextTitle:"\u30C6\u30AD\u30B9\u30C8\u30E2\u30FC\u30C9\u306B\u5207\u308A\u66FF\u3048",modeTreeText:"\u30C4\u30EA\u30FC\u30E2\u30FC\u30C9",modeTreeTitle:"\u30C4\u30EA\u30FC\u30E2\u30FC\u30C9\u306B\u5207\u308A\u66FF\u3048",modeViewText:"\u30D3\u30E5\u30FC\u30E2\u30FC\u30C9",modeViewTitle:"\u30D3\u30E5\u30FC\u30E2\u30FC\u30C9\u306B\u5207\u308A\u66FF\u3048",modePreviewText:"\u30D7\u30EC\u30D3\u30E5\u30FC",modePreviewTitle:"\u30D7\u30EC\u30D3\u30E5\u30FC\u306B\u5207\u308A\u66FF\u3048",examples:"\u4F8B",default:"\u30C7\u30D5\u30A9\u30EB\u30C8",containsInvalidProperties:"\u7121\u52B9\u306A\u30D7\u30ED\u30D1\u30C6\u30A3\u304C\u542B\u307E\u308C\u3066\u3044\u307E\u3059",containsInvalidItems:"\u7121\u52B9\u306A\u30A2\u30A4\u30C6\u30E0\u304C\u542B\u307E\u308C\u3066\u3044\u307E\u3059"},"fr-FR":{array:"Liste",auto:"Auto",appendText:"Ajouter",appendTitle:"Ajouter un champ de type 'auto' apr\xE8s ce champ (Ctrl+Shift+Ins)",appendSubmenuTitle:"S\xE9lectionner le type du champ \xE0 ajouter",appendTitleAuto:"Ajouter un champ de type 'auto' (Ctrl+Shift+Ins)",ascending:"Ascendant",ascendingTitle:"Trier les enfants de ce ${type} par ordre ascendant",actionsMenu:"Ouvrir le menu des actions (Ctrl+M)",collapseAll:"Regrouper",descending:"Descendant",descendingTitle:"Trier les enfants de ce ${type} par ordre descendant",drag:"D\xE9placer (Alt+Shift+Arrows)",duplicateKey:"Dupliquer la cl\xE9",duplicateText:"Dupliquer",duplicateTitle:"Dupliquer les champs s\xE9lectionn\xE9s (Ctrl+D)",duplicateField:"Dupliquer ce champ (Ctrl+D)",duplicateFieldError:"Dupliquer le nom de champ",cannotParseFieldError:"Champ impossible \xE0 parser en JSON",cannotParseValueError:"Valeur impossible \xE0 parser en JSON",empty:"vide",expandAll:"\xC9tendre",expandTitle:`\xC9tendre/regrouper ce champ (Ctrl+E). 
Ctrl+Click pour \xE9tendre/regrouper avec tous les champs.`,insert:"Ins\xE9rer",insertTitle:"Ins\xE9rer un champ de type 'auto' avant ce champ (Ctrl+Ins)",insertSub:"S\xE9lectionner le type de champ \xE0 ins\xE9rer",object:"Objet",ok:"Ok",redo:"Rejouer (Ctrl+Shift+Z)",removeText:"Supprimer",removeTitle:"Supprimer les champs s\xE9lectionn\xE9s (Ctrl+Del)",removeField:"Supprimer ce champ (Ctrl+Del)",searchTitle:"Rechercher champs et valeurs",searchNextResultTitle:"R\xE9sultat suivant (Enter)",searchPreviousResultTitle:"R\xE9sultat pr\xE9c\xE9dent (Shift + Enter)",selectNode:"S\xE9lectionner un n\u0153ud...",showAll:"voir tout",showMore:"voir plus",showMoreStatus:"${visibleChilds} \xE9l\xE9ments affich\xE9s de ${totalChilds}.",sort:"Trier",sortTitle:"Trier les champs de ce ${type}",sortTitleShort:"Trier",sortFieldLabel:"Champ:",sortDirectionLabel:"Direction:",sortFieldTitle:"S\xE9lectionner les champs permettant de trier les listes et objet",sortAscending:"Ascendant",sortAscendingTitle:"Trier les champs s\xE9lectionn\xE9s par ordre ascendant",sortDescending:"Descendant",sortDescendingTitle:"Trier les champs s\xE9lectionn\xE9s par ordre descendant",string:"Cha\xEEne",transform:"Transformer",transformTitle:"Filtrer, trier, or transformer les enfants de ce ${type}",transformTitleShort:"Filtrer, trier ou transformer le contenu",extract:"Extraire",extractTitle:"Extraire ce ${type}",transformQueryTitle:"Saisir une requ\xEAte JMESPath",transformWizardLabel:"Assistant",transformWizardFilter:"Filtrer",transformWizardSortBy:"Trier par",transformWizardSelectFields:"S\xE9lectionner les champs",transformQueryLabel:"Requ\xEAte",transformPreviewLabel:"Pr\xE9visualisation",type:"Type",typeTitle:"Changer le type de ce champ",openUrl:"Ctrl+Click ou Ctrl+Enter pour ouvrir l'url dans une autre fen\xEAtre",undo:"Annuler la derni\xE8re action (Ctrl+Z)",validationCannotMove:"Cannot move a field into a child of itself",autoType:'Champe de type "auto". Ce type de champ est automatiquement d\xE9termin\xE9 en fonction de la valeur et peut \xEAtre de type "cha\xEEne", "nombre", "bool\xE9en" ou null.',objectType:'Champ de type "objet". Un objet contient un ensemble non ordonn\xE9 de paires cl\xE9/valeur.',arrayType:'Champ de type "liste". Une liste contient une collection ordonn\xE9e de valeurs.',stringType:`Champ de type "cha\xEEne". Ce type de champ n'est pas d\xE9termin\xE9 en fonction de la valeur, mais retourne syst\xE9matiquement une cha\xEEne de caract\xE8res.`,modeEditorTitle:"Changer mode d'\xE9dition",modeCodeText:"Code",modeCodeTitle:"Activer surlignage code",modeFormText:"Formulaire",modeFormTitle:"Activer formulaire",modeTextText:"Texte",modeTextTitle:"Activer \xE9diteur texte",modeTreeText:"Arbre",modeTreeTitle:"Activer \xE9diteur arbre",modeViewText:"Lecture seule",modeViewTitle:"Activer vue arbre",modePreviewText:"Pr\xE9visualisation",modePreviewTitle:"Activer mode pr\xE9visualiser",examples:"Exemples",default:"D\xE9faut",containsInvalidProperties:"Contient des propri\xE9t\xE9s non valides",containsInvalidItems:"Contient des \xE9l\xE9ments invalides"},de:{array:"Auflistung",auto:"Auto",appendText:"anh\xE4ngen",appendTitle:"F\xFCgen Sie nach diesem Feld ein neues Feld mit dem Typ 'auto' ein (Strg+Umschalt+Ein)",appendSubmenuTitle:"W\xE4hlen Sie den Typ des neuen Feldes",appendTitleAuto:"Ein neues Feld vom Typ 'auto' hinzuf\xFCgen (Strg+Umschalt+Ein)",ascending:"Aufsteigend",ascendingTitle:"Sortieren Sie die Elemente dieses ${type} in aufsteigender Reihenfolge",actionsMenu:"Klicken Sie zum \xD6ffnen des Aktionsmen\xFCs (Strg+M)",cannotParseFieldError:"Feld kann nicht in JSON geparst werden",cannotParseValueError:"Wert kann nicht in JSON geparst werden",collapseAll:"Alle Felder zuklappen",compactTitle:"JSON-Daten verdichten, alle Leerzeichen entfernen (Strg+Umschalt+\\)",descending:"Absteigend",descendingTitle:"Sortieren Sie die Elemente dieses ${type} in absteigender Reihenfolge",drag:"Ziehen, um dieses Feld zu verschieben (Alt+Umschalt+Pfeile)",duplicateKey:"Doppelter Schl\xFCssel",duplicateText:"Duplikat",duplicateTitle:"Ausgew\xE4hlte Felder duplizieren (Strg+D)",duplicateField:"Dieses Feld duplizieren (Strg+D)",duplicateFieldError:"Doppelter Feldname",empty:"leer",expandAll:"Alle Felder anzeigen",expandTitle:`Klicken Sie, um dieses Feld zu erweitern/zu kollabieren (Strg+E). 
Strg+Klicken Sie, um dieses Feld einschlie\xDFlich aller Elemente zu erweitern/zu kollabieren.`,formatTitle:"JSON-Daten mit korrekter Einr\xFCckung und Zeilenvorsch\xFCben formatieren (Strg+\\)",insert:"einf\xFCgen",insertTitle:"F\xFCgen Sie vor diesem Feld ein neues Feld mit dem Typ 'auto' ein (Strg+Einfg)",insertSub:"W\xE4hlen Sie den Typ des neuen Feldes",object:"Objekt",ok:"Ok",redo:"Wiederholen (Strg+Umschalt+Z)",removeText:"entfernen",removeTitle:"Ausgew\xE4hlte Felder entfernen (Strg+Entf)",removeField:"Dieses Feld entfernen (Strg+Entf)",repairTitle:"JSON reparieren: Anf\xFChrungszeichen und Escape-Zeichen korrigieren, Kommentare und JSONP-Notation entfernen, JavaScript-Objekte in JSON umwandeln.",searchTitle:"Suchfelder und Werte",searchNextResultTitle:"N\xE4chstes Ergebnis (Enter)",searchPreviousResultTitle:"Vorheriges Ergebnis (Umschalt + Eingabe)",selectNode:"W\xE4hlen Sie einen Knoten aus...",showAll:"alle anzeigen",showMore:"mehr anzeigen",showMoreStatus:"Anzeige von ${visibleChilds} von ${totalChilds}-Elementen.",sort:"Sortieren",sortTitle:"Sortieren Sie die Elemente dieses ${type}",sortTitleShort:"Inhalt sortieren",sortFieldLabel:"Feld:",sortDirectionLabel:"Richtung:",sortFieldTitle:"W\xE4hlen Sie das verschachtelte Feld, nach dem das Array oder Objekt sortiert werden soll.",sortAscending:"Aufsteigend",sortAscendingTitle:"Sortieren Sie das ausgew\xE4hlte Feld in aufsteigender Reihenfolge",sortDescending:"Absteigend",sortDescendingTitle:"Sortieren Sie das ausgew\xE4hlte Feld in absteigender Reihenfolge",string:"Zeichenfolge",transform:"Verwandeln",transformTitle:"Die Elemente dieses ${type} filtern, sortieren oder transformieren",transformTitleShort:"Inhalte filtern, sortieren oder transformieren",extract:"Auszug",extractTitle:"Extrahieren Sie diesen ${type}",transformQueryTitle:"Eine JMESPath-Abfrage eingeben",transformWizardLabel:"Zauberer",transformWizardFilter:"Filter",transformWizardSortBy:"Sortieren nach",transformWizardSelectFields:"Felder ausw\xE4hlen",transformQueryLabel:"Anfrage",transformPreviewLabel:"Vorschau",type:"Geben Sie  ein.",typeTitle:"\xC4ndern Sie den Typ dieses Feldes",openUrl:"Strg+Klicken oder Strg+Eingabe, um die URL in einem neuen Fenster zu \xF6ffnen",undo:"Letzte Aktion r\xFCckg\xE4ngig machen (Strg+Z)",validationCannotMove:"Kann ein Feld nicht in ein Kind seiner selbst verschieben",autoType:'Feldtyp "auto". Der Feldtyp wird automatisch aus dem Wert bestimmt und kann ein String, eine Zahl, boolesch oder null sein.',objectType:'Feldtyp "Objekt". Ein Objekt enth\xE4lt eine ungeordnete Menge von Schl\xFCssel/Wert-Paaren.',arrayType:'Feldtyp "Array". Ein Array enth\xE4lt eine geordnete Sammlung von Werten.',stringType:'Feldtyp "Zeichenfolge". Der Feldtyp wird nicht aus dem Wert bestimmt, sondern immer als Zeichenfolge zur\xFCckgegeben.',modeEditorTitle:"Editor-Modus umschalten",modeCodeText:"Code",modeCodeTitle:"Umschalten auf Code-Highlighter",modeFormText:"Formular",modeFormTitle:"Zum Formular-Editor wechseln",modeTextText:"Text",modeTextTitle:"Zum Editor f\xFCr einfachen Text wechseln",modeTreeText:"Baum",modeTreeTitle:"Zum Baum-Editor wechseln",modeViewText:"Siehe",modeViewTitle:"Zur Baumansicht wechseln",modePreviewText:"Vorschau",modePreviewTitle:"In den Vorschau-Modus wechseln",examples:"Beispiele",default:"Standardm\xE4\xDFig",containsInvalidProperties:"Enth\xE4lt ung\xFCltige Eigenschaften",containsInvalidItems:"Enth\xE4lt ung\xFCltige Elemente"},ru:{array:"\u041C\u0430\u0441\u0441\u0438\u0432",auto:"\u0410\u0432\u0442\u043E",appendText:"\u0414\u043E\u0431\u0430\u0432\u0438\u0442\u044C",appendTitle:"\u0414\u043E\u0431\u0430\u0432\u0438\u0442\u044C \u043D\u043E\u0432\u043E\u0435 \u043F\u043E\u043B\u0435 \u0441 \u0442\u0438\u043F\u043E\u043C '\u0430\u0432\u0442\u043E' \u043F\u043E\u0441\u043B\u0435 \u044D\u0442\u043E\u0433\u043E \u043F\u043E\u043B\u044F (Ctrl+Shift+Ins)",appendSubmenuTitle:"\u0412\u044B\u0431\u0440\u0430\u0442\u044C \u0442\u0438\u043F \u043F\u043E\u043B\u044F \u0434\u043B\u044F \u0434\u043E\u0431\u0430\u0432\u043B\u0435\u043D\u0438\u044F",appendTitleAuto:"\u0414\u043E\u0431\u0430\u0432\u0438\u0442\u044C \u043D\u043E\u0432\u043E\u0435 \u043F\u043E\u043B\u0435 \u0441 \u0442\u0438\u043F\u043E\u043C '\u0430\u0432\u0442\u043E' (Ctrl+Shift+Ins)",ascending:"\u041F\u043E \u0432\u043E\u0437\u0440\u0430\u0441\u0442\u0430\u043D\u0438\u044E",ascendingTitle:"\u0421\u043E\u0440\u0442\u0438\u0440\u043E\u0432\u0430\u0442\u044C ${type} \u043F\u043E \u0432\u043E\u0437\u0440\u0430\u0441\u0442\u0430\u043D\u0438\u044E",actionsMenu:"\u041D\u0430\u0436\u043C\u0438\u0442\u0435 \u0434\u043B\u044F \u043E\u0442\u043A\u0440\u044B\u0442\u0438\u044F \u043C\u0435\u043D\u044E \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0439 (Ctrl+M)",cannotParseFieldError:"\u041D\u0435\u0432\u043E\u0437\u043C\u043E\u0436\u043D\u043E \u043F\u0440\u0435\u043E\u0431\u0440\u0430\u0437\u043E\u0432\u0430\u0442\u044C \u043F\u043E\u043B\u0435 \u0432 JSON",cannotParseValueError:"\u041D\u0435\u0432\u043E\u0437\u043C\u043E\u0436\u043D\u043E \u043F\u0440\u0435\u043E\u0431\u0440\u0430\u0437\u043E\u0432\u0430\u0442\u044C \u0437\u043D\u0430\u0447\u0435\u043D\u0438\u0435 \u0432 JSON",collapseAll:"\u0421\u0432\u0435\u0440\u043D\u0443\u0442\u044C \u0432\u0441\u0435",compactTitle:"\u041C\u0438\u043D\u0438\u0444\u0438\u043A\u0430\u0446\u0438\u044F JSON (Ctrl+Shift+I)",descending:"\u041F\u043E \u0443\u0431\u044B\u0432\u0430\u043D\u0438\u044E",descendingTitle:"\u0421\u043E\u0440\u0442\u0438\u0440\u043E\u0432\u0430\u0442\u044C ${type} \u043F\u043E \u0443\u0431\u044B\u0432\u0430\u043D\u0438\u044E",drag:"\u041F\u043E\u0442\u044F\u043D\u0438\u0442\u0435 \u0434\u043B\u044F \u043F\u0435\u0440\u0435\u043C\u0435\u0449\u0435\u043D\u0438\u044F \u044D\u0442\u043E\u0433\u043E \u043F\u043E\u043B\u044F (Alt+Shift+Arrows)",duplicateKey:"\u043F\u043E\u0432\u0442\u043E\u0440\u044F\u044E\u0449\u0438\u0439\u0441\u044F \u043A\u043B\u044E\u0447",duplicateText:"\u0414\u0443\u0431\u043B\u0438\u0440\u043E\u0432\u0430\u0442\u044C",duplicateTitle:"\u0414\u0443\u0431\u043B\u0438\u0440\u043E\u0432\u0430\u043D\u0438\u0435 \u043F\u043E\u043B\u0435\u0439 (Ctrl+D)",duplicateField:"\u0414\u0443\u0431\u043B\u0438\u0440\u043E\u0432\u0430\u0442\u044C \u043F\u043E\u043B\u0435 (Ctrl+D)",duplicateFieldError:"\u0414\u0443\u0431\u043B\u0438\u0440\u043E\u0432\u0430\u043D\u0438\u0435 \u043D\u0430\u0437\u0432\u0430\u043D\u0438\u044F \u043F\u043E\u043B\u044F",empty:"\u043F\u0443\u0441\u0442\u043E\u0439",expandAll:"\u0420\u0430\u0437\u0432\u0435\u0440\u043D\u0443\u0442\u044C \u0432\u0441\u0435",expandTitle:`\u041D\u0430\u0436\u043C\u0438\u0442\u0435 \u0434\u043B\u044F \u0440\u0430\u0441\u043A\u0440\u044B\u0442\u0438\u044F/\u0441\u043A\u0440\u044B\u0442\u0438\u044F \u043F\u043E\u043B\u044F (Ctrl+E)
\u0438\u043B\u0438 Ctrl+Click \u0434\u043B\u044F \u0440\u0430\u0441\u043A\u0440\u044B\u0442\u0438\u044F/\u0441\u043A\u0440\u044B\u0442\u0438\u044F \u0432\u0441\u0435\u0445 \u043F\u043E\u0442\u043E\u043C\u043A\u043E\u0432.`,formatTitle:"\u0424\u043E\u0440\u043C\u0430\u0442\u0438\u0440\u043E\u0432\u0430\u043D\u0438\u0435 JSON (Ctrl+I)",insert:"\u0412\u0441\u0442\u0430\u0432\u0438\u0442\u044C",insertTitle:"\u0412\u0441\u0442\u0430\u0432\u0438\u0442\u044C \u043D\u043E\u0432\u043E\u0435 \u043F\u043E\u043B\u0435 \u0441 \u0442\u0438\u043F\u043E\u043C '\u0430\u0432\u0442\u043E' \u043F\u0435\u0440\u0435\u0434 \u044D\u0442\u0438\u043C \u043F\u043E\u043B\u0435\u043C (Ctrl+Ins)",insertSub:"\u0412\u044B\u0431\u0440\u0430\u0442\u044C \u0442\u0438\u043F \u043F\u043E\u043B\u044F \u0434\u043B\u044F \u0432\u0441\u0442\u0430\u0432\u043A\u0438",object:"\u041E\u0431\u044A\u0435\u043A\u0442",ok:"\u041E\u041A",redo:"\u041F\u043E\u0432\u0442\u043E\u0440\u0438\u0442\u044C (Ctrl+Shift+Z)",removeText:"\u0423\u0434\u0430\u043B\u0438\u0442\u044C",removeTitle:"\u0423\u0434\u0430\u043B\u0438\u0442\u044C \u0432\u044B\u0431\u0440\u0430\u043D\u043D\u044B\u0435 \u043F\u043E\u043B\u044F (Ctrl+Del)",removeField:"\u0423\u0434\u0430\u043B\u0438\u0442\u044C \u043F\u043E\u043B\u0435 (Ctrl+Del)",repairTitle:"\u0412\u043E\u0441\u0441\u0442\u0430\u043D\u043E\u0432\u0438\u0442\u0435 JSON: \u0438\u0441\u043F\u0440\u0430\u0432\u044C\u0442\u0435 \u043A\u0430\u0432\u044B\u0447\u043A\u0438 \u0438 escape-\u0441\u0438\u043C\u0432\u043E\u043B\u044B, \u0443\u0434\u0430\u043B\u0438\u0442\u0435 \u043A\u043E\u043C\u043C\u0435\u043D\u0442\u0430\u0440\u0438\u0438 \u0438 \u043D\u043E\u0442\u0430\u0446\u0438\u044E JSONP, \u043C\u043E\u0434\u0438\u0444\u0438\u0446\u0438\u0440\u0443\u0439\u0442\u0435 \u043E\u0431\u044A\u0435\u043A\u0442\u044B JavaScript \u0432 JSON.",searchTitle:"\u041F\u043E\u0438\u0441\u043A",searchNextResultTitle:"\u0421\u043B\u0435\u0434\u0443\u044E\u0449\u0438\u0439 \u0440\u0435\u0437\u0443\u043B\u044C\u0442\u0430\u0442 (Enter)",searchPreviousResultTitle:"\u041F\u0440\u0435\u0434\u044B\u0434\u0443\u0449\u0438\u0439 \u0440\u0435\u0437\u0443\u043B\u044C\u0442\u0430\u0442 (Shift + Enter)",selectNode:"\u0412\u044B\u0431\u043E\u0440 \u0443\u0437\u043B\u0430...",showAll:"\u043F\u043E\u043A\u0430\u0437\u0430\u0442\u044C \u0432\u0441\u0435",showMore:"\u0431\u043E\u043B\u044C\u0448\u0435",showMoreStatus:"${visibleChilds} \u0438\u0437 ${totalChilds}",sort:"\u0421\u043E\u0440\u0442\u0438\u0440\u043E\u0432\u043A\u0430",sortTitle:"\u0421\u043E\u0440\u0442\u0438\u0440\u043E\u0432\u043A\u0430 \u043F\u043E\u0442\u043E\u043C\u043A\u043E\u0432 \u0442\u0438\u043F\u0430 ${type}",sortTitleShort:"\u0421\u043E\u0440\u0442\u0438\u0440\u043E\u0432\u043A\u0430 \u0441\u043E\u0434\u0435\u0440\u0436\u0438\u043C\u043E\u0433\u043E",sortFieldLabel:"\u041F\u043E\u043B\u0435:",sortDirectionLabel:"\u041D\u0430\u043F\u0440\u0430\u0432\u043B\u0435\u043D\u0438\u0435:",sortFieldTitle:"\u0412\u044B\u0431\u0435\u0440\u0438\u0442\u0435 \u043F\u043E\u043B\u0435 \u0434\u043B\u044F \u0441\u043E\u0440\u0442\u0438\u0440\u043E\u0432\u043A\u0438 \u043C\u0430\u0441\u0441\u0438\u0432\u0430 \u0438\u043B\u0438 \u043E\u0431\u044A\u0435\u043A\u0442\u0430",sortAscending:"\u041F\u043E \u0432\u043E\u0437\u0440\u0430\u0441\u0442\u0430\u043D\u0438\u044E",sortAscendingTitle:"\u0421\u043E\u0440\u0442\u0438\u0440\u043E\u0432\u043A\u0430 \u0432\u044B\u0431\u0440\u0430\u043D\u043D\u043E\u0433\u043E \u043F\u043E\u0440\u044F \u043F\u043E \u0432\u043E\u0437\u0440\u0430\u0441\u0442\u0430\u043D\u0438\u044E",sortDescending:"\u041F\u043E \u0443\u0431\u044B\u0432\u0430\u043D\u0438\u044E",sortDescendingTitle:"\u0421\u043E\u0440\u0442\u0438\u0440\u043E\u0432\u043A\u0430 \u0432\u044B\u0431\u0440\u0430\u043D\u043D\u043E\u0433\u043E \u043F\u043E\u0440\u044F \u043F\u043E \u0443\u0431\u044B\u0432\u0430\u043D\u0438\u044E",string:"\u0421\u0442\u0440\u043E\u043A\u0430",transform:"\u041C\u043E\u0434\u0438\u0444\u0438\u043A\u0430\u0446\u0438\u044F",transformTitle:"\u0424\u0438\u043B\u044C\u0442\u0440\u0430\u0446\u0438\u044F, \u0441\u043E\u0440\u0442\u0438\u0440\u043E\u0432\u043A\u0430 \u0438\u043B\u0438 \u043C\u043E\u0434\u0438\u0444\u0438\u043A\u0430\u0446\u0438\u044F \u0434\u0430\u043D\u043D\u044B\u0445 \u0442\u0438\u043F\u0430 ${type}",transformTitleShort:"\u0424\u0438\u043B\u044C\u0442\u0440\u0430\u0446\u0438\u044F, \u0441\u043E\u0440\u0442\u0438\u0440\u043E\u0432\u043A\u0430 \u0438\u043B\u0438 \u043C\u043E\u0434\u0438\u0444\u0438\u043A\u0430\u0446\u0438\u044F \u0434\u0430\u043D\u043D\u044B\u0445",extract:"\u0418\u0437\u0432\u043B\u0435\u0447\u0435\u043D\u0438\u0435",extractTitle:"\u0418\u0437\u0432\u043B\u0435\u0447\u044C \u0442\u0438\u043F ${type}",transformQueryTitle:"\u0412\u0432\u0435\u0434\u0438\u0442\u0435 JMESpath \u0437\u0430\u043F\u0440\u043E\u0441",transformWizardLabel:"\u041C\u0430\u0441\u0442\u0435\u0440",transformWizardFilter:"\u0424\u0438\u043B\u044C\u0442\u0440",transformWizardSortBy:"\u0421\u043E\u0440\u0442\u0438\u0440\u043E\u0432\u043A\u0430",transformWizardSelectFields:"\u041F\u043E\u043B\u044F",transformQueryLabel:"\u0417\u0430\u043F\u0440\u043E\u0441",transformPreviewLabel:"\u041F\u0440\u043E\u0441\u043C\u043E\u0442\u0440",type:"\u0422\u0438\u043F",typeTitle:"\u0418\u0437\u043C\u0435\u043D\u0438\u0442\u044C \u0442\u0438\u043F \u044D\u0442\u043E\u0433\u043E \u043F\u043E\u043B\u044F",openUrl:"Ctrl+Click \u0438\u043B\u0438 Ctrl+Enter \u0434\u043B\u044F \u043E\u0442\u043A\u0440\u044B\u0442\u0438\u044F url \u0432 \u043D\u043E\u0432\u043E\u043C \u043E\u043A\u043D\u0435",undo:"\u041E\u0442\u043C\u0435\u043D\u0438\u0442\u044C (Ctrl+Z)",validationCannotMove:"\u041F\u043E\u043B\u0435 \u043D\u0435 \u043C\u043E\u0436\u0435\u0442 \u0431\u044B\u0442\u044C \u043F\u0435\u0440\u0435\u043C\u0435\u0449\u0435\u043D\u043E \u0432 \u043F\u043E\u0442\u043E\u043C\u043A\u0430",autoType:"\u0422\u0438\u043F \u043F\u043E\u043B\u044F \u0430\u0432\u0442\u043E\u043C\u0430\u0442\u0438\u0447\u0435\u0441\u043A\u0438 \u043E\u043F\u0440\u0435\u0434\u0435\u043B\u044F\u0435\u0442\u0441\u044F \u043F\u043E \u0437\u043D\u0430\u0447\u0435\u043D\u0438\u044E \u0438 \u043C\u043E\u0436\u0435\u0442 \u0431\u044B\u0442\u044C \u0441\u0442\u0440\u043E\u043A\u043E\u0439, \u0447\u0438\u0441\u043B\u043E\u043C, \u043B\u043E\u0433\u0438\u0447\u0435\u0441\u043A\u0438\u043C \u0437\u043D\u0430\u0447\u0435\u043D\u0438\u0435\u043C \u0438\u043B\u0438 null.",objectType:"\u041E\u0431\u044A\u0435\u043A\u0442 \u0441\u043E\u0434\u0435\u0440\u0436\u0438\u0442 \u043D\u0435\u0443\u043F\u043E\u0440\u044F\u0434\u043E\u0447\u0435\u043D\u043D\u044B\u0439 \u043D\u0430\u0431\u043E\u0440 \u043F\u0430\u0440 \u043A\u043B\u044E\u0447/\u0437\u043D\u0430\u0447\u0435\u043D\u0438\u0435.",arrayType:"\u041C\u0430\u0441\u0441\u0438\u0432 \u0441\u043E\u0434\u0435\u0440\u0436\u0438\u0442 \u0443\u043F\u043E\u0440\u044F\u0434\u043E\u0447\u0435\u043D\u043D\u044B\u0439 \u043D\u0430\u0431\u043E\u0440 \u0437\u043D\u0430\u0447\u0435\u043D\u0438\u0439.",stringType:"\u0422\u0438\u043F \u043F\u043E\u043B\u044F \u043D\u0435 \u043E\u043F\u0440\u0435\u0434\u0435\u043B\u044F\u0435\u0442\u0441\u044F \u0438\u0437 \u0437\u043D\u0430\u0447\u0435\u043D\u0438\u044F, \u043D\u043E \u0432\u0441\u0435\u0433\u0434\u0430 \u0432\u043E\u0437\u0432\u0440\u0430\u0449\u0430\u0435\u0442\u0441\u044F \u043A\u0430\u043A \u0441\u0442\u0440\u043E\u043A\u0430.",modeEditorTitle:"\u041F\u0435\u0440\u0435\u043A\u043B\u044E\u0447\u0435\u043D\u0438\u0435 \u0440\u0435\u0436\u0438\u043C\u0430 \u0440\u0435\u0434\u0430\u043A\u0442\u043E\u0440\u0430",modeCodeText:"\u041A\u043E\u0434",modeCodeTitle:"\u041F\u0435\u0440\u0435\u043A\u043B\u044E\u0447\u0438\u0442\u044C \u0432 \u0440\u0435\u0436\u0438\u043C \u0440\u0435\u0434\u0430\u043A\u0442\u043E\u0440\u0430 \u043A\u043E\u0434\u0430",modeFormText:"\u0424\u043E\u0440\u043C\u0430",modeFormTitle:"\u041F\u0435\u0440\u0435\u043A\u043B\u044E\u0447\u0438\u0442\u044C \u0432 \u0440\u0435\u0436\u0438\u043C \u0444\u043E\u0440\u043C\u044B",modeTextText:"\u0422\u0435\u043A\u0441\u0442",modeTextTitle:"\u041F\u0435\u0440\u0435\u043A\u043B\u044E\u0447\u0438\u0442\u044C \u0432 \u0440\u0435\u0436\u0438\u043C \u0440\u0435\u0434\u0430\u043A\u0442\u043E\u0440\u0430 \u0442\u0435\u043A\u0441\u0442\u0430",modeTreeText:"\u0414\u0435\u0440\u0435\u0432\u043E",modeTreeTitle:"\u041F\u0435\u0440\u0435\u043A\u043B\u044E\u0447\u0438\u0442\u044C \u0432 \u0440\u0435\u0436\u0438\u043C \u0440\u0435\u0434\u0430\u043A\u0442\u043E\u0440\u0430 \u0434\u0435\u0440\u0435\u0432\u0430",modeViewText:"\u041F\u0440\u043E\u0441\u043C\u043E\u0442\u0440 \u0434\u0435\u0440\u0435\u0432\u0430",modeViewTitle:"\u041F\u0435\u0440\u0435\u043A\u043B\u044E\u0447\u0438\u0442\u044C \u0432 \u0440\u0435\u0436\u0438\u043C \u043F\u0440\u043E\u0441\u043C\u043E\u0442\u0440\u0430 \u0434\u0435\u0440\u0435\u0432\u0430",modePreviewText:"\u041F\u0440\u043E\u0441\u043C\u043E\u0442\u0440",modePreviewTitle:"\u041F\u0435\u0440\u0435\u043A\u043B\u044E\u0447\u0438\u0442\u044C \u0432 \u0440\u0435\u0436\u0438\u043C \u043F\u0440\u043E\u0441\u043C\u043E\u0442\u0440\u0430",examples:"\u041F\u0440\u0438\u043C\u0435\u0440\u044B",default:"\u041F\u043E \u0443\u043C\u043E\u043B\u0447\u0430\u043D\u0438\u044E",containsInvalidProperties:"\u0421\u043E\u0434\u0435\u0440\u0436\u0438\u0442 \u043D\u0435\u0434\u043E\u043F\u0443\u0441\u0442\u0438\u043C\u044B\u0435 \u0441\u0432\u043E\u0439\u0441\u0442\u0432\u0430",containsInvalidItems:"\u0421\u043E\u0434\u0435\u0440\u0436\u0438\u0442 \u043D\u0435\u0434\u043E\u043F\u0443\u0441\u0442\u0438\u043C\u044B\u0435 \u044D\u043B\u0435\u043C\u0435\u043D\u0442\u044B"},ko:{array:"\uBC30\uC5F4",auto:"\uC790\uB3D9",appendText:"\uCD94\uAC00",appendTitle:'\uC120\uD0DD\uD55C \uC694\uC18C \uC544\uB798\uC5D0 "\uC790\uB3D9" \uC694\uC18C\uB97C \uCD94\uAC00\uD569\uB2C8\uB2E4. (Ctrl + Shift + Ins)',appendSubmenuTitle:"\uCD94\uAC00\uD560 \uC694\uC18C\uC758 \uC720\uD615\uC744 \uC120\uD0DD\uD574\uC8FC\uC138\uC694.",appendTitleAuto:'"\uC790\uB3D9" \uC694\uC18C\uB97C \uCD94\uAC00\uD569\uB2C8\uB2E4. (Ctrl + Shift + Ins)',ascending:"\uC624\uB984\uCC28\uC21C",ascendingTitle:"\uC120\uD0DD\uD55C ${type}\uC758 \uD558\uC704 \uC694\uC18C\uB97C \uC624\uB984\uCC28\uC21C \uC815\uB82C\uD569\uB2C8\uB2E4.",actionsMenu:"\uBA54\uB274 \uC5F4\uAE30 (Ctrl + M)",cannotParseFieldError:"JSON\uC758 \uC694\uC18C\uB97C \uD574\uC11D\uD560 \uC218 \uC5C6\uC2B5\uB2C8\uB2E4.",cannotParseValueError:"JSON\uC758 \uAC12\uC744 \uD574\uC11D\uD560 \uC218 \uC5C6\uC2B5\uB2C8\uB2E4.",collapseAll:"\uBAA8\uB450 \uC811\uAE30",compactTitle:"\uBAA8\uB4E0 \uACF5\uBC31\uC744 \uC81C\uAC70\uD558\uC5EC JSON \uB370\uC774\uD130\uB97C \uC791\uAC8C \uB9CC\uB4ED\uB2C8\uB2E4. (Ctrl + Shift + I)",descending:"\uB0B4\uB9BC\uCC28\uC21C",descendingTitle:"\uC120\uD0DD\uD55C ${type}\uC758 \uD558\uC704 \uC694\uC18C\uB97C \uB0B4\uB9BC\uCC28\uC21C\uC73C\uB85C \uC815\uB82C",drag:"\uB4DC\uB798\uADF8\uD558\uC5EC \uC694\uC18C\uB97C \uC774\uB3D9\uD569\uB2C8\uB2E4. (Alt + Shift + Arrows)",duplicateKey:"\uBCF5\uC81C\uD0A4",duplicateText:"\uBCF5\uC81C",duplicateTitle:"\uC120\uD0DD\uD55C \uC694\uC18C\uB97C \uBCF5\uC81C\uD569\uB2C8\uB2E4. (Ctrl + D)",duplicateField:"\uC120\uD0DD\uD55C \uC694\uC18C\uB97C \uBCF5\uC81C\uD569\uB2C8\uB2E4. (Ctrl + D)",duplicateFieldError:"\uC694\uC18C \uC774\uB984\uC774 \uC911\uBCF5\uB418\uC5C8\uC2B5\uB2C8\uB2E4.",empty:"\uBE44\uC5B4\uC788\uC74C",expandAll:"\uBAA8\uB450 \uC5F4\uAE30",expandTitle:`\uD074\uB9AD\uD558\uC5EC \uC694\uC18C\uB97C \uC5F4\uAC70\uB098 \uB2EB\uC2B5\uB2C8\uB2E4. (Ctrl + E) 
Ctrl + Click\uC73C\uB85C \uBAA8\uB4E0 \uD558\uC704 \uC694\uC18C\uB97C \uC5F4\uAC70\uB098 \uB2EB\uC2B5\uB2C8\uB2E4.`,formatTitle:"\uC801\uC808\uD55C \uB4E4\uC5EC\uC4F0\uAE30 \uBC0F \uC904\uBC14\uAFC8\uC73C\uB85C JSON \uB370\uC774\uD130\uB97C \uC815\uD615\uD654\uD569\uB2C8\uB2E4. (Ctrl + I)",insert:"\uC0BD\uC785",insertTitle:"\uC120\uD0DD\uD55C \uC694\uC18C \uC704\uC5D0 \uC0C8\uC694\uC18C\uB97C \uC0BD\uC785\uD569\uB2C8\uB2E4. (Ctrl + Ins)",insertSub:"\uC0BD\uC785\uD560 \uC694\uC18C\uC758 \uC720\uD615\uC744 \uC120\uD0DD\uD574\uC8FC\uC138\uC694.",object:"\uAC1D\uCCB4",ok:"\uD655\uC778",redo:"\uB2E4\uC2DC \uC2E4\uD589 (Ctrl + Shift + Z)",removeText:"\uC0AD\uC81C",removeTitle:"\uC120\uD0DD\uD55C \uC694\uC18C\uB97C \uC0AD\uC81C\uD569\uB2C8\uB2E4. (Ctrl + Del)",removeField:"\uC120\uD0DD\uD55C \uC694\uC18C\uB97C \uC0AD\uC81C\uD569\uB2C8\uB2E4. (Ctrl + Del)",repairTitle:"JSON \uAD50\uC815: JSON \uB0B4\uC758 \uC8FC\uC11D\uACFC JSONP \uD45C\uAE30\uBC95\uC744 \uC9C0\uC6B0\uACE0 \uB530\uC634\uD45C\uC640 \uC774\uC2A4\uCF00\uC774\uD504 \uBB38\uC790\uB97C \uC218\uC815\uD569\uB2C8\uB2E4.",searchTitle:"\uC694\uC18C \uB610\uB294 \uAC12 \uCC3E\uAE30",searchNextResultTitle:"\uB2E4\uC74C\uC73C\uB85C \uCC3E\uAE30 (Enter)",searchPreviousResultTitle:"\uC774\uC804\uC73C\uB85C \uCC3E\uAE30 (Shift + Enter)",selectNode:"\uC694\uC18C\uB97C \uC120\uD0DD\uD574\uC8FC\uC138\uC694...",showAll:"\uBAA8\uB450\uBCF4\uAE30",showMore:"\uB354\uBCF4\uAE30",showMoreStatus:"${totalChilds} \uAC1C\uC758 \uD56D\uBAA9 \uC911 ${visibleChilds} \uAC1C\uB97C \uD45C\uC2DC\uD569\uB2C8\uB2E4.",sort:"\uC815\uB82C",sortTitle:"\uC120\uD0DD\uD55C ${type}\uC758 \uD558\uC704 \uC694\uC18C\uB97C \uC815\uB82C\uD569\uB2C8\uB2E4.",sortTitleShort:"\uC815\uB82C",sortFieldLabel:"\uC694\uC18C:",sortDirectionLabel:"\uC21C\uC11C:",sortFieldTitle:"\uBC30\uC5F4\uC774\uB098 \uAC1D\uCCB4\uB97C \uC815\uB82C\uD558\uB294 \uC694\uC18C\uB97C \uC120\uD0DD\uD574\uC8FC\uC138\uC694.",sortAscending:"\uC624\uB984\uCC28\uC21C",sortAscendingTitle:"\uC120\uD0DD\uD55C \uC694\uC18C\uB97C \uC624\uB984\uCC28\uC21C\uC73C\uB85C \uC815\uB82C\uD569\uB2C8\uB2E4.",sortDescending:"\uB0B4\uB9BC\uCC28\uC21C",sortDescendingTitle:"\uC120\uD0DD\uD55C \uC694\uC18C\uB97C \uB0B4\uB9BC\uCC28\uC21C\uC73C\uB85C \uC815\uB82C\uD569\uB2C8\uB2E4.",string:"\uBB38\uC790",transform:"\uBCC0\uD658",transformTitle:"\uC120\uD0DD\uD55C ${type}\uC758 \uD558\uC704 \uC694\uC18C\uB97C \uD544\uD130\uD558\uAC70\uB098 \uC815\uB82C \uB610\uB294 \uBCC0\uD658\uD569\uB2C8\uB2E4.",transformTitleShort:"\uB0B4\uC6A9\uC744 \uD544\uD130\uD558\uAC70\uB098 \uC815\uB82C \uB610\uB294 \uBCC0\uD658\uD569\uB2C8\uB2E4.",extract:"\uCD94\uCD9C",extractTitle:"\uC120\uD0DD\uD55C ${type}\uC758 \uAC12\uC744 \uCD5C\uC0C1\uC704\uC5D0 \uC704\uCE58\uC2DC\uD0B5\uB2C8\uB2E4.",transformQueryTitle:"JMESPath \uCFFC\uB9AC\uB97C \uC785\uB825\uD574\uC8FC\uC138\uC694.",transformWizardLabel:"\uB9C8\uBC95\uC0AC",transformWizardFilter:"\uD544\uD130",transformWizardSortBy:"\uC815\uB82C",transformWizardSelectFields:"\uC694\uC18C\uB97C \uC120\uD0DD\uD574\uC8FC\uC138\uC694.",transformQueryLabel:"\uCFFC\uB9AC",transformPreviewLabel:"\uBBF8\uB9AC\uBCF4\uAE30",type:"\uC720\uD615",typeTitle:"\uC120\uD0DD\uD55C \uC694\uC18C\uC758 \uC720\uD615\uC744 \uBCC0\uACBD\uD569\uB2C8\uB2E4.",openUrl:"Ctrl + Click \uB610\uB294 Ctrl + Enter\uB85C \uC0C8 \uCC3D\uC5D0\uC11C URL \uC5F4\uAE30",undo:"\uC2E4\uD589 \uCDE8\uC18C (Ctrl + Z)",validationCannotMove:"\uD558\uC704 \uC694\uC18C\uB85C \uC774\uB3D9\uD560 \uC218 \uC5C6\uC2B5\uB2C8\uB2E4.",autoType:"\uC790\uB3D9: \uC694\uC18C\uC758 \uD615\uC2DD\uC774 \uAC12\uC758 \uC720\uD615\uC73C\uB85C \uACB0\uC815\uB429\uB2C8\uB2E4. \uBB38\uC790, \uC22B\uC790, \uBD80\uC6B8, \uB610\uB294 null\uB9CC \uD5C8\uC6A9\uB429\uB2C8\uB2E4.",objectType:"\uAC1D\uCCB4: \uC21C\uC11C\uB300\uB85C \uB098\uC5F4\uB418\uC9C0 \uC54A\uC740 \uC774\uB984/\uAC12 \uC30D\uC73C\uB85C \uC774\uB8E8\uC5B4\uC9C4 \uC9D1\uD569\uC785\uB2C8\uB2E4.",arrayType:"\uBC30\uC5F4: \uC21C\uC11C\uB300\uB85C \uB098\uC5F4\uB41C \uAC12\uC758 \uC9D1\uD569\uC785\uB2C8\uB2E4.",stringType:"\uBB38\uC790: \uC694\uC18C\uC758 \uC720\uD615\uC774 \uAC12\uC5D0\uC11C \uACB0\uC815\uB418\uC9C0 \uC54A\uC9C0\uB9CC \uD56D\uC0C1 \uBB38\uC790\uB85C \uBC18\uD658\uB429\uB2C8\uB2E4.",modeEditorTitle:"\uD3B8\uC9D1\uAE30 \uC720\uD615 \uBCC0\uACBD",modeCodeText:"\uCF54\uB4DC",modeCodeTitle:"\uD615\uC2DD \uAD50\uC815\uC744 \uB3C4\uC640\uC8FC\uB294 \uAE30\uB2A5\uC774 \uD3EC\uD568\uB41C \uBB38\uC790 \uD3B8\uC9D1\uAE30",modeFormText:"\uC785\uB825 \uC591\uC2DD",modeFormTitle:"\uC815\uD574\uC9C4 \uC694\uC18C\uC5D0 \uAC12\uC744 \uC785\uB825\uD558\uB294 \uD3B8\uC9D1\uAE30",modeTextText:"\uBB38\uC790",modeTextTitle:"\uB2E8\uC21C \uBB38\uC790 \uD3B8\uC9D1\uAE30",modeTreeText:"\uD2B8\uB9AC",modeTreeTitle:"\uD2B8\uB9AC \uAD6C\uC870\uB85C \uD45C\uC2DC\uB418\uB294 \uD3B8\uC9D1\uAE30",modeViewText:"\uBCF4\uAE30",modeViewTitle:"\uC77D\uAE30\uC804\uC6A9 \uD2B8\uB9AC \uAD6C\uC870\uB85C JSON\uC744 \uD45C\uC2DC",modePreviewText:"\uBBF8\uB9AC\uBCF4\uAE30",modePreviewTitle:"\uC77D\uAE30\uC804\uC6A9 \uBB38\uC790\uB85C JSON\uC744 \uD45C\uC2DC",examples:"\uC608\uC81C",default:"\uAE30\uBCF8\uAC12",containsInvalidProperties:"\uC798\uBABB\uB41C \uC18D\uC131\uC774 \uD3EC\uD568\uB418\uC5B4 \uC788\uC2B5\uB2C8\uB2E4.",containsInvalidItems:"\uC798\uBABB\uB41C \uD56D\uBAA9\uC774 \uD3EC\uD568\uB418\uC5B4 \uC788\uC2B5\uB2C8\uB2E4"}},k=Object.keys(X),N="en",Z=typeof navigator!="undefined"?navigator.language||navigator.userLanguage:void 0,O=k.find(function(C){return C===Z})||N;function W(C){var m;C&&((m=k.find(function(b){return b===C}))?O=m:console.error("Language not found"))}function F(C){if(C)for(var m in C)(function(b){k.find(function(x){return x===b})||k.push(b),X[b]=Object.assign({},X[N],X[b],C[b])})(m)}function L(C,m,b){var x=X[b=b||O][C]||X[N][C]||C;if(m)for(var p in m)x=x.replace("${"+p+"}",m[p]);return x}},6056:function(ie,X,V){V.d(X,{J:function(){return O},r:function(){return Z}});var X=V(5156),k=V.n(X),N=V(9791);function Z(W,b){var L,C=b.sort,m=b.filter,b=b.projection,x="";return m?(L=m.field!=="@"?["0"].concat((0,N.parsePath)("."+m.field)):["0"],L=typeof(0,N.get)(W,L)=="string"?m.value:(0,N.parseString)(m.value),x+="[? "+m.field+" "+m.relation+" `"+JSON.stringify(L)+"`]"):x+=Array.isArray(W)?"[*]":"@",C&&(C.direction==="desc"?x+=" | reverse(sort_by(@, &"+C.field+"))":x+=" | sort_by(@, &"+C.field+")"),b&&(x[x.length-1]!=="]"&&(x+=" | [*]"),b.fields.length===1?x+="."+b.fields[0]:1<b.fields.length&&(x+=".{"+b.fields.map(function(p){var l=p.split(".");return l[l.length-1]+": "+p}).join(", ")+"}")),x}function O(W,F){return k().search(W,F)}},4987:function(){function ie(u){u===void 0||"remove"in u||Object.defineProperty(u,"remove",{configurable:!0,enumerable:!0,writable:!0,value:function(){this.parentNode!==void 0&&this.parentNode.removeChild(this)}})}typeof Element!="undefined"&&(window.Element!==void 0&&ie(window.Element.prototype),window.CharacterData!==void 0&&ie(window.CharacterData.prototype),window.DocumentType!==void 0&&ie(window.DocumentType.prototype)),Array.prototype.findIndex||Object.defineProperty(Array.prototype,"findIndex",{value:function(u){for(var V=0;V<this.length;V++){var X=this[V];if(u.call(this,X,V,this))return V}return-1},configurable:!0,writable:!0}),Array.prototype.find||Object.defineProperty(Array.prototype,"find",{value:function(u){return u=this.findIndex(u),this[u]},configurable:!0,writable:!0}),String.prototype.trim||(String.prototype.trim=function(){return this.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"")})},341:function(ie,l,p){p.r(l),p.d(l,{previewModeMixins:function(){return s}});var l=p(3860),X=p.n(l),k=p(4188),N=p(6436),Z=p(2474);function O(n,t){for(var i=0;i<t.length;i++){var e=t[i];e.enumerable=e.enumerable||!1,e.configurable=!0,"value"in e&&(e.writable=!0),Object.defineProperty(n,e.key,e)}}var W=function(){function n(e,r,a){if(!(this instanceof n))throw new TypeError("Cannot call a class as a function");this.onChange=e,this.calculateItemSize=r||function(){return 1},this.limit=a,this.items=[],this.index=-1}var t,i;return t=n,(i=[{key:"add",value:function(e){for(;this._calculateHistorySize()>this.limit&&1<this.items.length;)this.items.shift(),this.index--;this.items=this.items.slice(0,this.index+1),this.items.push(e),this.index++,this.onChange()}},{key:"_calculateHistorySize",value:function(){var e=this.calculateItemSize,r=0;return this.items.forEach(function(a){r+=e(a)}),r}},{key:"undo",value:function(){if(this.canUndo())return this.index--,this.onChange(),this.items[this.index]}},{key:"redo",value:function(){if(this.canRedo())return this.index++,this.onChange(),this.items[this.index]}},{key:"canUndo",value:function(){return 0<this.index}},{key:"canRedo",value:function(){return this.index<this.items.length-1}},{key:"clear",value:function(){this.items=[],this.index=-1,this.onChange()}}])&&O(t.prototype,i),Object.defineProperty(t,"prototype",{writable:!1}),n}(),F=p(7907),L=p(6056),C=p(6617),m=p(6210),b=p(2558),l=p(8458),x=p(9791),p=l.textModeMixins[0].mixin,l={create:function(e){var t=1<arguments.length&&arguments[1]!==void 0?arguments[1]:{},i=(t.statusBar===void 0&&(t.statusBar=!0),t.mainMenuBar=t.mainMenuBar!==!1,t.enableSort=t.enableSort!==!1,t.enableTransform=t.enableTransform!==!1,t.createQuery=t.createQuery||L.r,t.executeQuery=t.executeQuery||L.J,typeof(this.options=t).indentation=="number"?this.indentation=Number(t.indentation):this.indentation=2,(0,F.cC)(this.options.languages),(0,F.m0)(this.options.language),this.mode="preview",this),e=(this.container=e,this.dom={},this.json=void 0,this.text="",this._debouncedValidate=(0,x.debounce)(this.validate.bind(this),this.DEBOUNCE_INTERVAL),this.width=e.clientWidth,this.height=e.clientHeight,this.frame=document.createElement("div"),this.frame.className="jsoneditor jsoneditor-mode-preview",this.frame.onclick=function(r){r.preventDefault()},{target:this.frame,onFocus:this.options.onFocus||null,onBlur:this.options.onBlur||null});this.frameFocusTracker=new Z.R(e),this.content=document.createElement("div"),this.content.className="jsoneditor-outer",this.dom.busy=document.createElement("div"),this.dom.busy.className="jsoneditor-busy",this.dom.busyContent=document.createElement("span"),this.dom.busyContent.textContent="busy...",this.dom.busy.appendChild(this.dom.busyContent),this.content.appendChild(this.dom.busy),this.dom.previewContent=document.createElement("pre"),this.dom.previewContent.className="jsoneditor-preview",this.dom.previewText=document.createTextNode(""),this.dom.previewContent.appendChild(this.dom.previewText),this.content.appendChild(this.dom.previewContent),this.options.mainMenuBar&&((0,x.addClassName)(this.content,"has-main-menu-bar"),this.menu=document.createElement("div"),this.menu.className="jsoneditor-menu",this.frame.appendChild(this.menu),(e=document.createElement("button")).type="button",e.className="jsoneditor-format",e.title=(0,F.Iu)("formatTitle"),this.menu.appendChild(e),e.onclick=function(){i.executeWithBusyMessage(function(){try{i.format()}catch(r){i._onError(r)}},"formatting...")},(e=document.createElement("button")).type="button",e.className="jsoneditor-compact",e.title=(0,F.Iu)("compactTitle"),this.menu.appendChild(e),e.onclick=function(){i.executeWithBusyMessage(function(){try{i.compact()}catch(r){i._onError(r)}},"compacting...")},this.options.enableSort&&((e=document.createElement("button")).type="button",e.className="jsoneditor-sort",e.title=(0,F.Iu)("sortTitleShort"),e.onclick=function(){i._showSortModal()},this.menu.appendChild(e)),this.options.enableTransform&&((e=document.createElement("button")).type="button",e.title=(0,F.Iu)("transformTitleShort"),e.className="jsoneditor-transform",e.onclick=function(){i._showTransformModal()},this.dom.transform=e,this.menu.appendChild(e)),(e=document.createElement("button")).type="button",e.className="jsoneditor-repair",e.title=(0,F.Iu)("repairTitle"),this.menu.appendChild(e),!(e.onclick=function(){i.json===void 0&&i.executeWithBusyMessage(function(){try{i.repair()}catch(r){i._onError(r)}},"repairing...")})!==this.options.history&&(this.history=new W(function(){i.dom.undo.disabled=!i.history.canUndo(),i.dom.redo.disabled=!i.history.canRedo()},function(r){return 2*r.text.length},k.oW),(e=document.createElement("button")).type="button",e.className="jsoneditor-undo jsoneditor-separator",e.title=(0,F.Iu)("undo"),e.onclick=function(){var r=i.history.undo();r&&i._applyHistory(r)},this.menu.appendChild(e),this.dom.undo=e,(e=document.createElement("button")).type="button",e.className="jsoneditor-redo",e.title=(0,F.Iu)("redo"),e.onclick=function(){var r=i.history.redo();r&&i._applyHistory(r)},this.menu.appendChild(e),this.dom.redo=e,this.history.onChange()),this.options&&this.options.modes&&this.options.modes.length&&(this.modeSwitcher=new C.x(this.menu,this.options.modes,this.options.mode,function(r){try{i.setMode(r),i.modeSwitcher.focus()}catch(a){i._onError(a)}}))),this.errorTable=new N.Q({errorTableVisible:!0,onToggleVisibility:function(){i.validate()},onFocusLine:null,onChangeHeight:function(r){r=r+(i.dom.statusBar?i.dom.statusBar.clientHeight:0)+1,i.content.style.marginBottom=-r+"px",i.content.style.paddingBottom=r+"px"}}),this.frame.appendChild(this.content),this.frame.appendChild(this.errorTable.getErrorTable()),this.container.appendChild(this.frame),t.statusBar&&((0,x.addClassName)(this.content,"has-status-bar"),e=document.createElement("div"),(this.dom.statusBar=e).className="jsoneditor-statusbar",this.frame.appendChild(e),this.dom.fileSizeInfo=document.createElement("span"),this.dom.fileSizeInfo.className="jsoneditor-size-info",this.dom.fileSizeInfo.innerText="",e.appendChild(this.dom.fileSizeInfo),this.dom.arrayInfo=document.createElement("span"),this.dom.arrayInfo.className="jsoneditor-size-info",this.dom.arrayInfo.innerText="",e.appendChild(this.dom.arrayInfo),e.appendChild(this.errorTable.getErrorCounter()),e.appendChild(this.errorTable.getWarningIcon()),e.appendChild(this.errorTable.getErrorIcon())),this._renderPreview(),this.setSchema(this.options.schema,this.options.schemaRefs)},_renderPreview:function(){var n=this.getText();this.dom.previewText.nodeValue=(0,x.limitCharacters)(n,k.WF),this.dom.fileSizeInfo&&(this.dom.fileSizeInfo.innerText="Size: "+(0,x.formatSize)(n.length)),this.dom.arrayInfo&&(Array.isArray(this.json)?this.dom.arrayInfo.innerText="Array: "+this.json.length+" items":this.dom.arrayInfo.innerText="")},_onChange:function(){if(this._debouncedValidate(),this.options.onChange)try{this.options.onChange()}catch(n){console.error("Error in onChange callback: ",n)}if(this.options.onChangeJSON)try{this.options.onChangeJSON(this.get())}catch(n){console.error("Error in onChangeJSON callback: ",n)}if(this.options.onChangeText)try{this.options.onChangeText(this.getText())}catch(n){console.error("Error in onChangeText callback: ",n)}}},s=(l._showSortModal=function(){var n=this;this.executeWithBusyMessage(function(){var t=n.options.modalAnchor||k.qD,i=n.get();n._renderPreview(),(0,m.showSortModal)(t,i,function(e){n.executeWithBusyMessage(function(){var r,a,o;r=i,a=e,Array.isArray(r)&&(o=(0,x.sort)(r,a.path,a.direction),n.sortedBy=a,n._setAndFireOnChange(o)),(0,x.isObject)(r)&&(o=(0,x.sortObjectKeys)(r,a.direction),n.sortedBy=a,n._setAndFireOnChange(o))},"sorting...")},n.sortedBy)},"parsing...")},l._showTransformModal=function(){var n=this;this.executeWithBusyMessage(function(){var r=n.options,t=r.createQuery,i=r.executeQuery,e=r.modalAnchor,r=r.queryDescription,a=n.get();n._renderPreview(),(0,b.showTransformModal)({container:e||k.qD,json:a,queryDescription:r,createQuery:t,executeQuery:i,onTransform:function(o){n.executeWithBusyMessage(function(){var c=i(a,o);n._setAndFireOnChange(c)},"transforming...")}})},"parsing...")},l.destroy=function(){this.frame&&this.container&&this.frame.parentNode===this.container&&this.container.removeChild(this.frame),this.modeSwitcher&&(this.modeSwitcher.destroy(),this.modeSwitcher=null),this._debouncedValidate=null,this.history&&(this.history.clear(),this.history=null),this.frameFocusTracker.destroy()},l.compact=function(){var n=this.get(),t=JSON.stringify(n);this._setTextAndFireOnChange(t,n)},l.format=function(){var n=this.get(),t=JSON.stringify(n,null,this.indentation);this._setTextAndFireOnChange(t,n)},l.repair=function(){var n=this.getText();try{var t=X()(n);this._setTextAndFireOnChange(t)}catch{}},l.focus=function(){this.dom.transform.focus()},l.set=function(n){this.history&&this.history.clear(),this._set(n)},l.update=function(n){this._set(n)},l._set=function(n){this.text=void 0,this.json=n,this._renderPreview(),this._pushHistory(),this._debouncedValidate()},l._setAndFireOnChange=function(n){this._set(n),this._onChange()},l.get=function(){var n;return this.json===void 0&&(n=this.getText(),this.json=(0,x.parse)(n)),this.json},l.getText=function(){return this.text===void 0&&(this.text=JSON.stringify(this.json,null,this.indentation),this.options.escapeUnicode===!0&&(this.text=(0,x.escapeUnicodeChars)(this.text))),this.text},l.setText=function(n){this.history&&this.history.clear(),this._setText(n)},l.updateText=function(n){this.getText()!==n&&this._setText(n)},l._setText=function(n,t){var i;this.options.escapeUnicode===!0?this.text=(0,x.escapeUnicodeChars)(n):this.text=n,this.json=t,this._renderPreview(),this.json===void 0?(i=this).executeWithBusyMessage(function(){try{i.json=i.get(),i._renderPreview(),i._pushHistory()}catch{}},"parsing..."):this._pushHistory(),this._debouncedValidate()},l._setTextAndFireOnChange=function(n,t){this._setText(n,t),this._onChange()},l._applyHistory=function(n){this.json=n.json,this.text=n.text,this._renderPreview(),this._debouncedValidate()},l._pushHistory=function(){var n;this.history&&(n={text:this.text,json:this.json},this.history.add(n))},l.executeWithBusyMessage=function(n,t){var i;this.getText().length>k.EX?((0,x.addClassName)((i=this).frame,"busy"),i.dom.busyContent.innerText=t,setTimeout(function(){n(),(0,x.removeClassName)(i.frame,"busy"),i.dom.busyContent.innerText=""},100)):n()},l.validate=p.validate,l._renderErrors=p._renderErrors,[{mode:"preview",mixin:l,data:"json"}])},6210:function(ie,X,V){V.r(X),V.d(X,{showSortModal:function(){return O}});var X=V(483),k=V.n(X),N=V(7907),Z=V(9791);function O(W,p,L,C){var m=Array.isArray(p)?(0,Z.getChildPaths)(p):[""],b=C&&C.path&&(0,Z.contains)(m,C.path)?C.path:m[0],x=C&&C.direction||"asc",p='<div class="pico-modal-contents"><div class="pico-modal-header">'+(0,N.Iu)("sort")+"</div><form><table><tbody><tr>  <td>"+(0,N.Iu)("sortFieldLabel")+' </td>  <td class="jsoneditor-modal-input">  <div class="jsoneditor-select-wrapper">    <select id="field" title="'+(0,N.Iu)("sortFieldTitle")+'">    </select>  </div>  </td></tr><tr>  <td>'+(0,N.Iu)("sortDirectionLabel")+' </td>  <td class="jsoneditor-modal-input">  <div id="direction" class="jsoneditor-button-group"><input type="button" value="'+(0,N.Iu)("sortAscending")+'" title="'+(0,N.Iu)("sortAscendingTitle")+'" data-value="asc" class="jsoneditor-button-first jsoneditor-button-asc"/><input type="button" value="'+(0,N.Iu)("sortDescending")+'" title="'+(0,N.Iu)("sortDescendingTitle")+'" data-value="desc" class="jsoneditor-button-last jsoneditor-button-desc"/>  </div>  </td></tr><tr><td colspan="2" class="jsoneditor-modal-input jsoneditor-modal-actions">  <input type="submit" id="ok" value="'+(0,N.Iu)("ok")+'" /></td></tr></tbody></table></form></div>';k()({parent:W,content:p,overlayClass:"jsoneditor-modal-overlay",overlayStyles:{backgroundColor:"rgb(1,1,1)",opacity:.3},modalClass:"jsoneditor-modal jsoneditor-modal-sort"}).afterCreate(function(l){var s=l.modalElem().querySelector("form"),n=l.modalElem().querySelector("#ok"),t=l.modalElem().querySelector("#field"),i=l.modalElem().querySelector("#direction");function e(r){i.value=r,i.className="jsoneditor-button-group jsoneditor-button-group-value-"+i.value}m.forEach(function(r){var a,o=document.createElement("option");o.text=(a=r)===""?"@":a[0]==="."?a.slice(1):a,o.value=r,t.appendChild(o)}),t.value=b||m[0],e(x||"asc"),i.onclick=function(r){e(r.target.getAttribute("data-value"))},n.onclick=function(r){r.preventDefault(),r.stopPropagation(),l.close(),L({path:t.value,direction:i.value})},s&&(s.onsubmit=n.onclick)}).afterClose(function(l){l.destroy()}).show()}},2558:function(ie,k,V){V.r(k),V.d(k,{showTransformModal:function(){return b}});var k=V(483),X=V.n(k),k=V(3879),N=V.n(k),Z=V(7907);function O(x){return(O=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(p){return typeof p}:function(p){return p&&typeof Symbol=="function"&&p.constructor===Symbol&&p!==Symbol.prototype?"symbol":typeof p})(x)}function W(x,p,l,s){if(typeof x=="boolean"||x instanceof Boolean||x===null||typeof x=="number"||x instanceof Number||typeof x=="string"||x instanceof String||x instanceof Date)return JSON.stringify(x);if(Array.isArray(x)){for(var n=x,t=p,i=l,e=s,r=t?i+t:void 0,a=t?`[
`:"[",o=0;o<n.length;o++){var c=n[o];if(t&&(a+=r),a+=c!==void 0&&typeof c!="function"?W(c,t,r,e):"null",o<n.length-1&&(a+=t?`,
`:","),a.length>e)return a+"..."}return a+=t?`
`+i+"]":"]"}if(x&&O(x)==="object"){var h,A=x,v=p,i=l,d=s,g=v?i+v:void 0,y=!0,w=v?`{
`:"{";if(typeof A.toJSON=="function")return W(A.toJSON(),v,i,d);for(h in A)if(function(B,E){return Object.prototype.hasOwnProperty.call(B,E)}(A,h)){var I=A[h];if(y?y=!1:w+=v?`,
`:",",(w=(w+=v?g+'"'+h+'": ':'"'+h+'":')+W(I,v,g,d)).length>d)return w+"..."}return w+=v?`
`+i+"}":"}"}}function F(x,p){for(var l="";0<p--;)l+=x;return l}var L=V(9791),C=V(4188),m='Enter a <a href="http://jmespath.org" target="_blank">JMESPath</a> query to filter, sort, or transform the JSON data.<br/>To learn JMESPath, go to <a href="http://jmespath.org/tutorial.html" target="_blank">the interactive tutorial</a>.';function b(r){var p=r.container,l=r.json,s=r.queryDescription,s=s===void 0?m:s,n=r.createQuery,t=r.executeQuery,i=r.onTransform,e=l,r='<label class="pico-modal-contents"><div class="pico-modal-header">'+(0,Z.Iu)("transform")+"</div><p>"+s+'</p><div class="jsoneditor-jmespath-label">'+(0,Z.Iu)("transformWizardLabel")+' </div><div id="wizard" class="jsoneditor-jmespath-block jsoneditor-jmespath-wizard">  <table class="jsoneditor-jmespath-wizard-table">    <tbody>      <tr>        <th>'+(0,Z.Iu)("transformWizardFilter")+'</th>        <td class="jsoneditor-jmespath-filter">          <div class="jsoneditor-inline jsoneditor-jmespath-filter-field" >            <select id="filterField">            </select>          </div>          <div class="jsoneditor-inline jsoneditor-jmespath-filter-relation" >            <select id="filterRelation">              <option value="==">==</option>              <option value="!=">!=</option>              <option value="<">&lt;</option>              <option value="<=">&lt;=</option>              <option value=">">&gt;</option>              <option value=">=">&gt;=</option>            </select>          </div>          <div class="jsoneditor-inline jsoneditor-jmespath-filter-value" >            <input type="text" class="value" placeholder="value..." id="filterValue" />          </div>        </td>      </tr>      <tr>        <th>'+(0,Z.Iu)("transformWizardSortBy")+'</th>        <td class="jsoneditor-jmespath-filter">          <div class="jsoneditor-inline jsoneditor-jmespath-sort-field">            <select id="sortField">            </select>          </div>          <div class="jsoneditor-inline jsoneditor-jmespath-sort-order" >            <select id="sortOrder">              <option value="asc">Ascending</option>              <option value="desc">Descending</option>            </select>          </div>        </td>      </tr>      <tr id="selectFieldsPart">        <th>'+(0,Z.Iu)("transformWizardSelectFields")+'</th>        <td class="jsoneditor-jmespath-filter">          <select class="jsoneditor-jmespath-select-fields" id="selectFields" multiple></select>        </td>      </tr>    </tbody>  </table></div><div class="jsoneditor-jmespath-label">'+(0,Z.Iu)("transformQueryLabel")+' </div><div class="jsoneditor-jmespath-block">  <textarea id="query"             rows="4"             autocomplete="off"             autocorrect="off"             autocapitalize="off"             spellcheck="false"            title="'+(0,Z.Iu)("transformQueryTitle")+'">[*]</textarea></div><div class="jsoneditor-jmespath-label">'+(0,Z.Iu)("transformPreviewLabel")+' </div><div class="jsoneditor-jmespath-block">  <textarea id="preview"       class="jsoneditor-transform-preview"      readonly> </textarea></div><div class="jsoneditor-jmespath-block jsoneditor-modal-actions">  <input type="submit" id="ok" value="'+(0,Z.Iu)("ok")+'" autofocus /></div></div>';X()({parent:p,content:r,overlayClass:"jsoneditor-modal-overlay",overlayStyles:{backgroundColor:"rgb(1,1,1)",opacity:.3},modalClass:"jsoneditor-modal jsoneditor-modal-transform",focus:!1}).afterCreate(function(a){var o=a.modalElem(),T=o.querySelector("#wizard"),c=o.querySelector("#ok"),h=o.querySelector("#filterField"),A=o.querySelector("#filterRelation"),v=o.querySelector("#filterValue"),d=o.querySelector("#sortField"),g=o.querySelector("#sortOrder"),y=o.querySelector("#selectFields"),w=o.querySelector("#query"),I=o.querySelector("#preview");Array.isArray(e)||(T.style.fontStyle="italic",T.textContent="(wizard not available for objects, only for arrays)"),(0,L.getChildPaths)(l).forEach(function(H){var H=j(H),G=document.createElement("option"),G=(G.text=H,G.value=H,h.appendChild(G),document.createElement("option"));G.text=H,G.value=H,d.appendChild(G)});var T=(0,L.getChildPaths)(l,!0).filter(function(R){return R!==""}),T=(0<T.length?T.forEach(function(H){var H=j(H),G=document.createElement("option");G.text=H,G.value=H,y.appendChild(G)}):(T=o.querySelector("#selectFieldsPart"))&&(T.style.display="none"),new(N())(h,{defaultSelected:!1,clearable:!0,allowDeselect:!0,placeholder:"field..."})),B=new(N())(A,{defaultSelected:!1,clearable:!0,allowDeselect:!0,placeholder:"compare..."}),E=new(N())(d,{defaultSelected:!1,clearable:!0,allowDeselect:!0,placeholder:"field..."}),_=new(N())(g,{defaultSelected:!1,clearable:!0,allowDeselect:!0,placeholder:"order..."}),P=new(N())(y,{multiple:!0,clearable:!0,defaultSelected:!1,placeholder:"select fields..."});function j(R){return R===""?"@":R[0]==="."?R.slice(1):R}T.on("selectr.change",Y),B.on("selectr.change",Y),v.oninput=Y,E.on("selectr.change",Y),_.on("selectr.change",Y),P.on("selectr.change",Y),o.querySelector(".pico-modal-contents").onclick=function(R){R.target.nodeName!=="A"&&R.preventDefault()};var z=(0,L.debounce)(function(){try{var R=t(e,w.value);I.className="jsoneditor-transform-preview",I.value=(H=R,G=2,f=C.WF,typeof G=="number"?10<G?S=F(" ",10):1<=G&&(S=F(" ",G)):typeof G=="string"&&G!==""&&(S=G),(G=W(H,S,"",f)).length>f?(H=G,(typeof(S=f)=="number"?H.slice(0,S):H)+"..."):G),c.disabled=!1}catch($){I.className="jsoneditor-transform-preview jsoneditor-error",I.value=$.toString(),c.disabled=!0}var H,G,f,S},300);function D(R,H){try{w.value=n(R,H),c.disabled=!1,z()}catch(G){R='Error: an error happened when executing "createQuery": '+(G.message||G.toString()),w.value="",c.disabled=!0,I.className="jsoneditor-transform-preview jsoneditor-error",I.value=R}}function Y(){var R={};if(h.value&&A.value&&v.value&&(R.filter={field:h.value,relation:A.value,value:v.value}),d.value&&g.value&&(R.sort={field:d.value,direction:g.value}),y.value){for(var H,G=[],f=0;f<y.options.length;f++)y.options[f].selected&&(H=y.options[f].value,G.push(H));R.projection={fields:G}}D(l,R)}w.oninput=z,c.onclick=function(R){R.preventDefault(),R.stopPropagation(),a.close(),i(w.value)},D(l,{}),setTimeout(function(){w.select(),w.focus(),w.selectionStart=3,w.selectionEnd=3})}).afterClose(function(a){a.destroy()}).show()}},8458:function(ie,t,V){V.r(t),V.d(t,{textModeMixins:function(){return r}});var t=V(3860),X=V.n(t),t=V(8170),k=V.n(t),N=V(4188),Z=V(6436),O=V(2474),W=V(7907),F=V(6056),L=V(6617),C=V(6210),m=V(2558),b=V(9125),x=V(7026),p=V(9791);function l(a,o){for(var c=0;c<o.length;c++){var h=o[c];h.enumerable=h.enumerable||!1,h.configurable=!0,"value"in h&&(h.writable=!0),Object.defineProperty(a,h.key,h)}}var s=function(){function a(h,A){if(!(this instanceof a))throw new TypeError("Cannot call a class as a function");this.schema=h,this.schemaRefs=A||{},this.suggestions={},this.suggestionsRefs={},this._buildSuggestions()}var o,c;return o=a,(c=[{key:"_buildSuggestions",value:function(){for(var h in this._handleSchemaEntry("",this.schema,this.suggestions),this.schemaRefs)this.suggestionsRefs[h]={},this._handleSchemaEntry("",this.schemaRefs[h],this.suggestionsRefs[h])}},{key:"_handleRef",value:function(h,A,v){v[h]=v[h]||{},v[h].refs=v[h].refs||[],v[h].refs=(0,p.uniqueMergeArrays)(v[h].refs,[A])}},{key:"_handleSchemaEntry",value:function(h,A,v){if(A)if(A.$ref)this._handleRef(h,A.$ref,v);else{var d=this._checkOfConditon(A);if(d)this._handleOfCondition(h,A[d],v);else switch(A.type){case"object":this._handleObject(h,A,v);break;case"string":case"number":case"integer":this._handlePrimitive(h,A,v);break;case"boolean":this._handleBoolean(h,A,v);break;case"array":this._handleArray(h,A,v)}}else console.error("SchemaTextCompleter: schema node is missing for path",h)}},{key:"_handleObject",value:function(h,A,v){var d,g=this;(0,p.isObject)(A.properties)&&(d=Object.keys(A.properties),v[h]=v[h]||{},v[h].props=v[h].props||[],v[h].props=(0,p.uniqueMergeArrays)(v[h].props,d),d.forEach(function(y){(0,p.asyncExec)(function(){g._handleSchemaEntry("".concat(h,"/").concat(y),A.properties[y],v)})}))}},{key:"_handlePrimitive",value:function(h,A,v){v[h]=v[h]||{},(0,p.isArray)(A.examples)&&(v[h].examples=v[h].examples||[],v[h].examples=(0,p.uniqueMergeArrays)(v[h].examples,A.examples)),(0,p.isArray)(A.enum)&&(v[h].enum=v[h].enum||[],v[h].enum=(0,p.uniqueMergeArrays)(v[h].enum,A.enum))}},{key:"_handleBoolean",value:function(h,A,v){v[h]||(v[h]={bool:[!0,!1]})}},{key:"_handleArray",value:function(h,A,v){var d=this;A.items&&(0,p.asyncExec)(function(){d._handleSchemaEntry("".concat(h,"/\\d+"),A.items,v)})}},{key:"_handleOfCondition",value:function(h,A,v){var d=this;A&&A.length&&A.forEach(function(g){(0,p.asyncExec)(function(){d._handleSchemaEntry(h,g,v)})})}},{key:"_checkOfConditon",value:function(h){if(h)return h.oneOf?"oneOf":h.anyOf?"anyOf":h.allOf?"allOf":void 0}},{key:"getCompletions",value:function(h,A,v,d,g){var y=this;try{var w=x.parse(A.getValue()).pointers||{},I=function(T){function B(P){var j,z={props:"property",enum:"enum",bool:"boolean",examples:"examples"};T&&(j=T[P])!=null&&j.length&&(E=E.concat(T[P].map(function(D){return{caption:D+"",meta:"schema [".concat(z[P],"]"),score:_++,value:D+""}})))}var E=[],_=0;B("props"),B("enum"),B("bool"),B("examples"),E.length&&g(null,E)};Object.keys(w).forEach(function(T){(0,p.asyncExec)(function(){function B(P,j,z){var D,Y=Object.keys(j).reduce(function(f,S){return new RegExp("^".concat(z).concat(S)).test(P)&&(!f||f.length<S.length)?S:f});if(typeof Y=="string"){if((D=j[Y])!=null&&(D=D.refs)!=null&&D.length){var R,H={};for(R in j[Y].refs){var G=j[Y].refs[R];y.suggestionsRefs[G]&&((G=B(P,y.suggestionsRefs[G],"".concat(z).concat(Y)))!=null&&G.enum&&(H.enum=(0,p.uniqueMergeArrays)(H.enum,G.enum)),G!=null&&G.examples&&(H.examples=(0,p.uniqueMergeArrays)(H.examples,G.examples)),G!=null&&G.bool&&(H.bool=(0,p.uniqueMergeArrays)(H.bool,G.bool)),G!=null&&G.props&&(H.props=(0,p.uniqueMergeArrays)(H.props,G.props)))}return H}if(new RegExp("^".concat(z).concat(Y,"$")).test(P))return console.log("SchemaTextCompleter: Text suggestion match",{path:P,schemaPath:"".concat(z).concat(Y),suggestions:j[Y]}),j[Y]}}var E,_;((_=w[T].key)==null?void 0:_.line)===v.row&&v.column>=w[T].key.column&&v.column<=w[T].keyEnd.column&&(E=T.slice(0,T.lastIndexOf("/"))),(E=((_=w[T].value)==null?void 0:_.line)===v.row&&((_=w[T].value)==null?void 0:_.line)===((_=w[T].valueEnd)==null?void 0:_.line)&&v.column>=w[T].value.column&&v.column<=w[T].valueEnd.column?T:E)&&(_=B(E,y.suggestions,""),I(_))})})}catch{}}}])&&l(o.prototype,c),Object.defineProperty(o,"prototype",{writable:!1}),a}();function n(a){return(n=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(o){return typeof o}:function(o){return o&&typeof Symbol=="function"&&o.constructor===Symbol&&o!==Symbol.prototype?"symbol":typeof o})(a)}var t={},i="ace/theme/jsoneditor";function e(){try{this.format()}catch{}}t.create=function(y){var o,c,h,A=this,v=1<arguments.length&&arguments[1]!==void 0?arguments[1]:{},d=(v.statusBar===void 0&&(v.statusBar=!0),v.mainMenuBar=v.mainMenuBar!==!1,v.enableSort=v.enableSort!==!1,v.enableTransform=v.enableTransform!==!1,v.createQuery=v.createQuery||F.r,v.executeQuery=v.executeQuery||F.J,typeof(this.options=v).indentation=="number"?this.indentation=Number(v.indentation):this.indentation=2,(0,W.cC)(this.options.languages),(0,W.m0)(this.options.language),v.ace||k()),g=(this.mode=v.mode==="code"?"code":"text",this.mode==="code"&&d===void 0&&(this.mode="text",console.warn("Failed to load Ace editor, falling back to plain text mode. Please use a JSONEditor bundle including Ace, or pass Ace as via the configuration option `ace`.")),this.theme=v.theme||i,this.theme===i&&d&&(0,b.O)(),v.onTextSelectionChange&&this.onTextSelectionChange(v.onTextSelectionChange),this),y=(this.container=y,this.dom={},this.aceEditor=void 0,this.textarea=void 0,this.validateSchema=null,this.annotations=[],this.lastSchemaErrors=void 0,this._debouncedValidate=(0,p.debounce)(this._validateAndCatch.bind(this),this.DEBOUNCE_INTERVAL),this.width=y.clientWidth,this.height=y.clientHeight,this.frame=document.createElement("div"),this.frame.className="jsoneditor jsoneditor-mode-"+this.options.mode,this.frame.onclick=function(w){w.preventDefault()},this.frame.onkeydown=function(w){g._onKeyDown(w)},{target:this.frame,onFocus:this.options.onFocus||null,onBlur:this.options.onBlur||null}),y=(this.frameFocusTracker=new O.R(y),this.content=document.createElement("div"),this.content.className="jsoneditor-outer",this.options.mainMenuBar&&((0,p.addClassName)(this.content,"has-main-menu-bar"),this.menu=document.createElement("div"),this.menu.className="jsoneditor-menu",this.frame.appendChild(this.menu),(y=document.createElement("button")).type="button",y.className="jsoneditor-format",y.title=(0,W.Iu)("formatTitle"),this.menu.appendChild(y),y.onclick=function(){try{g.format(),g._onChange()}catch(w){g._onError(w)}},(y=document.createElement("button")).type="button",y.className="jsoneditor-compact",y.title=(0,W.Iu)("compactTitle"),this.menu.appendChild(y),y.onclick=function(){try{g.compact(),g._onChange()}catch(w){g._onError(w)}},this.options.enableSort&&((y=document.createElement("button")).type="button",y.className="jsoneditor-sort",y.title=(0,W.Iu)("sortTitleShort"),y.onclick=function(){g._showSortModal()},this.menu.appendChild(y)),this.options.enableTransform&&((y=document.createElement("button")).type="button",y.title=(0,W.Iu)("transformTitleShort"),y.className="jsoneditor-transform",y.onclick=function(){g._showTransformModal()},this.menu.appendChild(y)),(y=document.createElement("button")).type="button",y.className="jsoneditor-repair",y.title=(0,W.Iu)("repairTitle"),this.menu.appendChild(y),y.onclick=function(){try{g.repair(),g._onChange()}catch(w){g._onError(w)}},this.mode==="code"&&((y=document.createElement("button")).type="button",y.className="jsoneditor-undo jsoneditor-separator",y.title=(0,W.Iu)("undo"),y.onclick=function(){A.aceEditor.getSession().getUndoManager().undo()},this.menu.appendChild(y),this.dom.undo=y,(y=document.createElement("button")).type="button",y.className="jsoneditor-redo",y.title=(0,W.Iu)("redo"),y.onclick=function(){A.aceEditor.getSession().getUndoManager().redo()},this.menu.appendChild(y),this.dom.redo=y),this.options&&this.options.modes&&this.options.modes.length&&(this.modeSwitcher=new L.x(this.menu,this.options.modes,this.options.mode,function(w){try{g.setMode(w),g.modeSwitcher.focus()}catch(I){g._onError(I)}})),this.mode==="code"&&((o=document.createElement("a")).appendChild(document.createTextNode("powered by ace")),o.href="https://ace.c9.io/",o.target="_blank",o.className="jsoneditor-poweredBy",o.onclick=function(){window.open(o.href,o.target,"noreferrer")},this.menu.appendChild(o))),this.options.onEditable&&n(this.options.onEditable==="function")&&!this.options.onEditable({}));this.frame.appendChild(this.content),this.container.appendChild(this.frame),this.mode==="code"?(this.editorDom=document.createElement("div"),this.editorDom.style.height="100%",this.editorDom.style.width="100%",this.content.appendChild(this.editorDom),h=(d=d.edit(this.editorDom)).getSession(),d.$blockScrolling=1/0,d.setTheme(this.theme),d.setOptions({readOnly:y}),d.setShowPrintMargin(!1),d.setFontSize("14px"),h.setMode("ace/mode/json"),h.setTabSize(this.indentation),h.setUseSoftTabs(!0),h.setUseWrapMode(!0),c=h.setAnnotations,h.setAnnotations=function(w){c.call(this,w&&w.length?w:g.annotations)},d.commands.bindKey("Ctrl-L",null),d.commands.bindKey("Command-L",null),d.commands.bindKey("Ctrl-\\",null),d.commands.bindKey("Command-\\",null),d.commands.bindKey("Ctrl-Shift-\\",null),d.commands.bindKey("Command-Shift-\\",null),(this.aceEditor=d).on("change",this._onChange.bind(this)),d.on("changeSelection",this._onSelect.bind(this))):((h=document.createElement("textarea")).className="jsoneditor-text",h.spellcheck=!1,this.content.appendChild(h),this.textarea=h,this.textarea.readOnly=y,this.textarea.oninput===null?this.textarea.oninput=this._onChange.bind(this):this.textarea.onchange=this._onChange.bind(this),h.onselect=this._onSelect.bind(this),h.onmousedown=this._onMouseDown.bind(this),h.onblur=this._onBlur.bind(this)),this._updateHistoryButtons(),this.errorTable=new Z.Q({errorTableVisible:this.mode==="text",onToggleVisibility:function(){g._validateAndCatch()},onFocusLine:function(w){g.isFocused=!0,isNaN(w)||g.setTextSelection({row:w,column:1},{row:w,column:1e3})},onChangeHeight:function(w){w=w+(g.dom.statusBar?g.dom.statusBar.clientHeight:0)+1,g.content.style.marginBottom=-w+"px",g.content.style.paddingBottom=w+"px"}}),this.frame.appendChild(this.errorTable.getErrorTable()),v.statusBar&&((0,p.addClassName)(this.content,"has-status-bar"),this.curserInfoElements={},d=document.createElement("div"),(this.dom.statusBar=d).className="jsoneditor-statusbar",this.frame.appendChild(d),(y=document.createElement("span")).className="jsoneditor-curserinfo-label",y.innerText="Ln:",(h=document.createElement("span")).className="jsoneditor-curserinfo-val",h.innerText="1",d.appendChild(y),d.appendChild(h),(v=document.createElement("span")).className="jsoneditor-curserinfo-label",v.innerText="Col:",(y=document.createElement("span")).className="jsoneditor-curserinfo-val",y.innerText="1",d.appendChild(v),d.appendChild(y),this.curserInfoElements.colVal=y,this.curserInfoElements.lnVal=h,(v=document.createElement("span")).className="jsoneditor-curserinfo-label",v.innerText="characters selected",v.style.display="none",(y=document.createElement("span")).className="jsoneditor-curserinfo-count",y.innerText="0",y.style.display="none",this.curserInfoElements.countLabel=v,this.curserInfoElements.countVal=y,d.appendChild(y),d.appendChild(v),d.appendChild(this.errorTable.getErrorCounter()),d.appendChild(this.errorTable.getWarningIcon()),d.appendChild(this.errorTable.getErrorIcon())),this.setSchema(this.options.schema,this.options.schemaRefs)},t._onSchemaChange=function(a,o){this.aceEditor&&(this.options.allowSchemaSuggestions&&a?(this.aceEditor.setOption("enableBasicAutocompletion",[new s(a,o)]),this.aceEditor.setOption("enableLiveAutocompletion",!0)):(this.aceEditor.setOption("enableBasicAutocompletion",void 0),this.aceEditor.setOption("enableLiveAutocompletion",!1)))},t._onChange=function(){var a=this;if(!this.onChangeDisabled){if(setTimeout(function(){a._updateHistoryButtons&&a._updateHistoryButtons()}),this._debouncedValidate(),this.options.onChange)try{this.options.onChange()}catch(o){console.error("Error in onChange callback: ",o)}if(this.options.onChangeText)try{this.options.onChangeText(this.getText())}catch(o){console.error("Error in onChangeText callback: ",o)}}},t._updateHistoryButtons=function(){var a;this.aceEditor&&this.dom.undo&&this.dom.redo&&(a=this.aceEditor.getSession().getUndoManager())&&a.hasUndo&&a.hasRedo&&(this.dom.undo.disabled=!a.hasUndo(),this.dom.redo.disabled=!a.hasRedo())},t._showSortModal=function(){try{var a=this,o=this.options.modalAnchor||N.qD,c=this.get();(0,C.showSortModal)(o,c,function(h){var A;Array.isArray(c)&&(A=(0,p.sort)(c,h.path,h.direction),a.sortedBy=h,a.update(A)),(0,p.isObject)(c)&&(A=(0,p.sortObjectKeys)(c,h.direction),a.sortedBy=h,a.update(A))},a.sortedBy)}catch(h){this._onError(h)}},t._showTransformModal=function(){var a=this;try{var o=this.options,c=o.modalAnchor,h=o.createQuery,A=o.executeQuery,v=o.queryDescription,d=this.get();(0,m.showTransformModal)({container:c||N.qD,json:d,queryDescription:v,createQuery:h,executeQuery:A,onTransform:function(g){g=A(d,g),a.update(g)}})}catch(g){this._onError(g)}},t._onSelect=function(){this._updateCursorInfo(),this._emitSelectionChange()},t._onKeyDown=function(a){var o=!1;(a.which||a.keyCode)===73&&a.ctrlKey&&(a.shiftKey?this.compact():this.format(),this._onChange(),o=!0),o&&(a.preventDefault(),a.stopPropagation()),this._updateCursorInfo(),this._emitSelectionChange()},t._onMouseDown=function(){this._updateCursorInfo(),this._emitSelectionChange()},t._onBlur=function(){var a=this;setTimeout(function(){a.isFocused||(a._updateCursorInfo(),a._emitSelectionChange()),a.isFocused=!1})},t._updateCursorInfo=function(){var a,o,c,h,A,v=this;function d(){v.curserInfoElements.countVal.innerText!==A&&(v.curserInfoElements.countVal.innerText=A,v.curserInfoElements.countVal.style.display=A?"inline":"none",v.curserInfoElements.countLabel.style.display=A?"inline":"none"),v.curserInfoElements.lnVal.innerText=c,v.curserInfoElements.colVal.innerText=h}this.textarea?setTimeout(function(){var g=(0,p.getInputSelection)(v.textarea);g.startIndex!==g.endIndex&&(A=g.endIndex-g.startIndex),h=(A&&v.cursorInfo&&v.cursorInfo.line===g.end.row&&v.cursorInfo.column===g.end.column?(c=g.start.row,g.start):(c=g.end.row,g.end)).column,v.cursorInfo={line:c,column:h,count:A},v.options.statusBar&&d()},0):this.aceEditor&&this.curserInfoElements&&(a=this.aceEditor.getCursorPosition(),o=this.aceEditor.getSelectedText(),c=a.row+1,h=a.column+1,A=o.length,v.cursorInfo={line:c,column:h,count:A},this.options.statusBar&&d())},t._emitSelectionChange=function(){var a;this._selectionChangedHandler&&(a=this.getTextSelection(),this._selectionChangedHandler(a.start,a.end,a.text))},t._refreshAnnotations=function(){var a,o=this.aceEditor&&this.aceEditor.getSession();o&&(a=o.getAnnotations().filter(function(c){return c.type==="error"}),o.setAnnotations(a))},t.destroy=function(){this.aceEditor&&(this.aceEditor.destroy(),this.aceEditor=null),this.frame&&this.container&&this.frame.parentNode===this.container&&this.container.removeChild(this.frame),this.modeSwitcher&&(this.modeSwitcher.destroy(),this.modeSwitcher=null),this.textarea=null,this._debouncedValidate=null,this.frameFocusTracker.destroy()},t.compact=function(){var a=this.get(),a=JSON.stringify(a);this.updateText(a)},t.format=function(){var a=this.get(),a=JSON.stringify(a,null,this.indentation);this.updateText(a)},t.repair=function(){var a=this.getText();try{var o=X()(a);this.updateText(o)}catch{}},t.focus=function(){this.textarea&&this.textarea.focus(),this.aceEditor&&this.aceEditor.focus()},t.resize=function(){this.aceEditor&&this.aceEditor.resize(!1)},t.set=function(a){this.setText(JSON.stringify(a,null,this.indentation))},t.update=function(a){this.updateText(JSON.stringify(a,null,this.indentation))},t.get=function(){var a=this.getText();return(0,p.parse)(a)},t.getText=function(){return this.textarea?this.textarea.value:this.aceEditor?this.aceEditor.getValue():""},t._setText=function(A,o){var c,h=this,A=this.options.escapeUnicode===!0?(0,p.escapeUnicodeChars)(A):A;this.textarea&&(this.textarea.value=A),this.aceEditor&&(this.onChangeDisabled=!0,this.aceEditor.setValue(A,-1),this.onChangeDisabled=!1,o&&(c=this,setTimeout(function(){c.aceEditor&&c.aceEditor.session.getUndoManager().reset()})),setTimeout(function(){h._updateHistoryButtons&&h._updateHistoryButtons()})),this._debouncedValidate()},t.setText=function(a){this._setText(a,!0)},t.updateText=function(a){this.getText()!==a&&this._setText(a,!1)},t.validate=function(){var a,o=this,c=[],h=[];try{var A=this.get(),v=(this.validateSchema&&!this.validateSchema(A)&&(c=this.validateSchema.errors.map(function(g){return g.type="validation",(0,p.improveSchemaError)(g)})),this.validationSequence=(this.validationSequence||0)+1,this),d=this.validationSequence;return function(g,y){if(!y)return Promise.resolve([]);try{var w=y(g);return((0,p.isPromise)(w)?w:Promise.resolve(w)).then(function(I){return Array.isArray(I)?I.filter(function(T){var B=(0,p.isValidValidationError)(T);return B||console.warn('Ignoring a custom validation error with invalid structure. Expected structure: {path: [...], message: "..."}. Actual error:',T),B}).map(function(T){return{dataPath:(0,p.stringifyPath)(T.path),message:T.message,type:"customValidation"}}):[]})}catch(I){return Promise.reject(I)}}(A,this.options.onValidate).then(function(g){return d===v.validationSequence&&(g=c.concat(h).concat(g),v._renderErrors(g),typeof o.options.onValidationError=="function"&&(0,p.isValidationErrorChanged)(g,o.lastSchemaErrors)&&o.options.onValidationError.call(o,g),o.lastSchemaErrors=g),o.lastSchemaErrors})}catch(g){return this.getText()&&((A=/\w*line\s*(\d+)\w*/g.exec(g.message))&&(a=+A[1]),h=[{type:"error",message:g.message.replace(/\n/g,"<br>"),line:a}]),this._renderErrors(h),typeof this.options.onValidationError=="function"&&(0,p.isValidationErrorChanged)(h,this.lastSchemaErrors)&&this.options.onValidationError.call(this,h),this.lastSchemaErrors=h,Promise.resolve(this.lastSchemaErrors)}},t._validateAndCatch=function(){this.validate().catch(function(a){console.error("Error running validation:",a)})},t._renderErrors=function(a){var c=this.getText(),o=[],c=(a.reduce(function(h,A){return typeof A.dataPath=="string"&&h.indexOf(A.dataPath)===-1&&h.push(A.dataPath),h},o),(0,p.getPositionForPath)(c,o));this.aceEditor&&(this.annotations=c.map(function(h){var A=a.filter(function(d){return d.dataPath===h.path}),v=A.map(function(d){return d.message}).join(`
`);return v?{row:h.line,column:h.column,text:"Schema validation error"+(A.length!==1?"s":"")+`: 
`+v,type:"warning",source:"jsoneditor"}:{}}),this._refreshAnnotations()),this.errorTable.setErrors(a,c),this.aceEditor&&this.aceEditor.resize(!1)},t.getTextSelection=function(){var a,o,c,h={};return this.textarea?(c=(0,p.getInputSelection)(this.textarea),this.cursorInfo&&this.cursorInfo.line===c.end.row&&this.cursorInfo.column===c.end.column?(h.start=c.end,h.end=c.start):h=c,{start:h.start,end:h.end,text:this.textarea.value.substring(c.startIndex,c.endIndex)}):this.aceEditor?(c=this.aceEditor.getSelection(),a=this.aceEditor.getSelectedText(),o=c.getRange(),(c=c.getSelectionLead()).row===o.end.row&&c.column===o.end.column?h=o:(h.start=o.end,h.end=o.start),{start:{row:h.start.row+1,column:h.start.column+1},end:{row:h.end.row+1,column:h.end.column+1},text:a}):void 0},t.onTextSelectionChange=function(a){typeof a=="function"&&(this._selectionChangedHandler=(0,p.debounce)(a,this.DEBOUNCE_INTERVAL))},t.setTextSelection=function(a,o){var c,h,A;a&&o&&(this.textarea?(c=(0,p.getIndexForPosition)(this.textarea,a.row,a.column),A=(0,p.getIndexForPosition)(this.textarea,o.row,o.column),-1<c&&-1<A&&(this.textarea.setSelectionRange?(this.textarea.focus(),this.textarea.setSelectionRange(c,A)):this.textarea.createTextRange&&((h=this.textarea.createTextRange()).collapse(!0),h.moveEnd("character",A),h.moveStart("character",c),h.select()),A=(this.textarea.value.match(/\n/g)||[]).length+1,c=this.textarea.scrollHeight/A,h=a.row*c,this.textarea.scrollTop=h>this.textarea.clientHeight?h-this.textarea.clientHeight/2:0)):this.aceEditor&&(A={start:{row:a.row-1,column:a.column-1},end:{row:o.row-1,column:o.column-1}},this.aceEditor.selection.setRange(A),this.aceEditor.scrollToLine(a.row-1,!0)))};var r=[{mode:"text",mixin:t,data:"text",load:e},{mode:"code",mixin:t,data:"text",load:e}]},8038:function(ie,j,D){D.r(j),D.d(j,{treeModeMixins:function(){return Y}});var X={start:function(R,H,G){return H.indexOf(R)===0},contain:function(R,H,G){return-1<H.indexOf(R)}},k=D(897),N=D(2474);function Z(R,H){for(var G=0;G<H.length;G++){var f=H[G];f.enumerable=f.enumerable||!1,f.configurable=!0,"value"in f&&(f.writable=!0),Object.defineProperty(R,f.key,f)}}var O=function(){function R(){if(!(this instanceof R))throw new TypeError("Cannot call a class as a function");this.locked=!1}var H,G;return H=R,(G=[{key:"highlight",value:function(f){this.locked||(this.node!==f&&(this.node&&this.node.setHighlight(!1),this.node=f,this.node.setHighlight(!0)),this._cancelUnhighlight())}},{key:"unhighlight",value:function(){var f;this.locked||(f=this).node&&(this._cancelUnhighlight(),this.unhighlightTimer=setTimeout(function(){f.node.setHighlight(!1),f.node=void 0,f.unhighlightTimer=void 0},0))}},{key:"_cancelUnhighlight",value:function(){this.unhighlightTimer&&(clearTimeout(this.unhighlightTimer),this.unhighlightTimer=void 0)}},{key:"lock",value:function(){this.locked=!0}},{key:"unlock",value:function(){this.locked=!1}}])&&Z(H.prototype,G),Object.defineProperty(H,"prototype",{writable:!1}),R}(),W=D(7907),F=D(6056),L=D(6617),j=D(233),C=D.n(j),m=D(2602),b=D(9791),x=D(6210),p=D(2558),l=D(4188);function s(R){return function(H){if(Array.isArray(H))return e(H)}(R)||function(H){if(typeof Symbol!="undefined"&&H[Symbol.iterator]!=null||H["@@iterator"]!=null)return Array.from(H)}(R)||i(R)||function(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}()}function n(R,H){return function(G){if(Array.isArray(G))return G}(R)||function(G,f){var S=G==null?null:typeof Symbol!="undefined"&&G[Symbol.iterator]||G["@@iterator"];if(S!=null){var $,M,K=[],Q=!0,te=!1;try{for(S=S.call(G);!(Q=($=S.next()).done)&&(K.push($.value),!f||K.length!==f);Q=!0);}catch(he){te=!0,M=he}finally{try{Q||S.return==null||S.return()}finally{if(te)throw M}}return K}}(R,H)||i(R,H)||function(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}()}function t(R,H){var G,f,S,$,M=typeof Symbol!="undefined"&&R[Symbol.iterator]||R["@@iterator"];if(M)return f=!(G=!0),{s:function(){M=M.call(R)},n:function(){var K=M.next();return G=K.done,K},e:function(K){f=!0,S=K},f:function(){try{G||M.return==null||M.return()}finally{if(f)throw S}}};if(Array.isArray(R)||(M=i(R))||H&&R&&typeof R.length=="number")return M&&(R=M),$=0,{s:H=function(){},n:function(){return $>=R.length?{done:!0}:{done:!1,value:R[$++]}},e:function(K){throw K},f:H};throw new TypeError(`Invalid attempt to iterate non-iterable instance.
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function i(R,H){var G;if(R)return typeof R=="string"?e(R,H):(G=(G=Object.prototype.toString.call(R).slice(8,-1))==="Object"&&R.constructor?R.constructor.name:G)==="Map"||G==="Set"?Array.from(R):G==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(G)?e(R,H):void 0}function e(R,H){(H==null||H>R.length)&&(H=R.length);for(var G=0,f=new Array(H);G<H;G++)f[G]=R[G];return f}function r(R){return(r=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(H){return typeof H}:function(H){return H&&typeof Symbol=="function"&&H.constructor===Symbol&&H!==Symbol.prototype?"symbol":typeof H})(R)}function a(R,H){for(var G=0;G<H.length;G++){var f=H[G];f.enumerable=f.enumerable||!1,f.configurable=!0,"value"in f&&(f.writable=!0),Object.defineProperty(R,f.key,f)}}var o=function(){function R(f,S){if(!(this instanceof R))throw new TypeError("Cannot call a class as a function");this.editor=f,this.dom={},this.expanded=!1,S&&S instanceof Object?(this.setField(S.field,S.fieldEditable),"value"in S&&this.setValue(S.value,S.type),"internalValue"in S&&this.setInternalValue(S.internalValue)):(this.setField(""),this.setValue(null)),this._debouncedOnChangeValue=(0,b.debounce)(this._onChangeValue.bind(this),R.prototype.DEBOUNCE_INTERVAL),this._debouncedOnChangeField=(0,b.debounce)(this._onChangeField.bind(this),R.prototype.DEBOUNCE_INTERVAL),this.visibleChilds=this.getMaxVisibleChilds()}var H,G;return H=R,(G=[{key:"getMaxVisibleChilds",value:function(){return this.editor&&this.editor.options&&this.editor.options.maxVisibleChilds?this.editor.options.maxVisibleChilds:c}},{key:"_updateEditability",value:function(){var f,S;this.editable={field:!0,value:!0},this.editor&&(this.editable.field=this.editor.options.mode==="tree",this.editable.value=this.editor.options.mode!=="view",this.editor.options.mode!=="tree"&&this.editor.options.mode!=="form"||typeof this.editor.options.onEditable!="function"||(f=this.getValue.bind(this),typeof(S=this.editor.options.onEditable({field:this.field,get value(){return f()},path:this.getPath()}))=="boolean"?(this.editable.field=S,this.editable.value=S):r(S)==="object"&&S!==null?(typeof S.field=="boolean"&&(this.editable.field=S.field),typeof S.value=="boolean"&&(this.editable.value=S.value)):(console.error("Invalid return value for function onEditable.","Actual value:",S,".","Either a boolean or object { field: boolean, value: boolean } expected."),this.editable.field=!1,this.editable.value=!1)))}},{key:"getPath",value:function(){for(var f=this,S=[];f;){var $=f.getName();$!==void 0&&S.unshift($),f=f.parent}return S}},{key:"getInternalPath",value:function(){for(var f=this,S=[];f;)f.parent&&S.unshift(f.getIndex()),f=f.parent;return S}},{key:"getName",value:function(){return this.parent?this.parent.type!=="array"?this.field:this.index:void 0}},{key:"findNodeByPath",value:function(f){if(f){if(f.length===0)return this;if(f.length&&this.childs&&this.childs.length){for(var S=0;S<this.childs.length;++S)if(""+f[0]==""+this.childs[S].getName())return this.childs[S].findNodeByPath(f.slice(1))}}}},{key:"findNodeByInternalPath",value:function(f){if(f){for(var M=this,S=0;S<f.length&&M;S++)var $=f[S],M=M.childs[$];return M}}},{key:"serialize",value:function(){return{value:this.getValue(),path:this.getPath()}}},{key:"findNode",value:function(f){for(var S=(0,b.parsePath)(f),$=this;$&&0<S.length;)(function(){var M=S.shift();if(typeof M=="number"){if($.type!=="array")throw new Error("Cannot get child node at index "+M+": node is no array");$=$.childs[M]}else{if($.type!=="object")throw new Error("Cannot get child node "+M+": node is no object");$=$.childs.filter(function(K){return K.field===M})[0]}})();return $}},{key:"findParents",value:function(){for(var f=[],S=this.parent;S;)f.unshift(S),S=S.parent;return f}},{key:"setError",value:function(f,S){this.error=f,this.errorChild=S,this.dom&&this.dom.tr&&this.updateError()}},{key:"updateError",value:function(){var f=this,S=this.fieldError||this.valueError||this.error,$=this.dom.tdError;if(S&&this.dom&&this.dom.tr){(0,b.addClassName)(this.dom.tr,"jsoneditor-validation-error"),$||($=document.createElement("td"),this.dom.tdError=$,this.dom.tdValue.parentNode.appendChild($));var M=document.createElement("button"),K=(M.type="button",M.className="jsoneditor-button jsoneditor-schema-error",function(){f.dom.popupAnchor&&f.dom.popupAnchor.destroy()}),Q=function(){delete f.dom.popupAnchor},te=function(Ce){var ge=f.editor.frame,Ce=(f.dom.popupAnchor=(0,m.w)(M,f.editor.getPopupAnchor(),Q,Ce),M.getBoundingClientRect()),ge=120<ge.getBoundingClientRect().width-Ce.x?"jsoneditor-above":"jsoneditor-left",Ce=document.createElement("div");Ce.className="jsoneditor-popover "+ge,Ce.appendChild(document.createTextNode(S.message)),f.dom.popupAnchor.appendChild(Ce)},he=(M.onmouseover=function(){f.dom.popupAnchor||te(!0)},M.onfocus=function(){K(),te(!1)},M.onblur=function(){K()},this.errorChild);for(he&&(M.onclick=function(){he.findParents().forEach(function(Ae){Ae.expand(!1)}),he.scrollTo(function(){he.focus()})});$.firstChild;)$.removeChild($.firstChild);$.appendChild(M)}else this.dom.tr&&(0,b.removeClassName)(this.dom.tr,"jsoneditor-validation-error"),$&&(this.dom.tdError.parentNode.removeChild(this.dom.tdError),delete this.dom.tdError)}},{key:"getIndex",value:function(){var f;return this.parent?(f=this.parent.childs.indexOf(this))!==-1?f:null:-1}},{key:"setParent",value:function(f){this.parent=f}},{key:"setField",value:function(f,S){this.field=f,this.previousField=f,this.fieldEditable=S===!0}},{key:"getField",value:function(){return this.field===void 0&&this._getDomField(),this.field}},{key:"setValue",value:function(f,S){var $,M,K,Q,te,he,Ae=this.childs;if(this.type=this._getType(f),S&&S!==this.type){if(S!=="string"||this.type!=="auto")throw new Error('Type mismatch: cannot cast value of type "'+this.type+' to the specified type "'+S+'"');this.type=S}if(this.type==="array"){for(this.childs||(this.childs=[]),$=0;$<f.length;$++)(te=f[$])===void 0||te instanceof Function||($<this.childs.length?((K=this.childs[$]).fieldEditable=!1,K.index=$,K.setValue(te)):(K=new R(this.editor,{value:te}),Q=$<this.getMaxVisibleChilds(),this.appendChild(K,Q,!1)));for(M=this.childs.length;M>=f.length;M--)this.removeChild(this.childs[M],!1)}else if(this.type==="object"){for(this.childs||(this.childs=[]),M=this.childs.length-1;0<=M;M--)v(f,this.childs[M].field)||this.removeChild(this.childs[M],!1);for(var ge in $=0,f)v(f,ge)&&((te=f[ge])===void 0||te instanceof Function||((he=this.findChildByProperty(ge))?(he.setField(ge,!0),he.setValue(te)):(he=new R(this.editor,{field:ge,value:te}),ge=$<this.getMaxVisibleChilds(),this.appendChild(he,ge,!1))),$++);!(this.value="")===this.editor.options.sortObjectKeys&&this.sort([],"asc",!1)}else this.hideChilds(),delete this.append,delete this.showMore,delete this.expanded,delete this.childs,this.value=f;Array.isArray(Ae)!==Array.isArray(this.childs)&&this.recreateDom(),this.updateDom({updateIndexes:!0}),this.previousValue=this.value}},{key:"setInternalValue",value:function(f){var S,$,M,K,Q,te=this.childs;if(this.type=f.type,f.type==="array"){for(this.childs||(this.childs=[]),K=0;K<f.childs.length;K++)(S=f.childs[K])===void 0||S instanceof Function||(K<this.childs.length?(($=this.childs[K]).fieldEditable=!1,$.index=K,$.setInternalValue(S)):($=new R(this.editor,{internalValue:S}),M=K<this.getMaxVisibleChilds(),this.appendChild($,M,!1)));for(Q=this.childs.length;Q>=f.childs.length;Q--)this.removeChild(this.childs[Q],!1)}else if(f.type==="object"){for(this.childs||(this.childs=[]),K=0;K<f.childs.length;K++)(S=f.childs[K])===void 0||S instanceof Function||(K<this.childs.length?(delete($=this.childs[K]).index,$.setField(S.field,!0),$.setInternalValue(S.value)):($=new R(this.editor,{field:S.field,internalValue:S.value}),M=K<this.getMaxVisibleChilds(),this.appendChild($,M,!1)));for(Q=this.childs.length;Q>=f.childs.length;Q--)this.removeChild(this.childs[Q],!1)}else this.hideChilds(),delete this.append,delete this.showMore,delete this.expanded,delete this.childs,this.value=f.value;Array.isArray(te)!==Array.isArray(this.childs)&&this.recreateDom(),this.updateDom({updateIndexes:!0}),this.previousValue=this.value}},{key:"recreateDom",value:function(){var f;this.dom&&this.dom.tr&&this.dom.tr.parentNode?(f=this._detachFromDom(),this.clearDom(),this._attachToDom(f)):this.clearDom()}},{key:"getValue",value:function(){var f,S;return this.type==="array"?(f=[],this.childs.forEach(function($){f.push($.getValue())}),f):this.type==="object"?(S={},this.childs.forEach(function($){S[$.getField()]=$.getValue()}),S):(this.value===void 0&&this._getDomValue(),this.value)}},{key:"getInternalValue",value:function(){return this.type==="array"?{type:this.type,childs:this.childs.map(function(f){return f.getInternalValue()})}:this.type==="object"?{type:this.type,childs:this.childs.map(function(f){return{field:f.getField(),value:f.getInternalValue()}})}:(this.value===void 0&&this._getDomValue(),{type:this.type,value:this.value})}},{key:"getLevel",value:function(){return this.parent?this.parent.getLevel()+1:0}},{key:"getNodePath",value:function(){var f=this.parent?this.parent.getNodePath():[];return f.push(this),f}},{key:"clone",value:function(){var f,S;return(f=new R(this.editor)).type=this.type,f.field=this.field,f.fieldInnerText=this.fieldInnerText,f.fieldEditable=this.fieldEditable,f.previousField=this.previousField,f.value=this.value,f.valueInnerText=this.valueInnerText,f.previousValue=this.previousValue,f.expanded=this.expanded,f.visibleChilds=this.visibleChilds,this.childs?(S=[],this.childs.forEach(function($){$=$.clone(),$.setParent(f),S.push($)}),f.childs=S):f.childs=void 0,f}},{key:"expand",value:function(f){this.childs&&(this.expanded=!0,this.dom.expand&&(this.dom.expand.className="jsoneditor-button jsoneditor-expanded"),this.showChilds(),f!==!1&&this.childs.forEach(function(S){S.expand(f)}),this.updateDom({recurse:!1}))}},{key:"collapse",value:function(f){this.childs&&(this.hideChilds(),f!==!1&&this.childs.forEach(function(S){S.collapse(f)}),this.dom.expand&&(this.dom.expand.className="jsoneditor-button jsoneditor-collapsed"),this.expanded=!1,this.updateDom({recurse:!1}))}},{key:"showChilds",value:function(){var f=this.childs;if(f&&this.expanded){var f=this.dom.tr,S=f?f.parentNode:void 0;if(S){for(var $=this.getAppendDom(),M=($.parentNode||((K=f.nextSibling)?S.insertBefore($,K):S.appendChild($)),Math.min(this.childs.length,this.visibleChilds)),K=this._getNextTr(),Q=0;Q<M;Q++){var te=this.childs[Q];te.getDom().parentNode||S.insertBefore(te.getDom(),K),te.showChilds()}f=this.getShowMoreDom(),K=this._getNextTr(),f.parentNode||S.insertBefore(f,K),this.showMore.updateDom()}}}},{key:"_getNextTr",value:function(){return this.showMore&&this.showMore.getDom().parentNode?this.showMore.getDom():this.append&&this.append.getDom().parentNode?this.append.getDom():void 0}},{key:"hide",value:function(f){var S=this.dom.tr,$=S?S.parentNode:void 0;$&&$.removeChild(S),this.dom.popupAnchor&&this.dom.popupAnchor.destroy(),this.hideChilds(f)}},{key:"hideChilds",value:function(f){var S;this.childs&&this.expanded&&((S=this.getAppendDom()).parentNode&&S.parentNode.removeChild(S),this.childs.forEach(function($){$.hide()}),(S=this.getShowMoreDom()).parentNode&&S.parentNode.removeChild(S),f&&!f.resetVisibleChilds||(this.visibleChilds=this.getMaxVisibleChilds()))}},{key:"_updateCssClassName",value:function(){var f,S;this.dom.field&&this.editor&&this.editor.options&&typeof this.editor.options.onClassName=="function"&&this.dom.tree&&((0,b.removeAllClassNames)(this.dom.tree),f=this.getValue.bind(this),S=this.editor.options.onClassName({path:this.getPath(),field:this.field,get value(){return f()}})||"",(0,b.addClassName)(this.dom.tree,"jsoneditor-values "+S))}},{key:"recursivelyUpdateCssClassesOnNodes",value:function(){if(this._updateCssClassName(),Array.isArray(this.childs))for(var f=0;f<this.childs.length;f++)this.childs[f].recursivelyUpdateCssClassesOnNodes()}},{key:"expandTo",value:function(){for(var f=this.parent;f;)f.expanded||f.expand(),f=f.parent}},{key:"appendChild",value:function(f,S,$){var M,K;this._hasChilds()&&(f.setParent(this),f.fieldEditable=this.type==="object",this.type==="array"&&(f.index=this.childs.length),this.type==="object"&&f.field===void 0&&f.setField(""),this.childs.push(f),this.expanded&&S!==!1&&(S=f.getDom(),K=(M=this._getNextTr())?M.parentNode:void 0,M&&K&&K.insertBefore(S,M),f.showChilds(),this.visibleChilds++),$!==!1&&(this.updateDom({updateIndexes:!0}),f.updateDom({recurse:!0})))}},{key:"moveBefore",value:function(f,S,$){var M,K,Q;this._hasChilds()&&((M=this.dom.tr?this.dom.tr.parentNode:void 0)&&((K=document.createElement("tr")).style.height=M.clientHeight+"px",M.appendChild(K)),f.parent&&f.parent.removeChild(f),S instanceof d||!S?this.childs.length+1>this.visibleChilds?(Q=this.childs[this.visibleChilds-1],this.insertBefore(f,Q,$)):this.appendChild(f,!0,$):this.insertBefore(f,S,$),M&&K&&M.removeChild(K))}},{key:"insertBefore",value:function(f,S,$){if(this._hasChilds()){if(this.visibleChilds++,this.type==="object"&&f.field===void 0&&f.setField(""),S===this.append)f.setParent(this),f.fieldEditable=this.type==="object",this.childs.push(f);else{var M=this.childs.indexOf(S);if(M===-1)throw new Error("Node not found");f.setParent(this),f.fieldEditable=this.type==="object",this.childs.splice(M,0,f)}var K;this.expanded&&(M=f.getDom(),K=(S=S.getDom())?S.parentNode:void 0,S&&K&&K.insertBefore(M,S),f.showChilds(),this.showChilds()),$!==!1&&(this.updateDom({updateIndexes:!0}),f.updateDom({recurse:!0}))}}},{key:"insertAfter",value:function(f,S){this._hasChilds()&&(S=this.childs.indexOf(S),(S=this.childs[S+1])?this.insertBefore(f,S):this.appendChild(f))}},{key:"search",value:function(f,S){Array.isArray(S)||(S=[]);var $=f?f.toLowerCase():void 0;return delete this.searchField,delete this.searchValue,this.field!==void 0&&S.length<=this.MAX_SEARCH_RESULTS&&(String(this.field).toLowerCase().indexOf($)!==-1&&(this.searchField=!0,S.push({node:this,elem:"field"})),this._updateDomField()),this._hasChilds()?this.childs&&this.childs.forEach(function(M){M.search(f,S)}):this.value!==void 0&&S.length<=this.MAX_SEARCH_RESULTS&&(String(this.value).toLowerCase().indexOf($)!==-1&&(this.searchValue=!0,S.push({node:this,elem:"value"})),this._updateDomValue()),S}},{key:"scrollTo",value:function(f){this.expandPathToNode(),this.dom.tr&&this.dom.tr.parentNode&&this.editor.scrollTo(this.dom.tr.offsetTop,f)}},{key:"expandPathToNode",value:function(){for(var f=this;f&&f.parent;){for(var S=f.parent.type==="array"?f.index:f.parent.childs.indexOf(f);f.parent.visibleChilds<S+1;)f.parent.visibleChilds+=this.getMaxVisibleChilds();f.parent.expand(!1),f=f.parent}}},{key:"focus",value:function(f){if(R.focusElement=f,this.dom.tr&&this.dom.tr.parentNode){var S=this.dom;switch(f){case"drag":(S.drag||S.menu).focus();break;case"menu":S.menu.focus();break;case"expand":this._hasChilds()?S.expand.focus():S.field&&this.fieldEditable?(S.field.focus(),(0,b.selectContentEditable)(S.field)):S.value&&!this._hasChilds()?(S.value.focus(),(0,b.selectContentEditable)(S.value)):S.menu.focus();break;case"field":S.field&&this.fieldEditable?(S.field.focus(),(0,b.selectContentEditable)(S.field)):S.value&&!this._hasChilds()?(S.value.focus(),(0,b.selectContentEditable)(S.value)):(this._hasChilds()?S.expand:S.menu).focus();break;default:S.select?S.select.focus():S.value&&!this._hasChilds()?(S.value.focus(),(0,b.selectContentEditable)(S.value)):S.field&&this.fieldEditable?(S.field.focus(),(0,b.selectContentEditable)(S.field)):(this._hasChilds()?S.expand:S.menu).focus()}}}},{key:"containsNode",value:function(f){if(this===f)return!0;var S=this.childs;if(S){for(var $=0,M=S.length;$<M;$++)if(S[$].containsNode(f))return!0}return!1}},{key:"removeChild",value:function(f,S){if(this.childs){var $=this.childs.indexOf(f);if($!==-1)return $<this.visibleChilds&&this.expanded&&this.visibleChilds--,f.hide(),delete f.searchField,delete f.searchValue,(f=this.childs.splice($,1)[0]).parent=null,S!==!1&&this.updateDom({updateIndexes:!0}),f}}},{key:"_remove",value:function(f){this.removeChild(f)}},{key:"changeType",value:function(f){var S,$=this.type;$!==f&&(f!=="string"&&f!=="auto"||$!=="string"&&$!=="auto"?(S=this._detachFromDom(),this.clearDom(),(this.type=f)==="object"?(this.childs||(this.childs=[]),this.childs.forEach(function(M){M.clearDom(),delete M.index,M.fieldEditable=!0,M.field===void 0&&(M.field="")}),$!=="string"&&$!=="auto"||(this.expanded=!0)):f==="array"?(this.childs||(this.childs=[]),this.childs.forEach(function(M,K){M.clearDom(),M.fieldEditable=!1,M.index=K}),$!=="string"&&$!=="auto"||(this.expanded=!0)):this.expanded=!1,this._attachToDom(S)):this.type=f,f!=="auto"&&f!=="string"||(this.value=f==="string"?String(this.value):(0,b.parseString)(String(this.value)),this.focus()),this.updateDom({updateIndexes:!0}))}},{key:"deepEqual",value:function(f){var S;if(this.type==="array"){if(!Array.isArray(f)||this.childs.length!==f.length)return!1;for(S=0;S<this.childs.length;S++)if(!this.childs[S].deepEqual(f[S]))return!1}else if(this.type==="object"){if(r(f)!=="object"||!f)return!1;var $=Object.keys(f);if(this.childs.length!==$.length)return!1;for(S=0;S<$.length;S++){var M=this.childs[S];if(M.field!==$[S]||!M.deepEqual(f[M.field]))return!1}}else if(this.value!==f)return!1;return!0}},{key:"_getDomValue",value:function(){if(this._clearValueError(),this.dom.value&&this.type!=="array"&&this.type!=="object"&&(this.valueInnerText=(0,b.getInnerText)(this.dom.value),this.valueInnerText===""&&this.dom.value.innerHTML!==""&&(this.dom.value.textContent="")),this.valueInnerText!==void 0)try{var f,S;(S=this.type==="string"?this._unescapeHTML(this.valueInnerText):(f=this._unescapeHTML(this.valueInnerText),(0,b.parseString)(f)))!==this.value&&(this.value=S,this._debouncedOnChangeValue())}catch{this._setValueError((0,W.Iu)("cannotParseValueError"))}}},{key:"_setValueError",value:function(f){this.valueError={message:f},this.updateError()}},{key:"_clearValueError",value:function(){this.valueError&&(this.valueError=null,this.updateError())}},{key:"_setFieldError",value:function(f){this.fieldError={message:f},this.updateError()}},{key:"_clearFieldError",value:function(){this.fieldError&&(this.fieldError=null,this.updateError())}},{key:"_onChangeValue",value:function(){var f,S=this.editor.getDomSelection(),$=(S.range&&($=(0,b.textDiff)(String(this.value),String(this.previousValue)),S.range.startOffset=$.start,S.range.endOffset=$.end),this.editor.getDomSelection());$.range&&(f=(0,b.textDiff)(String(this.previousValue),String(this.value)),$.range.startOffset=f.start,$.range.endOffset=f.end),this.editor._onAction("editValue",{path:this.getInternalPath(),oldValue:this.previousValue,newValue:this.value,oldSelection:S,newSelection:$}),this.previousValue=this.value}},{key:"_onChangeField",value:function(){var f=this.editor.getDomSelection(),S=this.previousField||"",$=(f.range&&($=(0,b.textDiff)(this.field,S),f.range.startOffset=$.start,f.range.endOffset=$.end),this.editor.getDomSelection());$.range&&(S=(0,b.textDiff)(S,this.field),$.range.startOffset=S.start,$.range.endOffset=S.end),this.editor._onAction("editField",{parentPath:this.parent.getInternalPath(),index:this.getIndex(),oldValue:this.previousField,newValue:this.field,oldSelection:f,newSelection:$}),this.previousField=this.field}},{key:"_updateDomValue",value:function(){var f=this.dom.value;if(f){var S=["jsoneditor-value"],$=this.value,M=this.type==="auto"?(0,b.getType)($):this.type,K=M==="string"&&(0,b.isUrl)($);if(S.push("jsoneditor-"+M),K&&S.push("jsoneditor-url"),String(this.value)===""&&this.type!=="array"&&this.type!=="object"&&S.push("jsoneditor-empty"),this.searchValueActive&&S.push("jsoneditor-highlight-active"),this.searchValue&&S.push("jsoneditor-highlight"),f.className=S.join(" "),M==="array"||M==="object"?(S=this.childs?this.childs.length:0,f.title=this.type+" containing "+S+" items"):K&&this.editable.value?f.title=(0,W.Iu)("openUrl"):f.title="",M==="boolean"&&this.editable.value?(this.dom.checkbox||(this.dom.checkbox=document.createElement("input"),this.dom.checkbox.type="checkbox",this.dom.tdCheckbox=document.createElement("td"),this.dom.tdCheckbox.className="jsoneditor-tree",this.dom.tdCheckbox.appendChild(this.dom.checkbox),this.dom.tdValue.parentNode.insertBefore(this.dom.tdCheckbox,this.dom.tdValue)),this.dom.checkbox.checked=this.value):this.dom.tdCheckbox&&(this.dom.tdCheckbox.parentNode.removeChild(this.dom.tdCheckbox),delete this.dom.tdCheckbox,delete this.dom.checkbox),this.enum&&this.editable.value?(this.dom.select||(this.dom.select=document.createElement("select"),this.id=this.field+"_"+new Date().getUTCMilliseconds(),this.dom.select.id=this.id,this.dom.select.name=this.dom.select.id,(S=document.createElement("option")).value="",S.textContent="--",this.dom.select.appendChild(S),this._updateEnumOptions(),this.dom.tdSelect=document.createElement("td"),this.dom.tdSelect.className="jsoneditor-tree",this.dom.tdSelect.appendChild(this.dom.select),this.dom.tdValue.parentNode.insertBefore(this.dom.tdSelect,this.dom.tdValue)),this.dom.select.value=this.enum.indexOf(this.value)!==-1?this.value:"",!this.schema||v(this.schema,"oneOf")||v(this.schema,"anyOf")||v(this.schema,"allOf")?delete this.valueFieldHTML:(this.valueFieldHTML=this.dom.tdValue.innerHTML,this.dom.tdValue.style.visibility="hidden",this.dom.tdValue.textContent="")):this.dom.tdSelect&&(this.dom.tdSelect.parentNode.removeChild(this.dom.tdSelect),delete this.dom.tdSelect,delete this.dom.select,this.dom.tdValue.innerHTML=this.valueFieldHTML,this.dom.tdValue.style.visibility="",delete this.valueFieldHTML,this.dom.tdValue.appendChild(this.dom.value)),this.editor.options.colorPicker&&typeof $=="string"&&(0,b.isValidColor)($)?(this.dom.color||(this.dom.color=document.createElement("div"),this.dom.color.className="jsoneditor-color",this.dom.tdColor=document.createElement("td"),this.dom.tdColor.className="jsoneditor-tree",this.dom.tdColor.appendChild(this.dom.color),this.dom.tdValue.parentNode.insertBefore(this.dom.tdColor,this.dom.tdValue)),(0,b.addClassName)(this.dom.value,"jsoneditor-color-value"),(this.editable.value?b.removeClassName:b.addClassName)(this.dom.color,"jsoneditor-color-readonly"),this.dom.color.style.backgroundColor=$):this._deleteDomColor(),this._showTimestampTag()){if(this.dom.date||(this.dom.date=document.createElement("div"),this.dom.date.className="jsoneditor-date",this.dom.value.parentNode.appendChild(this.dom.date)),K=null,K=typeof this.editor.options.timestampFormat=="function"?this.editor.options.timestampFormat({field:this.field,value:this.value,path:this.getPath()}):K){for(;this.dom.date.firstChild;)this.dom.date.removeChild(this.dom.date.firstChild);this.dom.date.appendChild(document.createTextNode(K))}else this.dom.date.textContent=new Date($).toISOString();this.dom.date.title=new Date($).toString()}else this.dom.date&&(this.dom.date.parentNode.removeChild(this.dom.date),delete this.dom.date);(0,b.stripFormatting)(f),this._updateDomDefault()}}},{key:"_updateEnumOptions",value:function(){if(this.enum&&this.dom.select){this.dom.select.innerHTML="";for(var f=0;f<this.enum.length;f++){var S=document.createElement("option");S.value=this.enum[f],S.textContent=this.enum[f],this.dom.select.appendChild(S)}}}},{key:"_deleteDomColor",value:function(){this.dom.color&&(this.dom.tdColor.parentNode.removeChild(this.dom.tdColor),delete this.dom.tdColor,delete this.dom.color,(0,b.removeClassName)(this.dom.value,"jsoneditor-color-value"))}},{key:"_updateDomField",value:function(){var f,S=this.dom.field;S&&((f=(0,b.makeFieldTooltip)(this.schema,this.editor.options.language))&&(S.title=f),(String(this.field)===""&&this.parent&&this.parent.type!=="array"?b.addClassName:b.removeClassName)(S,"jsoneditor-empty"),(this.searchFieldActive?b.addClassName:b.removeClassName)(S,"jsoneditor-highlight-active"),(this.searchField?b.addClassName:b.removeClassName)(S,"jsoneditor-highlight"),(0,b.stripFormatting)(S))}},{key:"_getDomField",value:function(f){if(this._clearFieldError(),this.dom.field&&this.fieldEditable&&(this.fieldInnerText=(0,b.getInnerText)(this.dom.field),this.fieldInnerText===""&&this.dom.field.innerHTML!==""&&(this.dom.field.textContent="")),this.fieldInnerText!==void 0)try{var S=this._unescapeHTML(this.fieldInnerText),$=this.parent.getFieldNames(this);$.indexOf(S)!==-1?f?(S=(0,b.findUniqueName)(S,$))!==this.field&&(this.field=S,this._debouncedOnChangeField()):this._setFieldError((0,W.Iu)("duplicateFieldError")):S!==this.field&&(this.field=S,this._debouncedOnChangeField())}catch{this._setFieldError((0,W.Iu)("cannotParseFieldError"))}}},{key:"_updateDomDefault",value:function(){var f;this.schema&&this.schema.default!==void 0&&!this._hasChilds()&&(f=this.dom.select||this.dom.value)&&(this.value===this.schema.default?(f.title=(0,W.Iu)("default"),(0,b.addClassName)(f,"jsoneditor-is-default"),b.removeClassName):(f.removeAttribute("title"),(0,b.removeClassName)(f,"jsoneditor-is-default"),b.addClassName))(f,"jsoneditor-is-not-default")}},{key:"_showTimestampTag",value:function(){var f,S;return typeof this.value=="number"&&(typeof(f=this.editor.options.timestampTag)=="function"?typeof(S=f({field:this.field,value:this.value,path:this.getPath()}))=="boolean"?S:(0,b.isTimestamp)(this.field,this.value):f===!0&&(0,b.isTimestamp)(this.field,this.value))}},{key:"clearDom",value:function(){this.dom={}}},{key:"getDom",value:function(){var f,S,$=this.dom;return $.tr||(this._updateEditability(),$.tr=document.createElement("tr"),($.tr.node=this).editor.options.mode==="tree"&&(S=document.createElement("td"),this.editable.field&&this.parent&&((f=document.createElement("button")).type="button",($.drag=f).className="jsoneditor-button jsoneditor-dragarea",f.title=(0,W.Iu)("drag"),S.appendChild(f)),$.tr.appendChild(S),f=document.createElement("td"),(S=document.createElement("button")).type="button",($.menu=S).className="jsoneditor-button jsoneditor-contextmenu-button",S.title=(0,W.Iu)("actionsMenu"),f.appendChild($.menu),$.tr.appendChild(f)),S=document.createElement("td"),$.tr.appendChild(S),$.tree=this._createDomTree(),S.appendChild($.tree),this.updateDom({updateIndexes:!0})),$.tr}},{key:"isVisible",value:function(){return this.dom&&this.dom.tr&&this.dom.tr.parentNode||!1}},{key:"isDescendantOf",value:function(f){for(var S=this.parent;S;){if(S===f)return!0;S=S.parent}return!1}},{key:"_createDomField",value:function(){return document.createElement("div")}},{key:"setHighlight",value:function(f){this.dom.tr&&((f?b.addClassName:b.removeClassName)(this.dom.tr,"jsoneditor-highlight"),this.append&&this.append.setHighlight(f),this.childs&&this.childs.forEach(function(S){S.setHighlight(f)}))}},{key:"setSelected",value:function(f,S){this.selected=f,this.dom.tr&&((f?b.addClassName:b.removeClassName)(this.dom.tr,"jsoneditor-selected"),(S?b.addClassName:b.removeClassName)(this.dom.tr,"jsoneditor-first"),this.append&&this.append.setSelected(f),this.showMore&&this.showMore.setSelected(f),this.childs&&this.childs.forEach(function($){$.setSelected(f)}))}},{key:"updateValue",value:function(f){this.value=f,this.previousValue=f,this.valueError=void 0,this.updateDom()}},{key:"updateField",value:function(f){this.field=f,this.previousField=f,this.fieldError=void 0,this.updateDom()}},{key:"updateDom",value:function(f){var S,$=this.dom.tree,$=($&&($.style.marginLeft=24*this.getLevel()+"px"),this.dom.field),$=($&&(this.fieldEditable?($.contentEditable=this.editable.field,$.spellcheck=!1,$.className="jsoneditor-field"):($.contentEditable=!1,$.className="jsoneditor-readonly"),S=this.index!==void 0?this.index:this.field!==void 0?this.field:(S=this.editor.options.schema?R._findSchema(this.editor.options.schema,this.editor.options.schemaRefs||{},this.getPath()):void 0)&&S.title?S.title:this._hasChilds()?this.type:"",S=this._escapeHTML(S),document.activeElement!==$&&S!==this._unescapeHTML((0,b.getInnerText)($))&&($.innerHTML=S),this._updateSchema(),this._updateEnumOptions()),this.dom.value),$=($&&(this.type==="array"||this.type==="object"?this.updateNodeName():(S=this._escapeHTML(this.value),document.activeElement!==$&&S!==this._unescapeHTML((0,b.getInnerText)($))&&($.innerHTML=S))),this.dom.tr);$&&(this.type==="array"||this.type==="object"?((0,b.addClassName)($,"jsoneditor-expandable"),this.expanded?((0,b.addClassName)($,"jsoneditor-expanded"),(0,b.removeClassName)($,"jsoneditor-collapsed")):((0,b.addClassName)($,"jsoneditor-collapsed"),(0,b.removeClassName)($,"jsoneditor-expanded"))):((0,b.removeClassName)($,"jsoneditor-expandable"),(0,b.removeClassName)($,"jsoneditor-expanded"),(0,b.removeClassName)($,"jsoneditor-collapsed"))),this._updateDomField(),this._updateDomValue(),f&&f.updateIndexes===!0&&this._updateDomIndexes(),f&&f.recurse===!0&&this.childs&&this.childs.forEach(function(M){M.updateDom(f)}),this.error&&this.updateError(),this.append&&this.append.updateDom(),this.showMore&&this.showMore.updateDom(),this._updateCssClassName()}},{key:"_updateSchema",value:function(){this.editor&&this.editor.options&&(this.schema=this.editor.options.schema?R._findSchema(this.editor.options.schema,this.editor.options.schemaRefs||{},this.getPath()):null,this.schema?this.enum=R._findEnum(this.schema):delete this.enum)}},{key:"_updateDomIndexes",value:function(){var f=this.dom.value,S=this.childs;f&&S&&(this.type==="array"?S.forEach(function($,M){$.index=M,$=$.dom.field,$&&($.textContent=M)}):this.type==="object"&&S.forEach(function($){$.index!==void 0&&(delete $.index,$.field===void 0&&($.field=""))}))}},{key:"_createDomValue",value:function(){var f;return this.type==="array"?(f=document.createElement("div")).textContent="[...]":this.type==="object"?(f=document.createElement("div")).textContent="{...}":(!this.editable.value&&(0,b.isUrl)(this.value)?(f=document.createElement("a")).href=this.value:((f=document.createElement("div")).contentEditable=this.editable.value,f.spellcheck=!1),f.innerHTML=this._escapeHTML(this.value)),f}},{key:"_createDomExpandButton",value:function(){var f=document.createElement("button");return f.type="button",this._hasChilds()?(f.className=this.expanded?"jsoneditor-button jsoneditor-expanded":"jsoneditor-button jsoneditor-collapsed",f.title=(0,W.Iu)("expandTitle")):(f.className="jsoneditor-button jsoneditor-invisible",f.title=""),f}},{key:"_createDomTree",value:function(){var f=this.dom,S=document.createElement("table"),M=document.createElement("tbody"),$=(S.style.borderCollapse="collapse",S.className="jsoneditor-values",S.appendChild(M),document.createElement("tr")),M=(M.appendChild($),document.createElement("td")),M=(M.className="jsoneditor-tree",$.appendChild(M),f.expand=this._createDomExpandButton(),M.appendChild(f.expand),f.tdExpand=M,document.createElement("td")),M=(M.className="jsoneditor-tree",$.appendChild(M),f.field=this._createDomField(),M.appendChild(f.field),f.tdField=M,document.createElement("td")),M=(M.className="jsoneditor-tree",$.appendChild(M),this.type!=="object"&&this.type!=="array"&&(M.appendChild(document.createTextNode(":")),M.className="jsoneditor-separator"),f.tdSeparator=M,document.createElement("td"));return M.className="jsoneditor-tree",$.appendChild(M),f.value=this._createDomValue(),M.appendChild(f.value),f.tdValue=M,S}},{key:"onEvent",value:function(f){var S,$=f.type,M=f.target||f.srcElement,K=this.dom,Q=this,te=this._hasChilds(),he=(M!==K.drag&&M!==K.menu||($==="mouseover"?this.editor.highlighter.highlight(this):$==="mouseout"&&this.editor.highlighter.unhighlight()),$==="click"&&M===K.menu&&((S=Q.editor.highlighter).highlight(Q),S.lock(),(0,b.addClassName)(K.menu,"jsoneditor-selected"),this.showContextMenu(K.menu,function(){(0,b.removeClassName)(K.menu,"jsoneditor-selected"),S.unlock(),S.unhighlight()})),$==="click"&&M===K.expand&&te&&(ve=f.ctrlKey,this._onExpand(ve)),$!=="click"||f.target!==Q.dom.tdColor&&f.target!==Q.dom.color||!this.editable.value||this._showColorPicker(),$==="change"&&M===K.checkbox&&(this.dom.value.textContent=String(!this.value),this._getDomValue(),this._updateDomDefault()),$==="change"&&M===K.select&&(this.dom.value.innerHTML=this._escapeHTML(K.select.value),this._getDomValue(),this._updateDomValue()),K.value);if(M===he)switch($){case"blur":case"change":this._getDomValue(),this._clearValueError(),this._updateDomValue();var Ae=this._escapeHTML(this.value);Ae!==this._unescapeHTML((0,b.getInnerText)(he))&&(he.innerHTML=Ae);break;case"input":this._getDomValue(),this._updateDomValue();break;case"keydown":case"mousedown":this.editor.selection=this.editor.getDomSelection();break;case"click":f.ctrlKey&&this.editable.value&&(0,b.isUrl)(this.value)&&(f.preventDefault(),window.open(this.value,"_blank","noreferrer"));break;case"keyup":this._getDomValue(),this._updateDomValue();break;case"cut":case"paste":setTimeout(function(){Q._getDomValue(),Q._updateDomValue()},1)}var ge=K.field;if(M===ge)switch($){case"blur":this._getDomField(!0),this._updateDomField();var Ce=this._escapeHTML(this.field);Ce!==this._unescapeHTML((0,b.getInnerText)(ge))&&(ge.innerHTML=Ce);break;case"input":this._getDomField(),this._updateSchema(),this._updateDomField(),this._updateDomValue();break;case"keydown":case"mousedown":this.editor.selection=this.editor.getDomSelection();break;case"keyup":this._getDomField(),this._updateDomField();break;case"cut":case"paste":setTimeout(function(){Q._getDomField(),Q._updateDomField()},1)}var ve=K.tree;ve&&M===ve.parentNode&&$==="click"&&!f.hasMoved&&((f.offsetX!==void 0?f.offsetX<24*(this.getLevel()+1):f.pageX<(0,b.getAbsoluteLeft)(K.tdSeparator))||te?ge&&((0,b.setEndOfContentEditable)(ge),ge.focus()):he&&!this.enum&&((0,b.setEndOfContentEditable)(he),he.focus())),(M!==K.tdExpand||te)&&M!==K.tdField&&M!==K.tdSeparator||$!=="click"||f.hasMoved||ge&&((0,b.setEndOfContentEditable)(ge),ge.focus()),$==="keydown"&&this.onKeyDown(f),typeof this.editor.options.onEvent=="function"&&this._onEvent(f)}},{key:"_onEvent",value:function(f){var $=f.target,S=$===this.dom.field,$=$===this.dom.value||$===this.dom.checkbox||$===this.dom.select;(S||$)&&(S={field:this.getField(),path:this.getPath()},$&&!this._hasChilds()&&(S.value=this.getValue()),this.editor.options.onEvent(S,f))}},{key:"onKeyDown",value:function(f){var S,$,M,K,Q,te,he,Ae,ge,Ce,ve,ye,Te,_e,Se=f.which||f.keyCode,ue=f.target||f.srcElement,$e=f.ctrlKey,ae=f.shiftKey,pe=f.altKey,ce=!1,de=this.editor.options.mode==="tree",fe=0<this.editor.multiselection.nodes.length?this.editor.multiselection.nodes:[this],be=fe[0],ke=fe[fe.length-1];Se===13?ue===this.dom.value?this.editable.value&&!f.ctrlKey||(0,b.isUrl)(this.value)&&(window.open(this.value,"_blank","noreferrer"),ce=!0):ue===this.dom.expand&&this._hasChilds()&&(Te=f.ctrlKey,this._onExpand(Te),ue.focus(),ce=!0):Se===68?$e&&de&&(R.onDuplicate(fe),ce=!0):Se===69?$e&&(this._onExpand(ae),ue.focus(),ce=!0):Se===77&&de?$e&&(this.showContextMenu(ue),ce=!0):Se===46&&de?$e&&(R.onRemove(fe),ce=!0):Se===45&&de?$e&&!ae?(this._onInsertBefore(),ce=!0):$e&&ae&&(this._onInsertAfter(),ce=!0):Se===35?pe&&((Te=this._lastNode())&&Te.focus(R.focusElement||this._getElementName(ue)),ce=!0):Se===36?pe&&((Te=this._firstNode())&&Te.focus(R.focusElement||this._getElementName(ue)),ce=!0):Se===37?pe&&!ae?((Te=this._previousElement(ue))&&this.focus(this._getElementName(Te)),ce=!0):pe&&ae&&de&&(Te=ke.expanded?(Te=ke.getAppendDom())?Te.nextSibling:void 0:ke.getDom().nextSibling)&&(ve=R.getNodeFromTarget(Te),Te=Te.nextSibling,ye=R.getNodeFromTarget(Te),ve&&ve instanceof d&&ke.parent.childs.length!==1&&ye&&ye.parent&&($=this.editor.getDomSelection(),M=(K=be.parent).childs[ke.getIndex()+1]||K.append,Q=be.getIndex(),te=ye.getIndex(),he=K.getInternalPath(),Ae=ye.parent.getInternalPath(),fe.forEach(function(Me){ye.parent.moveBefore(Me,ye)}),this.focus(R.focusElement||this._getElementName(ue)),this.editor._onAction("moveNodes",{count:fe.length,fieldNames:fe.map(A),oldParentPath:K.getInternalPath(),newParentPath:be.parent.getInternalPath(),oldIndex:M.getIndex(),newIndex:be.getIndex(),oldIndexRedo:Q,newIndexRedo:te,oldParentPathRedo:he,newParentPathRedo:Ae,oldSelection:$,newSelection:this.editor.getDomSelection()}))):Se===38?pe&&!ae?((S=this._previousNode())&&(this.editor.deselect(!0),S.focus(R.focusElement||this._getElementName(ue))),ce=!0):!pe&&$e&&ae&&de?((S=this._previousNode())&&((Ce=this.editor.multiselection).start=Ce.start||this,Ce.end=S,ge=this.editor._findTopLevelNodes(Ce.start,Ce.end),this.editor.select(ge),S.focus("field")),ce=!0):pe&&ae&&de&&((S=be._previousNode())&&S.parent&&($=this.editor.getDomSelection(),M=(K=be.parent).childs[ke.getIndex()+1]||K.append,Q=be.getIndex(),te=S.getIndex(),he=K.getInternalPath(),Ae=S.parent.getInternalPath(),fe.forEach(function(Me){S.parent.moveBefore(Me,S)}),this.focus(R.focusElement||this._getElementName(ue)),this.editor._onAction("moveNodes",{count:fe.length,fieldNames:fe.map(A),oldParentPath:K.getInternalPath(),newParentPath:be.parent.getInternalPath(),oldIndex:M.getIndex(),newIndex:be.getIndex(),oldIndexRedo:Q,newIndexRedo:te,oldParentPathRedo:he,newParentPathRedo:Ae,oldSelection:$,newSelection:this.editor.getDomSelection()})),ce=!0):Se===39?pe&&!ae?((Te=this._nextElement(ue))&&this.focus(this._getElementName(Te)),ce=!0):pe&&ae&&de&&(Te=be.getDom().previousSibling)&&(S=R.getNodeFromTarget(Te))&&S.parent&&!S.isVisible()&&($=this.editor.getDomSelection(),M=(K=be.parent).childs[ke.getIndex()+1]||K.append,Q=be.getIndex(),te=S.getIndex(),he=K.getInternalPath(),Ae=S.parent.getInternalPath(),fe.forEach(function(Me){S.parent.moveBefore(Me,S)}),this.focus(R.focusElement||this._getElementName(ue)),this.editor._onAction("moveNodes",{count:fe.length,fieldNames:fe.map(A),oldParentPath:K.getInternalPath(),newParentPath:be.parent.getInternalPath(),oldIndex:M.getIndex(),newIndex:be.getIndex(),oldIndexRedo:Q,newIndexRedo:te,oldParentPathRedo:he,newParentPathRedo:Ae,oldSelection:$,newSelection:this.editor.getDomSelection()})):Se===40&&(pe&&!ae?((ve=this._nextNode())&&(this.editor.deselect(!0),ve.focus(R.focusElement||this._getElementName(ue))),ce=!0):!pe&&$e&&ae&&de?((ve=this._nextNode())&&((Ce=this.editor.multiselection).start=Ce.start||this,Ce.end=ve,ge=this.editor._findTopLevelNodes(Ce.start,Ce.end),this.editor.select(ge),ve.focus("field")),ce=!0):pe&&ae&&de&&((_e=(ve=(ve=(ve=ke.expanded?ke.append?ke.append._nextNode():void 0:ke._nextNode())&&!ve.isVisible()?ve.parent.showMore:ve)&&ve instanceof d?ke:ve)&&(ve._nextNode()||ve.parent.append))&&_e.parent&&($=this.editor.getDomSelection(),M=(K=be.parent).childs[ke.getIndex()+1]||K.append,Q=be.getIndex(),te=_e.getIndex(),he=K.getInternalPath(),Ae=_e.parent.getInternalPath(),fe.forEach(function(Me){_e.parent.moveBefore(Me,_e)}),this.focus(R.focusElement||this._getElementName(ue)),this.editor._onAction("moveNodes",{count:fe.length,fieldNames:fe.map(A),oldParentPath:K.getInternalPath(),newParentPath:be.parent.getInternalPath(),oldParentPathRedo:he,newParentPathRedo:Ae,oldIndexRedo:Q,newIndexRedo:te,oldIndex:M.getIndex(),newIndex:be.getIndex(),oldSelection:$,newSelection:this.editor.getDomSelection()})),ce=!0)),ce&&(f.preventDefault(),f.stopPropagation())}},{key:"_onExpand",value:function(f){var S,$,M;f&&(M=($=(S=this.dom.tr.parentNode).parentNode).scrollTop,$.removeChild(S)),this.expanded?this.collapse(f):this.expand(f),f&&($.appendChild(S),$.scrollTop=M),typeof this.editor.options.onExpand=="function"&&this.editor.options.onExpand({path:this.getPath(),isExpand:this.expanded,recursive:f})}},{key:"_showColorPicker",value:function(){var f,S;typeof this.editor.options.onColorPicker=="function"&&this.dom.color&&((f=this)._deleteDomColor(),f.updateDom(),S=(0,m.w)(this.dom.color,this.editor.getPopupAnchor()),this.editor.options.onColorPicker(S,this.value,function($){typeof $=="string"&&$!==f.value&&(f._deleteDomColor(),f.value=$,f.updateDom(),f._debouncedOnChangeValue())}))}},{key:"getFieldNames",value:function(f){return this.type==="object"?this.childs.filter(function(S){return S!==f}).map(function(S){return S.field}):[]}},{key:"_onInsertBefore",value:function(K,Q,te){var M=this.editor.getDomSelection(),K=new R(this.editor,{field:K!==void 0?K:"",value:Q!==void 0?Q:"",type:te}),Q=(K.expand(!0),this.getInternalPath()),te=(this.parent.insertBefore(K,this),this.editor.highlighter.unhighlight(),K.focus("field"),this.editor.getDomSelection());this.editor._onAction("insertBeforeNodes",{nodes:[K],paths:[K.getInternalPath()],beforePath:Q,parentPath:this.parent.getInternalPath(),oldSelection:M,newSelection:te})}},{key:"_onInsertAfter",value:function(K,Q,$){var M=this.editor.getDomSelection(),K=new R(this.editor,{field:K!==void 0?K:"",value:Q!==void 0?Q:"",type:$}),Q=(K.expand(!0),this.parent.insertAfter(K,this),this.editor.highlighter.unhighlight(),K.focus("field"),this.editor.getDomSelection());this.editor._onAction("insertAfterNodes",{nodes:[K],paths:[K.getInternalPath()],afterPath:this.getInternalPath(),parentPath:this.parent.getInternalPath(),oldSelection:M,newSelection:Q})}},{key:"_onAppend",value:function(K,Q,$){var M=this.editor.getDomSelection(),K=new R(this.editor,{field:K!==void 0?K:"",value:Q!==void 0?Q:"",type:$}),Q=(K.expand(!0),this.parent.appendChild(K),this.editor.highlighter.unhighlight(),K.focus("field"),this.editor.getDomSelection());this.editor._onAction("appendNodes",{nodes:[K],paths:[K.getInternalPath()],parentPath:this.parent.getInternalPath(),oldSelection:M,newSelection:Q})}},{key:"_onChangeType",value:function(f){var S,$,M=this.type;f!==M&&(S=this.editor.getDomSelection(),this.changeType(f),$=this.editor.getDomSelection(),this.editor._onAction("changeType",{path:this.getInternalPath(),oldType:M,newType:f,oldSelection:S,newSelection:$}))}},{key:"sort",value:function(f,S){var $,M,K=!(2<arguments.length&&arguments[2]!==void 0)||arguments[2];typeof f=="string"&&(f=(0,b.parsePath)(f)),this._hasChilds()&&(this.hideChilds(),$=this.childs,this.childs=this.childs.concat(),M=S==="desc"?-1:1,this.type==="object"?this.childs.sort(function(Q,te){return M*C()(Q.field,te.field)}):this.childs.sort(function(he,Ae){var he=he.getNestedChild(f),Ae=Ae.getNestedChild(f);return he?Ae?(he=he.value,Ae=Ae.value,typeof he!="string"&&typeof Ae!="string"?Ae<he?M:he<Ae?-M:0:M*C()(he,Ae)):-M:M}),this._updateDomIndexes(),this.showChilds(),K===!0&&this.editor._onAction("sort",{path:this.getInternalPath(),oldChilds:$,newChilds:this.childs}))}},{key:"update",value:function(f){var S=this.getInternalValue();this.setValue(f),this.editor._onAction("transform",{path:this.getInternalPath(),oldValue:S,newValue:this.getInternalValue()})}},{key:"_detachFromDom",value:function(){var f=this.dom.tr?this.dom.tr.parentNode:void 0,S=this.expanded?this.getAppendDom():this.getDom(),S=S&&S.parentNode?S.nextSibling:void 0;return this.hide({resetVisibleChilds:!1}),{table:f,nextTr:S}}},{key:"_attachToDom",value:function(f){f.table&&(f.nextTr?f.table.insertBefore(this.getDom(),f.nextTr):f.table.appendChild(this.getDom())),this.expanded&&this.showChilds()}},{key:"transform",value:function(f){if(this._hasChilds()){this.hideChilds();try{var S=this.getInternalValue(),$=this.getValue(),M=this.editor.options.executeQuery($,f),K=(this.setValue(M),this.getInternalValue());this.editor._onAction("transform",{path:this.getInternalPath(),oldValue:S,newValue:K}),this.showChilds()}catch(Q){this.showChilds(),this.editor._onError(Q)}}}},{key:"extract",value:function(){this.editor.node.hideChilds(),this.hideChilds();try{var f=this.editor.node.getInternalValue(),S=(this.editor._setRoot(this),this.editor.node.getInternalValue());this.editor._onAction("transform",{path:this.editor.node.getInternalPath(),oldValue:f,newValue:S})}catch($){this.editor._onError($)}finally{this.updateDom({recurse:!0}),this.showChilds()}}},{key:"getNestedChild",value:function(f){for(var S=0,$=this;$&&S<f.length;)$=$.findChildByProperty(f[S]),S++;return $}},{key:"findChildByProperty",value:function(f){if(this.type==="object")return this.childs.find(function(S){return S.field===f})}},{key:"getAppendDom",value:function(){return this.append||(this.append=new d(this.editor),this.append.setParent(this)),this.append.getDom()}},{key:"getShowMoreDom",value:function(){return this.showMore||(this.showMore=new y(this.editor,this)),this.showMore.getDom()}},{key:"nextSibling",value:function(){var f=this.parent.childs.indexOf(this);return this.parent.childs[f+1]||this.parent.append}},{key:"_previousNode",value:function(){var f=null,S=this.getDom();if(S&&S.parentNode)for(var $=S;$=$.previousSibling,f=R.getNodeFromTarget($),$&&f&&f instanceof d&&!f.isVisible(););return f}},{key:"_nextNode",value:function(){var f=null,S=this.getDom();if(S&&S.parentNode)for(var $=S;$=$.nextSibling,f=R.getNodeFromTarget($),$&&f&&f instanceof d&&!f.isVisible(););return f}},{key:"_firstNode",value:function(){var f=null,S=this.getDom();return S&&S.parentNode&&(S=S.parentNode.firstChild,f=R.getNodeFromTarget(S)),f}},{key:"_lastNode",value:function(){var f=null,S=this.getDom();if(S&&S.parentNode)for(var $=S.parentNode.lastChild,f=R.getNodeFromTarget($);$&&f&&!f.isVisible();)$=$.previousSibling,f=R.getNodeFromTarget($);return f}},{key:"_previousElement",value:function(f){var S=this.dom;switch(f){case S.value:if(this.fieldEditable)return S.field;case S.field:if(this._hasChilds())return S.expand;case S.expand:return S.menu;case S.menu:if(S.drag)return S.drag;default:return null}}},{key:"_nextElement",value:function(f){var S=this.dom;switch(f){case S.drag:return S.menu;case S.menu:if(this._hasChilds())return S.expand;case S.expand:if(this.fieldEditable)return S.field;case S.field:if(!this._hasChilds())return S.value;default:return null}}},{key:"_getElementName",value:function(f){var S=this;return Object.keys(this.dom).find(function($){return S.dom[$]===f})}},{key:"_hasChilds",value:function(){return this.type==="array"||this.type==="object"}},{key:"addTemplates",value:function(f,S){var $=this,M=$.editor.options.templates;M!=null&&(M.length&&f.push({type:"separator"}),M.forEach(function(K){f.push({text:K.text,className:K.className||"jsoneditor-type-object",title:K.title,click:(S?function(Q,te){$._onAppend(Q,te)}:function(Q,te){$._onInsertBefore(Q,te)}).bind(this,K.field,K.value)})}))}},{key:"showContextMenu",value:function(f,S){var $,M=this,K=[];this.editable.value&&K.push({text:(0,W.Iu)("type"),title:(0,W.Iu)("typeTitle"),className:"jsoneditor-type-"+this.type,submenu:[{text:(0,W.Iu)("auto"),className:"jsoneditor-type-auto"+(this.type==="auto"?" jsoneditor-selected":""),title:(0,W.Iu)("autoType"),click:function(){M._onChangeType("auto")}},{text:(0,W.Iu)("array"),className:"jsoneditor-type-array"+(this.type==="array"?" jsoneditor-selected":""),title:(0,W.Iu)("arrayType"),click:function(){M._onChangeType("array")}},{text:(0,W.Iu)("object"),className:"jsoneditor-type-object"+(this.type==="object"?" jsoneditor-selected":""),title:(0,W.Iu)("objectType"),click:function(){M._onChangeType("object")}},{text:(0,W.Iu)("string"),className:"jsoneditor-type-string"+(this.type==="string"?" jsoneditor-selected":""),title:(0,W.Iu)("stringType"),click:function(){M._onChangeType("string")}}]}),this._hasChilds()&&(this.editor.options.enableSort&&K.push({text:(0,W.Iu)("sort"),title:(0,W.Iu)("sortTitle",{type:this.type}),className:"jsoneditor-sort-asc",click:function(){M.showSortModal()}}),this.editor.options.enableTransform&&K.push({text:(0,W.Iu)("transform"),title:(0,W.Iu)("transformTitle",{type:this.type}),className:"jsoneditor-transform",click:function(){M.showTransformModal()}}),this.parent&&K.push({text:(0,W.Iu)("extract"),title:(0,W.Iu)("extractTitle",{type:this.type}),className:"jsoneditor-extract",click:function(){M.extract()}})),this.parent&&this.parent._hasChilds()&&(K.length&&K.push({type:"separator"}),$=M.parent.childs,M===$[$.length-1]&&($=[{text:(0,W.Iu)("auto"),className:"jsoneditor-type-auto",title:(0,W.Iu)("autoType"),click:function(){M._onAppend("","","auto")}},{text:(0,W.Iu)("array"),className:"jsoneditor-type-array",title:(0,W.Iu)("arrayType"),click:function(){M._onAppend("",[])}},{text:(0,W.Iu)("object"),className:"jsoneditor-type-object",title:(0,W.Iu)("objectType"),click:function(){M._onAppend("",{})}},{text:(0,W.Iu)("string"),className:"jsoneditor-type-string",title:(0,W.Iu)("stringType"),click:function(){M._onAppend("","","string")}}],M.addTemplates($,!0),K.push({text:(0,W.Iu)("appendText"),title:(0,W.Iu)("appendTitle"),submenuTitle:(0,W.Iu)("appendSubmenuTitle"),className:"jsoneditor-append",click:function(){M._onAppend("","","auto")},submenu:$})),$=[{text:(0,W.Iu)("auto"),className:"jsoneditor-type-auto",title:(0,W.Iu)("autoType"),click:function(){M._onInsertBefore("","","auto")}},{text:(0,W.Iu)("array"),className:"jsoneditor-type-array",title:(0,W.Iu)("arrayType"),click:function(){M._onInsertBefore("",[])}},{text:(0,W.Iu)("object"),className:"jsoneditor-type-object",title:(0,W.Iu)("objectType"),click:function(){M._onInsertBefore("",{})}},{text:(0,W.Iu)("string"),className:"jsoneditor-type-string",title:(0,W.Iu)("stringType"),click:function(){M._onInsertBefore("","","string")}}],M.addTemplates($,!1),K.push({text:(0,W.Iu)("insert"),title:(0,W.Iu)("insertTitle"),submenuTitle:(0,W.Iu)("insertSub"),className:"jsoneditor-insert",click:function(){M._onInsertBefore("","","auto")},submenu:$}),this.editable.field&&(K.push({text:(0,W.Iu)("duplicateText"),title:(0,W.Iu)("duplicateField"),className:"jsoneditor-duplicate",click:function(){R.onDuplicate(M)}}),K.push({text:(0,W.Iu)("removeText"),title:(0,W.Iu)("removeField"),className:"jsoneditor-remove",click:function(){R.onRemove(M)}}))),this.editor.options.onCreateMenu&&($=M.getPath(),K=this.editor.options.onCreateMenu(K,{type:"single",path:$,paths:[$]})),new k.x(K,{close:S}).show(f,this.editor.getPopupAnchor())}},{key:"showSortModal",value:function(){var f=this,S=this.editor.options.modalAnchor||l.qD,$=this.getValue();(0,x.showSortModal)(S,$,function(M){var K=M.path,K=(0,b.parsePath)(K);f.sortedBy=M,f.sort(K,M.direction)},f.sortedBy)}},{key:"showTransformModal",value:function(){var f=this,K=this.editor.options,S=K.modalAnchor,$=K.createQuery,M=K.executeQuery,K=K.queryDescription,Q=this.getValue();(0,p.showTransformModal)({container:S||l.qD,json:Q,queryDescription:K,createQuery:$,executeQuery:M,onTransform:function(te){f.transform(te)}})}},{key:"_getType",value:function(f){return f instanceof Array?"array":f instanceof Object?"object":typeof f=="string"&&typeof(0,b.parseString)(f)!="string"?"string":"auto"}},{key:"_escapeHTML",value:function(f){return typeof f!="string"?String(f):(f=String(f).replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/ {2}/g," &nbsp;").replace(/^ /,"&nbsp;").replace(/ $/,"&nbsp;"),f=(f=JSON.stringify(f)).substring(1,f.length-1),this.editor.options.escapeUnicode===!0?(0,b.escapeUnicodeChars)(f):f)}},{key:"_unescapeHTML",value:function(f){return f='"'+this._escapeJSON(f)+'"',(0,b.parse)(f).replace(/&lt;/g,"<").replace(/&gt;/g,">").replace(/&nbsp;|\u00A0/g," ").replace(/&amp;/g,"&")}},{key:"_escapeJSON",value:function(f){for(var S="",$=0;$<f.length;){var M=f.charAt($);M===`
`?S+="\\n":M==="\\"?(S+=M,$++,(M=f.charAt($))!==""&&'"\\/bfnrtu'.indexOf(M)!==-1||(S+="\\"),S+=M):S+=M==='"'?'\\"':M,$++}return S}},{key:"updateNodeName",value:function(){var f=this.childs?this.childs.length:0;if(this.type==="object"||this.type==="array"){if(this.editor.options.onNodeName)try{var S=this.getValue.bind(this),$=this.editor.options.onNodeName({path:this.getPath(),size:f,type:this.type,get value(){return S()}})}catch(M){console.error("Error in onNodeName callback: ",M)}this.dom.value.textContent=this.type==="object"?"{"+($||f)+"}":"["+($||f)+"]"}}},{key:"recursivelyUpdateNodeName",value:function(){if(this.expanded&&(this.updateNodeName(),this.childs!=="undefined"))for(var f in this.childs)this.childs[f].recursivelyUpdateNodeName()}}])&&a(H.prototype,G),Object.defineProperty(H,"prototype",{writable:!1}),R}(),c=(o.prototype.DEBOUNCE_INTERVAL=150,o.prototype.MAX_SEARCH_RESULTS=999,100);function h(R){return R.getInternalPath()}function A(R){return R.getField()}function v(R,H){return Object.prototype.hasOwnProperty.call(R,H)}o.focusElement=void 0,o.select=function(R){setTimeout(function(){(0,b.selectContentEditable)(R)},0)},o.onDragStart=function(R,H){if(!Array.isArray(R))return o.onDragStart([R],H);var G,f,S,$,M;R.length!==0&&(G=R[0],f=R[R.length-1],S=G.parent,M=o.getNodeFromTarget(H.target),$=G.editor,M=(0,b.getAbsoluteTop)(M.dom.tr)-(0,b.getAbsoluteTop)(G.dom.tr),$.mousemove||($.mousemove=(0,b.addEventListener)(H.view,"mousemove",function(K){o.onDrag(R,K)})),$.mouseup||($.mouseup=(0,b.addEventListener)(H.view,"mouseup",function(K){o.onDragEnd(R,K)})),$.highlighter.lock(),$.drag={oldCursor:document.body.style.cursor,oldSelection:$.getDomSelection(),oldPaths:R.map(h),oldParent:S,oldNextNode:S.childs[f.getIndex()+1]||S.append,oldParentPathRedo:S.getInternalPath(),oldIndexRedo:G.getIndex(),mouseX:H.pageX,offsetY:M,level:G.getLevel()},document.body.style.cursor="move",H.preventDefault())},o.onDrag=function(R,H){if(!Array.isArray(R))return o.onDrag([R],H);if(R.length!==0){var G,f,S,$,M,K=R[0].editor,Q=H.pageY-K.drag.offsetY,te=H.pageX,he=!1,Ae=R[0],ge=Ae.dom.tr,Ce=(0,b.getAbsoluteTop)(ge),ve=ge.offsetHeight;if(Q<Ce){for(Se=ge;Se=Se.previousSibling,ue=o.getNodeFromTarget(Se),S=Se?(0,b.getAbsoluteTop)(Se):0,Se&&Q<S;);(ue=ue&&!ue.parent?void 0:ue)||(Se=(ge=ge.parentNode.firstChild)?ge.nextSibling:void 0,(ue=o.getNodeFromTarget(Se))===Ae&&(ue=void 0)),!(ue=ue&&ue.isVisible()&&(S=(Se=ue.dom.tr)?(0,b.getAbsoluteTop)(Se):0)+ve<Q?void 0:ue)||K.options.limitDragging!==!1&&ue.parent!==R[0].parent||(R.forEach(function(ae){ue.parent.moveBefore(ae,ue)}),he=!0)}else{var ye=R[R.length-1];if(ve=(ge=ye.expanded&&ye.append?ye.append.getDom():ye.dom.tr)?ge.nextSibling:void 0){for($=(0,b.getAbsoluteTop)(ve),G=ve;f=o.getNodeFromTarget(G),G&&(M=G.nextSibling?(0,b.getAbsoluteTop)(G.nextSibling):0,M=G?M-$:0,f&&f.parent.childs.length===R.length&&f.parent.childs[R.length-1]===ye&&(Ce+=27),G=G.nextSibling),G&&Ce+M<Q;);if(f&&f.parent){for(var ve=te-K.drag.mouseX,ve=Math.round(ve/24/2),Te=K.drag.level+ve,_e=f.getLevel(),Se=f.dom.tr&&f.dom.tr.previousSibling;_e<Te&&Se;){var ue=o.getNodeFromTarget(Se),$e=R.some(function(pe){return pe===ue||ue.isDescendantOf(pe)});if(!$e){if(!(ue instanceof d)||($e=ue.parent.childs,$e.length===R.length&&$e[R.length-1]===ye))break;_e=(f=o.getNodeFromTarget(Se)).getLevel()}Se=Se.previousSibling}(f=f instanceof d&&!f.isVisible()&&f.parent.showMore.isVisible()?f._nextNode():f)&&(K.options.limitDragging===!1||f.parent===R[0].parent)&&f.dom.tr&&f.dom.tr!==ge.nextSibling&&(R.forEach(function(ae){f.parent.moveBefore(ae,f)}),he=!0)}}}he&&(K.drag.mouseX=te,K.drag.level=Ae.getLevel()),K.startAutoScroll(Q),H.preventDefault()}},o.onDragEnd=function(R,H){if(!Array.isArray(R))return o.onDrag([R],H);var G,f,S,$,M,K,Q,te,he;R.length!==0&&(K=R[0],G=K.editor,K&&K.dom.menu&&K.dom.menu.focus(),f=G.drag.oldParent.getInternalPath(),S=K.parent.getInternalPath(),$=G.drag.oldParent===K.parent,M=G.drag.oldNextNode.getIndex(),K=K.getIndex(),Q=G.drag.oldParentPathRedo,te=G.drag.oldIndexRedo,he=$&&te<K?K+R.length:K,$&&te===K||G._onAction("moveNodes",{count:R.length,fieldNames:R.map(A),oldParentPath:f,newParentPath:S,oldIndex:M,newIndex:K,oldIndexRedo:te,newIndexRedo:he,oldParentPathRedo:Q,newParentPathRedo:null,oldSelection:G.drag.oldSelection,newSelection:G.getDomSelection()}),document.body.style.cursor=G.drag.oldCursor,G.highlighter.unlock(),R.forEach(function(Ae){Ae.updateDom(),H.target!==Ae.dom.drag&&H.target!==Ae.dom.menu&&G.highlighter.unhighlight()}),delete G.drag,G.mousemove&&((0,b.removeEventListener)(H.view,"mousemove",G.mousemove),delete G.mousemove),G.mouseup&&((0,b.removeEventListener)(H.view,"mouseup",G.mouseup),delete G.mouseup),G.stopAutoScroll(),H.preventDefault())},o._findEnum=function(R){return R.enum?R.enum:(R=R.oneOf||R.anyOf||R.allOf,R&&(R=R.filter(function(H){return H.enum}),0<R.length)?R[0].enum:null)},o._findSchema=function(R,H,G){for(var f=3<arguments.length&&arguments[3]!==void 0?arguments[3]:R,S=G.slice(1,G.length),$=G[0],M=[f],K=0,Q=[f.oneOf,f.anyOf,f.allOf];K<Q.length;K++){var te=Q[K];Array.isArray(te)&&(M=M.concat(te))}var he,Ae=t(M);try{for(Ae.s();!(he=Ae.n()).done;){if("$ref"in(f=he.value)&&typeof f.$ref=="string"){var ge,Ce=f.$ref;if(Ce in H)f=H[Ce];else{if(!Ce.startsWith("#/")){if(((ge=Ce.match(/#\//g))==null?void 0:ge.length)===1){var ve,ye,Te,_e=n(Ce.split("#/"),2),Se=_e[0],ue=_e[1];if(Se in H)return ve=H[Se],ye={$ref:"#/".concat(ue)},(Te=[]).push($),0<S.length&&Te.push.apply(Te,s(S)),o._findSchema(ve,H,Te,ye)}throw Error("Unable to resolve reference ".concat(Ce))}var $e,ae=Ce.substring(2).split("/"),f=R,pe=t(ae);try{for(pe.s();!($e=pe.n()).done;){var ce=$e.value;if(!(ce in f))throw Error("Unable to resolve reference ".concat(Ce));f=f[ce]}}catch(be){pe.e(be)}finally{pe.f()}}}if($===void 0)return f;if(typeof $=="string"){if(r(f.properties)==="object"&&f.properties!==null&&$ in f.properties)return f=f.properties[$],o._findSchema(R,H,S,f);if(r(f.patternProperties)==="object"&&f.patternProperties!==null){for(var de in f.patternProperties)if($.match(de))return f=f.patternProperties[de],o._findSchema(R,H,S,f)}if(r(f.additionalProperties)==="object")return f=f.additionalProperties,o._findSchema(R,H,S,f)}else if(typeof $=="number"&&r(f.items)==="object"&&f.items!==null)return f=f.items,o._findSchema(R,H,S,f)}}catch(fe){Ae.e(fe)}finally{Ae.f()}return null},o.onRemove=function(R){if(!Array.isArray(R))return o.onRemove([R]);var H,G,f,S,$,M;R&&0<R.length&&(H=(f=R[0]).parent,G=f.editor,f=f.getIndex(),G.highlighter.unhighlight(),S=G.getDomSelection(),o.blurNodes(R),$=G.getDomSelection(),M=R.map(h),R.forEach(function(K){K.parent._remove(K)}),G._onAction("removeNodes",{nodes:R,paths:M,parentPath:H.getInternalPath(),index:f,oldSelection:S,newSelection:$}))},o.onDuplicate=function(R){if(!Array.isArray(R))return o.onDuplicate([R]);var H,G,f,S,$,M,K;R&&0<R.length&&(H=R[R.length-1],G=H.parent,(f=H.editor).deselect(f.multiselection.nodes),S=f.getDomSelection(),$=H,M=R.map(function(Q){var te,he=Q.clone();return Q.parent.type==="object"&&(te=Q.parent.getFieldNames(),he.field=(0,b.findUniqueName)(Q.field,te)),G.insertAfter(he,$),$=he}),R.length===1?M[0].parent.type==="object"?(M[0].dom.field.innerHTML=R[0]._escapeHTML(R[0].field),M[0].focus("field")):M[0].focus():f.select(M),K=f.getDomSelection(),f._onAction("duplicateNodes",{paths:R.map(h),clonePaths:M.map(h),afterPath:H.getInternalPath(),parentPath:G.getInternalPath(),oldSelection:S,newSelection:K}))},o.getNodeFromTarget=function(R){for(;R;){if(R.node)return R.node;R=R.parentNode}},o.targetIsColorPicker=function(R){var H=o.getNodeFromTarget(R);if(H)for(var G=R&&R.parentNode;G;){if(G===H.dom.color)return!0;G=G.parentNode}return!1},o.blurNodes=function(R){var H,G;Array.isArray(R)?(H=(G=R[0]).parent,G=G.getIndex(),(H.childs[G+R.length]?H.childs[G+R.length]:H.childs[G-1]||H).focus()):o.blurNodes([R])},(g.prototype=new o).getDom=function(){var R=this.dom;if(R.tr)return R.tr;this._updateEditability();var H=document.createElement("tr"),G=(H.className="jsoneditor-append",H.node=this,R.tr=H,this.editor.options.mode==="tree"&&(R.tdDrag=document.createElement("td"),f=document.createElement("td"),R.tdMenu=f,(G=document.createElement("button")).type="button",G.className="jsoneditor-button jsoneditor-contextmenu-button",G.title="Click to open the actions menu (Ctrl+M)",R.menu=G,f.appendChild(R.menu)),document.createElement("td")),f=document.createElement("div");return f.appendChild(document.createTextNode("("+(0,W.Iu)("empty")+")")),f.className="jsoneditor-readonly",G.appendChild(f),R.td=G,R.text=f,this.updateDom(),H},g.prototype.getPath=function(){return null},g.prototype.getIndex=function(){return null},g.prototype.updateDom=function(R){var H=this.dom,G=H.td,f=(G&&(G.style.paddingLeft=24*this.getLevel()+26+"px"),H.text),f=(f&&(f.firstChild.nodeValue="("+(0,W.Iu)("empty")+" "+this.parent.type+")"),H.tr);this.isVisible()?H.tr.firstChild||(H.tdDrag&&f.appendChild(H.tdDrag),H.tdMenu&&f.appendChild(H.tdMenu),f.appendChild(G)):H.tr.firstChild&&(H.tdDrag&&f.removeChild(H.tdDrag),H.tdMenu&&f.removeChild(H.tdMenu),f.removeChild(G))},g.prototype.isVisible=function(){return this.parent.childs.length===0},g.prototype.showContextMenu=function(R,H){var G,f=this,S=[{text:(0,W.Iu)("auto"),className:"jsoneditor-type-auto",title:(0,W.Iu)("autoType"),click:function(){f._onAppend("","","auto")}},{text:(0,W.Iu)("array"),className:"jsoneditor-type-array",title:(0,W.Iu)("arrayType"),click:function(){f._onAppend("",[])}},{text:(0,W.Iu)("object"),className:"jsoneditor-type-object",title:(0,W.Iu)("objectType"),click:function(){f._onAppend("",{})}},{text:(0,W.Iu)("string"),className:"jsoneditor-type-string",title:(0,W.Iu)("stringType"),click:function(){f._onAppend("","","string")}}],S=(f.addTemplates(S,!0),[{text:(0,W.Iu)("appendText"),title:(0,W.Iu)("appendTitleAuto"),submenuTitle:(0,W.Iu)("appendSubmenuTitle"),className:"jsoneditor-insert",click:function(){f._onAppend("","","auto")},submenu:S}]);this.editor.options.onCreateMenu&&(G=f.parent.getPath(),S=this.editor.options.onCreateMenu(S,{type:"append",path:G,paths:[G]})),new k.x(S,{close:H}).show(R,this.editor.getPopupAnchor())},g.prototype.onEvent=function(R){var H,G=R.type,f=R.target||R.srcElement,S=this.dom;f===S.menu&&(G==="mouseover"?this.editor.highlighter.highlight(this.parent):G==="mouseout"&&this.editor.highlighter.unhighlight()),G==="click"&&f===S.menu&&((H=this.editor.highlighter).highlight(this.parent),H.lock(),(0,b.addClassName)(S.menu,"jsoneditor-selected"),this.showContextMenu(S.menu,function(){(0,b.removeClassName)(S.menu,"jsoneditor-selected"),H.unlock(),H.unhighlight()})),G==="keydown"&&this.onKeyDown(R)};var d=g;function g(R){this.editor=R,this.dom={}}(w.prototype=new o).getDom=function(){var R,H,G,f,S,$;return this.dom.tr||(this._updateEditability(),this.dom.tr||(H=(R=this).parent,(S=document.createElement("a")).appendChild(document.createTextNode((0,W.Iu)("showMore"))),S.href="#",S.onclick=function(M){return H.visibleChilds=Math.floor(H.visibleChilds/H.getMaxVisibleChilds()+1)*H.getMaxVisibleChilds(),R.updateDom(),H.showChilds(),M.preventDefault(),!1},($=document.createElement("a")).appendChild(document.createTextNode((0,W.Iu)("showAll"))),$.href="#",$.onclick=function(M){return H.visibleChilds=1/0,R.updateDom(),H.showChilds(),M.preventDefault(),!1},G=document.createElement("div"),f=document.createTextNode(this._getShowMoreText()),G.className="jsoneditor-show-more",G.appendChild(f),G.appendChild(S),G.appendChild(document.createTextNode(". ")),G.appendChild($),G.appendChild(document.createTextNode(". ")),(S=document.createElement("td")).appendChild(G),$=document.createElement("tr"),this.editor.options.mode==="tree"&&($.appendChild(document.createElement("td")),$.appendChild(document.createElement("td"))),$.appendChild(S),$.className="jsoneditor-show-more",this.dom.tr=$,this.dom.moreContents=G,this.dom.moreText=f),this.updateDom()),this.dom.tr},w.prototype.updateDom=function(R){var H;this.isVisible()?(this.dom.tr.node=this.parent.childs[this.parent.visibleChilds],this.dom.tr.parentNode||(H=this.parent._getNextTr())&&H.parentNode.insertBefore(this.dom.tr,H),this.dom.moreText.nodeValue=this._getShowMoreText(),this.dom.moreContents.style.marginLeft=24*(this.getLevel()+1)+"px"):this.dom.tr&&this.dom.tr.parentNode&&this.dom.tr.parentNode.removeChild(this.dom.tr)},w.prototype._getShowMoreText=function(){return(0,W.Iu)("showMoreStatus",{visibleChilds:this.parent.visibleChilds,totalChilds:this.parent.childs.length})+" "},w.prototype.isVisible=function(){return this.parent.expanded&&this.parent.childs.length>this.parent.visibleChilds},w.prototype.onEvent=function(R){R.type==="keydown"&&this.onKeyDown(R)};var y=w;function w(R,H){this.editor=R,this.parent=H,this.dom={}}function I(R,H){for(var G=0;G<H.length;G++){var f=H[G];f.enumerable=f.enumerable||!1,f.configurable=!0,"value"in f&&(f.writable=!0),Object.defineProperty(R,f.key,f)}}var T=function(){function R(f){if(!(this instanceof R))throw new TypeError("Cannot call a class as a function");function S($){return f.node.findNodeByInternalPath($)}this.editor=f,this.history=[],this.index=-1,this.clear(),this.actions={editField:{undo:function($){S($.parentPath).childs[$.index].updateField($.oldValue)},redo:function($){S($.parentPath).childs[$.index].updateField($.newValue)}},editValue:{undo:function($){S($.path).updateValue($.oldValue)},redo:function($){S($.path).updateValue($.newValue)}},changeType:{undo:function($){S($.path).changeType($.oldType)},redo:function($){S($.path).changeType($.newType)}},appendNodes:{undo:function($){var M=S($.parentPath);$.paths.map(S).forEach(function(K){M.removeChild(K)})},redo:function($){var M=S($.parentPath);$.nodes.forEach(function(K){M.appendChild(K)})}},insertBeforeNodes:{undo:function($){var M=S($.parentPath);$.paths.map(S).forEach(function(K){M.removeChild(K)})},redo:function($){var M=S($.parentPath),K=S($.beforePath);$.nodes.forEach(function(Q){M.insertBefore(Q,K)})}},insertAfterNodes:{undo:function($){var M=S($.parentPath);$.paths.map(S).forEach(function(K){M.removeChild(K)})},redo:function($){var M=S($.parentPath),K=S($.afterPath);$.nodes.forEach(function(Q){M.insertAfter(Q,K),K=Q})}},removeNodes:{undo:function($){var M=S($.parentPath),K=M.childs[$.index]||M.append;$.nodes.forEach(function(Q){M.insertBefore(Q,K)})},redo:function($){var M=S($.parentPath);$.paths.map(S).forEach(function(K){M.removeChild(K)})}},duplicateNodes:{undo:function($){var M=S($.parentPath);$.clonePaths.map(S).forEach(function(K){M.removeChild(K)})},redo:function($){var M=S($.parentPath),K=S($.afterPath);$.paths.map(S).forEach(function(Q){var te,he=Q.clone();M.type==="object"&&(te=M.getFieldNames(),he.field=(0,b.findUniqueName)(Q.field,te)),M.insertAfter(he,K),K=he})}},moveNodes:{undo:function($){var M=S($.oldParentPath),K=S($.newParentPath),Q=M.childs[$.oldIndex]||M.append;K.childs.slice($.newIndex,$.newIndex+$.count).forEach(function(te,he){te.field=$.fieldNames[he],M.moveBefore(te,Q)}),$.newParentPathRedo===null&&($.newParentPathRedo=K.getInternalPath())},redo:function($){var M=S($.oldParentPathRedo),K=S($.newParentPathRedo),Q=K.childs[$.newIndexRedo]||K.append;M.childs.slice($.oldIndexRedo,$.oldIndexRedo+$.count).forEach(function(te,he){te.field=$.fieldNames[he],K.moveBefore(te,Q)})}},sort:{undo:function($){var M=S($.path);M.hideChilds(),M.childs=$.oldChilds,M.updateDom({updateIndexes:!0}),M.showChilds()},redo:function($){var M=S($.path);M.hideChilds(),M.childs=$.newChilds,M.updateDom({updateIndexes:!0}),M.showChilds()}},transform:{undo:function($){S($.path).setInternalValue($.oldValue)},redo:function($){S($.path).setInternalValue($.newValue)}}}}var H,G;return H=R,(G=[{key:"onChange",value:function(){}},{key:"add",value:function(f,S){this.index++,this.history[this.index]={action:f,params:S,timestamp:new Date},this.index<this.history.length-1&&this.history.splice(this.index+1,this.history.length-this.index-1),this.onChange()}},{key:"clear",value:function(){this.history=[],this.index=-1,this.onChange()}},{key:"canUndo",value:function(){return 0<=this.index}},{key:"canRedo",value:function(){return this.index<this.history.length-1}},{key:"undo",value:function(){if(this.canUndo()){var f=this.history[this.index];if(f){var S=this.actions[f.action];if(S&&S.undo){if(S.undo(f.params),f.params.oldSelection)try{this.editor.setDomSelection(f.params.oldSelection)}catch($){console.error($)}}else console.error(new Error('unknown action "'+f.action+'"'))}this.index--,this.onChange()}}},{key:"redo",value:function(){if(this.canRedo()){this.index++;var f=this.history[this.index];if(f){var S=this.actions[f.action];if(S&&S.redo){if(S.redo(f.params),f.params.newSelection)try{this.editor.setDomSelection(f.params.newSelection)}catch($){console.error($)}}else console.error(new Error('unknown action "'+f.action+'"'))}this.onChange()}}},{key:"destroy",value:function(){this.editor=null,this.history=[],this.index=-1}}])&&I(H.prototype,G),Object.defineProperty(H,"prototype",{writable:!1}),R}();function B(R,H){for(var G=0;G<H.length;G++){var f=H[G];f.enumerable=f.enumerable||!1,f.configurable=!0,"value"in f&&(f.writable=!0),Object.defineProperty(R,f.key,f)}}var E=function(){function R(Q,M){if(!(this instanceof R))throw new TypeError("Cannot call a class as a function");var $=this,Q=(this.editor=Q,this.timeout=void 0,this.delay=200,this.lastText=void 0,this.results=null,this.dom={},this.dom.container=M,document.createElement("div")),M=((this.dom.wrapper=Q).className="jsoneditor-search",M.appendChild(Q),document.createElement("div")),M=((this.dom.results=M).className="jsoneditor-results",Q.appendChild(M),document.createElement("div")),Q=((this.dom.input=M).className="jsoneditor-frame",M.title=(0,W.Iu)("searchTitle"),Q.appendChild(M),document.createElement("button")),K=(Q.type="button",Q.className="jsoneditor-refresh",M.appendChild(Q),document.createElement("input")),Q=(K.type="text",(this.dom.search=K).oninput=function(te){$._onDelayedSearch(te)},K.onchange=function(te){$._onSearch()},K.onkeydown=function(te){$._onKeyDown(te)},K.onkeyup=function(te){$._onKeyUp(te)},Q.onclick=function(te){K.select()},M.appendChild(K),document.createElement("button")),Q=(Q.type="button",Q.title=(0,W.Iu)("searchNextResultTitle"),Q.className="jsoneditor-next",Q.onclick=function(){$.next()},M.appendChild(Q),document.createElement("button"));Q.type="button",Q.title=(0,W.Iu)("searchPreviousResultTitle"),Q.className="jsoneditor-previous",Q.onclick=function(){$.previous()},M.appendChild(Q)}var H,G;return H=R,(G=[{key:"next",value:function(f){var S;this.results&&((S=this.resultIndex!==null?this.resultIndex+1:0)>this.results.length-1&&(S=0),this._setActiveResult(S,f))}},{key:"previous",value:function(f){var S,$;this.results&&(S=this.results.length-1,$=this.resultIndex!==null?this.resultIndex-1:S,this._setActiveResult($=$<0?S:$,f))}},{key:"_setActiveResult",value:function(f,S){var $,M,K;this.activeResult&&($=this.activeResult.node,this.activeResult.elem==="field"?delete $.searchFieldActive:delete $.searchValueActive,$.updateDom()),this.results&&this.results[f]?(this.resultIndex=f,M=this.results[this.resultIndex].node,(K=this.results[this.resultIndex].elem)==="field"?M.searchFieldActive=!0:M.searchValueActive=!0,this.activeResult=this.results[this.resultIndex],M.updateDom(),M.scrollTo(function(){S&&M.focus(K)})):(this.resultIndex=void 0,this.activeResult=void 0)}},{key:"_clearDelay",value:function(){this.timeout!==void 0&&(clearTimeout(this.timeout),delete this.timeout)}},{key:"_onDelayedSearch",value:function(f){this._clearDelay();var S=this;this.timeout=setTimeout(function($){S._onSearch()},this.delay)}},{key:"_onSearch",value:function(f){this._clearDelay();var S=this.dom.search.value,S=0<S.length?S:void 0;if(S!==this.lastText||f){this.lastText=S,this.results=this.editor.search(S);var f=this.results[0]?this.results[0].node.MAX_SEARCH_RESULTS:1/0,$=0;if(this.activeResult){for(var M=0;M<this.results.length;M++)if(this.results[M].node===this.activeResult.node){$=M;break}}this._setActiveResult($,!1),S!==void 0?(S=this.results.length,this.dom.results.textContent=S===0?"no\xA0results":S===1?"1\xA0result":f<S?f+"+\xA0results":S+"\xA0results"):this.dom.results.textContent=""}}},{key:"_onKeyDown",value:function(f){var S=f.which;S===27?(this.dom.search.value="",this._onSearch(),f.preventDefault(),f.stopPropagation()):S===13&&(f.ctrlKey?this._onSearch(!0):f.shiftKey?this.previous():this.next(),f.preventDefault(),f.stopPropagation())}},{key:"_onKeyUp",value:function(f){var S=f.keyCode;S!==27&&S!==13&&this._onDelayedSearch(f)}},{key:"clear",value:function(){this.dom.search.value="",this._onSearch()}},{key:"forceSearch",value:function(){this._onSearch(!0)}},{key:"isEmpty",value:function(){return this.dom.search.value===""}},{key:"destroy",value:function(){this.editor=null,this.dom.container.removeChild(this.dom.wrapper),this.dom=null,this.results=null,this.activeResult=null,this._clearDelay()}}])&&B(H.prototype,G),Object.defineProperty(H,"prototype",{writable:!1}),R}();function _(R,H){for(var G=0;G<H.length;G++){var f=H[G];f.enumerable=f.enumerable||!1,f.configurable=!0,"value"in f&&(f.writable=!0),Object.defineProperty(R,f.key,f)}}var P=function(){function R(f,S){if(!(this instanceof R))throw new TypeError("Cannot call a class as a function");f&&(this.root=S,this.path=document.createElement("div"),this.path.className="jsoneditor-treepath",this.path.setAttribute("tabindex",0),this.contentMenuClicked=!1,f.appendChild(this.path),this.reset())}var H,G;return H=R,(G=[{key:"reset",value:function(){this.path.textContent=(0,W.Iu)("selectNode")}},{key:"setPath",value:function(f){var S=this;this.path.textContent="",f&&f.length&&f.forEach(function($,M){var K,Q=document.createElement("span");Q.className="jsoneditor-treepath-element",Q.innerText=$.name,Q.onclick=function(te){this.selectionCallback&&this.selectionCallback(te)}.bind(S,$),S.path.appendChild(Q),$.children.length&&((K=document.createElement("span")).className="jsoneditor-treepath-seperator",K.textContent="\u25BA",K.onclick=function(){S.contentMenuClicked=!0;var te=[];$.children.forEach(function(he){te.push({text:he.name,className:"jsoneditor-type-modes"+(f[M+1]+1&&f[M+1].name===he.name?" jsoneditor-selected":""),click:function(Ae,ge){this.contextMenuCallback&&this.contextMenuCallback(Ae,ge)}.bind(S,$,he.name)})}),new k.x(te,{limitHeight:!0}).show(K,S.root,!0)},S.path.appendChild(K)),M===f.length-1&&(Q=(K||Q).getBoundingClientRect().right,S.path.offsetWidth<Q&&(S.path.scrollLeft=Q),S.path.scrollLeft&&((Q=document.createElement("span")).className="jsoneditor-treepath-show-all-btn",Q.title="show all path",Q.textContent="...",Q.onclick=function(te){(S.contentMenuClicked=!1,b.addClassName)(S.path,"show-all"),S.path.style.width=S.path.parentNode.getBoundingClientRect().width-10+"px",S.path.onblur=function(){S.contentMenuClicked?(S.contentMenuClicked=!1,S.path.focus()):((0,b.removeClassName)(S.path,"show-all"),S.path.onblur=void 0,S.path.style.width="",S.setPath(te))}}.bind(S,f),S.path.insertBefore(Q,S.path.firstChild)))})}},{key:"onSectionSelected",value:function(f){typeof f=="function"&&(this.selectionCallback=f)}},{key:"onContextMenuItemSelected",value:function(f){typeof f=="function"&&(this.contextMenuCallback=f)}}])&&_(H.prototype,G),Object.defineProperty(H,"prototype",{writable:!1}),R}(),j=D(8037),z=D.n(j),D={},Y=(D.create=function(R,H){if(!R)throw new Error("No container element provided.");function G(ce){var de,fe;document.createRange?((de=document.createRange()).selectNodeContents(ce),de.collapse(!1),(fe=window.getSelection()).removeAllRanges(),fe.addRange(de)):document.selection&&((de=document.body.createTextRange()).moveToElementText(ce),de.collapse(!1),de.select())}function f(ce){return Q===void 0&&((Q=document.createElement("span")).style.visibility="hidden",Q.style.position="fixed",Q.style.outline="0",Q.style.margin="0",Q.style.padding="0",Q.style.border="0",Q.style.left="0",Q.style.whiteSpace="pre",Q.style.fontSize=he,Q.style.fontFamily=Ae,Q.style.fontWeight="normal",document.body.appendChild(Q)),Q.textContent=ce,Q.getBoundingClientRect().right}function S(){this.style.backgroundColor="#ddd"}function $(){this.style.backgroundColor=""}function M(){Se.hide(),Se.onmouseselection(this.__hint,Se.rs)}var K,Q,te,he,Ae,ge,Ce,ve,ye,Te,_e,Se,ue,$e,ae,pe;this.container=R,this.dom={},this.highlighter=new O,this.selection=void 0,this.multiselection={nodes:[]},this.validateSchema=null,this.validationSequence=0,this.errorNodes=[],this.lastSchemaErrors=void 0,this.node=null,this.focusTarget=null,this._setOptions(H),H.autocomplete&&(this.autocomplete=((K=(K=H.autocomplete)||{}).filter=K.filter||"start",K.trigger=K.trigger||"keydown",K.confirmKeys=K.confirmKeys||[39,35,9],K.caseSensitive=K.caseSensitive||!1,Ae=he="",(ge=document.createElement("div")).style.position="relative",ge.style.outline="0",ge.style.border="0",ge.style.margin="0",ge.style.padding="0",(Ce=document.createElement("div")).className="autocomplete dropdown",Ce.style.position="absolute",Ce.style.visibility="hidden",ve=Ce,ye=[],_e=-1,$e=Se={rs:ue={onArrowDown:function(){},onArrowUp:function(){},onEnter:function(){},onTab:function(){},startFrom:Te=0,options:[],element:null,elementHint:null,elementStyle:null,wrapper:ge,show:function(ce,de,fe){var be=this;this.startFrom=de,this.wrapper.remove(),this.elementHint&&(this.elementHint.remove(),this.elementHint=null),he===""&&(he=window.getComputedStyle(ce).getPropertyValue("font-size")),Ae===""&&(Ae=window.getComputedStyle(ce).getPropertyValue("font-family")),Ce.style.marginLeft="0",Ce.style.marginTop=ce.getBoundingClientRect().height+"px",this.options=fe.map(String),this.element!==ce&&(this.element=ce,this.elementStyle={zIndex:this.element.style.zIndex,position:this.element.style.position,backgroundColor:this.element.style.backgroundColor,borderColor:this.element.style.borderColor}),this.element.style.zIndex=3,this.element.style.position="relative",this.element.style.backgroundColor="transparent",this.element.style.borderColor="transparent",this.elementHint=ce.cloneNode(),this.elementHint.className="autocomplete hint",this.elementHint.style.zIndex=2,this.elementHint.style.position="absolute",this.elementHint.onfocus=function(){be.element.focus()},this.element.addEventListener&&(this.element.removeEventListener("keydown",ae),this.element.addEventListener("keydown",ae,!1),this.element.removeEventListener("blur",pe),this.element.addEventListener("blur",pe,!1)),ge.appendChild(this.elementHint),ge.appendChild(Ce),ce.parentElement.appendChild(ge),this.repaint(ce)},setText:function(ce){this.element.innerText=ce},getText:function(){return this.element.innerText},hideDropDown:function(){this.wrapper.remove(),this.elementHint&&(this.elementHint.remove(),this.elementHint=null,$e.hide(),this.element.style.zIndex=this.elementStyle.zIndex,this.element.style.position=this.elementStyle.position,this.element.style.backgroundColor=this.elementStyle.backgroundColor,this.element.style.borderColor=this.elementStyle.borderColor)},repaint:function(de){var de=(de=de.innerText).replace(`
`,""),fe=this.options.length,be=de.substring(this.startFrom);te=de.substring(0,this.startFrom);for(var ke=0;ke<fe;ke++){var Me=this.options[ke];if(!K.caseSensitive&&Me.toLowerCase().indexOf(be.toLowerCase())===0||K.caseSensitive&&Me.indexOf(be)===0){this.elementHint.innerText=te+be+Me.substring(be.length),this.elementHint.realInnerText=te+Me;break}}Ce.style.left=f(te)+"px",$e.refresh(be,this.options),this.elementHint.style.width=f(this.elementHint.innerText)+10+"px",Ce.style.visibility!=="hidden"&&(this.elementHint.style.width=f(this.elementHint.innerText)+Ce.clientWidth+"px")}},hide:function(){ve.style.visibility="hidden"},refresh:function(ce,de){ve.style.visibility="hidden",Te=0,ve.textContent="";var be=window.innerHeight||document.documentElement.clientHeight,Me=ve.parentNode.getBoundingClientRect(),fe=Me.top-6,be=be-Me.bottom-6,ke=(ye=[],typeof K.filter=="function"?K.filter:X[K.filter]),Me=ke?de.filter(function(Ye){return ke(K.caseSensitive?ce:ce.toLowerCase(),K.caseSensitive?Ye:Ye.toLowerCase(),K)}):[];(ye=Me.map(function(Ye){var Ve=document.createElement("div"),Qe=(Ve.className="item",Ve.onmouseover=S,Ve.onmouseout=$,Ve.onmousedown=M,Ve.__hint=Ye,Ve.textContent="",Ve.appendChild(document.createTextNode(Ye.substring(0,ce.length))),document.createElement("b"));return Qe.appendChild(document.createTextNode(Ye.substring(ce.length))),Ve.appendChild(Qe),ve.appendChild(Ve),Ve})).length===0||ye.length===1&&(ce.toLowerCase()===ye[0].__hint.toLowerCase()&&!K.caseSensitive||ce===ye[0].__hint&&K.caseSensitive)||ye.length<2||(Se.highlight(0),3*be<fe?(ve.style.maxHeight=fe+"px",ve.style.top="",ve.style.bottom="100%"):(ve.style.top="100%",ve.style.bottom="",ve.style.maxHeight=be+"px"),ve.style.visibility="visible")},highlight:function(ce){_e!==-1&&ye[_e]&&(ye[_e].className="item"),ye[ce].className="item hover",_e=ce},move:function(ce){return ve.style.visibility==="hidden"?"":(Te+ce!==-1&&Te+ce!==ye.length&&(Te+=ce,Se.highlight(Te)),ye[Te].__hint)},onmouseselection:function(){}},ae=function(ce){var de=(ce=ce||window.event).keyCode;if(this.elementHint!=null&&de!==33&&de!==34)if(de===27)ue.hideDropDown(),ue.element.focus(),ce.preventDefault(),ce.stopPropagation();else{var fe,be=(be=this.element.innerText).replace(`
`,"");if(0<=K.confirmKeys.indexOf(de))de===9&&this.elementHint.innerText.length===0&&ue.onTab(),0<this.elementHint.innerText.length&&this.element.innerText!==this.elementHint.realInnerText&&(this.element.innerText=this.elementHint.realInnerText,ue.hideDropDown(),G(this.element),de===9&&(ue.element.focus(),ce.preventDefault(),ce.stopPropagation()));else if(de===13)if(this.elementHint.innerText.length===0)ue.onEnter();else{var ke=Ce.style.visibility==="hidden";if($e.hide(),ke)return ue.hideDropDown(),ue.element.focus(),void ue.onEnter();this.element.innerText=this.elementHint.realInnerText,ue.hideDropDown(),G(this.element),ce.preventDefault(),ce.stopPropagation()}else de===40?(ke=be.substring(this.startFrom),(fe=$e.move(1))===""&&ue.onArrowDown(),this.elementHint.innerText=te+ke+fe.substring(ke.length),this.elementHint.realInnerText=te+fe,ce.preventDefault(),ce.stopPropagation()):de===38&&(ke=be.substring(this.startFrom),(fe=$e.move(-1))===""&&ue.onArrowUp(),this.elementHint.innerText=te+ke+fe.substring(ke.length),this.elementHint.realInnerText=te+fe,ce.preventDefault(),ce.stopPropagation())}}.bind(ue),pe=function(ce){ue.hideDropDown()},$e.onmouseselection=function(ce,de){de.element.innerText=de.elementHint.innerText=te+ce,de.hideDropDown(),window.setTimeout(function(){de.element.focus(),G(de.element)},1)},ue)),this.options.history&&this.options.mode!=="view"&&(this.history=new T(this)),this._createFrame(),this._createTable()},D.destroy=function(){this.frame&&this.container&&this.frame.parentNode===this.container&&(this.container.removeChild(this.frame),this.frame=null),this.container=null,this.dom=null,this.clear(),this.node=null,this.focusTarget=null,this.selection=null,this.multiselection=null,this.errorNodes=null,this.validateSchema=null,this._debouncedValidate=null,this.history&&(this.history.destroy(),this.history=null),this.searchBox&&(this.searchBox.destroy(),this.searchBox=null),this.modeSwitcher&&(this.modeSwitcher.destroy(),this.modeSwitcher=null),this.frameFocusTracker.destroy()},D._setOptions=function(R){var H=this;this.options={search:!0,history:!0,mode:"tree",name:void 0,schema:null,schemaRefs:null,autocomplete:null,navigationBar:!0,mainMenuBar:!0,limitDragging:!1,onSelectionChange:null,colorPicker:!0,onColorPicker:function(G,f,S){var $;z()?($=G.getBoundingClientRect().top,$=(0,b.getWindow)(G).innerHeight-$<300&&300<$,new(z())({parent:G,color:f,popup:$?"top":"bottom",onDone:function(M){M=M.rgba[3]===1?M.hex.substr(0,7):M.hex,S(M)}}).show()):console.warn("Cannot open color picker: the `vanilla-picker` library is not included in the bundle. Either use the full bundle or implement your own color picker using `onColorPicker`.")},timestampTag:!0,timestampFormat:null,createQuery:F.r,executeQuery:F.J,onEvent:null,enableSort:!0,enableTransform:!0},R&&(Object.keys(R).forEach(function(G){H.options[G]=R[G]}),R.limitDragging==null&&R.schema!=null&&(this.options.limitDragging=!0)),this.setSchema(this.options.schema,this.options.schemaRefs),this._debouncedValidate=(0,b.debounce)(this._validateAndCatch.bind(this),this.DEBOUNCE_INTERVAL),R.onSelectionChange&&this.onSelectionChange(R.onSelectionChange),(0,W.cC)(this.options.languages),(0,W.m0)(this.options.language)},D.set=function(R){R instanceof Function||R===void 0?this.clear():(this.content.removeChild(this.table),R={field:this.options.name,value:R},R=new o(this,R),this._setRoot(R),this._validateAndCatch(),this.node.expand(!1),this.content.appendChild(this.table)),this.history&&this.history.clear(),this.searchBox&&this.searchBox.clear()},D.update=function(R){var H,G;this.node.deepEqual(R)||(H=this.getSelection(),this.onChangeDisabled=!0,this.node.update(R),this.onChangeDisabled=!1,this._validateAndCatch(),this.searchBox&&!this.searchBox.isEmpty()&&this.searchBox.forceSearch(),H&&H.start&&H.end&&(R=this.node.findNodeByPath(H.start.path),G=this.node.findNodeByPath(H.end.path),R&&G)?this.setSelection(H.start,H.end):this.setSelection({},{}))},D.get=function(){if(this.node)return this.node.getValue()},D.getText=function(){return JSON.stringify(this.get())},D.setText=function(R){try{this.set((0,b.parse)(R))}catch{R=(0,b.tryJsonRepair)(R),this.set((0,b.parse)(R))}},D.updateText=function(R){try{this.update((0,b.parse)(R))}catch{R=(0,b.tryJsonRepair)(R),this.update((0,b.parse)(R))}},D.setName=function(R){this.options.name=R,this.node&&this.node.updateField(this.options.name)},D.getName=function(){return this.options.name},D.focus=function(){var R=this.scrollableContent.querySelector("[contenteditable=true]");R?R.focus():this.node.dom.expand?this.node.dom.expand.focus():this.node.dom.menu?this.node.dom.menu.focus():(R=this.frame.querySelector("button"))&&R.focus()},D.clear=function(){this.node&&(this.node.hide(),delete this.node),this.treePath&&this.treePath.reset()},D._setRoot=function(R){this.clear(),(this.node=R).setParent(null),R.setField(this.getName(),!1),delete R.index,this.tbody.appendChild(R.getDom())},D.search=function(R){var H;return this.node?(this.content.removeChild(this.table),H=this.node.search(R),this.content.appendChild(this.table)):H=[],H},D.expandAll=function(){this.node&&(this.content.removeChild(this.table),this.node.expand(),this.content.appendChild(this.table))},D.collapseAll=function(){this.node&&(this.content.removeChild(this.table),this.node.collapse(),this.content.appendChild(this.table))},D.expand=function(R){var H;!R||(H=this.node?this.node.findNodeByPath(R.path):null)&&(R.isExpand?H.expand(R.recursive):H.collapse(R.recursive))},D._onAction=function(R,H){this.history&&this.history.add(R,H),this._onChange()},D._onChange=function(){if(!this.onChangeDisabled){var R;if(this.selection=this.getDomSelection(),this._debouncedValidate(),this.treePath&&((R=this.node&&this.selection?this.node.findNodeByInternalPath(this.selection.path):this.multiselection?this.multiselection.nodes[0]:void 0)?this._updateTreePath(R.getNodePath()):this.treePath.reset()),this.options.onChange)try{this.options.onChange()}catch(H){console.error("Error in onChange callback: ",H)}if(this.options.onChangeJSON)try{this.options.onChangeJSON(this.get())}catch(H){console.error("Error in onChangeJSON callback: ",H)}if(this.options.onChangeText)try{this.options.onChangeText(this.getText())}catch(H){console.error("Error in onChangeText callback: ",H)}if(this.options.onClassName&&this.node.recursivelyUpdateCssClassesOnNodes(),this.options.onNodeName&&this.node.childs)try{this.node.recursivelyUpdateNodeName()}catch(H){console.error("Error in onNodeName callback: ",H)}}},D.validate=function(){var R=this,H=this.node;if(H){var G=H.getValue(),f=[];this.validateSchema&&!this.validateSchema(G)&&(f=this.validateSchema.errors.map(function(M){return(0,b.improveSchemaError)(M)}).map(function(M){return{node:H.findNode(M.dataPath),error:M,type:"validation"}}).filter(function(M){return M.node!=null}));try{this.validationSequence++;var S=this,$=this.validationSequence;return this._validateCustom(G).then(function(M){return $===S.validationSequence&&(M=[].concat(f,M||[]),S._renderValidationErrors(M),typeof R.options.onValidationError=="function"&&(0,b.isValidationErrorChanged)(M,R.lastSchemaErrors)&&R.options.onValidationError.call(R,M),R.lastSchemaErrors=M),R.lastSchemaErrors})}catch(M){return Promise.reject(M)}}},D._validateAndCatch=function(){this.validate().catch(function(R){console.error("Error running validation:",R)})},D._renderValidationErrors=function(R){this.errorNodes&&this.errorNodes.forEach(function(G){G.setError(null)});var H=R.reduce(function(G,f){return f.node.findParents().filter(function(S){return!G.some(function($){return $[0]===S})}).map(function(S){return[S,f.node]}).concat(G)},[]);this.errorNodes=H.map(function(G){return{node:G[0],child:G[1],error:{message:G[0].type==="object"?(0,W.Iu)("containsInvalidProperties"):(0,W.Iu)("containsInvalidItems")}}}).concat(R).map(function(G){return G.node.setError(G.error,G.child),G.node})},D._validateCustom=function(R){try{var H,G;if(this.options.onValidate)return H=this.node,G=this.options.onValidate(R),((0,b.isPromise)(G)?G:Promise.resolve(G)).then(function(f){return Array.isArray(f)?f.filter(function(S){var $=(0,b.isValidValidationError)(S);return $||console.warn('Ignoring a custom validation error with invalid structure. Expected structure: {path: [...], message: "..."}. Actual error:',S),$}).map(function(S){var $;try{$=S&&S.path?H.findNodeByPath(S.path):null}catch{}return $||console.warn("Ignoring validation error: node not found. Path:",S.path,"Error:",S),{node:$,error:S,type:"customValidation"}}).filter(function(S){return S&&S.node&&S.error&&S.error.message}):null})}catch(f){return Promise.reject(f)}return Promise.resolve(null)},D.refresh=function(){this.node&&this.node.updateDom({recurse:!0})},D.startAutoScroll=function(R){var H=this,G=this.scrollableContent,f=(0,b.getAbsoluteTop)(G),S=G.clientHeight,$=f+S;R<f+24&&0<G.scrollTop?this.autoScrollStep=(f+24-R)/3:$-24<R&&S+G.scrollTop<G.scrollHeight?this.autoScrollStep=($-24-R)/3:this.autoScrollStep=void 0,this.autoScrollStep?this.autoScrollTimer||(this.autoScrollTimer=setInterval(function(){H.autoScrollStep?G.scrollTop-=H.autoScrollStep:H.stopAutoScroll()},50)):this.stopAutoScroll()},D.stopAutoScroll=function(){this.autoScrollTimer&&(clearTimeout(this.autoScrollTimer),delete this.autoScrollTimer),this.autoScrollStep&&delete this.autoScrollStep},D.setDomSelection=function(R){var H,G,f;R&&("scrollTop"in R&&this.scrollableContent&&(this.scrollableContent.scrollTop=R.scrollTop),R.paths?(H=this,G=R.paths.map(function(S){return H.node.findNodeByInternalPath(S)}),this.select(G)):(f=(G=R.path?this.node.findNodeByInternalPath(R.path):null)&&R.domName?G.dom[R.domName]:null,R.range&&f?(R=Object.assign({},R.range,{container:f}),(0,b.setSelectionOffset)(R)):G&&G.focus()))},D.getDomSelection=function(){var R=o.getNodeFromTarget(this.focusTarget),H=this.focusTarget,G=R?Object.keys(R.dom).find(function(S){return R.dom[S]===H}):null,f=(0,b.getSelectionOffset)();return(f=(f=f&&f.container.nodeName!=="DIV"?null:f)&&f.container!==H?null:f)&&delete f.container,{path:R?R.getInternalPath():null,domName:G,range:f,paths:0<this.multiselection.length?this.multiselection.nodes.map(function(S){return S.getInternalPath()}):null,scrollTop:this.scrollableContent?this.scrollableContent.scrollTop:0}},D.scrollTo=function(R,H){var G,f,S,$,M=this.scrollableContent;M?((G=this).animateTimeout&&(clearTimeout(G.animateTimeout),delete G.animateTimeout),G.animateCallback&&(G.animateCallback(!1),delete G.animateCallback),f=M.clientHeight,S=M.scrollHeight-f,$=Math.min(Math.max(R-f/4,0),S),function K(){var Q=M.scrollTop,Q=$-Q;3<Math.abs(Q)?(M.scrollTop+=Q/3,G.animateCallback=H,G.animateTimeout=setTimeout(K,50)):(H&&H(!0),M.scrollTop=$,delete G.animateTimeout,delete G.animateCallback)}()):H&&H(!1)},D._createFrame=function(){var R=this,H=(this.frame=document.createElement("div"),this.frame.className="jsoneditor jsoneditor-mode-"+this.options.mode,this.container.appendChild(this.frame),this.contentOuter=document.createElement("div"),this.contentOuter.className="jsoneditor-outer",this);function G(K){H._onEvent&&H._onEvent(K)}var f,S,$,M={target:this.frame,onFocus:this.options.onFocus||null,onBlur:this.options.onBlur||null};this.frameFocusTracker=new N.R(M),this.frame.onclick=function(K){var Q=K.target;G(K),Q.nodeName==="BUTTON"&&K.preventDefault()},this.frame.oninput=G,this.frame.onchange=G,this.frame.onkeydown=G,this.frame.onkeyup=G,this.frame.oncut=G,this.frame.onpaste=G,this.frame.onmousedown=G,this.frame.onmouseup=G,this.frame.onmouseover=G,this.frame.onmouseout=G,(0,b.addEventListener)(this.frame,"focus",G,!0),(0,b.addEventListener)(this.frame,"blur",G,!0),this.frame.onfocusin=G,this.frame.onfocusout=G,this.options.mainMenuBar&&((0,b.addClassName)(this.contentOuter,"has-main-menu-bar"),this.menu=document.createElement("div"),this.menu.className="jsoneditor-menu",this.frame.appendChild(this.menu),(M=document.createElement("button")).type="button",M.className="jsoneditor-expand-all",M.title=(0,W.Iu)("expandAll"),M.onclick=function(){H.expandAll(),typeof R.options.onExpand=="function"&&R.options.onExpand({path:[],isExpand:!0,recursive:!0})},this.menu.appendChild(M),(M=document.createElement("button")).type="button",M.title=(0,W.Iu)("collapseAll"),M.className="jsoneditor-collapse-all",M.onclick=function(){H.collapseAll(),typeof R.options.onExpand=="function"&&R.options.onExpand({path:[],isExpand:!1,recursive:!0})},this.menu.appendChild(M),this.options.enableSort&&((M=document.createElement("button")).type="button",M.className="jsoneditor-sort",M.title=(0,W.Iu)("sortTitleShort"),M.onclick=function(){H.node.showSortModal()},this.menu.appendChild(M)),this.options.enableTransform&&((M=document.createElement("button")).type="button",M.title=(0,W.Iu)("transformTitleShort"),M.className="jsoneditor-transform",M.onclick=function(){H.node.showTransformModal()},this.menu.appendChild(M)),this.history&&((f=document.createElement("button")).type="button",f.className="jsoneditor-undo jsoneditor-separator",f.title=(0,W.Iu)("undo"),f.onclick=function(){H._onUndo()},this.menu.appendChild(f),this.dom.undo=f,(S=document.createElement("button")).type="button",S.className="jsoneditor-redo",S.title=(0,W.Iu)("redo"),S.onclick=function(){H._onRedo()},this.menu.appendChild(S),this.dom.redo=S,this.history.onChange=function(){f.disabled=!H.history.canUndo(),S.disabled=!H.history.canRedo()},this.history.onChange()),this.options&&this.options.modes&&this.options.modes.length&&(($=this).modeSwitcher=new L.x(this.menu,this.options.modes,this.options.mode,function(K){try{$.setMode(K),$.modeSwitcher.focus()}catch(Q){$._onError(Q)}})),this.options.search&&(this.searchBox=new E(this,this.menu))),this.options.navigationBar&&(this.navBar=document.createElement("div"),this.navBar.className="jsoneditor-navigation-bar nav-bar-empty",this.frame.appendChild(this.navBar),this.treePath=new P(this.navBar,this.getPopupAnchor()),this.treePath.onSectionSelected(this._onTreePathSectionSelected.bind(this)),this.treePath.onContextMenuItemSelected(this._onTreePathMenuItemSelected.bind(this)))},D._onUndo=function(){this.history&&(this.history.undo(),this._onChange())},D._onRedo=function(){this.history&&(this.history.redo(),this._onChange())},D._onEvent=function(R){if(!o.targetIsColorPicker(R.target)){var H,G=o.getNodeFromTarget(R.target);if(R.type==="keydown"&&this._onKeyDown(R),G&&R.type==="focus"&&(this.focusTarget=R.target,this.options.autocomplete&&this.options.autocomplete.trigger==="focus"&&this._showAutoComplete(R.target)),R.type==="mousedown"&&this._startDragDistance(R),R.type!=="mousemove"&&R.type!=="mouseup"&&R.type!=="click"||this._updateDragDistance(R),G&&this.options&&this.options.navigationBar&&G&&(R.type==="keydown"||R.type==="mousedown")&&(H=this,setTimeout(function(){H._updateTreePath(G.getNodePath())})),G&&G.selected){if(R.type==="click"){if(R.target===G.dom.menu)return void this.showContextMenu(R.target);R.hasMoved||this.deselect()}R.type==="mousedown"&&o.onDragStart(this.multiselection.nodes,R)}else R.type==="mousedown"&&(0,b.hasParentNode)(R.target,this.content)&&(this.deselect(),G&&R.target===G.dom.drag?o.onDragStart(G,R):G&&(R.target===G.dom.field||R.target===G.dom.value||R.target===G.dom.select)||this._onMultiSelectStart(R));G&&G.onEvent(R)}},D._updateTreePath=function(R){var H;function G(f){return f.parent?f.parent.type==="array"?f.index:f.field:f.field||f.type}R&&R.length?((0,b.removeClassName)(this.navBar,"nav-bar-empty"),H=[],R.forEach(function(f){var S={name:G(f),node:f,children:[]};f.childs&&f.childs.length&&f.childs.forEach(function($){S.children.push({name:G($),node:$})}),H.push(S)}),this.treePath.setPath(H)):(0,b.addClassName)(this.navBar,"nav-bar-empty")},D._onTreePathSectionSelected=function(R){R&&R.node&&(R.node.expandTo(),R.node.focus())},D._onTreePathMenuItemSelected=function(R,H){R&&R.children.length&&(R=R.children.find(function(G){return G.name===H}))&&R.node&&(this._updateTreePath(R.node.getNodePath()),R.node.expandTo(),R.node.focus())},D._startDragDistance=function(R){this.dragDistanceEvent={initialTarget:R.target,initialPageX:R.pageX,initialPageY:R.pageY,dragDistance:0,hasMoved:!1}},D._updateDragDistance=function(R){this.dragDistanceEvent||this._startDragDistance(R);var H=R.pageX-this.dragDistanceEvent.initialPageX,G=R.pageY-this.dragDistanceEvent.initialPageY;return this.dragDistanceEvent.dragDistance=Math.sqrt(H*H+G*G),this.dragDistanceEvent.hasMoved=this.dragDistanceEvent.hasMoved||10<this.dragDistanceEvent.dragDistance,R.dragDistance=this.dragDistanceEvent.dragDistance,R.hasMoved=this.dragDistanceEvent.hasMoved,R.dragDistance},D._onMultiSelectStart=function(R){var H,G=o.getNodeFromTarget(R.target);this.options.mode==="tree"&&this.options.onEditable===void 0&&(this.multiselection={start:G||null,end:null,nodes:[]},this._startDragDistance(R),(H=this).mousemove||(this.mousemove=(0,b.addEventListener)(R.view,"mousemove",function(f){H._onMultiSelect(f)})),this.mouseup||(this.mouseup=(0,b.addEventListener)(R.view,"mouseup",function(f){H._onMultiSelectEnd(f)})),R.preventDefault())},D._onMultiSelect=function(R){var H;R.preventDefault(),this._updateDragDistance(R),R.hasMoved&&((R=o.getNodeFromTarget(R.target))&&(this.multiselection.start==null&&(this.multiselection.start=R),this.multiselection.end=R),this.deselect(),R=this.multiselection.start,H=this.multiselection.end||this.multiselection.start,R&&H&&(this.multiselection.nodes=this._findTopLevelNodes(R,H),this.multiselection.nodes&&this.multiselection.nodes.length&&(R=this.multiselection.nodes[0],this.multiselection.start===R||this.multiselection.start.isDescendantOf(R)?this.multiselection.direction="down":this.multiselection.direction="up"),this.select(this.multiselection.nodes)))},D._onMultiSelectEnd=function(R){var H=this.multiselection.nodes[0];H&&H.dom.menu&&H.dom.menu.focus(),this.multiselection.start=null,this.multiselection.end=null,this.mousemove&&((0,b.removeEventListener)(R.view,"mousemove",this.mousemove),delete this.mousemove),this.mouseup&&((0,b.removeEventListener)(R.view,"mouseup",this.mouseup),delete this.mouseup)},D.deselect=function(R){var H=!!this.multiselection.nodes.length;this.multiselection.nodes.forEach(function(G){G.setSelected(!1)}),this.multiselection.nodes=[],R&&(this.multiselection.start=null,this.multiselection.end=null),H&&this._selectionChangedHandler&&this._selectionChangedHandler()},D.select=function(R){if(!Array.isArray(R))return this.select([R]);var H;R&&(this.deselect(),this.multiselection.nodes=R.slice(0),H=R[0],R.forEach(function(G){G.expandPathToNode(),G.setSelected(!0,G===H)}),this._selectionChangedHandler&&(R=this.getSelection(),this._selectionChangedHandler(R.start,R.end)))},D._findTopLevelNodes=function(M,K){for(var G=M.getNodePath(),f=K.getNodePath(),S=0;S<G.length&&G[S]===f[S];)S++;var $,M=G[S-1],K=G[S],Q=f[S];return K&&Q||(M.parent?M=(Q=K=M).parent:(K=M.childs[0],Q=M.childs[M.childs.length-1])),M&&K&&Q?(K=M.childs.indexOf(K),Q=M.childs.indexOf(Q),$=Math.min(K,Q),K=Math.max(K,Q),M.childs.slice($,K+1)):[]},D._showAutoComplete=function(R){var H,G=o.getNodeFromTarget(R),f="";0<=R.className.indexOf("jsoneditor-value")&&(f="value"),(f=0<=R.className.indexOf("jsoneditor-field")?"field":f)!==""&&(H=this,setTimeout(function(){var S;!G||!(H.options.autocomplete.trigger==="focus"||0<R.innerText.length)||(S=H.options.autocomplete.getOptions(R.innerText,G.getPath(),f,G.editor))===null?H.autocomplete.hideDropDown():typeof S.then=="function"?S.then(function($){$===null?H.autocomplete.hideDropDown():$.options?H.autocomplete.show(R,$.startFrom,$.options):H.autocomplete.show(R,0,$)}).catch(function($){console.error($)}):S.options?H.autocomplete.show(R,S.startFrom,S.options):H.autocomplete.show(R,0,S)},50))},D._onKeyDown=function(R){var H,G=R.which||R.keyCode,f=R.altKey,S=R.ctrlKey,$=R.metaKey,M=R.shiftKey,K=!1,Q=this.focusTarget;G===9&&(H=this,setTimeout(function(){H.focusTarget!==Q&&(0,b.selectContentEditable)(H.focusTarget)},0)),this.searchBox&&(S&&G===70?(this.searchBox.dom.search.focus(),this.searchBox.dom.search.select(),K=!0):(G===114||S&&G===71)&&(M?this.searchBox.previous(!0):this.searchBox.next(!0),K=!0)),this.history&&(S&&!M&&G===90?(this._onUndo(),K=!0):S&&M&&G===90&&(this._onRedo(),K=!0)),!this.options.autocomplete||K||S||f||$||R.key.length!==1&&G!==8&&G!==46||(K=!1,this._showAutoComplete(R.target)),K&&(R.preventDefault(),R.stopPropagation())},D._createTable=function(){var R;this.options.navigationBar&&(0,b.addClassName)(this.contentOuter,"has-nav-bar"),this.scrollableContent=document.createElement("div"),this.scrollableContent.className="jsoneditor-tree",this.contentOuter.appendChild(this.scrollableContent),this.content=document.createElement("div"),this.content.className="jsoneditor-tree-inner",this.scrollableContent.appendChild(this.content),this.table=document.createElement("table"),this.table.className="jsoneditor-tree",this.content.appendChild(this.table),this.colgroupContent=document.createElement("colgroup"),this.options.mode==="tree"&&((R=document.createElement("col")).width="24px",this.colgroupContent.appendChild(R)),(R=document.createElement("col")).width="24px",this.colgroupContent.appendChild(R),R=document.createElement("col"),this.colgroupContent.appendChild(R),this.table.appendChild(this.colgroupContent),this.tbody=document.createElement("tbody"),this.table.appendChild(this.tbody),this.frame.appendChild(this.contentOuter)},D.showContextMenu=function(R,H){var G,f=[],S=this.multiselection.nodes.slice();f.push({text:(0,W.Iu)("duplicateText"),title:(0,W.Iu)("duplicateTitle"),className:"jsoneditor-duplicate",click:function(){o.onDuplicate(S)}}),f.push({text:(0,W.Iu)("remove"),title:(0,W.Iu)("removeTitle"),className:"jsoneditor-remove",click:function(){o.onRemove(S)}}),this.options.onCreateMenu&&(G=S.map(function($){return $.getPath()}),f=this.options.onCreateMenu(f,{type:"multiple",path:G[0],paths:G})),new k.x(f,{close:H}).show(R,this.getPopupAnchor())},D.getPopupAnchor=function(){return this.options.popupAnchor||this.frame},D.getSelection=function(){var R,H,G={start:null,end:null};return this.multiselection.nodes&&this.multiselection.nodes.length&&this.multiselection.nodes.length&&(R=this.multiselection.nodes[0],H=this.multiselection.nodes[this.multiselection.nodes.length-1],this.multiselection.direction==="down"?(G.start=R.serialize(),G.end=H.serialize()):(G.start=H.serialize(),G.end=R.serialize())),G},D.onSelectionChange=function(R){typeof R=="function"&&(this._selectionChangedHandler=(0,b.debounce)(R,this.DEBOUNCE_INTERVAL))},D.setSelection=function(R,H){R&&R.dom&&R.range&&(console.warn("setSelection/getSelection usage for text selection is deprecated and should not be used, see documentation for supported selection options"),this.setDomSelection(R)),R=this._getNodeInstancesByRange(R,H),R.forEach(function(G){G.expandTo()}),this.select(R)},D._getNodeInstancesByRange=function(R,H){R&&R.path&&(G=this.node.findNodeByPath(R.path),H&&H.path&&(f=this.node.findNodeByPath(H.path)));var G,f,S=[];if(G instanceof o)if(f instanceof o&&f!==G)if(G.parent===f.parent){H=G.getIndex()<f.getIndex()?(R=G,f):(R=f,G);var $=R;for(S.push($);$=$.nextSibling(),S.push($),$&&$!==H;);}else S=this._findTopLevelNodes(G,f);else S.push(G);return S},D.getNodesByRange=function(G,H){var G=this._getNodeInstancesByRange(G,H),f=[];return G.forEach(function(S){f.push(S.serialize())}),f},[{mode:"tree",mixin:D,data:"json"},{mode:"view",mixin:D,data:"json"},{mode:"form",mixin:D,data:"json"}])},2744:function(ie,u,V){u.tryRequireAjv=function(){try{return V(8903)}catch{}}},9125:function(ie,u,V){u.O=function(){try{V(4864)}catch(X){console.error(X)}}},9791:function(ie,k,V){V.r(k),V.d(k,{addClassName:function(){return A},addEventListener:function(){return R},asyncExec:function(){return Qe},clear:function(){return t},compileJSONPointer:function(){return ve},contains:function(){return Me},debounce:function(){return te},escapeUnicodeChars:function(){return l},extend:function(){return n},findUniqueName:function(){return ue},formatSize:function(){return fe},get:function(){return Se},getAbsoluteLeft:function(){return c},getAbsoluteTop:function(){return h},getChildPaths:function(){return $e},getColorCSS:function(){return ye},getIndexForPosition:function(){return ge},getInnerText:function(){return _},getInputSelection:function(){return Ae},getInternetExplorerVersion:function(){return z},getPositionForPath:function(){return Ce},getSelection:function(){return I},getSelectionOffset:function(){return B},getType:function(){return i},getWindow:function(){return o},hasParentNode:function(){return j},improveSchemaError:function(){return $},insideRect:function(){return Q},isArray:function(){return a},isChildOf:function(){return G},isFirefox:function(){return Y},isObject:function(){return ke},isPromise:function(){return M},isTimestamp:function(){return de},isUrl:function(){return r},isValidColor:function(){return Te},isValidValidationError:function(){return K},isValidationErrorChanged:function(){return Ye},limitCharacters:function(){return be},makeFieldTooltip:function(){return _e},parse:function(){return x},parsePath:function(){return f},parseString:function(){return ce},removeAllClassNames:function(){return v},removeClassName:function(){return d},removeEventListener:function(){return H},removeReturnsAndSurroundingWhitespace:function(){return P},selectContentEditable:function(){return w},setEndOfContentEditable:function(){return y},setSelection:function(){return T},setSelectionOffset:function(){return E},sort:function(){return ae},sortObjectKeys:function(){return pe},stringifyPath:function(){return S},stripFormatting:function(){return g},textDiff:function(){return he},tryJsonRepair:function(){return p},uniqueMergeArrays:function(){return Ve},validate:function(){return s}}),V(4987);var k=V(233),X=V.n(k),k=V(3860),N=V.n(k),Z=V(6589),O=V(7026),W=V(7907);function F(J){return function(ne){if(Array.isArray(ne))return L(ne)}(J)||function(ne){if(typeof Symbol!="undefined"&&ne[Symbol.iterator]!=null||ne["@@iterator"]!=null)return Array.from(ne)}(J)||function(ne,oe){var me;if(ne)return typeof ne=="string"?L(ne,oe):(me=(me=Object.prototype.toString.call(ne).slice(8,-1))==="Object"&&ne.constructor?ne.constructor.name:me)==="Map"||me==="Set"?Array.from(ne):me==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(me)?L(ne,oe):void 0}(J)||function(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}()}function L(J,ne){(ne==null||ne>J.length)&&(ne=J.length);for(var oe=0,me=new Array(ne);oe<ne;oe++)me[oe]=J[oe];return me}function C(J){return(C=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(ne){return typeof ne}:function(ne){return ne&&typeof Symbol=="function"&&ne.constructor===Symbol&&ne!==Symbol.prototype?"symbol":typeof ne})(J)}var m=1e4,b=9466848e5;function x(J){try{return JSON.parse(J)}catch(ne){throw s(J),ne}}function p(J){try{return N()(J)}catch{return J}}function l(J){return J.replace(/[\u007F-\uFFFF]/g,function(ne){return"\\u"+("0000"+ne.charCodeAt(0).toString(16)).slice(-4)})}function s(J){(Z!==void 0?Z:JSON).parse(J)}function n(J,ne){for(var oe in ne)yt(ne,oe)&&(J[oe]=ne[oe]);return J}function t(J){for(var ne in J)yt(J,ne)&&delete J[ne];return J}function i(J){return J===null?"null":J===void 0?"undefined":J instanceof Number||typeof J=="number"?"number":J instanceof String||typeof J=="string"?"string":J instanceof Boolean||typeof J=="boolean"?"boolean":J instanceof RegExp?"regexp":a(J)?"array":"object"}var e=/^https?:\/\/\S+$/;function r(J){return(typeof J=="string"||J instanceof String)&&e.test(J)}function a(J){return Object.prototype.toString.call(J)==="[object Array]"}function o(J){return J.ownerDocument.defaultView}function c(J){return J.getBoundingClientRect().left+window.pageXOffset||document.scrollLeft||0}function h(J){return J.getBoundingClientRect().top+window.pageYOffset||document.scrollTop||0}function A(J,ne){var oe=J.className.split(" ");oe.indexOf(ne)===-1&&(oe.push(ne),J.className=oe.join(" "))}function v(J){J.className=""}function d(J,me){var oe=J.className.split(" "),me=oe.indexOf(me);me!==-1&&(oe.splice(me,1),J.className=oe.join(" "))}function g(J){for(var ne=J.childNodes,oe=0,me=ne.length;oe<me;oe++){var xe=ne[oe],we=(xe.style&&xe.removeAttribute("style"),xe.attributes);if(we)for(var We=we.length-1;0<=We;We--){var De=we[We];De.specified===!0&&xe.removeAttribute(De.name)}g(xe)}}function y(J){var ne;document.createRange&&((ne=document.createRange()).selectNodeContents(J),ne.collapse(!1),(J=window.getSelection()).removeAllRanges(),J.addRange(ne))}function w(J){var ne;J&&J.nodeName==="DIV"&&window.getSelection&&document.createRange&&((ne=document.createRange()).selectNodeContents(J),(J=window.getSelection()).removeAllRanges(),J.addRange(ne))}function I(){if(window.getSelection){var J=window.getSelection();if(J.getRangeAt&&J.rangeCount)return J.getRangeAt(0)}return null}function T(J){var ne;J&&window.getSelection&&((ne=window.getSelection()).removeAllRanges(),ne.addRange(J))}function B(){var J=I();return J&&"startOffset"in J&&"endOffset"in J&&J.startContainer&&J.startContainer===J.endContainer?{startOffset:J.startOffset,endOffset:J.endOffset,container:J.startContainer.parentNode}:null}function E(J){var ne;document.createRange&&window.getSelection&&window.getSelection()&&(ne=document.createRange(),J.container.firstChild||J.container.appendChild(document.createTextNode("")),ne.setStart(J.container.firstChild,J.startOffset),ne.setEnd(J.container.firstChild,J.endOffset),T(ne))}function _(J,ne){var oe;if(ne===void 0&&(ne={_text:"",flush:function(){var at=this._text;return this._text="",at},set:function(at){this._text=at}}),J.nodeValue)return(oe=P(J.nodeValue))!==""?ne.flush()+oe:"";if(J.hasChildNodes()){for(var me=J.childNodes,xe="",we=0,We=me.length;we<We;we++){var De,Ue=me[we];Ue.nodeName==="DIV"||Ue.nodeName==="P"?((De=(De=me[we-1])?De.nodeName:void 0)&&De!=="DIV"&&De!=="P"&&De!=="BR"&&(xe!==""&&(xe+=`
`),ne.flush()),xe+=_(Ue,ne),ne.set(`
`)):Ue.nodeName==="BR"?(xe+=ne.flush(),ne.set(`
`)):xe+=_(Ue,ne)}return xe}return""}function P(J){return J.replace(/(\b|^)\s*(\b|$)/g,function(ne){return/\n/.exec(ne)?"":ne})}function j(J,ne){for(var oe=J?J.parentNode:void 0;oe;){if(oe===ne)return!0;oe=oe.parentNode}return!1}function z(){var J;return D===-1&&(J=-1,typeof navigator!="undefined"&&navigator.appName==="Microsoft Internet Explorer"&&/MSIE ([0-9]+[.0-9]+)/.exec(navigator.userAgent)!=null&&(J=parseFloat(RegExp.$1)),D=J),D}var D=-1;function Y(){return typeof navigator!="undefined"&&navigator.userAgent.indexOf("Firefox")!==-1}function R(J,ne,oe,me){return J.addEventListener?(me===void 0&&(me=!1),ne==="mousewheel"&&Y()&&(ne="DOMMouseScroll"),J.addEventListener(ne,oe,me),oe):J.attachEvent?(J.attachEvent("on"+ne,me=function(){return oe.call(J,window.event)}),me):void 0}function H(J,ne,oe,me){J.removeEventListener?(me===void 0&&(me=!1),ne==="mousewheel"&&Y()&&(ne="DOMMouseScroll"),J.removeEventListener(ne,oe,me)):J.detachEvent&&J.detachEvent("on"+ne,oe)}function G(J,ne){for(var oe=J.parentNode;oe;){if(oe===ne)return!0;oe=oe.parentNode}return!1}function f(J){var ne=[],oe=0;function me(we){for(var We="";J[oe]!==void 0&&J[oe]!==we;)We+=J[oe],oe++;if(J[oe]!==we)throw new Error("Invalid JSON path: unexpected end, character "+we+" expected");return We}for(;J[oe]!==void 0;)if(J[oe]===".")oe++,ne.push(function(){for(var we="";J[oe]!==void 0&&/[\w$]/.test(J[oe]);)we+=J[oe],oe++;if(we==="")throw new Error("Invalid JSON path: property name expected at index "+oe);return we}());else{if(J[oe]!=="[")throw new Error('Invalid JSON path: unexpected character "'+J[oe]+'" at index '+oe);if(J[++oe]==="'"||J[oe]==='"'){var xe=J[oe];if(oe++,ne.push(me(xe)),J[oe]!==xe)throw new Error("Invalid JSON path: closing quote ' expected at index "+oe);oe++}else{if(xe=me("]").trim(),xe.length===0)throw new Error("Invalid JSON path: array value expected at index "+oe);xe=xe==="*"?xe:JSON.parse(xe),ne.push(xe)}if(J[oe]!=="]")throw new Error("Invalid JSON path: closing bracket ] expected at index "+oe);oe++}return ne}function S(J){return J.map(function(ne){return typeof ne=="number"?"["+ne+"]":typeof ne=="string"&&ne.match(/^[A-Za-z0-9_$]+$/)?"."+ne:'["'+ne+'"]'}).join("")}function $(J){var ne,oe;return J.keyword==="enum"&&Array.isArray(J.schema)&&(oe=J.schema)&&(5<(oe=oe.map(function(me){return JSON.stringify(me)})).length&&(ne=["("+(oe.length-5)+" more...)"],(oe=oe.slice(0,5)).push(ne)),J.message="should be equal to one of: "+oe.join(", ")),J.keyword==="additionalProperties"&&(J.message="should NOT have additional property: "+J.params.additionalProperty),J}function M(J){return J&&typeof J.then=="function"&&typeof J.catch=="function"}function K(J){return C(J)==="object"&&Array.isArray(J.path)&&typeof J.message=="string"}function Q(J,ne,oe){return oe=oe!==void 0?oe:0,ne.left-oe>=J.left&&ne.right+oe<=J.right&&ne.top-oe>=J.top&&ne.bottom+oe<=J.bottom}function te(J,ne,oe){var me;return function(){var xe=this,we=arguments,We=oe&&!me;clearTimeout(me),me=setTimeout(function(){me=null,oe||J.apply(xe,we)},ne),We&&J.apply(xe,we)}}function he(J,ne){for(var oe=ne.length,me=0,xe=J.length,we=ne.length;ne.charAt(me)===J.charAt(me)&&me<oe;)me++;for(;ne.charAt(we-1)===J.charAt(xe-1)&&me<we&&0<xe;)we--,xe--;return{start:me,end:we}}function Ae(J){var ne,oe,me,xe,we=0,We=0;return typeof J.selectionStart=="number"&&typeof J.selectionEnd=="number"?(we=J.selectionStart,We=J.selectionEnd):(xe=document.selection.createRange())&&xe.parentElement()===J&&(me=J.value.length,ne=J.value.replace(/\r\n/g,`
`),(oe=J.createTextRange()).moveToBookmark(xe.getBookmark()),(xe=J.createTextRange()).collapse(!1),-1<oe.compareEndPoints("StartToEnd",xe)?we=We=me:(we=-oe.moveStart("character",-me),we+=ne.slice(0,we).split(`
`).length-1,-1<oe.compareEndPoints("EndToEnd",xe)?We=me:(We=-oe.moveEnd("character",-me),We+=ne.slice(0,We).split(`
`).length-1))),{startIndex:we,endIndex:We,start:De(we),end:De(We)};function De(Ue){return Ue=J.value.substring(0,Ue),{row:(Ue.match(/\n/g)||[]).length+1,column:Ue.length-Ue.lastIndexOf(`
`)}}}function ge(me,ne,oe){var me=me.value||"";return 0<ne&&0<oe?(me=me.split(`
`,ne),ne=Math.min(me.length,ne),oe=Math.min(me[ne-1].length,oe-1),oe=ne===1?oe:oe+1,me.slice(0,ne-1).join(`
`).length+oe):-1}function Ce(J,ne){var oe,me=[];if(ne&&ne.length){try{oe=O.parse(J)}catch{return me}ne.forEach(function(xe){var we=ve(f(xe)),we=oe.pointers[we];we&&me.push({path:xe,line:we.key?we.key.line:we.value?we.value.line:0,column:we.key?we.key.column:we.value?we.value.column:0})})}return me}function ve(J){return J.map(function(ne){return"/"+String(ne).replace(/~/g,"~0").replace(/\//g,"~1")}).join("")}function ye(J){var ne=document.createElement("div");return ne.style.color=J,ne.style.color.split(/\s+/).join("").toLowerCase()||null}function Te(J){return!!ye(J)}function _e(J,ne){var oe;return J?(oe="",J.title&&(oe+=J.title),J.description&&(0<oe.length&&(oe+=`
`),oe+=J.description),J.default&&(0<oe.length&&(oe+=`

`),oe=(oe+=(0,W.Iu)("default",void 0,ne)+`
`)+JSON.stringify(J.default,null,2)),Array.isArray(J.examples)&&0<J.examples.length&&(0<oe.length&&(oe+=`

`),oe+=(0,W.Iu)("examples",void 0,ne)+`
`,J.examples.forEach(function(me,xe){oe+=JSON.stringify(me,null,2),xe!==J.examples.length-1&&(oe+=`
`)})),oe):""}function Se(J,ne){for(var oe=J,me=0;me<ne.length&&oe!=null;me++)oe=oe[ne[me]];return oe}function ue(J,ne){for(var oe=J.replace(/ \(copy( \d+)?\)$/,""),me=oe,xe=1;ne.indexOf(me)!==-1;)me=oe+" ("+("copy"+(1<xe?" "+xe:""))+")",xe++;return me}function $e(J,ne){var oe={};if(Array.isArray(J))for(var me=Math.min(J.length,m),xe=0;xe<me;xe++)(function we(We,De,Ue,at){(Array.isArray(We)||ke(We))&&!at||(De[Ue||""]=!0),ke(We)&&Object.keys(We).forEach(function(q){we(We[q],De,Ue+"."+q,at)})})(J[xe],oe,"",ne);else oe[""]=!0;return Object.keys(oe).sort()}function ae(J,we,oe){var me=we&&we!=="."?f(we):[],xe=oe==="desc"?-1:1,we=J.slice();return we.sort(function(We,De){return We=Se(We,me),De=Se(De,me),xe*(De<We?1:We<De?-1:0)}),we}function pe(J,me){var oe=me==="desc"?-1:1,me=Object.keys(J).sort(function(we,We){return oe*X()(we,We)}),xe={};return me.forEach(function(we){xe[we]=J[we]}),xe}function ce(J){var ne,oe;return J===""?"":(ne=J.toLowerCase())==="null"?null:ne==="true"||ne!=="false"&&(ne=Number(J),oe=parseFloat(J),isNaN(ne)||isNaN(oe)?J:ne)}function de(J,ne){return typeof ne=="number"&&b<ne&&isFinite(ne)&&Math.floor(ne)===ne&&!isNaN(new Date(ne).valueOf())}function fe(J){return J<900?J.toFixed()+" B":(J=J/1e3)<900?J.toFixed(1)+" KB":(J=J/1e3)<900?J.toFixed(1)+" MB":(J=J/1e3)<900?J.toFixed(1)+" GB":(J/1e3).toFixed(1)+" TB"}function be(J,ne){return J.length<=ne?J:J.slice(0,ne)+"..."}function ke(J){return C(J)==="object"&&J!==null&&!Array.isArray(J)}function Me(J,ne){return J.indexOf(ne)!==-1}function Ye(J,ne){if(ne||J){if(ne&&!J||!ne&&J||ne.length!==J.length)return!0;for(var oe=0;oe<J.length;++oe){var me=function(xe){if(!(J[xe].type==="error"?ne.find(function(we){return we.line===J[xe].line}):ne.find(function(we){return we.dataPath===J[xe].dataPath&&we.schemaPath===J[xe].schemaPath})))return{v:!0}}(oe);if(C(me)==="object")return me.v}}return!1}function Ve(J,ne){return J=J!=null&&J.length?J:[],ne=ne!=null&&ne.length?ne:[],F(new Set(J.concat(ne)))}function Qe(J){setTimeout(J)}function yt(J,ne){return Object.prototype.hasOwnProperty.call(J,ne)}},8037:function(ie,u,V){var X;if(window.Picker)X=window.Picker;else try{X=V(4049)}catch{}ie.exports=X},6225:function(ie,u,V){function X(C,m){var b,x;return m=L(C,m),(C=O.modules[m])||(typeof(C=O.payloads[m])=="function"&&(b={id:m,uri:"",exports:x={},packaged:!0},x=C(function(p,l){return W(m,p,l)},x,b)||b.exports,O.modules[m]=x,delete O.payloads[m]),C=O.modules[m]=x||C),C}var k,N,Z,O,W,F,L;ie=V.nmd(ie),(Z=function(){return this}())||typeof window=="undefined"||(Z=window),(O=function(C,m,b){typeof C!="string"?O.original?O.original.apply(this,arguments):(console.error("dropping module because define wasn't a string."),console.trace()):(arguments.length==2&&(b=m),O.modules[C]||(O.payloads[C]=b,O.modules[C]=null))}).modules={},O.payloads={},W=function(C,m,b){if(typeof m=="string"){var x=X(C,m);if(x!=null)return b&&b(),x}else if(Object.prototype.toString.call(m)==="[object Array]"){for(var p=[],l=0,s=m.length;l<s;++l){var n=X(C,m[l]);if(n==null&&F.original)return;p.push(n)}return b&&b.apply(null,p)||!0}},F=function(C,m){var b=W("",C,m);return b==null&&F.original?F.original.apply(this,arguments):b},L=function(C,m){var b;if(m.indexOf("!")!==-1)return b=m.split("!"),L(C,b[0])+"!"+L(C,b[1]);if(m.charAt(0)==".")for(m=C.split("/").slice(0,-1).join("/")+"/"+m;m.indexOf(".")!==-1&&x!=m;){var x=m;m=m.replace(/\/\.\//,"/").replace(/[^\/]+\/\.\.\//,"")}return m},N=Z,(k="ace")&&(Z[k]||(Z[k]={}),N=Z[k]),N.define&&N.define.packaged||(O.original=N.define,N.define=O,N.define.packaged=!0),N.require&&N.require.packaged||(F.original=N.require,N.require=F,N.require.packaged=!0),ace.define("ace/lib/es6-shim",["require","exports","module"],function(C,m,b){function x(p,l,s){Object.defineProperty(p,l,{value:s,enumerable:!1,writable:!0,configurable:!0})}String.prototype.startsWith||x(String.prototype,"startsWith",function(p,l){return this.lastIndexOf(p,l=l||0)===l}),String.prototype.endsWith||x(String.prototype,"endsWith",function(p,l){return(l===void 0||l>this.length)&&(l=this.length),l-=p.length,p=this.indexOf(p,l),p!==-1&&p===l}),String.prototype.repeat||x(String.prototype,"repeat",function(p){for(var l="",s=this;0<p;)1&p&&(l+=s),(p>>=1)&&(s+=s);return l}),String.prototype.includes||x(String.prototype,"includes",function(p,l){return this.indexOf(p,l)!=-1}),Object.assign||(Object.assign=function(p){if(p==null)throw new TypeError("Cannot convert undefined or null to object");for(var l=Object(p),s=1;s<arguments.length;s++){var n=arguments[s];n!=null&&Object.keys(n).forEach(function(t){l[t]=n[t]})}return l}),Object.values||(Object.values=function(p){return Object.keys(p).map(function(l){return p[l]})}),Array.prototype.find||x(Array.prototype,"find",function(p){for(var l=this.length,s=arguments[1],n=0;n<l;n++){var t=this[n];if(p.call(s,t,n,this))return t}}),Array.prototype.findIndex||x(Array.prototype,"findIndex",function(p){for(var l=this.length,s=arguments[1],n=0;n<l;n++){var t=this[n];if(p.call(s,t,n,this))return n}}),Array.prototype.includes||x(Array.prototype,"includes",function(p,l){return this.indexOf(p,l)!=-1}),Array.prototype.fill||x(Array.prototype,"fill",function(p){for(var l=this.length>>>0,n=arguments[1]>>0,s=n<0?Math.max(l+n,0):Math.min(n,l),n=arguments[2],n=n===void 0?l:n>>0,t=n<0?Math.max(l+n,0):Math.min(n,l);s<t;)this[s]=p,s++;return this}),Array.of||x(Array,"of",function(){return Array.prototype.slice.call(arguments)})}),ace.define("ace/lib/fixoldbrowsers",["require","exports","module","ace/lib/es6-shim"],function(C,m,b){C("./es6-shim")}),ace.define("ace/lib/lang",["require","exports","module"],function(C,m,b){m.last=function(l){return l[l.length-1]},m.stringReverse=function(l){return l.split("").reverse().join("")},m.stringRepeat=function(l,s){for(var n="";0<s;)1&s&&(n+=l),(s>>=1)&&(l+=l);return n};var x=/^\s\s*/,p=/\s\s*$/;m.stringTrimLeft=function(l){return l.replace(x,"")},m.stringTrimRight=function(l){return l.replace(p,"")},m.copyObject=function(l){var s,n={};for(s in l)n[s]=l[s];return n},m.copyArray=function(l){for(var s=[],n=0,t=l.length;n<t;n++)l[n]&&typeof l[n]=="object"?s[n]=this.copyObject(l[n]):s[n]=l[n];return s},m.deepCopy=function l(s){if(typeof s!="object"||!s)return s;if(Array.isArray(s))for(var n=[],t=0;t<s.length;t++)n[t]=l(s[t]);else{if(Object.prototype.toString.call(s)!=="[object Object]")return s;for(var t in n={},s)n[t]=l(s[t])}return n},m.arrayToMap=function(l){for(var s={},n=0;n<l.length;n++)s[l[n]]=1;return s},m.createMap=function(l){var s,n=Object.create(null);for(s in l)n[s]=l[s];return n},m.arrayRemove=function(l,s){for(var n=0;n<=l.length;n++)s===l[n]&&l.splice(n,1)},m.escapeRegExp=function(l){return l.replace(/([.*+?^${}()|[\]\/\\])/g,"\\$1")},m.escapeHTML=function(l){return(""+l).replace(/&/g,"&#38;").replace(/"/g,"&#34;").replace(/'/g,"&#39;").replace(/</g,"&#60;")},m.getMatchOffsets=function(l,s){var n=[];return l.replace(s,function(t){n.push({offset:arguments[arguments.length-2],length:t.length})}),n},m.deferredCall=function(l){function s(){t=null,l()}function n(i){return n.cancel(),t=setTimeout(s,i||0),n}var t=null;return(n.schedule=n).call=function(){return this.cancel(),l(),n},n.cancel=function(){return clearTimeout(t),t=null,n},n.isPending=function(){return t},n},m.delayedCall=function(l,s){function n(){i=null,l()}function t(e){i==null&&(i=setTimeout(n,e||s))}var i=null;return t.delay=function(e){i&&clearTimeout(i),i=setTimeout(n,e||s)},(t.schedule=t).call=function(){this.cancel(),l()},t.cancel=function(){i&&clearTimeout(i),i=null},t.isPending=function(){return i},t}}),ace.define("ace/lib/oop",["require","exports","module"],function(C,m,b){m.inherits=function(x,p){x.super_=p,x.prototype=Object.create(p.prototype,{constructor:{value:x,enumerable:!1,writable:!0,configurable:!0}})},m.mixin=function(x,p){for(var l in p)x[l]=p[l];return x},m.implement=function(x,p){m.mixin(x,p)}}),ace.define("ace/lib/useragent",["require","exports","module"],function(C,m,b){m.OS={LINUX:"LINUX",MAC:"MAC",WINDOWS:"WINDOWS"},m.getOS=function(){return m.isMac?m.OS.MAC:m.isLinux?m.OS.LINUX:m.OS.WINDOWS};var l=typeof navigator=="object"?navigator:{},x=(/mac|win|linux/i.exec(l.platform)||["other"])[0].toLowerCase(),p=l.userAgent||"",l=l.appName||"";m.isWin=x=="win",m.isMac=x=="mac",m.isLinux=x=="linux",m.isIE=l=="Microsoft Internet Explorer"||0<=l.indexOf("MSAppHost")?parseFloat((p.match(/(?:MSIE |Trident\/[0-9]+[\.0-9]+;.*rv:)([0-9]+[\.0-9]+)/)||[])[1]):parseFloat((p.match(/(?:Trident\/[0-9]+[\.0-9]+;.*rv:)([0-9]+[\.0-9]+)/)||[])[1]),m.isOldIE=m.isIE&&m.isIE<9,m.isGecko=m.isMozilla=p.match(/ Gecko\/\d+/),m.isOpera=typeof opera=="object"&&Object.prototype.toString.call(window.opera)=="[object Opera]",m.isWebKit=parseFloat(p.split("WebKit/")[1])||void 0,m.isChrome=parseFloat(p.split(" Chrome/")[1])||void 0,m.isEdge=parseFloat(p.split(" Edge/")[1])||void 0,m.isAIR=0<=p.indexOf("AdobeAIR"),m.isAndroid=0<=p.indexOf("Android"),m.isChromeOS=0<=p.indexOf(" CrOS "),m.isIOS=/iPad|iPhone|iPod/.test(p)&&!window.MSStream,m.isIOS&&(m.isMac=!0),m.isMobile=m.isIOS||m.isAndroid}),ace.define("ace/lib/dom",["require","exports","module","ace/lib/useragent"],function(l,m,b){var x,p,l=l("./useragent"),s=(m.buildDom=function i(e,r,a){if(typeof e=="string"&&e)return d=document.createTextNode(e),r&&r.appendChild(d),d;if(!Array.isArray(e))return e&&e.appendChild&&r&&r.appendChild(e),e;if(typeof e[0]!="string"||!e[0]){for(var o=[],c=0;c<e.length;c++){var h=i(e[c],r,a);h&&o.push(h)}return o}for(var A=document.createElement(e[0]),v=e[1],d=1,c=d=v&&typeof v=="object"&&!Array.isArray(v)?2:d;c<e.length;c++)i(e[c],A,a);return d==2&&Object.keys(v).forEach(function(g){var y=v[g];g==="class"?A.className=Array.isArray(y)?y.join(" "):y:typeof y=="function"||g=="value"||g[0]=="$"?A[g]=y:g==="ref"?a&&(a[y]=A):g==="style"?typeof y=="string"&&(A.style.cssText=y):y!=null&&A.setAttribute(g,y)}),r&&r.appendChild(A),A},m.getDocumentHead=function(i){return(i=i||document).head||i.getElementsByTagName("head")[0]||i.documentElement},m.createElement=function(i,e){return document.createElementNS?document.createElementNS(e||"http://www.w3.org/1999/xhtml",i):document.createElement(i)},m.removeChildren=function(i){i.innerHTML=""},m.createTextNode=function(i,e){return(e?e.ownerDocument:document).createTextNode(i)},m.createFragment=function(i){return(i?i.ownerDocument:document).createDocumentFragment()},m.hasCssClass=function(i,e){return(i.className+"").split(/\s+/g).indexOf(e)!==-1},m.addCssClass=function(i,e){m.hasCssClass(i,e)||(i.className+=" "+e)},m.removeCssClass=function(i,e){for(var r=i.className.split(/\s+/g);;){var a=r.indexOf(e);if(a==-1)break;r.splice(a,1)}i.className=r.join(" ")},m.toggleCssClass=function(i,e){for(var r=i.className.split(/\s+/g),a=!0;;){var o=r.indexOf(e);if(o==-1)break;a=!1,r.splice(o,1)}return a&&r.push(e),i.className=r.join(" "),a},m.setCssClass=function(i,e,r){r?m.addCssClass(i,e):m.removeCssClass(i,e)},m.hasCssString=function(i,e){var r,a=0;if(r=(e=e||document).querySelectorAll("style")){for(;a<r.length;)if(r[a++].id===i)return!0}},m.removeElementById=function(i,e){(e=e||document).getElementById(i)&&e.getElementById(i).remove()},[]);function n(){var i=s;s=null,i&&i.forEach(function(e){t(e[0],e[1])})}function t(i,e,r){if(typeof document!="undefined"){if(s){if(r)n();else if(r===!1)return s.push([i,e])}if(!x){var a=r,r=(a=r&&r.getRootNode&&(a=r.getRootNode())&&a!=r?a:document).ownerDocument||a;if(e&&m.hasCssString(e,a))return null;e&&(i+=`
/*# sourceURL=ace/css/`+e+" */");var o=m.createElement("style");o.appendChild(r.createTextNode(i)),e&&(o.id=e),(a=a==r?m.getDocumentHead(r):a).insertBefore(o,a.firstChild)}}}m.useStrictCSP=function(i){(x=i)==0?n():s=s||[]},m.importCssString=t,m.importCssStylsheet=function(i,e){m.buildDom(["link",{rel:"stylesheet",href:i}],m.getDocumentHead(e))},m.scrollbarWidth=function(a){var e=m.createElement("ace_inner"),r=(e.style.width="100%",e.style.minWidth="0px",e.style.height="200px",e.style.display="block",m.createElement("ace_outer")),c=r.style,a=(c.position="absolute",c.left="-10000px",c.overflow="hidden",c.width="200px",c.minWidth="0px",c.height="150px",c.display="block",r.appendChild(e),a.documentElement),o=(a.appendChild(r),e.offsetWidth),c=(c.overflow="scroll",e.offsetWidth);return o==c&&(c=r.clientWidth),a.removeChild(r),o-c},m.computedStyle=function(i,e){return window.getComputedStyle(i,"")||{}},m.setStyle=function(i,e,r){i[e]!==r&&(i[e]=r)},m.HAS_CSS_ANIMATION=!1,m.HAS_CSS_TRANSFORMS=!1,m.HI_DPI=!l.isWin||typeof window!="undefined"&&1.5<=window.devicePixelRatio,l.isChromeOS&&(m.HI_DPI=!1),typeof document!="undefined"&&(p=document.createElement("div"),m.HI_DPI&&p.style.transform!==void 0&&(m.HAS_CSS_TRANSFORMS=!0),l.isEdge||p.style.animationName===void 0||(m.HAS_CSS_ANIMATION=!0),p=null),m.HAS_CSS_TRANSFORMS?m.translate=function(i,e,r){i.style.transform="translate("+Math.round(e)+"px, "+Math.round(r)+"px)"}:m.translate=function(i,e,r){i.style.top=Math.round(r)+"px",i.style.left=Math.round(e)+"px"}}),ace.define("ace/lib/net",["require","exports","module","ace/lib/dom"],function(C,m,b){var x=C("./dom");m.get=function(p,l){var s=new XMLHttpRequest;s.open("GET",p,!0),s.onreadystatechange=function(){s.readyState===4&&l(s.responseText)},s.send(null)},m.loadScript=function(p,l){var s=x.getDocumentHead(),n=document.createElement("script");n.src=p,s.appendChild(n),n.onload=n.onreadystatechange=function(t,i){!i&&n.readyState&&n.readyState!="loaded"&&n.readyState!="complete"||(n=n.onload=n.onreadystatechange=null,i||l())}},m.qualifyURL=function(p){var l=document.createElement("a");return l.href=p,l.href}}),ace.define("ace/lib/event_emitter",["require","exports","module"],function(C,m,b){function x(){this.propagationStopped=!0}function p(){this.defaultPrevented=!0}var l={};l._emit=l._dispatchEvent=function(s,n){this._eventRegistry||(this._eventRegistry={}),this._defaultHandlers||(this._defaultHandlers={});var t=this._eventRegistry[s]||[],i=this._defaultHandlers[s];if(t.length||i){(n=typeof n=="object"&&n?n:{}).type||(n.type=s),n.stopPropagation||(n.stopPropagation=x),n.preventDefault||(n.preventDefault=p);for(var t=t.slice(),e=0;e<t.length&&(t[e](n,this),!n.propagationStopped);e++);return i&&!n.defaultPrevented?i(n,this):void 0}},l._signal=function(s,n){if(t=(this._eventRegistry||{})[s])for(var t=t.slice(),i=0;i<t.length;i++)t[i](n,this)},l.once=function(s,n){var t=this;if(this.on(s,function i(){t.off(s,i),n.apply(null,arguments)}),!n)return new Promise(function(i){n=i})},l.setDefaultHandler=function(s,n){var t,i,e=this._defaultHandlers;(e=e||(this._defaultHandlers={_disabled_:{}}))[s]&&(i=e[s],(t=e._disabled_[s])||(e._disabled_[s]=t=[]),t.push(i),(i=t.indexOf(n))!=-1&&t.splice(i,1)),e[s]=n},l.removeDefaultHandler=function(s,n){var t,i=this._defaultHandlers;i&&(t=i._disabled_[s],i[s]==n?t&&this.setDefaultHandler(s,t.pop()):t&&(i=t.indexOf(n))!=-1&&t.splice(i,1))},l.on=l.addEventListener=function(s,n,t){this._eventRegistry=this._eventRegistry||{};var i=this._eventRegistry[s];return(i=i||(this._eventRegistry[s]=[])).indexOf(n)==-1&&i[t?"unshift":"push"](n),n},l.off=l.removeListener=l.removeEventListener=function(s,n){this._eventRegistry=this._eventRegistry||{},s=this._eventRegistry[s],!s||(n=s.indexOf(n))!==-1&&s.splice(n,1)},l.removeAllListeners=function(s){s||(this._eventRegistry=this._defaultHandlers=void 0),this._eventRegistry&&(this._eventRegistry[s]=void 0),this._defaultHandlers&&(this._defaultHandlers[s]=void 0)},m.EventEmitter=l}),ace.define("ace/lib/app_config",["require","exports","module","ace/lib/oop","ace/lib/event_emitter"],function(C,m,b){var x=C("./oop"),p=C("./event_emitter").EventEmitter,l={setOptions:function(i){Object.keys(i).forEach(function(e){this.setOption(e,i[e])},this)},getOptions:function(i){var e,r={};return i?Array.isArray(i)||(r=i,i=Object.keys(r)):(e=this.$options,i=Object.keys(e).filter(function(a){return!e[a].hidden})),i.forEach(function(a){r[a]=this.getOption(a)},this),r},setOption:function(i,e){var r;if(this["$"+i]!==e)return(r=this.$options[i])?r.forwardTo?this[r.forwardTo]&&this[r.forwardTo].setOption(i,e):(r.handlesSet||(this["$"+i]=e),void(r&&r.set&&r.set.call(this,e))):s('misspelled option "'+i+'"')},getOption:function(i){var e=this.$options[i];return e?e.forwardTo?this[e.forwardTo]&&this[e.forwardTo].getOption(i):e&&e.get?e.get.call(this):this["$"+i]:s('misspelled option "'+i+'"')}};function s(i){typeof console!="undefined"&&console.warn&&console.warn.apply(console,arguments)}function n(i,e){var r=new Error(i);r.data=e,typeof console=="object"&&console.error&&console.error(r),setTimeout(function(){throw r})}function t(){this.$defaultOptions={}}(function(){x.implement(this,p),this.defineOptions=function(i,e,r){return i.$options||(this.$defaultOptions[e]=i.$options={}),Object.keys(r).forEach(function(a){var o=r[a];(o=typeof o=="string"?{forwardTo:o}:o).name||(o.name=a),"initialValue"in(i.$options[o.name]=o)&&(i["$"+o.name]=o.initialValue)}),x.implement(i,l),this},this.resetOptions=function(i){Object.keys(i.$options).forEach(function(e){var r=i.$options[e];"value"in r&&i.setOption(e,r.value)})},this.setDefaultValue=function(i,e,r){if(!i){for(i in this.$defaultOptions)if(this.$defaultOptions[i][e])break;if(!this.$defaultOptions[i][e])return!1}var a=this.$defaultOptions[i]||(this.$defaultOptions[i]={});a[e]&&(a.forwardTo?this.setDefaultValue(a.forwardTo,e,r):a[e].value=r)},this.setDefaultValues=function(i,e){Object.keys(e).forEach(function(r){this.setDefaultValue(i,r,e[r])},this)},this.warn=s,this.reportError=n}).call(t.prototype),m.AppConfig=t}),ace.define("ace/theme/textmate.css",["require","exports","module"],function(C,m,b){b.exports=`.ace-tm .ace_gutter {
  background: #f0f0f0;
  color: #333;
}

.ace-tm .ace_print-margin {
  width: 1px;
  background: #e8e8e8;
}

.ace-tm .ace_fold {
    background-color: #6B72E6;
}

.ace-tm {
  background-color: #FFFFFF;
  color: black;
}

.ace-tm .ace_cursor {
  color: black;
}
        
.ace-tm .ace_invisible {
  color: rgb(191, 191, 191);
}

.ace-tm .ace_storage,
.ace-tm .ace_keyword {
  color: blue;
}

.ace-tm .ace_constant {
  color: rgb(197, 6, 11);
}

.ace-tm .ace_constant.ace_buildin {
  color: rgb(88, 72, 246);
}

.ace-tm .ace_constant.ace_language {
  color: rgb(88, 92, 246);
}

.ace-tm .ace_constant.ace_library {
  color: rgb(6, 150, 14);
}

.ace-tm .ace_invalid {
  background-color: rgba(255, 0, 0, 0.1);
  color: red;
}

.ace-tm .ace_support.ace_function {
  color: rgb(60, 76, 114);
}

.ace-tm .ace_support.ace_constant {
  color: rgb(6, 150, 14);
}

.ace-tm .ace_support.ace_type,
.ace-tm .ace_support.ace_class {
  color: rgb(109, 121, 222);
}

.ace-tm .ace_keyword.ace_operator {
  color: rgb(104, 118, 135);
}

.ace-tm .ace_string {
  color: rgb(3, 106, 7);
}

.ace-tm .ace_comment {
  color: rgb(76, 136, 107);
}

.ace-tm .ace_comment.ace_doc {
  color: rgb(0, 102, 255);
}

.ace-tm .ace_comment.ace_doc.ace_tag {
  color: rgb(128, 159, 191);
}

.ace-tm .ace_constant.ace_numeric {
  color: rgb(0, 0, 205);
}

.ace-tm .ace_variable {
  color: rgb(49, 132, 149);
}

.ace-tm .ace_xml-pe {
  color: rgb(104, 104, 91);
}

.ace-tm .ace_entity.ace_name.ace_function {
  color: #0000A2;
}


.ace-tm .ace_heading {
  color: rgb(12, 7, 255);
}

.ace-tm .ace_list {
  color:rgb(185, 6, 144);
}

.ace-tm .ace_meta.ace_tag {
  color:rgb(0, 22, 142);
}

.ace-tm .ace_string.ace_regex {
  color: rgb(255, 0, 0)
}

.ace-tm .ace_marker-layer .ace_selection {
  background: rgb(181, 213, 255);
}
.ace-tm.ace_multiselect .ace_selection.ace_start {
  box-shadow: 0 0 3px 0px white;
}
.ace-tm .ace_marker-layer .ace_step {
  background: rgb(252, 255, 0);
}

.ace-tm .ace_marker-layer .ace_stack {
  background: rgb(164, 229, 101);
}

.ace-tm .ace_marker-layer .ace_bracket {
  margin: -1px 0 0 -1px;
  border: 1px solid rgb(192, 192, 192);
}

.ace-tm .ace_marker-layer .ace_active-line {
  background: rgba(0, 0, 0, 0.07);
}

.ace-tm .ace_gutter-active-line {
    background-color : #dcdcdc;
}

.ace-tm .ace_marker-layer .ace_selected-word {
  background: rgb(250, 250, 255);
  border: 1px solid rgb(200, 200, 250);
}

.ace-tm .ace_indent-guide {
  background: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAE0lEQVQImWP4////f4bLly//BwAmVgd1/w11/gAAAABJRU5ErkJggg==") right repeat-y;
}

.ace-tm .ace_indent-guide-active {
  background: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAACXBIWXMAAAsTAAALEwEAmpwYAAAAIGNIUk0AAHolAACAgwAA+f8AAIDpAAB1MAAA6mAAADqYAAAXb5JfxUYAAAAZSURBVHjaYvj///9/hivKyv8BAAAA//8DACLqBhbvk+/eAAAAAElFTkSuQmCC") right repeat-y;
}
`}),ace.define("ace/theme/textmate",["require","exports","module","ace/theme/textmate.css","ace/lib/dom"],function(C,m,b){m.isDark=!1,m.cssClass="ace-tm",m.cssText=C("./textmate.css"),m.$id="ace/theme/textmate",C("../lib/dom").importCssString(m.cssText,m.cssClass,!1)}),ace.define("ace/config",["require","exports","module","ace/lib/lang","ace/lib/oop","ace/lib/net","ace/lib/dom","ace/lib/app_config","ace/theme/textmate"],function(C,m,b){var x=C("./lib/lang"),p=(C("./lib/oop"),C("./lib/net")),l=C("./lib/dom"),s=C("./lib/app_config").AppConfig,n=(b.exports=m=new s,{packaged:!1,workerPath:null,modePath:null,themePath:null,basePath:"",suffix:".js",$moduleUrls:{},loadWorkerFromBlob:!0,sharedPopups:!1,useStrictCSP:null}),t=(m.get=function(e){if(n.hasOwnProperty(e))return n[e];throw new Error("Unknown config key: "+e)},m.set=function(e,r){if(n.hasOwnProperty(e))n[e]=r;else if(this.setDefaultValue("",e,r)==0)throw new Error("Unknown config key: "+e);e=="useStrictCSP"&&l.useStrictCSP(r)},m.all=function(){return x.copyObject(n)},m.$modes={},m.moduleUrl=function(e,r){var a,o,c;return n.$moduleUrls[e]||(e=e.split("/"),a=(r=r||e[e.length-2]||"")=="snippets"?"/":"-",o=e[e.length-1],r=="worker"&&a=="-"&&(c=new RegExp("^"+r+"[\\-_]|[\\-_]"+r+"$","g"),o=o.replace(c,"")),(!o||o==r)&&1<e.length&&(o=e[e.length-2]),(c=n[r+"Path"])==null?c=n.basePath:a=="/"&&(r=a=""),c&&c.slice(-1)!="/"&&(c+="/"),c+r+a+o+this.get("suffix"))},m.setModuleUrl=function(e,r){return n.$moduleUrls[e]=r},function(e,r){return e=="ace/theme/textmate"?r(null,C("./theme/textmate")):console.error("loader is not configured")}),i=(m.setLoader=function(e){t=e},m.$loading={},m.loadModule=function(e,r){var a,o;Array.isArray(e)&&(o=e[0],e=e[1]);try{a=C(e)}catch{}if(a&&!m.$loading[e])return r&&r(a);if(m.$loading[e]||(m.$loading[e]=[]),m.$loading[e].push(r),!(1<m.$loading[e].length)){let c=function(){t(e,function(h,A){m._emit("load.module",{name:e,module:A});var v=m.$loading[e];m.$loading[e]=null,v.forEach(function(d){d&&d(A)})})};if(!m.get("packaged"))return c();p.loadScript(m.moduleUrl(e,o),c),i()}},function(){n.basePath||n.workerPath||n.modePath||n.themePath||Object.keys(n.$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"),i=function(){})});m.version="1.10.1"}),ace.define("ace/loader_build",["require","exports","module","ace/lib/fixoldbrowsers","ace/config"],function(C,m,b){C("./lib/fixoldbrowsers");var x=C("./config"),p=(x.setLoader(function(s,n){C([s],function(t){n(null,t)})}),function(){return this||typeof window!="undefined"&&window}());function l(s){if(p&&p.document){x.set("packaged",s||C.packaged||b.packaged||p.define&&V.amdD.packaged);for(var n,t={},i="",s=document.currentScript||document._currentScript,e=(s&&s.ownerDocument||document).getElementsByTagName("script"),r=0;r<e.length;r++){var a=e[r],o=a.src||a.getAttribute("src");if(o){for(var c=a.attributes,h=0,A=c.length;h<A;h++){var v=c[h];v.name.indexOf("data-ace-")===0&&(t[v.name.replace(/^data-ace-/,"").replace(/-(.)/g,function(g,y){return y.toUpperCase()})]=v.value)}a=o.match(/^(.*)\/ace(\-\w+)?\.js(\?|$)/),a&&(i=a[1])}}for(n in i&&(t.base=t.base||i,t.packaged=!0),t.basePath=t.base,t.workerPath=t.workerPath||t.base,t.modePath=t.modePath||t.base,t.themePath=t.themePath||t.base,delete t.base,t)t[n]!==void 0&&x.set(n,t[n])}}b.exports=function(s){x.init=l,s.require=C,s.define=V.amdD},l(!0)}),ace.define("ace/lib/keys",["require","exports","module","ace/lib/oop"],function(C,m,b){var x=C("./oop"),p=function(){var l,s,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(s in n.FUNCTION_KEYS)l=n.FUNCTION_KEYS[s].toLowerCase(),n[l]=parseInt(s,10);for(s in n.PRINTABLE_KEYS)l=n.PRINTABLE_KEYS[s].toLowerCase(),n[l]=parseInt(s,10);x.mixin(n,n.MODIFIER_KEYS),x.mixin(n,n.PRINTABLE_KEYS),x.mixin(n,n.FUNCTION_KEYS),n.enter=n.return,n.escape=n.esc,n.del=n.delete,n[173]="-";for(var t=["cmd","ctrl","alt","shift"],i=Math.pow(2,t.length);i--;)n.KEY_MODS[i]=t.filter(function(e){return i&n.KEY_MODS[e]}).join("-")+"-";return n.KEY_MODS[0]="",n.KEY_MODS[-1]="input-",n}();x.mixin(m,p),m.keyCodeToString=function(l){var s=p[l];return(s=typeof s!="string"?String.fromCharCode(l):s).toLowerCase()}}),ace.define("ace/lib/event",["require","exports","module","ace/lib/keys","ace/lib/useragent"],function(C,m,b){var x,p=C("./keys"),l=C("./useragent"),s=null,n=0;function t(){if(x==null){x=!1;try{document.createComment("").addEventListener("test",function(){},{get passive(){x={passive:!1}}})}catch{}}return x}function i(A,v,d){this.elem=A,this.type=v,this.callback=d}i.prototype.destroy=function(){o(this.elem,this.type,this.callback),this.elem=this.type=this.callback=void 0};function e(A){return 0|(A.ctrlKey?1:0)|(A.altKey?2:0)|(A.shiftKey?4:0)|(A.metaKey?8:0)}var r,a=m.addListener=function(A,v,d,g){A.addEventListener(v,d,t()),g&&g.$toDestroy.push(new i(A,v,d))},o=m.removeListener=function(A,v,d){A.removeEventListener(v,d,t())};m.stopEvent=function(A){return m.stopPropagation(A),m.preventDefault(A),!1},m.stopPropagation=function(A){A.stopPropagation&&A.stopPropagation()},m.preventDefault=function(A){A.preventDefault&&A.preventDefault()},m.getButton=function(A){return A.type=="dblclick"?0:A.type=="contextmenu"||l.isMac&&A.ctrlKey&&!A.altKey&&!A.shiftKey?2:A.button},m.capture=function(A,v,d){var g=A&&A.ownerDocument||document;function y(w){v&&v(w),d&&d(w),o(g,"mousemove",v),o(g,"mouseup",y),o(g,"dragstart",y)}return a(g,"mousemove",v),a(g,"mouseup",y),a(g,"dragstart",y),y},m.addMouseWheelListener=function(A,v,d){a(A,"wheel",function(g){var y=g.deltaX||0,w=g.deltaY||0;switch(g.deltaMode){case g.DOM_DELTA_PIXEL:g.wheelX=.15*y,g.wheelY=.15*w;break;case g.DOM_DELTA_LINE:g.wheelX=15*y,g.wheelY=15*w;break;case g.DOM_DELTA_PAGE:g.wheelX=150*y,g.wheelY=150*w}v(g)},d)},m.addMultiMouseDownListener=function(A,v,d,g,y){var w,I,T,B=0,E={2:"dblclick",3:"tripleclick",4:"quadclick"};function _(P){var j;if(m.getButton(P)!==0?B=0:1<P.detail&&!(4<++B)||(B=1),l.isIE&&(j=5<Math.abs(P.clientX-w)||5<Math.abs(P.clientY-I),T&&!j||(B=1),T&&clearTimeout(T),T=setTimeout(function(){T=null},v[B-1]||600),B==1&&(w=P.clientX,I=P.clientY)),P._clicks=B,d[g]("mousedown",P),4<B)B=0;else if(1<B)return d[g](E[B],P)}(A=Array.isArray(A)?A:[A]).forEach(function(P){a(P,"mousedown",_,y)})};function c(A,v,d){var g=e(v);if(!l.isMac&&s){if(v.getModifierState&&(v.getModifierState("OS")||v.getModifierState("Win"))&&(g|=8),s.altGr){if((3&g)==3)return;s.altGr=0}d!==18&&d!==17||(y="location"in v?v.location:v.keyLocation,d===17&&y===1?s[d]==1&&(n=v.timeStamp):d===18&&g===3&&y===2&&v.timeStamp-n<50&&(s.altGr=!0))}if(d in p.MODIFIER_KEYS&&(d=-1),!g&&d===13){var y="location"in v?v.location:v.keyLocation;if(y===3&&(A(v,g,-d),v.defaultPrevented))return}if(l.isChromeOS&&8&g){if(A(v,g,d),v.defaultPrevented)return;g&=-9}return!!(g||d in p.FUNCTION_KEYS||d in p.PRINTABLE_KEYS)&&A(v,g,d)}function h(){s=Object.create(null)}m.getModifierString=function(A){return p.KEY_MODS[e(A)]},m.addCommandKeyListener=function(A,v,d){var g,y;l.isOldGecko||l.isOpera&&!("KeyboardEvent"in window)?(g=null,a(A,"keydown",function(w){g=w.keyCode},d),a(A,"keypress",function(w){return c(v,w,g)},d)):(y=null,a(A,"keydown",function(w){s[w.keyCode]=(s[w.keyCode]||0)+1;var I=c(v,w,w.keyCode);return y=w.defaultPrevented,I},d),a(A,"keypress",function(w){y&&(w.ctrlKey||w.altKey||w.shiftKey||w.metaKey)&&(m.stopEvent(w),y=null)},d),a(A,"keyup",function(w){s[w.keyCode]=null},d),s||(h(),a(window,"focus",h)))},typeof window=="object"&&window.postMessage&&!l.isOldIE&&(r=1,m.nextTick=function(A,v){v=v||window;function d(y){y.data==g&&(m.stopPropagation(y),o(v,"message",d),A())}var g="zero-timeout-message-"+r++;a(v,"message",d),v.postMessage(g,"*")}),m.$idleBlocked=!1,m.onIdle=function(A,v){return setTimeout(function d(){m.$idleBlocked?setTimeout(d,100):A()},v)},m.$idleBlockId=null,m.blockIdle=function(A){m.$idleBlockId&&clearTimeout(m.$idleBlockId),m.$idleBlocked=!0,m.$idleBlockId=setTimeout(function(){m.$idleBlocked=!1},A||100)},m.nextFrame=typeof window=="object"&&(window.requestAnimationFrame||window.mozRequestAnimationFrame||window.webkitRequestAnimationFrame||window.msRequestAnimationFrame||window.oRequestAnimationFrame),m.nextFrame?m.nextFrame=m.nextFrame.bind(window):m.nextFrame=function(A){setTimeout(A,17)}}),ace.define("ace/range",["require","exports","module"],function(C,m,b){function x(p,l,s,n){this.start={row:p,column:l},this.end={row:s,column:n}}(function(){this.isEqual=function(p){return this.start.row===p.start.row&&this.end.row===p.end.row&&this.start.column===p.start.column&&this.end.column===p.end.column},this.toString=function(){return"Range: ["+this.start.row+"/"+this.start.column+"] -> ["+this.end.row+"/"+this.end.column+"]"},this.contains=function(p,l){return this.compare(p,l)==0},this.compareRange=function(l){var s=l.end,l=l.start,s=this.compare(s.row,s.column);return s==1?(s=this.compare(l.row,l.column))==1?2:s==0?1:0:s==-1?-2:(s=this.compare(l.row,l.column))==-1?-1:s==1?42:0},this.comparePoint=function(p){return this.compare(p.row,p.column)},this.containsRange=function(p){return this.comparePoint(p.start)==0&&this.comparePoint(p.end)==0},this.intersects=function(p){return p=this.compareRange(p),p==-1||p==0||p==1},this.isEnd=function(p,l){return this.end.row==p&&this.end.column==l},this.isStart=function(p,l){return this.start.row==p&&this.start.column==l},this.setStart=function(p,l){typeof p=="object"?(this.start.column=p.column,this.start.row=p.row):(this.start.row=p,this.start.column=l)},this.setEnd=function(p,l){typeof p=="object"?(this.end.column=p.column,this.end.row=p.row):(this.end.row=p,this.end.column=l)},this.inside=function(p,l){return this.compare(p,l)==0&&!this.isEnd(p,l)&&!this.isStart(p,l)},this.insideStart=function(p,l){return this.compare(p,l)==0&&!this.isEnd(p,l)},this.insideEnd=function(p,l){return this.compare(p,l)==0&&!this.isStart(p,l)},this.compare=function(p,l){return this.isMultiLine()||p!==this.start.row?p<this.start.row?-1:p>this.end.row?1:this.start.row===p?l>=this.start.column?0:-1:this.end.row!==p||l<=this.end.column?0:1:l<this.start.column?-1:l>this.end.column?1:0},this.compareStart=function(p,l){return this.start.row==p&&this.start.column==l?-1:this.compare(p,l)},this.compareEnd=function(p,l){return this.end.row==p&&this.end.column==l?1:this.compare(p,l)},this.compareInside=function(p,l){return this.end.row==p&&this.end.column==l?1:this.start.row==p&&this.start.column==l?-1:this.compare(p,l)},this.clipRows=function(p,l){var s,n;return this.end.row>l?s={row:l+1,column:0}:this.end.row<p&&(s={row:p,column:0}),this.start.row>l?n={row:l+1,column:0}:this.start.row<p&&(n={row:p,column:0}),x.fromPoints(n||this.start,s||this.end)},this.extend=function(p,l){var s,n,t=this.compare(p,l);return t==0?this:(t==-1?s={row:p,column:l}:n={row:p,column:l},x.fromPoints(s||this.start,n||this.end))},this.isEmpty=function(){return this.start.row===this.end.row&&this.start.column===this.end.column},this.isMultiLine=function(){return this.start.row!==this.end.row},this.clone=function(){return x.fromPoints(this.start,this.end)},this.collapseRows=function(){return this.end.column==0?new x(this.start.row,0,Math.max(this.start.row,this.end.row-1),0):new x(this.start.row,0,this.end.row,0)},this.toScreenRange=function(s){var l=s.documentToScreenPosition(this.start),s=s.documentToScreenPosition(this.end);return new x(l.row,l.column,s.row,s.column)},this.moveBy=function(p,l){this.start.row+=p,this.start.column+=l,this.end.row+=p,this.end.column+=l}}).call(x.prototype),x.fromPoints=function(p,l){return new x(p.row,p.column,l.row,l.column)},x.comparePoints=function(p,l){return p.row-l.row||p.column-l.column},x.comparePoints=function(p,l){return p.row-l.row||p.column-l.column},m.Range=x}),ace.define("ace/clipboard",["require","exports","module"],function(C,m,b){var x;b.exports={lineMode:!1,pasteCancelled:function(){return!!(x&&x>Date.now()-50)||(x=!1)},cancel:function(){x=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(C,m,b){var x=C("../lib/event"),p=C("../lib/useragent"),l=C("../lib/dom"),s=C("../lib/lang"),n=C("../clipboard"),t=p.isChrome<18,i=p.isIE,e=63<p.isChrome,r=C("../lib/keys"),a=r.KEY_MODS,o=p.isIOS,c=o?/\s/:/\n/,h=p.isMobile;m.TextInput=function(A,v){var d=l.createElement("textarea"),g=(d.className="ace_text-input",d.setAttribute("wrap","off"),d.setAttribute("autocorrect","off"),d.setAttribute("autocapitalize","off"),d.setAttribute("spellcheck",!1),d.style.opacity="0",A.insertBefore(d,A.firstChild),!1),y=!1,w=!1,I=!1,T="",B=(h||(d.style.fontSize="1px"),!1),E=!1,_="",P=0,j=0,z=0;try{var D=document.activeElement===d}catch{}x.addListener(d,"blur",function(ae){E||(v.onBlur(ae),D=!1)},v),x.addListener(d,"focus",function(ae){if(!E){if(D=!0,p.isEdge)try{if(!document.hasFocus())return}catch{}v.onFocus(ae),p.isEdge?setTimeout(G):G()}},v),this.$focusScroll=!1,this.focus=function(){if(T||e||this.$focusScroll=="browser")return d.focus({preventScroll:!0});var ae=d.style.top;d.style.position="fixed",d.style.top="0px";try{var pe=d.getBoundingClientRect().top!=0}catch{return}var ce=[];if(pe)for(var de=d.parentElement;de&&de.nodeType==1;)ce.push(de),de.setAttribute("ace_nocontext",!0),de=!de.parentElement&&de.getRootNode?de.getRootNode().host:de.parentElement;d.focus({preventScroll:!0}),pe&&ce.forEach(function(fe){fe.removeAttribute("ace_nocontext")}),setTimeout(function(){d.style.position="",d.style.top=="0px"&&(d.style.top=ae)},0)},this.blur=function(){d.blur()},this.isFocused=function(){return D},v.on("beforeEndOperation",function(){var ae=v.curOp,pe=ae&&ae.command&&ae.command.name;pe!="insertstring"&&(pe=pe&&(ae.docChanged||ae.selectionChanged),w&&pe&&(_=d.value="",Ae()),G())});function Y(ae){te(ae,!0)}function R(ae){te(ae,!1)}function H(ae){var pe=Q(ae);n.pasteCancelled()||(typeof pe=="string"?(pe&&v.onPaste(pe,ae),p.isIE&&setTimeout(G),x.preventDefault(ae)):(d.value="",y=!0))}var G=o?function(ae){var pe;!D||g&&!ae||I||((pe=`
 ab`+(ae=ae||"")+`cde fg
`)!=d.value&&(d.value=_=pe),pe=4+(ae.length||(v.selection.isEmpty()?0:1)),P==4&&j==pe||d.setSelectionRange(4,pe),P=4,j=pe)}:function(){if(!w&&!I&&(D||$)){w=!0;var ae,pe,ce=0,de=0,fe="",be=(v.session&&(be=(ae=v.selection).getRange(),ae=ae.cursor.row,ce=be.start.column,de=be.end.column,fe=v.session.getLine(ae),be.start.row!=ae?(pe=v.session.getLine(ae-1),ce=be.start.row<ae-1?0:ce,de+=pe.length+1,fe=pe+`
`+fe):be.end.row!=ae?(pe=v.session.getLine(ae+1),de=be.end.row>ae+1?pe.length:de,de+=fe.length+1,fe=fe+`
`+pe):h&&0<ae&&(fe=`
`+fe,de+=1,ce+=1),400<fe.length&&(ce<400&&de<400?fe=fe.slice(0,400):(fe=`
`,ce==de?ce=de=0:(ce=0,de=1)))),fe+`

`);if(be!=_&&(d.value=_=be,P=j=be.length),$&&(P=d.selectionStart,j=d.selectionEnd),j!=de||P!=ce||d.selectionEnd!=j)try{d.setSelectionRange(ce,de),P=ce,j=de}catch{}w=!1}},f=(this.resetSelection=G,D&&v.onFocus(),function(ae){return ae.selectionStart===0&&ae.selectionEnd>=_.length&&ae.value===_&&_&&ae.selectionEnd!==j}),S=null,$=(this.setInputHandler=function(ae){S=ae},!(this.getInputHandler=function(){return S})),M=function(ae,pe){if($=$&&!1,y)return G(),ae&&v.onPaste(ae),y=!1,"";for(var ce=d.selectionStart,de=d.selectionEnd,fe=P,be=_.length-j,ke=ae,Me=ae.length-ce,Ye=ae.length-de,Ve=0;0<fe&&_[Ve]==ae[Ve];)Ve++,fe--;for(ke=ke.slice(Ve),Ve=1;0<be&&_.length-Ve>P-1&&_[_.length-Ve]==ae[ae.length-Ve];)Ve++,be--;Me-=Ve-1,Ye-=Ve-1;var Qe=ke.length-Ve+1;return Qe<0&&(fe=-Qe,Qe=0),ke=ke.slice(0,Qe),pe||ke||Me||fe||be||Ye?(Qe=!(I=!0),p.isAndroid&&ke==". "&&(ke="  ",Qe=!0),ke&&!fe&&!be&&!Me&&!Ye||B?v.onTextInput(ke):v.onTextInput(ke,{extendLeft:fe,extendRight:be,restoreStart:Me,restoreEnd:Ye}),I=!1,_=ae,P=ce,j=de,z=Ye,Qe?`
`:ke):""},K=function(pe){if(w)return he();if(pe&&pe.inputType){if(pe.inputType=="historyUndo")return v.execCommand("undo");if(pe.inputType=="historyRedo")return v.execCommand("redo")}var pe=d.value,ce=M(pe,!0);(500<pe.length||c.test(ce)||h&&P<1&&P==j)&&G()},Q=function(ae,pe,ce){var de=ae.clipboardData||window.clipboardData;if(de&&!t){var fe=i||ce?"Text":"text/plain";try{return pe?de.setData(fe,pe)!==!1:de.getData(fe)}catch(be){if(!ce)return Q(be,pe,!0)}}},te=function(ae,pe){var ce=v.getCopyText();if(!ce)return x.preventDefault(ae);Q(ae,ce)?(o&&(G(ce),g=ce,setTimeout(function(){g=!1},10)),pe?v.onCut():v.onCopy(),x.preventDefault(ae)):(g=!0,d.value=ce,d.select(),setTimeout(function(){g=!1,G(),pe?v.onCut():v.onCopy()}))},he=(x.addCommandKeyListener(d,v.onCommandKey.bind(v),v),x.addListener(d,"select",function(ae){w||(g?g=!1:f(d)?(v.selectAll(),G()):h&&d.selectionStart!=P&&G())},v),x.addListener(d,"input",K,v),x.addListener(d,"cut",Y,v),x.addListener(d,"copy",R,v),x.addListener(d,"paste",H,v),"oncut"in d&&"oncopy"in d&&"onpaste"in d||x.addListener(A,"keydown",function(ae){if((!p.isMac||ae.metaKey)&&ae.ctrlKey)switch(ae.keyCode){case 67:R(ae);break;case 86:H(ae);break;case 88:Y(ae)}},v),function(){var ae;if(w&&v.onCompositionUpdate&&!v.$readOnly)return B?ge():void(w.useTextareaForIME?v.onCompositionUpdate(d.value):(ae=d.value,M(ae),w.markerRange&&(w.context&&(w.markerRange.start.column=w.selectionStart=w.context.compositionStartOffset),w.markerRange.end.column=w.markerRange.start.column+j-w.selectionStart+z)))}),Ae=function(ae){v.onCompositionEnd&&!v.$readOnly&&(w=!1,v.onCompositionEnd(),v.off("mousedown",ge),ae&&K())};function ge(){E=!0,d.blur(),d.focus(),E=!1}var Ce,ve=s.delayedCall(he,50).schedule.bind(null,null);function ye(){clearTimeout(Ce),Ce=setTimeout(function(){T&&(d.style.cssText=T,T=""),v.renderer.$isMousePressed=!1,v.renderer.$keepTextAreaAtCursor&&v.renderer.$moveTextAreaToCursor()},0)}x.addListener(d,"compositionstart",function(ae){w||!v.onCompositionStart||v.$readOnly||(w={},B||(ae.data&&(w.useTextareaForIME=!1),setTimeout(he,0),v._signal("compositionStart"),v.on("mousedown",ge),(ae=v.getSelectionRange()).end.row=ae.start.row,ae.end.column=ae.start.column,w.markerRange=ae,w.selectionStart=P,v.onCompositionStart(w),w.useTextareaForIME?(_=d.value="",j=P=0):(d.msGetInputContext&&(w.context=d.msGetInputContext()),d.getInputContext&&(w.context=d.getInputContext()))))},v),x.addListener(d,"compositionupdate",he,v),x.addListener(d,"keyup",function(ae){ae.keyCode==27&&d.value.length<d.selectionStart&&(w||(_=d.value),P=j=-1,G()),ve()},v),x.addListener(d,"keydown",ve,v),x.addListener(d,"compositionend",Ae,v),this.getElement=function(){return d},this.setCommandMode=function(ae){B=ae,d.readOnly=!1},this.setReadOnly=function(ae){B||(d.readOnly=ae)},this.setCopyWithEmptySelection=function(ae){},this.onContextMenu=function(ae){$=!0,G(),v._emit("nativecontextmenu",{target:v,domEvent:ae}),this.moveToMouse(ae,!0)},this.moveToMouse=function(ae,de){T=T||d.style.cssText,d.style.cssText=(de?"z-index:100000;":"")+(p.isIE?"opacity:0.1;":"")+"text-indent: -"+(P+j)*v.renderer.characterWidth*.5+"px;";function ce(Ye){l.translate(d,Ye.clientX-ke-2,Math.min(Ye.clientY-be-2,Me))}var de=v.container.getBoundingClientRect(),fe=l.computedStyle(v.container),be=de.top+(parseInt(fe.borderTopWidth)||0),ke=de.left+(parseInt(de.borderLeftWidth)||0),Me=de.bottom-be-d.clientHeight-2;ce(ae),ae.type=="mousedown"&&(v.renderer.$isMousePressed=!0,clearTimeout(Ce),p.isWin&&x.capture(v.container,ce,ye))},this.onContextMenuClose=ye;function Te(ae){v.textInput.onContextMenu(ae),ye()}if(x.addListener(d,"mouseup",Te,v),x.addListener(d,"mousedown",function(ae){ae.preventDefault(),ye()},v),x.addListener(v.renderer.scroller,"contextmenu",Te,v),x.addListener(d,"contextmenu",Te,v),o){let ae=function(pe){var ce,de,fe,be;document.activeElement!==Se||$e||w||_e.$mouseHandler.isMousePressed||g||(ce=Se.selectionStart,de=Se.selectionEnd,fe=null,(be=0)==ce?fe=r.up:ce==1?fe=r.home:j<de&&_[de]==`
`?fe=r.end:ce<P&&_[ce-1]==" "?(fe=r.left,be=a.option):ce<P||ce==P&&j!=P&&ce==de?fe=r.left:j<de&&2<_.slice(0,de).split(`
`).length?fe=r.down:j<de&&_[de-1]==" "?(fe=r.right,be=a.option):(j<de||de==j&&j!=P&&ce==de)&&(fe=r.right),ce!==de&&(be|=a.shift),fe&&(!_e.onCommandKey({},be,fe)&&_e.commands&&(fe=r.keyCodeToString(fe),(be=_e.commands.findKeyCommand(be,fe))&&_e.execCommand(be)),P=ce,j=de,G("")))};var _e=v,Se=d,ue=null,$e=!1;Se.addEventListener("keydown",function(pe){ue&&clearTimeout(ue),$e=!0},!0),Se.addEventListener("keyup",function(pe){ue=setTimeout(function(){$e=!1},100)},!0),document.addEventListener("selectionchange",ae),_e.on("destroy",function(){document.removeEventListener("selectionchange",ae)})}this.destroy=function(){d.parentElement&&d.parentElement.removeChild(d)}},m.$setUserAgentForTests=function(A,v){h=A,o=v}}),ace.define("ace/mouse/default_handlers",["require","exports","module","ace/lib/useragent"],function(C,m,b){var x=C("../lib/useragent");function p(s){s.$clickSelection=null;var n=s.editor;n.setDefaultHandler("mousedown",this.onMouseDown.bind(s)),n.setDefaultHandler("dblclick",this.onDoubleClick.bind(s)),n.setDefaultHandler("tripleclick",this.onTripleClick.bind(s)),n.setDefaultHandler("quadclick",this.onQuadClick.bind(s)),n.setDefaultHandler("mousewheel",this.onMouseWheel.bind(s)),["select","startSelect","selectEnd","selectAllEnd","selectByWordsEnd","selectByLinesEnd","dragWait","dragWaitEnd","focusWait"].forEach(function(t){s[t]=this[t]},this),s.selectByLines=this.extendSelectionBy.bind(s,"getLineRange"),s.selectByWords=this.extendSelectionBy.bind(s,"getWordRange")}function l(s,n){return(s.start.row==s.end.row?2*n.column-s.start.column-s.end.column:s.start.row!=s.end.row-1||s.start.column||s.end.column?2*n.row-s.start.row-s.end.row:n.column-4)<0?{cursor:s.start,anchor:s.end}:{cursor:s.end,anchor:s.start}}(function(){this.onMouseDown=function(s){var n=s.inSelection(),t=s.getDocumentPosition(),i=(this.mousedownEvent=s,this.editor),e=s.getButton();if(e!==0)!i.getSelectionRange().isEmpty()&&e!=1||i.selection.moveToPosition(t),e==2&&(i.textInput.onContextMenu(s.domEvent),x.isMozilla||s.preventDefault());else{if(this.mousedownEvent.time=Date.now(),!n||i.isFocused()||(i.focus(),!this.$focusTimeout||this.$clickSelection||i.inMultiSelectMode))return this.captureMouse(s),this.startSelect(t,1<s.domEvent._clicks),s.preventDefault();this.setState("focusWait"),this.captureMouse(s)}},this.startSelect=function(s,n){s=s||this.editor.renderer.screenToTextCoordinates(this.x,this.y);var t=this.editor;this.mousedownEvent&&(this.mousedownEvent.getShiftKey()?t.selection.selectToPosition(s):n||t.selection.moveToPosition(s),n||this.select(),t.renderer.scroller.setCapture&&t.renderer.scroller.setCapture(),t.setStyle("ace_selecting"),this.setState("select"))},this.select=function(){var s,n=this.editor,t=n.renderer.screenToTextCoordinates(this.x,this.y);this.$clickSelection&&(s=(s=this.$clickSelection.comparePoint(t))==-1?this.$clickSelection.end:s==1?this.$clickSelection.start:(t=(s=l(this.$clickSelection,t)).cursor,s.anchor),n.selection.setSelectionAnchor(s.row,s.column)),n.selection.selectToPosition(t),n.renderer.scrollCursorIntoView()},this.extendSelectionBy=function(a){var n,t,i,e=this.editor,r=e.renderer.screenToTextCoordinates(this.x,this.y),a=e.selection[a](r.row,r.column);this.$clickSelection&&(t=this.$clickSelection.comparePoint(a.start),n=this.$clickSelection.comparePoint(a.end),t==-1&&n<=0?(i=this.$clickSelection.end,a.end.row==r.row&&a.end.column==r.column||(r=a.start)):n==1&&0<=t?(i=this.$clickSelection.start,a.start.row==r.row&&a.start.column==r.column||(r=a.end)):i=t==-1&&n==1?(r=a.end,a.start):(r=(t=l(this.$clickSelection,r)).cursor,t.anchor),e.selection.setSelectionAnchor(i.row,i.column)),e.selection.selectToPosition(r),e.renderer.scrollCursorIntoView()},this.selectEnd=this.selectAllEnd=this.selectByWordsEnd=this.selectByLinesEnd=function(){this.$clickSelection=null,this.editor.unsetStyle("ace_selecting"),this.editor.renderer.scroller.releaseCapture&&this.editor.renderer.scroller.releaseCapture()},this.focusWait=function(){i=this.mousedownEvent.x,s=this.mousedownEvent.y,t=this.x,n=this.y;var s,n,t=Math.sqrt(Math.pow(t-i,2)+Math.pow(n-s,2)),i=Date.now();(0<t||i-this.mousedownEvent.time>this.$focusTimeout)&&this.startSelect(this.mousedownEvent.getDocumentPosition())},this.onDoubleClick=function(n){var n=n.getDocumentPosition(),t=this.editor,i=t.session.getBracketRange(n);i?(i.isEmpty()&&(i.start.column--,i.end.column++),this.setState("select")):(i=t.selection.getWordRange(n.row,n.column),this.setState("selectByWords")),this.$clickSelection=i,this.select()},this.onTripleClick=function(n){var n=n.getDocumentPosition(),t=this.editor,i=(this.setState("selectByLines"),t.getSelectionRange());i.isMultiLine()&&i.contains(n.row,n.column)?(this.$clickSelection=t.selection.getLineRange(i.start.row),this.$clickSelection.end=t.selection.getLineRange(i.end.row).end):this.$clickSelection=t.selection.getLineRange(n.row),this.select()},this.onQuadClick=function(s){var n=this.editor;n.selectAll(),this.$clickSelection=n.getSelectionRange(),this.setState("selectAll")},this.onMouseWheel=function(s){var n,t,i,e,r,a,o;if(!s.getAccelKey())return s.getShiftKey()&&s.wheelY&&!s.wheelX&&(s.wheelX=s.wheelY,s.wheelY=0),n=this.editor,this.$lastScroll||(this.$lastScroll={t:0,vx:0,vy:0,allowed:0}),t=this.$lastScroll,e=(o=(i=s.domEvent.timeStamp)-t.t)?s.wheelX/o:t.vx,r=o?s.wheelY/o:t.vy,o<550&&(e=(e+t.vx)/2,r=(r+t.vy)/2),o=!1,1<=(a=Math.abs(e/r))&&n.renderer.isScrollableBy(s.wheelX*s.speed,0)&&(o=!0),(o=a<=1&&n.renderer.isScrollableBy(0,s.wheelY*s.speed)?!0:o)?t.allowed=i:i-t.allowed<550&&(Math.abs(e)<=1.5*Math.abs(t.vx)&&Math.abs(r)<=1.5*Math.abs(t.vy)?(o=!0,t.allowed=i):t.allowed=0),t.t=i,t.vx=e,t.vy=r,o?(n.renderer.scrollBy(s.wheelX*s.speed,s.wheelY*s.speed),s.stop()):void 0}}).call(p.prototype),m.DefaultHandlers=p}),ace.define("ace/tooltip",["require","exports","module","ace/lib/oop","ace/lib/dom"],function(C,m,b){C("./lib/oop");var x=C("./lib/dom"),p="ace_tooltip";function l(s){this.isOpen=!1,this.$element=null,this.$parentNode=s}(function(){this.$init=function(){return this.$element=x.createElement("div"),this.$element.className=p,this.$element.style.display="none",this.$parentNode.appendChild(this.$element),this.$element},this.getElement=function(){return this.$element||this.$init()},this.setText=function(s){this.getElement().textContent=s},this.setHtml=function(s){this.getElement().innerHTML=s},this.setPosition=function(s,n){this.getElement().style.left=s+"px",this.getElement().style.top=n+"px"},this.setClassName=function(s){x.addCssClass(this.getElement(),s)},this.show=function(s,n,t){s!=null&&this.setText(s),n!=null&&t!=null&&this.setPosition(n,t),this.isOpen||(this.getElement().style.display="block",this.isOpen=!0)},this.hide=function(){this.isOpen&&(this.getElement().style.display="none",this.getElement().className=p,this.isOpen=!1)},this.getHeight=function(){return this.getElement().offsetHeight},this.getWidth=function(){return this.getElement().offsetWidth},this.destroy=function(){this.isOpen=!1,this.$element&&this.$element.parentNode&&this.$element.parentNode.removeChild(this.$element)}}).call(l.prototype),m.Tooltip=l}),ace.define("ace/mouse/default_gutter_handler",["require","exports","module","ace/lib/dom","ace/lib/oop","ace/lib/event","ace/tooltip"],function(C,m,b){var x=C("../lib/dom"),p=C("../lib/oop"),l=C("../lib/event"),s=C("../tooltip").Tooltip;function n(t){s.call(this,t)}p.inherits(n,s),function(){this.setPosition=function(t,i){var e=window.innerWidth||document.documentElement.clientWidth,r=window.innerHeight||document.documentElement.clientHeight,a=this.getWidth(),o=this.getHeight();e<(t+=15)+a&&(t-=t+a-e),r<(i+=15)+o&&(i-=20+o),s.prototype.setPosition.call(this,t,i)}}.call(n.prototype),m.GutterHandler=function(t){var i,e,r,a=t.editor,o=a.renderer.$gutterLayer,c=new n(a.container);function h(){i=i&&clearTimeout(i),r&&(c.hide(),r=null,a._signal("hideGutterTooltip",c),a.off("mousewheel",h))}function A(v){c.setPosition(v.x,v.y)}t.editor.setDefaultHandler("guttermousedown",function(v){if(a.isFocused()&&v.getButton()==0){var d=o.getRegion(v);if(d!="foldWidgets"){var d=v.getDocumentPosition().row,g=a.session.selection;if(v.getShiftKey())g.selectTo(d,0);else{if(v.domEvent.detail==2)return a.selectAll(),v.preventDefault();t.$clickSelection=a.selection.getLineRange(d)}return t.setState("selectByLines"),t.captureMouse(v),v.preventDefault()}}}),t.editor.setDefaultHandler("guttermousemove",function(v){var d=v.domEvent.target||v.domEvent.srcElement;if(x.hasCssClass(d,"ace_fold-widget"))return h();r&&t.$tooltipFollowsMouse&&A(v),e=v,i=i||setTimeout(function(){if(i=null,e&&!t.isMousePressed){var g=e.getDocumentPosition().row,y=o.$annotations[g];if(y){if(g==a.session.getLength()){var g=a.renderer.pixelToScreenCoordinates(0,e.y).row,w=e.$pos;if(g>a.session.documentToScreenRow(w.row,w.column))return void h()}r!=y&&(r=y.text.join("<br/>"),c.setHtml(r),(g=y.className)&&c.setClassName(g.trim()),c.show(),a._signal("showGutterTooltip",c),a.on("mousewheel",h),t.$tooltipFollowsMouse?A(e):(w=e.domEvent.target.getBoundingClientRect(),(y=c.getElement().style).left=w.right+"px",y.top=w.bottom+"px"))}else h()}else h()},50)}),l.addListener(a.renderer.$gutter,"mouseout",function(v){e=null,r&&!i&&(i=setTimeout(function(){i=null,h()},50))},a),a.on("changeSession",h)}}),ace.define("ace/mouse/mouse_event",["require","exports","module","ace/lib/event","ace/lib/useragent"],function(l,m,b){var x=l("../lib/event"),p=l("../lib/useragent"),l=m.MouseEvent=function(s,n){this.domEvent=s,this.editor=n,this.x=this.clientX=s.clientX,this.y=this.clientY=s.clientY,this.$pos=null,this.$inSelection=null,this.propagationStopped=!1,this.defaultPrevented=!1};(function(){this.stopPropagation=function(){x.stopPropagation(this.domEvent),this.propagationStopped=!0},this.preventDefault=function(){x.preventDefault(this.domEvent),this.defaultPrevented=!0},this.stop=function(){this.stopPropagation(),this.preventDefault()},this.getDocumentPosition=function(){return this.$pos||(this.$pos=this.editor.renderer.screenToTextCoordinates(this.clientX,this.clientY)),this.$pos},this.inSelection=function(){var s,n;return this.$inSelection===null&&((s=this.editor.getSelectionRange()).isEmpty()?this.$inSelection=!1:(n=this.getDocumentPosition(),this.$inSelection=s.contains(n.row,n.column))),this.$inSelection},this.getButton=function(){return x.getButton(this.domEvent)},this.getShiftKey=function(){return this.domEvent.shiftKey},this.getAccelKey=p.isMac?function(){return this.domEvent.metaKey}:function(){return this.domEvent.ctrlKey}}).call(l.prototype)}),ace.define("ace/mouse/dragdrop_handler",["require","exports","module","ace/lib/dom","ace/lib/event","ace/lib/useragent"],function(C,m,b){var x=C("../lib/dom"),p=C("../lib/event"),l=C("../lib/useragent");function s(t){var i,e,r,a,o,c,h,A,v,d,g,y=t.editor,w=x.createElement("div"),I=(w.style.cssText="top:-100px;position:absolute;z-index:2147483647;opacity:0.5",w.textContent="\xA0",["dragWait","dragWaitEnd","startDrag","dragReadyEnd","onMouseDrag"].forEach(function(Y){t[Y]=this[Y]},this),y.on("mousedown",this.onMouseDown.bind(t)),y.container),T=0;function B(){var Y,R,H,G,f,S,$,M,K=c;c=y.renderer.screenToTextCoordinates(e,r),H=c,R=K,G=Date.now(),Y=!R||H.row!=R.row,R=!R||H.column!=R.column,!d||Y||R?(y.moveCursorToPosition(H),d=G,g={x:e,y:r}):5<n(g.x,g.y,e,r)?d=null:200<=G-d&&(y.renderer.scrollCursorIntoView(),d=null),Y=c,R=K,H=Date.now(),G=y.renderer.layerConfig.lineHeight,K=y.renderer.layerConfig.characterWidth,f=y.renderer.scroller.getBoundingClientRect(),f={x:{left:e-f.left,right:f.right-e},y:{top:r-f.top,bottom:f.bottom-r}},S=Math.min(f.x.left,f.x.right),$=Math.min(f.y.top,f.y.bottom),M={row:Y.row,column:Y.column},S/K<=2&&(M.column+=f.x.left<f.x.right?-3:2),$/G<=1&&(M.row+=f.y.top<f.y.bottom?-1:1),S=Y.row!=M.row,K=Y.column!=M.column,$=!R||Y.row!=R.row,S||K&&!$?v?200<=H-v&&y.renderer.scrollCursorIntoView(M):v=H:v=null}function E(){o=y.selection.toOrientedRange(),i=y.session.addMarker(o,"ace_selection",y.getSelectionStyle()),y.clearSelection(),y.isFocused()&&y.renderer.$cursorLayer.setBlinking(!1),clearInterval(a),B(),a=setInterval(B,20),T=0,p.addListener(document,"mousemove",j)}function _(){clearInterval(a),y.session.removeMarker(i),i=null,y.selection.fromOrientedRange(o),y.isFocused()&&!A&&y.$resetCursorStyle(),T=0,d=v=c=o=null,p.removeListener(document,"mousemove",j)}this.onDragStart=function(Y){var R;if(this.cancelDrag||!I.draggable)return R=this,setTimeout(function(){R.startSelect(),R.captureMouse(Y)},0),Y.preventDefault();o=y.getSelectionRange();var H=Y.dataTransfer;H.effectAllowed=y.getReadOnly()?"copy":"copyMove",y.container.appendChild(w),H.setDragImage&&H.setDragImage(w,0,0),setTimeout(function(){y.container.removeChild(w)}),H.clearData(),H.setData("Text",y.session.getTextRange()),A=!0,this.setState("drag")},this.onDragEnd=function(Y){I.draggable=!1,A=!1,this.setState(null),y.getReadOnly()||(Y=Y.dataTransfer.dropEffect,h||Y!="move"||y.session.remove(y.getSelectionRange()),y.$resetCursorStyle()),this.editor.unsetStyle("ace_dragging"),this.editor.renderer.setCursorStyle("")},this.onDragEnter=function(Y){if(!y.getReadOnly()&&z(Y.dataTransfer))return e=Y.clientX,r=Y.clientY,i||E(),T++,Y.dataTransfer.dropEffect=h=D(Y),p.preventDefault(Y)},this.onDragOver=function(Y){if(!y.getReadOnly()&&z(Y.dataTransfer))return e=Y.clientX,r=Y.clientY,i||(E(),T++),P!==null&&(P=null),Y.dataTransfer.dropEffect=h=D(Y),p.preventDefault(Y)},this.onDragLeave=function(Y){if(--T<=0&&i)return _(),h=null,p.preventDefault(Y)},this.onDrop=function(Y){if(c){var R=Y.dataTransfer;if(A)switch(h){case"move":o=o.contains(c.row,c.column)?{start:c,end:c}:y.moveText(o,c);break;case"copy":o=y.moveText(o,c,!0)}else R=R.getData("Text"),o={start:c,end:y.session.insert(c,R)},y.focus(),h=null;return _(),p.preventDefault(Y)}},p.addListener(I,"dragstart",this.onDragStart.bind(t),y),p.addListener(I,"dragend",this.onDragEnd.bind(t),y),p.addListener(I,"dragenter",this.onDragEnter.bind(t),y),p.addListener(I,"dragover",this.onDragOver.bind(t),y),p.addListener(I,"dragleave",this.onDragLeave.bind(t),y),p.addListener(I,"drop",this.onDrop.bind(t),y);var P=null;function j(){P==null&&(P=setTimeout(function(){P!=null&&i&&_()},20))}function z(Y){return Y=Y.types,!Y||Array.prototype.some.call(Y,function(R){return R=="text/plain"||R=="Text"})}function D(Y){var R=["copy","copymove","all","uninitialized"],H=l.isMac?Y.altKey:Y.ctrlKey,G="uninitialized";try{G=Y.dataTransfer.effectAllowed.toLowerCase()}catch{}var f="none";return H&&0<=R.indexOf(G)?f="copy":0<=["move","copymove","linkmove","all","uninitialized"].indexOf(G)?f="move":0<=R.indexOf(G)&&(f="copy"),f}}function n(t,i,e,r){return Math.sqrt(Math.pow(e-t,2)+Math.pow(r-i,2))}(function(){this.dragWait=function(){Date.now()-this.mousedownEvent.time>this.editor.getDragDelay()&&this.startDrag()},this.dragWaitEnd=function(){this.editor.container.draggable=!1,this.startSelect(this.mousedownEvent.getDocumentPosition()),this.selectEnd()},this.dragReadyEnd=function(t){this.editor.$resetCursorStyle(),this.editor.unsetStyle("ace_dragging"),this.editor.renderer.setCursorStyle(""),this.dragWaitEnd()},this.startDrag=function(){this.cancelDrag=!1;var t=this.editor,i=(t.container.draggable=!0,t.renderer.$cursorLayer.setBlinking(!1),t.setStyle("ace_dragging"),l.isWin?"default":"move");t.renderer.setCursorStyle(i),this.setState("dragReady")},this.onMouseDrag=function(t){var i=this.editor.container;l.isIE&&this.state=="dragReady"&&3<n(this.mousedownEvent.x,this.mousedownEvent.y,this.x,this.y)&&i.dragDrop(),this.state==="dragWait"&&0<n(this.mousedownEvent.x,this.mousedownEvent.y,this.x,this.y)&&(i.draggable=!1,this.startSelect(this.mousedownEvent.getDocumentPosition()))},this.onMouseDown=function(t){var i,e,r;this.$dragEnabled&&(this.mousedownEvent=t,i=this.editor,e=t.inSelection(),r=t.getButton(),(t.domEvent.detail||1)!==1||r!==0||!e||t.editor.inMultiSelectMode&&(t.getAccelKey()||t.getShiftKey())||(this.mousedownEvent.time=Date.now(),"unselectable"in(r=t.domEvent.target||t.domEvent.srcElement)&&(r.unselectable="on"),i.getDragDelay()?(l.isWebKit&&(this.cancelDrag=!0,i.container.draggable=!0),this.setState("dragWait")):this.startDrag(),this.captureMouse(t,this.onMouseDrag.bind(this)),t.defaultPrevented=!0))}}).call(s.prototype),m.DragdropHandler=s}),ace.define("ace/mouse/touch_handler",["require","exports","module","ace/mouse/mouse_event","ace/lib/event","ace/lib/dom"],function(C,m,b){var x=C("./mouse_event").MouseEvent,p=C("../lib/event"),l=C("../lib/dom");m.addTouchListeners=function(s,n){var t,i,e,r,a,o,c,h,A,v="scroll",d=0,g=0,y=0,w=0;function I(){function _(z){var D,Y=z.target.getAttribute("action");Y!="more"&&j?(Y=="paste"?P.readText().then(function(R){n.execCommand(Y,R)}):Y&&(Y!="cut"&&Y!="copy"||(P?P.writeText(n.getCopyText()):document.execCommand("copy")),n.execCommand(Y)),A.firstChild.style.display="none",j=!1,Y!="openCommandPallete"&&n.focus()):(j=!j,z=n.getCopyText(),D=n.session.getUndoManager().hasUndo(),A.replaceChild(l.buildDom(j?["span",!z&&["span",{class:"ace_mobile-button",action:"selectall"},"Select All"],z&&["span",{class:"ace_mobile-button",action:"copy"},"Copy"],z&&["span",{class:"ace_mobile-button",action:"cut"},"Cut"],P&&["span",{class:"ace_mobile-button",action:"paste"},"Paste"],D&&["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"]),A.firstChild))}var P=window.navigator&&window.navigator.clipboard,j=!1;A=l.buildDom(["div",{class:"ace_mobile-menu",ontouchstart:function(z){v="menu",z.stopPropagation(),z.preventDefault(),n.textInput.focus()},ontouchend:function(z){z.stopPropagation(),z.preventDefault(),_(z)},onclick:_},["span"],["span",{class:"ace_mobile-button",action:"more"},"..."]],n.container)}function T(){A||I();var _=n.selection.cursor,_=n.renderer.textToScreenCoordinates(_.row,_.column),P=n.renderer.textToScreenCoordinates(0,0).pageX,j=n.renderer.scrollLeft,z=n.container.getBoundingClientRect();A.style.top=_.pageY-z.top-3+"px",_.pageX-z.left<z.width-70?(A.style.left="",A.style.right="10px"):(A.style.right="",A.style.left=P+j-z.left+"px"),A.style.display="",A.firstChild.style.display="none",n.on("input",B)}function B(_){A&&(A.style.display="none"),n.off("input",B)}function E(){a=null,clearTimeout(a);var _=n.selection.getRange(),P=_.contains(c.row,c.column);!_.isEmpty()&&P||(n.selection.moveToPosition(c),n.selection.selectWord()),v="wait",T()}p.addListener(s,"contextmenu",function(_){h&&n.textInput.getElement().focus()},n),p.addListener(s,"touchstart",function(_){var P=_.touches;if(a||1<P.length)clearTimeout(a),a=null,e=-1,v="zoom";else{h=n.$mouseHandler.isMousePressed=!0;var j=n.renderer.layerConfig.lineHeight,z=n.renderer.layerConfig.lineHeight,D=_.timeStamp,Y=(r=D,P[0]),R=Y.clientX,Y=Y.clientY,R=(Math.abs(t-R)+Math.abs(i-Y)>j&&(e=-1),t=_.clientX=R,i=_.clientY=Y,y=w=0,new x(_,n));if(c=R.getDocumentPosition(),D-e<500&&P.length==1&&!d)g++,_.preventDefault(),_.button=0,a=null,clearTimeout(a),n.selection.moveToPosition(c),(Y=2<=g?n.selection.getLineRange(c.row):n.session.getBracketRange(c))&&!Y.isEmpty()?n.selection.setRange(Y):n.selection.selectWord(),v="wait";else{g=0;var R=n.selection.cursor,P=n.selection.isEmpty()?R:n.selection.anchor,Y=n.renderer.$cursorLayer.getPixelPosition(R,!0),R=n.renderer.$cursorLayer.getPixelPosition(P,!0),P=n.renderer.scroller.getBoundingClientRect(),H=n.renderer.layerConfig.offset,G=n.renderer.scrollLeft,f=function(K,Q){return(K/=z)*K+(Q=Q/j-.75)*Q};if(_.clientX<P.left)return void(v="zoom");Y=f(_.clientX-P.left-Y.left+G,_.clientY-P.top-Y.top+H),f=f(_.clientX-P.left-R.left+G,_.clientY-P.top-R.top+H),Y<3.5&&f<3.5&&(v=f<Y?"cursor":"anchor"),v=f<3.5?"anchor":Y<3.5?"cursor":"scroll",a=setTimeout(E,450)}e=D}},n),p.addListener(s,"touchend",function(_){h=n.$mouseHandler.isMousePressed=!1,o&&clearInterval(o),v=="zoom"?(v="",d=0):(a?(n.selection.moveToPosition(c),d=0,T):v=="scroll"?(d+=60,o=setInterval(function(){d--<=0&&(clearInterval(o),o=null),Math.abs(y)<.01&&(y=0),Math.abs(w)<.01&&(w=0),d<20&&(y*=.9),d<20&&(w*=.9);var P=n.session.getScrollTop();n.renderer.scrollBy(10*y,10*w),P==n.session.getScrollTop()&&(d=0)},10),B):T)(),clearTimeout(a),a=null},n),p.addListener(s,"touchmove",function(_){a&&(clearTimeout(a),a=null);var P=_.touches;if(!(1<P.length||v=="zoom")){var P=P[0],j=t-P.clientX,z=i-P.clientY;if(v=="wait"){if(!(4<j*j+z*z))return _.preventDefault();v="cursor"}t=P.clientX,i=P.clientY,_.clientX=P.clientX,_.clientY=P.clientY;var P=_.timeStamp,D=P-r;r=P,v=="scroll"?((P=new x(_,n)).speed=1,P.wheelX=j,P.wheelY=z,10*Math.abs(j)<Math.abs(z)&&(j=0),10*Math.abs(z)<Math.abs(j)&&(z=0),D!=0&&(y=j/D,w=z/D),n._emit("mousewheel",P),P.propagationStopped||(y=w=0)):(j=new x(_,n).getDocumentPosition(),v=="cursor"?n.selection.moveCursorToPosition(j):v=="anchor"&&n.selection.setSelectionAnchor(j.row,j.column),n.renderer.scrollCursorIntoView(j),_.preventDefault())}},n)}}),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(r,m,b){function x(a){function o(v){document.hasFocus&&document.hasFocus()&&(a.isFocused()||document.activeElement!=(a.textInput&&a.textInput.getElement()))||window.focus(),a.focus(),setTimeout(function(){a.isFocused()||a.focus()})}var c=this,h=(this.editor=a,new s(this),new n(this),new i(this),a.renderer.getMouseEventTarget()),A=(p.addListener(h,"click",this.onMouseEvent.bind(this,"click"),a),p.addListener(h,"mousemove",this.onMouseMove.bind(this,"mousemove"),a),p.addMultiMouseDownListener([h,a.renderer.scrollBarV&&a.renderer.scrollBarV.inner,a.renderer.scrollBarH&&a.renderer.scrollBarH.inner,a.textInput&&a.textInput.getElement()].filter(Boolean),[400,300,250],this,"onMouseEvent",a),p.addMouseWheelListener(a.container,this.onMouseWheel.bind(this,"mousewheel"),a),e(a.container,a),a.renderer.$gutter);p.addListener(A,"mousedown",this.onMouseEvent.bind(this,"guttermousedown"),a),p.addListener(A,"click",this.onMouseEvent.bind(this,"gutterclick"),a),p.addListener(A,"dblclick",this.onMouseEvent.bind(this,"gutterdblclick"),a),p.addListener(A,"mousemove",this.onMouseEvent.bind(this,"guttermousemove"),a),p.addListener(h,"mousedown",o,a),p.addListener(A,"mousedown",o,a),l.isIE&&a.renderer.scrollBarV&&(p.addListener(a.renderer.scrollBarV.element,"mousedown",o,a),p.addListener(a.renderer.scrollBarH.element,"mousedown",o,a)),a.on("mousemove",function(v){var d,g;c.state||c.$dragDelay||!c.$dragEnabled||(v=a.renderer.screenToTextCoordinates(v.x,v.y),d=a.session.selection.getRange(),g=a.renderer,!d.isEmpty()&&d.insideStart(v.row,v.column)?g.setCursorStyle("default"):g.setCursorStyle(""))},a)}var p=r("../lib/event"),l=r("../lib/useragent"),s=r("./default_handlers").DefaultHandlers,n=r("./default_gutter_handler").GutterHandler,t=r("./mouse_event").MouseEvent,i=r("./dragdrop_handler").DragdropHandler,e=r("./touch_handler").addTouchListeners,r=r("../config");(function(){this.onMouseEvent=function(a,o){this.editor.session&&this.editor._emit(a,new t(o,this.editor))},this.onMouseMove=function(a,o){var c=this.editor._eventRegistry&&this.editor._eventRegistry.mousemove;c&&c.length&&this.editor._emit(a,new t(o,this.editor))},this.onMouseWheel=function(a,o){var c=new t(o,this.editor);c.speed=2*this.$scrollSpeed,c.wheelX=o.wheelX,c.wheelY=o.wheelY,this.editor._emit(a,c)},this.setState=function(a){this.state=a},this.captureMouse=function(a,o){this.x=a.x,this.y=a.y,this.isMousePressed=!0;function c(I){if(I){if(l.isWebKit&&!I.which&&g.releaseMouse)return g.releaseMouse();g.x=I.clientX,g.y=I.clientY,o&&o(I),g.mouseEvent=new t(I,g.editor),g.$mouseMoved=!0}}function h(I){v.off("beforeEndOperation",y),clearInterval(w),v.session&&A(),g[g.state+"End"]&&g[g.state+"End"](I),g.state="",g.isMousePressed=d.$isMousePressed=!1,d.$keepTextAreaAtCursor&&d.$moveTextAreaToCursor(),g.$onCaptureMouseMove=g.releaseMouse=null,I&&g.onMouseEvent("mouseup",I),v.endOperation()}function A(){g[g.state]&&g[g.state](),g.$mouseMoved=!1}var v=this.editor,d=this.editor.renderer,g=(d.$isMousePressed=!0,this);if(l.isOldIE&&a.domEvent.type=="dblclick")return setTimeout(function(){h(a)});var y=function(I){g.releaseMouse&&v.curOp.command.name&&v.curOp.selectionChanged&&(g[g.state+"End"]&&g[g.state+"End"](),g.state="",g.releaseMouse())},w=(v.on("beforeEndOperation",y),v.startOperation({command:{name:"mouse"}}),g.$onCaptureMouseMove=c,g.releaseMouse=p.capture(this.editor.container,c,h),setInterval(A,20))},this.releaseMouse=null,this.cancelContextMenu=function(){var a=function(o){o&&o.domEvent&&o.domEvent.type!="contextmenu"||(this.editor.off("nativecontextmenu",a),o&&o.domEvent&&p.stopEvent(o.domEvent))}.bind(this);setTimeout(a,10),this.editor.on("nativecontextmenu",a)},this.destroy=function(){this.releaseMouse&&this.releaseMouse()}}).call(x.prototype),r.defineOptions(x.prototype,"mouseHandler",{scrollSpeed:{initialValue:2},dragDelay:{initialValue:l.isMac?150:0},dragEnabled:{initialValue:!0},focusTimeout:{initialValue:0},tooltipFollowsMouse:{initialValue:!0}}),m.MouseHandler=x}),ace.define("ace/mouse/fold_handler",["require","exports","module","ace/lib/dom"],function(C,m,b){var x=C("../lib/dom");m.FoldHandler=function(p){p.on("click",function(l){var n=l.getDocumentPosition(),s=p.session,n=s.getFoldAt(n.row,n.column,1),n=(n&&(l.getAccelKey()?s.removeFold(n):s.expandFold(n),l.stop()),l.domEvent&&l.domEvent.target);n&&x.hasCssClass(n,"ace_inline_button")&&x.hasCssClass(n,"ace_toggle_wrap")&&(s.setOption("wrap",!s.getUseWrapMode()),p.renderer.scrollCursorIntoView())}),p.on("gutterclick",function(l){var s,n;p.renderer.$gutterLayer.getRegion(l)=="foldWidgets"&&(s=l.getDocumentPosition().row,(n=p.session).foldWidgets&&n.foldWidgets[s]&&p.session.onFoldWidgetClick(s,l),p.isFocused()||p.focus(),l.stop())}),p.on("gutterdblclick",function(l){var s,n,t;p.renderer.$gutterLayer.getRegion(l)=="foldWidgets"&&(t=l.getDocumentPosition().row,(n=(n=(s=p.session).getParentFoldRangeData(t,!0)).range||n.firstRange)&&(t=n.start.row,(t=s.getFoldAt(t,s.getLine(t).length,1))?s.removeFold(t):(s.addFold("...",n),p.renderer.scrollCursorIntoView({row:n.start.row,column:0}))),l.stop())})}}),ace.define("ace/keyboard/keybinding",["require","exports","module","ace/lib/keys","ace/lib/event"],function(C,m,b){function x(s){this.$editor=s,this.$data={editor:s},this.$handlers=[],this.setDefaultHandler(s.commands)}var p=C("../lib/keys"),l=C("../lib/event");(function(){this.setDefaultHandler=function(s){this.removeKeyboardHandler(this.$defaultHandler),this.$defaultHandler=s,this.addKeyboardHandler(s,0)},this.setKeyboardHandler=function(s){var n=this.$handlers;if(n[n.length-1]!=s){for(;n[n.length-1]&&n[n.length-1]!=this.$defaultHandler;)this.removeKeyboardHandler(n[n.length-1]);this.addKeyboardHandler(s,1)}},this.addKeyboardHandler=function(s,n){var t;s&&(typeof s!="function"||s.handleKeyboard||(s.handleKeyboard=s),(t=this.$handlers.indexOf(s))!=-1&&this.$handlers.splice(t,1),n==null?this.$handlers.push(s):this.$handlers.splice(n,0,s),t==-1&&s.attach&&s.attach(this.$editor))},this.removeKeyboardHandler=function(s){var n=this.$handlers.indexOf(s);return n!=-1&&(this.$handlers.splice(n,1),s.detach&&s.detach(this.$editor),!0)},this.getKeyboardHandler=function(){return this.$handlers[this.$handlers.length-1]},this.getStatusText=function(){var s=this.$data,n=s.editor;return this.$handlers.map(function(t){return t.getStatusText&&t.getStatusText(n,s)||""}).filter(Boolean).join(" ")},this.$callKeyboardHandlers=function(s,n,t,i){for(var e,r=!1,a=this.$editor.commands,o=this.$handlers.length;o--&&!((e=this.$handlers[o].handleKeyboard(this.$data,s,n,t,i))&&e.command&&((r=e.command=="null"||a.exec(e.command,this.$editor,e.args,i))&&i&&s!=-1&&e.passEvent!=1&&e.command.passEvent!=1&&l.stopEvent(i),r)););return r||s!=-1||(e={command:"insertstring"},r=a.exec("insertstring",this.$editor,n)),r&&this.$editor._signal&&this.$editor._signal("keyboardActivity",e),r},this.onCommandKey=function(s,n,t){var i=p.keyCodeToString(t);return this.$callKeyboardHandlers(n,i,t,s)},this.onTextInput=function(s){return this.$callKeyboardHandlers(-1,s)}}).call(x.prototype),m.KeyBinding=x}),ace.define("ace/lib/bidiutil",["require","exports","module"],function(C,m,b){var x=0,p=0,l=!1,s=!1,n=!1,t=[[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]],i=[[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]],e=0,r=1,a=2,o=3,c=4,h=5,A=6,v=7,d=8,g=9,y=10,w=11,I=12,T=13,B=14,E=15,_=16,P=17,j=18,z=[j,j,j,j,j,j,j,j,j,A,h,A,d,h,j,j,j,j,j,j,j,j,j,j,j,j,j,j,h,h,h,A,d,c,c,w,w,w,c,c,c,c,c,y,g,y,g,g,a,a,a,a,a,a,a,a,a,a,g,c,c,c,c,c,c,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,c,c,c,c,c,c,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,c,c,c,c,j,j,j,j,j,j,h,j,j,j,j,j,j,j,j,j,j,j,j,j,j,j,j,j,j,j,j,j,j,j,j,j,j,g,c,w,w,w,w,c,c,c,c,e,c,c,j,c,c,w,w,a,a,c,e,c,c,c,a,e,c,c,c,c,c],D=[d,d,d,d,d,d,d,d,d,d,d,j,j,j,e,r,c,c,c,c,c,c,c,c,c,c,c,c,c,c,c,c,c,c,c,c,c,c,c,c,d,h,T,B,E,_,P,g,w,w,w,w,w,c,c,c,c,c,c,c,c,c,c,c,c,c,c,c,g,c,c,c,c,c,c,c,c,c,c,c,c,c,c,c,c,c,c,c,c,c,c,c,c,c,c,d];function Y(G,f,S,$){var M,K,Q,te=x?i:t,he=0,Ae=-1,ge=null,Ce=null,ve=[];if(!$)for(ge=0,$=[];ge<S;ge++)$[ge]=H(G[ge]);for(p=x,n=s=l=!1,Ce=0;Ce<S;Ce++){if(Q=he,ve[Ce]=M=function(Te,_e,Se,ue){var $e,ae,pe,ce=_e[ue];switch(ce){case e:case r:l=!1;case c:case o:return ce;case a:return l?o:a;case v:return l=!0,r;case d:return c;case g:return ue<1||ue+1>=_e.length||($e=Se[ue-1])!=a&&$e!=o||(de=_e[ue+1])!=a&&de!=o?c:(de=l?o:de)==$e?de:c;case y:return($e=0<ue?Se[ue-1]:h)==a&&ue+1<_e.length&&_e[ue+1]==a?a:c;case w:if(0<ue&&Se[ue-1]==a)return a;if(l)return c;for(pe=ue+1,ae=_e.length;pe<ae&&_e[pe]==w;)pe++;return pe<ae&&_e[pe]==a?a:c;case I:for(ae=_e.length,pe=ue+1;pe<ae&&_e[pe]==I;)pe++;if(pe<ae){var de=Te[ue],de=1425<=de&&de<=2303||de==64286;if($e=_e[pe],de&&($e==r||$e==v))return r}return ue<1||($e=_e[ue-1])==h?c:Se[ue-1];case h:return s=!(l=!1),x;case A:return n=!0,c;case T:case B:case _:case P:case E:l=!1;case j:return c}}(G,$,ve,Ce),Q=240&(he=te[Q][M]),he&=15,f[Ce]=K=te[he][5],0<Q){if(Q==16)for(ge=Ae;ge<Ce;ge++)f[ge]=1;Ae=-1}if(te[he][6])Ae==-1&&(Ae=Ce);else if(-1<Ae){for(ge=Ae;ge<Ce;ge++)f[ge]=K;Ae=-1}$[Ce]==h&&(f[Ce]=0),p|=K}if(n){for(ge=0;ge<S;ge++)if($[ge]==A){f[ge]=x;for(var ye=ge-1;0<=ye&&$[ye]==d;ye--)f[ye]=x}}}function R(G,f,S){if(!(p<G))if(G!=1||x!=1||s)for(var $,M,K,Q,te=S.length,he=0;he<te;){if(f[he]>=G){for($=he+1;$<te&&f[$]>=G;)$++;for(M=he,K=$-1;M<K;M++,K--)Q=S[M],S[M]=S[K],S[K]=Q;he=$}he++}else S.reverse()}function H(G){var f=G.charCodeAt(0),S=f>>8;return S==0?191<f?e:z[f]:S==5?/[\u0591-\u05f4]/.test(G)?r:e:S==6?/[\u0610-\u061a\u064b-\u065f\u06d6-\u06e4\u06e7-\u06ed]/.test(G)?I:/[\u0660-\u0669\u066b-\u066c]/.test(G)?o:f==1642?w:/[\u06f0-\u06f9]/.test(G)?a:v:S==32&&f<=8287?D[255&f]:S==254&&65136<=f?v:c}m.L=e,m.R=r,m.EN=a,m.ON_R=3,m.AN=4,m.R_H=5,m.B=6,m.RLE=7,m.DOT="\xB7",m.doBidiReorder=function(G,f,S){if(G.length<2)return{};var $=G.split(""),M=new Array($.length),K=new Array($.length),Q=[];x=S?1:0,Y($,Q,$.length,f);for(var te=0;te<M.length;M[te]=te,te++);for(R(2,Q,M),R(1,Q,M),te=0;te<M.length-1;te++)f[te]===o?Q[te]=m.AN:Q[te]===r&&(f[te]>v&&f[te]<T||f[te]===c||f[te]===j)?Q[te]=m.ON_R:0<te&&$[te-1]==="\u0644"&&/\u0622|\u0623|\u0625|\u0627/.test($[te])&&(Q[te-1]=Q[te]=m.R_H,te++);for($[$.length-1]===m.DOT&&(Q[$.length-1]=m.B),$[0]==="\u202B"&&(Q[0]=m.RLE),te=0;te<M.length;te++)K[te]=Q[M[te]];return{logicalFromVisual:M,bidiLevels:K}},m.hasBidiCharacters=function(G,f){for(var S=!1,$=0;$<G.length;$++)f[$]=H(G.charAt($)),S||f[$]!=r&&f[$]!=v&&f[$]!=o||(S=!0);return S},m.getVisualFromLogicalIdx=function(G,f){for(var S=0;S<f.logicalFromVisual.length;S++)if(f.logicalFromVisual[S]==G)return S;return 0}}),ace.define("ace/bidihandler",["require","exports","module","ace/lib/bidiutil","ace/lib/lang"],function(C,m,b){function x(n){this.session=n,this.bidiMap={},this.currentRow=null,this.bidiUtil=p,this.charWidths=[],this.EOL="\xAC",this.showInvisibles=!0,this.isRtlDir=!1,this.$isRtl=!1,this.line="",this.wrapIndent=0,this.EOF="\xB6",this.RLE="\u202B",this.contentWidth=0,this.fontMetrics=null,this.rtlLineOffset=0,this.wrapOffset=0,this.isMoveLeftOperation=!1,this.seenBidi=s.test(n.getValue())}var p=C("./lib/bidiutil"),l=C("./lib/lang"),s=/[\u0590-\u05f4\u0600-\u06ff\u0700-\u08ac\u202B]/;(function(){this.isBidiRow=function(n,t,i){return!!this.seenBidi&&(n!==this.currentRow&&(this.currentRow=n,this.updateRowLine(t,i),this.updateBidiMap()),this.bidiMap.bidiLevels)},this.onChange=function(n){this.seenBidi?this.currentRow=null:n.action=="insert"&&s.test(n.lines.join(`
`))&&(this.seenBidi=!0,this.currentRow=null)},this.getDocumentRow=function(){var n=0,t=this.session.$screenRowCache;return n=t.length&&0<=(t=this.session.$getRowCacheIndex(t,this.currentRow))?this.session.$docRowCache[t]:n},this.getSplitIndex=function(){var n=0,t=this.session.$screenRowCache;if(t.length)for(var i,e=this.session.$getRowCacheIndex(t,this.currentRow);0<this.currentRow-n&&(i=this.session.$getRowCacheIndex(t,this.currentRow-n-1))===e;)e=i,n++;else n=this.currentRow;return n},this.updateRowLine=function(n,t){var i,e=(n=n===void 0?this.getDocumentRow():n)===this.session.getLength()-1?this.EOF:this.EOL,r=(this.wrapIndent=0,this.line=this.session.getLine(n),this.isRtlDir=this.$isRtl||this.line.charAt(0)===this.RLE,this.session.$useWrapMode?(n=this.session.$wrapData[n])&&(0<(t=t===void 0?this.getSplitIndex():t)&&n.length?(this.wrapIndent=n.indent,this.wrapOffset=this.wrapIndent*this.charWidths[p.L],this.line=t<n.length?this.line.substring(n[t-1],n[t]):this.line.substring(n[n.length-1])):this.line=this.line.substring(0,n[t]),t==n.length&&(this.line+=this.showInvisibles?e:p.DOT)):this.line+=this.showInvisibles?e:p.DOT,this.session),a=0;this.line=this.line.replace(/\t|[\u1100-\u2029, \u202F-\uFFE6]/g,function(o,c){return o==="	"||r.isFullWidth(o.charCodeAt(0))?(i=o==="	"?r.getScreenTabSize(c+a):2,a+=i-1,l.stringRepeat(p.DOT,i)):o}),this.isRtlDir&&(this.fontMetrics.$main.textContent=this.line.charAt(this.line.length-1)==p.DOT?this.line.substr(0,this.line.length-1):this.line,this.rtlLineOffset=this.contentWidth-this.fontMetrics.$main.getBoundingClientRect().width)},this.updateBidiMap=function(){var n=[];p.hasBidiCharacters(this.line,n)||this.isRtlDir?this.bidiMap=p.doBidiReorder(this.line,n,this.isRtlDir):this.bidiMap={}},this.markAsDirty=function(){this.currentRow=null},this.updateCharacterWidths=function(n){var t;this.characterWidth!==n.$characterSize.width&&(this.fontMetrics=n,t=this.characterWidth=n.$characterSize.width,n=n.$measureCharWidth("\u05D4"),this.charWidths[p.L]=this.charWidths[p.EN]=this.charWidths[p.ON_R]=t,this.charWidths[p.R]=this.charWidths[p.AN]=n,this.charWidths[p.R_H]=.45*n,this.charWidths[p.B]=this.charWidths[p.RLE]=0,this.currentRow=null)},this.setShowInvisibles=function(n){this.showInvisibles=n,this.currentRow=null},this.setEolChar=function(n){this.EOL=n},this.setContentWidth=function(n){this.contentWidth=n},this.isRtlLine=function(n){return!!this.$isRtl||(n!=null?this.session.getLine(n).charAt(0)==this.RLE:this.isRtlDir)},this.setRtlDirection=function(n,t){for(var i=n.getCursorPosition(),e=n.selection.getSelectionAnchor().row;e<=i.row;e++)t||n.session.getLine(e).charAt(0)!==n.session.$bidiHandler.RLE?t&&n.session.getLine(e).charAt(0)!==n.session.$bidiHandler.RLE&&n.session.doc.insert({column:0,row:e},n.session.$bidiHandler.RLE):n.session.doc.removeInLine(e,0,1)},this.getPosLeft=function(n){n-=this.wrapIndent;var t=this.line.charAt(0)===this.RLE?1:0,i=t<n?this.session.getOverwrite()?n:n-1:t,e=p.getVisualFromLogicalIdx(i,this.bidiMap),r=this.bidiMap.bidiLevels,a=0;!this.session.getOverwrite()&&n<=t&&r[e]%2!=0&&e++;for(var o=0;o<e;o++)a+=this.charWidths[r[o]];return!this.session.getOverwrite()&&t<n&&r[e]%2==0&&(a+=this.charWidths[r[e]]),this.wrapIndent&&(a+=this.isRtlDir?-1*this.wrapOffset:this.wrapOffset),this.isRtlDir&&(a+=this.rtlLineOffset),a},this.getSelections=function(n,t){var i,e=this.bidiMap,r=e.bidiLevels,a=[],o=0,c=Math.min(n,t)-this.wrapIndent,h=Math.max(n,t)-this.wrapIndent,A=!1,v=!1,d=0;this.wrapIndent&&(o+=this.isRtlDir?-1*this.wrapOffset:this.wrapOffset);for(var g,y=0;y<r.length;y++)g=e.logicalFromVisual[y],i=r[y],(A=c<=g&&g<h)&&!v?d=o:!A&&v&&a.push({left:d,width:o-d}),o+=this.charWidths[i],v=A;if(A&&y===r.length&&a.push({left:d,width:o-d}),this.isRtlDir)for(var w=0;w<a.length;w++)a[w].left+=this.rtlLineOffset;return a},this.offsetToCol=function(i){this.isRtlDir&&(i-=this.rtlLineOffset);var t=0,i=Math.max(i,0),e=0,r=0,a=this.bidiMap.bidiLevels,o=this.charWidths[a[r]];for(this.wrapIndent&&(i-=this.isRtlDir?-1*this.wrapOffset:this.wrapOffset);e+o/2<i;){if(e+=o,r===a.length-1){o=0;break}o=this.charWidths[a[++r]]}return(t=0<r&&a[r-1]%2!=0&&a[r]%2==0?(i<e&&r--,this.bidiMap.logicalFromVisual[r]):0<r&&a[r-1]%2==0&&a[r]%2!=0?1+(e<i?this.bidiMap.logicalFromVisual[r]:this.bidiMap.logicalFromVisual[r-1]):this.isRtlDir&&r===a.length-1&&o===0&&a[r-1]%2==0||!this.isRtlDir&&r===0&&a[r]%2!=0?1+this.bidiMap.logicalFromVisual[r]:(0<r&&a[r-1]%2!=0&&o!==0&&r--,this.bidiMap.logicalFromVisual[r]))===0&&this.isRtlDir&&t++,t+this.wrapIndent}}).call(x.prototype),m.BidiHandler=x}),ace.define("ace/selection",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/lib/event_emitter","ace/range"],function(C,m,b){function x(t){this.session=t,this.doc=t.getDocument(),this.clearSelection(),this.cursor=this.lead=this.doc.createAnchor(0,0),this.anchor=this.doc.createAnchor(0,0),this.$silent=!1;var i=this;this.cursor.on("change",function(e){i.$cursorChanged=!0,i.$silent||i._emit("changeCursor"),i.$isEmpty||i.$silent||i._emit("changeSelection"),i.$keepDesiredColumnOnChange||e.old.column==e.value.column||(i.$desiredColumn=null)}),this.anchor.on("change",function(){i.$anchorChanged=!0,i.$isEmpty||i.$silent||i._emit("changeSelection")})}var p=C("./lib/oop"),l=C("./lib/lang"),s=C("./lib/event_emitter").EventEmitter,n=C("./range").Range;(function(){p.implement(this,s),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.setSelectionAnchor=function(t,i){this.$isEmpty=!1,this.anchor.setPosition(t,i)},this.getAnchor=this.getSelectionAnchor=function(){return this.$isEmpty?this.getSelectionLead():this.anchor.getPosition()},this.getSelectionLead=function(){return this.lead.getPosition()},this.isBackwards=function(){var t=this.anchor,i=this.lead;return t.row>i.row||t.row==i.row&&t.column>i.column},this.getRange=function(){var t=this.anchor,i=this.lead;return this.$isEmpty?n.fromPoints(i,i):this.isBackwards()?n.fromPoints(i,t):n.fromPoints(t,i)},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(t,r){var e=r?t.end:t.start,r=r?t.start:t.end;this.$setSelection(e.row,e.column,r.row,r.column)},this.$setSelection=function(t,i,e,r){var a,o;this.$silent||(a=this.$isEmpty,o=this.inMultiSelectMode,this.$silent=!0,this.$cursorChanged=this.$anchorChanged=!1,this.anchor.setPosition(t,i),this.cursor.setPosition(e,r),this.$isEmpty=!n.comparePoints(this.anchor,this.cursor),this.$silent=!1,this.$cursorChanged&&this._emit("changeCursor"),(this.$cursorChanged||this.$anchorChanged||a!=this.$isEmpty||o)&&this._emit("changeSelection"))},this.$moveSelection=function(t){var i=this.lead;this.$isEmpty&&this.setSelectionAnchor(i.row,i.column),t.call(this)},this.selectTo=function(t,i){this.$moveSelection(function(){this.moveCursorTo(t,i)})},this.selectToPosition=function(t){this.$moveSelection(function(){this.moveCursorToPosition(t)})},this.moveTo=function(t,i){this.clearSelection(),this.moveCursorTo(t,i)},this.moveToPosition=function(t){this.clearSelection(),this.moveCursorToPosition(t)},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(t,i){var e;return i===void 0&&(t=(e=t||this.lead).row,i=e.column),this.session.getWordRange(t,i)},this.selectWord=function(){this.setSelectionRange(this.getWordRange())},this.selectAWord=function(){var t=this.getCursor(),t=this.session.getAWordRange(t.row,t.column);this.setSelectionRange(t)},this.getLineRange=function(e,i){var e=typeof e=="number"?e:this.lead.row,r=this.session.getFoldLine(e),r=r?(e=r.start.row,r.end.row):e;return i===!0?new n(e,0,r,this.session.getLine(r).length):new n(e,0,r+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(t,i,e){var r=t.column,a=t.column+i;return e<0&&(r=t.column-i,a=t.column),this.session.isTabStop(t)&&this.doc.getLine(t.row).slice(r,a).split(" ").length-1==i},this.moveCursorLeft=function(){var t,i=this.lead.getPosition();(t=this.session.getFoldAt(i.row,i.column,-1))?this.moveCursorTo(t.start.row,t.start.column):i.column===0?0<i.row&&this.moveCursorTo(i.row-1,this.doc.getLine(i.row-1).length):(t=this.session.getTabSize(),this.wouldMoveIntoSoftTab(i,t,-1)&&!this.session.getNavigateWithinSoftTabs()?this.moveCursorBy(0,-t):this.moveCursorBy(0,-1))},this.moveCursorRight=function(){var t,i=this.lead.getPosition();(t=this.session.getFoldAt(i.row,i.column,1))?this.moveCursorTo(t.end.row,t.end.column):this.lead.column==this.doc.getLine(this.lead.row).length?this.lead.row<this.doc.getLength()-1&&this.moveCursorTo(this.lead.row+1,0):(t=this.session.getTabSize(),i=this.lead,this.wouldMoveIntoSoftTab(i,t,1)&&!this.session.getNavigateWithinSoftTabs()?this.moveCursorBy(0,t):this.moveCursorBy(0,1))},this.moveCursorLineStart=function(){var e=this.lead.row,t=this.lead.column,i=this.session.documentToScreenRow(e,t),i=this.session.screenToDocumentPosition(i,0),e=this.session.getDisplayLine(e,null,i.row,i.column).match(/^\s*/);e[0].length==t||this.session.$useEmacsStyleLineStart||(i.column+=e[0].length),this.moveCursorToPosition(i)},this.moveCursorLineEnd=function(){var t,i=this.lead,i=this.session.getDocumentLastRowColumnPosition(i.row,i.column);this.lead.column==i.column&&(t=this.session.getLine(i.row),i.column==t.length&&0<(t=t.search(/\s+$/))&&(i.column=t)),this.moveCursorTo(i.row,i.column)},this.moveCursorFileEnd=function(){var t=this.doc.getLength()-1,i=this.doc.getLine(t).length;this.moveCursorTo(t,i)},this.moveCursorFileStart=function(){this.moveCursorTo(0,0)},this.moveCursorLongWordRight=function(){var t=this.lead.row,i=this.lead.column,e=this.doc.getLine(t),r=e.substring(i),a=(this.session.nonTokenRe.lastIndex=0,this.session.tokenRe.lastIndex=0,this.session.getFoldAt(t,i,1));a?this.moveCursorTo(a.end.row,a.end.column):(this.session.nonTokenRe.exec(r)&&(i+=this.session.nonTokenRe.lastIndex,this.session.nonTokenRe.lastIndex=0,r=e.substring(i)),i>=e.length?(this.moveCursorTo(t,e.length),this.moveCursorRight(),t<this.doc.getLength()-1&&this.moveCursorWordRight()):(this.session.tokenRe.exec(r)&&(i+=this.session.tokenRe.lastIndex,this.session.tokenRe.lastIndex=0),this.moveCursorTo(t,i)))},this.moveCursorLongWordLeft=function(){var t,i=this.lead.row,e=this.lead.column;(t=this.session.getFoldAt(i,e,-1))?this.moveCursorTo(t.start.row,t.start.column):((t=this.session.getFoldStringAt(i,e,-1))==null&&(t=this.doc.getLine(i).substring(0,e)),t=l.stringReverse(t),this.session.nonTokenRe.lastIndex=0,this.session.tokenRe.lastIndex=0,this.session.nonTokenRe.exec(t)&&(e-=this.session.nonTokenRe.lastIndex,t=t.slice(this.session.nonTokenRe.lastIndex),this.session.nonTokenRe.lastIndex=0),e<=0?(this.moveCursorTo(i,0),this.moveCursorLeft(),0<i&&this.moveCursorWordLeft()):(this.session.tokenRe.exec(t)&&(e-=this.session.tokenRe.lastIndex,this.session.tokenRe.lastIndex=0),this.moveCursorTo(i,e)))},this.$shortWordEndIndex=function(t){var i,e=0,r=/\s/,a=this.session.tokenRe;if(a.lastIndex=0,this.session.tokenRe.exec(t))e=this.session.tokenRe.lastIndex;else{for(;(i=t[e])&&r.test(i);)e++;if(e<1){for(a.lastIndex=0;(i=t[e])&&!a.test(i);)if(a.lastIndex=0,e++,r.test(i)){if(2<e){e--;break}for(;(i=t[e])&&r.test(i);)e++;if(2<e)break}}}return a.lastIndex=0,e},this.moveCursorShortWordRight=function(){var t=this.lead.row,i=this.lead.column,e=this.doc.getLine(t),r=e.substring(i),a=this.session.getFoldAt(t,i,1);if(a)return this.moveCursorTo(a.end.row,a.end.column);if(i==e.length){for(var o=this.doc.getLength();r=this.doc.getLine(++t),t<o&&/^\s*$/.test(r););/^\s+/.test(r)||(r=""),i=0}a=this.$shortWordEndIndex(r),this.moveCursorTo(t,i+a)},this.moveCursorShortWordLeft=function(){var t=this.lead.row,i=this.lead.column;if(r=this.session.getFoldAt(t,i,-1))return this.moveCursorTo(r.start.row,r.start.column);var e=this.session.getLine(t).substring(0,i);if(i===0){for(;e=this.doc.getLine(--t),0<t&&/^\s*$/.test(e););i=e.length,/\s+$/.test(e)||(e="")}var r=l.stringReverse(e),r=this.$shortWordEndIndex(r);return this.moveCursorTo(t,i-r)},this.moveCursorWordRight=function(){this.session.$selectLongWords?this.moveCursorLongWordRight():this.moveCursorShortWordRight()},this.moveCursorWordLeft=function(){this.session.$selectLongWords?this.moveCursorLongWordLeft():this.moveCursorShortWordLeft()},this.moveCursorBy=function(t,i){var e,r=this.session.documentToScreenPosition(this.lead.row,this.lead.column),a=(i===0&&(t!==0&&(this.session.$bidiHandler.isBidiRow(r.row,this.lead.row)?(e=this.session.$bidiHandler.getPosLeft(r.column),r.column=Math.round(e/this.session.$bidiHandler.charWidths[0])):e=r.column*this.session.$bidiHandler.charWidths[0]),this.$desiredColumn?r.column=this.$desiredColumn:this.$desiredColumn=r.column),t!=0&&this.session.lineWidgets&&this.session.lineWidgets[this.lead.row]&&(a=this.session.lineWidgets[this.lead.row],t<0?t-=a.rowsAbove||0:0<t&&(t+=a.rowCount-(a.rowsAbove||0))),this.session.screenToDocumentPosition(r.row+t,r.column,e));t!==0&&i===0&&a.row===this.lead.row&&(a.column,this.lead.column),this.moveCursorTo(a.row,a.column+i,i===0)},this.moveCursorToPosition=function(t){this.moveCursorTo(t.row,t.column)},this.moveCursorTo=function(t,i,e){var r=this.session.getFoldAt(t,i,1),r=(r&&(t=r.start.row,i=r.start.column),this.$keepDesiredColumnOnChange=!0,this.session.getLine(t));/[\uDC00-\uDFFF]/.test(r.charAt(i))&&r.charAt(i-1)&&(this.lead.row==t&&this.lead.column==i+1?i-=1:i+=1),this.lead.setPosition(t,i),this.$keepDesiredColumnOnChange=!1,e||(this.$desiredColumn=null)},this.moveCursorToScreen=function(t,i,e){t=this.session.screenToDocumentPosition(t,i),this.moveCursorTo(t.row,t.column,e)},this.detach=function(){this.lead.detach(),this.anchor.detach()},this.fromOrientedRange=function(t){this.setSelectionRange(t,t.cursor==t.start),this.$desiredColumn=t.desiredColumn||this.$desiredColumn},this.toOrientedRange=function(t){var i=this.getRange();return t?(t.start.column=i.start.column,t.start.row=i.start.row,t.end.column=i.end.column,t.end.row=i.end.row):t=i,t.cursor=this.isBackwards()?t.start:t.end,t.desiredColumn=this.$desiredColumn,t},this.getRangeOfMovements=function(t){var i=this.getCursor();try{t(this);var e=this.getCursor();return n.fromPoints(i,e)}catch{return n.fromPoints(i,i)}finally{this.moveCursorToPosition(i)}},this.toJSON=function(){var t;return this.rangeCount?t=this.ranges.map(function(i){var e=i.clone();return e.isBackwards=i.cursor==i.start,e}):(t=this.getRange()).isBackwards=this.isBackwards(),t},this.fromJSON=function(t){if(t.start==null){if(this.rangeList&&1<t.length){this.toSingleRange(t[0]);for(var i=t.length;i--;){var e=n.fromPoints(t[i].start,t[i].end);t[i].isBackwards&&(e.cursor=e.start),this.addRange(e,!0)}return}t=t[0]}this.rangeList&&this.toSingleRange(t),this.setSelectionRange(t,t.isBackwards)},this.isEqual=function(t){if((t.length||this.rangeCount)&&t.length!=this.rangeCount)return!1;if(!t.length||!this.ranges)return this.getRange().isEqual(t);for(var i=this.ranges.length;i--;)if(!this.ranges[i].isEqual(t[i]))return!1;return!0}}).call(x.prototype),m.Selection=x}),ace.define("ace/tokenizer",["require","exports","module","ace/config"],function(C,m,b){function x(s){for(var n in this.states=s,this.regExps={},this.matchMappings={},this.states){for(var t=this.states[n],i=[],e=0,r=this.matchMappings[n]={defaultToken:"text"},a="g",o=[],c=0;c<t.length;c++){var h,A,v=t[c];v.defaultToken&&(r.defaultToken=v.defaultToken),v.caseInsensitive&&a.indexOf("i")===-1&&(a+="i"),v.unicode&&a.indexOf("u")===-1&&(a+="u"),v.regex!=null&&(v.regex instanceof RegExp&&(v.regex=v.regex.toString().slice(1,-1)),h=v.regex,A=new RegExp("(?:("+h+")|(.))").exec("a").length-2,Array.isArray(v.token)?v.token.length==1||A==1?v.token=v.token[0]:A-1!=v.token.length?(this.reportError("number of classes and regexp groups doesn't match",{rule:v,groupCount:A-1}),v.token=v.token[0]):(v.tokenArray=v.token,v.token=null,v.onMatch=this.$arrayTokens):typeof v.token!="function"||v.onMatch||(v.onMatch=1<A?this.$applyToken:v.token),1<A&&(h=/\\\d/.test(v.regex)?v.regex.replace(/\\([0-9]+)/g,function(d,g){return"\\"+(parseInt(g,10)+e+1)}):(A=1,this.removeCapturingGroups(v.regex)),v.splitRegex||typeof v.token=="string"||o.push(v)),r[e]=c,e+=A,i.push(h),v.onMatch||(v.onMatch=null))}i.length||(r[0]=0,i.push("$")),o.forEach(function(d){d.splitRegex=this.createSplitterRegexp(d.regex,a)},this),this.regExps[n]=new RegExp("("+i.join(")|(")+")|($)",a)}}var p=C("./config"),l=2e3;(function(){this.$setMaxTokenCount=function(s){l=0|s},this.$applyToken=function(s){var n=this.splitRegex.exec(s).slice(1),t=this.token.apply(this,n);if(typeof t=="string")return[{type:t,value:s}];for(var i=[],e=0,r=t.length;e<r;e++)n[e]&&(i[i.length]={type:t[e],value:n[e]});return i},this.$arrayTokens=function(s){if(!s)return[];var n=this.splitRegex.exec(s);if(!n)return"text";for(var t=[],i=this.tokenArray,e=0,r=i.length;e<r;e++)n[e+1]&&(t[t.length]={type:i[e],value:n[e+1]});return t},this.removeCapturingGroups=function(s){return s.replace(/\\.|\[(?:\\.|[^\\\]])*|\(\?[:=!<]|(\()/g,function(n,t){return t?"(?:":n})},this.createSplitterRegexp=function(s,n){var t,i,e;return s.indexOf("(?=")!=-1&&(t=0,i=!1,e={},s.replace(/(\\.)|(\((?:\?[=!])?)|(\))|([\[\]])/g,function(r,a,o,c,h,A){return i?i=h!="]":h?i=!0:c?(t==e.stack&&(e.end=A+1,e.stack=-1),t--):o&&(t++,o.length!=1&&(e.stack=t,e.start=A)),r}),e.end!=null&&/^\)*$/.test(s.substr(e.end))&&(s=s.substring(0,e.start)+s.substr(e.end))),(s=s.charAt(0)!="^"?"^"+s:s).charAt(s.length-1)!="$"&&(s+="$"),new RegExp(s,(n||"").replace("g",""))},this.getLineTokens=function(s,n){n&&typeof n!="string"?(n=(t=n.slice(0))[0])==="#tmp"&&(t.shift(),n=t.shift()):t=[];for(var t,i,e=n||"start",r=(r=this.states[e])||this.states[e="start"],a=this.matchMappings[e],o=this.regExps[e],c=[],h=o.lastIndex=0,A=0,v={type:null,value:""};i=o.exec(s);){var d,g=a.defaultToken,y=null,w=i[0],I=o.lastIndex;I-w.length>h&&(d=s.substring(h,I-w.length),v.type==g?v.value+=d:(v.type&&c.push(v),v={type:g,value:d}));for(var T=0;T<i.length-2;T++)if(i[T+1]!==void 0){g=(y=r[a[T]]).onMatch?y.onMatch(w,e,t,s):y.token,y.next&&(e=typeof y.next=="string"?y.next:y.next(e,t),(r=this.states[e])||(this.reportError("state doesn't exist",e),r=this.states[e="start"]),a=this.matchMappings[e],(o=this.regExps[e]).lastIndex=h=I),y.consumeLineEnd&&(h=I);break}if(w){if(typeof g=="string")y&&y.merge===!1||v.type!==g?(v.type&&c.push(v),v={type:g,value:w}):v.value+=w;else if(g)for(v.type&&c.push(v),v={type:null,value:""},T=0;T<g.length;T++)c.push(g[T])}if(h==s.length)break;if(h=I,A++>l){for(A>2*s.length&&this.reportError("infinite loop with in ace tokenizer",{startState:n,line:s});h<s.length;)v.type&&c.push(v),v={value:s.substring(h,h+=500),type:"overflow"};e="start",t=[];break}}return v.type&&c.push(v),1<t.length&&t[0]!==e&&t.unshift("#tmp",e),{tokens:c,state:t.length?t:e}},this.reportError=p.reportError}).call(x.prototype),m.Tokenizer=x}),ace.define("ace/mode/text_highlight_rules",["require","exports","module","ace/lib/lang"],function(C,m,b){function x(){this.$rules={start:[{token:"empty_line",regex:"^$"},{defaultToken:"text"}]}}var p=C("../lib/lang");(function(){this.addRules=function(n,t){if(t)for(var i in n){for(var e=n[i],r=0;r<e.length;r++){var a=e[r];(a.next||a.onMatch)&&(typeof a.next=="string"&&a.next.indexOf(t)!==0&&(a.next=t+a.next),a.nextState&&a.nextState.indexOf(t)!==0&&(a.nextState=t+a.nextState))}this.$rules[t+i]=e}else for(var i in n)this.$rules[i]=n[i]},this.getRules=function(){return this.$rules},this.embedRules=function(n,t,i,e,r){if(n=typeof n=="function"?new n().getRules():n,e)for(var a=0;a<e.length;a++)e[a]=t+e[a];else for(var o in e=[],n)e.push(t+o);if(this.addRules(n,t),i)for(var c=Array.prototype[r?"push":"unshift"],a=0;a<e.length;a++)c.apply(this.$rules[e[a]],p.deepCopy(i));this.$embeds||(this.$embeds=[]),this.$embeds.push(t)},this.getEmbeds=function(){return this.$embeds};function l(n,t){return n=="start"&&!t.length||t.unshift(this.nextState,n),this.nextState}function s(n,t){return t.shift(),t.shift()||"start"}this.normalizeRules=function(){var n=0,t=this.$rules;Object.keys(t).forEach(function i(e){var r=t[e];r.processed=!0;for(var a=0;a<r.length;a++){var o=r[a],c=null,h=(Array.isArray(o)&&(c=o,o={}),!o.regex&&o.start&&(o.regex=o.start,o.next||(o.next=[]),o.next.push({defaultToken:o.token},{token:o.token+".end",regex:o.end||o.start,next:"pop"}),o.token=o.token+".start",o.push=!0),o.next||o.push);if(h&&Array.isArray(h)?((v=o.stateName)||(typeof(v=o.token)!="string"&&(v=v[0]||""),t[v]&&(v+=n++)),t[v]=h,i(o.next=v)):h=="pop"&&(o.next=s),o.push&&(o.nextState=o.next||o.push,o.next=l,delete o.push),o.rules)for(var A in o.rules)t[A]?t[A].push&&t[A].push.apply(t[A],o.rules[A]):t[A]=o.rules[A];var v=typeof o=="string"?o:o.include;(c=v?Array.isArray(v)?v.map(function(d){return t[d]}):t[v]:c)&&(h=[a,1].concat(c),o.noEscape&&(h=h.filter(function(d){return!d.next})),r.splice.apply(r,h),a--),o.keywordMap&&(o.token=this.createKeywordMapper(o.keywordMap,o.defaultToken||"text",o.caseInsensitive),delete o.defaultToken)}},this)},this.createKeywordMapper=function(n,t,i,e){var r=Object.create(null);return this.$keywordList=[],Object.keys(n).forEach(function(a){for(var o=n[a].split(e||"|"),c=o.length;c--;){var h=o[c];this.$keywordList.push(h),i&&(h=h.toLowerCase()),r[h]=a}},this),n=null,i?function(a){return r[a.toLowerCase()]||t}:function(a){return r[a]||t}},this.getKeywords=function(){return this.$keywords}}).call(x.prototype),m.TextHighlightRules=x}),ace.define("ace/mode/behaviour",["require","exports","module"],function(C,m,b){function x(){this.$behaviours={}}(function(){this.add=function(p,l,s){switch(void 0){case this.$behaviours:this.$behaviours={};case this.$behaviours[p]:this.$behaviours[p]={}}this.$behaviours[p][l]=s},this.addBehaviours=function(p){for(var l in p)for(var s in p[l])this.add(l,s,p[l][s])},this.remove=function(p){this.$behaviours&&this.$behaviours[p]&&delete this.$behaviours[p]},this.inherit=function(p,l){p=(typeof p=="function"?new p:p).getBehaviours(l),this.addBehaviours(p)},this.getBehaviours=function(p){if(p){for(var l={},s=0;s<p.length;s++)this.$behaviours[p[s]]&&(l[p[s]]=this.$behaviours[p[s]]);return l}return this.$behaviours}}).call(x.prototype),m.Behaviour=x}),ace.define("ace/token_iterator",["require","exports","module","ace/range"],function(C,m,b){function x(l,s,n){this.$session=l,this.$row=s,this.$rowTokens=l.getTokens(s),l=l.getTokenAt(s,n),this.$tokenIndex=l?l.index:-1}var p=C("./range").Range;(function(){this.stepBackward=function(){for(--this.$tokenIndex;this.$tokenIndex<0;){if(--this.$row,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]},this.stepForward=function(){var l;for(this.$tokenIndex+=1;this.$tokenIndex>=this.$rowTokens.length;){if(this.$row+=1,l=l||this.$session.getLength(),this.$row>=l)return this.$row=l-1,null;this.$rowTokens=this.$session.getTokens(this.$row),this.$tokenIndex=0}return this.$rowTokens[this.$tokenIndex]},this.getCurrentToken=function(){return this.$rowTokens[this.$tokenIndex]},this.getCurrentTokenRow=function(){return this.$row},this.getCurrentTokenColumn=function(){var l=this.$rowTokens,s=this.$tokenIndex,n=l[s].start;if(n===void 0)for(n=0;0<s;)n+=l[--s].value.length;return n},this.getCurrentTokenPosition=function(){return{row:this.$row,column:this.getCurrentTokenColumn()}},this.getCurrentTokenRange=function(){var l=this.$rowTokens[this.$tokenIndex],s=this.getCurrentTokenColumn();return new p(this.$row,s,this.$row,s+l.value.length)}}).call(x.prototype),m.TokenIterator=x}),ace.define("ace/mode/behaviour/cstyle",["require","exports","module","ace/lib/oop","ace/mode/behaviour","ace/token_iterator","ace/lib/lang"],function(C,m,b){function x(h){var A=-1;if(h.multiSelect&&(A=h.selection.index,o.rangeCount!=h.multiSelect.rangeCount&&(o={rangeCount:h.multiSelect.rangeCount})),o[A])return s=o[A];s=o[A]={autoInsertedBrackets:0,autoInsertedRow:-1,autoInsertedLineEnd:"",maybeInsertedBrackets:0,maybeInsertedRow:-1,maybeInsertedLineStart:"",maybeInsertedLineEnd:""}}function p(h,A,v,d){var g=h.end.row-h.start.row;return{text:v+A+d,selection:[0,h.start.column+1,g,h.end.column+(g?0:1)]}}function l(h){this.add("braces","insertion",function(A,v,d,g,y){var w=d.getCursorPosition(),I=g.doc.getLine(w.row);if(y=="{")return x(d),B=d.getSelectionRange(),(E=g.doc.getTextRange(B))!==""&&E!=="{"&&d.getWrapBehavioursEnabled()?p(B,E,"{","}"):l.isSaneInsertion(d,g)?/[\]\}\)]/.test(I[w.column])||d.inMultiSelectMode||h&&h.braces?(l.recordAutoInsert(d,g,"}"),{text:"{}",selection:[1,1]}):(l.recordMaybeInsert(d,g,"{"),{text:"{",selection:[1,1]}):void 0;if(y=="}"){x(d);var T=I.substring(w.column,w.column+1);if(T=="}"&&g.$findOpeningBracket("}",{column:w.column+1,row:w.row})!==null&&l.isAutoInsertedClosing(w,I,y))return l.popAutoInsertedClosing(),{text:"",selection:[1,1]}}else{if(y==`
`||y==`\r
`){x(d);var B="";if(l.isMaybeInsertedClosing(w,I)&&(B=e.stringRepeat("}",s.maybeInsertedBrackets),l.clearMaybeInsertedClosing()),(T=I.substring(w.column,w.column+1))==="}"){var E=g.findMatchingBracket({row:w.row,column:w.column+1},"}");if(!E)return null;var _=this.$getIndent(g.getLine(E.row))}else{if(!B)return void l.clearMaybeInsertedClosing();_=this.$getIndent(I)}return y=_+g.getTabString(),{text:`
`+y+`
`+_+B,selection:[1,y.length,1,y.length]}}l.clearMaybeInsertedClosing()}}),this.add("braces","deletion",function(A,v,d,g,y){var w=g.doc.getTextRange(y);if(!y.isMultiLine()&&w=="{"){if(x(d),g.doc.getLine(y.start.row).substring(y.end.column,y.end.column+1)=="}")return y.end.column++,y;s.maybeInsertedBrackets--}}),this.add("parens","insertion",function(A,v,d,g,y){if(y=="(")return x(d),w=d.getSelectionRange(),(I=g.doc.getTextRange(w))!==""&&d.getWrapBehavioursEnabled()?p(w,I,"(",")"):l.isSaneInsertion(d,g)?(l.recordAutoInsert(d,g,")"),{text:"()",selection:[1,1]}):void 0;if(y==")"){x(d);var w=d.getCursorPosition(),I=g.doc.getLine(w.row),d=I.substring(w.column,w.column+1);if(d==")"&&g.$findOpeningBracket(")",{column:w.column+1,row:w.row})!==null&&l.isAutoInsertedClosing(w,I,y))return l.popAutoInsertedClosing(),{text:"",selection:[1,1]}}}),this.add("parens","deletion",function(A,v,d,g,y){var w=g.doc.getTextRange(y);if(!y.isMultiLine()&&w=="("&&(x(d),g.doc.getLine(y.start.row).substring(y.start.column+1,y.start.column+2)==")"))return y.end.column++,y}),this.add("brackets","insertion",function(A,v,d,g,y){if(y=="[")return x(d),w=d.getSelectionRange(),(I=g.doc.getTextRange(w))!==""&&d.getWrapBehavioursEnabled()?p(w,I,"[","]"):l.isSaneInsertion(d,g)?(l.recordAutoInsert(d,g,"]"),{text:"[]",selection:[1,1]}):void 0;if(y=="]"){x(d);var w=d.getCursorPosition(),I=g.doc.getLine(w.row),d=I.substring(w.column,w.column+1);if(d=="]"&&g.$findOpeningBracket("]",{column:w.column+1,row:w.row})!==null&&l.isAutoInsertedClosing(w,I,y))return l.popAutoInsertedClosing(),{text:"",selection:[1,1]}}}),this.add("brackets","deletion",function(A,v,d,g,y){var w=g.doc.getTextRange(y);if(!y.isMultiLine()&&w=="["&&(x(d),g.doc.getLine(y.start.row).substring(y.start.column+1,y.start.column+2)=="]"))return y.end.column++,y}),this.add("string_dquotes","insertion",function(A,v,d,g,y){var w=g.$mode.$quotes||c;if(y.length==1&&w[y]&&(!this.lineCommentStart||this.lineCommentStart.indexOf(y)==-1)){x(d);var I=d.getSelectionRange(),T=g.doc.getTextRange(I);if(!(T===""||T.length==1&&w[T])&&d.getWrapBehavioursEnabled())return p(I,T,y,y);if(!T){var w=d.getCursorPosition(),I=g.doc.getLine(w.row),T=I.substring(w.column-1,w.column),d=I.substring(w.column,w.column+1),_=g.getTokenAt(w.row,w.column),B=g.getTokenAt(w.row,w.column+1);if(T=="\\"&&_&&/escape/.test(_.type))return null;var E,_=_&&/string|escape/.test(_.type),P=!B||/string|escape/.test(B.type);if(d==y)(E=_!==P)&&/string\.end/.test(B.type)&&(E=!1);else{if(_&&!P||_&&P||(B=g.$mode.tokenRe,_=(B.lastIndex=0,B.test(T)),P=(B.lastIndex=0,B.test(T)),_||P)||d&&!/[\s;,.})\]\\]/.test(d)||(g=I[w.column-2],T==y&&(g==y||B.test(g))))return null;E=!0}return{text:E?y+y:"",selection:[1,1]}}}}),this.add("string_dquotes","deletion",function(A,v,d,g,y){var w=g.$mode.$quotes||c,I=g.doc.getTextRange(y);if(!y.isMultiLine()&&w.hasOwnProperty(I)&&(x(d),g.doc.getLine(y.start.row).substring(y.start.column+1,y.start.column+2)==I))return y.end.column++,y})}var s,n=C("../../lib/oop"),t=C("../behaviour").Behaviour,i=C("../../token_iterator").TokenIterator,e=C("../../lib/lang"),r=["text","paren.rparen","rparen","paren","punctuation.operator"],a=["text","paren.rparen","rparen","paren","punctuation.operator","comment"],o={},c={'"':'"',"'":"'"};l.isSaneInsertion=function(h,A){var v=h.getCursorPosition(),d=new i(A,v.row,v.column);if(!this.$matchTokenType(d.getCurrentToken()||"text",r)){if(/[)}\]]/.test(h.session.getLine(v.row)[v.column]))return!0;if(h=new i(A,v.row,v.column+1),!this.$matchTokenType(h.getCurrentToken()||"text",r))return!1}return d.stepForward(),d.getCurrentTokenRow()!==v.row||this.$matchTokenType(d.getCurrentToken()||"text",a)},l.$matchTokenType=function(h,A){return-1<A.indexOf(h.type||h)},l.recordAutoInsert=function(h,A,v){h=h.getCursorPosition(),A=A.doc.getLine(h.row),this.isAutoInsertedClosing(h,A,s.autoInsertedLineEnd[0])||(s.autoInsertedBrackets=0),s.autoInsertedRow=h.row,s.autoInsertedLineEnd=v+A.substr(h.column),s.autoInsertedBrackets++},l.recordMaybeInsert=function(h,A,v){h=h.getCursorPosition(),A=A.doc.getLine(h.row),this.isMaybeInsertedClosing(h,A)||(s.maybeInsertedBrackets=0),s.maybeInsertedRow=h.row,s.maybeInsertedLineStart=A.substr(0,h.column)+v,s.maybeInsertedLineEnd=A.substr(h.column),s.maybeInsertedBrackets++},l.isAutoInsertedClosing=function(h,A,v){return 0<s.autoInsertedBrackets&&h.row===s.autoInsertedRow&&v===s.autoInsertedLineEnd[0]&&A.substr(h.column)===s.autoInsertedLineEnd},l.isMaybeInsertedClosing=function(h,A){return 0<s.maybeInsertedBrackets&&h.row===s.maybeInsertedRow&&A.substr(h.column)===s.maybeInsertedLineEnd&&A.substr(0,h.column)==s.maybeInsertedLineStart},l.popAutoInsertedClosing=function(){s.autoInsertedLineEnd=s.autoInsertedLineEnd.substr(1),s.autoInsertedBrackets--},l.clearMaybeInsertedClosing=function(){s&&(s.maybeInsertedBrackets=0,s.maybeInsertedRow=-1)},n.inherits(l,t),m.CstyleBehaviour=l}),ace.define("ace/unicode",["require","exports","module"],function(C,m,b){for(var x=[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],p=0,l=[],s=0;s<x.length;s+=2)l.push(p+=x[s]),x[s+1]&&l.push(45,p+=x[s+1]);m.wordChars=String.fromCharCode.apply(null,l)}),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(C,m,b){function x(){this.HighlightRules=s}var p=C("../config"),l=C("../tokenizer").Tokenizer,s=C("./text_highlight_rules").TextHighlightRules,n=C("./behaviour/cstyle").CstyleBehaviour,t=C("../unicode"),i=C("../lib/lang"),e=C("../token_iterator").TokenIterator,r=C("../range").Range;(function(){this.$defaultBehaviour=new n,this.tokenRe=new RegExp("^["+t.wordChars+"\\$_]+","g"),this.nonTokenRe=new RegExp("^(?:[^"+t.wordChars+"\\$_]|\\s])+","g"),this.getTokenizer=function(){return this.$tokenizer||(this.$highlightRules=this.$highlightRules||new this.HighlightRules(this.$highlightRuleConfig),this.$tokenizer=new l(this.$highlightRules.getRules())),this.$tokenizer},this.lineCommentStart="",this.blockComment="",this.toggleCommentLines=function(a,o,c,h){var A=o.doc,v=!0,d=!0,g=1/0,y=o.getTabSize(),w=!1;if(this.lineCommentStart){P=Array.isArray(this.lineCommentStart)?(z=this.lineCommentStart.map(i.escapeRegExp).join("|"),this.lineCommentStart[0]):(z=i.escapeRegExp(this.lineCommentStart),this.lineCommentStart),z=new RegExp("^(\\s*)(?:"+z+") ?"),w=o.getUseSoftTabs();var I=function(H,G){var f,S,$=H.match(z);$&&(f=$[1].length,S=$[0].length,_(H,f,S)||$[0][S-1]!=" "||S--,A.removeInLine(G,f,S))},T=P+" ",B=function(H,G){v&&!/\S/.test(H)||(_(H,g,g)?A.insertInLine({row:G,column:g},T):A.insertInLine({row:G,column:g},P))},E=function(H,G){return z.test(H)},_=function(H,G,f){for(var S=0;G--&&H.charAt(G)==" ";)S++;if(S%y!=0)return!1;for(S=0;H.charAt(f++)==" ";)S++;return 2<y?S%y!=y-1:S%y==0}}else{if(!this.blockComment)return!1;var P=this.blockComment.start,j=this.blockComment.end,z=new RegExp("^(\\s*)(?:"+i.escapeRegExp(P)+")"),D=new RegExp("(?:"+i.escapeRegExp(j)+")\\s*$"),B=function(S,$){E(S,$)||v&&!/\S/.test(S)||(A.insertInLine({row:$,column:S.length},j),A.insertInLine({row:$,column:g},P))},I=function(S,$){var M;(M=S.match(D))&&A.removeInLine($,S.length-M[0].length,S.length),(M=S.match(z))&&A.removeInLine($,M[1].length,M[0].length)},E=function(S,$){if(z.test(S))return!0;for(var M=o.getTokens($),K=0;K<M.length;K++)if(M[K].type==="comment")return!0}}function Y(H){for(var G=c;G<=h;G++)H(A.getLine(G),G)}var R=1/0;Y(function(H,G){var f=H.search(/\S/);f!==-1?(f<g&&(g=f),d&&!E(H,G)&&(d=!1)):R>H.length&&(R=H.length)}),g==1/0&&(g=R,d=v=!1),w&&g%y!=0&&(g=Math.floor(g/y)*y),Y(d?I:B)},this.toggleBlockComment=function(a,o,c,h){var A=this.blockComment;if(A){!A.start&&A[0]&&(A=A[0]);var v,d,g=(B=new e(o,h.row,h.column)).getCurrentToken(),y=(o.selection,o.selection.toOrientedRange());if(g&&/comment/.test(g.type)){for(;g&&/comment/.test(g.type);){if((E=g.value.indexOf(A.start))!=-1){var w=B.getCurrentTokenRow(),I=B.getCurrentTokenColumn()+E,T=new r(w,I,w,I+A.start.length);break}g=B.stepBackward()}for(var B,E,g=(B=new e(o,h.row,h.column)).getCurrentToken();g&&/comment/.test(g.type);){if((E=g.value.indexOf(A.end))!=-1){var w=B.getCurrentTokenRow(),I=B.getCurrentTokenColumn()+E,_=new r(w,I,w,I+A.end.length);break}g=B.stepForward()}_&&o.remove(_),T&&(o.remove(T),v=T.start.row,d=-A.start.length)}else d=A.start.length,v=c.start.row,o.insert(c.end,A.end),o.insert(c.start,A.start);y.start.row==v&&(y.start.column+=d),y.end.row==v&&(y.end.column+=d),o.selection.fromOrientedRange(y)}},this.getNextLineIndent=function(a,o,c){return this.$getIndent(o)},this.checkOutdent=function(a,o,c){return!1},this.autoOutdent=function(a,o,c){},this.$getIndent=function(a){return a.match(/^\s*/)[0]},this.createWorker=function(a){return null},this.createModeDelegates=function(a){for(var o in this.$embeds=[],this.$modes={},a){var c,h,A;a[o]&&(h=(c=a[o]).prototype.$id,(A=p.$modes[h])||(p.$modes[h]=A=new c),p.$modes[o]||(p.$modes[o]=A),this.$embeds.push(o),this.$modes[o]=A)}for(var v=["toggleBlockComment","toggleCommentLines","getNextLineIndent","checkOutdent","autoOutdent","transformAction","getCompletions"],o=0;o<v.length;o++)(function(g){var y=v[o],w=g[y];g[v[o]]=function(){return this.$delegator(y,arguments,w)}})(this)},this.$delegator=function(a,o,c){var h=o[0]||"start";if(typeof h!="string"){if(Array.isArray(h[2])){var A=h[2][h[2].length-1];if(d=this.$modes[A])return d[a].apply(d,[h[1]].concat([].slice.call(o,1)))}h=h[0]||"start"}for(var v=0;v<this.$embeds.length;v++)if(this.$modes[this.$embeds[v]]){var d,g=h.split(this.$embeds[v]);if(!g[0]&&g[1])return o[0]=g[1],(d=this.$modes[this.$embeds[v]])[a].apply(d,o)}return A=c.apply(this,o),c?A:void 0},this.transformAction=function(a,o,c,h,A){if(this.$behaviour){var v,d=this.$behaviour.getBehaviours();for(v in d)if(d[v][o]){var g=d[v][o].apply(this,arguments);if(g)return g}}},this.getKeywords=function(a){if(!this.completionKeywords){var o=this.$tokenizer.rules,c=[];for(d in o)for(var h=o[d],A=0,v=h.length;A<v;A++)if(typeof h[A].token=="string")/keyword|support|storage/.test(h[A].token)&&c.push(h[A].regex);else if(typeof h[A].token=="object")for(var d,g=0,y=h[A].token.length;g<y;g++)/keyword|support|storage/.test(h[A].token[g])&&(d=h[A].regex.match(/\(.+?\)/g)[g],c.push(d.substr(1,d.length-2)));this.completionKeywords=c}return a?c.concat(this.$keywordList||[]):this.$keywordList},this.$createKeywordList=function(){return this.$highlightRules||this.getTokenizer(),this.$keywordList=this.$highlightRules.$keywordList||[]},this.getCompletions=function(a,o,c,h){return(this.$keywordList||this.$createKeywordList()).map(function(A){return{name:A,value:A,score:0,meta:"keyword"}})},this.$id="ace/mode/text"}).call(x.prototype),m.Mode=x}),ace.define("ace/apply_delta",["require","exports","module"],function(C,m,b){m.applyDelta=function(x,p,l){var s=p.start.row,n=p.start.column,t=x[s]||"";switch(p.action){case"insert":p.lines.length===1?x[s]=t.substring(0,n)+p.lines[0]+t.substring(n):(i=[s,1].concat(p.lines),x.splice.apply(x,i),x[s]=t.substring(0,n)+x[s],x[s+p.lines.length-1]+=t.substring(n));break;case"remove":var i=p.end.column,e=p.end.row;s===e?x[s]=t.substring(0,n)+t.substring(i):x.splice(s,e-s+1,t.substring(0,n)+x[e].substring(i))}}}),ace.define("ace/anchor",["require","exports","module","ace/lib/oop","ace/lib/event_emitter"],function(l,m,b){var x=l("./lib/oop"),p=l("./lib/event_emitter").EventEmitter,l=m.Anchor=function(s,n,t){this.$onChange=this.onChange.bind(this),this.attach(s),t===void 0?this.setPosition(n.row,n.column):this.setPosition(n,t)};(function(){function s(n,t,i){return i=i?n.column<=t.column:n.column<t.column,n.row<t.row||n.row==t.row&&i}x.implement(this,p),this.getPosition=function(){return this.$clipPositionToDocument(this.row,this.column)},this.getDocument=function(){return this.document},this.$insertRight=!1,this.onChange=function(n){n.start.row==n.end.row&&n.start.row!=this.row||n.start.row>this.row||(n=function(t,i,e){var c=t.action=="insert",r=(c?1:-1)*(t.end.row-t.start.row),a=(c?1:-1)*(t.end.column-t.start.column),o=t.start,c=c?o:t.end;return s(i,o,e)?{row:i.row,column:i.column}:s(c,i,!e)?{row:i.row+r,column:i.column+(i.row==c.row?a:0)}:{row:o.row,column:o.column}}(n,{row:this.row,column:this.column},this.$insertRight),this.setPosition(n.row,n.column,!0))},this.setPosition=function(n,t,i){i=i?{row:n,column:t}:this.$clipPositionToDocument(n,t),this.row==i.row&&this.column==i.column||(n={row:this.row,column:this.column},this.row=i.row,this.column=i.column,this._signal("change",{old:n,value:i}))},this.detach=function(){this.document.off("change",this.$onChange)},this.attach=function(n){this.document=n||this.document,this.document.on("change",this.$onChange)},this.$clipPositionToDocument=function(n,t){var i={};return n>=this.document.getLength()?(i.row=Math.max(0,this.document.getLength()-1),i.column=this.document.getLine(i.row).length):n<0?(i.row=0,i.column=0):(i.row=n,i.column=Math.min(this.document.getLine(i.row).length,Math.max(0,t))),t<0&&(i.column=0),i}}).call(l.prototype)}),ace.define("ace/document",["require","exports","module","ace/lib/oop","ace/apply_delta","ace/lib/event_emitter","ace/range","ace/anchor"],function(C,m,b){function x(i){this.$lines=[""],i.length===0?this.$lines=[""]:Array.isArray(i)?this.insertMergedLines({row:0,column:0},i):this.insert({row:0,column:0},i)}var p=C("./lib/oop"),l=C("./apply_delta").applyDelta,s=C("./lib/event_emitter").EventEmitter,n=C("./range").Range,t=C("./anchor").Anchor;(function(){p.implement(this,s),this.setValue=function(i){var e=this.getLength()-1;this.remove(new n(0,0,e,this.getLine(e).length)),this.insert({row:0,column:0},i)},this.getValue=function(){return this.getAllLines().join(this.getNewLineCharacter())},this.createAnchor=function(i,e){return new t(this,i,e)},"aaa".split(/a/).length===0?this.$split=function(i){return i.replace(/\r\n|\r/g,`
`).split(`
`)}:this.$split=function(i){return i.split(/\r\n|\r|\n/)},this.$detectNewLine=function(i){i=i.match(/^.*?(\r\n|\r|\n)/m),this.$autoNewLine=i?i[1]:`
`,this._signal("changeNewLineMode")},this.getNewLineCharacter=function(){switch(this.$newLineMode){case"windows":return`\r
`;case"unix":return`
`;default:return this.$autoNewLine||`
`}},this.$autoNewLine="",this.$newLineMode="auto",this.setNewLineMode=function(i){this.$newLineMode!==i&&(this.$newLineMode=i,this._signal("changeNewLineMode"))},this.getNewLineMode=function(){return this.$newLineMode},this.isNewLine=function(i){return i==`\r
`||i=="\r"||i==`
`},this.getLine=function(i){return this.$lines[i]||""},this.getLines=function(i,e){return this.$lines.slice(i,e+1)},this.getAllLines=function(){return this.getLines(0,this.getLength())},this.getLength=function(){return this.$lines.length},this.getTextRange=function(i){return this.getLinesForRange(i).join(this.getNewLineCharacter())},this.getLinesForRange=function(i){var e,r;return i.start.row===i.end.row?e=[this.getLine(i.start.row).substring(i.start.column,i.end.column)]:((e=this.getLines(i.start.row,i.end.row))[0]=(e[0]||"").substring(i.start.column),r=e.length-1,i.end.row-i.start.row==r&&(e[r]=e[r].substring(0,i.end.column))),e},this.insertLines=function(i,e){return console.warn("Use of document.insertLines is deprecated. Use the insertFullLines method instead."),this.insertFullLines(i,e)},this.removeLines=function(i,e){return console.warn("Use of document.removeLines is deprecated. Use the removeFullLines method instead."),this.removeFullLines(i,e)},this.insertNewLine=function(i){return console.warn("Use of document.insertNewLine is deprecated. Use insertMergedLines(position, ['', '']) instead."),this.insertMergedLines(i,["",""])},this.insert=function(i,e){return this.getLength()<=1&&this.$detectNewLine(e),this.insertMergedLines(i,this.$split(e))},this.insertInLine=function(a,e){var r=this.clippedPos(a.row,a.column),a=this.pos(a.row,a.column+e.length);return this.applyDelta({start:r,end:a,action:"insert",lines:[e]},!0),this.clonePos(a)},this.clippedPos=function(i,e){var r=this.getLength(),r=(i===void 0?i=r:i<0?i=0:r<=i&&(i=r-1,e=void 0),this.getLine(i));return e==null&&(e=r.length),{row:i,column:e=Math.min(Math.max(e,0),r.length)}},this.clonePos=function(i){return{row:i.row,column:i.column}},this.pos=function(i,e){return{row:i,column:e}},this.$clipPosition=function(i){var e=this.getLength();return i.row>=e?(i.row=Math.max(0,e-1),i.column=this.getLine(e-1).length):(i.row=Math.max(0,i.row),i.column=Math.min(Math.max(i.column,0),this.getLine(i.row).length)),i},this.insertFullLines=function(i,e){var r=0,r=(i=Math.min(Math.max(i,0),this.getLength()))<this.getLength()?(e=e.concat([""]),0):(e=[""].concat(e),this.$lines[--i].length);this.insertMergedLines({row:i,column:r},e)},this.insertMergedLines=function(r,e){var r=this.clippedPos(r.row,r.column),a={row:r.row+e.length-1,column:(e.length==1?r.column:0)+e[e.length-1].length};return this.applyDelta({start:r,end:a,action:"insert",lines:e}),this.clonePos(a)},this.remove=function(r){var e=this.clippedPos(r.start.row,r.start.column),r=this.clippedPos(r.end.row,r.end.column);return this.applyDelta({start:e,end:r,action:"remove",lines:this.getLinesForRange({start:e,end:r})}),this.clonePos(e)},this.removeInLine=function(i,e,r){return e=this.clippedPos(i,e),i=this.clippedPos(i,r),this.applyDelta({start:e,end:i,action:"remove",lines:this.getLinesForRange({start:e,end:i})},!0),this.clonePos(e)},this.removeFullLines=function(i,e){i=Math.min(Math.max(0,i),this.getLength()-1);var c=(e=Math.min(Math.max(0,e),this.getLength()-1))==this.getLength()-1&&0<i,a=e<this.getLength()-1,o=c?i-1:i,c=c?this.getLine(o).length:0,r=a?e+1:e,a=a?0:this.getLine(r).length,o=new n(o,c,r,a),c=this.$lines.slice(i,e+1);return this.applyDelta({start:o.start,end:o.end,action:"remove",lines:this.getLinesForRange(o)}),c},this.removeNewLine=function(i){i<this.getLength()-1&&0<=i&&this.applyDelta({start:this.pos(i,this.getLine(i).length),end:this.pos(i+1,0),action:"remove",lines:["",""]})},this.replace=function(i,e){return i instanceof n||(i=n.fromPoints(i.start,i.end)),e.length===0&&i.isEmpty()?i.start:e==this.getTextRange(i)?i.end:(this.remove(i),e?this.insert(i.start,e):i.start)},this.applyDeltas=function(i){for(var e=0;e<i.length;e++)this.applyDelta(i[e])},this.revertDeltas=function(i){for(var e=i.length-1;0<=e;e--)this.revertDelta(i[e])},this.applyDelta=function(i,e){var r=i.action=="insert";(r?i.lines.length<=1&&!i.lines[0]:!n.comparePoints(i.start,i.end))||(r&&2e4<i.lines.length?this.$splitAndapplyLargeDelta(i,2e4):(l(this.$lines,i,e),this._signal("change",i)))},this.$safeApplyDelta=function(i){var e=this.$lines.length;(i.action=="remove"&&i.start.row<e&&i.end.row<e||i.action=="insert"&&i.start.row<=e)&&this.applyDelta(i)},this.$splitAndapplyLargeDelta=function(i,e){for(var r=i.lines,a=r.length-e+1,o=i.start.row,c=i.start.column,h=0,A=0;h<a;h=A){A+=e-1;var v=r.slice(h,A);v.push(""),this.applyDelta({start:this.pos(o+h,c),end:this.pos(o+A,c=0),action:i.action,lines:v},!0)}i.lines=r.slice(h),i.start.row=o+h,i.start.column=c,this.applyDelta(i,!0)},this.revertDelta=function(i){this.$safeApplyDelta({start:this.clonePos(i.start),end:this.clonePos(i.end),action:i.action=="insert"?"remove":"insert",lines:i.lines.slice()})},this.indexToPosition=function(i,e){for(var r=this.$lines||this.getAllLines(),a=this.getNewLineCharacter().length,o=e||0,c=r.length;o<c;o++)if((i-=r[o].length+a)<0)return{row:o,column:i+r[o].length+a};return{row:c-1,column:i+r[c-1].length+a}},this.positionToIndex=function(i,e){for(var r=this.$lines||this.getAllLines(),a=this.getNewLineCharacter().length,o=0,c=Math.min(i.row,r.length),h=e||0;h<c;++h)o+=r[h].length+a;return o+i.column}}).call(x.prototype),m.Document=x}),ace.define("ace/background_tokenizer",["require","exports","module","ace/lib/oop","ace/lib/event_emitter"],function(C,m,b){function x(s,n){this.running=!1,this.lines=[],this.states=[],this.currentLine=0,this.tokenizer=s;var t=this;this.$worker=function(){if(t.running){for(var i=new Date,e=t.currentLine,r=-1,a=t.doc,o=e;t.lines[e];)e++;var c=a.getLength(),h=0;for(t.running=!1;e<c;){for(t.$tokenizeRow(e),r=e;e++,t.lines[e];);if(++h%5==0&&20<new Date-i){t.running=setTimeout(t.$worker,20);break}}t.currentLine=e,o<=(r=r==-1?e:r)&&t.fireUpdateEvent(o,r)}}}var p=C("./lib/oop"),l=C("./lib/event_emitter").EventEmitter;(function(){p.implement(this,l),this.setTokenizer=function(s){this.tokenizer=s,this.lines=[],this.states=[],this.start(0)},this.setDocument=function(s){this.doc=s,this.lines=[],this.states=[],this.stop()},this.fireUpdateEvent=function(s,n){this._signal("update",{data:{first:s,last:n}})},this.start=function(s){this.currentLine=Math.min(s||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)},this.scheduleStart=function(){this.running||(this.running=setTimeout(this.$worker,700))},this.$updateOnChange=function(s){var n=s.start.row,t=s.end.row-n;t==0?this.lines[n]=null:s.action=="remove"?(this.lines.splice(n,1+t,null),this.states.splice(n,1+t,null)):((s=Array(1+t)).unshift(n,1),this.lines.splice.apply(this.lines,s),this.states.splice.apply(this.states,s)),this.currentLine=Math.min(n,this.currentLine,this.doc.getLength()),this.stop()},this.stop=function(){this.running&&clearTimeout(this.running),this.running=!1},this.getTokens=function(s){return this.lines[s]||this.$tokenizeRow(s)},this.getState=function(s){return this.currentLine==s&&this.$tokenizeRow(s),this.states[s]||"start"},this.$tokenizeRow=function(s){var t=this.doc.getLine(s),n=this.states[s-1],t=this.tokenizer.getLineTokens(t,n,s);return this.states[s]+""!=t.state+""?(this.states[s]=t.state,this.lines[s+1]=null,this.currentLine>s+1&&(this.currentLine=s+1)):this.currentLine==s&&(this.currentLine=s+1),this.lines[s]=t.tokens},this.cleanup=function(){this.running=!1,this.lines=[],this.states=[],this.currentLine=0,this.removeAllListeners()}}).call(x.prototype),m.BackgroundTokenizer=x}),ace.define("ace/search_highlight",["require","exports","module","ace/lib/lang","ace/lib/oop","ace/range"],function(C,m,b){function x(s,n,t){this.setRegexp(s),this.clazz=n,this.type=t||"text"}var p=C("./lib/lang"),l=(C("./lib/oop"),C("./range").Range);(function(){this.MAX_RANGES=500,this.setRegexp=function(s){this.regExp+""!=s+""&&(this.regExp=s,this.cache=[])},this.update=function(s,n,t,i){if(this.regExp)for(var e=i.firstRow,r=i.lastRow,a={},o=e;o<=r;o++){var c=this.cache[o];c==null&&(c=(c=(c=p.getMatchOffsets(t.getLine(o),this.regExp)).length>this.MAX_RANGES?c.slice(0,this.MAX_RANGES):c).map(function(d){return new l(o,d.offset,o,d.offset+d.length)}),this.cache[o]=c.length?c:"");for(var h=c.length;h--;){var A=c[h].toScreenRange(t),v=A.toString();a[v]||(a[v]=!0,n.drawSingleLineMarker(s,A,this.clazz,i))}}}}).call(x.prototype),m.SearchHighlight=x}),ace.define("ace/edit_session/fold_line",["require","exports","module","ace/range"],function(C,m,b){var x=C("../range").Range;function p(l,s){this.foldData=l,Array.isArray(s)?this.folds=s:s=this.folds=[s],l=s[s.length-1],this.range=new x(s[0].start.row,s[0].start.column,l.end.row,l.end.column),this.start=this.range.start,this.end=this.range.end,this.folds.forEach(function(n){n.setFoldLine(this)},this)}(function(){this.shiftRow=function(l){this.start.row+=l,this.end.row+=l,this.folds.forEach(function(s){s.start.row+=l,s.end.row+=l})},this.addFold=function(l){if(l.sameRow){if(l.start.row<this.startRow||l.endRow>this.endRow)throw new Error("Can't add a fold to this FoldLine as it has no connection");this.folds.push(l),this.folds.sort(function(s,n){return-s.range.compareEnd(n.start.row,n.start.column)}),0<this.range.compareEnd(l.start.row,l.start.column)?(this.end.row=l.end.row,this.end.column=l.end.column):this.range.compareStart(l.end.row,l.end.column)<0&&(this.start.row=l.start.row,this.start.column=l.start.column)}else if(l.start.row==this.end.row)this.folds.push(l),this.end.row=l.end.row,this.end.column=l.end.column;else{if(l.end.row!=this.start.row)throw new Error("Trying to add fold to FoldRow that doesn't have a matching row");this.folds.unshift(l),this.start.row=l.start.row,this.start.column=l.start.column}l.foldLine=this},this.containsRow=function(l){return l>=this.start.row&&l<=this.end.row},this.walk=function(l,s,n){var t,i,e=0,r=this.folds,a=!0;s==null&&(s=this.end.row,n=this.end.column);for(var o=0;o<r.length;o++){if((i=(t=r[o]).range.compareStart(s,n))==-1)return void l(null,s,n,e,a);if(!l(null,t.start.row,t.start.column,e,a)&&l(t.placeholder,t.start.row,t.start.column,e)||i===0)return;a=!t.sameRow,e=t.end.column}l(null,s,n,e,a)},this.getNextFoldTo=function(l,s){for(var n,t,i=0;i<this.folds.length;i++){if((t=(n=this.folds[i]).range.compareEnd(l,s))==-1)return{fold:n,kind:"after"};if(t===0)return{fold:n,kind:"inside"}}return null},this.addRemoveChars=function(l,s,n){var t,i=this.getNextFoldTo(l,s);if(i){if(t=i.fold,i.kind=="inside"&&t.start.column!=s&&t.start.row!=l)window.console&&window.console.log(l,s,t);else if(t.start.row==l){var e,r=(e=this.folds).indexOf(t);for(r===0&&(this.start.column+=n);r<e.length;r++){if((t=e[r]).start.column+=n,!t.sameRow)return;t.end.column+=n}this.end.column+=n}}},this.split=function(i,s){var n,t,i=this.getNextFoldTo(i,s);return i&&i.kind!="inside"?(s=i.fold,i=this.folds,n=this.foldData,s=i.indexOf(s),t=i[s-1],this.end.row=t.end.row,this.end.column=t.end.column,t=new p(n,i=i.splice(s,i.length-s)),n.splice(n.indexOf(this)+1,0,t),t):null},this.merge=function(l){for(var s=l.folds,n=0;n<s.length;n++)this.addFold(s[n]);var t=this.foldData;t.splice(t.indexOf(l),1)},this.toString=function(){var l=[this.range.toString()+": ["];return this.folds.forEach(function(s){l.push("  "+s.toString())}),l.push("]"),l.join(`
`)},this.idxToPosition=function(l){for(var s=0,n=0;n<this.folds.length;n++){var t=this.folds[n];if((l-=t.start.column-s)<0)return{row:t.start.row,column:t.start.column+l};if((l-=t.placeholder.length)<0)return t.start;s=t.end.column}return{row:this.end.row,column:this.end.column+l}}}).call(p.prototype),m.FoldLine=p}),ace.define("ace/range_list",["require","exports","module","ace/range"],function(C,m,b){function x(){this.ranges=[],this.$bias=1}var p=C("./range").Range.comparePoints;(function(){this.comparePoints=p,this.pointIndex=function(l,s,n){for(var t=this.ranges,i=n||0;i<t.length;i++){var e=t[i],r=p(l,e.end);if(!(0<r))return e=p(l,e.start),r===0?s&&e!==0?-i-2:i:0<e||e===0&&!s?i:-i-1}return-i-1},this.add=function(l){var n=!l.isEmpty(),s=this.pointIndex(l.start,n),n=this.pointIndex(l.end,n,s=s<0?-s-1:s);return n<0?n=-n-1:n++,this.ranges.splice(s,n-s,l)},this.addList=function(l){for(var s=[],n=l.length;n--;)s.push.apply(s,this.add(l[n]));return s},this.substractPoint=function(l){if(l=this.pointIndex(l),0<=l)return this.ranges.splice(l,1)},this.merge=function(){for(var l=[],s=this.ranges,n=(s=s.sort(function(r,a){return p(r.start,a.start)}))[0],t=1;t<s.length;t++){var i=n,n=s[t],e=p(i.end,n.start);e<0||(e!=0||i.isEmpty()||n.isEmpty())&&(p(i.end,n.end)<0&&(i.end.row=n.end.row,i.end.column=n.end.column),s.splice(t,1),l.push(n),n=i,t--)}return this.ranges=s,l},this.contains=function(l,s){return 0<=this.pointIndex({row:l,column:s})},this.containsPoint=function(l){return 0<=this.pointIndex(l)},this.rangeAtPoint=function(l){if(l=this.pointIndex(l),0<=l)return this.ranges[l]},this.clipRows=function(l,s){var n=this.ranges;if(n[0].start.row>s||n[n.length-1].start.row<l)return[];for(var l=this.pointIndex({row:l,column:0}),t=this.pointIndex({row:s,column:0},l=l<0?-l-1:l),i=(t<0&&(t=-t-1),[]),e=l;e<t;e++)i.push(n[e]);return i},this.removeAll=function(){return this.ranges.splice(0,this.ranges.length)},this.attach=function(l){this.session&&this.detach(),this.session=l,this.onChange=this.$onChange.bind(this),this.session.on("change",this.onChange)},this.detach=function(){this.session&&(this.session.removeListener("change",this.onChange),this.session=null)},this.$onChange=function(l){for(var s=l.start,n=l.end,t=s.row,i=n.row,e=this.ranges,r=0,a=e.length;r<a&&!((h=e[r]).end.row>=t);r++);if(l.action=="insert")for(var o=i-t,c=-s.column+n.column;r<a&&!((h=e[r]).start.row>t);r++)h.start.row==t&&h.start.column>=s.column&&(h.start.column==s.column&&this.$bias<=0||(h.start.column+=c,h.start.row+=o)),h.end.row==t&&h.end.column>=s.column&&(h.end.column==s.column&&this.$bias<0||(h.end.column==s.column&&0<c&&r<a-1&&h.end.column>h.start.column&&h.end.column==e[r+1].start.column&&(h.end.column-=c),h.end.column+=c,h.end.row+=o));else for(var h,o=t-i,c=s.column-n.column;r<a&&!((h=e[r]).start.row>i);r++)h.end.row<i&&(t<h.end.row||t==h.end.row&&s.column<h.end.column)?(h.end.row=t,h.end.column=s.column):h.end.row==i?h.end.column<=n.column?(o||h.end.column>s.column)&&(h.end.column=s.column,h.end.row=s.row):(h.end.column+=c,h.end.row+=o):h.end.row>i&&(h.end.row+=o),h.start.row<i&&(t<h.start.row||t==h.start.row&&s.column<h.start.column)?(h.start.row=t,h.start.column=s.column):h.start.row==i?h.start.column<=n.column?(o||h.start.column>s.column)&&(h.start.column=s.column,h.start.row=s.row):(h.start.column+=c,h.start.row+=o):h.start.row>i&&(h.start.row+=o);if(o!=0&&r<a)for(;r<a;r++)(h=e[r]).start.row+=o,h.end.row+=o}}).call(x.prototype),m.RangeList=x}),ace.define("ace/edit_session/fold",["require","exports","module","ace/range_list","ace/lib/oop"],function(p,m,b){var x=p("../range_list").RangeList,p=p("../lib/oop"),l=m.Fold=function(t,i){this.foldLine=null,this.placeholder=i,this.range=t,this.start=t.start,this.end=t.end,this.sameRow=t.start.row==t.end.row,this.subFolds=this.ranges=[]};function s(t,i){t.row-=i.row,t.row==0&&(t.column-=i.column)}function n(t,i){t.row==0&&(t.column+=i.column),t.row+=i.row}p.inherits(l,x),function(){this.toString=function(){return'"'+this.placeholder+'" '+this.range.toString()},this.setFoldLine=function(t){this.foldLine=t,this.subFolds.forEach(function(i){i.setFoldLine(t)})},this.clone=function(){var t=this.range.clone(),i=new l(t,this.placeholder);return this.subFolds.forEach(function(e){i.subFolds.push(e.clone())}),i.collapseChildren=this.collapseChildren,i},this.addSubFold=function(t){if(!this.range.isEqual(t)){o=t,c=this.start,s(o.start,c),s(o.end,c);for(var i=t.start.row,e=t.start.column,r=0,a=-1;r<this.subFolds.length&&(a=this.subFolds[r].range.compare(i,e))==1;r++);var o=this.subFolds[r],c=0;if(a==0){if(o.range.containsRange(t))return o.addSubFold(t);c=1}for(var i=t.range.end.row,e=t.range.end.column,h=r,a=-1;h<this.subFolds.length&&(a=this.subFolds[h].range.compare(i,e))==1;h++);a==0&&h++;for(var A=this.subFolds.splice(r,h-r,t),v=a==0?A.length-1:A.length,d=c;d<v;d++)t.addSubFold(A[d]);return t.setFoldLine(this.foldLine),t}},this.restoreRange=function(t){return t=t,i=this.start,n(t.start,i),void n(t.end,i);var i}}.call(l.prototype)}),ace.define("ace/edit_session/folding",["require","exports","module","ace/range","ace/edit_session/fold_line","ace/edit_session/fold","ace/token_iterator"],function(C,m,b){var x=C("../range").Range,p=C("./fold_line").FoldLine,l=C("./fold").Fold,s=C("../token_iterator").TokenIterator;m.Folding=function(){this.getFoldAt=function(n,t,i){var e=this.getFoldLine(n);if(!e)return null;for(var r=e.folds,a=0;a<r.length;a++){var o=r[a].range;if(o.contains(n,t)&&(i!=1||!o.isEnd(n,t)||o.isEmpty())&&(i!=-1||!o.isStart(n,t)||o.isEmpty()))return r[a]}},this.getFoldsInRange=function(n){var t=n.start,i=n.end,e=this.$foldData,r=[];t.column+=1,--i.column;for(var a=0;a<e.length;a++){var o=e[a].range.compareRange(n);if(o!=2){if(o==-2)break;for(var c=e[a].folds,h=0;h<c.length;h++){var A=c[h];if((o=A.range.compareRange(n))==-2)break;if(o!=2){if(o==42)break;r.push(A)}}}}return--t.column,i.column+=1,r},this.getFoldsInRangeList=function(n){var t;return Array.isArray(n)?(t=[],n.forEach(function(i){t=t.concat(this.getFoldsInRange(i))},this)):t=this.getFoldsInRange(n),t},this.getAllFolds=function(){for(var n=[],t=this.$foldData,i=0;i<t.length;i++)for(var e=0;e<t[i].folds.length;e++)n.push(t[i].folds[e]);return n},this.getFoldStringAt=function(n,t,i,e){if(!(e=e||this.getFoldLine(n)))return null;for(var r,a={end:{column:0}},o=0;o<e.folds.length;o++){var c,h=(c=e.folds[o]).range.compareEnd(n,t);if(h==-1){r=this.getLine(c.start.row).substring(a.end.column,c.start.column);break}if(h===0)return null;a=c}return r=r||this.getLine(c.start.row).substring(a.end.column),i==-1?r.substring(0,t-a.end.column):i==1?r.substring(t-a.end.column):r},this.getFoldLine=function(n,t){var i=this.$foldData,e=0;for((e=t?i.indexOf(t):e)==-1&&(e=0);e<i.length;e++){var r=i[e];if(r.start.row<=n&&r.end.row>=n)return r;if(r.end.row>n)return null}return null},this.getNextFoldLine=function(n,t){var i=this.$foldData,e=0;for((e=t?i.indexOf(t):e)==-1&&(e=0);e<i.length;e++){var r=i[e];if(r.end.row>=n)return r}return null},this.getFoldedRowCount=function(n,t){for(var i=this.$foldData,e=t-n+1,r=0;r<i.length;r++){var o=i[r],a=o.end.row,o=o.start.row;if(t<=a){o<t&&(n<=o?e-=t-o:e=0);break}n<=a&&(e-=n<=o?a-o:a-n+1)}return e},this.$addFoldLine=function(n){return this.$foldData.push(n),this.$foldData.sort(function(t,i){return t.start.row-i.start.row}),n},this.addFold=function(o,h){var i,e=this.$foldData,r=!1,a=(o instanceof l?i=o:(i=new l(h,o)).collapseChildren=h.collapseChildren,this.$clipRangeToDocument(i.range),i.start.row),o=i.start.column,c=i.end.row,h=i.end.column,A=this.getFoldAt(a,o,1),v=this.getFoldAt(c,h,-1);if(A&&v==A)return A.addSubFold(i);A&&!A.range.isStart(a,o)&&this.removeFold(A),v&&!v.range.isEnd(c,h)&&this.removeFold(v),o=this.getFoldsInRange(i.range),0<o.length&&(this.removeFolds(o),i.collapseChildren||o.forEach(function(w){i.addSubFold(w)}));for(var d=0;d<e.length;d++){var g=e[d];if(c==g.start.row){g.addFold(i),r=!0;break}if(a==g.end.row){if(g.addFold(i),r=!0,!i.sameRow){var y=e[d+1];if(y&&y.start.row==c){g.merge(y);break}}break}if(c<=g.start.row)break}return r||(g=this.$addFoldLine(new p(this.$foldData,i))),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:i,action:"add"}),i},this.addFolds=function(n){n.forEach(function(t){this.addFold(t)},this)},this.removeFold=function(n){var t=n.foldLine,i=t.start.row,e=t.end.row,r=this.$foldData,a=t.folds;a.length==1?r.splice(r.indexOf(t),1):t.range.isEnd(n.end.row,n.end.column)?(a.pop(),t.end.row=a[a.length-1].end.row,t.end.column=a[a.length-1].end.column):t.range.isStart(n.start.row,n.start.column)?(a.shift(),t.start.row=a[0].start.row,t.start.column=a[0].start.column):n.sameRow?a.splice(a.indexOf(n),1):((a=(r=t.split(n.start.row,n.start.column)).folds).shift(),r.start.row=a[0].start.row,r.start.column=a[0].start.column),this.$updating||(this.$useWrapMode?this.$updateWrapData(i,e):this.$updateRowLengthCache(i,e)),this.$modified=!0,this._signal("changeFold",{data:n,action:"remove"})},this.removeFolds=function(n){for(var t=[],i=0;i<n.length;i++)t.push(n[i]);t.forEach(function(e){this.removeFold(e)},this),this.$modified=!0},this.expandFold=function(n){this.removeFold(n),n.subFolds.forEach(function(t){n.restoreRange(t),this.addFold(t)},this),0<n.collapseChildren&&this.foldAll(n.start.row+1,n.end.row,n.collapseChildren-1),n.subFolds=[]},this.expandFolds=function(n){n.forEach(function(t){this.expandFold(t)},this)},this.unfold=function(n,t){var i;if(n==null)i=new x(0,0,this.getLength(),0),t==null&&(t=!0);else if(typeof n=="number")i=new x(n,0,n,this.getLine(n).length);else if("row"in n)i=x.fromPoints(n,n);else{if(Array.isArray(n))return e=[],n.forEach(function(r){e=e.concat(this.unfold(r))},this),e;i=n}for(var e,n=e=this.getFoldsInRangeList(i);e.length==1&&x.comparePoints(e[0].start,i.start)<0&&0<x.comparePoints(e[0].end,i.end);)this.expandFolds(e),e=this.getFoldsInRangeList(i);if(t!=0?this.removeFolds(e):this.expandFolds(e),n.length)return n},this.isRowFolded=function(n,t){return!!this.getFoldLine(n,t)},this.getRowFoldEnd=function(n,t){return t=this.getFoldLine(n,t),t?t.end.row:n},this.getRowFoldStart=function(n,t){return t=this.getFoldLine(n,t),t?t.start.row:n},this.getFoldDisplayLine=function(n,t,i,e,r){e==null&&(e=n.start.row),r==null&&(r=0),t==null&&(t=n.end.row),i==null&&(i=this.getLine(t).length);var a=this.doc,o="";return n.walk(function(c,h,A,v){if(!(h<e)){if(h==e){if(A<r)return;v=Math.max(r,v)}o+=c!=null?c:a.getLine(h).substring(v,A)}},t,i),o},this.getDisplayLine=function(n,t,i,e){var r=this.getFoldLine(n);return r?this.getFoldDisplayLine(r,n,t,i,e):(r=this.doc.getLine(n)).substring(e||0,t||r.length)},this.$cloneFoldData=function(){var n=[];return n=this.$foldData.map(function(t){return t=t.folds.map(function(i){return i.clone()}),new p(n,t)})},this.toggleFold=function(n){var t=this.selection.getRange();if(t.isEmpty()){var i,e=t.start;if(i=this.getFoldAt(e.row,e.column))return void this.expandFold(i);(r=this.findMatchingBracket(e))?t.comparePoint(r)==1?t.end=r:(t.start=r,t.start.column++,t.end.column--):(r=this.findMatchingBracket({row:e.row,column:e.column+1}))?(t.comparePoint(r)==1?t.end=r:t.start=r,t.start.column++):t=this.getCommentFoldRange(e.row,e.column)||t}else{var r=this.getFoldsInRange(t);if(n&&r.length)return void this.expandFolds(r);r.length==1&&(i=r[0])}if((i=i||this.getFoldAt(t.start.row,t.start.column))&&i.range.toString()==t.toString())this.expandFold(i);else{if(e="...",!t.isMultiLine()){if((e=this.getTextRange(t)).length<4)return;e=e.trim().substring(0,2)+".."}this.addFold(e,t)}},this.getCommentFoldRange=function(n,t,i){var e=new s(this,n,t),r=e.getCurrentToken(),a=r&&r.type;if(r&&/^comment|string/.test(a)){(a=a.match(/comment|string/)[0])=="comment"&&(a+="|doc-start");var o=new RegExp(a),a=new x;if(i!=1){for(;(r=e.stepBackward())&&o.test(r.type););e.stepForward()}if(a.start.row=e.getCurrentTokenRow(),a.start.column=e.getCurrentTokenColumn()+2,e=new s(this,n,t),i!=-1){var c=-1;do if(r=e.stepForward(),c==-1){var h=this.getState(e.$row);o.test(h)||(c=e.$row)}else if(e.$row>c)break;while(r&&o.test(r.type));r=e.stepBackward()}else r=e.getCurrentToken();return a.end.row=e.getCurrentTokenRow(),a.end.column=e.getCurrentTokenColumn()+r.value.length-2,a}},this.foldAll=function(n,t,i,e){i==null&&(i=1e5);var r=this.foldWidgets;if(r){t=t||this.getLength();for(var a,o=n=n||0;o<t;o++)r[o]==null&&(r[o]=this.getFoldWidget(o)),r[o]!="start"||e&&!e(o)||(a=this.getFoldWidgetRange(o))&&a.isMultiLine()&&a.end.row<=t&&a.start.row>=n&&(o=a.end.row,a.collapseChildren=i,this.addFold("...",a))}},this.foldToLevel=function(n){for(this.foldAll();0<n--;)this.unfold(null,!1)},this.foldAllComments=function(){var n=this;this.foldAll(null,null,null,function(t){for(var i=n.getTokens(t),e=0;e<i.length;e++){var r=i[e];if(r.type!="text"||!/^\s+$/.test(r.value))return!!/comment/.test(r.type)}})},this.$foldStyles={manual:1,markbegin:1,markbeginend:1},this.$foldStyle="markbegin",this.setFoldStyle=function(n){if(!this.$foldStyles[n])throw new Error("invalid fold style: "+n+"["+Object.keys(this.$foldStyles).join(", ")+"]");this.$foldStyle!=n&&((this.$foldStyle=n)=="manual"&&this.unfold(),n=this.$foldMode,this.$setFolding(null),this.$setFolding(n))},this.$setFolding=function(n){this.$foldMode!=n&&(this.$foldMode=n,this.off("change",this.$updateFoldWidgets),this.off("tokenizerUpdate",this.$tokenizerUpdateFoldWidgets),this._signal("changeAnnotation"),n&&this.$foldStyle!="manual"?(this.foldWidgets=[],this.getFoldWidget=n.getFoldWidget.bind(n,this,this.$foldStyle),this.getFoldWidgetRange=n.getFoldWidgetRange.bind(n,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(n,t){var i=this.foldWidgets;if(!i||t&&i[n])return{};for(var e=n-1;0<=e;){var r=i[e];if((r=r==null?i[e]=this.getFoldWidget(e):r)=="start"){var a=this.getFoldWidgetRange(e),o=o||a;if(a&&a.end.row>=n)break}e--}return{range:e!==-1&&a,firstRange:o}},this.onFoldWidgetClick=function(n,t){var i={children:(t=t.domEvent).shiftKey,all:t.ctrlKey||t.metaKey,siblings:t.altKey};this.$toggleFoldWidget(n,i)||(n=t.target||t.srcElement)&&/ace_fold-widget/.test(n.className)&&(n.className+=" ace_invalid")},this.$toggleFoldWidget=function(n,t){var i,e,r,a;if(this.getFoldWidget)return i=this.getFoldWidget(n),e=this.getLine(n),(e=this.getFoldAt(n,(i=i==="end"?-1:1)==-1?0:e.length,i))?(t.children||t.all?this.removeFold(e):this.expandFold(e),e):(i=this.getFoldWidgetRange(n,!0))&&!i.isMultiLine()&&(e=this.getFoldAt(i.start.row,i.start.column,1))&&i.isEqual(e.range)?(this.removeFold(e),e):(t.siblings?((e=this.getParentFoldRangeData(n)).range&&(r=e.range.start.row+1,a=e.range.end.row),this.foldAll(r,a,t.all?1e4:0)):t.children?(a=i?i.end.row:this.getLength(),this.foldAll(n+1,a,t.all?1e4:0)):i&&(t.all&&(i.collapseChildren=1e4),this.addFold("...",i)),i)},this.toggleFoldWidget=function(n){var t,i=this.selection.getCursor().row;i=this.getRowFoldStart(i),this.$toggleFoldWidget(i,{})||(t=(t=this.getParentFoldRangeData(i,!0)).range||t.firstRange)&&(i=t.start.row,(i=this.getFoldAt(i,this.getLine(i).length,1))?this.removeFold(i):this.addFold("...",t))},this.updateFoldWidgets=function(n){var t=n.start.row,i=n.end.row-t;i==0?this.foldWidgets[t]=null:n.action=="remove"?this.foldWidgets.splice(t,1+i,null):((n=Array(1+i)).unshift(t,1),this.foldWidgets.splice.apply(this.foldWidgets,n))},this.tokenizerUpdateFoldWidgets=function(n){n=n.data,n.first!=n.last&&this.foldWidgets.length>n.first&&this.foldWidgets.splice(n.first,this.foldWidgets.length)}}}),ace.define("ace/edit_session/bracket_match",["require","exports","module","ace/token_iterator","ace/range"],function(C,m,b){var x=C("../token_iterator").TokenIterator,p=C("../range").Range;m.BracketMatch=function(){this.findMatchingBracket=function(l,s){return l.column!=0&&(s=s||this.getLine(l.row).charAt(l.column-1))!=""&&(s=s.match(/([\(\[\{])|([\)\]\}])/))?s[1]?this.$findClosingBracket(s[1],l):this.$findOpeningBracket(s[2],l):null},this.getBracketRange=function(l){var s,n,t=this.getLine(l.row),i=!0,e=t.charAt(l.column-1),r=e&&e.match(/([\(\[\{])|([\)\]\}])/);if(r||(e=t.charAt(l.column),l={row:l.row,column:l.column+1},r=e&&e.match(/([\(\[\{])|([\)\]\}])/),i=!1),!r)return null;if(r[1]){if(!(n=this.$findClosingBracket(r[1],l)))return null;s=p.fromPoints(l,n),i||(s.end.column++,s.start.column--),s.cursor=s.end}else{if(!(n=this.$findOpeningBracket(r[2],l)))return null;s=p.fromPoints(n,l),i||(s.start.column++,s.end.column--),s.cursor=s.start}return s},this.getMatchingBracketRanges=function(l){var s=this.getLine(l.row),n=s.charAt(l.column-1),t=n&&n.match(/([\(\[\{])|([\)\]\}])/);return t||(n=s.charAt(l.column),l={row:l.row,column:l.column+1},t=n&&n.match(/([\(\[\{])|([\)\]\}])/)),t?(s=new p(l.row,l.column-1,l.row,l.column),(n=t[1]?this.$findClosingBracket(t[1],l):this.$findOpeningBracket(t[2],l))?[s,new p(n.row,n.column,n.row,n.column+1)]:[s]):null},this.$brackets={")":"(","(":")","]":"[","[":"]","{":"}","}":"{","<":">",">":"<"},this.$findOpeningBracket=function(l,s,n){var t=this.$brackets[l],i=1,e=new x(this,s.row,s.column),r=e.getCurrentToken();if(r=r||e.stepForward()){n=n||new RegExp("(\\.?"+r.type.replace(".","\\.").replace("rparen",".paren").replace(/\b(?:end)\b/,"(?:start|begin|end)")+")+");for(var a=s.column-e.getCurrentTokenColumn()-2,o=r.value;;){for(;0<=a;){var c=o.charAt(a);if(c==t){if(--i==0)return{row:e.getCurrentTokenRow(),column:a+e.getCurrentTokenColumn()}}else c==l&&(i+=1);--a}for(;(r=e.stepBackward())&&!n.test(r.type););if(r==null)break;a=(o=r.value).length-1}return null}},this.$findClosingBracket=function(l,s,n){var t=this.$brackets[l],i=1,e=new x(this,s.row,s.column),r=e.getCurrentToken();if(r=r||e.stepForward()){n=n||new RegExp("(\\.?"+r.type.replace(".","\\.").replace("lparen",".paren").replace(/\b(?:start|begin)\b/,"(?:start|begin|end)")+")+");for(var a=s.column-e.getCurrentTokenColumn();;){for(var o=r.value,c=o.length;a<c;){var h=o.charAt(a);if(h==t){if(--i==0)return{row:e.getCurrentTokenRow(),column:a+e.getCurrentTokenColumn()}}else h==l&&(i+=1);a+=1}for(;(r=e.stepForward())&&!n.test(r.type););if(r==null)break;a=0}return null}}}}),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(C,m,b){function x(h,A){this.$breakpoints=[],this.$decorations=[],this.$frontMarkers={},this.$backMarkers={},this.$markerId=1,this.$undoSelect=!0,this.$foldData=[],this.id="session"+ ++x.$uid,this.$foldData.toString=function(){return this.join(`
`)},this.bgTokenizer=new o(new e().getTokenizer(),this);var v=this;this.bgTokenizer.on("update",function(d){v._signal("tokenizerUpdate",d)}),this.on("changeFold",this.onChangeFold.bind(this)),this.$onChange=this.onChange.bind(this),typeof h=="object"&&h.getLine||(h=new a(h)),this.setDocument(h),this.selection=new i(this),this.$bidiHandler=new s(this),n.resetOptions(this),this.setMode(A),n._signal("session",this),this.destroyed=!1}var p=C("./lib/oop"),l=C("./lib/lang"),s=C("./bidihandler").BidiHandler,n=C("./config"),t=C("./lib/event_emitter").EventEmitter,i=C("./selection").Selection,e=C("./mode/text").Mode,r=C("./range").Range,a=C("./document").Document,o=C("./background_tokenizer").BackgroundTokenizer,c=C("./search_highlight").SearchHighlight;x.$uid=0,function(){p.implement(this,t),this.setDocument=function(d){this.doc&&this.doc.off("change",this.$onChange),(this.doc=d).on("change",this.$onChange,!0),this.bgTokenizer.setDocument(this.getDocument()),this.resetCaches()},this.getDocument=function(){return this.doc},this.$resetRowCache=function(d){var g;d?(g=this.$docRowCache.length,(d=this.$getRowCacheIndex(this.$docRowCache,d)+1)<g&&(this.$docRowCache.splice(d,g),this.$screenRowCache.splice(d,g))):(this.$docRowCache=[],this.$screenRowCache=[])},this.$getRowCacheIndex=function(d,g){for(var y=0,w=d.length-1;y<=w;){var I=y+w>>1,T=d[I];if(T<g)y=1+I;else{if(!(g<T))return I;w=I-1}}return y-1},this.resetCaches=function(){this.$modified=!0,this.$wrapData=[],this.$rowLengthCache=[],this.$resetRowCache(0),this.destroyed||this.bgTokenizer.start(0)},this.onChangeFold=function(d){d=d.data,this.$resetRowCache(d.start.row)},this.onChange=function(d){this.$modified=!0,this.$bidiHandler.onChange(d),this.$resetRowCache(d.start.row);var g=this.$updateInternalDataOnChange(d);!this.$fromUndo&&this.$undoManager&&(g&&g.length&&(this.$undoManager.add({action:"removeFolds",folds:g},this.mergeUndoDeltas),this.mergeUndoDeltas=!0),this.$undoManager.add(d,this.mergeUndoDeltas),this.mergeUndoDeltas=!0,this.$informUndoManager.schedule()),this.bgTokenizer.$updateOnChange(d),this._signal("change",d)},this.setValue=function(d){this.doc.setValue(d),this.selection.moveTo(0,0),this.$resetRowCache(0),this.setUndoManager(this.$undoManager),this.getUndoManager().reset()},this.getValue=this.toString=function(){return this.doc.getValue()},this.getSelection=function(){return this.selection},this.getState=function(d){return this.bgTokenizer.getState(d)},this.getTokens=function(d){return this.bgTokenizer.getTokens(d)},this.getTokenAt=function(d,g){var y=this.bgTokenizer.getTokens(d),I=0;if(g==null)var w=y.length-1,I=this.getLine(d).length;else for(w=0;w<y.length&&!(g<=(I+=y[w].value.length));w++);return(d=y[w])?(d.index=w,d.start=I-d.value.length,d):null},this.setUndoManager=function(d){var g;this.$undoManager=d,this.$informUndoManager&&this.$informUndoManager.cancel(),d?(d.addSession(g=this),this.$syncInformUndoManager=function(){g.$informUndoManager.cancel(),g.mergeUndoDeltas=!1},this.$informUndoManager=l.delayedCall(this.$syncInformUndoManager)):this.$syncInformUndoManager=function(){}},this.markUndoGroup=function(){this.$syncInformUndoManager&&this.$syncInformUndoManager()},this.$defaultUndoManager={undo:function(){},redo:function(){},hasUndo:function(){},hasRedo:function(){},reset:function(){},add:function(){},addSelection:function(){},startNewGroup:function(){},addSession:function(){}},this.getUndoManager=function(){return this.$undoManager||this.$defaultUndoManager},this.getTabString=function(){return this.getUseSoftTabs()?l.stringRepeat(" ",this.getTabSize()):"	"},this.setUseSoftTabs=function(d){this.setOption("useSoftTabs",d)},this.getUseSoftTabs=function(){return this.$useSoftTabs&&!this.$mode.$indentWithTabs},this.setTabSize=function(d){this.setOption("tabSize",d)},this.getTabSize=function(){return this.$tabSize},this.isTabStop=function(d){return this.$useSoftTabs&&d.column%this.$tabSize==0},this.setNavigateWithinSoftTabs=function(d){this.setOption("navigateWithinSoftTabs",d)},this.getNavigateWithinSoftTabs=function(){return this.$navigateWithinSoftTabs},this.$overwrite=!1,this.setOverwrite=function(d){this.setOption("overwrite",d)},this.getOverwrite=function(){return this.$overwrite},this.toggleOverwrite=function(){this.setOverwrite(!this.$overwrite)},this.addGutterDecoration=function(d,g){this.$decorations[d]||(this.$decorations[d]=""),this.$decorations[d]+=" "+g,this._signal("changeBreakpoint",{})},this.removeGutterDecoration=function(d,g){this.$decorations[d]=(this.$decorations[d]||"").replace(" "+g,""),this._signal("changeBreakpoint",{})},this.getBreakpoints=function(){return this.$breakpoints},this.setBreakpoints=function(d){this.$breakpoints=[];for(var g=0;g<d.length;g++)this.$breakpoints[d[g]]="ace_breakpoint";this._signal("changeBreakpoint",{})},this.clearBreakpoints=function(){this.$breakpoints=[],this._signal("changeBreakpoint",{})},this.setBreakpoint=function(d,g){(g=g===void 0?"ace_breakpoint":g)?this.$breakpoints[d]=g:delete this.$breakpoints[d],this._signal("changeBreakpoint",{})},this.clearBreakpoint=function(d){delete this.$breakpoints[d],this._signal("changeBreakpoint",{})},this.addMarker=function(T,g,y,w){var I=this.$markerId++,T={range:T,type:y||"line",renderer:typeof y=="function"?y:null,clazz:g,inFront:!!w,id:I};return w?(this.$frontMarkers[I]=T,this._signal("changeFrontMarker")):(this.$backMarkers[I]=T,this._signal("changeBackMarker")),I},this.addDynamicMarker=function(d,g){var y;if(d.update)return y=this.$markerId++,d.id=y,d.inFront=!!g,g?(this.$frontMarkers[y]=d,this._signal("changeFrontMarker")):(this.$backMarkers[y]=d,this._signal("changeBackMarker")),d},this.removeMarker=function(d){var g=this.$frontMarkers[d]||this.$backMarkers[d];g&&(delete(g.inFront?this.$frontMarkers:this.$backMarkers)[d],this._signal(g.inFront?"changeFrontMarker":"changeBackMarker"))},this.getMarkers=function(d){return d?this.$frontMarkers:this.$backMarkers},this.highlight=function(d){var g;this.$searchHighlight||(g=new c(null,"ace_selected-word","text"),this.$searchHighlight=this.addDynamicMarker(g)),this.$searchHighlight.setRegexp(d)},this.highlightLines=function(d,g,y,w){return typeof g!="number"&&(y=g,g=d),y=y||"ace_step",d=new r(d,0,g,1/0),d.id=this.addMarker(d,y,"fullLine",w),d},this.setAnnotations=function(d){this.$annotations=d,this._signal("changeAnnotation",{})},this.getAnnotations=function(){return this.$annotations||[]},this.clearAnnotations=function(){this.setAnnotations([])},this.$detectNewLine=function(d){d=d.match(/^.*?(\r?\n)/m),this.$autoNewLine=d?d[1]:`
`},this.getWordRange=function(d,g){var y,w=this.getLine(d),I=!1,T=(y=(I=(I=0<g?!!w.charAt(g-1).match(this.tokenRe):I)||!!w.charAt(g).match(this.tokenRe))?this.tokenRe:/^\s+$/.test(w.slice(g-1,g+1))?/\s/:this.nonTokenRe,g);if(0<T){for(;0<=--T&&w.charAt(T).match(y););T++}for(var B=g;B<w.length&&w.charAt(B).match(y);)B++;return new r(d,T,d,B)},this.getAWordRange=function(d,g){for(var y=this.getWordRange(d,g),w=this.getLine(y.end.row);w.charAt(y.end.column).match(/[ \t]/);)y.end.column+=1;return y},this.setNewLineMode=function(d){this.doc.setNewLineMode(d)},this.getNewLineMode=function(){return this.doc.getNewLineMode()},this.setUseWorker=function(d){this.setOption("useWorker",d)},this.getUseWorker=function(){return this.$useWorker},this.onReloadTokenizer=function(d){var g=d.data;this.bgTokenizer.start(g.first),this._signal("tokenizerUpdate",d)},this.$modes=n.$modes,this.$mode=null,this.$modeId=null,this.setMode=function(d,g){if(d&&typeof d=="object"){if(d.getTokenizer)return this.$onChangeMode(d);var y=d,w=y.path}else w=d||"ace/mode/text";this.$modes["ace/mode/text"]||(this.$modes["ace/mode/text"]=new e),this.$modes[w]&&!y?(this.$onChangeMode(this.$modes[w]),g&&g()):(this.$modeId=w,n.loadModule(["mode",w],function(I){if(this.$modeId!==w)return g&&g();this.$modes[w]&&!y?this.$onChangeMode(this.$modes[w]):I&&I.Mode&&(I=new I.Mode(y),y||((this.$modes[w]=I).$id=w),this.$onChangeMode(I)),g&&g()}.bind(this)),this.$mode||this.$onChangeMode(this.$modes["ace/mode/text"],!0))},this.$onChangeMode=function(d,g){var y,w,I;g||(this.$modeId=d.$id),this.$mode!==d&&(y=this.$mode,this.$mode=d,this.$stopWorker(),this.$useWorker&&this.$startWorker(),(w=d.getTokenizer()).on!==void 0&&(I=this.onReloadTokenizer.bind(this),w.on("update",I)),this.bgTokenizer.setTokenizer(w),this.bgTokenizer.setDocument(this.getDocument()),this.tokenRe=d.tokenRe,this.nonTokenRe=d.nonTokenRe,g||(d.attachToSession&&d.attachToSession(this),this.$options.wrapMethod.set.call(this,this.$wrapMethod),this.$setFolding(d.foldingRules),this.bgTokenizer.start(0),this._emit("changeMode",{oldMode:y,mode:d})))},this.$stopWorker=function(){this.$worker&&(this.$worker.terminate(),this.$worker=null)},this.$startWorker=function(){try{this.$worker=this.$mode.createWorker(this)}catch(d){n.warn("Could not load worker",d),this.$worker=null}},this.getMode=function(){return this.$mode},this.$scrollTop=0,this.setScrollTop=function(d){this.$scrollTop===d||isNaN(d)||(this.$scrollTop=d,this._signal("changeScrollTop",d))},this.getScrollTop=function(){return this.$scrollTop},this.$scrollLeft=0,this.setScrollLeft=function(d){this.$scrollLeft===d||isNaN(d)||(this.$scrollLeft=d,this._signal("changeScrollLeft",d))},this.getScrollLeft=function(){return this.$scrollLeft},this.getScreenWidth=function(){return this.$computeWidth(),this.lineWidgets?Math.max(this.getLineWidgetMaxWidth(),this.screenWidth):this.screenWidth},this.getLineWidgetMaxWidth=function(){var d;return this.lineWidgetsWidth!=null?this.lineWidgetsWidth:(d=0,this.lineWidgets.forEach(function(g){g&&g.screenWidth>d&&(d=g.screenWidth)}),this.lineWidgetWidth=d)},this.$computeWidth=function(d){if(this.$modified||d){if(this.$modified=!1,this.$useWrapMode)return this.screenWidth=this.$wrapLimit;for(var g=this.doc.getAllLines(),y=this.$rowLengthCache,w=0,I=0,T=this.$foldData[I],B=T?T.start.row:1/0,E=g.length,_=0;_<E;_++){if(B<_){if(E<=(_=T.end.row+1))break;B=(T=this.$foldData[I++])?T.start.row:1/0}y[_]==null&&(y[_]=this.$getStringScreenWidth(g[_])[0]),y[_]>w&&(w=y[_])}this.screenWidth=w}},this.getLine=function(d){return this.doc.getLine(d)},this.getLines=function(d,g){return this.doc.getLines(d,g)},this.getLength=function(){return this.doc.getLength()},this.getTextRange=function(d){return this.doc.getTextRange(d||this.selection.getRange())},this.insert=function(d,g){return this.doc.insert(d,g)},this.remove=function(d){return this.doc.remove(d)},this.removeFullLines=function(d,g){return this.doc.removeFullLines(d,g)},this.undoChanges=function(d,g){if(d.length){this.$fromUndo=!0;for(var y=d.length-1;y!=-1;y--){var w=d[y];w.action=="insert"||w.action=="remove"?this.doc.revertDelta(w):w.folds&&this.addFolds(w.folds)}!g&&this.$undoSelect&&(d.selectionBefore?this.selection.fromJSON(d.selectionBefore):this.selection.setRange(this.$getUndoSelection(d,!0))),this.$fromUndo=!1}},this.redoChanges=function(d,g){if(d.length){this.$fromUndo=!0;for(var y=0;y<d.length;y++){var w=d[y];w.action!="insert"&&w.action!="remove"||this.doc.$safeApplyDelta(w)}!g&&this.$undoSelect&&(d.selectionAfter?this.selection.fromJSON(d.selectionAfter):this.selection.setRange(this.$getUndoSelection(d,!1))),this.$fromUndo=!1}},this.setUndoSelect=function(d){this.$undoSelect=d},this.$getUndoSelection=function(d,g){function y(E){return g?E.action!=="insert":E.action==="insert"}for(var w,I,T=0;T<d.length;T++){var B=d[T];B.start&&(w?y(B)?(I=B.start,w.compare(I.row,I.column)==-1&&w.setStart(I),I=B.end,w.compare(I.row,I.column)==1&&w.setEnd(I)):(I=B.start,w.compare(I.row,I.column)==-1&&(w=r.fromPoints(B.start,B.start))):w=y(B)?r.fromPoints(B.start,B.end):r.fromPoints(B.start,B.start))}return w},this.replace=function(d,g){return this.doc.replace(d,g)},this.moveText=function(d,_,y){var w,I,T,B=this.getTextRange(d),E=this.getFoldsInRange(d),_=r.fromPoints(_,_);return y||(this.remove(d),I=d.start.row-d.end.row,(T=I?-d.end.column:d.start.column-d.end.column)&&(_.start.row==d.end.row&&_.start.column>d.end.column&&(_.start.column+=T),_.end.row==d.end.row&&_.end.column>d.end.column&&(_.end.column+=T)),I&&_.start.row>=d.end.row&&(_.start.row+=I,_.end.row+=I)),_.end=this.insert(_.start,B),E.length&&(w=d.start,y=_.start,I=y.row-w.row,T=y.column-w.column,this.addFolds(E.map(function(P){return(P=P.clone()).start.row==w.row&&(P.start.column+=T),P.end.row==w.row&&(P.end.column+=T),P.start.row+=I,P.end.row+=I,P}))),_},this.indentRows=function(d,g,y){y=y.replace(/\t/g,this.getTabString());for(var w=d;w<=g;w++)this.doc.insertInLine({row:w,column:0},y)},this.outdentRows=function(d){for(var g=d.collapseRows(),y=new r(0,0,0,0),w=this.getTabSize(),I=g.start.row;I<=g.end.row;++I){var T=this.getLine(I);y.start.row=I,y.end.row=I;for(var B=0;B<w&&T.charAt(B)==" ";++B);B<w&&T.charAt(B)=="	"?(y.start.column=B,y.end.column=B+1):(y.start.column=0,y.end.column=B),this.remove(y)}},this.$moveLines=function(d,g,T){if(d=this.getRowFoldStart(d),g=this.getRowFoldEnd(g),T<0){if((I=this.getRowFoldStart(d+T))<0)return 0;var w=I-d}else if(0<T){if((I=this.getRowFoldEnd(g+T))>this.doc.getLength()-1)return 0;w=I-g}else d=this.$clipRowToDocument(d),w=(g=this.$clipRowToDocument(g))-d+1;var I=new r(d,0,g,Number.MAX_VALUE),I=this.getFoldsInRange(I).map(function(B){return(B=B.clone()).start.row+=w,B.end.row+=w,B}),T=T==0?this.doc.getLines(d,g):this.doc.removeFullLines(d,g);return this.doc.insertFullLines(d+w,T),I.length&&this.addFolds(I),w},this.moveLinesUp=function(d,g){return this.$moveLines(d,g,-1)},this.moveLinesDown=function(d,g){return this.$moveLines(d,g,1)},this.duplicateLines=function(d,g){return this.$moveLines(d,g,0)},this.$clipRowToDocument=function(d){return Math.max(0,Math.min(d,this.doc.getLength()-1))},this.$clipColumnToRow=function(d,g){return g<0?0:Math.min(this.doc.getLine(d).length,g)},this.$clipPositionToDocument=function(d,g){var y;return g=Math.max(0,g),g=d<0?d=0:(y=this.doc.getLength())<=d?this.doc.getLine(d=y-1).length:Math.min(this.doc.getLine(d).length,g),{row:d,column:g}},this.$clipRangeToDocument=function(d){d.start.row<0?(d.start.row=0,d.start.column=0):d.start.column=this.$clipColumnToRow(d.start.row,d.start.column);var g=this.doc.getLength()-1;return d.end.row>g?(d.end.row=g,d.end.column=this.doc.getLine(g).length):d.end.column=this.$clipColumnToRow(d.end.row,d.end.column),d},this.$wrapLimit=80,this.$useWrapMode=!1,this.$wrapLimitRange={min:null,max:null},this.setUseWrapMode=function(d){d!=this.$useWrapMode&&(this.$useWrapMode=d,this.$modified=!0,this.$resetRowCache(0),d&&(d=this.getLength(),this.$wrapData=Array(d),this.$updateWrapData(0,d-1)),this._signal("changeWrapMode"))},this.getUseWrapMode=function(){return this.$useWrapMode},this.setWrapLimitRange=function(d,g){this.$wrapLimitRange.min===d&&this.$wrapLimitRange.max===g||(this.$wrapLimitRange={min:d,max:g},this.$modified=!0,this.$bidiHandler.markAsDirty(),this.$useWrapMode&&this._signal("changeWrapMode"))},this.adjustWrapLimit=function(d,w){var y=this.$wrapLimitRange,w=(y.max<0&&(y={min:w,max:w}),this.$constrainWrapLimit(d,y.min,y.max));return w!=this.$wrapLimit&&1<w&&(this.$wrapLimit=w,this.$modified=!0,this.$useWrapMode&&(this.$updateWrapData(0,this.getLength()-1),this.$resetRowCache(0),this._signal("changeWrapLimit")),!0)},this.$constrainWrapLimit=function(d,g,y){return g&&(d=Math.max(g,d)),d=y?Math.min(y,d):d},this.getWrapLimit=function(){return this.$wrapLimit},this.setWrapLimit=function(d){this.setWrapLimitRange(d,d)},this.getWrapLimitRange=function(){return{min:this.$wrapLimitRange.min,max:this.$wrapLimitRange.max}},this.$updateInternalDataOnChange=function(d){var g=this.$useWrapMode,y=d.action,w=d.start,I=d.end,T=w.row,B=I.row,E=B-T,_=null;if(this.$updating=!0,E!=0)if(y==="remove"){this[g?"$wrapData":"$rowLengthCache"].splice(T,E);var P=this.$foldData,_=this.getFoldsInRange(d);this.removeFolds(_);var j=0;for((Y=this.getFoldLine(I.row))&&(Y.addRemoveChars(I.row,I.column,w.column-I.column),Y.shiftRow(-E),(z=this.getFoldLine(T))&&z!==Y&&(z.merge(Y),Y=z),j=P.indexOf(Y)+1);j<P.length;j++)(Y=P[j]).start.row>=I.row&&Y.shiftRow(-E);B=T}else{var z=Array(E),D=(z.unshift(T,0),g?this.$wrapData:this.$rowLengthCache),P=(D.splice.apply(D,z),this.$foldData),j=0;for((Y=this.getFoldLine(T))&&((D=Y.range.compareInside(w.row,w.column))==0?(Y=Y.split(w.row,w.column))&&(Y.shiftRow(E),Y.addRemoveChars(B,0,I.column-w.column)):D==-1&&(Y.addRemoveChars(T,0,I.column-w.column),Y.shiftRow(E)),j=P.indexOf(Y)+1);j<P.length;j++)(Y=P[j]).start.row>=T&&Y.shiftRow(E)}else{var Y,E=Math.abs(d.start.column-d.end.column);y==="remove"&&(_=this.getFoldsInRange(d),this.removeFolds(_),E=-E),(Y=this.getFoldLine(T))&&Y.addRemoveChars(T,w.column,E)}return g&&this.$wrapData.length!=this.doc.getLength()&&console.error("doc.getLength() and $wrapData.length have to be the same!"),this.$updating=!1,g?this.$updateWrapData(T,B):this.$updateRowLengthCache(T,B),_},this.$updateRowLengthCache=function(d,g,y){this.$rowLengthCache[d]=null,this.$rowLengthCache[g]=null},this.$updateWrapData=function(d,g){var y,w,I=this.doc.getAllLines(),T=this.getTabSize(),B=this.$wrapData,E=this.$wrapLimit,_=d;for(g=Math.min(g,I.length-1);_<=g;)(w=this.getFoldLine(_,w))?(y=[],w.walk(function(P,j,z,D){var Y;if(P!=null){(Y=this.$getDisplayTokens(P,y.length))[0]=h;for(var R=1;R<Y.length;R++)Y[R]=A}else Y=this.$getDisplayTokens(I[j].substring(D,z),y.length);y=y.concat(Y)}.bind(this),w.end.row,I[w.end.row].length+1),B[w.start.row]=this.$computeWrapSplits(y,E,T),_=w.end.row+1):(y=this.$getDisplayTokens(I[_]),B[_]=this.$computeWrapSplits(y,E,T),_++)};var h=3,A=4;function v(d){return!(d<4352)&&(4352<=d&&d<=4447||4515<=d&&d<=4519||4602<=d&&d<=4607||9001<=d&&d<=9002||11904<=d&&d<=11929||11931<=d&&d<=12019||12032<=d&&d<=12245||12272<=d&&d<=12283||12288<=d&&d<=12350||12353<=d&&d<=12438||12441<=d&&d<=12543||12549<=d&&d<=12589||12593<=d&&d<=12686||12688<=d&&d<=12730||12736<=d&&d<=12771||12784<=d&&d<=12830||12832<=d&&d<=12871||12880<=d&&d<=13054||13056<=d&&d<=19903||19968<=d&&d<=42124||42128<=d&&d<=42182||43360<=d&&d<=43388||44032<=d&&d<=55203||55216<=d&&d<=55238||55243<=d&&d<=55291||63744<=d&&d<=64255||65040<=d&&d<=65049||65072<=d&&d<=65106||65108<=d&&d<=65126||65128<=d&&d<=65131||65281<=d&&d<=65376||65504<=d&&d<=65510)}this.$computeWrapSplits=function(d,g,y){if(d.length==0)return[];var w=[],I=d.length,T=0,B=0,E=this.$wrapAsCode,_=this.$indentedSoftWrap,P=g<=Math.max(2*y,8)||_===!1?0:Math.floor(g/2);function j(R){for(var H=R-T,G=T;G<R;G++){var f=d[G];f!==12&&f!==2||--H}w.length||(z=function(){var S=0;if(P===0)return S;if(_)for(var $=0;$<d.length;$++){var M=d[$];if(M==10)S+=1;else if(M==11)S+=y;else if(M!=12)break}return E&&_!==!1&&(S+=y),Math.min(S,P)}(),w.indent=z),B+=H,w.push(B),T=R}for(var z=0;g-z<I-T;){var D=T+g-z;if(10<=d[D-1]&&10<=d[D])j(D);else if(d[D]==h||d[D]==A){for(;D!=T-1&&d[D]!=h;D--);if(!(T<D)){for(D=T+g;D<d.length&&d[D]==A;D++);if(D==d.length)break}j(D)}else{for(var Y=Math.max(D-(g-(g>>2)),T-1);Y<D&&d[D]<h;)D--;if(E){for(;Y<D&&d[D]<h;)D--;for(;Y<D&&d[D]==9;)D--}else for(;Y<D&&d[D]<10;)D--;Y<D?j(++D):(d[D=T+g]==2&&D--,j(D-z))}}return w},this.$getDisplayTokens=function(d,g){var y,w=[];g=g||0;for(var I=0;I<d.length;I++){var T=d.charCodeAt(I);if(T==9){y=this.getScreenTabSize(w.length+g),w.push(11);for(var B=1;B<y;B++)w.push(12)}else T==32?w.push(10):39<T&&T<48||57<T&&T<64?w.push(9):4352<=T&&v(T)?w.push(1,2):w.push(1)}return w},this.$getStringScreenWidth=function(d,g,y){if(g==0)return[0,0];var w,I;for(g==null&&(g=1/0),y=y||0,I=0;I<d.length&&((w=d.charCodeAt(I))==9?y+=this.getScreenTabSize(y):4352<=w&&v(w)?y+=2:y+=1,!(g<y));I++);return[y,I]},this.lineWidgets=null,this.getRowLength=function(d){var g=1;return this.lineWidgets&&(g+=this.lineWidgets[d]&&this.lineWidgets[d].rowCount||0),this.$useWrapMode&&this.$wrapData[d]?this.$wrapData[d].length+g:g},this.getRowLineCount=function(d){return this.$useWrapMode&&this.$wrapData[d]?this.$wrapData[d].length+1:1},this.getRowWrapIndent=function(d){var g;return this.$useWrapMode&&(d=this.screenToDocumentPosition(d,Number.MAX_VALUE),(g=this.$wrapData[d.row]).length&&g[0]<d.column)?g.indent:0},this.getScreenLastRowColumn=function(d){return d=this.screenToDocumentPosition(d,Number.MAX_VALUE),this.documentToScreenColumn(d.row,d.column)},this.getDocumentLastRowColumn=function(d,g){return d=this.documentToScreenRow(d,g),this.getScreenLastRowColumn(d)},this.getDocumentLastRowColumnPosition=function(d,g){return d=this.documentToScreenRow(d,g),this.screenToDocumentPosition(d,Number.MAX_VALUE/10)},this.getRowSplitData=function(d){if(this.$useWrapMode)return this.$wrapData[d]},this.getScreenTabSize=function(d){return this.$tabSize-(d%this.$tabSize|0)},this.screenToDocumentRow=function(d,g){return this.screenToDocumentPosition(d,g).row},this.screenToDocumentColumn=function(d,g){return this.screenToDocumentPosition(d,g).column},this.screenToDocumentPosition=function(d,g,y){if(d<0)return{row:0,column:0};for(var w,I,T,B=0,E=0,_=0,P=0,j=this.$screenRowCache,z=this.$getRowCacheIndex(j,d),D=j.length,Y=(T=D&&0<=z?(_=j[z],B=this.$docRowCache[z],d>j[D-1]):!D,this.getLength()-1),R=this.getNextFoldLine(B),H=R?R.start.row:1/0;_<=d&&!(d<_+(P=this.getRowLength(B))||Y<=B);)_+=P,H<++B&&(B=R.end.row+1,H=(R=this.getNextFoldLine(B,R))?R.start.row:1/0),T&&(this.$docRowCache.push(B),this.$screenRowCache.push(_));if(R&&R.start.row<=B)w=this.getFoldDisplayLine(R),B=R.start.row;else{if(_+P<=d||Y<B)return{row:Y,column:this.getLine(Y).length};w=this.getLine(B),R=null}return z=0,j=Math.floor(d-_),this.$useWrapMode&&(D=this.$wrapData[B])&&(I=D[j],0<j&&D.length&&(z=D.indent,E=D[j-1]||D[D.length-1],w=w.substring(E))),y!==void 0&&this.$bidiHandler.isBidiRow(_+j,B,j)&&(g=this.$bidiHandler.offsetToCol(y)),E+=this.$getStringScreenWidth(w,g-z)[1],this.$useWrapMode&&I<=E&&(E=I-1),R?R.idxToPosition(E):{row:B,column:E}},this.documentToScreenPosition=function(d,g){var z=g===void 0?this.$clipPositionToDocument(d.row,d.column):this.$clipPositionToDocument(d,g),y=(d=z.row,g=z.column,0),z=null;(B=this.getFoldAt(d,g,1))&&(d=B.start.row,g=B.start.column);for(var w,I,T=0,B=this.$docRowCache,D=this.$getRowCacheIndex(B,d),E=B.length,_=(I=E&&0<=D?(T=B[D],y=this.$screenRowCache[D],d>B[E-1]):!E,this.getNextFoldLine(T)),P=_?_.start.row:1/0;T<d;){if(P<=T){if(d<(w=_.end.row+1))break;P=(_=this.getNextFoldLine(w,_))?_.start.row:1/0}else w=T+1;y+=this.getRowLength(T),T=w,I&&(this.$docRowCache.push(T),this.$screenRowCache.push(y))}var j="",z=_&&P<=T?(j=this.getFoldDisplayLine(_,d,g),_.start.row):(j=this.getLine(d).substring(0,g),d),D=0;if(this.$useWrapMode){var Y=this.$wrapData[z];if(Y){for(var R=0;j.length>=Y[R];)y++,R++;j=j.substring(Y[R-1]||0,j.length),D=0<R?Y.indent:0}}return this.lineWidgets&&this.lineWidgets[T]&&this.lineWidgets[T].rowsAbove&&(y+=this.lineWidgets[T].rowsAbove),{row:y,column:D+this.$getStringScreenWidth(j)[0]}},this.documentToScreenColumn=function(d,g){return this.documentToScreenPosition(d,g).column},this.documentToScreenRow=function(d,g){return this.documentToScreenPosition(d,g).row},this.getScreenLength=function(){var d=0,g=null;if(this.$useWrapMode)for(var y=this.$wrapData.length,w=0,I=0,T=(g=this.$foldData[I++])?g.start.row:1/0;w<y;){var B=this.$wrapData[w];d+=B?B.length+1:1,T<++w&&(w=g.end.row+1,T=(g=this.$foldData[I++])?g.start.row:1/0)}else for(var d=this.getLength(),E=this.$foldData,I=0;I<E.length;I++)d-=(g=E[I]).end.row-g.start.row;return this.lineWidgets&&(d+=this.$getWidgetScreenLength()),d},this.$setFontMetrics=function(d){this.$enableVarChar&&(this.$getStringScreenWidth=function(g,y,w){if(y===0)return[0,0];var I,T;for(y=y||1/0,w=w||0,T=0;T<g.length&&!(y<(w+=(I=g.charAt(T))==="	"?this.getScreenTabSize(w):d.getCharacterWidth(I)));T++);return[w,T]})},this.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()},this.isFullWidth=v}.call(x.prototype),C("./edit_session/folding").Folding.call(x.prototype),C("./edit_session/bracket_match").BracketMatch.call(x.prototype),n.defineOptions(x.prototype,"session",{wrap:{set:function(h){h&&h!="off"?h=="free"?h=!0:h=="printMargin"?h=-1:typeof h=="string"&&(h=parseInt(h,10)||!1):h=!1,this.$wrap!=h&&((this.$wrap=h)?(this.setWrapLimitRange(h=typeof h=="number"?h:null,h),this.setUseWrapMode(!0)):this.setUseWrapMode(!1))},get:function(){return this.getUseWrapMode()?this.$wrap==-1?"printMargin":this.getWrapLimitRange().min?this.$wrap:"free":"off"},handlesSet:!0},wrapMethod:{set:function(h){(h=h=="auto"?this.$mode.type!="text":h!="text")!=this.$wrapAsCode&&(this.$wrapAsCode=h,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(h){this.$useWorker=h,this.$stopWorker(),h&&this.$startWorker()},initialValue:!0},useSoftTabs:{initialValue:!0},tabSize:{set:function(h){0<(h=parseInt(h))&&this.$tabSize!==h&&(this.$modified=!0,this.$rowLengthCache=[],this.$tabSize=h,this._signal("changeTabSize"))},initialValue:4,handlesSet:!0},navigateWithinSoftTabs:{initialValue:!1},foldStyle:{set:function(h){this.setFoldStyle(h)},handlesSet:!0},overwrite:{set:function(h){this._signal("changeOverwrite")},initialValue:!1},newLineMode:{set:function(h){this.doc.setNewLineMode(h)},get:function(){return this.doc.getNewLineMode()},handlesSet:!0},mode:{set:function(h){this.setMode(h)},get:function(){return this.$modeId},handlesSet:!0}}),m.EditSession=x}),ace.define("ace/search",["require","exports","module","ace/lib/lang","ace/lib/oop","ace/range"],function(C,m,b){function x(){this.$options={}}var p=C("./lib/lang"),l=C("./lib/oop"),s=C("./range").Range;(function(){this.set=function(n){return l.mixin(this.$options,n),this},this.getOptions=function(){return p.copyObject(this.$options)},this.setOptions=function(n){this.$options=n},this.find=function(e){var t,i=this.$options,e=this.$matchIterator(e,i);return!!e&&(t=null,e.forEach(function(r,a,o,c){return t=new s(r,a,o,c),!(a==c&&i.start&&i.start.start&&i.skipCurrent!=0&&t.isEqual(i.start))||(t=null,!1)}),t)},this.findAll=function(n){var t=this.$options;if(!t.needle)return[];this.$assembleRegExp(t);var i=t.range,e=i?n.getLines(i.start.row,i.end.row):n.doc.getAllLines(),r=[],a=t.re;if(t.$isMultiLine){var o,c=a.length,h=e.length-c;e:for(var A=a.offset||0;A<=h;A++){for(var v=0;v<c;v++)if(e[A+v].search(a[v])==-1)continue e;var d=e[A],g=e[A+c-1],d=d.length-d.match(a[0])[0].length,g=g.match(a[c-1])[0].length;o&&o.end.row===A&&o.end.column>d||(r.push(o=new s(A,d,A+c-1,g)),2<c&&(A=A+c-2))}}else for(var y=0;y<e.length;y++)for(var w=p.getMatchOffsets(e[y],a),v=0;v<w.length;v++){var I=w[v];r.push(new s(y,I.offset,y,I.offset+I.length))}if(i){for(var T=i.start.column,B=i.start.column,y=0,v=r.length-1;y<v&&r[y].start.column<T&&r[y].start.row==i.start.row;)y++;for(;y<v&&r[v].end.column>B&&r[v].end.row==i.end.row;)v--;for(r=r.slice(y,v+1),y=0,v=r.length;y<v;y++)r[y].start.row+=i.start.row,r[y].end.row+=i.start.row}return r},this.replace=function(n,t){var i=this.$options,e=this.$assembleRegExp(i);if(i.$isMultiLine)return t;if(e){var r=e.exec(n);if(!r||r[0].length!=n.length)return null;if(t=n.replace(e,t),i.preserveCase){t=t.split("");for(var a=Math.min(n.length,n.length);a--;){var o=n[a];o&&o.toLowerCase()!=o?t[a]=t[a].toUpperCase():t[a]=t[a].toLowerCase()}t=t.join("")}return t}},this.$assembleRegExp=function(n,t){if(n.needle instanceof RegExp)return n.re=n.needle;var i,e=n.needle;if(!n.needle)return n.re=!1;function r(c){return/\w/.test(c)||i.regExp?"\\b":""}n.regExp||(e=p.escapeRegExp(e)),n.wholeWord&&(i=n,e=r((a=e)[0])+a+r(a[a.length-1]));var a=n.caseSensitive?"gm":"gmi";if(n.$isMultiLine=!t&&/[\n\r]/.test(e),n.$isMultiLine)return n.re=this.$assembleMultilineRegExp(e,a);try{var o=new RegExp(e,a)}catch{o=!1}return n.re=o},this.$assembleMultilineRegExp=function(n,t){for(var i=n.replace(/\r\n|\r|\n/g,`$
^`).split(`
`),e=[],r=0;r<i.length;r++)try{e.push(new RegExp(i[r],t))}catch{return!1}return e},this.$matchIterator=function(n,t){var i,e,r,a,o,c,h,A,v=this.$assembleRegExp(t);return!!v&&(i=t.backwards==1,e=t.skipCurrent!=0,r=t.range,(a=(a=t.start)||(r?r[i?"end":"start"]:n.selection.getRange())).start&&(a=a[e!=i?"end":"start"]),o=r?r.start.row:0,c=r?r.end.row:n.getLength()-1,A=t.$isMultiLine?(h=v.length,function(d,g,y){var w=i?d-h+1:d;if(!(w<0||w+h>n.getLength())){var I=n.getLine(w),d=I.search(v[0]);if(!(!i&&d<g||d===-1)){for(var T=1;T<h;T++)if((I=n.getLine(w+T)).search(v[T])==-1)return;var B=I.match(v[h-1])[0].length;if(!(i&&g<B))return!!y(w,d,w+h-1,B)||void 0}}}):i?function(d,g,y){var w,I=n.getLine(d),T=[];for(v.lastIndex=0;w=v.exec(I);){var B=w[0].length,E=w.index;if(!B){if(E>=I.length)break;v.lastIndex=E+=1}if(w.index+B>g)break;T.push(w.index,B)}for(var _=T.length-1;0<=_;_-=2){var P=T[_-1];if(y(d,P,d,P+(B=T[_])))return!0}}:function(d,g,y){var w=n.getLine(d);for(v.lastIndex=g;I=v.exec(w);){var I,T=I[0].length;if(y(d,I=I.index,d,I+T))return!0;if(!T&&(v.lastIndex=I+=1,I>=w.length))return!1}},{forEach:i?function(d){var g=a.row;if(!A(g,a.column,d)){for(g--;o<=g;g--)if(A(g,Number.MAX_VALUE,d))return;if(t.wrap!=0){for(g=c,o=a.row;o<=g;g--)if(A(g,Number.MAX_VALUE,d))return}}}:function(d){var g=a.row;if(!A(g,a.column,d)){for(g+=1;g<=c;g++)if(A(g,0,d))return;if(t.wrap!=0){for(g=o,c=a.row;g<=c;g++)if(A(g,0,d))return}}}})}}).call(x.prototype),m.Search=x}),ace.define("ace/keyboard/hash_handler",["require","exports","module","ace/lib/keys","ace/lib/useragent"],function(C,m,b){var x=C("../lib/keys"),p=C("../lib/useragent"),l=x.KEY_MODS;function s(t,i){this.platform=i||(p.isMac?"mac":"win"),this.commands={},this.commandKeyBinding={},this.addCommands(t),this.$singleCommand=!0}function n(t,i){s.call(this,t,i),this.$singleCommand=!1}n.prototype=s.prototype,function(){function t(i){return typeof i=="object"&&i.bindKey&&i.bindKey.position||(i.isDefault?-100:0)}this.addCommand=function(i){this.commands[i.name]&&this.removeCommand(i),(this.commands[i.name]=i).bindKey&&this._buildKeyHash(i)},this.removeCommand=function(i,e){var r,a=i&&(typeof i=="string"?i:i.name),o=(i=this.commands[a],e||delete this.commands[a],this.commandKeyBinding);for(r in o){var c,h=o[r];h==i?delete o[r]:Array.isArray(h)&&(c=h.indexOf(i))!=-1&&(h.splice(c,1),h.length==1&&(o[r]=h[0]))}},this.bindKey=function(i,e,r){if(typeof i=="object"&&i&&(r==null&&(r=i.position),i=i[this.platform]),i)return typeof e=="function"?this.addCommand({exec:e,bindKey:i,name:e.name||i}):void i.split("|").forEach(function(h){var o="",c=(h.indexOf(" ")!=-1&&(h=(c=h.split(/\s+/)).pop(),c.forEach(function(A){A=this.parseKeys(A),A=l[A.hashId]+A.key,o+=(o?" ":"")+A,this._addCommandToBinding(o,"chainKeys")},this),o+=" "),this.parseKeys(h)),h=l[c.hashId]+c.key;this._addCommandToBinding(o+h,e,r)},this)},this._addCommandToBinding=function(i,e,r){var a=this.commandKeyBinding;if(e)if(!a[i]||this.$singleCommand)a[i]=e;else{Array.isArray(a[i])?(c=a[i].indexOf(e))!=-1&&a[i].splice(c,1):a[i]=[a[i]],typeof r!="number"&&(r=t(e));for(var o=a[i],c=0;c<o.length&&!(r<t(o[c]));c++);o.splice(c,0,e)}else delete a[i]},this.addCommands=function(i){i&&Object.keys(i).forEach(function(e){var r=i[e];if(r){if(typeof r=="string")return this.bindKey(r,e);typeof(r=typeof r=="function"?{exec:r}:r)=="object"&&(r.name||(r.name=e),this.addCommand(r))}},this)},this.removeCommands=function(i){Object.keys(i).forEach(function(e){this.removeCommand(i[e])},this)},this.bindKeys=function(i){Object.keys(i).forEach(function(e){this.bindKey(e,i[e])},this)},this._buildKeyHash=function(i){this.bindKey(i.bindKey,i)},this.parseKeys=function(i){var e=i.toLowerCase().split(/[\-\+]([\-\+])?/).filter(function(A){return A}),r=e.pop(),a=x[r];if(x.FUNCTION_KEYS[a])r=x.FUNCTION_KEYS[a].toLowerCase();else{if(!e.length)return{key:r,hashId:-1};if(e.length==1&&e[0]=="shift")return{key:r.toUpperCase(),hashId:-1}}for(var o=0,c=e.length;c--;){var h=x.KEY_MODS[e[c]];if(h==null)return typeof console!="undefined"&&console.error("invalid modifier "+e[c]+" in "+i),!1;o|=h}return{key:r,hashId:o}},this.findKeyCommand=function(i,e){return i=l[i]+e,this.commandKeyBinding[i]},this.handleKeyboard=function(i,e,r,a){var o,c;if(!(a<0))return o=l[e]+r,c=this.commandKeyBinding[o],i.$keyChain&&(i.$keyChain+=" "+o,c=this.commandKeyBinding[i.$keyChain]||c),!c||c!="chainKeys"&&c[c.length-1]!="chainKeys"?(i.$keyChain&&(e&&e!=4||r.length!=1?(e==-1||0<a)&&(i.$keyChain=""):i.$keyChain=i.$keyChain.slice(0,-o.length-1)),{command:c}):(i.$keyChain=i.$keyChain||o,{command:"null"})},this.getStatusText=function(i,e){return e.$keyChain||""}}.call(s.prototype),m.HashHandler=s,m.MultiHashHandler=n}),ace.define("ace/commands/command_manager",["require","exports","module","ace/lib/oop","ace/keyboard/hash_handler","ace/lib/event_emitter"],function(C,m,b){function x(n,t){l.call(this,t,n),this.byName=this.commands,this.setDefaultHandler("exec",function(i){return i.args?i.command.exec(i.editor,i.args,i.event,!1):i.command.exec(i.editor,{},i.event,!0)})}var p=C("../lib/oop"),l=C("../keyboard/hash_handler").MultiHashHandler,s=C("../lib/event_emitter").EventEmitter;p.inherits(x,l),function(){p.implement(this,s),this.exec=function(n,t,i){if(Array.isArray(n)){for(var e=n.length;e--;)if(this.exec(n[e],t,i))return!0;return!1}var r;return!!(n=typeof n=="string"?this.commands[n]:n)&&!(t&&t.$readOnly&&!n.readOnly)&&!(this.$checkCommandState!=0&&n.isAvailable&&!n.isAvailable(t))&&((r={editor:t,command:n,args:i}).returnValue=this._emit("exec",r),this._signal("afterExec",r),r.returnValue!==!1)},this.toggleRecording=function(n){if(!this.$inReplay)return n&&n._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(t){this.macro.push([t.command,t.args])}.bind(this)),this.oldMacro=this.macro,this.macro=[],this.on("exec",this.$addCommandToMacro),this.recording=!0)},this.replay=function(n){if(!this.$inReplay&&this.macro){if(this.recording)return this.toggleRecording(n);try{this.$inReplay=!0,this.macro.forEach(function(t){typeof t=="string"?this.exec(t,n):this.exec(t[0],n,t[1])},this)}finally{this.$inReplay=!1}}},this.trimMacro=function(n){return n.map(function(t){return typeof t[0]!="string"&&(t[0]=t[0].name),t=t[1]?t:t[0]})}}.call(x.prototype),m.CommandManager=x}),ace.define("ace/commands/default_commands",["require","exports","module","ace/lib/lang","ace/config","ace/range"],function(C,m,b){var x=C("../lib/lang"),p=C("../config"),l=C("../range").Range;function s(t,i){return{win:t,mac:i}}m.commands=[{name:"showSettingsMenu",description:"Show settings menu",bindKey:s("Ctrl-,","Command-,"),exec:function(t){p.loadModule("ace/ext/settings_menu",function(i){i.init(t),t.showSettingsMenu()})},readOnly:!0},{name:"goToNextError",description:"Go to next error",bindKey:s("Alt-E","F4"),exec:function(t){p.loadModule("./ext/error_marker",function(i){i.showErrorMarker(t,1)})},scrollIntoView:"animate",readOnly:!0},{name:"goToPreviousError",description:"Go to previous error",bindKey:s("Alt-Shift-E","Shift-F4"),exec:function(t){p.loadModule("./ext/error_marker",function(i){i.showErrorMarker(t,-1)})},scrollIntoView:"animate",readOnly:!0},{name:"selectall",description:"Select all",bindKey:s("Ctrl-A","Command-A"),exec:function(t){t.selectAll()},readOnly:!0},{name:"centerselection",description:"Center selection",bindKey:s(null,"Ctrl-L"),exec:function(t){t.centerSelection()},readOnly:!0},{name:"gotoline",description:"Go to line...",bindKey:s("Ctrl-L","Command-L"),exec:function(t,i){typeof i!="number"||isNaN(i)||t.gotoLine(i),t.prompt({$type:"gotoLine"})},readOnly:!0},{name:"fold",bindKey:s("Alt-L|Ctrl-F1","Command-Alt-L|Command-F1"),exec:function(t){t.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(t){t.session.toggleFold(!0)},multiSelectAction:"forEach",scrollIntoView:"center",readOnly:!0},{name:"toggleFoldWidget",description:"Toggle fold widget",bindKey:s("F2","F2"),exec:function(t){t.session.toggleFoldWidget()},multiSelectAction:"forEach",scrollIntoView:"center",readOnly:!0},{name:"toggleParentFoldWidget",description:"Toggle parent fold widget",bindKey:s("Alt-F2","Alt-F2"),exec:function(t){t.session.toggleFoldWidget(!0)},multiSelectAction:"forEach",scrollIntoView:"center",readOnly:!0},{name:"foldall",description:"Fold all",bindKey:s(null,"Ctrl-Command-Option-0"),exec:function(t){t.session.foldAll()},scrollIntoView:"center",readOnly:!0},{name:"foldAllComments",description:"Fold all comments",bindKey:s(null,"Ctrl-Command-Option-0"),exec:function(t){t.session.foldAllComments()},scrollIntoView:"center",readOnly:!0},{name:"foldOther",description:"Fold other",bindKey:s("Alt-0","Command-Option-0"),exec:function(t){t.session.foldAll(),t.session.unfold(t.selection.getAllRanges())},scrollIntoView:"center",readOnly:!0},{name:"unfoldall",description:"Unfold all",bindKey:s("Alt-Shift-0","Command-Option-Shift-0"),exec:function(t){t.session.unfold()},scrollIntoView:"center",readOnly:!0},{name:"findnext",description:"Find next",bindKey:s("Ctrl-K","Command-G"),exec:function(t){t.findNext()},multiSelectAction:"forEach",scrollIntoView:"center",readOnly:!0},{name:"findprevious",description:"Find previous",bindKey:s("Ctrl-Shift-K","Command-Shift-G"),exec:function(t){t.findPrevious()},multiSelectAction:"forEach",scrollIntoView:"center",readOnly:!0},{name:"selectOrFindNext",description:"Select or find next",bindKey:s("Alt-K","Ctrl-G"),exec:function(t){t.selection.isEmpty()?t.selection.selectWord():t.findNext()},readOnly:!0},{name:"selectOrFindPrevious",description:"Select or find previous",bindKey:s("Alt-Shift-K","Ctrl-Shift-G"),exec:function(t){t.selection.isEmpty()?t.selection.selectWord():t.findPrevious()},readOnly:!0},{name:"find",description:"Find",bindKey:s("Ctrl-F","Command-F"),exec:function(t){p.loadModule("ace/ext/searchbox",function(i){i.Search(t)})},readOnly:!0},{name:"overwrite",description:"Overwrite",bindKey:"Insert",exec:function(t){t.toggleOverwrite()},readOnly:!0},{name:"selecttostart",description:"Select to start",bindKey:s("Ctrl-Shift-Home","Command-Shift-Home|Command-Shift-Up"),exec:function(t){t.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(t){t.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(t){t.getSelection().selectUp()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"golineup",description:"Go line up",bindKey:s("Up","Up|Ctrl-P"),exec:function(t,i){t.navigateUp(i.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(t){t.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(t){t.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(t){t.getSelection().selectDown()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"golinedown",description:"Go line down",bindKey:s("Down","Down|Ctrl-N"),exec:function(t,i){t.navigateDown(i.times)},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectwordleft",description:"Select word left",bindKey:s("Ctrl-Shift-Left","Option-Shift-Left"),exec:function(t){t.getSelection().selectWordLeft()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotowordleft",description:"Go to word left",bindKey:s("Ctrl-Left","Option-Left"),exec:function(t){t.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(t){t.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(t){t.navigateLineStart()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectleft",description:"Select left",bindKey:s("Shift-Left","Shift-Left|Ctrl-Shift-B"),exec:function(t){t.getSelection().selectLeft()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotoleft",description:"Go to left",bindKey:s("Left","Left|Ctrl-B"),exec:function(t,i){t.navigateLeft(i.times)},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectwordright",description:"Select word right",bindKey:s("Ctrl-Shift-Right","Option-Shift-Right"),exec:function(t){t.getSelection().selectWordRight()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotowordright",description:"Go to word right",bindKey:s("Ctrl-Right","Option-Right"),exec:function(t){t.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(t){t.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(t){t.navigateLineEnd()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectright",description:"Select right",bindKey:s("Shift-Right","Shift-Right"),exec:function(t){t.getSelection().selectRight()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotoright",description:"Go to right",bindKey:s("Right","Right|Ctrl-F"),exec:function(t,i){t.navigateRight(i.times)},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectpagedown",description:"Select page down",bindKey:"Shift-PageDown",exec:function(t){t.selectPageDown()},readOnly:!0},{name:"pagedown",description:"Page down",bindKey:s(null,"Option-PageDown"),exec:function(t){t.scrollPageDown()},readOnly:!0},{name:"gotopagedown",description:"Go to page down",bindKey:s("PageDown","PageDown|Ctrl-V"),exec:function(t){t.gotoPageDown()},readOnly:!0},{name:"selectpageup",description:"Select page up",bindKey:"Shift-PageUp",exec:function(t){t.selectPageUp()},readOnly:!0},{name:"pageup",description:"Page up",bindKey:s(null,"Option-PageUp"),exec:function(t){t.scrollPageUp()},readOnly:!0},{name:"gotopageup",description:"Go to page up",bindKey:"PageUp",exec:function(t){t.gotoPageUp()},readOnly:!0},{name:"scrollup",description:"Scroll up",bindKey:s("Ctrl-Up",null),exec:function(t){t.renderer.scrollBy(0,-2*t.renderer.layerConfig.lineHeight)},readOnly:!0},{name:"scrolldown",description:"Scroll down",bindKey:s("Ctrl-Down",null),exec:function(t){t.renderer.scrollBy(0,2*t.renderer.layerConfig.lineHeight)},readOnly:!0},{name:"selectlinestart",description:"Select line start",bindKey:"Shift-Home",exec:function(t){t.getSelection().selectLineStart()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectlineend",description:"Select line end",bindKey:"Shift-End",exec:function(t){t.getSelection().selectLineEnd()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"togglerecording",description:"Toggle recording",bindKey:s("Ctrl-Alt-E","Command-Option-E"),exec:function(t){t.commands.toggleRecording(t)},readOnly:!0},{name:"replaymacro",description:"Replay macro",bindKey:s("Ctrl-Shift-E","Command-Shift-E"),exec:function(t){t.commands.replay(t)},readOnly:!0},{name:"jumptomatching",description:"Jump to matching",bindKey:s("Ctrl-\\|Ctrl-P","Command-\\"),exec:function(t){t.jumpToMatching()},multiSelectAction:"forEach",scrollIntoView:"animate",readOnly:!0},{name:"selecttomatching",description:"Select to matching",bindKey:s("Ctrl-Shift-\\|Ctrl-Shift-P","Command-Shift-\\"),exec:function(t){t.jumpToMatching(!0)},multiSelectAction:"forEach",scrollIntoView:"animate",readOnly:!0},{name:"expandToMatching",description:"Expand to matching",bindKey:s("Ctrl-Shift-M","Ctrl-Shift-M"),exec:function(t){t.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(t){},readOnly:!0},{name:"cut",description:"Cut",exec:function(t){var i=t.$copyWithEmptySelection&&t.selection.isEmpty()?t.selection.getLineRange():t.selection.getRange();t._emit("cut",i),i.isEmpty()||t.session.remove(i),t.clearSelection()},scrollIntoView:"cursor",multiSelectAction:"forEach"},{name:"paste",description:"Paste",exec:function(t,i){t.$handlePaste(i)},scrollIntoView:"cursor"},{name:"removeline",description:"Remove line",bindKey:s("Ctrl-D","Command-D"),exec:function(t){t.removeLines()},scrollIntoView:"cursor",multiSelectAction:"forEachLine"},{name:"duplicateSelection",description:"Duplicate selection",bindKey:s("Ctrl-Shift-D","Command-Shift-D"),exec:function(t){t.duplicateSelection()},scrollIntoView:"cursor",multiSelectAction:"forEach"},{name:"sortlines",description:"Sort lines",bindKey:s("Ctrl-Alt-S","Command-Alt-S"),exec:function(t){t.sortLines()},scrollIntoView:"selection",multiSelectAction:"forEachLine"},{name:"togglecomment",description:"Toggle comment",bindKey:s("Ctrl-/","Command-/"),exec:function(t){t.toggleCommentLines()},multiSelectAction:"forEachLine",scrollIntoView:"selectionPart"},{name:"toggleBlockComment",description:"Toggle block comment",bindKey:s("Ctrl-Shift-/","Command-Shift-/"),exec:function(t){t.toggleBlockComment()},multiSelectAction:"forEach",scrollIntoView:"selectionPart"},{name:"modifyNumberUp",description:"Modify number up",bindKey:s("Ctrl-Shift-Up","Alt-Shift-Up"),exec:function(t){t.modifyNumber(1)},scrollIntoView:"cursor",multiSelectAction:"forEach"},{name:"modifyNumberDown",description:"Modify number down",bindKey:s("Ctrl-Shift-Down","Alt-Shift-Down"),exec:function(t){t.modifyNumber(-1)},scrollIntoView:"cursor",multiSelectAction:"forEach"},{name:"replace",description:"Replace",bindKey:s("Ctrl-H","Command-Option-F"),exec:function(t){p.loadModule("ace/ext/searchbox",function(i){i.Search(t,!0)})}},{name:"undo",description:"Undo",bindKey:s("Ctrl-Z","Command-Z"),exec:function(t){t.undo()}},{name:"redo",description:"Redo",bindKey:s("Ctrl-Shift-Z|Ctrl-Y","Command-Shift-Z|Command-Y"),exec:function(t){t.redo()}},{name:"copylinesup",description:"Copy lines up",bindKey:s("Alt-Shift-Up","Command-Option-Up"),exec:function(t){t.copyLinesUp()},scrollIntoView:"cursor"},{name:"movelinesup",description:"Move lines up",bindKey:s("Alt-Up","Option-Up"),exec:function(t){t.moveLinesUp()},scrollIntoView:"cursor"},{name:"copylinesdown",description:"Copy lines down",bindKey:s("Alt-Shift-Down","Command-Option-Down"),exec:function(t){t.copyLinesDown()},scrollIntoView:"cursor"},{name:"movelinesdown",description:"Move lines down",bindKey:s("Alt-Down","Option-Down"),exec:function(t){t.moveLinesDown()},scrollIntoView:"cursor"},{name:"del",description:"Delete",bindKey:s("Delete","Delete|Ctrl-D|Shift-Delete"),exec:function(t){t.remove("right")},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"backspace",description:"Backspace",bindKey:s("Shift-Backspace|Backspace","Ctrl-Backspace|Shift-Backspace|Backspace|Ctrl-H"),exec:function(t){t.remove("left")},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"cut_or_delete",description:"Cut or delete",bindKey:s("Shift-Delete",null),exec:function(t){if(!t.selection.isEmpty())return!1;t.remove("left")},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"removetolinestart",description:"Remove to line start",bindKey:s("Alt-Backspace","Command-Backspace"),exec:function(t){t.removeToLineStart()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"removetolineend",description:"Remove to line end",bindKey:s("Alt-Delete","Ctrl-K|Command-Delete"),exec:function(t){t.removeToLineEnd()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"removetolinestarthard",description:"Remove to line start hard",bindKey:s("Ctrl-Shift-Backspace",null),exec:function(t){var i=t.selection.getRange();i.start.column=0,t.session.remove(i)},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"removetolineendhard",description:"Remove to line end hard",bindKey:s("Ctrl-Shift-Delete",null),exec:function(t){var i=t.selection.getRange();i.end.column=Number.MAX_VALUE,t.session.remove(i)},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"removewordleft",description:"Remove word left",bindKey:s("Ctrl-Backspace","Alt-Backspace|Ctrl-Alt-Backspace"),exec:function(t){t.removeWordLeft()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"removewordright",description:"Remove word right",bindKey:s("Ctrl-Delete","Alt-Delete"),exec:function(t){t.removeWordRight()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"outdent",description:"Outdent",bindKey:s("Shift-Tab","Shift-Tab"),exec:function(t){t.blockOutdent()},multiSelectAction:"forEach",scrollIntoView:"selectionPart"},{name:"indent",description:"Indent",bindKey:s("Tab","Tab"),exec:function(t){t.indent()},multiSelectAction:"forEach",scrollIntoView:"selectionPart"},{name:"blockoutdent",description:"Block outdent",bindKey:s("Ctrl-[","Ctrl-["),exec:function(t){t.blockOutdent()},multiSelectAction:"forEachLine",scrollIntoView:"selectionPart"},{name:"blockindent",description:"Block indent",bindKey:s("Ctrl-]","Ctrl-]"),exec:function(t){t.blockIndent()},multiSelectAction:"forEachLine",scrollIntoView:"selectionPart"},{name:"insertstring",description:"Insert string",exec:function(t,i){t.insert(i)},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"inserttext",description:"Insert text",exec:function(t,i){t.insert(x.stringRepeat(i.text||"",i.times||1))},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"splitline",description:"Split line",bindKey:s(null,"Ctrl-O"),exec:function(t){t.splitLine()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"transposeletters",description:"Transpose letters",bindKey:s("Alt-Shift-X","Ctrl-T"),exec:function(t){t.transposeLetters()},multiSelectAction:function(t){t.transposeSelections(1)},scrollIntoView:"cursor"},{name:"touppercase",description:"To uppercase",bindKey:s("Ctrl-U","Ctrl-U"),exec:function(t){t.toUpperCase()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"tolowercase",description:"To lowercase",bindKey:s("Ctrl-Shift-U","Ctrl-Shift-U"),exec:function(t){t.toLowerCase()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"autoindent",description:"Auto Indent",bindKey:s(null,null),exec:function(t){t.autoIndent()},multiSelectAction:"forEachLine",scrollIntoView:"animate"},{name:"expandtoline",description:"Expand to line",bindKey:s("Ctrl-Shift-L","Command-Shift-L"),exec:function(t){var i=t.selection.getRange();i.start.column=i.end.column=0,i.end.row++,t.selection.setRange(i,!1)},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"joinlines",description:"Join lines",bindKey:s(null,null),exec:function(t){for(var r=t.selection.isBackwards(),i=r?t.selection.getSelectionLead():t.selection.getSelectionAnchor(),e=r?t.selection.getSelectionAnchor():t.selection.getSelectionLead(),r=t.session.doc.getLine(i.row).length,a=t.session.doc.getTextRange(t.selection.getRange()).replace(/\n\s*/," ").length,o=t.session.doc.getLine(i.row),c=i.row+1;c<=e.row+1;c++){var h=x.stringTrimLeft(x.stringTrimRight(t.session.doc.getLine(c)));o+=h=h.length!==0?" "+h:h}e.row+1<t.session.doc.getLength()-1&&(o+=t.session.doc.getNewLineCharacter()),t.clearSelection(),t.session.doc.replace(new l(i.row,0,e.row+2,0),o),0<a?(t.selection.moveCursorTo(i.row,i.column),t.selection.selectTo(i.row,i.column+a)):(r=t.session.doc.getLine(i.row).length>r?r+1:r,t.selection.moveCursorTo(i.row,r))},multiSelectAction:"forEach",readOnly:!0},{name:"invertSelection",description:"Invert selection",bindKey:s(null,null),exec:function(t){var i=t.session.doc.getLength()-1,e=t.session.doc.getLine(i).length,r=t.selection.rangeList.ranges,a=[];r.length<1&&(r=[t.selection.getRange()]);for(var o=0;o<r.length;o++)o!=r.length-1||r[o].end.row===i&&r[o].end.column===e||a.push(new l(r[o].end.row,r[o].end.column,i,e)),o===0?r[o].start.row===0&&r[o].start.column===0||a.push(new l(0,0,r[o].start.row,r[o].start.column)):a.push(new l(r[o-1].end.row,r[o-1].end.column,r[o].start.row,r[o].start.column));for(t.exitMultiSelectMode(),t.clearSelection(),o=0;o<a.length;o++)t.selection.addRange(a[o],!1)},readOnly:!0,scrollIntoView:"none"},{name:"addLineAfter",description:"Add new line after the current line",exec:function(t){t.selection.clearSelection(),t.navigateLineEnd(),t.insert(`
`)},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"addLineBefore",description:"Add new line before the current line",exec:function(t){t.selection.clearSelection();var i=t.getCursorPosition();t.selection.moveTo(i.row-1,Number.MAX_VALUE),t.insert(`
`),i.row===0&&t.navigateUp()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"openCommandPallete",description:"Open command palette",bindKey:s("F1","F1"),exec:function(t){t.prompt({$type:"commands"})},readOnly:!0},{name:"modeSelect",description:"Change language mode...",bindKey:s(null,null),exec:function(t){t.prompt({$type:"modes"})},readOnly:!0}];for(var n=1;n<9;n++)m.commands.push({name:"foldToLevel"+n,description:"Fold To Level "+n,level:n,exec:function(t){t.session.foldToLevel(this.level)},scrollIntoView:"center",readOnly:!0})}),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/clipboard"],function(C,m,b){function x(I,T,B){this.$toDestroy=[];var E=I.getContainerElement();this.container=E,this.renderer=I,this.id="editor"+ ++x.$uid,this.commands=new A(n.isMac?"mac":"win",v),typeof document=="object"&&(this.textInput=new t(I.getTextAreaContainer(),this),this.renderer.textarea=this.textInput.getElement(),this.$mouseHandler=new i(this),new e(this)),this.keyBinding=new r(this),this.$search=new o().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(_,P){P._$emitInputEvent.schedule(31)}),this.setSession(T||B&&B.session||new a("")),d.resetOptions(this),B&&this.setOptions(B),d._signal("editor",this)}var p=C("./lib/oop"),l=C("./lib/dom"),s=C("./lib/lang"),n=C("./lib/useragent"),t=C("./keyboard/textinput").TextInput,i=C("./mouse/mouse_handler").MouseHandler,e=C("./mouse/fold_handler").FoldHandler,r=C("./keyboard/keybinding").KeyBinding,a=C("./edit_session").EditSession,o=C("./search").Search,c=C("./range").Range,h=C("./lib/event_emitter").EventEmitter,A=C("./commands/command_manager").CommandManager,v=C("./commands/default_commands").commands,d=C("./config"),g=C("./token_iterator").TokenIterator,y=C("./clipboard"),w=(x.$uid=0,function(){p.implement(this,h),this.$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)},this.curOp=null,this.prevOp={},this.startOperation=function(I){if(this.curOp){if(!I||this.curOp.command)return;this.prevOp=this.curOp}I||(this.previousCommand=null,I={}),this.$opResetTimer.schedule(),this.curOp=this.session.curOp={command:I.command||{},args:I.args,scrollTop:this.renderer.scrollTop},this.curOp.selectionBefore=this.selection.toJSON()},this.endOperation=function(I){if(this.curOp&&this.session){if(I&&I.returnValue===!1||!this.session)return this.curOp=null;if((I!=1||!this.curOp.command||this.curOp.command.name!="mouse")&&(this._signal("beforeEndOperation"),this.curOp)){var I=this.curOp.command,T=I&&I.scrollIntoView;if(T){switch(T){case"center-animate":T="animate";case"center":this.renderer.scrollCursorIntoView(null,.5);break;case"animate":case"cursor":this.renderer.scrollCursorIntoView();break;case"selectionPart":var B=this.selection.getRange(),E=this.renderer.layerConfig;(B.start.row>=E.lastRow||B.end.row<=E.firstRow)&&this.renderer.scrollSelectionIntoView(this.selection.anchor,this.selection.lead)}T=="animate"&&this.renderer.animateScrolling(this.curOp.scrollTop)}I=this.selection.toJSON(),this.curOp.selectionAfter=I,this.$lastSel=this.selection.toJSON(),this.session.getUndoManager().addSelection(I),this.prevOp=this.curOp,this.curOp=null}}},this.$mergeableCommands=["backspace","del","insertstring"],this.$historyTracker=function(I){var T,B,E,_;this.$mergeUndoDeltas&&(T=this.prevOp,B=this.$mergeableCommands,E=T.command&&I.command.name==T.command.name,I.command.name=="insertstring"?(_=I.args,this.mergeNextCommand===void 0&&(this.mergeNextCommand=!0),E=E&&this.mergeNextCommand&&(!/\s/.test(_)||/\s/.test(T.args)),this.mergeNextCommand=!0):E=E&&B.indexOf(I.command.name)!==-1,(E=this.$mergeUndoDeltas!="always"&&2e3<Date.now()-this.sequenceStartTime?!1:E)?this.session.mergeUndoDeltas=!0:B.indexOf(I.command.name)!==-1&&(this.sequenceStartTime=Date.now()))},this.setKeyboardHandler=function(I,T){var B;I&&typeof I=="string"&&I!="ace"?(this.$keybindingId=I,B=this,d.loadModule(["keybinding",I],function(E){B.$keybindingId==I&&B.keyBinding.setKeyboardHandler(E&&E.handler),T&&T()})):(this.$keybindingId=null,this.keyBinding.setKeyboardHandler(I),T&&T())},this.getKeyboardHandler=function(){return this.keyBinding.getKeyboardHandler()},this.setSession=function(I){var T,B;this.session!=I&&(this.curOp&&this.endOperation(),this.curOp={},(T=this.session)&&(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),(B=this.session.getSelection()).off("changeCursor",this.$onCursorChange),B.off("changeSelection",this.$onSelectionChange)),(this.session=I)?(this.$onDocumentChange=this.onDocumentChange.bind(this),I.on("change",this.$onDocumentChange),this.renderer.setSession(I),this.$onChangeMode=this.onChangeMode.bind(this),I.on("changeMode",this.$onChangeMode),this.$onTokenizerUpdate=this.onTokenizerUpdate.bind(this),I.on("tokenizerUpdate",this.$onTokenizerUpdate),this.$onChangeTabSize=this.renderer.onChangeTabSize.bind(this.renderer),I.on("changeTabSize",this.$onChangeTabSize),this.$onChangeWrapLimit=this.onChangeWrapLimit.bind(this),I.on("changeWrapLimit",this.$onChangeWrapLimit),this.$onChangeWrapMode=this.onChangeWrapMode.bind(this),I.on("changeWrapMode",this.$onChangeWrapMode),this.$onChangeFold=this.onChangeFold.bind(this),I.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=I.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(I)),this._signal("changeSession",{session:I,oldSession:T}),this.curOp=null,T&&T._signal("changeEditor",{oldEditor:this}),I&&I._signal("changeEditor",{editor:this}),I&&!I.destroyed&&I.bgTokenizer.scheduleStart())},this.getSession=function(){return this.session},this.setValue=function(I,T){return this.session.doc.setValue(I),T?T==1?this.navigateFileEnd():T==-1&&this.navigateFileStart():this.selectAll(),I},this.getValue=function(){return this.session.getValue()},this.getSelection=function(){return this.selection},this.resize=function(I){this.renderer.onResize(I)},this.setTheme=function(I,T){this.renderer.setTheme(I,T)},this.getTheme=function(){return this.renderer.getTheme()},this.setStyle=function(I){this.renderer.setStyle(I)},this.unsetStyle=function(I){this.renderer.unsetStyle(I)},this.getFontSize=function(){return this.getOption("fontSize")||l.computedStyle(this.container).fontSize},this.setFontSize=function(I){this.setOption("fontSize",I)},this.$highlightBrackets=function(){var I;this.$highlightPending||((I=this).$highlightPending=!0,setTimeout(function(){I.$highlightPending=!1;var T,B,E=I.session;E&&!E.destroyed&&(E.$bracketHighlight&&(E.$bracketHighlight.markerIds.forEach(function(_){E.removeMarker(_)}),E.$bracketHighlight=null),(T=!(T=E.getMatchingBracketRanges(I.getCursorPosition()))&&E.$mode.getMatching?E.$mode.getMatching(I.session):T)&&(B="ace_bracket",Array.isArray(T)?T.length==1&&(B="ace_error_bracket"):T=[T],T.length==2&&(c.comparePoints(T[0].end,T[1].start)==0?T=[c.fromPoints(T[0].start,T[1].end)]:c.comparePoints(T[0].start,T[1].end)==0&&(T=[c.fromPoints(T[1].start,T[0].end)])),E.$bracketHighlight={ranges:T,markerIds:T.map(function(_){return E.addMarker(_,B,"text")})}),I.getHighlightIndentGuides()&&I.renderer.$textLayer.$highlightIndentGuide())},50))},this.$highlightTags=function(){var I;this.$highlightTagPending||((I=this).$highlightTagPending=!0,setTimeout(function(){I.$highlightTagPending=!1;var T=I.session;if(T&&!T.destroyed){var B=I.getCursorPosition(),E=new g(I.session,B.row,B.column),_=E.getCurrentToken();if(_&&/\b(?:tag-open|tag-name)/.test(_.type)){if(_.type.indexOf("tag-open")===-1||(_=E.stepForward())){var P,j=_.value,z=_.value,D=0,Y=E.stepBackward();if(Y.value==="<")for(;Y=_,(_=E.stepForward())&&(_.type.indexOf("tag-name")!==-1?j===(z=_.value)&&(Y.value==="<"?D++:Y.value==="</"&&D--):j===z&&_.value==="/>"&&D--),_&&0<=D;);else{do if(_=Y,Y=E.stepBackward(),_){if(_.type.indexOf("tag-name")!==-1)j===_.value&&(Y.value==="<"?D++:Y.value==="</"&&D--);else if(_.value==="/>"){for(var R=0,H=Y;H;){if(H.type.indexOf("tag-name")!==-1&&H.value===j){D--;break}if(H.value==="<")break;H=E.stepBackward(),R++}for(var G=0;G<R;G++)E.stepForward()}}while(Y&&D<=0);E.stepForward()}_?(B=E.getCurrentTokenRow(),P=E.getCurrentTokenColumn(),B=new c(B,P,B,P+_.value.length),P=T.$backMarkers[T.$tagHighlight],T.$tagHighlight&&P!=null&&B.compareRange(P.range)!==0&&(T.removeMarker(T.$tagHighlight),T.$tagHighlight=null),T.$tagHighlight||(T.$tagHighlight=T.addMarker(B,"ace_bracket","text"))):(T.removeMarker(T.$tagHighlight),T.$tagHighlight=null)}}else T.removeMarker(T.$tagHighlight),T.$tagHighlight=null}},50))},this.focus=function(){this.textInput.focus()},this.isFocused=function(){return this.textInput.isFocused()},this.blur=function(){this.textInput.blur()},this.onFocus=function(I){this.$isFocused||(this.$isFocused=!0,this.renderer.showCursor(),this.renderer.visualizeFocus(),this._emit("focus",I))},this.onBlur=function(I){this.$isFocused&&(this.$isFocused=!1,this.renderer.hideCursor(),this.renderer.visualizeBlur(),this._emit("blur",I))},this.$cursorChange=function(){this.renderer.updateCursor(),this.$highlightBrackets(),this.$highlightTags(),this.$updateHighlightActiveLine()},this.onDocumentChange=function(I){var T=this.session.$useWrapMode,B=I.start.row==I.end.row?I.end.row:1/0;this.renderer.updateLines(I.start.row,B,T),this._signal("change",I),this.$cursorChange()},this.onTokenizerUpdate=function(I){I=I.data,this.renderer.updateLines(I.first,I.last)},this.onScrollTopChange=function(){this.renderer.scrollToY(this.session.getScrollTop())},this.onScrollLeftChange=function(){this.renderer.scrollToX(this.session.getScrollLeft())},this.onCursorChange=function(){this.$cursorChange(),this._signal("changeSelection")},this.$updateHighlightActiveLine=function(){var I,T,B=this.getSession();this.$highlightActiveLine&&(this.$selectionStyle=="line"&&this.selection.isMultiLine()||(I=this.getCursorPosition()),this.renderer.theme&&this.renderer.theme.$selectionColorConflict&&!this.selection.isEmpty()&&(I=!1),!this.renderer.$maxLines||this.session.getLength()!==1||1<this.renderer.$minLines||(I=!1)),B.$highlightLineMarker&&!I?(B.removeMarker(B.$highlightLineMarker.id),B.$highlightLineMarker=null):!B.$highlightLineMarker&&I?((T=new c(I.row,I.column,I.row,1/0)).id=B.addMarker(T,"ace_active-line","screenLine"),B.$highlightLineMarker=T):I&&(B.$highlightLineMarker.start.row=I.row,B.$highlightLineMarker.end.row=I.row,B.$highlightLineMarker.start.column=I.column,B._signal("changeBackMarker"))},this.onSelectionChange=function(I){var T,B,E=this.session,E=(E.$selectionMarker&&E.removeMarker(E.$selectionMarker),E.$selectionMarker=null,this.selection.isEmpty()?this.$updateHighlightActiveLine():(T=this.selection.getRange(),B=this.getSelectionStyle(),E.$selectionMarker=E.addMarker(T,"ace_selection",B)),this.$highlightSelectedWord&&this.$getSelectionHighLightRegexp());this.session.highlight(E),this._signal("changeSelection")},this.$getSelectionHighLightRegexp=function(){var I=this.session,T=this.getSelectionRange();if(!T.isEmpty()&&!T.isMultiLine()){var B=T.start.column,E=T.end.column,I=I.getLine(T.start.row),T=I.substring(B,E);if(!(5e3<T.length)&&/[\w\d]/.test(T)&&(T=this.$search.$assembleRegExp({wholeWord:!0,caseSensitive:!0,needle:T}),I=I.substring(B-1,E+1),T.test(I)))return T}},this.onChangeFrontMarker=function(){this.renderer.updateFrontMarkers()},this.onChangeBackMarker=function(){this.renderer.updateBackMarkers()},this.onChangeBreakpoint=function(){this.renderer.updateBreakpoints()},this.onChangeAnnotation=function(){this.renderer.setAnnotations(this.session.getAnnotations())},this.onChangeMode=function(I){this.renderer.updateText(),this._emit("changeMode",I)},this.onChangeWrapLimit=function(){this.renderer.updateFull()},this.onChangeWrapMode=function(){this.renderer.onResize(!0)},this.onChangeFold=function(){this.$updateHighlightActiveLine(),this.renderer.updateFull()},this.getSelectedText=function(){return this.session.getTextRange(this.getSelectionRange())},this.getCopyText=function(){var I=this.getSelectedText(),T=this.session.doc.getNewLineCharacter(),B=!1;if(!I&&this.$copyWithEmptySelection)for(var B=!0,E=this.selection.getAllRanges(),_=0;_<E.length;_++){var P=E[_];_&&E[_-1].start.row==P.start.row||(I+=this.session.getLine(P.start.row)+T)}var j={text:I};return this._signal("copy",j),y.lineMode=!!B&&j.text,j.text},this.onCopy=function(){this.commands.exec("copy",this)},this.onCut=function(){this.commands.exec("cut",this)},this.onPaste=function(I,T){this.commands.exec("paste",this,{text:I,event:T})},this.$handlePaste=function(B){this._signal("paste",B=typeof B=="string"?{text:B}:B);var T=B.text,B=T===y.lineMode,E=this.session;if(!this.inMultiSelectMode||this.inVirtualSelectionMode)B?E.insert({row:this.selection.lead.row,column:0},T):this.insert(T);else if(B)this.selection.rangeList.ranges.forEach(function(D){E.insert({row:D.start.row,column:0},T)});else{var _=T.split(/\r\n|\r|\n/),P=this.selection.rangeList.ranges,B=!(_.length!=2||_[0]&&_[1]);if(_.length!=P.length||B)return this.commands.exec("insertstring",this,T);for(var j=P.length;j--;){var z=P[j];z.isEmpty()||E.remove(z),E.insert(z.start,_[j])}}},this.execCommand=function(I,T){return this.commands.exec(I,this,T)},this.insert=function(I,z){var B,E=this.session,_=E.getMode(),P=this.getCursorPosition(),j=(!this.getBehavioursEnabled()||z||(B=_.transformAction(E.getState(P.row),"insertion",this,E,I))&&(I===B.text||this.inVirtualSelectionMode||(this.session.mergeUndoDeltas=!1,this.mergeNextCommand=!1),I=B.text),I=="	"&&(I=this.session.getTabString()),this.selection.isEmpty()?this.session.getOverwrite()&&I.indexOf(`
`)==-1&&((j=new c.fromPoints(P,P)).end.column+=I.length,this.session.remove(j)):(j=this.getSelectionRange(),P=this.session.remove(j),this.clearSelection()),I!=`
`&&I!=`\r
`||(D=E.getLine(P.row),P.column>D.search(/\S|$/)&&(z=D.substr(P.column).search(/\S|$/),E.doc.removeInLine(P.row,P.column,P.column+z))),this.clearSelection(),P.column),z=E.getState(P.row),D=E.getLine(P.row),Y=_.checkOutdent(z,D,I);E.insert(P,I),B&&B.selection&&(B.selection.length==2?this.selection.setSelectionRange(new c(P.row,j+B.selection[0],P.row,j+B.selection[1])):this.selection.setSelectionRange(new c(P.row+B.selection[0],B.selection[1],P.row+B.selection[2],B.selection[3]))),this.$enableAutoIndent&&(E.getDocument().isNewLine(I)&&(j=_.getNextLineIndent(z,D.slice(0,P.column),E.getTabString()),E.insert({row:P.row+1,column:0},j)),Y&&_.autoOutdent(z,E,P.row))},this.autoIndent=function(){for(var I,T,B,E,_,P=this.session,j=P.getMode(),z=(B=this.selection.isEmpty()?(T=0,P.doc.getLength()-1):(T=(I=this.getSelectionRange()).start.row,I.end.row),""),D="",Y=P.getTabString(),R=T;R<=B;R++)0<R&&(z=P.getState(R-1),E=P.getLine(R-1),D=j.getNextLineIndent(z,E,Y)),E=P.getLine(R),D!==(_=j.$getIndent(E))&&(0<_.length&&(_=new c(R,0,R,_.length),P.remove(_)),0<D.length&&P.insert({row:R,column:0},D)),j.autoOutdent(z,P,R)},this.onTextInput=function(I,T){if(!T)return this.keyBinding.onTextInput(I);this.startOperation({command:{name:"insertstring"}}),I=this.applyComposition.bind(this,I,T),this.selection.rangeCount?this.forEachSelection(I):I(),this.endOperation()},this.applyComposition=function(I,T){var B;(T.extendLeft||T.extendRight)&&((B=this.selection.getRange()).start.column-=T.extendLeft,B.end.column+=T.extendRight,B.start.column<0&&(B.start.row--,B.start.column+=this.session.getLine(B.start.row).length+1),this.selection.setRange(B),I||B.isEmpty()||this.remove()),!I&&this.selection.isEmpty()||this.insert(I,!0),(T.restoreStart||T.restoreEnd)&&((B=this.selection.getRange()).start.column-=T.restoreStart,B.end.column-=T.restoreEnd,this.selection.setRange(B))},this.onCommandKey=function(I,T,B){return this.keyBinding.onCommandKey(I,T,B)},this.setOverwrite=function(I){this.session.setOverwrite(I)},this.getOverwrite=function(){return this.session.getOverwrite()},this.toggleOverwrite=function(){this.session.toggleOverwrite()},this.setScrollSpeed=function(I){this.setOption("scrollSpeed",I)},this.getScrollSpeed=function(){return this.getOption("scrollSpeed")},this.setDragDelay=function(I){this.setOption("dragDelay",I)},this.getDragDelay=function(){return this.getOption("dragDelay")},this.setSelectionStyle=function(I){this.setOption("selectionStyle",I)},this.getSelectionStyle=function(){return this.getOption("selectionStyle")},this.setHighlightActiveLine=function(I){this.setOption("highlightActiveLine",I)},this.getHighlightActiveLine=function(){return this.getOption("highlightActiveLine")},this.setHighlightGutterLine=function(I){this.setOption("highlightGutterLine",I)},this.getHighlightGutterLine=function(){return this.getOption("highlightGutterLine")},this.setHighlightSelectedWord=function(I){this.setOption("highlightSelectedWord",I)},this.getHighlightSelectedWord=function(){return this.$highlightSelectedWord},this.setAnimatedScroll=function(I){this.renderer.setAnimatedScroll(I)},this.getAnimatedScroll=function(){return this.renderer.getAnimatedScroll()},this.setShowInvisibles=function(I){this.renderer.setShowInvisibles(I)},this.getShowInvisibles=function(){return this.renderer.getShowInvisibles()},this.setDisplayIndentGuides=function(I){this.renderer.setDisplayIndentGuides(I)},this.getDisplayIndentGuides=function(){return this.renderer.getDisplayIndentGuides()},this.setHighlightIndentGuides=function(I){this.renderer.setHighlightIndentGuides(I)},this.getHighlightIndentGuides=function(){return this.renderer.getHighlightIndentGuides()},this.setShowPrintMargin=function(I){this.renderer.setShowPrintMargin(I)},this.getShowPrintMargin=function(){return this.renderer.getShowPrintMargin()},this.setPrintMarginColumn=function(I){this.renderer.setPrintMarginColumn(I)},this.getPrintMarginColumn=function(){return this.renderer.getPrintMarginColumn()},this.setReadOnly=function(I){this.setOption("readOnly",I)},this.getReadOnly=function(){return this.getOption("readOnly")},this.setBehavioursEnabled=function(I){this.setOption("behavioursEnabled",I)},this.getBehavioursEnabled=function(){return this.getOption("behavioursEnabled")},this.setWrapBehavioursEnabled=function(I){this.setOption("wrapBehavioursEnabled",I)},this.getWrapBehavioursEnabled=function(){return this.getOption("wrapBehavioursEnabled")},this.setShowFoldWidgets=function(I){this.setOption("showFoldWidgets",I)},this.getShowFoldWidgets=function(){return this.getOption("showFoldWidgets")},this.setFadeFoldWidgets=function(I){this.setOption("fadeFoldWidgets",I)},this.getFadeFoldWidgets=function(){return this.getOption("fadeFoldWidgets")},this.remove=function(_){this.selection.isEmpty()&&(_=="left"?this.selection.selectLeft():this.selection.selectRight());var T,B,E,_=this.getSelectionRange();this.getBehavioursEnabled()&&(B=(T=this.session).getState(_.start.row),B=T.getMode().transformAction(B,"deletion",this,T,_),_.end.column===0&&(E=T.getTextRange(_))[E.length-1]==`
`&&(E=T.getLine(_.end.row),/^\s+$/.test(E)&&(_.end.column=E.length)),B&&(_=B)),this.session.remove(_),this.clearSelection()},this.removeWordRight=function(){this.selection.isEmpty()&&this.selection.selectWordRight(),this.session.remove(this.getSelectionRange()),this.clearSelection()},this.removeWordLeft=function(){this.selection.isEmpty()&&this.selection.selectWordLeft(),this.session.remove(this.getSelectionRange()),this.clearSelection()},this.removeToLineStart=function(){this.selection.isEmpty()&&this.selection.selectLineStart(),this.selection.isEmpty()&&this.selection.selectLeft(),this.session.remove(this.getSelectionRange()),this.clearSelection()},this.removeToLineEnd=function(){this.selection.isEmpty()&&this.selection.selectLineEnd();var I=this.getSelectionRange();I.start.column==I.end.column&&I.start.row==I.end.row&&(I.end.column=0,I.end.row++),this.session.remove(I),this.clearSelection()},this.splitLine=function(){this.selection.isEmpty()||(this.session.remove(this.getSelectionRange()),this.clearSelection());var I=this.getCursorPosition();this.insert(`
`),this.moveCursorToPosition(I)},this.transposeLetters=function(){var I,T,B,E;!this.selection.isEmpty()||(T=(I=this.getCursorPosition()).column)!==0&&(E=T<(E=this.session.getLine(I.row)).length?(B=E.charAt(T)+E.charAt(T-1),new c(I.row,T-1,I.row,T+1)):(B=E.charAt(T-1)+E.charAt(T-2),new c(I.row,T-2,I.row,T)),this.session.replace(E,B),this.session.selection.moveToPosition(E.end))},this.toLowerCase=function(){var I=this.getSelectionRange(),T=(this.selection.isEmpty()&&this.selection.selectWord(),this.getSelectionRange()),B=this.session.getTextRange(T);this.session.replace(T,B.toLowerCase()),this.selection.setSelectionRange(I)},this.toUpperCase=function(){var I=this.getSelectionRange(),T=(this.selection.isEmpty()&&this.selection.selectWord(),this.getSelectionRange()),B=this.session.getTextRange(T);this.session.replace(T,B.toUpperCase()),this.selection.setSelectionRange(I)},this.indent=function(){var I=this.session,T=this.getSelectionRange();if(!(T.start.row<T.end.row)){if(T.start.column<T.end.column){var B,P=I.getTextRange(T);if(!/^\s+$/.test(P))return B=this.$getSelectedRows(),void I.indentRows(B.first,B.last,"	")}var E=I.getLine(T.start.row),P=T.start,_=I.getTabSize(),P=I.documentToScreenColumn(P.row,P.column);if(this.session.getUseSoftTabs())var j=_-P%_,z=s.stringRepeat(" ",j);else{for(j=P%_;E[T.start.column-1]==" "&&j;)T.start.column--,j--;this.selection.setSelectionRange(T),z="	"}return this.insert(z)}B=this.$getSelectedRows(),I.indentRows(B.first,B.last,"	")},this.blockIndent=function(){var I=this.$getSelectedRows();this.session.indentRows(I.first,I.last,"	")},this.blockOutdent=function(){var I=this.session.getSelection();this.session.outdentRows(I.getRange())},this.sortLines=function(){for(var I=this.$getSelectedRows(),T=this.session,B=[],E=I.first;E<=I.last;E++)B.push(T.getLine(E));B.sort(function(j,z){return j.toLowerCase()<z.toLowerCase()?-1:j.toLowerCase()>z.toLowerCase()?1:0});for(var _=new c(0,0,0,0),E=I.first;E<=I.last;E++){var P=T.getLine(E);_.start.row=E,_.end.row=E,_.end.column=P.length,T.replace(_,B[E-I.first])}},this.toggleCommentLines=function(){var I=this.session.getState(this.getCursorPosition().row),T=this.$getSelectedRows();this.session.getMode().toggleCommentLines(I,this.session,T.first,T.last)},this.toggleBlockComment=function(){var I=this.getCursorPosition(),T=this.session.getState(I.row),B=this.getSelectionRange();this.session.getMode().toggleBlockComment(T,this.session,B,I)},this.getNumberAt=function(I,T){for(var B=/[\-]?[0-9]+(?:\.[0-9]+)?/g,E=(B.lastIndex=0,this.session.getLine(I));B.lastIndex<T;){var _=B.exec(E);if(_.index<=T&&_.index+_[0].length>=T)return{value:_[0],start:_.index,end:_.index+_[0].length}}return null},this.modifyNumber=function(I){var T,B,E,_=this.selection.getCursor().row,P=this.selection.getCursor().column,j=new c(_,P-1,_,P),j=this.session.getTextRange(j);!isNaN(parseFloat(j))&&isFinite(j)?(j=this.getNumberAt(_,P))&&(E=0<=j.value.indexOf(".")?j.start+j.value.indexOf(".")+1:j.end,T=j.start+j.value.length-E,B=parseFloat(j.value),B*=Math.pow(10,T),E!==j.end&&P<E?I*=Math.pow(10,j.end-P-1):I*=Math.pow(10,j.end-P),E=(B=(B+=I)/Math.pow(10,T)).toFixed(T),I=new c(_,j.start,_,j.end),this.session.replace(I,E),this.moveCursorTo(_,Math.max(j.start+1,P+E.length-j.value.length))):this.toggleWord()},this.$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"],["&&","||"],["==","!="]],this.toggleWord=function(){for(var I,T=this.selection.getCursor().row,B=this.selection.getCursor().column,E=(this.selection.selectWord(),this.getSelectedText()),_=this.selection.getWordRange().start.column,P=E.replace(/([a-z]+|[A-Z]+)(?=[A-Z_]|$)/g,"$1 ").split(/\s/),j=B-_-1,z=(j<0&&(j=0),0),D=this,Y=(E.match(/[A-Za-z0-9_]+/)&&P.forEach(function($,M){I=z+$.length,z<=j&&j<=I&&(E=$,D.selection.clearSelection(),D.moveCursorTo(T,z+_),D.selection.selectTo(T,I+_)),z=I}),this.$toggleWordPairs),R=0;R<Y.length;R++)for(var H=Y[R],G=0;G<=1;G++){var f=+!G,S=E.match(new RegExp("^\\s?_?("+s.escapeRegExp(H[G])+")\\s?$","i"));S&&E.match(new RegExp("([_]|^|\\s)("+s.escapeRegExp(S[1])+")($|\\s)","g"))&&(S=E.replace(new RegExp(s.escapeRegExp(H[G]),"i"),function($){var M=H[f];return $.toUpperCase()==$?M=M.toUpperCase():$.charAt(0).toUpperCase()==$.charAt(0)&&(M=M.substr(0,0)+H[f].charAt(0).toUpperCase()+M.substr(1)),M}),this.insert(S))}},this.removeLines=function(){var I=this.$getSelectedRows();this.session.removeFullLines(I.first,I.last),this.clearSelection()},this.duplicateSelection=function(){var I,T=this.selection,B=this.session,E=T.getRange(),_=T.isBackwards();E.isEmpty()?(I=E.start.row,B.duplicateLines(I,I)):(I=_?E.start:E.end,B=B.insert(I,B.getTextRange(E),!1),E.start=I,E.end=B,T.setSelectionRange(E,_))},this.moveLinesDown=function(){this.$moveLines(1,!1)},this.moveLinesUp=function(){this.$moveLines(-1,!1)},this.moveText=function(I,T,B){return this.session.moveText(I,T,B)},this.copyLinesUp=function(){this.$moveLines(-1,!0)},this.copyLinesDown=function(){this.$moveLines(1,!0)},this.$moveLines=function(I,T){var B=this.selection;if(!B.inMultiSelectMode||this.inVirtualSelectionMode){var E=B.toOrientedRange(),_=this.$getSelectedRows(E),P=this.session.$moveLines(_.first,_.last,T?0:I);E.moveBy(P=T&&I==-1?0:P,0),B.fromOrientedRange(E)}else{for(var j=B.rangeList.ranges,z=(B.rangeList.detach(this.session),this.inVirtualSelectionMode=!0,0),D=0,Y=j.length,R=0;R<Y;R++){for(var H=R,G=(j[R].moveBy(z,0),(_=this.$getSelectedRows(j[R])).first),f=_.last;++R<Y;){D&&j[R].moveBy(D,0);var S=this.$getSelectedRows(j[R]);if(T&&S.first!=f||!T&&S.first>f+1)break;f=S.last}for(R--,z=this.session.$moveLines(G,f,T?0:I),T&&I==-1&&(H=R+1);H<=R;)j[H].moveBy(z,0),H++;D+=z=T?z:0}B.fromOrientedRange(B.ranges[0]),B.rangeList.attach(this.session),this.inVirtualSelectionMode=!1}},this.$getSelectedRows=function(I){return I=(I||this.getSelectionRange()).collapseRows(),{first:this.session.getRowFoldStart(I.start.row),last:this.session.getRowFoldEnd(I.end.row)}},this.onCompositionStart=function(I){this.renderer.showComposition(I)},this.onCompositionUpdate=function(I){this.renderer.setCompositionText(I)},this.onCompositionEnd=function(){this.renderer.hideComposition()},this.getFirstVisibleRow=function(){return this.renderer.getFirstVisibleRow()},this.getLastVisibleRow=function(){return this.renderer.getLastVisibleRow()},this.isRowVisible=function(I){return I>=this.getFirstVisibleRow()&&I<=this.getLastVisibleRow()},this.isRowFullyVisible=function(I){return I>=this.renderer.getFirstFullyVisibleRow()&&I<=this.renderer.getLastFullyVisibleRow()},this.$getVisibleRowCount=function(){return this.renderer.getScrollBottomRow()-this.renderer.getScrollTopRow()+1},this.$moveByPage=function(P,T){var B=this.renderer,E=this.renderer.layerConfig,_=P*Math.floor(E.height/E.lineHeight),P=(T===!0?this.selection.$moveSelection(function(){this.moveCursorBy(_,0)}):T===!1&&(this.selection.moveCursorBy(_,0),this.selection.clearSelection()),B.scrollTop);B.scrollBy(0,_*E.lineHeight),T!=null&&B.scrollCursorIntoView(null,.5),B.animateScrolling(P)},this.selectPageDown=function(){this.$moveByPage(1,!0)},this.selectPageUp=function(){this.$moveByPage(-1,!0)},this.gotoPageDown=function(){this.$moveByPage(1,!1)},this.gotoPageUp=function(){this.$moveByPage(-1,!1)},this.scrollPageDown=function(){this.$moveByPage(1)},this.scrollPageUp=function(){this.$moveByPage(-1)},this.scrollToRow=function(I){this.renderer.scrollToRow(I)},this.scrollToLine=function(I,T,B,E){this.renderer.scrollToLine(I,T,B,E)},this.centerSelection=function(){var I=this.getSelectionRange(),I={row:Math.floor(I.start.row+(I.end.row-I.start.row)/2),column:Math.floor(I.start.column+(I.end.column-I.start.column)/2)};this.renderer.alignCursor(I,.5)},this.getCursorPosition=function(){return this.selection.getCursor()},this.getCursorPositionScreen=function(){return this.session.documentToScreenPosition(this.getCursorPosition())},this.getSelectionRange=function(){return this.selection.getRange()},this.selectAll=function(){this.selection.selectAll()},this.clearSelection=function(){this.selection.clearSelection()},this.moveCursorTo=function(I,T){this.selection.moveCursorTo(I,T)},this.moveCursorToPosition=function(I){this.selection.moveCursorToPosition(I)},this.jumpToMatching=function(I,T){var B=this.getCursorPosition(),E=new g(this.session,B.row,B.column),_=E.getCurrentToken(),P=_||E.stepForward();if(P){var j,z,D,Y=!1,R={},H=B.column-P.start,G={")":"(","(":"(","]":"[","[":"[","{":"{","}":"{"};do if(P.value.match(/[{}()\[\]]/g)){for(;H<P.value.length&&!Y;H++)if(G[P.value[H]])switch(z=G[P.value[H]]+"."+P.type.replace("rparen","lparen"),isNaN(R[z])&&(R[z]=0),P.value[H]){case"(":case"[":case"{":R[z]++;break;case")":case"]":case"}":R[z]--,R[z]===-1&&(j="bracket",Y=!0)}}else P.type.indexOf("tag-name")!==-1&&(isNaN(R[P.value])&&(R[P.value]=0),_.value==="<"?R[P.value]++:_.value==="</"&&R[P.value]--,R[P.value]===-1&&(j="tag",Y=!0));while(Y||(_=P,P=E.stepForward(),H=0),P&&!Y);if(j){if(j==="bracket")(f=this.session.getBracketRange(B))||(D=(f=new c(E.getCurrentTokenRow(),E.getCurrentTokenColumn()+H-1,E.getCurrentTokenRow(),E.getCurrentTokenColumn()+H-1)).start,(T||D.row===B.row&&Math.abs(D.column-B.column)<2)&&(f=this.session.getBracketRange(D)));else if(j==="tag"){if(!P||P.type.indexOf("tag-name")===-1)return;var f,S=P.value;if((f=new c(E.getCurrentTokenRow(),E.getCurrentTokenColumn()-2,E.getCurrentTokenRow(),E.getCurrentTokenColumn()-2)).compare(B.row,B.column)===0)for(Y=!1;P=_,(_=E.stepBackward())&&(_.type.indexOf("tag-close")!==-1&&f.setEnd(E.getCurrentTokenRow(),E.getCurrentTokenColumn()+1),P.value===S&&P.type.indexOf("tag-name")!==-1&&(_.value==="<"?R[S]++:_.value==="</"&&R[S]--,R[S]===0&&(Y=!0))),_&&!Y;);P&&P.type.indexOf("tag-name")&&(D=f.start).row==B.row&&Math.abs(D.column-B.column)<2&&(D=f.end)}(D=f&&f.cursor||D)&&(I?f&&T?this.selection.setRange(f):f&&f.isEqual(this.getSelectionRange())?this.clearSelection():this.selection.selectTo(D.row,D.column):this.selection.moveTo(D.row,D.column))}}},this.gotoLine=function(I,T,B){this.selection.clearSelection(),this.session.unfold({row:I-1,column:T||0}),this.exitMultiSelectMode&&this.exitMultiSelectMode(),this.moveCursorTo(I-1,T||0),this.isRowFullyVisible(I-1)||this.scrollToLine(I-1,!0,B)},this.navigateTo=function(I,T){this.selection.moveTo(I,T)},this.navigateUp=function(I){var T;if(this.selection.isMultiLine()&&!this.selection.isBackwards())return T=this.selection.anchor.getPosition(),this.moveCursorToPosition(T);this.selection.clearSelection(),this.selection.moveCursorBy(-I||-1,0)},this.navigateDown=function(I){var T;if(this.selection.isMultiLine()&&this.selection.isBackwards())return T=this.selection.anchor.getPosition(),this.moveCursorToPosition(T);this.selection.clearSelection(),this.selection.moveCursorBy(I||1,0)},this.navigateLeft=function(I){if(this.selection.isEmpty())for(I=I||1;I--;)this.selection.moveCursorLeft();else{var T=this.getSelectionRange().start;this.moveCursorToPosition(T)}this.clearSelection()},this.navigateRight=function(I){if(this.selection.isEmpty())for(I=I||1;I--;)this.selection.moveCursorRight();else{var T=this.getSelectionRange().end;this.moveCursorToPosition(T)}this.clearSelection()},this.navigateLineStart=function(){this.selection.moveCursorLineStart(),this.clearSelection()},this.navigateLineEnd=function(){this.selection.moveCursorLineEnd(),this.clearSelection()},this.navigateFileEnd=function(){this.selection.moveCursorFileEnd(),this.clearSelection()},this.navigateFileStart=function(){this.selection.moveCursorFileStart(),this.clearSelection()},this.navigateWordRight=function(){this.selection.moveCursorWordRight(),this.clearSelection()},this.navigateWordLeft=function(){this.selection.moveCursorWordLeft(),this.clearSelection()},this.replace=function(I,B){B&&this.$search.set(B);var B=this.$search.find(this.session),E=0;return B&&(this.$tryReplace(B,I)&&(E=1),this.selection.setSelectionRange(B),this.renderer.scrollSelectionIntoView(B.start,B.end)),E},this.replaceAll=function(I,T){T&&this.$search.set(T);var B=this.$search.findAll(this.session),E=0;if(B.length){T=this.getSelectionRange(),this.selection.moveTo(0,0);for(var _=B.length-1;0<=_;--_)this.$tryReplace(B[_],I)&&E++;this.selection.setSelectionRange(T)}return E},this.$tryReplace=function(I,T){var B=this.session.getTextRange(I);return(T=this.$search.replace(B,T))!==null?(I.end=this.session.replace(I,T),I):null},this.getLastSearchOptions=function(){return this.$search.getOptions()},this.find=function(_,T,B){T=T||{},typeof _=="string"||_ instanceof RegExp?T.needle=_:typeof _=="object"&&p.mixin(T,_);var E=this.selection.getRange(),_=(T.needle==null&&((_=this.session.getTextRange(E)||this.$search.$options.needle)||(E=this.session.getWordRange(E.start.row,E.start.column),_=this.session.getTextRange(E)),this.$search.set({needle:_})),this.$search.set(T),T.start||this.$search.set({start:E}),this.$search.find(this.session));return T.preventScroll?_:_?(this.revealRange(_,B),_):(T.backwards?E.start=E.end:E.end=E.start,void this.selection.setRange(E))},this.findNext=function(I,T){this.find({skipCurrent:!0,backwards:!1},I,T)},this.findPrevious=function(I,T){this.find(I,{skipCurrent:!0,backwards:!0},T)},this.revealRange=function(I,T){this.session.unfold(I),this.selection.setSelectionRange(I);var B=this.renderer.scrollTop;this.renderer.scrollSelectionIntoView(I.start,I.end,.5),T!==!1&&this.renderer.animateScrolling(B)},this.undo=function(){this.session.getUndoManager().undo(this.session),this.renderer.scrollCursorIntoView(null,.5)},this.redo=function(){this.session.getUndoManager().redo(this.session),this.renderer.scrollCursorIntoView(null,.5)},this.destroy=function(){this.$toDestroy&&(this.$toDestroy.forEach(function(I){I.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()},this.setAutoScrollEditorIntoView=function(I){var T,B,E,_,P,j,z;I&&(E=!1,(B=this).$scrollAnchor||(this.$scrollAnchor=document.createElement("div")),(_=this.$scrollAnchor).style.cssText="position:absolute",this.container.insertBefore(_,this.container.firstChild),P=this.on("changeSelection",function(){E=!0}),j=this.renderer.on("beforeRender",function(){E&&(T=B.renderer.container.getBoundingClientRect())}),z=this.renderer.on("afterRender",function(){var D,Y,R;E&&T&&(B.isFocused()||B.searchBox&&B.searchBox.isFocused())&&(D=(Y=B.renderer).$cursorLayer.$pixelPos,Y=Y.layerConfig,R=D.top-Y.offset,(E=0<=D.top&&R+T.top<0||!(D.top<Y.height&&D.top+T.top+Y.lineHeight>window.innerHeight)&&null)!=null&&(_.style.top=R+"px",_.style.left=D.left+"px",_.style.height=Y.lineHeight+"px",_.scrollIntoView(E)),E=T=null)}),this.setAutoScrollEditorIntoView=function(D){D||(delete this.setAutoScrollEditorIntoView,this.off("changeSelection",P),this.renderer.off("afterRender",z),this.renderer.off("beforeRender",j))})},this.$resetCursorStyle=function(){var I=this.$cursorStyle||"ace",T=this.renderer.$cursorLayer;T&&(T.setSmoothBlinking(/smooth/.test(I)),T.isBlinking=!this.$readOnly&&I!="wide",l.setCssClass(T.element,"ace_slim-cursors",/slim/.test(I)))},this.prompt=function(I,T,B){var E=this;d.loadModule("./ext/prompt",function(_){_.prompt(E,I,T,B)})}}.call(x.prototype),d.defineOptions(x.prototype,"editor",{selectionStyle:{set:function(I){this.onSelectionChange(),this._signal("changeSelectionStyle",{data:I})},initialValue:"line"},highlightActiveLine:{set:function(){this.$updateHighlightActiveLine()},initialValue:!0},highlightSelectedWord:{set:function(I){this.$onSelectionChange()},initialValue:!0},readOnly:{set:function(I){this.textInput.setReadOnly(I),this.$resetCursorStyle()},initialValue:!1},copyWithEmptySelection:{set:function(I){this.textInput.setCopyWithEmptySelection(I)},initialValue:!1},cursorStyle:{set:function(I){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(I){this.setAutoScrollEditorIntoView(I)}},keyboardHandler:{set:function(I){this.setKeyboardHandler(I)},get:function(){return this.$keybindingId},handlesSet:!0},value:{set:function(I){this.session.setValue(I)},get:function(){return this.getValue()},handlesSet:!0,hidden:!0},session:{set:function(I){this.setSession(I)},get:function(){return this.session},handlesSet:!0,hidden:!0},showLineNumbers:{set:function(I){this.renderer.$gutterLayer.setShowLineNumbers(I),this.renderer.$loop.schedule(this.renderer.CHANGE_GUTTER),I&&this.$relativeLineNumbers?w.attach(this):w.detach(this)},initialValue:!0},relativeLineNumbers:{set:function(I){this.$showLineNumbers&&I?w.attach(this):w.detach(this)}},placeholder:{set:function(I){this.$updatePlaceholder||(this.$updatePlaceholder=function(){var T=this.session&&(this.renderer.$composition||this.getValue());T&&this.renderer.placeholderNode?(this.renderer.off("afterRender",this.$updatePlaceholder),l.removeCssClass(this.container,"ace_hasPlaceholder"),this.renderer.placeholderNode.remove(),this.renderer.placeholderNode=null):T||this.renderer.placeholderNode?!T&&this.renderer.placeholderNode&&(this.renderer.placeholderNode.textContent=this.$placeholder||""):(this.renderer.on("afterRender",this.$updatePlaceholder),l.addCssClass(this.container,"ace_hasPlaceholder"),(T=l.createElement("div")).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()}},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",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"}),{getText:function(I,T){return(Math.abs(I.selection.lead.row-T)||T+1+(T<9?"\xB7":""))+""},getWidth:function(I,T,B){return Math.max(T.toString().length,(B.lastRow+1).toString().length,2)*B.characterWidth},update:function(I,T){T.renderer.$loop.schedule(T.renderer.CHANGE_GUTTER)},attach:function(I){I.renderer.$gutterLayer.$renderer=this,I.on("changeSelection",this.update),this.update(null,I)},detach:function(I){I.renderer.$gutterLayer.$renderer==this&&(I.renderer.$gutterLayer.$renderer=null),I.off("changeSelection",this.update),this.update(null,I)}});m.Editor=x}),ace.define("ace/undomanager",["require","exports","module","ace/range"],function(C,m,b){function x(){this.$maxRev=0,this.$fromUndo=!1,this.$undoDepth=1/0,this.reset()}(function(){this.addSession=function(o){this.$session=o},this.add=function(o,c,h){this.$fromUndo||o!=this.$lastDelta&&(this.$keepRedoStack||(this.$redoStack.length=0),c!==!1&&this.lastDeltas||(this.lastDeltas=[],(c=this.$undoStack.length)>this.$undoDepth-1&&this.$undoStack.splice(0,c-this.$undoDepth+1),this.$undoStack.push(this.lastDeltas),o.id=this.$rev=++this.$maxRev),o.action!="remove"&&o.action!="insert"||(this.$lastDelta=o),this.lastDeltas.push(o))},this.addSelection=function(o,c){this.selections.push({value:o,rev:c||this.$rev})},this.startNewGroup=function(){return this.lastDeltas=null,this.$rev},this.markIgnored=function(o,c){c==null&&(c=this.$rev+1);for(var h=this.$undoStack,A=h.length;A--;){var v=h[A][0];if(v.id<=o)break;v.id<c&&(v.ignore=!0)}this.lastDeltas=null},this.getSelection=function(o,c){for(var h=this.selections,A=h.length;A--;){var v=h[A];if(v.rev<o)return v=c?h[A+1]:v}},this.getRevision=function(){return this.$rev},this.getDeltas=function(o,c){c==null&&(c=this.$rev+1);for(var h=this.$undoStack,A=null,v=0,d=h.length;d--;){var g=h[d][0];if(g.id<c&&!A&&(A=d+1),g.id<=o){v=d+1;break}}return h.slice(v,A)},this.getChangedRanges=function(o,c){c==null&&this.$rev},this.getChangedLines=function(o,c){c==null&&this.$rev},this.undo=function(o,c){this.lastDeltas=null;var h,A=this.$undoStack;if(function(v,d){for(var g=d;g--;){var y=v[g];if(y&&!y[0].ignore){for(;g<d-1;){var w=function(I,T){for(var B=I.length;B--;)for(var E=0;E<T.length;E++)if(!i(I[B],T[E])){for(;B<I.length;){for(;E--;)i(T[E],I[B]);E=T.length,B++}return[I,T]}return I.selectionBefore=T.selectionBefore=I.selectionAfter=T.selectionAfter=null,[T,I]}(v[g],v[g+1]);v[g]=w[0],v[g+1]=w[1],g++}return 1}}}(A,A.length))return o=o||this.$session,this.$redoStackBaseRev!==this.$rev&&this.$redoStack.length&&(this.$redoStack=[]),this.$fromUndo=!0,h=null,(A=A.pop())&&(h=o.undoChanges(A,c),this.$redoStack.push(A),this.$syncRev()),this.$fromUndo=!1,h},this.redo=function(o,c){if(this.lastDeltas=null,o=o||this.$session,this.$fromUndo=!0,this.$redoStackBaseRev!=this.$rev){for(var _=this.getDeltas(this.$redoStackBaseRev,this.$rev+1),h=this.$redoStack,A=_,v=0;v<A.length;v++)for(var d=A[v],g=0;g<d.length;g++){y=void 0,w=void 0,I=void 0,T=void 0,B=void 0,E=void 0;var y=h,w=d[g];w=function(z){return{start:s(z.start),end:s(z.end),action:z.action,lines:z.lines.slice()}}(w);for(var I=y.length;I--;){for(var T=y[I],B=0;B<T.length;B++){var E=function(z,D){var Y,R,H=z.action=="insert",G=D.action=="insert";if(H&&G)l(z.start,D.start)<0?e(D,z,1):e(z,D,1);else if(H&&!G)0<=l(z.start,D.end)?e(z,D,-1):(l(z.start,D.start)<=0||e(z,p.fromPoints(D.start,z.start),-1),e(D,z,1));else if(!H&&G)0<=l(D.start,z.end)?e(D,z,-1):(l(D.start,z.start)<=0||e(D,p.fromPoints(z.start,D.start),-1),e(z,D,1));else if(!H&&!G)if(0<=l(D.start,z.end))e(D,z,-1);else{if(!(l(D.end,z.start)<=0))return l(z.start,D.start)<0&&(z=a(Y=z,D.start)),0<l(z.end,D.end)&&(R=a(z,D.end)),r(D.end,z.start,z.end,-1),R&&!Y&&(z.lines=R.lines,z.start=R.start,z.end=R.end,R=z),[D,Y,R].filter(Boolean);e(z,D,-1)}return[D,z]}(T[B],w);w=E[0],E.length!=2&&(E[2]?(T.splice(B+1,1,E[1],E[2]),B++):E[1]||(T.splice(B,1),B--))}T.length||y.splice(I,1)}}this.$redoStackBaseRev=this.$rev,this.$redoStack.forEach(function(j){j[0].id=++this.$maxRev},this)}var _=this.$redoStack.pop(),P=null;return _&&(P=o.redoChanges(_,c),this.$undoStack.push(_),this.$syncRev()),this.$fromUndo=!1,P},this.$syncRev=function(){var o=this.$undoStack,o=o[o.length-1],o=o&&o[0].id||0;this.$redoStackBaseRev=o,this.$rev=o},this.reset=function(){this.lastDeltas=null,this.$lastDelta=null,this.$undoStack=[],this.$redoStack=[],this.$rev=0,this.mark=0,this.$redoStackBaseRev=this.$rev,this.selections=[]},this.canUndo=function(){return 0<this.$undoStack.length},this.canRedo=function(){return 0<this.$redoStack.length},this.bookmark=function(o){o==null&&(o=this.$rev),this.mark=o},this.isAtBookmark=function(){return this.$rev===this.mark},this.toJSON=function(){},this.fromJSON=function(){},this.hasUndo=this.canUndo,this.hasRedo=this.canRedo,this.isClean=this.isAtBookmark,this.markClean=this.bookmark,this.$prettyPrint=function(o){return o?n(o):n(this.$undoStack)+`
---
`+n(this.$redoStack)}}).call(x.prototype);var p=C("./range").Range,l=p.comparePoints;p.comparePoints;function s(o){return{row:o.row,column:o.column}}function n(o){var c;return o=o||this,Array.isArray(o)?o.map(n).join(`
`):(c="",o.action?(c=o.action=="insert"?"+":"-",c+="["+o.lines+"]"):o.value&&(c=Array.isArray(o.value)?o.value.map(t).join(`
`):t(o.value)),o.start&&(c+=t(o)),(o.id||o.rev)&&(c+="	("+(o.id||o.rev)+")"),c)}function t(o){return o.start.row+":"+o.start.column+"=>"+o.end.row+":"+o.end.column}function i(o,c){var h=o.action=="insert",A=c.action=="insert";if(h&&A)if(0<=l(c.start,o.end))e(c,o,-1);else{if(!(l(c.start,o.start)<=0))return;e(o,c,1)}else if(h&&!A)if(0<=l(c.start,o.end))e(c,o,-1);else{if(!(l(c.end,o.start)<=0))return;e(o,c,-1)}else if(!h&&A)if(0<=l(c.start,o.start))e(c,o,1);else{if(!(l(c.start,o.start)<=0))return;e(o,c,1)}else if(!h&&!A)if(0<=l(c.start,o.start))e(c,o,1);else{if(!(l(c.end,o.start)<=0))return;e(o,c,-1)}return 1}function e(o,c,h){r(o.start,c.start,c.end,h),r(o.end,c.start,c.end,h)}function r(o,c,h,A){o.row==(A==1?c:h).row&&(o.column+=A*(h.column-c.column)),o.row+=A*(h.row-c.row)}function a(o,c){var h=o.lines,A=o.end,d=(o.end=s(c),o.end.row-o.start.row),v=h.splice(d,h.length),d=d?c.column:c.column-o.start.column;return h.push(v[0].substring(0,d)),v[0]=v[0].substr(d),{start:s(c),end:A,lines:v,action:o.action}}m.UndoManager=x}),ace.define("ace/layer/lines",["require","exports","module","ace/lib/dom"],function(C,m,b){function x(l,s){this.element=l,this.canvasHeight=s||5e5,this.element.style.height=2*this.canvasHeight+"px",this.cells=[],this.cellCache=[],this.$offsetCoefficient=0}var p=C("../lib/dom");(function(){this.moveContainer=function(l){p.translate(this.element,0,-(l.firstRowScreen*l.lineHeight%this.canvasHeight)-l.offset*this.$offsetCoefficient)},this.pageChanged=function(l,s){return Math.floor(l.firstRowScreen*l.lineHeight/this.canvasHeight)!==Math.floor(s.firstRowScreen*s.lineHeight/this.canvasHeight)},this.computeLineTop=function(l,s,n){var t=s.firstRowScreen*s.lineHeight,t=Math.floor(t/this.canvasHeight);return n.documentToScreenRow(l,0)*s.lineHeight-t*this.canvasHeight},this.computeLineHeight=function(l,s,n){return s.lineHeight*n.getRowLineCount(l)},this.getLength=function(){return this.cells.length},this.get=function(l){return this.cells[l]},this.shift=function(){this.$cacheCell(this.cells.shift())},this.pop=function(){this.$cacheCell(this.cells.pop())},this.push=function(l){if(Array.isArray(l)){this.cells.push.apply(this.cells,l);for(var s=p.createFragment(this.element),n=0;n<l.length;n++)s.appendChild(l[n].element);this.element.appendChild(s)}else this.cells.push(l),this.element.appendChild(l.element)},this.unshift=function(l){if(Array.isArray(l)){this.cells.unshift.apply(this.cells,l);for(var s=p.createFragment(this.element),n=0;n<l.length;n++)s.appendChild(l[n].element);this.element.firstChild?this.element.insertBefore(s,this.element.firstChild):this.element.appendChild(s)}else this.cells.unshift(l),this.element.insertAdjacentElement("afterbegin",l.element)},this.last=function(){return this.cells.length?this.cells[this.cells.length-1]:null},this.$cacheCell=function(l){l&&(l.element.remove(),this.cellCache.push(l))},this.createCell=function(l,s,n,t){var i,e=this.cellCache.pop();return e||(i=p.createElement("div"),t&&t(i),this.element.appendChild(i),e={element:i,text:"",row:l}),e.row=l,e}}).call(x.prototype),m.Lines=x}),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(C,m,b){function x(e){this.element=p.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 t(this.element),this.$lines.$offsetCoefficient=1}var p=C("../lib/dom"),l=C("../lib/oop"),s=C("../lib/lang"),n=C("../lib/event_emitter").EventEmitter,t=C("./lines").Lines;function i(e){var r=document.createTextNode(""),r=(e.appendChild(r),p.createElement("span"));return e.appendChild(r),e}(function(){l.implement(this,n),this.setSession=function(e){this.session&&this.session.off("change",this.$updateAnnotations),(this.session=e)&&e.on("change",this.$updateAnnotations)},this.addGutterDecoration=function(e,r){window.console&&console.warn&&console.warn("deprecated use session.addGutterDecoration"),this.session.addGutterDecoration(e,r)},this.removeGutterDecoration=function(e,r){window.console&&console.warn&&console.warn("deprecated use session.removeGutterDecoration"),this.session.removeGutterDecoration(e,r)},this.setAnnotations=function(e){this.$annotations=[];for(var r=0;r<e.length;r++){var c=e[r],o=c.row,a=(a=this.$annotations[o])||(this.$annotations[o]={text:[]}),o=(o=c.text)?s.escapeHTML(o):c.html||"",o=(a.text.indexOf(o)===-1&&a.text.push(o),c.type),c=c.className;c?a.className=c:o=="error"?a.className=" ace_error":o=="warning"&&a.className!=" ace_error"?a.className=" ace_warning":o!="info"||a.className||(a.className=" ace_info")}},this.$updateAnnotations=function(e){var r,a;this.$annotations.length&&(r=e.start.row,(a=e.end.row-r)!=0&&(e.action=="remove"?this.$annotations.splice(r,1+a,null):((e=new Array(1+a)).unshift(r,1),this.$annotations.splice.apply(this.$annotations,e))))},this.update=function(e){this.config=e;for(var r=this.session,a=e.firstRow,o=Math.min(e.lastRow+e.gutterOffset,r.getLength()-1),c=(this.oldLastRow=o,this.config=e,this.$lines.moveContainer(e),this.$updateCursorRow(),r.getNextFoldLine(a)),h=c?c.start.row:1/0,A=null,v=-1,d=a;;){if(h<d&&(d=c.end.row+1,h=(c=r.getNextFoldLine(d,c))?c.start.row:1/0),o<d){for(;this.$lines.getLength()>v+1;)this.$lines.pop();break}(A=this.$lines.get(++v))?A.row=d:(A=this.$lines.createCell(d,e,this.session,i),this.$lines.push(A)),this.$renderCell(A,e,c,d),d++}this._signal("afterRender"),this.$updateGutterWidth(e)},this.$updateGutterWidth=function(e){var r=this.session,c=r.gutterRenderer||this.$renderer,o=r.$firstLineNumber,a=this.$lines.last()?this.$lines.last().text:"",o=((this.$fixedWidth||r.$useWrapMode)&&(a=r.getLength()+o-1),c?c.getWidth(r,a,e):a.toString().length*e.characterWidth),c=this.$padding||this.$computePadding();(o+=c.left+c.right)===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))},this.$updateCursorRow=function(){var e;this.$highlightGutterLine&&(e=this.session.selection.getCursor(),this.$cursorRow!==e.row&&(this.$cursorRow=e.row))},this.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 r=this.$lines.cells;this.$cursorCell=null;for(var a=0;a<r.length;a++){var o=r[a];if(o.row>=this.$cursorRow){if(o.row>this.$cursorRow){var c=this.session.getFoldLine(this.$cursorRow);if(!(0<a&&c&&c.start.row==r[a-1].row))break;o=r[a-1]}o.element.className="ace_gutter-active-line "+o.element.className,this.$cursorCell=o;break}}}}},this.scrollLines=function(e){var r=this.config;if(this.config=e,this.$updateCursorRow(),this.$lines.pageChanged(r,e))return this.update(e);this.$lines.moveContainer(e);var a=Math.min(e.lastRow+e.gutterOffset,this.session.getLength()-1),o=this.oldLastRow;if(this.oldLastRow=a,!r||o<e.firstRow)return this.update(e);if(a<r.firstRow)return this.update(e);if(r.firstRow<e.firstRow)for(var c=this.session.getFoldedRowCount(r.firstRow,e.firstRow-1);0<c;c--)this.$lines.shift();if(a<o)for(c=this.session.getFoldedRowCount(a+1,o);0<c;c--)this.$lines.pop();e.firstRow<r.firstRow&&this.$lines.unshift(this.$renderLines(e,e.firstRow,r.firstRow-1)),o<a&&this.$lines.push(this.$renderLines(e,o+1,a)),this.updateLineHighlight(),this._signal("afterRender"),this.$updateGutterWidth(e)},this.$renderLines=function(e,r,a){for(var o=[],c=r,h=this.session.getNextFoldLine(c),A=h?h.start.row:1/0;A<c&&(c=h.end.row+1,A=(h=this.session.getNextFoldLine(c,h))?h.start.row:1/0),!(a<c);){var v=this.$lines.createCell(c,e,this.session,i);this.$renderCell(v,e,h,c),o.push(v),c++}return o},this.$renderCell=function(e,r,a,o){var c,h=e.element,A=this.session,v=h.childNodes[0],d=h.childNodes[1],g=A.$firstLineNumber,y=A.$breakpoints,E=A.$decorations,w=A.gutterRenderer||this.$renderer,I=this.$showFoldWidgets&&A.foldWidgets,T=a?a.start.row:Number.MAX_VALUE,B="ace_gutter-cell ",E=(this.$highlightGutterLine&&(o==this.$cursorRow||a&&o<this.$cursorRow&&T<=o&&this.$cursorRow<=a.end.row)&&(B+="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)),y[o]&&(B+=y[o]),E[o]&&(B+=E[o]),this.$annotations[o]&&(B+=this.$annotations[o].className),h.className!=B&&(h.className=B),!I||(c=I[o])==null&&(c=I[o]=A.getFoldWidget(o)),c?(B="ace_fold-widget ace_"+c,c=="start"&&o==T&&o<a.end.row?B+=" ace_closed":B+=" ace_open",d.className!=B&&(d.className=B),y=r.lineHeight+"px",p.setStyle(d.style,"height",y),p.setStyle(d.style,"display","inline-block")):d&&p.setStyle(d.style,"display","none"),(w?w.getText(A,o):o+g).toString());return E!==v.data&&(v.data=E),p.setStyle(e.element.style,"height",this.$lines.computeLineHeight(o,r,A)+"px"),p.setStyle(e.element.style,"top",this.$lines.computeLineTop(o,r,A)+"px"),e.text=E,e},this.$fixedWidth=!1,this.$highlightGutterLine=!0,this.$renderer="",this.setHighlightGutterLine=function(e){this.$highlightGutterLine=e},this.$showLineNumbers=!0,this.$renderer="",this.setShowLineNumbers=function(e){this.$renderer=!e&&{getWidth:function(){return 0},getText:function(){return""}}},this.getShowLineNumbers=function(){return this.$showLineNumbers},this.$showFoldWidgets=!0,this.setShowFoldWidgets=function(e){e?p.addCssClass(this.element,"ace_folding-enabled"):p.removeCssClass(this.element,"ace_folding-enabled"),this.$showFoldWidgets=e,this.$padding=null},this.getShowFoldWidgets=function(){return this.$showFoldWidgets},this.$computePadding=function(){var e;return this.element.firstChild?(e=p.computedStyle(this.element.firstChild),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):{left:0,right:0}},this.getRegion=function(e){var r=this.$padding||this.$computePadding(),a=this.element.getBoundingClientRect();return e.x<r.left+a.left?"markers":this.$showFoldWidgets&&e.x>a.right-r.right?"foldWidgets":void 0}}).call(x.prototype),m.Gutter=x}),ace.define("ace/layer/marker",["require","exports","module","ace/range","ace/lib/dom"],function(C,m,b){function x(s){this.element=l.createElement("div"),this.element.className="ace_layer ace_marker-layer",s.appendChild(this.element)}var p=C("../range").Range,l=C("../lib/dom");(function(){this.$padding=0,this.setPadding=function(s){this.$padding=s},this.setSession=function(s){this.session=s},this.setMarkers=function(s){this.markers=s},this.elt=function(s,n){var t=this.i!=-1&&this.element.childNodes[this.i];t?this.i++:(t=document.createElement("div"),this.element.appendChild(t),this.i=-1),t.style.cssText=n,t.className=s},this.update=function(s){if(s){var n,t;for(t in this.config=s,this.i=0,this.markers){var i,e,r,a=this.markers[t];a.range?(r=a.range.clipRows(s.firstRow,s.lastRow)).isEmpty()||(r=r.toScreenRange(this.session),a.renderer?(i=this.$getTop(r.start.row,s),e=this.$padding+r.start.column*s.characterWidth,a.renderer(n,r,e,i,s)):a.type=="fullLine"?this.drawFullLineMarker(n,r,a.clazz,s):a.type=="screenLine"?this.drawScreenLineMarker(n,r,a.clazz,s):r.isMultiLine()?a.type=="text"?this.drawTextMarker(n,r,a.clazz,s):this.drawMultiLineMarker(n,r,a.clazz,s):this.drawSingleLineMarker(n,r,a.clazz+" ace_start ace_br15",s)):a.update(n,this,this.session,s)}if(this.i!=-1)for(;this.i<this.element.childElementCount;)this.element.removeChild(this.element.lastChild)}},this.$getTop=function(s,n){return(s-n.firstRowScreen)*n.lineHeight},this.drawTextMarker=function(s,n,t,i,e){for(var r,a=this.session,o=n.start.row,c=n.end.row,h=o,A=0,v=a.getScreenLastRowColumn(h),d=new p(h,n.start.column,h,A);h<=c;h++)d.start.row=d.end.row=h,d.start.column=h==o?n.start.column:a.getRowWrapIndent(h),d.end.column=v,r=A,A=v,v=h+1<c?a.getScreenLastRowColumn(h+1):h==c?0:n.end.column,this.drawSingleLineMarker(s,d,t+(h==o?" ace_start":"")+" ace_br"+((h==o||h==o+1&&n.start.column?1:0)|(r<A?2:0)|(v<A?4:0)|(h==c?8:0)),i,h==c?0:1,e)},this.drawMultiLineMarker=function(s,n,t,i,e){var r,a=this.$padding,o=i.lineHeight,c=this.$getTop(n.start.row,i),h=a+n.start.column*i.characterWidth;e=e||"",this.session.$bidiHandler.isBidiRow(n.start.row)?((r=n.clone()).end.row=r.start.row,r.end.column=this.session.getLine(r.start.row).length,this.drawBidiSingleLineMarker(s,r,t+" ace_br1 ace_start",i,null,e)):this.elt(t+" ace_br1 ace_start","height:"+o+"px;right:0;top:"+c+"px;left:"+h+"px;"+(e||"")),this.session.$bidiHandler.isBidiRow(n.end.row)?((r=n.clone()).start.row=r.end.row,r.start.column=0,this.drawBidiSingleLineMarker(s,r,t+" ace_br12",i,null,e)):(c=this.$getTop(n.end.row,i),h=n.end.column*i.characterWidth,this.elt(t+" ace_br12","height:"+o+"px;width:"+h+"px;top:"+c+"px;left:"+a+"px;"+(e||""))),(o=(n.end.row-n.start.row-1)*i.lineHeight)<=0||(c=this.$getTop(n.start.row+1,i),s=(n.start.column?1:0)|(n.end.column?0:8),this.elt(t+(s?" ace_br"+s:""),"height:"+o+"px;right:0;top:"+c+"px;left:"+a+"px;"+(e||"")))},this.drawSingleLineMarker=function(a,h,t,i,o,r){if(this.session.$bidiHandler.isBidiRow(h.start.row))return this.drawBidiSingleLineMarker(a,h,t,i,o,r);var a=i.lineHeight,o=(h.end.column+(o||0)-h.start.column)*i.characterWidth,c=this.$getTop(h.start.row,i),h=this.$padding+h.start.column*i.characterWidth;this.elt(t,"height:"+a+"px;width:"+o+"px;top:"+c+"px;left:"+h+"px;"+(r||""))},this.drawBidiSingleLineMarker=function(s,n,t,i,e,r){var a=i.lineHeight,o=this.$getTop(n.start.row,i),c=this.$padding;this.session.$bidiHandler.getSelections(n.start.column,n.end.column).forEach(function(h){this.elt(t,"height:"+a+"px;width:"+h.width+(e||0)+"px;top:"+o+"px;left:"+(c+h.left)+"px;"+(r||""))},this)},this.drawFullLineMarker=function(s,n,t,i,e){var r=this.$getTop(n.start.row,i),a=i.lineHeight;n.start.row!=n.end.row&&(a+=this.$getTop(n.end.row,i)-r),this.elt(t,"height:"+a+"px;top:"+r+"px;left:0;right:0;"+(e||""))},this.drawScreenLineMarker=function(s,n,t,i,e){n=this.$getTop(n.start.row,i),i=i.lineHeight,this.elt(t,"height:"+i+"px;top:"+n+"px;left:0;right:0;"+(e||""))}}).call(x.prototype),m.Marker=x}),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(C,m,b){function x(i){this.dom=l,this.element=this.dom.createElement("div"),this.element.className="ace_layer ace_text-layer",i.appendChild(this.element),this.$updateEolChar=this.$updateEolChar.bind(this),this.$lines=new n(this.element)}var p=C("../lib/oop"),l=C("../lib/dom"),s=C("../lib/lang"),n=C("./lines").Lines,t=C("../lib/event_emitter").EventEmitter;(function(){p.implement(this,t),this.EOF_CHAR="\xB6",this.EOL_CHAR_LF="\xAC",this.EOL_CHAR_CRLF="\xA4",this.EOL_CHAR=this.EOL_CHAR_LF,this.TAB_CHAR="\u2014",this.SPACE_CHAR="\xB7",this.$padding=0,this.MAX_LINE_LENGTH=1e4,this.$updateEolChar=function(){var i=this.session.doc,i=i.getNewLineCharacter()==`
`&&i.getNewLineMode()!="windows"?this.EOL_CHAR_LF:this.EOL_CHAR_CRLF;if(this.EOL_CHAR!=i)return this.EOL_CHAR=i,!0},this.setPadding=function(i){this.$padding=i,this.element.style.margin="0 "+i+"px"},this.getLineHeight=function(){return this.$fontMetrics.$characterSize.height||0},this.getCharacterWidth=function(){return this.$fontMetrics.$characterSize.width||0},this.$setFontMetrics=function(i){this.$fontMetrics=i,this.$fontMetrics.on("changeCharacterSize",function(e){this._signal("changeCharacterSize",e)}.bind(this)),this.$pollSizeChanges()},this.checkForSizeChanges=function(){this.$fontMetrics.checkForSizeChanges()},this.$pollSizeChanges=function(){return this.$pollSizeChangesTimer=this.$fontMetrics.$pollSizeChanges()},this.setSession=function(i){(this.session=i)&&this.$computeTabString()},this.showInvisibles=!1,this.showSpaces=!1,this.showTabs=!1,this.showEOL=!1,this.setShowInvisibles=function(i){return this.showInvisibles!=i&&(typeof(this.showInvisibles=i)=="string"?(this.showSpaces=/tab/i.test(i),this.showTabs=/space/i.test(i),this.showEOL=/eol/i.test(i)):this.showSpaces=this.showTabs=this.showEOL=i,this.$computeTabString(),!0)},this.displayIndentGuides=!0,this.setDisplayIndentGuides=function(i){return this.displayIndentGuides!=i&&(this.displayIndentGuides=i,this.$computeTabString(),!0)},this.$highlightIndentGuides=!0,this.setHighlightIndentGuides=function(i){return this.$highlightIndentGuides!==i&&(this.$highlightIndentGuides=i)},this.$tabStrings=[],this.onChangeTabSize=this.$computeTabString=function(){for(var i,e,r,a,o,c,h=this.session.getTabSize(),A=(this.tabSize=h,this.$tabStrings=[0]),v=1;v<h+1;v++)this.showTabs?((c=this.dom.createElement("span")).className="ace_invisible ace_invisible_tab",c.textContent=s.stringRepeat(this.TAB_CHAR,v),A.push(c)):A.push(this.dom.createTextNode(s.stringRepeat(" ",v),this.element));this.displayIndentGuides&&(this.$indentGuideRe=/\s\S| \t|\t |\s$/,i="ace_indent-guide",e=this.showSpaces?" ace_invisible ace_invisible_space":"",r=this.showSpaces?s.stringRepeat(this.SPACE_CHAR,this.tabSize):s.stringRepeat(" ",this.tabSize),a=this.showTabs?" ace_invisible ace_invisible_tab":"",o=this.showTabs?s.stringRepeat(this.TAB_CHAR,this.tabSize):r,(c=this.dom.createElement("span")).className=i+e,c.textContent=r,this.$tabStrings[" "]=c,(c=this.dom.createElement("span")).className=i+a,c.textContent=o,this.$tabStrings["	"]=c)},this.updateLines=function(i,e,r){if(this.config.lastRow!=i.lastRow||this.config.firstRow!=i.firstRow)return this.update(i);this.config=i;for(var a=Math.max(e,i.firstRow),o=Math.min(r,i.lastRow),c=this.element.childNodes,h=0,A=i.firstRow;A<a;A++){if(v=this.session.getFoldLine(A)){if(v.containsRow(a)){a=v.start.row;break}A=v.end.row}h++}for(var v,d=!1,A=a,g=(v=this.session.getNextFoldLine(A))?v.start.row:1/0;g<A&&(A=v.end.row+1,g=(v=this.session.getNextFoldLine(A,v))?v.start.row:1/0),!(o<A);){var y,w=c[h++];w&&(this.dom.removeChildren(w),this.$renderLine(w,A,A==g&&v),d&&(w.style.top=this.$lines.computeLineTop(A,i,this.session)+"px"),y=i.lineHeight*this.session.getRowLength(A)+"px",w.style.height!=y&&(d=!0,w.style.height=y)),A++}if(d)for(;h<this.$lines.cells.length;){var I=this.$lines.cells[h++];I.element.style.top=this.$lines.computeLineTop(I.row,i,this.session)+"px"}},this.scrollLines=function(i){var e=this.config;if(this.config=i,this.$lines.pageChanged(e,i))return this.update(i);this.$lines.moveContainer(i);var r=i.lastRow,a=e?e.lastRow:-1;if(!e||a<i.firstRow)return this.update(i);if(r<e.firstRow)return this.update(i);if(!e||e.lastRow<i.firstRow)return this.update(i);if(i.lastRow<e.firstRow)return this.update(i);if(e.firstRow<i.firstRow)for(var o=this.session.getFoldedRowCount(e.firstRow,i.firstRow-1);0<o;o--)this.$lines.shift();if(e.lastRow>i.lastRow)for(o=this.session.getFoldedRowCount(i.lastRow+1,e.lastRow);0<o;o--)this.$lines.pop();i.firstRow<e.firstRow&&this.$lines.unshift(this.$renderLinesFragment(i,i.firstRow,e.firstRow-1)),i.lastRow>e.lastRow&&this.$lines.push(this.$renderLinesFragment(i,e.lastRow+1,i.lastRow)),this.$highlightIndentGuide()},this.$renderLinesFragment=function(i,e,r){for(var a=[],o=e,c=this.session.getNextFoldLine(o),h=c?c.start.row:1/0;h<o&&(o=c.end.row+1,h=(c=this.session.getNextFoldLine(o,c))?c.start.row:1/0),!(r<o);){var A=this.$lines.createCell(o,i,this.session),v=A.element;this.dom.removeChildren(v),l.setStyle(v.style,"height",this.$lines.computeLineHeight(o,i,this.session)+"px"),l.setStyle(v.style,"top",this.$lines.computeLineTop(o,i,this.session)+"px"),this.$renderLine(v,o,o==h&&c),this.$useLineGroups()?v.className="ace_line_group":v.className="ace_line",a.push(A),o++}return a},this.update=function(i){this.$lines.moveContainer(i);for(var e=(this.config=i).firstRow,r=i.lastRow,a=this.$lines;a.getLength();)a.pop();a.push(this.$renderLinesFragment(i,e,r))},this.$textToken={text:!0,rparen:!0,lparen:!0},this.$renderToken=function(i,e,r,a){for(var o,c,h=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,v=this.dom.createFragment(this.element),d=0;o=A.exec(a);){var g,y,w=o[1],I=o[2],T=o[3],B=o[4],E=o[5];!h.showSpaces&&I||(g=d!=o.index?a.slice(d,o.index):"",d=o.index+o[0].length,g&&v.appendChild(this.dom.createTextNode(g,this.element)),w?(g=h.session.getScreenTabSize(e+o.index),v.appendChild(h.$tabStrings[g].cloneNode(!0)),e+=g-1):I?h.showSpaces?((y=this.dom.createElement("span")).className="ace_invisible ace_invisible_space",y.textContent=s.stringRepeat(h.SPACE_CHAR,I.length),v.appendChild(y)):v.appendChild(this.com.createTextNode(I,this.element)):T?((y=this.dom.createElement("span")).className="ace_invisible ace_invisible_space ace_invalid",y.textContent=s.stringRepeat(h.SPACE_CHAR,T.length),v.appendChild(y)):B?(e+=1,(y=this.dom.createElement("span")).style.width=2*h.config.characterWidth+"px",y.className=h.showSpaces?"ace_cjk ace_invisible ace_invisible_space":"ace_cjk",y.textContent=h.showSpaces?h.SPACE_CHAR:B,v.appendChild(y)):E&&(e+=1,(y=this.dom.createElement("span")).style.width=2*h.config.characterWidth+"px",y.className="ace_cjk",y.textContent=E,v.appendChild(y)))}return v.appendChild(this.dom.createTextNode(d?a.slice(d):a,this.element)),this.$textToken[r.type]?i.appendChild(v):(c="ace_"+r.type.replace(/\./g," ace_"),y=this.dom.createElement("span"),r.type=="fold"&&(y.style.width=r.value.length*this.config.characterWidth+"px"),y.className=c,y.appendChild(v),i.appendChild(y)),e+a.length},this.renderIndentGuide=function(i,e,r){var a=e.search(this.$indentGuideRe);if(!(a<=0||r<=a)){if(e[0]==" "){for(var o=(a-=a%this.tabSize)/this.tabSize,c=0;c<o;c++)i.appendChild(this.$tabStrings[" "].cloneNode(!0));return this.$highlightIndentGuide(),e.substr(a)}if(e[0]=="	"){for(c=0;c<a;c++)i.appendChild(this.$tabStrings["	"].cloneNode(!0));return this.$highlightIndentGuide(),e.substr(a)}this.$highlightIndentGuide()}return e},this.$highlightIndentGuide=function(){if(this.$highlightIndentGuides&&this.displayIndentGuides){this.$highlightIndentGuideMarker={indentLevel:void 0,start:void 0,end:void 0,dir:void 0};var i=this.session.doc.$lines,e=this.session.selection.getCursor(),r=/^\s*/.exec(this.session.doc.getLine(e.row))[0].length,a=Math.floor(r/this.tabSize);if(this.$highlightIndentGuideMarker={indentLevel:a,start:e.row},this.session.$bracketHighlight){for(var o=this.session.$bracketHighlight.ranges,c=0;c<o.length;c++)if(e.row!==o[c].start.row){this.$highlightIndentGuideMarker.end=o[c].start.row,e.row>o[c].start.row?this.$highlightIndentGuideMarker.dir=-1:this.$highlightIndentGuideMarker.dir=1;break}}if(!this.$highlightIndentGuideMarker.end&&i[e.row]!==""&&e.column===i[e.row].length)for(this.$highlightIndentGuideMarker.dir=1,c=e.row+1;c<i.length;c++){var h=i[c],A=/^\s*/.exec(h)[0].length;if(h!==""&&(this.$highlightIndentGuideMarker.end=c,A<=r))break}this.$renderHighlightIndentGuide()}},this.$clearActiveIndentGuide=function(){for(var i=this.$lines.cells,e=0;e<i.length;e++){var r=i[e].element.childNodes;if(0<r.length){for(var a=0;a<r.length;a++)if(r[a].classList&&r[a].classList.contains("ace_indent-guide-active")){r[a].classList.remove("ace_indent-guide-active");break}}}},this.$setIndentGuideActive=function(i,e){this.session.doc.getLine(i.row)!==""&&(i=i.element.childNodes)&&i[e-1]&&i[e-1].classList&&i[e-1].classList.add("ace_indent-guide-active")},this.$renderHighlightIndentGuide=function(){if(this.$lines){var i=this.$lines.cells,e=(this.$clearActiveIndentGuide(),this.$highlightIndentGuideMarker.indentLevel);if(e!==0){if(this.$highlightIndentGuideMarker.dir===1)for(var r=0;r<i.length;r++){var a=i[r];if(this.$highlightIndentGuideMarker.end&&a.row>=this.$highlightIndentGuideMarker.start+1){if(a.row>=this.$highlightIndentGuideMarker.end)break;this.$setIndentGuideActive(a,e)}}else for(r=i.length-1;0<=r;r--)if(a=i[r],this.$highlightIndentGuideMarker.end&&a.row<this.$highlightIndentGuideMarker.start){if(a.row<=this.$highlightIndentGuideMarker.end)break;this.$setIndentGuideActive(a,e)}}}},this.$createLineElement=function(i){var e=this.dom.createElement("div");return e.className="ace_line",e.style.height=this.config.lineHeight+"px",e},this.$renderWrappedLine=function(i,e,r){var a=0,o=0,c=r[0],h=0,A=this.$createLineElement();i.appendChild(A);for(var v=0;v<e.length;v++){var d=e[v],g=d.value;if(v==0&&this.displayIndentGuides){if(a=g.length,!(g=this.renderIndentGuide(A,g,c)))continue;a-=g.length}if(a+g.length<c)h=this.$renderToken(A,h,d,g),a+=g.length;else{for(;a+g.length>=c;)h=this.$renderToken(A,h,d,g.substring(0,c-a)),g=g.substring(c-a),a=c,A=this.$createLineElement(),i.appendChild(A),A.appendChild(this.dom.createTextNode(s.stringRepeat("\xA0",r.indent),this.element)),h=0,c=r[++o]||Number.MAX_VALUE;g.length!=0&&(a+=g.length,h=this.$renderToken(A,h,d,g))}}r[r.length-1]>this.MAX_LINE_LENGTH&&this.$renderOverflowMessage(A,h,null,"",!0)},this.$renderSimpleLine=function(i,e){for(var r=0,a=0;a<e.length;a++){var o=e[a],c=o.value;if(a!=0||!this.displayIndentGuides||(c=this.renderIndentGuide(i,c))){if(r+c.length>this.MAX_LINE_LENGTH)return this.$renderOverflowMessage(i,r,o,c);r=this.$renderToken(i,r,o,c)}}},this.$renderOverflowMessage=function(i,e,r,a,o){r&&this.$renderToken(i,e,r,a.slice(0,this.MAX_LINE_LENGTH-e)),r=this.dom.createElement("span"),r.className="ace_inline_button ace_keyword ace_toggle_wrap",r.textContent=o?"<hide>":"<click to see more...>",i.appendChild(r)},this.$renderLine=function(i,e,r){var a,o,c=i;(a=(r=r||r==0?r:this.session.getFoldLine(e))?this.$getFoldLineTokens(e,r):this.session.getTokens(e)).length?(o=this.session.getRowSplitData(e))&&o.length?(this.$renderWrappedLine(i,a,o),c=i.lastChild):(c=i,this.$useLineGroups()&&(c=this.$createLineElement(),i.appendChild(c)),this.$renderSimpleLine(c,a)):this.$useLineGroups()&&(c=this.$createLineElement(),i.appendChild(c)),this.showEOL&&c&&(r&&(e=r.end.row),(o=this.dom.createElement("span")).className="ace_invisible ace_invisible_eol",o.textContent=e==this.session.getLength()-1?this.EOF_CHAR:this.EOL_CHAR,c.appendChild(o))},this.$getFoldLineTokens=function(i,e){var r=this.session,a=[],o=r.getTokens(i);return e.walk(function(c,h,A,v,d){if(c!=null)a.push({type:"fold",value:c});else if((o=d?r.getTokens(h):o).length){for(var g,y=o,w=v,I=A,T=0,B=0;B+y[T].value.length<w;)if(B+=y[T].value.length,++T==y.length)return;for(B!=w&&((g=y[T].value.substring(w-B)).length>I-w&&(g=g.substring(0,I-w)),a.push({type:y[T].type,value:g}),B=w+g.length,T+=1);B<I&&T<y.length;)(g=y[T].value).length+B>I?a.push({type:y[T].type,value:g.substring(0,I-B)}):a.push(y[T]),B+=g.length,T+=1}},e.end.row,this.session.getLine(e.end.row).length),a},this.$useLineGroups=function(){return this.session.getUseWrapMode()},this.destroy=function(){}}).call(x.prototype),m.Text=x}),ace.define("ace/layer/cursor",["require","exports","module","ace/lib/dom"],function(C,m,b){function x(l){this.element=p.createElement("div"),this.element.className="ace_layer ace_cursor-layer",l.appendChild(this.element),this.isVisible=!1,this.isBlinking=!0,this.blinkInterval=1e3,this.smoothBlinking=!1,this.cursors=[],this.cursor=this.addCursor(),p.addCssClass(this.element,"ace_hidden-cursors"),this.$updateCursors=this.$updateOpacity.bind(this)}var p=C("../lib/dom");(function(){this.$updateOpacity=function(l){for(var s=this.cursors,n=s.length;n--;)p.setStyle(s[n].style,"opacity",l?"":"0")},this.$startCssAnimation=function(){for(var l=this.cursors,s=l.length;s--;)l[s].style.animationDuration=this.blinkInterval+"ms";this.$isAnimating=!0,setTimeout(function(){this.$isAnimating&&p.addCssClass(this.element,"ace_animate-blinking")}.bind(this))},this.$stopCssAnimation=function(){this.$isAnimating=!1,p.removeCssClass(this.element,"ace_animate-blinking")},this.$padding=0,this.setPadding=function(l){this.$padding=l},this.setSession=function(l){this.session=l},this.setBlinking=function(l){l!=this.isBlinking&&(this.isBlinking=l,this.restartTimer())},this.setBlinkInterval=function(l){l!=this.blinkInterval&&(this.blinkInterval=l,this.restartTimer())},this.setSmoothBlinking=function(l){l!=this.smoothBlinking&&(this.smoothBlinking=l,p.setCssClass(this.element,"ace_smooth-blinking",l),this.$updateCursors(!0),this.restartTimer())},this.addCursor=function(){var l=p.createElement("div");return l.className="ace_cursor",this.element.appendChild(l),this.cursors.push(l),l},this.removeCursor=function(){var l;if(1<this.cursors.length)return(l=this.cursors.pop()).parentNode.removeChild(l),l},this.hideCursor=function(){this.isVisible=!1,p.addCssClass(this.element,"ace_hidden-cursors"),this.restartTimer()},this.showCursor=function(){this.isVisible=!0,p.removeCssClass(this.element,"ace_hidden-cursors"),this.restartTimer()},this.restartTimer=function(){var l,s=this.$updateCursors;clearInterval(this.intervalId),clearTimeout(this.timeoutId),this.$stopCssAnimation(),this.smoothBlinking&&(this.$isSmoothBlinking=!1,p.removeCssClass(this.element,"ace_smooth-blinking")),s(!0),this.isBlinking&&this.blinkInterval&&this.isVisible?(this.smoothBlinking&&(this.$isSmoothBlinking=!0,setTimeout(function(){this.$isSmoothBlinking&&p.addCssClass(this.element,"ace_smooth-blinking")}.bind(this))),p.HAS_CSS_ANIMATION?this.$startCssAnimation():(l=function(){this.timeoutId=setTimeout(function(){s(!1)},.6*this.blinkInterval)}.bind(this),this.intervalId=setInterval(function(){s(!0),l()},this.blinkInterval),l())):this.$stopCssAnimation()},this.getPixelPosition=function(l,s){if(!this.config||!this.session)return{left:0,top:0};l=l||this.session.selection.getCursor();var n=this.session.documentToScreenPosition(l);return{left:this.$padding+(this.session.$bidiHandler.isBidiRow(n.row,l.row)?this.session.$bidiHandler.getPosLeft(n.column):n.column*this.config.characterWidth),top:(n.row-(s?this.config.firstRowScreen:0))*this.config.lineHeight}},this.isCursorInView=function(l,s){return 0<=l.top&&l.top<s.maxHeight},this.update=function(l){this.config=l;for(var s=this.session.$selectionMarkers,t=0,n=0,t=0,i=(s=s!==void 0&&s.length!==0?s:[{cursor:null}]).length;t<i;t++){var e,r,a=this.getPixelPosition(s[t].cursor,!0);(a.top>l.height+l.offset||a.top<0)&&1<t||(r=(e=this.cursors[n++]||this.addCursor()).style,this.drawCursor?this.drawCursor(e,a,l,s[t],this.session):this.isCursorInView(a,l)?(p.setStyle(r,"display","block"),p.translate(e,a.left,a.top),p.setStyle(r,"width",Math.round(l.characterWidth)+"px"),p.setStyle(r,"height",l.lineHeight+"px")):p.setStyle(r,"display","none"))}for(;this.cursors.length>n;)this.removeCursor();var o=this.session.getOverwrite();this.$setOverwrite(o),this.$pixelPos=a,this.restartTimer()},this.drawCursor=null,this.$setOverwrite=function(l){l!=this.overwrite&&((this.overwrite=l)?p.addCssClass(this.element,"ace_overwrite-cursors"):p.removeCssClass(this.element,"ace_overwrite-cursors"))},this.destroy=function(){clearInterval(this.intervalId),clearTimeout(this.timeoutId)}}).call(x.prototype),m.Cursor=x}),ace.define("ace/scrollbar",["require","exports","module","ace/lib/oop","ace/lib/dom","ace/lib/event","ace/lib/event_emitter"],function(C,m,b){function x(e){this.element=n.createElement("div"),this.element.className="ace_scrollbar ace_scrollbar"+this.classSuffix,this.inner=n.createElement("div"),this.inner.className="ace_scrollbar-inner",this.inner.textContent="\xA0",this.element.appendChild(this.inner),e.appendChild(this.element),this.setVisible(!1),this.skipEvent=!1,t.addListener(this.element,"scroll",this.onScroll.bind(this)),t.addListener(this.element,"mousedown",t.preventDefault)}function p(e,r){x.call(this,e),this.scrollTop=0,this.scrollHeight=0,r.$scrollbarWidth=this.width=n.scrollbarWidth(e.ownerDocument),this.inner.style.width=this.element.style.width=(this.width||15)+5+"px",this.$minWidth=0}function l(e,r){x.call(this,e),this.scrollLeft=0,this.height=r.$scrollbarWidth,this.inner.style.height=this.element.style.height=(this.height||15)+5+"px"}var s=C("./lib/oop"),n=C("./lib/dom"),t=C("./lib/event"),i=C("./lib/event_emitter").EventEmitter;(function(){s.implement(this,i),this.setVisible=function(e){this.element.style.display=e?"":"none",this.isVisible=e,this.coeff=1}}).call(x.prototype),s.inherits(p,x),function(){this.classSuffix="-v",this.onScroll=function(){var e;this.skipEvent||(this.scrollTop=this.element.scrollTop,this.coeff!=1&&(e=this.element.clientHeight/this.scrollHeight,this.scrollTop=this.scrollTop*(1-e)/(this.coeff-e)),this._emit("scroll",{data:this.scrollTop})),this.skipEvent=!1},this.getWidth=function(){return Math.max(this.isVisible?this.width:0,this.$minWidth||0)},this.setHeight=function(e){this.element.style.height=e+"px"},this.setInnerHeight=this.setScrollHeight=function(e){32768<(this.scrollHeight=e)?(this.coeff=32768/e,e=32768):this.coeff!=1&&(this.coeff=1),this.inner.style.height=e+"px"},this.setScrollTop=function(e){this.scrollTop!=e&&(this.skipEvent=!0,this.scrollTop=e,this.element.scrollTop=e*this.coeff)}}.call(p.prototype),s.inherits(l,x),function(){this.classSuffix="-h",this.onScroll=function(){this.skipEvent||(this.scrollLeft=this.element.scrollLeft,this._emit("scroll",{data:this.scrollLeft})),this.skipEvent=!1},this.getHeight=function(){return this.isVisible?this.height:0},this.setWidth=function(e){this.element.style.width=e+"px"},this.setInnerWidth=function(e){this.inner.style.width=e+"px"},this.setScrollWidth=function(e){this.inner.style.width=e+"px"},this.setScrollLeft=function(e){this.scrollLeft!=e&&(this.skipEvent=!0,this.scrollLeft=this.element.scrollLeft=e)}}.call(l.prototype),m.ScrollBar=p,m.ScrollBarV=p,m.ScrollBarH=l,m.VScrollBar=p,m.HScrollBar=l}),ace.define("ace/renderloop",["require","exports","module","ace/lib/event"],function(C,m,b){function x(l,s){this.onRender=l,this.pending=!1,this.changes=0,this.$recursionLimit=2,this.window=s||window;var n=this;this._flush=function(t){n.pending=!1;var i=n.changes;i&&(p.blockIdle(100),n.changes=0,n.onRender(i)),n.changes?n.$recursionLimit--<0||n.schedule():n.$recursionLimit=2}}var p=C("./lib/event");(function(){this.schedule=function(l){this.changes=this.changes|l,this.changes&&!this.pending&&(p.nextFrame(this._flush),this.pending=!0)},this.clear=function(l){var s=this.changes;return this.changes=0,s}}).call(x.prototype),m.RenderLoop=x}),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,m,b){var x=e("../lib/oop"),p=e("../lib/dom"),l=e("../lib/lang"),s=e("../lib/event"),n=e("../lib/useragent"),t=e("../lib/event_emitter").EventEmitter,i=typeof ResizeObserver=="function",e=m.FontMetrics=function(r){this.el=p.createElement("div"),this.$setMeasureNodeStyles(this.el.style,!0),this.$main=p.createElement("div"),this.$setMeasureNodeStyles(this.$main.style),this.$measureNode=p.createElement("div"),this.$setMeasureNodeStyles(this.$measureNode.style),this.el.appendChild(this.$main),this.el.appendChild(this.$measureNode),r.appendChild(this.el),this.$measureNode.textContent=l.stringRepeat("X",256),this.$characterSize={width:0,height:0},i?this.$addObserver():this.checkForSizeChanges()};(function(){x.implement(this,t),this.$characterSize={width:0,height:0},this.$setMeasureNodeStyles=function(r,a){r.width=r.height="auto",r.left=r.top="0px",r.visibility="hidden",r.position="absolute",r.whiteSpace="pre",n.isIE<8?r["font-family"]="inherit":r.font="inherit",r.overflow=a?"hidden":"visible"},this.checkForSizeChanges=function(r){var a;!(r=r===void 0?this.$measureSizes():r)||this.$characterSize.width===r.width&&this.$characterSize.height===r.height||(this.$measureNode.style.fontWeight="bold",a=this.$measureSizes(),this.$measureNode.style.fontWeight="",this.$characterSize=r,this.charSizes=Object.create(null),this.allowBoldFonts=a&&a.width===r.width&&a.height===r.height,this._emit("changeCharacterSize",{data:r}))},this.$addObserver=function(){var r=this;this.$observer=new window.ResizeObserver(function(a){r.checkForSizeChanges()}),this.$observer.observe(this.$measureNode)},this.$pollSizeChanges=function(){var r;return this.$pollSizeChangesTimer||this.$observer?this.$pollSizeChangesTimer:(r=this).$pollSizeChangesTimer=s.onIdle(function a(){r.checkForSizeChanges(),s.onIdle(a,500)},500)},this.setPolling=function(r){r?this.$pollSizeChanges():this.$pollSizeChangesTimer&&(clearInterval(this.$pollSizeChangesTimer),this.$pollSizeChangesTimer=0)},this.$measureSizes=function(r){return r={height:(r||this.$measureNode).clientHeight,width:(r||this.$measureNode).clientWidth/256},r.width===0||r.height===0?null:r},this.$measureCharWidth=function(r){return this.$main.textContent=l.stringRepeat(r,256),this.$main.getBoundingClientRect().width/256},this.getCharacterWidth=function(r){var a=this.charSizes[r];return a=a===void 0?this.charSizes[r]=this.$measureCharWidth(r)/this.$characterSize.width:a},this.destroy=function(){clearInterval(this.$pollSizeChangesTimer),this.$observer&&this.$observer.disconnect(),this.el&&this.el.parentNode&&this.el.parentNode.removeChild(this.el)},this.$getZoom=function r(a){return a&&a.parentElement?(window.getComputedStyle(a).zoom||1)*r(a.parentElement):1},this.$initTransformMeasureNodes=function(){function r(a,o){return["div",{style:"position: absolute;top:"+a+"px;left:"+o+"px;"}]}this.els=p.buildDom([r(0,0),r(200,0),r(0,200),r(200,200)],this.el)},this.transformCoordinates=function(r,a){function o(T,B,E){var _=T[1]*B[0]-T[0]*B[1];return[(-B[1]*E[0]+B[0]*E[1])/_,(+T[1]*E[0]-T[0]*E[1])/_]}function c(T,B){return[T[0]-B[0],T[1]-B[1]]}function h(T,B){return[T[0]+B[0],T[1]+B[1]]}function A(T,B){return[T*B[0],T*B[1]]}function v(T){return T=T.getBoundingClientRect(),[T.left,T.top]}r=r&&A(1/this.$getZoom(this.el),r),this.els||this.$initTransformMeasureNodes();var d,g=v(this.els[0]),w=v(this.els[1]),I=v(this.els[2]),y=v(this.els[3]),y=o(c(y,w),c(y,I),c(h(w,I),h(y,g))),w=A(1+y[0],c(w,g)),I=A(1+y[1],c(I,g));return a?(d=y[0]*a[0]/200+y[1]*a[1]/200+1,a=h(A(a[0],w),A(a[1],I)),h(A(1/d/200,a),g)):(d=c(r,g),a=o(c(w,A(y[0],d)),c(I,A(y[1],d)),d),A(200,a))}}).call(e.prototype)}),ace.define("ace/css/editor.css",["require","exports","module"],function(C,m,b){b.exports=`/*
styles = []
for (var i = 1; i < 16; i++) {
    styles.push(".ace_br" + i + "{" + (
        ["top-left", "top-right", "bottom-right", "bottom-left"]
    ).map(function(x, j) {
        return i & (1<<j) ? "border-" + x + "-radius: 3px;" : "" 
    }).filter(Boolean).join(" ") + "}")
}
styles.join("\\n")
*/
.ace_br1 {border-top-left-radius    : 3px;}
.ace_br2 {border-top-right-radius   : 3px;}
.ace_br3 {border-top-left-radius    : 3px; border-top-right-radius:    3px;}
.ace_br4 {border-bottom-right-radius: 3px;}
.ace_br5 {border-top-left-radius    : 3px; border-bottom-right-radius: 3px;}
.ace_br6 {border-top-right-radius   : 3px; border-bottom-right-radius: 3px;}
.ace_br7 {border-top-left-radius    : 3px; border-top-right-radius:    3px; border-bottom-right-radius: 3px;}
.ace_br8 {border-bottom-left-radius : 3px;}
.ace_br9 {border-top-left-radius    : 3px; border-bottom-left-radius:  3px;}
.ace_br10{border-top-right-radius   : 3px; border-bottom-left-radius:  3px;}
.ace_br11{border-top-left-radius    : 3px; border-top-right-radius:    3px; border-bottom-left-radius:  3px;}
.ace_br12{border-bottom-right-radius: 3px; border-bottom-left-radius:  3px;}
.ace_br13{border-top-left-radius    : 3px; border-bottom-right-radius: 3px; border-bottom-left-radius:  3px;}
.ace_br14{border-top-right-radius   : 3px; border-bottom-right-radius: 3px; border-bottom-left-radius:  3px;}
.ace_br15{border-top-left-radius    : 3px; border-top-right-radius:    3px; border-bottom-right-radius: 3px; border-bottom-left-radius: 3px;}


.ace_editor {
    position: relative;
    overflow: hidden;
    padding: 0;
    font: 12px/normal 'Monaco', 'Menlo', 'Ubuntu Mono', 'Consolas', 'source-code-pro', monospace;
    direction: ltr;
    text-align: left;
    -webkit-tap-highlight-color: rgba(0, 0, 0, 0);
}

.ace_scroller {
    position: absolute;
    overflow: hidden;
    top: 0;
    bottom: 0;
    background-color: inherit;
    -ms-user-select: none;
    -moz-user-select: none;
    -webkit-user-select: none;
    user-select: none;
    cursor: text;
}

.ace_content {
    position: absolute;
    box-sizing: border-box;
    min-width: 100%;
    contain: style size layout;
    font-variant-ligatures: no-common-ligatures;
}

.ace_dragging .ace_scroller:before{
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    content: '';
    background: rgba(250, 250, 250, 0.01);
    z-index: 1000;
}
.ace_dragging.ace_dark .ace_scroller:before{
    background: rgba(0, 0, 0, 0.01);
}

.ace_gutter {
    position: absolute;
    overflow : hidden;
    width: auto;
    top: 0;
    bottom: 0;
    left: 0;
    cursor: default;
    z-index: 4;
    -ms-user-select: none;
    -moz-user-select: none;
    -webkit-user-select: none;
    user-select: none;
    contain: style size layout;
}

.ace_gutter-active-line {
    position: absolute;
    left: 0;
    right: 0;
}

.ace_scroller.ace_scroll-left {
    box-shadow: 17px 0 16px -16px rgba(0, 0, 0, 0.4) inset;
}

.ace_gutter-cell {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    padding-left: 19px;
    padding-right: 6px;
    background-repeat: no-repeat;
}

.ace_gutter-cell.ace_error {
    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==");
    background-repeat: no-repeat;
    background-position: 2px center;
}

.ace_gutter-cell.ace_warning {
    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==");
    background-position: 2px center;
}

.ace_gutter-cell.ace_info {
    background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAAAAAA6mKC9AAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAAJ0Uk5TAAB2k804AAAAPklEQVQY02NgIB68QuO3tiLznjAwpKTgNyDbMegwisCHZUETUZV0ZqOquBpXj2rtnpSJT1AEnnRmL2OgGgAAIKkRQap2htgAAAAASUVORK5CYII=");
    background-position: 2px center;
}
.ace_dark .ace_gutter-cell.ace_info {
    background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQBAMAAADt3eJSAAAAJFBMVEUAAAChoaGAgIAqKiq+vr6tra1ZWVmUlJSbm5s8PDxubm56enrdgzg3AAAAAXRSTlMAQObYZgAAAClJREFUeNpjYMAPdsMYHegyJZFQBlsUlMFVCWUYKkAZMxZAGdxlDMQBAG+TBP4B6RyJAAAAAElFTkSuQmCC");
}

.ace_scrollbar {
    contain: strict;
    position: absolute;
    right: 0;
    bottom: 0;
    z-index: 6;
}

.ace_scrollbar-inner {
    position: absolute;
    cursor: text;
    left: 0;
    top: 0;
}

.ace_scrollbar-v{
    overflow-x: hidden;
    overflow-y: scroll;
    top: 0;
}

.ace_scrollbar-h {
    overflow-x: scroll;
    overflow-y: hidden;
    left: 0;
}

.ace_print-margin {
    position: absolute;
    height: 100%;
}

.ace_text-input {
    position: absolute;
    z-index: 0;
    width: 0.5em;
    height: 1em;
    opacity: 0;
    background: transparent;
    -moz-appearance: none;
    appearance: none;
    border: none;
    resize: none;
    outline: none;
    overflow: hidden;
    font: inherit;
    padding: 0 1px;
    margin: 0 -1px;
    contain: strict;
    -ms-user-select: text;
    -moz-user-select: text;
    -webkit-user-select: text;
    user-select: text;
    /*with \`pre-line\` chrome inserts &nbsp; instead of space*/
    white-space: pre!important;
}
.ace_text-input.ace_composition {
    background: transparent;
    color: inherit;
    z-index: 1000;
    opacity: 1;
}
.ace_composition_placeholder { color: transparent }
.ace_composition_marker { 
    border-bottom: 1px solid;
    position: absolute;
    border-radius: 0;
    margin-top: 1px;
}

[ace_nocontext=true] {
    transform: none!important;
    filter: none!important;
    clip-path: none!important;
    mask : none!important;
    contain: none!important;
    perspective: none!important;
    mix-blend-mode: initial!important;
    z-index: auto;
}

.ace_layer {
    z-index: 1;
    position: absolute;
    overflow: hidden;
    /* workaround for chrome bug https://github.com/ajaxorg/ace/issues/2312*/
    word-wrap: normal;
    white-space: pre;
    height: 100%;
    width: 100%;
    box-sizing: border-box;
    /* setting pointer-events: auto; on node under the mouse, which changes
        during scroll, will break mouse wheel scrolling in Safari */
    pointer-events: none;
}

.ace_gutter-layer {
    position: relative;
    width: auto;
    text-align: right;
    pointer-events: auto;
    height: 1000000px;
    contain: style size layout;
}

.ace_text-layer {
    font: inherit !important;
    position: absolute;
    height: 1000000px;
    width: 1000000px;
    contain: style size layout;
}

.ace_text-layer > .ace_line, .ace_text-layer > .ace_line_group {
    contain: style size layout;
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
}

.ace_hidpi .ace_text-layer,
.ace_hidpi .ace_gutter-layer,
.ace_hidpi .ace_content,
.ace_hidpi .ace_gutter {
    contain: strict;
    will-change: transform;
}
.ace_hidpi .ace_text-layer > .ace_line, 
.ace_hidpi .ace_text-layer > .ace_line_group {
    contain: strict;
}

.ace_cjk {
    display: inline-block;
    text-align: center;
}

.ace_cursor-layer {
    z-index: 4;
}

.ace_cursor {
    z-index: 4;
    position: absolute;
    box-sizing: border-box;
    border-left: 2px solid;
    /* workaround for smooth cursor repaintng whole screen in chrome */
    transform: translatez(0);
}

.ace_multiselect .ace_cursor {
    border-left-width: 1px;
}

.ace_slim-cursors .ace_cursor {
    border-left-width: 1px;
}

.ace_overwrite-cursors .ace_cursor {
    border-left-width: 0;
    border-bottom: 1px solid;
}

.ace_hidden-cursors .ace_cursor {
    opacity: 0.2;
}

.ace_hasPlaceholder .ace_hidden-cursors .ace_cursor {
    opacity: 0;
}

.ace_smooth-blinking .ace_cursor {
    transition: opacity 0.18s;
}

.ace_animate-blinking .ace_cursor {
    animation-duration: 1000ms;
    animation-timing-function: step-end;
    animation-name: blink-ace-animate;
    animation-iteration-count: infinite;
}

.ace_animate-blinking.ace_smooth-blinking .ace_cursor {
    animation-duration: 1000ms;
    animation-timing-function: ease-in-out;
    animation-name: blink-ace-animate-smooth;
}
    
@keyframes blink-ace-animate {
    from, to { opacity: 1; }
    60% { opacity: 0; }
}

@keyframes blink-ace-animate-smooth {
    from, to { opacity: 1; }
    45% { opacity: 1; }
    60% { opacity: 0; }
    85% { opacity: 0; }
}

.ace_marker-layer .ace_step, .ace_marker-layer .ace_stack {
    position: absolute;
    z-index: 3;
}

.ace_marker-layer .ace_selection {
    position: absolute;
    z-index: 5;
}

.ace_marker-layer .ace_bracket {
    position: absolute;
    z-index: 6;
}

.ace_marker-layer .ace_error_bracket {
    position: absolute;
    border-bottom: 1px solid #DE5555;
    border-radius: 0;
}

.ace_marker-layer .ace_active-line {
    position: absolute;
    z-index: 2;
}

.ace_marker-layer .ace_selected-word {
    position: absolute;
    z-index: 4;
    box-sizing: border-box;
}

.ace_line .ace_fold {
    box-sizing: border-box;

    display: inline-block;
    height: 11px;
    margin-top: -2px;
    vertical-align: middle;

    background-image:
        url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABEAAAAJCAYAAADU6McMAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAJpJREFUeNpi/P//PwOlgAXGYGRklAVSokD8GmjwY1wasKljQpYACtpCFeADcHVQfQyMQAwzwAZI3wJKvCLkfKBaMSClBlR7BOQikCFGQEErIH0VqkabiGCAqwUadAzZJRxQr/0gwiXIal8zQQPnNVTgJ1TdawL0T5gBIP1MUJNhBv2HKoQHHjqNrA4WO4zY0glyNKLT2KIfIMAAQsdgGiXvgnYAAAAASUVORK5CYII="),
        url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAA3CAYAAADNNiA5AAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAACJJREFUeNpi+P//fxgTAwPDBxDxD078RSX+YeEyDFMCIMAAI3INmXiwf2YAAAAASUVORK5CYII=");
    background-repeat: no-repeat, repeat-x;
    background-position: center center, top left;
    color: transparent;

    border: 1px solid black;
    border-radius: 2px;

    cursor: pointer;
    pointer-events: auto;
}

.ace_dark .ace_fold {
}

.ace_fold:hover{
    background-image:
        url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABEAAAAJCAYAAADU6McMAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAJpJREFUeNpi/P//PwOlgAXGYGRklAVSokD8GmjwY1wasKljQpYACtpCFeADcHVQfQyMQAwzwAZI3wJKvCLkfKBaMSClBlR7BOQikCFGQEErIH0VqkabiGCAqwUadAzZJRxQr/0gwiXIal8zQQPnNVTgJ1TdawL0T5gBIP1MUJNhBv2HKoQHHjqNrA4WO4zY0glyNKLT2KIfIMAAQsdgGiXvgnYAAAAASUVORK5CYII="),
        url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAA3CAYAAADNNiA5AAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAACBJREFUeNpi+P//fz4TAwPDZxDxD5X4i5fLMEwJgAADAEPVDbjNw87ZAAAAAElFTkSuQmCC");
}

.ace_tooltip {
    background-color: #FFF;
    background-image: linear-gradient(to bottom, transparent, rgba(0, 0, 0, 0.1));
    border: 1px solid gray;
    border-radius: 1px;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
    color: black;
    max-width: 100%;
    padding: 3px 4px;
    position: fixed;
    z-index: 999999;
    box-sizing: border-box;
    cursor: default;
    white-space: pre;
    word-wrap: break-word;
    line-height: normal;
    font-style: normal;
    font-weight: normal;
    letter-spacing: normal;
    pointer-events: none;
}

.ace_folding-enabled > .ace_gutter-cell {
    padding-right: 13px;
}

.ace_fold-widget {
    box-sizing: border-box;

    margin: 0 -12px 0 1px;
    display: none;
    width: 11px;
    vertical-align: top;

    background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAANElEQVR42mWKsQ0AMAzC8ixLlrzQjzmBiEjp0A6WwBCSPgKAXoLkqSot7nN3yMwR7pZ32NzpKkVoDBUxKAAAAABJRU5ErkJggg==");
    background-repeat: no-repeat;
    background-position: center;

    border-radius: 3px;
    
    border: 1px solid transparent;
    cursor: pointer;
}

.ace_folding-enabled .ace_fold-widget {
    display: inline-block;   
}

.ace_fold-widget.ace_end {
    background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAANElEQVR42m3HwQkAMAhD0YzsRchFKI7sAikeWkrxwScEB0nh5e7KTPWimZki4tYfVbX+MNl4pyZXejUO1QAAAABJRU5ErkJggg==");
}

.ace_fold-widget.ace_closed {
    background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAMAAAAGCAYAAAAG5SQMAAAAOUlEQVR42jXKwQkAMAgDwKwqKD4EwQ26sSOkVWjgIIHAzPiCgaqiqnJHZnKICBERHN194O5b9vbLuAVRL+l0YWnZAAAAAElFTkSuQmCCXA==");
}

.ace_fold-widget:hover {
    border: 1px solid rgba(0, 0, 0, 0.3);
    background-color: rgba(255, 255, 255, 0.2);
    box-shadow: 0 1px 1px rgba(255, 255, 255, 0.7);
}

.ace_fold-widget:active {
    border: 1px solid rgba(0, 0, 0, 0.4);
    background-color: rgba(0, 0, 0, 0.05);
    box-shadow: 0 1px 1px rgba(255, 255, 255, 0.8);
}
/**
 * Dark version for fold widgets
 */
.ace_dark .ace_fold-widget {
    background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAAHklEQVQIW2P4//8/AzoGEQ7oGCaLLAhWiSwB146BAQCSTPYocqT0AAAAAElFTkSuQmCC");
}
.ace_dark .ace_fold-widget.ace_end {
    background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAAH0lEQVQIW2P4//8/AxQ7wNjIAjDMgC4AxjCVKBirIAAF0kz2rlhxpAAAAABJRU5ErkJggg==");
}
.ace_dark .ace_fold-widget.ace_closed {
    background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAMAAAAFCAYAAACAcVaiAAAAHElEQVQIW2P4//+/AxAzgDADlOOAznHAKgPWAwARji8UIDTfQQAAAABJRU5ErkJggg==");
}
.ace_dark .ace_fold-widget:hover {
    box-shadow: 0 1px 1px rgba(255, 255, 255, 0.2);
    background-color: rgba(255, 255, 255, 0.1);
}
.ace_dark .ace_fold-widget:active {
    box-shadow: 0 1px 1px rgba(255, 255, 255, 0.2);
}

.ace_inline_button {
    border: 1px solid lightgray;
    display: inline-block;
    margin: -1px 8px;
    padding: 0 5px;
    pointer-events: auto;
    cursor: pointer;
}
.ace_inline_button:hover {
    border-color: gray;
    background: rgba(200,200,200,0.2);
    display: inline-block;
    pointer-events: auto;
}

.ace_fold-widget.ace_invalid {
    background-color: #FFB4B4;
    border-color: #DE5555;
}

.ace_fade-fold-widgets .ace_fold-widget {
    transition: opacity 0.4s ease 0.05s;
    opacity: 0;
}

.ace_fade-fold-widgets:hover .ace_fold-widget {
    transition: opacity 0.05s ease 0.05s;
    opacity:1;
}

.ace_underline {
    text-decoration: underline;
}

.ace_bold {
    font-weight: bold;
}

.ace_nobold .ace_bold {
    font-weight: normal;
}

.ace_italic {
    font-style: italic;
}


.ace_error-marker {
    background-color: rgba(255, 0, 0,0.2);
    position: absolute;
    z-index: 9;
}

.ace_highlight-marker {
    background-color: rgba(255, 255, 0,0.2);
    position: absolute;
    z-index: 8;
}

.ace_mobile-menu {
    position: absolute;
    line-height: 1.5;
    border-radius: 4px;
    -ms-user-select: none;
    -moz-user-select: none;
    -webkit-user-select: none;
    user-select: none;
    background: white;
    box-shadow: 1px 3px 2px grey;
    border: 1px solid #dcdcdc;
    color: black;
}
.ace_dark > .ace_mobile-menu {
    background: #333;
    color: #ccc;
    box-shadow: 1px 3px 2px grey;
    border: 1px solid #444;

}
.ace_mobile-button {
    padding: 2px;
    cursor: pointer;
    overflow: hidden;
}
.ace_mobile-button:hover {
    background-color: #eee;
    opacity:1;
}
.ace_mobile-button:active {
    background-color: #ddd;
}

.ace_placeholder {
    font-family: arial;
    transform: scale(0.9);
    transform-origin: left;
    white-space: pre;
    opacity: 0.7;
    margin: 0 10px;
}`}),ace.define("ace/virtual_renderer",["require","exports","module","ace/lib/oop","ace/lib/dom","ace/config","ace/layer/gutter","ace/layer/marker","ace/layer/text","ace/layer/cursor","ace/scrollbar","ace/scrollbar","ace/renderloop","ace/layer/font_metrics","ace/lib/event_emitter","ace/css/editor.css","ace/lib/useragent"],function(C,m,b){function x(I,y){var w=this,I=(this.container=I||l.createElement("div"),l.addCssClass(this.container,"ace_editor"),l.HI_DPI&&l.addCssClass(this.container,"ace_hidpi"),this.setTheme(y),s.get("useStrictCSP")==null&&s.set("useStrictCSP",!1),this.$gutter=l.createElement("div"),this.$gutter.className="ace_gutter",this.container.appendChild(this.$gutter),this.$gutter.setAttribute("aria-hidden",!0),this.scroller=l.createElement("div"),this.scroller.className="ace_scroller",this.container.appendChild(this.scroller),this.content=l.createElement("div"),this.content.className="ace_content",this.scroller.appendChild(this.content),this.$gutterLayer=new n(this.$gutter),this.$gutterLayer.on("changeGutterWidth",this.onGutterResize.bind(this)),this.$markerBack=new t(this.content),this.$textLayer=new i(this.content));this.canvas=I.element,this.$markerFront=new t(this.content),this.$cursorLayer=new e(this.content),this.$horizScroll=!1,this.$vScroll=!1,this.scrollBar=this.scrollBarV=new a(this.container,this),this.scrollBarH=new r(this.container,this),this.scrollBarV.on("scroll",function(T){w.$scrollAnimation||w.session.setScrollTop(T.data-w.scrollMargin.top)}),this.scrollBarH.on("scroll",function(T){w.$scrollAnimation||w.session.setScrollLeft(T.data-w.scrollMargin.left)}),this.scrollTop=0,this.scrollLeft=0,this.cursorPos={row:0,column:0},this.$fontMetrics=new c(this.container),this.$textLayer.$setFontMetrics(this.$fontMetrics),this.$textLayer.on("changeCharacterSize",function(T){w.updateCharacterSize(),w.onResize(!0,w.gutterWidth,w.$size.width,w.$size.height),w._signal("changeCharacterSize",T)}),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=!v.isIOS,this.$loop=new o(this.$renderChanges.bind(this),this.container.ownerDocument.defaultView),this.$loop.schedule(this.CHANGE_FULL),this.updateCharacterSize(),this.setPadding(4),s.resetOptions(this),s._signal("renderer",this)}var p=C("./lib/oop"),l=C("./lib/dom"),s=C("./config"),n=C("./layer/gutter").Gutter,t=C("./layer/marker").Marker,i=C("./layer/text").Text,e=C("./layer/cursor").Cursor,r=C("./scrollbar").HScrollBar,a=C("./scrollbar").VScrollBar,o=C("./renderloop").RenderLoop,c=C("./layer/font_metrics").FontMetrics,h=C("./lib/event_emitter").EventEmitter,A=C("./css/editor.css"),v=C("./lib/useragent"),d=v.isIE;l.importCssString(A,"ace_editor.css",!1),function(){this.CHANGE_CURSOR=1,this.CHANGE_MARKER=2,this.CHANGE_GUTTER=4,this.CHANGE_SCROLL=8,this.CHANGE_LINES=16,this.CHANGE_TEXT=32,this.CHANGE_SIZE=64,this.CHANGE_MARKER_BACK=128,this.CHANGE_MARKER_FRONT=256,this.CHANGE_FULL=512,this.CHANGE_H_SCROLL=1024,p.implement(this,h),this.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(),l.setStyle(this.scroller.style,"line-height",this.lineHeight+"px")},this.setSession=function(g){this.session&&this.session.doc.off("changeNewLineMode",this.onChangeNewLineMode),(this.session=g)&&this.scrollMargin.top&&g.getScrollTop()<=0&&g.setScrollTop(-this.scrollMargin.top),this.$cursorLayer.setSession(g),this.$markerBack.setSession(g),this.$markerFront.setSession(g),this.$gutterLayer.setSession(g),this.$textLayer.setSession(g),g&&(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))},this.updateLines=function(g,y,w){if(y===void 0&&(y=1/0),this.$changedLines?(this.$changedLines.firstRow>g&&(this.$changedLines.firstRow=g),this.$changedLines.lastRow<y&&(this.$changedLines.lastRow=y)):this.$changedLines={firstRow:g,lastRow:y},this.$changedLines.lastRow<this.layerConfig.firstRow){if(!w)return;this.$changedLines.lastRow=this.layerConfig.lastRow}this.$changedLines.firstRow>this.layerConfig.lastRow||this.$loop.schedule(this.CHANGE_LINES)},this.onChangeNewLineMode=function(){this.$loop.schedule(this.CHANGE_TEXT),this.$textLayer.$updateEolChar(),this.session.$bidiHandler.setEolChar(this.$textLayer.EOL_CHAR)},this.onChangeTabSize=function(){this.$loop.schedule(this.CHANGE_TEXT|this.CHANGE_MARKER),this.$textLayer.onChangeTabSize()},this.updateText=function(){this.$loop.schedule(this.CHANGE_TEXT)},this.updateFull=function(g){g?this.$renderChanges(this.CHANGE_FULL,!0):this.$loop.schedule(this.CHANGE_FULL)},this.updateFontSize=function(){this.$textLayer.checkForSizeChanges()},this.$changes=0,this.$updateSizeAsync=function(){this.$loop.pending?this.$size.$dirty=!0:this.onResize()},this.onResize=function(g,y,w,I){if(!(2<this.resizing)){0<this.resizing?this.resizing++:this.resizing=g?1:0;var T=this.container,T=(I=I||T.clientHeight||T.scrollHeight,w=w||T.clientWidth||T.scrollWidth,this.$updateCachedSize(g,y,w,I));if(!this.$size.scrollerHeight||!w&&!I)return this.resizing=0;g&&(this.$gutterLayer.$padding=null),g?this.$renderChanges(T|this.$changes,!0):this.$loop.schedule(T|this.$changes),this.resizing&&(this.resizing=0),this.scrollBarH.scrollLeft=this.scrollBarV.scrollTop=null}},this.$updateCachedSize=function(g,y,w,I){I-=this.$extraHeight||0;var T=0,B=this.$size,E={width:B.width,height:B.height,scrollerHeight:B.scrollerHeight,scrollerWidth:B.scrollerWidth};return I&&(g||B.height!=I)&&(B.height=I,T|=this.CHANGE_SIZE,B.scrollerHeight=B.height,this.$horizScroll&&(B.scrollerHeight-=this.scrollBarH.getHeight()),this.scrollBarV.element.style.bottom=this.scrollBarH.getHeight()+"px",T|=this.CHANGE_SCROLL),w&&(g||B.width!=w)&&(T|=this.CHANGE_SIZE,B.width=w,y==null&&(y=this.$showGutter?this.$gutter.offsetWidth:0),this.gutterWidth=y,l.setStyle(this.scrollBarH.element.style,"left",y+"px"),l.setStyle(this.scroller.style,"left",y+this.margin.left+"px"),B.scrollerWidth=Math.max(0,w-y-this.scrollBarV.getWidth()-this.margin.h),l.setStyle(this.$gutter.style,"left",this.margin.left+"px"),y=this.scrollBarV.getWidth()+"px",l.setStyle(this.scrollBarH.element.style,"right",y),l.setStyle(this.scroller.style,"right",y),l.setStyle(this.scroller.style,"bottom",this.scrollBarH.getHeight()),(this.session&&this.session.getUseWrapMode()&&this.adjustWrapLimit()||g)&&(T|=this.CHANGE_FULL)),B.$dirty=!w||!I,T&&this._signal("resize",E),T},this.onGutterResize=function(g){g=this.$showGutter?g:0,g!=this.gutterWidth&&(this.$changes|=this.$updateCachedSize(!0,g,this.$size.width,this.$size.height)),this.session.getUseWrapMode()&&this.adjustWrapLimit()||this.$size.$dirty?this.$loop.schedule(this.CHANGE_FULL):this.$computeLayerConfig()},this.adjustWrapLimit=function(){var g=this.$size.scrollerWidth-2*this.$padding,g=Math.floor(g/this.characterWidth);return this.session.adjustWrapLimit(g,this.$showPrintMargin&&this.$printMarginColumn)},this.setAnimatedScroll=function(g){this.setOption("animatedScroll",g)},this.getAnimatedScroll=function(){return this.$animatedScroll},this.setShowInvisibles=function(g){this.setOption("showInvisibles",g),this.session.$bidiHandler.setShowInvisibles(g)},this.getShowInvisibles=function(){return this.getOption("showInvisibles")},this.getDisplayIndentGuides=function(){return this.getOption("displayIndentGuides")},this.setDisplayIndentGuides=function(g){this.setOption("displayIndentGuides",g)},this.getHighlightIndentGuides=function(){return this.getOption("highlightIndentGuides")},this.setHighlightIndentGuides=function(g){this.setOption("highlightIndentGuides",g)},this.setShowPrintMargin=function(g){this.setOption("showPrintMargin",g)},this.getShowPrintMargin=function(){return this.getOption("showPrintMargin")},this.setPrintMarginColumn=function(g){this.setOption("printMarginColumn",g)},this.getPrintMarginColumn=function(){return this.getOption("printMarginColumn")},this.getShowGutter=function(){return this.getOption("showGutter")},this.setShowGutter=function(g){return this.setOption("showGutter",g)},this.getFadeFoldWidgets=function(){return this.getOption("fadeFoldWidgets")},this.setFadeFoldWidgets=function(g){this.setOption("fadeFoldWidgets",g)},this.setHighlightGutterLine=function(g){this.setOption("highlightGutterLine",g)},this.getHighlightGutterLine=function(){return this.getOption("highlightGutterLine")},this.$updatePrintMargin=function(){var g;(this.$showPrintMargin||this.$printMarginEl)&&(this.$printMarginEl||((g=l.createElement("div")).className="ace_layer ace_print-margin-layer",this.$printMarginEl=l.createElement("div"),this.$printMarginEl.className="ace_print-margin",g.appendChild(this.$printMarginEl),this.content.insertBefore(g,this.content.firstChild)),(g=this.$printMarginEl.style).left=Math.round(this.characterWidth*this.$printMarginColumn+this.$padding)+"px",g.visibility=this.$showPrintMargin?"visible":"hidden",this.session&&this.session.$wrap==-1&&this.adjustWrapLimit())},this.getContainerElement=function(){return this.container},this.getMouseEventTarget=function(){return this.scroller},this.getTextAreaContainer=function(){return this.container},this.$moveTextAreaToCursor=function(){var g,y,w,I,T,B,E;this.$isMousePressed||(g=this.textarea.style,B=this.$composition,this.$keepTextAreaAtCursor||B?(w=this.$cursorLayer.$pixelPos)&&(B&&B.markerRange&&(w=this.$cursorLayer.getPixelPosition(B.markerRange.start,!0)),E=this.layerConfig,y=w.top,w=w.left,y-=E.offset,I=B&&B.useTextareaForIME?this.lineHeight:d?0:1,y<0||y>E.height-I?l.translate(this.textarea,0,0):(E=1,T=this.$size.height-I,B?B.useTextareaForIME?(B=this.textarea.value,E=this.characterWidth*this.session.$getStringScreenWidth(B)[0]):y+=this.lineHeight+2:y+=this.lineHeight,(w-=this.scrollLeft)>this.$size.scrollerWidth-E&&(w=this.$size.scrollerWidth-E),w+=this.gutterWidth+this.margin.left,l.setStyle(g,"height",I+"px"),l.setStyle(g,"width",E+"px"),l.translate(this.textarea,Math.min(w,this.$size.scrollerWidth-E),Math.min(y,T)))):l.translate(this.textarea,-100,0))},this.getFirstVisibleRow=function(){return this.layerConfig.firstRow},this.getFirstFullyVisibleRow=function(){return this.layerConfig.firstRow+(this.layerConfig.offset===0?0:1)},this.getLastFullyVisibleRow=function(){var g=this.layerConfig,y=g.lastRow;return this.session.documentToScreenRow(y,0)*g.lineHeight-this.session.getScrollTop()>g.height-g.lineHeight?y-1:y},this.getLastVisibleRow=function(){return this.layerConfig.lastRow},this.$padding=null,this.setPadding=function(g){this.$padding=g,this.$textLayer.setPadding(g),this.$cursorLayer.setPadding(g),this.$markerFront.setPadding(g),this.$markerBack.setPadding(g),this.$loop.schedule(this.CHANGE_FULL),this.$updatePrintMargin()},this.setScrollMargin=function(g,y,w,I){var T=this.scrollMargin;T.top=0|g,T.bottom=0|y,T.right=0|I,T.left=0|w,T.v=T.top+T.bottom,T.h=T.left+T.right,T.top&&this.scrollTop<=0&&this.session&&this.session.setScrollTop(-T.top),this.updateFull()},this.setMargin=function(g,y,w,I){var T=this.margin;T.top=0|g,T.bottom=0|y,T.right=0|I,T.left=0|w,T.v=T.top+T.bottom,T.h=T.left+T.right,this.$updateCachedSize(!0,this.gutterWidth,this.$size.width,this.$size.height),this.updateFull()},this.getHScrollBarAlwaysVisible=function(){return this.$hScrollBarAlwaysVisible},this.setHScrollBarAlwaysVisible=function(g){this.setOption("hScrollBarAlwaysVisible",g)},this.getVScrollBarAlwaysVisible=function(){return this.$vScrollBarAlwaysVisible},this.setVScrollBarAlwaysVisible=function(g){this.setOption("vScrollBarAlwaysVisible",g)},this.$updateScrollBarV=function(){var g=this.layerConfig.maxHeight,y=this.$size.scrollerHeight;!this.$maxLines&&this.$scrollPastEnd&&(g-=(y-this.lineHeight)*this.$scrollPastEnd,this.scrollTop>g-y&&(g=this.scrollTop+y,this.scrollBarV.scrollTop=null)),this.scrollBarV.setScrollHeight(g+this.scrollMargin.v),this.scrollBarV.setScrollTop(this.scrollTop+this.scrollMargin.top)},this.$updateScrollBarH=function(){this.scrollBarH.setScrollWidth(this.layerConfig.width+2*this.$padding+this.scrollMargin.h),this.scrollBarH.setScrollLeft(this.scrollLeft+this.scrollMargin.left)},this.$frozen=!1,this.freeze=function(){this.$frozen=!0},this.unfreeze=function(){this.$frozen=!1},this.$renderChanges=function(g,y){if(this.$changes&&(g|=this.$changes,this.$changes=0),this.session&&this.container.offsetWidth&&!this.$frozen&&(g||y)){if(this.$size.$dirty)return this.$changes|=g,this.onResize(!0);this.lineHeight||this.$textLayer.checkForSizeChanges(),this._signal("beforeRender",g),this.session&&this.session.$bidiHandler&&this.session.$bidiHandler.updateCharacterWidths(this.$fontMetrics);var w,I,y=this.layerConfig;(g&this.CHANGE_FULL||g&this.CHANGE_SIZE||g&this.CHANGE_TEXT||g&this.CHANGE_LINES||g&this.CHANGE_SCROLL||g&this.CHANGE_H_SCROLL)&&(g|=this.$computeLayerConfig()|this.$loop.clear(),y.firstRow!=this.layerConfig.firstRow&&y.firstRowScreen==this.layerConfig.firstRowScreen&&0<(w=this.scrollTop+(y.firstRow-this.layerConfig.firstRow)*this.lineHeight)&&(this.scrollTop=w,g=(g|=this.CHANGE_SCROLL)|(this.$computeLayerConfig()|this.$loop.clear())),y=this.layerConfig,this.$updateScrollBarV(),g&this.CHANGE_H_SCROLL&&this.$updateScrollBarH(),l.translate(this.content,-this.scrollLeft,-y.offset),w=y.width+2*this.$padding+"px",I=y.minHeight+"px",l.setStyle(this.content.style,"width",w),l.setStyle(this.content.style,"height",I)),g&this.CHANGE_H_SCROLL&&(l.translate(this.content,-this.scrollLeft,-y.offset),this.scroller.className=this.scrollLeft<=0?"ace_scroller":"ace_scroller ace_scroll-left"),g&this.CHANGE_FULL?(this.$changedLines=null,this.$textLayer.update(y),this.$showGutter&&this.$gutterLayer.update(y),this.$markerBack.update(y),this.$markerFront.update(y),this.$cursorLayer.update(y),this.$moveTextAreaToCursor()):g&this.CHANGE_SCROLL?(this.$changedLines=null,g&this.CHANGE_TEXT||g&this.CHANGE_LINES?this.$textLayer.update(y):this.$textLayer.scrollLines(y),this.$showGutter&&(g&this.CHANGE_GUTTER||g&this.CHANGE_LINES?this.$gutterLayer.update(y):this.$gutterLayer.scrollLines(y)),this.$markerBack.update(y),this.$markerFront.update(y),this.$cursorLayer.update(y),this.$moveTextAreaToCursor()):(g&this.CHANGE_TEXT?(this.$changedLines=null,this.$textLayer.update(y),this.$showGutter&&this.$gutterLayer.update(y)):g&this.CHANGE_LINES?(this.$updateLines()||g&this.CHANGE_GUTTER&&this.$showGutter)&&this.$gutterLayer.update(y):g&this.CHANGE_TEXT||g&this.CHANGE_GUTTER?this.$showGutter&&this.$gutterLayer.update(y):g&this.CHANGE_CURSOR&&this.$highlightGutterLine&&this.$gutterLayer.updateLineHighlight(y),g&this.CHANGE_CURSOR&&(this.$cursorLayer.update(y),this.$moveTextAreaToCursor()),g&(this.CHANGE_MARKER|this.CHANGE_MARKER_FRONT)&&this.$markerFront.update(y),g&(this.CHANGE_MARKER|this.CHANGE_MARKER_BACK)&&this.$markerBack.update(y)),this._signal("afterRender",g)}else this.$changes|=g},this.$autosize=function(){var g=this.session.getScreenLength()*this.lineHeight,y=this.$maxLines*this.lineHeight,w=Math.min(y,Math.max((this.$minLines||1)*this.lineHeight,g))+this.scrollMargin.v+(this.$extraHeight||0);this.$horizScroll&&(w+=this.scrollBarH.getHeight()),y=!((w=this.$maxPixelHeight&&w>this.$maxPixelHeight?this.$maxPixelHeight:w)<=2*this.lineHeight)&&y<g,w==this.desiredHeight&&this.$size.height==this.desiredHeight&&y==this.$vScroll||(y!=this.$vScroll&&(this.$vScroll=y,this.scrollBarV.setVisible(y)),g=this.container.clientWidth,this.container.style.height=w+"px",this.$updateCachedSize(!0,this.$gutterWidth,g,w),this.desiredHeight=w,this._signal("autosize"))},this.$computeLayerConfig=function(){var g,Y=this.session,y=this.$size,z=y.height<=2*this.lineHeight,w=this.session.getScreenLength()*this.lineHeight,I=this.$getLongestLine(),P=!z&&(this.$hScrollBarAlwaysVisible||y.scrollerWidth-I-2*this.$padding<0),T=this.$horizScroll!==P,P=(T&&(this.$horizScroll=P,this.scrollBarH.setVisible(P)),this.$vScroll),B=(this.$maxLines&&1<this.lineHeight&&this.$autosize(),y.scrollerHeight+this.lineHeight),E=!this.$maxLines&&this.$scrollPastEnd?(y.scrollerHeight-this.lineHeight)*this.$scrollPastEnd:0,_=(w+=E,this.scrollMargin),z=(this.session.setScrollTop(Math.max(-_.top,Math.min(this.scrollTop,w-y.scrollerHeight+_.bottom))),this.session.setScrollLeft(Math.max(-_.left,Math.min(this.scrollLeft,I+2*this.$padding-y.scrollerWidth+_.right))),!z&&(this.$vScrollBarAlwaysVisible||y.scrollerHeight-w+E<0||this.scrollTop>_.top)),E=P!==z,_=(E&&(this.$vScroll=z,this.scrollBarV.setVisible(z)),this.scrollTop%this.lineHeight),P=Math.ceil(B/this.lineHeight)-1,P=(z=Math.max(0,Math.round((this.scrollTop-_)/this.lineHeight)))+P,j=this.lineHeight,z=Y.screenToDocumentRow(z,0),D=Y.getFoldLine(z),Y=(D&&(z=D.start.row),D=Y.documentToScreenRow(z,0),g=Y.getRowLength(z)*j,P=Math.min(Y.screenToDocumentRow(P,0),Y.getLength()-1),B=y.scrollerHeight+Y.getRowLength(P)*j+g,_=this.scrollTop-D*j,0);return this.layerConfig.width==I&&!T||(Y=this.CHANGE_H_SCROLL),(T||E)&&(Y|=this.$updateCachedSize(!0,this.gutterWidth,y.width,y.height),this._signal("scrollbarVisibilityChanged"),E&&(I=this.$getLongestLine())),this.layerConfig={width:I,padding:this.$padding,firstRow:z,firstRowScreen:D,lastRow:P,lineHeight:j,characterWidth:this.characterWidth,minHeight:B,maxHeight:w,offset:_,gutterOffset:j?Math.max(0,Math.ceil((_+y.height-y.scrollerHeight)/j)):0,height:this.$size.scrollerHeight},this.session.$bidiHandler&&this.session.$bidiHandler.setContentWidth(I-this.$padding),Y},this.$updateLines=function(){if(this.$changedLines){var g=this.$changedLines.firstRow,y=this.$changedLines.lastRow,w=(this.$changedLines=null,this.layerConfig);if(!(g>w.lastRow+1||y<w.firstRow)){if(y!==1/0)return this.$textLayer.updateLines(w,g,y),!0;this.$showGutter&&this.$gutterLayer.update(w),this.$textLayer.update(w)}}},this.$getLongestLine=function(){var g=this.session.getScreenWidth();return this.showInvisibles&&!this.session.$useWrapMode&&(g+=1),this.$textLayer&&g>this.$textLayer.MAX_LINE_LENGTH&&(g=this.$textLayer.MAX_LINE_LENGTH+30),Math.max(this.$size.scrollerWidth-2*this.$padding,Math.round(g*this.characterWidth))},this.updateFrontMarkers=function(){this.$markerFront.setMarkers(this.session.getMarkers(!0)),this.$loop.schedule(this.CHANGE_MARKER_FRONT)},this.updateBackMarkers=function(){this.$markerBack.setMarkers(this.session.getMarkers()),this.$loop.schedule(this.CHANGE_MARKER_BACK)},this.addGutterDecoration=function(g,y){this.$gutterLayer.addGutterDecoration(g,y)},this.removeGutterDecoration=function(g,y){this.$gutterLayer.removeGutterDecoration(g,y)},this.updateBreakpoints=function(g){this.$loop.schedule(this.CHANGE_GUTTER)},this.setAnnotations=function(g){this.$gutterLayer.setAnnotations(g),this.$loop.schedule(this.CHANGE_GUTTER)},this.updateCursor=function(){this.$loop.schedule(this.CHANGE_CURSOR)},this.hideCursor=function(){this.$cursorLayer.hideCursor()},this.showCursor=function(){this.$cursorLayer.showCursor()},this.scrollSelectionIntoView=function(g,y,w){this.scrollCursorIntoView(g,w),this.scrollCursorIntoView(y,w)},this.scrollCursorIntoView=function(g,y,w){var I,T,B;this.$size.scrollerHeight!==0&&(I=(g=this.$cursorLayer.getPixelPosition(g)).left,g=g.top,B=w&&w.top||0,w=w&&w.bottom||0,g<(T=this.$scrollAnimation?this.session.getScrollTop():this.scrollTop)+B?(y&&T+B>g+this.lineHeight&&(g-=y*this.$size.scrollerHeight),g===0&&(g=-this.scrollMargin.top),this.session.setScrollTop(g)):T+this.$size.scrollerHeight-w<g+this.lineHeight&&(y&&T+this.$size.scrollerHeight-w<g-this.lineHeight&&(g+=y*this.$size.scrollerHeight),this.session.setScrollTop(g+this.lineHeight+w-this.$size.scrollerHeight)),I<(B=this.scrollLeft)?(I<this.$padding+2*this.layerConfig.characterWidth&&(I=-this.scrollMargin.left),this.session.setScrollLeft(I)):B+this.$size.scrollerWidth<I+this.characterWidth?this.session.setScrollLeft(Math.round(I+this.characterWidth-this.$size.scrollerWidth)):B<=this.$padding&&I-B<this.characterWidth&&this.session.setScrollLeft(0))},this.getScrollTop=function(){return this.session.getScrollTop()},this.getScrollLeft=function(){return this.session.getScrollLeft()},this.getScrollTopRow=function(){return this.scrollTop/this.lineHeight},this.getScrollBottomRow=function(){return Math.max(0,Math.floor((this.scrollTop+this.$size.scrollerHeight)/this.lineHeight)-1)},this.scrollToRow=function(g){this.session.setScrollTop(g*this.lineHeight)},this.alignCursor=function(I,y){var I=this.$cursorLayer.getPixelPosition(I=typeof I=="number"?{row:I,column:0}:I),w=this.$size.scrollerHeight-this.lineHeight,I=I.top-w*(y||0);return this.session.setScrollTop(I),I},this.STEPS=8,this.$calcSteps=function(g,y){for(var w,I,E=0,T=this.STEPS,B=[],E=0;E<T;++E)B.push((w=E/this.STEPS,(y-(I=g))*(Math.pow(w-1,3)+1)+I));return B},this.scrollToLine=function(g,y,w,I){g=this.$cursorLayer.getPixelPosition({row:g,column:0}).top,y&&(g-=this.$size.scrollerHeight/2),y=this.scrollTop,this.session.setScrollTop(g),w!==!1&&this.animateScrolling(y,I)},this.animateScrolling=function(g,y){var w=this.scrollTop;if(this.$animatedScroll){var I=this;if(g!=w){if(this.$scrollAnimation){var T=this.$scrollAnimation.steps;if(T.length&&(g=T[0])==w)return}var B=I.$calcSteps(g,w);this.$scrollAnimation={from:g,to:w,steps:B},clearInterval(this.$timer),I.session.setScrollTop(B.shift()),I.session.$scrollTop=w,this.$timer=setInterval(function(){if(!I.session)return clearInterval(I.$timer);B.length?(I.session.setScrollTop(B.shift()),I.session.$scrollTop=w):w!=null?(I.session.$scrollTop=-1,I.session.setScrollTop(w),w=null):(I.$timer=clearInterval(I.$timer),I.$scrollAnimation=null,y&&y())},10)}}},this.scrollToY=function(g){this.scrollTop!==g&&(this.$loop.schedule(this.CHANGE_SCROLL),this.scrollTop=g)},this.scrollToX=function(g){this.scrollLeft!==g&&(this.scrollLeft=g),this.$loop.schedule(this.CHANGE_H_SCROLL)},this.scrollTo=function(g,y){this.session.setScrollTop(y),this.session.setScrollLeft(g)},this.scrollBy=function(g,y){y&&this.session.setScrollTop(this.session.getScrollTop()+y),g&&this.session.setScrollLeft(this.session.getScrollLeft()+g)},this.isScrollableBy=function(g,y){return y<0&&this.session.getScrollTop()>=1-this.scrollMargin.top||0<y&&this.session.getScrollTop()+this.$size.scrollerHeight-this.layerConfig.maxHeight<-1+this.scrollMargin.bottom||g<0&&this.session.getScrollLeft()>=1-this.scrollMargin.left||0<g&&this.session.getScrollLeft()+this.$size.scrollerWidth-this.layerConfig.width<-1+this.scrollMargin.right||void 0},this.pixelToScreenCoordinates=function(I,T){this.$hasCssTransforms?(B={top:0,left:0},I=(w=this.$fontMetrics.transformCoordinates([I,T]))[1]-this.gutterWidth-this.margin.left,T=w[0]):B=this.scroller.getBoundingClientRect();var w=I+this.scrollLeft-B.left-this.$padding,I=w/this.characterWidth,T=Math.floor((T+this.scrollTop-B.top)/this.lineHeight),B=this.$blockCursor?Math.floor(I):Math.round(I);return{row:T,column:B,side:0<I-B?1:-1,offsetX:w}},this.screenToTextCoordinates=function(T,B){this.$hasCssTransforms?(w={top:0,left:0},T=(I=this.$fontMetrics.transformCoordinates([T,B]))[1]-this.gutterWidth-this.margin.left,B=I[0]):w=this.scroller.getBoundingClientRect();var w,I=T+this.scrollLeft-w.left-this.$padding,T=I/this.characterWidth,T=this.$blockCursor?Math.floor(T):Math.round(T),B=Math.floor((B+this.scrollTop-w.top)/this.lineHeight);return this.session.screenToDocumentPosition(B,Math.max(T,0),I)},this.textToScreenCoordinates=function(I,T){var w=this.scroller.getBoundingClientRect(),T=this.session.documentToScreenPosition(I,T),I=this.$padding+(this.session.$bidiHandler.isBidiRow(T.row,I)?this.session.$bidiHandler.getPosLeft(T.column):Math.round(T.column*this.characterWidth)),T=T.row*this.lineHeight;return{pageX:w.left+I-this.scrollLeft,pageY:w.top+T-this.scrollTop}},this.visualizeFocus=function(){l.addCssClass(this.container,"ace_focus")},this.visualizeBlur=function(){l.removeCssClass(this.container,"ace_focus")},this.showComposition=function(g){(this.$composition=g).cssText||(g.cssText=this.textarea.style.cssText),g.useTextareaForIME==null&&(g.useTextareaForIME=this.$useTextareaForIME),this.$useTextareaForIME?(l.addCssClass(this.textarea,"ace_composition"),this.textarea.style.cssText="",this.$moveTextAreaToCursor(),this.$cursorLayer.element.style.display="none"):g.markerId=this.session.addMarker(g.markerRange,"ace_composition_marker","text")},this.setCompositionText=function(g){var y=this.session.selection.cursor;this.addToken(g,"composition_placeholder",y.row,y.column),this.$moveTextAreaToCursor()},this.hideComposition=function(){var g;this.$composition&&(this.$composition.markerId&&this.session.removeMarker(this.$composition.markerId),l.removeCssClass(this.textarea,"ace_composition"),this.textarea.style.cssText=this.$composition.cssText,g=this.session.selection.cursor,this.removeExtraToken(g.row,g.column),this.$composition=null,this.$cursorLayer.element.style.display="")},this.addToken=function(g,y,w,I){var T=this.session,B=(T.bgTokenizer.lines[w]=null,{type:y,value:g}),E=T.getTokens(w);if(I==null)E.push(B);else for(var _=0,P=0;P<E.length;P++){var j=E[P];if(I<=(_+=j.value.length)){var D=j.value.length-(_-I),z=j.value.slice(0,D),D=j.value.slice(D);E.splice(P,1,{type:j.type,value:z},B,{type:j.type,value:D});break}}this.updateLines(w,w)},this.removeExtraToken=function(g,y){this.updateLines(g,g)},this.setTheme=function(g,y){var w,I=this;function T(B){if(I.$themeId!=g)return y&&y();if(!B||!B.cssClass)throw new Error("couldn't load module "+g+" or it didn't call define");B.$id&&(I.$themeId=B.$id),l.importCssString(B.cssText,B.cssClass,I.container),I.theme&&l.removeCssClass(I.container,I.theme.cssClass);var E="padding"in B?B.padding:"padding"in(I.theme||{})?4:I.$padding;I.$padding&&E!=I.$padding&&I.setPadding(E),I.$theme=B.cssClass,I.theme=B,l.addCssClass(I.container,B.cssClass),l.setCssClass(I.container,"ace_dark",B.isDark),I.$size&&(I.$size.width=0,I.$updateSizeAsync()),I._dispatchEvent("themeLoaded",{theme:B}),y&&y()}this.$themeId=g,I._dispatchEvent("themeChange",{theme:g}),g&&typeof g!="string"?T(g):(w=g||this.$options.theme.initialValue,s.loadModule(["theme",w],T))},this.getTheme=function(){return this.$themeId},this.setStyle=function(g,y){l.setCssClass(this.container,g,y!==!1)},this.unsetStyle=function(g){l.removeCssClass(this.container,g)},this.setCursorStyle=function(g){l.setStyle(this.scroller.style,"cursor",g)},this.setMouseCursor=function(g){l.setStyle(this.scroller.style,"cursor",g)},this.attachToShadowRoot=function(){l.importCssString(A,"ace_editor.css",this.container)},this.destroy=function(){this.freeze(),this.$fontMetrics.destroy(),this.$cursorLayer.destroy(),this.removeAllListeners(),this.container.textContent=""}}.call(x.prototype),s.defineOptions(x.prototype,"renderer",{animatedScroll:{initialValue:!1},showInvisibles:{set:function(g){this.$textLayer.setShowInvisibles(g)&&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(g){typeof g=="number"&&(this.$printMarginColumn=g),this.$showPrintMargin=!!g,this.$updatePrintMargin()},get:function(){return this.$showPrintMargin&&this.$printMarginColumn}},showGutter:{set:function(g){this.$gutter.style.display=g?"block":"none",this.$loop.schedule(this.CHANGE_FULL),this.onGutterResize()},initialValue:!0},fadeFoldWidgets:{set:function(g){l.setCssClass(this.$gutter,"ace_fade-fold-widgets",g)},initialValue:!1},showFoldWidgets:{set:function(g){this.$gutterLayer.setShowFoldWidgets(g),this.$loop.schedule(this.CHANGE_GUTTER)},initialValue:!0},displayIndentGuides:{set:function(g){this.$textLayer.setDisplayIndentGuides(g)&&this.$loop.schedule(this.CHANGE_TEXT)},initialValue:!0},highlightIndentGuides:{set:function(g){this.$textLayer.setHighlightIndentGuides(g)==1?this.$textLayer.$highlightIndentGuide():this.$textLayer.$clearActiveIndentGuide(this.$textLayer.$lines.cells)},initialValue:!0},highlightGutterLine:{set:function(g){this.$gutterLayer.setHighlightGutterLine(g),this.$loop.schedule(this.CHANGE_GUTTER)},initialValue:!0},hScrollBarAlwaysVisible:{set:function(g){this.$hScrollBarAlwaysVisible&&this.$horizScroll||this.$loop.schedule(this.CHANGE_SCROLL)},initialValue:!1},vScrollBarAlwaysVisible:{set:function(g){this.$vScrollBarAlwaysVisible&&this.$vScroll||this.$loop.schedule(this.CHANGE_SCROLL)},initialValue:!1},fontSize:{set:function(g){typeof g=="number"&&(g+="px"),this.container.style.fontSize=g,this.updateFontSize()},initialValue:12},fontFamily:{set:function(g){this.container.style.fontFamily=g,this.updateFontSize()}},maxLines:{set:function(g){this.updateFull()}},minLines:{set:function(g){this.$minLines<562949953421311||(this.$minLines=0),this.updateFull()}},maxPixelHeight:{set:function(g){this.updateFull()},initialValue:0},scrollPastEnd:{set:function(g){this.$scrollPastEnd!=(g=+g||0)&&(this.$scrollPastEnd=g,this.$loop.schedule(this.CHANGE_SCROLL))},initialValue:0,handlesSet:!0},fixedWidthGutter:{set:function(g){this.$gutterLayer.$fixedWidth=!!g,this.$loop.schedule(this.CHANGE_GUTTER)}},theme:{set:function(g){this.setTheme(g)},get:function(){return this.$themeId||this.theme},initialValue:"./theme/textmate",handlesSet:!0},hasCssTransforms:{},useTextareaForIME:{initialValue:!v.isMobile&&!v.isIE}}),m.VirtualRenderer=x}),ace.define("ace/worker/worker_client",["require","exports","module","ace/lib/oop","ace/lib/net","ace/lib/event_emitter","ace/config"],function(C,m,b){var x=C("../lib/oop"),p=C("../lib/net"),l=C("../lib/event_emitter").EventEmitter,s=C("../config");function n(i){var e;return typeof Worker=="undefined"?{postMessage:function(){},terminate:function(){}}:s.get("loadWorkerFromBlob")?(e=function(r){r="importScripts('"+p.qualifyURL(r)+"');";try{return new Blob([r],{type:"application/javascript"})}catch{var a=new(window.BlobBuilder||window.WebKitBlobBuilder||window.MozBlobBuilder);return a.append(r),a.getBlob("application/javascript")}}(i),e=(window.URL||window.webkitURL).createObjectURL(e),new Worker(e)):new Worker(i)}function t(i){i.postMessage||(i=this.$createWorkerFromOldConfig.apply(this,arguments)),this.$worker=i,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(){x.implement(this,l),this.$createWorkerFromOldConfig=function(i,e,r,a,o){var c,h;return C.nameToUrl&&!C.toUrl&&(C.toUrl=C.nameToUrl),s.get("packaged")||!C.toUrl?a=a||s.moduleUrl(e,"worker"):(c=this.$normalizePath,a=a||c(C.toUrl("ace/worker/worker.js",null,"_")),h={},i.forEach(function(A){h[A]=c(C.toUrl(A,null,"_").replace(/(\.js)?(\?.*)?$/,""))})),this.$worker=n(a),o&&this.send("importScripts",o),this.$worker.postMessage({init:!0,tlns:h,module:e,classname:r}),this.$worker},this.onMessage=function(i){var e=i.data;switch(e.type){case"event":this._signal(e.name,{data:e.data});break;case"call":var r=this.callbacks[e.id];r&&(r(e.data),delete this.callbacks[e.id]);break;case"error":this.reportError(e.data);break;case"log":window.console&&console.log&&console.log.apply(console,e.data)}},this.reportError=function(i){window.console&&console.error&&console.error(i)},this.$normalizePath=function(i){return p.qualifyURL(i)},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(i,e){this.$worker.postMessage({command:i,args:e})},this.call=function(i,e,r){var a;r&&(a=this.callbackId++,this.callbacks[a]=r,e.push(a)),this.send(i,e)},this.emit=function(i,e){try{e.data&&e.data.err&&(e.data.err={message:e.data.err.message,stack:e.data.err.stack,code:e.data.err.code}),this.$worker&&this.$worker.postMessage({event:i,data:{data:e.data}})}catch(r){console.error(r.stack)}},this.attachToDocument=function(i){this.$doc&&this.terminate(),this.$doc=i,this.call("setValue",[i.getValue()]),i.on("change",this.changeListener,!0)},this.changeListener=function(i){this.deltaQueue||(this.deltaQueue=[],setTimeout(this.$sendDeltaQueue,0)),i.action=="insert"?this.deltaQueue.push(i.start,i.lines):this.deltaQueue.push(i.start,i.end)},this.$sendDeltaQueue=function(){var i=this.deltaQueue;i&&(this.deltaQueue=null,50<i.length&&i.length>this.$doc.getLength()>>1?this.call("setValue",[this.$doc.getValue()]):this.emit("change",{data:i}))}}).call(t.prototype),m.UIWorkerClient=function(i,e,r){var a=null,o=!1,c=Object.create(l),h=[],A=new t({messageBuffer:h,terminate:function(){},postMessage:function(d){h.push(d),a&&(o?setTimeout(v):v())}}),v=(A.setEmitSync=function(d){o=d},function(){var d=h.shift();d.command?a[d.command].apply(a,d.args):d.event&&c._signal(d.event,d.data)});return c.postMessage=function(d){A.onMessage({data:d})},c.callback=function(d,g){this.postMessage({type:"call",id:g,data:d})},c.emit=function(d,g){this.postMessage({type:"event",name:d,data:g})},s.loadModule(["worker",e],function(d){for(a=new d[r](c);h.length;)v()}),A},m.WorkerClient=t,m.createWorker=n}),ace.define("ace/placeholder",["require","exports","module","ace/range","ace/lib/event_emitter","ace/lib/oop"],function(C,m,b){function x(n,c,i,e,r,a){var o=this,c=(this.length=c,this.session=n,this.doc=n.getDocument(),this.mainClass=r,this.othersClass=a,this.$onUpdate=this.onUpdate.bind(this),this.doc.on("change",this.$onUpdate,!0),this.$others=e,this.$onCursorChange=function(){setTimeout(function(){o.onCursorChange()})},this.$pos=i,n.getUndoManager().$undoStack||n.getUndoManager().$undostack||{length:-1});this.$undoStackDepth=c.length,this.setup(),n.selection.on("changeCursor",this.$onCursorChange)}var p=C("./range").Range,l=C("./lib/event_emitter").EventEmitter,s=C("./lib/oop");(function(){s.implement(this,l),this.setup=function(){var n=this,t=this.doc,i=this.session,e=(this.selectionBefore=i.selection.toJSON(),i.selection.inMultiSelectMode&&i.selection.toSingleRange(),this.pos=t.createAnchor(this.$pos.row,this.$pos.column),this.pos);e.$insertRight=!0,e.detach(),e.markerId=i.addMarker(new p(e.row,e.column,e.row,e.column+this.length),this.mainClass,null,!1),this.others=[],this.$others.forEach(function(r){r=t.createAnchor(r.row,r.column),r.$insertRight=!0,r.detach(),n.others.push(r)}),i.setUndoSelect(!1)},this.showOtherMarkers=function(){var n,t;this.othersActive||(n=this.session,(t=this).othersActive=!0,this.others.forEach(function(i){i.markerId=n.addMarker(new p(i.row,i.column,i.row,i.column+t.length),t.othersClass,null,!1)}))},this.hideOtherMarkers=function(){if(this.othersActive){this.othersActive=!1;for(var n=0;n<this.others.length;n++)this.session.removeMarker(this.others[n].markerId)}},this.onUpdate=function(n){if(this.$updating)return this.updateAnchors(n);var t=n;if(t.start.row===t.end.row&&t.start.row===this.pos.row){this.$updating=!0;var i=n.action==="insert"?t.end.column-t.start.column:t.start.column-t.end.column,e=t.start.column>=this.pos.column&&t.start.column<=this.pos.column+this.length+1,r=t.start.column-this.pos.column;if(this.updateAnchors(n),e&&(this.length+=i),e&&!this.session.$fromUndo){if(n.action==="insert")for(var a=this.others.length-1;0<=a;a--){var o={row:(c=this.others[a]).row,column:c.column+r};this.doc.insertMergedLines(o,n.lines)}else if(n.action==="remove")for(a=this.others.length-1;0<=a;a--){var c,o={row:(c=this.others[a]).row,column:c.column+r};this.doc.remove(new p(o.row,o.column,o.row,o.column-i))}}this.$updating=!1,this.updateMarkers()}},this.updateAnchors=function(n){this.pos.onChange(n);for(var t=this.others.length;t--;)this.others[t].onChange(n);this.updateMarkers()},this.updateMarkers=function(){if(!this.$updating){var n=this,t=this.session,i=function(r,a){t.removeMarker(r.markerId),r.markerId=t.addMarker(new p(r.row,r.column,r.row,r.column+n.length),a,null,!1)};i(this.pos,this.mainClass);for(var e=this.others.length;e--;)i(this.others[e],this.othersClass)}},this.onCursorChange=function(n){var t;!this.$updating&&this.session&&((t=this.session.selection.getCursor()).row===this.pos.row&&t.column>=this.pos.column&&t.column<=this.pos.column+this.length?(this.showOtherMarkers(),this._emit("cursorEnter",n)):(this.hideOtherMarkers(),this._emit("cursorLeave",n)))},this.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},this.cancel=function(){if(this.$undoStackDepth!==-1){for(var n=this.session.getUndoManager(),t=(n.$undoStack||n.$undostack).length-this.$undoStackDepth,i=0;i<t;i++)n.undo(this.session,!0);this.selectionBefore&&this.session.selection.fromJSON(this.selectionBefore)}}}).call(x.prototype),m.PlaceHolder=x}),ace.define("ace/mouse/multi_select_handler",["require","exports","module","ace/lib/event","ace/lib/useragent"],function(C,m,b){var x=C("../lib/event"),p=C("../lib/useragent");function l(s,n){return s.row==n.row&&s.column==n.column}m.onMouseDown=function(s){var n=s.domEvent,t=n.altKey,i=n.shiftKey,e=n.ctrlKey,r=s.getAccelKey(),a=s.getButton();if(e&&p.isMac&&(a=n.button),s.editor.inMultiSelectMode&&a==2)s.editor.textInput.onContextMenu(s.domEvent);else if(e||t||r){if(a===0){var o,c,h,A,v,d,g,y,w=s.editor,I=w.selection,T=w.inMultiSelectMode,B=s.getDocumentPosition(),E=I.getCursor(),E=s.inSelection()||I.isEmpty()&&l(B,E),_=s.x,P=s.y,j=w.session,z=w.renderer.pixelToScreenCoordinates(_,P),D=z;if(w.$mouseHandler.$enableJumpToDef)e&&t||r&&t?o=i?"block":"add":t&&w.$blockSelectEnabled&&(o="block");else if(r&&!t){if(o="add",!T&&i)return}else t&&w.$blockSelectEnabled&&(o="block");if(o&&p.isMac&&n.ctrlKey&&w.$mouseHandler.cancelContextMenu(),o=="add")!T&&E||(T||(c=I.toOrientedRange(),w.addSelectionMarker(c)),h=I.rangeList.rangeAtPoint(B),w.inVirtualSelectionMode=!0,i&&(h=null,c=I.ranges[0]||c,w.removeSelectionMarker(c)),w.once("mouseup",function(){var Y=I.toOrientedRange();h&&Y.isEmpty()&&l(h.cursor,Y.cursor)?I.substractPoint(Y.cursor):(i?I.substractPoint(c.cursor):c&&(w.removeSelectionMarker(c),I.addRange(c)),I.addRange(Y)),w.inVirtualSelectionMode=!1}));else if(o=="block")return s.stop(),w.inVirtualSelectionMode=!0,v=[],d=function(){var Y=w.renderer.pixelToScreenCoordinates(_,P),R=j.screenToDocumentPosition(Y.row,Y.column,Y.offsetX);l(D,Y)&&l(R,I.lead)||(D=Y,w.selection.moveToPosition(R),w.renderer.scrollCursorIntoView(),w.removeSelectionMarkers(v),v=I.rectangularRangeBlock(D,z),w.$mouseHandler.$clickSelection&&v.length==1&&v[0].isEmpty()&&(v[0]=w.$mouseHandler.$clickSelection.clone()),v.forEach(w.addSelectionMarker,w),w.updateSelectionMarkers())},T&&!r?I.toSingleRange():!T&&r&&(A=I.toOrientedRange(),w.addSelectionMarker(A)),i?z=j.documentToScreenPosition(I.lead):I.moveToPosition(B),D={row:-1,column:-1},g=d,x.capture(w.container,function(Y){_=Y.clientX,P=Y.clientY},function(Y){d(),clearInterval(y),w.removeSelectionMarkers(v),v.length||(v=[I.toOrientedRange()]),A&&(w.removeSelectionMarker(A),I.toSingleRange(A));for(var R=0;R<v.length;R++)I.addRange(v[R]);w.inVirtualSelectionMode=!1,w.$mouseHandler.$clickSelection=null}),y=setInterval(function(){g()},20),s.preventDefault()}}else a===0&&s.editor.inMultiSelectMode&&s.editor.exitMultiSelectMode()}}),ace.define("ace/commands/multi_select_commands",["require","exports","module","ace/keyboard/hash_handler"],function(C,m,b){m.defaultCommands=[{name:"addCursorAbove",description:"Add cursor above",exec:function(x){x.selectMoreLines(-1)},bindKey:{win:"Ctrl-Alt-Up",mac:"Ctrl-Alt-Up"},scrollIntoView:"cursor",readOnly:!0},{name:"addCursorBelow",description:"Add cursor below",exec:function(x){x.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(x){x.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(x){x.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(x){x.selectMore(-1)},bindKey:{win:"Ctrl-Alt-Left",mac:"Ctrl-Alt-Left"},scrollIntoView:"cursor",readOnly:!0},{name:"selectMoreAfter",description:"Select more after",exec:function(x){x.selectMore(1)},bindKey:{win:"Ctrl-Alt-Right",mac:"Ctrl-Alt-Right"},scrollIntoView:"cursor",readOnly:!0},{name:"selectNextBefore",description:"Select next before",exec:function(x){x.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(x){x.selectMore(1,!0)},bindKey:{win:"Ctrl-Alt-Shift-Right",mac:"Ctrl-Alt-Shift-Right"},scrollIntoView:"cursor",readOnly:!0},{name:"toggleSplitSelectionIntoLines",description:"Split into lines",exec:function(x){1<x.multiSelect.rangeCount?x.multiSelect.joinSelections():x.multiSelect.splitIntoLines()},bindKey:{win:"Ctrl-Alt-L",mac:"Ctrl-Alt-L"},readOnly:!0},{name:"splitSelectionIntoLines",description:"Split into lines",exec:function(x){x.multiSelect.splitIntoLines()},readOnly:!0},{name:"alignCursors",description:"Align cursors",exec:function(x){x.alignCursors()},bindKey:{win:"Ctrl-Alt-A",mac:"Ctrl-Alt-A"},scrollIntoView:"cursor"},{name:"findAll",description:"Find all",exec:function(x){x.findAll()},bindKey:{win:"Ctrl-Alt-K",mac:"Ctrl-Alt-G"},scrollIntoView:"cursor",readOnly:!0}],m.multiSelectCommands=[{name:"singleSelection",description:"Single selection",bindKey:"esc",exec:function(x){x.exitMultiSelectMode()},scrollIntoView:"cursor",readOnly:!0,isAvailable:function(x){return x&&x.inMultiSelectMode}}],C=C("../keyboard/hash_handler").HashHandler,m.keyboardHandler=new C(m.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(C,m,b){var x=C("./range_list").RangeList,p=C("./range").Range,l=C("./selection").Selection,s=C("./mouse/multi_select_handler").onMouseDown,n=C("./lib/event"),t=C("./lib/lang"),i=C("./commands/multi_select_commands");m.commands=i.defaultCommands.concat(i.multiSelectCommands);var e=new(C("./search")).Search,r=C("./edit_session").EditSession,r=(function(){this.getSelectionMarkers=function(){return this.$selectionMarkers}}.call(r.prototype),function(){this.ranges=null,this.rangeList=null,this.addRange=function(o,c){if(o){if(!this.inMultiSelectMode&&this.rangeCount===0){var h=this.toOrientedRange();if(this.rangeList.add(h),this.rangeList.add(o),this.rangeList.ranges.length!=2)return this.rangeList.removeAll(),c||this.fromOrientedRange(o);this.rangeList.removeAll(),this.rangeList.add(h),this.$onAddRange(h)}return o.cursor||(o.cursor=o.end),h=this.rangeList.add(o),this.$onAddRange(o),h.length&&this.$onRemoveRange(h),1<this.rangeCount&&!this.inMultiSelectMode&&(this._signal("multiSelect"),this.inMultiSelectMode=!0,this.session.$undoSelect=!1,this.rangeList.attach(this.session)),c||this.fromOrientedRange(o)}},this.toSingleRange=function(o){o=o||this.ranges[0];var c=this.rangeList.removeAll();c.length&&this.$onRemoveRange(c),o&&this.fromOrientedRange(o)},this.substractPoint=function(o){if(o=this.rangeList.substractPoint(o),o)return this.$onRemoveRange(o),o[0]},this.mergeOverlappingRanges=function(){var o=this.rangeList.merge();o.length&&this.$onRemoveRange(o)},this.$onAddRange=function(o){this.rangeCount=this.rangeList.ranges.length,this.ranges.unshift(o),this._signal("addRange",{range:o})},this.$onRemoveRange=function(o){var c;this.rangeCount=this.rangeList.ranges.length,this.rangeCount==1&&this.inMultiSelectMode&&(c=this.rangeList.ranges.pop(),o.push(c),this.rangeCount=0);for(var h=o.length;h--;){var A=this.ranges.indexOf(o[h]);this.ranges.splice(A,1)}this._signal("removeRange",{ranges:o}),this.rangeCount===0&&this.inMultiSelectMode&&(this.inMultiSelectMode=!1,this._signal("singleSelect"),this.session.$undoSelect=!0,this.rangeList.detach(this.session)),(c=c||this.ranges[0])&&!c.isEqual(this.getRange())&&this.fromOrientedRange(c)},this.$initRangeList=function(){this.rangeList||(this.rangeList=new x,this.ranges=[],this.rangeCount=0)},this.getAllRanges=function(){return this.rangeCount?this.rangeList.ranges.concat():[this.getRange()]},this.splitIntoLines=function(){for(var o=this.ranges.length?this.ranges:[this.getRange()],c=[],h=0;h<o.length;h++){var A=o[h],v=A.start.row,d=A.end.row;if(v===d)c.push(A.clone());else{for(c.push(new p(v,A.start.column,v,this.session.getLine(v).length));++v<d;)c.push(this.getLineRange(v,!0));c.push(new p(d,0,d,A.end.column))}h!=0||this.isBackwards()||(c=c.reverse())}for(this.toSingleRange(),h=c.length;h--;)this.addRange(c[h])},this.joinSelections=function(){var c=this.rangeList.ranges,o=c[c.length-1],c=p.fromPoints(c[0].start,o.end);this.toSingleRange(),this.setSelectionRange(c,o.cursor==o.start)},this.toggleBlockSelection=function(){var o,c;1<this.rangeCount?(c=(o=this.rangeList.ranges)[o.length-1],o=p.fromPoints(o[0].start,c.end),this.toSingleRange(),this.setSelectionRange(o,c.cursor==c.start)):(o=this.session.documentToScreenPosition(this.cursor),c=this.session.documentToScreenPosition(this.anchor),this.rectangularRangeBlock(o,c).forEach(this.addRange,this))},this.rectangularRangeBlock=function(o,c,h){var A,v,d,g,y,w,I,T=[],B=o.column<c.column,E=(g=(B?(A=o.column,v=c.column,d=o.offsetX,c):(A=c.column,v=o.column,d=c.offsetX,o)).offsetX,o.row<c.row);w=(E?(y=o.row,c):(y=c.row,o)).row,A<0&&(A=0),(y=y<0?0:y)==w&&(h=!0);for(var _,P,j=y;j<=w;j++){var z=p.fromPoints(this.session.screenToDocumentPosition(j,A,d),this.session.screenToDocumentPosition(j,v,g));if(z.isEmpty()){if(I&&(_=z.end,P=I,_.row==P.row&&_.column==P.column))break;I=z.end}z.cursor=B?z.start:z.end,T.push(z)}if(E&&T.reverse(),!h){for(var D=T.length-1;T[D].isEmpty()&&0<D;)D--;if(0<D)for(var Y=0;T[Y].isEmpty();)Y++;for(var R=D;Y<=R;R--)T[R].isEmpty()&&T.splice(R,1)}return T}}.call(l.prototype),C("./editor").Editor);function a(o){var c,h;function A(v){h&&(c.renderer.setMouseCursor(""),h=!1)}o.$multiselectOnSessionChange||(o.$onAddRange=o.$onAddRange.bind(o),o.$onRemoveRange=o.$onRemoveRange.bind(o),o.$onMultiSelect=o.$onMultiSelect.bind(o),o.$onSingleSelect=o.$onSingleSelect.bind(o),o.$multiselectOnSessionChange=m.onSessionChange.bind(o),o.$checkMultiselectChange=o.$checkMultiselectChange.bind(o),o.$multiselectOnSessionChange(o),o.on("changeSession",o.$multiselectOnSessionChange),o.on("mousedown",s),o.commands.addCommands(i.defaultCommands),(c=o).textInput&&(o=c.textInput.getElement(),h=!1,n.addListener(o,"keydown",function(v){v=v.keyCode==18&&!(v.ctrlKey||v.shiftKey||v.metaKey),c.$blockSelectEnabled&&v?h||(c.renderer.setMouseCursor("crosshair"),h=!0):h&&A()},c),n.addListener(o,"keyup",A,c),n.addListener(o,"blur",A,c)))}(function(){this.updateSelectionMarkers=function(){this.renderer.updateCursor(),this.renderer.updateBackMarkers()},this.addSelectionMarker=function(o){o.cursor||(o.cursor=o.end);var c=this.getSelectionStyle();return o.marker=this.session.addMarker(o,"ace_selection",c),this.session.$selectionMarkers.push(o),this.session.selectionMarkerCount=this.session.$selectionMarkers.length,o},this.removeSelectionMarker=function(o){o.marker&&(this.session.removeMarker(o.marker),(o=this.session.$selectionMarkers.indexOf(o))!=-1&&this.session.$selectionMarkers.splice(o,1),this.session.selectionMarkerCount=this.session.$selectionMarkers.length)},this.removeSelectionMarkers=function(o){for(var c=this.session.$selectionMarkers,h=o.length;h--;){var A=o[h];A.marker&&(this.session.removeMarker(A.marker),(A=c.indexOf(A))!=-1&&c.splice(A,1))}this.session.selectionMarkerCount=c.length},this.$onAddRange=function(o){this.addSelectionMarker(o.range),this.renderer.updateCursor(),this.renderer.updateBackMarkers()},this.$onRemoveRange=function(o){this.removeSelectionMarkers(o.ranges),this.renderer.updateCursor(),this.renderer.updateBackMarkers()},this.$onMultiSelect=function(o){this.inMultiSelectMode||(this.inMultiSelectMode=!0,this.setStyle("ace_multiselect"),this.keyBinding.addKeyboardHandler(i.keyboardHandler),this.commands.setDefaultHandler("exec",this.$onMultiSelectExec),this.renderer.updateCursor(),this.renderer.updateBackMarkers())},this.$onSingleSelect=function(o){this.session.multiSelect.inVirtualMode||(this.inMultiSelectMode=!1,this.unsetStyle("ace_multiselect"),this.keyBinding.removeKeyboardHandler(i.keyboardHandler),this.commands.removeDefaultHandler("exec",this.$onMultiSelectExec),this.renderer.updateCursor(),this.renderer.updateBackMarkers(),this._emit("changeSelection"))},this.$onMultiSelectExec=function(o){var c,h=o.command,A=o.editor;if(A.multiSelect)return h.multiSelectAction?c=h.multiSelectAction=="forEach"?A.forEachSelection(h,o.args):h.multiSelectAction=="forEachLine"?A.forEachSelection(h,o.args,!0):h.multiSelectAction=="single"?(A.exitMultiSelectMode(),h.exec(A,o.args||{})):h.multiSelectAction(A,o.args||{}):(c=h.exec(A,o.args||{}),A.multiSelect.addRange(A.multiSelect.toOrientedRange()),A.multiSelect.mergeOverlappingRanges()),c},this.forEachSelection=function(o,c,h){if(!this.inVirtualSelectionMode){var A,w=h&&h.keepOrder,v=h==1||h&&h.$byLines,d=this.session,h=this.selection,g=h.rangeList,y=(w?h:g).ranges;if(!y.length)return o.exec?o.exec(this,c||{}):o(this,c||{});var w=h._eventRegistry,I=(h._eventRegistry={},new l(d));this.inVirtualSelectionMode=!0;for(var T=y.length;T--;){if(v)for(;0<T&&y[T].start.row==y[T-1].end.row;)T--;I.fromOrientedRange(y[T]),I.index=T,this.selection=d.selection=I;var B=o.exec?o.exec(this,c||{}):o(this,c||{});A||B===void 0||(A=B),I.toOrientedRange(y[T])}return I.detach(),this.selection=d.selection=h,this.inVirtualSelectionMode=!1,h._eventRegistry=w,h.mergeOverlappingRanges(),h.ranges[0]&&h.fromOrientedRange(h.ranges[0]),g=this.renderer.$scrollAnimation,this.onCursorChange(),this.onSelectionChange(),g&&g.from==g.to&&this.renderer.animateScrolling(g.from),A}},this.exitMultiSelectMode=function(){this.inMultiSelectMode&&!this.inVirtualSelectionMode&&this.multiSelect.toSingleRange()},this.getSelectedText=function(){var o="";if(this.inMultiSelectMode&&!this.inVirtualSelectionMode){for(var c=this.multiSelect.rangeList.ranges,h=[],A=0;A<c.length;A++)h.push(this.session.getTextRange(c[A]));var v=this.session.getDocument().getNewLineCharacter();(o=h.join(v)).length==(h.length-1)*v.length&&(o="")}else this.selection.isEmpty()||(o=this.session.getTextRange(this.getSelectionRange()));return o},this.$checkMultiselectChange=function(o,c){var h;this.inMultiSelectMode&&!this.inVirtualSelectionMode&&(h=this.multiSelect.ranges[0],this.multiSelect.isEmpty()&&c==this.multiSelect.anchor||((h=c==this.multiSelect.anchor?h.cursor==h.start?h.end:h.start:h.cursor).row!=c.row||this.session.$clipPositionToDocument(h.row,h.column).column!=c.column?this.multiSelect.toSingleRange(this.multiSelect.toOrientedRange()):this.multiSelect.mergeOverlappingRanges()))},this.findAll=function(o,c,h){(c=c||{}).needle=o||c.needle,c.needle==null&&(A=this.selection.isEmpty()?this.selection.getWordRange():this.selection.getRange(),c.needle=this.session.getTextRange(A)),this.$search.set(c);var A,v=this.$search.findAll(this.session);if(!v.length)return 0;var d=this.multiSelect;h||d.toSingleRange(v[0]);for(var g=v.length;g--;)d.addRange(v[g],!0);return A&&d.rangeList.rangeAtPoint(A.start)&&d.addRange(A,!0),v.length},this.selectMoreLines=function(o,c){var h,A,v,d=this.selection.toOrientedRange(),g=d.cursor==d.end,y=this.session.documentToScreenPosition(d.cursor),w=(this.selection.$desiredColumn&&(y.column=this.selection.$desiredColumn),this.session.screenToDocumentPosition(y.row+o,y.column));o=d.isEmpty()?w:(h=this.session.documentToScreenPosition(g?d.end:d.start),this.session.screenToDocumentPosition(h.row+o,h.column)),g?(A=p.fromPoints(w,o)).cursor=A.start:(A=p.fromPoints(o,w)).cursor=A.end,A.desiredColumn=y.column,this.selection.inMultiSelectMode?c&&(v=d.cursor):this.selection.addRange(d),this.selection.addRange(A),v&&this.selection.substractPoint(v)},this.transposeSelections=function(o){for(var c=this.session,h=c.multiSelect,A=h.ranges,v=A.length;v--;)(g=A[v]).isEmpty()&&(y=c.getWordRange(g.start.row,g.start.column),g.start.row=y.start.row,g.start.column=y.start.column,g.end.row=y.end.row,g.end.column=y.end.column);h.mergeOverlappingRanges();for(var d=[],v=A.length;v--;){var g=A[v];d.unshift(c.getTextRange(g))}for(o<0?d.unshift(d.pop()):d.push(d.shift()),v=A.length;v--;){var y=(g=A[v]).clone();c.replace(g,d[v]),g.start.row=y.start.row,g.start.column=y.start.column}h.fromOrientedRange(h.ranges[0])},this.selectMore=function(o,c,h){var A,v=this.session,d=v.multiSelect.toOrientedRange();d.isEmpty()&&((d=v.getWordRange(d.start.row,d.start.column)).cursor=o==-1?d.start:d.end,this.multiSelect.addRange(d),h)||(h=v.getTextRange(d),v=v,h=h,A=o,e.$options.wrap=!0,e.$options.needle=h,e.$options.backwards=A==-1,(h=e.find(v))&&(h.cursor=o==-1?h.start:h.end,this.session.unfold(h),this.multiSelect.addRange(h),this.renderer.scrollCursorIntoView(null,.5)),c&&this.multiSelect.substractPoint(d.cursor))},this.alignCursors=function(){var o=this.session,c=o.multiSelect,h=c.ranges,A=-1,v=h.filter(function(_){if(_.cursor.row==A)return!0;A=_.cursor.row});if(h.length&&v.length!=h.length-1){v.forEach(function(_){c.substractPoint(_.cursor)});var d=0,g=1/0,y=h.map(function(P){var P=P.cursor,j=o.getLine(P.row).substr(P.column).search(/\S/g);return P.column>d&&(d=P.column),(j=j==-1?0:j)<g&&(g=j),j});h.forEach(function(_,D){var j=_.cursor,z=d-j.column,D=y[D]-g;D<z?o.insert(j,t.stringRepeat(" ",z-D)):o.remove(new p(j.row,j.column,j.row,j.column-z+D)),_.start.column=_.end.column=d,_.start.row=_.end.row=j.row,_.cursor=_.end}),c.fromOrientedRange(h[0]),this.renderer.updateCursor(),this.renderer.updateBackMarkers()}else{var v=this.selection.getRange(),w=v.start.row,I=v.end.row,h=w==I;if(h){for(var T,B=this.session.getLength();T=this.session.getLine(I),/[=:]/.test(T)&&++I<B;);for(;T=this.session.getLine(w),/[=:]/.test(T)&&0<--w;);w<0&&(w=0),B<=I&&(I=B-1)}var E=this.session.removeFullLines(w,I),E=this.$reAlignText(E,h);this.session.insert({row:w,column:0},E.join(`
`)+`
`),h||(v.start.column=0,v.end.column=E[E.length-1].length),this.selection.setRange(v)}},this.$reAlignText=function(o,c){var h,A,v,d=!0,g=!0;return o.map(function(I){var T=I.match(/(\s*)(.*?)(\s*)([=:].*)/);return T?(h==null?(h=T[1].length,A=T[2].length,v=T[3].length):(h+A+v!=T[1].length+T[2].length+T[3].length&&(g=!1),h!=T[1].length&&(d=!1),h>T[1].length&&(h=T[1].length),A<T[2].length&&(A=T[2].length),v>T[3].length&&(v=T[3].length)),T):[I]}).map(c?w:d?g?function(I){return I[2]?y(h+A-I[2].length)+I[2]+y(v)+I[4].replace(/^([=:])\s+/,"$1 "):I[0]}:w:function(I){return I[2]?y(h)+I[2]+y(v)+I[4].replace(/^([=:])\s+/,"$1 "):I[0]});function y(I){return t.stringRepeat(" ",I)}function w(I){return I[2]?y(h)+I[2]+y(A-I[2].length+v)+I[4].replace(/^([=:])\s+/,"$1 "):I[0]}}}).call(r.prototype),m.onSessionChange=function(h){var c=h.session,h=(c&&!c.multiSelect&&(c.$selectionMarkers=[],c.selection.$initRangeList(),c.multiSelect=c.selection),this.multiSelect=c&&c.multiSelect,h.oldSession);h&&(h.multiSelect.off("addRange",this.$onAddRange),h.multiSelect.off("removeRange",this.$onRemoveRange),h.multiSelect.off("multiSelect",this.$onMultiSelect),h.multiSelect.off("singleSelect",this.$onSingleSelect),h.multiSelect.lead.off("change",this.$checkMultiselectChange),h.multiSelect.anchor.off("change",this.$checkMultiselectChange)),c&&(c.multiSelect.on("addRange",this.$onAddRange),c.multiSelect.on("removeRange",this.$onRemoveRange),c.multiSelect.on("multiSelect",this.$onMultiSelect),c.multiSelect.on("singleSelect",this.$onSingleSelect),c.multiSelect.lead.on("change",this.$checkMultiselectChange),c.multiSelect.anchor.on("change",this.$checkMultiselectChange)),c&&this.inMultiSelectMode!=c.selection.inMultiSelectMode&&(c.selection.inMultiSelectMode?this.$onMultiSelect():this.$onSingleSelect())},m.MultiSelect=a,C("./config").defineOptions(r.prototype,"editor",{enableMultiselect:{set:function(o){a(this),o?(this.on("changeSession",this.$multiselectOnSessionChange),this.on("mousedown",s)):(this.off("changeSession",this.$multiselectOnSessionChange),this.off("mousedown",s))},value:!0},enableBlockSelect:{set:function(o){this.$blockSelectEnabled=o},value:!0}})}),ace.define("ace/mode/folding/fold_mode",["require","exports","module","ace/range"],function(p,m,b){var x=p("../../range").Range,p=m.FoldMode=function(){};(function(){this.foldingStartMarker=null,this.foldingStopMarker=null,this.getFoldWidget=function(l,s,n){return l=l.getLine(n),this.foldingStartMarker.test(l)?"start":s=="markbeginend"&&this.foldingStopMarker&&this.foldingStopMarker.test(l)?"end":""},this.getFoldWidgetRange=function(l,s,n){return null},this.indentationBlock=function(l,s,n){var t=/\S/,i=l.getLine(s),e=i.search(t);if(e!=-1){for(var r,n=n||i.length,a=l.getLength(),i=s,o=s;++s<a;){var c=l.getLine(s).search(t);if(c!=-1){if(c<=e&&(c=l.getTokenAt(s,0),!c||c.type!=="string"))break;o=s}}return i<o?(r=l.getLine(o).length,new x(i,n,o,r)):void 0}},this.openingBracketBlock=function(l,s,n,t,i){if(n={row:n,column:t+1},t=l.$findClosingBracket(s,n,i),t)return(s=(s=l.foldWidgets[t.row])==null?l.getFoldWidget(t.row):s)=="start"&&t.row>n.row&&(t.row--,t.column=l.getLine(t.row).length),x.fromPoints(n,t)},this.closingBracketBlock=function(l,s,n,t,i){if(n={row:n,column:t},t=l.$findOpeningBracket(s,n),t)return t.column++,n.column--,x.fromPoints(t,n)}}).call(p.prototype)}),ace.define("ace/line_widgets",["require","exports","module","ace/lib/dom"],function(C,m,b){var x=C("./lib/dom");function p(l){this.session=l,(this.session.widgetManager=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)}(function(){this.getRowLength=function(l){var s=this.lineWidgets&&this.lineWidgets[l]&&this.lineWidgets[l].rowCount||0;return this.$useWrapMode&&this.$wrapData[l]?this.$wrapData[l].length+1+s:1+s},this.$getWidgetScreenLength=function(){var l=0;return this.lineWidgets.forEach(function(s){s&&s.rowCount&&!s.hidden&&(l+=s.rowCount)}),l},this.$onChangeEditor=function(l){this.attach(l.editor)},this.attach=function(l){l&&l.widgetManager&&l.widgetManager!=this&&l.widgetManager.detach(),this.editor!=l&&(this.detach(),(this.editor=l)&&(l.widgetManager=this,l.renderer.on("beforeRender",this.measureWidgets),l.renderer.on("afterRender",this.renderWidgets)))},this.detach=function(l){var s=this.editor;s&&(this.editor=null,s.widgetManager=null,s.renderer.off("beforeRender",this.measureWidgets),s.renderer.off("afterRender",this.renderWidgets),(s=this.session.lineWidgets)&&s.forEach(function(n){n&&n.el&&n.el.parentNode&&(n._inDocument=!1,n.el.parentNode.removeChild(n.el))}))},this.updateOnFold=function(l,s){var n=s.lineWidgets;if(n&&l.action){for(var s=l.data,t=s.start.row,i=s.end.row,e=l.action=="add",r=t+1;r<i;r++)n[r]&&(n[r].hidden=e);n[i]&&(e?n[t]?n[i].hidden=e:n[t]=n[i]:(n[t]==n[i]&&(n[t]=void 0),n[i].hidden=e))}},this.updateOnChange=function(l){var s,n,t,i=this.session.lineWidgets;i&&(s=l.start.row,(n=l.end.row-s)!=0&&(l.action=="remove"?(t=i.splice(s+1,n),!i[s]&&t[t.length-1]&&(i[s]=t.pop()),t.forEach(function(e){e&&this.removeLineWidget(e)},this)):(t=new Array(n),i[s]&&i[s].column!=null&&l.start.column>i[s].column&&s++,t.unshift(s,0),i.splice.apply(i,t)),this.$updateRows()))},this.$updateRows=function(){var l,s=this.session.lineWidgets;s&&(l=!0,s.forEach(function(n,t){if(n)for(l=!1,n.row=t;n.$oldWidget;)n.$oldWidget.row=t,n=n.$oldWidget}),l&&(this.session.lineWidgets=null))},this.$registerLineWidget=function(l){this.session.lineWidgets||(this.session.lineWidgets=new Array(this.session.getLength()));var s=this.session.lineWidgets[l.row];return s&&(l.$oldWidget=s).el&&s.el.parentNode&&(s.el.parentNode.removeChild(s.el),s._inDocument=!1),this.session.lineWidgets[l.row]=l},this.addLineWidget=function(l){var s,n,t;return this.$registerLineWidget(l),l.session=this.session,this.editor&&(s=this.editor.renderer,l.html&&!l.el&&(l.el=x.createElement("div"),l.el.innerHTML=l.html),l.el&&(x.addCssClass(l.el,"ace_lineWidgetContainer"),l.el.style.position="absolute",l.el.style.zIndex=5,s.container.appendChild(l.el),l._inDocument=!0,l.coverGutter||(l.el.style.zIndex=3),l.pixelHeight==null&&(l.pixelHeight=l.el.offsetHeight)),l.rowCount==null&&(l.rowCount=l.pixelHeight/s.layerConfig.lineHeight),n=this.session.getFoldAt(l.row,0),(l.$fold=n)&&(t=this.session.lineWidgets,l.row!=n.end.row||t[n.start.row]?l.hidden=!0:t[n.start.row]=l),this.session._emit("changeFold",{data:{start:{row:l.row}}}),this.$updateRows(),this.renderWidgets(null,s),this.onWidgetChanged(l)),l},this.removeLineWidget=function(l){if(l._inDocument=!1,l.session=null,l.el&&l.el.parentNode&&l.el.parentNode.removeChild(l.el),l.editor&&l.editor.destroy)try{l.editor.destroy()}catch{}if(this.session.lineWidgets){var s=this.session.lineWidgets[l.row];if(s==l)this.session.lineWidgets[l.row]=l.$oldWidget,l.$oldWidget&&this.onWidgetChanged(l.$oldWidget);else for(;s;){if(s.$oldWidget==l){s.$oldWidget=l.$oldWidget;break}s=s.$oldWidget}}this.session._emit("changeFold",{data:{start:{row:l.row}}}),this.$updateRows()},this.getWidgetsAtRow=function(l){for(var s=this.session.lineWidgets,n=s&&s[l],t=[];n;)t.push(n),n=n.$oldWidget;return t},this.onWidgetChanged=function(l){this.session._changedWidgets.push(l),this.editor&&this.editor.renderer.updateFull()},this.measureWidgets=function(l,s){var n=this.session._changedWidgets,t=s.layerConfig;if(n&&n.length){for(var i=1/0,e=0;e<n.length;e++){var r=n[e];if(r&&r.el&&r.session==this.session){if(!r._inDocument){if(this.session.lineWidgets[r.row]!=r)continue;r._inDocument=!0,s.container.appendChild(r.el)}r.h=r.el.offsetHeight,r.fixedWidth||(r.w=r.el.offsetWidth,r.screenWidth=Math.ceil(r.w/t.characterWidth));var a=r.h/t.lineHeight;r.coverLine&&(a-=this.session.getRowLineCount(r.row))<0&&(a=0),r.rowCount!=a&&(r.rowCount=a,r.row<i&&(i=r.row))}}i!=1/0&&(this.session._emit("changeFold",{data:{start:{row:i}}}),this.session.lineWidgetWidth=null),this.session._changedWidgets=[]}},this.renderWidgets=function(l,s){var n=s.layerConfig,t=this.session.lineWidgets;if(t){for(var i=Math.min(this.firstRow,n.firstRow),e=Math.max(this.lastRow,n.lastRow,t.length);0<i&&!t[i];)i--;this.firstRow=n.firstRow,this.lastRow=n.lastRow,s.$cursorLayer.config=n;for(var r=i;r<=e;r++){var a,o=t[r];o&&o.el&&(o.hidden?o.el.style.top=-100-(o.pixelHeight||0)+"px":(o._inDocument||(o._inDocument=!0,s.container.appendChild(o.el)),a=s.$cursorLayer.getPixelPosition({row:r,column:0},!0).top,o.coverLine||(a+=n.lineHeight*this.session.getRowLineCount(o.row)),o.el.style.top=a-n.offset+"px",a=o.coverGutter?0:s.gutterWidth,o.fixedWidth||(a-=s.scrollLeft),o.el.style.left=a+"px",o.fullWidth&&o.screenWidth&&(o.el.style.minWidth=n.width+2*n.padding+"px"),o.fixedWidth?o.el.style.right=s.scrollBar.getWidth()+"px":o.el.style.right=""))}}}}).call(p.prototype),m.LineWidgets=p}),ace.define("ace/ext/error_marker",["require","exports","module","ace/line_widgets","ace/lib/dom","ace/range"],function(C,m,b){var x=C("../line_widgets").LineWidgets,p=C("../lib/dom"),l=C("../range").Range;function s(n,t,i){var e=n.getAnnotations().sort(l.comparePoints);if(e.length){var r=function(c,h,A){for(var v=0,d=c.length-1;v<=d;){var g=v+d>>1,y=A(h,c[g]);if(0<y)v=1+g;else{if(!(y<0))return g;d=g-1}}return-(v+1)}(e,{row:t,column:-1},l.comparePoints),a=((r=r<0?-r-1:r)>=e.length?r=0<i?0:e.length-1:r===0&&i<0&&(r=e.length-1),e[r]);if(a&&i){if(a.row===t){for(;(a=e[r+=i])&&a.row===t;);if(!a)return e.slice()}var o=[];for(t=a.row;o[i<0?"unshift":"push"](a),(a=e[r+=i])&&a.row==t;);return o.length&&o}}}m.showErrorMarker=function(n,h){var i,e=n.session,r=(e.widgetManager||(e.widgetManager=new x(e),e.widgetManager.attach(n)),n.getCursorPosition()),c=r.row,A=e.widgetManager.getWidgetsAtRow(c).filter(function(v){return v.type=="errorMarker"})[0],c=(A?A.destroy():c-=h,s(e,c,h));if(c)h=c[0],r.column=(h.pos&&typeof h.column!="number"?h.pos.sc:h.column)||0,r.row=h.row,i=n.renderer.$gutterLayer.$annotations[r.row];else{if(A)return;i={text:["Looks good!"],className:"ace_ok"}}n.session.unfold(r.row),n.selection.moveToPosition(r);function a(v,d,g){if(d===0&&(g==="esc"||g==="return"))return o.destroy(),{command:"null"}}var o={row:r.row,fixedWidth:!0,coverGutter:!0,el:p.createElement("div"),type:"errorMarker"},c=o.el.appendChild(p.createElement("div")),h=o.el.appendChild(p.createElement("div")),A=(h.className="error_widget_arrow "+i.className,n.renderer.$cursorLayer.getPixelPosition(r).left);h.style.left=A+n.renderer.gutterWidth-5+"px",o.el.className="error_widget_wrapper",c.className="error_widget "+i.className,c.innerHTML=i.text.join("<br>"),c.appendChild(p.createElement("div")),o.destroy=function(){n.$mouseHandler.isMousePressed||(n.keyBinding.removeKeyboardHandler(a),e.widgetManager.removeLineWidget(o),n.off("changeSelection",o.destroy),n.off("changeSession",o.destroy),n.off("mouseup",o.destroy),n.off("change",o.destroy))},n.keyBinding.addKeyboardHandler(a),n.on("changeSelection",o.destroy),n.on("changeSession",o.destroy),n.on("mouseup",o.destroy),n.on("change",o.destroy),n.session.widgetManager.addLineWidget(o),o.el.onmousedown=n.focus.bind(n),n.renderer.scrollCursorIntoView(null,.5,{bottom:o.el.offsetHeight})},p.importCssString(`
    .error_widget_wrapper {
        background: inherit;
        color: inherit;
        border:none
    }
    .error_widget {
        border-top: solid 2px;
        border-bottom: solid 2px;
        margin: 5px 0;
        padding: 10px 40px;
        white-space: pre-wrap;
    }
    .error_widget.ace_error, .error_widget_arrow.ace_error{
        border-color: #ff5a5a
    }
    .error_widget.ace_warning, .error_widget_arrow.ace_warning{
        border-color: #F1D817
    }
    .error_widget.ace_info, .error_widget_arrow.ace_info{
        border-color: #5a5a5a
    }
    .error_widget.ace_ok, .error_widget_arrow.ace_ok{
        border-color: #5aaa5a
    }
    .error_widget_arrow {
        position: absolute;
        border: solid 5px;
        border-top-color: transparent!important;
        border-right-color: transparent!important;
        border-left-color: transparent!important;
        top: -5px;
    }
`,"error_marker.css",!1)}),ace.define("ace/ace",["require","exports","module","ace/lib/dom","ace/lib/event","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(C,m,b){C("./loader_build")(m);var x=C("./lib/dom"),p=C("./lib/event"),l=C("./range").Range,s=C("./editor").Editor,n=C("./edit_session").EditSession,t=C("./undomanager").UndoManager,i=C("./virtual_renderer").VirtualRenderer;C("./worker/worker_client"),C("./keyboard/hash_handler"),C("./placeholder"),C("./multi_select"),C("./mode/folding/fold_mode"),C("./theme/textmate"),C("./ext/error_marker"),m.config=C("./config"),m.edit=function(e,r){if(typeof e=="string"){var a=e;if(!(e=document.getElementById(a)))throw new Error("ace.edit can't find div #"+a)}var o,c;return e&&e.env&&e.env.editor instanceof s?e.env.editor:(a="",e&&/input|textarea/i.test(e.tagName)?(a=(o=e).value,e=x.createElement("pre"),o.parentNode.replaceChild(e,o)):e&&(a=e.textContent,e.innerHTML=""),a=m.createEditSession(a),e=new s(new i(e),a,r),c={document:a,editor:e,onResize:e.resize.bind(e,null)},o&&(c.textarea=o),p.addListener(window,"resize",c.onResize),e.on("destroy",function(){p.removeListener(window,"resize",c.onResize),c.editor.container.env=null}),e.container.env=e.env=c,e)},m.createEditSession=function(e,r){return e=new n(e,r),e.setUndoManager(new t),e},m.Range=l,m.Editor=s,m.EditSession=n,m.UndoManager=t,m.VirtualRenderer=i,m.version=m.config.version}),ace.require(["ace/ace"],function(C){for(var m in C&&(C.config.init(!0),C.define=ace.define),window.ace||(window.ace=C),C)C.hasOwnProperty(m)&&(window.ace[m]=C[m]);window.ace.default=window.ace,ie&&(ie.exports=window.ace)})},4317:function(ie,u,V){ie=V.nmd(ie),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(X,k,N){var i=X("./lib/dom"),Z=X("./lib/oop"),O=X("./lib/event_emitter").EventEmitter,W=X("./lib/lang"),F=X("./range").Range,L=X("./range_list").RangeList,C=X("./keyboard/hash_handler").HashHandler,m=X("./tokenizer").Tokenizer,b=X("./clipboard"),x={CURRENT_WORD:function(e){return e.session.getTextRange(e.session.getWordRange())},SELECTION:function(e,r,a){return e=e.session.getTextRange(),a?e.replace(/\n\r?([ \t]*\S)/g,`
`+a+"$1"):e},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 b.getText&&b.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){return e=e.session.$mode||{},e.blockComment&&e.blockComment.start||""},BLOCK_COMMENT_END:function(e){return e=e.session.$mode||{},e.blockComment&&e.blockComment.end||""},LINE_COMMENT:function(e){return(e.session.$mode||{}).lineCommentStart||""},CURRENT_YEAR:p.bind(null,{year:"numeric"}),CURRENT_YEAR_SHORT:p.bind(null,{year:"2-digit"}),CURRENT_MONTH:p.bind(null,{month:"numeric"}),CURRENT_MONTH_NAME:p.bind(null,{month:"long"}),CURRENT_MONTH_NAME_SHORT:p.bind(null,{month:"short"}),CURRENT_DATE:p.bind(null,{day:"2-digit"}),CURRENT_DAY_NAME:p.bind(null,{weekday:"long"}),CURRENT_DAY_NAME_SHORT:p.bind(null,{weekday:"short"}),CURRENT_HOUR:p.bind(null,{hour:"2-digit",hour12:!1}),CURRENT_MINUTE:p.bind(null,{minute:"2-digit"}),CURRENT_SECOND:p.bind(null,{second:"2-digit"})};function p(e){return e=new Date().toLocaleString("en-us",e),e.length==1?"0"+e:e}x.SELECTED_TEXT=x.SELECTION;function l(){this.snippetMap={},this.snippetNameMap={}}(function(){Z.implement(this,O),this.getTokenizer=function(){return l.$tokenizer||this.createTokenizer()},this.createTokenizer=function(){function e(o){return o=o.substr(1),/^\d+$/.test(o)?[{tabstopId:parseInt(o,10)}]:[{text:o}]}function r(o){return"(?:[^\\\\"+o+"]|\\\\.)"}var a={regex:"/("+r("/")+"+)/",onMatch:function(o,c,h){return h=h[0],h.fmtString=!0,h.guard=o.slice(1,-1),h.flag=""},next:"formatString"};return l.$tokenizer=new m({start:[{regex:/\\./,onMatch:function(o,c,h){var A=o[1];return[o=A=="}"&&h.length||"`$\\".indexOf(A)!=-1?A:o]}},{regex:/}/,onMatch:function(o,c,h){return[h.length?h.shift():o]}},{regex:/\$(?:\d+|\w+)/,onMatch:e},{regex:/\$\{[\dA-Z_a-z]+/,onMatch:function(o,c,h){return o=e(o.substr(1)),h.unshift(o[0]),o},next:"snippetVar"},{regex:/\n/,token:"newline",merge:!1}],snippetVar:[{regex:"\\|"+r("\\|")+"*\\|",onMatch:function(o,c,h){return o=o.slice(1,-1).replace(/\\[,|\\]|,/g,function(A){return A.length==2?A[1]:"\0"}).split("\0").map(function(A){return{value:A}}),[(h[0].choices=o)[0]]},next:"start"},a,{regex:"([^:}\\\\]|\\\\.)*:?",token:"",next:"start"}],formatString:[{regex:/:/,onMatch:function(o,c,h){return h.length&&h[0].expectElse?(h[0].expectElse=!1,h[0].ifEnd={elseEnd:h[0]},[h[0].ifEnd]):":"}},{regex:/\\./,onMatch:function(o,c,h){var A=o[1];return A=="}"&&h.length||"`$\\".indexOf(A)!=-1?o=A:A=="n"?o=`
`:A=="t"?o="	":"ulULE".indexOf(A)!=-1&&(o={changeCase:A,local:"a"<A}),[o]}},{regex:"/\\w*}",onMatch:function(o,c,h){return h=h.shift(),h&&(h.flag=o.slice(1,-1)),this.next=h&&h.tabstopId?"start":"",[h||o]},next:"start"},{regex:/\$(?:\d+|\w+)/,onMatch:function(o,c,h){return[{text:o.slice(1)}]}},{regex:/\${\w+/,onMatch:function(o,c,h){return o={text:o.slice(2)},h.unshift(o),[o]},next:"formatStringVar"},{regex:/\n/,token:"newline",merge:!1},{regex:/}/,onMatch:function(o,c,h){return h=h.shift(),this.next=h&&h.tabstopId?"start":"",[h||o]},next:"start"}],formatStringVar:[{regex:/:\/\w+}/,onMatch:function(o,c,h){return h[0].formatFunction=o.slice(2,-1),[h.shift()]},next:"formatString"},a,{regex:/:[\?\-+]?/,onMatch:function(o,c,h){o[1]=="+"&&(h[0].ifEnd=h[0]),o[1]=="?"&&(h[0].expectElse=!0)},next:"formatString"},{regex:"([^:}\\\\]|\\\\.)*:?",token:"",next:"formatString"}]})},this.tokenizeTmSnippet=function(e,r){return this.getTokenizer().getLineTokens(e,r).tokens.map(function(a){return a.value||a})},this.getVariableValue=function(e,r,a){var o;return/^\d+$/.test(r)?(this.variables.__||{})[r]||"":/^[A-Z]\d+$/.test(r)?(this.variables[r[0]+"__"]||{})[r.substr(1)]||"":(r=r.replace(/^TM_/,""),!this.variables.hasOwnProperty(r)||(o=typeof(o=this.variables[r])=="function"?this.variables[r](e,r,a):o)==null?"":o)},this.variables=x,this.tmStrFormat=function(e,r,a){var o,c,h,A;return r.fmt?(o=r.flag||"",c=r.guard,c=new RegExp(c,o.replace(/[^gim]/g,"")),h=typeof r.fmt=="string"?this.tokenizeTmSnippet(r.fmt,"formatString"):r.fmt,A=this,e.replace(c,function(){for(var v=A.variables.__,d=(A.variables.__=[].slice.call(arguments),A.resolveVariables(h,a)),g="E",y=0;y<d.length;y++){var w,I=d[y];typeof I=="object"?(d[y]="",I.changeCase&&I.local?(w=d[y+1])&&typeof w=="string"&&(I.changeCase=="u"?d[y]=w[0].toUpperCase():d[y]=w[0].toLowerCase(),d[y+1]=w.substr(1)):I.changeCase&&(g=I.changeCase)):g=="U"?d[y]=I.toUpperCase():g=="L"&&(d[y]=I.toLowerCase())}return A.variables.__=v,d.join("")})):e},this.tmFormatFunction=function(e,r,a){return r.formatFunction=="upcase"?e.toUpperCase():r.formatFunction=="downcase"?e.toLowerCase():e},this.resolveVariables=function(e,r){for(var a=[],o="",c=!0,h=0;h<e.length;h++){var A,v=e[h];typeof v=="string"?(a.push(v),v==`
`?(c=!0,o=""):c&&(o=/^\t*/.exec(v)[0],c=/\S/.test(v))):v&&(c=!1,v.fmtString&&((A=e.indexOf(v,h+1))==-1&&(A=e.length),v.fmt=e.slice(h+1,A),h=A),v.text?(A=this.getVariableValue(r,v.text,o)+"",v.fmtString&&(A=this.tmStrFormat(A,v,r)),(A=v.formatFunction?this.tmFormatFunction(A,v,r):A)&&!v.ifEnd?(a.push(A),d(v)):!A&&v.ifEnd&&d(v.ifEnd)):v.elseEnd?d(v.elseEnd):v.tabstopId==null&&v.changeCase==null||a.push(v))}function d(g){g=e.indexOf(g,h+1),g!=-1&&(h=g)}return a},this.insertSnippetForSelection=function(e,P){for(var _=e.getCursorPosition(),E=e.session.getLine(_.row),a=e.session.getTabString(),o=E.match(/^\s*/)[0],c=(_.column<o.length&&(o=o.slice(0,_.column)),P=P.replace(/\r/g,""),this.tokenizeTmSnippet(P)),h=(c=(c=this.resolveVariables(c,e)).map(function(z){return z==`
`?z+o:typeof z=="string"?z.replace(/\t/g,a):z}),[]),A=(c.forEach(function(z,D){var Y,R;typeof z=="object"&&(R=z.tabstopId,(Y=h[R])||((Y=h[R]=[]).index=R,Y.value="",Y.parents={}),Y.indexOf(z)===-1&&(z.choices&&!Y.choices&&(Y.choices=z.choices),Y.push(z),(R=c.indexOf(z,D+1))!==-1&&((z=c.slice(D+1,R)).some(function(H){return typeof H=="object"})&&!Y.value?Y.value=z:!z.length||Y.value&&typeof Y.value=="string"||(Y.value=z.join("")))))}),h.forEach(function(z){z.length=0}),{}),v=0;v<c.length;v++){var d,g,y,w=c[v];typeof w=="object"&&(y=w.tabstopId,d=h[y],g=c.indexOf(w,v+1),A[y]?A[y]===w&&(delete A[y],Object.keys(A).forEach(function(z){d.parents[z]=!0})):(A[y]=w,typeof(y=d.value)!="string"?y=function(z){for(var D=[],Y=0;Y<z.length;Y++){if(typeof(R=z[Y])=="object"){if(A[R.tabstopId])continue;var R=D[z.lastIndexOf(R,Y-1)]||{tabstopId:R.tabstopId}}D[Y]=R}return D}(y):w.fmt&&(y=this.tmStrFormat(y,w,e)),c.splice.apply(c,[v+1,Math.max(0,g-v)].concat(y,w)),d.indexOf(w)===-1&&d.push(w)))}var I=0,T=0,B="",E=(c.forEach(function(z){var D;typeof z=="string"?(1<(D=z.split(`
`)).length?(T=D[D.length-1].length,I+=D.length-1):T+=z.length,B+=z):z&&(z.start?z.end={row:I,column:T}:z.start={row:I,column:T})}),e.getSelectionRange()),_=e.session.replace(E,B),P=new s(e),j=e.inVirtualSelectionMode&&e.selection.index;P.addTabstops(h,E.start,_,j)},this.insertSnippet=function(e,r){var a=this;if(e.inVirtualSelectionMode)return a.insertSnippetForSelection(e,r);e.forEachSelection(function(){a.insertSnippetForSelection(e,r)},null,{keepOrder:!0}),e.tabstopManager&&e.tabstopManager.tabNext()},this.$getScope=function(e){var r,a=e.session.$mode.$id||"";return(a=a.split("/").pop())!=="html"&&a!=="php"||(a!=="php"||e.session.$mode.inlinePhp||(a="html"),r=e.getCursorPosition(),(e=typeof(e=e.session.getState(r.row))=="object"?e[0]:e).substring&&(e.substring(0,3)=="js-"?a="javascript":e.substring(0,4)=="css-"?a="css":e.substring(0,4)=="php-"&&(a="php"))),a},this.getActiveScopes=function(r){var r=this.$getScope(r),a=[r],o=this.snippetMap;return o[r]&&o[r].includeScopes&&a.push.apply(a,o[r].includeScopes),a.push("_"),a},this.expandWithTab=function(e,r){var a=this,o=e.forEachSelection(function(){return a.expandSnippetForSelection(e,r)},null,{keepOrder:!0});return o&&e.tabstopManager&&e.tabstopManager.tabNext(),o},this.expandSnippetForSelection=function(e,r){var a,o=e.getCursorPosition(),c=e.session.getLine(o.row),h=c.substring(0,o.column),A=c.substr(o.column),v=this.snippetMap;return this.getActiveScopes(e).some(function(d){return d=v[d],!!(a=d?this.findMatchingSnippet(d,h,A):a)},this),!!a&&(r&&r.dryRun||(e.session.doc.removeInLine(o.row,o.column-a.replaceBefore.length,o.column+a.replaceAfter.length),this.variables.M__=a.matchBefore,this.variables.T__=a.matchAfter,this.insertSnippetForSelection(e,a.content),this.variables.M__=this.variables.T__=null),!0)},this.findMatchingSnippet=function(e,r,a){for(var o=e.length;o--;){var c=e[o];if((!c.startRe||c.startRe.test(r))&&(!c.endRe||c.endRe.test(a))&&(c.startRe||c.endRe))return c.matchBefore=c.startRe?c.startRe.exec(r):[""],c.matchAfter=c.endRe?c.endRe.exec(a):[""],c.replaceBefore=c.triggerRe?c.triggerRe.exec(r)[0]:"",c.replaceAfter=c.endTriggerRe?c.endTriggerRe.exec(a)[0]:"",c}},this.snippetMap={},this.snippetNameMap={},this.register=function(e,r){var a=this.snippetMap,o=this.snippetNameMap,c=this;function h(d){return(d=d&&!/^\^?\(.*\)\$?$|^\\b$/.test(d)?"(?:"+d+")":d)||""}function A(d,g,y){return d=h(d),g=h(g),y?(d=g+d)&&d[d.length-1]!="$"&&(d+="$"):(d+=g)&&d[0]!="^"&&(d="^"+d),new RegExp(d)}function v(d){d.scope||(d.scope=r||"_"),r=d.scope,a[r]||(a[r]=[],o[r]={});var g,y=o[r];d.name&&((g=y[d.name])&&c.unregister(g),y[d.name]=d),a[r].push(d),d.prefix&&(d.tabTrigger=d.prefix),!d.content&&d.body&&(d.content=Array.isArray(d.body)?d.body.join(`
`):d.body),d.tabTrigger&&!d.trigger&&(!d.guard&&/^\w/.test(d.tabTrigger)&&(d.guard="\\b"),d.trigger=W.escapeRegExp(d.tabTrigger)),(d.trigger||d.guard||d.endTrigger||d.endGuard)&&(d.startRe=A(d.trigger,d.guard,!0),d.triggerRe=new RegExp(d.trigger),d.endRe=A(d.endTrigger,d.endGuard,!0),d.endTriggerRe=new RegExp(d.endTrigger))}e=e||[],Array.isArray(e)?e.forEach(v):Object.keys(e).forEach(function(d){v(e[d])}),this._signal("registerSnippets",{scope:r})},this.unregister=function(e,r){var a=this.snippetMap,o=this.snippetNameMap;function c(h){var A=o[h.scope||r];A&&A[h.name]&&(delete A[h.name],0<=(h=(A=a[h.scope||r])&&A.indexOf(h))&&A.splice(h,1))}e.content?c(e):Array.isArray(e)&&e.forEach(c)},this.parseSnippetFile=function(e){e=e.replace(/\r/g,"");for(var r,a,o,c=[],h={},A=/^#.*|^({[\s\S]*})\s*$|^(\S+) (.*)$|^((?:\n*\t.*)+)/gm;a=A.exec(e);){if(a[1])try{h=JSON.parse(a[1]),c.push(h)}catch{}a[4]?(h.content=a[4].replace(/^\t/gm,""),c.push(h),h={}):(r=a[2],a=a[3],r=="regex"?(h.guard=(o=/\/((?:[^\/\\]|\\.)*)|$/g).exec(a)[1],h.trigger=o.exec(a)[1],h.endTrigger=o.exec(a)[1],h.endGuard=o.exec(a)[1]):r=="snippet"?(h.tabTrigger=a.match(/^\S*/)[0],h.name||(h.name=a)):r&&(h[r]=a))}return c},this.getSnippetByName=function(e,r){var a,o=this.snippetNameMap;return this.getActiveScopes(r).some(function(c){return c=o[c],!!(a=c?c[e]:a)},this),a}}).call(l.prototype);var s=function(e){if(e.tabstopManager)return e.tabstopManager;(e.tabstopManager=this).$onChange=this.onChange.bind(this),this.$onChangeSelection=W.delayedCall(this.onChangeSelection.bind(this)).schedule,this.$onChangeSession=this.onChangeSession.bind(this),this.$onAfterExec=this.onAfterExec.bind(this),this.attach(e)},n=(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 r=e.action[0]=="r",a=this.selectedTabstop||{},o=a.parents||{},c=(this.tabstops||[]).slice(),h=0;h<c.length;h++){var A=c[h],v=A==a||o[A.index];if(A.rangeList.$bias=v?0:1,e.action=="remove"&&A!==a)for(var v=A.parents&&A.parents[a.index],d=(d=A.rangeList.pointIndex(e.start,v))<0?-d-1:d+1,v=(v=A.rangeList.pointIndex(e.end,v))<0?-v-1:v-1,g=A.rangeList.ranges.slice(d,v),y=0;y<g.length;y++)this.removeRange(g[y]);A.rangeList.$onChange(e)}var w=this.editor.session;this.$inChange||!r||w.getLength()!=1||w.getValue()||this.detach()},this.updateLinkedFields=function(){var e=this.selectedTabstop;if(e&&e.hasLinkedRanges&&e.firstNonLinked){this.$inChange=!0;for(var r=this.editor.session,a=r.getTextRange(e.firstNonLinked),o=0;o<e.length;o++){var c,h=e[o];h.linked&&(c=h.original,c=k.snippetManager.tmStrFormat(a,c,this.editor),r.replace(h,c))}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,r=this.editor.selection.anchor,a=this.editor.selection.isEmpty(),o=0;o<this.ranges.length;o++)if(!this.ranges[o].linked){var c=this.ranges[o].contains(e.row,e.column),h=a||this.ranges[o].contains(r.row,r.column);if(c&&h)return}this.detach()}},this.onChangeSession=function(){this.detach()},this.tabNext=function(a){var r=this.tabstops.length,a=this.index+(a||1),a=Math.min(Math.max(a,1),r);this.selectTabstop(a=a==r?0:a),a===0&&this.detach()},this.selectTabstop=function(e){this.$openTabstops=null;var r=this.tabstops[this.index];if(r&&this.addTabstopMarkers(r),this.index=e,(r=this.tabstops[this.index])&&r.length){if(e=(this.selectedTabstop=r).firstNonLinked||r,r.choices&&(e.cursor=e.start),this.editor.inVirtualSelectionMode)this.editor.selection.fromOrientedRange(e);else{var a=this.editor.multiSelect;a.toSingleRange(e);for(var o=0;o<r.length;o++)r.hasLinkedRanges&&r[o].linked||a.addRange(r[o].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,r,a){var o=this.useLink||!this.editor.getOption("enableMultiselect");this.$openTabstops||(this.$openTabstops=[]),e[0]||(a=F.fromPoints(a,a),t(a.start,r),t(a.end,r),e[0]=[a],e[0].index=0);var c=[this.index+1,0],h=this.ranges;e.forEach(function(A,v){for(var d=this.$openTabstops[v]||A,g=0;g<A.length;g++){var y=A[g],w=F.fromPoints(y.start,y.end||y.start);n(w.start,r),n(w.end,r),w.original=y,w.tabstop=d,h.push(w),d!=A?d.unshift(w):d[g]=w,y.fmtString||d.firstNonLinked&&o?(w.linked=!0,d.hasLinkedRanges=!0):d.firstNonLinked||(d.firstNonLinked=w)}d.firstNonLinked||(d.hasLinkedRanges=!1),d===A&&(c.push(d),this.$openTabstops[v]=d),this.addTabstopMarkers(d),d.rangeList=d.rangeList||new L,d.rangeList.$bias=0,d.rangeList.addList(d)},this),2<c.length&&(this.tabstops.length&&c.push(c.splice(2,1)[0]),this.tabstops.splice.apply(this.tabstops,c))},this.addTabstopMarkers=function(e){var r=this.editor.session;e.forEach(function(a){a.markerId||(a.markerId=r.addMarker(a,"ace_snippet-marker","text"))})},this.removeTabstopMarkers=function(e){var r=this.editor.session;e.forEach(function(a){r.removeMarker(a.markerId),a.markerId=null})},this.removeRange=function(e){var r=e.tabstop.indexOf(e);r!=-1&&e.tabstop.splice(r,1),(r=this.ranges.indexOf(e))!=-1&&this.ranges.splice(r,1),(r=e.tabstop.rangeList.ranges.indexOf(e))!=-1&&e.tabstop.splice(r,1),this.editor.session.removeMarker(e.markerId),e.tabstop.length||((r=this.tabstops.indexOf(e.tabstop))!=-1&&this.tabstops.splice(r,1),this.tabstops.length||this.detach())},this.keyboardHandler=new C,this.keyboardHandler.bindKeys({Tab:function(e){k.snippetManager&&k.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(s.prototype),function(e,r){e.row==0&&(e.column+=r.column),e.row+=r.row}),t=function(e,r){e.row==r.row&&(e.column-=r.column),e.row-=r.row},i=(i.importCssString(`
.ace_snippet-marker {
    -moz-box-sizing: border-box;
    box-sizing: border-box;
    background: rgba(194, 193, 208, 0.09);
    border: 1px dotted rgba(211, 208, 235, 0.62);
    position: absolute;
}`,"snippets.css",!1),k.snippetManager=new l,X("./editor").Editor);(function(){this.insertSnippet=function(e,r){return k.snippetManager.insertSnippet(this,e,r)},this.expandSnippet=function(e){return k.snippetManager.expandWithTab(this,e)}}).call(i.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(X,k,N){function Z(b){return(b=new O(b)).$maxLines=4,(b=new W(b)).setHighlightActiveLine(!1),b.setShowPrintMargin(!1),b.renderer.setShowGutter(!1),b.renderer.setHighlightGutterLine(!1),b.$mouseHandler.$focusTimeout=0,b.$highlightTagPending=!0,b}var O=X("../virtual_renderer").VirtualRenderer,W=X("../editor").Editor,F=X("../range").Range,L=X("../lib/event"),C=X("../lib/lang"),m=X("../lib/dom");m.importCssString(`
.ace_editor.ace_autocomplete .ace_marker-layer .ace_active-line {
    background-color: #CAD6FA;
    z-index: 1;
}
.ace_dark.ace_editor.ace_autocomplete .ace_marker-layer .ace_active-line {
    background-color: #3a674e;
}
.ace_editor.ace_autocomplete .ace_line-hover {
    border: 1px solid #abbffe;
    margin-top: -1px;
    background: rgba(233,233,253,0.4);
    position: absolute;
    z-index: 2;
}
.ace_dark.ace_editor.ace_autocomplete .ace_line-hover {
    border: 1px solid rgba(109, 150, 13, 0.8);
    background: rgba(58, 103, 78, 0.62);
}
.ace_completion-meta {
    opacity: 0.5;
    margin: 0.9em;
}
.ace_completion-message {
    color: blue;
}
.ace_editor.ace_autocomplete .ace_completion-highlight{
    color: #2d69c7;
}
.ace_dark.ace_editor.ace_autocomplete .ace_completion-highlight{
    color: #93ca12;
}
.ace_editor.ace_autocomplete {
    width: 300px;
    z-index: 200000;
    border: 1px lightgray solid;
    position: fixed;
    box-shadow: 2px 3px 5px rgba(0,0,0,.2);
    line-height: 1.4;
    background: #fefefe;
    color: #111;
}
.ace_dark.ace_editor.ace_autocomplete {
    border: 1px #484747 solid;
    box-shadow: 2px 3px 5px rgba(0, 0, 0, 0.51);
    line-height: 1.4;
    background: #25282c;
    color: #c1c1c1;
}`,"autocompletion.css",!1),k.AcePopup=function(r){function x(){}function p(){e(-1)}var l,s=m.createElement("div"),n=new Z(s),t=(r&&r.appendChild(s),s.style.display="none",n.renderer.content.style.cursor="default",n.renderer.setStyle("ace_autocomplete"),n.setOption("displayIndentGuides",!1),n.setOption("dragDelay",150),n.focus=x,n.$isFocused=!0,n.renderer.$cursorLayer.restartTimer=x,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(a){var o=a.getDocumentPosition();n.selection.moveToPosition(o),i.start.row=i.end.row=o.row,a.stop()}),new F(-1,0,-1,1/0)),i=new F(-1,0,-1,1/0),e=(i.id=n.session.addMarker(i,"ace_active-line","fullLine"),n.setSelectOnHover=function(a){a?t.id&&(n.session.removeMarker(t.id),t.id=null):t.id=n.session.addMarker(t,"ace_line-hover","fullLine")},n.setSelectOnHover(!1),n.on("mousemove",function(a){var o;l?l.x==a.x&&l.y==a.y||((l=a).scrollTop=n.renderer.scrollTop,o=l.getDocumentPosition().row,t.start.row!=o&&(t.id||n.setRow(o),e(o))):l=a}),n.renderer.on("beforeRender",function(){var a;l&&t.start.row!=-1&&(l.$pos=null,a=l.getDocumentPosition().row,t.id||n.setRow(a),e(a,!0))}),n.renderer.on("afterRender",function(){var o=n.getRow(),a=n.renderer.$textLayer,o=a.element.childNodes[o-a.config.firstRow];o!==a.selectedNode&&a.selectedNode&&m.removeCssClass(a.selectedNode,"ace_selected"),(a.selectedNode=o)&&m.addCssClass(o,"ace_selected")}),function(a,o){a!==t.start.row&&(t.start.row=t.end.row=a,o||n.session._emit("changeBackMarker"),n._emit("changeHoverMarker"))}),r=(n.getHoveredRow=function(){return t.start.row},L.addListener(n.container,"mouseout",p),n.on("hide",p),n.on("changeSelection",p),n.session.doc.getLength=function(){return n.data.length},n.session.doc.getLine=function(a){return a=n.data[a],typeof a=="string"?a:a&&a.value||""},n.session.bgTokenizer);return r.$tokenizeRow=function(a){var o=n.data[a],c=[];if(o){for(var h,A,v=(o=typeof o=="string"?{value:o}:o).caption||o.value||o.name,d=v.toLowerCase(),g=(n.filterText||"").toLowerCase(),y=0,w=0,I=0;I<=g.length;I++)I!=w&&(o.matchMask&1<<I||I==g.length)&&(h=g.slice(w,I),w=I,(A=d.indexOf(h,y))!=-1&&(T(v.slice(y,A),""),y=A+h.length,T(v.slice(A,y),"completion-highlight")));T(v.slice(y,v.length),""),o.meta&&c.push({type:"completion-meta",value:o.meta}),o.message&&c.push({type:"completion-message",value:o.message})}return c;function T(B,E){B&&c.push({type:(o.className||"")+(E||""),value:B})}},r.$updateOnChange=x,r.start=x,n.session.$computeWidth=function(){return this.screenWidth=0},n.isOpen=!1,n.isTopdown=!1,n.autoSelect=!0,n.filterText="",n.data=[],n.setData=function(a,o){n.filterText=o||"",n.setValue(C.stringRepeat(`
`,a.length),-1),n.data=a||[],n.setRow(0)},n.getData=function(a){return n.data[a]},n.getRow=function(){return i.start.row},n.setRow=function(a){a=Math.max(this.autoSelect?0:-1,Math.min(this.data.length,a)),i.start.row!=a&&(n.selection.clearSelection(),i.start.row=i.end.row=a||0,n.session._emit("changeBackMarker"),n.moveCursorTo(a||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",this._signal("hide"),n.isOpen=!1},n.show=function(a,o,w){var h=this.container,A=window.innerHeight,v=window.innerWidth,d=this.renderer,g=d.$maxLines*o*1.4,y=a.top+this.$borderSize,w=(A/2<y&&!w&&A<y+o+g?(d.$maxPixelHeight=y-2*this.$borderSize,h.style.top="",h.style.bottom=A-y+"px",n.isTopdown=!1):(d.$maxPixelHeight=A-(y+=o)-.2*o,h.style.top=y+"px",h.style.bottom="",n.isTopdown=!0),h.style.display="",a.left);w+h.offsetWidth>v&&(w=v-h.offsetWidth),h.style.left=w+"px",this._signal("show"),l=null,n.isOpen=!0},n.goTo=function(a){var o=this.getRow(),c=this.session.getLength()-1;switch(a){case"up":o=o<=0?c:o-1;break;case"down":o=c<=o?-1:o+1;break;case"start":o=0;break;case"end":o=c}this.setRow(o)},n.getTextLeftOffset=function(){return this.$borderSize+this.renderer.$padding+this.$imageSize},n.$imageSize=0,n.$borderSize=1,n},k.$singleLineEditor=Z}),ace.define("ace/autocomplete/util",["require","exports","module"],function(X,k,N){k.parForEach=function(O,W,F){var L=0,C=O.length;C===0&&F();for(var m=0;m<C;m++)W(O[m],function(b,x){++L===C&&F(b,x)})};var Z=/[a-zA-Z_0-9\$\-\u00A2-\u2000\u2070-\uFFFF]/;k.retrievePrecedingIdentifier=function(O,W,F){F=F||Z;for(var L=[],C=W-1;0<=C&&F.test(O[C]);C--)L.push(O[C]);return L.reverse().join("")},k.retrieveFollowingIdentifier=function(O,W,F){F=F||Z;for(var L=[],C=W;C<O.length&&F.test(O[C]);C++)L.push(O[C]);return L},k.getCompletionPrefix=function(O){var W,F=O.getCursorPosition(),L=O.session.getLine(F.row);return O.completers.forEach(function(C){C.identifierRegexps&&C.identifierRegexps.forEach(function(m){!W&&m&&(W=this.retrievePrecedingIdentifier(L,F.column,m))}.bind(this))}.bind(this)),W||this.retrievePrecedingIdentifier(L,F.column)}}),ace.define("ace/autocomplete",["require","exports","module","ace/keyboard/hash_handler","ace/autocomplete/popup","ace/autocomplete/util","ace/lib/lang","ace/lib/dom","ace/snippets","ace/config"],function(X,k,N){function Z(){this.autoInsert=!1,this.autoSelect=!0,this.exactMatch=!1,this.gatherCompletionsId=0,this.keyboardHandler=new O,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)}var O=X("./keyboard/hash_handler").HashHandler,W=X("./autocomplete/popup").AcePopup,F=X("./autocomplete/util"),L=X("./lib/lang"),C=X("./lib/dom"),m=X("./snippets").snippetManager,b=X("./config"),x=(function(){this.$init=function(){return this.popup=new W(document.body||document.documentElement),this.popup.on("click",function(p){this.insertMatch(),p.stop()}.bind(this)),this.popup.focus=this.editor.focus.bind(this.editor),this.popup.on("show",this.tooltipTimer.bind(null,null)),this.popup.on("select",this.tooltipTimer.bind(null,null)),this.popup.on("changeHoverMarker",this.tooltipTimer.bind(null,null)),this.popup},this.getPopup=function(){return this.popup||this.$init()},this.openPopup=function(p,l,s){this.popup||this.$init(),this.popup.autoSelect=this.autoSelect,this.popup.setData(this.completions.filtered,this.completions.filterText),p.keyBinding.addKeyboardHandler(this.keyboardHandler);var n,t=p.renderer;this.popup.setRow(this.autoSelect?0:-1),s?l||this.detach():(this.popup.setTheme(p.getTheme()),this.popup.setFontSize(p.getFontSize()),s=t.layerConfig.lineHeight,(l=t.$cursorLayer.getPixelPosition(this.base,!0)).left-=this.popup.getTextLeftOffset(),n=p.container.getBoundingClientRect(),l.top+=n.top-t.layerConfig.offset,l.left+=n.left-p.renderer.scrollLeft,l.left+=t.gutterWidth,this.popup.show(l,s)),this.changeTimer.cancel()},this.detach=function(){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.gatherCompletionsId+=1,this.popup&&this.popup.isOpen&&this.popup.hide(),this.base&&this.base.detach(),this.activated=!1,this.completions=this.base=null},this.changeListener=function(p){var l=this.editor.selection.lead;(l.row!=this.base.row||l.column<this.base.column)&&this.detach(),this.activated?this.changeTimer.schedule():this.detach()},this.blurListener=function(p){var l=document.activeElement,s=this.editor.textInput.getElement(),n=p.relatedTarget&&this.tooltipNode&&this.tooltipNode.contains(p.relatedTarget),t=this.popup&&this.popup.container;l==s||l.parentNode==t||n||l==this.tooltipNode||p.relatedTarget==s||this.detach()},this.mousedownListener=function(p){this.detach()},this.mousewheelListener=function(p){this.detach()},this.goTo=function(p){this.popup.goTo(p)},this.insertMatch=function(p,l){if(!(p=p||this.popup.getData(this.popup.getRow())))return!1;var s=this.completions;if(this.editor.startOperation({command:{name:"insertMatch"}}),p.completer&&p.completer.insertMatch)p.completer.insertMatch(this.editor,p);else{if(!s)return!1;if(s.filterText)for(var n,t=this.editor.selection.getAllRanges(),i=0;n=t[i];i++)n.start.column-=s.filterText.length,this.editor.session.remove(n);p.snippet?m.insertSnippet(this.editor,p.snippet):this.editor.execCommand("insertstring",p.value||p)}this.completions==s&&this.detach(),this.editor.endOperation()},this.commands={Up:function(p){p.completer.goTo("up")},Down:function(p){p.completer.goTo("down")},"Ctrl-Up|Ctrl-Home":function(p){p.completer.goTo("start")},"Ctrl-Down|Ctrl-End":function(p){p.completer.goTo("end")},Esc:function(p){p.completer.detach()},Return:function(p){return p.completer.insertMatch()},"Shift-Return":function(p){p.completer.insertMatch(null,{deleteSuffix:!0})},Tab:function(p){var l=p.completer.insertMatch();if(l||p.tabstopManager)return l;p.completer.goTo("down")},PageUp:function(p){p.completer.popup.gotoPageUp()},PageDown:function(p){p.completer.popup.gotoPageDown()}},this.gatherCompletions=function(p,l){var s=p.getSession(),n=p.getCursorPosition(),t=F.getCompletionPrefix(p),i=(this.base=s.doc.createAnchor(n.row,n.column-t.length),this.base.$insertRight=!0,[]),e=p.completers.length;return p.completers.forEach(function(r,a){r.getCompletions(p,s,n,t,function(o,c){!o&&c&&(i=i.concat(c)),l(null,{prefix:F.getCompletionPrefix(p),matches:i,finished:--e==0})})}),!0},this.showPopup=function(p,l){this.editor&&this.detach(),this.activated=!0,(this.editor=p).completer!=this&&(p.completer&&p.completer.detach(),p.completer=this),p.on("changeSelection",this.changeListener),p.on("blur",this.blurListener),p.on("mousedown",this.mousedownListener),p.on("mousewheel",this.mousewheelListener),this.updateCompletions(!1,l)},this.updateCompletions=function(p,l){var s,n,t,i,e,r,a;return p&&this.base&&this.completions?(s=this.editor.getCursorPosition(),(r=this.editor.session.getTextRange({start:this.base,end:s}))==this.completions.filterText?void 0:(this.completions.setFilter(r),this.completions.filtered.length&&(this.completions.filtered.length!=1||this.completions.filtered[0].value!=r||this.completions.filtered[0].snippet)?void this.openPopup(this.editor,r,p):this.detach())):l&&l.matches?(s=this.editor.getSelectionRange().start,this.base=this.editor.session.doc.createAnchor(s.row,s.column),this.base.$insertRight=!0,this.completions=new x(l.matches),this.openPopup(this.editor,"",p)):(n=this.gatherCompletionsId,t=function(o){if(o.finished)return this.detach()}.bind(this),i=function(o){var c=o.prefix,h=o.matches,h=(this.completions=new x(h),this.exactMatch&&(this.completions.exactMatch=!0),this.completions.setFilter(c),this.completions.filtered);return h.length&&(h.length!=1||h[0].value!=c||h[0].snippet)?this.autoInsert&&h.length==1&&o.finished?this.insertMatch(h[0]):void this.openPopup(this.editor,c,p):t(o)}.bind(this),e=!0,a=null,this.gatherCompletions(this.editor,function(o,c){var h=c.prefix,A=c&&c.matches;if(!A||!A.length)return t(c);h.indexOf(c.prefix)===0&&n==this.gatherCompletionsId&&(e?a=c:i(c))}.bind(this)),e=!1,void(a&&(r=a,a=null,i(r))))},this.cancelContextMenu=function(){this.editor.$mouseHandler.cancelContextMenu()},this.updateDocTooltip=function(){var p=this.popup,l=p.data,s=l&&(l[p.getHoveredRow()]||l[p.getRow()]),n=null;return s&&this.editor&&this.popup.isOpen&&(this.editor.completers.some(function(t){return n=t.getDocTooltip?t.getDocTooltip(s):n}),(n=typeof(n=n||typeof s=="string"?n:s)=="string"?{docText:n}:n)&&(n.docHTML||n.docText))?void this.showDocTooltip(n):this.hideDocTooltip()},this.showDocTooltip=function(s){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 l=this.tooltipNode,s=(s.docHTML?l.innerHTML=s.docHTML:s.docText&&(l.textContent=s.docText),l.parentNode||document.body.appendChild(l),this.popup),n=s.container.getBoundingClientRect();l.style.top=s.container.style.top,l.style.bottom=s.container.style.bottom,l.style.display="block",window.innerWidth-n.right<320?n.left<320?(s.isTopdown?l.style.top=n.bottom+"px":l.style.top=s.container.offsetTop-l.offsetHeight+"px",l.style.left=n.left+"px",l.style.right="",l.style.bottom=""):(l.style.right=window.innerWidth-n.left+"px",l.style.left=""):(l.style.left=n.right+1+"px",l.style.right="")},this.hideDocTooltip=function(){var p;this.tooltipTimer.cancel(),this.tooltipNode&&(p=this.tooltipNode,this.editor.isFocused()||document.activeElement!=p||this.editor.focus(),this.tooltipNode=null,p.parentNode&&p.parentNode.removeChild(p))},this.onTooltipClick=function(p){for(var l=p.target;l&&l!=this.tooltipNode;){if(l.nodeName=="A"&&l.href){l.rel="noreferrer",l.target="_blank";break}l=l.parentNode}},this.destroy=function(){var p;this.detach(),this.popup&&(this.popup.destroy(),(p=this.popup.container)&&p.parentNode&&p.parentNode.removeChild(p)),this.editor&&this.editor.completer==this&&this.editor.completer,this.popup=null}}.call(Z.prototype),Z.for=function(p){return p.completer||(b.get("sharedPopups")?(Z.$shared||(Z.$sharedInstance=new Z),p.completer=Z.$sharedInstance):(p.completer=new Z,p.once("destroy",function(l,s){s.completer.destroy()}))),p.completer},Z.startCommand={name:"startAutocomplete",exec:function(p,l){var s=Z.for(p);s.autoInsert=!1,s.autoSelect=!0,s.showPopup(p,l),s.cancelContextMenu()},bindKey:"Ctrl-Space|Ctrl-Shift-Space|Alt-Space"},function(p,l){this.all=p,this.filtered=p,this.filterText=l||"",this.exactMatch=!1});(function(){this.setFilter=function(p){l=p.length>this.filterText&&p.lastIndexOf(this.filterText,0)===0?this.filtered:this.all,this.filterText=p,l=(l=this.filterCompletions(l,this.filterText)).sort(function(n,t){return t.exactMatch-n.exactMatch||t.$score-n.$score||(n.caption||n.value).localeCompare(t.caption||t.value)});var l,s=null;l=l.filter(function(n){return n=n.snippet||n.caption||n.value,n!==s&&(s=n,!0)}),this.filtered=l},this.filterCompletions=function(p,l){var s=[],n=l.toUpperCase(),t=l.toLowerCase();e:for(var i,e=0;i=p[e];e++){var r=i.caption||i.value||i.snippet;if(r){var a=-1,o=0,c=0;if(this.exactMatch){if(l!==r.substr(0,l.length))continue}else{var h=r.toLowerCase().indexOf(t);if(-1<h)c=h;else for(var A=0;A<l.length;A++){var v=r.indexOf(t[A],a+1),d=r.indexOf(n[A],a+1);if((v=0<=v&&(d<0||v<d)?v:d)<0)continue e;0<(d=v-a-1)&&(a===-1&&(c+=10),c+=d,o|=1<<A),a=v}}i.matchMask=o,i.exactMatch=c?0:1,i.$score=(i.score||0)-c,s.push(i)}}return s}}).call(x.prototype),k.Autocomplete=Z,k.FilteredList=x}),ace.define("ace/autocomplete/text_completer",["require","exports","module","ace/range"],function(X,k,N){var Z=X("../range").Range,O=/[^a-zA-Z_0-9\$\-\u00C0-\u1FFF\u2C00-\uD7FF\w]+/;function W(F,L){var C=F.getTextRange(Z.fromPoints({row:0,column:0},L)).split(O).length-1,m=F.getValue().split(O),b=Object.create(null),x=m[C];return m.forEach(function(p,l){p&&p!==x&&(l=Math.abs(C-l),l=m.length-l,b[p]?b[p]=Math.max(l,b[p]):b[p]=l)}),b}k.getCompletions=function(F,L,C,m,b){var x=W(L,C);b(null,Object.keys(x).map(function(p){return{caption:p,value:p,score:x[p],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(X,k,N){function Z(i,e){s(e.session.$mode)}function O(i){var e=i.editor,r=e.completer&&e.completer.activated;i.command.name==="backspace"?r&&!m.getCompletionPrefix(e)&&e.completer.detach():i.command.name==="insertstring"&&m.getCompletionPrefix(e)&&!r&&((i=F.for(e)).autoInsert=!1,i.showPopup(e))}var W=X("../snippets").snippetManager,F=X("../autocomplete").Autocomplete,L=X("../config"),C=X("../lib/lang"),m=X("../autocomplete/util"),t=X("../autocomplete/text_completer"),b={getCompletions:function(i,e,r,a,o){if(e.$mode.completer)return e.$mode.completer.getCompletions(i,e,r,a,o);i=i.session.getState(r.row),o(null,e.$mode.getCompletions(i,e,r,a))}},x={getCompletions:function(i,h,r,a,o){var c=[],h=h.getTokenAt(r.row,r.column),A=(h&&h.type.match(/(tag-name|tag-open|tag-whitespace|attribute-name|attribute-value)\.xml$/)?c.push("html-tag"):c=W.getActiveScopes(i),W.snippetMap),v=[];c.forEach(function(d){for(var g=A[d]||[],y=g.length;y--;){var w=g[y],I=w.name||w.tabTrigger;I&&v.push({caption:I,snippet:w.content,meta:w.tabTrigger&&!w.name?w.tabTrigger+"\u21E5 ":"snippet",type:"snippet"})}},this),o(null,v)},getDocTooltip:function(i){var e;i.type!="snippet"||i.docHTML||(i.docHTML=["<b>",C.escapeHTML(i.caption),"</b>","<hr></hr>",C.escapeHTML((i=i.snippet,e={},i.replace(/\${(\d+)(:(.*?))?}/g,function(r,a,o,c){return e[a]=c||""}).replace(/\$(\d+?)/g,function(r,a){return e[a]})))].join(""))}},p=[x,t,b],l=(k.setCompleters=function(i){p.length=0,i&&p.push.apply(p,i)},k.addCompleter=function(i){p.push(i)},k.textCompleter=t,k.keyWordCompleter=b,k.snippetCompleter=x,{name:"expandSnippet",exec:function(i){return W.expandWithTab(i)},bindKey:"Tab"}),s=function(i){(i=typeof i=="string"?L.$modes[i]:i)&&(W.files||(W.files={}),n(i.$id,i.snippetFileId),i.modes&&i.modes.forEach(s))},n=function(i,e){e&&i&&!W.files[i]&&(W.files[i]={},L.loadModule(e,function(r){r&&(!(W.files[i]=r).snippets&&r.snippetText&&(r.snippets=W.parseSnippetFile(r.snippetText)),W.register(r.snippets||[],r.scope),r.includeScopes&&(W.snippetMap[r.scope].includeScopes=r.includeScopes,r.includeScopes.forEach(function(a){s("ace/mode/"+a)})))}))},t=X("../editor").Editor;X("../config").defineOptions(t.prototype,"editor",{enableBasicAutocompletion:{set:function(i){i?(this.completers||(this.completers=Array.isArray(i)?i:p),this.commands.addCommand(F.startCommand)):this.commands.removeCommand(F.startCommand)},value:!1},enableLiveAutocompletion:{set:function(i){i?(this.completers||(this.completers=Array.isArray(i)?i:p),this.commands.on("afterExec",O)):this.commands.removeListener("afterExec",O)},value:!1},enableSnippets:{set:function(i){i?(this.commands.addCommand(l),this.on("changeMode",Z),Z(0,this)):(this.commands.removeCommand(l),this.off("changeMode",Z))},value:!1}})}),ace.require(["ace/ext/language_tools"],function(X){ie&&(ie.exports=X)})},3330:function(ie,u,V){ie=V.nmd(ie),ace.define("ace/ext/searchbox.css",["require","exports","module"],function(X,k,N){N.exports=`

/* ------------------------------------------------------------------------------------------
 * Editor Search Form
 * --------------------------------------------------------------------------------------- */
.ace_search {
    background-color: #ddd;
    color: #666;
    border: 1px solid #cbcbcb;
    border-top: 0 none;
    overflow: hidden;
    margin: 0;
    padding: 4px 6px 0 4px;
    position: absolute;
    top: 0;
    z-index: 99;
    white-space: normal;
}
.ace_search.left {
    border-left: 0 none;
    border-radius: 0px 0px 5px 0px;
    left: 0;
}
.ace_search.right {
    border-radius: 0px 0px 0px 5px;
    border-right: 0 none;
    right: 0;
}

.ace_search_form, .ace_replace_form {
    margin: 0 20px 4px 0;
    overflow: hidden;
    line-height: 1.9;
}
.ace_replace_form {
    margin-right: 0;
}
.ace_search_form.ace_nomatch {
    outline: 1px solid red;
}

.ace_search_field {
    border-radius: 3px 0 0 3px;
    background-color: white;
    color: black;
    border: 1px solid #cbcbcb;
    border-right: 0 none;
    outline: 0;
    padding: 0;
    font-size: inherit;
    margin: 0;
    line-height: inherit;
    padding: 0 6px;
    min-width: 17em;
    vertical-align: top;
    min-height: 1.8em;
    box-sizing: content-box;
}
.ace_searchbtn {
    border: 1px solid #cbcbcb;
    line-height: inherit;
    display: inline-block;
    padding: 0 6px;
    background: #fff;
    border-right: 0 none;
    border-left: 1px solid #dcdcdc;
    cursor: pointer;
    margin: 0;
    position: relative;
    color: #666;
}
.ace_searchbtn:last-child {
    border-radius: 0 3px 3px 0;
    border-right: 1px solid #cbcbcb;
}
.ace_searchbtn:disabled {
    background: none;
    cursor: default;
}
.ace_searchbtn:hover {
    background-color: #eef1f6;
}
.ace_searchbtn.prev, .ace_searchbtn.next {
     padding: 0px 0.7em
}
.ace_searchbtn.prev:after, .ace_searchbtn.next:after {
     content: "";
     border: solid 2px #888;
     width: 0.5em;
     height: 0.5em;
     border-width:  2px 0 0 2px;
     display:inline-block;
     transform: rotate(-45deg);
}
.ace_searchbtn.next:after {
     border-width: 0 2px 2px 0 ;
}
.ace_searchbtn_close {
    background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAA4AAAAcCAYAAABRVo5BAAAAZ0lEQVR42u2SUQrAMAhDvazn8OjZBilCkYVVxiis8H4CT0VrAJb4WHT3C5xU2a2IQZXJjiQIRMdkEoJ5Q2yMqpfDIo+XY4k6h+YXOyKqTIj5REaxloNAd0xiKmAtsTHqW8sR2W5f7gCu5nWFUpVjZwAAAABJRU5ErkJggg==) no-repeat 50% 0;
    border-radius: 50%;
    border: 0 none;
    color: #656565;
    cursor: pointer;
    font: 16px/16px Arial;
    padding: 0;
    height: 14px;
    width: 14px;
    top: 9px;
    right: 7px;
    position: absolute;
}
.ace_searchbtn_close:hover {
    background-color: #656565;
    background-position: 50% 100%;
    color: white;
}

.ace_button {
    margin-left: 2px;
    cursor: pointer;
    -webkit-user-select: none;
    -moz-user-select: none;
    -o-user-select: none;
    -ms-user-select: none;
    user-select: none;
    overflow: hidden;
    opacity: 0.7;
    border: 1px solid rgba(100,100,100,0.23);
    padding: 1px;
    box-sizing:    border-box!important;
    color: black;
}

.ace_button:hover {
    background-color: #eee;
    opacity:1;
}
.ace_button:active {
    background-color: #ddd;
}

.ace_button.checked {
    border-color: #3399ff;
    opacity:1;
}

.ace_search_options{
    margin-bottom: 3px;
    text-align: right;
    -webkit-user-select: none;
    -moz-user-select: none;
    -o-user-select: none;
    -ms-user-select: none;
    user-select: none;
    clear: both;
}

.ace_search_counter {
    float: left;
    font-family: arial;
    padding: 0 8px;
}`}),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(X,k,N){function Z(b,x,p){var l=O.createElement("div");O.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"},"\u200B"],["span",{action:"findNext",class:"ace_searchbtn next"},"\u200B"],["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"]]],l),this.element=l.firstChild,this.setSession=this.setSession.bind(this),this.$init(),this.setEditor(b),O.importCssString(L,"ace_searchbox",b.container)}var O=X("../lib/dom"),W=X("../lib/lang"),F=X("../lib/event"),L=X("./searchbox.css"),C=X("../keyboard/hash_handler").HashHandler,m=X("../lib/keys");O.importCssString(L,"ace_searchbox",!1),function(){this.setEditor=function(b){b.searchBox=this,b.renderer.scroller.appendChild(this.element),this.editor=b},this.setSession=function(b){this.searchRange=null,this.$syncOptions(!0)},this.$initElements=function(b){this.searchBox=b.querySelector(".ace_search_form"),this.replaceBox=b.querySelector(".ace_replace_form"),this.searchOption=b.querySelector("[action=searchInSelection]"),this.replaceOption=b.querySelector("[action=toggleReplace]"),this.regExpOption=b.querySelector("[action=toggleRegexpMode]"),this.caseSensitiveOption=b.querySelector("[action=toggleCaseSensitive]"),this.wholeWordOption=b.querySelector("[action=toggleWholeWords]"),this.searchInput=this.searchBox.querySelector(".ace_search_field"),this.replaceInput=this.replaceBox.querySelector(".ace_search_field"),this.searchCounter=b.querySelector(".ace_search_counter")},this.$init=function(){var b=this.element,x=(this.$initElements(b),this);F.addListener(b,"mousedown",function(p){setTimeout(function(){x.activeInput.focus()},0),F.stopPropagation(p)}),F.addListener(b,"click",function(p){var l=(p.target||p.srcElement).getAttribute("action");l&&x[l]?x[l]():x.$searchBarKb.commands[l]&&x.$searchBarKb.commands[l].exec(x),F.stopPropagation(p)}),F.addCommandKeyListener(b,function(p,l,s){s=m.keyCodeToString(s),l=x.$searchBarKb.findKeyCommand(l,s),l&&l.exec&&(l.exec(x),F.stopEvent(p))}),this.$onChange=W.delayedCall(function(){x.find(!1,!1)}),F.addListener(this.searchInput,"input",function(){x.$onChange.schedule(20)}),F.addListener(this.searchInput,"focus",function(){x.activeInput=x.searchInput,x.searchInput.value&&x.highlight()}),F.addListener(this.replaceInput,"focus",function(){x.activeInput=x.replaceInput,x.searchInput.value&&x.highlight()})},this.$closeSearchBarKb=new C([{bindKey:"Esc",name:"closeSearchBar",exec:function(b){b.searchBox.hide()}}]),this.$searchBarKb=new C,this.$searchBarKb.bindKeys({"Ctrl-f|Command-f":function(b){var x=b.isReplace=!b.isReplace;b.replaceBox.style.display=x?"":"none",b.replaceOption.checked=!1,b.$syncOptions(),b.searchInput.focus()},"Ctrl-H|Command-Option-F":function(b){b.editor.getReadOnly()||(b.replaceOption.checked=!0,b.$syncOptions(),b.replaceInput.focus())},"Ctrl-G|Command-G":function(b){b.findNext()},"Ctrl-Shift-G|Command-Shift-G":function(b){b.findPrev()},esc:function(b){setTimeout(function(){b.hide()})},Return:function(b){b.activeInput==b.replaceInput&&b.replace(),b.findNext()},"Shift-Return":function(b){b.activeInput==b.replaceInput&&b.replace(),b.findPrev()},"Alt-Return":function(b){b.activeInput==b.replaceInput&&b.replaceAll(),b.findAll()},Tab:function(b){(b.activeInput==b.replaceInput?b.searchInput:b.replaceInput).focus()}}),this.$searchBarKb.addCommands([{name:"toggleRegexpMode",bindKey:{win:"Alt-R|Alt-/",mac:"Ctrl-Alt-R|Ctrl-Alt-/"},exec:function(b){b.regExpOption.checked=!b.regExpOption.checked,b.$syncOptions()}},{name:"toggleCaseSensitive",bindKey:{win:"Alt-C|Alt-I",mac:"Ctrl-Alt-R|Ctrl-Alt-I"},exec:function(b){b.caseSensitiveOption.checked=!b.caseSensitiveOption.checked,b.$syncOptions()}},{name:"toggleWholeWords",bindKey:{win:"Alt-B|Alt-W",mac:"Ctrl-Alt-B|Ctrl-Alt-W"},exec:function(b){b.wholeWordOption.checked=!b.wholeWordOption.checked,b.$syncOptions()}},{name:"toggleReplace",exec:function(b){b.replaceOption.checked=!b.replaceOption.checked,b.$syncOptions()}},{name:"searchInSelection",exec:function(b){b.searchOption.checked=!b.searchRange,b.setSearchRange(b.searchOption.checked&&b.editor.getSelectionRange()),b.$syncOptions()}}]),this.setSearchRange=function(b){(this.searchRange=b)?this.searchRangeMarker=this.editor.session.addMarker(b,"ace_active-line"):this.searchRangeMarker&&(this.editor.session.removeMarker(this.searchRangeMarker),this.searchRangeMarker=null)},this.$syncOptions=function(b){O.setCssClass(this.replaceOption,"checked",this.searchRange),O.setCssClass(this.searchOption,"checked",this.searchOption.checked),this.replaceOption.textContent=this.replaceOption.checked?"-":"+",O.setCssClass(this.regExpOption,"checked",this.regExpOption.checked),O.setCssClass(this.wholeWordOption,"checked",this.wholeWordOption.checked),O.setCssClass(this.caseSensitiveOption,"checked",this.caseSensitiveOption.checked);var x=this.editor.getReadOnly();this.replaceOption.style.display=x?"none":"",this.replaceBox.style.display=this.replaceOption.checked&&!x?"":"none",this.find(!1,!1,b)},this.highlight=function(b){this.editor.session.highlight(b||this.editor.$search.$options.re),this.editor.renderer.updateBackMarkers()},this.find=function(b,x,p){b=!this.editor.find(this.searchInput.value,{skipCurrent:b,backwards:x,wrap:!0,regExp:this.regExpOption.checked,caseSensitive:this.caseSensitiveOption.checked,wholeWord:this.wholeWordOption.checked,preventScroll:p,range:this.searchRange})&&this.searchInput.value,O.setCssClass(this.searchBox,"ace_nomatch",b),this.editor._emit("findSearchBox",{match:!b}),this.highlight(),this.updateCounter()},this.updateCounter=function(){var b=this.editor,x=b.$search.$options.re,p=0,l=0;if(x){var s,n,t=this.searchRange?b.session.getTextRange(this.searchRange):b.getValue(),i=b.session.doc.positionToIndex(b.selection.anchor);for(this.searchRange&&(i-=b.session.doc.positionToIndex(this.searchRange.start)),x.lastIndex=0;(n=x.exec(t))&&((s=n.index)<=i&&l++,!(999<++p))&&(n[0]||(x.lastIndex=s+=1,!(s>=t.length))););}this.searchCounter.textContent=l+" of "+(999<p?"999+":p)},this.findNext=function(){this.find(!0,!1)},this.findPrev=function(){this.find(!0,!0)},this.findAll=function(){var b=!this.editor.findAll(this.searchInput.value,{regExp:this.regExpOption.checked,caseSensitive:this.caseSensitiveOption.checked,wholeWord:this.wholeWordOption.checked})&&this.searchInput.value;O.setCssClass(this.searchBox,"ace_nomatch",b),this.editor._emit("findSearchBox",{match:!b}),this.highlight(),this.hide()},this.replace=function(){this.editor.getReadOnly()||this.editor.replace(this.replaceInput.value)},this.replaceAndFindNext=function(){this.editor.getReadOnly()||(this.editor.replace(this.replaceInput.value),this.findNext())},this.replaceAll=function(){this.editor.getReadOnly()||this.editor.replaceAll(this.replaceInput.value)},this.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()},this.show=function(b,x){this.active=!0,this.editor.on("changeSession",this.setSession),this.element.style.display="",this.replaceOption.checked=x,b&&(this.searchInput.value=b),this.searchInput.focus(),this.searchInput.select(),this.editor.keyBinding.addKeyboardHandler(this.$closeSearchBarKb),this.$syncOptions(!0)},this.isFocused=function(){var b=document.activeElement;return b==this.searchInput||b==this.replaceInput}}.call(Z.prototype),k.SearchBox=Z,k.Search=function(b,x){(b.searchBox||new Z(b)).show(b.session.getTextRange(),x)}}),ace.require(["ace/ext/searchbox"],function(X){ie&&(ie.exports=X)})},4091:function(ie,u,V){ie=V.nmd(ie),ace.define("ace/mode/json_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"],function(W,k,N){function Z(){this.$rules={start:[{token:"variable",regex:'["](?:(?:\\\\.)|(?:[^"\\\\]))*?["]\\s*(?=:)'},{token:"string",regex:'"',next:"string"},{token:"constant.numeric",regex:"0[xX][0-9a-fA-F]+\\b"},{token:"constant.numeric",regex:"[+-]?\\d+(?:(?:\\.\\d*)?(?:[eE][+-]?\\d+)?)?\\b"},{token:"constant.language.boolean",regex:"(?:true|false)\\b"},{token:"text",regex:"['](?:(?:\\\\.)|(?:[^'\\\\]))*?[']"},{token:"comment",regex:"\\/\\/.*$"},{token:"comment.start",regex:"\\/\\*",next:"comment"},{token:"paren.lparen",regex:"[[({]"},{token:"paren.rparen",regex:"[\\])}]"},{token:"punctuation.operator",regex:/[,]/},{token:"text",regex:"\\s+"}],string:[{token:"constant.language.escape",regex:/\\(?:x[0-9a-fA-F]{2}|u[0-9a-fA-F]{4}|["\\\/bfnrt])/},{token:"string",regex:'"|$',next:"start"},{defaultToken:"string"}],comment:[{token:"comment.end",regex:"\\*\\/",next:"start"},{defaultToken:"comment"}]}}var O=W("../lib/oop"),W=W("./text_highlight_rules").TextHighlightRules;O.inherits(Z,W),k.JsonHighlightRules=Z}),ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"],function(X,k,N){function Z(){}var O=X("../range").Range;(function(){this.checkOutdent=function(W,F){return!!/^\s+$/.test(W)&&/^\s*\}/.test(F)},this.autoOutdent=function(W,F){var L,C=W.getLine(F).match(/^(\s*\})/);return C&&(C=C[1].length,(L=W.findMatchingBracket({row:F,column:C}))&&L.row!=F)?(L=this.$getIndent(W.getLine(L.row)),void W.replace(new O(F,0,F,C-1),L)):0},this.$getIndent=function(W){return W.match(/^\s*/)[0]}}).call(Z.prototype),k.MatchingBraceOutdent=Z}),ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"],function(W,F,N){var Z=W("../../lib/oop"),O=W("../../range").Range,W=W("./fold_mode").FoldMode,F=F.FoldMode=function(L){L&&(this.foldingStartMarker=new RegExp(this.foldingStartMarker.source.replace(/\|[^|]*?$/,"|"+L.start)),this.foldingStopMarker=new RegExp(this.foldingStopMarker.source.replace(/\|[^|]*?$/,"|"+L.end)))};Z.inherits(F,W),function(){this.foldingStartMarker=/([\{\[\(])[^\}\]\)]*$|^\s*(\/\*)/,this.foldingStopMarker=/^[^\[\{\(]*([\}\]\)])|^[\s\*]*(\*\/)/,this.singleLineBlockCommentRe=/^\s*(\/\*).*\*\/\s*$/,this.tripleStarBlockCommentRe=/^\s*(\/\*\*\*).*\*\/\s*$/,this.startRegionRe=/^\s*(\/\*|\/\/)#?region\b/,this._getFoldWidgetBase=this.getFoldWidget,this.getFoldWidget=function(L,C,m){var b=L.getLine(m);return!this.singleLineBlockCommentRe.test(b)||this.startRegionRe.test(b)||this.tripleStarBlockCommentRe.test(b)?!(L=this._getFoldWidgetBase(L,C,m))&&this.startRegionRe.test(b)?"start":L:""},this.getFoldWidgetRange=function(L,C,m,b){var x,p,l,s=L.getLine(m);return this.startRegionRe.test(s)?this.getCommentRegionBlock(L,s,m):(p=s.match(this.foldingStartMarker))?(l=p.index,p[1]?this.openingBracketBlock(L,p[1],m,l):((x=L.getCommentFoldRange(m,l+p[0].length,1))&&!x.isMultiLine()&&(b?x=this.getSectionRange(L,m):C!="all"&&(x=null)),x)):C!=="markbegin"&&(p=s.match(this.foldingStopMarker))?(l=p.index+p[0].length,p[1]?this.closingBracketBlock(L,p[1],m,l):L.getCommentFoldRange(m,l,-1)):void 0},this.getSectionRange=function(L,C){for(var m=(s=L.getLine(C)).search(/\S/),b=C,x=s.length,p=C+=1,l=L.getLength();++C<l;){var s,n=(s=L.getLine(C)).search(/\S/);if(n!==-1){if(n<m)break;var t=this.getFoldWidgetRange(L,"all",C);if(t){if(t.start.row<=b)break;if(t.isMultiLine())C=t.end.row;else if(m==n)break}p=C}}return new O(b,x,p,L.getLine(p).length)},this.getCommentRegionBlock=function(L,C,m){for(var b=C.search(/\s*$/),x=L.getLength(),p=m,l=/^\s*(?:\/\*|\/\/|--)#?(end)?region\b/,s=1;++m<x;){C=L.getLine(m);var n=l.exec(C);if(n&&(n[1]?s--:s++,!s))break}if(p<m)return new O(p,b,m,C.length)}}.call(F.prototype)}),ace.define("ace/mode/json",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/json_highlight_rules","ace/mode/matching_brace_outdent","ace/mode/behaviour/cstyle","ace/mode/folding/cstyle","ace/worker/worker_client"],function(X,k,N){function Z(){this.HighlightRules=F,this.$outdent=new L,this.$behaviour=new C,this.foldingRules=new m}var O=X("../lib/oop"),W=X("./text").Mode,F=X("./json_highlight_rules").JsonHighlightRules,L=X("./matching_brace_outdent").MatchingBraceOutdent,C=X("./behaviour/cstyle").CstyleBehaviour,m=X("./folding/cstyle").FoldMode,b=X("../worker/worker_client").WorkerClient;O.inherits(Z,W),function(){this.lineCommentStart="//",this.blockComment={start:"/*",end:"*/"},this.getNextLineIndent=function(x,p,l){var s=this.$getIndent(p);return x=="start"&&p.match(/^.*[\{\(\[]\s*$/)&&(s+=l),s},this.checkOutdent=function(x,p,l){return this.$outdent.checkOutdent(p,l)},this.autoOutdent=function(x,p,l){this.$outdent.autoOutdent(p,l)},this.createWorker=function(x){var p=new b(["ace"],"ace/mode/json_worker","JsonWorker");return p.attachToDocument(x.getDocument()),p.on("annotate",function(l){x.setAnnotations(l.data)}),p.on("terminate",function(){x.clearAnnotations()}),p},this.$id="ace/mode/json"}.call(Z.prototype),k.Mode=Z}),ace.require(["ace/mode/json"],function(X){ie&&(ie.exports=X)})},8903:function(m,u,V){var X=V(5689),k=V(3969),N=V(5255),Z=V(4293),O=V(3508),W=V(3368),F=V(742),L=V(9394),C=V(3724),m=((m.exports=l).prototype.validate=function(o,c){var h;if(typeof o=="string"){if(!(h=this.getSchema(o)))throw new Error('no schema with key or ref "'+o+'"')}else o=this._addSchema(o),h=o.validate||this._compile(o);return o=h(c),h.$async!==!0&&(this.errors=h.errors),o},l.prototype.compile=function(o,c){return o=this._addSchema(o,void 0,c),o.validate||this._compile(o)},l.prototype.addSchema=function(o,c,h,A){if(Array.isArray(o))for(var v=0;v<o.length;v++)this.addSchema(o[v],void 0,h,A);else{var d=this._getId(o);if(d!==void 0&&typeof d!="string")throw new Error("schema id must be string");r(this,c=k.normalizeId(c||d)),this._schemas[c]=this._addSchema(o,h,A,!0)}return this},l.prototype.addMetaSchema=function(o,c,h){return this.addSchema(o,c,h,!0),this},l.prototype.validateSchema=function(o,c){var h=o.$schema;if(h!==void 0&&typeof h!="string")throw new Error("$schema must be a string");if(!(h=h||this._opts.defaultMeta||function(A){var v=A._opts.meta;return A._opts.defaultMeta=typeof v=="object"?A._getId(v)||v:A.getSchema(b)?b:void 0,A._opts.defaultMeta}(this)))return this.logger.warn("meta-schema not available"),!(this.errors=null);if(h=this.validate(h,o),!h&&c){if(o="schema is invalid: "+this.errorsText(),this._opts.validateSchema!="log")throw new Error(o);this.logger.error(o)}return h},l.prototype.getSchema=function(o){var c=s(this,o);switch(typeof c){case"object":return c.validate||this._compile(c);case"string":return this.getSchema(c);case"undefined":return function(h,A){var v=k.schema.call(h,{schema:{}},A);{var d,g,y;if(v)return d=v.schema,g=v.root,v=v.baseId,y=X.call(h,d,g,void 0,v),h._fragments[A]=new Z({ref:A,fragment:!0,schema:d,root:g,baseId:v,validate:y}),y}}(this,o)}},l.prototype.removeSchema=function(o){if(o instanceof RegExp)n(this,this._schemas,o),n(this,this._refs,o);else switch(typeof o){case"undefined":return n(this,this._schemas),n(this,this._refs),this._cache.clear(),this;case"string":var c=s(this,o);return c&&this._cache.del(c.cacheKey),delete this._schemas[o],delete this._refs[o],this;case"object":c=this._opts.serialize,c=c?c(o):o,c=(this._cache.del(c),this._getId(o)),c&&(c=k.normalizeId(c),delete this._schemas[c],delete this._refs[c])}return this},l.prototype.addFormat=function(o,c){return typeof c=="string"&&(c=new RegExp(c)),this._formats[o]=c,this},l.prototype.errorsText=function(o,c){if(!(o=o||this.errors))return"No errors";for(var h=(c=c||{}).separator===void 0?", ":c.separator,A=c.dataVar===void 0?"data":c.dataVar,v="",d=0;d<o.length;d++){var g=o[d];g&&(v+=A+g.dataPath+" "+g.message+h)}return v.slice(0,-h.length)},l.prototype._addSchema=function(o,y,h,A){if(typeof o!="object"&&typeof o!="boolean")throw new Error("schema should be object or boolean");var v=this._opts.serialize,v=v?v(o):o,d=this._cache.get(v);if(d)return d;A=A||this._opts.addUsedSchema!==!1,d=k.normalizeId(this._getId(o)),d&&A&&r(this,d);var g,y=this._opts.validateSchema!==!1&&!y;y&&!(g=d&&d==k.normalizeId(o.$schema))&&this.validateSchema(o,!0);var w=k.ids.call(this,o),w=new Z({id:d,schema:o,localRefs:w,cacheKey:v,meta:h});return d[0]!="#"&&A&&(this._refs[d]=w),this._cache.put(v,w),y&&g&&this.validateSchema(o,!0),w},l.prototype._compile=function(o,c){if(o.compiling)return(o.validate=v).schema=o.schema,v.errors=null,v.root=c||v,o.schema.$async===!0&&(v.$async=!0),v;var h,A;o.compiling=!0,o.meta&&(h=this._opts,this._opts=this._metaOpts);try{A=X.call(this,o.schema,c,o.localRefs)}catch(d){throw delete o.validate,d}finally{o.compiling=!1,o.meta&&(this._opts=h)}return o.validate=A,o.refs=A.refs,o.refVal=A.refVal,o.root=A.root,A;function v(){var d=o.validate,g=d.apply(this,arguments);return v.errors=d.errors,g}},l.prototype.compileAsync=V(9677),V(7931)),m=(l.prototype.addKeyword=m.add,l.prototype.getKeyword=m.get,l.prototype.removeKeyword=m.remove,l.prototype.validateKeyword=m.validate,V(5359)),b=(l.ValidationError=m.Validation,l.MissingRefError=m.MissingRef,l.$dataMetaSchema=L,"http://json-schema.org/draft-07/schema"),x=["removeAdditional","useDefaults","coerceTypes","strictDefaults"],p=["/properties"];function l(o){if(!(this instanceof l))return new l(o);o=this._opts=C.copy(o)||{};var I=this,c=I._opts.logger;if(c===!1)I.logger={log:a,warn:a,error:a};else{if(!(typeof(c=c===void 0?console:c)=="object"&&c.log&&c.warn&&c.error))throw new Error("logger must implement log, warn and error methods");I.logger=c}if(this._schemas={},this._refs={},this._fragments={},this._formats=W(o.format),this._cache=o.cache||new N,this._loadingSchemas={},this._compilations=[],this.RULES=F(),this._getId=function(_){switch(_.schemaId){case"auto":return e;case"id":return t;default:return i}}(o),o.loopRequired=o.loopRequired||1/0,o.errorDataPath=="property"&&(o._errorDataPathProperty=!0),o.serialize===void 0&&(o.serialize=O),this._metaOpts=function(_){for(var P=C.copy(_._opts),j=0;j<x.length;j++)delete P[x[j]];return P}(this),o.formats){var h,A=this;for(h in A._opts.formats){var v=A._opts.formats[h];A.addFormat(h,v)}}if(o.keywords){var d,g=this;for(d in g._opts.keywords){var y=g._opts.keywords[d];g.addKeyword(d,y)}}var w,I=this,T=(I._opts.$data&&(w=V(894),I.addMetaSchema(w,w.$id,!0)),I._opts.meta!==!1&&(w=V(6680),I._opts.$data&&(w=L(w,p)),I.addMetaSchema(w,b,!0),I._refs["http://json-schema.org/schema"]=b),typeof o.meta=="object"&&this.addMetaSchema(o.meta),o.nullable&&this.addKeyword("nullable",{metaSchema:{type:"boolean"}}),this),B=T._opts.schemas;if(B)if(Array.isArray(B))T.addSchema(B);else for(var E in B)T.addSchema(B[E],E)}function s(o,c){return c=k.normalizeId(c),o._schemas[c]||o._refs[c]||o._fragments[c]}function n(o,c,h){for(var A in c){var v=c[A];v.meta||h&&!h.test(A)||(o._cache.del(v.cacheKey),delete c[A])}}function t(o){return o.$id&&this.logger.warn("schema $id ignored",o.$id),o.id}function i(o){return o.id&&this.logger.warn("schema id ignored",o.id),o.$id}function e(o){if(o.$id&&o.id&&o.$id!=o.id)throw new Error("schema $id is different from id");return o.$id||o.id}function r(o,c){if(o._schemas[c]||o._refs[c])throw new Error('schema with key or id "'+c+'" already exists')}function a(){}},5255:function(ie){ie=ie.exports=function(){this._cache={}},ie.prototype.put=function(u,V){this._cache[u]=V},ie.prototype.get=function(u){return this._cache[u]},ie.prototype.del=function(u){delete this._cache[u]},ie.prototype.clear=function(){this._cache={}}},9677:function(ie,u,V){var X=V(5359).MissingRef;function k(N,Z,O){var W=this;if(typeof this._opts.loadSchema!="function")throw new Error("options.loadSchema should be a function");typeof Z=="function"&&(O=Z,Z=void 0);var F=L(N).then(function(){var C=W._addSchema(N,void 0,Z);return C.validate||function m(b){try{return W._compile(b)}catch(p){if(p instanceof X)return x(p);throw p}function x(p){var l=p.missingSchema;if(n(l))throw new Error("Schema "+l+" is loaded but "+p.missingRef+" cannot be resolved");return p=W._loadingSchemas[l],p||(p=W._loadingSchemas[l]=W._opts.loadSchema(l)).then(s,s),p.then(function(t){if(!n(l))return L(t).then(function(){n(l)||W.addSchema(t,l,void 0,Z)})}).then(function(){return m(b)});function s(){delete W._loadingSchemas[l]}function n(t){return W._refs[t]||W._schemas[t]}}}(C)});return O&&F.then(function(C){O(null,C)},O),F;function L(C){return C=C.$schema,C&&!W.getSchema(C)?k.call(W,{$ref:C},!0):Promise.resolve()}}ie.exports=k},5359:function(ie,u,V){var X=V(3969);function k(Z,O,W){this.message=W||k.message(Z,O),this.missingRef=X.url(Z,O),this.missingSchema=X.normalizeId(X.fullPath(this.missingRef))}function N(Z){return Z.prototype=Object.create(Error.prototype),Z.prototype.constructor=Z}ie.exports={Validation:N(function(Z){this.message="validation failed",this.errors=Z,this.ajv=this.validation=!0}),MissingRef:N(k)},k.message=function(Z,O){return"can't resolve reference "+O+" from id "+Z}},3368:function(ie,u,O){var X=O(3724),k=/^(\d\d\d\d)-(\d\d)-(\d\d)$/,N=[0,31,28,31,30,31,30,31,31,30,31,30,31],Z=/^(\d\d):(\d\d):(\d\d)(\.\d+)?(z|[+-]\d\d(?::?\d\d)?)?$/i,O=/^(?=.{1,253}\.?$)[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?(?:\.[a-z0-9](?:[-0-9a-z]{0,61}[0-9a-z])?)*\.?$/i,W=/^(?:[a-z][a-z0-9+\-.]*:)(?:\/?\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:]|%[0-9a-f]{2})*@)?(?:\[(?:(?:(?:(?:[0-9a-f]{1,4}:){6}|::(?:[0-9a-f]{1,4}:){5}|(?:[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){4}|(?:(?:[0-9a-f]{1,4}:){0,1}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){3}|(?:(?:[0-9a-f]{1,4}:){0,2}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){2}|(?:(?:[0-9a-f]{1,4}:){0,3}[0-9a-f]{1,4})?::[0-9a-f]{1,4}:|(?:(?:[0-9a-f]{1,4}:){0,4}[0-9a-f]{1,4})?::)(?:[0-9a-f]{1,4}:[0-9a-f]{1,4}|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?))|(?:(?:[0-9a-f]{1,4}:){0,5}[0-9a-f]{1,4})?::[0-9a-f]{1,4}|(?:(?:[0-9a-f]{1,4}:){0,6}[0-9a-f]{1,4})?::)|[Vv][0-9a-f]+\.[a-z0-9\-._~!$&'()*+,;=:]+)\]|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)|(?:[a-z0-9\-._~!$&'()*+,;=]|%[0-9a-f]{2})*)(?::\d*)?(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*|\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*)?|(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*)(?:\?(?:[a-z0-9\-._~!$&'()*+,;=:@/?]|%[0-9a-f]{2})*)?(?:#(?:[a-z0-9\-._~!$&'()*+,;=:@/?]|%[0-9a-f]{2})*)?$/i,F=/^(?:(?:[^\x00-\x20"'<>%\\^`{|}]|%[0-9a-f]{2})|\{[+#./;?&=,!@|]?(?:[a-z0-9_]|%[0-9a-f]{2})+(?::[1-9][0-9]{0,3}|\*)?(?:,(?:[a-z0-9_]|%[0-9a-f]{2})+(?::[1-9][0-9]{0,3}|\*)?)*\})*$/i,L=/^(?:(?:http[s\u017F]?|ftp):\/\/)(?:(?:[\0-\x08\x0E-\x1F!-\x9F\xA1-\u167F\u1681-\u1FFF\u200B-\u2027\u202A-\u202E\u2030-\u205E\u2060-\u2FFF\u3001-\uD7FF\uE000-\uFEFE\uFF00-\uFFFF]|[\uD800-\uDBFF][\uDC00-\uDFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF])+(?::(?:[\0-\x08\x0E-\x1F!-\x9F\xA1-\u167F\u1681-\u1FFF\u200B-\u2027\u202A-\u202E\u2030-\u205E\u2060-\u2FFF\u3001-\uD7FF\uE000-\uFEFE\uFF00-\uFFFF]|[\uD800-\uDBFF][\uDC00-\uDFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF])*)?@)?(?:(?!10(?:\.[0-9]{1,3}){3})(?!127(?:\.[0-9]{1,3}){3})(?!169\.254(?:\.[0-9]{1,3}){2})(?!192\.168(?:\.[0-9]{1,3}){2})(?!172\.(?:1[6-9]|2[0-9]|3[01])(?:\.[0-9]{1,3}){2})(?:[1-9][0-9]?|1[0-9][0-9]|2[01][0-9]|22[0-3])(?:\.(?:1?[0-9]{1,2}|2[0-4][0-9]|25[0-5])){2}(?:\.(?:[1-9][0-9]?|1[0-9][0-9]|2[0-4][0-9]|25[0-4]))|(?:(?:(?:[0-9a-z\xA1-\uD7FF\uE000-\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF])+-)*(?:[0-9a-z\xA1-\uD7FF\uE000-\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF])+)(?:\.(?:(?:[0-9a-z\xA1-\uD7FF\uE000-\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF])+-)*(?:[0-9a-z\xA1-\uD7FF\uE000-\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF])+)*(?:\.(?:(?:[a-z\xA1-\uD7FF\uE000-\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]){2,})))(?::[0-9]{2,5})?(?:\/(?:[\0-\x08\x0E-\x1F!-\x9F\xA1-\u167F\u1681-\u1FFF\u200B-\u2027\u202A-\u202E\u2030-\u205E\u2060-\u2FFF\u3001-\uD7FF\uE000-\uFEFE\uFF00-\uFFFF]|[\uD800-\uDBFF][\uDC00-\uDFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF])*)?$/i,C=/^(?:urn:uuid:)?[0-9a-f]{8}-(?:[0-9a-f]{4}-){3}[0-9a-f]{12}$/i,m=/^(?:\/(?:[^~/]|~0|~1)*)*$/,b=/^#(?:\/(?:[a-z0-9_\-.!$&'()*+,;:=@]|%[0-9a-f]{2}|~0|~1)*)*$/i,x=/^(?:0|[1-9][0-9]*)(?:#|(?:\/(?:[^~/]|~0|~1)*)*)$/;function p(r){return X.copy(p[r=r=="full"?"full":"fast"])}function l(c){var a,o,c=c.match(k);return!!c&&(a=+c[1],o=+c[2],c=+c[3],1<=o&&o<=12&&1<=c&&c<=(o!=2||(c=a)%4!=0||c%100==0&&c%400!=0?N[o]:29))}function s(A,a){var o,c,h,A=A.match(Z);return!!A&&(o=A[1],c=A[2],h=A[3],A=A[5],(o<=23&&c<=59&&h<=59||o==23&&c==59&&h==60)&&(!a||A))}(ie.exports=p).fast={date:/^\d\d\d\d-[0-1]\d-[0-3]\d$/,time:/^(?:[0-2]\d:[0-5]\d:[0-5]\d|23:59:60)(?:\.\d+)?(?:z|[+-]\d\d(?::?\d\d)?)?$/i,"date-time":/^\d\d\d\d-[0-1]\d-[0-3]\d[t\s](?:[0-2]\d:[0-5]\d:[0-5]\d|23:59:60)(?:\.\d+)?(?:z|[+-]\d\d(?::?\d\d)?)$/i,uri:/^(?:[a-z][a-z0-9+\-.]*:)(?:\/?\/)?[^\s]*$/i,"uri-reference":/^(?:(?:[a-z][a-z0-9+\-.]*:)?\/?\/)?(?:[^\\\s#][^\s#]*)?(?:#[^\\\s]*)?$/i,"uri-template":F,url:L,email:/^[a-z0-9.!#$%&'*+/=?^_`{|}~-]+@[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?(?:\.[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?)*$/i,hostname:O,ipv4:/^(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)$/,ipv6:/^\s*(?:(?:(?:[0-9a-f]{1,4}:){7}(?:[0-9a-f]{1,4}|:))|(?:(?:[0-9a-f]{1,4}:){6}(?::[0-9a-f]{1,4}|(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(?:(?:[0-9a-f]{1,4}:){5}(?:(?:(?::[0-9a-f]{1,4}){1,2})|:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(?:(?:[0-9a-f]{1,4}:){4}(?:(?:(?::[0-9a-f]{1,4}){1,3})|(?:(?::[0-9a-f]{1,4})?:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(?:(?:[0-9a-f]{1,4}:){3}(?:(?:(?::[0-9a-f]{1,4}){1,4})|(?:(?::[0-9a-f]{1,4}){0,2}:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(?:(?:[0-9a-f]{1,4}:){2}(?:(?:(?::[0-9a-f]{1,4}){1,5})|(?:(?::[0-9a-f]{1,4}){0,3}:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(?:(?:[0-9a-f]{1,4}:){1}(?:(?:(?::[0-9a-f]{1,4}){1,6})|(?:(?::[0-9a-f]{1,4}){0,4}:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(?::(?:(?:(?::[0-9a-f]{1,4}){1,7})|(?:(?::[0-9a-f]{1,4}){0,5}:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:)))(?:%.+)?\s*$/i,regex:e,uuid:C,"json-pointer":m,"json-pointer-uri-fragment":b,"relative-json-pointer":x},p.full={date:l,time:s,"date-time":function(r){return r=r.split(n),r.length==2&&l(r[0])&&s(r[1],!0)},uri:function(r){return t.test(r)&&W.test(r)},"uri-reference":/^(?:[a-z][a-z0-9+\-.]*:)?(?:\/?\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:]|%[0-9a-f]{2})*@)?(?:\[(?:(?:(?:(?:[0-9a-f]{1,4}:){6}|::(?:[0-9a-f]{1,4}:){5}|(?:[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){4}|(?:(?:[0-9a-f]{1,4}:){0,1}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){3}|(?:(?:[0-9a-f]{1,4}:){0,2}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){2}|(?:(?:[0-9a-f]{1,4}:){0,3}[0-9a-f]{1,4})?::[0-9a-f]{1,4}:|(?:(?:[0-9a-f]{1,4}:){0,4}[0-9a-f]{1,4})?::)(?:[0-9a-f]{1,4}:[0-9a-f]{1,4}|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?))|(?:(?:[0-9a-f]{1,4}:){0,5}[0-9a-f]{1,4})?::[0-9a-f]{1,4}|(?:(?:[0-9a-f]{1,4}:){0,6}[0-9a-f]{1,4})?::)|[Vv][0-9a-f]+\.[a-z0-9\-._~!$&'()*+,;=:]+)\]|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)|(?:[a-z0-9\-._~!$&'"()*+,;=]|%[0-9a-f]{2})*)(?::\d*)?(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*|\/(?:(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*)?|(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*)?(?:\?(?:[a-z0-9\-._~!$&'"()*+,;=:@/?]|%[0-9a-f]{2})*)?(?:#(?:[a-z0-9\-._~!$&'"()*+,;=:@/?]|%[0-9a-f]{2})*)?$/i,"uri-template":F,url:L,email:/^[a-z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[a-z0-9!#$%&'*+/=?^_`{|}~-]+)*@(?:[a-z0-9](?:[a-z0-9-]*[a-z0-9])?\.)+[a-z0-9](?:[a-z0-9-]*[a-z0-9])?$/i,hostname:O,ipv4:/^(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)$/,ipv6:/^\s*(?:(?:(?:[0-9a-f]{1,4}:){7}(?:[0-9a-f]{1,4}|:))|(?:(?:[0-9a-f]{1,4}:){6}(?::[0-9a-f]{1,4}|(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(?:(?:[0-9a-f]{1,4}:){5}(?:(?:(?::[0-9a-f]{1,4}){1,2})|:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(?:(?:[0-9a-f]{1,4}:){4}(?:(?:(?::[0-9a-f]{1,4}){1,3})|(?:(?::[0-9a-f]{1,4})?:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(?:(?:[0-9a-f]{1,4}:){3}(?:(?:(?::[0-9a-f]{1,4}){1,4})|(?:(?::[0-9a-f]{1,4}){0,2}:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(?:(?:[0-9a-f]{1,4}:){2}(?:(?:(?::[0-9a-f]{1,4}){1,5})|(?:(?::[0-9a-f]{1,4}){0,3}:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(?:(?:[0-9a-f]{1,4}:){1}(?:(?:(?::[0-9a-f]{1,4}){1,6})|(?:(?::[0-9a-f]{1,4}){0,4}:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(?::(?:(?:(?::[0-9a-f]{1,4}){1,7})|(?:(?::[0-9a-f]{1,4}){0,5}:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:)))(?:%.+)?\s*$/i,regex:e,uuid:C,"json-pointer":m,"json-pointer-uri-fragment":b,"relative-json-pointer":x};var n=/t|\s/i,t=/\/|:/,i=/[^\\]\\Z/;function e(r){if(i.test(r))return!1;try{return new RegExp(r),!0}catch{return!1}}},5689:function(ie,u,V){var X=V(3969),k=V(3724),N=V(5359),Z=V(3508),O=V(1869),W=k.ucs2length,F=V(2303),L=N.Validation;function C(n,t,i,e){var r=this,a=this._opts,o=[void 0],c={},h=[],A={},v=[],d={},g=[],y=(t=t||{schema:n,refVal:o,refs:c},function(G,f,S){var $=m.call(this,G,f,S);return 0<=$?{index:$,compiling:!0}:($=this._compilations.length,this._compilations[$]={schema:G,root:f,baseId:S},{index:$,compiling:!1})}.call(this,n,t,e)),w=this._compilations[y.index];if(y.compiling)return w.callValidate=_;var I=this._formats,T=this.RULES;try{var B=P(n,t,i,e),E=(w.validate=B,w.callValidate);return E&&(E.schema=B.schema,E.errors=null,E.refs=B.refs,E.refVal=B.refVal,E.root=B.root,E.$async=B.$async,a.sourceCode&&(E.source=B.source)),B}finally{(function(G,f,S){G=m.call(this,G,f,S),0<=G&&this._compilations.splice(G,1)}).call(this,n,t,e)}function _(){var G=w.validate,f=G.apply(this,arguments);return _.errors=G.errors,f}function P(G,f,S,$){var M=!f||f.schema==G;if(f.schema!=t.schema)return C.call(r,G,f,S,$);S=G.$async===!0,$=O({isTop:!0,schema:G,isRoot:M,baseId:$,root:f,schemaPath:"",errSchemaPath:"#",errorPath:'""',MissingRefError:N.MissingRef,RULES:T,validate:O,util:k,resolve:X,resolveRef:j,usePattern:Y,useDefault:R,useCustomRule:H,opts:a,formats:I,logger:r.logger,self:r}),$=s(o,p)+s(h,b)+s(v,x)+s(g,l)+$,a.processCode&&($=a.processCode($,G));try{var K=new Function("self","RULES","formats","root","refVal","defaults","customRules","equal","ucs2length","ValidationError",$)(r,T,I,t,o,v,g,F,W,L);o[0]=K}catch(Q){throw r.logger.error("Error compiling schema, function code:",$),Q}return K.schema=G,K.errors=null,K.refs=c,K.refVal=o,K.root=M?K:f,S&&(K.$async=!0),a.sourceCode===!0&&(K.source={code:$,patterns:h,defaults:v}),K}function j(G,f,Q){f=X.url(G,f);var $=c[f];if($!==void 0)return D(M=o[$],K="refVal["+$+"]");if(!Q&&t.refs&&($=t.refs[f],$!==void 0))return D(M=t.refVal[$],K=z(f,M));var M,K=z(f),Q=X.call(r,P,t,f);if(Q!==void 0||($=i&&i[f])&&(Q=X.inlineRef($,a.inlineRefs)?$:C.call(r,$,t,i,G)),Q!==void 0)return M=Q,$=c[$=f],o[$]=M,D(Q,K);delete c[f]}function z(G,f){var S=o.length;return o[S]=f,"refVal"+(c[G]=S)}function D(G,f){return typeof G=="object"||typeof G=="boolean"?{code:f,schema:G,inline:!0}:{code:f,$async:G&&!!G.$async}}function Y(G){var f=A[G];return f===void 0&&(f=A[G]=h.length,h[f]=G),"pattern"+f}function R(G){switch(typeof G){case"boolean":case"number":return""+G;case"string":return k.toQuotedString(G);case"object":var f,S;return G===null?"null":(f=Z(G),(S=d[f])===void 0&&(S=d[f]=v.length,v[S]=G),"default"+S)}}function H(G,f,S,$){if(r._opts.validateSchema!==!1){var K=G.definition.dependencies;if(K&&!K.every(function(Ae){return Object.prototype.hasOwnProperty.call(S,Ae)}))throw new Error("parent schema must have all required keywords: "+K.join(","));if(K=G.definition.validateSchema,K&&!K(f)){if(K="keyword schema is invalid: "+r.errorsText(K.errors),r._opts.validateSchema!="log")throw new Error(K);r.logger.error(K)}}var M,K=G.definition.compile,Q=G.definition.inline,te=G.definition.macro;if(K)M=K.call(r,f,S,$);else if(te)M=te.call(r,f,S,$),a.validateSchema!==!1&&r.validateSchema(M,!0);else if(Q)M=Q.call(r,$,G.keyword,f,S);else if(!(M=G.definition.validate))return;if(M===void 0)throw new Error('custom keyword "'+G.keyword+'"failed to compile');return K=g.length,{code:"customRule"+K,validate:g[K]=M}}}function m(n,t,i){for(var e=0;e<this._compilations.length;e++){var r=this._compilations[e];if(r.schema==n&&r.root==t&&r.baseId==i)return e}return-1}function b(n,t){return"var pattern"+n+" = new RegExp("+k.toQuotedString(t[n])+");"}function x(n){return"var default"+n+" = defaults["+n+"];"}function p(n,t){return t[n]===void 0?"":"var refVal"+n+" = refVal["+n+"];"}function l(n){return"var customRule"+n+" = customRules["+n+"];"}function s(n,t){if(!n.length)return"";for(var i="",e=0;e<n.length;e++)i+=t(e,n);return i}ie.exports=C},3969:function(ie,u,V){var X=V(7533),k=V(2303),N=V(3724),Z=V(4293),O=V(500);function W(t,i,e){var r,a,o,c=this._refs[e];if(typeof c=="string"){if(!this._refs[c])return W.call(this,t,i,c);c=this._refs[c]}return(c=c||this._schemas[e])instanceof Z?b(c.schema,this._opts.inlineRefs)?c.schema:c.validate||this._compile(c):((c=F.call(this,i,e))&&(r=c.schema,i=c.root,o=c.baseId),r instanceof Z?a=r.validate||t.call(this,r.schema,i,void 0,o):r!==void 0&&(a=b(r,this._opts.inlineRefs)?r:t.call(this,r,i,void 0,o)),a)}function F(t,i){var e=X.parse(i),r=p(e),a=x(this._getId(t.schema));if(Object.keys(t.schema).length===0||r!==a){var r=s(r),o=this._refs[r];if(typeof o=="string")return function(h,A,v){A=F.call(this,h,A);{var d,g;if(A)return d=A.schema,g=A.baseId,h=A.root,(A=this._getId(d))&&(g=n(g,A)),C.call(this,v,g,d,h)}}.call(this,t,o,e);if(o instanceof Z)o.validate||this._compile(o);else{if(!((o=this._schemas[r])instanceof Z))return;if(o.validate||this._compile(o),r==s(i))return{schema:o,root:t,baseId:a}}if(!(t=o).schema)return;a=x(this._getId(t.schema))}return C.call(this,e,a,t.schema,t)}(ie.exports=W).normalizeId=s,W.fullPath=x,W.url=n,W.ids=function(t){var i=s(this._getId(t)),e={"":i},r={"":x(i,!1)},a={},o=this;return O(t,{allKeys:!0},function(c,h,A,v,d,g,y){if(h!==""){var w=o._getId(c),I=e[v],v=r[v]+"/"+d;if(y!==void 0&&(v+="/"+(typeof y=="number"?y:N.escapeFragment(y))),typeof w=="string"){if(w=I=s(I?X.resolve(I,w):w),d=o._refs[w],(d=typeof d=="string"?o._refs[d]:d)&&d.schema){if(!k(c,d.schema))throw new Error('id "'+w+'" resolves to more than one schema')}else if(w!=s(v))if(w[0]=="#"){if(a[w]&&!k(c,a[w]))throw new Error('id "'+w+'" resolves to more than one schema');a[w]=c}else o._refs[w]=v}e[h]=I,r[h]=v}}),a},W.inlineRef=b,W.schema=F;var L=N.toHash(["properties","patternProperties","enum","dependencies","definitions"]);function C(t,i,e,r){if(t.fragment=t.fragment||"",t.fragment.slice(0,1)=="/"){for(var a=t.fragment.split("/"),o=1;o<a.length;o++){var c=a[o];if(c){if((e=e[c=N.unescapeFragment(c)])===void 0)break;L[c]||((c=this._getId(e))&&(i=n(i,c)),e.$ref&&(c=n(i,e.$ref),(c=F.call(this,r,c))&&(e=c.schema,r=c.root,i=c.baseId)))}}return e!==void 0&&e!==r.schema?{schema:e,root:r,baseId:i}:void 0}}var m=N.toHash(["type","format","pattern","maxLength","minLength","maxProperties","minProperties","maxItems","minItems","maximum","minimum","uniqueItems","multipleOf","required","enum"]);function b(t,i){return i!==!1&&(i===void 0||i===!0?function e(r){var a;if(Array.isArray(r)){for(var o=0;o<r.length;o++)if(typeof(a=r[o])=="object"&&!e(a))return!1}else for(var c in r)if(c=="$ref"||typeof(a=r[c])=="object"&&!e(a))return!1;return!0}(t):i?function e(r){var a,o=0;if(Array.isArray(r)){for(var c=0;c<r.length;c++)if(typeof(a=r[c])=="object"&&(o+=e(a)),o==1/0)return 1/0}else for(var h in r){if(h=="$ref")return 1/0;if(m[h])o++;else if(typeof(a=r[h])=="object"&&(o+=e(a)+1),o==1/0)return 1/0}return o}(t)<=i:void 0)}function x(t,i){return i!==!1&&(t=s(t)),p(X.parse(t))}function p(t){return X.serialize(t).split("#")[0]+"#"}var l=/#\/?$/;function s(t){return t?t.replace(l,""):""}function n(t,i){return i=s(i),X.resolve(t,i)}},742:function(ie,u,V){var X=V(9646),k=V(3724).toHash;ie.exports=function(){var N=[{type:"number",rules:[{maximum:["exclusiveMaximum"]},{minimum:["exclusiveMinimum"]},"multipleOf","format"]},{type:"string",rules:["maxLength","minLength","pattern","format"]},{type:"array",rules:["maxItems","minItems","items","contains","uniqueItems"]},{type:"object",rules:["maxProperties","minProperties","required","dependencies","propertyNames",{properties:["additionalProperties","patternProperties"]}]},{rules:["$ref","const","enum","not","anyOf","oneOf","allOf","if"]}],Z=["type","$comment"];return N.all=k(Z),N.types=k(["number","integer","string","array","object","boolean","null"]),N.forEach(function(O){O.rules=O.rules.map(function(W){var F,L;return typeof W=="object"&&(L=W[F=Object.keys(W)[0]],W=F,L.forEach(function(C){Z.push(C),N.all[C]=!0})),Z.push(W),N.all[W]={keyword:W,code:X[W],implements:L}}),N.all.$comment={keyword:"$comment",code:X.$comment},O.type&&(N.types[O.type]=O)}),N.keywords=k(Z.concat(["$schema","$id","id","$data","$async","title","description","default","definitions","examples","readOnly","writeOnly","contentMediaType","contentEncoding","additionalItems","then","else"])),N.custom={},N}},4293:function(ie,u,V){var X=V(3724);ie.exports=function(k){X.copy(k,this)}},6887:function(ie){ie.exports=function(u){for(var V,X=0,k=u.length,N=0;N<k;)X++,55296<=(V=u.charCodeAt(N++))&&V<=56319&&N<k&&(64512&(V=u.charCodeAt(N)))==56320&&N++;return X}},3724:function(ie,u,V){function X(l,s,n,t){var i=t?" !== ":" === ",e=t?" || ":" && ",r=t?"!":"",a=t?"":"!";switch(l){case"null":return s+i+"null";case"array":return r+"Array.isArray("+s+")";case"object":return"("+r+s+e+"typeof "+s+i+'"object"'+e+a+"Array.isArray("+s+"))";case"integer":return"(typeof "+s+i+'"number"'+e+a+"("+s+" % 1)"+e+s+i+s+(n?e+r+"isFinite("+s+")":"")+")";case"number":return"(typeof "+s+i+'"'+l+'"'+(n?e+r+"isFinite("+s+")":"")+")";default:return"typeof "+s+i+'"'+l+'"'}}ie.exports={copy:function(l,s){for(var n in s=s||{},l)s[n]=l[n];return s},checkDataType:X,checkDataTypes:function(l,s,n){{if(l.length===1)return X(l[0],s,n,!0);var t,i="",l=N(l);for(t in l.array&&l.object&&(i=l.null?"(":"(!"+s+" || ",i+="typeof "+s+' !== "object")',delete l.null,delete l.array,delete l.object),l.number&&delete l.integer,l)i+=(i?" && ":"")+X(t,s,n,!0);return i}},coerceToTypes:function(l,s){{if(!Array.isArray(s))return k[s]?[s]:l==="array"&&s==="array"?["array"]:void 0;for(var n=[],t=0;t<s.length;t++){var i=s[t];(k[i]||l==="array"&&i==="array")&&(n[n.length]=i)}return n.length?n:void 0}},toHash:N,getProperty:W,escapeQuotes:F,equal:V(2303),ucs2length:V(6887),varOccurences:function(l,s){return s+="[^0-9]",l=l.match(new RegExp(s,"g")),l?l.length:0},varReplace:function(l,s,n){return s+="([^0-9])",n=n.replace(/\$/g,"$$$$"),l.replace(new RegExp(s,"g"),n+"$1")},schemaHasRules:function(l,s){if(typeof l=="boolean")return!l;for(var n in l)if(s[n])return!0},schemaHasRulesExcept:function(l,s,n){if(typeof l=="boolean")return!l&&n!="not";for(var t in l)if(t!=n&&s[t])return!0},schemaUnknownRules:function(l,s){if(typeof l!="boolean"){for(var n in l)if(!s[n])return n}},toQuotedString:L,getPathExpr:function(l,s,n,t){return b(l,n?"'/' + "+s+(t?"":".replace(/~/g, '~0').replace(/\\//g, '~1')"):t?"'[' + "+s+" + ']'":"'[\\'' + "+s+" + '\\']'")},getPath:function(l,s,n){return n=L(n?"/"+x(s):W(s)),b(l,n)},getData:function(l,s,n){var t,i,e;if(l==="")return"rootData";if(l[0]=="/"){if(!C.test(l))throw new Error("Invalid JSON-pointer: "+l);t=l,i="rootData"}else{if(!(e=l.match(m)))throw new Error("Invalid JSON-pointer: "+l);if(l=+e[1],(t=e[2])=="#"){if(s<=l)throw new Error("Cannot access property/index "+l+" levels up, current level is "+s);return n[s-l]}if(s<l)throw new Error("Cannot access data "+l+" levels up, current level is "+s);if(i="data"+(s-l||""),!t)return i}for(var r=i,a=t.split("/"),o=0;o<a.length;o++){var c=a[o];c&&(i+=W(p(c)),r+=" && "+i)}return r},unescapeFragment:function(l){return p(decodeURIComponent(l))},unescapeJsonPointer:p,escapeFragment:function(l){return encodeURIComponent(x(l))},escapeJsonPointer:x};var k=N(["string","number","integer","boolean","null"]);function N(l){for(var s={},n=0;n<l.length;n++)s[l[n]]=!0;return s}var Z=/^[a-z$_][a-z$_0-9]*$/i,O=/'|\\/g;function W(l){return typeof l=="number"?"["+l+"]":Z.test(l)?"."+l:"['"+F(l)+"']"}function F(l){return l.replace(O,"\\$&").replace(/\n/g,"\\n").replace(/\r/g,"\\r").replace(/\f/g,"\\f").replace(/\t/g,"\\t")}function L(l){return"'"+F(l)+"'"}var C=/^\/(?:[^~]|~0|~1)*$/,m=/^([0-9]+)(#|\/(?:[^~]|~0|~1)*)?$/;function b(l,s){return l=='""'?s:(l+" + "+s).replace(/([^\\])' \+ '/g,"$1")}function x(l){return l.replace(/~/g,"~0").replace(/\//g,"~1")}function p(l){return l.replace(/~1/g,"/").replace(/~0/g,"~")}},9394:function(ie){var u=["multipleOf","maximum","exclusiveMaximum","minimum","exclusiveMinimum","maxLength","minLength","pattern","additionalItems","maxItems","minItems","uniqueItems","maxProperties","minProperties","required","additionalProperties","enum","format","const"];ie.exports=function(V,X){for(var k=0;k<X.length;k++){V=JSON.parse(JSON.stringify(V));for(var N=X[k].split("/"),Z=V,O=1;O<N.length;O++)Z=Z[N[O]];for(O=0;O<u.length;O++){var W=u[O],F=Z[W];F&&(Z[W]={anyOf:[F,{$ref:"https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#"}]})}}return V}},5868:function(ie,u,V){V=V(6680),ie.exports={$id:"https://github.com/ajv-validator/ajv/blob/master/lib/definition_schema.js",definitions:{simpleTypes:V.definitions.simpleTypes},type:"object",dependencies:{schema:["validate"],$data:["validate"],statements:["inline"],valid:{not:{required:["macro"]}}},properties:{type:V.properties.type,schema:{type:"boolean"},statements:{type:"boolean"},dependencies:{type:"array",items:{type:"string"}},metaSchema:{type:"object"},modifying:{type:"boolean"},valid:{type:"boolean"},$data:{type:"boolean"},async:{type:"boolean"},errors:{anyOf:[{type:"boolean"},{const:"full"}]}}}},1796:function(ie){ie.exports=function(u,V,X){var k,N,Z,O,W,F=" ",L=u.level,C=u.dataLevel,m=u.schema[V],b=u.schemaPath+u.util.getProperty(V),x=u.errSchemaPath+"/"+V,p=!u.opts.allErrors,l="data"+(C||""),s=u.opts.$data&&m&&m.$data,n=s?(F+=" var schema"+L+" = "+u.util.getData(m.$data,C,u.dataPathArr)+"; ","schema"+L):m,t=V=="maximum",i=t?"exclusiveMaximum":"exclusiveMinimum",e=u.schema[i],r=u.opts.$data&&e&&e.$data,a=t?"<":">",o=t?">":"<",c=void 0;if(!s&&typeof m!="number"&&m!==void 0)throw new Error(V+" must be number");if(!r&&e!==void 0&&typeof e!="number"&&typeof e!="boolean")throw new Error(i+" must be number or boolean");r?(C=u.util.getData(e.$data,C,u.dataPathArr),Z="exclIsNumber"+L,O="' + "+(W="op"+L)+" + '",c=i,(h=h||[]).push(F=F+(" var schemaExcl"+L+" = "+C+"; ")+(" var "+(k="exclusive"+L)+"; var "+(N="exclType"+L)+" = typeof "+(C="schemaExcl"+L)+"; if ("+N+" != 'boolean' && "+N+" != 'undefined' && "+N+" != 'number') { ")),F="",u.createErrors!==!1?(F+=" { keyword: '"+(c||"_exclusiveLimit")+"' , dataPath: (dataPath || '') + "+u.errorPath+" , schemaPath: "+u.util.toQuotedString(x)+" , params: {} ",u.opts.messages!==!1&&(F+=" , message: '"+i+" should be boolean' "),u.opts.verbose&&(F+=" , schema: validate.schema"+b+" , parentSchema: validate.schema"+u.schemaPath+" , data: "+l+" "),F+=" } "):F+=" {} ",A=F,F=h.pop(),!u.compositeRule&&p?u.async?F+=" throw new ValidationError(["+A+"]); ":F+=" validate.errors = ["+A+"]; return false; ":F+=" var err = "+A+";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",F+=" } else if ( ",s&&(F+=" ("+n+" !== undefined && typeof "+n+" != 'number') || "),F+=" "+N+" == 'number' ? ( ("+k+" = "+n+" === undefined || "+C+" "+a+"= "+n+") ? "+l+" "+o+"= "+C+" : "+l+" "+o+" "+n+" ) : ( ("+k+" = "+C+" === true) ? "+l+" "+o+"= "+n+" : "+l+" "+o+" "+n+" ) || "+l+" !== "+l+") { var op"+L+" = "+k+" ? '"+a+"' : '"+a+"='; ",m===void 0&&(x=u.errSchemaPath+"/"+(c=i),n=C,s=r)):(O=a,(Z=typeof e=="number")&&s?(W="'"+O+"'",F+=" if ( ",s&&(F+=" ("+n+" !== undefined && typeof "+n+" != 'number') || "),F+=" ( "+n+" === undefined || "+e+" "+a+"= "+n+" ? "+l+" "+o+"= "+e+" : "+l+" "+o+" "+n+" ) || "+l+" !== "+l+") { "):(Z&&m===void 0?(k=!0,x=u.errSchemaPath+"/"+(c=i),n=e,o+="="):(Z&&(n=Math[t?"min":"max"](e,m)),e===(!Z||n)?(k=!0,x=u.errSchemaPath+"/"+(c=i),o+="="):(k=!1,O+="=")),W="'"+O+"'",F+=" if ( ",s&&(F+=" ("+n+" !== undefined && typeof "+n+" != 'number') || "),F+=" "+l+" "+o+" "+n+" || "+l+" !== "+l+") { ")),c=c||V,(h=h||[]).push(F),F="",u.createErrors!==!1?(F+=" { keyword: '"+(c||"_limit")+"' , dataPath: (dataPath || '') + "+u.errorPath+" , schemaPath: "+u.util.toQuotedString(x)+" , params: { comparison: "+W+", limit: "+n+", exclusive: "+k+" } ",u.opts.messages!==!1&&(F=F+" , message: 'should be "+O+" "+(s?"' + "+n:n+"'")),u.opts.verbose&&(F=(F+=" , schema:  ")+(s?"validate.schema"+b:""+m)+"         , parentSchema: validate.schema"+u.schemaPath+" , data: "+l+" "),F+=" } "):F+=" {} ";var h,A=F;return F=h.pop(),!u.compositeRule&&p?u.async?F+=" throw new ValidationError(["+A+"]); ":F+=" validate.errors = ["+A+"]; return false; ":F+=" var err = "+A+";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",F+=" } ",p&&(F+=" else { "),F}},2407:function(ie){ie.exports=function(u,V,X){var k,N=" ",Z=u.level,b=u.dataLevel,O=u.schema[V],W=u.schemaPath+u.util.getProperty(V),F=u.errSchemaPath+"/"+V,L=!u.opts.allErrors,C="data"+(b||""),m=u.opts.$data&&O&&O.$data,b=m?(N+=" var schema"+Z+" = "+u.util.getData(O.$data,b,u.dataPathArr)+"; ","schema"+Z):O;if(m||typeof O=="number")return N+="if ( ",m&&(N+=" ("+b+" !== undefined && typeof "+b+" != 'number') || "),(Z=[]).push(N+=" "+C+".length "+((k=V)=="maxItems"?">":"<")+" "+b+") { "),N="",u.createErrors!==!1?(N+=" { keyword: '"+(k||"_limitItems")+"' , dataPath: (dataPath || '') + "+u.errorPath+" , schemaPath: "+u.util.toQuotedString(F)+" , params: { limit: "+b+" } ",u.opts.messages!==!1&&(N=(N=(N+=" , message: 'should NOT have ")+(V=="maxItems"?"more":"fewer")+" than ")+(m?"' + "+b+" + '":""+O)+" items' "),u.opts.verbose&&(N=(N+=" , schema:  ")+(m?"validate.schema"+W:""+O)+"         , parentSchema: validate.schema"+u.schemaPath+" , data: "+C+" "),N+=" } "):N+=" {} ",k=N,N=Z.pop(),!u.compositeRule&&L?u.async?N+=" throw new ValidationError(["+k+"]); ":N+=" validate.errors = ["+k+"]; return false; ":N+=" var err = "+k+";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",N+="} ",L&&(N+=" else { "),N;throw new Error(V+" must be number")}},1250:function(ie){ie.exports=function(u,V,X){var k,N=" ",Z=u.level,b=u.dataLevel,O=u.schema[V],W=u.schemaPath+u.util.getProperty(V),F=u.errSchemaPath+"/"+V,L=!u.opts.allErrors,C="data"+(b||""),m=u.opts.$data&&O&&O.$data,b=m?(N+=" var schema"+Z+" = "+u.util.getData(O.$data,b,u.dataPathArr)+"; ","schema"+Z):O;if(m||typeof O=="number")return N+="if ( ",m&&(N+=" ("+b+" !== undefined && typeof "+b+" != 'number') || "),u.opts.unicode===!1?N+=" "+C+".length ":N+=" ucs2length("+C+") ",(Z=[]).push(N+=" "+((k=V)=="maxLength"?">":"<")+" "+b+") { "),N="",u.createErrors!==!1?(N+=" { keyword: '"+(k||"_limitLength")+"' , dataPath: (dataPath || '') + "+u.errorPath+" , schemaPath: "+u.util.toQuotedString(F)+" , params: { limit: "+b+" } ",u.opts.messages!==!1&&(N=(N=(N+=" , message: 'should NOT be ")+(V=="maxLength"?"longer":"shorter")+" than ")+(m?"' + "+b+" + '":""+O)+" characters' "),u.opts.verbose&&(N=(N+=" , schema:  ")+(m?"validate.schema"+W:""+O)+"         , parentSchema: validate.schema"+u.schemaPath+" , data: "+C+" "),N+=" } "):N+=" {} ",k=N,N=Z.pop(),!u.compositeRule&&L?u.async?N+=" throw new ValidationError(["+k+"]); ":N+=" validate.errors = ["+k+"]; return false; ":N+=" var err = "+k+";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",N+="} ",L&&(N+=" else { "),N;throw new Error(V+" must be number")}},2596:function(ie){ie.exports=function(u,V,X){var k,N=" ",Z=u.level,b=u.dataLevel,O=u.schema[V],W=u.schemaPath+u.util.getProperty(V),F=u.errSchemaPath+"/"+V,L=!u.opts.allErrors,C="data"+(b||""),m=u.opts.$data&&O&&O.$data,b=m?(N+=" var schema"+Z+" = "+u.util.getData(O.$data,b,u.dataPathArr)+"; ","schema"+Z):O;if(m||typeof O=="number")return N+="if ( ",m&&(N+=" ("+b+" !== undefined && typeof "+b+" != 'number') || "),(Z=[]).push(N+=" Object.keys("+C+").length "+((k=V)=="maxProperties"?">":"<")+" "+b+") { "),N="",u.createErrors!==!1?(N+=" { keyword: '"+(k||"_limitProperties")+"' , dataPath: (dataPath || '') + "+u.errorPath+" , schemaPath: "+u.util.toQuotedString(F)+" , params: { limit: "+b+" } ",u.opts.messages!==!1&&(N=(N=(N+=" , message: 'should NOT have ")+(V=="maxProperties"?"more":"fewer")+" than ")+(m?"' + "+b+" + '":""+O)+" properties' "),u.opts.verbose&&(N=(N+=" , schema:  ")+(m?"validate.schema"+W:""+O)+"         , parentSchema: validate.schema"+u.schemaPath+" , data: "+C+" "),N+=" } "):N+=" {} ",k=N,N=Z.pop(),!u.compositeRule&&L?u.async?N+=" throw new ValidationError(["+k+"]); ":N+=" validate.errors = ["+k+"]; return false; ":N+=" var err = "+k+";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",N+="} ",L&&(N+=" else { "),N;throw new Error(V+" must be number")}},9486:function(ie){ie.exports=function(u,V,X){var k=" ",N=u.schema[V],Z=u.schemaPath+u.util.getProperty(V),O=u.errSchemaPath+"/"+V,W=!u.opts.allErrors,F=u.util.copy(u),L="",C=(F.level++,"valid"+F.level),m=F.baseId,b=!0,x=N;if(x)for(var p,l=-1,s=x.length-1;l<s;)p=x[l+=1],(u.opts.strictKeywords?typeof p=="object"&&0<Object.keys(p).length||p===!1:u.util.schemaHasRules(p,u.RULES.all))&&(b=!1,F.schema=p,F.schemaPath=Z+"["+l+"]",F.errSchemaPath=O+"/"+l,k+="  "+u.validate(F)+" ",F.baseId=m,W&&(k+=" if ("+C+") { ",L+="}"));return W&&(k+=b?" if (true) { ":" "+L.slice(0,-1)+" "),k}},5347:function(ie){ie.exports=function(u,W,X){var k=" ",C=u.level,F=u.dataLevel,N=u.schema[W],Z=u.schemaPath+u.util.getProperty(W),O=u.errSchemaPath+"/"+W,W=!u.opts.allErrors,F="data"+(F||""),L="valid"+C,C="errs__"+C,m=u.util.copy(u),b="",x=(m.level++,"valid"+m.level);if(N.every(function(e){return u.opts.strictKeywords?typeof e=="object"&&0<Object.keys(e).length||e===!1:u.util.schemaHasRules(e,u.RULES.all)})){var p=m.baseId,l=(k+=" var "+C+" = errors; var "+L+" = false;  ",u.compositeRule),s=(u.compositeRule=m.compositeRule=!0,N);if(s)for(var n,t=-1,i=s.length-1;t<i;)n=s[t+=1],m.schema=n,m.schemaPath=Z+"["+t+"]",m.errSchemaPath=O+"/"+t,k+="  "+u.validate(m)+" ",m.baseId=p,k+=" "+L+" = "+L+" || "+x+"; if (!"+L+") { ",b+="}";u.compositeRule=m.compositeRule=l,k+=" "+b+" if (!"+L+") {   var err =   ",u.createErrors!==!1?(k+=" { keyword: 'anyOf' , dataPath: (dataPath || '') + "+u.errorPath+" , schemaPath: "+u.util.toQuotedString(O)+" , params: {} ",u.opts.messages!==!1&&(k+=" , message: 'should match some schema in anyOf' "),u.opts.verbose&&(k+=" , schema: validate.schema"+Z+" , parentSchema: validate.schema"+u.schemaPath+" , data: "+F+" "),k+=" } "):k+=" {} ",k+=";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",!u.compositeRule&&W&&(u.async?k+=" throw new ValidationError(vErrors); ":k+=" validate.errors = vErrors; return false; "),k+=" } else {  errors = "+C+"; if (vErrors !== null) { if ("+C+") vErrors.length = "+C+"; else vErrors = null; } ",u.opts.allErrors&&(k+=" } ")}else W&&(k+=" if (true) { ");return k}},923:function(ie){ie.exports=function(u,N,X){var k=" ",Z=u.schema[N],N=u.errSchemaPath+"/"+N,Z=(u.opts.allErrors,u.util.toQuotedString(Z));return u.opts.$comment===!0?k+=" console.log("+Z+");":typeof u.opts.$comment=="function"&&(k+=" self._opts.$comment("+Z+", "+u.util.toQuotedString(N)+", validate.root.schema);"),k}},2617:function(ie){ie.exports=function(u,Z,X){var b=" ",k=u.level,m=u.dataLevel,C=u.schema[Z],N=u.schemaPath+u.util.getProperty(Z),Z=u.errSchemaPath+"/"+Z,O=!u.opts.allErrors,W="data"+(m||""),F="valid"+k,L=u.opts.$data&&C&&C.$data,C=(L&&(b+=" var schema"+k+" = "+u.util.getData(C.$data,m,u.dataPathArr)+"; "),L||(b+=" var schema"+k+" = validate.schema"+N+";"),[]),m=(C.push(b+="var "+F+" = equal("+W+", schema"+k+"); if (!"+F+") {   "),b="",u.createErrors!==!1?(b+=" { keyword: 'const' , dataPath: (dataPath || '') + "+u.errorPath+" , schemaPath: "+u.util.toQuotedString(Z)+" , params: { allowedValue: schema"+k+" } ",u.opts.messages!==!1&&(b+=" , message: 'should be equal to constant' "),u.opts.verbose&&(b+=" , schema: validate.schema"+N+" , parentSchema: validate.schema"+u.schemaPath+" , data: "+W+" "),b+=" } "):b+=" {} ",b),b=C.pop();return!u.compositeRule&&O?u.async?b+=" throw new ValidationError(["+m+"]); ":b+=" validate.errors = ["+m+"]; return false; ":b+=" var err = "+m+";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",b+=" }",O&&(b+=" else { "),b}},2119:function(ie){ie.exports=function(u,Z,X){var n=" ",l=u.level,W=u.dataLevel,k=u.schema[Z],N=u.schemaPath+u.util.getProperty(Z),Z=u.errSchemaPath+"/"+Z,O=!u.opts.allErrors,W="data"+(W||""),F="valid"+l,L="errs__"+l,C=u.util.copy(u),m=(C.level++,"valid"+C.level),l="i"+l,b=C.dataLevel=u.dataLevel+1,x="data"+b,s=u.baseId,p=u.opts.strictKeywords?typeof k=="object"&&0<Object.keys(k).length||k===!1:u.util.schemaHasRules(k,u.RULES.all),l=(n+="var "+L+" = errors;var "+F+";",p?(F=u.compositeRule,u.compositeRule=C.compositeRule=!0,C.schema=k,C.schemaPath=N,C.errSchemaPath=Z,n+=" var "+m+" = false; for (var "+l+" = 0; "+l+" < "+W+".length; "+l+"++) { ",C.errorPath=u.util.getPathExpr(u.errorPath,l,u.opts.jsonPointers,!0),k=W+"["+l+"]",C.dataPathArr[b]=l,b=u.validate(C),C.baseId=s,u.util.varOccurences(b,x)<2?n+=" "+u.util.varReplace(b,x,k)+" ":n+=" var "+x+" = "+k+"; "+b+" ",n+=" if ("+m+") break; }  ",u.compositeRule=C.compositeRule=F,n+="  if (!"+m+") {"):n+=" if ("+W+".length == 0) {",[]),s=(l.push(n),n="",u.createErrors!==!1?(n+=" { keyword: 'contains' , dataPath: (dataPath || '') + "+u.errorPath+" , schemaPath: "+u.util.toQuotedString(Z)+" , params: {} ",u.opts.messages!==!1&&(n+=" , message: 'should contain a valid item' "),u.opts.verbose&&(n+=" , schema: validate.schema"+N+" , parentSchema: validate.schema"+u.schemaPath+" , data: "+W+" "),n+=" } "):n+=" {} ",n),n=l.pop();return!u.compositeRule&&O?u.async?n+=" throw new ValidationError(["+s+"]); ":n+=" validate.errors = ["+s+"]; return false; ":n+=" var err = "+s+";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",n+=" } else { ",p&&(n+="  errors = "+L+"; if (vErrors !== null) { if ("+L+") vErrors.length = "+L+"; else vErrors = null; } "),u.opts.allErrors&&(n+=" } "),n}},1793:function(ie){ie.exports=function(u,v,X){var k,N,Z,O=" ",W=u.level,F=u.dataLevel,d=u.schema[v],L=u.schemaPath+u.util.getProperty(v),C=u.errSchemaPath+"/"+v,m=!u.opts.allErrors,b="data"+(F||""),x="valid"+W,p="errs__"+W,l=u.opts.$data&&d&&d.$data,s=l?(O+=" var schema"+W+" = "+u.util.getData(d.$data,F,u.dataPathArr)+"; ","schema"+W):d,n="definition"+W,t=this.definition,i="";if(l&&t.$data){var e="keywordValidate"+W,r=t.validateSchema;O+=" var "+n+" = RULES.custom['"+v+"'].definition; var "+e+" = "+n+".validate;"}else{if(!(h=u.useCustomRule(this,d,u.schema,u)))return;s="validate.schema"+L,e=h.code,k=t.compile,N=t.inline,Z=t.macro}var a,o,c,h,A,v=e+".errors",d="i"+W,g="ruleErr"+W,y=t.async;if(y&&!u.async)throw new Error("async keyword in sync schema");return N||Z||(O+=v+" = null;"),O+="var "+p+" = errors;var "+x+";",l&&t.$data&&(i+="}",O+=" if ("+s+" === undefined) { "+x+" = true; } else { ",r&&(i+="}",O+=" "+x+" = "+n+".validateSchema("+s+"); if ("+x+") { ")),N?t.statements?O+=" "+h.validate+" ":O+=" "+x+" = "+h.validate+"; ":Z?(i="",(l=u.util.copy(u)).level++,a="valid"+l.level,l.schema=h.validate,l.schemaPath="",r=u.compositeRule,u.compositeRule=l.compositeRule=!0,n=u.validate(l).replace(/validate\.schema/g,e),u.compositeRule=l.compositeRule=r,O+=" "+n):((A=A||[]).push(O),O="",O+="  "+e+".call( ",u.opts.passContext?O+="this":O+="self",k||t.schema===!1?O+=" , "+b+" ":O+=" , "+s+" , "+b+" , validate.schema"+u.schemaPath+" ",O+=" , (dataPath || '')",u.errorPath!='""'&&(O+=" + "+u.errorPath),h=O+=" , "+(o=F?"data"+(F-1||""):"parentData")+" , "+(c=F?u.dataPathArr[F]:"parentDataProperty")+" , rootData )  ",O=A.pop(),t.errors===!1?(O+=" "+x+" = ",y&&(O+="await "),O+=h+"; "):O+=y?" var "+(v="customErrors"+W)+" = null; try { "+x+" = await "+h+"; } catch (e) { "+x+" = false; if (e instanceof ValidationError) "+v+" = e.errors; else throw e; } ":" "+v+" = null; "+x+" = "+h+"; "),t.modifying&&(O+=" if ("+o+") "+b+" = "+o+"["+c+"];"),O+=""+i,t.valid?m&&(O+=" if (true) { "):(O+=" if ( ",t.valid===void 0?O=O+" !"+(Z?""+a:x):O+=" "+!t.valid+" ",l=this.keyword,(A=A||[]).push(O+=") { "),(A=A||[]).push(O=""),O="",u.createErrors!==!1?(O+=" { keyword: '"+(l||"custom")+"' , dataPath: (dataPath || '') + "+u.errorPath+" , schemaPath: "+u.util.toQuotedString(C)+" , params: { keyword: '"+this.keyword+"' } ",u.opts.messages!==!1&&(O+=` , message: 'should pass "`+this.keyword+`" keyword validation' `),u.opts.verbose&&(O+=" , schema: validate.schema"+L+" , parentSchema: validate.schema"+u.schemaPath+" , data: "+b+" "),O+=" } "):O+=" {} ",r=O,O=A.pop(),!u.compositeRule&&m?u.async?O+=" throw new ValidationError(["+r+"]); ":O+=" validate.errors = ["+r+"]; return false; ":O+=" var err = "+r+";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",n=O,O=A.pop(),N?t.errors?t.errors!="full"&&(O+="  for (var "+d+"="+p+"; "+d+"<errors; "+d+"++) { var "+g+" = vErrors["+d+"]; if ("+g+".dataPath === undefined) "+g+".dataPath = (dataPath || '') + "+u.errorPath+"; if ("+g+".schemaPath === undefined) { "+g+'.schemaPath = "'+C+'"; } ',u.opts.verbose&&(O+=" "+g+".schema = "+s+"; "+g+".data = "+b+"; "),O+=" } "):t.errors===!1?O+=" "+n+" ":(O+=" if ("+p+" == errors) { "+n+" } else {  for (var "+d+"="+p+"; "+d+"<errors; "+d+"++) { var "+g+" = vErrors["+d+"]; if ("+g+".dataPath === undefined) "+g+".dataPath = (dataPath || '') + "+u.errorPath+"; if ("+g+".schemaPath === undefined) { "+g+'.schemaPath = "'+C+'"; } ',u.opts.verbose&&(O+=" "+g+".schema = "+s+"; "+g+".data = "+b+"; "),O+=" } } "):Z?(O+="   var err =   ",u.createErrors!==!1?(O+=" { keyword: '"+(l||"custom")+"' , dataPath: (dataPath || '') + "+u.errorPath+" , schemaPath: "+u.util.toQuotedString(C)+" , params: { keyword: '"+this.keyword+"' } ",u.opts.messages!==!1&&(O+=` , message: 'should pass "`+this.keyword+`" keyword validation' `),u.opts.verbose&&(O+=" , schema: validate.schema"+L+" , parentSchema: validate.schema"+u.schemaPath+" , data: "+b+" "),O+=" } "):O+=" {} ",O+=";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",!u.compositeRule&&m&&(u.async?O+=" throw new ValidationError(vErrors); ":O+=" validate.errors = vErrors; return false; ")):t.errors===!1?O+=" "+n+" ":(O+=" if (Array.isArray("+v+")) { if (vErrors === null) vErrors = "+v+"; else vErrors = vErrors.concat("+v+"); errors = vErrors.length;  for (var "+d+"="+p+"; "+d+"<errors; "+d+"++) { var "+g+" = vErrors["+d+"]; if ("+g+".dataPath === undefined) "+g+".dataPath = (dataPath || '') + "+u.errorPath+";  "+g+'.schemaPath = "'+C+'";  ',u.opts.verbose&&(O+=" "+g+".schema = "+s+"; "+g+".data = "+b+"; "),O+=" } } else { "+n+" } "),O+=" } ",m&&(O+=" else { ")),O}},9115:function(ie){ie.exports=function(u,b,X){var k,N=" ",Z=u.level,O=u.dataLevel,W=u.schema[b],F=u.schemaPath+u.util.getProperty(b),L=u.errSchemaPath+"/"+b,C=!u.opts.allErrors,m="data"+(O||""),b="errs__"+Z,x=u.util.copy(u),p="",l=(x.level++,"valid"+x.level),s={},n={},t=u.opts.ownProperties;for(I in W)I!="__proto__"&&(B=W[I],(k=Array.isArray(B)?n:s)[I]=B);var i=u.errorPath;for(I in N=N+("var "+b+" = errors;")+("var missing"+Z+";"),n)if((k=n[I]).length){if(N+=" if ( "+m+u.util.getProperty(I)+" !== undefined ",t&&(N+=" && Object.prototype.hasOwnProperty.call("+m+", '"+u.util.escapeQuotes(I)+"') "),C){N+=" && ( ";var e=k;if(e)for(var r=-1,a=e.length-1;r<a;)v=e[r+=1],r&&(N+=" || "),N+=" ( ( "+(w=m+(y=u.util.getProperty(v)))+" === undefined ",t&&(N+=" || ! Object.prototype.hasOwnProperty.call("+m+", '"+u.util.escapeQuotes(v)+"') "),N+=") && (missing"+Z+" = "+u.util.toQuotedString(u.opts.jsonPointers?v:y)+") ) ";N+=")) {  ";var h="missing"+Z,o="' + "+h+" + '",c=(u.opts._errorDataPathProperty&&(u.errorPath=u.opts.jsonPointers?u.util.getPathExpr(i,h,!0):i+" + "+h),c||[]),h=(c.push(N),N="",u.createErrors!==!1?(N+=" { keyword: 'dependencies' , dataPath: (dataPath || '') + "+u.errorPath+" , schemaPath: "+u.util.toQuotedString(L)+" , params: { property: '"+u.util.escapeQuotes(I)+"', missingProperty: '"+o+"', depsCount: "+k.length+", deps: '"+u.util.escapeQuotes(k.length==1?k[0]:k.join(", "))+"' } ",u.opts.messages!==!1&&(N+=" , message: 'should have ",k.length==1?N+="property "+u.util.escapeQuotes(k[0]):N+="properties "+u.util.escapeQuotes(k.join(", ")),N+=" when property "+u.util.escapeQuotes(I)+" is present' "),u.opts.verbose&&(N+=" , schema: validate.schema"+F+" , parentSchema: validate.schema"+u.schemaPath+" , data: "+m+" "),N+=" } "):N+=" {} ",N),N=c.pop();!u.compositeRule&&C?u.async?N+=" throw new ValidationError(["+h+"]); ":N+=" validate.errors = ["+h+"]; return false; ":N+=" var err = "+h+";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; "}else{N+=" ) { ";var A=k;if(A)for(var v,d=-1,g=A.length-1;d<g;){v=A[d+=1];var y=u.util.getProperty(v),o=u.util.escapeQuotes(v),w=m+y;u.opts._errorDataPathProperty&&(u.errorPath=u.util.getPath(i,v,u.opts.jsonPointers)),N+=" if ( "+w+" === undefined ",t&&(N+=" || ! Object.prototype.hasOwnProperty.call("+m+", '"+u.util.escapeQuotes(v)+"') "),N+=") {  var err =   ",u.createErrors!==!1?(N+=" { keyword: 'dependencies' , dataPath: (dataPath || '') + "+u.errorPath+" , schemaPath: "+u.util.toQuotedString(L)+" , params: { property: '"+u.util.escapeQuotes(I)+"', missingProperty: '"+o+"', depsCount: "+k.length+", deps: '"+u.util.escapeQuotes(k.length==1?k[0]:k.join(", "))+"' } ",u.opts.messages!==!1&&(N+=" , message: 'should have ",k.length==1?N+="property "+u.util.escapeQuotes(k[0]):N+="properties "+u.util.escapeQuotes(k.join(", ")),N+=" when property "+u.util.escapeQuotes(I)+" is present' "),u.opts.verbose&&(N+=" , schema: validate.schema"+F+" , parentSchema: validate.schema"+u.schemaPath+" , data: "+m+" "),N+=" } "):N+=" {} ",N+=";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; } "}}N+=" }   ",C&&(p+="}",N+=" else { ")}u.errorPath=i;var I,T=x.baseId;for(I in s){var B=s[I];(u.opts.strictKeywords?typeof B=="object"&&0<Object.keys(B).length||B===!1:u.util.schemaHasRules(B,u.RULES.all))&&(N+=" "+l+" = true; if ( "+m+u.util.getProperty(I)+" !== undefined ",t&&(N+=" && Object.prototype.hasOwnProperty.call("+m+", '"+u.util.escapeQuotes(I)+"') "),N+=") { ",x.schema=B,x.schemaPath=F+u.util.getProperty(I),x.errSchemaPath=L+"/"+u.util.escapeFragment(I),N+="  "+u.validate(x)+" ",x.baseId=T,N+=" }  ",C&&(N+=" if ("+l+") { ",p+="}"))}return C&&(N+="   "+p+" if ("+b+" == errors) {"),N}},9317:function(ie){ie.exports=function(u,Z,X){var b=" ",k=u.level,C=u.dataLevel,m=u.schema[Z],N=u.schemaPath+u.util.getProperty(Z),Z=u.errSchemaPath+"/"+Z,O=!u.opts.allErrors,W="data"+(C||""),F="valid"+k,L=u.opts.$data&&m&&m.$data,m=(L&&(b+=" var schema"+k+" = "+u.util.getData(m.$data,C,u.dataPathArr)+"; "),"i"+k),C="schema"+k,C=(L||(b+=" var "+C+" = validate.schema"+N+";"),b+="var "+F+";",L&&(b+=" if (schema"+k+" === undefined) "+F+" = true; else if (!Array.isArray(schema"+k+")) "+F+" = false; else {"),b+=F+" = false;for (var "+m+"=0; "+m+"<"+C+".length; "+m+"++) if (equal("+W+", "+C+"["+m+"])) { "+F+" = true; break; }",L&&(b+="  }  "),[]),m=(C.push(b+=" if (!"+F+") {   "),b="",u.createErrors!==!1?(b+=" { keyword: 'enum' , dataPath: (dataPath || '') + "+u.errorPath+" , schemaPath: "+u.util.toQuotedString(Z)+" , params: { allowedValues: schema"+k+" } ",u.opts.messages!==!1&&(b+=" , message: 'should be equal to one of the allowed values' "),u.opts.verbose&&(b+=" , schema: validate.schema"+N+" , parentSchema: validate.schema"+u.schemaPath+" , data: "+W+" "),b+=" } "):b+=" {} ",b),b=C.pop();return!u.compositeRule&&O?u.async?b+=" throw new ValidationError(["+m+"]); ":b+=" validate.errors = ["+m+"]; return false; ":b+=" var err = "+m+";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",b+=" }",O&&(b+=" else { "),b}},8327:function(ie){ie.exports=function(u,F,X){var k=" ",N=u.level,Z=u.dataLevel,O=u.schema[F],W=u.schemaPath+u.util.getProperty(F),F=u.errSchemaPath+"/"+F,L=!u.opts.allErrors,C="data"+(Z||"");if(u.opts.format===!1)L&&(k+=" if (true) { ");else{var m,b=u.opts.$data&&O&&O.$data,Z=b?(k+=" var schema"+N+" = "+u.util.getData(O.$data,Z,u.dataPathArr)+"; ","schema"+N):O,x=u.opts.unknownFormats,p=Array.isArray(x);if(b)k+=" var "+(m="format"+N)+" = formats["+Z+"]; var "+(l="isObject"+N)+" = typeof "+m+" == 'object' && !("+m+" instanceof RegExp) && "+m+".validate; var "+(n="formatType"+N)+" = "+l+" && "+m+".type || 'string'; if ("+l+") { ",u.async&&(k+=" var async"+N+" = "+m+".async; "),k+=" "+m+" = "+m+".validate; } if (  ",b&&(k+=" ("+Z+" !== undefined && typeof "+Z+" != 'string') || "),k+=" (",x!="ignore"&&(k+=" ("+Z+" && !"+m+" ",p&&(k+=" && self._opts.unknownFormats.indexOf("+Z+") == -1 "),k+=") || "),k+=" ("+m+" && "+n+" == '"+X+"' && !(typeof "+m+" == 'function' ? ",u.async?k+=" (async"+N+" ? await "+m+"("+C+") : "+m+"("+C+")) ":k+=" "+m+"("+C+") ",k+=" : "+m+".test("+C+"))))) {";else{if(!(m=u.formats[O])){if(x=="ignore")return u.logger.warn('unknown format "'+O+'" ignored in schema at path "'+u.errSchemaPath+'"'),L&&(k+=" if (true) { "),k;if(p&&0<=x.indexOf(O))return L&&(k+=" if (true) { "),k;throw new Error('unknown format "'+O+'" is used in schema at path "'+u.errSchemaPath+'"')}var l,s,n=(l=typeof m=="object"&&!(m instanceof RegExp)&&m.validate)&&m.type||"string";if(l&&(s=m.async===!0,m=m.validate),n!=X)return L&&(k+=" if (true) { "),k;if(s){if(!u.async)throw new Error("async format in sync schema");k+=" if (!(await "+(t="formats"+u.util.getProperty(O)+".validate")+"("+C+"))) { "}else{k+=" if (! ";var t="formats"+u.util.getProperty(O);l&&(t+=".validate"),k=k+(typeof m=="function"?" "+t+"("+C+") ":" "+t+".test("+C+") ")+") { "}}N=[],p=(N.push(k),k="",u.createErrors!==!1?(k=(k+=" { keyword: 'format' , dataPath: (dataPath || '') + "+u.errorPath+" , schemaPath: "+u.util.toQuotedString(F)+" , params: { format:  ")+(b?""+Z:""+u.util.toQuotedString(O))+"  } ",u.opts.messages!==!1&&(k=(k+=` , message: 'should match format "`)+(b?"' + "+Z+" + '":""+u.util.escapeQuotes(O))+`"' `),u.opts.verbose&&(k=(k=(k+=" , schema:  ")+(b?"validate.schema"+W:""+u.util.toQuotedString(O)))+"         , parentSchema: validate.schema"+u.schemaPath+" , data: "+C+" "),k+=" } "):k+=" {} ",k),k=N.pop(),!u.compositeRule&&L?u.async?k+=" throw new ValidationError(["+p+"]); ":k+=" validate.errors = ["+p+"]; return false; ":k+=" var err = "+p+";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",k+=" } ",L&&(k+=" else { ")}return k}},5926:function(ie){ie.exports=function(u,F,X){var k,N=" ",Z=u.level,C=u.dataLevel,O=u.schema[F],W=u.schemaPath+u.util.getProperty(F),F=u.errSchemaPath+"/"+F,L=!u.opts.allErrors,C="data"+(C||""),m="valid"+Z,b="errs__"+Z,x=u.util.copy(u),p=(x.level++,"valid"+x.level),l=u.schema.then,s=u.schema.else,l=l!==void 0&&(u.opts.strictKeywords?typeof l=="object"&&0<Object.keys(l).length||l===!1:u.util.schemaHasRules(l,u.RULES.all)),s=s!==void 0&&(u.opts.strictKeywords?typeof s=="object"&&0<Object.keys(s).length||s===!1:u.util.schemaHasRules(s,u.RULES.all)),n=x.baseId;return l||s?(x.createErrors=!1,x.schema=O,x.schemaPath=W,x.errSchemaPath=F,N+=" var "+b+" = errors; var "+m+" = true;  ",O=u.compositeRule,u.compositeRule=x.compositeRule=!0,N+="  "+u.validate(x)+" ",x.baseId=n,x.createErrors=!0,N+="  errors = "+b+"; if (vErrors !== null) { if ("+b+") vErrors.length = "+b+"; else vErrors = null; }  ",u.compositeRule=x.compositeRule=O,l?(N+=" if ("+p+") {  ",x.schema=u.schema.then,x.schemaPath=u.schemaPath+".then",x.errSchemaPath=u.errSchemaPath+"/then",N+="  "+u.validate(x)+" ",x.baseId=n,N+=" "+m+" = "+p+"; ",l&&s?N+=" var "+(k="ifClause"+Z)+" = 'then'; ":k="'then'",N+=" } ",s&&(N+=" else { ")):N+=" if (!"+p+") { ",s&&(x.schema=u.schema.else,x.schemaPath=u.schemaPath+".else",x.errSchemaPath=u.errSchemaPath+"/else",N+="  "+u.validate(x)+" ",x.baseId=n,N+=" "+m+" = "+p+"; ",l&&s?N+=" var "+(k="ifClause"+Z)+" = 'else'; ":k="'else'",N+=" } "),N+=" if (!"+m+") {   var err =   ",u.createErrors!==!1?(N+=" { keyword: 'if' , dataPath: (dataPath || '') + "+u.errorPath+" , schemaPath: "+u.util.toQuotedString(F)+" , params: { failingKeyword: "+k+" } ",u.opts.messages!==!1&&(N+=` , message: 'should match "' + `+k+` + '" schema' `),u.opts.verbose&&(N+=" , schema: validate.schema"+W+" , parentSchema: validate.schema"+u.schemaPath+" , data: "+C+" "),N+=" } "):N+=" {} ",N+=";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",!u.compositeRule&&L&&(u.async?N+=" throw new ValidationError(vErrors); ":N+=" validate.errors = vErrors; return false; "),N+=" }   ",L&&(N+=" else { ")):L&&(N+=" if (true) { "),N}},9646:function(ie,u,V){ie.exports={$ref:V(2331),allOf:V(9486),anyOf:V(5347),$comment:V(923),const:V(2617),contains:V(2119),dependencies:V(9115),enum:V(9317),format:V(8327),if:V(5926),items:V(392),maximum:V(1796),minimum:V(1796),maxItems:V(2407),minItems:V(2407),maxLength:V(1250),minLength:V(1250),maxProperties:V(2596),minProperties:V(2596),multipleOf:V(6039),not:V(7946),oneOf:V(9344),pattern:V(9737),properties:V(2537),propertyNames:V(2127),required:V(1204),uniqueItems:V(1985),validate:V(1869)}},392:function(ie){ie.exports=function(u,L,X){var k=" ",p=u.level,C=u.dataLevel,N=u.schema[L],Z=u.schemaPath+u.util.getProperty(L),O=u.errSchemaPath+"/"+L,W=!u.opts.allErrors,F="data"+(C||""),L="valid"+p,C="errs__"+p,m=u.util.copy(u),b="",x=(m.level++,"valid"+m.level),p="i"+p,l=m.dataLevel=u.dataLevel+1,s="data"+l,n=u.baseId;if(k+="var "+C+" = errors;var "+L+";",Array.isArray(N)){var t,i,e=u.schema.additionalItems,r=(e===!1&&(k+=" "+L+" = "+F+".length <= "+N.length+"; ",t=O,O=u.errSchemaPath+"/additionalItems",(i=i||[]).push(k+="  if (!"+L+") {   "),k="",u.createErrors!==!1?(k+=" { keyword: 'additionalItems' , dataPath: (dataPath || '') + "+u.errorPath+" , schemaPath: "+u.util.toQuotedString(O)+" , params: { limit: "+N.length+" } ",u.opts.messages!==!1&&(k+=" , message: 'should NOT have more than "+N.length+" items' "),u.opts.verbose&&(k+=" , schema: false , parentSchema: validate.schema"+u.schemaPath+" , data: "+F+" "),k+=" } "):k+=" {} ",L=k,k=i.pop(),!u.compositeRule&&W?u.async?k+=" throw new ValidationError(["+L+"]); ":k+=" validate.errors = ["+L+"]; return false; ":k+=" var err = "+L+";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",k+=" } ",O=t,W&&(b+="}",k+=" else { ")),N);if(r)for(var a=-1,o=r.length-1;a<o;){var c,h,A=r[a+=1];(u.opts.strictKeywords?typeof A=="object"&&0<Object.keys(A).length||A===!1:u.util.schemaHasRules(A,u.RULES.all))&&(k+=" "+x+" = true; if ("+F+".length > "+a+") { ",c=F+"["+a+"]",m.schema=A,m.schemaPath=Z+"["+a+"]",m.errSchemaPath=O+"/"+a,m.errorPath=u.util.getPathExpr(u.errorPath,a,u.opts.jsonPointers,!0),m.dataPathArr[l]=a,h=u.validate(m),m.baseId=n,u.util.varOccurences(h,s)<2?k+=" "+u.util.varReplace(h,s,c)+" ":k+=" var "+s+" = "+c+"; "+h+" ",k+=" }  ",W&&(k+=" if ("+x+") { ",b+="}"))}typeof e=="object"&&(u.opts.strictKeywords?typeof e=="object"&&0<Object.keys(e).length||e===!1:u.util.schemaHasRules(e,u.RULES.all))&&(m.schema=e,m.schemaPath=u.schemaPath+".additionalItems",m.errSchemaPath=u.errSchemaPath+"/additionalItems",k+=" "+x+" = true; if ("+F+".length > "+N.length+") {  for (var "+p+" = "+N.length+"; "+p+" < "+F+".length; "+p+"++) { ",m.errorPath=u.util.getPathExpr(u.errorPath,p,u.opts.jsonPointers,!0),c=F+"["+p+"]",m.dataPathArr[l]=p,h=u.validate(m),m.baseId=n,u.util.varOccurences(h,s)<2?k+=" "+u.util.varReplace(h,s,c)+" ":k+=" var "+s+" = "+c+"; "+h+" ",W&&(k+=" if (!"+x+") break; "),k+=" } }  ",W&&(k+=" if ("+x+") { ",b+="}"))}else(u.opts.strictKeywords?typeof N=="object"&&0<Object.keys(N).length||N===!1:u.util.schemaHasRules(N,u.RULES.all))&&(m.schema=N,m.schemaPath=Z,m.errSchemaPath=O,k+="  for (var "+p+" = 0; "+p+" < "+F+".length; "+p+"++) { ",m.errorPath=u.util.getPathExpr(u.errorPath,p,u.opts.jsonPointers,!0),c=F+"["+p+"]",m.dataPathArr[l]=p,h=u.validate(m),m.baseId=n,u.util.varOccurences(h,s)<2?k+=" "+u.util.varReplace(h,s,c)+" ":k+=" var "+s+" = "+c+"; "+h+" ",W&&(k+=" if (!"+x+") break; "),k+=" }");return W&&(k+=" "+b+" if ("+C+" == errors) {"),k}},6039:function(ie){ie.exports=function(u,V,X){var k=" ",N=u.level,m=u.dataLevel,Z=u.schema[V],O=u.schemaPath+u.util.getProperty(V),W=u.errSchemaPath+"/"+V,F=!u.opts.allErrors,L="data"+(m||""),C=u.opts.$data&&Z&&Z.$data,m=C?(k+=" var schema"+N+" = "+u.util.getData(Z.$data,m,u.dataPathArr)+"; ","schema"+N):Z;if(!C&&typeof Z!="number")throw new Error(V+" must be number");return k+="var division"+N+";if (",C&&(k+=" "+m+" !== undefined && ( typeof "+m+" != 'number' || "),k+=" (division"+N+" = "+L+" / "+m+", ",u.opts.multipleOfPrecision?k+=" Math.abs(Math.round(division"+N+") - division"+N+") > 1e-"+u.opts.multipleOfPrecision+" ":k+=" division"+N+" !== parseInt(division"+N+") ",k+=" ) ",C&&(k+="  )  "),V=[],V.push(k+=" ) {   "),k="",u.createErrors!==!1?(k+=" { keyword: 'multipleOf' , dataPath: (dataPath || '') + "+u.errorPath+" , schemaPath: "+u.util.toQuotedString(W)+" , params: { multipleOf: "+m+" } ",u.opts.messages!==!1&&(k=k+" , message: 'should be multiple of "+(C?"' + "+m:m+"'")),u.opts.verbose&&(k=(k+=" , schema:  ")+(C?"validate.schema"+O:""+Z)+"         , parentSchema: validate.schema"+u.schemaPath+" , data: "+L+" "),k+=" } "):k+=" {} ",N=k,k=V.pop(),!u.compositeRule&&F?u.async?k+=" throw new ValidationError(["+N+"]); ":k+=" validate.errors = ["+N+"]; return false; ":k+=" var err = "+N+";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",k+="} ",F&&(k+=" else { "),k}},7946:function(ie){ie.exports=function(u,F,X){var k,N,Z=" ",m=u.level,C=u.dataLevel,O=u.schema[F],W=u.schemaPath+u.util.getProperty(F),F=u.errSchemaPath+"/"+F,L=!u.opts.allErrors,C="data"+(C||""),m="errs__"+m,b=u.util.copy(u),x=(b.level++,"valid"+b.level);return(u.opts.strictKeywords?typeof O=="object"&&0<Object.keys(O).length||O===!1:u.util.schemaHasRules(O,u.RULES.all))?(b.schema=O,b.schemaPath=W,b.errSchemaPath=F,Z+=" var "+m+" = errors;  ",O=u.compositeRule,u.compositeRule=b.compositeRule=!0,b.createErrors=!1,b.opts.allErrors&&(N=b.opts.allErrors,b.opts.allErrors=!1),Z+=" "+u.validate(b)+" ",b.createErrors=!0,N&&(b.opts.allErrors=N),u.compositeRule=b.compositeRule=O,(k=k||[]).push(Z+=" if ("+x+") {   "),Z="",u.createErrors!==!1?(Z+=" { keyword: 'not' , dataPath: (dataPath || '') + "+u.errorPath+" , schemaPath: "+u.util.toQuotedString(F)+" , params: {} ",u.opts.messages!==!1&&(Z+=" , message: 'should NOT be valid' "),u.opts.verbose&&(Z+=" , schema: validate.schema"+W+" , parentSchema: validate.schema"+u.schemaPath+" , data: "+C+" "),Z+=" } "):Z+=" {} ",N=Z,Z=k.pop(),!u.compositeRule&&L?u.async?Z+=" throw new ValidationError(["+N+"]); ":Z+=" validate.errors = ["+N+"]; return false; ":Z+=" var err = "+N+";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",Z+=" } else {  errors = "+m+"; if (vErrors !== null) { if ("+m+") vErrors.length = "+m+"; else vErrors = null; } ",u.opts.allErrors&&(Z+=" } ")):(Z+="  var err =   ",u.createErrors!==!1?(Z+=" { keyword: 'not' , dataPath: (dataPath || '') + "+u.errorPath+" , schemaPath: "+u.util.toQuotedString(F)+" , params: {} ",u.opts.messages!==!1&&(Z+=" , message: 'should NOT be valid' "),u.opts.verbose&&(Z+=" , schema: validate.schema"+W+" , parentSchema: validate.schema"+u.schemaPath+" , data: "+C+" "),Z+=" } "):Z+=" {} ",Z+=";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",L&&(Z+=" if (false) { ")),Z}},9344:function(ie){ie.exports=function(u,W,X){var k=" ",n=u.level,F=u.dataLevel,N=u.schema[W],Z=u.schemaPath+u.util.getProperty(W),O=u.errSchemaPath+"/"+W,W=!u.opts.allErrors,F="data"+(F||""),L="valid"+n,C="errs__"+n,m=u.util.copy(u),b="",x=(m.level++,"valid"+m.level),p=m.baseId,l="prevValid"+n,s="passingSchemas"+n,n=(k+="var "+C+" = errors , "+l+" = false , "+L+" = false , "+s+" = null; ",u.compositeRule),t=(u.compositeRule=m.compositeRule=!0,N);if(t)for(var i,e=-1,r=t.length-1;e<r;)i=t[e+=1],(u.opts.strictKeywords?typeof i=="object"&&0<Object.keys(i).length||i===!1:u.util.schemaHasRules(i,u.RULES.all))?(m.schema=i,m.schemaPath=Z+"["+e+"]",m.errSchemaPath=O+"/"+e,k+="  "+u.validate(m)+" ",m.baseId=p):k+=" var "+x+" = true; ",e&&(k+=" if ("+x+" && "+l+") { "+L+" = false; "+s+" = ["+s+", "+e+"]; } else { ",b+="}"),k+=" if ("+x+") { "+L+" = "+l+" = true; "+s+" = "+e+"; }";return u.compositeRule=m.compositeRule=n,k+=b+"if (!"+L+") {   var err =   ",u.createErrors!==!1?(k+=" { keyword: 'oneOf' , dataPath: (dataPath || '') + "+u.errorPath+" , schemaPath: "+u.util.toQuotedString(O)+" , params: { passingSchemas: "+s+" } ",u.opts.messages!==!1&&(k+=" , message: 'should match exactly one schema in oneOf' "),u.opts.verbose&&(k+=" , schema: validate.schema"+Z+" , parentSchema: validate.schema"+u.schemaPath+" , data: "+F+" "),k+=" } "):k+=" {} ",k+=";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",!u.compositeRule&&W&&(u.async?k+=" throw new ValidationError(vErrors); ":k+=" validate.errors = vErrors; return false; "),k+="} else {  errors = "+C+"; if (vErrors !== null) { if ("+C+") vErrors.length = "+C+"; else vErrors = null; }",u.opts.allErrors&&(k+=" } "),k}},9737:function(ie){ie.exports=function(u,Z,X){var b=" ",m=u.level,L=u.dataLevel,k=u.schema[Z],N=u.schemaPath+u.util.getProperty(Z),Z=u.errSchemaPath+"/"+Z,O=!u.opts.allErrors,W="data"+(L||""),F=u.opts.$data&&k&&k.$data,L=F?(b+=" var schema"+m+" = "+u.util.getData(k.$data,L,u.dataPathArr)+"; ","schema"+m):k,m=F?"(new RegExp("+L+"))":u.usePattern(k),C=(b+="if ( ",F&&(b+=" ("+L+" !== undefined && typeof "+L+" != 'string') || "),[]),m=(C.push(b+=" !"+m+".test("+W+") ) {   "),b="",u.createErrors!==!1?(b=(b+=" { keyword: 'pattern' , dataPath: (dataPath || '') + "+u.errorPath+" , schemaPath: "+u.util.toQuotedString(Z)+" , params: { pattern:  ")+(F?""+L:""+u.util.toQuotedString(k))+"  } ",u.opts.messages!==!1&&(b=(b+=` , message: 'should match pattern "`)+(F?"' + "+L+" + '":""+u.util.escapeQuotes(k))+`"' `),u.opts.verbose&&(b=(b=(b+=" , schema:  ")+(F?"validate.schema"+N:""+u.util.toQuotedString(k)))+"         , parentSchema: validate.schema"+u.schemaPath+" , data: "+W+" "),b+=" } "):b+=" {} ",b),b=C.pop();return!u.compositeRule&&O?u.async?b+=" throw new ValidationError(["+m+"]); ":b+=" validate.errors = ["+m+"]; return false; ":b+=" var err = "+m+";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",b+="} ",O&&(b+=" else { "),b}},2537:function(ie){ie.exports=function(u,m,X){var k,N=" ",Z=u.level,e=u.dataLevel,O=u.schema[m],W=u.schemaPath+u.util.getProperty(m),F=u.errSchemaPath+"/"+m,L=!u.opts.allErrors,C="data"+(e||""),m="errs__"+Z,b=u.util.copy(u),x="",p=(b.level++,"valid"+b.level),l="key"+Z,s="idx"+Z,n=b.dataLevel=u.dataLevel+1,t="data"+n,i="dataProperties"+Z,e=Object.keys(O||{}).filter(I),r=u.schema.patternProperties||{},a=Object.keys(r).filter(I),o=u.schema.additionalProperties,c=e.length||a.length,h=o===!1,A=typeof o=="object"&&Object.keys(o).length,v=u.opts.removeAdditional,d=h||A||v,g=u.opts.ownProperties,y=u.baseId,w=u.schema.required;function I(Te){return Te!=="__proto__"}if(w&&(!u.opts.$data||!w.$data)&&w.length<u.opts.loopRequired&&(k=u.util.toHash(w)),N+="var "+m+" = errors;var "+p+" = true;",g&&(N+=" var "+i+" = undefined;"),d){if(N+=g?" "+i+" = "+i+" || Object.keys("+C+"); for (var "+s+"=0; "+s+"<"+i+".length; "+s+"++) { var "+l+" = "+i+"["+s+"]; ":" for (var "+l+" in "+C+") { ",c){if(N+=" var isAdditional"+Z+" = !(false ",e.length)if(8<e.length)N+=" || validate.schema"+W+".hasOwnProperty("+l+") ";else{var T=e;if(T)for(var B=-1,E=T.length-1;B<E;)Y=T[B+=1],N+=" || "+l+" == "+u.util.toQuotedString(Y)+" "}if(a.length){var _=a;if(_)for(var P=-1,j=_.length-1;P<j;)Ae=_[P+=1],N+=" || "+u.usePattern(Ae)+".test("+l+") "}N+=" ); if (isAdditional"+Z+") { "}v=="all"?N+=" delete "+C+"["+l+"]; ":(S=u.errorPath,w="' + "+l+" + '",u.opts._errorDataPathProperty&&(u.errorPath=u.util.getPathExpr(u.errorPath,l,u.opts.jsonPointers)),h?v?N+=" delete "+C+"["+l+"]; ":($=F,F=u.errSchemaPath+"/additionalProperties",(K=K||[]).push(N+=" "+p+" = false; "),N="",u.createErrors!==!1?(N+=" { keyword: 'additionalProperties' , dataPath: (dataPath || '') + "+u.errorPath+" , schemaPath: "+u.util.toQuotedString(F)+" , params: { additionalProperty: '"+w+"' } ",u.opts.messages!==!1&&(N+=" , message: '",u.opts._errorDataPathProperty?N+="is an invalid additional property":N+="should NOT have additional properties",N+="' "),u.opts.verbose&&(N+=" , schema: false , parentSchema: validate.schema"+u.schemaPath+" , data: "+C+" "),N+=" } "):N+=" {} ",Q=N,N=K.pop(),!u.compositeRule&&L?u.async?N+=" throw new ValidationError(["+Q+"]); ":N+=" validate.errors = ["+Q+"]; return false; ":N+=" var err = "+Q+";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",F=$,L&&(N+=" break; ")):A&&(v=="failing"?(N+=" var "+m+" = errors;  ",d=u.compositeRule,u.compositeRule=b.compositeRule=!0,b.schema=o,b.schemaPath=u.schemaPath+".additionalProperties",b.errSchemaPath=u.errSchemaPath+"/additionalProperties",b.errorPath=u.opts._errorDataPathProperty?u.errorPath:u.util.getPathExpr(u.errorPath,l,u.opts.jsonPointers),ve=C+"["+l+"]",b.dataPathArr[n]=l,ye=u.validate(b),b.baseId=y,u.util.varOccurences(ye,t)<2?N+=" "+u.util.varReplace(ye,t,ve)+" ":N+=" var "+t+" = "+ve+"; "+ye+" ",N+=" if (!"+p+") { errors = "+m+"; if (validate.errors !== null) { if (errors) validate.errors.length = errors; else validate.errors = null; } delete "+C+"["+l+"]; }  ",u.compositeRule=b.compositeRule=d):(b.schema=o,b.schemaPath=u.schemaPath+".additionalProperties",b.errSchemaPath=u.errSchemaPath+"/additionalProperties",b.errorPath=u.opts._errorDataPathProperty?u.errorPath:u.util.getPathExpr(u.errorPath,l,u.opts.jsonPointers),ve=C+"["+l+"]",b.dataPathArr[n]=l,ye=u.validate(b),b.baseId=y,u.util.varOccurences(ye,t)<2?N+=" "+u.util.varReplace(ye,t,ve)+" ":N+=" var "+t+" = "+ve+"; "+ye+" ",L&&(N+=" if (!"+p+") break; "))),u.errorPath=S),c&&(N+=" } "),N+=" }  ",L&&(N+=" if ("+p+") { ",x+="}")}var z=u.opts.useDefaults&&!u.compositeRule;if(e.length){var D=e;if(D)for(var Y,R=-1,H=D.length-1;R<H;){var G,f,S,$,M,K,Q,te=O[Y=D[R+=1]];(u.opts.strictKeywords?typeof te=="object"&&0<Object.keys(te).length||te===!1:u.util.schemaHasRules(te,u.RULES.all))&&(ve=C+(M=u.util.getProperty(Y)),G=z&&te.default!==void 0,b.schema=te,b.schemaPath=W+M,b.errSchemaPath=F+"/"+u.util.escapeFragment(Y),b.errorPath=u.util.getPath(u.errorPath,Y,u.opts.jsonPointers),b.dataPathArr[n]=u.util.toQuotedString(Y),ye=u.validate(b),b.baseId=y,u.util.varOccurences(ye,t)<2?(ye=u.util.varReplace(ye,t,ve),f=ve):N+=" var "+(f=t)+" = "+ve+"; ",G?N+=" "+ye+" ":(k&&k[Y]?(N+=" if ( "+f+" === undefined ",g&&(N+=" || ! Object.prototype.hasOwnProperty.call("+C+", '"+u.util.escapeQuotes(Y)+"') "),N+=") { "+p+" = false; ",S=u.errorPath,$=F,M=u.util.escapeQuotes(Y),u.opts._errorDataPathProperty&&(u.errorPath=u.util.getPath(S,Y,u.opts.jsonPointers)),F=u.errSchemaPath+"/required",(K=K||[]).push(N),N="",u.createErrors!==!1?(N+=" { keyword: 'required' , dataPath: (dataPath || '') + "+u.errorPath+" , schemaPath: "+u.util.toQuotedString(F)+" , params: { missingProperty: '"+M+"' } ",u.opts.messages!==!1&&(N+=" , message: '",u.opts._errorDataPathProperty?N+="is a required property":N+="should have required property \\'"+M+"\\'",N+="' "),u.opts.verbose&&(N+=" , schema: validate.schema"+W+" , parentSchema: validate.schema"+u.schemaPath+" , data: "+C+" "),N+=" } "):N+=" {} ",Q=N,N=K.pop(),!u.compositeRule&&L?u.async?N+=" throw new ValidationError(["+Q+"]); ":N+=" validate.errors = ["+Q+"]; return false; ":N+=" var err = "+Q+";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",F=$,u.errorPath=S,N+=" } else { "):L?(N+=" if ( "+f+" === undefined ",g&&(N+=" || ! Object.prototype.hasOwnProperty.call("+C+", '"+u.util.escapeQuotes(Y)+"') "),N+=") { "+p+" = true; } else { "):(N+=" if ("+f+" !== undefined ",g&&(N+=" &&   Object.prototype.hasOwnProperty.call("+C+", '"+u.util.escapeQuotes(Y)+"') "),N+=" ) { "),N+=" "+ye+" } ")),L&&(N+=" if ("+p+") { ",x+="}")}}if(a.length){var he=a;if(he)for(var Ae,ge=-1,Ce=he.length-1;ge<Ce;){var ve,ye,te=r[Ae=he[ge+=1]];(u.opts.strictKeywords?typeof te=="object"&&0<Object.keys(te).length||te===!1:u.util.schemaHasRules(te,u.RULES.all))&&(b.schema=te,b.schemaPath=u.schemaPath+".patternProperties"+u.util.getProperty(Ae),b.errSchemaPath=u.errSchemaPath+"/patternProperties/"+u.util.escapeFragment(Ae),N=(N+=g?" "+i+" = "+i+" || Object.keys("+C+"); for (var "+s+"=0; "+s+"<"+i+".length; "+s+"++) { var "+l+" = "+i+"["+s+"]; ":" for (var "+l+" in "+C+") { ")+" if ("+u.usePattern(Ae)+".test("+l+")) { ",b.errorPath=u.util.getPathExpr(u.errorPath,l,u.opts.jsonPointers),ve=C+"["+l+"]",b.dataPathArr[n]=l,ye=u.validate(b),b.baseId=y,u.util.varOccurences(ye,t)<2?N+=" "+u.util.varReplace(ye,t,ve)+" ":N+=" var "+t+" = "+ve+"; "+ye+" ",L&&(N+=" if (!"+p+") break; "),N+=" } ",L&&(N+=" else "+p+" = true; "),N+=" }  ",L&&(N+=" if ("+p+") { ",x+="}"))}}return L&&(N+=" "+x+" if ("+m+" == errors) {"),N}},2127:function(ie){ie.exports=function(u,p,X){var k,N,Z,O,W,F,L,C=" ",m=u.level,s=u.dataLevel,b=u.schema[p],x=u.schemaPath+u.util.getProperty(p),p=u.errSchemaPath+"/"+p,l=!u.opts.allErrors,s="data"+(s||""),n="errs__"+m,t=u.util.copy(u),i=(t.level++,"valid"+t.level);return C+="var "+n+" = errors;",(u.opts.strictKeywords?typeof b=="object"&&0<Object.keys(b).length||b===!1:u.util.schemaHasRules(b,u.RULES.all))&&(t.schema=b,t.schemaPath=x,t.errSchemaPath=p,b="idx"+m,N="i"+m,Z="' + "+(k="key"+m)+" + '",O="data"+(t.dataLevel=u.dataLevel+1),L="dataProperties"+m,F=u.opts.ownProperties,W=u.baseId,F&&(C+=" var "+L+" = undefined; "),C=C+(F?" "+L+" = "+L+" || Object.keys("+s+"); for (var "+b+"=0; "+b+"<"+L+".length; "+b+"++) { var "+k+" = "+L+"["+b+"]; ":" for (var "+k+" in "+s+") { ")+" var startErrs"+m+" = errors; ",F=k,L=u.compositeRule,u.compositeRule=t.compositeRule=!0,b=u.validate(t),t.baseId=W,u.util.varOccurences(b,O)<2?C+=" "+u.util.varReplace(b,O,F)+" ":C+=" var "+O+" = "+F+"; "+b+" ",u.compositeRule=t.compositeRule=L,C+=" if (!"+i+") { for (var "+N+"=startErrs"+m+"; "+N+"<errors; "+N+"++) { vErrors["+N+"].propertyName = "+k+"; }   var err =   ",u.createErrors!==!1?(C+=" { keyword: 'propertyNames' , dataPath: (dataPath || '') + "+u.errorPath+" , schemaPath: "+u.util.toQuotedString(p)+" , params: { propertyName: '"+Z+"' } ",u.opts.messages!==!1&&(C+=" , message: 'property name \\'"+Z+"\\' is invalid' "),u.opts.verbose&&(C+=" , schema: validate.schema"+x+" , parentSchema: validate.schema"+u.schemaPath+" , data: "+s+" "),C+=" } "):C+=" {} ",C+=";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",!u.compositeRule&&l&&(u.async?C+=" throw new ValidationError(vErrors); ":C+=" validate.errors = vErrors; return false; "),l&&(C+=" break; "),C+=" } }"),l&&(C+="  if ("+n+" == errors) {"),C}},2331:function(ie){ie.exports=function(u,F,X){var k,N,Z=" ",m=u.level,O=u.dataLevel,W=u.schema[F],F=u.errSchemaPath+"/"+F,L=!u.opts.allErrors,C="data"+(O||""),m="valid"+m;if(W=="#"||W=="#/")N=u.isRoot?(k=u.async,"validate"):(k=u.root.schema.$async===!0,"root.refVal[0]");else{var b=u.resolveRef(u.baseId,W,u.isRoot);if(b===void 0){var x=u.MissingRefError.message(u.baseId,W);if(u.opts.missingRefs=="fail")u.logger.error(x),(p=p||[]).push(Z),Z="",u.createErrors!==!1?(Z+=" { keyword: '$ref' , dataPath: (dataPath || '') + "+u.errorPath+" , schemaPath: "+u.util.toQuotedString(F)+" , params: { ref: '"+u.util.escapeQuotes(W)+"' } ",u.opts.messages!==!1&&(Z+=" , message: 'can\\'t resolve reference "+u.util.escapeQuotes(W)+"' "),u.opts.verbose&&(Z+=" , schema: "+u.util.toQuotedString(W)+" , parentSchema: validate.schema"+u.schemaPath+" , data: "+C+" "),Z+=" } "):Z+=" {} ",F=Z,Z=p.pop(),!u.compositeRule&&L?u.async?Z+=" throw new ValidationError(["+F+"]); ":Z+=" validate.errors = ["+F+"]; return false; ":Z+=" var err = "+F+";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",L&&(Z+=" if (false) { ");else{if(u.opts.missingRefs!="ignore")throw new u.MissingRefError(u.baseId,W,x);u.logger.warn(x),L&&(Z+=" if (true) { ")}}else b.inline?((F=u.util.copy(u)).level++,x="valid"+F.level,F.schema=b.schema,F.schemaPath="",F.errSchemaPath=W,Z+=" "+u.validate(F).replace(/validate\.schema/g,b.code)+" ",L&&(Z+=" if ("+x+") { ")):(k=b.$async===!0||u.async&&b.$async!==!1,N=b.code)}if(N){(p=p||[]).push(Z),Z="",u.opts.passContext?Z+=" "+N+".call(this, ":Z+=" "+N+"( ",Z+=" "+C+", (dataPath || '')",u.errorPath!='""'&&(Z+=" + "+u.errorPath);var p,W=O?"data"+(O-1||""):"parentData",F=Z+=" , "+W+" , "+(O?u.dataPathArr[O]:"parentDataProperty")+", rootData)  ";if(Z=p.pop(),k){if(!u.async)throw new Error("async schema referenced by sync schema");L&&(Z+=" var "+m+"; "),Z+=" try { await "+F+"; ",L&&(Z+=" "+m+" = true; "),Z+=" } catch (e) { if (!(e instanceof ValidationError)) throw e; if (vErrors === null) vErrors = e.errors; else vErrors = vErrors.concat(e.errors); errors = vErrors.length; ",L&&(Z+=" "+m+" = false; "),Z+=" } ",L&&(Z+=" if ("+m+") { ")}else Z+=" if (!"+F+") { if (vErrors === null) vErrors = "+N+".errors; else vErrors = vErrors.concat("+N+".errors); errors = vErrors.length; } ",L&&(Z+=" else { ")}return Z}},1204:function(ie){ie.exports=function(u,F,X){var k=" ",N=u.level,b=u.dataLevel,Z=u.schema[F],O=u.schemaPath+u.util.getProperty(F),W=u.errSchemaPath+"/"+F,F=!u.opts.allErrors,L="data"+(b||""),C="valid"+N,m=u.opts.$data&&Z&&Z.$data,b=(m&&(k+=" var schema"+N+" = "+u.util.getData(Z.$data,b,u.dataPathArr)+"; "),"schema"+N);if(!m)if(Z.length<u.opts.loopRequired&&u.schema.properties&&Object.keys(u.schema.properties).length){var x=[],p=Z;if(p)for(var l=-1,s=p.length-1;l<s;){var n=p[l+=1],t=u.schema.properties[n];t&&(u.opts.strictKeywords?typeof t=="object"&&0<Object.keys(t).length||t===!1:u.util.schemaHasRules(t,u.RULES.all))||(x[x.length]=n)}}else x=Z;if(m||x.length){var i=u.errorPath,Z=m||x.length>=u.opts.loopRequired,e=u.opts.ownProperties;if(F){if(k+=" var missing"+N+"; ",Z){m||(k+=" var "+b+" = validate.schema"+O+"; ");var r="' + "+(v="schema"+N+"["+(c="i"+N)+"]")+" + '";u.opts._errorDataPathProperty&&(u.errorPath=u.util.getPathExpr(i,v,u.opts.jsonPointers)),k+=" var "+C+" = true; ",m&&(k+=" if (schema"+N+" === undefined) "+C+" = true; else if (!Array.isArray(schema"+N+")) "+C+" = false; else {"),k+=" for (var "+c+" = 0; "+c+" < "+b+".length; "+c+"++) { "+C+" = "+L+"["+b+"["+c+"]] !== undefined ",e&&(k+=" &&   Object.prototype.hasOwnProperty.call("+L+", "+b+"["+c+"]) "),k+="; if (!"+C+") break; } ",m&&(k+="  }  "),(A=A||[]).push(k+="  if (!"+C+") {   "),k="",u.createErrors!==!1?(k+=" { keyword: 'required' , dataPath: (dataPath || '') + "+u.errorPath+" , schemaPath: "+u.util.toQuotedString(W)+" , params: { missingProperty: '"+r+"' } ",u.opts.messages!==!1&&(k+=" , message: '",u.opts._errorDataPathProperty?k+="is a required property":k+="should have required property \\'"+r+"\\'",k+="' "),u.opts.verbose&&(k+=" , schema: validate.schema"+O+" , parentSchema: validate.schema"+u.schemaPath+" , data: "+L+" "),k+=" } "):k+=" {} ";var a=k,k=A.pop()}else{k+=" if ( ";var o=x;if(o)for(var c=-1,h=o.length-1;c<h;)g=o[c+=1],c&&(k+=" || "),k+=" ( ( "+(T=L+(I=u.util.getProperty(g)))+" === undefined ",e&&(k+=" || ! Object.prototype.hasOwnProperty.call("+L+", '"+u.util.escapeQuotes(g)+"') "),k+=") && (missing"+N+" = "+u.util.toQuotedString(u.opts.jsonPointers?g:I)+") ) ";k+=") {  ",r="' + "+(v="missing"+N)+" + '",u.opts._errorDataPathProperty&&(u.errorPath=u.opts.jsonPointers?u.util.getPathExpr(i,v,!0):i+" + "+v),(A=A||[]).push(k),k="",u.createErrors!==!1?(k+=" { keyword: 'required' , dataPath: (dataPath || '') + "+u.errorPath+" , schemaPath: "+u.util.toQuotedString(W)+" , params: { missingProperty: '"+r+"' } ",u.opts.messages!==!1&&(k+=" , message: '",u.opts._errorDataPathProperty?k+="is a required property":k+="should have required property \\'"+r+"\\'",k+="' "),u.opts.verbose&&(k+=" , schema: validate.schema"+O+" , parentSchema: validate.schema"+u.schemaPath+" , data: "+L+" "),k+=" } "):k+=" {} ";var A,a=k;k=A.pop()}!u.compositeRule&&F?u.async?k+=" throw new ValidationError(["+a+"]); ":k+=" validate.errors = ["+a+"]; return false; ":k+=" var err = "+a+";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",k+=" } else { "}else if(Z){m||(k+=" var "+b+" = validate.schema"+O+"; ");var v,r="' + "+(v="schema"+N+"["+(c="i"+N)+"]")+" + '";u.opts._errorDataPathProperty&&(u.errorPath=u.util.getPathExpr(i,v,u.opts.jsonPointers)),m&&(k+=" if ("+b+" && !Array.isArray("+b+")) {  var err =   ",u.createErrors!==!1?(k+=" { keyword: 'required' , dataPath: (dataPath || '') + "+u.errorPath+" , schemaPath: "+u.util.toQuotedString(W)+" , params: { missingProperty: '"+r+"' } ",u.opts.messages!==!1&&(k+=" , message: '",u.opts._errorDataPathProperty?k+="is a required property":k+="should have required property \\'"+r+"\\'",k+="' "),u.opts.verbose&&(k+=" , schema: validate.schema"+O+" , parentSchema: validate.schema"+u.schemaPath+" , data: "+L+" "),k+=" } "):k+=" {} ",k+=";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; } else if ("+b+" !== undefined) { "),k+=" for (var "+c+" = 0; "+c+" < "+b+".length; "+c+"++) { if ("+L+"["+b+"["+c+"]] === undefined ",e&&(k+=" || ! Object.prototype.hasOwnProperty.call("+L+", "+b+"["+c+"]) "),k+=") {  var err =   ",u.createErrors!==!1?(k+=" { keyword: 'required' , dataPath: (dataPath || '') + "+u.errorPath+" , schemaPath: "+u.util.toQuotedString(W)+" , params: { missingProperty: '"+r+"' } ",u.opts.messages!==!1&&(k+=" , message: '",u.opts._errorDataPathProperty?k+="is a required property":k+="should have required property \\'"+r+"\\'",k+="' "),u.opts.verbose&&(k+=" , schema: validate.schema"+O+" , parentSchema: validate.schema"+u.schemaPath+" , data: "+L+" "),k+=" } "):k+=" {} ",k+=";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; } } ",m&&(k+="  }  ")}else{var d=x;if(d)for(var g,y=-1,w=d.length-1;y<w;){g=d[y+=1];var I=u.util.getProperty(g),r=u.util.escapeQuotes(g),T=L+I;u.opts._errorDataPathProperty&&(u.errorPath=u.util.getPath(i,g,u.opts.jsonPointers)),k+=" if ( "+T+" === undefined ",e&&(k+=" || ! Object.prototype.hasOwnProperty.call("+L+", '"+u.util.escapeQuotes(g)+"') "),k+=") {  var err =   ",u.createErrors!==!1?(k+=" { keyword: 'required' , dataPath: (dataPath || '') + "+u.errorPath+" , schemaPath: "+u.util.toQuotedString(W)+" , params: { missingProperty: '"+r+"' } ",u.opts.messages!==!1&&(k+=" , message: '",u.opts._errorDataPathProperty?k+="is a required property":k+="should have required property \\'"+r+"\\'",k+="' "),u.opts.verbose&&(k+=" , schema: validate.schema"+O+" , parentSchema: validate.schema"+u.schemaPath+" , data: "+L+" "),k+=" } "):k+=" {} ",k+=";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; } "}}u.errorPath=i}else F&&(k+=" if (true) {");return k}},1985:function(ie){ie.exports=function(u,F,X){var k,N=" ",Z=u.level,x=u.dataLevel,O=u.schema[F],W=u.schemaPath+u.util.getProperty(F),F=u.errSchemaPath+"/"+F,L=!u.opts.allErrors,C="data"+(x||""),m="valid"+Z,b=u.opts.$data&&O&&O.$data,x=b?(N+=" var schema"+Z+" = "+u.util.getData(O.$data,x,u.dataPathArr)+"; ","schema"+Z):O;return(O||b)&&u.opts.uniqueItems!==!1?(b&&(N+=" var "+m+"; if ("+x+" === false || "+x+" === undefined) "+m+" = true; else if (typeof "+x+" != 'boolean') "+m+" = false; else { "),N+=" var i = "+C+".length , "+m+" = true , j; if (i > 1) { ",Z=u.schema.items&&u.schema.items.type,x=Array.isArray(Z),!Z||Z=="object"||Z=="array"||x&&(0<=Z.indexOf("object")||0<=Z.indexOf("array"))?N+=" outer: for (;i--;) { for (j = i; j--;) { if (equal("+C+"[i], "+C+"[j])) { "+m+" = false; break outer; } } } ":(N=(N+=" var itemIndices = {}, item; for (;i--;) { var item = "+C+"[i]; ")+" if ("+u.util["checkDataType"+(x?"s":"")](Z,"item",u.opts.strictNumbers,!0)+") continue; ",x&&(N+=` if (typeof item == 'string') item = '"' + item; `),N+=" if (typeof itemIndices[item] == 'number') { "+m+" = false; j = itemIndices[item]; break; } itemIndices[item] = i; } "),N+=" } ",b&&(N+="  }  "),(k=k||[]).push(N+=" if (!"+m+") {   "),N="",u.createErrors!==!1?(N+=" { keyword: 'uniqueItems' , dataPath: (dataPath || '') + "+u.errorPath+" , schemaPath: "+u.util.toQuotedString(F)+" , params: { i: i, j: j } ",u.opts.messages!==!1&&(N+=" , message: 'should NOT have duplicate items (items ## ' + j + ' and ' + i + ' are identical)' "),u.opts.verbose&&(N=(N+=" , schema:  ")+(b?"validate.schema"+W:""+O)+"         , parentSchema: validate.schema"+u.schemaPath+" , data: "+C+" "),N+=" } "):N+=" {} ",Z=N,N=k.pop(),!u.compositeRule&&L?u.async?N+=" throw new ValidationError(["+Z+"]); ":N+=" validate.errors = ["+Z+"]; return false; ":N+=" var err = "+Z+";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",N+=" } ",L&&(N+=" else { ")):L&&(N+=" if (true) { "),N}},1869:function(ie){ie.exports=function(u,V,X){var k="",N=u.schema.$async===!0,Z=u.util.schemaHasRulesExcept(u.schema,u.RULES.all,"$ref"),O=u.self._getId(u.schema);if(u.opts.strictKeywords){var W=u.util.schemaUnknownRules(u.schema,u.RULES.keywords);if(W){if(W="unknown keyword: "+W,u.opts.strictKeywords!=="log")throw new Error(W);u.logger.warn(W)}}if(u.isTop&&(k+=" var validate = ",N&&(u.async=!0,k+="async "),k+="function(data, dataPath, parentData, parentDataProperty, rootData) { 'use strict'; ",O&&(u.opts.sourceCode||u.opts.processCode)&&(k+=" /*# sourceURL="+O+" */ ")),typeof u.schema=="boolean"||!Z&&!u.schema.$ref)L=u.level,C=u.dataLevel,T=u.schema[V="false schema"],r=u.schemaPath+u.util.getProperty(V),a=u.errSchemaPath+"/"+V,p=!u.opts.allErrors,m="data"+(C||""),x="valid"+L,u.schema===!1?(u.isTop?p=!0:k+=" var "+x+" = false; ",(R=R||[]).push(k),k="",u.createErrors!==!1?(k+=" { keyword: 'false schema' , dataPath: (dataPath || '') + "+u.errorPath+" , schemaPath: "+u.util.toQuotedString(a)+" , params: {} ",u.opts.messages!==!1&&(k+=" , message: 'boolean schema is false' "),u.opts.verbose&&(k+=" , schema: false , parentSchema: validate.schema"+u.schemaPath+" , data: "+m+" "),k+=" } "):k+=" {} ",g=k,k=R.pop(),!u.compositeRule&&p?u.async?k+=" throw new ValidationError(["+g+"]); ":k+=" validate.errors = ["+g+"]; return false; ":k+=" var err = "+g+";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; "):u.isTop?k+=N?" return data; ":" validate.errors = null; return true; ":k+=" var "+x+" = true; ",u.isTop&&(k+=" }; return validate; ");else{if(u.isTop){var F=u.isTop,L=u.level=0,C=u.dataLevel=0,m="data";if(u.rootId=u.resolve.fullPath(u.self._getId(u.root.schema)),u.baseId=u.baseId||u.rootId,delete u.isTop,u.dataPathArr=[""],u.schema.default!==void 0&&u.opts.useDefaults&&u.opts.strictDefaults){var b="default is ignored in the schema root";if(u.opts.strictDefaults!=="log")throw new Error(b);u.logger.warn(b)}k=(k+=" var vErrors = null; ")+" var errors = 0;      if (rootData === undefined) rootData = data; "}else{if(L=u.level,m="data"+((C=u.dataLevel)||""),O&&(u.baseId=u.resolve.url(u.baseId,O)),N&&!u.async)throw new Error("async schema in sync schema");k+=" var errs_"+L+" = errors;"}var x="valid"+L,p=!u.opts.allErrors,l="",s="",n=u.schema.type,t=Array.isArray(n);if(n&&u.opts.nullable&&u.schema.nullable===!0&&(t?n.indexOf("null")==-1&&(n=n.concat("null")):n!="null"&&(n=[n,"null"],t=!0)),t&&n.length==1&&(n=n[0],t=!1),u.schema.$ref&&Z){if(u.opts.extendRefs=="fail")throw new Error('$ref: validation keywords used in schema at path "'+u.errSchemaPath+'" (see option extendRefs)');u.opts.extendRefs!==!0&&(Z=!1,u.logger.warn('$ref: keywords ignored in schema at path "'+u.errSchemaPath+'"'))}if(u.schema.$comment&&u.opts.$comment&&(k+=" "+u.RULES.all.$comment.code(u,"$comment")),n){u.opts.coerceTypes&&(i=u.util.coerceToTypes(u.opts.coerceTypes,n));var i,e=u.RULES.types[n];if(i||t||e===!0||e&&!$(e)){var r=u.schemaPath+".type",a=u.errSchemaPath+"/type",r=u.schemaPath+".type",a=u.errSchemaPath+"/type";if(k+=" if ("+u.util[t?"checkDataTypes":"checkDataType"](n,m,u.opts.strictNumbers,!0)+") { ",i){var o="dataType"+L,c="coerced"+L,h=(k+=" var "+o+" = typeof "+m+"; var "+c+" = undefined; ",u.opts.coerceTypes=="array"&&(k+=" if ("+o+" == 'object' && Array.isArray("+m+") && "+m+".length == 1) { "+m+" = "+m+"[0]; "+o+" = typeof "+m+"; if ("+u.util.checkDataType(u.schema.type,m,u.opts.strictNumbers)+") "+c+" = "+m+"; } "),k+=" if ("+c+" !== undefined) ; ",i);if(h)for(var A,v=-1,d=h.length-1;v<d;)(A=h[v+=1])=="string"?k+=" else if ("+o+" == 'number' || "+o+" == 'boolean') "+c+" = '' + "+m+"; else if ("+m+" === null) "+c+" = ''; ":A=="number"||A=="integer"?(k+=" else if ("+o+" == 'boolean' || "+m+" === null || ("+o+" == 'string' && "+m+" && "+m+" == +"+m+" ",A=="integer"&&(k+=" && !("+m+" % 1)"),k+=")) "+c+" = +"+m+"; "):A=="boolean"?k+=" else if ("+m+" === 'false' || "+m+" === 0 || "+m+" === null) "+c+" = false; else if ("+m+" === 'true' || "+m+" === 1) "+c+" = true; ":A=="null"?k+=" else if ("+m+" === '' || "+m+" === 0 || "+m+" === false) "+c+" = null; ":u.opts.coerceTypes=="array"&&A=="array"&&(k+=" else if ("+o+" == 'string' || "+o+" == 'number' || "+o+" == 'boolean' || "+m+" == null) "+c+" = ["+m+"]; ");(R=R||[]).push(k+=" else {   "),k="",u.createErrors!==!1?(k=(k+=" { keyword: 'type' , dataPath: (dataPath || '') + "+u.errorPath+" , schemaPath: "+u.util.toQuotedString(a)+" , params: { type: '")+(t?""+n.join(","):""+n)+"' } ",u.opts.messages!==!1&&(k=(k+=" , message: 'should be ")+(t?""+n.join(","):""+n)+"' "),u.opts.verbose&&(k+=" , schema: validate.schema"+r+" , parentSchema: validate.schema"+u.schemaPath+" , data: "+m+" "),k+=" } "):k+=" {} ";var g=k,W=(k=R.pop(),!u.compositeRule&&p?u.async?k+=" throw new ValidationError(["+g+"]); ":k+=" validate.errors = ["+g+"]; return false; ":k+=" var err = "+g+";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",C?"data"+(C-1||""):"parentData");k=k+(" } if ("+c+" !== undefined) {  ")+(" "+m+" = "+c+"; "),C||(k+="if ("+W+" !== undefined)"),k+=" "+W+"["+(C?u.dataPathArr[C]:"parentDataProperty")+"] = "+c+"; } "}else g=((R=R||[]).push(k),k="",u.createErrors!==!1?(k=(k+=" { keyword: 'type' , dataPath: (dataPath || '') + "+u.errorPath+" , schemaPath: "+u.util.toQuotedString(a)+" , params: { type: '")+(t?""+n.join(","):""+n)+"' } ",u.opts.messages!==!1&&(k=(k+=" , message: 'should be ")+(t?""+n.join(","):""+n)+"' "),u.opts.verbose&&(k+=" , schema: validate.schema"+r+" , parentSchema: validate.schema"+u.schemaPath+" , data: "+m+" "),k+=" } "):k+=" {} ",k),k=R.pop(),!u.compositeRule&&p?u.async?k+=" throw new ValidationError(["+g+"]); ":k+=" validate.errors = ["+g+"]; return false; ":k+=" var err = "+g+";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ";k+=" } "}}if(u.schema.$ref&&!Z)k+=" "+u.RULES.all.$ref.code(u,"$ref")+" ",p&&(k=(k+=" } if (errors === ")+(F?"0":"errs_"+L)+") { ",s+="}");else{var y=u.RULES;if(y){for(var w=-1,I=y.length-1;w<I;)if($(e=y[w+=1])){if(e.type&&(k+=" if ("+u.util.checkDataType(e.type,m,u.opts.strictNumbers)+") { "),u.opts.useDefaults){if(e.type=="object"&&u.schema.properties){var T=u.schema.properties,B=Object.keys(T);if(B){for(var E,_=-1,P=B.length-1;_<P;)if((D=T[E=B[_+=1]]).default!==void 0){var j=m+u.util.getProperty(E);if(u.compositeRule){if(u.opts.strictDefaults){if(b="default is ignored for: "+j,u.opts.strictDefaults!=="log")throw new Error(b);u.logger.warn(b)}}else k+=" if ("+j+" === undefined ",u.opts.useDefaults=="empty"&&(k+=" || "+j+" === null || "+j+" === '' "),k+=" ) "+j+" = ",u.opts.useDefaults=="shared"?k+=" "+u.useDefault(D.default)+" ":k+=" "+JSON.stringify(D.default)+" ",k+="; "}}}else if(e.type=="array"&&Array.isArray(u.schema.items)){var z=u.schema.items;if(z){for(var D,v=-1,Y=z.length-1;v<Y;)if((D=z[v+=1]).default!==void 0)if(j=m+"["+v+"]",u.compositeRule){if(u.opts.strictDefaults){if(b="default is ignored for: "+j,u.opts.strictDefaults!=="log")throw new Error(b);u.logger.warn(b)}}else k+=" if ("+j+" === undefined ",u.opts.useDefaults=="empty"&&(k+=" || "+j+" === null || "+j+" === '' "),k+=" ) "+j+" = ",u.opts.useDefaults=="shared"?k+=" "+u.useDefault(D.default)+" ":k+=" "+JSON.stringify(D.default)+" ",k+="; "}}}var R,H=e.rules;if(H)for(var G,f=-1,S=H.length-1;f<S;)!M(G=H[f+=1])||(G=G.code(u,G.keyword,e.type))&&(k+=" "+G+" ",p&&(l+="}"));p&&(k+=" "+l+" ",l=""),e.type&&(k+=" } ",n&&n===e.type&&!i&&(k+=" else { ",r=u.schemaPath+".type",a=u.errSchemaPath+"/type",(R=R||[]).push(k),k="",u.createErrors!==!1?(k=(k+=" { keyword: 'type' , dataPath: (dataPath || '') + "+u.errorPath+" , schemaPath: "+u.util.toQuotedString(a)+" , params: { type: '")+(t?""+n.join(","):""+n)+"' } ",u.opts.messages!==!1&&(k=(k+=" , message: 'should be ")+(t?""+n.join(","):""+n)+"' "),u.opts.verbose&&(k+=" , schema: validate.schema"+r+" , parentSchema: validate.schema"+u.schemaPath+" , data: "+m+" "),k+=" } "):k+=" {} ",g=k,k=R.pop(),!u.compositeRule&&p?u.async?k+=" throw new ValidationError(["+g+"]); ":k+=" validate.errors = ["+g+"]; return false; ":k+=" var err = "+g+";  if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",k+=" } ")),p&&(k=(k+=" if (errors === ")+(F?"0":"errs_"+L)+") { ",s+="}")}}}p&&(k+=" "+s+" "),F?k=k+(N?" if (errors === 0) return data;            else throw new ValidationError(vErrors); ":" validate.errors = vErrors;  return errors === 0;       ")+" }; return validate;":k+=" var "+x+" = errors === errs_"+L+";"}return k;function $(K){for(var Q=K.rules,te=0;te<Q.length;te++)if(M(Q[te]))return 1}function M(K){return u.schema[K.keyword]!==void 0||K.implements&&function(Q){for(var te=Q.implements,he=0;he<te.length;he++)if(u.schema[te[he]]!==void 0)return 1}(K)}}},7931:function(ie,u,V){var X=/^[a-z_$][a-z0-9_$-]*$/i,k=V(1793),N=V(5868);function Z(O,W){Z.errors=null;var F=this._validateKeyword=this._validateKeyword||this.compile(N,!0);if(F(O))return!0;if(Z.errors=F.errors,W)throw new Error("custom keyword definition is invalid: "+this.errorsText(F.errors));return!1}ie.exports={add:function(O,W){var F=this.RULES;if(F.keywords[O])throw new Error("Keyword "+O+" is already defined");if(!X.test(O))throw new Error("Keyword "+O+" is not a valid identifier");if(W){this.validateKeyword(W,!0);var L=W.type;if(Array.isArray(L))for(var C=0;C<L.length;C++)b(O,L[C],W);else b(O,L,W);var m=W.metaSchema;m&&(W.$data&&this._opts.$data&&(m={anyOf:[m,{$ref:"https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#"}]}),W.validateSchema=this.compile(m,!0))}function b(x,p,l){for(var s,n=0;n<F.length;n++){var t=F[n];if(t.type==p){s=t;break}}s||F.push(s={type:p,rules:[]}),l={keyword:x,definition:l,custom:!0,code:k,implements:l.implements},s.rules.push(l),F.custom[x]=l}return F.keywords[O]=F.all[O]=!0,this},get:function(O){var W=this.RULES.custom[O];return W?W.definition:this.RULES.keywords[O]||!1},remove:function(O){var W=this.RULES;delete W.keywords[O],delete W.all[O],delete W.custom[O];for(var F=0;F<W.length;F++)for(var L=W[F].rules,C=0;C<L.length;C++)if(L[C].keyword==O){L.splice(C,1);break}return this},validate:Z}},2303:function(ie){ie.exports=function u(V,X){if(V===X)return!0;if(V&&X&&typeof V=="object"&&typeof X=="object"){if(V.constructor!==X.constructor)return!1;var k,N,Z;if(Array.isArray(V)){if((k=V.length)!=X.length)return!1;for(N=k;N--!=0;)if(!u(V[N],X[N]))return!1}else{if(V.constructor===RegExp)return V.source===X.source&&V.flags===X.flags;if(V.valueOf!==Object.prototype.valueOf)return V.valueOf()===X.valueOf();if(V.toString!==Object.prototype.toString)return V.toString()===X.toString();if((k=(Z=Object.keys(V)).length)!==Object.keys(X).length)return!1;for(N=k;N--!=0;)if(!Object.prototype.hasOwnProperty.call(X,Z[N]))return!1;for(N=k;N--!=0;){var O=Z[N];if(!u(V[O],X[O]))return!1}}return!0}return V!=V&&X!=X}},3508:function(ie){ie.exports=function(u,V){var X,k=typeof(V=typeof(V=V||{})=="function"?{cmp:V}:V).cycles=="boolean"&&V.cycles,N=V.cmp&&(X=V.cmp,function(O){return function(W,F){return W={key:W,value:O[W]},F={key:F,value:O[F]},X(W,F)}}),Z=[];return function O(W){if((W=W&&W.toJSON&&typeof W.toJSON=="function"?W.toJSON():W)!==void 0){if(typeof W=="number")return isFinite(W)?""+W:"null";if(typeof W!="object")return JSON.stringify(W);if(Array.isArray(W)){for(C="[",m=0;m<W.length;m++)m&&(C+=","),C+=O(W[m])||"null";return C+"]"}if(W===null)return"null";if(Z.indexOf(W)!==-1){if(k)return JSON.stringify("__cycle__");throw new TypeError("Converting circular structure to JSON")}for(var F=Z.push(W)-1,L=Object.keys(W).sort(N&&N(W)),C="",m=0;m<L.length;m++){var b=L[m],x=O(W[b]);x&&(C&&(C+=","),C+=JSON.stringify(b)+":"+x)}return Z.splice(F,1),"{"+C+"}"}}(u)}},233:function(ie){ie.exports=function u(L,C){function k(n){return u.insensitive&&(""+n).toLowerCase()||""+n}var N,Z,p=/(^([+\-]?(?:0|[1-9]\d*)(?:\.\d*)?(?:[eE][+\-]?\d+)?)?$|^0x[0-9a-f]+$|\d+)/gi,x=/(^[ ]*|[ ]*$)/g,O=/(^([\w ]+,?[\w ]+)?[\w ]+,?[\w ]+\d+:\d+(:\d+)?[\w ]?|^\d{1,4}[\/\-]\d{1,4}[\/\-]\d{1,4}|^\w+, \w+ \d+, \d{4})/,W=/^0x[0-9a-f]+$/i,F=/^0/,L=k(L).replace(x,"")||"",C=k(C).replace(x,"")||"",m=L.replace(p,"\0$1\0").replace(/\0$/,"").replace(/^\0/,"").split("\0"),b=C.replace(p,"\0$1\0").replace(/\0$/,"").replace(/^\0/,"").split("\0"),x=parseInt(L.match(W),16)||m.length!==1&&L.match(O)&&Date.parse(L),p=parseInt(C.match(W),16)||x&&C.match(O)&&Date.parse(C)||null;if(p){if(x<p)return-1;if(p<x)return 1}for(var l=0,s=Math.max(m.length,b.length);l<s;l++){if(N=!(m[l]||"").match(F)&&parseFloat(m[l])||m[l]||0,Z=!(b[l]||"").match(F)&&parseFloat(b[l])||b[l]||0,isNaN(N)!==isNaN(Z))return isNaN(N)?1:-1;if(typeof N!=typeof Z&&(N+="",Z+=""),N<Z)return-1;if(Z<N)return 1}return 0}},5156:function(ie,u){(function(V){function X(E){return E!==null&&Object.prototype.toString.call(E)==="[object Array]"}function k(E){return E!==null&&Object.prototype.toString.call(E)==="[object Object]"}function N(E,_){if(E!==_){if(Object.prototype.toString.call(E)!==Object.prototype.toString.call(_))return!1;if(X(E)===!0){if(E.length!==_.length)return!1;for(var P=0;P<E.length;P++)if(N(E[P],_[P])===!1)return!1}else{if(k(E)!==!0)return!1;var j,z,D={};for(j in E)if(hasOwnProperty.call(E,j)){if(N(E[j],_[j])===!1)return!1;D[j]=!0}for(z in _)if(hasOwnProperty.call(_,z)&&D[z]!==!0)return!1}}return!0}function Z(E){if(E===""||E===!1||E===null||X(E)&&E.length===0)return!0;if(k(E)){for(var _ in E)if(E.hasOwnProperty(_))return!1;return!0}return!1}var O=typeof String.prototype.trimLeft=="function"?function(E){return E.trimLeft()}:function(E){return E.match(/^\s*(.*)/)[1]},W={0:"number",1:"any",2:"string",3:"array",4:"object",5:"boolean",6:"expression",7:"null",8:"Array<number>",9:"Array<string>"},F="UnquotedIdentifier",L="QuotedIdentifier",C="Rbracket",m="Rparen",b="Comma",x="Colon",p="Rbrace",l="Number",s="Current",n="Expref",t="Pipe",i="Flatten",e="Star",r="Filter",a="Lbrace",o="Lbracket",c="Lparen",h="Literal",A={".":"Dot","*":e,",":b,":":x,"{":a,"}":p,"]":C,"(":c,")":m,"@":s},v={"<":!0,">":!0,"=":!0,"!":!0},d={" ":!0,"	":!0,"\n":!0};function g(E){return"0"<=E&&E<="9"||E==="-"}function y(){}y.prototype={tokenize:function(E){var _,P,j=[];for(this._current=0;this._current<E.length;)if("a"<=(D=E[this._current])&&D<="z"||"A"<=D&&D<="Z"||D==="_")z=this._current,_=this._consumeUnquotedIdentifier(E),j.push({type:F,value:_,start:z});else if(A[E[this._current]]!==void 0)j.push({type:A[E[this._current]],value:E[this._current],start:this._current}),this._current++;else if(g(E[this._current]))P=this._consumeNumber(E),j.push(P);else if(E[this._current]==="[")P=this._consumeLBracket(E),j.push(P);else if(E[this._current]==='"')z=this._current,_=this._consumeQuotedIdentifier(E),j.push({type:L,value:_,start:z});else if(E[this._current]==="'")z=this._current,_=this._consumeRawStringLiteral(E),j.push({type:h,value:_,start:z});else if(E[this._current]==="`"){var z=this._current,D=this._consumeLiteral(E);j.push({type:h,value:D,start:z})}else if(v[E[this._current]]!==void 0)j.push(this._consumeOperator(E));else if(d[E[this._current]]!==void 0)this._current++;else if(E[this._current]==="&")z=this._current,this._current++,E[this._current]==="&"?(this._current++,j.push({type:"And",value:"&&",start:z})):j.push({type:n,value:"&",start:z});else{if(E[this._current]!=="|")throw(D=new Error("Unknown character:"+E[this._current])).name="LexerError",D;z=this._current,this._current++,E[this._current]==="|"?(this._current++,j.push({type:"Or",value:"||",start:z})):j.push({type:t,value:"|",start:z})}return j},_consumeUnquotedIdentifier:function(E){var _,P=this._current;for(this._current++;this._current<E.length&&("a"<=(_=E[this._current])&&_<="z"||"A"<=_&&_<="Z"||"0"<=_&&_<="9"||_==="_");)this._current++;return E.slice(P,this._current)},_consumeQuotedIdentifier:function(E){for(var _=this._current,P=(this._current++,E.length);E[this._current]!=='"'&&this._current<P;){var j=this._current;E[j]!=="\\"||E[j+1]!=="\\"&&E[j+1]!=='"'?j++:j+=2,this._current=j}return this._current++,JSON.parse(E.slice(_,this._current))},_consumeRawStringLiteral:function(E){for(var _=this._current,P=(this._current++,E.length);E[this._current]!=="'"&&this._current<P;){var j=this._current;E[j]!=="\\"||E[j+1]!=="\\"&&E[j+1]!=="'"?j++:j+=2,this._current=j}return this._current++,E.slice(_+1,this._current-1).replace("\\'","'")},_consumeNumber:function(E){for(var _=this._current,P=(this._current++,E.length);g(E[this._current])&&this._current<P;)this._current++;var j=parseInt(E.slice(_,this._current));return{type:l,value:j,start:_}},_consumeLBracket:function(E){var _=this._current;return this._current++,E[this._current]==="?"?(this._current++,{type:r,value:"[?",start:_}):E[this._current]==="]"?(this._current++,{type:i,value:"[]",start:_}):{type:o,value:"[",start:_}},_consumeOperator:function(E){var _=this._current,P=E[_];return this._current++,P==="!"?E[this._current]==="="?(this._current++,{type:"NE",value:"!=",start:_}):{type:"Not",value:"!",start:_}:P==="<"?E[this._current]==="="?(this._current++,{type:"LTE",value:"<=",start:_}):{type:"LT",value:"<",start:_}:P===">"?E[this._current]==="="?(this._current++,{type:"GTE",value:">=",start:_}):{type:"GT",value:">",start:_}:P==="="&&E[this._current]==="="?(this._current++,{type:"EQ",value:"==",start:_}):void 0},_consumeLiteral:function(E){this._current++;for(var _=this._current,P=E.length;E[this._current]!=="`"&&this._current<P;){var j=this._current;E[j]!=="\\"||E[j+1]!=="\\"&&E[j+1]!=="`"?j++:j+=2,this._current=j}return _=(_=O(E.slice(_,this._current))).replace("\\`","`"),_=this._looksLikeJSON(_)?JSON.parse(_):JSON.parse('"'+_+'"'),this._current++,_},_looksLikeJSON:function(E){if(E==="")return!1;if(0<='[{"'.indexOf(E[0])||0<=["true","false","null"].indexOf(E))return!0;if(!(0<="-0123456789".indexOf(E[0])))return!1;try{return JSON.parse(E),!0}catch{return!1}}};var w={};function I(){}function T(E){this.runtime=E}function B(E){this._interpreter=E,this.functionTable={abs:{_func:this._functionAbs,_signature:[{types:[0]}]},avg:{_func:this._functionAvg,_signature:[{types:[8]}]},ceil:{_func:this._functionCeil,_signature:[{types:[0]}]},contains:{_func:this._functionContains,_signature:[{types:[2,3]},{types:[1]}]},ends_with:{_func:this._functionEndsWith,_signature:[{types:[2]},{types:[2]}]},floor:{_func:this._functionFloor,_signature:[{types:[0]}]},length:{_func:this._functionLength,_signature:[{types:[2,3,4]}]},map:{_func:this._functionMap,_signature:[{types:[6]},{types:[3]}]},max:{_func:this._functionMax,_signature:[{types:[8,9]}]},merge:{_func:this._functionMerge,_signature:[{types:[4],variadic:!0}]},max_by:{_func:this._functionMaxBy,_signature:[{types:[3]},{types:[6]}]},sum:{_func:this._functionSum,_signature:[{types:[8]}]},starts_with:{_func:this._functionStartsWith,_signature:[{types:[2]},{types:[2]}]},min:{_func:this._functionMin,_signature:[{types:[8,9]}]},min_by:{_func:this._functionMinBy,_signature:[{types:[3]},{types:[6]}]},type:{_func:this._functionType,_signature:[{types:[1]}]},keys:{_func:this._functionKeys,_signature:[{types:[4]}]},values:{_func:this._functionValues,_signature:[{types:[4]}]},sort:{_func:this._functionSort,_signature:[{types:[9,8]}]},sort_by:{_func:this._functionSortBy,_signature:[{types:[3]},{types:[6]}]},join:{_func:this._functionJoin,_signature:[{types:[2]},{types:[9]}]},reverse:{_func:this._functionReverse,_signature:[{types:[2,3]}]},to_array:{_func:this._functionToArray,_signature:[{types:[1]}]},to_string:{_func:this._functionToString,_signature:[{types:[1]}]},to_number:{_func:this._functionToNumber,_signature:[{types:[1]}]},not_null:{_func:this._functionNotNull,_signature:[{types:[1],variadic:!0}]}}}w.EOF=0,w[F]=0,w[L]=0,w[C]=0,w[m]=0,w[b]=0,w[p]=0,w[l]=0,w[s]=0,w[n]=0,w.Pipe=1,w.Or=2,w.And=3,w.EQ=5,w.GT=5,w.LT=5,w.GTE=5,w.LTE=5,w.NE=5,w[i]=9,w.Star=20,w[r]=21,w.Dot=40,w.Not=45,w[a]=50,w[o]=55,w[c]=60,I.prototype={parse:function(P){this._loadTokens(P),this.index=0;var _,P=this.expression(0);if(this._lookahead(0)!=="EOF")throw _=this._lookaheadToken(0),(_=new Error("Unexpected token type: "+_.type+", value: "+_.value)).name="ParserError",_;return P},_loadTokens:function(E){var _=new y().tokenize(E);_.push({type:"EOF",value:"",start:E.length}),this.tokens=_},expression:function(E){for(var _=this._lookaheadToken(0),P=(this._advance(),this.nud(_)),j=this._lookahead(0);E<w[j];)this._advance(),P=this.led(j,P),j=this._lookahead(0);return P},_lookahead:function(E){return this.tokens[this.index+E].type},_lookaheadToken:function(E){return this.tokens[this.index+E]},_advance:function(){this.index++},nud:function(E){var _,P;switch(E.type){case h:return{type:"Literal",value:E.value};case F:return{type:"Field",name:E.value};case L:var j={type:"Field",name:E.value};if(this._lookahead(0)===c)throw new Error("Quoted identifier not allowed for function names.");return j;case"Not":return{type:"NotExpression",children:[_=this.expression(w.Not)]};case e:return _=null,{type:"ValueProjection",children:[{type:"Identity"},_=this._lookahead(0)===C?{type:"Identity"}:this._parseProjectionRHS(w.Star)]};case r:return this.led(E.type,{type:"Identity"});case a:return this._parseMultiselectHash();case i:return{type:"Projection",children:[{type:i,children:[{type:"Identity"}]},_=this._parseProjectionRHS(w.Flatten)]};case o:return this._lookahead(0)===l||this._lookahead(0)===x?(_=this._parseIndexExpression(),this._projectIfSlice({type:"Identity"},_)):this._lookahead(0)===e&&this._lookahead(1)===C?(this._advance(),this._advance(),{type:"Projection",children:[{type:"Identity"},_=this._parseProjectionRHS(w.Star)]}):this._parseMultiselectList();case s:return{type:s};case n:return{type:"ExpressionReference",children:[P=this.expression(w.Expref)]};case c:for(var z=[];this._lookahead(0)!==m;)this._lookahead(0)===s?(P={type:s},this._advance()):P=this.expression(0),z.push(P);return this._match(m),z[0];default:this._errorToken(E)}},led:function(E,_){var P;switch(E){case"Dot":var j=w.Dot;return this._lookahead(0)!==e?{type:"Subexpression",children:[_,P=this._parseDotRHS(j)]}:(this._advance(),{type:"ValueProjection",children:[_,P=this._parseProjectionRHS(j)]});case t:return P=this.expression(w.Pipe),{type:t,children:[_,P]};case"Or":return{type:"OrExpression",children:[_,P=this.expression(w.Or)]};case"And":return{type:"AndExpression",children:[_,P=this.expression(w.And)]};case c:for(var z,j=_.name,D=[];this._lookahead(0)!==m;)this._lookahead(0)===s?(z={type:s},this._advance()):z=this.expression(0),this._lookahead(0)===b&&this._match(b),D.push(z);return this._match(m),{type:"Function",name:j,children:D};case r:return j=this.expression(0),this._match(C),{type:"FilterProjection",children:[_,P=this._lookahead(0)===i?{type:"Identity"}:this._parseProjectionRHS(w.Filter),j]};case i:return{type:"Projection",children:[{type:i,children:[_]},this._parseProjectionRHS(w.Flatten)]};case"EQ":case"NE":case"GT":case"GTE":case"LT":case"LTE":return this._parseComparator(_,E);case o:return j=this._lookaheadToken(0),j.type===l||j.type===x?(P=this._parseIndexExpression(),this._projectIfSlice(_,P)):(this._match(e),this._match(C),{type:"Projection",children:[_,P=this._parseProjectionRHS(w.Star)]});default:this._errorToken(this._lookaheadToken(0))}},_match:function(E){var _;if(this._lookahead(0)!==E)throw _=this._lookaheadToken(0),(E=new Error("Expected "+E+", got: "+_.type)).name="ParserError",E;this._advance()},_errorToken:function(E){throw E=new Error("Invalid token ("+E.type+'): "'+E.value+'"'),E.name="ParserError",E},_parseIndexExpression:function(){var E;return this._lookahead(0)===x||this._lookahead(1)===x?this._parseSliceExpression():(E={type:"Index",value:this._lookaheadToken(0).value},this._advance(),this._match(C),E)},_projectIfSlice:function(E,_){return E={type:"IndexExpression",children:[E,_]},_.type==="Slice"?{type:"Projection",children:[E,this._parseProjectionRHS(w.Star)]}:E},_parseSliceExpression:function(){for(var E,_=[null,null,null],P=0,j=this._lookahead(0);j!==C&&P<3;){if(j===x)P++;else{if(j!==l)throw E=this._lookahead(0),(E=new Error("Syntax error, unexpected token: "+E.value+"("+E.type+")")).name="Parsererror",E;_[P]=this._lookaheadToken(0).value}this._advance(),j=this._lookahead(0)}return this._match(C),{type:"Slice",children:_}},_parseComparator:function(E,_){return{type:"Comparator",name:_,children:[E,this.expression(w[_])]}},_parseDotRHS:function(E){var _=this._lookahead(0);return 0<=[F,L,e].indexOf(_)?this.expression(E):_===o?(this._match(o),this._parseMultiselectList()):_===a?(this._match(a),this._parseMultiselectHash()):void 0},_parseProjectionRHS:function(E){var _,P;if(w[this._lookahead(0)]<10)_={type:"Identity"};else if(this._lookahead(0)===o)_=this.expression(E);else if(this._lookahead(0)===r)_=this.expression(E);else{if(this._lookahead(0)!=="Dot")throw P=this._lookaheadToken(0),(P=new Error("Sytanx error, unexpected token: "+P.value+"("+P.type+")")).name="ParserError",P;this._match("Dot"),_=this._parseDotRHS(E)}return _},_parseMultiselectList:function(){for(var E=[];this._lookahead(0)!==C;){var _=this.expression(0);if(E.push(_),this._lookahead(0)===b&&(this._match(b),this._lookahead(0)===C))throw new Error("Unexpected token Rbracket")}return this._match(C),{type:"MultiSelectList",children:E}},_parseMultiselectHash:function(){for(var E,_,P=[],j=[F,L];;){if(E=this._lookaheadToken(0),j.indexOf(E.type)<0)throw new Error("Expecting an identifier token, got: "+E.type);if(E=E.value,this._advance(),this._match(x),_=this.expression(0),P.push({type:"KeyValuePair",name:E,value:_}),this._lookahead(0)===b)this._match(b);else if(this._lookahead(0)===p){this._match(p);break}}return{type:"MultiSelectHash",children:P}}},T.prototype={search:function(E,_){return this.visit(E,_)},visit:function(E,_){var P,j,z,D,Y,R;switch(E.type){case"Field":return _!==null&&k(_)?(H=_[E.name])===void 0?null:H:null;case"Subexpression":for($=this.visit(E.children[0],_),te=1;te<E.children.length;te++)if(($=this.visit(E.children[1],$))===null)return null;return $;case"IndexExpression":return Y=this.visit(E.children[0],_),this.visit(E.children[1],Y);case"Index":return X(_)?($=_[H=(H=E.value)<0?_.length+H:H])===void 0?null:$:null;case"Slice":if(!X(_))return null;var H=E.children.slice(0),H=this.computeSliceParams(_.length,H),G=H[0],f=H[1],S=H[2],$=[];if(0<S)for(te=G;te<f;te+=S)$.push(_[te]);else for(te=G;f<te;te+=S)$.push(_[te]);return $;case"Projection":var M=this.visit(E.children[0],_);if(!X(M))return null;for(K=[],te=0;te<M.length;te++)(j=this.visit(E.children[1],M[te]))!==null&&K.push(j);return K;case"ValueProjection":if(!k(M=this.visit(E.children[0],_)))return null;for(var K=[],Q=function(Te){for(var _e=Object.keys(Te),Se=[],ue=0;ue<_e.length;ue++)Se.push(Te[_e[ue]]);return Se}(M),te=0;te<Q.length;te++)(j=this.visit(E.children[1],Q[te]))!==null&&K.push(j);return K;case"FilterProjection":if(!X(M=this.visit(E.children[0],_)))return null;var he=[],Ae=[];for(te=0;te<M.length;te++)Z(P=this.visit(E.children[2],M[te]))||he.push(M[te]);for(var ge=0;ge<he.length;ge++)(j=this.visit(E.children[1],he[ge]))!==null&&Ae.push(j);return Ae;case"Comparator":switch(z=this.visit(E.children[0],_),D=this.visit(E.children[1],_),E.name){case"EQ":$=N(z,D);break;case"NE":$=!N(z,D);break;case"GT":$=D<z;break;case"GTE":$=D<=z;break;case"LT":$=z<D;break;case"LTE":$=z<=D;break;default:throw new Error("Unknown comparator: "+E.name)}return $;case i:var Ce=this.visit(E.children[0],_);if(!X(Ce))return null;var ve=[];for(te=0;te<Ce.length;te++)X(j=Ce[te])?ve.push.apply(ve,j):ve.push(j);return ve;case"Identity":return _;case"MultiSelectList":if(_===null)return null;for(K=[],te=0;te<E.children.length;te++)K.push(this.visit(E.children[te],_));return K;case"MultiSelectHash":if(_===null)return null;for(K={},te=0;te<E.children.length;te++)K[(R=E.children[te]).name]=this.visit(R.value,_);return K;case"OrExpression":return P=Z(P=this.visit(E.children[0],_))?this.visit(E.children[1],_):P;case"AndExpression":return Z(z=this.visit(E.children[0],_))===!0?z:this.visit(E.children[1],_);case"NotExpression":return Z(z=this.visit(E.children[0],_));case"Literal":return E.value;case t:return Y=this.visit(E.children[0],_),this.visit(E.children[1],Y);case s:return _;case"Function":var ye=[];for(te=0;te<E.children.length;te++)ye.push(this.visit(E.children[te],_));return this.runtime.callFunction(E.name,ye);case"ExpressionReference":return H=E.children[0],H.jmespathType=n,H;default:throw new Error("Unknown node type: "+E.type)}},computeSliceParams:function(E,P){var D=P[0],Y=P[1],P=P[2],j=[null,null,null];if(P===null)P=1;else if(P===0)throw(z=new Error("Invalid slice, step cannot be 0")).name="RuntimeError",z;var z=P<0,D=D===null?z?E-1:0:this.capSliceRange(E,D,P),Y=Y===null?z?-1:E:this.capSliceRange(E,Y,P);return j[0]=D,j[1]=Y,j[2]=P,j},capSliceRange:function(E,_,P){return _<0?(_+=E)<0&&(_=P<0?-1:0):E<=_&&(_=P<0?E-1:E),_}},B.prototype={callFunction:function(E,_){var P=this.functionTable[E];if(P===void 0)throw new Error("Unknown function: "+E+"()");return this._validateArgs(E,_,P._signature),P._func.call(this,_)},_validateArgs:function(E,_,P){var j;if(P[P.length-1].variadic){if(_.length<P.length)throw j=P.length===1?" argument":" arguments",new Error("ArgumentError: "+E+"() takes at least"+P.length+j+" but received "+_.length)}else if(_.length!==P.length)throw j=P.length===1?" argument":" arguments",new Error("ArgumentError: "+E+"() takes "+P.length+j+" but received "+_.length);for(var z=0;z<P.length;z++){for(var D,Y=!1,R=P[z].types,H=this._getTypeName(_[z]),G=0;G<R.length;G++)if(this._typeMatches(H,R[G],_[z])){Y=!0;break}if(!Y)throw D=R.map(function(f){return W[f]}).join(","),new Error("TypeError: "+E+"() expected argument "+(z+1)+" to be type "+D+" but received type "+W[H]+" instead.")}},_typeMatches:function(E,_,P){if(_===1)return!0;if(_!==9&&_!==8&&_!==3)return E===_;if(_===3)return E===3;if(E===3){var j;_===8?j=0:_===9&&(j=2);for(var z=0;z<P.length;z++)if(!this._typeMatches(this._getTypeName(P[z]),j,P[z]))return!1;return!0}},_getTypeName:function(E){switch(Object.prototype.toString.call(E)){case"[object String]":return 2;case"[object Number]":return 0;case"[object Array]":return 3;case"[object Boolean]":return 5;case"[object Null]":return 7;case"[object Object]":return E.jmespathType===n?6:4}},_functionStartsWith:function(E){return E[0].lastIndexOf(E[1])===0},_functionEndsWith:function(P){var _=P[0],P=P[1];return _.indexOf(P,_.length-P.length)!==-1},_functionReverse:function(E){var _;if(this._getTypeName(E[0])!==2)return(_=E[0].slice(0)).reverse(),_;for(var P=E[0],j="",z=P.length-1;0<=z;z--)j+=P[z];return j},_functionAbs:function(E){return Math.abs(E[0])},_functionCeil:function(E){return Math.ceil(E[0])},_functionAvg:function(E){for(var _=0,P=E[0],j=0;j<P.length;j++)_+=P[j];return _/P.length},_functionContains:function(E){return 0<=E[0].indexOf(E[1])},_functionFloor:function(E){return Math.floor(E[0])},_functionLength:function(E){return(k(E[0])?Object.keys(E[0]):E[0]).length},_functionMap:function(E){for(var _=[],P=this._interpreter,j=E[0],z=E[1],D=0;D<z.length;D++)_.push(P.visit(j,z[D]));return _},_functionMerge:function(E){for(var _={},P=0;P<E.length;P++){var j,z=E[P];for(j in z)_[j]=z[j]}return _},_functionMax:function(E){if(0<E[0].length){if(this._getTypeName(E[0][0])===0)return Math.max.apply(Math,E[0]);for(var _=E[0],P=_[0],j=1;j<_.length;j++)P.localeCompare(_[j])<0&&(P=_[j]);return P}return null},_functionMin:function(E){if(0<E[0].length){if(this._getTypeName(E[0][0])===0)return Math.min.apply(Math,E[0]);for(var _=E[0],P=_[0],j=1;j<_.length;j++)_[j].localeCompare(P)<0&&(P=_[j]);return P}return null},_functionSum:function(E){for(var _=0,P=E[0],j=0;j<P.length;j++)_+=P[j];return _},_functionType:function(E){switch(this._getTypeName(E[0])){case 0:return"number";case 2:return"string";case 3:return"array";case 4:return"object";case 5:return"boolean";case 6:return"expref";case 7:return"null"}},_functionKeys:function(E){return Object.keys(E[0])},_functionValues:function(E){for(var _=E[0],P=Object.keys(_),j=[],z=0;z<P.length;z++)j.push(_[P[z]]);return j},_functionJoin:function(E){var _=E[0];return E[1].join(_)},_functionToArray:function(E){return this._getTypeName(E[0])===3?E[0]:[E[0]]},_functionToString:function(E){return this._getTypeName(E[0])===2?E[0]:JSON.stringify(E[0])},_functionToNumber:function(E){var _=this._getTypeName(E[0]);return _===0?E[0]:_!==2||(_=+E[0],isNaN(_))?null:_},_functionNotNull:function(E){for(var _=0;_<E.length;_++)if(this._getTypeName(E[_])!==7)return E[_];return null},_functionSort:function(E){return E=E[0].slice(0),E.sort(),E},_functionSortBy:function(E){var _=E[0].slice(0);if(_.length!==0){var P=this._interpreter,j=E[1],z=this._getTypeName(P.visit(j,_[0]));if([0,2].indexOf(z)<0)throw new Error("TypeError");for(var D=this,Y=[],R=0;R<_.length;R++)Y.push([R,_[R]]);Y.sort(function(G,f){var S=P.visit(j,G[1]),$=P.visit(j,f[1]);if(D._getTypeName(S)!==z)throw new Error("TypeError: expected "+z+", received "+D._getTypeName(S));if(D._getTypeName($)!==z)throw new Error("TypeError: expected "+z+", received "+D._getTypeName($));return $<S?1:S<$?-1:G[0]-f[0]});for(var H=0;H<Y.length;H++)_[H]=Y[H][1]}return _},_functionMaxBy:function(E){for(var _,P,j=E[1],z=E[0],D=this.createKeyFunction(j,[0,2]),Y=-1/0,R=0;R<z.length;R++)Y<(P=D(z[R]))&&(Y=P,_=z[R]);return _},_functionMinBy:function(E){for(var _,P,j=E[1],z=E[0],D=this.createKeyFunction(j,[0,2]),Y=1/0,R=0;R<z.length;R++)(P=D(z[R]))<Y&&(Y=P,_=z[R]);return _},createKeyFunction:function(E,_){var P=this,j=this._interpreter;return function(Y){var D,Y=j.visit(E,Y);if(_.indexOf(P._getTypeName(Y))<0)throw D="TypeError: expected one of "+_+", received "+P._getTypeName(Y),new Error(D);return Y}}},V.tokenize=function(E){return new y().tokenize(E)},V.compile=function(E){return new I().parse(E)},V.search=function(E,_){var P=new I,j=new T(z=new B),z=(z._interpreter=j,P.parse(_));return j.search(z,E)},V.strictDeepEqual=N})(u)},500:function(ie){var u=ie.exports=function(X,k,N){typeof k=="function"&&(N=k,k={}),function Z(O,W,F,L,C,m,b,x,p,l){if(L&&typeof L=="object"&&!Array.isArray(L)){for(var s in W(L,C,m,b,x,p,l),L){var n=L[s];if(Array.isArray(n)){if(s in u.arrayKeywords)for(var t=0;t<n.length;t++)Z(O,W,F,n[t],C+"/"+s+"/"+t,m,C,s,L,t)}else if(s in u.propsKeywords){if(n&&typeof n=="object")for(var i in n)Z(O,W,F,n[i],C+"/"+s+"/"+V(i),m,C,s,L,i)}else(s in u.keywords||O.allKeys&&!(s in u.skipKeywords))&&Z(O,W,F,n,C+"/"+s,m,C,s,L)}F(L,C,m,b,x,p,l)}}(k,typeof(N=k.cb||N)=="function"?N:N.pre||function(){},N.post||function(){},X,"",X)};function V(X){return X.replace(/~/g,"~0").replace(/\//g,"~1")}u.keywords={additionalItems:!0,items:!0,contains:!0,additionalProperties:!0,propertyNames:!0,not:!0},u.arrayKeywords={items:!0,allOf:!0,anyOf:!0,oneOf:!0},u.propsKeywords={definitions:!0,properties:!0,patternProperties:!0,dependencies:!0},u.skipKeywords={default:!0,enum:!0,const:!0,required:!0,maximum:!0,minimum:!0,exclusiveMaximum:!0,exclusiveMinimum:!0,multipleOf:!0,maxLength:!0,minLength:!0,pattern:!0,format:!0,maxItems:!0,minItems:!0,uniqueItems:!0,maxProperties:!0,minProperties:!0}},7026:function(ie,u){var V={b:"\b",f:"\f",n:`
`,r:"\r",t:"	",'"':'"',"/":"/","\\":"\\"},X="a".charCodeAt(),k=(u.parse=function(l,s,n){var t={},i=0,e=0,r=0,a=n&&n.bigint&&typeof BigInt!="undefined";return{data:o("",!0),pointers:t};function o(_,P){c(),y(_,"value");var j,z=v();switch(z){case"t":A("rue"),j=!0;break;case"f":A("alse"),j=!1;break;case"n":A("ull"),j=null;break;case'"':j=h();break;case"[":j=function(D){c();var Y=[],R=0;if(v()!="]")for(d();;){var H=D+"/"+R,H=(Y.push(o(H)),c(),v());if(H=="]")break;H!=","&&B(),c(),R++}return Y}(_);break;case"{":j=function(D){c();var Y={};if(v()!="}")for(d();;){var G=I(),R=(v()!='"'&&B(),h()),H=D+"/"+p(R),G=(w(H,"key",G),y(H,"keyEnd"),c(),v()!=":"&&B(),c(),Y[R]=o(H),c(),v());if(G=="}")break;G!=","&&B(),c()}return Y}(_);break;default:d(),0<="-0123456789".indexOf(z)?j=function(){var D="",Y=!0;l[r]=="-"&&(D+=v()),D+=(l[r]=="0"?v:g)(),l[r]=="."&&(D+=v()+g(),Y=!1),l[r]!="e"&&l[r]!="E"||(D+=v(),l[r]!="+"&&l[r]!="-"||(D+=v()),D+=g(),Y=!1);var R=+D;return a&&Y&&(R>Number.MAX_SAFE_INTEGER||R<Number.MIN_SAFE_INTEGER)?BigInt(D):R}():T()}return y(_,"valueEnd"),c(),P&&r<l.length&&T(),j}function c(){e:for(;r<l.length;){switch(l[r]){case" ":e++;break;case"	":e+=4;break;case"\r":e=0;break;case`
`:e=0,i++;break;default:break e}r++}}function h(){for(var _,P="";(_=v())!='"';)_=="\\"?(_=v())in V?P+=V[_]:_=="u"?P+=function(){for(var j=4,z=0;j--;){z<<=4;var D=v().toLowerCase();"a"<=D&&D<="f"?z+=D.charCodeAt()-X+10:"0"<=D&&D<="9"?z+=+D:B()}return String.fromCharCode(z)}():B():P+=_;return P}function A(_){for(var P=0;P<_.length;P++)v()!==_[P]&&B()}function v(){E();var _=l[r];return r++,e++,_}function d(){r--,e--}function g(){for(var _="";"0"<=l[r]&&l[r]<="9";)_+=v();if(_.length)return _;E(),T()}function y(_,P){w(_,P,I())}function w(_,P,j){t[_]=t[_]||{},t[_][P]=j}function I(){return{line:i,column:e,pos:r}}function T(){throw new SyntaxError("Unexpected token "+l[r]+" in JSON at position "+r)}function B(){d(),T()}function E(){if(r>=l.length)throw new SyntaxError("Unexpected end of JSON input")}},u.stringify=function(l,s,n){if(N(l)){var t=0;switch(typeof(e=typeof n=="object"?n.space:n)){case"number":var i=10<e?10:e<0?0:Math.floor(e),e=i&&T(i," "),r=i,a=i;break;case"string":e=e.slice(0,10);for(var o=a=r=0;o<e.length;o++){switch(e[o]){case" ":a++;break;case"	":a+=4;break;case"\r":a=0;break;case`
`:a=0,t++;break;default:throw new Error("whitespace characters not allowed in JSON")}r++}break;default:e=void 0}var c="",h={},A=0,v=0,d=0,g=n&&n.es6&&typeof Map=="function";return function B(E,_,P){switch(I(P,"value"),typeof E){case"number":case"bigint":case"boolean":y(""+E);break;case"string":y(m(E));break;case"object":E===null?y("null"):typeof E.toJSON=="function"?y(m(E.toJSON())):Array.isArray(E)?j():g?E.constructor.BYTES_PER_ELEMENT?j():E instanceof Map?D():E instanceof Set?D(!0):z():z()}I(P,"valueEnd");function j(){if(E.length){y("[");for(var Y=_+1,R=0;R<E.length;R++){R&&y(","),w(Y);var H=N(E[R])?E[R]:null,G=P+"/"+R;B(H,Y,G)}w(_),y("]")}else y("[]")}function z(){var Y=Object.keys(E);if(Y.length){y("{");for(var R=_+1,H=0;H<Y.length;H++){var G,f=Y[H],S=E[f];N(S)&&(H&&y(","),G=P+"/"+p(f),w(R),I(G,"key"),y(m(f)),I(G,"keyEnd"),y(":"),e&&y(" "),B(S,R,G))}w(_),y("}")}else y("{}")}function D(Y){if(E.size){y("{");for(var R=_+1,H=!0,G=E.entries(),f=G.next();!f.done;){var S,M=f.value,$=M[0],M=!!Y||M[1];N(M)&&(H||y(","),H=!1,S=P+"/"+p($),w(R),I(S,"key"),y(m($)),I(S,"keyEnd"),y(":"),e&&y(" "),B(M,R,S)),f=G.next()}w(_),y("}")}else y("{}")}}(l,0,""),{json:c,pointers:h}}function y(B){v+=B.length,d+=B.length,c+=B}function w(B){if(e){for(c+=`
`+T(B,e),A++,v=0;B--;)t?(A+=t,v=a):v+=a,d+=r;d+=1}}function I(B,E){h[B]=h[B]||{},h[B][E]={line:A,column:v,pos:d}}function T(B,E){return Array(B+1).join(E)}},["number","bigint","boolean","string","object"]);function N(l){return 0<=k.indexOf(typeof l)}var Z=/"|\\/g,O=/[\b]/g,W=/\f/g,F=/\n/g,L=/\r/g,C=/\t/g;function m(l){return'"'+(l=l.replace(Z,"\\$&").replace(W,"\\f").replace(O,"\\b").replace(F,"\\n").replace(L,"\\r").replace(C,"\\t"))+'"'}var b=/~/g,x=/\//g;function p(l){return l.replace(b,"~0").replace(x,"~1")}},483:function(ie,u){var V,X;(function(){X=[],(X=typeof(V=function(){function k(n){return typeof Node=="object"?n instanceof Node:n&&typeof n=="object"&&typeof n.nodeType=="number"}function N(n){return typeof n=="string"}function Z(){var n=[];return{watch:n.push.bind(n),trigger:function(t,i){for(var e=!0,r={detail:i,preventDefault:function(){e=!1}},a=0;a<n.length;a++)n[a](t,r);return e}}}function O(n){return window.getComputedStyle(n).display==="none"}function W(n){this.elem=n}function F(n,t){return W.make(n("parent")).clazz("pico-overlay").clazz(n("overlayClass","")).stylize({display:"none",position:"fixed",top:"0px",left:"0px",height:"100%",width:"100%",zIndex:1e4}).stylize(n("overlayStyles",{opacity:.5,background:"#000"})).onClick(function(){n("overlayClose",!0)&&t()})}W.make=function(n,t){typeof n=="string"&&(n=document.querySelector(n));var i=document.createElement(t||"div");return(n||document.body).appendChild(i),new W(i)},W.prototype={child:function(n){return W.make(this.elem,n)},stylize:function(n){n=n||{},typeof n.opacity!="undefined"&&(n.filter="alpha(opacity="+n.opacity*100+")");for(var t in n)n.hasOwnProperty(t)&&(this.elem.style[t]=n[t]);return this},clazz:function(n){return this.elem.className+=" "+n,this},html:function(n){return k(n)?this.elem.appendChild(n):this.elem.innerHTML=n,this},onClick:function(n){return this.elem.addEventListener("click",n),this},destroy:function(){this.elem.parentNode.removeChild(this.elem)},hide:function(){this.elem.style.display="none"},show:function(){this.elem.style.display="block"},attr:function(n,t){return t!==void 0&&this.elem.setAttribute(n,t),this},anyAncestor:function(n){for(var t=this.elem;t;){if(n(new W(t)))return!0;t=t.parentNode}return!1},isVisible:function(){return!O(this.elem)}};var L=1;function C(n,t){var i=n("width","auto");typeof i=="number"&&(i=""+i+"px");var e=n("modalId","pico-"+L++),r=W.make(n("parent")).clazz("pico-content").clazz(n("modalClass","")).stylize({display:"none",position:"fixed",zIndex:10001,left:"50%",top:"38.1966%",maxHeight:"90%",boxSizing:"border-box",width:i,"-ms-transform":"translate(-50%,-38.1966%)","-moz-transform":"translate(-50%,-38.1966%)","-webkit-transform":"translate(-50%,-38.1966%)","-o-transform":"translate(-50%,-38.1966%)",transform:"translate(-50%,-38.1966%)"}).stylize(n("modalStyles",{overflow:"auto",backgroundColor:"white",padding:"20px",borderRadius:"5px"})).html(n("content")).attr("id",e).attr("role","dialog").attr("aria-labelledby",n("ariaLabelledBy")).attr("aria-describedby",n("ariaDescribedBy",e)).onClick(function(a){var o=new W(a.target).anyAncestor(function(c){return/\bpico-close\b/.test(c.elem.className)});o&&t()});return r}function m(n,t){if(t("closeButton",!0))return n.child("button").html(t("closeHtml","&#xD7;")).clazz("pico-close").clazz(t("closeClass","")).stylize(t("closeStyles",{borderRadius:"2px",border:0,padding:0,cursor:"pointer",height:"15px",width:"15px",position:"absolute",top:"5px",right:"5px",fontSize:"16px",textAlign:"center",lineHeight:"15px",background:"#CCC"})).attr("aria-label",t("close-label","Close"))}function b(n){return function(){return n().elem}}var x=Z(),p=Z();function l(n,t){function i(c,h){var A=c.msMatchesSelector||c.webkitMatchesSelector||c.matches;return A.call(c,h)}function e(c){return O(c)||i(c,":disabled")||c.hasAttribute("contenteditable")?!1:c.hasAttribute("tabindex")||i(c,"input,select,textarea,button,a[href],area[href],iframe")}function r(c){for(var h=c.getElementsByTagName("*"),A=0;A<h.length;A++)if(e(h[A]))return h[A]}function a(c){for(var h=c.getElementsByTagName("*"),A=h.length;A--;)if(e(h[A]))return h[A]}var o;n.beforeShow(function(){o=document.activeElement}),n.afterShow(function(){if(t()){var h=r(n.modalElem());h&&h.focus()}}),n.afterClose(function(){t()&&o&&o.focus(),o=null}),p.watch(function(h){if(t()&&n.isVisible()){var A=r(n.modalElem()),v=a(n.modalElem()),d=h.shiftKey?A:v;d===document.activeElement&&((h.shiftKey?v:A).focus(),h.preventDefault())}})}function s(n,t){var i,e=new W(document.body);n.beforeShow(function(){i=e.elem.style.overflow,t()&&e.stylize({overflow:"hidden"})}),n.afterClose(function(){e.stylize({overflow:i})})}return document.documentElement.addEventListener("keydown",function(t){var i=t.which||t.keyCode;i===27?x.trigger():i===9&&p.trigger(t)}),function(t){(N(t)||k(t))&&(t={content:t});var i=Z(),e=Z(),r=Z(),a=Z(),o=Z();function c(B,E){var _=t[B];return typeof _=="function"&&(_=_(E)),_===void 0?E:_}var h=T.bind(window,"modal"),A=T.bind(window,"overlay"),v=T.bind(window,"close"),d;function g(B){A().hide(),h().hide(),o.trigger(d,B)}function y(B){a.trigger(d,B)&&g(B)}function w(B){return function(){return B.apply(this,arguments),d}}var I;function T(B,E){if(!I){var _=C(c,y);I={modal:_,overlay:F(c,y),close:m(_,c)},i.trigger(d,E)}return I[B]}return d={modalElem:b(h),closeElem:b(v),overlayElem:b(A),buildDom:w(T.bind(null,null)),isVisible:function(){return!!(I&&h&&h().isVisible())},show:function(B){return e.trigger(d,B)&&(A().show(),v(),h().show(),r.trigger(d,B)),this},close:w(y),forceClose:w(g),destroy:function(){h().destroy(),A().destroy(),A=h=v=void 0},options:function(B){Object.keys(B).map(function(E){t[E]=B[E]})},afterCreate:w(i.watch),beforeShow:w(e.watch),afterShow:w(r.watch),beforeClose:w(a.watch),afterClose:w(o.watch)},l(d,c.bind(null,"focus",!0)),s(d,c.bind(null,"bodyOverflow",!0)),x.watch(function(){c("escCloses",!0)&&d.isVisible()&&d.close()}),d}})=="function"?V.apply(u,X):V)!==void 0&&(ie.exports=X)})()},7533:function(ie,u){/** @license URI.js v4.4.1 (c) 2011 Gary Court. License: http://github.com/garycourt/uri-js */(function(V){function X(){for(var q=arguments.length,U=Array(q),ee=0;ee<q;ee++)U[ee]=arguments[ee];if(U.length>1){U[0]=U[0].slice(0,-1);for(var se=U.length-1,re=1;re<se;++re)U[re]=U[re].slice(1,-1);return U[se]=U[se].slice(1),U.join("")}else return U[0]}function k(q){return"(?:"+q+")"}function N(q){return q===void 0?"undefined":q===null?"null":Object.prototype.toString.call(q).split(" ").pop().split("]").shift().toLowerCase()}function Z(q){return q.toUpperCase()}function O(q){return q!=null?q instanceof Array?q:typeof q.length!="number"||q.split||q.setInterval||q.call?[q]:Array.prototype.slice.call(q):[]}function W(q,U){var ee=q;if(U)for(var se in U)ee[se]=U[se];return ee}function F(q){var U="[A-Za-z]",ee="[0-9]",se=X(ee,"[A-Fa-f]"),re=k(k("%[EFef]"+se+"%"+se+se+"%"+se+se)+"|"+k("%[89A-Fa-f]"+se+"%"+se+se)+"|"+k("%"+se+se)),Ee="[\\:\\/\\?\\#\\[\\]\\@]",Re="[\\!\\$\\&\\'\\(\\)\\*\\+\\,\\;\\=]",Pe=X(Ee,Re),He=q?"[\\xA0-\\u200D\\u2010-\\u2029\\u202F-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF]":"[]",Ke=q?"[\\uE000-\\uF8FF]":"[]",Ne=X(U,ee,"[\\-\\.\\_\\~]",He);k(U+X(U,ee,"[\\+\\-\\.]")+"*"),k(k(re+"|"+X(Ne,Re,"[\\:]"))+"*");var je=k(k("25[0-5]")+"|"+k("2[0-4]"+ee)+"|"+k("1"+ee+ee)+"|"+k("0?[1-9]"+ee)+"|0?0?"+ee),ze=k(je+"\\."+je+"\\."+je+"\\."+je),Le=k(se+"{1,4}"),Ze=k(k(Le+"\\:"+Le)+"|"+ze),Xe=k(k(Le+"\\:")+"{6}"+Ze),Oe=k("\\:\\:"+k(Le+"\\:")+"{5}"+Ze),ct=k(k(Le)+"?\\:\\:"+k(Le+"\\:")+"{4}"+Ze),nt=k(k(k(Le+"\\:")+"{0,1}"+Le)+"?\\:\\:"+k(Le+"\\:")+"{3}"+Ze),ot=k(k(k(Le+"\\:")+"{0,2}"+Le)+"?\\:\\:"+k(Le+"\\:")+"{2}"+Ze),pt=k(k(k(Le+"\\:")+"{0,3}"+Le)+"?\\:\\:"+Le+"\\:"+Ze),dt=k(k(k(Le+"\\:")+"{0,4}"+Le)+"?\\:\\:"+Ze),et=k(k(k(Le+"\\:")+"{0,5}"+Le)+"?\\:\\:"+Le),rt=k(k(k(Le+"\\:")+"{0,6}"+Le)+"?\\:\\:"),ht=k([Xe,Oe,ct,nt,ot,pt,dt,et,rt].join("|")),lt=k(k(Ne+"|"+re)+"+");k("[vV]"+se+"+\\."+X(Ne,Re,"[\\:]")+"+"),k(k(re+"|"+X(Ne,Re))+"*");var Ct=k(re+"|"+X(Ne,Re,"[\\:\\@]"));return k(k(re+"|"+X(Ne,Re,"[\\@]"))+"+"),k(k(Ct+"|"+X("[\\/\\?]",Ke))+"*"),{NOT_SCHEME:new RegExp(X("[^]",U,ee,"[\\+\\-\\.]"),"g"),NOT_USERINFO:new RegExp(X("[^\\%\\:]",Ne,Re),"g"),NOT_HOST:new RegExp(X("[^\\%\\[\\]\\:]",Ne,Re),"g"),NOT_PATH:new RegExp(X("[^\\%\\/\\:\\@]",Ne,Re),"g"),NOT_PATH_NOSCHEME:new RegExp(X("[^\\%\\/\\@]",Ne,Re),"g"),NOT_QUERY:new RegExp(X("[^\\%]",Ne,Re,"[\\:\\@\\/\\?]",Ke),"g"),NOT_FRAGMENT:new RegExp(X("[^\\%]",Ne,Re,"[\\:\\@\\/\\?]"),"g"),ESCAPE:new RegExp(X("[^]",Ne,Re),"g"),UNRESERVED:new RegExp(Ne,"g"),OTHER_CHARS:new RegExp(X("[^\\%]",Ne,Pe),"g"),PCT_ENCODED:new RegExp(re,"g"),IPV4ADDRESS:new RegExp("^("+ze+")$"),IPV6ADDRESS:new RegExp("^\\[?("+ht+")"+k(k("\\%25|\\%(?!"+se+"{2})")+"("+lt+")")+"?\\]?$")}}var L=F(!1),C=F(!0),m=function(){function q(U,ee){var se=[],re=!0,Ee=!1,Re=void 0;try{for(var Pe=U[Symbol.iterator](),He;!(re=(He=Pe.next()).done)&&(se.push(He.value),!(ee&&se.length===ee));re=!0);}catch(Ke){Ee=!0,Re=Ke}finally{try{!re&&Pe.return&&Pe.return()}finally{if(Ee)throw Re}}return se}return function(U,ee){if(Array.isArray(U))return U;if(Symbol.iterator in Object(U))return q(U,ee);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),b=function(q){if(Array.isArray(q)){for(var U=0,ee=Array(q.length);U<q.length;U++)ee[U]=q[U];return ee}else return Array.from(q)},x=2147483647,p=36,l=1,s=26,n=38,t=700,i=72,e=128,r="-",a=/^xn--/,o=/[^\0-\x7E]/,c=/[\x2E\u3002\uFF0E\uFF61]/g,h={overflow:"Overflow: input needs wider integers to process","not-basic":"Illegal input >= 0x80 (not a basic code point)","invalid-input":"Invalid input"},A=p-l,v=Math.floor,d=String.fromCharCode;function g(q){throw new RangeError(h[q])}function y(q,U){for(var ee=[],se=q.length;se--;)ee[se]=U(q[se]);return ee}function w(q,U){var ee=q.split("@"),se="";ee.length>1&&(se=ee[0]+"@",q=ee[1]),q=q.replace(c,".");var re=q.split("."),Ee=y(re,U).join(".");return se+Ee}function I(q){for(var U=[],ee=0,se=q.length;ee<se;){var re=q.charCodeAt(ee++);if(re>=55296&&re<=56319&&ee<se){var Ee=q.charCodeAt(ee++);(Ee&64512)==56320?U.push(((re&1023)<<10)+(Ee&1023)+65536):(U.push(re),ee--)}else U.push(re)}return U}var T=function(U){return U-48<10?U-22:U-65<26?U-65:U-97<26?U-97:p},B=function(U,ee){return U+22+75*(U<26)-((ee!=0)<<5)},E=function(U,ee,se){var re=0;for(U=se?v(U/t):U>>1,U+=v(U/ee);U>A*s>>1;re+=p)U=v(U/A);return v(re+(A+1)*U/(U+n))},_=function(U){var ee=[],se=U.length,re=0,Ee=e,Re=i,Pe=U.lastIndexOf(r);Pe<0&&(Pe=0);for(var He=0;He<Pe;++He)U.charCodeAt(He)>=128&&g("not-basic"),ee.push(U.charCodeAt(He));for(var Ke=Pe>0?Pe+1:0;Ke<se;){for(var Ne=re,je=1,ze=p;;ze+=p){Ke>=se&&g("invalid-input");var Le=T(U.charCodeAt(Ke++));(Le>=p||Le>v((x-re)/je))&&g("overflow"),re+=Le*je;var Ze=ze<=Re?l:ze>=Re+s?s:ze-Re;if(Le<Ze)break;var Xe=p-Ze;je>v(x/Xe)&&g("overflow"),je*=Xe}var Oe=ee.length+1;Re=E(re-Ne,Oe,Ne==0),v(re/Oe)>x-Ee&&g("overflow"),Ee+=v(re/Oe),re%=Oe,ee.splice(re++,0,Ee)}return String.fromCodePoint.apply(String,ee)},P=function(U){var ee=[];U=I(U);var se=U.length,re=e,Ee=0,Re=i,Pe=!0,He=!1,Ke=void 0;try{for(var Ne=U[Symbol.iterator](),je;!(Pe=(je=Ne.next()).done);Pe=!0){var ze=je.value;ze<128&&ee.push(d(ze))}}catch(vt){He=!0,Ke=vt}finally{try{!Pe&&Ne.return&&Ne.return()}finally{if(He)throw Ke}}var Le=ee.length,Ze=Le;for(Le&&ee.push(r);Ze<se;){var Xe=x,Oe=!0,ct=!1,nt=void 0;try{for(var ot=U[Symbol.iterator](),pt;!(Oe=(pt=ot.next()).done);Oe=!0){var dt=pt.value;dt>=re&&dt<Xe&&(Xe=dt)}}catch(vt){ct=!0,nt=vt}finally{try{!Oe&&ot.return&&ot.return()}finally{if(ct)throw nt}}var et=Ze+1;Xe-re>v((x-Ee)/et)&&g("overflow"),Ee+=(Xe-re)*et,re=Xe;var rt=!0,ht=!1,lt=void 0;try{for(var Ct=U[Symbol.iterator](),$t;!(rt=($t=Ct.next()).done);rt=!0){var Lt=$t.value;if(Lt<re&&++Ee>x&&g("overflow"),Lt==re){for(var wt=Ee,xt=p;;xt+=p){var St=xt<=Re?l:xt>=Re+s?s:xt-Re;if(wt<St)break;var Bt=wt-St,Nt=p-St;ee.push(d(B(St+Bt%Nt,0))),wt=v(Bt/Nt)}ee.push(d(B(wt,0))),Re=E(Ee,et,Ze==Le),Ee=0,++Ze}}}catch(vt){ht=!0,lt=vt}finally{try{!rt&&Ct.return&&Ct.return()}finally{if(ht)throw lt}}++Ee,++re}return ee.join("")},j={version:"2.1.0",ucs2:{decode:I,encode:function(U){return String.fromCodePoint.apply(String,b(U))}},decode:_,encode:P,toASCII:function(U){return w(U,function(ee){return o.test(ee)?"xn--"+P(ee):ee})},toUnicode:function(U){return w(U,function(ee){return a.test(ee)?_(ee.slice(4).toLowerCase()):ee})}},z={};function D(q){var U=q.charCodeAt(0),ee=void 0;return U<16?ee="%0"+U.toString(16).toUpperCase():U<128?ee="%"+U.toString(16).toUpperCase():U<2048?ee="%"+(U>>6|192).toString(16).toUpperCase()+"%"+(U&63|128).toString(16).toUpperCase():ee="%"+(U>>12|224).toString(16).toUpperCase()+"%"+(U>>6&63|128).toString(16).toUpperCase()+"%"+(U&63|128).toString(16).toUpperCase(),ee}function Y(q){for(var U="",ee=0,se=q.length;ee<se;){var re=parseInt(q.substr(ee+1,2),16);if(re<128)U+=String.fromCharCode(re),ee+=3;else if(re>=194&&re<224){if(se-ee>=6){var Ee=parseInt(q.substr(ee+4,2),16);U+=String.fromCharCode((re&31)<<6|Ee&63)}else U+=q.substr(ee,6);ee+=6}else if(re>=224){if(se-ee>=9){var Re=parseInt(q.substr(ee+4,2),16),Pe=parseInt(q.substr(ee+7,2),16);U+=String.fromCharCode((re&15)<<12|(Re&63)<<6|Pe&63)}else U+=q.substr(ee,9);ee+=9}else U+=q.substr(ee,3),ee+=3}return U}function R(q,U){function ee(se){var re=Y(se);return re.match(U.UNRESERVED)?re:se}return q.scheme&&(q.scheme=String(q.scheme).replace(U.PCT_ENCODED,ee).toLowerCase().replace(U.NOT_SCHEME,"")),q.userinfo!==void 0&&(q.userinfo=String(q.userinfo).replace(U.PCT_ENCODED,ee).replace(U.NOT_USERINFO,D).replace(U.PCT_ENCODED,Z)),q.host!==void 0&&(q.host=String(q.host).replace(U.PCT_ENCODED,ee).toLowerCase().replace(U.NOT_HOST,D).replace(U.PCT_ENCODED,Z)),q.path!==void 0&&(q.path=String(q.path).replace(U.PCT_ENCODED,ee).replace(q.scheme?U.NOT_PATH:U.NOT_PATH_NOSCHEME,D).replace(U.PCT_ENCODED,Z)),q.query!==void 0&&(q.query=String(q.query).replace(U.PCT_ENCODED,ee).replace(U.NOT_QUERY,D).replace(U.PCT_ENCODED,Z)),q.fragment!==void 0&&(q.fragment=String(q.fragment).replace(U.PCT_ENCODED,ee).replace(U.NOT_FRAGMENT,D).replace(U.PCT_ENCODED,Z)),q}function H(q){return q.replace(/^0*(.*)/,"$1")||"0"}function G(q,U){var ee=q.match(U.IPV4ADDRESS)||[],se=m(ee,2),re=se[1];return re?re.split(".").map(H).join("."):q}function f(q,U){var ee=q.match(U.IPV6ADDRESS)||[],se=m(ee,3),re=se[1],Ee=se[2];if(re){for(var Re=re.toLowerCase().split("::").reverse(),Pe=m(Re,2),He=Pe[0],Ke=Pe[1],Ne=Ke?Ke.split(":").map(H):[],je=He.split(":").map(H),ze=U.IPV4ADDRESS.test(je[je.length-1]),Le=ze?7:8,Ze=je.length-Le,Xe=Array(Le),Oe=0;Oe<Le;++Oe)Xe[Oe]=Ne[Oe]||je[Ze+Oe]||"";ze&&(Xe[Le-1]=G(Xe[Le-1],U));var ct=Xe.reduce(function(et,rt,ht){if(!rt||rt==="0"){var lt=et[et.length-1];lt&&lt.index+lt.length===ht?lt.length++:et.push({index:ht,length:1})}return et},[]),nt=ct.sort(function(et,rt){return rt.length-et.length})[0],ot=void 0;if(nt&&nt.length>1){var pt=Xe.slice(0,nt.index),dt=Xe.slice(nt.index+nt.length);ot=pt.join(":")+"::"+dt.join(":")}else ot=Xe.join(":");return Ee&&(ot+="%"+Ee),ot}else return q}var S=/^(?:([^:\/?#]+):)?(?:\/\/((?:([^\/?#@]*)@)?(\[[^\/?#\]]+\]|[^\/?#:]*)(?:\:(\d*))?))?([^?#]*)(?:\?([^#]*))?(?:#((?:.|\n|\r)*))?/i,$="".match(/(){0}/)[1]===void 0;function M(q){var U=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},ee={},se=U.iri!==!1?C:L;U.reference==="suffix"&&(q=(U.scheme?U.scheme+":":"")+"//"+q);var re=q.match(S);if(re){$?(ee.scheme=re[1],ee.userinfo=re[3],ee.host=re[4],ee.port=parseInt(re[5],10),ee.path=re[6]||"",ee.query=re[7],ee.fragment=re[8],isNaN(ee.port)&&(ee.port=re[5])):(ee.scheme=re[1]||void 0,ee.userinfo=q.indexOf("@")!==-1?re[3]:void 0,ee.host=q.indexOf("//")!==-1?re[4]:void 0,ee.port=parseInt(re[5],10),ee.path=re[6]||"",ee.query=q.indexOf("?")!==-1?re[7]:void 0,ee.fragment=q.indexOf("#")!==-1?re[8]:void 0,isNaN(ee.port)&&(ee.port=q.match(/\/\/(?:.|\n)*\:(?:\/|\?|\#|$)/)?re[4]:void 0)),ee.host&&(ee.host=f(G(ee.host,se),se)),ee.scheme===void 0&&ee.userinfo===void 0&&ee.host===void 0&&ee.port===void 0&&!ee.path&&ee.query===void 0?ee.reference="same-document":ee.scheme===void 0?ee.reference="relative":ee.fragment===void 0?ee.reference="absolute":ee.reference="uri",U.reference&&U.reference!=="suffix"&&U.reference!==ee.reference&&(ee.error=ee.error||"URI is not a "+U.reference+" reference.");var Ee=z[(U.scheme||ee.scheme||"").toLowerCase()];if(!U.unicodeSupport&&(!Ee||!Ee.unicodeSupport)){if(ee.host&&(U.domainHost||Ee&&Ee.domainHost))try{ee.host=j.toASCII(ee.host.replace(se.PCT_ENCODED,Y).toLowerCase())}catch(Re){ee.error=ee.error||"Host's domain name can not be converted to ASCII via punycode: "+Re}R(ee,L)}else R(ee,se);Ee&&Ee.parse&&Ee.parse(ee,U)}else ee.error=ee.error||"URI can not be parsed.";return ee}function K(q,U){var ee=U.iri!==!1?C:L,se=[];return q.userinfo!==void 0&&(se.push(q.userinfo),se.push("@")),q.host!==void 0&&se.push(f(G(String(q.host),ee),ee).replace(ee.IPV6ADDRESS,function(re,Ee,Re){return"["+Ee+(Re?"%25"+Re:"")+"]"})),(typeof q.port=="number"||typeof q.port=="string")&&(se.push(":"),se.push(String(q.port))),se.length?se.join(""):void 0}var Q=/^\.\.?\//,te=/^\/\.(\/|$)/,he=/^\/\.\.(\/|$)/,Ae=/^\/?(?:.|\n)*?(?=\/|$)/;function ge(q){for(var U=[];q.length;)if(q.match(Q))q=q.replace(Q,"");else if(q.match(te))q=q.replace(te,"/");else if(q.match(he))q=q.replace(he,"/"),U.pop();else if(q==="."||q==="..")q="";else{var ee=q.match(Ae);if(ee){var se=ee[0];q=q.slice(se.length),U.push(se)}else throw new Error("Unexpected dot segment condition")}return U.join("")}function Ce(q){var U=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},ee=U.iri?C:L,se=[],re=z[(U.scheme||q.scheme||"").toLowerCase()];if(re&&re.serialize&&re.serialize(q,U),q.host&&!ee.IPV6ADDRESS.test(q.host)){if(U.domainHost||re&&re.domainHost)try{q.host=U.iri?j.toUnicode(q.host):j.toASCII(q.host.replace(ee.PCT_ENCODED,Y).toLowerCase())}catch(Pe){q.error=q.error||"Host's domain name can not be converted to "+(U.iri?"Unicode":"ASCII")+" via punycode: "+Pe}}R(q,ee),U.reference!=="suffix"&&q.scheme&&(se.push(q.scheme),se.push(":"));var Ee=K(q,U);if(Ee!==void 0&&(U.reference!=="suffix"&&se.push("//"),se.push(Ee),q.path&&q.path.charAt(0)!=="/"&&se.push("/")),q.path!==void 0){var Re=q.path;!U.absolutePath&&(!re||!re.absolutePath)&&(Re=ge(Re)),Ee===void 0&&(Re=Re.replace(/^\/\//,"/%2F")),se.push(Re)}return q.query!==void 0&&(se.push("?"),se.push(q.query)),q.fragment!==void 0&&(se.push("#"),se.push(q.fragment)),se.join("")}function ve(q,U){var ee=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},se=arguments[3],re={};return se||(q=M(Ce(q,ee),ee),U=M(Ce(U,ee),ee)),ee=ee||{},!ee.tolerant&&U.scheme?(re.scheme=U.scheme,re.userinfo=U.userinfo,re.host=U.host,re.port=U.port,re.path=ge(U.path||""),re.query=U.query):(U.userinfo!==void 0||U.host!==void 0||U.port!==void 0?(re.userinfo=U.userinfo,re.host=U.host,re.port=U.port,re.path=ge(U.path||""),re.query=U.query):(U.path?(U.path.charAt(0)==="/"?re.path=ge(U.path):((q.userinfo!==void 0||q.host!==void 0||q.port!==void 0)&&!q.path?re.path="/"+U.path:q.path?re.path=q.path.slice(0,q.path.lastIndexOf("/")+1)+U.path:re.path=U.path,re.path=ge(re.path)),re.query=U.query):(re.path=q.path,U.query!==void 0?re.query=U.query:re.query=q.query),re.userinfo=q.userinfo,re.host=q.host,re.port=q.port),re.scheme=q.scheme),re.fragment=U.fragment,re}function ye(q,U,ee){var se=W({scheme:"null"},ee);return Ce(ve(M(q,se),M(U,se),se,!0),se)}function Te(q,U){return typeof q=="string"?q=Ce(M(q,U),U):N(q)==="object"&&(q=M(Ce(q,U),U)),q}function _e(q,U,ee){return typeof q=="string"?q=Ce(M(q,ee),ee):N(q)==="object"&&(q=Ce(q,ee)),typeof U=="string"?U=Ce(M(U,ee),ee):N(U)==="object"&&(U=Ce(U,ee)),q===U}function Se(q,U){return q&&q.toString().replace(!U||!U.iri?L.ESCAPE:C.ESCAPE,D)}function ue(q,U){return q&&q.toString().replace(!U||!U.iri?L.PCT_ENCODED:C.PCT_ENCODED,Y)}var $e={scheme:"http",domainHost:!0,parse:function(U,ee){return U.host||(U.error=U.error||"HTTP URIs must have a host."),U},serialize:function(U,ee){var se=String(U.scheme).toLowerCase()==="https";return(U.port===(se?443:80)||U.port==="")&&(U.port=void 0),U.path||(U.path="/"),U}},ae={scheme:"https",domainHost:$e.domainHost,parse:$e.parse,serialize:$e.serialize};function pe(q){return typeof q.secure=="boolean"?q.secure:String(q.scheme).toLowerCase()==="wss"}var ce={scheme:"ws",domainHost:!0,parse:function(U,ee){var se=U;return se.secure=pe(se),se.resourceName=(se.path||"/")+(se.query?"?"+se.query:""),se.path=void 0,se.query=void 0,se},serialize:function(U,ee){if((U.port===(pe(U)?443:80)||U.port==="")&&(U.port=void 0),typeof U.secure=="boolean"&&(U.scheme=U.secure?"wss":"ws",U.secure=void 0),U.resourceName){var se=U.resourceName.split("?"),re=m(se,2),Ee=re[0],Re=re[1];U.path=Ee&&Ee!=="/"?Ee:void 0,U.query=Re,U.resourceName=void 0}return U.fragment=void 0,U}},de={scheme:"wss",domainHost:ce.domainHost,parse:ce.parse,serialize:ce.serialize},fe={},be="[A-Za-z0-9\\-\\.\\_\\~\\xA0-\\u200D\\u2010-\\u2029\\u202F-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF]",ke="[0-9A-Fa-f]",Me=k(k("%[EFef]"+ke+"%"+ke+ke+"%"+ke+ke)+"|"+k("%[89A-Fa-f]"+ke+"%"+ke+ke)+"|"+k("%"+ke+ke)),Ye="[A-Za-z0-9\\!\\$\\%\\'\\*\\+\\-\\^\\_\\`\\{\\|\\}\\~]",Ve=X("[\\!\\$\\%\\'\\(\\)\\*\\+\\,\\-\\.0-9\\<\\>A-Z\\x5E-\\x7E]",'[\\"\\\\]'),Qe="[\\!\\$\\'\\(\\)\\*\\+\\,\\;\\:\\@]",yt=new RegExp(be,"g"),J=new RegExp(Me,"g"),ne=new RegExp(X("[^]",Ye,"[\\.]",'[\\"]',Ve),"g"),oe=new RegExp(X("[^]",be,Qe),"g"),me=oe;function xe(q){var U=Y(q);return U.match(yt)?U:q}var we={scheme:"mailto",parse:function(U,ee){var se=U,re=se.to=se.path?se.path.split(","):[];if(se.path=void 0,se.query){for(var Ee=!1,Re={},Pe=se.query.split("&"),He=0,Ke=Pe.length;He<Ke;++He){var Ne=Pe[He].split("=");switch(Ne[0]){case"to":for(var je=Ne[1].split(","),ze=0,Le=je.length;ze<Le;++ze)re.push(je[ze]);break;case"subject":se.subject=ue(Ne[1],ee);break;case"body":se.body=ue(Ne[1],ee);break;default:Ee=!0,Re[ue(Ne[0],ee)]=ue(Ne[1],ee);break}}Ee&&(se.headers=Re)}se.query=void 0;for(var Ze=0,Xe=re.length;Ze<Xe;++Ze){var Oe=re[Ze].split("@");if(Oe[0]=ue(Oe[0]),ee.unicodeSupport)Oe[1]=ue(Oe[1],ee).toLowerCase();else try{Oe[1]=j.toASCII(ue(Oe[1],ee).toLowerCase())}catch(ct){se.error=se.error||"Email address's domain name can not be converted to ASCII via punycode: "+ct}re[Ze]=Oe.join("@")}return se},serialize:function(U,ee){var se=U,re=O(U.to);if(re){for(var Ee=0,Re=re.length;Ee<Re;++Ee){var Pe=String(re[Ee]),He=Pe.lastIndexOf("@"),Ke=Pe.slice(0,He).replace(J,xe).replace(J,Z).replace(ne,D),Ne=Pe.slice(He+1);try{Ne=ee.iri?j.toUnicode(Ne):j.toASCII(ue(Ne,ee).toLowerCase())}catch(Ze){se.error=se.error||"Email address's domain name can not be converted to "+(ee.iri?"Unicode":"ASCII")+" via punycode: "+Ze}re[Ee]=Ke+"@"+Ne}se.path=re.join(",")}var je=U.headers=U.headers||{};U.subject&&(je.subject=U.subject),U.body&&(je.body=U.body);var ze=[];for(var Le in je)je[Le]!==fe[Le]&&ze.push(Le.replace(J,xe).replace(J,Z).replace(oe,D)+"="+je[Le].replace(J,xe).replace(J,Z).replace(me,D));return ze.length&&(se.query=ze.join("&")),se}},We=/^([^\:]+)\:(.*)/,De={scheme:"urn",parse:function(U,ee){var se=U.path&&U.path.match(We),re=U;if(se){var Ee=ee.scheme||re.scheme||"urn",Re=se[1].toLowerCase(),Pe=se[2],He=Ee+":"+(ee.nid||Re),Ke=z[He];re.nid=Re,re.nss=Pe,re.path=void 0,Ke&&(re=Ke.parse(re,ee))}else re.error=re.error||"URN can not be parsed.";return re},serialize:function(U,ee){var se=ee.scheme||U.scheme||"urn",re=U.nid,Ee=se+":"+(ee.nid||re),Re=z[Ee];Re&&(U=Re.serialize(U,ee));var Pe=U,He=U.nss;return Pe.path=(re||ee.nid)+":"+He,Pe}},Ue=/^[0-9A-Fa-f]{8}(?:\-[0-9A-Fa-f]{4}){3}\-[0-9A-Fa-f]{12}$/,at={scheme:"urn:uuid",parse:function(U,ee){var se=U;return se.uuid=se.nss,se.nss=void 0,!ee.tolerant&&(!se.uuid||!se.uuid.match(Ue))&&(se.error=se.error||"UUID is not valid."),se},serialize:function(U,ee){var se=U;return se.nss=(U.uuid||"").toLowerCase(),se}};z[$e.scheme]=$e,z[ae.scheme]=ae,z[ce.scheme]=ce,z[de.scheme]=de,z[we.scheme]=we,z[De.scheme]=De,z[at.scheme]=at,V.SCHEMES=z,V.pctEncChar=D,V.pctDecChars=Y,V.parse=M,V.removeDotSegments=ge,V.serialize=Ce,V.resolveComponents=ve,V.resolve=ye,V.normalize=Te,V.equal=_e,V.escapeComponent=Se,V.unescapeComponent=ue,Object.defineProperty(V,"__esModule",{value:!0})})(u)},4049:function(ie){ie.exports=function(){var u=function(i,e){if(!(i instanceof e))throw new TypeError("Cannot call a class as a function")},V=function(){function i(e,r){for(var a=0;a<r.length;a++){var o=r[a];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(e,r,a){return r&&i(e.prototype,r),a&&i(e,a),e}}(),X=function(){function i(e,r){var a=[],o=!0,c=!1,h=void 0;try{for(var A=e[Symbol.iterator](),v;!(o=(v=A.next()).done)&&(a.push(v.value),!(r&&a.length===r));o=!0);}catch(d){c=!0,h=d}finally{try{!o&&A.return&&A.return()}finally{if(c)throw h}}return a}return function(e,r){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return i(e,r);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),k=(String.prototype.startsWith=String.prototype.startsWith||function(i){return this.indexOf(i)===0},String.prototype.padStart=String.prototype.padStart||function(i,e){for(var r=this;r.length<i;)r=e+r;return r},{cb:"0f8ff",tqw:"aebd7",q:"-ffff",qmrn:"7fffd4",zr:"0ffff",bg:"5f5dc",bsq:"e4c4",bck:"---",nch:"ebcd",b:"--ff",bvt:"8a2be2",brwn:"a52a2a",brw:"deb887",ctb:"5f9ea0",hrt:"7fff-",chcT:"d2691e",cr:"7f50",rnw:"6495ed",crns:"8dc",crms:"dc143c",cn:"-ffff",Db:"--8b",Dcn:"-8b8b",Dgnr:"b8860b",Dgr:"a9a9a9",Dgrn:"-64-",Dkhk:"bdb76b",Dmgn:"8b-8b",Dvgr:"556b2f",Drng:"8c-",Drch:"9932cc",Dr:"8b--",Dsmn:"e9967a",Dsgr:"8fbc8f",DsTb:"483d8b",DsTg:"2f4f4f",Dtrq:"-ced1",Dvt:"94-d3",ppnk:"1493",pskb:"-bfff",mgr:"696969",grb:"1e90ff",rbrc:"b22222",rwht:"af0",stg:"228b22",chs:"-ff",gnsb:"dcdcdc",st:"8f8ff",g:"d7-",gnr:"daa520",gr:"808080",grn:"-8-0",grnw:"adff2f",hnw:"0fff0",htpn:"69b4",nnr:"cd5c5c",ng:"4b-82",vr:"0",khk:"0e68c",vnr:"e6e6fa",nrb:"0f5",wngr:"7cfc-",mnch:"acd",Lb:"add8e6",Lcr:"08080",Lcn:"e0ffff",Lgnr:"afad2",Lgr:"d3d3d3",Lgrn:"90ee90",Lpnk:"b6c1",Lsmn:"a07a",Lsgr:"20b2aa",Lskb:"87cefa",LsTg:"778899",Lstb:"b0c4de",Lw:"e0",m:"-ff-",mgrn:"32cd32",nn:"af0e6",mgnt:"-ff",mrn:"8--0",mqm:"66cdaa",mmb:"--cd",mmrc:"ba55d3",mmpr:"9370db",msg:"3cb371",mmsT:"7b68ee","":"-fa9a",mtr:"48d1cc",mmvt:"c71585",mnLb:"191970",ntc:"5fffa",mstr:"e4e1",mccs:"e4b5",vjw:"dead",nv:"--80",c:"df5e6",v:"808-0",vrb:"6b8e23",rng:"a5-",rngr:"45-",rch:"da70d6",pgnr:"eee8aa",pgrn:"98fb98",ptrq:"afeeee",pvtr:"db7093",ppwh:"efd5",pchp:"dab9",pr:"cd853f",pnk:"c0cb",pm:"dda0dd",pwrb:"b0e0e6",prp:"8-080",cc:"663399",r:"--",sbr:"bc8f8f",rb:"4169e1",sbrw:"8b4513",smn:"a8072",nbr:"4a460",sgrn:"2e8b57",ssh:"5ee",snn:"a0522d",svr:"c0c0c0",skb:"87ceeb",sTb:"6a5acd",sTgr:"708090",snw:"afa",n:"-ff7f",stb:"4682b4",tn:"d2b48c",t:"-8080",thst:"d8bfd8",tmT:"6347",trqs:"40e0d0",vt:"ee82ee",whT:"5deb3",wht:"",hts:"5f5f5",w:"-",wgrn:"9acd32"});function N(i){var e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1,r=e>0?i.toFixed(e).replace(/0+$/,"").replace(/\.$/,""):i.toString();return r||"0"}var Z=function(){function i(e,r,a,o){u(this,i);var c=this;function h(v){if(v.startsWith("hsl")){var d=v.match(/([\-\d\.e]+)/g).map(Number),g=X(d,4),y=g[0],w=g[1],I=g[2],T=g[3];T===void 0&&(T=1),y/=360,w/=100,I/=100,c.hsla=[y,w,I,T]}else if(v.startsWith("rgb")){var B=v.match(/([\-\d\.e]+)/g).map(Number),E=X(B,4),_=E[0],P=E[1],j=E[2],z=E[3];z===void 0&&(z=1),c.rgba=[_,P,j,z]}else v.startsWith("#")?c.rgba=i.hexToRgb(v):c.rgba=i.nameToRgb(v)||i.hexToRgb(v)}if(e!==void 0)if(Array.isArray(e))this.rgba=e;else if(a===void 0){var A=e&&""+e;A&&h(A.toLowerCase())}else this.rgba=[e,r,a,o===void 0?1:o]}return V(i,[{key:"printRGB",value:function(r){var a=r?this.rgba:this.rgba.slice(0,3),o=a.map(function(c,h){return N(c,h===3?3:0)});return r?"rgba("+o+")":"rgb("+o+")"}},{key:"printHSL",value:function(r){var a=[360,100,100,1],o=["","%","%",""],c=r?this.hsla:this.hsla.slice(0,3),h=c.map(function(A,v){return N(A*a[v],v===3?3:1)+o[v]});return r?"hsla("+h+")":"hsl("+h+")"}},{key:"printHex",value:function(r){var a=this.hex;return r?a:a.substring(0,7)}},{key:"rgba",get:function(){if(this._rgba)return this._rgba;if(!this._hsla)throw new Error("No color is set");return this._rgba=i.hslToRgb(this._hsla)},set:function(r){r.length===3&&(r[3]=1),this._rgba=r,this._hsla=null}},{key:"rgbString",get:function(){return this.printRGB()}},{key:"rgbaString",get:function(){return this.printRGB(!0)}},{key:"hsla",get:function(){if(this._hsla)return this._hsla;if(!this._rgba)throw new Error("No color is set");return this._hsla=i.rgbToHsl(this._rgba)},set:function(r){r.length===3&&(r[3]=1),this._hsla=r,this._rgba=null}},{key:"hslString",get:function(){return this.printHSL()}},{key:"hslaString",get:function(){return this.printHSL(!0)}},{key:"hex",get:function(){var r=this.rgba,a=r.map(function(o,c){return c<3?o.toString(16):Math.round(o*255).toString(16)});return"#"+a.map(function(o){return o.padStart(2,"0")}).join("")},set:function(r){this.rgba=i.hexToRgb(r)}}],[{key:"hexToRgb",value:function(r){var a=(r.startsWith("#")?r.slice(1):r).replace(/^(\w{3})$/,"$1F").replace(/^(\w)(\w)(\w)(\w)$/,"$1$1$2$2$3$3$4$4").replace(/^(\w{6})$/,"$1FF");if(!a.match(/^([0-9a-fA-F]{8})$/))throw new Error("Unknown hex color; "+r);var o=a.match(/^(\w\w)(\w\w)(\w\w)(\w\w)$/).slice(1).map(function(c){return parseInt(c,16)});return o[3]=o[3]/255,o}},{key:"nameToRgb",value:function(r){var a=r.toLowerCase().replace("at","T").replace(/[aeiouyldf]/g,"").replace("ght","L").replace("rk","D").slice(-5,4),o=k[a];return o===void 0?o:i.hexToRgb(o.replace(/\-/g,"00").padStart(6,"f"))}},{key:"rgbToHsl",value:function(r){var a=X(r,4),o=a[0],c=a[1],h=a[2],A=a[3];o/=255,c/=255,h/=255;var v=Math.max(o,c,h),d=Math.min(o,c,h),g=void 0,y=void 0,w=(v+d)/2;if(v===d)g=y=0;else{var I=v-d;switch(y=w>.5?I/(2-v-d):I/(v+d),v){case o:g=(c-h)/I+(c<h?6:0);break;case c:g=(h-o)/I+2;break;case h:g=(o-c)/I+4;break}g/=6}return[g,y,w,A]}},{key:"hslToRgb",value:function(r){var a=X(r,4),o=a[0],c=a[1],h=a[2],A=a[3],v=void 0,d=void 0,g=void 0;if(c===0)v=d=g=h;else{var y=function(E,_,P){return P<0&&(P+=1),P>1&&(P-=1),P<.16666666666666666?E+(_-E)*6*P:P<.5?_:P<.6666666666666666?E+(_-E)*(.6666666666666666-P)*6:E},w=h<.5?h*(1+c):h+c-h*c,I=2*h-w;v=y(I,w,o+1/3),d=y(I,w,o),g=y(I,w,o-1/3)}var T=[v*255,d*255,g*255].map(Math.round);return T[3]=A,T}}]),i}(),O=function(){function i(){u(this,i),this._events=[]}return V(i,[{key:"add",value:function(r,a,o){r.addEventListener(a,o,!1),this._events.push({target:r,type:a,handler:o})}},{key:"remove",value:function(r,a,o){this._events=this._events.filter(function(c){var h=!0;return r&&r!==c.target&&(h=!1),a&&a!==c.type&&(h=!1),o&&o!==c.handler&&(h=!1),h&&i._doRemove(c.target,c.type,c.handler),!h})}},{key:"destroy",value:function(){this._events.forEach(function(r){return i._doRemove(r.target,r.type,r.handler)}),this._events=[]}}],[{key:"_doRemove",value:function(r,a,o){r.removeEventListener(a,o,!1)}}]),i}();function W(i){var e=document.createElement("div");return e.innerHTML=i,e.firstElementChild}function F(i,e,r){var a=!1;function o(v,d,g){return Math.max(d,Math.min(v,g))}function c(v,d,g){if(g&&(a=!0),!!a){v.preventDefault();var y=e.getBoundingClientRect(),w=y.width,I=y.height,T=d.clientX,B=d.clientY,E=o(T-y.left,0,w),_=o(B-y.top,0,I);r(E/w,_/I)}}function h(v,d){var g=v.buttons===void 0?v.which:v.buttons;g===1?c(v,v,d):a=!1}function A(v,d){v.touches.length===1?c(v,v.touches[0],d):a=!1}i.add(e,"mousedown",function(v){h(v,!0)}),i.add(e,"touchstart",function(v){A(v,!0)}),i.add(window,"mousemove",h),i.add(e,"touchmove",A),i.add(window,"mouseup",function(v){a=!1}),i.add(e,"touchend",function(v){a=!1}),i.add(e,"touchcancel",function(v){a=!1})}var L=`linear-gradient(45deg, lightgrey 25%, transparent 25%, transparent 75%, lightgrey 75%) 0 0 / 2em 2em,
                   linear-gradient(45deg, lightgrey 25%,       white 25%,       white 75%, lightgrey 75%) 1em 1em / 2em 2em`,C=360,m="keydown",b="mousedown",x="focusin";function p(i,e){return(e||document).querySelector(i)}function l(i){i.preventDefault(),i.stopPropagation()}function s(i,e,r,a,o){i.add(e,m,function(c){r.indexOf(c.key)>=0&&(o&&l(c),a(c))})}var n=function(){function i(e){u(this,i),this.settings={popup:"right",layout:"default",alpha:!0,editor:!0,editorFormat:"hex",cancelButton:!1,defaultColor:"#0cf"},this._events=new O,this.onChange=null,this.onDone=null,this.onOpen=null,this.onClose=null,this.setOptions(e)}return V(i,[{key:"setOptions",value:function(r){var a=this;if(!r)return;var o=this.settings;function c(d,g,y){for(var w in d)y&&y.indexOf(w)>=0||(g[w]=d[w])}if(r instanceof HTMLElement)o.parent=r;else{o.parent&&r.parent&&o.parent!==r.parent&&(this._events.remove(o.parent),this._popupInited=!1),c(r,o),r.onChange&&(this.onChange=r.onChange),r.onDone&&(this.onDone=r.onDone),r.onOpen&&(this.onOpen=r.onOpen),r.onClose&&(this.onClose=r.onClose);var h=r.color||r.colour;h&&this._setColor(h)}var A=o.parent;if(A&&o.popup&&!this._popupInited){var v=function(g){return a.openHandler(g)};this._events.add(A,"click",v),s(this._events,A,[" ","Spacebar","Enter"],v),this._popupInited=!0}else r.parent&&!o.popup&&this.show()}},{key:"openHandler",value:function(r){if(this.show()){r&&r.preventDefault(),this.settings.parent.style.pointerEvents="none";var a=r&&r.type===m?this._domEdit:this.domElement;setTimeout(function(){return a.focus()},100),this.onOpen&&this.onOpen(this.colour)}}},{key:"closeHandler",value:function(r){var a=r&&r.type,o=!1;if(!r)o=!0;else if(a===b||a===x){var c=(this.__containedEvent||0)+100;r.timeStamp>c&&(o=!0)}else l(r),o=!0;o&&this.hide()&&(this.settings.parent.style.pointerEvents="",a!==b&&this.settings.parent.focus(),this.onClose&&this.onClose(this.colour))}},{key:"movePopup",value:function(r,a){this.closeHandler(),this.setOptions(r),a&&this.openHandler()}},{key:"setColor",value:function(r,a){this._setColor(r,{silent:a})}},{key:"_setColor",value:function(r,a){if(typeof r=="string"&&(r=r.trim()),!!r){a=a||{};var o=void 0;try{o=new Z(r)}catch(h){if(a.failSilently)return;throw h}if(!this.settings.alpha){var c=o.hsla;c[3]=1,o.hsla=c}this.colour=this.color=o,this._setHSLA(null,null,null,null,a)}}},{key:"setColour",value:function(r,a){this.setColor(r,a)}},{key:"show",value:function(){var r=this.settings.parent;if(!r)return!1;if(this.domElement){var a=this._toggleDOM(!0);return this._setPosition(),a}var o=this.settings.template||'<div class="picker_wrapper" tabindex="-1"><div class="picker_arrow"></div><div class="picker_hue picker_slider"><div class="picker_selector"></div></div><div class="picker_sl"><div class="picker_selector"></div></div><div class="picker_alpha picker_slider"><div class="picker_selector"></div></div><div class="picker_editor"><input aria-label="Type a color name or hex value"/></div><div class="picker_sample"></div><div class="picker_done"><button>Ok</button></div><div class="picker_cancel"><button>Cancel</button></div></div>',c=W(o);return this.domElement=c,this._domH=p(".picker_hue",c),this._domSL=p(".picker_sl",c),this._domA=p(".picker_alpha",c),this._domEdit=p(".picker_editor input",c),this._domSample=p(".picker_sample",c),this._domOkay=p(".picker_done button",c),this._domCancel=p(".picker_cancel button",c),c.classList.add("layout_"+this.settings.layout),this.settings.alpha||c.classList.add("no_alpha"),this.settings.editor||c.classList.add("no_editor"),this.settings.cancelButton||c.classList.add("no_cancel"),this._ifPopup(function(){return c.classList.add("popup")}),this._setPosition(),this.colour?this._updateUI():this._setColor(this.settings.defaultColor),this._bindEvents(),!0}},{key:"hide",value:function(){return this._toggleDOM(!1)}},{key:"destroy",value:function(){this._events.destroy(),this.domElement&&this.settings.parent.removeChild(this.domElement)}},{key:"_bindEvents",value:function(){var r=this,a=this,o=this.domElement,c=this._events;function h(d,g,y){c.add(d,g,y)}h(o,"click",function(d){return d.preventDefault()}),F(c,this._domH,function(d,g){return a._setHSLA(d)}),F(c,this._domSL,function(d,g){return a._setHSLA(null,d,1-g)}),this.settings.alpha&&F(c,this._domA,function(d,g){return a._setHSLA(null,null,null,1-g)});var A=this._domEdit;h(A,"input",function(d){a._setColor(this.value,{fromEditor:!0,failSilently:!0})}),h(A,"focus",function(d){var g=this;g.selectionStart===g.selectionEnd&&g.select()}),this._ifPopup(function(){var d=function(w){return r.closeHandler(w)};h(window,b,d),h(window,x,d),s(c,o,["Esc","Escape"],d);var g=function(w){r.__containedEvent=w.timeStamp};h(o,b,g),h(o,x,g),h(r._domCancel,"click",d)});var v=function(g){r._ifPopup(function(){return r.closeHandler(g)}),r.onDone&&r.onDone(r.colour)};h(this._domOkay,"click",v),s(c,o,["Enter"],v)}},{key:"_setPosition",value:function(){var r=this.settings.parent,a=this.domElement;r!==a.parentNode&&r.appendChild(a),this._ifPopup(function(o){getComputedStyle(r).position==="static"&&(r.style.position="relative");var c=o===!0?"popup_right":"popup_"+o;["popup_top","popup_bottom","popup_left","popup_right"].forEach(function(h){h===c?a.classList.add(h):a.classList.remove(h)}),a.classList.add(c)})}},{key:"_setHSLA",value:function(r,a,o,c,h){h=h||{};var A=this.colour,v=A.hsla;[r,a,o,c].forEach(function(d,g){(d||d===0)&&(v[g]=d)}),A.hsla=v,this._updateUI(h),this.onChange&&!h.silent&&this.onChange(A)}},{key:"_updateUI",value:function(r){if(!this.domElement)return;r=r||{};var a=this.colour,o=a.hsla,c="hsl("+o[0]*C+", 100%, 50%)",h=a.hslString,A=a.hslaString,v=this._domH,d=this._domSL,g=this._domA,y=p(".picker_selector",v),w=p(".picker_selector",d),I=p(".picker_selector",g);function T(Y,R,H){R.style.left=H*100+"%"}function B(Y,R,H){R.style.top=H*100+"%"}T(v,y,o[0]),this._domSL.style.backgroundColor=this._domH.style.color=c,T(d,w,o[1]),B(d,w,1-o[2]),d.style.color=h,B(g,I,1-o[3]);var E=h,_=E.replace("hsl","hsla").replace(")",", 0)"),P="linear-gradient("+[E,_]+")";if(this._domA.style.background=P+", "+L,!r.fromEditor){var j=this.settings.editorFormat,z=this.settings.alpha,D=void 0;switch(j){case"rgb":D=a.printRGB(z);break;case"hsl":D=a.printHSL(z);break;default:D=a.printHex(z)}this._domEdit.value=D}this._domSample.style.color=A}},{key:"_ifPopup",value:function(r,a){this.settings.parent&&this.settings.popup?r&&r(this.settings.popup):a&&a()}},{key:"_toggleDOM",value:function(r){var a=this.domElement;if(!a)return!1;var o=r?"":"none",c=a.style.display!==o;return c&&(a.style.display=o),c}}]),i}(),t=document.createElement("style");return t.textContent='.picker_wrapper.no_alpha .picker_alpha{display:none}.picker_wrapper.no_editor .picker_editor{position:absolute;z-index:-1;opacity:0}.picker_wrapper.no_cancel .picker_cancel{display:none}.layout_default.picker_wrapper{display:flex;flex-flow:row wrap;justify-content:space-between;align-items:stretch;font-size:10px;width:25em;padding:.5em}.layout_default.picker_wrapper input,.layout_default.picker_wrapper button{font-size:1rem}.layout_default.picker_wrapper>*{margin:.5em}.layout_default.picker_wrapper::before{content:"";display:block;width:100%;height:0;order:1}.layout_default .picker_slider,.layout_default .picker_selector{padding:1em}.layout_default .picker_hue{width:100%}.layout_default .picker_sl{flex:1 1 auto}.layout_default .picker_sl::before{content:"";display:block;padding-bottom:100%}.layout_default .picker_editor{order:1;width:6.5rem}.layout_default .picker_editor input{width:100%;height:100%}.layout_default .picker_sample{order:1;flex:1 1 auto}.layout_default .picker_done,.layout_default .picker_cancel{order:1}.picker_wrapper{box-sizing:border-box;background:#f2f2f2;box-shadow:0 0 0 1px silver;cursor:default;font-family:sans-serif;color:#444;pointer-events:auto}.picker_wrapper:focus{outline:none}.picker_wrapper button,.picker_wrapper input{box-sizing:border-box;border:none;box-shadow:0 0 0 1px silver;outline:none}.picker_wrapper button:focus,.picker_wrapper button:active,.picker_wrapper input:focus,.picker_wrapper input:active{box-shadow:0 0 2px 1px #1e90ff}.picker_wrapper button{padding:.4em .6em;cursor:pointer;background-color:#f5f5f5;background-image:linear-gradient(0deg, gainsboro, transparent)}.picker_wrapper button:active{background-image:linear-gradient(0deg, transparent, gainsboro)}.picker_wrapper button:hover{background-color:#fff}.picker_selector{position:absolute;z-index:1;display:block;-webkit-transform:translate(-50%, -50%);transform:translate(-50%, -50%);border:2px solid #fff;border-radius:100%;box-shadow:0 0 3px 1px #67b9ff;background:currentColor;cursor:pointer}.picker_slider .picker_selector{border-radius:2px}.picker_hue{position:relative;background-image:linear-gradient(90deg, red, yellow, lime, cyan, blue, magenta, red);box-shadow:0 0 0 1px silver}.picker_sl{position:relative;box-shadow:0 0 0 1px silver;background-image:linear-gradient(180deg, white, rgba(255, 255, 255, 0) 50%),linear-gradient(0deg, black, rgba(0, 0, 0, 0) 50%),linear-gradient(90deg, #808080, rgba(128, 128, 128, 0))}.picker_alpha,.picker_sample{position:relative;background:linear-gradient(45deg, lightgrey 25%, transparent 25%, transparent 75%, lightgrey 75%) 0 0/2em 2em,linear-gradient(45deg, lightgrey 25%, white 25%, white 75%, lightgrey 75%) 1em 1em/2em 2em;box-shadow:0 0 0 1px silver}.picker_alpha .picker_selector,.picker_sample .picker_selector{background:none}.picker_editor input{font-family:monospace;padding:.2em .4em}.picker_sample::before{content:"";position:absolute;display:block;width:100%;height:100%;background:currentColor}.picker_arrow{position:absolute;z-index:-1}.picker_wrapper.popup{position:absolute;z-index:2;margin:1.5em}.picker_wrapper.popup,.picker_wrapper.popup .picker_arrow::before,.picker_wrapper.popup .picker_arrow::after{background:#f2f2f2;box-shadow:0 0 10px 1px rgba(0,0,0,.4)}.picker_wrapper.popup .picker_arrow{width:3em;height:3em;margin:0}.picker_wrapper.popup .picker_arrow::before,.picker_wrapper.popup .picker_arrow::after{content:"";display:block;position:absolute;top:0;left:0;z-index:-99}.picker_wrapper.popup .picker_arrow::before{width:100%;height:100%;-webkit-transform:skew(45deg);transform:skew(45deg);-webkit-transform-origin:0 100%;transform-origin:0 100%}.picker_wrapper.popup .picker_arrow::after{width:150%;height:150%;box-shadow:none}.popup.popup_top{bottom:100%;left:0}.popup.popup_top .picker_arrow{bottom:0;left:0;-webkit-transform:rotate(-90deg);transform:rotate(-90deg)}.popup.popup_bottom{top:100%;left:0}.popup.popup_bottom .picker_arrow{top:0;left:0;-webkit-transform:rotate(90deg) scale(1, -1);transform:rotate(90deg) scale(1, -1)}.popup.popup_left{top:0;right:100%}.popup.popup_left .picker_arrow{top:0;right:0;-webkit-transform:scale(-1, 1);transform:scale(-1, 1)}.popup.popup_right{top:0;left:100%}.popup.popup_right .picker_arrow{top:0;left:0}',document.documentElement.firstElementChild.appendChild(t),n.StyleElement=t,n}()},402:function(ie,u){function V(X,k){if(!(this instanceof V))throw new SyntaxError("Constructor must be called with the new operator");this.message=X+" (char "+k+")",this.char=k,this.stack=new Error().stack}Object.defineProperty(u,"__esModule",{value:!0}),((u.default=V).prototype=new Error).constructor=Error},3860:function(ie,u,V){ie.exports=V(7490).default},7490:function(ie,u,V){u.default=function(g){n="",t=0,i=(s=g).charAt(0),e="",r=C,h();var y=r;if(d(),A(),e==="")return n;if(y===r&&c()){for(var w="";y===r&&c();)n=(0,k.insertBeforeLastWhitespace)(n,","),w+=n,n="",d(),A();return`[
`.concat(w).concat(n,`
]`)}throw new X.default("Unexpected characters",t-e.length)};var X=(u=V(402))&&u.__esModule?u:{default:u},k=V(9422),N=0,Z=1,O=2,W=3,F=4,L=5,C=6,m={"":!0,"{":!0,"}":!0,"[":!0,"]":!0,":":!0,",":!0,"(":!0,")":!0,";":!0,"+":!0},b={'"':'"',"\\":"\\","/":"/",b:"\b",f:"\f",n:`
`,r:"\r",t:"	"},x={"\b":"\\b","\f":"\\f","\n":"\\n","\r":"\\r","	":"\\t"},p={null:"null",true:"true",false:"false"},l={None:"null",True:"true",False:"false"},s="",n="",t=0,i="",e="",r=C;function a(){t++,i=s.charAt(t)}function o(){a(),i==="\\"&&a()}function c(){return r===N&&(e==="["||e==="{")||r===O||r===Z||r===W}function h(){if(n+=e,r=C,e="",m[i])r=N,e=i,a();else if((0,k.isDigit)(i)||i==="-"){if(r=Z,i==="-"){if(e+=i,a(),!(0,k.isDigit)(i))throw new X.default("Invalid number, digit expected",t)}else i==="0"&&(e+=i,a());for(;(0,k.isDigit)(i);)e+=i,a();if(i==="."){if(e+=i,a(),!(0,k.isDigit)(i))throw new X.default("Invalid number, digit expected",t);for(;(0,k.isDigit)(i);)e+=i,a()}if(i==="e"||i==="E"){if(e+=i,a(),i!=="+"&&i!=="-"||(e+=i,a()),!(0,k.isDigit)(i))throw new X.default("Invalid number, digit expected",t);for(;(0,k.isDigit)(i);)e+=i,a()}}else i==="\\"&&s.charAt(t+1)==='"'?(a(),v(o)):v(a);r===F&&(e=(0,k.normalizeWhitespace)(e),h()),r===L&&(r=C,e="",h())}function A(){e===","&&(e="",r=C,h())}function v(g){if((0,k.isQuote)(i)){var y=(0,k.normalizeQuote)(i),w=(0,k.isSingleQuote)(i)?k.isSingleQuote:k.isDoubleQuote;for(e+='"',r=O,g();i!==""&&!w(i);)if(i==="\\")if(g(),b[i]!==void 0)e+="\\"+i,g();else if(i==="u"){e+="\\u",g();for(var I=0;I<4;I++){if(!(0,k.isHex)(i))throw new X.default("Invalid unicode character",t-e.length);e+=i,g()}}else{if(i!=="'")throw new X.default('Invalid escape character "\\'+i+'"',t);e+="'",g()}else x[i]?e+=x[i]:e+=i==='"'?'\\"':i,g();if((0,k.normalizeQuote)(i)!==y)throw new X.default("End of string expected",t-e.length);e+='"',g()}else if((0,k.isAlpha)(i))for(r=W;(0,k.isAlpha)(i)||(0,k.isDigit)(i)||i==="$";)e+=i,a();else if((0,k.isWhitespace)(i)||(0,k.isSpecialWhitespace)(i))for(r=F;(0,k.isWhitespace)(i)||(0,k.isSpecialWhitespace)(i);)e+=i,a();else if(i==="/"&&s[t+1]==="*"){for(r=L;i!==""&&(i!=="*"||i==="*"&&s[t+1]!=="/");)e+=i,a();i==="*"&&s[t+1]==="/"&&(e+=i,a(),e+=i,a())}else if(i==="/"&&s[t+1]==="/")for(r=L;i!==""&&i!==`
`;)e+=i,a();else{for(r=C;i!=="";)e+=i,a();throw new X.default('Syntax error in part "'+e+'"',t-e.length)}}function d(){if(r===N&&e==="{")if(h(),r===N&&e==="}")h();else{for(;;){if(r!==W&&r!==Z||(r=O,e='"'.concat(e,'"')),r!==O)throw new X.default("Object key expected",t-e.length);if(h(),r===N&&e===":")h();else{if(!c())throw new X.default("Colon expected",t-e.length);n=(0,k.insertBeforeLastWhitespace)(n,":")}if(d(),r===N&&e===","){if(h(),r===N&&e==="}"){n=(0,k.stripLastOccurrence)(n,",");break}if(e===""){n=(0,k.stripLastOccurrence)(n,",");break}}else{if(r!==O&&r!==Z&&r!==W)break;n=(0,k.insertBeforeLastWhitespace)(n,",")}}r===N&&e==="}"?h():n=(0,k.insertBeforeLastWhitespace)(n,"}")}else if(r===N&&e==="[")if(h(),r===N&&e==="]")h();else{for(;;)if(d(),r===N&&e===","){if(h(),r===N&&e==="]"){n=(0,k.stripLastOccurrence)(n,",");break}if(e===""){n=(0,k.stripLastOccurrence)(n,",");break}}else{if(!c())break;n=(0,k.insertBeforeLastWhitespace)(n,",")}r===N&&e==="]"?h():n=(0,k.insertBeforeLastWhitespace)(n,"]")}else if(r===O)for(h();r===N&&e==="+";){var g;e="",h(),r===O&&(g=n.lastIndexOf('"'),n=n.substring(0,g)+e.substring(1),e="",h())}else if(r===Z)h();else{if(r!==W)throw e===""?new X.default("Unexpected end of json string",t-e.length):new X.default("Value expected",t-e.length);if(p[e])h();else if(l[e])e=l[e],h();else{var y=e,w=n.length;if(e="",h(),r===N&&e==="(")e="",h(),d(),r===N&&e===")"&&(e="",h(),r===N&&e===";"&&(e="",h()));else{for(n=(0,k.insertAtIndex)(n,'"'.concat(y),w);r===W||r===Z;)h();n+='"'}}}}},9422:function(ie,u){Object.defineProperty(u,"__esModule",{value:!0}),u.isAlpha=function(F){return k.test(F)},u.isHex=function(F){return N.test(F)},u.isDigit=function(F){return Z.test(F)},u.isWhitespace=O,u.isSpecialWhitespace=W,u.normalizeWhitespace=function(F){for(var L="",C=0;C<F.length;C++){var m=F[C];L+=W(m)?" ":m}return L},u.isQuote=function(F){return V[F]===!0||X[F]===!0},u.isSingleQuote=function(F){return V[F]===!0},u.isDoubleQuote=function(F){return X[F]===!0},u.normalizeQuote=function(F){return V[F]!==!0?X[F]!==!0?F:'"':"'"},u.stripLastOccurrence=function(F,L){return L=F.lastIndexOf(L),L!==-1?F.substring(0,L)+F.substring(L+1):F},u.insertBeforeLastWhitespace=function(F,L){var C=F.length;if(!O(F[C-1]))return F+L;for(;O(F[C-1]);)C--;return F.substring(0,C)+L+F.substring(C)},u.insertAtIndex=function(F,L,C){return F.substring(0,C)+L+F.substring(C)};var V={"'":!0,"\u2018":!0,"\u2019":!0,"`":!0,"\xB4":!0},X={'"':!0,"\u201C":!0,"\u201D":!0},k=/^[a-zA-Z_]$/,N=/^[0-9a-fA-F]$/,Z=/^[0-9]$/;function O(F){return F===" "||F==="	"||F===`
`||F==="\r"}function W(F){return F==="\xA0"||"\u2000"<=F&&F<="\u200A"||F==="\u202F"||F==="\u205F"||F==="\u3000"}},894:function(ie){ie.exports=JSON.parse('{"$schema":"http://json-schema.org/draft-07/schema#","$id":"https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#","description":"Meta-schema for $data reference (JSON Schema extension proposal)","type":"object","required":["$data"],"properties":{"$data":{"type":"string","anyOf":[{"format":"relative-json-pointer"},{"format":"json-pointer"}]}},"additionalProperties":false}')},7171:function(ie){ie.exports=JSON.parse('{"id":"http://json-schema.org/draft-04/schema#","$schema":"http://json-schema.org/draft-04/schema#","description":"Core schema meta-schema","definitions":{"schemaArray":{"type":"array","minItems":1,"items":{"$ref":"#"}},"positiveInteger":{"type":"integer","minimum":0},"positiveIntegerDefault0":{"allOf":[{"$ref":"#/definitions/positiveInteger"},{"default":0}]},"simpleTypes":{"enum":["array","boolean","integer","null","number","object","string"]},"stringArray":{"type":"array","items":{"type":"string"},"minItems":1,"uniqueItems":true}},"type":"object","properties":{"id":{"type":"string"},"$schema":{"type":"string"},"title":{"type":"string"},"description":{"type":"string"},"default":{},"multipleOf":{"type":"number","minimum":0,"exclusiveMinimum":true},"maximum":{"type":"number"},"exclusiveMaximum":{"type":"boolean","default":false},"minimum":{"type":"number"},"exclusiveMinimum":{"type":"boolean","default":false},"maxLength":{"$ref":"#/definitions/positiveInteger"},"minLength":{"$ref":"#/definitions/positiveIntegerDefault0"},"pattern":{"type":"string","format":"regex"},"additionalItems":{"anyOf":[{"type":"boolean"},{"$ref":"#"}],"default":{}},"items":{"anyOf":[{"$ref":"#"},{"$ref":"#/definitions/schemaArray"}],"default":{}},"maxItems":{"$ref":"#/definitions/positiveInteger"},"minItems":{"$ref":"#/definitions/positiveIntegerDefault0"},"uniqueItems":{"type":"boolean","default":false},"maxProperties":{"$ref":"#/definitions/positiveInteger"},"minProperties":{"$ref":"#/definitions/positiveIntegerDefault0"},"required":{"$ref":"#/definitions/stringArray"},"additionalProperties":{"anyOf":[{"type":"boolean"},{"$ref":"#"}],"default":{}},"definitions":{"type":"object","additionalProperties":{"$ref":"#"},"default":{}},"properties":{"type":"object","additionalProperties":{"$ref":"#"},"default":{}},"patternProperties":{"type":"object","additionalProperties":{"$ref":"#"},"default":{}},"dependencies":{"type":"object","additionalProperties":{"anyOf":[{"$ref":"#"},{"$ref":"#/definitions/stringArray"}]}},"enum":{"type":"array","minItems":1,"uniqueItems":true},"type":{"anyOf":[{"$ref":"#/definitions/simpleTypes"},{"type":"array","items":{"$ref":"#/definitions/simpleTypes"},"minItems":1,"uniqueItems":true}]},"format":{"type":"string"},"allOf":{"$ref":"#/definitions/schemaArray"},"anyOf":{"$ref":"#/definitions/schemaArray"},"oneOf":{"$ref":"#/definitions/schemaArray"},"not":{"$ref":"#"}},"dependencies":{"exclusiveMaximum":["maximum"],"exclusiveMinimum":["minimum"]},"default":{}}')},6273:function(ie){ie.exports=JSON.parse('{"$schema":"http://json-schema.org/draft-06/schema#","$id":"http://json-schema.org/draft-06/schema#","title":"Core schema meta-schema","definitions":{"schemaArray":{"type":"array","minItems":1,"items":{"$ref":"#"}},"nonNegativeInteger":{"type":"integer","minimum":0},"nonNegativeIntegerDefault0":{"allOf":[{"$ref":"#/definitions/nonNegativeInteger"},{"default":0}]},"simpleTypes":{"enum":["array","boolean","integer","null","number","object","string"]},"stringArray":{"type":"array","items":{"type":"string"},"uniqueItems":true,"default":[]}},"type":["object","boolean"],"properties":{"$id":{"type":"string","format":"uri-reference"},"$schema":{"type":"string","format":"uri"},"$ref":{"type":"string","format":"uri-reference"},"title":{"type":"string"},"description":{"type":"string"},"default":{},"examples":{"type":"array","items":{}},"multipleOf":{"type":"number","exclusiveMinimum":0},"maximum":{"type":"number"},"exclusiveMaximum":{"type":"number"},"minimum":{"type":"number"},"exclusiveMinimum":{"type":"number"},"maxLength":{"$ref":"#/definitions/nonNegativeInteger"},"minLength":{"$ref":"#/definitions/nonNegativeIntegerDefault0"},"pattern":{"type":"string","format":"regex"},"additionalItems":{"$ref":"#"},"items":{"anyOf":[{"$ref":"#"},{"$ref":"#/definitions/schemaArray"}],"default":{}},"maxItems":{"$ref":"#/definitions/nonNegativeInteger"},"minItems":{"$ref":"#/definitions/nonNegativeIntegerDefault0"},"uniqueItems":{"type":"boolean","default":false},"contains":{"$ref":"#"},"maxProperties":{"$ref":"#/definitions/nonNegativeInteger"},"minProperties":{"$ref":"#/definitions/nonNegativeIntegerDefault0"},"required":{"$ref":"#/definitions/stringArray"},"additionalProperties":{"$ref":"#"},"definitions":{"type":"object","additionalProperties":{"$ref":"#"},"default":{}},"properties":{"type":"object","additionalProperties":{"$ref":"#"},"default":{}},"patternProperties":{"type":"object","additionalProperties":{"$ref":"#"},"default":{}},"dependencies":{"type":"object","additionalProperties":{"anyOf":[{"$ref":"#"},{"$ref":"#/definitions/stringArray"}]}},"propertyNames":{"$ref":"#"},"const":{},"enum":{"type":"array","minItems":1,"uniqueItems":true},"type":{"anyOf":[{"$ref":"#/definitions/simpleTypes"},{"type":"array","items":{"$ref":"#/definitions/simpleTypes"},"minItems":1,"uniqueItems":true}]},"format":{"type":"string"},"allOf":{"$ref":"#/definitions/schemaArray"},"anyOf":{"$ref":"#/definitions/schemaArray"},"oneOf":{"$ref":"#/definitions/schemaArray"},"not":{"$ref":"#"}},"default":{}}')},6680:function(ie){ie.exports=JSON.parse('{"$schema":"http://json-schema.org/draft-07/schema#","$id":"http://json-schema.org/draft-07/schema#","title":"Core schema meta-schema","definitions":{"schemaArray":{"type":"array","minItems":1,"items":{"$ref":"#"}},"nonNegativeInteger":{"type":"integer","minimum":0},"nonNegativeIntegerDefault0":{"allOf":[{"$ref":"#/definitions/nonNegativeInteger"},{"default":0}]},"simpleTypes":{"enum":["array","boolean","integer","null","number","object","string"]},"stringArray":{"type":"array","items":{"type":"string"},"uniqueItems":true,"default":[]}},"type":["object","boolean"],"properties":{"$id":{"type":"string","format":"uri-reference"},"$schema":{"type":"string","format":"uri"},"$ref":{"type":"string","format":"uri-reference"},"$comment":{"type":"string"},"title":{"type":"string"},"description":{"type":"string"},"default":true,"readOnly":{"type":"boolean","default":false},"examples":{"type":"array","items":true},"multipleOf":{"type":"number","exclusiveMinimum":0},"maximum":{"type":"number"},"exclusiveMaximum":{"type":"number"},"minimum":{"type":"number"},"exclusiveMinimum":{"type":"number"},"maxLength":{"$ref":"#/definitions/nonNegativeInteger"},"minLength":{"$ref":"#/definitions/nonNegativeIntegerDefault0"},"pattern":{"type":"string","format":"regex"},"additionalItems":{"$ref":"#"},"items":{"anyOf":[{"$ref":"#"},{"$ref":"#/definitions/schemaArray"}],"default":true},"maxItems":{"$ref":"#/definitions/nonNegativeInteger"},"minItems":{"$ref":"#/definitions/nonNegativeIntegerDefault0"},"uniqueItems":{"type":"boolean","default":false},"contains":{"$ref":"#"},"maxProperties":{"$ref":"#/definitions/nonNegativeInteger"},"minProperties":{"$ref":"#/definitions/nonNegativeIntegerDefault0"},"required":{"$ref":"#/definitions/stringArray"},"additionalProperties":{"$ref":"#"},"definitions":{"type":"object","additionalProperties":{"$ref":"#"},"default":{}},"properties":{"type":"object","additionalProperties":{"$ref":"#"},"default":{}},"patternProperties":{"type":"object","additionalProperties":{"$ref":"#"},"propertyNames":{"format":"regex"},"default":{}},"dependencies":{"type":"object","additionalProperties":{"anyOf":[{"$ref":"#"},{"$ref":"#/definitions/stringArray"}]}},"propertyNames":{"$ref":"#"},"const":true,"enum":{"type":"array","items":true,"minItems":1,"uniqueItems":true},"type":{"anyOf":[{"$ref":"#/definitions/simpleTypes"},{"type":"array","items":{"$ref":"#/definitions/simpleTypes"},"minItems":1,"uniqueItems":true}]},"format":{"type":"string"},"contentMediaType":{"type":"string"},"contentEncoding":{"type":"string"},"if":{"$ref":"#"},"then":{"$ref":"#"},"else":{"$ref":"#"},"allOf":{"$ref":"#/definitions/schemaArray"},"anyOf":{"$ref":"#/definitions/schemaArray"},"oneOf":{"$ref":"#/definitions/schemaArray"},"not":{"$ref":"#"}},"default":true}')}},st={},Fe.amdD=function(){throw new Error("define cannot be used indirect")},Fe.n=function(ie){var u=ie&&ie.__esModule?function(){return ie.default}:function(){return ie};return Fe.d(u,{a:u}),u},Fe.d=function(ie,u){for(var V in u)Fe.o(u,V)&&!Fe.o(ie,V)&&Object.defineProperty(ie,V,{enumerable:!0,get:u[V]})},Fe.o=function(ie,u){return Object.prototype.hasOwnProperty.call(ie,u)},Fe.r=function(ie){typeof Symbol!="undefined"&&Symbol.toStringTag&&Object.defineProperty(ie,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(ie,"__esModule",{value:!0})},Fe.nmd=function(ie){return ie.paths=[],ie.children||(ie.children=[]),ie},Fe(3161);function Fe(ie){var u=st[ie];return u!==void 0||(u=st[ie]={id:ie,loaded:!1,exports:{}},it[ie].call(u.exports,u,u.exports,Fe),u.loaded=!0),u.exports}var it,st})})(Ht);var oi=Ut(Ht.exports);const ri=Ft({name:"JsonEdit",components:{},props:{modelValue:{type:[String,Object]},height:{type:String,default:"500px"},width:{type:String,default:"auto"},options:{type:Object,default:null},currentMode:{type:String,default:"tree"},modeList:{type:Array,default(){return["tree","code","form","text","view"]}}},setup(Ie,{emit:le}){let{modelValue:Fe,options:it,modeList:st,currentMode:ie}=_t(Ie);const u=Mt(null);let V=null,X="string",k=!1;const N=Vt({height:"500px",width:"auto"});Qt(()=>{N.width=Ie.width,N.height=Ie.height,W(),Z(Fe.value)}),qt(()=>{V==null||V.destroy(),V=null}),ei(()=>Ie.modelValue,F=>{V||W(),Z(F)});const Z=F=>{k||(typeof F=="string"?(X="string",V.set(JSON.parse(F))):(X="object",V.set(F)))},O=()=>{try{const F=V.get();X=="string"?le("update:modelValue",JSON.stringify(F)):le("update:modelValue",F),le("onChange",F),k=!0,ti(()=>{k=!1})}catch{}},W=()=>{console.log("init json editor");const F=Et(kt({},it.value),{mode:ie.value,modes:st.value,onChange:O});V=new oi(u.value,F)};return Et(kt({},_t(N)),{jsoneditorVue:u})}});function si(Ie,le,Fe,it,st,ie){return qe(),gt("div",null,[tt("div",{ref:"jsoneditorVue",style:ii({height:Ie.height,width:Ie.width})},null,4)])}var ai=jt(ri,[["render",si]]);const li=Ft({name:"MongoDataOp",components:{ProjectEnvSelect:Xt,JsonEdit:ai},setup(){const Ie=Mt(null),le=Vt({loading:!1,mongoList:[],query:{envId:0},mongoId:null,database:"",collection:"",activeName:"",databases:[],collections:[],dataTabs:{},findDialog:{visible:!1,findParam:{filter:"",sort:""}},insertDocDialog:{visible:!1,doc:""},jsoneditorDialog:{visible:!1,doc:"",item:{}}}),Fe=async()=>{Yt(le.query.envId,"\u8BF7\u5148\u9009\u62E9\u9879\u76EE\u73AF\u5883");const s=await ut.mongoList.request(le.query);le.mongoList=s.list},it=(s,n)=>{le.databases=[],le.collections=[],le.mongoId=null,le.collection="",le.database="",le.dataTabs={},n!=null&&(le.query.envId=n,Fe())},st=()=>{le.databases=[],le.collections=[],le.dataTabs={},ie()},ie=async()=>{const s=await ut.databases.request({id:le.mongoId});le.databases=s.Databases},u=()=>{le.collections=[],le.collection="",le.dataTabs={},V()},V=async()=>{le.collections=await ut.collections.request({id:le.mongoId,database:le.database})},X=()=>{const s=le.collection;if(!le.dataTabs[s]){const t={filter:"{}",sort:'{"_id": -1}',skip:0,limit:12},i={name:s,datas:[],findParamStr:JSON.stringify(t),findParam:t};le.dataTabs[s]=i}le.activeName=s,Z(s)},k=s=>{const n=Object.keys(le.dataTabs);for(let t=0;t<n.length;t++)s==n[t]&&Ie.value[t].blur();le.findDialog.findParam=le.dataTabs[s].findParam,le.findDialog.visible=!0},N=()=>{le.dataTabs[le.activeName].findParam=le.findDialog.findParam,le.dataTabs[le.activeName].findParamStr=JSON.stringify(le.findDialog.findParam),le.findDialog.visible=!1,Z(le.activeName)},Z=async s=>{const t=le.dataTabs[s].findParam;let i,e;try{i=t.filter?JSON.parse(t.filter):{},e=t.sort?JSON.parse(t.sort):{}}catch{ft.error("filter\u6216sort\u5B57\u6BB5json\u5B57\u7B26\u4E32\u503C\u9519\u8BEF\u3002\u6CE8\u610F: json key\u9700\u53CC\u5F15\u53F7");return}const r=await ut.findCommand.request({id:le.mongoId,database:le.database,collection:s,filter:i,sort:e,limit:t.limit||12,skip:t.skip||0});le.dataTabs[s].datas=O(r)},O=s=>{const n=[];if(!s)return n;for(let t of s)n.push({value:JSON.stringify(t,null,4)});return n},W=()=>{const s=le.dataTabs[le.activeName].datas[0];let n="";if(s){const t=JSON.parse(s.value);delete t._id,n=JSON.stringify(t,null,4)}le.insertDocDialog.doc=n,le.insertDocDialog.visible=!0},F=async()=>{let s;try{s=JSON.parse(le.insertDocDialog.doc)}catch{ft.error("\u6587\u6863\u5185\u5BB9\u9519\u8BEF,\u65E0\u6CD5\u89E3\u6790\u4E3Ajson\u5BF9\u8C61")}const n=await ut.insertCommand.request({id:le.mongoId,database:le.database,collection:le.activeName,doc:s});Tt(n.InsertedID,"\u65B0\u589E\u5931\u8D25"),ft.success("\u65B0\u589E\u6210\u529F"),Z(le.activeName),le.insertDocDialog.visible=!1},L=s=>{le.jsoneditorDialog.item=s,le.jsoneditorDialog.doc=s.value,le.jsoneditorDialog.visible=!0},C=()=>{le.jsoneditorDialog.item.value=JSON.stringify(JSON.parse(le.jsoneditorDialog.doc),null,4)},m=async s=>{const n=x(s),t=n._id;Pt(t,"\u6587\u6863\u7684_id\u5C5E\u6027\u4E0D\u5B58\u5728"),delete n._id;const i=await ut.updateByIdCommand.request({id:le.mongoId,database:le.database,collection:le.collection,docId:t,update:{$set:n}});Tt(i.ModifiedCount==1,"\u4FEE\u6539\u5931\u8D25"),ft.success("\u4FDD\u5B58\u6210\u529F")},b=async s=>{const t=x(s)._id;Pt(t,"\u6587\u6863\u7684_id\u5C5E\u6027\u4E0D\u5B58\u5728");const i=await ut.deleteByIdCommand.request({id:le.mongoId,database:le.database,collection:le.collection,docId:t});Tt(i.DeletedCount==1,"\u5220\u9664\u5931\u8D25"),ft.success("\u5220\u9664\u6210\u529F"),Z(le.activeName)},x=s=>{try{return JSON.parse(s)}catch(n){throw ft.error("\u6587\u6863\u5185\u5BB9\u89E3\u6790\u4E3Ajson\u5BF9\u8C61\u5931\u8D25"),n}},p=s=>{const n=s.props.name;le.collection=n},l=s=>{const n=Object.keys(le.dataTabs);let t=le.activeName;n.forEach((i,e)=>{if(i===s){const r=n[e+1]||n[e-1];r&&(t=r)}}),le.activeName=t,t==s?le.collection="":le.collection=t,delete le.dataTabs[s]};return Et(kt({},_t(le)),{findParamInputRef:Ie,changeProjectEnv:it,changeMongo:st,changeDatabase:u,changeCollection:X,onDataTabClick:p,removeDataTab:l,showFindDialog:k,confirmFindDialog:N,findCommand:Z,showInsertDocDialog:W,onInsertDoc:F,onSaveDoc:m,onDeleteDoc:b,onJsonEditor:L,onCloseJsonEditDialog:C,formatByteSize:Jt})}}),ci={class:"toolbar"},di={style:{float:"left"}},hi={style:{float:"right",color:"#8492a6","margin-left":"6px","font-size":"13px"}},ui={style:{float:"left"}},gi={style:{float:"right",color:"#8492a6","margin-left":"4px","font-size":"13px"}},pi={style:{padding:"3px",float:"right"},class:"mr5 mongo-doc-btns"},mi=tt("div",{style:{"text-align":"center","margin-top":"10px"}},null,-1);function fi(Ie,le,Fe,it,st,ie){const u=Je("el-option"),V=Je("el-select"),X=Je("el-form-item"),k=Je("project-env-select"),N=Je("el-col"),Z=Je("el-row"),O=Je("el-link"),W=Je("el-input"),F=Je("el-divider"),L=Je("el-popconfirm"),C=Je("el-card"),m=Je("el-tab-pane"),b=Je("el-tabs"),x=Je("el-container"),p=Je("el-form"),l=Je("el-button"),s=Je("el-dialog"),n=Je("json-edit");return qe(),gt("div",null,[tt("div",ci,[Be(Z,{type:"flex",justify:"space-between"},{default:Ge(()=>[Be(N,{span:24},{default:Ge(()=>[Be(k,{onChangeProjectEnv:Ie.changeProjectEnv},{default:Ge(()=>[Be(X,{label:"\u5B9E\u4F8B","label-width":"40px"},{default:Ge(()=>[Be(V,{modelValue:Ie.mongoId,"onUpdate:modelValue":le[0]||(le[0]=t=>Ie.mongoId=t),placeholder:"\u8BF7\u9009\u62E9mongo",onChange:Ie.changeMongo},{default:Ge(()=>[(qe(!0),gt(It,null,bt(Ie.mongoList,t=>(qe(),mt(u,{key:t.id,label:t.name,value:t.id},{default:Ge(()=>[tt("span",di,Rt(t.name),1),tt("span",hi,Rt(` [${t.uri}]`),1)]),_:2},1032,["label","value"]))),128))]),_:1},8,["modelValue","onChange"])]),_:1}),Be(X,{label:"\u5E93","label-width":"20px"},{default:Ge(()=>[Be(V,{modelValue:Ie.database,"onUpdate:modelValue":le[1]||(le[1]=t=>Ie.database=t),placeholder:"\u8BF7\u9009\u62E9\u5E93",onChange:Ie.changeDatabase,filterable:""},{default:Ge(()=>[(qe(!0),gt(It,null,bt(Ie.databases,t=>(qe(),mt(u,{key:t.Name,label:t.Name,value:t.Name},{default:Ge(()=>[tt("span",ui,Rt(t.Name),1),tt("span",gi,Rt(` [${Ie.formatByteSize(t.SizeOnDisk)}]`),1)]),_:2},1032,["label","value"]))),128))]),_:1},8,["modelValue","onChange"])]),_:1}),Be(X,{label:"\u96C6\u5408","label-width":"40px"},{default:Ge(()=>[Be(V,{modelValue:Ie.collection,"onUpdate:modelValue":le[2]||(le[2]=t=>Ie.collection=t),placeholder:"\u8BF7\u9009\u62E9\u96C6\u5408",onChange:Ie.changeCollection,filterable:""},{default:Ge(()=>[(qe(!0),gt(It,null,bt(Ie.collections,t=>(qe(),mt(u,{key:t,label:t,value:t},null,8,["label","value"]))),128))]),_:1},8,["modelValue","onChange"])]),_:1})]),_:1},8,["onChangeProjectEnv"])]),_:1})]),_:1})]),Be(x,{id:"data-exec",style:{border:"1px solid #eee","margin-top":"1px"}},{default:Ge(()=>[Be(b,{onTabRemove:Ie.removeDataTab,onTabClick:Ie.onDataTabClick,style:{width:"100%","margin-left":"5px"},modelValue:Ie.activeName,"onUpdate:modelValue":le[4]||(le[4]=t=>Ie.activeName=t)},{default:Ge(()=>[(qe(!0),gt(It,null,bt(Ie.dataTabs,t=>(qe(),mt(m,{closable:"",key:t.name,label:t.name,name:t.name},{default:Ge(()=>[Ie.mongoId?(qe(),mt(Z,{key:0},{default:Ge(()=>[Be(O,{onClick:le[3]||(le[3]=i=>Ie.findCommand(Ie.activeName)),icon:"refresh",underline:!1,class:"ml5"}),Be(O,{onClick:Ie.showInsertDocDialog,class:"ml5",type:"primary",icon:"plus",underline:!1},null,8,["onClick"])]),_:1})):ni("",!0),Be(Z,{class:"mt5 mb5"},{default:Ge(()=>[Be(W,{ref_for:!0,ref:"findParamInputRef",modelValue:t.findParamStr,"onUpdate:modelValue":i=>t.findParamStr=i,placeholder:"\u70B9\u51FB\u8F93\u5165\u76F8\u5E94\u67E5\u8BE2\u6761\u4EF6",onFocus:i=>Ie.showFindDialog(t.name)},{prepend:Ge(()=>[At("\u67E5\u8BE2\u53C2\u6570")]),_:2},1032,["modelValue","onUpdate:modelValue","onFocus"])]),_:2},1024),Be(Z,null,{default:Ge(()=>[(qe(!0),gt(It,null,bt(t.datas,i=>(qe(),mt(N,{span:6,key:i},{default:Ge(()=>[Be(C,{"body-style":{padding:"0px",position:"relative"}},{default:Ge(()=>[Be(W,{type:"textarea",modelValue:i.value,"onUpdate:modelValue":e=>i.value=e,rows:12},null,8,["modelValue","onUpdate:modelValue"]),tt("div",pi,[tt("div",null,[Be(O,{onClick:e=>Ie.onJsonEditor(i),underline:!1,type:"success",icon:"MagicStick"},null,8,["onClick"]),Be(F,{direction:"vertical","border-style":"dashed"}),Be(O,{onClick:e=>Ie.onSaveDoc(i.value),underline:!1,type:"warning",icon:"DocumentChecked"},null,8,["onClick"]),Be(F,{direction:"vertical","border-style":"dashed"}),Be(L,{onConfirm:e=>Ie.onDeleteDoc(i.value),title:"\u786E\u5B9A\u5220\u9664\u8BE5\u6587\u6863?"},{reference:Ge(()=>[Be(O,{underline:!1,type:"danger",icon:"DocumentDelete"})]),_:2},1032,["onConfirm"])])])]),_:2},1024)]),_:2},1024))),128))]),_:2},1024)]),_:2},1032,["label","name"]))),128))]),_:1},8,["onTabRemove","onTabClick","modelValue"])]),_:1}),Be(s,{width:"600px",title:"find\u53C2\u6570",modelValue:Ie.findDialog.visible,"onUpdate:modelValue":le[10]||(le[10]=t=>Ie.findDialog.visible=t)},{footer:Ge(()=>[tt("div",null,[Be(l,{onClick:le[9]||(le[9]=t=>Ie.findDialog.visible=!1)},{default:Ge(()=>[At("\u53D6 \u6D88")]),_:1}),Be(l,{onClick:Ie.confirmFindDialog,type:"primary"},{default:Ge(()=>[At("\u786E \u5B9A")]),_:1},8,["onClick"])])]),default:Ge(()=>[Be(p,{"label-width":"70px"},{default:Ge(()=>[Be(X,{label:"filter"},{default:Ge(()=>[Be(W,{modelValue:Ie.findDialog.findParam.filter,"onUpdate:modelValue":le[5]||(le[5]=t=>Ie.findDialog.findParam.filter=t),type:"textarea",rows:6,clearable:"","auto-complete":"off"},null,8,["modelValue"])]),_:1}),Be(X,{label:"sort"},{default:Ge(()=>[Be(W,{modelValue:Ie.findDialog.findParam.sort,"onUpdate:modelValue":le[6]||(le[6]=t=>Ie.findDialog.findParam.sort=t),type:"textarea",rows:3,clearable:"","auto-complete":"off"},null,8,["modelValue"])]),_:1}),Be(X,{label:"limit"},{default:Ge(()=>[Be(W,{modelValue:Ie.findDialog.findParam.limit,"onUpdate:modelValue":le[7]||(le[7]=t=>Ie.findDialog.findParam.limit=t),modelModifiers:{number:!0},type:"number","auto-complete":"off"},null,8,["modelValue"])]),_:1}),Be(X,{label:"skip"},{default:Ge(()=>[Be(W,{modelValue:Ie.findDialog.findParam.skip,"onUpdate:modelValue":le[8]||(le[8]=t=>Ie.findDialog.findParam.skip=t),modelModifiers:{number:!0},type:"number","auto-complete":"off"},null,8,["modelValue"])]),_:1})]),_:1})]),_:1},8,["modelValue"]),Be(s,{width:"800px",title:`\u65B0\u589E'${Ie.activeName}'\u96C6\u5408\u6587\u6863`,modelValue:Ie.insertDocDialog.visible,"onUpdate:modelValue":le[13]||(le[13]=t=>Ie.insertDocDialog.visible=t),"close-on-click-modal":!1},{footer:Ge(()=>[tt("div",null,[Be(l,{onClick:le[12]||(le[12]=t=>Ie.insertDocDialog.visible=!1)},{default:Ge(()=>[At("\u53D6 \u6D88")]),_:1}),Be(l,{onClick:Ie.onInsertDoc,type:"primary"},{default:Ge(()=>[At("\u786E \u5B9A")]),_:1},8,["onClick"])])]),default:Ge(()=>[Be(n,{currentMode:"code",modelValue:Ie.insertDocDialog.doc,"onUpdate:modelValue":le[11]||(le[11]=t=>Ie.insertDocDialog.doc=t)},null,8,["modelValue"])]),_:1},8,["title","modelValue"]),Be(s,{width:"70%",title:"json\u7F16\u8F91\u5668",modelValue:Ie.jsoneditorDialog.visible,"onUpdate:modelValue":le[15]||(le[15]=t=>Ie.jsoneditorDialog.visible=t),onClose:Ie.onCloseJsonEditDialog,"close-on-click-modal":!1},{default:Ge(()=>[Be(n,{modelValue:Ie.jsoneditorDialog.doc,"onUpdate:modelValue":le[14]||(le[14]=t=>Ie.jsoneditorDialog.doc=t)},null,8,["modelValue"])]),_:1},8,["modelValue","onClose"]),mi])}var Si=jt(li,[["render",fi]]);export{Si as default};
