@finos/legend-application-studio 25.0.7 → 26.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/application/LegendStudio.d.ts.map +1 -1
- package/lib/application/LegendStudio.js +2 -0
- package/lib/application/LegendStudio.js.map +1 -1
- package/lib/components/editor/editor-group/GenerationSpecificationEditor.d.ts.map +1 -1
- package/lib/components/editor/editor-group/GenerationSpecificationEditor.js +5 -5
- package/lib/components/editor/editor-group/GenerationSpecificationEditor.js.map +1 -1
- package/lib/components/editor/editor-group/GrammarTextEditor.d.ts.map +1 -1
- package/lib/components/editor/editor-group/GrammarTextEditor.js +1 -28
- package/lib/components/editor/editor-group/GrammarTextEditor.js.map +1 -1
- package/lib/components/editor/editor-group/ModelImporter.d.ts.map +1 -1
- package/lib/components/editor/editor-group/ModelImporter.js +4 -4
- package/lib/components/editor/editor-group/ModelImporter.js.map +1 -1
- package/lib/components/editor/editor-group/RuntimeEditor.d.ts.map +1 -1
- package/lib/components/editor/editor-group/RuntimeEditor.js +2 -2
- package/lib/components/editor/editor-group/RuntimeEditor.js.map +1 -1
- package/lib/components/editor/editor-group/UnsupportedElementEditor.d.ts.map +1 -1
- package/lib/components/editor/editor-group/UnsupportedElementEditor.js +3 -3
- package/lib/components/editor/editor-group/UnsupportedElementEditor.js.map +1 -1
- package/lib/components/editor/editor-group/connection-editor/DatabaseBuilder.d.ts.map +1 -1
- package/lib/components/editor/editor-group/connection-editor/DatabaseBuilder.js +1 -0
- package/lib/components/editor/editor-group/connection-editor/DatabaseBuilder.js.map +1 -1
- package/lib/components/editor/editor-group/connection-editor/RelationalDatabaseConnectionEditor.d.ts.map +1 -1
- package/lib/components/editor/editor-group/connection-editor/RelationalDatabaseConnectionEditor.js +13 -11
- package/lib/components/editor/editor-group/connection-editor/RelationalDatabaseConnectionEditor.js.map +1 -1
- package/lib/components/editor/editor-group/element-generation-editor/FileGenerationEditor.d.ts.map +1 -1
- package/lib/components/editor/editor-group/element-generation-editor/FileGenerationEditor.js +11 -22
- package/lib/components/editor/editor-group/element-generation-editor/FileGenerationEditor.js.map +1 -1
- package/lib/components/editor/editor-group/mapping-editor/ClassMappingEditor.d.ts.map +1 -1
- package/lib/components/editor/editor-group/mapping-editor/ClassMappingEditor.js +7 -3
- package/lib/components/editor/editor-group/mapping-editor/ClassMappingEditor.js.map +1 -1
- package/lib/components/editor/editor-group/mapping-editor/DEPRECATED__MappingTestEditor.d.ts.map +1 -1
- package/lib/components/editor/editor-group/mapping-editor/DEPRECATED__MappingTestEditor.js +1 -4
- package/lib/components/editor/editor-group/mapping-editor/DEPRECATED__MappingTestEditor.js.map +1 -1
- package/lib/components/editor/editor-group/mapping-editor/InstanceSetImplementationEditor.d.ts.map +1 -1
- package/lib/components/editor/editor-group/mapping-editor/InstanceSetImplementationEditor.js +2 -2
- package/lib/components/editor/editor-group/mapping-editor/InstanceSetImplementationEditor.js.map +1 -1
- package/lib/components/editor/editor-group/project-configuration-editor/ProjectDependencyEditor.d.ts.map +1 -1
- package/lib/components/editor/editor-group/project-configuration-editor/ProjectDependencyEditor.js +3 -3
- package/lib/components/editor/editor-group/project-configuration-editor/ProjectDependencyEditor.js.map +1 -1
- package/lib/components/editor/editor-group/service-editor/BulkServiceRegistrationEditor.d.ts.map +1 -1
- package/lib/components/editor/editor-group/service-editor/BulkServiceRegistrationEditor.js +5 -10
- package/lib/components/editor/editor-group/service-editor/BulkServiceRegistrationEditor.js.map +1 -1
- package/lib/components/editor/editor-group/service-editor/ServiceExecutionQueryEditor.d.ts.map +1 -1
- package/lib/components/editor/editor-group/service-editor/ServiceExecutionQueryEditor.js +1 -4
- package/lib/components/editor/editor-group/service-editor/ServiceExecutionQueryEditor.js.map +1 -1
- package/lib/components/editor/editor-group/service-editor/ServicePostValidationEditor.d.ts.map +1 -1
- package/lib/components/editor/editor-group/service-editor/ServicePostValidationEditor.js +2 -2
- package/lib/components/editor/editor-group/service-editor/ServicePostValidationEditor.js.map +1 -1
- package/lib/components/editor/editor-group/service-editor/ServiceRegistrationEditor.d.ts.map +1 -1
- package/lib/components/editor/editor-group/service-editor/ServiceRegistrationEditor.js +2 -1
- package/lib/components/editor/editor-group/service-editor/ServiceRegistrationEditor.js.map +1 -1
- package/lib/components/editor/editor-group/uml-editor/AssociationEditor.d.ts.map +1 -1
- package/lib/components/editor/editor-group/uml-editor/AssociationEditor.js +2 -2
- package/lib/components/editor/editor-group/uml-editor/AssociationEditor.js.map +1 -1
- package/lib/components/editor/editor-group/uml-editor/ClassQueryBuilder.js +2 -2
- package/lib/components/editor/editor-group/uml-editor/ClassQueryBuilder.js.map +1 -1
- package/lib/components/editor/side-bar/Explorer.d.ts.map +1 -1
- package/lib/components/editor/side-bar/Explorer.js +14 -5
- package/lib/components/editor/side-bar/Explorer.js.map +1 -1
- package/lib/components/editor/side-bar/ProjectOverview.d.ts.map +1 -1
- package/lib/components/editor/side-bar/ProjectOverview.js +0 -5
- package/lib/components/editor/side-bar/ProjectOverview.js.map +1 -1
- package/lib/components/editor/side-bar/testable/GlobalTestRunner.d.ts.map +1 -1
- package/lib/components/editor/side-bar/testable/GlobalTestRunner.js +2 -2
- package/lib/components/editor/side-bar/testable/GlobalTestRunner.js.map +1 -1
- package/lib/components/extensions/Core_LegendStudioApplicationPlugin.d.ts.map +1 -1
- package/lib/components/extensions/Core_LegendStudioApplicationPlugin.js +0 -3
- package/lib/components/extensions/Core_LegendStudioApplicationPlugin.js.map +1 -1
- package/lib/components/extensions/DSL_ExternalFormat_LegendStudioApplicationPlugin.d.ts +1 -3
- package/lib/components/extensions/DSL_ExternalFormat_LegendStudioApplicationPlugin.d.ts.map +1 -1
- package/lib/components/extensions/DSL_ExternalFormat_LegendStudioApplicationPlugin.js +0 -16
- package/lib/components/extensions/DSL_ExternalFormat_LegendStudioApplicationPlugin.js.map +1 -1
- package/lib/index.css +2 -2
- package/lib/index.css.map +1 -1
- package/lib/index.d.ts +0 -1
- package/lib/index.d.ts.map +1 -1
- package/lib/index.js +0 -1
- package/lib/index.js.map +1 -1
- package/lib/package.json +1 -1
- package/lib/stores/LegendStudioApplicationPlugin.d.ts +0 -8
- package/lib/stores/LegendStudioApplicationPlugin.d.ts.map +1 -1
- package/lib/stores/LegendStudioBaseStore.d.ts +1 -0
- package/lib/stores/LegendStudioBaseStore.d.ts.map +1 -1
- package/lib/stores/LegendStudioBaseStore.js +7 -4
- package/lib/stores/LegendStudioBaseStore.js.map +1 -1
- package/lib/stores/editor/EditorGraphState.d.ts.map +1 -1
- package/lib/stores/editor/EditorGraphState.js +2 -2
- package/lib/stores/editor/EditorGraphState.js.map +1 -1
- package/lib/stores/editor/EditorSDLCState.d.ts +8 -5
- package/lib/stores/editor/EditorSDLCState.d.ts.map +1 -1
- package/lib/stores/editor/EditorSDLCState.js +25 -5
- package/lib/stores/editor/EditorSDLCState.js.map +1 -1
- package/lib/stores/editor/EditorStore.d.ts +0 -2
- package/lib/stores/editor/EditorStore.d.ts.map +1 -1
- package/lib/stores/editor/EditorStore.js +10 -15
- package/lib/stores/editor/EditorStore.js.map +1 -1
- package/lib/stores/editor/EditorTabManagerState.d.ts.map +1 -1
- package/lib/stores/editor/EditorTabManagerState.js +1 -1
- package/lib/stores/editor/EditorTabManagerState.js.map +1 -1
- package/lib/stores/editor/ExplorerTreeState.d.ts +5 -1
- package/lib/stores/editor/ExplorerTreeState.d.ts.map +1 -1
- package/lib/stores/editor/ExplorerTreeState.js +13 -0
- package/lib/stores/editor/ExplorerTreeState.js.map +1 -1
- package/lib/stores/editor/GraphEditGrammarModeState.d.ts +0 -3
- package/lib/stores/editor/GraphEditGrammarModeState.d.ts.map +1 -1
- package/lib/stores/editor/GraphEditGrammarModeState.js +26 -21
- package/lib/stores/editor/GraphEditGrammarModeState.js.map +1 -1
- package/lib/stores/editor/editor-state/GrammarTextEditorState.d.ts +3 -4
- package/lib/stores/editor/editor-state/GrammarTextEditorState.d.ts.map +1 -1
- package/lib/stores/editor/editor-state/GrammarTextEditorState.js +5 -111
- package/lib/stores/editor/editor-state/GrammarTextEditorState.js.map +1 -1
- package/lib/stores/editor/editor-state/element-editor-state/connection/ConnectionEditorState.d.ts +2 -4
- package/lib/stores/editor/editor-state/element-editor-state/connection/ConnectionEditorState.d.ts.map +1 -1
- package/lib/stores/editor/editor-state/element-editor-state/connection/ConnectionEditorState.js +6 -8
- package/lib/stores/editor/editor-state/element-editor-state/connection/ConnectionEditorState.js.map +1 -1
- package/lib/stores/editor/editor-state/element-editor-state/connection/DatabaseBuilderState.d.ts +4 -2
- package/lib/stores/editor/editor-state/element-editor-state/connection/DatabaseBuilderState.d.ts.map +1 -1
- package/lib/stores/editor/editor-state/element-editor-state/connection/DatabaseBuilderState.js +8 -4
- package/lib/stores/editor/editor-state/element-editor-state/connection/DatabaseBuilderState.js.map +1 -1
- package/lib/stores/editor/editor-state/element-editor-state/data/DataEditorState.d.ts +4 -7
- package/lib/stores/editor/editor-state/element-editor-state/data/DataEditorState.d.ts.map +1 -1
- package/lib/stores/editor/editor-state/element-editor-state/data/DataEditorState.js +0 -3
- package/lib/stores/editor/editor-state/element-editor-state/data/DataEditorState.js.map +1 -1
- package/lib/stores/editor/editor-state/element-editor-state/mapping/DEPRECATED__MappingTestState.d.ts +1 -0
- package/lib/stores/editor/editor-state/element-editor-state/mapping/DEPRECATED__MappingTestState.d.ts.map +1 -1
- package/lib/stores/editor/editor-state/element-editor-state/mapping/DEPRECATED__MappingTestState.js +19 -2
- package/lib/stores/editor/editor-state/element-editor-state/mapping/DEPRECATED__MappingTestState.js.map +1 -1
- package/lib/stores/editor/editor-state/element-editor-state/mapping/FlatDataInstanceSetImplementationState.js +1 -1
- package/lib/stores/editor/editor-state/element-editor-state/mapping/FlatDataInstanceSetImplementationState.js.map +1 -1
- package/lib/stores/editor/editor-state/element-editor-state/mapping/MappingEditorState.d.ts.map +1 -1
- package/lib/stores/editor/editor-state/element-editor-state/mapping/MappingEditorState.js +5 -2
- package/lib/stores/editor/editor-state/element-editor-state/mapping/MappingEditorState.js.map +1 -1
- package/lib/stores/editor/editor-state/element-editor-state/mapping/MappingElementDecorator.d.ts +3 -1
- package/lib/stores/editor/editor-state/element-editor-state/mapping/MappingElementDecorator.d.ts.map +1 -1
- package/lib/stores/editor/editor-state/element-editor-state/mapping/MappingElementDecorator.js +6 -0
- package/lib/stores/editor/editor-state/element-editor-state/mapping/MappingElementDecorator.js.map +1 -1
- package/lib/stores/editor/editor-state/element-editor-state/mapping/relational/RelationalInstanceSetImplementationState.js +1 -1
- package/lib/stores/editor/editor-state/element-editor-state/mapping/relational/RelationalInstanceSetImplementationState.js.map +1 -1
- package/lib/stores/editor/editor-state/element-editor-state/service/ServiceExecutionState.d.ts +1 -0
- package/lib/stores/editor/editor-state/element-editor-state/service/ServiceExecutionState.d.ts.map +1 -1
- package/lib/stores/editor/editor-state/element-editor-state/service/ServiceExecutionState.js +23 -3
- package/lib/stores/editor/editor-state/element-editor-state/service/ServiceExecutionState.js.map +1 -1
- package/lib/stores/editor/editor-state/element-editor-state/service/ServiceRegistrationState.d.ts.map +1 -1
- package/lib/stores/editor/editor-state/element-editor-state/service/ServiceRegistrationState.js +4 -3
- package/lib/stores/editor/editor-state/element-editor-state/service/ServiceRegistrationState.js.map +1 -1
- package/lib/stores/editor/editor-state/project-configuration-editor-state/ProjectConfigurationEditorState.d.ts +3 -4
- package/lib/stores/editor/editor-state/project-configuration-editor-state/ProjectConfigurationEditorState.d.ts.map +1 -1
- package/lib/stores/editor/editor-state/project-configuration-editor-state/ProjectConfigurationEditorState.js +2 -4
- package/lib/stores/editor/editor-state/project-configuration-editor-state/ProjectConfigurationEditorState.js.map +1 -1
- package/lib/stores/editor/sidebar-state/ProjectOverviewState.d.ts +0 -4
- package/lib/stores/editor/sidebar-state/ProjectOverviewState.d.ts.map +1 -1
- package/lib/stores/editor/sidebar-state/ProjectOverviewState.js +0 -48
- package/lib/stores/editor/sidebar-state/ProjectOverviewState.js.map +1 -1
- package/lib/stores/editor/sidebar-state/WorkspaceUpdateConflictResolutionState.d.ts +1 -1
- package/lib/stores/editor/sidebar-state/WorkspaceUpdateConflictResolutionState.d.ts.map +1 -1
- package/lib/stores/editor/sidebar-state/WorkspaceUpdateConflictResolutionState.js +1 -4
- package/lib/stores/editor/sidebar-state/WorkspaceUpdateConflictResolutionState.js.map +1 -1
- package/lib/stores/editor/utils/ModelClassifierUtils.d.ts +2 -1
- package/lib/stores/editor/utils/ModelClassifierUtils.d.ts.map +1 -1
- package/lib/stores/editor/utils/ModelClassifierUtils.js +2 -1
- package/lib/stores/editor/utils/ModelClassifierUtils.js.map +1 -1
- package/lib/stores/editor/utils/TestableUtils.d.ts +3 -1
- package/lib/stores/editor/utils/TestableUtils.d.ts.map +1 -1
- package/lib/stores/editor/utils/TestableUtils.js +6 -0
- package/lib/stores/editor/utils/TestableUtils.js.map +1 -1
- package/lib/stores/graph-modifier/STO_Relational_GraphModifierHelper.d.ts +2 -2
- package/lib/stores/graph-modifier/STO_Relational_GraphModifierHelper.d.ts.map +1 -1
- package/lib/stores/graph-modifier/STO_Relational_GraphModifierHelper.js.map +1 -1
- package/lib/stores/project-view/ProjectViewerStore.d.ts.map +1 -1
- package/lib/stores/project-view/ProjectViewerStore.js +8 -5
- package/lib/stores/project-view/ProjectViewerStore.js.map +1 -1
- package/package.json +11 -11
- package/src/application/LegendStudio.tsx +2 -0
- package/src/components/editor/editor-group/GenerationSpecificationEditor.tsx +21 -22
- package/src/components/editor/editor-group/GrammarTextEditor.tsx +1 -41
- package/src/components/editor/editor-group/ModelImporter.tsx +13 -10
- package/src/components/editor/editor-group/RuntimeEditor.tsx +2 -9
- package/src/components/editor/editor-group/UnsupportedElementEditor.tsx +16 -10
- package/src/components/editor/editor-group/connection-editor/DatabaseBuilder.tsx +3 -0
- package/src/components/editor/editor-group/connection-editor/RelationalDatabaseConnectionEditor.tsx +22 -23
- package/src/components/editor/editor-group/element-generation-editor/FileGenerationEditor.tsx +51 -83
- package/src/components/editor/editor-group/mapping-editor/ClassMappingEditor.tsx +23 -8
- package/src/components/editor/editor-group/mapping-editor/DEPRECATED__MappingTestEditor.tsx +5 -4
- package/src/components/editor/editor-group/mapping-editor/InstanceSetImplementationEditor.tsx +39 -29
- package/src/components/editor/editor-group/project-configuration-editor/ProjectDependencyEditor.tsx +21 -23
- package/src/components/editor/editor-group/service-editor/BulkServiceRegistrationEditor.tsx +24 -55
- package/src/components/editor/editor-group/service-editor/ServiceExecutionQueryEditor.tsx +3 -4
- package/src/components/editor/editor-group/service-editor/ServicePostValidationEditor.tsx +20 -24
- package/src/components/editor/editor-group/service-editor/ServiceRegistrationEditor.tsx +4 -1
- package/src/components/editor/editor-group/uml-editor/AssociationEditor.tsx +5 -4
- package/src/components/editor/editor-group/uml-editor/ClassQueryBuilder.tsx +3 -3
- package/src/components/editor/side-bar/Explorer.tsx +40 -2
- package/src/components/editor/side-bar/ProjectOverview.tsx +0 -5
- package/src/components/editor/side-bar/testable/GlobalTestRunner.tsx +2 -4
- package/src/components/extensions/Core_LegendStudioApplicationPlugin.tsx +0 -8
- package/src/components/extensions/DSL_ExternalFormat_LegendStudioApplicationPlugin.tsx +0 -18
- package/src/index.ts +0 -1
- package/src/stores/LegendStudioApplicationPlugin.ts +0 -10
- package/src/stores/LegendStudioBaseStore.ts +7 -4
- package/src/stores/editor/EditorGraphState.ts +2 -4
- package/src/stores/editor/EditorSDLCState.ts +33 -4
- package/src/stores/editor/EditorStore.ts +24 -19
- package/src/stores/editor/EditorTabManagerState.ts +1 -4
- package/src/stores/editor/ExplorerTreeState.ts +22 -0
- package/src/stores/editor/GraphEditGrammarModeState.ts +49 -39
- package/src/stores/editor/editor-state/GrammarTextEditorState.ts +6 -145
- package/src/stores/editor/editor-state/element-editor-state/connection/ConnectionEditorState.ts +8 -18
- package/src/stores/editor/editor-state/element-editor-state/connection/DatabaseBuilderState.ts +17 -4
- package/src/stores/editor/editor-state/element-editor-state/data/DataEditorState.ts +5 -7
- package/src/stores/editor/editor-state/element-editor-state/mapping/DEPRECATED__MappingTestState.ts +24 -2
- package/src/stores/editor/editor-state/element-editor-state/mapping/FlatDataInstanceSetImplementationState.ts +1 -1
- package/src/stores/editor/editor-state/element-editor-state/mapping/MappingEditorState.ts +4 -1
- package/src/stores/editor/editor-state/element-editor-state/mapping/MappingElementDecorator.ts +13 -0
- package/src/stores/editor/editor-state/element-editor-state/mapping/relational/RelationalInstanceSetImplementationState.ts +1 -1
- package/src/stores/editor/editor-state/element-editor-state/service/ServiceExecutionState.ts +30 -7
- package/src/stores/editor/editor-state/element-editor-state/service/ServiceRegistrationState.ts +7 -5
- package/src/stores/editor/editor-state/project-configuration-editor-state/ProjectConfigurationEditorState.ts +4 -5
- package/src/stores/editor/sidebar-state/ProjectOverviewState.ts +0 -87
- package/src/stores/editor/sidebar-state/WorkspaceUpdateConflictResolutionState.ts +3 -7
- package/src/stores/editor/utils/ModelClassifierUtils.ts +3 -1
- package/src/stores/editor/utils/TestableUtils.ts +13 -0
- package/src/stores/graph-modifier/STO_Relational_GraphModifierHelper.ts +1 -2
- package/src/stores/project-view/ProjectViewerStore.ts +10 -8
- package/tsconfig.json +0 -3
- package/lib/components/editor/side-bar/ProjectDependantsEditor.d.ts +0 -19
- package/lib/components/editor/side-bar/ProjectDependantsEditor.d.ts.map +0 -1
- package/lib/components/editor/side-bar/ProjectDependantsEditor.js +0 -76
- package/lib/components/editor/side-bar/ProjectDependantsEditor.js.map +0 -1
- package/lib/stores/editor/EditorDepotState.d.ts +0 -25
- package/lib/stores/editor/EditorDepotState.d.ts.map +0 -1
- package/lib/stores/editor/EditorDepotState.js +0 -49
- package/lib/stores/editor/EditorDepotState.js.map +0 -1
- package/lib/stores/editor/sidebar-state/ProjectDependantEditorState.d.ts +0 -31
- package/lib/stores/editor/sidebar-state/ProjectDependantEditorState.d.ts.map +0 -1
- package/lib/stores/editor/sidebar-state/ProjectDependantEditorState.js +0 -42
- package/lib/stores/editor/sidebar-state/ProjectDependantEditorState.js.map +0 -1
- package/src/components/editor/side-bar/ProjectDependantsEditor.tsx +0 -219
- package/src/stores/editor/EditorDepotState.ts +0 -70
- package/src/stores/editor/sidebar-state/ProjectDependantEditorState.ts +0 -50
@@ -36,6 +36,10 @@ import {
|
|
36
36
|
ResizablePanelSplitterLine,
|
37
37
|
TimesIcon,
|
38
38
|
clsx,
|
39
|
+
Panel,
|
40
|
+
PanelHeader,
|
41
|
+
PanelHeaderActions,
|
42
|
+
PanelHeaderActionItem,
|
39
43
|
} from '@finos/legend-art';
|
40
44
|
import type { PostValidation } from '@finos/legend-graph';
|
41
45
|
import { forwardRef, useEffect, useState } from 'react';
|
@@ -395,31 +399,25 @@ export const ServicePostValidationsEditor = observer(
|
|
395
399
|
}, [validationState]);
|
396
400
|
return (
|
397
401
|
<div className="service-post-validation-editor">
|
398
|
-
<
|
399
|
-
<div className="panel__header__title">
|
400
|
-
<div className="panel__header__title__label">Post Validations</div>
|
401
|
-
</div>
|
402
|
-
</div>
|
402
|
+
<PanelHeader title="Post validations" />
|
403
403
|
<div className="service-test-editor__content">
|
404
404
|
<ResizablePanelGroup orientation="vertical">
|
405
405
|
<ResizablePanel minSize={100} size={300}>
|
406
|
-
<
|
406
|
+
<PanelHeader>
|
407
407
|
<div className="panel__header__title">
|
408
408
|
<div className="panel__header__title__label">
|
409
409
|
Post Validations
|
410
410
|
</div>
|
411
411
|
</div>
|
412
|
-
<
|
413
|
-
<
|
414
|
-
className="panel__header__action"
|
415
|
-
tabIndex={-1}
|
412
|
+
<PanelHeaderActions>
|
413
|
+
<PanelHeaderActionItem
|
416
414
|
onClick={addPostValidation}
|
417
415
|
title="Add Post Validations"
|
418
416
|
>
|
419
417
|
<PlusIcon />
|
420
|
-
</
|
421
|
-
</
|
422
|
-
</
|
418
|
+
</PanelHeaderActionItem>
|
419
|
+
</PanelHeaderActions>
|
420
|
+
</PanelHeader>
|
423
421
|
<PanelContent>
|
424
422
|
{service.postValidations.map((postValidation, _idx) => (
|
425
423
|
<PostValidationItem
|
@@ -444,15 +442,13 @@ export const ServicePostValidationsEditor = observer(
|
|
444
442
|
<ResizablePanelSplitterLine color="var(--color-dark-grey-200)" />
|
445
443
|
</ResizablePanelSplitter>
|
446
444
|
<ResizablePanel>
|
447
|
-
<
|
448
|
-
<
|
449
|
-
|
450
|
-
|
451
|
-
|
452
|
-
|
453
|
-
|
454
|
-
</div>
|
455
|
-
<div className="service-test-editor__content">
|
445
|
+
<Panel className="service-test-editor">
|
446
|
+
<PanelHeader
|
447
|
+
className="service-test-suite-editor__header"
|
448
|
+
title="valiation"
|
449
|
+
labelClassName="service-test-suite-editor__header__title__label--tests-suites"
|
450
|
+
/>
|
451
|
+
<PanelContent className="service-test-editor__content">
|
456
452
|
{validationState.selectedPostValidationState && (
|
457
453
|
<ServicePostValidationEditor
|
458
454
|
postValidationState={
|
@@ -469,8 +465,8 @@ export const ServicePostValidationsEditor = observer(
|
|
469
465
|
tooltipText="Click to add post validation"
|
470
466
|
/>
|
471
467
|
)}
|
472
|
-
</
|
473
|
-
</
|
468
|
+
</PanelContent>
|
469
|
+
</Panel>
|
474
470
|
</ResizablePanel>
|
475
471
|
</ResizablePanelGroup>
|
476
472
|
</div>
|
@@ -285,7 +285,10 @@ export const ServiceRegistrationEditor = observer(() => {
|
|
285
285
|
darkMode={true}
|
286
286
|
disabled={registrationState.versionOptions === undefined}
|
287
287
|
placeholder={versionPlaceholder}
|
288
|
-
isLoading={
|
288
|
+
isLoading={
|
289
|
+
editorStore.sdlcState.fetchPublishedProjectVersionsState
|
290
|
+
.isInProgress
|
291
|
+
}
|
289
292
|
/>
|
290
293
|
</div>
|
291
294
|
</div>
|
@@ -44,6 +44,7 @@ import {
|
|
44
44
|
PanelDropZone,
|
45
45
|
Panel,
|
46
46
|
InfoCircleIcon,
|
47
|
+
PanelHeader,
|
47
48
|
} from '@finos/legend-art';
|
48
49
|
import { getElementIcon } from '../../../ElementIconUtils.js';
|
49
50
|
import { prettyCONSTName, guaranteeType } from '@finos/legend-shared';
|
@@ -512,7 +513,7 @@ export const AssociationEditor = observer(
|
|
512
513
|
minSize={56}
|
513
514
|
>
|
514
515
|
<Panel>
|
515
|
-
<
|
516
|
+
<PanelHeader>
|
516
517
|
<div className="panel__header__title">
|
517
518
|
{isReadOnly && (
|
518
519
|
<div className="uml-element-editor__header__lock">
|
@@ -524,8 +525,8 @@ export const AssociationEditor = observer(
|
|
524
525
|
{association.name}
|
525
526
|
</div>
|
526
527
|
</div>
|
527
|
-
</
|
528
|
-
<
|
528
|
+
</PanelHeader>
|
529
|
+
<PanelHeader className="uml-element-editor__tabs__header">
|
529
530
|
<div className="uml-element-editor__tabs">
|
530
531
|
{tabs.map((tab) => (
|
531
532
|
<div
|
@@ -552,7 +553,7 @@ export const AssociationEditor = observer(
|
|
552
553
|
<PlusIcon />
|
553
554
|
</button>
|
554
555
|
</div>
|
555
|
-
</
|
556
|
+
</PanelHeader>
|
556
557
|
<div
|
557
558
|
className={clsx('panel__content', {
|
558
559
|
'panel__content--with-backdrop-element':
|
@@ -274,7 +274,7 @@ const PromoteToServiceQueryBuilderAction = observer(
|
|
274
274
|
!queryBuilderState.allValidationIssues.length,
|
275
275
|
);
|
276
276
|
|
277
|
-
const
|
277
|
+
const renderSaveAsModal = (): React.ReactNode => {
|
278
278
|
if (
|
279
279
|
promoteQueryModal === PROMOTE_QUERY_TYPE.SERVICE &&
|
280
280
|
queryBuilderState.mapping
|
@@ -355,11 +355,11 @@ const PromoteToServiceQueryBuilderAction = observer(
|
|
355
355
|
}}
|
356
356
|
>
|
357
357
|
<div className="query-builder__sub-header__custom-action__label">
|
358
|
-
|
358
|
+
Save As...
|
359
359
|
</div>
|
360
360
|
<CaretDownIcon className="query-builder__sub-header__custom-action__icon" />
|
361
361
|
</DropdownMenu>
|
362
|
-
{
|
362
|
+
{renderSaveAsModal()}
|
363
363
|
</>
|
364
364
|
);
|
365
365
|
},
|
@@ -30,7 +30,6 @@ import {
|
|
30
30
|
PanelLoadingIndicator,
|
31
31
|
BlankPanelContent,
|
32
32
|
TreeView,
|
33
|
-
ProjectConfigurationIcon,
|
34
33
|
ChevronDownIcon,
|
35
34
|
ChevronRightIcon,
|
36
35
|
CompressIcon,
|
@@ -98,6 +97,9 @@ import {
|
|
98
97
|
getFunctionSignature,
|
99
98
|
getFunctionNameWithPath,
|
100
99
|
getElementRootPackage,
|
100
|
+
type PackageableElement,
|
101
|
+
PackageableConnection,
|
102
|
+
RelationalDatabaseConnection,
|
101
103
|
} from '@finos/legend-graph';
|
102
104
|
import { useApplicationStore } from '@finos/legend-application';
|
103
105
|
import {
|
@@ -120,6 +122,8 @@ import {
|
|
120
122
|
CODE_EDITOR_LANGUAGE,
|
121
123
|
CodeEditor,
|
122
124
|
} from '@finos/legend-lego/code-editor';
|
125
|
+
import { guaranteeRelationalDatabaseConnection } from '../../../stores/editor/editor-state/element-editor-state/connection/DatabaseBuilderState.js';
|
126
|
+
import { DatabaseBuilder } from '../editor-group/connection-editor/DatabaseBuilder.js';
|
123
127
|
|
124
128
|
const ElementRenamer = observer(() => {
|
125
129
|
const editorStore = useEditorStore();
|
@@ -431,6 +435,12 @@ const SampleDataGenerator = observer(() => {
|
|
431
435
|
);
|
432
436
|
});
|
433
437
|
|
438
|
+
const isRelationalDatabaseConnection = (
|
439
|
+
val: PackageableElement | undefined,
|
440
|
+
): boolean =>
|
441
|
+
val instanceof PackageableConnection &&
|
442
|
+
val.connectionValue instanceof RelationalDatabaseConnection;
|
443
|
+
|
434
444
|
const ExplorerContextMenu = observer(
|
435
445
|
forwardRef<
|
436
446
|
HTMLDivElement,
|
@@ -492,6 +502,16 @@ const ExplorerContextMenu = observer(
|
|
492
502
|
}
|
493
503
|
},
|
494
504
|
);
|
505
|
+
const buildDatabase = editorStore.applicationStore.guardUnhandledError(
|
506
|
+
async () => {
|
507
|
+
if (isRelationalDatabaseConnection(node?.packageableElement)) {
|
508
|
+
editorStore.explorerTreeState.buildDbBuilderState(
|
509
|
+
guaranteeRelationalDatabaseConnection(node?.packageableElement),
|
510
|
+
editorStore.isInViewerMode,
|
511
|
+
);
|
512
|
+
}
|
513
|
+
},
|
514
|
+
);
|
495
515
|
const removeElement = (): void => {
|
496
516
|
if (node) {
|
497
517
|
flowResult(
|
@@ -701,6 +721,14 @@ const ExplorerContextMenu = observer(
|
|
701
721
|
<MenuContentDivider />
|
702
722
|
</>
|
703
723
|
)}
|
724
|
+
{isRelationalDatabaseConnection(node.packageableElement) && (
|
725
|
+
<>
|
726
|
+
<MenuContentItem onClick={buildDatabase}>
|
727
|
+
Build Database...
|
728
|
+
</MenuContentItem>
|
729
|
+
<MenuContentDivider />
|
730
|
+
</>
|
731
|
+
)}
|
704
732
|
{extraExplorerContextMenuItems}
|
705
733
|
{Boolean(extraExplorerContextMenuItems.length) && (
|
706
734
|
<MenuContentDivider />
|
@@ -753,7 +781,9 @@ const ProjectConfig = observer(() => {
|
|
753
781
|
>
|
754
782
|
<div className="tree-view__node__icon explorer__package-tree__node__icon">
|
755
783
|
<div className="explorer__package-tree__node__icon__type explorer__config__icon">
|
756
|
-
<
|
784
|
+
<div>
|
785
|
+
<SettingsEthernetIcon />
|
786
|
+
</div>
|
757
787
|
</div>
|
758
788
|
</div>
|
759
789
|
<button
|
@@ -1013,6 +1043,14 @@ const ExplorerTrees = observer(() => {
|
|
1013
1043
|
/>
|
1014
1044
|
<ElementRenamer />
|
1015
1045
|
<SampleDataGenerator />
|
1046
|
+
{editorStore.explorerTreeState.databaseBuilderState && (
|
1047
|
+
<DatabaseBuilder
|
1048
|
+
databaseBuilderState={
|
1049
|
+
editorStore.explorerTreeState.databaseBuilderState
|
1050
|
+
}
|
1051
|
+
isReadOnly={false}
|
1052
|
+
/>
|
1053
|
+
)}
|
1016
1054
|
{editorStore.projectConfigurationEditorState
|
1017
1055
|
.projectConfiguration && <ProjectConfig />}
|
1018
1056
|
{/* SYSTEM TREE */}
|
@@ -56,7 +56,6 @@ import {
|
|
56
56
|
import { useEditorStore } from '../EditorStoreProvider.js';
|
57
57
|
import { useApplicationStore } from '@finos/legend-application';
|
58
58
|
import { useLegendStudioApplicationStore } from '../../LegendStudioFrameworkProvider.js';
|
59
|
-
import { ProjectDependantsEditor } from './ProjectDependantsEditor.js';
|
60
59
|
|
61
60
|
const ShareProjectModal = observer(
|
62
61
|
(props: { open: boolean; closeModal: () => void }) => {
|
@@ -812,7 +811,6 @@ export const ProjectOverviewActivityBar = observer(() => {
|
|
812
811
|
mode: PROJECT_OVERVIEW_ACTIVITY_MODE.RELEASE,
|
813
812
|
title: 'Release',
|
814
813
|
},
|
815
|
-
{ mode: PROJECT_OVERVIEW_ACTIVITY_MODE.DEPENDANTS, title: 'Dependants' },
|
816
814
|
{ mode: PROJECT_OVERVIEW_ACTIVITY_MODE.VERSIONS, title: 'Versions' },
|
817
815
|
{ mode: PROJECT_OVERVIEW_ACTIVITY_MODE.WORKSPACES, title: 'Workspaces' },
|
818
816
|
].filter((activity): activity is ProjectOverviewActivityDisplay =>
|
@@ -863,9 +861,6 @@ export const ProjectOverview = observer(() => {
|
|
863
861
|
return <OverviewViewer />;
|
864
862
|
case PROJECT_OVERVIEW_ACTIVITY_MODE.RELEASE:
|
865
863
|
return <ReleaseEditor />;
|
866
|
-
// TODO: @xannem move this into dependency dashboard extension
|
867
|
-
case PROJECT_OVERVIEW_ACTIVITY_MODE.DEPENDANTS:
|
868
|
-
return <ProjectDependantsEditor />;
|
869
864
|
case PROJECT_OVERVIEW_ACTIVITY_MODE.VERSIONS:
|
870
865
|
return <VersionsViewer />;
|
871
866
|
case PROJECT_OVERVIEW_ACTIVITY_MODE.WORKSPACES:
|
@@ -496,9 +496,7 @@ export const GlobalTestRunner = observer(
|
|
496
496
|
const reset = (): void => globalTestRunnerState.init(true);
|
497
497
|
|
498
498
|
const renderTestRunnerTab = (): React.ReactNode => {
|
499
|
-
if (
|
500
|
-
selectedTab === GLOBAL_TEST_RUNNER_TABS.GLOBAL_TEST_RUNNER.valueOf()
|
501
|
-
) {
|
499
|
+
if (selectedTab === GLOBAL_TEST_RUNNER_TABS.GLOBAL_TEST_RUNNER) {
|
502
500
|
return (
|
503
501
|
<div
|
504
502
|
data-testid={LEGEND_STUDIO_TEST_ID.GLOBAL_TEST_RUNNER}
|
@@ -580,7 +578,7 @@ export const GlobalTestRunner = observer(
|
|
580
578
|
}
|
581
579
|
return (
|
582
580
|
<UnsupportedEditorPanel
|
583
|
-
text="Can't display this
|
581
|
+
text="Can't display this tab"
|
584
582
|
isReadOnly={true}
|
585
583
|
/>
|
586
584
|
);
|
@@ -60,14 +60,6 @@ export class Core_LegendStudioApplicationPlugin extends LegendStudioApplicationP
|
|
60
60
|
plugin as DSL_LegendStudioApplicationPlugin_Extension
|
61
61
|
).getExtraPureGrammarKeywords?.() ?? [],
|
62
62
|
),
|
63
|
-
extraParserKeywords: applicationStore.pluginManager
|
64
|
-
.getApplicationPlugins()
|
65
|
-
.flatMap(
|
66
|
-
(plugin) =>
|
67
|
-
(
|
68
|
-
plugin as DSL_LegendStudioApplicationPlugin_Extension
|
69
|
-
).getExtraPureGrammarParserNames?.() ?? [],
|
70
|
-
),
|
71
63
|
});
|
72
64
|
},
|
73
65
|
];
|
@@ -51,7 +51,6 @@ import {
|
|
51
51
|
type PureGrammarParserKeywordSuggestionGetter,
|
52
52
|
LegendStudioApplicationPlugin,
|
53
53
|
type DSL_LegendStudioApplicationPlugin_Extension,
|
54
|
-
type PureGrammarElementLabeler,
|
55
54
|
} from '../../stores/LegendStudioApplicationPlugin.js';
|
56
55
|
import type {
|
57
56
|
ConnectionEditorRenderer,
|
@@ -126,10 +125,6 @@ export class DSL_ExternalFormat_LegendStudioApplicationPlugin
|
|
126
125
|
];
|
127
126
|
}
|
128
127
|
|
129
|
-
getExtraPureGrammarParserNames(): string[] {
|
130
|
-
return [PURE_GRAMMAR_EXTERNAL_FORMAT_PARSER_NAME];
|
131
|
-
}
|
132
|
-
|
133
128
|
getExtraPureGrammarKeywords(): string[] {
|
134
129
|
return [
|
135
130
|
PURE_GRAMMAR_BINDING_ELEMENT_TYPE_LABEL,
|
@@ -138,19 +133,6 @@ export class DSL_ExternalFormat_LegendStudioApplicationPlugin
|
|
138
133
|
];
|
139
134
|
}
|
140
135
|
|
141
|
-
getExtraPureGrammarElementLabelers(): PureGrammarElementLabeler[] {
|
142
|
-
return [
|
143
|
-
(element): string | undefined => {
|
144
|
-
if (element instanceof Binding) {
|
145
|
-
return PURE_GRAMMAR_BINDING_ELEMENT_TYPE_LABEL;
|
146
|
-
} else if (element instanceof SchemaSet) {
|
147
|
-
return PURE_GRAMMAR_SCHEMA_SET_ELEMENT_TYPE_LABEL;
|
148
|
-
}
|
149
|
-
return undefined;
|
150
|
-
},
|
151
|
-
];
|
152
|
-
}
|
153
|
-
|
154
136
|
getExtraPureGrammarConnectionLabelers(): PureGrammarConnectionLabeler[] {
|
155
137
|
return [
|
156
138
|
(connection): string | undefined => {
|
package/src/index.ts
CHANGED
@@ -105,7 +105,6 @@ export {
|
|
105
105
|
FileGenerationState,
|
106
106
|
GeneratedFileStructureState,
|
107
107
|
} from './stores/editor/editor-state/FileGenerationState.js';
|
108
|
-
export { DSL_ExternalFormat_LegendStudioApplicationPlugin } from './components/extensions/DSL_ExternalFormat_LegendStudioApplicationPlugin.js';
|
109
108
|
export {
|
110
109
|
externalFormatData_setData,
|
111
110
|
externalFormatData_setContentType,
|
@@ -217,21 +217,11 @@ export type PureGrammarParserElementSnippetSuggestionsGetter = (
|
|
217
217
|
*/
|
218
218
|
export interface DSL_LegendStudioApplicationPlugin_Extension
|
219
219
|
extends LegendStudioApplicationPlugin {
|
220
|
-
/**
|
221
|
-
* Get the list of supported Pure grammar parsers.
|
222
|
-
*/
|
223
|
-
getExtraPureGrammarParserNames?(): string[];
|
224
|
-
|
225
220
|
/**
|
226
221
|
* Get the list of supported Pure grammar keywords.
|
227
222
|
*/
|
228
223
|
getExtraPureGrammarKeywords?(): string[];
|
229
224
|
|
230
|
-
/**
|
231
|
-
* Get the list of Pure grammar element labelers.
|
232
|
-
*/
|
233
|
-
getExtraPureGrammarElementLabelers?(): PureGrammarElementLabeler[];
|
234
|
-
|
235
225
|
/**
|
236
226
|
* Get the list of the supported packageable element type specifiers.
|
237
227
|
*/
|
@@ -62,6 +62,7 @@ export class LegendStudioBaseStore {
|
|
62
62
|
readonly initState = ActionState.create();
|
63
63
|
|
64
64
|
isSDLCAuthorized: boolean | undefined = false;
|
65
|
+
private isSDLCServerInitialized = false;
|
65
66
|
SDLCServerTermsOfServicesUrlsToView: string[] = [];
|
66
67
|
|
67
68
|
constructor(applicationStore: LegendStudioApplicationStore) {
|
@@ -116,9 +117,11 @@ export class LegendStudioBaseStore {
|
|
116
117
|
// setup SDLC server client
|
117
118
|
yield flowResult(this.initializeSDLCServerClient());
|
118
119
|
|
119
|
-
//
|
120
|
-
//
|
121
|
-
|
120
|
+
// if SDLC server is not properly authorized/initialized, we would need to stop making call
|
121
|
+
// to SDLC server, as this could intertwine and mess up OIDC/OAuth authentication on the server
|
122
|
+
// See https://github.com/finos/legend-studio/pull/2205
|
123
|
+
// See https://github.com/finos/legend-sdlc/pull/628
|
124
|
+
if (!this.isSDLCServerInitialized) {
|
122
125
|
return;
|
123
126
|
}
|
124
127
|
|
@@ -234,7 +237,7 @@ export class LegendStudioBaseStore {
|
|
234
237
|
yield this.sdlcServerClient.fetchServerFeaturesConfiguration();
|
235
238
|
|
236
239
|
// the sdlc server client is authorized and initialized
|
237
|
-
this.
|
240
|
+
this.isSDLCServerInitialized = true;
|
238
241
|
}
|
239
242
|
} catch (error) {
|
240
243
|
assertErrorThrown(error);
|
@@ -727,7 +727,7 @@ export class EditorGraphState {
|
|
727
727
|
projectDependencies: ProjectDependency[],
|
728
728
|
): Promise<ProjectDependencyCoordinates[]> {
|
729
729
|
return Promise.all(
|
730
|
-
projectDependencies.map((dep) => {
|
730
|
+
projectDependencies.map(async (dep) => {
|
731
731
|
/**
|
732
732
|
* We expect current dependency ids to be in the format of {groupId}:{artifactId}.
|
733
733
|
* For the legacy dependency we must fetch the corresponding coordinates (group, artifact ids) from the depot server
|
@@ -835,8 +835,6 @@ export class EditorGraphState {
|
|
835
835
|
return label;
|
836
836
|
}
|
837
837
|
}
|
838
|
-
|
839
|
-
`Can't get type label for element '${element.path}': no compatible label getter available from plugins`,
|
840
|
-
);
|
838
|
+
return PACKAGEABLE_ELEMENT_TYPE.UNKNOWN;
|
841
839
|
}
|
842
840
|
}
|
@@ -32,6 +32,7 @@ import {
|
|
32
32
|
HttpStatus,
|
33
33
|
guaranteeNonNullable,
|
34
34
|
assertTrue,
|
35
|
+
ActionState,
|
35
36
|
} from '@finos/legend-shared';
|
36
37
|
import { EDITOR_MODE, ACTIVITY_MODE } from './EditorConfig.js';
|
37
38
|
import { type Entity, extractEntityNameFromPath } from '@finos/legend-storage';
|
@@ -56,16 +57,20 @@ export const entityDiffSorter = (a: EntityDiff, b: EntityDiff): number =>
|
|
56
57
|
export class EditorSDLCState {
|
57
58
|
readonly editorStore: EditorStore;
|
58
59
|
|
60
|
+
readonly fetchPublishedProjectVersionsState = ActionState.create();
|
61
|
+
|
62
|
+
isWorkspaceOutdated = false;
|
63
|
+
isCheckingIfWorkspaceIsOutdated = false;
|
64
|
+
isFetchingProjectVersions = false;
|
65
|
+
isFetchingProject = false;
|
66
|
+
|
59
67
|
currentProject?: Project | undefined;
|
60
68
|
currentWorkspace?: Workspace | undefined;
|
61
69
|
remoteWorkspaceRevision?: Revision | undefined;
|
62
70
|
currentRevision?: Revision | undefined;
|
63
|
-
isWorkspaceOutdated = false;
|
64
71
|
workspaceWorkflows: Workflow[] = [];
|
65
72
|
projectVersions: Version[] = [];
|
66
|
-
|
67
|
-
isFetchingProjectVersions = false;
|
68
|
-
isFetchingProject = false;
|
73
|
+
projectPublishedVersions: string[] = [];
|
69
74
|
|
70
75
|
constructor(editorStore: EditorStore) {
|
71
76
|
makeObservable(this, {
|
@@ -79,6 +84,7 @@ export class EditorSDLCState {
|
|
79
84
|
isCheckingIfWorkspaceIsOutdated: observable,
|
80
85
|
isFetchingProjectVersions: observable,
|
81
86
|
isFetchingProject: observable,
|
87
|
+
projectPublishedVersions: observable,
|
82
88
|
activeProject: computed,
|
83
89
|
activeWorkspace: computed,
|
84
90
|
activeRevision: computed,
|
@@ -99,6 +105,7 @@ export class EditorSDLCState {
|
|
99
105
|
buildWorkspaceBaseRevisionEntityHashesIndex: flow,
|
100
106
|
buildProjectLatestRevisionEntityHashesIndex: flow,
|
101
107
|
fetchWorkspaceWorkflows: flow,
|
108
|
+
fetchPublishedProjectVersions: flow,
|
102
109
|
});
|
103
110
|
|
104
111
|
this.editorStore = editorStore;
|
@@ -477,4 +484,26 @@ export class EditorSDLCState {
|
|
477
484
|
this.editorStore.applicationStore.notificationService.notifyError(error);
|
478
485
|
}
|
479
486
|
}
|
487
|
+
|
488
|
+
*fetchPublishedProjectVersions(): GeneratorFn<void> {
|
489
|
+
try {
|
490
|
+
this.fetchPublishedProjectVersionsState.inProgress();
|
491
|
+
this.projectPublishedVersions =
|
492
|
+
(yield this.editorStore.depotServerClient.getVersions(
|
493
|
+
this.editorStore.projectConfigurationEditorState
|
494
|
+
.currentProjectConfiguration.groupId,
|
495
|
+
this.editorStore.projectConfigurationEditorState
|
496
|
+
.currentProjectConfiguration.artifactId,
|
497
|
+
true,
|
498
|
+
)) as string[];
|
499
|
+
} catch (error) {
|
500
|
+
assertErrorThrown(error);
|
501
|
+
this.editorStore.applicationStore.logService.error(
|
502
|
+
LogEvent.create(LEGEND_STUDIO_APP_EVENT.DEPOT_MANAGER_FAILURE),
|
503
|
+
error,
|
504
|
+
);
|
505
|
+
} finally {
|
506
|
+
this.fetchPublishedProjectVersionsState.complete();
|
507
|
+
}
|
508
|
+
}
|
480
509
|
}
|
@@ -101,7 +101,6 @@ import { GraphEditFormModeState } from './GraphEditFormModeState.js';
|
|
101
101
|
import type { GraphEditorMode } from './GraphEditorMode.js';
|
102
102
|
import { GraphEditGrammarModeState } from './GraphEditGrammarModeState.js';
|
103
103
|
import { GlobalBulkServiceRegistrationState } from './sidebar-state/BulkServiceRegistrationState.js';
|
104
|
-
import { EditorDepotState } from './EditorDepotState.js';
|
105
104
|
|
106
105
|
export abstract class EditorExtensionState {
|
107
106
|
/**
|
@@ -118,6 +117,7 @@ export class EditorStore implements CommandRegistrar {
|
|
118
117
|
readonly pluginManager: LegendStudioPluginManager;
|
119
118
|
|
120
119
|
readonly initState = ActionState.create();
|
120
|
+
|
121
121
|
initialEntityPath?: string | undefined;
|
122
122
|
editorMode: EditorMode;
|
123
123
|
// NOTE: once we clear up the editor store to make modes more separated
|
@@ -130,7 +130,6 @@ export class EditorStore implements CommandRegistrar {
|
|
130
130
|
editorExtensionStates: EditorExtensionState[] = [];
|
131
131
|
explorerTreeState: ExplorerTreeState;
|
132
132
|
sdlcState: EditorSDLCState;
|
133
|
-
depotState: EditorDepotState;
|
134
133
|
graphState: EditorGraphState;
|
135
134
|
graphManagerState: GraphManagerState;
|
136
135
|
graphEditorMode: GraphEditorMode;
|
@@ -213,7 +212,6 @@ export class EditorStore implements CommandRegistrar {
|
|
213
212
|
this.editorMode = new StandardEditorMode(this);
|
214
213
|
|
215
214
|
this.sdlcState = new EditorSDLCState(this);
|
216
|
-
this.depotState = new EditorDepotState(this);
|
217
215
|
this.graphState = new EditorGraphState(this);
|
218
216
|
this.graphManagerState = new GraphManagerState(
|
219
217
|
applicationStore.pluginManager,
|
@@ -669,6 +667,20 @@ export class EditorStore implements CommandRegistrar {
|
|
669
667
|
}
|
670
668
|
|
671
669
|
private *initStandardMode(): GeneratorFn<void> {
|
670
|
+
const projectId = this.sdlcState.activeProject.projectId;
|
671
|
+
const activeWorkspace = this.sdlcState.activeWorkspace;
|
672
|
+
const projectConfiguration = (yield this.sdlcServerClient.getConfiguration(
|
673
|
+
projectId,
|
674
|
+
activeWorkspace,
|
675
|
+
)) as PlainObject<ProjectConfiguration>;
|
676
|
+
this.projectConfigurationEditorState.setProjectConfiguration(
|
677
|
+
ProjectConfiguration.serialization.fromJson(projectConfiguration),
|
678
|
+
);
|
679
|
+
// make sure we set the original project configuration to a different object
|
680
|
+
this.projectConfigurationEditorState.setOriginalProjectConfiguration(
|
681
|
+
ProjectConfiguration.serialization.fromJson(projectConfiguration),
|
682
|
+
);
|
683
|
+
|
672
684
|
yield Promise.all([
|
673
685
|
this.buildGraph(),
|
674
686
|
this.sdlcState.checkIfWorkspaceIsOutdated(),
|
@@ -678,11 +690,14 @@ export class EditorStore implements CommandRegistrar {
|
|
678
690
|
this.graphState.graphGenerationState.fetchAvailableFileGenerationDescriptions(),
|
679
691
|
this.graphState.graphGenerationState.externalFormatState.fetchExternalFormatsDescriptions(),
|
680
692
|
this.sdlcState.fetchProjectVersions(),
|
681
|
-
this.
|
693
|
+
this.sdlcState.fetchPublishedProjectVersions(),
|
682
694
|
]);
|
683
695
|
}
|
684
696
|
|
685
697
|
private *initConflictResolutionMode(): GeneratorFn<void> {
|
698
|
+
yield flowResult(
|
699
|
+
this.conflictResolutionState.initProjectConfigurationInConflictResolutionMode(),
|
700
|
+
);
|
686
701
|
this.applicationStore.alertService.setActionAlertInfo({
|
687
702
|
message: 'Failed to update workspace.',
|
688
703
|
prompt:
|
@@ -715,33 +730,23 @@ export class EditorStore implements CommandRegistrar {
|
|
715
730
|
this.graphState.graphGenerationState.fetchAvailableFileGenerationDescriptions(),
|
716
731
|
this.graphState.graphGenerationState.externalFormatState.fetchExternalFormatsDescriptions(),
|
717
732
|
this.sdlcState.fetchProjectVersions(),
|
718
|
-
this.
|
733
|
+
this.sdlcState.fetchPublishedProjectVersions(),
|
719
734
|
]);
|
720
735
|
}
|
721
736
|
|
722
737
|
*buildGraph(graphEntities?: Entity[]): GeneratorFn<void> {
|
723
738
|
const startTime = Date.now();
|
724
739
|
let entities: Entity[];
|
725
|
-
let projectConfiguration: PlainObject<ProjectConfiguration>;
|
726
740
|
|
727
741
|
this.initState.setMessage(`Fetching entities...`);
|
728
742
|
try {
|
729
743
|
// fetch workspace entities and config at the same time
|
730
744
|
const projectId = this.sdlcState.activeProject.projectId;
|
731
745
|
const activeWorkspace = this.sdlcState.activeWorkspace;
|
732
|
-
|
733
|
-
|
734
|
-
|
735
|
-
|
736
|
-
entities = result[0];
|
737
|
-
projectConfiguration = result[1];
|
738
|
-
this.projectConfigurationEditorState.setProjectConfiguration(
|
739
|
-
ProjectConfiguration.serialization.fromJson(projectConfiguration),
|
740
|
-
);
|
741
|
-
// make sure we set the original project configuration to a different object
|
742
|
-
this.projectConfigurationEditorState.setOriginalProjectConfiguration(
|
743
|
-
ProjectConfiguration.serialization.fromJson(projectConfiguration),
|
744
|
-
);
|
746
|
+
entities = (yield this.sdlcServerClient.getEntities(
|
747
|
+
projectId,
|
748
|
+
activeWorkspace,
|
749
|
+
)) as Entity[];
|
745
750
|
this.changeDetectionState.workspaceLocalLatestRevisionState.setEntities(
|
746
751
|
entities,
|
747
752
|
);
|
@@ -139,10 +139,7 @@ export class EditorTabManagerState extends TabManagerState {
|
|
139
139
|
return elementEditorState;
|
140
140
|
}
|
141
141
|
}
|
142
|
-
|
143
|
-
`Can't create editor state for element: no compatible editor state creator available from plugins`,
|
144
|
-
element,
|
145
|
-
);
|
142
|
+
return new UnsupportedElementEditorState(this.editorStore, element);
|
146
143
|
}
|
147
144
|
|
148
145
|
refreshCurrentEntityDiffViewer(): void {
|