Skip to content

Commit f6c00ae

Browse files
authored
Merge branch 'main' into creilly11235/vertex-sidebar-registry
2 parents 7bf3f7b + f9645f1 commit f6c00ae

6 files changed

Lines changed: 76 additions & 13 deletions

File tree

packages/apollo-react/CHANGELOG.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,9 @@
1+
## [@uipath/apollo-react-v3.70.3](https://github.com/UiPath/apollo-ui/compare/@uipath/apollo-react@3.70.2...@uipath/apollo-react@3.70.3) (2026-04-09)
2+
3+
### Bug Fixes
4+
5+
* **apollo-react:** clamp node header and subheader text to prevent overflow ([374b758](https://github.com/UiPath/apollo-ui/commit/374b75872a7a514674ea81a5d2e1b73ad39b5b03))
6+
17
## [@uipath/apollo-react-v3.70.1](https://github.com/UiPath/apollo-ui/compare/@uipath/apollo-react@3.70.0...@uipath/apollo-react@3.70.1) (2026-04-08)
28

39
### Bug Fixes

packages/apollo-react/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@uipath/apollo-react",
3-
"version": "3.70.1",
3+
"version": "3.70.3",
44
"description": "Apollo Design System - React component library with Material UI theming",
55
"repository": {
66
"type": "git",

packages/apollo-react/src/canvas/components/BaseNode/BaseNode.styles.ts

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -292,16 +292,19 @@ export const BaseHeader = styled.div<{ shape?: NodeShape; backgroundColor?: stri
292292
`}
293293
line-height: 1.4;
294294
margin-bottom: 2px;
295+
overflow: hidden;
295296
${({ shape }) =>
296297
shape === 'rectangle'
297298
? css`
298299
width: 100%;
299300
white-space: nowrap;
300-
overflow: hidden;
301301
text-overflow: ellipsis;
302302
`
303303
: css`
304304
word-break: break-word;
305+
display: -webkit-box;
306+
-webkit-box-orient: vertical;
307+
-webkit-line-clamp: 3;
305308
`}
306309
`;
307310

@@ -310,16 +313,18 @@ export const BaseSubHeader = styled.div<{ shape?: NodeShape }>`
310313
color: var(--uix-canvas-foreground-de-emp);
311314
line-height: 1.3;
312315
word-break: break-word;
316+
overflow: hidden;
317+
display: -webkit-box;
318+
-webkit-box-orient: vertical;
313319
${({ shape }) =>
314320
shape === 'rectangle'
315321
? css`
316322
width: 100%;
317-
display: -webkit-box;
318-
-webkit-box-orient: vertical;
319323
-webkit-line-clamp: 2;
320-
overflow: hidden;
321324
`
322-
: ''}
325+
: css`
326+
-webkit-line-clamp: 5;
327+
`}
323328
`;
324329

325330
export const EditableLabel = styled.textarea<{

packages/apollo-react/src/canvas/components/StageNode/StageNode.stories.tsx

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1061,6 +1061,20 @@ const AddAndReplaceTasksStory = () => {
10611061
data: {
10621062
stageDetails: {
10631063
label: 'Add, Replace, and Group Tasks',
1064+
isReadOnly: false,
1065+
tasks: initialTasksForAddReplace,
1066+
},
1067+
taskOptions: availableTaskOptions,
1068+
},
1069+
},
1070+
{
1071+
id: 'readonly-stage',
1072+
type: 'stage',
1073+
position: { x: 720, y: 96 },
1074+
data: {
1075+
stageDetails: {
1076+
label: 'ReadOnly Stage',
1077+
isReadOnly: true,
10641078
tasks: initialTasksForAddReplace,
10651079
},
10661080
taskOptions: availableTaskOptions,

packages/apollo-react/src/canvas/components/StageNode/StageNode.test.tsx

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -847,6 +847,42 @@ describe('StageNode - hideParallelOptions', () => {
847847
});
848848
});
849849

850+
describe('StageNode - ReadOnly Mode', () => {
851+
beforeEach(() => {
852+
vi.clearAllMocks();
853+
});
854+
855+
it('should not render task kebab menu when isReadOnly is true', () => {
856+
const onTaskGroupModification = vi.fn();
857+
const tasks: StageTaskItem[][] = [
858+
[createTask('task-1', 'Task 1')],
859+
[createTask('task-2', 'Task 2')],
860+
];
861+
862+
renderStageNode({
863+
onTaskGroupModification,
864+
stageDetails: { ...defaultProps.stageDetails, tasks, isReadOnly: true },
865+
});
866+
867+
expect(screen.queryByTestId('task-menu-button-task-1')).not.toBeInTheDocument();
868+
expect(screen.queryByTestId('task-menu-button-task-2')).not.toBeInTheDocument();
869+
});
870+
871+
it('should not render adhoc task kebab menu when isReadOnly is true', () => {
872+
const onTaskGroupModification = vi.fn();
873+
const adhocTask = createTask('adhoc-1', 'Adhoc Task 1');
874+
adhocTask.isAdhoc = true;
875+
const tasks: StageTaskItem[][] = [[adhocTask]];
876+
877+
renderStageNode({
878+
onTaskGroupModification,
879+
stageDetails: { ...defaultProps.stageDetails, tasks, isReadOnly: true },
880+
});
881+
882+
expect(screen.queryByTestId('task-menu-button-adhoc-1')).not.toBeInTheDocument();
883+
});
884+
});
885+
850886
describe('StageNode - Header Chips', () => {
851887
beforeEach(() => {
852888
vi.clearAllMocks();

packages/apollo-react/src/canvas/components/StageNode/StageNode.tsx

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -758,9 +758,10 @@ const StageNodeInner = (props: StageNodeProps) => {
758758
: undefined
759759
}
760760
isDragDisabled={!onTaskReorder}
761-
{...(hasContextMenu && {
762-
getContextMenuItems: buildContextMenuItems,
763-
})}
761+
{...(hasContextMenu &&
762+
!isReadOnly && {
763+
getContextMenuItems: buildContextMenuItems,
764+
})}
764765
/>
765766
);
766767
})}
@@ -800,10 +801,11 @@ const StageNodeInner = (props: StageNodeProps) => {
800801
isSelected={selectedTaskId === task.id}
801802
onTaskClick={handleTaskClick}
802803
onTaskPlay={onTaskPlay}
803-
{...((onTaskGroupModification || onReplaceTaskFromToolbox) && {
804-
getContextMenuItems: () =>
805-
getAdhocContextMenuItems(groupIndex, taskIndex, task.id),
806-
})}
804+
{...((onTaskGroupModification || onReplaceTaskFromToolbox) &&
805+
!isReadOnly && {
806+
getContextMenuItems: () =>
807+
getAdhocContextMenuItems(groupIndex, taskIndex, task.id),
808+
})}
807809
/>
808810
);
809811
})}

0 commit comments

Comments
 (0)