@walkeros/explorer 3.1.0 → 3.1.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/index.d.ts +1338 -69
- package/dist/index.js +1 -59
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +1 -1
- package/dist/index.mjs.map +1 -1
- package/package.json +6 -6
- package/dist/__mocks__/@monaco-editor/react.d.ts +0 -3
- package/dist/__mocks__/@monaco-editor/react.d.ts.map +0 -1
- package/dist/__mocks__/@monaco-editor/react.js +0 -4
- package/dist/__mocks__/@monaco-editor/react.js.map +0 -1
- package/dist/components/atoms/box.d.ts +0 -27
- package/dist/components/atoms/box.d.ts.map +0 -1
- package/dist/components/atoms/box.js +0 -86
- package/dist/components/atoms/box.js.map +0 -1
- package/dist/components/atoms/box.stories.d.ts +0 -34
- package/dist/components/atoms/box.stories.d.ts.map +0 -1
- package/dist/components/atoms/box.stories.js +0 -104
- package/dist/components/atoms/box.stories.js.map +0 -1
- package/dist/components/atoms/button-group.d.ts +0 -17
- package/dist/components/atoms/button-group.d.ts.map +0 -1
- package/dist/components/atoms/button-group.js +0 -12
- package/dist/components/atoms/button-group.js.map +0 -1
- package/dist/components/atoms/button-group.stories.d.ts +0 -18
- package/dist/components/atoms/button-group.stories.d.ts.map +0 -1
- package/dist/components/atoms/button-group.stories.js +0 -39
- package/dist/components/atoms/button-group.stories.js.map +0 -1
- package/dist/components/atoms/button-link.d.ts +0 -12
- package/dist/components/atoms/button-link.d.ts.map +0 -1
- package/dist/components/atoms/button-link.js +0 -10
- package/dist/components/atoms/button-link.js.map +0 -1
- package/dist/components/atoms/button-link.stories.d.ts +0 -11
- package/dist/components/atoms/button-link.stories.d.ts.map +0 -1
- package/dist/components/atoms/button-link.stories.js +0 -50
- package/dist/components/atoms/button-link.stories.js.map +0 -1
- package/dist/components/atoms/button.d.ts +0 -15
- package/dist/components/atoms/button.d.ts.map +0 -1
- package/dist/components/atoms/button.js +0 -11
- package/dist/components/atoms/button.js.map +0 -1
- package/dist/components/atoms/button.stories.d.ts +0 -14
- package/dist/components/atoms/button.stories.d.ts.map +0 -1
- package/dist/components/atoms/button.stories.js +0 -25
- package/dist/components/atoms/button.stories.js.map +0 -1
- package/dist/components/atoms/code.d.ts +0 -92
- package/dist/components/atoms/code.d.ts.map +0 -1
- package/dist/components/atoms/code.js +0 -405
- package/dist/components/atoms/code.js.map +0 -1
- package/dist/components/atoms/code.stories.d.ts +0 -46
- package/dist/components/atoms/code.stories.d.ts.map +0 -1
- package/dist/components/atoms/code.stories.js +0 -156
- package/dist/components/atoms/code.stories.js.map +0 -1
- package/dist/components/atoms/footer.d.ts +0 -21
- package/dist/components/atoms/footer.d.ts.map +0 -1
- package/dist/components/atoms/footer.js +0 -19
- package/dist/components/atoms/footer.js.map +0 -1
- package/dist/components/atoms/footer.stories.d.ts +0 -14
- package/dist/components/atoms/footer.stories.d.ts.map +0 -1
- package/dist/components/atoms/footer.stories.js +0 -29
- package/dist/components/atoms/footer.stories.js.map +0 -1
- package/dist/components/atoms/grid.d.ts +0 -65
- package/dist/components/atoms/grid.d.ts.map +0 -1
- package/dist/components/atoms/grid.js +0 -169
- package/dist/components/atoms/grid.js.map +0 -1
- package/dist/components/atoms/grid.stories.d.ts +0 -18
- package/dist/components/atoms/grid.stories.d.ts.map +0 -1
- package/dist/components/atoms/grid.stories.js +0 -60
- package/dist/components/atoms/grid.stories.js.map +0 -1
- package/dist/components/atoms/header.d.ts +0 -7
- package/dist/components/atoms/header.d.ts.map +0 -1
- package/dist/components/atoms/header.js +0 -5
- package/dist/components/atoms/header.js.map +0 -1
- package/dist/components/atoms/header.stories.d.ts +0 -15
- package/dist/components/atoms/header.stories.d.ts.map +0 -1
- package/dist/components/atoms/header.stories.js +0 -37
- package/dist/components/atoms/header.stories.js.map +0 -1
- package/dist/components/atoms/icons/icon.stories.d.ts +0 -18
- package/dist/components/atoms/icons/icon.stories.d.ts.map +0 -1
- package/dist/components/atoms/icons/icon.stories.js +0 -37
- package/dist/components/atoms/icons/icon.stories.js.map +0 -1
- package/dist/components/atoms/icons/icons.d.ts +0 -2
- package/dist/components/atoms/icons/icons.d.ts.map +0 -1
- package/dist/components/atoms/icons/icons.js +0 -7
- package/dist/components/atoms/icons/icons.js.map +0 -1
- package/dist/components/atoms/icons/index.d.ts +0 -3
- package/dist/components/atoms/icons/index.d.ts.map +0 -1
- package/dist/components/atoms/icons/index.js +0 -3
- package/dist/components/atoms/icons/index.js.map +0 -1
- package/dist/components/atoms/mdx-code.d.ts +0 -33
- package/dist/components/atoms/mdx-code.d.ts.map +0 -1
- package/dist/components/atoms/mdx-code.js +0 -69
- package/dist/components/atoms/mdx-code.js.map +0 -1
- package/dist/components/atoms/preview-footer.d.ts +0 -32
- package/dist/components/atoms/preview-footer.d.ts.map +0 -1
- package/dist/components/atoms/preview-footer.js +0 -31
- package/dist/components/atoms/preview-footer.js.map +0 -1
- package/dist/components/atoms/spinner.d.ts +0 -17
- package/dist/components/atoms/spinner.d.ts.map +0 -1
- package/dist/components/atoms/spinner.js +0 -14
- package/dist/components/atoms/spinner.js.map +0 -1
- package/dist/components/atoms/spinner.stories.d.ts +0 -7
- package/dist/components/atoms/spinner.stories.d.ts.map +0 -1
- package/dist/components/atoms/spinner.stories.js +0 -9
- package/dist/components/atoms/spinner.stories.js.map +0 -1
- package/dist/components/atoms/toggle.d.ts +0 -9
- package/dist/components/atoms/toggle.d.ts.map +0 -1
- package/dist/components/atoms/toggle.js +0 -6
- package/dist/components/atoms/toggle.js.map +0 -1
- package/dist/components/demos/DestinationDemo.d.ts +0 -48
- package/dist/components/demos/DestinationDemo.d.ts.map +0 -1
- package/dist/components/demos/DestinationDemo.js +0 -105
- package/dist/components/demos/DestinationDemo.js.map +0 -1
- package/dist/components/demos/DestinationDemo.stories.d.ts +0 -17
- package/dist/components/demos/DestinationDemo.stories.d.ts.map +0 -1
- package/dist/components/demos/DestinationDemo.stories.js +0 -53
- package/dist/components/demos/DestinationDemo.stories.js.map +0 -1
- package/dist/components/demos/DestinationInitDemo.d.ts +0 -34
- package/dist/components/demos/DestinationInitDemo.d.ts.map +0 -1
- package/dist/components/demos/DestinationInitDemo.js +0 -73
- package/dist/components/demos/DestinationInitDemo.js.map +0 -1
- package/dist/components/demos/DestinationInitDemo.stories.d.ts +0 -17
- package/dist/components/demos/DestinationInitDemo.stories.d.ts.map +0 -1
- package/dist/components/demos/DestinationInitDemo.stories.js +0 -39
- package/dist/components/demos/DestinationInitDemo.stories.js.map +0 -1
- package/dist/components/demos/PromotionPlayground.d.ts +0 -30
- package/dist/components/demos/PromotionPlayground.d.ts.map +0 -1
- package/dist/components/demos/PromotionPlayground.js +0 -366
- package/dist/components/demos/PromotionPlayground.js.map +0 -1
- package/dist/components/demos/PromotionPlayground.stories.d.ts +0 -27
- package/dist/components/demos/PromotionPlayground.stories.d.ts.map +0 -1
- package/dist/components/demos/PromotionPlayground.stories.js +0 -32
- package/dist/components/demos/PromotionPlayground.stories.js.map +0 -1
- package/dist/components/molecules/architecture-flow/ArchitectureFlow.d.ts +0 -24
- package/dist/components/molecules/architecture-flow/ArchitectureFlow.d.ts.map +0 -1
- package/dist/components/molecules/architecture-flow/ArchitectureFlow.js +0 -10
- package/dist/components/molecules/architecture-flow/ArchitectureFlow.js.map +0 -1
- package/dist/components/molecules/architecture-flow/ArchitectureFlow.stories.d.ts +0 -7
- package/dist/components/molecules/architecture-flow/ArchitectureFlow.stories.d.ts.map +0 -1
- package/dist/components/molecules/architecture-flow/ArchitectureFlow.stories.js +0 -71
- package/dist/components/molecules/architecture-flow/ArchitectureFlow.stories.js.map +0 -1
- package/dist/components/molecules/architecture-flow/index.d.ts +0 -3
- package/dist/components/molecules/architecture-flow/index.d.ts.map +0 -1
- package/dist/components/molecules/architecture-flow/index.js +0 -2
- package/dist/components/molecules/architecture-flow/index.js.map +0 -1
- package/dist/components/molecules/code-box.d.ts +0 -75
- package/dist/components/molecules/code-box.d.ts.map +0 -1
- package/dist/components/molecules/code-box.js +0 -174
- package/dist/components/molecules/code-box.js.map +0 -1
- package/dist/components/molecules/code-box.stories.d.ts +0 -87
- package/dist/components/molecules/code-box.stories.d.ts.map +0 -1
- package/dist/components/molecules/code-box.stories.js +0 -300
- package/dist/components/molecules/code-box.stories.js.map +0 -1
- package/dist/components/molecules/code-snippet.d.ts +0 -58
- package/dist/components/molecules/code-snippet.d.ts.map +0 -1
- package/dist/components/molecules/code-snippet.js +0 -72
- package/dist/components/molecules/code-snippet.js.map +0 -1
- package/dist/components/molecules/code-snippet.stories.d.ts +0 -23
- package/dist/components/molecules/code-snippet.stories.d.ts.map +0 -1
- package/dist/components/molecules/code-snippet.stories.js +0 -87
- package/dist/components/molecules/code-snippet.stories.js.map +0 -1
- package/dist/components/molecules/dropdown.d.ts +0 -68
- package/dist/components/molecules/dropdown.d.ts.map +0 -1
- package/dist/components/molecules/dropdown.js +0 -47
- package/dist/components/molecules/dropdown.js.map +0 -1
- package/dist/components/molecules/dropdown.stories.d.ts +0 -7
- package/dist/components/molecules/dropdown.stories.d.ts.map +0 -1
- package/dist/components/molecules/dropdown.stories.js +0 -18
- package/dist/components/molecules/dropdown.stories.js.map +0 -1
- package/dist/components/molecules/flow-map/FlowMap.d.ts +0 -74
- package/dist/components/molecules/flow-map/FlowMap.d.ts.map +0 -1
- package/dist/components/molecules/flow-map/FlowMap.js +0 -1039
- package/dist/components/molecules/flow-map/FlowMap.js.map +0 -1
- package/dist/components/molecules/flow-map/FlowMap.stories.d.ts +0 -47
- package/dist/components/molecules/flow-map/FlowMap.stories.d.ts.map +0 -1
- package/dist/components/molecules/flow-map/FlowMap.stories.js +0 -355
- package/dist/components/molecules/flow-map/FlowMap.stories.js.map +0 -1
- package/dist/components/molecules/flow-map/FlowMap.transformers.stories.d.ts +0 -29
- package/dist/components/molecules/flow-map/FlowMap.transformers.stories.d.ts.map +0 -1
- package/dist/components/molecules/flow-map/FlowMap.transformers.stories.js +0 -117
- package/dist/components/molecules/flow-map/FlowMap.transformers.stories.js.map +0 -1
- package/dist/components/molecules/flow-map/index.d.ts +0 -3
- package/dist/components/molecules/flow-map/index.d.ts.map +0 -1
- package/dist/components/molecules/flow-map/index.js +0 -2
- package/dist/components/molecules/flow-map/index.js.map +0 -1
- package/dist/components/molecules/preview.d.ts +0 -23
- package/dist/components/molecules/preview.d.ts.map +0 -1
- package/dist/components/molecules/preview.js +0 -232
- package/dist/components/molecules/preview.js.map +0 -1
- package/dist/components/molecules/preview.stories.d.ts +0 -23
- package/dist/components/molecules/preview.stories.d.ts.map +0 -1
- package/dist/components/molecules/preview.stories.js +0 -186
- package/dist/components/molecules/preview.stories.js.map +0 -1
- package/dist/components/molecules/property-table.d.ts +0 -7
- package/dist/components/molecules/property-table.d.ts.map +0 -1
- package/dist/components/molecules/property-table.js +0 -88
- package/dist/components/molecules/property-table.js.map +0 -1
- package/dist/components/molecules/property-table.stories.d.ts +0 -24
- package/dist/components/molecules/property-table.stories.d.ts.map +0 -1
- package/dist/components/molecules/property-table.stories.js +0 -86
- package/dist/components/molecules/property-table.stories.js.map +0 -1
- package/dist/components/organisms/browser-box.d.ts +0 -31
- package/dist/components/organisms/browser-box.d.ts.map +0 -1
- package/dist/components/organisms/browser-box.js +0 -80
- package/dist/components/organisms/browser-box.js.map +0 -1
- package/dist/components/organisms/browser-box.stories.d.ts +0 -26
- package/dist/components/organisms/browser-box.stories.d.ts.map +0 -1
- package/dist/components/organisms/browser-box.stories.js +0 -102
- package/dist/components/organisms/browser-box.stories.js.map +0 -1
- package/dist/components/organisms/collector-box.d.ts +0 -24
- package/dist/components/organisms/collector-box.d.ts.map +0 -1
- package/dist/components/organisms/collector-box.js +0 -56
- package/dist/components/organisms/collector-box.js.map +0 -1
- package/dist/components/organisms/collector-box.stories.d.ts +0 -22
- package/dist/components/organisms/collector-box.stories.d.ts.map +0 -1
- package/dist/components/organisms/collector-box.stories.js +0 -59
- package/dist/components/organisms/collector-box.stories.js.map +0 -1
- package/dist/components/organisms/live-code.d.ts +0 -22
- package/dist/components/organisms/live-code.d.ts.map +0 -1
- package/dist/components/organisms/live-code.js +0 -50
- package/dist/components/organisms/live-code.js.map +0 -1
- package/dist/components/organisms/live-code.stories.d.ts +0 -24
- package/dist/components/organisms/live-code.stories.d.ts.map +0 -1
- package/dist/components/organisms/live-code.stories.js +0 -55
- package/dist/components/organisms/live-code.stories.js.map +0 -1
- package/dist/components/ui/button.d.ts +0 -4
- package/dist/components/ui/button.d.ts.map +0 -1
- package/dist/components/ui/button.js +0 -6
- package/dist/components/ui/button.js.map +0 -1
- package/dist/components/ui/icon.d.ts +0 -5
- package/dist/components/ui/icon.d.ts.map +0 -1
- package/dist/components/ui/icon.js +0 -5
- package/dist/components/ui/icon.js.map +0 -1
- package/dist/contexts/GridHeightContext.d.ts +0 -11
- package/dist/contexts/GridHeightContext.d.ts.map +0 -1
- package/dist/contexts/GridHeightContext.js +0 -14
- package/dist/contexts/GridHeightContext.js.map +0 -1
- package/dist/helpers/capture.d.ts +0 -83
- package/dist/helpers/capture.d.ts.map +0 -1
- package/dist/helpers/capture.js +0 -125
- package/dist/helpers/capture.js.map +0 -1
- package/dist/helpers/destinations.d.ts +0 -21
- package/dist/helpers/destinations.d.ts.map +0 -1
- package/dist/helpers/destinations.js +0 -46
- package/dist/helpers/destinations.js.map +0 -1
- package/dist/hooks/useDropdown.d.ts +0 -34
- package/dist/hooks/useDropdown.d.ts.map +0 -1
- package/dist/hooks/useDropdown.js +0 -66
- package/dist/hooks/useDropdown.js.map +0 -1
- package/dist/hooks/useMonacoHeight.d.ts +0 -31
- package/dist/hooks/useMonacoHeight.d.ts.map +0 -1
- package/dist/hooks/useMonacoHeight.js +0 -83
- package/dist/hooks/useMonacoHeight.js.map +0 -1
- package/dist/hooks/useTreeState.d.ts +0 -32
- package/dist/hooks/useTreeState.d.ts.map +0 -1
- package/dist/hooks/useTreeState.js +0 -94
- package/dist/hooks/useTreeState.js.map +0 -1
- package/dist/index.d.ts.map +0 -1
- package/dist/lib/utils.d.ts +0 -7
- package/dist/lib/utils.d.ts.map +0 -1
- package/dist/lib/utils.js +0 -10
- package/dist/lib/utils.js.map +0 -1
- package/dist/providers/MDXProvider.d.ts +0 -40
- package/dist/providers/MDXProvider.d.ts.map +0 -1
- package/dist/providers/MDXProvider.js +0 -57
- package/dist/providers/MDXProvider.js.map +0 -1
- package/dist/themes/index.d.ts +0 -23
- package/dist/themes/index.d.ts.map +0 -1
- package/dist/themes/index.js +0 -29
- package/dist/themes/index.js.map +0 -1
- package/dist/themes/lighthouse.d.ts +0 -26
- package/dist/themes/lighthouse.d.ts.map +0 -1
- package/dist/themes/lighthouse.js +0 -230
- package/dist/themes/lighthouse.js.map +0 -1
- package/dist/themes/palenight.d.ts +0 -31
- package/dist/themes/palenight.d.ts.map +0 -1
- package/dist/themes/palenight.js +0 -236
- package/dist/themes/palenight.js.map +0 -1
- package/dist/themes/types.d.ts +0 -103
- package/dist/themes/types.d.ts.map +0 -1
- package/dist/themes/types.js +0 -8
- package/dist/themes/types.js.map +0 -1
- package/dist/types/intellisense.d.ts +0 -33
- package/dist/types/intellisense.d.ts.map +0 -1
- package/dist/types/intellisense.js +0 -2
- package/dist/types/intellisense.js.map +0 -1
- package/dist/utils/code-normalizer.d.ts +0 -11
- package/dist/utils/code-normalizer.d.ts.map +0 -1
- package/dist/utils/code-normalizer.js +0 -21
- package/dist/utils/code-normalizer.js.map +0 -1
- package/dist/utils/contract-path-walker.d.ts +0 -27
- package/dist/utils/contract-path-walker.d.ts.map +0 -1
- package/dist/utils/contract-path-walker.js +0 -145
- package/dist/utils/contract-path-walker.js.map +0 -1
- package/dist/utils/format-code.d.ts +0 -9
- package/dist/utils/format-code.d.ts.map +0 -1
- package/dist/utils/format-code.js +0 -77
- package/dist/utils/format-code.js.map +0 -1
- package/dist/utils/mapping-context-detector.d.ts +0 -17
- package/dist/utils/mapping-context-detector.d.ts.map +0 -1
- package/dist/utils/mapping-context-detector.js +0 -22
- package/dist/utils/mapping-context-detector.js.map +0 -1
- package/dist/utils/monaco-context-types.d.ts +0 -39
- package/dist/utils/monaco-context-types.d.ts.map +0 -1
- package/dist/utils/monaco-context-types.js +0 -426
- package/dist/utils/monaco-context-types.js.map +0 -1
- package/dist/utils/monaco-decorators.d.ts +0 -17
- package/dist/utils/monaco-decorators.d.ts.map +0 -1
- package/dist/utils/monaco-decorators.js +0 -81
- package/dist/utils/monaco-decorators.js.map +0 -1
- package/dist/utils/monaco-formatters.d.ts +0 -16
- package/dist/utils/monaco-formatters.d.ts.map +0 -1
- package/dist/utils/monaco-formatters.js +0 -139
- package/dist/utils/monaco-formatters.js.map +0 -1
- package/dist/utils/monaco-intellisense-flow-extractor.d.ts +0 -13
- package/dist/utils/monaco-intellisense-flow-extractor.d.ts.map +0 -1
- package/dist/utils/monaco-intellisense-flow-extractor.js +0 -168
- package/dist/utils/monaco-intellisense-flow-extractor.js.map +0 -1
- package/dist/utils/monaco-json-path.d.ts +0 -12
- package/dist/utils/monaco-json-path.d.ts.map +0 -1
- package/dist/utils/monaco-json-path.js +0 -68
- package/dist/utils/monaco-json-path.js.map +0 -1
- package/dist/utils/monaco-json-schema.d.ts +0 -45
- package/dist/utils/monaco-json-schema.d.ts.map +0 -1
- package/dist/utils/monaco-json-schema.js +0 -90
- package/dist/utils/monaco-json-schema.js.map +0 -1
- package/dist/utils/monaco-schema-contract.d.ts +0 -8
- package/dist/utils/monaco-schema-contract.d.ts.map +0 -1
- package/dist/utils/monaco-schema-contract.js +0 -73
- package/dist/utils/monaco-schema-contract.js.map +0 -1
- package/dist/utils/monaco-schema-enrichment.d.ts +0 -26
- package/dist/utils/monaco-schema-enrichment.d.ts.map +0 -1
- package/dist/utils/monaco-schema-enrichment.js +0 -31
- package/dist/utils/monaco-schema-enrichment.js.map +0 -1
- package/dist/utils/monaco-schema-flow-config.d.ts +0 -10
- package/dist/utils/monaco-schema-flow-config.d.ts.map +0 -1
- package/dist/utils/monaco-schema-flow-config.js +0 -201
- package/dist/utils/monaco-schema-flow-config.js.map +0 -1
- package/dist/utils/monaco-schema-variables.d.ts +0 -4
- package/dist/utils/monaco-schema-variables.d.ts.map +0 -1
- package/dist/utils/monaco-schema-variables.js +0 -26
- package/dist/utils/monaco-schema-variables.js.map +0 -1
- package/dist/utils/monaco-types.d.ts +0 -174
- package/dist/utils/monaco-types.d.ts.map +0 -1
- package/dist/utils/monaco-types.js +0 -378
- package/dist/utils/monaco-types.js.map +0 -1
- package/dist/utils/monaco-walkeros-completions.d.ts +0 -23
- package/dist/utils/monaco-walkeros-completions.d.ts.map +0 -1
- package/dist/utils/monaco-walkeros-completions.js +0 -258
- package/dist/utils/monaco-walkeros-completions.js.map +0 -1
- package/dist/utils/monaco-walkeros-decorations.d.ts +0 -29
- package/dist/utils/monaco-walkeros-decorations.d.ts.map +0 -1
- package/dist/utils/monaco-walkeros-decorations.js +0 -87
- package/dist/utils/monaco-walkeros-decorations.js.map +0 -1
- package/dist/utils/monaco-walkeros-markers.d.ts +0 -13
- package/dist/utils/monaco-walkeros-markers.d.ts.map +0 -1
- package/dist/utils/monaco-walkeros-markers.js +0 -69
- package/dist/utils/monaco-walkeros-markers.js.map +0 -1
- package/dist/utils/monaco-walkeros-providers.d.ts +0 -19
- package/dist/utils/monaco-walkeros-providers.d.ts.map +0 -1
- package/dist/utils/monaco-walkeros-providers.js +0 -284
- package/dist/utils/monaco-walkeros-providers.js.map +0 -1
- package/dist/utils/path-analyzer.d.ts +0 -88
- package/dist/utils/path-analyzer.d.ts.map +0 -1
- package/dist/utils/path-analyzer.js +0 -215
- package/dist/utils/path-analyzer.js.map +0 -1
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"monaco-formatters.js","sourceRoot":"","sources":["../../src/utils/monaco-formatters.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,QAAQ,MAAM,qBAAqB,CAAC;AAChD,OAAO,aAAa,MAAM,wBAAwB,CAAC;AACnD,OAAO,cAAc,MAAM,yBAAyB,CAAC;AACrD,OAAO,kBAAkB,MAAM,6B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EAAE,CAAC,YAAY,CAAC;oBACvB,QAAQ,EAAE,OAAO,CAAC,OAAO;oBACzB,OAAO,EAAE,CAAC,OAAO,CAAC,YAAY;oBAC9B,yBAAyB,EAAE,KAAK;iBACjC,CAAC,CAAC;gBACH,OAAO;oBACL;wBACE,KAAK,EAAE,KAAK,CAAC,iBAAiB,EAAE;wBAChC,IAAI,EAAE,SAAS;qBAChB;iBACF,CAAC;YACJ,CAAC;YAAC,OAAO,KAAK,EAAE,CAAC;gBACf,OAAO,EAAE,CAAC;YACZ,CAAC;QACH,CAAC;KACF,CAAC,CAAC;IAEH,gBAAgB;IAChB,cAAc,CAAC,SAAS,CAAC,sCAAsC,CAAC,KAAK,EAAE;QACrE,KAAK,CAAC,8BAA8B,CAAC,KAAK,EAAE,OAAO;YACjD,IAAI,CAAC;gBACH,MAAM,IAAI,GAAG,KAAK,CAAC,QAAQ,EAAE,CAAC;gBAC9B,MAAM,SAAS,GAAG,MAAM,QAAQ,CAAC,MAAM,CAAC,IAAI,EAAE;oBAC5C,MAAM,EAAE,KAAK;oBACb,OAAO,EAAE,CAAC,YAAY,CAAC,EAAE,+BAA+B;oBACxD,QAAQ,EAAE,OAAO,CAAC,OAAO;oBACzB,OAAO,EAAE,CAAC,OAAO,CAAC,YAAY;iBAC/B,CAAC,CAAC;gBACH,OAAO;oBACL;wBACE,KAAK,EAAE,KAAK,CAAC,iBAAiB,EAAE;wBAChC,IAAI,EAAE,SAAS;qBAChB;iBACF,CAAC;YACJ,CAAC;YAAC,OAAO,KAAK,EAAE,CAAC;gBACf,OAAO,EAAE,CAAC;YACZ,CAAC;QACH,CAAC;KACF,CAAC,CAAC;AACL,CAAC"}
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import type { IntelliSenseContext } from '../types/intellisense';
|
|
2
|
-
/**
|
|
3
|
-
* Extract IntelliSense context from a Flow.Config JSON string.
|
|
4
|
-
*
|
|
5
|
-
* Parses the JSON, walks config → settings → steps, and collects
|
|
6
|
-
* all discoverable variables, definitions, step names, packages,
|
|
7
|
-
* platform, and contract entities.
|
|
8
|
-
*
|
|
9
|
-
* Returns `{}` for invalid JSON or non-Flow structures.
|
|
10
|
-
* Pure function — no side effects, no state.
|
|
11
|
-
*/
|
|
12
|
-
export declare function extractFlowIntelliSenseContext(json: string): Partial<IntelliSenseContext>;
|
|
13
|
-
//# sourceMappingURL=monaco-intellisense-flow-extractor.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"monaco-intellisense-flow-extractor.d.ts","sourceRoot":"","sources":["../../src/utils/monaco-intellisense-flow-extractor.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,mBAAmB,EAAe,MAAM,uBAAuB,CAAC;AAE9E;;;;;;;;;GASG;AACH,wBAAgB,8BAA8B,CAC5C,IAAI,EAAE,MAAM,GACX,OAAO,CAAC,mBAAmB,CAAC,CAiH9B"}
|
|
@@ -1,168 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Extract IntelliSense context from a Flow.Config JSON string.
|
|
3
|
-
*
|
|
4
|
-
* Parses the JSON, walks config → settings → steps, and collects
|
|
5
|
-
* all discoverable variables, definitions, step names, packages,
|
|
6
|
-
* platform, and contract entities.
|
|
7
|
-
*
|
|
8
|
-
* Returns `{}` for invalid JSON or non-Flow structures.
|
|
9
|
-
* Pure function — no side effects, no state.
|
|
10
|
-
*/
|
|
11
|
-
export function extractFlowIntelliSenseContext(json) {
|
|
12
|
-
let parsed;
|
|
13
|
-
try {
|
|
14
|
-
parsed = JSON.parse(json);
|
|
15
|
-
}
|
|
16
|
-
catch {
|
|
17
|
-
return {};
|
|
18
|
-
}
|
|
19
|
-
if (!isFlowConfig(parsed))
|
|
20
|
-
return {};
|
|
21
|
-
const variables = {};
|
|
22
|
-
const definitions = {};
|
|
23
|
-
const sources = [];
|
|
24
|
-
const destinations = [];
|
|
25
|
-
const transformers = [];
|
|
26
|
-
const packages = [];
|
|
27
|
-
const contractEntities = [];
|
|
28
|
-
const contractRaw = {};
|
|
29
|
-
let platform;
|
|
30
|
-
// Config-level
|
|
31
|
-
mergeVars(variables, parsed.variables);
|
|
32
|
-
mergeDefs(definitions, parsed.definitions);
|
|
33
|
-
extractContract(contractEntities, parsed.contract);
|
|
34
|
-
if (isObject(parsed.contract))
|
|
35
|
-
Object.assign(contractRaw, parsed.contract);
|
|
36
|
-
// Walk each flow settings
|
|
37
|
-
for (const settings of Object.values(parsed.flows)) {
|
|
38
|
-
if (!isObject(settings))
|
|
39
|
-
continue;
|
|
40
|
-
// Platform detection (first match wins)
|
|
41
|
-
if (!platform) {
|
|
42
|
-
if ('web' in settings)
|
|
43
|
-
platform = 'web';
|
|
44
|
-
else if ('server' in settings)
|
|
45
|
-
platform = 'server';
|
|
46
|
-
}
|
|
47
|
-
// Settings-level variables/definitions/contract
|
|
48
|
-
mergeVars(variables, settings.variables);
|
|
49
|
-
mergeDefs(definitions, settings.definitions);
|
|
50
|
-
extractContract(contractEntities, settings.contract);
|
|
51
|
-
if (isObject(settings.contract))
|
|
52
|
-
Object.assign(contractRaw, settings.contract);
|
|
53
|
-
// Sources
|
|
54
|
-
if (isObject(settings.sources)) {
|
|
55
|
-
for (const [name, ref] of Object.entries(settings.sources)) {
|
|
56
|
-
sources.push(name);
|
|
57
|
-
if (isObject(ref)) {
|
|
58
|
-
mergeVars(variables, ref.variables);
|
|
59
|
-
mergeDefs(definitions, ref.definitions);
|
|
60
|
-
if (typeof ref.package === 'string') {
|
|
61
|
-
packages.push({
|
|
62
|
-
package: ref.package,
|
|
63
|
-
shortName: name,
|
|
64
|
-
type: 'source',
|
|
65
|
-
platform: platform || 'web',
|
|
66
|
-
});
|
|
67
|
-
}
|
|
68
|
-
}
|
|
69
|
-
}
|
|
70
|
-
}
|
|
71
|
-
// Destinations
|
|
72
|
-
if (isObject(settings.destinations)) {
|
|
73
|
-
for (const [name, ref] of Object.entries(settings.destinations)) {
|
|
74
|
-
destinations.push(name);
|
|
75
|
-
if (isObject(ref)) {
|
|
76
|
-
mergeVars(variables, ref.variables);
|
|
77
|
-
mergeDefs(definitions, ref.definitions);
|
|
78
|
-
if (typeof ref.package === 'string') {
|
|
79
|
-
packages.push({
|
|
80
|
-
package: ref.package,
|
|
81
|
-
shortName: name,
|
|
82
|
-
type: 'destination',
|
|
83
|
-
platform: platform || 'web',
|
|
84
|
-
});
|
|
85
|
-
}
|
|
86
|
-
}
|
|
87
|
-
}
|
|
88
|
-
}
|
|
89
|
-
// Transformers
|
|
90
|
-
if (isObject(settings.transformers)) {
|
|
91
|
-
for (const [name, ref] of Object.entries(settings.transformers)) {
|
|
92
|
-
transformers.push(name);
|
|
93
|
-
if (isObject(ref)) {
|
|
94
|
-
mergeVars(variables, ref.variables);
|
|
95
|
-
mergeDefs(definitions, ref.definitions);
|
|
96
|
-
if (typeof ref.package === 'string') {
|
|
97
|
-
packages.push({
|
|
98
|
-
package: ref.package,
|
|
99
|
-
shortName: name,
|
|
100
|
-
type: 'transformer',
|
|
101
|
-
platform: platform || 'web',
|
|
102
|
-
});
|
|
103
|
-
}
|
|
104
|
-
}
|
|
105
|
-
}
|
|
106
|
-
}
|
|
107
|
-
}
|
|
108
|
-
const result = {
|
|
109
|
-
variables,
|
|
110
|
-
definitions,
|
|
111
|
-
stepNames: { sources, destinations, transformers },
|
|
112
|
-
};
|
|
113
|
-
if (platform)
|
|
114
|
-
result.platform = platform;
|
|
115
|
-
if (packages.length > 0)
|
|
116
|
-
result.packages = packages;
|
|
117
|
-
if (contractEntities.length > 0)
|
|
118
|
-
result.contract = contractEntities;
|
|
119
|
-
if (Object.keys(contractRaw).length > 0)
|
|
120
|
-
result.contractRaw = contractRaw;
|
|
121
|
-
return result;
|
|
122
|
-
}
|
|
123
|
-
// --- Helpers ---
|
|
124
|
-
function isObject(v) {
|
|
125
|
-
return typeof v === 'object' && v !== null && !Array.isArray(v);
|
|
126
|
-
}
|
|
127
|
-
function isFlowConfig(v) {
|
|
128
|
-
return isObject(v) && 'version' in v && 'flows' in v && isObject(v.flows);
|
|
129
|
-
}
|
|
130
|
-
function isPrimitive(v) {
|
|
131
|
-
return (typeof v === 'string' || typeof v === 'number' || typeof v === 'boolean');
|
|
132
|
-
}
|
|
133
|
-
function mergeVars(target, source) {
|
|
134
|
-
if (!isObject(source))
|
|
135
|
-
return;
|
|
136
|
-
for (const [k, v] of Object.entries(source)) {
|
|
137
|
-
if (isPrimitive(v))
|
|
138
|
-
target[k] = v;
|
|
139
|
-
}
|
|
140
|
-
}
|
|
141
|
-
function mergeDefs(target, source) {
|
|
142
|
-
if (!isObject(source))
|
|
143
|
-
return;
|
|
144
|
-
for (const [k, v] of Object.entries(source)) {
|
|
145
|
-
target[k] = v;
|
|
146
|
-
}
|
|
147
|
-
}
|
|
148
|
-
function extractContract(target, contract) {
|
|
149
|
-
if (!isObject(contract))
|
|
150
|
-
return;
|
|
151
|
-
for (const [key, value] of Object.entries(contract)) {
|
|
152
|
-
if (key.startsWith('$') || !isObject(value))
|
|
153
|
-
continue;
|
|
154
|
-
// Avoid duplicates when merging config + settings contracts
|
|
155
|
-
const existing = target.find((e) => e.entity === key);
|
|
156
|
-
const actions = Object.keys(value);
|
|
157
|
-
if (existing) {
|
|
158
|
-
for (const a of actions) {
|
|
159
|
-
if (!existing.actions.includes(a))
|
|
160
|
-
existing.actions.push(a);
|
|
161
|
-
}
|
|
162
|
-
}
|
|
163
|
-
else {
|
|
164
|
-
target.push({ entity: key, actions });
|
|
165
|
-
}
|
|
166
|
-
}
|
|
167
|
-
}
|
|
168
|
-
//# sourceMappingURL=monaco-intellisense-flow-extractor.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"monaco-intellisense-flow-extractor.js","sourceRoot":"","sources":["../../src/utils/monaco-intellisense-flow-extractor.ts"],"names":[],"mappings":"AAEA;;;;;;;;;GASG;AACH,MAAM,UAAU,8BAA8B,CAC5C,IAAY;IAEZ,IAAI,MAAe,CAAC;IACpB,IAAI,CAAC;QACH,MAAM,GA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key path at a given character offset in a JSON string.
|
|
3
|
-
*
|
|
4
|
-
* Uses a simple stack-based parser that tracks object keys as we scan
|
|
5
|
-
* from the start to the offset position.
|
|
6
|
-
*
|
|
7
|
-
* @param json - The full JSON string
|
|
8
|
-
* @param offset - Character offset (0-based) of cursor position
|
|
9
|
-
* @returns Array of key segments from root to cursor
|
|
10
|
-
*/
|
|
11
|
-
export declare function getJsonPathAtOffset(json: string, offset: number): string[];
|
|
12
|
-
//# sourceMappingURL=monaco-json-path.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"monaco-json-path.d.ts","sourceRoot":"","sources":["../../src/utils/monaco-json-path.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AACH,wBAAgB,mBAAmB,CAAC,IAAI,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,GAAG,MAAM,EAAE,CA4D1E"}
|
|
@@ -1,68 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Extract the JSON key path at a given character offset in a JSON string.
|
|
3
|
-
*
|
|
4
|
-
* Uses a simple stack-based parser that tracks object keys as we scan
|
|
5
|
-
* from the start to the offset position.
|
|
6
|
-
*
|
|
7
|
-
* @param json - The full JSON string
|
|
8
|
-
* @param offset - Character offset (0-based) of cursor position
|
|
9
|
-
* @returns Array of key segments from root to cursor
|
|
10
|
-
*/
|
|
11
|
-
export function getJsonPathAtOffset(json, offset) {
|
|
12
|
-
const path = [];
|
|
13
|
-
let i = 0;
|
|
14
|
-
let currentKey;
|
|
15
|
-
let inString = false;
|
|
16
|
-
let stringStart = -1;
|
|
17
|
-
let escaped = false;
|
|
18
|
-
while (i < json.length && i <= offset) {
|
|
19
|
-
const ch = json[i];
|
|
20
|
-
if (escaped) {
|
|
21
|
-
escaped = false;
|
|
22
|
-
i++;
|
|
23
|
-
continue;
|
|
24
|
-
}
|
|
25
|
-
if (ch === '\\' && inString) {
|
|
26
|
-
escaped = true;
|
|
27
|
-
i++;
|
|
28
|
-
continue;
|
|
29
|
-
}
|
|
30
|
-
if (ch === '"') {
|
|
31
|
-
if (inString) {
|
|
32
|
-
// End of string
|
|
33
|
-
const str = json.substring(stringStart, i);
|
|
34
|
-
inString = false;
|
|
35
|
-
// Determine if this string is a key or value by looking ahead for ':'
|
|
36
|
-
let j = i + 1;
|
|
37
|
-
while (j < json.length && /\s/.test(json[j]))
|
|
38
|
-
j++;
|
|
39
|
-
if (json[j] === ':') {
|
|
40
|
-
currentKey = str;
|
|
41
|
-
}
|
|
42
|
-
}
|
|
43
|
-
else {
|
|
44
|
-
// Start of string
|
|
45
|
-
inString = true;
|
|
46
|
-
stringStart = i + 1;
|
|
47
|
-
}
|
|
48
|
-
}
|
|
49
|
-
else if (!inString) {
|
|
50
|
-
if (ch === '{') {
|
|
51
|
-
if (currentKey !== undefined) {
|
|
52
|
-
path.push(currentKey);
|
|
53
|
-
currentKey = undefined;
|
|
54
|
-
}
|
|
55
|
-
}
|
|
56
|
-
else if (ch === '}') {
|
|
57
|
-
path.pop();
|
|
58
|
-
}
|
|
59
|
-
}
|
|
60
|
-
i++;
|
|
61
|
-
}
|
|
62
|
-
// Add the current key if we're at a value position
|
|
63
|
-
if (currentKey !== undefined) {
|
|
64
|
-
path.push(currentKey);
|
|
65
|
-
}
|
|
66
|
-
return path;
|
|
67
|
-
}
|
|
68
|
-
//# sourceMappingURL=monaco-json-path.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"monaco-json-path.js","sourceRoot":"","sources":["../../src/utils/monaco-json-path.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AACH,MAAM,UAAU,mBAAmB,CAAC,IAAY,EAAE,MAAc;IAC9D,MAAM,IAAI,GAAa,EAAE,CAAC;IAC1B,IAAI,CAAC,GAAG,CAAC,CAAC;IACV,IAAI,UAA8B,CAAC;IACnC,IAAI,QAAQ,GAAG,KAAK,CAAC;IACrB,IAAI,WAAW,GAAG,CAAC,CAAC,CAAC;IACrB,IAAI,OA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;gBACzB,CAAC;YACH,CAAC;iBAAM,IAAI,EAAE,KAAK,GAAG,EAAE,CAAC;gBACtB,IAAI,CAAC,GAAG,EAAE,CAAC;YACb,CAAC;QACH,CAAC;QAED,CAAC,EAAE,CAAC;IACN,CAAC;IAED,mDAAmD;IACnD,IAAI,UAAU,KAAK,SAAS,EAAE,CAAC;QAC7B,IAAI,CAAC,IAAI,CAAC,UAAU,CAAC,CAAC;IACxB,CAAC;IAED,OAAO,IAAI,CAAC;AACd,CAAC"}
|
|
@@ -1,45 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Monaco JSON Schema Registry
|
|
3
|
-
*
|
|
4
|
-
* Manages JSON Schema registrations for Monaco's JSON language service.
|
|
5
|
-
* Multiple Code instances can register schemas concurrently — the registry
|
|
6
|
-
* accumulates all schemas and issues a single setDiagnosticsOptions() call.
|
|
7
|
-
*
|
|
8
|
-
* The monaco json namespace is initialized via initMonacoJson() when the
|
|
9
|
-
* Code atom's beforeMount fires. Schemas registered before initialization
|
|
10
|
-
* are queued and flushed once the namespace becomes available.
|
|
11
|
-
*/
|
|
12
|
-
/**
|
|
13
|
-
* Initialize the JSON schema registry with the monaco instance.
|
|
14
|
-
* Called from Code atom's handleBeforeMount where monaco is guaranteed loaded.
|
|
15
|
-
* Flushes any schemas registered before initialization.
|
|
16
|
-
*/
|
|
17
|
-
export declare function initMonacoJson(monaco: typeof import('monaco-editor')): void;
|
|
18
|
-
/**
|
|
19
|
-
* Reset state (for testing only).
|
|
20
|
-
*/
|
|
21
|
-
export declare function resetMonacoJson(): void;
|
|
22
|
-
/**
|
|
23
|
-
* Generate a unique model path for a Code instance.
|
|
24
|
-
* Used as the `path` prop for @monaco-editor/react Editor.
|
|
25
|
-
*/
|
|
26
|
-
export declare function generateModelPath(): string;
|
|
27
|
-
/**
|
|
28
|
-
* Register a JSON schema for a specific model path.
|
|
29
|
-
* Triggers a global setDiagnosticsOptions update.
|
|
30
|
-
*/
|
|
31
|
-
export declare function registerJsonSchema(modelPath: string, schema: Record<string, unknown>): void;
|
|
32
|
-
/**
|
|
33
|
-
* Unregister a JSON schema when a Code instance unmounts.
|
|
34
|
-
* Triggers a global setDiagnosticsOptions update.
|
|
35
|
-
*/
|
|
36
|
-
export declare function unregisterJsonSchema(modelPath: string): void;
|
|
37
|
-
/**
|
|
38
|
-
* Get count of registered schemas (for testing/debugging).
|
|
39
|
-
*/
|
|
40
|
-
export declare function getRegisteredSchemaCount(): number;
|
|
41
|
-
/**
|
|
42
|
-
* Clear all schemas (for testing).
|
|
43
|
-
*/
|
|
44
|
-
export declare function clearAllSchemas(): void;
|
|
45
|
-
//# sourceMappingURL=monaco-json-schema.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"monaco-json-schema.d.ts","sourceRoot":"","sources":["../../src/utils/monaco-json-schema.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAkBH;;;;GAIG;AACH,wBAAgB,cAAc,CAAC,MAAM,EAAE,cAAc,eAAe,CAAC,GAAG,IAAI,CAI3E;AAED;;GAEG;AACH,wBAAgB,eAAe,IAAI,IAAI,CAItC;AAED;;;GAGG;AACH,wBAAgB,iBAAiB,IAAI,MAAM,CAE1C;AAED;;;GAGG;AACH,wBAAgB,kBAAkB,CAChC,SAAS,EAAE,MAAM,EACjB,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAC9B,IAAI,CAON;AAED;;;GAGG;AACH,wBAAgB,oBAAoB,CAAC,SAAS,EAAE,MAAM,GAAG,IAAI,CAG5D;AAgBD;;GAEG;AACH,wBAAgB,wBAAwB,IAAI,MAAM,CAEjD;AAED;;GAEG;AACH,wBAAgB,eAAe,IAAI,IAAI,CAGtC"}
|
|
@@ -1,90 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Monaco JSON Schema Registry
|
|
3
|
-
*
|
|
4
|
-
* Manages JSON Schema registrations for Monaco's JSON language service.
|
|
5
|
-
* Multiple Code instances can register schemas concurrently — the registry
|
|
6
|
-
* accumulates all schemas and issues a single setDiagnosticsOptions() call.
|
|
7
|
-
*
|
|
8
|
-
* The monaco json namespace is initialized via initMonacoJson() when the
|
|
9
|
-
* Code atom's beforeMount fires. Schemas registered before initialization
|
|
10
|
-
* are queued and flushed once the namespace becomes available.
|
|
11
|
-
*/
|
|
12
|
-
const schemaRegistry = new Map();
|
|
13
|
-
let idCounter = 0;
|
|
14
|
-
// Monaco JSON namespace, set via initMonacoJson() from Code atom's beforeMount
|
|
15
|
-
let _json;
|
|
16
|
-
/**
|
|
17
|
-
* Initialize the JSON schema registry with the monaco instance.
|
|
18
|
-
* Called from Code atom's handleBeforeMount where monaco is guaranteed loaded.
|
|
19
|
-
* Flushes any schemas registered before initialization.
|
|
20
|
-
*/
|
|
21
|
-
export function initMonacoJson(monaco) {
|
|
22
|
-
if (_json)
|
|
23
|
-
return;
|
|
24
|
-
_json = monaco.json;
|
|
25
|
-
if (schemaRegistry.size > 0)
|
|
26
|
-
applySchemas();
|
|
27
|
-
}
|
|
28
|
-
/**
|
|
29
|
-
* Reset state (for testing only).
|
|
30
|
-
*/
|
|
31
|
-
export function resetMonacoJson() {
|
|
32
|
-
_json = undefined;
|
|
33
|
-
schemaRegistry.clear();
|
|
34
|
-
idCounter = 0;
|
|
35
|
-
}
|
|
36
|
-
/**
|
|
37
|
-
* Generate a unique model path for a Code instance.
|
|
38
|
-
* Used as the `path` prop for @monaco-editor/react Editor.
|
|
39
|
-
*/
|
|
40
|
-
export function generateModelPath() {
|
|
41
|
-
return `inmemory://walkeros/json-${++idCounter}.json`;
|
|
42
|
-
}
|
|
43
|
-
/**
|
|
44
|
-
* Register a JSON schema for a specific model path.
|
|
45
|
-
* Triggers a global setDiagnosticsOptions update.
|
|
46
|
-
*/
|
|
47
|
-
export function registerJsonSchema(modelPath, schema) {
|
|
48
|
-
schemaRegistry.set(modelPath, {
|
|
49
|
-
uri: `schema://walkeros/${modelPath}`,
|
|
50
|
-
fileMatch: [modelPath],
|
|
51
|
-
schema,
|
|
52
|
-
});
|
|
53
|
-
applySchemas();
|
|
54
|
-
}
|
|
55
|
-
/**
|
|
56
|
-
* Unregister a JSON schema when a Code instance unmounts.
|
|
57
|
-
* Triggers a global setDiagnosticsOptions update.
|
|
58
|
-
*/
|
|
59
|
-
export function unregisterJsonSchema(modelPath) {
|
|
60
|
-
schemaRegistry.delete(modelPath);
|
|
61
|
-
applySchemas();
|
|
62
|
-
}
|
|
63
|
-
/**
|
|
64
|
-
* Apply all registered schemas to Monaco's JSON language service.
|
|
65
|
-
*/
|
|
66
|
-
function applySchemas() {
|
|
67
|
-
if (!_json)
|
|
68
|
-
return;
|
|
69
|
-
_json.jsonDefaults.setDiagnosticsOptions({
|
|
70
|
-
validate: true,
|
|
71
|
-
schemaValidation: 'error',
|
|
72
|
-
schemaRequest: 'ignore',
|
|
73
|
-
enableSchemaRequest: false,
|
|
74
|
-
schemas: Array.from(schemaRegistry.values()),
|
|
75
|
-
});
|
|
76
|
-
}
|
|
77
|
-
/**
|
|
78
|
-
* Get count of registered schemas (for testing/debugging).
|
|
79
|
-
*/
|
|
80
|
-
export function getRegisteredSchemaCount() {
|
|
81
|
-
return schemaRegistry.size;
|
|
82
|
-
}
|
|
83
|
-
/**
|
|
84
|
-
* Clear all schemas (for testing).
|
|
85
|
-
*/
|
|
86
|
-
export function clearAllSchemas() {
|
|
87
|
-
schemaRegistry.clear();
|
|
88
|
-
applySchemas();
|
|
89
|
-
}
|
|
90
|
-
//# sourceMappingURL=monaco-json-schema.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"monaco-json-schema.js","sourceRoot":"","sources":["../../src/utils/monaco-json-schema.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAWH,MAAM,cAAc,GAAG,IAAI,GAAG,EAA4B,CAAC;AAE3D,IAAI,SAAS,GAAG,CAAC,CAAC;AAElB,+EAA+E;AAC/E,IAAI,KAAsD,CAAC;AAE3D;;;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;AACH,MAAM,UAAU,eAAe;IAC7B,cAAc,CAAC,KAAK,EAAE,CAAC;IACvB,YAAY,EAAE,CAAC;AACjB,CAAC"}
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
type AnySchema = Record<string, any>;
|
|
2
|
-
/**
|
|
3
|
-
* Returns an enriched JSON Schema for the walkerOS Contract editor.
|
|
4
|
-
* Structure: { $tagging: number, entity: { action: JSONSchema } }
|
|
5
|
-
*/
|
|
6
|
-
export declare function getEnrichedContractSchema(): AnySchema;
|
|
7
|
-
export {};
|
|
8
|
-
//# sourceMappingURL=monaco-schema-contract.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"monaco-schema-contract.d.ts","sourceRoot":"","sources":["../../src/utils/monaco-schema-contract.ts"],"names":[],"mappings":"AACA,KAAK,SAAS,GAAG,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAC;AAErC;;;GAGG;AACH,wBAAgB,yBAAyB,IAAI,SAAS,CAsErD"}
|
|
@@ -1,73 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Returns an enriched JSON Schema for the walkerOS Contract editor.
|
|
3
|
-
* Structure: { $tagging: number, entity: { action: JSONSchema } }
|
|
4
|
-
*/
|
|
5
|
-
export function getEnrichedContractSchema() {
|
|
6
|
-
return {
|
|
7
|
-
type: 'object',
|
|
8
|
-
markdownDescription: 'walkerOS Data Contract. Defines entity→action schemas for event validation.\n\n' +
|
|
9
|
-
'```json\n{\n "$tagging": 1,\n "page": {\n' +
|
|
10
|
-
' "view": {\n "type": "object",\n "properties": {\n' +
|
|
11
|
-
' "title": { "type": "string" }\n }\n }\n }\n}\n```',
|
|
12
|
-
properties: {
|
|
13
|
-
$tagging: {
|
|
14
|
-
type: 'number',
|
|
15
|
-
markdownDescription: 'Contract version number. Increment when making breaking changes.\n\n```json\n"$tagging": 1\n```',
|
|
16
|
-
},
|
|
17
|
-
},
|
|
18
|
-
additionalProperties: {
|
|
19
|
-
type: 'object',
|
|
20
|
-
markdownDescription: 'Entity name. Contains action→schema mappings.',
|
|
21
|
-
additionalProperties: {
|
|
22
|
-
type: 'object',
|
|
23
|
-
markdownDescription: 'Action schema (JSON Schema). Defines valid event data for this entity+action.\n\n' +
|
|
24
|
-
'```json\n{\n "type": "object",\n "properties": {\n' +
|
|
25
|
-
' "name": { "type": "string" },\n "price": { "type": "number" }\n' +
|
|
26
|
-
' },\n "required": ["name"]\n}\n```',
|
|
27
|
-
defaultSnippets: [
|
|
28
|
-
{
|
|
29
|
-
label: 'Object schema',
|
|
30
|
-
description: 'Schema with typed properties',
|
|
31
|
-
body: {
|
|
32
|
-
type: 'object',
|
|
33
|
-
properties: {
|
|
34
|
-
'${1:name}': { type: '${2:string}' },
|
|
35
|
-
},
|
|
36
|
-
},
|
|
37
|
-
},
|
|
38
|
-
],
|
|
39
|
-
},
|
|
40
|
-
defaultSnippets: [
|
|
41
|
-
{
|
|
42
|
-
label: 'Add action',
|
|
43
|
-
description: 'Action with event data schema',
|
|
44
|
-
body: {
|
|
45
|
-
'${1:action}': {
|
|
46
|
-
type: 'object',
|
|
47
|
-
properties: {
|
|
48
|
-
'${2:property}': { type: '${3:string}' },
|
|
49
|
-
},
|
|
50
|
-
},
|
|
51
|
-
},
|
|
52
|
-
},
|
|
53
|
-
],
|
|
54
|
-
},
|
|
55
|
-
defaultSnippets: [
|
|
56
|
-
{
|
|
57
|
-
label: 'Entity with action',
|
|
58
|
-
description: 'New entity with one action and properties',
|
|
59
|
-
body: {
|
|
60
|
-
'${1:entity}': {
|
|
61
|
-
'${2:action}': {
|
|
62
|
-
type: 'object',
|
|
63
|
-
properties: {
|
|
64
|
-
'${3:property}': { type: '${4:string}' },
|
|
65
|
-
},
|
|
66
|
-
},
|
|
67
|
-
},
|
|
68
|
-
},
|
|
69
|
-
},
|
|
70
|
-
],
|
|
71
|
-
};
|
|
72
|
-
}
|
|
73
|
-
//# sourceMappingURL=monaco-schema-contract.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"monaco-schema-contract.js","sourceRoot":"","sources":["../../src/utils/monaco-schema-contract.ts"],"names":[],"mappings":"AAGA;;;GAGG;AACH,MAAM,UAAU,yBAAyB;IACvC,OAAO;QACL,IAAI,EAAE,QAAQ;QACd,mBAAmB,EACjB,iFAAiF;YACjF,6CAA6C;YAC7C,iEAAiE;YACjE,8DAA8D;QAChE,UAAU,EAAE;YACV,QAAQ,EAAE;gBACR,IAAI,EAAE,QAAQ;gBACd,mBAAmB,EACjB,iGAAiG;aACpG;SACF;QACD,oBAAoB,EAAE;YACpB,IAAI,EAAE,QAAQ;YACd,mBAAmB,EAAE,+CAA+C;YACpE,oBAAoB,EAAE;gBACpB,IAAI,EAAE,QAAQ;gBACd,mBAAmB,EACjB,mFAAmF;oBACnF,sDAAsD;oBACtD,wEAAwE;oBACxE,sCAAsC;gBACxC,eAAe,EAAE;oBACf;wBACE,KAAK,EAAE,eAAe;wBACtB,WAAW,EAAE,8BAA8B;wBAC3C,IAAI,EAAE;4BACJ,IAAI,EAAE,QAAQ;4BACd,UAAU,EAAE;gCACV,WAAW,EAAE,EAAE,IAAI,EAAE,aAAa,EAAE;6BACrC;yBACF;qBACF;iBACF;aACF;YACD,eAAe,EAAE;gBACf;oBACE,KAAK,EAAE,YAAY;oBACnB,WAAW,EAAE,+BAA+B;oBAC5C,IAAI,EAAE;wBACJ,aAAa,EAAE;4BACb,IAAI,EAAE,QAAQ;4BACd,UAAU,EAAE;gCACV,eAAe,EAAE,EAAE,IAAI,EAAE,aAAa,EAAE;6BACzC;yBACF;qBACF;iBACF;aACF;SACF;QACD,eAAe,EAAE;YACf;gBACE,KAAK,EAAE,oBAAoB;gBAC3B,WAAW,EAAE,2CAA2C;gBACxD,IAAI,EAAE;oBACJ,aAAa,EAAE;wBACb,aAAa,EAAE;4BACb,IAAI,EAAE,QAAQ;4BACd,UAAU,EAAE;gCACV,eAAe,EAAE,EAAE,IAAI,EAAE,aAAa,EAAE;6BACzC;yBACF;qBACF;iBACF;aACF;SACF;KACF,CAAC;AACJ,CAAC"}
|
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
export interface MonacoSchemaExtension {
|
|
2
|
-
defaultSnippets?: Array<{
|
|
3
|
-
label: string;
|
|
4
|
-
description?: string;
|
|
5
|
-
markdownDescription?: string;
|
|
6
|
-
body?: unknown;
|
|
7
|
-
bodyText?: string;
|
|
8
|
-
}>;
|
|
9
|
-
markdownDescription?: string;
|
|
10
|
-
enumDescriptions?: string[];
|
|
11
|
-
markdownEnumDescriptions?: string[];
|
|
12
|
-
deprecationMessage?: string;
|
|
13
|
-
errorMessage?: string;
|
|
14
|
-
patternErrorMessage?: string;
|
|
15
|
-
doNotSuggest?: boolean;
|
|
16
|
-
suggestSortText?: string;
|
|
17
|
-
}
|
|
18
|
-
type EnrichmentMap = Record<string, MonacoSchemaExtension>;
|
|
19
|
-
/**
|
|
20
|
-
* Deep-merges Monaco-specific JSON Schema extensions into a base schema.
|
|
21
|
-
* Keys in the enrichment map are dot-paths (e.g., 'properties.sources').
|
|
22
|
-
* Empty string '' targets the root. Does not mutate the original.
|
|
23
|
-
*/
|
|
24
|
-
export declare function enrichSchema(baseSchema: Record<string, unknown>, enrichments: EnrichmentMap): Record<string, unknown>;
|
|
25
|
-
export {};
|
|
26
|
-
//# sourceMappingURL=monaco-schema-enrichment.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"monaco-schema-enrichment.d.ts","sourceRoot":"","sources":["../../src/utils/monaco-schema-enrichment.ts"],"names":[],"mappings":"AAAA,MAAM,WAAW,qBAAqB;IACpC,eAAe,CAAC,EAAE,KAAK,CAAC;QACtB,KAAK,EAAE,MAAM,CAAC;QACd,WAAW,CAAC,EAAE,MAAM,CAAC;QACrB,mBAAmB,CAAC,EAAE,MAAM,CAAC;QAC7B,IAAI,CAAC,EAAE,OAAO,CAAC;QACf,QAAQ,CAAC,EAAE,MAAM,CAAC;KACnB,CAAC,CAAC;IACH,mBAAmB,CAAC,EAAE,MAAM,CAAC;IAC7B,gBAAgB,CAAC,EAAE,MAAM,EAAE,CAAC;IAC5B,wBAAwB,CAAC,EAAE,MAAM,EAAE,CAAC;IACpC,kBAAkB,CAAC,EAAE,MAAM,CAAC;IAC5B,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,mBAAmB,CAAC,EAAE,MAAM,CAAC;IAC7B,YAAY,CAAC,EAAE,OAAO,CAAC;IACvB,eAAe,CAAC,EAAE,MAAM,CAAC;CAC1B;AAED,KAAK,aAAa,GAAG,MAAM,CAAC,MAAM,EAAE,qBAAqB,CAAC,CAAC;AAE3D;;;;GAIG;AACH,wBAAgB,YAAY,CAC1B,UAAU,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,EACnC,WAAW,EAAE,aAAa,GACzB,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAWzB"}
|
|
@@ -1,31 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Deep-merges Monaco-specific JSON Schema extensions into a base schema.
|
|
3
|
-
* Keys in the enrichment map are dot-paths (e.g., 'properties.sources').
|
|
4
|
-
* Empty string '' targets the root. Does not mutate the original.
|
|
5
|
-
*/
|
|
6
|
-
export function enrichSchema(baseSchema, enrichments) {
|
|
7
|
-
const schema = JSON.parse(JSON.stringify(baseSchema));
|
|
8
|
-
for (const [path, extensions] of Object.entries(enrichments)) {
|
|
9
|
-
const target = path === '' ? schema : getNestedObject(schema, path);
|
|
10
|
-
if (target && typeof target === 'object') {
|
|
11
|
-
Object.assign(target, extensions);
|
|
12
|
-
}
|
|
13
|
-
}
|
|
14
|
-
return schema;
|
|
15
|
-
}
|
|
16
|
-
function getNestedObject(obj, path) {
|
|
17
|
-
const keys = path.split('.');
|
|
18
|
-
let current = obj;
|
|
19
|
-
for (const key of keys) {
|
|
20
|
-
if (current &&
|
|
21
|
-
typeof current === 'object' &&
|
|
22
|
-
key in current) {
|
|
23
|
-
current = current[key];
|
|
24
|
-
}
|
|
25
|
-
else {
|
|
26
|
-
return undefined;
|
|
27
|
-
}
|
|
28
|
-
}
|
|
29
|
-
return current;
|
|
30
|
-
}
|
|
31
|
-
//# sourceMappingURL=monaco-schema-enrichment.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"monaco-schema-enrichment.js","sourceRoot":"","sources":["../../src/utils/monaco-schema-enrichment.ts"],"names":[],"mappings":"AAoBA;;;;GAIG;AACH,MAAM,UAAU,YAAY,CAC1B,UAAmC,EACnC,WAA0B;IAE1B,MAAM,MAAM,GAAG,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,SAAS,CAAC,UAAU,CAAC,CAAC,CAAC;IAEtD,KAAK,MAAM,CAAC,IAAI,EAAE,UAAU,CAAC,IAAI,MAAM,CAAC,OAAO,CAAC,WAAW,CAAC,EAAE,CAAC;QAC7D,MAAM,MAAM,GAAG,IAAI,KAAK,EAAE,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,eAAe,CAAC,MAAM,EAAE,IAAI,CAAC,CAAC;QACpE,IAAI,MAAM,IAAI,OAAO,MAAM,KAAK,QAAQ,EAAE,CAAC;YACzC,MAAM,CAAC,MAAM,CAAC,MAAM,EAAE,UAAU,CAAC,CAAC;QACpC,CAAC;IACH,CAAC;IAED,OAAO,MAAM,CAAC;AAChB,CAAC;AAED,SAAS,eAAe,CACtB,GAA4B,EAC5B,IAAY;IAEZ,MAAM,IAAI,GAAG,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC;IAC7B,IAAI,OAAO,GAAY,GAAG,CAAC;IAC3B,KAAK,MAAM,GAAG,IAAI,IAAI,EAAE,CAAC;QACvB,IACE,OAAO;YACP,OAAO,OAAO,KAAK,QAAQ;YAC3B,GAAG,IAAK,OAAmC,EAC3C,CAAC;YACD,OAAO,GAAI,OAAmC,CAAC,GAAG,CAAC,CAAC;QACtD,CAAC;aAAM,CAAC;YACN,OAAO,SAAS,CAAC;QACnB,CAAC;IACH,CAAC;IACD,OAAO,OAA8C,CAAC;AACxD,CAAC"}
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
type AnySchema = Record<string, any>;
|
|
2
|
-
/**
|
|
3
|
-
* Takes the base Flow.Config JSON Schema (from @walkeros/core z.toJSONSchema())
|
|
4
|
-
* and returns an enriched version with Monaco-specific extensions.
|
|
5
|
-
*
|
|
6
|
-
* The actual schema uses anyOf[0] at the top level.
|
|
7
|
-
*/
|
|
8
|
-
export declare function enrichFlowConfigSchema(baseSchema: AnySchema): AnySchema;
|
|
9
|
-
export {};
|
|
10
|
-
//# sourceMappingURL=monaco-schema-flow-config.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"monaco-schema-flow-config.d.ts","sourceRoot":"","sources":["../../src/utils/monaco-schema-flow-config.ts"],"names":[],"mappings":"AAGA,KAAK,SAAS,GAAG,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAC;AAErC;;;;;GAKG;AACH,wBAAgB,sBAAsB,CAAC,UAAU,EAAE,SAAS,GAAG,SAAS,CA8MvE"}
|