@finos/legend-application-studio 27.1.0 → 27.1.2

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 (156) hide show
  1. package/lib/__lib__/LegendStudioEvent.d.ts +1 -0
  2. package/lib/__lib__/LegendStudioEvent.d.ts.map +1 -1
  3. package/lib/__lib__/LegendStudioEvent.js +1 -0
  4. package/lib/__lib__/LegendStudioEvent.js.map +1 -1
  5. package/lib/components/editor/editor-group/FunctionEditor.d.ts.map +1 -1
  6. package/lib/components/editor/editor-group/FunctionEditor.js +28 -24
  7. package/lib/components/editor/editor-group/FunctionEditor.js.map +1 -1
  8. package/lib/components/editor/editor-group/connection-editor/{DatabaseBuilder.d.ts → DatabaseBuilderWizard.d.ts} +4 -11
  9. package/lib/components/editor/editor-group/connection-editor/DatabaseBuilderWizard.d.ts.map +1 -0
  10. package/lib/components/editor/editor-group/connection-editor/DatabaseBuilderWizard.js +48 -0
  11. package/lib/components/editor/editor-group/connection-editor/DatabaseBuilderWizard.js.map +1 -0
  12. package/lib/components/editor/editor-group/connection-editor/DatabaseSchemaExplorer.d.ts +32 -0
  13. package/lib/components/editor/editor-group/connection-editor/DatabaseSchemaExplorer.d.ts.map +1 -0
  14. package/lib/components/editor/editor-group/connection-editor/DatabaseSchemaExplorer.js +99 -0
  15. package/lib/components/editor/editor-group/connection-editor/DatabaseSchemaExplorer.js.map +1 -0
  16. package/lib/components/editor/editor-group/connection-editor/RelationalDatabaseConnectionEditor.js +1 -1
  17. package/lib/components/editor/editor-group/connection-editor/RelationalDatabaseConnectionEditor.js.map +1 -1
  18. package/lib/components/editor/editor-group/data-editor/EmbeddedDataEditor.d.ts.map +1 -1
  19. package/lib/components/editor/editor-group/data-editor/EmbeddedDataEditor.js +5 -4
  20. package/lib/components/editor/editor-group/data-editor/EmbeddedDataEditor.js.map +1 -1
  21. package/lib/components/editor/editor-group/data-editor/RelationalCSVDataEditor.d.ts.map +1 -1
  22. package/lib/components/editor/editor-group/data-editor/RelationalCSVDataEditor.js +62 -12
  23. package/lib/components/editor/editor-group/data-editor/RelationalCSVDataEditor.js.map +1 -1
  24. package/lib/components/editor/editor-group/mapping-editor/MappingTestableEditor.d.ts +1 -1
  25. package/lib/components/editor/editor-group/mapping-editor/MappingTestableEditor.d.ts.map +1 -1
  26. package/lib/components/editor/editor-group/mapping-editor/MappingTestableEditor.js +101 -137
  27. package/lib/components/editor/editor-group/mapping-editor/MappingTestableEditor.js.map +1 -1
  28. package/lib/components/editor/editor-group/testable/TestableSharedComponents.d.ts +11 -0
  29. package/lib/components/editor/editor-group/testable/TestableSharedComponents.d.ts.map +1 -1
  30. package/lib/components/editor/editor-group/testable/TestableSharedComponents.js +27 -2
  31. package/lib/components/editor/editor-group/testable/TestableSharedComponents.js.map +1 -1
  32. package/lib/components/editor/panel-group/SQLPlaygroundPanel.d.ts +0 -7
  33. package/lib/components/editor/panel-group/SQLPlaygroundPanel.d.ts.map +1 -1
  34. package/lib/components/editor/panel-group/SQLPlaygroundPanel.js +20 -77
  35. package/lib/components/editor/panel-group/SQLPlaygroundPanel.js.map +1 -1
  36. package/lib/components/editor/side-bar/Explorer.js +3 -3
  37. package/lib/components/editor/side-bar/Explorer.js.map +1 -1
  38. package/lib/components/editor/side-bar/WorkflowManager.d.ts.map +1 -1
  39. package/lib/components/editor/side-bar/WorkflowManager.js +6 -1
  40. package/lib/components/editor/side-bar/WorkflowManager.js.map +1 -1
  41. package/lib/index.css +2 -2
  42. package/lib/index.css.map +1 -1
  43. package/lib/package.json +3 -3
  44. package/lib/stores/editor/ExplorerTreeState.d.ts +4 -4
  45. package/lib/stores/editor/ExplorerTreeState.d.ts.map +1 -1
  46. package/lib/stores/editor/ExplorerTreeState.js +4 -4
  47. package/lib/stores/editor/ExplorerTreeState.js.map +1 -1
  48. package/lib/stores/editor/NewElementState.d.ts.map +1 -1
  49. package/lib/stores/editor/NewElementState.js.map +1 -1
  50. package/lib/stores/editor/editor-state/element-editor-state/FunctionEditorState.d.ts +12 -12
  51. package/lib/stores/editor/editor-state/element-editor-state/FunctionEditorState.d.ts.map +1 -1
  52. package/lib/stores/editor/editor-state/element-editor-state/FunctionEditorState.js +45 -46
  53. package/lib/stores/editor/editor-state/element-editor-state/FunctionEditorState.js.map +1 -1
  54. package/lib/stores/editor/editor-state/element-editor-state/connection/DatabaseBuilderState.d.ts +20 -29
  55. package/lib/stores/editor/editor-state/element-editor-state/connection/DatabaseBuilderState.d.ts.map +1 -1
  56. package/lib/stores/editor/editor-state/element-editor-state/connection/DatabaseBuilderState.js +60 -141
  57. package/lib/stores/editor/editor-state/element-editor-state/connection/DatabaseBuilderState.js.map +1 -1
  58. package/lib/stores/editor/editor-state/element-editor-state/connection/DatabaseBuilderWizardState.d.ts +33 -0
  59. package/lib/stores/editor/editor-state/element-editor-state/connection/DatabaseBuilderWizardState.d.ts.map +1 -0
  60. package/lib/stores/editor/editor-state/element-editor-state/connection/DatabaseBuilderWizardState.js +71 -0
  61. package/lib/stores/editor/editor-state/element-editor-state/connection/DatabaseBuilderWizardState.js.map +1 -0
  62. package/lib/stores/editor/editor-state/element-editor-state/data/DataEditorState.d.ts +2 -2
  63. package/lib/stores/editor/editor-state/element-editor-state/data/DataEditorState.d.ts.map +1 -1
  64. package/lib/stores/editor/editor-state/element-editor-state/data/DataEditorState.js +2 -2
  65. package/lib/stores/editor/editor-state/element-editor-state/data/DataEditorState.js.map +1 -1
  66. package/lib/stores/editor/editor-state/element-editor-state/data/EmbeddedDataState.d.ts +14 -19
  67. package/lib/stores/editor/editor-state/element-editor-state/data/EmbeddedDataState.d.ts.map +1 -1
  68. package/lib/stores/editor/editor-state/element-editor-state/data/EmbeddedDataState.js +30 -65
  69. package/lib/stores/editor/editor-state/element-editor-state/data/EmbeddedDataState.js.map +1 -1
  70. package/lib/stores/editor/editor-state/element-editor-state/mapping/testable/MappingTestableState.d.ts +56 -78
  71. package/lib/stores/editor/editor-state/element-editor-state/mapping/testable/MappingTestableState.d.ts.map +1 -1
  72. package/lib/stores/editor/editor-state/element-editor-state/mapping/testable/MappingTestableState.js +285 -384
  73. package/lib/stores/editor/editor-state/element-editor-state/mapping/testable/MappingTestableState.js.map +1 -1
  74. package/lib/stores/editor/editor-state/element-editor-state/mapping/testable/MappingTestingHelper.d.ts +23 -0
  75. package/lib/stores/editor/editor-state/element-editor-state/mapping/testable/MappingTestingHelper.d.ts.map +1 -0
  76. package/lib/stores/editor/editor-state/element-editor-state/mapping/testable/MappingTestingHelper.js +129 -0
  77. package/lib/stores/editor/editor-state/element-editor-state/mapping/testable/MappingTestingHelper.js.map +1 -0
  78. package/lib/stores/editor/editor-state/element-editor-state/service/ServiceEditorState.d.ts.map +1 -1
  79. package/lib/stores/editor/editor-state/element-editor-state/service/ServiceEditorState.js +2 -2
  80. package/lib/stores/editor/editor-state/element-editor-state/service/ServiceEditorState.js.map +1 -1
  81. package/lib/stores/editor/editor-state/element-editor-state/service/testable/ServiceTestDataState.d.ts +1 -0
  82. package/lib/stores/editor/editor-state/element-editor-state/service/testable/ServiceTestDataState.d.ts.map +1 -1
  83. package/lib/stores/editor/editor-state/element-editor-state/service/testable/ServiceTestDataState.js +12 -2
  84. package/lib/stores/editor/editor-state/element-editor-state/service/testable/ServiceTestDataState.js.map +1 -1
  85. package/lib/stores/editor/editor-state/element-editor-state/service/testable/ServiceTestableState.d.ts.map +1 -1
  86. package/lib/stores/editor/editor-state/element-editor-state/service/testable/ServiceTestableState.js +15 -8
  87. package/lib/stores/editor/editor-state/element-editor-state/service/testable/ServiceTestableState.js.map +1 -1
  88. package/lib/stores/editor/editor-state/element-editor-state/testable/TestAssertionState.d.ts +7 -4
  89. package/lib/stores/editor/editor-state/element-editor-state/testable/TestAssertionState.d.ts.map +1 -1
  90. package/lib/stores/editor/editor-state/element-editor-state/testable/TestAssertionState.js +53 -10
  91. package/lib/stores/editor/editor-state/element-editor-state/testable/TestAssertionState.js.map +1 -1
  92. package/lib/stores/editor/editor-state/element-editor-state/testable/TestableEditorState.d.ts +2 -1
  93. package/lib/stores/editor/editor-state/element-editor-state/testable/TestableEditorState.d.ts.map +1 -1
  94. package/lib/stores/editor/editor-state/element-editor-state/testable/TestableEditorState.js +20 -16
  95. package/lib/stores/editor/editor-state/element-editor-state/testable/TestableEditorState.js.map +1 -1
  96. package/lib/stores/editor/panel-group/SQLPlaygroundPanelState.d.ts +3 -48
  97. package/lib/stores/editor/panel-group/SQLPlaygroundPanelState.d.ts.map +1 -1
  98. package/lib/stores/editor/panel-group/SQLPlaygroundPanelState.js +12 -350
  99. package/lib/stores/editor/panel-group/SQLPlaygroundPanelState.js.map +1 -1
  100. package/lib/stores/editor/sidebar-state/WorkflowManagerState.d.ts +5 -0
  101. package/lib/stores/editor/sidebar-state/WorkflowManagerState.d.ts.map +1 -1
  102. package/lib/stores/editor/sidebar-state/WorkflowManagerState.js +26 -0
  103. package/lib/stores/editor/sidebar-state/WorkflowManagerState.js.map +1 -1
  104. package/lib/stores/editor/sidebar-state/testable/GlobalTestRunnerState.d.ts +1 -1
  105. package/lib/stores/editor/sidebar-state/testable/GlobalTestRunnerState.d.ts.map +1 -1
  106. package/lib/stores/editor/sidebar-state/testable/GlobalTestRunnerState.js +3 -0
  107. package/lib/stores/editor/sidebar-state/testable/GlobalTestRunnerState.js.map +1 -1
  108. package/lib/stores/editor/utils/MockDataUtils.d.ts.map +1 -1
  109. package/lib/stores/editor/utils/MockDataUtils.js +3 -0
  110. package/lib/stores/editor/utils/MockDataUtils.js.map +1 -1
  111. package/lib/stores/editor/utils/TestableUtils.d.ts +11 -1
  112. package/lib/stores/editor/utils/TestableUtils.d.ts.map +1 -1
  113. package/lib/stores/editor/utils/TestableUtils.js +50 -1
  114. package/lib/stores/editor/utils/TestableUtils.js.map +1 -1
  115. package/lib/stores/graph-modifier/DSL_Mapping_GraphModifierHelper.d.ts +5 -4
  116. package/lib/stores/graph-modifier/DSL_Mapping_GraphModifierHelper.d.ts.map +1 -1
  117. package/lib/stores/graph-modifier/DSL_Mapping_GraphModifierHelper.js +4 -1
  118. package/lib/stores/graph-modifier/DSL_Mapping_GraphModifierHelper.js.map +1 -1
  119. package/package.json +9 -9
  120. package/src/__lib__/LegendStudioEvent.ts +1 -1
  121. package/src/components/editor/editor-group/FunctionEditor.tsx +133 -118
  122. package/src/components/editor/editor-group/connection-editor/DatabaseBuilderWizard.tsx +191 -0
  123. package/src/components/editor/editor-group/connection-editor/DatabaseSchemaExplorer.tsx +227 -0
  124. package/src/components/editor/editor-group/connection-editor/RelationalDatabaseConnectionEditor.tsx +1 -1
  125. package/src/components/editor/editor-group/data-editor/EmbeddedDataEditor.tsx +34 -37
  126. package/src/components/editor/editor-group/data-editor/RelationalCSVDataEditor.tsx +134 -31
  127. package/src/components/editor/editor-group/mapping-editor/MappingTestableEditor.tsx +296 -414
  128. package/src/components/editor/editor-group/testable/TestableSharedComponents.tsx +88 -3
  129. package/src/components/editor/panel-group/SQLPlaygroundPanel.tsx +47 -211
  130. package/src/components/editor/side-bar/Explorer.tsx +3 -3
  131. package/src/components/editor/side-bar/WorkflowManager.tsx +10 -0
  132. package/src/stores/editor/ExplorerTreeState.ts +6 -9
  133. package/src/stores/editor/NewElementState.ts +0 -1
  134. package/src/stores/editor/editor-state/element-editor-state/FunctionEditorState.ts +44 -50
  135. package/src/stores/editor/editor-state/element-editor-state/connection/DatabaseBuilderState.ts +88 -212
  136. package/src/stores/editor/editor-state/element-editor-state/connection/DatabaseBuilderWizardState.ts +102 -0
  137. package/src/stores/editor/editor-state/element-editor-state/data/DataEditorState.ts +7 -1
  138. package/src/stores/editor/editor-state/element-editor-state/data/EmbeddedDataState.ts +48 -77
  139. package/src/stores/editor/editor-state/element-editor-state/mapping/testable/MappingTestableState.ts +407 -617
  140. package/src/stores/editor/editor-state/element-editor-state/mapping/testable/MappingTestingHelper.ts +243 -0
  141. package/src/stores/editor/editor-state/element-editor-state/service/ServiceEditorState.ts +6 -2
  142. package/src/stores/editor/editor-state/element-editor-state/service/testable/ServiceTestDataState.ts +18 -1
  143. package/src/stores/editor/editor-state/element-editor-state/service/testable/ServiceTestableState.ts +20 -12
  144. package/src/stores/editor/editor-state/element-editor-state/testable/TestAssertionState.ts +76 -18
  145. package/src/stores/editor/editor-state/element-editor-state/testable/TestableEditorState.ts +29 -24
  146. package/src/stores/editor/panel-group/SQLPlaygroundPanelState.ts +13 -533
  147. package/src/stores/editor/sidebar-state/WorkflowManagerState.ts +47 -0
  148. package/src/stores/editor/sidebar-state/testable/GlobalTestRunnerState.ts +4 -1
  149. package/src/stores/editor/utils/MockDataUtils.ts +2 -0
  150. package/src/stores/editor/utils/TestableUtils.ts +73 -0
  151. package/src/stores/graph-modifier/DSL_Mapping_GraphModifierHelper.ts +15 -12
  152. package/tsconfig.json +4 -1
  153. package/lib/components/editor/editor-group/connection-editor/DatabaseBuilder.d.ts.map +0 -1
  154. package/lib/components/editor/editor-group/connection-editor/DatabaseBuilder.js +0 -133
  155. package/lib/components/editor/editor-group/connection-editor/DatabaseBuilder.js.map +0 -1
  156. package/src/components/editor/editor-group/connection-editor/DatabaseBuilder.tsx +0 -397
@@ -326,8 +326,11 @@ export const getTestableResultFromAssertionStatus = (
326
326
  return TESTABLE_RESULT.DID_NOT_RUN;
327
327
  };
328
328
  export const getTestableResultFromTestResults = (
329
- testResults: (TestResult | undefined)[],
329
+ testResults: (TestResult | undefined)[] | undefined,
330
330
  ): TESTABLE_RESULT => {
331
+ if (testResults === undefined || !testResults.length) {
332
+ return TESTABLE_RESULT.DID_NOT_RUN;
333
+ }
331
334
  if (
332
335
  testResults.every(
333
336
  (t) =>
@@ -308,6 +308,8 @@ export const createMockDataForMappingElementSource = (
308
308
  srcElement.relation instanceof Table
309
309
  ) {
310
310
  return createMockDataForTable(srcElement.relation);
311
+ } else if (srcElement instanceof Table) {
312
+ return createMockDataForTable(srcElement);
311
313
  }
312
314
  editorStore.applicationStore.notificationService.notifyWarning(
313
315
  new UnsupportedOperationError(
@@ -28,6 +28,7 @@ import {
28
28
  type TestAssertion,
29
29
  type AtomicTest,
30
30
  type Class,
31
+ type EmbeddedDataVisitor,
31
32
  ExternalFormatData,
32
33
  RelationalCSVData,
33
34
  ConnectionTestData,
@@ -36,6 +37,14 @@ import {
36
37
  RelationalCSVDataTable,
37
38
  type INTERNAL__UnknownConnection,
38
39
  getAllIdentifiedConnectionsFromRuntime,
40
+ ModelStoreData,
41
+ ModelEmbeddedData,
42
+ PackageableElementExplicitReference,
43
+ type DataElementReference,
44
+ type INTERNAL__UnknownEmbeddedData,
45
+ type TestResult,
46
+ TestExecuted,
47
+ TestExecutionStatus,
39
48
  } from '@finos/legend-graph';
40
49
  import {
41
50
  assertTrue,
@@ -58,6 +67,7 @@ export const validateTestableId = (
58
67
  id: string | undefined,
59
68
  possibleIds: string[] | undefined,
60
69
  ): string | undefined => {
70
+ // undefined in this case means user has yet to write anything so we shouldnt show any error message
61
71
  if (id === undefined) {
62
72
  return undefined;
63
73
  }
@@ -101,6 +111,64 @@ export const createEmbeddedDataFromClass = (
101
111
  return data;
102
112
  };
103
113
 
114
+ export const createBareModelStoreData = (
115
+ _class: Class,
116
+ editorStore: EditorStore,
117
+ ): ModelStoreData => {
118
+ const embeddedData = createEmbeddedDataFromClass(_class, editorStore);
119
+ const modelStoreData = new ModelStoreData();
120
+ const modelData = new ModelEmbeddedData();
121
+ modelData.data = embeddedData;
122
+ modelData.model = PackageableElementExplicitReference.create(_class);
123
+ modelStoreData.modelData = [modelData];
124
+ return modelStoreData;
125
+ };
126
+
127
+ export class EmbeddedDataCreatorFromEmbeddedData
128
+ implements EmbeddedDataVisitor<EmbeddedData>
129
+ {
130
+ visit_EmbeddedData(data: EmbeddedData): EmbeddedData {
131
+ throw new Error('Method not implemented.');
132
+ }
133
+ visit_INTERNAL__UnknownEmbeddedData(
134
+ data: INTERNAL__UnknownEmbeddedData,
135
+ ): EmbeddedData {
136
+ throw new Error('Method not implemented.');
137
+ }
138
+ visit_ExternalFormatData(data: ExternalFormatData): EmbeddedData {
139
+ const val = new ExternalFormatData();
140
+ val.contentType = data.contentType;
141
+ val.data = '';
142
+ return val;
143
+ }
144
+ visit_ModelStoreData(data: ModelStoreData): EmbeddedData {
145
+ const val = new ModelStoreData();
146
+ val.modelData = data.modelData
147
+ ?.map((e) => {
148
+ if (e instanceof ModelEmbeddedData) {
149
+ const v = new ModelEmbeddedData();
150
+ v.model = PackageableElementExplicitReference.create(e.model.value);
151
+ v.data = e.data.accept_EmbeddedDataVisitor(
152
+ new EmbeddedDataCreatorFromEmbeddedData(),
153
+ );
154
+ return v;
155
+ }
156
+ return undefined;
157
+ })
158
+ .filter(isNonNullable);
159
+ return val;
160
+ }
161
+ visit_DataElementReference(data: DataElementReference): EmbeddedData {
162
+ return data.dataElement.value.data.accept_EmbeddedDataVisitor(
163
+ new EmbeddedDataCreatorFromEmbeddedData(),
164
+ );
165
+ }
166
+ visit_RelationalCSVData(data: RelationalCSVData): EmbeddedData {
167
+ const val = new RelationalCSVData();
168
+ return val;
169
+ }
170
+ }
171
+
104
172
  // NOTE: this will all move to `engine` once engine support generating test data for all connections
105
173
  // Throws if unable to generate test data
106
174
  export class TEMPORARY__EmbeddedDataConnectionVisitor
@@ -251,3 +319,8 @@ export const TEMPORARY__createRelationalDataFromCSV = (
251
319
  });
252
320
  return data;
253
321
  };
322
+
323
+ // test result
324
+ export const isTestPassing = (testResult: TestResult): boolean =>
325
+ testResult instanceof TestExecuted &&
326
+ testResult.testExecutionStatus === TestExecutionStatus.PASS;
@@ -78,11 +78,10 @@ import {
78
78
  PrimitiveType,
79
79
  type MappingTestSuite,
80
80
  observe_MappingTestSuite,
81
- type MappingQueryTestSuite,
82
- type MappingQueryTest,
83
- type MappingDataTestSuite,
84
- type MappingDataTest,
85
81
  type StoreTestData,
82
+ type MappingTest,
83
+ type EmbeddedData,
84
+ observe_EmbeddedData,
86
85
  } from '@finos/legend-graph';
87
86
  import {
88
87
  addUniqueEntry,
@@ -203,25 +202,29 @@ export const mapping_deleteTestSuite = action(
203
202
  );
204
203
 
205
204
  export const mappingTestable_setQuery = action(
206
- (test: MappingQueryTest | MappingQueryTestSuite, value: RawLambda): void => {
205
+ (test: MappingTestSuite, value: RawLambda): void => {
207
206
  test.func = observe_RawLambda(value);
208
207
  },
209
208
  );
210
209
 
211
210
  export const mappingTestable_deleteStoreTestData = action(
212
- (
213
- dataHolder: MappingDataTestSuite | MappingDataTest,
214
- val: StoreTestData,
215
- ): void => {
211
+ (dataHolder: MappingTest, val: StoreTestData): void => {
216
212
  deleteEntry(dataHolder.storeTestData, val);
217
213
  },
218
214
  );
219
215
 
220
- export const mappingTestable_addStoreTestData = action(
216
+ export const mappingTestable_setEmbeddedData = action(
221
217
  (
222
- dataHolder: MappingDataTestSuite | MappingDataTest,
223
- val: StoreTestData,
218
+ store: StoreTestData,
219
+ embeddedData: EmbeddedData,
220
+ observerContext: ObserverContext,
224
221
  ): void => {
222
+ store.data = observe_EmbeddedData(embeddedData, observerContext);
223
+ },
224
+ );
225
+
226
+ export const mappingTestable_addStoreTestData = action(
227
+ (dataHolder: MappingTest, val: StoreTestData): void => {
225
228
  addUniqueEntry(dataHolder.storeTestData, val);
226
229
  },
227
230
  );
package/tsconfig.json CHANGED
@@ -95,6 +95,7 @@
95
95
  "./src/stores/editor/editor-state/element-editor-state/UMLEditorState.ts",
96
96
  "./src/stores/editor/editor-state/element-editor-state/connection/ConnectionEditorState.ts",
97
97
  "./src/stores/editor/editor-state/element-editor-state/connection/DatabaseBuilderState.ts",
98
+ "./src/stores/editor/editor-state/element-editor-state/connection/DatabaseBuilderWizardState.ts",
98
99
  "./src/stores/editor/editor-state/element-editor-state/connection/PostProcessorEditorState.ts",
99
100
  "./src/stores/editor/editor-state/element-editor-state/data/DataEditorState.ts",
100
101
  "./src/stores/editor/editor-state/element-editor-state/data/EmbeddedDataState.ts",
@@ -112,6 +113,7 @@
112
113
  "./src/stores/editor/editor-state/element-editor-state/mapping/UnsupportedInstanceSetImplementationState.ts",
113
114
  "./src/stores/editor/editor-state/element-editor-state/mapping/relational/RelationalInstanceSetImplementationState.ts",
114
115
  "./src/stores/editor/editor-state/element-editor-state/mapping/testable/MappingTestableState.ts",
116
+ "./src/stores/editor/editor-state/element-editor-state/mapping/testable/MappingTestingHelper.ts",
115
117
  "./src/stores/editor/editor-state/element-editor-state/service/ServiceEditorState.ts",
116
118
  "./src/stores/editor/editor-state/element-editor-state/service/ServiceExecutionState.ts",
117
119
  "./src/stores/editor/editor-state/element-editor-state/service/ServicePostValidationState.ts",
@@ -191,8 +193,9 @@
191
193
  "./src/components/editor/editor-group/RuntimeEditor.tsx",
192
194
  "./src/components/editor/editor-group/UnsupportedElementEditor.tsx",
193
195
  "./src/components/editor/editor-group/connection-editor/ConnectionEditor.tsx",
194
- "./src/components/editor/editor-group/connection-editor/DatabaseBuilder.tsx",
196
+ "./src/components/editor/editor-group/connection-editor/DatabaseBuilderWizard.tsx",
195
197
  "./src/components/editor/editor-group/connection-editor/DatabaseEditorHelper.tsx",
198
+ "./src/components/editor/editor-group/connection-editor/DatabaseSchemaExplorer.tsx",
196
199
  "./src/components/editor/editor-group/connection-editor/FlatDataConnectionEditor.tsx",
197
200
  "./src/components/editor/editor-group/connection-editor/RelationalDatabaseConnectionEditor.tsx",
198
201
  "./src/components/editor/editor-group/connection-editor/post-processor-editor/MapperPostProcessorEditor.tsx",
@@ -1 +0,0 @@
1
- {"version":3,"file":"DatabaseBuilder.d.ts","sourceRoot":"","sources":["../../../../../src/components/editor/editor-group/connection-editor/DatabaseBuilder.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAiCH,OAAO,EACL,KAAK,oBAAoB,EACzB,KAAK,uBAAuB,EAK7B,MAAM,gGAAgG,CAAC;AAmIxG,eAAO,MAAM,uBAAuB,WAC1B;IACN,QAAQ,EAAE,uBAAuB,CAAC;IAClC,UAAU,EAAE,OAAO,CAAC;IACpB,oBAAoB,EAAE,oBAAoB,CAAC;CAC5C;;CAmDF,CAAC;AAEF,eAAO,MAAM,eAAe,WAClB;IACN,oBAAoB,EAAE,oBAAoB,CAAC;IAC3C,UAAU,EAAE,OAAO,CAAC;CACrB;;CAqJF,CAAC"}
@@ -1,133 +0,0 @@
1
- import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
- /**
3
- * Copyright (c) 2020-present, Goldman Sachs
4
- *
5
- * Licensed under the Apache License, Version 2.0 (the "License");
6
- * you may not use this file except in compliance with the License.
7
- * You may obtain a copy of the License at
8
- *
9
- * http://www.apache.org/licenses/LICENSE-2.0
10
- *
11
- * Unless required by applicable law or agreed to in writing, software
12
- * distributed under the License is distributed on an "AS IS" BASIS,
13
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14
- * See the License for the specific language governing permissions and
15
- * limitations under the License.
16
- */
17
- import { observer } from 'mobx-react-lite';
18
- import { Dialog, ResizablePanelGroup, ResizablePanel, ResizablePanelSplitter, PanelLoadingIndicator, TreeView, PURE_DatabaseSchemaIcon, PURE_DatabaseTableIcon, CircleIcon, ChevronDownIcon, ChevronRightIcon, CheckCircleIcon, EmptyCircleIcon, PanelContent, Modal, ModalHeader, ModalBody, ModalFooter, ModalTitle, ModalHeaderActions, TimesIcon, ModalFooterButton, BlankPanelContent, KeyIcon, PanelHeader, Panel, } from '@finos/legend-art';
19
- import { useEffect } from 'react';
20
- import { ColumnDatabaseBuilderTreeNodeData, SchemaDatabaseBuilderTreeNodeData, TableDatabaseBuilderTreeNodeData, } from '../../../../stores/editor/editor-state/element-editor-state/connection/DatabaseBuilderState.js';
21
- import { noop } from '@finos/legend-shared';
22
- import { useApplicationStore, useConditionedApplicationNavigationContext, } from '@finos/legend-application';
23
- import { renderColumnTypeIcon } from './DatabaseEditorHelper.js';
24
- import { flowResult } from 'mobx';
25
- import { LEGEND_STUDIO_APPLICATION_NAVIGATION_CONTEXT_KEY } from '../../../../__lib__/LegendStudioApplicationNavigationContext.js';
26
- import { CODE_EDITOR_LANGUAGE, CodeEditor, } from '@finos/legend-lego/code-editor';
27
- import { stringifyDataType } from '@finos/legend-graph';
28
- const getDatabaseSchemaNodeIcon = (node) => {
29
- if (node instanceof SchemaDatabaseBuilderTreeNodeData) {
30
- return (_jsx("div", { className: "database-builder-tree__icon--schema", children: _jsx(PURE_DatabaseSchemaIcon, {}) }));
31
- }
32
- else if (node instanceof TableDatabaseBuilderTreeNodeData) {
33
- return (_jsx("div", { className: "database-builder-tree__icon--table", children: _jsx(PURE_DatabaseTableIcon, {}) }));
34
- }
35
- else if (node instanceof ColumnDatabaseBuilderTreeNodeData) {
36
- return renderColumnTypeIcon(node.column.type);
37
- }
38
- return null;
39
- };
40
- const DatabaseBuilderTreeNodeContainer = observer((props) => {
41
- const { node, level, stepPaddingInRem, onNodeSelect, innerProps } = props;
42
- const { toggleCheckedNode, isPartiallySelected } = innerProps;
43
- const isExpandable = Boolean(!node.childrenIds || node.childrenIds.length) &&
44
- !(node instanceof ColumnDatabaseBuilderTreeNodeData);
45
- const nodeExpandIcon = isExpandable ? (node.isOpen ? (_jsx(ChevronDownIcon, {})) : (_jsx(ChevronRightIcon, {}))) : (_jsx("div", {}));
46
- const nodeTypeIcon = getDatabaseSchemaNodeIcon(node);
47
- const toggleExpandNode = () => {
48
- onNodeSelect?.(node);
49
- if (!isExpandable) {
50
- toggleCheckedNode(node);
51
- }
52
- };
53
- const isPrimaryKeyColumn = node instanceof ColumnDatabaseBuilderTreeNodeData &&
54
- node.owner.primaryKey.includes(node.column);
55
- const renderCheckedIcon = (_node) => {
56
- if (_node instanceof ColumnDatabaseBuilderTreeNodeData) {
57
- return null;
58
- }
59
- else if (isPartiallySelected(_node)) {
60
- return _jsx(CircleIcon, {});
61
- }
62
- else if (_node.isChecked) {
63
- return _jsx(CheckCircleIcon, {});
64
- }
65
- return _jsx(EmptyCircleIcon, {});
66
- };
67
- return (_jsxs("div", { className: "tree-view__node__container", style: {
68
- paddingLeft: `${level * (stepPaddingInRem ?? 1)}rem`,
69
- display: 'flex',
70
- }, onClick: toggleExpandNode, children: [_jsxs("div", { className: "tree-view__node__icon database-builder-tree__node__icon__group", children: [_jsx("div", { className: "database-builder-tree__expand-icon", children: nodeExpandIcon }), _jsx("div", { className: "database-builder-tree__checker-icon", onClick: (event) => {
71
- event.stopPropagation();
72
- toggleCheckedNode(node);
73
- }, children: renderCheckedIcon(node) }), _jsx("div", { className: "database-builder-tree__type-icon", children: nodeTypeIcon })] }), _jsxs("div", { className: "tree-view__node__label database-builder-tree__node__label", children: [node.label, node instanceof ColumnDatabaseBuilderTreeNodeData && (_jsx("div", { className: "database-builder-tree__node__type", children: _jsx("div", { className: "database-builder-tree__node__type__label", children: stringifyDataType(node.column.type) }) })), isPrimaryKeyColumn && (_jsx("div", { className: "database-builder-tree__node__pk", title: "Primary Key", children: _jsx(KeyIcon, {}) }))] })] }));
74
- });
75
- export const DatabaseBuilderExplorer = observer((props) => {
76
- const { treeData, databaseBuilderState } = props;
77
- const applicationStore = useApplicationStore();
78
- const onNodeSelect = (node) => {
79
- flowResult(databaseBuilderState.onNodeSelect(node, treeData)).catch(applicationStore.alertUnhandledError);
80
- };
81
- const getChildNodes = (node) => databaseBuilderState
82
- .getChildNodes(node, treeData)
83
- ?.sort((a, b) => a.label.localeCompare(b.label)) ?? [];
84
- const isPartiallySelected = (node) => {
85
- if (node instanceof SchemaDatabaseBuilderTreeNodeData &&
86
- !node.isChecked) {
87
- return Boolean(databaseBuilderState
88
- .getChildNodes(node, treeData)
89
- ?.find((childNode) => childNode.isChecked === true));
90
- }
91
- return false;
92
- };
93
- const toggleCheckedNode = (node) => databaseBuilderState.toggleCheckedNode(node, treeData);
94
- return (_jsx(TreeView, { className: "database-builder-tree", components: {
95
- TreeNodeContainer: DatabaseBuilderTreeNodeContainer,
96
- }, innerProps: {
97
- toggleCheckedNode,
98
- isPartiallySelected,
99
- }, treeData: treeData, onNodeSelect: onNodeSelect, getChildNodes: getChildNodes }));
100
- });
101
- export const DatabaseBuilder = observer((props) => {
102
- const { databaseBuilderState, isReadOnly } = props;
103
- const applicationStore = useApplicationStore();
104
- const preview = applicationStore.guardUnhandledError(() => flowResult(databaseBuilderState.previewDatabaseModel()));
105
- const saveOrUpdateDatabase = applicationStore.guardUnhandledError(() => flowResult(databaseBuilderState.createOrUpdateDatabase()));
106
- const closeModal = () => {
107
- databaseBuilderState.setShowModal(false);
108
- databaseBuilderState.editorStore.explorerTreeState.setDatabaseBuilderState(undefined);
109
- };
110
- const isExecutingAction = databaseBuilderState.isBuildingDatabase ||
111
- databaseBuilderState.isSavingDatabase;
112
- const changeValue = (event) => {
113
- if (!databaseBuilderState.currentDatabase) {
114
- const stringValue = event.target.value;
115
- const updatedValue = stringValue ? stringValue : undefined;
116
- databaseBuilderState.setTargetDatabasePath(updatedValue ?? '');
117
- }
118
- };
119
- useEffect(() => {
120
- flowResult(databaseBuilderState.fetchDatabaseMetadata()).catch(applicationStore.alertUnhandledError);
121
- }, [databaseBuilderState, applicationStore]);
122
- useConditionedApplicationNavigationContext(LEGEND_STUDIO_APPLICATION_NAVIGATION_CONTEXT_KEY.DATABASE_BUILDER, databaseBuilderState.showModal);
123
- return (_jsx(Dialog, { open: databaseBuilderState.showModal, onClose: noop, classes: { container: 'search-modal__container' }, PaperProps: {
124
- classes: {
125
- root: 'search-modal__inner-container database-builder__container',
126
- },
127
- }, children: _jsxs(Modal, { darkMode: true, className: "database-builder", children: [_jsxs(ModalHeader, { children: [_jsx(ModalTitle, { title: "Database Builder" }), _jsx(ModalHeaderActions, { children: _jsx("button", { className: "modal__header__action", tabIndex: -1, onClick: closeModal, children: _jsx(TimesIcon, {}) }) })] }), _jsxs(ModalBody, { className: "database-builder__content", children: [_jsx(PanelLoadingIndicator, { isLoading: isExecutingAction }), _jsxs(ResizablePanelGroup, { orientation: "vertical", children: [_jsx(ResizablePanel, { size: 450, children: _jsxs("div", { className: "database-builder__config", children: [_jsx(PanelHeader, { title: "schema explorer" }), _jsx(PanelContent, { className: "database-builder__config__content", children: databaseBuilderState.treeData && (_jsx(DatabaseBuilderExplorer, { treeData: databaseBuilderState.treeData, isReadOnly: false, databaseBuilderState: databaseBuilderState })) })] }) }), _jsx(ResizablePanelSplitter, {}), _jsx(ResizablePanel, { children: _jsxs(Panel, { className: "database-builder__model", children: [_jsx(PanelHeader, { title: "database model" }), _jsx(PanelContent, { children: _jsxs("div", { className: "database-builder__modeller", children: [_jsxs("div", { className: "panel__content__form__section database-builder__modeller__path", children: [_jsx("div", { className: "panel__content__form__section__header__label", children: "Target Database Path" }), _jsx("input", { className: "panel__content__form__section__input", spellCheck: false, disabled: isReadOnly ||
128
- Boolean(databaseBuilderState.currentDatabase), value: databaseBuilderState.currentDatabase?.path ??
129
- databaseBuilderState.targetDatabasePath, onChange: changeValue })] }), _jsxs("div", { className: "database-builder__modeller__preview", children: [databaseBuilderState.databaseGrammarCode && (_jsx(CodeEditor, { language: CODE_EDITOR_LANGUAGE.PURE, inputValue: databaseBuilderState.databaseGrammarCode, isReadOnly: true })), !databaseBuilderState.databaseGrammarCode && (_jsx(BlankPanelContent, { children: "No database preview" }))] })] }) })] }) })] })] }), _jsxs(ModalFooter, { children: [_jsx(ModalFooterButton, { className: "database-builder__action--btn", disabled: isReadOnly || isExecutingAction, onClick: preview, title: "Preview database model...", children: "Preview" }), _jsx(ModalFooterButton, { className: "database-builder__action--btn", disabled: isReadOnly || isExecutingAction, onClick: saveOrUpdateDatabase, children: databaseBuilderState.currentDatabase
130
- ? 'Update Database'
131
- : 'Build Database' })] })] }) }));
132
- });
133
- //# sourceMappingURL=DatabaseBuilder.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"DatabaseBuilder.js","sourceRoot":"","sources":["../../../../../src/components/editor/editor-group/connection-editor/DatabaseBuilder.tsx"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;GAcG;AAEH,OAAO,EAAE,QAAQ,EAAE,MAAM,iBAAiB,CAAC;AAC3C,OAAO,EACL,MAAM,EAEN,mBAAmB,EACnB,cAAc,EACd,sBAAsB,EACtB,qBAAqB,EACrB,QAAQ,EACR,u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