Skip to content

Commit 159f868

Browse files
Allow to delete bbox even if there is no visible segmentation layer (#8164)
* allow to delete bbox even if there is no visible segmentation layer * add changelog
1 parent 97b2058 commit 159f868

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

CHANGELOG.unreleased.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,7 @@ For upgrade instructions, please check the [migration guide](MIGRATIONS.released
3737
- Fixed a bug where you could not create annotations for public datasets of other organizations. [#8107](https://github.com/scalableminds/webknossos/pull/8107)
3838
- Users without edit permissions to a dataset can no longer delete sharing tokens via the API. [#8083](https://github.com/scalableminds/webknossos/issues/8083)
3939
- Fixed downloading task annotations of teams you are not in, when accessing directly via URI. [#8155](https://github.com/scalableminds/webknossos/pull/8155)
40+
- Deleting a bounding box is now possible independently of a visible segmentation layer. [#8164](https://github.com/scalableminds/webknossos/pull/8164)
4041

4142
### Removed
4243

frontend/javascripts/oxalis/view/components/setting_input_views.tsx

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -554,7 +554,6 @@ class UserBoundingBoxInput extends React.PureComponent<UserBoundingBoxInputProps
554554
isLockedByOwner,
555555
isOwner,
556556
);
557-
const isDeleteEnabled = !disabled && this.props.visibleSegmentationLayer != null;
558557

559558
const getContextMenu = () => {
560559
const items: MenuProps["items"] = [
@@ -590,13 +589,13 @@ class UserBoundingBoxInput extends React.PureComponent<UserBoundingBoxInputProps
590589
},
591590
{
592591
key: "delete",
593-
label: isDeleteEnabled ? (
592+
label: !disabled ? (
594593
deleteButton
595594
) : (
596595
<FastTooltip title={editingDisallowedExplanation}>{deleteButton}</FastTooltip>
597596
),
598597
onClick: onDelete,
599-
disabled: !isDeleteEnabled,
598+
disabled,
600599
},
601600
];
602601

0 commit comments

Comments
 (0)