@finos/legend-application-query 13.4.12 → 13.4.13
Sign up to get free protection for your applications and to get access to all the features.
- package/lib/components/Core_LegendQueryApplicationPlugin.d.ts +3 -0
- package/lib/components/Core_LegendQueryApplicationPlugin.d.ts.map +1 -1
- package/lib/components/Core_LegendQueryApplicationPlugin.js +250 -5
- package/lib/components/Core_LegendQueryApplicationPlugin.js.map +1 -1
- package/lib/components/QueryEditor.d.ts +8 -0
- package/lib/components/QueryEditor.d.ts.map +1 -1
- package/lib/components/QueryEditor.js +15 -136
- package/lib/components/QueryEditor.js.map +1 -1
- package/lib/components/__test-utils__/QueryEditorComponentTestUtils.d.ts.map +1 -1
- package/lib/components/__test-utils__/QueryEditorComponentTestUtils.js +2 -0
- package/lib/components/__test-utils__/QueryEditorComponentTestUtils.js.map +1 -1
- package/lib/components/data-space/DataSpaceQuerySetup.d.ts.map +1 -1
- package/lib/components/data-space/DataSpaceQuerySetup.js +7 -6
- package/lib/components/data-space/DataSpaceQuerySetup.js.map +1 -1
- package/lib/index.css +2 -2
- package/lib/index.css.map +1 -1
- package/lib/index.d.ts +1 -1
- package/lib/index.d.ts.map +1 -1
- package/lib/index.js +1 -1
- package/lib/index.js.map +1 -1
- package/lib/package.json +1 -1
- package/lib/stores/LegendQueryApplicationPlugin.d.ts +4 -4
- package/lib/stores/LegendQueryApplicationPlugin.d.ts.map +1 -1
- package/lib/stores/LegendQueryApplicationPlugin.js +1 -0
- package/lib/stores/LegendQueryApplicationPlugin.js.map +1 -1
- package/lib/stores/QueryEditorStore.d.ts +5 -1
- package/lib/stores/QueryEditorStore.d.ts.map +1 -1
- package/lib/stores/QueryEditorStore.js +12 -4
- package/lib/stores/QueryEditorStore.js.map +1 -1
- package/lib/stores/__test-utils__/LegendQueryApplicationTestUtils.js +1 -1
- package/lib/stores/__test-utils__/LegendQueryApplicationTestUtils.js.map +1 -1
- package/lib/stores/data-space/DataSpaceQueryCreatorStore.d.ts.map +1 -1
- package/lib/stores/data-space/DataSpaceQueryCreatorStore.js +2 -2
- package/lib/stores/data-space/DataSpaceQueryCreatorStore.js.map +1 -1
- package/lib/stores/data-space/DataSpaceQuerySetupState.d.ts +2 -1
- package/lib/stores/data-space/DataSpaceQuerySetupState.d.ts.map +1 -1
- package/lib/stores/data-space/DataSpaceQuerySetupState.js +6 -3
- package/lib/stores/data-space/DataSpaceQuerySetupState.js.map +1 -1
- package/lib/stores/data-space/DataSpaceTemplateQueryCreatorStore.d.ts.map +1 -1
- package/lib/stores/data-space/DataSpaceTemplateQueryCreatorStore.js +2 -2
- package/lib/stores/data-space/DataSpaceTemplateQueryCreatorStore.js.map +1 -1
- package/package.json +6 -6
- package/src/components/Core_LegendQueryApplicationPlugin.tsx +593 -1
- package/src/components/QueryEditor.tsx +30 -468
- package/src/components/__test-utils__/QueryEditorComponentTestUtils.tsx +2 -0
- package/src/components/data-space/DataSpaceQuerySetup.tsx +52 -53
- package/src/index.ts +2 -1
- package/src/stores/{LegendQueryApplicationPlugin.ts → LegendQueryApplicationPlugin.tsx} +11 -6
- package/src/stores/QueryEditorStore.ts +16 -0
- package/src/stores/__test-utils__/LegendQueryApplicationTestUtils.ts +1 -1
- package/src/stores/data-space/DataSpaceQueryCreatorStore.ts +2 -0
- package/src/stores/data-space/DataSpaceQuerySetupState.ts +8 -0
- package/src/stores/data-space/DataSpaceTemplateQueryCreatorStore.ts +2 -0
- package/tsconfig.json +2 -2
@@ -15,11 +15,14 @@
|
|
15
15
|
*/
|
16
16
|
import { LegendQueryApplicationPlugin, type QuerySetupActionConfiguration } from '../stores/LegendQueryApplicationPlugin.js';
|
17
17
|
import { type ApplicationPageEntry, type LegendApplicationSetup } from '@finos/legend-application';
|
18
|
+
import type { QueryBuilderHeaderActionConfiguration } from '@finos/legend-query-builder';
|
18
19
|
export declare class Core_LegendQueryApplicationPlugin extends LegendQueryApplicationPlugin {
|
19
20
|
static NAME: string;
|
20
21
|
constructor();
|
21
22
|
getExtraApplicationSetups(): LegendApplicationSetup[];
|
22
23
|
getExtraApplicationPageEntries(): ApplicationPageEntry[];
|
23
24
|
getExtraQuerySetupActionConfigurations(): QuerySetupActionConfiguration[];
|
25
|
+
getExtraQueryBuilderHeaderActionConfigurations?(): QueryBuilderHeaderActionConfiguration[];
|
26
|
+
getExtraQueryBuilderHeaderTitleConfigurations?(): QueryBuilderHeaderActionConfiguration;
|
24
27
|
}
|
25
28
|
//# sourceMappingURL=Core_LegendQueryApplicationPlugin.d.ts.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"Core_LegendQueryApplicationPlugin.d.ts","sourceRoot":"","sources":["../../src/components/Core_LegendQueryApplicationPlugin.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAEH,OAAO,EACL,4BAA4B,EAE5B,KAAK,6BAA6B,EACnC,MAAM,2CAA2C,CAAC;
|
1
|
+
{"version":3,"file":"Core_LegendQueryApplicationPlugin.d.ts","sourceRoot":"","sources":["../../src/components/Core_LegendQueryApplicationPlugin.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAEH,OAAO,EACL,4BAA4B,EAE5B,KAAK,6BAA6B,EACnC,MAAM,2CAA2C,CAAC;AAiCnD,OAAO,EAEL,KAAK,oBAAoB,EACzB,KAAK,sBAAsB,EAC5B,MAAM,2BAA2B,CAAC;AAanC,OAAO,KAAK,EAAE,qCAAqC,EAAE,MAAM,6BAA6B,CAAC;AAqBzF,qBAAa,iCAAkC,SAAQ,4BAA4B;IACjF,MAAM,CAAC,IAAI,SAAiD;;IAMnD,yBAAyB,IAAI,sBAAsB,EAAE;IASrD,8BAA8B,IAAI,oBAAoB,EAAE;IA+BxD,sCAAsC,IAAI,6BAA6B,EAAE;IAyGlF,8CAA8C,CAAC,IAAI,qCAAqC,EAAE;IA0f1F,6CAA6C,CAAC,IAAI,qCAAqC;CAgDxF"}
|
@@ -1,4 +1,4 @@
|
|
1
|
-
import { jsx as _jsx } from "react/jsx-runtime";
|
1
|
+
import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
|
2
2
|
/**
|
3
3
|
* Copyright (c) 2020-present, Goldman Sachs
|
4
4
|
*
|
@@ -16,15 +16,26 @@ import { jsx as _jsx } from "react/jsx-runtime";
|
|
16
16
|
*/
|
17
17
|
import { LegendQueryApplicationPlugin, QuerySetupActionTag, } from '../stores/LegendQueryApplicationPlugin.js';
|
18
18
|
import packageJson from '../../package.json' assert { type: 'json' };
|
19
|
-
import { ArrowCircleUpIcon, DroidIcon, ManageSearchIcon, PlusIcon, RobotIcon, SquareIcon, } from '@finos/legend-art';
|
20
|
-
import { generateCloneServiceQuerySetupRoute, generateCreateMappingQuerySetupRoute, generateEditExistingQuerySetupRoute, generateLoadProjectServiceQuerySetup, generateQueryProductionizerSetupRoute, generateUpdateExistingServiceQuerySetup, LEGEND_QUERY_ROUTE_PATTERN, } from '../__lib__/LegendQueryNavigation.js';
|
21
|
-
import {} from '@finos/legend-application';
|
19
|
+
import { ArrowCircleUpIcon, Button, CaretDownIcon, CheckIcon, DroidIcon, DropdownMenu, EmptyLightBulbIcon, LightBulbIcon, ManageSearchIcon, MenuContent, MenuContentItem, MenuContentItemIcon, MenuContentItemLabel, PlusIcon, RobotIcon, SaveAsIcon, SaveCurrIcon, SquareIcon, } from '@finos/legend-art';
|
20
|
+
import { generateCloneServiceQuerySetupRoute, generateCreateMappingQuerySetupRoute, generateEditExistingQuerySetupRoute, generateLoadProjectServiceQuerySetup, generateMappingQueryCreatorRoute, generateQueryProductionizerSetupRoute, generateUpdateExistingServiceQuerySetup, LEGEND_QUERY_ROUTE_PATTERN, } from '../__lib__/LegendQueryNavigation.js';
|
21
|
+
import { LEGEND_APPLICATION_COLOR_THEME, } from '@finos/legend-application';
|
22
22
|
import { CloneQueryServiceSetup } from './CloneQueryServiceSetup.js';
|
23
23
|
import { QueryProductionizerSetup } from './QueryProductionizerSetup.js';
|
24
24
|
import { UpdateExistingServiceQuerySetup } from './UpdateExistingServiceQuerySetup.js';
|
25
25
|
import { LoadProjectServiceQuerySetup } from './LoadProjectServiceQuerySetup.js';
|
26
26
|
import { configureCodeEditorComponent, setupPureLanguageService, } from '@finos/legend-lego/code-editor';
|
27
|
-
import { generateDataSpaceQuerySetupRoute } from '../__lib__/DSL_DataSpace_LegendQueryNavigation.js';
|
27
|
+
import { generateDataSpaceQueryCreatorRoute, generateDataSpaceQuerySetupRoute, } from '../__lib__/DSL_DataSpace_LegendQueryNavigation.js';
|
28
|
+
import { ExistingQueryEditorStore, QueryBuilderActionConfig_QueryApplication, createViewProjectHandler, createViewSDLCProjectHandler, } from '../stores/QueryEditorStore.js';
|
29
|
+
import { DataSpaceQueryBuilderState, generateDataSpaceTemplateQueryPromotionRoute, } from '@finos/legend-extension-dsl-data-space/application';
|
30
|
+
import { RuntimePointer } from '@finos/legend-graph';
|
31
|
+
import { QUERY_DOCUMENTATION_KEY } from '../application/LegendQueryDocumentation.js';
|
32
|
+
import { LegendQueryTelemetryHelper } from '../__lib__/LegendQueryTelemetryHelper.js';
|
33
|
+
import { StoreProjectData } from '@finos/legend-server-depot';
|
34
|
+
import { buildUrl } from '@finos/legend-shared';
|
35
|
+
import { parseProjectIdentifier } from '@finos/legend-storage';
|
36
|
+
import { QUERY_EDITOR_TEST_ID } from '../__lib__/LegendQueryTesting.js';
|
37
|
+
import { QueryEditorExistingQueryHeader } from './QueryEditor.js';
|
38
|
+
import { DataSpaceTemplateQueryCreatorStore } from '../stores/data-space/DataSpaceTemplateQueryCreatorStore.js';
|
28
39
|
export class Core_LegendQueryApplicationPlugin extends LegendQueryApplicationPlugin {
|
29
40
|
static NAME = packageJson.extensions.applicationQueryPlugin;
|
30
41
|
constructor() {
|
@@ -154,5 +165,239 @@ export class Core_LegendQueryApplicationPlugin extends LegendQueryApplicationPlu
|
|
154
165
|
},
|
155
166
|
];
|
156
167
|
}
|
168
|
+
getExtraQueryBuilderHeaderActionConfigurations() {
|
169
|
+
return [
|
170
|
+
{
|
171
|
+
key: 'promote-as-template-query',
|
172
|
+
category: 0,
|
173
|
+
renderer: (queryBuilderState) => {
|
174
|
+
if (queryBuilderState.workflowState.actionConfig instanceof
|
175
|
+
QueryBuilderActionConfig_QueryApplication) {
|
176
|
+
const editorStore = queryBuilderState.workflowState.actionConfig.editorStore;
|
177
|
+
const proceedCuratedTemplateQueryPromotion = async () => {
|
178
|
+
if (!(editorStore instanceof ExistingQueryEditorStore &&
|
179
|
+
queryBuilderState instanceof DataSpaceQueryBuilderState)) {
|
180
|
+
return;
|
181
|
+
}
|
182
|
+
// fetch project data
|
183
|
+
const project = StoreProjectData.serialization.fromJson(await editorStore.depotServerClient.getProject(editorStore.lightQuery.groupId, editorStore.lightQuery.artifactId));
|
184
|
+
// find the matching SDLC instance
|
185
|
+
const projectIDPrefix = parseProjectIdentifier(project.projectId).prefix;
|
186
|
+
const matchingSDLCEntry = editorStore.applicationStore.config.studioInstances.find((entry) => entry.sdlcProjectIDPrefix === projectIDPrefix);
|
187
|
+
if (matchingSDLCEntry) {
|
188
|
+
editorStore.applicationStore.navigationService.navigator.visitAddress(buildUrl([
|
189
|
+
editorStore.applicationStore.config.studioApplicationUrl,
|
190
|
+
generateDataSpaceTemplateQueryPromotionRoute(editorStore.lightQuery.groupId, editorStore.lightQuery.artifactId, editorStore.lightQuery.versionId, queryBuilderState.dataSpace.path, editorStore.lightQuery.id),
|
191
|
+
]));
|
192
|
+
}
|
193
|
+
else {
|
194
|
+
editorStore.applicationStore.notificationService.notifyWarning(`Can't find the corresponding SDLC instance to productionize the query`);
|
195
|
+
}
|
196
|
+
};
|
197
|
+
const proceedTemplate = () => {
|
198
|
+
queryBuilderState.changeDetectionState.alertUnsavedChanges(() => {
|
199
|
+
proceedCuratedTemplateQueryPromotion().catch(editorStore.applicationStore.alertUnhandledError);
|
200
|
+
});
|
201
|
+
};
|
202
|
+
return (_jsx(_Fragment, { children: editorStore instanceof ExistingQueryEditorStore &&
|
203
|
+
queryBuilderState instanceof DataSpaceQueryBuilderState && (_jsxs("button", { className: "query-editor__header__action btn--dark", tabIndex: -1, onClick: proceedTemplate, title: !(editorStore instanceof ExistingQueryEditorStore)
|
204
|
+
? 'Please save your query first before promoting'
|
205
|
+
: 'Promote Curated Template query...', children: [_jsx(ArrowCircleUpIcon, { className: "query-editor__header__action__icon--productionize" }), _jsx("div", { className: "query-editor__header__action__label", children: "Promote as Template Query" })] })) }));
|
206
|
+
}
|
207
|
+
return undefined;
|
208
|
+
},
|
209
|
+
},
|
210
|
+
{
|
211
|
+
key: 'load-query',
|
212
|
+
category: 0,
|
213
|
+
renderer: (queryBuilderState) => {
|
214
|
+
if (queryBuilderState.workflowState.actionConfig instanceof
|
215
|
+
QueryBuilderActionConfig_QueryApplication) {
|
216
|
+
const editorStore = queryBuilderState.workflowState.actionConfig.editorStore;
|
217
|
+
const openQueryLoader = () => {
|
218
|
+
editorStore.queryLoaderState.setQueryLoaderDialogOpen(true);
|
219
|
+
};
|
220
|
+
return (_jsxs(Button, { className: "query-editor__header__action btn--dark", disabled: editorStore.isPerformingBlockingAction, onClick: openQueryLoader, title: "Load query...", children: [_jsx(ManageSearchIcon, { className: "query-editor__header__action__icon--load" }), _jsx("div", { className: "query-editor__header__action__label", children: "Load Query" })] }));
|
221
|
+
}
|
222
|
+
return undefined;
|
223
|
+
},
|
224
|
+
},
|
225
|
+
{
|
226
|
+
key: 'new-query',
|
227
|
+
category: 0,
|
228
|
+
renderer: (queryBuilderState) => {
|
229
|
+
if (queryBuilderState.workflowState.actionConfig instanceof
|
230
|
+
QueryBuilderActionConfig_QueryApplication) {
|
231
|
+
const editorStore = queryBuilderState.workflowState.actionConfig.editorStore;
|
232
|
+
const isExistingQuery = editorStore instanceof ExistingQueryEditorStore;
|
233
|
+
const handleNewQuery = () => {
|
234
|
+
if (editorStore instanceof ExistingQueryEditorStore) {
|
235
|
+
const query = editorStore.query;
|
236
|
+
if (query) {
|
237
|
+
if (queryBuilderState instanceof DataSpaceQueryBuilderState) {
|
238
|
+
editorStore.applicationStore.navigationService.navigator.goToLocation(generateDataSpaceQueryCreatorRoute(query.groupId, query.artifactId, query.versionId, queryBuilderState.dataSpace.path, queryBuilderState.executionContext.name, undefined, undefined));
|
239
|
+
}
|
240
|
+
else {
|
241
|
+
const mapping = editorStore.queryBuilderState?.executionContextState
|
242
|
+
.mapping;
|
243
|
+
const runtime = editorStore.queryBuilderState?.executionContextState
|
244
|
+
.runtimeValue;
|
245
|
+
if (mapping && runtime instanceof RuntimePointer) {
|
246
|
+
editorStore.applicationStore.navigationService.navigator.goToLocation(generateMappingQueryCreatorRoute(query.groupId, query.artifactId, query.versionId, mapping.path, runtime.packageableRuntime.value.path));
|
247
|
+
}
|
248
|
+
}
|
249
|
+
}
|
250
|
+
}
|
251
|
+
};
|
252
|
+
return (_jsx(_Fragment, { children: isExistingQuery && (_jsxs(Button, { className: "query-editor__header__action btn--dark", disabled: editorStore.isPerformingBlockingAction, onClick: handleNewQuery, title: "New query", children: [_jsx(SaveCurrIcon, {}), _jsx("div", { className: "query-editor__header__action__label", children: "New Query" })] })) }));
|
253
|
+
}
|
254
|
+
return undefined;
|
255
|
+
},
|
256
|
+
},
|
257
|
+
{
|
258
|
+
key: 'save-query',
|
259
|
+
category: 0,
|
260
|
+
renderer: (queryBuilderState) => {
|
261
|
+
if (queryBuilderState.workflowState.actionConfig instanceof
|
262
|
+
QueryBuilderActionConfig_QueryApplication) {
|
263
|
+
const editorStore = queryBuilderState.workflowState.actionConfig.editorStore;
|
264
|
+
const isExistingQuery = editorStore instanceof ExistingQueryEditorStore;
|
265
|
+
const openSaveQueryModal = () => {
|
266
|
+
if (editorStore instanceof ExistingQueryEditorStore) {
|
267
|
+
editorStore.updateState.showSaveModal();
|
268
|
+
}
|
269
|
+
};
|
270
|
+
return (_jsxs(Button, { className: "query-editor__header__action btn--dark", disabled: !isExistingQuery ||
|
271
|
+
editorStore.isPerformingBlockingAction ||
|
272
|
+
!queryBuilderState.canBuildQuery, onClick: openSaveQueryModal, title: !queryBuilderState.canBuildQuery
|
273
|
+
? 'Please fix query errors before saving'
|
274
|
+
: 'Save query', children: [_jsx(SaveCurrIcon, {}), _jsx("div", { className: "query-editor__header__action__label", children: "Save" })] }));
|
275
|
+
}
|
276
|
+
return undefined;
|
277
|
+
},
|
278
|
+
},
|
279
|
+
{
|
280
|
+
key: 'save-as',
|
281
|
+
category: 0,
|
282
|
+
renderer: (queryBuilderState) => {
|
283
|
+
if (queryBuilderState.workflowState.actionConfig instanceof
|
284
|
+
QueryBuilderActionConfig_QueryApplication) {
|
285
|
+
const editorStore = queryBuilderState.workflowState.actionConfig.editorStore;
|
286
|
+
const handleQuerySaveAs = () => {
|
287
|
+
editorStore.queryCreatorState.open(editorStore instanceof ExistingQueryEditorStore
|
288
|
+
? editorStore.query
|
289
|
+
: undefined);
|
290
|
+
};
|
291
|
+
return (_jsxs(Button, { className: "query-editor__header__action btn--dark", disabled: editorStore.isPerformingBlockingAction ||
|
292
|
+
!queryBuilderState.canBuildQuery, onClick: handleQuerySaveAs, title: !queryBuilderState.canBuildQuery
|
293
|
+
? 'Please fix query errors before saving'
|
294
|
+
: 'Save as new query', children: [_jsx(SaveAsIcon, {}), _jsx("div", { className: "query-editor__header__action__label", children: "Save As..." })] }));
|
295
|
+
}
|
296
|
+
return undefined;
|
297
|
+
},
|
298
|
+
},
|
299
|
+
{
|
300
|
+
key: 'help',
|
301
|
+
category: 0,
|
302
|
+
renderer: (queryBuilderState) => {
|
303
|
+
if (queryBuilderState.workflowState.actionConfig instanceof
|
304
|
+
QueryBuilderActionConfig_QueryApplication) {
|
305
|
+
const editorStore = queryBuilderState.workflowState.actionConfig.editorStore;
|
306
|
+
const queryDocEntry = editorStore.applicationStore.documentationService.getDocEntry(QUERY_DOCUMENTATION_KEY.TUTORIAL_QUERY_BUILDER);
|
307
|
+
const toggleAssistant = () => editorStore.applicationStore.assistantService.toggleAssistant();
|
308
|
+
const openQueryTutorial = () => {
|
309
|
+
if (queryDocEntry?.url) {
|
310
|
+
editorStore.applicationStore.navigationService.navigator.visitAddress(queryDocEntry.url);
|
311
|
+
}
|
312
|
+
};
|
313
|
+
const extraHelpMenuContentItems = editorStore.applicationStore.pluginManager
|
314
|
+
.getApplicationPlugins()
|
315
|
+
.flatMap((plugin) => plugin.getExtraQueryEditorHelpMenuActionConfigurations?.() ??
|
316
|
+
[])
|
317
|
+
.map((item) => (_jsxs(MenuContentItem, { title: item.title ?? '', onClick: () => item.onClick(editorStore), children: [item.icon && (_jsx(MenuContentItemIcon, { children: item.icon })), _jsx(MenuContentItemLabel, { children: item.label })] }, item.key)));
|
318
|
+
return (_jsxs(DropdownMenu, { className: "query-editor__header__action btn--dark", disabled: editorStore.isViewProjectActionDisabled, content: _jsxs(MenuContent, { children: [extraHelpMenuContentItems, queryDocEntry && (_jsxs(MenuContentItem, { onClick: openQueryTutorial, children: [_jsx(MenuContentItemIcon, { children: null }), _jsx(MenuContentItemLabel, { children: "Open Documentation" })] })), _jsxs(MenuContentItem, { onClick: toggleAssistant, children: [_jsx(MenuContentItemIcon, { children: !editorStore.applicationStore.assistantService
|
319
|
+
.isHidden ? (_jsx(CheckIcon, {})) : null }), _jsx(MenuContentItemLabel, { children: "Show Virtual Assistant" })] })] }), children: [_jsx("div", { className: "query-editor__header__action__label", title: "See more options", children: "Help..." }), _jsx(CaretDownIcon, { className: "query-editor__header__action__dropdown-trigger" })] }));
|
320
|
+
}
|
321
|
+
return undefined;
|
322
|
+
},
|
323
|
+
},
|
324
|
+
{
|
325
|
+
key: 'toggle-theme',
|
326
|
+
category: 0,
|
327
|
+
renderer: (queryBuilderState) => {
|
328
|
+
if (queryBuilderState.workflowState.actionConfig instanceof
|
329
|
+
QueryBuilderActionConfig_QueryApplication) {
|
330
|
+
const editorStore = queryBuilderState.workflowState.actionConfig.editorStore;
|
331
|
+
const applicationStore = editorStore.applicationStore;
|
332
|
+
const TEMPORARY__toggleLightDarkMode = () => {
|
333
|
+
applicationStore.layoutService.setColorTheme(applicationStore.layoutService
|
334
|
+
.TEMPORARY__isLightColorThemeEnabled
|
335
|
+
? LEGEND_APPLICATION_COLOR_THEME.DEFAULT_DARK
|
336
|
+
: LEGEND_APPLICATION_COLOR_THEME.LEGACY_LIGHT, { persist: true });
|
337
|
+
};
|
338
|
+
return (_jsx("button", { title: "Toggle light/dark mode", onClick: TEMPORARY__toggleLightDarkMode, className: "query-editor__header__action query-editor__header__action__theme-toggler", children: applicationStore.layoutService
|
339
|
+
.TEMPORARY__isLightColorThemeEnabled ? (_jsx(_Fragment, { children: _jsx(LightBulbIcon, { className: "query-editor__header__action__icon--bulb--light" }) })) : (_jsx(_Fragment, { children: _jsx(EmptyLightBulbIcon, { className: "query-editor__header__action__icon--bulb--dark" }) })) }));
|
340
|
+
}
|
341
|
+
return undefined;
|
342
|
+
},
|
343
|
+
},
|
344
|
+
{
|
345
|
+
key: 'more-actions',
|
346
|
+
category: 0,
|
347
|
+
renderer: (queryBuilderState) => {
|
348
|
+
if (queryBuilderState.workflowState.actionConfig instanceof
|
349
|
+
QueryBuilderActionConfig_QueryApplication) {
|
350
|
+
const editorStore = queryBuilderState.workflowState.actionConfig.editorStore;
|
351
|
+
const isExistingQuery = editorStore instanceof ExistingQueryEditorStore;
|
352
|
+
const renameQuery = () => {
|
353
|
+
if (editorStore instanceof ExistingQueryEditorStore) {
|
354
|
+
editorStore.updateState.setQueryRenamer(true);
|
355
|
+
}
|
356
|
+
};
|
357
|
+
const showQueryInfo = () => {
|
358
|
+
if (editorStore instanceof ExistingQueryEditorStore) {
|
359
|
+
editorStore.updateState.setShowQueryInfo(true);
|
360
|
+
}
|
361
|
+
};
|
362
|
+
const viewProject = () => {
|
363
|
+
LegendQueryTelemetryHelper.logEvent_QueryViewProjectLaunched(editorStore.applicationStore.telemetryService);
|
364
|
+
const { groupId, artifactId, versionId } = editorStore.getProjectInfo();
|
365
|
+
createViewProjectHandler(editorStore.applicationStore)(groupId, artifactId, versionId, undefined);
|
366
|
+
};
|
367
|
+
const viewSDLCProject = () => {
|
368
|
+
LegendQueryTelemetryHelper.logEvent_QueryViewSdlcProjectLaunched(editorStore.applicationStore.telemetryService);
|
369
|
+
const { groupId, artifactId } = editorStore.getProjectInfo();
|
370
|
+
createViewSDLCProjectHandler(editorStore.applicationStore, editorStore.depotServerClient)(groupId, artifactId, undefined).catch(editorStore.applicationStore.alertUnhandledError);
|
371
|
+
};
|
372
|
+
return (_jsxs(DropdownMenu, { className: "query-editor__header__action btn--medium", disabled: editorStore.isViewProjectActionDisabled, content: _jsxs(MenuContent, { children: [isExistingQuery && (_jsx(MenuContentItem, { className: "query-editor__header__action__options", onClick: renameQuery, disabled: !isExistingQuery, children: "Rename Query" })), isExistingQuery && (_jsx(MenuContentItem, { className: "query-editor__header__action__options", onClick: showQueryInfo, disabled: !isExistingQuery, children: "Get Query Info" })), _jsx(MenuContentItem, { className: "query-editor__header__action__options", disabled: editorStore.isViewProjectActionDisabled, onClick: viewProject, children: "Go to Project" }), _jsx(MenuContentItem, { className: "query-editor__header__action__options", disabled: editorStore.isViewProjectActionDisabled, onClick: viewSDLCProject, children: "Go to SDLC project" })] }), children: [_jsx("div", { className: "query-editor__header__action__label", title: "See more options", children: "More Actions..." }), _jsx(CaretDownIcon, { className: "query-editor__header__action__dropdown-trigger" })] }));
|
373
|
+
}
|
374
|
+
return undefined;
|
375
|
+
},
|
376
|
+
},
|
377
|
+
];
|
378
|
+
}
|
379
|
+
getExtraQueryBuilderHeaderTitleConfigurations() {
|
380
|
+
return {
|
381
|
+
key: 'query-title',
|
382
|
+
category: 0,
|
383
|
+
renderer: (queryBuilderState) => {
|
384
|
+
if (queryBuilderState.workflowState.actionConfig instanceof
|
385
|
+
QueryBuilderActionConfig_QueryApplication) {
|
386
|
+
const editorStore = queryBuilderState.workflowState.actionConfig.editorStore;
|
387
|
+
const renderQueryTitle = () => {
|
388
|
+
if (editorStore instanceof ExistingQueryEditorStore) {
|
389
|
+
return (_jsx(QueryEditorExistingQueryHeader, { queryBuilderState: queryBuilderState, existingEditorStore: editorStore }));
|
390
|
+
}
|
391
|
+
else if (editorStore instanceof DataSpaceTemplateQueryCreatorStore) {
|
392
|
+
return (_jsxs("div", { className: "query-editor__dataspace__header", children: [_jsx("div", { className: "query-editor__header__content__main query-editor__header__content__title__text query-editor__dataspace__header__title__text", children: editorStore.templateQueryTitle }), _jsx("div", { className: "query-editor__dataspace__header__title__tag", children: "template" })] }));
|
393
|
+
}
|
394
|
+
return undefined;
|
395
|
+
};
|
396
|
+
return (_jsx("div", { className: "query-editor__header__content", "data-testid": QUERY_EDITOR_TEST_ID.QUERY_EDITOR_ACTIONS, children: renderQueryTitle() }));
|
397
|
+
}
|
398
|
+
return undefined;
|
399
|
+
},
|
400
|
+
};
|
401
|
+
}
|
157
402
|
}
|
158
403
|
//# sourceMappingURL=Core_LegendQueryApplicationPlugin.js.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"Core_LegendQueryApplicationPlugin.js","sourceRoot":"","sources":["../../src/components/Core_LegendQueryApplicationPlugin.tsx"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;GAcG;AAEH,OAAO,EACL,4BAA4B,EAC5B,mBAAmB,GAEpB,MAAM,2CAA2C,CAAC;AACnD,OAAO,WAAW,MAAM,oBAAoB,CAAC,SAAS,IAAI,EAAE,MAAM,EAAE,CAAC;AAErE,OAAO,EACL,iBAAiB,EACjB,SAAS,EACT,gBAAgB,EAChB,QAAQ,EACR,SAAS,EACT,UAAU,GACX,MAAM,mBAAmB,CAAC;AAC3B,OAAO,EACL,mCAAmC,EACnC,oCAAoC,EACpC,mCAAmC,EACnC,oCAAoC,EACpC,qCAAqC,EACrC,uCAAuC,EACvC,0BAA0B,GAC3B,MAAM,qCAAqC,CAAC;AAC7C,OAAO,EAGN,MAAM,2BAA2B,CAAC;AACnC,OAAO,EAAE,sBAAsB,EAAE,MAAM,6BAA6B,CAAC;AACrE,OAAO,EAAE,wBAAwB,EAAE,MAAM,+BAA+B,CAAC;AACzE,OAAO,EAAE,+BAA+B,EAAE,MAAM,sCAAsC,CAAC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D,IAAI,EAAE,CACJ,KAAC,UAAU,IAAC,SAAS,EAAC,6CAA6C,GAAG,CACvE;aACF;SACF,CAAC;IACJ,CAAC"}
|
1
|
+
{"version":3,"file":"Core_LegendQueryApplicationPlugin.js","sourceRoot":"","sources":["../../src/components/Core_LegendQueryApplicationPlugin.tsx"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;GAcG;AAEH,OAAO,EACL,4BAA4B,EAC5B,mBAAmB,GAEpB,MAAM,2CAA2C,CAAC;AACnD,OAAO,WAAW,MAAM,oBAAoB,CAAC,SAAS,IAAI,EAAE,MAAM,EAAE,CAAC;AAErE,OAAO,EACL,iBAAiB,EACjB,MAAM,EACN,aAAa,EACb,SAAS,EACT,SAAS,EACT,YAAY,EACZ,kBAAkB,EAClB,aAAa,EACb,gBAAgB,EAChB,WAAW,EACX,eAAe,EACf,mBAAmB,EACnB,oBAAoB,EACpB,QAAQ,EACR,SAAS,EACT,UAAU,EACV,YAAY,EACZ,UAAU,GACX,MAAM,mBAAmB,CAAC;AAC3B,OAAO,EACL,mCAAmC,EACnC,oCAAoC,EACpC,mCAAmC,EACnC,oCAAoC,EACpC,gCAAgC,EAChC,qCAAqC,EACrC,uCAAuC,EACvC,0BAA0B,GAC3B,MAAM,qCAAqC,CAAC;AAC7C,OAAO,EACL,8BAA8B,GAG/B,MAAM,2BAA2B,CAAC;AACnC,OAAO,EAAE,sBAAsB,EAAE,MAAM,6BAA6B,CAAC;AACrE,OAAO,EAAE,wBAAwB,EAAE,MAAM,+BAA+B,CAAC;AACzE,OAAO,EAAE,+BAA+B,EAAE,MAAM,sCAAsC,CAAC;AACvF,OAAO,EAAE,4BAA4B,EAAE,MAAM,mCAAmC,CAAC;AACjF,OAAO,EACL,4BAA4B,EAC5B,wBAAwB,GACzB,MAAM,gCAAgC,CAAC;AACxC,OAAO,EACL,kCAAkC,EAClC,gCAAgC,GACjC,MAAM,mDAAmD,CAAC;AAE3D,OAAO,EACL,wBAAwB,EACxB,yCAAyC,E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wBACJ,CAAC;6BAAM,IACL,WAAW,YAAY,kCAAkC,EACzD,CAAC;4BACD,OAAO,CACL,eAAK,SAAS,EAAC,iCAAiC,aAC9C,cAAK,SAAS,EAAC,6HAA6H,YACzI,WAAW,CAAC,kBAAkB,GAC3B,EACN,cAAK,SAAS,EAAC,6CAA6C,yBAEtD,IACF,CACP,CAAC;wBACJ,CAAC;wBACD,OAAO,SAAS,CAAC;oBACnB,CAAC,CAAC;oBACF,OAAO,CACL,cACE,SAAS,EAAC,+BAA+B,iBAC5B,oBAAoB,CAAC,oBAAoB,YAErD,gBAAgB,EAAE,GACf,CACP,CAAC;gBACJ,CAAC;gBACD,OAAO,SAAS,CAAC;YACnB,CAAC;SACF,CAAC;IACJ,CAAC"}
|
@@ -13,6 +13,14 @@
|
|
13
13
|
* See the License for the specific language governing permissions and
|
14
14
|
* limitations under the License.
|
15
15
|
*/
|
16
|
+
import { ExistingQueryEditorStore } from '../stores/QueryEditorStore.js';
|
17
|
+
import { type QueryBuilderState } from '@finos/legend-query-builder';
|
18
|
+
export declare const QueryEditorExistingQueryHeader: ((props: {
|
19
|
+
queryBuilderState: QueryBuilderState;
|
20
|
+
existingEditorStore: ExistingQueryEditorStore;
|
21
|
+
}) => import("react/jsx-runtime").JSX.Element) & {
|
22
|
+
displayName: string;
|
23
|
+
};
|
16
24
|
export declare const QueryEditor: (() => import("react/jsx-runtime").JSX.Element) & {
|
17
25
|
displayName: string;
|
18
26
|
};
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"QueryEditor.d.ts","sourceRoot":"","sources":["../../src/components/QueryEditor.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;
|
1
|
+
{"version":3,"file":"QueryEditor.d.ts","sourceRoot":"","sources":["../../src/components/QueryEditor.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAwCH,OAAO,EAAE,wBAAwB,EAAE,MAAM,+BAA+B,CAAC;AAUzE,OAAO,EAKL,KAAK,iBAAiB,EACvB,MAAM,6BAA6B,CAAC;AAuLrC,eAAO,MAAM,8BAA8B,WACjC;IACN,iBAAiB,EAAE,iBAAiB,CAAC;IACrC,mBAAmB,EAAE,wBAAwB,CAAC;CAC/C;;CA6GF,CAAC;AAsLF,eAAO,MAAM,WAAW;;CA4ItB,CAAC;AAEH,eAAO,MAAM,mBAAmB;;CAS9B,CAAC;AAEH,eAAO,MAAM,mBAAmB;;CAmB9B,CAAC;AAEH,eAAO,MAAM,mBAAmB;;CAe9B,CAAC"}
|
@@ -14,29 +14,22 @@ import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-run
|
|
14
14
|
* See the License for the specific language governing permissions and
|
15
15
|
* limitations under the License.
|
16
16
|
*/
|
17
|
-
import { Dialog, PanelLoadingIndicator, BlankPanelContent, DropdownMenu, MenuContent, MenuContentItem,
|
17
|
+
import { Dialog, PanelLoadingIndicator, BlankPanelContent, DropdownMenu, MenuContent, MenuContentItem, MenuIcon, MenuContentDivider, MenuContentItemIcon, CheckIcon, MenuContentItemLabel, Modal, ModalHeader, ModalBody, ModalFooter, ModalTitle, ModalFooterButton, ExclamationTriangleIcon, PanelListItem, clsx, ModalHeaderActions, TimesIcon, Panel, PanelFullContent, CustomSelectorInput, } from '@finos/legend-art';
|
18
18
|
import { observer } from 'mobx-react-lite';
|
19
19
|
import { Fragment, useEffect, useMemo, useRef, useState } from 'react';
|
20
|
-
import { LEGEND_QUERY_QUERY_PARAM_TOKEN, LEGEND_QUERY_ROUTE_PATTERN_TOKEN, generateQuerySetupRoute, generateExistingQueryEditorRoute,
|
21
|
-
import {
|
22
|
-
import {
|
20
|
+
import { LEGEND_QUERY_QUERY_PARAM_TOKEN, LEGEND_QUERY_ROUTE_PATTERN_TOKEN, generateQuerySetupRoute, generateExistingQueryEditorRoute, } from '../__lib__/LegendQueryNavigation.js';
|
21
|
+
import { ExistingQueryEditorStore } from '../stores/QueryEditorStore.js';
|
22
|
+
import { useApplicationStore } from '@finos/legend-application';
|
23
23
|
import { useParams } from '@finos/legend-application/browser';
|
24
24
|
import { MappingQueryCreatorStoreProvider, ExistingQueryEditorStoreProvider, ServiceQueryCreatorStoreProvider, useQueryEditorStore, } from './QueryEditorStoreProvider.js';
|
25
25
|
import { flowResult } from 'mobx';
|
26
|
-
import { useLegendQueryApplicationStore } from './LegendQueryFrameworkProvider.js';
|
27
26
|
import { QueryBuilder, QueryBuilderNavigationBlocker, QueryLoaderDialog, QueryBuilderDiffViewPanel, } from '@finos/legend-query-builder';
|
28
|
-
import {
|
29
|
-
import {
|
30
|
-
import {
|
31
|
-
import { QUERY_EDITOR_TEST_ID } from '../__lib__/LegendQueryTesting.js';
|
32
|
-
import { compareSemVerVersions, generateGAVCoordinates, parseProjectIdentifier, } from '@finos/legend-storage';
|
33
|
-
import { QueryDataSpaceExecutionContext, QueryExplicitExecutionContext, RuntimePointer, } from '@finos/legend-graph';
|
34
|
-
import { LATEST_VERSION_ALIAS, StoreProjectData, } from '@finos/legend-server-depot';
|
27
|
+
import { compareSemVerVersions, generateGAVCoordinates, } from '@finos/legend-storage';
|
28
|
+
import { QueryDataSpaceExecutionContext, QueryExplicitExecutionContext, } from '@finos/legend-graph';
|
29
|
+
import { LATEST_VERSION_ALIAS } from '@finos/legend-server-depot';
|
35
30
|
import { buildVersionOption } from './QuerySetup.js';
|
36
31
|
import { QueryEditorExistingQueryVersionRevertModal } from './QueryEdtiorExistingQueryVersionRevertModal.js';
|
37
|
-
import {
|
38
|
-
import { generateDataSpaceQueryCreatorRoute } from '../__lib__/DSL_DataSpace_LegendQueryNavigation.js';
|
39
|
-
import { DataSpaceTemplateQueryCreatorStore } from '../stores/data-space/DataSpaceTemplateQueryCreatorStore.js';
|
32
|
+
import { debounce } from '@finos/legend-shared';
|
40
33
|
const CreateQueryDialog = observer(() => {
|
41
34
|
const editorStore = useQueryEditorStore();
|
42
35
|
const createQueryState = editorStore.queryCreatorState;
|
@@ -89,7 +82,7 @@ const SaveQueryDialog = observer((props) => {
|
|
89
82
|
paper: 'editor-modal__content',
|
90
83
|
}, children: _jsxs(Modal, { darkMode: !applicationStore.layoutService.TEMPORARY__isLightColorThemeEnabled, className: clsx('editor-modal query-builder-text-mode__modal'), children: [_jsxs(ModalHeader, { children: [_jsx(ModalTitle, { title: "Save Existing Query" }), _jsx(ModalHeaderActions, { children: _jsx("button", { className: "modal__header__action", tabIndex: -1, onClick: close, children: _jsx(TimesIcon, {}) }) })] }), _jsxs(ModalBody, { children: [_jsx(PanelLoadingIndicator, { isLoading: updateState.updateQueryState.isInProgress }), updateState.updateDiffState && (_jsx(QueryBuilderDiffViewPanel, { diffViewState: updateState.updateDiffState }))] }), _jsxs(ModalFooter, { children: [_jsx(ModalFooterButton, { text: "Save", title: "Save (Will Overwrite Existing Query)", disabled: Boolean(existingEditorStore.isPerformingBlockingAction), onClick: saveQuery }), _jsx(ModalFooterButton, { text: "Close", onClick: close, type: "secondary" })] })] }) }));
|
91
84
|
});
|
92
|
-
const QueryEditorExistingQueryHeader = observer((props) => {
|
85
|
+
export const QueryEditorExistingQueryHeader = observer((props) => {
|
93
86
|
const { existingEditorStore } = props;
|
94
87
|
const updateState = existingEditorStore.updateState;
|
95
88
|
const isRenaming = updateState.queryRenamer;
|
@@ -179,128 +172,11 @@ const QueryEditorExistingQueryInfoModal = observer((props) => {
|
|
179
172
|
updateState.queryVersionId !== query.versionId && (_jsxs(_Fragment, { children: [_jsx("div", { className: "query-preview__field__warning__icon", children: _jsx(ExclamationTriangleIcon, {}) }), _jsx("div", { className: "query-preview__field__warning__label", children: "Update action will reload query" })] })) }), _jsxs("div", { className: "search-modal__actions", children: [_jsx(ModalFooterButton, { text: "Update", disabled: !updateState.queryVersionId ||
|
180
173
|
updateState.queryVersionId === query.versionId, onClick: updateQueryVersionId }), _jsx(ModalFooterButton, { text: "Close", onClick: closeModal, type: "secondary" })] })] })] }) }));
|
181
174
|
});
|
182
|
-
const QueryEditorHeaderContent = observer((props) => {
|
183
|
-
const { queryBuilderState } = props;
|
184
|
-
const editorStore = useQueryEditorStore();
|
185
|
-
const applicationStore = useLegendQueryApplicationStore();
|
186
|
-
const isExistingQuery = editorStore instanceof ExistingQueryEditorStore;
|
187
|
-
const renameQuery = () => {
|
188
|
-
if (editorStore instanceof ExistingQueryEditorStore) {
|
189
|
-
editorStore.updateState.setQueryRenamer(true);
|
190
|
-
}
|
191
|
-
};
|
192
|
-
const showQueryInfo = () => {
|
193
|
-
if (editorStore instanceof ExistingQueryEditorStore) {
|
194
|
-
editorStore.updateState.setShowQueryInfo(true);
|
195
|
-
}
|
196
|
-
};
|
197
|
-
// actions
|
198
|
-
const openQueryLoader = () => {
|
199
|
-
editorStore.queryLoaderState.setQueryLoaderDialogOpen(true);
|
200
|
-
};
|
201
|
-
const viewProject = () => {
|
202
|
-
LegendQueryTelemetryHelper.logEvent_QueryViewProjectLaunched(editorStore.applicationStore.telemetryService);
|
203
|
-
const { groupId, artifactId, versionId } = editorStore.getProjectInfo();
|
204
|
-
createViewProjectHandler(applicationStore)(groupId, artifactId, versionId, undefined);
|
205
|
-
};
|
206
|
-
const viewSDLCProject = () => {
|
207
|
-
LegendQueryTelemetryHelper.logEvent_QueryViewSdlcProjectLaunched(editorStore.applicationStore.telemetryService);
|
208
|
-
const { groupId, artifactId } = editorStore.getProjectInfo();
|
209
|
-
createViewSDLCProjectHandler(applicationStore, editorStore.depotServerClient)(groupId, artifactId, undefined).catch(applicationStore.alertUnhandledError);
|
210
|
-
};
|
211
|
-
const TEMPORARY__toggleLightDarkMode = () => {
|
212
|
-
applicationStore.layoutService.setColorTheme(applicationStore.layoutService.TEMPORARY__isLightColorThemeEnabled
|
213
|
-
? LEGEND_APPLICATION_COLOR_THEME.DEFAULT_DARK
|
214
|
-
: LEGEND_APPLICATION_COLOR_THEME.LEGACY_LIGHT, { persist: true });
|
215
|
-
};
|
216
|
-
const openSaveQueryModal = () => {
|
217
|
-
if (editorStore instanceof ExistingQueryEditorStore) {
|
218
|
-
editorStore.updateState.showSaveModal();
|
219
|
-
}
|
220
|
-
};
|
221
|
-
const handleNewQuery = () => {
|
222
|
-
if (editorStore instanceof ExistingQueryEditorStore) {
|
223
|
-
const query = editorStore.query;
|
224
|
-
if (query) {
|
225
|
-
if (queryBuilderState instanceof DataSpaceQueryBuilderState) {
|
226
|
-
editorStore.applicationStore.navigationService.navigator.goToLocation(generateDataSpaceQueryCreatorRoute(query.groupId, query.artifactId, query.versionId, queryBuilderState.dataSpace.path, queryBuilderState.executionContext.name, undefined, undefined));
|
227
|
-
}
|
228
|
-
else {
|
229
|
-
const mapping = editorStore.queryBuilderState?.executionContextState.mapping;
|
230
|
-
const runtime = editorStore.queryBuilderState?.executionContextState.runtimeValue;
|
231
|
-
if (mapping && runtime instanceof RuntimePointer) {
|
232
|
-
editorStore.applicationStore.navigationService.navigator.goToLocation(generateMappingQueryCreatorRoute(query.groupId, query.artifactId, query.versionId, mapping.path, runtime.packageableRuntime.value.path));
|
233
|
-
}
|
234
|
-
}
|
235
|
-
}
|
236
|
-
}
|
237
|
-
};
|
238
|
-
const toggleAssistant = () => applicationStore.assistantService.toggleAssistant();
|
239
|
-
const queryDocEntry = applicationStore.documentationService.getDocEntry(QUERY_DOCUMENTATION_KEY.TUTORIAL_QUERY_BUILDER);
|
240
|
-
const openQueryTutorial = () => {
|
241
|
-
if (queryDocEntry?.url) {
|
242
|
-
applicationStore.navigationService.navigator.visitAddress(queryDocEntry.url);
|
243
|
-
}
|
244
|
-
};
|
245
|
-
const handleQuerySaveAs = () => {
|
246
|
-
editorStore.queryCreatorState.open(editorStore instanceof ExistingQueryEditorStore
|
247
|
-
? editorStore.query
|
248
|
-
: undefined);
|
249
|
-
};
|
250
|
-
const renderQueryTitle = () => {
|
251
|
-
if (editorStore instanceof ExistingQueryEditorStore) {
|
252
|
-
return (_jsx(QueryEditorExistingQueryHeader, { queryBuilderState: queryBuilderState, existingEditorStore: editorStore }));
|
253
|
-
}
|
254
|
-
else if (editorStore instanceof DataSpaceTemplateQueryCreatorStore) {
|
255
|
-
return (_jsxs("div", { className: "query-editor__dataspace__header", children: [_jsx("div", { className: "query-editor__header__content__main query-editor__header__content__title__text query-editor__dataspace__header__title__text", children: editorStore.templateQueryTitle }), _jsx("div", { className: "query-editor__dataspace__header__title__tag", children: "template" })] }));
|
256
|
-
}
|
257
|
-
return (_jsx("div", { className: "query-editor__header__content__main query-editor__header__content__title" }));
|
258
|
-
};
|
259
|
-
const extraHelpMenuContentItems = applicationStore.pluginManager
|
260
|
-
.getApplicationPlugins()
|
261
|
-
.flatMap((plugin) => plugin.getExtraQueryEditorHelpMenuActionConfigurations?.() ?? [])
|
262
|
-
.map((item) => (_jsxs(MenuContentItem, { title: item.title ?? '', onClick: () => item.onClick(editorStore), children: [item.icon && _jsx(MenuContentItemIcon, { children: item.icon }), _jsx(MenuContentItemLabel, { children: item.label })] }, item.key)));
|
263
|
-
const proceedCuratedTemplateQueryPromotion = async () => {
|
264
|
-
if (!(editorStore instanceof ExistingQueryEditorStore &&
|
265
|
-
queryBuilderState instanceof DataSpaceQueryBuilderState)) {
|
266
|
-
return;
|
267
|
-
}
|
268
|
-
// fetch project data
|
269
|
-
const project = StoreProjectData.serialization.fromJson(await editorStore.depotServerClient.getProject(editorStore.lightQuery.groupId, editorStore.lightQuery.artifactId));
|
270
|
-
// find the matching SDLC instance
|
271
|
-
const projectIDPrefix = parseProjectIdentifier(project.projectId).prefix;
|
272
|
-
const matchingSDLCEntry = editorStore.applicationStore.config.studioInstances.find((entry) => entry.sdlcProjectIDPrefix === projectIDPrefix);
|
273
|
-
if (matchingSDLCEntry) {
|
274
|
-
editorStore.applicationStore.navigationService.navigator.visitAddress(buildUrl([
|
275
|
-
editorStore.applicationStore.config.studioApplicationUrl,
|
276
|
-
generateDataSpaceTemplateQueryPromotionRoute(editorStore.lightQuery.groupId, editorStore.lightQuery.artifactId, editorStore.lightQuery.versionId, queryBuilderState.dataSpace.path, editorStore.lightQuery.id),
|
277
|
-
]));
|
278
|
-
}
|
279
|
-
else {
|
280
|
-
editorStore.applicationStore.notificationService.notifyWarning(`Can't find the corresponding SDLC instance to productionize the query`);
|
281
|
-
}
|
282
|
-
};
|
283
|
-
const proceedTemplate = () => {
|
284
|
-
queryBuilderState.changeDetectionState.alertUnsavedChanges(() => {
|
285
|
-
proceedCuratedTemplateQueryPromotion().catch(editorStore.applicationStore.alertUnhandledError);
|
286
|
-
});
|
287
|
-
};
|
288
|
-
return (_jsxs("div", { className: "query-editor__header__content", "data-testid": QUERY_EDITOR_TEST_ID.QUERY_EDITOR_ACTIONS, children: [renderQueryTitle(), _jsxs("div", { className: "query-editor__header__actions", children: [applicationStore.pluginManager
|
289
|
-
.getApplicationPlugins()
|
290
|
-
.flatMap((plugin) => plugin.getExtraQueryEditorActionConfigurations?.(editorStore) ??
|
291
|
-
[])
|
292
|
-
.map((actionConfig) => (_jsx(Fragment, { children: actionConfig.renderer(editorStore, queryBuilderState) }, actionConfig.key))), _jsx(_Fragment, { children: editorStore instanceof ExistingQueryEditorStore &&
|
293
|
-
queryBuilderState instanceof DataSpaceQueryBuilderState && (_jsxs("button", { className: "query-editor__header__action btn--dark", tabIndex: -1, onClick: proceedTemplate, title: !(editorStore instanceof ExistingQueryEditorStore)
|
294
|
-
? 'Please save your query first before promoting'
|
295
|
-
: 'Promote Curated Template query...', children: [_jsx(ArrowCircleUpIcon, { className: "query-editor__header__action__icon--productionize" }), _jsx("div", { className: "query-editor__header__action__label", children: "Promote as Template Query" })] })) }), _jsxs(Button, { className: "query-editor__header__action btn--dark", disabled: editorStore.isPerformingBlockingAction, onClick: openQueryLoader, title: "Load query...", children: [_jsx(ManageSearchIcon, { className: "query-editor__header__action__icon--load" }), _jsx("div", { className: "query-editor__header__action__label", children: "Load Query" })] }), isExistingQuery && (_jsxs(Button, { className: "query-editor__header__action btn--dark", disabled: editorStore.isPerformingBlockingAction, onClick: handleNewQuery, title: "New query", children: [_jsx(SaveCurrIcon, {}), _jsx("div", { className: "query-editor__header__action__label", children: "New Query" })] })), _jsxs(Button, { className: "query-editor__header__action btn--dark", disabled: !isExistingQuery || editorStore.isPerformingBlockingAction, onClick: openSaveQueryModal, title: "Save query", children: [_jsx(SaveCurrIcon, {}), _jsx("div", { className: "query-editor__header__action__label", children: "Save" })] }), _jsxs(Button, { className: "query-editor__header__action btn--dark", disabled: editorStore.isPerformingBlockingAction, onClick: handleQuerySaveAs, title: "Save as new query", children: [_jsx(SaveAsIcon, {}), _jsx("div", { className: "query-editor__header__action__label", children: "Save As..." })] }), _jsxs(DropdownMenu, { className: "query-editor__header__action btn--dark", disabled: editorStore.isViewProjectActionDisabled, content: _jsxs(MenuContent, { children: [extraHelpMenuContentItems, queryDocEntry && (_jsxs(MenuContentItem, { onClick: openQueryTutorial, children: [_jsx(MenuContentItemIcon, { children: null }), _jsx(MenuContentItemLabel, { children: "Open Documentation" })] })), _jsxs(MenuContentItem, { onClick: toggleAssistant, children: [_jsx(MenuContentItemIcon, { children: !applicationStore.assistantService.isHidden ? (_jsx(CheckIcon, {})) : null }), _jsx(MenuContentItemLabel, { children: "Show Virtual Assistant" })] })] }), children: [_jsx("div", { className: "query-editor__header__action__label", title: "See more options", children: "Help..." }), _jsx(CaretDownIcon, { className: "query-editor__header__action__dropdown-trigger" })] }), editorStore.queryLoaderState.isQueryLoaderDialogOpen && (_jsx(QueryLoaderDialog, { queryLoaderState: editorStore.queryLoaderState, title: "Load query" })), _jsx("button", { title: "Toggle light/dark mode", onClick: TEMPORARY__toggleLightDarkMode, className: "query-editor__header__action query-editor__header__action__theme-toggler", children: applicationStore.layoutService
|
296
|
-
.TEMPORARY__isLightColorThemeEnabled ? (_jsx(_Fragment, { children: _jsx(LightBulbIcon, { className: "query-editor__header__action__icon--bulb--light" }) })) : (_jsx(_Fragment, { children: _jsx(EmptyLightBulbIcon, { className: "query-editor__header__action__icon--bulb--dark" }) })) }), _jsxs(DropdownMenu, { className: "query-editor__header__action btn--medium", disabled: editorStore.isViewProjectActionDisabled, content: _jsxs(MenuContent, { children: [isExistingQuery && (_jsx(MenuContentItem, { className: "query-editor__header__action__options", onClick: renameQuery, disabled: !isExistingQuery, children: "Rename Query" })), isExistingQuery && (_jsx(MenuContentItem, { className: "query-editor__header__action__options", onClick: showQueryInfo, disabled: !isExistingQuery, children: "Get Query Info" })), _jsx(MenuContentItem, { className: "query-editor__header__action__options", disabled: editorStore.isViewProjectActionDisabled, onClick: viewProject, children: "Go to Project" }), _jsx(MenuContentItem, { className: "query-editor__header__action__options", disabled: editorStore.isViewProjectActionDisabled, onClick: viewSDLCProject, children: "Go to SDLC project" })] }), children: [_jsx("div", { className: "query-editor__header__action__label", title: "See more options", children: "More Actions..." }), _jsx(CaretDownIcon, { className: "query-editor__header__action__dropdown-trigger" })] }), editorStore.queryCreatorState.showCreateModal && (_jsx(CreateQueryDialog, {})), isExistingQuery &&
|
297
|
-
editorStore.updateState.showQueryInfo &&
|
298
|
-
editorStore.query && (_jsx(QueryEditorExistingQueryInfoModal, { existingEditorStore: editorStore, query: editorStore.query }))] })] }));
|
299
|
-
});
|
300
175
|
export const QueryEditor = observer(() => {
|
301
176
|
const applicationStore = useApplicationStore();
|
302
177
|
const editorStore = useQueryEditorStore();
|
303
178
|
const isLoadingEditor = !editorStore.initState.hasCompleted;
|
179
|
+
const isExistingQuery = editorStore instanceof ExistingQueryEditorStore;
|
304
180
|
// documentation
|
305
181
|
const appDocUrl = applicationStore.documentationService.url;
|
306
182
|
const docLinks = applicationStore.documentationService.links;
|
@@ -314,6 +190,7 @@ export const QueryEditor = observer(() => {
|
|
314
190
|
};
|
315
191
|
// go to setup page
|
316
192
|
const goToQuerySetup = () => applicationStore.navigationService.navigator.visitAddress(applicationStore.navigationService.navigator.generateAddress(generateQuerySetupRoute()));
|
193
|
+
const goToReleaseLog = () => applicationStore.releaseNotesService.setReleaseLog(true);
|
317
194
|
// settings
|
318
195
|
// NOTE: this is temporary until we find a better home for these settings in query builder
|
319
196
|
const engineConfig = editorStore.graphManagerState.graphManager.TEMPORARY__getEngineConfig();
|
@@ -321,11 +198,13 @@ export const QueryEditor = observer(() => {
|
|
321
198
|
useEffect(() => {
|
322
199
|
flowResult(editorStore.initialize()).catch(applicationStore.alertUnhandledError);
|
323
200
|
}, [editorStore, applicationStore]);
|
324
|
-
return (_jsxs("div", { className: "query-editor", children: [_jsxs("div", { className: "query-
|
201
|
+
return (_jsxs("div", { className: "query-editor", children: [_jsxs("div", { className: "query-editor__logo-header", children: [_jsx("div", { className: "query-editor__logo-header__menu", children: _jsx(DropdownMenu, { className: "query-editor__logo-header__menu-item", menuProps: {
|
325
202
|
anchorOrigin: { vertical: 'top', horizontal: 'right' },
|
326
203
|
transformOrigin: { vertical: 'top', horizontal: 'left' },
|
327
204
|
elevation: 7,
|
328
|
-
}, content: _jsxs(MenuContent, { children: [_jsx(MenuContentItem, { onClick: goToQuerySetup, children: "Back to query setup" }), _jsx(MenuContentItem, { disabled: !appDocUrl, onClick: goToDocumentation, children: "Documentation" }), docLinks?.map((entry) => (_jsx(MenuContentItem, { onClick: () => goToDocLink(entry.url), children: entry.label }, entry.key))), _jsx(MenuContentDivider, {}), _jsx(MenuContentItem, { disabled: true, children: "Settings" }), _jsxs(MenuContentItem, { onClick: toggleEngineClientRequestPayloadCompression, children: [_jsx(MenuContentItemIcon, { children: engineConfig.useClientRequestPayloadCompression ? (_jsx(CheckIcon, {})) : null }), _jsx(MenuContentItemLabel, { children: "Compress request payload" })] })] }), children: _jsx(MenuIcon, {}) }) }),
|
205
|
+
}, content: _jsxs(MenuContent, { children: [_jsx(MenuContentItem, { onClick: goToQuerySetup, children: "Back to query setup" }), _jsx(MenuContentItem, { onClick: goToReleaseLog, children: "Legend Query Release Log" }), _jsx(MenuContentItem, { disabled: !appDocUrl, onClick: goToDocumentation, children: "Documentation" }), docLinks?.map((entry) => (_jsx(MenuContentItem, { onClick: () => goToDocLink(entry.url), children: entry.label }, entry.key))), _jsx(MenuContentDivider, {}), _jsx(MenuContentItem, { disabled: true, children: "Settings" }), _jsxs(MenuContentItem, { onClick: toggleEngineClientRequestPayloadCompression, children: [_jsx(MenuContentItemIcon, { children: engineConfig.useClientRequestPayloadCompression ? (_jsx(CheckIcon, {})) : null }), _jsx(MenuContentItemLabel, { children: "Compress request payload" })] })] }), children: _jsx(MenuIcon, {}) }) }), _jsx("div", { className: "query-editor__logo-header__name", children: "Legend Query" }), editorStore.queryLoaderState.isQueryLoaderDialogOpen && (_jsx(QueryLoaderDialog, { queryLoaderState: editorStore.queryLoaderState, title: "Load query" })), editorStore.queryCreatorState.showCreateModal && _jsx(CreateQueryDialog, {}), isExistingQuery &&
|
206
|
+
editorStore.updateState.showQueryInfo &&
|
207
|
+
editorStore.query && (_jsx(QueryEditorExistingQueryInfoModal, { existingEditorStore: editorStore, query: editorStore.query }))] }), _jsxs("div", { className: "query-editor__content", children: [_jsx(PanelLoadingIndicator, { isLoading: isLoadingEditor }), !isLoadingEditor && editorStore.queryBuilderState && (_jsxs(_Fragment, { children: [_jsx(QueryBuilderNavigationBlocker, { queryBuilderState: editorStore.queryBuilderState }), _jsx(QueryBuilder, { queryBuilderState: editorStore.queryBuilderState })] })), isLoadingEditor && (_jsx(BlankPanelContent, { children: editorStore.initState.message ??
|
329
208
|
editorStore.graphManagerState.systemBuildState.message ??
|
330
209
|
editorStore.graphManagerState.dependenciesBuildState.message ??
|
331
210
|
editorStore.graphManagerState.generationsBuildState.message ??
|