@finos/legend-application-query 13.5.48 → 13.5.49

Sign up to get free protection for your applications and to get access to all the features.
@@ -1 +1 @@
1
- {"version":3,"file":"DataSpaceInfo.d.ts","sourceRoot":"","sources":["../../../src/components/data-space/DataSpaceInfo.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAeH,OAAO,EAAE,KAAK,gBAAgB,EAAE,MAAM,kCAAkC,CAAC;AACzE,OAAO,EACL,KAAK,SAAS,EACd,KAAK,yBAAyB,EAE/B,MAAM,8CAA8C,CAAC;AAYtD,eAAO,MAAM,6BAA6B,WAChC;IACN,WAAW,EAAE,gBAAgB,CAAC;IAC9B,SAAS,EAAE,SAAS,CAAC;IACrB,gBAAgB,EAAE,yBAAyB,CAAC;IAC5C,IAAI,EAAE,OAAO,CAAC;IACd,UAAU,EAAE,MAAM,IAAI,CAAC;CACxB;;CAuOF,CAAC"}
1
+ {"version":3,"file":"DataSpaceInfo.d.ts","sourceRoot":"","sources":["../../../src/components/data-space/DataSpaceInfo.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAeH,OAAO,EAAE,KAAK,gBAAgB,EAAE,MAAM,kCAAkC,CAAC;AACzE,OAAO,EACL,KAAK,SAAS,EACd,KAAK,yBAAyB,EAG/B,MAAM,8CAA8C,CAAC;AAYtD,eAAO,MAAM,6BAA6B,WAChC;IACN,WAAW,EAAE,gBAAgB,CAAC;IAC9B,SAAS,EAAE,SAAS,CAAC;IACrB,gBAAgB,EAAE,yBAAyB,CAAC;IAC5C,IAAI,EAAE,OAAO,CAAC;IACd,UAAU,EAAE,MAAM,IAAI,CAAC;CACxB;;CAgQF,CAAC"}
@@ -18,7 +18,7 @@ import { Dialog, Modal, ModalTitle, Panel, PanelFullContent, } from '@finos/lege
18
18
  import { LATEST_VERSION_ALIAS, StoreProjectData, VersionedProjectData, } from '@finos/legend-server-depot';
19
19
  import { observer } from 'mobx-react-lite';
20
20
  import {} from '../../stores/QueryEditorStore.js';
21
- import { DataSpaceSupportEmail, } from '@finos/legend-extension-dsl-data-space/graph';
21
+ import { DataSpaceQueryBuilderState, DataSpaceSupportEmail, } from '@finos/legend-extension-dsl-data-space/graph';
22
22
  import { EXTERNAL_APPLICATION_NAVIGATION__generateStudioSDLCProjectViewUrl, EXTERNAL_APPLICATION_NAVIGATION__generateTaxonomyDataspaceViewUrl, } from '../../__lib__/LegendQueryNavigation.js';
23
23
  import { flowResult } from 'mobx';
24
24
  import { assertErrorThrown } from '@finos/legend-shared';
@@ -43,11 +43,30 @@ export const QueryEditorDataspaceInfoModal = observer((props) => {
43
43
  : `Can't visit project`);
44
44
  }
45
45
  };
46
- const connection = executionContext.defaultRuntime.value.runtimeValue.connections[0]
47
- ?.storeConnections[0]?.connection instanceof ConnectionPointer
46
+ const dataSpaceAnalysisResult = editorStore.queryBuilderState instanceof DataSpaceQueryBuilderState
47
+ ? editorStore.queryBuilderState.dataSpaceAnalysisResult
48
+ : undefined;
49
+ const dataSpaceMedata = dataSpaceAnalysisResult?.executionContextsIndex.get(executionContext.name)?.runtimeMetadata;
50
+ const connection = executionContext.defaultRuntime.value.runtimeValue.connections.length > 0
48
51
  ? executionContext.defaultRuntime.value.runtimeValue.connections[0]
49
- ?.storeConnections[0]?.connection
52
+ ?.storeConnections?.[0]?.connection instanceof ConnectionPointer
53
+ ? executionContext.defaultRuntime.value.runtimeValue.connections[0]
54
+ ?.storeConnections?.[0]?.connection
55
+ : undefined
50
56
  : undefined;
57
+ const connectionPath = connection
58
+ ? connection.packageableConnection.value.path
59
+ : dataSpaceMedata
60
+ ? dataSpaceMedata.connectionPath
61
+ : undefined;
62
+ const connectionType = connection &&
63
+ connection.packageableConnection.value.connectionValue instanceof
64
+ RelationalDatabaseConnection
65
+ ? connection.packageableConnection.value.connectionValue.type
66
+ : dataSpaceMedata
67
+ ? dataSpaceMedata.connectionType
68
+ : undefined;
69
+ const storePath = connection?.store?.value.path ?? dataSpaceMedata?.storePath;
51
70
  const openInTaxonomy = () => {
52
71
  if (projectInfo &&
53
72
  editorStore.applicationStore.config.taxonomyApplicationUrl) {
@@ -58,13 +77,22 @@ export const QueryEditorDataspaceInfoModal = observer((props) => {
58
77
  classes: { root: 'dataspace-info-modal__inner-container' },
59
78
  }, children: _jsxs(Modal, { darkMode: !editorStore.applicationStore.layoutService
60
79
  .TEMPORARY__isLightColorThemeEnabled, className: "dataspace-info-modal", children: [_jsxs("div", { className: "dataspace-info-modal__header", children: [_jsx(ModalTitle, { title: "About Dataspace" }), _jsx("button", { className: "btn--dark dataspace-info-modal__header__open-btn", title: "Close", disabled: !(editorStore.applicationStore.config.taxonomyApplicationUrl &&
61
- projectInfo), onClick: openInTaxonomy, children: "Open Dataspace" })] }), _jsx(Panel, { children: _jsxs(PanelFullContent, { children: [projectInfo && (_jsxs("div", { className: "dataspace-info-modal__field", children: [_jsx("div", { className: "dataspace-info-modal__field__label", children: "Project" }), _jsx("div", { className: "dataspace-info-modal__field__value dataspace-info-modal__field__value--linkable", onClick: () => flowResult(visitElement(undefined)), children: `${projectInfo.groupId}:${projectInfo.artifactId}:${projectInfo.versionId}` })] })), _jsxs("div", { className: "dataspace-info-modal__field", children: [_jsx("div", { className: "dataspace-info-modal__field__label", children: "Name" }), _jsx("div", { className: "dataspace-info-modal__field__value", children: dataspace.title ?? dataspace.name })] }), _jsxs("div", { className: "dataspace-info-modal__field", children: [_jsx("div", { className: "dataspace-info-modal__field__label", children: "Execution Context" }), _jsx("div", { className: "dataspace-info-modal__field__value", children: executionContext.name })] }), _jsxs("div", { className: "dataspace-info-modal__field", children: [_jsx("div", { className: "dataspace-info-modal__field__label", children: "Mapping" }), _jsx("div", { className: "dataspace-info-modal__field__value dataspace-info-modal__field__value--linkable", onClick: () => flowResult(visitElement(executionContext.mapping.value.path)), children: executionContext.mapping.value.name })] }), _jsxs("div", { className: "dataspace-info-modal__field", children: [_jsx("div", { className: "dataspace-info-modal__field__label", children: "Runtime" }), _jsx("div", { className: "dataspace-info-modal__field__value dataspace-info-modal__field__value--linkable", onClick: () => flowResult(visitElement(executionContext.defaultRuntime.value.path)), children: executionContext.defaultRuntime.value.name })] }), connection && (_jsxs(_Fragment, { children: [connection.store && (_jsxs("div", { className: "dataspace-info-modal__field", children: [_jsx("div", { className: "dataspace-info-modal__field__label", children: "Store" }), _jsx("div", { className: "dataspace-info-modal__field__value dataspace-info-modal__field__value--linkable", onClick: () => {
62
- if (connection.store) {
63
- flowResult(visitElement(connection.store.value.path));
80
+ projectInfo), onClick: openInTaxonomy, children: "Open Dataspace" })] }), _jsx(Panel, { children: _jsxs(PanelFullContent, { children: [projectInfo && (_jsxs("div", { className: "dataspace-info-modal__field", children: [_jsx("div", { className: "dataspace-info-modal__field__label", children: "Project" }), _jsx("div", { className: "dataspace-info-modal__field__value dataspace-info-modal__field__value--linkable", onClick: () => flowResult(visitElement(undefined)), children: `${projectInfo.groupId}:${projectInfo.artifactId}:${projectInfo.versionId}` })] })), _jsxs("div", { className: "dataspace-info-modal__field", children: [_jsx("div", { className: "dataspace-info-modal__field__label", children: "Name" }), _jsx("div", { className: "dataspace-info-modal__field__value", children: dataspace.title ?? dataspace.name })] }), _jsxs("div", { className: "dataspace-info-modal__field", children: [_jsx("div", { className: "dataspace-info-modal__field__label", children: "Execution Context" }), _jsx("div", { className: "dataspace-info-modal__field__value", children: executionContext.name })] }), _jsxs("div", { className: "dataspace-info-modal__field", children: [_jsx("div", { className: "dataspace-info-modal__field__label", children: "Mapping" }), _jsx("div", { className: "dataspace-info-modal__field__value dataspace-info-modal__field__value--linkable", onClick: () => flowResult(visitElement(executionContext.mapping.value.path)), children: executionContext.mapping.value.name })] }), _jsxs("div", { className: "dataspace-info-modal__field", children: [_jsx("div", { className: "dataspace-info-modal__field__label", children: "Runtime" }), _jsx("div", { className: "dataspace-info-modal__field__value dataspace-info-modal__field__value--linkable", onClick: () => flowResult(visitElement(executionContext.defaultRuntime.value.path)), children: executionContext.defaultRuntime.value.name })] }), (connection || dataSpaceMedata) && (_jsxs(_Fragment, { children: [storePath && (_jsxs("div", { className: "dataspace-info-modal__field", children: [_jsx("div", { className: "dataspace-info-modal__field__label", children: "Store" }), _jsx("div", { className: "dataspace-info-modal__field__value dataspace-info-modal__field__value--linkable", onClick: () => {
81
+ flowResult(visitElement(storePath));
82
+ }, children: connection?.store?.value.name ?? storePath })] })), _jsxs("div", { className: "dataspace-info-modal__field", children: [_jsx("div", { className: "dataspace-info-modal__field__label", children: "Connection" }), _jsx("div", { className: "dataspace-info-modal__field__value dataspace-info-modal__field__value--linkable", onClick: () => {
83
+ if (connectionPath) {
84
+ flowResult(visitElement(connectionPath));
64
85
  }
65
- }, children: connection.store.value.name })] })), _jsxs("div", { className: "dataspace-info-modal__field", children: [_jsx("div", { className: "dataspace-info-modal__field__label", children: "Connection" }), _jsx("div", { className: "dataspace-info-modal__field__value dataspace-info-modal__field__value--linkable", onClick: () => flowResult(visitElement(connection.packageableConnection.value.path)), children: connection.packageableConnection.value
66
- .connectionValue instanceof RelationalDatabaseConnection
86
+ }, children: connection &&
87
+ connection.packageableConnection.value
88
+ .connectionValue instanceof RelationalDatabaseConnection
67
89
  ? `${connection.packageableConnection.value.name}:${connection.packageableConnection.value.connectionValue.type}`
68
- : connection.packageableConnection.value.name })] })] })), _jsxs("div", { className: "dataspace-info-modal__field", children: [_jsx("div", { className: "dataspace-info-modal__field__label", children: "Configuration" }), _jsx("div", { className: "dataspace-info-modal__field__value dataspace-info-modal__field__value--linkable", onClick: () => flowResult(visitElement(dataspace.path)), children: "Show Dataspace Configuration" })] }), dataspace.supportInfo instanceof DataSpaceSupportEmail && (_jsxs("div", { className: "dataspace-info-modal__field", children: [_jsx("div", { className: "dataspace-info-modal__field__label", children: "Support Email" }), _jsx("a", { className: "dataspace-info-modal__field__value dataspace-info-modal__field__value--linkable", href: `mailto:${dataspace.supportInfo.address}`, children: dataspace.supportInfo.address })] }))] }) })] }) }));
90
+ : connection
91
+ ? connection.packageableConnection.value.name
92
+ : connectionPath && connectionType
93
+ ? `${connectionPath}:${connectionType}`
94
+ : connectionPath
95
+ ? `${connectionPath}`
96
+ : `${connectionType}` })] })] })), _jsxs("div", { className: "dataspace-info-modal__field", children: [_jsx("div", { className: "dataspace-info-modal__field__label", children: "Configuration" }), _jsx("div", { className: "dataspace-info-modal__field__value dataspace-info-modal__field__value--linkable", onClick: () => flowResult(visitElement(dataspace.path)), children: "Show Dataspace Configuration" })] }), dataspace.supportInfo instanceof DataSpaceSupportEmail && (_jsxs("div", { className: "dataspace-info-modal__field", children: [_jsx("div", { className: "dataspace-info-modal__field__label", children: "Support Email" }), _jsx("a", { className: "dataspace-info-modal__field__value dataspace-info-modal__field__value--linkable", href: `mailto:${dataspace.supportInfo.address}`, children: dataspace.supportInfo.address })] }))] }) })] }) }));
69
97
  });
70
98
  //# sourceMappingURL=DataSpaceInfo.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"DataSpaceInfo.js","sourceRoot":"","sources":["../../../src/components/data-space/DataSpaceInfo.tsx"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;GAcG;AAEH,OAAO,EACL,MAAM,EACN,KAAK,EACL,UAAU,EACV,KAAK,EACL,gBAAgB,GACjB,MAAM,mBAAmB,CAAC;AAC3B,OAAO,EACL,oBAAoB,EACpB,gBAAgB,EAChB,oBAAoB,GACrB,MAAM,4BAA4B,CAAC;AACpC,OAAO,EAAE,QAAQ,EAAE,MAAM,iBAAiB,CAAC;AAC3C,OAAO,EAAyB,MAAM,kCAAkC,CAAC;AACzE,OAAO,EAGL,qBAAqB,GACtB,MAAM,8CAA8C,CAAC;AACtD,OAAO,EACL,iEAAiE,EACjE,iEAAiE,GAClE,MAAM,wCAAwC,CAAC;AAChD,OAAO,EAAE,UAAU,EAAE,MAAM,MAAM,CAAC;AAClC,OAAO,EAAE,iBAAiB,EAAE,MAAM,sBAAsB,CAAC;AACzD,OAAO,EACL,iBAAiB,EACjB,4BAA4B,GAC7B,MAAM,qBAAqB,CAAC;AAE7B,MAAM,CAAC,MAAM,6BAA6B,GAAG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BAA6B,aAC1C,cAAK,SAAS,EAAC,oCAAoC,8BAE7C,EACN,YACE,SAAS,EAAC,iFAAiF,EAC3F,IAAI,EAAE,UAAU,SAAS,CAAC,WAAW,CAAC,OAAO,EAAE,YAE9C,SAAS,CAAC,WAAW,CAAC,OAAO,GAC5B,IACA,CACP,IACgB,GACb,IACF,GACD,CACV,CAAC;AACJ,CAAC,CACF,CAAC"}
1
+ {"version":3,"file":"DataSpaceInfo.js","sourceRoot":"","sources":["../../../src/components/data-space/DataSpaceInfo.tsx"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;GAcG;AAEH,OAAO,EACL,MAAM,EACN,KAAK,EACL,UAAU,EACV,KAAK,EACL,gBAAgB,GACjB,MAAM,mBAAmB,CAAC;AAC3B,OAAO,EACL,oBAAoB,EACpB,gBAAgB,EAChB,oBAAoB,GACrB,MAAM,4BAA4B,CAAC;AACpC,OAAO,EAAE,QAAQ,EAAE,MAAM,iBAAiB,CAAC;AAC3C,OAAO,EAAyB,MAAM,kCAAkC,CAAC;AACzE,OAAO,EAGL,0BAA0B,EAC1B,qBAAqB,GACtB,MAAM,8CAA8C,CAAC;AACtD,OAAO,EACL,iEAAiE,EACjE,iEAAiE,GAClE,MAAM,wCAAwC,CAAC;AAChD,OAAO,EAAE,UAAU,EAAE,MAAM,MAAM,CAAC;AAClC,OAAO,EAAE,iBAAiB,EAAE,MAAM,sBAAsB,CAAC;AACzD,OAAO,EACL,iBAAiB,EACjB,4BAA4B,GAC7B,MAAM,qBAAqB,CAAC;AAE7B,MAAM,CAAC,MAAM,6BAA6B,GAAG,QAAQ,CACnD,CAAC,KAMA,EAAE,EAAE;IACH,MAAM,EAAE,WAAW,EAAE,SAAS,EAAE,gBAAgB,EAAE,IAAI,EAAE,UAAU,EAAE,GAClE,KAAK,CAAC;IACR,MAAM,WAAW,GAAG,WAAW,CAAC,cAAc,EAAE,CAAC;IACjD,MAAM,YAAY,GAAG,KAAK,EAAE,IAAwB,EAAiB,EAAE;QACrE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AU,CAAC,YAAY,CAAC,cAAc,CAAC,CAAC,CAAC;oDAC3C,CAAC;gDACH,CAAC,YAEA,UAAU;oDACX,UAAU,CAAC,qBAAqB,CAAC,KAAK;yDACnC,eAAe,YAAY,4BAA4B;oDACxD,CAAC,CAAC,GAAG,UAAU,CAAC,qBAAqB,CAAC,KAAK,CAAC,IAAI,IAAI,UAAU,CAAC,qBAAqB,CAAC,KAAK,CAAC,eAAe,CAAC,IAAI,EAAE;oDACjH,CAAC,CAAC,UAAU;wDACV,CAAC,CAAC,UAAU,CAAC,qBAAqB,CAAC,KAAK,CAAC,IAAI;wDAC7C,CAAC,CAAC,cAAc,IAAI,cAAc;4DAChC,CAAC,CAAC,GAAG,cAAc,IAAI,cAAc,EAAE;4DACvC,CAAC,CAAC,cAAc;gEACd,CAAC,CAAC,GAAG,cAAc,EAAE;gEACrB,CAAC,CAAC,GAAG,cAAc,EAAE,GACzB,IACF,IACL,CACJ,EACD,eAAK,SAAS,EAAC,6BAA6B,aAC1C,cAAK,SAAS,EAAC,oCAAoC,8BAE7C,EACN,cACE,SAAS,EAAC,iFAAiF,EAC3F,OAAO,EAAE,GAAG,EAAE,CAAC,UAAU,CAAC,YAAY,CAAC,SAAS,CAAC,IAAI,CAAC,CAAC,6CAGnD,IACF,EACL,SAAS,CAAC,WAAW,YAAY,qBAAqB,IAAI,CACzD,eAAK,SAAS,EAAC,6BAA6B,aAC1C,cAAK,SAAS,EAAC,oCAAoC,8BAE7C,EACN,YACE,SAAS,EAAC,iFAAiF,EAC3F,IAAI,EAAE,UAAU,SAAS,CAAC,WAAW,CAAC,OAAO,EAAE,YAE9C,SAAS,CAAC,WAAW,CAAC,OAAO,GAC5B,IACA,CACP,IACgB,GACb,IACF,GACD,CACV,CAAC;AACJ,CAAC,CACF,CAAC"}
package/lib/index.css CHANGED
@@ -1,4 +1,4 @@
1
- /** @license @finos/legend-application-query v13.5.48
1
+ /** @license @finos/legend-application-query v13.5.49
2
2
  * Copyright (c) 2020-present, Goldman Sachs
3
3
  *
4
4
  * Licensed under the Apache License, Version 2.0 (the "License");
package/lib/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@finos/legend-application-query",
3
- "version": "13.5.48",
3
+ "version": "13.5.49",
4
4
  "description": "Legend Query application core",
5
5
  "keywords": [
6
6
  "legend",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@finos/legend-application-query",
3
- "version": "13.5.48",
3
+ "version": "13.5.49",
4
4
  "description": "Legend Query application core",
5
5
  "keywords": [
6
6
  "legend",
@@ -43,12 +43,12 @@
43
43
  "test:watch": "jest --watch"
44
44
  },
45
45
  "dependencies": {
46
- "@finos/legend-application": "15.1.29",
47
- "@finos/legend-art": "7.1.56",
48
- "@finos/legend-extension-dsl-data-space": "10.3.69",
49
- "@finos/legend-graph": "31.10.29",
50
- "@finos/legend-lego": "1.2.68",
51
- "@finos/legend-query-builder": "4.14.88",
46
+ "@finos/legend-application": "15.1.30",
47
+ "@finos/legend-art": "7.1.57",
48
+ "@finos/legend-extension-dsl-data-space": "10.3.70",
49
+ "@finos/legend-graph": "31.10.30",
50
+ "@finos/legend-lego": "1.2.69",
51
+ "@finos/legend-query-builder": "4.14.89",
52
52
  "@finos/legend-server-depot": "6.0.59",
53
53
  "@finos/legend-shared": "10.0.54",
54
54
  "@finos/legend-storage": "3.0.104",
@@ -31,6 +31,7 @@ import { type QueryEditorStore } from '../../stores/QueryEditorStore.js';
31
31
  import {
32
32
  type DataSpace,
33
33
  type DataSpaceExecutionContext,
34
+ DataSpaceQueryBuilderState,
34
35
  DataSpaceSupportEmail,
35
36
  } from '@finos/legend-extension-dsl-data-space/graph';
36
37
  import {
@@ -93,12 +94,36 @@ export const QueryEditorDataspaceInfoModal = observer(
93
94
  }
94
95
  };
95
96
 
97
+ const dataSpaceAnalysisResult =
98
+ editorStore.queryBuilderState instanceof DataSpaceQueryBuilderState
99
+ ? editorStore.queryBuilderState.dataSpaceAnalysisResult
100
+ : undefined;
101
+ const dataSpaceMedata = dataSpaceAnalysisResult?.executionContextsIndex.get(
102
+ executionContext.name,
103
+ )?.runtimeMetadata;
96
104
  const connection =
97
- executionContext.defaultRuntime.value.runtimeValue.connections[0]
98
- ?.storeConnections[0]?.connection instanceof ConnectionPointer
105
+ executionContext.defaultRuntime.value.runtimeValue.connections.length > 0
99
106
  ? executionContext.defaultRuntime.value.runtimeValue.connections[0]
100
- ?.storeConnections[0]?.connection
107
+ ?.storeConnections?.[0]?.connection instanceof ConnectionPointer
108
+ ? executionContext.defaultRuntime.value.runtimeValue.connections[0]
109
+ ?.storeConnections?.[0]?.connection
110
+ : undefined
111
+ : undefined;
112
+ const connectionPath = connection
113
+ ? connection.packageableConnection.value.path
114
+ : dataSpaceMedata
115
+ ? dataSpaceMedata.connectionPath
101
116
  : undefined;
117
+ const connectionType =
118
+ connection &&
119
+ connection.packageableConnection.value.connectionValue instanceof
120
+ RelationalDatabaseConnection
121
+ ? connection.packageableConnection.value.connectionValue.type
122
+ : dataSpaceMedata
123
+ ? dataSpaceMedata.connectionType
124
+ : undefined;
125
+ const storePath =
126
+ connection?.store?.value.path ?? dataSpaceMedata?.storePath;
102
127
 
103
128
  const openInTaxonomy = (): void => {
104
129
  if (
@@ -209,9 +234,9 @@ export const QueryEditorDataspaceInfoModal = observer(
209
234
  {executionContext.defaultRuntime.value.name}
210
235
  </div>
211
236
  </div>
212
- {connection && (
237
+ {(connection || dataSpaceMedata) && (
213
238
  <>
214
- {connection.store && (
239
+ {storePath && (
215
240
  <div className="dataspace-info-modal__field">
216
241
  <div className="dataspace-info-modal__field__label">
217
242
  Store
@@ -219,14 +244,10 @@ export const QueryEditorDataspaceInfoModal = observer(
219
244
  <div
220
245
  className="dataspace-info-modal__field__value dataspace-info-modal__field__value--linkable"
221
246
  onClick={() => {
222
- if (connection.store) {
223
- flowResult(
224
- visitElement(connection.store.value.path),
225
- );
226
- }
247
+ flowResult(visitElement(storePath));
227
248
  }}
228
249
  >
229
- {connection.store.value.name}
250
+ {connection?.store?.value.name ?? storePath}
230
251
  </div>
231
252
  </div>
232
253
  )}
@@ -236,18 +257,23 @@ export const QueryEditorDataspaceInfoModal = observer(
236
257
  </div>
237
258
  <div
238
259
  className="dataspace-info-modal__field__value dataspace-info-modal__field__value--linkable"
239
- onClick={() =>
240
- flowResult(
241
- visitElement(
242
- connection.packageableConnection.value.path,
243
- ),
244
- )
245
- }
260
+ onClick={() => {
261
+ if (connectionPath) {
262
+ flowResult(visitElement(connectionPath));
263
+ }
264
+ }}
246
265
  >
247
- {connection.packageableConnection.value
266
+ {connection &&
267
+ connection.packageableConnection.value
248
268
  .connectionValue instanceof RelationalDatabaseConnection
249
269
  ? `${connection.packageableConnection.value.name}:${connection.packageableConnection.value.connectionValue.type}`
250
- : connection.packageableConnection.value.name}
270
+ : connection
271
+ ? connection.packageableConnection.value.name
272
+ : connectionPath && connectionType
273
+ ? `${connectionPath}:${connectionType}`
274
+ : connectionPath
275
+ ? `${connectionPath}`
276
+ : `${connectionType}`}
251
277
  </div>
252
278
  </div>
253
279
  </>