+
+ {labelText}
+
{controller.showTooltip && !node.dragging ? (
) : null}
diff --git a/rsconcept/frontend/src/pages/OssPage/EditorOssGraph/OperationNode.tsx b/rsconcept/frontend/src/pages/OssPage/EditorOssGraph/OperationNode.tsx
index e8055e89..779e0925 100644
--- a/rsconcept/frontend/src/pages/OssPage/EditorOssGraph/OperationNode.tsx
+++ b/rsconcept/frontend/src/pages/OssPage/EditorOssGraph/OperationNode.tsx
@@ -1,3 +1,5 @@
+'use client';
+
import { Handle, Position } from 'reactflow';
import { IconConsolidation, IconRSForm } from '@/components/Icons';
@@ -5,7 +7,8 @@ import TooltipOperation from '@/components/info/TooltipOperation';
import MiniButton from '@/components/ui/MiniButton.tsx';
import Overlay from '@/components/ui/Overlay';
import { OssNodeInternal } from '@/models/miscellaneous';
-import { prefixes } from '@/utils/constants';
+import { PARAMETER, prefixes } from '@/utils/constants';
+import { truncateText } from '@/utils/utils';
import { useOssEdit } from '../OssEditContext';
@@ -13,6 +16,8 @@ function OperationNode(node: OssNodeInternal) {
const controller = useOssEdit();
const hasFile = !!node.data.operation.result;
+ const longLabel = node.data.label.length > PARAMETER.ossLongLabel;
+ const labelText = truncateText(node.data.label, PARAMETER.ossTruncateLabel);
const handleOpenSchema = () => {
controller.openOperationSchema(Number(node.id));
@@ -22,14 +27,9 @@ function OperationNode(node: OssNodeInternal) {
<>
-
+
- }
+ icon={}
noHover
noPadding
title={hasFile ? 'Связанная КС' : 'Нет связанной КС'}
@@ -39,7 +39,7 @@ function OperationNode(node: OssNodeInternal) {
/>
{node.data.operation.is_consolidation ? (
}
+ icon={}
disabled
noPadding
noHover
@@ -55,8 +55,18 @@ function OperationNode(node: OssNodeInternal) {
) : null}
-
- {node.data.label}
+
+
+ {labelText}
+
{controller.showTooltip && !node.dragging ? (
) : null}
diff --git a/rsconcept/frontend/src/styling/overrides.css b/rsconcept/frontend/src/styling/overrides.css
index db41764b..ed8c579b 100644
--- a/rsconcept/frontend/src/styling/overrides.css
+++ b/rsconcept/frontend/src/styling/overrides.css
@@ -66,7 +66,7 @@
border: 1px solid;
padding: 2px;
width: 150px;
- height: 30px;
+ height: 40px;
font-size: 14px;
border-radius: 5px;
diff --git a/rsconcept/frontend/src/utils/constants.ts b/rsconcept/frontend/src/utils/constants.ts
index 167fb57c..9264dafc 100644
--- a/rsconcept/frontend/src/utils/constants.ts
+++ b/rsconcept/frontend/src/utils/constants.ts
@@ -25,6 +25,9 @@ export const PARAMETER = {
graphPopupDelay: 500, // milliseconds delay for graph popup selections
graphRefreshDelay: 10, // milliseconds delay for graph viewpoint reset
+ ossLongLabel: 14, // characters - threshold for long labels - small font
+ ossTruncateLabel: 28, // characters - threshold for long labels - truncate
+
logicLabel: 'LOGIC',
exteorVersion: '4.9.3',