@loopstack/loopstack-studio 0.28.0 → 0.29.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/_virtual/rolldown_runtime.js +13 -15
- package/dist/api/config.js +2 -2
- package/dist/components/dynamic-form/Form.js +49 -52
- package/dist/config.js +6 -0
- package/dist/features/debug/components/WorkflowFlowViewer.js +94 -81
- package/dist/features/debug/components/workflow-flow/StateNode.js +154 -79
- package/dist/features/debug/components/workflow-flow/WorkflowGraph.js +43 -31
- package/dist/features/debug/components/workflow-flow/WorkflowTransitionEdge.js +52 -51
- package/dist/features/debug/lib/edge-paths.js +45 -30
- package/dist/features/debug/lib/flow-types.js +2 -0
- package/dist/features/debug/lib/flow-utils.js +66 -64
- package/dist/features/documents/components/DocumentList.js +19 -18
- package/dist/features/workbench/WorkflowItem.js +4 -3
- package/dist/features/workbench/components/EmbedLogsContent.js +5 -0
- package/dist/features/workbench/components/NewRunDialog.js +2 -2
- package/dist/features/workbench/components/PreviewEmptyState.js +10 -0
- package/dist/features/workbench/components/PreviewWorkbench.js +14 -0
- package/dist/features/workbench/components/RecentRunItem.js +48 -0
- package/dist/features/workbench/components/WorkflowForms.js +4 -3
- package/dist/features/workbench/hooks/useEmbedBridge.js +3 -0
- package/dist/features/workbench/hooks/useWorkflowData.js +9 -9
- package/dist/features/workbench/index.js +4 -0
- package/dist/features/workspaces/Workspaces.js +2 -2
- package/dist/features/workspaces/components/ExecutionTimeline.js +9 -8
- package/dist/hooks/index.js +2 -2
- package/dist/hooks/query-keys.js +3 -3
- package/dist/hooks/useConfig.js +15 -15
- package/dist/index.d.ts +12 -12
- package/dist/index.js +3 -3
- package/dist/loopstack-studio.css +1 -1
- package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/{architecture-YZFGNWBL.js → architecture-7EHR7CIX.js} +2 -2
- package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/{chunk-7N4EOEYR.js → chunk-4EGX6M5U.js} +9 -13
- package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/{chunk-KGLVRYIC.js → chunk-5DO6E6H7.js} +3 -7
- package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/chunk-BR22UD5L.js +56 -0
- package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/{chunk-2KRD3SAO.js → chunk-FHYWG6QK.js} +3 -7
- package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/{chunk-FOC6F5B3.js → chunk-MPE355IW.js} +3 -7
- package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/chunk-MZUSXYTE.js +24 -0
- package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/chunk-N66VUXT2.js +48 -0
- package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/chunk-NNHCCRGN.js +20219 -0
- package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/chunk-PUPMXCY4.js +19 -0
- package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/{chunk-67CJDMHE.js → chunk-UIBZB4QT.js} +3 -7
- package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/chunk-WCWK7LTN.js +25 -0
- package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/eventmodeling-FCH6USID.js +3 -0
- package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/{gitGraph-7Q5UKJZL.js → gitGraph-WXDBUCRP.js} +2 -2
- package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/info-J43DQDTF.js +3 -0
- package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/packet-YPE3B663.js +3 -0
- package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/pie-LRSECV5Y.js +3 -0
- package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/radar-GUYGQ44K.js +3 -0
- package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/{treeView-SZITEDCU.js → treeView-BLDUP644.js} +2 -2
- package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/treemap-LRROVOQU.js +3 -0
- package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/wardley-L42UT6IY.js +3 -0
- package/dist/node_modules/@mermaid-js/parser/dist/mermaid-parser.core.js +24 -19
- package/dist/node_modules/@ungap/structured-clone/esm/deserialize.js +36 -26
- package/dist/node_modules/@xyflow/react/dist/esm/index.js +1 -1
- package/dist/node_modules/cytoscape/dist/cytoscape.esm.js +257 -254
- package/dist/node_modules/dagre-d3-es/src/dagre/greedy-fas.js +19 -19
- package/dist/node_modules/dagre-d3-es/src/dagre/layout.js +48 -48
- package/dist/node_modules/dagre-d3-es/src/dagre/nesting-graph.js +9 -9
- package/dist/node_modules/dagre-d3-es/src/dagre/order/cross-count.js +3 -3
- package/dist/node_modules/dagre-d3-es/src/dagre/order/index.js +11 -11
- package/dist/node_modules/dagre-d3-es/src/dagre/order/init-order.js +4 -4
- package/dist/node_modules/dagre-d3-es/src/dagre/order/resolve-conflicts.js +4 -4
- package/dist/node_modules/dagre-d3-es/src/dagre/order/sort-subgraph.js +8 -8
- package/dist/node_modules/dagre-d3-es/src/dagre/order/sort.js +5 -5
- package/dist/node_modules/dagre-d3-es/src/dagre/position/bk.js +72 -72
- package/dist/node_modules/dagre-d3-es/src/dagre/position/index.js +1 -1
- package/dist/node_modules/dagre-d3-es/src/dagre/rank/network-simplex.js +25 -25
- package/dist/node_modules/dagre-d3-es/src/dagre/rank/util.js +8 -8
- package/dist/node_modules/dagre-d3-es/src/dagre/util.js +48 -48
- package/dist/node_modules/dagre-d3-es/src/graphlib/graph.js +109 -109
- package/dist/node_modules/dagre-d3-es/src/graphlib/json.js +17 -17
- package/dist/node_modules/dompurify/dist/purify.es.js +293 -205
- package/dist/node_modules/es-toolkit/dist/_internal/globalThis.js +4 -0
- package/dist/node_modules/es-toolkit/dist/_internal/isUnsafeProperty.js +4 -0
- package/dist/node_modules/es-toolkit/dist/compat/_internal/getSymbols.js +4 -0
- package/dist/node_modules/es-toolkit/dist/compat/_internal/getTag.js +4 -0
- package/dist/node_modules/es-toolkit/dist/compat/_internal/isPrototype.js +5 -0
- package/dist/node_modules/es-toolkit/dist/compat/_internal/tags.js +2 -0
- package/dist/node_modules/es-toolkit/dist/compat/function/memoize.js +12 -0
- package/dist/node_modules/es-toolkit/dist/compat/object/clone.js +97 -0
- package/dist/node_modules/es-toolkit/dist/compat/object/cloneDeep.js +5 -0
- package/dist/node_modules/es-toolkit/dist/compat/object/cloneDeepWith.js +29 -0
- package/dist/node_modules/es-toolkit/dist/compat/object/merge.js +6 -0
- package/dist/node_modules/es-toolkit/dist/compat/object/mergeWith.js +49 -0
- package/dist/node_modules/es-toolkit/dist/compat/predicate/isArguments.js +5 -0
- package/dist/node_modules/es-toolkit/dist/compat/predicate/isArray.js +4 -0
- package/dist/node_modules/es-toolkit/dist/compat/predicate/isArrayLike.js +5 -0
- package/dist/node_modules/es-toolkit/dist/compat/predicate/isArrayLikeObject.js +6 -0
- package/dist/node_modules/es-toolkit/dist/compat/predicate/isEmpty.js +16 -0
- package/dist/node_modules/es-toolkit/dist/compat/predicate/isObjectLike.js +4 -0
- package/dist/node_modules/es-toolkit/dist/compat/predicate/isPlainObject.js +12 -0
- package/dist/node_modules/es-toolkit/dist/compat/predicate/isTypedArray.js +5 -0
- package/dist/node_modules/es-toolkit/dist/function/noop.js +2 -0
- package/dist/node_modules/es-toolkit/dist/object/clone.js +29 -0
- package/dist/node_modules/es-toolkit/dist/object/cloneDeepWith.js +114 -0
- package/dist/node_modules/es-toolkit/dist/predicate/isBuffer.js +5 -0
- package/dist/node_modules/es-toolkit/dist/predicate/isLength.js +4 -0
- package/dist/node_modules/es-toolkit/dist/predicate/isPrimitive.js +4 -0
- package/dist/node_modules/es-toolkit/dist/predicate/isTypedArray.js +4 -0
- package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/tokenizer/index.js +2 -2
- package/dist/node_modules/internmap/src/index.js +1 -1
- package/dist/node_modules/katex/dist/katex.js +379 -417
- package/dist/node_modules/lodash-es/_arrayLikeKeys.js +3 -3
- package/dist/node_modules/lodash-es/_assignMergeValue.js +1 -1
- package/dist/node_modules/lodash-es/_assignValue.js +1 -1
- package/dist/node_modules/lodash-es/_baseClone.js +9 -9
- package/dist/node_modules/lodash-es/_baseForOwn.js +1 -1
- package/dist/node_modules/lodash-es/_baseIsEqualDeep.js +1 -1
- package/dist/node_modules/lodash-es/_baseMatchesProperty.js +6 -6
- package/dist/node_modules/lodash-es/_baseMerge.js +2 -2
- package/dist/node_modules/lodash-es/_baseMergeDeep.js +7 -7
- package/dist/node_modules/lodash-es/_baseOrderBy.js +12 -12
- package/dist/node_modules/lodash-es/_baseRest.js +1 -1
- package/dist/node_modules/lodash-es/_baseSet.js +1 -1
- package/dist/node_modules/lodash-es/_baseSetToString.js +3 -3
- package/dist/node_modules/lodash-es/_baseToString.js +2 -2
- package/dist/node_modules/lodash-es/_baseUniq.js +1 -1
- package/dist/node_modules/lodash-es/_createRange.js +1 -1
- package/dist/node_modules/lodash-es/_createSet.js +3 -3
- package/dist/node_modules/lodash-es/_flatRest.js +1 -1
- package/dist/node_modules/lodash-es/_getAllKeys.js +2 -2
- package/dist/node_modules/lodash-es/_getAllKeysIn.js +1 -1
- package/dist/node_modules/lodash-es/_getSymbolsIn.js +1 -1
- package/dist/node_modules/lodash-es/_getTag.js +1 -1
- package/dist/node_modules/lodash-es/_hasPath.js +2 -2
- package/dist/node_modules/lodash-es/_initCloneByTag.js +1 -1
- package/dist/node_modules/lodash-es/_initCloneObject.js +1 -1
- package/dist/node_modules/lodash-es/_isFlattenable.js +1 -1
- package/dist/node_modules/lodash-es/_isIterateeCall.js +1 -1
- package/dist/node_modules/lodash-es/_isKey.js +1 -1
- package/dist/node_modules/lodash-es/_setToString.js +1 -1
- package/dist/node_modules/lodash-es/defaults.js +1 -1
- package/dist/node_modules/lodash-es/findIndex.js +2 -2
- package/dist/node_modules/lodash-es/forEach.js +1 -1
- package/dist/node_modules/lodash-es/forIn.js +1 -1
- package/dist/node_modules/lodash-es/isEmpty.js +2 -2
- package/dist/node_modules/lodash-es/isPlainObject.js +1 -1
- package/dist/node_modules/lodash-es/map.js +1 -1
- package/dist/node_modules/lodash-es/max.js +1 -1
- package/dist/node_modules/lodash-es/merge.js +3 -3
- package/dist/node_modules/lodash-es/min.js +1 -1
- package/dist/node_modules/lodash-es/minBy.js +1 -1
- package/dist/node_modules/lodash-es/reduce.js +1 -1
- package/dist/node_modules/lodash-es/toNumber.js +1 -1
- package/dist/node_modules/lodash-es/union.js +3 -3
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{architectureDiagram-Q4EWVU46.js → architectureDiagram-3BPJPVTR.js} +310 -308
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{blockDiagram-DXYQGD6D.js → blockDiagram-GPEHLZMM.js} +215 -190
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{c4Diagram-AHTNJAMY.js → c4Diagram-AAUBKEIU.js} +3 -3
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{chunk-EDXVE4YY.js → chunk-2J33WTMH.js} +1 -1
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{chunk-5FUZZQ4R.js → chunk-3OPIFGDE.js} +48 -20
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{chunk-5PVQY5BW.js → chunk-5ZQYHXKU.js} +8 -8
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{chunk-4TB4RGXK.js → chunk-727SXJPM.js} +555 -459
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{chunk-OYMX7WX6.js → chunk-AQP2D5EJ.js} +155 -145
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{chunk-ICPOFSXX.js → chunk-CSCIHK7Q.js} +106 -12
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{chunk-ENJZ2VHE.js → chunk-KSCS5N6A.js} +12 -12
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{chunk-ZZ45TVLE.js → chunk-L5ZTLDWV.js} +2 -2
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{chunk-336JU56O.js → chunk-LZXEDZCA.js} +5 -5
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{chunk-YZCP3GAM.js → chunk-ND2GUHAM.js} +1 -1
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{chunk-X2U36JSP.js → chunk-NZK2D7GU.js} +1 -1
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{chunk-U2HBQHQK.js → chunk-O5CBEL6O.js} +2 -2
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{chunk-426QAEUC.js → chunk-WU5MYG2G.js} +1 -1
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{classDiagram-6PBFFD2Q.js → classDiagram-4FO5ZUOK.js} +11 -11
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{classDiagram-v2-HSJHXN6E.js → classDiagram-v2-Q7XG4LA2.js} +11 -11
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{dagre-KV5264BT.js → dagre-BM42HDAG.js} +8 -8
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{diagram-MMDJMWI5.js → diagram-2AECGRRQ.js} +3 -3
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{diagram-5BDNPKRD.js → diagram-5GNKFQAL.js} +3 -3
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/diagram-KO2AKTUF.js +433 -0
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{diagram-TYMM5635.js → diagram-LMA3HP47.js} +3 -3
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{diagram-G4DWMVQ6.js → diagram-OG6HWLK6.js} +5 -5
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{erDiagram-SMLLAGMA.js → erDiagram-TEJ5UH35.js} +9 -9
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{flowDiagram-DWJPFMVM.js → flowDiagram-I6XJVG4X.js} +10 -10
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{ganttDiagram-T4ZO3ILL.js → ganttDiagram-6RSMTGT7.js} +7 -4
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{gitGraphDiagram-UUTBAWPF.js → gitGraphDiagram-PVQCEYII.js} +2 -2
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{infoDiagram-42DDH7IO.js → infoDiagram-5YYISTIA.js} +3 -3
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{ishikawaDiagram-UXIWVN3A.js → ishikawaDiagram-YF4QCWOH.js} +3 -3
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{journeyDiagram-VCZTEJTY.js → journeyDiagram-JHISSGLW.js} +2 -2
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{kanban-definition-6JOO6SKY.js → kanban-definition-UN3LZRKU.js} +7 -7
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{mindmap-definition-QFDTVHPH.js → mindmap-definition-RKZ34NQL.js} +9 -9
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{pieDiagram-DEJITSTG.js → pieDiagram-4H26LBE5.js} +3 -3
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{quadrantDiagram-34T5L4WZ.js → quadrantDiagram-W4KKPZXB.js} +364 -337
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{requirementDiagram-MS252O5E.js → requirementDiagram-4Y6WPE33.js} +9 -9
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{sankeyDiagram-XADWPNL6.js → sankeyDiagram-5OEKKPKP.js} +187 -138
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{sequenceDiagram-FGHM5R23.js → sequenceDiagram-3UESZ5HK.js} +15 -8
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{stateDiagram-FHFEXIEX.js → stateDiagram-AJRCARHV.js} +10 -10
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{stateDiagram-v2-QKLJ7IA2.js → stateDiagram-v2-BHNVJYJU.js} +10 -10
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{timeline-definition-GMOUNBTQ.js → timeline-definition-PNZ67QCA.js} +3 -3
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{vennDiagram-DHZGUBPP.js → vennDiagram-CIIHVFJN.js} +3 -3
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/wardleyDiagram-YWT4CUSO.js +640 -0
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{xychartDiagram-5P7HB3ND.js → xychartDiagram-2RQKCTM6.js} +4 -4
- package/dist/node_modules/mermaid/dist/mermaid.core.js +96 -70
- package/dist/node_modules/stylis/src/Enum.js +2 -2
- package/dist/node_modules/stylis/src/Middleware.js +9 -0
- package/dist/node_modules/stylis/src/Parser.js +55 -44
- package/dist/node_modules/stylis/src/Utility.js +9 -12
- package/dist/node_modules/unified/lib/index.js +1 -1
- package/dist/packages/contracts/dist/enums/index.js +4 -24
- package/dist/packages/contracts/dist/enums/registry.enum.js +9 -20
- package/dist/packages/contracts/dist/enums/sort-order.enum.js +5 -10
- package/dist/packages/contracts/dist/enums/user-type.enum.js +5 -10
- package/dist/packages/contracts/dist/enums/workflow-state.enum.js +5 -10
- package/dist/pages/DebugWorkflowDetailsPage.js +2 -2
- package/dist/pages/DebugWorkflowsPage.js +12 -12
- package/dist/pages/EmbedWorkbenchPage.js +4 -3
- package/dist/pages/PreviewWorkbenchPage.js +126 -124
- package/dist/pages/StudioLandingPage.js +28 -72
- package/dist/pages/WorkspacePage.js +2 -2
- package/package.json +2 -2
- package/dist/node_modules/@chevrotain/gast/lib/src/helpers.js +0 -23
- package/dist/node_modules/@chevrotain/gast/lib/src/model.js +0 -151
- package/dist/node_modules/@chevrotain/gast/lib/src/visitor.js +0 -40
- package/dist/node_modules/@chevrotain/regexp-to-ast/lib/src/api.js +0 -2
- package/dist/node_modules/@chevrotain/regexp-to-ast/lib/src/base-regexp-visitor.js +0 -85
- package/dist/node_modules/@chevrotain/regexp-to-ast/lib/src/character-classes.js +0 -35
- package/dist/node_modules/@chevrotain/regexp-to-ast/lib/src/regexp-parser.js +0 -570
- package/dist/node_modules/@chevrotain/regexp-to-ast/lib/src/utils.js +0 -25
- package/dist/node_modules/@chevrotain/utils/lib/src/print.js +0 -9
- package/dist/node_modules/@chevrotain/utils/lib/src/timer.js +0 -8
- package/dist/node_modules/@chevrotain/utils/lib/src/to-fast-properties.js +0 -10
- package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/chunk-AA7GKIK3.js +0 -28
- package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/chunk-CIAEETIT.js +0 -23
- package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/chunk-K5T4RW27.js +0 -1197
- package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/chunk-LIHQZDEY.js +0 -60
- package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/chunk-ORNJ4GCN.js +0 -29
- package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/info-OMHHGYJF.js +0 -3
- package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/packet-4T2RLAQJ.js +0 -3
- package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/pie-ZZUOXDRM.js +0 -3
- package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/radar-PYXPWWZC.js +0 -3
- package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/treemap-W4RFUUIX.js +0 -3
- package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/wardley-RL74JXVD.js +0 -3
- package/dist/node_modules/chevrotain/lib/src/api.js +0 -10
- package/dist/node_modules/chevrotain/lib/src/lang/lang_extensions.js +0 -10
- package/dist/node_modules/chevrotain/lib/src/parse/constants.js +0 -2
- package/dist/node_modules/chevrotain/lib/src/parse/cst/cst.js +0 -13
- package/dist/node_modules/chevrotain/lib/src/parse/cst/cst_visitor.js +0 -49
- package/dist/node_modules/chevrotain/lib/src/parse/errors_public.js +0 -77
- package/dist/node_modules/chevrotain/lib/src/parse/exceptions_public.js +0 -33
- package/dist/node_modules/chevrotain/lib/src/parse/grammar/checks.js +0 -275
- package/dist/node_modules/chevrotain/lib/src/parse/grammar/first.js +0 -23
- package/dist/node_modules/chevrotain/lib/src/parse/grammar/follow.js +0 -28
- package/dist/node_modules/chevrotain/lib/src/parse/grammar/gast/gast_resolver_public.js +0 -14
- package/dist/node_modules/chevrotain/lib/src/parse/grammar/interpreter.js +0 -262
- package/dist/node_modules/chevrotain/lib/src/parse/grammar/keys.js +0 -5
- package/dist/node_modules/chevrotain/lib/src/parse/grammar/llk_lookahead.js +0 -41
- package/dist/node_modules/chevrotain/lib/src/parse/grammar/lookahead.js +0 -241
- package/dist/node_modules/chevrotain/lib/src/parse/grammar/resolver.js +0 -30
- package/dist/node_modules/chevrotain/lib/src/parse/grammar/rest.js +0 -56
- package/dist/node_modules/chevrotain/lib/src/parse/parser/parser.js +0 -114
- package/dist/node_modules/chevrotain/lib/src/parse/parser/traits/error_handler.js +0 -46
- package/dist/node_modules/chevrotain/lib/src/parse/parser/traits/gast_recorder.js +0 -166
- package/dist/node_modules/chevrotain/lib/src/parse/parser/traits/lexer_adapter.js +0 -43
- package/dist/node_modules/chevrotain/lib/src/parse/parser/traits/looksahead.js +0 -107
- package/dist/node_modules/chevrotain/lib/src/parse/parser/traits/perf_tracer.js +0 -21
- package/dist/node_modules/chevrotain/lib/src/parse/parser/traits/recognizer_api.js +0 -312
- package/dist/node_modules/chevrotain/lib/src/parse/parser/traits/recognizer_engine.js +0 -285
- package/dist/node_modules/chevrotain/lib/src/parse/parser/traits/recoverable.js +0 -144
- package/dist/node_modules/chevrotain/lib/src/parse/parser/traits/tree_builder.js +0 -92
- package/dist/node_modules/chevrotain/lib/src/parse/parser/utils/apply_mixins.js +0 -11
- package/dist/node_modules/chevrotain/lib/src/scan/lexer.js +0 -437
- package/dist/node_modules/chevrotain/lib/src/scan/lexer_errors_public.js +0 -9
- package/dist/node_modules/chevrotain/lib/src/scan/lexer_public.js +0 -253
- package/dist/node_modules/chevrotain/lib/src/scan/reg_exp.js +0 -152
- package/dist/node_modules/chevrotain/lib/src/scan/reg_exp_parser.js +0 -15
- package/dist/node_modules/chevrotain/lib/src/scan/tokens.js +0 -65
- package/dist/node_modules/chevrotain/lib/src/scan/tokens_public.js +0 -39
- package/dist/node_modules/chevrotain-allstar/lib/all-star-lookahead.js +0 -346
- package/dist/node_modules/chevrotain-allstar/lib/atn.js +0 -194
- package/dist/node_modules/chevrotain-allstar/lib/dfa.js +0 -32
- package/dist/node_modules/chevrotain-allstar/lib/index.js +0 -1
- package/dist/node_modules/langium/lib/default-module.js +0 -85
- package/dist/node_modules/langium/lib/dependency-injection.js +0 -62
- package/dist/node_modules/langium/lib/documentation/comment-provider.js +0 -11
- package/dist/node_modules/langium/lib/documentation/documentation-provider.js +0 -36
- package/dist/node_modules/langium/lib/documentation/jsdoc.js +0 -303
- package/dist/node_modules/langium/lib/index.js +0 -182
- package/dist/node_modules/langium/lib/languages/generated/ast.js +0 -1089
- package/dist/node_modules/langium/lib/languages/grammar-config.js +0 -13
- package/dist/node_modules/langium/lib/parser/async-parser.js +0 -83
- package/dist/node_modules/langium/lib/parser/completion-parser-builder.js +0 -7
- package/dist/node_modules/langium/lib/parser/cst-node-builder.js +0 -160
- package/dist/node_modules/langium/lib/parser/indentation-aware.js +0 -141
- package/dist/node_modules/langium/lib/parser/langium-parser-builder.js +0 -11
- package/dist/node_modules/langium/lib/parser/langium-parser.js +0 -388
- package/dist/node_modules/langium/lib/parser/lexer.js +0 -50
- package/dist/node_modules/langium/lib/parser/parser-builder-base.js +0 -275
- package/dist/node_modules/langium/lib/parser/token-builder.js +0 -61
- package/dist/node_modules/langium/lib/parser/value-converter.js +0 -78
- package/dist/node_modules/langium/lib/references/linker.js +0 -190
- package/dist/node_modules/langium/lib/references/name-provider.js +0 -13
- package/dist/node_modules/langium/lib/references/references.js +0 -76
- package/dist/node_modules/langium/lib/references/scope-computation.js +0 -35
- package/dist/node_modules/langium/lib/references/scope-provider.js +0 -34
- package/dist/node_modules/langium/lib/references/scope.js +0 -73
- package/dist/node_modules/langium/lib/serializer/hydrator.js +0 -125
- package/dist/node_modules/langium/lib/serializer/json-serializer.js +0 -145
- package/dist/node_modules/langium/lib/service-registry.js +0 -37
- package/dist/node_modules/langium/lib/syntax-tree.js +0 -70
- package/dist/node_modules/langium/lib/utils/ast-utils.js +0 -157
- package/dist/node_modules/langium/lib/utils/caching.js +0 -91
- package/dist/node_modules/langium/lib/utils/cancellation.js +0 -5
- package/dist/node_modules/langium/lib/utils/collections.js +0 -85
- package/dist/node_modules/langium/lib/utils/cst-utils.js +0 -190
- package/dist/node_modules/langium/lib/utils/disposable.js +0 -8
- package/dist/node_modules/langium/lib/utils/errors.js +0 -12
- package/dist/node_modules/langium/lib/utils/event.js +0 -5
- package/dist/node_modules/langium/lib/utils/grammar-loader.js +0 -22
- package/dist/node_modules/langium/lib/utils/grammar-utils.js +0 -296
- package/dist/node_modules/langium/lib/utils/index.js +0 -53
- package/dist/node_modules/langium/lib/utils/promise-utils.js +0 -30
- package/dist/node_modules/langium/lib/utils/regexp-utils.js +0 -167
- package/dist/node_modules/langium/lib/utils/stream.js +0 -327
- package/dist/node_modules/langium/lib/utils/uri-utils.js +0 -107
- package/dist/node_modules/langium/lib/validation/document-validator.js +0 -210
- package/dist/node_modules/langium/lib/validation/validation-registry.js +0 -87
- package/dist/node_modules/langium/lib/workspace/ast-descriptions.js +0 -57
- package/dist/node_modules/langium/lib/workspace/ast-node-locator.js +0 -28
- package/dist/node_modules/langium/lib/workspace/configuration.js +0 -51
- package/dist/node_modules/langium/lib/workspace/document-builder.js +0 -201
- package/dist/node_modules/langium/lib/workspace/documents.js +0 -142
- package/dist/node_modules/langium/lib/workspace/file-system-provider.js +0 -34
- package/dist/node_modules/langium/lib/workspace/index-manager.js +0 -49
- package/dist/node_modules/langium/lib/workspace/profiler.js +0 -89
- package/dist/node_modules/langium/lib/workspace/workspace-lock.js +0 -42
- package/dist/node_modules/langium/lib/workspace/workspace-manager.js +0 -66
- package/dist/node_modules/lodash-es/flatMap.js +0 -7
- package/dist/node_modules/lodash-es/uniqBy.js +0 -7
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/wardleyDiagram-NUSXRM2D.js +0 -574
- package/dist/node_modules/vscode-jsonrpc/browser.js +0 -7
- package/dist/node_modules/vscode-jsonrpc/lib/browser/main.js +0 -52
- package/dist/node_modules/vscode-jsonrpc/lib/browser/ril.js +0 -120
- package/dist/node_modules/vscode-jsonrpc/lib/common/api.js +0 -337
- package/dist/node_modules/vscode-jsonrpc/lib/common/cancellation.js +0 -57
- package/dist/node_modules/vscode-jsonrpc/lib/common/connection.js +0 -647
- package/dist/node_modules/vscode-jsonrpc/lib/common/disposable.js +0 -13
- package/dist/node_modules/vscode-jsonrpc/lib/common/events.js +0 -64
- package/dist/node_modules/vscode-jsonrpc/lib/common/is.js +0 -34
- package/dist/node_modules/vscode-jsonrpc/lib/common/linkedMap.js +0 -235
- package/dist/node_modules/vscode-jsonrpc/lib/common/messageBuffer.js +0 -93
- package/dist/node_modules/vscode-jsonrpc/lib/common/messageReader.js +0 -129
- package/dist/node_modules/vscode-jsonrpc/lib/common/messageWriter.js +0 -85
- package/dist/node_modules/vscode-jsonrpc/lib/common/messages.js +0 -161
- package/dist/node_modules/vscode-jsonrpc/lib/common/ral.js +0 -18
- package/dist/node_modules/vscode-jsonrpc/lib/common/semaphore.js +0 -44
- package/dist/node_modules/vscode-jsonrpc/lib/common/sharedArrayCancellation.js +0 -58
- package/dist/node_modules/vscode-languageserver-protocol/lib/browser/main.js +0 -28
- package/dist/node_modules/vscode-languageserver-protocol/lib/common/api.js +0 -36
- package/dist/node_modules/vscode-languageserver-protocol/lib/common/connection.js +0 -12
- package/dist/node_modules/vscode-languageserver-protocol/lib/common/messages.js +0 -31
- package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.callHierarchy.js +0 -19
- package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.colorProvider.js +0 -15
- package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.configuration.js +0 -11
- package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.declaration.js +0 -11
- package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.diagnostic.js +0 -33
- package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.fileOperations.js +0 -35
- package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.foldingRange.js +0 -15
- package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.implementation.js +0 -11
- package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.inlayHint.js +0 -19
- package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.inlineCompletion.js +0 -11
- package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.inlineValue.js +0 -15
- package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.js +0 -674
- package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.linkedEditingRange.js +0 -11
- package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.moniker.js +0 -19
- package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.notebook.js +0 -126
- package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.progress.js +0 -24
- package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.selectionRange.js +0 -11
- package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.semanticTokens.js +0 -31
- package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.showDocument.js +0 -11
- package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.typeDefinition.js +0 -11
- package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.typeHierarchy.js +0 -19
- package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.workspaceFolder.js +0 -15
- package/dist/node_modules/vscode-languageserver-protocol/lib/common/utils/is.js +0 -42
- package/dist/node_modules/vscode-languageserver-textdocument/lib/esm/main.js +0 -138
- package/dist/node_modules/vscode-languageserver-types/lib/esm/main.js +0 -1084
- package/dist/node_modules/vscode-uri/lib/esm/index.js +0 -373
- /package/dist/node_modules/{entities → hast-util-raw/node_modules/entities}/dist/esm/decode-codepoint.js +0 -0
- /package/dist/node_modules/{entities → hast-util-raw/node_modules/entities}/dist/esm/decode.js +0 -0
- /package/dist/node_modules/{entities → hast-util-raw/node_modules/entities}/dist/esm/generated/decode-data-html.js +0 -0
- /package/dist/node_modules/{unified/node_modules/is-plain-obj → is-plain-obj}/index.js +0 -0
|
@@ -1,388 +0,0 @@
|
|
|
1
|
-
import { assignMandatoryProperties, getContainerOfType, linkContentToContainer } from "../utils/ast-utils.js";
|
|
2
|
-
import { isAssignment, isCrossReference, isInfixRule, isKeyword, isParserRule } from "../languages/generated/ast.js";
|
|
3
|
-
import { getTypeName, isDataTypeRule } from "../utils/grammar-utils.js";
|
|
4
|
-
import { defaultParserErrorProvider } from "../../../chevrotain/lib/src/parse/errors_public.js";
|
|
5
|
-
import { LLkLookaheadStrategy } from "../../../chevrotain/lib/src/parse/grammar/llk_lookahead.js";
|
|
6
|
-
import { EmbeddedActionsParser } from "../../../chevrotain/lib/src/parse/parser/parser.js";
|
|
7
|
-
import "../../../chevrotain/lib/src/api.js";
|
|
8
|
-
import { LLStarLookaheadStrategy } from "../../../chevrotain-allstar/lib/all-star-lookahead.js";
|
|
9
|
-
import "../../../chevrotain-allstar/lib/index.js";
|
|
10
|
-
import { CstNodeBuilder } from "./cst-node-builder.js";
|
|
11
|
-
const DatatypeSymbol = Symbol("Datatype");
|
|
12
|
-
function isDataTypeNode(e) {
|
|
13
|
-
return e.$type === DatatypeSymbol;
|
|
14
|
-
}
|
|
15
|
-
var ruleSuffix = "", withRuleSuffix = (e) => e.endsWith(ruleSuffix) ? e : e + ruleSuffix, AbstractLangiumParser = class {
|
|
16
|
-
constructor(e) {
|
|
17
|
-
this._unorderedGroups = /* @__PURE__ */ new Map(), this.allRules = /* @__PURE__ */ new Map(), this.lexer = e.parser.Lexer;
|
|
18
|
-
let m = this.lexer.definition, h = e.LanguageMetaData.mode === "production";
|
|
19
|
-
e.shared.profilers.LangiumProfiler?.isActive("parsing") ? this.wrapper = new ProfilerWrapper(m, {
|
|
20
|
-
...e.parser.ParserConfig,
|
|
21
|
-
skipValidations: h,
|
|
22
|
-
errorMessageProvider: e.parser.ParserErrorMessageProvider
|
|
23
|
-
}, e.shared.profilers.LangiumProfiler.createTask("parsing", e.LanguageMetaData.languageId)) : this.wrapper = new ChevrotainWrapper(m, {
|
|
24
|
-
...e.parser.ParserConfig,
|
|
25
|
-
skipValidations: h,
|
|
26
|
-
errorMessageProvider: e.parser.ParserErrorMessageProvider
|
|
27
|
-
});
|
|
28
|
-
}
|
|
29
|
-
alternatives(e, m) {
|
|
30
|
-
this.wrapper.wrapOr(e, m);
|
|
31
|
-
}
|
|
32
|
-
optional(e, m) {
|
|
33
|
-
this.wrapper.wrapOption(e, m);
|
|
34
|
-
}
|
|
35
|
-
many(e, m) {
|
|
36
|
-
this.wrapper.wrapMany(e, m);
|
|
37
|
-
}
|
|
38
|
-
atLeastOne(e, m) {
|
|
39
|
-
this.wrapper.wrapAtLeastOne(e, m);
|
|
40
|
-
}
|
|
41
|
-
getRule(e) {
|
|
42
|
-
return this.allRules.get(e);
|
|
43
|
-
}
|
|
44
|
-
isRecording() {
|
|
45
|
-
return this.wrapper.IS_RECORDING;
|
|
46
|
-
}
|
|
47
|
-
get unorderedGroups() {
|
|
48
|
-
return this._unorderedGroups;
|
|
49
|
-
}
|
|
50
|
-
getRuleStack() {
|
|
51
|
-
return this.wrapper.RULE_STACK;
|
|
52
|
-
}
|
|
53
|
-
finalize() {
|
|
54
|
-
this.wrapper.wrapSelfAnalysis();
|
|
55
|
-
}
|
|
56
|
-
}, LangiumParser = class extends AbstractLangiumParser {
|
|
57
|
-
get current() {
|
|
58
|
-
return this.stack[this.stack.length - 1];
|
|
59
|
-
}
|
|
60
|
-
constructor(e) {
|
|
61
|
-
super(e), this.nodeBuilder = new CstNodeBuilder(), this.stack = [], this.assignmentMap = /* @__PURE__ */ new Map(), this.operatorPrecedence = /* @__PURE__ */ new Map(), this.linker = e.references.Linker, this.converter = e.parser.ValueConverter, this.astReflection = e.shared.AstReflection;
|
|
62
|
-
}
|
|
63
|
-
rule(e, m) {
|
|
64
|
-
let h = this.computeRuleType(e), g;
|
|
65
|
-
isInfixRule(e) && (g = e.name, this.registerPrecedenceMap(e));
|
|
66
|
-
let _ = this.wrapper.DEFINE_RULE(withRuleSuffix(e.name), this.startImplementation(h, g, m).bind(this));
|
|
67
|
-
return this.allRules.set(e.name, _), isParserRule(e) && e.entry && (this.mainRule = _), _;
|
|
68
|
-
}
|
|
69
|
-
registerPrecedenceMap(e) {
|
|
70
|
-
let m = e.name, h = /* @__PURE__ */ new Map();
|
|
71
|
-
for (let m = 0; m < e.operators.precedences.length; m++) {
|
|
72
|
-
let g = e.operators.precedences[m];
|
|
73
|
-
for (let e of g.operators) h.set(e.value, {
|
|
74
|
-
precedence: m,
|
|
75
|
-
rightAssoc: g.associativity === "right"
|
|
76
|
-
});
|
|
77
|
-
}
|
|
78
|
-
this.operatorPrecedence.set(m, h);
|
|
79
|
-
}
|
|
80
|
-
computeRuleType(e) {
|
|
81
|
-
return isInfixRule(e) ? getTypeName(e) : e.fragment ? void 0 : isDataTypeRule(e) ? DatatypeSymbol : getTypeName(e);
|
|
82
|
-
}
|
|
83
|
-
parse(e, m = {}) {
|
|
84
|
-
this.nodeBuilder.buildRootNode(e);
|
|
85
|
-
let g = this.lexerResult = this.lexer.tokenize(e);
|
|
86
|
-
this.wrapper.input = g.tokens;
|
|
87
|
-
let _ = m.rule ? this.allRules.get(m.rule) : this.mainRule;
|
|
88
|
-
if (!_) throw Error(m.rule ? `No rule found with name '${m.rule}'` : "No main rule available.");
|
|
89
|
-
let v = this.doParse(_);
|
|
90
|
-
return this.nodeBuilder.addHiddenNodes(g.hidden), this.unorderedGroups.clear(), this.lexerResult = void 0, linkContentToContainer(v, { deep: !0 }), {
|
|
91
|
-
value: v,
|
|
92
|
-
lexerErrors: g.errors,
|
|
93
|
-
lexerReport: g.report,
|
|
94
|
-
parserErrors: this.wrapper.errors
|
|
95
|
-
};
|
|
96
|
-
}
|
|
97
|
-
doParse(e) {
|
|
98
|
-
let m = this.wrapper.rule(e);
|
|
99
|
-
if (this.stack.length > 0 && (m = this.construct()), m === void 0) throw Error("No result from parser");
|
|
100
|
-
if (this.stack.length > 0) throw Error("Parser stack is not empty after parsing");
|
|
101
|
-
return m;
|
|
102
|
-
}
|
|
103
|
-
startImplementation(e, m, h) {
|
|
104
|
-
return (g) => {
|
|
105
|
-
let _ = !this.isRecording() && e !== void 0;
|
|
106
|
-
if (_) {
|
|
107
|
-
let h = { $type: e };
|
|
108
|
-
this.stack.push(h), e === DatatypeSymbol ? h.value = "" : m !== void 0 && (h.$infixName = m);
|
|
109
|
-
}
|
|
110
|
-
return h(g), _ ? this.construct() : void 0;
|
|
111
|
-
};
|
|
112
|
-
}
|
|
113
|
-
extractHiddenTokens(e) {
|
|
114
|
-
let m = this.lexerResult.hidden;
|
|
115
|
-
if (!m.length) return [];
|
|
116
|
-
let h = e.startOffset;
|
|
117
|
-
for (let e = 0; e < m.length; e++) if (m[e].startOffset > h) return m.splice(0, e);
|
|
118
|
-
return m.splice(0, m.length);
|
|
119
|
-
}
|
|
120
|
-
consume(e, m, h) {
|
|
121
|
-
let g = this.wrapper.wrapConsume(e, m);
|
|
122
|
-
if (!this.isRecording() && this.isValidToken(g)) {
|
|
123
|
-
let e = this.extractHiddenTokens(g);
|
|
124
|
-
this.nodeBuilder.addHiddenNodes(e);
|
|
125
|
-
let m = this.nodeBuilder.buildLeafNode(g, h), { assignment: _, crossRef: v } = this.getAssignment(h), b = this.current;
|
|
126
|
-
if (_) {
|
|
127
|
-
let e = isKeyword(h) ? g.image : this.converter.convert(g.image, m);
|
|
128
|
-
this.assign(_.operator, _.feature, e, m, v);
|
|
129
|
-
} else if (isDataTypeNode(b)) {
|
|
130
|
-
let e = g.image;
|
|
131
|
-
isKeyword(h) || (e = this.converter.convert(e, m).toString()), b.value += e;
|
|
132
|
-
}
|
|
133
|
-
}
|
|
134
|
-
}
|
|
135
|
-
isValidToken(e) {
|
|
136
|
-
return !e.isInsertedInRecovery && !isNaN(e.startOffset) && typeof e.endOffset == "number" && !isNaN(e.endOffset);
|
|
137
|
-
}
|
|
138
|
-
subrule(e, m, h, g, _) {
|
|
139
|
-
let v;
|
|
140
|
-
!this.isRecording() && !h && (v = this.nodeBuilder.buildCompositeNode(g));
|
|
141
|
-
let y;
|
|
142
|
-
try {
|
|
143
|
-
y = this.wrapper.wrapSubrule(e, m, _);
|
|
144
|
-
} finally {
|
|
145
|
-
this.isRecording() || (y === void 0 && !h && (y = this.construct()), y !== void 0 && v && v.length > 0 && this.performSubruleAssignment(y, g, v));
|
|
146
|
-
}
|
|
147
|
-
}
|
|
148
|
-
performSubruleAssignment(e, m, h) {
|
|
149
|
-
let { assignment: g, crossRef: _ } = this.getAssignment(m);
|
|
150
|
-
if (g) this.assign(g.operator, g.feature, e, h, _);
|
|
151
|
-
else if (!g) {
|
|
152
|
-
let m = this.current;
|
|
153
|
-
if (isDataTypeNode(m)) m.value += e.toString();
|
|
154
|
-
else if (typeof e == "object" && e) {
|
|
155
|
-
let h = this.assignWithoutOverride(e, m);
|
|
156
|
-
this.stack.pop(), this.stack.push(h);
|
|
157
|
-
}
|
|
158
|
-
}
|
|
159
|
-
}
|
|
160
|
-
action(e, m) {
|
|
161
|
-
if (!this.isRecording()) {
|
|
162
|
-
let h = this.current;
|
|
163
|
-
if (m.feature && m.operator) {
|
|
164
|
-
h = this.construct(), this.nodeBuilder.removeNode(h.$cstNode), this.nodeBuilder.buildCompositeNode(m).content.push(h.$cstNode);
|
|
165
|
-
let g = { $type: e };
|
|
166
|
-
this.stack.push(g), this.assign(m.operator, m.feature, h, h.$cstNode);
|
|
167
|
-
} else h.$type = e;
|
|
168
|
-
}
|
|
169
|
-
}
|
|
170
|
-
construct() {
|
|
171
|
-
if (this.isRecording()) return;
|
|
172
|
-
let m = this.stack.pop();
|
|
173
|
-
return this.nodeBuilder.construct(m), "$infixName" in m ? this.constructInfix(m, this.operatorPrecedence.get(m.$infixName)) : isDataTypeNode(m) ? this.converter.convert(m.value, m.$cstNode) : (assignMandatoryProperties(this.astReflection, m), m);
|
|
174
|
-
}
|
|
175
|
-
constructInfix(e, m) {
|
|
176
|
-
let h = e.parts;
|
|
177
|
-
if (!Array.isArray(h) || h.length === 0) return;
|
|
178
|
-
let g = e.operators;
|
|
179
|
-
if (!Array.isArray(g) || h.length < 2) return h[0];
|
|
180
|
-
let _ = 0, v = -1;
|
|
181
|
-
for (let e = 0; e < g.length; e++) {
|
|
182
|
-
let h = g[e], y = m.get(h) ?? {
|
|
183
|
-
precedence: Infinity,
|
|
184
|
-
rightAssoc: !1
|
|
185
|
-
};
|
|
186
|
-
y.precedence > v ? (v = y.precedence, _ = e) : y.precedence === v && (y.rightAssoc || (_ = e));
|
|
187
|
-
}
|
|
188
|
-
let y = g.slice(0, _), b = g.slice(_ + 1), x = h.slice(0, _ + 1), S = h.slice(_ + 1), C = {
|
|
189
|
-
$infixName: e.$infixName,
|
|
190
|
-
$type: e.$type,
|
|
191
|
-
$cstNode: e.$cstNode,
|
|
192
|
-
parts: x,
|
|
193
|
-
operators: y
|
|
194
|
-
}, w = {
|
|
195
|
-
$infixName: e.$infixName,
|
|
196
|
-
$type: e.$type,
|
|
197
|
-
$cstNode: e.$cstNode,
|
|
198
|
-
parts: S,
|
|
199
|
-
operators: b
|
|
200
|
-
}, T = this.constructInfix(C, m), E = this.constructInfix(w, m);
|
|
201
|
-
return {
|
|
202
|
-
$type: e.$type,
|
|
203
|
-
$cstNode: e.$cstNode,
|
|
204
|
-
left: T,
|
|
205
|
-
operator: g[_],
|
|
206
|
-
right: E
|
|
207
|
-
};
|
|
208
|
-
}
|
|
209
|
-
getAssignment(e) {
|
|
210
|
-
if (!this.assignmentMap.has(e)) {
|
|
211
|
-
let h = getContainerOfType(e, isAssignment);
|
|
212
|
-
this.assignmentMap.set(e, {
|
|
213
|
-
assignment: h,
|
|
214
|
-
crossRef: h && isCrossReference(h.terminal) ? h.terminal.isMulti ? "multi" : "single" : void 0
|
|
215
|
-
});
|
|
216
|
-
}
|
|
217
|
-
return this.assignmentMap.get(e);
|
|
218
|
-
}
|
|
219
|
-
assign(e, m, h, g, _) {
|
|
220
|
-
let v = this.current, y;
|
|
221
|
-
switch (y = _ === "single" && typeof h == "string" ? this.linker.buildReference(v, m, g, h) : _ === "multi" && typeof h == "string" ? this.linker.buildMultiReference(v, m, g, h) : h, e) {
|
|
222
|
-
case "=":
|
|
223
|
-
v[m] = y;
|
|
224
|
-
break;
|
|
225
|
-
case "?=":
|
|
226
|
-
v[m] = !0;
|
|
227
|
-
break;
|
|
228
|
-
case "+=": Array.isArray(v[m]) || (v[m] = []), v[m].push(y);
|
|
229
|
-
}
|
|
230
|
-
}
|
|
231
|
-
assignWithoutOverride(e, m) {
|
|
232
|
-
for (let [h, g] of Object.entries(m)) {
|
|
233
|
-
let m = e[h];
|
|
234
|
-
m === void 0 ? e[h] = g : Array.isArray(m) && Array.isArray(g) && (g.push(...m), e[h] = g);
|
|
235
|
-
}
|
|
236
|
-
let h = e.$cstNode;
|
|
237
|
-
return h && (h.astNode = void 0, e.$cstNode = void 0), e;
|
|
238
|
-
}
|
|
239
|
-
get definitionErrors() {
|
|
240
|
-
return this.wrapper.definitionErrors;
|
|
241
|
-
}
|
|
242
|
-
}, AbstractParserErrorMessageProvider = class {
|
|
243
|
-
buildMismatchTokenMessage(e) {
|
|
244
|
-
return defaultParserErrorProvider.buildMismatchTokenMessage(e);
|
|
245
|
-
}
|
|
246
|
-
buildNotAllInputParsedMessage(e) {
|
|
247
|
-
return defaultParserErrorProvider.buildNotAllInputParsedMessage(e);
|
|
248
|
-
}
|
|
249
|
-
buildNoViableAltMessage(e) {
|
|
250
|
-
return defaultParserErrorProvider.buildNoViableAltMessage(e);
|
|
251
|
-
}
|
|
252
|
-
buildEarlyExitMessage(e) {
|
|
253
|
-
return defaultParserErrorProvider.buildEarlyExitMessage(e);
|
|
254
|
-
}
|
|
255
|
-
}, LangiumParserErrorMessageProvider = class extends AbstractParserErrorMessageProvider {
|
|
256
|
-
buildMismatchTokenMessage({ expected: e, actual: m }) {
|
|
257
|
-
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 \`${m.image}\`.`;
|
|
258
|
-
}
|
|
259
|
-
buildNotAllInputParsedMessage({ firstRedundant: e }) {
|
|
260
|
-
return `Expecting end of file but found \`${e.image}\`.`;
|
|
261
|
-
}
|
|
262
|
-
}, LangiumCompletionParser = class extends AbstractLangiumParser {
|
|
263
|
-
constructor() {
|
|
264
|
-
super(...arguments), this.tokens = [], this.elementStack = [], this.lastElementStack = [], this.nextTokenIndex = 0, this.stackSize = 0;
|
|
265
|
-
}
|
|
266
|
-
action() {}
|
|
267
|
-
construct() {}
|
|
268
|
-
parse(e) {
|
|
269
|
-
return this.resetState(), this.tokens = this.lexer.tokenize(e, { mode: "partial" }).tokens, this.wrapper.input = [...this.tokens], this.mainRule.call(this.wrapper, {}), this.unorderedGroups.clear(), {
|
|
270
|
-
tokens: this.tokens,
|
|
271
|
-
elementStack: [...this.lastElementStack],
|
|
272
|
-
tokenIndex: this.nextTokenIndex
|
|
273
|
-
};
|
|
274
|
-
}
|
|
275
|
-
rule(e, m) {
|
|
276
|
-
let h = this.wrapper.DEFINE_RULE(withRuleSuffix(e.name), this.startImplementation(m).bind(this));
|
|
277
|
-
return this.allRules.set(e.name, h), e.entry && (this.mainRule = h), h;
|
|
278
|
-
}
|
|
279
|
-
resetState() {
|
|
280
|
-
this.elementStack = [], this.lastElementStack = [], this.nextTokenIndex = 0, this.stackSize = 0;
|
|
281
|
-
}
|
|
282
|
-
startImplementation(e) {
|
|
283
|
-
return (m) => {
|
|
284
|
-
let h = this.keepStackSize();
|
|
285
|
-
try {
|
|
286
|
-
e(m);
|
|
287
|
-
} finally {
|
|
288
|
-
this.resetStackSize(h);
|
|
289
|
-
}
|
|
290
|
-
};
|
|
291
|
-
}
|
|
292
|
-
removeUnexpectedElements() {
|
|
293
|
-
this.elementStack.splice(this.stackSize);
|
|
294
|
-
}
|
|
295
|
-
keepStackSize() {
|
|
296
|
-
let e = this.elementStack.length;
|
|
297
|
-
return this.stackSize = e, e;
|
|
298
|
-
}
|
|
299
|
-
resetStackSize(e) {
|
|
300
|
-
this.removeUnexpectedElements(), this.stackSize = e;
|
|
301
|
-
}
|
|
302
|
-
consume(e, m, h) {
|
|
303
|
-
this.wrapper.wrapConsume(e, m), this.isRecording() || (this.lastElementStack = [...this.elementStack, h], this.nextTokenIndex = this.currIdx + 1);
|
|
304
|
-
}
|
|
305
|
-
subrule(e, m, h, g, _) {
|
|
306
|
-
this.before(g), this.wrapper.wrapSubrule(e, m, _), this.after(g);
|
|
307
|
-
}
|
|
308
|
-
before(e) {
|
|
309
|
-
this.isRecording() || this.elementStack.push(e);
|
|
310
|
-
}
|
|
311
|
-
after(e) {
|
|
312
|
-
if (!this.isRecording()) {
|
|
313
|
-
let m = this.elementStack.lastIndexOf(e);
|
|
314
|
-
m >= 0 && this.elementStack.splice(m);
|
|
315
|
-
}
|
|
316
|
-
}
|
|
317
|
-
get currIdx() {
|
|
318
|
-
return this.wrapper.currIdx;
|
|
319
|
-
}
|
|
320
|
-
}, defaultConfig = {
|
|
321
|
-
recoveryEnabled: !0,
|
|
322
|
-
nodeLocationTracking: "full",
|
|
323
|
-
skipValidations: !0,
|
|
324
|
-
errorMessageProvider: new LangiumParserErrorMessageProvider()
|
|
325
|
-
}, ChevrotainWrapper = class extends EmbeddedActionsParser {
|
|
326
|
-
constructor(e, m) {
|
|
327
|
-
let h = m && "maxLookahead" in m;
|
|
328
|
-
super(e, {
|
|
329
|
-
...defaultConfig,
|
|
330
|
-
lookaheadStrategy: h ? new LLkLookaheadStrategy({ maxLookahead: m.maxLookahead }) : new LLStarLookaheadStrategy({ logging: m.skipValidations ? () => {} : void 0 }),
|
|
331
|
-
...m
|
|
332
|
-
});
|
|
333
|
-
}
|
|
334
|
-
get IS_RECORDING() {
|
|
335
|
-
return this.RECORDING_PHASE;
|
|
336
|
-
}
|
|
337
|
-
DEFINE_RULE(e, m, h) {
|
|
338
|
-
return this.RULE(e, m, h);
|
|
339
|
-
}
|
|
340
|
-
wrapSelfAnalysis() {
|
|
341
|
-
this.performSelfAnalysis();
|
|
342
|
-
}
|
|
343
|
-
wrapConsume(e, m) {
|
|
344
|
-
return this.consume(e, m, void 0);
|
|
345
|
-
}
|
|
346
|
-
wrapSubrule(e, m, h) {
|
|
347
|
-
return this.subrule(e, m, { ARGS: [h] });
|
|
348
|
-
}
|
|
349
|
-
wrapOr(e, m) {
|
|
350
|
-
this.or(e, m);
|
|
351
|
-
}
|
|
352
|
-
wrapOption(e, m) {
|
|
353
|
-
this.option(e, m);
|
|
354
|
-
}
|
|
355
|
-
wrapMany(e, m) {
|
|
356
|
-
this.many(e, m);
|
|
357
|
-
}
|
|
358
|
-
wrapAtLeastOne(e, m) {
|
|
359
|
-
this.atLeastOne(e, m);
|
|
360
|
-
}
|
|
361
|
-
rule(e) {
|
|
362
|
-
return e.call(this, {});
|
|
363
|
-
}
|
|
364
|
-
}, ProfilerWrapper = class extends ChevrotainWrapper {
|
|
365
|
-
constructor(e, m, h) {
|
|
366
|
-
super(e, m), this.task = h;
|
|
367
|
-
}
|
|
368
|
-
rule(e) {
|
|
369
|
-
this.task.start(), this.task.startSubTask(this.ruleName(e));
|
|
370
|
-
try {
|
|
371
|
-
return super.rule(e);
|
|
372
|
-
} finally {
|
|
373
|
-
this.task.stopSubTask(this.ruleName(e)), this.task.stop();
|
|
374
|
-
}
|
|
375
|
-
}
|
|
376
|
-
ruleName(e) {
|
|
377
|
-
return e.ruleName;
|
|
378
|
-
}
|
|
379
|
-
subrule(e, m, h) {
|
|
380
|
-
this.task.startSubTask(this.ruleName(m));
|
|
381
|
-
try {
|
|
382
|
-
return super.subrule(e, m, h);
|
|
383
|
-
} finally {
|
|
384
|
-
this.task.stopSubTask(this.ruleName(m));
|
|
385
|
-
}
|
|
386
|
-
}
|
|
387
|
-
};
|
|
388
|
-
export { AbstractLangiumParser, AbstractParserErrorMessageProvider, DatatypeSymbol, LangiumCompletionParser, LangiumParser, LangiumParserErrorMessageProvider };
|
|
@@ -1,50 +0,0 @@
|
|
|
1
|
-
import { defaultLexerErrorProvider } from "../../../chevrotain/lib/src/scan/lexer_errors_public.js";
|
|
2
|
-
import { Lexer } from "../../../chevrotain/lib/src/scan/lexer_public.js";
|
|
3
|
-
import "../../../chevrotain/lib/src/api.js";
|
|
4
|
-
var DefaultLexerErrorMessageProvider = class {
|
|
5
|
-
buildUnexpectedCharactersMessage(r, i, a, o, s) {
|
|
6
|
-
return defaultLexerErrorProvider.buildUnexpectedCharactersMessage(r, i, a, o, s);
|
|
7
|
-
}
|
|
8
|
-
buildUnableToPopLexerModeMessage(r) {
|
|
9
|
-
return defaultLexerErrorProvider.buildUnableToPopLexerModeMessage(r);
|
|
10
|
-
}
|
|
11
|
-
};
|
|
12
|
-
const DEFAULT_TOKENIZE_OPTIONS = { mode: "full" };
|
|
13
|
-
var DefaultLexer = class {
|
|
14
|
-
constructor(e) {
|
|
15
|
-
this.errorMessageProvider = e.parser.LexerErrorMessageProvider, this.tokenBuilder = e.parser.TokenBuilder;
|
|
16
|
-
let i = this.tokenBuilder.buildTokens(e.Grammar, { caseInsensitive: e.LanguageMetaData.caseInsensitive });
|
|
17
|
-
this.tokenTypes = this.toTokenTypeDictionary(i), this.chevrotainLexer = new Lexer(isTokenTypeDictionary(i) ? Object.values(i) : i, {
|
|
18
|
-
positionTracking: "full",
|
|
19
|
-
skipValidations: e.LanguageMetaData.mode === "production",
|
|
20
|
-
errorMessageProvider: this.errorMessageProvider
|
|
21
|
-
});
|
|
22
|
-
}
|
|
23
|
-
get definition() {
|
|
24
|
-
return this.tokenTypes;
|
|
25
|
-
}
|
|
26
|
-
tokenize(e, r = DEFAULT_TOKENIZE_OPTIONS) {
|
|
27
|
-
let i = this.chevrotainLexer.tokenize(e);
|
|
28
|
-
return {
|
|
29
|
-
tokens: i.tokens,
|
|
30
|
-
errors: i.errors,
|
|
31
|
-
hidden: i.groups.hidden ?? [],
|
|
32
|
-
report: this.tokenBuilder.flushLexingReport?.(e)
|
|
33
|
-
};
|
|
34
|
-
}
|
|
35
|
-
toTokenTypeDictionary(e) {
|
|
36
|
-
if (isTokenTypeDictionary(e)) return e;
|
|
37
|
-
let r = isIMultiModeLexerDefinition(e) ? Object.values(e.modes).flat() : e, i = {};
|
|
38
|
-
return r.forEach((e) => i[e.name] = e), i;
|
|
39
|
-
}
|
|
40
|
-
};
|
|
41
|
-
function isTokenTypeArray(e) {
|
|
42
|
-
return Array.isArray(e) && (e.length === 0 || "name" in e[0]);
|
|
43
|
-
}
|
|
44
|
-
function isIMultiModeLexerDefinition(e) {
|
|
45
|
-
return e && "modes" in e && "defaultMode" in e;
|
|
46
|
-
}
|
|
47
|
-
function isTokenTypeDictionary(e) {
|
|
48
|
-
return !isTokenTypeArray(e) && !isIMultiModeLexerDefinition(e);
|
|
49
|
-
}
|
|
50
|
-
export { DEFAULT_TOKENIZE_OPTIONS, DefaultLexer, DefaultLexerErrorMessageProvider, isIMultiModeLexerDefinition, isTokenTypeArray, isTokenTypeDictionary };
|