@finos/legend-application-studio 28.19.109 → 28.19.111

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (29) hide show
  1. package/lib/components/editor/editor-group/dataProduct/DataProductEditor.js +1 -1
  2. package/lib/components/editor/editor-group/dataProduct/DataProductEditor.js.map +1 -1
  3. package/lib/components/editor/editor-group/mapping-editor/MappingEditor.d.ts.map +1 -1
  4. package/lib/components/editor/editor-group/mapping-editor/MappingEditor.js +3 -6
  5. package/lib/components/editor/editor-group/mapping-editor/MappingEditor.js.map +1 -1
  6. package/lib/index.css +1 -1
  7. package/lib/package.json +1 -1
  8. package/lib/stores/LegendStudioBaseStore.d.ts.map +1 -1
  9. package/lib/stores/LegendStudioBaseStore.js +1 -1
  10. package/lib/stores/LegendStudioBaseStore.js.map +1 -1
  11. package/lib/stores/editor/editor-state/element-editor-state/dataProduct/DataProductEditorState.d.ts +3 -1
  12. package/lib/stores/editor/editor-state/element-editor-state/dataProduct/DataProductEditorState.d.ts.map +1 -1
  13. package/lib/stores/editor/editor-state/element-editor-state/dataProduct/DataProductEditorState.js +39 -1
  14. package/lib/stores/editor/editor-state/element-editor-state/dataProduct/DataProductEditorState.js.map +1 -1
  15. package/lib/stores/editor/editor-state/element-editor-state/mapping/MappingDiagramGenerator.d.ts +1 -1
  16. package/lib/stores/editor/editor-state/element-editor-state/mapping/MappingDiagramGenerator.d.ts.map +1 -1
  17. package/lib/stores/editor/editor-state/element-editor-state/mapping/MappingDiagramGenerator.js +2 -2
  18. package/lib/stores/editor/editor-state/element-editor-state/mapping/MappingDiagramGenerator.js.map +1 -1
  19. package/lib/stores/editor/editor-state/element-editor-state/mapping/MappingEditorState.d.ts +1 -1
  20. package/lib/stores/editor/editor-state/element-editor-state/mapping/MappingEditorState.d.ts.map +1 -1
  21. package/lib/stores/editor/editor-state/element-editor-state/mapping/MappingEditorState.js +4 -2
  22. package/lib/stores/editor/editor-state/element-editor-state/mapping/MappingEditorState.js.map +1 -1
  23. package/package.json +11 -11
  24. package/src/components/editor/editor-group/dataProduct/DataProductEditor.tsx +1 -1
  25. package/src/components/editor/editor-group/mapping-editor/MappingEditor.tsx +0 -26
  26. package/src/stores/LegendStudioBaseStore.ts +1 -0
  27. package/src/stores/editor/editor-state/element-editor-state/dataProduct/DataProductEditorState.ts +51 -1
  28. package/src/stores/editor/editor-state/element-editor-state/mapping/MappingDiagramGenerator.ts +5 -2
  29. package/src/stores/editor/editor-state/element-editor-state/mapping/MappingEditorState.ts +4 -1
@@ -32,14 +32,17 @@ import { uuid } from '@finos/legend-shared';
32
32
 
33
33
  export const generateMappingDiagram = (
34
34
  mapping: Mapping,
35
- allClasses: Class[],
35
+ featuredClasses: Class[],
36
36
  ): Diagram => {
37
37
  let diagramName = mapping.name.replace(/mapping/i, 'Diagram');
38
38
  if (diagramName === mapping.name) {
39
39
  diagramName = `${mapping.name}GeneratedDiagram`;
40
40
  }
41
41
  const diagram = new Diagram(diagramName);
42
- const classesInMapping = getMappingCompatibleClasses(mapping, allClasses);
42
+ const classesInMapping = getMappingCompatibleClasses(
43
+ mapping,
44
+ featuredClasses,
45
+ );
43
46
  diagram.classViews = classesInMapping.map(
44
47
  (clazz) =>
45
48
  new ClassView(
@@ -623,11 +623,14 @@ const reprocessMappingElementNodes = (
623
623
  export const onGeneratingDiagramFromMapping = flow(function* (
624
624
  mapping: Mapping,
625
625
  editorStore: EditorStore,
626
+ featuredClasses?: Class[],
626
627
  ): GeneratorFn<Diagram | undefined> {
627
628
  try {
628
629
  const diagram = generateMappingDiagram(
629
630
  mapping,
630
- editorStore.graphManagerState.usableClasses,
631
+ featuredClasses && featuredClasses.length > 0
632
+ ? featuredClasses
633
+ : editorStore.graphManagerState.usableClasses,
631
634
  );
632
635
  observe_Diagram(diagram);
633
636
  editorStore.graphManagerState.graph.addElement(