@labelbee/lb-components 1.5.0 → 1.6.0-alpha.2
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/assets/annotation/lineTool/icon_line.svg.js +1 -0
- package/dist/assets/annotation/pointCloudTool/changePointCloudValid.svg.js +1 -0
- package/dist/assets/annotation/pointCloudTool/copy.svg.js +1 -0
- package/dist/assets/annotation/pointCloudTool/nextBox.svg.js +1 -0
- package/dist/assets/annotation/pointCloudTool/patse.svg.js +1 -0
- package/dist/assets/annotation/pointCloudTool/prevBox.svg.js +1 -0
- package/dist/assets/annotation/pointCloudTool/rotate180_black.svg.js +1 -0
- package/dist/assets/annotation/pointCloudTool/selectAll.svg.js +1 -0
- package/dist/assets/annotation/pointCloudTool/selectMultiple.svg.js +1 -0
- package/dist/assets/annotation/pointTool/icon_point.svg.js +1 -0
- package/dist/assets/annotation/polygonTool/icon_polygon.svg.js +1 -0
- package/dist/assets/annotation/rectTool/icon_rect.svg.js +1 -0
- package/dist/assets/annotation/rectTool/{icon_rectPattern.svg.js → icon_rect_a.svg.js} +0 -0
- package/dist/assets/{cssIcon/annotation/icon_clearSmall.svg → icons/25541b4d.svg} +0 -0
- package/dist/assets/icons/25ef334b.svg +8 -0
- package/dist/assets/icons/7eadb9c4.svg +5 -0
- package/dist/assets/icons/9d70807.svg +5 -0
- package/dist/assets/icons/c5b4262e.png +0 -0
- package/dist/assets/{cssIcon/slide_btn.svg → icons/cc550fff.svg} +0 -0
- package/dist/assets/{cssIcon/annotation/icon_clearSmall_a.svg → icons/dc9b6bfc.svg} +0 -0
- package/dist/assets/icons/e4f0b7fe.png +0 -0
- package/dist/components/AnnotationView/index.js +1 -1
- package/dist/components/customResizeHook/index.js +1 -1
- package/dist/components/pointCloudView/PointCloud2DView.js +1 -0
- package/dist/components/pointCloudView/PointCloud3DView.js +1 -0
- package/dist/components/pointCloudView/PointCloudBackView.js +1 -0
- package/dist/components/pointCloudView/PointCloudContext.js +1 -0
- package/dist/components/pointCloudView/PointCloudInfos.js +1 -0
- package/dist/components/pointCloudView/PointCloudLayout.js +1 -0
- package/dist/components/pointCloudView/PointCloudListener.js +1 -0
- package/dist/components/pointCloudView/PointCloudSideView.js +1 -0
- package/dist/components/pointCloudView/PointCloudTopView.js +1 -0
- package/dist/components/pointCloudView/hooks/useBoxes.js +1 -0
- package/dist/components/pointCloudView/hooks/usePointCloudViews.js +1 -0
- package/dist/components/pointCloudView/hooks/usePolygon.js +1 -0
- package/dist/components/pointCloudView/hooks/useRotate.js +1 -0
- package/dist/components/pointCloudView/hooks/useSingleBox.js +1 -0
- package/dist/components/pointCloudView/hooks/useStatus.js +1 -0
- package/dist/components/pointCloudView/index.js +1 -0
- package/dist/components/videoPlayer/components/controller/index.js +1 -1
- package/dist/components/videoPlayer/index.js +1 -1
- package/dist/components/videoPlayer/utils.js +1 -1
- package/dist/data/enums/ToolType.js +1 -1
- package/dist/hooks/annotation.js +1 -0
- package/dist/index.css +273 -43
- package/dist/index.js +1 -1
- package/dist/store/annotation/actionCreators.js +1 -1
- package/dist/store/annotation/map.js +1 -0
- package/dist/store/annotation/reducer.js +1 -1
- package/dist/types/App.d.ts +4 -3
- package/dist/types/components/AnnotationView/index.d.ts +2 -2
- package/dist/types/components/pointCloudView/PointCloud2DView.d.ts +6 -0
- package/dist/types/components/pointCloudView/PointCloud3DView.d.ts +6 -0
- package/dist/types/components/pointCloudView/PointCloudBackView.d.ts +3 -0
- package/dist/types/components/pointCloudView/PointCloudContext.d.ts +31 -0
- package/dist/types/components/pointCloudView/PointCloudInfos.d.ts +19 -0
- package/dist/types/components/pointCloudView/PointCloudLayout.d.ts +6 -0
- package/dist/types/components/pointCloudView/PointCloudListener.d.ts +6 -0
- package/dist/types/components/pointCloudView/PointCloudSideView.d.ts +6 -0
- package/dist/types/components/pointCloudView/PointCloudTopView.d.ts +6 -0
- package/dist/types/components/pointCloudView/hooks/useBoxes.d.ts +10 -0
- package/dist/types/components/pointCloudView/hooks/usePointCloudViews.d.ts +59 -0
- package/dist/types/components/pointCloudView/hooks/usePolygon.d.ts +9 -0
- package/dist/types/components/pointCloudView/hooks/useRotate.d.ts +8 -0
- package/dist/types/components/pointCloudView/hooks/useSingleBox.d.ts +13 -0
- package/dist/types/components/pointCloudView/hooks/useStatus.d.ts +11 -0
- package/dist/types/components/pointCloudView/index.d.ts +15 -0
- package/dist/types/components/videoPlayer/TagToolInstanceAdaptor.d.ts +1 -1
- package/dist/types/components/videoPlayer/index.d.ts +1 -1
- package/dist/types/data/enums/ToolType.d.ts +3 -1
- package/dist/types/hooks/annotation.d.ts +24 -0
- package/dist/types/index.d.ts +1 -0
- package/dist/types/store/annotation/actionCreators.d.ts +4 -4
- package/dist/types/store/annotation/map.d.ts +13 -0
- package/dist/types/store/annotation/reducer.d.ts +1 -1
- package/dist/types/utils/PageOperator.d.ts +1 -1
- package/dist/types/utils/StepUtils.d.ts +7 -0
- package/dist/types/utils/ToolUtils.d.ts +10 -0
- package/dist/types/utils/data.d.ts +1 -1
- package/dist/types/utils/dom.d.ts +1 -1
- package/dist/types/utils/index.d.ts +1 -1
- package/dist/types/views/MainView/annotationOperation/index.d.ts +1 -1
- package/dist/types/views/MainView/sidebar/GeneralOperation/ActionsConfirm.d.ts +12 -0
- package/dist/types/views/MainView/sidebar/GeneralOperation/index.d.ts +5 -1
- package/dist/types/views/MainView/sidebar/GeneralOperation/useOperationList.d.ts +12 -0
- package/dist/types/views/MainView/sidebar/PointCloudToolSidebar/index.d.ts +11 -0
- package/dist/types/views/MainView/sidebar/ToolIcons.d.ts +11 -0
- package/dist/types/views/MainView/sidebar/ToolStyle/index.d.ts +1 -1
- package/dist/types/views/MainView/sidebar/index.d.ts +1 -0
- package/dist/types/views/MainView/toolFooter/FooterTips/ToolHotKey/pointCloud/index.d.ts +3 -0
- package/dist/types/views/MainView/toolFooter/Pagination.d.ts +12 -2
- package/dist/types/views/MainView/toolFooter/ZoomController/index.d.ts +14 -4
- package/dist/types/views/MainView/toolFooter/index.d.ts +5 -8
- package/dist/types/views/MainView/toolHeader/ExportData/index.d.ts +1 -1
- package/dist/utils/StepUtils.js +1 -1
- package/dist/utils/ToolUtils.js +1 -0
- package/dist/utils/data.js +1 -1
- package/dist/utils/dom.js +1 -1
- package/dist/utils/index.js +1 -1
- package/dist/views/MainView/annotationOperation/index.js +1 -1
- package/dist/views/MainView/index.js +1 -1
- package/dist/views/MainView/sidebar/GeneralOperation/ActionsConfirm.js +1 -0
- package/dist/views/MainView/sidebar/GeneralOperation/index.js +1 -1
- package/dist/views/MainView/sidebar/GeneralOperation/useOperationList.js +1 -0
- package/dist/views/MainView/sidebar/PointCloudToolSidebar/index.js +1 -0
- package/dist/views/MainView/sidebar/SwitchAttributeList/index.js +1 -1
- package/dist/views/MainView/sidebar/ToolIcons.js +1 -0
- package/dist/views/MainView/sidebar/index.js +1 -1
- package/dist/views/MainView/toolFooter/FooterTips/ToolHotKey/index.js +1 -1
- package/dist/views/MainView/toolFooter/FooterTips/ToolHotKey/pointCloud/index.js +1 -0
- package/dist/views/MainView/toolFooter/Pagination.js +1 -1
- package/dist/views/MainView/toolFooter/ZoomController/ZoomLevel/index.js +1 -1
- package/dist/views/MainView/toolFooter/ZoomController/index.js +1 -1
- package/dist/views/MainView/toolFooter/index.js +1 -1
- package/es/App.js.map +1 -1
- package/es/assets/annotation/lineTool/icon_line.svg.js +1 -0
- package/es/assets/annotation/lineTool/icon_line.svg.js.map +1 -0
- package/es/assets/annotation/pointCloudTool/changePointCloudValid.svg.js +1 -0
- package/es/assets/annotation/pointCloudTool/changePointCloudValid.svg.js.map +1 -0
- package/es/assets/annotation/pointCloudTool/copy.svg.js +1 -0
- package/es/assets/annotation/pointCloudTool/copy.svg.js.map +1 -0
- package/es/assets/annotation/pointCloudTool/nextBox.svg.js +1 -0
- package/es/assets/annotation/pointCloudTool/nextBox.svg.js.map +1 -0
- package/es/assets/annotation/pointCloudTool/patse.svg.js +1 -0
- package/es/assets/annotation/pointCloudTool/patse.svg.js.map +1 -0
- package/es/assets/annotation/pointCloudTool/prevBox.svg.js +1 -0
- package/es/assets/annotation/pointCloudTool/prevBox.svg.js.map +1 -0
- package/es/assets/annotation/pointCloudTool/rotate180_black.svg.js +1 -0
- package/es/assets/annotation/pointCloudTool/rotate180_black.svg.js.map +1 -0
- package/es/assets/annotation/pointCloudTool/selectAll.svg.js +1 -0
- package/es/assets/annotation/pointCloudTool/selectAll.svg.js.map +1 -0
- package/es/assets/annotation/pointCloudTool/selectMultiple.svg.js +1 -0
- package/es/assets/annotation/pointCloudTool/selectMultiple.svg.js.map +1 -0
- package/es/assets/annotation/pointTool/icon_point.svg.js +1 -0
- package/es/assets/annotation/pointTool/icon_point.svg.js.map +1 -0
- package/es/assets/annotation/polygonTool/icon_polygon.svg.js +1 -0
- package/es/assets/annotation/polygonTool/icon_polygon.svg.js.map +1 -0
- package/es/assets/annotation/rectTool/icon_rect.svg.js +1 -0
- package/es/assets/annotation/rectTool/icon_rect.svg.js.map +1 -0
- package/es/assets/annotation/rectTool/icon_rectPattern.svg.js +4 -1
- package/es/assets/annotation/rectTool/icon_rect_a.svg.js +1 -0
- package/es/assets/annotation/rectTool/icon_rect_a.svg.js.map +1 -0
- package/es/components/AnnotationView/index.js +1 -1
- package/es/components/AnnotationView/index.js.map +1 -1
- package/es/components/customResizeHook/index.js +1 -1
- package/es/components/customResizeHook/index.js.map +1 -1
- package/es/components/pointCloudView/PointCloud2DView.js +1 -0
- package/es/components/pointCloudView/PointCloud2DView.js.map +1 -0
- package/es/components/pointCloudView/PointCloud3DView.js +1 -0
- package/es/components/pointCloudView/PointCloud3DView.js.map +1 -0
- package/es/components/pointCloudView/PointCloudBackView.js +1 -0
- package/es/components/pointCloudView/PointCloudBackView.js.map +1 -0
- package/es/components/pointCloudView/PointCloudContext.js +1 -0
- package/es/components/pointCloudView/PointCloudContext.js.map +1 -0
- package/es/components/pointCloudView/PointCloudInfos.js +1 -0
- package/es/components/pointCloudView/PointCloudInfos.js.map +1 -0
- package/es/components/pointCloudView/PointCloudLayout.js +1 -0
- package/es/components/pointCloudView/PointCloudLayout.js.map +1 -0
- package/es/components/pointCloudView/PointCloudListener.js +1 -0
- package/es/components/pointCloudView/PointCloudListener.js.map +1 -0
- package/es/components/pointCloudView/PointCloudSideView.js +1 -0
- package/es/components/pointCloudView/PointCloudSideView.js.map +1 -0
- package/es/components/pointCloudView/PointCloudTopView.js +1 -0
- package/es/components/pointCloudView/PointCloudTopView.js.map +1 -0
- package/es/components/pointCloudView/data.js +4 -0
- package/es/components/pointCloudView/data.js.map +1 -0
- package/es/components/pointCloudView/hooks/useBoxes.js +1 -0
- package/es/components/pointCloudView/hooks/useBoxes.js.map +1 -0
- package/es/components/pointCloudView/hooks/usePointCloudViews.js +1 -0
- package/es/components/pointCloudView/hooks/usePointCloudViews.js.map +1 -0
- package/es/components/pointCloudView/hooks/usePolygon.js +1 -0
- package/es/components/pointCloudView/hooks/usePolygon.js.map +1 -0
- package/es/components/pointCloudView/hooks/useRotate.js +1 -0
- package/es/components/pointCloudView/hooks/useRotate.js.map +1 -0
- package/es/components/pointCloudView/hooks/useSingleBox.js +1 -0
- package/es/components/pointCloudView/hooks/useSingleBox.js.map +1 -0
- package/es/components/pointCloudView/hooks/useStatus.js +1 -0
- package/es/components/pointCloudView/hooks/useStatus.js.map +1 -0
- package/es/components/pointCloudView/index.js +1 -0
- package/es/components/pointCloudView/index.js.map +1 -0
- package/es/components/videoPlayer/components/controller/index.js +1 -1
- package/es/components/videoPlayer/components/controller/index.js.map +1 -1
- package/es/components/videoPlayer/index.js +1 -1
- package/es/components/videoPlayer/index.js.map +1 -1
- package/es/components/videoPlayer/utils.js +1 -1
- package/es/components/videoPlayer/utils.js.map +1 -1
- package/es/data/enums/ToolType.js +1 -1
- package/es/data/enums/ToolType.js.map +1 -1
- package/es/hooks/annotation.js +1 -0
- package/es/hooks/annotation.js.map +1 -0
- package/es/hooks/useSize.js.map +1 -1
- package/es/index.css +1364 -0
- package/es/index.js +1 -1
- package/es/index.js.map +1 -1
- package/es/store/annotation/actionCreators.js +1 -1
- package/es/store/annotation/actionCreators.js.map +1 -1
- package/es/store/annotation/map.js +1 -0
- package/es/store/annotation/map.js.map +1 -0
- package/es/store/annotation/reducer.js +1 -1
- package/es/store/annotation/reducer.js.map +1 -1
- package/es/utils/StepUtils.js +1 -1
- package/es/utils/StepUtils.js.map +1 -1
- package/es/utils/ToolUtils.js +1 -0
- package/es/utils/ToolUtils.js.map +1 -0
- package/es/utils/data.js +1 -1
- package/es/utils/data.js.map +1 -1
- package/es/utils/dom.js +1 -1
- package/es/utils/dom.js.map +1 -1
- package/es/utils/index.js +1 -1
- package/es/utils/index.js.map +1 -1
- package/es/views/MainView/annotationOperation/index.js +1 -1
- package/es/views/MainView/annotationOperation/index.js.map +1 -1
- package/es/views/MainView/index.js +1 -1
- package/es/views/MainView/index.js.map +1 -1
- package/es/views/MainView/sidebar/GeneralOperation/ActionsConfirm.js +1 -0
- package/es/views/MainView/sidebar/GeneralOperation/ActionsConfirm.js.map +1 -0
- package/es/views/MainView/sidebar/GeneralOperation/index.js +1 -1
- package/es/views/MainView/sidebar/GeneralOperation/index.js.map +1 -1
- package/es/views/MainView/sidebar/GeneralOperation/useOperationList.js +1 -0
- package/es/views/MainView/sidebar/GeneralOperation/useOperationList.js.map +1 -0
- package/es/views/MainView/sidebar/PointCloudToolSidebar/index.js +1 -0
- package/es/views/MainView/sidebar/PointCloudToolSidebar/index.js.map +1 -0
- package/es/views/MainView/sidebar/SwitchAttributeList/index.js +1 -1
- package/es/views/MainView/sidebar/SwitchAttributeList/index.js.map +1 -1
- package/es/views/MainView/sidebar/ToolIcons.js +1 -0
- package/es/views/MainView/sidebar/ToolIcons.js.map +1 -0
- package/es/views/MainView/sidebar/index.js +1 -1
- package/es/views/MainView/sidebar/index.js.map +1 -1
- package/es/views/MainView/toolFooter/FooterTips/ToolHotKey/index.js +1 -1
- package/es/views/MainView/toolFooter/FooterTips/ToolHotKey/index.js.map +1 -1
- package/es/views/MainView/toolFooter/FooterTips/ToolHotKey/pointCloud/index.js +1 -0
- package/es/views/MainView/toolFooter/FooterTips/ToolHotKey/pointCloud/index.js.map +1 -0
- package/es/views/MainView/toolFooter/Pagination.js +1 -1
- package/es/views/MainView/toolFooter/Pagination.js.map +1 -1
- package/es/views/MainView/toolFooter/ZoomController/ZoomLevel/index.js +1 -1
- package/es/views/MainView/toolFooter/ZoomController/ZoomLevel/index.js.map +1 -1
- package/es/views/MainView/toolFooter/ZoomController/index.js +1 -1
- package/es/views/MainView/toolFooter/ZoomController/index.js.map +1 -1
- package/es/views/MainView/toolFooter/index.js +1 -1
- package/es/views/MainView/toolFooter/index.js.map +1 -1
- package/package.json +14 -13
- package/dist/index.css.map +0 -1
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { IAnnotationStateProps } from '@/store/annotation/map';
|
|
3
|
+
declare const _default: import("react-redux").ConnectedComponent<React.FC<IAnnotationStateProps>, import("react-redux").Omit<IAnnotationStateProps & {
|
|
4
|
+
children?: React.ReactNode;
|
|
5
|
+
}, "currentData">>;
|
|
6
|
+
export default _default;
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
import { IAnnotationStateProps } from '@/store/annotation/map';
|
|
2
|
+
declare const _default: import("react-redux").ConnectedComponent<({ currentData }: IAnnotationStateProps) => JSX.Element, import("react-redux").Omit<IAnnotationStateProps, "currentData">>;
|
|
3
|
+
export default _default;
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import { IPointCloudBox, IPointCloudBoxList, IPolygonData } from '@labelbee/lb-utils';
|
|
2
|
+
import { PointCloud, PointCloudAnnotation } from '@labelbee/lb-annotation';
|
|
3
|
+
import React from 'react';
|
|
4
|
+
interface IPointCloudContextInstances {
|
|
5
|
+
topViewInstance?: PointCloudAnnotation;
|
|
6
|
+
sideViewInstance?: PointCloudAnnotation;
|
|
7
|
+
backViewInstance?: PointCloudAnnotation;
|
|
8
|
+
mainViewInstance?: PointCloud;
|
|
9
|
+
setTopViewInstance: (instance: PointCloudAnnotation) => void;
|
|
10
|
+
setSideViewInstance: (instance: PointCloudAnnotation) => void;
|
|
11
|
+
setBackViewInstance: (instance: PointCloudAnnotation) => void;
|
|
12
|
+
setMainViewInstance: (instance: PointCloud) => void;
|
|
13
|
+
}
|
|
14
|
+
export interface IPointCloudContext extends IPointCloudContextInstances {
|
|
15
|
+
pointCloudBoxList: IPointCloudBoxList;
|
|
16
|
+
selectedIDs: string[];
|
|
17
|
+
setSelectedIDs: (ids?: string[] | string) => void;
|
|
18
|
+
valid: boolean;
|
|
19
|
+
setPointCloudResult: (resultList: IPointCloudBoxList) => void;
|
|
20
|
+
selectedPointCloudBox?: IPointCloudBox;
|
|
21
|
+
setPointCloudValid: (valid?: boolean) => void;
|
|
22
|
+
addSelectedID: (selectedID: string) => void;
|
|
23
|
+
selectedAllBoxes: () => void;
|
|
24
|
+
selectedID: string;
|
|
25
|
+
addPointCloudBox: (boxParams: IPointCloudBox) => void;
|
|
26
|
+
polygonList: IPolygonData[];
|
|
27
|
+
setPolygonList: (polygonList: IPolygonData[]) => void;
|
|
28
|
+
}
|
|
29
|
+
export declare const PointCloudContext: React.Context<IPointCloudContext>;
|
|
30
|
+
export declare const PointCloudProvider: React.FC<{}>;
|
|
31
|
+
export {};
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @author Glenfiddish <edwinlee0927@hotmail.com>
|
|
3
|
+
* @file Display selected box's infos
|
|
4
|
+
* @createdate 2022-07-13
|
|
5
|
+
*/
|
|
6
|
+
import { EPerspectiveView } from '@labelbee/lb-utils';
|
|
7
|
+
/**
|
|
8
|
+
* Display size info for views
|
|
9
|
+
* @param param0
|
|
10
|
+
* @returns
|
|
11
|
+
*/
|
|
12
|
+
export declare const SizeInfoForView: ({ perspectiveView }: {
|
|
13
|
+
perspectiveView: EPerspectiveView;
|
|
14
|
+
}) => JSX.Element | null;
|
|
15
|
+
/**
|
|
16
|
+
* Display selected box's infos
|
|
17
|
+
*/
|
|
18
|
+
export declare const BoxInfos: () => JSX.Element | null;
|
|
19
|
+
export declare const PointCloudValidity: () => JSX.Element | null;
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { IAnnotationStateProps } from '@/store/annotation/map';
|
|
3
|
+
declare const _default: import("react-redux").ConnectedComponent<React.FC<IAnnotationStateProps>, import("react-redux").Omit<IAnnotationStateProps & {
|
|
4
|
+
children?: React.ReactNode;
|
|
5
|
+
}, "currentData">>;
|
|
6
|
+
export default _default;
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { IAnnotationStateProps } from '@/store/annotation/map';
|
|
3
|
+
declare const _default: import("react-redux").ConnectedComponent<React.FC<IAnnotationStateProps>, import("react-redux").Omit<IAnnotationStateProps & {
|
|
4
|
+
children?: React.ReactNode;
|
|
5
|
+
}, "currentData">>;
|
|
6
|
+
export default _default;
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { IAnnotationStateProps } from '@/store/annotation/map';
|
|
3
|
+
declare const _default: import("react-redux").ConnectedComponent<React.FC<IAnnotationStateProps>, import("react-redux").Omit<IAnnotationStateProps & {
|
|
4
|
+
children?: React.ReactNode;
|
|
5
|
+
}, "currentData">>;
|
|
6
|
+
export default _default;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { IPointCloudBoxList } from '@labelbee/lb-utils';
|
|
2
|
+
/**
|
|
3
|
+
* Actions for selected boxes
|
|
4
|
+
*/
|
|
5
|
+
export declare const useBoxes: () => {
|
|
6
|
+
copySelectedBoxes: () => void;
|
|
7
|
+
pasteSelectedBoxes: () => void;
|
|
8
|
+
copiedBoxes: IPointCloudBoxList;
|
|
9
|
+
selectedBoxes: import("@labelbee/lb-utils").IPointCloudBox[];
|
|
10
|
+
};
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @file Point cloud interface for crud
|
|
3
|
+
* @author Glenfiddish <edwinlee0927@hotmail.com>
|
|
4
|
+
* @createdate 2022-08-17
|
|
5
|
+
*/
|
|
6
|
+
import { PointCloudAnnotation, PointCloud } from '@labelbee/lb-annotation';
|
|
7
|
+
import { IPointCloudBox } from '@labelbee/lb-utils';
|
|
8
|
+
import { ISize } from '@/types/main';
|
|
9
|
+
/**
|
|
10
|
+
* Get the coordinate from canvas2d-coordinate to world coordinate
|
|
11
|
+
*/
|
|
12
|
+
export declare const transferCanvas2World: (currentPos: {
|
|
13
|
+
x: number;
|
|
14
|
+
y: number;
|
|
15
|
+
}, size: {
|
|
16
|
+
width: number;
|
|
17
|
+
height: number;
|
|
18
|
+
}) => {
|
|
19
|
+
x: number;
|
|
20
|
+
y: number;
|
|
21
|
+
};
|
|
22
|
+
export declare const topViewPolygon2PointCloud: (newPolygon: any, size: ISize, pointCloud?: PointCloud | undefined, selectedPointCloud?: IPointCloudBox | undefined, defaultValue?: {
|
|
23
|
+
[v: string]: any;
|
|
24
|
+
} | undefined) => Omit<IPointCloudBox, "trackID">;
|
|
25
|
+
/**
|
|
26
|
+
* NewBox synchronize sideView
|
|
27
|
+
* @param boxParams
|
|
28
|
+
* @param newPolygon TODO! Need to add type
|
|
29
|
+
*/
|
|
30
|
+
export declare const synchronizeSideView: (boxParams: IPointCloudBox, newPolygon: any, sideViewInstance: PointCloudAnnotation | undefined, url: string) => void;
|
|
31
|
+
/**
|
|
32
|
+
* NewBox synchronize backView
|
|
33
|
+
* @param boxParams
|
|
34
|
+
* @param newPolygon TODO! Need to add type
|
|
35
|
+
*/
|
|
36
|
+
export declare const synchronizeBackView: (boxParams: IPointCloudBox, newPolygon: any, BackViewInstance: PointCloudAnnotation, url: string) => void;
|
|
37
|
+
/**
|
|
38
|
+
* NewBox synchronize TopView
|
|
39
|
+
* @param boxParams
|
|
40
|
+
* @param newPolygon TODO! Need to add type
|
|
41
|
+
*/
|
|
42
|
+
export declare const synchronizeTopView: (newBoxParams: IPointCloudBox, newPolygon: any, topViewInstance?: PointCloudAnnotation | undefined, mainViewInstance?: PointCloud | undefined) => void;
|
|
43
|
+
export declare const usePointCloudViews: () => {
|
|
44
|
+
topViewAddBox: () => void;
|
|
45
|
+
topViewSelectedChanged: () => void;
|
|
46
|
+
sideViewUpdateBox: () => void;
|
|
47
|
+
topViewUpdateBox?: undefined;
|
|
48
|
+
backViewUpdateBox?: undefined;
|
|
49
|
+
pointCloudBoxListUpdated?: undefined;
|
|
50
|
+
clearAllResult?: undefined;
|
|
51
|
+
} | {
|
|
52
|
+
topViewAddBox: (newPolygon: any, size: ISize) => void;
|
|
53
|
+
topViewSelectedChanged: () => void;
|
|
54
|
+
topViewUpdateBox: (polygon: any, size: ISize) => void;
|
|
55
|
+
sideViewUpdateBox: (newPolygon: any, originPolygon: any) => void;
|
|
56
|
+
backViewUpdateBox: (newPolygon: any, originPolygon: any) => void;
|
|
57
|
+
pointCloudBoxListUpdated: (newBoxes: IPointCloudBox[]) => void;
|
|
58
|
+
clearAllResult: () => void;
|
|
59
|
+
};
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { IPointCloudBox } from '@labelbee/lb-utils';
|
|
2
|
+
/** Actions for single selected box */
|
|
3
|
+
export declare const useSingleBox: () => {
|
|
4
|
+
selectedBox: {
|
|
5
|
+
info: IPointCloudBox;
|
|
6
|
+
index: number;
|
|
7
|
+
} | undefined;
|
|
8
|
+
updateSelectedBox: (params: Partial<IPointCloudBox>) => void;
|
|
9
|
+
changeSelectedBoxValid: () => void;
|
|
10
|
+
selectNextBox: (sort?: any) => void;
|
|
11
|
+
selectPrevBox: () => void;
|
|
12
|
+
deletePointCloudBox: (id: string) => void;
|
|
13
|
+
};
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @file Update PointCloud Status
|
|
3
|
+
* @createDate 2022-08-26
|
|
4
|
+
* @author Ron <ron.f.luo@gmail.com>
|
|
5
|
+
*/
|
|
6
|
+
import { cTool } from '@labelbee/lb-annotation';
|
|
7
|
+
export declare const useStatus: () => {
|
|
8
|
+
clearAllResult: () => void;
|
|
9
|
+
updatePointCloudPattern: (toolName: any) => void;
|
|
10
|
+
pointCloudPattern: cTool.EToolName;
|
|
11
|
+
};
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @author Glenfiddish <edwinlee0927@hotmail.com>
|
|
3
|
+
* @file Point cloud tool view
|
|
4
|
+
* Includes 2D-view、3Dview、top-view、side-view、back-view
|
|
5
|
+
* @date 2022-06-21
|
|
6
|
+
*/
|
|
7
|
+
import React from 'react';
|
|
8
|
+
import { IFileItem } from '@/types/data';
|
|
9
|
+
interface IProps {
|
|
10
|
+
imgList: IFileItem[];
|
|
11
|
+
}
|
|
12
|
+
declare const _default: import("react-redux").ConnectedComponent<React.FC<IProps>, import("react-redux").Omit<IProps & {
|
|
13
|
+
children?: React.ReactNode;
|
|
14
|
+
}, "imgList">>;
|
|
15
|
+
export default _default;
|
|
@@ -40,7 +40,7 @@ export declare class TagToolInstanceAdaptor extends React.Component<IVideoTagIns
|
|
|
40
40
|
};
|
|
41
41
|
get currentTagResult(): any;
|
|
42
42
|
get valid(): boolean;
|
|
43
|
-
clearResult: (sendMsg?: boolean, value?: string) => void;
|
|
43
|
+
clearResult: (sendMsg?: boolean, value?: string | undefined) => void;
|
|
44
44
|
exportData: () => (any[] | {
|
|
45
45
|
valid: boolean;
|
|
46
46
|
duration: number;
|
|
@@ -9,7 +9,7 @@ export declare const VideoPlayerCtx: React.Context<{
|
|
|
9
9
|
videoRef?: React.RefObject<HTMLVideoElement> | null | undefined;
|
|
10
10
|
isPlay: boolean;
|
|
11
11
|
playPause: () => void;
|
|
12
|
-
updateNextPlaybackRate: (isForward?: boolean) => void;
|
|
12
|
+
updateNextPlaybackRate: (isForward?: boolean | undefined) => void;
|
|
13
13
|
setCurrentTime: (time: number) => void;
|
|
14
14
|
playbackRate: number;
|
|
15
15
|
currentTime: number;
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
export interface ICustomToolInstance {
|
|
3
|
+
exportData: () => [any[], {}];
|
|
4
|
+
exportCustomData: () => {};
|
|
5
|
+
singleOn: () => void;
|
|
6
|
+
clearResult: () => void;
|
|
7
|
+
on: () => void;
|
|
8
|
+
setResult: () => void;
|
|
9
|
+
setValid: (valid: boolean) => void;
|
|
10
|
+
history: {
|
|
11
|
+
initRecord: () => void;
|
|
12
|
+
pushHistory: () => void;
|
|
13
|
+
};
|
|
14
|
+
setDefaultAttribute: (attribute: string) => void;
|
|
15
|
+
setSubAttribute: (key: string, value: string) => void;
|
|
16
|
+
}
|
|
17
|
+
/**
|
|
18
|
+
* Custom an empty toolInstance to adapt old use.
|
|
19
|
+
* @returns
|
|
20
|
+
*/
|
|
21
|
+
declare const useCustomToolInstance: () => {
|
|
22
|
+
toolInstanceRef: import("react").MutableRefObject<ICustomToolInstance>;
|
|
23
|
+
};
|
|
24
|
+
export { useCustomToolInstance };
|
package/dist/types/index.d.ts
CHANGED
|
@@ -3,6 +3,7 @@ import AnnotationView from '@/components/AnnotationView';
|
|
|
3
3
|
import { i18n } from '@labelbee/lb-utils';
|
|
4
4
|
import React from 'react';
|
|
5
5
|
import { VideoTagTool } from '@/components/videoPlayer/TagToolInstanceAdaptorI18nProvider';
|
|
6
|
+
import './index.scss';
|
|
6
7
|
export declare const store: import("redux").Store<{}, import("redux").Action<any>> & {
|
|
7
8
|
dispatch: unknown;
|
|
8
9
|
};
|
|
@@ -25,12 +25,12 @@ export declare function CopyBackWordResult(): AnnotationActionTypes;
|
|
|
25
25
|
*/
|
|
26
26
|
export declare function InitTaskData({ onSubmit, onSave, onPageChange, onStepChange, getFileData, pageSize, loadFileList, step, stepList, }: any): any;
|
|
27
27
|
/** 切换到下一步 */
|
|
28
|
-
export declare const ToNextStep: (pageNumber?: number) => (dispatch: any, getState: any) => any[];
|
|
28
|
+
export declare const ToNextStep: (pageNumber?: number | undefined) => (dispatch: any, getState: any) => any[];
|
|
29
29
|
/**
|
|
30
30
|
* 更新当前操作的步骤
|
|
31
31
|
* @param {number} toStep
|
|
32
32
|
*/
|
|
33
|
-
export declare const UpdateProcessingStep: (toStep: number, index?: number) => (dispatch: any, getState: any) => any[];
|
|
33
|
+
export declare const UpdateProcessingStep: (toStep: number, index?: number | undefined) => (dispatch: any, getState: any) => any[];
|
|
34
34
|
/**
|
|
35
35
|
* 提交当前的文件数据
|
|
36
36
|
* @param submitType
|
|
@@ -52,7 +52,7 @@ export declare const PageJump: (toIndex: number, triggerEventAfterIndexChanged?:
|
|
|
52
52
|
* @param nextIndex 需要加载的图片index
|
|
53
53
|
* @param isInitial // 是否为初始化加载
|
|
54
54
|
*/
|
|
55
|
-
export declare const loadImgList: (dispatch: any, getState: any, nextIndex: number, isInitial?: boolean) => Promise<true | undefined>;
|
|
55
|
+
export declare const loadImgList: (dispatch: any, getState: any, nextIndex: number, isInitial?: boolean | undefined) => Promise<true | undefined>;
|
|
56
56
|
/**
|
|
57
57
|
* 判断翻页还是切换依赖数据
|
|
58
58
|
* @param dispatch
|
|
@@ -60,7 +60,7 @@ export declare const loadImgList: (dispatch: any, getState: any, nextIndex: numb
|
|
|
60
60
|
* @param pageTurningOperation
|
|
61
61
|
* @param toIndex
|
|
62
62
|
*/
|
|
63
|
-
export declare const DispatcherTurning: (dispatch: any, getState: any, pageTurningOperation: EPageTurningOperation, triggerEventAfterIndexChanged?: boolean, toIndex?: number) => Promise<any>;
|
|
63
|
+
export declare const DispatcherTurning: (dispatch: any, getState: any, pageTurningOperation: EPageTurningOperation, triggerEventAfterIndexChanged?: boolean, toIndex?: number | undefined) => Promise<any>;
|
|
64
64
|
/**
|
|
65
65
|
* 保存当前页数据
|
|
66
66
|
* */
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @file MapStateToProps set
|
|
3
|
+
* @createdate 2022-07-19
|
|
4
|
+
* @author Ron <ron.f.luo@gmail.com>
|
|
5
|
+
*/
|
|
6
|
+
import { AppState } from '../index';
|
|
7
|
+
import { IFileItem } from '@/types/data';
|
|
8
|
+
export declare const aMapStateToProps: (state: AppState) => {
|
|
9
|
+
currentData: any;
|
|
10
|
+
};
|
|
11
|
+
export interface IAnnotationStateProps {
|
|
12
|
+
currentData: IFileItem;
|
|
13
|
+
}
|
|
@@ -10,5 +10,5 @@ export declare const getTotalPage: (state: AnnotationState) => number;
|
|
|
10
10
|
* @param nextIndex
|
|
11
11
|
* @param nextBasicIndex
|
|
12
12
|
*/
|
|
13
|
-
export declare const LoadFileAndFileData: (nextIndex: number, nextBasicIndex?: number) => any;
|
|
13
|
+
export declare const LoadFileAndFileData: (nextIndex: number, nextBasicIndex?: number | undefined) => any;
|
|
14
14
|
export declare const annotationReducer: (state: AnnotationState | undefined, action: AnnotationActionTypes) => AnnotationState;
|
|
@@ -43,6 +43,6 @@ declare class PageOperator {
|
|
|
43
43
|
* @param pageTurningOperation
|
|
44
44
|
* @param fileIndex
|
|
45
45
|
*/
|
|
46
|
-
static getNextFileIndex: (pageTurningOperation: EPageTurningOperation, pageInfo: IPageInfo, fileIndex?: number) => number;
|
|
46
|
+
static getNextFileIndex: (pageTurningOperation: EPageTurningOperation, pageInfo: IPageInfo, fileIndex?: number | undefined) => number;
|
|
47
47
|
}
|
|
48
48
|
export default PageOperator;
|
|
@@ -22,4 +22,11 @@ export default class StepUtils {
|
|
|
22
22
|
* @returns {Number} 是否为视频工具
|
|
23
23
|
*/
|
|
24
24
|
static currentToolIsVideo(step: number, stepList: IStepInfo[]): boolean;
|
|
25
|
+
/**
|
|
26
|
+
* Check for PointCloud
|
|
27
|
+
* @param step
|
|
28
|
+
* @param stepList
|
|
29
|
+
* @returns
|
|
30
|
+
*/
|
|
31
|
+
static currentToolIsPointCloud(step: number, stepList: IStepInfo[]): boolean;
|
|
25
32
|
}
|
|
@@ -7,5 +7,5 @@ export declare function getTargetElement(target?: BasicTarget<TargetElement>, de
|
|
|
7
7
|
* @param elm
|
|
8
8
|
* @param modify
|
|
9
9
|
*/
|
|
10
|
-
export declare const getClassName: (
|
|
10
|
+
export declare const getClassName: (block: string, elm?: string | undefined, modify?: string | undefined) => string;
|
|
11
11
|
export {};
|
|
@@ -2,4 +2,4 @@ export declare const jsonParser: (content: any, defaultValue?: any) => any;
|
|
|
2
2
|
export declare const getNewNode: <T>(newNode: T, oldNode: T) => T;
|
|
3
3
|
export declare const classnames: (className: {
|
|
4
4
|
[key: string]: boolean;
|
|
5
|
-
} | string[]) => string;
|
|
5
|
+
} | (string | undefined)[]) => string;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { AppState } from 'src/store';
|
|
3
3
|
import { ImgAttributeState } from 'src/store/imgAttribute/types';
|
|
4
|
-
import { AnnotationEngine } from '@labelbee/lb-annotation';
|
|
5
4
|
import { AppProps } from '@/App';
|
|
5
|
+
import { AnnotationEngine } from '@labelbee/lb-annotation';
|
|
6
6
|
interface IProps extends AppState, AppProps {
|
|
7
7
|
imgAttribute: ImgAttributeState;
|
|
8
8
|
imgIndex: number;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
export interface IOperationConfig {
|
|
3
|
+
name: string;
|
|
4
|
+
key: string;
|
|
5
|
+
imgSvg: string | React.ReactElement;
|
|
6
|
+
hoverSvg: string | React.ReactElement;
|
|
7
|
+
onClick: () => void;
|
|
8
|
+
}
|
|
9
|
+
declare const ActionsConfirm: React.FC<{
|
|
10
|
+
allOperation: IOperationConfig[];
|
|
11
|
+
}>;
|
|
12
|
+
export default ActionsConfirm;
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
+
import { ConnectedComponent } from 'react-redux';
|
|
2
3
|
import { ToolInstance } from '@/store/annotation/types';
|
|
3
4
|
import { IStepInfo } from '@/types/step';
|
|
4
5
|
import { AnnotationFileList } from '@/types/data';
|
|
@@ -8,7 +9,10 @@ interface IProps {
|
|
|
8
9
|
imgList: AnnotationFileList;
|
|
9
10
|
imgIndex: number;
|
|
10
11
|
}
|
|
11
|
-
declare const
|
|
12
|
+
export declare const PointCloudOperation: ConnectedComponent<React.FC<IProps>, Omit<IProps & {
|
|
13
|
+
children?: React.ReactNode;
|
|
14
|
+
}, 'toolInstance' | 'stepInfo' | 'imgList' | 'imgIndex'>>;
|
|
15
|
+
declare const _default: ConnectedComponent<React.FC<IProps>, import("react-redux").Omit<IProps & {
|
|
12
16
|
children?: React.ReactNode;
|
|
13
17
|
}, "imgIndex" | "imgList" | "toolInstance" | "stepInfo">>;
|
|
14
18
|
export default _default;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { IOperationConfig } from './ActionsConfirm';
|
|
2
|
+
/**
|
|
3
|
+
* Hooks for sidebar common operations' config
|
|
4
|
+
* @param toolInstance
|
|
5
|
+
* @returns
|
|
6
|
+
*/
|
|
7
|
+
declare const useOperationList: (toolInstance: any) => {
|
|
8
|
+
empty: IOperationConfig;
|
|
9
|
+
setValidity: IOperationConfig;
|
|
10
|
+
copyPrevious: IOperationConfig;
|
|
11
|
+
};
|
|
12
|
+
export default useOperationList;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { IStepInfo } from '@/types/step';
|
|
3
|
+
import { ICustomToolInstance } from '@/hooks/annotation';
|
|
4
|
+
interface IProps {
|
|
5
|
+
stepInfo: IStepInfo;
|
|
6
|
+
toolInstance: ICustomToolInstance;
|
|
7
|
+
}
|
|
8
|
+
declare const _default: import("react-redux").ConnectedComponent<React.FC<IProps>, import("react-redux").Omit<IProps & {
|
|
9
|
+
children?: React.ReactNode;
|
|
10
|
+
}, "toolInstance" | "stepInfo">>;
|
|
11
|
+
export default _default;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @file Tool options on tool's sidebar
|
|
3
|
+
* @author Glenfiddish <edwinlee0927@hotmail.com>
|
|
4
|
+
* @createdate 2022-07-14
|
|
5
|
+
*/
|
|
6
|
+
import { EToolName } from '@/data/enums/ToolType';
|
|
7
|
+
export declare const ToolIcons: ({ toolName, selectedToolName, onChange, }: {
|
|
8
|
+
toolName: string;
|
|
9
|
+
selectedToolName?: string | undefined;
|
|
10
|
+
onChange: (toolName: EToolName) => void;
|
|
11
|
+
}) => JSX.Element;
|
|
@@ -3,5 +3,5 @@ interface IProps {
|
|
|
3
3
|
toolStyle: ToolStyleState;
|
|
4
4
|
config: string;
|
|
5
5
|
}
|
|
6
|
-
declare const _default: import("react-redux").ConnectedComponent<(props: IProps) => JSX.Element, import("react-redux").Omit<IProps, "
|
|
6
|
+
declare const _default: import("react-redux").ConnectedComponent<(props: IProps) => JSX.Element, import("react-redux").Omit<IProps, "toolStyle" | "config">>;
|
|
7
7
|
export default _default;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
interface
|
|
2
|
+
interface IPaginationProps {
|
|
3
3
|
imgIndex: number;
|
|
4
4
|
totalPage: number;
|
|
5
5
|
pageJump: (page: string) => void;
|
|
@@ -8,5 +8,15 @@ interface IPagination {
|
|
|
8
8
|
footerCls: string;
|
|
9
9
|
isVideo?: boolean;
|
|
10
10
|
}
|
|
11
|
-
|
|
11
|
+
interface IPageProps {
|
|
12
|
+
jumpSkip: Function;
|
|
13
|
+
imgIndex: number;
|
|
14
|
+
}
|
|
15
|
+
/**
|
|
16
|
+
* page input for changing current page or file index
|
|
17
|
+
* @param props
|
|
18
|
+
* @returns
|
|
19
|
+
*/
|
|
20
|
+
export declare const PageInput: (props: IPageProps) => JSX.Element;
|
|
21
|
+
export declare const Pagination: React.FC<IPaginationProps>;
|
|
12
22
|
export {};
|
|
@@ -1,10 +1,20 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { ToolInstance } from '@/store/annotation/types';
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
mode?:
|
|
3
|
+
import { FooterTheme } from '../index';
|
|
4
|
+
interface IZoomControllerProps {
|
|
5
|
+
mode?: FooterTheme;
|
|
6
|
+
initialPosition?: () => void;
|
|
7
|
+
zoomIn?: () => void;
|
|
8
|
+
zoomOut?: () => void;
|
|
6
9
|
}
|
|
7
|
-
declare const
|
|
10
|
+
export declare const ZoomController: React.FC<IZoomControllerProps>;
|
|
11
|
+
declare const _default: import("react-redux").ConnectedComponent<React.FC<{
|
|
12
|
+
toolInstance: ToolInstance;
|
|
13
|
+
mode: FooterTheme;
|
|
14
|
+
}>, import("react-redux").Omit<{
|
|
15
|
+
toolInstance: ToolInstance;
|
|
16
|
+
mode: FooterTheme;
|
|
17
|
+
} & {
|
|
8
18
|
children?: React.ReactNode;
|
|
9
19
|
}, "toolInstance">>;
|
|
10
20
|
export default _default;
|
|
@@ -1,11 +1,7 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { RenderFooter } from '@/types/main';
|
|
2
2
|
import { IStepInfo } from '@/types/step';
|
|
3
3
|
import React from 'react';
|
|
4
|
-
|
|
5
|
-
jumpSkip: Function;
|
|
6
|
-
imgIndex: number;
|
|
7
|
-
}
|
|
8
|
-
export declare const PageInput: (props: IPageProps) => JSX.Element;
|
|
4
|
+
export declare type FooterTheme = 'light' | 'dark';
|
|
9
5
|
interface IProps {
|
|
10
6
|
totalPage: number;
|
|
11
7
|
imgIndex: number;
|
|
@@ -16,10 +12,11 @@ interface IProps {
|
|
|
16
12
|
step: number;
|
|
17
13
|
basicResultList: any[];
|
|
18
14
|
basicIndex: number;
|
|
19
|
-
mode?:
|
|
20
|
-
footer?:
|
|
15
|
+
mode?: FooterTheme;
|
|
16
|
+
footer?: RenderFooter;
|
|
21
17
|
}
|
|
22
18
|
export declare const footerCls: string;
|
|
19
|
+
export declare const FooterDivider: () => JSX.Element;
|
|
23
20
|
declare const _default: import("react-redux").ConnectedComponent<React.FC<IProps>, import("react-redux").Omit<IProps & {
|
|
24
21
|
children?: React.ReactNode;
|
|
25
22
|
}, "stepList" | "step" | "imgIndex" | "basicResultList" | "basicIndex" | "totalPage">>;
|
|
@@ -11,5 +11,5 @@ interface IProps {
|
|
|
11
11
|
}
|
|
12
12
|
declare const _default: import("react-redux").ConnectedComponent<React.FC<IProps>, import("react-redux").Omit<IProps & {
|
|
13
13
|
children?: React.ReactNode;
|
|
14
|
-
}, "imgList" | "
|
|
14
|
+
}, "imgList" | "onSubmit" | "toolInstance" | "dispatch">>;
|
|
15
15
|
export default _default;
|
package/dist/utils/StepUtils.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";var index=require("../constant/index.js"),
|
|
1
|
+
"use strict";var index=require("../constant/index.js"),ToolUtils=require("./ToolUtils.js");class StepUtils{static getCurrentStepInfo(o,e){const t=this.getStepInfo(o,e);return[index.EStepType.QUALITY_INSPECTION,index.EStepType.MANUAL_CORRECTION].includes(t==null?void 0:t.type)?this.getStepInfo(t.dataSourceStep,e):t}static getStepInfo(o,e){return e==null?void 0:e.filter(t=>t.step===o)[0]}static currentToolIsVideo(o,e){const t=StepUtils.getCurrentStepInfo(o,e);return ToolUtils.isVideoTool(t==null?void 0:t.tool)}static currentToolIsPointCloud(o,e){const t=StepUtils.getCurrentStepInfo(o,e);return ToolUtils.isPointCloudTool(t==null?void 0:t.tool)}}module.exports=StepUtils;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";var lbAnnotation=require("@labelbee/lb-annotation");const{EVideoToolName,EPointCloudName}=lbAnnotation.cTool;class ToolUtils{static isVideoTool(e){return e?Object.values(EVideoToolName).includes(e):!1}static isPointCloudTool(e){return e?Object.values(EPointCloudName).includes(e):!1}}module.exports=ToolUtils;
|
package/dist/utils/data.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var index=require("./index.js"),StepUtils=require("./StepUtils.js"),__defProp=Object.defineProperty,__defProps=Object.defineProperties,__getOwnPropDescs=Object.getOwnPropertyDescriptors,__getOwnPropSymbols=Object.getOwnPropertySymbols,__hasOwnProp=Object.prototype.hasOwnProperty,__propIsEnum=Object.prototype.propertyIsEnumerable,__defNormalProp=(r,e,t)=>e in r?__defProp(r,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):r[e]=t,__spreadValues=(r,e)=>{for(var t in e||(e={}))__hasOwnProp.call(e,t)&&__defNormalProp(r,t,e[t]);if(__getOwnPropSymbols)for(var t of __getOwnPropSymbols(e))__propIsEnum.call(e,t)&&__defNormalProp(r,t,e[t]);return r},__spreadProps=(r,e)=>__defProps(r,__getOwnPropDescs(e));const composeResultWithBasicImgInfo=(r,e)=>JSON.stringify(__spreadValues(__spreadValues({},index.jsonParser(r)),e)),composeResult=(r,e,t)=>{const{step:
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var index=require("./index.js"),StepUtils=require("./StepUtils.js"),__defProp=Object.defineProperty,__defProps=Object.defineProperties,__getOwnPropDescs=Object.getOwnPropertyDescriptors,__getOwnPropSymbols=Object.getOwnPropertySymbols,__hasOwnProp=Object.prototype.hasOwnProperty,__propIsEnum=Object.prototype.propertyIsEnumerable,__defNormalProp=(r,e,t)=>e in r?__defProp(r,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):r[e]=t,__spreadValues=(r,e)=>{for(var t in e||(e={}))__hasOwnProp.call(e,t)&&__defNormalProp(r,t,e[t]);if(__getOwnPropSymbols)for(var t of __getOwnPropSymbols(e))__propIsEnum.call(e,t)&&__defNormalProp(r,t,e[t]);return r},__spreadProps=(r,e)=>__defProps(r,__getOwnPropDescs(e));const composeResultWithBasicImgInfo=(r,e)=>JSON.stringify(__spreadValues(__spreadValues({},index.jsonParser(r)),e)),composeResult=(r,e,t,c)=>{const{step:a,stepList:l}=e,{rect:n,basicRectID:u}=t;try{const s=index.jsonParser(r),f=StepUtils.getCurrentStepInfo(a,l),{dataSourceStep:_}=f,i=`step_${f.step}`;if(s[i]){const o=s[i];return Object.assign(o,c),o.result?(JSON.stringify(o.result)===JSON.stringify(n)||(u?o.result=[...o.result.filter(p=>!(p.sourceID&&p.sourceID===u)),...n.filter(p=>p.sourceID&&p.sourceID===u)]:o.result=n),JSON.stringify(s)):JSON.stringify(__spreadProps(__spreadValues({},s),{[i]:__spreadProps(__spreadValues(__spreadValues({},s[i]),c),{result:n})}))}return JSON.stringify(__spreadProps(__spreadValues({},s),{[i]:__spreadProps(__spreadValues({dataSourceStep:_},c),{toolName:l[a-1].tool,result:n})}))}catch(s){return r}};exports.composeResult=composeResult,exports.composeResultWithBasicImgInfo=composeResultWithBasicImgInfo;
|