fix(editing): regression bug in disable editing (#3687)
This commit is contained in:
parent
4c88a4a2fd
commit
4dc2acdefa
@ -416,11 +416,13 @@ jobs:
|
|||||||
workflows:
|
workflows:
|
||||||
PR_CHECKS:
|
PR_CHECKS:
|
||||||
jobs:
|
jobs:
|
||||||
- BUILD_PACKAGES_QUICK
|
- BUILD_PACKAGES_QUICK:
|
||||||
|
filters:
|
||||||
|
branches:
|
||||||
|
ignore: master
|
||||||
- UNIT_TESTS:
|
- UNIT_TESTS:
|
||||||
requires:
|
requires:
|
||||||
- BUILD_PACKAGES_QUICK
|
- BUILD_PACKAGES_QUICK
|
||||||
|
|
||||||
- CYPRESS_CUSTOM_RUN:
|
- CYPRESS_CUSTOM_RUN:
|
||||||
name: 'Cypress Tests'
|
name: 'Cypress Tests'
|
||||||
context: cypress
|
context: cypress
|
||||||
|
|||||||
@ -1,13 +1,12 @@
|
|||||||
describe('OHIF Multi Study', () => {
|
describe('OHIF Multi Study', () => {
|
||||||
const beforeSetup = () => {
|
const beforeSetup = () => {
|
||||||
cy.checkStudyRouteInViewer(
|
cy.initViewer(
|
||||||
'1.3.6.1.4.1.25403.345050719074.3824.20170125113417.1,1.2.840.113619.2.5.1762583153.215519.978957063.78',
|
'1.3.6.1.4.1.25403.345050719074.3824.20170125113417.1,1.2.840.113619.2.5.1762583153.215519.978957063.78',
|
||||||
'&hangingProtocolId=@ohif/hpCompare'
|
{
|
||||||
|
params: '&hangingProtocolId=@ohif/hpCompare',
|
||||||
|
minimumThumbnails: 3,
|
||||||
|
}
|
||||||
);
|
);
|
||||||
cy.expectMinimumThumbnails(4);
|
|
||||||
cy.initCornerstoneToolsAliases();
|
|
||||||
cy.initCommonElementsAliases();
|
|
||||||
cy.waitDicomImage();
|
|
||||||
};
|
};
|
||||||
|
|
||||||
it('Should display 2 comparison up', () => {
|
it('Should display 2 comparison up', () => {
|
||||||
|
|||||||
@ -131,6 +131,7 @@ const SegmentItem = ({
|
|||||||
{/* Icons that show only when hovering */}
|
{/* Icons that show only when hovering */}
|
||||||
<div className="hidden group-hover/row:flex">
|
<div className="hidden group-hover/row:flex">
|
||||||
<HoveringIcons
|
<HoveringIcons
|
||||||
|
disableEditing={disableEditing}
|
||||||
onEdit={onEdit}
|
onEdit={onEdit}
|
||||||
isLocked={isLocked}
|
isLocked={isLocked}
|
||||||
isVisible={isVisible}
|
isVisible={isVisible}
|
||||||
@ -147,6 +148,7 @@ const SegmentItem = ({
|
|||||||
};
|
};
|
||||||
|
|
||||||
const HoveringIcons = ({
|
const HoveringIcons = ({
|
||||||
|
disableEditing,
|
||||||
onEdit,
|
onEdit,
|
||||||
isLocked,
|
isLocked,
|
||||||
isVisible,
|
isVisible,
|
||||||
@ -172,7 +174,7 @@ const HoveringIcons = ({
|
|||||||
|
|
||||||
return (
|
return (
|
||||||
<div className="flex items-center">
|
<div className="flex items-center">
|
||||||
{createIcon('row-edit', onEdit)}
|
{!disableEditing && createIcon('row-edit', onEdit)}
|
||||||
{createIcon(
|
{createIcon(
|
||||||
isLocked ? 'row-lock' : 'row-unlock',
|
isLocked ? 'row-lock' : 'row-unlock',
|
||||||
onToggleLocked,
|
onToggleLocked,
|
||||||
|
|||||||
@ -104,18 +104,20 @@ const SegmentationGroupTable = ({
|
|||||||
</div>
|
</div>
|
||||||
) : (
|
) : (
|
||||||
<div className="mt-1 select-none">
|
<div className="mt-1 select-none">
|
||||||
<SegmentationDropDownRow
|
{!disableEditing && (
|
||||||
segmentations={segmentations}
|
<SegmentationDropDownRow
|
||||||
disableEditing={disableEditing}
|
segmentations={segmentations}
|
||||||
activeSegmentation={activeSegmentation}
|
disableEditing={disableEditing}
|
||||||
onActiveSegmentationChange={onActiveSegmentationChange}
|
activeSegmentation={activeSegmentation}
|
||||||
onSegmentationDelete={onSegmentationDelete}
|
onActiveSegmentationChange={onActiveSegmentationChange}
|
||||||
onSegmentationEdit={onSegmentationEdit}
|
onSegmentationDelete={onSegmentationDelete}
|
||||||
onSegmentationDownload={onSegmentationDownload}
|
onSegmentationEdit={onSegmentationEdit}
|
||||||
storeSegmentation={storeSegmentation}
|
onSegmentationDownload={onSegmentationDownload}
|
||||||
onSegmentationAdd={onSegmentationAdd}
|
storeSegmentation={storeSegmentation}
|
||||||
onToggleSegmentationVisibility={onToggleSegmentationVisibility}
|
onSegmentationAdd={onSegmentationAdd}
|
||||||
/>
|
onToggleSegmentationVisibility={onToggleSegmentationVisibility}
|
||||||
|
/>
|
||||||
|
)}
|
||||||
{!disableEditing && showAddSegment && (
|
{!disableEditing && showAddSegment && (
|
||||||
<AddSegmentRow onClick={() => onSegmentAdd(activeSegmentationId)} />
|
<AddSegmentRow onClick={() => onSegmentAdd(activeSegmentationId)} />
|
||||||
)}
|
)}
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user