@loopstack/loopstack-studio 0.27.0 → 0.29.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 (371) hide show
  1. package/dist/_virtual/rolldown_runtime.js +13 -15
  2. package/dist/components/ai-elements/code-block.js +2 -2
  3. package/dist/components/dynamic-form/Form.js +49 -52
  4. package/dist/components/loopstack-elements/tool.js +18 -9
  5. package/dist/config.js +6 -0
  6. package/dist/features/debug/components/WorkflowFlowViewer.js +94 -81
  7. package/dist/features/debug/components/workflow-flow/StateNode.js +154 -79
  8. package/dist/features/debug/components/workflow-flow/WorkflowGraph.js +43 -31
  9. package/dist/features/debug/components/workflow-flow/WorkflowTransitionEdge.js +52 -51
  10. package/dist/features/debug/lib/edge-paths.js +45 -30
  11. package/dist/features/debug/lib/flow-types.js +2 -0
  12. package/dist/features/debug/lib/flow-utils.js +66 -64
  13. package/dist/features/documents/DocumentRenderer.js +2 -2
  14. package/dist/features/documents/components/DocumentList.js +19 -18
  15. package/dist/features/documents/renderers/LlmMessage.js +89 -0
  16. package/dist/features/workbench/WorkflowItem.js +4 -3
  17. package/dist/features/workbench/components/EmbedLogsContent.js +5 -0
  18. package/dist/features/workbench/components/PreviewEmptyState.js +10 -0
  19. package/dist/features/workbench/components/PreviewWorkbench.js +14 -0
  20. package/dist/features/workbench/components/RecentRunItem.js +48 -0
  21. package/dist/features/workbench/components/WorkflowForms.js +4 -3
  22. package/dist/features/workbench/hooks/useEmbedBridge.js +3 -0
  23. package/dist/features/workbench/hooks/useWorkflowData.js +9 -9
  24. package/dist/features/workbench/index.js +4 -0
  25. package/dist/features/workspaces/components/ExecutionTimeline.js +9 -8
  26. package/dist/loopstack-studio.css +1 -1
  27. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/{architecture-YZFGNWBL.js → architecture-7EHR7CIX.js} +2 -2
  28. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/{chunk-7N4EOEYR.js → chunk-4EGX6M5U.js} +9 -13
  29. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/{chunk-KGLVRYIC.js → chunk-5DO6E6H7.js} +3 -7
  30. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/chunk-BR22UD5L.js +56 -0
  31. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/{chunk-2KRD3SAO.js → chunk-FHYWG6QK.js} +3 -7
  32. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/{chunk-FOC6F5B3.js → chunk-MPE355IW.js} +3 -7
  33. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/chunk-MZUSXYTE.js +24 -0
  34. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/chunk-N66VUXT2.js +48 -0
  35. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/chunk-NNHCCRGN.js +20219 -0
  36. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/chunk-PUPMXCY4.js +19 -0
  37. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/{chunk-67CJDMHE.js → chunk-UIBZB4QT.js} +3 -7
  38. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/chunk-WCWK7LTN.js +25 -0
  39. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/eventmodeling-FCH6USID.js +3 -0
  40. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/{gitGraph-7Q5UKJZL.js → gitGraph-WXDBUCRP.js} +2 -2
  41. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/info-J43DQDTF.js +3 -0
  42. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/packet-YPE3B663.js +3 -0
  43. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/pie-LRSECV5Y.js +3 -0
  44. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/radar-GUYGQ44K.js +3 -0
  45. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/{treeView-SZITEDCU.js → treeView-BLDUP644.js} +2 -2
  46. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/treemap-LRROVOQU.js +3 -0
  47. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/wardley-L42UT6IY.js +3 -0
  48. package/dist/node_modules/@mermaid-js/parser/dist/mermaid-parser.core.js +24 -19
  49. package/dist/node_modules/@ungap/structured-clone/esm/deserialize.js +36 -26
  50. package/dist/node_modules/@xyflow/react/dist/esm/index.js +1 -1
  51. package/dist/node_modules/cytoscape/dist/cytoscape.esm.js +257 -254
  52. package/dist/node_modules/dagre-d3-es/src/dagre/greedy-fas.js +19 -19
  53. package/dist/node_modules/dagre-d3-es/src/dagre/layout.js +48 -48
  54. package/dist/node_modules/dagre-d3-es/src/dagre/nesting-graph.js +9 -9
  55. package/dist/node_modules/dagre-d3-es/src/dagre/order/cross-count.js +3 -3
  56. package/dist/node_modules/dagre-d3-es/src/dagre/order/index.js +11 -11
  57. package/dist/node_modules/dagre-d3-es/src/dagre/order/init-order.js +4 -4
  58. package/dist/node_modules/dagre-d3-es/src/dagre/order/resolve-conflicts.js +4 -4
  59. package/dist/node_modules/dagre-d3-es/src/dagre/order/sort-subgraph.js +8 -8
  60. package/dist/node_modules/dagre-d3-es/src/dagre/order/sort.js +5 -5
  61. package/dist/node_modules/dagre-d3-es/src/dagre/position/bk.js +72 -72
  62. package/dist/node_modules/dagre-d3-es/src/dagre/position/index.js +1 -1
  63. package/dist/node_modules/dagre-d3-es/src/dagre/rank/network-simplex.js +25 -25
  64. package/dist/node_modules/dagre-d3-es/src/dagre/rank/util.js +8 -8
  65. package/dist/node_modules/dagre-d3-es/src/dagre/util.js +48 -48
  66. package/dist/node_modules/dagre-d3-es/src/graphlib/graph.js +109 -109
  67. package/dist/node_modules/dagre-d3-es/src/graphlib/json.js +17 -17
  68. package/dist/node_modules/dompurify/dist/purify.es.js +301 -209
  69. package/dist/node_modules/es-toolkit/dist/_internal/globalThis.js +4 -0
  70. package/dist/node_modules/es-toolkit/dist/_internal/isUnsafeProperty.js +4 -0
  71. package/dist/node_modules/es-toolkit/dist/compat/_internal/getSymbols.js +4 -0
  72. package/dist/node_modules/es-toolkit/dist/compat/_internal/getTag.js +4 -0
  73. package/dist/node_modules/es-toolkit/dist/compat/_internal/isPrototype.js +5 -0
  74. package/dist/node_modules/es-toolkit/dist/compat/_internal/tags.js +2 -0
  75. package/dist/node_modules/es-toolkit/dist/compat/function/memoize.js +12 -0
  76. package/dist/node_modules/es-toolkit/dist/compat/object/clone.js +97 -0
  77. package/dist/node_modules/es-toolkit/dist/compat/object/cloneDeep.js +5 -0
  78. package/dist/node_modules/es-toolkit/dist/compat/object/cloneDeepWith.js +29 -0
  79. package/dist/node_modules/es-toolkit/dist/compat/object/merge.js +6 -0
  80. package/dist/node_modules/es-toolkit/dist/compat/object/mergeWith.js +49 -0
  81. package/dist/node_modules/es-toolkit/dist/compat/predicate/isArguments.js +5 -0
  82. package/dist/node_modules/es-toolkit/dist/compat/predicate/isArray.js +4 -0
  83. package/dist/node_modules/es-toolkit/dist/compat/predicate/isArrayLike.js +5 -0
  84. package/dist/node_modules/es-toolkit/dist/compat/predicate/isArrayLikeObject.js +6 -0
  85. package/dist/node_modules/es-toolkit/dist/compat/predicate/isEmpty.js +16 -0
  86. package/dist/node_modules/es-toolkit/dist/compat/predicate/isObjectLike.js +4 -0
  87. package/dist/node_modules/es-toolkit/dist/compat/predicate/isPlainObject.js +12 -0
  88. package/dist/node_modules/es-toolkit/dist/compat/predicate/isTypedArray.js +5 -0
  89. package/dist/node_modules/es-toolkit/dist/function/noop.js +2 -0
  90. package/dist/node_modules/es-toolkit/dist/object/clone.js +29 -0
  91. package/dist/node_modules/es-toolkit/dist/object/cloneDeepWith.js +114 -0
  92. package/dist/node_modules/es-toolkit/dist/predicate/isBuffer.js +5 -0
  93. package/dist/node_modules/es-toolkit/dist/predicate/isLength.js +4 -0
  94. package/dist/node_modules/es-toolkit/dist/predicate/isPrimitive.js +4 -0
  95. package/dist/node_modules/es-toolkit/dist/predicate/isTypedArray.js +4 -0
  96. package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/tokenizer/index.js +2 -2
  97. package/dist/node_modules/internmap/src/index.js +1 -1
  98. package/dist/node_modules/katex/dist/katex.js +379 -417
  99. package/dist/node_modules/lodash-es/_arrayLikeKeys.js +3 -3
  100. package/dist/node_modules/lodash-es/_assignMergeValue.js +1 -1
  101. package/dist/node_modules/lodash-es/_assignValue.js +1 -1
  102. package/dist/node_modules/lodash-es/_baseClone.js +9 -9
  103. package/dist/node_modules/lodash-es/_baseForOwn.js +1 -1
  104. package/dist/node_modules/lodash-es/_baseIsEqualDeep.js +1 -1
  105. package/dist/node_modules/lodash-es/_baseMatchesProperty.js +6 -6
  106. package/dist/node_modules/lodash-es/_baseMerge.js +2 -2
  107. package/dist/node_modules/lodash-es/_baseMergeDeep.js +7 -7
  108. package/dist/node_modules/lodash-es/_baseOrderBy.js +12 -12
  109. package/dist/node_modules/lodash-es/_baseRest.js +1 -1
  110. package/dist/node_modules/lodash-es/_baseSet.js +1 -1
  111. package/dist/node_modules/lodash-es/_baseSetToString.js +3 -3
  112. package/dist/node_modules/lodash-es/_baseToString.js +2 -2
  113. package/dist/node_modules/lodash-es/_baseUniq.js +1 -1
  114. package/dist/node_modules/lodash-es/_createRange.js +1 -1
  115. package/dist/node_modules/lodash-es/_createSet.js +3 -3
  116. package/dist/node_modules/lodash-es/_flatRest.js +1 -1
  117. package/dist/node_modules/lodash-es/_getAllKeys.js +2 -2
  118. package/dist/node_modules/lodash-es/_getAllKeysIn.js +1 -1
  119. package/dist/node_modules/lodash-es/_getSymbolsIn.js +1 -1
  120. package/dist/node_modules/lodash-es/_getTag.js +1 -1
  121. package/dist/node_modules/lodash-es/_hasPath.js +2 -2
  122. package/dist/node_modules/lodash-es/_initCloneByTag.js +1 -1
  123. package/dist/node_modules/lodash-es/_initCloneObject.js +1 -1
  124. package/dist/node_modules/lodash-es/_isFlattenable.js +1 -1
  125. package/dist/node_modules/lodash-es/_isIterateeCall.js +1 -1
  126. package/dist/node_modules/lodash-es/_isKey.js +1 -1
  127. package/dist/node_modules/lodash-es/_setToString.js +1 -1
  128. package/dist/node_modules/lodash-es/defaults.js +1 -1
  129. package/dist/node_modules/lodash-es/findIndex.js +2 -2
  130. package/dist/node_modules/lodash-es/forEach.js +1 -1
  131. package/dist/node_modules/lodash-es/forIn.js +1 -1
  132. package/dist/node_modules/lodash-es/isEmpty.js +2 -2
  133. package/dist/node_modules/lodash-es/isPlainObject.js +1 -1
  134. package/dist/node_modules/lodash-es/map.js +1 -1
  135. package/dist/node_modules/lodash-es/max.js +1 -1
  136. package/dist/node_modules/lodash-es/merge.js +3 -3
  137. package/dist/node_modules/lodash-es/min.js +1 -1
  138. package/dist/node_modules/lodash-es/minBy.js +1 -1
  139. package/dist/node_modules/lodash-es/reduce.js +1 -1
  140. package/dist/node_modules/lodash-es/toNumber.js +1 -1
  141. package/dist/node_modules/lodash-es/union.js +3 -3
  142. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{architectureDiagram-Q4EWVU46.js → architectureDiagram-3BPJPVTR.js} +310 -308
  143. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{blockDiagram-DXYQGD6D.js → blockDiagram-GPEHLZMM.js} +215 -190
  144. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{c4Diagram-AHTNJAMY.js → c4Diagram-AAUBKEIU.js} +3 -3
  145. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{chunk-EDXVE4YY.js → chunk-2J33WTMH.js} +1 -1
  146. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{chunk-5FUZZQ4R.js → chunk-3OPIFGDE.js} +48 -20
  147. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{chunk-5PVQY5BW.js → chunk-5ZQYHXKU.js} +8 -8
  148. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{chunk-4TB4RGXK.js → chunk-727SXJPM.js} +555 -459
  149. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{chunk-OYMX7WX6.js → chunk-AQP2D5EJ.js} +155 -145
  150. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{chunk-ICPOFSXX.js → chunk-CSCIHK7Q.js} +106 -12
  151. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{chunk-ENJZ2VHE.js → chunk-KSCS5N6A.js} +12 -12
  152. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{chunk-ZZ45TVLE.js → chunk-L5ZTLDWV.js} +2 -2
  153. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{chunk-336JU56O.js → chunk-LZXEDZCA.js} +5 -5
  154. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{chunk-YZCP3GAM.js → chunk-ND2GUHAM.js} +1 -1
  155. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{chunk-X2U36JSP.js → chunk-NZK2D7GU.js} +1 -1
  156. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{chunk-U2HBQHQK.js → chunk-O5CBEL6O.js} +2 -2
  157. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{chunk-426QAEUC.js → chunk-WU5MYG2G.js} +1 -1
  158. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{classDiagram-6PBFFD2Q.js → classDiagram-4FO5ZUOK.js} +11 -11
  159. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{classDiagram-v2-HSJHXN6E.js → classDiagram-v2-Q7XG4LA2.js} +11 -11
  160. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{dagre-KV5264BT.js → dagre-BM42HDAG.js} +8 -8
  161. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{diagram-MMDJMWI5.js → diagram-2AECGRRQ.js} +3 -3
  162. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{diagram-5BDNPKRD.js → diagram-5GNKFQAL.js} +3 -3
  163. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/diagram-KO2AKTUF.js +433 -0
  164. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{diagram-TYMM5635.js → diagram-LMA3HP47.js} +3 -3
  165. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{diagram-G4DWMVQ6.js → diagram-OG6HWLK6.js} +5 -5
  166. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{erDiagram-SMLLAGMA.js → erDiagram-TEJ5UH35.js} +9 -9
  167. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{flowDiagram-DWJPFMVM.js → flowDiagram-I6XJVG4X.js} +10 -10
  168. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{ganttDiagram-T4ZO3ILL.js → ganttDiagram-6RSMTGT7.js} +7 -4
  169. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{gitGraphDiagram-UUTBAWPF.js → gitGraphDiagram-PVQCEYII.js} +2 -2
  170. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{infoDiagram-42DDH7IO.js → infoDiagram-5YYISTIA.js} +3 -3
  171. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{ishikawaDiagram-UXIWVN3A.js → ishikawaDiagram-YF4QCWOH.js} +3 -3
  172. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{journeyDiagram-VCZTEJTY.js → journeyDiagram-JHISSGLW.js} +2 -2
  173. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{kanban-definition-6JOO6SKY.js → kanban-definition-UN3LZRKU.js} +7 -7
  174. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{mindmap-definition-QFDTVHPH.js → mindmap-definition-RKZ34NQL.js} +9 -9
  175. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{pieDiagram-DEJITSTG.js → pieDiagram-4H26LBE5.js} +3 -3
  176. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{quadrantDiagram-34T5L4WZ.js → quadrantDiagram-W4KKPZXB.js} +364 -337
  177. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{requirementDiagram-MS252O5E.js → requirementDiagram-4Y6WPE33.js} +9 -9
  178. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{sankeyDiagram-XADWPNL6.js → sankeyDiagram-5OEKKPKP.js} +187 -138
  179. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{sequenceDiagram-FGHM5R23.js → sequenceDiagram-3UESZ5HK.js} +15 -8
  180. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{stateDiagram-FHFEXIEX.js → stateDiagram-AJRCARHV.js} +10 -10
  181. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{stateDiagram-v2-QKLJ7IA2.js → stateDiagram-v2-BHNVJYJU.js} +10 -10
  182. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{timeline-definition-GMOUNBTQ.js → timeline-definition-PNZ67QCA.js} +3 -3
  183. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{vennDiagram-DHZGUBPP.js → vennDiagram-CIIHVFJN.js} +3 -3
  184. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/wardleyDiagram-YWT4CUSO.js +640 -0
  185. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{xychartDiagram-5P7HB3ND.js → xychartDiagram-2RQKCTM6.js} +4 -4
  186. package/dist/node_modules/mermaid/dist/mermaid.core.js +96 -70
  187. package/dist/node_modules/stylis/src/Enum.js +2 -2
  188. package/dist/node_modules/stylis/src/Middleware.js +9 -0
  189. package/dist/node_modules/stylis/src/Parser.js +55 -44
  190. package/dist/node_modules/stylis/src/Utility.js +9 -12
  191. package/dist/node_modules/unified/lib/index.js +1 -1
  192. package/dist/packages/contracts/dist/enums/index.js +4 -24
  193. package/dist/packages/contracts/dist/enums/registry.enum.js +9 -20
  194. package/dist/packages/contracts/dist/enums/sort-order.enum.js +5 -10
  195. package/dist/packages/contracts/dist/enums/user-type.enum.js +5 -10
  196. package/dist/packages/contracts/dist/enums/workflow-state.enum.js +5 -10
  197. package/dist/pages/EmbedWorkbenchPage.js +4 -3
  198. package/dist/pages/PreviewWorkbenchPage.js +126 -124
  199. package/dist/pages/StudioLandingPage.js +28 -72
  200. package/package.json +2 -2
  201. package/dist/features/documents/renderers/ClaudeMessage.js +0 -96
  202. package/dist/node_modules/@chevrotain/gast/lib/src/helpers.js +0 -23
  203. package/dist/node_modules/@chevrotain/gast/lib/src/model.js +0 -151
  204. package/dist/node_modules/@chevrotain/gast/lib/src/visitor.js +0 -40
  205. package/dist/node_modules/@chevrotain/regexp-to-ast/lib/src/api.js +0 -2
  206. package/dist/node_modules/@chevrotain/regexp-to-ast/lib/src/base-regexp-visitor.js +0 -85
  207. package/dist/node_modules/@chevrotain/regexp-to-ast/lib/src/character-classes.js +0 -35
  208. package/dist/node_modules/@chevrotain/regexp-to-ast/lib/src/regexp-parser.js +0 -570
  209. package/dist/node_modules/@chevrotain/regexp-to-ast/lib/src/utils.js +0 -25
  210. package/dist/node_modules/@chevrotain/utils/lib/src/print.js +0 -9
  211. package/dist/node_modules/@chevrotain/utils/lib/src/timer.js +0 -8
  212. package/dist/node_modules/@chevrotain/utils/lib/src/to-fast-properties.js +0 -10
  213. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/chunk-AA7GKIK3.js +0 -28
  214. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/chunk-CIAEETIT.js +0 -23
  215. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/chunk-K5T4RW27.js +0 -1197
  216. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/chunk-LIHQZDEY.js +0 -60
  217. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/chunk-ORNJ4GCN.js +0 -29
  218. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/info-OMHHGYJF.js +0 -3
  219. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/packet-4T2RLAQJ.js +0 -3
  220. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/pie-ZZUOXDRM.js +0 -3
  221. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/radar-PYXPWWZC.js +0 -3
  222. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/treemap-W4RFUUIX.js +0 -3
  223. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/wardley-RL74JXVD.js +0 -3
  224. package/dist/node_modules/chevrotain/lib/src/api.js +0 -10
  225. package/dist/node_modules/chevrotain/lib/src/lang/lang_extensions.js +0 -10
  226. package/dist/node_modules/chevrotain/lib/src/parse/constants.js +0 -2
  227. package/dist/node_modules/chevrotain/lib/src/parse/cst/cst.js +0 -13
  228. package/dist/node_modules/chevrotain/lib/src/parse/cst/cst_visitor.js +0 -49
  229. package/dist/node_modules/chevrotain/lib/src/parse/errors_public.js +0 -77
  230. package/dist/node_modules/chevrotain/lib/src/parse/exceptions_public.js +0 -33
  231. package/dist/node_modules/chevrotain/lib/src/parse/grammar/checks.js +0 -275
  232. package/dist/node_modules/chevrotain/lib/src/parse/grammar/first.js +0 -23
  233. package/dist/node_modules/chevrotain/lib/src/parse/grammar/follow.js +0 -28
  234. package/dist/node_modules/chevrotain/lib/src/parse/grammar/gast/gast_resolver_public.js +0 -14
  235. package/dist/node_modules/chevrotain/lib/src/parse/grammar/interpreter.js +0 -262
  236. package/dist/node_modules/chevrotain/lib/src/parse/grammar/keys.js +0 -5
  237. package/dist/node_modules/chevrotain/lib/src/parse/grammar/llk_lookahead.js +0 -41
  238. package/dist/node_modules/chevrotain/lib/src/parse/grammar/lookahead.js +0 -241
  239. package/dist/node_modules/chevrotain/lib/src/parse/grammar/resolver.js +0 -30
  240. package/dist/node_modules/chevrotain/lib/src/parse/grammar/rest.js +0 -56
  241. package/dist/node_modules/chevrotain/lib/src/parse/parser/parser.js +0 -114
  242. package/dist/node_modules/chevrotain/lib/src/parse/parser/traits/error_handler.js +0 -46
  243. package/dist/node_modules/chevrotain/lib/src/parse/parser/traits/gast_recorder.js +0 -166
  244. package/dist/node_modules/chevrotain/lib/src/parse/parser/traits/lexer_adapter.js +0 -43
  245. package/dist/node_modules/chevrotain/lib/src/parse/parser/traits/looksahead.js +0 -107
  246. package/dist/node_modules/chevrotain/lib/src/parse/parser/traits/perf_tracer.js +0 -21
  247. package/dist/node_modules/chevrotain/lib/src/parse/parser/traits/recognizer_api.js +0 -312
  248. package/dist/node_modules/chevrotain/lib/src/parse/parser/traits/recognizer_engine.js +0 -285
  249. package/dist/node_modules/chevrotain/lib/src/parse/parser/traits/recoverable.js +0 -144
  250. package/dist/node_modules/chevrotain/lib/src/parse/parser/traits/tree_builder.js +0 -92
  251. package/dist/node_modules/chevrotain/lib/src/parse/parser/utils/apply_mixins.js +0 -11
  252. package/dist/node_modules/chevrotain/lib/src/scan/lexer.js +0 -437
  253. package/dist/node_modules/chevrotain/lib/src/scan/lexer_errors_public.js +0 -9
  254. package/dist/node_modules/chevrotain/lib/src/scan/lexer_public.js +0 -253
  255. package/dist/node_modules/chevrotain/lib/src/scan/reg_exp.js +0 -152
  256. package/dist/node_modules/chevrotain/lib/src/scan/reg_exp_parser.js +0 -15
  257. package/dist/node_modules/chevrotain/lib/src/scan/tokens.js +0 -65
  258. package/dist/node_modules/chevrotain/lib/src/scan/tokens_public.js +0 -39
  259. package/dist/node_modules/chevrotain-allstar/lib/all-star-lookahead.js +0 -346
  260. package/dist/node_modules/chevrotain-allstar/lib/atn.js +0 -194
  261. package/dist/node_modules/chevrotain-allstar/lib/dfa.js +0 -32
  262. package/dist/node_modules/chevrotain-allstar/lib/index.js +0 -1
  263. package/dist/node_modules/langium/lib/default-module.js +0 -85
  264. package/dist/node_modules/langium/lib/dependency-injection.js +0 -62
  265. package/dist/node_modules/langium/lib/documentation/comment-provider.js +0 -11
  266. package/dist/node_modules/langium/lib/documentation/documentation-provider.js +0 -36
  267. package/dist/node_modules/langium/lib/documentation/jsdoc.js +0 -303
  268. package/dist/node_modules/langium/lib/index.js +0 -182
  269. package/dist/node_modules/langium/lib/languages/generated/ast.js +0 -1089
  270. package/dist/node_modules/langium/lib/languages/grammar-config.js +0 -13
  271. package/dist/node_modules/langium/lib/parser/async-parser.js +0 -83
  272. package/dist/node_modules/langium/lib/parser/completion-parser-builder.js +0 -7
  273. package/dist/node_modules/langium/lib/parser/cst-node-builder.js +0 -160
  274. package/dist/node_modules/langium/lib/parser/indentation-aware.js +0 -141
  275. package/dist/node_modules/langium/lib/parser/langium-parser-builder.js +0 -11
  276. package/dist/node_modules/langium/lib/parser/langium-parser.js +0 -388
  277. package/dist/node_modules/langium/lib/parser/lexer.js +0 -50
  278. package/dist/node_modules/langium/lib/parser/parser-builder-base.js +0 -275
  279. package/dist/node_modules/langium/lib/parser/token-builder.js +0 -61
  280. package/dist/node_modules/langium/lib/parser/value-converter.js +0 -78
  281. package/dist/node_modules/langium/lib/references/linker.js +0 -190
  282. package/dist/node_modules/langium/lib/references/name-provider.js +0 -13
  283. package/dist/node_modules/langium/lib/references/references.js +0 -76
  284. package/dist/node_modules/langium/lib/references/scope-computation.js +0 -35
  285. package/dist/node_modules/langium/lib/references/scope-provider.js +0 -34
  286. package/dist/node_modules/langium/lib/references/scope.js +0 -73
  287. package/dist/node_modules/langium/lib/serializer/hydrator.js +0 -125
  288. package/dist/node_modules/langium/lib/serializer/json-serializer.js +0 -145
  289. package/dist/node_modules/langium/lib/service-registry.js +0 -37
  290. package/dist/node_modules/langium/lib/syntax-tree.js +0 -70
  291. package/dist/node_modules/langium/lib/utils/ast-utils.js +0 -157
  292. package/dist/node_modules/langium/lib/utils/caching.js +0 -91
  293. package/dist/node_modules/langium/lib/utils/cancellation.js +0 -5
  294. package/dist/node_modules/langium/lib/utils/collections.js +0 -85
  295. package/dist/node_modules/langium/lib/utils/cst-utils.js +0 -190
  296. package/dist/node_modules/langium/lib/utils/disposable.js +0 -8
  297. package/dist/node_modules/langium/lib/utils/errors.js +0 -12
  298. package/dist/node_modules/langium/lib/utils/event.js +0 -5
  299. package/dist/node_modules/langium/lib/utils/grammar-loader.js +0 -22
  300. package/dist/node_modules/langium/lib/utils/grammar-utils.js +0 -296
  301. package/dist/node_modules/langium/lib/utils/index.js +0 -53
  302. package/dist/node_modules/langium/lib/utils/promise-utils.js +0 -30
  303. package/dist/node_modules/langium/lib/utils/regexp-utils.js +0 -167
  304. package/dist/node_modules/langium/lib/utils/stream.js +0 -327
  305. package/dist/node_modules/langium/lib/utils/uri-utils.js +0 -107
  306. package/dist/node_modules/langium/lib/validation/document-validator.js +0 -210
  307. package/dist/node_modules/langium/lib/validation/validation-registry.js +0 -87
  308. package/dist/node_modules/langium/lib/workspace/ast-descriptions.js +0 -57
  309. package/dist/node_modules/langium/lib/workspace/ast-node-locator.js +0 -28
  310. package/dist/node_modules/langium/lib/workspace/configuration.js +0 -51
  311. package/dist/node_modules/langium/lib/workspace/document-builder.js +0 -201
  312. package/dist/node_modules/langium/lib/workspace/documents.js +0 -142
  313. package/dist/node_modules/langium/lib/workspace/file-system-provider.js +0 -34
  314. package/dist/node_modules/langium/lib/workspace/index-manager.js +0 -49
  315. package/dist/node_modules/langium/lib/workspace/profiler.js +0 -89
  316. package/dist/node_modules/langium/lib/workspace/workspace-lock.js +0 -42
  317. package/dist/node_modules/langium/lib/workspace/workspace-manager.js +0 -66
  318. package/dist/node_modules/lodash-es/flatMap.js +0 -7
  319. package/dist/node_modules/lodash-es/uniqBy.js +0 -7
  320. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/wardleyDiagram-NUSXRM2D.js +0 -574
  321. package/dist/node_modules/vscode-jsonrpc/browser.js +0 -7
  322. package/dist/node_modules/vscode-jsonrpc/lib/browser/main.js +0 -52
  323. package/dist/node_modules/vscode-jsonrpc/lib/browser/ril.js +0 -120
  324. package/dist/node_modules/vscode-jsonrpc/lib/common/api.js +0 -337
  325. package/dist/node_modules/vscode-jsonrpc/lib/common/cancellation.js +0 -57
  326. package/dist/node_modules/vscode-jsonrpc/lib/common/connection.js +0 -647
  327. package/dist/node_modules/vscode-jsonrpc/lib/common/disposable.js +0 -13
  328. package/dist/node_modules/vscode-jsonrpc/lib/common/events.js +0 -64
  329. package/dist/node_modules/vscode-jsonrpc/lib/common/is.js +0 -34
  330. package/dist/node_modules/vscode-jsonrpc/lib/common/linkedMap.js +0 -235
  331. package/dist/node_modules/vscode-jsonrpc/lib/common/messageBuffer.js +0 -93
  332. package/dist/node_modules/vscode-jsonrpc/lib/common/messageReader.js +0 -129
  333. package/dist/node_modules/vscode-jsonrpc/lib/common/messageWriter.js +0 -85
  334. package/dist/node_modules/vscode-jsonrpc/lib/common/messages.js +0 -161
  335. package/dist/node_modules/vscode-jsonrpc/lib/common/ral.js +0 -18
  336. package/dist/node_modules/vscode-jsonrpc/lib/common/semaphore.js +0 -44
  337. package/dist/node_modules/vscode-jsonrpc/lib/common/sharedArrayCancellation.js +0 -58
  338. package/dist/node_modules/vscode-languageserver-protocol/lib/browser/main.js +0 -28
  339. package/dist/node_modules/vscode-languageserver-protocol/lib/common/api.js +0 -36
  340. package/dist/node_modules/vscode-languageserver-protocol/lib/common/connection.js +0 -12
  341. package/dist/node_modules/vscode-languageserver-protocol/lib/common/messages.js +0 -31
  342. package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.callHierarchy.js +0 -19
  343. package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.colorProvider.js +0 -15
  344. package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.configuration.js +0 -11
  345. package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.declaration.js +0 -11
  346. package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.diagnostic.js +0 -33
  347. package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.fileOperations.js +0 -35
  348. package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.foldingRange.js +0 -15
  349. package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.implementation.js +0 -11
  350. package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.inlayHint.js +0 -19
  351. package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.inlineCompletion.js +0 -11
  352. package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.inlineValue.js +0 -15
  353. package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.js +0 -674
  354. package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.linkedEditingRange.js +0 -11
  355. package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.moniker.js +0 -19
  356. package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.notebook.js +0 -126
  357. package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.progress.js +0 -24
  358. package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.selectionRange.js +0 -11
  359. package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.semanticTokens.js +0 -31
  360. package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.showDocument.js +0 -11
  361. package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.typeDefinition.js +0 -11
  362. package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.typeHierarchy.js +0 -19
  363. package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.workspaceFolder.js +0 -15
  364. package/dist/node_modules/vscode-languageserver-protocol/lib/common/utils/is.js +0 -42
  365. package/dist/node_modules/vscode-languageserver-textdocument/lib/esm/main.js +0 -138
  366. package/dist/node_modules/vscode-languageserver-types/lib/esm/main.js +0 -1084
  367. package/dist/node_modules/vscode-uri/lib/esm/index.js +0 -373
  368. /package/dist/node_modules/{entities → hast-util-raw/node_modules/entities}/dist/esm/decode-codepoint.js +0 -0
  369. /package/dist/node_modules/{entities → hast-util-raw/node_modules/entities}/dist/esm/decode.js +0 -0
  370. /package/dist/node_modules/{entities → hast-util-raw/node_modules/entities}/dist/esm/generated/decode-data-html.js +0 -0
  371. /package/dist/node_modules/{unified/node_modules/is-plain-obj → is-plain-obj}/index.js +0 -0
@@ -1,114 +0,0 @@
1
- import { toFastProperties } from "../../../../../@chevrotain/utils/lib/src/to-fast-properties.js";
2
- import { computeAllProdsFollows } from "../grammar/follow.js";
3
- import { EOF, createTokenInstance } from "../../scan/tokens_public.js";
4
- import { defaultGrammarValidatorErrorProvider, defaultParserErrorProvider } from "../errors_public.js";
5
- import { validateLookahead } from "../grammar/checks.js";
6
- import { resolveGrammar, validateGrammar } from "../grammar/gast/gast_resolver_public.js";
7
- import { Recoverable } from "./traits/recoverable.js";
8
- import { LooksAhead } from "./traits/looksahead.js";
9
- import { TreeBuilder } from "./traits/tree_builder.js";
10
- import { LexerAdapter } from "./traits/lexer_adapter.js";
11
- import { RecognizerApi } from "./traits/recognizer_api.js";
12
- import { RecognizerEngine } from "./traits/recognizer_engine.js";
13
- import { ErrorHandler } from "./traits/error_handler.js";
14
- import { GastRecorder } from "./traits/gast_recorder.js";
15
- import { PerformanceTracer } from "./traits/perf_tracer.js";
16
- import { applyMixins } from "./utils/apply_mixins.js";
17
- const END_OF_FILE = createTokenInstance(EOF, "", NaN, NaN, NaN, NaN, NaN, NaN);
18
- Object.freeze(END_OF_FILE);
19
- const DEFAULT_PARSER_CONFIG = Object.freeze({
20
- recoveryEnabled: !1,
21
- maxLookahead: 3,
22
- dynamicTokensEnabled: !1,
23
- outputCst: !0,
24
- errorMessageProvider: defaultParserErrorProvider,
25
- nodeLocationTracking: "none",
26
- traceInitPerf: !1,
27
- skipValidations: !1
28
- }), DEFAULT_RULE_CONFIG = Object.freeze({
29
- recoveryValueFunc: () => void 0,
30
- resyncEnabled: !0
31
- });
32
- var ParserDefinitionErrorType;
33
- (function(e) {
34
- 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";
35
- })(ParserDefinitionErrorType ||= {});
36
- function EMPTY_ALT(e = void 0) {
37
- return function() {
38
- return e;
39
- };
40
- }
41
- var Parser = class S {
42
- static performSelfAnalysis(e) {
43
- throw Error("The **static** `performSelfAnalysis` method has been deprecated. \nUse the **instance** method with the same name instead.");
44
- }
45
- performSelfAnalysis() {
46
- this.TRACE_INIT("performSelfAnalysis", () => {
47
- let C;
48
- this.selfAnalysisDone = !0;
49
- let w = this.className;
50
- this.TRACE_INIT("toFastProps", () => {
51
- toFastProperties(this);
52
- }), this.TRACE_INIT("Grammar Recording", () => {
53
- try {
54
- this.enableRecording(), this.definedRulesNames.forEach((e) => {
55
- let x = this[e].originalGrammarAction, S;
56
- this.TRACE_INIT(`${e} Rule`, () => {
57
- S = this.topLevelRuleRecord(e, x);
58
- }), this.gastProductionsCache[e] = S;
59
- });
60
- } finally {
61
- this.disableRecording();
62
- }
63
- });
64
- let T = [];
65
- if (this.TRACE_INIT("Grammar Resolving", () => {
66
- T = resolveGrammar({ rules: Object.values(this.gastProductionsCache) }), this.definitionErrors = this.definitionErrors.concat(T);
67
- }), this.TRACE_INIT("Grammar Validations", () => {
68
- if (T.length === 0 && this.skipValidations === !1) {
69
- let e = validateGrammar({
70
- rules: Object.values(this.gastProductionsCache),
71
- tokenTypes: Object.values(this.tokensMap),
72
- errMsgProvider: defaultGrammarValidatorErrorProvider,
73
- grammarName: w
74
- }), x = validateLookahead({
75
- lookaheadStrategy: this.lookaheadStrategy,
76
- rules: Object.values(this.gastProductionsCache),
77
- tokenTypes: Object.values(this.tokensMap),
78
- grammarName: w
79
- });
80
- this.definitionErrors = this.definitionErrors.concat(e, x);
81
- }
82
- }), this.definitionErrors.length === 0 && (this.recoveryEnabled && this.TRACE_INIT("computeAllProdsFollows", () => {
83
- this.resyncFollows = computeAllProdsFollows(Object.values(this.gastProductionsCache));
84
- }), this.TRACE_INIT("ComputeLookaheadFunctions", () => {
85
- var e, x;
86
- (x = (e = this.lookaheadStrategy).initialize) == null || x.call(e, { rules: Object.values(this.gastProductionsCache) }), this.preComputeLookaheadFunctions(Object.values(this.gastProductionsCache));
87
- })), !S.DEFER_DEFINITION_ERRORS_HANDLING && this.definitionErrors.length !== 0) throw C = this.definitionErrors.map((e) => e.message), Error(`Parser Definition Errors detected:\n ${C.join("\n-------------------------------\n")}`);
88
- });
89
- }
90
- constructor(e, x) {
91
- this.definitionErrors = [], this.selfAnalysisDone = !1;
92
- let S = this;
93
- if (S.initErrorHandler(x), S.initLexerAdapter(), S.initLooksAhead(x), S.initRecognizerEngine(e, x), S.initRecoverable(x), S.initTreeBuilder(x), S.initGastRecorder(x), S.initPerformanceTracer(x), Object.hasOwn(x, "ignoredIssues")) throw Error("The <ignoredIssues> IParserConfig property has been deprecated.\n Please use the <IGNORE_AMBIGUITIES> flag on the relevant DSL method instead.\n See: https://chevrotain.io/docs/guide/resolving_grammar_errors.html#IGNORING_AMBIGUITIES\n For further details.");
94
- this.skipValidations = Object.hasOwn(x, "skipValidations") ? x.skipValidations : DEFAULT_PARSER_CONFIG.skipValidations;
95
- }
96
- };
97
- Parser.DEFER_DEFINITION_ERRORS_HANDLING = !1, applyMixins(Parser, [
98
- Recoverable,
99
- LooksAhead,
100
- TreeBuilder,
101
- LexerAdapter,
102
- RecognizerEngine,
103
- RecognizerApi,
104
- ErrorHandler,
105
- GastRecorder,
106
- PerformanceTracer
107
- ]);
108
- var EmbeddedActionsParser = class extends Parser {
109
- constructor(e, x = DEFAULT_PARSER_CONFIG) {
110
- let S = Object.assign({}, x);
111
- S.outputCst = !1, super(e, S);
112
- }
113
- };
114
- export { DEFAULT_PARSER_CONFIG, DEFAULT_RULE_CONFIG, EMPTY_ALT, END_OF_FILE, EmbeddedActionsParser, ParserDefinitionErrorType };
@@ -1,46 +0,0 @@
1
- import { getLookaheadPathsForOptionalProd, getLookaheadPathsForOr } from "../../grammar/lookahead.js";
2
- import { EarlyExitException, NoViableAltException, isRecognitionException } from "../../exceptions_public.js";
3
- import { DEFAULT_PARSER_CONFIG } from "../parser.js";
4
- var ErrorHandler = class {
5
- initErrorHandler(e) {
6
- this._errors = [], this.errorMessageProvider = Object.hasOwn(e, "errorMessageProvider") ? e.errorMessageProvider : DEFAULT_PARSER_CONFIG.errorMessageProvider;
7
- }
8
- SAVE_ERROR(e) {
9
- if (isRecognitionException(e)) return e.context = {
10
- ruleStack: this.getHumanReadableRuleStack(),
11
- ruleOccurrenceStack: this.RULE_OCCURRENCE_STACK.slice(0, this.RULE_OCCURRENCE_STACK_IDX + 1)
12
- }, this._errors.push(e), e;
13
- throw Error("Trying to save an Error which is not a RecognitionException");
14
- }
15
- get errors() {
16
- return [...this._errors];
17
- }
18
- set errors(e) {
19
- this._errors = e;
20
- }
21
- raiseEarlyExitException(t, r, i) {
22
- let a = this.getCurrRuleFullName(), o = this.getGAstProductions()[a], s = getLookaheadPathsForOptionalProd(t, o, r, this.maxLookahead)[0], c = [];
23
- for (let e = 1; e <= this.maxLookahead; e++) c.push(this.LA(e));
24
- let l = this.errorMessageProvider.buildEarlyExitMessage({
25
- expectedIterationPaths: s,
26
- actual: c,
27
- previous: this.LA(0),
28
- customUserDescription: i,
29
- ruleName: a
30
- });
31
- throw this.SAVE_ERROR(new EarlyExitException(l, this.LA(1), this.LA(0)));
32
- }
33
- raiseNoAltException(e, n) {
34
- let i = this.getCurrRuleFullName(), a = this.getGAstProductions()[i], o = getLookaheadPathsForOr(e, a, this.maxLookahead), s = [];
35
- for (let e = 1; e <= this.maxLookahead; e++) s.push(this.LA(e));
36
- let c = this.LA(0), l = this.errorMessageProvider.buildNoViableAltMessage({
37
- expectedPathsPerAlt: o,
38
- actual: s,
39
- previous: c,
40
- customUserDescription: n,
41
- ruleName: this.getCurrRuleFullName()
42
- });
43
- throw this.SAVE_ERROR(new NoViableAltException(l, this.LA(1), c));
44
- }
45
- };
46
- export { ErrorHandler };
@@ -1,166 +0,0 @@
1
- import { Alternation, Alternative, NonTerminal, Option, Repetition, RepetitionMandatory, RepetitionMandatoryWithSeparator, RepetitionWithSeparator, Rule, Terminal } from "../../../../../../@chevrotain/gast/lib/src/model.js";
2
- import { augmentTokenTypes, hasShortKeyProperty } from "../../../scan/tokens.js";
3
- import { Lexer } from "../../../scan/lexer_public.js";
4
- import { createToken, createTokenInstance } from "../../../scan/tokens_public.js";
5
- import { BITS_FOR_OCCURRENCE_IDX } from "../../grammar/keys.js";
6
- import { END_OF_FILE } from "../parser.js";
7
- var RECORDING_NULL_OBJECT = { description: "This Object indicates the Parser is during Recording Phase" };
8
- Object.freeze(RECORDING_NULL_OBJECT);
9
- var HANDLE_SEPARATOR = !0, MAX_METHOD_IDX = 2 ** 8 - 1, RFT = createToken({
10
- name: "RECORDING_PHASE_TOKEN",
11
- pattern: Lexer.NA
12
- });
13
- augmentTokenTypes([RFT]);
14
- var RECORDING_PHASE_TOKEN = createTokenInstance(RFT, "This IToken indicates the Parser is in Recording Phase\n See: https://chevrotain.io/docs/guide/internals.html#grammar-recording for details", -1, -1, -1, -1, -1, -1);
15
- Object.freeze(RECORDING_PHASE_TOKEN);
16
- var RECORDING_PHASE_CSTNODE = {
17
- name: "This CSTNode indicates the Parser is in Recording Phase\n See: https://chevrotain.io/docs/guide/internals.html#grammar-recording for details",
18
- children: {}
19
- }, GastRecorder = class {
20
- initGastRecorder(e) {
21
- this.recordingProdStack = [], this.RECORDING_PHASE = !1;
22
- }
23
- enableRecording() {
24
- this.RECORDING_PHASE = !0, this.TRACE_INIT("Enable Recording", () => {
25
- for (let e = 0; e < 10; e++) {
26
- let x = e > 0 ? e : "";
27
- this[`CONSUME${x}`] = function(x, S) {
28
- return this.consumeInternalRecord(x, e, S);
29
- }, this[`SUBRULE${x}`] = function(x, S) {
30
- return this.subruleInternalRecord(x, e, S);
31
- }, this[`OPTION${x}`] = function(x) {
32
- return this.optionInternalRecord(x, e);
33
- }, this[`OR${x}`] = function(x) {
34
- return this.orInternalRecord(x, e);
35
- }, this[`MANY${x}`] = function(x) {
36
- this.manyInternalRecord(e, x);
37
- }, this[`MANY_SEP${x}`] = function(x) {
38
- this.manySepFirstInternalRecord(e, x);
39
- }, this[`AT_LEAST_ONE${x}`] = function(x) {
40
- this.atLeastOneInternalRecord(e, x);
41
- }, this[`AT_LEAST_ONE_SEP${x}`] = function(x) {
42
- this.atLeastOneSepFirstInternalRecord(e, x);
43
- };
44
- }
45
- this.consume = function(e, x, S) {
46
- return this.consumeInternalRecord(x, e, S);
47
- }, this.subrule = function(e, x, S) {
48
- return this.subruleInternalRecord(x, e, S);
49
- }, this.option = function(e, x) {
50
- return this.optionInternalRecord(x, e);
51
- }, this.or = function(e, x) {
52
- return this.orInternalRecord(x, e);
53
- }, this.many = function(e, x) {
54
- this.manyInternalRecord(e, x);
55
- }, this.atLeastOne = function(e, x) {
56
- this.atLeastOneInternalRecord(e, x);
57
- }, this.ACTION = this.ACTION_RECORD, this.BACKTRACK = this.BACKTRACK_RECORD, this.LA = this.LA_RECORD;
58
- });
59
- }
60
- disableRecording() {
61
- this.RECORDING_PHASE = !1, this.TRACE_INIT("Deleting Recording methods", () => {
62
- let e = this;
63
- for (let x = 0; x < 10; x++) {
64
- let S = x > 0 ? x : "";
65
- delete e[`CONSUME${S}`], delete e[`SUBRULE${S}`], delete e[`OPTION${S}`], delete e[`OR${S}`], delete e[`MANY${S}`], delete e[`MANY_SEP${S}`], delete e[`AT_LEAST_ONE${S}`], delete e[`AT_LEAST_ONE_SEP${S}`];
66
- }
67
- 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;
68
- });
69
- }
70
- ACTION_RECORD(e) {}
71
- BACKTRACK_RECORD(e, x) {
72
- return () => !0;
73
- }
74
- LA_RECORD(e) {
75
- return END_OF_FILE;
76
- }
77
- topLevelRuleRecord(e, x) {
78
- try {
79
- let S = new Rule({
80
- definition: [],
81
- name: e
82
- });
83
- return S.name = e, this.recordingProdStack.push(S), x.call(this), this.recordingProdStack.pop(), S;
84
- } catch (e) {
85
- if (e.KNOWN_RECORDER_ERROR !== !0) try {
86
- e.message += "\n This error was thrown during the \"grammar recording phase\" For more info see:\n https://chevrotain.io/docs/guide/internals.html#grammar-recording";
87
- } catch {
88
- throw e;
89
- }
90
- throw e;
91
- }
92
- }
93
- optionInternalRecord(e, x) {
94
- return recordProd.call(this, Option, e, x);
95
- }
96
- atLeastOneInternalRecord(e, x) {
97
- recordProd.call(this, RepetitionMandatory, x, e);
98
- }
99
- atLeastOneSepFirstInternalRecord(e, x) {
100
- recordProd.call(this, RepetitionMandatoryWithSeparator, x, e, HANDLE_SEPARATOR);
101
- }
102
- manyInternalRecord(e, x) {
103
- recordProd.call(this, Repetition, x, e);
104
- }
105
- manySepFirstInternalRecord(e, x) {
106
- recordProd.call(this, RepetitionWithSeparator, x, e, HANDLE_SEPARATOR);
107
- }
108
- orInternalRecord(e, x) {
109
- return recordOrProd.call(this, e, x);
110
- }
111
- subruleInternalRecord(e, x, C) {
112
- if (assertMethodIdxIsValid(x), !e || !Object.hasOwn(e, "ruleName")) {
113
- let S = /* @__PURE__ */ Error(`<SUBRULE${getIdxSuffix(x)}> argument is invalid expecting a Parser method reference but got: <${JSON.stringify(e)}>\n inside top level rule: <${this.recordingProdStack[0].name}>`);
114
- throw S.KNOWN_RECORDER_ERROR = !0, S;
115
- }
116
- let w = this.recordingProdStack.at(-1), T = e.ruleName, E = new NonTerminal({
117
- idx: x,
118
- nonTerminalName: T,
119
- label: C?.LABEL,
120
- referencedRule: void 0
121
- });
122
- return w.definition.push(E), this.outputCst ? RECORDING_PHASE_CSTNODE : RECORDING_NULL_OBJECT;
123
- }
124
- consumeInternalRecord(e, x, S) {
125
- if (assertMethodIdxIsValid(x), !hasShortKeyProperty(e)) {
126
- let S = /* @__PURE__ */ Error(`<CONSUME${getIdxSuffix(x)}> argument is invalid expecting a TokenType reference but got: <${JSON.stringify(e)}>\n inside top level rule: <${this.recordingProdStack[0].name}>`);
127
- throw S.KNOWN_RECORDER_ERROR = !0, S;
128
- }
129
- let C = this.recordingProdStack.at(-1), w = new Terminal({
130
- idx: x,
131
- terminalType: e,
132
- label: S?.LABEL
133
- });
134
- return C.definition.push(w), RECORDING_PHASE_TOKEN;
135
- }
136
- };
137
- function recordProd(e, x, S, C = !1) {
138
- assertMethodIdxIsValid(S);
139
- let w = this.recordingProdStack.at(-1), T = typeof x == "function" ? x : x.DEF, E = new e({
140
- definition: [],
141
- idx: S
142
- });
143
- return C && (E.separator = x.SEP), Object.hasOwn(x, "MAX_LOOKAHEAD") && (E.maxLookahead = x.MAX_LOOKAHEAD), this.recordingProdStack.push(E), T.call(this), w.definition.push(E), this.recordingProdStack.pop(), RECORDING_NULL_OBJECT;
144
- }
145
- function recordOrProd(S, C) {
146
- assertMethodIdxIsValid(C);
147
- let w = this.recordingProdStack.at(-1), T = Array.isArray(S) === !1, E = T === !1 ? S : S.DEF, D = new Alternation({
148
- definition: [],
149
- idx: C,
150
- ignoreAmbiguities: T && S.IGNORE_AMBIGUITIES === !0
151
- });
152
- return Object.hasOwn(S, "MAX_LOOKAHEAD") && (D.maxLookahead = S.MAX_LOOKAHEAD), D.hasPredicates = E.some((e) => typeof e.GATE == "function"), w.definition.push(D), E.forEach((e) => {
153
- let S = new Alternative({ definition: [] });
154
- D.definition.push(S), Object.hasOwn(e, "IGNORE_AMBIGUITIES") ? S.ignoreAmbiguities = e.IGNORE_AMBIGUITIES : Object.hasOwn(e, "GATE") && (S.ignoreAmbiguities = !0), this.recordingProdStack.push(S), e.ALT.call(this), this.recordingProdStack.pop();
155
- }), RECORDING_NULL_OBJECT;
156
- }
157
- function getIdxSuffix(e) {
158
- return e === 0 ? "" : `${e}`;
159
- }
160
- function assertMethodIdxIsValid(e) {
161
- if (e < 0 || e > MAX_METHOD_IDX) {
162
- let x = /* @__PURE__ */ Error(`Invalid DSL Method idx value: <${e}>\n\tIdx value must be a none negative value smaller than ${MAX_METHOD_IDX + 1}`);
163
- throw x.KNOWN_RECORDER_ERROR = !0, x;
164
- }
165
- }
166
- export { GastRecorder };
@@ -1,43 +0,0 @@
1
- import { END_OF_FILE } from "../parser.js";
2
- var LexerAdapter = class {
3
- initLexerAdapter() {
4
- this.tokVector = [], this.tokVectorLength = 0, this.currIdx = -1;
5
- }
6
- set input(e) {
7
- if (this.selfAnalysisDone !== !0) throw Error("Missing <performSelfAnalysis> invocation at the end of the Parser's constructor.");
8
- this.reset(), this.tokVector = e, this.tokVectorLength = e.length;
9
- }
10
- get input() {
11
- return this.tokVector;
12
- }
13
- SKIP_TOKEN() {
14
- return this.currIdx <= this.tokVectorLength - 2 ? (this.consumeToken(), this.LA_FAST(1)) : END_OF_FILE;
15
- }
16
- LA_FAST(e) {
17
- let t = this.currIdx + e;
18
- return this.tokVector[t];
19
- }
20
- LA(t) {
21
- let n = this.currIdx + t;
22
- return n < 0 || this.tokVectorLength <= n ? END_OF_FILE : this.tokVector[n];
23
- }
24
- consumeToken() {
25
- this.currIdx++;
26
- }
27
- exportLexerState() {
28
- return this.currIdx;
29
- }
30
- importLexerState(e) {
31
- this.currIdx = e;
32
- }
33
- resetLexerState() {
34
- this.currIdx = -1;
35
- }
36
- moveToTerminatedState() {
37
- this.currIdx = this.tokVectorLength - 1;
38
- }
39
- getLexerPosition() {
40
- return this.exportLexerState();
41
- }
42
- };
43
- export { LexerAdapter };
@@ -1,107 +0,0 @@
1
- import { GAstVisitor } from "../../../../../../@chevrotain/gast/lib/src/visitor.js";
2
- import { getProductionDslName } from "../../../../../../@chevrotain/gast/lib/src/helpers.js";
3
- import { AT_LEAST_ONE_IDX, AT_LEAST_ONE_SEP_IDX, MANY_IDX, MANY_SEP_IDX, OPTION_IDX, OR_IDX, getKeyForAutomaticLookahead } from "../../grammar/keys.js";
4
- import { LLkLookaheadStrategy } from "../../grammar/llk_lookahead.js";
5
- import { DEFAULT_PARSER_CONFIG } from "../parser.js";
6
- var LooksAhead = class {
7
- initLooksAhead(e) {
8
- this.dynamicTokensEnabled = Object.hasOwn(e, "dynamicTokensEnabled") ? e.dynamicTokensEnabled : DEFAULT_PARSER_CONFIG.dynamicTokensEnabled, this.maxLookahead = Object.hasOwn(e, "maxLookahead") ? e.maxLookahead : DEFAULT_PARSER_CONFIG.maxLookahead, this.lookaheadStrategy = Object.hasOwn(e, "lookaheadStrategy") ? e.lookaheadStrategy : new LLkLookaheadStrategy({ maxLookahead: this.maxLookahead }), this.lookAheadFuncsCache = /* @__PURE__ */ new Map();
9
- }
10
- preComputeLookaheadFunctions(e) {
11
- e.forEach((e) => {
12
- this.TRACE_INIT(`${e.name} Rule Lookahead`, () => {
13
- let { alternation: s, repetition: l, option: u, repetitionMandatory: d, repetitionMandatoryWithSeparator: f, repetitionWithSeparator: p } = collectMethods(e);
14
- s.forEach((a) => {
15
- let o = a.idx === 0 ? "" : a.idx;
16
- this.TRACE_INIT(`${getProductionDslName(a)}${o}`, () => {
17
- let i = this.lookaheadStrategy.buildLookaheadForAlternation({
18
- prodOccurrence: a.idx,
19
- rule: e,
20
- maxLookahead: a.maxLookahead || this.maxLookahead,
21
- hasPredicates: a.hasPredicates,
22
- dynamicTokensEnabled: this.dynamicTokensEnabled
23
- }), o = getKeyForAutomaticLookahead(this.fullRuleNameToShort[e.name], 256, a.idx);
24
- this.setLaFuncCache(o, i);
25
- });
26
- }), l.forEach((a) => {
27
- this.computeLookaheadFunc(e, a.idx, 768, "Repetition", a.maxLookahead, getProductionDslName(a));
28
- }), u.forEach((a) => {
29
- this.computeLookaheadFunc(e, a.idx, 512, "Option", a.maxLookahead, getProductionDslName(a));
30
- }), d.forEach((o) => {
31
- this.computeLookaheadFunc(e, o.idx, AT_LEAST_ONE_IDX, "RepetitionMandatory", o.maxLookahead, getProductionDslName(o));
32
- }), f.forEach((a) => {
33
- this.computeLookaheadFunc(e, a.idx, AT_LEAST_ONE_SEP_IDX, "RepetitionMandatoryWithSeparator", a.maxLookahead, getProductionDslName(a));
34
- }), p.forEach((a) => {
35
- this.computeLookaheadFunc(e, a.idx, MANY_SEP_IDX, "RepetitionWithSeparator", a.maxLookahead, getProductionDslName(a));
36
- });
37
- });
38
- });
39
- }
40
- computeLookaheadFunc(e, i, a, o, s, c) {
41
- this.TRACE_INIT(`${c}${i === 0 ? "" : i}`, () => {
42
- let c = this.lookaheadStrategy.buildLookaheadForOptional({
43
- prodOccurrence: i,
44
- rule: e,
45
- maxLookahead: s || this.maxLookahead,
46
- dynamicTokensEnabled: this.dynamicTokensEnabled,
47
- prodType: o
48
- }), l = getKeyForAutomaticLookahead(this.fullRuleNameToShort[e.name], a, i);
49
- this.setLaFuncCache(l, c);
50
- });
51
- }
52
- getKeyForAutomaticLookahead(e, i) {
53
- return getKeyForAutomaticLookahead(this.currRuleShortName, e, i);
54
- }
55
- getLaFuncFromCache(e) {
56
- return this.lookAheadFuncsCache.get(e);
57
- }
58
- /* istanbul ignore next */
59
- setLaFuncCache(e, i) {
60
- this.lookAheadFuncsCache.set(e, i);
61
- }
62
- }, collectorVisitor = new class extends GAstVisitor {
63
- constructor() {
64
- super(...arguments), this.dslMethods = {
65
- option: [],
66
- alternation: [],
67
- repetition: [],
68
- repetitionWithSeparator: [],
69
- repetitionMandatory: [],
70
- repetitionMandatoryWithSeparator: []
71
- };
72
- }
73
- reset() {
74
- this.dslMethods = {
75
- option: [],
76
- alternation: [],
77
- repetition: [],
78
- repetitionWithSeparator: [],
79
- repetitionMandatory: [],
80
- repetitionMandatoryWithSeparator: []
81
- };
82
- }
83
- visitOption(e) {
84
- this.dslMethods.option.push(e);
85
- }
86
- visitRepetitionWithSeparator(e) {
87
- this.dslMethods.repetitionWithSeparator.push(e);
88
- }
89
- visitRepetitionMandatory(e) {
90
- this.dslMethods.repetitionMandatory.push(e);
91
- }
92
- visitRepetitionMandatoryWithSeparator(e) {
93
- this.dslMethods.repetitionMandatoryWithSeparator.push(e);
94
- }
95
- visitRepetition(e) {
96
- this.dslMethods.repetition.push(e);
97
- }
98
- visitAlternation(e) {
99
- this.dslMethods.alternation.push(e);
100
- }
101
- }();
102
- function collectMethods(e) {
103
- collectorVisitor.reset(), e.accept(collectorVisitor);
104
- let i = collectorVisitor.dslMethods;
105
- return collectorVisitor.reset(), i;
106
- }
107
- export { LooksAhead };
@@ -1,21 +0,0 @@
1
- import { timer } from "../../../../../../@chevrotain/utils/lib/src/timer.js";
2
- import { DEFAULT_PARSER_CONFIG } from "../parser.js";
3
- var PerformanceTracer = class {
4
- initPerformanceTracer(e) {
5
- if (Object.hasOwn(e, "traceInitPerf")) {
6
- let t = e.traceInitPerf, n = typeof t == "number";
7
- this.traceInitMaxIdent = n ? t : Infinity, this.traceInitPerf = n ? t > 0 : t;
8
- } else this.traceInitMaxIdent = 0, this.traceInitPerf = DEFAULT_PARSER_CONFIG.traceInitPerf;
9
- this.traceInitIndent = -1;
10
- }
11
- TRACE_INIT(t, n) {
12
- if (this.traceInitPerf === !0) {
13
- this.traceInitIndent++;
14
- let r = Array(this.traceInitIndent + 1).join(" ");
15
- this.traceInitIndent < this.traceInitMaxIdent && console.log(`${r}--> <${t}>`);
16
- let { time: i, value: a } = timer(n), o = i > 10 ? console.warn : console.log;
17
- return this.traceInitIndent < this.traceInitMaxIdent && o(`${r}<-- <${t}> time: ${i}ms`), this.traceInitIndent--, a;
18
- } else return n();
19
- }
20
- };
21
- export { PerformanceTracer };