@arcgis/coding-components 4.29.0-beta.49 → 4.29.0-beta.50

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.
Files changed (43) hide show
  1. package/dist/arcgis-coding-components/arcgis-coding-components.esm.js +1 -1
  2. package/dist/arcgis-coding-components/assets/code-editor/arcade.worker.js +2 -2
  3. package/dist/arcgis-coding-components/index.esm.js +1 -1
  4. package/dist/arcgis-coding-components/{p-7475f3a6.js → p-0a53fe19.js} +1 -1
  5. package/dist/arcgis-coding-components/{p-ff21f230.js → p-8f70c5af.js} +1 -1
  6. package/dist/arcgis-coding-components/{p-aefe77ce.js → p-99fbda7a.js} +1 -1
  7. package/dist/arcgis-coding-components/{p-9f6db08a.js → p-c00e3a35.js} +1 -1
  8. package/dist/arcgis-coding-components/{p-7d8caba9.js → p-d622ac25.js} +1 -1
  9. package/dist/arcgis-coding-components/{p-d425a387.js → p-dc1deab5.js} +1 -1
  10. package/dist/arcgis-coding-components/{p-5ddccf04.js → p-e23bef61.js} +1 -1
  11. package/dist/arcgis-coding-components/p-f3be955a.entry.js +1 -0
  12. package/dist/arcgis-coding-components/{p-0d616249.js → p-f5598cde.js} +7 -7
  13. package/dist/arcgis-coding-components/{p-5802524a.js → p-f9ddcb21.js} +1 -1
  14. package/dist/cjs/{arcade-defaults-2d513b59.js → arcade-defaults-62df45ef.js} +8 -8
  15. package/dist/cjs/{arcade-mode-6219f1b8.js → arcade-mode-029b2c16.js} +2 -2
  16. package/dist/cjs/arcgis-arcade-api_6.cjs.entry.js +7 -6
  17. package/dist/cjs/{cssMode-1ec48254.js → cssMode-65260fc7.js} +1 -1
  18. package/dist/cjs/{html-0e1741fe.js → html-c6e0b09d.js} +1 -1
  19. package/dist/cjs/{htmlMode-279d3c29.js → htmlMode-3b2449e0.js} +1 -1
  20. package/dist/cjs/index.cjs.js +1 -1
  21. package/dist/cjs/{javascript-04f1bce0.js → javascript-17ac37a3.js} +2 -2
  22. package/dist/cjs/{jsonMode-59322f7a.js → jsonMode-4f26087b.js} +1 -1
  23. package/dist/cjs/{tsMode-17561f70.js → tsMode-d20bed54.js} +1 -1
  24. package/dist/cjs/{typescript-b7da8629.js → typescript-cacef1c1.js} +1 -1
  25. package/dist/components/arcade-api.js +2 -1
  26. package/dist/components/arcade-defaults.js +1 -1
  27. package/dist/components/arcade-mode.js +1 -1
  28. package/dist/components/arcade-results.js +1 -1
  29. package/dist/components/arcgis-arcade-editor.js +1 -1
  30. package/dist/components/markdown.js +1 -1
  31. package/dist/esm/{arcade-defaults-0bafa696.js → arcade-defaults-2ce9f0c3.js} +8 -8
  32. package/dist/esm/{arcade-mode-c17a1fa1.js → arcade-mode-e78165f9.js} +2 -2
  33. package/dist/esm/arcgis-arcade-api_6.entry.js +7 -6
  34. package/dist/esm/{cssMode-3d18bd2b.js → cssMode-108dda4d.js} +1 -1
  35. package/dist/esm/{html-2bce5d77.js → html-a19f99cb.js} +1 -1
  36. package/dist/esm/{htmlMode-69d56956.js → htmlMode-cd3f510a.js} +1 -1
  37. package/dist/esm/index.js +1 -1
  38. package/dist/esm/{javascript-ded5c9d7.js → javascript-552ad17f.js} +2 -2
  39. package/dist/esm/{jsonMode-0bf84cb2.js → jsonMode-ca43c6cd.js} +1 -1
  40. package/dist/esm/{tsMode-15d4e936.js → tsMode-bd6f8aa1.js} +1 -1
  41. package/dist/esm/{typescript-cc4d00f0.js → typescript-8e361b98.js} +1 -1
  42. package/package.json +6 -6
  43. package/dist/arcgis-coding-components/p-ce2be55e.entry.js +0 -1
@@ -1 +1 @@
1
- import{p as e,b as t}from"./p-2c0d6f15.js";export{s as setNonce}from"./p-2c0d6f15.js";(()=>{const t=import.meta.url,n={};return""!==t&&(n.resourcesUrl=new URL(".",t).href),e(n)})().then((e=>t([["p-ce2be55e",[[0,"arcgis-arcade-editor",{profile:[16],script:[1],testData:[16],suggestions:[16],snippets:[16],hideDocumentationActions:[4,"hide-documentation-actions"],hideSideBar:[4,"hide-side-bar"],sideActionBarExpanded:[1540,"side-action-bar-expanded"],openedSidePanel:[1537,"opened-side-panel"],_lang:[32],_t9nLocale:[32],_t9nStrings:[32],_standaloneCodeEditor:[32],_preparingProfile:[32],_editorProfile:[32],_showExecutionPanel:[32],_resultPanel:[32],_executingScript:[32],_consoleLogs:[32],_executionResult:[32],getScript:[64],setFocus:[64],getEditorInstance:[64],getTestResult:[64],getOutputType:[64],updateThemeColors:[64]},null,{profile:["_profileChanged"],testData:["_testDataChanged"],snippets:["_snippetChanged"]}],[1,"arcgis-arcade-api",{hideDocumentationActions:[4,"hide-documentation-actions"],modelId:[1,"model-id"],_lang:[32],_t9nLocale:[32],_t9nStrings:[32],_selectedApiItem:[32],_filterValue:[32],_colorizeStyle:[32],_preparingApi:[32],_apiLibrary:[32]}],[1,"arcgis-arcade-results",{loading:[4],openedResultPanel:[1537,"opened-result-panel"],result:[16],consoleLogs:[16],_lang:[32],_t9nLocale:[32],_t9nStrings:[32]}],[1,"arcgis-arcade-suggestions",{suggestions:[16],_lang:[32],_t9nLocale:[32],_t9nStrings:[32],_selectedSuggestion:[32],_filterValue:[32],_colorizeStyle:[32]},null,{suggestions:["suggestionsPropChanged"]}],[1,"arcgis-arcade-variables",{loading:[4],modelId:[1,"model-id"],_lang:[32],_t9nLocale:[32],_t9nStrings:[32],_mutationCounter:[32],_flowItemRenderers:[32],_filterValue:[32]},null,{modelId:["modelIdPropChanged"]}],[0,"arcgis-code-editor",{value:[1],language:[1],modelId:[1,"model-id"],getValue:[64],setValue:[64],insertText:[64],insertSnippet:[64],getEditorInstance:[64],setFocus:[64]},null,{value:["valuePropChange"],language:["languagePropChange"],modelId:["modelIdPropChange"]}]]]],e)));
1
+ import{p as e,b as t}from"./p-2c0d6f15.js";export{s as setNonce}from"./p-2c0d6f15.js";(()=>{const t=import.meta.url,n={};return""!==t&&(n.resourcesUrl=new URL(".",t).href),e(n)})().then((e=>t([["p-f3be955a",[[0,"arcgis-arcade-editor",{profile:[16],script:[1],testData:[16],suggestions:[16],snippets:[16],hideDocumentationActions:[4,"hide-documentation-actions"],hideSideBar:[4,"hide-side-bar"],sideActionBarExpanded:[1540,"side-action-bar-expanded"],openedSidePanel:[1537,"opened-side-panel"],_lang:[32],_t9nLocale:[32],_t9nStrings:[32],_standaloneCodeEditor:[32],_preparingProfile:[32],_editorProfile:[32],_showExecutionPanel:[32],_resultPanel:[32],_executingScript:[32],_consoleLogs:[32],_executionResult:[32],getScript:[64],setFocus:[64],getEditorInstance:[64],getTestResult:[64],getOutputType:[64],updateThemeColors:[64]},null,{profile:["_profileChanged"],testData:["_testDataChanged"],snippets:["_snippetChanged"]}],[1,"arcgis-arcade-api",{hideDocumentationActions:[4,"hide-documentation-actions"],modelId:[1,"model-id"],_lang:[32],_t9nLocale:[32],_t9nStrings:[32],_selectedApiItem:[32],_filterValue:[32],_colorizeStyle:[32],_preparingApi:[32],_apiLibrary:[32]}],[1,"arcgis-arcade-results",{loading:[4],openedResultPanel:[1537,"opened-result-panel"],result:[16],consoleLogs:[16],_lang:[32],_t9nLocale:[32],_t9nStrings:[32]}],[1,"arcgis-arcade-suggestions",{suggestions:[16],_lang:[32],_t9nLocale:[32],_t9nStrings:[32],_selectedSuggestion:[32],_filterValue:[32],_colorizeStyle:[32]},null,{suggestions:["suggestionsPropChanged"]}],[1,"arcgis-arcade-variables",{loading:[4],modelId:[1,"model-id"],_lang:[32],_t9nLocale:[32],_t9nStrings:[32],_mutationCounter:[32],_flowItemRenderers:[32],_filterValue:[32]},null,{modelId:["modelIdPropChanged"]}],[0,"arcgis-code-editor",{value:[1],language:[1],modelId:[1,"model-id"],getValue:[64],setValue:[64],insertText:[64],insertSnippet:[64],getEditorInstance:[64],setFocus:[64]},null,{value:["valuePropChange"],language:["languagePropChange"],modelId:["modelIdPropChange"]}]]]],e)));
@@ -1,4 +1,4 @@
1
- (()=>{var fi=class{constructor(){this.listeners=[],this.unexpectedErrorHandler=function(t){setTimeout(()=>{throw t.stack?Mt.isErrorNoTelemetry(t)?new Mt(t.message+`
1
+ "use strict";(()=>{var fi=class{constructor(){this.listeners=[],this.unexpectedErrorHandler=function(t){setTimeout(()=>{throw t.stack?Mt.isErrorNoTelemetry(t)?new Mt(t.message+`
2
2
 
3
3
  `+t.stack):new Error(t.message+`
4
4
 
@@ -16,7 +16,7 @@
16
16
  `&&(this.index+=1),this.lineStart=this.index;else switch(o){case"n":e+=`
17
17
  `;break;case"r":e+="\r";break;case"t":e+=" ";break;case"u":if(this.source[this.index]==="{")this.index+=1,e+=this.scanUnicodeCodePointEscape();else{let a=this.index,l=this.scanHexEscape(o);l!==null?e+=l:(this.index=a,e+=o)}break;case"x":{let a=this.scanHexEscape(o);a===null&&this.throwUnexpectedToken("InvalidHexEscapeSequence"),e+=a;break}case"b":e+="\b";break;case"f":e+="\f";break;case"v":e+="\v";break;default:o==="0"?(P.isDecimalDigit(this.source.charCodeAt(this.index))&&this.throwUnexpectedToken("TemplateOctalLiteral"),e+="\0"):P.isOctalDigit(o.charCodeAt(0))?this.throwUnexpectedToken("TemplateOctalLiteral"):e+=o;break}continue}if(P.isLineTerminator(o.charCodeAt(0))){this.lineNumber+=1,o==="\r"&&this.source[this.index]===`
18
18
  `&&(this.index+=1),this.lineStart=this.index,e+=`
19
- `;continue}e+=o}return t||this.throwUnexpectedToken(),i||this.curlyStack.pop(),{type:10,value:this.source.slice(n+1,this.index-s),cooked:e,head:i,tail:r,lineNumber:this.lineNumber,lineStart:this.lineStart,start:n,end:this.index}}lex(){if(this.eof())return{type:2,value:"",lineNumber:this.lineNumber,lineStart:this.lineStart,start:this.index,end:this.index};let e=this.source.charCodeAt(this.index);return P.isIdentifierStart(e)?this.scanIdentifier():e===40||e===41||e===59?this.scanPunctuator():e===39||e===34?this.scanStringLiteral():e===46?P.isDecimalDigit(this.source.charCodeAt(this.index+1))?this.scanNumericLiteral():this.scanPunctuator():P.isDecimalDigit(e)?this.scanNumericLiteral():e===96||e===125&&this.curlyStack[this.curlyStack.length-1]==="${"?this.scanTemplate():e>=55296&&e<57343&&P.isIdentifierStart(this.codePointAt(this.index))?this.scanIdentifier():this.scanPunctuator()}};function r1(e,t=0){let n=e.start-e.lineStart,i=e.lineNumber;return n<0&&(n+=t,i-=1),{index:e.start,line:i,column:n}}function s1(e){return[{index:e.range[0],...e.loc.start},{index:e.range[1],...e.loc.end}]}function o1(e){return yr[e]??0}var gl=class{constructor(e,t={},n){this.delegate=n,this.hasLineTerminator=!1,this.options={tokens:typeof t.tokens=="boolean"&&t.tokens,comments:typeof t.comments=="boolean"&&t.comments,tolerant:typeof t.tolerant=="boolean"&&t.tolerant},this.options.comments&&(this.commentHandler=new ml),this.errorHandler=new A1(this.options.tolerant),this.scanner=new E1(e,this.errorHandler),this.context={isAssignmentTarget:!1,blockContext:0,curlyParsingType:0},this.rawToken={type:2,value:"",lineNumber:this.scanner.lineNumber,lineStart:0,start:0,end:0},this.tokens=[],this.startMarker={index:0,line:this.scanner.lineNumber,column:0},this.endMarker={index:0,line:this.scanner.lineNumber,column:0},this.readNextRawToken(),this.endMarker={index:this.scanner.index,line:this.scanner.lineNumber,column:this.scanner.index-this.scanner.lineStart}}throwIfInvalidType(e,t,{validTypes:n,invalidTypes:i}){n?.some(r=>e.type===r)||i?.some(r=>e.type===r)&&this.throwError("InvalidExpression",t)}throwError(e,t,n=this.endMarker){let{index:i,line:r,column:s}=t,o=n.index-i-1;this.errorHandler.throwError({code:e,index:i,line:r,column:s+1,len:o})}tolerateError(e,t){throw new Error("######################################### !!!")}unexpectedTokenError(e={}){let{rawToken:t}=e,{code:n,data:i}=e,r;if(t){if(!n)switch(t.type){case 2:n="UnexpectedEndOfScript";break;case 3:n="UnexpectedIdentifier";break;case 6:n="UnexpectedNumber";break;case 8:n="UnexpectedString";break;case 10:n="UnexpectedTemplate";break}r=t.value.toString()}else r="ILLEGAL";n??(n="UnexpectedToken"),i||(i={value:r});let s=Ir(n,i);if(t){let l=t.start,c=t.lineNumber,h=t.start-t.lineStart+1;return new ri({code:n,index:l,line:c,column:h,len:t.end-t.start-1,data:i,description:s})}let{index:o,line:a}=this.endMarker;return new ri({code:n,index:o,line:a,column:this.endMarker.column+1,data:i,description:s})}throwUnexpectedToken(e={}){throw e.rawToken??(e.rawToken=this.rawToken),this.unexpectedTokenError(e)}collectComments(e){let{commentHandler:t}=this;!t||!e.length||e.forEach(n=>{let i={type:n.multiLine?"BlockComment":"LineComment",value:this.getSourceValue(n),range:n.range,loc:n.loc};t.collectComment(i)})}peekAhead(e){let t=()=>(this.scanner.scanComments(),this.scanner.lex()),n=this.scanner.saveState(),i=e.call(this,t);return this.scanner.restoreState(n),i}getSourceValue(e){return this.scanner.source.slice(e.start,e.end)}convertToToken(e){return{type:b1[e.type],value:this.getSourceValue(e),range:[e.start,e.end],loc:{start:{line:this.startMarker.line,column:this.startMarker.column},end:{line:this.scanner.lineNumber,column:this.scanner.index-this.scanner.lineStart}}}}readNextRawToken(){this.endMarker.index=this.scanner.index,this.endMarker.line=this.scanner.lineNumber,this.endMarker.column=this.scanner.index-this.scanner.lineStart;let e=this.rawToken;this.collectComments(this.scanner.scanComments()),this.scanner.index!==this.startMarker.index&&(this.startMarker.index=this.scanner.index,this.startMarker.line=this.scanner.lineNumber,this.startMarker.column=this.scanner.index-this.scanner.lineStart),this.rawToken=this.scanner.lex(),this.hasLineTerminator=e.lineNumber!==this.rawToken.lineNumber,this.options.tokens&&this.rawToken.type!==2&&this.tokens.push(this.convertToToken(this.rawToken))}captureStartMarker(){return{index:this.startMarker.index,line:this.startMarker.line,column:this.startMarker.column}}getItemLocation(e){return{range:[e.index,this.endMarker.index],loc:{start:{line:e.line,column:e.column},end:{line:this.endMarker.line,column:this.endMarker.column}}}}finalize(e){return(this.delegate||this.commentHandler)&&(this.commentHandler?.attachComments(e),this.delegate?.(e)),e}expectPunctuator(e){let t=this.rawToken;if(this.matchPunctuator(e)){this.readNextRawToken();return}this.throwUnexpectedToken({rawToken:t,code:"PunctuatorExpected",data:{value:e}})}expectKeyword(e){if(this.rawToken.type===4&&this.rawToken.value.toLowerCase()===e){this.readNextRawToken();return}this.throwUnexpectedToken({rawToken:this.rawToken})}expectContextualKeyword(e){if(this.rawToken.type===3&&this.rawToken.value.toLowerCase()===e){this.readNextRawToken();return}this.throwUnexpectedToken({rawToken:this.rawToken})}matchKeyword(e){return this.rawToken.type===4&&this.rawToken.value.toLowerCase()===e}matchContextualKeyword(e){return this.rawToken.type===3&&this.rawToken.value===e}matchPunctuator(e){return this.rawToken.type===7&&this.rawToken.value===e}getMatchingPunctuator(e){if(typeof e=="string"&&(e=e.split("")),!(this.rawToken.type!==7||!e?.length))return e.find(this.matchPunctuator,this)}isolateCoverGrammar(e){let t=this.context.isAssignmentTarget;this.context.isAssignmentTarget=!0;let n=e.call(this);return this.context.isAssignmentTarget=t,n}inheritCoverGrammar(e){var t;let n=this.context.isAssignmentTarget;this.context.isAssignmentTarget=!0;let i=e.call(this);return(t=this.context).isAssignmentTarget&&(t.isAssignmentTarget=n),i}withBlockContext(e,t){let n=this.context.blockContext;this.context.blockContext|=e;let i=this.context.curlyParsingType;this.context.curlyParsingType=1;let r=t.call(this);return this.context.blockContext=n,this.context.curlyParsingType=i,r}consumeSemicolon(){if(this.matchPunctuator(";")){this.readNextRawToken();return}if(!this.hasLineTerminator){if(this.rawToken.type===2||this.matchPunctuator("}")){this.endMarker.index=this.startMarker.index,this.endMarker.line=this.startMarker.line,this.endMarker.column=this.startMarker.column;return}this.throwUnexpectedToken({rawToken:this.rawToken})}}parsePrimaryExpression(){let e=this.captureStartMarker(),t=this.rawToken;switch(t.type){case 3:return this.readNextRawToken(),this.finalize({type:"Identifier",name:t.value,...this.getItemLocation(e)});case 6:case 8:return this.context.isAssignmentTarget=!1,this.readNextRawToken(),this.finalize({type:"Literal",value:t.value,raw:this.getSourceValue(t),isString:typeof t.value=="string",...this.getItemLocation(e)});case 1:return this.context.isAssignmentTarget=!1,this.readNextRawToken(),this.finalize({type:"Literal",value:t.value.toLowerCase()==="true",raw:this.getSourceValue(t),isString:!1,...this.getItemLocation(e)});case 5:return this.context.isAssignmentTarget=!1,this.readNextRawToken(),this.finalize({type:"Literal",value:null,raw:this.getSourceValue(t),isString:!1,...this.getItemLocation(e)});case 10:return this.parseTemplateLiteral();case 7:switch(t.value){case"(":return this.inheritCoverGrammar(this.parseGroupExpression);case"[":return this.inheritCoverGrammar(this.parseArrayInitializer);case"{":return this.inheritCoverGrammar(this.parseObjectExpression);default:return this.throwUnexpectedToken({rawToken:this.rawToken})}case 4:return this.context.isAssignmentTarget=!1,this.throwUnexpectedToken({rawToken:this.rawToken});default:return this.throwUnexpectedToken({rawToken:this.rawToken})}}parseArrayInitializer(){let e=this.captureStartMarker();this.expectPunctuator("[");let t=[];for(;!this.matchPunctuator("]");){let n=this.captureStartMarker();this.matchPunctuator(",")?(this.readNextRawToken(),this.throwError("InvalidExpression",n)):(t.push(this.inheritCoverGrammar(this.parseAssignmentExpression)),this.matchPunctuator("]")||this.expectPunctuator(","))}return this.expectPunctuator("]"),this.finalize({type:"ArrayExpression",elements:t,...this.getItemLocation(e)})}parseObjectPropertyKey(){let e=this.captureStartMarker(),t=this.rawToken;switch(t.type){case 8:return this.readNextRawToken(),this.finalize({type:"Literal",value:t.value,raw:this.getSourceValue(t),isString:!0,...this.getItemLocation(e)});case 3:case 1:case 5:case 4:return this.readNextRawToken(),this.finalize({type:"Identifier",name:t.value,...this.getItemLocation(e)});default:this.throwError("KeyMustBeString",e)}}parseObjectProperty(){let e=this.rawToken,t=this.captureStartMarker(),n=this.parseObjectPropertyKey(),i=!1,r=null;return this.matchPunctuator(":")?(this.readNextRawToken(),r=this.inheritCoverGrammar(this.parseAssignmentExpression)):e.type===3?(i=!0,r=this.finalize({type:"Identifier",name:e.value,...this.getItemLocation(t)})):this.throwUnexpectedToken({rawToken:this.rawToken}),this.finalize({type:"Property",kind:"init",key:n,value:r,shorthand:i,...this.getItemLocation(t)})}parseObjectExpression(){let e=this.captureStartMarker();this.expectPunctuator("{");let t=[];for(;!this.matchPunctuator("}");)t.push(this.parseObjectProperty()),this.matchPunctuator("}")||this.expectPunctuator(",");return this.expectPunctuator("}"),this.finalize({type:"ObjectExpression",properties:t,...this.getItemLocation(e)})}parseTemplateElement(e=!1){let t=this.rawToken;t.type!==10&&this.throwUnexpectedToken({rawToken:t}),e&&!t.head&&this.throwUnexpectedToken({code:"InvalidTemplateHead",rawToken:t});let n=this.captureStartMarker();this.readNextRawToken();let{value:i,cooked:r,tail:s}=t,o=this.finalize({type:"TemplateElement",value:{raw:i,cooked:r},tail:s,...this.getItemLocation(n)});return o.loc.start.column+=1,o.loc.end.column-=s?1:2,o}parseTemplateLiteral(){let e=this.captureStartMarker(),t=[],n=[],i=this.parseTemplateElement(!0);for(n.push(i);!i.tail;)t.push(this.parseExpression()),i=this.parseTemplateElement(),n.push(i);return this.finalize({type:"TemplateLiteral",quasis:n,expressions:t,...this.getItemLocation(e)})}parseGroupExpression(){this.expectPunctuator("(");let e=this.inheritCoverGrammar(this.parseAssignmentExpression);return this.expectPunctuator(")"),e}parseArguments(){this.expectPunctuator("(");let e=[];if(!this.matchPunctuator(")"))for(;;){let t=this.isolateCoverGrammar(this.parseAssignmentExpression);if(e.push(t),this.matchPunctuator(")")||(this.expectPunctuator(","),this.matchPunctuator(")")))break}return this.expectPunctuator(")"),e}parseMemberName(){let e=this.rawToken,t=this.captureStartMarker();return this.readNextRawToken(),e.type!==5&&e.type!==3&&e.type!==4&&e.type!==1&&this.throwUnexpectedToken({rawToken:e}),this.finalize({type:"Identifier",name:e.value,...this.getItemLocation(t)})}parseLeftHandSideExpression(){let e=this.captureStartMarker(),t=this.inheritCoverGrammar(this.parsePrimaryExpression),n=this.captureStartMarker(),i;for(;i=this.getMatchingPunctuator("([.");)switch(i){case"(":{this.context.isAssignmentTarget=!1,t.type!=="Identifier"&&t.type!=="MemberExpression"&&this.throwError("IdentiferExpected",e,n);let r=this.parseArguments();t=this.finalize({type:"CallExpression",callee:t,arguments:r,...this.getItemLocation(e)});continue}case"[":{this.context.isAssignmentTarget=!0,this.expectPunctuator("[");let r=this.isolateCoverGrammar(this.parseExpression);this.expectPunctuator("]"),t=this.finalize({type:"MemberExpression",computed:!0,object:t,property:r,...this.getItemLocation(e)});continue}case".":{this.context.isAssignmentTarget=!0,this.expectPunctuator(".");let r=this.parseMemberName();t=this.finalize({type:"MemberExpression",computed:!1,object:t,property:r,...this.getItemLocation(e)});continue}default:break}return t}parseUpdateExpression(){let e=this.captureStartMarker(),t=this.getMatchingPunctuator(Sr);if(t){this.readNextRawToken();let s=this.captureStartMarker(),o=this.inheritCoverGrammar(this.parseUnaryExpression);return o.type!=="Identifier"&&o.type!=="MemberExpression"&&o.type!=="CallExpression"&&this.throwError("InvalidExpression",s),this.context.isAssignmentTarget||this.tolerateError("InvalidLeftHandSideInAssignment",e),this.context.isAssignmentTarget=!1,this.finalize({type:"UpdateExpression",operator:t,argument:o,prefix:!0,...this.getItemLocation(e)})}let n=this.captureStartMarker(),i=this.inheritCoverGrammar(this.parseLeftHandSideExpression),r=this.captureStartMarker();return this.hasLineTerminator||(t=this.getMatchingPunctuator(Sr),!t)?i:(i.type!=="Identifier"&&i.type!=="MemberExpression"&&this.throwError("InvalidExpression",n,r),this.context.isAssignmentTarget||this.tolerateError("InvalidLeftHandSideInAssignment",e),this.readNextRawToken(),this.context.isAssignmentTarget=!1,this.finalize({type:"UpdateExpression",operator:t,argument:i,prefix:!1,...this.getItemLocation(e)}))}parseUnaryExpression(){let e=this.getMatchingPunctuator(p1);if(e){let t=this.captureStartMarker();this.readNextRawToken();let n=this.inheritCoverGrammar(this.parseUnaryExpression);return this.context.isAssignmentTarget=!1,this.finalize({type:"UnaryExpression",operator:e,argument:n,prefix:!0,...this.getItemLocation(t)})}return this.parseUpdateExpression()}parseBinaryExpression(){let e=this.rawToken,t=this.inheritCoverGrammar(this.parseUnaryExpression);if(this.rawToken.type!==7)return t;let n=this.rawToken.value,i=o1(n);if(i===0)return t;this.readNextRawToken(),this.context.isAssignmentTarget=!1;let r=[e,this.rawToken],s=t,o=this.inheritCoverGrammar(this.parseUnaryExpression),a=[s,n,o],l=[i];for(;this.rawToken.type===7&&(i=o1(this.rawToken.value))>0;){for(;a.length>2&&i<=l[l.length-1];){o=a.pop();let f=a.pop();l.pop(),s=a.pop(),r.pop();let d=r[r.length-1],m=r1(d,d.lineStart);a.push(this.finalize(this.createBinaryOrLogicalExpression(m,f,s,o)))}a.push(this.rawToken.value),l.push(i),r.push(this.rawToken),this.readNextRawToken(),a.push(this.inheritCoverGrammar(this.parseUnaryExpression))}let c=a.length-1;t=a[c];let h=r.pop();for(;c>1;){let f=r.pop();if(!f)break;let d=h?.lineStart,m=r1(f,d),p=a[c-1];t=this.finalize(this.createBinaryOrLogicalExpression(m,p,a[c-2],t)),c-=2,h=f}return t}createBinaryOrLogicalExpression(e,t,n,i){let r=D1.includes(t)?"LogicalExpression":"BinaryExpression";return r==="BinaryExpression"?{type:r,operator:t,left:n,right:i,...this.getItemLocation(e)}:((n.type==="AssignmentExpression"||n.type==="UpdateExpression")&&this.throwError("InvalidExpression",...s1(n)),(i.type==="AssignmentExpression"||i.type==="UpdateExpression")&&this.throwError("InvalidExpression",...s1(n)),{type:r,operator:t,left:n,right:i,...this.getItemLocation(e)})}parseAssignmentExpression(){let e=this.captureStartMarker(),t=this.inheritCoverGrammar(this.parseBinaryExpression),n=this.captureStartMarker(),i=this.getMatchingPunctuator(x1);if(!i)return t;t.type!=="Identifier"&&t.type!=="MemberExpression"&&this.throwError("InvalidExpression",e,n),this.context.isAssignmentTarget||this.tolerateError("InvalidLeftHandSideInAssignment",e),this.matchPunctuator("=")||(this.context.isAssignmentTarget=!1),this.readNextRawToken();let r=this.isolateCoverGrammar(this.parseAssignmentExpression);return this.finalize({type:"AssignmentExpression",left:t,operator:i,right:r,...this.getItemLocation(e)})}parseExpression(){return this.isolateCoverGrammar(this.parseAssignmentExpression)}parseStatements(e){let t=[];for(;this.rawToken.type!==2&&!this.matchPunctuator(e);){let n=this.parseStatementListItem();Ur(n)||t.push(n)}return t}parseStatementListItem(){return this.context.isAssignmentTarget=!0,this.matchKeyword("function")?this.parseFunctionDeclaration():this.matchKeyword("export")?this.parseExportDeclaration():this.matchKeyword("import")?this.parseImportDeclaration():this.parseStatement()}parseBlock(){let e=this.captureStartMarker();this.expectPunctuator("{");let t=this.parseStatements("}");return this.expectPunctuator("}"),this.finalize({type:"BlockStatement",body:t,...this.getItemLocation(e)})}parseObjectStatement(){let e=this.captureStartMarker(),t=this.parseObjectExpression();return this.finalize({type:"ExpressionStatement",expression:t,...this.getItemLocation(e)})}parseBlockOrObjectStatement(){return this.context.curlyParsingType===0?this.parseObjectStatement():this.peekAhead(e=>{let t=e();return!(t.type!==3&&t.type!==8||(t=e(),t.type!==7||t.value!==":"))})?this.parseObjectStatement():this.parseBlock()}parseIdentifier(){let e=this.rawToken;if(e.type!==3)return null;let t=this.captureStartMarker();return this.readNextRawToken(),this.finalize({type:"Identifier",name:e.value,...this.getItemLocation(t)})}parseVariableDeclarator(){let e=this.captureStartMarker(),t=this.parseIdentifier();t||this.throwUnexpectedToken({code:"IdentiferExpected"});let n=null;if(this.matchPunctuator("=")){this.readNextRawToken();let i=this.rawToken;try{n=this.isolateCoverGrammar(this.parseAssignmentExpression)}catch{this.throwUnexpectedToken({rawToken:i,code:"InvalidVariableAssignment"})}}return this.finalize({type:"VariableDeclarator",id:t,init:n,...this.getItemLocation(e)})}parseVariableDeclarationList(){let e=[this.parseVariableDeclarator()];for(;this.matchPunctuator(",");)this.readNextRawToken(),e.push(this.parseVariableDeclarator());return e}parseVariableDeclaration(){let e=this.captureStartMarker();this.expectKeyword("var");let t=this.parseVariableDeclarationList();return this.consumeSemicolon(),this.finalize({type:"VariableDeclaration",declarations:t,kind:"var",...this.getItemLocation(e)})}parseEmptyStatement(){let e=this.captureStartMarker();return this.expectPunctuator(";"),this.finalize({type:"EmptyStatement",...this.getItemLocation(e)})}parseExpressionStatement(){let e=this.captureStartMarker(),t=this.parseExpression();return this.consumeSemicolon(),this.finalize({type:"ExpressionStatement",expression:t,...this.getItemLocation(e)})}parseIfClause(){return this.withBlockContext(2,this.parseStatement)}parseIfStatement(){let e=this.captureStartMarker();this.expectKeyword("if"),this.expectPunctuator("(");let t=this.captureStartMarker(),n=this.parseExpression(),i=this.captureStartMarker();this.expectPunctuator(")"),(n.type==="AssignmentExpression"||n.type==="UpdateExpression")&&this.throwError("InvalidExpression",t,i);let r=this.parseIfClause(),s=null;return this.matchKeyword("else")&&(this.readNextRawToken(),s=this.parseIfClause()),this.finalize({type:"IfStatement",test:n,consequent:r,alternate:s,...this.getItemLocation(e)})}parseWhileStatement(){let e=this.captureStartMarker();this.expectKeyword("while"),this.expectPunctuator("(");let t=this.captureStartMarker(),n=this.parseExpression(),i=this.captureStartMarker();this.expectPunctuator(")"),(n.type==="AssignmentExpression"||n.type==="UpdateExpression")&&this.throwError("InvalidExpression",t,i);let r=this.withBlockContext(8,this.parseStatement);return this.finalize({type:"WhileStatement",test:n,body:r,...this.getItemLocation(e)})}parseForStatement(){let e=null,t=null,n=null,i=null,r=null,s=this.captureStartMarker();if(this.expectKeyword("for"),this.expectPunctuator("("),this.matchPunctuator(";"))this.readNextRawToken();else if(this.matchKeyword("var")){let a=this.captureStartMarker();this.readNextRawToken();let l=this.parseVariableDeclarationList();l.length===1&&this.matchKeyword("in")?(l[0].init&&this.throwError("ForInOfLoopInitializer",a),i=this.finalize({type:"VariableDeclaration",declarations:l,kind:"var",...this.getItemLocation(a)}),this.readNextRawToken(),r=this.parseExpression()):(this.matchKeyword("in")&&this.throwError("InvalidLeftHandSideInForIn",a),e=this.finalize({type:"VariableDeclaration",declarations:l,kind:"var",...this.getItemLocation(a)}),this.expectPunctuator(";"))}else{let a=this.context.isAssignmentTarget,l=this.captureStartMarker();e=this.inheritCoverGrammar(this.parseAssignmentExpression),this.matchKeyword("in")?(this.context.isAssignmentTarget||this.tolerateError("InvalidLeftHandSideInForIn",l),e.type!=="Identifier"&&this.throwError("InvalidLeftHandSideInForIn",l),this.readNextRawToken(),i=e,r=this.parseExpression(),e=null):(this.context.isAssignmentTarget=a,this.expectPunctuator(";"))}i||(this.matchPunctuator(";")||(t=this.isolateCoverGrammar(this.parseExpression)),this.expectPunctuator(";"),this.matchPunctuator(")")||(n=this.isolateCoverGrammar(this.parseExpression))),this.expectPunctuator(")");let o=this.withBlockContext(4,()=>this.isolateCoverGrammar(this.parseStatement));return i&&r?this.finalize({type:"ForInStatement",left:i,right:r,body:o,...this.getItemLocation(s)}):this.finalize({type:"ForStatement",init:e,test:t,update:n,body:o,...this.getItemLocation(s)})}parseContinueStatement(){let e=this.captureStartMarker();return this.expectKeyword("continue"),this.consumeSemicolon(),this.finalize({type:"ContinueStatement",...this.getItemLocation(e)})}parseBreakStatement(){let e=this.captureStartMarker();return this.expectKeyword("break"),this.consumeSemicolon(),this.finalize({type:"BreakStatement",...this.getItemLocation(e)})}parseReturnStatement(){let e=this.captureStartMarker();this.expectKeyword("return");let t=!this.matchPunctuator(";")&&!this.matchPunctuator("}")&&!this.hasLineTerminator&&this.rawToken.type!==2||this.rawToken.type===8||this.rawToken.type===10?this.parseExpression():null;return this.consumeSemicolon(),this.finalize({type:"ReturnStatement",argument:t,...this.getItemLocation(e)})}parseStatement(){switch(this.rawToken.type){case 1:case 5:case 6:case 8:case 10:case 3:return this.parseExpressionStatement();case 7:return this.rawToken.value==="{"?this.parseBlockOrObjectStatement():this.rawToken.value==="("?this.parseExpressionStatement():this.rawToken.value===";"?this.parseEmptyStatement():this.parseExpressionStatement();case 4:switch(this.rawToken.value.toLowerCase()){case"break":return this.parseBreakStatement();case"continue":return this.parseContinueStatement();case"for":return this.parseForStatement();case"function":return this.parseFunctionDeclaration();case"if":return this.parseIfStatement();case"return":return this.parseReturnStatement();case"var":return this.parseVariableDeclaration();case"while":return this.parseWhileStatement();default:return this.parseExpressionStatement()}default:return this.throwUnexpectedToken({rawToken:this.rawToken})}}parseFormalParameters(){let e=[];if(this.expectPunctuator("("),!this.matchPunctuator(")"))for(;this.rawToken.type!==2;){let t=this.parseIdentifier();if(t||this.throwUnexpectedToken({rawToken:this.rawToken,code:"IdentiferExpected"}),e.push(t),this.matchPunctuator(")")||(this.expectPunctuator(","),this.matchPunctuator(")")))break}return this.expectPunctuator(")"),e}parseFunctionDeclaration(){(this.context.blockContext&1)===1&&this.throwUnexpectedToken({code:"NoFunctionInsideFunction"}),((this.context.blockContext&8)===8||(this.context.blockContext&2)===2)&&this.throwUnexpectedToken({code:"NoFunctionInsideBlock"});let e=this.captureStartMarker();this.expectKeyword("function");let t=this.parseIdentifier();t||this.throwUnexpectedToken({code:"InvalidFunctionIdentifier"});let n=this.parseFormalParameters(),i=this.context.blockContext;this.context.blockContext|=1;let r=this.parseBlock();return this.context.blockContext=i,this.finalize({type:"FunctionDeclaration",id:t,params:n,body:r,...this.getItemLocation(e)})}parseScript(){let e=this.captureStartMarker(),t=this.parseStatements(),n=this.finalize({type:"Program",body:t,...this.getItemLocation(e)});return this.options.tokens&&(n.tokens=this.tokens),this.options.tolerant&&(n.errors=this.errorHandler.errors),n}parseExportDeclaration(){this.context.blockContext!==0&&this.throwUnexpectedToken({code:"ModuleExportRootOnly"});let e=null,t=this.captureStartMarker();return this.expectKeyword("export"),this.matchKeyword("var")?e=this.parseVariableDeclaration():this.matchKeyword("function")?e=this.parseFunctionDeclaration():this.throwUnexpectedToken({code:"InvalidExpression"}),this.finalize({type:"ExportNamedDeclaration",declaration:e,specifiers:[],source:null,...this.getItemLocation(t)})}parseModuleSpecifier(){let e=this.captureStartMarker(),t=this.rawToken;if(t.type===8)return this.readNextRawToken(),this.finalize({type:"Literal",value:t.value,raw:this.getSourceValue(t),isString:!0,...this.getItemLocation(e)});this.throwError("InvalidModuleUri",e)}parseDefaultSpecifier(){let e=this.captureStartMarker(),t=this.parseIdentifier();return t||this.throwUnexpectedToken({code:"IdentiferExpected"}),this.finalize({type:"ImportDefaultSpecifier",local:t,...this.getItemLocation(e)})}parseImportDeclaration(){this.context.blockContext!==0&&this.throwUnexpectedToken({code:"ModuleImportRootOnly"});let e=this.captureStartMarker();this.expectKeyword("import");let t=this.parseDefaultSpecifier();this.expectContextualKeyword("from");let n=this.parseModuleSpecifier();return this.finalize({type:"ImportDeclaration",specifiers:[t],source:n,...this.getItemLocation(e)})}},pl=class{constructor(e,t){this.errorHandler=new A1,this.errorHandler.tolerant=t?typeof t.tolerant=="boolean"&&t.tolerant:!1,this.scanner=new E1(e,this.errorHandler),this.trackComments=t?typeof t.comment=="boolean"&&t.comment:!1,this.buffer=[]}errors(){return this.errorHandler.errors}getNextToken(){if(this.buffer.length===0){let e=this.scanner.scanComments();if(this.trackComments&&e.forEach(t=>{let n=this.scanner.source.slice(t.start,t.end),i={type:t.multiLine?"BlockComment":"LineComment",value:n,range:t.range,loc:t.loc};this.buffer.push(i)}),!this.scanner.eof()){let t={line:this.scanner.lineNumber,column:this.scanner.index-this.scanner.lineStart},n=this.scanner.lex(),i={line:this.scanner.lineNumber,column:this.scanner.index-this.scanner.lineStart},r={type:b1[n.type],value:this.scanner.source.slice(n.start,n.end),range:[n.start,n.end],loc:{start:t,end:i}};this.buffer.push(r)}}return this.buffer.shift()}};function w1(e,t,n){return new gl(e,t,n).parseScript()}function xl(e,t,n){let i=new pl(e,t),r=[],s;try{let o;for(;o=i.getNextToken();)n&&(o=n(o)),r.push(o)}catch(o){i.errorHandler.tolerate(o)}return i.errorHandler.tolerant&&(s=i.errors()),{tokens:r,errors:s}}var Dl=(e=>(e.AlreadyDefined="AlreadyDefined",e.ApiConflict="ApiConflict",e.AssignedNeverUsed="AssignedNeverUsed",e.DefinedNeverAssigned="DefinedNeverAssigned",e.DefinedNeverUsed="DefinedNeverUsed",e.EmptyBlockStatement="EmptyBlockStatement",e.ExecutionError="ExecutionError",e.InvalidApiFunctionUsage="InvalidApiFunctionUsage",e.InvalidConstantIdentifier="InvalidConstantIdentifier",e.InvalidPropertyIdentifier="InvalidPropertyIdentifier",e.NoArgumentExpected="NoArgumentExpected",e.NotADictionary="NotADictionary",e.NotDefined="NotDefined",e.NotEnoughArguments="NotEnoughArguments",e.ProfileVariablesAreImmutable="ProfileVariablesAreImmutable",e.ProfileVariablesConflict="ProfileVariablesConflict",e.ReservedKeyword="ReservedKeyword",e.TooManyArguments="TooManyArguments",e.UnexpectedEmptyFunction="UnexpectedEmptyFunction",e.UnexpectedPropertyIdentifier="UnexpectedPropertyIdentifier",e.UnknownPropertyIdentifier="UnknownPropertyIdentifier",e))(Dl||{}),bl={AlreadyDefined:"'${identifier}' is already defined.",ApiConflict:"'${identifier}' is already defined as an Arcade constant or function.",AssignedNeverUsed:"'${identifier}' is assigned but never used.",DefinedNeverAssigned:"'${identifier}' is defined but never assigned.",DefinedNeverUsed:"'${identifier}' is defined but never used.",EmptyBlockStatement:"Empty block statement.",ExecutionError:"Execution Error: '${stack}'",InvalidApiFunctionUsage:"Arcade function '${identifier}' not used in a call expression.",InvalidConstantIdentifier:"Invalid constant identifier, expecting ${list}.",InvalidPropertyIdentifier:"Invalid property identifier, expecting ${list}.",NoArgumentExpected:"Expecting no argument.",NotADictionary:"'${identifier}' doesn't have properties.",NotDefined:"'${identifier}' is not defined.",NotEnoughArguments:"Expecting at least ${min} argument(s).",ProfileVariablesAreImmutable:"Profile variables cannot be modified.",ProfileVariablesConflict:"'${identifier}' is already defined as a profile variable.",ReservedKeyword:"'${identifier}' is a reserved keyword.",TooManyArguments:"Too many arguments, expecting ${max}.",UnexpectedEmptyFunction:"Unexpected empty function '${identifier}'.",UnexpectedPropertyIdentifier:"Unexpected property identifier.",UnknownPropertyIdentifier:"Unknown property identifier '${identifier}'.",...Tr},Cl=Object.values(g1),_l=Object.values(m1),vl=["case","catch","debugger","switch","try"],a1=new Map;function Al(e){return Array.isArray(e?.testSdkCategories)}function El(e,t){return`${e}/api/arcade-api.t9n.${t}.json`}var wl=class{constructor(e={}){this._settings=e}async getApiDatabase(e){let{locale:t="en"}=e,n=a1.get(t);if(!n){let{assetsPath:i}=this._settings;if(!i)return{categories:[],functionDefinitions:new Map,constantDefinitions:new Map};n=this.loadSdkApiLibrary(t,i),a1.set(t,n)}return this.filterApi(n,e)}async getApiLibrary(e){let{categories:t}=await this.getApiDatabase(e);return t}async filterApi(e,t){try{let n=await e,i=new Map,r=new Map,s=[],o=Ll(t);return n.forEach(a=>{let l=[];a.items.forEach(c=>Fl(l,r,i,o,c)),l.length&&s.push({...a,items:l})}),{categories:s,functionDefinitions:i,constantDefinitions:r}}catch{return{categories:[],functionDefinitions:new Map,constantDefinitions:new Map}}}async loadSdkApiLibrary(e="en",t=""){if(Al(this._settings))return this._settings.testSdkCategories;if(t=t.replace(/\/$/u,""),!t)return[];try{let n=await fetch(El(t,e));return n.ok?n.json():e==="en"?[]:this.loadSdkApiLibrary("en",t)}catch{return[]}}};function Ll(e){let{profile:{apiVersion:t,bundles:n,hiddenApiItems:i=[]}={}}=e,r=L1(t),s=Array.isArray(n)&&n.length>0?new Set(["core",...n]):void 0;return o=>yl(r,o.sinceVersion)&&(!s||s.has(o.bundle))&&!i.includes(o.name)}function Fl(e,t,n,i,r){if(Array.isArray(r)){r.forEach(s=>u1(e,n,i,s));return}if(r.type==="constant")return Sl(e,t,i,r);u1(e,n,i,r)}function u1(e,t,n,i){if(!n(i))return;i.disableDocumentation||e.push(i);let{completion:{label:r}}=i,s=r.toLowerCase(),o=t.get(s);o||(o={type:"functionDefinition",key:s,overloads:[]},t.set(s,o)),o.overloads.push(i)}function Sl(e,t,n,i){if(!n(i))return;e.push(i);let{completion:{label:r}}=i,s=r.toLowerCase();t.set(s,i);let[o,a]=i.completion.label.split(".");if(!a)return;let l=o.toLowerCase(),c=t.get(l);c||(c={type:"namespace",key:l,members:[],completion:{label:o,detail:o,insertText:o,insertTextMode:oe.adjustIndentation,insertTextFormat:se.PlainText,kind:Q.Enum}},t.set(l,c));let h=JSON.parse(JSON.stringify(i));h.key=a.toLowerCase(),h.name=a,h.completion.label=a,h.completion.insertText=a,h.completion.kind=Q.Constant,c.members.push(h),c.completion.documentation=c.members.reduce((f,d)=>(f.value=`${f.value}${f.value?`
19
+ `;continue}e+=o}return t||this.throwUnexpectedToken(),i||this.curlyStack.pop(),{type:10,value:this.source.slice(n+1,this.index-s),cooked:e,head:i,tail:r,lineNumber:this.lineNumber,lineStart:this.lineStart,start:n,end:this.index}}lex(){if(this.eof())return{type:2,value:"",lineNumber:this.lineNumber,lineStart:this.lineStart,start:this.index,end:this.index};let e=this.source.charCodeAt(this.index);return P.isIdentifierStart(e)?this.scanIdentifier():e===40||e===41||e===59?this.scanPunctuator():e===39||e===34?this.scanStringLiteral():e===46?P.isDecimalDigit(this.source.charCodeAt(this.index+1))?this.scanNumericLiteral():this.scanPunctuator():P.isDecimalDigit(e)?this.scanNumericLiteral():e===96||e===125&&this.curlyStack[this.curlyStack.length-1]==="${"?this.scanTemplate():e>=55296&&e<57343&&P.isIdentifierStart(this.codePointAt(this.index))?this.scanIdentifier():this.scanPunctuator()}};function r1(e,t=0){let n=e.start-e.lineStart,i=e.lineNumber;return n<0&&(n+=t,i-=1),{index:e.start,line:i,column:n}}function s1(e){return[{index:e.range[0],...e.loc.start},{index:e.range[1],...e.loc.end}]}function o1(e){return yr[e]??0}var gl=class{constructor(e,t={},n){this.delegate=n,this.hasLineTerminator=!1,this.options={tokens:typeof t.tokens=="boolean"&&t.tokens,comments:typeof t.comments=="boolean"&&t.comments,tolerant:typeof t.tolerant=="boolean"&&t.tolerant},this.options.comments&&(this.commentHandler=new ml),this.errorHandler=new A1(this.options.tolerant),this.scanner=new E1(e,this.errorHandler),this.context={isAssignmentTarget:!1,blockContext:0,curlyParsingType:0},this.rawToken={type:2,value:"",lineNumber:this.scanner.lineNumber,lineStart:0,start:0,end:0},this.tokens=[],this.startMarker={index:0,line:this.scanner.lineNumber,column:0},this.endMarker={index:0,line:this.scanner.lineNumber,column:0},this.readNextRawToken(),this.endMarker={index:this.scanner.index,line:this.scanner.lineNumber,column:this.scanner.index-this.scanner.lineStart}}throwIfInvalidType(e,t,{validTypes:n,invalidTypes:i}){n?.some(r=>e.type===r)||i?.some(r=>e.type===r)&&this.throwError("InvalidExpression",t)}throwError(e,t,n=this.endMarker){let{index:i,line:r,column:s}=t,o=n.index-i-1;this.errorHandler.throwError({code:e,index:i,line:r,column:s+1,len:o})}tolerateError(e,t){throw new Error("######################################### !!!")}unexpectedTokenError(e={}){let{rawToken:t}=e,{code:n,data:i}=e,r;if(t){if(!n)switch(t.type){case 2:n="UnexpectedEndOfScript";break;case 3:n="UnexpectedIdentifier";break;case 6:n="UnexpectedNumber";break;case 8:n="UnexpectedString";break;case 10:n="UnexpectedTemplate";break}r=t.value.toString()}else r="ILLEGAL";n??(n="UnexpectedToken"),i||(i={value:r});let s=Ir(n,i);if(t){let l=t.start,c=t.lineNumber,h=t.start-t.lineStart+1;return new ri({code:n,index:l,line:c,column:h,len:t.end-t.start-1,data:i,description:s})}let{index:o,line:a}=this.endMarker;return new ri({code:n,index:o,line:a,column:this.endMarker.column+1,data:i,description:s})}throwUnexpectedToken(e={}){throw e.rawToken??(e.rawToken=this.rawToken),this.unexpectedTokenError(e)}collectComments(e){let{commentHandler:t}=this;!t||!e.length||e.forEach(n=>{let i={type:n.multiLine?"BlockComment":"LineComment",value:this.getSourceValue(n),range:n.range,loc:n.loc};t.collectComment(i)})}peekAhead(e){let t=()=>(this.scanner.scanComments(),this.scanner.lex()),n=this.scanner.saveState(),i=e.call(this,t);return this.scanner.restoreState(n),i}getSourceValue(e){return this.scanner.source.slice(e.start,e.end)}convertToToken(e){return{type:b1[e.type],value:this.getSourceValue(e),range:[e.start,e.end],loc:{start:{line:this.startMarker.line,column:this.startMarker.column},end:{line:this.scanner.lineNumber,column:this.scanner.index-this.scanner.lineStart}}}}readNextRawToken(){this.endMarker.index=this.scanner.index,this.endMarker.line=this.scanner.lineNumber,this.endMarker.column=this.scanner.index-this.scanner.lineStart;let e=this.rawToken;this.collectComments(this.scanner.scanComments()),this.scanner.index!==this.startMarker.index&&(this.startMarker.index=this.scanner.index,this.startMarker.line=this.scanner.lineNumber,this.startMarker.column=this.scanner.index-this.scanner.lineStart),this.rawToken=this.scanner.lex(),this.hasLineTerminator=e.lineNumber!==this.rawToken.lineNumber,this.options.tokens&&this.rawToken.type!==2&&this.tokens.push(this.convertToToken(this.rawToken))}captureStartMarker(){return{index:this.startMarker.index,line:this.startMarker.line,column:this.startMarker.column}}getItemLocation(e){return{range:[e.index,this.endMarker.index],loc:{start:{line:e.line,column:e.column},end:{line:this.endMarker.line,column:this.endMarker.column}}}}finalize(e){return(this.delegate||this.commentHandler)&&(this.commentHandler?.attachComments(e),this.delegate?.(e)),e}expectPunctuator(e){let t=this.rawToken;if(this.matchPunctuator(e)){this.readNextRawToken();return}this.throwUnexpectedToken({rawToken:t,code:"PunctuatorExpected",data:{value:e}})}expectKeyword(e){if(this.rawToken.type===4&&this.rawToken.value.toLowerCase()===e){this.readNextRawToken();return}this.throwUnexpectedToken({rawToken:this.rawToken})}expectContextualKeyword(e){if(this.rawToken.type===3&&this.rawToken.value.toLowerCase()===e){this.readNextRawToken();return}this.throwUnexpectedToken({rawToken:this.rawToken})}matchKeyword(e){return this.rawToken.type===4&&this.rawToken.value.toLowerCase()===e}matchContextualKeyword(e){return this.rawToken.type===3&&this.rawToken.value===e}matchPunctuator(e){return this.rawToken.type===7&&this.rawToken.value===e}getMatchingPunctuator(e){if(typeof e=="string"&&(e=e.split("")),!(this.rawToken.type!==7||!e?.length))return e.find(this.matchPunctuator,this)}isolateCoverGrammar(e){let t=this.context.isAssignmentTarget;this.context.isAssignmentTarget=!0;let n=e.call(this);return this.context.isAssignmentTarget=t,n}inheritCoverGrammar(e){var t;let n=this.context.isAssignmentTarget;this.context.isAssignmentTarget=!0;let i=e.call(this);return(t=this.context).isAssignmentTarget&&(t.isAssignmentTarget=n),i}withBlockContext(e,t){let n=this.context.blockContext;this.context.blockContext|=e;let i=this.context.curlyParsingType;this.context.curlyParsingType=1;let r=t.call(this);return this.context.blockContext=n,this.context.curlyParsingType=i,r}consumeSemicolon(){if(this.matchPunctuator(";")){this.readNextRawToken();return}if(!this.hasLineTerminator){if(this.rawToken.type===2||this.matchPunctuator("}")){this.endMarker.index=this.startMarker.index,this.endMarker.line=this.startMarker.line,this.endMarker.column=this.startMarker.column;return}this.throwUnexpectedToken({rawToken:this.rawToken})}}parsePrimaryExpression(){let e=this.captureStartMarker(),t=this.rawToken;switch(t.type){case 3:return this.readNextRawToken(),this.finalize({type:"Identifier",name:t.value,...this.getItemLocation(e)});case 6:case 8:return this.context.isAssignmentTarget=!1,this.readNextRawToken(),this.finalize({type:"Literal",value:t.value,raw:this.getSourceValue(t),isString:typeof t.value=="string",...this.getItemLocation(e)});case 1:return this.context.isAssignmentTarget=!1,this.readNextRawToken(),this.finalize({type:"Literal",value:t.value.toLowerCase()==="true",raw:this.getSourceValue(t),isString:!1,...this.getItemLocation(e)});case 5:return this.context.isAssignmentTarget=!1,this.readNextRawToken(),this.finalize({type:"Literal",value:null,raw:this.getSourceValue(t),isString:!1,...this.getItemLocation(e)});case 10:return this.parseTemplateLiteral();case 7:switch(t.value){case"(":return this.inheritCoverGrammar(this.parseGroupExpression);case"[":return this.inheritCoverGrammar(this.parseArrayInitializer);case"{":return this.inheritCoverGrammar(this.parseObjectExpression);default:return this.throwUnexpectedToken({rawToken:this.rawToken})}case 4:return this.context.isAssignmentTarget=!1,this.throwUnexpectedToken({rawToken:this.rawToken});default:return this.throwUnexpectedToken({rawToken:this.rawToken})}}parseArrayInitializer(){let e=this.captureStartMarker();this.expectPunctuator("[");let t=[];for(;!this.matchPunctuator("]");){let n=this.captureStartMarker();this.matchPunctuator(",")?(this.readNextRawToken(),this.throwError("InvalidExpression",n)):(t.push(this.inheritCoverGrammar(this.parseAssignmentExpression)),this.matchPunctuator("]")||this.expectPunctuator(","))}return this.expectPunctuator("]"),this.finalize({type:"ArrayExpression",elements:t,...this.getItemLocation(e)})}parseObjectPropertyKey(){let e=this.captureStartMarker(),t=this.rawToken;switch(t.type){case 8:return this.readNextRawToken(),this.finalize({type:"Literal",value:t.value,raw:this.getSourceValue(t),isString:!0,...this.getItemLocation(e)});case 3:case 1:case 5:case 4:return this.readNextRawToken(),this.finalize({type:"Identifier",name:t.value,...this.getItemLocation(e)});default:this.throwError("KeyMustBeString",e)}}parseObjectProperty(){let e=this.rawToken,t=this.captureStartMarker(),n=this.parseObjectPropertyKey(),i=!1,r=null;return this.matchPunctuator(":")?(this.readNextRawToken(),r=this.inheritCoverGrammar(this.parseAssignmentExpression)):e.type===3?(i=!0,r=this.finalize({type:"Identifier",name:e.value,...this.getItemLocation(t)})):this.throwUnexpectedToken({rawToken:this.rawToken}),this.finalize({type:"Property",kind:"init",key:n,value:r,shorthand:i,...this.getItemLocation(t)})}parseObjectExpression(){let e=this.captureStartMarker();this.expectPunctuator("{");let t=[];for(;!this.matchPunctuator("}");)t.push(this.parseObjectProperty()),this.matchPunctuator("}")||this.expectPunctuator(",");return this.expectPunctuator("}"),this.finalize({type:"ObjectExpression",properties:t,...this.getItemLocation(e)})}parseTemplateElement(e=!1){let t=this.rawToken;t.type!==10&&this.throwUnexpectedToken({rawToken:t}),e&&!t.head&&this.throwUnexpectedToken({code:"InvalidTemplateHead",rawToken:t});let n=this.captureStartMarker();this.readNextRawToken();let{value:i,cooked:r,tail:s}=t,o=this.finalize({type:"TemplateElement",value:{raw:i,cooked:r},tail:s,...this.getItemLocation(n)});return o.loc.start.column+=1,o.loc.end.column-=s?1:2,o}parseTemplateLiteral(){let e=this.captureStartMarker(),t=[],n=[],i=this.parseTemplateElement(!0);for(n.push(i);!i.tail;)t.push(this.parseExpression()),i=this.parseTemplateElement(),n.push(i);return this.finalize({type:"TemplateLiteral",quasis:n,expressions:t,...this.getItemLocation(e)})}parseGroupExpression(){this.expectPunctuator("(");let e=this.inheritCoverGrammar(this.parseAssignmentExpression);return this.expectPunctuator(")"),e}parseArguments(){this.expectPunctuator("(");let e=[];if(!this.matchPunctuator(")"))for(;;){let t=this.isolateCoverGrammar(this.parseAssignmentExpression);if(e.push(t),this.matchPunctuator(")")||(this.expectPunctuator(","),this.matchPunctuator(")")))break}return this.expectPunctuator(")"),e}parseMemberName(){let e=this.rawToken,t=this.captureStartMarker();return this.readNextRawToken(),e.type!==5&&e.type!==3&&e.type!==4&&e.type!==1&&this.throwUnexpectedToken({rawToken:e}),this.finalize({type:"Identifier",name:e.value,...this.getItemLocation(t)})}parseLeftHandSideExpression(){let e=this.captureStartMarker(),t=this.inheritCoverGrammar(this.parsePrimaryExpression),n=this.captureStartMarker(),i;for(;i=this.getMatchingPunctuator("([.");)switch(i){case"(":{this.context.isAssignmentTarget=!1,t.type!=="Identifier"&&t.type!=="MemberExpression"&&this.throwError("IdentiferExpected",e,n);let r=this.parseArguments();t=this.finalize({type:"CallExpression",callee:t,arguments:r,...this.getItemLocation(e)});continue}case"[":{this.context.isAssignmentTarget=!0,this.expectPunctuator("[");let r=this.isolateCoverGrammar(this.parseExpression);this.expectPunctuator("]"),t=this.finalize({type:"MemberExpression",computed:!0,object:t,property:r,...this.getItemLocation(e)});continue}case".":{this.context.isAssignmentTarget=!0,this.expectPunctuator(".");let r=this.parseMemberName();t=this.finalize({type:"MemberExpression",computed:!1,object:t,property:r,...this.getItemLocation(e)});continue}default:break}return t}parseUpdateExpression(){let e=this.captureStartMarker(),t=this.getMatchingPunctuator(Sr);if(t){this.readNextRawToken();let s=this.captureStartMarker(),o=this.inheritCoverGrammar(this.parseUnaryExpression);return o.type!=="Identifier"&&o.type!=="MemberExpression"&&o.type!=="CallExpression"&&this.throwError("InvalidExpression",s),this.context.isAssignmentTarget||this.tolerateError("InvalidLeftHandSideInAssignment",e),this.context.isAssignmentTarget=!1,this.finalize({type:"UpdateExpression",operator:t,argument:o,prefix:!0,...this.getItemLocation(e)})}let n=this.captureStartMarker(),i=this.inheritCoverGrammar(this.parseLeftHandSideExpression),r=this.captureStartMarker();return this.hasLineTerminator||(t=this.getMatchingPunctuator(Sr),!t)?i:(i.type!=="Identifier"&&i.type!=="MemberExpression"&&this.throwError("InvalidExpression",n,r),this.context.isAssignmentTarget||this.tolerateError("InvalidLeftHandSideInAssignment",e),this.readNextRawToken(),this.context.isAssignmentTarget=!1,this.finalize({type:"UpdateExpression",operator:t,argument:i,prefix:!1,...this.getItemLocation(e)}))}parseUnaryExpression(){let e=this.getMatchingPunctuator(p1);if(e){let t=this.captureStartMarker();this.readNextRawToken();let n=this.inheritCoverGrammar(this.parseUnaryExpression);return this.context.isAssignmentTarget=!1,this.finalize({type:"UnaryExpression",operator:e,argument:n,prefix:!0,...this.getItemLocation(t)})}return this.parseUpdateExpression()}parseBinaryExpression(){let e=this.rawToken,t=this.inheritCoverGrammar(this.parseUnaryExpression);if(this.rawToken.type!==7)return t;let n=this.rawToken.value,i=o1(n);if(i===0)return t;this.readNextRawToken(),this.context.isAssignmentTarget=!1;let r=[e,this.rawToken],s=t,o=this.inheritCoverGrammar(this.parseUnaryExpression),a=[s,n,o],l=[i];for(;this.rawToken.type===7&&(i=o1(this.rawToken.value))>0;){for(;a.length>2&&i<=l[l.length-1];){o=a.pop();let f=a.pop();l.pop(),s=a.pop(),r.pop();let d=r[r.length-1],m=r1(d,d.lineStart);a.push(this.finalize(this.createBinaryOrLogicalExpression(m,f,s,o)))}a.push(this.rawToken.value),l.push(i),r.push(this.rawToken),this.readNextRawToken(),a.push(this.inheritCoverGrammar(this.parseUnaryExpression))}let c=a.length-1;t=a[c];let h=r.pop();for(;c>1;){let f=r.pop();if(!f)break;let d=h?.lineStart,m=r1(f,d),p=a[c-1];t=this.finalize(this.createBinaryOrLogicalExpression(m,p,a[c-2],t)),c-=2,h=f}return t}createBinaryOrLogicalExpression(e,t,n,i){let r=D1.includes(t)?"LogicalExpression":"BinaryExpression";return r==="BinaryExpression"?{type:r,operator:t,left:n,right:i,...this.getItemLocation(e)}:((n.type==="AssignmentExpression"||n.type==="UpdateExpression")&&this.throwError("InvalidExpression",...s1(n)),(i.type==="AssignmentExpression"||i.type==="UpdateExpression")&&this.throwError("InvalidExpression",...s1(n)),{type:r,operator:t,left:n,right:i,...this.getItemLocation(e)})}parseAssignmentExpression(){let e=this.captureStartMarker(),t=this.inheritCoverGrammar(this.parseBinaryExpression),n=this.captureStartMarker(),i=this.getMatchingPunctuator(x1);if(!i)return t;t.type!=="Identifier"&&t.type!=="MemberExpression"&&this.throwError("InvalidExpression",e,n),this.context.isAssignmentTarget||this.tolerateError("InvalidLeftHandSideInAssignment",e),this.matchPunctuator("=")||(this.context.isAssignmentTarget=!1),this.readNextRawToken();let r=this.isolateCoverGrammar(this.parseAssignmentExpression);return this.finalize({type:"AssignmentExpression",left:t,operator:i,right:r,...this.getItemLocation(e)})}parseExpression(){return this.isolateCoverGrammar(this.parseAssignmentExpression)}parseStatements(e){let t=[];for(;this.rawToken.type!==2&&!this.matchPunctuator(e);){let n=this.parseStatementListItem();Ur(n)||t.push(n)}return t}parseStatementListItem(){return this.context.isAssignmentTarget=!0,this.matchKeyword("function")?this.parseFunctionDeclaration():this.matchKeyword("export")?this.parseExportDeclaration():this.matchKeyword("import")?this.parseImportDeclaration():this.parseStatement()}parseBlock(){let e=this.captureStartMarker();this.expectPunctuator("{");let t=this.parseStatements("}");return this.expectPunctuator("}"),this.finalize({type:"BlockStatement",body:t,...this.getItemLocation(e)})}parseObjectStatement(){let e=this.captureStartMarker(),t=this.parseObjectExpression();return this.finalize({type:"ExpressionStatement",expression:t,...this.getItemLocation(e)})}parseBlockOrObjectStatement(){return this.context.curlyParsingType===0?this.parseObjectStatement():this.peekAhead(e=>{let t=e();return!(t.type!==3&&t.type!==8||(t=e(),t.type!==7||t.value!==":"))})?this.parseObjectStatement():this.parseBlock()}parseIdentifier(){let e=this.rawToken;if(e.type!==3)return null;let t=this.captureStartMarker();return this.readNextRawToken(),this.finalize({type:"Identifier",name:e.value,...this.getItemLocation(t)})}parseVariableDeclarator(){let e=this.captureStartMarker(),t=this.parseIdentifier();t||this.throwUnexpectedToken({code:"IdentiferExpected"});let n=null;if(this.matchPunctuator("=")){this.readNextRawToken();let i=this.rawToken;try{n=this.isolateCoverGrammar(this.parseAssignmentExpression)}catch{this.throwUnexpectedToken({rawToken:i,code:"InvalidVariableAssignment"})}}return this.finalize({type:"VariableDeclarator",id:t,init:n,...this.getItemLocation(e)})}parseVariableDeclarationList(){let e=[this.parseVariableDeclarator()];for(;this.matchPunctuator(",");)this.readNextRawToken(),e.push(this.parseVariableDeclarator());return e}parseVariableDeclaration(){let e=this.captureStartMarker();this.expectKeyword("var");let t=this.parseVariableDeclarationList();return this.consumeSemicolon(),this.finalize({type:"VariableDeclaration",declarations:t,kind:"var",...this.getItemLocation(e)})}parseEmptyStatement(){let e=this.captureStartMarker();return this.expectPunctuator(";"),this.finalize({type:"EmptyStatement",...this.getItemLocation(e)})}parseExpressionStatement(){let e=this.captureStartMarker(),t=this.parseExpression();return this.consumeSemicolon(),this.finalize({type:"ExpressionStatement",expression:t,...this.getItemLocation(e)})}parseIfClause(){return this.withBlockContext(2,this.parseStatement)}parseIfStatement(){let e=this.captureStartMarker();this.expectKeyword("if"),this.expectPunctuator("(");let t=this.captureStartMarker(),n=this.parseExpression(),i=this.captureStartMarker();this.expectPunctuator(")"),(n.type==="AssignmentExpression"||n.type==="UpdateExpression")&&this.throwError("InvalidExpression",t,i);let r=this.parseIfClause(),s=null;return this.matchKeyword("else")&&(this.readNextRawToken(),s=this.parseIfClause()),this.finalize({type:"IfStatement",test:n,consequent:r,alternate:s,...this.getItemLocation(e)})}parseWhileStatement(){let e=this.captureStartMarker();this.expectKeyword("while"),this.expectPunctuator("(");let t=this.captureStartMarker(),n=this.parseExpression(),i=this.captureStartMarker();this.expectPunctuator(")"),(n.type==="AssignmentExpression"||n.type==="UpdateExpression")&&this.throwError("InvalidExpression",t,i);let r=this.withBlockContext(8,this.parseStatement);return this.finalize({type:"WhileStatement",test:n,body:r,...this.getItemLocation(e)})}parseForStatement(){let e=null,t=null,n=null,i=null,r=null,s=this.captureStartMarker();if(this.expectKeyword("for"),this.expectPunctuator("("),this.matchPunctuator(";"))this.readNextRawToken();else if(this.matchKeyword("var")){let a=this.captureStartMarker();this.readNextRawToken();let l=this.parseVariableDeclarationList();l.length===1&&this.matchKeyword("in")?(l[0].init&&this.throwError("ForInOfLoopInitializer",a),i=this.finalize({type:"VariableDeclaration",declarations:l,kind:"var",...this.getItemLocation(a)}),this.readNextRawToken(),r=this.parseExpression()):(this.matchKeyword("in")&&this.throwError("InvalidLeftHandSideInForIn",a),e=this.finalize({type:"VariableDeclaration",declarations:l,kind:"var",...this.getItemLocation(a)}),this.expectPunctuator(";"))}else{let a=this.context.isAssignmentTarget,l=this.captureStartMarker();e=this.inheritCoverGrammar(this.parseAssignmentExpression),this.matchKeyword("in")?(this.context.isAssignmentTarget||this.tolerateError("InvalidLeftHandSideInForIn",l),e.type!=="Identifier"&&this.throwError("InvalidLeftHandSideInForIn",l),this.readNextRawToken(),i=e,r=this.parseExpression(),e=null):(this.context.isAssignmentTarget=a,this.expectPunctuator(";"))}i||(this.matchPunctuator(";")||(t=this.isolateCoverGrammar(this.parseExpression)),this.expectPunctuator(";"),this.matchPunctuator(")")||(n=this.isolateCoverGrammar(this.parseExpression))),this.expectPunctuator(")");let o=this.withBlockContext(4,()=>this.isolateCoverGrammar(this.parseStatement));return i&&r?this.finalize({type:"ForInStatement",left:i,right:r,body:o,...this.getItemLocation(s)}):this.finalize({type:"ForStatement",init:e,test:t,update:n,body:o,...this.getItemLocation(s)})}parseContinueStatement(){let e=this.captureStartMarker();return this.expectKeyword("continue"),this.consumeSemicolon(),this.finalize({type:"ContinueStatement",...this.getItemLocation(e)})}parseBreakStatement(){let e=this.captureStartMarker();return this.expectKeyword("break"),this.consumeSemicolon(),this.finalize({type:"BreakStatement",...this.getItemLocation(e)})}parseReturnStatement(){let e=this.captureStartMarker();this.expectKeyword("return");let t=!this.matchPunctuator(";")&&!this.matchPunctuator("}")&&!this.hasLineTerminator&&this.rawToken.type!==2||this.rawToken.type===8||this.rawToken.type===10?this.parseExpression():null;return this.consumeSemicolon(),this.finalize({type:"ReturnStatement",argument:t,...this.getItemLocation(e)})}parseStatement(){switch(this.rawToken.type){case 1:case 5:case 6:case 8:case 10:case 3:return this.parseExpressionStatement();case 7:return this.rawToken.value==="{"?this.parseBlockOrObjectStatement():this.rawToken.value==="("?this.parseExpressionStatement():this.rawToken.value===";"?this.parseEmptyStatement():this.parseExpressionStatement();case 4:switch(this.rawToken.value.toLowerCase()){case"break":return this.parseBreakStatement();case"continue":return this.parseContinueStatement();case"for":return this.parseForStatement();case"function":return this.parseFunctionDeclaration();case"if":return this.parseIfStatement();case"return":return this.parseReturnStatement();case"var":return this.parseVariableDeclaration();case"while":return this.parseWhileStatement();default:return this.parseExpressionStatement()}default:return this.throwUnexpectedToken({rawToken:this.rawToken})}}parseFormalParameters(){let e=[];if(this.expectPunctuator("("),!this.matchPunctuator(")"))for(;this.rawToken.type!==2;){let t=this.parseIdentifier();if(t||this.throwUnexpectedToken({rawToken:this.rawToken,code:"IdentiferExpected"}),e.push(t),this.matchPunctuator(")")||(this.expectPunctuator(","),this.matchPunctuator(")")))break}return this.expectPunctuator(")"),e}parseFunctionDeclaration(){(this.context.blockContext&1)===1&&this.throwUnexpectedToken({code:"NoFunctionInsideFunction"}),((this.context.blockContext&8)===8||(this.context.blockContext&2)===2)&&this.throwUnexpectedToken({code:"NoFunctionInsideBlock"});let e=this.captureStartMarker();this.expectKeyword("function");let t=this.parseIdentifier();t||this.throwUnexpectedToken({code:"InvalidFunctionIdentifier"});let n=this.parseFormalParameters(),i=this.context.blockContext;this.context.blockContext|=1;let r=this.parseBlock();return this.context.blockContext=i,this.finalize({type:"FunctionDeclaration",id:t,params:n,body:r,...this.getItemLocation(e)})}parseScript(){let e=this.captureStartMarker(),t=this.parseStatements(),n=this.finalize({type:"Program",body:t,...this.getItemLocation(e)});return this.options.tokens&&(n.tokens=this.tokens),this.options.tolerant&&(n.errors=this.errorHandler.errors),n}parseExportDeclaration(){this.context.blockContext!==0&&this.throwUnexpectedToken({code:"ModuleExportRootOnly"});let e=null,t=this.captureStartMarker();return this.expectKeyword("export"),this.matchKeyword("var")?e=this.parseVariableDeclaration():this.matchKeyword("function")?e=this.parseFunctionDeclaration():this.throwUnexpectedToken({code:"InvalidExpression"}),this.finalize({type:"ExportNamedDeclaration",declaration:e,specifiers:[],source:null,...this.getItemLocation(t)})}parseModuleSpecifier(){let e=this.captureStartMarker(),t=this.rawToken;if(t.type===8)return this.readNextRawToken(),this.finalize({type:"Literal",value:t.value,raw:this.getSourceValue(t),isString:!0,...this.getItemLocation(e)});this.throwError("InvalidModuleUri",e)}parseDefaultSpecifier(){let e=this.captureStartMarker(),t=this.parseIdentifier();return t||this.throwUnexpectedToken({code:"IdentiferExpected"}),this.finalize({type:"ImportDefaultSpecifier",local:t,...this.getItemLocation(e)})}parseImportDeclaration(){this.context.blockContext!==0&&this.throwUnexpectedToken({code:"ModuleImportRootOnly"});let e=this.captureStartMarker();this.expectKeyword("import");let t=this.parseDefaultSpecifier();this.expectContextualKeyword("from");let n=this.parseModuleSpecifier();return this.finalize({type:"ImportDeclaration",specifiers:[t],source:n,...this.getItemLocation(e)})}},pl=class{constructor(e,t){this.errorHandler=new A1,this.errorHandler.tolerant=t?typeof t.tolerant=="boolean"&&t.tolerant:!1,this.scanner=new E1(e,this.errorHandler),this.trackComments=t?typeof t.comment=="boolean"&&t.comment:!1,this.buffer=[]}errors(){return this.errorHandler.errors}getNextToken(){if(this.buffer.length===0){let e=this.scanner.scanComments();if(this.trackComments&&e.forEach(t=>{let n=this.scanner.source.slice(t.start,t.end),i={type:t.multiLine?"BlockComment":"LineComment",value:n,range:t.range,loc:t.loc};this.buffer.push(i)}),!this.scanner.eof()){let t={line:this.scanner.lineNumber,column:this.scanner.index-this.scanner.lineStart},n=this.scanner.lex(),i={line:this.scanner.lineNumber,column:this.scanner.index-this.scanner.lineStart},r={type:b1[n.type],value:this.scanner.source.slice(n.start,n.end),range:[n.start,n.end],loc:{start:t,end:i}};this.buffer.push(r)}}return this.buffer.shift()}};function w1(e,t,n){return new gl(e,t,n).parseScript()}function xl(e,t,n){let i=new pl(e,t),r=[],s;try{let o;for(;o=i.getNextToken();)n&&(o=n(o)),r.push(o)}catch(o){o instanceof Error&&i.errorHandler.tolerate(o)}return i.errorHandler.tolerant&&(s=i.errors()),{tokens:r,errors:s}}var Dl=(e=>(e.AlreadyDefined="AlreadyDefined",e.ApiConflict="ApiConflict",e.AssignedNeverUsed="AssignedNeverUsed",e.DefinedNeverAssigned="DefinedNeverAssigned",e.DefinedNeverUsed="DefinedNeverUsed",e.EmptyBlockStatement="EmptyBlockStatement",e.ExecutionError="ExecutionError",e.InvalidApiFunctionUsage="InvalidApiFunctionUsage",e.InvalidConstantIdentifier="InvalidConstantIdentifier",e.InvalidPropertyIdentifier="InvalidPropertyIdentifier",e.NoArgumentExpected="NoArgumentExpected",e.NotADictionary="NotADictionary",e.NotDefined="NotDefined",e.NotEnoughArguments="NotEnoughArguments",e.ProfileVariablesAreImmutable="ProfileVariablesAreImmutable",e.ProfileVariablesConflict="ProfileVariablesConflict",e.ReservedKeyword="ReservedKeyword",e.TooManyArguments="TooManyArguments",e.UnexpectedEmptyFunction="UnexpectedEmptyFunction",e.UnexpectedPropertyIdentifier="UnexpectedPropertyIdentifier",e.UnknownPropertyIdentifier="UnknownPropertyIdentifier",e))(Dl||{}),bl={AlreadyDefined:"'${identifier}' is already defined.",ApiConflict:"'${identifier}' is already defined as an Arcade constant or function.",AssignedNeverUsed:"'${identifier}' is assigned but never used.",DefinedNeverAssigned:"'${identifier}' is defined but never assigned.",DefinedNeverUsed:"'${identifier}' is defined but never used.",EmptyBlockStatement:"Empty block statement.",ExecutionError:"Execution Error: '${stack}'",InvalidApiFunctionUsage:"Arcade function '${identifier}' not used in a call expression.",InvalidConstantIdentifier:"Invalid constant identifier, expecting ${list}.",InvalidPropertyIdentifier:"Invalid property identifier, expecting ${list}.",NoArgumentExpected:"Expecting no argument.",NotADictionary:"'${identifier}' doesn't have properties.",NotDefined:"'${identifier}' is not defined.",NotEnoughArguments:"Expecting at least ${min} argument(s).",ProfileVariablesAreImmutable:"Profile variables cannot be modified.",ProfileVariablesConflict:"'${identifier}' is already defined as a profile variable.",ReservedKeyword:"'${identifier}' is a reserved keyword.",TooManyArguments:"Too many arguments, expecting ${max}.",UnexpectedEmptyFunction:"Unexpected empty function '${identifier}'.",UnexpectedPropertyIdentifier:"Unexpected property identifier.",UnknownPropertyIdentifier:"Unknown property identifier '${identifier}'.",...Tr},Cl=Object.values(g1),_l=Object.values(m1),vl=["case","catch","debugger","switch","try"],a1=new Map;function Al(e){return Array.isArray(e?.testSdkCategories)}function El(e,t){return`${e}/api/arcade-api.t9n.${t}.json`}var wl=class{constructor(e={}){this._settings=e}async getApiDatabase(e){let{locale:t="en"}=e,n=a1.get(t);if(!n){let{assetsPath:i}=this._settings;if(!i)return{categories:[],functionDefinitions:new Map,constantDefinitions:new Map};n=this.loadSdkApiLibrary(t,i),a1.set(t,n)}return this.filterApi(n,e)}async getApiLibrary(e){let{categories:t}=await this.getApiDatabase(e);return t}async filterApi(e,t){try{let n=await e,i=new Map,r=new Map,s=[],o=Ll(t);return n.forEach(a=>{let l=[];a.items.forEach(c=>Fl(l,r,i,o,c)),l.length&&s.push({...a,items:l})}),{categories:s,functionDefinitions:i,constantDefinitions:r}}catch{return{categories:[],functionDefinitions:new Map,constantDefinitions:new Map}}}async loadSdkApiLibrary(e="en",t=""){if(Al(this._settings))return this._settings.testSdkCategories;if(t=t.replace(/\/$/u,""),!t)return[];try{let n=await fetch(El(t,e));return n.ok?n.json():e==="en"?[]:this.loadSdkApiLibrary("en",t)}catch{return[]}}};function Ll(e){let{profile:{apiVersion:t,bundles:n,hiddenApiItems:i=[]}={}}=e,r=L1(t),s=Array.isArray(n)&&n.length>0?new Set(["core",...n]):void 0;return o=>yl(r,o.sinceVersion)&&(!s||s.has(o.bundle))&&!i.includes(o.name)}function Fl(e,t,n,i,r){if(Array.isArray(r)){r.forEach(s=>u1(e,n,i,s));return}if(r.type==="constant")return Sl(e,t,i,r);u1(e,n,i,r)}function u1(e,t,n,i){if(!n(i))return;i.disableDocumentation||e.push(i);let{completion:{label:r}}=i,s=r.toLowerCase(),o=t.get(s);o||(o={type:"functionDefinition",key:s,overloads:[]},t.set(s,o)),o.overloads.push(i)}function Sl(e,t,n,i){if(!n(i))return;e.push(i);let{completion:{label:r}}=i,s=r.toLowerCase();t.set(s,i);let[o,a]=i.completion.label.split(".");if(!a)return;let l=o.toLowerCase(),c=t.get(l);c||(c={type:"namespace",key:l,members:[],completion:{label:o,detail:o,insertText:o,insertTextMode:oe.adjustIndentation,insertTextFormat:se.PlainText,kind:Q.Enum}},t.set(l,c));let h=JSON.parse(JSON.stringify(i));h.key=a.toLowerCase(),h.name=a,h.completion.label=a,h.completion.insertText=a,h.completion.kind=Q.Constant,c.members.push(h),c.completion.documentation=c.members.reduce((f,d)=>(f.value=`${f.value}${f.value?`
20
20
 
21
21
  `:""}**${d.completion.label}**: ${d.description}`,f),{kind:en.Markdown,value:""})}function L1(e){if(!e||typeof e!="string")return null;let t=e.split(".").map(r=>Number.parseInt(r));if(t.some(Number.isNaN))return console.error("Arcade: invalid API version string",e),null;let[n,i]=t.slice(0,2);return{major:n,minor:i}}function yl(e,t){if(!e)return!0;let n=L1(t);return n?e.major>n.major?!1:e.minor===void 0||n.minor===void 0?!0:n.minor<=e.minor:!0}var Nl=_l.map(e=>({label:e,kind:Q.Constant})),kl=Cl.map(e=>({label:e,kind:Q.Keyword})),Bl=[{label:"exportfunction",kind:Q.Snippet,detail:"Export Function Statement",insertText:`export function \${1:functionName} ($2) {
22
22
  $0
@@ -1 +1 @@
1
- export{a as arcade}from"./p-0d616249.js";import"./p-2c0d6f15.js";
1
+ export{a as arcade}from"./p-f5598cde.js";import"./p-2c0d6f15.js";
@@ -1 +1 @@
1
- import{n as e,e as t,M as n,R as r,l as i,E as s}from"./p-0d616249.js";import"./p-2c0d6f15.js";var o,a=((o=a||{}).False="false",o.Null="null",o.True="true",o),c=(e=>(e.Break="break",e.Continue="continue",e.Else="else",e.For="for",e.From="from",e.Function="function",e.If="if",e.Import="import",e.Export="export",e.In="in",e.Return="return",e.Var="var",e.While="while",e))(c||{}),u=(e=>(e.AssignmentExpression="AssignmentExpression",e.ArrayExpression="ArrayExpression",e.BlockComment="BlockComment",e.BlockStatement="BlockStatement",e.BinaryExpression="BinaryExpression",e.BreakStatement="BreakStatement",e.CallExpression="CallExpression",e.ContinueStatement="ContinueStatement",e.EmptyStatement="EmptyStatement",e.ExpressionStatement="ExpressionStatement",e.ExportNamedDeclaration="ExportNamedDeclaration",e.ExportSpecifier="ExportSpecifier",e.ForStatement="ForStatement",e.ForInStatement="ForInStatement",e.FunctionDeclaration="FunctionDeclaration",e.Identifier="Identifier",e.IfStatement="IfStatement",e.ImportDeclaration="ImportDeclaration",e.ImportDefaultSpecifier="ImportDefaultSpecifier",e.LineComment="LineComment",e.Literal="Literal",e.LogicalExpression="LogicalExpression",e.MemberExpression="MemberExpression",e.ObjectExpression="ObjectExpression",e.Program="Program",e.Property="Property",e.ReturnStatement="ReturnStatement",e.TemplateElement="TemplateElement",e.TemplateLiteral="TemplateLiteral",e.UnaryExpression="UnaryExpression",e.UpdateExpression="UpdateExpression",e.VariableDeclaration="VariableDeclaration",e.VariableDeclarator="VariableDeclarator",e.WhileStatement="WhileStatement",e))(u||{}),l=(e=>(e[e.Unknown=0]="Unknown",e[e.BooleanLiteral=1]="BooleanLiteral",e[e.EOF=2]="EOF",e[e.Identifier=3]="Identifier",e[e.Keyword=4]="Keyword",e[e.NullLiteral=5]="NullLiteral",e[e.NumericLiteral=6]="NumericLiteral",e[e.Punctuator=7]="Punctuator",e[e.StringLiteral=8]="StringLiteral",e[e.Template=10]="Template",e))(l||{}),p=(e=>(e.InvalidModuleUri="InvalidModuleUri",e.ForInOfLoopInitializer="ForInOfLoopInitializer",e.IdentiferExpected="IdentiferExpected",e.InvalidEscapedReservedWord="InvalidEscapedReservedWord",e.InvalidExpression="InvalidExpression",e.InvalidFunctionIdentifier="InvalidFunctionIdentifier",e.InvalidHexEscapeSequence="InvalidHexEscapeSequence",e.InvalidLeftHandSideInAssignment="InvalidLeftHandSideInAssignment",e.InvalidLeftHandSideInForIn="InvalidLeftHandSideInForIn",e.InvalidTemplateHead="InvalidTemplateHead",e.InvalidVariableAssignment="InvalidVariableAssignment",e.KeyMustBeString="KeyMustBeString",e.NoFunctionInsideBlock="NoFunctionInsideBlock",e.NoFunctionInsideFunction="NoFunctionInsideFunction",e.ModuleExportRootOnly="ModuleExportRootOnly",e.ModuleImportRootOnly="ModuleImportRootOnly",e.PunctuatorExpected="PunctuatorExpected",e.TemplateOctalLiteral="TemplateOctalLiteral",e.UnexpectedBoolean="UnexpectedBoolean",e.UnexpectedEndOfScript="UnexpectedEndOfScript",e.UnexpectedIdentifier="UnexpectedIdentifier",e.UnexpectedKeyword="UnexpectedKeyword",e.UnexpectedNull="UnexpectedNull",e.UnexpectedNumber="UnexpectedNumber",e.UnexpectedPunctuator="UnexpectedPunctuator",e.UnexpectedString="UnexpectedString",e.UnexpectedTemplate="UnexpectedTemplate",e.UnexpectedToken="UnexpectedToken",e))(p||{}),d=[[],[],[]];["++","--"].forEach((e=>d[e.length-1].push(e))),["-","+","!","~"].forEach((e=>d[e.length-1].push(e))),["||","&&"].forEach((e=>d[e.length-1].push(e))),["=","/=","*=","%=","+=","-="].forEach((e=>d[e.length-1].push(e))),["|","&",">>","<<",">>>","^","==","!=","<","<=",">",">=","+","-","*","/","%"].forEach((e=>d[e.length-1].push(e)));var g,m=((g=m||{}).AlreadyDefined="AlreadyDefined",g.ApiConflict="ApiConflict",g.AssignedNeverUsed="AssignedNeverUsed",g.DefinedNeverAssigned="DefinedNeverAssigned",g.DefinedNeverUsed="DefinedNeverUsed",g.EmptyBlockStatement="EmptyBlockStatement",g.ExecutionError="ExecutionError",g.InvalidApiFunctionUsage="InvalidApiFunctionUsage",g.InvalidConstantIdentifier="InvalidConstantIdentifier",g.InvalidPropertyIdentifier="InvalidPropertyIdentifier",g.NoArgumentExpected="NoArgumentExpected",g.NotADictionary="NotADictionary",g.NotDefined="NotDefined",g.NotEnoughArguments="NotEnoughArguments",g.ProfileVariablesAreImmutable="ProfileVariablesAreImmutable",g.ProfileVariablesConflict="ProfileVariablesConflict",g.ReservedKeyword="ReservedKeyword",g.TooManyArguments="TooManyArguments",g.UnexpectedEmptyFunction="UnexpectedEmptyFunction",g.UnexpectedPropertyIdentifier="UnexpectedPropertyIdentifier",g.UnknownPropertyIdentifier="UnknownPropertyIdentifier",g),x=Object.values(c);Object.values(a).map((t=>({label:t,kind:e.CompletionItemKind.Constant}))),x.map((t=>({label:t,kind:e.CompletionItemKind.Keyword})));const h={wordPattern:/(-?\d*\.\d\w*)|([^`~!#%\^&\*\(\)\-=\+\[\{\]\}\\\|;:'",\.<>\/\?\s]+)/gu,comments:{lineComment:"//",blockComment:["/*","*/"]},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"',notIn:["string"]},{open:"'",close:"'",notIn:["string","comment"]},{open:"`",close:"`",notIn:["string","comment"]}],autoCloseBefore:";:.,=}])` \n\t",folding:{markers:{start:/^\s*\/\/\s*#?region\b/u,end:/^\s*\/\/\s*#?endregion\b/u}},indentationRules:{decreaseIndentPattern:/^((?!.*?\/\*).*\*\/)?\s*[\}\]\)].*$/u,increaseIndentPattern:/^((?!\/\/).)*(\{[^}"'`]*|\([^)"'`]*|\[[^\]"'`]*)$/u}},f={defaultToken:"invalid",tokenPostfix:".arc",ignoreCase:!0,keywords:x.filter((e=>"from"!==e)),operators:["<=",">=","==","!=","+","-","*","/","%","++","--","<<",">>",">>>","&","|","^","!","~","&&","||","=","+=","-=","*=","**=","/=","%="],constants:["true","false","null"],symbols:/[=><!~?:&|+\-*\/\^%]+/u,escapes:/\\(?:[abfnrtv\\"']|x[0-9A-Fa-f]{1,4}|u[0-9A-Fa-f]{4}|U[0-9A-Fa-f]{8})/u,digits:/\d+(_+\d+)*/u,octaldigits:/[0-7]+(_+[0-7]+)*/u,binarydigits:/[0-1]+(_+[0-1]+)*/u,hexdigits:/[[0-9a-fA-F]+(_+[0-9a-fA-F]+)*/u,regexpctl:/[(){}\[\]\$\^|\-*+?\.]/u,regexpesc:/\\(?:[bBdDfnrstvwWn0\\\/]|@regexpctl|c[A-Z]|x[0-9a-fA-F]{2}|u[0-9a-fA-F]{4})/u,tokenizer:{root:[[/[{}]/u,"delimiter.bracket"],{include:"common"}],common:[[/import(?=\s)/u,{token:"keyword",next:"@import"}],[/[a-z_$][\w$]*/u,{cases:{"@constants":"constant","@keywords":"keyword","@default":"identifier"}}],{include:"@whitespace"},[/\/(?=([^\\\/]|\\.)+\/([gimsuy]*)(\s*)(\.|;|\/|,|\)|\]|\}|$))/u,{token:"regexp",bracket:"@open",next:"@regexp"}],[/[()\[\]]/u,"@brackets"],[/[<>](?!@symbols)/u,"@brackets"],[/@symbols/u,{cases:{"@operators":"delimiter","@default":""}}],[/(@digits)[eE]([\-+]?(@digits))?/u,"number"],[/(@digits)\.(@digits)([eE][\-+]?(@digits))?/u,"number"],[/0[xX](@hexdigits)/u,"number"],[/0[oO]?(@octaldigits)/u,"number"],[/0[bB](@binarydigits)/u,"number"],[/(@digits)/u,"number"],[/[;,.]/u,"delimiter"],[/"([^"\\]|\\.)*$/u,"string.invalid"],[/'([^'\\]|\\.)*$/u,"string.invalid"],[/"/u,"string","@string_double"],[/'/u,"string","@string_single"],[/`/u,"string","@string_backtick"]],import:[[/import(?=\s)/u,{token:"keyword"}],{include:"@whitespace"},[/[a-z_$][\w$]*/u,"identifier"],{include:"@whitespace"},[/from/u,{token:"keyword",next:"@popall"}]],whitespace:[[/[ \t\r\n]+/u,""],[/\/\*/u,"comment","@comment"],[/\/\/.*$/u,"comment"]],comment:[[/[^\/*]+/u,"comment"],[/\*\//u,"comment","@pop"],[/[\/*]/u,"comment"]],regexp:[[/(\{)(\d+(?:,\d*)?)(\})/u,["regexp.escape.control","regexp.escape.control","regexp.escape.control"]],[/(\[)(\^?)(?=(?:[^\]\\\/]|\\.)+)/u,["regexp.escape.control",{token:"regexp.escape.control",next:"@regexrange"}]],[/(\()(\?:|\?=|\?!)/u,["regexp.escape.control","regexp.escape.control"]],[/[()]/u,"regexp.escape.control"],[/@regexpctl/u,"regexp.escape.control"],[/[^\\\/]/u,"regexp"],[/@regexpesc/u,"regexp.escape"],[/\\\./u,"regexp.invalid"],[/(\/)([gimsuy]*)/u,[{token:"regexp",bracket:"@close",next:"@pop"},"keyword.other"]]],regexrange:[[/-/u,"regexp.escape.control"],[/\^/u,"regexp.invalid"],[/@regexpesc/u,"regexp.escape"],[/[^\]]/u,"regexp"],[/\]/u,{token:"regexp.escape.control",next:"@pop",bracket:"@close"}]],string_double:[[/[^\\"]+/u,"string"],[/@escapes/u,"string.escape"],[/\\./u,"string.escape.invalid"],[/"/u,"string","@pop"]],string_single:[[/[^\\']+/u,"string"],[/@escapes/u,"string.escape"],[/\\./u,"string.escape.invalid"],[/'/u,"string","@pop"]],string_backtick:[[/\$\{/u,{token:"delimiter.bracket",next:"@bracketCounting"}],[/[^\\`$]+/u,"string"],[/@escapes/u,"string.escape"],[/\\./u,"string.escape.invalid"],[/`/u,"string","@pop"]],bracketCounting:[[/\{/u,"delimiter.bracket","@bracketCounting"],[/\}/u,"delimiter.bracket","@pop"],{include:"common"}]}};class b{constructor(e,n,{defaults:r,diagnosticsService:i}){this._languageId=e,this._worker=n,this._disposables=[],this._listener=Object.create(null),this._diagnosticsService=i,this._defaults=r;const s=e=>{const t=e.getLanguageId();if(t!==this._languageId)return;let n;this._listener[e.uri.toString()]=e.onDidChangeContent((()=>{window.clearTimeout(n),n=window.setTimeout((()=>this._doValidate(e,t)),500)})),this._doValidate(e,t)},o=e=>{const n=e.uri.toString();t.setModelMarkers(e,this._languageId,[]);const r=this._listener[n];r&&(r.dispose(),delete this._listener[n])};this._disposables.push(t.onDidCreateModel(s)),this._disposables.push(t.onWillDisposeModel((e=>{o(e)}))),this._disposables.push(t.onDidChangeModelLanguage((e=>{o(e.model),s(e.model)}))),this._disposables.push(r.onDidChange((()=>{t.getModels().forEach((e=>{e.getLanguageId()===this._languageId&&(o(e),s(e))}))}))),this._disposables.push(r.onModelContextDidChange((e=>{t.getModels().forEach((t=>{t.getLanguageId()===this._languageId&&t.uri.toString()===e&&this._doValidate(t,this._languageId)}))}))),this._disposables.push({dispose:()=>{for(const e of Object.keys(this._listener))this._listener[e].dispose()}}),t.getModels().forEach(s)}dispose(){this._disposables.forEach((e=>e&&e.dispose())),this._disposables=[]}async _doValidate(e,n){if(e.isAttachedToEditor())try{const r=await this._worker(e.uri),i=this._defaults.getApiContextForModel(e.uri),s=await r.doValidation(e.uri.toString(),i),o=s.map((e=>{return{severity:k((t=e).severity),startLineNumber:t.range.start.line+1,startColumn:t.range.start.character+1,endLineNumber:t.range.end.line+1,endColumn:t.range.end.character+1,message:t.message};var t}));this._diagnosticsService.fireDiagnosticsChange(e.uri,s),t.setModelMarkers(e,n,o)}catch(e){console.error(e)}}}function k(t){switch(t){case e.DiagnosticSeverity.Error:return n.Error;case e.DiagnosticSeverity.Warning:return n.Warning;case e.DiagnosticSeverity.Information:return n.Info;case e.DiagnosticSeverity.Hint:return n.Hint;default:return n.Info}}function w(e){return new r(e.start.line+1,e.start.character+1,e.end.line+1,e.end.character+1)}function I(e){return{range:w(e.range),text:e.newText}}function y(t){const n=i.CompletionItemKind;switch(t){case e.CompletionItemKind.Text:return n.Text;case e.CompletionItemKind.Method:return n.Method;case e.CompletionItemKind.Function:return n.Function;case e.CompletionItemKind.Constructor:return n.Constructor;case e.CompletionItemKind.Field:return n.Field;case e.CompletionItemKind.Variable:return n.Variable;case e.CompletionItemKind.Class:return n.Class;case e.CompletionItemKind.Interface:return n.Interface;case e.CompletionItemKind.Module:return n.Module;case e.CompletionItemKind.Property:return n.Property;case e.CompletionItemKind.Unit:return n.Unit;case e.CompletionItemKind.Value:return n.Value;case e.CompletionItemKind.Enum:return n.Enum;case e.CompletionItemKind.Keyword:return n.Keyword;case e.CompletionItemKind.Snippet:return n.Snippet;case e.CompletionItemKind.Color:return n.Color;case e.CompletionItemKind.File:return n.File;case e.CompletionItemKind.Reference:return n.Reference;case e.CompletionItemKind.Folder:return n.Folder;case e.CompletionItemKind.EnumMember:return n.EnumMember;case e.CompletionItemKind.Constant:return n.Constant;case e.CompletionItemKind.Struct:return n.Struct;case e.CompletionItemKind.Event:return n.Event;case e.CompletionItemKind.Operator:return n.Operator;case e.CompletionItemKind.TypeParameter:return n.TypeParameter}return n.Property}class v{constructor(e,t){this._worker=e,this._defaults=t,this.triggerCharacters=[".","("]}async provideCompletionItems(t,n){const s=await this._worker(t.uri),o=this._defaults.getApiContextForModel(t.uri),a=await s.doComplete(t.uri.toString(),function(e){return{character:e.column-1,line:e.lineNumber-1}}(n),o);if(!a)return;const c=t.getWordUntilPosition(n),u=new r(n.lineNumber,c.startColumn,n.lineNumber,c.endColumn),l=a.items.map((t=>{const n={label:t.label,insertText:t.insertText||t.label,sortText:t.sortText,filterText:t.filterText,detail:t.detail,range:u,kind:y(t.kind)};var r;return t.textEdit&&(n.range=void 0!==(r=t.textEdit).insert&&void 0!==r.replace?{insert:w(t.textEdit.insert),replace:w(t.textEdit.replace)}:w(t.textEdit.range),n.insertText=t.textEdit.newText),t.additionalTextEdits&&(n.additionalTextEdits=t.additionalTextEdits.map(I)),t.insertTextFormat===e.InsertTextFormat.Snippet&&(n.insertTextRules=i.CompletionItemInsertTextRule.InsertAsSnippet),t.documentation&&(n.documentation="string"==typeof t.documentation?t.documentation:{supportThemeIcons:!1,value:t.documentation.value,supportHtml:!0}),n}));return{incomplete:a.isIncomplete,suggestions:l}}}class E{constructor(e,t){this._worker=e,this._defaults=t}async provideDocumentFormattingEdits(e){const t=await this._worker(e.uri),n=this._defaults.getApiContextForModel(e.uri.toString()),r=await t.doFormat(e.uri.toString(),n);return r?r.map((e=>({range:w(e.range),text:e.newText}))):[]}}class S{constructor(e){this._defaults=e,this._worker=null,this._client=null,this._configChangeListener=this._defaults.onDidChange((()=>this.stopWorker()))}dispose(){this._configChangeListener.dispose(),this.stopWorker()}stopWorker(){this._worker&&(this._worker.dispose(),this._worker=null),this._client=null}_getClientProxy(){if(!this._client){const{languageId:e,languageOptions:n}=this._defaults;this._worker=t.createWebWorker({moduleId:"ArcadeWorker",label:e,createData:{languageId:e,languageOptions:n}}),this._client=this._worker.getProxy()}return this._client}async getLanguageServiceWorker(...e){const t=await this._getClientProxy();return await(this._worker?.withSyncedResources(e)),t}}let A;async function C(...e){return new Promise(((t,n)=>{if(!A)return n(new Error("TypeScript not registered!"));t(A(...e))}))}const U=new class{constructor(){this._onDiagnosticsChange=new s}get onDiagnosticsChange(){return this._onDiagnosticsChange.event}fireDiagnosticsChange(e,t){this._onDiagnosticsChange.fire({uri:e,diagnostics:t})}};function F(){return U}function P(e){const t=new S(e),n=(...e)=>t.getLanguageServiceWorker(...e);A=n,i.setMonarchTokensProvider(e.languageId,f),i.setLanguageConfiguration(e.languageId,h),i.registerCompletionItemProvider(e.languageId,new v(n,e)),i.registerDocumentFormattingEditProvider(e.languageId,new E(n,e)),new b(e.languageId,n,{defaults:e,diagnosticsService:U})}export{F as getArcadeDiagnosticService,C as getArcadeWorker,P as setupMode}
1
+ import{n as e,e as t,M as n,R as r,l as i,E as s}from"./p-f5598cde.js";import"./p-2c0d6f15.js";var o,a=((o=a||{}).False="false",o.Null="null",o.True="true",o),c=(e=>(e.Break="break",e.Continue="continue",e.Else="else",e.For="for",e.From="from",e.Function="function",e.If="if",e.Import="import",e.Export="export",e.In="in",e.Return="return",e.Var="var",e.While="while",e))(c||{}),u=(e=>(e.AssignmentExpression="AssignmentExpression",e.ArrayExpression="ArrayExpression",e.BlockComment="BlockComment",e.BlockStatement="BlockStatement",e.BinaryExpression="BinaryExpression",e.BreakStatement="BreakStatement",e.CallExpression="CallExpression",e.ContinueStatement="ContinueStatement",e.EmptyStatement="EmptyStatement",e.ExpressionStatement="ExpressionStatement",e.ExportNamedDeclaration="ExportNamedDeclaration",e.ExportSpecifier="ExportSpecifier",e.ForStatement="ForStatement",e.ForInStatement="ForInStatement",e.FunctionDeclaration="FunctionDeclaration",e.Identifier="Identifier",e.IfStatement="IfStatement",e.ImportDeclaration="ImportDeclaration",e.ImportDefaultSpecifier="ImportDefaultSpecifier",e.LineComment="LineComment",e.Literal="Literal",e.LogicalExpression="LogicalExpression",e.MemberExpression="MemberExpression",e.ObjectExpression="ObjectExpression",e.Program="Program",e.Property="Property",e.ReturnStatement="ReturnStatement",e.TemplateElement="TemplateElement",e.TemplateLiteral="TemplateLiteral",e.UnaryExpression="UnaryExpression",e.UpdateExpression="UpdateExpression",e.VariableDeclaration="VariableDeclaration",e.VariableDeclarator="VariableDeclarator",e.WhileStatement="WhileStatement",e))(u||{}),l=(e=>(e[e.Unknown=0]="Unknown",e[e.BooleanLiteral=1]="BooleanLiteral",e[e.EOF=2]="EOF",e[e.Identifier=3]="Identifier",e[e.Keyword=4]="Keyword",e[e.NullLiteral=5]="NullLiteral",e[e.NumericLiteral=6]="NumericLiteral",e[e.Punctuator=7]="Punctuator",e[e.StringLiteral=8]="StringLiteral",e[e.Template=10]="Template",e))(l||{}),p=(e=>(e.InvalidModuleUri="InvalidModuleUri",e.ForInOfLoopInitializer="ForInOfLoopInitializer",e.IdentiferExpected="IdentiferExpected",e.InvalidEscapedReservedWord="InvalidEscapedReservedWord",e.InvalidExpression="InvalidExpression",e.InvalidFunctionIdentifier="InvalidFunctionIdentifier",e.InvalidHexEscapeSequence="InvalidHexEscapeSequence",e.InvalidLeftHandSideInAssignment="InvalidLeftHandSideInAssignment",e.InvalidLeftHandSideInForIn="InvalidLeftHandSideInForIn",e.InvalidTemplateHead="InvalidTemplateHead",e.InvalidVariableAssignment="InvalidVariableAssignment",e.KeyMustBeString="KeyMustBeString",e.NoFunctionInsideBlock="NoFunctionInsideBlock",e.NoFunctionInsideFunction="NoFunctionInsideFunction",e.ModuleExportRootOnly="ModuleExportRootOnly",e.ModuleImportRootOnly="ModuleImportRootOnly",e.PunctuatorExpected="PunctuatorExpected",e.TemplateOctalLiteral="TemplateOctalLiteral",e.UnexpectedBoolean="UnexpectedBoolean",e.UnexpectedEndOfScript="UnexpectedEndOfScript",e.UnexpectedIdentifier="UnexpectedIdentifier",e.UnexpectedKeyword="UnexpectedKeyword",e.UnexpectedNull="UnexpectedNull",e.UnexpectedNumber="UnexpectedNumber",e.UnexpectedPunctuator="UnexpectedPunctuator",e.UnexpectedString="UnexpectedString",e.UnexpectedTemplate="UnexpectedTemplate",e.UnexpectedToken="UnexpectedToken",e))(p||{}),d=[[],[],[]];["++","--"].forEach((e=>d[e.length-1].push(e))),["-","+","!","~"].forEach((e=>d[e.length-1].push(e))),["||","&&"].forEach((e=>d[e.length-1].push(e))),["=","/=","*=","%=","+=","-="].forEach((e=>d[e.length-1].push(e))),["|","&",">>","<<",">>>","^","==","!=","<","<=",">",">=","+","-","*","/","%"].forEach((e=>d[e.length-1].push(e)));var g,m=((g=m||{}).AlreadyDefined="AlreadyDefined",g.ApiConflict="ApiConflict",g.AssignedNeverUsed="AssignedNeverUsed",g.DefinedNeverAssigned="DefinedNeverAssigned",g.DefinedNeverUsed="DefinedNeverUsed",g.EmptyBlockStatement="EmptyBlockStatement",g.ExecutionError="ExecutionError",g.InvalidApiFunctionUsage="InvalidApiFunctionUsage",g.InvalidConstantIdentifier="InvalidConstantIdentifier",g.InvalidPropertyIdentifier="InvalidPropertyIdentifier",g.NoArgumentExpected="NoArgumentExpected",g.NotADictionary="NotADictionary",g.NotDefined="NotDefined",g.NotEnoughArguments="NotEnoughArguments",g.ProfileVariablesAreImmutable="ProfileVariablesAreImmutable",g.ProfileVariablesConflict="ProfileVariablesConflict",g.ReservedKeyword="ReservedKeyword",g.TooManyArguments="TooManyArguments",g.UnexpectedEmptyFunction="UnexpectedEmptyFunction",g.UnexpectedPropertyIdentifier="UnexpectedPropertyIdentifier",g.UnknownPropertyIdentifier="UnknownPropertyIdentifier",g),x=Object.values(c);Object.values(a).map((t=>({label:t,kind:e.CompletionItemKind.Constant}))),x.map((t=>({label:t,kind:e.CompletionItemKind.Keyword})));const h={wordPattern:/(-?\d*\.\d\w*)|([^`~!#%\^&\*\(\)\-=\+\[\{\]\}\\\|;:'",\.<>\/\?\s]+)/gu,comments:{lineComment:"//",blockComment:["/*","*/"]},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"',notIn:["string"]},{open:"'",close:"'",notIn:["string","comment"]},{open:"`",close:"`",notIn:["string","comment"]}],autoCloseBefore:";:.,=}])` \n\t",folding:{markers:{start:/^\s*\/\/\s*#?region\b/u,end:/^\s*\/\/\s*#?endregion\b/u}},indentationRules:{decreaseIndentPattern:/^((?!.*?\/\*).*\*\/)?\s*[\}\]\)].*$/u,increaseIndentPattern:/^((?!\/\/).)*(\{[^}"'`]*|\([^)"'`]*|\[[^\]"'`]*)$/u}},f={defaultToken:"invalid",tokenPostfix:".arc",ignoreCase:!0,keywords:x.filter((e=>"from"!==e)),operators:["<=",">=","==","!=","+","-","*","/","%","++","--","<<",">>",">>>","&","|","^","!","~","&&","||","=","+=","-=","*=","**=","/=","%="],constants:["true","false","null"],symbols:/[=><!~?:&|+\-*\/\^%]+/u,escapes:/\\(?:[abfnrtv\\"']|x[0-9A-Fa-f]{1,4}|u[0-9A-Fa-f]{4}|U[0-9A-Fa-f]{8})/u,digits:/\d+(_+\d+)*/u,octaldigits:/[0-7]+(_+[0-7]+)*/u,binarydigits:/[0-1]+(_+[0-1]+)*/u,hexdigits:/[[0-9a-fA-F]+(_+[0-9a-fA-F]+)*/u,regexpctl:/[(){}\[\]\$\^|\-*+?\.]/u,regexpesc:/\\(?:[bBdDfnrstvwWn0\\\/]|@regexpctl|c[A-Z]|x[0-9a-fA-F]{2}|u[0-9a-fA-F]{4})/u,tokenizer:{root:[[/[{}]/u,"delimiter.bracket"],{include:"common"}],common:[[/import(?=\s)/u,{token:"keyword",next:"@import"}],[/[a-z_$][\w$]*/u,{cases:{"@constants":"constant","@keywords":"keyword","@default":"identifier"}}],{include:"@whitespace"},[/\/(?=([^\\\/]|\\.)+\/([gimsuy]*)(\s*)(\.|;|\/|,|\)|\]|\}|$))/u,{token:"regexp",bracket:"@open",next:"@regexp"}],[/[()\[\]]/u,"@brackets"],[/[<>](?!@symbols)/u,"@brackets"],[/@symbols/u,{cases:{"@operators":"delimiter","@default":""}}],[/(@digits)[eE]([\-+]?(@digits))?/u,"number"],[/(@digits)\.(@digits)([eE][\-+]?(@digits))?/u,"number"],[/0[xX](@hexdigits)/u,"number"],[/0[oO]?(@octaldigits)/u,"number"],[/0[bB](@binarydigits)/u,"number"],[/(@digits)/u,"number"],[/[;,.]/u,"delimiter"],[/"([^"\\]|\\.)*$/u,"string.invalid"],[/'([^'\\]|\\.)*$/u,"string.invalid"],[/"/u,"string","@string_double"],[/'/u,"string","@string_single"],[/`/u,"string","@string_backtick"]],import:[[/import(?=\s)/u,{token:"keyword"}],{include:"@whitespace"},[/[a-z_$][\w$]*/u,"identifier"],{include:"@whitespace"},[/from/u,{token:"keyword",next:"@popall"}]],whitespace:[[/[ \t\r\n]+/u,""],[/\/\*/u,"comment","@comment"],[/\/\/.*$/u,"comment"]],comment:[[/[^\/*]+/u,"comment"],[/\*\//u,"comment","@pop"],[/[\/*]/u,"comment"]],regexp:[[/(\{)(\d+(?:,\d*)?)(\})/u,["regexp.escape.control","regexp.escape.control","regexp.escape.control"]],[/(\[)(\^?)(?=(?:[^\]\\\/]|\\.)+)/u,["regexp.escape.control",{token:"regexp.escape.control",next:"@regexrange"}]],[/(\()(\?:|\?=|\?!)/u,["regexp.escape.control","regexp.escape.control"]],[/[()]/u,"regexp.escape.control"],[/@regexpctl/u,"regexp.escape.control"],[/[^\\\/]/u,"regexp"],[/@regexpesc/u,"regexp.escape"],[/\\\./u,"regexp.invalid"],[/(\/)([gimsuy]*)/u,[{token:"regexp",bracket:"@close",next:"@pop"},"keyword.other"]]],regexrange:[[/-/u,"regexp.escape.control"],[/\^/u,"regexp.invalid"],[/@regexpesc/u,"regexp.escape"],[/[^\]]/u,"regexp"],[/\]/u,{token:"regexp.escape.control",next:"@pop",bracket:"@close"}]],string_double:[[/[^\\"]+/u,"string"],[/@escapes/u,"string.escape"],[/\\./u,"string.escape.invalid"],[/"/u,"string","@pop"]],string_single:[[/[^\\']+/u,"string"],[/@escapes/u,"string.escape"],[/\\./u,"string.escape.invalid"],[/'/u,"string","@pop"]],string_backtick:[[/\$\{/u,{token:"delimiter.bracket",next:"@bracketCounting"}],[/[^\\`$]+/u,"string"],[/@escapes/u,"string.escape"],[/\\./u,"string.escape.invalid"],[/`/u,"string","@pop"]],bracketCounting:[[/\{/u,"delimiter.bracket","@bracketCounting"],[/\}/u,"delimiter.bracket","@pop"],{include:"common"}]}};class b{constructor(e,n,{defaults:r,diagnosticsService:i}){this._languageId=e,this._worker=n,this._disposables=[],this._listener=Object.create(null),this._diagnosticsService=i,this._defaults=r;const s=e=>{const t=e.getLanguageId();if(t!==this._languageId)return;let n;this._listener[e.uri.toString()]=e.onDidChangeContent((()=>{window.clearTimeout(n),n=window.setTimeout((()=>this._doValidate(e,t)),500)})),this._doValidate(e,t)},o=e=>{const n=e.uri.toString();t.setModelMarkers(e,this._languageId,[]);const r=this._listener[n];r&&(r.dispose(),delete this._listener[n])};this._disposables.push(t.onDidCreateModel(s)),this._disposables.push(t.onWillDisposeModel((e=>{o(e)}))),this._disposables.push(t.onDidChangeModelLanguage((e=>{o(e.model),s(e.model)}))),this._disposables.push(r.onDidChange((()=>{t.getModels().forEach((e=>{e.getLanguageId()===this._languageId&&(o(e),s(e))}))}))),this._disposables.push(r.onModelContextDidChange((e=>{t.getModels().forEach((t=>{t.getLanguageId()===this._languageId&&t.uri.toString()===e&&this._doValidate(t,this._languageId)}))}))),this._disposables.push({dispose:()=>{for(const e of Object.keys(this._listener))this._listener[e].dispose()}}),t.getModels().forEach(s)}dispose(){this._disposables.forEach((e=>e&&e.dispose())),this._disposables=[]}async _doValidate(e,n){if(e.isAttachedToEditor())try{const r=await this._worker(e.uri),i=this._defaults.getApiContextForModel(e.uri),s=await r.doValidation(e.uri.toString(),i),o=s.map((e=>{return{severity:k((t=e).severity),startLineNumber:t.range.start.line+1,startColumn:t.range.start.character+1,endLineNumber:t.range.end.line+1,endColumn:t.range.end.character+1,message:t.message};var t}));this._diagnosticsService.fireDiagnosticsChange(e.uri,s),t.setModelMarkers(e,n,o)}catch(e){console.error(e)}}}function k(t){switch(t){case e.DiagnosticSeverity.Error:return n.Error;case e.DiagnosticSeverity.Warning:return n.Warning;case e.DiagnosticSeverity.Information:return n.Info;case e.DiagnosticSeverity.Hint:return n.Hint;default:return n.Info}}function w(e){return new r(e.start.line+1,e.start.character+1,e.end.line+1,e.end.character+1)}function I(e){return{range:w(e.range),text:e.newText}}function y(t){const n=i.CompletionItemKind;switch(t){case e.CompletionItemKind.Text:return n.Text;case e.CompletionItemKind.Method:return n.Method;case e.CompletionItemKind.Function:return n.Function;case e.CompletionItemKind.Constructor:return n.Constructor;case e.CompletionItemKind.Field:return n.Field;case e.CompletionItemKind.Variable:return n.Variable;case e.CompletionItemKind.Class:return n.Class;case e.CompletionItemKind.Interface:return n.Interface;case e.CompletionItemKind.Module:return n.Module;case e.CompletionItemKind.Property:return n.Property;case e.CompletionItemKind.Unit:return n.Unit;case e.CompletionItemKind.Value:return n.Value;case e.CompletionItemKind.Enum:return n.Enum;case e.CompletionItemKind.Keyword:return n.Keyword;case e.CompletionItemKind.Snippet:return n.Snippet;case e.CompletionItemKind.Color:return n.Color;case e.CompletionItemKind.File:return n.File;case e.CompletionItemKind.Reference:return n.Reference;case e.CompletionItemKind.Folder:return n.Folder;case e.CompletionItemKind.EnumMember:return n.EnumMember;case e.CompletionItemKind.Constant:return n.Constant;case e.CompletionItemKind.Struct:return n.Struct;case e.CompletionItemKind.Event:return n.Event;case e.CompletionItemKind.Operator:return n.Operator;case e.CompletionItemKind.TypeParameter:return n.TypeParameter}return n.Property}class v{constructor(e,t){this._worker=e,this._defaults=t,this.triggerCharacters=[".","("]}async provideCompletionItems(t,n){const s=await this._worker(t.uri),o=this._defaults.getApiContextForModel(t.uri),a=await s.doComplete(t.uri.toString(),function(e){return{character:e.column-1,line:e.lineNumber-1}}(n),o);if(!a)return;const c=t.getWordUntilPosition(n),u=new r(n.lineNumber,c.startColumn,n.lineNumber,c.endColumn),l=a.items.map((t=>{const n={label:t.label,insertText:t.insertText||t.label,sortText:t.sortText,filterText:t.filterText,detail:t.detail,range:u,kind:y(t.kind)};var r;return t.textEdit&&(n.range=void 0!==(r=t.textEdit).insert&&void 0!==r.replace?{insert:w(t.textEdit.insert),replace:w(t.textEdit.replace)}:w(t.textEdit.range),n.insertText=t.textEdit.newText),t.additionalTextEdits&&(n.additionalTextEdits=t.additionalTextEdits.map(I)),t.insertTextFormat===e.InsertTextFormat.Snippet&&(n.insertTextRules=i.CompletionItemInsertTextRule.InsertAsSnippet),t.documentation&&(n.documentation="string"==typeof t.documentation?t.documentation:{supportThemeIcons:!1,value:t.documentation.value,supportHtml:!0}),n}));return{incomplete:a.isIncomplete,suggestions:l}}}class E{constructor(e,t){this._worker=e,this._defaults=t}async provideDocumentFormattingEdits(e){const t=await this._worker(e.uri),n=this._defaults.getApiContextForModel(e.uri.toString()),r=await t.doFormat(e.uri.toString(),n);return r?r.map((e=>({range:w(e.range),text:e.newText}))):[]}}class S{constructor(e){this._defaults=e,this._worker=null,this._client=null,this._configChangeListener=this._defaults.onDidChange((()=>this.stopWorker()))}dispose(){this._configChangeListener.dispose(),this.stopWorker()}stopWorker(){this._worker&&(this._worker.dispose(),this._worker=null),this._client=null}_getClientProxy(){if(!this._client){const{languageId:e,languageOptions:n}=this._defaults;this._worker=t.createWebWorker({moduleId:"ArcadeWorker",label:e,createData:{languageId:e,languageOptions:n}}),this._client=this._worker.getProxy()}return this._client}async getLanguageServiceWorker(...e){const t=await this._getClientProxy();return await(this._worker?.withSyncedResources(e)),t}}let A;async function C(...e){return new Promise(((t,n)=>{if(!A)return n(new Error("TypeScript not registered!"));t(A(...e))}))}const U=new class{constructor(){this._onDiagnosticsChange=new s}get onDiagnosticsChange(){return this._onDiagnosticsChange.event}fireDiagnosticsChange(e,t){this._onDiagnosticsChange.fire({uri:e,diagnostics:t})}};function F(){return U}function P(e){const t=new S(e),n=(...e)=>t.getLanguageServiceWorker(...e);A=n,i.setMonarchTokensProvider(e.languageId,f),i.setLanguageConfiguration(e.languageId,h),i.registerCompletionItemProvider(e.languageId,new v(n,e)),i.registerDocumentFormattingEditProvider(e.languageId,new E(n,e)),new b(e.languageId,n,{defaults:e,diagnosticsService:U})}export{F as getArcadeDiagnosticService,C as getArcadeWorker,P as setupMode}
@@ -1,4 +1,4 @@
1
- import{t,m as e}from"./p-0d616249.js";import"./p-2c0d6f15.js";
1
+ import{t,m as e}from"./p-f5598cde.js";import"./p-2c0d6f15.js";
2
2
  /*!-----------------------------------------------------------------------------
3
3
  * Copyright (c) Microsoft Corporation. All rights reserved.
4
4
  * Version: 0.44.0(3e047efd345ff102c8c61b5398fb30845aaac166)
@@ -1,4 +1,4 @@
1
- import{m as e}from"./p-0d616249.js";import"./p-2c0d6f15.js";
1
+ import{m as e}from"./p-f5598cde.js";import"./p-2c0d6f15.js";
2
2
  /*!-----------------------------------------------------------------------------
3
3
  * Copyright (c) Microsoft Corporation. All rights reserved.
4
4
  * Version: 0.44.0(3e047efd345ff102c8c61b5398fb30845aaac166)
@@ -1,4 +1,4 @@
1
- import{m as t}from"./p-0d616249.js";import"./p-2c0d6f15.js";
1
+ import{m as t}from"./p-f5598cde.js";import"./p-2c0d6f15.js";
2
2
  /*!-----------------------------------------------------------------------------
3
3
  * Copyright (c) Microsoft Corporation. All rights reserved.
4
4
  * Version: 0.44.0(3e047efd345ff102c8c61b5398fb30845aaac166)
@@ -1,4 +1,4 @@
1
- import{conf as e,language as t}from"./p-aefe77ce.js";import"./p-0d616249.js";import"./p-2c0d6f15.js";
1
+ import{conf as e,language as t}from"./p-99fbda7a.js";import"./p-f5598cde.js";import"./p-2c0d6f15.js";
2
2
  /*!-----------------------------------------------------------------------------
3
3
  * Copyright (c) Microsoft Corporation. All rights reserved.
4
4
  * Version: 0.44.0(3e047efd345ff102c8c61b5398fb30845aaac166)
@@ -1,4 +1,4 @@
1
- import{m as t}from"./p-0d616249.js";import"./p-2c0d6f15.js";
1
+ import{m as t}from"./p-f5598cde.js";import"./p-2c0d6f15.js";
2
2
  /*!-----------------------------------------------------------------------------
3
3
  * Copyright (c) Microsoft Corporation. All rights reserved.
4
4
  * Version: 0.44.0(3e047efd345ff102c8c61b5398fb30845aaac166)
@@ -1,4 +1,4 @@
1
- import{m as e}from"./p-0d616249.js";import"./p-2c0d6f15.js";
1
+ import{m as e}from"./p-f5598cde.js";import"./p-2c0d6f15.js";
2
2
  /*!-----------------------------------------------------------------------------
3
3
  * Copyright (c) Microsoft Corporation. All rights reserved.
4
4
  * Version: 0.44.0(3e047efd345ff102c8c61b5398fb30845aaac166)