1import{b$ as Q}from"./index-4df07b51.js";function q(A,B){for(var y=0;y<B.length;y++){const m=B[y];if(typeof m!="string"&&!Array.isArray(m)){for(const $ in m)if($!=="default"&&!($ in A)){const L=Object.getOwnPropertyDescriptor(m,$);L&&Object.defineProperty(A,$,L.get?L:{enumerable:!0,get:()=>m[$]})}}}return Object.freeze(Object.defineProperty(A,Symbol.toStringTag,{value:"Module"}))}var Z={exports:{}};(function(A,B){ace.define("ace/snippets",["require","exports","module","ace/lib/dom","ace/lib/oop","ace/lib/event_emitter","ace/lib/lang","ace/range","ace/range_list","ace/keyboard/hash_handler","ace/tokenizer","ace/clipboard","ace/editor"],function(y,m,$){var L=y("./lib/dom"),D=y("./lib/oop"),K=y("./lib/event_emitter").EventEmitter,H=y("./lib/lang"),N=y("./range").Range,T=y("./range_list").RangeList,O=y("./keyboard/hash_handler").HashHandler,U=y("./tokenizer").Tokenizer,P=y("./clipboard"),R={CURRENT_WORD:function(i){return i.session.getTextRange(i.session.getWordRange())},SELECTION:function(i,e,t){var a=i.session.getTextRange();return t?a.replace(/\n\r?([ \t]*\S)/g,` 2`+t+"$1"):a},CURRENT_LINE:function(i){return i.session.getLine(i.getCursorPosition().row)},PREV_LINE:function(i){return i.session.getLine(i.getCursorPosition().row-1)},LINE_INDEX:function(i){return i.getCursorPosition().row},LINE_NUMBER:function(i){return i.getCursorPosition().row+1},SOFT_TABS:function(i){return i.session.getUseSoftTabs()?"YES":"NO"},TAB_SIZE:function(i){return i.session.getTabSize()},CLIPBOARD:function(i){return P.getText&&P.getText()},FILENAME:function(i){return/[^/\\]*$/.exec(this.FILEPATH(i))[0]},FILENAME_BASE:function(i){return/[^/\\]*$/.exec(this.FILEPATH(i))[0].replace(/\.[^.]*$/,"")},DIRECTORY:function(i){return this.FILEPATH(i).replace(/[^/\\]*$/,"")},FILEPATH:function(i){return"/not implemented.txt"},WORKSPACE_NAME:function(){return"Unknown"},FULLNAME:function(){return"Unknown"},BLOCK_COMMENT_START:function(i){var e=i.session.$mode||{};return e.blockComment&&e.blockComment.start||""},BLOCK_COMMENT_END:function(i){var e=i.session.$mode||{};return e.blockComment&&e.blockComment.end||""},LINE_COMMENT:function(i){var e=i.session.$mode||{};return e.lineCommentStart||""},CURRENT_YEAR:E.bind(null,{year:"numeric"}),CURRENT_YEAR_SHORT:E.bind(null,{year:"2-digit"}),CURRENT_MONTH:E.bind(null,{month:"numeric"}),CURRENT_MONTH_NAME:E.bind(null,{month:"long"}),CURRENT_MONTH_NAME_SHORT:E.bind(null,{month:"short"}),CURRENT_DATE:E.bind(null,{day:"2-digit"}),CURRENT_DAY_NAME:E.bind(null,{weekday:"long"}),CURRENT_DAY_NAME_SHORT:E.bind(null,{weekday:"short"}),CURRENT_HOUR:E.bind(null,{hour:"2-digit",hour12:!1}),CURRENT_MINUTE:E.bind(null,{minute:"2-digit"}),CURRENT_SECOND:E.bind(null,{second:"2-digit"})};R.SELECTED_TEXT=R.SELECTION;function E(i){var e=new Date().toLocaleString("en-us",i);return e.length==1?"0"+e:e}var F=function(){function i(){this.snippetMap={},this.snippetNameMap={},this.variables=R}return i.prototype.getTokenizer=function(){return i.$tokenizer||this.createTokenizer()},i.prototype.createTokenizer=function(){function e(r){return r=r.substr(1),/^\d+$/.test(r)?[{tabstopId:parseInt(r,10)}]:[{text:r}]}function t(r){return"(?:[^\\\\"+r+"]|\\\\.)"}var a={regex:"/("+t("/")+"+)/",onMatch:function(r,s,c){var n=c[0];return n.fmtString=!0,n.guard=r.slice(1,-1),n.flag="",""},next:"formatString"};return i.$tokenizer=new U({start:[{regex:/\\./,onMatch:function(r,s,c){var n=r[1];return(n=="}"&&c.length||"`$\\".indexOf(n)!=-1)&&(r=n),[r]}},{regex:/}/,onMatch:function(r,s,c){return[c.length?c.shift():r]}},{regex:/\$(?:\d+|\w+)/,onMatch:e},{regex:/\$\{[\dA-Z_a-z]+/,onMatch:function(r,s,c){var n=e(r.substr(1));return c.unshift(n[0]),n},next:"snippetVar"},{regex:/\n/,token:"newline",merge:!1}],snippetVar:[{regex:"\\|"+t("\\|")+"*\\|",onMatch:function(r,s,c){var n=r.slice(1,-1).replace(/\\[,|\\]|,/g,function(p){return p.length==2?p[1]:"\0"}).split("\0").map(function(p){return{value:p}});return c[0].choices=n,[n[0]]},next:"start"},a,{regex:"([^:}\\\\]|\\\\.)*:?",token:"",next:"start"}],formatString:[{regex:/:/,onMatch:function(r,s,c){return c.length&&c[0].expectElse?(c[0].expectElse=!1,c[0].ifEnd={elseEnd:c[0]},[c[0].ifEnd]):":"}},{regex:/\\./,onMatch:function(r,s,c){var n=r[1];return n=="}"&&c.length||"`$\\".indexOf(n)!=-1?r=n:n=="n"?r=`
3`:n=="t"?r=" ":"ulULE".indexOf(n)!=-1&&(r={changeCase:n,local:n>"a"}),[r]}},{regex:"/\\w*}",onMatch:function(r,s,c){var n=c.shift();return n&&(n.flag=r.slice(1,-1)),this.next=n&&n.tabstopId?"start":"",[n||r]},next:"start"},{regex:/\$(?:\d+|\w+)/,onMatch:function(r,s,c){return[{text:r.slice(1)}]}},{regex:/\${\w+/,onMatch:function(r,s,c){var n={text:r.slice(2)};return c.unshift(n),[n]},next:"formatStringVar"},{regex:/\n/,token:"newline",merge:!1},{regex:/}/,onMatch:function(r,s,c){var n=c.shift();return this.next=n&&n.tabstopId?"start":"",[n||r]},next:"start"}],formatStringVar:[{regex:/:\/\w+}/,onMatch:function(r,s,c){var n=c[0];return n.formatFunction=r.slice(2,-1),[c.shift()]},next:"formatString"},a,{regex:/:[\?\-+]?/,onMatch:function(r,s,c){r[1]=="+"&&(c[0].ifEnd=c[0]),r[1]=="?"&&(c[0].expectElse=!0)},next:"formatString"},{regex:"([^:}\\\\]|\\\\.)*:?",token:"",next:"formatString"}]}),i.$tokenizer},i.prototype.tokenizeTmSnippet=function(e,t){return this.getTokenizer().getLineTokens(e,t).tokens.map(function(a){return a.value||a})},i.prototype.getVariableValue=function(e,t,a){if(/^\d+$/.test(t))return(this.variables.__||{})[t]||"";if(/^[A-Z]\d+$/.test(t))return(this.variables[t[0]+"__"]||{})[t.substr(1)]||"";if(t=t.replace(/^TM_/,""),!this.variables.hasOwnProperty(t))return"";var r=this.variables[t];return typeof r=="function"&&(r=this.variables[t](e,t,a)),r??""},i.prototype.tmStrFormat=function(e,t,a){if(!t.fmt)return e;var r=t.flag||"",s=t.guard;s=new RegExp(s,r.replace(/[^gim]/g,""));var c=typeof t.fmt=="string"?this.tokenizeTmSnippet(t.fmt,"formatString"):t.fmt,n=this,p=e.replace(s,function(){var o=n.variables.__;n.variables.__=[].slice.call(arguments);for(var h=n.resolveVariables(c,a),v="E",u=0;u<h.length;u++){var x=h[u];if(typeof x=="object")if(h[u]="",x.changeCase&&x.local){var S=h[u+1];S&&typeof S=="string"&&(x.changeCase=="u"?h[u]=S[0].toUpperCase():h[u]=S[0].toLowerCase(),h[u+1]=S.substr(1))}else x.changeCase&&(v=x.changeCase);else v=="U"?h[u]=x.toUpperCase():v=="L"&&(h[u]=x.toLowerCase())}return n.variables.__=o,h.join("")});return p},i.prototype.tmFormatFunction=function(e,t,a){return t.formatFunction=="upcase"?e.toUpperCase():t.formatFunction=="downcase"?e.toLowerCase():e},i.prototype.resolveVariables=function(e,t){for(var a=[],r="",s=!0,c=0;c<e.length;c++){var n=e[c];if(typeof n=="string"){a.push(n),n==` 4`?(s=!0,r=""):s&&(r=/^\t*/.exec(n)[0],s=/\S/.test(n));continue}if(n){if(s=!1,n.fmtString){var p=e.indexOf(n,c+1);p==-1&&(p=e.length),n.fmt=e.slice(c+1,p),c=p}if(n.text){var o=this.getVariableValue(t,n.text,r)+"";n.fmtString&&(o=this.tmStrFormat(o,n,t)),n.formatFunction&&(o=this.tmFormatFunction(o,n,t)),o&&!n.ifEnd?(a.push(o),h(n)):!o&&n.ifEnd&&h(n.ifEnd)}else n.elseEnd?h(n.elseEnd):(n.tabstopId!=null||n.changeCase!=null)&&a.push(n)}}function h(v){var u=e.indexOf(v,c+1);u!=-1&&(c=u)}return a},i.prototype.getDisplayTextForSnippet=function(e,t){var a=l.call(this,e,t);return a.text},i.prototype.insertSnippetForSelection=function(e,t,a){a===void 0&&(a={});var r=l.call(this,e,t,a),s=e.getSelectionRange(),c=e.session.replace(s,r.text),n=new f(e),p=e.inVirtualSelectionMode&&e.selection.index;n.addTabstops(r.tabstops,s.start,c,p)},i.prototype.insertSnippet=function(e,t,a){a===void 0&&(a={});var r=this;if(e.inVirtualSelectionMode)return r.insertSnippetForSelection(e,t,a);e.forEachSelection(function(){r.insertSnippetForSelection(e,t,a)},null,{keepOrder:!0}),e.tabstopManager&&e.tabstopManager.tabNext()},i.prototype.$getScope=function(e){var t=e.session.$mode.$id||"";if(t=t.split("/").pop(),t==="html"||t==="php"){t==="php"&&!e.session.$mode.inlinePhp&&(t="html");var a=e.getCursorPosition(),r=e.session.getState(a.row);typeof r=="object"&&(r=r[0]),r.substring&&(r.substring(0,3)=="js-"?t="javascript":r.substring(0,4)=="css-"?t="css":r.substring(0,4)=="php-"&&(t="php"))}return t},i.prototype.getActiveScopes=function(e){var t=this.$getScope(e),a=[t],r=this.snippetMap;return r[t]&&r[t].includeScopes&&a.push.apply(a,r[t].includeScopes),a.push("_"),a},i.prototype.expandWithTab=function(e,t){var a=this,r=e.forEachSelection(function(){return a.expandSnippetForSelection(e,t)},null,{keepOrder:!0});return r&&e.tabstopManager&&e.tabstopManager.tabNext(),r},i.prototype.expandSnippetForSelection=function(e,t){var a=e.getCursorPosition(),r=e.session.getLine(a.row),s=r.substring(0,a.column),c=r.substr(a.column),n=this.snippetMap,p;return this.getActiveScopes(e).some(function(o){var h=n[o];return h&&(p=this.findMatchingSnippet(h,s,c)),!!p},this),p?(t&&t.dryRun||(e.session.doc.removeInLine(a.row,a.column-p.replaceBefore.length,a.column+
4p.replaceAfter.length),this.variables.M__=p.matchBefore,this.variables.T__=p.matchAfter,this.insertSnippetForSelection(e,p.content),this.variables.M__=this.variables.T__=null),!0):!1},i.prototype.findMatchingSnippet=function(e,t,a){for(var r=e.length;r--;){var s=e[r];if(!(s.startRe&&!s.startRe.test(t))&&!(s.endRe&&!s.endRe.test(a))&&!(!s.startRe&&!s.endRe))return s.matchBefore=s.startRe?s.startRe.exec(t):[""],s.matchAfter=s.endRe?s.endRe.exec(a):[""],s.replaceBefore=s.triggerRe?s.triggerRe.exec(t)[0]:"",s.replaceAfter=s.endTriggerRe?s.endTriggerRe.exec(a)[0]:"",s}},i.prototype.register=function(e,t){var a=this.snippetMap,r=this.snippetNameMap,s=this;e||(e=[]);function c(o){return o&&!/^\^?\(.*\)\$?$|^\\b$/.test(o)&&(o="(?:"+o+")"),o||""}function n(o,h,v){return o=c(o),h=c(h),v?(o=h+o,o&&o[o.length-1]!="$"&&(o=o+"$")):(o=o+h,o&&o[0]!="^"&&(o="^"+o)),new RegExp(o)}function p(o){o.scope||(o.scope=t||"_"),t=o.scope,a[t]||(a[t]=[],r[t]={});var h=r[t];if(o.name){var v=h[o.name];v&&s.unregister(v),h[o.name]=o}a[t].push(o),o.prefix&&(o.tabTrigger=o.prefix),!o.content&&o.body&&(o.content=Array.isArray(o.body)?o.body.join(` 5`):o.body),o.tabTrigger&&!o.trigger&&(!o.guard&&/^\w/.test(o.tabTrigger)&&(o.guard="\\b"),o.trigger=H.escapeRegExp(o.tabTrigger)),!(!o.trigger&&!o.guard&&!o.endTrigger&&!o.endGuard)&&(o.startRe=n(o.trigger,o.guard,!0),o.triggerRe=new RegExp(o.trigger),o.endRe=n(o.endTrigger,o.endGuard,!0),o.endTriggerRe=new RegExp(o.endTrigger))}Array.isArray(e)?e.forEach(p):Object.keys(e).forEach(function(o){p(e[o])}),this._signal("registerSnippets",{scope:t})},i.prototype.unregister=function(e,t){var a=this.snippetMap,r=this.snippetNameMap;function s(c){var n=r[c.scope||t];if(n&&n[c.name]){delete n[c.name];var p=a[c.scope||t],o=p&&p.indexOf(c);o>=0&&p.splice(o,1)}}e.content?s(e):Array.isArray(e)&&e.forEach(s)},i.prototype.parseSnippetFile=function(e){e=e.replace(/\r/g,"");for(var t=[],a={},r=/^#.*|^({[\s\S]*})\s*$|^(\S+) (.*)$|^((?:\n*\t.*)+)/gm,s;s=r.exec(e);){if(s[1])try{a=JSON.parse(s[1]),t.push(a)}catch{}if(s[4])a.content=s[4].replace(/^\t/gm,""),t.push(a),a={};else{var c=s[2],n=s[3];if(c=="regex"){var p=/\/((?:[^\/\\]|\\.)*)|$/g;a.guard=p.exec(n)[1],a.trigger=p.exec(n)[1],a.endTrigger=p.exec(n)[1],a.endGuard=p.exec(n)[1]}else c=="snippet"?(a.tabTrigger=n.match(/^\S*/)[0],a.name||(a.name=n)):c&&(a[c]=n)}}return t},i.prototype.getSnippetByName=function(e,t){var a=this.snippetNameMap,r;return this.getActiveScopes(t).some(function(s){var c=a[s];return c&&(r=c[e]),!!r},this),r},i}();D.implement(F.prototype,K);var l=function(i,e,t){t===void 0&&(t={});var a=i.getCursorPosition(),r=i.session.getLine(a.row),s=i.session.getTabString(),c=r.match(/^\s*/)[0];a.column<c.length&&(c=c.slice(0,a.column)),e=e.replace(/\r/g,"");var n=this.tokenizeTmSnippet(e);n=this.resolveVariables(n,i),n=n.map(function(b){return b==` 6`&&!t.excludeExtraIndent?b+c:typeof b=="string"?b.replace(/\t/g,s):b});var p=[];n.forEach(function(b,w){if(typeof b=="object"){var k=b.tabstopId,_=p[k];if(_||(_=p[k]=[],_.index=k,_.value="",_.parents={}),_.indexOf(b)===-1){b.choices&&!_.choices&&(_.choices=b.choices),_.push(b);var z=n.indexOf(b,w+1);if(z!==-1){var j=n.slice(w+1,z),X=j.some(function(J){return typeof J=="object"});X&&!_.value?_.value=j:j.length&&(!_.value||typeof _.value!="string")&&(_.value=j.join(""))}}}}),p.forEach(function(b){b.length=0});var o={};function h(b){for(var w=[],k=0;k<b.length;k++){var _=b[k];if(typeof _=="object"){if(o[_.tabstopId])continue;var z=b.lastIndexOf(_,k-1);_=w[z]||{tabstopId:_.tabstopId}}w[k]=_}return w}for(var v=0;v<n.length;v++){var u=n[v];if(typeof u=="object"){var x=u.tabstopId,S=p[x],C=n.indexOf(u,v+1);if(o[x]){o[x]===u&&(delete o[x],Object.keys(o).forEach(function(b){S.parents[b]=!0}));continue}o[x]=u;var I=S.value;typeof I!="string"?I=h(I):u.fmt&&(I=this.tmStrFormat(I,u,i)),n.splice.apply(n,[v+1,Math.max(0,C-v)].concat(I,u)),S.indexOf(u)===-1&&S.push(u)}}var Y=0,V=0,W="";return n.forEach(function(b){if(typeof b=="string"){var w=b.split(` 7`);w.length>1?(V=w[w.length-1].length,Y+=w.length-1):V+=b.length,W+=b}else b&&(b.start?b.end={row:Y,column:V}:b.start={row:Y,column:V})}),{text:W,tabstops:p,tokens:n}},f=function(){function i(e){if(this.index=0,this.ranges=[],this.tabstops=[],e.tabstopManager)return e.tabstopManager;e.tabstopManager=this,this.$onChange=this.onChange.bind(this),this.$onChangeSelection=H.delayedCall(this.onChangeSelection.bind(this)).schedule,this.$onChangeSession=this.onChangeSession.bind(this),this.$onAfterExec=this.onAfterExec.bind(this),this.attach(e)}return i.prototype.attach=function(e){this.$openTabstops=null,this.selectedTabstop=null,this.editor=e,this.session=e.session,this.editor.on("change",this.$onChange),this.editor.on("changeSelection",this.$onChangeSelection),this.editor.on("changeSession",this.$onChangeSession),this.editor.commands.on("afterExec",this.$onAfterExec),this.editor.keyBinding.addKeyboardHandler(this.keyboardHandler)},i.prototype.detach=function(){this.tabstops.forEach(this.removeTabstopMarkers,this),this.ranges.length=0,this.tabstops.length=0,this.selectedTabstop=null,this.editor.off("change",this.$onChange),this.editor.off("changeSelection",this.$onChangeSelection),this.editor.off("changeSession",this.$onChangeSession),this.editor.commands.off("after
7Exec",this.$onAfterExec),this.editor.keyBinding.removeKeyboardHandler(this.keyboardHandler),this.editor.tabstopManager=null,this.session=null,this.editor=null},i.prototype.onChange=function(e){for(var t=e.action[0]=="r",a=this.selectedTabstop||{},r=a.parents||{},s=this.tabstops.slice(),c=0;c<s.length;c++){var n=s[c],p=n==a||r[n.index];if(n.rangeList.$bias=p?0:1,e.action=="remove"&&n!==a){var o=n.parents&&n.parents[a.index],h=n.rangeList.pointIndex(e.start,o);h=h<0?-h-1:h+1;var v=n.rangeList.pointIndex(e.end,o);v=v<0?-v-1:v-1;for(var u=n.rangeList.ranges.slice(h,v),x=0;x<u.length;x++)this.removeRange(u[x])}n.rangeList.$onChange(e)}var S=this.session;!this.$inChange&&t&&S.getLength()==1&&!S.getValue()&&this.detach()},i.prototype.updateLinkedFields=function(){var e=this.selectedTabstop;if(!(!e||!e.hasLinkedRanges||!e.firstNonLinked)){this.$inChange=!0;for(var t=this.session,a=t.getTextRange(e.firstNonLinked),r=0;r<e.length;r++){var s=e[r];if(s.linked){var c=s.original,n=m.snippetManager.tmStrFormat(a,c,this.editor);t.replace(s,n)}}this.$inChange=!1}},i.prototype.onAfterExec=function(e){e.command&&!e.command.readOnly&&this.updateLinkedFields()},i.prototype.onChangeSelection=function(){if(this.editor){for(var e=this.editor.selection.lead,t=this.editor.selection.anchor,a=this.editor.selection.isEmpty(),r=0;r<this.ranges.length;r++)if(!this.ranges[r].linked){var s=this.ranges[r].contains(e.row,e.column),c=a||this.ranges[r].contains(t.row,t.column);if(s&&c)return}this.detach()}},i.prototype.onChangeSession=function(){this.detach()},i.prototype.tabNext=function(e){var t=this.tabstops.length,a=this.index+(e||1);a=Math.min(Math.max(a,1),t),a==t&&(a=0),this.selectTabstop(a),this.updateTabstopMarkers(),a===0&&this.detach()},i.prototype.selectTabstop=function(e){this.$openTabstops=null;var t=this.tabstops[this.index];if(t&&this.addTabstopMarkers(t),this.index=e,t=this.tabstops[this.index],!(!t||!t.length)){this.selectedTabstop=t;var a=t.firstNonLinked||t;if(t.choices&&(a.cursor=a.start),this.editor.inVirtualSelectionMode)this.editor.selection.fromOrientedRange(a);else{var r=this.editor.multiSelect;r.toSingleRange(a);for(var s=0;s<t.length;s++)t.hasLinkedRanges&&t[s].linked||r.addRange(t[s].clone(),!0)}this.editor.keyBinding.addKeyboardHandler(this.keyboardHandler),this.selectedTabstop&&this.selectedTabstop.choices&&this.editor.execCommand("startAutocomplete",{matches:this.selectedTabstop.choices})}},i.prototype.addTabstops=function(e,t,a){var r=this.useLink||!this.editor.getOption("enableMultiselect");if(this.$openTabstops||(this.$openTabstops=[]),!e[0]){var s=N.fromPoints(a,a);g(s.start,t),g(s.end,t),e[0]=[s],e[0].index=0}var c=this.index,n=[c+1,0],p=this.ranges,o=this.snippetId=(this.snippetId||0)+1;e.forEach(function(h,v){var u=this.$openTabstops[v]||h;u.snippetId=o;for(var x=0;x<h.length;x++){var S=h[x],C=N.fromPoints(S.start,S.end||S.start);d(C.start,t),d(C.end,t),C.original=S,C.tabstop=u,p.push(C),u!=h?u.unshift(C):u[x]=C,S.fmtString||u.firstNonLinked&&r?(C.linked=!0,u.hasLinkedRanges=!0):u.firstNonLinked||(u.firstNonLinked=C)}u.firstNonLinked||(u.hasLinkedRanges=!1),u===h&&(n.push(u),this.$openTabstops[v]=u),this.addTabstopMarkers(u),u.rangeList=u.rangeList||new T,u.rangeList.$bias=0,u.rangeList.addList(u)},this),n.length>2&&(this.tabstops.length&&n.push(n.splice(2,1)[0]),this.tabstops.splice.apply(this.tabstops,n))},i.prototype.addTabstopMarkers=function(e){var t=this.session;e.forEach(function(a){a.markerId||(a.markerId=t.addMarker(a,"ace_snippet-marker","text"))})},i.prototype.removeTabstopMarkers=function(e){var t=this.session;e.forEach(function(a){t.removeMarker(a.markerId),a.markerId=null})},i.prototype.updateTabstopMarkers=function(){if(this.selectedTabstop){var e=this.selectedTabstop.snippetId;this.selectedTabstop.index===0&&e--,this.tabstops.forEach(function(t){t.snippetId===e?this.addTabstopMarkers(t):this.removeTabstopMarkers(t)},this)}},i.prototype.removeRange=function(e){var t=e.tabstop.indexOf(e);t!=-1&&e.tabstop.splice(t,1),t=this.ranges.indexOf(e),t!=-1&&this.ranges.splice(t,1),t=e.tabstop.rangeList.ranges.indexOf(e),t!=-1&&e.tabstop.splice(t,1),this.session.removeMarker(e.markerId),e.tabstop.length||(t=this.tabstops.indexOf(e.tabstop),t!=-1&&this.tabstops.splice(t,1),this.tabstops.length||this.detach())},i}();f.prototype.keyboardHandler=new O,f.prototype.keyboardHandler.bindKeys({Tab:function(i){m.snippetManager&&m.snippetManager.expandWithTab(i)||(i.tabstopManager.tabNext(1),i.renderer.scrollCursorIntoView())},"Shift-Tab":function(i){i.tabstopManager.tabNext(-1),i.renderer.scrollCursorIntoView()},Esc:function(i){i.tabstopManager.detach()}});var d=function(i,e){i.row==0&&(i.column+=e.column),i.row+=e.row},g=function(i,e){i.row==e.row&&(i.column-=e.column),i.row-=e.row};L.importCssString(` 8.ace_snippet-marker { 9 -moz-box-sizing: border-box; 10 box-sizing: border-box; 11 background: rgba(194, 193, 208, 0.09); 12 border: 1px dotted rgba(211, 208, 235, 0.62); 13 position: absolute; 14}`,"snippets.css",!1),m.snippetManager=new F;var M=y("./editor").Editor;(function(){this.insertSnippet=function(i,e){return m.snippetManager.insertSnippet(this,i,e)},this.expandSnippet=function(i){return m.snippetManager.expandWithTab(this,i)}}).call(M.prototype)}),ace.define("ace/ext/emmet",["require","exports","module","ace/keyboard/hash_handler","ace/editor","ace/snippets","ace/range","ace/config","resources","resources","tabStops","resources","utils","actions"],function(y,m,$){var L=y("../keyboard/hash_handler").HashHandler,D=y("../editor").Editor,K=y("../snippets").snippetManager,H=y("../range").Range,N=y("../config"),T,O,U=function(){function l(){}return l.prototype.setupContext=function(f){this.ace=f,this.indentation=f.session.getTabString(),T||(T=window.emmet);var d=T.resources||T.require("resources");d.setVariable("indentation",this.indentation),this.$syntax=null,this.$syntax=this.getSyntax()},l.prototype.getSelectionRange=function(){var f=this.ace.getSelectionRange(),d=this.ace.session.doc;return{start:d.positionToIndex(f.start),end:d.positionToIndex(f.end)}},l.prototype.createSelection=function(f,d){var g=this.ace.session.doc;this.ace.selection.setRange({start:g.indexToPosition(f),end:g.indexToPosition(d)})},l.prototype.getCurrentLineRange=function(){var f=this.ace,d=f.getCursorPosition().row,g=f.session.getLine(d).length,M=f.session.doc.positionToIndex({row:d,column:0});return{start:M,end:M+g}},l.prototype.getCaretPos=function(){var f=this.ace.getCursorPosition();return this.ace.session.doc.positionToIndex(f)},l.prototype.setCaretPos=function(f){var d=this.ace.session.doc.indexToPosition(f);this.ace.selection.moveToPosition(d)},l.prototype.getCurrentLine=function(){var f=this.ace.getCursorPosition().row;return this.ace.session.getLine(f)},l.prototype.replaceContent=function(f,d,g,M){g==null&&(g=d??this.getContent().length),d==null&&(d=0);var i=this.ace,e=i.session.doc,t=H.fromPoints(e.indexToPosition(d),e.indexToPosition(g));i.session.remove(t),t.end=t.start,f=this.$updateTabstops(f),K.insertSnippet(i,f)},l.prototype.getContent=function(){return this.ace.getValue()},l.prototype.getSyntax=function(){if(this.$syntax)return this.$syntax;var f=this.ace.session.$modeId.split("/").pop();if(f=="html"||f=="php"){var d=this.ace.getCursorPosition(),g=this.ace.session.getState(d.row);typeof g!="string"&&(g=g[0]),g&&(g=g.split("-"),g.length>1?f=g[0]:f=="php"&&(f="html"))}return f},l.prototype.getProfileName=function(){var f=T.resources||T.require("resources");switch(this.getSyntax()){case"css":return"css";case"xml":case"xsl":return"xml";case"html":var d=f.getVariable("profile");return d||(d=this.ace.session.getLines(0,2).join("").search(/<!DOCTYPE[^>]+XHTML/i)!=-1?"xhtml":"html"),d;default:var g=this.ace.session.$mode;return g.emmetConfig&&g.emmetConfig.profile||"xhtml"}},l.prototype.prompt=function(f){return prompt(f)},l.prototype.getSelection=function(){return this.ace.session.getTextRange()},l.prototype.getFilePath=function(){return""},l.prototype.$updateTabstops=function(f){var d=1e3,g=0,M=null,i=T.tabStops||T.require("tabStops"),e=T.resources||T.require("resources"),t=e.getVocabulary("user"),a={tabstop:function(s){var c=parseInt(s.group,10),n=c===0;n?c=++g:c+=d;var p=s.placeholder;p&&(p=i.processText(p,a));var o="${"+c+(p?":"+p:"")+"}";return n&&(M=[s.start,o]),o},escape:function(s){return s=="$"?"\\$":s=="\\"?"\\\\":s}};if(f=i.processText(f,a),t.variables.insert_final_tabstop&&!/\$\{0\}$/.test(f))f+="${0}";else if(M){var r=T.utils?T.utils.common:T.require("utils");f=r.replaceSubstring(f,"${0}",M[0],M[1])}return f},l}
14(),P={expand_abbreviation:{mac:"ctrl+alt+e",win:"alt+e"},match_pair_outward:{mac:"ctrl+d",win:"ctrl+,"},match_pair_inward:{mac:"ctrl+j",win:"ctrl+shift+0"},matching_pair:{mac:"ctrl+alt+j",win:"alt+j"},next_edit_point:"alt+right",prev_edit_point:"alt+left",toggle_comment:{mac:"command+/",win:"ctrl+/"},split_join_tag:{mac:"shift+command+'",win:"shift+ctrl+`"},remove_tag:{mac:"command+'",win:"shift+ctrl+;"},evaluate_math_expression:{mac:"shift+command+y",win:"shift+ctrl+y"},increment_number_by_1:"ctrl+up",decrement_number_by_1:"ctrl+down",increment_number_by_01:"alt+up",decrement_number_by_01:"alt+down",increment_number_by_10:{mac:"alt+command+up",win:"shift+alt+up"},decrement_number_by_10:{mac:"alt+command+down",win:"shift+alt+down"},select_next_item:{mac:"shift+command+.",win:"shift+ctrl+."},select_previous_item:{mac:"shift+command+,",win:"shift+ctrl+,"},reflect_css_value:{mac:"shift+command+r",win:"shift+ctrl+r"},encode_decode_data_url:{mac:"shift+ctrl+d",win:"ctrl+'"},expand_abbreviation_with_tab:"Tab",wrap_with_abbreviation:{mac:"shift+ctrl+a",win:"shift+ctrl+a"}},R=new U;m.commands=new L,m.runEmmetCommand=function l(f){if(this.action=="expand_abbreviation_with_tab"){if(!f.selection.isEmpty())return!1;var d=f.selection.lead,g=f.session.getTokenAt(d.row,d.column);if(g&&/\btag\b/.test(g.type))return!1}try{R.setupContext(f);var M=T.actions||T.require("actions");if(this.action=="wrap_with_abbreviation")return setTimeout(function(){M.run("wrap_with_abbreviation",R)},0);var i=M.run(this.action,R)}catch(t){if(!T){var e=m.load(l.bind(this,f));return this.action=="expand_abbreviation_with_tab"?!1:e}f._signal("changeStatus",typeof t=="string"?t:t.message),N.warn(t),i=!1}return i};for(var E in P)m.commands.addCommand({name:"emmet:"+E,action:E,bindKey:P[E],exec:m.runEmmetCommand,multiSelectAction:"forEach"});m.updateCommands=function(l,f){f?l.keyBinding.addKeyboardHandler(m.commands):l.keyBinding.removeKeyboardHandler(m.commands)},m.isSupportedMode=function(l){if(!l)return!1;if(l.emmetConfig)return!0;var f=l.$id||l;return/css|less|scss|sass|stylus|html|php|twig|ejs|handlebars/.test(f)},m.isAvailable=function(l,f){if(/(evaluate_math_expression|expand_abbreviation)$/.test(f))return!0;var d=l.session.$mode,g=m.isSupportedMode(d);if(g&&d.$modes)try{R.setupContext(l),/js|php/.test(R.getSyntax())&&(g=!1)}catch{}return g};var F=function(l,f){var d=f;if(d){var g=m.isSupportedMode(d.session.$mode);l.enableEmmet===!1&&(g=!1),g&&m.load(),m.updateCommands(d,g)}};m.load=function(l){return typeof O!="string"?(N.warn("script for emmet-core is not loaded"),!1):(N.loadModule(O,function(){O=null,l&&l()}),!0)},m.AceEmmetEditor=U,N.defineOptions(D.prototype,"editor",{enableEmmet:{set:function(l){this[l?"on":"removeListener"]("changeMode",F),F({enableEmmet:!!l},this)},value:!0}}),m.setCore=function(l){typeof l=="string"?O=l:T=l}}),function(){ace.require(["ace/ext/emmet"],function(y){A&&(A.exports=y)})}()})(Z);var G=Z.exports;const ee=Q(G),ne=q({__proto__:null,default:ee},[G]);export{ne as e};
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.