Skip to content

Commit a73a084

Browse files
committed
Move edit bounding box
1 parent 524f68b commit a73a084

File tree

2 files changed

+13
-12
lines changed

2 files changed

+13
-12
lines changed

web_ui/src/pages/annotator/tools/edit-tool/edit-bounding-box/edit-bounding-box.component.tsx renamed to web_ui/packages/smart-tools/src/edit-bounding-box/edit-bounding-box/edit-bounding-box.component.tsx

Lines changed: 5 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -3,20 +3,15 @@
33

44
import { useEffect, useState } from 'react';
55

6-
import { ANCHOR_SIZE, ResizeAnchor } from '@geti/smart-tools';
7-
import { RegionOfInterest } from '@geti/smart-tools/types';
8-
9-
import { Annotation } from '../../../../../core/annotations/annotation.interface';
10-
import { Point } from '../../../../../core/annotations/shapes.interface';
11-
import { ShapeType } from '../../../../../core/annotations/shapetype.enum';
12-
import { Labels } from '../../../annotation/labels/labels.component';
6+
import { Annotation, Point, RegionOfInterest } from '../../shared/interfaces';
7+
import { getBoundingBoxInRoi, getBoundingBoxResizePoints, getClampedBoundingBox } from '../../utils/tool-utils';
8+
import { ANCHOR_SIZE, ResizeAnchor } from '../resize-anchor.component';
139
import { TranslateShape } from '../translate-shape.component';
14-
import { getBoundingBoxInRoi, getBoundingBoxResizePoints, getClampedBoundingBox } from '../utils';
1510

16-
import classes from './../../../annotator-canvas.module.scss';
11+
import classes from './edit-bounding-box.module.scss';
1712

1813
interface EditBoundingBoxProps {
19-
annotation: Annotation & { shape: { shapeType: ShapeType.Rect } };
14+
annotation: Annotation & { shape: { shapeType: 'rect' } };
2015
disableTranslation?: boolean;
2116
disablePoints?: boolean;
2217
roi: RegionOfInterest;
@@ -73,8 +68,6 @@ export const EditBoundingBox = ({
7368
/>
7469
</svg>
7570

76-
<Labels annotation={{ ...annotation, shape }} />
77-
7871
{disablePoints === false ? (
7972
<svg
8073
width={image.width}
Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
.disabledLayer {
2+
position: absolute;
3+
top: 0;
4+
left: 0;
5+
bottom: 0;
6+
right: 0;
7+
pointer-events: none;
8+
}

0 commit comments

Comments
 (0)