@likec4/diagram 1.17.1 → 1.19.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.
- package/LICENSE +1 -1
- package/dist/LikeC4CustomColors.d.ts +7 -0
- package/dist/LikeC4CustomColors.js +30 -0
- package/dist/LikeC4Diagram.css.d.ts +5 -0
- package/dist/LikeC4Diagram.css.js +13 -0
- package/dist/LikeC4Diagram.d.ts +6 -0
- package/dist/LikeC4Diagram.js +194 -0
- package/dist/LikeC4Diagram.props.d.ts +166 -0
- package/dist/LikeC4ModelProvider.d.ts +9 -0
- package/dist/LikeC4ModelProvider.js +12 -0
- package/dist/LikeC4Search.css.d.ts +1 -0
- package/dist/LikeC4Search.css.js +5 -0
- package/dist/LikeC4Search.d.ts +2 -0
- package/dist/LikeC4Search.js +96 -0
- package/dist/StaticLikeC4Diagram.d.ts +3 -0
- package/dist/StaticLikeC4Diagram.js +41 -0
- package/dist/_virtual/_commonjsHelpers.js +6 -0
- package/dist/controls/Text.d.ts +2 -0
- package/dist/controls/Text.js +7 -0
- package/dist/controls/action-button-bar/ActionButtonBar.css.d.ts +1 -0
- package/dist/controls/action-button-bar/ActionButtonBar.css.js +5 -0
- package/dist/controls/action-button-bar/ActionButtonBar.d.ts +9 -0
- package/dist/controls/action-button-bar/ActionButtonBar.js +100 -0
- package/dist/controls/action-button-bar/useActionButtonBarCtx.d.ts +10 -0
- package/dist/controls/action-button-bar/useActionButtonBarCtx.js +9 -0
- package/dist/controls/action-buttons/ActionButton.css.d.ts +1 -0
- package/dist/controls/action-buttons/ActionButton.css.js +5 -0
- package/dist/controls/action-buttons/ActionButton.d.ts +9 -0
- package/dist/controls/action-buttons/ActionButton.js +66 -0
- package/dist/controls/action-buttons/ActionButtons.d.ts +12 -0
- package/dist/controls/action-buttons/ActionButtons.js +99 -0
- package/dist/globals.css.d.ts +1 -0
- package/dist/globals.css.js +92 -0
- package/dist/hooks/index.d.ts +5 -0
- package/dist/hooks/useDiagramState.d.ts +6 -0
- package/dist/hooks/useDiagramState.js +27 -0
- package/dist/hooks/useMantinePortalProps.d.ts +9 -0
- package/dist/hooks/useMantinePortalProps.js +9 -0
- package/dist/hooks/useSetState.d.ts +2 -0
- package/dist/hooks/useSetState.js +19 -0
- package/dist/hooks/useUpdateEffect.d.ts +4 -0
- package/dist/hooks/useUpdateEffect.js +32 -0
- package/dist/hooks/useXYFlow.d.ts +270 -0
- package/dist/hooks/useXYFlow.js +20 -0
- package/dist/index.d.ts +11 -0
- package/dist/index.js +25 -0
- package/dist/likec4model/LikeC4ModelContext.d.ts +3 -0
- package/dist/likec4model/LikeC4ModelContext.js +5 -0
- package/dist/likec4model/index.d.ts +2 -0
- package/dist/likec4model/useLikeC4ElementsTree.d.ts +12 -0
- package/dist/likec4model/useLikeC4ElementsTree.js +25 -0
- package/dist/likec4model/useLikeC4Model.d.ts +20 -0
- package/dist/likec4model/useLikeC4Model.js +55 -0
- package/dist/overlays/OverlayContext.d.ts +10 -0
- package/dist/overlays/OverlayContext.js +9 -0
- package/dist/overlays/Overlays.css.d.ts +3 -0
- package/dist/overlays/Overlays.css.js +7 -0
- package/dist/overlays/Overlays.d.ts +2 -0
- package/dist/overlays/Overlays.js +137 -0
- package/dist/overlays/edge-details/EdgeDetailsXYFlow.d.ts +5 -0
- package/dist/overlays/edge-details/EdgeDetailsXYFlow.js +185 -0
- package/dist/overlays/edge-details/SelectEdge.css.d.ts +7 -0
- package/dist/overlays/edge-details/SelectEdge.css.js +17 -0
- package/dist/overlays/edge-details/SelectEdge.d.ts +5 -0
- package/dist/overlays/edge-details/SelectEdge.js +129 -0
- package/dist/overlays/edge-details/_types.d.ts +14 -0
- package/dist/overlays/edge-details/use-layouted-edge-details.d.ts +21 -0
- package/dist/overlays/edge-details/use-layouted-edge-details.js +270 -0
- package/dist/overlays/edge-details/xyflow/CompoundNode.d.ts +5 -0
- package/dist/overlays/edge-details/xyflow/CompoundNode.js +76 -0
- package/dist/overlays/edge-details/xyflow/ElementNode.d.ts +5 -0
- package/dist/overlays/edge-details/xyflow/ElementNode.js +159 -0
- package/dist/overlays/edge-details/xyflow/RelationshipEdge.d.ts +3 -0
- package/dist/overlays/edge-details/xyflow/RelationshipEdge.js +84 -0
- package/dist/overlays/edge-details/xyflow/styles.css.d.ts +9 -0
- package/dist/overlays/edge-details/xyflow/styles.css.js +21 -0
- package/dist/overlays/element-details/ElementDetailsCard.css.d.ts +16 -0
- package/dist/overlays/element-details/ElementDetailsCard.css.js +33 -0
- package/dist/overlays/element-details/ElementDetailsCard.d.ts +7 -0
- package/dist/overlays/element-details/ElementDetailsCard.js +484 -0
- package/dist/overlays/element-details/TabPanelDeployments.css.d.ts +4 -0
- package/dist/overlays/element-details/TabPanelDeployments.css.js +11 -0
- package/dist/overlays/element-details/TabPanelDeployments.d.ts +7 -0
- package/dist/overlays/element-details/TabPanelDeployments.js +173 -0
- package/dist/overlays/element-details/TabPanelRelationships.css.d.ts +5 -0
- package/dist/overlays/element-details/TabPanelRelationships.css.js +11 -0
- package/dist/overlays/element-details/TabPanelRelationships.d.ts +8 -0
- package/dist/overlays/element-details/TabPanelRelationships.js +157 -0
- package/dist/overlays/element-details/TabPanelStructure.css.d.ts +2 -0
- package/dist/overlays/element-details/TabPanelStructure.css.js +7 -0
- package/dist/overlays/element-details/TabPanelStructure.d.ts +25 -0
- package/dist/overlays/element-details/TabPanelStructure.js +91 -0
- package/dist/overlays/index.d.ts +1 -0
- package/dist/overlays/relationships-of/RelationshipsOverlay.d.ts +5 -0
- package/dist/overlays/relationships-of/RelationshipsOverlay.js +193 -0
- package/dist/overlays/relationships-of/RelationshipsXYFlow.d.ts +19 -0
- package/dist/overlays/relationships-of/RelationshipsXYFlow.js +290 -0
- package/dist/overlays/relationships-of/SelectElement.css.d.ts +2 -0
- package/dist/overlays/relationships-of/SelectElement.css.js +7 -0
- package/dist/overlays/relationships-of/SelectElement.d.ts +7 -0
- package/dist/overlays/relationships-of/SelectElement.js +126 -0
- package/dist/overlays/relationships-of/_types.d.ts +28 -0
- package/dist/overlays/relationships-of/use-layouted-relationships.d.ts +22 -0
- package/dist/overlays/relationships-of/use-layouted-relationships.js +496 -0
- package/dist/overlays/relationships-of/xyflow/CompoundNode.d.ts +6 -0
- package/dist/overlays/relationships-of/xyflow/CompoundNode.js +120 -0
- package/dist/overlays/relationships-of/xyflow/ElementNode.d.ts +6 -0
- package/dist/overlays/relationships-of/xyflow/ElementNode.js +194 -0
- package/dist/overlays/relationships-of/xyflow/EmptyNode.d.ts +5 -0
- package/dist/overlays/relationships-of/xyflow/EmptyNode.js +18 -0
- package/dist/overlays/relationships-of/xyflow/RelationshipEdge.d.ts +3 -0
- package/dist/overlays/relationships-of/xyflow/RelationshipEdge.js +123 -0
- package/dist/overlays/relationships-of/xyflow/styles.css.d.ts +14 -0
- package/dist/overlays/relationships-of/xyflow/styles.css.js +24 -0
- package/dist/overlays/shared/xyflow/RelationshipEdge.css.d.ts +4 -0
- package/dist/overlays/shared/xyflow/RelationshipEdge.css.js +12 -0
- package/dist/overlays/shared/xyflow/_types.d.ts +77 -0
- package/dist/state/DiagramContext.d.ts +1609 -0
- package/dist/state/DiagramContext.js +101 -0
- package/dist/state/aligners.d.ts +42 -0
- package/dist/state/aligners.js +349 -0
- package/dist/state/diagram-to-xyflow.d.ts +11 -0
- package/dist/state/diagram-to-xyflow.js +113 -0
- package/dist/state/diagramStore.d.ts +1705 -0
- package/dist/state/diagramStore.js +808 -0
- package/dist/state/diagramStore.layout.d.ts +4 -0
- package/dist/state/diagramStore.layout.js +56 -0
- package/dist/style.css +1 -0
- package/dist/theme-vars.css.d.ts +72 -0
- package/dist/theme-vars.css.js +6 -0
- package/dist/theme-vars.css.ts.vanilla.css.js +1 -0
- package/dist/theme-vars.d.ts +3 -0
- package/dist/theme-vars.js +5 -0
- package/dist/ui/DiagramTitlePanel.css.d.ts +4 -0
- package/dist/ui/DiagramTitlePanel.css.js +11 -0
- package/dist/ui/DiagramTitlePanel.d.ts +1 -0
- package/dist/ui/DiagramTitlePanel.js +159 -0
- package/dist/ui/DynamicViewWalkthrough.css.d.ts +4 -0
- package/dist/ui/DynamicViewWalkthrough.css.js +11 -0
- package/dist/ui/DynamicViewWalkthrough.d.ts +1 -0
- package/dist/ui/DynamicViewWalkthrough.js +156 -0
- package/dist/ui/EnsureMantine.d.ts +7 -0
- package/dist/ui/EnsureMantine.js +14 -0
- package/dist/ui/FramerMotionConfig.d.ts +2 -0
- package/dist/ui/FramerMotionConfig.js +14 -0
- package/dist/ui/Link.d.ts +4 -0
- package/dist/ui/Link.js +36 -0
- package/dist/ui/notation/NotationPanel.css.d.ts +6 -0
- package/dist/ui/notation/NotationPanel.css.js +16 -0
- package/dist/ui/notation/NotationPanel.d.ts +1 -0
- package/dist/ui/notation/NotationPanel.js +250 -0
- package/dist/ui/notation/index.d.ts +1 -0
- package/dist/ui/top-left/ChangeAutoLayoutButton.d.ts +2 -0
- package/dist/ui/top-left/ChangeAutoLayoutButton.js +159 -0
- package/dist/ui/top-left/ManualLayoutToolsButton.d.ts +2 -0
- package/dist/ui/top-left/ManualLayoutToolsButton.js +137 -0
- package/dist/ui/top-left/TopLeftPanel.d.ts +4 -0
- package/dist/ui/top-left/TopLeftPanel.js +211 -0
- package/dist/ui/top-left/_shared.d.ts +7 -0
- package/dist/ui/top-left/_shared.js +22 -0
- package/dist/ui/top-left/styles.css.d.ts +8 -0
- package/dist/ui/top-left/styles.css.js +17 -0
- package/dist/utils/types.d.ts +8 -0
- package/dist/utils/vector.d.ts +24 -0
- package/dist/utils/vector.js +55 -0
- package/dist/xyflow/EdgeMarkers.d.ts +12 -0
- package/dist/xyflow/EdgeMarkers.js +192 -0
- package/dist/xyflow/FitviewOnDiagramChange.d.ts +4 -0
- package/dist/xyflow/FitviewOnDiagramChange.js +72 -0
- package/dist/xyflow/SelectEdgesOnNodeFocus.d.ts +1 -0
- package/dist/xyflow/SelectEdgesOnNodeFocus.js +96 -0
- package/dist/xyflow/XYFlow.d.ts +8 -0
- package/dist/xyflow/XYFlow.js +145 -0
- package/dist/xyflow/XYFlowBackground.d.ts +10 -0
- package/dist/xyflow/XYFlowBackground.js +25 -0
- package/dist/xyflow/XYFlowInner.d.ts +8 -0
- package/dist/xyflow/XYFlowInner.js +41 -0
- package/dist/xyflow/const.d.ts +7 -0
- package/dist/xyflow/const.js +12 -0
- package/dist/xyflow/edges/EdgeLabel.d.ts +7 -0
- package/dist/xyflow/edges/EdgeLabel.js +160 -0
- package/dist/xyflow/edges/RelationshipEdge.d.ts +6 -0
- package/dist/xyflow/edges/RelationshipEdge.js +443 -0
- package/dist/xyflow/edges/RelationshipsDropdownMenu.css.d.ts +4 -0
- package/dist/xyflow/edges/RelationshipsDropdownMenu.css.js +11 -0
- package/dist/xyflow/edges/RelationshipsDropdownMenu.d.ts +13 -0
- package/dist/xyflow/edges/RelationshipsDropdownMenu.js +211 -0
- package/dist/xyflow/edges/edges.css.d.ts +17 -0
- package/dist/xyflow/edges/edges.css.js +37 -0
- package/dist/xyflow/edges/utils.d.ts +16 -0
- package/dist/xyflow/edges/utils.js +24 -0
- package/dist/xyflow/nodes/AnimateVariants.d.ts +1313 -0
- package/dist/xyflow/nodes/AnimateVariants.js +123 -0
- package/dist/xyflow/nodes/Node.css.d.ts +3 -0
- package/dist/xyflow/nodes/Node.css.js +9 -0
- package/dist/xyflow/nodes/compound/CompoundNode.css.d.ts +14 -0
- package/dist/xyflow/nodes/compound/CompoundNode.css.js +27 -0
- package/dist/xyflow/nodes/compound/CompoundNode.d.ts +6 -0
- package/dist/xyflow/nodes/compound/CompoundNode.js +216 -0
- package/dist/xyflow/nodes/compound/index.d.ts +1 -0
- package/dist/xyflow/nodes/element/ElementLink.css.d.ts +3 -0
- package/dist/xyflow/nodes/element/ElementLink.d.ts +6 -0
- package/dist/xyflow/nodes/element/ElementNode.d.ts +6 -0
- package/dist/xyflow/nodes/element/ElementNode.js +190 -0
- package/dist/xyflow/nodes/element/ElementShapeSvg.d.ts +17 -0
- package/dist/xyflow/nodes/element/ElementShapeSvg.js +175 -0
- package/dist/xyflow/nodes/element/element.css.d.ts +18 -0
- package/dist/xyflow/nodes/element/element.css.js +31 -0
- package/dist/xyflow/nodes/element/index.d.ts +1 -0
- package/dist/xyflow/nodes/shared/ElementIcon.d.ts +8 -0
- package/dist/xyflow/nodes/shared/ElementIcon.js +38 -0
- package/dist/xyflow/nodes/shared/Toolbar.d.ts +9 -0
- package/dist/xyflow/nodes/shared/Toolbar.js +436 -0
- package/dist/xyflow/types.d.ts +36 -0
- package/dist/xyflow/useLayoutConstraints.d.ts +42 -0
- package/dist/xyflow/useLayoutConstraints.js +226 -0
- package/dist/xyflow/useXYFlowEvents.d.ts +160 -0
- package/dist/xyflow/useXYFlowEvents.js +275 -0
- package/dist/xyflow/utils.d.ts +22 -0
- package/dist/xyflow/utils.js +72 -0
- package/package.json +40 -31
- package/src/LikeC4Diagram.props.ts +21 -12
- package/src/LikeC4Diagram.tsx +8 -10
- package/src/LikeC4Search.css.ts +12 -0
- package/src/LikeC4Search.tsx +45 -93
- package/src/controls/Text.ts +5 -0
- package/src/controls/action-button-bar/ActionButtonBar.css.ts +13 -0
- package/src/controls/action-button-bar/ActionButtonBar.tsx +138 -0
- package/src/controls/action-button-bar/useActionButtonBarCtx.ts +13 -0
- package/src/controls/action-buttons/ActionButton.css.ts +29 -0
- package/src/controls/action-buttons/ActionButton.tsx +66 -0
- package/src/controls/action-buttons/ActionButtons.tsx +138 -0
- package/src/hooks/useDiagramState.ts +8 -3
- package/src/hooks/useXYFlow.ts +9 -8
- package/src/index.ts +12 -6
- package/src/likec4model/index.ts +12 -2
- package/src/likec4model/useLikeC4ElementsTree.ts +6 -13
- package/src/likec4model/useLikeC4Model.ts +21 -11
- package/src/overlays/Overlays.tsx +96 -63
- package/src/overlays/edge-details/EdgeDetailsXYFlow.tsx +18 -10
- package/src/overlays/edge-details/_types.ts +13 -33
- package/src/overlays/edge-details/use-layouted-edge-details.ts +35 -26
- package/src/overlays/edge-details/xyflow/CompoundNode.tsx +3 -11
- package/src/overlays/edge-details/xyflow/ElementNode.tsx +8 -13
- package/src/overlays/edge-details/xyflow/RelationshipEdge.tsx +7 -7
- package/src/overlays/edge-details/xyflow/styles.css.ts +1 -59
- package/src/overlays/element-details/ElementDetailsCard.tsx +91 -78
- package/src/overlays/element-details/TabPanelDeployments.css.ts +69 -0
- package/src/overlays/element-details/TabPanelDeployments.tsx +217 -0
- package/src/overlays/element-details/TabPanelRelationships.tsx +8 -9
- package/src/overlays/element-details/TabPanelStructure.tsx +10 -10
- package/src/overlays/relationships-of/RelationshipsOverlay.tsx +1 -1
- package/src/overlays/relationships-of/RelationshipsXYFlow.tsx +26 -34
- package/src/overlays/relationships-of/SelectElement.tsx +2 -2
- package/src/overlays/relationships-of/_types.ts +20 -58
- package/src/overlays/relationships-of/use-layouted-relationships.ts +54 -59
- package/src/overlays/relationships-of/xyflow/CompoundNode.tsx +10 -16
- package/src/overlays/relationships-of/xyflow/ElementNode.tsx +24 -21
- package/src/overlays/relationships-of/xyflow/EmptyNode.tsx +4 -7
- package/src/overlays/relationships-of/xyflow/RelationshipEdge.tsx +16 -15
- package/src/overlays/shared/xyflow/RelationshipEdge.css.ts +60 -0
- package/src/overlays/shared/xyflow/_types.ts +87 -0
- package/src/state/diagram-to-xyflow.ts +6 -7
- package/src/state/diagramStore.layout.ts +3 -4
- package/src/state/diagramStore.ts +63 -48
- package/src/theme-vars.css.ts +81 -0
- package/src/theme-vars.ts +8 -81
- package/src/ui/DiagramTitlePanel.tsx +7 -34
- package/src/ui/Link.tsx +40 -0
- package/src/ui/notation/NotationPanel.tsx +4 -2
- package/src/ui/top-left/ChangeAutoLayoutButton.tsx +2 -2
- package/src/ui/top-left/TopLeftPanel.tsx +5 -5
- package/src/utils/types.ts +6 -0
- package/src/xyflow/SelectEdgesOnNodeFocus.tsx +3 -3
- package/src/xyflow/XYFlow.tsx +2 -2
- package/src/xyflow/edges/EdgeLabel.tsx +26 -19
- package/src/xyflow/edges/RelationshipEdge.tsx +5 -3
- package/src/xyflow/edges/RelationshipsDropdownMenu.tsx +23 -10
- package/src/xyflow/edges/edges.css.ts +68 -74
- package/src/xyflow/edges/utils.ts +6 -6
- package/src/xyflow/nodes/AnimateVariants.ts +143 -0
- package/src/xyflow/nodes/Node.css.ts +44 -0
- package/src/xyflow/nodes/compound/CompoundNode.css.ts +27 -75
- package/src/xyflow/nodes/compound/CompoundNode.tsx +82 -163
- package/src/xyflow/nodes/element/ElementLink.tsx +2 -3
- package/src/xyflow/nodes/element/ElementNode.tsx +73 -252
- package/src/xyflow/nodes/element/element.css.ts +40 -64
- package/src/xyflow/nodes/shared/ElementIcon.tsx +1 -1
- package/src/xyflow/nodes/shared/Toolbar.tsx +51 -35
- package/src/xyflow/types.ts +48 -51
- package/src/xyflow/useLayoutConstraints.ts +10 -10
- package/src/xyflow/useXYFlowEvents.ts +31 -35
- package/src/xyflow/utils.ts +2 -2
- package/src/ui/OptionsPanel.css.ts +0 -9
- package/src/ui/OptionsPanel.tsx +0 -70
- package/src/ui/options/EdgeOptions.tsx +0 -142
- package/src/ui/options/NodeOptions.tsx +0 -362
- package/src/xyflow/nodes/element/ElementDetails.css.ts +0 -101
- package/src/xyflow/nodes/element/ElementDetails.tsx +0 -393
- package/src/xyflow/nodes/use-animate-variants.tsx +0 -64
|
@@ -11,8 +11,10 @@ import {
|
|
|
11
11
|
ViewportPortal
|
|
12
12
|
} from '@xyflow/react'
|
|
13
13
|
import { memo, useEffect } from 'react'
|
|
14
|
+
import { only } from 'remeda'
|
|
14
15
|
import { useDiagramStoreApi } from '../../hooks/useDiagramState'
|
|
15
|
-
import type {
|
|
16
|
+
import type { SharedFlowTypes } from '../shared/xyflow/_types'
|
|
17
|
+
import type { EdgeDetailsFlowTypes } from './_types'
|
|
16
18
|
import { SelectEdge } from './SelectEdge'
|
|
17
19
|
import * as css from './SelectEdge.css'
|
|
18
20
|
import { useLayoutedEdgeDetails, ZIndexes } from './use-layouted-edge-details'
|
|
@@ -28,7 +30,7 @@ const edgeTypes = {
|
|
|
28
30
|
relation: RelationshipEdge
|
|
29
31
|
}
|
|
30
32
|
|
|
31
|
-
const resetDimmedAndHovered = (xyflow: ReactFlowInstance<
|
|
33
|
+
const resetDimmedAndHovered = (xyflow: ReactFlowInstance<SharedFlowTypes.Node, EdgeDetailsFlowTypes.Edge>) => {
|
|
32
34
|
xyflow.setEdges(edges =>
|
|
33
35
|
edges.map(edge => ({
|
|
34
36
|
...edge,
|
|
@@ -49,12 +51,12 @@ const resetDimmedAndHovered = (xyflow: ReactFlowInstance<XYFlowTypes.Node, XYFlo
|
|
|
49
51
|
dimmed: false,
|
|
50
52
|
hovered: false
|
|
51
53
|
}
|
|
52
|
-
}) as
|
|
54
|
+
}) as SharedFlowTypes.Node
|
|
53
55
|
)
|
|
54
56
|
)
|
|
55
57
|
}
|
|
56
58
|
|
|
57
|
-
const animateEdge = (node:
|
|
59
|
+
const animateEdge = (node: SharedFlowTypes.Node, animated = true) => (edges: EdgeDetailsFlowTypes.Edge[]) => {
|
|
58
60
|
return edges.map(edge => {
|
|
59
61
|
const isConnected = edge.source === node.id || edge.target === node.id || isAncestor(node.id, edge.source)
|
|
60
62
|
|| isAncestor(node.id, edge.target)
|
|
@@ -78,8 +80,8 @@ export const EdgeDetailsXYFlow = memo<{ edgeId: EdgeId }>(function EdgeDetailsXY
|
|
|
78
80
|
|
|
79
81
|
const boundsRef = useSyncedRef(bounds)
|
|
80
82
|
|
|
81
|
-
const xyflow = useReactFlow<
|
|
82
|
-
const xystore = useStoreApi<
|
|
83
|
+
const xyflow = useReactFlow<SharedFlowTypes.Node, EdgeDetailsFlowTypes.Edge>()
|
|
84
|
+
const xystore = useStoreApi<SharedFlowTypes.Node, EdgeDetailsFlowTypes.Edge>()
|
|
83
85
|
|
|
84
86
|
const fitview = useDebouncedCallback(
|
|
85
87
|
() => {
|
|
@@ -115,8 +117,8 @@ export const EdgeDetailsXYFlow = memo<{ edgeId: EdgeId }>(function EdgeDetailsXY
|
|
|
115
117
|
|
|
116
118
|
return (
|
|
117
119
|
<ReactFlow
|
|
118
|
-
defaultEdges={[] as
|
|
119
|
-
defaultNodes={[] as
|
|
120
|
+
defaultEdges={[] as EdgeDetailsFlowTypes.Edge[]}
|
|
121
|
+
defaultNodes={[] as SharedFlowTypes.Node[]}
|
|
120
122
|
nodeTypes={nodeTypes}
|
|
121
123
|
edgeTypes={edgeTypes}
|
|
122
124
|
defaultMarkerColor="var(--xy-edge-stroke)"
|
|
@@ -168,7 +170,7 @@ export const EdgeDetailsXYFlow = memo<{ edgeId: EdgeId }>(function EdgeDetailsXY
|
|
|
168
170
|
...n.data,
|
|
169
171
|
dimmed: n.id !== edge.source && n.id !== edge.target
|
|
170
172
|
}
|
|
171
|
-
} as
|
|
173
|
+
} as SharedFlowTypes.Node))
|
|
172
174
|
)
|
|
173
175
|
}}
|
|
174
176
|
onEdgeMouseLeave={() => {
|
|
@@ -194,7 +196,13 @@ export const EdgeDetailsXYFlow = memo<{ edgeId: EdgeId }>(function EdgeDetailsXY
|
|
|
194
196
|
// }}
|
|
195
197
|
onEdgeClick={(e, edge) => {
|
|
196
198
|
e.stopPropagation()
|
|
197
|
-
|
|
199
|
+
// edge-details only ever deals with edges that represent only one relation
|
|
200
|
+
let relationId = only(edge.data.relations)?.id
|
|
201
|
+
if (relationId) {
|
|
202
|
+
diagramStore.getState().onOpenSource?.({
|
|
203
|
+
relation: relationId
|
|
204
|
+
})
|
|
205
|
+
}
|
|
198
206
|
}}
|
|
199
207
|
// onEdgeClick={(e, edge) => {
|
|
200
208
|
// e.stopPropagation()
|
|
@@ -1,38 +1,18 @@
|
|
|
1
|
-
import type {
|
|
2
|
-
import type {
|
|
3
|
-
import type { SetRequired } from 'type-fest'
|
|
1
|
+
import type { AddEdgeData } from '../../utils/types'
|
|
2
|
+
import type { SharedFlowTypes } from '../shared/xyflow/_types'
|
|
4
3
|
|
|
5
|
-
export namespace
|
|
6
|
-
type NodeProps = {
|
|
7
|
-
fqn: Fqn
|
|
8
|
-
element: Pick<ComputedNode, 'color' | 'title' | 'description' | 'shape' | 'kind'>
|
|
9
|
-
ports: {
|
|
10
|
-
in: string[]
|
|
11
|
-
out: string[]
|
|
12
|
-
}
|
|
13
|
-
navigateTo: ViewID | null
|
|
14
|
-
hovered?: boolean
|
|
15
|
-
/**
|
|
16
|
-
* Whether the node is dimmed
|
|
17
|
-
* 'immediate' means that the node is dimmed without delay
|
|
18
|
-
*/
|
|
19
|
-
dimmed?: 'immediate' | boolean
|
|
20
|
-
}
|
|
21
|
-
|
|
22
|
-
export type ElementNode = SetRequired<ReactFlowNode<NodeProps, 'element'>, 'type'>
|
|
23
|
-
|
|
24
|
-
export type CompoundNode = SetRequired<ReactFlowNode<NodeProps, 'compound'>, 'type'>
|
|
4
|
+
export namespace EdgeDetailsFlowTypes {
|
|
25
5
|
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
}
|
|
34
|
-
type: 'relation'
|
|
6
|
+
/**
|
|
7
|
+
* Data that is exclusive to the edge-details overlay. It will be merged into the edge types
|
|
8
|
+
* provided by SharedFlowTypes.
|
|
9
|
+
*/
|
|
10
|
+
type EdgeDetailsEdgeData = {
|
|
11
|
+
technology: string | null
|
|
12
|
+
description: string | null
|
|
35
13
|
}
|
|
36
14
|
|
|
37
|
-
|
|
15
|
+
// Extend the edge types provided by SharedFlowTypes with EdgeDetailsEdgeData
|
|
16
|
+
|
|
17
|
+
export type Edge = AddEdgeData<SharedFlowTypes.Edge, EdgeDetailsEdgeData>
|
|
38
18
|
}
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import dagre, { type GraphLabel, type Label } from '@dagrejs/dagre'
|
|
2
2
|
import {
|
|
3
|
+
type AbstractRelation,
|
|
3
4
|
compareFqnHierarchically,
|
|
4
5
|
compareRelations,
|
|
5
6
|
type DiagramEdge,
|
|
@@ -16,7 +17,8 @@ import { useMemo } from 'react'
|
|
|
16
17
|
import { filter, first, forEach, isTruthy, map, pipe, prop, reverse, sort, sortBy, takeWhile } from 'remeda'
|
|
17
18
|
import { useDiagramState } from '../../hooks/useDiagramState'
|
|
18
19
|
import { useLikeC4Model } from '../../likec4model'
|
|
19
|
-
import type {
|
|
20
|
+
import type { SharedFlowTypes } from '../shared/xyflow/_types'
|
|
21
|
+
import type { EdgeDetailsFlowTypes } from './_types'
|
|
20
22
|
|
|
21
23
|
/**
|
|
22
24
|
* All constants related to the layout
|
|
@@ -67,16 +69,16 @@ function createGraph() {
|
|
|
67
69
|
type Context = {
|
|
68
70
|
g: dagre.graphlib.Graph
|
|
69
71
|
diagramNodes: Map<Fqn, DiagramNode>
|
|
70
|
-
xynodes: Map<Fqn,
|
|
72
|
+
xynodes: Map<Fqn, SharedFlowTypes.NonEmptyNode>
|
|
71
73
|
edge: DiagramEdge
|
|
72
|
-
edges:
|
|
74
|
+
edges: EdgeDetailsFlowTypes.Edge[]
|
|
73
75
|
}
|
|
74
76
|
const sized = (height: number = Sizes.hodeHeight) => ({
|
|
75
77
|
width: Sizes.nodeWidth,
|
|
76
78
|
height
|
|
77
79
|
})
|
|
78
80
|
|
|
79
|
-
const graphId = (node:
|
|
81
|
+
const graphId = (node: SharedFlowTypes.Node) => ({
|
|
80
82
|
id: node.id,
|
|
81
83
|
port: node.type === 'compound' ? `${node.id}::port` : node.id,
|
|
82
84
|
body: `${node.id}`,
|
|
@@ -84,16 +86,16 @@ const graphId = (node: XYFlowTypes.Node) => ({
|
|
|
84
86
|
})
|
|
85
87
|
|
|
86
88
|
function nodeData(
|
|
87
|
-
element: LikeC4Model.
|
|
89
|
+
element: LikeC4Model.Element,
|
|
88
90
|
ctx: Context
|
|
89
|
-
):
|
|
91
|
+
): SharedFlowTypes.OverlayNodeData {
|
|
90
92
|
// We try to inherit style from existing diagram node
|
|
91
93
|
let diagramNode = ctx.diagramNodes.get(element.id)
|
|
92
94
|
|
|
93
95
|
// Ansector separetely, because we want to inherit
|
|
94
96
|
// color from it if there is no diagram node
|
|
95
97
|
const ancestor = diagramNode ?? pipe(
|
|
96
|
-
element.ancestors(),
|
|
98
|
+
element.ancestors().toArray(),
|
|
97
99
|
map(ancestor => ctx.diagramNodes.get(ancestor.id)),
|
|
98
100
|
filter(isTruthy),
|
|
99
101
|
first()
|
|
@@ -104,11 +106,11 @@ function nodeData(
|
|
|
104
106
|
element: {
|
|
105
107
|
kind: element.kind,
|
|
106
108
|
title: diagramNode?.title ?? element.title,
|
|
107
|
-
description: diagramNode?.description ?? element.
|
|
109
|
+
description: diagramNode?.description ?? element.description,
|
|
108
110
|
color: diagramNode?.color ?? ancestor?.color ?? element.color,
|
|
109
111
|
shape: diagramNode?.shape ?? element.shape
|
|
110
112
|
},
|
|
111
|
-
navigateTo: diagramNode?.navigateTo ?? first(element.
|
|
113
|
+
navigateTo: diagramNode?.navigateTo ?? first(element.scopedViews().take(1).toArray())?.id ?? null,
|
|
112
114
|
ports: {
|
|
113
115
|
in: [],
|
|
114
116
|
out: []
|
|
@@ -117,10 +119,10 @@ function nodeData(
|
|
|
117
119
|
}
|
|
118
120
|
|
|
119
121
|
function createNode(
|
|
120
|
-
nodeType:
|
|
121
|
-
element: LikeC4Model.
|
|
122
|
+
nodeType: SharedFlowTypes.NonEmptyNode['type'],
|
|
123
|
+
element: LikeC4Model.Element,
|
|
122
124
|
ctx: Context
|
|
123
|
-
):
|
|
125
|
+
): SharedFlowTypes.Node {
|
|
124
126
|
let node = ctx.xynodes.get(element.id)
|
|
125
127
|
if (node) {
|
|
126
128
|
return node
|
|
@@ -129,13 +131,13 @@ function createNode(
|
|
|
129
131
|
|
|
130
132
|
// Create parent node
|
|
131
133
|
const parent = pipe(
|
|
132
|
-
element.ancestors(),
|
|
134
|
+
element.ancestors().toArray(),
|
|
133
135
|
takeWhile(ancestor => !isAncestor(ancestor.id, ctx.edge.source) && !isAncestor(ancestor.id, ctx.edge.target)),
|
|
134
136
|
first(),
|
|
135
137
|
found => found ? createNode('compound', found, ctx) : null
|
|
136
138
|
)
|
|
137
139
|
|
|
138
|
-
const xynode:
|
|
140
|
+
const xynode: SharedFlowTypes.NonEmptyNode = {
|
|
139
141
|
type: nodeType,
|
|
140
142
|
id: element.id,
|
|
141
143
|
position: { x: 0, y: 0 },
|
|
@@ -181,7 +183,7 @@ function createNode(
|
|
|
181
183
|
* And return a function to get node bounds for xyflow
|
|
182
184
|
*/
|
|
183
185
|
function applyDagreLayout(g: dagre.graphlib.Graph) {
|
|
184
|
-
type NodeBounds = Required<Pick<
|
|
186
|
+
type NodeBounds = Required<Pick<SharedFlowTypes.Node, 'position' | 'width' | 'height'>>
|
|
185
187
|
dagre.layout(g)
|
|
186
188
|
return function nodeBounds(nodeId: string, relativeTo?: string): NodeBounds {
|
|
187
189
|
const { x, y, width, height } = g.node(nodeId)
|
|
@@ -215,8 +217,8 @@ function layout(
|
|
|
215
217
|
): {
|
|
216
218
|
view: DiagramView
|
|
217
219
|
edge: DiagramEdge
|
|
218
|
-
nodes:
|
|
219
|
-
edges:
|
|
220
|
+
nodes: SharedFlowTypes.Node[]
|
|
221
|
+
edges: EdgeDetailsFlowTypes.Edge[]
|
|
220
222
|
bounds: { x: number; y: number; width: number; height: number }
|
|
221
223
|
} {
|
|
222
224
|
const edge = view.edges.find(e => e.id === edgeId)
|
|
@@ -225,10 +227,14 @@ function layout(
|
|
|
225
227
|
|
|
226
228
|
const relations = edge.relations
|
|
227
229
|
.map(r => {
|
|
228
|
-
const relation = likec4model.relationship(r)
|
|
229
|
-
all.add(relation.source)
|
|
230
|
-
all.add(relation.target)
|
|
231
|
-
return
|
|
230
|
+
const relation = likec4model.relationship(r)
|
|
231
|
+
all.add(relation.source.id)
|
|
232
|
+
all.add(relation.target.id)
|
|
233
|
+
return {
|
|
234
|
+
source: relation.source.id,
|
|
235
|
+
target: relation.target.id,
|
|
236
|
+
relation: relation.$relationship as AbstractRelation
|
|
237
|
+
}
|
|
232
238
|
})
|
|
233
239
|
.sort(compareRelations)
|
|
234
240
|
.reverse()
|
|
@@ -258,17 +264,17 @@ function layout(
|
|
|
258
264
|
g.setDefaultEdgeLabel(() => ({ width: 250 }))
|
|
259
265
|
}
|
|
260
266
|
|
|
261
|
-
for (const relation of relations) {
|
|
262
|
-
const source = ctx.xynodes.get(
|
|
267
|
+
for (const { relation, ...points } of relations) {
|
|
268
|
+
const source = ctx.xynodes.get(points.source)
|
|
263
269
|
invariant(source, 'source node not found')
|
|
264
|
-
const target = ctx.xynodes.get(
|
|
270
|
+
const target = ctx.xynodes.get(points.target)
|
|
265
271
|
invariant(target, 'target node not found')
|
|
266
272
|
|
|
267
273
|
source.data.ports.out.push(target.id)
|
|
268
274
|
target.data.ports.in.push(source.id)
|
|
269
275
|
|
|
270
276
|
g.setEdge(graphId(source).port, graphId(target).port)
|
|
271
|
-
const edge:
|
|
277
|
+
const edge: EdgeDetailsFlowTypes.Edge = {
|
|
272
278
|
id: relation.id,
|
|
273
279
|
type: 'relation',
|
|
274
280
|
source: source.id,
|
|
@@ -276,7 +282,10 @@ function layout(
|
|
|
276
282
|
sourceHandle: target.id,
|
|
277
283
|
targetHandle: source.id,
|
|
278
284
|
data: {
|
|
279
|
-
relation
|
|
285
|
+
relations: [relation],
|
|
286
|
+
navigateTo: relation.navigateTo ?? null,
|
|
287
|
+
technology: relation.technology ?? null,
|
|
288
|
+
description: relation.description ?? null
|
|
280
289
|
},
|
|
281
290
|
label: relation.title,
|
|
282
291
|
zIndex: ZIndexes.edge,
|
|
@@ -1,15 +1,11 @@
|
|
|
1
|
-
import { Text as MantineText } from '@mantine/core'
|
|
2
1
|
import { Handle, type NodeProps, Position } from '@xyflow/react'
|
|
3
2
|
import clsx from 'clsx'
|
|
4
3
|
import { m } from 'framer-motion'
|
|
5
|
-
import type {
|
|
4
|
+
import type { SharedFlowTypes } from '../../shared/xyflow/_types'
|
|
6
5
|
import * as css from './styles.css'
|
|
6
|
+
import { Text } from '../../../controls/Text'
|
|
7
7
|
|
|
8
|
-
|
|
9
|
-
component: 'div'
|
|
10
|
-
})
|
|
11
|
-
|
|
12
|
-
type CompoundNodeProps = NodeProps<XYFlowTypes.CompoundNode>
|
|
8
|
+
type CompoundNodeProps = NodeProps<SharedFlowTypes.CompoundNode>
|
|
13
9
|
|
|
14
10
|
export function CompoundNode({
|
|
15
11
|
data: {
|
|
@@ -71,10 +67,6 @@ export function CompoundNode({
|
|
|
71
67
|
top: `${16 + 20 * i}px`
|
|
72
68
|
}} />
|
|
73
69
|
))}
|
|
74
|
-
{
|
|
75
|
-
/* <Handle type="target" position={Position.Left}/>
|
|
76
|
-
<Handle type="source" position={Position.Right}/> */
|
|
77
|
-
}
|
|
78
70
|
</>
|
|
79
71
|
)
|
|
80
72
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ActionIcon, Box, Group
|
|
1
|
+
import { ActionIcon, Box, Group } from '@mantine/core'
|
|
2
2
|
import { IconFileSymlink, IconTransform, IconZoomScan } from '@tabler/icons-react'
|
|
3
3
|
import { Handle, type NodeProps, Position } from '@xyflow/react'
|
|
4
4
|
import clsx from 'clsx'
|
|
@@ -7,8 +7,9 @@ import { type DiagramState, useDiagramState } from '../../../hooks'
|
|
|
7
7
|
import { ElementShapeSvg } from '../../../xyflow/nodes/element/ElementShapeSvg'
|
|
8
8
|
import { stopPropagation } from '../../../xyflow/utils'
|
|
9
9
|
import { useOverlayDialog } from '../../OverlayContext'
|
|
10
|
-
import type {
|
|
10
|
+
import type { SharedFlowTypes } from '../../shared/xyflow/_types'
|
|
11
11
|
import * as css from './styles.css'
|
|
12
|
+
import { Text } from '../../../controls/Text'
|
|
12
13
|
|
|
13
14
|
const Action = ActionIcon.withProps({
|
|
14
15
|
className: 'nodrag nopan ' + css.navigateBtn,
|
|
@@ -18,18 +19,14 @@ const Action = ActionIcon.withProps({
|
|
|
18
19
|
onPointerDownCapture: stopPropagation
|
|
19
20
|
})
|
|
20
21
|
|
|
21
|
-
|
|
22
|
-
component: 'div'
|
|
23
|
-
})
|
|
24
|
-
|
|
25
|
-
type ElementNodeProps = NodeProps<XYFlowTypes.ElementNode>
|
|
22
|
+
type ElementNodeProps = NodeProps<SharedFlowTypes.ElementNode>
|
|
26
23
|
|
|
27
24
|
function selector(s: DiagramState) {
|
|
28
25
|
return {
|
|
29
26
|
currentViewId: s.view.id,
|
|
30
27
|
enableRelationshipBrowser: s.enableRelationshipBrowser,
|
|
31
28
|
onNavigateTo: s.onNavigateTo,
|
|
32
|
-
onOpenSource: s.
|
|
29
|
+
onOpenSource: s.onOpenSource
|
|
33
30
|
}
|
|
34
31
|
}
|
|
35
32
|
|
|
@@ -119,7 +116,9 @@ export function ElementNode({
|
|
|
119
116
|
<Action
|
|
120
117
|
onClick={(event) => {
|
|
121
118
|
event.stopPropagation()
|
|
122
|
-
onOpenSource(
|
|
119
|
+
onOpenSource({
|
|
120
|
+
element: data.fqn
|
|
121
|
+
})
|
|
123
122
|
}}>
|
|
124
123
|
<IconFileSymlink stroke={1.8} style={{ width: '72%' }} />
|
|
125
124
|
</Action>
|
|
@@ -148,10 +147,6 @@ export function ElementNode({
|
|
|
148
147
|
top: `${15 + (i + 1) * ((h - 30) / (ports.in.length + 1))}px`
|
|
149
148
|
}} />
|
|
150
149
|
))}
|
|
151
|
-
{
|
|
152
|
-
/* <Handle type="target" position={Position.Left} />
|
|
153
|
-
<Handle type="source" position={Position.Right} /> */
|
|
154
|
-
}
|
|
155
150
|
</>
|
|
156
151
|
)
|
|
157
152
|
}
|
|
@@ -2,22 +2,22 @@ import { ActionIcon, Box, Stack, Text } from '@mantine/core'
|
|
|
2
2
|
import { IconZoomScan } from '@tabler/icons-react'
|
|
3
3
|
import { BaseEdge, EdgeLabelRenderer, type EdgeProps, getBezierPath } from '@xyflow/react'
|
|
4
4
|
import clsx from 'clsx'
|
|
5
|
-
import { useDiagramState
|
|
5
|
+
import { useDiagramState } from '../../../hooks/useDiagramState'
|
|
6
6
|
import { stopPropagation } from '../../../xyflow/utils'
|
|
7
7
|
import { useOverlayDialog } from '../../OverlayContext'
|
|
8
|
-
import
|
|
8
|
+
import * as css from '../../shared/xyflow/RelationshipEdge.css'
|
|
9
|
+
import type { EdgeDetailsFlowTypes } from '../_types'
|
|
9
10
|
import { ZIndexes } from '../use-layouted-edge-details'
|
|
10
|
-
import * as css from './styles.css'
|
|
11
11
|
|
|
12
12
|
export function RelationshipEdge({
|
|
13
13
|
data,
|
|
14
14
|
label,
|
|
15
15
|
...props
|
|
16
|
-
}: EdgeProps<
|
|
16
|
+
}: EdgeProps<EdgeDetailsFlowTypes.Edge>) {
|
|
17
17
|
const overlay = useOverlayDialog()
|
|
18
18
|
const onNavigateTo = useDiagramState(s => s.onNavigateTo)
|
|
19
19
|
const [edgePath, labelX, labelY] = getBezierPath(props)
|
|
20
|
-
const navigateTo = data.
|
|
20
|
+
const navigateTo = data.navigateTo
|
|
21
21
|
return (
|
|
22
22
|
<>
|
|
23
23
|
<g
|
|
@@ -51,10 +51,10 @@ export function RelationshipEdge({
|
|
|
51
51
|
{label}
|
|
52
52
|
</Text>
|
|
53
53
|
)}
|
|
54
|
-
{data.
|
|
54
|
+
{data.technology && (
|
|
55
55
|
<Text component={'div'} className={css.edgeLabelTechnology}>
|
|
56
56
|
{'[ '}
|
|
57
|
-
{data.
|
|
57
|
+
{data.technology}
|
|
58
58
|
{' ]'}
|
|
59
59
|
</Text>
|
|
60
60
|
)}
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { globalStyle, style } from '@vanilla-extract/css'
|
|
2
|
-
import { mantine,
|
|
3
|
-
import { mixColor } from '../../Overlays.css'
|
|
2
|
+
import { mantine, vars } from '../../../theme-vars'
|
|
4
3
|
|
|
5
4
|
export const elementNode = style({
|
|
6
5
|
width: '100%',
|
|
@@ -84,63 +83,6 @@ export const cssShapeSvg = style({
|
|
|
84
83
|
zIndex: -1
|
|
85
84
|
})
|
|
86
85
|
|
|
87
|
-
const DimmedTransitionDelay = '400ms'
|
|
88
|
-
|
|
89
|
-
export const edgeContainer = style({
|
|
90
|
-
opacity: 1,
|
|
91
|
-
transition: transitions.fast,
|
|
92
|
-
vars: {
|
|
93
|
-
[xyvars.edge.stroke]: vars.relation.lineColor,
|
|
94
|
-
[xyvars.edge.strokeSelected]: `color-mix(in srgb, ${vars.relation.lineColor}, ${mixColor} 35%)`,
|
|
95
|
-
[xyvars.edge.labelColor]: `color-mix(in srgb, ${vars.relation.labelColor}, rgba(255 255 255 / 0.85) 50%)`,
|
|
96
|
-
[xyvars.edge.labelBgColor]: `color-mix(in srgb, ${vars.relation.labelBgColor}, transparent 20%)`
|
|
97
|
-
},
|
|
98
|
-
selectors: {
|
|
99
|
-
[`&[data-edge-dimmed='true']`]: {
|
|
100
|
-
opacity: 0.2,
|
|
101
|
-
transitionDelay: DimmedTransitionDelay
|
|
102
|
-
},
|
|
103
|
-
[`&[data-edge-dimmed='immediate']`]: {
|
|
104
|
-
opacity: 0.2
|
|
105
|
-
},
|
|
106
|
-
[`${whereDark} &`]: {
|
|
107
|
-
vars: {
|
|
108
|
-
[xyvars.edge.labelBgColor]: `color-mix(in srgb, ${vars.relation.labelBgColor}, transparent 50%)`
|
|
109
|
-
}
|
|
110
|
-
}
|
|
111
|
-
}
|
|
112
|
-
})
|
|
113
|
-
|
|
114
|
-
export const edgeLabel = style([edgeContainer, {
|
|
115
|
-
padding: '2px 5px',
|
|
116
|
-
fontFamily: vars.likec4.font,
|
|
117
|
-
position: 'absolute',
|
|
118
|
-
cursor: 'pointer',
|
|
119
|
-
width: 'fit-content',
|
|
120
|
-
color: xyvars.edge.labelColor,
|
|
121
|
-
backgroundColor: xyvars.edge.labelBgColor,
|
|
122
|
-
borderRadius: 4,
|
|
123
|
-
// everything inside EdgeLabelRenderer has no pointer events by default
|
|
124
|
-
// if you have an interactive element, set pointer-events: all
|
|
125
|
-
pointerEvents: 'all',
|
|
126
|
-
textWrap: 'pretty',
|
|
127
|
-
whiteSpace: 'preserve-breaks'
|
|
128
|
-
}])
|
|
129
|
-
|
|
130
|
-
export const edgeLabelText = style({
|
|
131
|
-
textAlign: 'center',
|
|
132
|
-
whiteSpaceCollapse: 'preserve-breaks',
|
|
133
|
-
fontSize: mantine.fontSizes.md,
|
|
134
|
-
lineHeight: mantine.lineHeights.xs
|
|
135
|
-
})
|
|
136
|
-
|
|
137
|
-
export const edgeLabelTechnology = style({
|
|
138
|
-
textAlign: 'center',
|
|
139
|
-
whiteSpaceCollapse: 'preserve-breaks',
|
|
140
|
-
fontSize: mantine.fontSizes.sm,
|
|
141
|
-
lineHeight: 1
|
|
142
|
-
})
|
|
143
|
-
|
|
144
86
|
export const navigateBtnBox = style({
|
|
145
87
|
zIndex: 100,
|
|
146
88
|
position: 'absolute',
|