(function(){ shadow$provide[475]=function(aa,K,za,t){(function(l,A){"object"===typeof t&&"undefined"!==typeof za?za.exports=A():"function"===typeof define&&define.amd?define(A):(l=l||self,l.CodeMirror=A())})(this,function(){function l(r){return new RegExp("(^|\\s)"+r+"(?:$|\\s)\\s*")}function A(r){for(var I=r.childNodes.length;0Ga||Ga>=I)return ra+(I-ea);ra+=Ga-ea;ra+=ka-ra%ka;ea=Ga+1}}function q(r,I){for(var ka=0;ka=I)return ea+Math.min(Qa,I-ra);ra+=Ga-ea;ra+=ka-ra%ka;ea=Ga+1;if(ra>=I)return ea}}function y(r){for(;zk.length<=r;)zk.push(E(zk)+" ");return zk[r]}function E(r){return r[r.length-1]}function M(r, I){for(var ka=[],ea=0;eaka?0ka?-1:1;;){if(I==ka)return I;var ra=(I+ka)/2;ra=0>ea?Math.ceil(ra):Math.floor(ra);if(ra==I)return r(ra)?I:ka;r(ra)?ka=ra:I=ra+ea}}function da(r,I,ka,ea){if(!r)return ea(I,ka,"ltr",0);for(var ra=!1,Ga=0;GaI||I==ka&&Qa.to==I)ea(Math.max(Qa.from,I),Math.min(Qa.to,ka),1==Qa.level?"rtl":"ltr", Ga),ra=!0}ra||ea(I,ka,"ltr")}function O(r,I,ka){var ea;bi=null;for(var ra=0;raI)return ra;Ga.to==I&&(Ga.from!=Ga.to&&"before"==ka?ea=ra:bi=ra);Ga.from==I&&(Ga.from!=Ga.to&&"before"!=ka?ea=ra:bi=ra)}return null!=ea?ea:bi}function X(r,I){var ka=r.order;null==ka&&(ka=r.order=xk(r.text,I));return ka}function Q(r,I,ka){if(r.removeEventListener)r.removeEventListener(I,ka,!1);else if(r.detachEvent)r.detachEvent("on"+I,ka);else{var ea=(r=r._handlers)&&r[I]; ea&&(ka=q(ea,ka),-1I||I>=r.size)throw Error("There is no line "+(I+r.first)+" in the document.");for(;!r.lines;)for(var ka= 0;;++ka){var ea=r.children[ka],ra=ea.chunkSize();if(I=r.first&&ILa(r,I)?I:r}function Yb(r,I){return 0>La(r,I)?r:I}function Ub(r,I){if(I.lineka)return ib(ka,Fb(r,ka).text.length);r=Fb(r,I.line).text.length;ka= I.ch;I=null==ka||ka>r?ib(I.line,r):0>ka?ib(I.line,0):I;return I}function Kc(r,I){for(var ka=[],ea=0;eaCc&&ra.splice(Kb,1,Cc,ra[Kb+1],be);Kb+=2;Ac=Math.min(Cc, be)}if(pc)if(Jb.opaque)ra.splice(ld,Kb-ld,Cc,"overlay "+pc),Kb=ld+2;else for(;ldr.options.maxHighlightLength&&Ta(r.doc.mode,ea.state),Ga=Dc(r,I,ea);ra&&(ea.state=ra);I.stateAfter= ea.save(!ra);I.styles=Ga.styles;Ga.classes?I.styleClasses=Ga.classes:I.styleClasses&&(I.styleClasses=null);ka===r.doc.highlightFrontier&&(r.doc.modeFrontier=Math.max(r.doc.modeFrontier,++r.doc.highlightFrontier))}return I.styles}function Mc(r,I,ka){var ea=r.doc,ra=r.display;if(!ea.mode.startState)return new id(ea,!0,I);var Ga=Dd(r,I,ka),Qa=Ga>ea.first&&Fb(ea,Ga-1).stateAfter,Pa=Qa?id.fromSaved(ea,Qa,Ga):new id(ea,Ib(ea.mode),Ga);ea.iter(Ga,I,function(fb){rd(r,fb.text,Pa);var Jb=Pa.line;fb.stateAfter= Jb==I-1||0==Jb%5||Jb>=ra.viewFrom&&Jbra;ra++){ea&&(ea[0]=db(r,ka).mode);var Ga=r.token(I, ka);if(I.pos>I.start)return Ga}throw Error("Mode "+r.name+" failed to advance stream.");}function ze(r,I,ka,ea){var ra=r.doc,Ga=ra.mode;I=Ub(ra,I);var Qa=Fb(ra,I.line);ka=Mc(r,I.line,ka);r=new fh(Qa.text,r.options.tabSize,ka);var Pa;for(ea&&(Pa=[]);(ea||r.posr.options.maxHighlightLength){Pa=!1;Qa&&rd(r,I,ea,Kb.pos);Kb.pos=I.length;var Cc=null}else Cc= Ee(ud(ka,Kb,ea.state,Ac),Ga);if(Ac){var pc=Ac[0].name;pc&&(Cc="m-"+(Cc?pc+" "+Cc:pc))}if(!Pa||Jb!=Cc){for(;fbQa;--I){if(I<=Ga.first)return Ga.first;var Pa=Fb(Ga,I-1),fb=Pa.stateAfter;if(fb&&(!ka||I+(fb instanceof jj?fb.lookAhead:0)<=Ga.modeFrontier))return I;Pa=e(Pa.text,null,r.options.tabSize); if(null==ra||ea>Pa)ra=I-1,ea=Pa}return ra}function Ie(r,I){r.modeFrontier=Math.min(r.modeFrontier,I);if(!(r.highlightFrontierka;ea--){var ra=Fb(r,ea).stateAfter;if(ra&&(!(ra instanceof jj)||ea+ra.lookAhead=r:fb.to>r);(Qa||(Qa=[])).push(new qg(Jb,fb.from,Kb?null:fb.to))}}ka=Qa;var Ac;if(ea)for(Qa= 0;Qa=ra:Pa.to>ra)||Pa.from==ra&&"bookmark"==fb.type&&(!Ga||Pa.marker.insertLeft))Jb=null==Pa.from||(fb.inclusiveLeft?Pa.from<=ra:Pa.fromLa(Qa.to,ra.from)||0fb||!ka.inclusiveLeft&& !fb)&&Pa.push({from:Qa.from,to:ra.from});(0Jh(ra,ka.marker)))var ra=ka.marker;return ra}function yg(r,I,ka,ea,ra){r=Fb(r,I);if(r=Md&&r.markedSpans)for(I=0;I=fb||0>=Pa&&0<=fb)&&(0>=Pa&&(Ga.marker.inclusiveRight&&ra.inclusiveLeft?0<=La(Qa.to,ka):0=La(Qa.from,ea):0>La(Qa.from,ea))))return!0}}}function xg(r){for(var I;I=Te(r,!0);)r=I.find(-1,!0).line;return r}function Se(r,I){r=Fb(r,I);var ka=xg(r);return r==ka?I:ec(ka)}function vb(r,I){if(I>r.lastLine())return I;var ka=Fb(r, I);if(!Eb(r,ka))return I;for(;r=Te(ka,!1);)ka=r.find(1,!0).line;return ec(ka)+1}function Eb(r,I){var ka=Md&&I.markedSpans;if(ka)for(var ea,ra=0;raI.maxLineLength&&(I.maxLineLength=ea,I.maxLine=ka)})}function Vb(r,I){if(!r||/^\s*$/.test(r))return null;I=I.addModeClass?Th:If;return I[r]||(I[r]=r.replace(/\S+/g, "cm-$\x26"))}function rc(r,I){var ka=b("span",null,null,Jg?"padding-right: .1px":null);ka={pre:b("pre",[ka],"CodeMirror-line"),content:ka,col:0,pos:0,cm:r,trailingSpace:!1,splitSpaces:r.getOption("lineWrapping")};I.measure={};for(var ea=0;ea<=(I.rest?I.rest.length:0);ea++){var ra=ea?I.rest[ea-1]:I.line,Ga=void 0;ka.pos=0;ka.addToken=Tc;var Qa=r.display.measure;if(null!=uj)Qa=uj;else{var Pa=n(Qa,document.createTextNode("AخA")),fb=Xi(Pa,0,1).getBoundingClientRect();Pa=Xi(Pa,1,2).getBoundingClientRect(); A(Qa);Qa=fb&&fb.left!=fb.right?uj=3>Pa.right-fb.right:!1}Qa&&(Ga=X(ra,r.doc.direction))&&(ka.addToken=Fd(ka.addToken,Ga));ka.map=[];var Jb=I!=r.display.externalMeasured&&ec(ra);a:{var Kb=Pa=fb=Qa=void 0,Ac=void 0,Cc=void 0,pc=void 0;Ga=ka;Jb=Hc(r,ra,Jb);var ld=ra.markedSpans,be=ra.text,df=0;if(ld)for(var Eh=be.length,Le=0,Hf=1,Ag="",Gg=0;;){if(Gg==Le){Ac=Kb=Pa=Cc="";fb=Qa=null;Gg=Infinity;for(var rg=[],Ke=void 0,ig=0;igLe||bg.collapsed&&Xf.to==Le&&Xf.from==Le)){null!=Xf.to&&Xf.to!=Le&&Gg>Xf.to&&(Gg=Xf.to,Kb="");bg.className&&(Ac+=" "+bg.className);bg.css&&(Cc=(Cc?Cc+";":"")+bg.css);bg.startStyle&&Xf.from==Le&&(Pa+=" "+bg.startStyle);bg.endStyle&&Xf.to==Gg&&(Ke||(Ke=[])).push(bg.endStyle,Xf.to);bg.title&&((Qa||(Qa={})).title=bg.title);if(bg.attributes)for(var Fh in bg.attributes)(Qa||(Qa={}))[Fh]=bg.attributes[Fh];bg.collapsed&&(!fb||0>Jh(fb.marker, bg))&&(fb=Xf)}else Xf.from>Le&&Gg>Xf.from&&(Gg=Xf.from)}if(Ke)for(ig=0;ig=Eh)break;for(rg=Math.min(Eh,Gg);;){if(Ag){Ke=Le+Ag.length;fb||(ig=Ke>rg?Ag.slice(0,rg-Le):Ag,Ga.addToken(Ga,ig,pc?pc+Ac:Ac,Pa,Le+ig.length==Gg?Kb:"",Cc,Qa));if(Ke>=rg){Ag=Ag.slice(rg- Le);Le=rg;break}Le=Ke;Pa=""}Ag=be.slice(df,df=Jb[Hf++]);pc=Vb(Jb[Hf++],Ga.cm.options)}}else for(Qa=1;Qa=Kb.offsetWidth&&2af))),Pa=fm?k("span","​"):k("span"," ",null,"display: inline-block; width: 1px; margin-right: -1px"),Pa.setAttribute("cm-text",""),Ga.call(ra,0,0,fb.call(Qa,Pa)));0==ea?(I.measure.map=ka.map,I.measure.cache={}):((I.measure.maps||(I.measure.maps=[])).push(ka.map),(I.measure.caches||(I.measure.caches=[])).push({}))}Jg&&(Fh=ka.content.lastChild,/\bcm-tab\b/.test(Fh.className)||Fh.querySelector&& Fh.querySelector(".cm-tab"))&&(ka.content.className="cm-tab-wrap-hack");V(r,"renderLine",r,I.line,ka.pre);ka.pre.className&&(ka.textClass=a(ka.pre.className,ka.textClass||""));return ka}function zc(r){var I=k("span","•","cm-invalidchar");I.title="\\u"+r.charCodeAt(0).toString(16);I.setAttribute("aria-label",I.title);return I}function Tc(r,I,ka,ea,ra,Ga,Qa){if(I){if(r.splitSpaces){var Pa=r.trailingSpace;if(1af?Pa.appendChild(k("span",[ld])):Pa.appendChild(ld);r.map.push(r.pos,r.pos+pc,ld);r.col+=pc;r.pos+=pc}if(!Cc)break;Ac+=pc+1;"\t"==Cc[0]?(Cc=r.cm.options.tabSize,Cc-=r.col% Cc,pc=Pa.appendChild(k("span",y(Cc),"cm-tab")),pc.setAttribute("role","presentation"),pc.setAttribute("cm-text","\t"),r.col+=Cc):("\r"==Cc[0]||"\n"==Cc[0]?(pc=Pa.appendChild(k("span","\r"==Cc[0]?"␍":"␤","cm-invalidchar")),pc.setAttribute("cm-text",Cc[0])):(pc=r.cm.options.specialCharPlaceholder(Cc[0]),pc.setAttribute("cm-text",Cc[0]),Uf&&9>af?Pa.appendChild(k("span",[pc])):Pa.appendChild(pc)),r.col+=1);r.map.push(r.pos,r.pos+1,pc);r.pos++}}else r.col+=I.length,Pa=document.createTextNode(fb),r.map.push(r.pos, r.pos+I.length,Pa),Uf&&9>af&&(Kb=!0),r.pos+=I.length;r.trailingSpace=32==fb.charCodeAt(I.length-1);if(ka||ea||ra||Kb||Ga||Qa){I=ka||"";ea&&(I+=ea);ra&&(I+=ra);ea=k("span",[Pa],I,Ga);if(Qa)for(var be in Qa)Qa.hasOwnProperty(be)&&"style"!=be&&"class"!=be&&ea.setAttribute(be,Qa[be]);return r.content.appendChild(ea)}r.content.appendChild(Pa)}}function Fd(r,I){return function(ka,ea,ra,Ga,Qa,Pa,fb){ra=ra?ra+" cm-force-border":"cm-force-border";for(var Jb=ka.pos,Kb=Jb+ea.length;;){for(var Ac=void 0,Cc=0;Cc< I.length&&!(Ac=I[Cc],Ac.to>Jb&&Ac.from<=Jb);Cc++);if(Ac.to>=Kb)return r(ka,ea,ra,Ga,Qa,Pa,fb);r(ka,ea.slice(0,Ac.to-Jb),ra,Ga,null,Pa,fb);Ga=null;ea=ea.slice(Ac.to-Jb);Jb=Ac.to}}}function jd(r,I,ka,ea){var ra=!ea&&ka.widgetNode;ra&&r.map.push(r.pos,r.pos+I,ra);!ea&&r.cm.display.input.needsContentAttribute&&(ra||(ra=r.content.appendChild(document.createElement("span"))),ra.setAttribute("cm-marker",ka.id));ra&&(r.cm.display.input.setUneditable(ra),r.content.appendChild(ra));r.pos+=I;r.trailingSpace= !1}function me(r,I,ka){for(var ea=this.line=I,ra;ea=Te(ea,!1);)ea=ea.find(1,!0).line,(ra||(ra=[])).push(ea);this.size=(this.rest=ra)?ec(E(this.rest))-ka+1:1;this.node=this.text=null;this.hidden=Eb(r,I)}function vc(r,I,ka){var ea=[],ra;for(ra=I;raaf&&(r.node.style.zIndex=2));return r.node}function nc(r,I){var ka=r.display.externalMeasured;return ka&&ka.line==I.line?(r.display.externalMeasured=null, I.measure=ka.measure,ka.built):rc(r,I)}function mb(r,I){var ka=I.bgClass?I.bgClass+" "+(I.line.bgClass||""):I.line.bgClass;ka&&(ka+=" CodeMirror-linebackground");if(I.background)ka?I.background.className=ka:(I.background.parentNode.removeChild(I.background),I.background=null);else if(ka){var ea=tb(I);I.background=ea.insertBefore(k("div",null,ka),ea.firstChild);r.display.input.setUneditable(I.background)}I.line.wrapClass?tb(I).className=I.line.wrapClass:I.node!=I.text&&(I.node.className="");I.text.className= (I.textClass?I.textClass+" "+(I.line.textClass||""):I.line.textClass)||""}function oc(r,I,ka,ea){I.gutter&&(I.node.removeChild(I.gutter),I.gutter=null);I.gutterBackground&&(I.node.removeChild(I.gutterBackground),I.gutterBackground=null);if(I.line.gutterClass){var ra=tb(I);I.gutterBackground=k("div",null,"CodeMirror-gutter-background "+I.line.gutterClass,"left: "+(r.options.fixedGutter?ea.fixedPos:-ea.gutterTotalWidth)+"px; width: "+ea.gutterTotalWidth+"px");r.display.input.setUneditable(I.gutterBackground); ra.insertBefore(I.gutterBackground,I.text)}ra=I.line.gutterMarkers;if(r.options.lineNumbers||ra){var Ga=tb(I),Qa=I.gutter=k("div",null,"CodeMirror-gutter-wrapper","left: "+(r.options.fixedGutter?ea.fixedPos:-ea.gutterTotalWidth)+"px");r.display.input.setUneditable(Qa);Ga.insertBefore(Qa,I.text);I.line.gutterClass&&(Qa.className+=" "+I.line.gutterClass);!r.options.lineNumbers||ra&&ra["CodeMirror-linenumbers"]||(I.lineNumber=Qa.appendChild(k("div",hb(r.options,ka),"CodeMirror-linenumber CodeMirror-gutter-elt", "left: "+ea.gutterLeft["CodeMirror-linenumbers"]+"px; width: "+r.display.lineNumInnerWidth+"px")));if(ra)for(I=0;Ika)return{map:r.measure.maps[I],cache:r.measure.caches[I],before:!0}}function jg(r,I){if(I>=r.display.viewFrom&&I=r.lineN&&ICc;Cc++){for(;Pa&&W(I.line.text.charAt(Qa.coverStart+ Pa));)--Pa;for(;Qa.coverStart+fbaf&&0==Pa&&fb==Qa.coverEnd-Qa.coverStart)var pc=ea.parentNode.getBoundingClientRect();else{pc=Xi(ea,Pa,fb).getClientRects();fb=pd;if("left"==Kb)for(Jb=0;Jbaf&&((Cc=!window.screen||null==screen.logicalXDPI||screen.logicalXDPI== screen.deviceXDPI)||(null!=wi?Cc=wi:(Kb=n(r.display.measure,k("span","x")),Cc=Kb.getBoundingClientRect(),Kb=Xi(Kb,0,1).getBoundingClientRect(),Cc=wi=1af)|| Pa||pc&&(pc.left||pc.right)||(pc=(pc=ea.parentNode.getClientRects()[0])?{left:pc.left,right:pc.left+tc(r.display),top:pc.top,bottom:pc.bottom}:pd);ea=pc.top-I.rect.top;Pa=pc.bottom-I.rect.top;Cc=(ea+Pa)/2;Kb=I.view.measure.heights;for(Qa=0;QaI)Ga=fb-Pa,ra=Ga-1,I>=fb&&(Qa="right");if(null!=ra){ea=r[Jb+2];Pa==fb&&ka==(ea.insertLeft?"left":"right")&&(Qa=ka);if("left"==ka&&0==ra)for(;Jb&&r[Jb-2]==r[Jb-3]&&r[Jb-1].insertLeft;)ea=r[(Jb-=3)+2], Qa="left";if("right"==ka&&ra==fb-Pa)for(;Jb=ea.text.length?(Jb=ea.text.length,I="before"):0>=Jb&&(Jb=0,I="after");if(!fb)return Qa("before"==I?Jb-1:Jb,"before"==I);var Kb=O(fb,Jb,I),Ac=bi;Kb=Pa(Jb,Kb,"before"==I);null!=Ac&&(Kb.other=Pa(Jb,Ac,"before"!=I));return Kb}function kg(r,I){var ka=0;I=Ub(r.doc,I);r.options.lineWrapping||(ka=tc(r.display)* I.ch);I=Fb(r.doc,I.line);r=Za(I)+r.display.lineSpace.offsetTop;return{left:ka,right:ka,top:r,bottom:r+I.height}}function ne(r,I,ka,ea,ra){r=ib(r,I,ka);r.xRel=ra;ea&&(r.outside=ea);return r}function $a(r,I,ka){var ea=r.doc;ka+=r.display.viewOffset;if(0>ka)return ne(ea.first,0,null,-1,-1);var ra=Zb(ea,ka),Ga=ea.first+ea.size-1;if(ra>Ga)return ne(ea.first+ea.size-1,Fb(ea,Ga).text.length,null,1,1);0>I&&(I=0);for(var Qa=Fb(ea,ra);;){Ga=Na(r,Qa,ra,I,ka);var Pa=void 0;var fb=Ga.ch+(0fb)&&(!Pa||0>Jh(Pa,Kb.marker))&&(Pa=Kb.marker)}if(!Pa)return Ga;Ga=Pa.find(1);if(Ga.line==ra)return Ga;Qa=Fb(ea,ra=Ga.line)}}function fa(r,I,ka,ea){ea-=Cd(I);I=I.text.length;var ra=ja(function(Ga){return cb(r,ka,Ga-1).bottom<=ea},I,0);I=ja(function(Ga){return cb(r,ka,Ga).top>ea},ra,I);return{begin:ra,end:I}}function ma(r,I,ka,ea){ka||(ka=Ia(r,I));ea=bd(r, I,cb(r,ka,ea),"line").top;return fa(r,I,ka,ea)}function xa(r,I,ka,ea){return r.bottom<=ka?!1:r.top>ka?!0:(ea?r.left:r.right)>I}function Na(r,I,ka,ea,ra){ra-=Za(I);var Ga=Ia(r,I),Qa=Cd(I),Pa=0,fb=I.text.length,Jb=!0,Kb=X(I,r.doc.direction);Kb&&(Kb=(r.options.lineWrapping?xb:jb)(r,I,ka,Ga,Kb,ea,ra),Pa=(Jb=1!=Kb.level)?Kb.from:Kb.to-1,fb=Jb?Kb.to:Kb.from-1);var Ac=null,Cc=null;Kb=ja(function(ld){var be=cb(r,Ga,ld);be.top+=Qa;be.bottom+=Qa;if(!xa(be,ea,ra,!1))return!1;be.top<=ra&&be.left<=ea&&(Ac=ld, Cc=be);return!0},Pa,fb);var pc=!1;Cc?(Pa=ea-Cc.left=pc.bottom?1:0);Kb=ia(I.text,Kb,1);return ne(ka,Kb,Jb,pc,ea-Pa)}function jb(r,I,ka,ea,ra,Ga,Qa){var Pa=ja(function(Kb){Kb=ra[Kb];var Ac=1!=Kb.level;return xa(ge(r,ib(ka,Ac?Kb.to: Kb.from,Ac?"before":"after"),"line",I,ea),Ga,Qa,!0)},0,ra.length-1),fb=ra[Pa];if(0Qa&&(fb=ra[Pa-1])}return fb}function xb(r,I,ka,ea,ra,Ga,Qa){Qa=fa(r,I,ea,Qa);ka=Qa.begin;Qa=Qa.end;/\s/.test(I.text.charAt(Qa-1))&&Qa--;for(var Pa=I=null,fb=0;fb=Qa||Jb.to<=ka)){var Kb=cb(r,ea,1!=Jb.level?Math.min(Qa,Jb.to)-1:Math.max(ka,Jb.from)).right;Kb=KbKb)I=Jb,Pa=Kb}}I||(I=ra[ra.length-1]);I.fromQa&&(I={from:I.from,to:Qa,level:I.level});return I}function Xb(r){if(null!=r.cachedTextHeight)return r.cachedTextHeight;if(null==yd){yd=k("pre",null,"CodeMirror-line-like");for(var I=0;49>I;++I)yd.appendChild(document.createTextNode("x")),yd.appendChild(k("br"));yd.appendChild(document.createTextNode("x"))}n(r.measure,yd);I=yd.offsetHeight/50;3=r.display.viewTo)return null;I-=r.display.viewFrom;if(0>I)return null;r=r.display.view;for(var ka=0;kaI)return ka}function qe(r,I,ka,ea){null==I&&(I=r.doc.first);null==ka&&(ka=r.doc.first+r.doc.size);ea||(ea=0);var ra=r.display;ea&&kaI)&&(ra.updateLineNumbers=I);r.curOp.viewChanged=!0;if(I>=ra.viewTo)Md&& Se(r.doc,I)ra.viewFrom?Kg(r):(ra.viewFrom+=ea,ra.viewTo+=ea);else if(I<=ra.viewFrom&&ka>=ra.viewTo)Kg(r);else if(I<=ra.viewFrom){var Ga=Uh(r,ka,ka+ea,1);Ga?(ra.view=ra.view.slice(Ga.index),ra.viewFrom=Ga.lineN,ra.viewTo+=ea):Kg(r)}else if(ka>=ra.viewTo)(Ga=Uh(r,I,I,-1))?(ra.view=ra.view.slice(0,Ga.index),ra.viewTo=Ga.lineN):Kg(r);else{Ga=Uh(r,I,I,-1);var Qa=Uh(r,ka,ka+ea,1);Ga&&Qa?(ra.view=ra.view.slice(0,Ga.index).concat(vc(r,Ga.lineN, Qa.lineN)).concat(ra.view.slice(Qa.index)),ra.viewTo+=ea):Kg(r)}if(r=ra.externalMeasured)ka=ra.lineN&&I=ea.viewTo||(r=ea.view[je(r,I)],null!=r.node&&(r=r.changes||(r.changes=[]),-1==q(r,ka)&&r.push(ka)))}function Kg(r){r.display.viewFrom=r.display.viewTo=r.doc.first;r.display.view= [];r.display.viewOffset=0}function Uh(r,I,ka,ea){var ra=je(r,I),Ga=r.display.view;if(!Md||ka==r.doc.first+r.doc.size)return{index:ra,lineN:ka};for(var Qa=r.display.viewFrom,Pa=0;Paea?0:Ga.length-1))return null;ka+=ea*Ga[ra-(0>ea?1:0)].size;ra+=ea}return{index:ra,lineN:ka}}function Vh(r){r=r.display.view;for(var I=0,ka=0;ka=r.display.viewTo||Pa.to().lineld&&(ld=0);ld=Math.round(ld);df=Math.round(df);Pa.appendChild(k("div",null,"CodeMirror-selected","position: absolute; left: "+pc+"px;\n top: "+ld+"px; width: "+(null==be?Kb-pc:be)+"px;\n height: "+(df-ld)+"px"))}function ra(pc,ld,be){function df(Ke,ig){return md(r,ib(pc,Ke),"div",Le,ig)}function Eh(Ke,ig,Xf){Ke=ma(r,Le,null,Ke); ig="ltr"==ig==("after"==Xf)?"left":"right";Xf="after"==Xf?Ke.begin:Ke.end-(/\s/.test(Le.text.charAt(Ke.end-1))?2:1);return df(Xf,ig)[ig]}var Le=Fb(Qa,pc),Hf=Le.text.length,Ag,Gg,rg=X(Le,Qa.direction);da(rg,ld||0,null==be?Hf:be,function(Ke,ig,Xf,bg){var Fh="ltr"==Xf,Pg=df(Ke,Fh?"left":"right"),Fi=df(ig-1,Fh?"right":"left"),Ak=null==ld&&0==Ke,Lk=null==be&&ig==Hf,wl=0==bg;bg=!rg||bg==rg.length-1;3>=Fi.top-Pg.top?(ig=(Ac?Ak:Lk)&&wl?Jb:(Fh?Pg:Fi).left,ea(ig,Pg.top,((Ac?Lk:Ak)&&bg?Kb:(Fh?Fi:Pg).right)- ig,Pg.bottom)):(Fh?(Fh=Ac&&Ak&&wl?Jb:Pg.left,Ak=Ac?Kb:Eh(Ke,Xf,"before"),Ke=Ac?Jb:Eh(ig,Xf,"after"),Lk=Ac&&Lk&&bg?Kb:Fi.right):(Fh=Ac?Eh(Ke,Xf,"before"):Jb,Ak=!Ac&&Ak&&wl?Kb:Pg.right,Ke=!Ac&&Lk&&bg?Jb:Fi.left,Lk=Ac?Eh(ig,Xf,"after"):Kb),ea(Fh,Pg.top,Ak-Fh,Pg.bottom),Pg.bottomId(Pg,Ag))Ag=Pg;0>Id(Fi,Ag)&&(Ag=Fi);if(!Gg||0>Id(Pg,Gg))Gg=Pg;0>Id(Fi,Gg)&&(Gg=Fi)});return{start:Ag,end:Gg}}var Ga=r.display,Qa=r.doc,Pa=document.createDocumentFragment(), fb=qc(r.display),Jb=fb.left,Kb=Math.max(Ga.sizerWidth,od(r)-Ga.sizer.offsetLeft)-fb.right,Ac="ltr"==Qa.direction;Ga=I.from();I=I.to();if(Ga.line==I.line)ra(Ga.line,Ga.ch,I.ch);else{var Cc=Fb(Qa,Ga.line);fb=Fb(Qa,I.line);fb=xg(Cc)==xg(fb);Ga=ra(Ga.line,Ga.ch,fb?Cc.text.length+1:null).end;I=ra(I.line,fb?0:null,I.ch).start;fb&&(Ga.topr.options.cursorBlinkRate&&(I.cursorDiv.style.visibility="hidden")}}function Vj(r){r.state.focused||(r.display.input.focus(),Qe(r))}function Ni(r){r.state.delayingBlurEvent=!0;setTimeout(function(){r.state.delayingBlurEvent&& (r.state.delayingBlurEvent=!1,Dk(r))},100)}function Qe(r,I){r.state.delayingBlurEvent&&(r.state.delayingBlurEvent=!1);"nocursor"!=r.options.readOnly&&(r.state.focused||(V(r,"focus",r,I),r.state.focused=!0,p(r.display.wrapper,"CodeMirror-focused"),r.curOp||r.display.selForContextMenu==r.doc.sel||(r.display.input.reset(),Jg&&setTimeout(function(){return r.display.input.reset(!0)},20)),r.display.input.receivedFocus()),oi(r))}function Dk(r,I){r.state.delayingBlurEvent||(r.state.focused&&(V(r,"blur",r, I),r.state.focused=!1,Ch(r.display.wrapper,"CodeMirror-focused")),clearInterval(r.display.blinker),setTimeout(function(){r.state.focused||(r.display.shift=!1)},150))}function Xk(r){for(var I=r.display,ka=I.lineDiv.offsetTop,ea=0;eaaf){Ga=ra.node.offsetTop+ra.node.offsetHeight;var Pa=Ga-ka;ka=Ga}else{var fb=ra.node.getBoundingClientRect();Pa=fb.bottom-fb.top;!Ga&&ra.text.firstChild&&(Qa=ra.text.firstChild.getBoundingClientRect().right- fb.left-1)}Ga=ra.line.height-Pa;if(.005Ga)if(Db(ra.line,Pa),yh(ra.line),ra.rest)for(Pa=0;Par.display.sizerWidth&&(Qa=Math.ceil(Qa/tc(r.display)),Qa>r.display.maxLineLength&&(r.display.maxLineLength=Qa,r.display.maxLine=ra.line,r.display.maxLineChanged=!0))}}}function yh(r){if(r.widgets)for(var I=0;I=ra&&(ea=Zb(I,Za(Fb(I,ka))-r.wrapper.clientHeight),ra=ka)}return{from:ea,to:Math.max(ra,ea+1)}}function Ol(r,I){var ka=r.display,ea=Xb(r.display);0>I.top&&(I.top=0);var ra=r.curOp&&null!=r.curOp.scrollTop? r.curOp.scrollTop:ka.scroller.scrollTop,Ga=sf(r),Qa={};I.bottom-I.top>Ga&&(I.bottom=I.top+Ga);var Pa=r.doc.height+$c(ka),fb=I.topPa-ea;I.topra+Ga&&(Ga=Math.min(I.top,(ea?Pa:I.bottom)-Ga),Ga!=ra&&(Qa.scrollTop=Ga));ra=r.curOp&&null!=r.curOp.scrollLeft?r.curOp.scrollLeft:ka.scroller.scrollLeft;r=od(r)-(r.options.fixedGutter?ka.gutters.offsetWidth:0);if(ka=I.right-I.left>r)I.right=I.left+r;10>I.left?Qa.scrollLeft=0:I.leftr+ra-3&&(Qa.scrollLeft=I.right+(ka?0:10)-r);return Qa}function xj(r,I){null!=I&&(Hi(r),r.curOp.scrollTop=(null==r.curOp.scrollTop?r.doc.scrollTop:r.curOp.scrollTop)+I)}function sg(r){Hi(r);var I=r.getCursor();r.curOp.scrollToPos={from:I,to:I,margin:r.options.cursorScrollMargin}}function yj(r,I,ka){null==I&&null==ka||Hi(r);null!=I&&(r.curOp.scrollLeft=I);null!=ka&&(r.curOp.scrollTop=ka)}function Hi(r){var I=r.curOp.scrollToPos;if(I){r.curOp.scrollToPos=null;var ka=kg(r,I.from), ea=kg(r,I.to);Pl(r,ka,ea,I.margin)}}function Pl(r,I,ka,ea){I=Ol(r,{left:Math.min(I.left,ka.left),top:Math.min(I.top,ka.top)-ea,right:Math.max(I.right,ka.right),bottom:Math.max(I.bottom,ka.bottom)+ea});yj(r,I.scrollLeft,I.scrollTop)}function Wj(r,I){2>Math.abs(r.doc.scrollTop-I)||(Qh||ak(r,{top:I}),Yk(r,I,!0),Qh&&ak(r),Og(r,100))}function Yk(r,I,ka){I=Math.max(0,Math.min(r.display.scroller.scrollHeight-r.display.scroller.clientHeight,I));if(r.display.scroller.scrollTop!=I||ka)r.doc.scrollTop=I,r.display.scrollbars.setScrollTop(I), r.display.scroller.scrollTop!=I&&(r.display.scroller.scrollTop=I)}function Zi(r,I,ka,ea){I=Math.max(0,Math.min(I,r.display.scroller.scrollWidth-r.display.scroller.clientWidth));(ka?I==r.doc.scrollLeft:2>Math.abs(r.doc.scrollLeft-I))&&!ea||(r.doc.scrollLeft=I,yc(r),r.display.scroller.scrollLeft!=I&&(r.display.scroller.scrollLeft=I),r.display.scrollbars.setScrollLeft(I))}function Fk(r){var I=r.display,ka=I.gutters.offsetWidth,ea=Math.round(r.doc.height+$c(r.display));return{clientHeight:I.scroller.clientHeight, viewHeight:I.wrapper.clientHeight,scrollWidth:I.scroller.scrollWidth,clientWidth:I.scroller.clientWidth,viewWidth:I.wrapper.clientWidth,barLeft:r.options.fixedGutter?ka:0,docHeight:ea,scrollHeight:ea+yb(r)+I.barHeight,nativeBarWidth:I.nativeBarWidth,gutterWidth:ka}}function Yj(r,I){I||(I=Fk(r));var ka=r.display.barWidth,ea=r.display.barHeight;ql(r,I);for(I=0;4>I&&ka!=r.display.barWidth||ea!=r.display.barHeight;I++)ka!=r.display.barWidth&&r.options.lineWrapping&&Xk(r),ql(r,Fk(r)),ka=r.display.barWidth, ea=r.display.barHeight}function ql(r,I){var ka=r.display,ea=ka.scrollbars.update(I);ka.sizer.style.paddingRight=(ka.barWidth=ea.right)+"px";ka.sizer.style.paddingBottom=(ka.barHeight=ea.bottom)+"px";ka.heightForcer.style.borderBottom=ea.bottom+"px solid transparent";ea.right&&ea.bottom?(ka.scrollbarFiller.style.display="block",ka.scrollbarFiller.style.height=ea.bottom+"px",ka.scrollbarFiller.style.width=ea.right+"px"):ka.scrollbarFiller.style.display="";ea.bottom&&r.options.coverGutterNextToScrollbar&& r.options.fixedGutter?(ka.gutterFiller.style.display="block",ka.gutterFiller.style.height=ea.bottom+"px",ka.gutterFiller.style.width=I.gutterWidth+"px"):ka.gutterFiller.style.display=""}function lj(r){r.display.scrollbars&&(r.display.scrollbars.clear(),r.display.scrollbars.addClass&&Ch(r.display.wrapper,r.display.scrollbars.addClass));r.display.scrollbars=new Ei[r.options.scrollbarStyle](function(I){r.display.wrapper.insertBefore(I,r.display.scrollbarFiller);Ne(I,"mousedown",function(){r.state.focused&& setTimeout(function(){return r.display.input.focus()},0)});I.setAttribute("cm-not-content","true")},function(I,ka){"horizontal"==ka?Zi(r,I):Wj(r,I)},r);r.display.scrollbars.addClass&&p(r.display.wrapper,r.display.scrollbars.addClass)}function $i(r){r.curOp={cm:r,viewChanged:!1,startHeight:r.doc.height,forceUpdate:!1,updateInput:0,typing:!1,changeObjs:null,cursorActivityHandlers:null,cursorActivityCalled:0,selectionChanged:!1,updateMaxLine:!1,scrollLeft:null,scrollTop:null,scrollToPos:null,focus:!1, id:++Kl};r=r.curOp;ng?ng.ops.push(r):r.ownsGroup=ng={ops:[r],delayedCallbacks:[]}}function Zj(r){(r=r.curOp)&&$b(r,function(I){for(var ka=0;ka=Ga.viewTo)||Ga.maxLineChanged&&ra.options.lineWrapping;ea.update=ea.mustUpdate&&new vj(ra,ea.mustUpdate&&{top:ea.scrollTop,ensure:ea.scrollToPos},ea.forceUpdate)}for(ka=0;kaAc;Ac++){var Cc=!1;Pa=ge(ra,fb);var pc=Jb&&Jb!=fb?ge(ra,Jb):Pa;Pa={left:Math.min(Pa.left,pc.left),top:Math.min(Pa.top,pc.top)-Kb,right:Math.max(Pa.left,pc.left),bottom:Math.max(Pa.bottom,pc.bottom)+Kb};pc=Ol(ra,Pa);var ld=ra.doc.scrollTop,be=ra.doc.scrollLeft;null!=pc.scrollTop&&(Wj(ra, pc.scrollTop),1Jb.top+Ac.top?fb=!0:Jb.bottom+Ac.top>(window.innerHeight||document.documentElement.clientHeight)&&(fb=!1),null==fb||Vg||(Jb=k("div","​",null,"position: absolute;\n top: "+(Jb.top-Kb.viewOffset-ra.display.lineSpace.offsetTop)+ "px;\n height: "+(Jb.bottom-Jb.top+yb(ra)+Kb.barHeight)+"px;\n left: "+Jb.left+"px; width: "+Math.max(2,Jb.right-Jb.left)+"px;"),ra.display.lineSpace.appendChild(Jb),Jb.scrollIntoView(fb),ra.display.lineSpace.removeChild(Jb)))}Jb=ea.maybeHiddenMarkers;fb=ea.maybeUnhiddenMarkers;if(Jb)for(Kb=0;Kb=r.display.viewTo)){var ka=+new Date+r.options.workTime,ea=Mc(r,I.highlightFrontier),ra=[];I.iter(ea.line,Math.min(I.first+I.size,r.display.viewTo+500),function(Ga){if(ea.line>=r.display.viewFrom){var Qa=Ga.styles,Pa=Ga.text.length>r.options.maxHighlightLength? Ta(I.mode,ea.state):null,fb=Dc(r,Ga,ea,!0);Pa&&(ea.state=Pa);Ga.styles=fb.styles;Pa=Ga.styleClasses;(fb=fb.classes)?Ga.styleClasses=fb:Pa&&(Ga.styleClasses=null);fb=!Qa||Qa.length!=Ga.styles.length||Pa!=fb&&(!Pa||!fb||Pa.bgClass!=fb.bgClass||Pa.textClass!=fb.textClass);for(Pa=0;!fb&&Pa ka)return Og(r,r.options.workDelay),!0});I.highlightFrontier=ea.line;I.modeFrontier=Math.max(I.modeFrontier,ea.line);ra.length&&Wd(r,function(){for(var Ga=0;Ga=ka.viewFrom&&I.visible.to<=ka.viewTo&&(null==ka.updateLineNumbers||ka.updateLineNumbers>=ka.viewTo)&&ka.renderedView==ka.view&&0==Vh(r))return!1;Gk(r)&&(Kg(r),I.dims=gd(r));var ra=ea.first+ea.size, Ga=Math.max(I.visible.from-r.options.viewportMargin,ea.first),Qa=Math.min(ra,I.visible.to+r.options.viewportMargin);ka.viewFromGa-ka.viewFrom&&(Ga=Math.max(ea.first,ka.viewFrom));ka.viewTo>Qa&&20>ka.viewTo-Qa&&(Qa=Math.min(ra,ka.viewTo));Md&&(Ga=Se(r.doc,Ga),Qa=vb(r.doc,Qa));ea=Ga!=ka.viewFrom||Qa!=ka.viewTo||ka.lastWrapHeight!=I.wrapperHeight||ka.lastWrapWidth!=I.wrapperWidth;ra=r.display;0==ra.view.length||Ga>=ra.viewTo||Qa<=ra.viewFrom?(ra.view=vc(r,Ga,Qa),ra.viewFrom=Ga):(ra.viewFrom> Ga?ra.view=vc(r,Ga,ra.viewFrom).concat(ra.view):ra.viewFromQa&&(ra.view=ra.view.slice(0,je(r,Qa))));ra.viewTo=Qa;ka.viewOffset=Za(Fb(r.doc,ka.viewFrom));r.display.mover.style.top=ka.viewOffset+"px";Qa=Vh(r);if(!ea&&0==Qa&&!I.force&&ka.renderedView==ka.view&&(null==ka.updateLineNumbers||ka.updateLineNumbers>=ka.viewTo))return!1;r.hasFocus()?Ga=null:(Ga=h())&&f(r.display.lineDiv,Ga)? (Ga={activeElt:Ga},window.getSelection&&(ra=window.getSelection(),ra.anchorNode&&ra.extend&&f(r.display.lineDiv,ra.anchorNode)&&(Ga.anchorNode=ra.anchorNode,Ga.anchorOffset=ra.anchorOffset,Ga.focusNode=ra.focusNode,Ga.focusOffset=ra.focusOffset))):Ga=null;4=r.display.viewFrom&&I.visible.to<=r.display.viewTo)break;if(!Hg(r,I))break;Xk(r);ea=Fk(r);Lg(r);Yj(r,ea);ce(r,ea);I.force=!1}I.signal(r,"update",r);if(r.display.viewFrom!=r.display.reportedViewFrom||r.display.viewTo!=r.display.reportedViewTo)I.signal(r,"viewportChange", r,r.display.viewFrom,r.display.viewTo),r.display.reportedViewFrom=r.display.viewFrom,r.display.reportedViewTo=r.display.viewTo}function ak(r,I){I=new vj(r,I);if(Hg(r,I)){Xk(r);Xh(r,I);var ka=Fk(r);Lg(r);Yj(r,ka);ce(r,ka);I.finish()}}function mj(r,I,ka){function ea(Cc){var pc=Cc.nextSibling;Jg&&Lf&&r.display.currentWheelTarget==Cc?Cc.style.display="none":Cc.parentNode.removeChild(Cc);return pc}var ra=r.display,Ga=r.options.lineNumbers,Qa=ra.lineDiv,Pa=Qa.firstChild,fb=ra.view;ra=ra.viewFrom;for(var Jb= 0;Jbaf&&(this.gutters.style.zIndex=-1,this.scroller.style.paddingRight=0);Jg||Qh&&lk||(this.scroller.draggable=!0);r&&(r.appendChild?r.appendChild(this.wrapper):r(this.wrapper));this.reportedViewFrom=this.reportedViewTo=this.viewFrom=this.viewTo=I.first;this.view=[];this.externalMeasured=this.renderedView=null;this.lastWrapHeight=this.lastWrapWidth=this.viewOffset=0;this.updateLineNumbers=null;this.nativeBarWidth=this.barHeight=this.barWidth=0;this.scrollbarsClipped= !1;this.lineNumWidth=this.lineNumInnerWidth=this.lineNumChars=null;this.alignWidgets=!1;this.maxLine=this.cachedCharWidth=this.cachedTextHeight=this.cachedPaddingH=null;this.maxLineLength=0;this.maxLineChanged=!1;this.wheelDX=this.wheelDY=this.wheelStartX=this.wheelStartY=null;this.shift=!1;this.activeTouch=this.selForContextMenu=null;this.gutterSpecs=ff(ea.gutters,ea.lineNumbers);Oi(this);ka.init(this)}function Ik(r){var I=r.wheelDeltaX,ka=r.wheelDeltaY;null==I&&r.detail&&r.axis==r.HORIZONTAL_AXIS&& (I=r.detail);null==ka&&r.detail&&r.axis==r.VERTICAL_AXIS?ka=r.detail:null==ka&&(ka=r.wheelDelta);return{x:I,y:ka}}function Wg(r){r=Ik(r);r.x*=zg;r.y*=zg;return r}function bk(r,I){var ka=Ik(I),ea=ka.x;ka=ka.y;var ra=r.display,Ga=ra.scroller,Qa=Ga.scrollWidth>Ga.clientWidth,Pa=Ga.scrollHeight>Ga.clientHeight;if(ea&&Qa||ka&&Pa){if(ka&&Lf&&Jg){Qa=I.target;var fb=ra.view;a:for(;Qa!=Ga;Qa=Qa.parentNode)for(var Jb=0;JbI?Pa=Math.max(0,Pa+I-50):Qa=Math.min(r.doc.height,Qa+I+50),ak(r,{top:Pa,bottom:Qa})),20>eh&&(null==ra.wheelStartX?(ra.wheelStartX=Ga.scrollLeft,ra.wheelStartY=Ga.scrollTop,ra.wheelDX=ea,ra.wheelDY=ka,setTimeout(function(){if(null!=ra.wheelStartX){var Kb=Ga.scrollLeft-ra.wheelStartX,Ac=Ga.scrollTop-ra.wheelStartY;Kb=Ac&&ra.wheelDY&&Ac/ra.wheelDY||Kb&&ra.wheelDX&&Kb/ra.wheelDX;ra.wheelStartX=ra.wheelStartY=null; Kb&&(zg=(zg*eh+Kb)/(eh+1),++eh)}},200)):(ra.wheelDX+=ea,ra.wheelDY+=ka))):(ka&&Pa&&Wj(r,Math.max(0,Ga.scrollTop+ka*zg)),Zi(r,Math.max(0,Ga.scrollLeft+ea*zg)),(!ka||ka&&Pa)&&ua(I),ra.wheelStartX=null)}}function Cg(r,I,ka){r=r&&r.options.selectionsMayTouch;ka=I[ka];I.sort(function(fb,Jb){return La(fb.from(),Jb.from())});ka=q(I,ka);for(var ea=1;eaLa(r,I.from))return r;if(0>=La(r,I.to))return tg(I);var ka=r.line+I.text.length-(I.to.line-I.from.line)-1,ea=r.ch;r.line==I.to.line&&(ea+=tg(I).ch-I.to.ch);return ib(ka,ea)}function Wb(r,I){for(var ka= [],ea=0;eaGa-(r.cm?r.cm.options.historyEventDelay:500)||"*"==I.origin.charAt(0))){if(ra.lastOp==ea){ck(ra.done);var Pa=E(ra.done)}else ra.done.length&&!E(ra.done).ranges? Pa=E(ra.done):1ra.undoDepth;)ra.done.shift(),ra.done[0].ranges||ra.done.shift();ra.done.push(ka);ra.generation=++ra.maxGeneration;ra.lastModTime=ra.lastSelTime=Ga;ra.lastOp= ra.lastSelOp=ea;ra.lastOrigin=ra.lastSelOrigin=I.origin;fb||V(r,"historyAdded")}function aj(r,I){var ka=E(I);ka&&ka.ranges&&ka.equals(r)||I.push(r)}function $k(r,I,ka,ea){var ra=I["spans_"+r.id],Ga=0;r.iter(Math.max(r.first,ka),Math.min(r.first+r.size,ea),function(Qa){Qa.markedSpans&&((ra||(ra=I["spans_"+r.id]={}))[Ga]=Qa.markedSpans);++Ga})}function Hn(r,I){var ka;if(ka=I["spans_"+r.id]){for(var ea=[],ra=0;raLa(I,r),ea!=0>La(ka,r)?(r=I,I=ka):ea!=0>La(I,ka)&&(I=ka)),new zf(r,I)):new zf(ka||I,I)}function Yg(r,I,ka,ea,ra){null==ra&&(ra=r.cm&&(r.cm.display.shift|| r.extend));Ze(r,new de([dk(r.sel.primary(),I,ka,ra)],0),ea)}function ki(r,I,ka){for(var ea=[],ra=r.cm&&(r.cm.display.shift||r.extend),Ga=0;GaLa(I.primary().head, r.sel.primary().head)?-1:1);Df(r,qj(r,I,ea,!0));ka&&!1===ka.scroll||!r.cm||sg(r.cm)}function Df(r,I){I.equals(r.sel)||(r.sel=I,r.cm&&(r.cm.curOp.updateInput=1,r.cm.curOp.selectionChanged=!0,N(r.cm)),Ae(r,"cursorActivity",r))}function qi(r){Df(r,qj(r,r.sel,null,!1))}function qj(r,I,ka,ea){for(var ra,Ga=0;Ga=I.ch:Pa.to>I.ch))){if(ra&&(V(fb,"beforeCursorEnter"),fb.explicitlyCleared))if(Ga.markedSpans){--Qa; continue}else break;if(fb.atomic){if(ka){Qa=fb.find(0>ea?1:-1);Pa=void 0;if(0>ea?Kb:Jb)Qa=Qi(r,Qa,-ea,Qa&&Qa.line==I.line?Ga:null);if(Qa&&Qa.line==I.line&&(Pa=La(Qa,ka))&&(0>ea?0>Pa:0ea?-1:1);if(0>ea?Jb:Kb)ka=Qi(r,ka,ea,ka.line==I.line?Ga:null);return ka?ek(r,ka,I,ea,ra):null}}}return I}function nh(r,I,ka,ea,ra){ea=ea||1;I=ek(r,I,ka,ea,ra)||!ra&&ek(r,I,ka,ea,!0)||ek(r,I,ka,-ea,ra)||!ra&&ek(r,I,ka,-ea,!0);return I?I:(r.cantEdit=!0,ib(r.first,0))}function Qi(r, I,ka,ea){return 0>ka&&0==I.ch?I.line>r.first?Ub(r,ib(I.line-1)):null:0r.lastLine())){if(I.from.linera&&(I={from:I.from,to:ib(ra,Fb(r,ra).text.length),text:[I.text[0]], origin:I.origin});I.removed=Sb(r,I.from,I.to);ka||(ka=Wb(r,I));r.cm?gk(r.cm,I,ea):Ii(r,I,ea);Jf(r,ka,Rh);r.cantEdit&&nh(r,ib(r.firstLine(),0))&&(r.cantEdit=!1)}}function gk(r,I,ka){var ea=r.doc,ra=r.display,Ga=I.from,Qa=I.to,Pa=!1,fb=Ga.line;r.options.lineWrapping||(fb=ec(xg(Fb(ea,Ga.line))),ea.iter(fb,Qa.line+1,function(Jb){if(Jb==ra.maxLine)return Pa=!0}));-1ra.maxLineLength&&(ra.maxLine=Jb,ra.maxLineLength=Kb,ra.maxLineChanged=!0,Pa=!1)}),Pa&&(r.curOp.updateMaxLine=!0));Ie(ea,Ga.line);Og(r,400);ka=I.text.length-(Qa.line-Ga.line)-1;I.full?qe(r):Ga.line!=Qa.line||1!=I.text.length||Pf(r.doc,I)?qe(r,Ga.line,Qa.line+1,ka):tf(r,Ga.line,"text");ka=J(r,"changes");if((ea=J(r,"change"))||ka)I={from:Ga,to:Qa,text:I.text,removed:I.removed,origin:I.origin},ea&&Ae(r,"change",r,I),ka&&(r.curOp.changeObjs||(r.curOp.changeObjs=[])).push(I);r.display.selForContextMenu= null}function Bg(r,I,ka,ea,ra){ea||(ea=ka);0>La(ea,ka)&&(ea=[ea,ka],ka=ea[0],ea=ea[1]);"string"==typeof I&&(I=r.splitLines(I));Vf(r,{from:ka,to:ea,text:I,origin:ra})}function Re(r,I,ka,ea){ka=La(Ga.from,E(ea).to);){var Qa=ea.pop();if(0>La(Qa.from,Ga.from)){Ga.from=Qa.from;break}}ea.push(Ga)}Wd(r,function(){for(var Pa=ea.length-1;0<=Pa;Pa--)Bg(r.doc,"",ea[Pa].from,ea[Pa].to,"+delete");sg(r)})}function ik(r,I,ka){I=ia(r.text,I+ka,ka);return 0>I||I>r.text.length?null:I}function Hj(r,I,ka){r=ik(r,I.ch,ka);return null==r?null:new ib(I.line,r,0>ka?"after":"before")}function kk(r,I,ka,ea,ra){if(r&&("rtl"==I.doc.direction&&(ra=-ra), r=X(ka,I.doc.direction))){r=0>ra?E(r):r[0];var Ga=0>ra==(1==r.level)?"after":"before";if(0ra?ka.text.length-1:0;var fb=cb(I,Qa,Pa).top;Pa=ja(function(Jb){return cb(I,Qa,Jb).top==fb},0>ra==(1==r.level)?r.from:r.to-1,Pa);"before"==Ga&&(Pa=ik(ka,Pa,1))}else Pa=0>ra?r.to:r.from;return new ib(ea,Pa,Ga)}return new ib(ea,0>ra?ka.text.length:0,0>ra?"before":"after")}function Ri(r,I,ka,ea){var ra=X(I,r.doc.direction);if(!ra)return Hj(I,ka,ea);ka.ch>= I.text.length?(ka.ch=I.text.length,ka.sticky="before"):0>=ka.ch&&(ka.ch=0,ka.sticky="after");var Ga=O(ra,ka.ch,ka.sticky),Qa=ra[Ga];if("ltr"==r.doc.direction&&0==Qa.level%2&&(0ka.ch:Qa.fromea,Cc=Pa(ka,Ac?1:-1);if(null!=Cc&&(Ac?Cc<=Qa.to&&Cc<=Kb.end:Cc>=Qa.from&&Cc>=Kb.begin))return new ib(ka.line,Cc,Ac?"before":"after")}Qa=function(pc,ld,be){for(var df=function(Ag,Gg){return Gg?new ib(ka.line,Pa(Ag,1),"before"):new ib(ka.line,Ag,"after")};0<=pc&&pcaf&&27==r.keyCode&&(r.returnValue=!1);var I=r.keyCode;this.display.shift=16==I||r.shiftKey;var ka=Wl(this,r);vh&&(al=ka?I:null,!ka&&88==I&&!Hh&&(Lf?r.metaKey:r.ctrlKey)&&this.replaceSelection("",null,"cut"));Qh&&!Lf&&!ka&&46==I&&r.shiftKey&&!r.ctrlKey&&document.execCommand&&document.execCommand("cut"); 18!=I||/\bCodeMirror-crosshair\b/.test(this.display.lineDiv.className)||zj(this)}}function zj(r){function I(ea){18!=ea.keyCode&&ea.altKey||(Ch(ka,"CodeMirror-crosshair"),Q(document,"keyup",I),Q(document,"mouseover",I))}var ka=r.display.lineDiv;p(ka,"CodeMirror-crosshair");Ne(document,"keyup",I);Ne(document,"mouseover",I)}function Sl(r){16==r.keyCode&&(this.doc.sel.shift=!1);L(this,r)}function Xl(r){if(!(r.target&&r.target!=this.display.input.getField()||Ic(this.display,r)||L(this,r)||r.ctrlKey&&!r.altKey|| Lf&&r.metaKey)){var I=r.keyCode,ka=r.charCode;if(vh&&I==al)al=null,ua(r);else if(!vh||r.which&&!(10>r.which)||!Wl(this,r))if(I=String.fromCharCode(null==ka?I:ka),"\b"!=I&&!nn(this,r,I))this.display.input.onKeyPress(r)}}function kh(r,I){var ka=+new Date;if(Ml&&Ml.compare(ka,r,I))return oe=Ml=null,"triple";if(oe&&oe.compare(ka,r,I))return Ml=new Uj(ka,r,I),oe=null,"double";oe=new Uj(ka,r,I);Ml=null;return"single"}function Yf(r){var I=this.display;if(!(L(this,r)||I.activeTouch&&I.input.supportsTouch()))if(I.input.ensurePolled(), I.shift=r.shiftKey,Ic(I,r))Jg||(I.scroller.draggable=!1,setTimeout(function(){return I.scroller.draggable=!0},100));else if(!Oh(this,r,"gutterClick",!0)){var ka=he(this,r),ea=wa(r),ra=ka?kh(ka,ea):"single";window.focus();1==ea&&this.state.selectingText&&this.state.selectingText(r);if(!ka||!hi(this,ea,ka,ra,r))if(1==ea)ka?gh(this,ka,ra,r):(r.target||r.srcElement)==I.scroller&&ua(r);else if(2==ea)ka&&Yg(this.doc,ka),setTimeout(function(){return I.input.focus()},20);else if(3==ea)if(Nk)this.display.input.onContextMenu(r); else Ni(this)}}function hi(r,I,ka,ea,ra){var Ga="Click";"double"==ea?Ga="Double"+Ga:"triple"==ea&&(Ga="Triple"+Ga);return xl(r,Vd((1==I?"Left":2==I?"Middle":"Right")+Ga,ra),ra,function(Qa){"string"==typeof Qa&&(Qa=Lj[Qa]);if(!Qa)return!1;var Pa=!1;try{r.isReadOnly()&&(r.state.suppressEdits=!0),Pa=Qa(r,ka)!=Uk}finally{r.state.suppressEdits=!1}return Pa})}function gh(r,I,ka,ea){Uf?setTimeout(u(Vj,r),0):r.curOp.focus=h();var ra=r.getOption("configureMouse");ra=ra?ra(r,ka,ea):{};null==ra.unit&&(ra.unit= (yf?ea.shiftKey&&ea.metaKey:ea.altKey)?"rectangle":"single"==ka?"char":"double"==ka?"word":"line");if(null==ra.extend||r.doc.extend)ra.extend=r.doc.extend||ea.shiftKey;null==ra.addNew&&(ra.addNew=Lf?ea.metaKey:ea.ctrlKey);null==ra.moveOnDrag&&(ra.moveOnDrag=!(Lf?ea.altKey:ea.ctrlKey));var Ga=r.doc.sel,Qa;r.options.dragDrop&&Jl&&!r.isReadOnly()&&"single"==ka&&-1<(Qa=Ga.contains(I))&&(0>La((Qa=Ga.ranges[Qa]).from(),I)||0I.xRel)?Ek(r,ea,I,ra):Li(r,ea,I,ra)}function Ek(r, I,ka,ea){var ra=r.display,Ga=!1,Qa=Pe(r,function(Jb){Jg&&(ra.scroller.draggable=!1);r.state.draggingText=!1;Q(ra.wrapper.ownerDocument,"mouseup",Qa);Q(ra.wrapper.ownerDocument,"mousemove",Pa);Q(ra.scroller,"dragstart",fb);Q(ra.scroller,"drop",Qa);Ga||(ua(Jb),ea.addNew||Yg(r.doc,ka,null,null,ea.extend),Jg&&!vk||Uf&&9==af?setTimeout(function(){ra.wrapper.ownerDocument.body.focus({preventScroll:!0});ra.input.focus()},20):ra.input.focus())}),Pa=function(Jb){Ga=Ga||10<=Math.abs(I.clientX-Jb.clientX)+Math.abs(I.clientY- Jb.clientY)},fb=function(){return Ga=!0};Jg&&(ra.scroller.draggable=!0);r.state.draggingText=Qa;Qa.copy=!ea.moveOnDrag;ra.scroller.dragDrop&&ra.scroller.dragDrop();Ne(ra.wrapper.ownerDocument,"mouseup",Qa);Ne(ra.wrapper.ownerDocument,"mousemove",Pa);Ne(ra.scroller,"dragstart",fb);Ne(ra.scroller,"drop",Qa);Ni(r);setTimeout(function(){return ra.input.focus()},20)}function lh(r,I,ka){if("char"==ka)return new zf(I,I);if("word"==ka)return r.findWordAt(I);if("line"==ka)return new zf(ib(I.line,0),Ub(r.doc, ib(I.line+1,0)));r=ka(r,I);return new zf(r.from,r.to)}function Li(r,I,ka,ea){function ra(Le){if(0!=La(pc,Le))if(pc=Le,"rectangle"==ea.unit){var Hf=[],Ag=r.options.tabSize,Gg=e(Fb(fb,ka.line).text,ka.ch,Ag),rg=e(Fb(fb,Le.line).text,Le.ch,Ag),Ke=Math.min(Gg,rg);Gg=Math.max(Gg,rg);rg=Math.min(ka.line,Le.line);for(var ig=Math.min(r.lastLine(),Math.max(ka.line,Le.line));rg<=ig;rg++){var Xf=Fb(fb,rg).text,bg=w(Xf,Ke,Ag);Ke==Gg?Hf.push(new zf(ib(rg,bg),ib(rg,bg))):Xf.length>bg&&Hf.push(new zf(ib(rg,bg), ib(rg,w(Xf,Gg,Ag))))}Hf.length||Hf.push(new zf(ka,ka));Ze(fb,Cg(r,Jb.ranges.slice(0,Ac).concat(Hf),Ac),{origin:"*mouse",scroll:!1});r.scrollIntoView(Le)}else Hf=Cc,Ke=lh(r,Le,ea.unit),Le=Hf.anchor,0=Gg.to||Ag.lineld.bottom?20:0;rg&&setTimeout(Pe(r,function(){be==Hf&&(Pa.scroller.scrollTop+=rg,Ga(Le))}),50)}}function Qa(Le){r.state.selectingText=!1;be=Infinity;Le&&(ua(Le),Pa.input.focus());Q(Pa.wrapper.ownerDocument,"mousemove",df);Q(Pa.wrapper.ownerDocument,"mouseup",Eh);fb.history.lastSelOrigin=null}var Pa=r.display,fb=r.doc;ua(I);var Jb=fb.sel,Kb=Jb.ranges;if(ea.addNew&&!ea.extend){var Ac= fb.sel.contains(ka);var Cc=-1Ga:0=Math.floor(r.display.gutters.getBoundingClientRect().right))return!1;ea&&ua(I);ea=r.display;var Qa=ea.lineDiv.getBoundingClientRect();if(Ga>Qa.bottom||!J(r,ka))return oa(I);Ga-=Qa.top-ea.viewOffset;for(Qa=0;Qa=ra)return ra=Zb(r.doc,Ga),V(r,ka,r,ra,r.display.gutterSpecs[Qa].className,I),oa(I)}}function Ue(r,I){var ka;(ka=Ic(r.display,I))||(ka=J(r,"gutterContextMenu")? Oh(r,I,"gutterContextMenu",!1):!1);if(!ka&&!L(r,I,"contextmenu")&&!Nk)r.display.input.onContextMenu(I)}function Ph(r){r.display.wrapper.className=r.display.wrapper.className.replace(/\s*cm-s-\S+/g,"")+r.options.theme.replace(/(^|\s)\s*/g," cm-s-");xc(r)}function Jj(r,I,ka){!I!=!(ka&&ka!=sh)&&(ka=r.display.dragFunctions,I=I?Ne:Q,I(r.display.scroller,"dragstart",ka.start),I(r.display.scroller,"dragenter",ka.enter),I(r.display.scroller,"dragover",ka.over),I(r.display.scroller,"dragleave",ka.leave),I(r.display.scroller, "drop",ka.drop))}function yl(r){r.options.lineWrapping?(p(r.display.wrapper,"CodeMirror-wrap"),r.display.sizer.style.minWidth="",r.display.sizerWidth=null):(Ch(r.display.wrapper,"CodeMirror-wrap"),wb(r));Ge(r);qe(r);xc(r);setTimeout(function(){return Yj(r)},100)}function ke(r,I){var ka=this;if(!(this instanceof ke))return new ke(r,I);this.options=I=I?m(I):{};m(Zg,I,!1);var ea=I.value;"string"==typeof ea?ea=new fe(ea,I.mode,null,I.lineSeparator,I.direction):I.mode&&(ea.modeOption=I.mode);this.doc= ea;var ra=new ke.inputStyles[I.inputStyle](this);r=this.display=new Pm(r,ea,ra,I);r.wrapper.CodeMirror=this;Ph(this);I.lineWrapping&&(this.display.wrapper.className+=" CodeMirror-wrap");lj(this);this.state={keyMaps:[],overlays:[],modeGen:0,overwrite:!1,delayingBlurEvent:!1,focused:!1,suppressEdits:!1,pasteIncoming:-1,cutIncoming:-1,selectingText:!1,draggingText:!1,highlight:new eg,keySeq:null,specialChars:null};I.autofocus&&!lk&&r.input.focus();Uf&&11>af&&setTimeout(function(){return ka.display.input.reset(!0)}, 20);cf(this);fg||(Vl(),fg=!0);$i(this);this.curOp.forceUpdate=!0;Ji(this,ea);I.autofocus&&!lk||this.hasFocus()?setTimeout(function(){ka.hasFocus()&&!ka.state.focused&&Qe(ka)},20):Dk(this);for(var Ga in wh)if(wh.hasOwnProperty(Ga))wh[Ga](this,I[Ga],sh);Gk(this);I.finishInit&&I.finishInit(this);for(ea=0;eaaf?Ne(ea.scroller,"dblclick",Pe(r,function(Pa){if(!L(r,Pa)){var fb=he(r,Pa);!fb||Oh(r,Pa,"gutterClick",!0)||Ic(r.display,Pa)||(ua(Pa),Pa=r.findWordAt(fb),Yg(r.doc,Pa.anchor,Pa.head))}})):Ne(ea.scroller,"dblclick",function(Pa){return L(r, Pa)||ua(Pa)});Ne(ea.scroller,"contextmenu",function(Pa){return Ue(r,Pa)});Ne(ea.input.getField(),"contextmenu",function(Pa){ea.scroller.contains(Pa.target)||Ue(r,Pa)});var ra,Ga={end:0};Ne(ea.scroller,"touchstart",function(Pa){var fb;if(fb=!L(r,Pa))1!=Pa.touches.length?fb=!1:(fb=Pa.touches[0],fb=1>=fb.radiusX&&1>=fb.radiusY),fb=!fb;fb&&!Oh(r,Pa,"gutterClick",!0)&&(ea.input.ensurePolled(),clearTimeout(ra),fb=+new Date,ea.activeTouch={start:fb,moved:!1,prev:300>=fb-Ga.end?Ga:null},1==Pa.touches.length&& (ea.activeTouch.left=Pa.touches[0].pageX,ea.activeTouch.top=Pa.touches[0].pageY))});Ne(ea.scroller,"touchmove",function(){ea.activeTouch&&(ea.activeTouch.moved=!0)});Ne(ea.scroller,"touchend",function(Pa){var fb=ea.activeTouch;if(fb&&!Ic(ea,Pa)&&null!=fb.left&&!fb.moved&&300>new Date-fb.start){var Jb=r.coordsChar(ea.activeTouch,"page");fb=!fb.prev||ka(fb,fb.prev)?new zf(Jb,Jb):!fb.prev.prev||ka(fb,fb.prev.prev)?r.findWordAt(Jb):new zf(ib(Jb.line,0),Ub(r.doc,ib(Jb.line+1,0)));r.setSelection(fb.anchor, fb.head);r.focus();ua(Pa)}I()});Ne(ea.scroller,"touchcancel",I);Ne(ea.scroller,"scroll",function(){ea.scroller.clientHeight&&(Wj(r,ea.scroller.scrollTop),Zi(r,ea.scroller.scrollLeft,!0),V(r,"scroll",r))});Ne(ea.scroller,"mousewheel",function(Pa){return bk(r,Pa)});Ne(ea.scroller,"DOMMouseScroll",function(Pa){return bk(r,Pa)});Ne(ea.wrapper,"scroll",function(){return ea.wrapper.scrollTop=ea.wrapper.scrollLeft=0});ea.dragFunctions={enter:function(Pa){L(r,Pa)||ta(Pa)},over:function(Pa){if(!L(r,Pa)){var fb= he(r,Pa);if(fb){var Jb=document.createDocumentFragment();ph(r,fb,Jb);r.display.dragCursor||(r.display.dragCursor=k("div",null,"CodeMirror-cursors CodeMirror-dragcursors"),r.display.lineSpace.insertBefore(r.display.dragCursor,r.display.cursorDiv));n(r.display.dragCursor,Jb)}ta(Pa)}},start:function(Pa){if(Uf&&(!r.state.draggingText||100>+new Date-ok))ta(Pa);else if(!L(r,Pa)&&!Ic(r.display,Pa)&&(Pa.dataTransfer.setData("Text",r.getSelection()),Pa.dataTransfer.effectAllowed="copyMove",Pa.dataTransfer.setDragImage&& !vk)){var fb=k("img",null,null,"position: fixed; left: 0; top: 0;");fb.src="data:image/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw\x3d\x3d";vh&&(fb.width=fb.height=1,r.display.wrapper.appendChild(fb),fb._top=fb.offsetTop);Pa.dataTransfer.setDragImage(fb,0,0);vh&&fb.parentNode.removeChild(fb)}},drop:Pe(r,Dj),leave:function(Pa){L(r,Pa)||mm(r)}};var Qa=ea.input.getField();Ne(Qa,"keyup",function(Pa){return Sl.call(r,Pa)});Ne(Qa,"keydown",Pe(r,Gm));Ne(Qa,"keypress",Pe(r,Xl));Ne(Qa,"focus", function(Pa){return Qe(r,Pa)});Ne(Qa,"blur",function(Pa){return Dk(r,Pa)})}function vg(r,I,ka,ea){var ra=r.doc,Ga;null==ka&&(ka="add");"smart"==ka&&(ra.mode.indent?Ga=Mc(r,I).state:ka="prev");var Qa=r.options.tabSize,Pa=Fb(ra,I),fb=e(Pa.text,null,Qa);Pa.stateAfter&&(Pa.stateAfter=null);var Jb=Pa.text.match(/^\s*/)[0];if(!ea&&!/\S/.test(Pa.text)){var Kb=0;ka="not"}else if("smart"==ka&&(Kb=ra.mode.indent(Ga,Pa.text.slice(Jb.length),Pa.text),Kb==Uk||150ra.first? e(Fb(ra,I-1).text,null,Qa):0:"add"==ka?Kb=fb+r.options.indentUnit:"subtract"==ka?Kb=fb-r.options.indentUnit:"number"==typeof ka&&(Kb=fb+ka);Kb=Math.max(0,Kb);ka="";ea=0;if(r.options.indentWithTabs)for(r=Math.floor(Kb/Qa);r;--r)ea+=Qa,ka+="\t";eaQa,fb=ij(I),Jb=null;if(Pa&&1Qa?"cut":"+input")};Vf(r.doc,Cc);Ae(r,"inputRead",r,Cc)}I&&!Pa&&Rj(r,I);sg(r);2>r.curOp.updateInput&&(r.curOp.updateInput=Kb);r.curOp.typing=!0;r.state.pasteIncoming=r.state.cutIncoming= -1}function mk(r,I){var ka=r.clipboardData&&r.clipboardData.getData("Text");if(ka)return r.preventDefault(),I.isReadOnly()||I.options.disableInput||Wd(I,function(){return Kj(I,ka,0,null,"paste")}),!0}function Rj(r,I){if(r.options.electricChars&&r.options.smartIndent)for(var ka=r.doc.sel,ea=ka.ranges.length-1;0<=ea;ea--){var ra=ka.ranges[ea];if(!(100df?2:1))),-ka)}else df=ra?Ri(r.cm,fb,I,ka):Hj(fb,I,ka);if(null==df){if(be=!be)be=I.line+Jb,be=r.first+r.size?be=!1:(I=new ib(be,I.ch,I.sticky),be=fb=Fb(r,be));if(be)I=kk(ra,r.cm,fb,I.line,Jb);else return!1}else I=df;return!0}var Qa=I,Pa=ka,fb=Fb(r,I.line),Jb=ra&&"rtl"==r.direction?-ka:ka;if("char"==ea||"codepoint"==ea)Ga();else if("column"==ea)Ga(!0);else if("word"==ea||"group"== ea)for(var Kb=null,Ac="group"==ea,Cc=r.cm&&r.cm.getHelper(I,"wordChars"),pc=!0;!(0>ka)||Ga(!pc);pc=!1){var ld=fb.text.charAt(I.ch)||"\n";ld=T(ld,Cc)?"w":Ac&&"\n"==ld?"n":!Ac||/\s/.test(ld)?null:"p";!Ac||pc||ld||(ld="s");if(Kb&&Kb!=ld){0>ka&&(ka=1,Ga(),I.sticky="after");break}ld&&(Kb=ld);if(0ka?0>=Qa:Qa>=ra.height){I.hitSide=!0;break}Qa+=5*ka}return I}function gj(r,I){var ka=jg(r,I.line);if(!ka||ka.hidden)return null;var ea=Fb(r.doc,I.line);ka=Rd(ka,ea,I.line);r=X(ea,r.doc.direction);ea="left";r&&(ea=O(r,I.ch)%2?"right":"left");I=Wa(ka.map,I.ch,ea);I.offset="right"==I.collapse?I.end:I.start;return I}function xm(r){for(;r;r= r.parentNode)if(/CodeMirror-gutter-wrapper/.test(r.className))return!0;return!1}function xf(r,I){I&&(r.bad=!0);return r}function kl(r,I,ka,ea,ra){function Ga(pc){return function(ld){return ld.id==pc}}function Qa(){Kb&&(Jb+=Ac,Cc&&(Jb+=Ac),Kb=Cc=!1)}function Pa(pc){pc&&(Qa(),Jb+=pc)}function fb(pc){if(1==pc.nodeType){var ld=pc.getAttribute("cm-text");if(ld)Pa(ld);else{ld=pc.getAttribute("cm-marker");var be;if(ld)pc=r.findMarks(ib(ea,0),ib(ra+1,0),Ga(+ld)),pc.length&&(be=pc[0].find(0))&&Pa(Sb(r.doc, be.from,be.to).join(Ac));else if("false"!=pc.getAttribute("contenteditable")&&(be=/^(pre|div|p|li|table|br)$/i.test(pc.nodeName),/^br$/i.test(pc.nodeName)||0!=pc.textContent.length)){be&&Qa();for(ld=0;ldpc?fb.map:Jb[pc],be=0;bepc?r.line:r.rest[pc]);pc=ld[be]+Cc;if(0>Cc||df!=Kb)pc=ld[be+(Cc?1:0)];return ib(Ac,pc)}}}var ra=r.text.firstChild,Ga=!1;if(!I||!f(ra,I))return xf(ib(ec(r.line),0),!0);if(I==ra&&(Ga=!0,I=ra.childNodes[ka],ka=0,!I))return ka=r.rest?E(r.rest):r.line,xf(ib(ec(ka),ka.text.length),Ga);var Qa=3==I.nodeType?I:null,Pa=I;Qa||1!=I.childNodes.length||3!=I.firstChild.nodeType||(Qa=I.firstChild,ka&&(ka=Qa.nodeValue.length));for(;Pa.parentNode!=ra;)Pa=Pa.parentNode; var fb=r.measure,Jb=fb.maps;if(I=ea(Qa,Pa,ka))return xf(I,Ga);ra=Pa.nextSibling;for(Qa=Qa?Qa.nodeValue.length-ka:0;ra;ra=ra.nextSibling){if(I=ea(ra,ra.firstChild,0))return xf(ib(I.line,I.ch-Qa),Ga);Qa+=ra.textContent.length}for(Pa=Pa.previousSibling;Pa;Pa=Pa.previousSibling){if(I=ea(Pa,Pa.firstChild,-1))return xf(ib(I.line,I.ch+ka),Ga);ka+=Pa.textContent.length}}var Wf=navigator.userAgent,Xj=navigator.platform,Qh=/gecko\/\d/i.test(Wf),sj=/MSIE \d/.test(Wf),Nm=/Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(Wf), Qj=/Edge\/(\d+)/.exec(Wf),Uf=sj||Nm||Qj,af=Uf&&(sj?document.documentMode||6:+(Qj||Nm)[1]),Jg=!Qj&&/WebKit\//.test(Wf),Tk=Jg&&/Qt\/\d+\.\d+/.test(Wf),uh=!Qj&&/Chrome\//.test(Wf),vh=/Opera\//.test(Wf),vk=/Apple Computer/.test(navigator.vendor),ll=/Mac OS X 1\d\D([8-9]|\d\d)\D/.test(Wf),Vg=/PhantomJS/.test(Wf),Ki=!Qj&&/AppleWebKit/.test(Wf)&&/Mobile\/\w+/.test(Wf),ai=/Android/.test(Wf),lk=Ki||ai||/webOS|BlackBerry|Opera Mini|Opera Mobi|IEMobile/i.test(Wf),Lf=Ki||/Mac/.test(Xj),yf=/\bCrOS\b/.test(Wf), Di=/win/i.test(Xj),th=vh&&Wf.match(/Version\/(\d*\.\d*)/);th&&(th=Number(th[1]));th&&15<=th&&(vh=!1,Jg=!0);var Zh=Lf&&(Tk||vh&&(null==th||12.11>th)),Nk=Qh||Uf&&9<=af,Ch=function(r,I){var ka=r.className;if(I=l(I).exec(ka)){var ea=ka.slice(I.index+I[0].length);r.className=ka.slice(0,I.index)+(ea?I[1]+ea:"")}};var Xi=document.createRange?function(r,I,ka,ea){var ra=document.createRange();ra.setEnd(ea||r,ka);ra.setStart(r,I);return ra}:function(r,I,ka){var ea=document.body.createTextRange();try{ea.moveToElementText(r.parentNode)}catch(ra){return ea}ea.collapse(!0); ea.moveEnd("character",ka);ea.moveStart("character",I);return ea};var Ok=function(r){r.select()};Ki?Ok=function(r){r.selectionStart=0;r.selectionEnd=r.value.length}:Uf&&(Ok=function(r){try{r.select()}catch(I){}});var eg=function(){this.f=this.id=null;this.time=0;this.handler=u(this.onTimeout,this)};eg.prototype.onTimeout=function(r){r.id=0;r.time<=+new Date?r.f():setTimeout(r.handler,r.time-+new Date)};eg.prototype.set=function(r,I){this.f=I;I=+new Date+r;if(!this.id||I=ld?"bbbbbbbbbtstwsbbbbbbbbbbbbbbssstwNN%%%NNNNNN,N,N1111111111NNNNNNNLLLLLLLLLLLLLLLLLLLLLLLLLLNNNNNNLLLLLLLLLLLLLLLLLLLLLLLLLLNNNNbbbbbbsbbbbbbbbbbbbbbbbbbbbbbbbbb,N%%%%NNNNLNNNNN%%11NLNNN1LNNNNNLLLLLLLLLLLLLLLLLLLLLLLNLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLN".charAt(ld): 1424<=ld&&1524>=ld?"R":1536<=ld&&1785>=ld?"nnnnnnNNr%%r,rNNmmmmmmmmmmmrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrmmmmmmmmmmmmmmmmmmmmmnnnnnnnnnn%nnrrrmrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrmmmmmmmnNmmmmmmrrmmNmmmmrr1111111111".charAt(ld-1536):1774<=ld&&2220>=ld?"r":8192<=ld&&8203>=ld?"w":8204==ld?"b":"L";pc.call(Cc,ld)}Ac=0;for(Cc=fb;Acaf)return!1; var r=k("div");return"draggable"in r||"dragDrop"in r}(),fm,uj,ij=3!="\n\nb".split(/\n/).length?function(r){for(var I=0,ka=[],ea=r.length;I<=ea;){var ra=r.indexOf("\n",I);-1==ra&&(ra=r.length);var Ga=r.slice(I,"\r"==r.charAt(ra-1)?ra-1:ra),Qa=Ga.indexOf("\r");-1!=Qa?(ka.push(Ga.slice(0,Qa)),I+=Qa+1):(ka.push(Ga),I=ra+1)}return ka}:function(r){return r.split(/\r\n?|\n/)},Sh=window.getSelection?function(r){try{return r.selectionStart!=r.selectionEnd}catch(I){return!1}}:function(r){try{var I=r.ownerDocument.selection.createRange()}catch(ka){}return I&& I.parentElement()==r?0!=I.compareEndPoints("StartToEnd",I):!1},Hh=function(){var r=k("div");if("oncopy"in r)return!0;r.setAttribute("oncopy","return;");return"function"==typeof r.oncopy}(),wi=null,tj={},yk={},Sj={},fh=function(r,I,ka){this.pos=this.start=0;this.string=r;this.tabSize=I||8;this.lineStart=this.lastColumnPos=this.lastColumnValue=0;this.lineOracle=ka};fh.prototype.eol=function(){return this.pos>=this.string.length};fh.prototype.sol=function(){return this.pos==this.lineStart};fh.prototype.peek= function(){return this.string.charAt(this.pos)||void 0};fh.prototype.next=function(){if(this.posI};fh.prototype.eatSpace=function(){for(var r=this.pos;/[\s\u00a0]/.test(this.string.charAt(this.pos));)++this.pos;return this.pos> r};fh.prototype.skipToEnd=function(){this.pos=this.string.length};fh.prototype.skipTo=function(r){r=this.string.indexOf(r,this.pos);if(-1this.maxLookAhead&&(this.maxLookAhead=r);return I};id.prototype.baseToken=function(r){if(!this.baseTokens)return null;for(;this.baseTokens[this.baseTokenPos]<=r;)this.baseTokenPos+=2;var I=this.baseTokens[this.baseTokenPos+1];return{type:I&&I.replace(/( |^)overlay .*/,""),size:this.baseTokens[this.baseTokenPos]-r}};id.prototype.nextLine=function(){this.line++;0af&&(this.horiz.style.minHeight=this.vert.style.minWidth= "18px")};hg.prototype.update=function(r){var I=r.scrollWidth>r.clientWidth+1,ka=r.scrollHeight>r.clientHeight+1,ea=r.nativeBarWidth;ka?(this.vert.style.display="block",this.vert.style.bottom=I?ea+"px":"0",this.vert.firstChild.style.height=Math.max(0,r.scrollHeight-r.clientHeight+(r.viewHeight-(I?ea:0)))+"px"):(this.vert.style.display="",this.vert.firstChild.style.height="0");I?(this.horiz.style.display="block",this.horiz.style.right=ka?ea+"px":"0",this.horiz.style.left=r.barLeft+"px",this.horiz.firstChild.style.width= Math.max(0,r.scrollWidth-r.clientWidth+(r.viewWidth-r.barLeft-(ka?ea:0)))+"px"):(this.horiz.style.display="",this.horiz.firstChild.style.width="0");!this.checkedZeroWidth&&0=La(r,ea.to()))return ka}return-1};var zf=function(r,I){this.anchor=r;this.head=I};zf.prototype.from=function(){return Yb(this.anchor,this.head)};zf.prototype.to=function(){return lb(this.anchor,this.head)};zf.prototype.empty=function(){return this.head.line== this.anchor.line&&this.head.ch==this.anchor.ch};ri.prototype={chunkSize:function(){return this.lines.length},removeInner:function(r,I){for(var ka=r,ea=r+I;kathis.size-I&&(1=this.children.length)){var r=this;do{var I=r.children.splice(r.children.length-5,5);I=new rh(I);if(r.parent){r.size-=I.size;r.height-=I.height;var ka=q(r.parent.children,r);r.parent.children.splice(ka+1,0,I)}else ka=new rh(r.children),ka.parent=r,r.children=[ka,I],r=ka;I.parent=r.parent}while(10r.display.maxLineLength&&(r.display.maxLine=Ga,r.display.maxLineLength=Qa,r.display.maxLineChanged=!0);null!=ka&&r&&this.collapsed&&qe(r,ka,ea+1);this.lines.length=0;this.explicitlyCleared=!0;this.atomic&&this.doc.cantEdit&&(this.doc.cantEdit=!1,r&&qi(r.doc));r&&Ae(r,"markerCleared",r,this,ka, ea);I&&Zj(r);this.parent&&this.parent.clear()}};pe.prototype.find=function(r,I){null==r&&"bookmark"==this.type&&(r=1);for(var ka,ea,ra=0;raLa(Pa.head,Pa.anchor),r[Ga]=new zf(Pa?fb:Qa,Pa?Qa:fb)):r[Ga]=new zf(Qa,Qa)}r=new de(r,this.sel.primIndex)}I=r;for(r=ea.length-1;0<=r;r--)Vf(this,ea[r]);I?Xg(this,I):this.cm&&sg(this.cm)}),undo:qh(function(){Mh(this,"undo")}),redo:qh(function(){Mh(this,"redo")}),undoSelection:qh(function(){Mh(this,"undo",!0)}),redoSelection:qh(function(){Mh(this,"redo",!0)}),setExtending:function(r){this.extend= r},getExtending:function(){return this.extend},historySize:function(){for(var r=this.history,I=0,ka=0,ea=0;ea=r.ch)&&I.push(ra.marker.parent||ra.marker)}return I},findMarks:function(r,I,ka){r=Ub(this,r);I=Ub(this,I);var ea=[],ra=r.line;this.iter(r.line,I.line+1,function(Ga){if(Ga=Ga.markedSpans)for(var Qa= 0;Qa=Pa.to||null==Pa.from&&ra!=r.line||null!=Pa.from&&ra==I.line&&Pa.from>=I.ch||ka&&!ka(Pa.marker)||ea.push(Pa.marker.parent||Pa.marker)}++ra});return ea},getAllMarks:function(){var r=[];this.iter(function(I){if(I=I.markedSpans)for(var ka=0;kar)return I= r,!0;r-=ra;++ka});return Ub(this,ib(ka,I))},indexFromPos:function(r){r=Ub(this,r);var I=r.ch;if(r.liner.ch)return 0;var ka=this.lineSeparator().length;this.iter(this.first,r.line,function(ea){I+=ea.text.length+ka});return I},copy:function(r){var I=new fe(hc(this,this.first,this.first+this.size),this.modeOption,this.first,this.lineSep,this.direction);I.scrollTop=this.scrollTop;I.scrollLeft=this.scrollLeft;I.sel=this.sel;I.extend=!1;r&&(I.history.undoDepth=this.history.undoDepth,I.setHistory(this.getHistory())); return I},linkedDoc:function(r){r||(r={});var I=this.first,ka=this.first+this.size;null!=r.from&&r.from>I&&(I=r.from);null!=r.to&&r.toHm;Hm++)Gi[Hm+48]=Gi[Hm+96]=String(Hm);for(var Ck=65;90>=Ck;Ck++)Gi[Ck]=String.fromCharCode(Ck);for(var Pk=1;12>=Pk;Pk++)Gi[Pk+111]=Gi[Pk+63235]="F"+Pk;var Bk={basic:{Left:"goCharLeft",Right:"goCharRight",Up:"goLineUp",Down:"goLineDown",End:"goLineEnd",Home:"goLineStartSmart",PageUp:"goPageUp",PageDown:"goPageDown",Delete:"delCharAfter",Backspace:"delCharBefore","Shift-Backspace":"delCharBefore",Tab:"defaultTab","Shift-Tab":"indentAuto",Enter:"newlineAndIndent",Insert:"toggleOverwrite",Esc:"singleSelection"}, pcDefault:{"Ctrl-A":"selectAll","Ctrl-D":"deleteLine","Ctrl-Z":"undo","Shift-Ctrl-Z":"redo","Ctrl-Y":"redo","Ctrl-Home":"goDocStart","Ctrl-End":"goDocEnd","Ctrl-Up":"goLineUp","Ctrl-Down":"goLineDown","Ctrl-Left":"goGroupLeft","Ctrl-Right":"goGroupRight","Alt-Left":"goLineStart","Alt-Right":"goLineEnd","Ctrl-Backspace":"delGroupBefore","Ctrl-Delete":"delGroupAfter","Ctrl-S":"save","Ctrl-F":"find","Ctrl-G":"findNext","Shift-Ctrl-G":"findPrev","Shift-Ctrl-F":"replace","Shift-Ctrl-R":"replaceAll","Ctrl-[":"indentLess", "Ctrl-]":"indentMore","Ctrl-U":"undoSelection","Shift-Ctrl-U":"redoSelection","Alt-U":"redoSelection",fallthrough:"basic"},emacsy:{"Ctrl-F":"goCharRight","Ctrl-B":"goCharLeft","Ctrl-P":"goLineUp","Ctrl-N":"goLineDown","Alt-F":"goWordRight","Alt-B":"goWordLeft","Ctrl-A":"goLineStart","Ctrl-E":"goLineEnd","Ctrl-V":"goPageDown","Shift-Ctrl-V":"goPageUp","Ctrl-D":"delCharAfter","Ctrl-H":"delCharBefore","Alt-D":"delWordAfter","Alt-Backspace":"delWordBefore","Ctrl-K":"killLine","Ctrl-T":"transposeChars", "Ctrl-O":"openLine"},macDefault:{"Cmd-A":"selectAll","Cmd-D":"deleteLine","Cmd-Z":"undo","Shift-Cmd-Z":"redo","Cmd-Y":"redo","Cmd-Home":"goDocStart","Cmd-Up":"goDocStart","Cmd-End":"goDocEnd","Cmd-Down":"goDocEnd","Alt-Left":"goGroupLeft","Alt-Right":"goGroupRight","Cmd-Left":"goLineLeft","Cmd-Right":"goLineRight","Alt-Backspace":"delGroupBefore","Ctrl-Alt-Backspace":"delGroupAfter","Alt-Delete":"delGroupAfter","Cmd-S":"save","Cmd-F":"find","Cmd-G":"findNext","Shift-Cmd-G":"findPrev","Cmd-Alt-F":"replace", "Shift-Cmd-Alt-F":"replaceAll","Cmd-[":"indentLess","Cmd-]":"indentMore","Cmd-Backspace":"delWrappedLineLeft","Cmd-Delete":"delWrappedLineRight","Cmd-U":"undoSelection","Shift-Cmd-U":"redoSelection","Ctrl-Up":"goDocStart","Ctrl-Down":"goDocEnd",fallthrough:["basic","emacsy"]}};Bk["default"]=Lf?Bk.macDefault:Bk.pcDefault;var Lj={selectAll:Dh,singleSelection:function(r){return r.setSelection(r.getCursor("anchor"),r.getCursor("head"),Rh)},killLine:function(r){return Gj(r,function(I){if(I.empty()){var ka= Fb(r.doc,I.head.line).text.length;return I.head.ch==ka&&I.head.liner.doc.first){var Qa=Fb(r.doc,ra.line-1).text;Qa&&(ra=new ib(ra.line,1),r.replaceRange(Ga.charAt(0)+r.doc.lineSeparator()+Qa.charAt(Qa.length-1),ib(ra.line-1,Qa.length-1),ra,"+transpose"))}ka.push(new zf(ra,ra))}r.setSelections(ka)})}, newlineAndIndent:function(r){return Wd(r,function(){for(var I=r.listSelections(),ka=I.length-1;0<=ka;ka--)r.replaceRange(r.doc.lineSeparator(),I[ka].anchor,I[ka].head,"+input");I=r.listSelections();for(ka=0;kar&&0==La(I,this.pos)&&ka==this.button};var oe,Ml,sh={toString:function(){return"CodeMirror.Init"}},Zg={},wh={};ke.defaults=Zg;ke.optionHandlers=wh;var Sf=[];ke.defineInitHook=function(r){return Sf.push(r)};var Kh=null,Be=function(r){this.cm=r;this.lastAnchorNode=this.lastAnchorOffset=this.lastFocusNode=this.lastFocusOffset=null;this.polling=new eg;this.composing=null;this.gracePeriod=!1;this.readDOMTimeout=null};Be.prototype.init=function(r){function I(Pa){for(Pa=Pa.target;Pa;Pa= Pa.parentNode){if(Pa==Qa)return!0;if(/\bCodeMirror-(?:line)?widget\b/.test(Pa.className))break}return!1}function ka(Pa){if(I(Pa)&&!L(Ga,Pa)){if(Ga.somethingSelected())Kh={lineWise:!1,text:Ga.getSelections()},"cut"==Pa.type&&Ga.replaceSelection("",null,"cut");else if(Ga.options.lineWiseCopyCut){var fb=Qf(Ga);Kh={lineWise:!0,text:fb.text};"cut"==Pa.type&&Ga.operation(function(){Ga.setSelections(fb.ranges,0,Rh);Ga.replaceSelection("",null,"cut")})}else return;if(Pa.clipboardData){Pa.clipboardData.clearData(); var Jb=Kh.text.join("\n");Pa.clipboardData.setData("Text",Jb);if(Pa.clipboardData.getData("Text")==Jb){Pa.preventDefault();return}}var Kb=vi();Pa=Kb.firstChild;Ga.display.lineSpace.insertBefore(Kb,Ga.display.lineSpace.firstChild);Pa.value=Kh.text.join("\n");var Ac=document.activeElement;Ok(Pa);setTimeout(function(){Ga.display.lineSpace.removeChild(Kb);Ac.focus();Ac==Qa&&ra.showPrimarySelection()},50)}}var ea=this,ra=this,Ga=ra.cm,Qa=ra.div=r.lineDiv;dh(Qa,Ga.options.spellcheck,Ga.options.autocorrect, Ga.options.autocapitalize);Ne(Qa,"paste",function(Pa){!I(Pa)||L(Ga,Pa)||mk(Pa,Ga)||11>=af&&setTimeout(Pe(Ga,function(){return ea.updateFromDOM()}),20)});Ne(Qa,"compositionstart",function(Pa){ea.composing={data:Pa.data,done:!1}});Ne(Qa,"compositionupdate",function(Pa){ea.composing||(ea.composing={data:Pa.data,done:!1})});Ne(Qa,"compositionend",function(Pa){ea.composing&&(Pa.data!=ea.composing.data&&ea.readFromDOMSoon(),ea.composing.done=!0)});Ne(Qa,"touchstart",function(){return ra.forceCompositionEnd()}); Ne(Qa,"input",function(){ea.composing||ea.readFromDOMSoon()});Ne(Qa,"copy",ka);Ne(Qa,"cut",ka)};Be.prototype.screenReaderLabelChanged=function(r){r?this.div.setAttribute("aria-label",r):this.div.removeAttribute("aria-label")};Be.prototype.prepareSelection=function(){var r=Ye(this.cm,!1);r.focus=document.activeElement==this.div;return r};Be.prototype.showSelection=function(r,I){r&&this.cm.display.view.length&&((r.focus||I)&&this.showPrimarySelection(),this.showMultipleSelections(r))};Be.prototype.getSelection= function(){return this.cm.display.wrapper.ownerDocument.getSelection()};Be.prototype.showPrimarySelection=function(){var r=this.getSelection(),I=this.cm,ka=I.doc.sel.primary(),ea=ka.from();ka=ka.to();if(I.display.viewTo==I.display.viewFrom||ea.line>=I.display.viewTo||ka.line=I.display.viewFrom&& gj(I,ea)||{node:ra[0].measure.map[2],offset:0},ka=ka.liner.firstLine()&&(ea=ib(ea.line-1,Fb(r.doc,ea.line-1).length));ra.ch==Fb(r.doc,ra.line).text.length&&ra.lineI.viewTo-1)return!1;var Ga;ea.line==I.viewFrom||0==(Ga=je(r,ea.line))?(ka=ec(I.view[0].line),Ga=I.view[0].node):(ka=ec(I.view[Ga].line),Ga=I.view[Ga-1].node.nextSibling);var Qa=je(r,ra.line);Qa==I.view.length-1?(ra=I.viewTo-1,I=I.lineDiv.lastChild):(ra=ec(I.view[Qa+1].line)-1,I=I.view[Qa+1].node.previousSibling);if(!Ga)return!1;I=r.doc.splitLines(kl(r,Ga,I,ka,ra));for(Ga=Sb(r.doc,ib(ka,0),ib(ra,Fb(r.doc,ra).text.length));1ea.ch&&fb.charCodeAt(fb.length-Qa-1)==Jb.charCodeAt(Jb.length-Qa-1);)Pa--, Qa++;I[I.length-1]=fb.slice(0,fb.length-Qa).replace(/^\u200b+/,"");I[0]=I[0].slice(Pa).replace(/\u200b+$/,"");ea=ib(ka,Pa);ka=ib(ra,Ga.length?E(Ga).length-Qa:0);if(1af&&Ga.scrollbars.setScrollTop(Ga.scroller.scrollTop=fb),null!=Qa.selectionStart)){(!Uf||Uf&&9>af)&&I();var pc=0,ld=function(){Ga.selForContextMenu==ra.doc.sel&&0==Qa.selectionStart&&0pc++?Ga.detectingSelectAll=setTimeout(ld,500):(Ga.selForContextMenu=null,Ga.input.reset())};Ga.detectingSelectAll= setTimeout(ld,200)}}var ea=this,ra=ea.cm,Ga=ra.display,Qa=ea.textarea;ea.contextMenuPending&&ea.contextMenuPending();var Pa=he(ra,r),fb=Ga.scroller.scrollTop;if(Pa&&!vh){ra.options.resetSelectionOnContextMenu&&-1==ra.doc.sel.contains(Pa)&&Pe(ra,Ze)(ra.doc,zh(Pa),Rh);var Jb=Qa.style.cssText,Kb=ea.wrapper.style.cssText;Pa=ea.wrapper.offsetParent.getBoundingClientRect();ea.wrapper.style.cssText="position: static";Qa.style.cssText="position: absolute; width: 30px; height: 30px;\n top: "+(r.clientY- Pa.top-5)+"px; left: "+(r.clientX-Pa.left-5)+"px;\n z-index: 1000; background: "+(Uf?"rgba(255, 255, 255, .05)":"transparent")+";\n outline: none; border-width: 0; outline: none; overflow: hidden; opacity: .05; filter: alpha(opacity\x3d5);";if(Jg)var Ac=window.scrollY;Ga.input.focus();Jg&&window.scrollTo(null,Ac);Ga.input.reset();ra.somethingSelected()||(Qa.value=ea.prevInput=" ");ea.contextMenuPending=ka;Ga.selForContextMenu=ra.doc.sel;clearTimeout(Ga.detectingSelectAll);Uf&&9<=af&&I(); if(Nk){ta(r);var Cc=function(){Q(window,"mouseup",Cc);setTimeout(ka,20)};Ne(window,"mouseup",Cc)}else setTimeout(ka,50)}};Fg.prototype.readOnlyChanged=function(r){r||this.reset();this.textarea.disabled="nocursor"==r;this.textarea.readOnly=!!r};Fg.prototype.setUneditable=function(){};Fg.prototype.needsContentAttribute=!1;(function(r){function I(ea,ra,Ga,Qa){r.defaults[ea]=ra;Ga&&(ka[ea]=Qa?function(Pa,fb,Jb){Jb!=sh&&Ga(Pa,fb,Jb)}:Ga)}var ka=r.optionHandlers;r.defineOption=I;r.Init=sh;I("value","", function(ea,ra){return ea.setValue(ra)},!0);I("mode",null,function(ea,ra){ea.doc.modeOption=ra;Aj(ea)},!0);I("indentUnit",2,Aj,!0);I("indentWithTabs",!1);I("smartIndent",!0);I("tabSize",4,function(ea){Rl(ea);xc(ea);qe(ea)},!0);I("lineSeparator",null,function(ea,ra){if(ea.doc.lineSep=ra){var Ga=[],Qa=ea.doc.first;ea.doc.iter(function(fb){for(var Jb=0;;){var Kb=fb.text.indexOf(ra,Jb);if(-1==Kb)break;Jb=Kb+ra.length;Ga.push(ib(Qa,Kb))}Qa++});for(var Pa=Ga.length-1;0<=Pa;Pa--)Bg(ea.doc,ra,Ga[Pa],ib(Ga[Pa].line, Ga[Pa].ch+ra.length))}});I("specialChars",/[\u0000-\u001f\u007f-\u009f\u00ad\u061c\u200b-\u200c\u200e\u200f\u2028\u2029\ufeff\ufff9-\ufffc]/g,function(ea,ra,Ga){ea.state.specialChars=new RegExp(ra.source+(ra.test("\t")?"":"|\t"),"g");Ga!=sh&&ea.refresh()});I("specialCharPlaceholder",zc,function(ea){return ea.refresh()},!0);I("electricChars",!0);I("inputStyle",lk?"contenteditable":"textarea",function(){throw Error("inputStyle can not (yet) be changed in a running editor");},!0);I("spellcheck",!1,function(ea, ra){return ea.getInputField().spellcheck=ra},!0);I("autocorrect",!1,function(ea,ra){return ea.getInputField().autocorrect=ra},!0);I("autocapitalize",!1,function(ea,ra){return ea.getInputField().autocapitalize=ra},!0);I("rtlMoveVisually",!Di);I("wholeLineUpdateBefore",!0);I("theme","default",function(ea){Ph(ea);Yd(ea)},!0);I("keyMap","default",function(ea,ra,Ga){ra=hk(ra);(Ga=Ga!=sh&&hk(Ga))&&Ga.detach&&Ga.detach(ea,ra);ra.attach&&ra.attach(ea,Ga||null)});I("extraKeys",null);I("configureMouse",null); I("lineWrapping",!1,yl,!0);I("gutters",[],function(ea,ra){ea.display.gutterSpecs=ff(ra,ea.options.lineNumbers);Yd(ea)},!0);I("fixedGutter",!0,function(ea,ra){ea.display.gutters.style.left=ra?Jd(ea.display)+"px":"0";ea.refresh()},!0);I("coverGutterNextToScrollbar",!1,function(ea){return Yj(ea)},!0);I("scrollbarStyle","native",function(ea){lj(ea);Yj(ea);ea.display.scrollbars.setScrollTop(ea.doc.scrollTop);ea.display.scrollbars.setScrollLeft(ea.doc.scrollLeft)},!0);I("lineNumbers",!1,function(ea,ra){ea.display.gutterSpecs= ff(ea.options.gutters,ra);Yd(ea)},!0);I("firstLineNumber",1,Yd,!0);I("lineNumberFormatter",function(ea){return ea},Yd,!0);I("showCursorWhenSelecting",!1,Lg,!0);I("resetSelectionOnContextMenu",!0);I("lineWiseCopyCut",!0);I("pasteLinesPerSelection",!0);I("selectionsMayTouch",!1);I("readOnly",!1,function(ea,ra){"nocursor"==ra&&(Dk(ea),ea.display.input.blur());ea.display.input.readOnlyChanged(ra)});I("screenReaderLabel",null,function(ea,ra){ea.display.input.screenReaderLabelChanged(""===ra?null:ra)}); I("disableInput",!1,function(ea,ra){ra||ea.display.input.reset()},!0);I("dragDrop",!0,Jj);I("allowDropFileTypes",null);I("cursorBlinkRate",530);I("cursorScrollMargin",0);I("cursorHeight",1,Lg,!0);I("singleCursorHeightPerLine",!0,Lg,!0);I("workTime",100);I("workDelay",100);I("flattenSpans",!0,Rl,!0);I("addModeClass",!1,Rl,!0);I("pollInterval",100);I("undoDepth",200,function(ea,ra){return ea.doc.history.undoDepth=ra});I("historyEventDelay",1250);I("viewportMargin",10,function(ea){return ea.refresh()}, !0);I("maxHighlightLength",1E4,Rl,!0);I("moveInputWithCursor",!0,function(ea,ra){ra||ea.display.input.resetPosition()});I("tabindex",null,function(ea,ra){return ea.display.input.getField().tabIndex=ra||""});I("autofocus",null);I("direction","ltr",function(ea,ra){return ea.doc.setDirection(ra)},!0);I("phrases",null)})(ke);(function(r){var I=r.optionHandlers,ka=r.helpers={};r.prototype={constructor:r,focus:function(){window.focus();this.display.input.focus()},setOption:function(ea,ra){var Ga=this.options, Qa=Ga[ea];if(Ga[ea]!=ra||"mode"==ea)Ga[ea]=ra,I.hasOwnProperty(ea)&&Pe(this,I[ea])(this,ra,Qa),V(this,"optionChange",this,ea)},getOption:function(ea){return this.options[ea]},getDoc:function(){return this.doc},addKeyMap:function(ea,ra){this.state.keyMaps[ra?"push":"unshift"](hk(ea))},removeKeyMap:function(ea){for(var ra=this.state.keyMaps,Ga=0;GaGa&&(vg(this,Pa.head.line,ea,!0),Ga=Pa.head.line,Qa==this.doc.sel.primIndex&&sg(this));else{var fb=Pa.from();Pa=Pa.to();var Jb=Math.max(Ga,fb.line);Ga=Math.min(this.lastLine(),Pa.line-(Pa.ch?0:1))+1;for(Pa=Jb;Pa>1;if((Pa?ra[2*Pa-1]:0)>=ea)Qa=Pa;else if(ra[2*Pa+1]Ga?ra:0==Ga?null:ra.slice(0,Ga-1)},getModeAt:function(ea){var ra= this.doc.mode;return ra.innerMode?r.innerMode(ra,this.getTokenAt(ea).state).mode:ra},getHelper:function(ea,ra){return this.getHelpers(ea,ra)[0]},getHelpers:function(ea,ra){var Ga=[];if(!ka.hasOwnProperty(ra))return Ga;var Qa=ka[ra];ea=this.getModeAt(ea);if("string"==typeof ea[ra])Qa[ea[ra]]&&Ga.push(Qa[ea[ra]]);else if(ea[ra])for(var Pa=0;PaPa&&(ea=Pa,Qa=!0);ea=Fb(this.doc,ea)}return bd(this,ea,{top:0,left:0},ra||"page",Ga||Qa).top+(Qa?this.doc.height-Za(ea):0)},defaultTextHeight:function(){return Xb(this.display)}, defaultCharWidth:function(){return tc(this.display)},getViewport:function(){return{from:this.display.viewFrom,to:this.display.viewTo}},addWidget:function(ea,ra,Ga,Qa,Pa){var fb=this.display;ea=ge(this,Ub(this.doc,ea));var Jb=ea.bottom,Kb=ea.left;ra.style.position="absolute";ra.setAttribute("cm-ignore-events","true");this.display.input.setUneditable(ra);fb.sizer.appendChild(ra);if("over"==Qa)Jb=ea.top;else if("above"==Qa||"near"==Qa){var Ac=Math.max(fb.wrapper.clientHeight,this.doc.height),Cc=Math.max(fb.sizer.clientWidth, fb.lineSpace.clientWidth);("above"==Qa||ea.bottom+ra.offsetHeight>Ac)&&ea.top>ra.offsetHeight?Jb=ea.top-ra.offsetHeight:ea.bottom+ra.offsetHeight<=Ac&&(Jb=ea.bottom);Kb+ra.offsetWidth>Cc&&(Kb=Cc-ra.offsetWidth)}ra.style.top=Jb+"px";ra.style.left=ra.style.right="";"right"==Pa?(Kb=fb.sizer.clientWidth-ra.offsetWidth,ra.style.right="0px"):("left"==Pa?Kb=0:"middle"==Pa&&(Kb=(fb.sizer.clientWidth-ra.offsetWidth)/2),ra.style.left=Kb+"px");Ga&&(ea=Ol(this,{left:Kb,top:Jb,right:Kb+ra.offsetWidth,bottom:Jb+ ra.offsetHeight}),null!=ea.scrollTop&&Wj(this,ea.scrollTop),null!=ea.scrollLeft&&Zi(this,ea.scrollLeft))},triggerOnKeyDown:Wh(Gm),triggerOnKeyPress:Wh(Xl),triggerOnKeyUp:Sl,triggerOnMouseDown:Wh(Yf),execCommand:function(ea){if(Lj.hasOwnProperty(ea))return Lj[ea].call(null,this)},triggerElectric:Wh(function(ea){Rj(this,ea)}),findPosH:function(ea,ra,Ga,Qa){var Pa=1;0>ra&&(Pa=-1,ra=-ra);ea=Ub(this.doc,ea);for(var fb=0;fbea?Qa.from():Qa.to()},ml)}),deleteH:Wh(function(ea,ra){var Ga=this.doc;this.doc.sel.somethingSelected()?Ga.replaceSelection("",null,"+delete"):Gj(this,function(Qa){var Pa=Me(Ga,Qa.head,ea,ra,!1);return 0>ea?{from:Pa,to:Qa.head}:{from:Qa.head,to:Pa}})}),findPosV:function(ea,ra,Ga,Qa){var Pa=1;0>ra&&(Pa=-1,ra=-ra);var fb=Ub(this.doc,ea);for(ea= 0;eaea?Kb.from():Kb.to();var Ac=ge(Ga,Kb.head,"div");null!=Kb.goalColumn&&(Ac.left=Kb.goalColumn);Pa.push(Ac.left);var Cc=li(Ga,Ac,ea,ra);"page"==ra&&Kb==Qa.sel.primary()&&xj(Ga,md(Ga,Cc,"div").top-Ac.top);return Cc},ml);if(Pa.length)for(var Jb= 0;Jbq(Qk,Vk)&&(ke.prototype[Vk]=function(r){return function(){return r.apply(this.doc,arguments)}}(fe.prototype[Vk]));ba(fe);ke.inputStyles={textarea:Fg, contenteditable:Be};ke.defineMode=function(r){ke.defaults.mode||"null"==r||(ke.defaults.mode=r);Da.apply(this,arguments)};ke.defineMIME=function(r,I){yk[r]=I};ke.defineMode("null",function(){return{token:function(r){return r.skipToEnd()}}});ke.defineMIME("text/plain","null");ke.defineExtension=function(r,I){ke.prototype[r]=I};ke.defineDocExtension=function(r,I){fe.prototype[r]=I};ke.fromTextArea=function(r,I){function ka(){r.value=Pa.getValue()}I=I?m(I):{};I.value=r.value;!I.tabindex&&r.tabIndex&& (I.tabindex=r.tabIndex);!I.placeholder&&r.placeholder&&(I.placeholder=r.placeholder);if(null==I.autofocus){var ea=h();I.autofocus=ea==r||null!=r.getAttribute("autofocus")&&ea==document.body}if(r.form&&(Ne(r.form,"submit",ka),!I.leaveSubmitMethodAlone)){var ra=r.form;var Ga=ra.submit;try{var Qa=ra.submit=function(){ka();ra.submit=Ga;ra.submit();ra.submit=Qa}}catch(fb){}}I.finishInit=function(fb){fb.save=ka;fb.getTextArea=function(){return r};fb.toTextArea=function(){fb.toTextArea=isNaN;ka();r.parentNode.removeChild(fb.getWrapperElement()); r.style.display="";r.form&&(Q(r.form,"submit",ka),I.leaveSubmitMethodAlone||"function"!=typeof r.form.submit||(r.form.submit=Ga))}};r.style.display="none";var Pa=ke(function(fb){return r.parentNode.insertBefore(fb,r.nextSibling)},I);return Pa};(function(r){r.off=Q;r.on=Ne;r.wheelEventPixels=Wg;r.Doc=fe;r.splitLines=ij;r.countColumn=e;r.findColumn=w;r.isWordChar=v;r.Pass=Uk;r.signal=V;r.Line=fi;r.changeEnd=tg;r.scrollbarModel=Ei;r.Pos=ib;r.cmpPos=La;r.modes=tj;r.mimeModes=yk;r.resolveMode=ya;r.getMode= Ma;r.modeExtensions=Sj;r.extendMode=Ra;r.copyState=Ta;r.startState=Ib;r.innerMode=db;r.commands=Lj;r.keyMap=Bk;r.keyName=hh;r.isModifierKey=Ul;r.lookupKey=si;r.normalizeKeyMap=zi;r.StringStream=fh;r.SharedTextMarker=Ll;r.TextMarker=pe;r.LineWidget=nk;r.e_preventDefault=ua;r.e_stopPropagation=U;r.e_stop=ta;r.addClass=p;r.contains=f;r.rmClass=Ch;r.keyNames=Gi})(ke);ke.version="5.58.1";return ke})}; shadow$provide[476]=function(aa,K,za,t){(function(l){"object"==typeof t&&"object"==typeof za?l(K(475)):"function"==typeof define&&define.amd?define(["../../lib/codemirror"],l):l(CodeMirror)})(function(l){function A(e,q){return"pairs"==q&&"string"==typeof e?e:"object"==typeof e&&null!=e[q]?e[q]:a[q]}function n(e){for(var q=0;qO;O++)e.execCommand("goCharRight");else if("surround"==v){var X=e.getSelections();for(O=0;Ow))for(M==u.line&&(B=u.ch-(0>m?1:0));B!=F;B+=m){var v=G.charAt(B);if(q.test(v)&&(void 0===e||a.getTokenTypeAt(h(M,B+1))==e)){var T=p[v];if(T&&"\x3e"==T.charAt(1)==0document.documentMode),h=l.Pos,p={"(":")\x3e",")":"(\x3c","[":"]\x3e","]":"[\x3c","{":"}\x3e","}":"{\x3c","\x3c":"\x3e\x3e","\x3e":"\x3c\x3c"};l.defineOption("matchBrackets",!1,function(a,u,m){function e(q){q.state.matchBrackets&&q.state.matchBrackets.currentlyHighlighted&& (q.state.matchBrackets.currentlyHighlighted(),q.state.matchBrackets.currentlyHighlighted=null)}m&&m!=l.Init&&(a.off("cursorActivity",b),a.off("focus",b),a.off("blur",e),e(a));u&&(a.state.matchBrackets="object"==typeof u?u:{},a.on("cursorActivity",b),a.on("focus",b),a.on("blur",e))});l.defineExtension("matchBrackets",function(){k(this,!0)});l.defineExtension("findMatchingBracket",function(a,u,m){if(m||"boolean"==typeof u)m?(m.strict=u,u=m):u=u?{strict:!0}:null;return A(this,a,u)});l.defineExtension("scanForBracket", function(a,u,m,e){return n(this,a,u,m,e)})})}; shadow$provide[478]=function(aa,K,za,t){(function(l){"object"==typeof t&&"object"==typeof za?l(K(475)):"function"==typeof define&&define.amd?define(["../../lib/codemirror"],l):l(CodeMirror)})(function(l){function A(f){for(var h=0;h≥≠≡≢∈⍷∪∩∼∨∧⍱⍲⍴,⍪⌽⊖⍉↑↓⊂⊃⌷⍋⍒⊤⊥⍕⍎⊣⊢]/,h=/←/,p=/[⍝#].*$/,a=function(u){var m=!1;return function(e){m=e;return e===u?"\\"===m:!0}};return{startState:function(){return{prev:!1,func:!1,op:!1,string:!1,escape:!1}},token:function(u,m){if(u.eatSpace())return null;var e=u.next();if('"'===e||"'"===e)return u.eatWhile(a(e)),u.next(),m.prev=!0,"string";if(/[\[{\(]/.test(e))return m.prev= !1,null;if(/[\]}\)]/.test(e))return m.prev=!0,null;if(b.test(e))return m.prev=!1,"niladic";if(/[¯\d]/.test(e))return m.func?(m.func=!1,m.prev=!1):m.prev=!0,u.eatWhile(/[\w\.]/),"number";if(k.test(e))return"operator apl-"+A[e];if(h.test(e))return"apl-arrow";if(f.test(e))return u="apl-",null!=n[e]&&(u=m.prev?u+n[e][1]:u+n[e][0]),m.func=!0,m.prev=!1,"function "+u;if(p.test(e))return u.skipToEnd(),"comment";if("∘"===e&&"."===u.peek())return u.next(),"function jot-dot";u.eatWhile(/[\w\$_]/);m.prev=!0; return"keyword"}}});l.defineMIME("text/apl","apl")})}; shadow$provide[480]=function(aa,K,za,t){(function(l){"object"==typeof t&&"object"==typeof za?l(K(475)):"function"==typeof define&&define.amd?define(["../../lib/codemirror"],l):l(CodeMirror)})(function(l){function A(n){var k=n.match(/^\s*\S/);n.skipToEnd();return k?"error":null}l.defineMode("asciiarmor",function(){return{token:function(n,k){var b;if("top"==k.state)return n.sol()&&(b=n.match(/^-----BEGIN (.*)?-----\s*$/))?(k.state="headers",k.type=b[1],"tag"):A(n);if("headers"==k.state){if(n.sol()&& n.match(/^\w+:/))return k.state="header","atom";if(n=A(n))k.state="body";return n}if("header"==k.state)return n.skipToEnd(),k.state="headers","string";if("body"==k.state){if(n.sol()&&(b=n.match(/^-----END (.*)?-----\s*$/))){if(b[1]!=k.type)return"error";k.state="end";return"tag"}if(n.eatWhile(/[A-Za-z0-9+\/=]/))return null;n.next();return"error"}if("end"==k.state)return A(n)},blankLine:function(n){"headers"==n.state&&(n.state="body")},startState:function(){return{state:"top",type:null}}}});l.defineMIME("application/pgp", "asciiarmor");l.defineMIME("application/pgp-encrypted","asciiarmor");l.defineMIME("application/pgp-keys","asciiarmor");l.defineMIME("application/pgp-signature","asciiarmor")})}; shadow$provide[481]=function(aa,K,za,t){(function(l){"object"==typeof t&&"object"==typeof za?l(K(475)):"function"==typeof define&&define.amd?define(["../../lib/codemirror"],l):l(CodeMirror)})(function(l){function A(n){var k={};n=n.split(" ");for(var b=0;b?$/.test(p))return h.extenExten=!0,h.extenStart=!1,"strong";h.extenStart=!1;f.skipToEnd();return"error"}if(h.extenExten)return h.extenExten=!1,h.extenPriority=!0,f.eatWhile(/[^,]/),h.extenInclude&&(f.skipToEnd(),h.extenPriority=!1,h.extenInclude= !1),h.extenSame&&(h.extenPriority=!1,h.extenSame=!1,h.extenApplication=!0),"tag";if(h.extenPriority){h.extenPriority=!1;h.extenApplication=!0;f.next();if(h.extenSame)return null;f.eatWhile(/[^,]/);return"number"}if(h.extenApplication){f.eatWhile(/,/);p=f.current();if(","===p)return null;f.eatWhile(/\w/);p=f.current().toLowerCase();h.extenApplication=!1;if(-1!==b.indexOf(p))return"def strong"}else return A(f,h);return null},blockCommentStart:";--",blockCommentEnd:"--;",lineComment:";"}});l.defineMIME("text/x-asterisk", "asterisk")})}; shadow$provide[483]=function(aa,K,za,t){(function(l){"object"==typeof t&&"object"==typeof za?l(K(475)):"function"==typeof define&&define.amd?define(["../../lib/codemirror"],l):l(CodeMirror)})(function(l){var A="\x3e\x3c+-.,[]".split("");l.defineMode("brainfuck",function(){return{startState:function(){return{commentLine:!1,left:0,right:0,commentLoop:!1}},token:function(n,k){if(n.eatSpace())return null;n.sol()&&(k.commentLine=!1);var b=n.next().toString();if(-1!==A.indexOf(b)){if(!0===k.commentLine)return n.eol()&& (k.commentLine=!1),"comment";if("]"===b||"["===b)return"["===b?k.left++:k.right++,"bracket";if("+"===b||"-"===b)return"keyword";if("\x3c"===b||"\x3e"===b)return"atom";if("."===b||","===b)return"def"}else return k.commentLine=!0,n.eol()&&(k.commentLine=!1),"comment";n.eol()&&(k.commentLine=!1)}}});l.defineMIME("text/x-brainfuck","brainfuck")})}; shadow$provide[484]=function(aa,K,za,t){(function(l){"object"==typeof t&&"object"==typeof za?l(K(475)):"function"==typeof define&&define.amd?define(["../../lib/codemirror"],l):l(CodeMirror)})(function(l){function A(da,O,X,Q,V,L){this.indented=da;this.column=O;this.type=X;this.info=Q;this.align=V;this.prev=L}function n(da,O,X,Q){var V=da.indented;da.context&&"statement"==da.context.type&&"statement"!=X&&(V=da.context.indented);return da.context=new A(V,O,X,Q,null,da.context)}function k(da){var O=da.context.type; if(")"==O||"]"==O||"}"==O)da.indented=da.context.indented;return da.context=da.context.prev}function b(da,O,X){if("variable"==O.prevToken||"type"==O.prevToken||/\S(?:[^- ]>|[*\]])\s*$|\*$/.test(da.string.slice(0,X))||O.typeAtEndOfLine&&da.column()==da.indentation())return!0}function f(da){for(;;){if(!da||"top"==da.type)return!0;if("}"==da.type&&"namespace"!=da.prev.info)return!1;da=da.prev}}function h(da){var O={};da=da.split(" ");for(var X=0;Xda.length||"_"!=da[0]?!1:"_"==da[1]||da[1]!==da[1].toLowerCase()}function w(da){da.eatWhile(/[\w\.']/); return"number"}function y(da,O){da.backUp(1);if(da.match(/(R|u8R|uR|UR|LR)/)){var X=da.match(/"([^\s\\()]{0,16})\(/);if(!X)return!1;O.cpp11RawStringDelim=X[1];O.tokenize=G;return G(da,O)}if(da.match(/(u8|u|U|L)/))return da.match(/["']/,!1)?"string":!1;da.next();return!1}function E(da){return(da=/(\w+)::~?(\w+)$/.exec(da))&&da[1]==da[2]}function M(da,O){for(var X;null!=(X=da.next());)if('"'==X&&!da.eat('"')){O.tokenize=null;break}return"string"}function G(da,O){var X=O.cpp11RawStringDelim.replace(/[^\w\s]/g, "\\$\x26");da.match(new RegExp(".*?\\)"+X+'"'))?O.tokenize=null:da.skipToEnd();return"string"}function B(da,O){function X(L){if(L)for(var N in L)L.hasOwnProperty(N)&&Q.push(N)}"string"==typeof da&&(da=[da]);var Q=[];X(O.keywords);X(O.types);X(O.builtin);X(O.atoms);Q.length&&(O.helperType=da[0],l.registerHelper("hintWords",da[0],Q));for(var V=0;V!?|\/]/,hc=O.isIdentifierChar||/[\w\$_\xa1-\uffff]/,Db=O.isReservedIdentifier||!1,ec,Zb;return{startState:function(Ab){return{tokenize:null,context:new A((Ab||0)-N,0,"top",null,!1),indented:0,startOfLine:!0,prevToken:null}},token:function(Ab,hb){var ib=hb.context; Ab.sol()&&(null==ib.align&&(ib.align=!1),hb.indented=Ab.indentation(),hb.startOfLine=!0);if(Ab.eatSpace())return L(Ab,hb),null;ec=Zb=null;var La=(hb.tokenize||X)(Ab,hb);if("comment"==La||"meta"==La)return La;null==ib.align&&(ib.align=!0);if(";"==ec||":"==ec||","==ec&&Ab.match(/^\s*(?:\/\/.*)?$/,!1))for(;"statement"==hb.context.type;)k(hb);else if("{"==ec)n(hb,Ab.column(),"}");else if("["==ec)n(hb,Ab.column(),"]");else if("("==ec)n(hb,Ab.column(),")");else if("}"==ec){for(;"statement"==ib.type;)ib= k(hb);for("}"==ib.type&&(ib=k(hb));"statement"==ib.type;)ib=k(hb)}else ec==ib.type?k(hb):Ra&&(("}"==ib.type||"top"==ib.type)&&";"!=ec||"statement"==ib.type&&"newstatement"==ec)&&n(hb,Ab.column(),"statement",Ab.current());"variable"==La&&("def"==hb.prevToken||O.typeFirstDefinitions&&b(Ab,hb,Ab.start)&&f(hb.context)&&Ab.match(/^\s*\(/,!1))&&(La="def");ya.token&&(ib=ya.token(Ab,hb,La),void 0!==ib&&(La=ib));"def"==La&&!1===O.styleDefs&&(La="variable");hb.startOfLine=!1;hb.prevToken=Zb?"def":La||ec;L(Ab, hb);return La},indent:function(Ab,hb){if(Ab.tokenize!=X&&null!=Ab.tokenize||Ab.typeAtEndOfLine)return l.Pass;var ib=Ab.context,La=hb&&hb.charAt(0),Ja=La==ib.type;"statement"==ib.type&&"}"==La&&(ib=ib.prev);if(O.dontIndentStatements)for(;"statement"==ib.type&&O.dontIndentStatements.test(ib.info);)ib=ib.prev;if(ya.indent&&(Ab=ya.indent(Ab,ib,hb,N),"number"==typeof Ab))return Ab;Ab=ib.prev&&"switch"==ib.prev.info;if(O.allmanIndentation&&/[{(]/.test(La)){for(;"top"!=ib.type&&"}"!=ib.type;)ib=ib.prev; return ib.indented}return"statement"==ib.type?ib.indented+("{"==La?0:J):!ib.align||ba&&")"==ib.type?")"!=ib.type||Ja?ib.indented+(Ja?0:N)+(Ja||!Ab||/^(?:case|default)\b/.test(hb)?0:N):ib.indented+J:ib.column+(Ja?0:1)},electricInput:!1!==O.indentSwitch?/^\s*(?:case .*?:|default:|\{\}?|\})$/:/^\s*[{}]$/,blockCommentStart:"/*",blockCommentEnd:"*/",blockCommentContinue:" * ",lineComment:"//",fold:"brace"}});var W=h("int long char short double float unsigned signed void bool"),ia=h("SEL instancetype id Class Protocol BOOL"); B(["text/x-csrc","text/x-c","text/x-chdr"],{name:"clike",keywords:h("auto if break case register continue return default do sizeof static else struct switch extern typedef union for goto while enum const volatile inline restrict asm fortran"),types:a,blockKeywords:h("case do else for if switch while struct enum union"),defKeywords:h("struct enum union"),typeFirstDefinitions:!0,atoms:h("NULL true false"),isReservedIdentifier:q,hooks:{"#":m,"*":e},modeProps:{fold:["brace","include"]}});B(["text/x-c++src", "text/x-c++hdr"],{name:"clike",keywords:h("auto if break case register continue return default do sizeof static else struct switch extern typedef union for goto while enum const volatile inline restrict asm fortran alignas alignof and and_eq audit axiom bitand bitor catch class compl concept constexpr const_cast decltype delete dynamic_cast explicit export final friend import module mutable namespace new noexcept not not_eq operator or or_eq override private protected public reinterpret_cast requires static_assert static_cast template this thread_local throw try typeid typename using virtual xor xor_eq"), types:a,blockKeywords:h("case do else for if switch while struct enum union class try catch"),defKeywords:h("struct enum union class namespace"),typeFirstDefinitions:!0,atoms:h("true false NULL nullptr"),dontIndentStatements:/^template$/,isIdentifierChar:/[\w\$_~\xa1-\uffff]/,isReservedIdentifier:q,hooks:{"#":m,"*":e,u:y,U:y,L:y,R:y,0:w,1:w,2:w,3:w,4:w,5:w,6:w,7:w,8:w,9:w,token:function(da,O,X){if("variable"==X&&"("==da.peek()&&(";"==O.prevToken||null==O.prevToken||"}"==O.prevToken)&&E(da.current()))return"def"}}, namespaceSeparator:"::",modeProps:{fold:["brace","include"]}});B("text/x-java",{name:"clike",keywords:h("abstract assert break case catch class const continue default do else enum extends final finally for goto if implements import instanceof interface native new package private protected public return static strictfp super switch synchronized this throw throws transient try volatile while @interface"),types:h("byte short int long float double boolean char void Boolean Byte Character Double Float Integer Long Number Object Short String StringBuffer StringBuilder Void"), blockKeywords:h("catch class do else finally for if switch try while"),defKeywords:h("class interface enum @interface"),typeFirstDefinitions:!0,atoms:h("true false null"),number:/^(?:0x[a-f\d_]+|0b[01_]+|(?:[\d_]+\.?\d*|\.\d+)(?:e[-+]?[\d_]+)?)(u|ll?|l|f)?/i,hooks:{"@":function(da){if(da.match("interface",!1))return!1;da.eatWhile(/[\w\$_]/);return"meta"}},modeProps:{fold:["brace","import"]}});B("text/x-csharp",{name:"clike",keywords:h("abstract as async await base break case catch checked class const continue default delegate do else enum event explicit extern finally fixed for foreach goto if implicit in interface internal is lock namespace new operator out override params private protected public readonly ref return sealed sizeof stackalloc static struct switch this throw try typeof unchecked unsafe using virtual void volatile while add alias ascending descending dynamic from get global group into join let orderby partial remove select set value var yield"), types:h("Action Boolean Byte Char DateTime DateTimeOffset Decimal Double Func Guid Int16 Int32 Int64 Object SByte Single String Task TimeSpan UInt16 UInt32 UInt64 bool byte char decimal double short int long object sbyte float string ushort uint ulong"),blockKeywords:h("catch class do else finally for foreach if struct switch try while"),defKeywords:h("class interface namespace struct var"),typeFirstDefinitions:!0,atoms:h("true false null"),hooks:{"@":function(da,O){if(da.eat('"'))return O.tokenize= M,M(da,O);da.eatWhile(/[\w\$_]/);return"meta"}}});B("text/x-scala",{name:"clike",keywords:h("abstract case catch class def do else extends final finally for forSome if implicit import lazy match new null object override package private protected return sealed super this throw trait try type val var while with yield _ assert assume require print println printf readLine readBoolean readByte readShort readChar readInt readLong readFloat readDouble"),types:h("AnyVal App Application Array BufferedIterator BigDecimal BigInt Char Console Either Enumeration Equiv Error Exception Fractional Function IndexedSeq Int Integral Iterable Iterator List Map Numeric Nil NotNull Option Ordered Ordering PartialFunction PartialOrdering Product Proxy Range Responder Seq Serializable Set Specializable Stream StringBuilder StringContext Symbol Throwable Traversable TraversableOnce Tuple Unit Vector Boolean Byte Character CharSequence Class ClassLoader Cloneable Comparable Compiler Double Exception Float Integer Long Math Number Object Package Pair Process Runtime Runnable SecurityManager Short StackTraceElement StrictMath String StringBuffer System Thread ThreadGroup ThreadLocal Throwable Triple Void"), multiLineStrings:!0,blockKeywords:h("catch class enum do else finally for forSome if match switch try while"),defKeywords:h("class enum def object package trait type val var"),atoms:h("true false null"),indentStatements:!1,indentSwitch:!1,isOperatorChar:/[+\-*&%=<>!?|\/#:@]/,hooks:{"@":function(da){da.eatWhile(/[\w\$_]/);return"meta"},'"':function(da,O){if(!da.match('""'))return!1;O.tokenize=F;return O.tokenize(da,O)},"'":function(da){da.eatWhile(/[\w\$_\xa1-\uffff]/);return"atom"},"\x3d":function(da, O){var X=O.context;return"}"==X.type&&X.align&&da.eat("\x3e")?(O.context=new A(X.indented,X.column,X.type,X.info,null,X.prev),"operator"):!1},"/":function(da,O){if(!da.eat("*"))return!1;O.tokenize=v(1);return O.tokenize(da,O)}},modeProps:{closeBrackets:{pairs:'()[]{}""',triples:'"'}}});B("text/x-kotlin",{name:"clike",keywords:h("package as typealias class interface this super val operator var fun for is in This throw return annotation break continue object if else while do try when !in !is as? file import where by get set abstract enum open inner override private public internal protected catch finally out final vararg reified dynamic companion constructor init sealed field property receiver param sparam lateinit data inline noinline tailrec external annotation crossinline const operator infix suspend actual expect setparam"), types:h("Boolean Byte Character CharSequence Class ClassLoader Cloneable Comparable Compiler Double Exception Float Integer Long Math Number Object Package Pair Process Runtime Runnable SecurityManager Short StackTraceElement StrictMath String StringBuffer System Thread ThreadGroup ThreadLocal Throwable Triple Void Annotation Any BooleanArray ByteArray Char CharArray DeprecationLevel DoubleArray Enum FloatArray Function Int IntArray Lazy LazyThreadSafetyMode LongArray Nothing ShortArray Unit"),intendSwitch:!1, indentStatements:!1,multiLineStrings:!0,number:/^(?:0x[a-f\d_]+|0b[01_]+|(?:[\d_]+(\.\d+)?|\.\d+)(?:e[-+]?[\d_]+)?)(u|ll?|l|f)?/i,blockKeywords:h("catch class do else finally for if where try while enum"),defKeywords:h("class val var object interface fun"),atoms:h("true false null this"),hooks:{"@":function(da){da.eatWhile(/[\w\$_]/);return"meta"},"*":function(da,O){return"."==O.prevToken?"variable":"operator"},'"':function(da,O){O.tokenize=T(da.match('""'));return O.tokenize(da,O)},"/":function(da, O){if(!da.eat("*"))return!1;O.tokenize=v(1);return O.tokenize(da,O)},indent:function(da,O,X,Q){var V=X&&X.charAt(0);if(("}"==da.prevToken||")"==da.prevToken)&&""==X)return da.indented;if("operator"==da.prevToken&&"}"!=X&&"}"!=da.context.type||"variable"==da.prevToken&&"."==V||("}"==da.prevToken||")"==da.prevToken)&&"."==V)return 2*Q+O.indented;if(O.align&&"}"==O.type)return O.indented+(da.context.type==(X||"").charAt(0)?0:Q)}},modeProps:{closeBrackets:{triples:'"'}}});B(["x-shader/x-vertex","x-shader/x-fragment"], {name:"clike",keywords:h("sampler1D sampler2D sampler3D samplerCube sampler1DShadow sampler2DShadow const attribute uniform varying break continue discard return for while do if else struct in out inout"),types:h("float int bool void vec2 vec3 vec4 ivec2 ivec3 ivec4 bvec2 bvec3 bvec4 mat2 mat3 mat4"),blockKeywords:h("for while do if else struct"),builtin:h("radians degrees sin cos tan asin acos atan pow exp log exp2 sqrt inversesqrt abs sign floor ceil fract mod min max clamp mix step smoothstep length distance dot cross normalize ftransform faceforward reflect refract matrixCompMult lessThan lessThanEqual greaterThan greaterThanEqual equal notEqual any all not texture1D texture1DProj texture1DLod texture1DProjLod texture2D texture2DProj texture2DLod texture2DProjLod texture3D texture3DProj texture3DLod texture3DProjLod textureCube textureCubeLod shadow1D shadow2D shadow1DProj shadow2DProj shadow1DLod shadow2DLod shadow1DProjLod shadow2DProjLod dFdx dFdy fwidth noise1 noise2 noise3 noise4"), atoms:h("true false gl_FragColor gl_SecondaryColor gl_Normal gl_Vertex gl_MultiTexCoord0 gl_MultiTexCoord1 gl_MultiTexCoord2 gl_MultiTexCoord3 gl_MultiTexCoord4 gl_MultiTexCoord5 gl_MultiTexCoord6 gl_MultiTexCoord7 gl_FogCoord gl_PointCoord gl_Position gl_PointSize gl_ClipVertex gl_FrontColor gl_BackColor gl_FrontSecondaryColor gl_BackSecondaryColor gl_TexCoord gl_FogFragCoord gl_FragCoord gl_FrontFacing gl_FragData gl_FragDepth gl_ModelViewMatrix gl_ProjectionMatrix gl_ModelViewProjectionMatrix gl_TextureMatrix gl_NormalMatrix gl_ModelViewMatrixInverse gl_ProjectionMatrixInverse gl_ModelViewProjectionMatrixInverse gl_TexureMatrixTranspose gl_ModelViewMatrixInverseTranspose gl_ProjectionMatrixInverseTranspose gl_ModelViewProjectionMatrixInverseTranspose gl_TextureMatrixInverseTranspose gl_NormalScale gl_DepthRange gl_ClipPlane gl_Point gl_FrontMaterial gl_BackMaterial gl_LightSource gl_LightModel gl_FrontLightModelProduct gl_BackLightModelProduct gl_TextureColor gl_EyePlaneS gl_EyePlaneT gl_EyePlaneR gl_EyePlaneQ gl_FogParameters gl_MaxLights gl_MaxClipPlanes gl_MaxTextureUnits gl_MaxTextureCoords gl_MaxVertexAttribs gl_MaxVertexUniformComponents gl_MaxVaryingFloats gl_MaxVertexTextureImageUnits gl_MaxTextureImageUnits gl_MaxFragmentUniformComponents gl_MaxCombineTextureImageUnits gl_MaxDrawBuffers"), indentSwitch:!1,hooks:{"#":m},modeProps:{fold:["brace","include"]}});B("text/x-nesc",{name:"clike",keywords:h("auto if break case register continue return default do sizeof static else struct switch extern typedef union for goto while enum const volatile inline restrict asm fortran as atomic async call command component components configuration event generic implementation includes interface module new norace nx_struct nx_union post provides signal task uses abstract extends"),types:a,blockKeywords:h("case do else for if switch while struct enum union"), atoms:h("null true false"),hooks:{"#":m},modeProps:{fold:["brace","include"]}});B("text/x-objectivec",{name:"clike",keywords:h("auto if break case register continue return default do sizeof static else struct switch extern typedef union for goto while enum const volatile inline restrict asm fortran bycopy byref in inout oneway out self super atomic nonatomic retain copy readwrite readonly strong weak assign typeof nullable nonnull null_resettable _cmd @interface @implementation @end @protocol @encode @property @synthesize @dynamic @class @public @package @private @protected @required @optional @try @catch @finally @import @selector @encode @defs @synchronized @autoreleasepool @compatibility_alias @available"), types:u,builtin:h("FOUNDATION_EXPORT FOUNDATION_EXTERN NS_INLINE NS_FORMAT_FUNCTION NS_RETURNS_RETAINEDNS_ERROR_ENUM NS_RETURNS_NOT_RETAINED NS_RETURNS_INNER_POINTER NS_DESIGNATED_INITIALIZER NS_ENUM NS_OPTIONS NS_REQUIRES_NIL_TERMINATION NS_ASSUME_NONNULL_BEGIN NS_ASSUME_NONNULL_END NS_SWIFT_NAME NS_REFINED_FOR_SWIFT"),blockKeywords:h("case do else for if switch while struct enum union @synthesize @try @catch @finally @autoreleasepool @synchronized"),defKeywords:h("struct enum union @interface @implementation @protocol @class"), dontIndentStatements:/^@.*$/,typeFirstDefinitions:!0,atoms:h("YES NO NULL Nil nil true false nullptr"),isReservedIdentifier:q,hooks:{"#":m,"*":e},modeProps:{fold:["brace","include"]}});B("text/x-objectivec++",{name:"clike",keywords:h("auto if break case register continue return default do sizeof static else struct switch extern typedef union for goto while enum const volatile inline restrict asm fortran bycopy byref in inout oneway out self super atomic nonatomic retain copy readwrite readonly strong weak assign typeof nullable nonnull null_resettable _cmd @interface @implementation @end @protocol @encode @property @synthesize @dynamic @class @public @package @private @protected @required @optional @try @catch @finally @import @selector @encode @defs @synchronized @autoreleasepool @compatibility_alias @available alignas alignof and and_eq audit axiom bitand bitor catch class compl concept constexpr const_cast decltype delete dynamic_cast explicit export final friend import module mutable namespace new noexcept not not_eq operator or or_eq override private protected public reinterpret_cast requires static_assert static_cast template this thread_local throw try typeid typename using virtual xor xor_eq"), types:u,builtin:h("FOUNDATION_EXPORT FOUNDATION_EXTERN NS_INLINE NS_FORMAT_FUNCTION NS_RETURNS_RETAINEDNS_ERROR_ENUM NS_RETURNS_NOT_RETAINED NS_RETURNS_INNER_POINTER NS_DESIGNATED_INITIALIZER NS_ENUM NS_OPTIONS NS_REQUIRES_NIL_TERMINATION NS_ASSUME_NONNULL_BEGIN NS_ASSUME_NONNULL_END NS_SWIFT_NAME NS_REFINED_FOR_SWIFT"),blockKeywords:h("case do else for if switch while struct enum union @synthesize @try @catch @finally @autoreleasepool @synchronized class try catch"),defKeywords:h("struct enum union @interface @implementation @protocol @class class namespace"), dontIndentStatements:/^@.*$|^template$/,typeFirstDefinitions:!0,atoms:h("YES NO NULL Nil nil true false nullptr"),isReservedIdentifier:q,hooks:{"#":m,"*":e,u:y,U:y,L:y,R:y,0:w,1:w,2:w,3:w,4:w,5:w,6:w,7:w,8:w,9:w,token:function(da,O,X){if("variable"==X&&"("==da.peek()&&(";"==O.prevToken||null==O.prevToken||"}"==O.prevToken)&&E(da.current()))return"def"}},namespaceSeparator:"::",modeProps:{fold:["brace","include"]}});B("text/x-squirrel",{name:"clike",keywords:h("base break clone continue const default delete enum extends function in class foreach local resume return this throw typeof yield constructor instanceof static"), types:a,blockKeywords:h("case catch class else for foreach if switch try while"),defKeywords:h("function local class"),typeFirstDefinitions:!0,atoms:h("true false null"),hooks:{"#":m},modeProps:{fold:["brace","include"]}});var ja=null;B("text/x-ceylon",{name:"clike",keywords:h("abstracts alias assembly assert assign break case catch class continue dynamic else exists extends finally for function given if import in interface is let module new nonempty object of out outer package return satisfies super switch then this throw try value void while"), types:function(da){da=da.charAt(0);return da===da.toUpperCase()&&da!==da.toLowerCase()},blockKeywords:h("case catch class dynamic else finally for function if interface module new object switch try while"),defKeywords:h("class dynamic function interface module object package value"),builtin:h("abstract actual aliased annotation by default deprecated doc final formal late license native optional sealed see serializable shared suppressWarnings tagged throws variable"),isPunctuationChar:/[\[\]{}\(\),;:\.`]/, isOperatorChar:/[+\-*&%=<>!?|^~:\/]/,numberStart:/[\d#$]/,number:/^(?:#[\da-fA-F_]+|\$[01_]+|[\d_]+[kMGTPmunpf]?|[\d_]+\.[\d_]+(?:[eE][-+]?\d+|[kMGTPmunpf]|)|)/i,multiLineStrings:!0,typeFirstDefinitions:!0,atoms:h("true false null larger smaller equal empty finished"),indentSwitch:!1,styleDefs:!1,hooks:{"@":function(da){da.eatWhile(/[\w\$_]/);return"meta"},'"':function(da,O){O.tokenize=ca(da.match('""')?"triple":"single");return O.tokenize(da,O)},"`":function(da,O){if(!ja||!da.match("`"))return!1; O.tokenize=ja;ja=null;return O.tokenize(da,O)},"'":function(da){da.eatWhile(/[\w\$_\xa1-\uffff]/);return"atom"},token:function(da,O,X){if(("variable"==X||"type"==X)&&"."==O.prevToken)return"variable-2"}},modeProps:{fold:["brace","import"],closeBrackets:{triples:'"'}}})})}; shadow$provide[485]=function(aa,K,za,t){(function(l){"object"===typeof t&&"object"===typeof za?l(K(475)):"function"===typeof define&&define.amd?define(["../../lib/codemirror"],l):l(CodeMirror)})(function(l){l.defineMode("clojure",function(A){function n(B,F){if(B.eatSpace()||B.eat(","))return["space",null];if(B.match(E))return[null,"number"];if(B.match(M))return[null,"string-2"];if(B.eat(/^"/))return(F.tokenize=k)(B,F);if(B.eat(/^[(\[{]/))return["open","bracket"];if(B.eat(/^[)\]}]/))return["close", "bracket"];if(B.eat(/^;/))return B.skipToEnd(),["space","comment"];if(B.eat(/^[#'@^`~]/))return[null,"meta"];var v=B.match(G);v=v&&v[0];return v?"comment"===v&&"("===F.lastToken?(F.tokenize=b)(B,F):h(v,m)||":"===v.charAt(0)?["symbol","atom"]:h(v,e)||h(v,q)?["symbol","keyword"]:"("===F.lastToken?["symbol","builtin"]:["symbol","variable"]:(B.next(),B.eatWhile(function(T){return!h(T,y)}),[null,"error"])}function k(B,F){for(var v=!1,T;T=B.next();){if('"'===T&&!v){F.tokenize=n;break}v=!v&&"\\"===T}return[null, "string"]}function b(B,F){for(var v=1,T;T=B.next();)if(")"===T&&v--,"("===T&&v++,0===v){B.backUp(1);F.tokenize=n;break}return["space","comment"]}function f(B){for(var F={},v=0;v=w)e="def";else if(72<=w&&79>=w)e.skipToEnd(),e="header";else if("*"== y&&6==w)e.skipToEnd(),e="comment";else if('"'==y||"'"==y)e=q.mode="string";else if("'"!=y||h.test(e.peek()))if("."==y)e="link";else if(q=y,"0"===q&&e.eat(/x/i)?(e.eatWhile(p),q=!0):("+"!=q&&"-"!=q||!f.test(e.peek())||(e.eat(a),q=e.next()),f.test(q)?(e.eat(q),e.eatWhile(f),"."==e.peek()&&(e.eat("."),e.eatWhile(f)),e.eat(u)&&(e.eat(a),e.eatWhile(f)),q=!0):q=!1),q)e="number";else{if(e.current().match(m))for(;71>w&&void 0!==e.eat(m);)w++;e=k&&k.propertyIsEnumerable(e.current().toUpperCase())?"keyword": b&&b.propertyIsEnumerable(e.current().toUpperCase())?"builtin":n&&n.propertyIsEnumerable(e.current().toUpperCase())?"atom":null}else e="atom"}return e},indent:function(e){return null==e.indentStack?e.indentation:e.indentStack.indent}}});l.defineMIME("text/x-cobol","cobol")})}; shadow$provide[488]=function(aa,K,za,t){(function(l){"object"==typeof t&&"object"==typeof za?l(K(475)):"function"==typeof define&&define.amd?define(["../../lib/codemirror"],l):l(CodeMirror)})(function(l){l.defineMode("coffeescript",function(A,n){function k(F){return new RegExp("^(("+F.join(")|(")+"))\\b")}function b(F,v){if(F.sol()){null===v.scope.align&&(v.scope.align=!1);var T=v.scope.offset;if(F.eatSpace())return F=F.indentation(),F>T&&"coffee"==v.scope.type?"indent":F|=>|\+[+=]?|-[\-=]?|\*[\*=]?|\/[\/=]?|[=!]=|<[><]?=?|>>?=?|%=?|&=?|\|=?|\^=?|~|!|\?|(or|and|\|\||&&|\?)=)/,m=/^(?:[()\[\]{},:`=;]|\.\.?\.?)/,e=/^[_A-Za-z$][_A-Za-z$0-9]*/, q=/^@[_A-Za-z$][_A-Za-z$0-9]*/,w=k("and or not is isnt in instanceof typeof".split(" ")),y="for while loop if unless else switch try catch finally class".split(" "),E=k(y.concat("break by continue debugger delete do in of new return then this @ throw when until extends".split(" ")));y=k(y);var M=/^('{3}|"{3}|['"])/,G=/^(\/{3}|\/)/,B=k("Infinity NaN undefined null true false on off yes no".split(" "));return{startState:function(F){return{tokenize:b,scope:{offset:F||0,type:"coffee",prev:null,align:!1}, prop:!1,dedent:0}},token:function(F,v){var T=null===v.scope.align&&v.scope;T&&F.sol()&&(T.align=!1);var ca=v.tokenize(F,v);var W=F.current();"return"===W&&(v.dedent=!0);(("-\x3e"===W||"\x3d\x3e"===W)&&F.eol()||"indent"===ca)&&p(F,v);var ia="[({".indexOf(W);-1!==ia&&p(F,v,"])}".slice(ia,ia+1));y.exec(W)&&p(F,v);"then"==W&&a(F,v);if("dedent"===ca&&a(F,v))ca="error";else{ia="])}".indexOf(W);if(-1!==ia){for(;"coffee"==v.scope.type&&v.scope.prev;)v.scope=v.scope.prev;v.scope.type==W&&(v.scope=v.scope.prev)}v.dedent&& F.eol()&&("coffee"==v.scope.type&&v.scope.prev&&(v.scope=v.scope.prev),v.dedent=!1)}ca&&"comment"!=ca&&(T&&(T.align=!0),v.prop="punctuation"==ca&&"."==F.current());return ca},indent:function(F,v){if(F.tokenize!=b)return 0;F=F.scope;var T=v&&-1<"])}".indexOf(v.charAt(0));if(T)for(;"coffee"==F.type&&F.prev;)F=F.prev;v=T&&F.type===v.charAt(0);return F.align?F.alignOffset-(v?1:0):(v?F.prev:F).offset},lineComment:"#",fold:"indent"}});l.defineMIME("application/vnd.coffeescript","coffeescript");l.defineMIME("text/x-coffeescript", "coffeescript");l.defineMIME("text/coffeescript","coffeescript")})}; shadow$provide[489]=function(aa,K,za,t){(function(l){"object"==typeof t&&"object"==typeof za?l(K(475)):"function"==typeof define&&define.amd?define(["../../lib/codemirror"],l):l(CodeMirror)})(function(l){l.defineMode("commonlisp",function(A){function n(e){for(var q;q=e.next();)if("\\"==q)e.next();else if(!u.test(q)){e.backUp(1);break}return e.current()}function k(e,q){if(e.eatSpace())return m="ws",null;if(e.match(a))return"number";var w=e.next();"\\"==w&&(w=e.next());if('"'==w)return(q.tokenize=b)(e, q);if("("==w)return m="open","bracket";if(")"==w||"]"==w)return m="close","bracket";if(";"==w)return e.skipToEnd(),m="ws","comment";if(/['`,@]/.test(w))return null;if("|"==w){if(e.skipTo("|"))return e.next(),"symbol";e.skipToEnd();return"error"}if("#"==w)return w=e.next(),"("==w?(m="open","bracket"):/[+\-=\.']/.test(w)||/\d/.test(w)&&e.match(/^\d*#/)?null:"|"==w?(q.tokenize=f)(e,q):":"==w?(n(e),"meta"):"\\"==w?(e.next(),n(e),"string-2"):"error";e=n(e);if("."==e)return null;m="symbol";return"nil"== e||"t"==e||":"==e.charAt(0)?"atom":"open"==q.lastType&&(h.test(e)||p.test(e))?"keyword":"\x26"==e.charAt(0)?"variable-2":"variable"}function b(e,q){for(var w=!1,y;y=e.next();){if('"'==y&&!w){q.tokenize=k;break}w=!w&&"\\"==y}return"string"}function f(e,q){for(var w,y;w=e.next();){if("#"==w&&"|"==y){q.tokenize=k;break}y=w}m="ws";return"comment"}var h=/^(block|let*|return-from|catch|load-time-value|setq|eval-when|locally|symbol-macrolet|flet|macrolet|tagbody|function|multiple-value-call|the|go|multiple-value-prog1|throw|if|progn|unwind-protect|labels|progv|let|quote)$/, p=/^with|^def|^do|^prog|case$|^cond$|bind$|when$|unless$/,a=/^(?:[+\-]?(?:\d+|\d*\.\d+)(?:[efd][+\-]?\d+)?|[+\-]?\d+(?:\/[+\-]?\d+)?|#b[+\-]?[01]+|#o[+\-]?[0-7]+|#x[+\-]?[\da-f]+)/,u=/[^\s'`,@()\[\]";]/,m;return{startState:function(){return{ctx:{prev:null,start:0,indentTo:0},lastType:null,tokenize:k}},token:function(e,q){e.sol()&&"number"!=typeof q.ctx.indentTo&&(q.ctx.indentTo=q.ctx.start+1);m=null;var w=q.tokenize(e,q);"ws"!=m&&(null==q.ctx.indentTo?"symbol"==m&&p.test(e.current())?q.ctx.indentTo= q.ctx.start+A.indentUnit:q.ctx.indentTo="next":"next"==q.ctx.indentTo&&(q.ctx.indentTo=e.column()),q.lastType=m);"open"==m?q.ctx={prev:q.ctx,start:e.column(),indentTo:null}:"close"==m&&(q.ctx=q.ctx.prev||q.ctx);return w},indent:function(e,q){q=e.ctx.indentTo;return"number"==typeof q?q:e.ctx.start+1},closeBrackets:{pairs:'()[]{}""'},lineComment:";;",blockCommentStart:"#|",blockCommentEnd:"|#"}});l.defineMIME("text/x-common-lisp","commonlisp")})}; shadow$provide[490]=function(aa,K,za,t){(function(l){"object"==typeof t&&"object"==typeof za?l(K(475)):"function"==typeof define&&define.amd?define(["../../lib/codemirror"],l):l(CodeMirror)})(function(l){l.defineMode("crystal",function(A){function n(O,X){return new RegExp((X?"":"^")+"(?:"+O.join("|")+")"+(X?"$":"\\b"))}function k(O,X,Q){Q.tokenize.push(O);return O(X,Q)}function b(O,X){if(O.eatSpace())return null;if("\\"!=X.lastToken&&O.match("{%",!1))return k(h("%","%"),O,X);if("\\"!=X.lastToken&& O.match("{{",!1))return k(h("{","}"),O,X);if("#"==O.peek())return O.skipToEnd(),"comment";if(O.match(E)){O.eat(/[?!]/);var Q=O.current();return O.eat(":")?"atom":"."==X.lastToken?"property":G.test(Q)?(F.test(Q)?"fun"==Q&&0<=X.blocks.indexOf("lib")||"def"==Q&&"abstract"==X.lastToken||(X.blocks.push(Q),X.currentIndent+=1):"operator"!=X.lastStyle&&X.lastStyle||!v.test(Q)?"end"==Q&&(X.blocks.pop(),--X.currentIndent):(X.blocks.push(Q),X.currentIndent+=1),ja.hasOwnProperty(Q)&&X.tokenize.push(ja[Q]),"keyword"): B.test(Q)?"atom":"variable"}if(O.eat("@")){if("["==O.peek())return k(f("[","]","meta"),O,X);O.eat("@");O.match(E)||O.match(M);return"variable-2"}if(O.match(M))return"tag";if(O.eat(":")){if(O.eat('"'))return k(u('"',"atom",!1),O,X);if(O.match(E)||O.match(M)||O.match(e)||O.match(q)||O.match(w))return"atom";O.eat(":");return"operator"}if(O.eat('"'))return k(u('"',"string",!0),O,X);if("%"==O.peek()){Q="string";var V=!0;if(O.match("%r")){Q="string-2";var L=O.next()}else if(O.match("%w"))V=!1,L=O.next(); else if(O.match("%q"))V=!1,L=O.next();else if(L=O.match(/^%([^\w\s=])/))L=L[1];else return O.match(/^%[a-zA-Z0-9_\u009F-\uFFFF]*/)?"meta":"operator";da.hasOwnProperty(L)&&(L=da[L]);return k(u(L,Q,V),O,X)}if(Q=O.match(/^<<-('?)([A-Z]\w*)\1/))return k(m(Q[2],!Q[1]),O,X);if(O.eat("'"))return O.match(/^(?:[^']|\\(?:[befnrtv0'"]|[0-7]{3}|u(?:[0-9a-fA-F]{4}|\{[0-9a-fA-F]{1,6}\})))/),O.eat("'"),"atom";if(O.eat("0"))return O.eat("x")?O.match(/^[0-9a-fA-F]+/):O.eat("o")?O.match(/^[0-7]+/):O.eat("b")&&O.match(/^[01]+/), "number";if(O.eat(/^\d/))return O.match(/^\d*(?:\.\d+)?(?:[eE][+-]?\d+)?/),"number";if(O.match(e))return O.eat("\x3d"),"operator";if(O.match(q)||O.match(y))return"operator";if(Q=O.match(/[({[]/,!1))return Q=Q[0],k(f(Q,da[Q],null),O,X);if(O.eat("\\"))return O.next(),"meta";O.next();return null}function f(O,X,Q,V){return function(L,N){if(!V&&L.match(O))return N.tokenize[N.tokenize.length-1]=f(O,X,Q,!0),N.currentIndent+=1,Q;var J=b(L,N);L.current()===X&&(N.tokenize.pop(),--N.currentIndent,J=Q);return J}} function h(O,X,Q){return function(V,L){return!Q&&V.match("{"+O)?(L.currentIndent+=1,L.tokenize[L.tokenize.length-1]=h(O,X,!0),"meta"):V.match(X+"}")?(--L.currentIndent,L.tokenize.pop(),"meta"):b(V,L)}}function p(O,X){if(O.eatSpace())return null;O.match(E)?O.eat(/[!?]/):O.match(e)||O.match(q)||O.match(w);X.tokenize.pop();return"def"}function a(O,X){if(O.eatSpace())return null;O.match(M);X.tokenize.pop();return"def"}function u(O,X,Q){return function(V,L){for(var N=!1;V.peek();)if(N)V.next(),N=!1;else{if(V.match("{%", !1)){L.tokenize.push(h("%","%"));break}if(V.match("{{",!1)){L.tokenize.push(h("{","}"));break}if(Q&&V.match("#{",!1)){L.tokenize.push(f("#{","}","meta"));break}N=V.next();if(N==O){L.tokenize.pop();break}N=Q&&"\\"==N}return X}}function m(O,X){return function(Q,V){if(Q.sol()&&(Q.eatSpace(),Q.match(O)))return V.tokenize.pop(),"string";for(var L=!1;Q.peek();)if(L)Q.next(),L=!1;else{if(Q.match("{%",!1)){V.tokenize.push(h("%","%"));break}if(Q.match("{{",!1)){V.tokenize.push(h("{","}"));break}if(X&&Q.match("#{", !1)){V.tokenize.push(f("#{","}","meta"));break}L=X&&"\\"==Q.next()}return"string"}}var e=/^(?:[-+/%|&^]|\*\*?|[<>]{2})/,q=/^(?:[=!]~|===|<=>|[<>=!]=?|[|&]{2}|~)/,w=/^(?:\[\][?=]?)/,y=/^(?:\.(?:\.{2})?|->|[?:])/,E=/^[a-z_\u009F-\uFFFF][a-zA-Z0-9_\u009F-\uFFFF]*/,M=/^[A-Z_\u009F-\uFFFF][a-zA-Z0-9_\u009F-\uFFFF]*/,G=n("abstract alias as asm begin break case class def do else elsif end ensure enum extend for fun if include instance_sizeof lib macro module next of out pointerof private protected rescue return require select sizeof struct super then type typeof uninitialized union unless until when while with yield __DIR__ __END_LINE__ __FILE__ __LINE__".split(" ")), B=n(["true","false","nil","self"]),F=n("def fun macro class module struct lib enum union do for".split(" ")),v=n("if unless case while until begin then".split(" ")),T=["end","else","elsif","rescue","ensure"],ca=n(T),W=["\\)","\\}","\\]"],ia=new RegExp("^(?:"+W.join("|")+")$"),ja={def:p,fun:p,macro:function(O,X){if(O.eatSpace())return null;var Q;if(Q=O.match(E)){if("def"==Q)return"keyword";O.eat(/[?!]/)}X.tokenize.pop();return"def"},"class":a,module:a,struct:a,lib:a,"enum":a,union:a},da={"[":"]","{":"}", "(":")","\x3c":"\x3e"};return{startState:function(){return{tokenize:[b],currentIndent:0,lastToken:null,lastStyle:null,blocks:[]}},token:function(O,X){var Q=X.tokenize[X.tokenize.length-1](O,X);O=O.current();Q&&"comment"!=Q&&(X.lastToken=O,X.lastStyle=Q);return Q},indent:function(O,X){X=X.replace(/^\s*(?:\{%)?\s*|\s*(?:%\})?\s*$/g,"");return ca.test(X)||ia.test(X)?A.indentUnit*(O.currentIndent-1):A.indentUnit*O.currentIndent},fold:"indent",electricInput:n(W.concat(T),!0),lineComment:"#"}});l.defineMIME("text/x-crystal", "crystal")})}; shadow$provide[491]=function(aa,K,za,t){(function(l){"object"==typeof t&&"object"==typeof za?l(K(475)):"function"==typeof define&&define.amd?define(["../../lib/codemirror"],l):l(CodeMirror)})(function(l){function A(T){for(var ca={},W=0;W*\/]/.test(Zb)?W(null,"select-op"):"."==Zb&&Db.match(/^-?[_a-z][_a-z0-9-]*/i)?W("qualifier","qualifier"):/[:;{}\[\]\(\)]/.test(Zb)?W(null,Zb):Db.match(/[\w-.]+(?=\()/)?(/^(url(-prefix)?|domain|regexp)$/.test(Db.current().toLowerCase())&&(ec.tokenize=da),W("variable callee","variable")): /[\w\\\-]/.test(Zb)?(Db.eatWhile(/[\w\\\-]/),W("property","word")):W(null,null)}function ja(Db){return function(ec,Zb){for(var Ab=!1,hb;null!=(hb=ec.next());){if(hb==Db&&!Ab){")"==Db&&ec.backUp(1);break}Ab=!Ab&&"\\"==hb}if(hb==Db||!Ab&&")"!=Db)Zb.tokenize=null;return W("string","string")}}function da(Db,ec){Db.next();Db.match(/\s*["')]/,!1)?ec.tokenize=null:ec.tokenize=ja(")");return W(null,"(")}function O(Db,ec,Zb){this.type=Db;this.indent=ec;this.prev=Zb}function X(Db,ec,Zb,Ab){Db.context=new O(Zb, ec.indentation()+(!1===Ab?0:J),Db.context);return Zb}function Q(Db){Db.context.prev&&(Db.context=Db.context.prev);return Db.context.type}function V(Db,ec,Zb,Ab){for(Ab=Ab||1;0