@live-codes/browser-compilers 0.5.4 → 0.5.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@live-codes/browser-compilers",
3
- "version": "0.5.4",
3
+ "version": "0.5.5",
4
4
  "description": "Compilers that run in the browser, for use in livecodes.io",
5
5
  "author": "Hatem Hosny",
6
6
  "license": "MIT",
@@ -35,6 +35,7 @@
35
35
  "@testing-library/react": "12.1.4",
36
36
  "@webassemblyjs/wast-refmt": "1.11.1",
37
37
  "babel-preset-solid": "1.3.5",
38
+ "dts-bundle": "0.7.3",
38
39
  "esbuild-plugin-cache": "0.2.9",
39
40
  "esbuild-plugin-velcro": "0.1.1",
40
41
  "eslint": "8.11.0",
@@ -0,0 +1,7 @@
1
+ var dts = require('dts-bundle');
2
+
3
+ dts.bundle({
4
+ name: '@testing-library/dom',
5
+ main: './node_modules/@testing-library/dom/types/index.d.ts',
6
+ out: '../../../../vendor_modules/types/testing-library-dom.d.ts',
7
+ });
@@ -279,3 +279,10 @@ fs.copyFileSync(
279
279
  });
280
280
  },
281
281
  );
282
+
283
+ // lua-fmt
284
+ mkdirp(targetDir + '/lua-fmt');
285
+ fs.copyFileSync(
286
+ path.resolve(vendor_modules_src + '/lua-fmt/lua-fmt.js'),
287
+ path.resolve(targetDir + '/lua-fmt/lua-fmt.js'),
288
+ );
@@ -0,0 +1 @@
1
+ export * from '@testing-library/preact';
@@ -0,0 +1 @@
1
+ export * from '@testing-library/svelte';
@@ -0,0 +1 @@
1
+ export * from '@testing-library/vue';
@@ -0,0 +1,51 @@
1
+ var luaFmt=(()=>{var Sn=Object.defineProperty;var Ln=(R,x)=>{for(var T in x)Sn(R,T,{get:x[T],enumerable:!0})};var Hn={};Ln(Hn,{WriteMode:()=>Wn,__moduleExports:()=>ye,default:()=>Ke,defaultOptions:()=>Bn,formatText:()=>Nn,producePatch:()=>Vn});var Ve=typeof globalThis!="undefined"?globalThis:typeof window!="undefined"?window:typeof global!="undefined"?global:typeof self!="undefined"?self:{};function Cn(R,x,T){return T={path:x,exports:{},require:function(r,l){return bn(r,l??T.path)}},R(T,T.exports),T.exports}function bn(){throw new Error("Dynamic requires are not currently supported by @rollup/plugin-commonjs")}var se=Cn(function(R,x){(function(T,r,l){var L=x&&!x.nodeType&&x,g=R&&!R.nodeType&&R,s=L&&g&&typeof Ve=="object"&&Ve,o=g&&g.exports===L&&L;s&&(s.global===s||s.window===s||s.self===s)&&(T=s),l(L&&g?o?g.exports:L:T[r]={})})(Ve,"luaparse",function(T){T.version="0.2.1";var r,l,L,g=T.defaultOptions={wait:!1,comments:!0,scope:!1,locations:!1,ranges:!1,onCreateNode:null,onCreateScope:null,onDestroyScope:null},s=1,o=2,S=4,d=8,u=16,p=32,v=64,c=128,t=256;T.tokenTypes={EOF:s,StringLiteral:o,Keyword:S,Identifier:d,NumericLiteral:u,Punctuator:p,BooleanLiteral:v,NilLiteral:c,VarargLiteral:t};var a=T.errors={unexpected:"unexpected %1 '%2' near '%3'",expected:"'%1' expected near '%2'",expectedToken:"%1 expected near '%2'",unfinishedString:"unfinished string near '%1'",malformedNumber:"malformed number near '%1'",invalidVar:"invalid left-hand side of assignment near '%1'"},w=T.ast={labelStatement:function(e){return{type:"LabelStatement",label:e}},breakStatement:function(){return{type:"BreakStatement"}},gotoStatement:function(e){return{type:"GotoStatement",label:e}},returnStatement:function(e){return{type:"ReturnStatement",arguments:e}},ifStatement:function(e){return{type:"IfStatement",clauses:e}},ifClause:function(e,i){return{type:"IfClause",condition:e,body:i}},elseifClause:function(e,i){return{type:"ElseifClause",condition:e,body:i}},elseClause:function(e){return{type:"ElseClause",body:e}},whileStatement:function(e,i){return{type:"WhileStatement",condition:e,body:i}},doStatement:function(e){return{type:"DoStatement",body:e}},repeatStatement:function(e,i){return{type:"RepeatStatement",condition:e,body:i}},localStatement:function(e,i){return{type:"LocalStatement",variables:e,init:i}},assignmentStatement:function(e,i){return{type:"AssignmentStatement",variables:e,init:i}},callStatement:function(e){return{type:"CallStatement",expression:e}},functionStatement:function(e,i,y,A){return{type:"FunctionDeclaration",identifier:e,isLocal:y,parameters:i,body:A}},forNumericStatement:function(e,i,y,A,V){return{type:"ForNumericStatement",variable:e,start:i,end:y,step:A,body:V}},forGenericStatement:function(e,i,y){return{type:"ForGenericStatement",variables:e,iterators:i,body:y}},chunk:function(e){return{type:"Chunk",body:e}},identifier:function(e){return{type:"Identifier",name:e}},literal:function(e,i,y){return e=e===o?"StringLiteral":e===u?"NumericLiteral":e===v?"BooleanLiteral":e===c?"NilLiteral":"VarargLiteral",{type:e,value:i,raw:y}},tableKey:function(e,i){return{type:"TableKey",key:e,value:i}},tableKeyString:function(e,i){return{type:"TableKeyString",key:e,value:i}},tableValue:function(e){return{type:"TableValue",value:e}},tableConstructorExpression:function(e){return{type:"TableConstructorExpression",fields:e}},binaryExpression:function(e,i,y){var A=e==="and"||e==="or"?"LogicalExpression":"BinaryExpression";return{type:A,operator:e,left:i,right:y}},unaryExpression:function(e,i){return{type:"UnaryExpression",operator:e,argument:i}},memberExpression:function(e,i,y){return{type:"MemberExpression",indexer:i,identifier:y,base:e}},indexExpression:function(e,i){return{type:"IndexExpression",base:e,index:i}},callExpression:function(e,i){return{type:"CallExpression",base:e,arguments:i}},tableCallExpression:function(e,i){return{type:"TableCallExpression",base:e,arguments:i}},stringCallExpression:function(e,i){return{type:"StringCallExpression",base:e,argument:i}},comment:function(e,i){return{type:"Comment",value:e,raw:i}}};function E(e){if(Z){var i=te.pop();i.complete(),l.locations&&(e.loc=i.loc),l.ranges&&(e.range=i.range)}return l.onCreateNode&&l.onCreateNode(e),e}var F=Array.prototype.slice,O=function(i,y){for(var A=0,V=i.length;A<V;A++)if(i[A]===y)return A;return-1};function z(e,i,y){for(var A=0,V=e.length;A<V;A++)if(e[A][i]===y)return A;return-1}function m(e){var i=F.call(arguments,1);return e=e.replace(/%(\d)/g,function(y,A){return""+i[A-1]||""}),e}function b(){for(var e=F.call(arguments),i={},y,A,V=0,j=e.length;V<j;V++){y=e[V];for(A in y)y.hasOwnProperty(A)&&(i[A]=y[A])}return i}function C(e){var i=m.apply(null,F.call(arguments,1)),y,A;throw typeof e.line!="undefined"?(A=e.range[0]-e.lineStart,y=new SyntaxError(m("[%1:%2] %3",e.line,A,i)),y.line=e.line,y.index=e.range[0],y.column=A):(A=n-B+1,y=new SyntaxError(m("[%1:%2] %3",W,A,i)),y.index=n,y.line=W,y.column=A),y}function P(e,i){C(i,a.expectedToken,e,i.value)}function M(e,i){if(typeof i=="undefined"&&(i=k.value),typeof e.type!="undefined"){var y;switch(e.type){case o:y="string";break;case S:y="keyword";break;case d:y="identifier";break;case u:y="number";break;case p:y="symbol";break;case v:y="boolean";break;case c:return C(e,a.unexpected,"symbol","nil",i)}return C(e,a.unexpected,y,e.value,i)}return C(e,a.unexpected,"symbol",e,i)}var n,f,D,k,N,I,W,B;T.lex=H;function H(){for(X();r.charCodeAt(n)===45&&r.charCodeAt(n+1)===45;)Pe(),X();if(n>=L)return{type:s,value:"<eof>",line:W,lineStart:B,range:[n,n]};var e=r.charCodeAt(n),i=r.charCodeAt(n+1);if(I=n,Xe(e))return we();switch(e){case 39:case 34:return de();case 48:case 49:case 50:case 51:case 52:case 53:case 54:case 55:case 56:case 57:return ce();case 46:return le(i)?ce():i===46?r.charCodeAt(n+2)===46?Te():K(".."):K(".");case 61:return K(i===61?"==":"=");case 62:return K(i===61?">=":i===62?">>":">");case 60:return K(i===60?"<<":i===61?"<=":"<");case 126:return K(i===61?"~=":"~");case 58:return K(i===58?"::":":");case 91:return i===91||i===61?Se():K("[");case 47:return K(i===47?"//":"/");case 42:case 94:case 37:case 44:case 123:case 124:case 125:case 93:case 40:case 41:case 59:case 38:case 35:case 45:case 43:return K(r.charAt(n))}return M(r.charAt(n))}function Q(){var e=r.charCodeAt(n),i=r.charCodeAt(n+1);return be(e)?(e===10&&i===13&&n++,e===13&&i===10&&n++,W++,B=++n,!0):!1}function X(){for(;n<L;){var e=r.charCodeAt(n);if($e(e))n++;else if(!Q())break}}function we(){for(var e,i;Ze(r.charCodeAt(++n)););return e=r.slice(I,n),Ye(e)?i=S:e==="true"||e==="false"?(i=v,e=e==="true"):e==="nil"?(i=c,e=null):i=d,{type:i,value:e,line:W,lineStart:B,range:[I,n]}}function K(e){return n+=e.length,{type:p,value:e,line:W,lineStart:B,range:[I,n]}}function Te(){return n+=3,{type:t,value:"...",line:W,lineStart:B,range:[I,n]}}function de(){for(var e=r.charCodeAt(n++),i=n,y="",A;n<L&&(A=r.charCodeAt(n++),e!==A);)A===92?(y+=r.slice(i,n-1)+Le(),i=n):(n>=L||be(A))&&(y+=r.slice(i,n-1),C({},a.unfinishedString,y+String.fromCharCode(A)));return y+=r.slice(i,n-1),{type:o,value:y,line:W,lineStart:B,range:[I,n]}}function Se(){var e=He();return e===!1&&C(f,a.expected,"[",f.value),{type:o,value:e,line:W,lineStart:B,range:[I,n]}}function ce(){var e=r.charAt(n),i=r.charAt(n+1),y=e==="0"&&"xX".indexOf(i||null)>=0?pe():ue();return{type:u,value:y,line:W,lineStart:B,range:[I,n]}}function pe(){var e=0,i=1,y=1,A,V,j,ne;for(ne=n+=2,Ce(r.charCodeAt(n))||C({},a.malformedNumber,r.slice(I,n));Ce(r.charCodeAt(n));)n++;if(A=parseInt(r.slice(ne,n),16),r.charAt(n)==="."){for(V=++n;Ce(r.charCodeAt(n));)n++;e=r.slice(V,n),e=V===n?0:parseInt(e,16)/Math.pow(16,n-V)}if("pP".indexOf(r.charAt(n)||null)>=0){for(n++,"+-".indexOf(r.charAt(n)||null)>=0&&(y=r.charAt(n++)==="+"?1:-1),j=n,le(r.charCodeAt(n))||C({},a.malformedNumber,r.slice(I,n));le(r.charCodeAt(n));)n++;i=r.slice(j,n),i=Math.pow(2,i*y)}return(A+e)*i}function ue(){for(;le(r.charCodeAt(n));)n++;if(r.charAt(n)===".")for(n++;le(r.charCodeAt(n));)n++;if("eE".indexOf(r.charAt(n)||null)>=0)for(n++,"+-".indexOf(r.charAt(n)||null)>=0&&n++,le(r.charCodeAt(n))||C({},a.malformedNumber,r.slice(I,n));le(r.charCodeAt(n));)n++;return parseFloat(r.slice(I,n))}function Le(){var e=n;switch(r.charAt(n)){case"n":return n++,`
2
+ `;case"r":return n++,"\r";case"t":return n++," ";case"v":return n++,"\v";case"b":return n++,"\b";case"f":return n++,"\f";case"z":return n++,X(),"";case"x":return Ce(r.charCodeAt(n+1))&&Ce(r.charCodeAt(n+2))?(n+=3,"\\"+r.slice(e,n)):"\\"+r.charAt(n++);default:if(le(r.charCodeAt(n))){for(;le(r.charCodeAt(++n)););return"\\"+r.slice(e,n)}return r.charAt(n++)}}function Pe(){I=n,n+=2;var e=r.charAt(n),i="",y=!1,A=n,V=B,j=W;if(e==="["&&(i=He(),i===!1?i=e:y=!0),!y){for(;n<L&&!be(r.charCodeAt(n));)n++;l.comments&&(i=r.slice(A,n))}if(l.comments){var ne=w.comment(i,r.slice(I,n));l.locations&&(ne.loc={start:{line:j,column:I-V},end:{line:W,column:n-B}}),l.ranges&&(ne.range=[I,n]),l.onCreateNode&&l.onCreateNode(ne),N.push(ne)}}function He(){var e=0,i="",y=!1,A,V;for(n++;r.charAt(n+e)==="=";)e++;if(r.charAt(n+e)!=="[")return!1;for(n+=e+1,be(r.charCodeAt(n))&&Q(),V=n;n<L;){if(be(r.charCodeAt(n))&&Q(),A=r.charAt(n++),A==="]"){y=!0;for(var j=0;j<e;j++)r.charAt(n+j)!=="="&&(y=!1);r.charAt(n+e)!=="]"&&(y=!1)}if(y)break}return i+=r.slice(V,n-1),n+=e+1,i}function G(){D=f,f=k,k=H()}function J(e){return e===f.value?(G(),!0):!1}function U(e){e===f.value?G():C(f,a.expected,e,f.value)}function $e(e){return e===9||e===32||e===11||e===12}function be(e){return e===10||e===13}function le(e){return e>=48&&e<=57}function Ce(e){return e>=48&&e<=57||e>=97&&e<=102||e>=65&&e<=70}function Xe(e){return e>=65&&e<=90||e>=97&&e<=122||e===95}function Ze(e){return e>=65&&e<=90||e>=97&&e<=122||e===95||e>=48&&e<=57}function Ye(e){switch(e.length){case 2:return e==="do"||e==="if"||e==="in"||e==="or";case 3:return e==="and"||e==="end"||e==="for"||e==="not";case 4:return e==="else"||e==="goto"||e==="then";case 5:return e==="break"||e==="local"||e==="until"||e==="while";case 6:return e==="elseif"||e==="repeat"||e==="return";case 8:return e==="function"}return!1}function en(e){return p===e.type?"#-~".indexOf(e.value)>=0:S===e.type?e.value==="not":!1}function nn(e){switch(e.type){case"CallExpression":case"TableCallExpression":case"StringCallExpression":return!0}return!1}function tn(e){if(s===e.type)return!0;if(S!==e.type)return!1;switch(e.value){case"else":case"elseif":case"end":case"until":return!0;default:return!1}}var he,me,De;function re(){var e=Array.apply(null,he[me++]);he.push(e),l.onCreateScope&&l.onCreateScope()}function ae(){var e=he.pop();me--,l.onDestroyScope&&l.onDestroyScope()}function Me(e){O(he[me],e)===-1&&he[me].push(e)}function Ee(e){Me(e.name),Ae(e,!0)}function Ae(e,i){!i&&z(De,"name",e.name)===-1&&De.push(e),e.isLocal=i}function Re(e){return O(he[me],e)!==-1}var te=[],Z;function fe(){return new Fe(f)}function Fe(e){l.locations&&(this.loc={start:{line:e.line,column:e.range[0]-e.lineStart},end:{line:0,column:0}}),l.ranges&&(this.range=[e.range[0],0])}Fe.prototype.complete=function(){l.locations&&(this.loc.end.line=D.line,this.loc.end.column=D.range[1]-D.lineStart),l.ranges&&(this.range[1]=D.range[1])};function ve(){Z&&te.push(fe())}function Y(e){Z&&te.push(e)}function rn(){G(),ve(),l.scope&&re();var e=ie();return l.scope&&ae(),s!==f.type&&M(f),Z&&!e.length&&(D=f),E(w.chunk(e))}function ie(e){for(var i=[],y;!tn(f);){if(f.value==="return"){i.push(ze());break}y=ze(),y&&i.push(y)}return i}function ze(){if(ve(),S===f.type)switch(f.value){case"local":return G(),pn();case"if":return G(),dn();case"return":return G(),fn();case"function":G();var e=vn();return Oe(e);case"while":return G(),on();case"for":return G(),hn();case"repeat":return G(),cn();case"break":return G(),sn();case"do":return G(),ln();case"goto":return G(),un()}if(p===f.type&&J("::"))return an();if(Z&&te.pop(),!J(";"))return mn()}function an(){var e=f.value,i=ee();return l.scope&&(Me("::"+e+"::"),Ae(i,!0)),U("::"),E(w.labelStatement(i))}function sn(){return E(w.breakStatement())}function un(){var e=f.value,i=ee();return E(w.gotoStatement(i))}function ln(){l.scope&&re();var e=ie();return l.scope&&ae(),U("end"),E(w.doStatement(e))}function on(){var e=$();U("do"),l.scope&&re();var i=ie();return l.scope&&ae(),U("end"),E(w.whileStatement(e,i))}function cn(){l.scope&&re();var e=ie();U("until");var i=$();return l.scope&&ae(),E(w.repeatStatement(i,e))}function fn(){var e=[];if(f.value!=="end"){var i=xe();for(i!=null&&e.push(i);J(",");)i=$(),e.push(i);J(";")}return E(w.returnStatement(e))}function dn(){var e=[],i,y,A;for(Z&&(A=te[te.length-1],te.push(A)),i=$(),U("then"),l.scope&&re(),y=ie(),l.scope&&ae(),e.push(E(w.ifClause(i,y))),Z&&(A=fe());J("elseif");)Y(A),i=$(),U("then"),l.scope&&re(),y=ie(),l.scope&&ae(),e.push(E(w.elseifClause(i,y))),Z&&(A=fe());return J("else")&&(Z&&(A=new Fe(D),te.push(A)),l.scope&&re(),y=ie(),l.scope&&ae(),e.push(E(w.elseClause(y)))),U("end"),E(w.ifStatement(e))}function hn(){var e=ee(),i;if(l.scope&&(re(),Ee(e)),J("=")){var y=$();U(",");var A=$(),V=J(",")?$():null;return U("do"),i=ie(),U("end"),l.scope&&ae(),E(w.forNumericStatement(e,y,A,V,i))}else{for(var j=[e];J(",");)e=ee(),l.scope&&Ee(e),j.push(e);U("in");var ne=[];do{var wn=$();ne.push(wn)}while(J(","));return U("do"),i=ie(),U("end"),l.scope&&ae(),E(w.forGenericStatement(j,ne,i))}}function pn(){var e;if(d===f.type){var i=[],y=[];do e=ee(),i.push(e);while(J(","));if(J("="))do{var A=$();y.push(A)}while(J(","));if(l.scope)for(var V=0,j=i.length;V<j;V++)Ee(i[V]);return E(w.localStatement(i,y))}if(J("function"))return e=ee(),l.scope&&(Ee(e),re()),Oe(e,!0);P("<name>",f)}function _e(e){(e.inParens||["Identifier","MemberExpression","IndexExpression"].indexOf(e.type)===-1)&&C(f,a.invalidVar,f.value)}function mn(){var e=f,i,y;if(Z&&(y=fe()),i=We(),i==null)return M(f);if(",=".indexOf(f.value)>=0){var A=[i],V=[],j;for(_e(i);J(",");)j=We(),j==null&&P("<expression>",f),_e(j),A.push(j);U("=");do j=$(),V.push(j);while(J(","));return Y(y),E(w.assignmentStatement(A,V))}return nn(i)?(Y(y),E(w.callStatement(i))):M(e)}function ee(){ve();var e=f.value;return d!==f.type&&P("<name>",f),G(),E(w.identifier(e))}function Oe(e,i){var y=[];if(U("("),!J(")"))for(;;)if(d===f.type){var A=ee();if(l.scope&&Ee(A),y.push(A),J(","))continue;if(J(")"))break}else if(t===f.type){y.push(Ne()),U(")");break}else P("<name> or '...'",f);var V=ie();return U("end"),l.scope&&ae(),i=i||!1,E(w.functionStatement(e,y,i,V))}function vn(){var e,i,y;for(Z&&(y=fe()),e=ee(),l.scope&&(Ae(e,Re(e.name)),re());J(".");)Y(y),i=ee(),e=E(w.memberExpression(e,".",i));return J(":")&&(Y(y),i=ee(),e=E(w.memberExpression(e,":",i)),l.scope&&Me("self")),e}function je(){for(var e=[],i,y;;){if(ve(),p===f.type&&J("["))i=$(),U("]"),U("="),y=$(),e.push(E(w.tableKey(i,y)));else if(d===f.type)k.value==="="?(i=ee(),G(),y=$(),e.push(E(w.tableKeyString(i,y)))):(y=$(),e.push(E(w.tableValue(y))));else{if((y=xe())==null){te.pop();break}e.push(E(w.tableValue(y)))}if(",;".indexOf(f.value)>=0){G();continue}break}return U("}"),E(w.tableConstructorExpression(e))}function xe(){var e=Ie(0);return e}function $(){var e=xe();if(e==null)P("<expression>",f);else return e}function gn(e){var i=e.charCodeAt(0),y=e.length;if(y===1)switch(i){case 94:return 12;case 42:case 47:case 37:return 10;case 43:case 45:return 9;case 38:return 6;case 126:return 5;case 124:return 4;case 60:case 62:return 3}else if(y===2)switch(i){case 47:return 10;case 46:return 8;case 60:case 62:return e==="<<"||e===">>"?7:3;case 61:case 126:return 3;case 111:return 1}else if(i===97&&e==="and")return 2;return 0}function Ie(e){var i=f.value,y,A;if(Z&&(A=fe()),en(f)){ve(),G();var V=Ie(10);V==null&&P("<expression>",f),y=E(w.unaryExpression(i,V))}if(y==null&&(y=Ne(),y==null&&(y=We())),y==null)return null;for(var j;i=f.value,j=p===f.type||S===f.type?gn(i):0,!(j===0||j<=e);){(i==="^"||i==="..")&&j--,G();var ne=Ie(j);ne==null&&P("<expression>",f),Z&&te.push(A),y=E(w.binaryExpression(i,y,ne))}return y}function We(){var e,i,y;if(Z&&(y=fe()),d===f.type)i=f.value,e=ee(),l.scope&&Ae(e,Re(i));else if(J("("))e=$(),U(")"),e.inParens=!0;else return null;for(var A,V;;)if(p===f.type)switch(f.value){case"[":Y(y),G(),A=$(),e=E(w.indexExpression(e,A)),U("]");break;case".":Y(y),G(),V=ee(),e=E(w.memberExpression(e,".",V));break;case":":Y(y),G(),V=ee(),e=E(w.memberExpression(e,":",V)),Y(y),e=Be(e);break;case"(":case"{":Y(y),e=Be(e);break;default:return e}else if(o===f.type)Y(y),e=Be(e);else break;return e}function Be(e){if(p===f.type)switch(f.value){case"(":G();var i=[],y=xe();for(y!=null&&i.push(y);J(",");)y=$(),i.push(y);return U(")"),E(w.callExpression(e,i));case"{":ve(),G();var A=je();return E(w.tableCallExpression(e,A))}else if(o===f.type)return E(w.stringCallExpression(e,Ne()));P("function arguments",f)}function Ne(){var e=o|u|v|c|t,i=f.value,y=f.type,A;if(Z&&(A=fe()),y&e){Y(A);var V=r.slice(f.range[0],f.range[1]);return G(),E(w.literal(y,i,V))}else{if(S===y&&i==="function")return Y(A),G(),l.scope&&re(),Oe(null);if(J("{"))return Y(A),je()}}T.parse=yn;function yn(e,i){return typeof i=="undefined"&&typeof e=="object"&&(i=e,e=void 0),i||(i={}),r=e||"",l=b(g,i),n=0,W=1,B=0,L=r.length,he=[[]],me=0,De=[],te=[],l.comments&&(N=[]),l.wait?T:Qe()}T.write=qe;function qe(e){return r+=String(e),L=r.length,T}T.end=Qe;function Qe(e){typeof e!="undefined"&&qe(e),r&&r.substr(0,2)==="#!"&&(r=r.replace(/^.*/,function(y){return y.replace(/./g," ")})),L=r.length,Z=l.locations||l.ranges,k=H();var i=rn();if(l.comments&&(i.comments=N),l.scope&&(i.globals=De),te.length>0)throw new Error("Location tracking failed. This is most likely a bug in luaparse");return i}})}),_n=se.ast,Ge=se,jn=se.defaultOptions,qn=se.end,Qn=se.errors,Gn=se.lex,Jn=se.parse,Un=se.tokenTypes,Kn=se.version,$n=se.write;var En=typeof globalThis!="undefined"?globalThis:typeof window!="undefined"?window:typeof global!="undefined"?global:typeof self!="undefined"?self:{};function kn(R){return R&&R.__esModule&&Object.prototype.hasOwnProperty.call(R,"default")?R.default:R}function Dn(R,x,T){return T={path:x,exports:{},require:function(r,l){return Tn(r,l??T.path)}},R(T,T.exports),T.exports}function Tn(){throw new Error("Dynamic requires are not currently supported by @rollup/plugin-commonjs")}var _=Dn(function(R,x){(function(r,l){R.exports=l()})(En,function(){return function(T){var r={};function l(L){if(r[L])return r[L].exports;var g=r[L]={exports:{},id:L,loaded:!1};return T[L].call(g.exports,g,g.exports,l),g.loaded=!0,g.exports}return l.m=T,l.c=r,l.p="",l(0)}([function(T,r,l){r.__esModule=!0,r.canonicalize=r.convertChangesToXML=r.convertChangesToDMP=r.merge=r.parsePatch=r.applyPatches=r.applyPatch=r.createPatch=r.createTwoFilesPatch=r.structuredPatch=r.diffArrays=r.diffJson=r.diffCss=r.diffSentences=r.diffTrimmedLines=r.diffLines=r.diffWordsWithSpace=r.diffWords=r.diffChars=r.Diff=void 0;var L=l(1),g=O(L),s=l(2),o=l(3),S=l(5),d=l(6),u=l(7),p=l(8),v=l(9),c=l(10),t=l(11),a=l(13),w=l(14),E=l(16),F=l(17);function O(z){return z&&z.__esModule?z:{default:z}}r.Diff=g.default,r.diffChars=s.diffChars,r.diffWords=o.diffWords,r.diffWordsWithSpace=o.diffWordsWithSpace,r.diffLines=S.diffLines,r.diffTrimmedLines=S.diffTrimmedLines,r.diffSentences=d.diffSentences,r.diffCss=u.diffCss,r.diffJson=p.diffJson,r.diffArrays=v.diffArrays,r.structuredPatch=w.structuredPatch,r.createTwoFilesPatch=w.createTwoFilesPatch,r.createPatch=w.createPatch,r.applyPatch=c.applyPatch,r.applyPatches=c.applyPatches,r.parsePatch=t.parsePatch,r.merge=a.merge,r.convertChangesToDMP=E.convertChangesToDMP,r.convertChangesToXML=F.convertChangesToXML,r.canonicalize=p.canonicalize},function(T,r){r.__esModule=!0,r.default=l;function l(){}l.prototype={diff:function(o,S){var d=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},u=d.callback;typeof d=="function"&&(u=d,d={}),this.options=d;var p=this;function v(m){return u?(setTimeout(function(){u(void 0,m)},0),!0):m}o=this.castInput(o),S=this.castInput(S),o=this.removeEmpty(this.tokenize(o)),S=this.removeEmpty(this.tokenize(S));var c=S.length,t=o.length,a=1,w=c+t,E=[{newPos:-1,components:[]}],F=this.extractCommon(E[0],S,o,0);if(E[0].newPos+1>=c&&F+1>=t)return v([{value:this.join(S),count:S.length}]);function O(){for(var m=-1*a;m<=a;m+=2){var b=void 0,C=E[m-1],P=E[m+1],M=(P?P.newPos:0)-m;C&&(E[m-1]=void 0);var n=C&&C.newPos+1<c,f=P&&0<=M&&M<t;if(!n&&!f){E[m]=void 0;continue}if(!n||f&&C.newPos<P.newPos?(b=g(P),p.pushComponent(b.components,void 0,!0)):(b=C,b.newPos++,p.pushComponent(b.components,!0,void 0)),M=p.extractCommon(b,S,o,m),b.newPos+1>=c&&M+1>=t)return v(L(p,b.components,S,o,p.useLongestToken));E[m]=b}a++}if(u)(function m(){setTimeout(function(){if(a>w)return u();O()||m()},0)})();else for(;a<=w;){var z=O();if(z)return z}},pushComponent:function(o,S,d){var u=o[o.length-1];u&&u.added===S&&u.removed===d?o[o.length-1]={count:u.count+1,added:S,removed:d}:o.push({count:1,added:S,removed:d})},extractCommon:function(o,S,d,u){for(var p=S.length,v=d.length,c=o.newPos,t=c-u,a=0;c+1<p&&t+1<v&&this.equals(S[c+1],d[t+1]);)c++,t++,a++;return a&&o.components.push({count:a}),o.newPos=c,t},equals:function(o,S){return this.options.comparator?this.options.comparator(o,S):o===S||this.options.ignoreCase&&o.toLowerCase()===S.toLowerCase()},removeEmpty:function(o){for(var S=[],d=0;d<o.length;d++)o[d]&&S.push(o[d]);return S},castInput:function(o){return o},tokenize:function(o){return o.split("")},join:function(o){return o.join("")}};function L(s,o,S,d,u){for(var p=0,v=o.length,c=0,t=0;p<v;p++){var a=o[p];if(a.removed){if(a.value=s.join(d.slice(t,t+a.count)),t+=a.count,p&&o[p-1].added){var E=o[p-1];o[p-1]=o[p],o[p]=E}}else{if(!a.added&&u){var w=S.slice(c,c+a.count);w=w.map(function(O,z){var m=d[t+z];return m.length>O.length?m:O}),a.value=s.join(w)}else a.value=s.join(S.slice(c,c+a.count));c+=a.count,a.added||(t+=a.count)}}var F=o[v-1];return v>1&&typeof F.value=="string"&&(F.added||F.removed)&&s.equals("",F.value)&&(o[v-2].value+=F.value,o.pop()),o}function g(s){return{newPos:s.newPos,components:s.components.slice(0)}}},function(T,r,l){r.__esModule=!0,r.characterDiff=void 0,r.diffChars=S;var L=l(1),g=s(L);function s(d){return d&&d.__esModule?d:{default:d}}var o=r.characterDiff=new g.default;function S(d,u,p){return o.diff(d,u,p)}},function(T,r,l){r.__esModule=!0,r.wordDiff=void 0,r.diffWords=p,r.diffWordsWithSpace=v;var L=l(1),g=o(L),s=l(4);function o(c){return c&&c.__esModule?c:{default:c}}var S=/^[A-Za-z\xC0-\u02C6\u02C8-\u02D7\u02DE-\u02FF\u1E00-\u1EFF]+$/,d=/\S/,u=r.wordDiff=new g.default;u.equals=function(c,t){return this.options.ignoreCase&&(c=c.toLowerCase(),t=t.toLowerCase()),c===t||this.options.ignoreWhitespace&&!d.test(c)&&!d.test(t)},u.tokenize=function(c){for(var t=c.split(/(\s+|\b)/),a=0;a<t.length-1;a++)!t[a+1]&&t[a+2]&&S.test(t[a])&&S.test(t[a+2])&&(t[a]+=t[a+2],t.splice(a+1,2),a--);return t};function p(c,t,a){return a=(0,s.generateOptions)(a,{ignoreWhitespace:!0}),u.diff(c,t,a)}function v(c,t,a){return u.diff(c,t,a)}},function(T,r){r.__esModule=!0,r.generateOptions=l;function l(L,g){if(typeof L=="function")g.callback=L;else if(L)for(var s in L)L.hasOwnProperty(s)&&(g[s]=L[s]);return g}},function(T,r,l){r.__esModule=!0,r.lineDiff=void 0,r.diffLines=d,r.diffTrimmedLines=u;var L=l(1),g=o(L),s=l(4);function o(p){return p&&p.__esModule?p:{default:p}}var S=r.lineDiff=new g.default;S.tokenize=function(p){var v=[],c=p.split(/(\n|\r\n)/);c[c.length-1]||c.pop();for(var t=0;t<c.length;t++){var a=c[t];t%2&&!this.options.newlineIsToken?v[v.length-1]+=a:(this.options.ignoreWhitespace&&(a=a.trim()),v.push(a))}return v};function d(p,v,c){return S.diff(p,v,c)}function u(p,v,c){var t=(0,s.generateOptions)(c,{ignoreWhitespace:!0});return S.diff(p,v,t)}},function(T,r,l){r.__esModule=!0,r.sentenceDiff=void 0,r.diffSentences=S;var L=l(1),g=s(L);function s(d){return d&&d.__esModule?d:{default:d}}var o=r.sentenceDiff=new g.default;o.tokenize=function(d){return d.split(/(\S.+?[.!?])(?=\s+|$)/)};function S(d,u,p){return o.diff(d,u,p)}},function(T,r,l){r.__esModule=!0,r.cssDiff=void 0,r.diffCss=S;var L=l(1),g=s(L);function s(d){return d&&d.__esModule?d:{default:d}}var o=r.cssDiff=new g.default;o.tokenize=function(d){return d.split(/([{}:;,]|\s+)/)};function S(d,u,p){return o.diff(d,u,p)}},function(T,r,l){r.__esModule=!0,r.jsonDiff=void 0;var L=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(c){return typeof c}:function(c){return c&&typeof Symbol=="function"&&c.constructor===Symbol&&c!==Symbol.prototype?"symbol":typeof c};r.diffJson=p,r.canonicalize=v;var g=l(1),s=S(g),o=l(5);function S(c){return c&&c.__esModule?c:{default:c}}var d=Object.prototype.toString,u=r.jsonDiff=new s.default;u.useLongestToken=!0,u.tokenize=o.lineDiff.tokenize,u.castInput=function(c){var t=this.options,a=t.undefinedReplacement,w=t.stringifyReplacer,E=w===void 0?function(F,O){return typeof O=="undefined"?a:O}:w;return typeof c=="string"?c:JSON.stringify(v(c,null,null,E),E," ")},u.equals=function(c,t){return s.default.prototype.equals.call(u,c.replace(/,([\r\n])/g,"$1"),t.replace(/,([\r\n])/g,"$1"))};function p(c,t,a){return u.diff(c,t,a)}function v(c,t,a,w,E){t=t||[],a=a||[],w&&(c=w(E,c));var F=void 0;for(F=0;F<t.length;F+=1)if(t[F]===c)return a[F];var O=void 0;if(d.call(c)==="[object Array]"){for(t.push(c),O=new Array(c.length),a.push(O),F=0;F<c.length;F+=1)O[F]=v(c[F],t,a,w,E);return t.pop(),a.pop(),O}if(c&&c.toJSON&&(c=c.toJSON()),(typeof c=="undefined"?"undefined":L(c))==="object"&&c!==null){t.push(c),O={},a.push(O);var z=[],m=void 0;for(m in c)c.hasOwnProperty(m)&&z.push(m);for(z.sort(),F=0;F<z.length;F+=1)m=z[F],O[m]=v(c[m],t,a,w,m);t.pop(),a.pop()}else O=c;return O}},function(T,r,l){r.__esModule=!0,r.arrayDiff=void 0,r.diffArrays=S;var L=l(1),g=s(L);function s(d){return d&&d.__esModule?d:{default:d}}var o=r.arrayDiff=new g.default;o.tokenize=function(d){return d.slice()},o.join=o.removeEmpty=function(d){return d};function S(d,u,p){return o.diff(d,u,p)}},function(T,r,l){r.__esModule=!0,r.applyPatch=S,r.applyPatches=d;var L=l(11),g=l(12),s=o(g);function o(u){return u&&u.__esModule?u:{default:u}}function S(u,p){var v=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};if(typeof p=="string"&&(p=(0,L.parsePatch)(p)),Array.isArray(p)){if(p.length>1)throw new Error("applyPatch only works with a single input.");p=p[0]}var c=u.split(/\r\n|[\n\v\f\r\x85]/),t=u.match(/\r\n|[\n\v\f\r\x85]/g)||[],a=p.hunks,w=v.compareLine||function(Se,ce,pe,ue){return ce===ue},E=0,F=v.fuzzFactor||0,O=0,z=0,m=void 0,b=void 0;function C(Se,ce){for(var pe=0;pe<Se.lines.length;pe++){var ue=Se.lines[pe],Le=ue.length>0?ue[0]:" ",Pe=ue.length>0?ue.substr(1):ue;if(Le===" "||Le==="-"){if(!w(ce+1,c[ce],Le,Pe)&&(E++,E>F))return!1;ce++}}return!0}for(var P=0;P<a.length;P++){for(var M=a[P],n=c.length-M.oldLines,f=0,D=z+M.oldStart-1,k=(0,s.default)(D,O,n);f!==void 0;f=k())if(C(M,D+f)){M.offset=z+=f;break}if(f===void 0)return!1;O=M.offset+M.oldStart+M.oldLines}for(var N=0,I=0;I<a.length;I++){var W=a[I],B=W.oldStart+W.offset+N-1;N+=W.newLines-W.oldLines,B<0&&(B=0);for(var H=0;H<W.lines.length;H++){var Q=W.lines[H],X=Q.length>0?Q[0]:" ",we=Q.length>0?Q.substr(1):Q,K=W.linedelimiters[H];if(X===" ")B++;else if(X==="-")c.splice(B,1),t.splice(B,1);else if(X==="+")c.splice(B,0,we),t.splice(B,0,K),B++;else if(X==="\\"){var Te=W.lines[H-1]?W.lines[H-1][0]:null;Te==="+"?m=!0:Te==="-"&&(b=!0)}}}if(m)for(;!c[c.length-1];)c.pop(),t.pop();else b&&(c.push(""),t.push(`
3
+ `));for(var de=0;de<c.length-1;de++)c[de]=c[de]+t[de];return c.join("")}function d(u,p){typeof u=="string"&&(u=(0,L.parsePatch)(u));var v=0;function c(){var t=u[v++];if(!t)return p.complete();p.loadFile(t,function(a,w){if(a)return p.complete(a);var E=S(w,t,p);p.patched(t,E,function(F){if(F)return p.complete(F);c()})})}c()}},function(T,r){r.__esModule=!0,r.parsePatch=l;function l(L){var g=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},s=L.split(/\r\n|[\n\v\f\r\x85]/),o=L.match(/\r\n|[\n\v\f\r\x85]/g)||[],S=[],d=0;function u(){var c={};for(S.push(c);d<s.length;){var t=s[d];if(/^(\-\-\-|\+\+\+|@@)\s/.test(t))break;var a=/^(?:Index:|diff(?: -r \w+)+)\s+(.+?)\s*$/.exec(t);a&&(c.index=a[1]),d++}for(p(c),p(c),c.hunks=[];d<s.length;){var w=s[d];if(/^(Index:|diff|\-\-\-|\+\+\+)\s/.test(w))break;if(/^@@/.test(w))c.hunks.push(v());else{if(w&&g.strict)throw new Error("Unknown line "+(d+1)+" "+JSON.stringify(w));d++}}}function p(c){var t=/^(---|\+\+\+)\s+(.*)$/.exec(s[d]);if(t){var a=t[1]==="---"?"old":"new",w=t[2].split(" ",2),E=w[0].replace(/\\\\/g,"\\");/^".*"$/.test(E)&&(E=E.substr(1,E.length-2)),c[a+"FileName"]=E,c[a+"Header"]=(w[1]||"").trim(),d++}}function v(){for(var c=d,t=s[d++],a=t.split(/@@ -(\d+)(?:,(\d+))? \+(\d+)(?:,(\d+))? @@/),w={oldStart:+a[1],oldLines:+a[2]||1,newStart:+a[3],newLines:+a[4]||1,lines:[],linedelimiters:[]},E=0,F=0;d<s.length&&!(s[d].indexOf("--- ")===0&&d+2<s.length&&s[d+1].indexOf("+++ ")===0&&s[d+2].indexOf("@@")===0);d++){var O=s[d].length==0&&d!=s.length-1?" ":s[d][0];if(O==="+"||O==="-"||O===" "||O==="\\")w.lines.push(s[d]),w.linedelimiters.push(o[d]||`
4
+ `),O==="+"?E++:O==="-"?F++:O===" "&&(E++,F++);else break}if(!E&&w.newLines===1&&(w.newLines=0),!F&&w.oldLines===1&&(w.oldLines=0),g.strict){if(E!==w.newLines)throw new Error("Added line count did not match for hunk at line "+(c+1));if(F!==w.oldLines)throw new Error("Removed line count did not match for hunk at line "+(c+1))}return w}for(;d<s.length;)u();return S}},function(T,r){r.__esModule=!0,r.default=function(l,L,g){var s=!0,o=!1,S=!1,d=1;return function u(){if(s&&!S){if(o?d++:s=!1,l+d<=g)return d;S=!0}if(!o)return S||(s=!0),L<=l-d?-d++:(o=!0,u())}}},function(T,r,l){r.__esModule=!0,r.calcLineCount=S,r.merge=d;var L=l(14),g=l(11),s=l(15);function o(n){if(Array.isArray(n)){for(var f=0,D=Array(n.length);f<n.length;f++)D[f]=n[f];return D}else return Array.from(n)}function S(n){var f=M(n.lines),D=f.oldLines,k=f.newLines;D!==void 0?n.oldLines=D:delete n.oldLines,k!==void 0?n.newLines=k:delete n.newLines}function d(n,f,D){n=u(n,D),f=u(f,D);var k={};(n.index||f.index)&&(k.index=n.index||f.index),(n.newFileName||f.newFileName)&&(p(n)?p(f)?(k.oldFileName=v(k,n.oldFileName,f.oldFileName),k.newFileName=v(k,n.newFileName,f.newFileName),k.oldHeader=v(k,n.oldHeader,f.oldHeader),k.newHeader=v(k,n.newHeader,f.newHeader)):(k.oldFileName=n.oldFileName,k.newFileName=n.newFileName,k.oldHeader=n.oldHeader,k.newHeader=n.newHeader):(k.oldFileName=f.oldFileName||n.oldFileName,k.newFileName=f.newFileName||n.newFileName,k.oldHeader=f.oldHeader||n.oldHeader,k.newHeader=f.newHeader||n.newHeader)),k.hunks=[];for(var N=0,I=0,W=0,B=0;N<n.hunks.length||I<f.hunks.length;){var H=n.hunks[N]||{oldStart:Infinity},Q=f.hunks[I]||{oldStart:Infinity};if(c(H,Q))k.hunks.push(t(H,W)),N++,B+=H.newLines-H.oldLines;else if(c(Q,H))k.hunks.push(t(Q,B)),I++,W+=Q.newLines-Q.oldLines;else{var X={oldStart:Math.min(H.oldStart,Q.oldStart),oldLines:0,newStart:Math.min(H.newStart+W,Q.oldStart+B),newLines:0,lines:[]};a(X,H.oldStart,H.lines,Q.oldStart,Q.lines),I++,N++,k.hunks.push(X)}}return k}function u(n,f){if(typeof n=="string"){if(/^@@/m.test(n)||/^Index:/m.test(n))return(0,g.parsePatch)(n)[0];if(!f)throw new Error("Must provide a base reference or pass in a patch");return(0,L.structuredPatch)(void 0,void 0,f,n)}return n}function p(n){return n.newFileName&&n.newFileName!==n.oldFileName}function v(n,f,D){return f===D?f:(n.conflict=!0,{mine:f,theirs:D})}function c(n,f){return n.oldStart<f.oldStart&&n.oldStart+n.oldLines<f.oldStart}function t(n,f){return{oldStart:n.oldStart,oldLines:n.oldLines,newStart:n.newStart+f,newLines:n.newLines,lines:n.lines}}function a(n,f,D,k,N){var I={offset:f,lines:D,index:0},W={offset:k,lines:N,index:0};for(O(n,I,W),O(n,W,I);I.index<I.lines.length&&W.index<W.lines.length;){var B=I.lines[I.index],H=W.lines[W.index];if((B[0]==="-"||B[0]==="+")&&(H[0]==="-"||H[0]==="+"))w(n,I,W);else if(B[0]==="+"&&H[0]===" "){var Q;(Q=n.lines).push.apply(Q,o(m(I)))}else if(H[0]==="+"&&B[0]===" "){var X;(X=n.lines).push.apply(X,o(m(W)))}else B[0]==="-"&&H[0]===" "?E(n,I,W):H[0]==="-"&&B[0]===" "?E(n,W,I,!0):B===H?(n.lines.push(B),I.index++,W.index++):F(n,m(I),m(W))}z(n,I),z(n,W),S(n)}function w(n,f,D){var k=m(f),N=m(D);if(C(k)&&C(N)){if((0,s.arrayStartsWith)(k,N)&&P(D,k,k.length-N.length)){var I;(I=n.lines).push.apply(I,o(k));return}else if((0,s.arrayStartsWith)(N,k)&&P(f,N,N.length-k.length)){var W;(W=n.lines).push.apply(W,o(N));return}}else if((0,s.arrayEqual)(k,N)){var B;(B=n.lines).push.apply(B,o(k));return}F(n,k,N)}function E(n,f,D,k){var N=m(f),I=b(D,N);if(I.merged){var W;(W=n.lines).push.apply(W,o(I.merged))}else F(n,k?I:N,k?N:I)}function F(n,f,D){n.conflict=!0,n.lines.push({conflict:!0,mine:f,theirs:D})}function O(n,f,D){for(;f.offset<D.offset&&f.index<f.lines.length;){var k=f.lines[f.index++];n.lines.push(k),f.offset++}}function z(n,f){for(;f.index<f.lines.length;){var D=f.lines[f.index++];n.lines.push(D)}}function m(n){for(var f=[],D=n.lines[n.index][0];n.index<n.lines.length;){var k=n.lines[n.index];if(D==="-"&&k[0]==="+"&&(D="+"),D===k[0])f.push(k),n.index++;else break}return f}function b(n,f){for(var D=[],k=[],N=0,I=!1,W=!1;N<f.length&&n.index<n.lines.length;){var B=n.lines[n.index],H=f[N];if(H[0]==="+")break;if(I=I||B[0]!==" ",k.push(H),N++,B[0]==="+")for(W=!0;B[0]==="+";)D.push(B),B=n.lines[++n.index];H.substr(1)===B.substr(1)?(D.push(B),n.index++):W=!0}if((f[N]||"")[0]==="+"&&I&&(W=!0),W)return D;for(;N<f.length;)k.push(f[N++]);return{merged:k,changes:D}}function C(n){return n.reduce(function(f,D){return f&&D[0]==="-"},!0)}function P(n,f,D){for(var k=0;k<D;k++){var N=f[f.length-D+k].substr(1);if(n.lines[n.index+k]!==" "+N)return!1}return n.index+=D,!0}function M(n){var f=0,D=0;return n.forEach(function(k){if(typeof k!="string"){var N=M(k.mine),I=M(k.theirs);f!==void 0&&(N.oldLines===I.oldLines?f+=N.oldLines:f=void 0),D!==void 0&&(N.newLines===I.newLines?D+=N.newLines:D=void 0)}else D!==void 0&&(k[0]==="+"||k[0]===" ")&&D++,f!==void 0&&(k[0]==="-"||k[0]===" ")&&f++}),{oldLines:f,newLines:D}}},function(T,r,l){r.__esModule=!0,r.structuredPatch=s,r.createTwoFilesPatch=o,r.createPatch=S;var L=l(5);function g(d){if(Array.isArray(d)){for(var u=0,p=Array(d.length);u<d.length;u++)p[u]=d[u];return p}else return Array.from(d)}function s(d,u,p,v,c,t,a){a||(a={}),typeof a.context=="undefined"&&(a.context=4);var w=(0,L.diffLines)(p,v,a);w.push({value:"",lines:[]});function E(n){return n.map(function(f){return" "+f})}for(var F=[],O=0,z=0,m=[],b=1,C=1,P=function(f){var D=w[f],k=D.lines||D.value.replace(/\n$/,"").split(`
5
+ `);if(D.lines=k,D.added||D.removed){var N;if(!O){var I=w[f-1];O=b,z=C,I&&(m=a.context>0?E(I.lines.slice(-a.context)):[],O-=m.length,z-=m.length)}(N=m).push.apply(N,g(k.map(function(K){return(D.added?"+":"-")+K}))),D.added?C+=k.length:b+=k.length}else{if(O)if(k.length<=a.context*2&&f<w.length-2){var W;(W=m).push.apply(W,g(E(k)))}else{var B,H=Math.min(k.length,a.context);(B=m).push.apply(B,g(E(k.slice(0,H))));var Q={oldStart:O,oldLines:b-O+H,newStart:z,newLines:C-z+H,lines:m};if(f>=w.length-2&&k.length<=a.context){var X=/\n$/.test(p),we=/\n$/.test(v);k.length==0&&!X?m.splice(Q.oldLines,0,"\"):(!X||!we)&&m.push("\")}F.push(Q),O=0,z=0,m=[]}b+=k.length,C+=k.length}},M=0;M<w.length;M++)P(M);return{oldFileName:d,newFileName:u,oldHeader:c,newHeader:t,hunks:F}}function o(d,u,p,v,c,t,a){var w=s(d,u,p,v,c,t,a),E=[];d==u&&E.push("Index: "+d),E.push("==================================================================="),E.push("--- "+w.oldFileName+(typeof w.oldHeader=="undefined"?"":" "+w.oldHeader)),E.push("+++ "+w.newFileName+(typeof w.newHeader=="undefined"?"":" "+w.newHeader));for(var F=0;F<w.hunks.length;F++){var O=w.hunks[F];E.push("@@ -"+O.oldStart+","+O.oldLines+" +"+O.newStart+","+O.newLines+" @@"),E.push.apply(E,O.lines)}return E.join(`
6
+ `)+`
7
+ `}function S(d,u,p,v,c,t){return o(d,d,u,p,v,c,t)}},function(T,r){r.__esModule=!0,r.arrayEqual=l,r.arrayStartsWith=L;function l(g,s){return g.length!==s.length?!1:L(g,s)}function L(g,s){if(s.length>g.length)return!1;for(var o=0;o<s.length;o++)if(s[o]!==g[o])return!1;return!0}},function(T,r){r.__esModule=!0,r.convertChangesToDMP=l;function l(L){for(var g=[],s=void 0,o=void 0,S=0;S<L.length;S++)s=L[S],s.added?o=1:s.removed?o=-1:o=0,g.push([o,s.value]);return g}},function(T,r){r.__esModule=!0,r.convertChangesToXML=l;function l(g){for(var s=[],o=0;o<g.length;o++){var S=g[o];S.added?s.push("<ins>"):S.removed&&s.push("<del>"),s.push(L(S.value)),S.added?s.push("</ins>"):S.removed&&s.push("</del>")}return s.join("")}function L(g){var s=g;return s=s.replace(/&/g,"&amp;"),s=s.replace(/</g,"&lt;"),s=s.replace(/>/g,"&gt;"),s=s.replace(/"/g,"&quot;"),s}}])})}),An=kn(_),Zn=_.Diff,Yn=_.JsDiff,et=_.applyPatch,nt=_.applyPatches,tt=_.arrayDiff,rt=_.arrayEqual,at=_.arrayStartsWith,it=_.calcLineCount,st=_.canonicalize,ut=_.characterDiff,lt=_.convertChangesToDMP,ot=_.convertChangesToXML,ct=_.createPatch,ft=_.createTwoFilesPatch,dt=_.cssDiff,Je=An,ht=_.diffArrays,pt=_.diffChars,mt=_.diffCss,vt=_.diffJson,gt=_.diffLines,yt=_.diffSentences,wt=_.diffTrimmedLines,St=_.diffWords,Lt=_.diffWordsWithSpace,bt=_.generateOptions,Ct=_.jsonDiff,Et=_.lineDiff,kt=_.merge,Tt=_.parsePatch,Dt=_.sentenceDiff,At=_.structuredPatch,xt=_.wordDiff;function xn(R){return R&&R.__esModule&&Object.prototype.hasOwnProperty.call(R,"default")?R.default:R}function oe(R,x,T){return T={path:x,exports:{},require:function(r,l){return Pn(r,l??T.path)}},R(T,T.exports),T.exports}function Pn(){throw new Error("Dynamic requires are not currently supported by @rollup/plugin-commonjs")}var h=oe(function(R,x){Object.defineProperty(x,"__esModule",{value:!0});function T(o){return{type:"concat",parts:o}}x.concat=T;function r(o,S){let d=[];return S.forEach((u,p)=>{p>0&&d.push(o),d.push(u)}),T(d)}x.join=r,x.line={type:"line",hard:!1,soft:!1},x.hardline={type:"line",hard:!0,soft:!1},x.softline={type:"line",hard:!1,soft:!0};function l(o){return{type:"indent",content:o}}x.indent=l;function L(o){return{type:"lineSuffix",content:o}}x.lineSuffix=L;function g(o,S=!1){return{type:"group",content:o,willBreak:S}}x.group=g,x.breakParent={type:"breakParent"};function s(o){return typeof o=="string"&&o.length===0}x.isEmpty=s}),q=oe(function(R,x){Object.defineProperty(x,"__esModule",{value:!0});function T(t){return t.range[0]}x.locStart=T;function r(t){return t.range[1]}x.locEnd=r;function l(t){if(!t||typeof t.type!="string")return!1;switch(t.type){case"LabelStatement":case"BreakStatement":case"GotoStatement":case"ReturnStatement":case"IfStatement":case"IfClause":case"ElseifClause":case"ElseClause":case"WhileStatement":case"DoStatement":case"RepeatStatement":case"LocalStatement":case"AssignmentStatement":case"CallStatement":case"FunctionDeclaration":case"ForNumericStatement":case"ForGenericStatement":case"Chunk":case"Identifier":case"BooleanLiteral":case"NilLiteral":case"NumericLiteral":case"StringLiteral":case"VarargLiteral":case"TableKey":case"TableKeyString":case"TableValue":case"TableConstructorExpression":case"BinaryExpression":case"LogicalExpression":case"UnaryExpression":case"MemberExpression":case"IndexExpression":case"CallExpression":case"TableCallExpression":case"StringCallExpression":case"Comment":return!0;default:return!1}}x.isNode=l;function L(t,a,w,E={}){let F=0;return w.forEach(O=>{if((E.searchBackwards?t.substring(a-O.length,a):t.substring(a,a+O.length))===O){F=O.length;return}}),a+(E.searchBackwards?-F:F)}x.skipOnce=L;function g(t,a,w,E={}){let F=null;for(;F!==a;)F=a,a=L(t,a,w,E);return a}x.skipMany=g;function s(t,a,w={}){return L(t,a,[`
8
+ `,`\r
9
+ `],w)}x.skipNewLine=s;function o(t,a,w={}){return g(t,a,[" "," "],w)}x.skipSpaces=o;function S(t,a,w={}){return g(t,o(t,a),[";"],w)}x.skipToLineEnd=S;function d(t,a,w={}){let E=o(t,a,w),F=s(t,E,w);return E!==F}x.hasNewLine=d;function u(t,a,w){return t.substr(a,w-a).indexOf(`
10
+ `)!==-1}x.hasNewLineInRange=u;function p(t,a){a=o(t,a,{searchBackwards:!0}),a=s(t,a,{searchBackwards:!0}),a=o(t,a,{searchBackwards:!0});let w=s(t,a,{searchBackwards:!0});return a!==w}x.isPreviousLineEmpty=p;function v(t,a){if(t.charAt(a)==="-"&&t.charAt(a+1)==="-")for(a+=2;a>=0&&a<t.length;){if(t.charAt(a)===`
11
+ `||t.charAt(a)==="\r"&&t.charAt(a+1)===`
12
+ `)return a;a++}return a}x.skipTrailingComment=v;function c(t,a,w={searchBackwards:!1}){a=S(t,a,w);let E=null;for(;a!==E;)E=a,a=o(t,a,w);return a=v(t,a),a=s(t,a,w),d(t,a)}x.isNextLineEmpty=c}),ge=oe(function(R,x){Object.defineProperty(x,"__esModule",{value:!0});var T;(function(m){m[m.Leading=0]="Leading",m[m.Trailing=1]="Trailing",m[m.Dangling=2]="Dangling",m[m.DanglingStatement=3]="DanglingStatement"})(T||(T={}));function r(m){let b=Object.keys(m),C=[];function P(M){if(M&&typeof M.type=="string"&&M.type!=="Comment"){let n;for(n=C.length-1;n>=0&&!(q.locStart(C[n])<=q.locStart(M)&&q.locEnd(C[n])<=q.locEnd(m));--n);C.splice(n+1,0,M)}}for(let M of b){let n=m[M];Array.isArray(n)?n.forEach(P):n&&P(n)}return C}function l(m,b){for(let C of m.comments){u(m,C);let P=C.precedingNode,M=C.enclosingNode,n=C.followingNode;q.hasNewLine(b.sourceText,q.locStart(C),{searchBackwards:!0})?w(M,C)||E(P,M,C)||F(P,M,n,C)||(n?v(n,C):P?a(P,C):c(M||m,C)):O(P,M,C)||z(P,M,C)||(P?a(P,C):n?v(n,C):c(M||m,C))}}x.attachComments=l;function L(m,b){if(!b.sourceText.startsWith("#!"))return;let C=b.sourceText.indexOf(`
13
+ `),P=b.sourceText.slice(0,C),M=b.sourceText.slice(2,C);m.comments.push({type:"Comment",loc:{start:{line:1,column:0},end:{line:1,column:C}},range:[0,C],raw:P,value:M})}x.injectShebang=L;function g(m,b=!1){let C=m.getValue();if(!C||!C.attachedComments)return"";let P=[];return m.forEach(M=>{let n=M.getValue();n.commentType===T.Dangling&&P.push(n.raw)},"attachedComments"),P.length===0?"":b?h.join(h.hardline,P):h.indent(h.concat([h.hardline,h.join(h.hardline,P)]))}x.printDanglingComments=g;function s(m){let b=m.getValue();if(!b||!b.attachedComments)return"";let C=[];return m.forEach(P=>{let M=P.getValue();M.commentType===T.DanglingStatement&&(C.push(" "),C.push(M.raw))},"attachedComments"),C.length===0?"":h.concat(C)}x.printDanglingStatementComments=s;function o(m,b){let C=m.getValue();if(C.raw.startsWith("--[["))return h.concat([C.raw,q.hasNewLine(b.sourceText,q.locEnd(C))?h.hardline:" "]);let M=[];return M.push(C.raw),M.push(h.hardline),q.isNextLineEmpty(b.sourceText,q.locEnd(C))&&M.push(h.hardline),h.concat(M)}function S(m,b){let C=m.getValue();if(q.hasNewLine(b.sourceText,q.locStart(C),{searchBackwards:!0})){let M=q.isPreviousLineEmpty(b.sourceText,q.locStart(C));return h.concat([h.hardline,M?h.hardline:"",C.raw])}if(C.raw.startsWith("--[["))return h.concat([" ",C.raw]);let P=[];return q.isNextLineEmpty(b.sourceText,q.locStart(C),{searchBackwards:!0})&&P.push(h.hardline),P.push(" "),P.push(C.raw),P.push(h.breakParent),h.lineSuffix(h.concat(P))}function d(m,b,C){let P=m.getValue(),M=C(m),n=P.attachedComments;if(!n||n.length===0)return M;let f=[],D=[M];return m.forEach(k=>{switch(k.getValue().commentType){case T.Leading:f.push(o(m,b));break;case T.Trailing:D.push(S(m,b));break}},"attachedComments"),h.concat(f.concat(D))}x.printComments=d;function u(m,b){let C=r(m),P=null,M=null,n=0,f=C.length;for(;n<f;){let D=Math.floor((n+f)/2),k=C[D];if(q.locStart(k)-q.locStart(b)<=0&&q.locEnd(b)-q.locEnd(k)<=0){b.enclosingNode=k,u(k,b);return}if(q.locEnd(k)-q.locStart(b)<=0){P=k,n=D+1;continue}if(q.locEnd(b)-q.locStart(k)<=0){M=k,f=D;continue}}P&&(b.precedingNode=P),M&&(b.followingNode=M)}function p(m,b){(m.attachedComments||(m.attachedComments=[])).push(b)}function v(m,b){b.commentType=T.Leading,p(m,b)}function c(m,b){b.commentType=T.Dangling,p(m,b)}function t(m,b){b.commentType=T.DanglingStatement,p(m,b)}function a(m,b){b.commentType=T.Trailing,p(m,b)}function w(m,b){return!m||m.body==null?!1:m.body.length===0?(c(m,b),!0):!1}function E(m,b,C){return!b||b.type!=="FunctionDeclaration"||b.body.length>0?!1:b.parameters.length>0&&b.parameters[b.parameters.length-1]===m||m&&m.type==="Identifier"?(c(b,C),!0):!1}function F(m,b,C,P){return!b||b.type!=="IfStatement"?!1:C&&(C.type==="ElseifClause"||C.type==="ElseClause")||m&&m.type==="ElseClause"?(c(m,P),!0):!1}function O(m,b,C){if(C.raw.startsWith("--[[")||!b)return!1;switch(b.type){case"WhileStatement":if(m===b.condition)return t(b,C),!0;break;case"DoStatement":case"RepeatStatement":if(m==null)return t(b,C),!0;break;case"FunctionDeclaration":if(b.parameters.length&&m===b.parameters[b.parameters.length-1]||m===b.identifier)return t(b,C),!0;break;case"ForNumericStatement":if(m===b.end||m===b.step)return t(b,C),!0;break;case"ForGenericStatement":if(m===b.iterators[b.iterators.length-1])return t(b,C),!0;break;case"IfClause":case"ElseifClause":if(m===b.condition&&C.loc.start.column>m.loc.start.column)return t(b,C),!0;break;case"ElseClause":if(m==null)return t(b,C),!0;break}return!1}function z(m,b,C){if(!m||!b||b.type!=="IfStatement")return!1;switch(m.type){case"IfClause":case"ElseifClause":case"ElseClause":if(m.body.length===0)return t(m,C),!0;break}return!1}}),Mn=oe(function(R,x){Object.defineProperty(x,"__esModule",{value:!0});class T{constructor(l){this.stack=[l]}getValue(){return this.stack[this.stack.length-1]}getNodeAtDepth(l){for(let L=this.stack.length-1;L>=0;L-=2){let g=this.stack[L];if(q.isNode(g)&&--l<0)return g}return null}getParent(l=0){return this.getNodeAtDepth(l+1)}call(l,L){let g=this.getValue(),s=this.stack.length;this.stack.push(L,g[L]);let o=l(this);return this.stack.length=s,o}forEach(l,L=null){let g=this.getValue(),s=this.stack.length;L&&(g=g[L],this.stack.push(g));for(let o=0;o<g.length;++o)this.stack.push(o,g[o]),l(this,o),this.stack.length-=2;this.stack.length=s}map(l,L){let g=this.getValue()[L];if(!Array.isArray(g))return[];let s=[],o=this.stack.length;return this.stack.push(L,g),g.forEach((S,d)=>{this.stack.push(d,S),s.push(l(this,d)),this.stack.length-=2}),this.stack.length=o,s}needsParens(){let l=this.getParent(),L=this.getValue(),g=!1;switch(L.type){case"FunctionDeclaration":case"Chunk":case"Identifier":case"BooleanLiteral":case"NilLiteral":case"NumericLiteral":case"StringLiteral":case"VarargLiteral":case"TableConstructorExpression":case"BinaryExpression":case"LogicalExpression":case"UnaryExpression":case"MemberExpression":case"IndexExpression":case"CallExpression":case"TableCallExpression":case"StringCallExpression":g=L.inParens||!1}return l&&L.type==="UnaryExpression"&&l.type==="UnaryExpression"&&(g=!0),g}}x.FastPath=T}),Ue=oe(function(R,x){Object.defineProperty(x,"__esModule",{value:!0});function T(s,o,S){let d=!1,u=p=>{if(o(p)){d=!0;return}if(!d&&typeof p!="string"){switch(p.type){case"concat":p.parts.forEach(u);break;case"indent":case"group":case"lineSuffix":u(p.content);break}S&&S(p)}};u(s)}function r(s,o){let S=!1;return T(s,d=>o(d)?(S=!0,!0):!1),S}function l(s){return r(s,o=>{if(typeof o=="string")return!1;switch(o.type){case"line":if(o.hard)return!0;break;case"group":if(o.willBreak)return!0}return!1})}x.willBreak=l;function L(s){s.length>0&&(s[s.length-1].willBreak=!0)}function g(s){let o=[];T(s,S=>{if(typeof S=="string")return!1;switch(S.type){case"breakParent":L(o);break;case"group":o.push(S);break}return!1},S=>{if(typeof S=="string")return!1;if(S.type==="group"){let d=o.pop();d&&d.willBreak&&L(o)}return!1})}x.propagateBreaks=g}),ke=oe(function(R,x){Object.defineProperty(x,"__esModule",{value:!0});var T;(function(L){L.StdOut="stdout",L.Replace="replace",L.Diff="diff"})(T=x.WriteMode||(x.WriteMode={})),x.defaultOptions={sourceText:"",lineWidth:120,indentCount:4,useTabs:!1,linebreakMultipleAssignments:!1,quotemark:"double",writeMode:T.StdOut};function r(L){return L==="single"?"'":'"'}x.getStringQuotemark=r;function l(L){return L==="single"?'"':"'"}x.getAlternativeStringQuotemark=l}),Fn=oe(function(R,x){Object.defineProperty(x,"__esModule",{value:!0});function T(u,p,v){let c=[];return u.forEach(t=>{let a=[v(t)];q.isNextLineEmpty(p.sourceText,q.locEnd(t.getValue()))&&!s(u)&&a.push(h.hardline),c.push(h.concat(a))}),h.join(h.hardline,c)}function r(u,p,v,c){let t=u.call(a=>T(a,p,v),c);return h.indent(h.concat([h.hardline,t]))}function l(u){return u.getValue().attachedComments?h.concat([ge.printDanglingStatementComments(u),ge.printDanglingComments(u)]):""}function L(u,p){let v=ke.getStringQuotemark(p),c=ke.getAlternativeStringQuotemark(p==="single"?"single":"double"),t=u.replace(/\\([\s\S])|(['"])/g,(a,w,E)=>w===c?w:E===v?"\\"+E:a);return v+t+v}function g(u,p){let v=u.getValue();if(v.type!=="StringLiteral")throw new Error("printStringLiteral: Expected StringLiteral, got "+v.type);if(v.raw.startsWith("[[")||v.raw.startsWith("[="))return v.raw;let c=v.raw.slice(1,-1),t=p.quotemark,a=ke.getStringQuotemark(t);return c.includes(a)&&(t=t==="single"?"double":"single"),L(c,t)}function s(u){let p=u.getParent(),v=u.getValue(),c=p.body;return c&&c[c.length-1]===v}function o(u,p,v){let c=u.getValue();if(!c)return"";let t=[],a=c;switch(a.type){case"Chunk":return t.push(u.call(P=>T(P,p,v),"body")),t.push(ge.printDanglingComments(u,!0)),(a.body.length||a.attachedComments)&&t.push(h.hardline),h.concat(t);case"LabelStatement":return h.concat(["::",u.call(v,"label"),"::"]);case"GotoStatement":return h.concat(["goto ",u.call(v,"label")]);case"BreakStatement":return"break";case"ReturnStatement":return t.push("return"),a.arguments.length>0&&(t.push(" "),t.push(h.join(", ",u.map(v,"arguments")))),h.concat(t);case"WhileStatement":return t.push("while "),t.push(u.call(v,"condition")),t.push(" do"),t.push(l(u)),a.body.length&&t.push(r(u,p,v,"body")),t.push(h.concat([h.hardline,"end"])),h.concat(t);case"DoStatement":return t.push("do"),t.push(l(u)),a.body.length&&t.push(r(u,p,v,"body")),t.push(h.concat([h.hardline,"end"])),h.concat(t);case"RepeatStatement":return t.push("repeat"),t.push(l(u)),a.body.length&&t.push(r(u,p,v,"body")),t.push(h.concat([h.hardline,"until "])),t.push(u.call(v,"condition")),h.concat(t);case"LocalStatement":case"AssignmentStatement":{let P=[];a.type==="LocalStatement"&&P.push("local ");let M=p.linebreakMultipleAssignments;P.push(h.indent(h.join(h.concat([",",M?h.hardline:h.line]),u.map(v,"variables"))));let n="",f=[];a.init.length&&(n=" =",a.init.length>1?f.push(h.indent(h.join(h.concat([",",h.line]),u.map(v,"init")))):f.push(h.join(h.concat([",",h.line]),u.map(v,"init"))));let D=a.init.some(k=>k!=null&&k.type!=="TableConstructorExpression"&&k.type!=="FunctionDeclaration");return h.group(h.concat([h.group(h.concat(P)),h.group(h.concat([n,D?h.indent(h.line):" ",h.concat(f)]))]))}case"CallStatement":return u.call(v,"expression");case"FunctionDeclaration":return a.isLocal&&t.push("local "),t.push("function"),a.identifier&&t.push(" ",u.call(v,"identifier")),t.push(h.concat(["(",h.group(h.indent(h.concat([h.softline,h.join(h.concat([",",h.line]),u.map(v,"parameters"))]))),")"])),t.push(l(u)),a.body.length&&t.push(r(u,p,v,"body")),t.push(h.hardline,"end"),h.concat(t);case"ForNumericStatement":return t.push("for "),t.push(u.call(v,"variable")),t.push(" = "),t.push(u.call(v,"start")),t.push(", "),t.push(u.call(v,"end")),a.step&&(t.push(", "),t.push(u.call(v,"step"))),t.push(" do"),t.push(l(u)),a.body.length&&t.push(r(u,p,v,"body")),t.push(h.concat([h.hardline,"end"])),h.concat(t);case"ForGenericStatement":return t.push("for "),t.push(h.join(", ",u.map(v,"variables"))),t.push(" in "),t.push(h.join(", ",u.map(v,"iterators"))),t.push(" do"),t.push(l(u)),a.body.length&&t.push(r(u,p,v,"body")),t.push(h.concat([h.hardline,"end"])),h.concat(t);case"IfStatement":let w=[];return u.forEach(P=>{w.push(v(P))},"clauses"),t.push(h.join(h.hardline,w)),t.push(h.concat([h.hardline,"end"])),h.concat(t);case"IfClause":return t.push(h.concat(["if ",h.group(h.concat([h.indent(h.concat([h.softline,u.call(v,"condition")])),h.softline]))," then"])),t.push(l(u)),a.body.length&&t.push(r(u,p,v,"body")),h.concat(t);case"ElseifClause":return t.push(h.concat(["elseif ",h.group(h.concat([h.indent(h.concat([h.softline,u.call(v,"condition")])),h.softline]))," then"])),t.push(l(u)),a.body.length&&t.push(r(u,p,v,"body")),h.concat(t);case"ElseClause":return t.push("else"),t.push(l(u)),a.body.length&&t.push(r(u,p,v,"body")),h.concat(t);case"BooleanLiteral":return a.raw;case"NilLiteral":return"nil";case"NumericLiteral":return a.raw;case"StringLiteral":return g(u,p);case"VarargLiteral":return"...";case"Identifier":return a.name;case"BinaryExpression":case"LogicalExpression":let F=u.getParent().type!==a.type&&a.left.type!==a.type&&a.right.type!==a.type,O=h.concat([a.operator,h.line,u.call(v,"right")]);return h.group(h.concat([u.call(v,"left"),h.indent(h.concat([" ",F?h.group(O):O]))]));case"UnaryExpression":return t.push(a.operator),a.operator==="not"&&t.push(" "),t.push(u.call(v,"argument")),h.concat(t);case"MemberExpression":return h.concat([u.call(v,"base"),a.indexer,u.call(v,"identifier")]);case"IndexExpression":return h.concat([u.call(v,"base"),"[",h.group(h.concat([h.indent(h.concat([h.softline,u.call(v,"index")])),h.softline])),"]"]);case"CallExpression":let z=u.map(v,"arguments");return h.concat([u.call(v,"base"),h.group(h.concat(["(",h.indent(h.concat([h.softline,h.join(h.concat([",",h.line]),z)])),h.softline,")"]),z.some(Ue.willBreak))]);case"TableCallExpression":return t.push(u.call(v,"base")),t.push(" "),t.push(u.call(v,"arguments")),h.concat(t);case"StringCallExpression":return t.push(u.call(v,"base")),t.push(" "),t.push(u.call(v,"argument")),h.concat(t);case"TableConstructorExpression":if(a.fields.length===0)return"{}";let m=[],b=[];u.forEach(P=>{m.push(h.concat(b)),m.push(h.group(v(P))),b=[",",h.line]},"fields");let C=q.hasNewLineInRange(p.sourceText,a.range[0],a.range[1]);return h.group(h.concat(["{",h.indent(h.concat([h.softline,h.concat(m)])),h.softline,"}"]),C);case"TableKeyString":return h.concat([u.call(v,"key")," = ",u.call(v,"value")]);case"TableKey":return h.concat(["[",u.call(v,"key"),"]"," = ",u.call(v,"value")]);case"TableValue":return u.call(v,"value")}throw new Error("Unhandled AST node: "+a.type)}function S(u,p,v){let c=o(u,p,v),t=[],a=u.needsParens();return a&&t.push("("),t.push(c),a&&t.push(")"),h.concat(t)}function d(u,p){let v=t=>ge.printComments(t,p,a=>S(a,p,v)),c=v(new Mn.FastPath(u));return Ue.propagateBreaks(c),c}x.buildDocFromAst=d}),On=oe(function(R,x){Object.defineProperty(x,"__esModule",{value:!0});var T;(function(g){g[g.Flat=0]="Flat",g[g.Break=1]="Break"})(T||(T={}));function r(g,s){let o={options:s,indentation:0,currentLineLength:0,mode:T.Break,lineSuffixes:[],renderedText:""};return L(g,o),o.renderedText}x.printDocToString=r;function l(g,s){function o(S){return s.currentLineLength+S.length<=s.options.lineWidth?(s.currentLineLength+=S.length,!0):!1}if(typeof g=="string")return o(g);switch(g.type){case"concat":return g.parts.every(S=>l(S,s));case"indent":return s.indentation++,l(g.content,s)?(s.indentation--,!0):(s.indentation--,!1);case"group":return g.willBreak&&(s.mode=T.Break),l(g.content,s);case"line":return s.mode===T.Flat&&!g.hard?g.soft?!0:o(" "):(s.currentLineLength=s.indentation,!0);case"lineSuffix":return!0}return!1}function L(g,s){if(typeof g=="string")s.renderedText+=g,s.currentLineLength+=g.length;else switch(g.type){case"concat":for(let u of g.parts)L(u,s);break;case"line":if(s.mode===T.Flat&&!g.hard){g.soft||(s.renderedText+=" ",s.currentLineLength+=1);break}if(s.lineSuffixes.length>0){let u=[...s.lineSuffixes];s.lineSuffixes.length=0;for(let p of u)L(p.content,s)}s.renderedText.length>0&&(s.renderedText=s.renderedText.replace(/[^\S\n]*$/,""));let o=s.options.useTabs?" ".repeat(s.indentation):" ".repeat(s.indentation*s.options.indentCount);s.renderedText+=`
14
+ `+o,s.currentLineLength=o.length;break;case"indent":{s.indentation++,L(g.content,s),s.indentation--;break}case"lineSuffix":s.lineSuffixes.push(g);break;case"group":let S=l(g,Object.assign({},s,{mode:T.Flat})),d=s.mode;!g.willBreak&&S?s.mode=T.Flat:s.mode=T.Break,L(g.content,s),s.mode=d;break}}}),ye=oe(function(R,x){Object.defineProperty(x,"__esModule",{value:!0});var T=ke;x.defaultOptions=T.defaultOptions,x.WriteMode=T.WriteMode;function r(L,g){let s=Ge.parse(L,{comments:!0,locations:!0,ranges:!0,luaVersion:"5.3"});s.range[0]=0,s.range[1]=L.length;let o=Object.assign({},ke.defaultOptions,g),S=Object.assign({},o,{sourceText:L});ge.injectShebang(s,S),ge.attachComments(s,S);let d=Fn.buildDocFromAst(s,S);return On.printDocToString(d,S)}x.formatText=r;function l(L,g,s){return Je.createPatch(L,g,s,"original","formatted")}x.producePatch=l}),In=xn(ye),Wn=ye.WriteMode,Ke=In,Bn=ye.defaultOptions,Nn=ye.formatText,Vn=ye.producePatch;return Hn;})();
15
+ /*!
16
+
17
+ diff v3.5.0
18
+
19
+ Software License Agreement (BSD License)
20
+
21
+ Copyright (c) 2009-2015, Kevin Decker <kpdecker@gmail.com>
22
+
23
+ All rights reserved.
24
+
25
+ Redistribution and use of this software in source and binary forms, with or without modification,
26
+ are permitted provided that the following conditions are met:
27
+
28
+ * Redistributions of source code must retain the above
29
+ copyright notice, this list of conditions and the
30
+ following disclaimer.
31
+
32
+ * Redistributions in binary form must reproduce the above
33
+ copyright notice, this list of conditions and the
34
+ following disclaimer in the documentation and/or other
35
+ materials provided with the distribution.
36
+
37
+ * Neither the name of Kevin Decker nor the names of its
38
+ contributors may be used to endorse or promote products
39
+ derived from this software without specific prior
40
+ written permission.
41
+
42
+ THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR
43
+ IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
44
+ FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
45
+ CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
46
+ DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
47
+ DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER
48
+ IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
49
+ OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
50
+ @license
51
+ */
@@ -0,0 +1 @@
1
+ from https://esbuild.vercel.app/lua-fmt@2.6.0?format=iife&globalName=luaFmt