@finos/legend-application-studio 28.20.0 → 28.21.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (61) hide show
  1. package/lib/__lib__/LegendStudioUserDataHelper.d.ts +4 -1
  2. package/lib/__lib__/LegendStudioUserDataHelper.d.ts.map +1 -1
  3. package/lib/__lib__/LegendStudioUserDataHelper.js +18 -0
  4. package/lib/__lib__/LegendStudioUserDataHelper.js.map +1 -1
  5. package/lib/components/editor/editor-group/EditorGroup.d.ts.map +1 -1
  6. package/lib/components/editor/editor-group/EditorGroup.js +5 -0
  7. package/lib/components/editor/editor-group/EditorGroup.js.map +1 -1
  8. package/lib/components/editor/editor-group/dataProduct/DataProductEditor.d.ts.map +1 -1
  9. package/lib/components/editor/editor-group/dataProduct/DataProductEditor.js +13 -44
  10. package/lib/components/editor/editor-group/dataProduct/DataProductEditor.js.map +1 -1
  11. package/lib/components/editor/editor-group/database-editor/DatabaseAnnotationDisplay.d.ts +26 -0
  12. package/lib/components/editor/editor-group/database-editor/DatabaseAnnotationDisplay.d.ts.map +1 -0
  13. package/lib/components/editor/editor-group/database-editor/DatabaseAnnotationDisplay.js +101 -0
  14. package/lib/components/editor/editor-group/database-editor/DatabaseAnnotationDisplay.js.map +1 -0
  15. package/lib/components/editor/editor-group/database-editor/DatabaseDiagramCanvas.d.ts +23 -0
  16. package/lib/components/editor/editor-group/database-editor/DatabaseDiagramCanvas.d.ts.map +1 -0
  17. package/lib/components/editor/editor-group/database-editor/DatabaseDiagramCanvas.js +434 -0
  18. package/lib/components/editor/editor-group/database-editor/DatabaseDiagramCanvas.js.map +1 -0
  19. package/lib/components/editor/editor-group/database-editor/DatabaseDiagramHelper.d.ts +242 -0
  20. package/lib/components/editor/editor-group/database-editor/DatabaseDiagramHelper.d.ts.map +1 -0
  21. package/lib/components/editor/editor-group/database-editor/DatabaseDiagramHelper.js +371 -0
  22. package/lib/components/editor/editor-group/database-editor/DatabaseDiagramHelper.js.map +1 -0
  23. package/lib/components/editor/editor-group/database-editor/DatabaseEditor.d.ts +29 -0
  24. package/lib/components/editor/editor-group/database-editor/DatabaseEditor.d.ts.map +1 -0
  25. package/lib/components/editor/editor-group/database-editor/DatabaseEditor.js +78 -0
  26. package/lib/components/editor/editor-group/database-editor/DatabaseEditor.js.map +1 -0
  27. package/lib/components/editor/editor-group/database-editor/DatabaseSchemaTree.d.ts +30 -0
  28. package/lib/components/editor/editor-group/database-editor/DatabaseSchemaTree.d.ts.map +1 -0
  29. package/lib/components/editor/editor-group/database-editor/DatabaseSchemaTree.js +331 -0
  30. package/lib/components/editor/editor-group/database-editor/DatabaseSchemaTree.js.map +1 -0
  31. package/lib/components/editor/editor-group/database-editor/DatabaseTableNode.d.ts +104 -0
  32. package/lib/components/editor/editor-group/database-editor/DatabaseTableNode.d.ts.map +1 -0
  33. package/lib/components/editor/editor-group/database-editor/DatabaseTableNode.js +151 -0
  34. package/lib/components/editor/editor-group/database-editor/DatabaseTableNode.js.map +1 -0
  35. package/lib/components/editor/editor-group/ingest-editor/IngestDefinitionEditor.d.ts.map +1 -1
  36. package/lib/components/editor/editor-group/ingest-editor/IngestDefinitionEditor.js +3 -78
  37. package/lib/components/editor/editor-group/ingest-editor/IngestDefinitionEditor.js.map +1 -1
  38. package/lib/index.css +2 -2
  39. package/lib/index.css.map +1 -1
  40. package/lib/package.json +4 -1
  41. package/lib/stores/editor/EditorTabManagerState.d.ts.map +1 -1
  42. package/lib/stores/editor/EditorTabManagerState.js +5 -3
  43. package/lib/stores/editor/EditorTabManagerState.js.map +1 -1
  44. package/lib/stores/editor/editor-state/element-editor-state/DatabaseEditorState.d.ts +252 -0
  45. package/lib/stores/editor/editor-state/element-editor-state/DatabaseEditorState.d.ts.map +1 -0
  46. package/lib/stores/editor/editor-state/element-editor-state/DatabaseEditorState.js +755 -0
  47. package/lib/stores/editor/editor-state/element-editor-state/DatabaseEditorState.js.map +1 -0
  48. package/package.json +12 -9
  49. package/src/__lib__/LegendStudioUserDataHelper.ts +30 -0
  50. package/src/components/editor/editor-group/EditorGroup.tsx +4 -0
  51. package/src/components/editor/editor-group/dataProduct/DataProductEditor.tsx +0 -52
  52. package/src/components/editor/editor-group/database-editor/DatabaseAnnotationDisplay.tsx +200 -0
  53. package/src/components/editor/editor-group/database-editor/DatabaseDiagramCanvas.tsx +701 -0
  54. package/src/components/editor/editor-group/database-editor/DatabaseDiagramHelper.ts +555 -0
  55. package/src/components/editor/editor-group/database-editor/DatabaseEditor.tsx +246 -0
  56. package/src/components/editor/editor-group/database-editor/DatabaseSchemaTree.tsx +1053 -0
  57. package/src/components/editor/editor-group/database-editor/DatabaseTableNode.tsx +465 -0
  58. package/src/components/editor/editor-group/ingest-editor/IngestDefinitionEditor.tsx +2 -242
  59. package/src/stores/editor/EditorTabManagerState.ts +4 -5
  60. package/src/stores/editor/editor-state/element-editor-state/DatabaseEditorState.ts +938 -0
  61. package/tsconfig.json +7 -0
@@ -0,0 +1 @@
1
+ {"version":3,"file":"DatabaseEditorState.js","sourceRoot":"","sources":["../../../../../src/stores/editor/editor-state/element-editor-state/DatabaseEditorState.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAEH,OAAO,EACL,MAAM,EACN,QAAQ,EACR,IAAI,EACJ,UAAU,EACV,cAAc,EACd,UAAU,GACX,MAAM,MAAM,CAAC;AACd,OAAO,EAAE,kBAAkB,EAAE,MAAM,yBAAyB,CAAC;AAC7D,OAAO,EAEL,QAAQ,EACR,iBAAiB,EACjB,aAAa,EACb,IAAI,GACL,MAAM,sBAAsB,CAAC;AAC9B,OAAO,EAEL,QAAQ,EAER,mBAAmB,GAMpB,MAAM,qBAAqB,CAAC;AAE7B,OAAO,EAAE,0BAA0B,EAAE,MAAM,mDAAmD,CAAC;AAE/F;;;;GAIG;AACH,MAAM,CAAN,IAAY,mBAGX;AAHD,WAAY,mBAAmB;IAC7B,oCAAa,CAAA;IACb,0CAAmB,CAAA;AACrB,CAAC,EAH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C,iBAAiB,GAAG,IAAI,GAAG,CAAC,IAAI,CAAC,iBAAiB,CAAC,CAAC;QACzD,IAAI,CAAC,mBAAmB,GAAG,IAAI,GAAG,CAAC,IAAI,CAAC,mBAAmB,CAAC,CAAC;QAC7D,IAAI,CAAC,oBAAoB,GAAG,IAAI,CAAC,oBAAoB,CAAC;QACtD,IAAI,CAAC,KAAK,GAAG,IAAI,CAAC,KAAK,CAAC;QACxB,sEAAsE;QACtE,yEAAyE;QACzE,iEAAiE;QACjE,yEAAyE;QACzE,iCAAiC;QACjC,OAAO,IAAI,CAAC;IACd,CAAC;CACF"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@finos/legend-application-studio",
3
- "version": "28.20.0",
3
+ "version": "28.21.0",
4
4
  "description": "Legend Studio application core",
5
5
  "keywords": [
6
6
  "legend",
@@ -46,17 +46,18 @@
46
46
  "test:watch": "jest --watch"
47
47
  },
48
48
  "dependencies": {
49
+ "@dagrejs/dagre": "1.1.4",
49
50
  "@finos/legend-application": "16.0.105",
50
51
  "@finos/legend-art": "7.1.147",
51
- "@finos/legend-code-editor": "2.0.168",
52
- "@finos/legend-data-cube": "0.3.85",
53
- "@finos/legend-extension-dsl-data-product": "0.0.74",
54
- "@finos/legend-extension-dsl-diagram": "8.1.232",
55
- "@finos/legend-graph": "32.6.0",
56
- "@finos/legend-lego": "2.0.187",
57
- "@finos/legend-query-builder": "4.18.4",
52
+ "@finos/legend-code-editor": "2.0.169",
53
+ "@finos/legend-data-cube": "0.3.86",
54
+ "@finos/legend-extension-dsl-data-product": "0.0.75",
55
+ "@finos/legend-extension-dsl-diagram": "8.1.233",
56
+ "@finos/legend-graph": "32.6.1",
57
+ "@finos/legend-lego": "2.0.188",
58
+ "@finos/legend-query-builder": "4.18.5",
58
59
  "@finos/legend-server-depot": "6.1.11",
59
- "@finos/legend-server-lakehouse": "0.3.49",
60
+ "@finos/legend-server-lakehouse": "0.3.50",
60
61
  "@finos/legend-server-sdlc": "5.4.2",
61
62
  "@finos/legend-server-showcase": "0.2.65",
62
63
  "@finos/legend-shared": "11.0.24",
@@ -65,7 +66,9 @@
65
66
  "@testing-library/react": "16.2.0",
66
67
  "@types/react": "19.0.10",
67
68
  "@types/react-dom": "19.0.4",
69
+ "@xyflow/react": "12.4.4",
68
70
  "fast-xml-parser": "5.0.8",
71
+ "html-to-image": "1.11.13",
69
72
  "mobx": "6.13.6",
70
73
  "mobx-react-lite": "4.1.0",
71
74
  "mobx-utils": "6.1.0",
@@ -18,6 +18,17 @@ import { returnUndefOnError } from '@finos/legend-shared';
18
18
  */
19
19
  export enum LEGEND_STUDIO_USER_DATA_KEY {
20
20
  GLOBAL_TEST_RUNNER_SHOW_DEPENDENCIES = 'studio-editor.global-test-runner-showDependencyPanel',
21
+ // Per-user theme preference for the database editor. Scoped to this one
22
+ // editor since the wider Studio app is dark-mode-only today — the rest of
23
+ // the app does not honor this value.
24
+ // TODO: when Studio adopts app-wide theming via `LayoutService` (the
25
+ // mechanism Query already uses with setting key
26
+ // `application.layout.colorTheme`), retire this key and have the database
27
+ // editor inherit `applicationStore.layoutService.currentColorTheme`
28
+ // instead. Migration is mechanical: delete this key + the helper getters,
29
+ // drop the toggle button in the tab header, and retarget the SCSS
30
+ // `.database-editor--light` block at the framework's color-theme tokens.
31
+ DATABASE_EDITOR_THEME = 'studio-editor.database-editor.theme',
21
32
  }
22
33
 
23
34
  export class LegendStudioUserDataHelper {
@@ -40,4 +51,23 @@ export class LegendStudioUserDataHelper {
40
51
  val,
41
52
  );
42
53
  }
54
+
55
+ static databaseEditor_getTheme(
56
+ service: UserDataService,
57
+ ): 'dark' | 'light' | undefined {
58
+ const val = returnUndefOnError(() =>
59
+ service.getStringValue(LEGEND_STUDIO_USER_DATA_KEY.DATABASE_EDITOR_THEME),
60
+ );
61
+ return val === 'light' || val === 'dark' ? val : undefined;
62
+ }
63
+
64
+ static databaseEditor_setTheme(
65
+ service: UserDataService,
66
+ val: 'dark' | 'light',
67
+ ): void {
68
+ service.persistValue(
69
+ LEGEND_STUDIO_USER_DATA_KEY.DATABASE_EDITOR_THEME,
70
+ val,
71
+ );
72
+ }
43
73
  }
@@ -63,6 +63,8 @@ import { EntityChangeConflictEditorState } from '../../../stores/editor/editor-s
63
63
  import { EntityChangeConflictEditor } from './diff-editor/EntityChangeConflictEditor.js';
64
64
  import { UnsupportedElementEditorState } from '../../../stores/editor/editor-state/UnsupportedElementEditorState.js';
65
65
  import { UnsupportedElementEditor } from './UnsupportedElementEditor.js';
66
+ import { DatabaseEditorState } from '../../../stores/editor/editor-state/element-editor-state/DatabaseEditorState.js';
67
+ import { DatabaseEditor } from './database-editor/DatabaseEditor.js';
66
68
  import { getPrettyLabelForRevision } from '../../../stores/editor/editor-state/entity-diff-editor-state/EntityDiffEditorState.js';
67
69
  import { GenerationSpecificationEditorState } from '../../../stores/editor/editor-state/GenerationSpecificationEditorState.js';
68
70
  import { GenerationSpecificationEditor } from './GenerationSpecificationEditor.js';
@@ -330,6 +332,8 @@ export const EditorGroup = observer(() => {
330
332
  currentTabState instanceof MemSQLFunctionActivatorEdtiorState
331
333
  ) {
332
334
  return <MemSQLFunctionActivatorEditor key={currentTabState.uuid} />;
335
+ } else if (currentTabState instanceof DatabaseEditorState) {
336
+ return <DatabaseEditor key={currentTabState.uuid} />;
333
337
  } else if (currentTabState instanceof UnsupportedElementEditorState) {
334
338
  return <UnsupportedElementEditor key={currentTabState.uuid} />;
335
339
  } else if (
@@ -22,7 +22,6 @@ import {
22
22
  DATA_PRODUCT_TAB,
23
23
  DATA_PRODUCT_TYPE,
24
24
  DataProductEditorState,
25
- generateUrlToDeployOnOpen,
26
25
  LakehouseAccessPointState,
27
26
  ModelAccessPointGroupState,
28
27
  } from '../../../../stores/editor/editor-state/element-editor-state/dataProduct/DataProductEditorState.js';
@@ -68,7 +67,6 @@ import {
68
67
  ResizablePanel,
69
68
  ResizablePanelGroup,
70
69
  ResizablePanelSplitter,
71
- RocketIcon,
72
70
  Switch,
73
71
  TimesIcon,
74
72
  Tooltip,
@@ -108,7 +106,6 @@ import {
108
106
  type QueryBuilderState,
109
107
  } from '@finos/legend-query-builder';
110
108
  import { action, autorun, flowResult } from 'mobx';
111
- import { useAuth } from 'react-oidc-context';
112
109
  import { CODE_EDITOR_LANGUAGE } from '@finos/legend-code-editor';
113
110
  import { CodeEditor } from '@finos/legend-lego/code-editor';
114
111
  import {
@@ -3352,35 +3349,10 @@ export const DataProductEditor = observer(() => {
3352
3349
  editorStore.tabManagerState.getCurrentEditorState(DataProductEditorState);
3353
3350
  const product = dataProductEditorState.product;
3354
3351
  const isReadOnly = dataProductEditorState.isReadOnly;
3355
- const auth = useAuth();
3356
3352
  const [showPreview, setShowPreview] = useState(false);
3357
3353
  const [dataProductViewerState, setDataProductViewerState] =
3358
3354
  useState<DataProductViewerState>();
3359
3355
 
3360
- const deployDataProduct = (): void => {
3361
- // Trigger OAuth flow if not authenticated
3362
- if (!auth.isAuthenticated) {
3363
- // remove this redirect if we move to do oauth at the beginning of opening studio
3364
- auth
3365
- .signinRedirect({
3366
- state: generateUrlToDeployOnOpen(dataProductEditorState),
3367
- })
3368
- .catch(editorStore.applicationStore.alertUnhandledError);
3369
- return;
3370
- }
3371
- // Use the token for deployment
3372
- const token = auth.user?.access_token;
3373
- if (token) {
3374
- flowResult(dataProductEditorState.deploy(token)).catch(
3375
- editorStore.applicationStore.alertUnhandledError,
3376
- );
3377
- } else {
3378
- editorStore.applicationStore.notificationService.notifyError(
3379
- 'Authentication failed. No token available.',
3380
- );
3381
- }
3382
- };
3383
-
3384
3356
  const selectedActivity = dataProductEditorState.selectedTab;
3385
3357
  const renderActivivtyBarTab = (): React.ReactNode => {
3386
3358
  switch (selectedActivity) {
@@ -3427,18 +3399,6 @@ export const DataProductEditor = observer(() => {
3427
3399
  );
3428
3400
  }, [dataProductEditorState]);
3429
3401
 
3430
- useEffect(() => {
3431
- if (dataProductEditorState.deployOnOpen) {
3432
- flowResult(dataProductEditorState.deploy(auth.user?.access_token)).catch(
3433
- editorStore.applicationStore.alertUnhandledError,
3434
- );
3435
- }
3436
- }, [
3437
- auth,
3438
- editorStore.applicationStore.alertUnhandledError,
3439
- dataProductEditorState,
3440
- ]);
3441
-
3442
3402
  useEffect(
3443
3403
  () =>
3444
3404
  autorun(
@@ -3520,18 +3480,6 @@ export const DataProductEditor = observer(() => {
3520
3480
  )}
3521
3481
  </button>
3522
3482
  </div>
3523
- <div className="btn__dropdown-combo btn__dropdown-combo--primary">
3524
- <button
3525
- className="btn__dropdown-combo__label"
3526
- onClick={deployDataProduct}
3527
- title={dataProductEditorState.deployValidationMessage}
3528
- tabIndex={-1}
3529
- disabled={!dataProductEditorState.deployValidationMessage}
3530
- >
3531
- <RocketIcon className="btn__dropdown-combo__label__icon" />
3532
- <div className="btn__dropdown-combo__label__title">Deploy</div>
3533
- </button>
3534
- </div>
3535
3483
  </PanelHeaderActions>
3536
3484
  </div>
3537
3485
 
@@ -0,0 +1,200 @@
1
+ /**
2
+ * Copyright (c) 2020-present, Goldman Sachs
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+
17
+ import { BasePopover, clsx, HashtagIcon, TagIcon } from '@finos/legend-art';
18
+ import type { StereotypeReference, TaggedValue } from '@finos/legend-graph';
19
+ import { useState } from 'react';
20
+
21
+ /**
22
+ * Read-only display for `stereotypes` + `taggedValues` on any
23
+ * `AnnotatedElement` (Database, Schema, Table, View, Column). Mirrors the
24
+ * Pure DSL form `<<profile.stereo>> { tag = "value" }` but rendered as small
25
+ * inline pills so it can sit next to a relation name in a header row, in a
26
+ * tree row, or in a dedicated section.
27
+ *
28
+ * Three layout modes:
29
+ * - `inline` (default): pills flow next to the surrounding row content.
30
+ * - `block`: pills wrap into their own block (used in side-panel sections
31
+ * where the parent has its own column structure).
32
+ * - `compact`: only renders a single combined badge with the count — used
33
+ * when horizontal space is tight (e.g. the canvas table-node header).
34
+ * Hover shows the full content via `title`.
35
+ *
36
+ * The component is dependency-free (no MobX) so it can be used from any of
37
+ * the editor's sub-components without observability concerns — the inputs
38
+ * are static metamodel arrays.
39
+ */
40
+
41
+ const formatStereotype = (stereotype: StereotypeReference): string => {
42
+ // Pure surface syntax: `profile.stereotypeName`. We mimic that for the
43
+ // tooltip + compact-mode label so users see the same identifier the
44
+ // grammar uses.
45
+ const profilePath =
46
+ stereotype.ownerReference.valueForSerialization ??
47
+ stereotype.value._OWNER.path;
48
+ return `${profilePath}.${stereotype.value.value}`;
49
+ };
50
+
51
+ const formatTaggedValue = (taggedValue: TaggedValue): string => {
52
+ // Same rationale as above — match the grammar form `profile.tag = "value"`.
53
+ const profilePath =
54
+ taggedValue.tag.ownerReference.valueForSerialization ??
55
+ taggedValue.tag.value._OWNER.path;
56
+ return `${profilePath}.${taggedValue.tag.value.value} = "${taggedValue.value}"`;
57
+ };
58
+
59
+ /**
60
+ * Click-to-open popover badge used in compact mode. Kept separate from the
61
+ * parent component so the `useState` hook for the popover anchor is
62
+ * unconditionally called (the parent has an early-return for the empty case
63
+ * which would otherwise put this hook below a conditional).
64
+ */
65
+ function CompactAnnotationBadge(props: {
66
+ stereotypes: StereotypeReference[];
67
+ taggedValues: TaggedValue[];
68
+ className?: string | undefined;
69
+ }): React.ReactElement {
70
+ const { stereotypes, taggedValues, className } = props;
71
+ const [anchor, setAnchor] = useState<HTMLElement | null>(null);
72
+ const total = stereotypes.length + taggedValues.length;
73
+ return (
74
+ <>
75
+ <button
76
+ type="button"
77
+ className={clsx(
78
+ 'database-annotation',
79
+ 'database-annotation--compact',
80
+ className,
81
+ )}
82
+ onClick={(event) => {
83
+ // Stop propagation so clicking the badge inside a clickable canvas
84
+ // node header (or tree row) doesn't also trigger the parent's
85
+ // selection handler.
86
+ event.stopPropagation();
87
+ setAnchor(event.currentTarget);
88
+ }}
89
+ title={`${total} annotation${total === 1 ? '' : 's'} \u2014 click to view`}
90
+ >
91
+ <TagIcon />
92
+ <span className="database-annotation__count">{total}</span>
93
+ </button>
94
+ <BasePopover
95
+ open={Boolean(anchor)}
96
+ anchorEl={anchor}
97
+ onClose={() => setAnchor(null)}
98
+ anchorOrigin={{ vertical: 'bottom', horizontal: 'left' }}
99
+ transformOrigin={{ vertical: 'top', horizontal: 'left' }}
100
+ >
101
+ <div
102
+ className="database-annotation__popover"
103
+ // Stop click events on the popover content from reaching the
104
+ // ReactFlow canvas underneath.
105
+ onClick={(event) => event.stopPropagation()}
106
+ >
107
+ {/* eslint-disable-next-line @typescript-eslint/no-use-before-define */}
108
+ <DatabaseAnnotationDisplay
109
+ stereotypes={stereotypes}
110
+ taggedValues={taggedValues}
111
+ layout="block"
112
+ />
113
+ </div>
114
+ </BasePopover>
115
+ </>
116
+ );
117
+ }
118
+
119
+ export interface DatabaseAnnotationDisplayProps {
120
+ stereotypes: StereotypeReference[];
121
+ taggedValues: TaggedValue[];
122
+ /** Layout density. Defaults to `inline`. */
123
+ layout?: 'inline' | 'block' | 'compact';
124
+ /** Optional className appended to the root element for layout overrides. */
125
+ className?: string | undefined;
126
+ }
127
+
128
+ export const DatabaseAnnotationDisplay: React.FC<
129
+ DatabaseAnnotationDisplayProps
130
+ > = ({ stereotypes, taggedValues, layout = 'inline', className }) => {
131
+ if (stereotypes.length === 0 && taggedValues.length === 0) {
132
+ return null;
133
+ }
134
+
135
+ // Compact: collapse everything into a single badge with the total count.
136
+ // Useful inside dense headers (canvas table-node) where a row of pills
137
+ // would crowd out the relation name. Click opens a popover with the full
138
+ // list rendered in `block` layout. Extracted into its own component so
139
+ // the `useState` hook is unconditionally called (we can't put a hook
140
+ // after the early-return at the top of the parent).
141
+ if (layout === 'compact') {
142
+ return (
143
+ <CompactAnnotationBadge
144
+ stereotypes={stereotypes}
145
+ taggedValues={taggedValues}
146
+ className={className}
147
+ />
148
+ );
149
+ }
150
+
151
+ return (
152
+ <div
153
+ className={clsx(
154
+ 'database-annotation',
155
+ `database-annotation--${layout}`,
156
+ className,
157
+ )}
158
+ >
159
+ {stereotypes.map((stereotype) => {
160
+ const label = formatStereotype(stereotype);
161
+ return (
162
+ // Profiles can re-use stereotype names across owners, so prefix the
163
+ // key with the owner path to keep keys unique.
164
+ <span
165
+ key={`stereo:${label}`}
166
+ className="database-annotation__stereotype"
167
+ title={`«${label}»`}
168
+ >
169
+ <HashtagIcon />
170
+ <span className="database-annotation__stereotype__label">
171
+ {stereotype.value.value}
172
+ </span>
173
+ </span>
174
+ );
175
+ })}
176
+ {taggedValues.map((taggedValue) => {
177
+ const tagName = taggedValue.tag.value.value;
178
+ return (
179
+ // Tagged values aren't unique by tag (the same tag can appear
180
+ // twice with different values), so we key off `_UUID` rather than
181
+ // a composite of tag path + name.
182
+ <span
183
+ key={taggedValue._UUID}
184
+ className="database-annotation__tagged-value"
185
+ title={formatTaggedValue(taggedValue)}
186
+ >
187
+ <TagIcon />
188
+ <span className="database-annotation__tagged-value__name">
189
+ {tagName}
190
+ </span>
191
+ <span className="database-annotation__tagged-value__sep">=</span>
192
+ <span className="database-annotation__tagged-value__value">
193
+ {taggedValue.value}
194
+ </span>
195
+ </span>
196
+ );
197
+ })}
198
+ </div>
199
+ );
200
+ };