@glodon-aiot/dataset-annotation 3.10.0-alpha.21 → 3.10.0-alpha.22
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/es/components/DetectionAnnotation/components/LabelMaker/Drawable.mjs +12 -12
- package/dist/es/components/DetectionAnnotation/components/LabelMaker/RectLabel.mjs +122 -97
- package/dist/es/components/DetectionAnnotation/components/LabelMaker/index.mjs +197 -162
- package/dist/es/components/VLMAnnotation/VLMLabelMaker/hooks/useCanvasDrag.mjs +75 -34
- package/dist/es/components/VLMAnnotation/VLMLabelMaker/hooks/useDrawingMode.mjs +159 -131
- package/dist/es/components/VLMAnnotation/VLMLabelMaker/hooks/useRegionSelection.mjs +59 -48
- package/dist/es/components/VLMAnnotation/VLMLabelMaker/index.mjs +158 -154
- package/dist/es/index.mjs +1 -1
- package/dist/lib/index.js +3 -3
- package/dist/src/components/VLMAnnotation/VLMLabelMaker/hooks/useCanvasDrag.d.ts +2 -1
- package/dist/src/components/VLMAnnotation/VLMLabelMaker/hooks/useDrawingMode.d.ts +2 -1
- package/package.json +2 -2
|
@@ -3,10 +3,11 @@ interface UseCanvasDragParams {
|
|
|
3
3
|
canvas: fabric.Canvas | undefined;
|
|
4
4
|
draggable: boolean;
|
|
5
5
|
drawingMode: boolean;
|
|
6
|
+
textLayersMapRef: React.MutableRefObject<Map<fabric.Rect, fabric.Rect[]>>;
|
|
6
7
|
}
|
|
7
8
|
/**
|
|
8
9
|
* Hook for managing canvas drag functionality
|
|
9
10
|
* @param params - Canvas drag configuration parameters
|
|
10
11
|
*/
|
|
11
|
-
export declare const useCanvasDrag: ({ canvas, draggable, drawingMode, }: UseCanvasDragParams) => void;
|
|
12
|
+
export declare const useCanvasDrag: ({ canvas, draggable, drawingMode, textLayersMapRef, }: UseCanvasDragParams) => void;
|
|
12
13
|
export {};
|
|
@@ -19,13 +19,14 @@ interface UseDrawingModeParams {
|
|
|
19
19
|
onRegionChange?: (region: Region | null, action: 'create' | 'update' | 'delete') => void;
|
|
20
20
|
onRegionSelect?: (region: Region | null) => void;
|
|
21
21
|
rectMapRef: React.MutableRefObject<Map<fabric.Rect, Region>>;
|
|
22
|
+
textLayersMapRef: React.MutableRefObject<Map<fabric.Rect, fabric.Rect[]>>;
|
|
22
23
|
}
|
|
23
24
|
/**
|
|
24
25
|
* Hook for managing drawing mode (rectangle drawing functionality)
|
|
25
26
|
* @param params - Drawing mode configuration parameters
|
|
26
27
|
* @returns stopDraw function to stop drawing
|
|
27
28
|
*/
|
|
28
|
-
export declare const useDrawingMode: ({ canvas, drawingMode, draggable, setDrawingMode, canvasToImageCoords, labelDefinitions, onChange, cropRegionImage, updateRegionShapeAndImage, performOCRIfNeeded, createDeleteControl, updateRegionNameText, onRegionChange, onRegionSelect, rectMapRef, }: UseDrawingModeParams) => {
|
|
29
|
+
export declare const useDrawingMode: ({ canvas, drawingMode, draggable, setDrawingMode, canvasToImageCoords, labelDefinitions, onChange, cropRegionImage, updateRegionShapeAndImage, performOCRIfNeeded, createDeleteControl, updateRegionNameText, onRegionChange, onRegionSelect, rectMapRef, textLayersMapRef, }: UseDrawingModeParams) => {
|
|
29
30
|
stopDraw: () => void;
|
|
30
31
|
};
|
|
31
32
|
export {};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@glodon-aiot/dataset-annotation",
|
|
3
|
-
"version": "3.10.0-alpha.
|
|
3
|
+
"version": "3.10.0-alpha.22",
|
|
4
4
|
"module": "./dist/es/index.mjs",
|
|
5
5
|
"main": "./dist/lib/index.js",
|
|
6
6
|
"types": "./dist/src/index.d.ts",
|
|
@@ -37,7 +37,7 @@
|
|
|
37
37
|
"dependencies": {
|
|
38
38
|
"@ant-design/icons": "^5.3.4",
|
|
39
39
|
"@aws-crypto/sha256-js": "^3.0.0",
|
|
40
|
-
"@glodon-aiot/apis": "^3.10.0-alpha.
|
|
40
|
+
"@glodon-aiot/apis": "^3.10.0-alpha.22",
|
|
41
41
|
"@glodon-aiot/minio": "^0.1.6",
|
|
42
42
|
"@reduxjs/toolkit": "^1.9.5",
|
|
43
43
|
"@types/fabric": "^5.3.2",
|