123456789 |
- import{c as ye}from"./index-693c203b.js";function Ne(m,T){for(var $=0;$<T.length;$++){const d=T[$];if(typeof d!="string"&&!Array.isArray(d)){for(const p in d)if(p!=="default"&&!(p in m)){const s=Object.getOwnPropertyDescriptor(d,p);s&&Object.defineProperty(m,p,s.get?s:{enumerable:!0,get:()=>d[p]})}}}return Object.freeze(Object.defineProperty(m,Symbol.toStringTag,{value:"Module"}))}var de={};(function(m){if(typeof m.window<"u"&&m.document||m.require&&m.define)return;m.console||(m.console=function(){var p=Array.prototype.slice.call(arguments,0);postMessage({type:"log",data:p})},m.console.error=m.console.warn=m.console.log=m.console.trace=m.console),m.window=m,m.ace=m,m.onerror=function(p,s,n,i,a){postMessage({type:"error",data:{message:p,data:a&&a.data,file:s,line:n,col:i,stack:a&&a.stack}})},m.normalizeModule=function(p,s){if(s.indexOf("!")!==-1){var n=s.split("!");return m.normalizeModule(p,n[0])+"!"+m.normalizeModule(p,n[1])}if(s.charAt(0)=="."){var i=p.split("/").slice(0,-1).join("/");for(s=(i?i+"/":"")+s;s.indexOf(".")!==-1&&a!=s;){var a=s;s=s.replace(/^\.\//,"").replace(/\/\.\//,"/").replace(/[^\/]+\/\.\.\//,"")}}return s},m.require=function(s,n){if(n||(n=s,s=null),!n.charAt)throw new Error("worker.js require() accepts only (parentId, id) as arguments");n=m.normalizeModule(s,n);var i=m.require.modules[n];if(i)return i.initialized||(i.initialized=!0,i.exports=i.factory().exports),i.exports;if(!m.require.tlns)return console.log("unable to load "+n);var a=T(n,m.require.tlns);return a.slice(-3)!=".js"&&(a+=".js"),m.require.id=n,m.require.modules[n]={},importScripts(a),m.require(s,n)};function T(p,s){for(var n=p,i="";n;){var a=s[n];if(typeof a=="string")return a+i;if(a)return a.location.replace(/\/*$/,"/")+(i||a.main||a.name);if(a===!1)return"";var u=n.lastIndexOf("/");if(u===-1)break;i=n.substr(u)+i,n=n.slice(0,u)}return p}m.require.modules={},m.require.tlns={},m.define=function(p,s,n){if(arguments.length==2?(n=s,typeof p!="string"&&(s=p,p=m.require.id)):arguments.length==1&&(n=p,s=[],p=m.require.id),typeof n!="function"){m.require.modules[p]={exports:n,initialized:!0};return}s.length||(s=["require","exports","module"]);var i=function(a){return m.require(p,a)};m.require.modules[p]={exports:{},factory:function(){var a=this,u=n.apply(this,s.slice(0,n.length).map(function(r){switch(r){case"require":return i;case"exports":return a.exports;case"module":return a;default:return i(r)}}));return u&&(a.exports=u),a}}},m.define.amd={},m.require.tlns={},m.initBaseUrls=function(s){for(var n in s)this.require.tlns[n]=s[n]},m.initSender=function(){var s=m.require("ace/lib/event_emitter").EventEmitter,n=m.require("ace/lib/oop"),i=function(){};return function(){n.implement(this,s),this.callback=function(a,u){postMessage({type:"call",id:u,data:a})},this.emit=function(a,u){postMessage({type:"event",name:a,data:u})}}.call(i.prototype),new i};var $=m.main=null,d=m.sender=null;m.onmessage=function(p){var s=p.data;if(s.event&&d)d._signal(s.event,s.data);else if(s.command)if($[s.command])$[s.command].apply($,s.args);else if(m[s.command])m[s.command].apply(m,s.args);else throw new Error("Unknown command:"+s.command);else if(s.init){m.initBaseUrls(s.tlns),d=m.sender=m.initSender();var n=this.require(s.module)[s.classname];$=m.main=new n(d)}}})(ye);ace.define("ace/lib/oop",[],function(m,T,$){T.inherits=function(d,p){d.super_=p,d.prototype=Object.create(p.prototype,{constructor:{value:d,enumerable:!1,writable:!0,configurable:!0}})},T.mixin=function(d,p){for(var s in p)d[s]=p[s];return d},T.implement=function(d,p){T.mixin(d,p)}});ace.define("ace/lib/lang",[],function(m,T,$){T.last=function(s){return s[s.length-1]},T.stringReverse=function(s){return s.split("").reverse().join("")},T.stringRepeat=function(s,n){for(var i="";n>0;)n&1&&(i+=s),(n>>=1)&&(s+=s);return i};var d=/^\s\s*/,p=/\s\s*$/;T.stringTrimLeft=function(s){return s.replace(d,"")},T.stringTrimRight=function(s){return s.replace(p,"")},T.copyObject=function(s){var n={};for(var i in s)n[i]=s[i];return n},T.copyArray=function(s){for(var n=[],i=0,a=s.length;i<a;i++)s[i]&&typeof s[i]=="object"?n[i]=this.copyObject(s[i]):n[i]=s[i];return n},T.deepCopy=function s(n){if(typeof n!="object"||!n)return n;var i;if(Array.isArray(n)){i=[];for(var a=0;a<n.length;a++)i[a]=s(n[a]);return i}if(Object.prototype.toString.call(n)!=="[object Object]")return n;i={};for(var a in n)i[a]=s(n[a]);return i},T.arrayToMap=function(s){for(var n={},i=0;i<s.length;i++)n[s[i]]=1;return n},T.createMap=function(s){var n=Object.create(null);for(var i in s)n[i]=s[i];return n},T.arrayRemove=function(s,n){for(var i=0;i<=s.length;i++)n===s[i]&&s.splice(i,1)},T.escapeRegExp=function(s){return s.replace(/([.*+?^${}()|[\]\/\\])/g,"\\$1")},T.escapeHTML=function(s){return(""+s).replace(/&/g,"&").replace(/"/g,""").replace(/'/g,"'").replace(/</g,"<")},T.getMatchOffsets=function(s,n){var i=[];return s.replace(n,function(a){i.push({offset:arguments[arguments.length-2],length:a.length})}),i},T.deferredCall=function(s){var n=null,i=function(){n=null,s()},a=function(u){return a.cancel(),n=setTimeout(i,u||0),a};return a.schedule=a,a.call=function(){return this.cancel(),s(),a},a.cancel=function(){return clearTimeout(n),n=null,a},a.isPending=function(){return n},a},T.delayedCall=function(s,n){var i=null,a=function(){i=null,s()},u=function(r){i==null&&(i=setTimeout(a,r||n))};return u.delay=function(r){i&&clearTimeout(i),i=setTimeout(a,r||n)},u.schedule=u,u.call=function(){this.cancel(),s()},u.cancel=function(){i&&clearTimeout(i),i=null},u.isPending=function(){return i},u}});ace.define("ace/apply_delta",[],function(m,T,$){T.applyDelta=function(d,p,s){var n=p.start.row,i=p.start.column,a=d[n]||"";switch(p.action){case"insert":var u=p.lines;if(u.length===1)d[n]=a.substring(0,i)+p.lines[0]+a.substring(i);else{var r=[n,1].concat(p.lines);d.splice.apply(d,r),d[n]=a.substring(0,i)+d[n],d[n+p.lines.length-1]+=a.substring(i)}break;case"remove":var c=p.end.column,l=p.end.row;n===l?d[n]=a.substring(0,i)+a.substring(c):d.splice(n,l-n+1,a.substring(0,i)+d[l].substring(c));break}}});ace.define("ace/lib/event_emitter",[],function(m,T,$){var d={},p=function(){this.propagationStopped=!0},s=function(){this.defaultPrevented=!0};d._emit=d._dispatchEvent=function(n,i){this._eventRegistry||(this._eventRegistry={}),this._defaultHandlers||(this._defaultHandlers={});var a=this._eventRegistry[n]||[],u=this._defaultHandlers[n];if(!(!a.length&&!u)){(typeof i!="object"||!i)&&(i={}),i.type||(i.type=n),i.stopPropagation||(i.stopPropagation=p),i.preventDefault||(i.preventDefault=s),a=a.slice();for(var r=0;r<a.length&&(a[r](i,this),!i.propagationStopped);r++);if(u&&!i.defaultPrevented)return u(i,this)}},d._signal=function(n,i){var a=(this._eventRegistry||{})[n];if(a){a=a.slice();for(var u=0;u<a.length;u++)a[u](i,this)}},d.once=function(n,i){var a=this;if(this.on(n,function u(){a.off(n,u),i.apply(null,arguments)}),!i)return new Promise(function(u){i=u})},d.setDefaultHandler=function(n,i){var a=this._defaultHandlers;if(a||(a=this._defaultHandlers={_disabled_:{}}),a[n]){var u=a[n],r=a._disabled_[n];r||(a._disabled_[n]=r=[]),r.push(u);var c=r.indexOf(i);c!=-1&&r.splice(c,1)}a[n]=i},d.removeDefaultHandler=function(n,i){var a=this._defaultHandlers;if(a){var u=a._disabled_[n];if(a[n]==i)u&&this.setDefaultHandler(n,u.pop());else if(u){var r=u.indexOf(i);r!=-1&&u.splice(r,1)}}},d.on=d.addEventListener=function(n,i,a){this._eventRegistry=this._eventRegistry||{};var u=this._eventRegistry[n];return u||(u=this._eventRegistry[n]=[]),u.indexOf(i)==-1&&u[a?"unshift":"push"](i),i},d.off=d.removeListener=d.removeEventListener=function(n,i){this._eventRegistry=this._eventRegistry||{};var a=this._eventRegistry[n];if(a){var u=a.indexOf(i);u!==-1&&a.splice(u,1)}},d.removeAllListeners=function(n){n||(this._eventRegistry=this._defaultHandlers=void 0),this._eventRegistry&&(this._eventRegistry[n]=void 0),this._defaultHandlers&&(this._defaultHandlers[n]=void 0)},T.EventEmitter=d});ace.define("ace/range",[],function(m,T,$){var d=function(s,n){return s.row-n.row||s.column-n.column},p=function(){function s(n,i,a,u){this.start={row:n,column:i},this.end={row:a,column:u}}return s.prototype.isEqual=function(n){return this.start.row===n.start.row&&this.end.row===n.end.row&&this.start.column===n.start.column&&this.end.column===n.end.column},s.prototype.toString=function(){return"Range: ["+this.start.row+"/"+this.start.column+"] -> ["+this.end.row+"/"+this.end.column+"]"},s.prototype.contains=function(n,i){return this.compare(n,i)==0},s.prototype.compareRange=function(n){var i,a=n.end,u=n.start;return i=this.compare(a.row,a.column),i==1?(i=this.compare(u.row,u.column),i==1?2:i==0?1:0):i==-1?-2:(i=this.compare(u.row,u.column),i==-1?-1:i==1?42:0)},s.prototype.comparePoint=function(n){return this.compare(n.row,n.column)},s.prototype.containsRange=function(n){return this.comparePoint(n.start)==0&&this.comparePoint(n.end)==0},s.prototype.intersects=function(n){var i=this.compareRange(n);return i==-1||i==0||i==1},s.prototype.isEnd=function(n,i){return this.end.row==n&&this.end.column==i},s.prototype.isStart=function(n,i){return this.start.row==n&&this.start.column==i},s.prototype.setStart=function(n,i){typeof n=="object"?(this.start.column=n.column,this.start.row=n.row):(this.start.row=n,this.start.column=i)},s.prototype.setEnd=function(n,i){typeof n=="object"?(this.end.column=n.column,this.end.row=n.row):(this.end.row=n,this.end.column=i)},s.prototype.inside=function(n,i){return this.compare(n,i)==0?!(this.isEnd(n,i)||this.isStart(n,i)):!1},s.prototype.insideStart=function(n,i){return this.compare(n,i)==0?!this.isEnd(n,i):!1},s.prototype.insideEnd=function(n,i){return this.compare(n,i)==0?!this.isStart(n,i):!1},s.prototype.compare=function(n,i){return!this.isMultiLine()&&n===this.start.row?i<this.start.column?-1:i>this.end.column?1:0:n<this.start.row?-1:n>this.end.row?1:this.start.row===n?i>=this.start.column?0:-1:this.end.row===n?i<=this.end.column?0:1:0},s.prototype.compareStart=function(n,i){return this.start.row==n&&this.start.column==i?-1:this.compare(n,i)},s.prototype.compareEnd=function(n,i){return this.end.row==n&&this.end.column==i?1:this.compare(n,i)},s.prototype.compareInside=function(n,i){return this.end.row==n&&this.end.column==i?1:this.start.row==n&&this.start.column==i?-1:this.compare(n,i)},s.prototype.clipRows=function(n,i){if(this.end.row>i)var a={row:i+1,column:0};else if(this.end.row<n)var a={row:n,column:0};if(this.start.row>i)var u={row:i+1,column:0};else if(this.start.row<n)var u={row:n,column:0};return s.fromPoints(u||this.start,a||this.end)},s.prototype.extend=function(n,i){var a=this.compare(n,i);if(a==0)return this;if(a==-1)var u={row:n,column:i};else var r={row:n,column:i};return s.fromPoints(u||this.start,r||this.end)},s.prototype.isEmpty=function(){return this.start.row===this.end.row&&this.start.column===this.end.column},s.prototype.isMultiLine=function(){return this.start.row!==this.end.row},s.prototype.clone=function(){return s.fromPoints(this.start,this.end)},s.prototype.collapseRows=function(){return this.end.column==0?new s(this.start.row,0,Math.max(this.start.row,this.end.row-1),0):new s(this.start.row,0,this.end.row,0)},s.prototype.toScreenRange=function(n){var i=n.documentToScreenPosition(this.start),a=n.documentToScreenPosition(this.end);return new s(i.row,i.column,a.row,a.column)},s.prototype.moveBy=function(n,i){this.start.row+=n,this.start.column+=i,this.end.row+=n,this.end.column+=i},s}();p.fromPoints=function(s,n){return new p(s.row,s.column,n.row,n.column)},p.comparePoints=d,p.comparePoints=function(s,n){return s.row-n.row||s.column-n.column},T.Range=p});ace.define("ace/anchor",[],function(m,T,$){var d=m("./lib/oop"),p=m("./lib/event_emitter").EventEmitter,s=function(){function a(u,r,c){this.$onChange=this.onChange.bind(this),this.attach(u),typeof c>"u"?this.setPosition(r.row,r.column):this.setPosition(r,c)}return a.prototype.getPosition=function(){return this.$clipPositionToDocument(this.row,this.column)},a.prototype.getDocument=function(){return this.document},a.prototype.onChange=function(u){if(!(u.start.row==u.end.row&&u.start.row!=this.row)&&!(u.start.row>this.row)){var r=i(u,{row:this.row,column:this.column},this.$insertRight);this.setPosition(r.row,r.column,!0)}},a.prototype.setPosition=function(u,r,c){var l;if(c?l={row:u,column:r}:l=this.$clipPositionToDocument(u,r),!(this.row==l.row&&this.column==l.column)){var g={row:this.row,column:this.column};this.row=l.row,this.column=l.column,this._signal("change",{old:g,value:l})}},a.prototype.detach=function(){this.document.off("change",this.$onChange)},a.prototype.attach=function(u){this.document=u||this.document,this.document.on("change",this.$onChange)},a.prototype.$clipPositionToDocument=function(u,r){var c={};return u>=this.document.getLength()?(c.row=Math.max(0,this.document.getLength()-1),c.column=this.document.getLine(c.row).length):u<0?(c.row=0,c.column=0):(c.row=u,c.column=Math.min(this.document.getLine(c.row).length,Math.max(0,r))),r<0&&(c.column=0),c},a}();s.prototype.$insertRight=!1,d.implement(s.prototype,p);function n(a,u,r){var c=r?a.column<=u.column:a.column<u.column;return a.row<u.row||a.row==u.row&&c}function i(a,u,r){var c=a.action=="insert",l=(c?1:-1)*(a.end.row-a.start.row),g=(c?1:-1)*(a.end.column-a.start.column),y=a.start,D=c?y:a.end;return n(u,y,r)?{row:u.row,column:u.column}:n(D,u,!r)?{row:u.row+l,column:u.column+(u.row==D.row?g:0)}:{row:y.row,column:y.column}}T.Anchor=s});ace.define("ace/document",[],function(m,T,$){var d=m("./lib/oop"),p=m("./apply_delta").applyDelta,s=m("./lib/event_emitter").EventEmitter,n=m("./range").Range,i=m("./anchor").Anchor,a=function(){function u(r){this.$lines=[""],r.length===0?this.$lines=[""]:Array.isArray(r)?this.insertMergedLines({row:0,column:0},r):this.insert({row:0,column:0},r)}return u.prototype.setValue=function(r){var c=this.getLength()-1;this.remove(new n(0,0,c,this.getLine(c).length)),this.insert({row:0,column:0},r||"")},u.prototype.getValue=function(){return this.getAllLines().join(this.getNewLineCharacter())},u.prototype.createAnchor=function(r,c){return new i(this,r,c)},u.prototype.$detectNewLine=function(r){var c=r.match(/^.*?(\r\n|\r|\n)/m);this.$autoNewLine=c?c[1]:`
- `,this._signal("changeNewLineMode")},u.prototype.getNewLineCharacter=function(){switch(this.$newLineMode){case"windows":return`\r
- `;case"unix":return`
- `;default:return this.$autoNewLine||`
- `}},u.prototype.setNewLineMode=function(r){this.$newLineMode!==r&&(this.$newLineMode=r,this._signal("changeNewLineMode"))},u.prototype.getNewLineMode=function(){return this.$newLineMode},u.prototype.isNewLine=function(r){return r==`\r
- `||r=="\r"||r==`
- `},u.prototype.getLine=function(r){return this.$lines[r]||""},u.prototype.getLines=function(r,c){return this.$lines.slice(r,c+1)},u.prototype.getAllLines=function(){return this.getLines(0,this.getLength())},u.prototype.getLength=function(){return this.$lines.length},u.prototype.getTextRange=function(r){return this.getLinesForRange(r).join(this.getNewLineCharacter())},u.prototype.getLinesForRange=function(r){var c;if(r.start.row===r.end.row)c=[this.getLine(r.start.row).substring(r.start.column,r.end.column)];else{c=this.getLines(r.start.row,r.end.row),c[0]=(c[0]||"").substring(r.start.column);var l=c.length-1;r.end.row-r.start.row==l&&(c[l]=c[l].substring(0,r.end.column))}return c},u.prototype.insertLines=function(r,c){return console.warn("Use of document.insertLines is deprecated. Use the insertFullLines method instead."),this.insertFullLines(r,c)},u.prototype.removeLines=function(r,c){return console.warn("Use of document.removeLines is deprecated. Use the removeFullLines method instead."),this.removeFullLines(r,c)},u.prototype.insertNewLine=function(r){return console.warn("Use of document.insertNewLine is deprecated. Use insertMergedLines(position, ['', '']) instead."),this.insertMergedLines(r,["",""])},u.prototype.insert=function(r,c){return this.getLength()<=1&&this.$detectNewLine(c),this.insertMergedLines(r,this.$split(c))},u.prototype.insertInLine=function(r,c){var l=this.clippedPos(r.row,r.column),g=this.pos(r.row,r.column+c.length);return this.applyDelta({start:l,end:g,action:"insert",lines:[c]},!0),this.clonePos(g)},u.prototype.clippedPos=function(r,c){var l=this.getLength();r===void 0?r=l:r<0?r=0:r>=l&&(r=l-1,c=void 0);var g=this.getLine(r);return c==null&&(c=g.length),c=Math.min(Math.max(c,0),g.length),{row:r,column:c}},u.prototype.clonePos=function(r){return{row:r.row,column:r.column}},u.prototype.pos=function(r,c){return{row:r,column:c}},u.prototype.$clipPosition=function(r){var c=this.getLength();return r.row>=c?(r.row=Math.max(0,c-1),r.column=this.getLine(c-1).length):(r.row=Math.max(0,r.row),r.column=Math.min(Math.max(r.column,0),this.getLine(r.row).length)),r},u.prototype.insertFullLines=function(r,c){r=Math.min(Math.max(r,0),this.getLength());var l=0;r<this.getLength()?(c=c.concat([""]),l=0):(c=[""].concat(c),r--,l=this.$lines[r].length),this.insertMergedLines({row:r,column:l},c)},u.prototype.insertMergedLines=function(r,c){var l=this.clippedPos(r.row,r.column),g={row:l.row+c.length-1,column:(c.length==1?l.column:0)+c[c.length-1].length};return this.applyDelta({start:l,end:g,action:"insert",lines:c}),this.clonePos(g)},u.prototype.remove=function(r){var c=this.clippedPos(r.start.row,r.start.column),l=this.clippedPos(r.end.row,r.end.column);return this.applyDelta({start:c,end:l,action:"remove",lines:this.getLinesForRange({start:c,end:l})}),this.clonePos(c)},u.prototype.removeInLine=function(r,c,l){var g=this.clippedPos(r,c),y=this.clippedPos(r,l);return this.applyDelta({start:g,end:y,action:"remove",lines:this.getLinesForRange({start:g,end:y})},!0),this.clonePos(g)},u.prototype.removeFullLines=function(r,c){r=Math.min(Math.max(0,r),this.getLength()-1),c=Math.min(Math.max(0,c),this.getLength()-1);var l=c==this.getLength()-1&&r>0,g=c<this.getLength()-1,y=l?r-1:r,D=l?this.getLine(y).length:0,L=g?c+1:c,C=g?0:this.getLine(L).length,U=new n(y,D,L,C),O=this.$lines.slice(r,c+1);return this.applyDelta({start:U.start,end:U.end,action:"remove",lines:this.getLinesForRange(U)}),O},u.prototype.removeNewLine=function(r){r<this.getLength()-1&&r>=0&&this.applyDelta({start:this.pos(r,this.getLine(r).length),end:this.pos(r+1,0),action:"remove",lines:["",""]})},u.prototype.replace=function(r,c){if(r instanceof n||(r=n.fromPoints(r.start,r.end)),c.length===0&&r.isEmpty())return r.start;if(c==this.getTextRange(r))return r.end;this.remove(r);var l;return c?l=this.insert(r.start,c):l=r.start,l},u.prototype.applyDeltas=function(r){for(var c=0;c<r.length;c++)this.applyDelta(r[c])},u.prototype.revertDeltas=function(r){for(var c=r.length-1;c>=0;c--)this.revertDelta(r[c])},u.prototype.applyDelta=function(r,c){var l=r.action=="insert";(l?r.lines.length<=1&&!r.lines[0]:!n.comparePoints(r.start,r.end))||(l&&r.lines.length>2e4?this.$splitAndapplyLargeDelta(r,2e4):(p(this.$lines,r,c),this._signal("change",r)))},u.prototype.$safeApplyDelta=function(r){var c=this.$lines.length;(r.action=="remove"&&r.start.row<c&&r.end.row<c||r.action=="insert"&&r.start.row<=c)&&this.applyDelta(r)},u.prototype.$splitAndapplyLargeDelta=function(r,c){for(var l=r.lines,g=l.length-c+1,y=r.start.row,D=r.start.column,L=0,C=0;L<g;L=C){C+=c-1;var U=l.slice(L,C);U.push(""),this.applyDelta({start:this.pos(y+L,D),end:this.pos(y+C,D=0),action:r.action,lines:U},!0)}r.lines=l.slice(L),r.start.row=y+L,r.start.column=D,this.applyDelta(r,!0)},u.prototype.revertDelta=function(r){this.$safeApplyDelta({start:this.clonePos(r.start),end:this.clonePos(r.end),action:r.action=="insert"?"remove":"insert",lines:r.lines.slice()})},u.prototype.indexToPosition=function(r,c){for(var l=this.$lines||this.getAllLines(),g=this.getNewLineCharacter().length,y=c||0,D=l.length;y<D;y++)if(r-=l[y].length+g,r<0)return{row:y,column:r+l[y].length+g};return{row:D-1,column:r+l[D-1].length+g}},u.prototype.positionToIndex=function(r,c){for(var l=this.$lines||this.getAllLines(),g=this.getNewLineCharacter().length,y=0,D=Math.min(r.row,l.length),L=c||0;L<D;++L)y+=l[L].length+g;return y+r.column},u.prototype.$split=function(r){return r.split(/\r\n|\r|\n/)},u}();a.prototype.$autoNewLine="",a.prototype.$newLineMode="auto",d.implement(a.prototype,s),T.Document=a});ace.define("ace/worker/mirror",[],function(m,T,$){var d=m("../document").Document,p=m("../lib/lang"),s=T.Mirror=function(n){this.sender=n;var i=this.doc=new d(""),a=this.deferredUpdate=p.delayedCall(this.onUpdate.bind(this)),u=this;n.on("change",function(r){var c=r.data;if(c[0].start)i.applyDeltas(c);else for(var l=0;l<c.length;l+=2){var g,y;if(Array.isArray(c[l+1])?g={action:"insert",start:c[l],lines:c[l+1]}:g={action:"remove",start:c[l],end:c[l+1]},(g.action=="insert"?g.start:g.end).row>=i.$lines.length)throw y=new Error("Invalid delta"),y.data={path:u.$path,linesLength:i.$lines.length,start:g.start,end:g.end},y;i.applyDelta(g,!0)}if(u.$timeout)return a.schedule(u.$timeout);u.onUpdate()})};(function(){this.$timeout=500,this.setTimeout=function(n){this.$timeout=n},this.setValue=function(n){this.doc.setValue(n),this.deferredUpdate.schedule(this.$timeout)},this.getValue=function(n){this.sender.callback(this.doc.getValue(),n)},this.onUpdate=function(){},this.isPending=function(){return this.deferredUpdate.isPending()}}).call(s.prototype)});ace.define("ace/mode/xml/sax",[],function(m,T,$){var d=/[A-Z_a-z\xC0-\xD6\xD8-\xF6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]/,p=new RegExp("[\\-\\.0-9"+d.source.slice(1,-1)+"·̀-ͯ\\ux203F-⁀]"),s=new RegExp("^"+d.source+p.source+"*(?::"+d.source+p.source+"*)?$"),n=0,i=1,a=2,u=3,r=4,c=5,l=6,g=7;function y(){}y.prototype={parse:function(h,v,N){var b=this.domBuilder;b.startDocument(),V(v,v={}),D(h,v,N,b,this.errorHandler),b.endDocument()}};function D(h,v,N,b,S){function _(I){if(I>65535){I-=65536;var H=55296+(I>>10),fe=56320+(I&1023);return String.fromCharCode(H,fe)}else return String.fromCharCode(I)}function E(I){var H=I.slice(1,-1);return H in N?N[H]:H.charAt(0)==="#"?_(parseInt(H.substr(1).replace("x","0x"))):(S.error("entity not found:"+I),I)}function A(I){var H=h.substring(q,I).replace(/&#?\w+;/g,E);F&&x(q),b.characters(H,0,I-q),q=I}function x(I,H){for(;I>=j&&(H=B.exec(h));)M=H.index,j=M+H[0].length,F.lineNumber++;F.columnNumber=I-M+1}for(var M=0,j=0,B=/.+(?:\r\n?|\n)|.*$/g,F=b.locator,Y=[{currentNSMap:v}],oe={},q=0;;){var P=h.indexOf("<",q);if(P<0){if(!h.substr(q).match(/^\s*$/)){var te=b.document,se=te.createTextNode(h.substr(q));te.appendChild(se),b.currentElement=se}return}switch(P>q&&A(P),h.charAt(P+1)){case"/":var z=h.indexOf(">",P+3),ne=h.substring(P+2,z),Z;if(Y.length>1)Z=Y.pop();else{S.fatalError("end tag name not found for: "+ne);break}var ue=Z.localNSMap;if(Z.tagName!=ne&&S.fatalError("end tag name: "+ne+" does not match the current start tagName: "+Z.tagName),b.endElement(Z.uri,Z.localName,ne),ue)for(var pe in ue)b.endPrefixMapping(pe);z++;break;case"?":F&&x(P),z=ee(h,P,b);break;case"!":F&&x(P),z=he(h,P,b,S);break;default:try{F&&x(P);var X=new W,z=C(h,P,X,E,S),re=X.length;if(re&&F){for(var ce=L(F,{}),P=0;P<re;P++){var le=X[P];x(le.offset),le.offset=L(F,{})}L(ce,F)}!X.closed&&R(h,z,X.tagName,oe)&&(X.closed=!0,N.nbsp||S.warning("unclosed xml attribute")),U(X,b,Y),X.uri==="http://www.w3.org/1999/xhtml"&&!X.closed?z=O(h,z,X.tagName,E,b):z++}catch(I){S.error("element parse error: "+I),z=-1}}z<0?A(P+1):q=z}}function L(h,v){return v.lineNumber=h.lineNumber,v.columnNumber=h.columnNumber,v}function C(h,v,N,b,S){for(var _,E,A=++v,x=n;;){var M=h.charAt(A);switch(M){case"=":if(x===i)_=h.slice(v,A),x=u;else if(x===a)x=u;else throw new Error("attribute equal must after attrName");break;case"'":case'"':if(x===u)if(v=A+1,A=h.indexOf(M,v),A>0)E=h.slice(v,A).replace(/&#?\w+;/g,b),N.add(_,E,v-1),x=c;else throw new Error("attribute value no end '"+M+"' match");else if(x==r)E=h.slice(v,A).replace(/&#?\w+;/g,b),N.add(_,E,v),S.warning('attribute "'+_+'" missed start quot('+M+")!!"),v=A+1,x=c;else throw new Error('attribute value must after "="');break;case"/":switch(x){case n:N.setTagName(h.slice(v,A));case c:case l:case g:x=g,N.closed=!0;case r:case i:case a:break;default:throw new Error("attribute invalid close char('/')")}break;case"":S.error("unexpected end of input");case">":switch(x){case n:N.setTagName(h.slice(v,A));case c:case l:case g:break;case r:case i:E=h.slice(v,A),E.slice(-1)==="/"&&(N.closed=!0,E=E.slice(0,-1));case a:x===a&&(E=_),x==r?(S.warning('attribute "'+E+'" missed quot(")!!'),N.add(_,E.replace(/&#?\w+;/g,b),v)):(S.warning('attribute "'+E+'" missed value!! "'+E+'" instead!!'),N.add(E,E,v));break;case u:throw new Error("attribute value missed!!")}return A;case"":M=" ";default:if(M<=" ")switch(x){case n:N.setTagName(h.slice(v,A)),x=l;break;case i:_=h.slice(v,A),x=a;break;case r:var E=h.slice(v,A).replace(/&#?\w+;/g,b);S.warning('attribute "'+E+'" missed quot(")!!'),N.add(_,E,v);case c:x=l;break}else switch(x){case a:S.warning('attribute "'+_+'" missed value!! "'+_+'" instead!!'),N.add(_,_,v),v=A,x=i;break;case c:S.warning('attribute space is required"'+_+'"!!');case l:x=i,v=A;break;case u:x=r,v=A;break;case g:throw new Error("elements closed character '/' and '>' must be connected to")}}A++}}function U(h,v,N){for(var b=h.tagName,S=null,_=N[N.length-1].currentNSMap,F=h.length;F--;){var E=h[F],A=E.qName,x=E.value,Y=A.indexOf(":");if(Y>0)var M=E.prefix=A.slice(0,Y),j=A.slice(Y+1),B=M==="xmlns"&&j;else j=A,M=null,B=A==="xmlns"&&"";E.localName=j,B!==!1&&(S==null&&(S={},V(_,_={})),_[B]=S[B]=x,E.uri="http://www.w3.org/2000/xmlns/",v.startPrefixMapping(B,x))}for(var F=h.length;F--;){E=h[F];var M=E.prefix;M&&(M==="xml"&&(E.uri="http://www.w3.org/XML/1998/namespace"),M!=="xmlns"&&(E.uri=_[M]))}var Y=b.indexOf(":");Y>0?(M=h.prefix=b.slice(0,Y),j=h.localName=b.slice(Y+1)):(M=null,j=h.localName=b);var oe=h.uri=_[M||""];if(v.startElement(oe,j,b,h),h.closed){if(v.endElement(oe,j,b),S)for(M in S)v.endPrefixMapping(M)}else h.currentNSMap=_,h.localNSMap=S,N.push(h)}function O(h,v,N,b,S){if(/^(?:script|textarea)$/i.test(N)){var _=h.indexOf("</"+N+">",v),E=h.substring(v+1,_);if(/[&<]/.test(E))return/^script$/i.test(N)?(S.characters(E,0,E.length),_):(E=E.replace(/&#?\w+;/g,b),S.characters(E,0,E.length),_)}return v+1}function R(h,v,N,b){var S=b[N];return S==null&&(S=b[N]=h.lastIndexOf("</"+N+">")),S<v}function V(h,v){for(var N in h)v[N]=h[N]}function he(h,v,N,b){var S=h.charAt(v+2);switch(S){case"-":if(h.charAt(v+3)==="-"){var _=h.indexOf("-->",v+4);return _>v?(N.comment(h,v+4,_-v-4),_+3):(b.error("Unclosed comment"),-1)}else return-1;default:if(h.substr(v+3,6)=="CDATA["){var _=h.indexOf("]]>",v+9);return _>v?(N.startCDATA(),N.characters(h,v+9,_-v-9),N.endCDATA(),_+3):(b.error("Unclosed CDATA"),-1)}var E=ae(h,v),A=E.length;if(A>1&&/!doctype/i.test(E[0][0])){var x=E[1][0],M=A>3&&/^public$/i.test(E[2][0])&&E[3][0],j=A>4&&E[4][0],B=E[A-1];return N.startDTD(x,M&&M.replace(/^(['"])(.*?)\1$/,"$2"),j&&j.replace(/^(['"])(.*?)\1$/,"$2")),N.endDTD(),B.index+B[0].length}}return-1}function ee(h,v,N){var b=h.indexOf("?>",v);if(b){var S=h.substring(v,b).match(/^<\?(\S*)\s*([\s\S]*?)\s*$/);return S?(S[0].length,N.processingInstruction(S[1],S[2]),b+2):-1}return-1}function W(h){}W.prototype={setTagName:function(h){if(!s.test(h))throw new Error("invalid tagName:"+h);this.tagName=h},add:function(h,v,N){if(!s.test(h))throw new Error("invalid attribute:"+h);this[this.length++]={qName:h,value:v,offset:N}},length:0,getLocalName:function(h){return this[h].localName},getOffset:function(h){return this[h].offset},getQName:function(h){return this[h].qName},getURI:function(h){return this[h].uri},getValue:function(h){return this[h].value}};function Q(h,v){return h.__proto__=v,h}Q({},Q.prototype)instanceof Q||(Q=function(h,v){function N(){}N.prototype=v,N=new N;for(v in h)N[v]=h[v];return N});function ae(h,v){var N,b=[],S=/'[^']+'|"[^"]+"|[^\s<>\/=]+=?|(\/?\s*>|<)/g;for(S.lastIndex=v,S.exec(h);N=S.exec(h);)if(b.push(N),N[1])return b}return y});ace.define("ace/mode/xml/dom",[],function(m,T,$){function d(e,t){for(var o in e)t[o]=e[o]}function p(e,t){var o=function(){},f=e.prototype;if(Object.create){var w=Object.create(t.prototype);f.__proto__=w}f instanceof t||(o.prototype=t.prototype,o=new o,d(f,o),e.prototype=f=o),f.constructor!=e&&(typeof e!="function"&&console.error("unknown Class:"+e),f.constructor=e)}var s="http://www.w3.org/1999/xhtml",n={},i=n.ELEMENT_NODE=1,a=n.ATTRIBUTE_NODE=2,u=n.TEXT_NODE=3,r=n.CDATA_SECTION_NODE=4,c=n.ENTITY_REFERENCE_NODE=5,l=n.ENTITY_NODE=6,g=n.PROCESSING_INSTRUCTION_NODE=7,y=n.COMMENT_NODE=8,D=n.DOCUMENT_NODE=9,L=n.DOCUMENT_TYPE_NODE=10,C=n.DOCUMENT_FRAGMENT_NODE=11,U=n.NOTATION_NODE=12,O={},R={};O.INDEX_SIZE_ERR=(R[1]="Index size error",1),O.DOMSTRING_SIZE_ERR=(R[2]="DOMString size error",2),O.HIERARCHY_REQUEST_ERR=(R[3]="Hierarchy request error",3),O.WRONG_DOCUMENT_ERR=(R[4]="Wrong document",4),O.INVALID_CHARACTER_ERR=(R[5]="Invalid character",5),O.NO_DATA_ALLOWED_ERR=(R[6]="No data allowed",6),O.NO_MODIFICATION_ALLOWED_ERR=(R[7]="No modification allowed",7);var V=O.NOT_FOUND_ERR=(R[8]="Not found",8);O.NOT_SUPPORTED_ERR=(R[9]="Not supported",9);var he=O.INUSE_ATTRIBUTE_ERR=(R[10]="Attribute in use",10);O.INVALID_STATE_ERR=(R[11]="Invalid state",11),O.SYNTAX_ERR=(R[12]="Syntax error",12),O.INVALID_MODIFICATION_ERR=(R[13]="Invalid modification",13),O.NAMESPACE_ERR=(R[14]="Invalid namespace",14),O.INVALID_ACCESS_ERR=(R[15]="Invalid access",15);function ee(e,t){if(t instanceof Error)var o=t;else o=this,Error.call(this,R[e]),this.message=R[e],Error.captureStackTrace&&Error.captureStackTrace(this,ee);return o.code=e,t&&(this.message=this.message+": "+t),o}ee.prototype=Error.prototype,d(O,ee);function W(){}W.prototype={length:0,item:function(e){return this[e]||null}};function Q(e,t){this._node=e,this._refresh=t,ae(this)}function ae(e){var t=e._node._inc||e._node.ownerDocument._inc;if(e._inc!=t){var o=e._refresh(e._node);ve(e,"length",o.length),d(o,e),e._inc=t}}Q.prototype.item=function(e){return ae(this),this[e]},p(Q,W);function h(){}function v(e,t){for(var o=e.length;o--;)if(e[o]===t)return o}function N(e,t,o,f){if(f?t[v(t,f)]=o:t[t.length++]=o,e){o.ownerElement=e;var w=e.ownerDocument;w&&(f&&j(w,e,f),M(w,e,o))}}function b(e,t,o){var f=v(t,o);if(f>=0){for(var w=t.length-1;f<w;)t[f]=t[++f];if(t.length=w,e){var k=e.ownerDocument;k&&(j(k,e,o),o.ownerElement=null)}}else throw new ee(V,new Error)}h.prototype={length:0,item:W.prototype.item,getNamedItem:function(e){for(var t=this.length;t--;){var o=this[t];if(o.nodeName==e)return o}},setNamedItem:function(e){var t=e.ownerElement;if(t&&t!=this._ownerElement)throw new ee(he);var o=this.getNamedItem(e.nodeName);return N(this._ownerElement,this,e,o),o},setNamedItemNS:function(e){var t=e.ownerElement,o;if(t&&t!=this._ownerElement)throw new ee(he);return o=this.getNamedItemNS(e.namespaceURI,e.localName),N(this._ownerElement,this,e,o),o},removeNamedItem:function(e){var t=this.getNamedItem(e);return b(this._ownerElement,this,t),t},removeNamedItemNS:function(e,t){var o=this.getNamedItemNS(e,t);return b(this._ownerElement,this,o),o},getNamedItemNS:function(e,t){for(var o=this.length;o--;){var f=this[o];if(f.localName==t&&f.namespaceURI==e)return f}return null}};function S(e){if(this._features={},e)for(var t in e)this._features=e[t]}S.prototype={hasFeature:function(e,t){var o=this._features[e.toLowerCase()];return!!(o&&(!t||t in o))},createDocument:function(e,t,o){var f=new x;if(f.implementation=this,f.childNodes=new W,f.doctype=o,o&&f.appendChild(o),t){var w=f.createElementNS(e,t);f.appendChild(w)}return f},createDocumentType:function(e,t,o){var f=new Z;return f.name=e,f.nodeName=e,f.publicId=t,f.systemId=o,f}};function _(){}_.prototype={firstChild:null,lastChild:null,previousSibling:null,nextSibling:null,attributes:null,parentNode:null,childNodes:null,ownerDocument:null,nodeValue:null,namespaceURI:null,prefix:null,localName:null,insertBefore:function(e,t){return Y(this,e,t)},replaceChild:function(e,t){this.insertBefore(e,t),t&&this.removeChild(t)},removeChild:function(e){return F(this,e)},appendChild:function(e){return this.insertBefore(e,null)},hasChildNodes:function(){return this.firstChild!=null},cloneNode:function(e){return fe(this.ownerDocument||this,this,e)},normalize:function(){for(var e=this.firstChild;e;){var t=e.nextSibling;t&&t.nodeType==u&&e.nodeType==u?(this.removeChild(t),e.appendData(t.data)):(e.normalize(),e=t)}},isSupported:function(e,t){return this.ownerDocument.implementation.hasFeature(e,t)},hasAttributes:function(){return this.attributes.length>0},lookupPrefix:function(e){for(var t=this;t;){var o=t._nsMap;if(o){for(var f in o)if(o[f]==e)return f}t=t.nodeType==2?t.ownerDocument:t.parentNode}return null},lookupNamespaceURI:function(e){for(var t=this;t;){var o=t._nsMap;if(o&&e in o)return o[e];t=t.nodeType==2?t.ownerDocument:t.parentNode}return null},isDefaultNamespace:function(e){var t=this.lookupPrefix(e);return t==null}};function E(e){return e=="<"&&"<"||e==">"&&">"||e=="&"&&"&"||e=='"'&&"""||"&#"+e.charCodeAt()+";"}d(n,_),d(n,_.prototype);function A(e,t){if(t(e))return!0;if(e=e.firstChild)do if(A(e,t))return!0;while(e=e.nextSibling)}function x(){}function M(e,t,o){e&&e._inc++;var f=o.namespaceURI;f=="http://www.w3.org/2000/xmlns/"&&(t._nsMap[o.prefix?o.localName:""]=o.value)}function j(e,t,o,f){e&&e._inc++;var w=o.namespaceURI;w=="http://www.w3.org/2000/xmlns/"&&delete t._nsMap[o.prefix?o.localName:""]}function B(e,t,o){if(e&&e._inc){e._inc++;var f=t.childNodes;if(o)f[f.length++]=o;else{for(var w=t.firstChild,k=0;w;)f[k++]=w,w=w.nextSibling;f.length=k}}}function F(e,t){var o=t.previousSibling,f=t.nextSibling;return o?o.nextSibling=f:e.firstChild=f,f?f.previousSibling=o:e.lastChild=o,B(e.ownerDocument,e),t}function Y(e,t,o){var f=t.parentNode;if(f&&f.removeChild(t),t.nodeType===C){var w=t.firstChild;if(w==null)return t;var k=t.lastChild}else w=k=t;var J=o?o.previousSibling:e.lastChild;w.previousSibling=J,k.nextSibling=o,J?J.nextSibling=w:e.firstChild=w,o==null?e.lastChild=k:o.previousSibling=k;do w.parentNode=e;while(w!==k&&(w=w.nextSibling));return B(e.ownerDocument||e,e),t.nodeType==C&&(t.firstChild=t.lastChild=null),t}function oe(e,t){var o=t.parentNode;if(o){var f=e.lastChild;o.removeChild(t);var f=e.lastChild}var f=e.lastChild;return t.parentNode=e,t.previousSibling=f,t.nextSibling=null,f?f.nextSibling=t:e.firstChild=t,e.lastChild=t,B(e.ownerDocument,e,t),t}x.prototype={nodeName:"#document",nodeType:D,doctype:null,documentElement:null,_inc:1,insertBefore:function(e,t){if(e.nodeType==C){for(var o=e.firstChild;o;){var f=o.nextSibling;this.insertBefore(o,t),o=f}return e}return this.documentElement==null&&e.nodeType==1&&(this.documentElement=e),Y(this,e,t),e.ownerDocument=this,e},removeChild:function(e){return this.documentElement==e&&(this.documentElement=null),F(this,e)},importNode:function(e,t){return H(this,e,t)},getElementById:function(e){var t=null;return A(this.documentElement,function(o){if(o.nodeType==1&&o.getAttribute("id")==e)return t=o,!0}),t},createElement:function(e){var t=new q;t.ownerDocument=this,t.nodeName=e,t.tagName=e,t.childNodes=new W;var o=t.attributes=new h;return o._ownerElement=t,t},createDocumentFragment:function(){var e=new re;return e.ownerDocument=this,e.childNodes=new W,e},createTextNode:function(e){var t=new se;return t.ownerDocument=this,t.appendData(e),t},createComment:function(e){var t=new z;return t.ownerDocument=this,t.appendData(e),t},createCDATASection:function(e){var t=new ne;return t.ownerDocument=this,t.appendData(e),t},createProcessingInstruction:function(e,t){var o=new ce;return o.ownerDocument=this,o.tagName=o.target=e,o.nodeValue=o.data=t,o},createAttribute:function(e){var t=new P;return t.ownerDocument=this,t.name=e,t.nodeName=e,t.localName=e,t.specified=!0,t},createEntityReference:function(e){var t=new X;return t.ownerDocument=this,t.nodeName=e,t},createElementNS:function(e,t){var o=new q,f=t.split(":"),w=o.attributes=new h;return o.childNodes=new W,o.ownerDocument=this,o.nodeName=t,o.tagName=t,o.namespaceURI=e,f.length==2?(o.prefix=f[0],o.localName=f[1]):o.localName=t,w._ownerElement=o,o},createAttributeNS:function(e,t){var o=new P,f=t.split(":");return o.ownerDocument=this,o.nodeName=t,o.name=t,o.namespaceURI=e,o.specified=!0,f.length==2?(o.prefix=f[0],o.localName=f[1]):o.localName=t,o}},p(x,_);function q(){this._nsMap={}}q.prototype={nodeType:i,hasAttribute:function(e){return this.getAttributeNode(e)!=null},getAttribute:function(e){var t=this.getAttributeNode(e);return t&&t.value||""},getAttributeNode:function(e){return this.attributes.getNamedItem(e)},setAttribute:function(e,t){var o=this.ownerDocument.createAttribute(e);o.value=o.nodeValue=""+t,this.setAttributeNode(o)},removeAttribute:function(e){var t=this.getAttributeNode(e);t&&this.removeAttributeNode(t)},appendChild:function(e){return e.nodeType===C?this.insertBefore(e,null):oe(this,e)},setAttributeNode:function(e){return this.attributes.setNamedItem(e)},setAttributeNodeNS:function(e){return this.attributes.setNamedItemNS(e)},removeAttributeNode:function(e){return this.attributes.removeNamedItem(e.nodeName)},removeAttributeNS:function(e,t){var o=this.getAttributeNodeNS(e,t);o&&this.removeAttributeNode(o)},hasAttributeNS:function(e,t){return this.getAttributeNodeNS(e,t)!=null},getAttributeNS:function(e,t){var o=this.getAttributeNodeNS(e,t);return o&&o.value||""},setAttributeNS:function(e,t,o){var f=this.ownerDocument.createAttributeNS(e,t);f.value=f.nodeValue=""+o,this.setAttributeNode(f)},getAttributeNodeNS:function(e,t){return this.attributes.getNamedItemNS(e,t)},getElementsByTagName:function(e){return new Q(this,function(t){var o=[];return A(t,function(f){f!==t&&f.nodeType==i&&(e==="*"||f.tagName==e)&&o.push(f)}),o})},getElementsByTagNameNS:function(e,t){return new Q(this,function(o){var f=[];return A(o,function(w){w!==o&&w.nodeType===i&&(e==="*"||w.namespaceURI===e)&&(t==="*"||w.localName==t)&&f.push(w)}),f})}},x.prototype.getElementsByTagName=q.prototype.getElementsByTagName,x.prototype.getElementsByTagNameNS=q.prototype.getElementsByTagNameNS,p(q,_);function P(){}P.prototype.nodeType=a,p(P,_);function te(){}te.prototype={data:"",substringData:function(e,t){return this.data.substring(e,e+t)},appendData:function(e){e=this.data+e,this.nodeValue=this.data=e,this.length=e.length},insertData:function(e,t){this.replaceData(e,0,t)},appendChild:function(e){throw new Error(R[3])},deleteData:function(e,t){this.replaceData(e,t,"")},replaceData:function(e,t,o){var f=this.data.substring(0,e),w=this.data.substring(e+t);o=f+o+w,this.nodeValue=this.data=o,this.length=o.length}},p(te,_);function se(){}se.prototype={nodeName:"#text",nodeType:u,splitText:function(e){var t=this.data,o=t.substring(e);t=t.substring(0,e),this.data=this.nodeValue=t,this.length=t.length;var f=this.ownerDocument.createTextNode(o);return this.parentNode&&this.parentNode.insertBefore(f,this.nextSibling),f}},p(se,te);function z(){}z.prototype={nodeName:"#comment",nodeType:y},p(z,te);function ne(){}ne.prototype={nodeName:"#cdata-section",nodeType:r},p(ne,te);function Z(){}Z.prototype.nodeType=L,p(Z,_);function ue(){}ue.prototype.nodeType=U,p(ue,_);function pe(){}pe.prototype.nodeType=l,p(pe,_);function X(){}X.prototype.nodeType=c,p(X,_);function re(){}re.prototype.nodeName="#document-fragment",re.prototype.nodeType=C,p(re,_);function ce(){}ce.prototype.nodeType=g,p(ce,_);function le(){}le.prototype.serializeToString=function(e){var t=[];return I(e,t),t.join("")},_.prototype.toString=function(){return le.prototype.serializeToString(this)};function I(e,t){switch(e.nodeType){case i:var o=e.attributes,f=o.length,G=e.firstChild,w=e.tagName,k=s===e.namespaceURI;t.push("<",w);for(var J=0;J<f;J++)I(o.item(J),t);if(G||k&&!/^(?:meta|link|img|br|hr|input|button)$/i.test(w)){if(t.push(">"),k&&/^script$/i.test(w))G&&t.push(G.data);else for(;G;)I(G,t),G=G.nextSibling;t.push("</",w,">")}else t.push("/>");return;case D:case C:for(var G=e.firstChild;G;)I(G,t),G=G.nextSibling;return;case a:return t.push(" ",e.name,'="',e.value.replace(/[<&"]/g,E),'"');case u:return t.push(e.data.replace(/[<&]/g,E));case r:return t.push("<![CDATA[",e.data,"]]>");case y:return t.push("<!--",e.data,"-->");case L:var me=e.publicId,K=e.systemId;if(t.push("<!DOCTYPE ",e.name),me)t.push(' PUBLIC "',me),K&&K!="."&&t.push('" "',K),t.push('">');else if(K&&K!=".")t.push(' SYSTEM "',K,'">');else{var ie=e.internalSubset;ie&&t.push(" [",ie,"]"),t.push(">")}return;case g:return t.push("<?",e.target," ",e.data,"?>");case c:return t.push("&",e.nodeName,";");default:t.push("??",e.nodeName)}}function H(e,t,o){var f;switch(t.nodeType){case i:f=t.cloneNode(!1),f.ownerDocument=e;case C:break;case a:o=!0;break}if(f||(f=t.cloneNode(!1)),f.ownerDocument=e,f.parentNode=null,o)for(var w=t.firstChild;w;)f.appendChild(H(e,w,o)),w=w.nextSibling;return f}function fe(e,t,o){var f=new t.constructor;for(var w in t){var k=t[w];typeof k!="object"&&k!=f[w]&&(f[w]=k)}switch(t.childNodes&&(f.childNodes=new W),f.ownerDocument=e,f.nodeType){case i:var J=t.attributes,G=f.attributes=new h,me=J.length;G._ownerElement=f;for(var K=0;K<me;K++)f.setAttributeNode(fe(e,J.item(K),!0));break;case a:o=!0}if(o)for(var ie=t.firstChild;ie;)f.appendChild(fe(e,ie,o)),ie=ie.nextSibling;return f}function ve(e,t,o){e[t]=o}function ge(e){switch(e.nodeType){case 1:case 11:var t=[];for(e=e.firstChild;e;)e.nodeType!==7&&e.nodeType!==8&&t.push(ge(e)),e=e.nextSibling;return t.join("");default:return e.nodeValue}}try{Object.defineProperty&&(Object.defineProperty(Q.prototype,"length",{get:function(){return ae(this),this.$$length}}),Object.defineProperty(_.prototype,"textContent",{get:function(){return ge(this)},set:function(e){switch(this.nodeType){case 1:case 11:for(;this.firstChild;)this.removeChild(this.firstChild);(e||String(e))&&this.appendChild(this.ownerDocument.createTextNode(e));break;default:this.data=e,this.value=value,this.nodeValue=e}}}),ve=function(e,t,o){e["$$"+t]=o})}catch{}return S});ace.define("ace/mode/xml/dom-parser",[],function(m,T,$){var d=m("./sax"),p=m("./dom");function s(l){this.options=l||{locator:{}}}s.prototype.parseFromString=function(l,g){var y=this.options,D=new d,L=y.domBuilder||new i,C=y.errorHandler,U=y.locator,O=y.xmlns||{},R={lt:"<",gt:">",amp:"&",quot:'"',apos:"'"};return U&&L.setDocumentLocator(U),D.errorHandler=n(C,L,U),D.domBuilder=y.domBuilder||L,/\/x?html?$/.test(g)&&(R.nbsp=" ",R.copy="©",O[""]="http://www.w3.org/1999/xhtml"),l?D.parse(l,O,R):D.errorHandler.error("invalid document source"),L.document};function n(l,g,y){if(!l){if(g instanceof i)return g;l=g}var D={},L=l instanceof Function;y=y||{};function C(U){var O=l[U];if(!O)if(L)O=l.length==2?function(V){l(U,V)}:l;else for(var R=arguments.length;--R&&!(O=l[arguments[R]]););D[U]=O&&function(V){O(V+u(y),V,y)}||function(){}}return C("warning","warn"),C("error","warn","warning"),C("fatalError","warn","warning","error"),D}function i(){this.cdata=!1}function a(l,g){g.lineNumber=l.lineNumber,g.columnNumber=l.columnNumber}i.prototype={startDocument:function(){this.document=new p().createDocument(null,null,null),this.locator&&(this.document.documentURI=this.locator.systemId)},startElement:function(l,g,y,D){var L=this.document,C=L.createElementNS(l,y||g),U=D.length;c(this,C),this.currentElement=C,this.locator&&a(this.locator,C);for(var O=0;O<U;O++){var l=D.getURI(O),R=D.getValue(O),y=D.getQName(O),V=L.createAttributeNS(l,y);V.getOffset&&a(V.getOffset(1),V),V.value=V.nodeValue=R,C.setAttributeNode(V)}},endElement:function(l,g,y){var D=this.currentElement;D.tagName,this.currentElement=D.parentNode},startPrefixMapping:function(l,g){},endPrefixMapping:function(l){},processingInstruction:function(l,g){var y=this.document.createProcessingInstruction(l,g);this.locator&&a(this.locator,y),c(this,y)},ignorableWhitespace:function(l,g,y){},characters:function(l,g,y){if(l=r.apply(this,arguments),this.currentElement&&l){if(this.cdata){var D=this.document.createCDATASection(l);this.currentElement.appendChild(D)}else{var D=this.document.createTextNode(l);this.currentElement.appendChild(D)}this.locator&&a(this.locator,D)}},skippedEntity:function(l){},endDocument:function(){this.document.normalize()},setDocumentLocator:function(l){(this.locator=l)&&(l.lineNumber=0)},comment:function(l,g,y){l=r.apply(this,arguments);var D=this.document.createComment(l);this.locator&&a(this.locator,D),c(this,D)},startCDATA:function(){this.cdata=!0},endCDATA:function(){this.cdata=!1},startDTD:function(l,g,y){var D=this.document.implementation;if(D&&D.createDocumentType){var L=D.createDocumentType(l,g,y);this.locator&&a(this.locator,L),c(this,L)}},warning:function(l){console.warn(l,u(this.locator))},error:function(l){console.error(l,u(this.locator))},fatalError:function(l){throw console.error(l,u(this.locator)),l}};function u(l){if(l)return`
- @`+(l.systemId||"")+"#[line:"+l.lineNumber+",col:"+l.columnNumber+"]"}function r(l,g,y){return typeof l=="string"?l.substr(g,y):l.length>=g+y||g?new java.lang.String(l,g,y)+"":l}"endDTD,startEntity,endEntity,attributeDecl,elementDecl,externalEntityDecl,internalEntityDecl,resolveEntity,getExternalSubset,notationDecl,unparsedEntityDecl".replace(/\w+/g,function(l){i.prototype[l]=function(){return null}});function c(l,g){l.currentElement?l.currentElement.appendChild(g):l.document.appendChild(g)}return{DOMParser:s}});ace.define("ace/mode/xml_worker",[],function(m,T,$){var d=m("../lib/oop");m("../lib/lang");var p=m("../worker/mirror").Mirror,s=m("./xml/dom-parser").DOMParser,n=T.Worker=function(i){p.call(this,i),this.setTimeout(400),this.context=null};d.inherits(n,p),function(){this.setOptions=function(i){this.context=i.context},this.onUpdate=function(){var i=this.doc.getValue();if(i){var a=new s,u=[];a.options.errorHandler={fatalError:function(r,c,l){u.push({row:l.lineNumber,column:l.columnNumber,text:c,type:"error"})},error:function(r,c,l){u.push({row:l.lineNumber,column:l.columnNumber,text:c,type:"error"})},warning:function(r,c,l){u.push({row:l.lineNumber,column:l.columnNumber,text:c,type:"warning"})}},a.parseFromString(i),this.sender.emit("error",u)}}}.call(n.prototype)});const we=Ne({__proto__:null,default:de},[de]);export{we as w};
- //# sourceMappingURL=worker-xml-26a73b34.js.map
|