@abuswami1996/agent-md 0.1.0

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 (96) hide show
  1. package/CHANGELOG.md +9 -0
  2. package/LICENSE +21 -0
  3. package/README.md +43 -0
  4. package/agent-md-preview.vsix +0 -0
  5. package/dist/index.d.ts +2 -0
  6. package/dist/index.js +932 -0
  7. package/package.json +45 -0
  8. package/viewer-dist/assets/arc-BGWRvh4A.js +1 -0
  9. package/viewer-dist/assets/architecture-7EHR7CIX-tMtXFVEB.js +1 -0
  10. package/viewer-dist/assets/architectureDiagram-3BPJPVTR-BpnMGpeV.js +36 -0
  11. package/viewer-dist/assets/array-CLXCPui0.js +1 -0
  12. package/viewer-dist/assets/blockDiagram-GPEHLZMM-BHk4-xwc.js +132 -0
  13. package/viewer-dist/assets/c4Diagram-AAUBKEIU-BShCidQJ.js +10 -0
  14. package/viewer-dist/assets/channel-BeF3oGSA.js +1 -0
  15. package/viewer-dist/assets/chunk-2J33WTMH-D_hBYQSk.js +1 -0
  16. package/viewer-dist/assets/chunk-3OPIFGDE-yFgTZecx.js +62 -0
  17. package/viewer-dist/assets/chunk-4BX2VUAB-BrcCtoyJ.js +1 -0
  18. package/viewer-dist/assets/chunk-4EGX6M5U-sKH2Isf8.js +1 -0
  19. package/viewer-dist/assets/chunk-55IACEB6-DbDA7kYA.js +1 -0
  20. package/viewer-dist/assets/chunk-5DO6E6H7-DVriMWxp.js +1 -0
  21. package/viewer-dist/assets/chunk-5ZQYHXKU-DQ5fX41l.js +2 -0
  22. package/viewer-dist/assets/chunk-727SXJPM-SK34XSEC.js +206 -0
  23. package/viewer-dist/assets/chunk-AQP2D5EJ-DXK-1dYB.js +231 -0
  24. package/viewer-dist/assets/chunk-BR22UD5L-BCm2xrxa.js +1 -0
  25. package/viewer-dist/assets/chunk-BSJP7CBP-B3Tyh4s5.js +1 -0
  26. package/viewer-dist/assets/chunk-CSCIHK7Q-BmRiMG-E.js +123 -0
  27. package/viewer-dist/assets/chunk-FHYWG6QK-B_z4diOF.js +1 -0
  28. package/viewer-dist/assets/chunk-FMBD7UC4-Dxft-q4P.js +15 -0
  29. package/viewer-dist/assets/chunk-KSCS5N6A-eA-nZKPR.js +10 -0
  30. package/viewer-dist/assets/chunk-L5ZTLDWV-CJt5R1DD.js +1 -0
  31. package/viewer-dist/assets/chunk-MPE355IW-BrU23f3r.js +1 -0
  32. package/viewer-dist/assets/chunk-MZUSXYTE-BGj-wpbJ.js +1 -0
  33. package/viewer-dist/assets/chunk-N66VUXT2-Bx9F_D4P.js +1 -0
  34. package/viewer-dist/assets/chunk-ND2GUHAM-DhxorC-R.js +1 -0
  35. package/viewer-dist/assets/chunk-NNHCCRGN-DSaPFNsL.js +159 -0
  36. package/viewer-dist/assets/chunk-NZK2D7GU-DaLfDAf-.js +1 -0
  37. package/viewer-dist/assets/chunk-O5CBEL6O-D0rppU0M.js +70 -0
  38. package/viewer-dist/assets/chunk-PUPMXCY4-C2l0dHY4.js +1 -0
  39. package/viewer-dist/assets/chunk-QZHKN3VN-CqO4Iw07.js +1 -0
  40. package/viewer-dist/assets/chunk-UIBZB4QT-DXVjm6Jo.js +1 -0
  41. package/viewer-dist/assets/chunk-WCWK7LTN-zc10zcLo.js +1 -0
  42. package/viewer-dist/assets/classDiagram-4FO5ZUOK-tR_J6scJ.js +1 -0
  43. package/viewer-dist/assets/classDiagram-v2-Q7XG4LA2-DStV2Q4p.js +1 -0
  44. package/viewer-dist/assets/cose-bilkent-S5V4N54A-SSDlF1_a.js +1 -0
  45. package/viewer-dist/assets/cytoscape.esm-mg8EQp5B.js +321 -0
  46. package/viewer-dist/assets/dagre-BM42HDAG-CbZJzBab.js +4 -0
  47. package/viewer-dist/assets/dagre-CdwzCXQr.js +1 -0
  48. package/viewer-dist/assets/defaultLocale-Dda4OpKy.js +1 -0
  49. package/viewer-dist/assets/diagram-2AECGRRQ-BB3K5hE5.js +43 -0
  50. package/viewer-dist/assets/diagram-5GNKFQAL-DWmbyuQH.js +10 -0
  51. package/viewer-dist/assets/diagram-KO2AKTUF-CYSKyVh3.js +3 -0
  52. package/viewer-dist/assets/diagram-LMA3HP47-CyTMJfPw.js +24 -0
  53. package/viewer-dist/assets/diagram-OG6HWLK6-72YuHoex.js +24 -0
  54. package/viewer-dist/assets/dist-Cz_gOj_F.js +1 -0
  55. package/viewer-dist/assets/erDiagram-TEJ5UH35-B7Z-qey-.js +85 -0
  56. package/viewer-dist/assets/eventmodeling-FCH6USID-Cmphiy0Z.js +1 -0
  57. package/viewer-dist/assets/flowDiagram-I6XJVG4X-Bd8YQF0F.js +162 -0
  58. package/viewer-dist/assets/ganttDiagram-6RSMTGT7-B0R6fBcN.js +292 -0
  59. package/viewer-dist/assets/gitGraph-WXDBUCRP-CABAU2x_.js +1 -0
  60. package/viewer-dist/assets/gitGraphDiagram-PVQCEYII-DgTF7l00.js +106 -0
  61. package/viewer-dist/assets/graphlib-B0DVs0bw.js +1 -0
  62. package/viewer-dist/assets/index-BiU7pYUM.css +1 -0
  63. package/viewer-dist/assets/index-C_Rab63U.js +99 -0
  64. package/viewer-dist/assets/info-J43DQDTF-CtHtznhp.js +1 -0
  65. package/viewer-dist/assets/infoDiagram-5YYISTIA-D3ae-MRJ.js +2 -0
  66. package/viewer-dist/assets/init-Ct4VudL3.js +1 -0
  67. package/viewer-dist/assets/ishikawaDiagram-YF4QCWOH-BpRQFD12.js +70 -0
  68. package/viewer-dist/assets/journeyDiagram-JHISSGLW-DTbccBmQ.js +139 -0
  69. package/viewer-dist/assets/kanban-definition-UN3LZRKU-DBpDPAaX.js +89 -0
  70. package/viewer-dist/assets/katex-pVJiI_rc.js +257 -0
  71. package/viewer-dist/assets/line-CSkXZgM5.js +1 -0
  72. package/viewer-dist/assets/linear-C69MUSpN.js +1 -0
  73. package/viewer-dist/assets/mermaid-parser.core-BxtmlK9F.js +4 -0
  74. package/viewer-dist/assets/mindmap-definition-RKZ34NQL-CJfLUd4u.js +96 -0
  75. package/viewer-dist/assets/ordinal-bHkc4Rpt.js +1 -0
  76. package/viewer-dist/assets/packet-YPE3B663-DmtvbI4l.js +1 -0
  77. package/viewer-dist/assets/path-ZGOlHDxT.js +1 -0
  78. package/viewer-dist/assets/pie-LRSECV5Y-Y82O9nng.js +1 -0
  79. package/viewer-dist/assets/pieDiagram-4H26LBE5-BsHXB8IC.js +30 -0
  80. package/viewer-dist/assets/quadrantDiagram-W4KKPZXB-B3RaddW4.js +7 -0
  81. package/viewer-dist/assets/radar-GUYGQ44K-BHcHsGeF.js +1 -0
  82. package/viewer-dist/assets/requirementDiagram-4Y6WPE33-CanuKYuP.js +84 -0
  83. package/viewer-dist/assets/rough.esm-C6nrIGLg.js +1 -0
  84. package/viewer-dist/assets/sankeyDiagram-5OEKKPKP-B92qVA_9.js +40 -0
  85. package/viewer-dist/assets/sequenceDiagram-3UESZ5HK-IBhScJkH.js +162 -0
  86. package/viewer-dist/assets/src--c83fjKW.js +1 -0
  87. package/viewer-dist/assets/stateDiagram-AJRCARHV-D9ORfcYk.js +1 -0
  88. package/viewer-dist/assets/stateDiagram-v2-BHNVJYJU-CCmjUx_g.js +1 -0
  89. package/viewer-dist/assets/timeline-definition-PNZ67QCA-D4afYQ3m.js +120 -0
  90. package/viewer-dist/assets/treeView-BLDUP644-Cmu4mPLp.js +1 -0
  91. package/viewer-dist/assets/treemap-LRROVOQU-_N62KlUg.js +1 -0
  92. package/viewer-dist/assets/vennDiagram-CIIHVFJN-DjSaUOWp.js +34 -0
  93. package/viewer-dist/assets/wardley-L42UT6IY-DWSXD3L4.js +1 -0
  94. package/viewer-dist/assets/wardleyDiagram-YWT4CUSO-CBn2PjeZ.js +78 -0
  95. package/viewer-dist/assets/xychartDiagram-2RQKCTM6-CAAAsGIb.js +7 -0
  96. package/viewer-dist/index.html +22 -0
@@ -0,0 +1,159 @@
1
+ var e=Object.create,t=Object.defineProperty,n=Object.getOwnPropertyDescriptor,r=Object.getOwnPropertyNames,i=Object.getPrototypeOf,a=Object.prototype.hasOwnProperty,o=(e,n)=>t(e,`name`,{value:n,configurable:!0}),s=(e,t)=>function(){return e&&(t=(0,e[r(e)[0]])(e=0)),t},c=(e,t)=>function(){return t||(0,e[r(e)[0]])((t={exports:{}}).exports,t),t.exports},l=(e,n)=>{for(var r in n)t(e,r,{get:n[r],enumerable:!0})},u=(e,i,o,s)=>{if(i&&typeof i==`object`||typeof i==`function`)for(let c of r(i))!a.call(e,c)&&c!==o&&t(e,c,{get:()=>i[c],enumerable:!(s=n(i,c))||s.enumerable});return e},d=(e,t,n)=>(u(e,t,`default`),n&&u(n,t,`default`)),f=(n,r,a)=>(a=n==null?{}:e(i(n)),u(r||!n||!n.__esModule?t(a,`default`,{value:n,enumerable:!0}):a,n)),p=e=>u(t({},`__esModule`,{value:!0}),e),m={};l(m,{AnnotatedTextEdit:()=>T,ChangeAnnotation:()=>de,ChangeAnnotationIdentifier:()=>w,CodeAction:()=>Ge,CodeActionContext:()=>We,CodeActionKind:()=>He,CodeActionTriggerKind:()=>Ue,CodeDescription:()=>se,CodeLens:()=>Ke,Color:()=>S,ColorInformation:()=>te,ColorPresentation:()=>ne,Command:()=>le,CompletionItem:()=>ke,CompletionItemKind:()=>Ce,CompletionItemLabelDetails:()=>Oe,CompletionItemTag:()=>Te,CompletionList:()=>Ae,CreateFile:()=>E,DeleteFile:()=>pe,Diagnostic:()=>ce,DiagnosticRelatedInformation:()=>ie,DiagnosticSeverity:()=>ae,DiagnosticTag:()=>oe,DocumentHighlight:()=>Ie,DocumentHighlightKind:()=>Fe,DocumentLink:()=>Je,DocumentSymbol:()=>Ve,DocumentUri:()=>h,EOL:()=>pt,FoldingRange:()=>re,FoldingRangeKind:()=>C,FormattingOptions:()=>qe,Hover:()=>Me,InlayHint:()=>at,InlayHintKind:()=>rt,InlayHintLabelPart:()=>it,InlineCompletionContext:()=>dt,InlineCompletionItem:()=>st,InlineCompletionList:()=>ct,InlineCompletionTriggerKind:()=>lt,InlineValueContext:()=>nt,InlineValueEvaluatableExpression:()=>tt,InlineValueText:()=>$e,InlineValueVariableLookup:()=>et,InsertReplaceEdit:()=>Ee,InsertTextFormat:()=>we,InsertTextMode:()=>De,Location:()=>x,LocationLink:()=>ee,MarkedString:()=>je,MarkupContent:()=>Se,MarkupKind:()=>xe,OptionalVersionedTextDocumentIdentifier:()=>ye,ParameterInformation:()=>Ne,Position:()=>y,Range:()=>b,RenameFile:()=>D,SelectedCompletionInfo:()=>ut,SelectionRange:()=>Ye,SemanticTokenModifiers:()=>Ze,SemanticTokenTypes:()=>Xe,SemanticTokens:()=>Qe,SignatureInformation:()=>Pe,StringValue:()=>ot,SymbolInformation:()=>ze,SymbolKind:()=>Le,SymbolTag:()=>Re,TextDocument:()=>mt,TextDocumentEdit:()=>fe,TextDocumentIdentifier:()=>_e,TextDocumentItem:()=>be,TextEdit:()=>ue,URI:()=>g,VersionedTextDocumentIdentifier:()=>ve,WorkspaceChange:()=>ge,WorkspaceEdit:()=>O,WorkspaceFolder:()=>ft,WorkspaceSymbol:()=>Be,integer:()=>_,uinteger:()=>v});var h,g,_,v,y,b,x,ee,S,te,ne,C,re,ie,ae,oe,se,ce,le,ue,de,w,T,fe,E,D,pe,O,me,he,ge,_e,ve,ye,be,xe,Se,Ce,we,Te,Ee,De,Oe,ke,Ae,je,Me,Ne,Pe,Fe,Ie,Le,Re,ze,Be,Ve,He,Ue,We,Ge,Ke,qe,Je,Ye,Xe,Ze,Qe,$e,et,tt,nt,rt,it,at,ot,st,ct,lt,ut,dt,ft,pt,mt,ht,k,gt=s({"../../node_modules/.pnpm/vscode-languageserver-types@3.17.5/node_modules/vscode-languageserver-types/lib/esm/main.js"(){(function(e){function t(e){return typeof e==`string`}o(t,`is`),e.is=t})(h||={}),(function(e){function t(e){return typeof e==`string`}o(t,`is`),e.is=t})(g||={}),(function(e){e.MIN_VALUE=-2147483648,e.MAX_VALUE=2147483647;function t(t){return typeof t==`number`&&e.MIN_VALUE<=t&&t<=e.MAX_VALUE}o(t,`is`),e.is=t})(_||={}),(function(e){e.MIN_VALUE=0,e.MAX_VALUE=2147483647;function t(t){return typeof t==`number`&&e.MIN_VALUE<=t&&t<=e.MAX_VALUE}o(t,`is`),e.is=t})(v||={}),(function(e){function t(e,t){return e===Number.MAX_VALUE&&(e=v.MAX_VALUE),t===Number.MAX_VALUE&&(t=v.MAX_VALUE),{line:e,character:t}}o(t,`create`),e.create=t;function n(e){let t=e;return k.objectLiteral(t)&&k.uinteger(t.line)&&k.uinteger(t.character)}o(n,`is`),e.is=n})(y||={}),(function(e){function t(e,t,n,r){if(k.uinteger(e)&&k.uinteger(t)&&k.uinteger(n)&&k.uinteger(r))return{start:y.create(e,t),end:y.create(n,r)};if(y.is(e)&&y.is(t))return{start:e,end:t};throw Error(`Range#create called with invalid arguments[${e}, ${t}, ${n}, ${r}]`)}o(t,`create`),e.create=t;function n(e){let t=e;return k.objectLiteral(t)&&y.is(t.start)&&y.is(t.end)}o(n,`is`),e.is=n})(b||={}),(function(e){function t(e,t){return{uri:e,range:t}}o(t,`create`),e.create=t;function n(e){let t=e;return k.objectLiteral(t)&&b.is(t.range)&&(k.string(t.uri)||k.undefined(t.uri))}o(n,`is`),e.is=n})(x||={}),(function(e){function t(e,t,n,r){return{targetUri:e,targetRange:t,targetSelectionRange:n,originSelectionRange:r}}o(t,`create`),e.create=t;function n(e){let t=e;return k.objectLiteral(t)&&b.is(t.targetRange)&&k.string(t.targetUri)&&b.is(t.targetSelectionRange)&&(b.is(t.originSelectionRange)||k.undefined(t.originSelectionRange))}o(n,`is`),e.is=n})(ee||={}),(function(e){function t(e,t,n,r){return{red:e,green:t,blue:n,alpha:r}}o(t,`create`),e.create=t;function n(e){let t=e;return k.objectLiteral(t)&&k.numberRange(t.red,0,1)&&k.numberRange(t.green,0,1)&&k.numberRange(t.blue,0,1)&&k.numberRange(t.alpha,0,1)}o(n,`is`),e.is=n})(S||={}),(function(e){function t(e,t){return{range:e,color:t}}o(t,`create`),e.create=t;function n(e){let t=e;return k.objectLiteral(t)&&b.is(t.range)&&S.is(t.color)}o(n,`is`),e.is=n})(te||={}),(function(e){function t(e,t,n){return{label:e,textEdit:t,additionalTextEdits:n}}o(t,`create`),e.create=t;function n(e){let t=e;return k.objectLiteral(t)&&k.string(t.label)&&(k.undefined(t.textEdit)||ue.is(t))&&(k.undefined(t.additionalTextEdits)||k.typedArray(t.additionalTextEdits,ue.is))}o(n,`is`),e.is=n})(ne||={}),(function(e){e.Comment=`comment`,e.Imports=`imports`,e.Region=`region`})(C||={}),(function(e){function t(e,t,n,r,i,a){let o={startLine:e,endLine:t};return k.defined(n)&&(o.startCharacter=n),k.defined(r)&&(o.endCharacter=r),k.defined(i)&&(o.kind=i),k.defined(a)&&(o.collapsedText=a),o}o(t,`create`),e.create=t;function n(e){let t=e;return k.objectLiteral(t)&&k.uinteger(t.startLine)&&k.uinteger(t.startLine)&&(k.undefined(t.startCharacter)||k.uinteger(t.startCharacter))&&(k.undefined(t.endCharacter)||k.uinteger(t.endCharacter))&&(k.undefined(t.kind)||k.string(t.kind))}o(n,`is`),e.is=n})(re||={}),(function(e){function t(e,t){return{location:e,message:t}}o(t,`create`),e.create=t;function n(e){let t=e;return k.defined(t)&&x.is(t.location)&&k.string(t.message)}o(n,`is`),e.is=n})(ie||={}),(function(e){e.Error=1,e.Warning=2,e.Information=3,e.Hint=4})(ae||={}),(function(e){e.Unnecessary=1,e.Deprecated=2})(oe||={}),(function(e){function t(e){let t=e;return k.objectLiteral(t)&&k.string(t.href)}o(t,`is`),e.is=t})(se||={}),(function(e){function t(e,t,n,r,i,a){let o={range:e,message:t};return k.defined(n)&&(o.severity=n),k.defined(r)&&(o.code=r),k.defined(i)&&(o.source=i),k.defined(a)&&(o.relatedInformation=a),o}o(t,`create`),e.create=t;function n(e){let t=e;return k.defined(t)&&b.is(t.range)&&k.string(t.message)&&(k.number(t.severity)||k.undefined(t.severity))&&(k.integer(t.code)||k.string(t.code)||k.undefined(t.code))&&(k.undefined(t.codeDescription)||k.string(t.codeDescription?.href))&&(k.string(t.source)||k.undefined(t.source))&&(k.undefined(t.relatedInformation)||k.typedArray(t.relatedInformation,ie.is))}o(n,`is`),e.is=n})(ce||={}),(function(e){function t(e,t,...n){let r={title:e,command:t};return k.defined(n)&&n.length>0&&(r.arguments=n),r}o(t,`create`),e.create=t;function n(e){let t=e;return k.defined(t)&&k.string(t.title)&&k.string(t.command)}o(n,`is`),e.is=n})(le||={}),(function(e){function t(e,t){return{range:e,newText:t}}o(t,`replace`),e.replace=t;function n(e,t){return{range:{start:e,end:e},newText:t}}o(n,`insert`),e.insert=n;function r(e){return{range:e,newText:``}}o(r,`del`),e.del=r;function i(e){let t=e;return k.objectLiteral(t)&&k.string(t.newText)&&b.is(t.range)}o(i,`is`),e.is=i})(ue||={}),(function(e){function t(e,t,n){let r={label:e};return t!==void 0&&(r.needsConfirmation=t),n!==void 0&&(r.description=n),r}o(t,`create`),e.create=t;function n(e){let t=e;return k.objectLiteral(t)&&k.string(t.label)&&(k.boolean(t.needsConfirmation)||t.needsConfirmation===void 0)&&(k.string(t.description)||t.description===void 0)}o(n,`is`),e.is=n})(de||={}),(function(e){function t(e){let t=e;return k.string(t)}o(t,`is`),e.is=t})(w||={}),(function(e){function t(e,t,n){return{range:e,newText:t,annotationId:n}}o(t,`replace`),e.replace=t;function n(e,t,n){return{range:{start:e,end:e},newText:t,annotationId:n}}o(n,`insert`),e.insert=n;function r(e,t){return{range:e,newText:``,annotationId:t}}o(r,`del`),e.del=r;function i(e){let t=e;return ue.is(t)&&(de.is(t.annotationId)||w.is(t.annotationId))}o(i,`is`),e.is=i})(T||={}),(function(e){function t(e,t){return{textDocument:e,edits:t}}o(t,`create`),e.create=t;function n(e){let t=e;return k.defined(t)&&ye.is(t.textDocument)&&Array.isArray(t.edits)}o(n,`is`),e.is=n})(fe||={}),(function(e){function t(e,t,n){let r={kind:`create`,uri:e};return t!==void 0&&(t.overwrite!==void 0||t.ignoreIfExists!==void 0)&&(r.options=t),n!==void 0&&(r.annotationId=n),r}o(t,`create`),e.create=t;function n(e){let t=e;return t&&t.kind===`create`&&k.string(t.uri)&&(t.options===void 0||(t.options.overwrite===void 0||k.boolean(t.options.overwrite))&&(t.options.ignoreIfExists===void 0||k.boolean(t.options.ignoreIfExists)))&&(t.annotationId===void 0||w.is(t.annotationId))}o(n,`is`),e.is=n})(E||={}),(function(e){function t(e,t,n,r){let i={kind:`rename`,oldUri:e,newUri:t};return n!==void 0&&(n.overwrite!==void 0||n.ignoreIfExists!==void 0)&&(i.options=n),r!==void 0&&(i.annotationId=r),i}o(t,`create`),e.create=t;function n(e){let t=e;return t&&t.kind===`rename`&&k.string(t.oldUri)&&k.string(t.newUri)&&(t.options===void 0||(t.options.overwrite===void 0||k.boolean(t.options.overwrite))&&(t.options.ignoreIfExists===void 0||k.boolean(t.options.ignoreIfExists)))&&(t.annotationId===void 0||w.is(t.annotationId))}o(n,`is`),e.is=n})(D||={}),(function(e){function t(e,t,n){let r={kind:`delete`,uri:e};return t!==void 0&&(t.recursive!==void 0||t.ignoreIfNotExists!==void 0)&&(r.options=t),n!==void 0&&(r.annotationId=n),r}o(t,`create`),e.create=t;function n(e){let t=e;return t&&t.kind===`delete`&&k.string(t.uri)&&(t.options===void 0||(t.options.recursive===void 0||k.boolean(t.options.recursive))&&(t.options.ignoreIfNotExists===void 0||k.boolean(t.options.ignoreIfNotExists)))&&(t.annotationId===void 0||w.is(t.annotationId))}o(n,`is`),e.is=n})(pe||={}),(function(e){function t(e){let t=e;return t&&(t.changes!==void 0||t.documentChanges!==void 0)&&(t.documentChanges===void 0||t.documentChanges.every(e=>k.string(e.kind)?E.is(e)||D.is(e)||pe.is(e):fe.is(e)))}o(t,`is`),e.is=t})(O||={}),me=class{static{o(this,`TextEditChangeImpl`)}constructor(e,t){this.edits=e,this.changeAnnotations=t}insert(e,t,n){let r,i;if(n===void 0?r=ue.insert(e,t):w.is(n)?(i=n,r=T.insert(e,t,n)):(this.assertChangeAnnotations(this.changeAnnotations),i=this.changeAnnotations.manage(n),r=T.insert(e,t,i)),this.edits.push(r),i!==void 0)return i}replace(e,t,n){let r,i;if(n===void 0?r=ue.replace(e,t):w.is(n)?(i=n,r=T.replace(e,t,n)):(this.assertChangeAnnotations(this.changeAnnotations),i=this.changeAnnotations.manage(n),r=T.replace(e,t,i)),this.edits.push(r),i!==void 0)return i}delete(e,t){let n,r;if(t===void 0?n=ue.del(e):w.is(t)?(r=t,n=T.del(e,t)):(this.assertChangeAnnotations(this.changeAnnotations),r=this.changeAnnotations.manage(t),n=T.del(e,r)),this.edits.push(n),r!==void 0)return r}add(e){this.edits.push(e)}all(){return this.edits}clear(){this.edits.splice(0,this.edits.length)}assertChangeAnnotations(e){if(e===void 0)throw Error(`Text edit change is not configured to manage change annotations.`)}},he=class{static{o(this,`ChangeAnnotations`)}constructor(e){this._annotations=e===void 0?Object.create(null):e,this._counter=0,this._size=0}all(){return this._annotations}get size(){return this._size}manage(e,t){let n;if(w.is(e)?n=e:(n=this.nextId(),t=e),this._annotations[n]!==void 0)throw Error(`Id ${n} is already in use.`);if(t===void 0)throw Error(`No annotation provided for id ${n}`);return this._annotations[n]=t,this._size++,n}nextId(){return this._counter++,this._counter.toString()}},ge=class{static{o(this,`WorkspaceChange`)}constructor(e){this._textEditChanges=Object.create(null),e===void 0?this._workspaceEdit={}:(this._workspaceEdit=e,e.documentChanges?(this._changeAnnotations=new he(e.changeAnnotations),e.changeAnnotations=this._changeAnnotations.all(),e.documentChanges.forEach(e=>{if(fe.is(e)){let t=new me(e.edits,this._changeAnnotations);this._textEditChanges[e.textDocument.uri]=t}})):e.changes&&Object.keys(e.changes).forEach(t=>{let n=new me(e.changes[t]);this._textEditChanges[t]=n}))}get edit(){return this.initDocumentChanges(),this._changeAnnotations!==void 0&&(this._changeAnnotations.size===0?this._workspaceEdit.changeAnnotations=void 0:this._workspaceEdit.changeAnnotations=this._changeAnnotations.all()),this._workspaceEdit}getTextEditChange(e){if(ye.is(e)){if(this.initDocumentChanges(),this._workspaceEdit.documentChanges===void 0)throw Error(`Workspace edit is not configured for document changes.`);let t={uri:e.uri,version:e.version},n=this._textEditChanges[t.uri];if(!n){let e=[],r={textDocument:t,edits:e};this._workspaceEdit.documentChanges.push(r),n=new me(e,this._changeAnnotations),this._textEditChanges[t.uri]=n}return n}else{if(this.initChanges(),this._workspaceEdit.changes===void 0)throw Error(`Workspace edit is not configured for normal text edit changes.`);let t=this._textEditChanges[e];if(!t){let n=[];this._workspaceEdit.changes[e]=n,t=new me(n),this._textEditChanges[e]=t}return t}}initDocumentChanges(){this._workspaceEdit.documentChanges===void 0&&this._workspaceEdit.changes===void 0&&(this._changeAnnotations=new he,this._workspaceEdit.documentChanges=[],this._workspaceEdit.changeAnnotations=this._changeAnnotations.all())}initChanges(){this._workspaceEdit.documentChanges===void 0&&this._workspaceEdit.changes===void 0&&(this._workspaceEdit.changes=Object.create(null))}createFile(e,t,n){if(this.initDocumentChanges(),this._workspaceEdit.documentChanges===void 0)throw Error(`Workspace edit is not configured for document changes.`);let r;de.is(t)||w.is(t)?r=t:n=t;let i,a;if(r===void 0?i=E.create(e,n):(a=w.is(r)?r:this._changeAnnotations.manage(r),i=E.create(e,n,a)),this._workspaceEdit.documentChanges.push(i),a!==void 0)return a}renameFile(e,t,n,r){if(this.initDocumentChanges(),this._workspaceEdit.documentChanges===void 0)throw Error(`Workspace edit is not configured for document changes.`);let i;de.is(n)||w.is(n)?i=n:r=n;let a,o;if(i===void 0?a=D.create(e,t,r):(o=w.is(i)?i:this._changeAnnotations.manage(i),a=D.create(e,t,r,o)),this._workspaceEdit.documentChanges.push(a),o!==void 0)return o}deleteFile(e,t,n){if(this.initDocumentChanges(),this._workspaceEdit.documentChanges===void 0)throw Error(`Workspace edit is not configured for document changes.`);let r;de.is(t)||w.is(t)?r=t:n=t;let i,a;if(r===void 0?i=pe.create(e,n):(a=w.is(r)?r:this._changeAnnotations.manage(r),i=pe.create(e,n,a)),this._workspaceEdit.documentChanges.push(i),a!==void 0)return a}},(function(e){function t(e){return{uri:e}}o(t,`create`),e.create=t;function n(e){let t=e;return k.defined(t)&&k.string(t.uri)}o(n,`is`),e.is=n})(_e||={}),(function(e){function t(e,t){return{uri:e,version:t}}o(t,`create`),e.create=t;function n(e){let t=e;return k.defined(t)&&k.string(t.uri)&&k.integer(t.version)}o(n,`is`),e.is=n})(ve||={}),(function(e){function t(e,t){return{uri:e,version:t}}o(t,`create`),e.create=t;function n(e){let t=e;return k.defined(t)&&k.string(t.uri)&&(t.version===null||k.integer(t.version))}o(n,`is`),e.is=n})(ye||={}),(function(e){function t(e,t,n,r){return{uri:e,languageId:t,version:n,text:r}}o(t,`create`),e.create=t;function n(e){let t=e;return k.defined(t)&&k.string(t.uri)&&k.string(t.languageId)&&k.integer(t.version)&&k.string(t.text)}o(n,`is`),e.is=n})(be||={}),(function(e){e.PlainText=`plaintext`,e.Markdown=`markdown`;function t(t){let n=t;return n===e.PlainText||n===e.Markdown}o(t,`is`),e.is=t})(xe||={}),(function(e){function t(e){let t=e;return k.objectLiteral(e)&&xe.is(t.kind)&&k.string(t.value)}o(t,`is`),e.is=t})(Se||={}),(function(e){e.Text=1,e.Method=2,e.Function=3,e.Constructor=4,e.Field=5,e.Variable=6,e.Class=7,e.Interface=8,e.Module=9,e.Property=10,e.Unit=11,e.Value=12,e.Enum=13,e.Keyword=14,e.Snippet=15,e.Color=16,e.File=17,e.Reference=18,e.Folder=19,e.EnumMember=20,e.Constant=21,e.Struct=22,e.Event=23,e.Operator=24,e.TypeParameter=25})(Ce||={}),(function(e){e.PlainText=1,e.Snippet=2})(we||={}),(function(e){e.Deprecated=1})(Te||={}),(function(e){function t(e,t,n){return{newText:e,insert:t,replace:n}}o(t,`create`),e.create=t;function n(e){let t=e;return t&&k.string(t.newText)&&b.is(t.insert)&&b.is(t.replace)}o(n,`is`),e.is=n})(Ee||={}),(function(e){e.asIs=1,e.adjustIndentation=2})(De||={}),(function(e){function t(e){let t=e;return t&&(k.string(t.detail)||t.detail===void 0)&&(k.string(t.description)||t.description===void 0)}o(t,`is`),e.is=t})(Oe||={}),(function(e){function t(e){return{label:e}}o(t,`create`),e.create=t})(ke||={}),(function(e){function t(e,t){return{items:e||[],isIncomplete:!!t}}o(t,`create`),e.create=t})(Ae||={}),(function(e){function t(e){return e.replace(/[\\`*_{}[\]()#+\-.!]/g,`\\$&`)}o(t,`fromPlainText`),e.fromPlainText=t;function n(e){let t=e;return k.string(t)||k.objectLiteral(t)&&k.string(t.language)&&k.string(t.value)}o(n,`is`),e.is=n})(je||={}),(function(e){function t(e){let t=e;return!!t&&k.objectLiteral(t)&&(Se.is(t.contents)||je.is(t.contents)||k.typedArray(t.contents,je.is))&&(e.range===void 0||b.is(e.range))}o(t,`is`),e.is=t})(Me||={}),(function(e){function t(e,t){return t?{label:e,documentation:t}:{label:e}}o(t,`create`),e.create=t})(Ne||={}),(function(e){function t(e,t,...n){let r={label:e};return k.defined(t)&&(r.documentation=t),k.defined(n)?r.parameters=n:r.parameters=[],r}o(t,`create`),e.create=t})(Pe||={}),(function(e){e.Text=1,e.Read=2,e.Write=3})(Fe||={}),(function(e){function t(e,t){let n={range:e};return k.number(t)&&(n.kind=t),n}o(t,`create`),e.create=t})(Ie||={}),(function(e){e.File=1,e.Module=2,e.Namespace=3,e.Package=4,e.Class=5,e.Method=6,e.Property=7,e.Field=8,e.Constructor=9,e.Enum=10,e.Interface=11,e.Function=12,e.Variable=13,e.Constant=14,e.String=15,e.Number=16,e.Boolean=17,e.Array=18,e.Object=19,e.Key=20,e.Null=21,e.EnumMember=22,e.Struct=23,e.Event=24,e.Operator=25,e.TypeParameter=26})(Le||={}),(function(e){e.Deprecated=1})(Re||={}),(function(e){function t(e,t,n,r,i){let a={name:e,kind:t,location:{uri:r,range:n}};return i&&(a.containerName=i),a}o(t,`create`),e.create=t})(ze||={}),(function(e){function t(e,t,n,r){return r===void 0?{name:e,kind:t,location:{uri:n}}:{name:e,kind:t,location:{uri:n,range:r}}}o(t,`create`),e.create=t})(Be||={}),(function(e){function t(e,t,n,r,i,a){let o={name:e,detail:t,kind:n,range:r,selectionRange:i};return a!==void 0&&(o.children=a),o}o(t,`create`),e.create=t;function n(e){let t=e;return t&&k.string(t.name)&&k.number(t.kind)&&b.is(t.range)&&b.is(t.selectionRange)&&(t.detail===void 0||k.string(t.detail))&&(t.deprecated===void 0||k.boolean(t.deprecated))&&(t.children===void 0||Array.isArray(t.children))&&(t.tags===void 0||Array.isArray(t.tags))}o(n,`is`),e.is=n})(Ve||={}),(function(e){e.Empty=``,e.QuickFix=`quickfix`,e.Refactor=`refactor`,e.RefactorExtract=`refactor.extract`,e.RefactorInline=`refactor.inline`,e.RefactorRewrite=`refactor.rewrite`,e.Source=`source`,e.SourceOrganizeImports=`source.organizeImports`,e.SourceFixAll=`source.fixAll`})(He||={}),(function(e){e.Invoked=1,e.Automatic=2})(Ue||={}),(function(e){function t(e,t,n){let r={diagnostics:e};return t!=null&&(r.only=t),n!=null&&(r.triggerKind=n),r}o(t,`create`),e.create=t;function n(e){let t=e;return k.defined(t)&&k.typedArray(t.diagnostics,ce.is)&&(t.only===void 0||k.typedArray(t.only,k.string))&&(t.triggerKind===void 0||t.triggerKind===Ue.Invoked||t.triggerKind===Ue.Automatic)}o(n,`is`),e.is=n})(We||={}),(function(e){function t(e,t,n){let r={title:e},i=!0;return typeof t==`string`?(i=!1,r.kind=t):le.is(t)?r.command=t:r.edit=t,i&&n!==void 0&&(r.kind=n),r}o(t,`create`),e.create=t;function n(e){let t=e;return t&&k.string(t.title)&&(t.diagnostics===void 0||k.typedArray(t.diagnostics,ce.is))&&(t.kind===void 0||k.string(t.kind))&&(t.edit!==void 0||t.command!==void 0)&&(t.command===void 0||le.is(t.command))&&(t.isPreferred===void 0||k.boolean(t.isPreferred))&&(t.edit===void 0||O.is(t.edit))}o(n,`is`),e.is=n})(Ge||={}),(function(e){function t(e,t){let n={range:e};return k.defined(t)&&(n.data=t),n}o(t,`create`),e.create=t;function n(e){let t=e;return k.defined(t)&&b.is(t.range)&&(k.undefined(t.command)||le.is(t.command))}o(n,`is`),e.is=n})(Ke||={}),(function(e){function t(e,t){return{tabSize:e,insertSpaces:t}}o(t,`create`),e.create=t;function n(e){let t=e;return k.defined(t)&&k.uinteger(t.tabSize)&&k.boolean(t.insertSpaces)}o(n,`is`),e.is=n})(qe||={}),(function(e){function t(e,t,n){return{range:e,target:t,data:n}}o(t,`create`),e.create=t;function n(e){let t=e;return k.defined(t)&&b.is(t.range)&&(k.undefined(t.target)||k.string(t.target))}o(n,`is`),e.is=n})(Je||={}),(function(e){function t(e,t){return{range:e,parent:t}}o(t,`create`),e.create=t;function n(t){let n=t;return k.objectLiteral(n)&&b.is(n.range)&&(n.parent===void 0||e.is(n.parent))}o(n,`is`),e.is=n})(Ye||={}),(function(e){e.namespace=`namespace`,e.type=`type`,e.class=`class`,e.enum=`enum`,e.interface=`interface`,e.struct=`struct`,e.typeParameter=`typeParameter`,e.parameter=`parameter`,e.variable=`variable`,e.property=`property`,e.enumMember=`enumMember`,e.event=`event`,e.function=`function`,e.method=`method`,e.macro=`macro`,e.keyword=`keyword`,e.modifier=`modifier`,e.comment=`comment`,e.string=`string`,e.number=`number`,e.regexp=`regexp`,e.operator=`operator`,e.decorator=`decorator`})(Xe||={}),(function(e){e.declaration=`declaration`,e.definition=`definition`,e.readonly=`readonly`,e.static=`static`,e.deprecated=`deprecated`,e.abstract=`abstract`,e.async=`async`,e.modification=`modification`,e.documentation=`documentation`,e.defaultLibrary=`defaultLibrary`})(Ze||={}),(function(e){function t(e){let t=e;return k.objectLiteral(t)&&(t.resultId===void 0||typeof t.resultId==`string`)&&Array.isArray(t.data)&&(t.data.length===0||typeof t.data[0]==`number`)}o(t,`is`),e.is=t})(Qe||={}),(function(e){function t(e,t){return{range:e,text:t}}o(t,`create`),e.create=t;function n(e){let t=e;return t!=null&&b.is(t.range)&&k.string(t.text)}o(n,`is`),e.is=n})($e||={}),(function(e){function t(e,t,n){return{range:e,variableName:t,caseSensitiveLookup:n}}o(t,`create`),e.create=t;function n(e){let t=e;return t!=null&&b.is(t.range)&&k.boolean(t.caseSensitiveLookup)&&(k.string(t.variableName)||t.variableName===void 0)}o(n,`is`),e.is=n})(et||={}),(function(e){function t(e,t){return{range:e,expression:t}}o(t,`create`),e.create=t;function n(e){let t=e;return t!=null&&b.is(t.range)&&(k.string(t.expression)||t.expression===void 0)}o(n,`is`),e.is=n})(tt||={}),(function(e){function t(e,t){return{frameId:e,stoppedLocation:t}}o(t,`create`),e.create=t;function n(e){let t=e;return k.defined(t)&&b.is(e.stoppedLocation)}o(n,`is`),e.is=n})(nt||={}),(function(e){e.Type=1,e.Parameter=2;function t(e){return e===1||e===2}o(t,`is`),e.is=t})(rt||={}),(function(e){function t(e){return{value:e}}o(t,`create`),e.create=t;function n(e){let t=e;return k.objectLiteral(t)&&(t.tooltip===void 0||k.string(t.tooltip)||Se.is(t.tooltip))&&(t.location===void 0||x.is(t.location))&&(t.command===void 0||le.is(t.command))}o(n,`is`),e.is=n})(it||={}),(function(e){function t(e,t,n){let r={position:e,label:t};return n!==void 0&&(r.kind=n),r}o(t,`create`),e.create=t;function n(e){let t=e;return k.objectLiteral(t)&&y.is(t.position)&&(k.string(t.label)||k.typedArray(t.label,it.is))&&(t.kind===void 0||rt.is(t.kind))&&t.textEdits===void 0||k.typedArray(t.textEdits,ue.is)&&(t.tooltip===void 0||k.string(t.tooltip)||Se.is(t.tooltip))&&(t.paddingLeft===void 0||k.boolean(t.paddingLeft))&&(t.paddingRight===void 0||k.boolean(t.paddingRight))}o(n,`is`),e.is=n})(at||={}),(function(e){function t(e){return{kind:`snippet`,value:e}}o(t,`createSnippet`),e.createSnippet=t})(ot||={}),(function(e){function t(e,t,n,r){return{insertText:e,filterText:t,range:n,command:r}}o(t,`create`),e.create=t})(st||={}),(function(e){function t(e){return{items:e}}o(t,`create`),e.create=t})(ct||={}),(function(e){e.Invoked=0,e.Automatic=1})(lt||={}),(function(e){function t(e,t){return{range:e,text:t}}o(t,`create`),e.create=t})(ut||={}),(function(e){function t(e,t){return{triggerKind:e,selectedCompletionInfo:t}}o(t,`create`),e.create=t})(dt||={}),(function(e){function t(e){let t=e;return k.objectLiteral(t)&&g.is(t.uri)&&k.string(t.name)}o(t,`is`),e.is=t})(ft||={}),pt=[`
2
+ `,`\r
3
+ `,`\r`],(function(e){function t(e,t,n,r){return new ht(e,t,n,r)}o(t,`create`),e.create=t;function n(e){let t=e;return!!(k.defined(t)&&k.string(t.uri)&&(k.undefined(t.languageId)||k.string(t.languageId))&&k.uinteger(t.lineCount)&&k.func(t.getText)&&k.func(t.positionAt)&&k.func(t.offsetAt))}o(n,`is`),e.is=n;function r(e,t){let n=e.getText(),r=i(t,(e,t)=>{let n=e.range.start.line-t.range.start.line;return n===0?e.range.start.character-t.range.start.character:n}),a=n.length;for(let t=r.length-1;t>=0;t--){let i=r[t],o=e.offsetAt(i.range.start),s=e.offsetAt(i.range.end);if(s<=a)n=n.substring(0,o)+i.newText+n.substring(s,n.length);else throw Error(`Overlapping edit`);a=o}return n}o(r,`applyEdits`),e.applyEdits=r;function i(e,t){if(e.length<=1)return e;let n=e.length/2|0,r=e.slice(0,n),a=e.slice(n);i(r,t),i(a,t);let o=0,s=0,c=0;for(;o<r.length&&s<a.length;)t(r[o],a[s])<=0?e[c++]=r[o++]:e[c++]=a[s++];for(;o<r.length;)e[c++]=r[o++];for(;s<a.length;)e[c++]=a[s++];return e}o(i,`mergeSort`)})(mt||={}),ht=class{static{o(this,`FullTextDocument`)}constructor(e,t,n,r){this._uri=e,this._languageId=t,this._version=n,this._content=r,this._lineOffsets=void 0}get uri(){return this._uri}get languageId(){return this._languageId}get version(){return this._version}getText(e){if(e){let t=this.offsetAt(e.start),n=this.offsetAt(e.end);return this._content.substring(t,n)}return this._content}update(e,t){this._content=e.text,this._version=t,this._lineOffsets=void 0}getLineOffsets(){if(this._lineOffsets===void 0){let e=[],t=this._content,n=!0;for(let r=0;r<t.length;r++){n&&=(e.push(r),!1);let i=t.charAt(r);n=i===`\r`||i===`
4
+ `,i===`\r`&&r+1<t.length&&t.charAt(r+1)===`
5
+ `&&r++}n&&t.length>0&&e.push(t.length),this._lineOffsets=e}return this._lineOffsets}positionAt(e){e=Math.max(Math.min(e,this._content.length),0);let t=this.getLineOffsets(),n=0,r=t.length;if(r===0)return y.create(0,e);for(;n<r;){let i=Math.floor((n+r)/2);t[i]>e?r=i:n=i+1}let i=n-1;return y.create(i,e-t[i])}offsetAt(e){let t=this.getLineOffsets();if(e.line>=t.length)return this._content.length;if(e.line<0)return 0;let n=t[e.line],r=e.line+1<t.length?t[e.line+1]:this._content.length;return Math.max(Math.min(n+e.character,r),n)}get lineCount(){return this.getLineOffsets().length}},(function(e){let t=Object.prototype.toString;function n(e){return e!==void 0}o(n,`defined`),e.defined=n;function r(e){return e===void 0}o(r,`undefined`),e.undefined=r;function i(e){return e===!0||e===!1}o(i,`boolean`),e.boolean=i;function a(e){return t.call(e)===`[object String]`}o(a,`string`),e.string=a;function s(e){return t.call(e)===`[object Number]`}o(s,`number`),e.number=s;function c(e,n,r){return t.call(e)===`[object Number]`&&n<=e&&e<=r}o(c,`numberRange`),e.numberRange=c;function l(e){return t.call(e)===`[object Number]`&&-2147483648<=e&&e<=2147483647}o(l,`integer`),e.integer=l;function u(e){return t.call(e)===`[object Number]`&&0<=e&&e<=2147483647}o(u,`uinteger`),e.uinteger=u;function d(e){return t.call(e)===`[object Function]`}o(d,`func`),e.func=d;function f(e){return typeof e==`object`&&!!e}o(f,`objectLiteral`),e.objectLiteral=f;function p(e,t){return Array.isArray(e)&&e.every(t)}o(p,`typedArray`),e.typedArray=p})(k||={})}}),_t=c({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/common/ral.js"(e){Object.defineProperty(e,`__esModule`,{value:!0});var t;function n(){if(t===void 0)throw Error(`No runtime abstraction layer installed`);return t}o(n,`RAL`),(function(e){function n(e){if(e===void 0)throw Error(`No runtime abstraction layer provided`);t=e}o(n,`install`),e.install=n})(n||={}),e.default=n}}),vt=c({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/common/is.js"(e){Object.defineProperty(e,`__esModule`,{value:!0}),e.stringArray=e.array=e.func=e.error=e.number=e.string=e.boolean=void 0;function t(e){return e===!0||e===!1}o(t,`boolean`),e.boolean=t;function n(e){return typeof e==`string`||e instanceof String}o(n,`string`),e.string=n;function r(e){return typeof e==`number`||e instanceof Number}o(r,`number`),e.number=r;function i(e){return e instanceof Error}o(i,`error`),e.error=i;function a(e){return typeof e==`function`}o(a,`func`),e.func=a;function s(e){return Array.isArray(e)}o(s,`array`),e.array=s;function c(e){return s(e)&&e.every(e=>n(e))}o(c,`stringArray`),e.stringArray=c}}),yt=c({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/common/events.js"(e){Object.defineProperty(e,`__esModule`,{value:!0}),e.Emitter=e.Event=void 0;var t=_t(),n;(function(e){let t={dispose(){}};e.None=function(){return t}})(n||(e.Event=n={}));var r=class{static{o(this,`CallbackList`)}add(e,t=null,n){this._callbacks||(this._callbacks=[],this._contexts=[]),this._callbacks.push(e),this._contexts.push(t),Array.isArray(n)&&n.push({dispose:o(()=>this.remove(e,t),`dispose`)})}remove(e,t=null){if(!this._callbacks)return;let n=!1;for(let r=0,i=this._callbacks.length;r<i;r++)if(this._callbacks[r]===e)if(this._contexts[r]===t){this._callbacks.splice(r,1),this._contexts.splice(r,1);return}else n=!0;if(n)throw Error(`When adding a listener with a context, you should remove it with the same context`)}invoke(...e){if(!this._callbacks)return[];let n=[],r=this._callbacks.slice(0),i=this._contexts.slice(0);for(let a=0,o=r.length;a<o;a++)try{n.push(r[a].apply(i[a],e))}catch(e){(0,t.default)().console.error(e)}return n}isEmpty(){return!this._callbacks||this._callbacks.length===0}dispose(){this._callbacks=void 0,this._contexts=void 0}},i=class e{static{o(this,`Emitter`)}constructor(e){this._options=e}get event(){return this._event||=(t,n,i)=>{this._callbacks||=new r,this._options&&this._options.onFirstListenerAdd&&this._callbacks.isEmpty()&&this._options.onFirstListenerAdd(this),this._callbacks.add(t,n);let a={dispose:o(()=>{this._callbacks&&(this._callbacks.remove(t,n),a.dispose=e._noop,this._options&&this._options.onLastListenerRemove&&this._callbacks.isEmpty()&&this._options.onLastListenerRemove(this))},`dispose`)};return Array.isArray(i)&&i.push(a),a},this._event}fire(e){this._callbacks&&this._callbacks.invoke.call(this._callbacks,e)}dispose(){this._callbacks&&=(this._callbacks.dispose(),void 0)}};e.Emitter=i,i._noop=function(){}}}),bt=c({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/common/cancellation.js"(e){Object.defineProperty(e,`__esModule`,{value:!0}),e.CancellationTokenSource=e.CancellationToken=void 0;var t=_t(),n=vt(),r=yt(),i;(function(e){e.None=Object.freeze({isCancellationRequested:!1,onCancellationRequested:r.Event.None}),e.Cancelled=Object.freeze({isCancellationRequested:!0,onCancellationRequested:r.Event.None});function t(t){let r=t;return r&&(r===e.None||r===e.Cancelled||n.boolean(r.isCancellationRequested)&&!!r.onCancellationRequested)}o(t,`is`),e.is=t})(i||(e.CancellationToken=i={}));var a=Object.freeze(function(e,n){let r=(0,t.default)().timer.setTimeout(e.bind(n),0);return{dispose(){r.dispose()}}}),s=class{static{o(this,`MutableToken`)}constructor(){this._isCancelled=!1}cancel(){this._isCancelled||(this._isCancelled=!0,this._emitter&&(this._emitter.fire(void 0),this.dispose()))}get isCancellationRequested(){return this._isCancelled}get onCancellationRequested(){return this._isCancelled?a:(this._emitter||=new r.Emitter,this._emitter.event)}dispose(){this._emitter&&=(this._emitter.dispose(),void 0)}};e.CancellationTokenSource=class{static{o(this,`CancellationTokenSource`)}get token(){return this._token||=new s,this._token}cancel(){this._token?this._token.cancel():this._token=i.Cancelled}dispose(){this._token?this._token instanceof s&&this._token.dispose():this._token=i.None}}}}),xt=c({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/common/messages.js"(e){Object.defineProperty(e,`__esModule`,{value:!0}),e.Message=e.NotificationType9=e.NotificationType8=e.NotificationType7=e.NotificationType6=e.NotificationType5=e.NotificationType4=e.NotificationType3=e.NotificationType2=e.NotificationType1=e.NotificationType0=e.NotificationType=e.RequestType9=e.RequestType8=e.RequestType7=e.RequestType6=e.RequestType5=e.RequestType4=e.RequestType3=e.RequestType2=e.RequestType1=e.RequestType=e.RequestType0=e.AbstractMessageSignature=e.ParameterStructures=e.ResponseError=e.ErrorCodes=void 0;var t=vt(),n;(function(e){e.ParseError=-32700,e.InvalidRequest=-32600,e.MethodNotFound=-32601,e.InvalidParams=-32602,e.InternalError=-32603,e.jsonrpcReservedErrorRangeStart=-32099,e.serverErrorStart=-32099,e.MessageWriteError=-32099,e.MessageReadError=-32098,e.PendingResponseRejected=-32097,e.ConnectionInactive=-32096,e.ServerNotInitialized=-32002,e.UnknownErrorCode=-32001,e.jsonrpcReservedErrorRangeEnd=-32e3,e.serverErrorEnd=-32e3})(n||(e.ErrorCodes=n={})),e.ResponseError=class e extends Error{static{o(this,`ResponseError`)}constructor(r,i,a){super(i),this.code=t.number(r)?r:n.UnknownErrorCode,this.data=a,Object.setPrototypeOf(this,e.prototype)}toJson(){let e={code:this.code,message:this.message};return this.data!==void 0&&(e.data=this.data),e}};var r=class e{static{o(this,`ParameterStructures`)}constructor(e){this.kind=e}static is(t){return t===e.auto||t===e.byName||t===e.byPosition}toString(){return this.kind}};e.ParameterStructures=r,r.auto=new r(`auto`),r.byPosition=new r(`byPosition`),r.byName=new r(`byName`);var i=class{static{o(this,`AbstractMessageSignature`)}constructor(e,t){this.method=e,this.numberOfParams=t}get parameterStructures(){return r.auto}};e.AbstractMessageSignature=i,e.RequestType0=class extends i{static{o(this,`RequestType0`)}constructor(e){super(e,0)}},e.RequestType=class extends i{static{o(this,`RequestType`)}constructor(e,t=r.auto){super(e,1),this._parameterStructures=t}get parameterStructures(){return this._parameterStructures}},e.RequestType1=class extends i{static{o(this,`RequestType1`)}constructor(e,t=r.auto){super(e,1),this._parameterStructures=t}get parameterStructures(){return this._parameterStructures}},e.RequestType2=class extends i{static{o(this,`RequestType2`)}constructor(e){super(e,2)}},e.RequestType3=class extends i{static{o(this,`RequestType3`)}constructor(e){super(e,3)}},e.RequestType4=class extends i{static{o(this,`RequestType4`)}constructor(e){super(e,4)}},e.RequestType5=class extends i{static{o(this,`RequestType5`)}constructor(e){super(e,5)}},e.RequestType6=class extends i{static{o(this,`RequestType6`)}constructor(e){super(e,6)}},e.RequestType7=class extends i{static{o(this,`RequestType7`)}constructor(e){super(e,7)}},e.RequestType8=class extends i{static{o(this,`RequestType8`)}constructor(e){super(e,8)}},e.RequestType9=class extends i{static{o(this,`RequestType9`)}constructor(e){super(e,9)}},e.NotificationType=class extends i{static{o(this,`NotificationType`)}constructor(e,t=r.auto){super(e,1),this._parameterStructures=t}get parameterStructures(){return this._parameterStructures}},e.NotificationType0=class extends i{static{o(this,`NotificationType0`)}constructor(e){super(e,0)}},e.NotificationType1=class extends i{static{o(this,`NotificationType1`)}constructor(e,t=r.auto){super(e,1),this._parameterStructures=t}get parameterStructures(){return this._parameterStructures}},e.NotificationType2=class extends i{static{o(this,`NotificationType2`)}constructor(e){super(e,2)}},e.NotificationType3=class extends i{static{o(this,`NotificationType3`)}constructor(e){super(e,3)}},e.NotificationType4=class extends i{static{o(this,`NotificationType4`)}constructor(e){super(e,4)}},e.NotificationType5=class extends i{static{o(this,`NotificationType5`)}constructor(e){super(e,5)}},e.NotificationType6=class extends i{static{o(this,`NotificationType6`)}constructor(e){super(e,6)}},e.NotificationType7=class extends i{static{o(this,`NotificationType7`)}constructor(e){super(e,7)}},e.NotificationType8=class extends i{static{o(this,`NotificationType8`)}constructor(e){super(e,8)}},e.NotificationType9=class extends i{static{o(this,`NotificationType9`)}constructor(e){super(e,9)}};var a;(function(e){function n(e){let n=e;return n&&t.string(n.method)&&(t.string(n.id)||t.number(n.id))}o(n,`isRequest`),e.isRequest=n;function r(e){let n=e;return n&&t.string(n.method)&&e.id===void 0}o(r,`isNotification`),e.isNotification=r;function i(e){let n=e;return n&&(n.result!==void 0||!!n.error)&&(t.string(n.id)||t.number(n.id)||n.id===null)}o(i,`isResponse`),e.isResponse=i})(a||(e.Message=a={}))}}),St=c({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/common/linkedMap.js"(e){var t;Object.defineProperty(e,`__esModule`,{value:!0}),e.LRUCache=e.LinkedMap=e.Touch=void 0;var n;(function(e){e.None=0,e.First=1,e.AsOld=e.First,e.Last=2,e.AsNew=e.Last})(n||(e.Touch=n={}));var r=class{static{o(this,`LinkedMap`)}constructor(){this[t]=`LinkedMap`,this._map=new Map,this._head=void 0,this._tail=void 0,this._size=0,this._state=0}clear(){this._map.clear(),this._head=void 0,this._tail=void 0,this._size=0,this._state++}isEmpty(){return!this._head&&!this._tail}get size(){return this._size}get first(){return this._head?.value}get last(){return this._tail?.value}has(e){return this._map.has(e)}get(e,t=n.None){let r=this._map.get(e);if(r)return t!==n.None&&this.touch(r,t),r.value}set(e,t,r=n.None){let i=this._map.get(e);if(i)i.value=t,r!==n.None&&this.touch(i,r);else{switch(i={key:e,value:t,next:void 0,previous:void 0},r){case n.None:this.addItemLast(i);break;case n.First:this.addItemFirst(i);break;case n.Last:this.addItemLast(i);break;default:this.addItemLast(i);break}this._map.set(e,i),this._size++}return this}delete(e){return!!this.remove(e)}remove(e){let t=this._map.get(e);if(t)return this._map.delete(e),this.removeItem(t),this._size--,t.value}shift(){if(!this._head&&!this._tail)return;if(!this._head||!this._tail)throw Error(`Invalid list`);let e=this._head;return this._map.delete(e.key),this.removeItem(e),this._size--,e.value}forEach(e,t){let n=this._state,r=this._head;for(;r;){if(t?e.bind(t)(r.value,r.key,this):e(r.value,r.key,this),this._state!==n)throw Error(`LinkedMap got modified during iteration.`);r=r.next}}keys(){let e=this._state,t=this._head,n={[Symbol.iterator]:()=>n,next:o(()=>{if(this._state!==e)throw Error(`LinkedMap got modified during iteration.`);if(t){let e={value:t.key,done:!1};return t=t.next,e}else return{value:void 0,done:!0}},`next`)};return n}values(){let e=this._state,t=this._head,n={[Symbol.iterator]:()=>n,next:o(()=>{if(this._state!==e)throw Error(`LinkedMap got modified during iteration.`);if(t){let e={value:t.value,done:!1};return t=t.next,e}else return{value:void 0,done:!0}},`next`)};return n}entries(){let e=this._state,t=this._head,n={[Symbol.iterator]:()=>n,next:o(()=>{if(this._state!==e)throw Error(`LinkedMap got modified during iteration.`);if(t){let e={value:[t.key,t.value],done:!1};return t=t.next,e}else return{value:void 0,done:!0}},`next`)};return n}[(t=Symbol.toStringTag,Symbol.iterator)](){return this.entries()}trimOld(e){if(e>=this.size)return;if(e===0){this.clear();return}let t=this._head,n=this.size;for(;t&&n>e;)this._map.delete(t.key),t=t.next,n--;this._head=t,this._size=n,t&&(t.previous=void 0),this._state++}addItemFirst(e){if(!this._head&&!this._tail)this._tail=e;else if(this._head)e.next=this._head,this._head.previous=e;else throw Error(`Invalid list`);this._head=e,this._state++}addItemLast(e){if(!this._head&&!this._tail)this._head=e;else if(this._tail)e.previous=this._tail,this._tail.next=e;else throw Error(`Invalid list`);this._tail=e,this._state++}removeItem(e){if(e===this._head&&e===this._tail)this._head=void 0,this._tail=void 0;else if(e===this._head){if(!e.next)throw Error(`Invalid list`);e.next.previous=void 0,this._head=e.next}else if(e===this._tail){if(!e.previous)throw Error(`Invalid list`);e.previous.next=void 0,this._tail=e.previous}else{let t=e.next,n=e.previous;if(!t||!n)throw Error(`Invalid list`);t.previous=n,n.next=t}e.next=void 0,e.previous=void 0,this._state++}touch(e,t){if(!this._head||!this._tail)throw Error(`Invalid list`);if(!(t!==n.First&&t!==n.Last)){if(t===n.First){if(e===this._head)return;let t=e.next,n=e.previous;e===this._tail?(n.next=void 0,this._tail=n):(t.previous=n,n.next=t),e.previous=void 0,e.next=this._head,this._head.previous=e,this._head=e,this._state++}else if(t===n.Last){if(e===this._tail)return;let t=e.next,n=e.previous;e===this._head?(t.previous=void 0,this._head=t):(t.previous=n,n.next=t),e.next=void 0,e.previous=this._tail,this._tail.next=e,this._tail=e,this._state++}}}toJSON(){let e=[];return this.forEach((t,n)=>{e.push([n,t])}),e}fromJSON(e){this.clear();for(let[t,n]of e)this.set(t,n)}};e.LinkedMap=r,e.LRUCache=class extends r{static{o(this,`LRUCache`)}constructor(e,t=1){super(),this._limit=e,this._ratio=Math.min(Math.max(0,t),1)}get limit(){return this._limit}set limit(e){this._limit=e,this.checkTrim()}get ratio(){return this._ratio}set ratio(e){this._ratio=Math.min(Math.max(0,e),1),this.checkTrim()}get(e,t=n.AsNew){return super.get(e,t)}peek(e){return super.get(e,n.None)}set(e,t){return super.set(e,t,n.Last),this.checkTrim(),this}checkTrim(){this.size>this._limit&&this.trimOld(Math.round(this._limit*this._ratio))}}}}),Ct=c({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/common/disposable.js"(e){Object.defineProperty(e,`__esModule`,{value:!0}),e.Disposable=void 0;var t;(function(e){function t(e){return{dispose:e}}o(t,`create`),e.create=t})(t||(e.Disposable=t={}))}}),wt=c({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/common/sharedArrayCancellation.js"(e){Object.defineProperty(e,`__esModule`,{value:!0}),e.SharedArrayReceiverStrategy=e.SharedArraySenderStrategy=void 0;var t=bt(),n;(function(e){e.Continue=0,e.Cancelled=1})(n||={}),e.SharedArraySenderStrategy=class{static{o(this,`SharedArraySenderStrategy`)}constructor(){this.buffers=new Map}enableCancellation(e){if(e.id===null)return;let t=new SharedArrayBuffer(4),r=new Int32Array(t,0,1);r[0]=n.Continue,this.buffers.set(e.id,t),e.$cancellationData=t}async sendCancellation(e,t){let r=this.buffers.get(t);if(r===void 0)return;let i=new Int32Array(r,0,1);Atomics.store(i,0,n.Cancelled)}cleanup(e){this.buffers.delete(e)}dispose(){this.buffers.clear()}};var r=class{static{o(this,`SharedArrayBufferCancellationToken`)}constructor(e){this.data=new Int32Array(e,0,1)}get isCancellationRequested(){return Atomics.load(this.data,0)===n.Cancelled}get onCancellationRequested(){throw Error(`Cancellation over SharedArrayBuffer doesn't support cancellation events`)}},i=class{static{o(this,`SharedArrayBufferCancellationTokenSource`)}constructor(e){this.token=new r(e)}cancel(){}dispose(){}};e.SharedArrayReceiverStrategy=class{static{o(this,`SharedArrayReceiverStrategy`)}constructor(){this.kind=`request`}createCancellationTokenSource(e){let n=e.$cancellationData;return n===void 0?new t.CancellationTokenSource:new i(n)}}}}),Tt=c({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/common/semaphore.js"(e){Object.defineProperty(e,`__esModule`,{value:!0}),e.Semaphore=void 0;var t=_t();e.Semaphore=class{static{o(this,`Semaphore`)}constructor(e=1){if(e<=0)throw Error(`Capacity must be greater than 0`);this._capacity=e,this._active=0,this._waiting=[]}lock(e){return new Promise((t,n)=>{this._waiting.push({thunk:e,resolve:t,reject:n}),this.runNext()})}get active(){return this._active}runNext(){this._waiting.length===0||this._active===this._capacity||(0,t.default)().timer.setImmediate(()=>this.doRunNext())}doRunNext(){if(this._waiting.length===0||this._active===this._capacity)return;let e=this._waiting.shift();if(this._active++,this._active>this._capacity)throw Error(`To many thunks active`);try{let t=e.thunk();t instanceof Promise?t.then(t=>{this._active--,e.resolve(t),this.runNext()},t=>{this._active--,e.reject(t),this.runNext()}):(this._active--,e.resolve(t),this.runNext())}catch(t){this._active--,e.reject(t),this.runNext()}}}}}),Et=c({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/common/messageReader.js"(e){Object.defineProperty(e,`__esModule`,{value:!0}),e.ReadableStreamMessageReader=e.AbstractMessageReader=e.MessageReader=void 0;var t=_t(),n=vt(),r=yt(),i=Tt(),a;(function(e){function t(e){let t=e;return t&&n.func(t.listen)&&n.func(t.dispose)&&n.func(t.onError)&&n.func(t.onClose)&&n.func(t.onPartialMessage)}o(t,`is`),e.is=t})(a||(e.MessageReader=a={}));var s=class{static{o(this,`AbstractMessageReader`)}constructor(){this.errorEmitter=new r.Emitter,this.closeEmitter=new r.Emitter,this.partialMessageEmitter=new r.Emitter}dispose(){this.errorEmitter.dispose(),this.closeEmitter.dispose()}get onError(){return this.errorEmitter.event}fireError(e){this.errorEmitter.fire(this.asError(e))}get onClose(){return this.closeEmitter.event}fireClose(){this.closeEmitter.fire(void 0)}get onPartialMessage(){return this.partialMessageEmitter.event}firePartialMessage(e){this.partialMessageEmitter.fire(e)}asError(e){return e instanceof Error?e:Error(`Reader received error. Reason: ${n.string(e.message)?e.message:`unknown`}`)}};e.AbstractMessageReader=s;var c;(function(e){function n(e){let n,r,i=new Map,a,o=new Map;if(e===void 0||typeof e==`string`)n=e??`utf-8`;else{if(n=e.charset??`utf-8`,e.contentDecoder!==void 0&&(r=e.contentDecoder,i.set(r.name,r)),e.contentDecoders!==void 0)for(let t of e.contentDecoders)i.set(t.name,t);if(e.contentTypeDecoder!==void 0&&(a=e.contentTypeDecoder,o.set(a.name,a)),e.contentTypeDecoders!==void 0)for(let t of e.contentTypeDecoders)o.set(t.name,t)}return a===void 0&&(a=(0,t.default)().applicationJson.decoder,o.set(a.name,a)),{charset:n,contentDecoder:r,contentDecoders:i,contentTypeDecoder:a,contentTypeDecoders:o}}o(n,`fromOptions`),e.fromOptions=n})(c||={}),e.ReadableStreamMessageReader=class extends s{static{o(this,`ReadableStreamMessageReader`)}constructor(e,n){super(),this.readable=e,this.options=c.fromOptions(n),this.buffer=(0,t.default)().messageBuffer.create(this.options.charset),this._partialMessageTimeout=1e4,this.nextMessageLength=-1,this.messageToken=0,this.readSemaphore=new i.Semaphore(1)}set partialMessageTimeout(e){this._partialMessageTimeout=e}get partialMessageTimeout(){return this._partialMessageTimeout}listen(e){this.nextMessageLength=-1,this.messageToken=0,this.partialMessageTimer=void 0,this.callback=e;let t=this.readable.onData(e=>{this.onData(e)});return this.readable.onError(e=>this.fireError(e)),this.readable.onClose(()=>this.fireClose()),t}onData(e){try{for(this.buffer.append(e);;){if(this.nextMessageLength===-1){let e=this.buffer.tryReadHeaders(!0);if(!e)return;let t=e.get(`content-length`);if(!t){this.fireError(Error(`Header must provide a Content-Length property.
6
+ ${JSON.stringify(Object.fromEntries(e))}`));return}let n=parseInt(t);if(isNaN(n)){this.fireError(Error(`Content-Length value must be a number. Got ${t}`));return}this.nextMessageLength=n}let e=this.buffer.tryReadBody(this.nextMessageLength);if(e===void 0){this.setPartialMessageTimer();return}this.clearPartialMessageTimer(),this.nextMessageLength=-1,this.readSemaphore.lock(async()=>{let t=this.options.contentDecoder===void 0?e:await this.options.contentDecoder.decode(e),n=await this.options.contentTypeDecoder.decode(t,this.options);this.callback(n)}).catch(e=>{this.fireError(e)})}}catch(e){this.fireError(e)}}clearPartialMessageTimer(){this.partialMessageTimer&&=(this.partialMessageTimer.dispose(),void 0)}setPartialMessageTimer(){this.clearPartialMessageTimer(),!(this._partialMessageTimeout<=0)&&(this.partialMessageTimer=(0,t.default)().timer.setTimeout((e,t)=>{this.partialMessageTimer=void 0,e===this.messageToken&&(this.firePartialMessage({messageToken:e,waitingTime:t}),this.setPartialMessageTimer())},this._partialMessageTimeout,this.messageToken,this._partialMessageTimeout))}}}}),Dt=c({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/common/messageWriter.js"(e){Object.defineProperty(e,`__esModule`,{value:!0}),e.WriteableStreamMessageWriter=e.AbstractMessageWriter=e.MessageWriter=void 0;var t=_t(),n=vt(),r=Tt(),i=yt(),a=`Content-Length: `,s=`\r
7
+ `,c;(function(e){function t(e){let t=e;return t&&n.func(t.dispose)&&n.func(t.onClose)&&n.func(t.onError)&&n.func(t.write)}o(t,`is`),e.is=t})(c||(e.MessageWriter=c={}));var l=class{static{o(this,`AbstractMessageWriter`)}constructor(){this.errorEmitter=new i.Emitter,this.closeEmitter=new i.Emitter}dispose(){this.errorEmitter.dispose(),this.closeEmitter.dispose()}get onError(){return this.errorEmitter.event}fireError(e,t,n){this.errorEmitter.fire([this.asError(e),t,n])}get onClose(){return this.closeEmitter.event}fireClose(){this.closeEmitter.fire(void 0)}asError(e){return e instanceof Error?e:Error(`Writer received error. Reason: ${n.string(e.message)?e.message:`unknown`}`)}};e.AbstractMessageWriter=l;var u;(function(e){function n(e){return e===void 0||typeof e==`string`?{charset:e??`utf-8`,contentTypeEncoder:(0,t.default)().applicationJson.encoder}:{charset:e.charset??`utf-8`,contentEncoder:e.contentEncoder,contentTypeEncoder:e.contentTypeEncoder??(0,t.default)().applicationJson.encoder}}o(n,`fromOptions`),e.fromOptions=n})(u||={}),e.WriteableStreamMessageWriter=class extends l{static{o(this,`WriteableStreamMessageWriter`)}constructor(e,t){super(),this.writable=e,this.options=u.fromOptions(t),this.errorCount=0,this.writeSemaphore=new r.Semaphore(1),this.writable.onError(e=>this.fireError(e)),this.writable.onClose(()=>this.fireClose())}async write(e){return this.writeSemaphore.lock(async()=>this.options.contentTypeEncoder.encode(e,this.options).then(e=>this.options.contentEncoder===void 0?e:this.options.contentEncoder.encode(e)).then(t=>{let n=[];return n.push(a,t.byteLength.toString(),s),n.push(s),this.doWrite(e,n,t)},e=>{throw this.fireError(e),e}))}async doWrite(e,t,n){try{return await this.writable.write(t.join(``),`ascii`),this.writable.write(n)}catch(t){return this.handleError(t,e),Promise.reject(t)}}handleError(e,t){this.errorCount++,this.fireError(e,t,this.errorCount)}end(){this.writable.end()}}}}),Ot=c({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/common/messageBuffer.js"(e){Object.defineProperty(e,`__esModule`,{value:!0}),e.AbstractMessageBuffer=void 0;var t=13,n=10,r=`\r
8
+ `;e.AbstractMessageBuffer=class{static{o(this,`AbstractMessageBuffer`)}constructor(e=`utf-8`){this._encoding=e,this._chunks=[],this._totalLength=0}get encoding(){return this._encoding}append(e){let t=typeof e==`string`?this.fromString(e,this._encoding):e;this._chunks.push(t),this._totalLength+=t.byteLength}tryReadHeaders(e=!1){if(this._chunks.length===0)return;let i=0,a=0,o=0,s=0;row:for(;a<this._chunks.length;){let e=this._chunks[a];o=0;column:for(;o<e.length;){switch(e[o]){case t:switch(i){case 0:i=1;break;case 2:i=3;break;default:i=0}break;case n:switch(i){case 1:i=2;break;case 3:i=4,o++;break row;default:i=0}break;default:i=0}o++}s+=e.byteLength,a++}if(i!==4)return;let c=this._read(s+o),l=new Map,u=this.toString(c,`ascii`).split(r);if(u.length<2)return l;for(let t=0;t<u.length-2;t++){let n=u[t],r=n.indexOf(`:`);if(r===-1)throw Error(`Message header must separate key and value using ':'
9
+ ${n}`);let i=n.substr(0,r),a=n.substr(r+1).trim();l.set(e?i.toLowerCase():i,a)}return l}tryReadBody(e){if(!(this._totalLength<e))return this._read(e)}get numberOfBytes(){return this._totalLength}_read(e){if(e===0)return this.emptyBuffer();if(e>this._totalLength)throw Error(`Cannot read so many bytes!`);if(this._chunks[0].byteLength===e){let t=this._chunks[0];return this._chunks.shift(),this._totalLength-=e,this.asNative(t)}if(this._chunks[0].byteLength>e){let t=this._chunks[0],n=this.asNative(t,e);return this._chunks[0]=t.slice(e),this._totalLength-=e,n}let t=this.allocNative(e),n=0;for(;e>0;){let r=this._chunks[0];if(r.byteLength>e){let i=r.slice(0,e);t.set(i,n),n+=e,this._chunks[0]=r.slice(e),this._totalLength-=e,e-=e}else t.set(r,n),n+=r.byteLength,this._chunks.shift(),this._totalLength-=r.byteLength,e-=r.byteLength}return t}}}}),kt=c({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/common/connection.js"(e){Object.defineProperty(e,`__esModule`,{value:!0}),e.createMessageConnection=e.ConnectionOptions=e.MessageStrategy=e.CancellationStrategy=e.CancellationSenderStrategy=e.CancellationReceiverStrategy=e.RequestCancellationReceiverStrategy=e.IdCancellationReceiverStrategy=e.ConnectionStrategy=e.ConnectionError=e.ConnectionErrors=e.LogTraceNotification=e.SetTraceNotification=e.TraceFormat=e.TraceValues=e.Trace=e.NullLogger=e.ProgressType=e.ProgressToken=void 0;var t=_t(),n=vt(),r=xt(),i=St(),a=yt(),s=bt(),c;(function(e){e.type=new r.NotificationType(`$/cancelRequest`)})(c||={});var l;(function(e){function t(e){return typeof e==`string`||typeof e==`number`}o(t,`is`),e.is=t})(l||(e.ProgressToken=l={}));var u;(function(e){e.type=new r.NotificationType(`$/progress`)})(u||={}),e.ProgressType=class{static{o(this,`ProgressType`)}constructor(){}};var d;(function(e){function t(e){return n.func(e)}o(t,`is`),e.is=t})(d||={}),e.NullLogger=Object.freeze({error:o(()=>{},`error`),warn:o(()=>{},`warn`),info:o(()=>{},`info`),log:o(()=>{},`log`)});var f;(function(e){e[e.Off=0]=`Off`,e[e.Messages=1]=`Messages`,e[e.Compact=2]=`Compact`,e[e.Verbose=3]=`Verbose`})(f||(e.Trace=f={}));var p;(function(e){e.Off=`off`,e.Messages=`messages`,e.Compact=`compact`,e.Verbose=`verbose`})(p||(e.TraceValues=p={})),(function(e){function t(t){if(!n.string(t))return e.Off;switch(t=t.toLowerCase(),t){case`off`:return e.Off;case`messages`:return e.Messages;case`compact`:return e.Compact;case`verbose`:return e.Verbose;default:return e.Off}}o(t,`fromString`),e.fromString=t;function r(t){switch(t){case e.Off:return`off`;case e.Messages:return`messages`;case e.Compact:return`compact`;case e.Verbose:return`verbose`;default:return`off`}}o(r,`toString`),e.toString=r})(f||(e.Trace=f={}));var m;(function(e){e.Text=`text`,e.JSON=`json`})(m||(e.TraceFormat=m={})),(function(e){function t(t){return n.string(t)?(t=t.toLowerCase(),t===`json`?e.JSON:e.Text):e.Text}o(t,`fromString`),e.fromString=t})(m||(e.TraceFormat=m={}));var h;(function(e){e.type=new r.NotificationType(`$/setTrace`)})(h||(e.SetTraceNotification=h={}));var g;(function(e){e.type=new r.NotificationType(`$/logTrace`)})(g||(e.LogTraceNotification=g={}));var _;(function(e){e[e.Closed=1]=`Closed`,e[e.Disposed=2]=`Disposed`,e[e.AlreadyListening=3]=`AlreadyListening`})(_||(e.ConnectionErrors=_={}));var v=class e extends Error{static{o(this,`ConnectionError`)}constructor(t,n){super(n),this.code=t,Object.setPrototypeOf(this,e.prototype)}};e.ConnectionError=v;var y;(function(e){function t(e){let t=e;return t&&n.func(t.cancelUndispatched)}o(t,`is`),e.is=t})(y||(e.ConnectionStrategy=y={}));var b;(function(e){function t(e){let t=e;return t&&(t.kind===void 0||t.kind===`id`)&&n.func(t.createCancellationTokenSource)&&(t.dispose===void 0||n.func(t.dispose))}o(t,`is`),e.is=t})(b||(e.IdCancellationReceiverStrategy=b={}));var x;(function(e){function t(e){let t=e;return t&&t.kind===`request`&&n.func(t.createCancellationTokenSource)&&(t.dispose===void 0||n.func(t.dispose))}o(t,`is`),e.is=t})(x||(e.RequestCancellationReceiverStrategy=x={}));var ee;(function(e){e.Message=Object.freeze({createCancellationTokenSource(e){return new s.CancellationTokenSource}});function t(e){return b.is(e)||x.is(e)}o(t,`is`),e.is=t})(ee||(e.CancellationReceiverStrategy=ee={}));var S;(function(e){e.Message=Object.freeze({sendCancellation(e,t){return e.sendNotification(c.type,{id:t})},cleanup(e){}});function t(e){let t=e;return t&&n.func(t.sendCancellation)&&n.func(t.cleanup)}o(t,`is`),e.is=t})(S||(e.CancellationSenderStrategy=S={}));var te;(function(e){e.Message=Object.freeze({receiver:ee.Message,sender:S.Message});function t(e){let t=e;return t&&ee.is(t.receiver)&&S.is(t.sender)}o(t,`is`),e.is=t})(te||(e.CancellationStrategy=te={}));var ne;(function(e){function t(e){let t=e;return t&&n.func(t.handleMessage)}o(t,`is`),e.is=t})(ne||(e.MessageStrategy=ne={}));var C;(function(e){function t(e){let t=e;return t&&(te.is(t.cancellationStrategy)||y.is(t.connectionStrategy)||ne.is(t.messageStrategy))}o(t,`is`),e.is=t})(C||(e.ConnectionOptions=C={}));var re;(function(e){e[e.New=1]=`New`,e[e.Listening=2]=`Listening`,e[e.Closed=3]=`Closed`,e[e.Disposed=4]=`Disposed`})(re||={});function ie(p,y,x,ee){let S=x===void 0?e.NullLogger:x,C=0,ie=0,ae=0,oe,se=new Map,ce,le=new Map,ue=new Map,de,w=new i.LinkedMap,T=new Map,fe=new Set,E=new Map,D=f.Off,pe=m.Text,O,me=re.New,he=new a.Emitter,ge=new a.Emitter,_e=new a.Emitter,ve=new a.Emitter,ye=new a.Emitter,be=ee&&ee.cancellationStrategy?ee.cancellationStrategy:te.Message;function xe(e){if(e===null)throw Error(`Can't send requests with id null since the response can't be correlated.`);return`req-`+e.toString()}o(xe,`createRequestQueueKey`);function Se(e){return e===null?`res-unknown-`+(++ae).toString():`res-`+e.toString()}o(Se,`createResponseQueueKey`);function Ce(){return`not-`+(++ie).toString()}o(Ce,`createNotificationQueueKey`);function we(e,t){r.Message.isRequest(t)?e.set(xe(t.id),t):r.Message.isResponse(t)?e.set(Se(t.id),t):e.set(Ce(),t)}o(we,`addMessageToQueue`);function Te(e){}o(Te,`cancelUndispatched`);function Ee(){return me===re.Listening}o(Ee,`isListening`);function De(){return me===re.Closed}o(De,`isClosed`);function Oe(){return me===re.Disposed}o(Oe,`isDisposed`);function ke(){(me===re.New||me===re.Listening)&&(me=re.Closed,ge.fire(void 0))}o(ke,`closeHandler`);function Ae(e){he.fire([e,void 0,void 0])}o(Ae,`readErrorHandler`);function je(e){he.fire(e)}o(je,`writeErrorHandler`),p.onClose(ke),p.onError(Ae),y.onClose(ke),y.onError(je);function Me(){de||w.size===0||(de=(0,t.default)().timer.setImmediate(()=>{de=void 0,Pe()}))}o(Me,`triggerMessageQueue`);function Ne(e){r.Message.isRequest(e)?Ie(e):r.Message.isNotification(e)?Re(e):r.Message.isResponse(e)?Le(e):ze(e)}o(Ne,`handleMessage`);function Pe(){if(w.size===0)return;let e=w.shift();try{let t=ee?.messageStrategy;ne.is(t)?t.handleMessage(e,Ne):Ne(e)}finally{Me()}}o(Pe,`processMessageQueue`);let Fe=o(e=>{try{if(r.Message.isNotification(e)&&e.method===c.type.method){let t=e.params.id,n=xe(t),i=w.get(n);if(r.Message.isRequest(i)){let r=ee?.connectionStrategy,a=r&&r.cancelUndispatched?r.cancelUndispatched(i,Te):void 0;if(a&&(a.error!==void 0||a.result!==void 0)){w.delete(n),E.delete(t),a.id=i.id,Ue(a,e.method,Date.now()),y.write(a).catch(()=>S.error(`Sending response for canceled message failed.`));return}}let a=E.get(t);if(a!==void 0){a.cancel(),Ge(e);return}else fe.add(t)}we(w,e)}finally{Me()}},`callback`);function Ie(e){if(Oe())return;function t(t,n,i){let a={jsonrpc:`2.0`,id:e.id};t instanceof r.ResponseError?a.error=t.toJson():a.result=t===void 0?null:t,Ue(a,n,i),y.write(a).catch(()=>S.error(`Sending response failed.`))}o(t,`reply`);function i(t,n,r){let i={jsonrpc:`2.0`,id:e.id,error:t.toJson()};Ue(i,n,r),y.write(i).catch(()=>S.error(`Sending response failed.`))}o(i,`replyError`);function a(t,n,r){t===void 0&&(t=null);let i={jsonrpc:`2.0`,id:e.id,result:t};Ue(i,n,r),y.write(i).catch(()=>S.error(`Sending response failed.`))}o(a,`replySuccess`),We(e);let s=se.get(e.method),c,l;s&&(c=s.type,l=s.handler);let u=Date.now();if(l||oe){let o=e.id??String(Date.now()),s=b.is(be.receiver)?be.receiver.createCancellationTokenSource(o):be.receiver.createCancellationTokenSource(e);e.id!==null&&fe.has(e.id)&&s.cancel(),e.id!==null&&E.set(o,s);try{let d;if(l)if(e.params===void 0){if(c!==void 0&&c.numberOfParams!==0){i(new r.ResponseError(r.ErrorCodes.InvalidParams,`Request ${e.method} defines ${c.numberOfParams} params but received none.`),e.method,u);return}d=l(s.token)}else if(Array.isArray(e.params)){if(c!==void 0&&c.parameterStructures===r.ParameterStructures.byName){i(new r.ResponseError(r.ErrorCodes.InvalidParams,`Request ${e.method} defines parameters by name but received parameters by position`),e.method,u);return}d=l(...e.params,s.token)}else{if(c!==void 0&&c.parameterStructures===r.ParameterStructures.byPosition){i(new r.ResponseError(r.ErrorCodes.InvalidParams,`Request ${e.method} defines parameters by position but received parameters by name`),e.method,u);return}d=l(e.params,s.token)}else oe&&(d=oe(e.method,e.params,s.token));let f=d;d?f.then?f.then(n=>{E.delete(o),t(n,e.method,u)},t=>{E.delete(o),t instanceof r.ResponseError?i(t,e.method,u):t&&n.string(t.message)?i(new r.ResponseError(r.ErrorCodes.InternalError,`Request ${e.method} failed with message: ${t.message}`),e.method,u):i(new r.ResponseError(r.ErrorCodes.InternalError,`Request ${e.method} failed unexpectedly without providing any details.`),e.method,u)}):(E.delete(o),t(d,e.method,u)):(E.delete(o),a(d,e.method,u))}catch(a){E.delete(o),a instanceof r.ResponseError?t(a,e.method,u):a&&n.string(a.message)?i(new r.ResponseError(r.ErrorCodes.InternalError,`Request ${e.method} failed with message: ${a.message}`),e.method,u):i(new r.ResponseError(r.ErrorCodes.InternalError,`Request ${e.method} failed unexpectedly without providing any details.`),e.method,u)}}else i(new r.ResponseError(r.ErrorCodes.MethodNotFound,`Unhandled method ${e.method}`),e.method,u)}o(Ie,`handleRequest`);function Le(e){if(!Oe())if(e.id===null)e.error?S.error(`Received response message without id: Error is:
10
+ ${JSON.stringify(e.error,void 0,4)}`):S.error(`Received response message without id. No further error information provided.`);else{let t=e.id,n=T.get(t);if(Ke(e,n),n!==void 0){T.delete(t);try{if(e.error){let t=e.error;n.reject(new r.ResponseError(t.code,t.message,t.data))}else if(e.result!==void 0)n.resolve(e.result);else throw Error(`Should never happen.`)}catch(e){e.message?S.error(`Response handler '${n.method}' failed with message: ${e.message}`):S.error(`Response handler '${n.method}' failed unexpectedly.`)}}}}o(Le,`handleResponse`);function Re(e){if(Oe())return;let t,n;if(e.method===c.type.method){let t=e.params.id;fe.delete(t),Ge(e);return}else{let r=le.get(e.method);r&&(n=r.handler,t=r.type)}if(n||ce)try{if(Ge(e),n)if(e.params===void 0)t!==void 0&&t.numberOfParams!==0&&t.parameterStructures!==r.ParameterStructures.byName&&S.error(`Notification ${e.method} defines ${t.numberOfParams} params but received none.`),n();else if(Array.isArray(e.params)){let i=e.params;e.method===u.type.method&&i.length===2&&l.is(i[0])?n({token:i[0],value:i[1]}):(t!==void 0&&(t.parameterStructures===r.ParameterStructures.byName&&S.error(`Notification ${e.method} defines parameters by name but received parameters by position`),t.numberOfParams!==e.params.length&&S.error(`Notification ${e.method} defines ${t.numberOfParams} params but received ${i.length} arguments`)),n(...i))}else t!==void 0&&t.parameterStructures===r.ParameterStructures.byPosition&&S.error(`Notification ${e.method} defines parameters by position but received parameters by name`),n(e.params);else ce&&ce(e.method,e.params)}catch(t){t.message?S.error(`Notification handler '${e.method}' failed with message: ${t.message}`):S.error(`Notification handler '${e.method}' failed unexpectedly.`)}else _e.fire(e)}o(Re,`handleNotification`);function ze(e){if(!e){S.error(`Received empty message.`);return}S.error(`Received message which is neither a response nor a notification message:
11
+ ${JSON.stringify(e,null,4)}`);let t=e;if(n.string(t.id)||n.number(t.id)){let e=t.id,n=T.get(e);n&&n.reject(Error(`The received response has neither a result nor an error property.`))}}o(ze,`handleInvalidMessage`);function Be(e){if(e!=null)switch(D){case f.Verbose:return JSON.stringify(e,null,4);case f.Compact:return JSON.stringify(e);default:return}}o(Be,`stringifyTrace`);function Ve(e){if(!(D===f.Off||!O))if(pe===m.Text){let t;(D===f.Verbose||D===f.Compact)&&e.params&&(t=`Params: ${Be(e.params)}
12
+
13
+ `),O.log(`Sending request '${e.method} - (${e.id})'.`,t)}else qe(`send-request`,e)}o(Ve,`traceSendingRequest`);function He(e){if(!(D===f.Off||!O))if(pe===m.Text){let t;(D===f.Verbose||D===f.Compact)&&(t=e.params?`Params: ${Be(e.params)}
14
+
15
+ `:`No parameters provided.
16
+
17
+ `),O.log(`Sending notification '${e.method}'.`,t)}else qe(`send-notification`,e)}o(He,`traceSendingNotification`);function Ue(e,t,n){if(!(D===f.Off||!O))if(pe===m.Text){let r;(D===f.Verbose||D===f.Compact)&&(e.error&&e.error.data?r=`Error data: ${Be(e.error.data)}
18
+
19
+ `:e.result?r=`Result: ${Be(e.result)}
20
+
21
+ `:e.error===void 0&&(r=`No result returned.
22
+
23
+ `)),O.log(`Sending response '${t} - (${e.id})'. Processing request took ${Date.now()-n}ms`,r)}else qe(`send-response`,e)}o(Ue,`traceSendingResponse`);function We(e){if(!(D===f.Off||!O))if(pe===m.Text){let t;(D===f.Verbose||D===f.Compact)&&e.params&&(t=`Params: ${Be(e.params)}
24
+
25
+ `),O.log(`Received request '${e.method} - (${e.id})'.`,t)}else qe(`receive-request`,e)}o(We,`traceReceivedRequest`);function Ge(e){if(!(D===f.Off||!O||e.method===g.type.method))if(pe===m.Text){let t;(D===f.Verbose||D===f.Compact)&&(t=e.params?`Params: ${Be(e.params)}
26
+
27
+ `:`No parameters provided.
28
+
29
+ `),O.log(`Received notification '${e.method}'.`,t)}else qe(`receive-notification`,e)}o(Ge,`traceReceivedNotification`);function Ke(e,t){if(!(D===f.Off||!O))if(pe===m.Text){let n;if((D===f.Verbose||D===f.Compact)&&(e.error&&e.error.data?n=`Error data: ${Be(e.error.data)}
30
+
31
+ `:e.result?n=`Result: ${Be(e.result)}
32
+
33
+ `:e.error===void 0&&(n=`No result returned.
34
+
35
+ `)),t){let r=e.error?` Request failed: ${e.error.message} (${e.error.code}).`:``;O.log(`Received response '${t.method} - (${e.id})' in ${Date.now()-t.timerStart}ms.${r}`,n)}else O.log(`Received response ${e.id} without active response promise.`,n)}else qe(`receive-response`,e)}o(Ke,`traceReceivedResponse`);function qe(e,t){if(!O||D===f.Off)return;let n={isLSPMessage:!0,type:e,message:t,timestamp:Date.now()};O.log(n)}o(qe,`logLSPMessage`);function Je(){if(De())throw new v(_.Closed,`Connection is closed.`);if(Oe())throw new v(_.Disposed,`Connection is disposed.`)}o(Je,`throwIfClosedOrDisposed`);function Ye(){if(Ee())throw new v(_.AlreadyListening,`Connection is already listening`)}o(Ye,`throwIfListening`);function Xe(){if(!Ee())throw Error(`Call listen() first.`)}o(Xe,`throwIfNotListening`);function Ze(e){return e===void 0?null:e}o(Ze,`undefinedToNull`);function Qe(e){if(e!==null)return e}o(Qe,`nullToUndefined`);function $e(e){return e!=null&&!Array.isArray(e)&&typeof e==`object`}o($e,`isNamedParam`);function et(e,t){switch(e){case r.ParameterStructures.auto:return $e(t)?Qe(t):[Ze(t)];case r.ParameterStructures.byName:if(!$e(t))throw Error(`Received parameters by name but param is not an object literal.`);return Qe(t);case r.ParameterStructures.byPosition:return[Ze(t)];default:throw Error(`Unknown parameter structure ${e.toString()}`)}}o(et,`computeSingleParam`);function tt(e,t){let n,r=e.numberOfParams;switch(r){case 0:n=void 0;break;case 1:n=et(e.parameterStructures,t[0]);break;default:n=[];for(let e=0;e<t.length&&e<r;e++)n.push(Ze(t[e]));if(t.length<r)for(let e=t.length;e<r;e++)n.push(null);break}return n}o(tt,`computeMessageParams`);let nt={sendNotification:o((e,...t)=>{Je();let i,a;if(n.string(e)){i=e;let n=t[0],o=0,s=r.ParameterStructures.auto;r.ParameterStructures.is(n)&&(o=1,s=n);let c=t.length,l=c-o;switch(l){case 0:a=void 0;break;case 1:a=et(s,t[o]);break;default:if(s===r.ParameterStructures.byName)throw Error(`Received ${l} parameters for 'by Name' notification parameter structure.`);a=t.slice(o,c).map(e=>Ze(e));break}}else{let n=t;i=e.method,a=tt(e,n)}let o={jsonrpc:`2.0`,method:i,params:a};return He(o),y.write(o).catch(e=>{throw S.error(`Sending notification failed.`),e})},`sendNotification`),onNotification:o((e,t)=>{Je();let r;return n.func(e)?ce=e:t&&(n.string(e)?(r=e,le.set(e,{type:void 0,handler:t})):(r=e.method,le.set(e.method,{type:e,handler:t}))),{dispose:o(()=>{r===void 0?ce=void 0:le.delete(r)},`dispose`)}},`onNotification`),onProgress:o((e,t,n)=>{if(ue.has(t))throw Error(`Progress handler for token ${t} already registered`);return ue.set(t,n),{dispose:o(()=>{ue.delete(t)},`dispose`)}},`onProgress`),sendProgress:o((e,t,n)=>nt.sendNotification(u.type,{token:t,value:n}),`sendProgress`),onUnhandledProgress:ve.event,sendRequest:o((e,...t)=>{Je(),Xe();let i,a,c;if(n.string(e)){i=e;let n=t[0],o=t[t.length-1],l=0,u=r.ParameterStructures.auto;r.ParameterStructures.is(n)&&(l=1,u=n);let d=t.length;s.CancellationToken.is(o)&&(--d,c=o);let f=d-l;switch(f){case 0:a=void 0;break;case 1:a=et(u,t[l]);break;default:if(u===r.ParameterStructures.byName)throw Error(`Received ${f} parameters for 'by Name' request parameter structure.`);a=t.slice(l,d).map(e=>Ze(e));break}}else{let n=t;i=e.method,a=tt(e,n);let r=e.numberOfParams;c=s.CancellationToken.is(n[r])?n[r]:void 0}let l=C++,u;c&&(u=c.onCancellationRequested(()=>{let e=be.sender.sendCancellation(nt,l);return e===void 0?(S.log(`Received no promise from cancellation strategy when cancelling id ${l}`),Promise.resolve()):e.catch(()=>{S.log(`Sending cancellation messages for id ${l} failed`)})}));let d={jsonrpc:`2.0`,id:l,method:i,params:a};return Ve(d),typeof be.sender.enableCancellation==`function`&&be.sender.enableCancellation(d),new Promise(async(e,t)=>{let n=o(t=>{e(t),be.sender.cleanup(l),u?.dispose()},`resolveWithCleanup`),a=o(e=>{t(e),be.sender.cleanup(l),u?.dispose()},`rejectWithCleanup`),s={method:i,timerStart:Date.now(),resolve:n,reject:a};try{await y.write(d),T.set(l,s)}catch(e){throw S.error(`Sending request failed.`),s.reject(new r.ResponseError(r.ErrorCodes.MessageWriteError,e.message?e.message:`Unknown reason`)),e}})},`sendRequest`),onRequest:o((e,t)=>{Je();let r=null;return d.is(e)?(r=void 0,oe=e):n.string(e)?(r=null,t!==void 0&&(r=e,se.set(e,{handler:t,type:void 0}))):t!==void 0&&(r=e.method,se.set(e.method,{type:e,handler:t})),{dispose:o(()=>{r!==null&&(r===void 0?oe=void 0:se.delete(r))},`dispose`)}},`onRequest`),hasPendingResponse:o(()=>T.size>0,`hasPendingResponse`),trace:o(async(e,t,r)=>{let i=!1,a=m.Text;r!==void 0&&(n.boolean(r)?i=r:(i=r.sendNotification||!1,a=r.traceFormat||m.Text)),D=e,pe=a,O=D===f.Off?void 0:t,i&&!De()&&!Oe()&&await nt.sendNotification(h.type,{value:f.toString(e)})},`trace`),onError:he.event,onClose:ge.event,onUnhandledNotification:_e.event,onDispose:ye.event,end:o(()=>{y.end()},`end`),dispose:o(()=>{if(Oe())return;me=re.Disposed,ye.fire(void 0);let e=new r.ResponseError(r.ErrorCodes.PendingResponseRejected,`Pending response rejected since connection got disposed`);for(let t of T.values())t.reject(e);T=new Map,E=new Map,fe=new Set,w=new i.LinkedMap,n.func(y.dispose)&&y.dispose(),n.func(p.dispose)&&p.dispose()},`dispose`),listen:o(()=>{Je(),Ye(),me=re.Listening,p.listen(Fe)},`listen`),inspect:o(()=>{(0,t.default)().console.log(`inspect`)},`inspect`)};return nt.onNotification(g.type,e=>{if(D===f.Off||!O)return;let t=D===f.Verbose||D===f.Compact;O.log(e.message,t?e.verbose:void 0)}),nt.onNotification(u.type,e=>{let t=ue.get(e.token);t?t(e.value):ve.fire(e)}),nt}o(ie,`createMessageConnection`),e.createMessageConnection=ie}}),At=c({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/common/api.js"(e){Object.defineProperty(e,`__esModule`,{value:!0}),e.ProgressType=e.ProgressToken=e.createMessageConnection=e.NullLogger=e.ConnectionOptions=e.ConnectionStrategy=e.AbstractMessageBuffer=e.WriteableStreamMessageWriter=e.AbstractMessageWriter=e.MessageWriter=e.ReadableStreamMessageReader=e.AbstractMessageReader=e.MessageReader=e.SharedArrayReceiverStrategy=e.SharedArraySenderStrategy=e.CancellationToken=e.CancellationTokenSource=e.Emitter=e.Event=e.Disposable=e.LRUCache=e.Touch=e.LinkedMap=e.ParameterStructures=e.NotificationType9=e.NotificationType8=e.NotificationType7=e.NotificationType6=e.NotificationType5=e.NotificationType4=e.NotificationType3=e.NotificationType2=e.NotificationType1=e.NotificationType0=e.NotificationType=e.ErrorCodes=e.ResponseError=e.RequestType9=e.RequestType8=e.RequestType7=e.RequestType6=e.RequestType5=e.RequestType4=e.RequestType3=e.RequestType2=e.RequestType1=e.RequestType0=e.RequestType=e.Message=e.RAL=void 0,e.MessageStrategy=e.CancellationStrategy=e.CancellationSenderStrategy=e.CancellationReceiverStrategy=e.ConnectionError=e.ConnectionErrors=e.LogTraceNotification=e.SetTraceNotification=e.TraceFormat=e.TraceValues=e.Trace=void 0;var t=xt();Object.defineProperty(e,`Message`,{enumerable:!0,get:o(function(){return t.Message},`get`)}),Object.defineProperty(e,`RequestType`,{enumerable:!0,get:o(function(){return t.RequestType},`get`)}),Object.defineProperty(e,`RequestType0`,{enumerable:!0,get:o(function(){return t.RequestType0},`get`)}),Object.defineProperty(e,`RequestType1`,{enumerable:!0,get:o(function(){return t.RequestType1},`get`)}),Object.defineProperty(e,`RequestType2`,{enumerable:!0,get:o(function(){return t.RequestType2},`get`)}),Object.defineProperty(e,`RequestType3`,{enumerable:!0,get:o(function(){return t.RequestType3},`get`)}),Object.defineProperty(e,`RequestType4`,{enumerable:!0,get:o(function(){return t.RequestType4},`get`)}),Object.defineProperty(e,`RequestType5`,{enumerable:!0,get:o(function(){return t.RequestType5},`get`)}),Object.defineProperty(e,`RequestType6`,{enumerable:!0,get:o(function(){return t.RequestType6},`get`)}),Object.defineProperty(e,`RequestType7`,{enumerable:!0,get:o(function(){return t.RequestType7},`get`)}),Object.defineProperty(e,`RequestType8`,{enumerable:!0,get:o(function(){return t.RequestType8},`get`)}),Object.defineProperty(e,`RequestType9`,{enumerable:!0,get:o(function(){return t.RequestType9},`get`)}),Object.defineProperty(e,`ResponseError`,{enumerable:!0,get:o(function(){return t.ResponseError},`get`)}),Object.defineProperty(e,`ErrorCodes`,{enumerable:!0,get:o(function(){return t.ErrorCodes},`get`)}),Object.defineProperty(e,`NotificationType`,{enumerable:!0,get:o(function(){return t.NotificationType},`get`)}),Object.defineProperty(e,`NotificationType0`,{enumerable:!0,get:o(function(){return t.NotificationType0},`get`)}),Object.defineProperty(e,`NotificationType1`,{enumerable:!0,get:o(function(){return t.NotificationType1},`get`)}),Object.defineProperty(e,`NotificationType2`,{enumerable:!0,get:o(function(){return t.NotificationType2},`get`)}),Object.defineProperty(e,`NotificationType3`,{enumerable:!0,get:o(function(){return t.NotificationType3},`get`)}),Object.defineProperty(e,`NotificationType4`,{enumerable:!0,get:o(function(){return t.NotificationType4},`get`)}),Object.defineProperty(e,`NotificationType5`,{enumerable:!0,get:o(function(){return t.NotificationType5},`get`)}),Object.defineProperty(e,`NotificationType6`,{enumerable:!0,get:o(function(){return t.NotificationType6},`get`)}),Object.defineProperty(e,`NotificationType7`,{enumerable:!0,get:o(function(){return t.NotificationType7},`get`)}),Object.defineProperty(e,`NotificationType8`,{enumerable:!0,get:o(function(){return t.NotificationType8},`get`)}),Object.defineProperty(e,`NotificationType9`,{enumerable:!0,get:o(function(){return t.NotificationType9},`get`)}),Object.defineProperty(e,`ParameterStructures`,{enumerable:!0,get:o(function(){return t.ParameterStructures},`get`)});var n=St();Object.defineProperty(e,`LinkedMap`,{enumerable:!0,get:o(function(){return n.LinkedMap},`get`)}),Object.defineProperty(e,`LRUCache`,{enumerable:!0,get:o(function(){return n.LRUCache},`get`)}),Object.defineProperty(e,`Touch`,{enumerable:!0,get:o(function(){return n.Touch},`get`)});var r=Ct();Object.defineProperty(e,`Disposable`,{enumerable:!0,get:o(function(){return r.Disposable},`get`)});var i=yt();Object.defineProperty(e,`Event`,{enumerable:!0,get:o(function(){return i.Event},`get`)}),Object.defineProperty(e,`Emitter`,{enumerable:!0,get:o(function(){return i.Emitter},`get`)});var a=bt();Object.defineProperty(e,`CancellationTokenSource`,{enumerable:!0,get:o(function(){return a.CancellationTokenSource},`get`)}),Object.defineProperty(e,`CancellationToken`,{enumerable:!0,get:o(function(){return a.CancellationToken},`get`)});var s=wt();Object.defineProperty(e,`SharedArraySenderStrategy`,{enumerable:!0,get:o(function(){return s.SharedArraySenderStrategy},`get`)}),Object.defineProperty(e,`SharedArrayReceiverStrategy`,{enumerable:!0,get:o(function(){return s.SharedArrayReceiverStrategy},`get`)});var c=Et();Object.defineProperty(e,`MessageReader`,{enumerable:!0,get:o(function(){return c.MessageReader},`get`)}),Object.defineProperty(e,`AbstractMessageReader`,{enumerable:!0,get:o(function(){return c.AbstractMessageReader},`get`)}),Object.defineProperty(e,`ReadableStreamMessageReader`,{enumerable:!0,get:o(function(){return c.ReadableStreamMessageReader},`get`)});var l=Dt();Object.defineProperty(e,`MessageWriter`,{enumerable:!0,get:o(function(){return l.MessageWriter},`get`)}),Object.defineProperty(e,`AbstractMessageWriter`,{enumerable:!0,get:o(function(){return l.AbstractMessageWriter},`get`)}),Object.defineProperty(e,`WriteableStreamMessageWriter`,{enumerable:!0,get:o(function(){return l.WriteableStreamMessageWriter},`get`)});var u=Ot();Object.defineProperty(e,`AbstractMessageBuffer`,{enumerable:!0,get:o(function(){return u.AbstractMessageBuffer},`get`)});var d=kt();Object.defineProperty(e,`ConnectionStrategy`,{enumerable:!0,get:o(function(){return d.ConnectionStrategy},`get`)}),Object.defineProperty(e,`ConnectionOptions`,{enumerable:!0,get:o(function(){return d.ConnectionOptions},`get`)}),Object.defineProperty(e,`NullLogger`,{enumerable:!0,get:o(function(){return d.NullLogger},`get`)}),Object.defineProperty(e,`createMessageConnection`,{enumerable:!0,get:o(function(){return d.createMessageConnection},`get`)}),Object.defineProperty(e,`ProgressToken`,{enumerable:!0,get:o(function(){return d.ProgressToken},`get`)}),Object.defineProperty(e,`ProgressType`,{enumerable:!0,get:o(function(){return d.ProgressType},`get`)}),Object.defineProperty(e,`Trace`,{enumerable:!0,get:o(function(){return d.Trace},`get`)}),Object.defineProperty(e,`TraceValues`,{enumerable:!0,get:o(function(){return d.TraceValues},`get`)}),Object.defineProperty(e,`TraceFormat`,{enumerable:!0,get:o(function(){return d.TraceFormat},`get`)}),Object.defineProperty(e,`SetTraceNotification`,{enumerable:!0,get:o(function(){return d.SetTraceNotification},`get`)}),Object.defineProperty(e,`LogTraceNotification`,{enumerable:!0,get:o(function(){return d.LogTraceNotification},`get`)}),Object.defineProperty(e,`ConnectionErrors`,{enumerable:!0,get:o(function(){return d.ConnectionErrors},`get`)}),Object.defineProperty(e,`ConnectionError`,{enumerable:!0,get:o(function(){return d.ConnectionError},`get`)}),Object.defineProperty(e,`CancellationReceiverStrategy`,{enumerable:!0,get:o(function(){return d.CancellationReceiverStrategy},`get`)}),Object.defineProperty(e,`CancellationSenderStrategy`,{enumerable:!0,get:o(function(){return d.CancellationSenderStrategy},`get`)}),Object.defineProperty(e,`CancellationStrategy`,{enumerable:!0,get:o(function(){return d.CancellationStrategy},`get`)}),Object.defineProperty(e,`MessageStrategy`,{enumerable:!0,get:o(function(){return d.MessageStrategy},`get`)}),e.RAL=_t().default}}),jt=c({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/browser/ril.js"(e){Object.defineProperty(e,`__esModule`,{value:!0});var t=At(),n=class e extends t.AbstractMessageBuffer{static{o(this,`MessageBuffer`)}constructor(e=`utf-8`){super(e),this.asciiDecoder=new TextDecoder(`ascii`)}emptyBuffer(){return e.emptyBuffer}fromString(e,t){return new TextEncoder().encode(e)}toString(e,t){return t===`ascii`?this.asciiDecoder.decode(e):new TextDecoder(t).decode(e)}asNative(e,t){return t===void 0?e:e.slice(0,t)}allocNative(e){return new Uint8Array(e)}};n.emptyBuffer=new Uint8Array;var r=class{static{o(this,`ReadableStreamWrapper`)}constructor(e){this.socket=e,this._onData=new t.Emitter,this._messageListener=e=>{e.data.arrayBuffer().then(e=>{this._onData.fire(new Uint8Array(e))},()=>{(0,t.RAL)().console.error(`Converting blob to array buffer failed.`)})},this.socket.addEventListener(`message`,this._messageListener)}onClose(e){return this.socket.addEventListener(`close`,e),t.Disposable.create(()=>this.socket.removeEventListener(`close`,e))}onError(e){return this.socket.addEventListener(`error`,e),t.Disposable.create(()=>this.socket.removeEventListener(`error`,e))}onEnd(e){return this.socket.addEventListener(`end`,e),t.Disposable.create(()=>this.socket.removeEventListener(`end`,e))}onData(e){return this._onData.event(e)}},i=class{static{o(this,`WritableStreamWrapper`)}constructor(e){this.socket=e}onClose(e){return this.socket.addEventListener(`close`,e),t.Disposable.create(()=>this.socket.removeEventListener(`close`,e))}onError(e){return this.socket.addEventListener(`error`,e),t.Disposable.create(()=>this.socket.removeEventListener(`error`,e))}onEnd(e){return this.socket.addEventListener(`end`,e),t.Disposable.create(()=>this.socket.removeEventListener(`end`,e))}write(e,t){if(typeof e==`string`){if(t!==void 0&&t!==`utf-8`)throw Error(`In a Browser environments only utf-8 text encoding is supported. But got encoding: ${t}`);this.socket.send(e)}else this.socket.send(e);return Promise.resolve()}end(){this.socket.close()}},a=new TextEncoder,s=Object.freeze({messageBuffer:Object.freeze({create:o(e=>new n(e),`create`)}),applicationJson:Object.freeze({encoder:Object.freeze({name:`application/json`,encode:o((e,t)=>{if(t.charset!==`utf-8`)throw Error(`In a Browser environments only utf-8 text encoding is supported. But got encoding: ${t.charset}`);return Promise.resolve(a.encode(JSON.stringify(e,void 0,0)))},`encode`)}),decoder:Object.freeze({name:`application/json`,decode:o((e,t)=>{if(!(e instanceof Uint8Array))throw Error(`In a Browser environments only Uint8Arrays are supported.`);return Promise.resolve(JSON.parse(new TextDecoder(t.charset).decode(e)))},`decode`)})}),stream:Object.freeze({asReadableStream:o(e=>new r(e),`asReadableStream`),asWritableStream:o(e=>new i(e),`asWritableStream`)}),console,timer:Object.freeze({setTimeout(e,t,...n){let r=setTimeout(e,t,...n);return{dispose:o(()=>clearTimeout(r),`dispose`)}},setImmediate(e,...t){let n=setTimeout(e,0,...t);return{dispose:o(()=>clearTimeout(n),`dispose`)}},setInterval(e,t,...n){let r=setInterval(e,t,...n);return{dispose:o(()=>clearInterval(r),`dispose`)}}})});function c(){return s}o(c,`RIL`),(function(e){function n(){t.RAL.install(s)}o(n,`install`),e.install=n})(c||={}),e.default=c}}),Mt=c({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/browser/main.js"(e){var t=e&&e.__createBinding||(Object.create?(function(e,t,n,r){r===void 0&&(r=n);var i=Object.getOwnPropertyDescriptor(t,n);(!i||(`get`in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:o(function(){return t[n]},`get`)}),Object.defineProperty(e,r,i)}):(function(e,t,n,r){r===void 0&&(r=n),e[r]=t[n]})),n=e&&e.__exportStar||function(e,n){for(var r in e)r!==`default`&&!Object.prototype.hasOwnProperty.call(n,r)&&t(n,e,r)};Object.defineProperty(e,`__esModule`,{value:!0}),e.createMessageConnection=e.BrowserMessageWriter=e.BrowserMessageReader=void 0,jt().default.install();var r=At();n(At(),e),e.BrowserMessageReader=class extends r.AbstractMessageReader{static{o(this,`BrowserMessageReader`)}constructor(e){super(),this._onData=new r.Emitter,this._messageListener=e=>{this._onData.fire(e.data)},e.addEventListener(`error`,e=>this.fireError(e)),e.onmessage=this._messageListener}listen(e){return this._onData.event(e)}},e.BrowserMessageWriter=class extends r.AbstractMessageWriter{static{o(this,`BrowserMessageWriter`)}constructor(e){super(),this.port=e,this.errorCount=0,e.addEventListener(`error`,e=>this.fireError(e))}write(e){try{return this.port.postMessage(e),Promise.resolve()}catch(t){return this.handleError(t,e),Promise.reject(t)}}handleError(e,t){this.errorCount++,this.fireError(e,t,this.errorCount)}end(){}};function i(e,t,n,i){return n===void 0&&(n=r.NullLogger),r.ConnectionStrategy.is(i)&&(i={connectionStrategy:i}),(0,r.createMessageConnection)(e,t,n,i)}o(i,`createMessageConnection`),e.createMessageConnection=i}}),Nt=c({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/browser.js"(e,t){t.exports=Mt()}}),A=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/messages.js"(e){Object.defineProperty(e,`__esModule`,{value:!0}),e.ProtocolNotificationType=e.ProtocolNotificationType0=e.ProtocolRequestType=e.ProtocolRequestType0=e.RegistrationType=e.MessageDirection=void 0;var t=Mt(),n;(function(e){e.clientToServer=`clientToServer`,e.serverToClient=`serverToClient`,e.both=`both`})(n||(e.MessageDirection=n={})),e.RegistrationType=class{static{o(this,`RegistrationType`)}constructor(e){this.method=e}},e.ProtocolRequestType0=class extends t.RequestType0{static{o(this,`ProtocolRequestType0`)}constructor(e){super(e)}},e.ProtocolRequestType=class extends t.RequestType{static{o(this,`ProtocolRequestType`)}constructor(e){super(e,t.ParameterStructures.byName)}},e.ProtocolNotificationType0=class extends t.NotificationType0{static{o(this,`ProtocolNotificationType0`)}constructor(e){super(e)}},e.ProtocolNotificationType=class extends t.NotificationType{static{o(this,`ProtocolNotificationType`)}constructor(e){super(e,t.ParameterStructures.byName)}}}}),Pt=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/utils/is.js"(e){Object.defineProperty(e,`__esModule`,{value:!0}),e.objectLiteral=e.typedArray=e.stringArray=e.array=e.func=e.error=e.number=e.string=e.boolean=void 0;function t(e){return e===!0||e===!1}o(t,`boolean`),e.boolean=t;function n(e){return typeof e==`string`||e instanceof String}o(n,`string`),e.string=n;function r(e){return typeof e==`number`||e instanceof Number}o(r,`number`),e.number=r;function i(e){return e instanceof Error}o(i,`error`),e.error=i;function a(e){return typeof e==`function`}o(a,`func`),e.func=a;function s(e){return Array.isArray(e)}o(s,`array`),e.array=s;function c(e){return s(e)&&e.every(e=>n(e))}o(c,`stringArray`),e.stringArray=c;function l(e,t){return Array.isArray(e)&&e.every(t)}o(l,`typedArray`),e.typedArray=l;function u(e){return typeof e==`object`&&!!e}o(u,`objectLiteral`),e.objectLiteral=u}}),Ft=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.implementation.js"(e){Object.defineProperty(e,`__esModule`,{value:!0}),e.ImplementationRequest=void 0;var t=A(),n;(function(e){e.method=`textDocument/implementation`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(n||(e.ImplementationRequest=n={}))}}),It=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.typeDefinition.js"(e){Object.defineProperty(e,`__esModule`,{value:!0}),e.TypeDefinitionRequest=void 0;var t=A(),n;(function(e){e.method=`textDocument/typeDefinition`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(n||(e.TypeDefinitionRequest=n={}))}}),Lt=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.workspaceFolder.js"(e){Object.defineProperty(e,`__esModule`,{value:!0}),e.DidChangeWorkspaceFoldersNotification=e.WorkspaceFoldersRequest=void 0;var t=A(),n;(function(e){e.method=`workspace/workspaceFolders`,e.messageDirection=t.MessageDirection.serverToClient,e.type=new t.ProtocolRequestType0(e.method)})(n||(e.WorkspaceFoldersRequest=n={}));var r;(function(e){e.method=`workspace/didChangeWorkspaceFolders`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolNotificationType(e.method)})(r||(e.DidChangeWorkspaceFoldersNotification=r={}))}}),Rt=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.configuration.js"(e){Object.defineProperty(e,`__esModule`,{value:!0}),e.ConfigurationRequest=void 0;var t=A(),n;(function(e){e.method=`workspace/configuration`,e.messageDirection=t.MessageDirection.serverToClient,e.type=new t.ProtocolRequestType(e.method)})(n||(e.ConfigurationRequest=n={}))}}),zt=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.colorProvider.js"(e){Object.defineProperty(e,`__esModule`,{value:!0}),e.ColorPresentationRequest=e.DocumentColorRequest=void 0;var t=A(),n;(function(e){e.method=`textDocument/documentColor`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(n||(e.DocumentColorRequest=n={}));var r;(function(e){e.method=`textDocument/colorPresentation`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(r||(e.ColorPresentationRequest=r={}))}}),Bt=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.foldingRange.js"(e){Object.defineProperty(e,`__esModule`,{value:!0}),e.FoldingRangeRefreshRequest=e.FoldingRangeRequest=void 0;var t=A(),n;(function(e){e.method=`textDocument/foldingRange`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(n||(e.FoldingRangeRequest=n={}));var r;(function(e){e.method=`workspace/foldingRange/refresh`,e.messageDirection=t.MessageDirection.serverToClient,e.type=new t.ProtocolRequestType0(e.method)})(r||(e.FoldingRangeRefreshRequest=r={}))}}),Vt=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.declaration.js"(e){Object.defineProperty(e,`__esModule`,{value:!0}),e.DeclarationRequest=void 0;var t=A(),n;(function(e){e.method=`textDocument/declaration`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(n||(e.DeclarationRequest=n={}))}}),Ht=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.selectionRange.js"(e){Object.defineProperty(e,`__esModule`,{value:!0}),e.SelectionRangeRequest=void 0;var t=A(),n;(function(e){e.method=`textDocument/selectionRange`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(n||(e.SelectionRangeRequest=n={}))}}),Ut=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.progress.js"(e){Object.defineProperty(e,`__esModule`,{value:!0}),e.WorkDoneProgressCancelNotification=e.WorkDoneProgressCreateRequest=e.WorkDoneProgress=void 0;var t=Mt(),n=A(),r;(function(e){e.type=new t.ProgressType;function n(t){return t===e.type}o(n,`is`),e.is=n})(r||(e.WorkDoneProgress=r={}));var i;(function(e){e.method=`window/workDoneProgress/create`,e.messageDirection=n.MessageDirection.serverToClient,e.type=new n.ProtocolRequestType(e.method)})(i||(e.WorkDoneProgressCreateRequest=i={}));var a;(function(e){e.method=`window/workDoneProgress/cancel`,e.messageDirection=n.MessageDirection.clientToServer,e.type=new n.ProtocolNotificationType(e.method)})(a||(e.WorkDoneProgressCancelNotification=a={}))}}),Wt=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.callHierarchy.js"(e){Object.defineProperty(e,`__esModule`,{value:!0}),e.CallHierarchyOutgoingCallsRequest=e.CallHierarchyIncomingCallsRequest=e.CallHierarchyPrepareRequest=void 0;var t=A(),n;(function(e){e.method=`textDocument/prepareCallHierarchy`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(n||(e.CallHierarchyPrepareRequest=n={}));var r;(function(e){e.method=`callHierarchy/incomingCalls`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(r||(e.CallHierarchyIncomingCallsRequest=r={}));var i;(function(e){e.method=`callHierarchy/outgoingCalls`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(i||(e.CallHierarchyOutgoingCallsRequest=i={}))}}),Gt=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.semanticTokens.js"(e){Object.defineProperty(e,`__esModule`,{value:!0}),e.SemanticTokensRefreshRequest=e.SemanticTokensRangeRequest=e.SemanticTokensDeltaRequest=e.SemanticTokensRequest=e.SemanticTokensRegistrationType=e.TokenFormat=void 0;var t=A(),n;(function(e){e.Relative=`relative`})(n||(e.TokenFormat=n={}));var r;(function(e){e.method=`textDocument/semanticTokens`,e.type=new t.RegistrationType(e.method)})(r||(e.SemanticTokensRegistrationType=r={}));var i;(function(e){e.method=`textDocument/semanticTokens/full`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method),e.registrationMethod=r.method})(i||(e.SemanticTokensRequest=i={}));var a;(function(e){e.method=`textDocument/semanticTokens/full/delta`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method),e.registrationMethod=r.method})(a||(e.SemanticTokensDeltaRequest=a={}));var o;(function(e){e.method=`textDocument/semanticTokens/range`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method),e.registrationMethod=r.method})(o||(e.SemanticTokensRangeRequest=o={}));var s;(function(e){e.method=`workspace/semanticTokens/refresh`,e.messageDirection=t.MessageDirection.serverToClient,e.type=new t.ProtocolRequestType0(e.method)})(s||(e.SemanticTokensRefreshRequest=s={}))}}),Kt=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.showDocument.js"(e){Object.defineProperty(e,`__esModule`,{value:!0}),e.ShowDocumentRequest=void 0;var t=A(),n;(function(e){e.method=`window/showDocument`,e.messageDirection=t.MessageDirection.serverToClient,e.type=new t.ProtocolRequestType(e.method)})(n||(e.ShowDocumentRequest=n={}))}}),qt=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.linkedEditingRange.js"(e){Object.defineProperty(e,`__esModule`,{value:!0}),e.LinkedEditingRangeRequest=void 0;var t=A(),n;(function(e){e.method=`textDocument/linkedEditingRange`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(n||(e.LinkedEditingRangeRequest=n={}))}}),Jt=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.fileOperations.js"(e){Object.defineProperty(e,`__esModule`,{value:!0}),e.WillDeleteFilesRequest=e.DidDeleteFilesNotification=e.DidRenameFilesNotification=e.WillRenameFilesRequest=e.DidCreateFilesNotification=e.WillCreateFilesRequest=e.FileOperationPatternKind=void 0;var t=A(),n;(function(e){e.file=`file`,e.folder=`folder`})(n||(e.FileOperationPatternKind=n={}));var r;(function(e){e.method=`workspace/willCreateFiles`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(r||(e.WillCreateFilesRequest=r={}));var i;(function(e){e.method=`workspace/didCreateFiles`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolNotificationType(e.method)})(i||(e.DidCreateFilesNotification=i={}));var a;(function(e){e.method=`workspace/willRenameFiles`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(a||(e.WillRenameFilesRequest=a={}));var o;(function(e){e.method=`workspace/didRenameFiles`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolNotificationType(e.method)})(o||(e.DidRenameFilesNotification=o={}));var s;(function(e){e.method=`workspace/didDeleteFiles`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolNotificationType(e.method)})(s||(e.DidDeleteFilesNotification=s={}));var c;(function(e){e.method=`workspace/willDeleteFiles`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(c||(e.WillDeleteFilesRequest=c={}))}}),Yt=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.moniker.js"(e){Object.defineProperty(e,`__esModule`,{value:!0}),e.MonikerRequest=e.MonikerKind=e.UniquenessLevel=void 0;var t=A(),n;(function(e){e.document=`document`,e.project=`project`,e.group=`group`,e.scheme=`scheme`,e.global=`global`})(n||(e.UniquenessLevel=n={}));var r;(function(e){e.$import=`import`,e.$export=`export`,e.local=`local`})(r||(e.MonikerKind=r={}));var i;(function(e){e.method=`textDocument/moniker`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(i||(e.MonikerRequest=i={}))}}),Xt=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.typeHierarchy.js"(e){Object.defineProperty(e,`__esModule`,{value:!0}),e.TypeHierarchySubtypesRequest=e.TypeHierarchySupertypesRequest=e.TypeHierarchyPrepareRequest=void 0;var t=A(),n;(function(e){e.method=`textDocument/prepareTypeHierarchy`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(n||(e.TypeHierarchyPrepareRequest=n={}));var r;(function(e){e.method=`typeHierarchy/supertypes`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(r||(e.TypeHierarchySupertypesRequest=r={}));var i;(function(e){e.method=`typeHierarchy/subtypes`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(i||(e.TypeHierarchySubtypesRequest=i={}))}}),Zt=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.inlineValue.js"(e){Object.defineProperty(e,`__esModule`,{value:!0}),e.InlineValueRefreshRequest=e.InlineValueRequest=void 0;var t=A(),n;(function(e){e.method=`textDocument/inlineValue`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(n||(e.InlineValueRequest=n={}));var r;(function(e){e.method=`workspace/inlineValue/refresh`,e.messageDirection=t.MessageDirection.serverToClient,e.type=new t.ProtocolRequestType0(e.method)})(r||(e.InlineValueRefreshRequest=r={}))}}),Qt=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.inlayHint.js"(e){Object.defineProperty(e,`__esModule`,{value:!0}),e.InlayHintRefreshRequest=e.InlayHintResolveRequest=e.InlayHintRequest=void 0;var t=A(),n;(function(e){e.method=`textDocument/inlayHint`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(n||(e.InlayHintRequest=n={}));var r;(function(e){e.method=`inlayHint/resolve`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(r||(e.InlayHintResolveRequest=r={}));var i;(function(e){e.method=`workspace/inlayHint/refresh`,e.messageDirection=t.MessageDirection.serverToClient,e.type=new t.ProtocolRequestType0(e.method)})(i||(e.InlayHintRefreshRequest=i={}))}}),$t=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.diagnostic.js"(e){Object.defineProperty(e,`__esModule`,{value:!0}),e.DiagnosticRefreshRequest=e.WorkspaceDiagnosticRequest=e.DocumentDiagnosticRequest=e.DocumentDiagnosticReportKind=e.DiagnosticServerCancellationData=void 0;var t=Mt(),n=Pt(),r=A(),i;(function(e){function t(e){let t=e;return t&&n.boolean(t.retriggerRequest)}o(t,`is`),e.is=t})(i||(e.DiagnosticServerCancellationData=i={}));var a;(function(e){e.Full=`full`,e.Unchanged=`unchanged`})(a||(e.DocumentDiagnosticReportKind=a={}));var s;(function(e){e.method=`textDocument/diagnostic`,e.messageDirection=r.MessageDirection.clientToServer,e.type=new r.ProtocolRequestType(e.method),e.partialResult=new t.ProgressType})(s||(e.DocumentDiagnosticRequest=s={}));var c;(function(e){e.method=`workspace/diagnostic`,e.messageDirection=r.MessageDirection.clientToServer,e.type=new r.ProtocolRequestType(e.method),e.partialResult=new t.ProgressType})(c||(e.WorkspaceDiagnosticRequest=c={}));var l;(function(e){e.method=`workspace/diagnostic/refresh`,e.messageDirection=r.MessageDirection.serverToClient,e.type=new r.ProtocolRequestType0(e.method)})(l||(e.DiagnosticRefreshRequest=l={}))}}),en=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.notebook.js"(e){Object.defineProperty(e,`__esModule`,{value:!0}),e.DidCloseNotebookDocumentNotification=e.DidSaveNotebookDocumentNotification=e.DidChangeNotebookDocumentNotification=e.NotebookCellArrayChange=e.DidOpenNotebookDocumentNotification=e.NotebookDocumentSyncRegistrationType=e.NotebookDocument=e.NotebookCell=e.ExecutionSummary=e.NotebookCellKind=void 0;var t=(gt(),p(m)),n=Pt(),r=A(),i;(function(e){e.Markup=1,e.Code=2;function t(e){return e===1||e===2}o(t,`is`),e.is=t})(i||(e.NotebookCellKind=i={}));var a;(function(e){function r(e,t){let n={executionOrder:e};return(t===!0||t===!1)&&(n.success=t),n}o(r,`create`),e.create=r;function i(e){let r=e;return n.objectLiteral(r)&&t.uinteger.is(r.executionOrder)&&(r.success===void 0||n.boolean(r.success))}o(i,`is`),e.is=i;function a(e,t){return e===t?!0:e==null||t==null?!1:e.executionOrder===t.executionOrder&&e.success===t.success}o(a,`equals`),e.equals=a})(a||(e.ExecutionSummary=a={}));var s;(function(e){function r(e,t){return{kind:e,document:t}}o(r,`create`),e.create=r;function s(e){let r=e;return n.objectLiteral(r)&&i.is(r.kind)&&t.DocumentUri.is(r.document)&&(r.metadata===void 0||n.objectLiteral(r.metadata))}o(s,`is`),e.is=s;function c(e,t){let n=new Set;return e.document!==t.document&&n.add(`document`),e.kind!==t.kind&&n.add(`kind`),e.executionSummary!==t.executionSummary&&n.add(`executionSummary`),(e.metadata!==void 0||t.metadata!==void 0)&&!l(e.metadata,t.metadata)&&n.add(`metadata`),(e.executionSummary!==void 0||t.executionSummary!==void 0)&&!a.equals(e.executionSummary,t.executionSummary)&&n.add(`executionSummary`),n}o(c,`diff`),e.diff=c;function l(e,t){if(e===t)return!0;if(e==null||t==null||typeof e!=typeof t||typeof e!=`object`)return!1;let r=Array.isArray(e),i=Array.isArray(t);if(r!==i)return!1;if(r&&i){if(e.length!==t.length)return!1;for(let n=0;n<e.length;n++)if(!l(e[n],t[n]))return!1}if(n.objectLiteral(e)&&n.objectLiteral(t)){let n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length||(n.sort(),r.sort(),!l(n,r)))return!1;for(let r=0;r<n.length;r++){let i=n[r];if(!l(e[i],t[i]))return!1}}return!0}o(l,`equalsMetadata`)})(s||(e.NotebookCell=s={}));var c;(function(e){function r(e,t,n,r){return{uri:e,notebookType:t,version:n,cells:r}}o(r,`create`),e.create=r;function i(e){let r=e;return n.objectLiteral(r)&&n.string(r.uri)&&t.integer.is(r.version)&&n.typedArray(r.cells,s.is)}o(i,`is`),e.is=i})(c||(e.NotebookDocument=c={}));var l;(function(e){e.method=`notebookDocument/sync`,e.messageDirection=r.MessageDirection.clientToServer,e.type=new r.RegistrationType(e.method)})(l||(e.NotebookDocumentSyncRegistrationType=l={}));var u;(function(e){e.method=`notebookDocument/didOpen`,e.messageDirection=r.MessageDirection.clientToServer,e.type=new r.ProtocolNotificationType(e.method),e.registrationMethod=l.method})(u||(e.DidOpenNotebookDocumentNotification=u={}));var d;(function(e){function r(e){let r=e;return n.objectLiteral(r)&&t.uinteger.is(r.start)&&t.uinteger.is(r.deleteCount)&&(r.cells===void 0||n.typedArray(r.cells,s.is))}o(r,`is`),e.is=r;function i(e,t,n){let r={start:e,deleteCount:t};return n!==void 0&&(r.cells=n),r}o(i,`create`),e.create=i})(d||(e.NotebookCellArrayChange=d={}));var f;(function(e){e.method=`notebookDocument/didChange`,e.messageDirection=r.MessageDirection.clientToServer,e.type=new r.ProtocolNotificationType(e.method),e.registrationMethod=l.method})(f||(e.DidChangeNotebookDocumentNotification=f={}));var h;(function(e){e.method=`notebookDocument/didSave`,e.messageDirection=r.MessageDirection.clientToServer,e.type=new r.ProtocolNotificationType(e.method),e.registrationMethod=l.method})(h||(e.DidSaveNotebookDocumentNotification=h={}));var g;(function(e){e.method=`notebookDocument/didClose`,e.messageDirection=r.MessageDirection.clientToServer,e.type=new r.ProtocolNotificationType(e.method),e.registrationMethod=l.method})(g||(e.DidCloseNotebookDocumentNotification=g={}))}}),tn=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.inlineCompletion.js"(e){Object.defineProperty(e,`__esModule`,{value:!0}),e.InlineCompletionRequest=void 0;var t=A(),n;(function(e){e.method=`textDocument/inlineCompletion`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(n||(e.InlineCompletionRequest=n={}))}}),nn=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.js"(e){Object.defineProperty(e,`__esModule`,{value:!0}),e.WorkspaceSymbolRequest=e.CodeActionResolveRequest=e.CodeActionRequest=e.DocumentSymbolRequest=e.DocumentHighlightRequest=e.ReferencesRequest=e.DefinitionRequest=e.SignatureHelpRequest=e.SignatureHelpTriggerKind=e.HoverRequest=e.CompletionResolveRequest=e.CompletionRequest=e.CompletionTriggerKind=e.PublishDiagnosticsNotification=e.WatchKind=e.RelativePattern=e.FileChangeType=e.DidChangeWatchedFilesNotification=e.WillSaveTextDocumentWaitUntilRequest=e.WillSaveTextDocumentNotification=e.TextDocumentSaveReason=e.DidSaveTextDocumentNotification=e.DidCloseTextDocumentNotification=e.DidChangeTextDocumentNotification=e.TextDocumentContentChangeEvent=e.DidOpenTextDocumentNotification=e.TextDocumentSyncKind=e.TelemetryEventNotification=e.LogMessageNotification=e.ShowMessageRequest=e.ShowMessageNotification=e.MessageType=e.DidChangeConfigurationNotification=e.ExitNotification=e.ShutdownRequest=e.InitializedNotification=e.InitializeErrorCodes=e.InitializeRequest=e.WorkDoneProgressOptions=e.TextDocumentRegistrationOptions=e.StaticRegistrationOptions=e.PositionEncodingKind=e.FailureHandlingKind=e.ResourceOperationKind=e.UnregistrationRequest=e.RegistrationRequest=e.DocumentSelector=e.NotebookCellTextDocumentFilter=e.NotebookDocumentFilter=e.TextDocumentFilter=void 0,e.MonikerRequest=e.MonikerKind=e.UniquenessLevel=e.WillDeleteFilesRequest=e.DidDeleteFilesNotification=e.WillRenameFilesRequest=e.DidRenameFilesNotification=e.WillCreateFilesRequest=e.DidCreateFilesNotification=e.FileOperationPatternKind=e.LinkedEditingRangeRequest=e.ShowDocumentRequest=e.SemanticTokensRegistrationType=e.SemanticTokensRefreshRequest=e.SemanticTokensRangeRequest=e.SemanticTokensDeltaRequest=e.SemanticTokensRequest=e.TokenFormat=e.CallHierarchyPrepareRequest=e.CallHierarchyOutgoingCallsRequest=e.CallHierarchyIncomingCallsRequest=e.WorkDoneProgressCancelNotification=e.WorkDoneProgressCreateRequest=e.WorkDoneProgress=e.SelectionRangeRequest=e.DeclarationRequest=e.FoldingRangeRefreshRequest=e.FoldingRangeRequest=e.ColorPresentationRequest=e.DocumentColorRequest=e.ConfigurationRequest=e.DidChangeWorkspaceFoldersNotification=e.WorkspaceFoldersRequest=e.TypeDefinitionRequest=e.ImplementationRequest=e.ApplyWorkspaceEditRequest=e.ExecuteCommandRequest=e.PrepareRenameRequest=e.RenameRequest=e.PrepareSupportDefaultBehavior=e.DocumentOnTypeFormattingRequest=e.DocumentRangesFormattingRequest=e.DocumentRangeFormattingRequest=e.DocumentFormattingRequest=e.DocumentLinkResolveRequest=e.DocumentLinkRequest=e.CodeLensRefreshRequest=e.CodeLensResolveRequest=e.CodeLensRequest=e.WorkspaceSymbolResolveRequest=void 0,e.InlineCompletionRequest=e.DidCloseNotebookDocumentNotification=e.DidSaveNotebookDocumentNotification=e.DidChangeNotebookDocumentNotification=e.NotebookCellArrayChange=e.DidOpenNotebookDocumentNotification=e.NotebookDocumentSyncRegistrationType=e.NotebookDocument=e.NotebookCell=e.ExecutionSummary=e.NotebookCellKind=e.DiagnosticRefreshRequest=e.WorkspaceDiagnosticRequest=e.DocumentDiagnosticRequest=e.DocumentDiagnosticReportKind=e.DiagnosticServerCancellationData=e.InlayHintRefreshRequest=e.InlayHintResolveRequest=e.InlayHintRequest=e.InlineValueRefreshRequest=e.InlineValueRequest=e.TypeHierarchySupertypesRequest=e.TypeHierarchySubtypesRequest=e.TypeHierarchyPrepareRequest=void 0;var t=A(),n=(gt(),p(m)),r=Pt(),i=Ft();Object.defineProperty(e,`ImplementationRequest`,{enumerable:!0,get:o(function(){return i.ImplementationRequest},`get`)});var a=It();Object.defineProperty(e,`TypeDefinitionRequest`,{enumerable:!0,get:o(function(){return a.TypeDefinitionRequest},`get`)});var s=Lt();Object.defineProperty(e,`WorkspaceFoldersRequest`,{enumerable:!0,get:o(function(){return s.WorkspaceFoldersRequest},`get`)}),Object.defineProperty(e,`DidChangeWorkspaceFoldersNotification`,{enumerable:!0,get:o(function(){return s.DidChangeWorkspaceFoldersNotification},`get`)});var c=Rt();Object.defineProperty(e,`ConfigurationRequest`,{enumerable:!0,get:o(function(){return c.ConfigurationRequest},`get`)});var l=zt();Object.defineProperty(e,`DocumentColorRequest`,{enumerable:!0,get:o(function(){return l.DocumentColorRequest},`get`)}),Object.defineProperty(e,`ColorPresentationRequest`,{enumerable:!0,get:o(function(){return l.ColorPresentationRequest},`get`)});var u=Bt();Object.defineProperty(e,`FoldingRangeRequest`,{enumerable:!0,get:o(function(){return u.FoldingRangeRequest},`get`)}),Object.defineProperty(e,`FoldingRangeRefreshRequest`,{enumerable:!0,get:o(function(){return u.FoldingRangeRefreshRequest},`get`)});var d=Vt();Object.defineProperty(e,`DeclarationRequest`,{enumerable:!0,get:o(function(){return d.DeclarationRequest},`get`)});var f=Ht();Object.defineProperty(e,`SelectionRangeRequest`,{enumerable:!0,get:o(function(){return f.SelectionRangeRequest},`get`)});var h=Ut();Object.defineProperty(e,`WorkDoneProgress`,{enumerable:!0,get:o(function(){return h.WorkDoneProgress},`get`)}),Object.defineProperty(e,`WorkDoneProgressCreateRequest`,{enumerable:!0,get:o(function(){return h.WorkDoneProgressCreateRequest},`get`)}),Object.defineProperty(e,`WorkDoneProgressCancelNotification`,{enumerable:!0,get:o(function(){return h.WorkDoneProgressCancelNotification},`get`)});var g=Wt();Object.defineProperty(e,`CallHierarchyIncomingCallsRequest`,{enumerable:!0,get:o(function(){return g.CallHierarchyIncomingCallsRequest},`get`)}),Object.defineProperty(e,`CallHierarchyOutgoingCallsRequest`,{enumerable:!0,get:o(function(){return g.CallHierarchyOutgoingCallsRequest},`get`)}),Object.defineProperty(e,`CallHierarchyPrepareRequest`,{enumerable:!0,get:o(function(){return g.CallHierarchyPrepareRequest},`get`)});var _=Gt();Object.defineProperty(e,`TokenFormat`,{enumerable:!0,get:o(function(){return _.TokenFormat},`get`)}),Object.defineProperty(e,`SemanticTokensRequest`,{enumerable:!0,get:o(function(){return _.SemanticTokensRequest},`get`)}),Object.defineProperty(e,`SemanticTokensDeltaRequest`,{enumerable:!0,get:o(function(){return _.SemanticTokensDeltaRequest},`get`)}),Object.defineProperty(e,`SemanticTokensRangeRequest`,{enumerable:!0,get:o(function(){return _.SemanticTokensRangeRequest},`get`)}),Object.defineProperty(e,`SemanticTokensRefreshRequest`,{enumerable:!0,get:o(function(){return _.SemanticTokensRefreshRequest},`get`)}),Object.defineProperty(e,`SemanticTokensRegistrationType`,{enumerable:!0,get:o(function(){return _.SemanticTokensRegistrationType},`get`)});var v=Kt();Object.defineProperty(e,`ShowDocumentRequest`,{enumerable:!0,get:o(function(){return v.ShowDocumentRequest},`get`)});var y=qt();Object.defineProperty(e,`LinkedEditingRangeRequest`,{enumerable:!0,get:o(function(){return y.LinkedEditingRangeRequest},`get`)});var b=Jt();Object.defineProperty(e,`FileOperationPatternKind`,{enumerable:!0,get:o(function(){return b.FileOperationPatternKind},`get`)}),Object.defineProperty(e,`DidCreateFilesNotification`,{enumerable:!0,get:o(function(){return b.DidCreateFilesNotification},`get`)}),Object.defineProperty(e,`WillCreateFilesRequest`,{enumerable:!0,get:o(function(){return b.WillCreateFilesRequest},`get`)}),Object.defineProperty(e,`DidRenameFilesNotification`,{enumerable:!0,get:o(function(){return b.DidRenameFilesNotification},`get`)}),Object.defineProperty(e,`WillRenameFilesRequest`,{enumerable:!0,get:o(function(){return b.WillRenameFilesRequest},`get`)}),Object.defineProperty(e,`DidDeleteFilesNotification`,{enumerable:!0,get:o(function(){return b.DidDeleteFilesNotification},`get`)}),Object.defineProperty(e,`WillDeleteFilesRequest`,{enumerable:!0,get:o(function(){return b.WillDeleteFilesRequest},`get`)});var x=Yt();Object.defineProperty(e,`UniquenessLevel`,{enumerable:!0,get:o(function(){return x.UniquenessLevel},`get`)}),Object.defineProperty(e,`MonikerKind`,{enumerable:!0,get:o(function(){return x.MonikerKind},`get`)}),Object.defineProperty(e,`MonikerRequest`,{enumerable:!0,get:o(function(){return x.MonikerRequest},`get`)});var ee=Xt();Object.defineProperty(e,`TypeHierarchyPrepareRequest`,{enumerable:!0,get:o(function(){return ee.TypeHierarchyPrepareRequest},`get`)}),Object.defineProperty(e,`TypeHierarchySubtypesRequest`,{enumerable:!0,get:o(function(){return ee.TypeHierarchySubtypesRequest},`get`)}),Object.defineProperty(e,`TypeHierarchySupertypesRequest`,{enumerable:!0,get:o(function(){return ee.TypeHierarchySupertypesRequest},`get`)});var S=Zt();Object.defineProperty(e,`InlineValueRequest`,{enumerable:!0,get:o(function(){return S.InlineValueRequest},`get`)}),Object.defineProperty(e,`InlineValueRefreshRequest`,{enumerable:!0,get:o(function(){return S.InlineValueRefreshRequest},`get`)});var te=Qt();Object.defineProperty(e,`InlayHintRequest`,{enumerable:!0,get:o(function(){return te.InlayHintRequest},`get`)}),Object.defineProperty(e,`InlayHintResolveRequest`,{enumerable:!0,get:o(function(){return te.InlayHintResolveRequest},`get`)}),Object.defineProperty(e,`InlayHintRefreshRequest`,{enumerable:!0,get:o(function(){return te.InlayHintRefreshRequest},`get`)});var ne=$t();Object.defineProperty(e,`DiagnosticServerCancellationData`,{enumerable:!0,get:o(function(){return ne.DiagnosticServerCancellationData},`get`)}),Object.defineProperty(e,`DocumentDiagnosticReportKind`,{enumerable:!0,get:o(function(){return ne.DocumentDiagnosticReportKind},`get`)}),Object.defineProperty(e,`DocumentDiagnosticRequest`,{enumerable:!0,get:o(function(){return ne.DocumentDiagnosticRequest},`get`)}),Object.defineProperty(e,`WorkspaceDiagnosticRequest`,{enumerable:!0,get:o(function(){return ne.WorkspaceDiagnosticRequest},`get`)}),Object.defineProperty(e,`DiagnosticRefreshRequest`,{enumerable:!0,get:o(function(){return ne.DiagnosticRefreshRequest},`get`)});var C=en();Object.defineProperty(e,`NotebookCellKind`,{enumerable:!0,get:o(function(){return C.NotebookCellKind},`get`)}),Object.defineProperty(e,`ExecutionSummary`,{enumerable:!0,get:o(function(){return C.ExecutionSummary},`get`)}),Object.defineProperty(e,`NotebookCell`,{enumerable:!0,get:o(function(){return C.NotebookCell},`get`)}),Object.defineProperty(e,`NotebookDocument`,{enumerable:!0,get:o(function(){return C.NotebookDocument},`get`)}),Object.defineProperty(e,`NotebookDocumentSyncRegistrationType`,{enumerable:!0,get:o(function(){return C.NotebookDocumentSyncRegistrationType},`get`)}),Object.defineProperty(e,`DidOpenNotebookDocumentNotification`,{enumerable:!0,get:o(function(){return C.DidOpenNotebookDocumentNotification},`get`)}),Object.defineProperty(e,`NotebookCellArrayChange`,{enumerable:!0,get:o(function(){return C.NotebookCellArrayChange},`get`)}),Object.defineProperty(e,`DidChangeNotebookDocumentNotification`,{enumerable:!0,get:o(function(){return C.DidChangeNotebookDocumentNotification},`get`)}),Object.defineProperty(e,`DidSaveNotebookDocumentNotification`,{enumerable:!0,get:o(function(){return C.DidSaveNotebookDocumentNotification},`get`)}),Object.defineProperty(e,`DidCloseNotebookDocumentNotification`,{enumerable:!0,get:o(function(){return C.DidCloseNotebookDocumentNotification},`get`)});var re=tn();Object.defineProperty(e,`InlineCompletionRequest`,{enumerable:!0,get:o(function(){return re.InlineCompletionRequest},`get`)});var ie;(function(e){function t(e){let t=e;return r.string(t)||r.string(t.language)||r.string(t.scheme)||r.string(t.pattern)}o(t,`is`),e.is=t})(ie||(e.TextDocumentFilter=ie={}));var ae;(function(e){function t(e){let t=e;return r.objectLiteral(t)&&(r.string(t.notebookType)||r.string(t.scheme)||r.string(t.pattern))}o(t,`is`),e.is=t})(ae||(e.NotebookDocumentFilter=ae={}));var oe;(function(e){function t(e){let t=e;return r.objectLiteral(t)&&(r.string(t.notebook)||ae.is(t.notebook))&&(t.language===void 0||r.string(t.language))}o(t,`is`),e.is=t})(oe||(e.NotebookCellTextDocumentFilter=oe={}));var se;(function(e){function t(e){if(!Array.isArray(e))return!1;for(let t of e)if(!r.string(t)&&!ie.is(t)&&!oe.is(t))return!1;return!0}o(t,`is`),e.is=t})(se||(e.DocumentSelector=se={}));var ce;(function(e){e.method=`client/registerCapability`,e.messageDirection=t.MessageDirection.serverToClient,e.type=new t.ProtocolRequestType(e.method)})(ce||(e.RegistrationRequest=ce={}));var le;(function(e){e.method=`client/unregisterCapability`,e.messageDirection=t.MessageDirection.serverToClient,e.type=new t.ProtocolRequestType(e.method)})(le||(e.UnregistrationRequest=le={}));var ue;(function(e){e.Create=`create`,e.Rename=`rename`,e.Delete=`delete`})(ue||(e.ResourceOperationKind=ue={}));var de;(function(e){e.Abort=`abort`,e.Transactional=`transactional`,e.TextOnlyTransactional=`textOnlyTransactional`,e.Undo=`undo`})(de||(e.FailureHandlingKind=de={}));var w;(function(e){e.UTF8=`utf-8`,e.UTF16=`utf-16`,e.UTF32=`utf-32`})(w||(e.PositionEncodingKind=w={}));var T;(function(e){function t(e){let t=e;return t&&r.string(t.id)&&t.id.length>0}o(t,`hasId`),e.hasId=t})(T||(e.StaticRegistrationOptions=T={}));var fe;(function(e){function t(e){let t=e;return t&&(t.documentSelector===null||se.is(t.documentSelector))}o(t,`is`),e.is=t})(fe||(e.TextDocumentRegistrationOptions=fe={}));var E;(function(e){function t(e){let t=e;return r.objectLiteral(t)&&(t.workDoneProgress===void 0||r.boolean(t.workDoneProgress))}o(t,`is`),e.is=t;function n(e){let t=e;return t&&r.boolean(t.workDoneProgress)}o(n,`hasWorkDoneProgress`),e.hasWorkDoneProgress=n})(E||(e.WorkDoneProgressOptions=E={}));var D;(function(e){e.method=`initialize`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(D||(e.InitializeRequest=D={}));var pe;(function(e){e.unknownProtocolVersion=1})(pe||(e.InitializeErrorCodes=pe={}));var O;(function(e){e.method=`initialized`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolNotificationType(e.method)})(O||(e.InitializedNotification=O={}));var me;(function(e){e.method=`shutdown`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType0(e.method)})(me||(e.ShutdownRequest=me={}));var he;(function(e){e.method=`exit`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolNotificationType0(e.method)})(he||(e.ExitNotification=he={}));var ge;(function(e){e.method=`workspace/didChangeConfiguration`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolNotificationType(e.method)})(ge||(e.DidChangeConfigurationNotification=ge={}));var _e;(function(e){e.Error=1,e.Warning=2,e.Info=3,e.Log=4,e.Debug=5})(_e||(e.MessageType=_e={}));var ve;(function(e){e.method=`window/showMessage`,e.messageDirection=t.MessageDirection.serverToClient,e.type=new t.ProtocolNotificationType(e.method)})(ve||(e.ShowMessageNotification=ve={}));var ye;(function(e){e.method=`window/showMessageRequest`,e.messageDirection=t.MessageDirection.serverToClient,e.type=new t.ProtocolRequestType(e.method)})(ye||(e.ShowMessageRequest=ye={}));var be;(function(e){e.method=`window/logMessage`,e.messageDirection=t.MessageDirection.serverToClient,e.type=new t.ProtocolNotificationType(e.method)})(be||(e.LogMessageNotification=be={}));var xe;(function(e){e.method=`telemetry/event`,e.messageDirection=t.MessageDirection.serverToClient,e.type=new t.ProtocolNotificationType(e.method)})(xe||(e.TelemetryEventNotification=xe={}));var Se;(function(e){e.None=0,e.Full=1,e.Incremental=2})(Se||(e.TextDocumentSyncKind=Se={}));var Ce;(function(e){e.method=`textDocument/didOpen`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolNotificationType(e.method)})(Ce||(e.DidOpenTextDocumentNotification=Ce={}));var we;(function(e){function t(e){let t=e;return t!=null&&typeof t.text==`string`&&t.range!==void 0&&(t.rangeLength===void 0||typeof t.rangeLength==`number`)}o(t,`isIncremental`),e.isIncremental=t;function n(e){let t=e;return t!=null&&typeof t.text==`string`&&t.range===void 0&&t.rangeLength===void 0}o(n,`isFull`),e.isFull=n})(we||(e.TextDocumentContentChangeEvent=we={}));var Te;(function(e){e.method=`textDocument/didChange`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolNotificationType(e.method)})(Te||(e.DidChangeTextDocumentNotification=Te={}));var Ee;(function(e){e.method=`textDocument/didClose`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolNotificationType(e.method)})(Ee||(e.DidCloseTextDocumentNotification=Ee={}));var De;(function(e){e.method=`textDocument/didSave`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolNotificationType(e.method)})(De||(e.DidSaveTextDocumentNotification=De={}));var Oe;(function(e){e.Manual=1,e.AfterDelay=2,e.FocusOut=3})(Oe||(e.TextDocumentSaveReason=Oe={}));var ke;(function(e){e.method=`textDocument/willSave`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolNotificationType(e.method)})(ke||(e.WillSaveTextDocumentNotification=ke={}));var Ae;(function(e){e.method=`textDocument/willSaveWaitUntil`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(Ae||(e.WillSaveTextDocumentWaitUntilRequest=Ae={}));var je;(function(e){e.method=`workspace/didChangeWatchedFiles`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolNotificationType(e.method)})(je||(e.DidChangeWatchedFilesNotification=je={}));var Me;(function(e){e.Created=1,e.Changed=2,e.Deleted=3})(Me||(e.FileChangeType=Me={}));var Ne;(function(e){function t(e){let t=e;return r.objectLiteral(t)&&(n.URI.is(t.baseUri)||n.WorkspaceFolder.is(t.baseUri))&&r.string(t.pattern)}o(t,`is`),e.is=t})(Ne||(e.RelativePattern=Ne={}));var Pe;(function(e){e.Create=1,e.Change=2,e.Delete=4})(Pe||(e.WatchKind=Pe={}));var Fe;(function(e){e.method=`textDocument/publishDiagnostics`,e.messageDirection=t.MessageDirection.serverToClient,e.type=new t.ProtocolNotificationType(e.method)})(Fe||(e.PublishDiagnosticsNotification=Fe={}));var Ie;(function(e){e.Invoked=1,e.TriggerCharacter=2,e.TriggerForIncompleteCompletions=3})(Ie||(e.CompletionTriggerKind=Ie={}));var Le;(function(e){e.method=`textDocument/completion`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(Le||(e.CompletionRequest=Le={}));var Re;(function(e){e.method=`completionItem/resolve`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(Re||(e.CompletionResolveRequest=Re={}));var ze;(function(e){e.method=`textDocument/hover`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(ze||(e.HoverRequest=ze={}));var Be;(function(e){e.Invoked=1,e.TriggerCharacter=2,e.ContentChange=3})(Be||(e.SignatureHelpTriggerKind=Be={}));var Ve;(function(e){e.method=`textDocument/signatureHelp`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(Ve||(e.SignatureHelpRequest=Ve={}));var He;(function(e){e.method=`textDocument/definition`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(He||(e.DefinitionRequest=He={}));var Ue;(function(e){e.method=`textDocument/references`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(Ue||(e.ReferencesRequest=Ue={}));var We;(function(e){e.method=`textDocument/documentHighlight`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(We||(e.DocumentHighlightRequest=We={}));var Ge;(function(e){e.method=`textDocument/documentSymbol`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(Ge||(e.DocumentSymbolRequest=Ge={}));var Ke;(function(e){e.method=`textDocument/codeAction`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(Ke||(e.CodeActionRequest=Ke={}));var qe;(function(e){e.method=`codeAction/resolve`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(qe||(e.CodeActionResolveRequest=qe={}));var Je;(function(e){e.method=`workspace/symbol`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(Je||(e.WorkspaceSymbolRequest=Je={}));var Ye;(function(e){e.method=`workspaceSymbol/resolve`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(Ye||(e.WorkspaceSymbolResolveRequest=Ye={}));var Xe;(function(e){e.method=`textDocument/codeLens`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(Xe||(e.CodeLensRequest=Xe={}));var Ze;(function(e){e.method=`codeLens/resolve`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(Ze||(e.CodeLensResolveRequest=Ze={}));var Qe;(function(e){e.method=`workspace/codeLens/refresh`,e.messageDirection=t.MessageDirection.serverToClient,e.type=new t.ProtocolRequestType0(e.method)})(Qe||(e.CodeLensRefreshRequest=Qe={}));var $e;(function(e){e.method=`textDocument/documentLink`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})($e||(e.DocumentLinkRequest=$e={}));var et;(function(e){e.method=`documentLink/resolve`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(et||(e.DocumentLinkResolveRequest=et={}));var tt;(function(e){e.method=`textDocument/formatting`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(tt||(e.DocumentFormattingRequest=tt={}));var nt;(function(e){e.method=`textDocument/rangeFormatting`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(nt||(e.DocumentRangeFormattingRequest=nt={}));var rt;(function(e){e.method=`textDocument/rangesFormatting`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(rt||(e.DocumentRangesFormattingRequest=rt={}));var it;(function(e){e.method=`textDocument/onTypeFormatting`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(it||(e.DocumentOnTypeFormattingRequest=it={}));var at;(function(e){e.Identifier=1})(at||(e.PrepareSupportDefaultBehavior=at={}));var ot;(function(e){e.method=`textDocument/rename`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(ot||(e.RenameRequest=ot={}));var st;(function(e){e.method=`textDocument/prepareRename`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(st||(e.PrepareRenameRequest=st={}));var ct;(function(e){e.method=`workspace/executeCommand`,e.messageDirection=t.MessageDirection.clientToServer,e.type=new t.ProtocolRequestType(e.method)})(ct||(e.ExecuteCommandRequest=ct={}));var lt;(function(e){e.method=`workspace/applyEdit`,e.messageDirection=t.MessageDirection.serverToClient,e.type=new t.ProtocolRequestType(`workspace/applyEdit`)})(lt||(e.ApplyWorkspaceEditRequest=lt={}))}}),rn=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/connection.js"(e){Object.defineProperty(e,`__esModule`,{value:!0}),e.createProtocolConnection=void 0;var t=Mt();function n(e,n,r,i){return t.ConnectionStrategy.is(i)&&(i={connectionStrategy:i}),(0,t.createMessageConnection)(e,n,r,i)}o(n,`createProtocolConnection`),e.createProtocolConnection=n}}),an=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/api.js"(e){var t=e&&e.__createBinding||(Object.create?(function(e,t,n,r){r===void 0&&(r=n);var i=Object.getOwnPropertyDescriptor(t,n);(!i||(`get`in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:o(function(){return t[n]},`get`)}),Object.defineProperty(e,r,i)}):(function(e,t,n,r){r===void 0&&(r=n),e[r]=t[n]})),n=e&&e.__exportStar||function(e,n){for(var r in e)r!==`default`&&!Object.prototype.hasOwnProperty.call(n,r)&&t(n,e,r)};Object.defineProperty(e,`__esModule`,{value:!0}),e.LSPErrorCodes=e.createProtocolConnection=void 0,n(Mt(),e),n((gt(),p(m)),e),n(A(),e),n(nn(),e);var r=rn();Object.defineProperty(e,`createProtocolConnection`,{enumerable:!0,get:o(function(){return r.createProtocolConnection},`get`)});var i;(function(e){e.lspReservedErrorRangeStart=-32899,e.RequestFailed=-32803,e.ServerCancelled=-32802,e.ContentModified=-32801,e.RequestCancelled=-32800,e.lspReservedErrorRangeEnd=-32800})(i||(e.LSPErrorCodes=i={}))}}),on=c({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/browser/main.js"(e){var t=e&&e.__createBinding||(Object.create?(function(e,t,n,r){r===void 0&&(r=n);var i=Object.getOwnPropertyDescriptor(t,n);(!i||(`get`in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:o(function(){return t[n]},`get`)}),Object.defineProperty(e,r,i)}):(function(e,t,n,r){r===void 0&&(r=n),e[r]=t[n]})),n=e&&e.__exportStar||function(e,n){for(var r in e)r!==`default`&&!Object.prototype.hasOwnProperty.call(n,r)&&t(n,e,r)};Object.defineProperty(e,`__esModule`,{value:!0}),e.createProtocolConnection=void 0;var r=Nt();n(Nt(),e),n(an(),e);function i(e,t,n,i){return(0,r.createMessageConnection)(e,t,n,i)}o(i,`createProtocolConnection`),e.createProtocolConnection=i}}),sn={};l(sn,{AbstractAstReflection:()=>pn,AbstractCstNode:()=>$A,AbstractLangiumParser:()=>cj,AbstractParserErrorMessageProvider:()=>uj,AbstractThreadedAsyncParser:()=>jN,AstUtils:()=>wn,BiMap:()=>mM,Cancellation:()=>Z,CompositeCstNodeImpl:()=>tj,ContextCache:()=>SM,CstNodeBuilder:()=>QA,CstUtils:()=>cn,DEFAULT_TOKENIZE_OPTIONS:()=>XM,DONE_RESULT:()=>xn,DatatypeSymbol:()=>ij,DefaultAstNodeDescriptionProvider:()=>zM,DefaultAstNodeLocator:()=>VM,DefaultAsyncParser:()=>AN,DefaultCommentProvider:()=>kN,DefaultConfigurationProvider:()=>UM,DefaultDocumentBuilder:()=>KM,DefaultDocumentValidator:()=>PM,DefaultHydrator:()=>PN,DefaultIndexManager:()=>qM,DefaultJsonSerializer:()=>OM,DefaultLangiumDocumentFactory:()=>oM,DefaultLangiumDocuments:()=>sM,DefaultLangiumProfiler:()=>nP,DefaultLexer:()=>ZM,DefaultLexerErrorMessageProvider:()=>YM,DefaultLinker:()=>lM,DefaultNameProvider:()=>dM,DefaultReferenceDescriptionProvider:()=>BM,DefaultReferences:()=>fM,DefaultScopeComputation:()=>hM,DefaultScopeProvider:()=>TM,DefaultServiceRegistry:()=>kM,DefaultTokenBuilder:()=>Lj,DefaultValueConverter:()=>Rj,DefaultWorkspaceLock:()=>NN,DefaultWorkspaceManager:()=>JM,Deferred:()=>qj,Disposable:()=>GM,DisposableCache:()=>bM,DocumentCache:()=>CM,DocumentState:()=>$,DocumentValidator:()=>RM,EMPTY_SCOPE:()=>yM,EMPTY_STREAM:()=>bn,EmptyFileSystem:()=>ZN,EmptyFileSystemProvider:()=>XN,ErrorWithLocation:()=>aa,GrammarAST:()=>zn,GrammarUtils:()=>ia,IndentationAwareLexer:()=>JN,IndentationAwareTokenBuilder:()=>qN,JSDocDocumentationProvider:()=>ON,LangiumCompletionParser:()=>fj,LangiumParser:()=>lj,LangiumParserErrorMessageProvider:()=>dj,LeafCstNodeImpl:()=>ej,LexingMode:()=>KN,MapScope:()=>_M,Module:()=>LN,MultiMap:()=>pM,MultiMapScope:()=>vM,OperationCancelled:()=>Gj,ParserWorker:()=>MN,ProfilingTask:()=>rP,Reduction:()=>Cn,RefResolving:()=>cM,RegExpUtils:()=>ca,RootCstNodeImpl:()=>rj,SimpleCache:()=>xM,StreamImpl:()=>_n,StreamScope:()=>gM,TextDocument:()=>Yj,TreeStreamImpl:()=>Sn,URI:()=>nM,UriTrie:()=>aM,UriUtils:()=>iM,VALIDATE_EACH_NODE:()=>NM,ValidationCategory:()=>jM,ValidationRegistry:()=>MM,ValueConverter:()=>zj,WorkspaceCache:()=>wM,assertCondition:()=>sa,assertUnreachable:()=>oa,createCompletionParser:()=>Pj,createDefaultCoreModule:()=>FN,createDefaultSharedCoreModule:()=>IN,createGrammarConfig:()=>vo,createLangiumParser:()=>Fj,createParser:()=>gj,delayNextTick:()=>Bj,diagnosticData:()=>AM,eagerLoad:()=>BN,getDiagnosticRange:()=>FM,indentationBuilderDefaultOptions:()=>GN,inject:()=>RN,interruptAndCheck:()=>Q,isAstNode:()=>j,isAstNodeDescription:()=>dn,isAstNodeWithComment:()=>EM,isCompositeCstNode:()=>mn,isIMultiModeLexerDefinition:()=>$M,isJSDoc:()=>nN,isLeafCstNode:()=>hn,isLinkingError:()=>fn,isMultiReference:()=>un,isNamed:()=>uM,isOperationCancelled:()=>Kj,isReference:()=>ln,isRootCstNode:()=>gn,isTokenTypeArray:()=>QM,isTokenTypeDictionary:()=>eN,loadGrammarFromJson:()=>tP,parseJSDoc:()=>tN,prepareLangiumParser:()=>Ij,setInterruptionPeriod:()=>Wj,startCancelableOperation:()=>Uj,stream:()=>M,toDiagnosticData:()=>LM,toDiagnosticSeverity:()=>IM});var cn={};l(cn,{DefaultNameRegexp:()=>Gi,RangeComparison:()=>Hi,compareRange:()=>Ui,findCommentNode:()=>qi,findDeclarationNodeAtOffset:()=>Ki,findLeafNodeAtOffset:()=>Yi,findLeafNodeBeforeOffset:()=>Xi,flattenCst:()=>Ri,getDatatypeNode:()=>Ii,getInteriorNodes:()=>ta,getNextNode:()=>$i,getPreviousNode:()=>Qi,getStartlineNode:()=>ea,inRange:()=>Wi,isChildNode:()=>zi,isCommentNode:()=>Ji,streamCst:()=>Li,toDocumentSegment:()=>Vi,tokenToRange:()=>Bi});function j(e){return typeof e==`object`&&!!e&&typeof e.$type==`string`}o(j,`isAstNode`);function ln(e){return typeof e==`object`&&!!e&&typeof e.$refText==`string`&&`ref`in e}o(ln,`isReference`);function un(e){return typeof e==`object`&&!!e&&typeof e.$refText==`string`&&`items`in e}o(un,`isMultiReference`);function dn(e){return typeof e==`object`&&!!e&&typeof e.name==`string`&&typeof e.type==`string`&&typeof e.path==`string`}o(dn,`isAstNodeDescription`);function fn(e){return typeof e==`object`&&!!e&&typeof e.info==`object`&&typeof e.message==`string`}o(fn,`isLinkingError`);var pn=class{static{o(this,`AbstractAstReflection`)}constructor(){this.subtypes={},this.allSubtypes={}}getAllTypes(){return Object.keys(this.types)}getReferenceType(e){let t=this.types[e.container.$type];if(!t)throw Error(`Type ${e.container.$type||`undefined`} not found.`);let n=t.properties[e.property]?.referenceType;if(!n)throw Error(`Property ${e.property||`undefined`} of type ${e.container.$type} is not a reference.`);return n}getTypeMetaData(e){return this.types[e]||{name:e,properties:{},superTypes:[]}}isInstance(e,t){return j(e)&&this.isSubtype(e.$type,t)}isSubtype(e,t){if(e===t)return!0;let n=this.subtypes[e];n||=this.subtypes[e]={};let r=n[t];if(r!==void 0)return r;{let r=this.types[e],i=r?r.superTypes.some(e=>this.isSubtype(e,t)):!1;return n[t]=i,i}}getAllSubTypes(e){let t=this.allSubtypes[e];if(t)return t;{let t=this.getAllTypes(),n=[];for(let r of t)this.isSubtype(r,e)&&n.push(r);return this.allSubtypes[e]=n,n}}};function mn(e){return typeof e==`object`&&!!e&&Array.isArray(e.content)}o(mn,`isCompositeCstNode`);function hn(e){return typeof e==`object`&&!!e&&typeof e.tokenType==`object`}o(hn,`isLeafCstNode`);function gn(e){return mn(e)&&typeof e.fullText==`string`}o(gn,`isRootCstNode`);var _n=class e{static{o(this,`StreamImpl`)}constructor(e,t){this.startFn=e,this.nextFn=t}iterator(){let e={state:this.startFn(),next:o(()=>this.nextFn(e.state),`next`),[Symbol.iterator]:()=>e};return e}[Symbol.iterator](){return this.iterator()}isEmpty(){return!!this.iterator().next().done}count(){let e=this.iterator(),t=0,n=e.next();for(;!n.done;)t++,n=e.next();return t}toArray(){let e=[],t=this.iterator(),n;do n=t.next(),n.value!==void 0&&e.push(n.value);while(!n.done);return e}toSet(){return new Set(this)}toMap(e,t){let n=this.map(n=>[e?e(n):n,t?t(n):n]);return new Map(n)}toString(){return this.join()}concat(t){return new e(()=>({first:this.startFn(),firstDone:!1,iterator:t[Symbol.iterator]()}),e=>{let t;if(!e.firstDone){do if(t=this.nextFn(e.first),!t.done)return t;while(!t.done);e.firstDone=!0}do if(t=e.iterator.next(),!t.done)return t;while(!t.done);return xn})}join(e=`,`){let t=this.iterator(),n=``,r,i=!1;do r=t.next(),r.done||(i&&(n+=e),n+=vn(r.value)),i=!0;while(!r.done);return n}indexOf(e,t=0){let n=this.iterator(),r=0,i=n.next();for(;!i.done;){if(r>=t&&i.value===e)return r;i=n.next(),r++}return-1}every(e){let t=this.iterator(),n=t.next();for(;!n.done;){if(!e(n.value))return!1;n=t.next()}return!0}some(e){let t=this.iterator(),n=t.next();for(;!n.done;){if(e(n.value))return!0;n=t.next()}return!1}forEach(e){let t=this.iterator(),n=0,r=t.next();for(;!r.done;)e(r.value,n),r=t.next(),n++}map(t){return new e(this.startFn,e=>{let{done:n,value:r}=this.nextFn(e);return n?xn:{done:!1,value:t(r)}})}filter(t){return new e(this.startFn,e=>{let n;do if(n=this.nextFn(e),!n.done&&t(n.value))return n;while(!n.done);return xn})}nonNullable(){return this.filter(e=>e!=null)}reduce(e,t){let n=this.iterator(),r=t,i=n.next();for(;!i.done;)r=r===void 0?i.value:e(r,i.value),i=n.next();return r}reduceRight(e,t){return this.recursiveReduce(this.iterator(),e,t)}recursiveReduce(e,t,n){let r=e.next();if(r.done)return n;let i=this.recursiveReduce(e,t,n);return i===void 0?r.value:t(i,r.value)}find(e){let t=this.iterator(),n=t.next();for(;!n.done;){if(e(n.value))return n.value;n=t.next()}}findIndex(e){let t=this.iterator(),n=0,r=t.next();for(;!r.done;){if(e(r.value))return n;r=t.next(),n++}return-1}includes(e){let t=this.iterator(),n=t.next();for(;!n.done;){if(n.value===e)return!0;n=t.next()}return!1}flatMap(t){return new e(()=>({this:this.startFn()}),e=>{do{if(e.iterator){let t=e.iterator.next();if(t.done)e.iterator=void 0;else return t}let{done:n,value:r}=this.nextFn(e.this);if(!n){let n=t(r);if(yn(n))e.iterator=n[Symbol.iterator]();else return{done:!1,value:n}}}while(e.iterator);return xn})}flat(t){if(t===void 0&&(t=1),t<=0)return this;let n=t>1?this.flat(t-1):this;return new e(()=>({this:n.startFn()}),e=>{do{if(e.iterator){let t=e.iterator.next();if(t.done)e.iterator=void 0;else return t}let{done:t,value:r}=n.nextFn(e.this);if(!t)if(yn(r))e.iterator=r[Symbol.iterator]();else return{done:!1,value:r}}while(e.iterator);return xn})}head(){let e=this.iterator().next();if(!e.done)return e.value}tail(t=1){return new e(()=>{let e=this.startFn();for(let n=0;n<t;n++)if(this.nextFn(e).done)return e;return e},this.nextFn)}limit(t){return new e(()=>({size:0,state:this.startFn()}),e=>(e.size++,e.size>t?xn:this.nextFn(e.state)))}distinct(t){return new e(()=>({set:new Set,internalState:this.startFn()}),e=>{let n;do if(n=this.nextFn(e.internalState),!n.done){let r=t?t(n.value):n.value;if(!e.set.has(r))return e.set.add(r),n}while(!n.done);return xn})}exclude(e,t){let n=new Set;for(let r of e){let e=t?t(r):r;n.add(e)}return this.filter(e=>{let r=t?t(e):e;return!n.has(r)})}};function vn(e){return typeof e==`string`?e:e===void 0?`undefined`:typeof e.toString==`function`?e.toString():Object.prototype.toString.call(e)}o(vn,`toString`);function yn(e){return!!e&&typeof e[Symbol.iterator]==`function`}o(yn,`isIterable`);var bn=new _n(()=>void 0,()=>xn),xn=Object.freeze({done:!0,value:void 0});function M(...e){if(e.length===1){let t=e[0];if(t instanceof _n)return t;if(yn(t))return new _n(()=>t[Symbol.iterator](),e=>e.next());if(typeof t.length==`number`)return new _n(()=>({index:0}),e=>e.index<t.length?{done:!1,value:t[e.index++]}:xn)}return e.length>1?new _n(()=>({collIndex:0,arrIndex:0}),t=>{do{if(t.iterator){let e=t.iterator.next();if(!e.done)return e;t.iterator=void 0}if(t.array){if(t.arrIndex<t.array.length)return{done:!1,value:t.array[t.arrIndex++]};t.array=void 0,t.arrIndex=0}if(t.collIndex<e.length){let n=e[t.collIndex++];yn(n)?t.iterator=n[Symbol.iterator]():n&&typeof n.length==`number`&&(t.array=n)}}while(t.iterator||t.array||t.collIndex<e.length);return xn}):bn}o(M,`stream`);var Sn=class extends _n{static{o(this,`TreeStreamImpl`)}constructor(e,t,n){super(()=>({iterators:n?.includeRoot?[[e][Symbol.iterator]()]:[t(e)[Symbol.iterator]()],pruned:!1}),e=>{for(e.pruned&&=(e.iterators.pop(),!1);e.iterators.length>0;){let n=e.iterators[e.iterators.length-1].next();if(n.done)e.iterators.pop();else return e.iterators.push(t(n.value)[Symbol.iterator]()),n}return xn})}iterator(){let e={state:this.startFn(),next:o(()=>this.nextFn(e.state),`next`),prune:o(()=>{e.state.pruned=!0},`prune`),[Symbol.iterator]:()=>e};return e}},Cn;(function(e){function t(e){return e.reduce((e,t)=>e+t,0)}o(t,`sum`),e.sum=t;function n(e){return e.reduce((e,t)=>e*t,0)}o(n,`product`),e.product=n;function r(e){return e.reduce((e,t)=>Math.min(e,t))}o(r,`min`),e.min=r;function i(e){return e.reduce((e,t)=>Math.max(e,t))}o(i,`max`),e.max=i})(Cn||={});var wn={};l(wn,{assignMandatoryProperties:()=>In,copyAstNode:()=>Rn,findRootNode:()=>kn,getContainerOfType:()=>En,getDocument:()=>On,getReferenceNodes:()=>An,hasContainerOfType:()=>Dn,linkContentToContainer:()=>Tn,streamAllContents:()=>Mn,streamAst:()=>Nn,streamContents:()=>jn,streamReferences:()=>Fn});function Tn(e,t={}){for(let[n,r]of Object.entries(e))n.startsWith(`$`)||(Array.isArray(r)?r.forEach((r,i)=>{j(r)&&(r.$container=e,r.$containerProperty=n,r.$containerIndex=i,t.deep&&Tn(r,t))}):j(r)&&(r.$container=e,r.$containerProperty=n,t.deep&&Tn(r,t)))}o(Tn,`linkContentToContainer`);function En(e,t){let n=e;for(;n;){if(t(n))return n;n=n.$container}}o(En,`getContainerOfType`);function Dn(e,t){let n=e;for(;n;){if(t(n))return!0;n=n.$container}return!1}o(Dn,`hasContainerOfType`);function On(e){let t=kn(e).$document;if(!t)throw Error(`AST node has no document.`);return t}o(On,`getDocument`);function kn(e){for(;e.$container;)e=e.$container;return e}o(kn,`findRootNode`);function An(e){return ln(e)?e.ref?[e.ref]:[]:un(e)?e.items.map(e=>e.ref):[]}o(An,`getReferenceNodes`);function jn(e,t){if(!e)throw Error(`Node must be an AstNode.`);let n=t?.range;return new _n(()=>({keys:Object.keys(e),keyIndex:0,arrayIndex:0}),t=>{for(;t.keyIndex<t.keys.length;){let r=t.keys[t.keyIndex];if(!r.startsWith(`$`)){let i=e[r];if(j(i)){if(t.keyIndex++,Pn(i,n))return{done:!1,value:i}}else if(Array.isArray(i)){for(;t.arrayIndex<i.length;){let e=i[t.arrayIndex++];if(j(e)&&Pn(e,n))return{done:!1,value:e}}t.arrayIndex=0}}t.keyIndex++}return xn})}o(jn,`streamContents`);function Mn(e,t){if(!e)throw Error(`Root node must be an AstNode.`);return new Sn(e,e=>jn(e,t))}o(Mn,`streamAllContents`);function Nn(e,t){if(!e)throw Error(`Root node must be an AstNode.`);return t?.range&&!Pn(e,t.range)?new Sn(e,()=>[]):new Sn(e,e=>jn(e,t),{includeRoot:!0})}o(Nn,`streamAst`);function Pn(e,t){if(!t)return!0;let n=e.$cstNode?.range;return n?Wi(n,t):!1}o(Pn,`isAstNodeInRange`);function Fn(e){return new _n(()=>({keys:Object.keys(e),keyIndex:0,arrayIndex:0}),t=>{for(;t.keyIndex<t.keys.length;){let n=t.keys[t.keyIndex];if(!n.startsWith(`$`)){let r=e[n];if(ln(r)||un(r))return t.keyIndex++,{done:!1,value:{reference:r,container:e,property:n}};if(Array.isArray(r)){for(;t.arrayIndex<r.length;){let i=t.arrayIndex++,a=r[i];if(ln(a)||un(r))return{done:!1,value:{reference:a,container:e,property:n,index:i}}}t.arrayIndex=0}}t.keyIndex++}return xn})}o(Fn,`streamReferences`);function In(e,t){let n=e.getTypeMetaData(t.$type),r=t;for(let e of Object.values(n.properties))e.defaultValue!==void 0&&r[e.name]===void 0&&(r[e.name]=Ln(e.defaultValue))}o(In,`assignMandatoryProperties`);function Ln(e){return Array.isArray(e)?[...e.map(Ln)]:e}o(Ln,`copyDefaultValue`);function Rn(e,t,n){let r={$type:e.$type};n&&(n.set(e,r),n.set(r,e));for(let[i,a]of Object.entries(e))if(!i.startsWith(`$`))if(j(a))r[i]=Rn(a,t,n);else if(ln(a))r[i]=t(r,i,a.$refNode,a.$refText,a);else if(Array.isArray(a)){let e=[];for(let o of a)j(o)?e.push(Rn(o,t,n)):ln(o)?e.push(t(r,i,o.$refNode,o.$refText,o)):e.push(o);r[i]=e}else r[i]=a;return Tn(r,{deep:!0}),r}o(Rn,`copyAstNode`);var zn={};l(zn,{AbstractElement:()=>Vn,AbstractParserRule:()=>Un,AbstractRule:()=>Gn,AbstractType:()=>qn,Action:()=>Yn,Alternatives:()=>Zn,ArrayLiteral:()=>$n,ArrayType:()=>tr,Assignment:()=>rr,BooleanLiteral:()=>ar,CharacterRange:()=>sr,Condition:()=>lr,Conjunction:()=>dr,CrossReference:()=>pr,Disjunction:()=>hr,EndOfFile:()=>_r,Grammar:()=>yr,GrammarImport:()=>xr,Group:()=>Cr,InferredType:()=>Tr,InfixRule:()=>Dr,InfixRuleOperatorList:()=>kr,InfixRuleOperators:()=>jr,Interface:()=>Nr,Keyword:()=>Fr,LangiumGrammarAstReflection:()=>Fi,LangiumGrammarTerminals:()=>Bn,NamedArgument:()=>Lr,NegatedToken:()=>zr,Negation:()=>Vr,NumberLiteral:()=>Ur,Parameter:()=>Gr,ParameterReference:()=>qr,ParserRule:()=>Yr,ReferenceType:()=>Zr,RegexToken:()=>$r,ReturnType:()=>ti,RuleCall:()=>ri,SimpleType:()=>ai,StringLiteral:()=>si,TerminalAlternatives:()=>li,TerminalElement:()=>di,TerminalGroup:()=>pi,TerminalRule:()=>hi,TerminalRuleCall:()=>_i,Type:()=>yi,TypeAttribute:()=>xi,TypeDefinition:()=>Ci,UnionType:()=>Ti,UnorderedGroup:()=>Di,UntilToken:()=>ki,ValueLiteral:()=>ji,Wildcard:()=>Ni,isAbstractElement:()=>Hn,isAbstractParserRule:()=>Wn,isAbstractRule:()=>Kn,isAbstractType:()=>Jn,isAction:()=>Xn,isAlternatives:()=>Qn,isArrayLiteral:()=>er,isArrayType:()=>nr,isAssignment:()=>ir,isBooleanLiteral:()=>or,isCharacterRange:()=>cr,isCondition:()=>ur,isConjunction:()=>fr,isCrossReference:()=>mr,isDisjunction:()=>gr,isEndOfFile:()=>vr,isGrammar:()=>br,isGrammarImport:()=>Sr,isGroup:()=>wr,isInferredType:()=>Er,isInfixRule:()=>Or,isInfixRuleOperatorList:()=>Ar,isInfixRuleOperators:()=>Mr,isInterface:()=>Pr,isKeyword:()=>Ir,isNamedArgument:()=>Rr,isNegatedToken:()=>Br,isNegation:()=>Hr,isNumberLiteral:()=>Wr,isParameter:()=>Kr,isParameterReference:()=>Jr,isParserRule:()=>Xr,isReferenceType:()=>Qr,isRegexToken:()=>ei,isReturnType:()=>ni,isRuleCall:()=>ii,isSimpleType:()=>oi,isStringLiteral:()=>ci,isTerminalAlternatives:()=>ui,isTerminalElement:()=>fi,isTerminalGroup:()=>mi,isTerminalRule:()=>gi,isTerminalRuleCall:()=>vi,isType:()=>bi,isTypeAttribute:()=>Si,isTypeDefinition:()=>wi,isUnionType:()=>Ei,isUnorderedGroup:()=>Oi,isUntilToken:()=>Ai,isValueLiteral:()=>Mi,isWildcard:()=>Pi,reflection:()=>N});var Bn={ID:/\^?[_a-zA-Z][\w_]*/,STRING:/"(\\.|[^"\\])*"|'(\\.|[^'\\])*'/,NUMBER:/NaN|-?((\d*\.\d+|\d+)([Ee][+-]?\d+)?|Infinity)/,RegexLiteral:/\/(?![*+?])(?:[^\r\n\[/\\]|\\.|\[(?:[^\r\n\]\\]|\\.)*\])+\/[a-z]*/,WS:/\s+/,ML_COMMENT:/\/\*[\s\S]*?\*\//,SL_COMMENT:/\/\/[^\n\r]*/},Vn={$type:`AbstractElement`,cardinality:`cardinality`};function Hn(e){return N.isInstance(e,Vn.$type)}o(Hn,`isAbstractElement`);var Un={$type:`AbstractParserRule`};function Wn(e){return N.isInstance(e,Un.$type)}o(Wn,`isAbstractParserRule`);var Gn={$type:`AbstractRule`};function Kn(e){return N.isInstance(e,Gn.$type)}o(Kn,`isAbstractRule`);var qn={$type:`AbstractType`};function Jn(e){return N.isInstance(e,qn.$type)}o(Jn,`isAbstractType`);var Yn={$type:`Action`,cardinality:`cardinality`,feature:`feature`,inferredType:`inferredType`,operator:`operator`,type:`type`};function Xn(e){return N.isInstance(e,Yn.$type)}o(Xn,`isAction`);var Zn={$type:`Alternatives`,cardinality:`cardinality`,elements:`elements`};function Qn(e){return N.isInstance(e,Zn.$type)}o(Qn,`isAlternatives`);var $n={$type:`ArrayLiteral`,elements:`elements`};function er(e){return N.isInstance(e,$n.$type)}o(er,`isArrayLiteral`);var tr={$type:`ArrayType`,elementType:`elementType`};function nr(e){return N.isInstance(e,tr.$type)}o(nr,`isArrayType`);var rr={$type:`Assignment`,cardinality:`cardinality`,feature:`feature`,operator:`operator`,predicate:`predicate`,terminal:`terminal`};function ir(e){return N.isInstance(e,rr.$type)}o(ir,`isAssignment`);var ar={$type:`BooleanLiteral`,true:`true`};function or(e){return N.isInstance(e,ar.$type)}o(or,`isBooleanLiteral`);var sr={$type:`CharacterRange`,cardinality:`cardinality`,left:`left`,lookahead:`lookahead`,parenthesized:`parenthesized`,right:`right`};function cr(e){return N.isInstance(e,sr.$type)}o(cr,`isCharacterRange`);var lr={$type:`Condition`};function ur(e){return N.isInstance(e,lr.$type)}o(ur,`isCondition`);var dr={$type:`Conjunction`,left:`left`,right:`right`};function fr(e){return N.isInstance(e,dr.$type)}o(fr,`isConjunction`);var pr={$type:`CrossReference`,cardinality:`cardinality`,deprecatedSyntax:`deprecatedSyntax`,isMulti:`isMulti`,terminal:`terminal`,type:`type`};function mr(e){return N.isInstance(e,pr.$type)}o(mr,`isCrossReference`);var hr={$type:`Disjunction`,left:`left`,right:`right`};function gr(e){return N.isInstance(e,hr.$type)}o(gr,`isDisjunction`);var _r={$type:`EndOfFile`,cardinality:`cardinality`};function vr(e){return N.isInstance(e,_r.$type)}o(vr,`isEndOfFile`);var yr={$type:`Grammar`,imports:`imports`,interfaces:`interfaces`,isDeclared:`isDeclared`,name:`name`,rules:`rules`,types:`types`};function br(e){return N.isInstance(e,yr.$type)}o(br,`isGrammar`);var xr={$type:`GrammarImport`,path:`path`};function Sr(e){return N.isInstance(e,xr.$type)}o(Sr,`isGrammarImport`);var Cr={$type:`Group`,cardinality:`cardinality`,elements:`elements`,guardCondition:`guardCondition`,predicate:`predicate`};function wr(e){return N.isInstance(e,Cr.$type)}o(wr,`isGroup`);var Tr={$type:`InferredType`,name:`name`};function Er(e){return N.isInstance(e,Tr.$type)}o(Er,`isInferredType`);var Dr={$type:`InfixRule`,call:`call`,dataType:`dataType`,inferredType:`inferredType`,name:`name`,operators:`operators`,parameters:`parameters`,returnType:`returnType`};function Or(e){return N.isInstance(e,Dr.$type)}o(Or,`isInfixRule`);var kr={$type:`InfixRuleOperatorList`,associativity:`associativity`,operators:`operators`};function Ar(e){return N.isInstance(e,kr.$type)}o(Ar,`isInfixRuleOperatorList`);var jr={$type:`InfixRuleOperators`,precedences:`precedences`};function Mr(e){return N.isInstance(e,jr.$type)}o(Mr,`isInfixRuleOperators`);var Nr={$type:`Interface`,attributes:`attributes`,name:`name`,superTypes:`superTypes`};function Pr(e){return N.isInstance(e,Nr.$type)}o(Pr,`isInterface`);var Fr={$type:`Keyword`,cardinality:`cardinality`,predicate:`predicate`,value:`value`};function Ir(e){return N.isInstance(e,Fr.$type)}o(Ir,`isKeyword`);var Lr={$type:`NamedArgument`,calledByName:`calledByName`,parameter:`parameter`,value:`value`};function Rr(e){return N.isInstance(e,Lr.$type)}o(Rr,`isNamedArgument`);var zr={$type:`NegatedToken`,cardinality:`cardinality`,lookahead:`lookahead`,parenthesized:`parenthesized`,terminal:`terminal`};function Br(e){return N.isInstance(e,zr.$type)}o(Br,`isNegatedToken`);var Vr={$type:`Negation`,value:`value`};function Hr(e){return N.isInstance(e,Vr.$type)}o(Hr,`isNegation`);var Ur={$type:`NumberLiteral`,value:`value`};function Wr(e){return N.isInstance(e,Ur.$type)}o(Wr,`isNumberLiteral`);var Gr={$type:`Parameter`,name:`name`};function Kr(e){return N.isInstance(e,Gr.$type)}o(Kr,`isParameter`);var qr={$type:`ParameterReference`,parameter:`parameter`};function Jr(e){return N.isInstance(e,qr.$type)}o(Jr,`isParameterReference`);var Yr={$type:`ParserRule`,dataType:`dataType`,definition:`definition`,entry:`entry`,fragment:`fragment`,inferredType:`inferredType`,name:`name`,parameters:`parameters`,returnType:`returnType`};function Xr(e){return N.isInstance(e,Yr.$type)}o(Xr,`isParserRule`);var Zr={$type:`ReferenceType`,isMulti:`isMulti`,referenceType:`referenceType`};function Qr(e){return N.isInstance(e,Zr.$type)}o(Qr,`isReferenceType`);var $r={$type:`RegexToken`,cardinality:`cardinality`,lookahead:`lookahead`,parenthesized:`parenthesized`,regex:`regex`};function ei(e){return N.isInstance(e,$r.$type)}o(ei,`isRegexToken`);var ti={$type:`ReturnType`,name:`name`};function ni(e){return N.isInstance(e,ti.$type)}o(ni,`isReturnType`);var ri={$type:`RuleCall`,arguments:`arguments`,cardinality:`cardinality`,predicate:`predicate`,rule:`rule`};function ii(e){return N.isInstance(e,ri.$type)}o(ii,`isRuleCall`);var ai={$type:`SimpleType`,primitiveType:`primitiveType`,stringType:`stringType`,typeRef:`typeRef`};function oi(e){return N.isInstance(e,ai.$type)}o(oi,`isSimpleType`);var si={$type:`StringLiteral`,value:`value`};function ci(e){return N.isInstance(e,si.$type)}o(ci,`isStringLiteral`);var li={$type:`TerminalAlternatives`,cardinality:`cardinality`,elements:`elements`,lookahead:`lookahead`,parenthesized:`parenthesized`};function ui(e){return N.isInstance(e,li.$type)}o(ui,`isTerminalAlternatives`);var di={$type:`TerminalElement`,cardinality:`cardinality`,lookahead:`lookahead`,parenthesized:`parenthesized`};function fi(e){return N.isInstance(e,di.$type)}o(fi,`isTerminalElement`);var pi={$type:`TerminalGroup`,cardinality:`cardinality`,elements:`elements`,lookahead:`lookahead`,parenthesized:`parenthesized`};function mi(e){return N.isInstance(e,pi.$type)}o(mi,`isTerminalGroup`);var hi={$type:`TerminalRule`,definition:`definition`,fragment:`fragment`,hidden:`hidden`,name:`name`,type:`type`};function gi(e){return N.isInstance(e,hi.$type)}o(gi,`isTerminalRule`);var _i={$type:`TerminalRuleCall`,cardinality:`cardinality`,lookahead:`lookahead`,parenthesized:`parenthesized`,rule:`rule`};function vi(e){return N.isInstance(e,_i.$type)}o(vi,`isTerminalRuleCall`);var yi={$type:`Type`,name:`name`,type:`type`};function bi(e){return N.isInstance(e,yi.$type)}o(bi,`isType`);var xi={$type:`TypeAttribute`,defaultValue:`defaultValue`,isOptional:`isOptional`,name:`name`,type:`type`};function Si(e){return N.isInstance(e,xi.$type)}o(Si,`isTypeAttribute`);var Ci={$type:`TypeDefinition`};function wi(e){return N.isInstance(e,Ci.$type)}o(wi,`isTypeDefinition`);var Ti={$type:`UnionType`,types:`types`};function Ei(e){return N.isInstance(e,Ti.$type)}o(Ei,`isUnionType`);var Di={$type:`UnorderedGroup`,cardinality:`cardinality`,elements:`elements`};function Oi(e){return N.isInstance(e,Di.$type)}o(Oi,`isUnorderedGroup`);var ki={$type:`UntilToken`,cardinality:`cardinality`,lookahead:`lookahead`,parenthesized:`parenthesized`,terminal:`terminal`};function Ai(e){return N.isInstance(e,ki.$type)}o(Ai,`isUntilToken`);var ji={$type:`ValueLiteral`};function Mi(e){return N.isInstance(e,ji.$type)}o(Mi,`isValueLiteral`);var Ni={$type:`Wildcard`,cardinality:`cardinality`,lookahead:`lookahead`,parenthesized:`parenthesized`};function Pi(e){return N.isInstance(e,Ni.$type)}o(Pi,`isWildcard`);var Fi=class extends pn{static{o(this,`LangiumGrammarAstReflection`)}constructor(){super(...arguments),this.types={AbstractElement:{name:Vn.$type,properties:{cardinality:{name:Vn.cardinality}},superTypes:[]},AbstractParserRule:{name:Un.$type,properties:{},superTypes:[Gn.$type,qn.$type]},AbstractRule:{name:Gn.$type,properties:{},superTypes:[]},AbstractType:{name:qn.$type,properties:{},superTypes:[]},Action:{name:Yn.$type,properties:{cardinality:{name:Yn.cardinality},feature:{name:Yn.feature},inferredType:{name:Yn.inferredType},operator:{name:Yn.operator},type:{name:Yn.type,referenceType:qn.$type}},superTypes:[Vn.$type]},Alternatives:{name:Zn.$type,properties:{cardinality:{name:Zn.cardinality},elements:{name:Zn.elements,defaultValue:[]}},superTypes:[Vn.$type]},ArrayLiteral:{name:$n.$type,properties:{elements:{name:$n.elements,defaultValue:[]}},superTypes:[ji.$type]},ArrayType:{name:tr.$type,properties:{elementType:{name:tr.elementType}},superTypes:[Ci.$type]},Assignment:{name:rr.$type,properties:{cardinality:{name:rr.cardinality},feature:{name:rr.feature},operator:{name:rr.operator},predicate:{name:rr.predicate},terminal:{name:rr.terminal}},superTypes:[Vn.$type]},BooleanLiteral:{name:ar.$type,properties:{true:{name:ar.true,defaultValue:!1}},superTypes:[lr.$type,ji.$type]},CharacterRange:{name:sr.$type,properties:{cardinality:{name:sr.cardinality},left:{name:sr.left},lookahead:{name:sr.lookahead},parenthesized:{name:sr.parenthesized,defaultValue:!1},right:{name:sr.right}},superTypes:[di.$type]},Condition:{name:lr.$type,properties:{},superTypes:[]},Conjunction:{name:dr.$type,properties:{left:{name:dr.left},right:{name:dr.right}},superTypes:[lr.$type]},CrossReference:{name:pr.$type,properties:{cardinality:{name:pr.cardinality},deprecatedSyntax:{name:pr.deprecatedSyntax,defaultValue:!1},isMulti:{name:pr.isMulti,defaultValue:!1},terminal:{name:pr.terminal},type:{name:pr.type,referenceType:qn.$type}},superTypes:[Vn.$type]},Disjunction:{name:hr.$type,properties:{left:{name:hr.left},right:{name:hr.right}},superTypes:[lr.$type]},EndOfFile:{name:_r.$type,properties:{cardinality:{name:_r.cardinality}},superTypes:[Vn.$type]},Grammar:{name:yr.$type,properties:{imports:{name:yr.imports,defaultValue:[]},interfaces:{name:yr.interfaces,defaultValue:[]},isDeclared:{name:yr.isDeclared,defaultValue:!1},name:{name:yr.name},rules:{name:yr.rules,defaultValue:[]},types:{name:yr.types,defaultValue:[]}},superTypes:[]},GrammarImport:{name:xr.$type,properties:{path:{name:xr.path}},superTypes:[]},Group:{name:Cr.$type,properties:{cardinality:{name:Cr.cardinality},elements:{name:Cr.elements,defaultValue:[]},guardCondition:{name:Cr.guardCondition},predicate:{name:Cr.predicate}},superTypes:[Vn.$type]},InferredType:{name:Tr.$type,properties:{name:{name:Tr.name}},superTypes:[qn.$type]},InfixRule:{name:Dr.$type,properties:{call:{name:Dr.call},dataType:{name:Dr.dataType},inferredType:{name:Dr.inferredType},name:{name:Dr.name},operators:{name:Dr.operators},parameters:{name:Dr.parameters,defaultValue:[]},returnType:{name:Dr.returnType,referenceType:qn.$type}},superTypes:[Un.$type]},InfixRuleOperatorList:{name:kr.$type,properties:{associativity:{name:kr.associativity},operators:{name:kr.operators,defaultValue:[]}},superTypes:[]},InfixRuleOperators:{name:jr.$type,properties:{precedences:{name:jr.precedences,defaultValue:[]}},superTypes:[]},Interface:{name:Nr.$type,properties:{attributes:{name:Nr.attributes,defaultValue:[]},name:{name:Nr.name},superTypes:{name:Nr.superTypes,defaultValue:[],referenceType:qn.$type}},superTypes:[qn.$type]},Keyword:{name:Fr.$type,properties:{cardinality:{name:Fr.cardinality},predicate:{name:Fr.predicate},value:{name:Fr.value}},superTypes:[Vn.$type]},NamedArgument:{name:Lr.$type,properties:{calledByName:{name:Lr.calledByName,defaultValue:!1},parameter:{name:Lr.parameter,referenceType:Gr.$type},value:{name:Lr.value}},superTypes:[]},NegatedToken:{name:zr.$type,properties:{cardinality:{name:zr.cardinality},lookahead:{name:zr.lookahead},parenthesized:{name:zr.parenthesized,defaultValue:!1},terminal:{name:zr.terminal}},superTypes:[di.$type]},Negation:{name:Vr.$type,properties:{value:{name:Vr.value}},superTypes:[lr.$type]},NumberLiteral:{name:Ur.$type,properties:{value:{name:Ur.value}},superTypes:[ji.$type]},Parameter:{name:Gr.$type,properties:{name:{name:Gr.name}},superTypes:[]},ParameterReference:{name:qr.$type,properties:{parameter:{name:qr.parameter,referenceType:Gr.$type}},superTypes:[lr.$type]},ParserRule:{name:Yr.$type,properties:{dataType:{name:Yr.dataType},definition:{name:Yr.definition},entry:{name:Yr.entry,defaultValue:!1},fragment:{name:Yr.fragment,defaultValue:!1},inferredType:{name:Yr.inferredType},name:{name:Yr.name},parameters:{name:Yr.parameters,defaultValue:[]},returnType:{name:Yr.returnType,referenceType:qn.$type}},superTypes:[Un.$type]},ReferenceType:{name:Zr.$type,properties:{isMulti:{name:Zr.isMulti,defaultValue:!1},referenceType:{name:Zr.referenceType}},superTypes:[Ci.$type]},RegexToken:{name:$r.$type,properties:{cardinality:{name:$r.cardinality},lookahead:{name:$r.lookahead},parenthesized:{name:$r.parenthesized,defaultValue:!1},regex:{name:$r.regex}},superTypes:[di.$type]},ReturnType:{name:ti.$type,properties:{name:{name:ti.name}},superTypes:[]},RuleCall:{name:ri.$type,properties:{arguments:{name:ri.arguments,defaultValue:[]},cardinality:{name:ri.cardinality},predicate:{name:ri.predicate},rule:{name:ri.rule,referenceType:Gn.$type}},superTypes:[Vn.$type]},SimpleType:{name:ai.$type,properties:{primitiveType:{name:ai.primitiveType},stringType:{name:ai.stringType},typeRef:{name:ai.typeRef,referenceType:qn.$type}},superTypes:[Ci.$type]},StringLiteral:{name:si.$type,properties:{value:{name:si.value}},superTypes:[ji.$type]},TerminalAlternatives:{name:li.$type,properties:{cardinality:{name:li.cardinality},elements:{name:li.elements,defaultValue:[]},lookahead:{name:li.lookahead},parenthesized:{name:li.parenthesized,defaultValue:!1}},superTypes:[di.$type]},TerminalElement:{name:di.$type,properties:{cardinality:{name:di.cardinality},lookahead:{name:di.lookahead},parenthesized:{name:di.parenthesized,defaultValue:!1}},superTypes:[Vn.$type]},TerminalGroup:{name:pi.$type,properties:{cardinality:{name:pi.cardinality},elements:{name:pi.elements,defaultValue:[]},lookahead:{name:pi.lookahead},parenthesized:{name:pi.parenthesized,defaultValue:!1}},superTypes:[di.$type]},TerminalRule:{name:hi.$type,properties:{definition:{name:hi.definition},fragment:{name:hi.fragment,defaultValue:!1},hidden:{name:hi.hidden,defaultValue:!1},name:{name:hi.name},type:{name:hi.type}},superTypes:[Gn.$type]},TerminalRuleCall:{name:_i.$type,properties:{cardinality:{name:_i.cardinality},lookahead:{name:_i.lookahead},parenthesized:{name:_i.parenthesized,defaultValue:!1},rule:{name:_i.rule,referenceType:hi.$type}},superTypes:[di.$type]},Type:{name:yi.$type,properties:{name:{name:yi.name},type:{name:yi.type}},superTypes:[qn.$type]},TypeAttribute:{name:xi.$type,properties:{defaultValue:{name:xi.defaultValue},isOptional:{name:xi.isOptional,defaultValue:!1},name:{name:xi.name},type:{name:xi.type}},superTypes:[]},TypeDefinition:{name:Ci.$type,properties:{},superTypes:[]},UnionType:{name:Ti.$type,properties:{types:{name:Ti.types,defaultValue:[]}},superTypes:[Ci.$type]},UnorderedGroup:{name:Di.$type,properties:{cardinality:{name:Di.cardinality},elements:{name:Di.elements,defaultValue:[]}},superTypes:[Vn.$type]},UntilToken:{name:ki.$type,properties:{cardinality:{name:ki.cardinality},lookahead:{name:ki.lookahead},parenthesized:{name:ki.parenthesized,defaultValue:!1},terminal:{name:ki.terminal}},superTypes:[di.$type]},ValueLiteral:{name:ji.$type,properties:{},superTypes:[]},Wildcard:{name:Ni.$type,properties:{cardinality:{name:Ni.cardinality},lookahead:{name:Ni.lookahead},parenthesized:{name:Ni.parenthesized,defaultValue:!1}},superTypes:[di.$type]}}}},N=new Fi;function Ii(e){let t=e,n=!1;for(;t;){let e=En(t.grammarSource,Xr);if(e&&e.dataType)t=t.container,n=!0;else if(n)return t;else return}}o(Ii,`getDatatypeNode`);function Li(e){return new Sn(e,e=>mn(e)?e.content:[],{includeRoot:!0})}o(Li,`streamCst`);function Ri(e){return Li(e).filter(hn)}o(Ri,`flattenCst`);function zi(e,t){for(;e.container;)if(e=e.container,e===t)return!0;return!1}o(zi,`isChildNode`);function Bi(e){return{start:{character:e.startColumn-1,line:e.startLine-1},end:{character:e.endColumn,line:e.endLine-1}}}o(Bi,`tokenToRange`);function Vi(e){if(!e)return;let{offset:t,end:n,range:r}=e;return{range:r,offset:t,end:n,length:n-t}}o(Vi,`toDocumentSegment`);var Hi;(function(e){e[e.Before=0]=`Before`,e[e.After=1]=`After`,e[e.OverlapFront=2]=`OverlapFront`,e[e.OverlapBack=3]=`OverlapBack`,e[e.Inside=4]=`Inside`,e[e.Outside=5]=`Outside`})(Hi||={});function Ui(e,t){if(e.end.line<t.start.line||e.end.line===t.start.line&&e.end.character<=t.start.character)return Hi.Before;if(e.start.line>t.end.line||e.start.line===t.end.line&&e.start.character>=t.end.character)return Hi.After;let n=e.start.line>t.start.line||e.start.line===t.start.line&&e.start.character>=t.start.character,r=e.end.line<t.end.line||e.end.line===t.end.line&&e.end.character<=t.end.character;return n&&r?Hi.Inside:n?Hi.OverlapBack:r?Hi.OverlapFront:Hi.Outside}o(Ui,`compareRange`);function Wi(e,t){return Ui(e,t)>Hi.After}o(Wi,`inRange`);var Gi=/^[\w\p{L}]$/u;function Ki(e,t,n=Gi){if(e){if(t>0){let r=t-e.offset,i=e.text.charAt(r);n.test(i)||t--}return Yi(e,t)}}o(Ki,`findDeclarationNodeAtOffset`);function qi(e,t){if(e){let n=Qi(e,!0);if(n&&Ji(n,t))return n;if(gn(e)){let n=e.content.findIndex(e=>!e.hidden);for(let r=n-1;r>=0;r--){let n=e.content[r];if(Ji(n,t))return n}}}}o(qi,`findCommentNode`);function Ji(e,t){return hn(e)&&t.includes(e.tokenType.name)}o(Ji,`isCommentNode`);function Yi(e,t){if(hn(e))return e;if(mn(e)){let n=Zi(e,t,!1);if(n)return Yi(n,t)}}o(Yi,`findLeafNodeAtOffset`);function Xi(e,t){if(hn(e))return e;if(mn(e)){let n=Zi(e,t,!0);if(n)return Xi(n,t)}}o(Xi,`findLeafNodeBeforeOffset`);function Zi(e,t,n){let r=0,i=e.content.length-1,a;for(;r<=i;){let o=Math.floor((r+i)/2),s=e.content[o];if(s.offset<=t&&s.end>t)return s;s.end<=t?(a=n?s:void 0,r=o+1):i=o-1}return a}o(Zi,`binarySearch`);function Qi(e,t=!0){for(;e.container;){let n=e.container,r=n.content.indexOf(e);for(;r>0;){r--;let e=n.content[r];if(t||!e.hidden)return e}e=n}}o(Qi,`getPreviousNode`);function $i(e,t=!0){for(;e.container;){let n=e.container,r=n.content.indexOf(e),i=n.content.length-1;for(;r<i;){r++;let e=n.content[r];if(t||!e.hidden)return e}e=n}}o($i,`getNextNode`);function ea(e){if(e.range.start.character===0)return e;let t=e.range.start.line,n=e,r;for(;e.container;){let i=e.container,a=r??i.content.indexOf(e);if(a===0?(e=i,r=void 0):(r=a-1,e=i.content[r]),e.range.start.line!==t)break;n=e}return n}o(ea,`getStartlineNode`);function ta(e,t){let n=na(e,t);return n?n.parent.content.slice(n.a+1,n.b):[]}o(ta,`getInteriorNodes`);function na(e,t){let n=ra(e),r=ra(t),i;for(let e=0;e<n.length&&e<r.length;e++){let t=n[e],a=r[e];if(t.parent===a.parent)i={parent:t.parent,a:t.index,b:a.index};else break}return i}o(na,`getCommonParent`);function ra(e){let t=[];for(;e.container;){let n=e.container,r=n.content.indexOf(e);t.push({parent:n,index:r}),e=n}return t.reverse()}o(ra,`getParentChain`);var ia={};l(ia,{findAssignment:()=>Ga,findNameAssignment:()=>Ka,findNodeForKeyword:()=>Ua,findNodeForProperty:()=>Ba,findNodesForKeyword:()=>Ha,findNodesForKeywordInternal:()=>Wa,findNodesForProperty:()=>za,getActionAtElement:()=>Ja,getActionType:()=>io,getAllReachableRules:()=>Pa,getAllRulesUsedForCrossReferences:()=>Ia,getCrossReferenceTerminal:()=>La,getEntryRule:()=>Ma,getExplicitRuleType:()=>no,getHiddenRules:()=>Na,getRuleType:()=>oo,getRuleTypeName:()=>ao,getTypeName:()=>ro,isArrayCardinality:()=>Xa,isArrayOperator:()=>Za,isCommentTerminal:()=>Ra,isDataType:()=>eo,isDataTypeRule:()=>Qa,isOptionalCardinality:()=>Ya,terminalRegex:()=>so});var aa=class extends Error{static{o(this,`ErrorWithLocation`)}constructor(e,t){super(e?`${t} at ${e.range.start.line}:${e.range.start.character}`:t)}};function oa(e,t=`Error: Got unexpected value.`){throw Error(t)}o(oa,`assertUnreachable`);function sa(e,t=`Error: Condition is violated.`){if(!e)throw Error(t)}o(sa,`assertCondition`);var ca={};l(ca,{NEWLINE_REGEXP:()=>Sa,escapeRegExp:()=>ka,getTerminalParts:()=>Ta,isMultilineComment:()=>Ea,isWhitespace:()=>Oa,partialMatches:()=>Aa,partialRegExp:()=>ja,whitespaceCharacters:()=>Da});function P(e){return e.charCodeAt(0)}o(P,`cc`);function la(e,t){Array.isArray(e)?e.forEach(function(e){t.push(e)}):t.push(e)}o(la,`insertToSet`);function ua(e,t){if(e[t]===!0)throw`duplicate flag `+t;e[t],e[t]=!0}o(ua,`addFlag`);function da(e){if(e===void 0)throw Error(`Internal Error - Should never get here!`);return!0}o(da,`ASSERT_EXISTS`);function fa(){throw Error(`Internal Error - Should never get here!`)}o(fa,`ASSERT_NEVER_REACH_HERE`);function pa(e){return e.type===`Character`}o(pa,`isCharacter`);var ma=[];for(let e=P(`0`);e<=P(`9`);e++)ma.push(e);var ha=[P(`_`)].concat(ma);for(let e=P(`a`);e<=P(`z`);e++)ha.push(e);for(let e=P(`A`);e<=P(`Z`);e++)ha.push(e);var ga=[P(` `),P(`\f`),P(`
36
+ `),P(`\r`),P(` `),P(`\v`),P(` `),P(`\xA0`),P(` `),P(` `),P(` `),P(` `),P(` `),P(` `),P(` `),P(` `),P(` `),P(` `),P(` `),P(` `),P(`\u2028`),P(`\u2029`),P(` `),P(` `),P(` `),P(``)],_a=/[0-9a-fA-F]/,va=/[0-9]/,ya=/[1-9]/,ba=class{static{o(this,`RegExpParser`)}constructor(){this.idx=0,this.input=``,this.groupIdx=0}saveState(){return{idx:this.idx,input:this.input,groupIdx:this.groupIdx}}restoreState(e){this.idx=e.idx,this.input=e.input,this.groupIdx=e.groupIdx}pattern(e){this.idx=0,this.input=e,this.groupIdx=0,this.consumeChar(`/`);let t=this.disjunction();this.consumeChar(`/`);let n={type:`Flags`,loc:{begin:this.idx,end:e.length},global:!1,ignoreCase:!1,multiLine:!1,unicode:!1,sticky:!1};for(;this.isRegExpFlag();)switch(this.popChar()){case`g`:ua(n,`global`);break;case`i`:ua(n,`ignoreCase`);break;case`m`:ua(n,`multiLine`);break;case`u`:ua(n,`unicode`);break;case`y`:ua(n,`sticky`);break}if(this.idx!==this.input.length)throw Error(`Redundant input: `+this.input.substring(this.idx));return{type:`Pattern`,flags:n,value:t,loc:this.loc(0)}}disjunction(){let e=[],t=this.idx;for(e.push(this.alternative());this.peekChar()===`|`;)this.consumeChar(`|`),e.push(this.alternative());return{type:`Disjunction`,value:e,loc:this.loc(t)}}alternative(){let e=[],t=this.idx;for(;this.isTerm();)e.push(this.term());return{type:`Alternative`,value:e,loc:this.loc(t)}}term(){return this.isAssertion()?this.assertion():this.atom()}assertion(){let e=this.idx;switch(this.popChar()){case`^`:return{type:`StartAnchor`,loc:this.loc(e)};case`$`:return{type:`EndAnchor`,loc:this.loc(e)};case`\\`:switch(this.popChar()){case`b`:return{type:`WordBoundary`,loc:this.loc(e)};case`B`:return{type:`NonWordBoundary`,loc:this.loc(e)}}throw Error(`Invalid Assertion Escape`);case`(`:this.consumeChar(`?`);let t;switch(this.popChar()){case`=`:t=`Lookahead`;break;case`!`:t=`NegativeLookahead`;break;case`<`:switch(this.popChar()){case`=`:t=`Lookbehind`;break;case`!`:t=`NegativeLookbehind`}break}da(t);let n=this.disjunction();return this.consumeChar(`)`),{type:t,value:n,loc:this.loc(e)}}return fa()}quantifier(e=!1){let t,n=this.idx;switch(this.popChar()){case`*`:t={atLeast:0,atMost:1/0};break;case`+`:t={atLeast:1,atMost:1/0};break;case`?`:t={atLeast:0,atMost:1};break;case`{`:let n=this.integerIncludingZero();switch(this.popChar()){case`}`:t={atLeast:n,atMost:n};break;case`,`:let e;this.isDigit()?(e=this.integerIncludingZero(),t={atLeast:n,atMost:e}):t={atLeast:n,atMost:1/0},this.consumeChar(`}`);break}if(e===!0&&t===void 0)return;da(t);break}if(!(e===!0&&t===void 0)&&da(t))return this.peekChar(0)===`?`?(this.consumeChar(`?`),t.greedy=!1):t.greedy=!0,t.type=`Quantifier`,t.loc=this.loc(n),t}atom(){let e,t=this.idx;switch(this.peekChar()){case`.`:e=this.dotAll();break;case`\\`:e=this.atomEscape();break;case`[`:e=this.characterClass();break;case`(`:e=this.group();break}return e===void 0&&this.isPatternCharacter()&&(e=this.patternCharacter()),da(e)?(e.loc=this.loc(t),this.isQuantifier()&&(e.quantifier=this.quantifier()),e):fa()}dotAll(){return this.consumeChar(`.`),{type:`Set`,complement:!0,value:[P(`
37
+ `),P(`\r`),P(`\u2028`),P(`\u2029`)]}}atomEscape(){switch(this.consumeChar(`\\`),this.peekChar()){case`1`:case`2`:case`3`:case`4`:case`5`:case`6`:case`7`:case`8`:case`9`:return this.decimalEscapeAtom();case`d`:case`D`:case`s`:case`S`:case`w`:case`W`:return this.characterClassEscape();case`f`:case`n`:case`r`:case`t`:case`v`:return this.controlEscapeAtom();case`c`:return this.controlLetterEscapeAtom();case`0`:return this.nulCharacterAtom();case`x`:return this.hexEscapeSequenceAtom();case`u`:return this.regExpUnicodeEscapeSequenceAtom();default:return this.identityEscapeAtom()}}decimalEscapeAtom(){return{type:`GroupBackReference`,value:this.positiveInteger()}}characterClassEscape(){let e,t=!1;switch(this.popChar()){case`d`:e=ma;break;case`D`:e=ma,t=!0;break;case`s`:e=ga;break;case`S`:e=ga,t=!0;break;case`w`:e=ha;break;case`W`:e=ha,t=!0;break}return da(e)?{type:`Set`,value:e,complement:t}:fa()}controlEscapeAtom(){let e;switch(this.popChar()){case`f`:e=P(`\f`);break;case`n`:e=P(`
38
+ `);break;case`r`:e=P(`\r`);break;case`t`:e=P(` `);break;case`v`:e=P(`\v`);break}return da(e)?{type:`Character`,value:e}:fa()}controlLetterEscapeAtom(){this.consumeChar(`c`);let e=this.popChar();if(/[a-zA-Z]/.test(e)===!1)throw Error(`Invalid `);return{type:`Character`,value:e.toUpperCase().charCodeAt(0)-64}}nulCharacterAtom(){return this.consumeChar(`0`),{type:`Character`,value:P(`\0`)}}hexEscapeSequenceAtom(){return this.consumeChar(`x`),this.parseHexDigits(2)}regExpUnicodeEscapeSequenceAtom(){return this.consumeChar(`u`),this.parseHexDigits(4)}identityEscapeAtom(){return{type:`Character`,value:P(this.popChar())}}classPatternCharacterAtom(){switch(this.peekChar()){case`
39
+ `:case`\r`:case`\u2028`:case`\u2029`:case`\\`:case`]`:throw Error(`TBD`);default:return{type:`Character`,value:P(this.popChar())}}}characterClass(){let e=[],t=!1;for(this.consumeChar(`[`),this.peekChar(0)===`^`&&(this.consumeChar(`^`),t=!0);this.isClassAtom();){let t=this.classAtom();if(t.type,pa(t)&&this.isRangeDash()){this.consumeChar(`-`);let n=this.classAtom();if(n.type,pa(n)){if(n.value<t.value)throw Error(`Range out of order in character class`);e.push({from:t.value,to:n.value})}else la(t.value,e),e.push(P(`-`)),la(n.value,e)}else la(t.value,e)}return this.consumeChar(`]`),{type:`Set`,complement:t,value:e}}classAtom(){switch(this.peekChar()){case`]`:case`
40
+ `:case`\r`:case`\u2028`:case`\u2029`:throw Error(`TBD`);case`\\`:return this.classEscape();default:return this.classPatternCharacterAtom()}}classEscape(){switch(this.consumeChar(`\\`),this.peekChar()){case`b`:return this.consumeChar(`b`),{type:`Character`,value:P(`\b`)};case`d`:case`D`:case`s`:case`S`:case`w`:case`W`:return this.characterClassEscape();case`f`:case`n`:case`r`:case`t`:case`v`:return this.controlEscapeAtom();case`c`:return this.controlLetterEscapeAtom();case`0`:return this.nulCharacterAtom();case`x`:return this.hexEscapeSequenceAtom();case`u`:return this.regExpUnicodeEscapeSequenceAtom();default:return this.identityEscapeAtom()}}group(){let e=!0;switch(this.consumeChar(`(`),this.peekChar(0)){case`?`:this.consumeChar(`?`),this.consumeChar(`:`),e=!1;break;default:this.groupIdx++;break}let t=this.disjunction();this.consumeChar(`)`);let n={type:`Group`,capturing:e,value:t};return e&&(n.idx=this.groupIdx),n}positiveInteger(){let e=this.popChar();if(ya.test(e)===!1)throw Error(`Expecting a positive integer`);for(;va.test(this.peekChar(0));)e+=this.popChar();return parseInt(e,10)}integerIncludingZero(){let e=this.popChar();if(va.test(e)===!1)throw Error(`Expecting an integer`);for(;va.test(this.peekChar(0));)e+=this.popChar();return parseInt(e,10)}patternCharacter(){let e=this.popChar();switch(e){case`
41
+ `:case`\r`:case`\u2028`:case`\u2029`:case`^`:case`$`:case`\\`:case`.`:case`*`:case`+`:case`?`:case`(`:case`)`:case`[`:case`|`:throw Error(`TBD`);default:return{type:`Character`,value:P(e)}}}isRegExpFlag(){switch(this.peekChar(0)){case`g`:case`i`:case`m`:case`u`:case`y`:return!0;default:return!1}}isRangeDash(){return this.peekChar()===`-`&&this.isClassAtom(1)}isDigit(){return va.test(this.peekChar(0))}isClassAtom(e=0){switch(this.peekChar(e)){case`]`:case`
42
+ `:case`\r`:case`\u2028`:case`\u2029`:return!1;default:return!0}}isTerm(){return this.isAtom()||this.isAssertion()}isAtom(){if(this.isPatternCharacter())return!0;switch(this.peekChar(0)){case`.`:case`\\`:case`[`:case`(`:return!0;default:return!1}}isAssertion(){switch(this.peekChar(0)){case`^`:case`$`:return!0;case`\\`:switch(this.peekChar(1)){case`b`:case`B`:return!0;default:return!1}case`(`:return this.peekChar(1)===`?`&&(this.peekChar(2)===`=`||this.peekChar(2)===`!`||this.peekChar(2)===`<`&&(this.peekChar(3)===`=`||this.peekChar(3)===`!`));default:return!1}}isQuantifier(){let e=this.saveState();try{return this.quantifier(!0)!==void 0}catch{return!1}finally{this.restoreState(e)}}isPatternCharacter(){switch(this.peekChar()){case`^`:case`$`:case`\\`:case`.`:case`*`:case`+`:case`?`:case`(`:case`)`:case`[`:case`|`:case`/`:case`
43
+ `:case`\r`:case`\u2028`:case`\u2029`:return!1;default:return!0}}parseHexDigits(e){let t=``;for(let n=0;n<e;n++){let e=this.popChar();if(_a.test(e)===!1)throw Error(`Expecting a HexDecimal digits`);t+=e}return{type:`Character`,value:parseInt(t,16)}}peekChar(e=0){return this.input[this.idx+e]}popChar(){let e=this.peekChar(0);return this.consumeChar(void 0),e}consumeChar(e){if(e!==void 0&&this.input[this.idx]!==e)throw Error(`Expected: '`+e+`' but found: '`+this.input[this.idx]+`' at offset: `+this.idx);if(this.idx>=this.input.length)throw Error(`Unexpected end of input`);this.idx++}loc(e){return{begin:e,end:this.idx}}},xa=class{static{o(this,`BaseRegExpVisitor`)}visitChildren(e){for(let t in e){let n=e[t];e.hasOwnProperty(t)&&(n.type===void 0?Array.isArray(n)&&n.forEach(e=>{this.visit(e)},this):this.visit(n))}}visit(e){switch(e.type){case`Pattern`:this.visitPattern(e);break;case`Flags`:this.visitFlags(e);break;case`Disjunction`:this.visitDisjunction(e);break;case`Alternative`:this.visitAlternative(e);break;case`StartAnchor`:this.visitStartAnchor(e);break;case`EndAnchor`:this.visitEndAnchor(e);break;case`WordBoundary`:this.visitWordBoundary(e);break;case`NonWordBoundary`:this.visitNonWordBoundary(e);break;case`Lookahead`:this.visitLookahead(e);break;case`NegativeLookahead`:this.visitNegativeLookahead(e);break;case`Lookbehind`:this.visitLookbehind(e);break;case`NegativeLookbehind`:this.visitNegativeLookbehind(e);break;case`Character`:this.visitCharacter(e);break;case`Set`:this.visitSet(e);break;case`Group`:this.visitGroup(e);break;case`GroupBackReference`:this.visitGroupBackReference(e);break;case`Quantifier`:this.visitQuantifier(e);break}this.visitChildren(e)}visitPattern(e){}visitFlags(e){}visitDisjunction(e){}visitAlternative(e){}visitStartAnchor(e){}visitEndAnchor(e){}visitWordBoundary(e){}visitNonWordBoundary(e){}visitLookahead(e){}visitNegativeLookahead(e){}visitLookbehind(e){}visitNegativeLookbehind(e){}visitCharacter(e){}visitSet(e){}visitGroup(e){}visitGroupBackReference(e){}visitQuantifier(e){}},Sa=/\r?\n/gm,Ca=new ba,wa=new class extends xa{static{o(this,`TerminalRegExpVisitor`)}constructor(){super(...arguments),this.isStarting=!0,this.endRegexpStack=[],this.multiline=!1}get endRegex(){return this.endRegexpStack.join(``)}reset(e){this.multiline=!1,this.regex=e,this.startRegexp=``,this.isStarting=!0,this.endRegexpStack=[]}visitGroup(e){e.quantifier&&(this.isStarting=!1,this.endRegexpStack=[])}visitCharacter(e){let t=String.fromCharCode(e.value);if(!this.multiline&&t===`
44
+ `&&(this.multiline=!0),e.quantifier)this.isStarting=!1,this.endRegexpStack=[];else{let e=ka(t);this.endRegexpStack.push(e),this.isStarting&&(this.startRegexp+=e)}}visitSet(e){if(!this.multiline){let t=this.regex.substring(e.loc.begin,e.loc.end),n=new RegExp(t);this.multiline=!!`
45
+ `.match(n)}if(e.quantifier)this.isStarting=!1,this.endRegexpStack=[];else{let t=this.regex.substring(e.loc.begin,e.loc.end);this.endRegexpStack.push(t),this.isStarting&&(this.startRegexp+=t)}}visitChildren(e){e.type===`Group`&&e.quantifier||super.visitChildren(e)}};function Ta(e){try{typeof e!=`string`&&(e=e.source),e=`/${e}/`;let t=Ca.pattern(e),n=[];for(let r of t.value.value)wa.reset(e),wa.visit(r),n.push({start:wa.startRegexp,end:wa.endRegex});return n}catch{return[]}}o(Ta,`getTerminalParts`);function Ea(e){try{return typeof e==`string`&&(e=new RegExp(e)),e=e.toString(),wa.reset(e),wa.visit(Ca.pattern(e)),wa.multiline}catch{return!1}}o(Ea,`isMultilineComment`);var Da=`\f
46
+ \r \v \xA0            \u2028\u2029   `.split(``);function Oa(e){let t=typeof e==`string`?new RegExp(e):e;return Da.some(e=>t.test(e))}o(Oa,`isWhitespace`);function ka(e){return e.replace(/[.*+?^${}()|[\]\\]/g,`\\$&`)}o(ka,`escapeRegExp`);function Aa(e,t){let n=ja(e),r=t.match(n);return!!r&&r[0].length>0}o(Aa,`partialMatches`);function ja(e){typeof e==`string`&&(e=new RegExp(e));let t=e,n=e.source,r=0;function i(){let e=``,a;function s(t){e+=n.substr(r,t),r+=t}o(s,`appendRaw`);function c(t){e+=`(?:`+n.substr(r,t)+`|$)`,r+=t}for(o(c,`appendOptional`);r<n.length;)switch(n[r]){case`\\`:switch(n[r+1]){case`c`:c(3);break;case`x`:c(4);break;case`u`:t.unicode?n[r+2]===`{`?c(n.indexOf(`}`,r)-r+1):c(6):c(2);break;case`p`:case`P`:t.unicode?c(n.indexOf(`}`,r)-r+1):c(2);break;case`k`:c(n.indexOf(`>`,r)-r+1);break;default:c(2);break}break;case`[`:a=/\[(?:\\.|.)*?\]/g,a.lastIndex=r,a=a.exec(n)||[],c(a[0].length);break;case`|`:case`^`:case`$`:case`*`:case`+`:case`?`:s(1);break;case`{`:a=/\{\d+,?\d*\}/g,a.lastIndex=r,a=a.exec(n),a?s(a[0].length):c(1);break;case`(`:if(n[r+1]===`?`)switch(n[r+2]){case`:`:e+=`(?:`,r+=3,e+=i()+`|$)`;break;case`=`:e+=`(?=`,r+=3,e+=i()+`)`;break;case`!`:a=r,r+=3,i(),e+=n.substr(a,r-a);break;case`<`:switch(n[r+3]){case`=`:case`!`:a=r,r+=4,i(),e+=n.substr(a,r-a);break;default:s(n.indexOf(`>`,r)-r+1),e+=i()+`|$)`;break}break}else s(1),e+=i()+`|$)`;break;case`)`:return++r,e;default:c(1);break}return e}return o(i,`process`),new RegExp(i(),e.flags)}o(ja,`partialRegExp`);function Ma(e){return e.rules.find(e=>Xr(e)&&e.entry)}o(Ma,`getEntryRule`);function Na(e){return e.rules.filter(e=>gi(e)&&e.hidden)}o(Na,`getHiddenRules`);function Pa(e,t){let n=new Set,r=Ma(e);if(!r)return new Set(e.rules);let i=[r].concat(Na(e));for(let e of i)Fa(e,n,t);let a=new Set;for(let t of e.rules)(n.has(t.name)||gi(t)&&t.hidden)&&a.add(t);return a}o(Pa,`getAllReachableRules`);function Fa(e,t,n){t.add(e.name),Mn(e).forEach(e=>{if(ii(e)||n&&vi(e)){let r=e.rule.ref;r&&!t.has(r.name)&&Fa(r,t,n)}})}o(Fa,`ruleDfs`);function Ia(e){let t=new Set;return Mn(e).forEach(e=>{mr(e)&&(Xr(e.type.ref)&&t.add(e.type.ref),Er(e.type.ref)&&Xr(e.type.ref.$container)&&t.add(e.type.ref.$container))}),t}o(Ia,`getAllRulesUsedForCrossReferences`);function La(e){if(e.terminal)return e.terminal;if(e.type.ref)return Ka(e.type.ref)?.terminal}o(La,`getCrossReferenceTerminal`);function Ra(e){return e.hidden&&!Oa(so(e))}o(Ra,`isCommentTerminal`);function za(e,t){return!e||!t?[]:Va(e,t,e.astNode,!0)}o(za,`findNodesForProperty`);function Ba(e,t,n){if(!e||!t)return;let r=Va(e,t,e.astNode,!0);if(r.length!==0)return n=n===void 0?0:Math.max(0,Math.min(n,r.length-1)),r[n]}o(Ba,`findNodeForProperty`);function Va(e,t,n,r){if(!r){let n=En(e.grammarSource,ir);if(n&&n.feature===t)return[e]}return mn(e)&&e.astNode===n?e.content.flatMap(e=>Va(e,t,n,!1)):[]}o(Va,`findNodesForPropertyInternal`);function Ha(e,t){return e?Wa(e,t,e?.astNode):[]}o(Ha,`findNodesForKeyword`);function Ua(e,t,n){if(!e)return;let r=Wa(e,t,e?.astNode);if(r.length!==0)return n=n===void 0?0:Math.max(0,Math.min(n,r.length-1)),r[n]}o(Ua,`findNodeForKeyword`);function Wa(e,t,n){if(e.astNode!==n)return[];if(Ir(e.grammarSource)&&e.grammarSource.value===t)return[e];let r=Li(e).iterator(),i,a=[];do if(i=r.next(),!i.done){let e=i.value;e.astNode===n?Ir(e.grammarSource)&&e.grammarSource.value===t&&a.push(e):r.prune()}while(!i.done);return a}o(Wa,`findNodesForKeywordInternal`);function Ga(e){let t=e.astNode;for(;t===e.container?.astNode;){let t=En(e.grammarSource,ir);if(t)return t;e=e.container}}o(Ga,`findAssignment`);function Ka(e){let t=e;return Er(t)&&(Xn(t.$container)?t=t.$container.$container:Wn(t.$container)?t=t.$container:oa(t.$container)),qa(e,t,new Map)}o(Ka,`findNameAssignment`);function qa(e,t,n){function r(t,r){let i;return En(t,ir)||(i=qa(r,r,n)),n.set(e,i),i}if(o(r,`go`),n.has(e))return n.get(e);n.set(e,void 0);for(let i of Mn(t))if(ir(i)&&i.feature.toLowerCase()===`name`)return n.set(e,i),i;else if(ii(i)&&Xr(i.rule.ref))return r(i,i.rule.ref);else if(oi(i)&&i.typeRef?.ref)return r(i,i.typeRef.ref)}o(qa,`findNameAssignmentInternal`);function Ja(e){let t=e.$container;if(wr(t)){let n=t.elements,r=n.indexOf(e);for(let e=r-1;e>=0;e--){let t=n[e];if(Xn(t))return t;{let t=Mn(n[e]).find(Xn);if(t)return t}}}if(Hn(t))return Ja(t)}o(Ja,`getActionAtElement`);function Ya(e,t){return e===`?`||e===`*`||wr(t)&&!!t.guardCondition}o(Ya,`isOptionalCardinality`);function Xa(e){return e===`*`||e===`+`}o(Xa,`isArrayCardinality`);function Za(e){return e===`+=`}o(Za,`isArrayOperator`);function Qa(e){return $a(e,new Set)}o(Qa,`isDataTypeRule`);function $a(e,t){if(t.has(e))return!0;t.add(e);for(let n of Mn(e))if(ii(n)){if(!n.rule.ref||Xr(n.rule.ref)&&!$a(n.rule.ref,t)||Or(n.rule.ref))return!1}else if(ir(n))return!1;else if(Xn(n))return!1;return!!e.definition}o($a,`isDataTypeRuleInternal`);function eo(e){return to(e.type,new Set)}o(eo,`isDataType`);function to(e,t){if(t.has(e))return!0;if(t.add(e),nr(e)||Qr(e))return!1;if(Ei(e))return e.types.every(e=>to(e,t));if(oi(e)){if(e.primitiveType!==void 0||e.stringType!==void 0)return!0;if(e.typeRef!==void 0){let n=e.typeRef.ref;return bi(n)?to(n.type,t):!1}else return!1}else return!1}o(to,`isDataTypeInternal`);function no(e){if(!gi(e)){if(e.inferredType)return e.inferredType.name;if(e.dataType)return e.dataType;if(e.returnType){let t=e.returnType.ref;if(t)return t.name}}}o(no,`getExplicitRuleType`);function ro(e){if(Wn(e))return Xr(e)&&Qa(e)?e.name:no(e)??e.name;if(Pr(e)||bi(e)||ni(e))return e.name;if(Xn(e)){let t=io(e);if(t)return t}else if(Er(e))return e.name;throw Error(`Cannot get name of Unknown Type`)}o(ro,`getTypeName`);function io(e){if(e.inferredType)return e.inferredType.name;if(e.type?.ref)return ro(e.type.ref)}o(io,`getActionType`);function ao(e){return gi(e)?e.type?.name??`string`:Xr(e)&&Qa(e)?e.name:no(e)??e.name}o(ao,`getRuleTypeName`);function oo(e){return gi(e)?e.type?.name??`string`:no(e)??e.name}o(oo,`getRuleType`);function so(e){let t={s:!1,i:!1,u:!1},n=lo(e.definition,t),r=Object.entries(t).filter(([,e])=>e).map(([e])=>e).join(``);return new RegExp(n,r)}o(so,`terminalRegex`);var co=`[\\s\\S]`;function lo(e,t){if(ui(e))return uo(e);if(mi(e))return fo(e);if(cr(e))return ho(e);if(vi(e)){let t=e.rule.ref;if(!t)throw Error(`Missing rule reference.`);return _o(lo(t.definition),{cardinality:e.cardinality,lookahead:e.lookahead,parenthesized:e.parenthesized})}else if(Br(e))return mo(e);else if(Ai(e))return po(e);else if(ei(e)){let n=e.regex.lastIndexOf(`/`),r=e.regex.substring(1,n),i=e.regex.substring(n+1);return t&&(t.i=i.includes(`i`),t.s=i.includes(`s`),t.u=i.includes(`u`)),_o(r,{cardinality:e.cardinality,lookahead:e.lookahead,parenthesized:e.parenthesized,wrap:!1})}else if(Pi(e))return _o(co,{cardinality:e.cardinality,lookahead:e.lookahead,parenthesized:e.parenthesized});else throw Error(`Invalid terminal element: ${e?.$type}, ${e?.$cstNode?.text}`)}o(lo,`abstractElementToRegex`);function uo(e){return _o(e.elements.map(e=>lo(e)).join(`|`),{cardinality:e.cardinality,lookahead:e.lookahead,parenthesized:e.parenthesized,wrap:!1})}o(uo,`terminalAlternativesToRegex`);function fo(e){return _o(e.elements.map(e=>lo(e)).join(``),{cardinality:e.cardinality,lookahead:e.lookahead,parenthesized:e.parenthesized,wrap:!1})}o(fo,`terminalGroupToRegex`);function po(e){return _o(`${co}*?${lo(e.terminal)}`,{cardinality:e.cardinality,lookahead:e.lookahead,parenthesized:e.parenthesized})}o(po,`untilTokenToRegex`);function mo(e){return _o(`(?!${lo(e.terminal)})${co}*?`,{cardinality:e.cardinality,lookahead:e.lookahead,parenthesized:e.parenthesized})}o(mo,`negateTokenToRegex`);function ho(e){return e.right?_o(`[${go(e.left)}-${go(e.right)}]`,{cardinality:e.cardinality,lookahead:e.lookahead,parenthesized:e.parenthesized,wrap:!1}):_o(go(e.left),{cardinality:e.cardinality,lookahead:e.lookahead,parenthesized:e.parenthesized,wrap:!1})}o(ho,`characterRangeToRegex`);function go(e){return ka(e.value)}o(go,`keywordToRegex`);function _o(e,t){return(t.parenthesized||t.lookahead||t.wrap!==!1)&&(e=`(${t.lookahead??(t.parenthesized?``:`?:`)}${e})`),t.cardinality?`${e}${t.cardinality}`:e}o(_o,`withCardinality`);function vo(e){let t=[],n=e.Grammar;for(let e of n.rules)gi(e)&&Ra(e)&&Ea(so(e))&&t.push(e.name);return{multilineCommentRules:t,nameRegexp:Gi}}o(vo,`createGrammarConfig`);var yo=typeof global==`object`&&global&&global.Object===Object&&global,bo=typeof self==`object`&&self&&self.Object===Object&&self,xo=yo||bo||Function(`return this`)(),So=xo.Symbol,Co=Object.prototype,wo=Co.hasOwnProperty,To=Co.toString,Eo=So?So.toStringTag:void 0;function Do(e){var t=wo.call(e,Eo),n=e[Eo];try{e[Eo]=void 0;var r=!0}catch{}var i=To.call(e);return r&&(t?e[Eo]=n:delete e[Eo]),i}o(Do,`getRawTag`);var Oo=Do,ko=Object.prototype.toString;function Ao(e){return ko.call(e)}o(Ao,`objectToString`);var jo=Ao,Mo=`[object Null]`,No=`[object Undefined]`,Po=So?So.toStringTag:void 0;function Fo(e){return e==null?e===void 0?No:Mo:Po&&Po in Object(e)?Oo(e):jo(e)}o(Fo,`baseGetTag`);var Io=Fo;function Lo(e){return typeof e==`object`&&!!e}o(Lo,`isObjectLike`);var Ro=Lo,zo=`[object Symbol]`;function Bo(e){return typeof e==`symbol`||Ro(e)&&Io(e)==zo}o(Bo,`isSymbol`);var Vo=Bo;function Ho(e,t){for(var n=-1,r=e==null?0:e.length,i=Array(r);++n<r;)i[n]=t(e[n],n,e);return i}o(Ho,`arrayMap`);var Uo=Ho,F=Array.isArray,Wo=1/0,Go=So?So.prototype:void 0,Ko=Go?Go.toString:void 0;function qo(e){if(typeof e==`string`)return e;if(F(e))return Uo(e,qo)+``;if(Vo(e))return Ko?Ko.call(e):``;var t=e+``;return t==`0`&&1/e==-Wo?`-0`:t}o(qo,`baseToString`);var Jo=qo,Yo=/\s/;function Xo(e){for(var t=e.length;t--&&Yo.test(e.charAt(t)););return t}o(Xo,`trimmedEndIndex`);var Zo=Xo,Qo=/^\s+/;function $o(e){return e&&e.slice(0,Zo(e)+1).replace(Qo,``)}o($o,`baseTrim`);var es=$o;function ts(e){var t=typeof e;return e!=null&&(t==`object`||t==`function`)}o(ts,`isObject`);var ns=ts,rs=NaN,is=/^[-+]0x[0-9a-f]+$/i,as=/^0b[01]+$/i,os=/^0o[0-7]+$/i,ss=parseInt;function cs(e){if(typeof e==`number`)return e;if(Vo(e))return rs;if(ns(e)){var t=typeof e.valueOf==`function`?e.valueOf():e;e=ns(t)?t+``:t}if(typeof e!=`string`)return e===0?e:+e;e=es(e);var n=as.test(e);return n||os.test(e)?ss(e.slice(2),n?2:8):is.test(e)?rs:+e}o(cs,`toNumber`);var ls=cs,us=1/0,ds=17976931348623157e292;function fs(e){return e?(e=ls(e),e===us||e===-us?(e<0?-1:1)*ds:e===e?e:0):e===0?e:0}o(fs,`toFinite`);var ps=fs;function ms(e){var t=ps(e),n=t%1;return t===t?n?t-n:t:0}o(ms,`toInteger`);var hs=ms;function gs(e){return e}o(gs,`identity`);var _s=gs,vs=`[object AsyncFunction]`,ys=`[object Function]`,bs=`[object GeneratorFunction]`,xs=`[object Proxy]`;function Ss(e){if(!ns(e))return!1;var t=Io(e);return t==ys||t==bs||t==vs||t==xs}o(Ss,`isFunction`);var Cs=Ss,ws=xo[`__core-js_shared__`],Ts=(function(){var e=/[^.]+$/.exec(ws&&ws.keys&&ws.keys.IE_PROTO||``);return e?`Symbol(src)_1.`+e:``})();function Es(e){return!!Ts&&Ts in e}o(Es,`isMasked`);var Ds=Es,Os=Function.prototype.toString;function ks(e){if(e!=null){try{return Os.call(e)}catch{}try{return e+``}catch{}}return``}o(ks,`toSource`);var As=ks,js=/[\\^$.*+?()[\]{}|]/g,Ms=/^\[object .+?Constructor\]$/,Ns=Function.prototype,Ps=Object.prototype,Fs=Ns.toString,Is=Ps.hasOwnProperty,Ls=RegExp(`^`+Fs.call(Is).replace(js,`\\$&`).replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,`$1.*?`)+`$`);function Rs(e){return!ns(e)||Ds(e)?!1:(Cs(e)?Ls:Ms).test(As(e))}o(Rs,`baseIsNative`);var zs=Rs;function Bs(e,t){return e?.[t]}o(Bs,`getValue`);var Vs=Bs;function Hs(e,t){var n=Vs(e,t);return zs(n)?n:void 0}o(Hs,`getNative`);var Us=Hs,Ws=Us(xo,`WeakMap`),Gs=Object.create,Ks=(function(){function e(){}return o(e,`object`),function(t){if(!ns(t))return{};if(Gs)return Gs(t);e.prototype=t;var n=new e;return e.prototype=void 0,n}})();function qs(e,t,n){switch(n.length){case 0:return e.call(t);case 1:return e.call(t,n[0]);case 2:return e.call(t,n[0],n[1]);case 3:return e.call(t,n[0],n[1],n[2])}return e.apply(t,n)}o(qs,`apply`);var Js=qs;function Ys(){}o(Ys,`noop`);var I=Ys;function Xs(e,t){var n=-1,r=e.length;for(t||=Array(r);++n<r;)t[n]=e[n];return t}o(Xs,`copyArray`);var Zs=Xs,Qs=800,$s=16,ec=Date.now;function tc(e){var t=0,n=0;return function(){var r=ec(),i=$s-(r-n);if(n=r,i>0){if(++t>=Qs)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}o(tc,`shortOut`);var nc=tc;function rc(e){return function(){return e}}o(rc,`constant`);var ic=rc,ac=(function(){try{var e=Us(Object,`defineProperty`);return e({},``,{}),e}catch{}})(),oc=nc(ac?function(e,t){return ac(e,`toString`,{configurable:!0,enumerable:!1,value:ic(t),writable:!0})}:_s);function sc(e,t){for(var n=-1,r=e==null?0:e.length;++n<r&&t(e[n],n,e)!==!1;);return e}o(sc,`arrayEach`);var cc=sc;function lc(e,t,n,r){for(var i=e.length,a=n+(r?1:-1);r?a--:++a<i;)if(t(e[a],a,e))return a;return-1}o(lc,`baseFindIndex`);var uc=lc;function dc(e){return e!==e}o(dc,`baseIsNaN`);var fc=dc;function pc(e,t,n){for(var r=n-1,i=e.length;++r<i;)if(e[r]===t)return r;return-1}o(pc,`strictIndexOf`);var mc=pc;function hc(e,t,n){return t===t?mc(e,t,n):uc(e,fc,n)}o(hc,`baseIndexOf`);var gc=hc;function _c(e,t){return!!(e!=null&&e.length)&&gc(e,t,0)>-1}o(_c,`arrayIncludes`);var vc=_c,yc=9007199254740991,bc=/^(?:0|[1-9]\d*)$/;function xc(e,t){var n=typeof e;return t??=yc,!!t&&(n==`number`||n!=`symbol`&&bc.test(e))&&e>-1&&e%1==0&&e<t}o(xc,`isIndex`);var Sc=xc;function Cc(e,t,n){t==`__proto__`&&ac?ac(e,t,{configurable:!0,enumerable:!0,value:n,writable:!0}):e[t]=n}o(Cc,`baseAssignValue`);var wc=Cc;function Tc(e,t){return e===t||e!==e&&t!==t}o(Tc,`eq`);var Ec=Tc,Dc=Object.prototype.hasOwnProperty;function Oc(e,t,n){var r=e[t];(!(Dc.call(e,t)&&Ec(r,n))||n===void 0&&!(t in e))&&wc(e,t,n)}o(Oc,`assignValue`);var kc=Oc;function Ac(e,t,n,r){var i=!n;n||={};for(var a=-1,o=t.length;++a<o;){var s=t[a],c=r?r(n[s],e[s],s,n,e):void 0;c===void 0&&(c=e[s]),i?wc(n,s,c):kc(n,s,c)}return n}o(Ac,`copyObject`);var jc=Ac,Mc=Math.max;function Nc(e,t,n){return t=Mc(t===void 0?e.length-1:t,0),function(){for(var r=arguments,i=-1,a=Mc(r.length-t,0),o=Array(a);++i<a;)o[i]=r[t+i];i=-1;for(var s=Array(t+1);++i<t;)s[i]=r[i];return s[t]=n(o),Js(e,this,s)}}o(Nc,`overRest`);var Pc=Nc;function Fc(e,t){return oc(Pc(e,t,_s),e+``)}o(Fc,`baseRest`);var Ic=Fc,Lc=9007199254740991;function Rc(e){return typeof e==`number`&&e>-1&&e%1==0&&e<=Lc}o(Rc,`isLength`);var zc=Rc;function Bc(e){return e!=null&&zc(e.length)&&!Cs(e)}o(Bc,`isArrayLike`);var Vc=Bc;function Hc(e,t,n){if(!ns(n))return!1;var r=typeof t;return(r==`number`?Vc(n)&&Sc(t,n.length):r==`string`&&t in n)?Ec(n[t],e):!1}o(Hc,`isIterateeCall`);var Uc=Hc;function Wc(e){return Ic(function(t,n){var r=-1,i=n.length,a=i>1?n[i-1]:void 0,o=i>2?n[2]:void 0;for(a=e.length>3&&typeof a==`function`?(i--,a):void 0,o&&Uc(n[0],n[1],o)&&(a=i<3?void 0:a,i=1),t=Object(t);++r<i;){var s=n[r];s&&e(t,s,r,a)}return t})}o(Wc,`createAssigner`);var Gc=Wc,Kc=Object.prototype;function qc(e){var t=e&&e.constructor;return e===(typeof t==`function`&&t.prototype||Kc)}o(qc,`isPrototype`);var Jc=qc;function Yc(e,t){for(var n=-1,r=Array(e);++n<e;)r[n]=t(n);return r}o(Yc,`baseTimes`);var Xc=Yc,Zc=`[object Arguments]`;function Qc(e){return Ro(e)&&Io(e)==Zc}o(Qc,`baseIsArguments`);var $c=Qc,el=Object.prototype,tl=el.hasOwnProperty,nl=el.propertyIsEnumerable,rl=$c((function(){return arguments})())?$c:function(e){return Ro(e)&&tl.call(e,`callee`)&&!nl.call(e,`callee`)};function il(){return!1}o(il,`stubFalse`);var al=il,ol=typeof exports==`object`&&exports&&!exports.nodeType&&exports,sl=ol&&typeof module==`object`&&module&&!module.nodeType&&module,cl=sl&&sl.exports===ol?xo.Buffer:void 0,ll=(cl?cl.isBuffer:void 0)||al,ul=`[object Arguments]`,dl=`[object Array]`,fl=`[object Boolean]`,pl=`[object Date]`,ml=`[object Error]`,hl=`[object Function]`,gl=`[object Map]`,_l=`[object Number]`,vl=`[object Object]`,yl=`[object RegExp]`,bl=`[object Set]`,xl=`[object String]`,Sl=`[object WeakMap]`,Cl=`[object ArrayBuffer]`,wl=`[object DataView]`,Tl=`[object Float32Array]`,El=`[object Float64Array]`,Dl=`[object Int8Array]`,Ol=`[object Int16Array]`,kl=`[object Int32Array]`,Al=`[object Uint8Array]`,jl=`[object Uint8ClampedArray]`,Ml=`[object Uint16Array]`,Nl=`[object Uint32Array]`,L={};L[Tl]=L[El]=L[Dl]=L[Ol]=L[kl]=L[Al]=L[jl]=L[Ml]=L[Nl]=!0,L[ul]=L[dl]=L[Cl]=L[fl]=L[wl]=L[pl]=L[ml]=L[hl]=L[gl]=L[_l]=L[vl]=L[yl]=L[bl]=L[xl]=L[Sl]=!1;function Pl(e){return Ro(e)&&zc(e.length)&&!!L[Io(e)]}o(Pl,`baseIsTypedArray`);var Fl=Pl;function Il(e){return function(t){return e(t)}}o(Il,`baseUnary`);var Ll=Il,Rl=typeof exports==`object`&&exports&&!exports.nodeType&&exports,zl=Rl&&typeof module==`object`&&module&&!module.nodeType&&module,Bl=zl&&zl.exports===Rl&&yo.process,Vl=(function(){try{return zl&&zl.require&&zl.require(`util`).types||Bl&&Bl.binding&&Bl.binding(`util`)}catch{}})(),Hl=Vl&&Vl.isTypedArray,Ul=Hl?Ll(Hl):Fl,Wl=Object.prototype.hasOwnProperty;function Gl(e,t){var n=F(e),r=!n&&rl(e),i=!n&&!r&&ll(e),a=!n&&!r&&!i&&Ul(e),o=n||r||i||a,s=o?Xc(e.length,String):[],c=s.length;for(var l in e)(t||Wl.call(e,l))&&!(o&&(l==`length`||i&&(l==`offset`||l==`parent`)||a&&(l==`buffer`||l==`byteLength`||l==`byteOffset`)||Sc(l,c)))&&s.push(l);return s}o(Gl,`arrayLikeKeys`);var Kl=Gl;function ql(e,t){return function(n){return e(t(n))}}o(ql,`overArg`);var Jl=ql,Yl=Jl(Object.keys,Object),Xl=Object.prototype.hasOwnProperty;function Zl(e){if(!Jc(e))return Yl(e);var t=[];for(var n in Object(e))Xl.call(e,n)&&n!=`constructor`&&t.push(n);return t}o(Zl,`baseKeys`);var Ql=Zl;function $l(e){return Vc(e)?Kl(e):Ql(e)}o($l,`keys`);var eu=$l,tu=Object.prototype.hasOwnProperty,nu=Gc(function(e,t){if(Jc(t)||Vc(t)){jc(t,eu(t),e);return}for(var n in t)tu.call(t,n)&&kc(e,n,t[n])});function ru(e){var t=[];if(e!=null)for(var n in Object(e))t.push(n);return t}o(ru,`nativeKeysIn`);var iu=ru,au=Object.prototype.hasOwnProperty;function ou(e){if(!ns(e))return iu(e);var t=Jc(e),n=[];for(var r in e)r==`constructor`&&(t||!au.call(e,r))||n.push(r);return n}o(ou,`baseKeysIn`);var su=ou;function cu(e){return Vc(e)?Kl(e,!0):su(e)}o(cu,`keysIn`);var lu=cu,uu=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,du=/^\w*$/;function fu(e,t){if(F(e))return!1;var n=typeof e;return n==`number`||n==`symbol`||n==`boolean`||e==null||Vo(e)?!0:du.test(e)||!uu.test(e)||t!=null&&e in Object(t)}o(fu,`isKey`);var pu=fu,mu=Us(Object,`create`);function hu(){this.__data__=mu?mu(null):{},this.size=0}o(hu,`hashClear`);var gu=hu;function _u(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=+!!t,t}o(_u,`hashDelete`);var vu=_u,yu=`__lodash_hash_undefined__`,bu=Object.prototype.hasOwnProperty;function xu(e){var t=this.__data__;if(mu){var n=t[e];return n===yu?void 0:n}return bu.call(t,e)?t[e]:void 0}o(xu,`hashGet`);var Su=xu,Cu=Object.prototype.hasOwnProperty;function wu(e){var t=this.__data__;return mu?t[e]!==void 0:Cu.call(t,e)}o(wu,`hashHas`);var Tu=wu,Eu=`__lodash_hash_undefined__`;function Du(e,t){var n=this.__data__;return this.size+=+!this.has(e),n[e]=mu&&t===void 0?Eu:t,this}o(Du,`hashSet`);var Ou=Du;function ku(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}o(ku,`Hash`),ku.prototype.clear=gu,ku.prototype.delete=vu,ku.prototype.get=Su,ku.prototype.has=Tu,ku.prototype.set=Ou;var Au=ku;function ju(){this.__data__=[],this.size=0}o(ju,`listCacheClear`);var Mu=ju;function Nu(e,t){for(var n=e.length;n--;)if(Ec(e[n][0],t))return n;return-1}o(Nu,`assocIndexOf`);var Pu=Nu,Fu=Array.prototype.splice;function Iu(e){var t=this.__data__,n=Pu(t,e);return n<0?!1:(n==t.length-1?t.pop():Fu.call(t,n,1),--this.size,!0)}o(Iu,`listCacheDelete`);var Lu=Iu;function Ru(e){var t=this.__data__,n=Pu(t,e);return n<0?void 0:t[n][1]}o(Ru,`listCacheGet`);var zu=Ru;function Bu(e){return Pu(this.__data__,e)>-1}o(Bu,`listCacheHas`);var Vu=Bu;function Hu(e,t){var n=this.__data__,r=Pu(n,e);return r<0?(++this.size,n.push([e,t])):n[r][1]=t,this}o(Hu,`listCacheSet`);var Uu=Hu;function Wu(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}o(Wu,`ListCache`),Wu.prototype.clear=Mu,Wu.prototype.delete=Lu,Wu.prototype.get=zu,Wu.prototype.has=Vu,Wu.prototype.set=Uu;var Gu=Wu,Ku=Us(xo,`Map`);function qu(){this.size=0,this.__data__={hash:new Au,map:new(Ku||Gu),string:new Au}}o(qu,`mapCacheClear`);var Ju=qu;function Yu(e){var t=typeof e;return t==`string`||t==`number`||t==`symbol`||t==`boolean`?e!==`__proto__`:e===null}o(Yu,`isKeyable`);var Xu=Yu;function Zu(e,t){var n=e.__data__;return Xu(t)?n[typeof t==`string`?`string`:`hash`]:n.map}o(Zu,`getMapData`);var Qu=Zu;function $u(e){var t=Qu(this,e).delete(e);return this.size-=+!!t,t}o($u,`mapCacheDelete`);var ed=$u;function td(e){return Qu(this,e).get(e)}o(td,`mapCacheGet`);var nd=td;function rd(e){return Qu(this,e).has(e)}o(rd,`mapCacheHas`);var id=rd;function ad(e,t){var n=Qu(this,e),r=n.size;return n.set(e,t),this.size+=n.size==r?0:1,this}o(ad,`mapCacheSet`);var od=ad;function sd(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}o(sd,`MapCache`),sd.prototype.clear=Ju,sd.prototype.delete=ed,sd.prototype.get=nd,sd.prototype.has=id,sd.prototype.set=od;var cd=sd,ld=`Expected a function`;function ud(e,t){if(typeof e!=`function`||t!=null&&typeof t!=`function`)throw TypeError(ld);var n=o(function(){var r=arguments,i=t?t.apply(this,r):r[0],a=n.cache;if(a.has(i))return a.get(i);var o=e.apply(this,r);return n.cache=a.set(i,o)||a,o},`memoized`);return n.cache=new(ud.Cache||cd),n}o(ud,`memoize`),ud.Cache=cd;var dd=ud,fd=500;function pd(e){var t=dd(e,function(e){return n.size===fd&&n.clear(),e}),n=t.cache;return t}o(pd,`memoizeCapped`);var md=pd,hd=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,gd=/\\(\\)?/g,_d=md(function(e){var t=[];return e.charCodeAt(0)===46&&t.push(``),e.replace(hd,function(e,n,r,i){t.push(r?i.replace(gd,`$1`):n||e)}),t});function vd(e){return e==null?``:Jo(e)}o(vd,`toString`);var yd=vd;function bd(e,t){return F(e)?e:pu(e,t)?[e]:_d(yd(e))}o(bd,`castPath`);var xd=bd,Sd=1/0;function Cd(e){if(typeof e==`string`||Vo(e))return e;var t=e+``;return t==`0`&&1/e==-Sd?`-0`:t}o(Cd,`toKey`);var wd=Cd;function Td(e,t){t=xd(t,e);for(var n=0,r=t.length;e!=null&&n<r;)e=e[wd(t[n++])];return n&&n==r?e:void 0}o(Td,`baseGet`);var Ed=Td;function Dd(e,t,n){var r=e==null?void 0:Ed(e,t);return r===void 0?n:r}o(Dd,`get`);var Od=Dd;function kd(e,t){for(var n=-1,r=t.length,i=e.length;++n<r;)e[i+n]=t[n];return e}o(kd,`arrayPush`);var Ad=kd,jd=So?So.isConcatSpreadable:void 0;function Md(e){return F(e)||rl(e)||!!(jd&&e&&e[jd])}o(Md,`isFlattenable`);var Nd=Md;function Pd(e,t,n,r,i){var a=-1,o=e.length;for(n||=Nd,i||=[];++a<o;){var s=e[a];t>0&&n(s)?t>1?Pd(s,t-1,n,r,i):Ad(i,s):r||(i[i.length]=s)}return i}o(Pd,`baseFlatten`);var Fd=Pd;function Id(e){return e!=null&&e.length?Fd(e,1):[]}o(Id,`flatten`);var Ld=Id,Rd=Jl(Object.getPrototypeOf,Object);function zd(e,t,n){var r=-1,i=e.length;t<0&&(t=-t>i?0:i+t),n=n>i?i:n,n<0&&(n+=i),i=t>n?0:n-t>>>0,t>>>=0;for(var a=Array(i);++r<i;)a[r]=e[r+t];return a}o(zd,`baseSlice`);var Bd=zd;function Vd(e,t,n,r){var i=-1,a=e==null?0:e.length;for(r&&a&&(n=e[++i]);++i<a;)n=t(n,e[i],i,e);return n}o(Vd,`arrayReduce`);var Hd=Vd;function Ud(){this.__data__=new Gu,this.size=0}o(Ud,`stackClear`);var Wd=Ud;function Gd(e){var t=this.__data__,n=t.delete(e);return this.size=t.size,n}o(Gd,`stackDelete`);var Kd=Gd;function qd(e){return this.__data__.get(e)}o(qd,`stackGet`);var Jd=qd;function Yd(e){return this.__data__.has(e)}o(Yd,`stackHas`);var Xd=Yd,Zd=200;function Qd(e,t){var n=this.__data__;if(n instanceof Gu){var r=n.__data__;if(!Ku||r.length<Zd-1)return r.push([e,t]),this.size=++n.size,this;n=this.__data__=new cd(r)}return n.set(e,t),this.size=n.size,this}o(Qd,`stackSet`);var $d=Qd;function ef(e){var t=this.__data__=new Gu(e);this.size=t.size}o(ef,`Stack`),ef.prototype.clear=Wd,ef.prototype.delete=Kd,ef.prototype.get=Jd,ef.prototype.has=Xd,ef.prototype.set=$d;var tf=ef;function nf(e,t){return e&&jc(t,eu(t),e)}o(nf,`baseAssign`);var rf=nf;function af(e,t){return e&&jc(t,lu(t),e)}o(af,`baseAssignIn`);var of=af,sf=typeof exports==`object`&&exports&&!exports.nodeType&&exports,cf=sf&&typeof module==`object`&&module&&!module.nodeType&&module,lf=cf&&cf.exports===sf?xo.Buffer:void 0,uf=lf?lf.allocUnsafe:void 0;function df(e,t){if(t)return e.slice();var n=e.length,r=uf?uf(n):new e.constructor(n);return e.copy(r),r}o(df,`cloneBuffer`);var ff=df;function pf(e,t){for(var n=-1,r=e==null?0:e.length,i=0,a=[];++n<r;){var o=e[n];t(o,n,e)&&(a[i++]=o)}return a}o(pf,`arrayFilter`);var mf=pf;function hf(){return[]}o(hf,`stubArray`);var gf=hf,_f=Object.prototype.propertyIsEnumerable,vf=Object.getOwnPropertySymbols,yf=vf?function(e){return e==null?[]:(e=Object(e),mf(vf(e),function(t){return _f.call(e,t)}))}:gf;function bf(e,t){return jc(e,yf(e),t)}o(bf,`copySymbols`);var xf=bf,Sf=Object.getOwnPropertySymbols?function(e){for(var t=[];e;)Ad(t,yf(e)),e=Rd(e);return t}:gf;function Cf(e,t){return jc(e,Sf(e),t)}o(Cf,`copySymbolsIn`);var wf=Cf;function Tf(e,t,n){var r=t(e);return F(e)?r:Ad(r,n(e))}o(Tf,`baseGetAllKeys`);var Ef=Tf;function Df(e){return Ef(e,eu,yf)}o(Df,`getAllKeys`);var Of=Df;function kf(e){return Ef(e,lu,Sf)}o(kf,`getAllKeysIn`);var Af=kf,jf=Us(xo,`DataView`),Mf=Us(xo,`Promise`),Nf=Us(xo,`Set`),Pf=`[object Map]`,Ff=`[object Object]`,If=`[object Promise]`,Lf=`[object Set]`,Rf=`[object WeakMap]`,zf=`[object DataView]`,Bf=As(jf),Vf=As(Ku),Hf=As(Mf),Uf=As(Nf),Wf=As(Ws),Gf=Io;(jf&&Gf(new jf(new ArrayBuffer(1)))!=zf||Ku&&Gf(new Ku)!=Pf||Mf&&Gf(Mf.resolve())!=If||Nf&&Gf(new Nf)!=Lf||Ws&&Gf(new Ws)!=Rf)&&(Gf=o(function(e){var t=Io(e),n=t==Ff?e.constructor:void 0,r=n?As(n):``;if(r)switch(r){case Bf:return zf;case Vf:return Pf;case Hf:return If;case Uf:return Lf;case Wf:return Rf}return t},`getTag`));var Kf=Gf,qf=Object.prototype.hasOwnProperty;function Jf(e){var t=e.length,n=new e.constructor(t);return t&&typeof e[0]==`string`&&qf.call(e,`index`)&&(n.index=e.index,n.input=e.input),n}o(Jf,`initCloneArray`);var Yf=Jf,Xf=xo.Uint8Array;function Zf(e){var t=new e.constructor(e.byteLength);return new Xf(t).set(new Xf(e)),t}o(Zf,`cloneArrayBuffer`);var Qf=Zf;function $f(e,t){var n=t?Qf(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.byteLength)}o($f,`cloneDataView`);var ep=$f,tp=/\w*$/;function np(e){var t=new e.constructor(e.source,tp.exec(e));return t.lastIndex=e.lastIndex,t}o(np,`cloneRegExp`);var rp=np,ip=So?So.prototype:void 0,ap=ip?ip.valueOf:void 0;function op(e){return ap?Object(ap.call(e)):{}}o(op,`cloneSymbol`);var sp=op;function cp(e,t){var n=t?Qf(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.length)}o(cp,`cloneTypedArray`);var lp=cp,up=`[object Boolean]`,dp=`[object Date]`,fp=`[object Map]`,pp=`[object Number]`,mp=`[object RegExp]`,hp=`[object Set]`,gp=`[object String]`,_p=`[object Symbol]`,vp=`[object ArrayBuffer]`,yp=`[object DataView]`,bp=`[object Float32Array]`,xp=`[object Float64Array]`,Sp=`[object Int8Array]`,Cp=`[object Int16Array]`,wp=`[object Int32Array]`,Tp=`[object Uint8Array]`,Ep=`[object Uint8ClampedArray]`,Dp=`[object Uint16Array]`,Op=`[object Uint32Array]`;function kp(e,t,n){var r=e.constructor;switch(t){case vp:return Qf(e);case up:case dp:return new r(+e);case yp:return ep(e,n);case bp:case xp:case Sp:case Cp:case wp:case Tp:case Ep:case Dp:case Op:return lp(e,n);case fp:return new r;case pp:case gp:return new r(e);case mp:return rp(e);case hp:return new r;case _p:return sp(e)}}o(kp,`initCloneByTag`);var Ap=kp;function jp(e){return typeof e.constructor==`function`&&!Jc(e)?Ks(Rd(e)):{}}o(jp,`initCloneObject`);var Mp=jp,Np=`[object Map]`;function Pp(e){return Ro(e)&&Kf(e)==Np}o(Pp,`baseIsMap`);var Fp=Pp,Ip=Vl&&Vl.isMap,Lp=Ip?Ll(Ip):Fp,Rp=`[object Set]`;function zp(e){return Ro(e)&&Kf(e)==Rp}o(zp,`baseIsSet`);var Bp=zp,Vp=Vl&&Vl.isSet,Hp=Vp?Ll(Vp):Bp,Up=1,Wp=2,Gp=4,Kp=`[object Arguments]`,qp=`[object Array]`,Jp=`[object Boolean]`,Yp=`[object Date]`,Xp=`[object Error]`,Zp=`[object Function]`,Qp=`[object GeneratorFunction]`,$p=`[object Map]`,em=`[object Number]`,tm=`[object Object]`,nm=`[object RegExp]`,rm=`[object Set]`,im=`[object String]`,am=`[object Symbol]`,om=`[object WeakMap]`,sm=`[object ArrayBuffer]`,cm=`[object DataView]`,lm=`[object Float32Array]`,um=`[object Float64Array]`,dm=`[object Int8Array]`,fm=`[object Int16Array]`,pm=`[object Int32Array]`,mm=`[object Uint8Array]`,hm=`[object Uint8ClampedArray]`,gm=`[object Uint16Array]`,_m=`[object Uint32Array]`,R={};R[Kp]=R[qp]=R[sm]=R[cm]=R[Jp]=R[Yp]=R[lm]=R[um]=R[dm]=R[fm]=R[pm]=R[$p]=R[em]=R[tm]=R[nm]=R[rm]=R[im]=R[am]=R[mm]=R[hm]=R[gm]=R[_m]=!0,R[Xp]=R[Zp]=R[om]=!1;function vm(e,t,n,r,i,a){var o,s=t&Up,c=t&Wp,l=t&Gp;if(n&&(o=i?n(e,r,i,a):n(e)),o!==void 0)return o;if(!ns(e))return e;var u=F(e);if(u){if(o=Yf(e),!s)return Zs(e,o)}else{var d=Kf(e),f=d==Zp||d==Qp;if(ll(e))return ff(e,s);if(d==tm||d==Kp||f&&!i){if(o=c||f?{}:Mp(e),!s)return c?wf(e,of(o,e)):xf(e,rf(o,e))}else{if(!R[d])return i?e:{};o=Ap(e,d,s)}}a||=new tf;var p=a.get(e);if(p)return p;a.set(e,o),Hp(e)?e.forEach(function(r){o.add(vm(r,t,n,r,e,a))}):Lp(e)&&e.forEach(function(r,i){o.set(i,vm(r,t,n,i,e,a))});var m=u?void 0:(l?c?Af:Of:c?lu:eu)(e);return cc(m||e,function(r,i){m&&(i=r,r=e[i]),kc(o,i,vm(r,t,n,i,e,a))}),o}o(vm,`baseClone`);var ym=vm,bm=4;function xm(e){return ym(e,bm)}o(xm,`clone`);var Sm=xm;function Cm(e){for(var t=-1,n=e==null?0:e.length,r=0,i=[];++t<n;){var a=e[t];a&&(i[r++]=a)}return i}o(Cm,`compact`);var wm=Cm,Tm=`__lodash_hash_undefined__`;function Em(e){return this.__data__.set(e,Tm),this}o(Em,`setCacheAdd`);var Dm=Em;function Om(e){return this.__data__.has(e)}o(Om,`setCacheHas`);var km=Om;function Am(e){var t=-1,n=e==null?0:e.length;for(this.__data__=new cd;++t<n;)this.add(e[t])}o(Am,`SetCache`),Am.prototype.add=Am.prototype.push=Dm,Am.prototype.has=km;var jm=Am;function Mm(e,t){for(var n=-1,r=e==null?0:e.length;++n<r;)if(t(e[n],n,e))return!0;return!1}o(Mm,`arraySome`);var Nm=Mm;function Pm(e,t){return e.has(t)}o(Pm,`cacheHas`);var Fm=Pm,Im=1,Lm=2;function Rm(e,t,n,r,i,a){var o=n&Im,s=e.length,c=t.length;if(s!=c&&!(o&&c>s))return!1;var l=a.get(e),u=a.get(t);if(l&&u)return l==t&&u==e;var d=-1,f=!0,p=n&Lm?new jm:void 0;for(a.set(e,t),a.set(t,e);++d<s;){var m=e[d],h=t[d];if(r)var g=o?r(h,m,d,t,e,a):r(m,h,d,e,t,a);if(g!==void 0){if(g)continue;f=!1;break}if(p){if(!Nm(t,function(e,t){if(!Fm(p,t)&&(m===e||i(m,e,n,r,a)))return p.push(t)})){f=!1;break}}else if(!(m===h||i(m,h,n,r,a))){f=!1;break}}return a.delete(e),a.delete(t),f}o(Rm,`equalArrays`);var zm=Rm;function Bm(e){var t=-1,n=Array(e.size);return e.forEach(function(e,r){n[++t]=[r,e]}),n}o(Bm,`mapToArray`);var Vm=Bm;function Hm(e){var t=-1,n=Array(e.size);return e.forEach(function(e){n[++t]=e}),n}o(Hm,`setToArray`);var Um=Hm,Wm=1,Gm=2,Km=`[object Boolean]`,qm=`[object Date]`,Jm=`[object Error]`,Ym=`[object Map]`,Xm=`[object Number]`,Zm=`[object RegExp]`,Qm=`[object Set]`,$m=`[object String]`,eh=`[object Symbol]`,th=`[object ArrayBuffer]`,nh=`[object DataView]`,rh=So?So.prototype:void 0,ih=rh?rh.valueOf:void 0;function ah(e,t,n,r,i,a,o){switch(n){case nh:if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case th:return!(e.byteLength!=t.byteLength||!a(new Xf(e),new Xf(t)));case Km:case qm:case Xm:return Ec(+e,+t);case Jm:return e.name==t.name&&e.message==t.message;case Zm:case $m:return e==t+``;case Ym:var s=Vm;case Qm:var c=r&Wm;if(s||=Um,e.size!=t.size&&!c)return!1;var l=o.get(e);if(l)return l==t;r|=Gm,o.set(e,t);var u=zm(s(e),s(t),r,i,a,o);return o.delete(e),u;case eh:if(ih)return ih.call(e)==ih.call(t)}return!1}o(ah,`equalByTag`);var oh=ah,sh=1,ch=Object.prototype.hasOwnProperty;function lh(e,t,n,r,i,a){var o=n&sh,s=Of(e),c=s.length;if(c!=Of(t).length&&!o)return!1;for(var l=c;l--;){var u=s[l];if(!(o?u in t:ch.call(t,u)))return!1}var d=a.get(e),f=a.get(t);if(d&&f)return d==t&&f==e;var p=!0;a.set(e,t),a.set(t,e);for(var m=o;++l<c;){u=s[l];var h=e[u],g=t[u];if(r)var _=o?r(g,h,u,t,e,a):r(h,g,u,e,t,a);if(!(_===void 0?h===g||i(h,g,n,r,a):_)){p=!1;break}m||=u==`constructor`}if(p&&!m){var v=e.constructor,y=t.constructor;v!=y&&`constructor`in e&&`constructor`in t&&!(typeof v==`function`&&v instanceof v&&typeof y==`function`&&y instanceof y)&&(p=!1)}return a.delete(e),a.delete(t),p}o(lh,`equalObjects`);var uh=lh,dh=1,fh=`[object Arguments]`,ph=`[object Array]`,mh=`[object Object]`,hh=Object.prototype.hasOwnProperty;function gh(e,t,n,r,i,a){var o=F(e),s=F(t),c=o?ph:Kf(e),l=s?ph:Kf(t);c=c==fh?mh:c,l=l==fh?mh:l;var u=c==mh,d=l==mh,f=c==l;if(f&&ll(e)){if(!ll(t))return!1;o=!0,u=!1}if(f&&!u)return a||=new tf,o||Ul(e)?zm(e,t,n,r,i,a):oh(e,t,c,n,r,i,a);if(!(n&dh)){var p=u&&hh.call(e,`__wrapped__`),m=d&&hh.call(t,`__wrapped__`);if(p||m){var h=p?e.value():e,g=m?t.value():t;return a||=new tf,i(h,g,n,r,a)}}return f?(a||=new tf,uh(e,t,n,r,i,a)):!1}o(gh,`baseIsEqualDeep`);var _h=gh;function vh(e,t,n,r,i){return e===t?!0:e==null||t==null||!Ro(e)&&!Ro(t)?e!==e&&t!==t:_h(e,t,n,r,vh,i)}o(vh,`baseIsEqual`);var yh=vh,bh=1,xh=2;function Sh(e,t,n,r){var i=n.length,a=i,o=!r;if(e==null)return!a;for(e=Object(e);i--;){var s=n[i];if(o&&s[2]?s[1]!==e[s[0]]:!(s[0]in e))return!1}for(;++i<a;){s=n[i];var c=s[0],l=e[c],u=s[1];if(o&&s[2]){if(l===void 0&&!(c in e))return!1}else{var d=new tf;if(r)var f=r(l,u,c,e,t,d);if(!(f===void 0?yh(u,l,bh|xh,r,d):f))return!1}}return!0}o(Sh,`baseIsMatch`);var Ch=Sh;function wh(e){return e===e&&!ns(e)}o(wh,`isStrictComparable`);var Th=wh;function Eh(e){for(var t=eu(e),n=t.length;n--;){var r=t[n],i=e[r];t[n]=[r,i,Th(i)]}return t}o(Eh,`getMatchData`);var Dh=Eh;function Oh(e,t){return function(n){return n==null?!1:n[e]===t&&(t!==void 0||e in Object(n))}}o(Oh,`matchesStrictComparable`);var kh=Oh;function Ah(e){var t=Dh(e);return t.length==1&&t[0][2]?kh(t[0][0],t[0][1]):function(n){return n===e||Ch(n,e,t)}}o(Ah,`baseMatches`);var jh=Ah;function Mh(e,t){return e!=null&&t in Object(e)}o(Mh,`baseHasIn`);var Nh=Mh;function Ph(e,t,n){t=xd(t,e);for(var r=-1,i=t.length,a=!1;++r<i;){var o=wd(t[r]);if(!(a=e!=null&&n(e,o)))break;e=e[o]}return a||++r!=i?a:(i=e==null?0:e.length,!!i&&zc(i)&&Sc(o,i)&&(F(e)||rl(e)))}o(Ph,`hasPath`);var Fh=Ph;function Ih(e,t){return e!=null&&Fh(e,t,Nh)}o(Ih,`hasIn`);var Lh=Ih,Rh=1,zh=2;function Bh(e,t){return pu(e)&&Th(t)?kh(wd(e),t):function(n){var r=Od(n,e);return r===void 0&&r===t?Lh(n,e):yh(t,r,Rh|zh)}}o(Bh,`baseMatchesProperty`);var Vh=Bh;function Hh(e){return function(t){return t?.[e]}}o(Hh,`baseProperty`);var Uh=Hh;function Wh(e){return function(t){return Ed(t,e)}}o(Wh,`basePropertyDeep`);var Gh=Wh;function Kh(e){return pu(e)?Uh(wd(e)):Gh(e)}o(Kh,`property`);var qh=Kh;function Jh(e){return typeof e==`function`?e:e==null?_s:typeof e==`object`?F(e)?Vh(e[0],e[1]):jh(e):qh(e)}o(Jh,`baseIteratee`);var Yh=Jh;function Xh(e,t,n,r){for(var i=-1,a=e==null?0:e.length;++i<a;){var o=e[i];t(r,o,n(o),e)}return r}o(Xh,`arrayAggregator`);var Zh=Xh;function Qh(e){return function(t,n,r){for(var i=-1,a=Object(t),o=r(t),s=o.length;s--;){var c=o[e?s:++i];if(n(a[c],c,a)===!1)break}return t}}o(Qh,`createBaseFor`);var $h=Qh();function eg(e,t){return e&&$h(e,t,eu)}o(eg,`baseForOwn`);var tg=eg;function ng(e,t){return function(n,r){if(n==null)return n;if(!Vc(n))return e(n,r);for(var i=n.length,a=t?i:-1,o=Object(n);(t?a--:++a<i)&&r(o[a],a,o)!==!1;);return n}}o(ng,`createBaseEach`);var rg=ng(tg);function ig(e,t,n,r){return rg(e,function(e,i,a){t(r,e,n(e),a)}),r}o(ig,`baseAggregator`);var ag=ig;function og(e,t){return function(n,r){var i=F(n)?Zh:ag,a=t?t():{};return i(n,e,Yh(r,2),a)}}o(og,`createAggregator`);var sg=og,cg=Object.prototype,lg=cg.hasOwnProperty,ug=Ic(function(e,t){e=Object(e);var n=-1,r=t.length,i=r>2?t[2]:void 0;for(i&&Uc(t[0],t[1],i)&&(r=1);++n<r;)for(var a=t[n],o=lu(a),s=-1,c=o.length;++s<c;){var l=o[s],u=e[l];(u===void 0||Ec(u,cg[l])&&!lg.call(e,l))&&(e[l]=a[l])}return e});function dg(e){return Ro(e)&&Vc(e)}o(dg,`isArrayLikeObject`);var fg=dg;function pg(e,t,n){for(var r=-1,i=e==null?0:e.length;++r<i;)if(n(t,e[r]))return!0;return!1}o(pg,`arrayIncludesWith`);var mg=pg,hg=200;function gg(e,t,n,r){var i=-1,a=vc,o=!0,s=e.length,c=[],l=t.length;if(!s)return c;n&&(t=Uo(t,Ll(n))),r?(a=mg,o=!1):t.length>=hg&&(a=Fm,o=!1,t=new jm(t));outer:for(;++i<s;){var u=e[i],d=n==null?u:n(u);if(u=r||u!==0?u:0,o&&d===d){for(var f=l;f--;)if(t[f]===d)continue outer;c.push(u)}else a(t,d,r)||c.push(u)}return c}o(gg,`baseDifference`);var _g=gg,vg=Ic(function(e,t){return fg(e)?_g(e,Fd(t,1,fg,!0)):[]});function yg(e){var t=e==null?0:e.length;return t?e[t-1]:void 0}o(yg,`last`);var bg=yg;function xg(e,t,n){var r=e==null?0:e.length;return r?(t=n||t===void 0?1:hs(t),Bd(e,t<0?0:t,r)):[]}o(xg,`drop`);var Sg=xg;function Cg(e,t,n){var r=e==null?0:e.length;return r?(t=n||t===void 0?1:hs(t),t=r-t,Bd(e,0,t<0?0:t)):[]}o(Cg,`dropRight`);var wg=Cg;function Tg(e){return typeof e==`function`?e:_s}o(Tg,`castFunction`);var Eg=Tg;function Dg(e,t){return(F(e)?cc:rg)(e,Eg(t))}o(Dg,`forEach`);var z=Dg;function Og(e,t){for(var n=-1,r=e==null?0:e.length;++n<r;)if(!t(e[n],n,e))return!1;return!0}o(Og,`arrayEvery`);var kg=Og;function Ag(e,t){var n=!0;return rg(e,function(e,r,i){return n=!!t(e,r,i),n}),n}o(Ag,`baseEvery`);var jg=Ag;function Mg(e,t,n){var r=F(e)?kg:jg;return n&&Uc(e,t,n)&&(t=void 0),r(e,Yh(t,3))}o(Mg,`every`);var Ng=Mg;function Pg(e,t){var n=[];return rg(e,function(e,r,i){t(e,r,i)&&n.push(e)}),n}o(Pg,`baseFilter`);var Fg=Pg;function Ig(e,t){return(F(e)?mf:Fg)(e,Yh(t,3))}o(Ig,`filter`);var Lg=Ig;function Rg(e){return function(t,n,r){var i=Object(t);if(!Vc(t)){var a=Yh(n,3);t=eu(t),n=o(function(e){return a(i[e],e,i)},`predicate`)}var s=e(t,n,r);return s>-1?i[a?t[s]:s]:void 0}}o(Rg,`createFind`);var zg=Rg,Bg=Math.max;function Vg(e,t,n){var r=e==null?0:e.length;if(!r)return-1;var i=n==null?0:hs(n);return i<0&&(i=Bg(r+i,0)),uc(e,Yh(t,3),i)}o(Vg,`findIndex`);var Hg=zg(Vg);function Ug(e){return e&&e.length?e[0]:void 0}o(Ug,`head`);var Wg=Ug;function Gg(e,t){var n=-1,r=Vc(e)?Array(e.length):[];return rg(e,function(e,i,a){r[++n]=t(e,i,a)}),r}o(Gg,`baseMap`);var Kg=Gg;function qg(e,t){return(F(e)?Uo:Kg)(e,Yh(t,3))}o(qg,`map`);var B=qg;function Jg(e,t){return Fd(B(e,t),1)}o(Jg,`flatMap`);var Yg=Jg,Xg=Object.prototype.hasOwnProperty,Zg=sg(function(e,t,n){Xg.call(e,n)?e[n].push(t):wc(e,n,[t])}),Qg=Object.prototype.hasOwnProperty;function $g(e,t){return e!=null&&Qg.call(e,t)}o($g,`baseHas`);var e_=$g;function t_(e,t){return e!=null&&Fh(e,t,e_)}o(t_,`has`);var V=t_,n_=`[object String]`;function r_(e){return typeof e==`string`||!F(e)&&Ro(e)&&Io(e)==n_}o(r_,`isString`);var i_=r_;function a_(e,t){return Uo(t,function(t){return e[t]})}o(a_,`baseValues`);var o_=a_;function s_(e){return e==null?[]:o_(e,eu(e))}o(s_,`values`);var H=s_,c_=Math.max;function l_(e,t,n,r){e=Vc(e)?e:H(e),n=n&&!r?hs(n):0;var i=e.length;return n<0&&(n=c_(i+n,0)),i_(e)?n<=i&&e.indexOf(t,n)>-1:!!i&&gc(e,t,n)>-1}o(l_,`includes`);var u_=l_,d_=Math.max;function f_(e,t,n){var r=e==null?0:e.length;if(!r)return-1;var i=n==null?0:hs(n);return i<0&&(i=d_(r+i,0)),gc(e,t,i)}o(f_,`indexOf`);var p_=f_,m_=`[object Map]`,h_=`[object Set]`,g_=Object.prototype.hasOwnProperty;function __(e){if(e==null)return!0;if(Vc(e)&&(F(e)||typeof e==`string`||typeof e.splice==`function`||ll(e)||Ul(e)||rl(e)))return!e.length;var t=Kf(e);if(t==m_||t==h_)return!e.size;if(Jc(e))return!Ql(e).length;for(var n in e)if(g_.call(e,n))return!1;return!0}o(__,`isEmpty`);var U=__,v_=`[object RegExp]`;function y_(e){return Ro(e)&&Io(e)==v_}o(y_,`baseIsRegExp`);var b_=y_,x_=Vl&&Vl.isRegExp,S_=x_?Ll(x_):b_;function C_(e){return e===void 0}o(C_,`isUndefined`);var w_=C_,T_=`Expected a function`;function E_(e){if(typeof e!=`function`)throw TypeError(T_);return function(){var t=arguments;switch(t.length){case 0:return!e.call(this);case 1:return!e.call(this,t[0]);case 2:return!e.call(this,t[0],t[1]);case 3:return!e.call(this,t[0],t[1],t[2])}return!e.apply(this,t)}}o(E_,`negate`);var D_=E_;function O_(e,t,n,r){if(!ns(e))return e;t=xd(t,e);for(var i=-1,a=t.length,o=a-1,s=e;s!=null&&++i<a;){var c=wd(t[i]),l=n;if(c===`__proto__`||c===`constructor`||c===`prototype`)return e;if(i!=o){var u=s[c];l=r?r(u,c,s):void 0,l===void 0&&(l=ns(u)?u:Sc(t[i+1])?[]:{})}kc(s,c,l),s=s[c]}return e}o(O_,`baseSet`);var k_=O_;function A_(e,t,n){for(var r=-1,i=t.length,a={};++r<i;){var o=t[r],s=Ed(e,o);n(s,o)&&k_(a,xd(o,e),s)}return a}o(A_,`basePickBy`);var j_=A_;function M_(e,t){if(e==null)return{};var n=Uo(Af(e),function(e){return[e]});return t=Yh(t),j_(e,n,function(e,n){return t(e,n[0])})}o(M_,`pickBy`);var N_=M_;function P_(e,t,n,r,i){return i(e,function(e,i,a){n=r?(r=!1,e):t(n,e,i,a)}),n}o(P_,`baseReduce`);var F_=P_;function I_(e,t,n){var r=F(e)?Hd:F_,i=arguments.length<3;return r(e,Yh(t,4),n,i,rg)}o(I_,`reduce`);var L_=I_;function R_(e,t){return(F(e)?mf:Fg)(e,D_(Yh(t,3)))}o(R_,`reject`);var z_=R_;function B_(e,t){var n;return rg(e,function(e,r,i){return n=t(e,r,i),!n}),!!n}o(B_,`baseSome`);var V_=B_;function H_(e,t,n){var r=F(e)?Nm:V_;return n&&Uc(e,t,n)&&(t=void 0),r(e,Yh(t,3))}o(H_,`some`);var U_=H_,W_=Nf&&1/Um(new Nf([,-0]))[1]==1/0?function(e){return new Nf(e)}:I,G_=200;function K_(e,t,n){var r=-1,i=vc,a=e.length,o=!0,s=[],c=s;if(n)o=!1,i=mg;else if(a>=G_){var l=t?null:W_(e);if(l)return Um(l);o=!1,i=Fm,c=new jm}else c=t?[]:s;outer:for(;++r<a;){var u=e[r],d=t?t(u):u;if(u=n||u!==0?u:0,o&&d===d){for(var f=c.length;f--;)if(c[f]===d)continue outer;t&&c.push(d),s.push(u)}else i(c,d,n)||(c!==s&&c.push(d),s.push(u))}return s}o(K_,`baseUniq`);var q_=K_;function J_(e){return e&&e.length?q_(e):[]}o(J_,`uniq`);var Y_=J_;function X_(e){console&&console.error&&console.error(`Error: ${e}`)}o(X_,`PRINT_ERROR`);function Z_(e){console&&console.warn&&console.warn(`Warning: ${e}`)}o(Z_,`PRINT_WARNING`);function Q_(e){let t=new Date().getTime(),n=e();return{time:new Date().getTime()-t,value:n}}o(Q_,`timer`);function $_(e){function t(){}o(t,`FakeConstructor`),t.prototype=e;let n=new t;function r(){return typeof n.bar}return o(r,`fakeAccess`),r(),r(),e}o($_,`toFastProperties`);function ev(e){return tv(e)?e.LABEL:e.name}o(ev,`tokenLabel`);function tv(e){return i_(e.LABEL)&&e.LABEL!==``}o(tv,`hasTokenLabel`);var nv=class{static{o(this,`AbstractProduction`)}get definition(){return this._definition}set definition(e){this._definition=e}constructor(e){this._definition=e}accept(e){e.visit(this),z(this.definition,t=>{t.accept(e)})}},rv=class extends nv{static{o(this,`NonTerminal`)}constructor(e){super([]),this.idx=1,nu(this,N_(e,e=>e!==void 0))}set definition(e){}get definition(){return this.referencedRule===void 0?[]:this.referencedRule.definition}accept(e){e.visit(this)}},iv=class extends nv{static{o(this,`Rule`)}constructor(e){super(e.definition),this.orgText=``,nu(this,N_(e,e=>e!==void 0))}},av=class extends nv{static{o(this,`Alternative`)}constructor(e){super(e.definition),this.ignoreAmbiguities=!1,nu(this,N_(e,e=>e!==void 0))}},ov=class extends nv{static{o(this,`Option`)}constructor(e){super(e.definition),this.idx=1,nu(this,N_(e,e=>e!==void 0))}},sv=class extends nv{static{o(this,`RepetitionMandatory`)}constructor(e){super(e.definition),this.idx=1,nu(this,N_(e,e=>e!==void 0))}},cv=class extends nv{static{o(this,`RepetitionMandatoryWithSeparator`)}constructor(e){super(e.definition),this.idx=1,nu(this,N_(e,e=>e!==void 0))}},W=class extends nv{static{o(this,`Repetition`)}constructor(e){super(e.definition),this.idx=1,nu(this,N_(e,e=>e!==void 0))}},lv=class extends nv{static{o(this,`RepetitionWithSeparator`)}constructor(e){super(e.definition),this.idx=1,nu(this,N_(e,e=>e!==void 0))}},uv=class extends nv{static{o(this,`Alternation`)}get definition(){return this._definition}set definition(e){this._definition=e}constructor(e){super(e.definition),this.idx=1,this.ignoreAmbiguities=!1,this.hasPredicates=!1,nu(this,N_(e,e=>e!==void 0))}},G=class{static{o(this,`Terminal`)}constructor(e){this.idx=1,nu(this,N_(e,e=>e!==void 0))}accept(e){e.visit(this)}};function dv(e){return B(e,fv)}o(dv,`serializeGrammar`);function fv(e){function t(e){return B(e,fv)}if(o(t,`convertDefinition`),e instanceof rv){let t={type:`NonTerminal`,name:e.nonTerminalName,idx:e.idx};return i_(e.label)&&(t.label=e.label),t}else if(e instanceof av)return{type:`Alternative`,definition:t(e.definition)};else if(e instanceof ov)return{type:`Option`,idx:e.idx,definition:t(e.definition)};else if(e instanceof sv)return{type:`RepetitionMandatory`,idx:e.idx,definition:t(e.definition)};else if(e instanceof cv)return{type:`RepetitionMandatoryWithSeparator`,idx:e.idx,separator:fv(new G({terminalType:e.separator})),definition:t(e.definition)};else if(e instanceof lv)return{type:`RepetitionWithSeparator`,idx:e.idx,separator:fv(new G({terminalType:e.separator})),definition:t(e.definition)};else if(e instanceof W)return{type:`Repetition`,idx:e.idx,definition:t(e.definition)};else if(e instanceof uv)return{type:`Alternation`,idx:e.idx,definition:t(e.definition)};else if(e instanceof G){let t={type:`Terminal`,name:e.terminalType.name,label:ev(e.terminalType),idx:e.idx};i_(e.label)&&(t.terminalLabel=e.label);let n=e.terminalType.PATTERN;return e.terminalType.PATTERN&&(t.pattern=S_(n)?n.source:n),t}else if(e instanceof iv)return{type:`Rule`,name:e.name,orgText:e.orgText,definition:t(e.definition)};else throw Error(`non exhaustive match`)}o(fv,`serializeProduction`);var pv=class{static{o(this,`GAstVisitor`)}visit(e){let t=e;switch(t.constructor){case rv:return this.visitNonTerminal(t);case av:return this.visitAlternative(t);case ov:return this.visitOption(t);case sv:return this.visitRepetitionMandatory(t);case cv:return this.visitRepetitionMandatoryWithSeparator(t);case lv:return this.visitRepetitionWithSeparator(t);case W:return this.visitRepetition(t);case uv:return this.visitAlternation(t);case G:return this.visitTerminal(t);case iv:return this.visitRule(t);default:throw Error(`non exhaustive match`)}}visitNonTerminal(e){}visitAlternative(e){}visitOption(e){}visitRepetition(e){}visitRepetitionMandatory(e){}visitRepetitionMandatoryWithSeparator(e){}visitRepetitionWithSeparator(e){}visitAlternation(e){}visitTerminal(e){}visitRule(e){}};function mv(e){return e instanceof av||e instanceof ov||e instanceof W||e instanceof sv||e instanceof cv||e instanceof lv||e instanceof G||e instanceof iv}o(mv,`isSequenceProd`);function hv(e,t=[]){return e instanceof ov||e instanceof W||e instanceof lv?!0:e instanceof uv?U_(e.definition,e=>hv(e,t)):e instanceof rv&&u_(t,e)?!1:e instanceof nv?(e instanceof rv&&t.push(e),Ng(e.definition,e=>hv(e,t))):!1}o(hv,`isOptionalProd`);function gv(e){return e instanceof uv}o(gv,`isBranchingProd`);function _v(e){if(e instanceof rv)return`SUBRULE`;if(e instanceof ov)return`OPTION`;if(e instanceof uv)return`OR`;if(e instanceof sv)return`AT_LEAST_ONE`;if(e instanceof cv)return`AT_LEAST_ONE_SEP`;if(e instanceof lv)return`MANY_SEP`;if(e instanceof W)return`MANY`;if(e instanceof G)return`CONSUME`;throw Error(`non exhaustive match`)}o(_v,`getProductionDslName`);var vv=class{static{o(this,`RestWalker`)}walk(e,t=[]){z(e.definition,(n,r)=>{let i=Sg(e.definition,r+1);if(n instanceof rv)this.walkProdRef(n,i,t);else if(n instanceof G)this.walkTerminal(n,i,t);else if(n instanceof av)this.walkFlat(n,i,t);else if(n instanceof ov)this.walkOption(n,i,t);else if(n instanceof sv)this.walkAtLeastOne(n,i,t);else if(n instanceof cv)this.walkAtLeastOneSep(n,i,t);else if(n instanceof lv)this.walkManySep(n,i,t);else if(n instanceof W)this.walkMany(n,i,t);else if(n instanceof uv)this.walkOr(n,i,t);else throw Error(`non exhaustive match`)})}walkTerminal(e,t,n){}walkProdRef(e,t,n){}walkFlat(e,t,n){let r=t.concat(n);this.walk(e,r)}walkOption(e,t,n){let r=t.concat(n);this.walk(e,r)}walkAtLeastOne(e,t,n){let r=[new ov({definition:e.definition})].concat(t,n);this.walk(e,r)}walkAtLeastOneSep(e,t,n){let r=yv(e,t,n);this.walk(e,r)}walkMany(e,t,n){let r=[new ov({definition:e.definition})].concat(t,n);this.walk(e,r)}walkManySep(e,t,n){let r=yv(e,t,n);this.walk(e,r)}walkOr(e,t,n){let r=t.concat(n);z(e.definition,e=>{let t=new av({definition:[e]});this.walk(t,r)})}};function yv(e,t,n){return[new ov({definition:[new G({terminalType:e.separator})].concat(e.definition)})].concat(t,n)}o(yv,`restForRepetitionWithSeparator`);function bv(e){if(e instanceof rv)return bv(e.referencedRule);if(e instanceof G)return Cv(e);if(mv(e))return xv(e);if(gv(e))return Sv(e);throw Error(`non exhaustive match`)}o(bv,`first`);function xv(e){let t=[],n=e.definition,r=0,i=n.length>r,a,o=!0;for(;i&&o;)a=n[r],o=hv(a),t=t.concat(bv(a)),r+=1,i=n.length>r;return Y_(t)}o(xv,`firstForSequence`);function Sv(e){return Y_(Ld(B(e.definition,e=>bv(e))))}o(Sv,`firstForBranching`);function Cv(e){return[e.terminalType]}o(Cv,`firstForTerminal`);var wv=`_~IN~_`,Tv=class extends vv{static{o(this,`ResyncFollowsWalker`)}constructor(e){super(),this.topProd=e,this.follows={}}startWalking(){return this.walk(this.topProd),this.follows}walkTerminal(e,t,n){}walkProdRef(e,t,n){let r=Dv(e.referencedRule,e.idx)+this.topProd.name,i=bv(new av({definition:t.concat(n)}));this.follows[r]=i}};function Ev(e){let t={};return z(e,e=>{nu(t,new Tv(e).startWalking())}),t}o(Ev,`computeAllProdsFollows`);function Dv(e,t){return e.name+t+wv}o(Dv,`buildBetweenProdsFollowPrefix`);var Ov={},kv=new ba;function Av(e){let t=e.toString();if(Ov.hasOwnProperty(t))return Ov[t];{let e=kv.pattern(t);return Ov[t]=e,e}}o(Av,`getRegExpAst`);function jv(){Ov={}}o(jv,`clearRegExpParserCache`);var Mv=`Complement Sets are not supported for first char optimization`,Nv=`Unable to use "first char" lexer optimizations:
47
+ `;function Pv(e,t=!1){try{let t=Av(e);return Fv(t.value,{},t.flags.ignoreCase)}catch(n){if(n.message===Mv)t&&Z_(`${Nv} Unable to optimize: < ${e.toString()} >
48
+ Complement Sets cannot be automatically optimized.
49
+ This will disable the lexer's first char optimizations.
50
+ See: https://chevrotain.io/docs/guide/resolving_lexer_errors.html#COMPLEMENT for details.`);else{let n=``;t&&(n=`
51
+ This will disable the lexer's first char optimizations.
52
+ See: https://chevrotain.io/docs/guide/resolving_lexer_errors.html#REGEXP_PARSING for details.`),X_(`${Nv}
53
+ Failed parsing: < ${e.toString()} >
54
+ Using the @chevrotain/regexp-to-ast library
55
+ Please open an issue at: https://github.com/chevrotain/chevrotain/issues`+n)}}return[]}o(Pv,`getOptimizedStartCodesIndices`);function Fv(e,t,n){switch(e.type){case`Disjunction`:for(let r=0;r<e.value.length;r++)Fv(e.value[r],t,n);break;case`Alternative`:let r=e.value;for(let e=0;e<r.length;e++){let i=r[e];switch(i.type){case`EndAnchor`:case`GroupBackReference`:case`Lookahead`:case`NegativeLookahead`:case`Lookbehind`:case`NegativeLookbehind`:case`StartAnchor`:case`WordBoundary`:case`NonWordBoundary`:continue}let a=i;switch(a.type){case`Character`:Iv(a.value,t,n);break;case`Set`:if(a.complement===!0)throw Error(Mv);z(a.value,e=>{if(typeof e==`number`)Iv(e,t,n);else{let r=e;if(n===!0)for(let e=r.from;e<=r.to;e++)Iv(e,t,n);else{for(let e=r.from;e<=r.to&&e<Sy;e++)Iv(e,t,n);if(r.to>=Sy){let e=r.from>=Sy?r.from:Sy,n=r.to,i=wy(e),a=wy(n);for(let e=i;e<=a;e++)t[e]=e}}}});break;case`Group`:Fv(a.value,t,n);break;default:throw Error(`Non Exhaustive Match`)}let o=a.quantifier!==void 0&&a.quantifier.atLeast===0;if(a.type===`Group`&&zv(a)===!1||a.type!==`Group`&&o===!1)break}break;default:throw Error(`non exhaustive match!`)}return H(t)}o(Fv,`firstCharOptimizedIndices`);function Iv(e,t,n){let r=wy(e);t[r]=r,n===!0&&Lv(e,t)}o(Iv,`addOptimizedIdxToResult`);function Lv(e,t){let n=String.fromCharCode(e),r=n.toUpperCase();if(r!==n){let e=wy(r.charCodeAt(0));t[e]=e}else{let e=n.toLowerCase();if(e!==n){let n=wy(e.charCodeAt(0));t[n]=n}}}o(Lv,`handleIgnoreCase`);function Rv(e,t){return Hg(e.value,e=>{if(typeof e==`number`)return u_(t,e);{let n=e;return Hg(t,e=>n.from<=e&&e<=n.to)!==void 0}})}o(Rv,`findCode`);function zv(e){let t=e.quantifier;return t&&t.atLeast===0?!0:e.value?F(e.value)?Ng(e.value,zv):zv(e.value):!1}o(zv,`isWholeOptional`);var Bv=class extends xa{static{o(this,`CharCodeFinder`)}constructor(e){super(),this.targetCharCodes=e,this.found=!1}visitChildren(e){if(this.found!==!0){switch(e.type){case`Lookahead`:this.visitLookahead(e);return;case`NegativeLookahead`:this.visitNegativeLookahead(e);return;case`Lookbehind`:this.visitLookbehind(e);return;case`NegativeLookbehind`:this.visitNegativeLookbehind(e);return}super.visitChildren(e)}}visitCharacter(e){u_(this.targetCharCodes,e.value)&&(this.found=!0)}visitSet(e){e.complement?Rv(e,this.targetCharCodes)===void 0&&(this.found=!0):Rv(e,this.targetCharCodes)!==void 0&&(this.found=!0)}};function Vv(e,t){if(t instanceof RegExp){let n=Av(t),r=new Bv(e);return r.visit(n),r.found}else return Hg(t,t=>u_(e,t.charCodeAt(0)))!==void 0}o(Vv,`canMatchCharCode`);var Hv=`PATTERN`,Uv=`defaultMode`,Wv=`modes`,Gv=typeof RegExp(`(?:)`).sticky==`boolean`;function Kv(e,t){t=ug(t,{useSticky:Gv,debug:!1,safeMode:!1,positionTracking:`full`,lineTerminatorCharacters:[`\r`,`
56
+ `],tracer:o((e,t)=>t(),`tracer`)});let n=t.tracer;n(`initCharCodeToOptimizedIndexMap`,()=>{Ty()});let r;n(`Reject Lexer.NA`,()=>{r=z_(e,e=>e[Hv]===Uy.NA)});let i=!1,a;n(`Transform Patterns`,()=>{i=!1,a=B(r,e=>{let n=e[Hv];if(S_(n)){let e=n.source;return e.length===1&&e!==`^`&&e!==`$`&&e!==`.`&&!n.ignoreCase?e:e.length===2&&e[0]===`\\`&&!u_([`d`,`D`,`s`,`S`,`t`,`r`,`n`,`t`,`0`,`c`,`b`,`B`,`f`,`v`,`w`,`W`],e[1])?e[1]:t.useSticky?dy(n):uy(n)}else if(Cs(n))return i=!0,{exec:n};else if(typeof n==`object`)return i=!0,n;else if(typeof n==`string`){if(n.length===1)return n;{let e=n.replace(/[\\^$.*+?()[\]{}|]/g,`\\$&`),r=new RegExp(e);return t.useSticky?dy(r):uy(r)}}else throw Error(`non exhaustive match`)})});let s,c,l,u,d;n(`misc mapping`,()=>{s=B(r,e=>e.tokenTypeIdx),c=B(r,e=>{let t=e.GROUP;if(t!==Uy.SKIPPED){if(i_(t))return t;if(w_(t))return!1;throw Error(`non exhaustive match`)}}),l=B(r,e=>{let t=e.LONGER_ALT;if(t)return F(t)?B(t,e=>p_(r,e)):[p_(r,t)]}),u=B(r,e=>e.PUSH_MODE),d=B(r,e=>V(e,`POP_MODE`))});let f;n(`Line Terminator Handling`,()=>{let e=by(t.lineTerminatorCharacters);f=B(r,e=>!1),t.positionTracking!==`onlyOffset`&&(f=B(r,t=>V(t,`LINE_BREAKS`)?!!t.LINE_BREAKS:vy(t,e)===!1&&Vv(e,t.PATTERN)))});let p,m,h,g;n(`Misc Mapping #2`,()=>{p=B(r,hy),m=B(a,gy),h=L_(r,(e,t)=>{let n=t.GROUP;return i_(n)&&n!==Uy.SKIPPED&&(e[n]=[]),e},{}),g=B(a,(e,t)=>({pattern:a[t],longerAlt:l[t],canLineTerminator:f[t],isCustom:p[t],short:m[t],group:c[t],push:u[t],pop:d[t],tokenTypeIdx:s[t],tokenType:r[t]}))});let _=!0,v=[];return t.safeMode||n(`First Char Optimization`,()=>{v=L_(r,(e,n,r)=>{if(typeof n.PATTERN==`string`)xy(e,wy(n.PATTERN.charCodeAt(0)),g[r]);else if(F(n.START_CHARS_HINT)){let t;z(n.START_CHARS_HINT,n=>{let i=wy(typeof n==`string`?n.charCodeAt(0):n);t!==i&&(t=i,xy(e,i,g[r]))})}else if(S_(n.PATTERN))if(n.PATTERN.unicode)_=!1,t.ensureOptimizations&&X_(`${Nv} Unable to analyze < ${n.PATTERN.toString()} > pattern.
57
+ The regexp unicode flag is not currently supported by the regexp-to-ast library.
58
+ This will disable the lexer's first char optimizations.
59
+ For details See: https://chevrotain.io/docs/guide/resolving_lexer_errors.html#UNICODE_OPTIMIZE`);else{let i=Pv(n.PATTERN,t.ensureOptimizations);U(i)&&(_=!1),z(i,t=>{xy(e,t,g[r])})}else t.ensureOptimizations&&X_(`${Nv} TokenType: <${n.name}> is using a custom token pattern without providing <start_chars_hint> parameter.
60
+ This will disable the lexer's first char optimizations.
61
+ For details See: https://chevrotain.io/docs/guide/resolving_lexer_errors.html#CUSTOM_OPTIMIZE`),_=!1;return e},[])}),{emptyGroups:h,patternIdxToConfig:g,charCodeToPatternIdxToConfig:v,hasCustom:i,canBeOptimized:_}}o(Kv,`analyzeTokenTypes`);function qv(e,t){let n=[],r=Yv(e);n=n.concat(r.errors);let i=Xv(r.valid),a=i.valid;return n=n.concat(i.errors),n=n.concat(Jv(a)),n=n.concat(iy(a)),n=n.concat(ay(a,t)),n=n.concat(oy(a)),n}o(qv,`validatePatterns`);function Jv(e){let t=[],n=Lg(e,e=>S_(e[Hv]));return t=t.concat(Qv(n)),t=t.concat(ty(n)),t=t.concat(ny(n)),t=t.concat(ry(n)),t=t.concat($v(n)),t}o(Jv,`validateRegExpPattern`);function Yv(e){let t=Lg(e,e=>!V(e,Hv));return{errors:B(t,e=>({message:`Token Type: ->`+e.name+`<- missing static 'PATTERN' property`,type:K.MISSING_PATTERN,tokenTypes:[e]})),valid:vg(e,t)}}o(Yv,`findMissingPatterns`);function Xv(e){let t=Lg(e,e=>{let t=e[Hv];return!S_(t)&&!Cs(t)&&!V(t,`exec`)&&!i_(t)});return{errors:B(t,e=>({message:`Token Type: ->`+e.name+`<- static 'PATTERN' can only be a RegExp, a Function matching the {CustomPatternMatcherFunc} type or an Object matching the {ICustomPattern} interface.`,type:K.INVALID_PATTERN,tokenTypes:[e]})),valid:vg(e,t)}}o(Xv,`findInvalidPatterns`);var Zv=/[^\\][$]/;function Qv(e){class t extends xa{static{o(this,`EndAnchorFinder`)}constructor(){super(...arguments),this.found=!1}visitEndAnchor(e){this.found=!0}}return B(Lg(e,e=>{let n=e.PATTERN;try{let e=Av(n),r=new t;return r.visit(e),r.found}catch{return Zv.test(n.source)}}),e=>({message:`Unexpected RegExp Anchor Error:
62
+ Token Type: ->`+e.name+`<- static 'PATTERN' cannot contain end of input anchor '$'
63
+ See chevrotain.io/docs/guide/resolving_lexer_errors.html#ANCHORS for details.`,type:K.EOI_ANCHOR_FOUND,tokenTypes:[e]}))}o(Qv,`findEndOfInputAnchor`);function $v(e){return B(Lg(e,e=>e.PATTERN.test(``)),e=>({message:`Token Type: ->`+e.name+`<- static 'PATTERN' must not match an empty string`,type:K.EMPTY_MATCH_PATTERN,tokenTypes:[e]}))}o($v,`findEmptyMatchRegExps`);var ey=/[^\\[][\^]|^\^/;function ty(e){class t extends xa{static{o(this,`StartAnchorFinder`)}constructor(){super(...arguments),this.found=!1}visitStartAnchor(e){this.found=!0}}return B(Lg(e,e=>{let n=e.PATTERN;try{let e=Av(n),r=new t;return r.visit(e),r.found}catch{return ey.test(n.source)}}),e=>({message:`Unexpected RegExp Anchor Error:
64
+ Token Type: ->`+e.name+`<- static 'PATTERN' cannot contain start of input anchor '^'
65
+ See https://chevrotain.io/docs/guide/resolving_lexer_errors.html#ANCHORS for details.`,type:K.SOI_ANCHOR_FOUND,tokenTypes:[e]}))}o(ty,`findStartOfInputAnchor`);function ny(e){return B(Lg(e,e=>{let t=e[Hv];return t instanceof RegExp&&(t.multiline||t.global)}),e=>({message:`Token Type: ->`+e.name+`<- static 'PATTERN' may NOT contain global('g') or multiline('m')`,type:K.UNSUPPORTED_FLAGS_FOUND,tokenTypes:[e]}))}o(ny,`findUnsupportedFlags`);function ry(e){let t=[],n=B(e,n=>L_(e,(e,r)=>n.PATTERN.source===r.PATTERN.source&&!u_(t,r)&&r.PATTERN!==Uy.NA?(t.push(r),e.push(r),e):e,[]));return n=wm(n),B(Lg(n,e=>e.length>1),e=>{let t=B(e,e=>e.name);return{message:`The same RegExp pattern ->${Wg(e).PATTERN}<-has been used in all of the following Token Types: ${t.join(`, `)} <-`,type:K.DUPLICATE_PATTERNS_FOUND,tokenTypes:e}})}o(ry,`findDuplicatePatterns`);function iy(e){return B(Lg(e,e=>{if(!V(e,`GROUP`))return!1;let t=e.GROUP;return t!==Uy.SKIPPED&&t!==Uy.NA&&!i_(t)}),e=>({message:`Token Type: ->`+e.name+`<- static 'GROUP' can only be Lexer.SKIPPED/Lexer.NA/A String`,type:K.INVALID_GROUP_TYPE_FOUND,tokenTypes:[e]}))}o(iy,`findInvalidGroupType`);function ay(e,t){return B(Lg(e,e=>e.PUSH_MODE!==void 0&&!u_(t,e.PUSH_MODE)),e=>({message:`Token Type: ->${e.name}<- static 'PUSH_MODE' value cannot refer to a Lexer Mode ->${e.PUSH_MODE}<-which does not exist`,type:K.PUSH_MODE_DOES_NOT_EXIST,tokenTypes:[e]}))}o(ay,`findModesThatDoNotExist`);function oy(e){let t=[],n=L_(e,(e,t,n)=>{let r=t.PATTERN;return r===Uy.NA||(i_(r)?e.push({str:r,idx:n,tokenType:t}):S_(r)&&cy(r)&&e.push({str:r.source,idx:n,tokenType:t})),e},[]);return z(e,(e,r)=>{z(n,({str:n,idx:i,tokenType:a})=>{if(r<i&&sy(n,e.PATTERN)){let n=`Token: ->${a.name}<- can never be matched.
66
+ Because it appears AFTER the Token Type ->${e.name}<-in the lexer's definition.
67
+ See https://chevrotain.io/docs/guide/resolving_lexer_errors.html#UNREACHABLE`;t.push({message:n,type:K.UNREACHABLE_PATTERN,tokenTypes:[e,a]})}})}),t}o(oy,`findUnreachablePatterns`);function sy(e,t){if(S_(t)){if(ly(t))return!1;let n=t.exec(e);return n!==null&&n.index===0}else if(Cs(t))return t(e,0,[],{});else if(V(t,`exec`))return t.exec(e,0,[],{});else if(typeof t==`string`)return t===e;else throw Error(`non exhaustive match`)}o(sy,`tryToMatchStrToPattern`);function cy(e){return Hg([`.`,`\\`,`[`,`]`,`|`,`^`,`$`,`(`,`)`,`?`,`*`,`+`,`{`],t=>e.source.indexOf(t)!==-1)===void 0}o(cy,`noMetaChar`);function ly(e){return/(\(\?=)|(\(\?!)|(\(\?<=)|(\(\?<!)/.test(e.source)}o(ly,`usesLookAheadOrBehind`);function uy(e){let t=e.ignoreCase?`i`:``;return RegExp(`^(?:${e.source})`,t)}o(uy,`addStartOfInput`);function dy(e){let t=e.ignoreCase?`iy`:`y`;return RegExp(`${e.source}`,t)}o(dy,`addStickyFlag`);function fy(e,t,n){let r=[];return V(e,Uv)||r.push({message:`A MultiMode Lexer cannot be initialized without a <`+Uv+`> property in its definition
68
+ `,type:K.MULTI_MODE_LEXER_WITHOUT_DEFAULT_MODE}),V(e,Wv)||r.push({message:`A MultiMode Lexer cannot be initialized without a <`+Wv+`> property in its definition
69
+ `,type:K.MULTI_MODE_LEXER_WITHOUT_MODES_PROPERTY}),V(e,Wv)&&V(e,Uv)&&!V(e.modes,e.defaultMode)&&r.push({message:`A MultiMode Lexer cannot be initialized with a ${Uv}: <${e.defaultMode}>which does not exist
70
+ `,type:K.MULTI_MODE_LEXER_DEFAULT_MODE_VALUE_DOES_NOT_EXIST}),V(e,Wv)&&z(e.modes,(e,t)=>{z(e,(n,i)=>{w_(n)?r.push({message:`A Lexer cannot be initialized using an undefined Token Type. Mode:<${t}> at index: <${i}>
71
+ `,type:K.LEXER_DEFINITION_CANNOT_CONTAIN_UNDEFINED}):V(n,`LONGER_ALT`)&&z(F(n.LONGER_ALT)?n.LONGER_ALT:[n.LONGER_ALT],i=>{!w_(i)&&!u_(e,i)&&r.push({message:`A MultiMode Lexer cannot be initialized with a longer_alt <${i.name}> on token <${n.name}> outside of mode <${t}>
72
+ `,type:K.MULTI_MODE_LEXER_LONGER_ALT_NOT_IN_CURRENT_MODE})})})}),r}o(fy,`performRuntimeChecks`);function py(e,t,n){let r=[],i=!1,a=z_(wm(Ld(H(e.modes))),e=>e[Hv]===Uy.NA),o=by(n);return t&&z(a,e=>{let t=vy(e,o);if(t!==!1){let n={message:yy(e,t),type:t.issue,tokenType:e};r.push(n)}else V(e,`LINE_BREAKS`)?e.LINE_BREAKS===!0&&(i=!0):Vv(o,e.PATTERN)&&(i=!0)}),t&&!i&&r.push({message:`Warning: No LINE_BREAKS Found.
73
+ This Lexer has been defined to track line and column information,
74
+ But none of the Token Types can be identified as matching a line terminator.
75
+ See https://chevrotain.io/docs/guide/resolving_lexer_errors.html#LINE_BREAKS
76
+ for details.`,type:K.NO_LINE_BREAKS_FLAGS}),r}o(py,`performWarningRuntimeChecks`);function my(e){let t={};return z(eu(e),n=>{let r=e[n];if(F(r))t[n]=[];else throw Error(`non exhaustive match`)}),t}o(my,`cloneEmptyGroups`);function hy(e){let t=e.PATTERN;if(S_(t))return!1;if(Cs(t)||V(t,`exec`))return!0;if(i_(t))return!1;throw Error(`non exhaustive match`)}o(hy,`isCustomPattern`);function gy(e){return i_(e)&&e.length===1?e.charCodeAt(0):!1}o(gy,`isShortPattern`);var _y={test:o(function(e){let t=e.length;for(let n=this.lastIndex;n<t;n++){let t=e.charCodeAt(n);if(t===10)return this.lastIndex=n+1,!0;if(t===13)return e.charCodeAt(n+1)===10?this.lastIndex=n+2:this.lastIndex=n+1,!0}return!1},`test`),lastIndex:0};function vy(e,t){if(V(e,`LINE_BREAKS`))return!1;if(S_(e.PATTERN)){try{Vv(t,e.PATTERN)}catch(e){return{issue:K.IDENTIFY_TERMINATOR,errMsg:e.message}}return!1}else if(i_(e.PATTERN))return!1;else if(hy(e))return{issue:K.CUSTOM_LINE_BREAK};else throw Error(`non exhaustive match`)}o(vy,`checkLineBreaksIssues`);function yy(e,t){if(t.issue===K.IDENTIFY_TERMINATOR)return`Warning: unable to identify line terminator usage in pattern.
77
+ The problem is in the <${e.name}> Token Type
78
+ Root cause: ${t.errMsg}.
79
+ For details See: https://chevrotain.io/docs/guide/resolving_lexer_errors.html#IDENTIFY_TERMINATOR`;if(t.issue===K.CUSTOM_LINE_BREAK)return`Warning: A Custom Token Pattern should specify the <line_breaks> option.
80
+ The problem is in the <${e.name}> Token Type
81
+ For details See: https://chevrotain.io/docs/guide/resolving_lexer_errors.html#CUSTOM_LINE_BREAK`;throw Error(`non exhaustive match`)}o(yy,`buildLineBreakIssueMessage`);function by(e){return B(e,e=>i_(e)?e.charCodeAt(0):e)}o(by,`getCharCodes`);function xy(e,t,n){e[t]===void 0?e[t]=[n]:e[t].push(n)}o(xy,`addToMapOfArrays`);var Sy=256,Cy=[];function wy(e){return e<Sy?e:Cy[e]}o(wy,`charCodeToOptimizedIndex`);function Ty(){if(U(Cy)){Cy=Array(65536);for(let e=0;e<65536;e++)Cy[e]=e>255?255+~~(e/255):e}}o(Ty,`initCharCodeToOptimizedIndexMap`);function Ey(e,t){let n=e.tokenTypeIdx;return n===t.tokenTypeIdx?!0:t.isParent===!0&&t.categoryMatchesMap[n]===!0}o(Ey,`tokenStructuredMatcher`);function Dy(e,t){return e.tokenTypeIdx===t.tokenTypeIdx}o(Dy,`tokenStructuredMatcherNoCategories`);var Oy=1,ky={};function Ay(e){let t=jy(e);My(t),Py(t),Ny(t),z(t,e=>{e.isParent=e.categoryMatches.length>0})}o(Ay,`augmentTokenTypes`);function jy(e){let t=Sm(e),n=e,r=!0;for(;r;){n=wm(Ld(B(n,e=>e.CATEGORIES)));let e=vg(n,t);t=t.concat(e),U(e)?r=!1:n=e}return t}o(jy,`expandCategories`);function My(e){z(e,e=>{Iy(e)||(ky[Oy]=e,e.tokenTypeIdx=Oy++),Ly(e)&&!F(e.CATEGORIES)&&(e.CATEGORIES=[e.CATEGORIES]),Ly(e)||(e.CATEGORIES=[]),Ry(e)||(e.categoryMatches=[]),zy(e)||(e.categoryMatchesMap={})})}o(My,`assignTokenDefaultProps`);function Ny(e){z(e,e=>{e.categoryMatches=[],z(e.categoryMatchesMap,(t,n)=>{e.categoryMatches.push(ky[n].tokenTypeIdx)})})}o(Ny,`assignCategoriesTokensProp`);function Py(e){z(e,e=>{Fy([],e)})}o(Py,`assignCategoriesMapProp`);function Fy(e,t){z(e,e=>{t.categoryMatchesMap[e.tokenTypeIdx]=!0}),z(t.CATEGORIES,n=>{let r=e.concat(t);u_(r,n)||Fy(r,n)})}o(Fy,`singleAssignCategoriesToksMap`);function Iy(e){return V(e,`tokenTypeIdx`)}o(Iy,`hasShortKeyProperty`);function Ly(e){return V(e,`CATEGORIES`)}o(Ly,`hasCategoriesProperty`);function Ry(e){return V(e,`categoryMatches`)}o(Ry,`hasExtendingTokensTypesProperty`);function zy(e){return V(e,`categoryMatchesMap`)}o(zy,`hasExtendingTokensTypesMapProperty`);function By(e){return V(e,`tokenTypeIdx`)}o(By,`isTokenType`);var Vy={buildUnableToPopLexerModeMessage(e){return`Unable to pop Lexer Mode after encountering Token ->${e.image}<- The Mode Stack is empty`},buildUnexpectedCharactersMessage(e,t,n,r,i,a){return`unexpected character: ->${e.charAt(t)}<- at offset: ${t}, skipped ${n} characters.`}},K;(function(e){e[e.MISSING_PATTERN=0]=`MISSING_PATTERN`,e[e.INVALID_PATTERN=1]=`INVALID_PATTERN`,e[e.EOI_ANCHOR_FOUND=2]=`EOI_ANCHOR_FOUND`,e[e.UNSUPPORTED_FLAGS_FOUND=3]=`UNSUPPORTED_FLAGS_FOUND`,e[e.DUPLICATE_PATTERNS_FOUND=4]=`DUPLICATE_PATTERNS_FOUND`,e[e.INVALID_GROUP_TYPE_FOUND=5]=`INVALID_GROUP_TYPE_FOUND`,e[e.PUSH_MODE_DOES_NOT_EXIST=6]=`PUSH_MODE_DOES_NOT_EXIST`,e[e.MULTI_MODE_LEXER_WITHOUT_DEFAULT_MODE=7]=`MULTI_MODE_LEXER_WITHOUT_DEFAULT_MODE`,e[e.MULTI_MODE_LEXER_WITHOUT_MODES_PROPERTY=8]=`MULTI_MODE_LEXER_WITHOUT_MODES_PROPERTY`,e[e.MULTI_MODE_LEXER_DEFAULT_MODE_VALUE_DOES_NOT_EXIST=9]=`MULTI_MODE_LEXER_DEFAULT_MODE_VALUE_DOES_NOT_EXIST`,e[e.LEXER_DEFINITION_CANNOT_CONTAIN_UNDEFINED=10]=`LEXER_DEFINITION_CANNOT_CONTAIN_UNDEFINED`,e[e.SOI_ANCHOR_FOUND=11]=`SOI_ANCHOR_FOUND`,e[e.EMPTY_MATCH_PATTERN=12]=`EMPTY_MATCH_PATTERN`,e[e.NO_LINE_BREAKS_FLAGS=13]=`NO_LINE_BREAKS_FLAGS`,e[e.UNREACHABLE_PATTERN=14]=`UNREACHABLE_PATTERN`,e[e.IDENTIFY_TERMINATOR=15]=`IDENTIFY_TERMINATOR`,e[e.CUSTOM_LINE_BREAK=16]=`CUSTOM_LINE_BREAK`,e[e.MULTI_MODE_LEXER_LONGER_ALT_NOT_IN_CURRENT_MODE=17]=`MULTI_MODE_LEXER_LONGER_ALT_NOT_IN_CURRENT_MODE`})(K||={});var Hy={deferDefinitionErrorsHandling:!1,positionTracking:`full`,lineTerminatorsPattern:/\n|\r\n?/g,lineTerminatorCharacters:[`
82
+ `,`\r`],ensureOptimizations:!1,safeMode:!1,errorMessageProvider:Vy,traceInitPerf:!1,skipValidations:!1,recoveryEnabled:!0};Object.freeze(Hy);var Uy=class{static{o(this,`Lexer`)}constructor(e,t=Hy){if(this.lexerDefinition=e,this.lexerDefinitionErrors=[],this.lexerDefinitionWarning=[],this.patternIdxToConfig={},this.charCodeToPatternIdxToConfig={},this.modes=[],this.emptyGroups={},this.trackStartLines=!0,this.trackEndLines=!0,this.hasCustom=!1,this.canModeBeOptimized={},this.TRACE_INIT=(e,t)=>{if(this.traceInitPerf===!0){this.traceInitIndent++;let n=Array(this.traceInitIndent+1).join(` `);this.traceInitIndent<this.traceInitMaxIdent&&console.log(`${n}--> <${e}>`);let{time:r,value:i}=Q_(t),a=r>10?console.warn:console.log;return this.traceInitIndent<this.traceInitMaxIdent&&a(`${n}<-- <${e}> time: ${r}ms`),this.traceInitIndent--,i}else return t()},typeof t==`boolean`)throw Error(`The second argument to the Lexer constructor is now an ILexerConfig Object.
83
+ a boolean 2nd argument is no longer supported`);this.config=nu({},Hy,t);let n=this.config.traceInitPerf;n===!0?(this.traceInitMaxIdent=1/0,this.traceInitPerf=!0):typeof n==`number`&&(this.traceInitMaxIdent=n,this.traceInitPerf=!0),this.traceInitIndent=-1,this.TRACE_INIT(`Lexer Constructor`,()=>{let n,r=!0;this.TRACE_INIT(`Lexer Config handling`,()=>{if(this.config.lineTerminatorsPattern===Hy.lineTerminatorsPattern)this.config.lineTerminatorsPattern=_y;else if(this.config.lineTerminatorCharacters===Hy.lineTerminatorCharacters)throw Error(`Error: Missing <lineTerminatorCharacters> property on the Lexer config.
84
+ For details See: https://chevrotain.io/docs/guide/resolving_lexer_errors.html#MISSING_LINE_TERM_CHARS`);if(t.safeMode&&t.ensureOptimizations)throw Error(`"safeMode" and "ensureOptimizations" flags are mutually exclusive.`);this.trackStartLines=/full|onlyStart/i.test(this.config.positionTracking),this.trackEndLines=/full/i.test(this.config.positionTracking),F(e)?n={modes:{defaultMode:Sm(e)},defaultMode:Uv}:(r=!1,n=Sm(e))}),this.config.skipValidations===!1&&(this.TRACE_INIT(`performRuntimeChecks`,()=>{this.lexerDefinitionErrors=this.lexerDefinitionErrors.concat(fy(n,this.trackStartLines,this.config.lineTerminatorCharacters))}),this.TRACE_INIT(`performWarningRuntimeChecks`,()=>{this.lexerDefinitionWarning=this.lexerDefinitionWarning.concat(py(n,this.trackStartLines,this.config.lineTerminatorCharacters))})),n.modes=n.modes?n.modes:{},z(n.modes,(e,t)=>{n.modes[t]=z_(e,e=>w_(e))});let i=eu(n.modes);if(z(n.modes,(e,n)=>{this.TRACE_INIT(`Mode: <${n}> processing`,()=>{if(this.modes.push(n),this.config.skipValidations===!1&&this.TRACE_INIT(`validatePatterns`,()=>{this.lexerDefinitionErrors=this.lexerDefinitionErrors.concat(qv(e,i))}),U(this.lexerDefinitionErrors)){Ay(e);let r;this.TRACE_INIT(`analyzeTokenTypes`,()=>{r=Kv(e,{lineTerminatorCharacters:this.config.lineTerminatorCharacters,positionTracking:t.positionTracking,ensureOptimizations:t.ensureOptimizations,safeMode:t.safeMode,tracer:this.TRACE_INIT})}),this.patternIdxToConfig[n]=r.patternIdxToConfig,this.charCodeToPatternIdxToConfig[n]=r.charCodeToPatternIdxToConfig,this.emptyGroups=nu({},this.emptyGroups,r.emptyGroups),this.hasCustom=r.hasCustom||this.hasCustom,this.canModeBeOptimized[n]=r.canBeOptimized}})}),this.defaultMode=n.defaultMode,!U(this.lexerDefinitionErrors)&&!this.config.deferDefinitionErrorsHandling){let e=B(this.lexerDefinitionErrors,e=>e.message).join(`-----------------------
85
+ `);throw Error(`Errors detected in definition of Lexer:
86
+ `+e)}z(this.lexerDefinitionWarning,e=>{Z_(e.message)}),this.TRACE_INIT(`Choosing sub-methods implementations`,()=>{if(Gv?(this.chopInput=_s,this.match=this.matchWithTest):(this.updateLastIndex=I,this.match=this.matchWithExec),r&&(this.handleModes=I),this.trackStartLines===!1&&(this.computeNewColumn=_s),this.trackEndLines===!1&&(this.updateTokenEndLineColumnLocation=I),/full/i.test(this.config.positionTracking))this.createTokenInstance=this.createFullToken;else if(/onlyStart/i.test(this.config.positionTracking))this.createTokenInstance=this.createStartOnlyToken;else if(/onlyOffset/i.test(this.config.positionTracking))this.createTokenInstance=this.createOffsetOnlyToken;else throw Error(`Invalid <positionTracking> config option: "${this.config.positionTracking}"`);this.hasCustom?(this.addToken=this.addTokenUsingPush,this.handlePayload=this.handlePayloadWithCustom):(this.addToken=this.addTokenUsingMemberAccess,this.handlePayload=this.handlePayloadNoCustom)}),this.TRACE_INIT(`Failed Optimization Warnings`,()=>{let e=L_(this.canModeBeOptimized,(e,t,n)=>(t===!1&&e.push(n),e),[]);if(t.ensureOptimizations&&!U(e))throw Error(`Lexer Modes: < ${e.join(`, `)} > cannot be optimized.
87
+ Disable the "ensureOptimizations" lexer config flag to silently ignore this and run the lexer in an un-optimized mode.
88
+ Or inspect the console log for details on how to resolve these issues.`)}),this.TRACE_INIT(`clearRegExpParserCache`,()=>{jv()}),this.TRACE_INIT(`toFastProperties`,()=>{$_(this)})})}tokenize(e,t=this.defaultMode){if(!U(this.lexerDefinitionErrors)){let e=B(this.lexerDefinitionErrors,e=>e.message).join(`-----------------------
89
+ `);throw Error(`Unable to Tokenize because Errors detected in definition of Lexer:
90
+ `+e)}return this.tokenizeInternal(e,t)}tokenizeInternal(e,t){let n,r,i,a,s,c,l,u,d,f,p,m,h,g,_,v=e,y=v.length,b=0,x=0,ee=this.hasCustom?0:Math.floor(e.length/10),S=Array(ee),te=[],ne=this.trackStartLines?1:void 0,C=this.trackStartLines?1:void 0,re=my(this.emptyGroups),ie=this.trackStartLines,ae=this.config.lineTerminatorsPattern,oe=0,se=[],ce=[],le=[],ue=[];Object.freeze(ue);let de;function w(){return se}o(w,`getPossiblePatternsSlow`);function T(e){let t=wy(e),n=ce[t];return n===void 0?ue:n}o(T,`getPossiblePatternsOptimized`);let fe=o(e=>{if(le.length===1&&e.tokenType.PUSH_MODE===void 0){let t=this.config.errorMessageProvider.buildUnableToPopLexerModeMessage(e);te.push({offset:e.startOffset,line:e.startLine,column:e.startColumn,length:e.image.length,message:t})}else{le.pop();let e=bg(le);se=this.patternIdxToConfig[e],ce=this.charCodeToPatternIdxToConfig[e],oe=se.length;let t=this.canModeBeOptimized[e]&&this.config.safeMode===!1;de=ce&&t?T:w}},`pop_mode`);function E(e){le.push(e),ce=this.charCodeToPatternIdxToConfig[e],se=this.patternIdxToConfig[e],oe=se.length,oe=se.length;let t=this.canModeBeOptimized[e]&&this.config.safeMode===!1;de=ce&&t?T:w}o(E,`push_mode`),E.call(this,t);let D,pe=this.config.recoveryEnabled;for(;b<y;){c=null;let t=v.charCodeAt(b),o=de(t),ee=o.length;for(n=0;n<ee;n++){D=o[n];let r=D.pattern;l=null;let d=D.short;if(d===!1?D.isCustom===!0?(_=r.exec(v,b,S,re),_===null?c=null:(c=_[0],_.payload!==void 0&&(l=_.payload))):(this.updateLastIndex(r,b),c=this.match(r,e,b)):t===d&&(c=r),c!==null){if(s=D.longerAlt,s!==void 0){let t=s.length;for(i=0;i<t;i++){let t=se[s[i]],n=t.pattern;if(u=null,t.isCustom===!0?(_=n.exec(v,b,S,re),_===null?a=null:(a=_[0],_.payload!==void 0&&(u=_.payload))):(this.updateLastIndex(n,b),a=this.match(n,e,b)),a&&a.length>c.length){c=a,l=u,D=t;break}}}break}}if(c!==null){if(d=c.length,f=D.group,f!==void 0&&(p=D.tokenTypeIdx,m=this.createTokenInstance(c,b,p,D.tokenType,ne,C,d),this.handlePayload(m,l),f===!1?x=this.addToken(S,x,m):re[f].push(m)),e=this.chopInput(e,d),b+=d,C=this.computeNewColumn(C,d),ie===!0&&D.canLineTerminator===!0){let e=0,t,n;ae.lastIndex=0;do t=ae.test(c),t===!0&&(n=ae.lastIndex-1,e++);while(t===!0);e!==0&&(ne+=e,C=d-n,this.updateTokenEndLineColumnLocation(m,f,n,e,ne,C,d))}this.handleModes(D,fe,E,m)}else{let t=b,n=ne,i=C,a=pe===!1;for(;a===!1&&b<y;)for(e=this.chopInput(e,1),b++,r=0;r<oe;r++){let t=se[r],n=t.pattern,i=t.short;if(i===!1?t.isCustom===!0?a=n.exec(v,b,S,re)!==null:(this.updateLastIndex(n,b),a=n.exec(e)!==null):v.charCodeAt(b)===i&&(a=!0),a===!0)break}if(h=b-t,C=this.computeNewColumn(C,h),g=this.config.errorMessageProvider.buildUnexpectedCharactersMessage(v,t,h,n,i,bg(le)),te.push({offset:t,line:n,column:i,length:h,message:g}),pe===!1)break}}return this.hasCustom||(S.length=x),{tokens:S,groups:re,errors:te}}handleModes(e,t,n,r){if(e.pop===!0){let i=e.push;t(r),i!==void 0&&n.call(this,i)}else e.push!==void 0&&n.call(this,e.push)}chopInput(e,t){return e.substring(t)}updateLastIndex(e,t){e.lastIndex=t}updateTokenEndLineColumnLocation(e,t,n,r,i,a,o){let s,c;t!==void 0&&(s=n===o-1,c=s?-1:0,r===1&&s===!0||(e.endLine=i+c,e.endColumn=a-1+-c))}computeNewColumn(e,t){return e+t}createOffsetOnlyToken(e,t,n,r){return{image:e,startOffset:t,tokenTypeIdx:n,tokenType:r}}createStartOnlyToken(e,t,n,r,i,a){return{image:e,startOffset:t,startLine:i,startColumn:a,tokenTypeIdx:n,tokenType:r}}createFullToken(e,t,n,r,i,a,o){return{image:e,startOffset:t,endOffset:t+o-1,startLine:i,endLine:i,startColumn:a,endColumn:a+o-1,tokenTypeIdx:n,tokenType:r}}addTokenUsingPush(e,t,n){return e.push(n),t}addTokenUsingMemberAccess(e,t,n){return e[t]=n,t++,t}handlePayloadNoCustom(e,t){}handlePayloadWithCustom(e,t){t!==null&&(e.payload=t)}matchWithTest(e,t,n){return e.test(t)===!0?t.substring(n,e.lastIndex):null}matchWithExec(e,t){let n=e.exec(t);return n===null?null:n[0]}};Uy.SKIPPED=`This marks a skipped Token pattern, this means each token identified by it will be consumed and then thrown into oblivion, this can be used to for example to completely ignore whitespace.`,Uy.NA=/NOT_APPLICABLE/;function Wy(e){return Gy(e)?e.LABEL:e.name}o(Wy,`tokenLabel`);function Gy(e){return i_(e.LABEL)&&e.LABEL!==``}o(Gy,`hasTokenLabel`);var Ky=`parent`,qy=`categories`,Jy=`label`,Yy=`group`,Xy=`push_mode`,Zy=`pop_mode`,Qy=`longer_alt`,$y=`line_breaks`,eb=`start_chars_hint`;function tb(e){return nb(e)}o(tb,`createToken`);function nb(e){let t=e.pattern,n={};if(n.name=e.name,w_(t)||(n.PATTERN=t),V(e,Ky))throw`The parent property is no longer supported.
91
+ See: https://github.com/chevrotain/chevrotain/issues/564#issuecomment-349062346 for details.`;return V(e,qy)&&(n.CATEGORIES=e[qy]),Ay([n]),V(e,Jy)&&(n.LABEL=e[Jy]),V(e,Yy)&&(n.GROUP=e[Yy]),V(e,Zy)&&(n.POP_MODE=e[Zy]),V(e,Xy)&&(n.PUSH_MODE=e[Xy]),V(e,Qy)&&(n.LONGER_ALT=e[Qy]),V(e,$y)&&(n.LINE_BREAKS=e[$y]),V(e,eb)&&(n.START_CHARS_HINT=e[eb]),n}o(nb,`createTokenInternal`);var rb=tb({name:`EOF`,pattern:Uy.NA});Ay([rb]);function ib(e,t,n,r,i,a,o,s){return{image:t,startOffset:n,endOffset:r,startLine:i,endLine:a,startColumn:o,endColumn:s,tokenTypeIdx:e.tokenTypeIdx,tokenType:e}}o(ib,`createTokenInstance`);function ab(e,t){return Ey(e,t)}o(ab,`tokenMatcher`);var ob={buildMismatchTokenMessage({expected:e,actual:t,previous:n,ruleName:r}){return`Expecting ${Gy(e)?`--> ${Wy(e)} <--`:`token of type --> ${e.name} <--`} but found --> '${t.image}' <--`},buildNotAllInputParsedMessage({firstRedundant:e,ruleName:t}){return`Redundant input, expecting EOF but found: `+e.image},buildNoViableAltMessage({expectedPathsPerAlt:e,actual:t,previous:n,customUserDescription:r,ruleName:i}){let a=`
92
+ but found: '`+Wg(t).image+`'`;return r?`Expecting: `+r+a:`Expecting: one of these possible Token sequences:
93
+ ${B(B(L_(e,(e,t)=>e.concat(t),[]),e=>`[${B(e,e=>Wy(e)).join(`, `)}]`),(e,t)=>` ${t+1}. ${e}`).join(`
94
+ `)}`+a},buildEarlyExitMessage({expectedIterationPaths:e,actual:t,customUserDescription:n,ruleName:r}){let i=`
95
+ but found: '`+Wg(t).image+`'`;return n?`Expecting: `+n+i:`Expecting: expecting at least one iteration which starts with one of these possible Token sequences::
96
+ <${B(e,e=>`[${B(e,e=>Wy(e)).join(`,`)}]`).join(` ,`)}>`+i}};Object.freeze(ob);var sb={buildRuleNotFoundError(e,t){return`Invalid grammar, reference to a rule which is not defined: ->`+t.nonTerminalName+`<-
97
+ inside top level rule: ->`+e.name+`<-`}},cb={buildDuplicateFoundError(e,t){function n(e){return e instanceof G?e.terminalType.name:e instanceof rv?e.nonTerminalName:``}o(n,`getExtraProductionArgument`);let r=e.name,i=Wg(t),a=i.idx,s=_v(i),c=n(i),l=`->${s}${a>0?a:``}<- ${c?`with argument: ->${c}<-`:``}
98
+ appears more than once (${t.length} times) in the top level rule: ->${r}<-.
99
+ For further details see: https://chevrotain.io/docs/FAQ.html#NUMERICAL_SUFFIXES
100
+ `;return l=l.replace(/[ \t]+/g,` `),l=l.replace(/\s\s+/g,`
101
+ `),l},buildNamespaceConflictError(e){return`Namespace conflict found in grammar.
102
+ The grammar has both a Terminal(Token) and a Non-Terminal(Rule) named: <${e.name}>.
103
+ To resolve this make sure each Terminal and Non-Terminal names are unique
104
+ This is easy to accomplish by using the convention that Terminal names start with an uppercase letter
105
+ and Non-Terminal names start with a lower case letter.`},buildAlternationPrefixAmbiguityError(e){let t=B(e.prefixPath,e=>Wy(e)).join(`, `),n=e.alternation.idx===0?``:e.alternation.idx;return`Ambiguous alternatives: <${e.ambiguityIndices.join(` ,`)}> due to common lookahead prefix
106
+ in <OR${n}> inside <${e.topLevelRule.name}> Rule,
107
+ <${t}> may appears as a prefix path in all these alternatives.
108
+ See: https://chevrotain.io/docs/guide/resolving_grammar_errors.html#COMMON_PREFIX
109
+ For Further details.`},buildAlternationAmbiguityError(e){let t=B(e.prefixPath,e=>Wy(e)).join(`, `),n=e.alternation.idx===0?``:e.alternation.idx,r=`Ambiguous Alternatives Detected: <${e.ambiguityIndices.join(` ,`)}> in <OR${n}> inside <${e.topLevelRule.name}> Rule,
110
+ <${t}> may appears as a prefix path in all these alternatives.
111
+ `;return r+=`See: https://chevrotain.io/docs/guide/resolving_grammar_errors.html#AMBIGUOUS_ALTERNATIVES
112
+ For Further details.`,r},buildEmptyRepetitionError(e){let t=_v(e.repetition);return e.repetition.idx!==0&&(t+=e.repetition.idx),`The repetition <${t}> within Rule <${e.topLevelRule.name}> can never consume any tokens.
113
+ This could lead to an infinite loop.`},buildTokenNameError(e){return`deprecated`},buildEmptyAlternationError(e){return`Ambiguous empty alternative: <${e.emptyChoiceIdx+1}> in <OR${e.alternation.idx}> inside <${e.topLevelRule.name}> Rule.
114
+ Only the last alternative may be an empty alternative.`},buildTooManyAlternativesError(e){return`An Alternation cannot have more than 256 alternatives:
115
+ <OR${e.alternation.idx}> inside <${e.topLevelRule.name}> Rule.
116
+ has ${e.alternation.definition.length+1} alternatives.`},buildLeftRecursionError(e){let t=e.topLevelRule.name;return`Left Recursion found in grammar.
117
+ rule: <${t}> can be invoked from itself (directly or indirectly)
118
+ without consuming any Tokens. The grammar path that causes this is:
119
+ ${`${t} --> ${B(e.leftRecursionPath,e=>e.name).concat([t]).join(` --> `)}`}
120
+ To fix this refactor your grammar to remove the left recursion.
121
+ see: https://en.wikipedia.org/wiki/LL_parser#Left_factoring.`},buildInvalidRuleNameError(e){return`deprecated`},buildDuplicateRuleNameError(e){let t;return t=e.topLevelRule instanceof iv?e.topLevelRule.name:e.topLevelRule,`Duplicate definition, rule: ->${t}<- is already defined in the grammar: ->${e.grammarName}<-`}};function lb(e,t){let n=new ub(e,t);return n.resolveRefs(),n.errors}o(lb,`resolveGrammar`);var ub=class extends pv{static{o(this,`GastRefResolverVisitor`)}constructor(e,t){super(),this.nameToTopRule=e,this.errMsgProvider=t,this.errors=[]}resolveRefs(){z(H(this.nameToTopRule),e=>{this.currTopLevel=e,e.accept(this)})}visitNonTerminal(e){let t=this.nameToTopRule[e.nonTerminalName];if(t)e.referencedRule=t;else{let t=this.errMsgProvider.buildRuleNotFoundError(this.currTopLevel,e);this.errors.push({message:t,type:hS.UNRESOLVED_SUBRULE_REF,ruleName:this.currTopLevel.name,unresolvedRefName:e.nonTerminalName})}}},db=class extends vv{static{o(this,`AbstractNextPossibleTokensWalker`)}constructor(e,t){super(),this.topProd=e,this.path=t,this.possibleTokTypes=[],this.nextProductionName=``,this.nextProductionOccurrence=0,this.found=!1,this.isAtEndOfPath=!1}startWalking(){if(this.found=!1,this.path.ruleStack[0]!==this.topProd.name)throw Error(`The path does not start with the walker's top Rule!`);return this.ruleStack=Sm(this.path.ruleStack).reverse(),this.occurrenceStack=Sm(this.path.occurrenceStack).reverse(),this.ruleStack.pop(),this.occurrenceStack.pop(),this.updateExpectedNext(),this.walk(this.topProd),this.possibleTokTypes}walk(e,t=[]){this.found||super.walk(e,t)}walkProdRef(e,t,n){if(e.referencedRule.name===this.nextProductionName&&e.idx===this.nextProductionOccurrence){let r=t.concat(n);this.updateExpectedNext(),this.walk(e.referencedRule,r)}}updateExpectedNext(){U(this.ruleStack)?(this.nextProductionName=``,this.nextProductionOccurrence=0,this.isAtEndOfPath=!0):(this.nextProductionName=this.ruleStack.pop(),this.nextProductionOccurrence=this.occurrenceStack.pop())}},fb=class extends db{static{o(this,`NextAfterTokenWalker`)}constructor(e,t){super(e,t),this.path=t,this.nextTerminalName=``,this.nextTerminalOccurrence=0,this.nextTerminalName=this.path.lastTok.name,this.nextTerminalOccurrence=this.path.lastTokOccurrence}walkTerminal(e,t,n){if(this.isAtEndOfPath&&e.terminalType.name===this.nextTerminalName&&e.idx===this.nextTerminalOccurrence&&!this.found){let e=new av({definition:t.concat(n)});this.possibleTokTypes=bv(e),this.found=!0}}},pb=class extends vv{static{o(this,`AbstractNextTerminalAfterProductionWalker`)}constructor(e,t){super(),this.topRule=e,this.occurrence=t,this.result={token:void 0,occurrence:void 0,isEndOfRule:void 0}}startWalking(){return this.walk(this.topRule),this.result}},mb=class extends pb{static{o(this,`NextTerminalAfterManyWalker`)}walkMany(e,t,n){if(e.idx===this.occurrence){let e=Wg(t.concat(n));this.result.isEndOfRule=e===void 0,e instanceof G&&(this.result.token=e.terminalType,this.result.occurrence=e.idx)}else super.walkMany(e,t,n)}},hb=class extends pb{static{o(this,`NextTerminalAfterManySepWalker`)}walkManySep(e,t,n){if(e.idx===this.occurrence){let e=Wg(t.concat(n));this.result.isEndOfRule=e===void 0,e instanceof G&&(this.result.token=e.terminalType,this.result.occurrence=e.idx)}else super.walkManySep(e,t,n)}},gb=class extends pb{static{o(this,`NextTerminalAfterAtLeastOneWalker`)}walkAtLeastOne(e,t,n){if(e.idx===this.occurrence){let e=Wg(t.concat(n));this.result.isEndOfRule=e===void 0,e instanceof G&&(this.result.token=e.terminalType,this.result.occurrence=e.idx)}else super.walkAtLeastOne(e,t,n)}},_b=class extends pb{static{o(this,`NextTerminalAfterAtLeastOneSepWalker`)}walkAtLeastOneSep(e,t,n){if(e.idx===this.occurrence){let e=Wg(t.concat(n));this.result.isEndOfRule=e===void 0,e instanceof G&&(this.result.token=e.terminalType,this.result.occurrence=e.idx)}else super.walkAtLeastOneSep(e,t,n)}};function vb(e,t,n=[]){n=Sm(n);let r=[],i=0;function a(t){return t.concat(Sg(e,i+1))}o(a,`remainingPathWith`);function s(e){let i=vb(a(e),t,n);return r.concat(i)}for(o(s,`getAlternativesForProd`);n.length<t&&i<e.length;){let t=e[i];if(t instanceof av||t instanceof rv)return s(t.definition);if(t instanceof ov)r=s(t.definition);else if(t instanceof sv)return s(t.definition.concat([new W({definition:t.definition})]));else if(t instanceof cv)return s([new av({definition:t.definition}),new W({definition:[new G({terminalType:t.separator})].concat(t.definition)})]);else if(t instanceof lv)r=s(t.definition.concat([new W({definition:[new G({terminalType:t.separator})].concat(t.definition)})]));else if(t instanceof W)r=s(t.definition.concat([new W({definition:t.definition})]));else if(t instanceof uv)return z(t.definition,e=>{U(e.definition)===!1&&(r=s(e.definition))}),r;else if(t instanceof G)n.push(t.terminalType);else throw Error(`non exhaustive match`);i++}return r.push({partialPath:n,suffixDef:Sg(e,i)}),r}o(vb,`possiblePathsFrom`);function yb(e,t,n,r){let i=`EXIT_NONE_TERMINAL`,a=[i],o=`EXIT_ALTERNATIVE`,s=!1,c=t.length,l=c-r-1,u=[],d=[];for(d.push({idx:-1,def:e,ruleStack:[],occurrenceStack:[]});!U(d);){let e=d.pop();if(e===o){s&&bg(d).idx<=l&&d.pop();continue}let r=e.def,f=e.idx,p=e.ruleStack,m=e.occurrenceStack;if(U(r))continue;let h=r[0];if(h===i){let e={idx:f,def:Sg(r),ruleStack:wg(p),occurrenceStack:wg(m)};d.push(e)}else if(h instanceof G)if(f<c-1){let e=f+1,i=t[e];if(n(i,h.terminalType)){let t={idx:e,def:Sg(r),ruleStack:p,occurrenceStack:m};d.push(t)}}else if(f===c-1)u.push({nextTokenType:h.terminalType,nextTokenOccurrence:h.idx,ruleStack:p,occurrenceStack:m}),s=!0;else throw Error(`non exhaustive match`);else if(h instanceof rv){let e=Sm(p);e.push(h.nonTerminalName);let t=Sm(m);t.push(h.idx);let n={idx:f,def:h.definition.concat(a,Sg(r)),ruleStack:e,occurrenceStack:t};d.push(n)}else if(h instanceof ov){let e={idx:f,def:Sg(r),ruleStack:p,occurrenceStack:m};d.push(e),d.push(o);let t={idx:f,def:h.definition.concat(Sg(r)),ruleStack:p,occurrenceStack:m};d.push(t)}else if(h instanceof sv){let e=new W({definition:h.definition,idx:h.idx}),t={idx:f,def:h.definition.concat([e],Sg(r)),ruleStack:p,occurrenceStack:m};d.push(t)}else if(h instanceof cv){let e=new W({definition:[new G({terminalType:h.separator})].concat(h.definition),idx:h.idx}),t={idx:f,def:h.definition.concat([e],Sg(r)),ruleStack:p,occurrenceStack:m};d.push(t)}else if(h instanceof lv){let e={idx:f,def:Sg(r),ruleStack:p,occurrenceStack:m};d.push(e),d.push(o);let t=new W({definition:[new G({terminalType:h.separator})].concat(h.definition),idx:h.idx}),n={idx:f,def:h.definition.concat([t],Sg(r)),ruleStack:p,occurrenceStack:m};d.push(n)}else if(h instanceof W){let e={idx:f,def:Sg(r),ruleStack:p,occurrenceStack:m};d.push(e),d.push(o);let t=new W({definition:h.definition,idx:h.idx}),n={idx:f,def:h.definition.concat([t],Sg(r)),ruleStack:p,occurrenceStack:m};d.push(n)}else if(h instanceof uv)for(let e=h.definition.length-1;e>=0;e--){let t={idx:f,def:h.definition[e].definition.concat(Sg(r)),ruleStack:p,occurrenceStack:m};d.push(t),d.push(o)}else if(h instanceof av)d.push({idx:f,def:h.definition.concat(Sg(r)),ruleStack:p,occurrenceStack:m});else if(h instanceof iv)d.push(bb(h,f,p,m));else throw Error(`non exhaustive match`)}return u}o(yb,`nextPossibleTokensAfter`);function bb(e,t,n,r){let i=Sm(n);i.push(e.name);let a=Sm(r);return a.push(1),{idx:t,def:e.definition,ruleStack:i,occurrenceStack:a}}o(bb,`expandTopLevelRule`);var q;(function(e){e[e.OPTION=0]=`OPTION`,e[e.REPETITION=1]=`REPETITION`,e[e.REPETITION_MANDATORY=2]=`REPETITION_MANDATORY`,e[e.REPETITION_MANDATORY_WITH_SEPARATOR=3]=`REPETITION_MANDATORY_WITH_SEPARATOR`,e[e.REPETITION_WITH_SEPARATOR=4]=`REPETITION_WITH_SEPARATOR`,e[e.ALTERNATION=5]=`ALTERNATION`})(q||={});function xb(e){if(e instanceof ov||e===`Option`)return q.OPTION;if(e instanceof W||e===`Repetition`)return q.REPETITION;if(e instanceof sv||e===`RepetitionMandatory`)return q.REPETITION_MANDATORY;if(e instanceof cv||e===`RepetitionMandatoryWithSeparator`)return q.REPETITION_MANDATORY_WITH_SEPARATOR;if(e instanceof lv||e===`RepetitionWithSeparator`)return q.REPETITION_WITH_SEPARATOR;if(e instanceof uv||e===`Alternation`)return q.ALTERNATION;throw Error(`non exhaustive match`)}o(xb,`getProdType`);function Sb(e){let{occurrence:t,rule:n,prodType:r,maxLookahead:i}=e,a=xb(r);return a===q.ALTERNATION?Nb(t,n,i):Pb(t,n,a,i)}o(Sb,`getLookaheadPaths`);function Cb(e,t,n,r,i,a){let o=Nb(e,t,n);return a(o,r,Lb(o)?Dy:Ey,i)}o(Cb,`buildLookaheadFuncForOr`);function wb(e,t,n,r,i,a){let o=Pb(e,t,i,n),s=Lb(o)?Dy:Ey;return a(o[0],s,r)}o(wb,`buildLookaheadFuncForOptionalProd`);function Tb(e,t,n,r){let i=e.length,a=Ng(e,e=>Ng(e,e=>e.length===1));if(t)return function(t){let r=B(t,e=>e.GATE);for(let t=0;t<i;t++){let i=e[t],a=i.length,o=r[t];if(!(o!==void 0&&o.call(this)===!1))nextPath:for(let e=0;e<a;e++){let r=i[e],a=r.length;for(let e=0;e<a;e++)if(n(this.LA(e+1),r[e])===!1)continue nextPath;return t}}};if(a&&!r){let t=L_(B(e,e=>Ld(e)),(e,t,n)=>(z(t,t=>{V(e,t.tokenTypeIdx)||(e[t.tokenTypeIdx]=n),z(t.categoryMatches,t=>{V(e,t)||(e[t]=n)})}),e),{});return function(){return t[this.LA(1).tokenTypeIdx]}}else return function(){for(let t=0;t<i;t++){let r=e[t],i=r.length;nextPath:for(let e=0;e<i;e++){let i=r[e],a=i.length;for(let e=0;e<a;e++)if(n(this.LA(e+1),i[e])===!1)continue nextPath;return t}}}}o(Tb,`buildAlternativesLookAheadFunc`);function Eb(e,t,n){let r=Ng(e,e=>e.length===1),i=e.length;if(r&&!n){let t=Ld(e);if(t.length===1&&U(t[0].categoryMatches)){let e=t[0].tokenTypeIdx;return function(){return this.LA(1).tokenTypeIdx===e}}else{let e=L_(t,(e,t,n)=>(e[t.tokenTypeIdx]=!0,z(t.categoryMatches,t=>{e[t]=!0}),e),[]);return function(){return e[this.LA(1).tokenTypeIdx]===!0}}}else return function(){nextPath:for(let n=0;n<i;n++){let r=e[n],i=r.length;for(let e=0;e<i;e++)if(t(this.LA(e+1),r[e])===!1)continue nextPath;return!0}return!1}}o(Eb,`buildSingleAlternativeLookaheadFunction`);var Db=class extends vv{static{o(this,`RestDefinitionFinderWalker`)}constructor(e,t,n){super(),this.topProd=e,this.targetOccurrence=t,this.targetProdType=n}startWalking(){return this.walk(this.topProd),this.restDef}checkIsTarget(e,t,n,r){return e.idx===this.targetOccurrence&&this.targetProdType===t?(this.restDef=n.concat(r),!0):!1}walkOption(e,t,n){this.checkIsTarget(e,q.OPTION,t,n)||super.walkOption(e,t,n)}walkAtLeastOne(e,t,n){this.checkIsTarget(e,q.REPETITION_MANDATORY,t,n)||super.walkOption(e,t,n)}walkAtLeastOneSep(e,t,n){this.checkIsTarget(e,q.REPETITION_MANDATORY_WITH_SEPARATOR,t,n)||super.walkOption(e,t,n)}walkMany(e,t,n){this.checkIsTarget(e,q.REPETITION,t,n)||super.walkOption(e,t,n)}walkManySep(e,t,n){this.checkIsTarget(e,q.REPETITION_WITH_SEPARATOR,t,n)||super.walkOption(e,t,n)}},Ob=class extends pv{static{o(this,`InsideDefinitionFinderVisitor`)}constructor(e,t,n){super(),this.targetOccurrence=e,this.targetProdType=t,this.targetRef=n,this.result=[]}checkIsTarget(e,t){e.idx===this.targetOccurrence&&this.targetProdType===t&&(this.targetRef===void 0||e===this.targetRef)&&(this.result=e.definition)}visitOption(e){this.checkIsTarget(e,q.OPTION)}visitRepetition(e){this.checkIsTarget(e,q.REPETITION)}visitRepetitionMandatory(e){this.checkIsTarget(e,q.REPETITION_MANDATORY)}visitRepetitionMandatoryWithSeparator(e){this.checkIsTarget(e,q.REPETITION_MANDATORY_WITH_SEPARATOR)}visitRepetitionWithSeparator(e){this.checkIsTarget(e,q.REPETITION_WITH_SEPARATOR)}visitAlternation(e){this.checkIsTarget(e,q.ALTERNATION)}};function kb(e){let t=Array(e);for(let n=0;n<e;n++)t[n]=[];return t}o(kb,`initializeArrayOfArrays`);function Ab(e){let t=[``];for(let n=0;n<e.length;n++){let r=e[n],i=[];for(let e=0;e<t.length;e++){let n=t[e];i.push(n+`_`+r.tokenTypeIdx);for(let e=0;e<r.categoryMatches.length;e++){let t=`_`+r.categoryMatches[e];i.push(n+t)}}t=i}return t}o(Ab,`pathToHashKeys`);function jb(e,t,n){for(let r=0;r<e.length;r++){if(r===n)continue;let i=e[r];for(let e=0;e<t.length;e++)if(i[t[e]]===!0)return!1}return!0}o(jb,`isUniquePrefixHash`);function Mb(e,t){let n=B(e,e=>vb([e],1)),r=kb(n.length),i=B(n,e=>{let t={};return z(e,e=>{z(Ab(e.partialPath),e=>{t[e]=!0})}),t}),a=n;for(let e=1;e<=t;e++){let n=a;a=kb(n.length);for(let o=0;o<n.length;o++){let s=n[o];for(let n=0;n<s.length;n++){let c=s[n].partialPath,l=s[n].suffixDef,u=Ab(c);if(jb(i,u,o)||U(l)||c.length===t){let e=r[o];if(Fb(e,c)===!1){e.push(c);for(let e=0;e<u.length;e++){let t=u[e];i[o][t]=!0}}}else{let t=vb(l,e+1,c);a[o]=a[o].concat(t),z(t,e=>{z(Ab(e.partialPath),e=>{i[o][e]=!0})})}}}}return r}o(Mb,`lookAheadSequenceFromAlternatives`);function Nb(e,t,n,r){let i=new Ob(e,q.ALTERNATION,r);return t.accept(i),Mb(i.result,n)}o(Nb,`getLookaheadPathsForOr`);function Pb(e,t,n,r){let i=new Ob(e,n);t.accept(i);let a=i.result,o=new Db(t,e,n).startWalking();return Mb([new av({definition:a}),new av({definition:o})],r)}o(Pb,`getLookaheadPathsForOptionalProd`);function Fb(e,t){compareOtherPath:for(let n=0;n<e.length;n++){let r=e[n];if(r.length===t.length){for(let e=0;e<r.length;e++){let n=t[e],i=r[e];if(!(n===i||i.categoryMatchesMap[n.tokenTypeIdx]!==void 0))continue compareOtherPath}return!0}}return!1}o(Fb,`containsPath`);function Ib(e,t){return e.length<t.length&&Ng(e,(e,n)=>{let r=t[n];return e===r||r.categoryMatchesMap[e.tokenTypeIdx]})}o(Ib,`isStrictPrefixOfPath`);function Lb(e){return Ng(e,e=>Ng(e,e=>Ng(e,e=>U(e.categoryMatches))))}o(Lb,`areTokenCategoriesNotUsed`);function Rb(e){return B(e.lookaheadStrategy.validate({rules:e.rules,tokenTypes:e.tokenTypes,grammarName:e.grammarName}),e=>Object.assign({type:hS.CUSTOM_LOOKAHEAD_VALIDATION},e))}o(Rb,`validateLookahead`);function zb(e,t,n,r){let i=Yg(e,e=>Bb(e,n)),a=nx(e,t,n),o=Yg(e,e=>Qb(e,n)),s=Yg(e,t=>Wb(t,e,r,n));return i.concat(a,o,s)}o(zb,`validateGrammar`);function Bb(e,t){let n=new Ub;e.accept(n);let r=n.allProductions;return B(H(N_(Zg(r,Vb),e=>e.length>1)),n=>{let r=Wg(n),i=t.buildDuplicateFoundError(e,n),a=_v(r),o={message:i,type:hS.DUPLICATE_PRODUCTIONS,ruleName:e.name,dslName:a,occurrence:r.idx},s=Hb(r);return s&&(o.parameter=s),o})}o(Bb,`validateDuplicateProductions`);function Vb(e){return`${_v(e)}_#_${e.idx}_#_${Hb(e)}`}o(Vb,`identifyProductionForDuplicates`);function Hb(e){return e instanceof G?e.terminalType.name:e instanceof rv?e.nonTerminalName:``}o(Hb,`getExtraProductionArgument`);var Ub=class extends pv{static{o(this,`OccurrenceValidationCollector`)}constructor(){super(...arguments),this.allProductions=[]}visitNonTerminal(e){this.allProductions.push(e)}visitOption(e){this.allProductions.push(e)}visitRepetitionWithSeparator(e){this.allProductions.push(e)}visitRepetitionMandatory(e){this.allProductions.push(e)}visitRepetitionMandatoryWithSeparator(e){this.allProductions.push(e)}visitRepetition(e){this.allProductions.push(e)}visitAlternation(e){this.allProductions.push(e)}visitTerminal(e){this.allProductions.push(e)}};function Wb(e,t,n,r){let i=[];if(L_(t,(t,n)=>n.name===e.name?t+1:t,0)>1){let t=r.buildDuplicateRuleNameError({topLevelRule:e,grammarName:n});i.push({message:t,type:hS.DUPLICATE_RULE_NAME,ruleName:e.name})}return i}o(Wb,`validateRuleDoesNotAlreadyExist`);function Gb(e,t,n){let r=[],i;return u_(t,e)||(i=`Invalid rule override, rule: ->${e}<- cannot be overridden in the grammar: ->${n}<-as it is not defined in any of the super grammars `,r.push({message:i,type:hS.INVALID_RULE_OVERRIDE,ruleName:e})),r}o(Gb,`validateRuleIsOverridden`);function Kb(e,t,n,r=[]){let i=[],a=qb(t.definition);if(U(a))return[];{let t=e.name;u_(a,e)&&i.push({message:n.buildLeftRecursionError({topLevelRule:e,leftRecursionPath:r}),type:hS.LEFT_RECURSION,ruleName:t});let o=Yg(vg(a,r.concat([e])),t=>{let i=Sm(r);return i.push(t),Kb(e,t,n,i)});return i.concat(o)}}o(Kb,`validateNoLeftRecursion`);function qb(e){let t=[];if(U(e))return t;let n=Wg(e);if(n instanceof rv)t.push(n.referencedRule);else if(n instanceof av||n instanceof ov||n instanceof sv||n instanceof cv||n instanceof lv||n instanceof W)t=t.concat(qb(n.definition));else if(n instanceof uv)t=Ld(B(n.definition,e=>qb(e.definition)));else if(!(n instanceof G))throw Error(`non exhaustive match`);let r=hv(n),i=e.length>1;if(r&&i){let n=Sg(e);return t.concat(qb(n))}else return t}o(qb,`getFirstNoneTerminal`);var Jb=class extends pv{static{o(this,`OrCollector`)}constructor(){super(...arguments),this.alternations=[]}visitAlternation(e){this.alternations.push(e)}};function Yb(e,t){let n=new Jb;e.accept(n);let r=n.alternations;return Yg(r,n=>Yg(wg(n.definition),(r,i)=>U(yb([r],[],Ey,1))?[{message:t.buildEmptyAlternationError({topLevelRule:e,alternation:n,emptyChoiceIdx:i}),type:hS.NONE_LAST_EMPTY_ALT,ruleName:e.name,occurrence:n.idx,alternative:i+1}]:[]))}o(Yb,`validateEmptyOrAlternative`);function Xb(e,t,n){let r=new Jb;e.accept(r);let i=r.alternations;return i=z_(i,e=>e.ignoreAmbiguities===!0),Yg(i,r=>{let i=r.idx,a=Nb(i,e,r.maxLookahead||t,r),o=ex(a,r,e,n),s=tx(a,r,e,n);return o.concat(s)})}o(Xb,`validateAmbiguousAlternationAlternatives`);var Zb=class extends pv{static{o(this,`RepetitionCollector`)}constructor(){super(...arguments),this.allProductions=[]}visitRepetitionWithSeparator(e){this.allProductions.push(e)}visitRepetitionMandatory(e){this.allProductions.push(e)}visitRepetitionMandatoryWithSeparator(e){this.allProductions.push(e)}visitRepetition(e){this.allProductions.push(e)}};function Qb(e,t){let n=new Jb;e.accept(n);let r=n.alternations;return Yg(r,n=>n.definition.length>255?[{message:t.buildTooManyAlternativesError({topLevelRule:e,alternation:n}),type:hS.TOO_MANY_ALTS,ruleName:e.name,occurrence:n.idx}]:[])}o(Qb,`validateTooManyAlts`);function $b(e,t,n){let r=[];return z(e,e=>{let i=new Zb;e.accept(i);let a=i.allProductions;z(a,i=>{let a=xb(i),o=i.maxLookahead||t,s=i.idx,c=Pb(s,e,a,o)[0];if(U(Ld(c))){let t=n.buildEmptyRepetitionError({topLevelRule:e,repetition:i});r.push({message:t,type:hS.NO_NON_EMPTY_LOOKAHEAD,ruleName:e.name})}})}),r}o($b,`validateSomeNonEmptyLookaheadPath`);function ex(e,t,n,r){let i=[];return B(L_(e,(n,r,a)=>(t.definition[a].ignoreAmbiguities===!0||z(r,r=>{let o=[a];z(e,(e,n)=>{a!==n&&Fb(e,r)&&t.definition[n].ignoreAmbiguities!==!0&&o.push(n)}),o.length>1&&!Fb(i,r)&&(i.push(r),n.push({alts:o,path:r}))}),n),[]),e=>{let i=B(e.alts,e=>e+1);return{message:r.buildAlternationAmbiguityError({topLevelRule:n,alternation:t,ambiguityIndices:i,prefixPath:e.path}),type:hS.AMBIGUOUS_ALTS,ruleName:n.name,occurrence:t.idx,alternatives:e.alts}})}o(ex,`checkAlternativesAmbiguities`);function tx(e,t,n,r){let i=L_(e,(e,t,n)=>{let r=B(t,e=>({idx:n,path:e}));return e.concat(r)},[]);return wm(Yg(i,e=>{if(t.definition[e.idx].ignoreAmbiguities===!0)return[];let a=e.idx,o=e.path;return B(Lg(i,e=>t.definition[e.idx].ignoreAmbiguities!==!0&&e.idx<a&&Ib(e.path,o)),e=>{let i=[e.idx+1,a+1],o=t.idx===0?``:t.idx;return{message:r.buildAlternationPrefixAmbiguityError({topLevelRule:n,alternation:t,ambiguityIndices:i,prefixPath:e.path}),type:hS.AMBIGUOUS_PREFIX_ALTS,ruleName:n.name,occurrence:o,alternatives:i}})}))}o(tx,`checkPrefixAlternativesAmbiguities`);function nx(e,t,n){let r=[],i=B(t,e=>e.name);return z(e,e=>{let t=e.name;if(u_(i,t)){let i=n.buildNamespaceConflictError(e);r.push({message:i,type:hS.CONFLICT_TOKENS_RULES_NAMESPACE,ruleName:t})}}),r}o(nx,`checkTerminalAndNoneTerminalsNameSpace`);function rx(e){let t=ug(e,{errMsgProvider:sb}),n={};return z(e.rules,e=>{n[e.name]=e}),lb(n,t.errMsgProvider)}o(rx,`resolveGrammar`);function ix(e){return e=ug(e,{errMsgProvider:cb}),zb(e.rules,e.tokenTypes,e.errMsgProvider,e.grammarName)}o(ix,`validateGrammar`);var ax=`MismatchedTokenException`,ox=`NoViableAltException`,sx=`EarlyExitException`,cx=`NotAllInputParsedException`,lx=[ax,ox,sx,cx];Object.freeze(lx);function ux(e){return u_(lx,e.name)}o(ux,`isRecognitionException`);var dx=class extends Error{static{o(this,`RecognitionException`)}constructor(e,t){super(e),this.token=t,this.resyncedTokens=[],Object.setPrototypeOf(this,new.target.prototype),Error.captureStackTrace&&Error.captureStackTrace(this,this.constructor)}},fx=class extends dx{static{o(this,`MismatchedTokenException`)}constructor(e,t,n){super(e,t),this.previousToken=n,this.name=ax}},px=class extends dx{static{o(this,`NoViableAltException`)}constructor(e,t,n){super(e,t),this.previousToken=n,this.name=ox}},mx=class extends dx{static{o(this,`NotAllInputParsedException`)}constructor(e,t){super(e,t),this.name=cx}},hx=class extends dx{static{o(this,`EarlyExitException`)}constructor(e,t,n){super(e,t),this.previousToken=n,this.name=sx}},gx={},_x=`InRuleRecoveryException`,vx=class extends Error{static{o(this,`InRuleRecoveryException`)}constructor(e){super(e),this.name=_x}},yx=class{static{o(this,`Recoverable`)}initRecoverable(e){this.firstAfterRepMap={},this.resyncFollows={},this.recoveryEnabled=V(e,`recoveryEnabled`)?e.recoveryEnabled:pS.recoveryEnabled,this.recoveryEnabled&&(this.attemptInRepetitionRecovery=bx)}getTokenToInsert(e){let t=ib(e,``,NaN,NaN,NaN,NaN,NaN,NaN);return t.isInsertedInRecovery=!0,t}canTokenTypeBeInsertedInRecovery(e){return!0}canTokenTypeBeDeletedInRecovery(e){return!0}tryInRepetitionRecovery(e,t,n,r){let i=this.findReSyncTokenType(),a=this.exportLexerState(),s=[],c=!1,l=this.LA(1),u=this.LA(1),d=o(()=>{let e=this.LA(0),t=new fx(this.errorMessageProvider.buildMismatchTokenMessage({expected:r,actual:l,previous:e,ruleName:this.getCurrRuleFullName()}),l,this.LA(0));t.resyncedTokens=wg(s),this.SAVE_ERROR(t)},`generateErrorMessage`);for(;!c;)if(this.tokenMatcher(u,r)){d();return}else if(n.call(this)){d(),e.apply(this,t);return}else this.tokenMatcher(u,i)?c=!0:(u=this.SKIP_TOKEN(),this.addToResyncTokens(u,s));this.importLexerState(a)}shouldInRepetitionRecoveryBeTried(e,t,n){return!(n===!1||this.tokenMatcher(this.LA(1),e)||this.isBackTracking()||this.canPerformInRuleRecovery(e,this.getFollowsForInRuleRecovery(e,t)))}getFollowsForInRuleRecovery(e,t){let n=this.getCurrentGrammarPath(e,t);return this.getNextPossibleTokenTypes(n)}tryInRuleRecovery(e,t){if(this.canRecoverWithSingleTokenInsertion(e,t))return this.getTokenToInsert(e);if(this.canRecoverWithSingleTokenDeletion(e)){let e=this.SKIP_TOKEN();return this.consumeToken(),e}throw new vx(`sad sad panda`)}canPerformInRuleRecovery(e,t){return this.canRecoverWithSingleTokenInsertion(e,t)||this.canRecoverWithSingleTokenDeletion(e)}canRecoverWithSingleTokenInsertion(e,t){if(!this.canTokenTypeBeInsertedInRecovery(e)||U(t))return!1;let n=this.LA(1);return Hg(t,e=>this.tokenMatcher(n,e))!==void 0}canRecoverWithSingleTokenDeletion(e){return this.canTokenTypeBeDeletedInRecovery(e)?this.tokenMatcher(this.LA(2),e):!1}isInCurrentRuleReSyncSet(e){let t=this.getCurrFollowKey();return u_(this.getFollowSetFromFollowKey(t),e)}findReSyncTokenType(){let e=this.flattenFollowSet(),t=this.LA(1),n=2;for(;;){let r=Hg(e,e=>ab(t,e));if(r!==void 0)return r;t=this.LA(n),n++}}getCurrFollowKey(){if(this.RULE_STACK.length===1)return gx;let e=this.getLastExplicitRuleShortName(),t=this.getLastExplicitRuleOccurrenceIndex(),n=this.getPreviousExplicitRuleShortName();return{ruleName:this.shortRuleNameToFullName(e),idxInCallingRule:t,inRule:this.shortRuleNameToFullName(n)}}buildFullFollowKeyStack(){let e=this.RULE_STACK,t=this.RULE_OCCURRENCE_STACK;return B(e,(n,r)=>r===0?gx:{ruleName:this.shortRuleNameToFullName(n),idxInCallingRule:t[r],inRule:this.shortRuleNameToFullName(e[r-1])})}flattenFollowSet(){return Ld(B(this.buildFullFollowKeyStack(),e=>this.getFollowSetFromFollowKey(e)))}getFollowSetFromFollowKey(e){if(e===gx)return[rb];let t=e.ruleName+e.idxInCallingRule+wv+e.inRule;return this.resyncFollows[t]}addToResyncTokens(e,t){return this.tokenMatcher(e,rb)||t.push(e),t}reSyncTo(e){let t=[],n=this.LA(1);for(;this.tokenMatcher(n,e)===!1;)n=this.SKIP_TOKEN(),this.addToResyncTokens(n,t);return wg(t)}attemptInRepetitionRecovery(e,t,n,r,i,a,o){}getCurrentGrammarPath(e,t){return{ruleStack:this.getHumanReadableRuleStack(),occurrenceStack:Sm(this.RULE_OCCURRENCE_STACK),lastTok:e,lastTokOccurrence:t}}getHumanReadableRuleStack(){return B(this.RULE_STACK,e=>this.shortRuleNameToFullName(e))}};function bx(e,t,n,r,i,a,o){let s=this.getKeyForAutomaticLookahead(r,i),c=this.firstAfterRepMap[s];if(c===void 0){let e=this.getCurrRuleFullName(),t=this.getGAstProductions()[e];c=new a(t,i).startWalking(),this.firstAfterRepMap[s]=c}let l=c.token,u=c.occurrence,d=c.isEndOfRule;this.RULE_STACK.length===1&&d&&l===void 0&&(l=rb,u=1),!(l===void 0||u===void 0)&&this.shouldInRepetitionRecoveryBeTried(l,u,o)&&this.tryInRepetitionRecovery(e,t,n,l)}o(bx,`attemptInRepetitionRecovery`);var xx=4,Sx=8,Cx=8,wx=1<<Sx,Tx=2<<Sx,Ex=3<<Sx,Dx=4<<Sx,Ox=5<<Sx,kx=6<<Sx;function Ax(e,t,n){return n|t|e}o(Ax,`getKeyForAutomaticLookahead`),32-Cx;var jx=class{static{o(this,`LLkLookaheadStrategy`)}constructor(e){this.maxLookahead=e?.maxLookahead??pS.maxLookahead}validate(e){let t=this.validateNoLeftRecursion(e.rules);if(U(t)){let n=this.validateEmptyOrAlternatives(e.rules),r=this.validateAmbiguousAlternationAlternatives(e.rules,this.maxLookahead),i=this.validateSomeNonEmptyLookaheadPath(e.rules,this.maxLookahead);return[...t,...n,...r,...i]}return t}validateNoLeftRecursion(e){return Yg(e,e=>Kb(e,e,cb))}validateEmptyOrAlternatives(e){return Yg(e,e=>Yb(e,cb))}validateAmbiguousAlternationAlternatives(e,t){return Yg(e,e=>Xb(e,t,cb))}validateSomeNonEmptyLookaheadPath(e,t){return $b(e,t,cb)}buildLookaheadForAlternation(e){return Cb(e.prodOccurrence,e.rule,e.maxLookahead,e.hasPredicates,e.dynamicTokensEnabled,Tb)}buildLookaheadForOptional(e){return wb(e.prodOccurrence,e.rule,e.maxLookahead,e.dynamicTokensEnabled,xb(e.prodType),Eb)}},Mx=class{static{o(this,`LooksAhead`)}initLooksAhead(e){this.dynamicTokensEnabled=V(e,`dynamicTokensEnabled`)?e.dynamicTokensEnabled:pS.dynamicTokensEnabled,this.maxLookahead=V(e,`maxLookahead`)?e.maxLookahead:pS.maxLookahead,this.lookaheadStrategy=V(e,`lookaheadStrategy`)?e.lookaheadStrategy:new jx({maxLookahead:this.maxLookahead}),this.lookAheadFuncsCache=new Map}preComputeLookaheadFunctions(e){z(e,e=>{this.TRACE_INIT(`${e.name} Rule Lookahead`,()=>{let{alternation:t,repetition:n,option:r,repetitionMandatory:i,repetitionMandatoryWithSeparator:a,repetitionWithSeparator:o}=Px(e);z(t,t=>{let n=t.idx===0?``:t.idx;this.TRACE_INIT(`${_v(t)}${n}`,()=>{let n=this.lookaheadStrategy.buildLookaheadForAlternation({prodOccurrence:t.idx,rule:e,maxLookahead:t.maxLookahead||this.maxLookahead,hasPredicates:t.hasPredicates,dynamicTokensEnabled:this.dynamicTokensEnabled}),r=Ax(this.fullRuleNameToShort[e.name],wx,t.idx);this.setLaFuncCache(r,n)})}),z(n,t=>{this.computeLookaheadFunc(e,t.idx,Ex,`Repetition`,t.maxLookahead,_v(t))}),z(r,t=>{this.computeLookaheadFunc(e,t.idx,Tx,`Option`,t.maxLookahead,_v(t))}),z(i,t=>{this.computeLookaheadFunc(e,t.idx,Dx,`RepetitionMandatory`,t.maxLookahead,_v(t))}),z(a,t=>{this.computeLookaheadFunc(e,t.idx,kx,`RepetitionMandatoryWithSeparator`,t.maxLookahead,_v(t))}),z(o,t=>{this.computeLookaheadFunc(e,t.idx,Ox,`RepetitionWithSeparator`,t.maxLookahead,_v(t))})})})}computeLookaheadFunc(e,t,n,r,i,a){this.TRACE_INIT(`${a}${t===0?``:t}`,()=>{let a=this.lookaheadStrategy.buildLookaheadForOptional({prodOccurrence:t,rule:e,maxLookahead:i||this.maxLookahead,dynamicTokensEnabled:this.dynamicTokensEnabled,prodType:r}),o=Ax(this.fullRuleNameToShort[e.name],n,t);this.setLaFuncCache(o,a)})}getKeyForAutomaticLookahead(e,t){return Ax(this.getLastExplicitRuleShortName(),e,t)}getLaFuncFromCache(e){return this.lookAheadFuncsCache.get(e)}setLaFuncCache(e,t){this.lookAheadFuncsCache.set(e,t)}},Nx=new class extends pv{static{o(this,`DslMethodsCollectorVisitor`)}constructor(){super(...arguments),this.dslMethods={option:[],alternation:[],repetition:[],repetitionWithSeparator:[],repetitionMandatory:[],repetitionMandatoryWithSeparator:[]}}reset(){this.dslMethods={option:[],alternation:[],repetition:[],repetitionWithSeparator:[],repetitionMandatory:[],repetitionMandatoryWithSeparator:[]}}visitOption(e){this.dslMethods.option.push(e)}visitRepetitionWithSeparator(e){this.dslMethods.repetitionWithSeparator.push(e)}visitRepetitionMandatory(e){this.dslMethods.repetitionMandatory.push(e)}visitRepetitionMandatoryWithSeparator(e){this.dslMethods.repetitionMandatoryWithSeparator.push(e)}visitRepetition(e){this.dslMethods.repetition.push(e)}visitAlternation(e){this.dslMethods.alternation.push(e)}};function Px(e){Nx.reset(),e.accept(Nx);let t=Nx.dslMethods;return Nx.reset(),t}o(Px,`collectMethods`);function Fx(e,t){isNaN(e.startOffset)===!0?(e.startOffset=t.startOffset,e.endOffset=t.endOffset):e.endOffset<t.endOffset&&(e.endOffset=t.endOffset)}o(Fx,`setNodeLocationOnlyOffset`);function Ix(e,t){isNaN(e.startOffset)===!0?(e.startOffset=t.startOffset,e.startColumn=t.startColumn,e.startLine=t.startLine,e.endOffset=t.endOffset,e.endColumn=t.endColumn,e.endLine=t.endLine):e.endOffset<t.endOffset&&(e.endOffset=t.endOffset,e.endColumn=t.endColumn,e.endLine=t.endLine)}o(Ix,`setNodeLocationFull`);function Lx(e,t,n){e.children[n]===void 0?e.children[n]=[t]:e.children[n].push(t)}o(Lx,`addTerminalToCst`);function Rx(e,t,n){e.children[t]===void 0?e.children[t]=[n]:e.children[t].push(n)}o(Rx,`addNoneTerminalToCst`);var zx=`name`;function Bx(e,t){Object.defineProperty(e,zx,{enumerable:!1,configurable:!0,writable:!1,value:t})}o(Bx,`defineNameProp`);function Vx(e,t){let n=eu(e),r=n.length;for(let i=0;i<r;i++){let r=e[n[i]],a=r.length;for(let e=0;e<a;e++){let n=r[e];n.tokenTypeIdx===void 0&&this[n.name](n.children,t)}}}o(Vx,`defaultVisit`);function Hx(e,t){let n=o(function(){},`derivedConstructor`);return Bx(n,e+`BaseSemantics`),n.prototype={visit:o(function(e,t){if(F(e)&&(e=e[0]),!w_(e))return this[e.name](e.children,t)},`visit`),validateVisitor:o(function(){let e=Gx(this,t);if(!U(e)){let t=B(e,e=>e.msg);throw Error(`Errors Detected in CST Visitor <${this.constructor.name}>:
122
+ ${t.join(`
123
+
124
+ `).replace(/\n/g,`
125
+ `)}`)}},`validateVisitor`)},n.prototype.constructor=n,n._RULE_NAMES=t,n}o(Hx,`createBaseSemanticVisitorConstructor`);function Ux(e,t,n){let r=o(function(){},`derivedConstructor`);Bx(r,e+`BaseSemanticsWithDefaults`);let i=Object.create(n.prototype);return z(t,e=>{i[e]=Vx}),r.prototype=i,r.prototype.constructor=r,r}o(Ux,`createBaseVisitorConstructorWithDefaults`);var Wx;(function(e){e[e.REDUNDANT_METHOD=0]=`REDUNDANT_METHOD`,e[e.MISSING_METHOD=1]=`MISSING_METHOD`})(Wx||={});function Gx(e,t){return Kx(e,t)}o(Gx,`validateVisitor`);function Kx(e,t){return wm(B(Lg(t,t=>Cs(e[t])===!1),t=>({msg:`Missing visitor method: <${t}> on ${e.constructor.name} CST Visitor.`,type:Wx.MISSING_METHOD,methodName:t})))}o(Kx,`validateMissingCstMethods`);var qx=class{static{o(this,`TreeBuilder`)}initTreeBuilder(e){if(this.CST_STACK=[],this.outputCst=e.outputCst,this.nodeLocationTracking=V(e,`nodeLocationTracking`)?e.nodeLocationTracking:pS.nodeLocationTracking,!this.outputCst)this.cstInvocationStateUpdate=I,this.cstFinallyStateUpdate=I,this.cstPostTerminal=I,this.cstPostNonTerminal=I,this.cstPostRule=I;else if(/full/i.test(this.nodeLocationTracking))this.recoveryEnabled?(this.setNodeLocationFromToken=Ix,this.setNodeLocationFromNode=Ix,this.cstPostRule=I,this.setInitialNodeLocation=this.setInitialNodeLocationFullRecovery):(this.setNodeLocationFromToken=I,this.setNodeLocationFromNode=I,this.cstPostRule=this.cstPostRuleFull,this.setInitialNodeLocation=this.setInitialNodeLocationFullRegular);else if(/onlyOffset/i.test(this.nodeLocationTracking))this.recoveryEnabled?(this.setNodeLocationFromToken=Fx,this.setNodeLocationFromNode=Fx,this.cstPostRule=I,this.setInitialNodeLocation=this.setInitialNodeLocationOnlyOffsetRecovery):(this.setNodeLocationFromToken=I,this.setNodeLocationFromNode=I,this.cstPostRule=this.cstPostRuleOnlyOffset,this.setInitialNodeLocation=this.setInitialNodeLocationOnlyOffsetRegular);else if(/none/i.test(this.nodeLocationTracking))this.setNodeLocationFromToken=I,this.setNodeLocationFromNode=I,this.cstPostRule=I,this.setInitialNodeLocation=I;else throw Error(`Invalid <nodeLocationTracking> config option: "${e.nodeLocationTracking}"`)}setInitialNodeLocationOnlyOffsetRecovery(e){e.location={startOffset:NaN,endOffset:NaN}}setInitialNodeLocationOnlyOffsetRegular(e){e.location={startOffset:this.LA(1).startOffset,endOffset:NaN}}setInitialNodeLocationFullRecovery(e){e.location={startOffset:NaN,startLine:NaN,startColumn:NaN,endOffset:NaN,endLine:NaN,endColumn:NaN}}setInitialNodeLocationFullRegular(e){let t=this.LA(1);e.location={startOffset:t.startOffset,startLine:t.startLine,startColumn:t.startColumn,endOffset:NaN,endLine:NaN,endColumn:NaN}}cstInvocationStateUpdate(e){let t={name:e,children:Object.create(null)};this.setInitialNodeLocation(t),this.CST_STACK.push(t)}cstFinallyStateUpdate(){this.CST_STACK.pop()}cstPostRuleFull(e){let t=this.LA(0),n=e.location;n.startOffset<=t.startOffset?(n.endOffset=t.endOffset,n.endLine=t.endLine,n.endColumn=t.endColumn):(n.startOffset=NaN,n.startLine=NaN,n.startColumn=NaN)}cstPostRuleOnlyOffset(e){let t=this.LA(0),n=e.location;n.startOffset<=t.startOffset?n.endOffset=t.endOffset:n.startOffset=NaN}cstPostTerminal(e,t){let n=this.CST_STACK[this.CST_STACK.length-1];Lx(n,t,e),this.setNodeLocationFromToken(n.location,t)}cstPostNonTerminal(e,t){let n=this.CST_STACK[this.CST_STACK.length-1];Rx(n,t,e),this.setNodeLocationFromNode(n.location,e.location)}getBaseCstVisitorConstructor(){if(w_(this.baseCstVisitorConstructor)){let e=Hx(this.className,eu(this.gastProductionsCache));return this.baseCstVisitorConstructor=e,e}return this.baseCstVisitorConstructor}getBaseCstVisitorConstructorWithDefaults(){if(w_(this.baseCstVisitorWithDefaultsConstructor)){let e=Ux(this.className,eu(this.gastProductionsCache),this.getBaseCstVisitorConstructor());return this.baseCstVisitorWithDefaultsConstructor=e,e}return this.baseCstVisitorWithDefaultsConstructor}getLastExplicitRuleShortName(){let e=this.RULE_STACK;return e[e.length-1]}getPreviousExplicitRuleShortName(){let e=this.RULE_STACK;return e[e.length-2]}getLastExplicitRuleOccurrenceIndex(){let e=this.RULE_OCCURRENCE_STACK;return e[e.length-1]}},Jx=class{static{o(this,`LexerAdapter`)}initLexerAdapter(){this.tokVector=[],this.tokVectorLength=0,this.currIdx=-1}set input(e){if(this.selfAnalysisDone!==!0)throw Error(`Missing <performSelfAnalysis> invocation at the end of the Parser's constructor.`);this.reset(),this.tokVector=e,this.tokVectorLength=e.length}get input(){return this.tokVector}SKIP_TOKEN(){return this.currIdx<=this.tokVector.length-2?(this.consumeToken(),this.LA(1)):fS}LA(e){let t=this.currIdx+e;return t<0||this.tokVectorLength<=t?fS:this.tokVector[t]}consumeToken(){this.currIdx++}exportLexerState(){return this.currIdx}importLexerState(e){this.currIdx=e}resetLexerState(){this.currIdx=-1}moveToTerminatedState(){this.currIdx=this.tokVector.length-1}getLexerPosition(){return this.exportLexerState()}},Yx=class{static{o(this,`RecognizerApi`)}ACTION(e){return e.call(this)}consume(e,t,n){return this.consumeInternal(t,e,n)}subrule(e,t,n){return this.subruleInternal(t,e,n)}option(e,t){return this.optionInternal(t,e)}or(e,t){return this.orInternal(t,e)}many(e,t){return this.manyInternal(e,t)}atLeastOne(e,t){return this.atLeastOneInternal(e,t)}CONSUME(e,t){return this.consumeInternal(e,0,t)}CONSUME1(e,t){return this.consumeInternal(e,1,t)}CONSUME2(e,t){return this.consumeInternal(e,2,t)}CONSUME3(e,t){return this.consumeInternal(e,3,t)}CONSUME4(e,t){return this.consumeInternal(e,4,t)}CONSUME5(e,t){return this.consumeInternal(e,5,t)}CONSUME6(e,t){return this.consumeInternal(e,6,t)}CONSUME7(e,t){return this.consumeInternal(e,7,t)}CONSUME8(e,t){return this.consumeInternal(e,8,t)}CONSUME9(e,t){return this.consumeInternal(e,9,t)}SUBRULE(e,t){return this.subruleInternal(e,0,t)}SUBRULE1(e,t){return this.subruleInternal(e,1,t)}SUBRULE2(e,t){return this.subruleInternal(e,2,t)}SUBRULE3(e,t){return this.subruleInternal(e,3,t)}SUBRULE4(e,t){return this.subruleInternal(e,4,t)}SUBRULE5(e,t){return this.subruleInternal(e,5,t)}SUBRULE6(e,t){return this.subruleInternal(e,6,t)}SUBRULE7(e,t){return this.subruleInternal(e,7,t)}SUBRULE8(e,t){return this.subruleInternal(e,8,t)}SUBRULE9(e,t){return this.subruleInternal(e,9,t)}OPTION(e){return this.optionInternal(e,0)}OPTION1(e){return this.optionInternal(e,1)}OPTION2(e){return this.optionInternal(e,2)}OPTION3(e){return this.optionInternal(e,3)}OPTION4(e){return this.optionInternal(e,4)}OPTION5(e){return this.optionInternal(e,5)}OPTION6(e){return this.optionInternal(e,6)}OPTION7(e){return this.optionInternal(e,7)}OPTION8(e){return this.optionInternal(e,8)}OPTION9(e){return this.optionInternal(e,9)}OR(e){return this.orInternal(e,0)}OR1(e){return this.orInternal(e,1)}OR2(e){return this.orInternal(e,2)}OR3(e){return this.orInternal(e,3)}OR4(e){return this.orInternal(e,4)}OR5(e){return this.orInternal(e,5)}OR6(e){return this.orInternal(e,6)}OR7(e){return this.orInternal(e,7)}OR8(e){return this.orInternal(e,8)}OR9(e){return this.orInternal(e,9)}MANY(e){this.manyInternal(0,e)}MANY1(e){this.manyInternal(1,e)}MANY2(e){this.manyInternal(2,e)}MANY3(e){this.manyInternal(3,e)}MANY4(e){this.manyInternal(4,e)}MANY5(e){this.manyInternal(5,e)}MANY6(e){this.manyInternal(6,e)}MANY7(e){this.manyInternal(7,e)}MANY8(e){this.manyInternal(8,e)}MANY9(e){this.manyInternal(9,e)}MANY_SEP(e){this.manySepFirstInternal(0,e)}MANY_SEP1(e){this.manySepFirstInternal(1,e)}MANY_SEP2(e){this.manySepFirstInternal(2,e)}MANY_SEP3(e){this.manySepFirstInternal(3,e)}MANY_SEP4(e){this.manySepFirstInternal(4,e)}MANY_SEP5(e){this.manySepFirstInternal(5,e)}MANY_SEP6(e){this.manySepFirstInternal(6,e)}MANY_SEP7(e){this.manySepFirstInternal(7,e)}MANY_SEP8(e){this.manySepFirstInternal(8,e)}MANY_SEP9(e){this.manySepFirstInternal(9,e)}AT_LEAST_ONE(e){this.atLeastOneInternal(0,e)}AT_LEAST_ONE1(e){return this.atLeastOneInternal(1,e)}AT_LEAST_ONE2(e){this.atLeastOneInternal(2,e)}AT_LEAST_ONE3(e){this.atLeastOneInternal(3,e)}AT_LEAST_ONE4(e){this.atLeastOneInternal(4,e)}AT_LEAST_ONE5(e){this.atLeastOneInternal(5,e)}AT_LEAST_ONE6(e){this.atLeastOneInternal(6,e)}AT_LEAST_ONE7(e){this.atLeastOneInternal(7,e)}AT_LEAST_ONE8(e){this.atLeastOneInternal(8,e)}AT_LEAST_ONE9(e){this.atLeastOneInternal(9,e)}AT_LEAST_ONE_SEP(e){this.atLeastOneSepFirstInternal(0,e)}AT_LEAST_ONE_SEP1(e){this.atLeastOneSepFirstInternal(1,e)}AT_LEAST_ONE_SEP2(e){this.atLeastOneSepFirstInternal(2,e)}AT_LEAST_ONE_SEP3(e){this.atLeastOneSepFirstInternal(3,e)}AT_LEAST_ONE_SEP4(e){this.atLeastOneSepFirstInternal(4,e)}AT_LEAST_ONE_SEP5(e){this.atLeastOneSepFirstInternal(5,e)}AT_LEAST_ONE_SEP6(e){this.atLeastOneSepFirstInternal(6,e)}AT_LEAST_ONE_SEP7(e){this.atLeastOneSepFirstInternal(7,e)}AT_LEAST_ONE_SEP8(e){this.atLeastOneSepFirstInternal(8,e)}AT_LEAST_ONE_SEP9(e){this.atLeastOneSepFirstInternal(9,e)}RULE(e,t,n=mS){if(u_(this.definedRulesNames,e)){let t={message:cb.buildDuplicateRuleNameError({topLevelRule:e,grammarName:this.className}),type:hS.DUPLICATE_RULE_NAME,ruleName:e};this.definitionErrors.push(t)}this.definedRulesNames.push(e);let r=this.defineRule(e,t,n);return this[e]=r,r}OVERRIDE_RULE(e,t,n=mS){let r=Gb(e,this.definedRulesNames,this.className);this.definitionErrors=this.definitionErrors.concat(r);let i=this.defineRule(e,t,n);return this[e]=i,i}BACKTRACK(e,t){return function(){this.isBackTrackingStack.push(1);let n=this.saveRecogState();try{return e.apply(this,t),!0}catch(e){if(ux(e))return!1;throw e}finally{this.reloadRecogState(n),this.isBackTrackingStack.pop()}}}getGAstProductions(){return this.gastProductionsCache}getSerializedGastProductions(){return dv(H(this.gastProductionsCache))}},Xx=class{static{o(this,`RecognizerEngine`)}initRecognizerEngine(e,t){if(this.className=this.constructor.name,this.shortRuleNameToFull={},this.fullRuleNameToShort={},this.ruleShortNameIdx=256,this.tokenMatcher=Dy,this.subruleIdx=0,this.definedRulesNames=[],this.tokensMap={},this.isBackTrackingStack=[],this.RULE_STACK=[],this.RULE_OCCURRENCE_STACK=[],this.gastProductionsCache={},V(t,`serializedGrammar`))throw Error(`The Parser's configuration can no longer contain a <serializedGrammar> property.
126
+ See: https://chevrotain.io/docs/changes/BREAKING_CHANGES.html#_6-0-0
127
+ For Further details.`);if(F(e)){if(U(e))throw Error(`A Token Vocabulary cannot be empty.
128
+ Note that the first argument for the parser constructor
129
+ is no longer a Token vector (since v4.0).`);if(typeof e[0].startOffset==`number`)throw Error(`The Parser constructor no longer accepts a token vector as the first argument.
130
+ See: https://chevrotain.io/docs/changes/BREAKING_CHANGES.html#_4-0-0
131
+ For Further details.`)}if(F(e))this.tokensMap=L_(e,(e,t)=>(e[t.name]=t,e),{});else if(V(e,`modes`)&&Ng(Ld(H(e.modes)),By)){let t=Y_(Ld(H(e.modes)));this.tokensMap=L_(t,(e,t)=>(e[t.name]=t,e),{})}else if(ns(e))this.tokensMap=Sm(e);else throw Error(`<tokensDictionary> argument must be An Array of Token constructors, A dictionary of Token constructors or an IMultiModeLexerDefinition`);this.tokensMap.EOF=rb;let n=Ng(V(e,`modes`)?Ld(H(e.modes)):H(e),e=>U(e.categoryMatches));this.tokenMatcher=n?Dy:Ey,Ay(H(this.tokensMap))}defineRule(e,t,n){if(this.selfAnalysisDone)throw Error(`Grammar rule <${e}> may not be defined after the 'performSelfAnalysis' method has been called'
132
+ Make sure that all grammar rule definitions are done before 'performSelfAnalysis' is called.`);let r=V(n,`resyncEnabled`)?n.resyncEnabled:mS.resyncEnabled,i=V(n,`recoveryValueFunc`)?n.recoveryValueFunc:mS.recoveryValueFunc,a=this.ruleShortNameIdx<<xx+Sx;this.ruleShortNameIdx++,this.shortRuleNameToFull[a]=e,this.fullRuleNameToShort[e]=a;let s;return s=this.outputCst===!0?o(function(...n){try{this.ruleInvocationStateUpdate(a,e,this.subruleIdx),t.apply(this,n);let r=this.CST_STACK[this.CST_STACK.length-1];return this.cstPostRule(r),r}catch(e){return this.invokeRuleCatch(e,r,i)}finally{this.ruleFinallyStateUpdate()}},`invokeRuleWithTry`):o(function(...n){try{return this.ruleInvocationStateUpdate(a,e,this.subruleIdx),t.apply(this,n)}catch(e){return this.invokeRuleCatch(e,r,i)}finally{this.ruleFinallyStateUpdate()}},`invokeRuleWithTryCst`),Object.assign(s,{ruleName:e,originalGrammarAction:t})}invokeRuleCatch(e,t,n){let r=this.RULE_STACK.length===1,i=t&&!this.isBackTracking()&&this.recoveryEnabled;if(ux(e)){let t=e;if(i){let r=this.findReSyncTokenType();if(this.isInCurrentRuleReSyncSet(r))if(t.resyncedTokens=this.reSyncTo(r),this.outputCst){let e=this.CST_STACK[this.CST_STACK.length-1];return e.recoveredNode=!0,e}else return n(e);else{if(this.outputCst){let e=this.CST_STACK[this.CST_STACK.length-1];e.recoveredNode=!0,t.partialCstResult=e}throw t}}else if(r)return this.moveToTerminatedState(),n(e);else throw t}else throw e}optionInternal(e,t){let n=this.getKeyForAutomaticLookahead(Tx,t);return this.optionInternalLogic(e,t,n)}optionInternalLogic(e,t,n){let r=this.getLaFuncFromCache(n),i;if(typeof e!=`function`){i=e.DEF;let t=e.GATE;if(t!==void 0){let e=r;r=o(()=>t.call(this)&&e.call(this),`lookAheadFunc`)}}else i=e;if(r.call(this)===!0)return i.call(this)}atLeastOneInternal(e,t){let n=this.getKeyForAutomaticLookahead(Dx,e);return this.atLeastOneInternalLogic(e,t,n)}atLeastOneInternalLogic(e,t,n){let r=this.getLaFuncFromCache(n),i;if(typeof t!=`function`){i=t.DEF;let e=t.GATE;if(e!==void 0){let t=r;r=o(()=>e.call(this)&&t.call(this),`lookAheadFunc`)}}else i=t;if(r.call(this)===!0){let e=this.doSingleRepetition(i);for(;r.call(this)===!0&&e===!0;)e=this.doSingleRepetition(i)}else throw this.raiseEarlyExitException(e,q.REPETITION_MANDATORY,t.ERR_MSG);this.attemptInRepetitionRecovery(this.atLeastOneInternal,[e,t],r,Dx,e,gb)}atLeastOneSepFirstInternal(e,t){let n=this.getKeyForAutomaticLookahead(kx,e);this.atLeastOneSepFirstInternalLogic(e,t,n)}atLeastOneSepFirstInternalLogic(e,t,n){let r=t.DEF,i=t.SEP;if(this.getLaFuncFromCache(n).call(this)===!0){r.call(this);let t=o(()=>this.tokenMatcher(this.LA(1),i),`separatorLookAheadFunc`);for(;this.tokenMatcher(this.LA(1),i)===!0;)this.CONSUME(i),r.call(this);this.attemptInRepetitionRecovery(this.repetitionSepSecondInternal,[e,i,t,r,_b],t,kx,e,_b)}else throw this.raiseEarlyExitException(e,q.REPETITION_MANDATORY_WITH_SEPARATOR,t.ERR_MSG)}manyInternal(e,t){let n=this.getKeyForAutomaticLookahead(Ex,e);return this.manyInternalLogic(e,t,n)}manyInternalLogic(e,t,n){let r=this.getLaFuncFromCache(n),i;if(typeof t!=`function`){i=t.DEF;let e=t.GATE;if(e!==void 0){let t=r;r=o(()=>e.call(this)&&t.call(this),`lookaheadFunction`)}}else i=t;let a=!0;for(;r.call(this)===!0&&a===!0;)a=this.doSingleRepetition(i);this.attemptInRepetitionRecovery(this.manyInternal,[e,t],r,Ex,e,mb,a)}manySepFirstInternal(e,t){let n=this.getKeyForAutomaticLookahead(Ox,e);this.manySepFirstInternalLogic(e,t,n)}manySepFirstInternalLogic(e,t,n){let r=t.DEF,i=t.SEP;if(this.getLaFuncFromCache(n).call(this)===!0){r.call(this);let t=o(()=>this.tokenMatcher(this.LA(1),i),`separatorLookAheadFunc`);for(;this.tokenMatcher(this.LA(1),i)===!0;)this.CONSUME(i),r.call(this);this.attemptInRepetitionRecovery(this.repetitionSepSecondInternal,[e,i,t,r,hb],t,Ox,e,hb)}}repetitionSepSecondInternal(e,t,n,r,i){for(;n();)this.CONSUME(t),r.call(this);this.attemptInRepetitionRecovery(this.repetitionSepSecondInternal,[e,t,n,r,i],n,kx,e,i)}doSingleRepetition(e){let t=this.getLexerPosition();return e.call(this),this.getLexerPosition()>t}orInternal(e,t){let n=this.getKeyForAutomaticLookahead(wx,t),r=F(e)?e:e.DEF,i=this.getLaFuncFromCache(n).call(this,r);if(i!==void 0)return r[i].ALT.call(this);this.raiseNoAltException(t,e.ERR_MSG)}ruleFinallyStateUpdate(){if(this.RULE_STACK.pop(),this.RULE_OCCURRENCE_STACK.pop(),this.cstFinallyStateUpdate(),this.RULE_STACK.length===0&&this.isAtEndOfInput()===!1){let e=this.LA(1),t=this.errorMessageProvider.buildNotAllInputParsedMessage({firstRedundant:e,ruleName:this.getCurrRuleFullName()});this.SAVE_ERROR(new mx(t,e))}}subruleInternal(e,t,n){let r;try{let i=n===void 0?void 0:n.ARGS;return this.subruleIdx=t,r=e.apply(this,i),this.cstPostNonTerminal(r,n!==void 0&&n.LABEL!==void 0?n.LABEL:e.ruleName),r}catch(t){throw this.subruleInternalError(t,n,e.ruleName)}}subruleInternalError(e,t,n){throw ux(e)&&e.partialCstResult!==void 0&&(this.cstPostNonTerminal(e.partialCstResult,t!==void 0&&t.LABEL!==void 0?t.LABEL:n),delete e.partialCstResult),e}consumeInternal(e,t,n){let r;try{let t=this.LA(1);this.tokenMatcher(t,e)===!0?(this.consumeToken(),r=t):this.consumeInternalError(e,t,n)}catch(n){r=this.consumeInternalRecovery(e,t,n)}return this.cstPostTerminal(n!==void 0&&n.LABEL!==void 0?n.LABEL:e.name,r),r}consumeInternalError(e,t,n){let r,i=this.LA(0);throw r=n!==void 0&&n.ERR_MSG?n.ERR_MSG:this.errorMessageProvider.buildMismatchTokenMessage({expected:e,actual:t,previous:i,ruleName:this.getCurrRuleFullName()}),this.SAVE_ERROR(new fx(r,t,i))}consumeInternalRecovery(e,t,n){if(this.recoveryEnabled&&n.name===`MismatchedTokenException`&&!this.isBackTracking()){let r=this.getFollowsForInRuleRecovery(e,t);try{return this.tryInRuleRecovery(e,r)}catch(e){throw e.name===_x?n:e}}else throw n}saveRecogState(){let e=this.errors,t=Sm(this.RULE_STACK);return{errors:e,lexerState:this.exportLexerState(),RULE_STACK:t,CST_STACK:this.CST_STACK}}reloadRecogState(e){this.errors=e.errors,this.importLexerState(e.lexerState),this.RULE_STACK=e.RULE_STACK}ruleInvocationStateUpdate(e,t,n){this.RULE_OCCURRENCE_STACK.push(n),this.RULE_STACK.push(e),this.cstInvocationStateUpdate(t)}isBackTracking(){return this.isBackTrackingStack.length!==0}getCurrRuleFullName(){let e=this.getLastExplicitRuleShortName();return this.shortRuleNameToFull[e]}shortRuleNameToFullName(e){return this.shortRuleNameToFull[e]}isAtEndOfInput(){return this.tokenMatcher(this.LA(1),rb)}reset(){this.resetLexerState(),this.subruleIdx=0,this.isBackTrackingStack=[],this.errors=[],this.RULE_STACK=[],this.CST_STACK=[],this.RULE_OCCURRENCE_STACK=[]}},Zx=class{static{o(this,`ErrorHandler`)}initErrorHandler(e){this._errors=[],this.errorMessageProvider=V(e,`errorMessageProvider`)?e.errorMessageProvider:pS.errorMessageProvider}SAVE_ERROR(e){if(ux(e))return e.context={ruleStack:this.getHumanReadableRuleStack(),ruleOccurrenceStack:Sm(this.RULE_OCCURRENCE_STACK)},this._errors.push(e),e;throw Error(`Trying to save an Error which is not a RecognitionException`)}get errors(){return Sm(this._errors)}set errors(e){this._errors=e}raiseEarlyExitException(e,t,n){let r=this.getCurrRuleFullName(),i=this.getGAstProductions()[r],a=Pb(e,i,t,this.maxLookahead)[0],o=[];for(let e=1;e<=this.maxLookahead;e++)o.push(this.LA(e));let s=this.errorMessageProvider.buildEarlyExitMessage({expectedIterationPaths:a,actual:o,previous:this.LA(0),customUserDescription:n,ruleName:r});throw this.SAVE_ERROR(new hx(s,this.LA(1),this.LA(0)))}raiseNoAltException(e,t){let n=this.getCurrRuleFullName(),r=this.getGAstProductions()[n],i=Nb(e,r,this.maxLookahead),a=[];for(let e=1;e<=this.maxLookahead;e++)a.push(this.LA(e));let o=this.LA(0),s=this.errorMessageProvider.buildNoViableAltMessage({expectedPathsPerAlt:i,actual:a,previous:o,customUserDescription:t,ruleName:this.getCurrRuleFullName()});throw this.SAVE_ERROR(new px(s,this.LA(1),o))}},Qx=class{static{o(this,`ContentAssist`)}initContentAssist(){}computeContentAssist(e,t){let n=this.gastProductionsCache[e];if(w_(n))throw Error(`Rule ->${e}<- does not exist in this grammar.`);return yb([n],t,this.tokenMatcher,this.maxLookahead)}getNextPossibleTokenTypes(e){let t=Wg(e.ruleStack),n=this.getGAstProductions()[t];return new fb(n,e).startWalking()}},$x={description:`This Object indicates the Parser is during Recording Phase`};Object.freeze($x);var eS=!0,tS=2**Sx-1,nS=tb({name:`RECORDING_PHASE_TOKEN`,pattern:Uy.NA});Ay([nS]);var rS=ib(nS,`This IToken indicates the Parser is in Recording Phase
133
+ See: https://chevrotain.io/docs/guide/internals.html#grammar-recording for details`,-1,-1,-1,-1,-1,-1);Object.freeze(rS);var iS={name:`This CSTNode indicates the Parser is in Recording Phase
134
+ See: https://chevrotain.io/docs/guide/internals.html#grammar-recording for details`,children:{}},aS=class{static{o(this,`GastRecorder`)}initGastRecorder(e){this.recordingProdStack=[],this.RECORDING_PHASE=!1}enableRecording(){this.RECORDING_PHASE=!0,this.TRACE_INIT(`Enable Recording`,()=>{for(let e=0;e<10;e++){let t=e>0?e:``;this[`CONSUME${t}`]=function(t,n){return this.consumeInternalRecord(t,e,n)},this[`SUBRULE${t}`]=function(t,n){return this.subruleInternalRecord(t,e,n)},this[`OPTION${t}`]=function(t){return this.optionInternalRecord(t,e)},this[`OR${t}`]=function(t){return this.orInternalRecord(t,e)},this[`MANY${t}`]=function(t){this.manyInternalRecord(e,t)},this[`MANY_SEP${t}`]=function(t){this.manySepFirstInternalRecord(e,t)},this[`AT_LEAST_ONE${t}`]=function(t){this.atLeastOneInternalRecord(e,t)},this[`AT_LEAST_ONE_SEP${t}`]=function(t){this.atLeastOneSepFirstInternalRecord(e,t)}}this.consume=function(e,t,n){return this.consumeInternalRecord(t,e,n)},this.subrule=function(e,t,n){return this.subruleInternalRecord(t,e,n)},this.option=function(e,t){return this.optionInternalRecord(t,e)},this.or=function(e,t){return this.orInternalRecord(t,e)},this.many=function(e,t){this.manyInternalRecord(e,t)},this.atLeastOne=function(e,t){this.atLeastOneInternalRecord(e,t)},this.ACTION=this.ACTION_RECORD,this.BACKTRACK=this.BACKTRACK_RECORD,this.LA=this.LA_RECORD})}disableRecording(){this.RECORDING_PHASE=!1,this.TRACE_INIT(`Deleting Recording methods`,()=>{let e=this;for(let t=0;t<10;t++){let n=t>0?t:``;delete e[`CONSUME${n}`],delete e[`SUBRULE${n}`],delete e[`OPTION${n}`],delete e[`OR${n}`],delete e[`MANY${n}`],delete e[`MANY_SEP${n}`],delete e[`AT_LEAST_ONE${n}`],delete e[`AT_LEAST_ONE_SEP${n}`]}delete e.consume,delete e.subrule,delete e.option,delete e.or,delete e.many,delete e.atLeastOne,delete e.ACTION,delete e.BACKTRACK,delete e.LA})}ACTION_RECORD(e){}BACKTRACK_RECORD(e,t){return()=>!0}LA_RECORD(e){return fS}topLevelRuleRecord(e,t){try{let n=new iv({definition:[],name:e});return n.name=e,this.recordingProdStack.push(n),t.call(this),this.recordingProdStack.pop(),n}catch(e){if(e.KNOWN_RECORDER_ERROR!==!0)try{e.message+=`
135
+ This error was thrown during the "grammar recording phase" For more info see:
136
+ https://chevrotain.io/docs/guide/internals.html#grammar-recording`}catch{throw e}throw e}}optionInternalRecord(e,t){return oS.call(this,ov,e,t)}atLeastOneInternalRecord(e,t){oS.call(this,sv,t,e)}atLeastOneSepFirstInternalRecord(e,t){oS.call(this,cv,t,e,eS)}manyInternalRecord(e,t){oS.call(this,W,t,e)}manySepFirstInternalRecord(e,t){oS.call(this,lv,t,e,eS)}orInternalRecord(e,t){return sS.call(this,e,t)}subruleInternalRecord(e,t,n){if(lS(t),!e||V(e,`ruleName`)===!1){let n=Error(`<SUBRULE${cS(t)}> argument is invalid expecting a Parser method reference but got: <${JSON.stringify(e)}>
137
+ inside top level rule: <${this.recordingProdStack[0].name}>`);throw n.KNOWN_RECORDER_ERROR=!0,n}let r=bg(this.recordingProdStack),i=e.ruleName,a=new rv({idx:t,nonTerminalName:i,label:n?.LABEL,referencedRule:void 0});return r.definition.push(a),this.outputCst?iS:$x}consumeInternalRecord(e,t,n){if(lS(t),!Iy(e)){let n=Error(`<CONSUME${cS(t)}> argument is invalid expecting a TokenType reference but got: <${JSON.stringify(e)}>
138
+ inside top level rule: <${this.recordingProdStack[0].name}>`);throw n.KNOWN_RECORDER_ERROR=!0,n}let r=bg(this.recordingProdStack),i=new G({idx:t,terminalType:e,label:n?.LABEL});return r.definition.push(i),rS}};function oS(e,t,n,r=!1){lS(n);let i=bg(this.recordingProdStack),a=Cs(t)?t:t.DEF,o=new e({definition:[],idx:n});return r&&(o.separator=t.SEP),V(t,`MAX_LOOKAHEAD`)&&(o.maxLookahead=t.MAX_LOOKAHEAD),this.recordingProdStack.push(o),a.call(this),i.definition.push(o),this.recordingProdStack.pop(),$x}o(oS,`recordProd`);function sS(e,t){lS(t);let n=bg(this.recordingProdStack),r=F(e)===!1,i=r===!1?e:e.DEF,a=new uv({definition:[],idx:t,ignoreAmbiguities:r&&e.IGNORE_AMBIGUITIES===!0});return V(e,`MAX_LOOKAHEAD`)&&(a.maxLookahead=e.MAX_LOOKAHEAD),a.hasPredicates=U_(i,e=>Cs(e.GATE)),n.definition.push(a),z(i,e=>{let t=new av({definition:[]});a.definition.push(t),V(e,`IGNORE_AMBIGUITIES`)?t.ignoreAmbiguities=e.IGNORE_AMBIGUITIES:V(e,`GATE`)&&(t.ignoreAmbiguities=!0),this.recordingProdStack.push(t),e.ALT.call(this),this.recordingProdStack.pop()}),$x}o(sS,`recordOrProd`);function cS(e){return e===0?``:`${e}`}o(cS,`getIdxSuffix`);function lS(e){if(e<0||e>tS){let t=Error(`Invalid DSL Method idx value: <${e}>
139
+ Idx value must be a none negative value smaller than ${tS+1}`);throw t.KNOWN_RECORDER_ERROR=!0,t}}o(lS,`assertMethodIdxIsValid`);var uS=class{static{o(this,`PerformanceTracer`)}initPerformanceTracer(e){if(V(e,`traceInitPerf`)){let t=e.traceInitPerf,n=typeof t==`number`;this.traceInitMaxIdent=n?t:1/0,this.traceInitPerf=n?t>0:t}else this.traceInitMaxIdent=0,this.traceInitPerf=pS.traceInitPerf;this.traceInitIndent=-1}TRACE_INIT(e,t){if(this.traceInitPerf===!0){this.traceInitIndent++;let n=Array(this.traceInitIndent+1).join(` `);this.traceInitIndent<this.traceInitMaxIdent&&console.log(`${n}--> <${e}>`);let{time:r,value:i}=Q_(t),a=r>10?console.warn:console.log;return this.traceInitIndent<this.traceInitMaxIdent&&a(`${n}<-- <${e}> time: ${r}ms`),this.traceInitIndent--,i}else return t()}};function dS(e,t){t.forEach(t=>{let n=t.prototype;Object.getOwnPropertyNames(n).forEach(r=>{if(r===`constructor`)return;let i=Object.getOwnPropertyDescriptor(n,r);i&&(i.get||i.set)?Object.defineProperty(e.prototype,r,i):e.prototype[r]=t.prototype[r]})})}o(dS,`applyMixins`);var fS=ib(rb,``,NaN,NaN,NaN,NaN,NaN,NaN);Object.freeze(fS);var pS=Object.freeze({recoveryEnabled:!1,maxLookahead:3,dynamicTokensEnabled:!1,outputCst:!0,errorMessageProvider:ob,nodeLocationTracking:`none`,traceInitPerf:!1,skipValidations:!1}),mS=Object.freeze({recoveryValueFunc:o(()=>void 0,`recoveryValueFunc`),resyncEnabled:!0}),hS;(function(e){e[e.INVALID_RULE_NAME=0]=`INVALID_RULE_NAME`,e[e.DUPLICATE_RULE_NAME=1]=`DUPLICATE_RULE_NAME`,e[e.INVALID_RULE_OVERRIDE=2]=`INVALID_RULE_OVERRIDE`,e[e.DUPLICATE_PRODUCTIONS=3]=`DUPLICATE_PRODUCTIONS`,e[e.UNRESOLVED_SUBRULE_REF=4]=`UNRESOLVED_SUBRULE_REF`,e[e.LEFT_RECURSION=5]=`LEFT_RECURSION`,e[e.NONE_LAST_EMPTY_ALT=6]=`NONE_LAST_EMPTY_ALT`,e[e.AMBIGUOUS_ALTS=7]=`AMBIGUOUS_ALTS`,e[e.CONFLICT_TOKENS_RULES_NAMESPACE=8]=`CONFLICT_TOKENS_RULES_NAMESPACE`,e[e.INVALID_TOKEN_NAME=9]=`INVALID_TOKEN_NAME`,e[e.NO_NON_EMPTY_LOOKAHEAD=10]=`NO_NON_EMPTY_LOOKAHEAD`,e[e.AMBIGUOUS_PREFIX_ALTS=11]=`AMBIGUOUS_PREFIX_ALTS`,e[e.TOO_MANY_ALTS=12]=`TOO_MANY_ALTS`,e[e.CUSTOM_LOOKAHEAD_VALIDATION=13]=`CUSTOM_LOOKAHEAD_VALIDATION`})(hS||={});function gS(e=void 0){return function(){return e}}o(gS,`EMPTY_ALT`);var _S=class e{static{o(this,`Parser`)}static performSelfAnalysis(e){throw Error("The **static** `performSelfAnalysis` method has been deprecated. \nUse the **instance** method with the same name instead.")}performSelfAnalysis(){this.TRACE_INIT(`performSelfAnalysis`,()=>{let t;this.selfAnalysisDone=!0;let n=this.className;this.TRACE_INIT(`toFastProps`,()=>{$_(this)}),this.TRACE_INIT(`Grammar Recording`,()=>{try{this.enableRecording(),z(this.definedRulesNames,e=>{let t=this[e].originalGrammarAction,n;this.TRACE_INIT(`${e} Rule`,()=>{n=this.topLevelRuleRecord(e,t)}),this.gastProductionsCache[e]=n})}finally{this.disableRecording()}});let r=[];if(this.TRACE_INIT(`Grammar Resolving`,()=>{r=rx({rules:H(this.gastProductionsCache)}),this.definitionErrors=this.definitionErrors.concat(r)}),this.TRACE_INIT(`Grammar Validations`,()=>{if(U(r)&&this.skipValidations===!1){let e=ix({rules:H(this.gastProductionsCache),tokenTypes:H(this.tokensMap),errMsgProvider:cb,grammarName:n}),t=Rb({lookaheadStrategy:this.lookaheadStrategy,rules:H(this.gastProductionsCache),tokenTypes:H(this.tokensMap),grammarName:n});this.definitionErrors=this.definitionErrors.concat(e,t)}}),U(this.definitionErrors)&&(this.recoveryEnabled&&this.TRACE_INIT(`computeAllProdsFollows`,()=>{let e=Ev(H(this.gastProductionsCache));this.resyncFollows=e}),this.TRACE_INIT(`ComputeLookaheadFunctions`,()=>{var e,t;(t=(e=this.lookaheadStrategy).initialize)==null||t.call(e,{rules:H(this.gastProductionsCache)}),this.preComputeLookaheadFunctions(H(this.gastProductionsCache))})),!e.DEFER_DEFINITION_ERRORS_HANDLING&&!U(this.definitionErrors))throw t=B(this.definitionErrors,e=>e.message),Error(`Parser Definition Errors detected:
140
+ ${t.join(`
141
+ -------------------------------
142
+ `)}`)})}constructor(e,t){this.definitionErrors=[],this.selfAnalysisDone=!1;let n=this;if(n.initErrorHandler(t),n.initLexerAdapter(),n.initLooksAhead(t),n.initRecognizerEngine(e,t),n.initRecoverable(t),n.initTreeBuilder(t),n.initContentAssist(),n.initGastRecorder(t),n.initPerformanceTracer(t),V(t,`ignoredIssues`))throw Error(`The <ignoredIssues> IParserConfig property has been deprecated.
143
+ Please use the <IGNORE_AMBIGUITIES> flag on the relevant DSL method instead.
144
+ See: https://chevrotain.io/docs/guide/resolving_grammar_errors.html#IGNORING_AMBIGUITIES
145
+ For further details.`);this.skipValidations=V(t,`skipValidations`)?t.skipValidations:pS.skipValidations}};_S.DEFER_DEFINITION_ERRORS_HANDLING=!1,dS(_S,[yx,Mx,qx,Jx,Xx,Yx,Zx,Qx,aS,uS]);var vS=class extends _S{static{o(this,`EmbeddedActionsParser`)}constructor(e,t=pS){let n=Sm(t);n.outputCst=!1,super(e,n)}};function yS(e,t){for(var n=-1,r=e==null?0:e.length,i=Array(r);++n<r;)i[n]=t(e[n],n,e);return i}o(yS,`arrayMap`);var bS=yS;function xS(){this.__data__=[],this.size=0}o(xS,`listCacheClear`);var SS=xS;function CS(e,t){return e===t||e!==e&&t!==t}o(CS,`eq`);var wS=CS;function TS(e,t){for(var n=e.length;n--;)if(wS(e[n][0],t))return n;return-1}o(TS,`assocIndexOf`);var ES=TS,DS=Array.prototype.splice;function OS(e){var t=this.__data__,n=ES(t,e);return n<0?!1:(n==t.length-1?t.pop():DS.call(t,n,1),--this.size,!0)}o(OS,`listCacheDelete`);var kS=OS;function AS(e){var t=this.__data__,n=ES(t,e);return n<0?void 0:t[n][1]}o(AS,`listCacheGet`);var jS=AS;function MS(e){return ES(this.__data__,e)>-1}o(MS,`listCacheHas`);var NS=MS;function PS(e,t){var n=this.__data__,r=ES(n,e);return r<0?(++this.size,n.push([e,t])):n[r][1]=t,this}o(PS,`listCacheSet`);var FS=PS;function IS(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}o(IS,`ListCache`),IS.prototype.clear=SS,IS.prototype.delete=kS,IS.prototype.get=jS,IS.prototype.has=NS,IS.prototype.set=FS;var LS=IS;function RS(){this.__data__=new LS,this.size=0}o(RS,`stackClear`);var zS=RS;function BS(e){var t=this.__data__,n=t.delete(e);return this.size=t.size,n}o(BS,`stackDelete`);var VS=BS;function HS(e){return this.__data__.get(e)}o(HS,`stackGet`);var US=HS;function WS(e){return this.__data__.has(e)}o(WS,`stackHas`);var GS=WS,KS=typeof global==`object`&&global&&global.Object===Object&&global,qS=typeof self==`object`&&self&&self.Object===Object&&self,JS=KS||qS||Function(`return this`)(),YS=JS.Symbol,XS=Object.prototype,ZS=XS.hasOwnProperty,QS=XS.toString,$S=YS?YS.toStringTag:void 0;function eC(e){var t=ZS.call(e,$S),n=e[$S];try{e[$S]=void 0;var r=!0}catch{}var i=QS.call(e);return r&&(t?e[$S]=n:delete e[$S]),i}o(eC,`getRawTag`);var tC=eC,nC=Object.prototype.toString;function rC(e){return nC.call(e)}o(rC,`objectToString`);var iC=rC,aC=`[object Null]`,oC=`[object Undefined]`,sC=YS?YS.toStringTag:void 0;function cC(e){return e==null?e===void 0?oC:aC:sC&&sC in Object(e)?tC(e):iC(e)}o(cC,`baseGetTag`);var lC=cC;function uC(e){var t=typeof e;return e!=null&&(t==`object`||t==`function`)}o(uC,`isObject`);var dC=uC,fC=`[object AsyncFunction]`,pC=`[object Function]`,mC=`[object GeneratorFunction]`,hC=`[object Proxy]`;function gC(e){if(!dC(e))return!1;var t=lC(e);return t==pC||t==mC||t==fC||t==hC}o(gC,`isFunction`);var _C=gC,vC=JS[`__core-js_shared__`],yC=(function(){var e=/[^.]+$/.exec(vC&&vC.keys&&vC.keys.IE_PROTO||``);return e?`Symbol(src)_1.`+e:``})();function bC(e){return!!yC&&yC in e}o(bC,`isMasked`);var xC=bC,SC=Function.prototype.toString;function CC(e){if(e!=null){try{return SC.call(e)}catch{}try{return e+``}catch{}}return``}o(CC,`toSource`);var wC=CC,TC=/[\\^$.*+?()[\]{}|]/g,EC=/^\[object .+?Constructor\]$/,DC=Function.prototype,OC=Object.prototype,kC=DC.toString,AC=OC.hasOwnProperty,jC=RegExp(`^`+kC.call(AC).replace(TC,`\\$&`).replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,`$1.*?`)+`$`);function MC(e){return!dC(e)||xC(e)?!1:(_C(e)?jC:EC).test(wC(e))}o(MC,`baseIsNative`);var NC=MC;function PC(e,t){return e?.[t]}o(PC,`getValue`);var FC=PC;function IC(e,t){var n=FC(e,t);return NC(n)?n:void 0}o(IC,`getNative`);var LC=IC,RC=LC(JS,`Map`),zC=LC(Object,`create`);function BC(){this.__data__=zC?zC(null):{},this.size=0}o(BC,`hashClear`);var VC=BC;function HC(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=+!!t,t}o(HC,`hashDelete`);var UC=HC,WC=`__lodash_hash_undefined__`,GC=Object.prototype.hasOwnProperty;function KC(e){var t=this.__data__;if(zC){var n=t[e];return n===WC?void 0:n}return GC.call(t,e)?t[e]:void 0}o(KC,`hashGet`);var qC=KC,JC=Object.prototype.hasOwnProperty;function YC(e){var t=this.__data__;return zC?t[e]!==void 0:JC.call(t,e)}o(YC,`hashHas`);var XC=YC,ZC=`__lodash_hash_undefined__`;function QC(e,t){var n=this.__data__;return this.size+=+!this.has(e),n[e]=zC&&t===void 0?ZC:t,this}o(QC,`hashSet`);var $C=QC;function ew(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}o(ew,`Hash`),ew.prototype.clear=VC,ew.prototype.delete=UC,ew.prototype.get=qC,ew.prototype.has=XC,ew.prototype.set=$C;var tw=ew;function nw(){this.size=0,this.__data__={hash:new tw,map:new(RC||LS),string:new tw}}o(nw,`mapCacheClear`);var rw=nw;function iw(e){var t=typeof e;return t==`string`||t==`number`||t==`symbol`||t==`boolean`?e!==`__proto__`:e===null}o(iw,`isKeyable`);var aw=iw;function ow(e,t){var n=e.__data__;return aw(t)?n[typeof t==`string`?`string`:`hash`]:n.map}o(ow,`getMapData`);var sw=ow;function cw(e){var t=sw(this,e).delete(e);return this.size-=+!!t,t}o(cw,`mapCacheDelete`);var lw=cw;function uw(e){return sw(this,e).get(e)}o(uw,`mapCacheGet`);var dw=uw;function fw(e){return sw(this,e).has(e)}o(fw,`mapCacheHas`);var pw=fw;function mw(e,t){var n=sw(this,e),r=n.size;return n.set(e,t),this.size+=n.size==r?0:1,this}o(mw,`mapCacheSet`);var hw=mw;function gw(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}o(gw,`MapCache`),gw.prototype.clear=rw,gw.prototype.delete=lw,gw.prototype.get=dw,gw.prototype.has=pw,gw.prototype.set=hw;var _w=gw,vw=200;function yw(e,t){var n=this.__data__;if(n instanceof LS){var r=n.__data__;if(!RC||r.length<vw-1)return r.push([e,t]),this.size=++n.size,this;n=this.__data__=new _w(r)}return n.set(e,t),this.size=n.size,this}o(yw,`stackSet`);var bw=yw;function xw(e){var t=this.__data__=new LS(e);this.size=t.size}o(xw,`Stack`),xw.prototype.clear=zS,xw.prototype.delete=VS,xw.prototype.get=US,xw.prototype.has=GS,xw.prototype.set=bw;var Sw=xw,Cw=`__lodash_hash_undefined__`;function ww(e){return this.__data__.set(e,Cw),this}o(ww,`setCacheAdd`);var Tw=ww;function Ew(e){return this.__data__.has(e)}o(Ew,`setCacheHas`);var Dw=Ew;function Ow(e){var t=-1,n=e==null?0:e.length;for(this.__data__=new _w;++t<n;)this.add(e[t])}o(Ow,`SetCache`),Ow.prototype.add=Ow.prototype.push=Tw,Ow.prototype.has=Dw;var kw=Ow;function Aw(e,t){for(var n=-1,r=e==null?0:e.length;++n<r;)if(t(e[n],n,e))return!0;return!1}o(Aw,`arraySome`);var jw=Aw;function Mw(e,t){return e.has(t)}o(Mw,`cacheHas`);var Nw=Mw,Pw=1,Fw=2;function Iw(e,t,n,r,i,a){var o=n&Pw,s=e.length,c=t.length;if(s!=c&&!(o&&c>s))return!1;var l=a.get(e),u=a.get(t);if(l&&u)return l==t&&u==e;var d=-1,f=!0,p=n&Fw?new kw:void 0;for(a.set(e,t),a.set(t,e);++d<s;){var m=e[d],h=t[d];if(r)var g=o?r(h,m,d,t,e,a):r(m,h,d,e,t,a);if(g!==void 0){if(g)continue;f=!1;break}if(p){if(!jw(t,function(e,t){if(!Nw(p,t)&&(m===e||i(m,e,n,r,a)))return p.push(t)})){f=!1;break}}else if(!(m===h||i(m,h,n,r,a))){f=!1;break}}return a.delete(e),a.delete(t),f}o(Iw,`equalArrays`);var Lw=Iw,Rw=JS.Uint8Array;function zw(e){var t=-1,n=Array(e.size);return e.forEach(function(e,r){n[++t]=[r,e]}),n}o(zw,`mapToArray`);var Bw=zw;function Vw(e){var t=-1,n=Array(e.size);return e.forEach(function(e){n[++t]=e}),n}o(Vw,`setToArray`);var Hw=Vw,Uw=1,Ww=2,Gw=`[object Boolean]`,Kw=`[object Date]`,qw=`[object Error]`,Jw=`[object Map]`,Yw=`[object Number]`,Xw=`[object RegExp]`,Zw=`[object Set]`,Qw=`[object String]`,$w=`[object Symbol]`,eT=`[object ArrayBuffer]`,tT=`[object DataView]`,nT=YS?YS.prototype:void 0,rT=nT?nT.valueOf:void 0;function iT(e,t,n,r,i,a,o){switch(n){case tT:if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case eT:return!(e.byteLength!=t.byteLength||!a(new Rw(e),new Rw(t)));case Gw:case Kw:case Yw:return wS(+e,+t);case qw:return e.name==t.name&&e.message==t.message;case Xw:case Qw:return e==t+``;case Jw:var s=Bw;case Zw:var c=r&Uw;if(s||=Hw,e.size!=t.size&&!c)return!1;var l=o.get(e);if(l)return l==t;r|=Ww,o.set(e,t);var u=Lw(s(e),s(t),r,i,a,o);return o.delete(e),u;case $w:if(rT)return rT.call(e)==rT.call(t)}return!1}o(iT,`equalByTag`);var aT=iT;function oT(e,t){for(var n=-1,r=t.length,i=e.length;++n<r;)e[i+n]=t[n];return e}o(oT,`arrayPush`);var sT=oT,cT=Array.isArray;function lT(e,t,n){var r=t(e);return cT(e)?r:sT(r,n(e))}o(lT,`baseGetAllKeys`);var uT=lT;function dT(e,t){for(var n=-1,r=e==null?0:e.length,i=0,a=[];++n<r;){var o=e[n];t(o,n,e)&&(a[i++]=o)}return a}o(dT,`arrayFilter`);var fT=dT;function pT(){return[]}o(pT,`stubArray`);var mT=pT,hT=Object.prototype.propertyIsEnumerable,gT=Object.getOwnPropertySymbols,_T=gT?function(e){return e==null?[]:(e=Object(e),fT(gT(e),function(t){return hT.call(e,t)}))}:mT;function vT(e,t){for(var n=-1,r=Array(e);++n<e;)r[n]=t(n);return r}o(vT,`baseTimes`);var yT=vT;function bT(e){return typeof e==`object`&&!!e}o(bT,`isObjectLike`);var xT=bT,ST=`[object Arguments]`;function CT(e){return xT(e)&&lC(e)==ST}o(CT,`baseIsArguments`);var wT=CT,TT=Object.prototype,ET=TT.hasOwnProperty,DT=TT.propertyIsEnumerable,OT=wT((function(){return arguments})())?wT:function(e){return xT(e)&&ET.call(e,`callee`)&&!DT.call(e,`callee`)};function kT(){return!1}o(kT,`stubFalse`);var AT=kT,jT=typeof exports==`object`&&exports&&!exports.nodeType&&exports,MT=jT&&typeof module==`object`&&module&&!module.nodeType&&module,NT=MT&&MT.exports===jT?JS.Buffer:void 0,PT=(NT?NT.isBuffer:void 0)||AT,FT=9007199254740991,IT=/^(?:0|[1-9]\d*)$/;function LT(e,t){var n=typeof e;return t??=FT,!!t&&(n==`number`||n!=`symbol`&&IT.test(e))&&e>-1&&e%1==0&&e<t}o(LT,`isIndex`);var RT=LT,zT=9007199254740991;function BT(e){return typeof e==`number`&&e>-1&&e%1==0&&e<=zT}o(BT,`isLength`);var VT=BT,HT=`[object Arguments]`,UT=`[object Array]`,WT=`[object Boolean]`,GT=`[object Date]`,KT=`[object Error]`,qT=`[object Function]`,JT=`[object Map]`,YT=`[object Number]`,XT=`[object Object]`,ZT=`[object RegExp]`,QT=`[object Set]`,$T=`[object String]`,eE=`[object WeakMap]`,tE=`[object ArrayBuffer]`,nE=`[object DataView]`,rE=`[object Float32Array]`,iE=`[object Float64Array]`,aE=`[object Int8Array]`,oE=`[object Int16Array]`,sE=`[object Int32Array]`,cE=`[object Uint8Array]`,lE=`[object Uint8ClampedArray]`,uE=`[object Uint16Array]`,dE=`[object Uint32Array]`,J={};J[rE]=J[iE]=J[aE]=J[oE]=J[sE]=J[cE]=J[lE]=J[uE]=J[dE]=!0,J[HT]=J[UT]=J[tE]=J[WT]=J[nE]=J[GT]=J[KT]=J[qT]=J[JT]=J[YT]=J[XT]=J[ZT]=J[QT]=J[$T]=J[eE]=!1;function fE(e){return xT(e)&&VT(e.length)&&!!J[lC(e)]}o(fE,`baseIsTypedArray`);var pE=fE;function mE(e){return function(t){return e(t)}}o(mE,`baseUnary`);var hE=mE,gE=typeof exports==`object`&&exports&&!exports.nodeType&&exports,_E=gE&&typeof module==`object`&&module&&!module.nodeType&&module,vE=_E&&_E.exports===gE&&KS.process,yE=(function(){try{return _E&&_E.require&&_E.require(`util`).types||vE&&vE.binding&&vE.binding(`util`)}catch{}})(),bE=yE&&yE.isTypedArray,xE=bE?hE(bE):pE,SE=Object.prototype.hasOwnProperty;function CE(e,t){var n=cT(e),r=!n&&OT(e),i=!n&&!r&&PT(e),a=!n&&!r&&!i&&xE(e),o=n||r||i||a,s=o?yT(e.length,String):[],c=s.length;for(var l in e)(t||SE.call(e,l))&&!(o&&(l==`length`||i&&(l==`offset`||l==`parent`)||a&&(l==`buffer`||l==`byteLength`||l==`byteOffset`)||RT(l,c)))&&s.push(l);return s}o(CE,`arrayLikeKeys`);var wE=CE,TE=Object.prototype;function EE(e){var t=e&&e.constructor;return e===(typeof t==`function`&&t.prototype||TE)}o(EE,`isPrototype`);var DE=EE;function OE(e,t){return function(n){return e(t(n))}}o(OE,`overArg`);var kE=OE(Object.keys,Object),AE=Object.prototype.hasOwnProperty;function jE(e){if(!DE(e))return kE(e);var t=[];for(var n in Object(e))AE.call(e,n)&&n!=`constructor`&&t.push(n);return t}o(jE,`baseKeys`);var ME=jE;function NE(e){return e!=null&&VT(e.length)&&!_C(e)}o(NE,`isArrayLike`);var PE=NE;function FE(e){return PE(e)?wE(e):ME(e)}o(FE,`keys`);var IE=FE;function LE(e){return uT(e,IE,_T)}o(LE,`getAllKeys`);var RE=LE,zE=1,BE=Object.prototype.hasOwnProperty;function VE(e,t,n,r,i,a){var o=n&zE,s=RE(e),c=s.length;if(c!=RE(t).length&&!o)return!1;for(var l=c;l--;){var u=s[l];if(!(o?u in t:BE.call(t,u)))return!1}var d=a.get(e),f=a.get(t);if(d&&f)return d==t&&f==e;var p=!0;a.set(e,t),a.set(t,e);for(var m=o;++l<c;){u=s[l];var h=e[u],g=t[u];if(r)var _=o?r(g,h,u,t,e,a):r(h,g,u,e,t,a);if(!(_===void 0?h===g||i(h,g,n,r,a):_)){p=!1;break}m||=u==`constructor`}if(p&&!m){var v=e.constructor,y=t.constructor;v!=y&&`constructor`in e&&`constructor`in t&&!(typeof v==`function`&&v instanceof v&&typeof y==`function`&&y instanceof y)&&(p=!1)}return a.delete(e),a.delete(t),p}o(VE,`equalObjects`);var HE=VE,UE=LC(JS,`DataView`),WE=LC(JS,`Promise`),GE=LC(JS,`Set`),KE=LC(JS,`WeakMap`),qE=`[object Map]`,JE=`[object Object]`,YE=`[object Promise]`,XE=`[object Set]`,ZE=`[object WeakMap]`,QE=`[object DataView]`,$E=wC(UE),eD=wC(RC),tD=wC(WE),nD=wC(GE),rD=wC(KE),iD=lC;(UE&&iD(new UE(new ArrayBuffer(1)))!=QE||RC&&iD(new RC)!=qE||WE&&iD(WE.resolve())!=YE||GE&&iD(new GE)!=XE||KE&&iD(new KE)!=ZE)&&(iD=o(function(e){var t=lC(e),n=t==JE?e.constructor:void 0,r=n?wC(n):``;if(r)switch(r){case $E:return QE;case eD:return qE;case tD:return YE;case nD:return XE;case rD:return ZE}return t},`getTag`));var aD=iD,oD=1,sD=`[object Arguments]`,cD=`[object Array]`,lD=`[object Object]`,uD=Object.prototype.hasOwnProperty;function dD(e,t,n,r,i,a){var o=cT(e),s=cT(t),c=o?cD:aD(e),l=s?cD:aD(t);c=c==sD?lD:c,l=l==sD?lD:l;var u=c==lD,d=l==lD,f=c==l;if(f&&PT(e)){if(!PT(t))return!1;o=!0,u=!1}if(f&&!u)return a||=new Sw,o||xE(e)?Lw(e,t,n,r,i,a):aT(e,t,c,n,r,i,a);if(!(n&oD)){var p=u&&uD.call(e,`__wrapped__`),m=d&&uD.call(t,`__wrapped__`);if(p||m){var h=p?e.value():e,g=m?t.value():t;return a||=new Sw,i(h,g,n,r,a)}}return f?(a||=new Sw,HE(e,t,n,r,i,a)):!1}o(dD,`baseIsEqualDeep`);var fD=dD;function pD(e,t,n,r,i){return e===t?!0:e==null||t==null||!xT(e)&&!xT(t)?e!==e&&t!==t:fD(e,t,n,r,pD,i)}o(pD,`baseIsEqual`);var mD=pD,hD=1,gD=2;function _D(e,t,n,r){var i=n.length,a=i,o=!r;if(e==null)return!a;for(e=Object(e);i--;){var s=n[i];if(o&&s[2]?s[1]!==e[s[0]]:!(s[0]in e))return!1}for(;++i<a;){s=n[i];var c=s[0],l=e[c],u=s[1];if(o&&s[2]){if(l===void 0&&!(c in e))return!1}else{var d=new Sw;if(r)var f=r(l,u,c,e,t,d);if(!(f===void 0?mD(u,l,hD|gD,r,d):f))return!1}}return!0}o(_D,`baseIsMatch`);var vD=_D;function yD(e){return e===e&&!dC(e)}o(yD,`isStrictComparable`);var bD=yD;function xD(e){for(var t=IE(e),n=t.length;n--;){var r=t[n],i=e[r];t[n]=[r,i,bD(i)]}return t}o(xD,`getMatchData`);var SD=xD;function CD(e,t){return function(n){return n==null?!1:n[e]===t&&(t!==void 0||e in Object(n))}}o(CD,`matchesStrictComparable`);var wD=CD;function TD(e){var t=SD(e);return t.length==1&&t[0][2]?wD(t[0][0],t[0][1]):function(n){return n===e||vD(n,e,t)}}o(TD,`baseMatches`);var ED=TD,DD=`[object Symbol]`;function OD(e){return typeof e==`symbol`||xT(e)&&lC(e)==DD}o(OD,`isSymbol`);var kD=OD,AD=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,jD=/^\w*$/;function MD(e,t){if(cT(e))return!1;var n=typeof e;return n==`number`||n==`symbol`||n==`boolean`||e==null||kD(e)?!0:jD.test(e)||!AD.test(e)||t!=null&&e in Object(t)}o(MD,`isKey`);var ND=MD,PD=`Expected a function`;function FD(e,t){if(typeof e!=`function`||t!=null&&typeof t!=`function`)throw TypeError(PD);var n=o(function(){var r=arguments,i=t?t.apply(this,r):r[0],a=n.cache;if(a.has(i))return a.get(i);var o=e.apply(this,r);return n.cache=a.set(i,o)||a,o},`memoized`);return n.cache=new(FD.Cache||_w),n}o(FD,`memoize`),FD.Cache=_w;var ID=FD,LD=500;function RD(e){var t=ID(e,function(e){return n.size===LD&&n.clear(),e}),n=t.cache;return t}o(RD,`memoizeCapped`);var zD=RD,BD=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,VD=/\\(\\)?/g,HD=zD(function(e){var t=[];return e.charCodeAt(0)===46&&t.push(``),e.replace(BD,function(e,n,r,i){t.push(r?i.replace(VD,`$1`):n||e)}),t}),UD=1/0,WD=YS?YS.prototype:void 0,GD=WD?WD.toString:void 0;function KD(e){if(typeof e==`string`)return e;if(cT(e))return bS(e,KD)+``;if(kD(e))return GD?GD.call(e):``;var t=e+``;return t==`0`&&1/e==-UD?`-0`:t}o(KD,`baseToString`);var qD=KD;function JD(e){return e==null?``:qD(e)}o(JD,`toString`);var YD=JD;function XD(e,t){return cT(e)?e:ND(e,t)?[e]:HD(YD(e))}o(XD,`castPath`);var ZD=XD,QD=1/0;function $D(e){if(typeof e==`string`||kD(e))return e;var t=e+``;return t==`0`&&1/e==-QD?`-0`:t}o($D,`toKey`);var eO=$D;function tO(e,t){t=ZD(t,e);for(var n=0,r=t.length;e!=null&&n<r;)e=e[eO(t[n++])];return n&&n==r?e:void 0}o(tO,`baseGet`);var nO=tO;function rO(e,t,n){var r=e==null?void 0:nO(e,t);return r===void 0?n:r}o(rO,`get`);var iO=rO;function aO(e,t){return e!=null&&t in Object(e)}o(aO,`baseHasIn`);var oO=aO;function sO(e,t,n){t=ZD(t,e);for(var r=-1,i=t.length,a=!1;++r<i;){var o=eO(t[r]);if(!(a=e!=null&&n(e,o)))break;e=e[o]}return a||++r!=i?a:(i=e==null?0:e.length,!!i&&VT(i)&&RT(o,i)&&(cT(e)||OT(e)))}o(sO,`hasPath`);var cO=sO;function lO(e,t){return e!=null&&cO(e,t,oO)}o(lO,`hasIn`);var uO=lO,dO=1,fO=2;function pO(e,t){return ND(e)&&bD(t)?wD(eO(e),t):function(n){var r=iO(n,e);return r===void 0&&r===t?uO(n,e):mD(t,r,dO|fO)}}o(pO,`baseMatchesProperty`);var mO=pO;function hO(e){return e}o(hO,`identity`);var gO=hO;function _O(e){return function(t){return t?.[e]}}o(_O,`baseProperty`);var vO=_O;function yO(e){return function(t){return nO(t,e)}}o(yO,`basePropertyDeep`);var bO=yO;function xO(e){return ND(e)?vO(eO(e)):bO(e)}o(xO,`property`);var SO=xO;function CO(e){return typeof e==`function`?e:e==null?gO:typeof e==`object`?cT(e)?mO(e[0],e[1]):ED(e):SO(e)}o(CO,`baseIteratee`);var wO=CO;function TO(e){return function(t,n,r){for(var i=-1,a=Object(t),o=r(t),s=o.length;s--;){var c=o[e?s:++i];if(n(a[c],c,a)===!1)break}return t}}o(TO,`createBaseFor`);var EO=TO();function DO(e,t){return e&&EO(e,t,IE)}o(DO,`baseForOwn`);var OO=DO;function kO(e,t){return function(n,r){if(n==null)return n;if(!PE(n))return e(n,r);for(var i=n.length,a=t?i:-1,o=Object(n);(t?a--:++a<i)&&r(o[a],a,o)!==!1;);return n}}o(kO,`createBaseEach`);var AO=kO(OO);function jO(e,t){var n=-1,r=PE(e)?Array(e.length):[];return AO(e,function(e,i,a){r[++n]=t(e,i,a)}),r}o(jO,`baseMap`);var MO=jO;function NO(e,t){return(cT(e)?bS:MO)(e,wO(t,3))}o(NO,`map`);var PO=NO;function FO(e,t){var n=[];return AO(e,function(e,r,i){t(e,r,i)&&n.push(e)}),n}o(FO,`baseFilter`);var IO=FO;function LO(e,t){return(cT(e)?fT:IO)(e,wO(t,3))}o(LO,`filter`);var RO=LO;function zO(e,t,n){return`${e.name}_${t}_${n}`}o(zO,`buildATNKey`);var BO=1,VO=2,HO=4,UO=5,WO=7,GO=8,KO=9,qO=10,JO=11,YO=12,XO=class{static{o(this,`AbstractTransition`)}constructor(e){this.target=e}isEpsilon(){return!1}},ZO=class extends XO{static{o(this,`AtomTransition`)}constructor(e,t){super(e),this.tokenType=t}},QO=class extends XO{static{o(this,`EpsilonTransition`)}constructor(e){super(e)}isEpsilon(){return!0}},$O=class extends XO{static{o(this,`RuleTransition`)}constructor(e,t,n){super(e),this.rule=t,this.followState=n}isEpsilon(){return!0}};function ek(e){let t={decisionMap:{},decisionStates:[],ruleToStartState:new Map,ruleToStopState:new Map,states:[]};tk(t,e);let n=e.length;for(let r=0;r<n;r++){let n=e[r],i=lk(t,n,n);i!==void 0&&yk(t,n,i)}return t}o(ek,`createATN`);function tk(e,t){let n=t.length;for(let r=0;r<n;r++){let n=t[r],i=X(e,n,void 0,{type:VO}),a=X(e,n,void 0,{type:WO});i.stop=a,e.ruleToStartState.set(n,i),e.ruleToStopState.set(n,a)}}o(tk,`createRuleStartAndStopATNStates`);function nk(e,t,n){return n instanceof G?_k(e,t,n.terminalType,n):n instanceof rv?vk(e,t,n):n instanceof uv?sk(e,t,n):n instanceof ov?ck(e,t,n):n instanceof W?rk(e,t,n):n instanceof lv?ik(e,t,n):n instanceof sv?ak(e,t,n):n instanceof cv?ok(e,t,n):lk(e,t,n)}o(nk,`atom`);function rk(e,t,n){let r=X(e,t,n,{type:UO});return pk(e,r),dk(e,t,n,mk(e,t,r,n,lk(e,t,n)))}o(rk,`repetition`);function ik(e,t,n){let r=X(e,t,n,{type:UO});return pk(e,r),dk(e,t,n,mk(e,t,r,n,lk(e,t,n)),_k(e,t,n.separator,n))}o(ik,`repetitionSep`);function ak(e,t,n){let r=X(e,t,n,{type:HO});return pk(e,r),uk(e,t,n,mk(e,t,r,n,lk(e,t,n)))}o(ak,`repetitionMandatory`);function ok(e,t,n){let r=X(e,t,n,{type:HO});return pk(e,r),uk(e,t,n,mk(e,t,r,n,lk(e,t,n)),_k(e,t,n.separator,n))}o(ok,`repetitionMandatorySep`);function sk(e,t,n){let r=X(e,t,n,{type:BO});return pk(e,r),mk(e,t,r,n,...PO(n.definition,n=>nk(e,t,n)))}o(sk,`alternation`);function ck(e,t,n){let r=X(e,t,n,{type:BO});return pk(e,r),fk(e,t,n,mk(e,t,r,n,lk(e,t,n)))}o(ck,`option`);function lk(e,t,n){let r=RO(PO(n.definition,n=>nk(e,t,n)),e=>e!==void 0);return r.length===1?r[0]:r.length===0?void 0:gk(e,r)}o(lk,`block`);function uk(e,t,n,r,i){let a=r.left,o=r.right,s=X(e,t,n,{type:JO});pk(e,s);let c=X(e,t,n,{type:YO});return a.loopback=s,c.loopback=s,e.decisionMap[zO(t,i?`RepetitionMandatoryWithSeparator`:`RepetitionMandatory`,n.idx)]=s,Y(o,s),i===void 0?(Y(s,a),Y(s,c)):(Y(s,c),Y(s,i.left),Y(i.right,a)),{left:a,right:c}}o(uk,`plus`);function dk(e,t,n,r,i){let a=r.left,o=r.right,s=X(e,t,n,{type:qO});pk(e,s);let c=X(e,t,n,{type:YO}),l=X(e,t,n,{type:KO});return s.loopback=l,c.loopback=l,Y(s,a),Y(s,c),Y(o,l),i===void 0?Y(l,s):(Y(l,c),Y(l,i.left),Y(i.right,a)),e.decisionMap[zO(t,i?`RepetitionWithSeparator`:`Repetition`,n.idx)]=s,{left:s,right:c}}o(dk,`star`);function fk(e,t,n,r){let i=r.left,a=r.right;return Y(i,a),e.decisionMap[zO(t,`Option`,n.idx)]=i,r}o(fk,`optional`);function pk(e,t){return e.decisionStates.push(t),t.decision=e.decisionStates.length-1,t.decision}o(pk,`defineDecisionState`);function mk(e,t,n,r,...i){let a=X(e,t,r,{type:GO,start:n});n.end=a;for(let e of i)e===void 0?Y(n,a):(Y(n,e.left),Y(e.right,a));let o={left:n,right:a};return e.decisionMap[zO(t,hk(r),r.idx)]=n,o}o(mk,`makeAlts`);function hk(e){if(e instanceof uv)return`Alternation`;if(e instanceof ov)return`Option`;if(e instanceof W)return`Repetition`;if(e instanceof lv)return`RepetitionWithSeparator`;if(e instanceof sv)return`RepetitionMandatory`;if(e instanceof cv)return`RepetitionMandatoryWithSeparator`;throw Error(`Invalid production type encountered`)}o(hk,`getProdType`);function gk(e,t){let n=t.length;for(let r=0;r<n-1;r++){let n=t[r],i;n.left.transitions.length===1&&(i=n.left.transitions[0]);let a=i instanceof $O,o=i,s=t[r+1].left;n.left.type===BO&&n.right.type===BO&&i!==void 0&&(a&&o.followState===n.right||i.target===n.right)?(a?o.followState=s:i.target=s,xk(e,n.right)):Y(n.right,s)}let r=t[0],i=t[n-1];return{left:r.left,right:i.right}}o(gk,`makeBlock`);function _k(e,t,n,r){let i=X(e,t,r,{type:BO}),a=X(e,t,r,{type:BO});return bk(i,new ZO(a,n)),{left:i,right:a}}o(_k,`tokenRef`);function vk(e,t,n){let r=n.referencedRule,i=e.ruleToStartState.get(r),a=X(e,t,n,{type:BO}),o=X(e,t,n,{type:BO});return bk(a,new $O(i,r,o)),{left:a,right:o}}o(vk,`ruleRef`);function yk(e,t,n){let r=e.ruleToStartState.get(t);Y(r,n.left);let i=e.ruleToStopState.get(t);return Y(n.right,i),{left:r,right:i}}o(yk,`buildRuleHandle`);function Y(e,t){bk(e,new QO(t))}o(Y,`epsilon`);function X(e,t,n,r){let i=Object.assign({atn:e,production:n,epsilonOnlyTransitions:!1,rule:t,transitions:[],nextTokenWithinRule:[],stateNumber:e.states.length},r);return e.states.push(i),i}o(X,`newState`);function bk(e,t){e.transitions.length===0&&(e.epsilonOnlyTransitions=t.isEpsilon()),e.transitions.push(t)}o(bk,`addTransition`);function xk(e,t){e.states.splice(e.states.indexOf(t),1)}o(xk,`removeState`);var Sk={},Ck=class{static{o(this,`ATNConfigSet`)}constructor(){this.map={},this.configs=[]}get size(){return this.configs.length}finalize(){this.map={}}add(e){let t=wk(e);t in this.map||(this.map[t]=this.configs.length,this.configs.push(e))}get elements(){return this.configs}get alts(){return PO(this.configs,e=>e.alt)}get key(){let e=``;for(let t in this.map)e+=t+`:`;return e}};function wk(e,t=!0){return`${t?`a${e.alt}`:``}s${e.state.stateNumber}:${e.stack.map(e=>e.stateNumber.toString()).join(`_`)}`}o(wk,`getATNConfigKey`);function Tk(e,t,n){for(var r=-1,i=e.length;++r<i;){var a=e[r],o=t(a);if(o!=null&&(s===void 0?o===o&&!kD(o):n(o,s)))var s=o,c=a}return c}o(Tk,`baseExtremum`);var Ek=Tk;function Dk(e,t){return e<t}o(Dk,`baseLt`);var Ok=Dk;function kk(e){return e&&e.length?Ek(e,gO,Ok):void 0}o(kk,`min`);var Ak=kk,jk=YS?YS.isConcatSpreadable:void 0;function Mk(e){return cT(e)||OT(e)||!!(jk&&e&&e[jk])}o(Mk,`isFlattenable`);var Nk=Mk;function Pk(e,t,n,r,i){var a=-1,o=e.length;for(n||=Nk,i||=[];++a<o;){var s=e[a];t>0&&n(s)?t>1?Pk(s,t-1,n,r,i):sT(i,s):r||(i[i.length]=s)}return i}o(Pk,`baseFlatten`);var Fk=Pk;function Ik(e,t){return Fk(PO(e,t),1)}o(Ik,`flatMap`);var Lk=Ik;function Rk(e,t,n,r){for(var i=e.length,a=n+(r?1:-1);r?a--:++a<i;)if(t(e[a],a,e))return a;return-1}o(Rk,`baseFindIndex`);var zk=Rk;function Bk(e){return e!==e}o(Bk,`baseIsNaN`);var Vk=Bk;function Hk(e,t,n){for(var r=n-1,i=e.length;++r<i;)if(e[r]===t)return r;return-1}o(Hk,`strictIndexOf`);var Uk=Hk;function Wk(e,t,n){return t===t?Uk(e,t,n):zk(e,Vk,n)}o(Wk,`baseIndexOf`);var Gk=Wk;function Kk(e,t){return!!(e!=null&&e.length)&&Gk(e,t,0)>-1}o(Kk,`arrayIncludes`);var qk=Kk;function Jk(e,t,n){for(var r=-1,i=e==null?0:e.length;++r<i;)if(n(t,e[r]))return!0;return!1}o(Jk,`arrayIncludesWith`);var Yk=Jk;function Xk(){}o(Xk,`noop`);var Zk=Xk,Qk=GE&&1/Hw(new GE([,-0]))[1]==1/0?function(e){return new GE(e)}:Zk,$k=200;function eA(e,t,n){var r=-1,i=qk,a=e.length,o=!0,s=[],c=s;if(n)o=!1,i=Yk;else if(a>=$k){var l=t?null:Qk(e);if(l)return Hw(l);o=!1,i=Nw,c=new kw}else c=t?[]:s;outer:for(;++r<a;){var u=e[r],d=t?t(u):u;if(u=n||u!==0?u:0,o&&d===d){for(var f=c.length;f--;)if(c[f]===d)continue outer;t&&c.push(d),s.push(u)}else i(c,d,n)||(c!==s&&c.push(d),s.push(u))}return s}o(eA,`baseUniq`);var tA=eA;function nA(e,t){return e&&e.length?tA(e,wO(t,2)):[]}o(nA,`uniqBy`);var rA=nA;function iA(e){return e!=null&&e.length?Fk(e,1):[]}o(iA,`flatten`);var aA=iA;function oA(e,t){for(var n=-1,r=e==null?0:e.length;++n<r&&t(e[n],n,e)!==!1;);return e}o(oA,`arrayEach`);var sA=oA;function cA(e){return typeof e==`function`?e:gO}o(cA,`castFunction`);var lA=cA;function uA(e,t){return(cT(e)?sA:AO)(e,lA(t))}o(uA,`forEach`);var dA=uA,fA=`[object Map]`,pA=`[object Set]`,mA=Object.prototype.hasOwnProperty;function hA(e){if(e==null)return!0;if(PE(e)&&(cT(e)||typeof e==`string`||typeof e.splice==`function`||PT(e)||xE(e)||OT(e)))return!e.length;var t=aD(e);if(t==fA||t==pA)return!e.size;if(DE(e))return!ME(e).length;for(var n in e)if(mA.call(e,n))return!1;return!0}o(hA,`isEmpty`);var gA=hA;function _A(e,t,n,r){var i=-1,a=e==null?0:e.length;for(r&&a&&(n=e[++i]);++i<a;)n=t(n,e[i],i,e);return n}o(_A,`arrayReduce`);var vA=_A;function yA(e,t,n,r,i){return i(e,function(e,i,a){n=r?(r=!1,e):t(n,e,i,a)}),n}o(yA,`baseReduce`);var bA=yA;function xA(e,t,n){var r=cT(e)?vA:bA,i=arguments.length<3;return r(e,wO(t,4),n,i,AO)}o(xA,`reduce`);var SA=xA;function CA(e,t){let n={};return r=>{let i=r.toString(),a=n[i];return a===void 0?(a={atnStartState:e,decision:t,states:{}},n[i]=a,a):a}}o(CA,`createDFACache`);var wA=class{static{o(this,`PredicateSet`)}constructor(){this.predicates=[]}is(e){return e>=this.predicates.length||this.predicates[e]}set(e,t){this.predicates[e]=t}toString(){let e=``,t=this.predicates.length;for(let n=0;n<t;n++)e+=this.predicates[n]===!0?`1`:`0`;return e}},TA=new wA,EA=class extends jx{static{o(this,`LLStarLookaheadStrategy`)}constructor(e){super(),this.logging=e?.logging??(e=>console.log(e))}initialize(e){this.atn=ek(e.rules),this.dfas=OA(this.atn)}validateAmbiguousAlternationAlternatives(){return[]}validateEmptyOrAlternatives(){return[]}buildLookaheadForAlternation(e){let{prodOccurrence:t,rule:n,hasPredicates:r,dynamicTokensEnabled:i}=e,a=this.dfas,o=this.logging,s=zO(n,`Alternation`,t),c=this.atn.decisionMap[s].decision,l=PO(Sb({maxLookahead:1,occurrence:t,prodType:`Alternation`,rule:n}),e=>PO(e,e=>e[0]));if(DA(l,!1)&&!i){let e=SA(l,(e,t,n)=>(dA(t,t=>{t&&(e[t.tokenTypeIdx]=n,dA(t.categoryMatches,t=>{e[t]=n}))}),e),{});return r?function(t){let n=e[this.LA(1).tokenTypeIdx];if(t!==void 0&&n!==void 0){let e=t[n]?.GATE;if(e!==void 0&&e.call(this)===!1)return}return n}:function(){return e[this.LA(1).tokenTypeIdx]}}else if(r)return function(e){let t=new wA,n=e===void 0?0:e.length;for(let r=0;r<n;r++){let n=e?.[r].GATE;t.set(r,n===void 0||n.call(this))}let r=kA.call(this,a,c,t,o);return typeof r==`number`?r:void 0};else return function(){let e=kA.call(this,a,c,TA,o);return typeof e==`number`?e:void 0}}buildLookaheadForOptional(e){let{prodOccurrence:t,rule:n,prodType:r,dynamicTokensEnabled:i}=e,a=this.dfas,o=this.logging,s=zO(n,r,t),c=this.atn.decisionMap[s].decision,l=PO(Sb({maxLookahead:1,occurrence:t,prodType:r,rule:n}),e=>PO(e,e=>e[0]));if(DA(l)&&l[0][0]&&!i){let e=l[0],t=aA(e);if(t.length===1&&gA(t[0].categoryMatches)){let e=t[0].tokenTypeIdx;return function(){return this.LA(1).tokenTypeIdx===e}}else{let e=SA(t,(e,t)=>(t!==void 0&&(e[t.tokenTypeIdx]=!0,dA(t.categoryMatches,t=>{e[t]=!0})),e),{});return function(){return e[this.LA(1).tokenTypeIdx]===!0}}}return function(){let e=kA.call(this,a,c,TA,o);return typeof e==`object`?!1:e===0}}};function DA(e,t=!0){let n=new Set;for(let r of e){let e=new Set;for(let i of r){if(i===void 0){if(t)break;return!1}let r=[i.tokenTypeIdx].concat(i.categoryMatches);for(let t of r)if(n.has(t)){if(!e.has(t))return!1}else n.add(t),e.add(t)}}return!0}o(DA,`isLL1Sequence`);function OA(e){let t=e.decisionStates.length,n=Array(t);for(let r=0;r<t;r++)n[r]=CA(e.decisionStates[r],r);return n}o(OA,`initATNSimulator`);function kA(e,t,n,r){let i=e[t](n),a=i.start;return a===void 0&&(a=HA(i,BA(UA(i.atnStartState))),i.start=a),AA.apply(this,[i,a,n,r])}o(kA,`adaptivePredict`);function AA(e,t,n,r){let i=t,a=1,o=[],s=this.LA(a++);for(;;){let t=IA(i,s);if(t===void 0&&(t=jA.apply(this,[e,i,s,a,n,r])),t===Sk)return FA(o,i,s);if(t.isAcceptState===!0)return t.prediction;i=t,o.push(s),s=this.LA(a++)}}o(AA,`performLookahead`);function jA(e,t,n,r,i,a){let o=LA(t.configs,n,i);if(o.size===0)return VA(e,t,n,Sk),Sk;let s=BA(o),c=zA(o,i);if(c!==void 0)s.isAcceptState=!0,s.prediction=c,s.configs.uniqueAlt=c;else if(JA(o)){let t=Ak(o.alts);s.isAcceptState=!0,s.prediction=t,s.configs.uniqueAlt=t,MA.apply(this,[e,r,o.alts,a])}return s=VA(e,t,n,s),s}o(jA,`computeLookaheadTarget`);function MA(e,t,n,r){let i=[];for(let e=1;e<=t;e++)i.push(this.LA(e).tokenType);let a=e.atnStartState,o=a.rule,s=a.production;r(NA({topLevelRule:o,ambiguityIndices:n,production:s,prefixPath:i}))}o(MA,`reportLookaheadAmbiguity`);function NA(e){let t=PO(e.prefixPath,e=>Wy(e)).join(`, `),n=e.production.idx===0?``:e.production.idx,r=`Ambiguous Alternatives Detected: <${e.ambiguityIndices.join(`, `)}> in <${PA(e.production)}${n}> inside <${e.topLevelRule.name}> Rule,
146
+ <${t}> may appears as a prefix path in all these alternatives.
147
+ `;return r+=`See: https://chevrotain.io/docs/guide/resolving_grammar_errors.html#AMBIGUOUS_ALTERNATIVES
148
+ For Further details.`,r}o(NA,`buildAmbiguityError`);function PA(e){if(e instanceof rv)return`SUBRULE`;if(e instanceof ov)return`OPTION`;if(e instanceof uv)return`OR`;if(e instanceof sv)return`AT_LEAST_ONE`;if(e instanceof cv)return`AT_LEAST_ONE_SEP`;if(e instanceof lv)return`MANY_SEP`;if(e instanceof W)return`MANY`;if(e instanceof G)return`CONSUME`;throw Error(`non exhaustive match`)}o(PA,`getProductionDslName`);function FA(e,t,n){return{actualToken:n,possibleTokenTypes:rA(Lk(t.configs.elements,e=>e.state.transitions).filter(e=>e instanceof ZO).map(e=>e.tokenType),e=>e.tokenTypeIdx),tokenPath:e}}o(FA,`buildAdaptivePredictError`);function IA(e,t){return e.edges[t.tokenTypeIdx]}o(IA,`getExistingTargetState`);function LA(e,t,n){let r=new Ck,i=[];for(let a of e.elements){if(n.is(a.alt)===!1)continue;if(a.state.type===WO){i.push(a);continue}let e=a.state.transitions.length;for(let n=0;n<e;n++){let e=a.state.transitions[n],i=RA(e,t);i!==void 0&&r.add({state:i,alt:a.alt,stack:a.stack})}}let a;if(i.length===0&&r.size===1&&(a=r),a===void 0){a=new Ck;for(let e of r.elements)WA(e,a)}if(i.length>0&&!KA(a))for(let e of i)a.add(e);return a}o(LA,`computeReachSet`);function RA(e,t){if(e instanceof ZO&&ab(t,e.tokenType))return e.target}o(RA,`getReachableTarget`);function zA(e,t){let n;for(let r of e.elements)if(t.is(r.alt)===!0){if(n===void 0)n=r.alt;else if(n!==r.alt)return}return n}o(zA,`getUniqueAlt`);function BA(e){return{configs:e,edges:{},isAcceptState:!1,prediction:-1}}o(BA,`newDFAState`);function VA(e,t,n,r){return r=HA(e,r),t.edges[n.tokenTypeIdx]=r,r}o(VA,`addDFAEdge`);function HA(e,t){if(t===Sk)return t;let n=t.configs.key,r=e.states[n];return r===void 0?(t.configs.finalize(),e.states[n]=t,t):r}o(HA,`addDFAState`);function UA(e){let t=new Ck,n=e.transitions.length;for(let r=0;r<n;r++)WA({state:e.transitions[r].target,alt:r,stack:[]},t);return t}o(UA,`computeStartState`);function WA(e,t){let n=e.state;if(n.type===WO){if(e.stack.length>0){let n=[...e.stack];WA({state:n.pop(),alt:e.alt,stack:n},t)}else t.add(e);return}n.epsilonOnlyTransitions||t.add(e);let r=n.transitions.length;for(let i=0;i<r;i++){let r=n.transitions[i],a=GA(e,r);a!==void 0&&WA(a,t)}}o(WA,`closure`);function GA(e,t){if(t instanceof QO)return{state:t.target,alt:e.alt,stack:e.stack};if(t instanceof $O){let n=[...e.stack,t.followState];return{state:t.target,alt:e.alt,stack:n}}}o(GA,`getEpsilonTarget`);function KA(e){for(let t of e.elements)if(t.state.type===WO)return!0;return!1}o(KA,`hasConfigInRuleStopState`);function qA(e){for(let t of e.elements)if(t.state.type!==WO)return!1;return!0}o(qA,`allConfigsInRuleStopStates`);function JA(e){if(qA(e))return!0;let t=YA(e.elements);return XA(t)&&!ZA(t)}o(JA,`hasConflictTerminatingPrediction`);function YA(e){let t=new Map;for(let n of e){let e=wk(n,!1),r=t.get(e);r===void 0&&(r={},t.set(e,r)),r[n.alt]=!0}return t}o(YA,`getConflictingAltSets`);function XA(e){for(let t of Array.from(e.values()))if(Object.keys(t).length>1)return!0;return!1}o(XA,`hasConflictingAltSet`);function ZA(e){for(let t of Array.from(e.values()))if(Object.keys(t).length===1)return!0;return!1}o(ZA,`hasStateAssociatedWithOneAlt`),gt();var QA=class{static{o(this,`CstNodeBuilder`)}constructor(){this.nodeStack=[]}get current(){return this.nodeStack[this.nodeStack.length-1]??this.rootNode}buildRootNode(e){return this.rootNode=new rj(e),this.rootNode.root=this.rootNode,this.nodeStack=[this.rootNode],this.rootNode}buildCompositeNode(e){let t=new tj;return t.grammarSource=e,t.root=this.rootNode,this.current.content.push(t),this.nodeStack.push(t),t}buildLeafNode(e,t){let n=new ej(e.startOffset,e.image.length,Bi(e),e.tokenType,!t);return n.grammarSource=t,n.root=this.rootNode,this.current.content.push(n),n}removeNode(e){let t=e.container;if(t){let n=t.content.indexOf(e);n>=0&&t.content.splice(n,1)}}addHiddenNodes(e){let t=[];for(let n of e){let e=new ej(n.startOffset,n.image.length,Bi(n),n.tokenType,!0);e.root=this.rootNode,t.push(e)}let n=this.current,r=!1;if(n.content.length>0){n.content.push(...t);return}for(;n.container;){let e=n.container.content.indexOf(n);if(e>0){n.container.content.splice(e,0,...t),r=!0;break}n=n.container}r||this.rootNode.content.unshift(...t)}construct(e){let t=this.current;typeof e.$type==`string`&&!e.$infix&&(this.current.astNode=e),e.$cstNode=t;let n=this.nodeStack.pop();n?.content.length===0&&this.removeNode(n)}},$A=class{static{o(this,`AbstractCstNode`)}get hidden(){return!1}get astNode(){let e=typeof this._astNode?.$type==`string`?this._astNode:this.container?.astNode;if(!e)throw Error(`This node has no associated AST element`);return e}set astNode(e){this._astNode=e}get text(){return this.root.fullText.substring(this.offset,this.end)}},ej=class extends $A{static{o(this,`LeafCstNodeImpl`)}get offset(){return this._offset}get length(){return this._length}get end(){return this._offset+this._length}get hidden(){return this._hidden}get tokenType(){return this._tokenType}get range(){return this._range}constructor(e,t,n,r,i=!1){super(),this._hidden=i,this._offset=e,this._tokenType=r,this._length=t,this._range=n}},tj=class extends $A{static{o(this,`CompositeCstNodeImpl`)}constructor(){super(...arguments),this.content=new nj(this)}get offset(){return this.firstNonHiddenNode?.offset??0}get length(){return this.end-this.offset}get end(){return this.lastNonHiddenNode?.end??0}get range(){let e=this.firstNonHiddenNode,t=this.lastNonHiddenNode;if(e&&t){if(this._rangeCache===void 0){let{range:n}=e,{range:r}=t;this._rangeCache={start:n.start,end:r.end.line<n.start.line?n.start:r.end}}return this._rangeCache}else return{start:y.create(0,0),end:y.create(0,0)}}get firstNonHiddenNode(){for(let e of this.content)if(!e.hidden)return e;return this.content[0]}get lastNonHiddenNode(){for(let e=this.content.length-1;e>=0;e--){let t=this.content[e];if(!t.hidden)return t}return this.content[this.content.length-1]}},nj=class e extends Array{static{o(this,`CstNodeContainer`)}constructor(t){super(),this.parent=t,Object.setPrototypeOf(this,e.prototype)}push(...e){return this.addParents(e),super.push(...e)}unshift(...e){return this.addParents(e),super.unshift(...e)}splice(e,t,...n){return this.addParents(n),super.splice(e,t,...n)}addParents(e){for(let t of e)t.container=this.parent}},rj=class extends tj{static{o(this,`RootCstNodeImpl`)}get text(){return this._text.substring(this.offset,this.end)}get fullText(){return this._text}constructor(e){super(),this._text=``,this._text=e??``}},ij=Symbol(`Datatype`);function aj(e){return e.$type===ij}o(aj,`isDataTypeNode`);var oj=`​`,sj=o(e=>e.endsWith(oj)?e:e+oj,`withRuleSuffix`),cj=class{static{o(this,`AbstractLangiumParser`)}constructor(e){this._unorderedGroups=new Map,this.allRules=new Map,this.lexer=e.parser.Lexer;let t=this.lexer.definition,n=e.LanguageMetaData.mode===`production`;e.shared.profilers.LangiumProfiler?.isActive(`parsing`)?this.wrapper=new hj(t,{...e.parser.ParserConfig,skipValidations:n,errorMessageProvider:e.parser.ParserErrorMessageProvider},e.shared.profilers.LangiumProfiler.createTask(`parsing`,e.LanguageMetaData.languageId)):this.wrapper=new mj(t,{...e.parser.ParserConfig,skipValidations:n,errorMessageProvider:e.parser.ParserErrorMessageProvider})}alternatives(e,t){this.wrapper.wrapOr(e,t)}optional(e,t){this.wrapper.wrapOption(e,t)}many(e,t){this.wrapper.wrapMany(e,t)}atLeastOne(e,t){this.wrapper.wrapAtLeastOne(e,t)}getRule(e){return this.allRules.get(e)}isRecording(){return this.wrapper.IS_RECORDING}get unorderedGroups(){return this._unorderedGroups}getRuleStack(){return this.wrapper.RULE_STACK}finalize(){this.wrapper.wrapSelfAnalysis()}},lj=class extends cj{static{o(this,`LangiumParser`)}get current(){return this.stack[this.stack.length-1]}constructor(e){super(e),this.nodeBuilder=new QA,this.stack=[],this.assignmentMap=new Map,this.operatorPrecedence=new Map,this.linker=e.references.Linker,this.converter=e.parser.ValueConverter,this.astReflection=e.shared.AstReflection}rule(e,t){let n=this.computeRuleType(e),r;Or(e)&&(r=e.name,this.registerPrecedenceMap(e));let i=this.wrapper.DEFINE_RULE(sj(e.name),this.startImplementation(n,r,t).bind(this));return this.allRules.set(e.name,i),Xr(e)&&e.entry&&(this.mainRule=i),i}registerPrecedenceMap(e){let t=e.name,n=new Map;for(let t=0;t<e.operators.precedences.length;t++){let r=e.operators.precedences[t];for(let e of r.operators)n.set(e.value,{precedence:t,rightAssoc:r.associativity===`right`})}this.operatorPrecedence.set(t,n)}computeRuleType(e){return Or(e)?ro(e):e.fragment?void 0:Qa(e)?ij:ro(e)}parse(e,t={}){this.nodeBuilder.buildRootNode(e);let n=this.lexerResult=this.lexer.tokenize(e);this.wrapper.input=n.tokens;let r=t.rule?this.allRules.get(t.rule):this.mainRule;if(!r)throw Error(t.rule?`No rule found with name '${t.rule}'`:`No main rule available.`);let i=this.doParse(r);return this.nodeBuilder.addHiddenNodes(n.hidden),this.unorderedGroups.clear(),this.lexerResult=void 0,Tn(i,{deep:!0}),{value:i,lexerErrors:n.errors,lexerReport:n.report,parserErrors:this.wrapper.errors}}doParse(e){let t=this.wrapper.rule(e);if(this.stack.length>0&&(t=this.construct()),t===void 0)throw Error(`No result from parser`);if(this.stack.length>0)throw Error(`Parser stack is not empty after parsing`);return t}startImplementation(e,t,n){return r=>{let i=!this.isRecording()&&e!==void 0;if(i){let n={$type:e};this.stack.push(n),e===ij?n.value=``:t!==void 0&&(n.$infixName=t)}return n(r),i?this.construct():void 0}}extractHiddenTokens(e){let t=this.lexerResult.hidden;if(!t.length)return[];let n=e.startOffset;for(let e=0;e<t.length;e++)if(t[e].startOffset>n)return t.splice(0,e);return t.splice(0,t.length)}consume(e,t,n){let r=this.wrapper.wrapConsume(e,t);if(!this.isRecording()&&this.isValidToken(r)){let e=this.extractHiddenTokens(r);this.nodeBuilder.addHiddenNodes(e);let t=this.nodeBuilder.buildLeafNode(r,n),{assignment:i,crossRef:a}=this.getAssignment(n),o=this.current;if(i){let e=Ir(n)?r.image:this.converter.convert(r.image,t);this.assign(i.operator,i.feature,e,t,a)}else if(aj(o)){let e=r.image;Ir(n)||(e=this.converter.convert(e,t).toString()),o.value+=e}}}isValidToken(e){return!e.isInsertedInRecovery&&!isNaN(e.startOffset)&&typeof e.endOffset==`number`&&!isNaN(e.endOffset)}subrule(e,t,n,r,i){let a;!this.isRecording()&&!n&&(a=this.nodeBuilder.buildCompositeNode(r));let o;try{o=this.wrapper.wrapSubrule(e,t,i)}finally{this.isRecording()||(o===void 0&&!n&&(o=this.construct()),o!==void 0&&a&&a.length>0&&this.performSubruleAssignment(o,r,a))}}performSubruleAssignment(e,t,n){let{assignment:r,crossRef:i}=this.getAssignment(t);if(r)this.assign(r.operator,r.feature,e,n,i);else if(!r){let t=this.current;if(aj(t))t.value+=e.toString();else if(typeof e==`object`&&e){let n=this.assignWithoutOverride(e,t);this.stack.pop(),this.stack.push(n)}}}action(e,t){if(!this.isRecording()){let n=this.current;if(t.feature&&t.operator){n=this.construct(),this.nodeBuilder.removeNode(n.$cstNode),this.nodeBuilder.buildCompositeNode(t).content.push(n.$cstNode);let r={$type:e};this.stack.push(r),this.assign(t.operator,t.feature,n,n.$cstNode)}else n.$type=e}}construct(){if(this.isRecording())return;let e=this.stack.pop();return this.nodeBuilder.construct(e),`$infixName`in e?this.constructInfix(e,this.operatorPrecedence.get(e.$infixName)):aj(e)?this.converter.convert(e.value,e.$cstNode):(In(this.astReflection,e),e)}constructInfix(e,t){let n=e.parts;if(!Array.isArray(n)||n.length===0)return;let r=e.operators;if(!Array.isArray(r)||n.length<2)return n[0];let i=0,a=-1;for(let e=0;e<r.length;e++){let n=r[e],o=t.get(n)??{precedence:1/0,rightAssoc:!1};o.precedence>a?(a=o.precedence,i=e):o.precedence===a&&(o.rightAssoc||(i=e))}let o=r.slice(0,i),s=r.slice(i+1),c=n.slice(0,i+1),l=n.slice(i+1),u={$infixName:e.$infixName,$type:e.$type,$cstNode:e.$cstNode,parts:c,operators:o},d={$infixName:e.$infixName,$type:e.$type,$cstNode:e.$cstNode,parts:l,operators:s},f=this.constructInfix(u,t),p=this.constructInfix(d,t);return{$type:e.$type,$cstNode:e.$cstNode,left:f,operator:r[i],right:p}}getAssignment(e){if(!this.assignmentMap.has(e)){let t=En(e,ir);this.assignmentMap.set(e,{assignment:t,crossRef:t&&mr(t.terminal)?t.terminal.isMulti?`multi`:`single`:void 0})}return this.assignmentMap.get(e)}assign(e,t,n,r,i){let a=this.current,o;switch(o=i===`single`&&typeof n==`string`?this.linker.buildReference(a,t,r,n):i===`multi`&&typeof n==`string`?this.linker.buildMultiReference(a,t,r,n):n,e){case`=`:a[t]=o;break;case`?=`:a[t]=!0;break;case`+=`:Array.isArray(a[t])||(a[t]=[]),a[t].push(o)}}assignWithoutOverride(e,t){for(let[n,r]of Object.entries(t)){let t=e[n];t===void 0?e[n]=r:Array.isArray(t)&&Array.isArray(r)&&(r.push(...t),e[n]=r)}let n=e.$cstNode;return n&&(n.astNode=void 0,e.$cstNode=void 0),e}get definitionErrors(){return this.wrapper.definitionErrors}},uj=class{static{o(this,`AbstractParserErrorMessageProvider`)}buildMismatchTokenMessage(e){return ob.buildMismatchTokenMessage(e)}buildNotAllInputParsedMessage(e){return ob.buildNotAllInputParsedMessage(e)}buildNoViableAltMessage(e){return ob.buildNoViableAltMessage(e)}buildEarlyExitMessage(e){return ob.buildEarlyExitMessage(e)}},dj=class extends uj{static{o(this,`LangiumParserErrorMessageProvider`)}buildMismatchTokenMessage({expected:e,actual:t}){return`Expecting ${e.LABEL?"`"+e.LABEL+"`":e.name.endsWith(`:KW`)?`keyword '${e.name.substring(0,e.name.length-3)}'`:`token of type '${e.name}'`} but found \`${t.image}\`.`}buildNotAllInputParsedMessage({firstRedundant:e}){return`Expecting end of file but found \`${e.image}\`.`}},fj=class extends cj{static{o(this,`LangiumCompletionParser`)}constructor(){super(...arguments),this.tokens=[],this.elementStack=[],this.lastElementStack=[],this.nextTokenIndex=0,this.stackSize=0}action(){}construct(){}parse(e){this.resetState();let t=this.lexer.tokenize(e,{mode:`partial`});return this.tokens=t.tokens,this.wrapper.input=[...this.tokens],this.mainRule.call(this.wrapper,{}),this.unorderedGroups.clear(),{tokens:this.tokens,elementStack:[...this.lastElementStack],tokenIndex:this.nextTokenIndex}}rule(e,t){let n=this.wrapper.DEFINE_RULE(sj(e.name),this.startImplementation(t).bind(this));return this.allRules.set(e.name,n),e.entry&&(this.mainRule=n),n}resetState(){this.elementStack=[],this.lastElementStack=[],this.nextTokenIndex=0,this.stackSize=0}startImplementation(e){return t=>{let n=this.keepStackSize();try{e(t)}finally{this.resetStackSize(n)}}}removeUnexpectedElements(){this.elementStack.splice(this.stackSize)}keepStackSize(){let e=this.elementStack.length;return this.stackSize=e,e}resetStackSize(e){this.removeUnexpectedElements(),this.stackSize=e}consume(e,t,n){this.wrapper.wrapConsume(e,t),this.isRecording()||(this.lastElementStack=[...this.elementStack,n],this.nextTokenIndex=this.currIdx+1)}subrule(e,t,n,r,i){this.before(r),this.wrapper.wrapSubrule(e,t,i),this.after(r)}before(e){this.isRecording()||this.elementStack.push(e)}after(e){if(!this.isRecording()){let t=this.elementStack.lastIndexOf(e);t>=0&&this.elementStack.splice(t)}}get currIdx(){return this.wrapper.currIdx}},pj={recoveryEnabled:!0,nodeLocationTracking:`full`,skipValidations:!0,errorMessageProvider:new dj},mj=class extends vS{static{o(this,`ChevrotainWrapper`)}constructor(e,t){let n=t&&`maxLookahead`in t;super(e,{...pj,lookaheadStrategy:n?new jx({maxLookahead:t.maxLookahead}):new EA({logging:t.skipValidations?()=>{}:void 0}),...t})}get IS_RECORDING(){return this.RECORDING_PHASE}DEFINE_RULE(e,t,n){return this.RULE(e,t,n)}wrapSelfAnalysis(){this.performSelfAnalysis()}wrapConsume(e,t){return this.consume(e,t,void 0)}wrapSubrule(e,t,n){return this.subrule(e,t,{ARGS:[n]})}wrapOr(e,t){this.or(e,t)}wrapOption(e,t){this.option(e,t)}wrapMany(e,t){this.many(e,t)}wrapAtLeastOne(e,t){this.atLeastOne(e,t)}rule(e){return e.call(this,{})}},hj=class extends mj{static{o(this,`ProfilerWrapper`)}constructor(e,t,n){super(e,t),this.task=n}rule(e){this.task.start(),this.task.startSubTask(this.ruleName(e));try{return super.rule(e)}finally{this.task.stopSubTask(this.ruleName(e)),this.task.stop()}}ruleName(e){return e.ruleName}subrule(e,t,n){this.task.startSubTask(this.ruleName(t));try{return super.subrule(e,t,n)}finally{this.task.stopSubTask(this.ruleName(t))}}};function gj(e,t,n){return _j({parser:t,tokens:n,ruleNames:new Map},e),t}o(gj,`createParser`);function _j(e,t){let n=Pa(t,!1),r=M(t.rules).filter(Xr).filter(e=>n.has(e));for(let t of r){let n={...e,consume:1,optional:1,subrule:1,many:1,or:1};e.parser.rule(t,yj(n,t.definition))}let i=M(t.rules).filter(Or).filter(e=>n.has(e));for(let t of i)e.parser.rule(t,vj(e,t))}o(_j,`buildRules`);function vj(e,t){let n=t.call.rule.ref;if(!n)throw Error(`Could not resolve reference to infix operator rule: `+t.call.rule.$refText);if(gi(n))throw Error(`Cannot use terminal rule in infix expression`);let r=t.operators.precedences.flatMap(e=>e.operators),i={$type:`Group`,elements:[]},a={$container:i,$type:`Assignment`,feature:`parts`,operator:`+=`,terminal:t.call},s={$container:i,$type:`Group`,elements:[],cardinality:`*`};i.elements.push(a,s);let c={$container:s,$type:`Assignment`,feature:`operators`,operator:`+=`,terminal:{$type:`Alternatives`,elements:r}},l={...a,$container:s};s.elements.push(c,l);let u=r.map(t=>e.tokens[t.value]).map((t,n)=>({ALT:o(()=>e.parser.consume(n,t,c),`ALT`)})),d;return t=>{d??=jj(e,n),e.parser.subrule(0,d,!1,a,t),e.parser.many(0,{DEF:o(()=>{e.parser.alternatives(0,u),e.parser.subrule(1,d,!1,l,t)},`DEF`)})}}o(vj,`buildInfixRule`);function yj(e,t,n=!1){let r;if(Ir(t))r=kj(e,t);else if(Xn(t))r=bj(e,t);else if(ir(t))r=yj(e,t.terminal);else if(mr(t))r=Oj(e,t);else if(ii(t))r=xj(e,t);else if(Qn(t))r=wj(e,t);else if(Oi(t))r=Tj(e,t);else if(wr(t))r=Ej(e,t);else if(vr(t)){let n=e.consume++;r=o(()=>e.parser.consume(n,rb,t),`method`)}else throw new aa(t.$cstNode,`Unexpected element type: ${t.$type}`);return Aj(e,n?void 0:Dj(t),r,t.cardinality)}o(yj,`buildElement`);function bj(e,t){let n=ro(t);return()=>e.parser.action(n,t)}o(bj,`buildAction`);function xj(e,t){let n=t.rule.ref;if(Wn(n)){let r=e.subrule++,i=Xr(n)&&n.fragment,a=t.arguments.length>0?Sj(n,t.arguments):()=>({}),o;return s=>{o??=jj(e,n),e.parser.subrule(r,o,i,t,a(s))}}else if(gi(n)){let r=e.consume++,i=Nj(e,n.name);return()=>e.parser.consume(r,i,t)}else if(n)oa(n);else throw new aa(t.$cstNode,`Undefined rule: ${t.rule.$refText}`)}o(xj,`buildRuleCall`);function Sj(e,t){if(t.some(e=>e.calledByName)){let e=t.map(e=>({parameterName:e.parameter?.ref?.name,predicate:Cj(e.value)}));return t=>{let n={};for(let{parameterName:r,predicate:i}of e)r&&(n[r]=i(t));return n}}else{let n=t.map(e=>Cj(e.value));return t=>{let r={};for(let i=0;i<n.length;i++)if(i<e.parameters.length){let a=e.parameters[i].name,o=n[i];r[a]=o(t)}return r}}}o(Sj,`buildRuleCallPredicate`);function Cj(e){if(gr(e)){let t=Cj(e.left),n=Cj(e.right);return e=>t(e)||n(e)}else if(fr(e)){let t=Cj(e.left),n=Cj(e.right);return e=>t(e)&&n(e)}else if(Hr(e)){let t=Cj(e.value);return e=>!t(e)}else if(Jr(e)){let t=e.parameter.ref.name;return e=>e!==void 0&&e[t]===!0}else if(or(e)){let t=!!e.true;return()=>t}oa(e)}o(Cj,`buildPredicate`);function wj(e,t){if(t.elements.length===1)return yj(e,t.elements[0]);{let n=[];for(let r of t.elements){let t={ALT:yj(e,r,!0)},i=Dj(r);i&&(t.GATE=Cj(i)),n.push(t)}let r=e.or++;return t=>e.parser.alternatives(r,n.map(e=>{let n={ALT:o(()=>e.ALT(t),`ALT`)},r=e.GATE;return r&&(n.GATE=()=>r(t)),n}))}}o(wj,`buildAlternatives`);function Tj(e,t){if(t.elements.length===1)return yj(e,t.elements[0]);let n=[];for(let r of t.elements){let t={ALT:yj(e,r,!0)},i=Dj(r);i&&(t.GATE=Cj(i)),n.push(t)}let r=e.or++,i=o((e,t)=>`uGroup_${e}_${t.getRuleStack().join(`-`)}`,`idFunc`),a=o(t=>e.parser.alternatives(r,n.map((n,a)=>{let s={ALT:o(()=>!0,`ALT`)},c=e.parser;s.ALT=()=>{if(n.ALT(t),!c.isRecording()){let e=i(r,c);c.unorderedGroups.get(e)||c.unorderedGroups.set(e,[]);let t=c.unorderedGroups.get(e);t?.[a]===void 0&&(t[a]=!0)}};let l=n.GATE;return l?s.GATE=()=>l(t):s.GATE=()=>!c.unorderedGroups.get(i(r,c))?.[a],s})),`alternatives`),s=Aj(e,Dj(t),a,`*`);return t=>{s(t),e.parser.isRecording()||e.parser.unorderedGroups.delete(i(r,e.parser))}}o(Tj,`buildUnorderedGroup`);function Ej(e,t){let n=t.elements.map(t=>yj(e,t));return e=>n.forEach(t=>t(e))}o(Ej,`buildGroup`);function Dj(e){if(wr(e))return e.guardCondition}o(Dj,`getGuardCondition`);function Oj(e,t,n=t.terminal){if(!n){if(!t.type.ref)throw Error(`Could not resolve reference to type: `+t.type.$refText);let n=Ka(t.type.ref)?.terminal;if(!n)throw Error(`Could not find name assignment for type: `+ro(t.type.ref));return Oj(e,t,n)}else if(ii(n)&&Xr(n.rule.ref)){let r=n.rule.ref,i=e.subrule++,a;return n=>{a??=jj(e,r),e.parser.subrule(i,a,!1,t,n)}}else if(ii(n)&&gi(n.rule.ref)){let r=e.consume++,i=Nj(e,n.rule.ref.name);return()=>e.parser.consume(r,i,t)}else if(Ir(n)){let r=e.consume++,i=Nj(e,n.value);return()=>e.parser.consume(r,i,t)}else throw Error(`Could not build cross reference parser`)}o(Oj,`buildCrossReference`);function kj(e,t){let n=e.consume++,r=e.tokens[t.value];if(!r)throw Error(`Could not find token for keyword: `+t.value);return()=>e.parser.consume(n,r,t)}o(kj,`buildKeyword`);function Aj(e,t,n,r){let i=t&&Cj(t);if(!r)if(i){let t=e.or++;return r=>e.parser.alternatives(t,[{ALT:o(()=>n(r),`ALT`),GATE:o(()=>i(r),`GATE`)},{ALT:gS(),GATE:o(()=>!i(r),`GATE`)}])}else return n;if(r===`*`){let t=e.many++;return r=>e.parser.many(t,{DEF:o(()=>n(r),`DEF`),GATE:i?()=>i(r):void 0})}else if(r===`+`){let t=e.many++;if(i){let r=e.or++;return a=>e.parser.alternatives(r,[{ALT:o(()=>e.parser.atLeastOne(t,{DEF:o(()=>n(a),`DEF`)}),`ALT`),GATE:o(()=>i(a),`GATE`)},{ALT:gS(),GATE:o(()=>!i(a),`GATE`)}])}else return r=>e.parser.atLeastOne(t,{DEF:o(()=>n(r),`DEF`)})}else if(r===`?`){let t=e.optional++;return r=>e.parser.optional(t,{DEF:o(()=>n(r),`DEF`),GATE:i?()=>i(r):void 0})}else oa(r)}o(Aj,`wrap`);function jj(e,t){let n=Mj(e,t),r=e.parser.getRule(n);if(!r)throw Error(`Rule "${n}" not found."`);return r}o(jj,`getRule`);function Mj(e,t){if(Wn(t))return t.name;if(e.ruleNames.has(t))return e.ruleNames.get(t);{let n=t,r=n.$container,i=t.$type;for(;!Xr(r);)(wr(r)||Qn(r)||Oi(r))&&(i=r.elements.indexOf(n).toString()+`:`+i),n=r,r=r.$container;return i=r.name+`:`+i,e.ruleNames.set(t,i),i}}o(Mj,`getRuleName`);function Nj(e,t){let n=e.tokens[t];if(!n)throw Error(`Token "${t}" not found."`);return n}o(Nj,`getToken`);function Pj(e){let t=e.Grammar,n=e.parser.Lexer,r=new fj(e);return gj(t,r,n.definition),r.finalize(),r}o(Pj,`createCompletionParser`);function Fj(e){let t=Ij(e);return t.finalize(),t}o(Fj,`createLangiumParser`);function Ij(e){let t=e.Grammar,n=e.parser.Lexer;return gj(t,new lj(e),n.definition)}o(Ij,`prepareLangiumParser`);var Lj=class{static{o(this,`DefaultTokenBuilder`)}constructor(){this.diagnostics=[]}buildTokens(e,t){let n=M(Pa(e,!1)),r=this.buildTerminalTokens(n),i=this.buildKeywordTokens(n,r,t);return i.push(...r),i}flushLexingReport(e){return{diagnostics:this.popDiagnostics()}}popDiagnostics(){let e=[...this.diagnostics];return this.diagnostics=[],e}buildTerminalTokens(e){return e.filter(gi).filter(e=>!e.fragment).map(e=>this.buildTerminalToken(e)).toArray()}buildTerminalToken(e){let t=so(e),n=this.requiresCustomPattern(t)?this.regexPatternFunction(t):t,r={name:e.name,PATTERN:n};return typeof n==`function`&&(r.LINE_BREAKS=!0),e.hidden&&(r.GROUP=Oa(t)?Uy.SKIPPED:`hidden`),r}requiresCustomPattern(e){return!!(e.flags.includes(`u`)||e.flags.includes(`s`))}regexPatternFunction(e){let t=new RegExp(e,e.flags+`y`);return(e,n)=>(t.lastIndex=n,t.exec(e))}buildKeywordTokens(e,t,n){return e.filter(Wn).flatMap(e=>Mn(e).filter(Ir)).distinct(e=>e.value).toArray().sort((e,t)=>t.value.length-e.value.length).map(e=>this.buildKeywordToken(e,t,!!n?.caseInsensitive))}buildKeywordToken(e,t,n){let r=this.buildKeywordPattern(e,n),i={name:e.value,PATTERN:r,LONGER_ALT:this.findLongerAlt(e,t)};return typeof r==`function`&&(i.LINE_BREAKS=!0),i}buildKeywordPattern(e,t){return t?new RegExp(ka(e.value),`i`):e.value}findLongerAlt(e,t){return t.reduce((t,n)=>{let r=n?.PATTERN;return r?.source&&Aa(`^`+r.source+`$`,e.value)&&t.push(n),t},[])}},Rj=class{static{o(this,`DefaultValueConverter`)}convert(e,t){let n=t.grammarSource;if(mr(n)&&(n=La(n)),ii(n)){let r=n.rule.ref;if(!r)throw Error(`This cst node was not parsed by a rule.`);return this.runConverter(r,e,t)}return e}runConverter(e,t,n){switch(e.name.toUpperCase()){case`INT`:return zj.convertInt(t);case`STRING`:return zj.convertString(t);case`ID`:return zj.convertID(t)}switch(oo(e)?.toLowerCase()){case`number`:return zj.convertNumber(t);case`boolean`:return zj.convertBoolean(t);case`bigint`:return zj.convertBigint(t);case`date`:return zj.convertDate(t);default:return t}}},zj;(function(e){function t(e){let t=``;for(let r=1;r<e.length-1;r++){let i=e.charAt(r);if(i===`\\`){let i=e.charAt(++r);t+=n(i)}else t+=i}return t}o(t,`convertString`),e.convertString=t;function n(e){switch(e){case`b`:return`\b`;case`f`:return`\f`;case`n`:return`
149
+ `;case`r`:return`\r`;case`t`:return` `;case`v`:return`\v`;case`0`:return`\0`;default:return e}}o(n,`convertEscapeCharacter`);function r(e){return e.charAt(0)===`^`?e.substring(1):e}o(r,`convertID`),e.convertID=r;function i(e){return parseInt(e)}o(i,`convertInt`),e.convertInt=i;function a(e){return BigInt(e)}o(a,`convertBigint`),e.convertBigint=a;function s(e){return new Date(e)}o(s,`convertDate`),e.convertDate=s;function c(e){return Number(e)}o(c,`convertNumber`),e.convertNumber=c;function l(e){return e.toLowerCase()===`true`}o(l,`convertBoolean`),e.convertBoolean=l})(zj||={});var Z={};d(Z,f(bt(),1));function Bj(){return new Promise(e=>{typeof setImmediate>`u`?setTimeout(e,0):setImmediate(e)})}o(Bj,`delayNextTick`);var Vj=0,Hj=10;function Uj(){return Vj=performance.now(),new Z.CancellationTokenSource}o(Uj,`startCancelableOperation`);function Wj(e){Hj=e}o(Wj,`setInterruptionPeriod`);var Gj=Symbol(`OperationCancelled`);function Kj(e){return e===Gj}o(Kj,`isOperationCancelled`);async function Q(e){if(e===Z.CancellationToken.None)return;let t=performance.now();if(t-Vj>=Hj&&(Vj=t,await Bj(),Vj=performance.now()),e.isCancellationRequested)throw Gj}o(Q,`interruptAndCheck`);var qj=class{static{o(this,`Deferred`)}constructor(){this.promise=new Promise((e,t)=>{this.resolve=t=>(e(t),this),this.reject=e=>(t(e),this)})}},Jj=class e{static{o(this,`FullTextDocument`)}constructor(e,t,n,r){this._uri=e,this._languageId=t,this._version=n,this._content=r,this._lineOffsets=void 0}get uri(){return this._uri}get languageId(){return this._languageId}get version(){return this._version}getText(e){if(e){let t=this.offsetAt(e.start),n=this.offsetAt(e.end);return this._content.substring(t,n)}return this._content}update(t,n){for(let n of t)if(e.isIncremental(n)){let e=$j(n.range),t=this.offsetAt(e.start),r=this.offsetAt(e.end);this._content=this._content.substring(0,t)+n.text+this._content.substring(r,this._content.length);let i=Math.max(e.start.line,0),a=Math.max(e.end.line,0),o=this._lineOffsets,s=Zj(n.text,!1,t);if(a-i===s.length)for(let e=0,t=s.length;e<t;e++)o[e+i+1]=s[e];else s.length<1e4?o.splice(i+1,a-i,...s):this._lineOffsets=o=o.slice(0,i+1).concat(s,o.slice(a+1));let c=n.text.length-(r-t);if(c!==0)for(let e=i+1+s.length,t=o.length;e<t;e++)o[e]=o[e]+c}else if(e.isFull(n))this._content=n.text,this._lineOffsets=void 0;else throw Error(`Unknown change event received`);this._version=n}getLineOffsets(){return this._lineOffsets===void 0&&(this._lineOffsets=Zj(this._content,!0)),this._lineOffsets}positionAt(e){e=Math.max(Math.min(e,this._content.length),0);let t=this.getLineOffsets(),n=0,r=t.length;if(r===0)return{line:0,character:e};for(;n<r;){let i=Math.floor((n+r)/2);t[i]>e?r=i:n=i+1}let i=n-1;return e=this.ensureBeforeEOL(e,t[i]),{line:i,character:e-t[i]}}offsetAt(e){let t=this.getLineOffsets();if(e.line>=t.length)return this._content.length;if(e.line<0)return 0;let n=t[e.line];if(e.character<=0)return n;let r=e.line+1<t.length?t[e.line+1]:this._content.length,i=Math.min(n+e.character,r);return this.ensureBeforeEOL(i,n)}ensureBeforeEOL(e,t){for(;e>t&&Qj(this._content.charCodeAt(e-1));)e--;return e}get lineCount(){return this.getLineOffsets().length}static isIncremental(e){let t=e;return t!=null&&typeof t.text==`string`&&t.range!==void 0&&(t.rangeLength===void 0||typeof t.rangeLength==`number`)}static isFull(e){let t=e;return t!=null&&typeof t.text==`string`&&t.range===void 0&&t.rangeLength===void 0}},Yj;(function(e){function t(e,t,n,r){return new Jj(e,t,n,r)}o(t,`create`),e.create=t;function n(e,t,n){if(e instanceof Jj)return e.update(t,n),e;throw Error(`TextDocument.update: document must be created by TextDocument.create`)}o(n,`update`),e.update=n;function r(e,t){let n=e.getText(),r=Xj(t.map(eM),(e,t)=>{let n=e.range.start.line-t.range.start.line;return n===0?e.range.start.character-t.range.start.character:n}),i=0,a=[];for(let t of r){let r=e.offsetAt(t.range.start);if(r<i)throw Error(`Overlapping edit`);r>i&&a.push(n.substring(i,r)),t.newText.length&&a.push(t.newText),i=e.offsetAt(t.range.end)}return a.push(n.substr(i)),a.join(``)}o(r,`applyEdits`),e.applyEdits=r})(Yj||={});function Xj(e,t){if(e.length<=1)return e;let n=e.length/2|0,r=e.slice(0,n),i=e.slice(n);Xj(r,t),Xj(i,t);let a=0,o=0,s=0;for(;a<r.length&&o<i.length;)t(r[a],i[o])<=0?e[s++]=r[a++]:e[s++]=i[o++];for(;a<r.length;)e[s++]=r[a++];for(;o<i.length;)e[s++]=i[o++];return e}o(Xj,`mergeSort`);function Zj(e,t,n=0){let r=t?[n]:[];for(let t=0;t<e.length;t++){let i=e.charCodeAt(t);Qj(i)&&(i===13&&t+1<e.length&&e.charCodeAt(t+1)===10&&t++,r.push(n+t+1))}return r}o(Zj,`computeLineOffsets`);function Qj(e){return e===13||e===10}o(Qj,`isEOL`);function $j(e){let t=e.start,n=e.end;return t.line>n.line||t.line===n.line&&t.character>n.character?{start:n,end:t}:e}o($j,`getWellformedRange`);function eM(e){let t=$j(e.range);return t===e.range?e:{newText:e.newText,range:t}}o(eM,`getWellformedEdit`);var tM;(()=>{var e={975:e=>{function t(e){if(typeof e!=`string`)throw TypeError(`Path must be a string. Received `+JSON.stringify(e))}o(t,`e`);function n(e,t){for(var n,r=``,i=0,a=-1,o=0,s=0;s<=e.length;++s){if(s<e.length)n=e.charCodeAt(s);else{if(n===47)break;n=47}if(n===47){if(!(a===s-1||o===1))if(a!==s-1&&o===2){if(r.length<2||i!==2||r.charCodeAt(r.length-1)!==46||r.charCodeAt(r.length-2)!==46){if(r.length>2){var c=r.lastIndexOf(`/`);if(c!==r.length-1){c===-1?(r=``,i=0):i=(r=r.slice(0,c)).length-1-r.lastIndexOf(`/`),a=s,o=0;continue}}else if(r.length===2||r.length===1){r=``,i=0,a=s,o=0;continue}}t&&(r.length>0?r+=`/..`:r=`..`,i=2)}else r.length>0?r+=`/`+e.slice(a+1,s):r=e.slice(a+1,s),i=s-a-1;a=s,o=0}else n===46&&o!==-1?++o:o=-1}return r}o(n,`r`);var r={resolve:o(function(){for(var e,r=``,i=!1,a=arguments.length-1;a>=-1&&!i;a--){var o;a>=0?o=arguments[a]:(e===void 0&&(e=process.cwd()),o=e),t(o),o.length!==0&&(r=o+`/`+r,i=o.charCodeAt(0)===47)}return r=n(r,!i),i?r.length>0?`/`+r:`/`:r.length>0?r:`.`},`resolve`),normalize:o(function(e){if(t(e),e.length===0)return`.`;var r=e.charCodeAt(0)===47,i=e.charCodeAt(e.length-1)===47;return(e=n(e,!r)).length!==0||r||(e=`.`),e.length>0&&i&&(e+=`/`),r?`/`+e:e},`normalize`),isAbsolute:o(function(e){return t(e),e.length>0&&e.charCodeAt(0)===47},`isAbsolute`),join:o(function(){if(arguments.length===0)return`.`;for(var e,n=0;n<arguments.length;++n){var i=arguments[n];t(i),i.length>0&&(e===void 0?e=i:e+=`/`+i)}return e===void 0?`.`:r.normalize(e)},`join`),relative:o(function(e,n){if(t(e),t(n),e===n||(e=r.resolve(e))===(n=r.resolve(n)))return``;for(var i=1;i<e.length&&e.charCodeAt(i)===47;++i);for(var a=e.length,o=a-i,s=1;s<n.length&&n.charCodeAt(s)===47;++s);for(var c=n.length-s,l=o<c?o:c,u=-1,d=0;d<=l;++d){if(d===l){if(c>l){if(n.charCodeAt(s+d)===47)return n.slice(s+d+1);if(d===0)return n.slice(s+d)}else o>l&&(e.charCodeAt(i+d)===47?u=d:d===0&&(u=0));break}var f=e.charCodeAt(i+d);if(f!==n.charCodeAt(s+d))break;f===47&&(u=d)}var p=``;for(d=i+u+1;d<=a;++d)d!==a&&e.charCodeAt(d)!==47||(p.length===0?p+=`..`:p+=`/..`);return p.length>0?p+n.slice(s+u):(s+=u,n.charCodeAt(s)===47&&++s,n.slice(s))},`relative`),_makeLong:o(function(e){return e},`_makeLong`),dirname:o(function(e){if(t(e),e.length===0)return`.`;for(var n=e.charCodeAt(0),r=n===47,i=-1,a=!0,o=e.length-1;o>=1;--o)if((n=e.charCodeAt(o))===47){if(!a){i=o;break}}else a=!1;return i===-1?r?`/`:`.`:r&&i===1?`//`:e.slice(0,i)},`dirname`),basename:o(function(e,n){if(n!==void 0&&typeof n!=`string`)throw TypeError(`"ext" argument must be a string`);t(e);var r,i=0,a=-1,o=!0;if(n!==void 0&&n.length>0&&n.length<=e.length){if(n.length===e.length&&n===e)return``;var s=n.length-1,c=-1;for(r=e.length-1;r>=0;--r){var l=e.charCodeAt(r);if(l===47){if(!o){i=r+1;break}}else c===-1&&(o=!1,c=r+1),s>=0&&(l===n.charCodeAt(s)?--s==-1&&(a=r):(s=-1,a=c))}return i===a?a=c:a===-1&&(a=e.length),e.slice(i,a)}for(r=e.length-1;r>=0;--r)if(e.charCodeAt(r)===47){if(!o){i=r+1;break}}else a===-1&&(o=!1,a=r+1);return a===-1?``:e.slice(i,a)},`basename`),extname:o(function(e){t(e);for(var n=-1,r=0,i=-1,a=!0,o=0,s=e.length-1;s>=0;--s){var c=e.charCodeAt(s);if(c!==47)i===-1&&(a=!1,i=s+1),c===46?n===-1?n=s:o!==1&&(o=1):n!==-1&&(o=-1);else if(!a){r=s+1;break}}return n===-1||i===-1||o===0||o===1&&n===i-1&&n===r+1?``:e.slice(n,i)},`extname`),format:o(function(e){if(typeof e!=`object`||!e)throw TypeError(`The "pathObject" argument must be of type Object. Received type `+typeof e);return(function(e,t){var n=t.dir||t.root,r=t.base||(t.name||``)+(t.ext||``);return n?n===t.root?n+r:n+`/`+r:r})(0,e)},`format`),parse:o(function(e){t(e);var n={root:``,dir:``,base:``,ext:``,name:``};if(e.length===0)return n;var r,i=e.charCodeAt(0),a=i===47;a?(n.root=`/`,r=1):r=0;for(var o=-1,s=0,c=-1,l=!0,u=e.length-1,d=0;u>=r;--u)if((i=e.charCodeAt(u))!==47)c===-1&&(l=!1,c=u+1),i===46?o===-1?o=u:d!==1&&(d=1):o!==-1&&(d=-1);else if(!l){s=u+1;break}return o===-1||c===-1||d===0||d===1&&o===c-1&&o===s+1?c!==-1&&(n.base=n.name=s===0&&a?e.slice(1,c):e.slice(s,c)):(s===0&&a?(n.name=e.slice(1,o),n.base=e.slice(1,c)):(n.name=e.slice(s,o),n.base=e.slice(s,c)),n.ext=e.slice(o,c)),s>0?n.dir=e.slice(0,s-1):a&&(n.dir=`/`),n},`parse`),sep:`/`,delimiter:`:`,win32:null,posix:null};r.posix=r,e.exports=r}},t={};function n(r){var i=t[r];if(i!==void 0)return i.exports;var a=t[r]={exports:{}};return e[r](a,a.exports,n),a.exports}o(n,`r`),n.d=(e,t)=>{for(var r in t)n.o(t,r)&&!n.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},n.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),n.r=e=>{typeof Symbol<`u`&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:`Module`}),Object.defineProperty(e,`__esModule`,{value:!0})};var r={};let i;n.r(r),n.d(r,{URI:o(()=>d,`URI`),Utils:o(()=>te,`Utils`)}),typeof process==`object`?i=process.platform===`win32`:typeof navigator==`object`&&(i=navigator.userAgent.indexOf(`Windows`)>=0);let a=/^\w[\w\d+.-]*$/,s=/^\//,c=/^\/\//;function l(e,t){if(!e.scheme&&t)throw Error(`[UriError]: Scheme is missing: {scheme: "", authority: "${e.authority}", path: "${e.path}", query: "${e.query}", fragment: "${e.fragment}"}`);if(e.scheme&&!a.test(e.scheme))throw Error(`[UriError]: Scheme contains illegal characters.`);if(e.path){if(e.authority){if(!s.test(e.path))throw Error(`[UriError]: If a URI contains an authority component, then the path component must either be empty or begin with a slash ("/") character`)}else if(c.test(e.path))throw Error(`[UriError]: If a URI does not contain an authority component, then the path cannot begin with two slash characters ("//")`)}}o(l,`a`);let u=/^(([^:/?#]+?):)?(\/\/([^/?#]*))?([^?#]*)(\?([^#]*))?(#(.*))?/;class d{static{o(this,`l`)}static isUri(e){return e instanceof d||!!e&&typeof e.authority==`string`&&typeof e.fragment==`string`&&typeof e.path==`string`&&typeof e.query==`string`&&typeof e.scheme==`string`&&typeof e.fsPath==`string`&&typeof e.with==`function`&&typeof e.toString==`function`}scheme;authority;path;query;fragment;constructor(e,t,n,r,i,a=!1){typeof e==`object`?(this.scheme=e.scheme||``,this.authority=e.authority||``,this.path=e.path||``,this.query=e.query||``,this.fragment=e.fragment||``):(this.scheme=(function(e,t){return e||t?e:`file`})(e,a),this.authority=t||``,this.path=(function(e,t){switch(e){case`https`:case`http`:case`file`:t?t[0]!==`/`&&(t=`/`+t):t=`/`}return t})(this.scheme,n||``),this.query=r||``,this.fragment=i||``,l(this,a))}get fsPath(){return _(this,!1)}with(e){if(!e)return this;let{scheme:t,authority:n,path:r,query:i,fragment:a}=e;return t===void 0?t=this.scheme:t===null&&(t=``),n===void 0?n=this.authority:n===null&&(n=``),r===void 0?r=this.path:r===null&&(r=``),i===void 0?i=this.query:i===null&&(i=``),a===void 0?a=this.fragment:a===null&&(a=``),t===this.scheme&&n===this.authority&&r===this.path&&i===this.query&&a===this.fragment?this:new p(t,n,r,i,a)}static parse(e,t=!1){let n=u.exec(e);return n?new p(n[2]||``,x(n[4]||``),x(n[5]||``),x(n[7]||``),x(n[9]||``),t):new p(``,``,``,``,``)}static file(e){let t=``;if(i&&(e=e.replace(/\\/g,`/`)),e[0]===`/`&&e[1]===`/`){let n=e.indexOf(`/`,2);n===-1?(t=e.substring(2),e=`/`):(t=e.substring(2,n),e=e.substring(n)||`/`)}return new p(`file`,t,e,``,``)}static from(e){let t=new p(e.scheme,e.authority,e.path,e.query,e.fragment);return l(t,!0),t}toString(e=!1){return v(this,e)}toJSON(){return this}static revive(e){if(e){if(e instanceof d)return e;{let t=new p(e);return t._formatted=e.external,t._fsPath=e._sep===f?e.fsPath:null,t}}return e}}let f=i?1:void 0;class p extends d{static{o(this,`d`)}_formatted=null;_fsPath=null;get fsPath(){return this._fsPath||=_(this,!1),this._fsPath}toString(e=!1){return e?v(this,!0):(this._formatted||=v(this,!1),this._formatted)}toJSON(){let e={$mid:1};return this._fsPath&&(e.fsPath=this._fsPath,e._sep=f),this._formatted&&(e.external=this._formatted),this.path&&(e.path=this.path),this.scheme&&(e.scheme=this.scheme),this.authority&&(e.authority=this.authority),this.query&&(e.query=this.query),this.fragment&&(e.fragment=this.fragment),e}}let m={58:`%3A`,47:`%2F`,63:`%3F`,35:`%23`,91:`%5B`,93:`%5D`,64:`%40`,33:`%21`,36:`%24`,38:`%26`,39:`%27`,40:`%28`,41:`%29`,42:`%2A`,43:`%2B`,44:`%2C`,59:`%3B`,61:`%3D`,32:`%20`};function h(e,t,n){let r,i=-1;for(let a=0;a<e.length;a++){let o=e.charCodeAt(a);if(o>=97&&o<=122||o>=65&&o<=90||o>=48&&o<=57||o===45||o===46||o===95||o===126||t&&o===47||n&&o===91||n&&o===93||n&&o===58)i!==-1&&(r+=encodeURIComponent(e.substring(i,a)),i=-1),r!==void 0&&(r+=e.charAt(a));else{r===void 0&&(r=e.substr(0,a));let t=m[o];t===void 0?i===-1&&(i=a):(i!==-1&&(r+=encodeURIComponent(e.substring(i,a)),i=-1),r+=t)}}return i!==-1&&(r+=encodeURIComponent(e.substring(i))),r===void 0?e:r}o(h,`m`);function g(e){let t;for(let n=0;n<e.length;n++){let r=e.charCodeAt(n);r===35||r===63?(t===void 0&&(t=e.substr(0,n)),t+=m[r]):t!==void 0&&(t+=e[n])}return t===void 0?e:t}o(g,`y`);function _(e,t){let n;return n=e.authority&&e.path.length>1&&e.scheme===`file`?`//${e.authority}${e.path}`:e.path.charCodeAt(0)===47&&(e.path.charCodeAt(1)>=65&&e.path.charCodeAt(1)<=90||e.path.charCodeAt(1)>=97&&e.path.charCodeAt(1)<=122)&&e.path.charCodeAt(2)===58?t?e.path.substr(1):e.path[1].toLowerCase()+e.path.substr(2):e.path,i&&(n=n.replace(/\//g,`\\`)),n}o(_,`v`);function v(e,t){let n=t?g:h,r=``,{scheme:i,authority:a,path:o,query:s,fragment:c}=e;if(i&&(r+=i,r+=`:`),(a||i===`file`)&&(r+=`/`,r+=`/`),a){let e=a.indexOf(`@`);if(e!==-1){let t=a.substr(0,e);a=a.substr(e+1),e=t.lastIndexOf(`:`),e===-1?r+=n(t,!1,!1):(r+=n(t.substr(0,e),!1,!1),r+=`:`,r+=n(t.substr(e+1),!1,!0)),r+=`@`}a=a.toLowerCase(),e=a.lastIndexOf(`:`),e===-1?r+=n(a,!1,!0):(r+=n(a.substr(0,e),!1,!0),r+=a.substr(e))}if(o){if(o.length>=3&&o.charCodeAt(0)===47&&o.charCodeAt(2)===58){let e=o.charCodeAt(1);e>=65&&e<=90&&(o=`/${String.fromCharCode(e+32)}:${o.substr(3)}`)}else if(o.length>=2&&o.charCodeAt(1)===58){let e=o.charCodeAt(0);e>=65&&e<=90&&(o=`${String.fromCharCode(e+32)}:${o.substr(2)}`)}r+=n(o,!0,!1)}return s&&(r+=`?`,r+=n(s,!1,!1)),c&&(r+=`#`,r+=t?c:h(c,!1,!1)),r}o(v,`b`);function y(e){try{return decodeURIComponent(e)}catch{return e.length>3?e.substr(0,3)+y(e.substr(3)):e}}o(y,`C`);let b=/(%[0-9A-Za-z][0-9A-Za-z])+/g;function x(e){return e.match(b)?e.replace(b,(e=>y(e))):e}o(x,`w`);var ee=n(975);let S=ee.posix||ee;var te;(function(e){e.joinPath=function(e,...t){return e.with({path:S.join(e.path,...t)})},e.resolvePath=function(e,...t){let n=e.path,r=!1;n[0]!==`/`&&(n=`/`+n,r=!0);let i=S.resolve(n,...t);return r&&i[0]===`/`&&!e.authority&&(i=i.substring(1)),e.with({path:i})},e.dirname=function(e){if(e.path.length===0||e.path===`/`)return e;let t=S.dirname(e.path);return t.length===1&&t.charCodeAt(0)===46&&(t=``),e.with({path:t})},e.basename=function(e){return S.basename(e.path)},e.extname=function(e){return S.extname(e.path)}})(te||={}),tM=r})();var{URI:nM,Utils:rM}=tM,iM;(function(e){e.basename=rM.basename,e.dirname=rM.dirname,e.extname=rM.extname,e.joinPath=rM.joinPath,e.resolvePath=rM.resolvePath;let t=typeof process==`object`&&process?.platform===`win32`;function n(e,t){return e?.toString()===t?.toString()}o(n,`equals`),e.equals=n;function r(e,n){let r=typeof e==`string`?nM.parse(e).path:e.path,i=typeof n==`string`?nM.parse(n).path:n.path,a=r.split(`/`).filter(e=>e.length>0),o=i.split(`/`).filter(e=>e.length>0);if(t){let e=/^[A-Z]:$/;if(a[0]&&e.test(a[0])&&(a[0]=a[0].toLowerCase()),o[0]&&e.test(o[0])&&(o[0]=o[0].toLowerCase()),a[0]!==o[0])return i.substring(1)}let s=0;for(;s<a.length&&a[s]===o[s];s++);return`../`.repeat(a.length-s)+o.slice(s).join(`/`)}o(r,`relative`),e.relative=r;function i(e){return nM.parse(e.toString()).toString()}o(i,`normalize`),e.normalize=i;function a(e,t){let n=typeof e==`string`?e:e.path,r=typeof t==`string`?t:t.path;return r.charAt(r.length-1)===`/`&&(r=r.slice(0,-1)),n.charAt(n.length-1)===`/`&&(n=n.slice(0,-1)),r===n?!0:r.length<n.length||r.charAt(n.length)!==`/`?!1:r.startsWith(n)}o(a,`contains`),e.contains=a})(iM||={});var aM=class{static{o(this,`UriTrie`)}constructor(){this.root={name:``,children:new Map}}normalizeUri(e){return iM.normalize(e)}clear(){this.root.children.clear()}insert(e,t){let n=this.getNode(this.normalizeUri(e),!0);n.element=t}delete(e){let t=this.getNode(this.normalizeUri(e),!1);t?.parent&&t.parent.children.delete(t.name)}has(e){return this.getNode(this.normalizeUri(e),!1)?.element!==void 0}hasNode(e){return this.getNode(this.normalizeUri(e),!1)!==void 0}find(e){return this.getNode(this.normalizeUri(e),!1)?.element}findNode(e){let t=this.normalizeUri(e),n=this.getNode(t,!1);if(n)return{name:n.name,uri:iM.joinPath(nM.parse(t),n.name).toString(),element:n.element}}findChildren(e){let t=this.normalizeUri(e),n=this.getNode(t,!1);return n?Array.from(n.children.values()).map(e=>({name:e.name,uri:iM.joinPath(nM.parse(t),e.name).toString(),element:e.element})):[]}all(){return this.collectValues(this.root)}findAll(e){let t=this.getNode(iM.normalize(e),!1);return t?this.collectValues(t):[]}getNode(e,t){let n=e.split(`/`);e.charAt(e.length-1)===`/`&&n.pop();let r=this.root;for(let e of n){let n=r.children.get(e);if(!n)if(t)n={name:e,children:new Map,parent:r},r.children.set(e,n);else return;r=n}return r}collectValues(e){let t=[];e.element&&t.push(e.element);for(let n of e.children.values())t.push(...this.collectValues(n));return t}},$;(function(e){e[e.Changed=0]=`Changed`,e[e.Parsed=1]=`Parsed`,e[e.IndexedContent=2]=`IndexedContent`,e[e.ComputedScopes=3]=`ComputedScopes`,e[e.Linked=4]=`Linked`,e[e.IndexedReferences=5]=`IndexedReferences`,e[e.Validated=6]=`Validated`})($||={});var oM=class{static{o(this,`DefaultLangiumDocumentFactory`)}constructor(e){this.serviceRegistry=e.ServiceRegistry,this.textDocuments=e.workspace.TextDocuments,this.fileSystemProvider=e.workspace.FileSystemProvider}async fromUri(e,t=Z.CancellationToken.None){let n=await this.fileSystemProvider.readFile(e);return this.createAsync(e,n,t)}fromTextDocument(e,t,n){return t??=nM.parse(e.uri),Z.CancellationToken.is(n)?this.createAsync(t,e,n):this.create(t,e,n)}fromString(e,t,n){return Z.CancellationToken.is(n)?this.createAsync(t,e,n):this.create(t,e,n)}fromModel(e,t){return this.create(t,{$model:e})}create(e,t,n){if(typeof t==`string`){let r=this.parse(e,t,n);return this.createLangiumDocument(r,e,void 0,t)}else if(`$model`in t){let n={value:t.$model,parserErrors:[],lexerErrors:[]};return this.createLangiumDocument(n,e)}else{let r=this.parse(e,t.getText(),n);return this.createLangiumDocument(r,e,t)}}async createAsync(e,t,n){if(typeof t==`string`){let r=await this.parseAsync(e,t,n);return this.createLangiumDocument(r,e,void 0,t)}else{let r=await this.parseAsync(e,t.getText(),n);return this.createLangiumDocument(r,e,t)}}createLangiumDocument(e,t,n,r){let i;if(n)i={parseResult:e,uri:t,state:$.Parsed,references:[],textDocument:n};else{let n=this.createTextDocumentGetter(t,r);i={parseResult:e,uri:t,state:$.Parsed,references:[],get textDocument(){return n()}}}return e.value.$document=i,i}async update(e,t){let n=e.parseResult.value.$cstNode?.root.fullText,r=this.textDocuments?.get(e.uri.toString()),i=r?r.getText():await this.fileSystemProvider.readFile(e.uri);if(r)Object.defineProperty(e,`textDocument`,{value:r});else{let t=this.createTextDocumentGetter(e.uri,i);Object.defineProperty(e,`textDocument`,{get:t})}return n!==i&&(e.parseResult=await this.parseAsync(e.uri,i,t),e.parseResult.value.$document=e),e.state=$.Parsed,e}parse(e,t,n){return this.serviceRegistry.getServices(e).parser.LangiumParser.parse(t,n)}parseAsync(e,t,n){return this.serviceRegistry.getServices(e).parser.AsyncParser.parse(t,n)}createTextDocumentGetter(e,t){let n=this.serviceRegistry,r;return()=>r??=Yj.create(e.toString(),n.getServices(e).LanguageMetaData.languageId,0,t??``)}},sM=class{static{o(this,`DefaultLangiumDocuments`)}constructor(e){this.documentTrie=new aM,this.services=e,this.langiumDocumentFactory=e.workspace.LangiumDocumentFactory,this.documentBuilder=()=>e.workspace.DocumentBuilder}get all(){return M(this.documentTrie.all())}addDocument(e){let t=e.uri.toString();if(this.documentTrie.has(t))throw Error(`A document with the URI '${t}' is already present.`);this.documentTrie.insert(t,e)}getDocument(e){let t=e.toString();return this.documentTrie.find(t)}getDocuments(e){let t=e.toString();return this.documentTrie.findAll(t)}async getOrCreateDocument(e,t){let n=this.getDocument(e);return n||(n=await this.langiumDocumentFactory.fromUri(e,t),this.addDocument(n),n)}createDocument(e,t,n){if(n)return this.langiumDocumentFactory.fromString(t,e,n).then(e=>(this.addDocument(e),e));{let n=this.langiumDocumentFactory.fromString(t,e);return this.addDocument(n),n}}hasDocument(e){return this.documentTrie.has(e.toString())}invalidateDocument(e){let t=e.toString(),n=this.documentTrie.find(t);return n&&this.documentBuilder().resetToState(n,$.Changed),n}deleteDocument(e){let t=e.toString(),n=this.documentTrie.find(t);return n&&(n.state=$.Changed,this.documentTrie.delete(t)),n}deleteDocuments(e){let t=e.toString(),n=this.documentTrie.findAll(t);for(let e of n)e.state=$.Changed;return this.documentTrie.delete(t),n}},cM=Symbol(`RefResolving`),lM=class{static{o(this,`DefaultLinker`)}constructor(e){this.reflection=e.shared.AstReflection,this.langiumDocuments=()=>e.shared.workspace.LangiumDocuments,this.scopeProvider=e.references.ScopeProvider,this.astNodeLocator=e.workspace.AstNodeLocator,this.profiler=e.shared.profilers.LangiumProfiler,this.languageId=e.LanguageMetaData.languageId}async link(e,t=Z.CancellationToken.None){if(this.profiler?.isActive(`linking`)){let n=this.profiler.createTask(`linking`,this.languageId);n.start();try{for(let r of Nn(e.parseResult.value))await Q(t),Fn(r).forEach(t=>{let i=`${r.$type}:${t.property}`;n.startSubTask(i);try{this.doLink(t,e)}finally{n.stopSubTask(i)}})}finally{n.stop()}}else for(let n of Nn(e.parseResult.value))await Q(t),Fn(n).forEach(t=>this.doLink(t,e))}doLink(e,t){let n=e.reference;if(`_ref`in n&&n._ref===void 0){n._ref=cM;try{let t=this.getCandidate(e);fn(t)?n._ref=t:(n._nodeDescription=t,n._ref=this.loadAstNode(t)??this.createLinkingError(e,t))}catch(t){console.error(`An error occurred while resolving reference to '${n.$refText}':`,t);let r=t.message??String(t);n._ref={info:e,message:`An error occurred while resolving reference to '${n.$refText}': ${r}`}}t.references.push(n)}else if(`_items`in n&&n._items===void 0){n._items=cM;try{let t=this.getCandidates(e),r=[];if(fn(t))n._linkingError=t;else for(let e of t){let t=this.loadAstNode(e);t&&r.push({ref:t,$nodeDescription:e})}n._items=r}catch(t){n._linkingError={info:e,message:`An error occurred while resolving reference to '${n.$refText}': ${t}`},n._items=[]}t.references.push(n)}}unlink(e){for(let t of e.references)`_ref`in t?(t._ref=void 0,delete t._nodeDescription):`_items`in t&&(t._items=void 0,delete t._linkingError);e.references=[]}getCandidate(e){return this.scopeProvider.getScope(e).getElement(e.reference.$refText)??this.createLinkingError(e)}getCandidates(e){let t=this.scopeProvider.getScope(e).getElements(e.reference.$refText).distinct(e=>`${e.documentUri}#${e.path}`).toArray();return t.length>0?t:this.createLinkingError(e)}buildReference(e,t,n,r){let i=this,a={$refNode:n,$refText:r,_ref:void 0,get ref(){if(j(this._ref))return this._ref;if(dn(this._nodeDescription)){let n=i.loadAstNode(this._nodeDescription);this._ref=n??i.createLinkingError({reference:a,container:e,property:t},this._nodeDescription)}else if(this._ref===void 0){this._ref=cM;let n=kn(e).$document,r=i.getLinkedNode({reference:a,container:e,property:t});if(r.error&&n&&n.state<$.ComputedScopes){this._ref=void 0;return}this._ref=r.node??r.error,this._nodeDescription=r.descr,n?.references.push(this)}else this._ref===cM&&i.throwCyclicReferenceError(e,t,r);return j(this._ref)?this._ref:void 0},get $nodeDescription(){return this._nodeDescription},get error(){return fn(this._ref)?this._ref:void 0}};return a}buildMultiReference(e,t,n,r){let i=this,a={$refNode:n,$refText:r,_items:void 0,get items(){if(Array.isArray(this._items))return this._items;if(this._items===void 0){this._items=cM;let n=kn(e).$document,r=i.getCandidates({reference:a,container:e,property:t}),o=[];if(fn(r))this._linkingError=r;else for(let e of r){let t=i.loadAstNode(e);t&&o.push({ref:t,$nodeDescription:e})}this._items=o,n?.references.push(this)}else this._items===cM&&i.throwCyclicReferenceError(e,t,r);return Array.isArray(this._items)?this._items:[]},get error(){if(this._linkingError)return this._linkingError;if(!(this.items.length>0))return this._linkingError=i.createLinkingError({reference:a,container:e,property:t})}};return a}throwCyclicReferenceError(e,t,n){throw Error(`Cyclic reference resolution detected: ${this.astNodeLocator.getAstNodePath(e)}/${t} (symbol '${n}')`)}getLinkedNode(e){try{let t=this.getCandidate(e);if(fn(t))return{error:t};let n=this.loadAstNode(t);return n?{node:n,descr:t}:{descr:t,error:this.createLinkingError(e,t)}}catch(t){console.error(`An error occurred while resolving reference to '${e.reference.$refText}':`,t);let n=t.message??String(t);return{error:{info:e,message:`An error occurred while resolving reference to '${e.reference.$refText}': ${n}`}}}}loadAstNode(e){if(e.node)return e.node;let t=this.langiumDocuments().getDocument(e.documentUri);if(t)return this.astNodeLocator.getAstNode(t.parseResult.value,e.path)}createLinkingError(e,t){let n=kn(e.container).$document;return n&&n.state<$.ComputedScopes&&console.warn(`Attempted reference resolution before document reached ComputedScopes state (${n.uri}).`),{info:e,message:`Could not resolve reference to ${this.reflection.getReferenceType(e)} named '${e.reference.$refText}'.`,targetDescription:t}}};function uM(e){return typeof e.name==`string`}o(uM,`isNamed`);var dM=class{static{o(this,`DefaultNameProvider`)}getName(e){if(uM(e))return e.name}getNameNode(e){return Ba(e.$cstNode,`name`)}},fM=class{static{o(this,`DefaultReferences`)}constructor(e){this.nameProvider=e.references.NameProvider,this.index=e.shared.workspace.IndexManager,this.nodeLocator=e.workspace.AstNodeLocator,this.documents=e.shared.workspace.LangiumDocuments,this.hasMultiReference=Nn(e.Grammar).some(e=>mr(e)&&e.isMulti)}findDeclarations(e){if(e){let t=Ga(e),n=e.astNode;if(t&&n){let r=n[t.feature];if(ln(r)||un(r))return An(r);if(Array.isArray(r)){for(let t of r)if((ln(t)||un(t))&&t.$refNode&&t.$refNode.offset<=e.offset&&t.$refNode.end>=e.end)return An(t)}}if(n){let t=this.nameProvider.getNameNode(n);if(t&&(t===e||zi(e,t)))return this.getSelfNodes(n)}}return[]}getSelfNodes(e){if(this.hasMultiReference){let t=this.index.findAllReferences(e,this.nodeLocator.getAstNodePath(e)),n=this.getNodeFromReferenceDescription(t.head());if(n){for(let t of Fn(n))if(un(t.reference)&&t.reference.items.some(t=>t.ref===e))return t.reference.items.map(e=>e.ref)}return[e]}else return[e]}getNodeFromReferenceDescription(e){if(!e)return;let t=this.documents.getDocument(e.sourceUri);if(t)return this.nodeLocator.getAstNode(t.parseResult.value,e.sourcePath)}findDeclarationNodes(e){let t=this.findDeclarations(e),n=[];for(let e of t){let t=this.nameProvider.getNameNode(e)??e.$cstNode;t&&n.push(t)}return n}findReferences(e,t){let n=[];t.includeDeclaration&&n.push(...this.getSelfReferences(e));let r=this.index.findAllReferences(e,this.nodeLocator.getAstNodePath(e));return t.documentUri&&(r=r.filter(e=>iM.equals(e.sourceUri,t.documentUri))),n.push(...r),M(n)}getSelfReferences(e){let t=this.getSelfNodes(e),n=[];for(let e of t){let t=this.nameProvider.getNameNode(e);if(t){let r=On(e),i=this.nodeLocator.getAstNodePath(e);n.push({sourceUri:r.uri,sourcePath:i,targetUri:r.uri,targetPath:i,segment:Vi(t),local:!0})}}return n}},pM=class{static{o(this,`MultiMap`)}constructor(e){if(this.map=new Map,e)for(let[t,n]of e)this.add(t,n)}get size(){return Cn.sum(M(this.map.values()).map(e=>e.length))}clear(){this.map.clear()}delete(e,t){if(t===void 0)return this.map.delete(e);{let n=this.map.get(e);if(n){let r=n.indexOf(t);if(r>=0)return n.length===1?this.map.delete(e):n.splice(r,1),!0}return!1}}get(e){return this.map.get(e)??[]}getStream(e){let t=this.map.get(e);return t?M(t):bn}has(e,t){if(t===void 0)return this.map.has(e);{let n=this.map.get(e);return n?n.indexOf(t)>=0:!1}}add(e,t){return this.map.has(e)?this.map.get(e).push(t):this.map.set(e,[t]),this}addAll(e,t){return this.map.has(e)?this.map.get(e).push(...t):this.map.set(e,Array.from(t)),this}forEach(e){this.map.forEach((t,n)=>t.forEach(t=>e(t,n,this)))}[Symbol.iterator](){return this.entries().iterator()}entries(){return M(this.map.entries()).flatMap(([e,t])=>t.map(t=>[e,t]))}keys(){return M(this.map.keys())}values(){return M(this.map.values()).flat()}entriesGroupedByKey(){return M(this.map.entries())}},mM=class{static{o(this,`BiMap`)}get size(){return this.map.size}constructor(e){if(this.map=new Map,this.inverse=new Map,e)for(let[t,n]of e)this.set(t,n)}clear(){this.map.clear(),this.inverse.clear()}set(e,t){return this.map.set(e,t),this.inverse.set(t,e),this}get(e){return this.map.get(e)}getKey(e){return this.inverse.get(e)}delete(e){let t=this.map.get(e);return t===void 0?!1:(this.map.delete(e),this.inverse.delete(t),!0)}},hM=class{static{o(this,`DefaultScopeComputation`)}constructor(e){this.nameProvider=e.references.NameProvider,this.descriptions=e.workspace.AstNodeDescriptionProvider}async collectExportedSymbols(e,t=Z.CancellationToken.None){return this.collectExportedSymbolsForNode(e.parseResult.value,e,void 0,t)}async collectExportedSymbolsForNode(e,t,n=jn,r=Z.CancellationToken.None){let i=[];this.addExportedSymbol(e,i,t);for(let a of n(e))await Q(r),this.addExportedSymbol(a,i,t);return i}addExportedSymbol(e,t,n){let r=this.nameProvider.getName(e);r&&t.push(this.descriptions.createDescription(e,r,n))}async collectLocalSymbols(e,t=Z.CancellationToken.None){let n=e.parseResult.value,r=new pM;for(let i of Mn(n))await Q(t),this.addLocalSymbol(i,e,r);return r}addLocalSymbol(e,t,n){let r=e.$container;if(r){let i=this.nameProvider.getName(e);i&&n.add(r,this.descriptions.createDescription(e,i,t))}}},gM=class{static{o(this,`StreamScope`)}constructor(e,t,n){this.elements=e,this.outerScope=t,this.caseInsensitive=n?.caseInsensitive??!1,this.concatOuterScope=n?.concatOuterScope??!0}getAllElements(){return this.outerScope?this.elements.concat(this.outerScope.getAllElements()):this.elements}getElement(e){let t=this.caseInsensitive?e.toLowerCase():e,n=this.caseInsensitive?this.elements.find(e=>e.name.toLowerCase()===t):this.elements.find(t=>t.name===e);if(n)return n;if(this.outerScope)return this.outerScope.getElement(e)}getElements(e){let t=this.caseInsensitive?e.toLowerCase():e,n=this.caseInsensitive?this.elements.filter(e=>e.name.toLowerCase()===t):this.elements.filter(t=>t.name===e);return(this.concatOuterScope||n.isEmpty())&&this.outerScope?n.concat(this.outerScope.getElements(e)):n}},_M=class{static{o(this,`MapScope`)}constructor(e,t,n){this.elements=new Map,this.caseInsensitive=n?.caseInsensitive??!1,this.concatOuterScope=n?.concatOuterScope??!0;for(let t of e){let e=this.caseInsensitive?t.name.toLowerCase():t.name;this.elements.set(e,t)}this.outerScope=t}getElement(e){let t=this.caseInsensitive?e.toLowerCase():e,n=this.elements.get(t);if(n)return n;if(this.outerScope)return this.outerScope.getElement(e)}getElements(e){let t=this.caseInsensitive?e.toLowerCase():e,n=this.elements.get(t),r=n?[n]:[];return(this.concatOuterScope||r.length>0)&&this.outerScope?M(r).concat(this.outerScope.getElements(e)):M(r)}getAllElements(){let e=M(this.elements.values());return this.outerScope&&(e=e.concat(this.outerScope.getAllElements())),e}},vM=class{static{o(this,`MultiMapScope`)}constructor(e,t,n){this.elements=new pM,this.caseInsensitive=n?.caseInsensitive??!1,this.concatOuterScope=n?.concatOuterScope??!0;for(let t of e){let e=this.caseInsensitive?t.name.toLowerCase():t.name;this.elements.add(e,t)}this.outerScope=t}getElement(e){let t=this.caseInsensitive?e.toLowerCase():e,n=this.elements.get(t)[0];if(n)return n;if(this.outerScope)return this.outerScope.getElement(e)}getElements(e){let t=this.caseInsensitive?e.toLowerCase():e,n=this.elements.get(t);return(this.concatOuterScope||n.length===0)&&this.outerScope?M(n).concat(this.outerScope.getElements(e)):M(n)}getAllElements(){let e=M(this.elements.values());return this.outerScope&&(e=e.concat(this.outerScope.getAllElements())),e}},yM={getElement(){},getElements(){return bn},getAllElements(){return bn}},bM=class{static{o(this,`DisposableCache`)}constructor(){this.toDispose=[],this.isDisposed=!1}onDispose(e){this.toDispose.push(e)}dispose(){this.throwIfDisposed(),this.clear(),this.isDisposed=!0,this.toDispose.forEach(e=>e.dispose())}throwIfDisposed(){if(this.isDisposed)throw Error(`This cache has already been disposed`)}},xM=class extends bM{static{o(this,`SimpleCache`)}constructor(){super(...arguments),this.cache=new Map}has(e){return this.throwIfDisposed(),this.cache.has(e)}set(e,t){this.throwIfDisposed(),this.cache.set(e,t)}get(e,t){if(this.throwIfDisposed(),this.cache.has(e))return this.cache.get(e);if(t){let n=t();return this.cache.set(e,n),n}else return}delete(e){return this.throwIfDisposed(),this.cache.delete(e)}clear(){this.throwIfDisposed(),this.cache.clear()}},SM=class extends bM{static{o(this,`ContextCache`)}constructor(e){super(),this.cache=new Map,this.converter=e??(e=>e)}has(e,t){return this.throwIfDisposed(),this.cacheForContext(e).has(t)}set(e,t,n){this.throwIfDisposed(),this.cacheForContext(e).set(t,n)}get(e,t,n){this.throwIfDisposed();let r=this.cacheForContext(e);if(r.has(t))return r.get(t);if(n){let e=n();return r.set(t,e),e}else return}delete(e,t){return this.throwIfDisposed(),this.cacheForContext(e).delete(t)}clear(e){if(this.throwIfDisposed(),e){let t=this.converter(e);this.cache.delete(t)}else this.cache.clear()}cacheForContext(e){let t=this.converter(e),n=this.cache.get(t);return n||(n=new Map,this.cache.set(t,n)),n}},CM=class extends SM{static{o(this,`DocumentCache`)}constructor(e,t){super(e=>e.toString()),t?(this.toDispose.push(e.workspace.DocumentBuilder.onDocumentPhase(t,e=>{this.clear(e.uri.toString())})),this.toDispose.push(e.workspace.DocumentBuilder.onUpdate((e,t)=>{for(let e of t)this.clear(e)}))):this.toDispose.push(e.workspace.DocumentBuilder.onUpdate((e,t)=>{let n=e.concat(t);for(let e of n)this.clear(e)}))}},wM=class extends xM{static{o(this,`WorkspaceCache`)}constructor(e,t){super(),t?(this.toDispose.push(e.workspace.DocumentBuilder.onBuildPhase(t,()=>{this.clear()})),this.toDispose.push(e.workspace.DocumentBuilder.onUpdate((e,t)=>{t.length>0&&this.clear()}))):this.toDispose.push(e.workspace.DocumentBuilder.onUpdate(()=>{this.clear()}))}},TM=class{static{o(this,`DefaultScopeProvider`)}constructor(e){this.reflection=e.shared.AstReflection,this.nameProvider=e.references.NameProvider,this.descriptions=e.workspace.AstNodeDescriptionProvider,this.indexManager=e.shared.workspace.IndexManager,this.globalScopeCache=new wM(e.shared)}getScope(e){let t=[],n=this.reflection.getReferenceType(e),r=On(e.container).localSymbols;if(r){let i=e.container;do r.has(i)&&t.push(r.getStream(i).filter(e=>this.reflection.isSubtype(e.type,n))),i=i.$container;while(i)}let i=this.getGlobalScope(n,e);for(let e=t.length-1;e>=0;e--)i=this.createScope(t[e],i);return i}createScope(e,t,n){return new gM(M(e),t,n)}createScopeForNodes(e,t,n){return new gM(M(e).map(e=>{let t=this.nameProvider.getName(e);if(t)return this.descriptions.createDescription(e,t)}).nonNullable(),t,n)}getGlobalScope(e,t){return this.globalScopeCache.get(e,()=>new vM(this.indexManager.allElements(e)))}};function EM(e){return typeof e.$comment==`string`}o(EM,`isAstNodeWithComment`);function DM(e){return typeof e==`object`&&!!e&&(`$ref`in e||`$error`in e)}o(DM,`isIntermediateReference`);var OM=class{static{o(this,`DefaultJsonSerializer`)}constructor(e){this.ignoreProperties=new Set([`$container`,`$containerProperty`,`$containerIndex`,`$document`,`$cstNode`]),this.langiumDocuments=e.shared.workspace.LangiumDocuments,this.astNodeLocator=e.workspace.AstNodeLocator,this.nameProvider=e.references.NameProvider,this.commentProvider=e.documentation.CommentProvider}serialize(e,t){let n=t??{},r=t?.replacer,i=o((e,t)=>this.replacer(e,t,n),`defaultReplacer`),a=r?(e,t)=>r(e,t,i):i;try{return this.currentDocument=On(e),JSON.stringify(e,a,t?.space)}finally{this.currentDocument=void 0}}deserialize(e,t){let n=t??{},r=JSON.parse(e);return this.linkNode(r,r,n),r}replacer(e,t,{refText:n,sourceText:r,textRegions:i,comments:a,uriConverter:o}){if(!this.ignoreProperties.has(e))if(ln(t)){let e=t.ref,r=n?t.$refText:void 0;if(e){let t=On(e),n=``;this.currentDocument&&this.currentDocument!==t&&(n=o?o(t.uri,e):t.uri.toString());let i=this.astNodeLocator.getAstNodePath(e);return{$ref:`${n}#${i}`,$refText:r}}else return{$error:t.error?.message??`Could not resolve reference`,$refText:r}}else if(un(t)){let e=n?t.$refText:void 0,r=[];for(let e of t.items){let t=e.ref,n=On(e.ref),i=``;this.currentDocument&&this.currentDocument!==n&&(i=o?o(n.uri,t):n.uri.toString());let a=this.astNodeLocator.getAstNodePath(t);r.push(`${i}#${a}`)}return{$refs:r,$refText:e}}else if(j(t)){let n;if(i&&(n=this.addAstNodeRegionWithAssignmentsTo({...t}),(!e||t.$document)&&n?.$textRegion&&(n.$textRegion.documentURI=this.currentDocument?.uri.toString())),r&&!e&&(n??={...t},n.$sourceText=t.$cstNode?.text),a){n??={...t};let e=this.commentProvider.getComment(t);e&&(n.$comment=e.replace(/\r/g,``))}return n??t}else return t}addAstNodeRegionWithAssignmentsTo(e){let t=o(e=>({offset:e.offset,end:e.end,length:e.length,range:e.range}),`createDocumentSegment`);if(e.$cstNode){let n=e.$textRegion=t(e.$cstNode),r=n.assignments={};return Object.keys(e).filter(e=>!e.startsWith(`$`)).forEach(n=>{let i=za(e.$cstNode,n).map(t);i.length!==0&&(r[n]=i)}),e}}linkNode(e,t,n,r,i,a){for(let[r,i]of Object.entries(e))if(Array.isArray(i))for(let a=0;a<i.length;a++){let o=i[a];DM(o)?i[a]=this.reviveReference(e,r,t,o,n):j(o)&&this.linkNode(o,t,n,e,r,a)}else DM(i)?e[r]=this.reviveReference(e,r,t,i,n):j(i)&&this.linkNode(i,t,n,e,r);let o=e;o.$container=r,o.$containerProperty=i,o.$containerIndex=a}reviveReference(e,t,n,r,i){let a=r.$refText,o=r.$error,s;if(r.$ref){let e=this.getRefNode(n,r.$ref,i.uriConverter);if(j(e))return a||=this.nameProvider.getName(e),{$refText:a??``,ref:e};o=e}else if(r.$refs){let e=[];for(let t of r.$refs){let r=this.getRefNode(n,t,i.uriConverter);j(r)&&e.push({ref:r})}if(e.length===0)s={$refText:a??``,items:e},o??=`Could not resolve multi-reference`;else return{$refText:a??``,items:e}}if(o)return s??={$refText:a??``,ref:void 0},s.error={info:{container:e,property:t,reference:s},message:o},s}getRefNode(e,t,n){try{let r=t.indexOf(`#`);if(r===0)return this.astNodeLocator.getAstNode(e,t.substring(1))||`Could not resolve path: `+t;if(r<0){let e=n?n(t):nM.parse(t),r=this.langiumDocuments.getDocument(e);return r?r.parseResult.value:`Could not find document for URI: `+t}let i=n?n(t.substring(0,r)):nM.parse(t.substring(0,r)),a=this.langiumDocuments.getDocument(i);return a?r===t.length-1?a.parseResult.value:this.astNodeLocator.getAstNode(a.parseResult.value,t.substring(r+1))||`Could not resolve URI: `+t:`Could not find document for URI: `+t}catch(e){return String(e)}}},kM=class{static{o(this,`DefaultServiceRegistry`)}get map(){return this.fileExtensionMap}constructor(e){this.languageIdMap=new Map,this.fileExtensionMap=new Map,this.fileNameMap=new Map,this.textDocuments=e?.workspace.TextDocuments}register(e){let t=e.LanguageMetaData;for(let n of t.fileExtensions)this.fileExtensionMap.has(n)&&console.warn(`The file extension ${n} is used by multiple languages. It is now assigned to '${t.languageId}'.`),this.fileExtensionMap.set(n,e);if(t.fileNames)for(let n of t.fileNames)this.fileNameMap.has(n)&&console.warn(`The file name ${n} is used by multiple languages. It is now assigned to '${t.languageId}'.`),this.fileNameMap.set(n,e);this.languageIdMap.set(t.languageId,e)}getServices(e){if(this.languageIdMap.size===0)throw Error("The service registry is empty. Use `register` to register the services of a language.");let t=this.textDocuments?.get(e)?.languageId;if(t!==void 0){let e=this.languageIdMap.get(t);if(e)return e}let n=iM.extname(e),r=iM.basename(e),i=this.fileNameMap.get(r)??this.fileExtensionMap.get(n);if(!i)throw Error(t?`The service registry contains no services for the extension '${n}' for language '${t}'.`:`The service registry contains no services for the extension '${n}'.`);return i}hasServices(e){try{return this.getServices(e),!0}catch{return!1}}get all(){return Array.from(this.languageIdMap.values())}};function AM(e){return{code:e}}o(AM,`diagnosticData`);var jM;(function(e){e.defaults=[`fast`,`slow`,`built-in`],e.all=e.defaults})(jM||={});var MM=class{static{o(this,`ValidationRegistry`)}constructor(e){this.entries=new pM,this.knownCategories=new Set(jM.defaults),this.entriesBefore=[],this.entriesAfter=[],this.reflection=e.shared.AstReflection}register(e,t=this,n=`fast`){if(n===`built-in`)throw Error(`The 'built-in' category is reserved for lexer, parser, and linker errors.`);this.knownCategories.add(n);for(let[r,i]of Object.entries(e)){let e=i;if(Array.isArray(e))for(let i of e){let e={check:this.wrapValidationException(i,t),category:n};this.addEntry(r,e)}else if(typeof e==`function`){let i={check:this.wrapValidationException(e,t),category:n};this.addEntry(r,i)}else oa(e)}}wrapValidationException(e,t){return async(n,r,i)=>{await this.handleException(()=>e.call(t,n,r,i),`An error occurred during validation`,r,n)}}async handleException(e,t,n,r){try{await e()}catch(e){if(Kj(e))throw e;console.error(`${t}:`,e),e instanceof Error&&e.stack&&console.error(e.stack),n(`error`,`${t}: ${e instanceof Error?e.message:String(e)}`,{node:r})}}addEntry(e,t){if(e===`AstNode`){this.entries.add(`AstNode`,t);return}for(let n of this.reflection.getAllSubTypes(e))this.entries.add(n,t)}getChecks(e,t){let n=M(this.entries.get(e)).concat(this.entries.get(`AstNode`));return t&&(n=n.filter(e=>t.includes(e.category))),n.map(e=>e.check)}registerBeforeDocument(e,t=this){this.entriesBefore.push(this.wrapPreparationException(e,`An error occurred during set-up of the validation`,t))}registerAfterDocument(e,t=this){this.entriesAfter.push(this.wrapPreparationException(e,`An error occurred during tear-down of the validation`,t))}wrapPreparationException(e,t,n){return async(r,i,a,o)=>{await this.handleException(()=>e.call(n,r,i,a,o),t,i,r)}}get checksBefore(){return this.entriesBefore}get checksAfter(){return this.entriesAfter}getAllValidationCategories(e){return this.knownCategories}},NM=Object.freeze({validateNode:!0,validateChildren:!0}),PM=class{static{o(this,`DefaultDocumentValidator`)}constructor(e){this.validationRegistry=e.validation.ValidationRegistry,this.metadata=e.LanguageMetaData,this.profiler=e.shared.profilers.LangiumProfiler,this.languageId=e.LanguageMetaData.languageId}async validateDocument(e,t={},n=Z.CancellationToken.None){let r=e.parseResult,i=[];if(await Q(n),(!t.categories||t.categories.includes(`built-in`))&&(this.processLexingErrors(r,i,t),t.stopAfterLexingErrors&&i.some(e=>e.data?.code===RM.LexingError)||(this.processParsingErrors(r,i,t),t.stopAfterParsingErrors&&i.some(e=>e.data?.code===RM.ParsingError))||(this.processLinkingErrors(e,i,t),t.stopAfterLinkingErrors&&i.some(e=>e.data?.code===RM.LinkingError))))return i;try{i.push(...await this.validateAst(r.value,t,n))}catch(e){if(Kj(e))throw e;console.error(`An error occurred during validation:`,e)}return await Q(n),i}processLexingErrors(e,t,n){let r=[...e.lexerErrors,...e.lexerReport?.diagnostics??[]];for(let e of r){let n=e.severity??`error`,r={severity:IM(n),range:{start:{line:e.line-1,character:e.column-1},end:{line:e.line-1,character:e.column+e.length-1}},message:e.message,data:LM(n),source:this.getSource()};t.push(r)}}processParsingErrors(e,t,n){for(let n of e.parserErrors){let e;if(isNaN(n.token.startOffset)){if(`previousToken`in n){let t=n.previousToken;if(isNaN(t.startOffset)){let t={line:0,character:0};e={start:t,end:t}}else{let n={line:t.endLine-1,character:t.endColumn};e={start:n,end:n}}}}else e=Bi(n.token);if(e){let r={severity:IM(`error`),range:e,message:n.message,data:AM(RM.ParsingError),source:this.getSource()};t.push(r)}}}processLinkingErrors(e,t,n){for(let n of e.references){let e=n.error;if(e){let r={node:e.info.container,range:n.$refNode?.range,property:e.info.property,index:e.info.index,data:{code:RM.LinkingError,containerType:e.info.container.$type,property:e.info.property,refText:e.info.reference.$refText}};t.push(this.toDiagnostic(`error`,e.message,r))}}}async validateAst(e,t,n=Z.CancellationToken.None){let r=[],i=o((e,t,n)=>{r.push(this.toDiagnostic(e,t,n))},`acceptor`);return await this.validateAstBefore(e,t,i,n),await this.validateAstNodes(e,t,i,n),await this.validateAstAfter(e,t,i,n),r}async validateAstBefore(e,t,n,r=Z.CancellationToken.None){let i=this.validationRegistry.checksBefore;for(let a of i)await Q(r),await a(e,n,t.categories??[],r)}async validateAstNodes(e,t,n,r=Z.CancellationToken.None){if(this.profiler?.isActive(`validating`)){let i=this.profiler.createTask(`validating`,this.languageId);i.start();try{let a=Nn(e).iterator();for(let e of a){i.startSubTask(e.$type);let o=this.validateSingleNodeOptions(e,t);if(o.validateNode)try{let i=this.validationRegistry.getChecks(e.$type,t.categories);for(let t of i)await t(e,n,r)}finally{i.stopSubTask(e.$type)}o.validateChildren||a.prune()}}finally{i.stop()}}else{let i=Nn(e).iterator();for(let e of i){await Q(r);let a=this.validateSingleNodeOptions(e,t);if(a.validateNode){let i=this.validationRegistry.getChecks(e.$type,t.categories);for(let t of i)await t(e,n,r)}a.validateChildren||i.prune()}}}validateSingleNodeOptions(e,t){return NM}async validateAstAfter(e,t,n,r=Z.CancellationToken.None){let i=this.validationRegistry.checksAfter;for(let a of i)await Q(r),await a(e,n,t.categories??[],r)}toDiagnostic(e,t,n){return{message:t,range:FM(n),severity:IM(e),code:n.code,codeDescription:n.codeDescription,tags:n.tags,relatedInformation:n.relatedInformation,data:n.data,source:this.getSource()}}getSource(){return this.metadata.languageId}};function FM(e){if(e.range)return e.range;let t;return typeof e.property==`string`?t=Ba(e.node.$cstNode,e.property,e.index):typeof e.keyword==`string`&&(t=Ua(e.node.$cstNode,e.keyword,e.index)),t??=e.node.$cstNode,t?t.range:{start:{line:0,character:0},end:{line:0,character:0}}}o(FM,`getDiagnosticRange`);function IM(e){switch(e){case`error`:return 1;case`warning`:return 2;case`info`:return 3;case`hint`:return 4;default:throw Error(`Invalid diagnostic severity: `+e)}}o(IM,`toDiagnosticSeverity`);function LM(e){switch(e){case`error`:return AM(RM.LexingError);case`warning`:return AM(RM.LexingWarning);case`info`:return AM(RM.LexingInfo);case`hint`:return AM(RM.LexingHint);default:throw Error(`Invalid diagnostic severity: `+e)}}o(LM,`toDiagnosticData`);var RM;(function(e){e.LexingError=`lexing-error`,e.LexingWarning=`lexing-warning`,e.LexingInfo=`lexing-info`,e.LexingHint=`lexing-hint`,e.ParsingError=`parsing-error`,e.LinkingError=`linking-error`})(RM||={});var zM=class{static{o(this,`DefaultAstNodeDescriptionProvider`)}constructor(e){this.astNodeLocator=e.workspace.AstNodeLocator,this.nameProvider=e.references.NameProvider}createDescription(e,t,n){let r=n??On(e);t??=this.nameProvider.getName(e);let i=this.astNodeLocator.getAstNodePath(e);if(!t)throw Error(`Node at path ${i} has no name.`);let a,s=o(()=>a??=Vi(this.nameProvider.getNameNode(e)??e.$cstNode),`nameSegmentGetter`);return{node:e,name:t,get nameSegment(){return s()},selectionSegment:Vi(e.$cstNode),type:e.$type,documentUri:r.uri,path:i}}},BM=class{static{o(this,`DefaultReferenceDescriptionProvider`)}constructor(e){this.nodeLocator=e.workspace.AstNodeLocator}async createDescriptions(e,t=Z.CancellationToken.None){let n=[],r=e.parseResult.value;for(let e of Nn(r))await Q(t),Fn(e).forEach(e=>{e.reference.error||n.push(...this.createInfoDescriptions(e))});return n}createInfoDescriptions(e){let t=e.reference;if(t.error||!t.$refNode)return[];let n=[];ln(t)&&t.$nodeDescription?n=[t.$nodeDescription]:un(t)&&(n=t.items.map(e=>e.$nodeDescription).filter(e=>e!==void 0));let r=On(e.container).uri,i=this.nodeLocator.getAstNodePath(e.container),a=[],o=Vi(t.$refNode);for(let e of n)a.push({sourceUri:r,sourcePath:i,targetUri:e.documentUri,targetPath:e.path,segment:o,local:iM.equals(e.documentUri,r)});return a}},VM=class{static{o(this,`DefaultAstNodeLocator`)}constructor(){this.segmentSeparator=`/`,this.indexSeparator=`@`}getAstNodePath(e){if(e.$container){let t=this.getAstNodePath(e.$container),n=this.getPathSegment(e);return t+this.segmentSeparator+n}return``}getPathSegment({$containerProperty:e,$containerIndex:t}){if(!e)throw Error(`Missing '$containerProperty' in AST node.`);return t===void 0?e:e+this.indexSeparator+t}getAstNode(e,t){return t.split(this.segmentSeparator).reduce((e,t)=>{if(!e||t.length===0)return e;let n=t.indexOf(this.indexSeparator);if(n>0){let r=t.substring(0,n),i=parseInt(t.substring(n+1));return e[r]?.[i]}return e[t]},e)}},HM={};d(HM,f(yt(),1));var UM=class{static{o(this,`DefaultConfigurationProvider`)}constructor(e){this._ready=new qj,this.onConfigurationSectionUpdateEmitter=new HM.Emitter,this.settings={},this.workspaceConfig=!1,this.serviceRegistry=e.ServiceRegistry}get ready(){return this._ready.promise}initialize(e){this.workspaceConfig=e.capabilities.workspace?.configuration??!1}async initialized(e){if(this.workspaceConfig){if(e.register){let t=this.serviceRegistry.all;e.register({section:t.map(e=>this.toSectionName(e.LanguageMetaData.languageId))})}if(e.fetchConfiguration){let t=this.serviceRegistry.all.map(e=>({section:this.toSectionName(e.LanguageMetaData.languageId)})),n=await e.fetchConfiguration(t);t.forEach((e,t)=>{this.updateSectionConfiguration(e.section,n[t])})}}this._ready.resolve()}updateConfiguration(e){typeof e.settings!=`object`||e.settings===null||Object.entries(e.settings).forEach(([e,t])=>{this.updateSectionConfiguration(e,t),this.onConfigurationSectionUpdateEmitter.fire({section:e,configuration:t})})}updateSectionConfiguration(e,t){this.settings[e]=t}async getConfiguration(e,t){await this.ready;let n=this.toSectionName(e);if(this.settings[n])return this.settings[n][t]}toSectionName(e){return`${e}`}get onConfigurationSectionUpdate(){return this.onConfigurationSectionUpdateEmitter.event}},WM=f(on(),1),GM;(function(e){function t(e){return{dispose:o(async()=>await e(),`dispose`)}}o(t,`create`),e.create=t})(GM||={});var KM=class{static{o(this,`DefaultDocumentBuilder`)}constructor(e){this.updateBuildOptions={validation:{categories:[`built-in`,`fast`]}},this.updateListeners=[],this.buildPhaseListeners=new pM,this.documentPhaseListeners=new pM,this.buildState=new Map,this.documentBuildWaiters=new Map,this.currentState=$.Changed,this.langiumDocuments=e.workspace.LangiumDocuments,this.langiumDocumentFactory=e.workspace.LangiumDocumentFactory,this.textDocuments=e.workspace.TextDocuments,this.indexManager=e.workspace.IndexManager,this.fileSystemProvider=e.workspace.FileSystemProvider,this.workspaceManager=()=>e.workspace.WorkspaceManager,this.serviceRegistry=e.ServiceRegistry}async build(e,t={},n=Z.CancellationToken.None){for(let n of e){let e=n.uri.toString();if(n.state===$.Validated){if(typeof t.validation==`boolean`&&t.validation)this.resetToState(n,$.IndexedReferences);else if(typeof t.validation==`object`){let r=this.findMissingValidationCategories(n,t);r.length>0&&(this.buildState.set(e,{completed:!1,options:{validation:{categories:r}},result:this.buildState.get(e)?.result}),n.state=$.IndexedReferences)}}else this.buildState.delete(e)}this.currentState=$.Changed,await this.emitUpdate(e.map(e=>e.uri),[]),await this.buildDocuments(e,t,n)}async update(e,t,n=Z.CancellationToken.None){this.currentState=$.Changed;let r=[];for(let e of t){let t=this.langiumDocuments.deleteDocuments(e);for(let e of t)r.push(e.uri),this.cleanUpDeleted(e)}let i=(await Promise.all(e.map(e=>this.findChangedUris(e)))).flat();for(let e of i){let t=this.langiumDocuments.getDocument(e);t===void 0&&(t=this.langiumDocumentFactory.fromModel({$type:`INVALID`},e),t.state=$.Changed,this.langiumDocuments.addDocument(t)),this.resetToState(t,$.Changed)}let a=M(i).concat(r).map(e=>e.toString()).toSet();this.langiumDocuments.all.filter(e=>!a.has(e.uri.toString())&&this.shouldRelink(e,a)).forEach(e=>this.resetToState(e,$.ComputedScopes)),await this.emitUpdate(i,r),await Q(n);let o=this.sortDocuments(this.langiumDocuments.all.filter(e=>e.state<$.Validated||!this.buildState.get(e.uri.toString())?.completed||this.resultsAreIncomplete(e,this.updateBuildOptions)).toArray());await this.buildDocuments(o,this.updateBuildOptions,n)}resultsAreIncomplete(e,t){return this.findMissingValidationCategories(e,t).length>=1}findMissingValidationCategories(e,t){let n=this.buildState.get(e.uri.toString()),r=this.serviceRegistry.getServices(e.uri).validation.ValidationRegistry.getAllValidationCategories(e),i=n?.result?.validationChecks?new Set(n?.result?.validationChecks):n?.completed?r:new Set;return M(t===void 0||t.validation===!0?r:typeof t.validation==`object`?t.validation.categories??r:[]).filter(e=>!i.has(e)).toArray()}async findChangedUris(e){if(this.langiumDocuments.getDocument(e)??this.textDocuments?.get(e))return[e];try{let t=await this.fileSystemProvider.stat(e);if(t.isDirectory)return await this.workspaceManager().searchFolder(e);if(this.workspaceManager().shouldIncludeEntry(t))return[e]}catch{}return[]}async emitUpdate(e,t){await Promise.all(this.updateListeners.map(n=>n(e,t)))}sortDocuments(e){let t=0,n=e.length-1;for(;t<n;){for(;t<e.length&&this.hasTextDocument(e[t]);)t++;for(;n>=0&&!this.hasTextDocument(e[n]);)n--;t<n&&([e[t],e[n]]=[e[n],e[t]])}return e}hasTextDocument(e){return!!this.textDocuments?.get(e.uri)}shouldRelink(e,t){return e.references.some(e=>e.error!==void 0)?!0:this.indexManager.isAffected(e,t)}onUpdate(e){return this.updateListeners.push(e),GM.create(()=>{let t=this.updateListeners.indexOf(e);t>=0&&this.updateListeners.splice(t,1)})}resetToState(e,t){switch(t){case $.Changed:case $.Parsed:this.indexManager.removeContent(e.uri);case $.IndexedContent:e.localSymbols=void 0;case $.ComputedScopes:this.serviceRegistry.getServices(e.uri).references.Linker.unlink(e);case $.Linked:this.indexManager.removeReferences(e.uri);case $.IndexedReferences:e.diagnostics=void 0,this.buildState.delete(e.uri.toString());case $.Validated:}e.state>t&&(e.state=t)}cleanUpDeleted(e){this.buildState.delete(e.uri.toString()),this.indexManager.remove(e.uri),e.state=$.Changed}async buildDocuments(e,t,n){this.prepareBuild(e,t),await this.runCancelable(e,$.Parsed,n,e=>this.langiumDocumentFactory.update(e,n)),await this.runCancelable(e,$.IndexedContent,n,e=>this.indexManager.updateContent(e,n)),await this.runCancelable(e,$.ComputedScopes,n,async e=>{e.localSymbols=await this.serviceRegistry.getServices(e.uri).references.ScopeComputation.collectLocalSymbols(e,n)});let r=e.filter(e=>this.shouldLink(e));await this.runCancelable(r,$.Linked,n,e=>this.serviceRegistry.getServices(e.uri).references.Linker.link(e,n)),await this.runCancelable(r,$.IndexedReferences,n,e=>this.indexManager.updateReferences(e,n));let i=e.filter(e=>this.shouldValidate(e)?!0:(this.markAsCompleted(e),!1));await this.runCancelable(i,$.Validated,n,async e=>{await this.validate(e,n),this.markAsCompleted(e)})}markAsCompleted(e){let t=this.buildState.get(e.uri.toString());t&&(t.completed=!0)}prepareBuild(e,t){for(let n of e){let e=n.uri.toString(),r=this.buildState.get(e);(!r||r.completed)&&this.buildState.set(e,{completed:!1,options:t,result:r?.result})}}async runCancelable(e,t,n,r){for(let i of e)i.state<t&&(await Q(n),await r(i),i.state=t,await this.notifyDocumentPhase(i,t,n));let i=e.filter(e=>e.state===t);await this.notifyBuildPhase(i,t,n),this.currentState=t}onBuildPhase(e,t){return this.buildPhaseListeners.add(e,t),GM.create(()=>{this.buildPhaseListeners.delete(e,t)})}onDocumentPhase(e,t){return this.documentPhaseListeners.add(e,t),GM.create(()=>{this.documentPhaseListeners.delete(e,t)})}waitUntil(e,t,n){let r;return t&&`path`in t?r=t:n=t,n??=Z.CancellationToken.None,r?this.awaitDocumentState(e,r,n):this.awaitBuilderState(e,n)}awaitDocumentState(e,t,n){let r=this.langiumDocuments.getDocument(t);return r?r.state>=e?Promise.resolve(t):n.isCancellationRequested?Promise.reject(Gj):this.currentState>=e&&e>r.state?Promise.reject(new WM.ResponseError(WM.LSPErrorCodes.RequestFailed,`Document state of ${t.toString()} is ${$[r.state]}, requiring ${$[e]}, but workspace state is already ${$[this.currentState]}. Returning undefined.`)):new Promise((r,i)=>{let a=this.onDocumentPhase(e,e=>{iM.equals(e.uri,t)&&(a.dispose(),o.dispose(),r(e.uri))}),o=n.onCancellationRequested(()=>{a.dispose(),o.dispose(),i(Gj)})}):Promise.reject(new WM.ResponseError(WM.LSPErrorCodes.ServerCancelled,`No document found for URI: ${t.toString()}`))}awaitBuilderState(e,t){return this.currentState>=e?Promise.resolve():t.isCancellationRequested?Promise.reject(Gj):new Promise((n,r)=>{let i=this.onBuildPhase(e,()=>{i.dispose(),a.dispose(),n()}),a=t.onCancellationRequested(()=>{i.dispose(),a.dispose(),r(Gj)})})}async notifyDocumentPhase(e,t,n){let r=this.documentPhaseListeners.get(t).slice();for(let t of r)try{await Q(n),await t(e,n)}catch(e){if(!Kj(e))throw e}}async notifyBuildPhase(e,t,n){if(e.length===0)return;let r=this.buildPhaseListeners.get(t).slice();for(let t of r)await Q(n),await t(e,n)}shouldLink(e){return this.getBuildOptions(e).eagerLinking??!0}shouldValidate(e){return!!this.getBuildOptions(e).validation}async validate(e,t){let n=this.serviceRegistry.getServices(e.uri).validation.DocumentValidator,r=this.getBuildOptions(e),i=typeof r.validation==`object`?{...r.validation}:{};i.categories=this.findMissingValidationCategories(e,r);let a=await n.validateDocument(e,i,t);e.diagnostics?e.diagnostics.push(...a):e.diagnostics=a;let o=this.buildState.get(e.uri.toString());o&&(o.result??={},o.result.validationChecks?o.result.validationChecks=M(o.result.validationChecks).concat(i.categories).distinct().toArray():o.result.validationChecks=[...i.categories])}getBuildOptions(e){return this.buildState.get(e.uri.toString())?.options??{}}},qM=class{static{o(this,`DefaultIndexManager`)}constructor(e){this.symbolIndex=new Map,this.symbolByTypeIndex=new SM,this.referenceIndex=new Map,this.documents=e.workspace.LangiumDocuments,this.serviceRegistry=e.ServiceRegistry,this.astReflection=e.AstReflection}findAllReferences(e,t){let n=On(e).uri,r=[];return this.referenceIndex.forEach(e=>{e.forEach(e=>{iM.equals(e.targetUri,n)&&e.targetPath===t&&r.push(e)})}),M(r)}allElements(e,t){let n=M(this.symbolIndex.keys());return t&&(n=n.filter(e=>!t||t.has(e))),n.map(t=>this.getFileDescriptions(t,e)).flat()}getFileDescriptions(e,t){return t?this.symbolByTypeIndex.get(e,t,()=>(this.symbolIndex.get(e)??[]).filter(e=>this.astReflection.isSubtype(e.type,t))):this.symbolIndex.get(e)??[]}remove(e){this.removeContent(e),this.removeReferences(e)}removeContent(e){let t=e.toString();this.symbolIndex.delete(t),this.symbolByTypeIndex.clear(t)}removeReferences(e){let t=e.toString();this.referenceIndex.delete(t)}async updateContent(e,t=Z.CancellationToken.None){let n=await this.serviceRegistry.getServices(e.uri).references.ScopeComputation.collectExportedSymbols(e,t),r=e.uri.toString();this.symbolIndex.set(r,n),this.symbolByTypeIndex.clear(r)}async updateReferences(e,t=Z.CancellationToken.None){let n=await this.serviceRegistry.getServices(e.uri).workspace.ReferenceDescriptionProvider.createDescriptions(e,t);this.referenceIndex.set(e.uri.toString(),n)}isAffected(e,t){let n=this.referenceIndex.get(e.uri.toString());return n?n.some(e=>!e.local&&t.has(e.targetUri.toString())):!1}},JM=class{static{o(this,`DefaultWorkspaceManager`)}constructor(e){this.initialBuildOptions={},this._ready=new qj,this.serviceRegistry=e.ServiceRegistry,this.langiumDocuments=e.workspace.LangiumDocuments,this.documentBuilder=e.workspace.DocumentBuilder,this.fileSystemProvider=e.workspace.FileSystemProvider,this.mutex=e.workspace.WorkspaceLock}get ready(){return this._ready.promise}get workspaceFolders(){return this.folders}initialize(e){this.folders=e.workspaceFolders??void 0}initialized(e){return this.mutex.write(e=>this.initializeWorkspace(this.folders??[],e))}async initializeWorkspace(e,t=Z.CancellationToken.None){let n=await this.performStartup(e);await Q(t),await this.documentBuilder.build(n,this.initialBuildOptions,t)}async performStartup(e){let t=[],n=o(e=>{t.push(e),this.langiumDocuments.hasDocument(e.uri)||this.langiumDocuments.addDocument(e)},`collector`);await this.loadAdditionalDocuments(e,n);let r=[];await Promise.all(e.map(e=>this.getRootFolder(e)).map(async e=>this.traverseFolder(e,r)));let i=M(r).distinct(e=>e.toString()).filter(e=>!this.langiumDocuments.hasDocument(e));return await this.loadWorkspaceDocuments(i,n),this._ready.resolve(),t}async loadWorkspaceDocuments(e,t){await Promise.all(e.map(async e=>{t(await this.langiumDocuments.getOrCreateDocument(e))}))}loadAdditionalDocuments(e,t){return Promise.resolve()}getRootFolder(e){return nM.parse(e.uri)}async traverseFolder(e,t){try{let n=await this.fileSystemProvider.readDirectory(e);await Promise.all(n.map(async e=>{this.shouldIncludeEntry(e)&&(e.isDirectory?await this.traverseFolder(e.uri,t):e.isFile&&t.push(e.uri))}))}catch(t){console.error(`Failure to read directory content of `+e.toString(!0),t)}}async searchFolder(e){let t=[];return await this.traverseFolder(e,t),t}shouldIncludeEntry(e){let t=iM.basename(e.uri);return t.startsWith(`.`)?!1:e.isDirectory?t!==`node_modules`&&t!==`out`:e.isFile?this.serviceRegistry.hasServices(e.uri):!1}},YM=class{static{o(this,`DefaultLexerErrorMessageProvider`)}buildUnexpectedCharactersMessage(e,t,n,r,i){return Vy.buildUnexpectedCharactersMessage(e,t,n,r,i)}buildUnableToPopLexerModeMessage(e){return Vy.buildUnableToPopLexerModeMessage(e)}},XM={mode:`full`},ZM=class{static{o(this,`DefaultLexer`)}constructor(e){this.errorMessageProvider=e.parser.LexerErrorMessageProvider,this.tokenBuilder=e.parser.TokenBuilder;let t=this.tokenBuilder.buildTokens(e.Grammar,{caseInsensitive:e.LanguageMetaData.caseInsensitive});this.tokenTypes=this.toTokenTypeDictionary(t);let n=eN(t)?Object.values(t):t,r=e.LanguageMetaData.mode===`production`;this.chevrotainLexer=new Uy(n,{positionTracking:`full`,skipValidations:r,errorMessageProvider:this.errorMessageProvider})}get definition(){return this.tokenTypes}tokenize(e,t=XM){let n=this.chevrotainLexer.tokenize(e);return{tokens:n.tokens,errors:n.errors,hidden:n.groups.hidden??[],report:this.tokenBuilder.flushLexingReport?.(e)}}toTokenTypeDictionary(e){if(eN(e))return e;let t=$M(e)?Object.values(e.modes).flat():e,n={};return t.forEach(e=>n[e.name]=e),n}};function QM(e){return Array.isArray(e)&&(e.length===0||`name`in e[0])}o(QM,`isTokenTypeArray`);function $M(e){return e&&`modes`in e&&`defaultMode`in e}o($M,`isIMultiModeLexerDefinition`);function eN(e){return!QM(e)&&!$M(e)}o(eN,`isTokenTypeDictionary`),gt();function tN(e,t,n){let r,i;typeof e==`string`?(i=t,r=n):(i=e.range.start,r=t),i||=y.create(0,0);let a=rN(e),o=yN(r);return fN({index:0,tokens:oN({lines:a,position:i,options:o}),position:i})}o(tN,`parseJSDoc`);function nN(e,t){let n=yN(t),r=rN(e);if(r.length===0)return!1;let i=r[0],a=r[r.length-1],o=n.start,s=n.end;return!!o?.exec(i)&&!!s?.exec(a)}o(nN,`isJSDoc`);function rN(e){let t=``;return t=typeof e==`string`?e:e.text,t.split(Sa)}o(rN,`getLines`);var iN=/\s*(@([\p{L}][\p{L}\p{N}]*)?)/uy,aN=/\{(@[\p{L}][\p{L}\p{N}]*)(\s*)([^\r\n}]+)?\}/gu;function oN(e){let t=[],n=e.position.line,r=e.position.character;for(let i=0;i<e.lines.length;i++){let a=i===0,o=i===e.lines.length-1,s=e.lines[i],c=0;if(a&&e.options.start){let t=e.options.start?.exec(s);t&&(c=t.index+t[0].length)}else{let t=e.options.line?.exec(s);t&&(c=t.index+t[0].length)}if(o){let t=e.options.end?.exec(s);t&&(s=s.substring(0,t.index))}if(s=s.substring(0,dN(s)),uN(s,c)>=s.length){if(t.length>0){let e=y.create(n,r);t.push({type:`break`,content:``,range:b.create(e,e)})}}else{iN.lastIndex=c;let e=iN.exec(s);if(e){let i=e[0],a=e[1],o=y.create(n,r+c),l=y.create(n,r+c+i.length);t.push({type:`tag`,content:a,range:b.create(o,l)}),c+=i.length,c=uN(s,c)}if(c<s.length){let e=s.substring(c),i=Array.from(e.matchAll(aN));t.push(...sN(i,e,n,r+c))}}n++,r=0}return t.length>0&&t[t.length-1].type===`break`?t.slice(0,-1):t}o(oN,`tokenize`);function sN(e,t,n,r){let i=[];if(e.length===0){let e=y.create(n,r),a=y.create(n,r+t.length);i.push({type:`text`,content:t,range:b.create(e,a)})}else{let a=0;for(let o of e){let e=o.index,s=t.substring(a,e);s.length>0&&i.push({type:`text`,content:t.substring(a,e),range:b.create(y.create(n,a+r),y.create(n,e+r))});let c=s.length+1,l=o[1];if(i.push({type:`inline-tag`,content:l,range:b.create(y.create(n,a+c+r),y.create(n,a+c+l.length+r))}),c+=l.length,o.length===4){c+=o[2].length;let e=o[3];i.push({type:`text`,content:e,range:b.create(y.create(n,a+c+r),y.create(n,a+c+e.length+r))})}else i.push({type:`text`,content:``,range:b.create(y.create(n,a+c+r),y.create(n,a+c+r))});a=e+o[0].length}let o=t.substring(a);o.length>0&&i.push({type:`text`,content:o,range:b.create(y.create(n,a+r),y.create(n,a+r+o.length))})}return i}o(sN,`buildInlineTokens`);var cN=/\S/,lN=/\s*$/;function uN(e,t){let n=e.substring(t).match(cN);return n?t+n.index:e.length}o(uN,`skipWhitespace`);function dN(e){let t=e.match(lN);if(t&&typeof t.index==`number`)return t.index}o(dN,`lastCharacter`);function fN(e){let t=y.create(e.position.line,e.position.character);if(e.tokens.length===0)return new xN([],b.create(t,t));let n=[];for(;e.index<e.tokens.length;){let t=pN(e,n[n.length-1]);t&&n.push(t)}let r=n[0]?.range.start??t,i=n[n.length-1]?.range.end??t;return new xN(n,b.create(r,i))}o(fN,`parseJSDocComment`);function pN(e,t){let n=e.tokens[e.index];if(n.type===`tag`)return _N(e,!1);if(n.type===`text`||n.type===`inline-tag`)return hN(e);mN(n,t),e.index++}o(pN,`parseJSDocElement`);function mN(e,t){if(t){let n=new EN(``,e.range);`inlines`in t?t.inlines.push(n):t.content.inlines.push(n)}}o(mN,`appendEmptyLine`);function hN(e){let t=e.tokens[e.index],n=t,r=t,i=[];for(;t&&t.type!==`break`&&t.type!==`tag`;)i.push(gN(e)),r=t,t=e.tokens[e.index];return new TN(i,b.create(n.range.start,r.range.end))}o(hN,`parseJSDocText`);function gN(e){return e.tokens[e.index].type===`inline-tag`?_N(e,!0):vN(e)}o(gN,`parseJSDocInline`);function _N(e,t){let n=e.tokens[e.index++],r=n.content.substring(1);if(e.tokens[e.index]?.type===`text`)if(t){let i=vN(e);return new SN(r,new TN([i],i.range),t,b.create(n.range.start,i.range.end))}else{let i=hN(e);return new SN(r,i,t,b.create(n.range.start,i.range.end))}else{let e=n.range;return new SN(r,new TN([],e),t,e)}}o(_N,`parseJSDocTag`);function vN(e){let t=e.tokens[e.index++];return new EN(t.content,t.range)}o(vN,`parseJSDocLine`);function yN(e){if(!e)return yN({start:`/**`,end:`*/`,line:`*`});let{start:t,end:n,line:r}=e;return{start:bN(t,!0),end:bN(n,!1),line:bN(r,!0)}}o(yN,`normalizeOptions`);function bN(e,t){if(typeof e==`string`||typeof e==`object`){let n=typeof e==`string`?ka(e):e.source;return RegExp(t?`^\\s*${n}`:`\\s*${n}\\s*$`)}else return e}o(bN,`normalizeOption`);var xN=class{static{o(this,`JSDocCommentImpl`)}constructor(e,t){this.elements=e,this.range=t}getTag(e){return this.getAllTags().find(t=>t.name===e)}getTags(e){return this.getAllTags().filter(t=>t.name===e)}getAllTags(){return this.elements.filter(e=>`name`in e)}toString(){let e=``;for(let t of this.elements)if(e.length===0)e=t.toString();else{let n=t.toString();e+=DN(e)+n}return e.trim()}toMarkdown(e){let t=``;for(let n of this.elements)if(t.length===0)t=n.toMarkdown(e);else{let r=n.toMarkdown(e);t+=DN(t)+r}return t.trim()}},SN=class{static{o(this,`JSDocTagImpl`)}constructor(e,t,n,r){this.name=e,this.content=t,this.inline=n,this.range=r}toString(){let e=`@${this.name}`,t=this.content.toString();return this.content.inlines.length===1?e=`${e} ${t}`:this.content.inlines.length>1&&(e=`${e}
150
+ ${t}`),this.inline?`{${e}}`:e}toMarkdown(e){return e?.renderTag?.(this)??this.toMarkdownDefault(e)}toMarkdownDefault(e){let t=this.content.toMarkdown(e);if(this.inline){let n=CN(this.name,t,e??{});if(typeof n==`string`)return n}let n=``;e?.tag===`italic`||e?.tag===void 0?n=`*`:e?.tag===`bold`?n=`**`:e?.tag===`bold-italic`&&(n=`***`);let r=`${n}@${this.name}${n}`;return this.content.inlines.length===1?r=`${r} \u2014 ${t}`:this.content.inlines.length>1&&(r=`${r}
151
+ ${t}`),this.inline?`{${r}}`:r}};function CN(e,t,n){if(e===`linkplain`||e===`linkcode`||e===`link`){let r=t.indexOf(` `),i=t;if(r>0){let e=uN(t,r);i=t.substring(e),t=t.substring(0,r)}return(e===`linkcode`||e===`link`&&n.link===`code`)&&(i=`\`${i}\``),n.renderLink?.(t,i)??wN(t,i)}}o(CN,`renderInlineTag`);function wN(e,t){try{return nM.parse(e,!0),`[${t}](${e})`}catch{return e}}o(wN,`renderLinkDefault`);var TN=class{static{o(this,`JSDocTextImpl`)}constructor(e,t){this.inlines=e,this.range=t}toString(){let e=``;for(let t=0;t<this.inlines.length;t++){let n=this.inlines[t],r=this.inlines[t+1];e+=n.toString(),r&&r.range.start.line>n.range.start.line&&(e+=`
152
+ `)}return e}toMarkdown(e){let t=``;for(let n=0;n<this.inlines.length;n++){let r=this.inlines[n],i=this.inlines[n+1];t+=r.toMarkdown(e),i&&i.range.start.line>r.range.start.line&&(t+=`
153
+ `)}return t}},EN=class{static{o(this,`JSDocLineImpl`)}constructor(e,t){this.text=e,this.range=t}toString(){return this.text}toMarkdown(){return this.text}};function DN(e){return e.endsWith(`
154
+ `)?`
155
+ `:`
156
+
157
+ `}o(DN,`fillNewlines`);var ON=class{static{o(this,`JSDocDocumentationProvider`)}constructor(e){this.indexManager=e.shared.workspace.IndexManager,this.commentProvider=e.documentation.CommentProvider}getDocumentation(e){let t=this.commentProvider.getComment(e);if(t&&nN(t))return tN(t).toMarkdown({renderLink:o((t,n)=>this.documentationLinkRenderer(e,t,n),`renderLink`),renderTag:o(t=>this.documentationTagRenderer(e,t),`renderTag`)})}documentationLinkRenderer(e,t,n){let r=this.findNameInLocalSymbols(e,t)??this.findNameInGlobalScope(e,t);if(r&&r.nameSegment){let e=r.nameSegment.range.start.line+1,t=r.nameSegment.range.start.character+1;return`[${n}](${r.documentUri.with({fragment:`L${e},${t}`}).toString()})`}else return}documentationTagRenderer(e,t){}findNameInLocalSymbols(e,t){let n=On(e).localSymbols;if(!n)return;let r=e;do{let e=n.getStream(r).find(e=>e.name===t);if(e)return e;r=r.$container}while(r)}findNameInGlobalScope(e,t){return this.indexManager.allElements().find(e=>e.name===t)}},kN=class{static{o(this,`DefaultCommentProvider`)}constructor(e){this.grammarConfig=()=>e.parser.GrammarConfig}getComment(e){return EM(e)?e.$comment:qi(e.$cstNode,this.grammarConfig().multilineCommentRules)?.text}},AN=class{static{o(this,`DefaultAsyncParser`)}constructor(e){this.syncParser=e.parser.LangiumParser}parse(e,t){return Promise.resolve(this.syncParser.parse(e))}},jN=class{static{o(this,`AbstractThreadedAsyncParser`)}constructor(e){this.threadCount=8,this.terminationDelay=200,this.workerPool=[],this.queue=[],this.hydrator=e.serializer.Hydrator}initializeWorkers(){for(;this.workerPool.length<this.threadCount;){let e=this.createWorker();e.onReady(()=>{if(this.queue.length>0){let t=this.queue.shift();t&&(e.lock(),t.resolve(e))}}),this.workerPool.push(e)}}async parse(e,t){let n=await this.acquireParserWorker(t),r=new qj,i,a=t.onCancellationRequested(()=>{i=setTimeout(()=>{this.terminateWorker(n)},this.terminationDelay)});return n.parse(e).then(e=>{let t=this.hydrator.hydrate(e);r.resolve(t)}).catch(e=>{r.reject(e)}).finally(()=>{a.dispose(),clearTimeout(i)}),r.promise}terminateWorker(e){e.terminate();let t=this.workerPool.indexOf(e);t>=0&&this.workerPool.splice(t,1)}async acquireParserWorker(e){this.initializeWorkers();for(let e of this.workerPool)if(e.ready)return e.lock(),e;let t=new qj;return e.onCancellationRequested(()=>{let e=this.queue.indexOf(t);e>=0&&this.queue.splice(e,1),t.reject(Gj)}),this.queue.push(t),t.promise}},MN=class{static{o(this,`ParserWorker`)}get ready(){return this._ready}get onReady(){return this.onReadyEmitter.event}constructor(e,t,n,r){this.onReadyEmitter=new HM.Emitter,this.deferred=new qj,this._ready=!0,this._parsing=!1,this.sendMessage=e,this._terminate=r,t(e=>{let t=e;this.deferred.resolve(t),this.unlock()}),n(e=>{this.deferred.reject(e),this.unlock()})}terminate(){this.deferred.reject(Gj),this._terminate()}lock(){this._ready=!1}unlock(){this._parsing=!1,this._ready=!0,this.onReadyEmitter.fire()}parse(e){if(this._parsing)throw Error(`Parser worker is busy`);return this._parsing=!0,this.deferred=new qj,this.sendMessage(e),this.deferred.promise}},NN=class{static{o(this,`DefaultWorkspaceLock`)}constructor(){this.previousTokenSource=new Z.CancellationTokenSource,this.writeQueue=[],this.readQueue=[],this.done=!0}write(e){this.cancelWrite();let t=Uj();return this.previousTokenSource=t,this.enqueue(this.writeQueue,e,t.token)}read(e){return this.enqueue(this.readQueue,e)}enqueue(e,t,n=Z.CancellationToken.None){let r=new qj,i={action:t,deferred:r,cancellationToken:n};return e.push(i),this.performNextOperation(),r.promise}async performNextOperation(){if(!this.done)return;let e=[];if(this.writeQueue.length>0)e.push(this.writeQueue.shift());else if(this.readQueue.length>0)e.push(...this.readQueue.splice(0,this.readQueue.length));else return;this.done=!1,await Promise.all(e.map(async({action:e,deferred:t,cancellationToken:n})=>{try{let r=await Promise.resolve().then(()=>e(n));t.resolve(r)}catch(e){Kj(e)?t.resolve(void 0):t.reject(e)}})),this.done=!0,this.performNextOperation()}cancelWrite(){this.previousTokenSource.cancel()}},PN=class{static{o(this,`DefaultHydrator`)}constructor(e){this.grammarElementIdMap=new mM,this.tokenTypeIdMap=new mM,this.grammar=e.Grammar,this.lexer=e.parser.Lexer,this.linker=e.references.Linker}dehydrate(e){return{lexerErrors:e.lexerErrors,lexerReport:e.lexerReport?this.dehydrateLexerReport(e.lexerReport):void 0,parserErrors:e.parserErrors.map(e=>({...e,message:e.message})),value:this.dehydrateAstNode(e.value,this.createDehyrationContext(e.value))}}dehydrateLexerReport(e){return e}createDehyrationContext(e){let t=new Map,n=new Map;for(let n of Nn(e))t.set(n,{});if(e.$cstNode)for(let t of Li(e.$cstNode))n.set(t,{});return{astNodes:t,cstNodes:n}}dehydrateAstNode(e,t){let n=t.astNodes.get(e);n.$type=e.$type,n.$containerIndex=e.$containerIndex,n.$containerProperty=e.$containerProperty,e.$cstNode!==void 0&&(n.$cstNode=this.dehydrateCstNode(e.$cstNode,t));for(let[r,i]of Object.entries(e))if(!r.startsWith(`$`))if(Array.isArray(i)){let e=[];n[r]=e;for(let n of i)j(n)?e.push(this.dehydrateAstNode(n,t)):ln(n)?e.push(this.dehydrateReference(n,t)):e.push(n)}else j(i)?n[r]=this.dehydrateAstNode(i,t):ln(i)?n[r]=this.dehydrateReference(i,t):i!==void 0&&(n[r]=i);return n}dehydrateReference(e,t){let n={};return n.$refText=e.$refText,e.$refNode&&(n.$refNode=t.cstNodes.get(e.$refNode)),n}dehydrateCstNode(e,t){let n=t.cstNodes.get(e);return gn(e)?n.fullText=e.fullText:n.grammarSource=this.getGrammarElementId(e.grammarSource),n.hidden=e.hidden,n.astNode=t.astNodes.get(e.astNode),mn(e)?n.content=e.content.map(e=>this.dehydrateCstNode(e,t)):hn(e)&&(n.tokenType=e.tokenType.name,n.offset=e.offset,n.length=e.length,n.startLine=e.range.start.line,n.startColumn=e.range.start.character,n.endLine=e.range.end.line,n.endColumn=e.range.end.character),n}hydrate(e){let t=e.value,n=this.createHydrationContext(t);return`$cstNode`in t&&this.hydrateCstNode(t.$cstNode,n),{lexerErrors:e.lexerErrors,lexerReport:e.lexerReport,parserErrors:e.parserErrors,value:this.hydrateAstNode(t,n)}}createHydrationContext(e){let t=new Map,n=new Map;for(let n of Nn(e))t.set(n,{});let r;if(e.$cstNode)for(let t of Li(e.$cstNode)){let e;`fullText`in t?(e=new rj(t.fullText),r=e):`content`in t?e=new tj:`tokenType`in t&&(e=this.hydrateCstLeafNode(t)),e&&(n.set(t,e),e.root=r)}return{astNodes:t,cstNodes:n}}hydrateAstNode(e,t){let n=t.astNodes.get(e);n.$type=e.$type,n.$containerIndex=e.$containerIndex,n.$containerProperty=e.$containerProperty,e.$cstNode&&(n.$cstNode=t.cstNodes.get(e.$cstNode));for(let[r,i]of Object.entries(e))if(!r.startsWith(`$`))if(Array.isArray(i)){let e=[];n[r]=e;for(let a of i)j(a)?e.push(this.setParent(this.hydrateAstNode(a,t),n)):ln(a)?e.push(this.hydrateReference(a,n,r,t)):e.push(a)}else j(i)?n[r]=this.setParent(this.hydrateAstNode(i,t),n):ln(i)?n[r]=this.hydrateReference(i,n,r,t):i!==void 0&&(n[r]=i);return n}setParent(e,t){return e.$container=t,e}hydrateReference(e,t,n,r){return this.linker.buildReference(t,n,r.cstNodes.get(e.$refNode),e.$refText)}hydrateCstNode(e,t,n=0){let r=t.cstNodes.get(e);if(typeof e.grammarSource==`number`&&(r.grammarSource=this.getGrammarElement(e.grammarSource)),r.astNode=t.astNodes.get(e.astNode),mn(r))for(let i of e.content){let e=this.hydrateCstNode(i,t,n++);r.content.push(e)}return r}hydrateCstLeafNode(e){let t=this.getTokenType(e.tokenType),n=e.offset,r=e.length,i=e.startLine,a=e.startColumn,o=e.endLine,s=e.endColumn,c=e.hidden;return new ej(n,r,{start:{line:i,character:a},end:{line:o,character:s}},t,c)}getTokenType(e){return this.lexer.definition[e]}getGrammarElementId(e){if(e)return this.grammarElementIdMap.size===0&&this.createGrammarElementIdMap(),this.grammarElementIdMap.get(e)}getGrammarElement(e){return this.grammarElementIdMap.size===0&&this.createGrammarElementIdMap(),this.grammarElementIdMap.getKey(e)}createGrammarElementIdMap(){let e=0;for(let t of Nn(this.grammar))Hn(t)&&this.grammarElementIdMap.set(t,e++)}};function FN(e){return{documentation:{CommentProvider:o(e=>new kN(e),`CommentProvider`),DocumentationProvider:o(e=>new ON(e),`DocumentationProvider`)},parser:{AsyncParser:o(e=>new AN(e),`AsyncParser`),GrammarConfig:o(e=>vo(e),`GrammarConfig`),LangiumParser:o(e=>Fj(e),`LangiumParser`),CompletionParser:o(e=>Pj(e),`CompletionParser`),ValueConverter:o(()=>new Rj,`ValueConverter`),TokenBuilder:o(()=>new Lj,`TokenBuilder`),Lexer:o(e=>new ZM(e),`Lexer`),ParserErrorMessageProvider:o(()=>new dj,`ParserErrorMessageProvider`),LexerErrorMessageProvider:o(()=>new YM,`LexerErrorMessageProvider`)},workspace:{AstNodeLocator:o(()=>new VM,`AstNodeLocator`),AstNodeDescriptionProvider:o(e=>new zM(e),`AstNodeDescriptionProvider`),ReferenceDescriptionProvider:o(e=>new BM(e),`ReferenceDescriptionProvider`)},references:{Linker:o(e=>new lM(e),`Linker`),NameProvider:o(()=>new dM,`NameProvider`),ScopeProvider:o(e=>new TM(e),`ScopeProvider`),ScopeComputation:o(e=>new hM(e),`ScopeComputation`),References:o(e=>new fM(e),`References`)},serializer:{Hydrator:o(e=>new PN(e),`Hydrator`),JsonSerializer:o(e=>new OM(e),`JsonSerializer`)},validation:{DocumentValidator:o(e=>new PM(e),`DocumentValidator`),ValidationRegistry:o(e=>new MM(e),`ValidationRegistry`)},shared:o(()=>e.shared,`shared`)}}o(FN,`createDefaultCoreModule`);function IN(e){return{ServiceRegistry:o(e=>new kM(e),`ServiceRegistry`),workspace:{LangiumDocuments:o(e=>new sM(e),`LangiumDocuments`),LangiumDocumentFactory:o(e=>new oM(e),`LangiumDocumentFactory`),DocumentBuilder:o(e=>new KM(e),`DocumentBuilder`),IndexManager:o(e=>new qM(e),`IndexManager`),WorkspaceManager:o(e=>new JM(e),`WorkspaceManager`),FileSystemProvider:o(t=>e.fileSystemProvider(t),`FileSystemProvider`),WorkspaceLock:o(()=>new NN,`WorkspaceLock`),ConfigurationProvider:o(e=>new UM(e),`ConfigurationProvider`)},profilers:{}}}o(IN,`createDefaultSharedCoreModule`);var LN;(function(e){e.merge=(e,t)=>WN(WN({},e),t)})(LN||={});function RN(e,t,n,r,i,a,o,s,c){return VN([e,t,n,r,i,a,o,s,c].reduce(WN,{}))}o(RN,`inject`);var zN=Symbol(`isProxy`);function BN(e){if(e&&e[zN])for(let t of Object.values(e))BN(t);return e}o(BN,`eagerLoad`);function VN(e,t){let n=new Proxy({},{deleteProperty:o(()=>!1,`deleteProperty`),set:o(()=>{throw Error(`Cannot set property on injected service container`)},`set`),get:o((r,i)=>i===zN?!0:UN(r,i,e,t||n),`get`),getOwnPropertyDescriptor:o((r,i)=>(UN(r,i,e,t||n),Object.getOwnPropertyDescriptor(r,i)),`getOwnPropertyDescriptor`),has:o((t,n)=>n in e,`has`),ownKeys:o(()=>[...Object.getOwnPropertyNames(e)],`ownKeys`)});return n}o(VN,`_inject`);var HN=Symbol();function UN(e,t,n,r){if(t in e){if(e[t]instanceof Error)throw Error(`Construction failure. Please make sure that your dependencies are constructable. Cause: `+e[t]);if(e[t]===HN)throw Error(`Cycle detected. Please make "`+String(t)+`" lazy. Visit https://langium.org/docs/reference/configuration-services/#resolving-cyclic-dependencies`);return e[t]}else if(t in n){let i=n[t];e[t]=HN;try{e[t]=typeof i==`function`?i(r):VN(i,r)}catch(n){throw e[t]=n instanceof Error?n:void 0,n}return e[t]}else return}o(UN,`_resolve`);function WN(e,t){if(t){for(let[n,r]of Object.entries(t))if(r!=null)if(typeof r==`object`){let t=e[n];typeof t==`object`&&t?e[n]=WN(t,r):e[n]=WN({},r)}else e[n]=r}return e}o(WN,`_merge`);var GN={indentTokenName:`INDENT`,dedentTokenName:`DEDENT`,whitespaceTokenName:`WS`,ignoreIndentationDelimiters:[]},KN;(function(e){e.REGULAR=`indentation-sensitive`,e.IGNORE_INDENTATION=`ignore-indentation`})(KN||={});var qN=class extends Lj{static{o(this,`IndentationAwareTokenBuilder`)}constructor(e=GN){super(),this.indentationStack=[0],this.whitespaceRegExp=/[ \t]+/y,this.options={...GN,...e},this.indentTokenType=tb({name:this.options.indentTokenName,pattern:this.indentMatcher.bind(this),line_breaks:!1}),this.dedentTokenType=tb({name:this.options.dedentTokenName,pattern:this.dedentMatcher.bind(this),line_breaks:!1})}buildTokens(e,t){let n=super.buildTokens(e,t);if(!QM(n))throw Error(`Invalid tokens built by default builder`);let{indentTokenName:r,dedentTokenName:i,whitespaceTokenName:a,ignoreIndentationDelimiters:o}=this.options,s,c,l,u=[];for(let e of n){for(let[t,n]of o)e.name===t?e.PUSH_MODE=KN.IGNORE_INDENTATION:e.name===n&&(e.POP_MODE=!0);e.name===i?s=e:e.name===r?c=e:e.name===a?l=e:u.push(e)}if(!s||!c||!l)throw Error(`Some indentation/whitespace tokens not found!`);return o.length>0?{modes:{[KN.REGULAR]:[s,c,...u,l],[KN.IGNORE_INDENTATION]:[...u,l]},defaultMode:KN.REGULAR}:[s,c,l,...u]}flushLexingReport(e){return{...super.flushLexingReport(e),remainingDedents:this.flushRemainingDedents(e)}}isStartOfLine(e,t){return t===0||`\r
158
+ `.includes(e[t-1])}matchWhitespace(e,t,n,r){this.whitespaceRegExp.lastIndex=t;let i=this.whitespaceRegExp.exec(e);return{currIndentLevel:i?.[0].length??0,prevIndentLevel:this.indentationStack.at(-1),match:i}}createIndentationTokenInstance(e,t,n,r){let i=this.getLineNumber(t,r);return ib(e,n,r,r+n.length,i,i,1,n.length)}getLineNumber(e,t){return e.substring(0,t).split(/\r\n|\r|\n/).length}indentMatcher(e,t,n,r){if(!this.isStartOfLine(e,t))return null;let{currIndentLevel:i,prevIndentLevel:a,match:o}=this.matchWhitespace(e,t,n,r);return i<=a?null:(this.indentationStack.push(i),o)}dedentMatcher(e,t,n,r){if(!this.isStartOfLine(e,t))return null;let{currIndentLevel:i,prevIndentLevel:a,match:o}=this.matchWhitespace(e,t,n,r);if(i>=a)return null;let s=this.indentationStack.lastIndexOf(i);if(s===-1)return this.diagnostics.push({severity:`error`,message:`Invalid dedent level ${i} at offset: ${t}. Current indentation stack: ${this.indentationStack}`,offset:t,length:o?.[0]?.length??0,line:this.getLineNumber(e,t),column:1}),null;let c=this.indentationStack.length-s-1,l=e.substring(0,t).match(/[\r\n]+$/)?.[0].length??1;for(let r=0;r<c;r++){let r=this.createIndentationTokenInstance(this.dedentTokenType,e,``,t-(l-1));n.push(r),this.indentationStack.pop()}return null}buildTerminalToken(e){let t=super.buildTerminalToken(e),{indentTokenName:n,dedentTokenName:r,whitespaceTokenName:i}=this.options;return t.name===n?this.indentTokenType:t.name===r?this.dedentTokenType:t.name===i?tb({name:i,pattern:this.whitespaceRegExp,group:Uy.SKIPPED}):t}flushRemainingDedents(e){let t=[];for(;this.indentationStack.length>1;)t.push(this.createIndentationTokenInstance(this.dedentTokenType,e,``,e.length)),this.indentationStack.pop();return this.indentationStack=[0],t}},JN=class extends ZM{static{o(this,`IndentationAwareLexer`)}constructor(e){if(super(e),e.parser.TokenBuilder instanceof qN)this.indentationTokenBuilder=e.parser.TokenBuilder;else throw Error(`IndentationAwareLexer requires an accompanying IndentationAwareTokenBuilder`)}tokenize(e,t=XM){let n=super.tokenize(e),r=n.report;t?.mode===`full`&&n.tokens.push(...r.remainingDedents),r.remainingDedents=[];let{indentTokenType:i,dedentTokenType:a}=this.indentationTokenBuilder,o=i.tokenTypeIdx,s=a.tokenTypeIdx,c=[],l=n.tokens.length-1;for(let e=0;e<l;e++){let t=n.tokens[e],r=n.tokens[e+1];if(t.tokenTypeIdx===o&&r.tokenTypeIdx===s){e++;continue}c.push(t)}return l>=0&&c.push(n.tokens[l]),n.tokens=c,n}},YN={};l(YN,{AstUtils:()=>wn,BiMap:()=>mM,Cancellation:()=>Z,ContextCache:()=>SM,CstUtils:()=>cn,DONE_RESULT:()=>xn,Deferred:()=>qj,Disposable:()=>GM,DisposableCache:()=>bM,DocumentCache:()=>CM,EMPTY_STREAM:()=>bn,ErrorWithLocation:()=>aa,GrammarUtils:()=>ia,MultiMap:()=>pM,OperationCancelled:()=>Gj,Reduction:()=>Cn,RegExpUtils:()=>ca,SimpleCache:()=>xM,StreamImpl:()=>_n,TreeStreamImpl:()=>Sn,URI:()=>nM,UriTrie:()=>aM,UriUtils:()=>iM,WorkspaceCache:()=>wM,assertCondition:()=>sa,assertUnreachable:()=>oa,delayNextTick:()=>Bj,interruptAndCheck:()=>Q,isOperationCancelled:()=>Kj,loadGrammarFromJson:()=>tP,setInterruptionPeriod:()=>Wj,startCancelableOperation:()=>Uj,stream:()=>M}),d(YN,HM);var XN=class{static{o(this,`EmptyFileSystemProvider`)}stat(e){throw Error(`No file system is available.`)}statSync(e){throw Error(`No file system is available.`)}async exists(){return!1}existsSync(){return!1}readBinary(){throw Error(`No file system is available.`)}readBinarySync(){throw Error(`No file system is available.`)}readFile(){throw Error(`No file system is available.`)}readFileSync(){throw Error(`No file system is available.`)}async readDirectory(){return[]}readDirectorySync(){return[]}},ZN={fileSystemProvider:o(()=>new XN,`fileSystemProvider`)},QN={Grammar:o(()=>void 0,`Grammar`),LanguageMetaData:o(()=>({caseInsensitive:!1,fileExtensions:[`.langium`],languageId:`langium`}),`LanguageMetaData`)},$N={AstReflection:o(()=>new Fi,`AstReflection`)};function eP(){let e=RN(IN(ZN),$N),t=RN(FN({shared:e}),QN);return e.ServiceRegistry.register(t),t}o(eP,`createMinimalGrammarServices`);function tP(e){let t=eP(),n=t.serializer.JsonSerializer.deserialize(e);return t.shared.workspace.LangiumDocumentFactory.fromModel(n,nM.parse(`memory:/${n.name??`grammar`}.langium`)),n}o(tP,`loadGrammarFromJson`),d(sn,YN);var nP=class{static{o(this,`DefaultLangiumProfiler`)}constructor(e){this.activeCategories=new Set,this.allCategories=new Set([`validating`,`parsing`,`linking`]),this.activeCategories=e??new Set(this.allCategories),this.records=new pM}isActive(e){return this.activeCategories.has(e)}start(...e){e?e.forEach(e=>this.activeCategories.add(e)):this.activeCategories=new Set(this.allCategories)}stop(...e){e?e.forEach(e=>this.activeCategories.delete(e)):this.activeCategories.clear()}createTask(e,t){if(!this.isActive(e))throw Error(`Category "${e}" is not active.`);return console.log(`Creating profiling task for '${e}.${t}'.`),new rP(t=>this.records.add(e,this.dumpRecord(e,t)),t)}dumpRecord(e,t){console.info(`Task ${e}.${t.identifier} executed in ${t.duration.toFixed(2)}ms and ended at ${t.date.toISOString()}`);let n=[];for(let e of t.entries.keys()){let r=t.entries.get(e),i=r.reduce((e,t)=>e+t);n.push({name:`${t.identifier}.${e}`,count:r.length,duration:i})}let r=t.duration-n.map(e=>e.duration).reduce((e,t)=>e+t,0);n.push({name:t.identifier,count:1,duration:r}),n.sort((e,t)=>t.duration-e.duration);function i(e){return Math.round(100*e)/100}return o(i,`Round`),console.table(n.map(e=>({Element:e.name,Count:e.count,"Self %":i(100*e.duration/t.duration),"Time (ms)":i(e.duration)}))),t}getRecords(...e){return e.length===0?this.records.values():this.records.entries().filter(t=>e.some(e=>e===t[0])).flatMap(e=>e[1])}},rP=class{static{o(this,`ProfilingTask`)}constructor(e,t){this.stack=[],this.entries=new pM,this.addRecord=e,this.identifier=t}start(){if(this.startTime!==void 0)throw Error(`Task "${this.identifier}" is already started.`);this.startTime=performance.now()}stop(){if(this.startTime===void 0)throw Error(`Task "${this.identifier}" was not started.`);if(this.stack.length!==0)throw Error(`Task "${this.identifier}" cannot be stopped before sub-task(s): ${this.stack.map(e=>e.id).join(`, `)}.`);let e={identifier:this.identifier,date:new Date,duration:performance.now()-this.startTime,entries:this.entries};this.addRecord(e),this.startTime=void 0,this.entries.clear()}startSubTask(e){this.stack.push({id:e,start:performance.now(),content:0})}stopSubTask(e){let t=this.stack.pop();if(!t)throw Error(`Task "${this.identifier}.${e}" was not started.`);if(t.id!==e)throw Error(`Sub-Task "${t.id}" is not already stopped.`);let n=performance.now()-t.start;this.stack.at(-1)!==void 0&&(this.stack[this.stack.length-1].content+=n);let r=n-t.content;this.entries.add(e,r)}},iP;(e=>{e.Terminals={ARROW_DIRECTION:/L|R|T|B/,ARROW_GROUP:/\{group\}/,ARROW_INTO:/<|>/,ACC_DESCR:/[\t ]*accDescr(?:[\t ]*:([^\n\r]*?(?=%%)|[^\n\r]*)|\s*{([^}]*)})/,ACC_TITLE:/[\t ]*accTitle[\t ]*:(?:[^\n\r]*?(?=%%)|[^\n\r]*)/,TITLE:/[\t ]*title(?:[\t ][^\n\r]*?(?=%%)|[\t ][^\n\r]*|)/,STRING:/"([^"\\]|\\.)*"|'([^'\\]|\\.)*'/,ID:/[\w]([-\w]*\w)?/,NEWLINE:/\r?\n/,WHITESPACE:/[\t ]+/,YAML:/---[\t ]*\r?\n(?:[\S\s]*?\r?\n)?---(?:\r?\n|(?!\S))/,DIRECTIVE:/[\t ]*%%{[\S\s]*?}%%(?:\r?\n|(?!\S))/,SINGLE_LINE_COMMENT:/[\t ]*%%[^\n\r]*/,ARCH_ICON:/\([\w-:]+\)/,ARCH_TITLE:/\[(?:"([^"\\]|\\.)*"|'([^'\\]|\\.)*'|[\w ]+)\]/}})(iP||={});var aP;(e=>{e.Terminals={EM_ID:/[_a-zA-Z][\w_]*/,EM_FID:/\d{1,3}/,EM_DATA_INLINE:/\{(.*)\}|"(.*)"|'(.*)'/,EM_DATA_BLOCK:/\{[\t ]*\r?\n(?:[\S\s]*?\r?\n)?\}(?:\r?\n|(?!\S))/,EM_ACC_DESCR:/[\t ]*accDescr(?:[\t ]*:([^\n\r]*?(?=%%)|[^\n\r]*)|\s*{([^}]*)})/,EM_ACC_TITLE:/[\t ]*accTitle[\t ]*:(?:[^\n\r]*?(?=%%)|[^\n\r]*)/,EM_TITLE:/[\t ]*title(?:[\t ][^\n\r]*?(?=%%)|[\t ][^\n\r]*|)/,EM_WS:/\s+/,EM_YAML:/---[\t ]*\r?\n(?:[\S\s]*?\r?\n)?---(?:\r?\n|(?!\S))/,EM_DIRECTIVE:/[\t ]*%%{[\S\s]*?}%%(?:\r?\n|(?!\S))/,EM_SINGLE_LINE_COMMENT:/[\t ]*%%[^\n\r]*/,EM_ML_COMMENT:/\/\*[\s\S]*?\*\//,EM_SL_COMMENT:/\/\/[^\n\r]*/}})(aP||={});var oP;(e=>{e.Terminals={ACC_DESCR:/[\t ]*accDescr(?:[\t ]*:([^\n\r]*?(?=%%)|[^\n\r]*)|\s*{([^}]*)})/,ACC_TITLE:/[\t ]*accTitle[\t ]*:(?:[^\n\r]*?(?=%%)|[^\n\r]*)/,TITLE:/[\t ]*title(?:[\t ][^\n\r]*?(?=%%)|[\t ][^\n\r]*|)/,INT:/0|[1-9][0-9]*(?!\.)/,STRING:/"([^"\\]|\\.)*"|'([^'\\]|\\.)*'/,NEWLINE:/\r?\n/,WHITESPACE:/[\t ]+/,YAML:/---[\t ]*\r?\n(?:[\S\s]*?\r?\n)?---(?:\r?\n|(?!\S))/,DIRECTIVE:/[\t ]*%%{[\S\s]*?}%%(?:\r?\n|(?!\S))/,SINGLE_LINE_COMMENT:/[\t ]*%%[^\n\r]*/,REFERENCE:/\w([-\./\w]*[-\w])?/}})(oP||={});var sP;(e=>{e.Terminals={ACC_DESCR:/[\t ]*accDescr(?:[\t ]*:([^\n\r]*?(?=%%)|[^\n\r]*)|\s*{([^}]*)})/,ACC_TITLE:/[\t ]*accTitle[\t ]*:(?:[^\n\r]*?(?=%%)|[^\n\r]*)/,TITLE:/[\t ]*title(?:[\t ][^\n\r]*?(?=%%)|[\t ][^\n\r]*|)/,NEWLINE:/\r?\n/,WHITESPACE:/[\t ]+/,YAML:/---[\t ]*\r?\n(?:[\S\s]*?\r?\n)?---(?:\r?\n|(?!\S))/,DIRECTIVE:/[\t ]*%%{[\S\s]*?}%%(?:\r?\n|(?!\S))/,SINGLE_LINE_COMMENT:/[\t ]*%%[^\n\r]*/}})(sP||={});var cP;(e=>{e.Terminals={ACC_DESCR:/[\t ]*accDescr(?:[\t ]*:([^\n\r]*?(?=%%)|[^\n\r]*)|\s*{([^}]*)})/,ACC_TITLE:/[\t ]*accTitle[\t ]*:(?:[^\n\r]*?(?=%%)|[^\n\r]*)/,TITLE:/[\t ]*title(?:[\t ][^\n\r]*?(?=%%)|[\t ][^\n\r]*|)/,INT:/0|[1-9][0-9]*(?!\.)/,STRING:/"([^"\\]|\\.)*"|'([^'\\]|\\.)*'/,NEWLINE:/\r?\n/,WHITESPACE:/[\t ]+/,YAML:/---[\t ]*\r?\n(?:[\S\s]*?\r?\n)?---(?:\r?\n|(?!\S))/,DIRECTIVE:/[\t ]*%%{[\S\s]*?}%%(?:\r?\n|(?!\S))/,SINGLE_LINE_COMMENT:/[\t ]*%%[^\n\r]*/}})(cP||={});var lP;(e=>{e.Terminals={NUMBER_PIE:/(?:-?[0-9]+\.[0-9]+(?!\.))|(?:-?(0|[1-9][0-9]*)(?!\.))/,ACC_DESCR:/[\t ]*accDescr(?:[\t ]*:([^\n\r]*?(?=%%)|[^\n\r]*)|\s*{([^}]*)})/,ACC_TITLE:/[\t ]*accTitle[\t ]*:(?:[^\n\r]*?(?=%%)|[^\n\r]*)/,TITLE:/[\t ]*title(?:[\t ][^\n\r]*?(?=%%)|[\t ][^\n\r]*|)/,STRING:/"([^"\\]|\\.)*"|'([^'\\]|\\.)*'/,NEWLINE:/\r?\n/,WHITESPACE:/[\t ]+/,YAML:/---[\t ]*\r?\n(?:[\S\s]*?\r?\n)?---(?:\r?\n|(?!\S))/,DIRECTIVE:/[\t ]*%%{[\S\s]*?}%%(?:\r?\n|(?!\S))/,SINGLE_LINE_COMMENT:/[\t ]*%%[^\n\r]*/}})(lP||={});var uP;(e=>{e.Terminals={GRATICULE:/circle|polygon/,BOOLEAN:/true|false/,ACC_DESCR:/[\t ]*accDescr(?:[\t ]*:([^\n\r]*?(?=%%)|[^\n\r]*)|\s*{([^}]*)})/,ACC_TITLE:/[\t ]*accTitle[\t ]*:(?:[^\n\r]*?(?=%%)|[^\n\r]*)/,TITLE:/[\t ]*title(?:[\t ][^\n\r]*?(?=%%)|[\t ][^\n\r]*|)/,NUMBER:/(?:[0-9]+\.[0-9]+(?!\.))|(?:0|[1-9][0-9]*(?!\.))/,STRING:/"([^"\\]|\\.)*"|'([^'\\]|\\.)*'/,ID:/[\w]([-\w]*\w)?/,NEWLINE:/\r?\n/,WHITESPACE:/[\t ]+/,YAML:/---[\t ]*\r?\n(?:[\S\s]*?\r?\n)?---(?:\r?\n|(?!\S))/,DIRECTIVE:/[\t ]*%%{[\S\s]*?}%%(?:\r?\n|(?!\S))/,SINGLE_LINE_COMMENT:/[\t ]*%%[^\n\r]*/}})(uP||={});var dP;(e=>{e.Terminals={ACC_DESCR:/[\t ]*accDescr(?:[\t ]*:([^\n\r]*?(?=%%)|[^\n\r]*)|\s*{([^}]*)})/,ACC_TITLE:/[\t ]*accTitle[\t ]*:(?:[^\n\r]*?(?=%%)|[^\n\r]*)/,TITLE:/[\t ]*title(?:[\t ][^\n\r]*?(?=%%)|[\t ][^\n\r]*|)/,TREEMAP_KEYWORD:/treemap-beta|treemap/,CLASS_DEF:/classDef\s+([a-zA-Z_][a-zA-Z0-9_]+)(?:\s+([^;\r\n]*))?(?:;)?/,STYLE_SEPARATOR:/:::/,SEPARATOR:/:/,COMMA:/,/,INDENTATION:/[ \t]{1,}/,WS:/[ \t]+/,ML_COMMENT:/\%\%[^\n]*/,NL:/\r?\n/,ID2:/[a-zA-Z_][a-zA-Z0-9_]*/,NUMBER2:/[0-9_\.\,]+/,STRING2:/"[^"]*"|'[^']*'/}})(dP||={});var fP;(e=>{e.Terminals={ACC_DESCR:/[\t ]*accDescr(?:[\t ]*:([^\n\r]*?(?=%%)|[^\n\r]*)|\s*{([^}]*)})/,ACC_TITLE:/[\t ]*accTitle[\t ]*:(?:[^\n\r]*?(?=%%)|[^\n\r]*)/,TITLE:/[\t ]*title(?:[\t ][^\n\r]*?(?=%%)|[\t ][^\n\r]*|)/,INDENTATION:/[ \t]{1,}/,WS:/[ \t]+/,ML_COMMENT:/\%\%[^\n]*/,NL:/\r?\n/,STRING2:/"[^"]*"|'[^']*'/}})(fP||={});var pP;(e=>{e.Terminals={WARDLEY_NUMBER:/[0-9]+\.[0-9]+/,ARROW:/->/,LINK_PORT:/\+<>|\+>|\+</,LINK_ARROW:/-->|-\.->|>|\+'[^']*'<>|\+'[^']*'<|\+'[^']*'>/,LINK_LABEL:/;[^\n\r]+/,STRATEGY:/build|buy|outsource|market/,KW_WARDLEY:/wardley-beta/,KW_SIZE:/size/,KW_EVOLUTION:/evolution/,KW_ANCHOR:/anchor/,KW_COMPONENT:/component/,KW_LABEL:/label/,KW_INERTIA:/inertia/,KW_EVOLVE:/evolve/,KW_PIPELINE:/pipeline/,KW_NOTE:/note/,KW_ANNOTATIONS:/annotations/,KW_ANNOTATION:/annotation/,KW_ACCELERATOR:/accelerator/,KW_DEACCELERATOR:/deaccelerator/,NAME_WITH_SPACES:/(?!title\s|accTitle|accDescr)[A-Za-z](?:[A-Za-z0-9_()&]|-(?!>))*(?:[ \t]+[A-Za-z(](?:[A-Za-z0-9_()&]|-(?!>))*)*/,WS:/[ \t]+/,ACC_DESCR:/[\t ]*accDescr(?:[\t ]*:([^\n\r]*?(?=%%)|[^\n\r]*)|\s*{([^}]*)})/,ACC_TITLE:/[\t ]*accTitle[\t ]*:(?:[^\n\r]*?(?=%%)|[^\n\r]*)/,TITLE:/[\t ]*title(?:[\t ][^\n\r]*?(?=%%)|[\t ][^\n\r]*|)/,INT:/0|[1-9][0-9]*(?!\.)/,STRING:/"([^"\\]|\\.)*"|'([^'\\]|\\.)*'/,ID:/[\w]([-\w]*\w)?/,NEWLINE:/\r?\n/,WHITESPACE:/[\t ]+/,YAML:/---[\t ]*\r?\n(?:[\S\s]*?\r?\n)?---(?:\r?\n|(?!\S))/,DIRECTIVE:/[\t ]*%%{[\S\s]*?}%%(?:\r?\n|(?!\S))/,SINGLE_LINE_COMMENT:/[\t ]*%%[^\n\r]*/}})(pP||={}),{...iP.Terminals,...aP.Terminals,...oP.Terminals,...sP.Terminals,...cP.Terminals,...lP.Terminals,...uP.Terminals,...fP.Terminals,...dP.Terminals,...pP.Terminals};var mP={$type:`Accelerator`,name:`name`,x:`x`,y:`y`},hP={$type:`Anchor`,evolution:`evolution`,name:`name`,visibility:`visibility`},gP={$type:`Annotation`,number:`number`,text:`text`,x:`x`,y:`y`},_P={$type:`Annotations`,x:`x`,y:`y`},vP={$type:`Architecture`,accDescr:`accDescr`,accTitle:`accTitle`,edges:`edges`,groups:`groups`,junctions:`junctions`,services:`services`,title:`title`};function yP(e){return NF.isInstance(e,vP.$type)}o(yP,`isArchitecture`);var bP={$type:`Axis`,label:`label`,name:`name`},xP={$type:`Branch`,name:`name`,order:`order`};function SP(e){return NF.isInstance(e,xP.$type)}o(SP,`isBranch`);var CP={$type:`Checkout`,branch:`branch`},wP={$type:`CherryPicking`,id:`id`,parent:`parent`,tags:`tags`},TP={$type:`ClassDefStatement`,className:`className`,styleText:`styleText`},EP={$type:`Commit`,id:`id`,message:`message`,tags:`tags`,type:`type`};function DP(e){return NF.isInstance(e,EP.$type)}o(DP,`isCommit`);var OP={$type:`Common`,accDescr:`accDescr`,accTitle:`accTitle`,title:`title`},kP={$type:`Component`,decorator:`decorator`,evolution:`evolution`,inertia:`inertia`,label:`label`,name:`name`,visibility:`visibility`},AP={$type:`Curve`,entries:`entries`,label:`label`,name:`name`},jP={$type:`Deaccelerator`,name:`name`,x:`x`,y:`y`},MP={$type:`Decorator`,strategy:`strategy`},NP={$type:`Direction`,accDescr:`accDescr`,accTitle:`accTitle`,dir:`dir`,statements:`statements`,title:`title`},PP={$type:`Edge`,lhsDir:`lhsDir`,lhsGroup:`lhsGroup`,lhsId:`lhsId`,lhsInto:`lhsInto`,rhsDir:`rhsDir`,rhsGroup:`rhsGroup`,rhsId:`rhsId`,rhsInto:`rhsInto`,title:`title`},FP={$type:`EmDataEntity`,dataBlockValue:`dataBlockValue`,dataType:`dataType`,name:`name`},IP={$type:`EmFrame`},LP={$type:`EmGwt`,givenStatements:`givenStatements`,sourceFrame:`sourceFrame`,thenStatements:`thenStatements`,whenStatements:`whenStatements`},RP={$type:`EmGwtStatement`,entityIdentifier:`entityIdentifier`},zP={$type:`EmModelEntity`,name:`name`};function BP(e){return e===`rmo`||e===`readmodel`||e===`ui`||e===`cmd`||e===`command`||e===`evt`||e===`event`||e===`pcr`||e===`processor`}o(BP,`isEmModelEntityType`);var VP={$type:`EmNoteEntity`,dataBlockValue:`dataBlockValue`,dataType:`dataType`,sourceFrame:`sourceFrame`},HP={$type:`EmResetFrame`,dataInlineValue:`dataInlineValue`,dataReference:`dataReference`,dataType:`dataType`,entityIdentifier:`entityIdentifier`,modelEntityType:`modelEntityType`,name:`name`,sourceFrames:`sourceFrames`};function UP(e){return NF.isInstance(e,HP.$type)}o(UP,`isEmResetFrame`);var WP={$type:`EmTimeFrame`,dataInlineValue:`dataInlineValue`,dataReference:`dataReference`,dataType:`dataType`,entityIdentifier:`entityIdentifier`,modelEntityType:`modelEntityType`,name:`name`,sourceFrames:`sourceFrames`},GP={$type:`Entry`,axis:`axis`,value:`value`},KP={$type:`EventModel`,accDescr:`accDescr`,accTitle:`accTitle`,dataEntities:`dataEntities`,frames:`frames`,gwtEntities:`gwtEntities`,modelEntities:`modelEntities`,noteEntities:`noteEntities`,title:`title`},qP={$type:`Evolution`,stages:`stages`},JP={$type:`EvolutionStage`,boundary:`boundary`,name:`name`,secondName:`secondName`},YP={$type:`Evolve`,component:`component`,target:`target`},XP={$type:`GitGraph`,accDescr:`accDescr`,accTitle:`accTitle`,statements:`statements`,title:`title`};function ZP(e){return NF.isInstance(e,XP.$type)}o(ZP,`isGitGraph`);var QP={$type:`Group`,icon:`icon`,id:`id`,in:`in`,title:`title`},$P={$type:`Info`,accDescr:`accDescr`,accTitle:`accTitle`,title:`title`};function eF(e){return NF.isInstance(e,$P.$type)}o(eF,`isInfo`);var tF={$type:`Item`,classSelector:`classSelector`,name:`name`},nF={$type:`Junction`,id:`id`,in:`in`},rF={$type:`Label`,negX:`negX`,negY:`negY`,offsetX:`offsetX`,offsetY:`offsetY`},iF={$type:`Leaf`,classSelector:`classSelector`,name:`name`,value:`value`},aF={$type:`Link`,arrow:`arrow`,from:`from`,fromPort:`fromPort`,linkLabel:`linkLabel`,to:`to`,toPort:`toPort`},oF={$type:`Merge`,branch:`branch`,id:`id`,tags:`tags`,type:`type`};function sF(e){return NF.isInstance(e,oF.$type)}o(sF,`isMerge`);var cF={$type:`Note`,evolution:`evolution`,text:`text`,visibility:`visibility`},lF={$type:`Option`,name:`name`,value:`value`},uF={$type:`Packet`,accDescr:`accDescr`,accTitle:`accTitle`,blocks:`blocks`,title:`title`};function dF(e){return NF.isInstance(e,uF.$type)}o(dF,`isPacket`);var fF={$type:`PacketBlock`,bits:`bits`,end:`end`,label:`label`,start:`start`};function pF(e){return NF.isInstance(e,fF.$type)}o(pF,`isPacketBlock`);var mF={$type:`Pie`,accDescr:`accDescr`,accTitle:`accTitle`,sections:`sections`,showData:`showData`,title:`title`};function hF(e){return NF.isInstance(e,mF.$type)}o(hF,`isPie`);var gF={$type:`PieSection`,label:`label`,value:`value`};function _F(e){return NF.isInstance(e,gF.$type)}o(_F,`isPieSection`);var vF={$type:`Pipeline`,components:`components`,parent:`parent`},yF={$type:`PipelineComponent`,evolution:`evolution`,label:`label`,name:`name`},bF={$type:`Radar`,accDescr:`accDescr`,accTitle:`accTitle`,axes:`axes`,curves:`curves`,options:`options`,title:`title`},xF={$type:`Section`,classSelector:`classSelector`,name:`name`},SF={$type:`Service`,icon:`icon`,iconText:`iconText`,id:`id`,in:`in`,title:`title`},CF={$type:`Size`,height:`height`,width:`width`},wF={$type:`Statement`},TF={$type:`Treemap`,accDescr:`accDescr`,accTitle:`accTitle`,title:`title`,TreemapRows:`TreemapRows`};function EF(e){return NF.isInstance(e,TF.$type)}o(EF,`isTreemap`);var DF={$type:`TreemapRow`,indent:`indent`,item:`item`},OF={$type:`TreeNode`,indent:`indent`,name:`name`},kF={$type:`TreeView`,accDescr:`accDescr`,accTitle:`accTitle`,nodes:`nodes`,title:`title`},AF={$type:`Wardley`,accDescr:`accDescr`,accelerators:`accelerators`,accTitle:`accTitle`,anchors:`anchors`,annotation:`annotation`,annotations:`annotations`,components:`components`,deaccelerators:`deaccelerators`,evolution:`evolution`,evolves:`evolves`,links:`links`,notes:`notes`,pipelines:`pipelines`,size:`size`,title:`title`};function jF(e){return NF.isInstance(e,AF.$type)}o(jF,`isWardley`);var MF=class extends pn{constructor(){super(...arguments),this.types={Accelerator:{name:mP.$type,properties:{name:{name:mP.name},x:{name:mP.x},y:{name:mP.y}},superTypes:[]},Anchor:{name:hP.$type,properties:{evolution:{name:hP.evolution},name:{name:hP.name},visibility:{name:hP.visibility}},superTypes:[]},Annotation:{name:gP.$type,properties:{number:{name:gP.number},text:{name:gP.text},x:{name:gP.x},y:{name:gP.y}},superTypes:[]},Annotations:{name:_P.$type,properties:{x:{name:_P.x},y:{name:_P.y}},superTypes:[]},Architecture:{name:vP.$type,properties:{accDescr:{name:vP.accDescr},accTitle:{name:vP.accTitle},edges:{name:vP.edges,defaultValue:[]},groups:{name:vP.groups,defaultValue:[]},junctions:{name:vP.junctions,defaultValue:[]},services:{name:vP.services,defaultValue:[]},title:{name:vP.title}},superTypes:[]},Axis:{name:bP.$type,properties:{label:{name:bP.label},name:{name:bP.name}},superTypes:[]},Branch:{name:xP.$type,properties:{name:{name:xP.name},order:{name:xP.order}},superTypes:[wF.$type]},Checkout:{name:CP.$type,properties:{branch:{name:CP.branch}},superTypes:[wF.$type]},CherryPicking:{name:wP.$type,properties:{id:{name:wP.id},parent:{name:wP.parent},tags:{name:wP.tags,defaultValue:[]}},superTypes:[wF.$type]},ClassDefStatement:{name:TP.$type,properties:{className:{name:TP.className},styleText:{name:TP.styleText}},superTypes:[]},Commit:{name:EP.$type,properties:{id:{name:EP.id},message:{name:EP.message},tags:{name:EP.tags,defaultValue:[]},type:{name:EP.type}},superTypes:[wF.$type]},Common:{name:OP.$type,properties:{accDescr:{name:OP.accDescr},accTitle:{name:OP.accTitle},title:{name:OP.title}},superTypes:[]},Component:{name:kP.$type,properties:{decorator:{name:kP.decorator},evolution:{name:kP.evolution},inertia:{name:kP.inertia,defaultValue:!1},label:{name:kP.label},name:{name:kP.name},visibility:{name:kP.visibility}},superTypes:[]},Curve:{name:AP.$type,properties:{entries:{name:AP.entries,defaultValue:[]},label:{name:AP.label},name:{name:AP.name}},superTypes:[]},Deaccelerator:{name:jP.$type,properties:{name:{name:jP.name},x:{name:jP.x},y:{name:jP.y}},superTypes:[]},Decorator:{name:MP.$type,properties:{strategy:{name:MP.strategy}},superTypes:[]},Direction:{name:NP.$type,properties:{accDescr:{name:NP.accDescr},accTitle:{name:NP.accTitle},dir:{name:NP.dir},statements:{name:NP.statements,defaultValue:[]},title:{name:NP.title}},superTypes:[XP.$type]},Edge:{name:PP.$type,properties:{lhsDir:{name:PP.lhsDir},lhsGroup:{name:PP.lhsGroup,defaultValue:!1},lhsId:{name:PP.lhsId},lhsInto:{name:PP.lhsInto,defaultValue:!1},rhsDir:{name:PP.rhsDir},rhsGroup:{name:PP.rhsGroup,defaultValue:!1},rhsId:{name:PP.rhsId},rhsInto:{name:PP.rhsInto,defaultValue:!1},title:{name:PP.title}},superTypes:[]},EmDataEntity:{name:FP.$type,properties:{dataBlockValue:{name:FP.dataBlockValue},dataType:{name:FP.dataType},name:{name:FP.name}},superTypes:[]},EmFrame:{name:IP.$type,properties:{},superTypes:[]},EmGwt:{name:LP.$type,properties:{givenStatements:{name:LP.givenStatements,defaultValue:[]},sourceFrame:{name:LP.sourceFrame,referenceType:IP.$type},thenStatements:{name:LP.thenStatements,defaultValue:[]},whenStatements:{name:LP.whenStatements,defaultValue:[]}},superTypes:[]},EmGwtStatement:{name:RP.$type,properties:{entityIdentifier:{name:RP.entityIdentifier,referenceType:zP.$type}},superTypes:[]},EmModelEntity:{name:zP.$type,properties:{name:{name:zP.name}},superTypes:[]},EmNoteEntity:{name:VP.$type,properties:{dataBlockValue:{name:VP.dataBlockValue},dataType:{name:VP.dataType},sourceFrame:{name:VP.sourceFrame,referenceType:IP.$type}},superTypes:[]},EmResetFrame:{name:HP.$type,properties:{dataInlineValue:{name:HP.dataInlineValue},dataReference:{name:HP.dataReference,referenceType:FP.$type},dataType:{name:HP.dataType},entityIdentifier:{name:HP.entityIdentifier},modelEntityType:{name:HP.modelEntityType},name:{name:HP.name},sourceFrames:{name:HP.sourceFrames,defaultValue:[],referenceType:IP.$type}},superTypes:[IP.$type]},EmTimeFrame:{name:WP.$type,properties:{dataInlineValue:{name:WP.dataInlineValue},dataReference:{name:WP.dataReference,referenceType:FP.$type},dataType:{name:WP.dataType},entityIdentifier:{name:WP.entityIdentifier},modelEntityType:{name:WP.modelEntityType},name:{name:WP.name},sourceFrames:{name:WP.sourceFrames,defaultValue:[],referenceType:IP.$type}},superTypes:[IP.$type]},Entry:{name:GP.$type,properties:{axis:{name:GP.axis,referenceType:bP.$type},value:{name:GP.value}},superTypes:[]},EventModel:{name:KP.$type,properties:{accDescr:{name:KP.accDescr},accTitle:{name:KP.accTitle},dataEntities:{name:KP.dataEntities,defaultValue:[]},frames:{name:KP.frames,defaultValue:[]},gwtEntities:{name:KP.gwtEntities,defaultValue:[]},modelEntities:{name:KP.modelEntities,defaultValue:[]},noteEntities:{name:KP.noteEntities,defaultValue:[]},title:{name:KP.title}},superTypes:[]},Evolution:{name:qP.$type,properties:{stages:{name:qP.stages,defaultValue:[]}},superTypes:[]},EvolutionStage:{name:JP.$type,properties:{boundary:{name:JP.boundary},name:{name:JP.name},secondName:{name:JP.secondName}},superTypes:[]},Evolve:{name:YP.$type,properties:{component:{name:YP.component},target:{name:YP.target}},superTypes:[]},GitGraph:{name:XP.$type,properties:{accDescr:{name:XP.accDescr},accTitle:{name:XP.accTitle},statements:{name:XP.statements,defaultValue:[]},title:{name:XP.title}},superTypes:[]},Group:{name:QP.$type,properties:{icon:{name:QP.icon},id:{name:QP.id},in:{name:QP.in},title:{name:QP.title}},superTypes:[]},Info:{name:$P.$type,properties:{accDescr:{name:$P.accDescr},accTitle:{name:$P.accTitle},title:{name:$P.title}},superTypes:[]},Item:{name:tF.$type,properties:{classSelector:{name:tF.classSelector},name:{name:tF.name}},superTypes:[]},Junction:{name:nF.$type,properties:{id:{name:nF.id},in:{name:nF.in}},superTypes:[]},Label:{name:rF.$type,properties:{negX:{name:rF.negX,defaultValue:!1},negY:{name:rF.negY,defaultValue:!1},offsetX:{name:rF.offsetX},offsetY:{name:rF.offsetY}},superTypes:[]},Leaf:{name:iF.$type,properties:{classSelector:{name:iF.classSelector},name:{name:iF.name},value:{name:iF.value}},superTypes:[tF.$type]},Link:{name:aF.$type,properties:{arrow:{name:aF.arrow},from:{name:aF.from},fromPort:{name:aF.fromPort},linkLabel:{name:aF.linkLabel},to:{name:aF.to},toPort:{name:aF.toPort}},superTypes:[]},Merge:{name:oF.$type,properties:{branch:{name:oF.branch},id:{name:oF.id},tags:{name:oF.tags,defaultValue:[]},type:{name:oF.type}},superTypes:[wF.$type]},Note:{name:cF.$type,properties:{evolution:{name:cF.evolution},text:{name:cF.text},visibility:{name:cF.visibility}},superTypes:[]},Option:{name:lF.$type,properties:{name:{name:lF.name},value:{name:lF.value,defaultValue:!1}},superTypes:[]},Packet:{name:uF.$type,properties:{accDescr:{name:uF.accDescr},accTitle:{name:uF.accTitle},blocks:{name:uF.blocks,defaultValue:[]},title:{name:uF.title}},superTypes:[]},PacketBlock:{name:fF.$type,properties:{bits:{name:fF.bits},end:{name:fF.end},label:{name:fF.label},start:{name:fF.start}},superTypes:[]},Pie:{name:mF.$type,properties:{accDescr:{name:mF.accDescr},accTitle:{name:mF.accTitle},sections:{name:mF.sections,defaultValue:[]},showData:{name:mF.showData,defaultValue:!1},title:{name:mF.title}},superTypes:[]},PieSection:{name:gF.$type,properties:{label:{name:gF.label},value:{name:gF.value}},superTypes:[]},Pipeline:{name:vF.$type,properties:{components:{name:vF.components,defaultValue:[]},parent:{name:vF.parent}},superTypes:[]},PipelineComponent:{name:yF.$type,properties:{evolution:{name:yF.evolution},label:{name:yF.label},name:{name:yF.name}},superTypes:[]},Radar:{name:bF.$type,properties:{accDescr:{name:bF.accDescr},accTitle:{name:bF.accTitle},axes:{name:bF.axes,defaultValue:[]},curves:{name:bF.curves,defaultValue:[]},options:{name:bF.options,defaultValue:[]},title:{name:bF.title}},superTypes:[]},Section:{name:xF.$type,properties:{classSelector:{name:xF.classSelector},name:{name:xF.name}},superTypes:[tF.$type]},Service:{name:SF.$type,properties:{icon:{name:SF.icon},iconText:{name:SF.iconText},id:{name:SF.id},in:{name:SF.in},title:{name:SF.title}},superTypes:[]},Size:{name:CF.$type,properties:{height:{name:CF.height},width:{name:CF.width}},superTypes:[]},Statement:{name:wF.$type,properties:{},superTypes:[]},TreeNode:{name:OF.$type,properties:{indent:{name:OF.indent},name:{name:OF.name}},superTypes:[]},TreeView:{name:kF.$type,properties:{accDescr:{name:kF.accDescr},accTitle:{name:kF.accTitle},nodes:{name:kF.nodes,defaultValue:[]},title:{name:kF.title}},superTypes:[]},Treemap:{name:TF.$type,properties:{accDescr:{name:TF.accDescr},accTitle:{name:TF.accTitle},title:{name:TF.title},TreemapRows:{name:TF.TreemapRows,defaultValue:[]}},superTypes:[]},TreemapRow:{name:DF.$type,properties:{indent:{name:DF.indent},item:{name:DF.item}},superTypes:[]},Wardley:{name:AF.$type,properties:{accDescr:{name:AF.accDescr},accelerators:{name:AF.accelerators,defaultValue:[]},accTitle:{name:AF.accTitle},anchors:{name:AF.anchors,defaultValue:[]},annotation:{name:AF.annotation,defaultValue:[]},annotations:{name:AF.annotations,defaultValue:[]},components:{name:AF.components,defaultValue:[]},deaccelerators:{name:AF.deaccelerators,defaultValue:[]},evolution:{name:AF.evolution},evolves:{name:AF.evolves,defaultValue:[]},links:{name:AF.links,defaultValue:[]},notes:{name:AF.notes,defaultValue:[]},pipelines:{name:AF.pipelines,defaultValue:[]},size:{name:AF.size},title:{name:AF.title}},superTypes:[]}}}static{o(this,`MermaidAstReflection`)}},NF=new MF,PF,FF=o(()=>PF??=tP(`{"$type":"Grammar","isDeclared":true,"name":"ArchitectureGrammar","imports":[],"rules":[{"$type":"ParserRule","entry":true,"name":"Architecture","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@23"},"arguments":[],"cardinality":"*"},{"$type":"Keyword","value":"architecture-beta"},{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@23"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@13"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@1"},"arguments":[]}],"cardinality":"*"}]},"fragment":false,"parameters":[]},{"$type":"ParserRule","fragment":true,"name":"Statement","definition":{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"groups","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@5"},"arguments":[]}},{"$type":"Assignment","feature":"services","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@6"},"arguments":[]}},{"$type":"Assignment","feature":"junctions","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@7"},"arguments":[]}},{"$type":"Assignment","feature":"edges","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@8"},"arguments":[]}}]},"entry":false,"parameters":[]},{"$type":"ParserRule","fragment":true,"name":"LeftPort","definition":{"$type":"Group","elements":[{"$type":"Keyword","value":":"},{"$type":"Assignment","feature":"lhsDir","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@9"},"arguments":[]}}]},"entry":false,"parameters":[]},{"$type":"ParserRule","fragment":true,"name":"RightPort","definition":{"$type":"Group","elements":[{"$type":"Assignment","feature":"rhsDir","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@9"},"arguments":[]}},{"$type":"Keyword","value":":"}]},"entry":false,"parameters":[]},{"$type":"ParserRule","fragment":true,"name":"Arrow","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@2"},"arguments":[]},{"$type":"Assignment","feature":"lhsInto","operator":"?=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@11"},"arguments":[]},"cardinality":"?"},{"$type":"Alternatives","elements":[{"$type":"Keyword","value":"--"},{"$type":"Group","elements":[{"$type":"Keyword","value":"-"},{"$type":"Assignment","feature":"title","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@29"},"arguments":[]}},{"$type":"Keyword","value":"-"}]}]},{"$type":"Assignment","feature":"rhsInto","operator":"?=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@11"},"arguments":[]},"cardinality":"?"},{"$type":"RuleCall","rule":{"$ref":"#/rules@3"},"arguments":[]}]},"entry":false,"parameters":[]},{"$type":"ParserRule","name":"Group","definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"group"},{"$type":"Assignment","feature":"id","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@22"},"arguments":[]}},{"$type":"Assignment","feature":"icon","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@28"},"arguments":[]},"cardinality":"?"},{"$type":"Assignment","feature":"title","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@29"},"arguments":[]},"cardinality":"?"},{"$type":"Group","elements":[{"$type":"Keyword","value":"in"},{"$type":"Assignment","feature":"in","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@22"},"arguments":[]}}],"cardinality":"?"},{"$type":"RuleCall","rule":{"$ref":"#/rules@12"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Service","definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"service"},{"$type":"Assignment","feature":"id","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@22"},"arguments":[]}},{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"iconText","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@21"},"arguments":[]}},{"$type":"Assignment","feature":"icon","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@28"},"arguments":[]}}],"cardinality":"?"},{"$type":"Assignment","feature":"title","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@29"},"arguments":[]},"cardinality":"?"},{"$type":"Group","elements":[{"$type":"Keyword","value":"in"},{"$type":"Assignment","feature":"in","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@22"},"arguments":[]}}],"cardinality":"?"},{"$type":"RuleCall","rule":{"$ref":"#/rules@12"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Junction","definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"junction"},{"$type":"Assignment","feature":"id","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@22"},"arguments":[]}},{"$type":"Group","elements":[{"$type":"Keyword","value":"in"},{"$type":"Assignment","feature":"in","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@22"},"arguments":[]}}],"cardinality":"?"},{"$type":"RuleCall","rule":{"$ref":"#/rules@12"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Edge","definition":{"$type":"Group","elements":[{"$type":"Assignment","feature":"lhsId","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@22"},"arguments":[]}},{"$type":"Assignment","feature":"lhsGroup","operator":"?=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@10"},"arguments":[]},"cardinality":"?"},{"$type":"RuleCall","rule":{"$ref":"#/rules@4"},"arguments":[]},{"$type":"Assignment","feature":"rhsId","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@22"},"arguments":[]}},{"$type":"Assignment","feature":"rhsGroup","operator":"?=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@10"},"arguments":[]},"cardinality":"?"},{"$type":"RuleCall","rule":{"$ref":"#/rules@12"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"TerminalRule","name":"ARROW_DIRECTION","definition":{"$type":"TerminalAlternatives","elements":[{"$type":"TerminalAlternatives","elements":[{"$type":"TerminalAlternatives","elements":[{"$type":"CharacterRange","left":{"$type":"Keyword","value":"L"},"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"R"},"parenthesized":false}],"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"T"},"parenthesized":false}],"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"B"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ARROW_GROUP","definition":{"$type":"RegexToken","regex":"/\\\\{group\\\\}/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ARROW_INTO","definition":{"$type":"RegexToken","regex":"/<|>/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"ParserRule","name":"EOL","dataType":"string","definition":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@23"},"arguments":[],"cardinality":"+"},{"$type":"EndOfFile"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","fragment":true,"name":"TitleAndAccessibilities","definition":{"$type":"Group","elements":[{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"accDescr","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@15"},"arguments":[]}},{"$type":"Assignment","feature":"accTitle","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@16"},"arguments":[]}},{"$type":"Assignment","feature":"title","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}}]},{"$type":"RuleCall","rule":{"$ref":"#/rules@12"},"arguments":[]}],"cardinality":"+"},"entry":false,"parameters":[]},{"$type":"TerminalRule","name":"BOOLEAN","type":{"$type":"ReturnType","name":"boolean"},"definition":{"$type":"TerminalAlternatives","elements":[{"$type":"CharacterRange","left":{"$type":"Keyword","value":"true"},"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"false"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_DESCR","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accDescr(?:[\\\\t ]*:([^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)|\\\\s*{([^}]*)})/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accTitle[\\\\t ]*:(?:[^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*title(?:[\\\\t ][^\\\\n\\\\r]*?(?=%%)|[\\\\t ][^\\\\n\\\\r]*|)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"FLOAT","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"RegexToken","regex":"/[0-9]+\\\\.[0-9]+(?!\\\\.)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"INT","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"RegexToken","regex":"/0|[1-9][0-9]*(?!\\\\.)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"NUMBER","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"TerminalAlternatives","elements":[{"$type":"TerminalRuleCall","rule":{"$ref":"#/rules@18"},"parenthesized":false},{"$type":"TerminalRuleCall","rule":{"$ref":"#/rules@19"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"STRING","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/\\"([^\\"\\\\\\\\]|\\\\\\\\.)*\\"|'([^'\\\\\\\\]|\\\\\\\\.)*'/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ID","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/[\\\\w]([-\\\\w]*\\\\w)?/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"NEWLINE","definition":{"$type":"RegexToken","regex":"/\\\\r?\\\\n/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","hidden":true,"name":"WHITESPACE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]+/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"YAML","definition":{"$type":"RegexToken","regex":"/---[\\\\t ]*\\\\r?\\\\n(?:[\\\\S\\\\s]*?\\\\r?\\\\n)?---(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"DIRECTIVE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%{[\\\\S\\\\s]*?}%%(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"SINGLE_LINE_COMMENT","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%[^\\\\n\\\\r]*/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","name":"ARCH_ICON","definition":{"$type":"RegexToken","regex":"/\\\\([\\\\w-:]+\\\\)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ARCH_TITLE","definition":{"$type":"RegexToken","regex":"/\\\\[(?:\\"([^\\"\\\\\\\\]|\\\\\\\\.)*\\"|'([^'\\\\\\\\]|\\\\\\\\.)*'|[\\\\w ]+)\\\\]/","parenthesized":false},"fragment":false,"hidden":false}],"interfaces":[],"types":[]}`),`ArchitectureGrammarGrammar`),IF,LF=o(()=>IF??=tP('{"$type":"Grammar","isDeclared":true,"name":"EventModeling","interfaces":[{"$type":"Interface","name":"Common","attributes":[{"$type":"TypeAttribute","name":"accDescr","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}},{"$type":"TypeAttribute","name":"accTitle","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}},{"$type":"TypeAttribute","name":"title","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}}],"superTypes":[]}],"rules":[{"$type":"ParserRule","entry":true,"name":"EventModel","definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"eventmodeling"},{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"accDescr","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@20"},"arguments":[]}},{"$type":"Assignment","feature":"accTitle","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@21"},"arguments":[]}},{"$type":"Assignment","feature":"title","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@22"},"arguments":[]}},{"$type":"Assignment","feature":"modelEntities","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@9"},"arguments":[]}},{"$type":"Assignment","feature":"frames","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@8"},"arguments":[]}},{"$type":"Assignment","feature":"dataEntities","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@10"},"arguments":[]}},{"$type":"Assignment","feature":"noteEntities","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@11"},"arguments":[]}},{"$type":"Assignment","feature":"gwtEntities","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@12"},"arguments":[]}}],"cardinality":"*"}]},"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EmModelEntityType","dataType":"string","definition":{"$type":"Alternatives","elements":[{"$type":"Keyword","value":"rmo"},{"$type":"Keyword","value":"readmodel"},{"$type":"Keyword","value":"ui"},{"$type":"Keyword","value":"cmd"},{"$type":"Keyword","value":"command"},{"$type":"Keyword","value":"evt"},{"$type":"Keyword","value":"event"},{"$type":"Keyword","value":"pcr"},{"$type":"Keyword","value":"processor"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EmDataType","dataType":"string","definition":{"$type":"Alternatives","elements":[{"$type":"Keyword","value":"json"},{"$type":"Keyword","value":"jsobj"},{"$type":"Keyword","value":"figma"},{"$type":"Keyword","value":"salt"},{"$type":"Keyword","value":"uri"},{"$type":"Keyword","value":"md"},{"$type":"Keyword","value":"html"},{"$type":"Keyword","value":"text"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","fragment":true,"name":"EmDataInline","definition":{"$type":"Group","elements":[{"$type":"Group","elements":[{"$type":"Keyword","value":"`"},{"$type":"Assignment","feature":"dataType","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@2"},"arguments":[]}},{"$type":"Keyword","value":"`"}],"cardinality":"?"},{"$type":"Assignment","feature":"dataInlineValue","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@18"},"arguments":[]}}]},"entry":false,"parameters":[]},{"$type":"ParserRule","fragment":true,"name":"EmDataBlock","definition":{"$type":"Group","elements":[{"$type":"Group","elements":[{"$type":"Keyword","value":"`"},{"$type":"Assignment","feature":"dataType","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@2"},"arguments":[]}},{"$type":"Keyword","value":"`"}],"cardinality":"?"},{"$type":"Assignment","feature":"dataBlockValue","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]}}]},"entry":false,"parameters":[]},{"$type":"ParserRule","name":"QualifiedName","dataType":"string","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@14"},"arguments":[]},{"$type":"Group","elements":[{"$type":"Keyword","value":"."},{"$type":"RuleCall","rule":{"$ref":"#/rules@14"},"arguments":[]}],"cardinality":"*"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EmTimeFrame","definition":{"$type":"Group","elements":[{"$type":"Alternatives","elements":[{"$type":"Keyword","value":"tf"},{"$type":"Keyword","value":"timeframe"}]},{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@15"},"arguments":[]}},{"$type":"Assignment","feature":"modelEntityType","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@1"},"arguments":[]}},{"$type":"Assignment","feature":"entityIdentifier","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@5"},"arguments":[]}},{"$type":"Group","elements":[{"$type":"Keyword","value":"->>"},{"$type":"Assignment","feature":"sourceFrames","operator":"+=","terminal":{"$type":"CrossReference","type":{"$ref":"#/rules@8"},"terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@15"},"arguments":[]},"deprecatedSyntax":false,"isMulti":false}}],"cardinality":"*"},{"$type":"Group","elements":[{"$type":"Keyword","value":"[["},{"$type":"Assignment","feature":"dataReference","operator":"=","terminal":{"$type":"CrossReference","type":{"$ref":"#/rules@10"},"terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@14"},"arguments":[]},"deprecatedSyntax":false,"isMulti":false}},{"$type":"Keyword","value":"]]"}],"cardinality":"?"},{"$type":"RuleCall","rule":{"$ref":"#/rules@3"},"arguments":[],"cardinality":"?"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EmResetFrame","definition":{"$type":"Group","elements":[{"$type":"Alternatives","elements":[{"$type":"Keyword","value":"rf"},{"$type":"Keyword","value":"resetframe"}]},{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@15"},"arguments":[]}},{"$type":"Assignment","feature":"modelEntityType","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@1"},"arguments":[]}},{"$type":"Assignment","feature":"entityIdentifier","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@5"},"arguments":[]}},{"$type":"Group","elements":[{"$type":"Keyword","value":"->>"},{"$type":"Assignment","feature":"sourceFrames","operator":"+=","terminal":{"$type":"CrossReference","type":{"$ref":"#/rules@8"},"terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@15"},"arguments":[]},"deprecatedSyntax":false,"isMulti":false}}],"cardinality":"*"},{"$type":"Group","elements":[{"$type":"Keyword","value":"[["},{"$type":"Assignment","feature":"dataReference","operator":"=","terminal":{"$type":"CrossReference","type":{"$ref":"#/rules@10"},"terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@14"},"arguments":[]},"deprecatedSyntax":false,"isMulti":false}},{"$type":"Keyword","value":"]]"}],"cardinality":"?"},{"$type":"RuleCall","rule":{"$ref":"#/rules@3"},"arguments":[],"cardinality":"?"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EmFrame","definition":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@6"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@7"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EmModelEntity","definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"entity"},{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@5"},"arguments":[]}}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EmDataEntity","definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"data"},{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@14"},"arguments":[]}},{"$type":"RuleCall","rule":{"$ref":"#/rules@4"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EmNoteEntity","definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"note"},{"$type":"Assignment","feature":"sourceFrame","operator":"=","terminal":{"$type":"CrossReference","type":{"$ref":"#/rules@8"},"terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@15"},"arguments":[]},"deprecatedSyntax":false,"isMulti":false}},{"$type":"RuleCall","rule":{"$ref":"#/rules@4"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EmGwt","definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"gwt"},{"$type":"Assignment","feature":"sourceFrame","operator":"=","terminal":{"$type":"CrossReference","type":{"$ref":"#/rules@8"},"terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@15"},"arguments":[]},"deprecatedSyntax":false,"isMulti":false}},{"$type":"Keyword","value":"given"},{"$type":"Assignment","feature":"givenStatements","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@13"},"arguments":[]},"cardinality":"+"},{"$type":"Group","elements":[{"$type":"Keyword","value":"when"},{"$type":"Assignment","feature":"whenStatements","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@13"},"arguments":[]},"cardinality":"+"}],"cardinality":"?"},{"$type":"Keyword","value":"then"},{"$type":"Assignment","feature":"thenStatements","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@13"},"arguments":[]},"cardinality":"+"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EmGwtStatement","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@1"},"arguments":[]},{"$type":"Assignment","feature":"entityIdentifier","operator":"=","terminal":{"$type":"CrossReference","type":{"$ref":"#/rules@9"},"terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@14"},"arguments":[]},"deprecatedSyntax":false,"isMulti":false}}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EM_EID","dataType":"string","definition":{"$type":"RuleCall","rule":{"$ref":"#/rules@16"},"arguments":[]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EM_FI","dataType":"string","definition":{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]},"entry":false,"fragment":false,"parameters":[]},{"$type":"TerminalRule","name":"EM_ID","definition":{"$type":"RegexToken","regex":"/[_a-zA-Z][\\\\w_]*/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"EM_FID","definition":{"$type":"RegexToken","regex":"/\\\\d{1,3}/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"EM_DATA_INLINE","definition":{"$type":"RegexToken","regex":"/\\\\{(.*)\\\\}|\\"(.*)\\"|\'(.*)\'/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"EM_DATA_BLOCK","definition":{"$type":"RegexToken","regex":"/\\\\{[\\\\t ]*\\\\r?\\\\n(?:[\\\\S\\\\s]*?\\\\r?\\\\n)?\\\\}(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"EM_ACC_DESCR","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accDescr(?:[\\\\t ]*:([^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)|\\\\s*{([^}]*)})/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"EM_ACC_TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accTitle[\\\\t ]*:(?:[^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"EM_TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*title(?:[\\\\t ][^\\\\n\\\\r]*?(?=%%)|[\\\\t ][^\\\\n\\\\r]*|)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","hidden":true,"name":"EM_WS","definition":{"$type":"RegexToken","regex":"/\\\\s+/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"EM_YAML","definition":{"$type":"RegexToken","regex":"/---[\\\\t ]*\\\\r?\\\\n(?:[\\\\S\\\\s]*?\\\\r?\\\\n)?---(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"EM_DIRECTIVE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%{[\\\\S\\\\s]*?}%%(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"EM_SINGLE_LINE_COMMENT","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%[^\\\\n\\\\r]*/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"EM_ML_COMMENT","definition":{"$type":"RegexToken","regex":"/\\\\/\\\\*[\\\\s\\\\S]*?\\\\*\\\\//","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"EM_SL_COMMENT","definition":{"$type":"RegexToken","regex":"/\\\\/\\\\/[^\\\\n\\\\r]*/","parenthesized":false},"fragment":false}],"imports":[],"types":[]}'),`EventModelingGrammar`),RF,zF=o(()=>RF??=tP(`{"$type":"Grammar","isDeclared":true,"name":"GitGraphGrammar","imports":[],"rules":[{"$type":"ParserRule","entry":true,"name":"GitGraph","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[],"cardinality":"*"},{"$type":"Alternatives","elements":[{"$type":"Keyword","value":"gitGraph"},{"$type":"Group","elements":[{"$type":"Keyword","value":"gitGraph"},{"$type":"Keyword","value":":"}]},{"$type":"Keyword","value":"gitGraph:"},{"$type":"Group","elements":[{"$type":"Keyword","value":"gitGraph"},{"$type":"RuleCall","rule":{"$ref":"#/rules@2"},"arguments":[]},{"$type":"Keyword","value":":"}]}]},{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@9"},"arguments":[]},{"$type":"Assignment","feature":"statements","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@1"},"arguments":[]}}],"cardinality":"*"}]},"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Statement","definition":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@3"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@4"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@5"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@6"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@7"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Direction","definition":{"$type":"Assignment","feature":"dir","operator":"=","terminal":{"$type":"Alternatives","elements":[{"$type":"Keyword","value":"LR"},{"$type":"Keyword","value":"TB"},{"$type":"Keyword","value":"BT"}]}},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Commit","definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"commit"},{"$type":"Alternatives","elements":[{"$type":"Group","elements":[{"$type":"Keyword","value":"id:"},{"$type":"Assignment","feature":"id","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}}]},{"$type":"Group","elements":[{"$type":"Keyword","value":"msg:","cardinality":"?"},{"$type":"Assignment","feature":"message","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}}]},{"$type":"Group","elements":[{"$type":"Keyword","value":"tag:"},{"$type":"Assignment","feature":"tags","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}}]},{"$type":"Group","elements":[{"$type":"Keyword","value":"type:"},{"$type":"Assignment","feature":"type","operator":"=","terminal":{"$type":"Alternatives","elements":[{"$type":"Keyword","value":"NORMAL"},{"$type":"Keyword","value":"REVERSE"},{"$type":"Keyword","value":"HIGHLIGHT"}]}}]}],"cardinality":"*"},{"$type":"RuleCall","rule":{"$ref":"#/rules@8"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Branch","definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"branch"},{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@24"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}]}},{"$type":"Group","elements":[{"$type":"Keyword","value":"order:"},{"$type":"Assignment","feature":"order","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@15"},"arguments":[]}}],"cardinality":"?"},{"$type":"RuleCall","rule":{"$ref":"#/rules@8"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Merge","definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"merge"},{"$type":"Assignment","feature":"branch","operator":"=","terminal":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@24"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}]}},{"$type":"Alternatives","elements":[{"$type":"Group","elements":[{"$type":"Keyword","value":"id:"},{"$type":"Assignment","feature":"id","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}}]},{"$type":"Group","elements":[{"$type":"Keyword","value":"tag:"},{"$type":"Assignment","feature":"tags","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}}]},{"$type":"Group","elements":[{"$type":"Keyword","value":"type:"},{"$type":"Assignment","feature":"type","operator":"=","terminal":{"$type":"Alternatives","elements":[{"$type":"Keyword","value":"NORMAL"},{"$type":"Keyword","value":"REVERSE"},{"$type":"Keyword","value":"HIGHLIGHT"}]}}]}],"cardinality":"*"},{"$type":"RuleCall","rule":{"$ref":"#/rules@8"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Checkout","definition":{"$type":"Group","elements":[{"$type":"Alternatives","elements":[{"$type":"Keyword","value":"checkout"},{"$type":"Keyword","value":"switch"}]},{"$type":"Assignment","feature":"branch","operator":"=","terminal":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@24"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}]}},{"$type":"RuleCall","rule":{"$ref":"#/rules@8"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"CherryPicking","definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"cherry-pick"},{"$type":"Alternatives","elements":[{"$type":"Group","elements":[{"$type":"Keyword","value":"id:"},{"$type":"Assignment","feature":"id","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}}]},{"$type":"Group","elements":[{"$type":"Keyword","value":"tag:"},{"$type":"Assignment","feature":"tags","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}}]},{"$type":"Group","elements":[{"$type":"Keyword","value":"parent:"},{"$type":"Assignment","feature":"parent","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}}]}],"cardinality":"*"},{"$type":"RuleCall","rule":{"$ref":"#/rules@8"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EOL","dataType":"string","definition":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[],"cardinality":"+"},{"$type":"EndOfFile"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","fragment":true,"name":"TitleAndAccessibilities","definition":{"$type":"Group","elements":[{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"accDescr","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@11"},"arguments":[]}},{"$type":"Assignment","feature":"accTitle","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@12"},"arguments":[]}},{"$type":"Assignment","feature":"title","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@13"},"arguments":[]}}]},{"$type":"RuleCall","rule":{"$ref":"#/rules@8"},"arguments":[]}],"cardinality":"+"},"entry":false,"parameters":[]},{"$type":"TerminalRule","name":"BOOLEAN","type":{"$type":"ReturnType","name":"boolean"},"definition":{"$type":"TerminalAlternatives","elements":[{"$type":"CharacterRange","left":{"$type":"Keyword","value":"true"},"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"false"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_DESCR","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accDescr(?:[\\\\t ]*:([^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)|\\\\s*{([^}]*)})/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accTitle[\\\\t ]*:(?:[^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*title(?:[\\\\t ][^\\\\n\\\\r]*?(?=%%)|[\\\\t ][^\\\\n\\\\r]*|)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"FLOAT","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"RegexToken","regex":"/[0-9]+\\\\.[0-9]+(?!\\\\.)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"INT","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"RegexToken","regex":"/0|[1-9][0-9]*(?!\\\\.)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"NUMBER","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"TerminalAlternatives","elements":[{"$type":"TerminalRuleCall","rule":{"$ref":"#/rules@14"},"parenthesized":false},{"$type":"TerminalRuleCall","rule":{"$ref":"#/rules@15"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"STRING","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/\\"([^\\"\\\\\\\\]|\\\\\\\\.)*\\"|'([^'\\\\\\\\]|\\\\\\\\.)*'/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ID","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/[\\\\w]([-\\\\w]*\\\\w)?/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"NEWLINE","definition":{"$type":"RegexToken","regex":"/\\\\r?\\\\n/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","hidden":true,"name":"WHITESPACE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]+/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"YAML","definition":{"$type":"RegexToken","regex":"/---[\\\\t ]*\\\\r?\\\\n(?:[\\\\S\\\\s]*?\\\\r?\\\\n)?---(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"DIRECTIVE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%{[\\\\S\\\\s]*?}%%(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"SINGLE_LINE_COMMENT","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%[^\\\\n\\\\r]*/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","name":"REFERENCE","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/\\\\w([-\\\\./\\\\w]*[-\\\\w])?/","parenthesized":false},"fragment":false,"hidden":false}],"interfaces":[],"types":[]}`),`GitGraphGrammarGrammar`),BF,VF=o(()=>BF??=tP(`{"$type":"Grammar","isDeclared":true,"name":"InfoGrammar","imports":[],"rules":[{"$type":"ParserRule","entry":true,"name":"Info","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@12"},"arguments":[],"cardinality":"*"},{"$type":"Keyword","value":"info"},{"$type":"RuleCall","rule":{"$ref":"#/rules@12"},"arguments":[],"cardinality":"*"},{"$type":"Group","elements":[{"$type":"Keyword","value":"showInfo"},{"$type":"RuleCall","rule":{"$ref":"#/rules@12"},"arguments":[],"cardinality":"*"}],"cardinality":"?"},{"$type":"RuleCall","rule":{"$ref":"#/rules@2"},"arguments":[],"cardinality":"?"}]},"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EOL","dataType":"string","definition":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@12"},"arguments":[],"cardinality":"+"},{"$type":"EndOfFile"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","fragment":true,"name":"TitleAndAccessibilities","definition":{"$type":"Group","elements":[{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"accDescr","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@4"},"arguments":[]}},{"$type":"Assignment","feature":"accTitle","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@5"},"arguments":[]}},{"$type":"Assignment","feature":"title","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@6"},"arguments":[]}}]},{"$type":"RuleCall","rule":{"$ref":"#/rules@1"},"arguments":[]}],"cardinality":"+"},"entry":false,"parameters":[]},{"$type":"TerminalRule","name":"BOOLEAN","type":{"$type":"ReturnType","name":"boolean"},"definition":{"$type":"TerminalAlternatives","elements":[{"$type":"CharacterRange","left":{"$type":"Keyword","value":"true"},"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"false"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_DESCR","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accDescr(?:[\\\\t ]*:([^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)|\\\\s*{([^}]*)})/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accTitle[\\\\t ]*:(?:[^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*title(?:[\\\\t ][^\\\\n\\\\r]*?(?=%%)|[\\\\t ][^\\\\n\\\\r]*|)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"FLOAT","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"RegexToken","regex":"/[0-9]+\\\\.[0-9]+(?!\\\\.)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"INT","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"RegexToken","regex":"/0|[1-9][0-9]*(?!\\\\.)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"NUMBER","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"TerminalAlternatives","elements":[{"$type":"TerminalRuleCall","rule":{"$ref":"#/rules@7"},"parenthesized":false},{"$type":"TerminalRuleCall","rule":{"$ref":"#/rules@8"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"STRING","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/\\"([^\\"\\\\\\\\]|\\\\\\\\.)*\\"|'([^'\\\\\\\\]|\\\\\\\\.)*'/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ID","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/[\\\\w]([-\\\\w]*\\\\w)?/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"NEWLINE","definition":{"$type":"RegexToken","regex":"/\\\\r?\\\\n/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","hidden":true,"name":"WHITESPACE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]+/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"YAML","definition":{"$type":"RegexToken","regex":"/---[\\\\t ]*\\\\r?\\\\n(?:[\\\\S\\\\s]*?\\\\r?\\\\n)?---(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"DIRECTIVE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%{[\\\\S\\\\s]*?}%%(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"SINGLE_LINE_COMMENT","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%[^\\\\n\\\\r]*/","parenthesized":false},"fragment":false}],"interfaces":[],"types":[]}`),`InfoGrammarGrammar`),HF,UF=o(()=>HF??=tP(`{"$type":"Grammar","isDeclared":true,"name":"PacketGrammar","imports":[],"rules":[{"$type":"ParserRule","entry":true,"name":"Packet","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@13"},"arguments":[],"cardinality":"*"},{"$type":"Alternatives","elements":[{"$type":"Keyword","value":"packet"},{"$type":"Keyword","value":"packet-beta"}]},{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@3"},"arguments":[]},{"$type":"Assignment","feature":"blocks","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@1"},"arguments":[]}},{"$type":"RuleCall","rule":{"$ref":"#/rules@13"},"arguments":[]}],"cardinality":"*"}]},"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"PacketBlock","definition":{"$type":"Group","elements":[{"$type":"Alternatives","elements":[{"$type":"Group","elements":[{"$type":"Assignment","feature":"start","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@9"},"arguments":[]}},{"$type":"Group","elements":[{"$type":"Keyword","value":"-"},{"$type":"Assignment","feature":"end","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@9"},"arguments":[]}}],"cardinality":"?"}]},{"$type":"Group","elements":[{"$type":"Keyword","value":"+"},{"$type":"Assignment","feature":"bits","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@9"},"arguments":[]}}]}]},{"$type":"Keyword","value":":"},{"$type":"Assignment","feature":"label","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@11"},"arguments":[]}},{"$type":"RuleCall","rule":{"$ref":"#/rules@2"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EOL","dataType":"string","definition":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@13"},"arguments":[],"cardinality":"+"},{"$type":"EndOfFile"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","fragment":true,"name":"TitleAndAccessibilities","definition":{"$type":"Group","elements":[{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"accDescr","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@5"},"arguments":[]}},{"$type":"Assignment","feature":"accTitle","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@6"},"arguments":[]}},{"$type":"Assignment","feature":"title","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@7"},"arguments":[]}}]},{"$type":"RuleCall","rule":{"$ref":"#/rules@2"},"arguments":[]}],"cardinality":"+"},"entry":false,"parameters":[]},{"$type":"TerminalRule","name":"BOOLEAN","type":{"$type":"ReturnType","name":"boolean"},"definition":{"$type":"TerminalAlternatives","elements":[{"$type":"CharacterRange","left":{"$type":"Keyword","value":"true"},"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"false"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_DESCR","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accDescr(?:[\\\\t ]*:([^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)|\\\\s*{([^}]*)})/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accTitle[\\\\t ]*:(?:[^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*title(?:[\\\\t ][^\\\\n\\\\r]*?(?=%%)|[\\\\t ][^\\\\n\\\\r]*|)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"FLOAT","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"RegexToken","regex":"/[0-9]+\\\\.[0-9]+(?!\\\\.)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"INT","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"RegexToken","regex":"/0|[1-9][0-9]*(?!\\\\.)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"NUMBER","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"TerminalAlternatives","elements":[{"$type":"TerminalRuleCall","rule":{"$ref":"#/rules@8"},"parenthesized":false},{"$type":"TerminalRuleCall","rule":{"$ref":"#/rules@9"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"STRING","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/\\"([^\\"\\\\\\\\]|\\\\\\\\.)*\\"|'([^'\\\\\\\\]|\\\\\\\\.)*'/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ID","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/[\\\\w]([-\\\\w]*\\\\w)?/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"NEWLINE","definition":{"$type":"RegexToken","regex":"/\\\\r?\\\\n/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","hidden":true,"name":"WHITESPACE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]+/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"YAML","definition":{"$type":"RegexToken","regex":"/---[\\\\t ]*\\\\r?\\\\n(?:[\\\\S\\\\s]*?\\\\r?\\\\n)?---(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"DIRECTIVE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%{[\\\\S\\\\s]*?}%%(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"SINGLE_LINE_COMMENT","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%[^\\\\n\\\\r]*/","parenthesized":false},"fragment":false}],"interfaces":[],"types":[]}`),`PacketGrammarGrammar`),WF,GF=o(()=>WF??=tP(`{"$type":"Grammar","isDeclared":true,"name":"PieGrammar","imports":[],"rules":[{"$type":"ParserRule","entry":true,"name":"Pie","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@16"},"arguments":[],"cardinality":"*"},{"$type":"Keyword","value":"pie"},{"$type":"Assignment","feature":"showData","operator":"?=","terminal":{"$type":"Keyword","value":"showData"},"cardinality":"?"},{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@6"},"arguments":[]},{"$type":"Assignment","feature":"sections","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@1"},"arguments":[]}},{"$type":"RuleCall","rule":{"$ref":"#/rules@16"},"arguments":[]}],"cardinality":"*"}]},"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"PieSection","definition":{"$type":"Group","elements":[{"$type":"Assignment","feature":"label","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@14"},"arguments":[]}},{"$type":"Keyword","value":":"},{"$type":"Assignment","feature":"value","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@4"},"arguments":[]}},{"$type":"RuleCall","rule":{"$ref":"#/rules@5"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"TerminalRule","name":"FLOAT_PIE","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"RegexToken","regex":"/-?[0-9]+\\\\.[0-9]+(?!\\\\.)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"INT_PIE","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"RegexToken","regex":"/-?(0|[1-9][0-9]*)(?!\\\\.)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"NUMBER_PIE","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"TerminalAlternatives","elements":[{"$type":"TerminalRuleCall","rule":{"$ref":"#/rules@2"},"parenthesized":false},{"$type":"TerminalRuleCall","rule":{"$ref":"#/rules@3"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"ParserRule","name":"EOL","dataType":"string","definition":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@16"},"arguments":[],"cardinality":"+"},{"$type":"EndOfFile"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","fragment":true,"name":"TitleAndAccessibilities","definition":{"$type":"Group","elements":[{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"accDescr","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@8"},"arguments":[]}},{"$type":"Assignment","feature":"accTitle","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@9"},"arguments":[]}},{"$type":"Assignment","feature":"title","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@10"},"arguments":[]}}]},{"$type":"RuleCall","rule":{"$ref":"#/rules@5"},"arguments":[]}],"cardinality":"+"},"entry":false,"parameters":[]},{"$type":"TerminalRule","name":"BOOLEAN","type":{"$type":"ReturnType","name":"boolean"},"definition":{"$type":"TerminalAlternatives","elements":[{"$type":"CharacterRange","left":{"$type":"Keyword","value":"true"},"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"false"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_DESCR","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accDescr(?:[\\\\t ]*:([^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)|\\\\s*{([^}]*)})/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accTitle[\\\\t ]*:(?:[^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*title(?:[\\\\t ][^\\\\n\\\\r]*?(?=%%)|[\\\\t ][^\\\\n\\\\r]*|)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"FLOAT","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"RegexToken","regex":"/[0-9]+\\\\.[0-9]+(?!\\\\.)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"INT","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"RegexToken","regex":"/0|[1-9][0-9]*(?!\\\\.)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"NUMBER","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"TerminalAlternatives","elements":[{"$type":"TerminalRuleCall","rule":{"$ref":"#/rules@11"},"parenthesized":false},{"$type":"TerminalRuleCall","rule":{"$ref":"#/rules@12"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"STRING","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/\\"([^\\"\\\\\\\\]|\\\\\\\\.)*\\"|'([^'\\\\\\\\]|\\\\\\\\.)*'/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ID","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/[\\\\w]([-\\\\w]*\\\\w)?/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"NEWLINE","definition":{"$type":"RegexToken","regex":"/\\\\r?\\\\n/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","hidden":true,"name":"WHITESPACE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]+/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"YAML","definition":{"$type":"RegexToken","regex":"/---[\\\\t ]*\\\\r?\\\\n(?:[\\\\S\\\\s]*?\\\\r?\\\\n)?---(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"DIRECTIVE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%{[\\\\S\\\\s]*?}%%(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"SINGLE_LINE_COMMENT","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%[^\\\\n\\\\r]*/","parenthesized":false},"fragment":false}],"interfaces":[],"types":[]}`),`PieGrammarGrammar`),KF,qF=o(()=>KF??=tP(`{"$type":"Grammar","isDeclared":true,"name":"RadarGrammar","imports":[],"rules":[{"$type":"ParserRule","entry":true,"name":"Radar","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@20"},"arguments":[],"cardinality":"*"},{"$type":"Alternatives","elements":[{"$type":"Keyword","value":"radar-beta"},{"$type":"Keyword","value":"radar-beta:"},{"$type":"Group","elements":[{"$type":"Keyword","value":"radar-beta"},{"$type":"Keyword","value":":"}]}]},{"$type":"RuleCall","rule":{"$ref":"#/rules@20"},"arguments":[],"cardinality":"*"},{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@10"},"arguments":[]},{"$type":"Group","elements":[{"$type":"Keyword","value":"axis"},{"$type":"Assignment","feature":"axes","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@2"},"arguments":[]}},{"$type":"Group","elements":[{"$type":"Keyword","value":","},{"$type":"Assignment","feature":"axes","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@2"},"arguments":[]}}],"cardinality":"*"}]},{"$type":"Group","elements":[{"$type":"Keyword","value":"curve"},{"$type":"Assignment","feature":"curves","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@3"},"arguments":[]}},{"$type":"Group","elements":[{"$type":"Keyword","value":","},{"$type":"Assignment","feature":"curves","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@3"},"arguments":[]}}],"cardinality":"*"}]},{"$type":"Group","elements":[{"$type":"Assignment","feature":"options","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@7"},"arguments":[]}},{"$type":"Group","elements":[{"$type":"Keyword","value":","},{"$type":"Assignment","feature":"options","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@7"},"arguments":[]}}],"cardinality":"*"}]},{"$type":"RuleCall","rule":{"$ref":"#/rules@20"},"arguments":[]}],"cardinality":"*"}]},"fragment":false,"parameters":[]},{"$type":"ParserRule","fragment":true,"name":"Label","definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"["},{"$type":"Assignment","feature":"label","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@18"},"arguments":[]}},{"$type":"Keyword","value":"]"}]},"entry":false,"parameters":[]},{"$type":"ParserRule","name":"Axis","definition":{"$type":"Group","elements":[{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]}},{"$type":"RuleCall","rule":{"$ref":"#/rules@1"},"arguments":[],"cardinality":"?"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Curve","definition":{"$type":"Group","elements":[{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]}},{"$type":"RuleCall","rule":{"$ref":"#/rules@1"},"arguments":[],"cardinality":"?"},{"$type":"Keyword","value":"{"},{"$type":"RuleCall","rule":{"$ref":"#/rules@4"},"arguments":[]},{"$type":"Keyword","value":"}"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","fragment":true,"name":"Entries","definition":{"$type":"Alternatives","elements":[{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@20"},"arguments":[],"cardinality":"*"},{"$type":"Assignment","feature":"entries","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@6"},"arguments":[]}},{"$type":"Group","elements":[{"$type":"Keyword","value":","},{"$type":"RuleCall","rule":{"$ref":"#/rules@20"},"arguments":[],"cardinality":"*"},{"$type":"Assignment","feature":"entries","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@6"},"arguments":[]}}],"cardinality":"*"},{"$type":"RuleCall","rule":{"$ref":"#/rules@20"},"arguments":[],"cardinality":"*"}]},{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@20"},"arguments":[],"cardinality":"*"},{"$type":"Assignment","feature":"entries","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@5"},"arguments":[]}},{"$type":"Group","elements":[{"$type":"Keyword","value":","},{"$type":"RuleCall","rule":{"$ref":"#/rules@20"},"arguments":[],"cardinality":"*"},{"$type":"Assignment","feature":"entries","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@5"},"arguments":[]}}],"cardinality":"*"},{"$type":"RuleCall","rule":{"$ref":"#/rules@20"},"arguments":[],"cardinality":"*"}]}]},"entry":false,"parameters":[]},{"$type":"ParserRule","name":"DetailedEntry","returnType":{"$ref":"#/interfaces@0"},"definition":{"$type":"Group","elements":[{"$type":"Assignment","feature":"axis","operator":"=","terminal":{"$type":"CrossReference","type":{"$ref":"#/rules@2"},"terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]},"deprecatedSyntax":false,"isMulti":false}},{"$type":"Keyword","value":":","cardinality":"?"},{"$type":"Assignment","feature":"value","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"NumberEntry","returnType":{"$ref":"#/interfaces@0"},"definition":{"$type":"Assignment","feature":"value","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Option","definition":{"$type":"Alternatives","elements":[{"$type":"Group","elements":[{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"Keyword","value":"showLegend"}},{"$type":"Assignment","feature":"value","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@11"},"arguments":[]}}]},{"$type":"Group","elements":[{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"Keyword","value":"ticks"}},{"$type":"Assignment","feature":"value","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}}]},{"$type":"Group","elements":[{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"Keyword","value":"max"}},{"$type":"Assignment","feature":"value","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}}]},{"$type":"Group","elements":[{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"Keyword","value":"min"}},{"$type":"Assignment","feature":"value","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}}]},{"$type":"Group","elements":[{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"Keyword","value":"graticule"}},{"$type":"Assignment","feature":"value","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@8"},"arguments":[]}}]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"TerminalRule","name":"GRATICULE","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"TerminalAlternatives","elements":[{"$type":"CharacterRange","left":{"$type":"Keyword","value":"circle"},"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"polygon"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"ParserRule","name":"EOL","dataType":"string","definition":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@20"},"arguments":[],"cardinality":"+"},{"$type":"EndOfFile"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","fragment":true,"name":"TitleAndAccessibilities","definition":{"$type":"Group","elements":[{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"accDescr","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@12"},"arguments":[]}},{"$type":"Assignment","feature":"accTitle","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@13"},"arguments":[]}},{"$type":"Assignment","feature":"title","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@14"},"arguments":[]}}]},{"$type":"RuleCall","rule":{"$ref":"#/rules@9"},"arguments":[]}],"cardinality":"+"},"entry":false,"parameters":[]},{"$type":"TerminalRule","name":"BOOLEAN","type":{"$type":"ReturnType","name":"boolean"},"definition":{"$type":"TerminalAlternatives","elements":[{"$type":"CharacterRange","left":{"$type":"Keyword","value":"true"},"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"false"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_DESCR","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accDescr(?:[\\\\t ]*:([^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)|\\\\s*{([^}]*)})/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accTitle[\\\\t ]*:(?:[^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*title(?:[\\\\t ][^\\\\n\\\\r]*?(?=%%)|[\\\\t ][^\\\\n\\\\r]*|)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"FLOAT","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"RegexToken","regex":"/[0-9]+\\\\.[0-9]+(?!\\\\.)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"INT","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"RegexToken","regex":"/0|[1-9][0-9]*(?!\\\\.)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"NUMBER","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"TerminalAlternatives","elements":[{"$type":"TerminalRuleCall","rule":{"$ref":"#/rules@15"},"parenthesized":false},{"$type":"TerminalRuleCall","rule":{"$ref":"#/rules@16"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"STRING","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/\\"([^\\"\\\\\\\\]|\\\\\\\\.)*\\"|'([^'\\\\\\\\]|\\\\\\\\.)*'/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ID","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/[\\\\w]([-\\\\w]*\\\\w)?/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"NEWLINE","definition":{"$type":"RegexToken","regex":"/\\\\r?\\\\n/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","hidden":true,"name":"WHITESPACE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]+/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"YAML","definition":{"$type":"RegexToken","regex":"/---[\\\\t ]*\\\\r?\\\\n(?:[\\\\S\\\\s]*?\\\\r?\\\\n)?---(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"DIRECTIVE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%{[\\\\S\\\\s]*?}%%(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"SINGLE_LINE_COMMENT","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%[^\\\\n\\\\r]*/","parenthesized":false},"fragment":false}],"interfaces":[{"$type":"Interface","name":"Entry","attributes":[{"$type":"TypeAttribute","name":"axis","isOptional":true,"type":{"$type":"ReferenceType","referenceType":{"$type":"SimpleType","typeRef":{"$ref":"#/rules@2"}},"isMulti":false}},{"$type":"TypeAttribute","name":"value","type":{"$type":"SimpleType","primitiveType":"number"},"isOptional":false}],"superTypes":[]}],"types":[]}`),`RadarGrammarGrammar`),JF,YF=o(()=>JF??=tP(`{"$type":"Grammar","isDeclared":true,"name":"TreemapGrammar","rules":[{"$type":"ParserRule","fragment":true,"name":"TitleAndAccessibilities","definition":{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"accDescr","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@2"},"arguments":[]}},{"$type":"Assignment","feature":"accTitle","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@3"},"arguments":[]}},{"$type":"Assignment","feature":"title","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@4"},"arguments":[]}}],"cardinality":"+"},"entry":false,"parameters":[]},{"$type":"TerminalRule","name":"BOOLEAN","type":{"$type":"ReturnType","name":"boolean"},"definition":{"$type":"TerminalAlternatives","elements":[{"$type":"CharacterRange","left":{"$type":"Keyword","value":"true"},"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"false"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_DESCR","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accDescr(?:[\\\\t ]*:([^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)|\\\\s*{([^}]*)})/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accTitle[\\\\t ]*:(?:[^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*title(?:[\\\\t ][^\\\\n\\\\r]*?(?=%%)|[\\\\t ][^\\\\n\\\\r]*|)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"ParserRule","entry":true,"name":"Treemap","returnType":{"$ref":"#/interfaces@4"},"definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@6"},"arguments":[]},{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@0"},"arguments":[]},{"$type":"Assignment","feature":"TreemapRows","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@15"},"arguments":[]}}],"cardinality":"*"}]},"fragment":false,"parameters":[]},{"$type":"TerminalRule","name":"TREEMAP_KEYWORD","definition":{"$type":"TerminalAlternatives","elements":[{"$type":"CharacterRange","left":{"$type":"Keyword","value":"treemap-beta"},"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"treemap"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"CLASS_DEF","definition":{"$type":"RegexToken","regex":"/classDef\\\\s+([a-zA-Z_][a-zA-Z0-9_]+)(?:\\\\s+([^;\\\\r\\\\n]*))?(?:;)?/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"STYLE_SEPARATOR","definition":{"$type":"CharacterRange","left":{"$type":"Keyword","value":":::"},"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"SEPARATOR","definition":{"$type":"CharacterRange","left":{"$type":"Keyword","value":":"},"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"COMMA","definition":{"$type":"CharacterRange","left":{"$type":"Keyword","value":","},"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"INDENTATION","definition":{"$type":"RegexToken","regex":"/[ \\\\t]{1,}/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","hidden":true,"name":"WS","definition":{"$type":"RegexToken","regex":"/[ \\\\t]+/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"ML_COMMENT","definition":{"$type":"RegexToken","regex":"/\\\\%\\\\%[^\\\\n]*/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"NL","definition":{"$type":"RegexToken","regex":"/\\\\r?\\\\n/","parenthesized":false},"fragment":false},{"$type":"ParserRule","name":"TreemapRow","definition":{"$type":"Group","elements":[{"$type":"Assignment","feature":"indent","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@11"},"arguments":[]},"cardinality":"?"},{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"item","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}},{"$type":"RuleCall","rule":{"$ref":"#/rules@16"},"arguments":[]}]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"ClassDef","dataType":"string","definition":{"$type":"RuleCall","rule":{"$ref":"#/rules@7"},"arguments":[]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Item","returnType":{"$ref":"#/interfaces@0"},"definition":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@18"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Section","returnType":{"$ref":"#/interfaces@1"},"definition":{"$type":"Group","elements":[{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@23"},"arguments":[]}},{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@8"},"arguments":[]},{"$type":"Assignment","feature":"classSelector","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@20"},"arguments":[]}}],"cardinality":"?"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Leaf","returnType":{"$ref":"#/interfaces@2"},"definition":{"$type":"Group","elements":[{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@23"},"arguments":[]}},{"$type":"RuleCall","rule":{"$ref":"#/rules@11"},"arguments":[],"cardinality":"?"},{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@9"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@10"},"arguments":[]}]},{"$type":"RuleCall","rule":{"$ref":"#/rules@11"},"arguments":[],"cardinality":"?"},{"$type":"Assignment","feature":"value","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@22"},"arguments":[]}},{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@8"},"arguments":[]},{"$type":"Assignment","feature":"classSelector","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@20"},"arguments":[]}}],"cardinality":"?"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"TerminalRule","name":"ID2","definition":{"$type":"RegexToken","regex":"/[a-zA-Z_][a-zA-Z0-9_]*/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"NUMBER2","definition":{"$type":"RegexToken","regex":"/[0-9_\\\\.\\\\,]+/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"ParserRule","name":"MyNumber","dataType":"number","definition":{"$type":"RuleCall","rule":{"$ref":"#/rules@21"},"arguments":[]},"entry":false,"fragment":false,"parameters":[]},{"$type":"TerminalRule","name":"STRING2","definition":{"$type":"RegexToken","regex":"/\\"[^\\"]*\\"|'[^']*'/","parenthesized":false},"fragment":false,"hidden":false}],"interfaces":[{"$type":"Interface","name":"Item","attributes":[{"$type":"TypeAttribute","name":"name","type":{"$type":"SimpleType","primitiveType":"string"},"isOptional":false},{"$type":"TypeAttribute","name":"classSelector","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}}],"superTypes":[]},{"$type":"Interface","name":"Section","superTypes":[{"$ref":"#/interfaces@0"}],"attributes":[]},{"$type":"Interface","name":"Leaf","superTypes":[{"$ref":"#/interfaces@0"}],"attributes":[{"$type":"TypeAttribute","name":"value","type":{"$type":"SimpleType","primitiveType":"number"},"isOptional":false}]},{"$type":"Interface","name":"ClassDefStatement","attributes":[{"$type":"TypeAttribute","name":"className","type":{"$type":"SimpleType","primitiveType":"string"},"isOptional":false},{"$type":"TypeAttribute","name":"styleText","type":{"$type":"SimpleType","primitiveType":"string"},"isOptional":false}],"superTypes":[]},{"$type":"Interface","name":"Treemap","attributes":[{"$type":"TypeAttribute","name":"TreemapRows","type":{"$type":"ArrayType","elementType":{"$type":"SimpleType","typeRef":{"$ref":"#/rules@15"}}},"isOptional":false},{"$type":"TypeAttribute","name":"title","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}},{"$type":"TypeAttribute","name":"accTitle","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}},{"$type":"TypeAttribute","name":"accDescr","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}}],"superTypes":[]}],"imports":[],"types":[],"$comment":"/**\\n * Treemap grammar for Langium\\n * Converted from mindmap grammar\\n *\\n * The ML_COMMENT and NL hidden terminals handle whitespace, comments, and newlines\\n * before the treemap keyword, allowing for empty lines and comments before the\\n * treemap declaration.\\n */"}`),`TreemapGrammarGrammar`),XF,ZF=o(()=>XF??=tP(`{"$type":"Grammar","isDeclared":true,"name":"TreeViewGrammar","rules":[{"$type":"TerminalRule","name":"ACC_DESCR","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accDescr(?:[\\\\t ]*:([^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)|\\\\s*{([^}]*)})/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accTitle[\\\\t ]*:(?:[^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*title(?:[\\\\t ][^\\\\n\\\\r]*?(?=%%)|[\\\\t ][^\\\\n\\\\r]*|)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"ParserRule","entry":true,"name":"TreeView","returnType":{"$ref":"#/interfaces@0"},"definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"treeView-beta"},{"$type":"RuleCall","rule":{"$ref":"#/rules@4"},"arguments":[],"cardinality":"?"},{"$type":"Assignment","feature":"nodes","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@9"},"arguments":[]},"cardinality":"*"}]},"fragment":false,"parameters":[]},{"$type":"ParserRule","fragment":true,"name":"TitleAndAccessibilities","definition":{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"accDescr","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@0"},"arguments":[]}},{"$type":"Assignment","feature":"accTitle","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@1"},"arguments":[]}},{"$type":"Assignment","feature":"title","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@2"},"arguments":[]}}],"cardinality":"+"},"entry":false,"parameters":[]},{"$type":"TerminalRule","name":"INDENTATION","definition":{"$type":"RegexToken","regex":"/[ \\\\t]{1,}/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","hidden":true,"name":"WS","definition":{"$type":"RegexToken","regex":"/[ \\\\t]+/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"ML_COMMENT","definition":{"$type":"RegexToken","regex":"/\\\\%\\\\%[^\\\\n]*/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"NL","definition":{"$type":"RegexToken","regex":"/\\\\r?\\\\n/","parenthesized":false},"fragment":false},{"$type":"ParserRule","name":"TreeNode","definition":{"$type":"Group","elements":[{"$type":"Assignment","feature":"indent","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@5"},"arguments":[]},"cardinality":"?"},{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@10"},"arguments":[]}}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"TerminalRule","name":"STRING2","definition":{"$type":"RegexToken","regex":"/\\"[^\\"]*\\"|'[^']*'/","parenthesized":false},"fragment":false,"hidden":false}],"interfaces":[{"$type":"Interface","name":"TreeView","attributes":[{"$type":"TypeAttribute","name":"nodes","type":{"$type":"ArrayType","elementType":{"$type":"SimpleType","typeRef":{"$ref":"#/rules@9"}}},"isOptional":false},{"$type":"TypeAttribute","name":"title","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}},{"$type":"TypeAttribute","name":"accTitle","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}},{"$type":"TypeAttribute","name":"accDescr","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}}],"superTypes":[]}],"imports":[],"types":[],"$comment":"/**\\n * TreeView grammar for Langium\\n * Converted from treemap grammar\\n *\\n * The ML_COMMENT and NL hidden terminals handle whitespace, comments, and newlines\\n * before the treemap keyword, allowing for empty lines and comments before the\\n * treeView declaration.\\n */"}`),`TreeViewGrammarGrammar`),QF,$F=o(()=>QF??=tP(`{"$type":"Grammar","isDeclared":true,"name":"WardleyGrammar","imports":[],"rules":[{"$type":"ParserRule","entry":true,"name":"Wardley","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@52"},"arguments":[],"cardinality":"*"},{"$type":"RuleCall","rule":{"$ref":"#/rules@25"},"arguments":[]},{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@52"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@42"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@1"},"arguments":[]}],"cardinality":"*"}]},"fragment":false,"parameters":[]},{"$type":"ParserRule","fragment":true,"name":"Statement","definition":{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"size","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@2"},"arguments":[]}},{"$type":"Assignment","feature":"evolution","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@3"},"arguments":[]}},{"$type":"Assignment","feature":"anchors","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@5"},"arguments":[]}},{"$type":"Assignment","feature":"components","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@6"},"arguments":[]}},{"$type":"Assignment","feature":"links","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@9"},"arguments":[]}},{"$type":"Assignment","feature":"evolves","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@10"},"arguments":[]}},{"$type":"Assignment","feature":"pipelines","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@11"},"arguments":[]}},{"$type":"Assignment","feature":"notes","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@13"},"arguments":[]}},{"$type":"Assignment","feature":"annotations","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@14"},"arguments":[]}},{"$type":"Assignment","feature":"annotation","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@15"},"arguments":[]}},{"$type":"Assignment","feature":"accelerators","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}},{"$type":"Assignment","feature":"deaccelerators","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@18"},"arguments":[]}}]},"entry":false,"parameters":[]},{"$type":"ParserRule","name":"Size","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@26"},"arguments":[]},{"$type":"Keyword","value":"["},{"$type":"Assignment","feature":"width","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@48"},"arguments":[]}},{"$type":"Keyword","value":","},{"$type":"Assignment","feature":"height","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@48"},"arguments":[]}},{"$type":"Keyword","value":"]"},{"$type":"RuleCall","rule":{"$ref":"#/rules@41"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Evolution","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@27"},"arguments":[]},{"$type":"Assignment","feature":"stages","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@4"},"arguments":[]}},{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@20"},"arguments":[]},{"$type":"Assignment","feature":"stages","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@4"},"arguments":[]}}],"cardinality":"+"},{"$type":"RuleCall","rule":{"$ref":"#/rules@41"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"EvolutionStage","definition":{"$type":"Group","elements":[{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@51"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@50"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@39"},"arguments":[]}]}},{"$type":"Group","elements":[{"$type":"Keyword","value":"@"},{"$type":"Assignment","feature":"boundary","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]}}],"cardinality":"?"},{"$type":"Group","elements":[{"$type":"Keyword","value":"/"},{"$type":"Assignment","feature":"secondName","operator":"=","terminal":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@51"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@50"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@39"},"arguments":[]}]}}],"cardinality":"?"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Anchor","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@28"},"arguments":[]},{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@50"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@51"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@39"},"arguments":[]}]}},{"$type":"Keyword","value":"["},{"$type":"Assignment","feature":"visibility","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]}},{"$type":"Keyword","value":","},{"$type":"Assignment","feature":"evolution","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]}},{"$type":"Keyword","value":"]"},{"$type":"RuleCall","rule":{"$ref":"#/rules@41"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Component","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@29"},"arguments":[]},{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@50"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@51"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@39"},"arguments":[]}]}},{"$type":"Keyword","value":"["},{"$type":"Assignment","feature":"visibility","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]}},{"$type":"Keyword","value":","},{"$type":"Assignment","feature":"evolution","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]}},{"$type":"Keyword","value":"]"},{"$type":"Assignment","feature":"label","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@7"},"arguments":[]},"cardinality":"?"},{"$type":"Assignment","feature":"decorator","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@8"},"arguments":[]},"cardinality":"?"},{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"inertia","operator":"?=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@31"},"arguments":[]}},{"$type":"Group","elements":[{"$type":"Keyword","value":"("},{"$type":"Assignment","feature":"inertia","operator":"?=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@31"},"arguments":[]}},{"$type":"Keyword","value":")"}]}],"cardinality":"?"},{"$type":"RuleCall","rule":{"$ref":"#/rules@41"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Label","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@30"},"arguments":[]},{"$type":"Keyword","value":"["},{"$type":"Assignment","feature":"negX","operator":"?=","terminal":{"$type":"Keyword","value":"-"},"cardinality":"?"},{"$type":"Assignment","feature":"offsetX","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@48"},"arguments":[]}},{"$type":"Keyword","value":","},{"$type":"Assignment","feature":"negY","operator":"?=","terminal":{"$type":"Keyword","value":"-"},"cardinality":"?"},{"$type":"Assignment","feature":"offsetY","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@48"},"arguments":[]}},{"$type":"Keyword","value":"]"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Decorator","definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"("},{"$type":"Assignment","feature":"strategy","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@24"},"arguments":[]}},{"$type":"Keyword","value":")"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Link","definition":{"$type":"Group","elements":[{"$type":"Assignment","feature":"from","operator":"=","terminal":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@50"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@51"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@39"},"arguments":[]}]}},{"$type":"Assignment","feature":"fromPort","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@21"},"arguments":[]},"cardinality":"?"},{"$type":"Assignment","feature":"arrow","operator":"=","terminal":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@22"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@20"},"arguments":[]}]},"cardinality":"?"},{"$type":"Assignment","feature":"to","operator":"=","terminal":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@50"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@51"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@39"},"arguments":[]}]}},{"$type":"Assignment","feature":"toPort","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@21"},"arguments":[]},"cardinality":"?"},{"$type":"Assignment","feature":"linkLabel","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@23"},"arguments":[]},"cardinality":"?"},{"$type":"RuleCall","rule":{"$ref":"#/rules@41"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Evolve","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@32"},"arguments":[]},{"$type":"Assignment","feature":"component","operator":"=","terminal":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@50"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@51"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@39"},"arguments":[]}]}},{"$type":"Assignment","feature":"target","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]}},{"$type":"RuleCall","rule":{"$ref":"#/rules@41"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Pipeline","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@33"},"arguments":[]},{"$type":"Assignment","feature":"parent","operator":"=","terminal":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@50"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@51"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@39"},"arguments":[]}]}},{"$type":"Keyword","value":"{"},{"$type":"RuleCall","rule":{"$ref":"#/rules@52"},"arguments":[],"cardinality":"+"},{"$type":"Assignment","feature":"components","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@12"},"arguments":[]},"cardinality":"+"},{"$type":"Keyword","value":"}"},{"$type":"RuleCall","rule":{"$ref":"#/rules@41"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"PipelineComponent","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@29"},"arguments":[]},{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@50"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@51"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@39"},"arguments":[]}]}},{"$type":"Keyword","value":"["},{"$type":"Assignment","feature":"evolution","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]}},{"$type":"Keyword","value":"]"},{"$type":"Assignment","feature":"label","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@7"},"arguments":[]},"cardinality":"?"},{"$type":"RuleCall","rule":{"$ref":"#/rules@41"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Note","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@34"},"arguments":[]},{"$type":"Assignment","feature":"text","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@50"},"arguments":[]}},{"$type":"Keyword","value":"["},{"$type":"Assignment","feature":"visibility","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]}},{"$type":"Keyword","value":","},{"$type":"Assignment","feature":"evolution","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]}},{"$type":"Keyword","value":"]"},{"$type":"RuleCall","rule":{"$ref":"#/rules@41"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Annotations","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@35"},"arguments":[]},{"$type":"Keyword","value":"["},{"$type":"Assignment","feature":"x","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@16"},"arguments":[]}},{"$type":"Keyword","value":","},{"$type":"Assignment","feature":"y","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@16"},"arguments":[]}},{"$type":"Keyword","value":"]"},{"$type":"RuleCall","rule":{"$ref":"#/rules@41"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Annotation","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@36"},"arguments":[]},{"$type":"Assignment","feature":"number","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@48"},"arguments":[]}},{"$type":"Keyword","value":","},{"$type":"Keyword","value":"["},{"$type":"Assignment","feature":"x","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@16"},"arguments":[]}},{"$type":"Keyword","value":","},{"$type":"Assignment","feature":"y","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@16"},"arguments":[]}},{"$type":"Keyword","value":"]"},{"$type":"Assignment","feature":"text","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@50"},"arguments":[]}},{"$type":"RuleCall","rule":{"$ref":"#/rules@41"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"CoordinateValue","dataType":"number","definition":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@48"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Accelerator","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@37"},"arguments":[]},{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@50"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@51"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@39"},"arguments":[]}]}},{"$type":"Keyword","value":"["},{"$type":"Assignment","feature":"x","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]}},{"$type":"Keyword","value":","},{"$type":"Assignment","feature":"y","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]}},{"$type":"Keyword","value":"]"},{"$type":"RuleCall","rule":{"$ref":"#/rules@41"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","name":"Deaccelerator","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@38"},"arguments":[]},{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@50"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@51"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@39"},"arguments":[]}]}},{"$type":"Keyword","value":"["},{"$type":"Assignment","feature":"x","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]}},{"$type":"Keyword","value":","},{"$type":"Assignment","feature":"y","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]}},{"$type":"Keyword","value":"]"},{"$type":"RuleCall","rule":{"$ref":"#/rules@41"},"arguments":[]}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"TerminalRule","name":"WARDLEY_NUMBER","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"RegexToken","regex":"/[0-9]+\\\\.[0-9]+/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ARROW","definition":{"$type":"CharacterRange","left":{"$type":"Keyword","value":"->"},"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"LINK_PORT","definition":{"$type":"TerminalAlternatives","elements":[{"$type":"TerminalAlternatives","elements":[{"$type":"CharacterRange","left":{"$type":"Keyword","value":"+<>"},"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"+>"},"parenthesized":false}],"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"+<"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"LINK_ARROW","definition":{"$type":"TerminalAlternatives","elements":[{"$type":"TerminalAlternatives","elements":[{"$type":"TerminalAlternatives","elements":[{"$type":"TerminalAlternatives","elements":[{"$type":"TerminalAlternatives","elements":[{"$type":"CharacterRange","left":{"$type":"Keyword","value":"-->"},"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"-.->"},"parenthesized":false}],"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":">"},"parenthesized":false}],"parenthesized":false},{"$type":"RegexToken","regex":"/\\\\+'[^']*'<>/","parenthesized":false}],"parenthesized":false},{"$type":"RegexToken","regex":"/\\\\+'[^']*'</","parenthesized":false}],"parenthesized":false},{"$type":"RegexToken","regex":"/\\\\+'[^']*'>/","parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"LINK_LABEL","definition":{"$type":"RegexToken","regex":"/;[^\\\\n\\\\r]+/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"STRATEGY","definition":{"$type":"TerminalAlternatives","elements":[{"$type":"TerminalAlternatives","elements":[{"$type":"TerminalAlternatives","elements":[{"$type":"CharacterRange","left":{"$type":"Keyword","value":"build"},"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"buy"},"parenthesized":false}],"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"outsource"},"parenthesized":false}],"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"market"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"KW_WARDLEY","definition":{"$type":"CharacterRange","left":{"$type":"Keyword","value":"wardley-beta"},"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"KW_SIZE","definition":{"$type":"CharacterRange","left":{"$type":"Keyword","value":"size"},"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"KW_EVOLUTION","definition":{"$type":"CharacterRange","left":{"$type":"Keyword","value":"evolution"},"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"KW_ANCHOR","definition":{"$type":"CharacterRange","left":{"$type":"Keyword","value":"anchor"},"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"KW_COMPONENT","definition":{"$type":"CharacterRange","left":{"$type":"Keyword","value":"component"},"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"KW_LABEL","definition":{"$type":"CharacterRange","left":{"$type":"Keyword","value":"label"},"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"KW_INERTIA","definition":{"$type":"CharacterRange","left":{"$type":"Keyword","value":"inertia"},"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"KW_EVOLVE","definition":{"$type":"CharacterRange","left":{"$type":"Keyword","value":"evolve"},"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"KW_PIPELINE","definition":{"$type":"CharacterRange","left":{"$type":"Keyword","value":"pipeline"},"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"KW_NOTE","definition":{"$type":"CharacterRange","left":{"$type":"Keyword","value":"note"},"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"KW_ANNOTATIONS","definition":{"$type":"CharacterRange","left":{"$type":"Keyword","value":"annotations"},"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"KW_ANNOTATION","definition":{"$type":"CharacterRange","left":{"$type":"Keyword","value":"annotation"},"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"KW_ACCELERATOR","definition":{"$type":"CharacterRange","left":{"$type":"Keyword","value":"accelerator"},"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"KW_DEACCELERATOR","definition":{"$type":"CharacterRange","left":{"$type":"Keyword","value":"deaccelerator"},"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"NAME_WITH_SPACES","definition":{"$type":"RegexToken","regex":"/(?!title\\\\s|accTitle|accDescr)[A-Za-z](?:[A-Za-z0-9_()&]|-(?!>))*(?:[ \\\\t]+[A-Za-z(](?:[A-Za-z0-9_()&]|-(?!>))*)*/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","hidden":true,"name":"WS","definition":{"$type":"RegexToken","regex":"/[ \\\\t]+/","parenthesized":false},"fragment":false},{"$type":"ParserRule","name":"EOL","dataType":"string","definition":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@52"},"arguments":[],"cardinality":"+"},{"$type":"EndOfFile"}]},"entry":false,"fragment":false,"parameters":[]},{"$type":"ParserRule","fragment":true,"name":"TitleAndAccessibilities","definition":{"$type":"Group","elements":[{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"accDescr","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@44"},"arguments":[]}},{"$type":"Assignment","feature":"accTitle","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@45"},"arguments":[]}},{"$type":"Assignment","feature":"title","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@46"},"arguments":[]}}]},{"$type":"RuleCall","rule":{"$ref":"#/rules@41"},"arguments":[]}],"cardinality":"+"},"entry":false,"parameters":[]},{"$type":"TerminalRule","name":"BOOLEAN","type":{"$type":"ReturnType","name":"boolean"},"definition":{"$type":"TerminalAlternatives","elements":[{"$type":"CharacterRange","left":{"$type":"Keyword","value":"true"},"parenthesized":false},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"false"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_DESCR","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accDescr(?:[\\\\t ]*:([^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)|\\\\s*{([^}]*)})/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accTitle[\\\\t ]*:(?:[^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*title(?:[\\\\t ][^\\\\n\\\\r]*?(?=%%)|[\\\\t ][^\\\\n\\\\r]*|)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"FLOAT","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"RegexToken","regex":"/[0-9]+\\\\.[0-9]+(?!\\\\.)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"INT","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"RegexToken","regex":"/0|[1-9][0-9]*(?!\\\\.)/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"NUMBER","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"TerminalAlternatives","elements":[{"$type":"TerminalRuleCall","rule":{"$ref":"#/rules@47"},"parenthesized":false},{"$type":"TerminalRuleCall","rule":{"$ref":"#/rules@48"},"parenthesized":false}],"parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"STRING","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/\\"([^\\"\\\\\\\\]|\\\\\\\\.)*\\"|'([^'\\\\\\\\]|\\\\\\\\.)*'/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ID","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/[\\\\w]([-\\\\w]*\\\\w)?/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"NEWLINE","definition":{"$type":"RegexToken","regex":"/\\\\r?\\\\n/","parenthesized":false},"fragment":false,"hidden":false},{"$type":"TerminalRule","hidden":true,"name":"WHITESPACE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]+/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"YAML","definition":{"$type":"RegexToken","regex":"/---[\\\\t ]*\\\\r?\\\\n(?:[\\\\S\\\\s]*?\\\\r?\\\\n)?---(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"DIRECTIVE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%{[\\\\S\\\\s]*?}%%(?:\\\\r?\\\\n|(?!\\\\S))/","parenthesized":false},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"SINGLE_LINE_COMMENT","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%[^\\\\n\\\\r]*/","parenthesized":false},"fragment":false}],"interfaces":[],"types":[]}`),`WardleyGrammarGrammar`),eI={languageId:`architecture`,fileExtensions:[`.mmd`,`.mermaid`],caseInsensitive:!1,mode:`production`},tI={languageId:`eventmodeling`,fileExtensions:[`.mmd`,`.mermaid`],caseInsensitive:!1,mode:`production`},nI={languageId:`gitGraph`,fileExtensions:[`.mmd`,`.mermaid`],caseInsensitive:!1,mode:`production`},rI={languageId:`info`,fileExtensions:[`.mmd`,`.mermaid`],caseInsensitive:!1,mode:`production`},iI={languageId:`packet`,fileExtensions:[`.mmd`,`.mermaid`],caseInsensitive:!1,mode:`production`},aI={languageId:`pie`,fileExtensions:[`.mmd`,`.mermaid`],caseInsensitive:!1,mode:`production`},oI={languageId:`radar`,fileExtensions:[`.mmd`,`.mermaid`],caseInsensitive:!1,mode:`production`},sI={languageId:`treemap`,fileExtensions:[`.mmd`,`.mermaid`],caseInsensitive:!1,mode:`production`},cI={languageId:`treeView`,fileExtensions:[`.mmd`,`.mermaid`],caseInsensitive:!1,mode:`production`},lI={languageId:`wardley`,fileExtensions:[`.mmd`,`.mermaid`],caseInsensitive:!1,mode:`production`},uI={AstReflection:o(()=>new MF,`AstReflection`)},dI={Grammar:o(()=>FF(),`Grammar`),LanguageMetaData:o(()=>eI,`LanguageMetaData`),parser:{}},fI={Grammar:o(()=>LF(),`Grammar`),LanguageMetaData:o(()=>tI,`LanguageMetaData`),parser:{}},pI={Grammar:o(()=>zF(),`Grammar`),LanguageMetaData:o(()=>nI,`LanguageMetaData`),parser:{}},mI={Grammar:o(()=>VF(),`Grammar`),LanguageMetaData:o(()=>rI,`LanguageMetaData`),parser:{}},hI={Grammar:o(()=>UF(),`Grammar`),LanguageMetaData:o(()=>iI,`LanguageMetaData`),parser:{}},gI={Grammar:o(()=>GF(),`Grammar`),LanguageMetaData:o(()=>aI,`LanguageMetaData`),parser:{}},_I={Grammar:o(()=>qF(),`Grammar`),LanguageMetaData:o(()=>oI,`LanguageMetaData`),parser:{}},vI={Grammar:o(()=>YF(),`Grammar`),LanguageMetaData:o(()=>sI,`LanguageMetaData`),parser:{}},yI={Grammar:o(()=>ZF(),`Grammar`),LanguageMetaData:o(()=>cI,`LanguageMetaData`),parser:{}},bI={Grammar:o(()=>$F(),`Grammar`),LanguageMetaData:o(()=>lI,`LanguageMetaData`),parser:{}},xI={ACC_DESCR:/accDescr(?:[\t ]*:([^\n\r]*)|\s*{([^}]*)})/,ACC_TITLE:/accTitle[\t ]*:([^\n\r]*)/,TITLE:/title([\t ][^\n\r]*|)/},SI=class extends Rj{static{o(this,`AbstractMermaidValueConverter`)}runConverter(e,t,n){let r=this.runCommonConverter(e,t,n);return r===void 0&&(r=this.runCustomConverter(e,t,n)),r===void 0?super.runConverter(e,t,n):r}runCommonConverter(e,t,n){let r=xI[e.name];if(r===void 0)return;let i=r.exec(t);if(i!==null){if(i[1]!==void 0)return i[1].trim().replace(/[\t ]{2,}/gm,` `);if(i[2]!==void 0)return i[2].replace(/^\s*/gm,``).replace(/\s+$/gm,``).replace(/[\t ]{2,}/gm,` `).replace(/[\n\r]{2,}/gm,`
159
+ `)}}},CI=class extends SI{static{o(this,`CommonValueConverter`)}runCustomConverter(e,t,n){}},wI=class extends Lj{static{o(this,`AbstractMermaidTokenBuilder`)}constructor(e){super(),this.keywords=new Set(e)}buildKeywordTokens(e,t,n){let r=super.buildKeywordTokens(e,t,n);return r.forEach(e=>{this.keywords.has(e.name)&&e.PATTERN!==void 0&&(e.PATTERN=RegExp(e.PATTERN.toString()+`(?:(?=%%)|(?!\\S))`))}),r}};(class extends wI{static{o(this,`CommonTokenBuilder`)}});export{FN as _,ZN as a,UP as b,mI as c,gI as d,_I as f,o as g,bI as h,CI as i,uI as l,vI as m,SI as n,fI as o,yI as p,dI as r,pI as s,wI as t,hI as u,IN as v,RN as y};