@likec4/diagram 1.31.0 → 1.32.1
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.
- package/bundle/{chunk-BBzMXzCg.js → chunk-DlHyKoeo.js} +1700 -1206
- package/bundle/custom.js +51 -47
- package/bundle/index.js +5495 -5428
- package/dist/LikeC4CustomColors.d.ts +2 -7
- package/dist/LikeC4CustomColors.js +17 -6
- package/dist/LikeC4Diagram.d.ts +3 -2
- package/dist/LikeC4Diagram.js +10 -14
- package/dist/LikeC4Diagram.props.d.ts +41 -24
- package/dist/LikeC4ModelProvider.d.ts +5 -4
- package/dist/StaticLikeC4Diagram.d.ts +3 -2
- package/dist/StaticLikeC4Diagram.js +2 -2
- package/dist/base/BaseXYFlow.js +5 -5
- package/dist/base/const.d.ts +1 -1
- package/dist/base/const.js +1 -1
- package/dist/base/index.d.ts +2 -1
- package/dist/base/primitives/compound/CompoundActionButton.js +2 -1
- package/dist/base/primitives/compound/CompoundDetailsButton.js +2 -1
- package/dist/base/primitives/compound/CompoundTitle.d.ts +1 -1
- package/dist/base/primitives/compound/CompoundTitle.js +2 -1
- package/dist/base/primitives/edge/EdgeContainer.d.ts +1 -1
- package/dist/base/primitives/edge/EdgeLabel.css.js +1 -0
- package/dist/base/primitives/edge/EdgeLabel.d.ts +3 -3
- package/dist/base/primitives/edge/EdgeLabel.js +6 -4
- package/dist/base/primitives/edge/EdgeLabelContainer.d.ts +1 -1
- package/dist/base/primitives/edge/EdgeMarkers.d.ts +1 -1
- package/dist/base/primitives/edge/EdgePath.d.ts +1 -1
- package/dist/base/primitives/element/ElementActionButtons.js +10 -9
- package/dist/base/primitives/element/ElementDetailsButton.js +2 -1
- package/dist/base/primitives/element/ElementShape.d.ts +1 -1
- package/dist/base/primitives/element/ElementTags.d.ts +14 -0
- package/dist/base/primitives/element/ElementTags.js +176 -0
- package/dist/base/primitives/element/ElementTitle.d.ts +5 -4
- package/dist/base/primitives/element/ElementTitle.js +6 -6
- package/dist/base/primitives/index.d.ts +1 -0
- package/dist/base/types.Base.d.ts +54 -0
- package/dist/base/types.Base.js +48 -0
- package/dist/base/types.d.ts +2 -52
- package/dist/bundle/LikeC4View.d.ts +2 -1
- package/dist/bundle/LikeC4View.js +22 -19
- package/dist/bundle/LikeC4View.props.d.ts +15 -4
- package/dist/bundle/ReactLikeC4.d.ts +4 -7
- package/dist/bundle/ReactLikeC4.js +10 -8
- package/dist/bundle/index.js +1 -1
- package/dist/components/ErrorFallback.d.ts +2 -0
- package/dist/components/ErrorFallback.js +29 -0
- package/dist/context/DiagramEventHandlers.d.ts +6 -5
- package/dist/context/DiagramFeatures.d.ts +2 -2
- package/dist/context/DiagramFeatures.js +3 -31
- package/dist/context/EnsureMantine.js +1 -1
- package/dist/context/IconRenderer.js +1 -4
- package/dist/context/RootContainer.js +5 -1
- package/dist/context/TagStylesContext.d.ts +7 -0
- package/dist/context/TagStylesContext.js +85 -0
- package/dist/custom/components.d.ts +1 -1
- package/dist/custom/customNodes.d.ts +32 -17
- package/dist/custom/hooks.d.ts +1 -1
- package/dist/hooks/index.d.ts +1 -1
- package/dist/hooks/useDiagram.d.ts +73 -38
- package/dist/hooks/useDiagram.js +7 -3
- package/dist/hooks/useMantinePortalProps.d.ts +2 -2
- package/dist/hooks/useSearchActor.d.ts +2 -0
- package/dist/hooks/useSearchActor.js +10 -0
- package/dist/hooks/useUpdateEffect.js +3 -0
- package/dist/hooks/useXYFlow.d.ts +39 -37
- package/dist/hooks/useXYFlow.js +5 -1
- package/dist/index.js +1 -1
- package/dist/likec4diagram/DiagramUI.js +7 -2
- package/dist/likec4diagram/DiagramXYFlow.d.ts +4 -3
- package/dist/likec4diagram/DiagramXYFlow.js +107 -110
- package/dist/likec4diagram/custom/edges/RelationshipEdge.d.ts +7 -6
- package/dist/likec4diagram/custom/edges/RelationshipEdge.js +8 -0
- package/dist/likec4diagram/custom/edges/RelationshipsDropdownMenu.js +7 -5
- package/dist/likec4diagram/custom/index.d.ts +7 -6
- package/dist/likec4diagram/custom/nodes/nodes.js +39 -26
- package/dist/likec4diagram/custom/nodes/toolbar/_shared.d.ts +7 -7
- package/dist/likec4diagram/types.d.ts +5 -5
- package/dist/likec4diagram/ui/controls/Controls.js +12 -4
- package/dist/likec4diagram/ui/notation/NotationPanel.js +1 -1
- package/dist/likec4diagram/useViewToNodesEdges.d.ts +5 -3
- package/dist/likec4diagram/useViewToNodesEdges.js +20 -30
- package/dist/likec4model/LikeC4ModelContext.d.ts +2 -2
- package/dist/likec4model/index.d.ts +1 -1
- package/dist/likec4model/useLikeC4ElementsTree.js +1 -1
- package/dist/likec4model/useLikeC4Model.d.ts +23 -10
- package/dist/likec4model/useLikeC4Model.js +22 -7
- package/dist/overlays/Overlays.js +4 -27
- package/dist/overlays/element-details/ElementDetailsCard.d.ts +1 -1
- package/dist/overlays/element-details/ElementDetailsCard.js +19 -12
- package/dist/overlays/element-details/TabPanelDeployments.d.ts +1 -1
- package/dist/overlays/element-details/TabPanelDeployments.js +1 -1
- package/dist/overlays/element-details/TabPanelRelationships.d.ts +1 -1
- package/dist/overlays/element-details/TabPanelStructure.d.ts +1 -1
- package/dist/overlays/element-details/actor.d.ts +288 -286
- package/dist/overlays/overlay/Overlay.css.d.ts +57 -2
- package/dist/overlays/overlay/Overlay.css.js +76 -39
- package/dist/overlays/overlay/Overlay.d.ts +12 -0
- package/dist/overlays/overlay/Overlay.js +58 -27
- package/dist/overlays/overlaysActor.d.ts +1 -1
- package/dist/overlays/relationship-details/RelationshipDetails.d.ts +3 -2
- package/dist/overlays/relationship-details/RelationshipDetails.js +3 -3
- package/dist/overlays/relationship-details/_types.d.ts +2 -2
- package/dist/overlays/relationship-details/actor.js +7 -7
- package/dist/overlays/relationship-details/custom/edgeTypes.d.ts +3 -2
- package/dist/overlays/relationship-details/custom/nodeTypes.js +4 -0
- package/dist/overlays/relationship-details/hooks.d.ts +10 -9
- package/dist/overlays/relationship-details/layout-to-xyflow.js +1 -0
- package/dist/overlays/relationship-details/layout.js +3 -1
- package/dist/overlays/relationships-browser/RelationshipsBrowser.d.ts +3 -2
- package/dist/overlays/relationships-browser/SelectElement.js +1 -1
- package/dist/overlays/relationships-browser/_types.d.ts +2 -2
- package/dist/overlays/relationships-browser/actor.d.ts +1 -1
- package/dist/overlays/relationships-browser/actor.js +7 -7
- package/dist/overlays/relationships-browser/custom/edgeTypes.d.ts +3 -2
- package/dist/overlays/relationships-browser/custom/nodeTypes.d.ts +8 -5
- package/dist/overlays/relationships-browser/custom/nodeTypes.js +4 -0
- package/dist/overlays/relationships-browser/layout.d.ts +2 -2
- package/dist/overlays/relationships-browser/layout.js +10 -6
- package/dist/overlays/relationships-browser/useViewToNodesEdges.js +4 -3
- package/dist/search/Search.d.ts +4 -0
- package/dist/search/Search.js +173 -0
- package/dist/{likec4diagram/ui/search → search/components}/ElementsColumn.css.js +0 -1
- package/dist/search/components/ElementsColumn.d.ts +2 -0
- package/dist/{likec4diagram/ui/search → search/components}/ElementsColumn.js +26 -25
- package/dist/search/components/PickView.d.ts +4 -0
- package/dist/search/components/PickView.js +135 -0
- package/dist/search/components/SearchByTags.d.ts +1 -0
- package/dist/search/components/SearchByTags.js +119 -0
- package/dist/search/components/SearchInput.d.ts +2 -0
- package/dist/{likec4diagram/ui/search → search/components}/SearchInput.js +61 -40
- package/dist/{likec4diagram/ui/search → search/components}/ViewsColum.d.ts +3 -2
- package/dist/{likec4diagram/ui/search → search/components}/ViewsColum.js +25 -17
- package/dist/{likec4diagram/ui/search → search/components}/_shared.css.js +26 -35
- package/dist/{likec4diagram/ui/search/LikeC4Search.css.d.ts → search/components/styles.css.d.ts} +0 -2
- package/dist/search/components/styles.css.js +60 -0
- package/dist/search/components/utils.d.ts +5 -0
- package/dist/search/components/utils.js +58 -0
- package/dist/search/hooks.d.ts +10 -0
- package/dist/search/hooks.js +35 -0
- package/dist/search/searchActor.d.ts +90 -0
- package/dist/search/searchActor.js +75 -0
- package/dist/state/DiagramActorProvider.d.ts +9 -7
- package/dist/state/DiagramActorProvider.js +24 -18
- package/dist/state/assign.d.ts +0 -1
- package/dist/state/assign.js +9 -19
- package/dist/state/diagram-machine.d.ts +645 -183
- package/dist/state/diagram-machine.js +127 -60
- package/dist/state/syncManualLayoutActor.d.ts +2 -2
- package/dist/state/types.d.ts +2 -0
- package/dist/state/utils.d.ts +2 -0
- package/dist/state/utils.js +3 -0
- package/dist/styles-min.css +1 -1
- package/dist/styles-xyflow.css +1 -1
- package/dist/styles.css +1 -1
- package/dist/styles.css2.js +1 -1
- package/package.json +20 -19
- package/panda.buildinfo.json +171 -148
- package/src/LikeC4CustomColors.tsx +21 -6
- package/src/LikeC4Diagram.props.ts +48 -32
- package/src/LikeC4Diagram.tsx +19 -20
- package/src/LikeC4ModelProvider.tsx +6 -5
- package/src/StaticLikeC4Diagram.tsx +8 -6
- package/src/base/const.ts +1 -1
- package/src/base/index.ts +2 -1
- package/src/base/primitives/compound/CompoundActionButton.tsx +2 -1
- package/src/base/primitives/compound/CompoundDetailsButton.tsx +2 -1
- package/src/base/primitives/compound/CompoundTitle.tsx +3 -2
- package/src/base/primitives/edge/EdgeContainer.tsx +2 -1
- package/src/base/primitives/edge/EdgeLabel.css.ts +1 -0
- package/src/base/primitives/edge/EdgeLabel.tsx +20 -15
- package/src/base/primitives/edge/EdgeLabelContainer.tsx +1 -1
- package/src/base/primitives/edge/EdgeMarkers.tsx +2 -1
- package/src/base/primitives/edge/EdgePath.tsx +1 -1
- package/src/base/primitives/element/ElementActionButtons.tsx +11 -10
- package/src/base/primitives/element/ElementDetailsButton.tsx +2 -1
- package/src/base/primitives/element/ElementShape.tsx +2 -1
- package/src/base/primitives/element/ElementTags.tsx +182 -0
- package/src/base/primitives/element/ElementTitle.tsx +21 -15
- package/src/base/primitives/index.ts +1 -0
- package/src/base/types.Base.ts +104 -0
- package/src/base/types.ts +2 -99
- package/src/bundle/LikeC4View.props.ts +17 -4
- package/src/bundle/LikeC4View.tsx +27 -36
- package/src/bundle/ReactLikeC4.tsx +16 -36
- package/src/components/ErrorFallback.tsx +30 -0
- package/src/context/DiagramEventHandlers.tsx +5 -4
- package/src/context/DiagramFeatures.tsx +3 -22
- package/src/context/EnsureMantine.tsx +1 -1
- package/src/context/IconRenderer.tsx +1 -4
- package/src/context/RootContainer.tsx +9 -3
- package/src/context/TagStylesContext.tsx +96 -0
- package/src/custom/components.ts +2 -0
- package/src/custom/customNodes.tsx +29 -14
- package/src/custom/hooks.ts +2 -0
- package/src/hooks/index.ts +1 -1
- package/src/hooks/useCurrentViewId.ts +1 -4
- package/src/hooks/useDiagram.ts +104 -12
- package/src/hooks/useMantinePortalProps.ts +10 -1
- package/src/hooks/useSearchActor.ts +11 -0
- package/src/hooks/useUpdateEffect.ts +7 -4
- package/src/hooks/useXYFlow.ts +5 -0
- package/src/likec4diagram/DiagramUI.tsx +5 -0
- package/src/likec4diagram/DiagramXYFlow.tsx +118 -121
- package/src/likec4diagram/custom/edges/RelationshipEdge.tsx +9 -0
- package/src/likec4diagram/custom/edges/RelationshipsDropdownMenu.tsx +10 -9
- package/src/likec4diagram/custom/nodes/nodes.tsx +45 -43
- package/src/likec4diagram/custom/nodes/toolbar/_shared.tsx +11 -3
- package/src/likec4diagram/types.ts +5 -3
- package/src/likec4diagram/ui/controls/Controls.tsx +11 -4
- package/src/likec4diagram/ui/notation/NotationPanel.tsx +2 -2
- package/src/likec4diagram/useViewToNodesEdges.ts +34 -36
- package/src/likec4model/LikeC4ModelContext.ts +2 -2
- package/src/likec4model/index.ts +2 -0
- package/src/likec4model/useLikeC4ElementsTree.ts +1 -1
- package/src/likec4model/useLikeC4Model.ts +32 -16
- package/src/overlays/Overlays.tsx +5 -32
- package/src/overlays/element-details/ElementDetailsCard.tsx +25 -18
- package/src/overlays/element-details/TabPanelDeployments.tsx +3 -2
- package/src/overlays/element-details/TabPanelRelationships.tsx +2 -1
- package/src/overlays/element-details/TabPanelStructure.tsx +1 -1
- package/src/overlays/element-details/actor.ts +2 -2
- package/src/overlays/overlay/Overlay.css.ts +75 -38
- package/src/overlays/overlay/Overlay.tsx +61 -29
- package/src/overlays/overlaysActor.ts +1 -1
- package/src/overlays/relationship-details/RelationshipDetails.tsx +4 -4
- package/src/overlays/relationship-details/_types.ts +2 -1
- package/src/overlays/relationship-details/custom/nodeTypes.tsx +4 -0
- package/src/overlays/relationship-details/layout-to-xyflow.ts +1 -0
- package/src/overlays/relationship-details/layout.ts +3 -1
- package/src/overlays/relationships-browser/SelectElement.tsx +1 -1
- package/src/overlays/relationships-browser/_types.ts +2 -1
- package/src/overlays/relationships-browser/custom/nodeTypes.tsx +4 -0
- package/src/overlays/relationships-browser/layout.ts +12 -7
- package/src/overlays/relationships-browser/useViewToNodesEdges.ts +4 -4
- package/src/search/Search.tsx +220 -0
- package/src/{likec4diagram/ui/search → search/components}/ElementsColumn.css.ts +0 -29
- package/src/{likec4diagram/ui/search → search/components}/ElementsColumn.tsx +28 -29
- package/src/search/components/PickView.tsx +134 -0
- package/src/search/components/SearchByTags.tsx +112 -0
- package/src/{likec4diagram/ui/search → search/components}/SearchInput.tsx +72 -42
- package/src/{likec4diagram/ui/search → search/components}/ViewsColum.tsx +29 -22
- package/src/{likec4diagram/ui/search → search/components}/_shared.css.ts +26 -37
- package/src/{likec4diagram/ui/search/LikeC4Search.css.ts → search/components/styles.css.ts} +9 -36
- package/src/search/components/utils.ts +64 -0
- package/src/search/hooks.ts +38 -0
- package/src/search/searchActor.ts +99 -0
- package/src/state/DiagramActorProvider.tsx +37 -25
- package/src/state/assign.ts +10 -10
- package/src/state/diagram-machine.ts +123 -58
- package/src/state/syncManualLayoutActor.ts +1 -1
- package/src/state/types.ts +2 -0
- package/src/state/utils.ts +4 -0
- package/dist/base/types.js +0 -54
- package/dist/likec4diagram/ui/search/ElementsColumn.d.ts +0 -1
- package/dist/likec4diagram/ui/search/LikeC4Search.css.js +0 -87
- package/dist/likec4diagram/ui/search/LikeC4Search.d.ts +0 -2
- package/dist/likec4diagram/ui/search/LikeC4Search.js +0 -267
- package/dist/likec4diagram/ui/search/SearchInput.d.ts +0 -1
- package/dist/likec4diagram/ui/search/state.d.ts +0 -19
- package/dist/likec4diagram/ui/search/state.js +0 -63
- package/dist/likec4diagram/ui/search/utils.d.ts +0 -3
- package/dist/likec4diagram/ui/search/utils.js +0 -20
- package/src/likec4diagram/ui/search/LikeC4Search.tsx +0 -301
- package/src/likec4diagram/ui/search/state.ts +0 -78
- package/src/likec4diagram/ui/search/utils.ts +0 -20
- /package/dist/{likec4diagram/ui/search → search/components}/ElementsColumn.css.d.ts +0 -0
- /package/dist/{likec4diagram/ui/search → search/components}/ViewsColumn.css.d.ts +0 -0
- /package/dist/{likec4diagram/ui/search → search/components}/ViewsColumn.css.js +0 -0
- /package/dist/{likec4diagram/ui/search → search/components}/_shared.css.d.ts +0 -0
- /package/src/{likec4diagram/ui/search → search/components}/ViewsColumn.css.ts +0 -0
|
@@ -1,5 +1,60 @@
|
|
|
1
|
-
import { SlotRecipeRuntimeFn
|
|
1
|
+
import { SlotRecipeRuntimeFn } from '@likec4/styles/types';
|
|
2
2
|
export declare const backdropBlur = "--_blur";
|
|
3
3
|
export declare const backdropOpacity = "--_opacity";
|
|
4
4
|
export declare const level = "--_level";
|
|
5
|
-
export declare const overlay: SlotRecipeRuntimeFn<"body" | "dialog",
|
|
5
|
+
export declare const overlay: SlotRecipeRuntimeFn<"body" | "dialog", {
|
|
6
|
+
fullscreen: {
|
|
7
|
+
false: {
|
|
8
|
+
dialog: {
|
|
9
|
+
sm: {
|
|
10
|
+
inset: "[var(--_inset) var(--_inset) var(--_offset) var(--_inset)]";
|
|
11
|
+
width: "calc(100vw - 2 * var(--_inset))";
|
|
12
|
+
height: "calc(100vh - var(--_offset) - var(--_inset))";
|
|
13
|
+
"--_border-radius": "6px";
|
|
14
|
+
padding: "6px";
|
|
15
|
+
"--_offset": "1rem";
|
|
16
|
+
};
|
|
17
|
+
md: {
|
|
18
|
+
"--_offset": "1rem";
|
|
19
|
+
};
|
|
20
|
+
lg: {
|
|
21
|
+
"--_offset": "2rem";
|
|
22
|
+
};
|
|
23
|
+
xl: {
|
|
24
|
+
"--_offset": "4rem";
|
|
25
|
+
};
|
|
26
|
+
};
|
|
27
|
+
body: {
|
|
28
|
+
sm: {
|
|
29
|
+
borderRadius: "calc(var(--_border-radius) - 2px)";
|
|
30
|
+
};
|
|
31
|
+
};
|
|
32
|
+
};
|
|
33
|
+
true: {
|
|
34
|
+
dialog: {
|
|
35
|
+
inset: number;
|
|
36
|
+
padding: number;
|
|
37
|
+
};
|
|
38
|
+
};
|
|
39
|
+
};
|
|
40
|
+
withBackdrop: {
|
|
41
|
+
false: {
|
|
42
|
+
dialog: {
|
|
43
|
+
_backdrop: {
|
|
44
|
+
display: "none";
|
|
45
|
+
};
|
|
46
|
+
};
|
|
47
|
+
};
|
|
48
|
+
true: {
|
|
49
|
+
dialog: {
|
|
50
|
+
_backdrop: {
|
|
51
|
+
backdropFilter: "blur(var(--_blur))";
|
|
52
|
+
backgroundColor: {
|
|
53
|
+
_dark: "[rgb(34 34 34 / var(--_opacity))]";
|
|
54
|
+
_light: "[rgb(15 15 15/ var(--_opacity))]";
|
|
55
|
+
};
|
|
56
|
+
};
|
|
57
|
+
};
|
|
58
|
+
};
|
|
59
|
+
};
|
|
60
|
+
}>;
|
|
@@ -10,8 +10,8 @@ const dialog = css.raw({
|
|
|
10
10
|
boxSizing: "border-box",
|
|
11
11
|
margin: 0,
|
|
12
12
|
position: "fixed",
|
|
13
|
-
width: "
|
|
14
|
-
height: "
|
|
13
|
+
width: "100vw",
|
|
14
|
+
height: "100vh",
|
|
15
15
|
maxWidth: "100vw",
|
|
16
16
|
maxHeight: "100vh",
|
|
17
17
|
background: `mantine.colors.defaultBorder/50`,
|
|
@@ -24,60 +24,97 @@ const dialog = css.raw({
|
|
|
24
24
|
[offset]: "0px",
|
|
25
25
|
[inset]: "calc((1 + var(--_level) * 0.75) * var(--_offset))",
|
|
26
26
|
[backdropOpacity]: "0%",
|
|
27
|
+
[borderRadius]: "0px",
|
|
27
28
|
_backdrop: {
|
|
28
|
-
cursor: "zoom-out"
|
|
29
|
-
backdropFilter: `blur(var(${backdropBlur}))`,
|
|
30
|
-
backgroundColor: {
|
|
31
|
-
_dark: `[rgb(34 34 34 / var(${backdropOpacity}))]`,
|
|
32
|
-
_light: `[rgb(15 15 15/ var(${backdropOpacity}))]`
|
|
33
|
-
}
|
|
34
|
-
},
|
|
35
|
-
smDown: {
|
|
36
|
-
[borderRadius]: "0px",
|
|
37
|
-
border: "none",
|
|
38
|
-
inset: 0,
|
|
39
|
-
padding: 0,
|
|
40
|
-
// [offset]: '0px',
|
|
41
|
-
// [inset]: '0px',
|
|
42
|
-
width: "100vw",
|
|
43
|
-
height: "100vh"
|
|
44
|
-
},
|
|
45
|
-
sm: {
|
|
46
|
-
inset: "[var(--_inset) var(--_inset) var(--_offset) var(--_inset)]",
|
|
47
|
-
width: "calc(100vw - 2 * var(--_inset))",
|
|
48
|
-
height: "calc(100vh - var(--_offset) - var(--_inset))",
|
|
49
|
-
[borderRadius]: "6px",
|
|
50
|
-
padding: "6px",
|
|
51
|
-
[offset]: "1rem"
|
|
52
|
-
},
|
|
53
|
-
md: {
|
|
54
|
-
[offset]: "1rem"
|
|
55
|
-
},
|
|
56
|
-
lg: {
|
|
57
|
-
[offset]: "2rem"
|
|
29
|
+
cursor: "zoom-out"
|
|
58
30
|
},
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
}
|
|
31
|
+
inset: 0,
|
|
32
|
+
padding: 0
|
|
62
33
|
});
|
|
63
34
|
const body = css.raw({
|
|
64
35
|
position: "relative",
|
|
65
36
|
containerName: "overlay-dialog",
|
|
66
37
|
containerType: "size",
|
|
67
38
|
border: `0 solid transparent`,
|
|
68
|
-
background: "mantine.colors.body",
|
|
69
39
|
overflow: "hidden",
|
|
70
40
|
width: "100%",
|
|
71
41
|
height: "100%",
|
|
72
|
-
|
|
73
|
-
borderRadius: `calc(var(${borderRadius}) - 2px)`
|
|
74
|
-
}
|
|
42
|
+
background: "mantine.colors.body"
|
|
75
43
|
});
|
|
76
44
|
const overlay = sva({
|
|
77
45
|
slots: ["dialog", "body"],
|
|
78
46
|
base: {
|
|
79
47
|
dialog,
|
|
80
48
|
body
|
|
49
|
+
},
|
|
50
|
+
variants: {
|
|
51
|
+
fullscreen: {
|
|
52
|
+
false: {
|
|
53
|
+
dialog: {
|
|
54
|
+
sm: {
|
|
55
|
+
inset: "[var(--_inset) var(--_inset) var(--_offset) var(--_inset)]",
|
|
56
|
+
width: "calc(100vw - 2 * var(--_inset))",
|
|
57
|
+
height: "calc(100vh - var(--_offset) - var(--_inset))",
|
|
58
|
+
[borderRadius]: "6px",
|
|
59
|
+
padding: "6px",
|
|
60
|
+
[offset]: "1rem"
|
|
61
|
+
},
|
|
62
|
+
md: {
|
|
63
|
+
[offset]: "1rem"
|
|
64
|
+
},
|
|
65
|
+
lg: {
|
|
66
|
+
[offset]: "2rem"
|
|
67
|
+
},
|
|
68
|
+
xl: {
|
|
69
|
+
[offset]: "4rem"
|
|
70
|
+
}
|
|
71
|
+
},
|
|
72
|
+
body: {
|
|
73
|
+
sm: {
|
|
74
|
+
borderRadius: `calc(var(${borderRadius}) - 2px)`
|
|
75
|
+
}
|
|
76
|
+
}
|
|
77
|
+
},
|
|
78
|
+
true: {
|
|
79
|
+
dialog: {
|
|
80
|
+
inset: 0,
|
|
81
|
+
padding: 0
|
|
82
|
+
}
|
|
83
|
+
}
|
|
84
|
+
},
|
|
85
|
+
// transparent: {
|
|
86
|
+
// false: {
|
|
87
|
+
// },
|
|
88
|
+
// true: {
|
|
89
|
+
// dialog: {
|
|
90
|
+
// background: 'transparent',
|
|
91
|
+
// },
|
|
92
|
+
// },
|
|
93
|
+
// },
|
|
94
|
+
withBackdrop: {
|
|
95
|
+
false: {
|
|
96
|
+
dialog: {
|
|
97
|
+
_backdrop: {
|
|
98
|
+
display: "none"
|
|
99
|
+
}
|
|
100
|
+
}
|
|
101
|
+
},
|
|
102
|
+
true: {
|
|
103
|
+
dialog: {
|
|
104
|
+
_backdrop: {
|
|
105
|
+
backdropFilter: `blur(var(${backdropBlur}))`,
|
|
106
|
+
backgroundColor: {
|
|
107
|
+
_dark: `[rgb(34 34 34 / var(${backdropOpacity}))]`,
|
|
108
|
+
_light: `[rgb(15 15 15/ var(${backdropOpacity}))]`
|
|
109
|
+
}
|
|
110
|
+
}
|
|
111
|
+
}
|
|
112
|
+
}
|
|
113
|
+
}
|
|
114
|
+
},
|
|
115
|
+
defaultVariants: {
|
|
116
|
+
fullscreen: false,
|
|
117
|
+
withBackdrop: true
|
|
81
118
|
}
|
|
82
119
|
});
|
|
83
120
|
|
|
@@ -1,21 +1,33 @@
|
|
|
1
1
|
import { PropsWithChildren, ForwardRefExoticComponent, ReactNode, RefAttributes } from 'react';
|
|
2
2
|
export type OverlayProps = PropsWithChildren<{
|
|
3
|
+
fullscreen?: boolean | undefined;
|
|
4
|
+
withBackdrop?: boolean | undefined;
|
|
3
5
|
overlayLevel?: number;
|
|
4
6
|
className?: string;
|
|
5
7
|
classes?: {
|
|
6
8
|
dialog?: string;
|
|
7
9
|
body?: string;
|
|
8
10
|
};
|
|
11
|
+
backdrop?: {
|
|
12
|
+
opacity?: number;
|
|
13
|
+
};
|
|
14
|
+
openDelay?: number;
|
|
9
15
|
onClose: () => void;
|
|
10
16
|
onClick?: never;
|
|
11
17
|
}>;
|
|
12
18
|
export declare const Overlay: ForwardRefExoticComponent<{
|
|
19
|
+
fullscreen?: boolean | undefined;
|
|
20
|
+
withBackdrop?: boolean | undefined;
|
|
13
21
|
overlayLevel?: number;
|
|
14
22
|
className?: string;
|
|
15
23
|
classes?: {
|
|
16
24
|
dialog?: string;
|
|
17
25
|
body?: string;
|
|
18
26
|
};
|
|
27
|
+
backdrop?: {
|
|
28
|
+
opacity?: number;
|
|
29
|
+
};
|
|
30
|
+
openDelay?: number;
|
|
19
31
|
onClose: () => void;
|
|
20
32
|
onClick?: never;
|
|
21
33
|
} & {
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { jsx, Fragment } from 'react/jsx-runtime';
|
|
2
2
|
import { cx } from '@likec4/styles/css';
|
|
3
3
|
import { RemoveScroll } from '@mantine/core';
|
|
4
|
-
import { useMergedRef } from '@mantine/hooks';
|
|
5
|
-
import {
|
|
4
|
+
import { useFocusTrap, useMergedRef } from '@mantine/hooks';
|
|
5
|
+
import { useDebouncedCallback, useTimeoutEffect } from '@react-hookz/web';
|
|
6
6
|
import { useReducedMotionConfig, m } from 'motion/react';
|
|
7
|
-
import { forwardRef, useState, useRef,
|
|
7
|
+
import { forwardRef, useState, useRef, useLayoutEffect } from 'react';
|
|
8
8
|
import { overlay, backdropOpacity, backdropBlur, level } from './Overlay.css.js';
|
|
9
9
|
import { stopPropagation } from '../../utils/xyflow.js';
|
|
10
10
|
|
|
@@ -14,13 +14,19 @@ const Overlay = forwardRef(({
|
|
|
14
14
|
classes,
|
|
15
15
|
overlayLevel = 0,
|
|
16
16
|
children,
|
|
17
|
+
fullscreen = false,
|
|
18
|
+
withBackdrop = true,
|
|
19
|
+
backdrop,
|
|
20
|
+
openDelay = 130,
|
|
17
21
|
...rest
|
|
18
22
|
}, ref) => {
|
|
19
|
-
const [opened, setOpened] = useState(
|
|
23
|
+
const [opened, setOpened] = useState(openDelay === 0);
|
|
24
|
+
const focusTrapRef = useFocusTrap(opened);
|
|
20
25
|
const dialogRef = useRef(null);
|
|
21
26
|
const isClosingRef = useRef(false);
|
|
22
27
|
const motionNotReduced = useReducedMotionConfig() !== true;
|
|
23
|
-
const onCloseRef =
|
|
28
|
+
const onCloseRef = useRef(onClose);
|
|
29
|
+
onCloseRef.current = onClose;
|
|
24
30
|
const close = useDebouncedCallback(
|
|
25
31
|
() => {
|
|
26
32
|
if (isClosingRef.current) return;
|
|
@@ -30,33 +36,36 @@ const Overlay = forwardRef(({
|
|
|
30
36
|
[],
|
|
31
37
|
50
|
|
32
38
|
);
|
|
33
|
-
|
|
34
|
-
const cancel = (e) => {
|
|
35
|
-
e.preventDefault();
|
|
36
|
-
e.stopPropagation();
|
|
37
|
-
close();
|
|
38
|
-
};
|
|
39
|
-
dialogRef.current?.addEventListener("cancel", cancel, { capture: true });
|
|
40
|
-
return () => {
|
|
41
|
-
dialogRef.current?.removeEventListener("cancel", cancel, { capture: true });
|
|
42
|
-
};
|
|
43
|
-
}, []);
|
|
44
|
-
useTimeoutEffect(() => {
|
|
39
|
+
useLayoutEffect(() => {
|
|
45
40
|
if (!dialogRef.current?.open) {
|
|
46
41
|
dialogRef.current?.showModal();
|
|
47
42
|
}
|
|
48
|
-
},
|
|
43
|
+
}, []);
|
|
49
44
|
useTimeoutEffect(() => {
|
|
50
45
|
setOpened(true);
|
|
51
|
-
},
|
|
46
|
+
}, openDelay > 0 ? openDelay : void 0);
|
|
52
47
|
const styles = overlay({
|
|
53
|
-
|
|
48
|
+
fullscreen,
|
|
49
|
+
withBackdrop
|
|
54
50
|
});
|
|
51
|
+
let targetBackdropOpacity = overlayLevel > 0 ? "50%" : "60%";
|
|
52
|
+
if (backdrop?.opacity !== void 0) {
|
|
53
|
+
targetBackdropOpacity = `${backdrop.opacity * 100}%`;
|
|
54
|
+
}
|
|
55
55
|
return /* @__PURE__ */ jsx(
|
|
56
56
|
m.dialog,
|
|
57
57
|
{
|
|
58
|
-
ref: useMergedRef(
|
|
59
|
-
|
|
58
|
+
ref: useMergedRef(
|
|
59
|
+
dialogRef,
|
|
60
|
+
focusTrapRef,
|
|
61
|
+
ref
|
|
62
|
+
),
|
|
63
|
+
className: cx(
|
|
64
|
+
classes?.dialog,
|
|
65
|
+
className,
|
|
66
|
+
styles.dialog,
|
|
67
|
+
fullscreen && RemoveScroll.classNames.fullWidth
|
|
68
|
+
),
|
|
60
69
|
layout: true,
|
|
61
70
|
style: {
|
|
62
71
|
// @ts-ignore
|
|
@@ -66,28 +75,35 @@ const Overlay = forwardRef(({
|
|
|
66
75
|
initial: {
|
|
67
76
|
[backdropBlur]: "0px",
|
|
68
77
|
[backdropOpacity]: "0%",
|
|
69
|
-
scale:
|
|
78
|
+
scale: 0.95,
|
|
79
|
+
originY: 0,
|
|
80
|
+
translateY: -20,
|
|
70
81
|
opacity: 0
|
|
71
82
|
},
|
|
72
83
|
animate: {
|
|
73
84
|
[backdropBlur]: overlayLevel > 0 ? "4px" : "8px",
|
|
74
|
-
[backdropOpacity]:
|
|
85
|
+
[backdropOpacity]: targetBackdropOpacity,
|
|
75
86
|
scale: 1,
|
|
76
87
|
opacity: 1,
|
|
88
|
+
translateY: 0,
|
|
77
89
|
transition: {
|
|
78
90
|
delay: 0.075
|
|
79
91
|
}
|
|
80
92
|
},
|
|
81
93
|
exit: {
|
|
82
|
-
scale: 1.2,
|
|
83
94
|
opacity: 0,
|
|
95
|
+
scale: 0.98,
|
|
96
|
+
translateY: -20,
|
|
97
|
+
transition: {
|
|
98
|
+
duration: 0.1
|
|
99
|
+
},
|
|
84
100
|
[backdropBlur]: "0px",
|
|
85
101
|
[backdropOpacity]: "0%"
|
|
86
102
|
}
|
|
87
103
|
} : {
|
|
88
104
|
initial: {
|
|
89
105
|
[backdropBlur]: "8px",
|
|
90
|
-
[backdropOpacity]:
|
|
106
|
+
[backdropOpacity]: targetBackdropOpacity
|
|
91
107
|
}
|
|
92
108
|
},
|
|
93
109
|
onClick: (e) => {
|
|
@@ -97,6 +113,11 @@ const Overlay = forwardRef(({
|
|
|
97
113
|
return;
|
|
98
114
|
}
|
|
99
115
|
},
|
|
116
|
+
onCancel: (e) => {
|
|
117
|
+
e.preventDefault();
|
|
118
|
+
e.stopPropagation();
|
|
119
|
+
close();
|
|
120
|
+
},
|
|
100
121
|
onDoubleClick: stopPropagation,
|
|
101
122
|
onPointerDown: stopPropagation,
|
|
102
123
|
onClose: (e) => {
|
|
@@ -104,7 +125,17 @@ const Overlay = forwardRef(({
|
|
|
104
125
|
close();
|
|
105
126
|
},
|
|
106
127
|
...rest,
|
|
107
|
-
children: /* @__PURE__ */ jsx(RemoveScroll, { forwardProps: true,
|
|
128
|
+
children: /* @__PURE__ */ jsx(RemoveScroll, { forwardProps: true, children: /* @__PURE__ */ jsx(
|
|
129
|
+
"div",
|
|
130
|
+
{
|
|
131
|
+
className: cx(
|
|
132
|
+
classes?.body,
|
|
133
|
+
styles.body,
|
|
134
|
+
"overlay-body"
|
|
135
|
+
),
|
|
136
|
+
children: opened && /* @__PURE__ */ jsx(Fragment, { children })
|
|
137
|
+
}
|
|
138
|
+
) })
|
|
108
139
|
}
|
|
109
140
|
);
|
|
110
141
|
});
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Fqn } from '@likec4/core';
|
|
1
|
+
import { Fqn } from '@likec4/core/types';
|
|
2
2
|
import { ActorLogicFrom, ActorRefFrom, SnapshotFrom, StateMachine, ActorRefFromLogic, CallbackActorLogic, EventObject, NonReducibleUnknown, Values, MetaObject } from 'xstate';
|
|
3
3
|
import { Overlays } from './types';
|
|
4
4
|
import { ElementDetailsLogic } from './element-details/actor';
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { RelationshipDetailsActorRef } from './actor';
|
|
2
2
|
import { FunctionComponent, CSSProperties, ReactNode } from 'react';
|
|
3
3
|
import { Position } from '@xyflow/system';
|
|
4
|
+
import { EdgeData, Dimmed } from '../../base/types.Base';
|
|
4
5
|
import { RelationId, Color, ViewId, RelationshipLineType } from '@likec4/core';
|
|
5
6
|
export declare const edgeTypes: {
|
|
6
7
|
relationship: FunctionComponent<{
|
|
@@ -30,10 +31,10 @@ export declare const edgeTypes: {
|
|
|
30
31
|
markerEnd?: string;
|
|
31
32
|
pathOptions?: any;
|
|
32
33
|
interactionWidth?: number;
|
|
33
|
-
data:
|
|
34
|
+
data: EdgeData & {
|
|
34
35
|
hovered?: boolean;
|
|
35
36
|
active?: boolean;
|
|
36
|
-
dimmed?:
|
|
37
|
+
dimmed?: Dimmed;
|
|
37
38
|
relationId: RelationId;
|
|
38
39
|
color: Color | undefined;
|
|
39
40
|
label: string | null;
|
|
@@ -46,7 +46,7 @@ const selectSubject = (state) => ({
|
|
|
46
46
|
const SyncRelationshipDetailsXYFlow = memo(() => {
|
|
47
47
|
const actor = useRelationshipDetailsActor();
|
|
48
48
|
const subject = useSelector(actor, selectSubject, deepEqual);
|
|
49
|
-
const likec4model = useLikeC4Model(
|
|
49
|
+
const likec4model = useLikeC4Model();
|
|
50
50
|
const view = likec4model.findView(subject.viewId) ?? null;
|
|
51
51
|
const data = useMemo(() => {
|
|
52
52
|
let data2;
|
|
@@ -170,14 +170,14 @@ const topLeftPanelselector = ({ context }) => ({
|
|
|
170
170
|
});
|
|
171
171
|
const TopLeftPanel = memo(() => {
|
|
172
172
|
const { subject, viewId } = useRelationshipDetailsState(topLeftPanelselector, deepEqual);
|
|
173
|
-
const likec4model = useLikeC4Model(
|
|
173
|
+
const likec4model = useLikeC4Model();
|
|
174
174
|
const view = likec4model.findView(viewId);
|
|
175
175
|
if (!view || !view.isDiagram()) {
|
|
176
176
|
return null;
|
|
177
177
|
}
|
|
178
178
|
const edges = [...view.edges()];
|
|
179
179
|
let edge = "edgeId" in subject && isTruthy(subject.edgeId) ? edges.find((e) => e.id === subject.edgeId) : find(edges, (e) => e.source.element?.id === subject.source && e.target.element?.id === subject.target) || find(edges, (e) => {
|
|
180
|
-
return (e.source.element?.id === subject.source || isAncestor(e.source.element?.id ?? "
|
|
180
|
+
return (e.source.element?.id === subject.source || isAncestor(e.source.element?.id ?? "__", subject.source ?? "__")) && (e.target.element?.id === subject.target || isAncestor(e.target.element?.id ?? "__", subject.target ?? "__"));
|
|
181
181
|
});
|
|
182
182
|
if (!edge) {
|
|
183
183
|
return null;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Color, DiagramNode, Fqn, IconUrl, RelationId, RelationshipLineType, ViewId } from '@likec4/core';
|
|
1
|
+
import { Color, DiagramNode, Fqn, IconUrl, RelationId, RelationshipLineType, ViewId } from '@likec4/core/types';
|
|
2
2
|
import { Simplify } from 'type-fest';
|
|
3
3
|
import { Base, NonOptional, ReactFlowEdge, ReactFlowNode } from '../../base/types';
|
|
4
4
|
export declare namespace RelationshipDetailsTypes {
|
|
@@ -10,7 +10,7 @@ export declare namespace RelationshipDetailsTypes {
|
|
|
10
10
|
in: string[];
|
|
11
11
|
out: string[];
|
|
12
12
|
};
|
|
13
|
-
type ElementNodeData = Base.NodeData & NonOptional<Pick<DiagramNode, 'title' | 'technology' | 'description' | 'color' | 'shape' | 'width' | 'height' | 'navigateTo' | 'style'>> & {
|
|
13
|
+
type ElementNodeData = Base.NodeData & NonOptional<Pick<DiagramNode, 'title' | 'technology' | 'description' | 'color' | 'shape' | 'width' | 'height' | 'navigateTo' | 'style' | 'tags'>> & {
|
|
14
14
|
column: Column;
|
|
15
15
|
fqn: Fqn;
|
|
16
16
|
icon: IconUrl;
|
|
@@ -7,7 +7,7 @@ import { MinZoom } from '../../base/const.js';
|
|
|
7
7
|
import { updateEdges } from '../../base/updateEdges.js';
|
|
8
8
|
import { updateNodes } from '../../base/updateNodes.js';
|
|
9
9
|
import { layoutResultToXYFlow } from './layout-to-xyflow.js';
|
|
10
|
-
import {
|
|
10
|
+
import { setDimmed, setHovered, setData } from '../../base/types.Base.js';
|
|
11
11
|
|
|
12
12
|
function inputToSubject(input) {
|
|
13
13
|
if ("edgeId" in input) {
|
|
@@ -161,12 +161,12 @@ const relationshipDetailsLogic = setup({
|
|
|
161
161
|
);
|
|
162
162
|
return context.xyedges.map((edge) => {
|
|
163
163
|
if (edge.id === event.edge.id) {
|
|
164
|
-
return
|
|
164
|
+
return setData(edge, {
|
|
165
165
|
hovered: true,
|
|
166
166
|
dimmed: false
|
|
167
167
|
});
|
|
168
168
|
}
|
|
169
|
-
return hasDimmed && !edge.selected ?
|
|
169
|
+
return hasDimmed && !edge.selected ? setDimmed(edge, "immediate") : edge;
|
|
170
170
|
});
|
|
171
171
|
}
|
|
172
172
|
}),
|
|
@@ -180,7 +180,7 @@ const relationshipDetailsLogic = setup({
|
|
|
180
180
|
assign({
|
|
181
181
|
xyedges: ({ context, event }) => context.xyedges.map((edge) => {
|
|
182
182
|
if (edge.id === event.edge.id) {
|
|
183
|
-
return
|
|
183
|
+
return setHovered(edge, false);
|
|
184
184
|
}
|
|
185
185
|
return edge;
|
|
186
186
|
})
|
|
@@ -191,7 +191,7 @@ const relationshipDetailsLogic = setup({
|
|
|
191
191
|
},
|
|
192
192
|
"dim.nonhovered.edges": {
|
|
193
193
|
actions: assign({
|
|
194
|
-
xyedges: ({ context }) => context.xyedges.map((edge) =>
|
|
194
|
+
xyedges: ({ context }) => context.xyedges.map((edge) => setDimmed(edge, edge.data.hovered !== true))
|
|
195
195
|
})
|
|
196
196
|
},
|
|
197
197
|
"undim.edges": {
|
|
@@ -200,10 +200,10 @@ const relationshipDetailsLogic = setup({
|
|
|
200
200
|
const hasSelected = context.xyedges.some((edge) => edge.selected === true);
|
|
201
201
|
if (hasSelected) {
|
|
202
202
|
return context.xyedges.map(
|
|
203
|
-
(edge) =>
|
|
203
|
+
(edge) => setDimmed(edge, edge.selected !== true ? edge.data.dimmed || "immediate" : false)
|
|
204
204
|
);
|
|
205
205
|
}
|
|
206
|
-
return context.xyedges.map(
|
|
206
|
+
return context.xyedges.map(setDimmed(false));
|
|
207
207
|
}
|
|
208
208
|
})
|
|
209
209
|
},
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { FunctionComponent, CSSProperties, ReactNode } from 'react';
|
|
2
2
|
import { Position } from '@xyflow/system';
|
|
3
|
+
import { EdgeData, Dimmed } from '../../../base/types.Base';
|
|
3
4
|
import { RelationId, Color, ViewId, RelationshipLineType } from '@likec4/core';
|
|
4
5
|
export declare const RelationshipEdge: FunctionComponent<{
|
|
5
6
|
id: string;
|
|
@@ -28,10 +29,10 @@ export declare const RelationshipEdge: FunctionComponent<{
|
|
|
28
29
|
markerEnd?: string;
|
|
29
30
|
pathOptions?: any;
|
|
30
31
|
interactionWidth?: number;
|
|
31
|
-
data:
|
|
32
|
+
data: EdgeData & {
|
|
32
33
|
hovered?: boolean;
|
|
33
34
|
active?: boolean;
|
|
34
|
-
dimmed?:
|
|
35
|
+
dimmed?: Dimmed;
|
|
35
36
|
relationId: RelationId;
|
|
36
37
|
color: Color | undefined;
|
|
37
38
|
label: string | null;
|
|
@@ -2,6 +2,7 @@ import { jsxs, jsx, Fragment } from 'react/jsx-runtime';
|
|
|
2
2
|
import { ElementActions } from './ElementActions.js';
|
|
3
3
|
import { Handle } from '@xyflow/react';
|
|
4
4
|
import { Position } from '@xyflow/system';
|
|
5
|
+
import { useEnabledFeatures } from '../../../context/DiagramFeatures.js';
|
|
5
6
|
import { useDiagram } from '../../../hooks/useDiagram.js';
|
|
6
7
|
import { customNode } from '../../../base/primitives/customNode.js';
|
|
7
8
|
import { CompoundNodeContainer } from '../../../base/primitives/compound/CompoundNodeContainer.js';
|
|
@@ -9,6 +10,7 @@ import { CompoundTitle } from '../../../base/primitives/compound/CompoundTitle.j
|
|
|
9
10
|
import { ElementNodeContainer } from '../../../base/primitives/element/ElementNodeContainer.js';
|
|
10
11
|
import { ElementShape } from '../../../base/primitives/element/ElementShape.js';
|
|
11
12
|
import { ElementTitle } from '../../../base/primitives/element/ElementTitle.js';
|
|
13
|
+
import { ElementTags } from '../../../base/primitives/element/ElementTags.js';
|
|
12
14
|
import { ElementDetailsButton } from '../../../base/primitives/element/ElementDetailsButton.js';
|
|
13
15
|
|
|
14
16
|
const ElementDetailsButtonWithHandler = (props) => {
|
|
@@ -25,9 +27,11 @@ const ElementDetailsButtonWithHandler = (props) => {
|
|
|
25
27
|
);
|
|
26
28
|
};
|
|
27
29
|
const ElementNode = customNode((props) => {
|
|
30
|
+
const { enableElementTags } = useEnabledFeatures();
|
|
28
31
|
return /* @__PURE__ */ jsxs(ElementNodeContainer, { nodeProps: props, children: [
|
|
29
32
|
/* @__PURE__ */ jsx(ElementShape, { ...props }),
|
|
30
33
|
/* @__PURE__ */ jsx(ElementTitle, { ...props }),
|
|
34
|
+
enableElementTags && /* @__PURE__ */ jsx(ElementTags, { ...props }),
|
|
31
35
|
/* @__PURE__ */ jsx(ElementDetailsButtonWithHandler, { ...props }),
|
|
32
36
|
/* @__PURE__ */ jsx(ElementActions, { ...props }),
|
|
33
37
|
/* @__PURE__ */ jsx(ElementPorts, { ...props })
|
|
@@ -3,6 +3,7 @@ import { RelationshipDetailsActorRef, RelationshipDetailsSnapshot, Events } from
|
|
|
3
3
|
import { Context, ReactNode, CSSProperties } from 'react';
|
|
4
4
|
import { GeneralHelpers, ViewportHelperFunctions, ReactFlowState } from '@xyflow/react';
|
|
5
5
|
import { EdgeMarkerType, HandleType } from '@xyflow/system';
|
|
6
|
+
import { Dimmed } from '../../base/types.Base';
|
|
6
7
|
export declare const RelationshipDetailsActorContext: Context<RelationshipDetailsActorRef | null>;
|
|
7
8
|
export declare function useRelationshipDetailsActor(): RelationshipDetailsActorRef;
|
|
8
9
|
export declare function useRelationshipDetailsState<T = unknown>(selector: (state: RelationshipDetailsSnapshot) => T, compare?: (a: NoInfer<T>, b: NoInfer<T>) => boolean): T;
|
|
@@ -50,7 +51,7 @@ export declare function useRelationshipDetails(): {
|
|
|
50
51
|
data: {
|
|
51
52
|
hovered?: boolean;
|
|
52
53
|
active?: boolean;
|
|
53
|
-
dimmed?:
|
|
54
|
+
dimmed?: Dimmed;
|
|
54
55
|
relationId: RelationId;
|
|
55
56
|
color: Color | undefined;
|
|
56
57
|
label: string | null;
|
|
@@ -93,7 +94,7 @@ export declare function useRelationshipDetails(): {
|
|
|
93
94
|
data: {
|
|
94
95
|
hovered?: boolean;
|
|
95
96
|
active?: boolean;
|
|
96
|
-
dimmed?:
|
|
97
|
+
dimmed?: Dimmed;
|
|
97
98
|
relationId: RelationId;
|
|
98
99
|
color: Color | undefined;
|
|
99
100
|
label: string | null;
|
|
@@ -133,7 +134,7 @@ export declare function useRelationshipDetails(): {
|
|
|
133
134
|
data: {
|
|
134
135
|
hovered?: boolean;
|
|
135
136
|
active?: boolean;
|
|
136
|
-
dimmed?:
|
|
137
|
+
dimmed?: Dimmed;
|
|
137
138
|
relationId: RelationId;
|
|
138
139
|
color: Color | undefined;
|
|
139
140
|
label: string | null;
|
|
@@ -172,7 +173,7 @@ export declare function useRelationshipDetails(): {
|
|
|
172
173
|
data: {
|
|
173
174
|
hovered?: boolean;
|
|
174
175
|
active?: boolean;
|
|
175
|
-
dimmed?:
|
|
176
|
+
dimmed?: Dimmed;
|
|
176
177
|
relationId: RelationId;
|
|
177
178
|
color: Color | undefined;
|
|
178
179
|
label: string | null;
|
|
@@ -211,7 +212,7 @@ export declare function useRelationshipDetails(): {
|
|
|
211
212
|
data: {
|
|
212
213
|
hovered?: boolean;
|
|
213
214
|
active?: boolean;
|
|
214
|
-
dimmed?:
|
|
215
|
+
dimmed?: Dimmed;
|
|
215
216
|
relationId: RelationId;
|
|
216
217
|
color: Color | undefined;
|
|
217
218
|
label: string | null;
|
|
@@ -250,7 +251,7 @@ export declare function useRelationshipDetails(): {
|
|
|
250
251
|
data: {
|
|
251
252
|
hovered?: boolean;
|
|
252
253
|
active?: boolean;
|
|
253
|
-
dimmed?:
|
|
254
|
+
dimmed?: Dimmed;
|
|
254
255
|
relationId: RelationId;
|
|
255
256
|
color: Color | undefined;
|
|
256
257
|
label: string | null;
|
|
@@ -289,7 +290,7 @@ export declare function useRelationshipDetails(): {
|
|
|
289
290
|
data: {
|
|
290
291
|
hovered?: boolean;
|
|
291
292
|
active?: boolean;
|
|
292
|
-
dimmed?:
|
|
293
|
+
dimmed?: Dimmed;
|
|
293
294
|
relationId: RelationId;
|
|
294
295
|
color: Color | undefined;
|
|
295
296
|
label: string | null;
|
|
@@ -329,7 +330,7 @@ export declare function useRelationshipDetails(): {
|
|
|
329
330
|
data: {
|
|
330
331
|
hovered?: boolean;
|
|
331
332
|
active?: boolean;
|
|
332
|
-
dimmed?:
|
|
333
|
+
dimmed?: Dimmed;
|
|
333
334
|
relationId: RelationId;
|
|
334
335
|
color: Color | undefined;
|
|
335
336
|
label: string | null;
|
|
@@ -368,7 +369,7 @@ export declare function useRelationshipDetails(): {
|
|
|
368
369
|
data: {
|
|
369
370
|
hovered?: boolean;
|
|
370
371
|
active?: boolean;
|
|
371
|
-
dimmed?:
|
|
372
|
+
dimmed?: Dimmed;
|
|
372
373
|
relationId: RelationId;
|
|
373
374
|
color: Color | undefined;
|
|
374
375
|
label: string | null;
|